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
|
@@ -5125,7 +5125,7 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5125
5125
|
}
|
|
5126
5126
|
this.beginNewAdPod();
|
|
5127
5127
|
this.podAssignedByPrefetch = true;
|
|
5128
|
-
var urlsToPregenerate =
|
|
5128
|
+
var urlsToPregenerate = 1;
|
|
5129
5129
|
var generatedUrls = this.generateVastUrlsWithCorrelators(baseVastUrl, urlsToPregenerate);
|
|
5130
5130
|
this.pendingAdBreak = _object_spread_props(_object_spread({
|
|
5131
5131
|
marker: marker
|
|
@@ -5150,7 +5150,7 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5150
5150
|
console.log("[PREFETCH] \uD83D\uDD04 Starting ad prefetch for upcoming ad break");
|
|
5151
5151
|
console.log("[PREFETCH] \uD83D\uDCCB Pre-generated ".concat(generatedUrls.length, " VAST URLs"));
|
|
5152
5152
|
}
|
|
5153
|
-
this.startPreloadPool(baseVastUrl, generatedUrls.slice(0,
|
|
5153
|
+
this.startPreloadPool(baseVastUrl, generatedUrls.slice(0, 1), false);
|
|
5154
5154
|
}
|
|
5155
5155
|
},
|
|
5156
5156
|
{
|
|
@@ -5168,6 +5168,7 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5168
5168
|
{
|
|
5169
5169
|
key: "startPreloadPool",
|
|
5170
5170
|
value: function startPreloadPool(baseVastUrl, initialUrls) {
|
|
5171
|
+
var startLoopImmediately = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : true;
|
|
5171
5172
|
if (this.preloadPoolActive) {
|
|
5172
5173
|
if (this.config.debugAdTiming) {
|
|
5173
5174
|
console.log("[PRELOAD-POOL] Already active, skipping duplicate start");
|
|
@@ -5201,7 +5202,11 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5201
5202
|
}
|
|
5202
5203
|
}
|
|
5203
5204
|
}
|
|
5204
|
-
|
|
5205
|
+
if (startLoopImmediately) {
|
|
5206
|
+
this.preloadPoolLoop(baseVastUrl);
|
|
5207
|
+
} else if (this.config.debugAdTiming) {
|
|
5208
|
+
console.log("[PRELOAD-POOL] Pre-break mode: preloaded once, waiting for SCTE start to continue fetching");
|
|
5209
|
+
}
|
|
5205
5210
|
}
|
|
5206
5211
|
},
|
|
5207
5212
|
{
|
|
@@ -5628,21 +5633,13 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5628
5633
|
currentMuted = this.video.muted;
|
|
5629
5634
|
currentVolume = this.video.volume;
|
|
5630
5635
|
this.adPlayer.updateOriginalMutedState(currentMuted, currentVolume);
|
|
5631
|
-
if (!this.video.muted) {
|
|
5632
|
-
this.video.muted = true;
|
|
5633
|
-
if (this.config.debugAdTiming) {
|
|
5634
|
-
console.log("[StormcloudVideoPlayer] Muted video in handleAdStart");
|
|
5635
|
-
}
|
|
5636
|
-
}
|
|
5637
5636
|
this.inAdBreak = true;
|
|
5638
5637
|
this.currentAdBreakStartWallClockMs = Date.now();
|
|
5639
5638
|
this.adBreakPlayedDurationMs = 0;
|
|
5640
5639
|
this.currentAdIndex = 0;
|
|
5641
5640
|
this.totalAdsInBreak = 0;
|
|
5642
5641
|
this.adPodQueue = [];
|
|
5643
|
-
this.showAds =
|
|
5644
|
-
this.showPlaceholderLayer();
|
|
5645
|
-
this.adPlayer.showPlaceholder();
|
|
5642
|
+
this.showAds = false;
|
|
5646
5643
|
if (this.expectedAdBreakDurationMs == null && adBreakDurationMs != null) {
|
|
5647
5644
|
this.expectedAdBreakDurationMs = adBreakDurationMs;
|
|
5648
5645
|
}
|
|
@@ -5731,6 +5728,8 @@ var StormcloudVideoPlayer = /*#__PURE__*/ function() {
|
|
|
5731
5728
|
this.startContinuousFetching(baseVastUrl);
|
|
5732
5729
|
if (!this.preloadPoolActive) {
|
|
5733
5730
|
this.preloadPoolActive = true;
|
|
5731
|
+
}
|
|
5732
|
+
if (!this.preloadPoolLoopRunning) {
|
|
5734
5733
|
this.preloadPoolLoop(baseVastUrl);
|
|
5735
5734
|
}
|
|
5736
5735
|
return [
|