@flowplayer/player 3.15.0 → 3.16.0-rc

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 (58) hide show
  1. package/core/events.d.ts +22 -2
  2. package/core/events.js +50 -50
  3. package/core.js +1 -1
  4. package/default.js +1 -1
  5. package/embed.js +2 -2
  6. package/flowplayer.css +1 -1
  7. package/index.d.ts +78 -35
  8. package/package.json +1 -1
  9. package/plugins/ads.d.ts +76 -33
  10. package/plugins/ads.js +1 -1
  11. package/plugins/airplay.d.ts +77 -52
  12. package/plugins/analytics.d.ts +76 -33
  13. package/plugins/analytics.js +1 -1
  14. package/plugins/asel.d.ts +221 -36
  15. package/plugins/asel.js +1 -1
  16. package/plugins/audio.d.ts +76 -33
  17. package/plugins/chapters.d.ts +76 -33
  18. package/plugins/chromecast.d.ts +76 -33
  19. package/plugins/chromecast.js +1 -1
  20. package/plugins/comscore.d.ts +76 -33
  21. package/plugins/consent.d.ts +76 -33
  22. package/plugins/context-menu.d.ts +76 -33
  23. package/plugins/cuepoints.d.ts +76 -33
  24. package/plugins/dash.d.ts +77 -45
  25. package/plugins/dash.js +1 -1
  26. package/plugins/drm.d.ts +76 -33
  27. package/plugins/endscreen.d.ts +76 -33
  28. package/plugins/fas.d.ts +76 -33
  29. package/plugins/float-on-scroll.d.ts +76 -33
  30. package/plugins/ga4.d.ts +76 -33
  31. package/plugins/gemius.d.ts +76 -33
  32. package/plugins/google-analytics.d.ts +76 -33
  33. package/plugins/health.d.ts +76 -33
  34. package/plugins/health.js +1 -1
  35. package/plugins/hls.d.ts +76 -33
  36. package/plugins/hls.js +1 -1
  37. package/plugins/id3.d.ts +76 -33
  38. package/plugins/iframe.d.ts +76 -33
  39. package/plugins/keyboard.d.ts +76 -33
  40. package/plugins/media-session.d.ts +76 -33
  41. package/plugins/message.d.ts +76 -33
  42. package/plugins/ovp.d.ts +76 -33
  43. package/plugins/playlist.d.ts +107 -33
  44. package/plugins/playlist.js +1 -1
  45. package/plugins/preview.d.ts +76 -33
  46. package/plugins/qsel.d.ts +76 -33
  47. package/plugins/qul.d.ts +76 -33
  48. package/plugins/rts.d.ts +76 -33
  49. package/plugins/share.d.ts +76 -33
  50. package/plugins/speed.d.ts +76 -33
  51. package/plugins/ssai.d.ts +76 -33
  52. package/plugins/ssai.js +1 -1
  53. package/plugins/subtitles.d.ts +76 -33
  54. package/plugins/thumbnails.d.ts +76 -33
  55. package/plugins/tizen.d.ts +76 -33
  56. package/plugins/vtsel.d.ts +76 -33
  57. package/plugins/webos.d.ts +76 -33
  58. package/util/loader.d.ts +76 -33
