stormcloud-video-player 0.8.11 → 0.8.13
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/stormcloud-vp.min.js +1 -1
- package/lib/index.cjs +11 -12
- package/lib/index.cjs.map +1 -1
- package/lib/index.js +11 -12
- package/lib/index.js.map +1 -1
- package/lib/player/StormcloudVideoPlayer.cjs +11 -12
- package/lib/player/StormcloudVideoPlayer.cjs.map +1 -1
- package/lib/player/StormcloudVideoPlayer.d.cts +1 -1
- package/lib/players/HlsPlayer.cjs +11 -12
- package/lib/players/HlsPlayer.cjs.map +1 -1
- package/lib/players/HlsPlayer.d.cts +1 -1
- package/lib/players/index.cjs +11 -12
- package/lib/players/index.cjs.map +1 -1
- package/lib/sdk/hlsAdPlayer.d.cts +1 -1
- package/lib/{types-CRd8dgO8.d.cts → types-BM5cceAy.d.cts} +1 -1
- package/lib/ui/StormcloudVideoPlayer.cjs +11 -12
- package/lib/ui/StormcloudVideoPlayer.cjs.map +1 -1
- package/lib/ui/StormcloudVideoPlayer.d.cts +1 -1
- package/lib/utils/tracking.d.cts +1 -1
- package/package.json +1 -1
|
@@ -108,4 +108,4 @@ interface AdImpressionInfo {
|
|
|
108
108
|
timestamp: string;
|
|
109
109
|
}
|
|
110
110
|
|
|
111
|
-
export type {
|
|
111
|
+
export type { AdController as A, ClientInfo as C, PlayerAnalyticsContext as P, StormcloudVideoPlayerConfig as S, AdDetectInfo as a, AdImpressionInfo as b, AdLoadedInfo as c };
|
|
@@ -5163,7 +5163,7 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5163
5163
|
}
|
|
5164
5164
|
this.beginNewAdPod();
|
|
5165
5165
|
this.podAssignedByPrefetch = true;
|
|
5166
|
-
var urlsToPregenerate =
|
|
5166
|
+
var urlsToPregenerate = 1;
|
|
5167
5167
|
var generatedUrls = this.generateVastUrlsWithCorrelators(baseVastUrl, urlsToPregenerate);
|
|
5168
5168
|
this.pendingAdBreak = _object_spread_props(_object_spread({
|
|
5169
5169
|
marker: marker
|
|
@@ -5188,7 +5188,7 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5188
5188
|
console.log("[PREFETCH] \uD83D\uDD04 Starting ad prefetch for upcoming ad break");
|
|
5189
5189
|
console.log("[PREFETCH] \uD83D\uDCCB Pre-generated ".concat(generatedUrls.length, " VAST URLs"));
|
|
5190
5190
|
}
|
|
5191
|
-
this.startPreloadPool(baseVastUrl, generatedUrls.slice(0,
|
|
5191
|
+
this.startPreloadPool(baseVastUrl, generatedUrls.slice(0, 1), false);
|
|
5192
5192
|
}
|
|
5193
5193
|
},
|
|
5194
5194
|
{
|
|
@@ -5206,6 +5206,7 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5206
5206
|
{
|
|
5207
5207
|
key: "startPreloadPool",
|
|
5208
5208
|
value: function startPreloadPool(baseVastUrl, initialUrls) {
|
|
5209
|
+
var startLoopImmediately = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : true;
|
|
5209
5210
|
if (this.preloadPoolActive) {
|
|
5210
5211
|
if (this.config.debugAdTiming) {
|
|
5211
5212
|
console.log("[PRELOAD-POOL] Already active, skipping duplicate start");
|
|
@@ -5239,7 +5240,11 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5239
5240
|
}
|
|
5240
5241
|
}
|
|
5241
5242
|
}
|
|
5242
|
-
|
|
5243
|
+
if (startLoopImmediately) {
|
|
5244
|
+
this.preloadPoolLoop(baseVastUrl);
|
|
5245
|
+
} else if (this.config.debugAdTiming) {
|
|
5246
|
+
console.log("[PRELOAD-POOL] Pre-break mode: preloaded once, waiting for SCTE start to continue fetching");
|
|
5247
|
+
}
|
|
5243
5248
|
}
|
|
5244
5249
|
},
|
|
5245
5250
|
{
|
|
@@ -5666,21 +5671,13 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5666
5671
|
currentMuted = this.video.muted;
|
|
5667
5672
|
currentVolume = this.video.volume;
|
|
5668
5673
|
this.adPlayer.updateOriginalMutedState(currentMuted, currentVolume);
|
|
5669
|
-
if (!this.video.muted) {
|
|
5670
|
-
this.video.muted = true;
|
|
5671
|
-
if (this.config.debugAdTiming) {
|
|
5672
|
-
console.log("[StormcloudVideoPlayer] Muted video in handleAdStart");
|
|
5673
|
-
}
|
|
5674
|
-
}
|
|
5675
5674
|
this.inAdBreak = true;
|
|
5676
5675
|
this.currentAdBreakStartWallClockMs = Date.now();
|
|
5677
5676
|
this.adBreakPlayedDurationMs = 0;
|
|
5678
5677
|
this.currentAdIndex = 0;
|
|
5679
5678
|
this.totalAdsInBreak = 0;
|
|
5680
5679
|
this.adPodQueue = [];
|
|
5681
|
-
this.showAds =
|
|
5682
|
-
this.showPlaceholderLayer();
|
|
5683
|
-
this.adPlayer.showPlaceholder();
|
|
5680
|
+
this.showAds = false;
|
|
5684
5681
|
if (this.expectedAdBreakDurationMs == null && adBreakDurationMs != null) {
|
|
5685
5682
|
this.expectedAdBreakDurationMs = adBreakDurationMs;
|
|
5686
5683
|
}
|
|
@@ -5769,6 +5766,8 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5769
5766
|
this.startContinuousFetching(baseVastUrl);
|
|
5770
5767
|
if (!this.preloadPoolActive) {
|
|
5771
5768
|
this.preloadPoolActive = true;
|
|
5769
|
+
}
|
|
5770
|
+
if (!this.preloadPoolLoopRunning) {
|
|
5772
5771
|
this.preloadPoolLoop(baseVastUrl);
|
|
5773
5772
|
}
|
|
5774
5773
|
return [
|