@gcorevideo/player 2.20.22 → 2.21.3
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/assets/audio-selector/style.scss +48 -82
- package/assets/audio-selector/track-selector.ejs +3 -3
- package/assets/bottom-gear/bottomgear.ejs +10 -12
- package/assets/bottom-gear/gear-sub-menu.scss +0 -15
- package/assets/bottom-gear/gear.scss +3 -32
- package/assets/media-control/media-control.ejs +5 -25
- package/assets/media-control/media-control.scss +114 -34
- package/assets/media-control/width370.scss +35 -109
- package/assets/picture-in-picture/button.ejs +1 -1
- package/assets/picture-in-picture/button.scss +5 -4
- package/assets/subtitles/combobox.ejs +7 -9
- package/assets/subtitles/style.scss +8 -15
- package/dist/core.js +151 -23
- package/dist/index.css +897 -1000
- package/dist/index.js +416 -438
- package/dist/player.d.ts +19 -16
- package/dist/plugins/index.css +1454 -1557
- package/dist/plugins/index.js +826 -23550
- package/docs/api/player.audioselector.md +4 -59
- package/docs/api/player.md +1 -1
- package/docs/api/player.mediacontrol.getelement.md +5 -0
- package/docs/api/player.mediacontrol.md +14 -0
- package/docs/api/{player.audioselector.updatecurrenttrack.md → player.mediacontrol.putelement.md} +7 -7
- package/docs/api/player.mediacontrolelement.md +1 -1
- package/docs/api/{player.audioselector.starttrackswitch.md → player.pictureinpicture.attributes.md} +5 -7
- package/docs/api/player.pictureinpicture.md +45 -0
- package/lib/playback/BasePlayback.d.ts +1 -1
- package/lib/playback/BasePlayback.d.ts.map +1 -1
- package/lib/playback/BasePlayback.js +3 -1
- package/lib/playback/HTML5Video.d.ts +4 -0
- package/lib/playback/HTML5Video.d.ts.map +1 -1
- package/lib/playback/HTML5Video.js +53 -4
- package/lib/playback/dash-playback/DashPlayback.d.ts +5 -0
- package/lib/playback/dash-playback/DashPlayback.d.ts.map +1 -1
- package/lib/playback/dash-playback/DashPlayback.js +48 -4
- package/lib/playback/hls-playback/HlsPlayback.d.ts +31 -25
- package/lib/playback/hls-playback/HlsPlayback.d.ts.map +1 -1
- package/lib/playback/hls-playback/HlsPlayback.js +47 -14
- package/lib/playback.types.d.ts +5 -0
- package/lib/playback.types.d.ts.map +1 -1
- package/lib/plugins/audio-selector/AudioSelector.d.ts +12 -11
- package/lib/plugins/audio-selector/AudioSelector.d.ts.map +1 -1
- package/lib/plugins/audio-selector/AudioSelector.js +65 -185
- package/lib/plugins/bottom-gear/BottomGear.d.ts +2 -2
- package/lib/plugins/bottom-gear/BottomGear.d.ts.map +1 -1
- package/lib/plugins/bottom-gear/BottomGear.js +12 -10
- package/lib/plugins/level-selector/LevelSelector.js +1 -1
- package/lib/plugins/media-control/MediaControl.d.ts +3 -4
- package/lib/plugins/media-control/MediaControl.d.ts.map +1 -1
- package/lib/plugins/media-control/MediaControl.js +23 -13
- package/lib/plugins/picture-in-picture/PictureInPicture.d.ts +3 -0
- package/lib/plugins/picture-in-picture/PictureInPicture.d.ts.map +1 -1
- package/lib/plugins/picture-in-picture/PictureInPicture.js +6 -1
- package/lib/plugins/playback-rate/PlaybackRate.d.ts +1 -0
- package/lib/plugins/playback-rate/PlaybackRate.d.ts.map +1 -1
- package/lib/plugins/playback-rate/PlaybackRate.js +1 -0
- package/lib/plugins/source-controller/SourceController.d.ts.map +1 -1
- package/lib/plugins/source-controller/SourceController.js +0 -1
- package/lib/plugins/spinner-three-bounce/SpinnerThreeBounce.d.ts +0 -2
- package/lib/plugins/spinner-three-bounce/SpinnerThreeBounce.d.ts.map +1 -1
- package/lib/plugins/spinner-three-bounce/SpinnerThreeBounce.js +1 -18
- package/lib/plugins/subtitles/Subtitles.d.ts +21 -19
- package/lib/plugins/subtitles/Subtitles.d.ts.map +1 -1
- package/lib/plugins/subtitles/Subtitles.js +121 -151
- package/lib/testUtils.d.ts.map +1 -1
- package/lib/testUtils.js +2 -0
- package/package.json +1 -1
- package/src/playback/BasePlayback.ts +4 -1
- package/src/playback/HTML5Video.ts +57 -4
- package/src/playback/dash-playback/DashPlayback.ts +64 -6
- package/src/playback/hls-playback/HlsPlayback.ts +82 -40
- package/src/playback.types.ts +6 -0
- package/src/plugins/audio-selector/AudioSelector.ts +84 -278
- package/src/plugins/bottom-gear/BottomGear.ts +14 -11
- package/src/plugins/bottom-gear/__tests__/BottomGear.test.ts +1 -3
- package/src/plugins/bottom-gear/__tests__/__snapshots__/BottomGear.test.ts.snap +14 -37
- package/src/plugins/level-selector/LevelSelector.ts +1 -1
- package/src/plugins/media-control/MediaControl.ts +54 -32
- package/src/plugins/picture-in-picture/PictureInPicture.ts +7 -1
- package/src/plugins/playback-rate/PlaybackRate.ts +1 -0
- package/src/plugins/source-controller/SourceController.ts +0 -1
- package/src/plugins/spinner-three-bounce/SpinnerThreeBounce.ts +1 -20
- package/src/plugins/subtitles/Subtitles.ts +144 -179
- package/src/testUtils.ts +2 -0
- package/src/typings/globals.d.ts +19 -0
- package/temp/player.api.json +102 -143
- package/tsconfig.tsbuildinfo +1 -1
- package/assets/media-control/plugins.scss +0 -94
- package/docs/api/player.audioselector.highlightcurrenttrack.md +0 -18
package/temp/player.api.json
CHANGED
|
@@ -175,7 +175,7 @@
|
|
|
175
175
|
{
|
|
176
176
|
"kind": "Class",
|
|
177
177
|
"canonicalReference": "@gcorevideo/player!AudioSelector:class",
|
|
178
|
-
"docComment": "/**\n * `PLUGIN` that
|
|
178
|
+
"docComment": "/**\n * `PLUGIN` that makes possible to switch audio tracks via the media control UI.\n *\n * @remarks\n *\n * The plugin is activated when there are multiple audio tracks available. The plugin adds a button showing the current audio track and a dropdown to switch to another audio track. Depends on:\n *\n * - {@link MediaControl}\n *\n * @beta\n */\n",
|
|
179
179
|
"excerptTokens": [
|
|
180
180
|
{
|
|
181
181
|
"kind": "Content",
|
|
@@ -196,145 +196,7 @@
|
|
|
196
196
|
"isAbstract": false,
|
|
197
197
|
"name": "AudioSelector",
|
|
198
198
|
"preserveMemberOrder": false,
|
|
199
|
-
"members": [
|
|
200
|
-
{
|
|
201
|
-
"kind": "Method",
|
|
202
|
-
"canonicalReference": "@gcorevideo/player!AudioSelector#highlightCurrentTrack:member(1)",
|
|
203
|
-
"docComment": "",
|
|
204
|
-
"excerptTokens": [
|
|
205
|
-
{
|
|
206
|
-
"kind": "Content",
|
|
207
|
-
"text": "highlightCurrentTrack(): "
|
|
208
|
-
},
|
|
209
|
-
{
|
|
210
|
-
"kind": "Content",
|
|
211
|
-
"text": "void"
|
|
212
|
-
},
|
|
213
|
-
{
|
|
214
|
-
"kind": "Content",
|
|
215
|
-
"text": ";"
|
|
216
|
-
}
|
|
217
|
-
],
|
|
218
|
-
"isStatic": false,
|
|
219
|
-
"returnTypeTokenRange": {
|
|
220
|
-
"startIndex": 1,
|
|
221
|
-
"endIndex": 2
|
|
222
|
-
},
|
|
223
|
-
"releaseTag": "Beta",
|
|
224
|
-
"isProtected": false,
|
|
225
|
-
"overloadIndex": 1,
|
|
226
|
-
"parameters": [],
|
|
227
|
-
"isOptional": false,
|
|
228
|
-
"isAbstract": false,
|
|
229
|
-
"name": "highlightCurrentTrack"
|
|
230
|
-
},
|
|
231
|
-
{
|
|
232
|
-
"kind": "Method",
|
|
233
|
-
"canonicalReference": "@gcorevideo/player!AudioSelector#startTrackSwitch:member(1)",
|
|
234
|
-
"docComment": "",
|
|
235
|
-
"excerptTokens": [
|
|
236
|
-
{
|
|
237
|
-
"kind": "Content",
|
|
238
|
-
"text": "startTrackSwitch(): "
|
|
239
|
-
},
|
|
240
|
-
{
|
|
241
|
-
"kind": "Content",
|
|
242
|
-
"text": "void"
|
|
243
|
-
},
|
|
244
|
-
{
|
|
245
|
-
"kind": "Content",
|
|
246
|
-
"text": ";"
|
|
247
|
-
}
|
|
248
|
-
],
|
|
249
|
-
"isStatic": false,
|
|
250
|
-
"returnTypeTokenRange": {
|
|
251
|
-
"startIndex": 1,
|
|
252
|
-
"endIndex": 2
|
|
253
|
-
},
|
|
254
|
-
"releaseTag": "Beta",
|
|
255
|
-
"isProtected": false,
|
|
256
|
-
"overloadIndex": 1,
|
|
257
|
-
"parameters": [],
|
|
258
|
-
"isOptional": false,
|
|
259
|
-
"isAbstract": false,
|
|
260
|
-
"name": "startTrackSwitch"
|
|
261
|
-
},
|
|
262
|
-
{
|
|
263
|
-
"kind": "Method",
|
|
264
|
-
"canonicalReference": "@gcorevideo/player!AudioSelector#updateCurrentTrack:member(1)",
|
|
265
|
-
"docComment": "",
|
|
266
|
-
"excerptTokens": [
|
|
267
|
-
{
|
|
268
|
-
"kind": "Content",
|
|
269
|
-
"text": "updateCurrentTrack(e: "
|
|
270
|
-
},
|
|
271
|
-
{
|
|
272
|
-
"kind": "Reference",
|
|
273
|
-
"text": "HlsEvents.AUDIO_TRACK_SWITCHED",
|
|
274
|
-
"canonicalReference": "hls.js!Events.AUDIO_TRACK_SWITCHED:member"
|
|
275
|
-
},
|
|
276
|
-
{
|
|
277
|
-
"kind": "Content",
|
|
278
|
-
"text": ", info: "
|
|
279
|
-
},
|
|
280
|
-
{
|
|
281
|
-
"kind": "Reference",
|
|
282
|
-
"text": "AudioTrackSwitchedData",
|
|
283
|
-
"canonicalReference": "hls.js!AudioTrackSwitchedData:interface"
|
|
284
|
-
},
|
|
285
|
-
{
|
|
286
|
-
"kind": "Content",
|
|
287
|
-
"text": " | "
|
|
288
|
-
},
|
|
289
|
-
{
|
|
290
|
-
"kind": "Reference",
|
|
291
|
-
"text": "AudioTrackLoadedData",
|
|
292
|
-
"canonicalReference": "hls.js!AudioTrackLoadedData:interface"
|
|
293
|
-
},
|
|
294
|
-
{
|
|
295
|
-
"kind": "Content",
|
|
296
|
-
"text": "): "
|
|
297
|
-
},
|
|
298
|
-
{
|
|
299
|
-
"kind": "Content",
|
|
300
|
-
"text": "void"
|
|
301
|
-
},
|
|
302
|
-
{
|
|
303
|
-
"kind": "Content",
|
|
304
|
-
"text": ";"
|
|
305
|
-
}
|
|
306
|
-
],
|
|
307
|
-
"isStatic": false,
|
|
308
|
-
"returnTypeTokenRange": {
|
|
309
|
-
"startIndex": 7,
|
|
310
|
-
"endIndex": 8
|
|
311
|
-
},
|
|
312
|
-
"releaseTag": "Beta",
|
|
313
|
-
"isProtected": false,
|
|
314
|
-
"overloadIndex": 1,
|
|
315
|
-
"parameters": [
|
|
316
|
-
{
|
|
317
|
-
"parameterName": "e",
|
|
318
|
-
"parameterTypeTokenRange": {
|
|
319
|
-
"startIndex": 1,
|
|
320
|
-
"endIndex": 2
|
|
321
|
-
},
|
|
322
|
-
"isOptional": false
|
|
323
|
-
},
|
|
324
|
-
{
|
|
325
|
-
"parameterName": "info",
|
|
326
|
-
"parameterTypeTokenRange": {
|
|
327
|
-
"startIndex": 3,
|
|
328
|
-
"endIndex": 6
|
|
329
|
-
},
|
|
330
|
-
"isOptional": false
|
|
331
|
-
}
|
|
332
|
-
],
|
|
333
|
-
"isOptional": false,
|
|
334
|
-
"isAbstract": false,
|
|
335
|
-
"name": "updateCurrentTrack"
|
|
336
|
-
}
|
|
337
|
-
],
|
|
199
|
+
"members": [],
|
|
338
200
|
"extendsTokenRange": {
|
|
339
201
|
"startIndex": 1,
|
|
340
202
|
"endIndex": 2
|
|
@@ -2837,7 +2699,7 @@
|
|
|
2837
2699
|
{
|
|
2838
2700
|
"kind": "Method",
|
|
2839
2701
|
"canonicalReference": "@gcorevideo/player!MediaControl#getElement:member(1)",
|
|
2840
|
-
"docComment": "/**\n * Get a media control element DOM node\n *\n * @remarks\n *\n * Use this method to render custom media control UI in a plugin\n *\n * @param name - The name of the media control element\n *\n * @returns The DOM node to render to or extend\n *\n * @example\n * ```ts\n * class MyPlugin extends UICorePlugin {\n * override render() {\n * const mediaControl = this.core.getPlugin('media_control')\n * const clipText = mediaControl.getElement('clipText')\n * clipText?.el.text('Here we go')\n * return this\n * }\n * }\n * ```\n *\n */\n",
|
|
2702
|
+
"docComment": "/**\n * Get a media control element DOM node\n *\n * @remarks\n *\n * Use this method to render custom media control UI in a plugin\n *\n * @deprecated\n *\n * Use {@link MediaControl.putElement} instead\n *\n * @param name - The name of the media control element\n *\n * @returns The DOM node to render to or extend\n *\n * @example\n * ```ts\n * class MyPlugin extends UICorePlugin {\n * override render() {\n * const mediaControl = this.core.getPlugin('media_control')\n * const clipText = mediaControl.getElement('clipText')\n * clipText?.el.text('Here we go')\n * return this\n * }\n * }\n * ```\n *\n */\n",
|
|
2841
2703
|
"excerptTokens": [
|
|
2842
2704
|
{
|
|
2843
2705
|
"kind": "Content",
|
|
@@ -2980,6 +2842,72 @@
|
|
|
2980
2842
|
"isProtected": false,
|
|
2981
2843
|
"isAbstract": false
|
|
2982
2844
|
},
|
|
2845
|
+
{
|
|
2846
|
+
"kind": "Method",
|
|
2847
|
+
"canonicalReference": "@gcorevideo/player!MediaControl#putElement:member(1)",
|
|
2848
|
+
"docComment": "",
|
|
2849
|
+
"excerptTokens": [
|
|
2850
|
+
{
|
|
2851
|
+
"kind": "Content",
|
|
2852
|
+
"text": "putElement(name: "
|
|
2853
|
+
},
|
|
2854
|
+
{
|
|
2855
|
+
"kind": "Reference",
|
|
2856
|
+
"text": "MediaControlElement",
|
|
2857
|
+
"canonicalReference": "@gcorevideo/player!MediaControlElement:type"
|
|
2858
|
+
},
|
|
2859
|
+
{
|
|
2860
|
+
"kind": "Content",
|
|
2861
|
+
"text": ", element: "
|
|
2862
|
+
},
|
|
2863
|
+
{
|
|
2864
|
+
"kind": "Reference",
|
|
2865
|
+
"text": "ZeptoResult",
|
|
2866
|
+
"canonicalReference": "@gcorevideo/player!ZeptoResult:type"
|
|
2867
|
+
},
|
|
2868
|
+
{
|
|
2869
|
+
"kind": "Content",
|
|
2870
|
+
"text": "): "
|
|
2871
|
+
},
|
|
2872
|
+
{
|
|
2873
|
+
"kind": "Content",
|
|
2874
|
+
"text": "void"
|
|
2875
|
+
},
|
|
2876
|
+
{
|
|
2877
|
+
"kind": "Content",
|
|
2878
|
+
"text": ";"
|
|
2879
|
+
}
|
|
2880
|
+
],
|
|
2881
|
+
"isStatic": false,
|
|
2882
|
+
"returnTypeTokenRange": {
|
|
2883
|
+
"startIndex": 5,
|
|
2884
|
+
"endIndex": 6
|
|
2885
|
+
},
|
|
2886
|
+
"releaseTag": "Beta",
|
|
2887
|
+
"isProtected": false,
|
|
2888
|
+
"overloadIndex": 1,
|
|
2889
|
+
"parameters": [
|
|
2890
|
+
{
|
|
2891
|
+
"parameterName": "name",
|
|
2892
|
+
"parameterTypeTokenRange": {
|
|
2893
|
+
"startIndex": 1,
|
|
2894
|
+
"endIndex": 2
|
|
2895
|
+
},
|
|
2896
|
+
"isOptional": false
|
|
2897
|
+
},
|
|
2898
|
+
{
|
|
2899
|
+
"parameterName": "element",
|
|
2900
|
+
"parameterTypeTokenRange": {
|
|
2901
|
+
"startIndex": 3,
|
|
2902
|
+
"endIndex": 4
|
|
2903
|
+
},
|
|
2904
|
+
"isOptional": false
|
|
2905
|
+
}
|
|
2906
|
+
],
|
|
2907
|
+
"isOptional": false,
|
|
2908
|
+
"isAbstract": false,
|
|
2909
|
+
"name": "putElement"
|
|
2910
|
+
},
|
|
2983
2911
|
{
|
|
2984
2912
|
"kind": "Method",
|
|
2985
2913
|
"canonicalReference": "@gcorevideo/player!MediaControl#setInitialVolume:member(1)",
|
|
@@ -3123,7 +3051,7 @@
|
|
|
3123
3051
|
},
|
|
3124
3052
|
{
|
|
3125
3053
|
"kind": "Content",
|
|
3126
|
-
"text": "'audioTracksSelector' | '
|
|
3054
|
+
"text": "'audioTracksSelector' | 'clipText' | 'gear' | 'pip' | 'playbackRate' | 'seekBarContainer' | 'subtitlesSelector'"
|
|
3127
3055
|
},
|
|
3128
3056
|
{
|
|
3129
3057
|
"kind": "Content",
|
|
@@ -3602,7 +3530,38 @@
|
|
|
3602
3530
|
"isAbstract": false,
|
|
3603
3531
|
"name": "PictureInPicture",
|
|
3604
3532
|
"preserveMemberOrder": false,
|
|
3605
|
-
"members": [
|
|
3533
|
+
"members": [
|
|
3534
|
+
{
|
|
3535
|
+
"kind": "Property",
|
|
3536
|
+
"canonicalReference": "@gcorevideo/player!PictureInPicture#attributes:member",
|
|
3537
|
+
"docComment": "",
|
|
3538
|
+
"excerptTokens": [
|
|
3539
|
+
{
|
|
3540
|
+
"kind": "Content",
|
|
3541
|
+
"text": "get attributes(): "
|
|
3542
|
+
},
|
|
3543
|
+
{
|
|
3544
|
+
"kind": "Content",
|
|
3545
|
+
"text": "{\n class: string;\n }"
|
|
3546
|
+
},
|
|
3547
|
+
{
|
|
3548
|
+
"kind": "Content",
|
|
3549
|
+
"text": ";"
|
|
3550
|
+
}
|
|
3551
|
+
],
|
|
3552
|
+
"isReadonly": true,
|
|
3553
|
+
"isOptional": false,
|
|
3554
|
+
"releaseTag": "Beta",
|
|
3555
|
+
"name": "attributes",
|
|
3556
|
+
"propertyTypeTokenRange": {
|
|
3557
|
+
"startIndex": 1,
|
|
3558
|
+
"endIndex": 2
|
|
3559
|
+
},
|
|
3560
|
+
"isStatic": false,
|
|
3561
|
+
"isProtected": false,
|
|
3562
|
+
"isAbstract": false
|
|
3563
|
+
}
|
|
3564
|
+
],
|
|
3606
3565
|
"extendsTokenRange": {
|
|
3607
3566
|
"startIndex": 1,
|
|
3608
3567
|
"endIndex": 2
|