@@ -344,6 +344,7 @@ declare type ErrorEventDetail = {
344
344
  declare namespace events {
345
345
  export {
346
346
  MOUNT,
347
+ RETRY,
347
348
  ERROR,
348
349
  CONTEXT_MENU,
349
350
  CLICK,
@@ -395,7 +396,8 @@ declare namespace events {
395
396
  LANDSCAPE,
396
397
  PORTRAIT,
397
398
  DVR,
398
- LIVE_2 as LIVE
399
+ LIVE,
400
+ RECOVER
399
401
  }
400
402
  }
401
403
 
@@ -594,8 +596,6 @@ declare const /**
594
596
  */
595
597
  LANDSCAPE = "landscape";
596
598
 
597
- declare const LIVE = "is-live";
598
-
599
599
  /**
600
600
  * @public
601
601
  * when src is a livestream
@@ -607,7 +607,9 @@ declare const /**
607
607
  * @public
608
608
  * when src is a livestream
609
609
  */
610
- LIVE_2 = "live";
610
+ LIVE = "live";
611
+
612
+ declare const LIVE_2 = "is-live";
611
613
 
612
614
  declare const LIVE_SEEKED = "is-live-seeked";
613
615
 
@@ -907,33 +909,27 @@ declare type Player = HTMLVideoElement & PlayerEventOverloads & {
907
909
 
908
910
  declare type PlayerCustomEventName = keyof PlayerCustomEventsDetailMap;
909
911
 
910
- declare type PlayerCustomEventsDetailMap = {
911
- [MOUNT]: MountEventDetail;
912
- [ERROR]: ErrorEventDetail;
913
- [CONTEXT_MENU]: ContextMenuEventDetail;
914
- /* Excluded from this release type: beforeplay */
915
- /* Excluded from this release type: beforepause */
916
- /* Excluded from this release type: state */
912
+ declare type PlayerCustomEventsDetailMap = PlayerEmittableCustomEventsDetailMap & {
913
+ [REAP]: ReapEventDetail;
914
+ [SOURCE]: SourceEventDetail;
917
915
  [CUEPOINT_START]: CuePointStartEventDetail;
918
916
  [CUEPOINT_END]: CuePointEndEventDetail;
919
- [VIEW_ENTER]: ViewEnterEventDetail;
920
- [VIEW_LEAVE]: ViewLeaveEventDetail;
921
- [SOURCE]: SourceEventDetail;
922
- /* Excluded from this release type: recover */
923
- [REAP]: ReapEventDetail;
924
- /* Excluded from this release type: config */
925
- [QUALITIES]: QualitiesEventDetail;
926
- /* Excluded from this release type: "error:fatal" */
927
- [RECOMMENDATIONS_READY]: RecommendationsReadyEventDetail;
917
+ [MOUNT]: MountEventDetail;
918
+ [LIVE]: LiveEventDetail;
919
+ [DVR]: DvrEventDetail;
920
+ [RETRY]: RetryEventDetail;
921
+ [RECOVER]: RecoverEventDetail;
928
922
  /* Excluded from this release type: audioonlysource */
929
923
  /* Excluded from this release type: renderplugin */
930
- [DVR]: DvrEventDetail;
931
- [LIVE_2]: LiveEventDetail;
932
924
  /* Excluded from this release type: "seek:queued" */
933
925
  /* Excluded from this release type: "seek:cancel" */
934
926
  /* Excluded from this release type: "plugin:registered" */
935
927
  /* Excluded from this release type: intersectionchange */
936
- /* Excluded from this release type: retry */
928
+ /* Excluded from this release type: beforeplay */
929
+ /* Excluded from this release type: beforepause */
930
+ /* Excluded from this release type: state */
931
+ /* Excluded from this release type: config */
932
+ /* Excluded from this release type: "error:fatal" */
937
933
  };
938
934
 
939
935
  declare type PlayerCustomEventsOverloads = {
@@ -972,11 +968,18 @@ declare type PlayerCustomEventsOverloads = {
972
968
  * Sent right before the player src attribute is set. This allows you to change the video URL before playback.
973
969
  */
974
970
  on(event: typeof SOURCE, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof SOURCE]>) => void): Player;
975
- /* Excluded from this release type: on */
971
+ /**
972
+ * Emitted when an Error recovery is attempted
973
+ */
974
+ on(event: typeof RECOVER, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof RECOVER]>) => void): Player;
976
975
  /**
977
976
  * 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.
978
977
  */
979
978
  on(event: typeof REAP, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof REAP]>) => void): Player;
