@lazycatcloud/lzc-video-player 1.1.1 → 1.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +48 -48
- package/dist/{browser-ponyfill.9fe1939a.js → browser-ponyfill.e29f9cb8.js} +1 -1
- package/dist/{lzc-video-player.7a1118d5.js → lzc-video-player.6c755f5f.js} +16056 -15969
- package/dist/lzc-video-player.js +2 -2
- package/dist/src/components/Dialog/index.vue.d.ts +24 -24
- package/dist/src/components/MultipleEdit/choose.vue.d.ts +20 -20
- package/dist/src/components/PlayList/index.vue.d.ts +26 -26
- package/dist/src/components/Spectrum/index.vue.d.ts +2 -2
- package/dist/src/components/Video/NativeVideoPlayer.vue.d.ts +79 -78
- package/dist/src/components/Video/components/LzcModal/components/simpleList.vue.d.ts +36 -36
- package/dist/src/components/Video/components/LzcModal/list.vue.d.ts +13 -13
- package/dist/src/components/Video/components/LzcModal/playrate.vue.d.ts +13 -13
- package/dist/src/components/Video/components/LzcModal/resolution.vue.d.ts +13 -13
- package/dist/src/components/Video/components/LzcModal/subtitle.vue.d.ts +13 -13
- package/dist/src/components/Video/components/LzcModal/useModal.d.ts +14 -14
- package/dist/src/components/Video/components/LzcOverlay/SubtitleLayer.vue.d.ts +19 -19
- package/dist/src/components/Video/components/LzcOverlay/cast.vue.d.ts +23 -23
- package/dist/src/components/Video/components/LzcOverlay/casting.vue.d.ts +13 -13
- package/dist/src/components/Video/components/LzcOverlay/error.vue.d.ts +13 -13
- package/dist/src/components/Video/components/LzcOverlay/helper.d.ts +26 -26
- package/dist/src/components/Video/components/LzcOverlay/index.vue.d.ts +25 -19
- package/dist/src/components/Video/components/LzcOverlay/playing.vue.d.ts +25 -19
- package/dist/src/components/Video/components/LzcOverlay/playingButtons.vue.d.ts +19 -13
- package/dist/src/components/Video/components/LzcOverlay/playingLayout.vue.d.ts +32 -26
- package/dist/src/components/Video/components/LzcOverlay/useCast.d.ts +16 -16
- package/dist/src/components/Video/components/LzcOverlay/useCommon.d.ts +5 -5
- package/dist/src/components/Video/components/LzcOverlay/useOctopusRenderer.d.ts +11 -11
- package/dist/src/components/Video/components/LzcOverlay/useSubtitleRenderEngine.d.ts +9 -9
- package/dist/src/components/Video/components/LzcOverlay/useSubtitleTrack.d.ts +7 -7
- package/dist/src/components/Video/components/useLzcCommon.d.ts +2 -2
- package/dist/src/components/Video/directPlay.d.ts +43 -43
- package/dist/src/components/Video/getSubtitleInfo.d.ts +2 -2
- package/dist/src/components/Video/native/EventEmitter.d.ts +22 -22
- package/dist/src/components/Video/native/NativeControls.vue.d.ts +117 -90
- package/dist/src/components/Video/native/NativeModal.vue.d.ts +44 -38
- package/dist/src/components/Video/native/NativePlayer.d.ts +198 -197
- package/dist/src/components/Video/native/NativePlayer.vue.d.ts +27 -27
- package/dist/src/components/Video/native/index.d.ts +3 -3
- package/dist/src/components/Video/native/playerKey.d.ts +3 -3
- package/dist/src/components/Video/native/useNativeCastMiddleware.d.ts +2 -2
- package/dist/src/components/Video/native/useNativePlayer.d.ts +2 -2
- package/dist/src/components/Video/native/useNativePlayerFullscreen.d.ts +10 -10
- package/dist/src/components/Video/native/useNativePlayerHistory.d.ts +9 -9
- package/dist/src/components/Video/native/useNativePlayerModal.d.ts +17 -17
- package/dist/src/components/Video/native/useNativePlayerPlaylist.d.ts +9 -9
- package/dist/src/components/Video/native/useNativePlayerState.d.ts +16 -16
- package/dist/src/components/Video/player.d.ts +99 -98
- package/dist/src/components/Video/useSource.d.ts +14 -14
- package/dist/src/components/Video/useSubtitlePreference.d.ts +11 -11
- package/dist/src/components/Video/useWebview.d.ts +7 -7
- package/dist/src/components/Video/videoFrame.d.ts +2 -2
- package/dist/src/i18n/index.d.ts +10 -10
- package/dist/src/lzc-video-player.d.ts +4 -6
- package/dist/src/model.d.ts +63 -63
- package/dist/src/stores/pinia.d.ts +2 -2
- package/dist/src/stores/playlist.d.ts +361 -361
- package/dist/src/use/useKeyBind.d.ts +3 -3
- package/dist/src/use/useMultipleEdit.d.ts +9 -9
- package/dist/src/use/useSdk.d.ts +5 -5
- package/dist/src/use/useSubtitle.d.ts +23 -23
- package/dist/src/use/useUtils.d.ts +3 -3
- package/dist/src/use/useVideoFrame.d.ts +5 -5
- package/package.json +22 -22
|
@@ -1,361 +1,361 @@
|
|
|
1
|
-
import { RemoteDB } from "@lazycatcloud/minidb";
|
|
2
|
-
import type { VideoInfo } from '../model';
|
|
3
|
-
export declare const useHistoryInfo: () => import("pinia").Store<"historyInfo", {
|
|
4
|
-
collection: RemoteDB<VideoInfo>;
|
|
5
|
-
infos: VideoInfo[];
|
|
6
|
-
ready: Promise<void>;
|
|
7
|
-
/** 从历史记录点击播放时传入的完整 info,供 Player 优先使用 */
|
|
8
|
-
pendingPlayInfo: VideoInfo | null;
|
|
9
|
-
}, {
|
|
10
|
-
getHistoryInfo(state: {
|
|
11
|
-
collection: {
|
|
12
|
-
find: (selector: Record<string, any>, options?: import("@lazycatcloud/minidb/dist/remoteDB").CollectionFindOptions | undefined) => {
|
|
13
|
-
fetch: () => Promise<VideoInfo[]>;
|
|
14
|
-
};
|
|
15
|
-
findOne: (selector: Record<string, any>, options?: import("@lazycatcloud/minidb/dist/remoteDB").CollectionFindOptions | undefined) => Promise<VideoInfo | null>;
|
|
16
|
-
upsertOrUpdate: (selector: Record<string, any>, doc: VideoInfo, options?: import("@lazycatcloud/minidb/dist/remoteDB").CollectionFindOptions | undefined) => Promise<VideoInfo | null>;
|
|
17
|
-
upsert: {
|
|
18
|
-
(doc: VideoInfo): Promise<VideoInfo | null>;
|
|
19
|
-
(doc: VideoInfo, base: VideoInfo | null | undefined): Promise<VideoInfo | null>;
|
|
20
|
-
(docs: VideoInfo[]): Promise<(VideoInfo | null)[]>;
|
|
21
|
-
(docs: VideoInfo[], bases: (VideoInfo | null | undefined)[]): Promise<(VideoInfo | null)[]>;
|
|
22
|
-
};
|
|
23
|
-
remove: {
|
|
24
|
-
(id: any): Promise<void>;
|
|
25
|
-
(ids: any[]): Promise<void>;
|
|
26
|
-
};
|
|
27
|
-
};
|
|
28
|
-
infos: {
|
|
29
|
-
sourceUrl: string;
|
|
30
|
-
name: string;
|
|
31
|
-
duration: number;
|
|
32
|
-
currentTime: number;
|
|
33
|
-
invalid: boolean;
|
|
34
|
-
updateTime: number | undefined;
|
|
35
|
-
fromNetdisk: boolean;
|
|
36
|
-
path: string | undefined;
|
|
37
|
-
subtitles: {
|
|
38
|
-
name: string;
|
|
39
|
-
language: string;
|
|
40
|
-
stream_index: number;
|
|
41
|
-
codec_name: string;
|
|
42
|
-
is_external: boolean;
|
|
43
|
-
path: string;
|
|
44
|
-
vtt_url?: string | undefined;
|
|
45
|
-
track_id?: string | undefined;
|
|
46
|
-
ass_url?: string | undefined;
|
|
47
|
-
ass_fonts?: string[] | undefined;
|
|
48
|
-
ass_renderable?: boolean | undefined;
|
|
49
|
-
ass_unavailable_reason?: string | undefined;
|
|
50
|
-
default?: boolean | undefined;
|
|
51
|
-
}[] | undefined;
|
|
52
|
-
beforeHiddenSubtitle?: {
|
|
53
|
-
name: string;
|
|
54
|
-
language: string;
|
|
55
|
-
stream_index: number;
|
|
56
|
-
codec_name: string;
|
|
57
|
-
is_external: boolean;
|
|
58
|
-
path: string;
|
|
59
|
-
vtt_url?: string | undefined;
|
|
60
|
-
track_id?: string | undefined;
|
|
61
|
-
ass_url?: string | undefined;
|
|
62
|
-
ass_fonts?: string[] | undefined;
|
|
63
|
-
ass_renderable?: boolean | undefined;
|
|
64
|
-
ass_unavailable_reason?: string | undefined;
|
|
65
|
-
default?: boolean | undefined;
|
|
66
|
-
} | undefined;
|
|
67
|
-
requestHistory?: boolean | undefined;
|
|
68
|
-
playMode?: "hls" | "direct" | undefined;
|
|
69
|
-
resolvedSourceUrl?: string | undefined;
|
|
70
|
-
originHlsUrl?: string | undefined;
|
|
71
|
-
originDirectUrl?: string | undefined;
|
|
72
|
-
subtitleInfoUrl?: string | undefined;
|
|
73
|
-
_id: string;
|
|
74
|
-
}[];
|
|
75
|
-
ready: {
|
|
76
|
-
then: <TResult1 = void, TResult2 = never>(onfulfilled?: ((value: void) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined) => Promise<TResult1 | TResult2>;
|
|
77
|
-
catch: <TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | null | undefined) => Promise<void | TResult>;
|
|
78
|
-
finally: (onfinally?: (() => void) | null | undefined) => Promise<void>;
|
|
79
|
-
readonly [Symbol.toStringTag]: string;
|
|
80
|
-
};
|
|
81
|
-
pendingPlayInfo: {
|
|
82
|
-
sourceUrl: string;
|
|
83
|
-
name: string;
|
|
84
|
-
duration: number;
|
|
85
|
-
currentTime: number;
|
|
86
|
-
invalid: boolean;
|
|
87
|
-
updateTime: number | undefined;
|
|
88
|
-
fromNetdisk: boolean;
|
|
89
|
-
path: string | undefined;
|
|
90
|
-
subtitles: {
|
|
91
|
-
name: string;
|
|
92
|
-
language: string;
|
|
93
|
-
stream_index: number;
|
|
94
|
-
codec_name: string;
|
|
95
|
-
is_external: boolean;
|
|
96
|
-
path: string;
|
|
97
|
-
vtt_url?: string | undefined;
|
|
98
|
-
track_id?: string | undefined;
|
|
99
|
-
ass_url?: string | undefined;
|
|
100
|
-
ass_fonts?: string[] | undefined;
|
|
101
|
-
ass_renderable?: boolean | undefined;
|
|
102
|
-
ass_unavailable_reason?: string | undefined;
|
|
103
|
-
default?: boolean | undefined;
|
|
104
|
-
}[] | undefined;
|
|
105
|
-
beforeHiddenSubtitle?: {
|
|
106
|
-
name: string;
|
|
107
|
-
language: string;
|
|
108
|
-
stream_index: number;
|
|
109
|
-
codec_name: string;
|
|
110
|
-
is_external: boolean;
|
|
111
|
-
path: string;
|
|
112
|
-
vtt_url?: string | undefined;
|
|
113
|
-
track_id?: string | undefined;
|
|
114
|
-
ass_url?: string | undefined;
|
|
115
|
-
ass_fonts?: string[] | undefined;
|
|
116
|
-
ass_renderable?: boolean | undefined;
|
|
117
|
-
ass_unavailable_reason?: string | undefined;
|
|
118
|
-
default?: boolean | undefined;
|
|
119
|
-
} | undefined;
|
|
120
|
-
requestHistory?: boolean | undefined;
|
|
121
|
-
playMode?: "hls" | "direct" | undefined;
|
|
122
|
-
resolvedSourceUrl?: string | undefined;
|
|
123
|
-
originHlsUrl?: string | undefined;
|
|
124
|
-
originDirectUrl?: string | undefined;
|
|
125
|
-
subtitleInfoUrl?: string | undefined;
|
|
126
|
-
_id: string;
|
|
127
|
-
} | null;
|
|
128
|
-
} & import("pinia").PiniaCustomStateProperties<{
|
|
129
|
-
collection: RemoteDB<VideoInfo>;
|
|
130
|
-
infos: VideoInfo[];
|
|
131
|
-
ready: Promise<void>;
|
|
132
|
-
/** 从历史记录点击播放时传入的完整 info,供 Player 优先使用 */
|
|
133
|
-
pendingPlayInfo: VideoInfo | null;
|
|
134
|
-
}>): (sourceUrl: string) => {
|
|
135
|
-
sourceUrl: string;
|
|
136
|
-
name: string;
|
|
137
|
-
duration: number;
|
|
138
|
-
currentTime: number;
|
|
139
|
-
invalid: boolean;
|
|
140
|
-
updateTime: number | undefined;
|
|
141
|
-
fromNetdisk: boolean;
|
|
142
|
-
path: string | undefined;
|
|
143
|
-
subtitles: {
|
|
144
|
-
name: string;
|
|
145
|
-
language: string;
|
|
146
|
-
stream_index: number;
|
|
147
|
-
codec_name: string;
|
|
148
|
-
is_external: boolean;
|
|
149
|
-
path: string;
|
|
150
|
-
vtt_url?: string | undefined;
|
|
151
|
-
track_id?: string | undefined;
|
|
152
|
-
ass_url?: string | undefined;
|
|
153
|
-
ass_fonts?: string[] | undefined;
|
|
154
|
-
ass_renderable?: boolean | undefined;
|
|
155
|
-
ass_unavailable_reason?: string | undefined;
|
|
156
|
-
default?: boolean | undefined;
|
|
157
|
-
}[] | undefined;
|
|
158
|
-
beforeHiddenSubtitle?: {
|
|
159
|
-
name: string;
|
|
160
|
-
language: string;
|
|
161
|
-
stream_index: number;
|
|
162
|
-
codec_name: string;
|
|
163
|
-
is_external: boolean;
|
|
164
|
-
path: string;
|
|
165
|
-
vtt_url?: string | undefined;
|
|
166
|
-
track_id?: string | undefined;
|
|
167
|
-
ass_url?: string | undefined;
|
|
168
|
-
ass_fonts?: string[] | undefined;
|
|
169
|
-
ass_renderable?: boolean | undefined;
|
|
170
|
-
ass_unavailable_reason?: string | undefined;
|
|
171
|
-
default?: boolean | undefined;
|
|
172
|
-
} | undefined;
|
|
173
|
-
requestHistory?: boolean | undefined;
|
|
174
|
-
playMode?: "hls" | "direct" | undefined;
|
|
175
|
-
resolvedSourceUrl?: string | undefined;
|
|
176
|
-
originHlsUrl?: string | undefined;
|
|
177
|
-
originDirectUrl?: string | undefined;
|
|
178
|
-
subtitleInfoUrl?: string | undefined;
|
|
179
|
-
_id: string;
|
|
180
|
-
} | undefined;
|
|
181
|
-
getHistoryInfoByPath(state: {
|
|
182
|
-
collection: {
|
|
183
|
-
find: (selector: Record<string, any>, options?: import("@lazycatcloud/minidb/dist/remoteDB").CollectionFindOptions | undefined) => {
|
|
184
|
-
fetch: () => Promise<VideoInfo[]>;
|
|
185
|
-
};
|
|
186
|
-
findOne: (selector: Record<string, any>, options?: import("@lazycatcloud/minidb/dist/remoteDB").CollectionFindOptions | undefined) => Promise<VideoInfo | null>;
|
|
187
|
-
upsertOrUpdate: (selector: Record<string, any>, doc: VideoInfo, options?: import("@lazycatcloud/minidb/dist/remoteDB").CollectionFindOptions | undefined) => Promise<VideoInfo | null>;
|
|
188
|
-
upsert: {
|
|
189
|
-
(doc: VideoInfo): Promise<VideoInfo | null>;
|
|
190
|
-
(doc: VideoInfo, base: VideoInfo | null | undefined): Promise<VideoInfo | null>;
|
|
191
|
-
(docs: VideoInfo[]): Promise<(VideoInfo | null)[]>;
|
|
192
|
-
(docs: VideoInfo[], bases: (VideoInfo | null | undefined)[]): Promise<(VideoInfo | null)[]>;
|
|
193
|
-
};
|
|
194
|
-
remove: {
|
|
195
|
-
(id: any): Promise<void>;
|
|
196
|
-
(ids: any[]): Promise<void>;
|
|
197
|
-
};
|
|
198
|
-
};
|
|
199
|
-
infos: {
|
|
200
|
-
sourceUrl: string;
|
|
201
|
-
name: string;
|
|
202
|
-
duration: number;
|
|
203
|
-
currentTime: number;
|
|
204
|
-
invalid: boolean;
|
|
205
|
-
updateTime: number | undefined;
|
|
206
|
-
fromNetdisk: boolean;
|
|
207
|
-
path: string | undefined;
|
|
208
|
-
subtitles: {
|
|
209
|
-
name: string;
|
|
210
|
-
language: string;
|
|
211
|
-
stream_index: number;
|
|
212
|
-
codec_name: string;
|
|
213
|
-
is_external: boolean;
|
|
214
|
-
path: string;
|
|
215
|
-
vtt_url?: string | undefined;
|
|
216
|
-
track_id?: string | undefined;
|
|
217
|
-
ass_url?: string | undefined;
|
|
218
|
-
ass_fonts?: string[] | undefined;
|
|
219
|
-
ass_renderable?: boolean | undefined;
|
|
220
|
-
ass_unavailable_reason?: string | undefined;
|
|
221
|
-
default?: boolean | undefined;
|
|
222
|
-
}[] | undefined;
|
|
223
|
-
beforeHiddenSubtitle?: {
|
|
224
|
-
name: string;
|
|
225
|
-
language: string;
|
|
226
|
-
stream_index: number;
|
|
227
|
-
codec_name: string;
|
|
228
|
-
is_external: boolean;
|
|
229
|
-
path: string;
|
|
230
|
-
vtt_url?: string | undefined;
|
|
231
|
-
track_id?: string | undefined;
|
|
232
|
-
ass_url?: string | undefined;
|
|
233
|
-
ass_fonts?: string[] | undefined;
|
|
234
|
-
ass_renderable?: boolean | undefined;
|
|
235
|
-
ass_unavailable_reason?: string | undefined;
|
|
236
|
-
default?: boolean | undefined;
|
|
237
|
-
} | undefined;
|
|
238
|
-
requestHistory?: boolean | undefined;
|
|
239
|
-
playMode?: "hls" | "direct" | undefined;
|
|
240
|
-
resolvedSourceUrl?: string | undefined;
|
|
241
|
-
originHlsUrl?: string | undefined;
|
|
242
|
-
originDirectUrl?: string | undefined;
|
|
243
|
-
subtitleInfoUrl?: string | undefined;
|
|
244
|
-
_id: string;
|
|
245
|
-
}[];
|
|
246
|
-
ready: {
|
|
247
|
-
then: <TResult1 = void, TResult2 = never>(onfulfilled?: ((value: void) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined) => Promise<TResult1 | TResult2>;
|
|
248
|
-
catch: <TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | null | undefined) => Promise<void | TResult>;
|
|
249
|
-
finally: (onfinally?: (() => void) | null | undefined) => Promise<void>;
|
|
250
|
-
readonly [Symbol.toStringTag]: string;
|
|
251
|
-
};
|
|
252
|
-
pendingPlayInfo: {
|
|
253
|
-
sourceUrl: string;
|
|
254
|
-
name: string;
|
|
255
|
-
duration: number;
|
|
256
|
-
currentTime: number;
|
|
257
|
-
invalid: boolean;
|
|
258
|
-
updateTime: number | undefined;
|
|
259
|
-
fromNetdisk: boolean;
|
|
260
|
-
path: string | undefined;
|
|
261
|
-
subtitles: {
|
|
262
|
-
name: string;
|
|
263
|
-
language: string;
|
|
264
|
-
stream_index: number;
|
|
265
|
-
codec_name: string;
|
|
266
|
-
is_external: boolean;
|
|
267
|
-
path: string;
|
|
268
|
-
vtt_url?: string | undefined;
|
|
269
|
-
track_id?: string | undefined;
|
|
270
|
-
ass_url?: string | undefined;
|
|
271
|
-
ass_fonts?: string[] | undefined;
|
|
272
|
-
ass_renderable?: boolean | undefined;
|
|
273
|
-
ass_unavailable_reason?: string | undefined;
|
|
274
|
-
default?: boolean | undefined;
|
|
275
|
-
}[] | undefined;
|
|
276
|
-
beforeHiddenSubtitle?: {
|
|
277
|
-
name: string;
|
|
278
|
-
language: string;
|
|
279
|
-
stream_index: number;
|
|
280
|
-
codec_name: string;
|
|
281
|
-
is_external: boolean;
|
|
282
|
-
path: string;
|
|
283
|
-
vtt_url?: string | undefined;
|
|
284
|
-
track_id?: string | undefined;
|
|
285
|
-
ass_url?: string | undefined;
|
|
286
|
-
ass_fonts?: string[] | undefined;
|
|
287
|
-
ass_renderable?: boolean | undefined;
|
|
288
|
-
ass_unavailable_reason?: string | undefined;
|
|
289
|
-
default?: boolean | undefined;
|
|
290
|
-
} | undefined;
|
|
291
|
-
requestHistory?: boolean | undefined;
|
|
292
|
-
playMode?: "hls" | "direct" | undefined;
|
|
293
|
-
resolvedSourceUrl?: string | undefined;
|
|
294
|
-
originHlsUrl?: string | undefined;
|
|
295
|
-
originDirectUrl?: string | undefined;
|
|
296
|
-
subtitleInfoUrl?: string | undefined;
|
|
297
|
-
_id: string;
|
|
298
|
-
} | null;
|
|
299
|
-
} & import("pinia").PiniaCustomStateProperties<{
|
|
300
|
-
collection: RemoteDB<VideoInfo>;
|
|
301
|
-
infos: VideoInfo[];
|
|
302
|
-
ready: Promise<void>;
|
|
303
|
-
/** 从历史记录点击播放时传入的完整 info,供 Player 优先使用 */
|
|
304
|
-
pendingPlayInfo: VideoInfo | null;
|
|
305
|
-
}>): (path: string) => {
|
|
306
|
-
sourceUrl: string;
|
|
307
|
-
name: string;
|
|
308
|
-
duration: number;
|
|
309
|
-
currentTime: number;
|
|
310
|
-
invalid: boolean;
|
|
311
|
-
updateTime: number | undefined;
|
|
312
|
-
fromNetdisk: boolean;
|
|
313
|
-
path: string | undefined;
|
|
314
|
-
subtitles: {
|
|
315
|
-
name: string;
|
|
316
|
-
language: string;
|
|
317
|
-
stream_index: number;
|
|
318
|
-
codec_name: string;
|
|
319
|
-
is_external: boolean;
|
|
320
|
-
path: string;
|
|
321
|
-
vtt_url?: string | undefined;
|
|
322
|
-
track_id?: string | undefined;
|
|
323
|
-
ass_url?: string | undefined;
|
|
324
|
-
ass_fonts?: string[] | undefined;
|
|
325
|
-
ass_renderable?: boolean | undefined;
|
|
326
|
-
ass_unavailable_reason?: string | undefined;
|
|
327
|
-
default?: boolean | undefined;
|
|
328
|
-
}[] | undefined;
|
|
329
|
-
beforeHiddenSubtitle?: {
|
|
330
|
-
name: string;
|
|
331
|
-
language: string;
|
|
332
|
-
stream_index: number;
|
|
333
|
-
codec_name: string;
|
|
334
|
-
is_external: boolean;
|
|
335
|
-
path: string;
|
|
336
|
-
vtt_url?: string | undefined;
|
|
337
|
-
track_id?: string | undefined;
|
|
338
|
-
ass_url?: string | undefined;
|
|
339
|
-
ass_fonts?: string[] | undefined;
|
|
340
|
-
ass_renderable?: boolean | undefined;
|
|
341
|
-
ass_unavailable_reason?: string | undefined;
|
|
342
|
-
default?: boolean | undefined;
|
|
343
|
-
} | undefined;
|
|
344
|
-
requestHistory?: boolean | undefined;
|
|
345
|
-
playMode?: "hls" | "direct" | undefined;
|
|
346
|
-
resolvedSourceUrl?: string | undefined;
|
|
347
|
-
originHlsUrl?: string | undefined;
|
|
348
|
-
originDirectUrl?: string | undefined;
|
|
349
|
-
subtitleInfoUrl?: string | undefined;
|
|
350
|
-
_id: string;
|
|
351
|
-
} | undefined;
|
|
352
|
-
}, {
|
|
353
|
-
init(): Promise<void>;
|
|
354
|
-
refreshData(): Promise<void>;
|
|
355
|
-
deleteHistory(info: VideoInfo): Promise<void>;
|
|
356
|
-
batchDeleteHistory(ids: string[]): Promise<void>;
|
|
357
|
-
updateOrCreateHistory(info: VideoInfo, blobFn: (() => Promise<Blob | null>) | null): Promise<void>;
|
|
358
|
-
markAsInvalid(sourceUrl: string): Promise<void>;
|
|
359
|
-
setPendingPlayInfo(info: VideoInfo | null): void;
|
|
360
|
-
clear(): Promise<void>;
|
|
361
|
-
}>;
|
|
1
|
+
import { RemoteDB } from "@lazycatcloud/minidb";
|
|
2
|
+
import type { VideoInfo } from '../model';
|
|
3
|
+
export declare const useHistoryInfo: () => import("pinia").Store<"historyInfo", {
|
|
4
|
+
collection: RemoteDB<VideoInfo>;
|
|
5
|
+
infos: VideoInfo[];
|
|
6
|
+
ready: Promise<void>;
|
|
7
|
+
/** 从历史记录点击播放时传入的完整 info,供 Player 优先使用 */
|
|
8
|
+
pendingPlayInfo: VideoInfo | null;
|
|
9
|
+
}, {
|
|
10
|
+
getHistoryInfo(state: {
|
|
11
|
+
collection: {
|
|
12
|
+
find: (selector: Record<string, any>, options?: import("@lazycatcloud/minidb/dist/remoteDB").CollectionFindOptions | undefined) => {
|
|
13
|
+
fetch: () => Promise<VideoInfo[]>;
|
|
14
|
+
};
|
|
15
|
+
findOne: (selector: Record<string, any>, options?: import("@lazycatcloud/minidb/dist/remoteDB").CollectionFindOptions | undefined) => Promise<VideoInfo | null>;
|
|
16
|
+
upsertOrUpdate: (selector: Record<string, any>, doc: VideoInfo, options?: import("@lazycatcloud/minidb/dist/remoteDB").CollectionFindOptions | undefined) => Promise<VideoInfo | null>;
|
|
17
|
+
upsert: {
|
|
18
|
+
(doc: VideoInfo): Promise<VideoInfo | null>;
|
|
19
|
+
(doc: VideoInfo, base: VideoInfo | null | undefined): Promise<VideoInfo | null>;
|
|
20
|
+
(docs: VideoInfo[]): Promise<(VideoInfo | null)[]>;
|
|
21
|
+
(docs: VideoInfo[], bases: (VideoInfo | null | undefined)[]): Promise<(VideoInfo | null)[]>;
|
|
22
|
+
};
|
|
23
|
+
remove: {
|
|
24
|
+
(id: any): Promise<void>;
|
|
25
|
+
(ids: any[]): Promise<void>;
|
|
26
|
+
};
|
|
27
|
+
};
|
|
28
|
+
infos: {
|
|
29
|
+
sourceUrl: string;
|
|
30
|
+
name: string;
|
|
31
|
+
duration: number;
|
|
32
|
+
currentTime: number;
|
|
33
|
+
invalid: boolean;
|
|
34
|
+
updateTime: number | undefined;
|
|
35
|
+
fromNetdisk: boolean;
|
|
36
|
+
path: string | undefined;
|
|
37
|
+
subtitles: {
|
|
38
|
+
name: string;
|
|
39
|
+
language: string;
|
|
40
|
+
stream_index: number;
|
|
41
|
+
codec_name: string;
|
|
42
|
+
is_external: boolean;
|
|
43
|
+
path: string;
|
|
44
|
+
vtt_url?: string | undefined;
|
|
45
|
+
track_id?: string | undefined;
|
|
46
|
+
ass_url?: string | undefined;
|
|
47
|
+
ass_fonts?: string[] | undefined;
|
|
48
|
+
ass_renderable?: boolean | undefined;
|
|
49
|
+
ass_unavailable_reason?: string | undefined;
|
|
50
|
+
default?: boolean | undefined;
|
|
51
|
+
}[] | undefined;
|
|
52
|
+
beforeHiddenSubtitle?: {
|
|
53
|
+
name: string;
|
|
54
|
+
language: string;
|
|
55
|
+
stream_index: number;
|
|
56
|
+
codec_name: string;
|
|
57
|
+
is_external: boolean;
|
|
58
|
+
path: string;
|
|
59
|
+
vtt_url?: string | undefined;
|
|
60
|
+
track_id?: string | undefined;
|
|
61
|
+
ass_url?: string | undefined;
|
|
62
|
+
ass_fonts?: string[] | undefined;
|
|
63
|
+
ass_renderable?: boolean | undefined;
|
|
64
|
+
ass_unavailable_reason?: string | undefined;
|
|
65
|
+
default?: boolean | undefined;
|
|
66
|
+
} | undefined;
|
|
67
|
+
requestHistory?: boolean | undefined;
|
|
68
|
+
playMode?: "hls" | "direct" | undefined;
|
|
69
|
+
resolvedSourceUrl?: string | undefined;
|
|
70
|
+
originHlsUrl?: string | undefined;
|
|
71
|
+
originDirectUrl?: string | undefined;
|
|
72
|
+
subtitleInfoUrl?: string | undefined;
|
|
73
|
+
_id: string;
|
|
74
|
+
}[];
|
|
75
|
+
ready: {
|
|
76
|
+
then: <TResult1 = void, TResult2 = never>(onfulfilled?: ((value: void) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined) => Promise<TResult1 | TResult2>;
|
|
77
|
+
catch: <TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | null | undefined) => Promise<void | TResult>;
|
|
78
|
+
finally: (onfinally?: (() => void) | null | undefined) => Promise<void>;
|
|
79
|
+
readonly [Symbol.toStringTag]: string;
|
|
80
|
+
};
|
|
81
|
+
pendingPlayInfo: {
|
|
82
|
+
sourceUrl: string;
|
|
83
|
+
name: string;
|
|
84
|
+
duration: number;
|
|
85
|
+
currentTime: number;
|
|
86
|
+
invalid: boolean;
|
|
87
|
+
updateTime: number | undefined;
|
|
88
|
+
fromNetdisk: boolean;
|
|
89
|
+
path: string | undefined;
|
|
90
|
+
subtitles: {
|
|
91
|
+
name: string;
|
|
92
|
+
language: string;
|
|
93
|
+
stream_index: number;
|
|
94
|
+
codec_name: string;
|
|
95
|
+
is_external: boolean;
|
|
96
|
+
path: string;
|
|
97
|
+
vtt_url?: string | undefined;
|
|
98
|
+
track_id?: string | undefined;
|
|
99
|
+
ass_url?: string | undefined;
|
|
100
|
+
ass_fonts?: string[] | undefined;
|
|
101
|
+
ass_renderable?: boolean | undefined;
|
|
102
|
+
ass_unavailable_reason?: string | undefined;
|
|
103
|
+
default?: boolean | undefined;
|
|
104
|
+
}[] | undefined;
|
|
105
|
+
beforeHiddenSubtitle?: {
|
|
106
|
+
name: string;
|
|
107
|
+
language: string;
|
|
108
|
+
stream_index: number;
|
|
109
|
+
codec_name: string;
|
|
110
|
+
is_external: boolean;
|
|
111
|
+
path: string;
|
|
112
|
+
vtt_url?: string | undefined;
|
|
113
|
+
track_id?: string | undefined;
|
|
114
|
+
ass_url?: string | undefined;
|
|
115
|
+
ass_fonts?: string[] | undefined;
|
|
116
|
+
ass_renderable?: boolean | undefined;
|
|
117
|
+
ass_unavailable_reason?: string | undefined;
|
|
118
|
+
default?: boolean | undefined;
|
|
119
|
+
} | undefined;
|
|
120
|
+
requestHistory?: boolean | undefined;
|
|
121
|
+
playMode?: "hls" | "direct" | undefined;
|
|
122
|
+
resolvedSourceUrl?: string | undefined;
|
|
123
|
+
originHlsUrl?: string | undefined;
|
|
124
|
+
originDirectUrl?: string | undefined;
|
|
125
|
+
subtitleInfoUrl?: string | undefined;
|
|
126
|
+
_id: string;
|
|
127
|
+
} | null;
|
|
128
|
+
} & import("pinia").PiniaCustomStateProperties<{
|
|
129
|
+
collection: RemoteDB<VideoInfo>;
|
|
130
|
+
infos: VideoInfo[];
|
|
131
|
+
ready: Promise<void>;
|
|
132
|
+
/** 从历史记录点击播放时传入的完整 info,供 Player 优先使用 */
|
|
133
|
+
pendingPlayInfo: VideoInfo | null;
|
|
134
|
+
}>): (sourceUrl: string) => {
|
|
135
|
+
sourceUrl: string;
|
|
136
|
+
name: string;
|
|
137
|
+
duration: number;
|
|
138
|
+
currentTime: number;
|
|
139
|
+
invalid: boolean;
|
|
140
|
+
updateTime: number | undefined;
|
|
141
|
+
fromNetdisk: boolean;
|
|
142
|
+
path: string | undefined;
|
|
143
|
+
subtitles: {
|
|
144
|
+
name: string;
|
|
145
|
+
language: string;
|
|
146
|
+
stream_index: number;
|
|
147
|
+
codec_name: string;
|
|
148
|
+
is_external: boolean;
|
|
149
|
+
path: string;
|
|
150
|
+
vtt_url?: string | undefined;
|
|
151
|
+
track_id?: string | undefined;
|
|
152
|
+
ass_url?: string | undefined;
|
|
153
|
+
ass_fonts?: string[] | undefined;
|
|
154
|
+
ass_renderable?: boolean | undefined;
|
|
155
|
+
ass_unavailable_reason?: string | undefined;
|
|
156
|
+
default?: boolean | undefined;
|
|
157
|
+
}[] | undefined;
|
|
158
|
+
beforeHiddenSubtitle?: {
|
|
159
|
+
name: string;
|
|
160
|
+
language: string;
|
|
161
|
+
stream_index: number;
|
|
162
|
+
codec_name: string;
|
|
163
|
+
is_external: boolean;
|
|
164
|
+
path: string;
|
|
165
|
+
vtt_url?: string | undefined;
|
|
166
|
+
track_id?: string | undefined;
|
|
167
|
+
ass_url?: string | undefined;
|
|
168
|
+
ass_fonts?: string[] | undefined;
|
|
169
|
+
ass_renderable?: boolean | undefined;
|
|
170
|
+
ass_unavailable_reason?: string | undefined;
|
|
171
|
+
default?: boolean | undefined;
|
|
172
|
+
} | undefined;
|
|
173
|
+
requestHistory?: boolean | undefined;
|
|
174
|
+
playMode?: "hls" | "direct" | undefined;
|
|
175
|
+
resolvedSourceUrl?: string | undefined;
|
|
176
|
+
originHlsUrl?: string | undefined;
|
|
177
|
+
originDirectUrl?: string | undefined;
|
|
178
|
+
subtitleInfoUrl?: string | undefined;
|
|
179
|
+
_id: string;
|
|
180
|
+
} | undefined;
|
|
181
|
+
getHistoryInfoByPath(state: {
|
|
182
|
+
collection: {
|
|
183
|
+
find: (selector: Record<string, any>, options?: import("@lazycatcloud/minidb/dist/remoteDB").CollectionFindOptions | undefined) => {
|
|
184
|
+
fetch: () => Promise<VideoInfo[]>;
|
|
185
|
+
};
|
|
186
|
+
findOne: (selector: Record<string, any>, options?: import("@lazycatcloud/minidb/dist/remoteDB").CollectionFindOptions | undefined) => Promise<VideoInfo | null>;
|
|
187
|
+
upsertOrUpdate: (selector: Record<string, any>, doc: VideoInfo, options?: import("@lazycatcloud/minidb/dist/remoteDB").CollectionFindOptions | undefined) => Promise<VideoInfo | null>;
|
|
188
|
+
upsert: {
|
|
189
|
+
(doc: VideoInfo): Promise<VideoInfo | null>;
|
|
190
|
+
(doc: VideoInfo, base: VideoInfo | null | undefined): Promise<VideoInfo | null>;
|
|
191
|
+
(docs: VideoInfo[]): Promise<(VideoInfo | null)[]>;
|
|
192
|
+
(docs: VideoInfo[], bases: (VideoInfo | null | undefined)[]): Promise<(VideoInfo | null)[]>;
|
|
193
|
+
};
|
|
194
|
+
remove: {
|
|
195
|
+
(id: any): Promise<void>;
|
|
196
|
+
(ids: any[]): Promise<void>;
|
|
197
|
+
};
|
|
198
|
+
};
|
|
199
|
+
infos: {
|
|
200
|
+
sourceUrl: string;
|
|
201
|
+
name: string;
|
|
202
|
+
duration: number;
|
|
203
|
+
currentTime: number;
|
|
204
|
+
invalid: boolean;
|
|
205
|
+
updateTime: number | undefined;
|
|
206
|
+
fromNetdisk: boolean;
|
|
207
|
+
path: string | undefined;
|
|
208
|
+
subtitles: {
|
|
209
|
+
name: string;
|
|
210
|
+
language: string;
|
|
211
|
+
stream_index: number;
|
|
212
|
+
codec_name: string;
|
|
213
|
+
is_external: boolean;
|
|
214
|
+
path: string;
|
|
215
|
+
vtt_url?: string | undefined;
|
|
216
|
+
track_id?: string | undefined;
|
|
217
|
+
ass_url?: string | undefined;
|
|
218
|
+
ass_fonts?: string[] | undefined;
|
|
219
|
+
ass_renderable?: boolean | undefined;
|
|
220
|
+
ass_unavailable_reason?: string | undefined;
|
|
221
|
+
default?: boolean | undefined;
|
|
222
|
+
}[] | undefined;
|
|
223
|
+
beforeHiddenSubtitle?: {
|
|
224
|
+
name: string;
|
|
225
|
+
language: string;
|
|
226
|
+
stream_index: number;
|
|
227
|
+
codec_name: string;
|
|
228
|
+
is_external: boolean;
|
|
229
|
+
path: string;
|
|
230
|
+
vtt_url?: string | undefined;
|
|
231
|
+
track_id?: string | undefined;
|
|
232
|
+
ass_url?: string | undefined;
|
|
233
|
+
ass_fonts?: string[] | undefined;
|
|
234
|
+
ass_renderable?: boolean | undefined;
|
|
235
|
+
ass_unavailable_reason?: string | undefined;
|
|
236
|
+
default?: boolean | undefined;
|
|
237
|
+
} | undefined;
|
|
238
|
+
requestHistory?: boolean | undefined;
|
|
239
|
+
playMode?: "hls" | "direct" | undefined;
|
|
240
|
+
resolvedSourceUrl?: string | undefined;
|
|
241
|
+
originHlsUrl?: string | undefined;
|
|
242
|
+
originDirectUrl?: string | undefined;
|
|
243
|
+
subtitleInfoUrl?: string | undefined;
|
|
244
|
+
_id: string;
|
|
245
|
+
}[];
|
|
246
|
+
ready: {
|
|
247
|
+
then: <TResult1 = void, TResult2 = never>(onfulfilled?: ((value: void) => TResult1 | PromiseLike<TResult1>) | null | undefined, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | null | undefined) => Promise<TResult1 | TResult2>;
|
|
248
|
+
catch: <TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | null | undefined) => Promise<void | TResult>;
|
|
249
|
+
finally: (onfinally?: (() => void) | null | undefined) => Promise<void>;
|
|
250
|
+
readonly [Symbol.toStringTag]: string;
|
|
251
|
+
};
|
|
252
|
+
pendingPlayInfo: {
|
|
253
|
+
sourceUrl: string;
|
|
254
|
+
name: string;
|
|
255
|
+
duration: number;
|
|
256
|
+
currentTime: number;
|
|
257
|
+
invalid: boolean;
|
|
258
|
+
updateTime: number | undefined;
|
|
259
|
+
fromNetdisk: boolean;
|
|
260
|
+
path: string | undefined;
|
|
261
|
+
subtitles: {
|
|
262
|
+
name: string;
|
|
263
|
+
language: string;
|
|
264
|
+
stream_index: number;
|
|
265
|
+
codec_name: string;
|
|
266
|
+
is_external: boolean;
|
|
267
|
+
path: string;
|
|
268
|
+
vtt_url?: string | undefined;
|
|
269
|
+
track_id?: string | undefined;
|
|
270
|
+
ass_url?: string | undefined;
|
|
271
|
+
ass_fonts?: string[] | undefined;
|
|
272
|
+
ass_renderable?: boolean | undefined;
|
|
273
|
+
ass_unavailable_reason?: string | undefined;
|
|
274
|
+
default?: boolean | undefined;
|
|
275
|
+
}[] | undefined;
|
|
276
|
+
beforeHiddenSubtitle?: {
|
|
277
|
+
name: string;
|
|
278
|
+
language: string;
|
|
279
|
+
stream_index: number;
|
|
280
|
+
codec_name: string;
|
|
281
|
+
is_external: boolean;
|
|
282
|
+
path: string;
|
|
283
|
+
vtt_url?: string | undefined;
|
|
284
|
+
track_id?: string | undefined;
|
|
285
|
+
ass_url?: string | undefined;
|
|
286
|
+
ass_fonts?: string[] | undefined;
|
|
287
|
+
ass_renderable?: boolean | undefined;
|
|
288
|
+
ass_unavailable_reason?: string | undefined;
|
|
289
|
+
default?: boolean | undefined;
|
|
290
|
+
} | undefined;
|
|
291
|
+
requestHistory?: boolean | undefined;
|
|
292
|
+
playMode?: "hls" | "direct" | undefined;
|
|
293
|
+
resolvedSourceUrl?: string | undefined;
|
|
294
|
+
originHlsUrl?: string | undefined;
|
|
295
|
+
originDirectUrl?: string | undefined;
|
|
296
|
+
subtitleInfoUrl?: string | undefined;
|
|
297
|
+
_id: string;
|
|
298
|
+
} | null;
|
|
299
|
+
} & import("pinia").PiniaCustomStateProperties<{
|
|
300
|
+
collection: RemoteDB<VideoInfo>;
|
|
301
|
+
infos: VideoInfo[];
|
|
302
|
+
ready: Promise<void>;
|
|
303
|
+
/** 从历史记录点击播放时传入的完整 info,供 Player 优先使用 */
|
|
304
|
+
pendingPlayInfo: VideoInfo | null;
|
|
305
|
+
}>): (path: string) => {
|
|
306
|
+
sourceUrl: string;
|
|
307
|
+
name: string;
|
|
308
|
+
duration: number;
|
|
309
|
+
currentTime: number;
|
|
310
|
+
invalid: boolean;
|
|
311
|
+
updateTime: number | undefined;
|
|
312
|
+
fromNetdisk: boolean;
|
|
313
|
+
path: string | undefined;
|
|
314
|
+
subtitles: {
|
|
315
|
+
name: string;
|
|
316
|
+
language: string;
|
|
317
|
+
stream_index: number;
|
|
318
|
+
codec_name: string;
|
|
319
|
+
is_external: boolean;
|
|
320
|
+
path: string;
|
|
321
|
+
vtt_url?: string | undefined;
|
|
322
|
+
track_id?: string | undefined;
|
|
323
|
+
ass_url?: string | undefined;
|
|
324
|
+
ass_fonts?: string[] | undefined;
|
|
325
|
+
ass_renderable?: boolean | undefined;
|
|
326
|
+
ass_unavailable_reason?: string | undefined;
|
|
327
|
+
default?: boolean | undefined;
|
|
328
|
+
}[] | undefined;
|
|
329
|
+
beforeHiddenSubtitle?: {
|
|
330
|
+
name: string;
|
|
331
|
+
language: string;
|
|
332
|
+
stream_index: number;
|
|
333
|
+
codec_name: string;
|
|
334
|
+
is_external: boolean;
|
|
335
|
+
path: string;
|
|
336
|
+
vtt_url?: string | undefined;
|
|
337
|
+
track_id?: string | undefined;
|
|
338
|
+
ass_url?: string | undefined;
|
|
339
|
+
ass_fonts?: string[] | undefined;
|
|
340
|
+
ass_renderable?: boolean | undefined;
|
|
341
|
+
ass_unavailable_reason?: string | undefined;
|
|
342
|
+
default?: boolean | undefined;
|
|
343
|
+
} | undefined;
|
|
344
|
+
requestHistory?: boolean | undefined;
|
|
345
|
+
playMode?: "hls" | "direct" | undefined;
|
|
346
|
+
resolvedSourceUrl?: string | undefined;
|
|
347
|
+
originHlsUrl?: string | undefined;
|
|
348
|
+
originDirectUrl?: string | undefined;
|
|
349
|
+
subtitleInfoUrl?: string | undefined;
|
|
350
|
+
_id: string;
|
|
351
|
+
} | undefined;
|
|
352
|
+
}, {
|
|
353
|
+
init(): Promise<void>;
|
|
354
|
+
refreshData(): Promise<void>;
|
|
355
|
+
deleteHistory(info: VideoInfo): Promise<void>;
|
|
356
|
+
batchDeleteHistory(ids: string[]): Promise<void>;
|
|
357
|
+
updateOrCreateHistory(info: VideoInfo, blobFn: (() => Promise<Blob | null>) | null): Promise<void>;
|
|
358
|
+
markAsInvalid(sourceUrl: string): Promise<void>;
|
|
359
|
+
setPendingPlayInfo(info: VideoInfo | null): void;
|
|
360
|
+
clear(): Promise<void>;
|
|
361
|
+
}>;
|