!function(){var e="undefined"!=typeof window?window:global,t={};if(!function(H,a,o){function s(e){var t=0;return function(){return t>>0)+"_",r=0;return function e(t){if(this instanceof e)throw new TypeError("Symbol is not a constructor");return new n(i+(t||"")+"_"+r++,t)}}),e("Symbol.iterator",function(e){if(e)return e;e=Symbol("Symbol.iterator");for(var t="Array Int8Array Uint8Array Uint8ClampedArray Int16Array Uint16Array Int32Array Uint32Array Float32Array Float64Array".split(" "),n=0;n=this.length))return this[e]}function F(e){return e||B}e("Object.assign",function(e){return e||j}),e("Array.prototype.values",function(e){return e||function(){return _(this,function(e,t){return t})}}),e("Promise.prototype.finally",function(e){return e||function(t){return this.then(function(e){return Promise.resolve(t()).then(function(){return e})},function(e){return Promise.resolve(t()).then(function(){throw e})})}}),e("Array.prototype.entries",function(e){return e||function(){return _(this,function(e,t){return[e,t]})}}),e("String.prototype.repeat",function(e){return e||function(e){var t=O(this,null,"repeat");if(e<0||1342177279>>=1)&&(t+=t);return n}}),e("Number.isNaN",function(e){return e||function(e){return"number"==typeof e&&isNaN(e)}}),e("Number.isFinite",function(e){return e||function(e){return"number"==typeof e&&(!isNaN(e)&&1/0!==e&&-1/0!==e)}}),e("Object.values",function(e){return e||function(e){var t,n=[];for(t in e)N(e,t)&&n.push(e[t]);return n}}),e("Math.log2",function(e){return e||function(e){return Math.log(e)/Math.LN2}}),e("Number.MAX_SAFE_INTEGER",function(){return 9007199254740991}),e("Math.trunc",function(e){return e||function(e){if(e=Number(e),isNaN(e)||1/0===e||-1/0===e||0===e)return e;var t=Math.floor(Math.abs(e));return e<0?-t:t}}),e("Object.entries",function(e){return e||function(e){var t,n=[];for(t in e)N(e,t)&&n.push([t,e[t]]);return n}}),e("Array.prototype.at",function(e){return e||B}),e("Int8Array.prototype.at",F),e("Uint8Array.prototype.at",F),e("Uint8ClampedArray.prototype.at",F),e("Int16Array.prototype.at",F),e("Uint16Array.prototype.at",F),e("Int32Array.prototype.at",F),e("Uint32Array.prototype.at",F),e("Float32Array.prototype.at",F),e("Float64Array.prototype.at",F),e("String.prototype.at",function(e){return e||B});var G=this||self;function i(e,t){e=e.split(".");var n,i=G;e[0]in i||void 0===i.execScript||i.execScript("var "+e[0]);for(;e.length&&(n=e.shift());)e.length||void 0===t?i=i[n]&&i[n]!==Object.prototype[n]?i[n]:i[n]={}:i[n]=t}function ce(e,t){if(t)if(t instanceof Map)for(var n=we(t.keys()),i=n.next();!i.done;i=n.next())i=i.value,Object.defineProperty(this,i,{value:t.get(i),writable:!0,enumerable:!0});else for(n in t)Object.defineProperty(this,n,{value:t[n],writable:!0,enumerable:!0});this.defaultPrevented=this.cancelable=this.bubbles=!1,this.timeStamp=(H.performance&&H.performance.now?H.performance:Date).now(),this.type=e,this.isTrusted=!1,this.target=this.currentTarget=null,this.g=!1}function V(e){var t,n=new ce(e.type);for(t in e)Object.defineProperty(n,t,{value:e[t],writable:!0,enumerable:!0});return n}ce.prototype.preventDefault=function(){this.cancelable&&(this.defaultPrevented=!0)},ce.prototype.stopImmediatePropagation=function(){this.g=!0},ce.prototype.stopPropagation=function(){},i("shaka.util.FakeEvent",ce);var K={xj:"abrstatuschanged",yj:"adaptation",zj:"buffering",Aj:"complete",Bj:"downloadfailed",Cj:"downloadheadersreceived",Dj:"drmsessionupdate",Fj:"emsg",Vj:"prft",Error:"error",Gj:"expirationupdated",Hj:"firstquartile",Ij:"gapjumped",Lj:"keystatuschanged",Nj:"loaded",Oj:"loading",Qj:"manifestparsed",Rj:"manifestupdated",Sj:"mediaqualitychanged",Metadata:"metadata",Tj:"midpoint",Uj:"onstatechange",Xj:"ratechange",Yj:"segmentappended",Zj:"sessiondata",$j:"stalldetected",bk:"started",ck:"statechanged",dk:"streaming",ek:"textchanged",fk:"texttrackvisibility",gk:"thirdquartile",hk:"timelineregionadded",ik:"timelineregionenter",jk:"timelineregionexit",kk:"trackschanged",nk:"unloading",qk:"variantchanged"};function z(){}function q(){}function X(){}function Y(e){var t=R.apply(1,arguments);Q.has(e)||(Q.add(e),X.apply(z,le(t)))}function J(){}var Q=new Set;function $(){this.g={}}function d(){this.Aa=new $,this.ve=this}function Le(e,t){for(var n=[],i=(e=we(e)).next();!i.done;i=e.next())n.push(t(i.value));return n}function Z(e,t){for(var n=(e=we(e)).next();!n.done;n=e.next())if(t(n.value))return 1}function ee(e,t){for(var n=[],i=(e=we(e)).next();!i.done;i=e.next())t(i=i.value)&&n.push(i);return n}H.console&&(X=function(){return console.warn.apply(console,le(R.apply(0,arguments)))},q=function(){console.error.apply(console,le(R.apply(0,arguments)))}),(t=$.prototype).push=function(e,t){this.g.hasOwnProperty(e)?this.g[e].push(t):this.g[e]=[t]},t.get=function(e){return(e=this.g[e])?e.slice():null},t.remove=function(e,t){e in this.g&&(this.g[e]=this.g[e].filter(function(e){return e!=t}),0==this.g[e].length&&delete this.g[e])},t.forEach=function(e){for(var t in this.g)e(t,this.g[t])},t.size=function(){return Object.keys(this.g).length},t.keys=function(){return Object.keys(this.g)},d.prototype.addEventListener=function(e,t){this.Aa&&this.Aa.push(e,t)},d.prototype.removeEventListener=function(e,t){this.Aa&&this.Aa.remove(e,t)},d.prototype.dispatchEvent=function(e){if(!this.Aa)return!0;for(var t=this.Aa.get(e.type)||[],n=(t=we(t=(n=this.Aa.get("All"))?t.concat(n):t)).next();!n.done;n=t.next()){n=n.value,e.target=this.ve,e.currentTarget=this.ve;try{n.handleEvent?n.handleEvent(e):n.call(this,e)}catch(e){}if(e.g)break}return e.defaultPrevented},d.prototype.release=function(){this.Aa=null};var te=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^/?#]*)@)?([^/#?]*?)(?::([0-9]+))?(?=[/#?]|$))?([^?#]+)?(?:\\?([^#]*))?(?:#(.*))?$");function ge(e){e instanceof ge?(se(this,e.sb),this.zc=e.zc,ue(this,e.Hb),me(this,e.Rc),this.Wa=e.Wa,ve(this,e.g.clone()),this.lc=e.lc):e&&(e=String(e).match(te))?(se(this,e[1]||"",!0),this.zc=ye(e[2]||""),ue(this,e[3]||"",!0),me(this,e[4]),this.Wa=ye(e[5]||"",!0),ve(this,e[6]||"",!0),this.lc=ye(e[7]||"")):this.g=new Oe(null)}function se(e,t,n){e.sb=n?ye(t,!0):t,e.sb&&(e.sb=e.sb.replace(/:$/,""))}function ue(e,t,n){e.Hb=n?ye(t,!0):t}function me(e,t){if(t){if(t=Number(t),isNaN(t)||t<0)throw Error("Bad port number "+t);e.Rc=t}else e.Rc=null}function ve(e,t,n){t instanceof Oe?e.g=t:(n||(t=be(t,_e)),e.g=new Oe(t))}function ye(e,t){return e?(t?decodeURI:decodeURIComponent)(e):""}function be(e,t,n){return null!=e?(e=encodeURI(e).replace(t,Re),e=n?e.replace(/%25([0-9a-fA-F]{2})/g,"%$1"):e):null}function Re(e){return"%"+((e=e.charCodeAt(0))>>4&15).toString(16)+(15&e).toString(16)}(t=ge.prototype).sb="",t.zc="",t.Hb="",t.Rc=null,t.Wa="",t.lc="",t.toString=function(){var e,t=[],n=this.sb;return n&&t.push(be(n,Ne,!0),":"),(n=this.Hb)&&(t.push("//"),(e=this.zc)&&t.push(be(e,Ne,!0),"@"),t.push(encodeURIComponent(n).replace(/%25([0-9a-fA-F]{2})/g,"%$1")),null!=(n=this.Rc)&&t.push(":",String(n))),(n=this.Wa)&&(this.Hb&&"/"!=n.charAt(0)&&t.push("/"),t.push(be(n,"/"==n.charAt(0)?De:Pe,!0))),(n=this.g.toString())&&t.push("?",n),(n=this.lc)&&t.push("#",be(n,Ue)),t.join("")},t.resolve=function(e){var t=this.clone(),n=("data"===t.sb&&(t=new ge),!!e.sb),i=(n?se(t,e.sb):n=!!e.zc,n?t.zc=e.zc:n=!!e.Hb,n?ue(t,e.Hb):n=null!=e.Rc,e.Wa);if(n)me(t,e.Rc);else if(n=!!e.Wa)if("/"!=i.charAt(0)&&(this.Hb&&!this.Wa?i="/"+i:-1!=(r=t.Wa.lastIndexOf("/"))&&(i=t.Wa.substr(0,r+1)+i)),".."==i||"."==i)i="";else if(-1!=i.indexOf("./")||-1!=i.indexOf("/.")){for(var r=0==i.lastIndexOf("/",0),i=i.split("/"),a=[],o=0;o=e.l&&u.startTime=i.h||(t<=i.g&&n>=i.h?i.g=i.h=null:t<=i.g&&ni.g&&n>=i.h&&(i.h=t)),Ae(e)})},i("shaka.text.TextEngine",gn),gn.findParser=function(e){return bn[e]},gn.unregisterParser=function(e){delete bn[e]},gn.registerParser=function(e,t){bn[e]=t};var bn={};function wn(e,t){return e.concat(t)}function Tn(){}function An(e){return null!=e}function En(e){var a=new WeakSet;return function e(t){switch(typeof t){case"undefined":case"boolean":case"number":case"string":case"symbol":case"function":return t;default:if(!t||t.buffer&&t.buffer.constructor==ArrayBuffer)return t;if(a.has(t))return null;var n=t.constructor==Array;if(t.constructor!=Object&&!n)return null;a.add(t);var i,r=n?[]:{};for(i in t)r[i]=e(t[i]);return n&&(r.length=t.length),r}}(e)}function Sn(e){var t,n={};for(t in e)n[t]=e[t];return n}function xn(e){this.h=e,this.g=null}function I(e){this.h=e,this.g=null}function In(){var e=H.ManagedMediaSource||H.MediaSource;return!(!e||!e.isTypeSupported)}function kn(e){return""!=jn().canPlayType(e)}function Cn(){return!!navigator.userAgent.match(/Edge?\//)}function Mn(){return On("Xbox One")}function Ln(){return On("Tizen")}function Rn(){return On("Tizen 3")}function Nn(){return On("Tizen 2")}function Pn(){return On("Web0S")&&On("Chrome/38.0.2125.122 Safari/537.36")}function Dn(){return!!navigator.vendor&&navigator.vendor.includes("Apple")&&!Ln()&&!On("PC=EOS")&&!On("PC=APL")&&!On("VirginMedia")&&!On("SOPOpenBrowser")&&!_n()&&!On("AFT")&&!On("WPE")}function _n(){return On("PlayStation 4")}function Un(){if(!Dn())return null;var e=navigator.userAgent.match(/Version\/(\d+)/);return(e=e||navigator.userAgent.match(/OS (\d+)(?:_\d+)?/))?parseInt(e[1],10):null}function On(e){return(navigator.userAgent||"").includes(e)}function jn(){return Fn||(Bn=Bn||new I(function(){Fn=null}),(Fn=document.getElementsByTagName("video")[0]||document.getElementsByTagName("audio")[0])||(Fn=document.createElement("video")),Bn.S(1),Fn)}xn.prototype.S=function(e){var t=this,n=(this.stop(),!0),i=null;return this.g=function(){H.clearTimeout(i),n=!1},i=H.setTimeout(function(){n&&t.h()},1e3*e),this},xn.prototype.stop=function(){this.g&&(this.g(),this.g=null)},I.prototype.Na=function(){return this.stop(),this.h(),this},I.prototype.S=function(e){var t=this;return this.stop(),this.g=new xn(function(){t.h()}).S(e),this},I.prototype.za=function(e){var t=this;return this.stop(),this.g=new xn(function(){t.g.S(e),t.h()}).S(e),this},I.prototype.stop=function(){this.g&&(this.g.stop(),this.g=null)},i("shaka.util.Timer",I),I.prototype.tickEvery=I.prototype.za,I.prototype.tickAfter=I.prototype.S,I.prototype.tickNow=I.prototype.Na;var Bn=null,Fn=null;function Gn(){}function Vn(e,t,n,a){var i=e.variants;if((t.length||n.length)&&(i=function(e,t,n){for(var i={},r=(t=we(t)).next();!r.done;i={Ze:i.Ze},r=t.next())if(i.Ze=r.value,(r=e.filter(function(t){return function(e){return e.video&&e.video.codecs.startsWith(t.Ze)}}(i))).length){e=r;break}for(i={},n=we(n),t=n.next();!t.done;i={Qe:i.Qe},t=n.next())if(i.Qe=t.value,(t=e.filter(function(t){return function(e){return e.audio&&e.audio.codecs.startsWith(t.Qe)}}(i))).length){e=t;break}return e}(i,t,n)),a.length){for(t=new $,i=(n=we(i)).next();!i.done;i=n.next())i=i.value,t.push(String(i.video.width||0),i);var o=[];t.forEach(function(e,t){e=0;for(var n=[],i={},r=(t=we(t)).next();!r.done;i={kd:i.kd},r=t.next())i.kd=r.value,e<(r=a.filter(function(t){return function(e){return t.kd.decodingInfos[0][e]}}(i)).length)?(e=r,n=[i.kd]):r==e&&n.push(i.kd);o.push.apply(o,le(n))}),i=o}n=new Set,t=new Set;for(i=(s=we(i)).next();!i.done;i=s.next())(i=i.value).audio&&n.add(i.audio),i.video&&t.add(i.video);n=Array.from(n).sort(function(e,t){return e.bandwidth-t.bandwidth});var r=[];for(i=new Map,s=(n=we(n)).next();!s.done;s=n.next()){var s,u,l=(s=s.value).language+(s.channelsCount||0)+(s.audioSamplingRate||0)+s.roles.join(",")+s.label+s.groupId+s.fastSwitching,c=i.get(l)||[];(!c.length||ln((u=c[c.length-1]).codecs)==ln(s.codecs)&&s.bandwidth>u.bandwidth)&&(c.push(s),r.push(s.id)),i.set(l,c)}n=Array.from(t).sort(function(e,t){return e.bandwidth&&t.bandwidth?e.bandwidth-t.bandwidth:e.width-t.width}),t=ct();var h=[];for(i=new Map,s=(n=we(n)).next();!s.done;s=n.next()){if(s=s.value,l=Math.round(s.frameRate||0)+(s.hdr||"")+s.fastSwitching,(c=i.get(l)||[]).length){if(u=c[c.length-1],!t&&ln(u.codecs)!==ln(s.codecs))continue;s.width>u.width||s.height>u.height?(c.push(s),h.push(s.id)):s.width==u.width&&s.height==u.height&&(ln(u.codecs)==ln(s.codecs)&&s.bandwidth=t.i))return;e.I=!0}t=e.chooseVariant(),e.getBandwidthEstimate(),t&&e.u(t,e.g.clearBufferSwitch,e.g.safeMarginSwitch)}function mi(e,t,n,i,r){var a;return e.j&&(a=e.j.Ug())&&(n=n.filter(function(e){return!e.bandwidth||!a||e.bandwidth<=a})),(n=t?n.filter(function(e){return Kn(e,t,{width:r,height:i})}):n).sort(function(e,t){return e.bandwidth-t.bandwidth})}(t=pi.prototype).stop=function(){this.u=null,this.l=!1,this.s=[],this.G=1,this.m=this.C=null,this.h&&(this.h.disconnect(),this.h=null),this.H.stop(),this.j=null},t.release=function(){navigator.connection&&navigator.connection.removeEventListener&&(navigator.connection.removeEventListener("change",this.D),this.D=null),this.H=null},t.init=function(e){this.u=e},t.chooseVariant=function(e){e=void 0!==e&&e;var t,n=1/0,i=1/0;if(this.g.restrictToScreenSize&&(i=this.g.ignoreDevicePixelRatio?1:H.devicePixelRatio,n=H.screen.height*i,i*=H.screen.width),this.h&&this.g.restrictToElementSize&&(t=this.g.ignoreDevicePixelRatio?1:H.devicePixelRatio,n=Math.min(n,this.m.clientHeight*t),i=Math.min(i,this.m.clientWidth*t)),t=r=(r=this.s.filter(function(e){return!(e.audio&&e.audio.fastSwitching||e.video&&e.video.fastSwitching)})).length?r:this.s,e&&r.length!=this.s.length&&(t=this.s.filter(function(e){return!!(e.audio&&e.audio.fastSwitching||e.video&&e.video.fastSwitching)})),e=mi(this,this.g.restrictions,t,1/0,1/0),1/0!=n||1/0!=i){for(e=function(e){for(var t=[],n=(e=we(e)).next();!n.done;n=e.next())(n=n.value.video)&&n.height&&n.width&&t.push({height:n.height,width:n.width});return t.sort(function(e,t){return e.width-t.width})}(e),r=(e=we(e)).next();!r.done;r=e.next())if((r=r.value).height>=n&&r.width>=i){n=r.height,i=r.width;break}e=mi(this,this.g.restrictions,t,n,i)}for(n=this.getBandwidthEstimate(),i=(e=t.length&&!e.length?[(e=mi(this,null,t,1/0,1/0))[0]]:e)[0]||null,t=0;t=t.l){if(!t.i)throw new ke(2,7,1010);t.g=1,t.h=t.j}return(n=t.g,t.g++,0==n)?e.return():(i=t.h*(1+(2*Math.random()-1)*t.s),Te(e,new Promise(function(e){new I(e).S(i/1e3)}),2))}t.h*=t.m,Ae(e)})}function _i(){return{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4}}function Ui(){var n,i,e=new Promise(function(e,t){n=e,i=t});return e.resolve=n,e.reject=i,e}function Oi(e,t){this.promise=e,this.i=t,this.g=!1}function ji(e){return new Oi(Promise.reject(e),function(){return Promise.resolve()})}function Bi(){var e=Promise.reject(new ke(2,7,7001));return e.catch(function(){}),new Oi(e,function(){return Promise.resolve()})}function Fi(e){return new Oi(Promise.resolve(e),function(){return Promise.resolve()})}function Gi(e){return new Oi(e,function(){return e.catch(function(){})})}function Vi(e){return new Oi(Promise.all(e.map(function(e){return e.promise})),function(){return Promise.all(e.map(function(e){return e.abort()}))})}function Ki(){this.g=[]}function zi(e,t){e.g.push(t.finally(function(){It(e.g,t)}))}function Hi(e,t,n,i,r){d.call(this),this.i=!1,this.m=new Ki,this.g=new Set,this.h=new Set,this.l=e||null,this.j=t||null,this.u=n||null,this.C=i||null,this.D=r||null,this.s=!1}function Xi(e,t,n,i){n=n||$i;var r=Zi[e];(!r||n>=r.priority)&&(Zi[e]={priority:n,Fe:t,Zi:void 0!==i&&i})}function Wi(e,t,n){return{uris:e,method:"GET",body:null,headers:{},allowCrossSiteCredentials:!1,retryParameters:t,licenseRequestType:null,sessionId:null,drmInfo:null,initData:null,initDataType:null,streamDataCallback:void 0===n?null:n}}function qi(e){if(e){var t=e.segment;if(e=e.stream,t&&e&&e.fastSwitching&&t.Dd)return!1}return!0}function Yi(){this.g=0}function Ji(e,t,n){Oi.call(this,e,t),this.h=n}Ui.prototype.resolve=function(){},Ui.prototype.reject=function(){},Oi.prototype.abort=function(){return this.g=!0,this.i()},Oi.prototype.finally=function(e){return this.promise.then(function(){return e(!0)},function(){return e(!1)}),this},Oi.prototype.Ga=function(i,r){function e(n){return function(e){var t;o.g&&n?s.reject(u):(t=n?i:r)?a=function(e,t,n){try{var i=e(t);return i&&i.promise&&i.abort?(n.resolve(i.promise),function(){return i.abort()}):(n.resolve(i),function(){return Promise.resolve(i).then(function(){},function(){})})}catch(e){return n.reject(e),function(){return Promise.resolve()}}}(t,e,s):(n?s.resolve:s.reject)(e)}}function a(){return s.reject(u),o.abort()}var o=this,s=new Ui,u=new ke(2,7,7001);return this.promise.then(e(!0),e(!1)),new Oi(s,function(){return a()})},i("shaka.util.AbortableOperation",Oi),Oi.prototype.chain=Oi.prototype.Ga,Oi.all=Vi,Oi.notAbortable=Gi,Oi.completed=Fi,Oi.aborted=Bi,Oi.failed=ji,Ki.prototype.destroy=function(){for(var e=[],t=we(this.g),n=t.next();!n.done;n=t.next())(n=n.value).promise.catch(function(){}),e.push(n.abort());return this.g=[],Promise.all(e)},n(Hi,d),(t=Hi.prototype).mg=function(e){this.s=e},t.$i=function(e){this.g.add(e)},t.rj=function(e){this.g.delete(e)},t.Lh=function(){this.g.clear()},t.aj=function(e){this.h.add(e)},t.sj=function(e){this.h.delete(e)},t.Mh=function(){this.h.clear()},t.destroy=function(){return this.i=!0,this.g.clear(),this.h.clear(),d.prototype.release.call(this),this.m.destroy()},t.request=function(u,i,l){var c=this,e=new Yi;if(this.i)return(t=Promise.reject(new ke(2,7,7001))).catch(function(){}),new Ji(t,function(){return Promise.resolve()},e);i.method=i.method||"GET",i.headers=i.headers||{},i.retryParameters=i.retryParameters?En(i.retryParameters):_i(),i.uris=En(i.uris);var t,n=(t=function(e,t,n,i){function r(e){a=a.Ga(function(){return n.body&&(n.body=vt(n.body)),e(t,n,i)})}var a=Fi(void 0);e.C&&r(e.C);for(var o=(e=we(e.g)).next();!o.done;o=e.next())r(o.value);return a.Ga(void 0,function(e){if(e instanceof ke&&7001==e.code)throw e;throw new ke(2,1,1006,e)})}(this,u,i,l)).Ga(function(){return function i(r,a,o,s,u,l,c,h){r.s&&(o.uris[l]=o.uris[l].replace("http://","https://"));0=n+2&&192==(224&e[n])&&128==(192&e[n+1])?(r=(31&e[n])<<6|63&e[n+1],n+=1):e.length>=n+3&&224==(240&e[n])&&128==(192&e[n+1])&&128==(192&e[n+2])?(r=(15&e[n])<<12|(63&e[n+1])<<6|63&e[n+2],n+=2):e.length>=n+4&&240==(241&e[n])&&128==(192&e[n+1])&&128==(192&e[n+2])&&128==(192&e[n+3])&&(r=(7&e[n])<<18|(63&e[n+1])<<12|(63&e[n+2])<<6|63&e[n+3],n+=3),r<=65535?t+=String.fromCharCode(r):(i=1023&(r-=65536),t=(t+=String.fromCharCode(55296+(r>>10)))+String.fromCharCode(56320+i))}return t}function cr(e,t,n){if(!e)return"";if(!n&&0!=e.byteLength%2)throw new ke(2,2,2004);n=Math.floor(e.byteLength/2);var i=new Uint16Array(n);e=bt(e);for(var r=0;rthis.h.byteLength)throw mr();var t=ne(this.h,this.g,e);return this.g+=e,t},t.skip=function(e){if(this.g+e>this.h.byteLength)throw mr();this.g+=e},t.ij=function(e){if(this.gthis.h.byteLength)throw mr();this.g=e},t.Fd=function(){for(var e=this.g;this.xa()&&0!=this.h.getUint8(this.g);)this.g+=1;return e=ne(this.h,e,this.g-e),this.g+=1,lr(e)},i("shaka.util.DataViewReader",gr),gr.prototype.readTerminatedString=gr.prototype.Fd,gr.prototype.rewind=gr.prototype.ij,gr.prototype.readBytes=gr.prototype.Nb,gr.prototype.readUint64=gr.prototype.Sc,gr.prototype.readInt32=gr.prototype.ih,gr.prototype.readUint32=gr.prototype.O,gr.prototype.readUint16=gr.prototype.Sa,gr.prototype.readUint8=gr.prototype.ra,gr.prototype.getPosition=gr.prototype.Ha,gr.prototype.hasMoreData=gr.prototype.xa;var vr=1;function yr(){this.i=[],this.h=[],this.g=!1}function D(e){for(var t=Sr(e);e.reader.xa()&&!e.parser.g;)e.parser.Cd(e.start+t,e.reader,e.partialOkay)}function br(e){for(var t=Sr(e),n=e.reader.O(),i=0;i>24&255,e>>16&255,e>>8&255,255&e)}function Sr(e){return 8+(e.has64BitSize?8:0)+(null!=e.flags?4:0)}gr.Endianness={BIG_ENDIAN:0,LITTLE_ENDIAN:vr},(t=yr.prototype).box=function(e,t){return e=Ar(e),this.i[e]=xr,this.h[e]=t,this},t.W=function(e,t){return e=Ar(e),this.i[e]=Ir,this.h[e]=t,this},t.stop=function(){this.g=!0},t.parse=function(e,t,n){for(e=new gr(e,0),this.g=!1;e.xa()&&!this.g;)this.Cd(0,e,t,n)},t.Cd=function(e,t,n,i){var r=t.Ha();if(i&&r+8>t.getLength())this.g=!0;else{var a=t.O(),o=t.O(),s=Er(o),u=!1;switch(a){case 0:a=t.getLength()-r;break;case 1:if(i&&t.Ha()+8>t.getLength())return void(this.g=!0);a=t.Sc(),u=!0}var l=this.h[o];if(l){var c=null,h=null;if(this.i[o]==Ir){if(i&&t.Ha()+4>t.getLength())return void(this.g=!0);c=(h=t.O())>>>24,h&=16777215}o=r+a,n&&o>t.getLength()&&(o=t.getLength()),i&&o>t.getLength()?this.g=!0:l({name:s,parser:this,partialOkay:n||!1,version:c,flags:h,reader:t=new gr(t=0<(i=o-t.Ha())?t.Nb(i):new Uint8Array(0),0),size:a,start:r+e,has64BitSize:u})}else t.skip(Math.min(r+a-t.Ha(),t.getLength()-t.Ha()))}},i("shaka.util.Mp4Parser",yr),yr.headerSize=Sr,yr.typeToString=Er,yr.allData=Tr,yr.visualSampleEntry=wr,yr.sampleDescription=br,yr.children=D,yr.prototype.parseNext=yr.prototype.Cd,yr.prototype.fullBox=yr.prototype.W;var xr=0,Ir=1;function kr(){}function Cr(e){return e=ne(e),e=pr.value()(e),btoa(e)}function Mr(e,t){return t=null==t||t,e=Cr(e).replace(/\+/g,"-").replace(/\//g,"_"),t?e:e.replace(/[=]*$/,"")}function Lr(e){e=H.atob(e.replace(/-/g,"+").replace(/_/g,"/"));for(var t=new Uint8Array(e.length),n=0;n>32),e.setUint32(12,4294967295&n)):e.setUint32(0,n))}var Ra=new ar(function(){return new Uint8Array([0,0,0,80,115,105,110,102,0,0,0,12,102,114,109,97,0,0,0,0,0,0,0,20,115,99,104,109,0,0,0,0,99,101,110,99,0,1,0,0,0,0,0,40,115,99,104,105,0,0,0,32,116,101,110,99,0,0,0,0,0,0,1,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0])});function Na(e,t,n,i,r,a,o){this.ba=e,this.fb=t,this.Ka=n,this.Tf=void 0===i?null:i,this.timescale=void 0===r?null:r,this.g=void 0===a?null:a,this.aes128Key=void 0===o?null:o,this.mimeType=this.codecs=null}function Pa(e,t){return e&&t?e.Xb()==t.Xb()&&e.Ub()==t.Ub()&&Ct(e.ba().sort(),t.ba().sort())&>(e.g,t.g):e==t}function P(e,t,n,i,r,a,o,s,u,l,c,h,d,f,p,g){for(l=void 0===l?[]:l,f=void 0===f?Da:f,this.startTime=e,this.h=this.endTime=t,this.D=n,this.fb=i,this.Ka=r,this.ka=a,this.timestampOffset=o,this.appendWindowStart=s,this.appendWindowEnd=u,this.g=l,this.tilesLayout=void 0===c?"":c,this.C=void 0===h?null:h,this.oa=void 0===d?null:d,this.status=f,this.l=!1,this.j=!0,this.m=!1,this.aes128Key=void 0===p?null:p,this.u=null,this.i=0,this.s=void 0!==g&&g,this.se=this.Dd=!1,t=(e=we(this.g)).next();!t.done;t=e.next())t.value.eh();this.s&&this.g.length&&this.g[this.g.length-1].dh(),this.mimeType=this.codecs=null}Na.prototype.Xb=function(){return this.fb},Na.prototype.Ub=function(){return this.Ka},i("shaka.media.InitSegmentReference",Na),Na.prototype.getEndByte=Na.prototype.Ub,Na.prototype.getStartByte=Na.prototype.Xb,(t=P.prototype).ba=function(){return this.D()},t.getStartTime=function(){return this.startTime},t.ci=function(){return this.endTime},t.Xb=function(){return this.fb},t.Ub=function(){return this.Ka},t.Ai=function(){return this.tilesLayout},t.zi=function(){return this.C},t.qc=function(){return this.status},t.Si=function(){this.status=_a},t.Sf=function(){this.l=!0},t.Mi=function(){return this.l},t.we=function(){this.j=!1},t.Ji=function(){return this.j},t.eh=function(){this.Dd=!0},t.Li=function(){return this.Dd},t.dh=function(){this.se=!0},t.Ki=function(){return this.se},t.bh=function(){this.m=!0},t.Gi=function(){return this.m},t.rh=function(e){this.u=e},t.xi=function(){return this.u},t.offset=function(e){this.startTime+=e,this.endTime+=e,this.h+=e;for(var t=we(this.g),n=t.next();!n.done;n=t.next())(n=n.value).startTime+=e,n.endTime+=e,n.h+=e},t.sg=function(e){null==this.oa?q("Sync attempted without sync time!"):(e=this.oa-e-this.startTime,.001<=Math.abs(e)&&this.offset(e))},i("shaka.media.SegmentReference",P),P.prototype.syncAgainst=P.prototype.sg,P.prototype.getThumbnailSprite=P.prototype.xi,P.prototype.setThumbnailSprite=P.prototype.rh,P.prototype.hasByterangeOptimization=P.prototype.Gi,P.prototype.markAsByterangeOptimization=P.prototype.bh,P.prototype.isLastPartial=P.prototype.Ki,P.prototype.markAsLastPartial=P.prototype.dh,P.prototype.isPartial=P.prototype.Li,P.prototype.markAsPartial=P.prototype.eh,P.prototype.isIndependent=P.prototype.Ji,P.prototype.markAsNonIndependent=P.prototype.we,P.prototype.isPreload=P.prototype.Mi,P.prototype.markAsPreload=P.prototype.Sf,P.prototype.markAsUnavailable=P.prototype.Si,P.prototype.getStatus=P.prototype.qc,P.prototype.getTileDuration=P.prototype.zi,P.prototype.getTilesLayout=P.prototype.Ai,P.prototype.getEndByte=P.prototype.Ub,P.prototype.getStartByte=P.prototype.Xb,P.prototype.getEndTime=P.prototype.ci,P.prototype.getUris=P.prototype.ba;var Da=0,_a=1;function Ua(e){return e&&!(1==e.length&&e.end(0)-e.start(0)<1e-6)&&e.length?e.end(e.length-1):null}function Oa(e,t){return!(!e||!e.length||1==e.length&&e.end(0)-e.start(0)<1e-6||t>e.end(e.length-1))&&t>=e.start(0)}function ja(e,t){if(!e||!e.length||1==e.length&&e.end(0)-e.start(0)<1e-6)return 0;for(var n=0,i=(e=we(Ba(e))).next();!i.done;i=e.next()){var r=i.value,i=r.start;t<(r=r.end)&&(n+=r-Math.max(i,t))}return n}function Ba(e){if(!e)return[];for(var t=[],n=0;n>6&1&&(t+=10),i=(t+=10)+i;t+10>6&1&&(i+=10),i=i+10+Ka(e,t+6),Va(e,t+10)&&(i+=10),t+=i;return 0>10))+String.fromCharCode(96+((960&e)>>5))+String.fromCharCode(96+(31&e))}}function Ya(e,t,n){var i=e.O(),r=[],a=null;1&n&&(a=e.O()),4&n&&e.skip(4);for(var o=0;o>>32-n;return e.g-=n,0>>t))return e.h<<=t,e.g-=t,t;return eo(e),t+no(e)}function io(e){to(e,1+no(e))}function re(e){return ie(e,no(e)+1)-1}function ro(e){return 1&(e=re(e))?1+e>>>1:-1*(e>>>1)}function ae(e){return 1===ie(e,1)}function oe(e){return ie(e,8)}function ao(e,t){for(var n=8,i=8,r=0;re.byteLength-6)return null;var n=e[7];return 192&n&&(t.pts=536870912*(14&e[9])+4194304*(255&e[10])+16384*(254&e[11])+128*(255&e[12])+(254&e[13])/2,t.dts=t.pts,64&n&&(t.dts=536870912*(14&e[14])+4194304*(255&e[15])+16384*(254&e[16])+128*(255&e[17])+(254&e[18])/2)),n=e[8]+9,e.byteLength<=n?null:(t.data=e.subarray(n),t)}function uo(e){return!(lo(e)<0)}function lo(e){for(var t=Math.min(1e3,e.length-564),n=0;n>4){var s=r+5+e[r+4];if(s==r+188)continue}else s=r+4;switch(o){case 0:a&&(s+=e[s]+1),this.D=(31&e[s+10])<<8|e[s+11];break;case 17:case 8191:break;case this.D:a&&(s+=e[s]+1);var o={audio:-1,video:-1,oe:-1,audioCodec:"",videoCodec:""},u=s+3+((15&(a=e)[s+1])<<8|a[s+2])-4;for(s+=12+((15&a[s+10])<<8|a[s+11]);s>1&63:31&e[c]}o=0}else o++;i-1<=c&&0<=u&&0<=o&&(a={data:e.subarray(u+r,i),fullData:e.subarray(u,i),type:l,time:n})}return a&&s.push(a),!s.length&&t&&(t.data=Pr(t.data,e),t.fullData=Pr(t.fullData,e)),s},t.getMetadata=function(){for(var e=[],t=we(this.l),n=t.next();!n.done;n=t.next())(n=so(n=Pr.apply(kr,le(n.value))))&&e.push({cueTime:n.pts?n.pts/9e4:null,data:n.data,frames:za(n.data),dts:n.dts,pts:n.pts});return e},t.mc=function(){if(this.i.length&&!this.h.length){for(var e=!1,t=we(this.i),n=t.next();!n.done;n=t.next()){var i=Pr.apply(kr,le(n.value)),r=so(i),n=this.h.length?this.h[this.h.length-1]:null;r&&null!=r.pts&&null!=r.dts&&(!n||n.pts!=r.pts&&n.dts!=r.dts)?(this.h.length&&r.dts<(n.dts||0)&&(e=!0),this.h.push(r)):this.h.length&&(i=r?r.data:i)&&((n=this.h.pop()).data=Pr(n.data,i),this.h.push(n))}e&&(this.h=this.h.sort(function(e,t){var n=(e.pts||0)-(t.pts||0);return(e.dts||0)-(t.dts||0)||n}))}return this.h},t.Mc=function(e){if(e=void 0===e||e,this.j.length&&!this.g.length){for(var t,n=!1,i=we(this.j),r=i.next();!r.done;r=i.next()){var a=Pr.apply(kr,le(r.value)),o=so(a),r=this.g.length?this.g[this.g.length-1]:null;o&&null!=o.pts&&null!=o.dts&&(!r||r.pts!=o.pts&&r.dts!=o.dts)?(this.g.length&&o.dts<(r.dts||0)&&(n=!0),this.g.push(o)):this.g.length&&(a=o?o.data:a)&&((r=this.g.pop()).data=Pr(r.data,a),this.g.push(r))}if(e){for(r=(i=we(this.g)).next();!r.done;r=i.next())(r=r.value).nalus=this.$f(r,t),r.nalus.length&&(t=r.nalus[r.nalus.length-1]);this.g=this.g.filter(function(e){return e.nalus.length})}n&&(this.g=this.g.sort(function(e,t){var n=(e.pts||0)-(t.pts||0);return(e.dts||0)-(t.dts||0)||n}))}return e?this.g:(e=this.g,this.g=[],e)},t.getStartTime=function(e){var t;return"audio"==e?(e=null,(t=this.mc()).length&&(e=t[0],e=Math.min(e.dts,e.pts)/9e4),e):"video"==e?(e=null,(t=this.Mc(!1)).length&&(e=t[0],e=Math.min(e.dts,e.pts)/9e4),e):null},t.qd=function(){return{audio:this.s,video:this.m}},t.ke=function(){for(var e=[],t=we(this.Mc()),n=t.next();!n.done;n=t.next())e.push.apply(e,le(n.value.nalus));return e},t.Di=function(){bi("TsParser","Please use getVideoInfo function instead.");var e=this.Kf();return{height:e.height,width:e.width}},t.Kf=function(){return("hvc"==this.m?function(e){var t={height:null,width:null,wa:null};if(!(e=e.ke()).length)return t;if(!(e=e.find(function(e){return 33==e.type})))return t;var n=new Za(e.fullData,!0),i=(oe(n),oe(n),ie(n,4),ie(n,3)),r=(ae(n),ie(n,2)),a=ie(n,1),o=ie(n,5),s=ie(n,32);e=oe(n);for(var u=oe(n),l=oe(n),c=oe(n),h=oe(n),d=oe(n),f=oe(n),p=[],g=[],m=0;m>n&1)<<31-n;return t>>>0}(s),a=1==a?"H":"L",r="hvc1."+["","A","B","C"][r]+o,r=(r+="."+n.toString(16).toUpperCase())+"."+a+f,d&&(r+="."+d.toString(16).toUpperCase()),h&&(r+="."+h.toString(16).toUpperCase()),c&&(r+="."+c.toString(16).toUpperCase()),l&&(r+="."+l.toString(16).toUpperCase()),u&&(r+="."+u.toString(16).toUpperCase()),e&&(r+="."+e.toString(16).toUpperCase()),t.wa=r,t}:function(e){var t={height:null,width:null,wa:null};if(!(e=e.ke()).length)return t;if(!(e=e.find(function(e){return 7==e.type})))return t;var n=oe(e=new Za(e.data)),i=oe(e),r=oe(e);if(io(e),co.includes(n)){var a=re(e);if(3===a&&to(e,1),io(e),io(e),to(e,1),ae(e)){a=3!==a?8:12;for(var o=0;o=d.l&&e.startTimen.end-.5)){t=!0;break e}t=!1}return t}function Xo(e,t,n,i,r){var a=this;this.C=r,this.g=e,this.D=t,this.u=n,this.l=new nr,this.j=!1,this.H=e.readyState,this.G=this.i=0,this.h=i,this.s=!1,this.l.o(e,"waiting",function(){return Wo(a)}),this.m=new I(function(){Wo(a)}).za(this.u.gapJumpTimerTime)}function Wo(e){if(0!=e.g.readyState){if(e.g.seeking){if(!e.j)return}else e.j=!1;var t,n,i,r;e.g.paused&&(e.g.currentTime!=e.i||!e.g.autoplay&&e.g.currentTime==e.i)||(e.g.readyState!=e.H&&(e.H=e.g.readyState),(t=!e.h)||(i=Ho(n=(t=e.h).l),r=n.g.currentTime,a=Date.now()/1e3,t.g==r&&t.u==i||(t.m=a,t.g=r,t.u=i,t.h=!1),(i=(r=a-t.m)>=t.C&&i&&!t.h)&&(t.i(t.g,r),t.h=!0,t.g=n.g.currentTime,t.s++,t.j(new ce("stalldetected"))),t=!i),t&&(t=e.g.currentTime,n=e.g.buffered,a=n,o=t,s=e.u.gapDetectionThreshold,null==(i=a&&a.length&&!(1==a.length&&a.end(0)-a.start(0)<1e-6)&&0<=(a=Ba(a).findIndex(function(e,t,n){return e.start>o&&(0==t||n[t-1].end-o<=s)}))?a:null)||0==i&&!e.s||((r=n.start(i))>=e.D.Kb()||r-t<.001||(0!=i&&n.end(i-1),e.g.currentTime=r,t==e.i&&(e.i=r),e.G++,e.C(new ce("gapjumped"))))))}var a,o,s}function qo(e,t,n,i){t==HTMLMediaElement.HAVE_NOTHING||e.readyState>=t?i():(t=Yo.value().get(t),n.na(e,t,i))}(t=fe.prototype).getDuration=function(){return this.j},t.li=function(){return this.g},t.og=function(e){this.i=e},t.eb=function(e){this.j=e},t.oi=function(){return this.i},t.nh=function(e){this.u=e},t.Tc=function(e){this.G=e},t.Le=function(e){this.C=e},t.oh=function(e){this.s=e},t.bi=function(){return this.s},t.hh=function(e,t){var n;0!=e.length&&(n=e[e.length-1].end+t,this.Be(e[0].start+t),this.g=e.reduce(function(e,t){return Math.max(e,t.end-t.start)},this.g),this.h=Math.max(this.h,n),null!=this.i&&this.D&&!this.m&&(this.i=(Date.now()+this.u)/1e3-this.h-this.g))},t.Bd=function(e){if(0!=e.length){for(var t=e[0].startTime,n=e[0].endTime,i=(Date.now()+this.u)/1e3,r=(e=we(e)).next();!r.done;r=e.next())i<(r=r.value).startTime||(t=Math.min(t,r.startTime),n=Math.max(n,r.endTime),this.g=Math.max(this.g,r.endTime-r.startTime));this.Be(t),this.h=Math.max(this.h,n),null!=this.i&&this.D&&!this.m&&(this.i=i-this.h-this.g)}},t.ue=function(){this.m=!0},t.Oi=function(){return this.m},t.Be=function(e){this.l=null==this.l?e:Math.min(this.l,e)},t.Vf=function(e){this.g=Math.max(this.g,e)},t.offset=function(e){null!=this.l&&(this.l+=e),null!=this.h&&(this.h+=e)},t.R=function(){return 1/0==this.j&&!this.G},t.uc=function(){return 1/0!=this.j&&!this.G},t.xb=function(){return Math.max(this.H,this.Wb()-this.C)},t.sh=function(e){this.H=e},t.Wb=function(){return this.R()||this.uc()?Math.min(Math.max(0,(Date.now()+this.u)/1e3-this.g-this.i)+this.I,this.j):this.h?Math.min(this.h,this.j):this.j},t.sd=function(e){var t=Math.max(this.l,this.H);return 1/0==this.C?Math.ceil(1e3*t)/1e3:Math.max(t,Math.min(this.Wb()-this.C+e,this.Kb()))},t.Lc=function(){return this.sd(0)},t.Kb=function(){return Math.max(0,this.Wb()-(this.R()||this.uc()?this.s:0))},t.yh=function(){return!(null==this.i||null!=this.h&&this.D)},t.mh=function(e){this.I=e},i("shaka.media.PresentationTimeline",fe),fe.prototype.setAvailabilityTimeOffset=fe.prototype.mh,fe.prototype.usingPresentationStartTime=fe.prototype.yh,fe.prototype.getSeekRangeEnd=fe.prototype.Kb,fe.prototype.getSeekRangeStart=fe.prototype.Lc,fe.prototype.getSafeSeekRangeStart=fe.prototype.sd,fe.prototype.getSegmentAvailabilityEnd=fe.prototype.Wb,fe.prototype.setUserSeekStart=fe.prototype.sh,fe.prototype.getSegmentAvailabilityStart=fe.prototype.xb,fe.prototype.isInProgress=fe.prototype.uc,fe.prototype.isLive=fe.prototype.R,fe.prototype.notifyMaxSegmentDuration=fe.prototype.Vf,fe.prototype.notifyMinSegmentStartTime=fe.prototype.Be,fe.prototype.isStartTimeLocked=fe.prototype.Oi,fe.prototype.lockStartTime=fe.prototype.ue,fe.prototype.notifySegments=fe.prototype.Bd,fe.prototype.notifyTimeRange=fe.prototype.hh,fe.prototype.getDelay=fe.prototype.bi,fe.prototype.setDelay=fe.prototype.oh,fe.prototype.setSegmentAvailabilityDuration=fe.prototype.Le,fe.prototype.setStatic=fe.prototype.Tc,fe.prototype.setClockOffset=fe.prototype.nh,fe.prototype.getPresentationStartTime=fe.prototype.oi,fe.prototype.setDuration=fe.prototype.eb,fe.prototype.setPresentationStartTime=fe.prototype.og,fe.prototype.getMaxSegmentDuration=fe.prototype.li,Ko.prototype.release=function(){this.j=this.l=null,this.i=function(){}},Xo.prototype.release=function(){this.l&&(this.l.release(),this.l=null),null!=this.m&&(this.m.stop(),this.m=null),this.h&&(this.h.release(),this.h=null),this.g=this.D=this.C=null},Xo.prototype.Yf=function(){this.s=!0,Wo(this)};var Yo=new ar(function(){return new Map([[HTMLMediaElement.HAVE_METADATA,"loadedmetadata"],[HTMLMediaElement.HAVE_CURRENT_DATA,"loadeddata"],[HTMLMediaElement.HAVE_FUTURE_DATA,"canplay"],[HTMLMediaElement.HAVE_ENOUGH_DATA,"canplaythrough"]])});function Jo(e,t,n,i){var r=this;this.g=e,this.m=t,this.u=n,this.l=null,this.j=function(){return null==r.l&&(r.l=i()),r.l},this.s=!1,this.h=new nr,this.i=new ts(e),qo(this.g,HTMLMediaElement.HAVE_METADATA,this.h,function(){Zo(r,r.j())})}function Qo(e){return e.s?e.g.currentTime:e.j()}function $o(e,t){0o.g.getDuration()?o.g.Lc():o.g.Kb():e<0&&(e=o.g.Kb()+e),as(o,ss(o,e))}),this.m=new I(function(){var e,t,n;0==o.i.readyState||o.i.paused||(e=Qo(o.h),t=o.g.Lc(),e<(t=(n=o.g.Kb())-t<3?n-3:t)&&(e=os(o,e),o.i.currentTime=e))})}function as(e,t){var n=e.g.getDuration();return n<=t?n-e.l.durationBackoff:t}function os(e,t){var n=Math.max(e.D,e.l.rebufferingGoal),i=e.l.safeSeekOffset,r=e.g.Lc(),a=e.g.Kb(),o=e.g.getDuration(),s=(a-r<3&&(r=a-3),e.g.sd(n)),u=e.g.sd(i),n=e.g.sd(n+i);return o<=t?as(e,t):a=i.startTime&&e=this.g.length?null:this.g[e]},t.offset=function(e){if(!this.s)for(var t=we(this.g),n=t.next();!n.done;n=t.next())n.value.offset(e)},t.ye=function(e){var t;!this.s&&e.length&&(t=Math.round(1e3*e[0].startTime)/1e3,this.g=this.g.filter(function(e){return Math.round(1e3*e.startTime)/1e3t&&(0==n.g.length||e.endTime>n.g[0].startTime)}),this.ye(e),this.vb(t)},t.vb=function(t){var e;this.s||(e=this.g.length,this.g=this.g.filter(function(e){return e.endTime>t}),this.j+=e-this.g.length)},t.Gc=function(e,t,n){if(n=void 0!==n&&n,!this.s){for(;this.g.length&&this.g[this.g.length-1].startTime>=t;)this.g.pop();for(;this.g.length&&this.g[0].endTime<=e;)this.g.shift(),n||this.j++;0!=this.g.length&&(e=this.g[this.g.length-1],this.g[this.g.length-1]=new P(e.startTime,t,e.D,e.fb,e.Ka,e.ka,e.timestampOffset,e.appendWindowStart,e.appendWindowEnd,e.g,e.tilesLayout,e.C,e.oa,e.status,e.aes128Key),this.g[this.g.length-1].i=e.i)}},t.Oe=function(e,t){var n=this;this.s||(this.l&&this.l.stop(),this.l=new I(function(){var e=t();e?n.g.push.apply(n.g,le(e)):(n.l.stop(),n.l=null)}),this.l.za(e))},us.prototype[Symbol.iterator]=function(){return this.nc(0)},us.prototype.nc=function(e){var t=this.find(e);if(null==t)return null;var n=this.get(--t+1),i=-1;if(n&&0=a.startTime&&e=e.g.length&&(this.g++,this.h=0,e=this.i.get(this.g)),e&&0=a[0].start&&ri.endTime?As:Ts;this.g.set(i,a);for(var o=we(this.m),s=o.next();!s.done;s=o.next())(s=s.value).Bc==r&&s.Ac==a&&s.tc(i,t)}}};var ws=1,Ts=2,As=3;function Es(e,t,n){this.i=e,this.h=t,this.j=0,this.l=n,this.g=new Map}function Ss(e,t,n){if(n=void 0!==n&&n,e.h.segmentIndex){var i=e.h.segmentIndex.nc(Math.max(t.startTime,e.j));if(i){var r=t;for(n&&(r=i.next().value)&&r.startTime==t.startTime&&r.endTime==t.endTime&&(r=null);e.g.sizer))&&f.ab.abort(),Ae(e)}).catch(function(e){t.g&&t.g.onError(e)})):(o=t,s=e,Ie(function(e){switch(e.g){case 1:return u=He,o.H++,l=o.H,Ee(e,2),Te(e,Lo(o.g.Y,u.Ea),4);case 4:Se(e,3);break;case 2:c=xe(e),o.g&&o.g.onError(c);case 3:c=on(s.mimeType,s.codecs),So(o.g.Y,c,o.m.sequenceMode,s.external),h=o.g.Y.H,(h.isTextVisible()||o.h.alwaysStreamText)&&o.H==l&&(h=Us(o,s),o.i.set(u.Ea,h),zs(o,h,0)),Ae(e)}}))}function _s(t,e){e.nd||e.Pb||(e.Ra?(e.Pb=!0,e.$d=0):null==Io(t.g.Y,e.type)?null==e.Bb&&zs(t,e,0):(Hs(e),Ks(t,e,!1,0).catch(function(e){t.g&&t.g.onError(e)})))}function Us(e,t){return{stream:t,type:t.type,ea:null,Ia:Os(e,t),Qa:null,ac:null,Qf:null,Of:null,Nf:null,yc:null,endOfStream:!1,Ra:!1,Bb:null,Pb:!1,$d:0,Pe:!1,nd:!1,Id:!0,Uf:!1,dg:!1,ud:!1,ab:null}}function Os(i,e){return("video"===e.type||"audio"===e.type)&&0=o+e.m.presentationTimeline.g?e.h.updateIntervalSeconds:(t.Ia&&t.ea&&(!(r=a.ka)||t.Qa&&Pa(r,t.ac)||(l=t.Ia,r=r,l.h.segmentIndex&&l.g.size>=8;return e.return(H.crypto.subtle.decrypt({name:"AES-CBC",iv:s},o.cryptoKey,i))})),4);e.F(3);break;case 4:m=e.h;case 3:return e.return(m)}var i,r,a,o,s,u,l})}function Vs(e,t,n,i){var r=t instanceof P?t:void 0,a=r?1:0;return t=Ms(t.ba(),t.fb,t.Ka,e.h.retryParameters,i),e.g.xc.request(Qi,t,{type:a,stream:n,segment:r})}function Ks(t,n,i,r){var a,o;return Ie(function(e){return 1==e.g?(n.Pb=!1,n.Pe=!1,n.$d=0,n.nd=!0,n.Qa=null,n.ac=null,n.ea=null,n.Ia&&xs(n.Ia),r?(a=t.g.ie(),o=t.g.Y.getDuration(),Te(e,t.g.Y.remove(n.type,a+r,o),3)):Te(e,Lo(t.g.Y,n.type),4)):3!=e.g?(tr(t.l),i?Te(e,t.g.Y.flush(n.type),3):e.F(3)):(tr(t.l),n.nd=!1,n.endOfStream=!1,n.Ra||n.Bb||zs(t,n,0),void Ae(e))})}function zs(n,i,e){var t=i.type;t==he&&!n.i.has(t)||(i.Bb=new xn(function(){var t;return Ie(function(e){return 1==e.g?(Ee(e,2),Te(e,js(n,i),4)):2!=e.g?Se(e,0):(t=xe(e),n.g&&n.g.onError(t),void Ae(e))})}).S(e))}function Hs(e){null!=e.Bb&&(e.Bb.stop(),e.Bb=null)}function Xs(t){return Ie(function(e){return t.ab?Te(e,t.ab.abort(),0):e.F(0)})}function Ws(t,n,i){var r;return Ie(function(e){if(1==e.g)return Te(e,Di(t.I),2);tr(t.l),r=0===t.h.maxDisabledTime&&1011==i.code?1:t.h.maxDisabledTime,1===i.category&&0r;){var o=a.pop();o&&Is(i,o)}0e||r.endTime=r.g&&e"+e+""},n.payload)}(r,t),i.push(n));return i}function $s(e,t){this.g=null;for(var n=we(Array.from(e.textTracks)),i=n.next();!i.done;i=n.next())(i=i.value).mode="disabled",i.label==t&&(this.g=i);this.g||(this.g=e.addTextTrack("subtitles",t)),this.g.mode="hidden"}function Zs(e,t){var n=e.mode;e.mode="showing"==n?"showing":"hidden";for(var i=we(Array.from(e.cues)),r=i.next();!r.done;r=i.next())(r=r.value)&&t(r)&&e.removeCue(r);e.mode=n}function eu(){}function tu(){}function E(e){return document.createElement(e)}function nu(){var e=document.createElement("button");return e.setAttribute("type","button"),e}function iu(e){for(;e.firstChild;)e.removeChild(e.firstChild)}function ru(e,t){var n=this;this.m=!1,this.i=[],this.D=e,this.u=t,this.j=null,this.g=E("div"),this.g.classList.add("shaka-text-container"),this.g.style.textAlign="center",this.g.style.display="flex",this.g.style.flexDirection="column",this.g.style.alignItems="center",this.g.style.justifyContent="flex-end",this.u.appendChild(this.g),this.G=new I(function(){ou(n)}).za(.25),this.h=new Map,this.l=new nr,this.l.o(document,"fullscreenchange",function(){ou(n,!0)}),this.l.o(this.D,"resize",function(){var e=(t=n.D).videoWidth,t=t.videoHeight;n.j=e&&t?e/t:null}),this.s=null,"ResizeObserver"in H&&(this.s=new ResizeObserver(function(){ou(n,!0)}),this.s.observe(this.g)),this.C=new Map}function au(e,t,n,i,r){for(var a=!1,o=[],s=[],u=(t=we(t)).next();!u.done;u=t.next()){u=u.value,r.push(u);var l,c,h,d,f,p=e.h.get(u),g=u.startTime<=i&&u.endTime>i,m=p?p.Ch:null;if(p&&(o.push(p.lf),p.Gd&&o.push(p.Gd),g||(a=!0,e.h.delete(u),p=null)),g){s.push(u);if(p)(function(e,t){for(;null!=t;){if(t==e.g)return 1;t=t.parentElement}})(e,m)||(a=!0);else{{g=void 0;v=void 0;y=void 0;b=void 0;w=void 0;T=void 0;l=void 0;c=void 0;h=void 0;d=void 0;f=void 0;g=e;var v=u;var y=r;var b=1t}),!0)},t.append=function(e){for(var t=Qs(e),n=[],i=(e=this.g.cues?Array.from(this.g.cues):[],{}),r=(t=we(t)).next();!r.done;i={Cc:i.Cc},r=t.next())i.Cc=r.value,e.some(function(t){return function(e){return e.startTime==t.Cc.startTime&&e.endTime==t.Cc.endTime&&e.text==t.Cc.payload}}(i))||(r=function(e){if(e.startTime>=e.endTime)return null;var t=new VTTCue(e.startTime,e.endTime,e.payload);t.lineAlign=e.lineAlign,t.positionAlign=e.positionAlign,e.size&&(t.size=e.size);try{t.align=e.textAlign}catch(e){}return"center"==e.textAlign&&"center"!=t.align&&(t.align="middle"),"vertical-lr"==e.writingMode?t.vertical="lr":"vertical-rl"==e.writingMode&&(t.vertical="rl"),1==e.lineInterpretation&&(t.snapToLines=!1),null!=e.line&&(t.line=e.line),null!=e.position&&(t.position=e.position),t}(i.Cc))&&n.push(r);for(i=(e=we(e=n.slice().sort(function(e,t){return e.startTime!=t.startTime?e.startTime-t.startTime:e.endTime!=t.endTime?e.endTime-t.startTime:"line"in VTTCue.prototype?n.indexOf(t)-n.indexOf(e):n.indexOf(e)-n.indexOf(t)}))).next();!i.done;i=e.next())this.g.addCue(i.value)},t.destroy=function(){return this.g&&(Zs(this.g,function(){return 1}),this.g.mode="disabled"),this.g=null,Promise.resolve()},t.isTextVisible=function(){return"showing"==this.g.mode},t.setTextVisibility=function(e){this.g.mode=e?"showing":"hidden"},i("shaka.text.SimpleTextDisplayer",$s),(t=eu.prototype).remove=function(){},t.append=function(){},t.destroy=function(){},t.isTextVisible=function(){return!1},t.setTextVisibility=function(){},i("shaka.text.StubTextDisplayer",eu),i("shaka.util.Dom",tu),tu.removeAllChildren=iu,(t=ru.prototype).append=function(e){for(var t=[].concat(le(this.i)),n={},i=(e=we(e)).next();!i.done;n={Pd:n.Pd},i=e.next())n.Pd=i.value,t.some(function(t){return function(e){return Rt(e,t.Pd)}}(n))||this.i.push(n.Pd);ou(this)},t.destroy=function(){return this.g&&(this.u.removeChild(this.g),this.g=null,this.m=!1,this.i=[],this.G&&this.G.stop(),this.h.clear(),this.l&&(this.l.release(),this.l=null),this.s&&(this.s.disconnect(),this.s=null)),Promise.resolve()},t.remove=function(t,n){if(!this.g)return!1;var e=this.i.length;return this.i=this.i.filter(function(e){return e.startTime=n}),ou(this,e>this.i.length),!0},t.isTextVisible=function(){return this.m},t.setTextVisibility=function(e){this.m=e},i("shaka.text.UITextDisplayer",ru),i("shaka.text.WebVttGenerator",function(){}),lu.prototype.configure=function(e){this.g=e};var pu="m",gu="a",mu="v",vu="av",yu="i",bu="c",wu="tt";function Tu(e){this.h=e,this.g=null}function Au(e){return!e||"false"!==e.toLowerCase()&&(/^[-0-9]/.test(e)?parseInt(e,10):e.replace(/["]+/g,""))}i("shaka.util.CmcdManager.StreamingFormat",{DASH:"d",HLS:"h",Eh:"s",OTHER:"o"}),(t=Tu.prototype).configure=function(e){this.h=e},t.Ug=function(){return this.h.enabled&&this.h.applyMaximumSuggestedBitrate&&this.g&&this.g.has(Su)?1e3*this.g.get(Su):null},t.Tg=function(){return this.h.enabled&&this.g&&this.g.has(Eu)?1e3*this.g.get(Eu):null},t.pi=function(){return this.h.enabled&&this.g&&this.g.has(xu)?this.g.get(xu):null},t.ri=function(){return this.h.enabled&&this.g&&this.g.has(Iu)?this.g.get(Iu):null},t.getBandwidthEstimate=function(e){var t=this.Tg();if(!t)return e;var n=this.h.estimatedThroughputWeightRatio;return 0=n}))?1e3*(e.end-n):NaN}(l,o.type)),o.bandwidth&&(r.br=o.bandwidth/1e3)),a&&r.ot!==wu&&(r.tb=function(e,t){var n=e.h.jb();if(!n.length)return NaN;e=n[0];for(var i=(n=we(n)).next();!i.done;i=n.next())"variant"===(i=i.value).type&&i.bandwidth>e.bandwidth&&(e=i);switch(t){case mu:return e.videoBandwidth||NaN;case gu:return e.audioBandwidth||NaN;default:return e.bandwidth}}(l,r.ot)/1e3),hu(l,t,r))}catch(e){Y("CMCD_SEGMENT_ERROR","Could not generate segment CMCD data.",e)}break;case 2:case 5:case 6:hu(l,t,{ot:"k"});break;case 4:hu(l,t,{ot:"o"})}},function(e,t,n,i){h.H&&h.H.banLocation&&h.H.banLocation(i)})),this.J.mg(this.h.streaming.forceHTTPS),this.D=null,ql&&(this.D=ql()),this.Ae.o(H,"online",function(){Ll(s),s.eg()}),this.re=new I(function(){for(var e=s,t=Date.now()/1e3,n=!1,i=we(e.i.variants),r=i.next();!r.done;r=i.next()){var a,o;0<(r=r.value).disabledUntilTime&&r.disabledUntilTime<=t&&(r.disabledUntilTime=0,n=!0,o=a=void 0,o="",(a=r).video&&(o+="video:"+a.video.id),o=a.audio?o+(o?"&":"")+"audio:"+a.audio.id:o)}e.i.variants.every(function(e){return 0===e.disabledUntilTime})&&e.re.stop(),n&&Al(e,!0,void 0,!1,!1)}),e&&(bi("Player","Please migrate from initializing Player with a mediaElement; use the attach method instead."),this.Ec(e,!0))}function Hu(e){null!=e.L&&(fo(e.L),e.L.release(),e.L=null)}function Xu(e,t){return new ce(e,t)}function Wu(){if(H.Promise||X("A Promise implementation or polyfill is required"),!(H.Promise&&H.Uint8Array&&Array.prototype.forEach)||On("Trident/"))return!1;var e=Un();return!(e&&e<9||!(H.MediaKeys&&H.navigator&&H.navigator.requestMediaKeySystemAccess&&H.MediaKeySystemAccess&&H.MediaKeySystemAccess.prototype.getConfiguration))&&(!!In()||kn("application/x-mpegurl"))}function qu(e,t){e.dispatchEvent(Xu("onstatechange",(new Map).set("state",t)))}function Yu(t,n){var i;return Ie(function(e){return 1==e.g?(i=++t.De,Te(e,Ru(t.V,n),2)):i!=t.De?(t.V.release(),e.return(!0)):e.return(!1)})}function Ju(a){var o,s;return Ie(function(e){if(1==e.g)return qu(a,"media-source"),o=a.h.textDisplayFactory,s=o(),a.fg=o,t=a.g,n=s,i=function(e,t,n){Qu(a,e,t,n)},r=a.L,(o=new To(t,n,i,r)).configure(a.h.mediaSource),s=a.h.manifest,s=s.segmentRelativeVttTiming,o.Z=s,Te(e,o.L,2);var t,n,i,r;a.I=o,Ae(e)})}function Qu(e,t,n,i){for(var r=(t=we(t)).next();!r.done;r=t.next())if((r=r.value).data&&r.cueTime&&r.frames){var a=r.cueTime+n,o=i;i&&i=e.g.duration-1;break;case Kl:e:if(e.g.ended||xo(e.I))t=!0;else{if(e.i.presentationTimeline.R()){var n=e.i.presentationTimeline.Wb(),i=Ua(e.g.buffered);if(null!=i&&n<=i){t=!0;break e}}t=!1}break;default:t=!1}var i=ja(e.g.buffered,e.g.currentTime),r=t,a=(n=e.M).h.get(n.g);(t=n.g)!=(n.g=i=r||a<=i?Ni:Ri)&&gl(e)}function il(t){var e,n,i,r;if(t.H&&(e=En(t.h.manifest),t.g&&"AUDIO"===t.g.nodeName&&(e.disableVideo=!0),t.H.configure(e)),t.u&&t.u.configure(t.h.drm),t.j){t.j.configure(t.h.streaming);try{fl(t,t.i)}catch(e){Rl(t,e)}t.s&&wl(t),!(e=t.j.j)||e.allowedByApplication&&e.allowedByKeySystem||Al(t)}t.J&&t.J.mg(t.h.streaming.forceHTTPS),t.I&&(t.I.configure(t.h.mediaSource),t.I.Z=t.h.manifest.segmentRelativeVttTiming,e=t.h.textDisplayFactory,t.fg!=e)&&(n=e(),r=(i=t.I).H,i.H=n,r&&(n.setTextVisibility(r.isTextVisible()),r.destroy()),i.h&&(i.h.j=n),t.fg=e,t.j&&(n=(e=t.j).i.get(he))&&Ds(e,n.stream,!0,0,!0)),t.s&&(t.s.configure(t.h.abr),t.h.abr.enabled?t.s.enable():t.s.disable(),Ml(t)),t.M&&(e=t.h.streaming.rebufferingGoal,t.i&&(e=Math.max(e,t.i.minBufferTime)),Li(t.M,e,Math.min(.5,e/2))),t.i&&Ul(t.i.presentationTimeline,t.h.playRangeStart,t.h.playRangeEnd),t.D&&t.D.configure(t.h.ads),t.U&&t.U.configure(t.h.cmcd),t.Z&&t.Z.configure(t.h.cmsd)}function rl(e){return(e=e&&/(\d+)x(\d+)/.exec(e))?{jc:parseInt(e[1],10),rows:parseInt(e[2],10)}:null}function al(e){return Array.from(e.g.textTracks).filter(function(e){return"metadata"!=e.kind&&"chapters"!=e.kind&&"Shaka Player TextTrack"!=e.label})}function ol(e){return Array.from(e.g.textTracks).filter(function(e){return"chapters"==e.kind})}function sl(t,n){var i;return Ie(function(e){switch(e.g){case 1:return Ee(e,2),Te(e,qs(n,t.J,t.h.streaming.retryParameters),4);case 4:i=e.h,Se(e,3);break;case 2:xe(e);case 3:if(i)return e.return(i);throw new ke(1,2,2011,n)}})}function ul(a,o,s,u,l,c,h){var d;return Ie(function(e){if(1==e.g)return"text/vtt"!=l||h.length?Te(e,ll(a,o,a.J,a.h.streaming.retryParameters),3):e.F(2);2!=e.g&&(d=e.h,d=cl(a,d,l,h),d=new Blob([d],{type:"text/vtt"}),o=Go(d),l="text/vtt"),d=document.createElement("track");var t=a.U,n=o;try{var i,r=t.g.enabled?((i=cu(t)).ot=bu,i.su=!0,fu(n,du(i))):n}catch(e){Y("CMCD_TEXT_TRACK_ERROR","Could not generate text track CMCD data.",e),r=n}return d.src=r,d.label=c,d.kind=u,d.srclang=s,a.g.getAttribute("crossorigin")||a.g.setAttribute("crossorigin","anonymous"),a.g.appendChild(d),e.return(d)})}function ll(n,i,r,a){var o,s;return Ie(function(e){if(1!=e.g)return s=e.h,e.return(s.data);s=Qi,(o=Wi([i],a)).method="GET";var t=n.U;try{t.g.enabled&&hu(t,o,{ot:bu,su:!0})}catch(e){Y("CMCD_TEXT_ERROR","Could not generate text CMCD data.",e)}return Te(e,r.request(s,o).promise,2)})}function cl(e,t,n,i){var r=bn[n];if(r){n=r(),e={periodStart:0,segmentStart:0,segmentEnd:e.g.duration,vttOffset:0},t=ne(t);var a=t=n.parseMedia(t,e,null),o=i;function s(e){for(var t=e,n=we(o),i=n.next();!i.done;i=n.next())(i=i.value).end&&i.start"===(n=n.trim()).substr(0,5)&&""===n.substr(-6)&&(n=n.slice(5,-6),e=!0);try{var i=JSON.parse(n);i.ckc&&(n=i.ckc,e=!0),i.CkcMessage&&(n=i.CkcMessage,e=!0),i.License&&(n=i.License,e=!0)}catch(e){}e&&(t.data=vt(Lr(n)))}},Nu.expressplayFairPlayRequest=function(e,t){Uu(e,t)},Nu.conaxFairPlayRequest=function(e,t){Uu(e,t)},Nu.ezdrmFairPlayRequest=function(e,t){Uu(e,t)},Nu.verimatrixFairPlayRequest=function(e,t){2===e&&(e=Mr(e=ne(t.body)),t.headers["Content-Type"]="application/x-www-form-urlencoded",t.body=dr("spc="+e))},Nu.expressplayInitDataTransform=_u,Nu.conaxInitDataTransform=function(e,t,n){if("skd"!==t)return e;t=n.serverCertificate,n=hr(e).split("skd://").pop().split("?").shift(),n=H.atob(n);for(var i=yt(i=new ArrayBuffer(2*n.length)),r=0,a=n.length;r=a)})):u.Ed=[],n={Tf:t,position:i},0<=(t=(e=e.Ed).findIndex(function(e){return e.position>=i}))?e.splice(t,e[t].position==i?1:0,n):e.push(n))},Gg:function(e,t){var n=l.u;if(n.h.parseInbandPsshEnabled&&!n.K&&["audio","video"].includes(e)){var i=0,r=we((t=new Dr(ne(t))).data);for(e=r.next();!e.done;e=r.next())i+=e.value.length;if(0==i)n=Promise.resolve();else{for(i=new Uint8Array(i),r=0,e=(t=we(t.data)).next();!e.done;e=t.next())e=e.value,i.set(e,r),r+=e.length;sa(n,"cenc",i),n=n.l}}else n=Promise.resolve();return n},Xi:function(e,t,n){Qu(l,e,t,n)},ae:function(e,t){return l.ae(e,t)}}),f.j.configure(f.h.streaming),f.l=Kl,g.textTracks&&f.m.o(g.textTracks,"addtrack",function(e){e.track&&"chapters"===(e=e.track).kind&&Zu(f,e)}),f.dispatchEvent(Xu("streaming")),m=null,(v=f.j.j)||(m=Tl(f,!0)),y=[],w=we([(b=v||m).video,b.audio]),T=w.next();!T.done;T=w.next())(A=T.value)&&!A.segmentIndex&&y.push(A.createSegmentIndex());if(0, the browser will not load anything until play() is called. We are unable to measure load latency in a meaningful way, and we cannot provide track info yet. Please do not use preload="none" with Shaka Player.'),i.resolve()),r.m.na(a,"error",function(){i.reject(Pl(r))}),Te(e,i,2);(s=r.R())&&r.h.streaming.liveSync?(u=function(){return yl(r)},r.m.o(a,"timeupdate",u)):s||(l=function(){return bl(r)},r.m.o(a,"timeupdate",l),bl(r)),r.D&&(r.D.onManifestUpdated(s),s&&(c=r.Ca().end,r.m.o(a,"progress",function(){var e=r.Ca().end;c!=e&&(r.D.onManifestUpdated(r.R()),c=e)}))),r.Va=!0,Ae(e)})),0);var r,t,n,a,o,i,s,u,l,c})},"srcEqualsInner_"),10);case 10:C.dispatchEvent(Xu("loaded")),Se(e,0);break;case 5:if(7e3!=(o=xe(e)).code)return Te(e,C.Uc(!1),18);e.F(18);break;case 18:throw o}})},t.cj=function(){for(var e=this.V;e.g;)e.release()},t.configure=function(e,t){(e=2==arguments.length&&"string"==typeof e?Mu(e,t):e).streaming&&"forceTransmuxTS"in e.streaming&&(bi("streaming.forceTransmuxTS configuration","Please Use mediaSource.forceTransmux instead."),e.mediaSource.mediaSource=e.streaming.forceTransmuxTS,delete e.streaming.forceTransmuxTS),e.streaming&&"forceTransmux"in e.streaming&&(bi("streaming.forceTransmux configuration","Please Use mediaSource.forceTransmux instead."),e.mediaSource.mediaSource=e.streaming.forceTransmux,delete e.streaming.forceTransmux),e.streaming&&e.streaming.lowLatencyMode&&(null==e.streaming.inaccurateManifestTolerance&&(e.streaming.inaccurateManifestTolerance=0),null==e.streaming.rebufferingGoal&&(e.streaming.rebufferingGoal=.01),null==e.streaming.segmentPrefetchLimit&&(e.streaming.segmentPrefetchLimit=2),null==e.streaming.retryParameters&&(e.streaming.retryParameters={}),null==e.streaming.retryParameters.baseDelay&&(e.streaming.retryParameters.baseDelay=100),null==e.manifest&&(e.manifest={}),null==e.manifest.retryParameters&&(e.manifest.retryParameters={}),null==e.manifest.retryParameters.baseDelay&&(e.manifest.retryParameters.baseDelay=100),null==e.drm&&(e.drm={}),null==e.drm.retryParameters&&(e.drm.retryParameters={}),null==e.drm.retryParameters.baseDelay&&(e.drm.retryParameters.baseDelay=100));var n=Bu(this.h,e,hl(this));return il(this),n},t.getConfiguration=function(){var e=hl(this);return Bu(e,this.h,hl(this)),e},t.Uh=function(){if(this.g){var e=(e=this.g.buffered.length)?this.g.buffered.end(e-1):0,t=this.getConfiguration().streaming.bufferingGoal;if((t=Math.min(this.g.currentTime+t,this.Ca().end))<=e)return 1;if(!(e<=this.g.currentTime)&&e=t.end&&r.md():e<=t.start+n&&r.md()}))},t.md=function(){var e=this.K.Jc();this.l==zl&&this.K.set(e),this.l==Kl&&(this.K.set(e),this.s.playbackRateChanged(e),Rs(this.j,!1)),this.va.bb()},t.jb=function(){if(this.i){for(var e,t=this.j?this.j.j:null,n=[],i=0,r=we(this.i.variants),a=r.next();!a.done;a=r.next())ri(a=a.value)&&((e=Qn(a)).active=a==t,e.active||1==i||null==t||a.video!=t.video||a.audio!=t.audio||(e.active=!0),e.active&&i++,n.push(e));return n}return this.g&&this.g.audioTracks?Array.from(this.g.audioTracks).map(ni):[]},t.Yb=function(){if(this.i){for(var e=this.j?this.j.s:null,t=[],n=we(this.i.textStreams),i=n.next();!i.done;i=n.next()){var r=$n(i=i.value);r.active=i==e,t.push(r)}return t}return this.g&&this.g.src&&this.g.textTracks?al(this).map(ti):[]},t.ee=function(){var e=this.rc;return(e=this.i?this.i.imageStreams:e).map(Zn)},t.Rh=function(r){var a,o,t,s=this;return Ie(function(e){return 1==e.g?s.l!=Kl&&s.l!=zl?e.return(null):(t=s.rc,s.i&&(t=s.i.imageStreams),(a=t.find(function(e){return e.id==r}))?a.segmentIndex?e.F(2):Te(e,a.createSegmentIndex(),2):e.return(null)):4!=e.g?(o=[],ls(a.segmentIndex,function(e){if(t=rl(e.tilesLayout||a.tilesLayout))for(var t=t.rows*t.jc,n=e.h-e.startTime,i=0;ie(a,t))&&(n=a);n?(e=Qn(n),this.Ke(e,!0,i)):Al(this)}else this.g&&this.g.audioTracks&&(i=oi(this.jb(),e,t||"",!1)[0])&&this.Ke(i)},t.ig=function(e,t,n){n=void 0!==n&&n,this.i&&this.G?(this.Ua=e,this.kc=t||"",this.Sb=n,(e=oi(this.i.textStreams,this.Ua,this.kc,this.Sb)[0]||null)&&e!=this.j.s&&(Ku(this.C.h,e,!1),this.h.streaming.alwaysStreamText||this.vc())&&(Ps(this.j,e),kl(this))):(e=oi(this.Yb(),e,t||"",n)[0])&&this.jg(e)},t.lj=function(e,t,n){if(t=void 0===t||t,n=void 0===n?0:n,this.i&&this.G){for(var i=null,r=we(this.i.variants),a=r.next();!a.done;a=r.next())if((a=a.value).audio.label==e){i=a;break}null!=i&&(this.Oa=new Ci(i.language,"",0,"",!1,"",e,"",this.h.mediaSource.codecSwitchingStrategy,this.h.manifest.dash.enableAudioGroups),Al(this,t,n))}else if(this.g&&this.g.audioTracks){for(t=null,i=(n=we(n=Array.from(this.g.audioTracks))).next();!i.done;i=n.next())(i=i.value).label==e&&(t=i);t&&Sl(this,t)}},t.vc=function(){var e=this.$;return this.I&&this.l==Kl?this.I.H.isTextVisible():this.g&&this.g.src&&this.g.textTracks?al(this).some(function(e){return"showing"==e.mode}):e},t.Sg=function(){return this.g&&this.g.src&&this.g.textTracks?ol(this).map(ti):[]},t.Ff=function(e){if(!this.g||!this.g.src||!this.g.textTracks)return[];var t=de(e),n=ol(this).filter(function(e){return de(e.language)==t});if(!n||!n.length)return[];e=[];for(var i=new Set,r=(n=we(n)).next();!r.done;r=n.next())if((r=r.value)&&r.cues)for(var a=(r=we(r.cues)).next();!a.done;a=r.next()){var o={id:a=(a=(o=a.value).id)&&""!=a?a:o.startTime+"-"+o.endTime+"-"+o.text,title:o.text,startTime:o.startTime,endTime:o.endTime};i.has(a)||(e.push(o),i.add(a))}return e},t.Me=function(e){if(this.$!=(e=!!e)){if(this.$=e,this.l==Kl)this.I.H.setTextVisibility(e),this.h.streaming.alwaysStreamText||(e?this.j.s||0<(e=oi(this.i.textStreams,this.Ua,this.kc,this.Sb)).length&&(Ps(this.j,e[0]),kl(this)):(i=this.j,(r=i.i.get(he))&&(Hs(r),Xs(r).catch(function(){}),i.i.delete(he)),i.s=null));else if(this.g&&this.g.src&&this.g.textTracks)for(var t=al(this),n=(t=we(t)).next();!n.done;n=t.next())"disabled"!=(n=n.value).mode&&(n.mode=e?"showing":"hidden");Cl(this)}var i,r},t.ni=function(){if(!this.R())return null;if(this.G)var e=this.G.Wd();else{if(null==this.ha)return new Date;e=this.ha}return this.i?new Date(1e3*(this.i.presentationTimeline.i+e)):this.g&&this.g.getStartDate?(t=this.g.getStartDate(),isNaN(t.getTime())?null:new Date(t.getTime()+1e3*e)):null;var t},t.Vg=function(){return this.R()?this.i?new Date(1e3*this.i.presentationTimeline.i):this.g&&this.g.getStartDate?(e=this.g.getStartDate(),isNaN(e.getTime())?null:e):null:null;var e},t.Ib=function(){if(this.l==Kl)return this.I.Ib();var e={total:[],audio:[],video:[],text:[]};return this.l==zl&&(e.total=Ba(this.g.buffered)),e},t.getStats=function(){if(this.l!=Kl&&this.l!=zl)return{width:NaN,height:NaN,streamBandwidth:NaN,decodedFrames:NaN,droppedFrames:NaN,corruptedFrames:NaN,stallsDetected:NaN,gapsJumped:NaN,estimatedBandwidth:NaN,completionPercent:NaN,loadLatency:NaN,manifestTimeSeconds:NaN,drmTimeSeconds:NaN,playTime:NaN,pauseTime:NaN,bufferingTime:NaN,licenseTime:NaN,liveLatency:NaN,maxSegmentDuration:NaN,switchHistory:[],stateHistory:[]};vl(this);var e,t,n=(r=this.g).currentTime/r.duration,i=(isNaN(n)||(t=this.C,n=Math.round(100*n),t.i=isNaN(t.i)?n:Math.max(t.i,n)),this.G&&(this.C.M=this.G.Bg(),this.C.N=this.G.Cg()),r.getVideoPlaybackQuality&&(t=r.getVideoPlaybackQuality(),n=this.C,e=Number(t.totalVideoFrames),n.L=Number(t.droppedVideoFrames),n.K=e,this.C.J=Number(t.corruptedVideoFrames)),t=this.u?(t=this.u).J||NaN:NaN,this.C.u=t,this.l==Kl&&(t=this.j.j,n=this.j.s,t&&(a=(e=this.K?this.K.h:1)*t.bandwidth,n&&n.bandwidth&&(a+=e*n.bandwidth),this.C.D=a),t&&t.video&&(n=this.C,e=t.video.height||NaN,n.s=t.video.width||NaN,n.l=e),this.R()&&(t=this.Vg().valueOf()+1e3*r.currentTime,this.C.G=(Date.now()-t)/1e3),this.i&&this.i.presentationTimeline&&(this.C.I=this.i.presentationTimeline.g),t=this.s.getBandwidthEstimate(),this.C.C=t),this.l==zl&&(t=this.C,n=r.videoHeight||NaN,t.s=r.videoWidth||NaN,t.l=n),this.C),r=i.s;t=i.l,n=i.D,e=i.K;for(var a=i.L,o=i.J,s=i.N,u=i.M,l=i.C,c=i.i,h=i.m,d=i.H,f=i.j,p=Gu(i.g,"playing"),g=Gu(i.g,"paused"),m=Gu(i.g,"buffering"),v=i.u,y=i.G,b=i.I,w=function(e){function t(e){return{timestamp:e.timestamp,state:e.state,duration:e.duration}}for(var n=[],i=we(e.h),r=i.next();!r.done;r=i.next())n.push(t(r.value));return e.g&&n.push(t(e.g)),n}(i.g),T=[],A=(i=we(i.h.g)).next();!A.done;A=i.next())A=A.value,T.push({timestamp:A.timestamp,id:A.id,type:A.type,fromAdaptation:A.fromAdaptation,bandwidth:A.bandwidth});return{width:r,height:t,streamBandwidth:n,decodedFrames:e,droppedFrames:a,corruptedFrames:o,stallsDetected:s,gapsJumped:u,estimatedBandwidth:l,completionPercent:c,loadLatency:h,manifestTimeSeconds:d,drmTimeSeconds:f,playTime:p,pauseTime:g,bufferingTime:m,licenseTime:v,liveLatency:y,maxSegmentDuration:b,stateHistory:w,switchHistory:T}},t.Hh=function(t,n,i,r,a,o,s){s=void 0!==s&&s;var u,l,c,h,d,f,p,g=this;return Ie(function(e){switch(e.g){case 1:if(g.l!=Kl&&g.l!=zl)throw new ke(1,7,7004);if(r){e.F(2);break}return Te(e,sl(g,t),3);case 3:r=e.h;case 2:if(u=[],g.D&&(u=g.D.getCuePoints()),g.l==zl)return Te(e,ul(g,t,n,i=s?"forced":i,r,o||"",u),5);e.F(4);break;case 5:if(l=de(n),d=g.Yb(),d=d.find(function(e){return de(e.language)==l&&e.label==(o||"")&&e.kind==i}))return xl(g),e.return(d);throw new ke(1,2,2012);case 4:if(c=He,h=g.g.duration,1/0==(h=g.i?g.i.presentationTimeline.getDuration():h))throw new ke(1,4,4033);if(u.length)return Te(e,ll(g,t,g.J,g.h.streaming.retryParameters),7);e.F(6);break;case 7:d=e.h,f=cl(g,d,r,u),f=new Blob([f],{type:"text/vtt"}),t=Go(f),r="text/vtt";case 6:if(f={id:g.Ag++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:cs(0,h,[t]),mimeType:r||"",codecs:a||"",kind:i,encrypted:!1,drmInfos:[],keyIds:new Set,language:n,originalLanguage:n,label:o||null,type:c.Ea,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!!s,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!0,fastSwitching:!1},p=on(f.mimeType,f.codecs),mn(p))return g.i.textStreams.push(f),xl(g),e.return($n(f));throw new ke(2,2,2014,r)}})},t.Ih=function(t,n){var i,r,a,o,s,u,l,c,h,d,f,p=this;return Ie(function(e){switch(e.g){case 1:if(p.l!=Kl&&p.l!=zl)throw new ke(1,7,7004);if(n){e.F(2);break}return Te(e,sl(p,t),3);case 3:n=e.h;case 2:if("text/vtt"!=n)throw new ke(1,2,2017,t);if(i=He,r=p.g.duration,1/0==(r=p.i?p.i.presentationTimeline.getDuration():r))throw new ke(1,4,4045);return Te(e,ll(p,t,p.J,p.h.streaming.retryParameters),4);case 4:if(f=e.h,!(o=bn[n]))throw new ke(2,2,2014,n);for(o=o(),a={periodStart:0,segmentStart:0,segmentEnd:r,vttOffset:0},f=ne(f),o=o.parseMedia(f,a,t),s=[],u={},l=we(o),c=l.next();!c.done;u={gd:u.gd,fc:u.fc},c=l.next())u.fc=c.value,u.gd=null,h=function(e){return function(){return null==e.gd&&(e.gd=Ge([t],[e.fc.payload])),e.gd||[]}}(u),h=new P(u.fc.startTime,u.fc.endTime,h,0,null,null,0,0,1/0),u.fc.payload.includes("#xywh")&&(4===(d=u.fc.payload.split("#xywh=")[1].split(",")).length&&h.rh({height:parseInt(d[3],10),positionX:parseInt(d[0],10),positionY:parseInt(d[1],10),width:parseInt(d[2],10)})),s.push(h);return f={id:p.Ag++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new us(s),mimeType:n||"",codecs:"",kind:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:i.$e,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,tilesLayout:"1x1",accessibilityPurpose:null,external:!0,fastSwitching:!1},(p.l==zl?p.rc:p.i.imageStreams).push(f),xl(p),e.return(Zn(f))}})},t.Gh=function(t,n,i){var r,a,o,s=this;return Ie(function(e){switch(e.g){case 1:if(s.l!=Kl&&s.l!=zl)throw new ke(1,7,7004);if(i){e.F(2);break}return Te(e,sl(s,t),3);case 3:i=e.h;case 2:return a=[],s.D&&(a=s.D.getCuePoints()),Te(e,ul(s,t,n,"chapters",i,"",a),4);case 4:if(r=e.h,a=s.Sg(),o=a.find(function(e){return e.language==n}))return Te(e,new Promise(function(e,t){s.m.na(r,"load",e),s.m.na(r,"error",function(){t(new ke(1,2,2015))})}),6);e.F(5);break;case 6:return xl(s),e.return(o);case 5:throw new ke(1,2,2012)}})},t.ng=function(e,t){this.xg.width=e,this.xg.height=t},t.eg=function(e){if(this.l==Kl){var t=this.j;if(e=void 0===e?.1:e,t.l.g)t=!1;else if(t.u)t=!1;else{for(var n=we(t.i.values()),i=n.next();!i.done;i=n.next())!(i=i.value).ud||i.Ra||i.Bb||(i.ud=!1,zs(t,i,e));t=!0}}else t=!1;return t},t.ji=function(){return X("Shaka Player's internal Manifest structure is NOT covered by semantic versioning compatibility guarantees. It may change at any time! Please consider filing a feature request for whatever you use getManifest() for."),this.i},t.ki=function(){return this.Ge},t.rg=function(e){this.me=e},t.ae=function(t,e){if(!this.h.abr.enabled||this.l===Gl||!navigator.onLine)return!1;if(this.i.variants.some(function(e){return!(!(e=e[t.type])||e.id===t.id)&&("audio"!=t.type||t.language===e.language)})){for(var n=we(this.i.variants),i=n.next();!i.done;i=n.next()){var r=(i=i.value)[t.type];r&&r.id===t.id&&(i.disabledUntilTime=Date.now()/1e3+e)}return this.re.za(1),e=this.Ib().video.reduce(function(e,t){return e+t.end-t.start},0),Al(this,!0,e,!0,!1),!0}return!1},i("shaka.Player",l),l.prototype.setVideoContainer=l.prototype.rg,l.prototype.getManifestParserFactory=l.prototype.ki,l.prototype.getManifest=l.prototype.ji,l.prototype.retryStreaming=l.prototype.eg,l.prototype.setMaxHardwareResolution=l.prototype.ng,l.prototype.addChaptersTrack=l.prototype.Gh,l.prototype.addThumbnailsTrack=l.prototype.Ih,l.prototype.addTextTrackAsync=l.prototype.Hh,l.prototype.getBufferedInfo=l.prototype.Ib,l.prototype.getPresentationStartTimeAsDate=l.prototype.Vg,l.prototype.getPlayheadTimeAsDate=l.prototype.ni,l.prototype.setTextTrackVisibility=l.prototype.Me,l.prototype.getChapters=l.prototype.Ff,l.prototype.getChaptersTracks=l.prototype.Sg,l.prototype.isTextTrackVisible=l.prototype.vc,l.prototype.selectVariantsByLabel=l.prototype.lj,l.prototype.selectTextLanguage=l.prototype.ig,l.prototype.selectAudioLanguage=l.prototype.Je,l.prototype.getTextLanguages=l.prototype.ti,l.prototype.getAudioLanguages=l.prototype.Sh,l.prototype.getTextLanguagesAndRoles=l.prototype.wi,l.prototype.getAudioLanguagesAndRoles=l.prototype.Th,l.prototype.selectVariantTrack=l.prototype.Ke,l.prototype.selectTextTrack=l.prototype.jg,l.prototype.getThumbnails=l.prototype.Jf,l.prototype.getAllThumbnails=l.prototype.Rh,l.prototype.getImageTracks=l.prototype.ee,l.prototype.getTextTracks=l.prototype.Yb,l.prototype.getVariantTracks=l.prototype.jb,l.prototype.cancelTrickPlay=l.prototype.md,l.prototype.trickPlay=l.prototype.Nd,l.prototype.getPlaybackRate=l.prototype.Jb,l.prototype.isBuffering=l.prototype.wd,l.prototype.getKeyStatuses=l.prototype.fe,l.prototype.getActiveSessionsMetadata=l.prototype.Df,l.prototype.getExpiration=l.prototype.rd,l.prototype.goToLive=l.prototype.Ei,l.prototype.seekRange=l.prototype.Ca,l.prototype.isAudioOnly=l.prototype.Nc,l.prototype.isInProgress=l.prototype.uc,l.prototype.isLive=l.prototype.R,l.prototype.getAdManager=l.prototype.ce,l.prototype.getAssetUri=l.prototype.Ef,l.prototype.getNetworkingEngine=l.prototype.Vb,l.prototype.getMediaElement=l.prototype.mi,l.prototype.getManifestType=l.prototype.Hf,l.prototype.getLoadMode=l.prototype.ge,l.prototype.resetConfiguration=l.prototype.gj,l.prototype.getBufferFullness=l.prototype.Uh,l.prototype.releaseAllMutexes=l.prototype.cj,l.prototype.updateStartTime=l.prototype.uj,l.prototype.unload=l.prototype.Uc,l.prototype.attachCanvas=l.prototype.Eg,l.prototype.attach=l.prototype.Ec,l.probeSupport=function(l){var c,h,d,f,p;return l=void 0===l||l,Ie(function(e){if(1==e.g)return c={},l?Te(e,Ie(function(e){return 1==e.g?(n="org.w3.clearkey com.widevine.alpha com.microsoft.playready com.microsoft.playready.recommendation com.apple.fps.1_0 com.apple.fps com.adobe.primetime".split(" "),r=[{videoCapabilities:t=[{contentType:'video/mp4; codecs="avc1.42E01E"'},{contentType:'video/webm; codecs="vp8"'}],persistentState:"required",sessionTypes:["persistent-license"]},{initDataTypes:["cenc"],videoCapabilities:t}],a=new Map,t=function(t){var n,i;return Ie(function(e){switch(e.g){case 1:if(Ee(e,2),"org.w3.clearkey"===t&&Un())throw Error("Unsupported keySystem");return Te(e,navigator.requestMediaKeySystemAccess(t,r),4);case 4:return n=e.h,i=!!(i=n.getConfiguration().sessionTypes)&&i.includes("persistent-license"),Rn()&&(i=!1),a.set(t,{persistentState:i}),Te(e,n.createMediaKeys(),5);case 5:Se(e,0);break;case 2:xe(e),a.set(t,null),Ae(e)}})},n=n.map(t),Te(e,Promise.all(n),2)):e.return(sr(a))}),3):e.F(2);2!=e.g&&(c=e.h);var r,a,t,n,i={};if(In())for(var o in Ca)i[o]=!0;for(var s=(o=we(["application/dash+xml","application/x-mpegurl","application/vnd.apple.mpegurl","application/vnd.ms-sstr+xml"])).next();!s.done;s=o.next())i[s=s.value]=In()?!!Ca[s]:kn(s);for(h=i,i={},s=(o=we(o='video/mp4; codecs="avc1.42E01E",video/mp4; codecs="avc3.42E01E",video/mp4; codecs="hev1.1.6.L93.90",video/mp4; codecs="hvc1.1.6.L93.90",video/mp4; codecs="hev1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="hvc1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="vp9",video/mp4; codecs="vp09.00.10.08",video/mp4; codecs="av01.0.01M.08",video/mp4; codecs="dvh1.20.01",audio/mp4; codecs="mp4a.40.2",audio/mp4; codecs="ac-3",audio/mp4; codecs="ec-3",audio/mp4; codecs="ac-4",audio/mp4; codecs="opus",audio/mp4; codecs="flac",audio/mp4; codecs="dtsc",audio/mp4; codecs="dtse",audio/mp4; codecs="dtsx",video/webm; codecs="vp8",video/webm; codecs="vp9",video/webm; codecs="vp09.00.10.08",audio/webm; codecs="vorbis",audio/webm; codecs="opus",video/mp2t; codecs="avc1.42E01E",video/mp2t; codecs="avc3.42E01E",video/mp2t; codecs="hvc1.1.6.L93.90",video/mp2t; codecs="mp4a.40.2",video/mp2t; codecs="ac-3",video/mp2t; codecs="ec-3",text/vtt,application/mp4; codecs="wvtt",application/ttml+xml,application/mp4; codecs="stpp"'.split(",").concat(le(pn)))).next();!s.done;s=o.next()){i[s=s.value]=In()?!!mn(s)||(lt(s)||!!$t(s)):kn(s);var u=s.split(";")[0];i[u]=i[u]||i[s]}for(p in d={manifest:h,media:i,drm:c},f=Wl)d[p]=f[p]();return e.return(d)})},l.isBrowserSupported=Wu,l.setAdManagerFactory=function(e){ql=e},l.registerSupportPlugin=function(e,t){Wl[e]=t};var Gl=0,Vl=1,Kl=2,zl=3,Hl=(l.LoadMode={DESTROYED:Gl,NOT_LOADED:Vl,MEDIA_SOURCE:Kl,SRC_EQUALS:zl},l.version="v4.7.6",["4","7"]),Ai=new function(e){this.g=e,this.i=wi,this.h=Ti}(new yi(Number(Hl[0]),Number(Hl[1]))),Xl=["output-restricted","internal-error"],Wl={},ql=null;function Yl(){this.h=[],this.j=this.i=this.g=0}function Jl(e,t,n){var i=this;this.g=e,this.h=t,this.j=n,this.i=!1,this.l=this.h.getVolume(),this.m=new nr,this.m.o(this.h,google.ima.AdEvent.Type.PAUSED,function(){i.i=!0}),this.m.o(this.h,google.ima.AdEvent.Type.RESUMED,function(){i.i=!1})}function Ql(e,t,n,i,r){var u=this;this.s=e,this.i=t,this.D=!1,this.u=this.G=null,this.H=NaN,this.m=r,this.j=null,this.h=new nr,google.ima.settings.setLocale(n),google.ima.settings.setDisableCustomPlaybackForIOS10Plus(!0),(e=new google.ima.AdDisplayContainer(this.s,this.i)).initialize(),this.l=new google.ima.AdsLoader(e),this.l.getSettings().setPlayerType("shaka-player"),this.l.getSettings().setPlayerVersion("v4.7.6"),this.g=null,this.C=i||new google.ima.AdsRenderingSettings,this.h.o(this.l,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,function(e){var t,n=u,i=e,r=(n.m(new ce("ads-loaded",(new Map).set("loadTime",Date.now()/1e3-n.H))),n.G.customPlayheadTracker?(t={currentTime:n.i.currentTime},n.g=i.getAdsManager(t,n.C),n.i.muted?n.g.setVolume(0):n.g.setVolume(n.i.volume),n.h.o(n.i,"timeupdate",function(){n.i.duration&&(t.currentTime=n.i.currentTime)}),n.h.o(n.i,"volumechange",function(){n.j&&(n.j.setVolume(n.i.volume),n.i.muted&&n.j.setMuted(!0))})):n.g=i.getAdsManager(n.i,n.C),n.m(new ce("ima-ad-manager-loaded",(new Map).set("imaAdManager",n.g))),n.g.getCuePoints());if(r.length){i=[];for(var a=(r=we(r)).next();!a.done;a=r.next())i.push({start:a.value,end:null});n.m(new ce("ad-cue-points-changed",(new Map).set("cuepoints",i)))}var o=n;function s(e,t){e=(new Map).set("originalEvent",e),o.m(new ce(t,e))}o.h.o(o.g,google.ima.AdErrorEvent.Type.AD_ERROR,function(e){$l(o,e)}),o.h.o(o.g,google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED,function(e){ec(o,e)}),o.h.o(o.g,google.ima.AdEvent.Type.STARTED,function(e){ec(o,e)}),o.h.o(o.g,google.ima.AdEvent.Type.FIRST_QUARTILE,function(e){s(e,"ad-first-quartile")}),o.h.o(o.g,google.ima.AdEvent.Type.MIDPOINT,function(e){s(e,"ad-midpoint")}),o.h.o(o.g,google.ima.AdEvent.Type.THIRD_QUARTILE,function(e){s(e,"ad-third-quartile")}),o.h.o(o.g,google.ima.AdEvent.Type.COMPLETE,function(e){s(e,"ad-complete")}),o.h.o(o.g,google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED,function(e){tc(o,e)}),o.h.o(o.g,google.ima.AdEvent.Type.ALL_ADS_COMPLETED,function(e){tc(o,e)}),o.h.o(o.g,google.ima.AdEvent.Type.SKIPPED,function(e){s(e,"ad-skipped")}),o.h.o(o.g,google.ima.AdEvent.Type.VOLUME_CHANGED,function(e){s(e,"ad-volume-changed")}),o.h.o(o.g,google.ima.AdEvent.Type.VOLUME_MUTED,function(e){s(e,"ad-muted")}),o.h.o(o.g,google.ima.AdEvent.Type.PAUSED,function(e){o.j&&(o.j.i=!0,s(e,"ad-paused"))}),o.h.o(o.g,google.ima.AdEvent.Type.RESUMED,function(e){o.j&&(o.j.i=!1,s(e,"ad-resumed"))}),o.h.o(o.g,google.ima.AdEvent.Type.SKIPPABLE_STATE_CHANGED,function(e){o.j&&s(e,"ad-skip-state-changed")}),o.h.o(o.g,google.ima.AdEvent.Type.CLICK,function(e){s(e,"ad-clicked")}),o.h.o(o.g,google.ima.AdEvent.Type.AD_PROGRESS,function(e){s(e,"ad-progress")}),o.h.o(o.g,google.ima.AdEvent.Type.AD_BUFFERING,function(e){s(e,"ad-buffering")}),o.h.o(o.g,google.ima.AdEvent.Type.IMPRESSION,function(e){s(e,"ad-impression")}),o.h.o(o.g,google.ima.AdEvent.Type.DURATION_CHANGE,function(e){s(e,"ad-duration-changed")}),o.h.o(o.g,google.ima.AdEvent.Type.USER_CLOSE,function(e){s(e,"ad-closed")}),o.h.o(o.g,google.ima.AdEvent.Type.LOADED,function(e){s(e,"ad-loaded")}),o.h.o(o.g,google.ima.AdEvent.Type.ALL_ADS_COMPLETED,function(e){s(e,"all-ads-completed")}),o.h.o(o.g,google.ima.AdEvent.Type.LINEAR_CHANGED,function(e){s(e,"ad-linear-changed")}),o.h.o(o.g,google.ima.AdEvent.Type.AD_METADATA,function(e){s(e,"ad-metadata")}),o.h.o(o.g,google.ima.AdEvent.Type.LOG,function(e){s(e,"ad-recoverable-error")}),o.h.o(o.g,google.ima.AdEvent.Type.AD_BREAK_READY,function(e){s(e,"ad-break-ready")}),o.h.o(o.g,google.ima.AdEvent.Type.INTERACTION,function(e){s(e,"ad-interaction")});try{n.g.init(n.i.offsetWidth,n.i.offsetHeight,Zl(n)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL),n.h.o(n.i,"loadeddata",function(){n.g.resize(n.i.offsetWidth,n.i.offsetHeight,Zl(n)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),"ResizeObserver"in H?(n.u=new ResizeObserver(function(){n.g.resize(n.i.offsetWidth,n.i.offsetHeight,Zl(n)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),n.u.observe(n.i)):n.h.o(document,"fullscreenchange",function(){n.g.resize(n.i.offsetWidth,n.i.offsetHeight,Zl(n)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),n.D?n.g.start():n.h.na(n.i,"play",function(){n.D=!0,n.g.start()})}catch(e){tc(n,null)}}),this.h.o(this.l,google.ima.AdErrorEvent.Type.AD_ERROR,function(e){$l(u,e)}),this.h.o(this.i,"ended",function(){u.l.contentComplete()}),this.h.na(this.i,"play",function(){u.D=!0})}function $l(e,t){t.getError(),t=(new Map).set("originalEvent",t),e.m(new ce("ad-error",t)),tc(e,null),e.m(new ce("ad-cue-points-changed",(new Map).set("cuepoints",[])))}function Zl(e){return document.fullscreenEnabled?document.fullscreenElement:(e=e.i).webkitSupportsFullscreen&&e.webkitDisplayingFullscreen}function ec(e,t){var n=t.getAd();n?(e.j=new Jl(n,e.g,e.i),t=(new Map).set("ad",e.j).set("sdkAdObject",n).set("originalEvent",t),e.m(new ce("ad-started",t)),e.j.isLinear()&&(e.s.setAttribute("ad-active","true"),e.i.pause(),e.i.muted?((t=e.j).l=e.i.volume,t.h.setVolume(0)):e.j.setVolume(e.i.volume))):X("The IMA SDK fired a "+t.type+" event with no associated ad. Unable to play ad!")}function tc(e,t){e.m(new ce("ad-stopped",(new Map).set("originalEvent",t))),e.j&&e.j.isLinear()&&(e.s.removeAttribute("ad-active"),e.i.ended||e.i.play())}function nc(e,t,n,i,r){this.h=e,this.g=r,this.i=t,this.j=n,this.l=i}function ic(e,t,n,i){this.D=e,this.K=t,this.g=n,this.l=null,this.V=NaN,this.i=i,this.J=!1,this.C=null,this.j=[],this.M=[],this.L=this.G=this.h=null,this.H=new Map,this.m=[],this.u=[],this.N="",this.U=!0,this.I="",this.s=new nr}function rc(e){return[e.adId,e.adParameters,e.adSystem,e.adTitle,e.creativeAdId,e.creativeId,e.creativeSequence,e.height,e.width,e.staticResource].join("")}function ac(e){var t=e.g.currentTime;if(0!=t&&null==e.C){for(var n,i,r=we(e.j),a=r.next();!a.done;a=r.next())for(var o=we((a=a.value).ads),s=o.next();!s.done;s=o.next())if(s=s.value,i){if(s.startTimeInSecondsi.startTimeInSeconds+i.durationInSeconds){i=s,n=a;break}}else s.startTimeInSeconds=t.startTimeInSeconds+.25*t.durationInSeconds&&!e.u.includes("firstQuartile")?(e.u.push("firstQuartile"),lc(e,"firstQuartile")):n<=r&&!e.u.includes("midpoint")?(e.u.push("midpoint"),lc(e,"midpoint")):i<=r&&!e.u.includes("thirdQuartile")&&(e.u.push("thirdQuartile"),lc(e,"thirdQuartile")),t=e.h.getRemainingTime(),0<(n=e.h.getDuration())&&(t<=0||nr&&(e.g.currentTime=e.C),e.C=null)}}}function sc(e){if(e.h){for(;e.D.lastChild;)e.D.removeChild(e.D.firstChild);e.J||e.M.push(e.G.adId),lc(e,"complete");for(var t=we(e.m),n=t.next();!n.done;n=t.next())n=n.value,e.s.dc(n.target,n.type,n.listener);e.m=[],e.u=[],(t=e.h.getPositionInSequence())===(n=e.h.getSequenceLength())&&lc(e,"breakEnd"),e.h=null,e.G=null,e.L=null}}function uc(e){var t=!1;e.g.paused?t=!0:(lc(e,"impression"),lc(e,"start")),e.m.push({target:e.g,type:"volumechange",listener:function(){e.g.muted&&lc(e,"mute")}}),e.m.push({target:e.g,type:"volumechange",listener:function(){e.g.muted||lc(e,"unmute")}}),e.m.push({target:e.g,type:"play",listener:function(){t?(lc(e,"impression"),lc(e,"start"),t=!1):lc(e,"resume")}}),e.m.push({target:e.g,type:"pause",listener:function(){lc(e,"pause")}});for(var n=we(e.m),i=n.next();!i.done;i=n.next())i=i.value,e.s.o(i.target,i.type,i.listener)}function lc(e,t){var n=e.G.trackingEvents.find(function(e){return e.eventType==t});if(n=n||e.L.adBreakTrackingEvents.find(function(e){return e.eventType==t}))for(var i=(n=we(n.beaconUrls)).next();!i.done;i=n.next())(i=i.value)&&""!=i&&((i=Wi([i],_i())).method="POST",e.K.request(7,i));switch(t){case"impression":e.i(new ce("ad-impression"));break;case"start":e.i(new ce("ad-started",(new Map).set("ad",e.h)));break;case"mute":e.i(new ce("ad-muted"));break;case"unmute":e.i(new ce("ad-volume-changed"));break;case"resume":e.i(new ce("ad-resumed"));break;case"pause":e.i(new ce("ad-paused"));break;case"firstQuartile":e.i(new ce("ad-first-quartile"));break;case"midpoint":e.i(new ce("ad-midpoint"));break;case"thirdQuartile":e.i(new ce("ad-third-quartile"));break;case"complete":e.i(new ce("ad-complete")),e.i(new ce("ad-stopped"));break;case"breakStart":e.D.setAttribute("ad-active","true");break;case"breakEnd":e.D.removeAttribute("ad-active")}}function cc(e,t){this.g=e,this.i=null,this.h=t}function hc(e,t,n,i){var r=this;this.u=e,this.l=t,this.j=null,this.H=NaN,this.i=i,this.I=!1,this.C=this.m=this.s=null,this.D="",this.G=[],this.h=new nr,(e=new google.ima.dai.api.UiSettings).setLocale(n),this.g=new google.ima.dai.api.StreamManager(this.l,this.u,e),this.i(new ce("ima-stream-manager-loaded",(new Map).set("imaStreamManager",this.g))),this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.LOADED,function(e){var n;e=e,(n=r).i(new ce("ads-loaded",(new Map).set("loadTime",Date.now()/1e3-n.H))),e=e.getStreamData().url,n.j.resolve(e),n.j=null,n.I||n.h.o(n.l,"seeked",function(){var e,t=n.l.currentTime;0!=t&&(n.g.streamTimeForContentTime(t),(e=n.g.previousCuePointForStreamTime(t))&&!e.played&&(n.s=t,n.l.currentTime=e.start))})}),this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.ERROR,function(){r.D.length?r.j.resolve(r.D):r.j.reject("IMA Stream request returned an error and there was no backup asset uri provided."),r.j=null}),this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.AD_BREAK_STARTED,function(){}),this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.STARTED,function(e){e=e.getAd(),r.m=new cc(e,r.l),r.C&&(r.m.i=r.C),r.i(new ce("ad-started",(new Map).set("ad",r.m))),r.u.setAttribute("ad-active","true")}),this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.AD_BREAK_ENDED,function(){r.u.removeAttribute("ad-active");var e=r.l.currentTime;r.s&&r.s>e&&(r.l.currentTime=r.s,r.s=null)}),this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.AD_PROGRESS,function(e){r.C=e.getStreamData().adProgressData,r.m&&(r.m.i=r.C)}),this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.FIRST_QUARTILE,function(){r.i(new ce("ad-first-quartile"))}),this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.MIDPOINT,function(){r.i(new ce("ad-midpoint"))}),this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.THIRD_QUARTILE,function(){r.i(new ce("ad-third-quartile"))}),this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.COMPLETE,function(){r.i(new ce("ad-complete")),r.i(new ce("ad-stopped")),r.u.removeAttribute("ad-active"),r.m=null}),this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.SKIPPED,function(){r.i(new ce("ad-skipped")),r.i(new ce("ad-stopped"))}),this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.CUEPOINTS_CHANGED,function(e){var t=e.getStreamData();e=[];for(var n=(t=we(t.cuepoints)).next();!n.done;n=t.next())n=n.value,e.push({start:n.start,end:n.end});r.G=e,r.i(new ce("ad-cue-points-changed",(new Map).set("cuepoints",e)))})}function dc(){d.call(this),this.g=this.i=this.h=null,this.j=new Yl,this.m=navigator.language,this.l=null}function fc(e,t){if(t&&t.type)switch(t.type){case"ads-loaded":e.j.h.push(t.loadTime);break;case"ad-started":e.j.g++;break;case"ad-complete":e.j.i++;break;case"ad-skipped":e.j.j++}e.dispatchEvent(t)}function pc(e){return JSON.stringify(e,function(e,t){if("function"!=typeof t){if(t instanceof Event||t instanceof ce){var n={};for(i in t)(e=t[i])&&"object"==typeof e?"detail"==i&&(n[i]=e):i in Event||(n[i]=e);return n}if(t instanceof Error){var i=new Set(["name","message","stack"]);for(n in t)i.add(n);for(n=(e=we(Object.getOwnPropertyNames(t))).next();!n.done;n=e.next())i.add(n.value);for(e={},n=(i=we(i)).next();!n.done;n=i.next())e[n=n.value]=t[n];t={__type__:"Error",contents:e}}else if(t instanceof TimeRanges){for(i={__type__:"TimeRanges",length:t.length,start:[],end:[]},n=(t=we(Ba(t))).next();!n.done;n=t.next())e=(n=n.value).end,i.start.push(n.start),i.end.push(e);t=i}else t=t instanceof Uint8Array?{__type__:"Uint8Array",entries:Array.from(t)}:"number"==typeof t?isNaN(t)?"NaN":isFinite(t)?t:t<0?"-Infinity":"Infinity":t;return t}})}function gc(e){return JSON.parse(e,function(e,t){if("NaN"==t)var n=NaN;else if("-Infinity"==t)n=-1/0;else if("Infinity"==t)n=1/0;else if(t&&"object"==typeof t&&"TimeRanges"==t.__type__)n={length:(i=t).length,start:function(e){return i.start[e]},end:function(e){return i.end[e]}};else if(t&&"object"==typeof t&&"Uint8Array"==t.__type__)n=new Uint8Array(t.entries);else if(t&&"object"==typeof t&&"Error"==t.__type__){for(n in e=t.contents,t=Error(e.message),e)t[n]=e[n];n=t}else n=t;var i;return n})}(t=Jl.prototype).getDuration=function(){return this.g.getDuration()},t.getMinSuggestedDuration=function(){return this.g.getMinSuggestedDuration()},t.getRemainingTime=function(){return this.h.getRemainingTime()},t.isPaused=function(){return this.i},t.isSkippable=function(){return 0<=this.g.getSkipTimeOffset()},t.getTimeUntilSkippable=function(){var e=this.g.getSkipTimeOffset(),e=this.getRemainingTime()-e;return Math.max(e,0)},t.canSkipNow=function(){return this.h.getAdSkippableState()},t.skip=function(){return this.h.skip()},t.pause=function(){return this.h.pause()},t.play=function(){return this.h.resume()},t.getVolume=function(){return this.h.getVolume()},t.setVolume=function(e){return this.j.volume=e,this.h.setVolume(e)},t.isMuted=function(){return 0==this.h.getVolume()},t.isLinear=function(){return this.g.isLinear()},t.resize=function(e,t){var n=!1,i=this.j;document.fullscreenEnabled?n=!!document.fullscreenElement:i.webkitSupportsFullscreen&&(n=i.webkitDisplayingFullscreen),this.h.resize(e,t,n?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)},t.setMuted=function(e){(this.j.muted=e)?(this.l=this.getVolume(),this.h.setVolume(0)):this.h.setVolume(this.l)},t.getSequenceLength=function(){var e=this.g.getAdPodInfo();return null==e?1:e.getTotalAds()},t.getPositionInSequence=function(){var e=this.g.getAdPodInfo();return null==e?1:e.getAdPosition()},t.getTitle=function(){return this.g.getTitle()},t.getDescription=function(){return this.g.getDescription()},t.getVastMediaBitrate=function(){return this.g.getVastMediaBitrate()},t.getVastMediaHeight=function(){return this.g.getVastMediaHeight()},t.getVastMediaWidth=function(){return this.g.getVastMediaWidth()},t.getAdId=function(){return this.g.getAdId()},t.getCreativeAdId=function(){return this.g.getCreativeAdId()},t.getAdvertiserName=function(){return this.g.getAdvertiserName()},t.getMediaUrl=function(){return this.g.getMediaUrl()},t.getTimeOffset=function(){var e=this.g.getAdPodInfo();return null==e?0:e.getTimeOffset()},t.getPodIndex=function(){var e=this.g.getAdPodInfo();return null==e?0:e.getPodIndex()},t.release=function(){this.h=this.g=null},i("shaka.ads.ClientSideAd",Jl),Ql.prototype.configure=function(e){this.G=e},Ql.prototype.stop=function(){this.g&&this.g.stop(),this.s&&iu(this.s)},Ql.prototype.release=function(){this.stop(),this.u&&this.u.disconnect(),this.h&&this.h.release(),this.g&&this.g.destroy(),this.l.destroy()},(t=nc.prototype).getDuration=function(){return this.h.durationInSeconds},t.getMinSuggestedDuration=function(){return this.getDuration()},t.getRemainingTime=function(){return this.h.startTimeInSeconds+this.h.durationInSeconds-this.g.currentTime},t.isPaused=function(){return this.g.paused},t.isSkippable=function(){return!!this.h.skipOffset},t.getTimeUntilSkippable=function(){if(!this.h.skipOffset)return this.getRemainingTime();var e=this.getRemainingTime()-this.h.skipOffset;return Math.max(e,0)},t.canSkipNow=function(){return 0==this.getTimeUntilSkippable()},t.skip=function(){this.g.currentTime+=this.getRemainingTime()},t.pause=function(){return this.g.pause()},t.play=function(){return this.g.play()},t.getVolume=function(){return this.g.volume},t.setVolume=function(e){this.g.volume=e},t.isMuted=function(){return this.g.muted},t.isLinear=function(){return this.l},t.resize=function(){},t.setMuted=function(e){this.g.muted=e},t.getSequenceLength=function(){return this.j||1},t.getPositionInSequence=function(){return this.i||1},t.getTitle=function(){return this.h.adTitle},t.getDescription=function(){return""},t.getVastMediaBitrate=function(){return 0},t.getVastMediaHeight=function(){return 0},t.getVastMediaWidth=function(){return 0},t.getAdId=function(){return this.h.adId},t.getCreativeAdId=function(){return this.h.creativeId},t.getAdvertiserName=function(){return""},t.getMediaUrl=function(){return null},t.getTimeOffset=function(){return 0},t.getPodIndex=function(){return 0},t.release=function(){this.j=this.i=this.g=this.h=null},i("shaka.ads.MediaTailorAd",nc),ic.prototype.stop=function(){for(var e=we(this.m),t=e.next();!t.done;t=e.next())t=t.value,this.s.dc(t.target,t.type,t.listener);sc(this),this.m=[],this.u=[],this.N="",this.U=!0,this.I="",this.C=null,this.j=[],this.M=[],this.H.clear()},ic.prototype.release=function(){this.stop(),this.s&&this.s.release()},ic.prototype.onManifestUpdated=function(e){var n,i,r,a,o,s,u,l,c,h,d,f,p,g,m;this.J=e,""!=this.N&&(i=(n=this).N,r=this.U,Ie(function(e){if(1==e.g)return a=Wi([i],_i()),a=n.K.request(7,a),Ee(e,2),Te(e,a.promise,4);if(2!=e.g){if(a=e.h,o=[],s=lr(a.data),0<(s=JSON.parse(s)).avails.length){if(JSON.stringify(n.j)!=JSON.stringify(s.avails)){for(n.j=s.avails,u=we(n.j),l=u.next();!l.done;l=u.next())for(c=l.value,h=we(c.nonLinearAdsList),d=h.next();!d.done;d=h.next())for(f=d.value,p=we(f.nonLinearAdList),g=p.next();!g.done;g=p.next())m=g.value,function(t,n){var i,r,a;Ie(function(e){return 1==e.g?n.staticResource?(i=rc(n),t.H.get(i)?e.return():(r=Wi([n.staticResource],_i()),r=t.K.request(7,r),Ee(e,2),t.H.set(i,[]),Te(e,r.promise,4))):e.return():2!=e.g?(r=e.h,a=lr(r.data),a=JSON.parse(a),a=a.apps,t.H.set(i,a),Se(e,0)):(xe(e),t.H.delete(i),void Ae(e))})}(n,m);o=n.getCuePoints(),n.i(new ce("ad-cue-points-changed",(new Map).set("cuepoints",o)))}}else n.j.length&&n.i(new ce("ad-cue-points-changed",(new Map).set("cuepoints",o))),sc(n),n.j=[];return r&&(n.J||0>=1;return n}function ud(e,t,n){for(var i=null,r=(t=we(sd(e,t))).next();!r.done;r=t.next()){var r=r.value,a=e.h[r];a.isVisible()&&(i=zh(a,n,e.i)),e.h[r]=null}return i}function ld(e){e.g=null,e.h=[null,null,null,null,null,null,null,null]}function cd(e,t,n){var i={0:0,1:0,2:1,3:1};return dd[(e=i[e])<<2|(t=i[t])<<1|(n=i[n])]}rd.prototype.xa=function(){return this.gthis.h.length)throw new ke(2,2,3e3);this.g+=e};var hd=new Map([[32," "],[33," "],[37,"…"],[42,"Š"],[44,"Œ"],[48,"█"],[49,"‘"],[50,"’"],[51,"“"],[52,"”"],[53,"•"],[57,"™"],[58,"š"],[60,"œ"],[61,"℠"],[63,"Ÿ"],[118,"⅛"],[119,"⅜"],[120,"⅝"],[121,"⅞"],[122,"│"],[123,"┐"],[124,"└"],[125,"─"],[126,"┘"],[127,"┌"]]),dd="black blue green cyan red magenta yellow white".split(" ");function fd(){this.h=[],this.g=[],this.i=new id,this.l=0,this.m=new Map([["CC1",new Mh(0,0)],["CC2",new Mh(0,1)],["CC3",new Mh(1,0)],["CC4",new Mh(1,1)]]),this.u=this.s=0,this.j=new Map,this.D=!0,this.C=new Set,pd(this)}function pd(e){e.s=0,e.u=0;for(var t=we(e.m.values()),n=t.next();!n.done;n=t.next())(n=n.value).h=Ph,n.g=n.j,n.m=null,mh(n.i),mh(n.j),mh(n.s);e.D=!0}function gd(e){for(var t=0;e;)t^=1&e,e>>=1;return 1===t}function md(e){for(var t=[],n=e,i=e=0;i>2,o=e.ra(),s=e.ra();a&&(0==(r&=3)||1==r?this.h.push({pts:t,type:r,hb:o,Gb:s,order:this.h.length}):(this.g.push({pts:t,type:r,value:o,order:this.g.length}),this.g.push({pts:t,type:2,value:s,order:this.g.length})))}},fd.prototype.decode=function(){function e(e,t){return e.pts-t.pts||e.order-t.order}var t=[];this.h.sort(e),this.g.sort(e);for(var n,i,r=we(this.h),a=r.next();!a.done;a=r.next())(a=function(e,t){var n=t.type;{var i;16==(112&t.hb)&&(i=t.hb>>3&1,0===n?e.s=i:e.u=i)}if(i="CC"+(1+(n<<1|(n?e.u:e.s))),n=e.m.get(i),255===t.hb&&255===t.Gb||!t.hb&&!t.Gb||!gd(t.hb)||!gd(t.Gb))return 45<=++e.l&&pd(e),null;if(e.l=0,t.hb&=127,t.Gb&=127,!t.hb&&!t.Gb)return null;if(e.C.add(i),e=null,16==(112&t.hb))e:{if(i=t.hb,e=t.Gb,n.m===(i<<8|e))n.m=null;else if(n.m=i<<8|e,16==(240&i)&&64==(192&e)){t=[11,11,1,2,3,4,12,13,14,15,5,6,7,8,9,10][(7&i)<<1|e>>5&1];var r=(30&e)>>1,a=!(i="white");r<7?i=jh[r]:7===r&&(a=!0),e=1==(1&e),n.h!==Uh&&(r=n.g,n.h===_h&&t!==r.g&&(n=1+t-r.h,yh(r,n,1+r.g-r.h,r.h),bh(r,0,n-1),bh(r,t+1,15-t)),r.g=t,r.m=e,r.j=a,r.l=i,r.s="black")}else if(17==(247&i)&&32==(240&e))n.g.m=!1,n.g.j=!1,n.g.l="white",vh(n.g,wh,32),i=!1,"white_italics"===(t=jh[(14&e)>>1])&&(t="white",i=!0),n.g.m=1==(1&e),n.g.j=i,n.g.l=t;else if(16==(247&i)&&32==(240&e)||23==(247&i)&&45==(255&e))t="black",0==(7&i)&&(t=Oh[(14&e)>>1]),n.g.s=t;else if(17==(247&i)&&48==(240&e))vh(n.g,Th,e);else if(18==(246&i)&&32==(224&e))vh(n.g,1&i?Eh:Ah,e);else if(20==(246&i)&&32==(240&e)){switch(e=t.pts,i=null,t.Gb){case 32:Rh(n);break;case 33:(n=n.g).i[n.g].pop();break;case 37:i=Lh(n,2,e);break;case 38:i=Lh(n,3,e);break;case 39:i=Lh(n,4,e);break;case 40:vh(n.g,wh,32);break;case 41:n.h=2,n.g=n.i,n.g.h=0,n.l=e;break;case 42:mh(n.s),Nh(n);break;case 43:Nh(n);break;case 44:t=n.i,i=null,n.h!==Uh&&(i=gh(t,n.l,e)),bh(t,0,15);break;case 45:t=n.g,n.h!==_h?i=null:(i=gh(t,n.l,e),a=t.g-t.h+1,yh(t,a-1,a,t.h),bh(t,0,a-1),bh(t,t.g,15-t.g),n.l=e);break;case 46:bh(n.j,0,15);break;case 47:t=null,n.h!==Uh&&(t=gh(n.i,n.l,e)),i=n.j,n.j=n.i,n.i=i,Rh(n),n.l=e,i=t}e=i;break e}e=null}else i=t.Gb,vh(n.g,wh,t.hb),vh(n.g,wh,i);return e}(this,a.value))&&t.push(a);for(r=we(this.g),a=r.next();!a.done;a=r.next())n=this.i,3===(i=a.value).type?(n.g=2*(63&i.value)-1,n.h=[]):n.h&&(0>5,a=31&i;if(0!=(r=7===r&&0!=a?63&ad(t).value:r)){e.C.add("svc"+r),e.j.has(r)||e.j.set(r,new od(r));for(var o=e.j.get(r),s=t.Ha();t.Ha()-s=p.s){f=p;for(var g=0,m=1;m<16;m++,g++)f.i[g]=f.i[m];for(m=0;m<1;m++,g++)f.i[g]=Gh()}else p.h++;p.g=0;break;case 14:p.isVisible()&&(r=zh(p,f,o.i)),p.i[p.h]=Gh(),p.g=0;break;case 12:p.isVisible()&&(r=zh(p,f,o.i)),Fh(p),(f=p).h=0,f.g=0}var v=r}else v=null}else v=128<=h&&h<=159?function(e,t,n,i){if(128<=n&&n<=135)e.h[i=7&n]&&(e.g=e.h[i]);else{if(136===n){n=ad(t).value,t=null;for(var r=(n=we(sd(e,n))).next();!r.done;r=n.next())(r=e.h[r.value]).isVisible()&&(t=zh(r,i,e.i)),Fh(r);return t}if(137===n)for(n=(t=we(sd(e,t=ad(t).value))).next();!n.done;n=t.next())(n=e.h[n.value]).isVisible()||(n.j=i),n.l=!0;else{if(138===n){for(n=ad(t).value,t=null,r=(n=we(sd(e,n))).next();!r.done;r=n.next())(r=e.h[r.value]).isVisible()&&(t=zh(r,i,e.i)),r.l=!1;return t}if(139===n){for(n=ad(t).value,t=null,r=(n=we(sd(e,n))).next();!r.done;r=n.next())(r=e.h[r.value]).isVisible()?t=zh(r,i,e.i):r.j=i,r.l=!r.l;return t}if(140===n)return ud(e,t=ad(t).value,i);if(143===n)return i=ud(e,255,i),ld(e),i;var a,o,s,u;144===n?(t.skip(1),i=ad(t).value,e.g&&(e.g.C=0<(128&i),e.g.G=0<(64&i))):145===n?(i=ad(t).value,n=ad(t).value,t.skip(1),e.g&&(t=cd((48&n)>>4,(12&n)>>2,3&n),e.g.D=cd((48&i)>>4,(12&i)>>2,3&i),e.g.u=t)):146===n?(i=ad(t).value,t=ad(t).value,e.g&&((e=e.g).h=15&i,e.g=63&t)):151===n?(t.skip(1),t.skip(1),i=ad(t).value,t.skip(1),e.g&&(e.g.H=3&i)):152<=n&&n<=159&&((r=null!==e.h[n=(15&n)-8])||((a=new Bh(n,e.i)).j=i,e.h[n]=a),i=ad(t).value,a=ad(t).value,o=ad(t).value,s=ad(t).value,u=ad(t).value,t=ad(t).value,r&&0==(7&t)||((t=e.h[n]).h=0,t.g=0,t.G=!1,t.C=!1,t.D="white",t.u="black"),(t=e.h[n]).l=0<(32&i),t.M=127&a,t.J=o,t.I=(240&s)>>4,t.L=0<(128&a),t.s=1+(15&s),t.m=1+(63&u),e.g=e.h[n])}}return null}(o,r,h,d):(4096<=h&&h<=4127?8<=(f=255&h)&&f<=15?r.skip(1):16<=f&&f<=23?r.skip(2):24<=f&&f<=31&&r.skip(3):4224<=h&&h<=4255?128<=(f=255&h)&&f<=135?r.skip(4):136<=f&&f<=143&&r.skip(5):32<=h&&h<=127?(r=h,o.g&&Vh(o.g,127===r?"♪":String.fromCharCode(r))):160<=h&&h<=255?o.g&&Vh(o.g,String.fromCharCode(h)):4128<=h&&h<=4223?(r=255&h,o.g&&(hd.has(r)?(l=hd.get(r),Vh(o.g,l)):Vh(o.g,"_"))):4256<=h&&h<=4351&&o.g&&Vh(o.g,160!=(255&h)?"_":"[CC]"),null);(r=v)&&n.push(r)}}}}catch(e){if(!(e instanceof ke&&3e3===e.code))throw e;Y("CEA708_INVALID_DATA","Buffer read out of bounds / invalid CEA-708 Data.")}return n}(this,a.value),t.push.apply(t,le(a));return this.i.i=[],this.h=[],this.g=[],t},fd.prototype.getStreams=function(){return Array.from(this.C)},i("shaka.cea.CeaDecoder",fd),St=function(){return new fd},vd.prototype.init=function(e){function t(e){(e=e.name)in Td&&(n.g=Td[e])}var n=this,i=[],r=[];if((new yr).box("moov",D).box("mvex",D).W("trex",function(e){var t=e.reader;t.skip(4),t.skip(4),e=t.O(),t=t.O(),n.h=e,n.i=t}).box("trak",D).W("tkhd",function(e){e=Ja(e.reader,e.version),i.push(e.trackId)}).box("mdia",D).W("mdhd",function(e){e=qa(e.reader,e.version),r.push(e.timescale)}).box("minf",D).box("stbl",D).W("stsd",br).box("avc1",t).box("avc3",t).box("hev1",t).box("hvc1",t).box("dvh1",t).box("dvhe",t).box("encv",wr).box("sinf",D).box("frma",function(e){(e=$a(e.reader).wa)in Td&&(n.g=Td[e])}).parse(e,!0),!i.length||!r.length||i.length!=r.length)throw new ke(2,2,2010);this.g==yd&&X("Unable to determine bitstream format for CEA parsing!"),i.forEach(function(e,t){n.j.set(e,r[t])})},vd.prototype.parse=function(e){var g=this;if(this.g==yd)return[];var m=[],v=this.h,y=this.i,b=0,w=[],T=null,A=9e4;return(new yr).box("moof",function(e){b=e.start,w=[],D(e)}).box("traf",D).W("trun",function(e){e=Ya(e.reader,e.version,e.flags),w.push(e)}).W("tfhd",function(e){e=Xa(e.reader,e.flags),v=e.Og||g.h,y=e.Qh||g.i,e=e.trackId,g.j.has(e)&&(A=g.j.get(e))}).W("tfdt",function(e){T=Wa(e.reader,e.version).baseMediaDecodeTime}).box("mdat",function(e){if(null===T)throw X("Unable to find base media decode time for CEA captions!"),new ke(2,2,2010);var t=g,n=e.reader,i=T,r=A,a=v,o=y,s=b-e.start-8,u=w,l=m,c=0,h=o,d=u.map(function(e){return e.lh});for((d=[].concat.apply([],le(d))).length&&(h=d[0].sampleSize||o),n.skip(s+u[0].Ph);n.xa();){s=n.O();var f=n.ra(),p=null;switch(p=!1,u=1,t.g){case bd:p=6==(p=31&f);break;case wd:u=2,n.skip(1),p=39==(p=f>>1&63)||40==p;break;default:return}if(p)for(f=0,ci.byteLength){i=[];break e}var a=ne(i,e,r);n.push({type:t,value:a}),e+=r}i=n}return i}(e=Lr(e.textContent)).filter(function(e){return e.type===xd})[0]))return"";if(e=Zr(e=cr(e.value,!0),"WRMHEADER")){for(var n=e,i=(n=we(n.getElementsByTagName("DATA"))).next();!i.done;i=n.next())for(var r=(i=we(i.value.childNodes)).next();!r.done;r=i.next())if((r=r.value)instanceof Element&&"LA_URL"==r.tagName)return r.textContent;return""}return""}Et["video/mp4"]=function(){return new vd},Ad.prototype.init=function(){},Ad.prototype.parse=function(e){var t=[];if(!uo(e=ne(e)))return t;var n=(e=(new oo).parse(e)).qd(),i=e.ke();switch(e=[],n.video){case"avc":e.push(6);break;case"hvc":e.push(39),e.push(40)}if(!e.length)return t;for(i=(n=we(i)).next();!i.done;i=n.next())if(i=i.value,e.includes(i.type)&&null!=i.time)for(var r=we(md(i.data)),a=r.next();!a.done;a=r.next())t.push({packet:a.value,pts:i.time});return t},i("shaka.cea.TsCeaParser",Ad),Et["video/mp2t"]=function(){return new Ad};var xd=1,Id=(new Map).set("com.widevine.alpha",function(e){var t=Or(e.node,"https://dashif.org/CPS","Laurl");return t&&t.textContent?t.textContent:(e=Or(e.node,"urn:microsoft","laurl"))&&e.getAttribute("licenseUrl")||""}).set("com.microsoft.playready",Sd).set("com.microsoft.playready.recommendation",Sd).set("com.microsoft.playready.software",Sd).set("com.microsoft.playready.hardware",Sd).set("org.w3.clearkey",function(e){var t=Or(e.node,"https://dashif.org/CPS","Laurl");return t&&t.textContent?t.textContent:(e=Or(e.node,"http://dashif.org/guidelines/clearKey","Laurl"))&&"EME-1.0"===e.getAttribute("Lic_type")&&e.textContent?e.textContent:""});function kd(e,t,n,i,r,a){var o={RepresentationID:t,Number:n,SubNumber:i,Bandwidth:r,Time:a};return e.replace(/\$(RepresentationID|Number|SubNumber|Bandwidth|Time)?(?:%0([0-9]+)([diouxX]))?\$/g,function(e,t,n,i){if("$$"==e)return"$";var r=o[t];if(null==r)return e;switch("RepresentationID"==t&&n&&(n=void 0),"Time"==t&&"bigint"!=typeof r&&(.2<=Math.abs(r-Math.round(r))&&X("Calculated $Time$ values must be close to integers"),r=Math.round(r)),i){case void 0:case"d":case"i":case"u":e=r.toString();break;case"o":e=r.toString(8);break;case"x":e=r.toString(16);break;case"X":e=r.toString(16).toUpperCase();break;default:e=r.toString()}return n=H.parseInt(n,10)||1,Array(Math.max(0,n-e.length)+1).join("0")+e})}function Cd(e,t){var n=1,i=((r=Ld(e,t,"timescale"))&&(n=qr(r)||1),Ld(e,t,"duration")),r=qr(i||""),a=((r="image"==e.P.contentType?Jr(i||""):r)&&(r/=n),Ld(e,t,"startNumber")),i=Number(Ld(e,t,"presentationTimeOffset"))||0,o=Yr(a||""),s=(null!=a&&null!=o||(o=1),Rd(e,t,"SegmentTimeline"));if(t=null,s){t=n,e=e.ma.duration||1/0;for(var a=o,s=jr(s,"S"),u=[],l=-i,c=0;c>>31,p=(d&=2147483647,o.reader.O());if(o.reader.skip(4),1==f)throw new ke(2,3,3006);s.push(new P(l/u+n,(l+p)/u+n,function(){return a},e,e+d-1,t,n,i,r)),l+=p,e+=d}return o.parser.stop(),s}(t,i,r,a,o,n,e)});if(e&&u.parse(e),s)return s;throw new ke(2,3,3004)}function Dd(e){this.h=bt(e),this.g=new gr(this.h,0)}function _d(e){var t=Ud(e);if(7Number.MAX_SAFE_INTEGER&&(e=BigInt(n)*BigInt(g)),e=kd(m,y,t,null,v,e),Ge(b(),[e])},0,null,a,w,h,l(),[],"",null,null,Da,o)).h=i,e}function u(){var e=[Math.max(c.xb(),h),Math.min(c.Wb(),l())].map(function(e){return e-h});return[Math.ceil(e[0]/f),Math.ceil(e[1]/f)-1].map(function(e){return e+p})}function l(){var e=null!=i&&n[i]||d;return e?h+e:1/0}var c=e.presentationTimeline,h=e.ma.start,i=e.Ja.id,d=e.ma.duration,f=r.Ma,p=r.Ld,g=r.timescale,m=r.Qc,v=e.bandwidth||null,y=e.P.id,b=e.P.wb,w=h-r.Ob,T=u();e=e.Tb?Math.max(T[0],T[1]-t+1):T[0],T=T[1],t=[];for(var A=e;A<=T;++A){var E=s(A);t.push(E)}var S,x=new us(t);return t=c.Wb()l()&&!n.length?null:n})),Promise.resolve(x)}};var s=null,u=(i=null,e.Ja.id&&e.P.id&&(i=n[i=e.Ja.id+","+e.P.id])&&(s=i.segmentIndex),e.ma.start),l=e.ma.duration?u+e.ma.duration:1/0,c=!(e.Tb&&e.ma.Lf);return s?(Zd(n=s,L,u,l,c,M),n.vb(e.presentationTimeline.xb())):s=new $d(L,e.P.id,e.bandwidth,e.P.wb,u,l,M,c,C,e.P.hg),L.timeline&&"image"!==e.Fa.contentType&&e.presentationTimeline.hh(L.timeline,u),i&&e.Tb&&(i.segmentIndex=s),{Ic:function(){return s instanceof $d&&0==s.pc()&&Zd(s,L,u,l,c,M),Promise.resolve(s)}}}function Qd(e){return e.Kd}function $d(e,t,n,i,r,a,o,s,u,l){us.call(this,[]),this.h=e,this.H=t,this.D=n,this.G=i,this.i=r,this.m=a,this.u=o,this.C=u,this.I=l,s&&ef(this)}function Zd(e,t,n,i,r,a){var o;e.u=a,e.h?(n=e.h.timeline,e.h.Qc=t.Qc,o=n[n.length-1],0<(t=t.timeline.filter(function(e){return e.start>=o.end})).length&&e.h.timeline.push.apply(e.h.timeline,le(t)),e.m!==i&&(e.m=i)):(e.h=t,e.i=n,e.m=i),r&&ef(e)}function ef(e){if(!e.s){for(var t=e.h.timeline;t.length&&t[t.length-1].start>=e.m;)t.pop();e.vb(e.i),0!==t.length&&1/0!==e.m&&(t[t.length-1].end=e.m-e.i)}}function tf(e,t,n,i,r,a,o){return e=kd(e,t,n,a,i||null,r),Ge(o(),[e]).map(function(e){return e.toString()})}function nf(e){this.s=null,this.C=e,this.I=new Ki,this.j=[],this.h=null,this.m=[],this.D=null,this.H=[],this.G=300,this.l=new Map,this.i=new Map,this.g=null,this.u="UNKNOWN"}function rf(a,o){var s,u;return Ie(function(e){if(1==e.g)return s=Ge(a.j,[function(e,t){if(!e.m.length)return t;t=new ge(t);var n=e.D||e.m[0],i=Math.round(e.C.getBandwidthEstimate()),r=t.g;return"DASH"==e.u?(r.add("_DASH_pathway",n),r.add("_DASH_throughput",String(i))):"HLS"==e.u&&(r.add("_HLS_pathway",n),r.add("_HLS_throughput",String(i))),Be(r)&&ve(t,r),t.toString()}(a,o)]),s=Wi(s,a.s.retryParameters),s=a.C.networkingEngine.request(8,s),zi(a.I,s),Ee(e,2),Te(e,s.promise,4);if(2!=e.g){s=e.h,u=lr(s.data),u=JSON.parse(u);if(1==u.VERSION){var t=a;var n=u;var i=s.uri;null!=t.g&&(t.g.stop(),t.g=null);var r=n["RELOAD-URI"]||i;t.g=new I(function(){rf(t,r)}),(i=n.TTL)&&(t.G=i);t.g.S(t.G),t.m=n["PATHWAY-PRIORITY"]||[],t.H=n["PATHWAY-CLONES"]||[]}return Se(e,0)}if((u=xe(e))&&7001==u.code)return e.return();null!=a.g&&(a.g.stop(),a.g=null),a.g=new I(function(){rf(a,o)}),a.g.S(a.G),Ae(e)})}function af(e,t,n,i){var r=e.l.get(t);(r=r||new Map).set(n,i),e.l.set(t,r)}function of(i,e,t){t=void 0!==t&&t,e=i.l.get(e)||new Map;for(var n,r=[],a={},o=we(i.m),s=o.next();!s.done;a={ic:a.ic},s=o.next())a.ic=s.value,(s=e.get(a.ic))?r.push({ag:a.ic,location:s}):(s=i.H.find(function(t){return function(e){return e.Kj==t.ic}}(a)))&&(n=e.get(s["BASE-ID"]))&&(s["URI-REPLACEMENT"].Dh?(ue(n=new ge(n),s["URI-REPLACEMENT"].Dh),r.push({ag:a.ic,location:n.toString()})):r.push({ag:a.ic,location:n}));for(a=Date.now(),s=(o=we(i.i.keys())).next();!s.done;s=o.next())s=s.value,(n=i.i.get(s))i.length||!(r.lengthi.length)return!0;if(r.length=t&&(this.g=this.g.slice(t)),this.j+=t,0===this.pc()&&this.release())}},t.find=function(e){if(this.h&&this.h.timeline&&this.h.timeline.length&&ethis.m)return null;for(var n=t.length-1,i=0;i=this.pc()||!this.h)return null;if(!(o=this.g[e])){for(var n=this.h.Qc,i=this.h.timeline[e],r=i.kj,a=this.h.yg+i.zg,o=this.i-this.h.Ob,s=[],u=(i.end-i.start)/i.yb,l={},c=0;ce.C)&&(e.C=h),o=function(S,x,e,t){x.Ja=zf(S,t.node,null,e),x.ma=t,x.Ja.Fc=x.Fc,x.Ja.id||(x.Ja.id="__shaka_period_"+t.start);var n=jr(t.node,"EventStream");e=x.presentationTimeline.xb();for(var i=(n=we(n)).next();!i.done;i=n.next())!function(e,t,n,i,r){for(var a=i.getAttribute("schemeIdUri")||"",o=i.getAttribute("value")||"",s=W(i,"timescale",Yr)||1,u=(i=we(jr(i,"Event"))).next();!u.done;u=i.next()){var l=W(u=u.value,"presentationTime",Yr)||0,c=W(u,"duration",Yr)||0;c=(l=l/s+t)+c/s,null!=n&&(l=Math.min(l,t+n),c=Math.min(c,t+n)),c>=1;return e;case"urn:mpeg:mpegB:cicp:ChannelConfiguration":if(t=[0,1,2,3,4,5,6,8,2,3,4,7,8,24,8,12,10,12,14,12,14],(n=parseInt(n,10))&&0>3)&&e.xa()?32+((7&i)<<3)+((224&e.ra())>>5):t))),{wa:n}}(e.reader),r.push(e.wa),a=!0}).box("ac-3",i).box("ec-3",i).box("opus",i).box("Opus",i).box("fLaC",i).box("avc1",function(e){e=Qa(e.reader,e.name),r.push(e.wa),o=!0}).box("avc3",function(e){e=Qa(e.reader,e.name),r.push(e.wa),o=!0}).box("hev1",i).box("hvc1",i).box("dvh1",i).box("dvhe",i).box("vp09",i).box("av01",i).box("enca",wr).box("encv",wr).box("sinf",D).box("frma",function(e){n(e=$a(e.reader).wa)}).parse(e||t,!0),!r.length)return null;var d=a&&!o,f=new Map;if(o){var p=new At("video/mp4");for(e&&p.init(e),p.i(t),t=(e=we(p.j())).next();!t.done;t=e.next())t=t.value,f.set(t,t);p.h()}return{type:d?"audio":"video",mimeType:d?"audio/mp4":"video/mp4",codecs:function(e){for(var t=new Set,n=[],i=(e=we(e)).next();!i.done;i=e.next()){var r=cn(i=i.value);t.has(r)||(n.push(i),t.add(r))}return n}(r).join(", "),language:s,height:u,width:l,channelCount:c,sampleRate:h,closedCaptions:f}}function Sp(){var e=this;this.g=this.i=null,this.C=1,this.s=new Map,this.J=new Map,this.L=new Map,this.L.set("video",new Map),this.L.set("audio",new Map),this.L.set(he,new Map),this.L.set("image",new Map),this.va=new Set,this.h=new Map,this.l=null,this.Z="",this.sa=new pp,this.K=-1,this.U=1/0,this.$=this.Va=!1,this.u=new I(function(){var t,n,i;t=e,Ie(function(e){switch(e.g){case 1:return t.i?(Ee(e,2),n=Date.now(),Te(e,t.update(),4)):e.return();case 4:i=Date.now(),Zp(t)&&(i=(i-n)/1e3,t.Oa.sample(1,i),i=t.m,i=Math.max(0,i-st(t.Oa)),t.u.S(i)),Se(e,3);break;case 2:if(i=xe(e),!t.i)return e.return();if(t.g.raiseFatalErrorOnManifestUpdateRequestFailure)return t.i.onError(i),e.return();i.severity=1,t.i.onError(i),t.u.S(.1);case 3:if(!t.i)return e.return();t.i.onManifestUpdated(),Ae(e)}})}),this.aa=ag,this.G=null,this.ua=0,this.m=1/0,this.ha=this.Aa=this.M=0,this.N=new Ki,this.H=new Map,this.I=new Map,this.V=new Map,this.Ua=this.D=!1,this.Oa=new ot(5),this.j=null}function xp(e,t){return Zp(e)?e.L.get(t.type):t.xe}function Ip(e,t,n){t.wc+=n,t.Lb+=n;for(var i=we(e=xp(e,t)),r=i.next();!r.done;r=i.next()){var r=(a=we(r.value)).next().value,a=a.next().value;e.set(r,a+n)}t.ba()}function kp(u,l,c){var h,d,f,p,g,m,v,y,b;return Ie(function(e){switch(e.g){case 1:if(h=Ap(u.g.hls.mediaPlaylistFullMimeType),!l.segments.length)return e.return(h);if(m=Math.trunc((l.segments.length-1)/2),m=l.segments[m],d=up(c(),l.segments[0].h),f=d[0],f=new ge(f),f=f.Wa.split(".").pop(),p=ng[f])return e.return(Ap(p));if(p=Qi,g=null,m=Xp(u,l,m.g,c),u.V.clear(),m)return m=Wi(m.ba(),u.g.retryParameters),Te(e,tg(u,m,p,{type:0}),3);e.F(2);break;case 3:m=e.h,g=m.data;case 2:return v=Wi(d,u.g.retryParameters),Te(e,tg(u,v,p,{type:1}),4);case 4:if(v=e.h,(y=v.headers["content-type"])&&(y=y.split(";")[0].toLowerCase()),"ts"==f||"video/mp2t"==y){var t=ne(o=v.data),n=(t=(new oo).parse(t)).qd(),i=(t=t.Kf(),[]),r=!1,a=!1;switch(n.audio){case"aac":i.push("mp4a.40.2"),r=!0;break;case"mp3":i.push("mp4a.40.34"),r=!0;break;case"ac3":i.push("ac-3"),r=!0;break;case"ec3":i.push("ec-3"),r=!0}switch(n.video){case"avc":t.wa?i.push(t.wa):i.push("avc1.42E01E"),a=!0;break;case"hvc":t.wa?i.push(t.wa):i.push("hvc1.1.6.L93.90"),a=!0}if(i.length){if(n=r&&!a,r=new Map,a){(a=new At("video/mp2t")).i(o);for(var o,s=(o=we(a.j())).next();!s.done;s=o.next())s=s.value,r.set(s,s);a.h()}t={type:n?"audio":"video",mimeType:"video/mp2t",codecs:i.join(", "),language:null,height:t.height,width:t.width,channelCount:null,sampleRate:null,closedCaptions:r}}else t=null;if(b=t)return e.return(b)}else if(("mp4"==f||"cmfv"==f||"m4s"==f||"video/mp4"==y||"audio/mp4"==y||"video/iso.segment"==y)&&(b=Ep(g,v.data)))return e.return(b);return e.return(h)}})}function Cp(e){if(Zp(e)){if(e.aa==sg&&(t=function(e){for(var t=1/0,n=1/0,i=(e=we(e.h.values())).next();!i.done;i=e.next())(i=i.value).stream.segmentIndex&&"text"!=i.stream.type&&(t=Math.min(t,i.Lb),n=Math.min(n,i.wc));return t-n}(e),e.g.hls.useSafariBehaviorForLive&&(t=e.l.s),isNaN(e.g.availabilityWindowOverride)||(t=e.g.availabilityWindowOverride),e.l.Le(t)),!e.l.m)for(var t,n=(t=we(t=Array.from(e.h.values()).filter(function(e){return e.stream.segmentIndex}))).next();!n.done;n=t.next())("audio"==(n=n.value).type||"video"==n.type)&&(n=n.stream.segmentIndex.get(0))&&n.oa&&e.l.og(n.oa)}else e.l.eb(Up(e));e.l.ue()}function Mp(e,t,n){n=new ge(n).g;for(var i=new Map,r=(t=we(t)).next();!r.done;r=t.next()){var a=pe(s=r.value,"NAME"),o=pe(s,"VALUE"),r=pe(s,"QUERYPARAM"),s=pe(s,"IMPORT");a&&o&&(i.has(a)||i.set(a,o)),r&&(a=n.get(r)[0])&&!i.has(a)&&i.set(r,a),s&&(r=e.s.get(s))&&i.set(s,r)}return i}function Lp(e,t){var n=pe(t,"CODECS")||"";e.$=0i.byteLength){i=[];break e}var a=ne(i,e,r);n.push({type:t,value:a}),e+=r}i=n}return i}(e=Lr(e.textContent)).filter(function(e){return e.type===hg})[0])&&(e=Zr(e=cr(e.value,!0),"WRMHEADER"))?e:null}Ca["application/x-mpegurl"]=function(){return new Sp},Ca["application/vnd.apple.mpegurl"]=function(){return new Sp};var hg=1,dg=(new Map).set("com.microsoft.playready",lg).set("com.microsoft.playready.recommendation",lg).set("com.microsoft.playready.software",lg).set("com.microsoft.playready.hardware",lg);function fg(e){var t,n,i;Tg||(Tg=!0,t=new Uint8Array([105,115,111,109]),n=new Uint8Array([97,118,99,49]),i=new Uint8Array([0,0,0,1]),Pg=b("ftyp",t,i,t,n),t=b("dref",Dg),_g=b("dinf",t)),this.g=e}function pg(e){for(var t=[],n=we(e.g),i=n.next();!i.done;i=n.next()){var r=t,a=r.push,o=i.value,i=b,s=o.id+1,u=o.stream.width||0,l=o.stream.height||0,c=("audio"==o.type&&(l=u=0),o.duration*o.timescale),h=Math.floor(c/(Ag+1)),c=Math.floor(c%(Ag+1));switch(s=b("tkhd",s=new Uint8Array([1,0,0,7,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(le(bg(s,4)),[0,0,0,0],le(bg(h,4)),le(bg(c,4)),[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0],le(bg(u,2)),[0,0],le(bg(l,2)),[0,0]))),u=b,h=o.duration*o.timescale,l=Math.floor(h/(Ag+1)),h=Math.floor(h%(Ag+1)),c=(c=o.stream.language).charCodeAt(0)-96<<10|c.charCodeAt(1)-96<<5|c.charCodeAt(2)-96,l=b("mdhd",l=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(le(bg(o.timescale,4)),le(bg(l,4)),le(bg(h,4)),le(bg(c,2)),[0,0]))),h=o,c=new Uint8Array([]),h.type){case"video":c=Sg;break;case"audio":c=xg}h=b("hdlr",c);e:{switch(o.type){case"video":o=b("minf",b("vmhd",Lg),_g,gg(o));break e;case"audio":o=b("minf",b("smhd",Rg),_g,gg(o));break e}o=new Uint8Array([])}i=i("trak",s,o=u("mdia",l,h,o)),a.call(r,i)}for(t=Pr.apply(kr,le(t)),n=b,i=(a=e.g[0]).duration*a.timescale,r=Math.floor(i/(Ag+1)),i=Math.floor(i%(Ag+1)),r=b("mvhd",r=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(le(bg(a.timescale,4)),le(bg(r,4)),le(bg(i,4)),[0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]))),i=[],u=(e=we(e.g)).next();!u.done;u=e.next())s=(o=i).push,u=b("trex",u=new Uint8Array([0,0,0,0].concat(le(bg(u.value.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1]))),s.call(o,u);if(e=b("mvex",e=Pr.apply(kr,le(i))),i=[],a.encrypted){for(o=(a=we(a.stream.drmInfos)).next();!o.done;o=a.next())if((o=o.value).initData)for(s=(o=we(o.initData)).next();!s.done;s=o.next())i.push(s.value.initData);a=Pr.apply(kr,le(i))}else a=new Uint8Array([]);return e=n("moov",r,t,e,a),(t=new Uint8Array(Pg.byteLength+e.byteLength)).set(Pg),t.set(e,Pg.byteLength),t}function gg(e){var t=b,n=new Uint8Array([]);switch(e.type){case"video":if(e.codecs.includes("avc1")){var n=e.stream.width||0,i=e.stream.height||0;if(0>8,a[h++]=255&o[u].length,a.set(o[u],h),h+=o[u].length;for(a[h++]=s.length,o=0;o>8,a[h++]=255&s[o].length,a.set(s[o],h),h+=s[o].length;r=r("avcC",a)}n=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0].concat(le(bg(n,2)),le(bg(i,2)),[0,72,0,0,0,72,0,0,0,0,0,0,0,1,19,118,105,100,101,111,106,115,45,99,111,110,116,114,105,98,45,104,108,115,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17])),i="avc1",s=new Uint8Array([]),e.encrypted&&(s=vg(e),i="encv"),n=b(i,n,r,s)}else e.codecs.includes("hvc1")&&(i=e.stream.width||0,r=e.stream.height||0,n=new Uint8Array([]),0>>1,s<<7|r<<3,6,1,2])))),"mp4a"),new Uint8Array([])),e.encrypted&&(r=vg(e),i="enca"),b(i,mg(e),n,r))}return t("stbl",e=b("stsd",Ng,n),b("stts",Ig),b("stsc",kg),b("stsz",Mg),b("stco",Cg))}function mg(e){return new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,e.stream.channelsCount||2,0,16,0,0,0,0].concat(le(bg(e.stream.audioSamplingRate||44100,2)),[0,0]))}function vg(e){for(var t=b,n=e.codecs.substring(0,e.codecs.indexOf(".")),i=0,r=0;r>8*t&255);return n}function wg(e){for(var t=new Uint8Array(e.length/2),n=0;n>24&255,r[1]=i>>16&255,r[2]=i>>8&255,r[3]=255&i,r.set(n,4),n=0,i=8;n>1,n[1]=i<<7|t<<3|e>>1,n[2]=e<<7|8,n[3]=0,(t=new Uint16Array(2))[0]=(n[0]<<8)+n[1],t[1]=(n[2]<<8)+n[3],t[0].toString(16)+t[1].toString(16)):((n=new Uint8Array(2))[0]=16|i>>1,n[1]=i<<7|t<<3,(t=new Uint16Array(1))[0]=(n[0]<<8)+n[1],t[0].toString(16))}(e,o,r,m),m.mssPrivateData.codecPrivateData=e,o){case"audio":if(!e)return X("Quality unsupported without CodecPrivateData",o),null;m.type="audio",m.mimeType="mss/audio/mp4",m.codecs=function(e,t){var n="AACH"===e?5:0;return t?0===n&&(n=(248&parseInt(t.substr(0,2),16))>>3):n="AACH"===e?5:2,"mp4a.40."+n}(r,e);break;case"video":if(!e)return X("Quality unsupported without CodecPrivateData",o),null;m.type="video",m.mimeType="mss/video/mp4",m.codecs=function(e){var t=/00000001[0-9]7/.exec(e);return t.length&&e?"avc1."+e.substr(e.indexOf(t[0])+10,6):""}(e);break;case"text":m.type=he,m.mimeType="application/mp4","TTML"!==r&&"DFXP"!==r||(m.codecs="stpp")}return m.createSegmentIndex=function(){return m.segmentIndex||(t.m.has(m.id)?e=t.m.get(m.id):(e=[],"video"==m.type&&(e=m.mssPrivateData.codecPrivateData.split("00000001").slice(1)),e=pg(new fg([e={id:m.id,type:m.type,codecs:m.codecs,encrypted:m.encrypted,timescale:m.mssPrivateData.timescale,duration:m.mssPrivateData.duration,gb:e,qa:new Uint8Array([]),Da:new Uint8Array([]),data:null,stream:m}])),t.m.set(m.id,e)),e=function(t,e,n,i,r){for(var a=i.getAttribute("Url").replace("{bitrate}",String(n.bandwidth)),o=(i=[],{}),s=(r=we(r)).next();!s.done;o={ed:o.ed},s=r.next())o.ed=s.value,i.push(new P(o.ed.start,o.ed.end,function(e){return function(){return Ge(t.l,[a.replace("{start time}",String(e.ed.zg))])}}(o),0,null,e,0,0,n.mssPrivateData.duration));return i}(t,new Na(function(){return[]},0,null,null,void 0,e),m,n,i),m.segmentIndex=new us(e)),Promise.resolve();var e},m.closeSegmentIndex=function(){m.segmentIndex&&(m.segmentIndex.release(),m.segmentIndex=null)},m}(b,s,c.value,u,i,t))&&("audio"!=c.type||b.g.disableAudio?"video"!=c.type||b.g.disableVideo?c.type!=he||b.g.disableText||a.push(c):r.push(c):o.push(c))}for(n=[],i=(o=we(0n,o&&s)return Te(e,a.updateManifestExpiration(i.key(),n),3);e.F(3);break;case 3:return Ce(e),Te(e,r.destroy(),10);case 10:Me(e,0);break;case 2:xe(e),e.F(3)}})},t.onInitialVariantChosen=function(){},t.banLocation=function(){},Ca["application/x-offline-manifest"]=function(){return new Rm},i("shaka.offline.OfflineScheme",Nm),Xi("offline",Nm.plugin=Pm),(t=Bm.prototype).destroy=function(){return this.l.destroy()},t.configure=function(e,t){return 2==arguments.length&&"string"==typeof e&&(e=Mu(e,t)),Bu(this.h,e)},t.getConfiguration=function(){var e=ju();return Bu(e,this.h,ju()),e},t.Vb=function(){return this.g},t.store=function(n,e,i){var ie,re,ae,oe,se,ue,le,ce,he,de,fe,pe,ge,me,ve,ye,be,t,r,a=this,o=this.getConfiguration(),s=new im(this.g);return this.j.push(s),ie=this,re=n,ae=e||{},oe=function(){var t;return Ie(function(e){return 1==e.g?i?e.F(2):Te(e,qs(n,a.g,o.manifest.retryParameters),3):(2!=e.g&&(i=e.h),t=ka(n,i||null),e.return(t()))})},se=o,ue=s,(e=new Oi(e=Ie(function(e){switch(e.g){case 1:return Wm(),ce=le=null,he=new mm,pe=fe=de=null,Ee(e,2,3),Te(e,oe(),5);case 5:return le=e.h,Te(e,(s=ie,Z=re,ee=le,te=se,Ie(function(e){if(1==e.g)return D=null,_=s.g,_={networkingEngine:_,filter:function(){return Promise.resolve()},makeTextStreamsForClosedCaptions:function(){},onTimelineRegionAdded:function(){},onEvent:function(){},onError:function(e){D=e},isLowLatencyMode:function(){return!1},isAutoLowLatencyMode:function(){return!1},enableLowLatencyMode:function(){},updateDuration:function(){},newDrmInfo:function(){},onManifestUpdated:function(){},getBandwidthEstimate:function(){return te.abr.defaultBandwidthEstimate}},ee.configure(te.manifest),Xm(s),Te(e,ee.start(Z,_),2);if(3!=e.g)return ne=e.h,Xm(s),_=Ym(ne),Te(e,Promise.all(Le(_,function(e){return e.createSegmentIndex()})),3);if(Xm(s),D)throw D;return e.return(ne)})),6);case 6:if(ge=e.h,Xm(ie),!ge.presentationTimeline.R()&&!ge.presentationTimeline.uc())return Te(e,(Y=ie,J=ge,Q=function(e){pe=pe||e},$=se,Ie(function(e){return 1==e.g?((o=new na({xc:Y.g,onError:Q,Ee:function(){},onExpirationUpdated:function(){},onEvent:function(){}})).configure($.drm),Te(e,(t=o,n=J.variants,i=$.offline.usePersistentLicense,t.ha=!0,t.C=new Map,t.M=i,ra(t,n)),2)):3!=e.g?Te(e,oa(o),3):e.return(o);var t,n,i})),7);throw new ke(2,9,9005,re);case 7:if(ce=e.h,Xm(ie),pe)throw pe;return Te(e,(u=ge,B=ce,l=se,Ie(function(e){switch(e.g){case 1:return h={width:1/0,height:1/0},o=l.restrictions,s=h,u.variants=u.variants.filter(function(e){return Kn(e,o,s)}),Te(e,Hn(B,u,l.offline.usePersistentLicense),2);case 2:for(c=[],h=l.preferredDecodingAttributes,N=l.preferredVideoCodecs,F=l.preferredAudioCodecs,Vn(u,N,F,h),d=we(u.variants),f=d.next();!f.done;f=d.next())G=f.value,c.push(Qn(G));for(p=we(u.textStreams),g=p.next();!g.done;g=p.next())V=g.value,c.push($n(V));for(m=we(u.imageStreams),I=m.next();!I.done;I=m.next())K=I.value,c.push(Zn(K));return Te(e,l.offline.trackSelectionCallback(c),3);case 3:for(k=e.h,z=u.presentationTimeline.getDuration(),C=0,M=we(k),L=M.next();!L.done;L=M.next())R=L.value,R=R.bandwidth*z/8,C+=R;return Ee(e,4),Te(e,l.offline.downloadSizeCallback(C),6);case 6:if(!e.h)throw new ke(2,9,9014);Se(e,5);break;case 4:if((N=xe(e))instanceof ke)throw N;throw new ke(2,9,9015);case 5:for(H=new Set,X=new Set,W=new Set,q=we(k),L=q.next();!L.done;L=q.next())"variant"==(P=L.value).type&&H.add(P.id),"text"==P.type&&X.add(P.id),"image"==P.type&&W.add(P.id);u.variants=u.variants.filter(function(e){return H.has(e.id)}),u.textStreams=u.textStreams.filter(function(e){return X.has(e.id)}),u.imageStreams=u.imageStreams.filter(function(e){return W.has(e.id)});var t=u,n=(t.variants.map(function(e){return e.video}),new Set(t.variants.map(function(e){return e.audio})));t=t.textStreams;for(var i=we(n),r=i.next();!r.done;r=i.next())for(var a=(r=we(n)).next();!a.done;a=r.next());for(n=we(t),i=n.next();!i.done;i=n.next())for(i=we(t),r=i.next();!r.done;r=i.next());Ae(e)}var o,s})),8);case 8:return Te(e,he.init(),9);case 9:return Xm(ie),Te(e,vm(he),10);case 10:return de=e.h,Xm(ie),ve=function(n,e,t,i,r,a){var o=function(e,t,n){return{offlineUri:null,originalManifestUri:e,duration:t.presentationTimeline.getDuration(),size:0,expiration:1/0,tracks:t=Um(t),appMetadata:n,isIncomplete:!1}}(t,e,i),s=r.offline.progressCallback,u=(function(e,t,n){e.m=t,e.l=n}(a,function(e,t){o.size=t,s(o,e)},function(e,t){u&&r.offline.usePersistentLicense&&l==t&&sa(n,"cenc",e)}),Km(e)&&!zm(e)),l=null;u&&(l=Jm.get(n.g.keySystem));for(var c=new Om,h=we(e.textStreams),d=h.next();!d.done;d=h.next())c.g[d.value.id]=52;for(h=we(e.imageStreams),d=h.next();!d.done;d=h.next())!function(e,t){e.g[t.id]=t.bandwidth||2048}(c,d.value);for(d=we(e.variants),h=d.next();!h.done;h=d.next())!function(e,t){var n,i,r=t.audio,a=t.video;r&&!a&&(e.g[r.id]=r.bandwidth||t.bandwidth),!r&&a&&(e.g[a.id]=a.bandwidth||t.bandwidth),r&&a&&(n=r.bandwidth||393216,(i=a.bandwidth||t.bandwidth-n)<=0&&(i=t.bandwidth),e.g[r.id]=n,e.g[a.id]=i)}(c,h.value);return c=function(e,t,n,i){for(var r=new Map,a=Ym(n),o=new Map,s=(a=we(a)).next();!s.done;s=a.next()){s=s.value;var u=function(r,a,e,o,t,s){var u={id:o.id,originalId:o.originalId,groupId:o.groupId,primary:o.primary,type:o.type,mimeType:o.mimeType,codecs:o.codecs,frameRate:o.frameRate,pixelAspectRatio:o.pixelAspectRatio,hdr:o.hdr,videoLayout:o.videoLayout,kind:o.kind,language:o.language,originalLanguage:o.originalLanguage,label:o.label,width:o.width||null,height:o.height||null,encrypted:o.encrypted,keyIds:o.keyIds,segments:[],variantIds:[],roles:o.roles,forced:o.forced,channelsCount:o.channelsCount,audioSamplingRate:o.audioSamplingRate,spatialAudio:o.spatialAudio,closedCaptions:o.closedCaptions,tilesLayout:o.tilesLayout,external:o.external,fastSwitching:o.fastSwitching},l=t.offline.numberOfParallelDownloads,c=0;return function(e,t,n){if(null!=(t=e.segmentIndex.find(t)))for(var i=e.segmentIndex.get(t);i;)n(i),i=e.segmentIndex.get(++t)}(o,e.presentationTimeline.xb(),function(e){var t,n=em(e),i=void 0;s.has(n)||(t=e.endTime-e.startTime,t=jm(a,o.id)*t,t=nm(r.g,t),s.set(n,new Zg(e,t,c,!1))),e.ka&&(i=em(e.ka),s.has(i)||(t=.5*jm(a,o.id),t=nm(r.g,t),s.set(i,new Zg(e.ka,t,c,!0)))),u.segments.push({pendingInitSegmentRefId:i,initSegmentKey:i?0:null,startTime:e.startTime,endTime:e.endTime,appendWindowStart:e.appendWindowStart,appendWindowEnd:e.appendWindowEnd,timestampOffset:e.timestampOffset,tilesLayout:e.tilesLayout,pendingSegmentRefId:n,dataKey:0}),c=(c+1)%l}),u}(e,t,n,s,i,r);o.set(s.id,u)}for(e=we(n.variants),t=e.next();!t.done;t=e.next())(t=t.value).audio&&o.get(t.audio.id).variantIds.push(t.id),t.video&&o.get(t.video.id).variantIds.push(t.id);return{streams:Array.from(o.values()),vg:Array.from(r.values())}}(a,c,e,r),a=c.streams,c=c.vg,d=n.g,h=r.offline.usePersistentLicense,d&&h&&(d.initData=[]),{Ri:{creationTime:Date.now(),originalManifestUri:t,duration:e.presentationTimeline.getDuration(),size:0,expiration:n.rd(),streams:a,sessionIds:h?la(n):[],drmInfo:d,appMetadata:i,isIncomplete:!0,sequenceMode:e.sequenceMode,type:e.type},vg:c}}(ce,ge,re,ae,se,ue),me=ve.Ri,ve=ve.vg,Te(e,de.Pa.addManifests([me]),11);case 11:if(ye=e.h,Xm(ie),fe=ye[0],Xm(ie),pe)throw pe;return Te(e,(v=ie,t=ve,y=fe,b=me,w=ue,T=se,A=de.Pa,E=ge,U=ce,Ie(function(e){switch(e.g){case 1:if(S={},x=0,i=!(n=function(u,l){var c,h,d,f,p,g,m;return Ie(function(e){if(1==e.g){for(c={},h=we(u),d=h.next();!d.done;c={hc:c.hc},d=h.next())c.hc=d.value,n=c.hc,i=T,f=Ms(n.g.ba(),n.g.fb,n.g.Ka,i.streaming.retryParameters),p=c.hc.i,g=c.hc.h,m=function(r){return function(t){var n,i;return Ie(function(e){if(1==e.g)return Te(e,A.addSegments([{data:t}]),2);n=e.h,Xm(v),i=r.hc.g,i=em(i),S[i]=n[0],x+=t.byteLength,Ae(e)})}}(c),am(w,c.hc.groupId,f,p,g,m);return Te(e,(t=w,Ie(function(e){return 1==e.g?Te(e,Promise.all(t.j.values()),2):e.return(t.g.h)})),2)}var t,n,i;if(!l)return e.F(0);Xm(v);var r=E,a=b,o=U,s=T;if(a.expiration=o.rd(),o=la(o),a.sessionIds=s.offline.usePersistentLicense?o:[],Km(r)&&s.offline.usePersistentLicense&&!o.length)throw new ke(2,9,9007);return Te(e,A.updateManifest(y,b),0)})}),Ee(e,2),Km(E)&&i&&!zm(E))return Te(e,n(t.filter(function(e){return e.h}),!0),5);e.F(4);break;case 5:return Xm(v),t=t.filter(function(e){return!e.h}),r=S,a=x,S={},x=0,Te(e,Vm(A,y,b,r,a,function(){Xm(v)}),6);case 6:Xm(v);case 4:if(i){e.F(7);break}return Te(e,n(t,!1),8);case 8:return Xm(v),r=S,a=x,S={},x=0,Te(e,Vm(A,y,b,r,a,function(){Xm(v)}),9);case 9:Xm(v);case 7:Se(e,0);break;case 2:return O=xe(e),j=Object.values(S),Te(e,A.removeSegments(j,function(){}),10);case 10:throw O}})),12);case 12:return Xm(ie),ye=new Im("manifest",de.path.ob,de.path.Pa,fe),e.return(_m(ye,me));case 3:return Ce(e),Te(e,he.destroy(),13);case 13:if(le)return Te(e,le.stop(),14);e.F(14);break;case 14:if(ce)return Te(e,ce.destroy(),16);e.F(16);break;case 16:Me(e,0);break;case 2:if(be=xe(e),null!=fe)return Te(e,Gm(fe),18);e.F(18);break;case 18:throw pe||be}var v,t,y,b,w,T,A,E,U,S,x,n,i,r,a,O,j,u,B,l,c,h,F,d,f,G,p,g,V,m,I,K,k,z,C,M,L,R,N,H,X,W,q,P,Y,J,Q,$,o,s,Z,ee,te,D,ne,_}),function(){return rm(s)})).finally(function(){It(a.j,s)}),t=this,r=(e=e).promise,t.i.push(r),e.finally(function(){It(t.i,r)})},t.remove=function(e){return qm(this,(o=this,s=e,Ie(function(e){switch(e.g){case 1:if(Wm(),null==(h=km(s))||"manifest"!=h.g)throw new ke(2,9,9004,s);return h=h,d=new mm,k(e,2),Te(e,d.init(),4);case 4:return Te(e,ym(d,h.ob(),h.Pa()),5);case 5:return Te(e,(f=e.h).getManifests([h.key()]),6);case 6:return p=e.h,p=p[0],Te(e,Promise.all([(u=o,l=p,c=d,Ie(function(e){return Te(e,(t=u.g,n=u.h.drm,i=c,r=l,Ie(function(e){return 1==e.g?r.drmInfo?(a=function(e){var t=Array.from(e.g.keys());if(t.length)return e.g.get(t[0]).getEmeSessionCell();throw new ke(2,9,9e3,"No supported storage mechanisms found")}(i),o=r.sessionIds.map(function(e){return{sessionId:e,keySystem:r.drmInfo.keySystem,licenseUri:r.drmInfo.licenseServerUri,serverCertificate:r.drmInfo.serverCertificate,audioCapabilities:Hm(r,!1),videoCapabilities:Hm(r,!0)}}),Te(e,Dm(n,t,o),2)):e.return():3!=e.g?(s=e.h,Te(e,a.remove(s),3)):Te(e,a.add(o.filter(function(e){return!s.includes(e.sessionId)})),0)})),0);var t,n,i,r,a,o,s})),(n=f,i=h,a=function(e){for(var t=new Set,n=(e=we(e.streams)).next();!n.done;n=e.next())for(var i=(n=we(n.value.segments)).next();!i.done;i=n.next())null!=(i=i.value).initSegmentKey&&t.add(i.initSegmentKey),t.add(i.dataKey);return Array.from(t)}(r=p),_m(i,r),Promise.all([n.removeSegments(a,t),n.removeManifests([i.key()],t)]))]),2);case 2:return Ce(e),Te(e,d.destroy(),8);case 8:Me(e,0)}function t(){}var n,i,r,a,u,l,c})));var o,s,h,d,f,p},t.ej=function(){return qm(this,(n=this,Ie(function(e){switch(e.g){case 1:return Wm(),i=n.g,r=n.h.drm,a=new mm,o=!1,k(e,2),Te(e,a.init(),4);case 4:s=[],t=function(e){s.push(e)},a.g.forEach(function(e){t(e.getEmeSessionCell())}),u=we(s),l=u.next();case 5:if(l.done){e.F(2);break}return Te(e,(c=l.value).getAll(),8);case 8:return h=e.h,Te(e,Dm(r,i,h),9);case 9:return d=e.h,Te(e,c.remove(d),10);case 10:d.length!=h.length&&(o=!0),l=u.next(),e.F(5);break;case 2:return Ce(e),Te(e,a.destroy(),11);case 11:Me(e,3);break;case 3:return e.return(!o)}var t})));var n,i,r,a,o,s,u,l,c,h,d},t.list=function(){return qm(this,Ie(function(e){switch(e.g){case 1:return Wm(),r=[],t=new mm,k(e,2),Te(e,t.init(),4);case 4:return a=Promise.resolve(),i=function(n,t){a=a.then(function(){return Ie(function(e){if(1==e.g)return Te(e,t.getAllManifests(),2);e.h.forEach(function(e,t){e=_m(new Im("manifest",n.ob,n.Pa,t),e),r.push(e)}),Ae(e)})})},t.g.forEach(function(e,n){e.getCells().forEach(function(e,t){i({ob:n,Pa:t},e)})}),Te(e,a,2);case 2:return Ce(e),Te(e,t.destroy(),6);case 6:Me(e,3);break;case 3:return e.return(r)}var i}));var r,t,a},i("shaka.offline.Storage",Bm),Bm.deleteAll=function(){var r;return Ie(function(e){return 1==e.g?(r=new mm,k(e,2),Te(e,(t=r,Ie(function(e){return 1==e.g?(n=Array.from(t.g.values()),(i=0 can only be inside
in TTML");for(f=(d=we(jr(i,"div"))).next();!f.done;f=d.next())if(jr(f.value,"span").length)throw new ke(2,2,2001," can only be inside

in TTML");return(t=function e(t,n,i,r,a,o,s,u,l,c,h,d){var f=t.parentNode;if(t.nodeType==Node.COMMENT_NODE)return null;if(t.nodeType==Node.TEXT_NODE){if(!h)return null;var p=document.createElement("span");p.textContent=t.textContent}else p=t;for(var g=null,m=we(ay),v=m.next();!v.done&&!(g=B0(p,"backgroundImage",r,"#",v.value)[0]);v=m.next());m=null;var y=Gr(p,ay,"backgroundImage");d&&y&&!y.startsWith("#")&&(v=new ge(d),y=new ge(y),(v=v.resolve(y).toString())&&(m=v));("p"==t.nodeName||g||m)&&(h=!0);t=h;v="default"==(p.getAttribute("xml:space")||(u?"default":"preserve"));y=Array.from(p.childNodes).every(function(e){return e.nodeType==Node.TEXT_NODE});u=[];if(!y)for(var b=we(p.childNodes),w=b.next();!w.done;w=b.next())(w=e(w.value,n,i,r,a,o,s,v,l,p,h,d))&&u.push(w);r=null!=c;d=/\S/.test(p.textContent);w=p.hasAttribute("begin")||p.hasAttribute("end")||p.hasAttribute("dur");if(!(w||d||"br"==p.tagName||0!=u.length||r&&!v))return null;b=G0(p,i);d=b.start;for(b=b.end;f&&f.nodeType==Node.ELEMENT_NODE&&"tt"!=f.tagName;)b=F0(f,i,d,b),d=b.start,b=b.end,f=f.parentNode;null==d&&(d=0);d+=n.periodStart;b=null==b?1/0:b+n.periodStart;d=Math.max(d,n.segmentStart);b=Math.min(b,n.segmentEnd);if(!w&&0",o);if(u<=o)break e;(u=e.substring(o+1,u))&&"c"===u&&(s=i.pop())?s===u?(a+="/"+u+">",o+=u.length+1):s.startsWith("c.")?(o+=u.length+1,a+="/"+s+">"):a+=e[o]:a+=e[o]}else"<"===e[o]?"c"!=e[r=o+1]&&(r=-1):">"===e[o]&&0"===i[r]&&0",'

'),i+="
";e:{for(r=e=i,a=[],e="",i=!(o=-1),u=0;u",u))){e=r;break e}if((s=r.substring(u+1,s))&&"v"==s){var i=!0,l=null;if(l=a.length?a[a.length-1]:l){if(l===s)e+="/"+s+">";else{if(!l.startsWith("v")){e+=r[u];continue}e+="/"+l+">"}u+=s.length+1}else e+=r[u]}else e+=r[u]}else"<"===r[u]?"v"!=r[o=u+1]&&(o=-1):">"===r[u]&&0","<"+o+">")).replace("",""),i||(e+="")}if(i=Zr(""+e+"","span"))if(1==(i=i.childNodes).length&&((r=i[0]).nodeType==Node.TEXT_NODE||r.nodeType==Node.CDATA_SECTION_NODE))t.payload=fy(e);else for(i=(e=we(i)).next();!i.done;i=e.next())!function e(t,n,i){var r=n.clone();r.nestedCues=[];r.payload="";r.rubyTag="";r.line=null;r.region=new Wt;r.position=null;r.size=0;if(t.nodeType===Node.ELEMENT_NODE&&t.nodeName)for(var a=we(t.nodeName.split(/(?=[ .])+/g)),o=a.next();!o.done;o=a.next()){var s,u=o=o.value;switch(u.startsWith(".voice-")&&(u='v[voice="'+(s=u.split("-").pop())+'"]',i.has(u)||(u="v[voice="+s+"]")),i.has(u)&&(u=i.get(u))&&(r.backgroundColor=cy(u.backgroundColor,r.backgroundColor),r.color=cy(u.color,r.color),r.fontFamily=cy(u.fontFamily,r.fontFamily),r.fontSize=cy(u.fontSize,r.fontSize),r.fontWeight=u.fontWeight,r.fontStyle=u.fontStyle,r.opacity=u.opacity,r.rubyTag=u.rubyTag,r.textCombineUpright=u.textCombineUpright,r.textShadow=u.textShadow,r.wrapLine=u.wrapLine),o){case"br":return r=Lt(r.startTime,r.endTime),void n.nestedCues.push(r);case"b":r.fontWeight=700;break;case"i":r.fontStyle="italic";break;case"u":r.textDecoration.push("underline");break;case"font":(o=t.getAttribute("color"))&&(r.color=o);break;case"div":if(!(o=t.getAttribute("time")))break;(o=dy(new cp(o)))&&(r.startTime=o);break;case"ruby":case"rp":case"rt":r.rubyTag=o}}a=t.childNodes;if(Kr(t)||1==a.length&&Kr(a[0]))for(a=!0,i=we(t.textContent.split("\n")),t=i.next();!t.done;t=i.next())t=t.value,a||(a=Lt(r.startTime,r.endTime),n.nestedCues.push(a)),0",""":'"',"'":"'"," ":" ","‎":"‎","‏":"‏"},n=/&(?:amp|lt|gt|quot|#(0+)?39|nbsp|lrm|rlm);/g,i=RegExp(n.source);return e&&i.test(e)?e.replace(n,function(e){return t[e]||"'"}):e||""}bn["application/ttml+xml"]=function(){return new N0},oy.prototype.parseInit=function(e){var t=!1;if((new yr).box("moov",D).box("trak",D).box("mdia",D).box("minf",D).box("stbl",D).W("stsd",br).box("stpp",function(e){t=!0,e.parser.stop()}).parse(e),!t)throw new ke(2,2,2007)},oy.prototype.setSequenceMode=function(){},oy.prototype.setManifestType=function(){},oy.prototype.parseMedia=function(e,t,n){var i=this,r=!1,a=[];if((new yr).box("mdat",Tr(function(e){r=!0,a=a.concat(i.g.parseMedia(e,t,n))})).parse(e,!1),r)return a;throw new ke(2,2,2007)},i("shaka.text.Mp4TtmlParser",oy),bn['application/mp4; codecs="stpp"']=function(){return new oy},bn['application/mp4; codecs="stpp.ttml"']=function(){return new oy},bn['application/mp4; codecs="stpp.ttml.im1t"']=function(){return new oy},bn['application/mp4; codecs="stpp.TTML.im1t"']=function(){return new oy},sy.prototype.parseInit=function(){},sy.prototype.setSequenceMode=function(e){this.h=e},sy.prototype.setManifestType=function(e){this.g=e},sy.prototype.parseMedia=function(e,t){var n=(e=(e=lr(e)).replace(/\r\n|\r(?=[^\n]|$)/gm,"\n")).split(/\n{2,}/m);if(!/^WEBVTT($|[ \t\n])/m.test(n[0]))throw new ke(2,2,2e3);if(e=t.vttOffset,n[0].includes("X-TIMESTAMP-MAP")&&this.h){var i=n[0].match(/LOCAL:((?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{3}))/m),r=n[0].match(/MPEGTS:(\d+)/m);if(i&&r){if(null==(e=dy(new cp(i[1]))))throw new ke(2,2,2e3);for(r=Number(r[1]),i=t.segmentStart-t.periodStart;95443.7176888889<=i;)i-=95443.7176888889,r+=8589934592;e=t.periodStart+r/9e4-e}}else n[0].includes("X-TIMESTAMP-MAP")&&"HLS"==this.g&&(e=t.segmentStart);for(t=[],i=(r=we(n[0].split("\n"))).next();!i.done;i=r.next())if(i=i.value,/^Region:/.test(i)){var i=new cp(i),a=new Wt;fp(i),hp(i);for(var o=fp(i);o;){var s=a,u=o;(o=/^id=(.*)$/.exec(u))?s.id=o[1]:(o=/^width=(\d{1,2}|100)%$/.exec(u))?s.width=Number(o[1]):(o=/^lines=(\d+)$/.exec(u))?(s.height=Number(o[1]),s.heightUnits=2):(o=/^regionanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(u))?(s.regionAnchorX=Number(o[1]),s.regionAnchorY=Number(o[2])):(o=/^viewportanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(u))?(s.viewportAnchorX=Number(o[1]),s.viewportAnchorY=Number(o[2])):/^scroll=up$/.exec(u)&&(s.scroll="up"),hp(i),o=fp(i)}t.push(a)}for(uy(r=new Map),i=[],a=(n=we(n.slice(1))).next();!a.done;a=n.next()){if((1!=(a=a.value.split("\n")).length||a[0])&&!/^NOTE($|[ \t])/.test(a[0])&&"STYLE"==a[0]){for(s=[],o=-1,u=1;u").replace(/{\/b}/g,"").replace(/{i}/g,"").replace(/{\/i}/g,"").replace(/{u}/g,"").replace(/{\/u}/g,"")+"\n\n";return t}function wy(){}function Ty(e){return 0<=(e=parseInt(e.replace("&H",""),16))?"rgba("+(255&e)+","+(e>>8&255)+","+(e>>16&255)+","+(e>>24&255^255)/255+")":null}function Ay(e){return 3600*((e=Iy.exec(e))[1]?parseInt(e[1].replace(":",""),10):0)+60*parseInt(e[2],10)+parseFloat(e[3])}bn["text/vtt"]=function(){return new sy},bn['text/vtt; codecs="vtt"']=function(){return new sy},bn['text/vtt; codecs="wvtt"']=function(){return new sy},gy.prototype.parseInit=function(e){var t=this,n=!1;if((new yr).box("moov",D).box("trak",D).box("mdia",D).W("mdhd",function(e){e=qa(e.reader,e.version),t.g=e.timescale}).box("minf",D).box("stbl",D).W("stsd",br).box("wvtt",function(){n=!0}).parse(e),!this.g)throw new ke(2,2,2008);if(!n)throw new ke(2,2,2008)},gy.prototype.setSequenceMode=function(){},gy.prototype.setManifestType=function(){},gy.prototype.parseMedia=function(e,t){if(!e.length)return[];if(!this.g)throw new ke(2,2,2008);var n,i=0,r=[],a=[],o=!1,s=!1,u=!1,l=null;if((new yr).box("moof",D).box("traf",D).W("tfdt",function(e){o=!0,i=Wa(e.reader,e.version).baseMediaDecodeTime}).W("tfhd",function(e){l=Xa(e.reader,e.flags).Og}).W("trun",function(e){s=!0,r=Ya(e.reader,e.version,e.flags).lh}).box("mdat",Tr(function(e){u=!0,n=e})).parse(e,!1),!u&&!o&&!s)throw new ke(2,2,2008);e=i;for(var c=new gr(n,0),h=we(r),d=h.next();!d.done;d=h.next()){var f=(d=d.value).gg||l,p=d.Ie?i+d.Ie:e,g=(e=p+(f||0),0);do{var m=c.O();g+=m;var v=null;"vttc"==Er(c.O())?8>>5)-n)?{le:n,X:e}:null}function Cy(e,t){var n=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350],i=(60&e[t+2])>>>2;if(n.length-1>>6),a=(1&e[t+2])<<2;return a|=(192&e[t+3])>>>6,{sampleRate:n[i],channelCount:a,wa:"mp4a.40."+r}}function My(e){this.i=e,this.h=0,this.g=new Map}function Ly(e,t){if(t+8>e.length||11!==e[t]||119!==e[t+1])return null;var n=e[t+4]>>6;if(3<=n)return null;var i=63&e[t+4],r=2*[64,69,96,64,70,96,80,87,120,80,88,120,96,104,144,96,105,144,112,121,168,112,122,168,128,139,192,128,140,192,160,174,240,160,175,240,192,208,288,192,209,288,224,243,336,224,244,336,256,278,384,256,279,384,320,348,480,320,349,480,384,417,576,384,418,576,448,487,672,448,488,672,512,557,768,512,558,768,640,696,960,640,697,960,768,835,1152,768,836,1152,896,975,1344,896,976,1344,1024,1114,1536,1024,1115,1536,1152,1253,1728,1152,1254,1728,1280,1393,1920,1280,1394,1920][3*i+n];if(t+r>e.length)return null;var a=e[t+6]>>5,o=0,s=(2==a?o+=2:(1&a&&1!=a&&(o+=2),4&a&&(o+=2)),o=(e[t+6]<<8|e[t+7])>>12-o&1,7&e[t+5]);return e=new Uint8Array([n<<6|e[t+5]>>3<<1|s>>2,(3&s)<<6|a<<3|o<<2|i>>4,i<<4&224]),{sampleRate:[48e3,44100,32e3][n],channelCount:[2,1,2,3,3,4,4,5][a]+o,qa:e,X:r}}function Ry(e){this.i=e,this.h=0,this.g=new Map}function Ny(e,t){if(t+8>e.length||2935!=(e[t]<<8|e[t+1]<<0))return null;to(s=new Za(e.subarray(t+2)),2),to(s,3);var n=ie(s,11)+1<<1,i=ie(s,2),r=3==i?(i=[24e3,22060,16e3][i=ie(s,2)],3):(i=[48e3,44100,32e3][i],ie(s,2)),a=ie(s,3),o=ie(s,1),s=ie(s,5);return t+n>e.byteLength?null:(e=Math.floor(n*i/(16*[1,2,3,6][r])),e=new Uint8Array([(8160&e)>>5,(31&e)<<3,i<<6|s<<1|0,0|a<<1|o<<0,0]),{sampleRate:i,channelCount:[2,1,2,3,3,4,4,5][a]+o,qa:e,X:n})}function Py(e){this.i=e,this.h=0,this.g=new Map}function Dy(e){for(var t,n=!1,i=[],r=e.find(function(e){return 7==e.type}),a=!1,o=(e=we(e)).next();!o.done;o=e.next()){var s=!1;switch((o=o.value).type){case 1:var s=a=!0,u=o.data;r&&4>24&255,u[1]=s>>16&255,u[2]=s>>8&255,u[3]=255&s,i.push(Pr(u,o.fullData)))}return i.length?{data:Pr.apply(kr,le(i)),yd:n}:null}bn["text/x-ssa"]=function(){return new wy},(t=My.prototype).destroy=function(){this.g.clear()},t.isSupported=function(e){return"audio/aac"==e.toLowerCase().split(";")[0]&<(this.convertCodecs("audio",e))},t.convertCodecs=function(e,t){return"audio/aac"==t.toLowerCase().split(";")[0]?'audio/mp4; codecs="'+(dn(t)||"mp4a.40.2")+'"':t},t.getOriginalMimeType=function(){return this.i},t.transmux=function(e,t,n,i){for(var r=ne(e),a=Ha(r),o=a.length;o=e.length)return;var i=(3&e[t+3])<<11|e[t+4]<<3|(224&e[t+5])>>>5;return i<=n?void 0:(t+=i)===e.length||t+1>>24+o<>o,n=n?n<>8,o[14]=255&i.ze,o[15]=252|3&i.Zf,o[16]=252|3&i.jf,o[17]=248|7&i.gf,o[18]=248|7&i.ef,o[19]=0,o[20]=0,o[21]=(3&i.kf)<<6|(7&i.Wf)<<3|(i.ug?1:0)<<2|3,o[22]=3,o[23]=160,o[24]=0,o[25]=1,o[26]=(65280&r.byteLength)>>8,o[27]=(255&r.byteLength)>>0,o.set(r,28),o[23+(5+r.byteLength)]=161,o[r.byteLength+29]=0,o[r.byteLength+30]=1,o[r.byteLength+31]=(65280&a.byteLength)>>8,o[r.byteLength+32]=(255&a.byteLength)>>0,o.set(a,r.byteLength+33),o[23+(r.byteLength+10+a.byteLength)]=162,o[r.byteLength+10+a.byteLength+24]=0,o[r.byteLength+10+a.byteLength+25]=1,o[r.byteLength+10+a.byteLength+26]=(65280&n.byteLength)>>8,o[r.byteLength+10+a.byteLength+27]=(255&n.byteLength)>>0,o.set(n,r.byteLength+10+a.byteLength+28),t=o,{height:e.height,width:e.width,Da:t}}function Oy(e,t){var n,i,r,a,o=e[t+1]>>3&3,s=e[t+1]>>1&3,u=e[t+2]>>4&15,l=e[t+2]>>2&3;return 1!==o&&0!==u&&15!==u&&3!==l?(n=e[t+3]>>6,u=1e3*By[14*(3===o?3-s:3==s?3:4)+u-1],l=Fy[3*(3===o?0:2===o?1:2)+l],o=Gy[o][s],i=Vy[s],r=Math.floor(o*u/l+(e[t+2]>>1&1))*i,(a=(a=(navigator.userAgent||"").match(/Chrome\/(\d+)/i))?parseInt(a[1],10):0)&&a<=87&&2==s&&224e3<=u&&0==n&&(e[t+3]|=128),{sampleRate:l,channelCount:3==n?1:2,X:r,jj:8*o*i}):null}function jy(e,t){return 255===e[t]&&224==(224&e[t+1])&&0!=(6&e[t+1])}var By=[32,64,96,128,160,192,224,256,288,320,352,384,416,448,32,48,56,64,80,96,112,128,160,192,224,256,320,384,32,40,48,56,64,80,96,112,128,160,192,224,256,320,32,48,56,64,80,96,112,128,144,160,176,192,224,256,8,16,24,32,40,48,56,64,80,96,112,128,144,160],Fy=[44100,48e3,32e3,22050,24e3,16e3,11025,12e3,8e3],Gy=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],Vy=[0,1,1,4];function Ky(e){this.i=e,this.h=0,this.g=new Map}function zy(e){this.h=e,this.g=null}function Hy(e){function n(){this._procFullBox(),1&this.flags&&(this._procField("AlgorithmID","uint",24),this._procField("IV_size","uint",8),this._procFieldArray("KID",16,"uint",8)),this._procField("sample_count","uint",32),this._procEntries("entry",this.sample_count,function(e){this._procEntryField(e,"InitializationVector","data",8),2&this.flags&&(this._procEntryField(e,"NumberOfEntries","uint",16),this._procSubEntries(e,"clearAndCryptedData",e.NumberOfEntries,function(e){this._procEntryField(e,"BytesOfClearData","uint",16),this._procEntryField(e,"BytesOfEncryptedData","uint",32)}))})}this.h=e,(this.g=Qf.get("ISOBoxer")())&&((e=this).g.addBoxProcessor("saio",function(){this._procFullBox(),1&this.flags&&(this._procField("aux_info_type","uint",32),this._procField("aux_info_type_parameter","uint",32)),this._procField("entry_count","uint",32),this._procFieldArray("offset",this.entry_count,"uint",1===this.version?64:32)}),e.g.addBoxProcessor("saiz",function(){this._procFullBox(),1&this.flags&&(this._procField("aux_info_type","uint",32),this._procField("aux_info_type_parameter","uint",32)),this._procField("default_sample_info_size","uint",8),this._procField("sample_count","uint",32),0===this.default_sample_info_size&&this._procFieldArray("sample_info_size",this.sample_count,"uint",8)}),e.g.addBoxProcessor("senc",n),e.g.addBoxProcessor("uuid",function(){for(var e=!0,t=0;t<16;t++)this.usertype[t]!==Wy[t]&&(e=!1);e&&(this._parsing&&(this.type="sepiff"),n.call(this))}))}function Xy(e,t){for(var n=8,i=0;i>>8&255),r.push(255&t.byteLength),r=r.concat.apply(r,le(t)),e=e.fullData,(t=[]).push(e.byteLength>>>8&255),t.push(255&e.byteLength),t=t.concat.apply(t,le(e)),{height:n,width:i,Da:e=new Uint8Array([1,r[3],r[4],r[5],255,225].concat(r,[1],t))}}(l);if(!m||null==u)throw new ke(2,3,3018);t.height=m.height,t.width=m.width,o={id:t.id,type:"video",codecs:"avc1",encrypted:t.encrypted&&0>24&255,w[1]=b>>16&255,w[2]=b>>8&255,w[3]=255&b,v.push(Pr(w,T.fullData)))}var E=v.length?{data:Pr.apply(kr,le(v)),yd:m}:null;E&&(null==f&&null!=u.dts&&(f=u.dts),m=void 0,m=g+1Date.now()&&(n.j.stop(),n.m=Date.now(),n.h.textContent=(n.l?parseInt(n.h.textContent,10)-e:parseInt(n.h.textContent,10)+e).toString()+"s",n.g.style.opacity="1",n.j.S(1)):(n.s=!0,n.m=Date.now(),n.j.S(1))))}),this.h=E("span"),this.h.textContent="0s",this.g.appendChild(this.h),this.i=E("span"),this.i.classList.add("shaka-forward-rewind-container-icon"),this.g.appendChild(this.i),this.l=!1}function N1(e,t){R1.call(this,e,t),this.g.classList.add("shaka-fast-foward-container"),this.i.textContent="fast_forward",this.l=!1}function P1(e,t){R1.call(this,e,t),this.g.classList.add("shaka-rewind-container"),this.i.textContent="fast_rewind",this.l=!0}function D1(e,t,n,i){m.call(this,e,t);var r=this;this.container=E("div"),this.container.classList.add("shaka-range-container"),this.container.classList.add.apply(this.container.classList,le(n)),this.h=!1,this.bar=document.createElement("input"),this.J=new I(function(){r.onChangeEnd(),r.h=!1}),this.bar.classList.add("shaka-range-element"),this.bar.classList.add.apply(this.bar.classList,le(i)),this.bar.type="range",this.bar.step="any",this.bar.min="0",this.bar.max="1",this.bar.value="0",this.container.appendChild(this.bar),this.parent.appendChild(this.container),this.eventManager.o(this.bar,"mousedown",function(){r.controls.$b()&&(r.h=!0,r.onChangeStart())}),this.eventManager.o(this.bar,"touchstart",function(e){r.controls.$b()&&(r.h=!0,_1(r,e),r.onChangeStart())}),this.eventManager.o(this.bar,"input",function(){r.onChange()}),this.eventManager.o(this.bar,"touchmove",function(e){r.h&&(_1(r,e),r.onChange())}),this.eventManager.o(this.bar,"touchend",function(e){r.h&&(r.h=!1,_1(r,e),r.onChangeEnd())}),this.eventManager.o(this.bar,"touchcancel",function(e){r.h&&(r.h=!1,_1(r,e),r.onChangeEnd())}),this.eventManager.o(this.bar,"mouseup",function(){r.h&&(r.h=!1,r.onChangeEnd())}),this.eventManager.o(this.bar,"blur",function(){r.h&&(r.h=!1,r.onChangeEnd())}),this.eventManager.o(this.bar,"contextmenu",function(e){e.preventDefault(),e.stopPropagation()})}function _1(e,t){t.preventDefault();var n=t.changedTouches[0],i=e.bar.getBoundingClientRect(),r=(t=parseFloat(e.bar.min),parseFloat(e.bar.max));(n=t+(r-t)/i.width*(n.clientX-i.left))=u.end||(e=c.startTime>u.start?c.startTime:u.start,t=c.endTime=i.start&&c.starti.end)&&(n=(t=(c.start-i.start)/r||0)+.01,c.end&&(n=(c.end-i.start)/r||0),o.push({start:t,end:n}));for(c=(i=we(o)).next();!c.done;c=i.next())r=c.value,a.push("transparent "+100*r.start+"%"),a.push(s+" "+100*r.start+"%"),a.push(s+" "+100*r.end+"%"),a.push("transparent "+100*r.end+"%");u&&(a.push("transparent 99%"),a.push(s+" 99%")),e.G.style.background="linear-gradient("+a.join(",")+")"}else e.G.style.background="transparent"}function j1(e){O1(e);var t=(t=e.player.Ca()).end-t.start;e.player.R()&&5