@gcorevideo/player 2.17.0 → 2.18.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.
Files changed (69) hide show
  1. package/dist/index.js +182 -109
  2. package/dist/player.d.ts +150 -24
  3. package/docs/api/player.containersize.md +19 -0
  4. package/docs/api/player.dashsettings.md +2 -0
  5. package/docs/api/player.errorlevel.md +1 -0
  6. package/docs/api/player.langtag.md +6 -0
  7. package/docs/api/player.md +57 -22
  8. package/docs/api/player.mediatransport.md +1 -0
  9. package/docs/api/player.playbackerror.code.md +2 -0
  10. package/docs/api/player.playbackerror.description.md +2 -0
  11. package/docs/api/player.playbackerror.level.md +2 -0
  12. package/docs/api/player.playbackerror.md +43 -4
  13. package/docs/api/player.playbackerror.message.md +2 -0
  14. package/docs/api/player.playbackerror.origin.md +21 -0
  15. package/docs/api/player.playbackerror.scope.md +16 -0
  16. package/docs/api/player.playbackerrorcode.md +4 -3
  17. package/docs/api/player.playbackmodule.md +1 -0
  18. package/docs/api/player.player.isdvrinuse.md +24 -0
  19. package/docs/api/player.player.isplaying.md +1 -1
  20. package/docs/api/player.player.md +15 -1
  21. package/docs/api/player.player.off.md +4 -4
  22. package/docs/api/player.player.on.md +5 -5
  23. package/docs/api/player.player.resize.md +3 -6
  24. package/docs/api/player.playercomponenttype.md +16 -0
  25. package/docs/api/player.playerdebugsettings.md +1 -1
  26. package/docs/api/player.playerdebugtag.md +1 -0
  27. package/docs/api/player.playerevent.md +96 -0
  28. package/docs/api/player.playereventhandler.md +3 -2
  29. package/docs/api/player.playereventparams.md +20 -0
  30. package/docs/api/player.playermediasourcedesc.md +1 -1
  31. package/docs/api/player.playermediasourcedesc.mimetype.md +1 -1
  32. package/docs/api/player.qualitylevel.bitrate.md +16 -0
  33. package/docs/api/player.qualitylevel.height.md +16 -0
  34. package/docs/api/player.qualitylevel.level.md +16 -0
  35. package/docs/api/player.qualitylevel.md +104 -7
  36. package/docs/api/player.qualitylevel.width.md +16 -0
  37. package/docs/api/player.timeposition.current.md +16 -0
  38. package/docs/api/player.timeposition.md +65 -7
  39. package/docs/api/player.timeposition.total.md +16 -0
  40. package/docs/api/player.timevalue.md +1 -1
  41. package/docs/api/player.translationsettings.md +7 -1
  42. package/docs/api/player.transportpreference.md +1 -0
  43. package/lib/Player.d.ts +30 -14
  44. package/lib/Player.d.ts.map +1 -1
  45. package/lib/Player.js +72 -65
  46. package/lib/internal.types.d.ts +3 -5
  47. package/lib/internal.types.d.ts.map +1 -1
  48. package/lib/playback/dash-playback/DashPlayback.d.ts +2 -0
  49. package/lib/playback/dash-playback/DashPlayback.d.ts.map +1 -1
  50. package/lib/playback/dash-playback/DashPlayback.js +37 -25
  51. package/lib/playback/hls-playback/HlsPlayback.d.ts +3 -0
  52. package/lib/playback/hls-playback/HlsPlayback.d.ts.map +1 -1
  53. package/lib/playback/hls-playback/HlsPlayback.js +33 -18
  54. package/lib/playback.types.d.ts +65 -6
  55. package/lib/playback.types.d.ts.map +1 -1
  56. package/lib/playback.types.js +10 -0
  57. package/lib/types.d.ts +54 -5
  58. package/lib/types.d.ts.map +1 -1
  59. package/lib/types.js +31 -2
  60. package/package.json +1 -1
  61. package/src/Player.ts +109 -78
  62. package/src/internal.types.ts +3 -2
  63. package/src/playback/dash-playback/DashPlayback.ts +64 -35
  64. package/src/playback/hls-playback/HlsPlayback.ts +46 -22
  65. package/src/playback.types.ts +65 -5
  66. package/src/types.ts +56 -6
  67. package/temp/player.api.json +611 -87
  68. package/tsconfig.tsbuildinfo +1 -1
  69. package/dist/DashPlayback-BRJzl8D8.js +0 -901
@@ -172,10 +172,36 @@
172
172
  "name": "",
173
173
  "preserveMemberOrder": false,
