@playkit-js/playkit-js-hls 1.32.3 → 1.32.4

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/CHANGELOG.md CHANGED
@@ -2,6 +2,15 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ### 1.32.4 (2023-05-17)
6
+
7
+
8
+ ### Bug Fixes
9
+
10
+ * **FEC-13123:** replace travis with github actions ([#203](https://github.com/kaltura/playkit-js-hls/issues/203)) ([cb687d0](https://github.com/kaltura/playkit-js-hls/commit/cb687d0))
11
+
12
+
13
+
5
14
  ### 1.32.3 (2023-05-08)
6
15
 
7
16
 
@@ -1,2 +1,2 @@
1
- !function(e,r){"object"==typeof exports&&"object"==typeof module?module.exports=r(require("@playkit-js/playkit-js"),require("hls.js")):"function"==typeof define&&define.amd?define("hls",["playkit-js","hls.js"],r):"object"==typeof exports?exports.hls=r(require("@playkit-js/playkit-js"),require("hls.js")):(e.playkit=e.playkit||{},e.playkit.hls=r(e.playkit.core,e.Hls))}(window,(function(e,r){return function(e){var r={};function t(a){if(r[a])return r[a].exports;var i=r[a]={i:a,l:!1,exports:{}};return e[a].call(i.exports,i,i.exports,t),i.l=!0,i.exports}return t.m=e,t.c=r,t.d=function(e,r,a){t.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:a})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,r){if(1&r&&(e=t(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var a=Object.create(null);if(t.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var i in e)t.d(a,i,function(r){return e[r]}.bind(null,i));return a},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},t.p="",t(t.s=3)}([function(r,t){r.exports=e},function(e,t){e.exports=r},function(e){e.exports=JSON.parse('{"recoverDecodingErrorDelay":3000,"recoverSwapAudioCodecDelay":3000,"abr":{"enabled":true,"restrictions":{}},"hlsConfig":{"fragLoadingMaxRetry":4,"maxMaxBufferLength":60},"network":{}}')},function(e,r,t){"use strict";t.r(r),t.d(r,"VERSION",(function(){return y})),t.d(r,"NAME",(function(){return R}));var a,i=t(0),o=t(1),n=t.n(o),s=t(2),l=((a={})[n.a.ErrorDetails.MANIFEST_LOAD_ERROR]={category:i.Error.Category.MANIFEST,code:i.Error.Code.HTTP_ERROR},a[n.a.ErrorDetails.MANIFEST_LOAD_TIMEOUT]={category:i.Error.Category.MANIFEST,code:i.Error.Code.TIMEOUT},a[n.a.ErrorDetails.MANIFEST_PARSING_ERROR]={category:i.Error.Category.MANIFEST,code:i.Error.Code.HLSJS_CANNOT_PARSE},a[n.a.ErrorDetails.LEVEL_LOAD_ERROR]={category:i.Error.Category.NETWORK,code:i.Error.Code.HTTP_ERROR},a[n.a.ErrorDetails.LEVEL_LOAD_TIMEOUT]={category:i.Error.Category.NETWORK,code:i.Error.Code.TIMEOUT},a[n.a.ErrorDetails.LEVEL_SWITCH_ERROR]={category:i.Error.Category.PLAYER,code:i.Error.Code.BITRATE_SWITCH_ISSUE},a[n.a.ErrorDetails.FRAG_LOAD_ERROR]={category:i.Error.Category.NETWORK,code:i.Error.Code.HTTP_ERROR},a[n.a.ErrorDetails.FRAG_LOOP_LOADING_ERROR]={category:i.Error.Category.NETWORK,code:i.Error.Code.HTTP_ERROR},a[n.a.ErrorDetails.FRAG_LOAD_TIMEOUT]={category:i.Error.Category.NETWORK,code:i.Error.Code.TIMEOUT},a[n.a.ErrorDetails.FRAG_PARSING_ERROR]={category:i.Error.Category.MEDIA,code:i.Error.Code.HLS_FRAG_PARSING_ERROR},a[n.a.ErrorDetails.BUFFER_APPEND_ERROR]={category:i.Error.Category.MEDIA,code:i.Error.Code.HLS_BUFFER_APPEND_ISSUE},a[n.a.ErrorDetails.BUFFER_APPENDING_ERROR]={category:i.Error.Category.MEDIA,code:i.Error.Code.HLS_BUFFER_APPENDING_ISSUE},a[n.a.ErrorDetails.BUFFER_STALLED_ERROR]={category:i.Error.Category.MEDIA,code:i.Error.Code.HLS_BUFFER_STALLED_ERROR},a);var c=function(e){var r,t;function a(r){var t;return t=e.call(this,r)||this,r&&r.readystatechange&&(t.readystatechange=r.readystatechange),t}return t=e,(r=a).prototype=Object.create(t.prototype),r.prototype.constructor=r,r.__proto__=t,a.prototype.loadInternal=function(){var e,r=this,t=this.context;e=this.loader=new XMLHttpRequest;var a=this.stats;a.tfirst=0,a.loaded=0;var i,o=this.xhrSetup;try{if(o)try{i=o(e,t.url,t)}catch(r){e.open("GET",t.url,!0),i=o(e,t.url,t)}e.readyState||e.open("GET",t.url,!0)}catch(e){i=Promise.reject(e)}(i=i||Promise.resolve()).then((function(){t.rangeEnd&&e.setRequestHeader("Range","bytes="+t.rangeStart+"-"+(t.rangeEnd-1)),e.onreadystatechange=r.readystatechange.bind(r),e.onprogress=r.loadprogress.bind(r),e.responseType=t.responseType,r.requestTimeout=window.setTimeout(r.loadtimeout.bind(r),r.config.timeout),e.send()})).catch((function(a){r.callbacks.onError({code:e.status,text:a.message},t,e)}))},a}(n.a.DefaultConfig.loader);var d,u,h,_=function(e){var r,t;function a(r){var t,o=(t=e.call(this,r)||this).load.bind(function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(t)),n=a.redirectExternalStreamsHandler;return t.load=function(e,r,t){var s=e.url;"manifest"===e.type?i.Utils.Http.jsonp(s,n,{timeout:a.redirectExternalStreamsTimeout}).then((function(a){e.url=a,o(e,r,t)})).catch((function(){return o(e,r,t)})):o(e,r,t)},t}return t=e,(r=a).prototype=Object.create(t.prototype),r.prototype.constructor=r,r.__proto__=t,a}(c);function E(e,r){var t;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(t=function(e,r){if(!e)return;if("string"==typeof e)return g(e,r);var t=Object.prototype.toString.call(e).slice(8,-1);"Object"===t&&e.constructor&&(t=e.constructor.name);if("Map"===t||"Set"===t)return Array.from(e);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return g(e,r)}(e))||r&&e&&"number"==typeof e.length){t&&(e=t);var a=0;return function(){return a>=e.length?{done:!0}:{done:!1,value:e[a++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(t=e[Symbol.iterator]()).next.bind(t)}function g(e,r){(null==r||r>e.length)&&(r=e.length);for(var t=0,a=new Array(r);t<r;t++)a[t]=e[t];return a}function f(e,r){for(var t=0;t<r.length;t++){var a=r[t];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function p(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function v(e,r,t){return r in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}h=function(e,r){return r},(u="redirectExternalStreamsHandler")in(d=_)?Object.defineProperty(d,u,{value:h,enumerable:!0,configurable:!0,writable:!0}):d[u]=h;var T=function(e){var r,t;function a(r,t,o){var l,c;return a._logger.debug("Creating adapter. Hls version: "+n.a.version),v(p(c=e.call(this,r,t,o)||this),"_hlsjsLib",n.a),v(p(c),"_triedReloadWithRedirect",!1),v(p(c),"_playerTracks",[]),v(p(c),"_startTime",0),v(p(c),"_requestFilterError",!1),v(p(c),"_responseFilterError",!1),v(p(c),"_nativeTextTracksMap",{}),v(p(c),"_lastLoadedFragSN",-1),v(p(c),"_sameFragSNLoadedCount",0),v(p(c),"_adapterEventsBindings",((l={})[n.a.Events.ERROR]=function(e,r){return c._onError(r)},l[n.a.Events.MANIFEST_LOADED]=function(e,r){return c._onManifestLoaded(r)},l[n.a.Events.LEVEL_SWITCHED]=function(e,r){return c._onLevelSwitched(e,r)},l[n.a.Events.AUDIO_TRACK_SWITCHED]=function(e,r){return c._onAudioTrackSwitched(e,r)},l[n.a.Events.FPS_DROP]=function(e,r){return c._onFpsDrop(r)},l[n.a.Events.FRAG_PARSING_METADATA]=function(e,r){return c._onFragParsingMetadata(r)},l[n.a.Events.FRAG_LOADED]=function(e,r){return c._onFragLoaded(r)},l[n.a.Events.MEDIA_ATTACHED]=function(){return c._onMediaAttached()},l[n.a.Events.LEVEL_LOADED]=function(e,r){return c._onLevelLoaded(e,r)},l)),v(p(c),"_onLevelLoaded",(function(e,r){if(c.isLive()){var t=r.details.endSN;if(c._lastLoadedFragSN===t){if(c._sameFragSNLoadedCount++,a._logger.debug("Same frag SN. Count is: "+c._sameFragSNLoadedCount+", Max is: "+c._config.network.maxStaleLevelReloads),c._sameFragSNLoadedCount>=c._config.network.maxStaleLevelReloads){a._logger.error("Same frag loading reached max count");var o=new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.NETWORK,i.Error.Code.LIVE_MANIFEST_REFRESH_ERROR,{fragSN:t});return c._trigger(i.EventType.ERROR,o),c.destroy()}a._logger.debug("Last frag SN is: "+t)}else c._sameFragSNLoadedCount=0;c._lastLoadedFragSN=t}})),c._config=i.Utils.Object.mergeDeep({},s,c._config),c._init(),c}t=e,(r=a).prototype=Object.create(t.prototype),r.prototype.constructor=r,r.__proto__=t,a.createAdapter=function(e,r,t){var o=i.Utils.Object.copyDeep(s);if(i.Utils.Object.hasPropertyPath(t,"sources.options")){var n=t.sources.options;o.forceRedirectExternalStreams=n.forceRedirectExternalStreams,o.redirectExternalStreamsHandler=n.redirectExternalStreamsHandler,o.redirectExternalStreamsTimeout=n.redirectExternalStreamsTimeout,_.redirectExternalStreamsHandler=o.redirectExternalStreamsHandler,_.redirectExternalStreamsTimeout=o.redirectExternalStreamsTimeout}i.Utils.Object.hasPropertyPath(t,"sources.startTime")&&(i.Utils.Object.getPropertyPath(t,"sources.startTime")>-1&&(o.hlsConfig.startPosition=t.sources.startTime));if(i.Utils.Object.hasPropertyPath(t,"text.useNativeTextTrack")&&(o.subtitleDisplay=i.Utils.Object.getPropertyPath(t,"text.useNativeTextTrack")),i.Utils.Object.hasPropertyPath(t,"abr.fpsDroppedFramesInterval")&&(o.hlsConfig.fpsDroppedFramesInterval=t.abr.fpsDroppedFramesInterval),i.Utils.Object.hasPropertyPath(t,"abr.fpsDroppedMonitoringThreshold")&&(o.hlsConfig.fpsDroppedMonitoringThreshold=t.abr.fpsDroppedMonitoringThreshold),i.Utils.Object.hasPropertyPath(t,"abr.capLevelOnFPSDrop")&&(a._logger.debug("capLevelOnFPSDrop = ",t.abr.capLevelOnFPSDrop),o.hlsConfig.capLevelOnFPSDrop=t.abr.capLevelOnFPSDrop),i.Utils.Object.hasPropertyPath(t,"text")&&(o.hlsConfig.enableCEA708Captions=t.text.enableCEA708Captions,o.hlsConfig.captionsTextTrack1Label=t.text.captionsTextTrack1Label,o.hlsConfig.captionsTextTrack1LanguageCode=t.text.captionsTextTrack1LanguageCode,o.hlsConfig.captionsTextTrack2Label=t.text.captionsTextTrack2Label,o.hlsConfig.captionsTextTrack2LanguageCode=t.text.captionsTextTrack2LanguageCode),i.Utils.Object.hasPropertyPath(t,"abr")){var l=t.abr;"boolean"==typeof l.enabled&&(o.abr.enabled=l.enabled),"boolean"==typeof l.capLevelToPlayerSize&&(o.hlsConfig.capLevelToPlayerSize=l.capLevelToPlayerSize),l.defaultBandwidthEstimate&&(o.hlsConfig.abrEwmaDefaultEstimate=l.defaultBandwidthEstimate),l.restrictions&&i.Utils.Object.createPropertyPath(o,"abr.restrictions",l.restrictions)}return i.Utils.Object.hasPropertyPath(t,"streaming.lowLatencyMode")&&(o.hlsConfig.lowLatencyMode=i.Utils.Object.getPropertyPath(t,"streaming.lowLatencyMode")),i.Utils.Object.hasPropertyPath(t,"playback.options.html5.hls")&&i.Utils.Object.mergeDeep(o.hlsConfig,t.playback.options.html5.hls),o.network=t.network,new this(e,r,o)},a.canPlayType=function(e){var r="string"==typeof e&&(a._hlsMimeTypes.includes(e.toLowerCase())&&a.isMSESupported());return a._logger.debug("canPlayType result for mimeType:"+e+" is "+r.toString()),r},a.canPlayDrm=function(){return a._logger.warn("canPlayDrm result is false"),!1},a.isSupported=function(){var e=n.a.isSupported();return a._logger.debug("isSupported:"+e),e};var o,d,u,h=a.prototype;return h._init=function(){this._config.forceRedirectExternalStreams&&(this._config.hlsConfig.pLoader=_),this._maybeSetFilters(),this._hls=new n.a(this._config.hlsConfig),this._capabilities.fpsControl=!0,this._hls.subtitleDisplay=this._config.subtitleDisplay,this._addBindings()},h._maybeSetFilters=function(){var e=this;if("function"==typeof i.Utils.Object.getPropertyPath(this._config,"network.requestFilter")&&(a._logger.debug("Register request filter"),i.Utils.Object.mergeDeep(this._config.hlsConfig,{loader:c,xhrSetup:function(r,t,a){var o,n={url:t,body:null,headers:{}};try{"manifest"===a.type&&(o=e._config.network.requestFilter(i.RequestType.MANIFEST,n)),a.frag&&"subtitle"!==a.frag.type&&(o=e._config.network.requestFilter(i.RequestType.SEGMENT,n))}catch(e){o=Promise.reject(e)}return(o=o||Promise.resolve(n)).then((function(e){a.url=e.url,r.open("GET",e.url,!0),Object.entries(e.headers).forEach((function(e){r.setRequestHeader.apply(r,e)})),"boolean"==typeof e.withCredentials&&(r.withCredentials=e.withCredentials)})).catch((function(r){throw e._requestFilterError=!0,r}))}})),"function"==typeof i.Utils.Object.getPropertyPath(this._config,"network.responseFilter")){var r=this;a._logger.debug("Register response filter"),i.Utils.Object.mergeDeep(this._config.hlsConfig,{loader:c,readystatechange:function(e){var t=this,o=e.currentTarget,n=o.readyState,s=this.stats,l=this.context,c=this.config;if(!s.aborted&&n>=2){window.clearTimeout(this.requestTimeout);var d=s.loading;if(0===d.first&&(d.first=Math.max(performance.now(),d.start)),4===n){var u=o.status;if(u>=200&&u<300){var h,_;d.end=Math.max(s.tfirst,performance.now()),_="arraybuffer"===l.responseType?(h=o.response).byteLength:(h=o.responseText).length,s.loaded=s.total=_;var E,g={url:o.responseURL,originalUrl:l.url,data:h,headers:i.Utils.Http.convertHeadersToDictionary(o.getAllResponseHeaders())};try{"manifest"===l.type&&(E=r._config.network.responseFilter(i.RequestType.MANIFEST,g)),l.frag&&"subtitle"!==l.frag.type&&(E=r._config.network.responseFilter(i.RequestType.SEGMENT,g))}catch(e){E=Promise.reject(e)}return(E=E||Promise.resolve(g)).then((function(e){t.callbacks.onSuccess(e,s,l,o)})).catch((function(e){r._responseFilterError=!0,t.callbacks.onError({code:u,text:e.message},l,o)}))}s.retry>=c.maxRetry||u>=400&&u<499?(a._logger.error(u+" while loading "+l.url),this.callbacks.onError({code:u,text:o.statusText},l,o)):(a._logger.warn(u+" while loading "+l.url+", retrying in "+this.retryDelay+"..."),this.destroy(),this.retryTimeout=window.setTimeout(this.loadInternal.bind(this),this.retryDelay),this.retryDelay=Math.min(2*this.retryDelay,c.maxRetryDelay),s.retry++)}else this.requestTimeout=window.setTimeout(this.loadtimeout.bind(this),c.timeout)}}})}},h._addBindings=function(){var e=this;this._mediaAttachedPromise=new Promise((function(r){return e._onMediaAttached=r}));for(var r=0,t=Object.entries(this._adapterEventsBindings);r<t.length;r++){var a=t[r],i=a[0],o=a[1];this._hls.on(i,o)}this._onRecoveredCallback=function(){return e._onRecovered()},this._onAddTrack=this._onAddTrack.bind(this),this._eventManager.listen(this._videoElement,"addtrack",this._onAddTrack),this._videoElement.textTracks.onaddtrack=this._onAddTrack},h._onFpsDrop=function(e){this._trigger(i.EventType.FPS_DROP,e)},h._onFragParsingMetadata=function(e){var r;this._trigger("hlsFragParsingMetadata",e);var t=Array.from(null==(r=this._videoElement)?void 0:r.textTracks).find((function(e){return"id3"===e.label})),a=Array.from((null==t?void 0:t.cues)||[]),o=[];null==e||e.samples.forEach((function(e){var r=i.Utils.binarySearch(a,(function(r){return r.startTime-e.pts}));if(r){var t=Object(i.createTimedMetadata)(r);o.push(t)}})),o.length&&this._trigger(i.EventType.TIMED_METADATA_ADDED,{cues:o})},h._onAddTrack=function(e){if(!this._hls.subtitleTracks.length){var r=this._parseCEATextTrack(e.track);r&&(a._logger.debug("A CEA 608/708 caption has been found",r),this._playerTracks.push(r),this._trigger(i.EventType.TRACKS_CHANGED,{tracks:this._playerTracks}))}},h.attachMediaSource=function(){this._hls||(this._videoElement&&this._videoElement.src&&(i.Utils.Dom.setAttribute(this._videoElement,"src",""),i.Utils.Dom.removeAttribute(this._videoElement,"src")),this._init())},h.detachMediaSource=function(){var e;this._hls&&(0===Math.floor(this.duration-this.currentTime)?this._config.hlsConfig.startPosition=0:this.currentTime>0&&(this._config.hlsConfig.startPosition=this.currentTime),this._reset(),null==(e=this._loadPromiseHandlers)||e.reject(new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.PLAYER,i.Error.Code.HLS_FATAL_MEDIA_ERROR,"media detached while loading")),this._loadPromiseHandlers=null,this._loadPromise=null,this._hls=null)},h.handleMediaError=function(e){return e.code===e.MEDIA_ERR_DECODE&&(a._logger.debug("The video playback was aborted due to a corruption problem or because the video used features your browser did not support.",e.message),this._handleMediaError(n.a.ErrorDetails.MANIFEST_INCOMPATIBLE_CODECS_ERROR))},h.load=function(e){var r=this;return this._loadPromise||(this._startTime=e,this._loadPromise=new Promise((function(e,t){r._loadPromiseHandlers={resolve:e,reject:t},r._loadInternal()}))),this._loadPromise},h._loadInternal=function(){var e;this._hls&&this._sourceObj&&this._sourceObj.url?(this._hls.loadSource(this._sourceObj.url),this._hls.attachMedia(this._videoElement),this._trigger(i.EventType.ABR_MODE_CHANGED,{mode:this.isAdaptiveBitrateEnabled()?"auto":"manual"})):null==(e=this._loadPromiseHandlers)||e.reject(new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.PLAYER,i.Error.Code.HLS_FATAL_MEDIA_ERROR,"no url provided"))},h._reloadWithDirectManifest=function(){this._triedReloadWithRedirect=!0,this._reset(),this._config.hlsConfig.pLoader=_,this._hls=new n.a(this._config.hlsConfig),this._addBindings(),this._loadInternal()},h.destroy=function(){var r=this;return new Promise((function(t,o){e.prototype.destroy.call(r).then((function(){var e;a._logger.debug("destroy"),r._playerTracks=[],r._nativeTextTracksMap={},r._sameFragSNLoadedCount=0,r._lastLoadedFragSN=-1,null==(e=r._loadPromiseHandlers)||e.reject(new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.PLAYER,i.Error.Code.HLS_FATAL_MEDIA_ERROR,"The adapter has been destroyed while loading")),r._loadPromiseHandlers=null,r._loadPromise=null,r._reset(),t()}),(function(){return o()}))}))},h._reset=function(){this._removeBindings(),this._requestFilterError=!1,this._responseFilterError=!1,this._hls.detachMedia(),this._hls.destroy()},h._parseTracks=function(){var e=this._parseAudioTracks(this._hls.audioTracks||[]),r=this._parseVideoTracks(this._hls.levels||[]),t=this._parseTextTracks(this._hls.subtitleTracks||[]);return e.concat(r).concat(t)},h._parseAudioTracks=function(e){for(var r=[],t=0;t<e.length;t++){var a={id:e[t].id,active:this._hls.audioTrack===e[t].id,label:e[t].name,language:e[t].lang,index:t};r.push(new i.AudioTrack(a))}return r},h._parseVideoTracks=function(e){for(var r=[],t=0;t<e.length;t++){var a={active:this._hls.startLevel===t,bandwidth:e[t].bitrate,width:e[t].width,height:e[t].height,language:"",index:t};r.push(new i.VideoTrack(a))}return r},h._parseTextTracks=function(e){for(var r,t=[],a=E(e);!(r=a()).done;){var o=r.value,n={id:o.id,active:!1,default:o.default,label:o.name,kind:o.type.toLowerCase(),language:o.lang};t.push(new i.TextTrack(n))}return t},h._parseCEATextTrack=function(e){var r=null;if("captions"===e.kind){var t={id:e.id,active:"showing"===e.mode,label:e.label,kind:e.kind,language:e.language};r=new i.TextTrack(t),this._nativeTextTracksMap[r.index]=e}return r},h.selectAudioTrack=function(e){e instanceof i.AudioTrack&&!e.active&&this._hls.audioTracks&&(this._hls.audioTrack=e.id)},h.selectVideoTrack=function(e){e instanceof i.VideoTrack&&(!e.active||this.isAdaptiveBitrateEnabled())&&this._hls.levels&&(this.isAdaptiveBitrateEnabled()&&this._trigger(i.EventType.ABR_MODE_CHANGED,{mode:"manual"}),this._hls.currentLevel=e.index)},h.selectTextTrack=function(e){e instanceof i.TextTrack&&!e.active&&this._hls&&(this._hls.subtitleTracks.length?(this._hls.subtitleTrack=e.id,this._notifyTrackChanged(e)):this._selectNativeTextTrack(e))},h._selectNativeTextTrack=function(e){var r=this._nativeTextTracksMap[e.index];r&&(this.disableNativeTextTracks(),r.mode=this._config.subtitleDisplay?"showing":"hidden",this._notifyTrackChanged(e))},h._notifyTrackChanged=function(e){this._onTrackChanged(e)},h.hideTextTrack=function(){this._hls&&(this._hls.subtitleTracks.length?this._hls.subtitleTrack=-1:this.disableNativeTextTracks())},h.enableAdaptiveBitrate=function(){this.isAdaptiveBitrateEnabled()||(this._trigger(i.EventType.ABR_MODE_CHANGED,{mode:"auto"}),this._hls.nextLevel=-1)},h.isAdaptiveBitrateEnabled=function(){return!!this._hls&&this._hls.autoLevelEnabled},h.applyABRRestriction=function(e){i.Utils.Object.createPropertyPath(this._config,"abr.restrictions",e),this._hls.capLevelToPlayerSize||this._maybeApplyAbrRestrictions(e)},h._getLevelDetails=function(){var e=this._hls.levels[this._hls.currentLevel]||this._hls.levels[this._hls.nextLevel]||this._hls.levels[this._hls.nextAutoLevel]||this._hls.levels[this._hls.nextLoadLevel];return e&&e.details?e.details:{}},h._getLiveEdge=function(){try{var e;return(e=this._hls.liveSyncPosition?this._hls.liveSyncPosition:this._hls.config.liveSyncDuration?this._videoElement.duration-this._hls.config.liveSyncDuration:this._videoElement.duration-this._hls.config.liveSyncDurationCount*this._getLevelDetails().targetduration)>0?e:this._videoElement.duration}catch(e){return a._logger.debug("Live edge calculation failed, fall back to duration"),this._videoElement.duration}},h.seekToLiveEdge=function(){try{this._videoElement.currentTime=this._getLiveEdge()}catch(e){return}},h.getSegmentDuration=function(){var e=i.Utils.Object.getPropertyPath(this._hls,"streamController.fragCurrent");return e?e.duration:0},h.isLive=function(){try{return!!this._getLevelDetails().live}catch(e){return!1}},h._onManifestLoaded=function(e){var r=this;a._logger.debug("The source has been loaded successfully"),this._hls.config.autoStartLoad||this._hls.startLoad(this._startTime),this._playerTracks=this._parseTracks(),this._config.abr.enabled||(this._hls.currentLevel=0),this._mediaAttachedPromise.then((function(){var e;null==(e=r._loadPromiseHandlers)||e.resolve({tracks:r._playerTracks}),r._loadPromiseHandlers=null}));var t=e.stats.loading,o=t.end-t.start;this._trigger(i.EventType.MANIFEST_LOADED,{miliSeconds:o})},h._maybeApplyAbrRestrictions=function(e){var r=this._playerTracks.filter((function(e){return e instanceof i.VideoTrack})),t=Object(i.filterTracksByRestriction)(r,e);if(t.length){var o=t[0],n=t.pop();this._hls.config.minAutoBitrate=o.bandwidth,this._hls.autoLevelCapping=n.index;var s=t.some((function(e){return e.active}));this.isAdaptiveBitrateEnabled()||s||this.selectVideoTrack(o)}else a._logger.warn("Invalid restrictions, there are not tracks within the restriction range")},h._onLevelSwitched=function(e,r){var t=this._playerTracks.find((function(e){return e instanceof i.VideoTrack&&e.index===r.level}));this._onTrackChanged(t)},h._onAudioTrackSwitched=function(e,r){var t=this._playerTracks.find((function(e){return e instanceof i.AudioTrack&&e.id===r.id}));this._onTrackChanged(t),this._handleWaitingUponAudioTrackSwitch()},h._handleWaitingUponAudioTrackSwitch=function(){var e=this;if(["IE","Edge"].includes(i.Env.browser.name)){this._eventManager.listenOnce(this._videoElement,i.EventType.TIME_UPDATE,(function(){e._trigger(i.EventType.PLAYING)}))}},h._getErrorDataObject=function(e){var r={};switch(r.name=e.details,r.name){case n.a.ErrorDetails.MANIFEST_LOAD_ERROR:case n.a.ErrorDetails.LEVEL_LOAD_ERROR:case n.a.ErrorDetails.AUDIO_TRACK_LOAD_ERROR:r.url=e.url,r.responseCode=e.response?e.response.code:null;break;case n.a.ErrorDetails.MANIFEST_LOAD_TIMEOUT:case n.a.ErrorDetails.LEVEL_LOAD_TIMEOUT:case n.a.ErrorDetails.AUDIO_TRACK_LOAD_TIMEOUT:r.url=e.url;break;case n.a.ErrorDetails.MANIFEST_PARSING_ERROR:r.url=e.url,r.reason=e.reason;break;case n.a.ErrorDetails.LEVEL_SWITCH_ERROR:r.level=e.level,r.reason=e.reason;break;case n.a.ErrorDetails.FRAG_LOAD_ERROR:r.fragUrl=e.frag?e.frag.url:null,r.responseCode=e.response?e.response.code:null;break;case n.a.ErrorDetails.FRAG_LOAD_TIMEOUT:r.fragUrl=e.frag?e.frag.url:null;break;case n.a.ErrorDetails.FRAG_DECRYPT_ERROR:case n.a.ErrorDetails.FRAG_PARSING_ERROR:r.reason=e.reason;break;case n.a.ErrorDetails.KEY_LOAD_ERROR:r.fragDecryptedDataUri=e.frag&&e.frag.decryptdata?e.frag.decryptdata.uri:null,r.responseCode=e.response?e.response.code:null;break;case n.a.ErrorDetails.KEY_LOAD_TIMEOUT:r.fragDecryptedDataUri=e.frag&&e.frag.decryptdata?e.frag.decryptdata.uri:null;break;case n.a.ErrorDetails.BUFFER_ADD_CODEC_ERROR:r.mimeType=e.mimeType,r.errorMsg=e.err?e.err.message:null;break;case n.a.ErrorDetails.BUFFER_STALLED_ERROR:r.buffer=e.buffer}return(this._requestFilterError||this._responseFilterError)&&(r.reason=e.response.text),r},h._onError=function(e){var r=e.type,t=e.details,o=e.fatal,s=this._getErrorDataObject(e);if(o){var c;switch(r){case n.a.ErrorTypes.NETWORK_ERROR:var d;d=this._requestFilterError?i.Error.Code.REQUEST_FILTER_ERROR:this._responseFilterError?i.Error.Code.RESPONSE_FILTER_ERROR:i.Error.Code.HTTP_ERROR,![n.a.ErrorDetails.MANIFEST_LOAD_ERROR,n.a.ErrorDetails.MANIFEST_LOAD_TIMEOUT].includes(t)||this._triedReloadWithRedirect||this._config.forceRedirectExternalStreams||this._requestFilterError||this._responseFilterError?c=new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.NETWORK,d,s):(c=new i.Error(i.Error.Severity.RECOVERABLE,i.Error.Category.NETWORK,d,s),this._reloadWithDirectManifest());break;case n.a.ErrorTypes.MEDIA_ERROR:c=this._handleMediaError(t)?new i.Error(i.Error.Severity.RECOVERABLE,i.Error.Category.MEDIA,i.Error.Code.HLS_FATAL_MEDIA_ERROR,s):new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.MEDIA,i.Error.Code.HLS_FATAL_MEDIA_ERROR,s);break;default:c=new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.PLAYER,i.Error.Code.HLS_FATAL_MEDIA_ERROR,s)}if(this._trigger(i.EventType.ERROR,c),c&&c.severity===i.Error.Severity.CRITICAL){var u;if(this._loadPromiseHandlers)null==(u=this._loadPromiseHandlers)||u.reject(c),this._loadPromiseHandlers=null,this._loadPromise=null;this.destroy()}}else{var h=this._requestFilterError||this._responseFilterError?{category:i.Error.Category.NETWORK,code:this._requestFilterError?i.Error.Code.REQUEST_FILTER_ERROR:i.Error.Code.RESPONSE_FILTER_ERROR}:l[t]||{category:0,code:0},_=h.category,E=h.code;a._logger.warn(new i.Error(i.Error.Severity.RECOVERABLE,_,E,s))}this._requestFilterError=!1,this._responseFilterError=!1},h._handleMediaError=function(e){a._logger.error("_handleMediaError mediaErrorName:",e);var r=performance.now(),t=!0;return e===n.a.ErrorDetails.MANIFEST_INCOMPATIBLE_CODECS_ERROR?(a._logger.error("recover aborted due to: MANIFEST_INCOMPATIBLE_CODECS_ERROR"),t=!1):this._checkTimeDeltaHasPassed(r,this._recoverDecodingErrorDate,this._config.recoverDecodingErrorDelay)?(this._eventManager.listen(this._videoElement,i.EventType.LOADED_METADATA,this._onRecoveredCallback),a._logger.debug("try to recover using: _recoverDecodingError()"),this._recoverDecodingError()):this._checkTimeDeltaHasPassed(r,this._recoverSwapAudioCodecDate,this._config.recoverSwapAudioCodecDelay)?(this._eventManager.listen(this._videoElement,i.EventType.LOADED_METADATA,this._onRecoveredCallback),a._logger.debug("try to recover using: _recoverSwapAudioCodec()"),this._recoverSwapAudioCodec()):(a._logger.error("cannot recover, last media error recovery failed error: ",e),t=!1),t},h._onRecovered=function(){this._trigger(i.EventType.MEDIA_RECOVERED),this._videoElement.removeEventListener(i.EventType.LOADED_METADATA,this._onRecoveredCallback)},h._checkTimeDeltaHasPassed=function(e,r,t){return!r||e-r>t},h._recoverDecodingError=function(){this._recoverDecodingErrorDate=performance.now(),a._logger.warn("try to recover media Error"),this._hls.recoverMediaError()},h._recoverSwapAudioCodec=function(){this._recoverSwapAudioCodecDate=performance.now(),a._logger.warn("try to swap Audio Codec and recover media Error"),this._hls.swapAudioCodec(),this._hls.recoverMediaError()},h._removeBindings=function(){for(var e=0,r=Object.entries(this._adapterEventsBindings);e<r.length;e++){var t=r[e],a=t[0],i=t[1];this._hls.off(a,i)}this._videoElement.textTracks.onaddtrack=null,this._onRecoveredCallback=null,this._eventManager&&this._eventManager.removeAll()},h.getStartTimeOfDvrWindow=function(){if(!this.isLive())return 0;try{var e=this._hls.levels[this._hls.nextLoadLevel].details,r=e.fragments,t=r.length,i=r[0].start+r[0].duration,o=r[t-1].start+r[t-1].duration,n=void 0!==this._hls.config.liveMaxLatencyDuration?this._hls.config.liveMaxLatencyDuration:this._hls.config.liveMaxLatencyDurationCount*e.targetduration;return Math.max(i-this._hls.config.maxFragLookUpTolerance,o-n)}catch(e){return a._logger.debug("Unable obtain the start of DVR window"),0}},h._onFragLoaded=function(e){if(i.Utils.Object.hasPropertyPath(e,"frag.stats.loading")){var r=e.frag.stats,t=r.loading.end-r.loading.start;this._trigger(i.EventType.FRAG_LOADED,{miliSeconds:t,bytes:r.loaded,url:e.frag.url})}},h._getLiveTargetBuffer=function(){return this._hls.config.liveSyncDuration?this._hls.config.liveSyncDuration:this._hls.config.liveSyncDurationCount*this._getLevelDetails().targetduration},o=a,(d=[{key:"liveDuration",get:function(){return this._getLiveEdge()+this.getSegmentDuration()}},{key:"targetBuffer",get:function(){var e=NaN;return this._hls?(e=this.isLive()?this._getLiveTargetBuffer()-(this._videoElement.currentTime-this._getLiveEdge()):this._videoElement.duration-this._videoElement.currentTime,e=Math.min(e,this._hls.config.maxMaxBufferLength+this._getLevelDetails().targetduration)):NaN}}])&&f(o.prototype,d),u&&f(o,u),a}(i.BaseMediaSourceAdapter);v(T,"id","HlsAdapter"),v(T,"_logger",i.BaseMediaSourceAdapter.getLogger(T.id)),v(T,"_hlsMimeTypes",["application/x-mpegurl","application/vnd.apple.mpegurl","audio/mpegurl","audio/x-mpegurl","video/x-mpegurl","video/mpegurl","application/mpegurl"]);var y="1.32.3",R="@playkit-js/playkit-js-hls";r.default=T;T.isSupported()&&Object(i.registerMediaSourceAdapter)(T)}])}));
1
+ !function(e,r){"object"==typeof exports&&"object"==typeof module?module.exports=r(require("@playkit-js/playkit-js"),require("hls.js")):"function"==typeof define&&define.amd?define("hls",["playkit-js","hls.js"],r):"object"==typeof exports?exports.hls=r(require("@playkit-js/playkit-js"),require("hls.js")):(e.playkit=e.playkit||{},e.playkit.hls=r(e.playkit.core,e.Hls))}(window,(function(e,r){return function(e){var r={};function t(a){if(r[a])return r[a].exports;var i=r[a]={i:a,l:!1,exports:{}};return e[a].call(i.exports,i,i.exports,t),i.l=!0,i.exports}return t.m=e,t.c=r,t.d=function(e,r,a){t.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:a})},t.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},t.t=function(e,r){if(1&r&&(e=t(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var a=Object.create(null);if(t.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var i in e)t.d(a,i,function(r){return e[r]}.bind(null,i));return a},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},t.p="",t(t.s=3)}([function(r,t){r.exports=e},function(e,t){e.exports=r},function(e){e.exports=JSON.parse('{"recoverDecodingErrorDelay":3000,"recoverSwapAudioCodecDelay":3000,"abr":{"enabled":true,"restrictions":{}},"hlsConfig":{"fragLoadingMaxRetry":4,"maxMaxBufferLength":60},"network":{}}')},function(e,r,t){"use strict";t.r(r),t.d(r,"VERSION",(function(){return y})),t.d(r,"NAME",(function(){return R}));var a,i=t(0),o=t(1),n=t.n(o),s=t(2),l=((a={})[n.a.ErrorDetails.MANIFEST_LOAD_ERROR]={category:i.Error.Category.MANIFEST,code:i.Error.Code.HTTP_ERROR},a[n.a.ErrorDetails.MANIFEST_LOAD_TIMEOUT]={category:i.Error.Category.MANIFEST,code:i.Error.Code.TIMEOUT},a[n.a.ErrorDetails.MANIFEST_PARSING_ERROR]={category:i.Error.Category.MANIFEST,code:i.Error.Code.HLSJS_CANNOT_PARSE},a[n.a.ErrorDetails.LEVEL_LOAD_ERROR]={category:i.Error.Category.NETWORK,code:i.Error.Code.HTTP_ERROR},a[n.a.ErrorDetails.LEVEL_LOAD_TIMEOUT]={category:i.Error.Category.NETWORK,code:i.Error.Code.TIMEOUT},a[n.a.ErrorDetails.LEVEL_SWITCH_ERROR]={category:i.Error.Category.PLAYER,code:i.Error.Code.BITRATE_SWITCH_ISSUE},a[n.a.ErrorDetails.FRAG_LOAD_ERROR]={category:i.Error.Category.NETWORK,code:i.Error.Code.HTTP_ERROR},a[n.a.ErrorDetails.FRAG_LOOP_LOADING_ERROR]={category:i.Error.Category.NETWORK,code:i.Error.Code.HTTP_ERROR},a[n.a.ErrorDetails.FRAG_LOAD_TIMEOUT]={category:i.Error.Category.NETWORK,code:i.Error.Code.TIMEOUT},a[n.a.ErrorDetails.FRAG_PARSING_ERROR]={category:i.Error.Category.MEDIA,code:i.Error.Code.HLS_FRAG_PARSING_ERROR},a[n.a.ErrorDetails.BUFFER_APPEND_ERROR]={category:i.Error.Category.MEDIA,code:i.Error.Code.HLS_BUFFER_APPEND_ISSUE},a[n.a.ErrorDetails.BUFFER_APPENDING_ERROR]={category:i.Error.Category.MEDIA,code:i.Error.Code.HLS_BUFFER_APPENDING_ISSUE},a[n.a.ErrorDetails.BUFFER_STALLED_ERROR]={category:i.Error.Category.MEDIA,code:i.Error.Code.HLS_BUFFER_STALLED_ERROR},a);var c=function(e){var r,t;function a(r){var t;return t=e.call(this,r)||this,r&&r.readystatechange&&(t.readystatechange=r.readystatechange),t}return t=e,(r=a).prototype=Object.create(t.prototype),r.prototype.constructor=r,r.__proto__=t,a.prototype.loadInternal=function(){var e,r=this,t=this.context;e=this.loader=new XMLHttpRequest;var a=this.stats;a.tfirst=0,a.loaded=0;var i,o=this.xhrSetup;try{if(o)try{i=o(e,t.url,t)}catch(r){e.open("GET",t.url,!0),i=o(e,t.url,t)}e.readyState||e.open("GET",t.url,!0)}catch(e){i=Promise.reject(e)}(i=i||Promise.resolve()).then((function(){t.rangeEnd&&e.setRequestHeader("Range","bytes="+t.rangeStart+"-"+(t.rangeEnd-1)),e.onreadystatechange=r.readystatechange.bind(r),e.onprogress=r.loadprogress.bind(r),e.responseType=t.responseType,r.requestTimeout=window.setTimeout(r.loadtimeout.bind(r),r.config.timeout),e.send()})).catch((function(a){r.callbacks.onError({code:e.status,text:a.message},t,e)}))},a}(n.a.DefaultConfig.loader);var d,u,h,_=function(e){var r,t;function a(r){var t,o=(t=e.call(this,r)||this).load.bind(function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(t)),n=a.redirectExternalStreamsHandler;return t.load=function(e,r,t){var s=e.url;"manifest"===e.type?i.Utils.Http.jsonp(s,n,{timeout:a.redirectExternalStreamsTimeout}).then((function(a){e.url=a,o(e,r,t)})).catch((function(){return o(e,r,t)})):o(e,r,t)},t}return t=e,(r=a).prototype=Object.create(t.prototype),r.prototype.constructor=r,r.__proto__=t,a}(c);function E(e,r){var t;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(t=function(e,r){if(!e)return;if("string"==typeof e)return g(e,r);var t=Object.prototype.toString.call(e).slice(8,-1);"Object"===t&&e.constructor&&(t=e.constructor.name);if("Map"===t||"Set"===t)return Array.from(e);if("Arguments"===t||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t))return g(e,r)}(e))||r&&e&&"number"==typeof e.length){t&&(e=t);var a=0;return function(){return a>=e.length?{done:!0}:{done:!1,value:e[a++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(t=e[Symbol.iterator]()).next.bind(t)}function g(e,r){(null==r||r>e.length)&&(r=e.length);for(var t=0,a=new Array(r);t<r;t++)a[t]=e[t];return a}function f(e,r){for(var t=0;t<r.length;t++){var a=r[t];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(e,a.key,a)}}function p(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function v(e,r,t){return r in e?Object.defineProperty(e,r,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[r]=t,e}h=function(e,r){return r},(u="redirectExternalStreamsHandler")in(d=_)?Object.defineProperty(d,u,{value:h,enumerable:!0,configurable:!0,writable:!0}):d[u]=h;var T=function(e){var r,t;function a(r,t,o){var l,c;return a._logger.debug("Creating adapter. Hls version: "+n.a.version),v(p(c=e.call(this,r,t,o)||this),"_hlsjsLib",n.a),v(p(c),"_triedReloadWithRedirect",!1),v(p(c),"_playerTracks",[]),v(p(c),"_startTime",0),v(p(c),"_requestFilterError",!1),v(p(c),"_responseFilterError",!1),v(p(c),"_nativeTextTracksMap",{}),v(p(c),"_lastLoadedFragSN",-1),v(p(c),"_sameFragSNLoadedCount",0),v(p(c),"_adapterEventsBindings",((l={})[n.a.Events.ERROR]=function(e,r){return c._onError(r)},l[n.a.Events.MANIFEST_LOADED]=function(e,r){return c._onManifestLoaded(r)},l[n.a.Events.LEVEL_SWITCHED]=function(e,r){return c._onLevelSwitched(e,r)},l[n.a.Events.AUDIO_TRACK_SWITCHED]=function(e,r){return c._onAudioTrackSwitched(e,r)},l[n.a.Events.FPS_DROP]=function(e,r){return c._onFpsDrop(r)},l[n.a.Events.FRAG_PARSING_METADATA]=function(e,r){return c._onFragParsingMetadata(r)},l[n.a.Events.FRAG_LOADED]=function(e,r){return c._onFragLoaded(r)},l[n.a.Events.MEDIA_ATTACHED]=function(){return c._onMediaAttached()},l[n.a.Events.LEVEL_LOADED]=function(e,r){return c._onLevelLoaded(e,r)},l)),v(p(c),"_onLevelLoaded",(function(e,r){if(c.isLive()){var t=r.details.endSN;if(c._lastLoadedFragSN===t){if(c._sameFragSNLoadedCount++,a._logger.debug("Same frag SN. Count is: "+c._sameFragSNLoadedCount+", Max is: "+c._config.network.maxStaleLevelReloads),c._sameFragSNLoadedCount>=c._config.network.maxStaleLevelReloads){a._logger.error("Same frag loading reached max count");var o=new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.NETWORK,i.Error.Code.LIVE_MANIFEST_REFRESH_ERROR,{fragSN:t});return c._trigger(i.EventType.ERROR,o),c.destroy()}a._logger.debug("Last frag SN is: "+t)}else c._sameFragSNLoadedCount=0;c._lastLoadedFragSN=t}})),c._config=i.Utils.Object.mergeDeep({},s,c._config),c._init(),c}t=e,(r=a).prototype=Object.create(t.prototype),r.prototype.constructor=r,r.__proto__=t,a.createAdapter=function(e,r,t){var o=i.Utils.Object.copyDeep(s);if(i.Utils.Object.hasPropertyPath(t,"sources.options")){var n=t.sources.options;o.forceRedirectExternalStreams=n.forceRedirectExternalStreams,o.redirectExternalStreamsHandler=n.redirectExternalStreamsHandler,o.redirectExternalStreamsTimeout=n.redirectExternalStreamsTimeout,_.redirectExternalStreamsHandler=o.redirectExternalStreamsHandler,_.redirectExternalStreamsTimeout=o.redirectExternalStreamsTimeout}i.Utils.Object.hasPropertyPath(t,"sources.startTime")&&(i.Utils.Object.getPropertyPath(t,"sources.startTime")>-1&&(o.hlsConfig.startPosition=t.sources.startTime));if(i.Utils.Object.hasPropertyPath(t,"text.useNativeTextTrack")&&(o.subtitleDisplay=i.Utils.Object.getPropertyPath(t,"text.useNativeTextTrack")),i.Utils.Object.hasPropertyPath(t,"abr.fpsDroppedFramesInterval")&&(o.hlsConfig.fpsDroppedFramesInterval=t.abr.fpsDroppedFramesInterval),i.Utils.Object.hasPropertyPath(t,"abr.fpsDroppedMonitoringThreshold")&&(o.hlsConfig.fpsDroppedMonitoringThreshold=t.abr.fpsDroppedMonitoringThreshold),i.Utils.Object.hasPropertyPath(t,"abr.capLevelOnFPSDrop")&&(a._logger.debug("capLevelOnFPSDrop = ",t.abr.capLevelOnFPSDrop),o.hlsConfig.capLevelOnFPSDrop=t.abr.capLevelOnFPSDrop),i.Utils.Object.hasPropertyPath(t,"text")&&(o.hlsConfig.enableCEA708Captions=t.text.enableCEA708Captions,o.hlsConfig.captionsTextTrack1Label=t.text.captionsTextTrack1Label,o.hlsConfig.captionsTextTrack1LanguageCode=t.text.captionsTextTrack1LanguageCode,o.hlsConfig.captionsTextTrack2Label=t.text.captionsTextTrack2Label,o.hlsConfig.captionsTextTrack2LanguageCode=t.text.captionsTextTrack2LanguageCode),i.Utils.Object.hasPropertyPath(t,"abr")){var l=t.abr;"boolean"==typeof l.enabled&&(o.abr.enabled=l.enabled),"boolean"==typeof l.capLevelToPlayerSize&&(o.hlsConfig.capLevelToPlayerSize=l.capLevelToPlayerSize),l.defaultBandwidthEstimate&&(o.hlsConfig.abrEwmaDefaultEstimate=l.defaultBandwidthEstimate),l.restrictions&&i.Utils.Object.createPropertyPath(o,"abr.restrictions",l.restrictions)}return i.Utils.Object.hasPropertyPath(t,"streaming.lowLatencyMode")&&(o.hlsConfig.lowLatencyMode=i.Utils.Object.getPropertyPath(t,"streaming.lowLatencyMode")),i.Utils.Object.hasPropertyPath(t,"playback.options.html5.hls")&&i.Utils.Object.mergeDeep(o.hlsConfig,t.playback.options.html5.hls),o.network=t.network,new this(e,r,o)},a.canPlayType=function(e){var r="string"==typeof e&&(a._hlsMimeTypes.includes(e.toLowerCase())&&a.isMSESupported());return a._logger.debug("canPlayType result for mimeType:"+e+" is "+r.toString()),r},a.canPlayDrm=function(){return a._logger.warn("canPlayDrm result is false"),!1},a.isSupported=function(){var e=n.a.isSupported();return a._logger.debug("isSupported:"+e),e};var o,d,u,h=a.prototype;return h._init=function(){this._config.forceRedirectExternalStreams&&(this._config.hlsConfig.pLoader=_),this._maybeSetFilters(),this._hls=new n.a(this._config.hlsConfig),this._capabilities.fpsControl=!0,this._hls.subtitleDisplay=this._config.subtitleDisplay,this._addBindings()},h._maybeSetFilters=function(){var e=this;if("function"==typeof i.Utils.Object.getPropertyPath(this._config,"network.requestFilter")&&(a._logger.debug("Register request filter"),i.Utils.Object.mergeDeep(this._config.hlsConfig,{loader:c,xhrSetup:function(r,t,a){var o,n={url:t,body:null,headers:{}};try{"manifest"===a.type&&(o=e._config.network.requestFilter(i.RequestType.MANIFEST,n)),a.frag&&"subtitle"!==a.frag.type&&(o=e._config.network.requestFilter(i.RequestType.SEGMENT,n))}catch(e){o=Promise.reject(e)}return(o=o||Promise.resolve(n)).then((function(e){a.url=e.url,r.open("GET",e.url,!0),Object.entries(e.headers).forEach((function(e){r.setRequestHeader.apply(r,e)})),"boolean"==typeof e.withCredentials&&(r.withCredentials=e.withCredentials)})).catch((function(r){throw e._requestFilterError=!0,r}))}})),"function"==typeof i.Utils.Object.getPropertyPath(this._config,"network.responseFilter")){var r=this;a._logger.debug("Register response filter"),i.Utils.Object.mergeDeep(this._config.hlsConfig,{loader:c,readystatechange:function(e){var t=this,o=e.currentTarget,n=o.readyState,s=this.stats,l=this.context,c=this.config;if(!s.aborted&&n>=2){window.clearTimeout(this.requestTimeout);var d=s.loading;if(0===d.first&&(d.first=Math.max(performance.now(),d.start)),4===n){var u=o.status;if(u>=200&&u<300){var h,_;d.end=Math.max(s.tfirst,performance.now()),_="arraybuffer"===l.responseType?(h=o.response).byteLength:(h=o.responseText).length,s.loaded=s.total=_;var E,g={url:o.responseURL,originalUrl:l.url,data:h,headers:i.Utils.Http.convertHeadersToDictionary(o.getAllResponseHeaders())};try{"manifest"===l.type&&(E=r._config.network.responseFilter(i.RequestType.MANIFEST,g)),l.frag&&"subtitle"!==l.frag.type&&(E=r._config.network.responseFilter(i.RequestType.SEGMENT,g))}catch(e){E=Promise.reject(e)}return(E=E||Promise.resolve(g)).then((function(e){t.callbacks.onSuccess(e,s,l,o)})).catch((function(e){r._responseFilterError=!0,t.callbacks.onError({code:u,text:e.message},l,o)}))}s.retry>=c.maxRetry||u>=400&&u<499?(a._logger.error(u+" while loading "+l.url),this.callbacks.onError({code:u,text:o.statusText},l,o)):(a._logger.warn(u+" while loading "+l.url+", retrying in "+this.retryDelay+"..."),this.destroy(),this.retryTimeout=window.setTimeout(this.loadInternal.bind(this),this.retryDelay),this.retryDelay=Math.min(2*this.retryDelay,c.maxRetryDelay),s.retry++)}else this.requestTimeout=window.setTimeout(this.loadtimeout.bind(this),c.timeout)}}})}},h._addBindings=function(){var e=this;this._mediaAttachedPromise=new Promise((function(r){return e._onMediaAttached=r}));for(var r=0,t=Object.entries(this._adapterEventsBindings);r<t.length;r++){var a=t[r],i=a[0],o=a[1];this._hls.on(i,o)}this._onRecoveredCallback=function(){return e._onRecovered()},this._onAddTrack=this._onAddTrack.bind(this),this._eventManager.listen(this._videoElement,"addtrack",this._onAddTrack),this._videoElement.textTracks.onaddtrack=this._onAddTrack},h._onFpsDrop=function(e){this._trigger(i.EventType.FPS_DROP,e)},h._onFragParsingMetadata=function(e){var r;this._trigger("hlsFragParsingMetadata",e);var t=Array.from(null==(r=this._videoElement)?void 0:r.textTracks).find((function(e){return"id3"===e.label})),a=Array.from((null==t?void 0:t.cues)||[]),o=[];null==e||e.samples.forEach((function(e){var r=i.Utils.binarySearch(a,(function(r){return r.startTime-e.pts}));if(r){var t=Object(i.createTimedMetadata)(r);o.push(t)}})),o.length&&this._trigger(i.EventType.TIMED_METADATA_ADDED,{cues:o})},h._onAddTrack=function(e){if(!this._hls.subtitleTracks.length){var r=this._parseCEATextTrack(e.track);r&&(a._logger.debug("A CEA 608/708 caption has been found",r),this._playerTracks.push(r),this._trigger(i.EventType.TRACKS_CHANGED,{tracks:this._playerTracks}))}},h.attachMediaSource=function(){this._hls||(this._videoElement&&this._videoElement.src&&(i.Utils.Dom.setAttribute(this._videoElement,"src",""),i.Utils.Dom.removeAttribute(this._videoElement,"src")),this._init())},h.detachMediaSource=function(){var e;this._hls&&(0===Math.floor(this.duration-this.currentTime)?this._config.hlsConfig.startPosition=0:this.currentTime>0&&(this._config.hlsConfig.startPosition=this.currentTime),this._reset(),null==(e=this._loadPromiseHandlers)||e.reject(new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.PLAYER,i.Error.Code.HLS_FATAL_MEDIA_ERROR,"media detached while loading")),this._loadPromiseHandlers=null,this._loadPromise=null,this._hls=null)},h.handleMediaError=function(e){return e.code===e.MEDIA_ERR_DECODE&&(a._logger.debug("The video playback was aborted due to a corruption problem or because the video used features your browser did not support.",e.message),this._handleMediaError(n.a.ErrorDetails.MANIFEST_INCOMPATIBLE_CODECS_ERROR))},h.load=function(e){var r=this;return this._loadPromise||(this._startTime=e,this._loadPromise=new Promise((function(e,t){r._loadPromiseHandlers={resolve:e,reject:t},r._loadInternal()}))),this._loadPromise},h._loadInternal=function(){var e;this._hls&&this._sourceObj&&this._sourceObj.url?(this._hls.loadSource(this._sourceObj.url),this._hls.attachMedia(this._videoElement),this._trigger(i.EventType.ABR_MODE_CHANGED,{mode:this.isAdaptiveBitrateEnabled()?"auto":"manual"})):null==(e=this._loadPromiseHandlers)||e.reject(new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.PLAYER,i.Error.Code.HLS_FATAL_MEDIA_ERROR,"no url provided"))},h._reloadWithDirectManifest=function(){this._triedReloadWithRedirect=!0,this._reset(),this._config.hlsConfig.pLoader=_,this._hls=new n.a(this._config.hlsConfig),this._addBindings(),this._loadInternal()},h.destroy=function(){var r=this;return new Promise((function(t,o){e.prototype.destroy.call(r).then((function(){var e;a._logger.debug("destroy"),r._playerTracks=[],r._nativeTextTracksMap={},r._sameFragSNLoadedCount=0,r._lastLoadedFragSN=-1,null==(e=r._loadPromiseHandlers)||e.reject(new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.PLAYER,i.Error.Code.HLS_FATAL_MEDIA_ERROR,"The adapter has been destroyed while loading")),r._loadPromiseHandlers=null,r._loadPromise=null,r._reset(),t()}),(function(){return o()}))}))},h._reset=function(){this._removeBindings(),this._requestFilterError=!1,this._responseFilterError=!1,this._hls.detachMedia(),this._hls.destroy()},h._parseTracks=function(){var e=this._parseAudioTracks(this._hls.audioTracks||[]),r=this._parseVideoTracks(this._hls.levels||[]),t=this._parseTextTracks(this._hls.subtitleTracks||[]);return e.concat(r).concat(t)},h._parseAudioTracks=function(e){for(var r=[],t=0;t<e.length;t++){var a={id:e[t].id,active:this._hls.audioTrack===e[t].id,label:e[t].name,language:e[t].lang,index:t};r.push(new i.AudioTrack(a))}return r},h._parseVideoTracks=function(e){for(var r=[],t=0;t<e.length;t++){var a={active:this._hls.startLevel===t,bandwidth:e[t].bitrate,width:e[t].width,height:e[t].height,language:"",index:t};r.push(new i.VideoTrack(a))}return r},h._parseTextTracks=function(e){for(var r,t=[],a=E(e);!(r=a()).done;){var o=r.value,n={id:o.id,active:!1,default:o.default,label:o.name,kind:o.type.toLowerCase(),language:o.lang};t.push(new i.TextTrack(n))}return t},h._parseCEATextTrack=function(e){var r=null;if("captions"===e.kind){var t={id:e.id,active:"showing"===e.mode,label:e.label,kind:e.kind,language:e.language};r=new i.TextTrack(t),this._nativeTextTracksMap[r.index]=e}return r},h.selectAudioTrack=function(e){e instanceof i.AudioTrack&&!e.active&&this._hls.audioTracks&&(this._hls.audioTrack=e.id)},h.selectVideoTrack=function(e){e instanceof i.VideoTrack&&(!e.active||this.isAdaptiveBitrateEnabled())&&this._hls.levels&&(this.isAdaptiveBitrateEnabled()&&this._trigger(i.EventType.ABR_MODE_CHANGED,{mode:"manual"}),this._hls.currentLevel=e.index)},h.selectTextTrack=function(e){e instanceof i.TextTrack&&!e.active&&this._hls&&(this._hls.subtitleTracks.length?(this._hls.subtitleTrack=e.id,this._notifyTrackChanged(e)):this._selectNativeTextTrack(e))},h._selectNativeTextTrack=function(e){var r=this._nativeTextTracksMap[e.index];r&&(this.disableNativeTextTracks(),r.mode=this._config.subtitleDisplay?"showing":"hidden",this._notifyTrackChanged(e))},h._notifyTrackChanged=function(e){this._onTrackChanged(e)},h.hideTextTrack=function(){this._hls&&(this._hls.subtitleTracks.length?this._hls.subtitleTrack=-1:this.disableNativeTextTracks())},h.enableAdaptiveBitrate=function(){this.isAdaptiveBitrateEnabled()||(this._trigger(i.EventType.ABR_MODE_CHANGED,{mode:"auto"}),this._hls.nextLevel=-1)},h.isAdaptiveBitrateEnabled=function(){return!!this._hls&&this._hls.autoLevelEnabled},h.applyABRRestriction=function(e){i.Utils.Object.createPropertyPath(this._config,"abr.restrictions",e),this._hls.capLevelToPlayerSize||this._maybeApplyAbrRestrictions(e)},h._getLevelDetails=function(){var e=this._hls.levels[this._hls.currentLevel]||this._hls.levels[this._hls.nextLevel]||this._hls.levels[this._hls.nextAutoLevel]||this._hls.levels[this._hls.nextLoadLevel];return e&&e.details?e.details:{}},h._getLiveEdge=function(){try{var e;return(e=this._hls.liveSyncPosition?this._hls.liveSyncPosition:this._hls.config.liveSyncDuration?this._videoElement.duration-this._hls.config.liveSyncDuration:this._videoElement.duration-this._hls.config.liveSyncDurationCount*this._getLevelDetails().targetduration)>0?e:this._videoElement.duration}catch(e){return a._logger.debug("Live edge calculation failed, fall back to duration"),this._videoElement.duration}},h.seekToLiveEdge=function(){try{this._videoElement.currentTime=this._getLiveEdge()}catch(e){return}},h.getSegmentDuration=function(){var e=i.Utils.Object.getPropertyPath(this._hls,"streamController.fragCurrent");return e?e.duration:0},h.isLive=function(){try{return!!this._getLevelDetails().live}catch(e){return!1}},h._onManifestLoaded=function(e){var r=this;a._logger.debug("The source has been loaded successfully"),this._hls.config.autoStartLoad||this._hls.startLoad(this._startTime),this._playerTracks=this._parseTracks(),this._config.abr.enabled||(this._hls.currentLevel=0),this._mediaAttachedPromise.then((function(){var e;null==(e=r._loadPromiseHandlers)||e.resolve({tracks:r._playerTracks}),r._loadPromiseHandlers=null}));var t=e.stats.loading,o=t.end-t.start;this._trigger(i.EventType.MANIFEST_LOADED,{miliSeconds:o})},h._maybeApplyAbrRestrictions=function(e){var r=this._playerTracks.filter((function(e){return e instanceof i.VideoTrack})),t=Object(i.filterTracksByRestriction)(r,e);if(t.length){var o=t[0],n=t.pop();this._hls.config.minAutoBitrate=o.bandwidth,this._hls.autoLevelCapping=n.index;var s=t.some((function(e){return e.active}));this.isAdaptiveBitrateEnabled()||s||this.selectVideoTrack(o)}else a._logger.warn("Invalid restrictions, there are not tracks within the restriction range")},h._onLevelSwitched=function(e,r){var t=this._playerTracks.find((function(e){return e instanceof i.VideoTrack&&e.index===r.level}));this._onTrackChanged(t)},h._onAudioTrackSwitched=function(e,r){var t=this._playerTracks.find((function(e){return e instanceof i.AudioTrack&&e.id===r.id}));this._onTrackChanged(t),this._handleWaitingUponAudioTrackSwitch()},h._handleWaitingUponAudioTrackSwitch=function(){var e=this;if(["IE","Edge"].includes(i.Env.browser.name)){this._eventManager.listenOnce(this._videoElement,i.EventType.TIME_UPDATE,(function(){e._trigger(i.EventType.PLAYING)}))}},h._getErrorDataObject=function(e){var r={};switch(r.name=e.details,r.name){case n.a.ErrorDetails.MANIFEST_LOAD_ERROR:case n.a.ErrorDetails.LEVEL_LOAD_ERROR:case n.a.ErrorDetails.AUDIO_TRACK_LOAD_ERROR:r.url=e.url,r.responseCode=e.response?e.response.code:null;break;case n.a.ErrorDetails.MANIFEST_LOAD_TIMEOUT:case n.a.ErrorDetails.LEVEL_LOAD_TIMEOUT:case n.a.ErrorDetails.AUDIO_TRACK_LOAD_TIMEOUT:r.url=e.url;break;case n.a.ErrorDetails.MANIFEST_PARSING_ERROR:r.url=e.url,r.reason=e.reason;break;case n.a.ErrorDetails.LEVEL_SWITCH_ERROR:r.level=e.level,r.reason=e.reason;break;case n.a.ErrorDetails.FRAG_LOAD_ERROR:r.fragUrl=e.frag?e.frag.url:null,r.responseCode=e.response?e.response.code:null;break;case n.a.ErrorDetails.FRAG_LOAD_TIMEOUT:r.fragUrl=e.frag?e.frag.url:null;break;case n.a.ErrorDetails.FRAG_DECRYPT_ERROR:case n.a.ErrorDetails.FRAG_PARSING_ERROR:r.reason=e.reason;break;case n.a.ErrorDetails.KEY_LOAD_ERROR:r.fragDecryptedDataUri=e.frag&&e.frag.decryptdata?e.frag.decryptdata.uri:null,r.responseCode=e.response?e.response.code:null;break;case n.a.ErrorDetails.KEY_LOAD_TIMEOUT:r.fragDecryptedDataUri=e.frag&&e.frag.decryptdata?e.frag.decryptdata.uri:null;break;case n.a.ErrorDetails.BUFFER_ADD_CODEC_ERROR:r.mimeType=e.mimeType,r.errorMsg=e.err?e.err.message:null;break;case n.a.ErrorDetails.BUFFER_STALLED_ERROR:r.buffer=e.buffer}return(this._requestFilterError||this._responseFilterError)&&(r.reason=e.response.text),r},h._onError=function(e){var r=e.type,t=e.details,o=e.fatal,s=this._getErrorDataObject(e);if(o){var c;switch(r){case n.a.ErrorTypes.NETWORK_ERROR:var d;d=this._requestFilterError?i.Error.Code.REQUEST_FILTER_ERROR:this._responseFilterError?i.Error.Code.RESPONSE_FILTER_ERROR:i.Error.Code.HTTP_ERROR,![n.a.ErrorDetails.MANIFEST_LOAD_ERROR,n.a.ErrorDetails.MANIFEST_LOAD_TIMEOUT].includes(t)||this._triedReloadWithRedirect||this._config.forceRedirectExternalStreams||this._requestFilterError||this._responseFilterError?c=new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.NETWORK,d,s):(c=new i.Error(i.Error.Severity.RECOVERABLE,i.Error.Category.NETWORK,d,s),this._reloadWithDirectManifest());break;case n.a.ErrorTypes.MEDIA_ERROR:c=this._handleMediaError(t)?new i.Error(i.Error.Severity.RECOVERABLE,i.Error.Category.MEDIA,i.Error.Code.HLS_FATAL_MEDIA_ERROR,s):new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.MEDIA,i.Error.Code.HLS_FATAL_MEDIA_ERROR,s);break;default:c=new i.Error(i.Error.Severity.CRITICAL,i.Error.Category.PLAYER,i.Error.Code.HLS_FATAL_MEDIA_ERROR,s)}if(this._trigger(i.EventType.ERROR,c),c&&c.severity===i.Error.Severity.CRITICAL){var u;if(this._loadPromiseHandlers)null==(u=this._loadPromiseHandlers)||u.reject(c),this._loadPromiseHandlers=null,this._loadPromise=null;this.destroy()}}else{var h=this._requestFilterError||this._responseFilterError?{category:i.Error.Category.NETWORK,code:this._requestFilterError?i.Error.Code.REQUEST_FILTER_ERROR:i.Error.Code.RESPONSE_FILTER_ERROR}:l[t]||{category:0,code:0},_=h.category,E=h.code;a._logger.warn(new i.Error(i.Error.Severity.RECOVERABLE,_,E,s))}this._requestFilterError=!1,this._responseFilterError=!1},h._handleMediaError=function(e){a._logger.error("_handleMediaError mediaErrorName:",e);var r=performance.now(),t=!0;return e===n.a.ErrorDetails.MANIFEST_INCOMPATIBLE_CODECS_ERROR?(a._logger.error("recover aborted due to: MANIFEST_INCOMPATIBLE_CODECS_ERROR"),t=!1):this._checkTimeDeltaHasPassed(r,this._recoverDecodingErrorDate,this._config.recoverDecodingErrorDelay)?(this._eventManager.listen(this._videoElement,i.EventType.LOADED_METADATA,this._onRecoveredCallback),a._logger.debug("try to recover using: _recoverDecodingError()"),this._recoverDecodingError()):this._checkTimeDeltaHasPassed(r,this._recoverSwapAudioCodecDate,this._config.recoverSwapAudioCodecDelay)?(this._eventManager.listen(this._videoElement,i.EventType.LOADED_METADATA,this._onRecoveredCallback),a._logger.debug("try to recover using: _recoverSwapAudioCodec()"),this._recoverSwapAudioCodec()):(a._logger.error("cannot recover, last media error recovery failed error: ",e),t=!1),t},h._onRecovered=function(){this._trigger(i.EventType.MEDIA_RECOVERED),this._videoElement.removeEventListener(i.EventType.LOADED_METADATA,this._onRecoveredCallback)},h._checkTimeDeltaHasPassed=function(e,r,t){return!r||e-r>t},h._recoverDecodingError=function(){this._recoverDecodingErrorDate=performance.now(),a._logger.warn("try to recover media Error"),this._hls.recoverMediaError()},h._recoverSwapAudioCodec=function(){this._recoverSwapAudioCodecDate=performance.now(),a._logger.warn("try to swap Audio Codec and recover media Error"),this._hls.swapAudioCodec(),this._hls.recoverMediaError()},h._removeBindings=function(){for(var e=0,r=Object.entries(this._adapterEventsBindings);e<r.length;e++){var t=r[e],a=t[0],i=t[1];this._hls.off(a,i)}this._videoElement.textTracks.onaddtrack=null,this._onRecoveredCallback=null,this._eventManager&&this._eventManager.removeAll()},h.getStartTimeOfDvrWindow=function(){if(!this.isLive())return 0;try{var e=this._hls.levels[this._hls.nextLoadLevel].details,r=e.fragments,t=r.length,i=r[0].start+r[0].duration,o=r[t-1].start+r[t-1].duration,n=void 0!==this._hls.config.liveMaxLatencyDuration?this._hls.config.liveMaxLatencyDuration:this._hls.config.liveMaxLatencyDurationCount*e.targetduration;return Math.max(i-this._hls.config.maxFragLookUpTolerance,o-n)}catch(e){return a._logger.debug("Unable obtain the start of DVR window"),0}},h._onFragLoaded=function(e){if(i.Utils.Object.hasPropertyPath(e,"frag.stats.loading")){var r=e.frag.stats,t=r.loading.end-r.loading.start;this._trigger(i.EventType.FRAG_LOADED,{miliSeconds:t,bytes:r.loaded,url:e.frag.url})}},h._getLiveTargetBuffer=function(){return this._hls.config.liveSyncDuration?this._hls.config.liveSyncDuration:this._hls.config.liveSyncDurationCount*this._getLevelDetails().targetduration},o=a,(d=[{key:"liveDuration",get:function(){return this._getLiveEdge()+this.getSegmentDuration()}},{key:"targetBuffer",get:function(){var e=NaN;return this._hls?(e=this.isLive()?this._getLiveTargetBuffer()-(this._videoElement.currentTime-this._getLiveEdge()):this._videoElement.duration-this._videoElement.currentTime,e=Math.min(e,this._hls.config.maxMaxBufferLength+this._getLevelDetails().targetduration)):NaN}}])&&f(o.prototype,d),u&&f(o,u),a}(i.BaseMediaSourceAdapter);v(T,"id","HlsAdapter"),v(T,"_logger",i.BaseMediaSourceAdapter.getLogger(T.id)),v(T,"_hlsMimeTypes",["application/x-mpegurl","application/vnd.apple.mpegurl","audio/mpegurl","audio/x-mpegurl","video/x-mpegurl","video/mpegurl","application/mpegurl"]);var y="1.32.4",R="@playkit-js/playkit-js-hls";r.default=T;T.isSupported()&&Object(i.registerMediaSourceAdapter)(T)}])}));
2
2
  //# sourceMappingURL=playkit-hls.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@playkit-js/playkit-js-hls",
3
- "version": "1.32.3",
3
+ "version": "1.32.4",
4
4
  "description": "",
5
5
  "keywords": [
6
6
  "hls",