bigscreen-player 5.3.2 → 5.4.2
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/esm/{imscsubtitles-26424d54.js → imscsubtitles-f57c0961.js} +1 -1
- package/dist/esm/{legacysubtitles-71b94bba.js → legacysubtitles-249d3851.js} +1 -1
- package/dist/esm/{main-1452a230.js → main-5a3f2039.js} +22 -11
- package/dist/esm/main.js +1 -1
- package/dist/esm/{msestrategy-0db784b4.js → msestrategy-7485a9bd.js} +4 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { fromXML, generateISD, renderHTML } from 'smp-imsc';
|
|
2
|
-
import { b as TimeUtils, L as LoadUrl, a as DebugTool, P as Plugins, U as Utils, D as DOMHelpers } from './main-
|
|
2
|
+
import { b as TimeUtils, L as LoadUrl, a as DebugTool, P as Plugins, U as Utils, D as DOMHelpers } from './main-5a3f2039.js';
|
|
3
3
|
|
|
4
4
|
function IMSCSubtitles (mediaPlayer, autoStart, parentElement, mediaSources, defaultStyleOpts) {
|
|
5
5
|
const SEGMENTS_TO_KEEP = 3;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { D as DOMHelpers, a as DebugTool, P as Plugins, L as LoadUrl, T as TransportControlPosition } from './main-
|
|
1
|
+
import { D as DOMHelpers, a as DebugTool, P as Plugins, L as LoadUrl, T as TransportControlPosition } from './main-5a3f2039.js';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* Safely checks if an attribute exists on an element.
|
|
@@ -1999,6 +1999,17 @@ function Cehtml () {
|
|
|
1999
1999
|
}
|
|
2000
2000
|
}
|
|
2001
2001
|
|
|
2002
|
+
function handlePlayPromise (playPromise) {
|
|
2003
|
+
if (!playPromise || typeof playPromise.catch !== 'function') return
|
|
2004
|
+
|
|
2005
|
+
playPromise.catch((e) => {
|
|
2006
|
+
if (e && e.name === 'AbortError') {
|
|
2007
|
+
return
|
|
2008
|
+
}
|
|
2009
|
+
throw e
|
|
2010
|
+
});
|
|
2011
|
+
}
|
|
2012
|
+
|
|
2002
2013
|
function Html5 () {
|
|
2003
2014
|
const sentinelLimits = {
|
|
2004
2015
|
pause: {
|
|
@@ -2491,11 +2502,11 @@ function Html5 () {
|
|
|
2491
2502
|
|
|
2492
2503
|
function deferredPlayFrom () {
|
|
2493
2504
|
if (window.bigscreenPlayer.overrides && window.bigscreenPlayer.overrides.deferredPlayback) {
|
|
2494
|
-
mediaElement.play();
|
|
2505
|
+
handlePlayPromise(mediaElement.play());
|
|
2495
2506
|
seekTo(targetSeekTime);
|
|
2496
2507
|
} else {
|
|
2497
2508
|
seekTo(targetSeekTime);
|
|
2498
|
-
mediaElement.play();
|
|
2509
|
+
handlePlayPromise(mediaElement.play());
|
|
2499
2510
|
}
|
|
2500
2511
|
|
|
2501
2512
|
if (postBufferingState === MediaPlayerBase.STATE.PAUSED) {
|
|
@@ -2742,7 +2753,7 @@ function Html5 () {
|
|
|
2742
2753
|
case MediaPlayerBase.STATE.STOPPED:
|
|
2743
2754
|
trustZeroes = true;
|
|
2744
2755
|
toBuffering();
|
|
2745
|
-
mediaElement.play();
|
|
2756
|
+
handlePlayPromise(mediaElement.play());
|
|
2746
2757
|
break
|
|
2747
2758
|
|
|
2748
2759
|
default:
|
|
@@ -2804,12 +2815,12 @@ function Html5 () {
|
|
|
2804
2815
|
case MediaPlayerBase.STATE.BUFFERING:
|
|
2805
2816
|
if (isReadyToPlayFrom()) {
|
|
2806
2817
|
// If we are not ready to playFrom, then calling play would seek to the start of media, which we might not want.
|
|
2807
|
-
mediaElement.play();
|
|
2818
|
+
handlePlayPromise(mediaElement.play());
|
|
2808
2819
|
}
|
|
2809
2820
|
break
|
|
2810
2821
|
|
|
2811
2822
|
case MediaPlayerBase.STATE.PAUSED:
|
|
2812
|
-
mediaElement.play();
|
|
2823
|
+
handlePlayPromise(mediaElement.play());
|
|
2813
2824
|
toPlaying();
|
|
2814
2825
|
break
|
|
2815
2826
|
|
|
@@ -5581,7 +5592,7 @@ function BasicStrategy (mediaSources, windowType, mediaKind, playbackElement, is
|
|
|
5581
5592
|
}
|
|
5582
5593
|
|
|
5583
5594
|
function play () {
|
|
5584
|
-
mediaElement.play();
|
|
5595
|
+
handlePlayPromise(mediaElement.play());
|
|
5585
5596
|
}
|
|
5586
5597
|
|
|
5587
5598
|
function setCurrentTime (time) {
|
|
@@ -5700,12 +5711,12 @@ function StrategyPicker (windowType, isUHD) {
|
|
|
5700
5711
|
return resolve(NativeStrategy)
|
|
5701
5712
|
}
|
|
5702
5713
|
|
|
5703
|
-
return import('./msestrategy-
|
|
5714
|
+
return import('./msestrategy-7485a9bd.js').then(({default: MSEStrategy}) => resolve(MSEStrategy))
|
|
5704
5715
|
.catch(() => {
|
|
5705
5716
|
reject({error: 'strategyDynamicLoadError'});
|
|
5706
5717
|
})
|
|
5707
5718
|
} else if (window.bigscreenPlayer.playbackStrategy === PlaybackStrategy.MSE) {
|
|
5708
|
-
return import('./msestrategy-
|
|
5719
|
+
return import('./msestrategy-7485a9bd.js').then(({default: MSEStrategy}) => resolve(MSEStrategy))
|
|
5709
5720
|
.catch(() => {
|
|
5710
5721
|
reject({error: 'strategyDynamicLoadError'});
|
|
5711
5722
|
})
|
|
@@ -6085,7 +6096,7 @@ function CallCallbacks (callbacks, data) {
|
|
|
6085
6096
|
callbacks.forEach((callback) => DeferExceptions(() => callback(data)));
|
|
6086
6097
|
}
|
|
6087
6098
|
|
|
6088
|
-
var version = "5.
|
|
6099
|
+
var version = "5.4.2";
|
|
6089
6100
|
|
|
6090
6101
|
var sourceList;
|
|
6091
6102
|
var source;
|
|
@@ -7271,14 +7282,14 @@ function Subtitles (mediaPlayer, autoStart, playbackElement, defaultStyleOpts, m
|
|
|
7271
7282
|
let subtitlesContainer;
|
|
7272
7283
|
|
|
7273
7284
|
if (useLegacySubs) {
|
|
7274
|
-
import('./legacysubtitles-
|
|
7285
|
+
import('./legacysubtitles-249d3851.js').then(({default: LegacySubtitles}) => {
|
|
7275
7286
|
subtitlesContainer = LegacySubtitles(mediaPlayer, autoStart, playbackElement, mediaSources, defaultStyleOpts);
|
|
7276
7287
|
callback(subtitlesEnabled);
|
|
7277
7288
|
}).catch(() => {
|
|
7278
7289
|
Plugins.interface.onSubtitlesDynamicLoadError();
|
|
7279
7290
|
});
|
|
7280
7291
|
} else {
|
|
7281
|
-
import('./imscsubtitles-
|
|
7292
|
+
import('./imscsubtitles-f57c0961.js').then(({default: IMSCSubtitles}) => {
|
|
7282
7293
|
subtitlesContainer = IMSCSubtitles(mediaPlayer, autoStart, playbackElement, mediaSources, defaultStyleOpts);
|
|
7283
7294
|
callback(subtitlesEnabled);
|
|
7284
7295
|
}).catch(() => {
|
package/dist/esm/main.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export { B as BigscreenPlayer, c as LiveSupport, d as MediaKinds, M as MediaState, f as MockBigscreenPlayer, g as PauseTriggers, h as PlaybackStrategy, i as TransferFormat, T as TransportControlPosition, W as WindowTypes } from './main-
|
|
1
|
+
export { B as BigscreenPlayer, c as LiveSupport, d as MediaKinds, M as MediaState, f as MockBigscreenPlayer, g as PauseTriggers, h as PlaybackStrategy, i as TransferFormat, T as TransportControlPosition, W as WindowTypes } from './main-5a3f2039.js';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { D as DOMHelpers, W as WindowTypes, c as LiveSupport, M as MediaState, a as DebugTool, P as Plugins, d as MediaKinds, U as Utils, b as TimeUtils, e as DynamicWindowUtils } from './main-
|
|
1
|
+
import { D as DOMHelpers, W as WindowTypes, c as LiveSupport, M as MediaState, a as DebugTool, P as Plugins, d as MediaKinds, U as Utils, b as TimeUtils, e as DynamicWindowUtils } from './main-5a3f2039.js';
|
|
2
2
|
import { MediaPlayer } from 'dashjs/index_mediaplayerOnly';
|
|
3
3
|
|
|
4
4
|
function filter (manifest, representationOptions) {
|
|
@@ -605,6 +605,9 @@ function MSEStrategy (mediaSources, windowType, mediaKind, playbackElement, isUH
|
|
|
605
605
|
getSeekableRange: getSeekableRange,
|
|
606
606
|
getCurrentTime: getCurrentTime,
|
|
607
607
|
getDuration: getDuration,
|
|
608
|
+
getPlayerElement: () => {
|
|
609
|
+
return mediaElement
|
|
610
|
+
},
|
|
608
611
|
tearDown: () => {
|
|
609
612
|
mediaPlayer.reset();
|
|
610
613
|
|