174
174
  "members": [
175
+ {
176
+ "kind": "TypeAlias",
177
+ "canonicalReference": "@gcorevideo/player!ContainerSize:type",
178
+ "docComment": "/**\n * Dimensions of the player container DOM element.\n *\n * @beta\n */\n",
179
+ "excerptTokens": [
180
+ {
181
+ "kind": "Content",
182
+ "text": "export type ContainerSize = "
183
+ },
184
+ {
185
+ "kind": "Content",
186
+ "text": "{\n width: number;\n height: number;\n}"
187
+ },
188
+ {
189
+ "kind": "Content",
190
+ "text": ";"
191
+ }
192
+ ],
193
+ "fileUrlPath": "src/types.ts",
194
+ "releaseTag": "Beta",
195
+ "name": "ContainerSize",
196
+ "typeTokenRange": {
197
+ "startIndex": 1,
198
+ "endIndex": 2
199
+ }
200
+ },
175
201
  {
176
202
  "kind": "TypeAlias",
177
203
  "canonicalReference": "@gcorevideo/player!DashSettings:type",
178
- "docComment": "/**\n * {@link https://cdn.dashjs.org/latest/jsdoc/module-Settings.html | DASH.js settings}\n *\n * @beta\n */\n",
204
+ "docComment": "/**\n * A plain JS object that must conform to the DASH.js settings schema.\n *\n * {@link https://cdn.dashjs.org/latest/jsdoc/module-Settings.html | DASH.js settings}\n *\n * @beta\n */\n",
179
205
  "excerptTokens": [
180
206
  {
181
207
  "kind": "Content",
@@ -206,7 +232,7 @@
206
232
  {
207
233
  "kind": "TypeAlias",
208
234
  "canonicalReference": "@gcorevideo/player!ErrorLevel:type",
209
- "docComment": "/**\n * @beta\n */\n",
235
+ "docComment": "/**\n * Levels of severity of errors. Non-fatal errors usually can be ignored.\n *\n * @beta\n */\n",
210
236
  "excerptTokens": [
211
237
  {
212
238
  "kind": "Content",
@@ -232,7 +258,7 @@
232
258
  {
233
259
  "kind": "TypeAlias",
234
260
  "canonicalReference": "@gcorevideo/player!LangTag:type",
235
- "docComment": "/**\n * @beta\n */\n",
261
+ "docComment": "/**\n * An ISO 639-1 language code.\n *\n * @example\n *\n * `pt`\n *\n * @beta\n */\n",
236
262
  "excerptTokens": [
237
263
  {
238
264
  "kind": "Content",
@@ -258,7 +284,7 @@
258
284
  {
259
285
  "kind": "TypeAlias",
260
286
  "canonicalReference": "@gcorevideo/player!MediaTransport:type",
261
- "docComment": "/**\n * @beta\n */\n",
287
+ "docComment": "/**\n * Media delivery protocol\n *\n * @beta\n */\n",
262
288
  "excerptTokens": [
263
289
  {
264
290
  "kind": "Content",
@@ -284,7 +310,7 @@
284
310
  {
285
311
  "kind": "Interface",
286
312
  "canonicalReference": "@gcorevideo/player!PlaybackError:interface",
287
- "docComment": "/**\n * @beta\n */\n",
313
+ "docComment": "/**\n * An error occurred during the playback.\n *\n * @beta\n */\n",
288
314
  "excerptTokens": [
289
315
  {
290
316
  "kind": "Content",
@@ -299,7 +325,7 @@
299
325
  {
300
326
  "kind": "PropertySignature",
301
327
  "canonicalReference": "@gcorevideo/player!PlaybackError#code:member",
302
- "docComment": "",
328
+ "docComment": "/**\n * Error code.\n */\n",
303
329
  "excerptTokens": [
304
330
  {
305
331
  "kind": "Content",
@@ -327,7 +353,7 @@
327
353
  {
328
354
  "kind": "PropertySignature",
329
355
  "canonicalReference": "@gcorevideo/player!PlaybackError#description:member",
330
- "docComment": "",
356
+ "docComment": "/**\n * Detailed description of the error.\n */\n",
331
357
  "excerptTokens": [
332
358
  {
333
359
  "kind": "Content",
@@ -354,7 +380,7 @@
354
380
  {
355
381
  "kind": "PropertySignature",
356
382
  "canonicalReference": "@gcorevideo/player!PlaybackError#level:member",
357
- "docComment": "",
383
+ "docComment": "/**\n * Level of severity of the error.\n */\n",
358
384
  "excerptTokens": [
359
385
  {
360
386
  "kind": "Content",
@@ -382,7 +408,7 @@
382
408
  {
383
409
  "kind": "PropertySignature",
384
410
  "canonicalReference": "@gcorevideo/player!PlaybackError#message:member",
385
- "docComment": "",
411
+ "docComment": "/**\n * Error message. Non-fatal usually can be ignored.\n */\n",
386
412
  "excerptTokens": [
387
413
  {
388
414
  "kind": "Content",
@@ -405,6 +431,61 @@
405
431
  "startIndex": 1,
406
432
  "endIndex": 2
407
433
  }
434
+ },
435
+ {
436
+ "kind": "PropertySignature",
437
+ "canonicalReference": "@gcorevideo/player!PlaybackError#origin:member",
438
+ "docComment": "/**\n * Exact component that originated the error.\n *\n * @example\n *\n * - 'core' - 'dash' - 'media_control'\n */\n",
439
+ "excerptTokens": [
440
+ {
441
+ "kind": "Content",
442
+ "text": "origin: "
443
+ },
444
+ {
445
+ "kind": "Content",
446
+ "text": "string"
447
+ },
448
+ {
449
+ "kind": "Content",
450
+ "text": ";"
451
+ }
452
+ ],
453
+ "isReadonly": false,
454
+ "isOptional": false,
455
+ "releaseTag": "Beta",
456
+ "name": "origin",
457
+ "propertyTypeTokenRange": {
458
+ "startIndex": 1,
459
+ "endIndex": 2
460
+ }
461
+ },
462
+ {
463
+ "kind": "PropertySignature",
464
+ "canonicalReference": "@gcorevideo/player!PlaybackError#scope:member",
465
+ "docComment": "/**\n * Component subsystem of the error origin\n */\n",
466
+ "excerptTokens": [
467
+ {
468
+ "kind": "Content",
469
+ "text": "scope: "
470
+ },
471
+ {
472
+ "kind": "Reference",
473
+ "text": "PlayerComponentType",
474
+ "canonicalReference": "@gcorevideo/player!PlayerComponentType:type"
475
+ },
476
+ {
477
+ "kind": "Content",
478
+ "text": ";"
479
+ }
480
+ ],
481
+ "isReadonly": false,
482
+ "isOptional": false,
483
+ "releaseTag": "Beta",
484
+ "name": "scope",
485
+ "propertyTypeTokenRange": {
486
+ "startIndex": 1,
487
+ "endIndex": 2
488
+ }
408
489
  }
409
490
  ],
410
491
  "extendsTokenRanges": []
@@ -412,7 +493,7 @@
412
493
  {
413
494
  "kind": "Enum",
414
495
  "canonicalReference": "@gcorevideo/player!PlaybackErrorCode:enum",
415
- "docComment": "/**\n * @beta\n */\n",
496
+ "docComment": "/**\n * Codes of errors occurring within the playback component.\n *\n * @beta\n */\n",
416
497
  "excerptTokens": [
417
498
  {
418
499
  "kind": "Content",
@@ -427,7 +508,7 @@
427
508
  {
428
509
  "kind": "EnumMember",
429
510
  "canonicalReference": "@gcorevideo/player!PlaybackErrorCode.Generic:member",
430
- "docComment": "",
511
+ "docComment": "/**\n * An unknown or uncategorised error.\n */\n",
431
512
  "excerptTokens": [
432
513
  {
433
514
  "kind": "Content",
@@ -448,7 +529,7 @@
448
529
  {
449
530
  "kind": "EnumMember",
450
531
  "canonicalReference": "@gcorevideo/player!PlaybackErrorCode.MediaSourceAccessDenied:member",
451
- "docComment": "",
532
+ "docComment": "/**\n * The media source is not accessible due to some protection policy.\n */\n",
452
533
  "excerptTokens": [
453
534
  {
454
535
  "kind": "Content",
@@ -469,7 +550,7 @@
469
550
  {
470
551
  "kind": "EnumMember",
471
552
  "canonicalReference": "@gcorevideo/player!PlaybackErrorCode.MediaSourceUnavailable:member",
472
- "docComment": "",
553
+ "docComment": "/**\n * The media source is not available. Typically a network error.\n */\n",
473
554
  "excerptTokens": [
474
555
  {
475
556
  "kind": "Content",
@@ -492,7 +573,7 @@
492
573
  {
493
574
  "kind": "TypeAlias",
494
575
  "canonicalReference": "@gcorevideo/player!PlaybackModule:type",
495
- "docComment": "/**\n * @beta\n */\n",
576
+ "docComment": "/**\n * Module to perform the playback.\n *\n * @beta\n */\n",
496
577
  "excerptTokens": [
497
578
  {
498
579
  "kind": "Content",
@@ -856,10 +937,41 @@
856
937
  "isAbstract": false,
857
938
  "name": "isDvrEnabled"
858
939
  },
940
+ {
941
+ "kind": "Method",
942
+ "canonicalReference": "@gcorevideo/player!Player#isDvrInUse:member(1)",
943
+ "docComment": "/**\n * Indicates whether DVR is in use.\n *\n * @remarks\n *\n * DVR mode, if it is enabled, is triggered we a user seeks behind the live edge.\n */\n",
944
+ "excerptTokens": [
945
+ {
946
+ "kind": "Content",
947
+ "text": "isDvrInUse(): "
948
+ },
949
+ {
950
+ "kind": "Content",
951
+ "text": "boolean"
952
+ },
953
+ {
954
+ "kind": "Content",
955
+ "text": ";"
956
+ }
957
+ ],
958
+ "isStatic": false,
959
+ "returnTypeTokenRange": {
960
+ "startIndex": 1,
961
+ "endIndex": 2
962
+ },
963
+ "releaseTag": "Beta",
964
+ "isProtected": false,
965
+ "overloadIndex": 1,
966
+ "parameters": [],
967
+ "isOptional": false,
968
+ "isAbstract": false,
969
+ "name": "isDvrInUse"
970
+ },
859
971
  {
860
972
  "kind": "Method",
861
973
  "canonicalReference": "@gcorevideo/player!Player#isPlaying:member(1)",
862
- "docComment": "/**\n * Indicates the playing state of the player.\n */\n",
974
+ "docComment": "/**\n * Indicates the playing state.\n */\n",
863
975
  "excerptTokens": [
864
976
  {
865
977
  "kind": "Content",
@@ -921,11 +1033,11 @@
921
1033
  {
922
1034
  "kind": "Method",
923
1035
  "canonicalReference": "@gcorevideo/player!Player#off:member(1)",
924
- "docComment": "/**\n * Removes a previously added event listener\n *\n * @param event - See {@link PlayerEvent}\n *\n * @param handler - See {@link PlayerEventHandler}\n */\n",
1036
+ "docComment": "/**\n * Removes a previously added event listener\n *\n * @param event - See {@link PlayerEvent}\n *\n * @param handler - a callback attached earlier to that event type\n */\n",
925
1037
  "excerptTokens": [
926
1038
  {
927
1039
  "kind": "Content",
928
- "text": "off<T extends "
1040
+ "text": "off<E extends "
929
1041
  },
930
1042
  {
931
1043
  "kind": "Reference",
@@ -938,7 +1050,7 @@
938
1050
  },
939
1051
  {
940
1052
  "kind": "Content",
941
- "text": "T"
1053
+ "text": "E"
942
1054
  },
943
1055
  {
944
1056
  "kind": "Content",
@@ -951,7 +1063,7 @@
951
1063
  },
952
1064
  {
953
1065
  "kind": "Content",
954
- "text": "<T>"
1066
+ "text": "<E>"
955
1067
  },
956
1068
  {
957
1069
  "kind": "Content",
@@ -968,7 +1080,7 @@
968
1080
  ],
969
1081
  "typeParameters": [
970
1082
  {
971
- "typeParameterName": "T",
1083
+ "typeParameterName": "E",
972
1084
  "constraintTokenRange": {
973
1085
  "startIndex": 1,
974
1086
  "endIndex": 2
@@ -1012,11 +1124,11 @@
1012
1124
  {
1013
1125
  "kind": "Method",
1014
1126
  "canonicalReference": "@gcorevideo/player!Player#on:member(1)",
1015
- "docComment": "/**\n * Adds a listener to a player event\n *\n * @param event - See {@link PlayerEvent}\n *\n * @param handler - See {@link PlayerEventHandler}\n */\n",
1127
+ "docComment": "/**\n * Adds a listener to a player event\n *\n * @param event - event type, see {@link PlayerEvent}\n *\n * @param handler - a callback function to handle the event\n */\n",
1016
1128
  "excerptTokens": [
1017
1129
  {
1018
1130
  "kind": "Content",
1019
- "text": "on<T extends "
1131
+ "text": "on<E extends "
1020
1132
  },
1021
1133
  {
1022
1134
  "kind": "Reference",
@@ -1029,7 +1141,7 @@
1029
1141
  },
1030
1142
  {
1031
1143
  "kind": "Content",
1032
- "text": "T"
1144
+ "text": "E"
1033
1145
  },
1034
1146
  {
1035
1147
  "kind": "Content",
@@ -1042,7 +1154,7 @@
1042
1154
  },
1043
1155
  {
1044
1156
  "kind": "Content",
1045
- "text": "<T>"
1157
+ "text": "<E>"
1046
1158
  },
1047
1159
  {
1048
1160
  "kind": "Content",
@@ -1059,7 +1171,7 @@
1059
1171
  ],
1060
1172
  "typeParameters": [
1061
1173
  {
1062
- "typeParameterName": "T",
1174
+ "typeParameterName": "E",
1063
1175
  "constraintTokenRange": {
1064
1176
  "startIndex": 1,
1065
1177
  "endIndex": 2
@@ -1214,15 +1326,16 @@
1214
1326
  {
1215
1327
  "kind": "Method",
1216
1328
  "canonicalReference": "@gcorevideo/player!Player#resize:member(1)",
1217
- "docComment": "/**\n * Resizes the player container element and everything within it.\n *\n * @remarks\n *\n * Use this method when the player itself does not detect the change in size of its container element. It can be a case for orientation change on some mobile devices.\n *\n * @param newSize - new size of the player\n */\n",
1329
+ "docComment": "/**\n * Resizes the player container element and everything within it.\n *\n * @remarks\n *\n * Use this method when the player itself does not detect properly the change in size of its container element. It can be a case for orientation change on some mobile devices.\n *\n * @param newSize - new size of the player\n */\n",
1218
1330
  "excerptTokens": [
1219
1331
  {
1220
1332
  "kind": "Content",
1221
1333
  "text": "resize(newSize: "
1222
1334
  },
1223
1335
  {
1224
- "kind": "Content",
1225
- "text": "{\n width: number;\n height: number;\n }"
1336
+ "kind": "Reference",
1337
+ "text": "ContainerSize",
1338
+ "canonicalReference": "@gcorevideo/player!ContainerSize:type"
1226
1339
  },
1227
1340
  {
1228
1341
  "kind": "Content",
@@ -1469,6 +1582,32 @@
1469
1582
  ],
1470
1583
  "implementsTokenRanges": []
1471
1584
  },
1585
+ {
1586
+ "kind": "TypeAlias",
1587
+ "canonicalReference": "@gcorevideo/player!PlayerComponentType:type",
1588
+ "docComment": "/**\n * Subsystems of a player component.\n *\n * @beta\n */\n",
1589
+ "excerptTokens": [
1590
+ {
1591
+ "kind": "Content",
1592
+ "text": "export type PlayerComponentType = "
1593
+ },
1594
+ {
1595
+ "kind": "Content",
1596
+ "text": "'container' | 'core' | 'playback'"
1597
+ },
1598
+ {
1599
+ "kind": "Content",
1600
+ "text": ";"
1601
+ }
1602
+ ],
1603
+ "fileUrlPath": "src/playback.types.ts",
1604
+ "releaseTag": "Beta",
1605
+ "name": "PlayerComponentType",
1606
+ "typeTokenRange": {
1607
+ "startIndex": 1,
1608
+ "endIndex": 2
1609
+ }
1610
+ },
1472
1611
  {
1473
1612
  "kind": "Interface",
1474
1613
  "canonicalReference": "@gcorevideo/player!PlayerConfig:interface",
@@ -1788,7 +1927,7 @@
1788
1927
  {
1789
1928
  "kind": "TypeAlias",
1790
1929
  "canonicalReference": "@gcorevideo/player!PlayerDebugSettings:type",
1791
- "docComment": "/**\n * @remarks\n *\n * true is equivalent to 'all', false is equivalent to 'none'\n *\n * @beta\n */\n",
1930
+ "docComment": "/**\n * @remarks\n *\n * `true` is equivalent to `'all'`, `false` is equivalent to `'none'`\n *\n * @beta\n */\n",
1792
1931
  "excerptTokens": [
1793
1932
  {
1794
1933
  "kind": "Content",
@@ -1819,7 +1958,7 @@
1819
1958
  {
1820
1959
  "kind": "TypeAlias",
1821
1960
  "canonicalReference": "@gcorevideo/player!PlayerDebugTag:type",
1822
- "docComment": "/**\n * @beta\n */\n",
1961
+ "docComment": "/**\n * Debug output category selector\n *\n * @beta\n */\n",
1823
1962
  "excerptTokens": [
1824
1963
  {
1825
1964
  "kind": "Content",
@@ -1878,6 +2017,48 @@
1878
2017
  "releaseTag": "Beta",
1879
2018
  "name": "Ended"
1880
2019
  },
2020
+ {
2021
+ "kind": "EnumMember",
2022
+ "canonicalReference": "@gcorevideo/player!PlayerEvent.Error:member",
2023
+ "docComment": "/**\n * An error occurred. Parameters: {@link PlaybackError}\n */\n",
2024
+ "excerptTokens": [
2025
+ {
2026
+ "kind": "Content",
2027
+ "text": "Error = "
2028
+ },
2029
+ {
2030
+ "kind": "Content",
2031
+ "text": "\"error\""
2032
+ }
2033
+ ],
2034
+ "initializerTokenRange": {
2035
+ "startIndex": 1,
2036
+ "endIndex": 2
2037
+ },
2038
+ "releaseTag": "Beta",
2039
+ "name": "Error"
2040
+ },
2041
+ {
2042
+ "kind": "EnumMember",
2043
+ "canonicalReference": "@gcorevideo/player!PlayerEvent.Fullscreen:member",
2044
+ "docComment": "/**\n * The player has switched to or from the fullscreen mode. Parameters:`boolean` isFullscreen\n */\n",
2045
+ "excerptTokens": [
2046
+ {
2047
+ "kind": "Content",
2048
+ "text": "Fullscreen = "
2049
+ },
2050
+ {
2051
+ "kind": "Content",
2052
+ "text": "\"fullscreen\""
2053
+ }
2054
+ ],
2055
+ "initializerTokenRange": {
2056
+ "startIndex": 1,
2057
+ "endIndex": 2
2058
+ },
2059
+ "releaseTag": "Beta",
2060
+ "name": "Fullscreen"
2061
+ },
1881
2062
  {
1882
2063
  "kind": "EnumMember",
1883
2064
  "canonicalReference": "@gcorevideo/player!PlayerEvent.Pause:member",
@@ -1941,6 +2122,48 @@
1941
2122
  "releaseTag": "Beta",
1942
2123
  "name": "Ready"
1943
2124
  },
2125
+ {
2126
+ "kind": "EnumMember",
2127
+ "canonicalReference": "@gcorevideo/player!PlayerEvent.Resize:member",
2128
+ "docComment": "/**\n * The player's container has been resized. Parameters: {@link ContainerSize}\n */\n",
2129
+ "excerptTokens": [
2130
+ {
2131
+ "kind": "Content",
2132
+ "text": "Resize = "
2133
+ },
2134
+ {
2135
+ "kind": "Content",
2136
+ "text": "\"resize\""
2137
+ }
2138
+ ],
2139
+ "initializerTokenRange": {
2140
+ "startIndex": 1,
2141
+ "endIndex": 2
2142
+ },
2143
+ "releaseTag": "Beta",
2144
+ "name": "Resize"
2145
+ },
2146
+ {
2147
+ "kind": "EnumMember",
2148
+ "canonicalReference": "@gcorevideo/player!PlayerEvent.Seek:member",
2149
+ "docComment": "/**\n * The player is seeking to a new position.\n */\n",
2150
+ "excerptTokens": [
2151
+ {
2152
+ "kind": "Content",
2153
+ "text": "Seek = "
2154
+ },
2155
+ {
2156
+ "kind": "Content",
2157
+ "text": "\"seek\""
2158
+ }
2159
+ ],
2160
+ "initializerTokenRange": {
2161
+ "startIndex": 1,
2162
+ "endIndex": 2
2163
+ },
2164
+ "releaseTag": "Beta",
2165
+ "name": "Seek"
2166
+ },
1944
2167
  {
1945
2168
  "kind": "EnumMember",
1946
2169
  "canonicalReference": "@gcorevideo/player!PlayerEvent.Stop:member",
@@ -1961,17 +2184,59 @@
1961
2184
  },
1962
2185
  "releaseTag": "Beta",
1963
2186
  "name": "Stop"
2187
+ },
2188
+ {
2189
+ "kind": "EnumMember",
2190
+ "canonicalReference": "@gcorevideo/player!PlayerEvent.TimeUpdate:member",
2191
+ "docComment": "/**\n * The current playback time has changed. Parameters: {@link TimePosition}\n */\n",
2192
+ "excerptTokens": [
2193
+ {
2194
+ "kind": "Content",
2195
+ "text": "TimeUpdate = "
2196
+ },
2197
+ {
2198
+ "kind": "Content",
2199
+ "text": "\"timeupdate\""
2200
+ }
2201
+ ],
2202
+ "initializerTokenRange": {
2203
+ "startIndex": 1,
2204
+ "endIndex": 2
2205
+ },
2206
+ "releaseTag": "Beta",
2207
+ "name": "TimeUpdate"
2208
+ },
2209
+ {
2210
+ "kind": "EnumMember",
2211
+ "canonicalReference": "@gcorevideo/player!PlayerEvent.VolumeUpdate:member",
2212
+ "docComment": "/**\n * The volume has changed. Parameters: `number` volume in the range 0..1\n */\n",
2213
+ "excerptTokens": [
2214
+ {
2215
+ "kind": "Content",
2216
+ "text": "VolumeUpdate = "
2217
+ },
2218
+ {
2219
+ "kind": "Content",
2220
+ "text": "\"volumeupdate\""
2221
+ }
2222
+ ],
2223
+ "initializerTokenRange": {
2224
+ "startIndex": 1,
2225
+ "endIndex": 2
2226
+ },
2227
+ "releaseTag": "Beta",
2228
+ "name": "VolumeUpdate"
1964
2229
  }
1965
2230
  ]
1966
2231
  },
1967
2232
  {
1968
2233
  "kind": "TypeAlias",
1969
2234
  "canonicalReference": "@gcorevideo/player!PlayerEventHandler:type",
1970
- "docComment": "/**\n * @beta\n */\n",
2235
+ "docComment": "/**\n * Type of a listener callback function for a player event. See the description of the event parameters in {@link PlayerEvent}.\n *\n * @beta\n */\n",
1971
2236
  "excerptTokens": [
1972
2237
  {
1973
2238
  "kind": "Content",
1974
- "text": "export type PlayerEventHandler<T extends "
2239
+ "text": "export type PlayerEventHandler<E extends "
1975
2240
  },
1976
2241
  {
1977
2242
  "kind": "Reference",
@@ -1984,7 +2249,16 @@
1984
2249
  },
1985
2250
  {
1986
2251
  "kind": "Content",
1987
- "text": "() => void"
2252
+ "text": "(...args: "
2253
+ },
2254
+ {
2255
+ "kind": "Reference",
2256
+ "text": "PlayerEventParams",
2257
+ "canonicalReference": "@gcorevideo/player!PlayerEventParams:type"
2258
+ },
2259
+ {
2260
+ "kind": "Content",
2261
+ "text": "<E>) => void"
1988
2262
  },
1989
2263
  {
1990
2264
  "kind": "Content",
@@ -1996,7 +2270,7 @@
1996
2270
  "name": "PlayerEventHandler",
1997
2271
  "typeParameters": [
1998
2272
  {
1999
- "typeParameterName": "T",
2273
+ "typeParameterName": "E",
2000
2274
  "constraintTokenRange": {
2001
2275
  "startIndex": 1,
2002
2276
  "endIndex": 2
@@ -2009,7 +2283,127 @@
2009
2283
  ],
2010
2284
  "typeTokenRange": {
2011
2285
  "startIndex": 3,
2012
- "endIndex": 4
2286
+ "endIndex": 6
2287
+ }
2288
+ },
2289
+ {
2290
+ "kind": "TypeAlias",
2291
+ "canonicalReference": "@gcorevideo/player!PlayerEventParams:type",
2292
+ "docComment": "/**\n * @beta\n */\n",
2293
+ "excerptTokens": [
2294
+ {
2295
+ "kind": "Content",
2296
+ "text": "export type PlayerEventParams<E extends "
2297
+ },
2298
+ {
2299
+ "kind": "Reference",
2300
+ "text": "PlayerEvent",
2301
+ "canonicalReference": "@gcorevideo/player!PlayerEvent:enum"
2302
+ },
2303
+ {
2304
+ "kind": "Content",
2305
+ "text": "> = "
2306
+ },
2307
+ {
2308
+ "kind": "Content",
2309
+ "text": "E extends "
2310
+ },
2311
+ {
2312
+ "kind": "Reference",
2313
+ "text": "PlayerEvent.Seek",
2314
+ "canonicalReference": "@gcorevideo/player!PlayerEvent.Seek:member"
2315
+ },
2316
+ {
2317
+ "kind": "Content",
2318
+ "text": " ? [number] : E extends "
2319
+ },
2320
+ {
2321
+ "kind": "Reference",
2322
+ "text": "PlayerEvent.VolumeUpdate",
2323
+ "canonicalReference": "@gcorevideo/player!PlayerEvent.VolumeUpdate:member"
2324
+ },
2325
+ {
2326
+ "kind": "Content",
2327
+ "text": " ? [number] : E extends "
2328
+ },
2329
+ {
2330
+ "kind": "Reference",
2331
+ "text": "PlayerEvent.TimeUpdate",
2332
+ "canonicalReference": "@gcorevideo/player!PlayerEvent.TimeUpdate:member"
2333
+ },
2334
+ {
2335
+ "kind": "Content",
2336
+ "text": " ? ["
2337
+ },
2338
+ {
2339
+ "kind": "Reference",
2340
+ "text": "TimePosition",
2341
+ "canonicalReference": "@gcorevideo/player!TimePosition:interface"
2342
+ },
2343
+ {
2344
+ "kind": "Content",
2345
+ "text": "] : E extends "
2346
+ },
2347
+ {
2348
+ "kind": "Reference",
2349
+ "text": "PlayerEvent.Resize",
2350
+ "canonicalReference": "@gcorevideo/player!PlayerEvent.Resize:member"
2351
+ },
2352
+ {
2353
+ "kind": "Content",
2354
+ "text": " ? [{\n width: number;\n height: number;\n}] : E extends "
2355
+ },
2356
+ {
2357
+ "kind": "Reference",
2358
+ "text": "PlayerEvent.Fullscreen",
2359
+ "canonicalReference": "@gcorevideo/player!PlayerEvent.Fullscreen:member"
2360
+ },
2361
+ {
2362
+ "kind": "Content",
2363
+ "text": " ? [boolean] : E extends "
2364
+ },
2365
+ {
2366
+ "kind": "Reference",
2367
+ "text": "PlayerEvent.Error",
2368
+ "canonicalReference": "@gcorevideo/player!PlayerEvent.Error:member"
2369
+ },
2370
+ {
2371
+ "kind": "Content",
2372
+ "text": " ? ["
2373
+ },
2374
+ {
2375
+ "kind": "Reference",
2376
+ "text": "PlaybackError",
2377
+ "canonicalReference": "@gcorevideo/player!PlaybackError:interface"
2378
+ },
2379
+ {
2380
+ "kind": "Content",
2381
+ "text": "] : []"
2382
+ },
2383
+ {
2384
+ "kind": "Content",
2385
+ "text": ";"
2386
+ }
2387
+ ],
2388
+ "fileUrlPath": "src/Player.ts",
2389
+ "releaseTag": "Beta",
2390
+ "name": "PlayerEventParams",
2391
+ "typeParameters": [
2392
+ {
2393
+ "typeParameterName": "E",
2394
+ "constraintTokenRange": {
2395
+ "startIndex": 1,
2396
+ "endIndex": 2
2397
+ },
2398
+ "defaultTypeTokenRange": {
2399
+ "startIndex": 0,
2400
+ "endIndex": 0
2401
+ }
2402
+ }
2403
+ ],
2404
+ "typeTokenRange": {
2405
+ "startIndex": 3,
2406
+ "endIndex": 20
2013
2407
  }
2014
2408
  },
2015
2409
  {
@@ -2061,7 +2455,7 @@
2061
2455
  {
2062
2456
  "kind": "PropertySignature",
2063
2457
  "canonicalReference": "@gcorevideo/player!PlayerMediaSourceDesc#mimeType:member",
2064
- "docComment": "/**\n * The MIME type of the media source (e.g. \"video/mp4\", \"application/x-mpegURL\")\n */\n",
2458
+ "docComment": "/**\n * The MIME type of the media source (e.g. `\"video/mp4\"`, `\"application/x-mpegURL\"`). Necessary if the type cannot be detected from file extension of the source URL.\n */\n",
2065
2459
  "excerptTokens": [
2066
2460
  {
2067
2461
  "kind": "Content",
@@ -2142,74 +2536,204 @@
2142
2536
  }
2143
2537
  },
2144
2538
  {
2145
- "kind": "TypeAlias",
2146
- "canonicalReference": "@gcorevideo/player!QualityLevel:type",
2147
- "docComment": "/**\n * @beta\n */\n",
2539
+ "kind": "Interface",
2540
+ "canonicalReference": "@gcorevideo/player!QualityLevel:interface",
2541
+ "docComment": "/**\n * A level of quality within a media source.\n *\n * @beta\n */\n",
2148
2542
  "excerptTokens": [
2149
2543
  {
2150
2544
  "kind": "Content",
2151
- "text": "export type QualityLevel = "
2152
- },
2153
- {
2154
- "kind": "Content",
2155
- "text": "{\n level: number;\n width: number;\n height: number;\n bitrate: number;\n}"
2156
- },
2157
- {
2158
- "kind": "Content",
2159
- "text": ";"
2545
+ "text": "export interface QualityLevel "
2160
2546
  }
2161
2547
  ],
2162
2548
  "fileUrlPath": "src/playback.types.ts",
2163
2549
  "releaseTag": "Beta",
2164
2550
  "name": "QualityLevel",
2165
- "typeTokenRange": {
2166
- "startIndex": 1,
2167
- "endIndex": 2
2168
- }
2169
- },
2170
- {
2171
- "kind": "TypeAlias",
2172
- "canonicalReference": "@gcorevideo/player!TimePosition:type",
2173
- "docComment": "/**\n * For the plugin development\n *\n * @beta\n */\n",
2174
- "excerptTokens": [
2175
- {
2176
- "kind": "Content",
2177
- "text": "export type TimePosition = "
2178
- },
2179
- {
2180
- "kind": "Content",
2181
- "text": "{\n current: "
2182
- },
2551
+ "preserveMemberOrder": false,
2552
+ "members": [
2183
2553
  {
2184
- "kind": "Reference",
2185
- "text": "TimeValue",
2186
- "canonicalReference": "@gcorevideo/player!TimeValue:type"
2554
+ "kind": "PropertySignature",
2555
+ "canonicalReference": "@gcorevideo/player!QualityLevel#bitrate:member",
2556
+ "docComment": "/**\n * Bitrate of the video, bps.\n */\n",
2557
+ "excerptTokens": [
2558
+ {
2559
+ "kind": "Content",
2560
+ "text": "bitrate: "
2561
+ },
2562
+ {
2563
+ "kind": "Content",
2564
+ "text": "number"
2565
+ },
2566
+ {
2567
+ "kind": "Content",
2568
+ "text": ";"
2569
+ }
2570
+ ],
2571
+ "isReadonly": false,
2572
+ "isOptional": false,
2573
+ "releaseTag": "Beta",
2574
+ "name": "bitrate",
2575
+ "propertyTypeTokenRange": {
2576
+ "startIndex": 1,
2577
+ "endIndex": 2
2578
+ }
2187
2579
  },
2188
2580
  {
2189
- "kind": "Content",
2190
- "text": ";\n total: "
2581
+ "kind": "PropertySignature",
2582
+ "canonicalReference": "@gcorevideo/player!QualityLevel#height:member",
2583
+ "docComment": "/**\n * Height of the video, pixels.\n */\n",
2584
+ "excerptTokens": [
2585
+ {
2586
+ "kind": "Content",
2587
+ "text": "height: "
2588
+ },
2589
+ {
2590
+ "kind": "Content",
2591
+ "text": "number"
2592
+ },
2593
+ {
2594
+ "kind": "Content",
2595
+ "text": ";"
2596
+ }
2597
+ ],
2598
+ "isReadonly": false,
2599
+ "isOptional": false,
2600
+ "releaseTag": "Beta",
2601
+ "name": "height",
2602
+ "propertyTypeTokenRange": {
2603
+ "startIndex": 1,
2604
+ "endIndex": 2
2605
+ }
2191
2606
  },
2192
2607
  {
2193
- "kind": "Reference",
2194
- "text": "TimeValue",
2195
- "canonicalReference": "@gcorevideo/player!TimeValue:type"
2608
+ "kind": "PropertySignature",
2609
+ "canonicalReference": "@gcorevideo/player!QualityLevel#level:member",
2610
+ "docComment": "/**\n * Zero-based index of the quality level.\n */\n",
2611
+ "excerptTokens": [
2612
+ {
2613
+ "kind": "Content",
2614
+ "text": "level: "
2615
+ },
2616
+ {
2617
+ "kind": "Content",
2618
+ "text": "number"
2619
+ },
2620
+ {
2621
+ "kind": "Content",
2622
+ "text": ";"
2623
+ }
2624
+ ],
2625
+ "isReadonly": false,
2626
+ "isOptional": false,
2627
+ "releaseTag": "Beta",
2628
+ "name": "level",
2629
+ "propertyTypeTokenRange": {
2630
+ "startIndex": 1,
2631
+ "endIndex": 2
2632
+ }
2196
2633
  },
2197
2634
  {
2198
- "kind": "Content",
2199
- "text": ";\n}"
2200
- },
2635
+ "kind": "PropertySignature",
2636
+ "canonicalReference": "@gcorevideo/player!QualityLevel#width:member",
2637
+ "docComment": "/**\n * Width of the video, pixels.\n */\n",
2638
+ "excerptTokens": [
2639
+ {
2640
+ "kind": "Content",
2641
+ "text": "width: "
2642
+ },
2643
+ {
2644
+ "kind": "Content",
2645
+ "text": "number"
2646
+ },
2647
+ {
2648
+ "kind": "Content",
2649
+ "text": ";"
2650
+ }
2651
+ ],
2652
+ "isReadonly": false,
2653
+ "isOptional": false,
2654
+ "releaseTag": "Beta",
2655
+ "name": "width",
2656
+ "propertyTypeTokenRange": {
2657
+ "startIndex": 1,
2658
+ "endIndex": 2
2659
+ }
2660
+ }
2661
+ ],
2662
+ "extendsTokenRanges": []
2663
+ },
2664
+ {
2665
+ "kind": "Interface",
2666
+ "canonicalReference": "@gcorevideo/player!TimePosition:interface",
2667
+ "docComment": "/**\n * Current playback time and total duration of the media.\n *\n * @beta\n */\n",
2668
+ "excerptTokens": [
2201
2669
  {
2202
2670
  "kind": "Content",
2203
- "text": ";"
2671
+ "text": "export interface TimePosition "
2204
2672
  }
2205
2673
  ],
2206
2674
  "fileUrlPath": "src/playback.types.ts",
2207
2675
  "releaseTag": "Beta",
2208
2676
  "name": "TimePosition",
2209
- "typeTokenRange": {
2210
- "startIndex": 1,
2211
- "endIndex": 6
2212
- }
2677
+ "preserveMemberOrder": false,
2678
+ "members": [
2679
+ {
2680
+ "kind": "PropertySignature",
2681
+ "canonicalReference": "@gcorevideo/player!TimePosition#current:member",
2682
+ "docComment": "/**\n * Current playback time, 0..duration, seconds.\n */\n",
2683
+ "excerptTokens": [
2684
+ {
2685
+ "kind": "Content",
2686
+ "text": "current: "
2687
+ },
2688
+ {
2689
+ "kind": "Reference",
2690
+ "text": "TimeValue",
2691
+ "canonicalReference": "@gcorevideo/player!TimeValue:type"
2692
+ },
2693
+ {
2694
+ "kind": "Content",
2695
+ "text": ";"
2696
+ }
2697
+ ],
2698
+ "isReadonly": false,
2699
+ "isOptional": false,
2700
+ "releaseTag": "Beta",
2701
+ "name": "current",
2702
+ "propertyTypeTokenRange": {
2703
+ "startIndex": 1,
2704
+ "endIndex": 2
2705
+ }
2706
+ },
2707
+ {
2708
+ "kind": "PropertySignature",
2709
+ "canonicalReference": "@gcorevideo/player!TimePosition#total:member",
2710
+ "docComment": "/**\n * Total duration of the media, seconds.\n */\n",
2711
+ "excerptTokens": [
2712
+ {
2713
+ "kind": "Content",
2714
+ "text": "total: "
2715
+ },
2716
+ {
2717
+ "kind": "Reference",
2718
+ "text": "TimeValue",
2719
+ "canonicalReference": "@gcorevideo/player!TimeValue:type"
2720
+ },
2721
+ {
2722
+ "kind": "Content",
2723
+ "text": ";"
2724
+ }
2725
+ ],
2726
+ "isReadonly": false,
2727
+ "isOptional": false,
2728
+ "releaseTag": "Beta",
2729
+ "name": "total",
2730
+ "propertyTypeTokenRange": {
2731
+ "startIndex": 1,
2732
+ "endIndex": 2
2733
+ }
2734
+ }
2735
+ ],
2736
+ "extendsTokenRanges": []
2213
2737
  },
2214
2738
  {
2215
2739
  "kind": "TypeAlias",
@@ -2223,7 +2747,7 @@
2223
2747
  {
2224
2748
  "kind": "Reference",
2225
2749
  "text": "TimePosition",
2226
- "canonicalReference": "@gcorevideo/player!TimePosition:type"
2750
+ "canonicalReference": "@gcorevideo/player!TimePosition:interface"
2227
2751
  },
2228
2752
  {
2229
2753
  "kind": "Content",
@@ -2254,7 +2778,7 @@
2254
2778
  {
2255
2779
  "kind": "Reference",
2256
2780
  "text": "TimePosition",
2257
- "canonicalReference": "@gcorevideo/player!TimePosition:type"
2781
+ "canonicalReference": "@gcorevideo/player!TimePosition:interface"
2258
2782
  },
2259
2783
  {
2260
2784
  "kind": "Content",
@@ -2276,7 +2800,7 @@
2276
2800
  {
2277
2801
  "kind": "TypeAlias",
2278
2802
  "canonicalReference": "@gcorevideo/player!TimeValue:type",
2279
- "docComment": "/**\n * Playback time in seconds since the beginning of the stream (or a segment for the live streams) For the plugin development\n *\n * @beta\n */\n",
2803
+ "docComment": "/**\n * Playback time in seconds since the beginning of the stream (or a segment for the live streams)\n *\n * @beta\n */\n",
2280
2804
  "excerptTokens": [
2281
2805
  {
2282
2806
  "kind": "Content",
@@ -2328,7 +2852,7 @@
2328
2852
  {
2329
2853
  "kind": "TypeAlias",
2330
2854
  "canonicalReference": "@gcorevideo/player!TranslationSettings:type",
2331
- "docComment": "/**\n * [language][key] =\\> string\n *\n * @example\n * ```\n * {\n * en: {\n * play: 'Play',\n * ...\n * },\n * es: {\n * play: 'Reproducir',\n * ...\n * },\n * ...\n * }\n * ```\n *\n * @beta\n */\n",
2855
+ "docComment": "/**\n * Localization strings for the player UI.\n *\n * @remarks\n *\n * The keys are language codes, and the values are objects with keys being the translation keys and values being the translations.\n *\n * This dictionary is used to localize the player UI, including the error messages and is shared across all the player components (including the plugins).\n *\n * @example\n * ```\n * {\n * en: {\n * play: 'Play',\n * ...\n * },\n * es: {\n * play: 'Reproducir',\n * ...\n * },\n * ...\n * }\n * ```\n *\n * @beta\n */\n",
2332
2856
  "excerptTokens": [
2333
2857
  {
2334
2858
  "kind": "Content",
@@ -2395,7 +2919,7 @@
2395
2919
  {
2396
2920
  "kind": "TypeAlias",
2397
2921
  "canonicalReference": "@gcorevideo/player!TransportPreference:type",
2398
- "docComment": "/**\n * @beta\n */\n",
2922
+ "docComment": "/**\n * Preferred media delivery protocol\n *\n * @beta\n */\n",
2399
2923
  "excerptTokens": [
2400
2924
  {
2401
2925
  "kind": "Content",