@flowplayer/player 3.14.1 → 3.15.0-rc.10
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/core/events.d.ts +575 -68
- package/core/events.js +286 -34
- package/core.js +1 -1
- package/default.js +1 -1
- package/embed.js +2 -2
- package/flowplayer.css +1 -1
- package/index.d.ts +1480 -91
- package/package.json +1 -1
- package/plugins/ads.d.ts +3744 -112
- package/plugins/ads.js +1 -1
- package/plugins/airplay.d.ts +1440 -116
- package/plugins/airplay.js +1 -1
- package/plugins/analytics.d.ts +1409 -82
- package/plugins/analytics.js +1 -1
- package/plugins/asel.d.ts +1409 -82
- package/plugins/asel.js +1 -1
- package/plugins/audio.d.ts +1409 -82
- package/plugins/audio.js +1 -1
- package/plugins/chapters.d.ts +1409 -82
- package/plugins/chapters.js +1 -1
- package/plugins/chromecast.d.ts +1464 -80
- package/plugins/chromecast.js +1 -1
- package/plugins/comscore.d.ts +1409 -82
- package/plugins/consent.d.ts +1409 -82
- package/plugins/consent.js +1 -1
- package/plugins/context-menu.d.ts +1443 -116
- package/plugins/cuepoints.d.ts +1443 -116
- package/plugins/cuepoints.js +1 -1
- package/plugins/dash.d.ts +1445 -115
- package/plugins/dash.js +1 -1
- package/plugins/drm.d.ts +1409 -82
- package/plugins/drm.js +1 -1
- package/plugins/endscreen.d.ts +1442 -115
- package/plugins/endscreen.js +1 -1
- package/plugins/fas.d.ts +1409 -82
- package/plugins/float-on-scroll.d.ts +1443 -116
- package/plugins/float-on-scroll.js +1 -1
- package/plugins/ga4.d.ts +1409 -82
- package/plugins/gemius.d.ts +1439 -112
- package/plugins/google-analytics.d.ts +1409 -82
- package/plugins/health.d.ts +1435 -107
- package/plugins/health.js +1 -1
- package/plugins/hls.d.ts +1431 -104
- package/plugins/hls.js +1 -1
- package/plugins/id3.d.ts +1409 -82
- package/plugins/id3.js +1 -1
- package/plugins/iframe.d.ts +1440 -116
- package/plugins/iframe.js +1 -1
- package/plugins/keyboard.d.ts +1409 -82
- package/plugins/media-session.d.ts +1409 -82
- package/plugins/message.d.ts +1409 -82
- package/plugins/message.js +1 -1
- package/plugins/ovp.d.ts +1435 -110
- package/plugins/ovp.js +1 -1
- package/plugins/playlist.d.ts +1409 -82
- package/plugins/playlist.js +1 -1
- package/plugins/preview.d.ts +1409 -82
- package/plugins/preview.js +1 -1
- package/plugins/qsel.d.ts +1409 -82
- package/plugins/qsel.js +1 -1
- package/plugins/qul.d.ts +1441 -114
- package/plugins/qul.js +1 -1
- package/plugins/rts.d.ts +1409 -82
- package/plugins/rts.js +1 -1
- package/plugins/share.d.ts +1409 -82
- package/plugins/share.js +1 -1
- package/plugins/speed.d.ts +1434 -107
- package/plugins/speed.js +1 -1
- package/plugins/ssai.d.ts +1412 -82
- package/plugins/ssai.js +1 -1
- package/plugins/subtitles.d.ts +1426 -102
- package/plugins/thumbnails.d.ts +1434 -107
- package/plugins/thumbnails.js +1 -1
- package/plugins/tizen.d.ts +1409 -82
- package/plugins/tizen.js +1 -1
- package/plugins/vtsel.d.ts +1409 -82
- package/plugins/vtsel.js +1 -1
- package/plugins/webos.d.ts +1409 -82
- package/plugins/webos.js +1 -1
- package/util/loader.d.ts +1436 -101
- package/util/loader.js +13 -2
package/plugins/ovp.d.ts
CHANGED
|
@@ -1,10 +1,31 @@
|
|
|
1
|
+
/// <reference types="node" />
|
|
2
|
+
|
|
3
|
+
import type { BitrateInfo } from 'dashjs';
|
|
1
4
|
import type { MediaKeyFunc } from 'hls.js';
|
|
2
5
|
|
|
6
|
+
/* Excluded from this release type: AnyLoader */
|
|
7
|
+
|
|
3
8
|
declare type ArrayToIntersection<T extends Array<unknown>> = T extends [
|
|
4
9
|
infer Current,
|
|
5
10
|
...infer Remaining
|
|
6
11
|
] ? Current & ArrayToIntersection<Remaining> : unknown;
|
|
7
12
|
|
|
13
|
+
/**
|
|
14
|
+
* Each loader must
|
|
15
|
+
*/
|
|
16
|
+
declare type _AttachedEventCheck = {
|
|
17
|
+
on(event: `${string}:attached`, handler: (e: FPEvent<unknown>) => void): Player;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
/* Excluded from this release type: AUDIO_ONLY_SOURCE */
|
|
21
|
+
|
|
22
|
+
/* Excluded from this release type: AudioOnlySourceEventDetail */
|
|
23
|
+
|
|
24
|
+
declare const AUTOPLAY = "is-autoplay";
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* @public
|
|
28
|
+
*/
|
|
8
29
|
declare type Autoplay = BitOpts | boolean;
|
|
9
30
|
|
|
10
31
|
declare enum AutoplayOpts {
|
|
@@ -13,19 +34,60 @@ declare enum AutoplayOpts {
|
|
|
13
34
|
AUDIO_REQUIRED = 2
|
|
14
35
|
}
|
|
15
36
|
|
|
16
|
-
|
|
37
|
+
/* Excluded from this release type: BEFORE_PAUSE */
|
|
38
|
+
|
|
39
|
+
/* Excluded from this release type: BEFORE_PLAY */
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* @public
|
|
43
|
+
*/
|
|
44
|
+
declare type BeforePauseEventDetail = {
|
|
45
|
+
forced: boolean;
|
|
46
|
+
};
|
|
17
47
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
48
|
+
/**
|
|
49
|
+
* @public
|
|
50
|
+
*/
|
|
51
|
+
declare type BeforePlayEventDetail = {
|
|
52
|
+
forced: boolean;
|
|
21
53
|
};
|
|
22
54
|
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
55
|
+
/**
|
|
56
|
+
* @public
|
|
57
|
+
*/
|
|
58
|
+
declare type BitOpts = number;
|
|
59
|
+
|
|
60
|
+
/**
|
|
61
|
+
* @public
|
|
62
|
+
*/
|
|
63
|
+
declare const /**
|
|
64
|
+
@public
|
|
65
|
+
* when a new player is inserted into the HTML
|
|
66
|
+
*/ /**
|
|
67
|
+
* @public
|
|
68
|
+
*/
|
|
69
|
+
CAN_PLAY = "canplay";
|
|
70
|
+
|
|
71
|
+
/**
|
|
72
|
+
* @public
|
|
73
|
+
*/
|
|
74
|
+
declare const /**
|
|
75
|
+
@public
|
|
76
|
+
* when a new player is inserted into the HTML
|
|
77
|
+
*/ /**
|
|
78
|
+
* @public
|
|
79
|
+
*/
|
|
80
|
+
CLICK = "click";
|
|
81
|
+
|
|
82
|
+
/* Excluded from this release type: Component */
|
|
28
83
|
|
|
84
|
+
/* Excluded from this release type: Components */
|
|
85
|
+
|
|
86
|
+
/* Excluded from this release type: CONFIG */
|
|
87
|
+
|
|
88
|
+
/**
|
|
89
|
+
* @public
|
|
90
|
+
*/
|
|
29
91
|
declare interface Config {
|
|
30
92
|
src?: UnsafeSource;
|
|
31
93
|
preload?: "none" | "metadata" | "auto";
|
|
@@ -35,7 +97,7 @@ declare interface Config {
|
|
|
35
97
|
autopause?: boolean;
|
|
36
98
|
rewind?: boolean;
|
|
37
99
|
loop?: boolean;
|
|
38
|
-
seamless
|
|
100
|
+
/* Excluded from this release type: seamless */
|
|
39
101
|
retry?: boolean;
|
|
40
102
|
autoplay?: Autoplay;
|
|
41
103
|
start_quality?: BitOpts;
|
|
@@ -43,10 +105,7 @@ declare interface Config {
|
|
|
43
105
|
poster?: string;
|
|
44
106
|
disabled?: boolean;
|
|
45
107
|
muted?: boolean;
|
|
46
|
-
|
|
47
|
-
* is src handled by one of plugins loaders
|
|
48
|
-
*/
|
|
49
|
-
is_native?: boolean;
|
|
108
|
+
/* Excluded from this release type: is_native */
|
|
50
109
|
/**
|
|
51
110
|
* bitflags for UI options
|
|
52
111
|
*/
|
|
@@ -55,10 +114,7 @@ declare interface Config {
|
|
|
55
114
|
* your user access token
|
|
56
115
|
*/
|
|
57
116
|
token?: string;
|
|
58
|
-
|
|
59
|
-
* manually configured duration for pre-rendering usually
|
|
60
|
-
*/
|
|
61
|
-
duration?: number;
|
|
117
|
+
/* Excluded from this release type: duration */
|
|
62
118
|
/**
|
|
63
119
|
* can the content be seeked to any position
|
|
64
120
|
*/
|
|
@@ -76,12 +132,120 @@ declare interface Config {
|
|
|
76
132
|
seconds_to_dvr?: number;
|
|
77
133
|
}
|
|
78
134
|
|
|
135
|
+
/* Excluded from this release type: ConfigEventDetail */
|
|
136
|
+
|
|
137
|
+
/**
|
|
138
|
+
* @public
|
|
139
|
+
*/
|
|
79
140
|
declare type ConfigWith<T> = Config & T;
|
|
80
141
|
|
|
81
|
-
|
|
142
|
+
/* Excluded from this release type: CONTENT_REAL_LOAD_START */
|
|
143
|
+
|
|
144
|
+
/**
|
|
145
|
+
* @public
|
|
146
|
+
*/
|
|
147
|
+
declare const /**
|
|
148
|
+
@public
|
|
149
|
+
* when a new player is inserted into the HTML
|
|
150
|
+
*/ /**
|
|
151
|
+
* @public
|
|
152
|
+
*/
|
|
153
|
+
CONTEXT_MENU = "contextmenu";
|
|
154
|
+
|
|
155
|
+
/**
|
|
156
|
+
* @public
|
|
157
|
+
*/
|
|
158
|
+
declare type ContextMenuEventDetail = null;
|
|
159
|
+
|
|
160
|
+
/**
|
|
161
|
+
* @public
|
|
162
|
+
* when a cuepoint becomes inactive
|
|
163
|
+
*/
|
|
164
|
+
declare const /**
|
|
165
|
+
@public
|
|
166
|
+
* when a new player is inserted into the HTML
|
|
167
|
+
*/ /**
|
|
168
|
+
* @public
|
|
169
|
+
* when a cuepoint becomes inactive
|
|
170
|
+
*/
|
|
171
|
+
CUEPOINT_END = "cuepointend";
|
|
172
|
+
|
|
173
|
+
/**
|
|
174
|
+
* @public
|
|
175
|
+
* when a cuepoint is active
|
|
176
|
+
*/
|
|
177
|
+
declare const /**
|
|
178
|
+
@public
|
|
179
|
+
* when a new player is inserted into the HTML
|
|
180
|
+
*/ /**
|
|
181
|
+
* @public
|
|
182
|
+
* when a cuepoint is active
|
|
183
|
+
*/
|
|
184
|
+
CUEPOINT_START = "cuepointstart";
|
|
185
|
+
|
|
186
|
+
/**
|
|
187
|
+
* @public
|
|
188
|
+
*/
|
|
189
|
+
declare type CuePointEndEventDetail = null;
|
|
190
|
+
|
|
191
|
+
/**
|
|
192
|
+
* @public
|
|
193
|
+
* cuepoints parsing is asynchronous
|
|
194
|
+
* you cannot rely on them existing until
|
|
195
|
+
* this event is emitted
|
|
196
|
+
*/
|
|
197
|
+
declare const /**
|
|
198
|
+
@public
|
|
199
|
+
* when a new player is inserted into the HTML
|
|
200
|
+
*/ /**
|
|
201
|
+
* @public
|
|
202
|
+
* cuepoints parsing is asynchronous
|
|
203
|
+
* you cannot rely on them existing until
|
|
204
|
+
* this event is emitted
|
|
205
|
+
*/
|
|
206
|
+
CUEPOINTS = "cuepoints";
|
|
207
|
+
|
|
208
|
+
/**
|
|
209
|
+
* @public
|
|
210
|
+
*/
|
|
211
|
+
declare type CuePointStartEventDetail = null;
|
|
212
|
+
|
|
213
|
+
/**
|
|
214
|
+
* @public
|
|
215
|
+
*/
|
|
216
|
+
declare const /**
|
|
217
|
+
@public
|
|
218
|
+
* when a new player is inserted into the HTML
|
|
219
|
+
*/ /**
|
|
220
|
+
* @public
|
|
221
|
+
*/
|
|
222
|
+
DATA = "loadeddata";
|
|
223
|
+
|
|
224
|
+
/**
|
|
225
|
+
* @public
|
|
226
|
+
*/
|
|
227
|
+
declare const /**
|
|
228
|
+
@public
|
|
229
|
+
* when a new player is inserted into the HTML
|
|
230
|
+
*/ /**
|
|
231
|
+
* @public
|
|
232
|
+
*/
|
|
233
|
+
DBL_CLICK = "dblclick";
|
|
234
|
+
|
|
235
|
+
declare const DESTROYED = "is-destroyed";
|
|
236
|
+
|
|
237
|
+
/* Excluded from this release type: DeviceId */
|
|
82
238
|
|
|
239
|
+
declare const DISABLED = "is-disabled";
|
|
240
|
+
|
|
241
|
+
/**
|
|
242
|
+
* @public
|
|
243
|
+
*/
|
|
83
244
|
declare type DRM_KEYSYSTEM = "com.widevine.alpha" | "com.microsoft.playready" | "org.w3.clearkey" | "com.apple.fps.1_0";
|
|
84
245
|
|
|
246
|
+
/**
|
|
247
|
+
* @public
|
|
248
|
+
*/
|
|
85
249
|
declare type DRMConfiguration = {
|
|
86
250
|
license_server: string;
|
|
87
251
|
http_headers?: Record<string, string>;
|
|
@@ -91,10 +255,16 @@ declare type DRMConfiguration = {
|
|
|
91
255
|
query_params?: Record<string, string>;
|
|
92
256
|
};
|
|
93
257
|
|
|
258
|
+
/**
|
|
259
|
+
* @public
|
|
260
|
+
*/
|
|
94
261
|
declare type DRMSourceConfiguration = {
|
|
95
262
|
[keysystem in DRM_KEYSYSTEM]?: DRMConfiguration;
|
|
96
263
|
};
|
|
97
264
|
|
|
265
|
+
/**
|
|
266
|
+
* @public
|
|
267
|
+
*/
|
|
98
268
|
declare type DRMVendorImplementation = {
|
|
99
269
|
fairplay_fetch_certificate: (url: string, cb: (certificate_data: Uint8Array) => void) => void;
|
|
100
270
|
fairplay_request_license: (url: string, params: {
|
|
@@ -103,6 +273,48 @@ declare type DRMVendorImplementation = {
|
|
|
103
273
|
}, cb: (license_data: Uint8Array) => void) => void;
|
|
104
274
|
};
|
|
105
275
|
|
|
276
|
+
/**
|
|
277
|
+
* @public
|
|
278
|
+
*/
|
|
279
|
+
declare const /**
|
|
280
|
+
@public
|
|
281
|
+
* when a new player is inserted into the HTML
|
|
282
|
+
*/ /**
|
|
283
|
+
* @public
|
|
284
|
+
*/
|
|
285
|
+
DURATION_CHANGE = "durationchange";
|
|
286
|
+
|
|
287
|
+
/**
|
|
288
|
+
* @public
|
|
289
|
+
* when the player has started playing dvr content
|
|
290
|
+
*/
|
|
291
|
+
declare const /**
|
|
292
|
+
@public
|
|
293
|
+
* when a new player is inserted into the HTML
|
|
294
|
+
*/ /**
|
|
295
|
+
* @public
|
|
296
|
+
* when the player has started playing dvr content
|
|
297
|
+
*/
|
|
298
|
+
DVR = "dvr";
|
|
299
|
+
|
|
300
|
+
/**
|
|
301
|
+
* @public
|
|
302
|
+
*/
|
|
303
|
+
declare type DvrEventDetail = number;
|
|
304
|
+
|
|
305
|
+
declare const ENDED = "is-ended";
|
|
306
|
+
|
|
307
|
+
/**
|
|
308
|
+
* @public
|
|
309
|
+
*/
|
|
310
|
+
declare const /**
|
|
311
|
+
@public
|
|
312
|
+
* when a new player is inserted into the HTML
|
|
313
|
+
*/ /**
|
|
314
|
+
* @public
|
|
315
|
+
*/
|
|
316
|
+
ENDED_2 = "ended";
|
|
317
|
+
|
|
106
318
|
declare type EndscreenEvents = typeof events;
|
|
107
319
|
|
|
108
320
|
/**
|
|
@@ -112,49 +324,195 @@ declare type EndscreenRecommendations = {
|
|
|
112
324
|
playlist: Array<PlaylistItem>;
|
|
113
325
|
};
|
|
114
326
|
|
|
327
|
+
declare type EnsureOnAttached<P extends Function, T extends Player> = ExtractPureAPI<T> extends _AttachedEventCheck ? P : "Loaders must implement on('<pluginname>:attached') event";
|
|
328
|
+
|
|
329
|
+
/**
|
|
330
|
+
* @public
|
|
331
|
+
*/
|
|
332
|
+
declare const /**
|
|
333
|
+
@public
|
|
334
|
+
* when a new player is inserted into the HTML
|
|
335
|
+
*/ /**
|
|
336
|
+
* @public
|
|
337
|
+
*/
|
|
338
|
+
ERROR = "error";
|
|
339
|
+
|
|
340
|
+
declare const ERRORED = "is-error";
|
|
341
|
+
|
|
342
|
+
/**
|
|
343
|
+
* @public
|
|
344
|
+
*/
|
|
345
|
+
declare type ErrorEventDetail = {
|
|
346
|
+
src?: string;
|
|
347
|
+
type?: string;
|
|
348
|
+
code?: number | string;
|
|
349
|
+
};
|
|
350
|
+
|
|
351
|
+
/* Excluded from this release type: _ErrorEventDetail */
|
|
352
|
+
|
|
115
353
|
declare namespace events {
|
|
116
354
|
export {
|
|
117
355
|
RECOMMENDATIONS_RENDER,
|
|
118
356
|
RECOMMENDATIONS_HIDE,
|
|
119
|
-
RECOMMENDATIONS_READY
|
|
357
|
+
RECOMMENDATIONS_READY_2 as RECOMMENDATIONS_READY
|
|
358
|
+
}
|
|
359
|
+
}
|
|
360
|
+
|
|
361
|
+
declare namespace events_2 {
|
|
362
|
+
export {
|
|
363
|
+
MOUNT,
|
|
364
|
+
ERROR,
|
|
365
|
+
CONTEXT_MENU,
|
|
366
|
+
CLICK,
|
|
367
|
+
DBL_CLICK,
|
|
368
|
+
KEYUP,
|
|
369
|
+
KEYDOWN,
|
|
370
|
+
LOAD,
|
|
371
|
+
MOUSE_ENTER,
|
|
372
|
+
MOUSE_LEAVE,
|
|
373
|
+
MOUSE_UP,
|
|
374
|
+
MOUSE_DOWN,
|
|
375
|
+
MOUSE_MOVE,
|
|
376
|
+
TOUCH_START,
|
|
377
|
+
TOUCH_MOVE,
|
|
378
|
+
TOUCH_END,
|
|
379
|
+
TOUCH_CANCEL,
|
|
380
|
+
RESIZE,
|
|
381
|
+
SCROLL,
|
|
382
|
+
FULLSCREEN_ENTER,
|
|
383
|
+
FULLSCREEN_EXIT,
|
|
384
|
+
FULLSCREEN_CHANGE,
|
|
385
|
+
METADATA,
|
|
386
|
+
DATA,
|
|
387
|
+
PROGRESS,
|
|
388
|
+
TIME_UPDATE,
|
|
389
|
+
LOAD_START,
|
|
390
|
+
VOLUME_CHANGE,
|
|
391
|
+
PAUSE,
|
|
392
|
+
PLAYING_2 as PLAYING,
|
|
393
|
+
PLAY,
|
|
394
|
+
WAITING_2 as WAITING,
|
|
395
|
+
CAN_PLAY,
|
|
396
|
+
ENDED_2 as ENDED,
|
|
397
|
+
SEEKED,
|
|
398
|
+
SEEKING_2 as SEEKING,
|
|
399
|
+
DURATION_CHANGE,
|
|
400
|
+
CUEPOINTS,
|
|
401
|
+
CUEPOINT_START,
|
|
402
|
+
CUEPOINT_END,
|
|
403
|
+
VIEW_ENTER,
|
|
404
|
+
VIEW_LEAVE,
|
|
405
|
+
SOURCE,
|
|
406
|
+
REAP,
|
|
407
|
+
QUALITIES,
|
|
408
|
+
VIDEO_TRACKS,
|
|
409
|
+
SET_QUALITY,
|
|
410
|
+
VIDEO_TRACK_SELECT,
|
|
411
|
+
RECOMMENDATIONS_READY,
|
|
412
|
+
LANDSCAPE,
|
|
413
|
+
PORTRAIT,
|
|
414
|
+
DVR,
|
|
415
|
+
LIVE_2 as LIVE
|
|
120
416
|
}
|
|
121
417
|
}
|
|
122
418
|
|
|
419
|
+
declare type ExtractPureAPI<T> = T extends PlayerWith<infer PureAPI> ? PureAPI : never;
|
|
420
|
+
|
|
421
|
+
/**
|
|
422
|
+
* @public
|
|
423
|
+
*/
|
|
123
424
|
declare type FlowplayerCustomElementRegistry = Map<string, string>;
|
|
124
425
|
|
|
426
|
+
/**
|
|
427
|
+
* @public
|
|
428
|
+
*/
|
|
429
|
+
declare type FlowplayerStates = typeof states;
|
|
430
|
+
|
|
431
|
+
/**
|
|
432
|
+
* @public
|
|
433
|
+
*/
|
|
125
434
|
declare interface FlowplayerUMD extends FlowplayerUMDBase {
|
|
435
|
+
/**
|
|
436
|
+
* Configure flowplayer and display it in the UI
|
|
437
|
+
* @param selector - query selector of the HTML element where player will render
|
|
438
|
+
* @param config - configuration of flowplayer
|
|
439
|
+
*/
|
|
126
440
|
(selector: string, config?: Config): Player;
|
|
441
|
+
/**
|
|
442
|
+
* Configure flowplayer and display it in the UI
|
|
443
|
+
* @param element - HTML element where player will render
|
|
444
|
+
* @param config - configuration of flowplayer
|
|
445
|
+
*/
|
|
127
446
|
(element: HTMLElement, config?: Config): Player;
|
|
447
|
+
/**
|
|
448
|
+
* Configure flowplayer and display it in the UI
|
|
449
|
+
* @param selector - query selector of the HTML element where player will render
|
|
450
|
+
* @param config - configuration of flowplayer
|
|
451
|
+
*/
|
|
128
452
|
<T>(selector: string, config?: ConfigWith<T>): Player;
|
|
453
|
+
/**
|
|
454
|
+
* Configure flowplayer and display it in the UI
|
|
455
|
+
* @param element - HTML element where player will render
|
|
456
|
+
* @param config - configuration of flowplayer
|
|
457
|
+
*/
|
|
129
458
|
<T>(element: HTMLElement, config?: ConfigWith<T>): Player;
|
|
459
|
+
/**
|
|
460
|
+
* Register plugins in flowplayer
|
|
461
|
+
* @returns flowplayer instance with registered plugins
|
|
462
|
+
*/
|
|
130
463
|
<PluginCtors extends PluginCtor[]>(...plugins: PluginCtors): FlowplayerUMDWithPlugins<ConfigWith<MergeConfigs<PluginCtors>>, PlayerWith<MergePlayerAPIExtensions<PluginCtors>>>;
|
|
131
464
|
}
|
|
132
465
|
|
|
133
466
|
declare interface FlowplayerUMDBase {
|
|
467
|
+
/**
|
|
468
|
+
* All player instances on the page
|
|
469
|
+
*/
|
|
134
470
|
instances: Player[];
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
471
|
+
/**
|
|
472
|
+
* Flowplayer core events
|
|
473
|
+
*/
|
|
474
|
+
events: typeof events_2;
|
|
475
|
+
/**
|
|
476
|
+
* Flowplayer ui states map
|
|
477
|
+
*/
|
|
478
|
+
states: FlowplayerStates;
|
|
141
479
|
quality: typeof QualityOpts;
|
|
480
|
+
autoplay: typeof AutoplayOpts;
|
|
142
481
|
commit: string;
|
|
143
482
|
version: string;
|
|
483
|
+
/**
|
|
484
|
+
* Flowplayer's custom element registry
|
|
485
|
+
*/
|
|
144
486
|
customElements: FlowplayerCustomElementRegistry;
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
487
|
+
/* Excluded from this release type: extensions */
|
|
488
|
+
/* Excluded from this release type: defaultElements */
|
|
489
|
+
/* Excluded from this release type: components */
|
|
490
|
+
/* Excluded from this release type: support */
|
|
491
|
+
/* Excluded from this release type: jwt */
|
|
492
|
+
/* Excluded from this release type: loaders */
|
|
151
493
|
}
|
|
152
494
|
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
495
|
+
/**
|
|
496
|
+
* @public
|
|
497
|
+
*/
|
|
498
|
+
declare interface FlowplayerUMDWithPlugins<ConfigWithPlugins extends Config = Config, PluginPlayer extends Player = Player> extends FlowplayerUMDBase {
|
|
499
|
+
/**
|
|
500
|
+
* Configure flowplayer, it's attached plugins and display flowplayer it in the UI
|
|
501
|
+
* @param selector - query selector of the HTML element where player will render
|
|
502
|
+
* @param config - Configuration of the flowplayer and the attached plugins
|
|
503
|
+
*/
|
|
504
|
+
(selector: string, config?: ConfigWithPlugins): PluginPlayer;
|
|
505
|
+
/**
|
|
506
|
+
* Configure flowplayer, it's attached plugins and display flowplayer it in the UI
|
|
507
|
+
* @param element - HTML element where player will render
|
|
508
|
+
* @param config - Configuration of the flowplayer and the attached plugins
|
|
509
|
+
*/
|
|
510
|
+
(element: HTMLElement, config?: ConfigWithPlugins): PluginPlayer;
|
|
156
511
|
}
|
|
157
512
|
|
|
513
|
+
/**
|
|
514
|
+
* @public
|
|
515
|
+
*/
|
|
158
516
|
declare interface FPEvent<T> extends CustomEvent<T> {
|
|
159
517
|
/**
|
|
160
518
|
* @deprecated
|
|
@@ -164,106 +522,600 @@ declare interface FPEvent<T> extends CustomEvent<T> {
|
|
|
164
522
|
data?: T;
|
|
165
523
|
}
|
|
166
524
|
|
|
167
|
-
declare
|
|
525
|
+
declare const FULLSCREEN = "is-fullscreen";
|
|
168
526
|
|
|
169
|
-
|
|
527
|
+
/**
|
|
528
|
+
* @public
|
|
529
|
+
*/
|
|
530
|
+
declare const /**
|
|
531
|
+
@public
|
|
532
|
+
* when a new player is inserted into the HTML
|
|
533
|
+
*/ /**
|
|
534
|
+
* @public
|
|
535
|
+
*/
|
|
536
|
+
FULLSCREEN_CHANGE = "fullscreenchange";
|
|
170
537
|
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
538
|
+
/**
|
|
539
|
+
* @public
|
|
540
|
+
*/
|
|
541
|
+
declare const /**
|
|
542
|
+
@public
|
|
543
|
+
* when a new player is inserted into the HTML
|
|
544
|
+
*/ /**
|
|
545
|
+
* @public
|
|
546
|
+
*/
|
|
547
|
+
FULLSCREEN_ENTER = "fullscreenenter";
|
|
176
548
|
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
549
|
+
/**
|
|
550
|
+
* @public
|
|
551
|
+
*/
|
|
552
|
+
declare const /**
|
|
553
|
+
@public
|
|
554
|
+
* when a new player is inserted into the HTML
|
|
555
|
+
*/ /**
|
|
556
|
+
* @public
|
|
557
|
+
*/
|
|
558
|
+
FULLSCREEN_EXIT = "fullscreenexit";
|
|
180
559
|
|
|
181
|
-
declare
|
|
182
|
-
[PluginType in keyof Arr]: Arr[PluginType] extends PluginCtor<infer _uConfigType, infer PlayerAPIExtension> ? PlayerAPIExtension : never;
|
|
183
|
-
};
|
|
560
|
+
declare const GRABBING = "is-grabbing";
|
|
184
561
|
|
|
185
|
-
declare
|
|
562
|
+
declare const HAS_POSTER = "has-poster";
|
|
186
563
|
|
|
187
|
-
declare
|
|
564
|
+
declare const HOVERED = "is-hovered";
|
|
565
|
+
|
|
566
|
+
declare const IN_VIEWPORT = "is-in-viewport";
|
|
567
|
+
|
|
568
|
+
/* Excluded from this release type: INTERSECTIONCHANGE */
|
|
569
|
+
|
|
570
|
+
/* Excluded from this release type: IntersectionChangeEventDetail */
|
|
571
|
+
|
|
572
|
+
declare const IS_SOURCE_PROCESSING = "is-source-processing";
|
|
573
|
+
|
|
574
|
+
declare type JSONPlayer = any;
|
|
188
575
|
|
|
189
576
|
/**
|
|
190
577
|
* @public
|
|
191
|
-
* OVP plugin
|
|
192
578
|
*/
|
|
193
|
-
declare const
|
|
194
|
-
|
|
579
|
+
declare const /**
|
|
580
|
+
@public
|
|
581
|
+
* when a new player is inserted into the HTML
|
|
582
|
+
*/ /**
|
|
583
|
+
* @public
|
|
584
|
+
*/
|
|
585
|
+
KEYDOWN = "keydown";
|
|
195
586
|
|
|
196
587
|
/**
|
|
197
588
|
* @public
|
|
198
|
-
* OVPConfig for npm users to configure the plugin
|
|
199
589
|
*/
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
590
|
+
declare const /**
|
|
591
|
+
@public
|
|
592
|
+
* when a new player is inserted into the HTML
|
|
593
|
+
*/ /**
|
|
594
|
+
* @public
|
|
595
|
+
*/
|
|
596
|
+
KEYUP = "keyup";
|
|
203
597
|
|
|
204
598
|
/**
|
|
205
599
|
* @public
|
|
206
600
|
*/
|
|
207
|
-
|
|
208
|
-
on(event: EndscreenEvents["RECOMMENDATIONS_READY"], handler: (e: RecommendationsReadyEvent) => void): Player;
|
|
209
|
-
};
|
|
601
|
+
declare type KeyValue = Record<string, any>;
|
|
210
602
|
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
603
|
+
/**
|
|
604
|
+
* @public
|
|
605
|
+
*/
|
|
606
|
+
declare const /**
|
|
607
|
+
@public
|
|
608
|
+
* when a new player is inserted into the HTML
|
|
609
|
+
*/ /**
|
|
610
|
+
* @public
|
|
611
|
+
*/
|
|
612
|
+
LANDSCAPE = "landscape";
|
|
613
|
+
|
|
614
|
+
declare const LIVE = "is-live";
|
|
615
|
+
|
|
616
|
+
/**
|
|
617
|
+
* @public
|
|
618
|
+
* when src is a livestream
|
|
619
|
+
*/
|
|
620
|
+
declare const /**
|
|
621
|
+
@public
|
|
622
|
+
* when a new player is inserted into the HTML
|
|
623
|
+
*/ /**
|
|
624
|
+
* @public
|
|
625
|
+
* when src is a livestream
|
|
626
|
+
*/
|
|
627
|
+
LIVE_2 = "live";
|
|
628
|
+
|
|
629
|
+
declare const LIVE_SEEKED = "is-live-seeked";
|
|
630
|
+
|
|
631
|
+
/**
|
|
632
|
+
* @public
|
|
633
|
+
*/
|
|
634
|
+
declare type LiveEventDetail = null;
|
|
635
|
+
|
|
636
|
+
/**
|
|
637
|
+
* @public
|
|
638
|
+
*/
|
|
639
|
+
declare const /**
|
|
640
|
+
@public
|
|
641
|
+
* when a new player is inserted into the HTML
|
|
642
|
+
*/ /**
|
|
643
|
+
* @public
|
|
644
|
+
*/
|
|
645
|
+
LOAD = "load";
|
|
646
|
+
|
|
647
|
+
/**
|
|
648
|
+
* @public
|
|
649
|
+
*/
|
|
650
|
+
declare const /**
|
|
651
|
+
@public
|
|
652
|
+
* when a new player is inserted into the HTML
|
|
653
|
+
*/ /**
|
|
654
|
+
* @public
|
|
655
|
+
*/
|
|
656
|
+
LOAD_START = "loadstart";
|
|
657
|
+
|
|
658
|
+
declare const LOADED = "is-loaded";
|
|
659
|
+
|
|
660
|
+
/**
|
|
661
|
+
* @public A plugin that supports loading new media formats. Use 'class MyPlugin implements Loader\<...\>' when writing your custom Loader
|
|
662
|
+
* @typeParam PluginPlayer- Player API that will be implemented by the loader. Loader at least must implement on(\<loader-name\>:attached, ...) event handler
|
|
663
|
+
*/
|
|
664
|
+
declare interface Loader<PluginOwnConfig extends KeyValue, // FIXME extends Config
|
|
665
|
+
PluginPlayer extends PlayerWith<_AttachedEventCheck>> extends Plugin_2<PluginOwnConfig, PluginPlayer> {
|
|
666
|
+
onload: EnsureOnAttached<(config: ConfigWith<PluginOwnConfig>, root: PlayerRoot, video: PlayerWith<PluginPlayer>, src: SourceObj) => void, PluginPlayer>;
|
|
667
|
+
wants<S = SourceObj>(srcString: SourceStr, srcObj: S, config: ConfigWith<PluginOwnConfig>): boolean;
|
|
668
|
+
wants<S = KeyValue>(srcString: SourceStr, srcObj: SourceWith<S>, config: ConfigWith<PluginOwnConfig>): boolean;
|
|
669
|
+
}
|
|
670
|
+
|
|
671
|
+
declare const LOADING = "is-loading";
|
|
672
|
+
|
|
673
|
+
declare type MapToConfigs<Arr extends PluginCtor[]> = {
|
|
674
|
+
[PluginType in keyof Arr]: Arr[PluginType] extends PluginCtor<ConfigWith<infer ConfigType>> ? ConfigType : never;
|
|
675
|
+
};
|
|
676
|
+
|
|
677
|
+
declare type MapToPlayerApiExtensions<Arr extends PluginCtor[]> = {
|
|
678
|
+
[PluginType in keyof Arr]: Arr[PluginType] extends PluginCtor<infer _uConfigType, PlayerWith<infer PlayerAPIExtension>> ? PlayerAPIExtension : never;
|
|
679
|
+
};
|
|
680
|
+
|
|
681
|
+
declare const MENU_OPENED = "has-menu-opened";
|
|
682
|
+
|
|
683
|
+
declare type MergeConfigs<Arr extends PluginCtor[]> = ArrayToIntersection<MapToConfigs<Arr>>;
|
|
684
|
+
|
|
685
|
+
declare type MergePlayerAPIExtensions<Arr extends PluginCtor[]> = ArrayToIntersection<MapToPlayerApiExtensions<Arr>>;
|
|
686
|
+
|
|
687
|
+
/**
|
|
688
|
+
* @public
|
|
689
|
+
* general video events flowplayer uses internally
|
|
690
|
+
* https://developer.mozilla.org/en-US/docs/Web/Guide/Events/Media_events
|
|
691
|
+
*/
|
|
692
|
+
declare const /**
|
|
693
|
+
@public
|
|
694
|
+
* when a new player is inserted into the HTML
|
|
695
|
+
*/ /**
|
|
696
|
+
* @public
|
|
697
|
+
* general video events flowplayer uses internally
|
|
698
|
+
* https://developer.mozilla.org/en-US/docs/Web/Guide/Events/Media_events
|
|
699
|
+
*/
|
|
700
|
+
METADATA = "loadedmetadata";
|
|
701
|
+
|
|
702
|
+
/**
|
|
703
|
+
@public
|
|
704
|
+
* when a new player is inserted into the HTML
|
|
705
|
+
*/
|
|
706
|
+
declare const /**
|
|
707
|
+
@public
|
|
708
|
+
* when a new player is inserted into the HTML
|
|
709
|
+
*/ /**
|
|
710
|
+
@public
|
|
711
|
+
* when a new player is inserted into the HTML
|
|
712
|
+
*/ MOUNT = "mount";
|
|
713
|
+
|
|
714
|
+
/**
|
|
715
|
+
* @public
|
|
716
|
+
*/
|
|
717
|
+
declare type MountEventDetail = null;
|
|
718
|
+
|
|
719
|
+
/**
|
|
720
|
+
* @public
|
|
721
|
+
*/
|
|
722
|
+
declare const /**
|
|
723
|
+
@public
|
|
724
|
+
* when a new player is inserted into the HTML
|
|
725
|
+
*/ /**
|
|
726
|
+
* @public
|
|
727
|
+
*/
|
|
728
|
+
MOUSE_DOWN = "mousedown";
|
|
729
|
+
|
|
730
|
+
/**
|
|
731
|
+
* @public
|
|
732
|
+
*/
|
|
733
|
+
declare const /**
|
|
734
|
+
@public
|
|
735
|
+
* when a new player is inserted into the HTML
|
|
736
|
+
*/ /**
|
|
737
|
+
* @public
|
|
738
|
+
*/
|
|
739
|
+
MOUSE_ENTER = "mouseenter";
|
|
740
|
+
|
|
741
|
+
/**
|
|
742
|
+
* @public
|
|
743
|
+
*/
|
|
744
|
+
declare const /**
|
|
745
|
+
@public
|
|
746
|
+
* when a new player is inserted into the HTML
|
|
747
|
+
*/ /**
|
|
748
|
+
* @public
|
|
749
|
+
*/
|
|
750
|
+
MOUSE_LEAVE = "mouseleave";
|
|
751
|
+
|
|
752
|
+
/**
|
|
753
|
+
* @public
|
|
754
|
+
*/
|
|
755
|
+
declare const /**
|
|
756
|
+
@public
|
|
757
|
+
* when a new player is inserted into the HTML
|
|
758
|
+
*/ /**
|
|
759
|
+
* @public
|
|
760
|
+
*/
|
|
761
|
+
MOUSE_MOVE = "mousemove";
|
|
762
|
+
|
|
763
|
+
/**
|
|
764
|
+
* @public
|
|
765
|
+
*/
|
|
766
|
+
declare const /**
|
|
767
|
+
@public
|
|
768
|
+
* when a new player is inserted into the HTML
|
|
769
|
+
*/ /**
|
|
770
|
+
* @public
|
|
771
|
+
*/
|
|
772
|
+
MOUSE_UP = "mouseup";
|
|
773
|
+
|
|
774
|
+
declare const MUTED = "is-muted";
|
|
775
|
+
|
|
776
|
+
declare const NO_CONTROLS = "no-controls";
|
|
777
|
+
|
|
778
|
+
declare const NO_DVR = "no-timeline";
|
|
779
|
+
|
|
780
|
+
/* Excluded from this release type: NON_RECOVERABLE_ERROR */
|
|
781
|
+
|
|
782
|
+
/* Excluded from this release type: NonRecoverableErrorEventDetail */
|
|
783
|
+
|
|
784
|
+
/* Excluded from this release type: NQState */
|
|
785
|
+
|
|
786
|
+
/**
|
|
787
|
+
* @public
|
|
788
|
+
* OVP plugin
|
|
789
|
+
*/
|
|
790
|
+
declare const OVP: PluginCtor<OVPConfig, OVPPlayer>;
|
|
791
|
+
export default OVP;
|
|
792
|
+
|
|
793
|
+
/**
|
|
794
|
+
* @public
|
|
795
|
+
* OVPConfig for npm users to configure the plugin
|
|
796
|
+
*/
|
|
797
|
+
export declare type OVPConfig = ConfigWith<{
|
|
798
|
+
recommendations?: boolean;
|
|
799
|
+
}>;
|
|
800
|
+
|
|
801
|
+
/**
|
|
802
|
+
* @public
|
|
803
|
+
*/
|
|
804
|
+
declare type OVPMetadata = {
|
|
805
|
+
player_id?: string;
|
|
806
|
+
media_id?: string;
|
|
807
|
+
ad_keywords?: string;
|
|
808
|
+
title?: string;
|
|
809
|
+
description?: string;
|
|
810
|
+
category_name?: string;
|
|
811
|
+
duration?: number;
|
|
812
|
+
tags?: string;
|
|
813
|
+
};
|
|
814
|
+
|
|
815
|
+
/**
|
|
816
|
+
* @public
|
|
817
|
+
*/
|
|
818
|
+
export declare type OVPPlayer = PlayerWith<{
|
|
819
|
+
on(event: EndscreenEvents["RECOMMENDATIONS_READY"], handler: (e: RecommendationsReadyEvent) => void): Player;
|
|
820
|
+
/* Excluded from this release type: on */
|
|
821
|
+
}>;
|
|
822
|
+
|
|
823
|
+
/**
|
|
824
|
+
* @public
|
|
825
|
+
*/
|
|
826
|
+
declare const /**
|
|
827
|
+
@public
|
|
828
|
+
* when a new player is inserted into the HTML
|
|
829
|
+
*/ /**
|
|
830
|
+
* @public
|
|
831
|
+
*/
|
|
832
|
+
PAUSE = "pause";
|
|
833
|
+
|
|
834
|
+
declare const PAUSED = "is-paused";
|
|
835
|
+
|
|
836
|
+
/**
|
|
837
|
+
* @public
|
|
838
|
+
*/
|
|
839
|
+
declare const /**
|
|
840
|
+
@public
|
|
841
|
+
* when a new player is inserted into the HTML
|
|
842
|
+
*/ /**
|
|
843
|
+
* @public
|
|
844
|
+
*/
|
|
845
|
+
PLAY = "play";
|
|
846
|
+
|
|
847
|
+
/**
|
|
848
|
+
* @public
|
|
849
|
+
*/
|
|
850
|
+
declare type Player = HTMLVideoElement & PlayerEventOverloads & {
|
|
851
|
+
/* Excluded from this release type: renderPlugin */
|
|
852
|
+
/**
|
|
853
|
+
* Disables and enables the player.
|
|
854
|
+
* @param flag -Forces disabled mode (true) or enabled mode (false). Disabled player cannot be seeked forward.
|
|
855
|
+
*/
|
|
856
|
+
toggleDisable: (flag?: boolean) => void;
|
|
857
|
+
/* Excluded from this release type: original_src */
|
|
858
|
+
/**
|
|
859
|
+
* The root element of the video player. This is the immediate parent element of the video tag.
|
|
860
|
+
*/
|
|
861
|
+
root: PlayerRoot;
|
|
862
|
+
/* Excluded from this release type: playerState */
|
|
863
|
+
/* Excluded from this release type: reaper */
|
|
864
|
+
/* Excluded from this release type: hasState */
|
|
865
|
+
/* Excluded from this release type: transitionState */
|
|
866
|
+
/**
|
|
867
|
+
* Toggles between playing and paused mode.
|
|
868
|
+
* @param on - Forces the playback (true) or paused state (false). Use this for initial playback of a source configured with setSrc() and when changing the state.
|
|
869
|
+
*/
|
|
870
|
+
togglePlay(on?: boolean): Promise<void>;
|
|
871
|
+
/* Excluded from this release type: toggleFullScreen */
|
|
872
|
+
/**
|
|
873
|
+
* @public
|
|
874
|
+
* Toggles between normal and fullscreen mode. The optional flag attribute forces the normal sized (false) or fullscreen (false) mode.
|
|
875
|
+
* The custom fullscreenenter and fullscreenexit events are sent respectively.
|
|
876
|
+
*/
|
|
877
|
+
toggleFullScreen(on?: boolean): void;
|
|
878
|
+
/* Excluded from this release type: toggleMute */
|
|
879
|
+
/**
|
|
880
|
+
* Toggles between muted and original volume level.
|
|
881
|
+
*/
|
|
882
|
+
toggleMute(): void;
|
|
883
|
+
/**
|
|
884
|
+
* Removes a Flowplayer instance from `flowplayer.instances` and emits the `flowplayer.events.REAP` event, enabling cleanup of unsafe resources.
|
|
885
|
+
*/
|
|
886
|
+
destroy(): void;
|
|
887
|
+
/* Excluded from this release type: render */
|
|
888
|
+
/* Excluded from this release type: render */
|
|
889
|
+
createComponents(...args: string[]): HTMLElement[];
|
|
890
|
+
/**
|
|
891
|
+
* Adds or changes configuration object. Usually used in conjunction with `setSrc()`. You can use all top-level config options like `subtitle:` , `logo:`, `ima:` etc.
|
|
892
|
+
* @example
|
|
893
|
+
* ```
|
|
894
|
+
* setOpts({
|
|
895
|
+
* subtitles:{
|
|
896
|
+
* tracks:[
|
|
897
|
+
* {
|
|
898
|
+
* src: "1.vtt",
|
|
899
|
+
* label: "English",
|
|
900
|
+
* default: true
|
|
901
|
+
* }, {
|
|
902
|
+
* src: "2.vtt",
|
|
903
|
+
* label: "Spanish",
|
|
904
|
+
* default : false }]},
|
|
905
|
+
* logo: "https://myserver.com/logo.png"
|
|
906
|
+
* })
|
|
907
|
+
* ```
|
|
908
|
+
*/
|
|
909
|
+
setOpts(config: Config): void;
|
|
910
|
+
/**
|
|
911
|
+
* Sets the video source to be played. The src attribute can be a string or an object similar to the src property.
|
|
912
|
+
*/
|
|
913
|
+
setSrc(sources: UnsafeSource): void;
|
|
914
|
+
/* Excluded from this release type: setSrc */
|
|
915
|
+
/* Excluded from this release type: setAttrs */
|
|
916
|
+
/* Excluded from this release type: opt */
|
|
917
|
+
/* Excluded from this release type: enqueueSeek */
|
|
918
|
+
/* Excluded from this release type: setState */
|
|
919
|
+
setState(state: PlayerState, flag: boolean): void;
|
|
920
|
+
/* Excluded from this release type: toJSON */
|
|
921
|
+
/**
|
|
922
|
+
* Adds a language to the project. See {@link https://developer.wowza.com/docs/wowza-flowplayer/player/translations/#using-npm| Official documentation}
|
|
923
|
+
*/
|
|
924
|
+
i18n(k: string, fallback?: string): string;
|
|
925
|
+
/* Excluded from this release type: deviceId */
|
|
926
|
+
/* Excluded from this release type: live_state */
|
|
927
|
+
/**
|
|
928
|
+
* A reference to the configuration state of the player.
|
|
929
|
+
*/
|
|
930
|
+
opts: Config;
|
|
931
|
+
/* Excluded from this release type: plugins */
|
|
932
|
+
/* Excluded from this release type: dvr_offset */
|
|
248
933
|
message?: {
|
|
249
934
|
events: Record<string, string>;
|
|
250
935
|
};
|
|
936
|
+
/**
|
|
937
|
+
* A boolean specifying whether the player is disabled and the user cannot seek forward using the mouse or keyboard.
|
|
938
|
+
* Player is disabled and enabled with the `toggleDisable()` method.
|
|
939
|
+
*/
|
|
251
940
|
disabled: boolean;
|
|
252
|
-
started
|
|
253
|
-
|
|
941
|
+
/* Excluded from this release type: started */
|
|
942
|
+
/* Excluded from this release type: token */
|
|
254
943
|
tracks?: VideoTrack[];
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
}
|
|
944
|
+
/* Excluded from this release type: _customElements */
|
|
945
|
+
/* Excluded from this release type: _storage */
|
|
946
|
+
};
|
|
947
|
+
|
|
948
|
+
declare type PlayerCustomEventName = keyof PlayerCustomEventsDetailMap;
|
|
949
|
+
|
|
950
|
+
declare type PlayerCustomEventsDetailMap = {
|
|
951
|
+
[MOUNT]: MountEventDetail;
|
|
952
|
+
[ERROR]: ErrorEventDetail;
|
|
953
|
+
[CONTEXT_MENU]: ContextMenuEventDetail;
|
|
954
|
+
/* Excluded from this release type: beforeplay */
|
|
955
|
+
/* Excluded from this release type: beforepause */
|
|
956
|
+
/* Excluded from this release type: state */
|
|
957
|
+
[CUEPOINT_START]: CuePointStartEventDetail;
|
|
958
|
+
[CUEPOINT_END]: CuePointEndEventDetail;
|
|
959
|
+
[VIEW_ENTER]: ViewEnterEventDetail;
|
|
960
|
+
[VIEW_LEAVE]: ViewLeaveEventDetail;
|
|
961
|
+
[SOURCE]: SourceEventDetail;
|
|
962
|
+
/* Excluded from this release type: recover */
|
|
963
|
+
[REAP]: ReapEventDetail;
|
|
964
|
+
/* Excluded from this release type: config */
|
|
965
|
+
[QUALITIES]: QualitiesEventDetail;
|
|
966
|
+
/* Excluded from this release type: "error:fatal" */
|
|
967
|
+
[RECOMMENDATIONS_READY]: RecommendationsReadyEventDetail;
|
|
968
|
+
/* Excluded from this release type: audioonlysource */
|
|
969
|
+
/* Excluded from this release type: renderplugin */
|
|
970
|
+
[DVR]: DvrEventDetail;
|
|
971
|
+
[LIVE_2]: LiveEventDetail;
|
|
972
|
+
/* Excluded from this release type: "seek:queued" */
|
|
973
|
+
/* Excluded from this release type: "seek:cancel" */
|
|
974
|
+
/* Excluded from this release type: "plugin:registered" */
|
|
975
|
+
/* Excluded from this release type: intersectionchange */
|
|
976
|
+
/* Excluded from this release type: retry */
|
|
977
|
+
};
|
|
978
|
+
|
|
979
|
+
declare type PlayerCustomEventsOverloads = {
|
|
980
|
+
/**
|
|
981
|
+
* Sent when the player interface is completely rendered and you can access all the elements with CSS and JavaScript. Due to the way mounting works, this event is only accessible inside of a custom extension.
|
|
982
|
+
*/
|
|
983
|
+
on(event: typeof MOUNT, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof MOUNT]>) => void): Player;
|
|
984
|
+
/**
|
|
985
|
+
* Sent when an error occurs. Learn more about error handling.
|
|
986
|
+
*/
|
|
987
|
+
on(event: typeof ERROR, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof ERROR]>) => void): Player;
|
|
988
|
+
on(// FIXME - this event is in context-menu plugin
|
|
989
|
+
event: typeof CONTEXT_MENU, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof CONTEXT_MENU]>) => void): Player;
|
|
990
|
+
/* Excluded from this release type: on */
|
|
991
|
+
/* Excluded from this release type: on */
|
|
992
|
+
/* Excluded from this release type: on */
|
|
993
|
+
/**
|
|
994
|
+
* TODO - move to Cuepoints? Sent when a configured cuepoint is entered.
|
|
995
|
+
*/
|
|
996
|
+
on(event: typeof CUEPOINT_START, // TODO: move to Cuepoints
|
|
997
|
+
handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof CUEPOINT_START]>) => void): Player;
|
|
998
|
+
/**
|
|
999
|
+
* Sent when a configured cuepoint is terminated.
|
|
1000
|
+
*/
|
|
1001
|
+
on(event: typeof CUEPOINT_END, // TODO: move to Cuepoints
|
|
1002
|
+
handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof CUEPOINT_END]>) => void): Player;
|
|
1003
|
+
/**
|
|
1004
|
+
* Sent when the player becomes visible for the user.
|
|
1005
|
+
*/
|
|
1006
|
+
on(event: typeof VIEW_ENTER, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof VIEW_ENTER]>) => void): Player;
|
|
1007
|
+
/**
|
|
1008
|
+
* Sent when the player leaves the users viewport and is longer visible.
|
|
1009
|
+
*/
|
|
1010
|
+
on(event: typeof VIEW_LEAVE, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof VIEW_LEAVE]>) => void): Player;
|
|
1011
|
+
/**
|
|
1012
|
+
* Sent right before the player src attribute is set. This allows you to change the video URL before playback.
|
|
1013
|
+
*/
|
|
1014
|
+
on(event: typeof SOURCE, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof SOURCE]>) => void): Player;
|
|
1015
|
+
/* Excluded from this release type: on */
|
|
1016
|
+
/**
|
|
1017
|
+
* Sent when a flowplayer instance is about to be removed from the DOM, and any unsafe references are about to be reaped, which allows Single Page Applications to perform the necessary resource cleanups. This is important when working with front-end frameworks like React. This event should never be emitted directly, only listened to.
|
|
1018
|
+
*/
|
|
1019
|
+
on(event: typeof REAP, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof REAP]>) => void): Player;
|
|
1020
|
+
/* Excluded from this release type: on */
|
|
1021
|
+
/**
|
|
1022
|
+
* Emitted when the set of underlying qualities has changed.
|
|
1023
|
+
*/
|
|
1024
|
+
on(event: typeof QUALITIES, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof QUALITIES]>) => void): Player;
|
|
1025
|
+
/* Excluded from this release type: on */
|
|
1026
|
+
/**
|
|
1027
|
+
* Listen to this event to create a recommendations grid using the data passed with the event.
|
|
1028
|
+
*/
|
|
1029
|
+
on(event: typeof RECOMMENDATIONS_READY, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof RECOMMENDATIONS_READY]>) => void): Player;
|
|
1030
|
+
/* Excluded from this release type: on */
|
|
1031
|
+
/* Excluded from this release type: on */
|
|
1032
|
+
/**
|
|
1033
|
+
* when the player has started playing dvr content
|
|
1034
|
+
*/
|
|
1035
|
+
on(event: typeof DVR, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof DVR]>) => void): Player;
|
|
1036
|
+
/**
|
|
1037
|
+
* when src is a livestream
|
|
1038
|
+
*/
|
|
1039
|
+
on(event: typeof LIVE_2, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof LIVE_2]>) => void): Player;
|
|
1040
|
+
/* Excluded from this release type: on */
|
|
1041
|
+
/* Excluded from this release type: on */
|
|
1042
|
+
/* Excluded from this release type: on */
|
|
1043
|
+
/* Excluded from this release type: on */
|
|
1044
|
+
/* Excluded from this release type: on */
|
|
1045
|
+
on<T>(event: string, handler: (e: FPEvent<T>) => void): Player;
|
|
1046
|
+
/* Excluded from this release type: on */
|
|
1047
|
+
/**
|
|
1048
|
+
* Same as `on()`, but the handler function is executed only once.
|
|
1049
|
+
*/
|
|
1050
|
+
once<T extends PlayerCustomEventName>(event: T, handler: (e: FPEvent<PlayerCustomEventsDetailMap[T]>) => void): Player;
|
|
1051
|
+
/**
|
|
1052
|
+
* Same as `on()`, but the handler function is executed only once.
|
|
1053
|
+
*/
|
|
1054
|
+
once<T extends PlayerNativeEventName>(event: T, handler: (e: PlayerNativeEventsDetailMap[T]) => void): Player;
|
|
1055
|
+
once<T>(event: string, handler: (e: FPEvent<T>) => void): Player;
|
|
1056
|
+
/**
|
|
1057
|
+
* Removes the event handler with the specified event type.
|
|
1058
|
+
*/
|
|
1059
|
+
off<T extends PlayerCustomEventName>(event: T, handler: (e: FPEvent<PlayerCustomEventsDetailMap[T]>) => void): Player;
|
|
1060
|
+
/**
|
|
1061
|
+
* Removes the event handler with the specified event type.
|
|
1062
|
+
*/
|
|
1063
|
+
off<T extends PlayerNativeEventName>(event: T, handler: (e: PlayerNativeEventsDetailMap[T]) => void): Player;
|
|
1064
|
+
/**
|
|
1065
|
+
* Removes the event handler with the specified event type.
|
|
1066
|
+
*/
|
|
1067
|
+
off<T>(event: string, handler: (e: FPEvent<T>) => void): Player;
|
|
1068
|
+
/* Excluded from this release type: poll */
|
|
1069
|
+
emit<T extends PlayerCustomEventName>(event: T, data?: PlayerCustomEventsDetailMap[T]): Player;
|
|
1070
|
+
/* Excluded from this release type: emit */
|
|
1071
|
+
emit<T, X extends string = string>(event: X & (X extends PlayerCustomEventName ? "Incorrect event detail type" : X), data?: T): Player;
|
|
1072
|
+
};
|
|
258
1073
|
|
|
1074
|
+
declare type PlayerEventOverloads = PlayerNativeEventsOverloads & PlayerCustomEventsOverloads;
|
|
1075
|
+
|
|
1076
|
+
declare type PlayerNativeEventName = keyof PlayerNativeEventsDetailMap;
|
|
1077
|
+
|
|
1078
|
+
declare type PlayerNativeEventsDetailMap = Omit<HTMLVideoElementEventMap, "error">;
|
|
1079
|
+
|
|
1080
|
+
declare type PlayerNativeEventsOverloads = {
|
|
1081
|
+
on<K extends keyof PlayerNativeEventsDetailMap>(event: K, handler: (ev: PlayerNativeEventsDetailMap[K]) => void): Player;
|
|
1082
|
+
};
|
|
1083
|
+
|
|
1084
|
+
/**
|
|
1085
|
+
* @public
|
|
1086
|
+
* The root element of the video player. This is the immediate parent element of the video tag.
|
|
1087
|
+
*/
|
|
259
1088
|
declare type PlayerRoot = HTMLElement & {
|
|
260
|
-
prevWidth
|
|
1089
|
+
/* Excluded from this release type: prevWidth */
|
|
261
1090
|
};
|
|
262
1091
|
|
|
263
|
-
|
|
1092
|
+
/**
|
|
1093
|
+
* @public
|
|
1094
|
+
*/
|
|
1095
|
+
declare type PlayerState = FlowplayerStates[keyof FlowplayerStates];
|
|
264
1096
|
|
|
1097
|
+
/* Excluded from this release type: _PlayerState */
|
|
1098
|
+
|
|
1099
|
+
/* Excluded from this release type: PlayerStates */
|
|
1100
|
+
|
|
1101
|
+
/**
|
|
1102
|
+
* @public
|
|
1103
|
+
*/
|
|
265
1104
|
declare type PlayerWith<T> = T & Player;
|
|
266
1105
|
|
|
1106
|
+
declare const PLAYING = "is-playing";
|
|
1107
|
+
|
|
1108
|
+
/**
|
|
1109
|
+
* @public
|
|
1110
|
+
*/
|
|
1111
|
+
declare const /**
|
|
1112
|
+
@public
|
|
1113
|
+
* when a new player is inserted into the HTML
|
|
1114
|
+
*/ /**
|
|
1115
|
+
* @public
|
|
1116
|
+
*/
|
|
1117
|
+
PLAYING_2 = "playing";
|
|
1118
|
+
|
|
267
1119
|
declare type PlaylistItem = {
|
|
268
1120
|
poster?: string;
|
|
269
1121
|
title?: string;
|
|
@@ -271,30 +1123,154 @@ declare type PlaylistItem = {
|
|
|
271
1123
|
src: string[];
|
|
272
1124
|
};
|
|
273
1125
|
|
|
274
|
-
|
|
1126
|
+
/**
|
|
1127
|
+
* @public
|
|
1128
|
+
*/
|
|
1129
|
+
declare interface Plugin_2<PluginConfig extends Config = Config, PluginPlayer extends Player = Player> {
|
|
275
1130
|
/**
|
|
276
1131
|
* a plugin must always implement the init method so a player instance knows how to initialize it
|
|
277
1132
|
*/
|
|
278
|
-
init(config:
|
|
1133
|
+
init(config: PluginConfig, container: PlayerRoot, player: PluginPlayer): void;
|
|
279
1134
|
}
|
|
280
1135
|
|
|
281
|
-
|
|
282
|
-
|
|
1136
|
+
/* Excluded from this release type: PLUGIN_REGISTERED */
|
|
1137
|
+
|
|
1138
|
+
/**
|
|
1139
|
+
* @public
|
|
1140
|
+
*/
|
|
1141
|
+
declare interface PluginCtor<PluginConfig extends Config = Config, PluginPlayer extends Player = Player> {
|
|
1142
|
+
new (umd: FlowplayerUMD, player: PluginPlayer): Plugin_2<PluginConfig, PluginPlayer>;
|
|
283
1143
|
}
|
|
284
1144
|
|
|
1145
|
+
/* Excluded from this release type: PluginRegisteredEventDetail */
|
|
1146
|
+
|
|
1147
|
+
declare type PluginStates = string;
|
|
1148
|
+
|
|
1149
|
+
/**
|
|
1150
|
+
* @public
|
|
1151
|
+
*/
|
|
1152
|
+
declare const /**
|
|
1153
|
+
@public
|
|
1154
|
+
* when a new player is inserted into the HTML
|
|
1155
|
+
*/ /**
|
|
1156
|
+
* @public
|
|
1157
|
+
*/
|
|
1158
|
+
PORTRAIT = "portrait";
|
|
1159
|
+
|
|
1160
|
+
/**
|
|
1161
|
+
* @public
|
|
1162
|
+
*/
|
|
1163
|
+
declare const /**
|
|
1164
|
+
@public
|
|
1165
|
+
* when a new player is inserted into the HTML
|
|
1166
|
+
*/ /**
|
|
1167
|
+
* @public
|
|
1168
|
+
*/
|
|
1169
|
+
PROGRESS = "progress";
|
|
1170
|
+
|
|
1171
|
+
/**
|
|
1172
|
+
* @public
|
|
1173
|
+
* emitted whenever a list of qualities has been made available
|
|
1174
|
+
* when index 0 is the highest quality and index 0+N is the lowest
|
|
1175
|
+
*/
|
|
1176
|
+
declare const /**
|
|
1177
|
+
@public
|
|
1178
|
+
* when a new player is inserted into the HTML
|
|
1179
|
+
*/ /**
|
|
1180
|
+
* @public
|
|
1181
|
+
* emitted whenever a list of qualities has been made available
|
|
1182
|
+
* when index 0 is the highest quality and index 0+N is the lowest
|
|
1183
|
+
*/
|
|
1184
|
+
QUALITIES = "qualities";
|
|
1185
|
+
|
|
1186
|
+
/**
|
|
1187
|
+
* @public
|
|
1188
|
+
*/
|
|
1189
|
+
declare type QualitiesEventDetail = QualityDetail[];
|
|
1190
|
+
|
|
1191
|
+
/**
|
|
1192
|
+
* @public
|
|
1193
|
+
*/
|
|
1194
|
+
declare type QualityDetail = {
|
|
1195
|
+
level: number;
|
|
1196
|
+
text: string;
|
|
1197
|
+
width: number;
|
|
1198
|
+
height: number;
|
|
1199
|
+
videoCodec: string;
|
|
1200
|
+
} | BitrateInfo | {
|
|
1201
|
+
text: string | number;
|
|
1202
|
+
encodingId: string;
|
|
1203
|
+
spatialLayerId: number;
|
|
1204
|
+
temporalLayerId: number;
|
|
1205
|
+
maxSpatialLayerId: number;
|
|
1206
|
+
maxTemporalLayerId: number;
|
|
1207
|
+
height: number;
|
|
1208
|
+
width: number;
|
|
1209
|
+
};
|
|
1210
|
+
|
|
285
1211
|
declare enum QualityOpts {
|
|
286
1212
|
LOW = 1,
|
|
287
1213
|
MEDIUM = 2,
|
|
288
1214
|
HIGH = 4
|
|
289
1215
|
}
|
|
290
1216
|
|
|
1217
|
+
/**
|
|
1218
|
+
* @public
|
|
1219
|
+
* emitted when it is safe to clean up a fp instance
|
|
1220
|
+
*/
|
|
1221
|
+
declare const /**
|
|
1222
|
+
@public
|
|
1223
|
+
* when a new player is inserted into the HTML
|
|
1224
|
+
*/ /**
|
|
1225
|
+
* @public
|
|
1226
|
+
* emitted when it is safe to clean up a fp instance
|
|
1227
|
+
*/
|
|
1228
|
+
REAP = "reap";
|
|
1229
|
+
|
|
1230
|
+
/**
|
|
1231
|
+
* @public
|
|
1232
|
+
*/
|
|
1233
|
+
declare type ReapEventDetail = null;
|
|
1234
|
+
|
|
1235
|
+
/**
|
|
1236
|
+
* @public
|
|
1237
|
+
*/
|
|
1238
|
+
declare type RecommendationItem = {
|
|
1239
|
+
poster?: string;
|
|
1240
|
+
src?: UnsafeSource;
|
|
1241
|
+
title?: string;
|
|
1242
|
+
description?: string;
|
|
1243
|
+
metadata: OVPMetadata;
|
|
1244
|
+
chapters?: {
|
|
1245
|
+
src: string;
|
|
1246
|
+
};
|
|
1247
|
+
thumbnails?: {
|
|
1248
|
+
src: string;
|
|
1249
|
+
};
|
|
1250
|
+
subtitles?: string[];
|
|
1251
|
+
};
|
|
1252
|
+
|
|
291
1253
|
declare const RECOMMENDATIONS_HIDE = "recommendations:hide";
|
|
292
1254
|
|
|
1255
|
+
/**
|
|
1256
|
+
* @public
|
|
1257
|
+
*/
|
|
1258
|
+
declare const /**
|
|
1259
|
+
@public
|
|
1260
|
+
* when a new player is inserted into the HTML
|
|
1261
|
+
*/ /**
|
|
1262
|
+
* @deprecated please use Endscreen.events.RECOMMENDATIONS_READY / flowplayer.endscreen.events.RECOMMENDATIONS_READY
|
|
1263
|
+
**/
|
|
1264
|
+
/**
|
|
1265
|
+
* @public
|
|
1266
|
+
*/
|
|
1267
|
+
RECOMMENDATIONS_READY = "recommendationsready";
|
|
1268
|
+
|
|
293
1269
|
/**
|
|
294
1270
|
* @public
|
|
295
1271
|
* emitted when recommandations list is available
|
|
296
1272
|
**/
|
|
297
|
-
declare const
|
|
1273
|
+
declare const RECOMMENDATIONS_READY_2 = "recommendationsready";
|
|
298
1274
|
|
|
299
1275
|
declare const RECOMMENDATIONS_RENDER = "recommendations:render";
|
|
300
1276
|
|
|
@@ -303,23 +1279,372 @@ declare const RECOMMENDATIONS_RENDER = "recommendations:render";
|
|
|
303
1279
|
*/
|
|
304
1280
|
declare type RecommendationsReadyEvent = FPEvent<EndscreenRecommendations>;
|
|
305
1281
|
|
|
1282
|
+
/**
|
|
1283
|
+
* @public
|
|
1284
|
+
*/
|
|
1285
|
+
declare type RecommendationsReadyEventDetail = {
|
|
1286
|
+
playlist: RecommendationItem[];
|
|
1287
|
+
};
|
|
1288
|
+
|
|
1289
|
+
/* Excluded from this release type: RECOVER */
|
|
1290
|
+
|
|
1291
|
+
/* Excluded from this release type: RecoverEventDetail */
|
|
1292
|
+
|
|
1293
|
+
/* Excluded from this release type: REMOTE_SESSION_ENDED */
|
|
1294
|
+
|
|
1295
|
+
/* Excluded from this release type: REMOTE_SESSION_STARTED */
|
|
1296
|
+
|
|
1297
|
+
/* Excluded from this release type: RENDER_PLUGIN */
|
|
1298
|
+
|
|
1299
|
+
/**
|
|
1300
|
+
* @public
|
|
1301
|
+
*/
|
|
1302
|
+
declare type RenderPluginEventDetail = HTMLElement;
|
|
1303
|
+
|
|
1304
|
+
/**
|
|
1305
|
+
* @public
|
|
1306
|
+
*/
|
|
1307
|
+
declare const /**
|
|
1308
|
+
@public
|
|
1309
|
+
* when a new player is inserted into the HTML
|
|
1310
|
+
*/ /**
|
|
1311
|
+
* @public
|
|
1312
|
+
*/
|
|
1313
|
+
RESIZE = "resize";
|
|
1314
|
+
|
|
1315
|
+
/* Excluded from this release type: RETRY */
|
|
1316
|
+
|
|
1317
|
+
/* Excluded from this release type: RetryEventDetail */
|
|
1318
|
+
|
|
1319
|
+
declare const RTL = "is-rtl";
|
|
1320
|
+
|
|
1321
|
+
/**
|
|
1322
|
+
* @public
|
|
1323
|
+
*/
|
|
1324
|
+
declare const /**
|
|
1325
|
+
@public
|
|
1326
|
+
* when a new player is inserted into the HTML
|
|
1327
|
+
*/ /**
|
|
1328
|
+
* @public
|
|
1329
|
+
*/
|
|
1330
|
+
SCROLL = "scroll";
|
|
1331
|
+
|
|
1332
|
+
declare const SEAMLESS = "is-seamless";
|
|
1333
|
+
|
|
1334
|
+
/* Excluded from this release type: SEEK_CANCEL */
|
|
1335
|
+
|
|
1336
|
+
/* Excluded from this release type: SEEK_QUEUED */
|
|
1337
|
+
|
|
1338
|
+
declare const SEEKABLE = "is-seekable";
|
|
1339
|
+
|
|
1340
|
+
/* Excluded from this release type: SeekCancelEventDetail */
|
|
1341
|
+
|
|
1342
|
+
/**
|
|
1343
|
+
* @public
|
|
1344
|
+
*/
|
|
1345
|
+
declare const /**
|
|
1346
|
+
@public
|
|
1347
|
+
* when a new player is inserted into the HTML
|
|
1348
|
+
*/ /**
|
|
1349
|
+
* @public
|
|
1350
|
+
*/
|
|
1351
|
+
SEEKED = "seeked";
|
|
1352
|
+
|
|
1353
|
+
declare const SEEKING = "is-seeking";
|
|
1354
|
+
|
|
1355
|
+
/**
|
|
1356
|
+
* @public
|
|
1357
|
+
*/
|
|
1358
|
+
declare const /**
|
|
1359
|
+
@public
|
|
1360
|
+
* when a new player is inserted into the HTML
|
|
1361
|
+
*/ /**
|
|
1362
|
+
* @public
|
|
1363
|
+
*/
|
|
1364
|
+
SEEKING_2 = "seeking";
|
|
1365
|
+
|
|
1366
|
+
/* Excluded from this release type: SeekQueuedEventDetail */
|
|
1367
|
+
|
|
1368
|
+
/**
|
|
1369
|
+
* @public
|
|
1370
|
+
* allows plugins to listen for forced quality changes
|
|
1371
|
+
* it should emit the index of the quality to set
|
|
1372
|
+
* -1 is a special idx saying to use ABR if the plugin
|
|
1373
|
+
* exposes an ABR implementation
|
|
1374
|
+
*/
|
|
1375
|
+
declare const /**
|
|
1376
|
+
@public
|
|
1377
|
+
* when a new player is inserted into the HTML
|
|
1378
|
+
*/ /**
|
|
1379
|
+
* @public
|
|
1380
|
+
* allows plugins to listen for forced quality changes
|
|
1381
|
+
* it should emit the index of the quality to set
|
|
1382
|
+
* -1 is a special idx saying to use ABR if the plugin
|
|
1383
|
+
* exposes an ABR implementation
|
|
1384
|
+
*/
|
|
1385
|
+
SET_QUALITY = "quality:set";
|
|
1386
|
+
|
|
1387
|
+
declare const SMALL = "is-small";
|
|
1388
|
+
|
|
1389
|
+
/**
|
|
1390
|
+
* @public
|
|
1391
|
+
* emitted when a valid source is found prior to mounting
|
|
1392
|
+
*/
|
|
1393
|
+
declare const /**
|
|
1394
|
+
@public
|
|
1395
|
+
* when a new player is inserted into the HTML
|
|
1396
|
+
*/ /**
|
|
1397
|
+
* @public
|
|
1398
|
+
* emitted when a valid source is found prior to mounting
|
|
1399
|
+
*/
|
|
1400
|
+
SOURCE = "src";
|
|
1401
|
+
|
|
1402
|
+
/**
|
|
1403
|
+
* @public
|
|
1404
|
+
*/
|
|
1405
|
+
declare type SourceEventDetail = SourceObj;
|
|
1406
|
+
|
|
1407
|
+
/**
|
|
1408
|
+
* @public
|
|
1409
|
+
*/
|
|
306
1410
|
declare type SourceObj = {
|
|
307
1411
|
src?: SourceStr;
|
|
1412
|
+
/**
|
|
1413
|
+
* the MIME type (example `video/mp4` or `application/x-mpegurl`)
|
|
1414
|
+
*/
|
|
308
1415
|
type?: string;
|
|
309
1416
|
drm?: DRMSourceConfiguration;
|
|
310
1417
|
};
|
|
311
1418
|
|
|
1419
|
+
/**
|
|
1420
|
+
* @public
|
|
1421
|
+
*/
|
|
312
1422
|
declare type SourceStr = string;
|
|
313
1423
|
|
|
1424
|
+
/**
|
|
1425
|
+
* @public
|
|
1426
|
+
*/
|
|
314
1427
|
declare type SourceWith<T> = SourceObj & T;
|
|
315
1428
|
|
|
1429
|
+
declare const STARTING = "is-starting";
|
|
1430
|
+
|
|
1431
|
+
/* Excluded from this release type: STATE */
|
|
1432
|
+
|
|
1433
|
+
/* Excluded from this release type: StateEventDetail */
|
|
1434
|
+
|
|
1435
|
+
declare namespace states {
|
|
1436
|
+
export {
|
|
1437
|
+
PLAYING,
|
|
1438
|
+
FULLSCREEN,
|
|
1439
|
+
PAUSED,
|
|
1440
|
+
MUTED,
|
|
1441
|
+
LOADED,
|
|
1442
|
+
LOADING,
|
|
1443
|
+
STARTING,
|
|
1444
|
+
SEEKING,
|
|
1445
|
+
GRABBING,
|
|
1446
|
+
DISABLED,
|
|
1447
|
+
SMALL,
|
|
1448
|
+
TINY,
|
|
1449
|
+
RTL,
|
|
1450
|
+
TV,
|
|
1451
|
+
ENDED,
|
|
1452
|
+
LIVE,
|
|
1453
|
+
ERRORED,
|
|
1454
|
+
WAITING,
|
|
1455
|
+
AUTOPLAY,
|
|
1456
|
+
SEAMLESS,
|
|
1457
|
+
TOGGLING,
|
|
1458
|
+
LIVE_SEEKED,
|
|
1459
|
+
NO_DVR,
|
|
1460
|
+
HAS_POSTER,
|
|
1461
|
+
WILL_PLAY,
|
|
1462
|
+
WILL_PAUSE,
|
|
1463
|
+
MENU_OPENED,
|
|
1464
|
+
TOUCHED,
|
|
1465
|
+
HOVERED,
|
|
1466
|
+
TOUCH_DEVICE,
|
|
1467
|
+
WILL_SEEK,
|
|
1468
|
+
SEEKABLE,
|
|
1469
|
+
IN_VIEWPORT,
|
|
1470
|
+
NO_CONTROLS,
|
|
1471
|
+
DESTROYED,
|
|
1472
|
+
IS_SOURCE_PROCESSING
|
|
1473
|
+
}
|
|
1474
|
+
}
|
|
1475
|
+
|
|
1476
|
+
/**
|
|
1477
|
+
* @public
|
|
1478
|
+
*/
|
|
1479
|
+
declare const /**
|
|
1480
|
+
@public
|
|
1481
|
+
* when a new player is inserted into the HTML
|
|
1482
|
+
*/ /**
|
|
1483
|
+
* @public
|
|
1484
|
+
*/
|
|
1485
|
+
TIME_UPDATE = "timeupdate";
|
|
1486
|
+
|
|
1487
|
+
declare const TINY = "is-tiny";
|
|
1488
|
+
|
|
1489
|
+
declare const TOGGLING = "is-toggling";
|
|
1490
|
+
|
|
1491
|
+
/**
|
|
1492
|
+
* @public
|
|
1493
|
+
*/
|
|
1494
|
+
declare const /**
|
|
1495
|
+
@public
|
|
1496
|
+
* when a new player is inserted into the HTML
|
|
1497
|
+
*/ /**
|
|
1498
|
+
* @public
|
|
1499
|
+
*/
|
|
1500
|
+
TOUCH_CANCEL = "touchcancel";
|
|
1501
|
+
|
|
1502
|
+
declare const TOUCH_DEVICE = "is-touch-device";
|
|
1503
|
+
|
|
1504
|
+
/**
|
|
1505
|
+
* @public
|
|
1506
|
+
*/
|
|
1507
|
+
declare const /**
|
|
1508
|
+
@public
|
|
1509
|
+
* when a new player is inserted into the HTML
|
|
1510
|
+
*/ /**
|
|
1511
|
+
* @public
|
|
1512
|
+
*/
|
|
1513
|
+
TOUCH_END = "touchend";
|
|
1514
|
+
|
|
1515
|
+
/**
|
|
1516
|
+
* @public
|
|
1517
|
+
*/
|
|
1518
|
+
declare const /**
|
|
1519
|
+
@public
|
|
1520
|
+
* when a new player is inserted into the HTML
|
|
1521
|
+
*/ /**
|
|
1522
|
+
* @public
|
|
1523
|
+
*/
|
|
1524
|
+
TOUCH_MOVE = "touchmove";
|
|
1525
|
+
|
|
1526
|
+
/**
|
|
1527
|
+
* @public
|
|
1528
|
+
*/
|
|
1529
|
+
declare const /**
|
|
1530
|
+
@public
|
|
1531
|
+
* when a new player is inserted into the HTML
|
|
1532
|
+
*/ /**
|
|
1533
|
+
* @public
|
|
1534
|
+
*/
|
|
1535
|
+
TOUCH_START = "touchstart";
|
|
1536
|
+
|
|
1537
|
+
declare const TOUCHED = "is-touched";
|
|
1538
|
+
|
|
1539
|
+
declare const TV = "is-tv";
|
|
1540
|
+
|
|
1541
|
+
/**
|
|
1542
|
+
* @public
|
|
1543
|
+
*/
|
|
316
1544
|
declare type UnsafeSource = SourceStr | SourceObj | Array<SourceStr | SourceObj>;
|
|
317
1545
|
|
|
1546
|
+
/**
|
|
1547
|
+
* @public
|
|
1548
|
+
* emitted when a video track is selected
|
|
1549
|
+
*/
|
|
1550
|
+
declare const /**
|
|
1551
|
+
@public
|
|
1552
|
+
* when a new player is inserted into the HTML
|
|
1553
|
+
*/ /**
|
|
1554
|
+
* @public
|
|
1555
|
+
* emitted when a video track is selected
|
|
1556
|
+
*/
|
|
1557
|
+
VIDEO_TRACK_SELECT = "tracks:video:select";
|
|
1558
|
+
|
|
1559
|
+
/**
|
|
1560
|
+
* @public
|
|
1561
|
+
* emitted whenever multiple video tracks are detected
|
|
1562
|
+
*/
|
|
1563
|
+
declare const /**
|
|
1564
|
+
@public
|
|
1565
|
+
* when a new player is inserted into the HTML
|
|
1566
|
+
*/ /**
|
|
1567
|
+
* @public
|
|
1568
|
+
* emitted whenever multiple video tracks are detected
|
|
1569
|
+
*/
|
|
1570
|
+
VIDEO_TRACKS = "videoTracks";
|
|
1571
|
+
|
|
1572
|
+
/**
|
|
1573
|
+
* @public
|
|
1574
|
+
*/
|
|
318
1575
|
declare interface VideoTrack {
|
|
319
1576
|
name: string;
|
|
320
|
-
|
|
1577
|
+
/* Excluded from this release type: data */
|
|
321
1578
|
default: boolean;
|
|
322
1579
|
selected: boolean;
|
|
323
1580
|
}
|
|
324
1581
|
|
|
1582
|
+
/**
|
|
1583
|
+
* @public
|
|
1584
|
+
* when a player enters the viewpoint
|
|
1585
|
+
*/
|
|
1586
|
+
declare const /**
|
|
1587
|
+
@public
|
|
1588
|
+
* when a new player is inserted into the HTML
|
|
1589
|
+
*/ /**
|
|
1590
|
+
* @public
|
|
1591
|
+
* when a player enters the viewpoint
|
|
1592
|
+
*/
|
|
1593
|
+
VIEW_ENTER = "viewenter";
|
|
1594
|
+
|
|
1595
|
+
/**
|
|
1596
|
+
* @public
|
|
1597
|
+
* when a player leaves the viewport
|
|
1598
|
+
*/
|
|
1599
|
+
declare const /**
|
|
1600
|
+
@public
|
|
1601
|
+
* when a new player is inserted into the HTML
|
|
1602
|
+
*/ /**
|
|
1603
|
+
* @public
|
|
1604
|
+
* when a player leaves the viewport
|
|
1605
|
+
*/
|
|
1606
|
+
VIEW_LEAVE = "viewleave";
|
|
1607
|
+
|
|
1608
|
+
/**
|
|
1609
|
+
* @public
|
|
1610
|
+
*/
|
|
1611
|
+
declare type ViewEnterEventDetail = null;
|
|
1612
|
+
|
|
1613
|
+
/**
|
|
1614
|
+
* @public
|
|
1615
|
+
*/
|
|
1616
|
+
declare type ViewLeaveEventDetail = null;
|
|
1617
|
+
|
|
1618
|
+
/**
|
|
1619
|
+
* @public
|
|
1620
|
+
*/
|
|
1621
|
+
declare const /**
|
|
1622
|
+
@public
|
|
1623
|
+
* when a new player is inserted into the HTML
|
|
1624
|
+
*/ /**
|
|
1625
|
+
* @public
|
|
1626
|
+
*/
|
|
1627
|
+
VOLUME_CHANGE = "volumechange";
|
|
1628
|
+
|
|
1629
|
+
declare const WAITING = "is-waiting";
|
|
1630
|
+
|
|
1631
|
+
/**
|
|
1632
|
+
* @public
|
|
1633
|
+
*/
|
|
1634
|
+
declare const /**
|
|
1635
|
+
@public
|
|
1636
|
+
* when a new player is inserted into the HTML
|
|
1637
|
+
*/ /**
|
|
1638
|
+
* @public
|
|
1639
|
+
*/
|
|
1640
|
+
WAITING_2 = "waiting";
|
|
1641
|
+
|
|
1642
|
+
/* Excluded from this release type: WEBKIT_NEEDKEY */
|
|
1643
|
+
|
|
1644
|
+
declare const WILL_PAUSE = "will-pause";
|
|
1645
|
+
|
|
1646
|
+
declare const WILL_PLAY = "will-play";
|
|
1647
|
+
|
|
1648
|
+
declare const WILL_SEEK = "will-seek";
|
|
1649
|
+
|
|
325
1650
|
export { }
|