979
+ /**
980
+ * Emitted when a player will retry to reload
981
+ */
982
+ on(event: typeof RETRY, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof RETRY]>) => void): Player;
980
983
  /* Excluded from this release type: on */
981
984
  /**
982
985
  * Emitted when the set of underlying qualities has changed.
@@ -996,8 +999,7 @@ declare type PlayerCustomEventsOverloads = {
996
999
  /**
997
1000
  * when src is a livestream
998
1001
  */
999
- on(event: typeof LIVE_2, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof LIVE_2]>) => void): Player;
1000
- /* Excluded from this release type: on */
1002
+ on(event: typeof LIVE, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof LIVE]>) => void): Player;
1001
1003
  /* Excluded from this release type: on */
1002
1004
  /* Excluded from this release type: on */
1003
1005
  /* Excluded from this release type: on */
@@ -1026,11 +1028,26 @@ declare type PlayerCustomEventsOverloads = {
1026
1028
  */
1027
1029
  off<T>(event: string, handler: (e: FPEvent<T>) => void): Player;
1028
1030
  /* Excluded from this release type: poll */
1029
- emit<T extends PlayerCustomEventName>(event: T, data?: PlayerCustomEventsDetailMap[T]): Player;
1030
1031
  /* Excluded from this release type: emit */
1031
- emit<T, X extends string = string>(event: X & (X extends PlayerCustomEventName ? "Incorrect event detail type" : X), data?: T): Player;
1032
+ /* Excluded from this release type: emit */
1033
+ emit<T extends PlayerEmittableEventNames>(event: T, data?: PlayerCustomEventsDetailMap[T]): Player;
1034
+ /* Excluded from this release type: emit */
1035
+ };
1036
+
1037
+ declare type PlayerEmittableCustomEventsDetailMap = {
1038
+ [ERROR]: ErrorEventDetail;
1039
+ [CONTEXT_MENU]: ContextMenuEventDetail;
1040
+ [VIEW_ENTER]: ViewEnterEventDetail;
1041
+ [VIEW_LEAVE]: ViewLeaveEventDetail;
1042
+ [QUALITIES]: QualitiesEventDetail;
1043
+ [RECOMMENDATIONS_READY]: RecommendationsReadyEventDetail;
1032
1044
  };
1033
1045
 
1046
+ declare type PlayerEmittableEventNames = keyof PlayerEmittableCustomEventsDetailMap;
1047
+
1048
+ /**
1049
+ * @public
1050
+ */
1034
1051
  declare type PlayerEventOverloads = PlayerNativeEventsOverloads & PlayerCustomEventsOverloads;
1035
1052
 
1036
1053
  declare type PlayerNativeEventName = keyof PlayerNativeEventsDetailMap;
@@ -1224,9 +1241,23 @@ declare type RecommendationsReadyEventDetail = {
1224
1241
  playlist: RecommendationItem[];
1225
1242
  };
1226
1243
 
1227
- /* Excluded from this release type: RECOVER */
1244
+ /**
1245
+ * @public
1246
+ * emitted when an Error recovery is attempted
1247
+ */
1248
+ declare const /**
1249
+ @public
1250
+ * when a new player is inserted into the HTML
1251
+ */ /**
1252
+ * @public
1253
+ * emitted when an Error recovery is attempted
1254
+ */
1255
+ RECOVER = "recover";
1228
1256
 
1229
- /* Excluded from this release type: RecoverEventDetail */
1257
+ /**
1258
+ * @public
1259
+ */
1260
+ declare type RecoverEventDetail = null;
1230
1261
 
1231
1262
  /* Excluded from this release type: REMOTE_SESSION_ENDED */
1232
1263
 
@@ -1250,9 +1281,21 @@ declare const /**
1250
1281
  */
1251
1282
  RESIZE = "resize";
1252
1283
 
