@gcorevideo/player 2.20.18 → 2.20.20

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/dist/index.js CHANGED
@@ -42624,7 +42624,6 @@ const T$h = 'playback.html5_video';
42624
42624
  const STALL_TIMEOUT = 15000;
42625
42625
  class HTML5Video extends BasePlayback {
42626
42626
  stallTimerId = null;
42627
- statllTimerId = null;
42628
42627
  /**
42629
42628
  * @internal
42630
42629
  */
@@ -42664,20 +42663,19 @@ class HTML5Video extends BasePlayback {
42664
42663
  trace(`${T$h} _handleBufferingEvents`, {
42665
42664
  networkState: this.el.networkState,
42666
42665
  });
42667
- if (!this.statllTimerId) {
42668
- this.statllTimerId = setTimeout(() => {
42666
+ if (!this.stallTimerId) {
42667
+ this.stallTimerId = setTimeout(() => {
42669
42668
  trace(`${T$h} _handleBufferingEvents stall timeout`, {
42670
42669
  buffering: this.buffering,
42671
42670
  ended: this.ended,
42672
- isPlaying: this.isPlaying,
42673
42671
  });
42674
- this.statllTimerId = null;
42675
- if (!this.isPlaying) {
42676
- this.createError({
42677
- code: PlaybackErrorCode.MediaSourceUnavailable,
42678
- message: 'Stall timeout',
42679
- });
42680
- }
42672
+ this.stallTimerId = null;
42673
+ this.createError({
42674
+ code: PlaybackErrorCode.MediaSourceUnavailable,
42675
+ level: PlayerError.Levels.FATAL,
42676
+ message: 'Stall timeout',
42677
+ description: 'Playback stalled for too long',
42678
+ });
42681
42679
  }, STALL_TIMEOUT);
42682
42680
  }
42683
42681
  super._handleBufferingEvents();
@@ -42690,6 +42688,14 @@ class HTML5Video extends BasePlayback {
42690
42688
  }
42691
42689
  super._onPlaying();
42692
42690
  }
42691
+ _onPause() {
42692
+ trace(`${T$h} _onPause`);
42693
+ super._onPause();
42694
+ if (this.stallTimerId) {
42695
+ clearTimeout(this.stallTimerId);
42696
+ this.stallTimerId = null;
42697
+ }
42698
+ }
42693
42699
  }
42694
42700
 
42695
42701
  // TODO consider allowing the variation of the order of playback modules
@@ -43163,7 +43169,7 @@ class Player {
43163
43169
  }
43164
43170
  }
43165
43171
 
43166
- var version$1 = "2.20.18";
43172
+ var version$1 = "2.20.20";
43167
43173
 
43168
43174
  var packages = {
43169
43175
  "node_modules/@clappr/core": {