stormcloud-video-player 0.8.22 → 0.8.24

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.
@@ -1063,7 +1063,7 @@ var HlsEngine = /*#__PURE__*/ function() {
1063
1063
  key: "setupNativeHls",
1064
1064
  value: function setupNativeHls() {
1065
1065
  return _async_to_generator(function() {
1066
- var _this_config_isLiveStream, _this_config_lowLatencyMode, _this_video_play;
1066
+ var _this_config_isLiveStream, _this_config_lowLatencyMode, adBehavior, _this_video_play;
1067
1067
  return _ts_generator(this, function(_state) {
1068
1068
  switch(_state.label){
1069
1069
  case 0:
@@ -1072,10 +1072,11 @@ var HlsEngine = /*#__PURE__*/ function() {
1072
1072
  this.video.src = this.config.src;
1073
1073
  this.isLiveStream = (_this_config_isLiveStream = this.config.isLiveStream) !== null && _this_config_isLiveStream !== void 0 ? _this_config_isLiveStream : (_this_config_lowLatencyMode = this.config.lowLatencyMode) !== null && _this_config_lowLatencyMode !== void 0 ? _this_config_lowLatencyMode : false;
1074
1074
  if (this.debug) {
1075
- console.log("[StormcloudVideoPlayer] Using native HLS playback - VOD mode:", {
1075
+ adBehavior = this.isLiveStream ? "live (main video continues muted during ads)" : "vod (main video pauses during ads)";
1076
+ console.log("[StormcloudVideoPlayer] Using native HLS playback:", {
1076
1077
  isLive: this.isLiveStream,
1077
1078
  allowNativeHls: this.config.allowNativeHls,
1078
- adBehavior: "vod (main video pauses during ads)"
1079
+ adBehavior: adBehavior
1079
1080
  });
1080
1081
  }
1081
1082
  if (!this.config.autoplay) return [
@@ -1484,6 +1485,14 @@ var HlsEngine = /*#__PURE__*/ function() {
1484
1485
  });
1485
1486
  }
1486
1487
  },
1488
+ {
1489
+ key: "getLiveSyncPosition",
1490
+ value: function getLiveSyncPosition() {
1491
+ var _this_hls;
1492
+ var pos = (_this_hls = this.hls) === null || _this_hls === void 0 ? void 0 : _this_hls.liveSyncPosition;
1493
+ return typeof pos === "number" && Number.isFinite(pos) ? pos : void 0;
1494
+ }
1495
+ },
1487
1496
  {
1488
1497
  key: "destroy",
1489
1498
  value: function destroy() {