1253
- /* Excluded from this release type: RETRY */
1284
+ /**
1285
+ * @public
1286
+ */
1287
+ declare const /**
1288
+ @public
1289
+ * when a new player is inserted into the HTML
1290
+ */ /**
1291
+ * @public
1292
+ */
1293
+ RETRY = "retry";
1254
1294
 
1255
- /* Excluded from this release type: RetryEventDetail */
1295
+ /**
1296
+ * @public
1297
+ */
1298
+ declare type RetryEventDetail = null;
1256
1299
 
1257
1300
  declare const RTL = "is-rtl";
1258
1301
 
@@ -1395,7 +1438,7 @@ declare namespace states {
1395
1438
  RTL,
1396
1439
  TV,
1397
1440
  ENDED,
1398
- LIVE,
1441
+ LIVE_2 as LIVE,
1399
1442
  ERRORED,
1400
1443
  WAITING,
1401
1444
  AUTOPLAY,
@@ -344,6 +344,7 @@ declare type ErrorEventDetail = {
344
344
  declare namespace events {
345
345
  export {
346
346
  MOUNT,
347
+ RETRY,
347
348
  ERROR,
348
349
  CONTEXT_MENU,
349
350
  CLICK,
@@ -395,7 +396,8 @@ declare namespace events {
395
396
  LANDSCAPE,
396
397
  PORTRAIT,
397
398
  DVR,
398
- LIVE_2 as LIVE
399
+ LIVE,
400
+ RECOVER
399
401
  }
400
402
  }
401
403
 
@@ -594,8 +596,6 @@ declare const /**
594
596
  */
595
597
  LANDSCAPE = "landscape";
596
598
 
597
- declare const LIVE = "is-live";
598
-
599
599
  /**
600
600
  * @public
601
601
  * when src is a livestream
@@ -607,7 +607,9 @@ declare const /**
607
607
  * @public
608
608
  * when src is a livestream
609
609
  */
610
- LIVE_2 = "live";
610
+ LIVE = "live";
611
+
612
+ declare const LIVE_2 = "is-live";
611
613
 
612
614
  declare const LIVE_SEEKED = "is-live-seeked";
613
615
 
@@ -907,33 +909,27 @@ declare type Player = HTMLVideoElement & PlayerEventOverloads & {
907
909
 
908
910
  declare type PlayerCustomEventName = keyof PlayerCustomEventsDetailMap;
909
911
 
910
- declare type PlayerCustomEventsDetailMap = {
911
- [MOUNT]: MountEventDetail;
912
- [ERROR]: ErrorEventDetail;
913
- [CONTEXT_MENU]: ContextMenuEventDetail;
914
- /* Excluded from this release type: beforeplay */
915
- /* Excluded from this release type: beforepause */
916
- /* Excluded from this release type: state */
912
+ declare type PlayerCustomEventsDetailMap = PlayerEmittableCustomEventsDetailMap & {
913
+ [REAP]: ReapEventDetail;
914
+ [SOURCE]: SourceEventDetail;
917
915
  [CUEPOINT_START]: CuePointStartEventDetail;
918
916
  [CUEPOINT_END]: CuePointEndEventDetail;
919
- [VIEW_ENTER]: ViewEnterEventDetail;
920
- [VIEW_LEAVE]: ViewLeaveEventDetail;
921
- [SOURCE]: SourceEventDetail;
922
- /* Excluded from this release type: recover */
923
- [REAP]: ReapEventDetail;
924
- /* Excluded from this release type: config */
925
- [QUALITIES]: QualitiesEventDetail;
926
- /* Excluded from this release type: "error:fatal" */
927
- [RECOMMENDATIONS_READY]: RecommendationsReadyEventDetail;
917
+ [MOUNT]: MountEventDetail;
918
+ [LIVE]: LiveEventDetail;
919
+ [DVR]: DvrEventDetail;
920
+ [RETRY]: RetryEventDetail;
921
+ [RECOVER]: RecoverEventDetail;
928
922
  /* Excluded from this release type: audioonlysource */
929
923
  /* Excluded from this release type: renderplugin */
930
- [DVR]: DvrEventDetail;
931
- [LIVE_2]: LiveEventDetail;
932
924
  /* Excluded from this release type: "seek:queued" */
933
925
  /* Excluded from this release type: "seek:cancel" */
934
926
  /* Excluded from this release type: "plugin:registered" */
935
927
  /* Excluded from this release type: intersectionchange */
936
- /* Excluded from this release type: retry */
928
+ /* Excluded from this release type: beforeplay */
929
+ /* Excluded from this release type: beforepause */
930
+ /* Excluded from this release type: state */
931
+ /* Excluded from this release type: config */
932
+ /* Excluded from this release type: "error:fatal" */
937
933
  };
938
934
 
939
935
  declare type PlayerCustomEventsOverloads = {
@@ -972,11 +968,18 @@ declare type PlayerCustomEventsOverloads = {
972
968
  * Sent right before the player src attribute is set. This allows you to change the video URL before playback.
973
969
  */
974
970
  on(event: typeof SOURCE, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof SOURCE]>) => void): Player;
975
- /* Excluded from this release type: on */
971
+ /**
972
+ * Emitted when an Error recovery is attempted
973
+ */
974
+ on(event: typeof RECOVER, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof RECOVER]>) => void): Player;
976
975
  /**
977
976
  * 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.
978
977
  */
979
978
  on(event: typeof REAP, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof REAP]>) => void): Player;
979
+ /**
980
+ * Emitted when a player will retry to reload
981
+ */
982
+ on(event: typeof RETRY, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof RETRY]>) => void): Player;
980
983
  /* Excluded from this release type: on */
