Skip to content

Commit eb1c6cf

Browse files
committed
fix: subtitles disappearing when resizing the window
1 parent b8f2501 commit eb1c6cf

File tree

5 files changed

+14
-25
lines changed

5 files changed

+14
-25
lines changed

electron-builder.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,6 @@ afterPack: scripts/cleaned-unused-arch-deps.js
6868
afterSign: scripts/notarize.js
6969
releaseInfo:
7070
releaseNotes: |
71-
修复视频导入失败的问题
72-
初次访问 web 版本提示优化
73-
修复内嵌字幕多次加载的问题
71+
优化提示信息
72+
修复改变窗口大小字幕消失的问题
7473

package.json

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,9 @@
4444
"@electron-toolkit/utils": "^3.0.0",
4545
"@electron/notarize": "^2.5.0",
4646
"@fontsource/manrope": "^5.0.21",
47-
"@hrgui/libass-wasm-ts": "^1.0.3",
4847
"@iconify-json/mingcute": "^1.1.19",
4948
"@iconify/tailwind": "^1.1.2",
49+
"@jellyfin/libass-wasm": "^4.2.3",
5050
"@radix-ui/react-accordion": "^1.2.0",
5151
"@radix-ui/react-checkbox": "^1.1.3",
5252
"@radix-ui/react-context-menu": "^2.2.2",
@@ -97,7 +97,6 @@
9797
"fluent-ffmpeg": "^2.1.3",
9898
"framer-motion": "^12.0.0-alpha.2",
9999
"jotai": "^2.9.3",
100-
"libass-wasm": "^4.1.0",
101100
"lint-staged": "^15.2.8",
102101
"lodash-es": "^4.17.21",
103102
"lowdb": "^7.0.1",

pnpm-lock.yaml

Lines changed: 8 additions & 16 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/renderer/src/components/modules/player/setting/items/subtitle/hooks.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
1+
import SubtitlesOctopus from '@jellyfin/libass-wasm'
2+
import workerUrl from '@jellyfin/libass-wasm/dist/js/subtitles-octopus-worker.js?url'
3+
import legacyWorkerUrl from '@jellyfin/libass-wasm/dist/js/subtitles-octopus-worker-legacy.js?url'
14
import { MARCHEN_PROTOCOL_PREFIX } from '@main/constants/protocol'
25
import { videoAtom } from '@renderer/atoms/player'
36
import { useToast } from '@renderer/components/ui/toast'
@@ -7,9 +10,6 @@ import { isWeb } from '@renderer/lib/utils'
710
import NotoSansSC from '@renderer/styles/fonts/notoSansSC-medium.woff2?url'
811
import { useQuery } from '@tanstack/react-query'
912
import { atom, useAtom, useAtomValue, useSetAtom } from 'jotai'
10-
import SubtitlesOctopus from 'libass-wasm'
11-
import workerUrl from 'libass-wasm/dist/js/subtitles-octopus-worker.js?url'
12-
import legacyWorkerUrl from 'libass-wasm/dist/js/subtitles-octopus-worker-legacy.js?url'
1313
import { useCallback } from 'react'
1414

1515
import { usePlayerInstance, useSubtitleInstance } from '../../../Context'

tsconfig.web.json

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,5 @@
2929
"@main/*": ["src/main/*"],
3030
"@pkg": ["./package.json"]
3131
},
32-
"types": ["@hrgui/libass-wasm-ts"]
3332
}
3433
}

0 commit comments

Comments
 (0)