981
984
  /**
982
985
  * Emitted when the set of underlying qualities has changed.
@@ -996,8 +999,7 @@ declare type PlayerCustomEventsOverloads = {
996
999
  /**
997
1000
  * when src is a livestream
998
1001
  */
999
- on(event: typeof LIVE_2, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof LIVE_2]>) => void): Player;
1000
- /* Excluded from this release type: on */
1002
+ on(event: typeof LIVE, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof LIVE]>) => void): Player;
1001
1003
  /* Excluded from this release type: on */
1002
1004
  /* Excluded from this release type: on */
1003
1005
  /* Excluded from this release type: on */
@@ -1026,11 +1028,26 @@ declare type PlayerCustomEventsOverloads = {
1026
1028
  */
1027
1029
  off<T>(event: string, handler: (e: FPEvent<T>) => void): Player;
1028
1030
  /* Excluded from this release type: poll */
1029
- emit<T extends PlayerCustomEventName>(event: T, data?: PlayerCustomEventsDetailMap[T]): Player;
1030
1031
  /* Excluded from this release type: emit */
1031
- emit<T, X extends string = string>(event: X & (X extends PlayerCustomEventName ? "Incorrect event detail type" : X), data?: T): Player;
1032
+ /* Excluded from this release type: emit */
1033
+ emit<T extends PlayerEmittableEventNames>(event: T, data?: PlayerCustomEventsDetailMap[T]): Player;
1034
+ /* Excluded from this release type: emit */
1035
+ };
1036
+
1037
+ declare type PlayerEmittableCustomEventsDetailMap = {
1038
+ [ERROR]: ErrorEventDetail;
1039
+ [CONTEXT_MENU]: ContextMenuEventDetail;
1040
+ [VIEW_ENTER]: ViewEnterEventDetail;
1041
+ [VIEW_LEAVE]: ViewLeaveEventDetail;
1042
+ [QUALITIES]: QualitiesEventDetail;
1043
+ [RECOMMENDATIONS_READY]: RecommendationsReadyEventDetail;
1032
1044
  };
1033
1045
 
1046
+ declare type PlayerEmittableEventNames = keyof PlayerEmittableCustomEventsDetailMap;
1047
+
1048
+ /**
1049
+ * @public
1050
+ */
1034
1051
  declare type PlayerEventOverloads = PlayerNativeEventsOverloads & PlayerCustomEventsOverloads;
1035
1052
 
1036
1053
  declare type PlayerNativeEventName = keyof PlayerNativeEventsDetailMap;
@@ -1224,9 +1241,23 @@ declare type RecommendationsReadyEventDetail = {
1224
1241
  playlist: RecommendationItem[];
1225
1242
  };
1226
1243
 
1227
- /* Excluded from this release type: RECOVER */
1244
+ /**
1245
+ * @public
1246
+ * emitted when an Error recovery is attempted
1247
+ */
1248
+ declare const /**
1249
+ @public
1250
+ * when a new player is inserted into the HTML
1251
+ */ /**
1252
+ * @public
1253
+ * emitted when an Error recovery is attempted
1254
+ */
1255
+ RECOVER = "recover";
1228
1256
 
1229
- /* Excluded from this release type: RecoverEventDetail */
1257
+ /**
1258
+ * @public
1259
+ */
1260
+ declare type RecoverEventDetail = null;
1230
1261
 
1231
1262
  /* Excluded from this release type: REMOTE_SESSION_ENDED */
1232
1263
 
@@ -1250,9 +1281,21 @@ declare const /**
1250
1281
  */
1251
1282
  RESIZE = "resize";
1252
1283
 
1253
- /* Excluded from this release type: RETRY */
1284
+ /**
1285
+ * @public
1286
+ */
1287
+ declare const /**
1288
+ @public
1289
+ * when a new player is inserted into the HTML
1290
+ */ /**
1291
+ * @public
1292
+ */
1293
+ RETRY = "retry";
1254
1294
 
1255
- /* Excluded from this release type: RetryEventDetail */
1295
+ /**
1296
+ * @public
1297
+ */
1298
+ declare type RetryEventDetail = null;
1256
1299
 
1257
1300
  declare const RTL = "is-rtl";
1258
1301
 
@@ -1403,7 +1446,7 @@ declare namespace states {
1403
1446
  RTL,
1404
1447
  TV,
1405
1448
  ENDED,
1406
- LIVE,
1449
+ LIVE_2 as LIVE,
1407
1450
  ERRORED,
1408
1451
  WAITING,
1409
1452
  AUTOPLAY,
package/plugins/ssai.d.ts CHANGED
@@ -362,6 +362,7 @@ declare type ErrorEventDetail = {
362
362
  declare namespace events {
363
363
  export {
364
364
  MOUNT,
365
+ RETRY,
365
366
  ERROR,
366
367
  CONTEXT_MENU,
367
368
  CLICK,
@@ -413,7 +414,8 @@ declare namespace events {
413
414
  LANDSCAPE,
414
415
  PORTRAIT,
415
416
  DVR,
416
- LIVE_2 as LIVE
417
+ LIVE,
418
+ RECOVER
417
419
  }
418
420
  }
419
421
 
@@ -612,8 +614,6 @@ declare const /**
612
614
  */
613
615
  LANDSCAPE = "landscape";
614
616
 
615
- declare const LIVE = "is-live";
616
-
617
617
  /**
618
618
  * @public
619
619
  * when src is a livestream
@@ -625,7 +625,9 @@ declare const /**
625
625
  * @public
626
626
  * when src is a livestream
627
627
  */
628
- LIVE_2 = "live";
628
+ LIVE = "live";
629
+
630
+ declare const LIVE_2 = "is-live";
629
631
 
630
632
  declare const LIVE_SEEKED = "is-live-seeked";
631
633
 
@@ -925,33 +927,27 @@ declare type Player = HTMLVideoElement & PlayerEventOverloads & {
925
927
 
926
928
  declare type PlayerCustomEventName = keyof PlayerCustomEventsDetailMap;
927
929
 
928
- declare type PlayerCustomEventsDetailMap = {
929
- [MOUNT]: MountEventDetail;
930
- [ERROR]: ErrorEventDetail;
931
- [CONTEXT_MENU]: ContextMenuEventDetail;
932
- /* Excluded from this release type: beforeplay */
933
- /* Excluded from this release type: beforepause */
934
- /* Excluded from this release type: state */
930
+ declare type PlayerCustomEventsDetailMap = PlayerEmittableCustomEventsDetailMap & {
931
+ [REAP]: ReapEventDetail;
932
+ [SOURCE]: SourceEventDetail;
935
933
  [CUEPOINT_START]: CuePointStartEventDetail;
936
934
  [CUEPOINT_END]: CuePointEndEventDetail;
937
- [VIEW_ENTER]: ViewEnterEventDetail;
938
- [VIEW_LEAVE]: ViewLeaveEventDetail;
939
- [SOURCE]: SourceEventDetail;
940
- /* Excluded from this release type: recover */
941
- [REAP]: ReapEventDetail;
942
- /* Excluded from this release type: config */
943
- [QUALITIES]: QualitiesEventDetail;
944
- /* Excluded from this release type: "error:fatal" */
945
- [RECOMMENDATIONS_READY]: RecommendationsReadyEventDetail;
935
+ [MOUNT]: MountEventDetail;
936
+ [LIVE]: LiveEventDetail;
937
+ [DVR]: DvrEventDetail;
938
+ [RETRY]: RetryEventDetail;
939
+ [RECOVER]: RecoverEventDetail;
946
940
  /* Excluded from this release type: audioonlysource */
947
941
  /* Excluded from this release type: renderplugin */
948
- [DVR]: DvrEventDetail;
949
- [LIVE_2]: LiveEventDetail;
950
942
  /* Excluded from this release type: "seek:queued" */
951
943
  /* Excluded from this release type: "seek:cancel" */
952
944
  /* Excluded from this release type: "plugin:registered" */
953
945
  /* Excluded from this release type: intersectionchange */
954
- /* Excluded from this release type: retry */
946
+ /* Excluded from this release type: beforeplay */
947
+ /* Excluded from this release type: beforepause */
948
+ /* Excluded from this release type: state */
949
+ /* Excluded from this release type: config */
950
+ /* Excluded from this release type: "error:fatal" */
955
951
  };
956
952
 
957
953
  declare type PlayerCustomEventsOverloads = {
@@ -990,11 +986,18 @@ declare type PlayerCustomEventsOverloads = {
990
986
  * Sent right before the player src attribute is set. This allows you to change the video URL before playback.
991
987
  */
992
988
  on(event: typeof SOURCE, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof SOURCE]>) => void): Player;
993
- /* Excluded from this release type: on */
989
+ /**
990
+ * Emitted when an Error recovery is attempted
991
+ */
992
+ on(event: typeof RECOVER, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof RECOVER]>) => void): Player;
994
993
  /**
995
994
  * 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.
996
995
  */
997
996
  on(event: typeof REAP, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof REAP]>) => void): Player;
997
+ /**
998
+ * Emitted when a player will retry to reload
999
+ */
1000
+ on(event: typeof RETRY, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof RETRY]>) => void): Player;
998
1001
  /* Excluded from this release type: on */
999
1002
  /**
1000
1003
  * Emitted when the set of underlying qualities has changed.
@@ -1014,8 +1017,7 @@ declare type PlayerCustomEventsOverloads = {
1014
1017
  /**
1015
1018
  * when src is a livestream
1016
1019
  */
1017
- on(event: typeof LIVE_2, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof LIVE_2]>) => void): Player;
1018
- /* Excluded from this release type: on */
1020
+ on(event: typeof LIVE, handler: (e: FPEvent<PlayerCustomEventsDetailMap[typeof LIVE]>) => void): Player;
1019
1021
  /* Excluded from this release type: on */
1020
1022
  /* Excluded from this release type: on */
1021
1023
  /* Excluded from this release type: on */
@@ -1044,11 +1046,26 @@ declare type PlayerCustomEventsOverloads = {
1044
1046
  */
1045
1047
  off<T>(event: string, handler: (e: FPEvent<T>) => void): Player;
1046
1048
  /* Excluded from this release type: poll */
1047
- emit<T extends PlayerCustomEventName>(event: T, data?: PlayerCustomEventsDetailMap[T]): Player;
1048
1049
  /* Excluded from this release type: emit */
1049
- emit<T, X extends string = string>(event: X & (X extends PlayerCustomEventName ? "Incorrect event detail type" : X), data?: T): Player;
1050
+ /* Excluded from this release type: emit */
1051
+ emit<T extends PlayerEmittableEventNames>(event: T, data?: PlayerCustomEventsDetailMap[T]): Player;
1052
+ /* Excluded from this release type: emit */
1053
+ };
1054
+
1055
+ declare type PlayerEmittableCustomEventsDetailMap = {
1056
+ [ERROR]: ErrorEventDetail;
1057
+ [CONTEXT_MENU]: ContextMenuEventDetail;
1058
+ [VIEW_ENTER]: ViewEnterEventDetail;
1059
+ [VIEW_LEAVE]: ViewLeaveEventDetail;
1060
+ [QUALITIES]: QualitiesEventDetail;
1061
+ [RECOMMENDATIONS_READY]: RecommendationsReadyEventDetail;
1050
1062
  };
1051
1063
 
1064
+ declare type PlayerEmittableEventNames = keyof PlayerEmittableCustomEventsDetailMap;
1065
+
1066
+ /**
1067
+ * @public
1068
+ */
1052
1069
  declare type PlayerEventOverloads = PlayerNativeEventsOverloads & PlayerCustomEventsOverloads;
1053
1070
 
1054
1071
  declare type PlayerNativeEventName = keyof PlayerNativeEventsDetailMap;
@@ -1244,9 +1261,23 @@ declare type RecommendationsReadyEventDetail = {
1244
1261
  playlist: RecommendationItem[];
1245
1262
  };
1246
1263
 
1247
- /* Excluded from this release type: RECOVER */
1264
+ /**
1265
+ * @public
1266
+ * emitted when an Error recovery is attempted
1267
+ */
1268
+ declare const /**
1269
+ @public
1270
+ * when a new player is inserted into the HTML
1271
+ */ /**
1272
+ * @public
1273
+ * emitted when an Error recovery is attempted
1274
+ */
1275
+ RECOVER = "recover";
1248
1276
 
1249
- /* Excluded from this release type: RecoverEventDetail */
1277
+ /**
1278
+ * @public
1279
+ */
1280
+ declare type RecoverEventDetail = null;
1250
1281
 
1251
1282
  /* Excluded from this release type: REMOTE_SESSION_ENDED */
1252
1283
 
@@ -1270,9 +1301,21 @@ declare const /**
1270
1301
  */
1271
1302
  RESIZE = "resize";
1272
1303
 
1273
- /* Excluded from this release type: RETRY */
1304
+ /**
1305
+ * @public
1306
+ */
1307
+ declare const /**
1308
+ @public
1309
+ * when a new player is inserted into the HTML
1310
+ */ /**
1311
+ * @public
1312
+ */
1313
+ RETRY = "retry";
1274
1314
 
1275
- /* Excluded from this release type: RetryEventDetail */
1315
+ /**
1316
+ * @public
1317
+ */
1318
+ declare type RetryEventDetail = null;
1276
1319
 
1277
1320
  declare const RTL = "is-rtl";
1278
1321
 
@@ -1424,7 +1467,7 @@ declare namespace states {
1424
1467
  RTL,
1425
1468
  TV,
1426
1469
  ENDED,
1427
- LIVE,
1470
+ LIVE_2 as LIVE,
1428
1471
  ERRORED,
1429
1472
  WAITING,
1430
1473
  AUTOPLAY,