@theoplayer/theoads 9.6.0 → 9.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/theoplayer.sw.js CHANGED
@@ -24,7 +24,7 @@
24
24
  THEOplayer is based on patented technology developed by
25
25
  THEO Technologies (https://www.theoplayer.com).
26
26
 
27
- Version: 9.6.0
28
- Created: 2025-06-19T12:04:41.838Z
27
+ Version: 9.6.1
28
+ Created: 2025-06-23T15:45:18.840Z
29
29
  */
30
30
  !function(t){"use strict";var n,i,e,r,o,u,s,f,c,h=t.window,a=t.document,v=(t.location,t.navigator),d=t.setTimeout,l=t.clearTimeout,w=t.setInterval,b=t.clearInterval,g=t.Error,m=t.TypeError,p=(t.SyntaxError,t.Object),y=t.Math,_=t.parseInt,S=t.parseFloat,T=t.isNaN,E=t.Uint8Array,I=(t.Worker,t.WorkerGlobalScope,t.XMLHttpRequest),k=p.create,R=p.defineProperty,O=p.getOwnPropertyDescriptor,N=p.getOwnPropertyNames,P=p.getPrototypeOf,A=p.prototype.hasOwnProperty,D=function(t,n){return function(){return t&&(n=t(t=0)),n}},C=function(t,n){return function(){return n||t((n={exports:{}}).exports,n),n.exports}},x=D((function(){"function"==typeof Symbol&&Symbol.iterator?(n=Symbol,i=null!=(u=Symbol.for)?u:Symbol,e=Symbol.iterator,r=null!=(s=Symbol.dispose)?s:i("Symbol.dispose"),o=null!=(f=Symbol.asyncDispose)?f:i("Symbol.asyncDispose")):(c=0,n=function(t){return"ul"+t+"_"+ ++c},e=(i=function(t){return"ul"+t})("Symbol.iterator"),r=i("Symbol.dispose"),o=i("Symbol.asyncDispose"),n.for=i,n.iterator=e,n.dispose=r,n.asyncDispose=o)}));function B(t){return t&&void 0!==n&&t.constructor===n?"symbol":typeof t}var M,L,U,F,z,W,V,H,q,X,j,Y,K,G,$,Z,J,Q,tt,nt=D((function(){x(),gt()}));function it(t){var n=this.constructor;return this.then((function(i){return n.resolve(t()).then((function(){return i}))}),(function(i){return n.resolve(t()).then((function(){return n.reject(i)}))}))}function et(t){return new this((function(n,i){if(!t||void 0===t.length)return i(new m((void 0===t?"undefined":B(t))+" "+t+" is not iterable(cannot read property Symbol(Symbol.iterator))"));var e=Array.prototype.slice.call(t);if(0===e.length)return n([]);var r=e.length;function o(t,i){if(i&&("object"===(void 0===i?"undefined":B(i))||"function"==typeof i)){var u=i.then;if("function"==typeof u)return void u.call(i,(function(n){o(t,n)}),(function(i){e[t]={status:"rejected",reason:i},0==--r&&n(e)}))}e[t]={status:"fulfilled",value:i},0==--r&&n(e)}for(var u=0;u<e.length;u++)o(u,e[u])}))}function rt(t){return Boolean(t&&void 0!==t.length)}function ot(){}function ut(t){if(!(this instanceof ut))throw new m("Promises must be constructed via new");if("function"!=typeof t)throw new m("not a function");this.Fa=0,this.ttn=!1,this.mTt=void 0,this.ntn=[],vt(t,this)}function st(t,n){for(;3===t.Fa;)t=t.mTt;0!==t.Fa?(t.ttn=!0,ut.itn((function(){var i=1===t.Fa?n.onFulfilled:n.onRejected;if(null!==i){var e;try{e=i(t.mTt)}catch(t){return void ct(n.promise,t)}ft(n.promise,e)}else(1===t.Fa?ft:ct)(n.promise,t.mTt)}))):t.ntn.push(n)}function ft(t,n){try{if(n===t)throw new m("A promise cannot be resolved with itself.");if(n&&("object"===(void 0===n?"undefined":B(n))||"function"==typeof n)){var i=n.then;if(n instanceof ut)return t.Fa=3,t.mTt=n,void ht(t);if("function"==typeof i)return void vt(function(t,n){return function(){t.apply(n,arguments)}}(i,n),t)}t.Fa=1,t.mTt=n,ht(t)}catch(n){ct(t,n)}}function ct(t,n){t.Fa=2,t.mTt=n,ht(t)}function ht(t){2===t.Fa&&0===t.ntn.length&&ut.itn((function(){t.ttn||ut.rtn(t.mTt)}));for(var n=0,i=t.ntn.length;n<i;n++)st(t,t.ntn[n]);t.ntn=null}function at(t,n,i){this.onFulfilled="function"==typeof t?t:null,this.onRejected="function"==typeof n?n:null,this.promise=i}function vt(t,n){var i=!1;try{t((function(t){i||(i=!0,ft(n,t))}),(function(t){i||(i=!0,ct(n,t))}))}catch(t){if(i)return;i=!0,ct(n,t)}}function dt(t){return new Y(j,{reason:t,promise:L.reject(t).catch((function(){})),cancelable:!0})}function lt(t){var n=new K(j,{detail:{reason:t},cancelable:!0});return p.defineProperty(n,"reason",{value:t}),n}function wt(t){var n=a.createEvent("CustomEvent");return n.initCustomEvent(j,!1,!0,{reason:t}),n}var bt=D((function(){var t,n,i,e;x(),gt(),nt(),M=d,ut.prototype.catch=function(t){return this.then(null,t)},ut.prototype.then=function(t,n){var i=new this.constructor(ot);return st(this,new at(t,n,i)),i},ut.prototype.finally=it,ut.all=function(t){return new ut((function(n,i){if(!rt(t))return i(new m("Promise.all accepts an array"));var e=Array.prototype.slice.call(t);if(0===e.length)return n([]);var r=e.length;function o(t,u){try{if(u&&("object"===(void 0===u?"undefined":B(u))||"function"==typeof u)){var s=u.then;if("function"==typeof s)return void s.call(u,(function(n){o(t,n)}),i)}e[t]=u,0==--r&&n(e)}catch(t){i(t)}}for(var u=0;u<e.length;u++)o(u,e[u])}))},ut.allSettled=et,ut.resolve=function(t){return t&&"object"===(void 0===t?"undefined":B(t))&&t.constructor===ut?t:new ut((function(n){n(t)}))},ut.reject=function(t){return new ut((function(n,i){i(t)}))},ut.race=function(t){return new ut((function(n,i){if(!rt(t))return i(new m("Promise.race accepts an array"));for(var e=0,r=t.length;e<r;e++)ut.resolve(t[e]).then(n,i)}))},ut.itn="function"==typeof setImmediate&&function(t){setImmediate(t)}||function(t){M(t,0)},ut.rtn=function(t){"undefined"!=typeof console&&console&&console.warn("Possible Unhandled Promise Rejection:",t)},L=function(){var t=self.Promise;if(void 0!==t)try{if(-1!==t.toString().indexOf("[native code]"))return t}catch(t){}}(),U=v?v.userAgent:"",F=U.match(/Firefox\/([0-9]+)/i),z=null!=F,W=F?Number(F[1]):0,V=U.match(/(Version)\/((\d+)\.(\d+)(?:\.(\d+))?).*Safari/),H=null!=V,q=V?Number(V[3]):0,X=function(){function t(t){this.Jb=0,this.Id=0,this.Zp=[],this.etn=t}return t.prototype.utn=function(t){var n=this.length();this.stn(n+1);var i=this.Id+n&this.etn-1;this.Zp[i]=t,this.Jb=n+1},t.prototype.push=function(t){var n=this.length()+1;if(this.etn<n)this.utn(t);else{var i=this.Id+n-1,e=this.etn-1;this.Zp[i&e]=t,this.Jb=n}},t.prototype.shift=function(){var t=this.Id,n=this.Zp[t];return this.Zp[t]=void 0,this.Id=t+1&this.etn-1,this.Jb--,n},t.prototype.length=function(){return this.Jb},t.prototype.stn=function(t){this.etn<t&&this.otn(this.etn<<1)},t.prototype.otn=function(t){var n=this.etn;this.etn=t;var i=this.Id+this.Jb&n-1;!function(t,n,i,e){for(var r=0;r<e;++r)t[r+i]=t[r+n],t[r+n]=void 0}(this.Zp,0,n,i)},t}(),j="unhandledrejection",Y=self.PromiseRejectionEvent,K=self.CustomEvent,G=function(t){return G=function(){try{var t=L.resolve(),n="error",i=new Y(j,{reason:n,promise:t});return j===i.type&&n===i.reason}catch(t){}return!1}()?dt:function(){try{var t="error",n=new K(j,{detail:{reason:t}});return j===n.type&&t===n.detail.reason}catch(t){}return!1}()?lt:wt,G(t)},Z=z&&W<60||H&&q<15,L&&!Z?(J=L,function(){}):(J=ut,Q=null!==($=function(){var t=self.queueMicrotask;if("function"==typeof t)return function(n){return t(n)};var n=L;if(n&&"function"==typeof n.resolve){var i=n.resolve();return function(t){return i.then(t)}}}())&&void 0!==$?$:ut.itn,t=Q,n=new X(16),i=!1,(tt={L6:function(r){n.push(r),i||(i=!0,t(e))},TY:e=function(){for(;n.length()>0;)n.shift()();i=!1}}).TY,ut.itn=tt.L6,ut.rtn=function(t){try{var n=G(t);if(!self.dispatchEvent(n)||n.defaultPrevented)return}catch(t){}d((function(){throw new g("Unhandled promise rejection: ".concat(t))}),0)})})),gt=D((function(){bt()})),mt=C((function(t,i){var r,o;x(),gt(),nt(),r=t,o=function(t){var i="function"==typeof n&&"symbol"===B(e)?n:function(t){return"Symbol("+t+")"};function r(){}var o=Number.isNaN||function(t){return t!=t},u=r;function s(t){return"object"===(void 0===t?"undefined":B(t))&&null!==t||"function"==typeof t}function f(t){return t.slice()}function c(t,n,i,e,r){new E(t).set(new E(i,e,r),n)}function h(t){return!1!==function(t){return"number"==typeof t&&(!o(t)&&!(t<0))}(t)&&t!==1/0}function a(t,n,i){if("function"!=typeof t)throw new m("Argument is not a function");return Function.prototype.apply.call(t,n,i)}function v(t,n,i,e){var r=t[n];if(void 0!==r){if("function"!=typeof r)throw new m(r+" is not a method");switch(i){case 0:return function(){return l(r,t,e)};case 1:return function(n){var i=[n].concat(e);return l(r,t,i)}}}return function(){return R(void 0)}}function d(t,n,i){var e=t[n];if(void 0!==e)return a(e,t,i)}function l(t,n,i){try{return R(a(t,n,i))}catch(t){return O(t)}}function w(t){if(t=Number(t),o(t)||t<0)throw new RangeError("highWaterMark property of a queuing strategy must be non-negative and non-NaN");return t}function b(t){if(void 0===t)return function(){return 1};if("function"!=typeof t)throw new m("size property of a queuing strategy must be a function");return function(n){return t(n)}}var _=J,S=J.prototype.then,T=J.resolve.bind(_),I=J.reject.bind(_);function k(t){return new _(t)}function R(t){return T(t)}function O(t){return I(t)}function N(t,n,i){return S.call(t,n,i)}function P(t,n,i){N(N(t,n,i),void 0,u)}function A(t,n){P(t,n)}function D(t,n){P(t,void 0,n)}function C(t,n,i){return N(t,n,i)}function x(t){N(t,void 0,u)}var M=function(){function t(){this.hd=0,this.Ed=0,this.Id={Rd:[],Dd:void 0},this.Nd=this.Id,this.hd=0,this.Ed=0}return p.defineProperty(t.prototype,"length",{get:function(){return this.Ed},enumerable:!0,configurable:!0}),t.prototype.push=function(t){var n=this.Nd,i=n;16383===n.Rd.length&&(i={Rd:[],Dd:void 0}),n.Rd.push(t),i!==n&&(this.Nd=i,n.Dd=i),++this.Ed},t.prototype.shift=function(){var t=this.Id,n=t,i=this.hd,e=i+1,r=t.Rd,o=r[i];return 16384===e&&(n=t.Dd,e=0),--this.Ed,this.hd=e,t!==n&&(this.Id=n),r[i]=void 0,o},t.prototype.forEach=function(t){for(var n=this.hd,i=this.Id,e=i.Rd;!(n===e.length&&void 0===i.Dd||n===e.length&&(n=0,0===(e=(i=i.Dd).Rd).length));)t(e[n]),++n},t.prototype.peek=function(){var t=this.Id,n=this.hd;return t.Rd[n]},t}();function L(t,n,i){var e=null;!0===i&&(e=p.prototype);var r=p.create(e);return r.value=t,r.done=n,r}function U(t,n){t.Ld=!0,t.Bd=n,n.Od=t,"readable"===n.Fa?V(t):"closed"===n.Fa?function(t){V(t),X(t)}(t):H(t,n.Fd)}function F(t,n){return Zn(t.Bd,n)}function z(t){"readable"===t.Bd.Fa?q(t,new m("Reader was released and can no longer be used to monitor the stream's closedness")):function(t,n){H(t,n)}(t,new m("Reader was released and can no longer be used to monitor the stream's closedness")),t.Bd.Od=void 0,t.Bd=void 0}function W(t){return new m("Cannot "+t+" a stream using a released reader")}function V(t){t.Vd=k((function(n,i){t.Wd=n,t.Ud=i}))}function H(t,n){V(t),q(t,n)}function q(t,n){x(t.Vd),t.Ud(n),t.Wd=void 0,t.Ud=void 0}function X(t){t.Wd(void 0),t.Wd=void 0,t.Ud=void 0}var j=i("[[CancelSteps]]"),Y=i("[[PullSteps]]");function K(t,n){void 0===n&&(n=!1);var i=new it(t);return i.Ld=n,i}function G(t){return k((function(n,i){var e={Gd:n,Zd:i};t.Od.Hd.push(e)}))}function $(t,n,i){var e=t.Od;e.Hd.shift().Gd(L(n,i,e.Ld))}function Z(t){return t.Od.Hd.length}function Q(t){var n=t.Od;return void 0!==n&&!!et(n)}var tt,nt,it=function(){function t(t){if(!1===Gn(t))throw new m("ReadableStreamDefaultReader can only be constructed with a ReadableStream instance");if(!0===$n(t))throw new m("This stream has already been locked for exclusive reading by another reader");U(this,t),this.Hd=new M}return p.defineProperty(t.prototype,"closed",{get:function(){return et(this)?this.Vd:O(ot("closed"))},enumerable:!0,configurable:!0}),t.prototype.cancel=function(t){return et(this)?void 0===this.Bd?O(W("cancel")):F(this,t):O(ot("cancel"))},t.prototype.read=function(){return et(this)?void 0===this.Bd?O(W("read from")):rt(this):O(ot("read"))},t.prototype.releaseLock=function(){if(!et(this))throw ot("releaseLock");if(void 0!==this.Bd){if(this.Hd.length>0)throw new m("Tried to release a reader lock when that reader has pending read() calls un-settled");z(this)}},t}();function et(t){return!!s(t)&&!!p.prototype.hasOwnProperty.call(t,"Hd")}function rt(t){var n=t.Bd;return n.Xd=!0,"closed"===n.Fa?R(L(void 0,!0,t.Ld)):"errored"===n.Fa?O(n.Fd):n.zd[Y]()}function ot(t){return new m("ReadableStreamDefaultReader.prototype."+t+" can only be used on a ReadableStreamDefaultReader")}"symbol"===B(i.asyncIterator)&&((tt={})[i.asyncIterator]=function(){return this},nt=tt,p.defineProperty(nt,i.asyncIterator,{enumerable:!1}));var ut={next:function(){if(!1===st(this))return O(ft("next"));var t=this.qd;return void 0===t.Bd?O(W("iterate")):C(rt(t),(function(n){var i=n.done;return i&&z(t),L(n.value,i,!0)}))},return:function(t){if(!1===st(this))return O(ft("next"));var n=this.qd;if(void 0===n.Bd)return O(W("finish iterating"));if(n.Hd.length>0)return O(new m("Tried to release a reader lock when that reader has pending read() calls un-settled"));if(!1===this.Yd){var i=F(n,t);return z(n),C(i,(function(){return L(t,!0,!0)}))}return z(n),R(L(t,!0,!0))}};function st(t){return!!s(t)&&!!p.prototype.hasOwnProperty.call(t,"qd")}function ft(t){return new m("ReadableStreamAsyncIterator."+t+" can only be used on a ReadableSteamAsyncIterator")}function ct(t){var n=t.Kd.shift();return t.Qd-=n.size,t.Qd<0&&(t.Qd=0),n.value}function ht(t,n,i){if(!h(i=Number(i)))throw new RangeError("Size must be a finite, non-NaN, non-negative number.");t.Kd.push({value:n,size:i}),t.Qd+=i}function at(t){t.Kd=new M,t.Qd=0}void 0!==nt&&p.setPrototypeOf(ut,nt),p.defineProperty(ut,"next",{enumerable:!1}),p.defineProperty(ut,"return",{enumerable:!1});var vt=i("[[AbortSteps]]"),dt=i("[[ErrorSteps]]"),lt=function(){function t(t,n){void 0===t&&(t={}),void 0===n&&(n={}),bt(this);var i=n.size,e=n.highWaterMark;if(void 0!==t.type)throw new RangeError("Invalid type is specified");var r=b(i);void 0===e&&(e=1),function(t,n,i,e){var r=p.create(xt.prototype);function o(){return d(n,"start",[r])}var u=v(n,"write",1,[r]),s=v(n,"close",0,[]),f=v(n,"abort",1,[]);Bt(t,r,o,u,s,f,i,e)}(this,t,e=w(e),r)}return p.defineProperty(t.prototype,"locked",{get:function(){if(!1===gt(this))throw Vt("locked");return mt(this)},enumerable:!0,configurable:!0}),t.prototype.abort=function(t){return!1===gt(this)?O(Vt("abort")):!0===mt(this)?O(new m("Cannot abort a stream that already has a writer")):pt(this,t)},t.prototype.close=function(){return!1===gt(this)?O(Vt("close")):!0===mt(this)?O(new m("Cannot close a stream that already has a writer")):!0===Et(this)?O(new m("Cannot close an already-closing stream")):yt(this)},t.prototype.getWriter=function(){if(!1===gt(this))throw Vt("getWriter");return wt(this)},t}();function wt(t){return new Rt(t)}function bt(t){t.Fa="writable",t.Fd=void 0,t.Jd=void 0,t.$d=void 0,t.tf=new M,t.ef=void 0,t.nf=void 0,t.rf=void 0,t.hf=void 0,t.uf=!1}function gt(t){return!!s(t)&&!!p.prototype.hasOwnProperty.call(t,"$d")}function mt(t){return void 0!==t.Jd}function pt(t,n){var i=t.Fa;if("closed"===i||"errored"===i)return R(void 0);if(void 0!==t.hf)return t.hf.cf;var e=!1;"erroring"===i&&(e=!0,n=void 0);var r=k((function(i,r){t.hf={cf:void 0,Gd:i,Zd:r,lf:n,df:e}}));return t.hf.cf=r,!1===e&&St(t,n),r}function yt(t){var n=t.Fa;if("closed"===n||"errored"===n)return O(new m("The stream (in "+n+" state) is not in the writable state and cannot be closed"));var i=k((function(n,i){var e={Gd:n,Zd:i};t.nf=e})),e=t.Jd;return void 0!==e&&!0===t.uf&&"writable"===n&&Qt(e),function(t){ht(t,"close",0),Ut(t)}(t.$d),i}function _t(t,n){"writable"!==t.Fa?Tt(t):St(t,n)}function St(t,n){var i=t.$d;t.Fa="erroring",t.Fd=n;var e=t.Jd;void 0!==e&&At(e,n),!1===function(t){return void 0!==t.ef||void 0!==t.rf}(t)&&!0===i._f&&Tt(t)}function Tt(t){t.Fa="errored",t.$d[dt]();var n=t.Fd;if(t.tf.forEach((function(t){t.Zd(n)})),t.tf=new M,void 0!==t.hf){var i=t.hf;if(t.hf=void 0,!0===i.df)return i.Zd(n),void It(t);P(t.$d[vt](i.lf),(function(){i.Gd(),It(t)}),(function(n){i.Zd(n),It(t)}))}else It(t)}function Et(t){return void 0!==t.nf||void 0!==t.rf}function It(t){void 0!==t.nf&&(t.nf.Zd(t.Fd),t.nf=void 0);var n=t.Jd;void 0!==n&&Yt(n,t.Fd)}function kt(t,n){var i=t.Jd;void 0!==i&&n!==t.uf&&(!0===n?function(t){Gt(t)}(i):Qt(i)),t.uf=n}var Rt=function(){function t(t){if(!1===gt(t))throw new m("WritableStreamDefaultWriter can only be constructed with a WritableStream instance");if(!0===mt(t))throw new m("This stream has already been locked for exclusive writing by another writer");this.vf=t,t.Jd=this;var n=t.Fa;if("writable"===n)!1===Et(t)&&!0===t.uf?Gt(this):Zt(this),Xt(this);else if("erroring"===n)$t(this,t.Fd),Xt(this);else if("closed"===n)Zt(this),function(t){Xt(t),Kt(t)}(this);else{var i=t.Fd;$t(this,i),jt(this,i)}}return p.defineProperty(t.prototype,"closed",{get:function(){return!1===Ot(this)?O(Ht("closed")):this.Vd},enumerable:!0,configurable:!0}),p.defineProperty(t.prototype,"desiredSize",{get:function(){if(!1===Ot(this))throw Ht("desiredSize");if(void 0===this.vf)throw qt("desiredSize");return function(t){var n=t.vf,i=n.Fa;return"errored"===i||"erroring"===i?null:"closed"===i?0:Lt(n.$d)}(this)},enumerable:!0,configurable:!0}),p.defineProperty(t.prototype,"ready",{get:function(){return!1===Ot(this)?O(Ht("ready")):this.gf},enumerable:!0,configurable:!0}),t.prototype.abort=function(t){return!1===Ot(this)?O(Ht("abort")):void 0===this.vf?O(qt("abort")):function(t,n){var i=t.vf;return pt(i,n)}(this,t)},t.prototype.close=function(){if(!1===Ot(this))return O(Ht("close"));var t=this.vf;return void 0===t?O(qt("close")):!0===Et(t)?O(new m("Cannot close an already-closing stream")):Nt(this)},t.prototype.releaseLock=function(){if(!1===Ot(this))throw Ht("releaseLock");void 0!==this.vf&&Dt(this)},t.prototype.write=function(t){return!1===Ot(this)?O(Ht("write")):void 0===this.vf?O(qt("write to")):Ct(this,t)},t}();function Ot(t){return!!s(t)&&!!p.prototype.hasOwnProperty.call(t,"vf")}function Nt(t){return yt(t.vf)}function Pt(t,n){"pending"===t.mf?Yt(t,n):function(t,n){jt(t,n)}(t,n)}function At(t,n){"pending"===t.pf?Jt(t,n):function(t,n){$t(t,n)}(t,n)}function Dt(t){var n=t.vf,i=new m("Writer was released and can no longer be used to monitor the stream's closedness");At(t,i),Pt(t,i),n.Jd=void 0,t.vf=void 0}function Ct(t,n){var i=t.vf,e=i.$d,r=function(t,n){try{return t.wf(n)}catch(n){return Ft(t,n),1}}(e,n);if(i!==t.vf)return O(qt("write to"));var o=i.Fa;if("errored"===o)return O(i.Fd);if(!0===Et(i)||"closed"===o)return O(new m("The stream is closing or closed and cannot be written to"));if("erroring"===o)return O(i.Fd);var u=function(t){return k((function(n,i){var e={Gd:n,Zd:i};t.tf.push(e)}))}(i);return function(t,n,i){var e={chunk:n};try{ht(t,e,i)}catch(n){return void Ft(t,n)}var r=t.yf;!1===Et(r)&&"writable"===r.Fa&&kt(r,zt(t)),Ut(t)}(e,n,r),u}var xt=function(){function t(){throw new m("WritableStreamDefaultController cannot be constructed explicitly")}return t.prototype.error=function(t){if(!1===function(t){return!!s(t)&&!!p.prototype.hasOwnProperty.call(t,"yf")}(this))throw new m("WritableStreamDefaultController.prototype.error can only be used on a WritableStreamDefaultController");"writable"===this.yf.Fa&&Wt(this,t)},t.prototype[vt]=function(t){var n=this.bf(t);return Mt(this),n},t.prototype[dt]=function(){at(this)},t}();function Bt(t,n,i,e,r,o,u,s){n.yf=t,t.$d=n,n.Kd=void 0,n.Qd=void 0,at(n),n._f=!1,n.wf=s,n.Af=u,n.Sf=e,n.Tf=r,n.bf=o;var f=zt(n);kt(t,f),P(R(i()),(function(){n._f=!0,Ut(n)}),(function(i){n._f=!0,_t(t,i)}))}function Mt(t){t.Sf=void 0,t.Tf=void 0,t.bf=void 0,t.wf=void 0}function Lt(t){return t.Af-t.Qd}function Ut(t){var n=t.yf;if(!1!==t._f&&void 0===n.ef)if("erroring"!==n.Fa){if(0!==t.Kd.length){var i=function(t){return t.Kd.peek().value}(t);"close"===i?function(t){var n=t.yf;(function(t){t.rf=t.nf,t.nf=void 0})(n),ct(t);var i=t.Tf();Mt(t),P(i,(function(){!function(t){t.rf.Gd(void 0),t.rf=void 0,"erroring"===t.Fa&&(t.Fd=void 0,void 0!==t.hf&&(t.hf.Gd(),t.hf=void 0)),t.Fa="closed";var n=t.Jd;void 0!==n&&Kt(n)}(n)}),(function(t){!function(t,n){t.rf.Zd(n),t.rf=void 0,void 0!==t.hf&&(t.hf.Zd(n),t.hf=void 0),_t(t,n)}(n,t)}))}(t):function(t,n){var i=t.yf;!function(t){t.ef=t.tf.shift()}(i);var e=t.Sf(n);P(e,(function(){!function(t){t.ef.Gd(void 0),t.ef=void 0}(i);var n=i.Fa;if(ct(t),!1===Et(i)&&"writable"===n){var e=zt(t);kt(i,e)}Ut(t)}),(function(n){"writable"===i.Fa&&Mt(t),function(t,n){t.ef.Zd(n),t.ef=void 0,_t(t,n)}(i,n)}))}(t,i.chunk)}}else Tt(n)}function Ft(t,n){"writable"===t.yf.Fa&&Wt(t,n)}function zt(t){return Lt(t)<=0}function Wt(t,n){var i=t.yf;Mt(t),St(i,n)}function Vt(t){return new m("WritableStream.prototype."+t+" can only be used on a WritableStream")}function Ht(t){return new m("WritableStreamDefaultWriter.prototype."+t+" can only be used on a WritableStreamDefaultWriter")}function qt(t){return new m("Cannot "+t+" a stream using a released writer")}function Xt(t){t.Vd=k((function(n,i){t.Wd=n,t.Ud=i,t.mf="pending"}))}function jt(t,n){Xt(t),Yt(t,n)}function Yt(t,n){x(t.Vd),t.Ud(n),t.Wd=void 0,t.Ud=void 0,t.mf="rejected"}function Kt(t){t.Wd(void 0),t.Wd=void 0,t.Ud=void 0,t.mf="resolved"}function Gt(t){t.gf=k((function(n,i){t.kf=n,t.Ef=i})),t.pf="pending"}function $t(t,n){Gt(t),Jt(t,n)}function Zt(t){Gt(t),Qt(t)}function Jt(t,n){x(t.gf),t.Ef(n),t.kf=void 0,t.Ef=void 0,t.pf="rejected"}function Qt(t){t.kf(void 0),t.kf=void 0,t.Ef=void 0,t.pf="fulfilled"}function tn(t){if("object"!==(void 0===t?"undefined":B(t))||null===t)return!1;try{return"boolean"==typeof t.aborted}catch(t){return!1}}var nn,en="undefined"!=typeof DOMException?DOMException:void 0,rn=function(t){if("function"!=typeof t&&"object"!==(void 0===t?"undefined":B(t)))return!1;try{return new t,!0}catch(t){return!1}}(en)?en:((nn=function(t,n){this.message=t||"",this.name=n||"Error",g.captureStackTrace&&g.captureStackTrace(this,this.constructor)}).prototype=p.create(g.prototype),p.defineProperty(nn.prototype,"constructor",{value:nn,writable:!0,configurable:!0}),nn);function on(t,n,i,e,o,u){var s=K(t),f=wt(n);t.Xd=!0;var c=!1,h=R(void 0);return k((function(a,v){var d,l,w,b;if(void 0!==u){if(d=function(){var i=new rn("Aborted","AbortError"),r=[];!1===e&&r.push((function(){return"writable"===n.Fa?pt(n,i):R(void 0)})),!1===o&&r.push((function(){return"readable"===t.Fa?Zn(t,i):R(void 0)})),_((function(){return J.all(r.map((function(t){return t()})))}),!0,i)},!0===u.aborted)return void d();u.addEventListener("abort",d)}if(y(t,s.Vd,(function(t){!1===e?_((function(){return pt(n,t)}),!0,t):S(!0,t)})),y(n,f.Vd,(function(n){!1===o?_((function(){return Zn(t,n)}),!0,n):S(!0,n)})),l=t,w=s.Vd,b=function(){!1===i?_((function(){return function(t){var n=t.vf,i=n.Fa;return!0===Et(n)||"closed"===i?R(void 0):"errored"===i?O(n.Fd):Nt(t)}(f)})):S()},"closed"===l.Fa?b():A(w,b),!0===Et(n)||"closed"===n.Fa){var g=new m("the destination writable stream closed before all data could be piped to it");!1===o?_((function(){return Zn(t,g)}),!0,g):S(!0,g)}function p(){var t=h;return N(h,(function(){return t!==h?p():void 0}))}function y(t,n,i){"errored"===t.Fa?i(t.Fd):D(n,i)}function _(t,i,e){function r(){P(t(),(function(){return T(i,e)}),(function(t){return T(!0,t)}))}!0!==c&&(c=!0,"writable"===n.Fa&&!1===Et(n)?A(p(),r):r())}function S(t,i){!0!==c&&(c=!0,"writable"===n.Fa&&!1===Et(n)?A(p(),(function(){return T(t,i)})):T(t,i))}function T(t,n){Dt(f),z(s),void 0!==u&&u.removeEventListener("abort",d),t?v(n):a(void 0)}x(k((function(t,n){!function i(e){e?t():N(!0===c?R(!0):N(f.gf,(function(){return N(rt(s),(function(t){return!0===t.done||(h=N(Ct(f,t.value),void 0,r),!1)}))})),i,n)}(!1)})))}))}var un=function(){function t(){throw new m}return p.defineProperty(t.prototype,"desiredSize",{get:function(){if(!1===sn(this))throw gn("desiredSize");return ln(this)},enumerable:!0,configurable:!0}),t.prototype.close=function(){if(!1===sn(this))throw gn("close");if(!1===wn(this))throw new m("The stream is not in a state that permits close");an(this)},t.prototype.enqueue=function(t){if(!1===sn(this))throw gn("enqueue");if(!1===wn(this))throw new m("The stream is not in a state that permits enqueue");return vn(this,t)},t.prototype.error=function(t){if(!1===sn(this))throw gn("error");dn(this,t)},t.prototype[j]=function(t){at(this);var n=this.xf(t);return hn(this),n},t.prototype[Y]=function(){var t=this.If;if(this.Kd.length>0){var n=ct(this);return!0===this.Rf&&0===this.Kd.length?(hn(this),Jn(t)):fn(this),R(L(n,!1,t.Od.Ld))}var i=G(t);return fn(this),i},t}();function sn(t){return!!s(t)&&!!p.prototype.hasOwnProperty.call(t,"If")}function fn(t){!1!==cn(t)&&(!0!==t.Cf?(t.Cf=!0,P(t.Pf(),(function(){t.Cf=!1,!0===t.Df&&(t.Df=!1,fn(t))}),(function(n){dn(t,n)}))):t.Df=!0)}function cn(t){var n=t.If;return!1!==wn(t)&&!1!==t._f&&(!0===$n(n)&&Z(n)>0||ln(t)>0)}function hn(t){t.Pf=void 0,t.xf=void 0,t.wf=void 0}function an(t){var n=t.If;t.Rf=!0,0===t.Kd.length&&(hn(t),Jn(n))}function vn(t,n){var i=t.If;if(!0===$n(i)&&Z(i)>0)$(i,n,!1);else{var e=void 0;try{e=t.wf(n)}catch(n){throw dn(t,n),n}try{ht(t,n,e)}catch(n){throw dn(t,n),n}}fn(t)}function dn(t,n){var i=t.If;"readable"===i.Fa&&(at(t),hn(t),Qn(i,n))}function ln(t){var n=t.If.Fa;return"errored"===n?null:"closed"===n?0:t.Af-t.Qd}function wn(t){var n=t.If.Fa;return!1===t.Rf&&"readable"===n}function bn(t,n,i,e,r,o,u){n.If=t,n.Kd=void 0,n.Qd=void 0,at(n),n._f=!1,n.Rf=!1,n.Df=!1,n.Cf=!1,n.wf=u,n.Af=o,n.Pf=e,n.xf=r,t.zd=n,P(R(i()),(function(){n._f=!0,fn(n)}),(function(t){dn(n,t)}))}function gn(t){return new m("ReadableStreamDefaultController.prototype."+t+" can only be used on a ReadableStreamDefaultController")}var mn=Number.isInteger||function(t){return"number"==typeof t&&isFinite(t)&&y.floor(t)===t},pn=function(){function t(){throw new m("ReadableStreamBYOBRequest cannot be used directly")}return p.defineProperty(t.prototype,"view",{get:function(){if(!1===Sn(this))throw Un("view");return this.Nf},enumerable:!0,configurable:!0}),t.prototype.respond=function(t){if(!1===Sn(this))throw Un("respond");if(void 0===this.Mf)throw new m("This BYOB request has been invalidated");this.Nf.buffer,function(t,n){if(!1===h(n=Number(n)))throw new RangeError("bytesWritten must be a finite");Dn(t,n)}(this.Mf,t)},t.prototype.respondWithNewView=function(t){if(!1===Sn(this))throw Un("respond");if(void 0===this.Mf)throw new m("This BYOB request has been invalidated");if(!ArrayBuffer.isView(t))throw new m("You can only respond with array buffer views");t.buffer,function(t,n){var i=t.Lf.peek();if(i.byteOffset+i.bytesFilled!==n.byteOffset)throw new RangeError("The region specified by view does not match byobRequest");if(i.byteLength!==n.byteLength)throw new RangeError("The buffer of view has different capacity than byobRequest");i.buffer=n.buffer,Dn(t,n.byteLength)}(this.Mf,t)},t}(),yn=function(){function t(){throw new m("ReadableByteStreamController constructor cannot be used directly")}return p.defineProperty(t.prototype,"byobRequest",{get:function(){if(!1===_n(this))throw Fn("byobRequest");if(void 0===this.Bf&&this.Lf.length>0){var t=this.Lf.peek(),n=new E(t.buffer,t.byteOffset+t.bytesFilled,t.byteLength-t.bytesFilled),i=p.create(pn.prototype);!function(t,n,i){t.Mf=n,t.Nf=i}(i,this,n),this.Bf=i}return this.Bf},enumerable:!0,configurable:!0}),p.defineProperty(t.prototype,"desiredSize",{get:function(){if(!1===_n(this))throw Fn("desiredSize");return Mn(this)},enumerable:!0,configurable:!0}),t.prototype.close=function(){if(!1===_n(this))throw Fn("close");if(!0===this.Rf)throw new m("The stream has already been closed; do not close it again!");var t=this.Of.Fa;if("readable"!==t)throw new m("The stream (in "+t+" state) is not in the readable state and cannot be closed");!function(t){var n=t.Of;if(t.Qd>0)t.Rf=!0;else{if(t.Lf.length>0&&t.Lf.peek().bytesFilled>0){var i=new m("Insufficient bytes to fill elements in the given buffer");throw Bn(t,i),i}xn(t),Jn(n)}}(this)},t.prototype.enqueue=function(t){if(!1===_n(this))throw Fn("enqueue");if(!0===this.Rf)throw new m("stream is closed or draining");var n=this.Of.Fa;if("readable"!==n)throw new m("The stream (in "+n+" state) is not in the readable state and cannot be enqueued to");if(!ArrayBuffer.isView(t))throw new m("You can only enqueue array buffer views when using a ReadableByteStreamController");t.buffer,function(t,n){var i=t.Of,e=n.buffer,r=n.byteOffset,o=n.byteLength,u=e;!0===Q(i)?0===Z(i)?kn(t,u,r,o):$(i,new E(u,r,o),!1):!0===Vn(i)?(kn(t,u,r,o),An(t)):kn(t,u,r,o),Tn(t)}(this,t)},t.prototype.error=function(t){if(!1===_n(this))throw Fn("error");Bn(this,t)},t.prototype[j]=function(t){this.Lf.length>0&&(this.Lf.peek().bytesFilled=0),at(this);var n=this.xf(t);return xn(this),n},t.prototype[Y]=function(){var t=this.Of;if(this.Qd>0){var n=this.Kd.shift();this.Qd-=n.byteLength,Nn(this);var i=void 0;try{i=new E(n.buffer,n.byteOffset,n.byteLength)}catch(t){return O(t)}return R(L(i,!1,t.Od.Ld))}var e=this.Ff;if(void 0!==e){var r=void 0;try{r=new ArrayBuffer(e)}catch(t){return O(t)}var o={buffer:r,byteOffset:0,byteLength:e,bytesFilled:0,elementSize:1,ctor:E,readerType:"default"};this.Lf.push(o)}var u=G(t);return Tn(this),u},t}();function _n(t){return!!s(t)&&!!p.prototype.hasOwnProperty.call(t,"Of")}function Sn(t){return!!s(t)&&!!p.prototype.hasOwnProperty.call(t,"Mf")}function Tn(t){var n=function(t){var n=t.Of;if("readable"!==n.Fa)return!1;if(!0===t.Rf)return!1;if(!1===t._f)return!1;if(!0===Q(n)&&Z(n)>0)return!0;if(!0===Vn(n)&&Wn(n)>0)return!0;var i=Mn(t);return i>0}(t);!1!==n&&(!0!==t.Cf?(t.Cf=!0,P(t.Pf(),(function(){t.Cf=!1,!0===t.Df&&(t.Df=!1,Tn(t))}),(function(n){Bn(t,n)}))):t.Df=!0)}function En(t,n){var i=!1;"closed"===t.Fa&&(i=!0);var e=In(n);"default"===n.readerType?$(t,e,i):function(t,n,i){var e=t.Od,r=e.Vf.shift();r.Gd(L(n,i,e.Ld))}(t,e,i)}function In(t){var n=t.bytesFilled,i=t.elementSize;return new t.ctor(t.buffer,t.byteOffset,n/i)}function kn(t,n,i,e){t.Kd.push({buffer:n,byteOffset:i,byteLength:e}),t.Qd+=e}function Rn(t,n){var i=n.elementSize,e=n.bytesFilled-n.bytesFilled%i,r=y.min(t.Qd,n.byteLength-n.bytesFilled),o=n.bytesFilled+r,u=o-o%i,s=r,f=!1;u>e&&(s=u-n.bytesFilled,f=!0);for(var h=t.Kd;s>0;){var a=h.peek(),v=y.min(s,a.byteLength),d=n.byteOffset+n.bytesFilled;c(n.buffer,d,a.buffer,a.byteOffset,v),a.byteLength===v?h.shift():(a.byteOffset+=v,a.byteLength-=v),t.Qd-=v,On(t,v,n),s-=v}return f}function On(t,n,i){Pn(t),i.bytesFilled+=n}function Nn(t){0===t.Qd&&!0===t.Rf?(xn(t),Jn(t.Of)):Tn(t)}function Pn(t){void 0!==t.Bf&&(t.Bf.Mf=void 0,t.Bf.Nf=void 0,t.Bf=void 0)}function An(t){for(;t.Lf.length>0;){if(0===t.Qd)return;var n=t.Lf.peek();!0===Rn(t,n)&&(Cn(t),En(t.Of,n))}}function Dn(t,n){var i=t.Lf.peek();if("closed"===t.Of.Fa){if(0!==n)throw new m("bytesWritten must be 0 when calling respond() on a closed stream");!function(t,n){n.buffer=n.buffer;var i=t.Of;if(!0===Vn(i))for(;Wn(i)>0;)En(i,Cn(t))}(t,i)}else!function(t,n,i){if(i.bytesFilled+n>i.byteLength)throw new RangeError("bytesWritten out of range");if(On(t,n,i),!(i.bytesFilled<i.elementSize)){Cn(t);var e=i.bytesFilled%i.elementSize;if(e>0){var r=i.byteOffset+i.bytesFilled,o=i.buffer.slice(r-e,r);kn(t,o,0,o.byteLength)}i.buffer=i.buffer,i.bytesFilled-=e,En(t.Of,i),An(t)}}(t,n,i);Tn(t)}function Cn(t){var n=t.Lf.shift();return Pn(t),n}function xn(t){t.Pf=void 0,t.xf=void 0}function Bn(t,n){var i=t.Of;"readable"===i.Fa&&(function(t){Pn(t),t.Lf=new M}(t),at(t),xn(t),Qn(i,n))}function Mn(t){var n=t.Of.Fa;return"errored"===n?null:"closed"===n?0:t.Af-t.Qd}function Ln(t,n,i){var e=p.create(yn.prototype),r=v(n,"pull",0,[e]),o=v(n,"cancel",1,[]),u=n.autoAllocateChunkSize;if(void 0!==u&&(u=Number(u),!1===mn(u)||u<=0))throw new RangeError("autoAllocateChunkSize must be a positive integer");!function(t,n,i,e,r,o,u){n.Of=t,n.Df=!1,n.Cf=!1,n.Bf=void 0,n.Kd=n.Qd=void 0,at(n),n.Rf=!1,n._f=!1,n.Af=w(o),n.Pf=e,n.xf=r,n.Ff=u,n.Lf=new M,t.zd=n,P(R(i()),(function(){n._f=!0,Tn(n)}),(function(t){Bn(n,t)}))}(t,e,(function(){return d(n,"start",[e])}),r,o,i,u)}function Un(t){return new m("ReadableStreamBYOBRequest.prototype."+t+" can only be used on a ReadableStreamBYOBRequest")}function Fn(t){return new m("ReadableByteStreamController.prototype."+t+" can only be used on a ReadableByteStreamController")}function zn(t){return k((function(n,i){var e={Gd:n,Zd:i};t.Od.Vf.push(e)}))}function Wn(t){return t.Od.Vf.length}function Vn(t){var n=t.Od;return void 0!==n&&!!qn(n)}var Hn=function(){function t(t){if(!Gn(t))throw new m("ReadableStreamBYOBReader can only be constructed with a ReadableStream instance given a byte source");if(!1===_n(t.zd))throw new m("Cannot construct a ReadableStreamBYOBReader for a stream not constructed with a byte source");if($n(t))throw new m("This stream has already been locked for exclusive reading by another reader");U(this,t),this.Vf=new M}return p.defineProperty(t.prototype,"closed",{get:function(){return qn(this)?this.Vd:O(Xn("closed"))},enumerable:!0,configurable:!0}),t.prototype.cancel=function(t){return qn(this)?void 0===this.Bd?O(W("cancel")):F(this,t):O(Xn("cancel"))},t.prototype.read=function(t){return qn(this)?void 0===this.Bd?O(W("read from")):ArrayBuffer.isView(t)?(t.buffer,0===t.byteLength?O(new m("view must have non-zero byteLength")):function(t,n){var i=t.Bd;return i.Xd=!0,"errored"===i.Fa?O(i.Fd):function(t,n){var i=t.Of,e=1;n.constructor!==DataView&&(e=n.constructor.BYTES_PER_ELEMENT);var r=n.constructor,o={buffer:n.buffer,byteOffset:n.byteOffset,byteLength:n.byteLength,bytesFilled:0,elementSize:e,ctor:r,readerType:"byob"};if(t.Lf.length>0)return t.Lf.push(o),zn(i);if("closed"===i.Fa)return R(L(new r(o.buffer,o.byteOffset,0),!0,i.Od.Ld));if(t.Qd>0){if(!0===Rn(t,o)){var u=In(o);return Nn(t),R(L(u,!1,i.Od.Ld))}if(!0===t.Rf){var s=new m("Insufficient bytes to fill elements in the given buffer");return Bn(t,s),O(s)}}t.Lf.push(o);var f=zn(i);return Tn(t),f}(i.zd,n)}(this,t)):O(new m("view must be an array buffer view")):O(Xn("read"))},t.prototype.releaseLock=function(){if(!qn(this))throw Xn("releaseLock");if(void 0!==this.Bd){if(this.Vf.length>0)throw new m("Tried to release a reader lock when that reader has pending read() calls un-settled");z(this)}},t}();function qn(t){return!!s(t)&&!!p.prototype.hasOwnProperty.call(t,"Vf")}function Xn(t){return new m("ReadableStreamBYOBReader.prototype."+t+" can only be used on a ReadableStreamBYOBReader")}var jn=function(){function t(t,n){void 0===t&&(t={}),void 0===n&&(n={}),Kn(this);var i=n.size,e=n.highWaterMark,r=t.type;if("bytes"===String(r)){if(void 0!==i)throw new RangeError("The strategy for a byte stream cannot have a size function");void 0===e&&(e=0),Ln(this,t,e=w(e))}else{if(void 0!==r)throw new RangeError("Invalid type is specified");var o=b(i);void 0===e&&(e=1),function(t,n,i,e){var r=p.create(un.prototype),o=v(n,"pull",0,[r]),u=v(n,"cancel",1,[]);bn(t,r,(function(){return d(n,"start",[r])}),o,u,i,e)}(this,t,e=w(e),o)}}return p.defineProperty(t.prototype,"locked",{get:function(){if(!1===Gn(this))throw ti("locked");return $n(this)},enumerable:!0,configurable:!0}),t.prototype.cancel=function(t){return!1===Gn(this)?O(ti("cancel")):!0===$n(this)?O(new m("Cannot cancel a stream that already has a reader")):Zn(this,t)},t.prototype.getReader=function(t){var n=(void 0===t?{}:t).mode;if(!1===Gn(this))throw ti("getReader");if(void 0===n)return K(this,!0);if("byob"===(n=String(n)))return function(t,n){void 0===n&&(n=!1);var i=new Hn(t);return i.Ld=n,i}(this,!0);throw new RangeError("Invalid mode is specified")},t.prototype.pipeThrough=function(t,n){var i=t.writable,e=t.readable,r=void 0===n?{}:n,o=r.preventClose,u=r.preventAbort,s=r.preventCancel,f=r.signal;if(!1===Gn(this))throw ti("pipeThrough");if(!1===gt(i))throw new m("writable argument to pipeThrough must be a WritableStream");if(!1===Gn(e))throw new m("readable argument to pipeThrough must be a ReadableStream");if(o=Boolean(o),u=Boolean(u),s=Boolean(s),void 0!==f&&!tn(f))throw new m("ReadableStream.prototype.pipeThrough's signal option must be an AbortSignal");if(!0===$n(this))throw new m("ReadableStream.prototype.pipeThrough cannot be used on a locked ReadableStream");if(!0===mt(i))throw new m("ReadableStream.prototype.pipeThrough cannot be used on a locked WritableStream");return x(on(this,i,o,u,s,f)),e},t.prototype.pipeTo=function(t,n){var i=void 0===n?{}:n,e=i.preventClose,r=i.preventAbort,o=i.preventCancel,u=i.signal;return!1===Gn(this)?O(ti("pipeTo")):!1===gt(t)?O(new m("ReadableStream.prototype.pipeTo's first argument must be a WritableStream")):(e=Boolean(e),r=Boolean(r),o=Boolean(o),void 0===u||tn(u)?!0===$n(this)?O(new m("ReadableStream.prototype.pipeTo cannot be used on a locked ReadableStream")):!0===mt(t)?O(new m("ReadableStream.prototype.pipeTo cannot be used on a locked WritableStream")):on(this,t,e,r,o,u):O(new m("ReadableStream.prototype.pipeTo's signal option must be an AbortSignal")))},t.prototype.tee=function(){if(!1===Gn(this))throw ti("tee");var t=function(t,n){var i,e,r,o,u,s=K(t),c=!1,h=!1,a=!1,v=k((function(t){u=t}));function d(){return!0===c||(c=!0,x(C(rt(s),(function(t){if(c=!1,!0===t.done)return!1===h&&an(r.zd),void(!1===a&&an(o.zd));var n=t.value,i=n,e=n;!1===h&&vn(r.zd,i),!1===a&&vn(o.zd,e)})))),R(void 0)}function l(){}return r=Yn(l,d,(function(n){if(h=!0,i=n,!0===a){var r=f([i,e]),o=Zn(t,r);u(o)}return v})),o=Yn(l,d,(function(n){if(a=!0,e=n,!0===h){var r=f([i,e]),o=Zn(t,r);u(o)}return v})),D(s.Vd,(function(t){dn(r.zd,t),dn(o.zd,t)})),[r,o]}(this);return f(t)},t.prototype.getIterator=function(t){var n=(void 0===t?{}:t).preventCancel,i=void 0!==n&&n;if(!1===Gn(this))throw ti("getIterator");return function(t,n){void 0===n&&(n=!1);var i=K(t),e=p.create(ut);return e.qd=i,e.Yd=Boolean(n),e}(this,i)},t}();function Yn(t,n,i,e,r){void 0===e&&(e=1),void 0===r&&(r=function(){return 1});var o=p.create(jn.prototype);return Kn(o),bn(o,p.create(un.prototype),t,n,i,e,r),o}function Kn(t){t.Fa="readable",t.Od=void 0,t.Fd=void 0,t.Xd=!1}function Gn(t){return!!s(t)&&!!p.prototype.hasOwnProperty.call(t,"zd")}function $n(t){return void 0!==t.Od}function Zn(t,n){return t.Xd=!0,"closed"===t.Fa?R(void 0):"errored"===t.Fa?O(t.Fd):(Jn(t),C(t.zd[j](n),r))}function Jn(t){t.Fa="closed";var n=t.Od;void 0!==n&&(et(n)&&(n.Hd.forEach((function(t){t.Gd(L(void 0,!0,n.Ld))})),n.Hd=new M),X(n))}function Qn(t,n){t.Fa="errored",t.Fd=n;var i=t.Od;void 0!==i&&(et(i)?(i.Hd.forEach((function(t){t.Zd(n)})),i.Hd=new M):(i.Vf.forEach((function(t){t.Zd(n)})),i.Vf=new M),q(i,n))}function ti(t){return new m("ReadableStream.prototype."+t+" can only be used on a ReadableStream")}"symbol"===B(i.asyncIterator)&&p.defineProperty(jn.prototype,i.asyncIterator,{value:jn.prototype.getIterator,enumerable:!1,writable:!0,configurable:!0});var ni=function(){function t(t){var n=t.highWaterMark;this.highWaterMark=n}return t.prototype.size=function(t){return t.byteLength},t}(),ii=function(){function t(t){var n=t.highWaterMark;this.highWaterMark=n}return t.prototype.size=function(){return 1},t}(),ei=function(){function t(t,n,i){void 0===t&&(t={}),void 0===n&&(n={}),void 0===i&&(i={});var e=n.size,r=n.highWaterMark,o=i.size,u=i.highWaterMark;if(void 0!==t.writableType)throw new RangeError("Invalid writable type specified");var s=b(e);if(void 0===r&&(r=1),r=w(r),void 0!==t.readableType)throw new RangeError("Invalid readable type specified");var f,c=b(o);void 0===u&&(u=0),u=w(u),function(t,n,i,e,r,o){function u(){return n}function s(n){return function(t,n){var i=t.Wf;return!0===t.uf?C(t.Uf,(function(){var e=t.Gf;if("erroring"===e.Fa)throw e.Fd;return vi(i,n)})):vi(i,n)}(t,n)}function f(n){return function(t,n){return oi(t,n),R(void 0)}(t,n)}function c(){return function(t){var n=t.Zf,i=t.Wf,e=i.Hf();return hi(i),C(e,(function(){if("errored"===n.Fa)throw n.Fd;var t=n.zd;!0===wn(t)&&an(t)}),(function(i){throw oi(t,i),n.Fd}))}(t)}function h(){return function(t){return si(t,!1),t.Uf}(t)}function a(n){return ui(t,n),R(void 0)}t.Gf=function(t,n,i,e,r,o){void 0===r&&(r=1),void 0===o&&(o=function(){return 1});var u=p.create(lt.prototype);return bt(u),Bt(u,p.create(xt.prototype),t,n,i,e,r,o),u}(u,s,c,f,i,e),t.Zf=Yn(u,h,a,r,o),t.uf=void 0,t.Uf=void 0,t.Xf=void 0,si(t,!0),t.Wf=void 0}(this,k((function(t){f=t})),r,s,u,c),function(t,n){var i=p.create(fi.prototype),e=function(t){try{return ai(i,t),R(void 0)}catch(t){return O(t)}},r=n.transform;if(void 0!==r){if("function"!=typeof r)throw new m("transform is not a method");e=function(t){return l(r,n,[t,i])}}var o=v(n,"flush",0,[i]);!function(t,n,i,e){n.zf=t,t.Wf=n,n.qf=i,n.Hf=e}(t,i,e,o)}(this,t);var h=d(t,"start",[this.Wf]);f(h)}return p.defineProperty(t.prototype,"readable",{get:function(){if(!1===ri(this))throw li("readable");return this.Zf},enumerable:!0,configurable:!0}),p.defineProperty(t.prototype,"writable",{get:function(){if(!1===ri(this))throw li("writable");return this.Gf},enumerable:!0,configurable:!0}),t}();function ri(t){return!!s(t)&&!!p.prototype.hasOwnProperty.call(t,"Wf")}function oi(t,n){dn(t.Zf.zd,n),ui(t,n)}function ui(t,n){hi(t.Wf),Ft(t.Gf.$d,n),!0===t.uf&&si(t,!1)}function si(t,n){void 0!==t.Uf&&t.Xf(),t.Uf=k((function(n){t.Xf=n})),t.uf=n}var fi=function(){function t(){throw new m("TransformStreamDefaultController instances cannot be created directly")}return p.defineProperty(t.prototype,"desiredSize",{get:function(){if(!1===ci(this))throw di("desiredSize");return ln(this.zf.Zf.zd)},enumerable:!0,configurable:!0}),t.prototype.enqueue=function(t){if(!1===ci(this))throw di("enqueue");ai(this,t)},t.prototype.error=function(t){if(!1===ci(this))throw di("error");!function(t,n){oi(t.zf,n)}(this,t)},t.prototype.terminate=function(){if(!1===ci(this))throw di("terminate");!function(t){var n=t.zf,i=n.Zf.zd;!0===wn(i)&&an(i);var e=new m("TransformStream terminated");ui(n,e)}(this)},t}();function ci(t){return!!s(t)&&!!p.prototype.hasOwnProperty.call(t,"zf")}function hi(t){t.qf=void 0,t.Hf=void 0}function ai(t,n){var i=t.zf,e=i.Zf.zd;if(!1===wn(e))throw new m("Readable side is not in a state that permits enqueue");try{vn(e,n)}catch(t){throw ui(i,t),i.Zf.Fd}var r=function(t){return!0!==cn(t)}(e);r!==i.uf&&si(i,!0)}function vi(t,n){return C(t.qf(n),void 0,(function(n){throw oi(t.zf,n),n}))}function di(t){return new m("TransformStreamDefaultController.prototype."+t+" can only be used on a TransformStreamDefaultController")}function li(t){return new m("TransformStream.prototype."+t+" can only be used on a TransformStream")}t.ByteLengthQueuingStrategy=ni,t.CountQueuingStrategy=ii,t.ReadableStream=jn,t.TransformStream=ei,t.WritableStream=lt,p.defineProperty(t,"__esModule",{value:!0})},"object"===(void 0===t?"undefined":B(t))&&void 0!==i?o(t):"function"==typeof define&&define.amd?define(["exports"],o):o((r=r||self).WebStreamsPolyfill={})})),pt=C((function(t){function n(){var t=mt();return n=function(){return t},t}x(),gt(),p.defineProperty(t,"__esModule",{value:!0}),function(t,n){for(var i in n)p.defineProperty(t,i,{enumerable:!0,get:n[i]})}(t,{ByteLengthQueuingStrategy:function(){return n().ByteLengthQueuingStrategy},CountQueuingStrategy:function(){return n().CountQueuingStrategy},ReadableStream:function(){return n().ReadableStream},TransformStream:function(){return n().TransformStream},WritableStream:function(){return n().WritableStream}})}));function yt(t,n){return(yt=p.setPrototypeOf||function(t,n){return t.__proto__=n,t})(t,n)}function _t(t,n){if("function"!=typeof n&&null!==n)throw new m("Super expression must either be null or a function");t.prototype=p.create(n&&n.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),n&&yt(t,n)}function St(t,n){for(var i=0;i<n.length;i++){var e=n[i];e.enumerable=e.enumerable||!1,e.configurable=!0,"value"in e&&(e.writable=!0),p.defineProperty(t,e.key,e)}}function Tt(t,n,i){return n&&St(t.prototype,n),i&&St(t,i),t}x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt();var Et,It=((Et={}).Tv="web",Et.Ev="android",Et.xv="android-tv",Et.Iv="ios",Et.Rv="tvos",Et.Cv="chromecast",Et.Pv="theoliveweb",Et);var kt=v?v.userAgent:"",Rt=kt.match(/chrome\/([0-9]+)\.([0-9]+)\.([0-9]+)\.([0-9]+)/i),Ot=kt.match(/Edg\/([0-9]+)\.([0-9]+)\.([0-9]+)\.([0-9]+)/i),Nt=kt.match(/Android ([0-9\.]+)/i),Pt=kt.match(/Windows NT ([0-9\.]+)/i),At=kt.match(/(Version)\/((\d+)\.(\d+)(?:\.(\d+))?).*Safari/),Dt=kt.match(/Firefox\/([0-9\.]+)/i),Ct=kt.match(/OPR\/(\d+\.\d+)/i),xt=kt.match(/Tizen ([0-9\.]+)/i),Bt=kt.match(/(iPhone OS|iPad OS|iPod OS|Mac OS X) (\d+)_(\d+)_?(\d+)?/),Mt=kt.match(/HbbTV\/([0-9.]+)/i),Lt=function(){function t(){this.Dv=Boolean("ontouchstart"in self||self.DocumentTouch&&a instanceof self.DocumentTouch||v&&v.msMaxTouchPoints),this.Mv=/(mac\sos\sx)\s?([\w\s\.]+\w)*/i.test(kt)||/(macintosh|mac(?=_powerpc)\s)/i.test(kt),this.Bv=/Windows NT/i.test(kt),this.Fv=Pt?S(Pt[1]):0,this.Wv=/Android/i.test(kt),this.Gv=Nt?S(Nt[1]):0,this.Hv=/windows phone (8|8\.1)/i.test(kt),this.zv=/iPhone/i.test(kt),this.Yv=/iPad/i.test(kt),this.Qv=this.Mv&&this.Dv&&!this.Yv,this.$v=/iPod/i.test(kt),this.dg=/Mobile Safari/i.test(kt),this.ag=/EOS\d*STB/i.test(kt),this.cg=/APP\d*STB/i.test(kt),this.eg=(this.zv||this.Yv||this.Qv||this.$v)&&!this.Hv,this.og=Bt?S(Bt[2]):0,this.fg=this.Hv||this.eg||this.Wv||this.dg,this.vg=/CriOS/i.test(kt),this.pg=Boolean(self.chrome&&/google/i.test(v.vendor))||this.vg,this.Tg=this.pg&&/Edg\//i.test(v.userAgent),this.xg=Ot?_(Ot[1],10):0,this.Fm=Boolean(/CriOS/i.test(kt)),this.Om=Boolean(self.chrome||/Chrome/i.test(kt)||this.Fm),this.Ag=Rt?_(Rt[1],10):0,this.Cg=/SMART-TV.*Tizen/i.test(kt),this.Dg=xt?S(xt[1]):0,this.yg=this.Dg>0?function(t){return t>=8?108:t>=7?94:t>=6.5?85:t>=6?76:t>=5.5?69:t>=5?63:t>=4?56:t>=3?47:0}(this.Dg):void 0,this.Mg=/webos|web0s/i.test(kt),this.Bg=/HbbTV/i.test(kt),this.Fg=!!Mt&&function(t){if(!t)return!1;var n=t.split(".").map(Number);return 3===n.length&&1===n[0]&&2===n[1]}(Mt[1]),this.Wg=/VIZIO/i.test(kt),this.Gg=/Edge\/\d+/i.test(kt),this.Hg=/Trident/i.test(kt),this.zg=this.Hg&&!self.ActiveXObject&&"ActiveXObject"in self,this.Yg=/Vivaldi/i.test(kt),this.jg=/Firefox/i.test(kt)&&!/Seamonkey/i.test(kt),this.Jg=Dt?S(Dt[1]):0,this.im=/Safari/i.test(kt)&&!/Chrome/i.test(kt)&&!this.Hv&&!this.Cg,this.hm=At?S(At[2]):0,this.lm=Boolean(Ct),this.fm=Ct?S(Ct[1]):0,this.vm=/CrKey/.test(kt),this.pm=/\b(tv|smart-tv|smarttv|appletv|crkey|googletv|hbbtv|pov_tv|roku|viera|nettv|philipstv|vizio)\b/i.test(kt),this.Am=/PlayStation 4/i.test(kt),this.Tm="web"===It.xv,this.xm="web"===It.Ev,this.Rm=this.xm||this.Tm,this.Pm="web"===It.Iv,this.Nm="web"===It.Rv,this.Lm="web"===It.Cv}return Tt(t,[{key:"Qe",get:function(){return this.Dv}},{key:"Nv",get:function(){return this.Mv}},{key:"Lv",get:function(){return this.Bv}},{key:"Ov",get:function(){return this.Fv}},{key:"Vv",get:function(){return this.Wv}},{key:"Uv",get:function(){return this.Gv}},{key:"Zv",get:function(){return this.Hv}},{key:"Xv",get:function(){return this.zv}},{key:"qv",get:function(){return this.Yv}},{key:"Kv",get:function(){return this.Qv}},{key:"Jv",get:function(){return this.$v}},{key:"su",get:function(){return this.eg}},{key:"rg",get:function(){return this.og}},{key:"hg",get:function(){return this.ag||this.cg}},{key:"ud",get:function(){return this.dg}},{key:"Qs",get:function(){return this.fg}},{key:"_g",get:function(){return this.vg}},{key:"gg",get:function(){return this.pg}},{key:"wg",get:function(){var t;return null!=(t=this.yg)?t:this.Ag}},{key:"Sg",get:function(){return this.Tg}},{key:"Eg",get:function(){var t;return(null==(t=h.chrome)?void 0:t.webview)&&this.xg>0}},{key:"Ig",get:function(){return this.xg}},{key:"Rg",get:function(){return this.Cg}},{key:"Pg",get:function(){return this.Dg}},{key:"Ng",get:function(){return this.Mg}},{key:"Lg",get:function(){return this.Bg}},{key:"Og",get:function(){return this.Fg}},{key:"Vg",get:function(){return this.Wg}},{key:"Ug",get:function(){return this.Gg}},{key:"Zg",get:function(){return this.Hg}},{key:"Xg",get:function(){return this.zg}},{key:"qg",get:function(){return this.Yg}},{key:"Kg",get:function(){return this.jg}},{key:"Qg",get:function(){return this.Jg}},{key:"$g",get:function(){return this.im}},{key:"nm",get:function(){return 0===this.hm&&Ut.su?this.og:this.hm}},{key:"um",get:function(){return this.lm}},{key:"dm",get:function(){return this.fm}},{key:"_m",get:function(){return this.vm}},{key:"gm",get:function(){return this.pm}},{key:"wm",get:function(){return!(!this.Ng&&!this.Rg)&&this.wg<=56}},{key:"ym",get:function(){return this.Am}},{key:"Sm",get:function(){return this.Tm}},{key:"Em",get:function(){return this.xm}},{key:"Im",get:function(){return this.Rm}},{key:"Cm",get:function(){return this.Pm}},{key:"Dm",get:function(){return this.Nm}},{key:"Mm",get:function(){return this.Lm}},{key:"Bm",get:function(){return this.Om}},{key:"IS_IOS_CHROME",get:function(){return this.Fm}}]),t}();Lt.Vm=new Lt;var Ut=Lt.Vm;x(),gt(),nt();var Ft={}.toString;function zt(t){return null!=t}var Wt,Vt=Array.isArray||function(t){return"[object Array]"===Ft.call(t)};function Ht(t){return"object"===(void 0===t?"undefined":B(t))&&null!==t}function qt(t){return"function"==typeof t}function Xt(t){return qt(t)||Ht(t)}function jt(t){Wt=t}x(),gt(),x(),gt();var Yt=function(){};function Kt(t){var n;return function(){return void 0!==t&&(n=t(),t=void 0),n}}function Gt(t,n,i,e,r,o,u){try{var s=t[o](u),f=s.value}catch(t){return void i(t)}s.done?n(f):J.resolve(f).then(e,r)}function $t(t){return function(){var n=this,i=arguments;return new J((function(e,r){var o=t.apply(n,i);function u(t){Gt(o,e,r,u,s,"next",t)}function s(t){Gt(o,e,r,u,s,"throw",t)}u(void 0)}))}}function Zt(t,i){var r,o,u,s={label:0,sent:function(){if(1&u[0])throw u[1];return u[1]},trys:[],ops:[]},f=p.create(("function"==typeof Iterator?Iterator:p).prototype);return f.next=c(0),f.throw=c(1),f.return=c(2),"function"==typeof n&&(f[e]=function(){return this}),f;function c(n){return function(e){return function(n){if(r)throw new m("Generator is already executing.");for(;f&&(f=0,n[0]&&(s=0)),s;)try{if(r=1,o&&(u=2&n[0]?o.return:n[0]?o.throw||((u=o.return)&&u.call(o),0):o.next)&&!(u=u.call(o,n[1])).done)return u;switch(o=0,u&&(n=[2&n[0],u.value]),n[0]){case 0:case 1:u=n;break;case 4:return s.label++,{value:n[1],done:!1};case 5:s.label++,o=n[1],n=[0];continue;case 7:n=s.ops.pop(),s.trys.pop();continue;default:if(!(u=s.trys,(u=u.length>0&&u[u.length-1])||6!==n[0]&&2!==n[0])){s=0;continue}if(3===n[0]&&(!u||n[1]>u[0]&&n[1]<u[3])){s.label=n[1];break}if(6===n[0]&&s.label<u[1]){s.label=u[1],u=n;break}if(u&&s.label<u[2]){s.label=u[2],s.ops.push(n);break}u[2]&&s.ops.pop(),s.trys.pop();continue}n=i.call(t,s)}catch(t){n=[6,t],o=0}finally{r=u=0}if(5&n[0])throw n[1];return{value:n[0]?n[1]:void 0,done:!0}}([n,e])}}}x(),gt(),x(),gt(),x(),gt(),x(),gt();var Jt="function"==typeof SuppressedError?SuppressedError:function(t,n,i){var e=new g(i);return e.name="SuppressedError",e.error=t,e.suppressed=n,e};function Qt(t,n){(null==n||n>t.length)&&(n=t.length);for(var i=0,e=new Array(n);i<n;i++)e[i]=t[i];return e}function tn(t,n){if(t){if("string"==typeof t)return Qt(t,n);var i=p.prototype.toString.call(t).slice(8,-1);return"Object"===i&&t.constructor&&(i=t.constructor.name),"Map"===i||"Set"===i?Array.from(i):"Arguments"===i||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?Qt(t,n):void 0}}function nn(t){return function(t){if(Array.isArray(t))return Qt(t)}(t)||function(t){if(void 0!==n&&null!=t[e]||null!=t["@@iterator"])return Array.from(t)}(t)||tn(t)||function(){throw new m("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt();var en=9007199254740991,rn=(y.pow(2,-52),Array.prototype.find,Array.prototype.findLast,"function"==typeof Array.prototype.findIndex?function(t,n){return t.findIndex(n)}:function(t,n){for(var i=0;i<t.length;i+=1){if(n(t[i],i,t))return i}return-1}),on="function"==typeof Array.prototype.findLastIndex?function(t,n){return t.findLastIndex(n)}:function(t,n){for(var i=t.length-1;i>=0;i-=1){if(n(t[i],i,t))return i}return-1};Array.prototype.at;function un(t,n){var i=t.indexOf(n);return-1!==i&&(function(t,n){0===n?t.shift():t.splice(n,1)}(t,i),!0)}function sn(t,n){for(var i=new Array(t.length),e=0,r=0;r<t.length;){if(t[r]===n){r++,i.length-=1;break}i[e++]=t[r++]}for(;r<t.length;)i[e++]=t[r++];return i}function fn(t,n){return-1!==t.indexOf(n)}function cn(t){t.length=0}Array.prototype.flat,Array.prototype.flatMap;var hn=function(){function t(){this.zm=!1,this.qm=!1,this.Ym=[],this.jm=[]}var n=t.prototype;return n.Xm=function(){if(!this.zm&&!this.qm){this.zm=!0;for(var t=0,n=this.Ym.slice();t<n.length;t++){(0,n[t])()}this.Km()}},n.Km=function(){if(!this.qm){this.qm=!0;for(var t=0,n=this.jm.slice();t<n.length;t++){(0,n[t])()}cn(this.Ym),cn(this.jm)}},n.Qm=function(t){this.qm||this.Ym.push(t)},n.Jm=function(t){this.qm||un(this.Ym,t)},n.$m=function(t){this.qm||this.jm.push(t)},n.tp=function(t){this.qm||un(this.jm,t)},t}(),an=function(){function t(){this.sp=new hn}var n=t.prototype;return n.np=function(){this.sp.Xm()},n.Km=function(){this.sp.Km()},n.rp=function(t){var n=this.sp;if(!n.zm)if(t.zm)n.Xm();else if(!n.qm&&!t.qm){var i=function(){e(),n.Xm()},e=function(){t.Jm(i),t.tp(e),n.Jm(i),n.tp(e)};t.Qm(i),t.$m(e),n.Qm(i),n.$m(e)}},n.op=function(){var n=new t,i=new t,e=n.ep,r=i.ep,o=this.sp,u=function(){e.zm&&r.qm||r.zm&&e.qm?o.Xm():e.qm&&r.qm&&o.Km()};e.Qm(u),r.Qm(u),e.$m(u),r.$m(u),n.rp(o),i.rp(o);return o.$m((function(){e.Jm(u),r.Jm(u),e.tp(u),r.tp(u)})),[n,i]},n[r]=function(){this.np()},t.hp=function(n){for(var i=new t,e=0;e<n.length;e++){var r=n[e];void 0!==r&&i.rp(r)}return i},Tt(t,[{key:"ep",get:function(){return this.sp}}]),t}();x(),gt(),x(),gt();var vn=function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];g.apply(this,n)};(vn.prototype=p.create(g.prototype)).constructor=vn;var dn=function(t){function n(n,i){var e;return(e=t.call(this)||this).message=n||"Unknown error",e.cause=i,g.captureStackTrace&&g.captureStackTrace(e,e.constructor),e}return _t(n,t),Tt(n,[{key:"name",get:function(){return"BaseError"}}]),n}(vn),ln=function(t){function n(n,i){return t.call(this,n||"Aborted",i)||this}return _t(n,t),Tt(n,[{key:"name",get:function(){return"AbortError"}}]),n}(dn);function wn(t){return t instanceof g&&"AbortError"===t.name}function bn(t,n){return n?new J((function(i,e){if(n.zm)return t.catch(Yt),e(new ln);var r=function(){n.Jm(r),e(new ln)};n.Qm(r),t.then((function(t){n.Jm(r),i(t)}),(function(t){n.Jm(r),e(t)}))})):t}function gn(t,n){return mn.apply(this,arguments)}function mn(){return mn=$t((function(t,n){var i,e;return Zt(this,(function(u){switch(u.label){case 0:i={stack:[],error:void 0,hasError:!1},u.label=1;case 1:return u.trys.push([1,3,4,5]),function(t,n,i){if(null!=n){if("object"!=typeof n&&"function"!=typeof n)throw new m("Object expected.");var e,u;if(i){if(!o)throw new m("Symbol.asyncDispose is not defined.");e=n[o]}if(void 0===e){if(!r)throw new m("Symbol.dispose is not defined.");e=n[r],i&&(u=e)}if("function"!=typeof e)throw new m("Object not disposable.");u&&(e=function(){try{u.call(this)}catch(t){return J.reject(t)}}),t.stack.push({value:n,dispose:e,async:i})}else i&&t.stack.push({async:!0});return n}(i,n,!1),[4,t];case 2:return[2,u.sent()];case 3:return e=u.sent(),i.error=e,i.hasError=!0,[3,5];case 4:return function(t){function n(n){t.error=t.hasError?new Jt(n,t.error,"An error was suppressed during disposal."):n,t.hasError=!0}var i,e=0;(function r(){for(;i=t.stack.pop();)try{if(!i.async&&1===e)return e=0,t.stack.push(i),J.resolve().then(r);if(i.dispose){var o=i.dispose.call(i.value);if(i.async)return e|=2,J.resolve(o).then(r,(function(t){return n(t),r()}))}else e|=1}catch(t){n(t)}if(1===e)return t.hasError?J.reject(t.error):J.resolve();if(t.hasError)throw t.error})()}(i),[7];case 5:return[2]}}))})),mn.apply(this,arguments)}J.resolve();function pn(t,n){return new J((function(i,e){if(void 0!==n&&n.zm)e(new ln);else{var r=Wt.Gm((function(){void 0!==n&&n.Jm(o),i()}),t),o=function(){Wt.Um(r),e(new ln)};void 0!==n&&n.Qm(o)}}))}function yn(){return void 0!==a?a.createElement("video"):void 0}var _n=Kt(yn);Kt((function(){return"undefined"!=typeof HTMLVideoElement&&_n()instanceof HTMLVideoElement}));x(),gt(),x(),gt(),x(),gt();var Sn=null;try{Sn=new WebAssembly.Instance(new WebAssembly.Module(new E([0,97,115,109,1,0,0,0,1,13,2,96,0,1,127,96,4,127,127,127,127,1,127,3,7,6,0,1,1,1,1,1,6,6,1,127,1,65,0,11,7,50,6,3,109,117,108,0,1,5,100,105,118,95,115,0,2,5,100,105,118,95,117,0,3,5,114,101,109,95,115,0,4,5,114,101,109,95,117,0,5,8,103,101,116,95,104,105,103,104,0,0,10,191,1,6,4,0,35,0,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,126,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,127,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,128,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,129,34,4,66,32,135,167,36,0,32,4,167,11,36,1,1,126,32,0,173,32,1,173,66,32,134,132,32,2,173,32,3,173,66,32,134,132,130,34,4,66,32,135,167,36,0,32,4,167,11])),{}).exports}catch(Et){}function Tn(t,n,i){this.low=0|t,this.high=0|n,this.unsigned=!!i}function En(t){return!0===(t&&t.cp)}function In(t){var n=y.clz32(t&-t);return t?31-n:n}Tn.prototype.cp,p.defineProperty(Tn.prototype,"cp",{value:!0}),Tn.isLong=En;var kn={},Rn={};function On(t,n){var i,e,r;return n?(r=0<=(t>>>=0)&&t<256)&&(e=Rn[t])?e:(i=Pn(t,0,!0),r&&(Rn[t]=i),i):(r=-128<=(t|=0)&&t<128)&&(e=kn[t])?e:(i=Pn(t,t<0?-1:0,!1),r&&(kn[t]=i),i)}function Nn(t,n){if(T(t))return n?Fn:Un;if(n){if(t<0)return Fn;if(t>=Bn)return qn}else{if(t<=-Mn)return Xn;if(t+1>=Mn)return Hn}return t<0?Nn(-t,n).neg():Pn(t%xn|0,t/xn|0,n)}function Pn(t,n,i){return new Tn(t,n,i)}Tn.fromInt=On,Tn.fromNumber=Nn,Tn.fromBits=Pn;var An=y.pow;function Dn(t,n,i){if(0===t.length)throw g("empty string");if("number"==typeof n?(i=n,n=!1):n=!!n,"NaN"===t||"Infinity"===t||"+Infinity"===t||"-Infinity"===t)return n?Fn:Un;if((i=i||10)<2||36<i)throw RangeError("radix");var e;if((e=t.indexOf("-"))>0)throw g("interior hyphen");if(0===e)return Dn(t.substring(1),n,i).neg();for(var r=Nn(An(i,8)),o=Un,u=0;u<t.length;u+=8){var s=y.min(8,t.length-u),f=_(t.substring(u,u+s),i);if(s<8){var c=Nn(An(i,s));o=o.mul(c).add(Nn(f))}else o=(o=o.mul(r)).add(Nn(f))}return o.unsigned=n,o}function Cn(t,n){return"number"==typeof t?Nn(t,n):"string"==typeof t?Dn(t,n):Pn(t.low,t.high,"boolean"==typeof n?n:t.unsigned)}Tn.fromString=Dn,Tn.fromValue=Cn;var xn=4294967296,Bn=xn*xn,Mn=Bn/2,Ln=On(1<<24),Un=On(0);Tn.ZERO=Un;var Fn=On(0,!0);Tn.UZERO=Fn;var zn=On(1);Tn.ONE=zn;var Wn=On(1,!0);Tn.UONE=Wn;var Vn=On(-1);Tn.NEG_ONE=Vn;var Hn=Pn(-1,2147483647,!1);Tn.MAX_VALUE=Hn;var qn=Pn(-1,-1,!0);Tn.MAX_UNSIGNED_VALUE=qn;var Xn=Pn(0,-2147483648,!1);Tn.MIN_VALUE=Xn;var jn=Tn.prototype;jn.toInt=function(){return this.unsigned?this.low>>>0:this.low},jn.toNumber=function(){return this.unsigned?(this.high>>>0)*xn+(this.low>>>0):this.high*xn+(this.low>>>0)},jn.toString=function(t){if((t=t||10)<2||36<t)throw RangeError("radix");if(this.isZero())return"0";if(this.isNegative()){if(this.eq(Xn)){var n=Nn(t),i=this.div(n),e=i.mul(n).sub(this);return i.toString(t)+e.toInt().toString(t)}return"-"+this.neg().toString(t)}for(var r=Nn(An(t,6),this.unsigned),o=this,u="";;){var s=o.div(r),f=(o.sub(s.mul(r)).toInt()>>>0).toString(t);if((o=s).isZero())return f+u;for(;f.length<6;)f="0"+f;u=""+f+u}},jn.getHighBits=function(){return this.high},jn.getHighBitsUnsigned=function(){return this.high>>>0},jn.getLowBits=function(){return this.low},jn.getLowBitsUnsigned=function(){return this.low>>>0},jn.getNumBitsAbs=function(){if(this.isNegative())return this.eq(Xn)?64:this.neg().getNumBitsAbs();for(var t=0!=this.high?this.high:this.low,n=31;n>0&&0==(t&1<<n);n--);return 0!=this.high?n+33:n+1},jn.isZero=function(){return 0===this.high&&0===this.low},jn.eqz=jn.isZero,jn.isNegative=function(){return!this.unsigned&&this.high<0},jn.isPositive=function(){return this.unsigned||this.high>=0},jn.isOdd=function(){return 1==(1&this.low)},jn.isEven=function(){return 0==(1&this.low)},jn.equals=function(t){return En(t)||(t=Cn(t)),(this.unsigned===t.unsigned||this.high>>>31!=1||t.high>>>31!=1)&&(this.high===t.high&&this.low===t.low)},jn.eq=jn.equals,jn.notEquals=function(t){return!this.eq(t)},jn.neq=jn.notEquals,jn.ne=jn.notEquals,jn.lessThan=function(t){return this.comp(t)<0},jn.lt=jn.lessThan,jn.lessThanOrEqual=function(t){return this.comp(t)<=0},jn.lte=jn.lessThanOrEqual,jn.le=jn.lessThanOrEqual,jn.greaterThan=function(t){return this.comp(t)>0},jn.gt=jn.greaterThan,jn.greaterThanOrEqual=function(t){return this.comp(t)>=0},jn.gte=jn.greaterThanOrEqual,jn.ge=jn.greaterThanOrEqual,jn.compare=function(t){if(En(t)||(t=Cn(t)),this.eq(t))return 0;var n=this.isNegative(),i=t.isNegative();return n&&!i?-1:!n&&i?1:this.unsigned?t.high>>>0>this.high>>>0||t.high===this.high&&t.low>>>0>this.low>>>0?-1:1:this.sub(t).isNegative()?-1:1},jn.comp=jn.compare,jn.negate=function(){return!this.unsigned&&this.eq(Xn)?Xn:this.not().add(zn)},jn.neg=jn.negate,jn.add=function(t){En(t)||(t=Cn(t));var n=this.high>>>16,i=65535&this.high,e=this.low>>>16,r=65535&this.low,o=t.high>>>16,u=65535&t.high,s=t.low>>>16,f=0,c=0,h=0,a=0;return h+=(a+=r+(65535&t.low))>>>16,c+=(h+=e+s)>>>16,f+=(c+=i+u)>>>16,f+=n+o,Pn((h&=65535)<<16|(a&=65535),(f&=65535)<<16|(c&=65535),this.unsigned)},jn.subtract=function(t){return En(t)||(t=Cn(t)),this.add(t.neg())},jn.sub=jn.subtract,jn.multiply=function(t){if(this.isZero())return this;if(En(t)||(t=Cn(t)),Sn)return Pn(Sn.mul(this.low,this.high,t.low,t.high),Sn.get_high(),this.unsigned);if(t.isZero())return this.unsigned?Fn:Un;if(this.eq(Xn))return t.isOdd()?Xn:Un;if(t.eq(Xn))return this.isOdd()?Xn:Un;if(this.isNegative())return t.isNegative()?this.neg().mul(t.neg()):this.neg().mul(t).neg();if(t.isNegative())return this.mul(t.neg()).neg();if(this.lt(Ln)&&t.lt(Ln))return Nn(this.toNumber()*t.toNumber(),this.unsigned);var n=this.high>>>16,i=65535&this.high,e=this.low>>>16,r=65535&this.low,o=t.high>>>16,u=65535&t.high,s=t.low>>>16,f=65535&t.low,c=0,h=0,a=0,v=0;return a+=(v+=r*f)>>>16,h+=(a+=e*f)>>>16,a&=65535,h+=(a+=r*s)>>>16,c+=(h+=i*f)>>>16,h&=65535,c+=(h+=e*s)>>>16,h&=65535,c+=(h+=r*u)>>>16,c+=n*f+i*s+e*u+r*o,Pn((a&=65535)<<16|(v&=65535),(c&=65535)<<16|(h&=65535),this.unsigned)},jn.mul=jn.multiply,jn.divide=function(t){if(En(t)||(t=Cn(t)),t.isZero())throw g("division by zero");var n,i,e;if(Sn)return this.unsigned||-2147483648!==this.high||-1!==t.low||-1!==t.high?Pn((this.unsigned?Sn.div_u:Sn.div_s)(this.low,this.high,t.low,t.high),Sn.get_high(),this.unsigned):this;if(this.isZero())return this.unsigned?Fn:Un;if(this.unsigned){if(t.unsigned||(t=t.toUnsigned()),t.gt(this))return Fn;if(t.gt(this.shru(1)))return Wn;e=Fn}else{if(this.eq(Xn))return t.eq(zn)||t.eq(Vn)?Xn:t.eq(Xn)?zn:(n=this.shr(1).div(t).shl(1)).eq(Un)?t.isNegative()?zn:Vn:(i=this.sub(t.mul(n)),e=n.add(i.div(t)));if(t.eq(Xn))return this.unsigned?Fn:Un;if(this.isNegative())return t.isNegative()?this.neg().div(t.neg()):this.neg().div(t).neg();if(t.isNegative())return this.div(t.neg()).neg();e=Un}for(i=this;i.gte(t);){n=y.max(1,y.floor(i.toNumber()/t.toNumber()));for(var r=y.ceil(y.log(n)/y.LN2),o=r<=48?1:An(2,r-48),u=Nn(n),s=u.mul(t);s.isNegative()||s.gt(i);)s=(u=Nn(n-=o,this.unsigned)).mul(t);u.isZero()&&(u=zn),e=e.add(u),i=i.sub(s)}return e},jn.div=jn.divide,jn.modulo=function(t){return En(t)||(t=Cn(t)),Sn?Pn((this.unsigned?Sn.rem_u:Sn.rem_s)(this.low,this.high,t.low,t.high),Sn.get_high(),this.unsigned):this.sub(this.div(t).mul(t))},jn.mod=jn.modulo,jn.rem=jn.modulo,jn.not=function(){return Pn(~this.low,~this.high,this.unsigned)},jn.countLeadingZeros=function(){return this.high?y.clz32(this.high):y.clz32(this.low)+32},jn.clz=jn.countLeadingZeros,jn.countTrailingZeros=function(){return this.low?In(this.low):In(this.high)+32},jn.ctz=jn.countTrailingZeros,jn.and=function(t){return En(t)||(t=Cn(t)),Pn(this.low&t.low,this.high&t.high,this.unsigned)},jn.or=function(t){return En(t)||(t=Cn(t)),Pn(this.low|t.low,this.high|t.high,this.unsigned)},jn.xor=function(t){return En(t)||(t=Cn(t)),Pn(this.low^t.low,this.high^t.high,this.unsigned)},jn.shiftLeft=function(t){return En(t)&&(t=t.toInt()),0==(t&=63)?this:t<32?Pn(this.low<<t,this.high<<t|this.low>>>32-t,this.unsigned):Pn(0,this.low<<t-32,this.unsigned)},jn.shl=jn.shiftLeft,jn.shiftRight=function(t){return En(t)&&(t=t.toInt()),0==(t&=63)?this:t<32?Pn(this.low>>>t|this.high<<32-t,this.high>>t,this.unsigned):Pn(this.high>>t-32,this.high>=0?0:-1,this.unsigned)},jn.shr=jn.shiftRight,jn.shiftRightUnsigned=function(t){return En(t)&&(t=t.toInt()),0==(t&=63)?this:t<32?Pn(this.low>>>t|this.high<<32-t,this.high>>>t,this.unsigned):Pn(32===t?this.high:this.high>>>t-32,0,this.unsigned)},jn.shru=jn.shiftRightUnsigned,jn.shr_u=jn.shiftRightUnsigned,jn.rotateLeft=function(t){var n;return En(t)&&(t=t.toInt()),0==(t&=63)?this:32===t?Pn(this.high,this.low,this.unsigned):t<32?(n=32-t,Pn(this.low<<t|this.high>>>n,this.high<<t|this.low>>>n,this.unsigned)):(n=32-(t-=32),Pn(this.high<<t|this.low>>>n,this.low<<t|this.high>>>n,this.unsigned))},jn.rotl=jn.rotateLeft,jn.rotateRight=function(t){var n;return En(t)&&(t=t.toInt()),0==(t&=63)?this:32===t?Pn(this.high,this.low,this.unsigned):t<32?(n=32-t,Pn(this.high<<n|this.low>>>t,this.low<<n|this.high>>>t,this.unsigned)):(n=32-(t-=32),Pn(this.low<<n|this.high>>>t,this.high<<n|this.low>>>t,this.unsigned))},jn.rotr=jn.rotateRight,jn.toSigned=function(){return this.unsigned?Pn(this.low,this.high,!1):this},jn.toUnsigned=function(){return this.unsigned?this:Pn(this.low,this.high,!0)},jn.toBytes=function(t){return t?this.toBytesLE():this.toBytesBE()},jn.toBytesLE=function(){var t=this.high,n=this.low;return[255&n,n>>>8&255,n>>>16&255,n>>>24,255&t,t>>>8&255,t>>>16&255,t>>>24]},jn.toBytesBE=function(){var t=this.high,n=this.low;return[t>>>24,t>>>16&255,t>>>8&255,255&t,n>>>24,n>>>16&255,n>>>8&255,255&n]},Tn.fromBytes=function(t,n,i){return i?Tn.fromBytesLE(t,n):Tn.fromBytesBE(t,n)},Tn.fromBytesLE=function(t,n){return new Tn(t[0]|t[1]<<8|t[2]<<16|t[3]<<24,t[4]|t[5]<<8|t[6]<<16|t[7]<<24,n)},Tn.fromBytesBE=function(t,n){return new Tn(t[4]<<24|t[5]<<16|t[6]<<8|t[7],t[0]<<24|t[1]<<16|t[2]<<8|t[3],n)};var Yn=Tn;function Kn(){return Date.now()||(new Date).getTime()}Yn.fromNumber(en);var Gn=Boolean("ontouchstart"in self||self.DocumentTouch&&a instanceof self.DocumentTouch)||Boolean(v&&v.msMaxTouchPoints),$n=_n(),Zn=Boolean($n&&$n.webkitShowPlaybackTargetPicker),Jn=function(){function t(){this.dp=void 0,this.Mp=!1,this.Qe=Gn,this.Qs=!1,this.ap=!0}var n=t.prototype;return n.fp=function(){return 0},n.Pp=function(t,n){return!0},n.Dp=function(t){return t>=.3333333333333333},Tt(t,[{key:"lp",get:function(){return void 0===this.dp&&(this.dp=this.fp()),this.dp}},{key:"_p",get:function(){return!Ut.gm}},{key:"vp",get:function(){if(h.screen)return{width:h.screen.width,height:h.screen.height}}},{key:"gp",get:function(){return h.devicePixelRatio||1}},{key:"mp",get:function(){return Zn}},{key:"pp",get:function(){return!1}},{key:"wp",get:function(){return!0}},{key:"yp",get:function(){return!!(Ut.$g||Ut.su||Ut.Eg)||!!Ut.Vg}},{key:"bp",get:function(){return Ut.Vg}},{key:"Ap",get:function(){return!Ut.su}},{key:"Sp",get:function(){return!0}},{key:"Tp",get:function(){return!0}},{key:"kp",get:function(){return!1}},{key:"Ep",get:function(){}},{key:"xp",get:function(){return!0}},{key:"Ip",get:function(){return!1}},{key:"Rp",get:function(){return Ut.Vg}},{key:"Cp",get:function(){return!1}},{key:"Np",get:function(){return!1}}]),t}(),Qn=function(t){function n(){return t.call(this)||this}return _t(n,t),n}(Jn);x(),gt();var ti=function(t){function n(){return t.apply(this,arguments)||this}return _t(n,t),n.prototype.Pp=function(t,n){if(t&&t.Lp&&n&&n.Lp){var i=ni(t.Lp,"mp4a.40.2")&&ni(n.Lp,"mp4a.40.5"),e=ni(t.Lp,"mp4a.40.5")&&ni(n.Lp,"mp4a.40.2"),r=ni(t.Lp,"mp4a.40.2")&&ni(n.Lp,"mp4a.40.34"),o=ni(t.Lp,"mp4a.40.34")&&ni(n.Lp,"mp4a.40.2"),u=ni(t.Lp,"mp4a.40.5")&&ni(n.Lp,"mp4a.40.34"),s=ni(t.Lp,"mp4a.40.34")&&ni(n.Lp,"mp4a.40.5");return!(i||e||r||o||u||s)}return!0},Tt(n,[{key:"Ep",get:function(){if(Ut.Nv)return 4096}}]),n}(Qn);function ni(t,n){return t.indexOf(n)>-1}x(),gt();var ii=function(t){function n(){return t.apply(this,arguments)||this}return _t(n,t),n.prototype.Dp=function(t){return t>=2},n}(Qn);x(),gt();var ei=function(t){function n(){var n;return(n=t.call(this)||this).Mp=Ut.nm>=11,n.ap=Ut.$g&&!(Ut.su&&Ut.nm<10),n}return _t(n,t),Tt(n,[{key:"Cp",get:function(){return Ut.nm<17}},{key:"Np",get:function(){return!0}}]),n}(Qn);x(),gt();var ri,oi=function(t){function n(){return t.apply(this,arguments)||this}return _t(n,t),Tt(n,[{key:"xp",get:function(){return!Ut.Lv||(Ut.Sg?92!==Ut.Ig:Ut.wg>=100)}}]),n}(Qn);x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt();var ui=function(){var t=yn();if(!t)return!1;var n=t.muted;return t.muted=!n,t.muted!==n}();!function(){if(Ut.Kv)return!1;var t=yn();if(!t)return!1;var n=t.volume;t.volume=n/2+.1,t.volume}();var si=function(t){function n(n){var i;return(i=t.call(this)||this).Bp=n,i.Mp=i.Bp.Mp,i.Qe=i.Bp.Qe,i.ap=ui&&i.Bp.ap,i}_t(n,t);var i=n.prototype;return i.fp=function(){return this.Bp.lp},i.Pp=function(t,n){return this.Bp.Pp(t,n)},i.Dp=function(t){return this.Bp.Dp(t)},Tt(n,[{key:"Ep",get:function(){return this.Bp.Ep}},{key:"xp",get:function(){return this.Bp.xp}},{key:"Cp",get:function(){return this.Bp.Cp}}]),n}(Jn),fi=function(t){function n(n){var i;return(i=t.call(this,n)||this).Mp=!0,i.Qs=!0,i}return _t(n,t),Tt(n,[{key:"kp",get:function(){return Ut.su}}]),n}(si);x(),gt();var ci=function(t){function n(){return t.apply(this,arguments)||this}return _t(n,t),n.prototype.fp=function(){return function(t){return t&&Xt(h.ManagedMediaSource)?h.ManagedMediaSource:Xt(h.MediaSource)?h.MediaSource:void 0}(!0)?t.prototype.fp.call(this):1},Tt(n,[{key:"kp",get:function(){return!0}}]),n}(fi);x(),gt();var hi=function(t){function n(){return t.apply(this,arguments)||this}return _t(n,t),n.prototype.Pp=function(n,i){return t.prototype.Pp.call(this,n,i)},Tt(n,[{key:"pp",get:function(){return Ut.Pg<3}},{key:"wp",get:function(){return Ut.Pg>=3}},{key:"vp",get:function(){var t=this;return h.tizen&&!this.Wp&&h.tizen.systeminfo.getPropertyValue("DISPLAY",(function(n){var i=n.resolutionWidth,e=n.resolutionHeight;1===i&&1===e||(t.Wp={width:i,height:e})})),this.Wp}},{key:"Ip",get:function(){return Ut.Pg<3}}]),n}(si);x(),gt();var ai=function(t){function n(){return t.apply(this,arguments)||this}return _t(n,t),Tt(n,[{key:"vp",get:function(){var t=this;return h.webOS&&!this.Wp&&h.webOS.deviceInfo((function(n){t.Wp={width:n.screenWidth,height:n.screenHeight}})),this.Wp}},{key:"Sp",get:function(){return!1}}]),n}(si);x(),gt();var vi=function(t){function n(){return t.apply(this,arguments)||this}return _t(n,t),Tt(n,[{key:"kp",get:function(){return!0}},{key:"Np",get:function(){return this.Bp.Np}}]),n}(si);!function(t){ri=t}(function(){var t=function(){if(Ut.Kg)return new ti;if(Ut.Ug||Ut.Zg)return new ii;if(Ut.$g)return new ei;if(Ut.gg)return new oi;return new Qn}();return Ut.su?new ci(t):Ut.Qs?new fi(t):Ut.Rg?new hi(t):Ut.Ng?new ai(t):Ut.Nv?new vi(t):new si(t)}()),x(),gt(),x(),gt(),nt(),x(),gt();var di=!(Ut.Zg&&!Ut.Xg),li=self.console;function wi(t){if(Ht(t))try{return JSON.stringify(t)}catch(t){}return t}function bi(t){return t.map(wi).join(" ")}function gi(t){var n=li&&li[t];return n?n.bind&&di?n.bind(li):function(){for(var n=arguments.length,i=new Array(n),e=0;e<n;e++)i[e]=arguments[e];li[t](bi(i))}:void 0}var mi=gi("log")||Yt,pi=gi("warn")||mi.bind(void 0,"WARNING:"),yi=gi("error")||mi.bind(void 0,"ERROR:"),_i=function(){var t=li&&li.assert;return t?t.bind&&di?t.bind(li):function(t){for(var n=arguments.length,i=new Array(n>1?n-1:0),e=1;e<n;e++)i[e-1]=arguments[e];li.assert(t,bi(i))}:function(t){for(var n=arguments.length,i=new Array(n>1?n-1:0),e=1;e<n;e++)i[e-1]=arguments[e];t||yi.apply(void 0,["Assertion failed:"].concat(nn(i)))}}();function Si(t,n){for(var i=0;i<n.length;i++){var e=n[i];e.enumerable=e.enumerable||!1,e.configurable=!0,"value"in e&&(e.writable=!0),p.defineProperty(t,e.key,e)}}function Ti(t,n){var i=function(t,n){var i=t.length;if(i<=1)return t;for(var e=new Array(i),r=1;r<i;r*=2){Ei(t,n,r,e);var o=t;t=e,e=o}return t}(t,n);return i!==t&&Ei(i,null,t.length,t),t}function Ei(t,n,i,e){var r,o,u,s,f,c=t.length,h=0,a=2*i;for(r=0;r<c;r+=a)for(u=(o=r+i)+i,o>c&&(o=c),u>c&&(u=c),s=r,f=o;;)if(s<o&&f<u)n(t[s],t[f])<=0?e[h++]=t[s++]:e[h++]=t[f++];else if(s<o)e[h++]=t[s++];else{if(!(f<u))break;e[h++]=t[f++]}}x(),gt();var Ii=/[a-zA-Z]/,ki=/[0-9]/,Ri=/[0-9a-fA-F]/,Oi=/^0x/i,Ni=/^[0-9]+$/,Pi=/^[0-9a-fA-F]+$/,Ai=/^[0-7]+$/,Di=p.prototype.toString,Ci=Array.isArray||function(t){return"[object Array]"===Di.call(t)},xi=void 0!==n&&"symbol"==typeof e;function Bi(t){return Ci(t)?t:Array.from(t)}function Mi(t,n,i){var e=t[n];t[n]=t[i],t[i]=e}function Li(t){return t>=65&&t<=90}function Ui(t){return Li(t)||function(t){return t>=97&&t<=122}(t)}function Fi(t){return t>=48&&t<=57}function zi(t){return Fi(t)||Ui(t)}function Wi(t){return Fi(t)||t>=65&&t<=70||t>=97&&t<=102}function Vi(t){return Li(t)?t+32:t}function Hi(t){return Fi(t)?t-48:t>=65&&t<=70?t-65+10:t>=97&&t<=102?t-97+10:-1}function qi(t,n){return void 0===n&&(n=!1),0<=t&&t<=9?t+48:10<=t&&t<=15?t+(n?87:55):-1}var Xi=y.min,ji=String.fromCharCode,Yi=16384;function Ki(t){for(var n=t.length,i=[],e=0;e<n;e+=Yi){var r=Xi(e+Yi,n);i.push(ji.apply(null,t.slice(e,r)))}return i.join("")}var Gi=2147483647,$i=/[^\0-\x7E]/,Zi=/[\x2E\u3002\uFF0E\uFF61]/g,Ji={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},Qi=y.floor,te=String.fromCharCode;function ne(t){throw new RangeError(Ji[t])}function ie(t){for(var n=[],i=0,e=t.length;i<e;){var r=t.charCodeAt(i++);if(r>=55296&&r<=56319&&i<e){var o=t.charCodeAt(i++);56320==(64512&o)?n.push(((1023&r)<<10)+(1023&o)+65536):(n.push(r),i--)}else n.push(r)}return n}var ee,re,oe,ue=function(t,n){return t+22+75*(t<26)-((0!=n)<<5)},se=function(t,n,i){var e=0;for(t=i?Qi(t/700):t>>1,t+=Qi(t/n);t>455;e+=36)t=Qi(t/35);return Qi(e+36*t/(t+38))},fe=function(t){return function(t,n){var i=t.split("@"),e="";i.length>1&&(e=i[0]+"@",t=i[1]);var r=function(t,n){for(var i=[],e=t.length;e--;)i[e]=n(t[e]);return i}((t=t.replace(Zi,".")).split("."),n).join(".");return e+r}(t,(function(t){return $i.test(t)?"xn--"+function(t){for(var n=[],i=(t=ie(t)).length,e=128,r=0,o=72,u=0,s=t;u<s.length;u++){var f=s[u];f<128&&n.push(te(f))}var c=n.length,h=c;for(c&&n.push("-");h<i;){for(var a=Gi,v=0,d=t;v<d.length;v++){var l=d[v];l>=e&&l<a&&(a=l)}var w=h+1;a-e>Qi((Gi-r)/w)&&ne("overflow"),r+=(a-e)*w,e=a;for(var b=0,g=t;b<g.length;b++){var m=g[b];if(m<e&&++r>Gi&&ne("overflow"),m==e){for(var p=r,y=36;;y+=36){var _=y<=o?1:y>=o+26?26:y-o;if(p<_)break;var S=p-_,T=36-_;n.push(te(ue(_+S%T,0))),p=Qi(S/T)}n.push(te(ue(p,0))),o=se(r,w,h==c),r=0,++h}}++r,++e}return n.join("")}(t):t}))};function ce(t){for(var n=[],i=0;i<t.length;i++){var e=t[i];e>65535&&(e-=65536,n.push(e>>>10&1023|55296),e=56320|1023&e),n.push(e)}return Ki(n)}function he(t){if(t>=55296&&t<=57343)throw new g("Lone surrogate U+"+t.toString(16).toUpperCase()+" is not a scalar value")}function ae(t,n){return t>>n&63|128}function ve(t,n){0!=(4294967168&t)?(0==(4294965248&t)?n.push(t>>6&31|192):0==(4294901760&t)?(he(t),n.push(t>>12&15|224),n.push(ae(t,6))):0==(4292870144&t)&&(n.push(t>>18&7|240),n.push(ae(t,12)),n.push(ae(t,6))),n.push(63&t|128)):n.push(t)}function de(t){for(var n=[],i=0;i<t.length;i++){ve(t[i],n)}return n}function le(){if(oe>=re)throw new g("Invalid byte index");var t=255&ee[oe];if(oe++,128==(192&t))return 63&t;throw new g("Invalid continuation byte")}function we(){var t,n;if(oe>re)throw new g("Invalid byte index");if(oe===re)return!1;if(t=255&ee[oe],oe++,0==(128&t))return t;if(192==(224&t)){if((n=(31&t)<<6|le())>=128)return n;throw new g("Invalid continuation byte")}if(224==(240&t)){if((n=(15&t)<<12|le()<<6|le())>=2048)return he(n),n;throw new g("Invalid continuation byte")}if(240==(248&t)&&(n=(7&t)<<18|le()<<12|le()<<6|le())>=65536&&n<=1114111)return n;throw new g("Invalid UTF-8 detected")}function be(t){return[37,qi(t>>4),qi(15&t)]}function ge(t){return function(t){return t>=0&&t<=31}(t)||t>126}function me(t){return ge(t)||32===t||34===t||60===t||62===t||96===t}function pe(t){return me(t)||35===t||63===t||123===t||125===t}function ye(t){return pe(t)||47===t||58===t||59===t||61===t||64===t||t>=91&&t<=94||124===t}function _e(t){return t<33||t>126||34===t||35===t||60===t||62===t}function Se(t){return _e(t)||39===t}function Te(t,n){if(!n(t))return[t];for(var i=de([t]),e=[],r=0;r<i.length;r++){var o=i[r];e.push.apply(e,be(o))}return e}function Ee(t,n){for(var i=[],e=0,r=ie(t);e<r.length;e++){var o=r[e];i.push.apply(i,Te(o,n))}return ce(i)}function Ie(t){return function(t){for(var n=[],i=t.length,e=0;e<i;e++){var r=t[e];if(37===r&&e+2<i&&Wi(t[e+1])&&Wi(t[e+2])){var o=Hi(t[e+1])<<4|Hi(t[e+2]);n.push(o),e+=2}else n.push(r)}return n}(de(t))}function ke(t){return ce(function(t){ee=t.slice(),re=ee.length,oe=0;for(var n,i=[];!1!==(n=we());)i.push(n);return i}(Ie(ie(t))))}function Re(t){var n=t.length,i=[0,0,0,0,0,0,0,0],e=0,r=null,o=0;if(o<n&&":"===t[o]){if(!(o+1<n&&":"===t[o+1]))throw new m;o+=2,r=e+=1}for(;o<n;){if(8===e)throw new m("Too many groups");if(":"!==t[o]){for(var u=0,s=0;s<4&&o<n&&Ri.test(t[o]);)u=u<<4|_(t[o],16),o+=1,s+=1;if("."===t[o]){if(0===s)throw new m;if(o-=s,e>6)throw new m;for(var f=0;o<n;){var c=null;if(f>0){if(!("."===t[o]&&f<4))throw new m;o+=1}if(!ki.test(t[o]))throw new m;for(;o<n&&ki.test(t[o]);){var h=_(t[o],10);if(null===c)c=h;else{if(0===c)throw new m;if((c=10*c+h)>255)throw new m}o+=1}i[e]=i[e]<<8|c,2!==(f+=1)&&4!==f||(e+=1)}if(4!==f)throw new m;break}if(":"===t[o]){if((o+=1)===n)throw new m}else if(o<n)throw new m;i[e]=u,e+=1}else{if(null!==r)throw new m("Too many :: groups");o+=1,r=e+=1}}if(null!==r){var a=e-r;for(e=7;0!==e&&a>0;)Mi(i,e,r+a-1),e-=1,a-=1}else if(8!==e)throw new m;return i}function Oe(t){var n=10,i=Ni;return Oi.test(t)?(t=t.slice(2),n=16,i=Pi):t.length>=2&&"0"===t[0]&&(t=t.slice(1),n=8,i=Ai),""===t?0:i.test(t)?_(t,n):void 0}var Ne={Up:4},Pe=/[\0\t\n\r #%/:?@\[\\\]]/,Ae=/[\0\t\n\r #/:?@\[\\\]]/;function De(t,n){if("["===t[0]){if("]"!==t[t.length-1])throw new m("Invalid IPv6 address");return{Up:2,Gp:Re(t.slice(1,-1))}}if(!n)return function(t){if(Ae.test(t))throw new m("Invalid code point in opaque host");var n=Ee(t,ge);return""===n?Ne:{Up:3,Zp:n}}(t);var i=function(t){var n=function(t){return fe(t.toLowerCase())}(t);return n}(ke(t));if(Pe.test(i))throw new m("Invalid code point in host");var e=function(t){var n=t.split(".");if(""===n[n.length-1]&&n.pop(),!(n.length>4)){for(var i=[],e=0;e<n.length;e++){var r=n[e];if(""===r)return;var o=Oe(r);if(void 0===o)return;i.push(o)}for(var u=0;u<i.length-1;u++)if(i[u]>255)throw new m;if(i[i.length-1]>=y.pow(256,5-i.length))throw new m;for(var s=i.pop(),f=0;f<i.length;f++)s+=i[f]*y.pow(256,3-f);return s}}(i);return void 0!==e?{Up:1,Gp:e}:""===i?Ne:{Up:0,Hp:i}}function Ce(t){switch(t.Up){case 0:return t.Hp;case 1:return function(t){for(var n=[],i=t,e=1;e<=4;e++)n.push(""+(255&i)),4!==e&&n.push("."),i>>>=8;return n.reverse().join("")}(t.Gp);case 2:return"["+function(t){for(var n="",i=function(t){for(var n=0,i=0,e=0,r=0,o=0;o<8;o++)0===t[o]?(0===r&&(e=o),r++):(r>i&&(n=e,i=r),r=0);return r>i&&(n=e,i=r),i>1?n:null}(t),e=!1,r=0;r<8;r++){if(e){if(0===t[r])continue;e=!1}i!==r?(n+=t[r].toString(16),7!==r&&(n+=":")):(n+=0===r?"::":":",e=!0)}return n}(t.Gp)+"]";case 3:return t.Zp;case 4:return""}}var xe=/\+/g;function Be(t){return 42===t||45===t||46===t||95===t||zi(t)}function Me(t){for(var n=t.split("&"),i=[],e=0;e<n.length;e++){var r=n[e];if(""!==r){var o=r.indexOf("="),u=void 0,s=void 0;-1!==o?(u=r.slice(0,o),s=r.slice(o+1)):(u=r,s=""),u=u.replace(xe," "),s=s.replace(xe," ");var f=ke(u),c=ke(s);i.push([f,c])}}return i}function Le(t){for(var n="",i=0;i<t.length;i++){var e=t[i];i>0&&(n+="&"),n+=Ue(de(ie(e[0])))+"="+Ue(de(ie(e[1])))}return n}function Ue(t){for(var n=[],i=0;i<t.length;i++){var e=t[i];32===e?n.push(43):Be(e)?n.push(e):n.push.apply(n,be(e))}return Ki(n)}var Fe=/(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])/;function ze(t){var n=""+t,i=Fe.exec(n);return i?function(t,n){for(var i=t.length,e=[],r=n;r<i;r++){var o=t.charCodeAt(r);if(Ve(o))if(He(o)||r===i-1)e.push(We);else{var u=t.charCodeAt(r+1);He(u)?(e.push(o,u),r++):e.push(We)}else e.push(o)}return t.slice(0,n)+Ki(e)}(n,i.index):n}var We=65533,Ve=function(t){return 55296==(63488&t)},He=function(t){return 0!=(1024&t)};function qe(t,n){var i=t[0],e=n[0];return i===e?0:i<e?-1:1}function Xe(t){t.D_.length=0}function je(t,n){!function(t,n){for(var i=0;i<n.length;i++)t[i]=n[i];t.length=n.length}(t.D_,Me(n))}function Ye(t){if(t.ic){var n=Le(t.D_);""===n&&(n=null),t.ic.ic.Xp=n}}var Ke=function(){function t(t){if(void 0===t&&(t=void 0),this.ic=null,null==t)this.D_=[];else if("object"==typeof t||"function"==typeof t)if(function(t){return t instanceof Ke&&!!Ci(t.D_)&&(!xi||t[e]===Ge)}(t))this.D_=t.D_.slice();else if(function(t){return null!=t&&(!!Ci(t)||!!xi&&"function"==typeof t[e])}(t)){this.D_=[];for(var n=0,i=Bi(t);n<i.length;n++){var r=Bi(i[n]);if(2!==r.length)throw new m("Invalid name-value pair");this.D_.push([ze(r[0]),ze(r[1])])}}else for(var o in this.D_=[],t)p.prototype.hasOwnProperty.call(t,o)&&this.D_.push([ze(o),ze(t[o])]);else(t=ze(t)).length>0&&"?"===t[0]&&(t=t.slice(1)),this.D_=Me(t)}var n=t.prototype;return n.append=function(t,n){t=ze(t),n=ze(n),this.D_.push([t,n]),Ye(this)},n.delete=function(t){t=ze(t);for(var n=this.D_,i=0;i<n.length;){n[i][0]===t?n.splice(i,1):i++}Ye(this)},n.get=function(t){t=ze(t);for(var n=this.D_,i=0;i<n.length;i++){var e=n[i];if(e[0]===t)return e[1]}return null},n.getAll=function(t){t=ze(t);for(var n=this.D_,i=[],e=0;e<n.length;e++){var r=n[e];r[0]===t&&i.push(r[1])}return i},n.has=function(t){t=ze(t);for(var n=this.D_,i=0;i<n.length;i++){if(n[i][0]===t)return!0}return!1},n.set=function(t,n){t=ze(t),n=ze(n);for(var i=this.D_,e=!1,r=0;r<i.length;){var o=i[r];o[0]===t?e?i.splice(r,1):(o[1]=n,e=!0,r++):r++}e||i.push([t,n]),Ye(this)},n.sort=function(){Ti(this.D_,qe),Ye(this)},n.toString=function(){return Le(this.D_)},n.entries=function(){return new Qe(this.D_,$e)},n.keys=function(){return new Qe(this.D_,Ze)},n.values=function(){return new Qe(this.D_,Je)},n.forEach=function(t){var n=this;this.D_.forEach((function(i){return t(i[1],i[0],n)}))},t}(),Ge=Ke.prototype.entries;xi&&(Ke.prototype[e]=Ge);var $e=function(t){return[t[0],t[1]]},Ze=function(t){return t[0]},Je=function(t){return t[1]},Qe=function(){function t(t,n){this.zp=0,this.D_=t,this.qp=n}return t.prototype.next=function(){return this.zp<this.D_.length?{done:!1,value:this.qp(this.D_[this.zp++])}:{done:!0,value:void 0}},t}(),tr="null";var nr=p.create(null);nr.ftp=21,nr.file=0,nr.gopher=70,nr.http=80,nr.https=443,nr.ws=80,nr.wss=443;var ir=/^(?:\.|%2e)$/i,er=/^(?:\.|%2e){2}$/i;function rr(t){return ir.test(t)}function or(t){return er.test(t)}function ur(t){return void 0!==nr[t]}function sr(t){return ur(t.Yp)}function fr(t){return""!==t.Kp||""!==t.jp}function cr(t){var n=t.length;if(!(n>=2))return!1;if(!ar(t.slice(0,2)))return!1;if(2!==n){var i=t[2];if(47!==i&&92!==i&&63!==i&&35!==i)return!1}return!0}function hr(t){return 2===t.length&&Ii.test(t[0])&&(":"===t[1]||"|"===t[1])}function ar(t){return 2===t.length&&hr(Ki(t))}function vr(t){return hr(t)&&":"===t[1]}function dr(t){var n=t.Qp;0!==n.length&&("file"===t.Yp&&1===n.length&&vr(n[0])||n.pop())}function lr(t){return null===t.Jp||Ne===t.Jp||t.$p||"file"===t.Yp}var wr=-1,br=/\t|\n|\r/g,gr=/^[\x00-\x1f ]+|[\x00-\x1f ]+$/g;function mr(t,n,i,e){void 0===i&&(i=null),void 0===e&&(e=null),i||(i=new yr,t=t.replace(gr,""));var r=null!==e?e:0;n=n||null;for(var o=[],u=!1,s=!1,f=!1,c=ie(t=t.replace(br,"")),h=c.length,a=0;a<=h;){var v=a<h?c[a]:wr;switch(r){case 0:if(!Ui(v)){if(null===e){o.length=0,r=2;continue}throw new m("Invalid scheme")}o.push(Vi(v)),r=1;break;case 1:if(zi(v)||43===v||45===v||46===v)o.push(Vi(v));else{if(58!==v){if(null===e){o.length=0,r=2,a=0;continue}throw new m("Invalid scheme")}var d=ce(o);if(null!==e){if(ur(i.Yp)&&!ur(d))return;if(!ur(i.Yp)&&ur(d))return;if((fr(i)||null!==i.ew)&&"file"===d)return;if("file"===i.Yp&&(i.Jp===Ne||null===i.Jp))return}if(i.Yp=d,null!==e)return void(sr(i)&&i.ew===nr[i.Yp]&&(i.ew=null));o.length=0,"file"===i.Yp?r=13:sr(i)&&n&&n.Yp===i.Yp?r=3:sr(i)?r=7:47===c[a+1]?(r=4,a+=1):(i.$p=!0,i.Qp.push(""),r=18)}break;case 2:if(!n||n.$p&&35!==v)throw new m("Invalid scheme");n.$p&&35===v?(i.Yp=n.Yp,i.Qp=n.Qp.slice(),i.Xp=n.Xp,i.iw="",i.$p=!0,r=20):"file"!==n.Yp?(r=5,a-=1):(r=13,a-=1);break;case 3:47===v&&47===c[a+1]?r=8:(r=5,a-=1);break;case 4:47===v?r=9:(r=17,a-=1);break;case 5:i.Yp=n.Yp,wr===v?(i.Kp=n.Kp,i.jp=n.jp,i.Jp=n.Jp,i.ew=n.ew,i.Qp=n.Qp.slice(),i.Xp=n.Xp):47===v?r=6:63===v?(i.Kp=n.Kp,i.jp=n.jp,i.Jp=n.Jp,i.ew=n.ew,i.Qp=n.Qp.slice(),i.Xp="",r=19):35===v?(i.Kp=n.Kp,i.jp=n.jp,i.Jp=n.Jp,i.ew=n.ew,i.Qp=n.Qp.slice(),i.Xp=n.Xp,i.iw="",r=20):92===v&&sr(i)?r=6:(i.Kp=n.Kp,i.jp=n.jp,i.Jp=n.Jp,i.ew=n.ew,i.Qp=n.Qp.slice(),i.Qp.pop(),r=17,a-=1);break;case 6:!sr(i)||47!==v&&92!==v?47===v?r=9:(i.Kp=n.Kp,i.jp=n.jp,i.Jp=n.Jp,i.ew=n.ew,r=17,a-=1):r=8;break;case 7:if(47!==v||47!==c[a+1]){r=8;continue}r=8,a+=1;break;case 8:47!==v&&92!==v&&(r=9,a-=1);break;case 9:if(64===v){u&&o.unshift(37,52,48),u=!0;for(var l=0;l<o.length;l++){var w=o[l];if(58!==w||f){var b=ce(Te(w,ye));f?i.jp+=b:i.Kp+=b}else f=!0}o.length=0}else if(wr===v||47===v||63===v||35===v||sr(i)&&92===v){if(u&&0===o.length)throw new m("Invalid host");a-=o.length+1,o.length=0,r=10}else o.push(v);break;case 10:case 11:if(null!==e&&"file"===i.Yp)a-=1,r=15;else if(58!==v||s)if(wr===v||47===v||63===v||35===v||sr(i)&&92===v){if(a-=1,sr(i)&&0===o.length)throw new m("Invalid host");if(null!==e&&0===o.length&&(fr(i)||null!==i.ew))return;var g=De(ce(o),sr(i));if(i.Jp=g,o.length=0,r=16,null!==e)return}else 91===v?s=!0:93===v&&(s=!1),o.push(v);else{if(0===o.length)throw new m("Invalid host");var p=De(ce(o),sr(i));if(i.Jp=p,o.length=0,r=12,11===e)return}break;case 12:if(Fi(v))o.push(v);else{if(!(wr===v||47===v||63===v||35===v||sr(i)&&92===v||null!==e))throw new m("Invalid port");if(0!==o.length){var y=_(ce(o),10);if(y>65535)throw new m("Invalid port");i.ew=y===nr[i.Yp]?null:y,o.length=0}if(null!==e)return;r=16,a-=1}break;case 13:i.Yp="file",47===v||92===v?r=14:n&&"file"===n.Yp?wr===v?(i.Jp=n.Jp,i.Qp=n.Qp.slice(),i.Xp=n.Xp):63===v?(i.Jp=n.Jp,i.Qp=n.Qp.slice(),i.Xp="",r=19):35===v?(i.Jp=n.Jp,i.Qp=n.Qp.slice(),i.Xp=n.Xp,i.iw="",r=20):(cr(c.slice(a))||(i.Jp=n.Jp,i.Qp=n.Qp.slice(),dr(i)),r=17,a-=1):(r=17,a-=1);break;case 14:47===v||92===v?r=15:(n&&"file"===n.Yp&&!cr(c.slice(a))&&(vr(n.Qp[0])?i.Qp.push(n.Qp[0]):i.Jp=n.Jp),r=17,a-=1);break;case 15:if(wr===v||47===v||92===v||63===v||35===v)if(a-=1,null===e&&ar(o))r=17;else if(0===o.length){if(i.Jp=Ne,null!==e)return;r=16}else{var S=De(ce(o),sr(i));if(0===S.Up&&"localhost"===S.Hp&&(S=Ne),i.Jp=S,null!==e)return;o.length=0,r=16}else o.push(v);break;case 16:sr(i)?(r=17,47!==v&&92!==v&&(a-=1)):null===e&&63===v?(i.Xp="",r=19):null===e&&35===v?(i.iw="",r=20):wr!==v&&(r=17,47!==v&&(a-=1));break;case 17:if(wr===v||47===v||sr(i)&&92===v||null===e&&(63===v||35===v)){var T=ce(o);if(or(T)?(dr(i),47===v||sr(i)&&92===v||i.Qp.push("")):!rr(T)||47===v||sr(i)&&92===v?rr(T)||("file"===i.Yp&&0===i.Qp.length&&ar(o)&&(Ne!==i.Jp&&null!==i.Jp&&(i.Jp=Ne),o[1]=58,T=ce(o)),i.Qp.push(T)):i.Qp.push(""),o.length=0,"file"===i.Yp&&(wr===v||63===v||35===v))for(;i.Qp.length>1&&""===i.Qp[0];)i.Qp.shift();63===v?(i.Xp="",r=19):35===v&&(i.iw="",r=20)}else o.push.apply(o,Te(v,pe));break;case 18:63===v?(i.Xp="",r=19):35===v?(i.iw="",r=20):wr!==v&&(i.Qp[0]+=ce(Te(v,ge)));break;case 19:null===e&&35===v?(i.iw="",r=20):wr!==v&&(i.Xp+=ce(Te(v,sr(i)?Se:_e)));break;case 20:wr===v||0===v||(i.iw+=ce(Te(v,me)))}a++}return i}function pr(t,n,i,e){try{mr(t,n,i,e)}catch(t){}}var yr=function(){this.Yp="",this.Kp="",this.jp="",this.Jp=null,this.ew=null,this.Qp=[],this.Xp=null,this.iw=null,this.$p=!1};function _r(t){switch(t.Yp){case"blob":var n;try{n=mr(t.Qp[0],null)}catch(t){return tr}return _r(n);case"ftp":case"gopher":case"http":case"https":case"ws":case"wss":return function(t,n,i){return t+"://"+Ce(n)+(null===i?"":":"+i)}(t.Yp,t.Jp,t.ew);default:return tr}}var Sr=function(){function t(t,n){var i,e=null;if(null!=n)if(function(t){return null!=t&&t instanceof Sr&&"object"==typeof t.ic}(n))e=n.ic;else try{e=mr(String(n),null)}catch(t){throw new m("Invalid base URL: "+t.message)}try{i=mr(String(t),e)}catch(t){throw new m("Invalid URL: "+t.message)}var r=i.Xp;this.ic=i,this.Xp=function(t){var n=new Ke;return null!==t&&je(n,t),n}(r),this.Xp.ic=this}var n=t.prototype;return n.toString=function(){return this.href},n.toJSON=function(){return this.href},function(t,n,i){n&&Si(t.prototype,n),i&&Si(t,i)}(t,[{key:"href",get:function(){return function(t,n){void 0===n&&(n=!1);var i=t.Yp+":";if(null!==t.Jp?(i+="//",fr(t)&&(i+=t.Kp,""!==t.jp&&(i+=":"+t.jp),i+="@"),i+=Ce(t.Jp),null!==t.ew&&(i+=":"+t.ew)):null===t.Jp&&"file"===t.Yp&&(i+="//"),t.$p)i+=t.Qp[0];else for(var e=0,r=t.Qp;e<r.length;e++)i+="/"+r[e];return null!==t.Xp&&(i+="?"+t.Xp),n||null===t.iw||(i+="#"+t.iw),i}(this.ic)},set:function(t){var n;try{n=mr(String(t),null)}catch(t){throw new m("Invalid URL: "+t.message)}this.ic=n,Xe(this.Xp);var i=this.ic.Xp;null!==i&&je(this.Xp,i)}},{key:"origin",get:function(){return _r(this.ic)}},{key:"protocol",get:function(){return this.ic.Yp+":"},set:function(t){pr(t+":",null,this.ic,0)}},{key:"username",get:function(){return this.ic.Kp},set:function(t){lr(this.ic)||(this.ic.Kp=Ee(t,ye))}},{key:"password",get:function(){return this.ic.jp},set:function(t){lr(this.ic)||(this.ic.jp=Ee(t,ye))}},{key:"host",get:function(){var t=this.ic,n=t.Jp;if(null===n)return"";var i=t.ew,e=Ce(n);return null!==i&&(e+=":"+i),e},set:function(t){this.ic.$p||pr(t,null,this.ic,10)}},{key:"hostname",get:function(){var t=this.ic.Jp;return null===t?"":Ce(t)},set:function(t){this.ic.$p||pr(t,null,this.ic,11)}},{key:"port",get:function(){var t=this.ic.ew;return null===t?"":""+t},set:function(t){lr(this.ic)||(""===t?this.ic.ew=null:pr(t,null,this.ic,12))}},{key:"pathname",get:function(){var t=this.ic.Qp;return this.ic.$p?t[0]:0===t.length?"":"/"+t.join("/")},set:function(t){this.ic.$p||(this.ic.Qp.length=0,pr(t,null,this.ic,16))}},{key:"search",get:function(){var t=this.ic.Xp;return null===t||""===t?"":"?"+t},set:function(t){t=ze(t);var n=this.ic;if(""===t)return n.Xp=null,void Xe(this.Xp);"?"===t[0]&&(t=t.slice(1)),n.Xp="",pr(t,null,n,19),je(this.Xp,t)}},{key:"searchParams",get:function(){return this.Xp}},{key:"hash",get:function(){var t=this.ic.iw;return null===t||""===t?"":"#"+t},set:function(t){""!==t?("#"===t[0]&&(t=t.slice(1)),this.ic.iw="",pr(t,null,this.ic,20)):this.ic.iw=null}}]),t}();function Tr(t){return t.document&&t.document.baseURI||t.location.href||""}x(),gt();var Er=function(){function t(){this.Aw=new Ir,this.Ew=ri,this.Tw=kr(),self.performance&&self.performance.now?this.Wm=function(){return self.performance.now()}:this.Wm=Kn}var n=t.prototype;return n.nw=function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];mi.apply(void 0,nn(n))},n.ow=function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];pi.apply(void 0,nn(n))},n.hw=function(){for(var t=arguments.length,n=new Array(t),i=0;i<t;i++)n[i]=arguments[i];yi.apply(void 0,nn(n))},n.aw=function(t){for(var n=arguments.length,i=new Array(n>1?n-1:0),e=1;e<n;e++)i[e-1]=arguments[e];_i.apply(void 0,[t].concat(nn(i)))},n.Gm=function(t,n){return d(t,n)},n.uw=function(t,n){return w(t,n)},n.Um=function(t){l(t)},n.cw=function(t){b(t)},n.lw=function(){return this.dw.lw()},n.fw=function(){return this.dw.fw()},n._w=function(){return this.dw._w()},n.gw=function(){return this.dw.gw()},n.mw=function(){return this.dw.mw()},n.pw=function(t,n){return this.dw.pw(t,n)},n.ww=function(t){return this.dw.ww(t)},n.Bh=function(t,n){var i;return void 0===n&&(n=Tr(h)),i="object"!==(void 0===n?"undefined":B(n))||n instanceof Sr?n:n.href,new Sr(t,i)},n.Sw=function(t,n){if(void 0===n&&(n=Tr(h)),this.Tw){var i=function(t){return"string"==typeof t}(n)?n:n.toString();return new self.URL(t,i).href}return this.Bh(t,n).href},Tt(t,[{key:"yw",get:function(){return this.Aw}},{key:"Ys",get:function(){return this.Ew}},{key:"xw",get:function(){return{Iw:v&&v.userAgent.match(/Android /i)?"Android":"other",Rw:Boolean(v&&v.userAgent.match(/Android 8.0.0/i))}}},{key:"Cw",get:function(){return self&&self.location&&"https:"===self.location.protocol}},{key:"Pw",get:function(){return"languages"in v?v.languages.slice():[v.language]}}]),t}(),Ir=function(){function t(){}return Tt(t,[{key:"Dw",get:function(){return v.oscpu}},{key:"Ys",get:function(){return v.platform}},{key:"Nw",get:function(){return v.vendor}},{key:"Mw",get:function(){return v.vendorSub}}]),t}();function kr(){if(self.URL)try{var t=new self.URL("b","http://a");return t.pathname="c d","http://a/c%20d"===t.href}catch(t){}return!1}x(),gt();var Rr=function(){function t(){}var n=t.prototype;return n.mw=function(){return J.resolve(!1)},n.fw=function(){return J.resolve(!1)},n.gw=function(){return J.resolve(!1)},n._w=function(){return J.resolve(!1)},n.ww=function(t){return J.resolve(!1)},n.pw=function(t,n){return J.resolve(!1)},n.lw=function(){return J.resolve(!1)},t}();x(),gt();var Or=function(){function t(){}var n=t.prototype;return n.yk=function(){},n.Vb=function(t){},n.Bb=function(t){},n.Ob=function(t,n){},t}();x(),gt();var Nr="default",Pr="unknown";x(),gt(),x(),gt(),x(),gt();var Ar=function(t){return t.Ak="arraybuffer",t.Sk="json",t.Tk="stream",t.Ek="text",t}({});function Dr(t,i){return function(t){if(Array.isArray(t))return t}(t)||function(t,i){var r=null==t?null:void 0!==n&&t[e]||t["@@iterator"];if(null!=r){var o,u,s=[],f=!0,c=!1;try{for(r=r.call(t);!(f=(o=r.next()).done)&&(s.push(o.value),!i||s.length!==i);f=!0);}catch(t){c=!0,u=t}finally{try{f||null==r.return||r.return()}finally{if(c)throw u}}return s}}(t,i)||tn(t,i)||function(){throw new m("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt();var Cr=function(){function t(n){var i=this;this.P_={},n instanceof t?n.asList().forEach((function(t){var n=Dr(t,2),e=n[0],r=n[1];i.append(e,r)})):Array.isArray(n)?n.forEach((function(t){var n=Dr(t,2),e=n[0],r=n[1];i.append(e,r)})):n&&p.getOwnPropertyNames(n).forEach((function(t){i.append(t,n[t])}))}var n=t.prototype;return n.append=function(t,n){var i=t,e=n;i=xr(i),e=Br(e);var r=i.toLowerCase();if(this.P_.hasOwnProperty(r)){var o=this.P_[r],u=o[1];o[1]=u?u+", "+e:e}else this.P_[r]=[i,e]},n.delete=function(t){var n=xr(t).toLowerCase();delete this.P_[n]},n.get=function(t){var n=xr(t).toLowerCase();return this.P_.hasOwnProperty(n)?this.P_[n][1]:null},n.has=function(t){var n=xr(t).toLowerCase();return this.P_.hasOwnProperty(n)},n.set=function(t,n){var i=t,e=(i=xr(i)).toLowerCase();this.P_[e]=[i,Br(n)]},n.forEach=function(t,n){for(var i in this.P_)this.P_.hasOwnProperty(i)&&t.call(n,this.P_[i][1],i,this)},n.asList=function(){var t=[];for(var n in this.P_)if(this.P_.hasOwnProperty(n)){var i=Dr(this.P_[n],2),e=i[0],r=i[1];t.push([e,r])}return t},n.xk=function(){var t={};return this.forEach((function(n,i){t[i]=n})),t},n.Ik=function(t){var n=this;t.forEach((function(t,i){n.append(i,t)}))},n.Rk=function(t){var n=this;t.forEach((function(t,i){n.set(i,t)}))},t}();function xr(t){var n=t;if("string"!=typeof n&&(n=String(n)),/[^a-z0-9\-#$%&'*+.^_`|~]/i.test(n))throw new m("Invalid character in header field name");return n}function Br(t){var n=t;return"string"!=typeof n&&(n=String(n)),n}var Mr=function(t){return t.DELETE="DELETE",t.GET="GET",t.HEAD="HEAD",t.OPTIONS="OPTIONS",t.POST="POST",t.PUT="PUT",t}({}),Lr=function(t){return t.wE="same-origin",t.yE="no-cors",t.bE="cors",t.AE="navigate",t}({}),Ur=function(t,n){var i,e,r,o,u,s,f,c,h,a,v,d,l,w,b,g,m,p,y=t.Xu;n?(i=n.Bk,e=n.$k,r=n.SE,o=n.Qk,u=n.TE,s=n.kE,f=n.ep,c=n.Hw,h=n.EE,a=n.xE,v=n.RE,d=n.CE,l=n.PE,w=n.DE,b=n.NE):(i=null,e={},r="GET",o=Ar.Ek,u=0,s=0,c="",h="",a="",v=!1,l=void 0,w=!1,b=void 0),this.Xu=y,this.Bk=t.Bk||i,this.$k=new Cr(t.$k||e),this.SE=t.SE||r,this.Qk=t.Qk||o,this.TE=void 0!==t.TE?Number(t.TE)||0:u,this.kE=void 0!==t.kE?Number(t.kE)||0:s,this.ep=t.ep||f||(new an).ep,this.Hw=t.Hw||c,this.EE=t.EE||h,this.xE=t.xE||a,this.RE=void 0!==t.RE?Boolean(t.RE):v,this.CE=t.CE||d,this.PE=null!=(g=t.PE)?g:l,this.DE=null!=(m=t.DE)?m:w,this.NE=null!=(p=t.NE)?p:b};x(),gt(),x(),gt();var Fr=function(t){return t.ZE="HttpOpenError",t.HE="HttpResponseError",t.XE="HttpTimeoutError",t}({}),zr=function(t){function n(n,i,e){var r;return(r=t.call(this,i,e)||this).zE=n,r}return _t(n,t),Tt(n,[{key:"Jk",get:function(){return this.zE}}]),n}(dn);var Wr=function(t){function n(n,i){return t.call(this,n,function(t){return"Error while opening "+t+". Invalid URL."}(n.Xu),i)||this}return _t(n,t),Tt(n,[{key:"name",get:function(){return Fr.ZE}}]),n}(zr),Vr=function(){function t(){}var n=t.prototype;return n.Jk=function(t){return J.reject(new Wr(new Ur(t)))},n.LE=function(t){},n.yn=function(){},t}();x(),gt();var Hr=function(t){function n(n){return t.call(this,"Invalid XML",n)||this}return _t(n,t),n}(dn),qr=function(t){function n(){var n;return(n=t.apply(this,arguments)||this).eI=new Rr,n.xW=new Vr,n.i=new Or,n}return _t(n,t),n.prototype.Cx=function(t){throw new Hr},Tt(n,[{key:"dw",get:function(){return this.eI}},{key:"iI",get:function(){return!1}},{key:"nI",get:function(){return!1}},{key:"aI",get:function(){return!1}},{key:"oI",get:function(){return!1}},{key:"uI",get:function(){return this.i}},{key:"cI",get:function(){return{lI:Yt}}},{key:"dI",get:function(){return Nr}},{key:"fI",get:function(){return Pr}},{key:"_I",get:function(){return this.xW}}]),n}(Er);function Xr(){return Xr=p.assign||function(t){for(var n=1;n<arguments.length;n++){var i=arguments[n];for(var e in i)p.prototype.hasOwnProperty.call(i,e)&&(t[e]=i[e])}return t},Xr.apply(this,arguments)}function jr(){var t=p.create(null);return t.Lw=void 0,delete t.Lw,t}function Yr(){return new Gr}jt(new qr),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt();var Kr="undefined"!=typeof Map&&"entries"in Map.prototype?Map:void 0,Gr=Kr||function(){var t=function(){function t(t,n){this.index=0,this.data=t,this.selector=n,this.keys=p.keys(t)}return t.prototype.next=function(){var t=this.index;return t<this.keys.length?(this.index++,{value:this.selector(this.data,this.keys[t]),done:!1}):{value:void 0,done:!0}},t}();return function(){function n(){this.data=jr(),this.size=0}var i=n.prototype;return i.get=function(t){return this.data[t]},i.set=function(t,n){return this.has(t)||this.size++,this.data[t]=n,this},i.has=function(t){return t in this.data},i.delete=function(t){return!!this.has(t)&&(this.size--,delete this.data[t],!0)},i.clear=function(){this.data=jr(),this.size=0},i.keys=function(){return new t(this.data,(function(t,n){return n}))},i.values=function(){return new t(this.data,(function(t,n){return t[n]}))},i.entries=function(){return new t(this.data,(function(t,n){return[n,t[n]]}))},i.forEach=function(t){for(var n in this.data)t(this.data[n],n)},n}()}();Kr||function(){var t=function(){function t(t,n){this.Bw=t,this.Ow=n}return t.prototype.next=function(){var t=this.Bw.next();return t.done?t:{value:this.Ow(t.value),done:!1}},t}();(function(){function n(){this.P_=Yr()}var i=n.prototype;i.get=function(t){return this.P_.get(""+t)},i.set=function(t,n){return this.P_.set(""+t,n),this},i.has=function(t){return this.P_.has(""+t)},i.delete=function(t){return this.P_.delete(""+t)},i.clear=function(){this.P_.clear()},i.keys=function(){return new t(this.P_.keys(),(function(t){return Number(t)}))},i.values=function(){return this.P_.values()},i.entries=function(){return new t(this.P_.entries(),(function(t){var n=Dr(t,2),i=n[0],e=n[1];return[Number(i),e]}))},i.forEach=function(t){this.P_.forEach((function(n,i){t(n,Number(i))}))},Tt(n,[{key:"size",get:function(){return this.P_.size}}])})()}();x(),gt(),x(),gt();var $r="9a04f079-9840-4286-ab92-e65be0885f95",Zr="urn:uuid:"+$r,Jr="com.microsoft.playready",Qr="edef8ba9-79d6-4ace-a3c8-27dcd51d21ed",to="urn:uuid:"+Qr,no="com.widevine.alpha",io="1077efec-c0b2-4d02-ace3-3c1e52e2fb4b",eo="urn:uuid:"+io,ro="org.w3.clearkey",oo="94ce86fb-07ff-4f43-adb8-93d2fa968ca2",uo="urn:uuid:"+oo,so="com.apple.fps.1_0";x(),gt();var fo=function(t){return t.Fw="playready",t.Vw="widevine",t.Gw="fairplay",t.Ww="clearkey",t.Uw="clearkey_dash_if",t.Zw="aes128",t}({}),co={Hw:fo.Fw,Xw:Jr,zw:"cenc",qw:$r,Yw:Zr,Kw:"PlayReady"},ho={Hw:fo.Vw,Xw:no,zw:"cenc",qw:Qr,Yw:to,Kw:"Widevine"},ao={Hw:fo.Gw,Xw:so,zw:"skd",qw:oo,Yw:uo,Kw:"FairPlay"},vo=(fo.Gw,{Hw:fo.Ww,Xw:ro,zw:"cenc",qw:io,Yw:eo,Kw:"ClearKey"});fo.Uw;x(),gt();String.prototype.replaceAll;var lo="function"==typeof String.prototype.startsWith?function(t,n){return zt(t)&&t.startsWith(n)}:function(t,n){return zt(t)&&t.substr(0,n.length)===n},wo=(String.prototype.endsWith,"function"==typeof String.prototype.repeat?function(t,n){return t.repeat(n)}:function(t,n){var i=0|n;if(0===t.length||0===i)return"";for(var e=t,r="";1==(1&i)&&(r+=e),0!=(i>>>=1);)e+=e;return r}),bo=(String.prototype.padStart,String.prototype.padEnd,16384),go="function"==typeof String.fromCodePoint?function(t){var n;return t.length<=bo?(n=String).fromCodePoint.apply(n,nn(t)):po(t,String.fromCodePoint)}:function(t){for(var n=[],i=0;i<t.length;i++){var e=t[i];e>65535&&(e-=65536,n.push(e>>>10&1023|55296),e=56320|1023&e),n.push(e)}return mo(n)};function mo(t){var n;return t.length<=bo?(n=String).fromCharCode.apply(n,nn(t)):po(t,String.fromCharCode)}function po(t,n){for(var i=[],e=0;e<t.length;e+=bo)i.push(n.apply(void 0,nn(t.slice(e,e+bo))));return i.join("")}var yo=Ut.gg&&Ut.wg>=42||Ut.Kg&&Ut.Qg>=38||Ut.Ug||Ut.Xg||Ut.um&&Ut.dm>=29;function _o(t,n){return function(t,n){return zt(t)&&-1!==t.indexOf(n)}(t,"audio")?{initDataTypes:["cenc"],audioCapabilities:[Xr({contentType:t},n?{robustness:"SW_SECURE_CRYPTO"}:{})]}:{initDataTypes:["cenc"],videoCapabilities:[Xr({contentType:t},n?{robustness:"SW_SECURE_CRYPTO"}:{})]}}var So=function(){function t(t){this.jw=Yr(),this.$w=void 0,this.Jw=t}var n=t.prototype;return n.mw=function(){return this.ww(ho)},n.fw=function(){return this.ww(vo)},n.gw=function(){return this.ww(co)},n._w=function(){return this.ww(ao)},n.ww=function(t){var n=t.Yw,i=this.jw.get(n);if(i)return i;var e=this.pw(t,'video/mp4; codecs="avc1.42000a"');return this.jw.set(n,e),e},n.pw=function(t,n){var i=this;return $t((function(){return Zt(this,(function(e){switch(e.label){case 0:return e.trys.push([0,2,,7]),[4,i.Jw.Qw(t.Xw,[_o(n,!0)])];case 1:return e.sent(),[2,!0];case 2:e.sent(),e.label=3;case 3:return e.trys.push([3,5,,6]),[4,i.Jw.Qw(t.Xw,[_o(n,!1)])];case 4:return e.sent(),[2,!0];case 5:return e.sent(),[2,!1];case 6:return[3,7];case 7:return[2]}}))}))()},n.lw=function(){return this.$w||(this.$w=this.ey()),this.$w},n.ey=function(){var t=this;return $t((function(){return Zt(this,(function(n){switch(n.label){case 0:return"https:"===h.location.protocol?[2,!1]:yo?[4,t.fw()]:[2,!1];case 1:return n.sent()?[2,!1]:[2,!0]}}))}))()},t}();function To(t,n,i){if("function"==typeof i)i.call(t,n);else for(var e=0;e<i.length;e++){i[e].call(t,n)}}x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt();var Eo=function(){function t(t){var n=this;this.sy=jr(),this.ly=void 0,this.oy=0,this.Ds=function(t){n._o(t)},this._y=null!=t?t:this}var n=t.prototype;return n.bn=function(t,n){if("function"==typeof n)if("string"==typeof t)this.iy(t,n);else for(var i=0;i<t.length;i++){var e=t[i];this.iy(e,n)}},n.iy=function(t,n){var i=this.sy[t];void 0===i?this.sy[t]=n:"function"==typeof i?this.sy[t]=[i,n]:0===this.oy?i.push(n):this.sy[t]=i.concat(n)},n.uy=function(t){if("function"==typeof t){var n=this.ly;void 0===n?this.ly=t:"function"==typeof n?this.ly=[n,t]:0===this.oy?n.push(t):this.ly=n.concat(t)}},n.Ro=function(){this.sy=jr(),this.ly=void 0},n._o=function(t){this.oy++;var n=this.sy[t.type],i=this.ly;void 0!==n&&To(this._y,t,n),void 0!==i&&To(this._y,t,i),this.oy--},n.vn=function(t,n){if("function"==typeof n)if("string"==typeof t)this.vy(t,n);else for(var i=0;i<t.length;i++){var e=t[i];this.vy(e,n)}},n.vy=function(t,n){var i=this.sy[t];void 0!==i&&("function"==typeof i?i===n&&(this.sy[t]=void 0):0===this.oy?un(i,n):this.sy[t]=sn(i,n))},n.gy=function(t){if("string"==typeof t)this.sy[t]=void 0;else for(var n=0;n<t.length;n++){var i=t[n];this.sy[i]=void 0}},n.py=function(t){var n=this.ly;void 0!==n&&("function"==typeof n?n===t&&(this.ly=void 0):0===this.oy?un(n,t):this.ly=sn(n,t))},n.wy=function(t,n){var i=this;return new J((function(e,r){if(n&&n.zm)return r(new ln);var o=function(t){s(),e(t)},u=function(){s(),r(new ln)},s=function(){i.vn(t,o),n&&n.Jm(u)};i.bn(t,o),n&&n.Qm(u)}))},t}();x(),gt(),x(),gt();var Io=function(t,n){void 0===n&&(n=new Date),this.type=t,this.date=n};x(),gt();var ko=function(t){return t.yy="Ay",t.Sy="Ty",t.Ey="contentprotectionerror",t.xy="contentprotectionsuccess",t.Iy="currentsourcechange",t.Ry="destroy",t.Cy="durationchange",t.Py="emptied",t.Dy="encrypted",t.Ny="ended",t.My="Ly",t.By="Oy",t.Fy="Vy",t.Wy="Uy",t.Gy="loadstart",t.Zy="manifestupdate",t.Hy="nosupportedrepresentationfound",t.Xy="offline",t.zy="online",t.qy="pause",t.ho="play",t.Yy="progress",t.Ky="ratechange",t.jy="representationchange",t.Qy="resize",t.Jy="seeked",t.$y="seeking",t.eb="segmentnotfound",t.ib="sb",t.ob="hb",t.uo="sourcechange",t.ub="timeupdate",t.fb="volumechange",t._b="vb",t.gb="mb",t.pb="metricschange",t}({}),Ro=["cenc"],Oo=["cbcs","cbcs-1-9"],No=function(t){function n(n){var i;return(i=t.call(this,ko.gb)||this).wb=n,i}return _t(n,t),n}(Io),Po=function(t){function n(n,i,e,r){var o;return(o=t.call(this,"yb")||this).bb=n,o.Ab=i,o.yb=e,o.Sb=r,o}return _t(n,t),n}(Io),Ao=function(t){function n(){return t.call(this,"lt")||this}return _t(n,t),n}(Io);x(),gt(),x(),gt(),x(),gt();var Do="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/".split(""),Co=16383;function xo(t,n,i){return Do[t>>2]+Do[(3&t)<<4|n>>4]+Do[(15&n)<<2|i>>6]+Do[63&i]}function Bo(t,n,i){for(var e=[],r=n;r<i;r+=3)e.push(xo(t[r],t[r+1],t[r+2]));return e.join("")}x(),gt(),x(),gt();var Mo=function(){function t(t){void 0===t&&(t=0),this.rc=t}var n=t.prototype;return n.Ib=function(t){this.rc+=t},n.Rb=function(t){this.rc=t},n.Cb=function(){return new t(this.nc)},Tt(t,[{key:"nc",get:function(){return this.rc}}]),t}();function Lo(t){if(t>=55296&&t<=57343)throw new g("Lone surrogate U+"+t.toString(16).toUpperCase()+" is not a scalar value")}function Uo(t,n){return t>>n&63|128}function Fo(t,n){0!=(4294967168&t)?(0==(4294965248&t)?n.push(t>>6&31|192):0==(4294901760&t)?(Lo(t),n.push(t>>12&15|224),n.push(Uo(t,6))):0==(4292870144&t)&&(n.push(t>>18&7|240),n.push(Uo(t,12)),n.push(Uo(t,6))),n.push(63&t|128)):n.push(t)}function zo(t,n){if(n.nc>=t.length)throw new g("Invalid byte index");var i=255&t[n.nc];if(n.Ib(1),128==(192&i))return 63&i;throw new g("Invalid continuation byte")}function Wo(t,n){var i=n.nc;if(i>t.length)throw new g("Invalid byte index");if(i===t.length)return!1;var e=255&t[i];if(n.Ib(1),0==(128&e))return e;if(192==(224&e)){var r=(31&e)<<6|zo(t,n);if(r>=128)return r;throw new g("Invalid continuation byte")}if(224==(240&e)){var o=(15&e)<<12|zo(t,n)<<6|zo(t,n);if(o>=2048)return Lo(o),o;throw new g("Invalid continuation byte")}if(240==(248&e)){var u=(7&e)<<18|zo(t,n)<<12|zo(t,n)<<6|zo(t,n);if(u>=65536&&u<=1114111)return u}throw new g("Invalid UTF-8 detected")}x(),gt(),x(),gt();var Vo=65279;function Ho(t,n,i){void 0===i&&(i=!1);var e=t.getUint16(n.nc,i);return n.Ib(2),e}function qo(t,n,i,e){void 0===e&&(e=!1),t.setUint16(n.nc,i,e),n.Ib(2)}function Xo(t,n,i,e){void 0===e&&(e=!1),t.setUint32(n.nc,i,e),n.Ib(4)}function jo(t,n,i,e){void 0===e&&(e=!1);for(var r=i.length,o=0;o<r;o+=1){qo(t,n,i.charCodeAt(o),e)}}function Yo(t,n){return void 0===n&&(n=!1),function(t,n,i,e){for(var r=[];n.nc+2<=t.byteLength;){var o=Ho(t,n,i);if(e&&!o)break;r.push(o)}return mo(r)}($o(t),new tu,n,!1)}function Ko(t){return function(t){return go(t)}(function(t,n){var i,e=[],r=new tu;if(!n){if(!1===(i=Wo(t,r)))return e;i===Vo||e.push(i)}for(;!1!==(i=Wo(t,r));)e.push(i);return e}(Zo(t)))}function Go(t){return new E(function(t){for(var n=[],i=0;i<t.length;i++)Fo(t[i],n);return n}(function(t){for(var n=[],i=0,e=t.length;i<e;){var r=t.charCodeAt(i++);if(r>=55296&&r<=56319&&i<e){var o=t.charCodeAt(i++);56320==(64512&o)?n.push(((1023&r)<<10)+(1023&o)+65536):(n.push(r),i--)}else n.push(r)}return n}(t)))}function $o(t){return new DataView(t.buffer,t.byteOffset,t.byteLength)}function Zo(t){return new E(t.buffer,t.byteOffset,t.byteLength)}function Jo(t){return t instanceof ArrayBuffer?new E(t):Zo(t)}function Qo(t){if(t.slice)return t.slice(0);var n=new E(t.byteLength);return n.set(t,0),n}var tu=function(){function t(t){void 0===t&&(t=0),this.rc=t}var n=t.prototype;return n.Ib=function(t){this.rc+=t},n.Rb=function(t){this.rc=t},n.Cb=function(){return new t(this.nc)},n.Nb=function(){return new Mo(this.nc<<3)},Tt(t,[{key:"nc",get:function(){return this.rc}}]),t}(),nu=["[object Int8Array]","[object Uint8Array]","[object Uint8ClampedArray]","[object Int16Array]","[object Uint16Array]","[object Int32Array]","[object Uint32Array]","[object Float32Array]","[object Float64Array]","[object DataView]"],iu=ArrayBuffer.isView||function(t){return t&&fn(nu,Ft.call(t))};function eu(t,n){return t===n||function(t,n){if(t===n)return!0;if(t.byteLength!==n.byteLength)return!1;if(t.buffer===n.buffer&&t.byteOffset===n.byteOffset)return!0;for(var i=0;i<t.length;i+=1)if(t[i]!==n[i])return!1;return!0}(Jo(t),Jo(n))}function ru(t){var n=t.reduce((function(t,n){return t+n.byteLength}),0);return function(t,n){for(var i=new E(n),e=0,r=0;r<t.length;r++){var o=t[r];i.set(o,e),e+=o.byteLength}return i}(t,n)}function ou(t){return function(t){for(var n=t.length,i=n%3,e=[],r=n-i,o=0;o<r;o+=Co)e.push(Bo(t,o,y.min(r,o+Co)));if(1===i){var u=t[n-1];e.push(Do[u>>2]+Do[(3&u)<<4]+"==")}else if(2===i){var s=t[n-2],f=t[n-1];e.push(Do[s>>2]+Do[(3&s)<<4|f>>4]+Do[(15&f)<<2]+"=")}return e.join("")}(new E(t))}var uu=new E([0]).buffer,su=function(){function t(){this.tc=[]}var n=t.prototype;return n.Lb=function(t){for(var n=0,i=this.tc;n<i.length;n++){if(eu(i[n][0],t))return!0}return!1},n.Bb=function(t){for(var n=0,i=this.tc;n<i.length;n++){var e=i[n];if(eu(e[0],t))return e[1]}},n.Ob=function(t,n){for(var i=0,e=this.tc;i<e.length;i++){var r=e[i];if(eu(r[0],t))return void(r[1]=n)}this.tc.push([t,n])},n.Fb=function(t,n){this.tc.forEach((function(n){return t(n[1],n[0])}),n)},n.Vb=function(){cn(this.tc)},Tt(t,[{key:"Mb",get:function(){return this.tc.length}}]),t}();x(),gt();var fu=function(){function t(){var t=this;this.Gb=new J((function(n,i){t.Gd=n,t.Zd=i}))}var n=t.prototype;return n.Wb=function(t){this.Gd&&(this.Gd(t),this.Km())},n.Ub=function(t){this.Zd&&(this.Zd(t),this.Km())},n.np=function(){this.Gb.catch(Yt),this.Ub(new ln)},n.rp=function(t){var n=this;t.then((function(t){return n.Wb(t)}),(function(t){return n.Ub(t)}))},n.Km=function(){this.Gd=void 0,this.Zd=void 0},t}();function cu(t,n){return t===Jr?function(t){if(t.byteLength<2*hu.length)return t;var n=new DataView(t,0,2*hu.length),i=Yo(n,!0);if(i===hu)return t;return function(t){var n='<PlayReadyKeyMessage type="LicenseAcquisition"><LicenseAcquisition Version="1"><Challenge encoding="base64encoded">',i='</Challenge><HttpHeaders><HttpHeader><name>Content-Type</name><value>text/xml; charset=utf-8</value></HttpHeader><HttpHeader><name>SOAPAction</name><value>"http://schemas.microsoft.com/DRM/2007/03/protocols/AcquireLicense"</value></HttpHeader></HttpHeaders></LicenseAcquisition></PlayReadyKeyMessage>',e=""+n+ou(t)+i;return function(t,n){void 0===n&&(n=!1);var i=new E(2*t.length);return jo($o(i),new tu,t,n),i}(e,!0).buffer}(t)}(n):n}x(),gt();var hu="<PlayReady";x(),gt(),x(),gt();var au=function(t){function n(n,i,e,r){var o;return(o=t.call(this,n,r)||this).Zb=i,o.Hb=e,o}return _t(n,t),n}(dn);x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt();var vu=function(t,n){return(vu=p.setPrototypeOf||{__proto__:[]}instanceof Array&&function(t,n){t.__proto__=n}||function(t,n){for(var i in n)p.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])})(t,n)};function du(t,n){if("function"!=typeof n&&null!==n)throw new m("Class extends value "+String(n)+" is not a constructor or null");function i(){this.constructor=t}vu(t,n),t.prototype=null===n?p.create(n):(i.prototype=n.prototype,new i)}function lu(t,n,i){return t.indexOf?t.indexOf(n,i):Array.prototype.indexOf.call(t,n,i)}x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt();!function(){function t(t,n){this.Xb=t,this.zb=n}t.prototype.get=function(t){var n=this.Xb.get(t);if(0===this.zb||void 0===n)return n;var i=this.Xb.get(t+1)||0,e=n&(1<<8-this.zb)-1,r=i>>8-this.zb;return(e<<this.zb)+r},t.prototype.getBit=function(t){if(!(t<0)){var n=this.Xb.get(y.floor((t+this.zb)/8));if(void 0!==n)return(n&1<<7-this.zb-t%8)>0?1:0}},p.defineProperty(t.prototype,"bitLength",{get:function(){return this.Xb.bitLength-this.zb},enumerable:!1,configurable:!0}),p.defineProperty(t.prototype,"length",{get:function(){return this.Xb.length},enumerable:!1,configurable:!0})}();x(),gt(),x(),gt();y.pow(2,-52);function wu(t,n,i){return y.min(y.max(t,n),i)}function bu(t,n){return t>>8-n}function gu(t,n){return t&(1<<n)-1}var mu=function(){function t(t){this.qb=t,this.Yb=0,this.Kb=0}return p.defineProperty(t.prototype,"totalBitsRead",{get:function(){return 8*this.Yb+this.Kb},enumerable:!1,configurable:!0}),p.defineProperty(t.prototype,"done",{get:function(){return this.Yb===this.qb.length&&0===this.Kb},enumerable:!1,configurable:!0}),p.defineProperty(t.prototype,"location",{get:function(){return{byte:this.Yb,bit:this.Kb}},enumerable:!1,configurable:!0}),t.prototype.copy=function(){var n=new t(this.qb);return n.seek(this.Yb,this.Kb),n},t.prototype.canReadBits=function(t){return 8*this.Yb+t+this.Kb<=8*this.qb.length},t.prototype.canReadBytes=function(t){return 0===this.Kb?this.Yb+t<=this.qb.length:this.Yb+t<this.qb.length},t.prototype.incBit=function(){this.Kb++,this.Kb>7&&(this.Yb++,this.Kb=0)},t.prototype.seek=function(t,n){this.Yb=t,this.Kb=n},t.prototype.peekBit=function(){if(!this.canReadBits(1))throw new g("Cannot read past end of buffer.");return this.qb.get(this.Yb)>>7-this.Kb&1},t.prototype.readBit=function(){var t=this.peekBit();return this.incBit(),t},t.prototype.readByte=function(){if(!this.canReadBytes(1))throw new g("Cannot read past end of buffer.");if(0===this.Kb)return this.qb.get(this.Yb++);var t=gu(this.qb.get(this.Yb),8-this.Kb),n=bu(this.qb.get(this.Yb+1),this.Kb);return this.Yb++,t<<this.Kb|n},t.prototype.readBits=function(t){if(!this.canReadBits(t))throw new g("Cannot read past end of buffer.");for(var n=[],i=0;i<t;i++)n.push(this.readBit());return n},t.prototype.readUInt=function(t){if(t>32)throw new g("The max bitlength that can be provided is 32.");if(!this.canReadBits(t))throw new g("Cannot read past end of buffer.");var n=0;if(0===this.Kb&&t%8==0)for(var i=t-8;i>=0;i-=8)n|=this.readByte()<<i;else for(i=t-1;i>=0;i--)n|=this.readBit()<<i;return n},t.prototype.readInt=function(t){if(t>32)throw new g("The max bitlength that can be provided is 32.");if(!this.canReadBits(t))throw new g("Cannot read past end of buffer.");var n=this.readUInt(t);return 0===(n&1<<t-1)?n:n-y.pow(2,t)},t.prototype.readExponentialGolombCode=function(){for(var t=0;0===this.readBit();)t++;var n=1<<t;return n+=this.readUInt(t)-1},t.prototype.readSignedExponentialGolombCode=function(){var t=this.readExponentialGolombCode();return 1&t?(t+1)/2:-t/2},t.prototype.skipBits=function(t){if(!this.canReadBits(t))throw new g("Skipping over the buffer edge is not allowed.");var n=this.Kb+t;this.Yb+=n>>3,this.Kb=7&n},t.prototype.readBool=function(){return this.readBit()>0},t.prototype.readString=function(t){if(!this.canReadBytes(t))throw new g("Cannot read past end of buffer.");for(var n=[],i=0;i<t;i++)n.push(this.readByte());return String.fromCharCode.apply(String,n)},t}();x(),gt(),x(),gt(),x(),gt();var pu=function(t,n){return t===n?0:t<n?-1:t>n?1:T(t)?T(n)?0:1:-1},yu=function(){function t(){this.jb=[],this.Qb=[],this.Jb=0}return t.from=function(){for(var n=[],i=0;i<arguments.length;i++)n[i]=arguments[i];for(var e=new t,r=0,o=n;r<o.length;r++){var u=o[r];e.pushRange(u)}return e},t.prototype.pushRange=function(t,n,i){if(void 0===n&&(n=0),void 0===i&&(i=t.length),i<0)throw new g("The buffer length must be positive.");if(0!==i){if(0===this.Qb.length)this.Qb.push(0);else{var e=this.Qb[this.Qb.length-1]+this.jb[this.jb.length-1].length;this.Qb.push(e)}this.jb.push(t.subarray(n,n+i)),this.Jb+=i}},t.prototype.concat=function(n){var i=new t;return i.pushRange(this.join()),i.pushRange(n.join()),i},t.prototype.copy=function(t,n,i,e){if(void 0===n&&(n=0),void 0===i&&(i=0),void 0===e&&(e=this.length),n<0||i<0||e<0)throw new RangeError;return this.slice(i,e).copyInternal(t,n)},t.prototype.copyInternal=function(t,n){for(var i=0,e=n,r=0,o=this.jb;r<o.length;r++){var u=o[r];t.set(u,e),i+=u.length,e+=u.length}return i},t.prototype.clear=function(){this.jb=[],this.Qb=[],this.Jb=0},t.prototype.get=function(t){if(!(t<0||t>=this.length)){var n=this.findContainingBufferIndex(t),i=t-this.Qb[n];return this.jb[n][i]}},p.defineProperty(t.prototype,"first",{get:function(){return this.get(0)},enumerable:!1,configurable:!0}),t.prototype.indexOf=function(t){if(this.jb.length<1)return-1;if(this.jb.length>1){var n=this.join();this.clear(),this.pushRange(n)}var i=this.jb[0];return"number"==typeof t?lu(i,t):"undefined"!=typeof Buffer?Buffer.from(i.buffer,i.byteOffset,i.byteLength).indexOf(t):function(t,n){if(0===n.length)return 0;for(var i=n[0],e=n.length,r=t.length-e,o=0;o<=r&&!((o=lu(t,i,o))<0||o>r);o++){for(var u=o+1,s=o+e,f=1;u<s&&t[u]===n[f];u++,f++);if(u===s)return o}return-1}(i,t)},t.prototype.findContainingBufferIndex=function(t){return function(t,n,i){if(0!==t.length){var e=0,r=t.length-1;if(1!==i(t[e],n)){if(1===i(n,t[r]))return r;for(;e!==r;){var o=y.ceil((e+r)/2);i(t[o],n)<=0?e=o:r=o-1}return e}}}(this.Qb,t,pu)},t.prototype.join=function(){if(1===this.jb.length)return this.jb[0];var t=new E(this.length);return this.copyInternal(t,0),t},p.defineProperty(t.prototype,"length",{get:function(){return this.Jb},enumerable:!1,configurable:!0}),p.defineProperty(t.prototype,"bitLength",{get:function(){return 8*this.length},enumerable:!1,configurable:!0}),t.prototype.readUIntBE=function(t,n){if(n<=0||n>4)throw new g("Expected byteLength to be between 0 and 4 but was "+n);if(t<0||t>this.length-n)throw new g("Offset must be between 0 and buffer.length - byteLength, but was "+t+" (max allowed "+(this.length-n)+")");if(1===n)return this.get(t);for(var i=0,e=0;e<n;e++)i+=this.get(t+e)*y.pow(2,8*(n-e-1));return i},t.prototype.slice=function(n,i){void 0===i&&(i=this.length);var e=wu(n,0,this.length),r=wu(i,0,this.length);if(e>r)return new t;if(e===r)return new t;for(var o=new t,u=this.findContainingBufferIndex(e),s=this.jb[u],f=e,c=f-this.Qb[u];f+s.length-c<r;)o.pushRange(s,c,s.length-c),u+=1,c=(f+=s.length-c)-this.Qb[u],s=this.jb[u];var h=r-f;return o.pushRange(s,c,h),o},t.prototype.trim=function(){if(0===this.length)return new t;for(var n=this.length-1,i=this.jb.length-1,e=this.jb[i],r=e.length-1;n>=0&&i>=0;){if(0!==e[r])break;if(0===r){if(0===i)return new t;i-=1,r=(e=this.jb[i]).length-1}else r-=1;n-=1}return this.slice(0,n+1)},t}(),_u=function(){function t(n){this.$b=n||t.BUFFER_CHUNK_SIZE,this.tA=!1,this.eA=new yu,this.qb=new E(this.$b),this.iA=0,this.sA=0,this.Kb=7}return t.prototype.closeByte=function(){this.qb[this.iA++]=this.sA,this.iA>=this.$b&&this.closeBuffer(),this.sA=0,this.Kb=7},t.prototype.closeBuffer=function(t){void 0===t&&(t=!0),0!==this.iA&&(this.eA.pushRange(this.qb,0,this.iA),t&&(this.qb=new E(this.$b)),this.iA=0)},p.defineProperty(t.prototype,"isWritingStartBit",{get:function(){return 7===this.Kb},enumerable:!1,configurable:!0}),t.prototype.close=function(){if(this.tA)throw new g("Cannot close a closed BitWriter.");return this.isWritingStartBit||this.closeByte(),this.closeBuffer(!1),this.tA=!0,this.eA},t.prototype.writeBit=function(t){if(this.tA)throw new g("Cannot write to a closed BitWriter.");this.sA|=t<<this.Kb,0===this.Kb?this.closeByte():this.Kb--},t.prototype.writeByte=function(t){if(this.tA)throw new g("Cannot write to a closed BitWriter.");this.isWritingStartBit?(this.sA=t,this.closeByte()):this.writeByteUnaligned(t)},t.prototype.writeByteUnaligned=function(t){var n=this.Kb;this.sA|=bu(t,n+1),this.closeByte(),this.sA=gu(t,8-n)<<n+1,this.Kb=n},t.prototype.writeBits=function(t){for(var n=0,i=t;n<i.length;n++){var e=i[n];this.writeBit(e)}},t.prototype.writeBytes=function(t){if(this.tA)throw new g("Cannot write to a closed BitWriter.");this.isWritingStartBit?this.writeBytesAligned(t):this.writeBytesUnaligned(t)},t.prototype.writeBytesAligned=function(t){this.iA+t.length<=this.$b?(this.qb.set(t,this.iA),this.iA+=t.length,this.iA===this.$b&&this.closeBuffer()):(this.closeBuffer(),this.eA.pushRange(t))},t.prototype.writeBytesUnaligned=function(t){if(0!==t.length){var n=this.Kb;this.sA|=bu(t[0],n+1),this.closeByte();for(var i=1;i<t.length;i++){var e=gu(t[i-1],8-n),r=bu(t[i],n+1);this.sA=e<<n+1|r,this.closeByte()}this.sA=gu(t[t.length-1],8-n)<<n+1,this.Kb=n}},t.prototype.writeUInt=function(t,n){if(t<0)throw new g("Received a negative number.");if(n>32)throw new g("The max bitlength that can be provided is 32.");if(t>=y.pow(2,n))throw new g("Uint "+t+" cannot be represented in "+n+" bit(s).");if(this.isWritingStartBit&&n%8==0)for(var i=n-8;i>=0;i-=8)this.writeByte(t>>i&255);else for(i=n-1;i>=0;i--)this.writeBool((t&1<<i)>0)},t.prototype.writeInt=function(t,n){if(n>32)throw new g("The max bitlength that can be provided is 32.");if(y.abs(t)>=y.pow(2,n-1))throw new g("Signed integer "+t+" cannot be represented in "+n+" bit(s).");t<0?this.writeUInt(t+y.pow(2,n),n):this.writeUInt(t,n)},t.prototype.writeExponentialGolombCode=function(t){if(t<0)throw new g("Received a negative number.");for(var n=y.floor(y.log2(t+1))+1,i=0;i<n-1;i++)this.writeBit(0);this.writeUInt(t+1,n)},t.prototype.writeSignedExponentialGolombCode=function(t){0===t?this.writeExponentialGolombCode(0):t<0?this.writeExponentialGolombCode(-2*t):this.writeExponentialGolombCode(2*t-1)},t.prototype.padByte=function(t){for(;!this.isWritingStartBit;)this.writeBit(t)},t.prototype.writeBool=function(t){this.writeBit(t?1:0)},t.prototype.writeString=function(t){for(var n=function(t){for(var n=new E(t.length),i=0;i<t.length;i++)n[i]=t.charCodeAt(i);return n}(t),i=0;i<n.length;i++)this.writeByte(n[i])},t.BUFFER_CHUNK_SIZE=1024,t}();x(),gt();var Su=function(){function t(t){this.rb=new yu,this.Jd=t}return t.prototype.closeWriter=function(){void 0!==this.Jd&&(this.rb=this.rb.concat(this.Jd.close()),this.Jd=void 0)},p.defineProperty(t.prototype,"writer",{get:function(){return void 0===this.Jd&&(this.Jd=new _u),this.Jd},enumerable:!1,configurable:!0}),t.prototype.concat=function(t){this.closeWriter(),this.rb=this.rb.concat(t)},t.prototype.toRangedBuffer=function(){return this.closeWriter(),this.rb},t}(),Tu=function(){function t(t){if(this.boxType=t,4!==t.length&&16!==t.length)throw new g("The provided box type does not conform to either a 4 character type or a 16 byte uuid.")}return t.prototype.serializeCommonBoxHeader=function(n){var i=this.getSize(),e=i>=t.LARGE_SIZE/8,r=16===this.boxType.length;n.writeUInt(e?1:i,32),n.writeString(r?"uuid":this.boxType),e&&(n.writeUInt(y.floor(i/t.LARGE_SIZE),32),n.writeUInt(i%t.LARGE_SIZE,32)),r&&n.writeString(this.boxType)},t.prototype.getSize=function(){var n=8+(this.boxType.length>4?16:0),i=this.getBoxContentSize()+n;return i>=t.LARGE_SIZE/8&&(i+=8),i},t.prototype.serialize=function(){var t=new Su;return this.serializeCommonBoxHeader(t.writer),this.serializeBoxContent(t),t.toRangedBuffer()},t.LARGE_SIZE=y.pow(2,32),t}();function Eu(t,n){return t instanceof Yn?64===n:t<y.pow(2,n)}function Iu(t,n){return y.round(t*y.pow(2,n))}function ku(t,n){for(var i=0;i<n.length;i++)t.writeByte(n[i])}function Ru(t,n){return t/y.pow(2,n)}x(),gt();var Ou=function(t){function n(n,i,e){var r=t.call(this,n)||this;if(r.version=i,!Eu(i,8))throw new g("the provided version cannot fit in 8 bits.");return r.flags=e,r}return du(n,t),p.defineProperty(n.prototype,"flags",{get:function(){return this.v_},set:function(t){this.v_=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return 4},n.prototype.serializeFlags=function(t){if("number"!=typeof this.flags)throw new g("Missing custom serializeFlags method.");t.writer.writeUInt(this.flags,24)},n.prototype.serializeBoxContent=function(t){t.writer.writeByte(this.version),this.serializeFlags(t)},n}(Tu);x(),gt(),x(),gt();var Nu=function(t){function n(n,i){var e=t.call(this,n)||this;return e.data=i,e}return du(n,t),n.prototype.getBoxContentSize=function(){return this.data.length},n.prototype.serializeBoxContent=function(t){t.concat(yu.from(this.data))},n}(Tu);x(),gt(),x(),gt();var Pu=function(){function t(t){void 0===t&&(t=0),this.offset=t}return t.prototype.shift=function(t){this.offset+=t},t.prototype.seek=function(t){this.offset=t},t.prototype.clone=function(){return new t(this.offset)},t}();x(),gt();var Au=16384;function Du(t){var n=t.length;if(n<=Au)return String.fromCharCode.apply(String,t);for(var i=[],e=0;e<n;e+=Au)i.push(String.fromCharCode.apply(String,t.slice(e,e+Au)));return i.join("")}var Cu=function(){function t(t){this.raw=t}return t.prototype.isSet=function(t){return function(t,n){return(t&n)===n}(this.raw,t)},t}();function xu(t,n){var i=t.getUint8(n.offset);return n.shift(1),i}function Bu(t,n,i){var e=Vu(qu(t),n.offset,n.offset+i);return n.shift(e.byteLength),e}function Mu(t,n,i){return n.offset+i<=t.byteLength}function Lu(t,n,i){void 0===i&&(i=!1);var e=t.getUint32(n.offset,i);return n.shift(4),e}function Uu(t,n,i){void 0===i&&(i=!1);var e=Lu(t,n,i),r=Lu(t,n,i),o=i?r:e,u=i?e:r;return Yn.fromBits(u,o,!0)}function Fu(t,n,i){return Du(function(t){return[].slice.call(t)}(Bu(t,n,i)))}function zu(t,n){var i,e=xu(t,n);return 0==(128&e)?i=e:192==(224&e)?i=64*(31&e)+(63&xu(t,n)):224==(240&e)?i=4096*(15&e)+64*(63&xu(t,n))+(63&xu(t,n)):240==(248&e)&&(i=262144*(7&e)+4096*(63&xu(t,n))+64*(63&xu(t,n))+(63&xu(t,n))),i}function Wu(t,n){return function(t,n,i){var e=[],r=function(t,n){return n.offset+3<=t.byteLength&&239===t.getUint8(n.offset)&&187===t.getUint8(n.offset+1)&&191===t.getUint8(n.offset+2)}(t,n);r&&n.shift(3);for(;n.offset<t.byteLength;){var o=zu(t,n);if(void 0===o)break;if(i&&0===o)break;e.push(o)}return function(t){for(var n=[],i=0,e=t;i<e.length;i++){var r=e[i];r>65535&&(r-=65536,n.push(r>>>10&1023|55296),r=56320|1023&r),n.push(r)}return Du(n)}(e)}(t,n,!0)}function Vu(t,n,i){return void 0===n&&(n=0),void 0===i&&(i=t.byteLength),new E(t.buffer,t.byteOffset+n,i-n)}function Hu(t,n,i){return void 0===n&&(n=0),void 0===i&&(i=t.byteLength),new DataView(t.buffer,t.byteOffset+n,i-n)}function qu(t){return new E(t.buffer,t.byteOffset,t.byteLength)}var Xu=function(){function t(t){void 0===t&&(t=0),this.offset=t}return t.prototype.shift=function(t){this.offset+=t},t.prototype.seek=function(t){this.offset=t},t.prototype.clone=function(){return new t(this.offset)},t.prototype.toBit=function(){return new Pu(this.offset<<3)},t}();x(),gt();var ju=function(){function t(t,n){this.data=t,this.cursor=n}return t.prototype.nextUint8=function(){return xu(this.data,this.cursor)},t.prototype.nextUint16=function(){return function(t,n,i){void 0===i&&(i=!1);var e=t.getUint16(n.offset,i);return n.shift(2),e}(this.data,this.cursor)},t.prototype.nextInt16=function(){return function(t,n,i){void 0===i&&(i=!1);var e=t.getInt16(n.offset,i);return n.shift(2),e}(this.data,this.cursor)},t.prototype.nextUint32=function(){return Lu(this.data,this.cursor)},t.prototype.nextInt32=function(){return function(t,n,i){void 0===i&&(i=!1);var e=t.getInt32(n.offset,i);return n.shift(4),e}(this.data,this.cursor)},t.prototype.nextInt64=function(){return function(t,n,i){void 0===i&&(i=!1);var e=Lu(t,n,i),r=Lu(t,n,i),o=i?r:e,u=i?e:r;return Yn.fromBits(u,o,!1)}(this.data,this.cursor)},t.prototype.nextUint64=function(){return Uu(this.data,this.cursor)},t.prototype.nextUint8Array=function(t){return Bu(this.data,this.cursor,t)},t.prototype.nextUint32Array=function(t){return function(t,n,i){for(var e=[],r=0;r<i;r++)e.push(Lu(t,n));return e}(this.data,this.cursor,t)},t.prototype.nextChars=function(t){return Fu(this.data,this.cursor,t)},t.prototype.nextUTF8String=function(){return Wu(this.data,this.cursor)},t.prototype.skip=function(t){this.cursor.shift(t)},t.prototype.clone=function(){return new t(this.data,this.cursor.clone())},t}();function Yu(t,n){return t.type===n}var Ku=8;function Gu(t){var n=function(t,n){var i=[];for(;n.offset<t.byteLength;){var e=$u(t,n);if(!e.complete)return{complete:!1,boxes:i};i.push(e.box)}return{complete:!0,boxes:i}}(t.data,t.cursor);if(!n.complete)throw new g("Data incomplete");return n.boxes}function $u(t,n){var i=n.offset,e=function(t,n){var i=n.offset;if(!Mu(t,n,Ku)){return{complete:!1,neededOffset:o=n.offset+Ku}}var e=Lu(t,n),r=Fu(t,n,4);if(1===e){if(!Mu(t,n,8)){var o=n.offset+8;return n.seek(i),{complete:!1,neededOffset:o}}e=Uu(t,n).toNumber()}if("uuid"===r){if(!Mu(t,n,16)){o=n.offset+16;return n.seek(i),{complete:!1,neededOffset:o}}r=Fu(t,n,16)}var u=n.offset,s={type:r,size:e,headerSize:u-i};return{complete:!0,header:s}}(t,n);if(!e.complete)return e;var r=e.header,o=r.size;0===o&&(o=t.byteLength-i);var u=i+o;if(u>t.byteLength){var s=u;return n.seek(i),{complete:!1,neededOffset:s}}var f={type:r.type,offset:i,data:new ju(Hu(t,i,u),new Xu(r.headerSize))};return n.seek(u),{complete:!0,box:f}}function Zu(t){return{version:t>>24,flags:new Cu(16777215&t)}}function Ju(t,n){var i,e,r,o;return 1===n?(i=t.nextUint64(),e=t.nextUint64(),r=t.nextUint32(),o=t.nextUint64()):(i=t.nextUint32(),e=t.nextUint32(),r=t.nextUint32(),o=t.nextUint32()),{creation:i,modification:e,scale:r,duration:o}}function Qu(t){return t.skipBits(4),{isLeading:t.readUInt(2),sampleDependsOn:t.readUInt(2),sampleIsDependedOn:t.readUInt(2),sampleHasRedundancy:t.readUInt(2),samplePaddingValue:t.readUInt(3),sampleIsNonSyncSample:Boolean(t.readBit()),sampleDegradationPriority:t.readUInt(16)}}function ts(t){var n=t.nextUint32Array(9);return{a:Ru(n[0],16),b:Ru(n[1],16),u:Ru(n[2],30),c:Ru(n[3],16),d:Ru(n[4],16),v:Ru(n[5],30),x:Ru(n[6],16),y:Ru(n[7],16),w:Ru(n[8],30)}}function ns(t){return new Nu(t.type,Vu(qu(t.data.data),t.data.cursor.offset))}var is=function(t){function n(n,i,e,r){void 0===e&&(e=0),void 0===r&&(r=0);var o=t.call(this,"hdlr",e,r)||this;return o.name=i,o.handlerType=n,o}return du(n,t),p.defineProperty(n.prototype,"handlerType",{get:function(){return this.nA},set:function(t){this.nA=t},enumerable:!1,configurable:!0}),n.prototype.serializeReserved=function(t){t.writer.writeUInt(0,32),t.writer.writeUInt(0,32),t.writer.writeUInt(0,32)},n.prototype.getBoxContentSize=function(){var n,i;return t.prototype.getBoxContentSize.call(this)+4+4+12+(null!==(i=null===(n=this.name)||void 0===n?void 0:n.length)&&void 0!==i?i:0)+1},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(0,32),n.writer.writeString(this.handlerType),this.serializeReserved(n),this.name&&n.writer.writeString(this.name),n.writer.writeByte(0)},n}(Ou);function es(t){var n=t.data,i=Zu(n.nextUint32()),e=i.version,r=i.flags;n.skip(4);var o=n.nextChars(4);n.skip(12);var u=n.nextUTF8String();return new is(o,u,e,r.raw)}!function(t){function n(){return t.call(this,"mdir")||this}du(n,t),n.prototype.serializeReserved=function(t){t.writer.writeString("appl"),t.writer.writeUInt(0,32),t.writer.writeUInt(0,32)}}(is);x(),gt(),x(),gt(),x(),gt();var rs=function(){function t(t,n){void 0===n&&(n=!1),this.fixed28BitMode=n,this.tag=t}return t.prototype.encodeSize=function(t){for(var n=[];t>0;)n.length>0&&(n[n.length-1]+=128),n.push(t%128),t>>=7;if(this.fixed28BitMode)for(;n.length<4;)n.push(128);return n.reverse()},p.defineProperty(t.prototype,"tag",{get:function(){return this.rA},set:function(t){if(!Eu(t,8))throw new g("Provided tag does not fit in 8 bits.");this.rA=t},enumerable:!1,configurable:!0}),t.prototype.getSize=function(){return this.getDescriptorSize()+1+this.encodeSize(this.getDescriptorSize()).length},t.prototype.serialize=function(t){t.writer.writeByte(this.tag);for(var n=0,i=this.encodeSize(this.getDescriptorSize());n<i.length;n++){var e=i[n];t.writer.writeByte(e)}this.serializeDescriptorContent(t)},t}();x(),gt();!function(t){function n(n,i,e,r,o,u,s){void 0===s&&(s={});var f=t.call(this,4,s.fixed28BitMode)||this;return f.upStream=e,f.decoderSpecificInfo=u,f.objectTypeIndication=n,f.streamType=i,f.bufferSizeDb=r,f.maxBitrate=o.max,f.avgBitrate=o.avg,f}du(n,t),p.defineProperty(n.prototype,"objectTypeIndication",{get:function(){return this.oA},set:function(t){if(!Eu(t,8))throw new g("Provided objectTypeIndication does not fit in 8 bits.");this.oA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"streamType",{get:function(){return this.hA},set:function(t){if(!Eu(t,6))throw new g("Provided streamType does not fit in 6 bits.");this.hA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"bufferSizeDb",{get:function(){return this.aA},set:function(t){if(!Eu(t,24))throw new g("Provided bufferSizeDb does not fit in 24 bits.");this.aA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"maxBitrate",{get:function(){return this.uA},set:function(t){if(!Eu(t,32))throw new g("Provided maxBitrate does not fit in 32 bits.");this.uA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"avgBitrate",{get:function(){return this.cA},set:function(t){if(!Eu(t,32))throw new g("Provided avgBitrate does not fit in 32 bits.");this.cA=t},enumerable:!1,configurable:!0}),n.prototype.getDescriptorSize=function(){return 13+this.decoderSpecificInfo.reduce((function(t,n){return t+n.getSize()}),0)},n.prototype.serializeDescriptorContent=function(t){t.writer.writeByte(this.objectTypeIndication),t.writer.writeUInt(this.streamType,6),t.writer.writeBool(this.upStream),t.writer.writeBit(1),t.writer.writeUInt(this.bufferSizeDb,24),t.writer.writeUInt(this.maxBitrate,32),t.writer.writeUInt(this.avgBitrate,32);for(var n=0,i=this.decoderSpecificInfo;n<i.length;n++){i[n].serialize(t)}}}(rs);x(),gt();!function(t){function n(n,i){void 0===i&&(i={});var e=t.call(this,5,i.fixed28BitMode)||this;return e.data=n,e}du(n,t),n.prototype.getDescriptorSize=function(){return this.data.length},n.prototype.serializeDescriptorContent=function(t){t.concat(yu.from(this.data))}}(rs);x(),gt(),x(),gt();var os=function(t){function n(n){void 0===n&&(n=!1);var i=t.call(this,6,n)||this;return i.predefined=2,i}return du(n,t),n.prototype.getDescriptorSize=function(){return 1},n.prototype.serializeDescriptorContent=function(t){t.writer.writeByte(this.predefined)},n}(rs);!function(t){function n(n,i,e,r){void 0===r&&(r={});var o=t.call(this,3,r.fixed28BitMode)||this;return o.decoderConfigDescriptor=e,o.esId=n,o.streamPriority=i,o.dependsOnEsId=null==r?void 0:r.dependsOnEsId,o.urlString=null==r?void 0:r.url,o.ocrEsId=null==r?void 0:r.ocrEsId,o.slConfigDescriptor=new os(r.fixed28BitMode),o}du(n,t),p.defineProperty(n.prototype,"streamDependenceFlag",{get:function(){return void 0!==this.dependsOnEsId},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"urlFlag",{get:function(){return void 0!==this.urlString},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"ocrStreamFlag",{get:function(){return void 0!==this.ocrEsId},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"esId",{get:function(){return this.lA},set:function(t){if(!Eu(t,16))throw new g("Provided esId does not fit in 16 bits.");this.lA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"streamPriority",{get:function(){return this.dA},set:function(t){if(!Eu(t,5))throw new g("Provided streamPriority does not fit in 5 bits.");this.dA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"dependsOnEsId",{get:function(){return this.fA},set:function(t){if(t&&!Eu(t,16))throw new g("Provided dependsOnEsId does not fit in 16 bits.");this.fA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"ocrEsId",{get:function(){return this._A},set:function(t){if(t&&!Eu(t,16))throw new g("Provided ocrEsId does not fit in 16 bits.");this._A=t},enumerable:!1,configurable:!0}),n.prototype.getDescriptorSize=function(){return 3+(this.streamDependenceFlag?2:0)+(this.urlFlag?1+this.urlString.length:0)+(this.ocrStreamFlag?2:0)+this.decoderConfigDescriptor.getSize()+this.slConfigDescriptor.getSize()},n.prototype.serializeDescriptorContent=function(t){t.writer.writeUInt(this.esId,16),t.writer.writeBool(this.streamDependenceFlag),t.writer.writeBool(this.urlFlag),t.writer.writeBool(this.ocrStreamFlag),t.writer.writeUInt(this.streamPriority,5),this.streamDependenceFlag&&t.writer.writeUInt(this.dependsOnEsId,16),this.urlFlag&&(t.writer.writeByte(this.urlString.length),t.writer.writeString(this.urlString)),this.ocrStreamFlag&&t.writer.writeUInt(this.ocrEsId,16),this.decoderConfigDescriptor.serialize(t),this.slConfigDescriptor.serialize(t)}}(rs);x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt();var us=function(t){function n(){var n=null!==t&&t.apply(this,arguments)||this;return n.boxes=[],n}return du(n,t),n.prototype.getSize=function(){return t.prototype.getSize.call(this)+this.boxes.reduce((function(t,n){return t+n.getSize()}),0)},n.prototype.serialize=function(){for(var n=t.prototype.serialize.call(this),i=0,e=this.boxes;i<e.length;i++){var r=e[i];n=n.concat(r.serialize())}return n},n}(Tu),ss=function(t){function n(){return null!==t&&t.apply(this,arguments)||this}return du(n,t),n.prototype.serializeBoxContent=function(t){},n.prototype.getBoxContentSize=function(){return 0},n}(us),fs=function(t){function n(n,i){var e=t.call(this,n)||this;return e.dataReferenceIndex=i,e}return du(n,t),p.defineProperty(n.prototype,"dataReferenceIndex",{get:function(){return this.vA},set:function(t){if(!Eu(t,16))throw new g("Provided dataReferenceIndex does not fit in 16 bits.");this.vA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return 8},n.prototype.serializeBoxContent=function(t){for(var n=0;n<6;n++)t.writer.writeByte(0);t.writer.writeUInt(this.dataReferenceIndex,16)},n}(ss),cs=function(t){function n(n,i,e,r){var o,u,s=this;return(s=t.call(this,n,i)||this).extra=r,s.channelCount=null!==(o=e.channelCount)&&void 0!==o?o:2,s.sampleSize=null!==(u=e.sampleSize)&&void 0!==u?u:16,s.sampleRate=e.sampleRate,s}return du(n,t),p.defineProperty(n.prototype,"channelCount",{get:function(){return this.gA},set:function(t){if(!Eu(t,16))throw new g("Provided channelCount does not fit in 16 bits.");this.gA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"sampleSize",{get:function(){return this.mA},set:function(t){if(!Eu(t,16))throw new g("Provided sampleSize does not fit in 16 bits.");this.mA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"sampleRate",{get:function(){return this.pA},set:function(t){if(!Eu(Iu(t,16),32))throw new g("Provided rate does not fit in 32 bits (fixed 16.16).");this.pA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){var n,i;return t.prototype.getBoxContentSize.call(this)+8+2+2+2+2+(void 0!==this.sampleRate?4:0)+(null!==(i=null===(n=this.extra)||void 0===n?void 0:n.length)&&void 0!==i?i:0)},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(0,32),n.writer.writeUInt(0,32),n.writer.writeUInt(this.channelCount,16),n.writer.writeUInt(this.sampleSize,16),n.writer.writeUInt(0,16),n.writer.writeUInt(0,16),n.writer.writeUInt(Iu(this.sampleRate,16),32),this.extra&&ku(n.writer,this.extra)},n}(fs);x(),gt();!function(t){function n(n){var i=t.call(this,"stco",0,0)||this;return i.entries=n,i}du(n,t),p.defineProperty(n.prototype,"entries",{get:function(){return this.wA},set:function(t){if(!Eu(t.length,32))throw new g("Number of allowed entries cannot fit in 32 bits.");if(t.some((function(t){return!Eu(t,32)})))throw new g("Not all entries can be represented in 32 bits.");this.wA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+4*this.entries.length},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.entries.length,32);for(var i=0,e=this.entries;i<e.length;i++){var r=e[i];n.writer.writeUInt(r,32)}}}(Ou);x(),gt();!function(t){function n(n){var i=t.call(this,"clap")||this;return i.cleanApertureWidthN=n.cleanApertureWidthN,i.cleanApertureWidthD=n.cleanApertureWidthD,i.cleanApertureHeightN=n.cleanApertureHeightN,i.cleanApertureHeightD=n.cleanApertureHeightD,i.horizOffN=n.horizOffN,i.horizOffD=n.horizOffD,i.vertOffN=n.vertOffN,i.vertOffD=n.vertOffD,i}du(n,t),p.defineProperty(n.prototype,"cleanApertureWidthN",{get:function(){return this.yA},set:function(t){if(!Eu(t,32))throw new g("Provided cleanApertureWidthN does not fit in 32 bits.");this.yA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"cleanApertureWidthD",{get:function(){return this.bA},set:function(t){if(!Eu(t,32))throw new g("Provided cleanApertureWidthD does not fit in 32 bits.");this.bA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"cleanApertureHeightN",{get:function(){return this.AA},set:function(t){if(!Eu(t,32))throw new g("Provided cleanApertureHeightN does not fit in 32 bits.");this.AA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"cleanApertureHeightD",{get:function(){return this.SA},set:function(t){if(!Eu(t,32))throw new g("Provided cleanApertureHeightD does not fit in 32 bits.");this.SA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"horizOffN",{get:function(){return this.TA},set:function(t){if(!Eu(t,32))throw new g("Provided horizOffN does not fit in 32 bits.");this.TA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"horizOffD",{get:function(){return this.kA},set:function(t){if(!Eu(t,32))throw new g("Provided horizOffD does not fit in 32 bits.");this.kA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"vertOffN",{get:function(){return this.EA},set:function(t){if(!Eu(t,32))throw new g("Provided vertOffN does not fit in 32 bits.");this.EA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"vertOffD",{get:function(){return this.xA},set:function(t){if(!Eu(t,32))throw new g("Provided vertOffD does not fit in 32 bits.");this.xA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return 32},n.prototype.serializeBoxContent=function(t){t.writer.writeUInt(this.cleanApertureWidthN,32),t.writer.writeUInt(this.cleanApertureWidthD,32),t.writer.writeUInt(this.cleanApertureHeightN,32),t.writer.writeUInt(this.cleanApertureHeightD,32),t.writer.writeUInt(this.horizOffN,32),t.writer.writeUInt(this.horizOffD,32),t.writer.writeUInt(this.vertOffN,32),t.writer.writeUInt(this.vertOffD,32)}}(Tu);x(),gt();!function(t){function n(n,i){var e=t.call(this,"ctts",n,0)||this;return e.entries=i,e}du(n,t),p.defineProperty(n.prototype,"entries",{get:function(){return this.wA},set:function(t){if(!Eu(t.length,32))throw new g("Number of allowed entries cannot fit in 32 bits.");if(t.some((function(t){return!Eu(t.sampleCount,32)||!Eu(t.sampleOffset,32)})))throw new g("Not all entries can be represented in 64 bits.");this.wA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+8*this.entries.length},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.entries.length,32);for(var i=0,e=this.entries;i<e.length;i++){var r=e[i];n.writer.writeUInt(r.sampleCount,32),0===this.version?n.writer.writeUInt(r.sampleOffset,32):1===this.version&&n.writer.writeInt(r.sampleOffset,32)}}}(Ou);x(),gt();!function(t){function n(n){var i=t.call(this,"url ",0,void 0===n?1:0)||this;return i.location=n,i}du(n,t),p.defineProperty(n.prototype,"location",{get:function(){return this.IA},set:function(t){this.flags=void 0===t?1:0,this.IA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){var n=t.prototype.getBoxContentSize.call(this);return this.location?n+this.location.length+1:n},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),this.location&&(n.writer.writeString(this.location),n.writer.writeByte(0))}}(Ou);x(),gt();!function(t){function n(n,i,e){var r=t.call(this,"urn ",0,e)||this;return r.name=n,r.location=i,r}du(n,t),p.defineProperty(n.prototype,"location",{get:function(){return this.IA},set:function(t){if(1&this.flags)throw new g("The moov containment flag is set, a DataEntryUrlBox should be used instead.");this.IA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){var n=t.prototype.getBoxContentSize.call(this)+this.name.length+1;return this.location?n+this.location.length+1:n},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeString(this.name),n.writer.writeByte(0),this.location&&(n.writer.writeString(this.location),n.writer.writeByte(0))}}(Ou);x(),gt();!function(t){function n(){return t.call(this,"dinf")||this}du(n,t)}(ss);x(),gt(),x(),gt();var hs=function(t){function n(n,i,e){var r=t.call(this,n)||this;if(r.version=i,!Eu(i,8))throw new g("the provided version cannot fit in 8 bits.");return r.flags=e,r}return du(n,t),p.defineProperty(n.prototype,"flags",{get:function(){return this.v_},set:function(t){this.v_=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return 4},n.prototype.serializeFlags=function(t){if("number"!=typeof this.flags)throw new g("Missing custom serializeFlags method.");t.writer.writeUInt(this.flags,24)},n.prototype.serializeBoxContent=function(t){t.writer.writeByte(this.version),this.serializeFlags(t)},n}(us);!function(t){function n(){return t.call(this,"dref",0,0)||this}du(n,t),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.boxes.length,32)}}(hs);x(),gt(),x(),gt();var as=function(t){function n(n,i,e){void 0===e&&(e=0);var r=t.call(this,"elst",i,e)||this;return r.entries=n,r}return du(n,t),p.defineProperty(n.prototype,"bitSize",{get:function(){return 0===this.version?32:64},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"entries",{get:function(){return this.wA},set:function(t){for(var n=0,i=t;n<i.length;n++){var e=i[n];if(!Eu(e.segmentDuration,this.bitSize))throw new g("SegmentDuration of one of the entries does not fit in ".concat(this.bitSize," bits."));if(!Eu(e.mediaTime,this.bitSize))throw new g("MediaTime of one of the entries does not fit in ".concat(this.bitSize," bits."));if(!Eu(e.mediaRateInteger,16))throw new g("Provided mediaRateInteger does not fit in 16 bits.");if(e.mediaRateFraction&&!Eu(e.mediaRateFraction,16))throw new g("Provided mediaRateFraction does not fit in 16 bits.")}this.wA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+this.entries.length*(2*this.bitSize/8+2+2)},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.entries.length,32),this.serializeElstBoxContent(n)},n}(Ou),vs=function(t){function n(n,i){return void 0===i&&(i=0),t.call(this,n,0,i)||this}return du(n,t),n.prototype.serializeElstBoxContent=function(t){for(var n,i=0,e=this.entries;i<e.length;i++){var r=e[i];t.writer.writeUInt(r.segmentDuration,32),t.writer.writeInt(r.mediaTime,32),t.writer.writeUInt(r.mediaRateInteger,16),t.writer.writeUInt(null!==(n=r.mediaRateFraction)&&void 0!==n?n:0,16)}},n}(as),ds=function(t){function n(n,i){return void 0===i&&(i=0),t.call(this,n,1,i)||this}return du(n,t),n.prototype.serializeElstBoxContent=function(t){for(var n,i=0,e=this.entries;i<e.length;i++){var r=e[i];t.writer.writeUInt(r.segmentDuration.getHighBitsUnsigned(),32),t.writer.writeUInt(r.segmentDuration.getLowBitsUnsigned(),32),t.writer.writeInt(r.mediaTime.getHighBits(),32),t.writer.writeInt(r.mediaTime.getLowBits(),32),t.writer.writeUInt(r.mediaRateInteger,16),t.writer.writeUInt(null!==(n=r.mediaRateFraction)&&void 0!==n?n:0,16)}},n}(as);function ls(t){for(var n=t.data,i=Zu(n.nextUint32()),e=i.version,r=i.flags,o=n.nextUint32(),u=[],s=0;s<o;s++){var f=void 0,c=void 0;0===e?(f=n.nextUint32(),c=n.nextInt32()):(f=n.nextUint64(),c=n.nextInt64());var h=n.nextInt16(),a=n.nextInt16();u.push({segmentDuration:f,mediaTime:c,mediaRateFraction:a,mediaRateInteger:h})}return 0===e?new vs(u,r.raw):new ds(u,r.raw)}var ws=function(t){function n(){return t.call(this,"edts")||this}return du(n,t),n}(ss);function bs(t){for(var n=new ws,i=0,e=Gu(t.data);i<e.length;i++){var r=e[i];Yu(r,"elst")?n.boxes.push(ls(r)):n.boxes.push(ns(r))}return n}x(),gt(),x(),gt();var gs=function(t){function n(n,i,e,r){var o=t.call(this,n)||this;return o.majorBrand=i,o.minorVersion=e,o.compatibleBrands=r,o}return du(n,t),p.defineProperty(n.prototype,"majorBrand",{get:function(){return this.RA},set:function(t){if(4!==t.length)throw new g("the provided major brand does not conform to the 4 character requirement");this.RA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"minorVersion",{get:function(){return this.CA},set:function(t){if(!Eu(t,32))throw new g("the provided minor version does not fit in 32 bits.");this.CA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"compatibleBrands",{get:function(){return this.PA},set:function(t){if(t.some((function(t){return 4!==t.length})))throw new g("Some of the compatible brands do not conform to the 4 character requirement");this.PA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return 4*(2+this.compatibleBrands.length)},n.prototype.serializeBoxContent=function(t){t.writer.writeString(this.majorBrand),t.writer.writeUInt(this.minorVersion,32);for(var n=0,i=this.compatibleBrands;n<i.length;n++){var e=i[n];t.writer.writeString(e)}},n}(Tu);!function(t){function n(n,i,e){return t.call(this,"ftyp",n,i,e)||this}du(n,t)}(gs);x(),gt();!function(t){function n(n,i){void 0===i&&(i="free");var e=t.call(this,i)||this;return e.data=n,e}du(n,t),n.prototype.getBoxContentSize=function(){var t,n;return null!==(n=null===(t=this.data)||void 0===t?void 0:t.length)&&void 0!==n?n:0},n.prototype.serializeBoxContent=function(t){this.data&&t.concat(yu.from(this.data))}}(Tu);x(),gt(),x(),gt();var ms=function(t){function n(n,i,e,r){void 0===r&&(r=0);var o=t.call(this,"mdhd",e,r)||this;return o.creationTime=n.creation,o.modificationTime=n.modification,o.timescale=n.scale,o.duration=n.duration,o.language=i,o}return du(n,t),p.defineProperty(n.prototype,"creationTime",{get:function(){return this.DA},set:function(t){if(!Eu(t,this.bitSize))throw new g("Provided sequence number does not fit in ".concat(this.bitSize," bits."));this.DA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"modificationTime",{get:function(){return this.NA},set:function(t){if(!Eu(t,this.bitSize))throw new g("Provided sequence number does not fit in ".concat(this.bitSize," bits."));this.NA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"timescale",{get:function(){return this.MA},set:function(t){if(!Eu(t,32))throw new g("Provided sequence number does not fit in 32 bits.");this.MA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"duration",{get:function(){return this.LA},set:function(t){if(!Eu(t,this.bitSize))throw new g("Provided sequence number does not fit in ".concat(this.bitSize," bits."));this.LA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"language",{get:function(){return this.BA},set:function(t){if(!Ss(t))throw new g("Expected an ISO-639-2/T language code");this.BA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"bitSize",{get:function(){return 0===this.version?32:64},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+this.bitSize/8*3+4+2+2},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),this.serializeMdiaContent(n),n.writer.writeBit(0);for(var i=0,e=this.language;i<e.length;i++){var r=e[i];n.writer.writeUInt(r.charCodeAt(0)-96,5)}n.writer.writeUInt(0,16)},n}(Ou),ps=function(t){function n(n,i,e){return void 0===e&&(e=0),t.call(this,n,i,0,e)||this}return du(n,t),n.prototype.serializeMdiaContent=function(t){t.writer.writeUInt(this.creationTime,32),t.writer.writeUInt(this.modificationTime,32),t.writer.writeUInt(this.timescale,32),t.writer.writeUInt(this.duration,32)},n}(ms),ys=function(t){function n(n,i,e){return void 0===e&&(e=0),t.call(this,n,i,1,e)||this}return du(n,t),n.prototype.serializeMdiaContent=function(t){t.writer.writeUInt(this.creationTime.getHighBitsUnsigned(),32),t.writer.writeUInt(this.creationTime.getLowBitsUnsigned(),32),t.writer.writeUInt(this.modificationTime.getHighBitsUnsigned(),32),t.writer.writeUInt(this.modificationTime.getLowBitsUnsigned(),32),t.writer.writeUInt(this.timescale,32),t.writer.writeUInt(this.duration.getHighBitsUnsigned(),32),t.writer.writeUInt(this.duration.getLowBitsUnsigned(),32)},n}(ms);function _s(t){var n=t.data,i=Zu(n.nextUint32()),e=i.version,r=i.flags,o=Ju(n,e),u=new mu(yu.from(n.nextUint8Array(2)));u.skipBits(1);for(var s=[],f=0;f<3;f++)s.push(u.readUInt(5));var c=s.map((function(t){return String.fromCharCode(t+96)})).join("");return Ss(c)||(c="und"),n.skip(2),0===e?new ps(o,c,r.raw):new ys(o,c,r.raw)}function Ss(t){return/^[a-z]{3}$/.test(t)}var Ts=function(t){function n(){return t.call(this,"mdia")||this}return du(n,t),n}(ss);function Es(t){for(var n=new Ts,i=0,e=Gu(t.data);i<e.length;i++){var r=e[i];Yu(r,"mdhd")?n.boxes.push(_s(r)):Yu(r,"hdlr")?n.boxes.push(es(r)):n.boxes.push(ns(r))}return n}x(),gt();!function(t){function n(){var n=t.call(this,"mdat")||this;return n.data=new yu,n}du(n,t),n.prototype.getBoxContentSize=function(){return this.data.length},n.prototype.serializeBoxContent=function(t){t.concat(this.data)}}(Tu);x(),gt();!function(t){function n(){return t.call(this,"minf")||this}du(n,t)}(ss);x(),gt();var Is;!function(t){function n(n){var i=t.call(this,"meta",0,0)||this;return i.handler=n,i}du(n,t),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+this.handler.getSize()},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.concat(this.handler.serialize())}}(hs);x(),gt(),x(),gt(),function(t){t.VIDEO="vide",t.AUXILIARY_VIDEO="auxv",t.AUDIO="soun",t.METADATA="meta",t.HINT="hint",t.TEXT="text",t.SUBTITLE="subt",t.FONT="fdsm"}(Is||(Is={})),x(),gt();var ks,Rs,Os={a:1,b:0,u:0,c:0,d:1,v:0,x:0,y:0,w:1};function Ns(t,n){n.writer.writeUInt(Iu(t.a,16),32),n.writer.writeUInt(Iu(t.b,16),32),n.writer.writeUInt(Iu(0,30),32),n.writer.writeUInt(Iu(t.c,16),32),n.writer.writeUInt(Iu(t.d,16),32),n.writer.writeUInt(Iu(0,30),32),n.writer.writeUInt(Iu(t.x,16),32),n.writer.writeUInt(Iu(t.y,16),32),n.writer.writeUInt(Iu(1,30),32)}function Ps(t,n){var i,e,r,o;n.writer.writeUInt(null!==(i=t.isLeading)&&void 0!==i?i:ks.UNKNOWN,2),n.writer.writeUInt(null!==(e=t.sampleDependsOn)&&void 0!==e?e:Rs.UNKNOWN,2),n.writer.writeUInt(null!==(r=t.sampleIsDependedOn)&&void 0!==r?r:Rs.UNKNOWN,2),n.writer.writeUInt(null!==(o=t.sampleHasRedundancy)&&void 0!==o?o:Rs.UNKNOWN,2)}function As(t,n){var i,e,r;n.writer.writeUInt(0,4),Ps(t,n),n.writer.writeUInt(null!==(i=t.samplePaddingValue)&&void 0!==i?i:0,3),n.writer.writeBool(null!==(e=t.sampleIsNonSyncSample)&&void 0!==e&&e),n.writer.writeUInt(null!==(r=t.sampleDegradationPriority)&&void 0!==r?r:0,16)}x(),gt(),function(t){t[t.UNKNOWN=0]="UNKNOWN",t[t.WITH_DEPENDENCY=1]="WITH_DEPENDENCY",t[t.NO=2]="NO",t[t.WITHOUT_DEPENDENCY=3]="WITHOUT_DEPENDENCY"}(ks||(ks={})),function(t){t[t.UNKNOWN=0]="UNKNOWN",t[t.YES=1]="YES",t[t.NO=2]="NO",t[t.RESERVED=3]="RESERVED"}(Rs||(Rs={})),x(),gt(),x(),gt();var Ds=function(){};x(),gt(),x(),gt(),x(),gt();var Cs=function(t){function n(n,i,e){var r=t.call(this,"pssh",n,0)||this;return r.systemId=i,r.data=e,r}return du(n,t),p.defineProperty(n.prototype,"systemId",{get:function(){return this.OA},set:function(t){if(16!==t.length)throw new g("Provided systemId length is not 16.");this.OA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"data",{get:function(){return this.Zp},set:function(t){if(!Eu(t.length,32))throw new g("Provided data length does not fit in 32 bits.");this.Zp=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+16+4+this.data.length},n.prototype.serializeVersionBoxContent=function(t){},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.concat(yu.from(this.systemId)),this.serializeVersionBoxContent(n),n.writer.writeUInt(this.data.length,32),n.concat(yu.from(this.data))},n}(Ou),xs=function(t){function n(n,i){return t.call(this,0,n,i)||this}return du(n,t),n}(Cs),Bs=function(t){function n(n,i,e){var r=t.call(this,1,n,i)||this;return r.kIds=e,r}return du(n,t),p.defineProperty(n.prototype,"kIds",{get:function(){return this.FA},set:function(t){if(!Eu(t.length,32))throw new g("Provided kIds length cannot fit in 32 bits.");if(t.some((function(t){return 16!==t.length})))throw new g("Not all provided key ids are 16 bytes long.");this.FA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+16*this.kIds.length},n.prototype.serializeVersionBoxContent=function(t){t.writer.writeUInt(this.kIds.length,32);for(var n=0,i=this.kIds;n<i.length;n++){var e=i[n];t.concat(yu.from(e))}},n}(Cs);function Ms(t){var n=t.data.nextUint8();t.data.skip(3);var i=t.data.nextUint8Array(16),e=[];if(1===n)for(var r=t.data.nextUint32(),o=0;o<r;o++)e.push(t.data.nextUint8Array(16));var u=t.data.nextUint32(),s=t.data.nextUint8Array(u);return 1===n?new Bs(i,s,e):new xs(i,s)}x(),gt(),x(),gt();var Ls=function(t){function n(n,i,e){void 0===e&&(e=0);var r=t.call(this,"mehd",i,e)||this;return r.fragmentDuration=n,r}return du(n,t),p.defineProperty(n.prototype,"bitSize",{get:function(){return 0===this.version?32:64},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"fragmentDuration",{get:function(){return this.VA},set:function(t){if(!Eu(t,this.bitSize))throw new g("The provided fragmentDuration does not fit in ".concat(this.bitSize," bits."));this.VA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+this.bitSize/8},n}(Ou),Us=function(t){function n(n,i){return void 0===i&&(i=0),t.call(this,n,0,i)||this}return du(n,t),n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.fragmentDuration,32)},n}(Ls),Fs=function(t){function n(n,i){return void 0===i&&(i=0),t.call(this,n,1,i)||this}return du(n,t),n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.fragmentDuration.getHighBitsUnsigned(),32),n.writer.writeUInt(this.fragmentDuration.getLowBitsUnsigned(),32)},n}(Ls);function zs(t){var n=t.data,i=Zu(n.nextUint32()),e=i.version,r=i.flags;return 0===e?new Us(n.nextUint32(),r.raw):new Fs(n.nextUint64(),r.raw)}x(),gt();var Ws=function(t){function n(n,i,e,r){void 0===i&&(i={}),void 0===e&&(e=0),void 0===r&&(r=0);var o,u,s,f=this;return(f=t.call(this,"trex",e,r)||this).trackId=n,f.defaultSampleDescriptionIndex=null!==(o=null==i?void 0:i.sampleDescriptionIndex)&&void 0!==o?o:0,f.defaultSampleDuration=null!==(u=i.sampleDuration)&&void 0!==u?u:0,f.defaultSampleSize=null!==(s=i.sampleSize)&&void 0!==s?s:0,f.defaultSampleFlags=i.sampleFlags,f}return du(n,t),p.defineProperty(n.prototype,"trackId",{get:function(){return this.WA},set:function(t){if(!Eu(t,32))throw new g("Provided track id does not fit in 32 bits.");this.WA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"defaultSampleDescriptionIndex",{get:function(){return this.UA},set:function(t){if(!Eu(t,32))throw new g("Provided default sample description index does not fit in 32 bits.");this.UA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"defaultSampleDuration",{get:function(){return this.GA},set:function(t){if(!Eu(t,32))throw new g("Provided default sample duration does not fit in 32 bits.");this.GA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"defaultSampleSize",{get:function(){return this.ZA},set:function(t){if(!Eu(t,32))throw new g("Provided default sample size does not fit in 32 bits.");this.ZA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"defaultSampleFlags",{get:function(){return this.HA},set:function(t){if((null==t?void 0:t.samplePaddingValue)&&!Eu(t.samplePaddingValue,3))throw new g("Provided sample padding value does not fit in 3 bits.");if((null==t?void 0:t.sampleDegradationPriority)&&!Eu(t.sampleDegradationPriority,16))throw new g("Provided sample degradation priority does not fit in 16 bits.");this.HA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+20},n.prototype.serializeBoxContent=function(n){var i;t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.trackId,32),n.writer.writeUInt(this.defaultSampleDescriptionIndex,32),n.writer.writeUInt(this.defaultSampleDuration,32),n.writer.writeUInt(this.defaultSampleSize,32),As(null!==(i=this.defaultSampleFlags)&&void 0!==i?i:{},n)},n}(Ou);function Vs(t){var n=t.data,i=Zu(n.nextUint32()),e=i.version,r=i.flags,o=n.nextUint32(),u=n.nextUint32(),s=n.nextUint32(),f=n.nextUint32(),c=Qu(new mu(yu.from(n.nextUint8Array(4))));return new Ws(o,{sampleDescriptionIndex:u,sampleDuration:s,sampleSize:f,sampleFlags:c},e,r.raw)}var Hs=function(t){function n(){return t.call(this,"mvex")||this}return du(n,t),n}(ss);function qs(t){for(var n=new Hs,i=0,e=Gu(t.data);i<e.length;i++){var r=e[i];Yu(r,"mehd")?n.boxes.push(zs(r)):Yu(r,"trex")?n.boxes.push(Vs(r)):n.boxes.push(ns(r))}return n}x(),gt();var Xs=function(t){function n(i,e,r,o,u){void 0===u&&(u=0);var s,f,c,h=this;return(h=t.call(this,"mvhd",o,u)||this).creationTime=i.creation,h.modificationTime=i.modification,h.timescale=i.scale,h.duration=i.duration,h.rate=null!==(s=r.rate)&&void 0!==s?s:n.DEFAULT_RATE,h.volume=null!==(f=r.volume)&&void 0!==f?f:n.DEFAULT_VOLUME,h.matrix=null!==(c=r.matrix)&&void 0!==c?c:Os,h.XA=e,h}return du(n,t),p.defineProperty(n.prototype,"bitSize",{get:function(){return 0===this.version?32:64},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"creationTime",{get:function(){return this.DA},set:function(t){if(!Eu(t,this.bitSize))throw new g("Provided sequence number does not fit in ".concat(this.bitSize," bits."));this.DA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"modificationTime",{get:function(){return this.NA},set:function(t){if(!Eu(t,this.bitSize))throw new g("Provided sequence number does not fit in ".concat(this.bitSize," bits."));this.NA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"timescale",{get:function(){return this.MA},set:function(t){if(!Eu(t,32))throw new g("Provided sequence number does not fit in 32 bits.");this.MA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"duration",{get:function(){return this.LA},set:function(t){if(!Eu(t,this.bitSize))throw new g("Provided sequence number does not fit in ".concat(this.bitSize," bits."));this.LA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"rate",{get:function(){return this.zA},set:function(t){if(!Eu(Iu(t,16),32))throw new g("Provided rate does not fit in 32 bits (fixed 16.16).");this.zA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"volume",{get:function(){return this.qA},set:function(t){if(!Eu(Iu(t,8),16))throw new g("Provided volume does not fit in 16 bits (fixed 8.8).");this.qA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"matrix",{get:function(){return this.YA},set:function(t){if(0!==t.u||0!==t.v||1!==t.w)throw new g("(u, v, w) does not match the required (0, 0, 1)");this.YA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"nextTrackId",{get:function(){return this.XA},set:function(t){if(0===t)throw new g("NextTrackId cannot be 0.");if(!Eu(t,32))throw new g("NextTrackId cannot exceed 32 bits.");this.XA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+this.bitSize/8*3+4+4+2+2+8+36+24+4},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),this.serializeMvhdContent(n),n.writer.writeUInt(Iu(this.rate,16),32),n.writer.writeUInt(Iu(this.volume,8),16),n.writer.writeUInt(0,16),n.writer.writeUInt(0,32),n.writer.writeUInt(0,32),Ns(this.matrix,n);for(var i=0;i<6;i++)n.writer.writeUInt(0,32);n.writer.writeUInt(this.nextTrackId,32)},n.DEFAULT_RATE=1,n.DEFAULT_VOLUME=1,n}(Ou),js=function(t){function n(n,i,e,r){return void 0===e&&(e={}),void 0===r&&(r=0),t.call(this,n,i,e,0,r)||this}return du(n,t),n.prototype.serializeMvhdContent=function(t){t.writer.writeUInt(this.creationTime,32),t.writer.writeUInt(this.modificationTime,32),t.writer.writeUInt(this.timescale,32),t.writer.writeUInt(this.duration,32)},n}(Xs),Ys=function(t){function n(n,i,e,r){return void 0===e&&(e={}),void 0===r&&(r=0),t.call(this,n,i,e,1,r)||this}return du(n,t),n.prototype.serializeMvhdContent=function(t){t.writer.writeUInt(this.creationTime.getHighBitsUnsigned(),32),t.writer.writeUInt(this.creationTime.getLowBitsUnsigned(),32),t.writer.writeUInt(this.modificationTime.getHighBitsUnsigned(),32),t.writer.writeUInt(this.modificationTime.getLowBitsUnsigned(),32),t.writer.writeUInt(this.timescale,32),t.writer.writeUInt(this.duration.getHighBitsUnsigned(),32),t.writer.writeUInt(this.duration.getLowBitsUnsigned(),32)},n}(Xs);function Ks(t){var n=t.data,i=Zu(n.nextUint32()),e=i.version,r=i.flags,o=Ju(n,e),u=Ru(n.nextUint32(),16),s=Ru(n.nextUint16(),8);n.skip(2),n.skip(8);var f=ts(n);n.skip(24);var c=n.nextUint32();return 0===e?new js(o,c,{rate:u,volume:s,matrix:f},r.raw):new Ys(o,c,{rate:u,volume:s,matrix:f},r.raw)}x(),gt(),x(),gt();var Gs=function(t){function n(n,i,e,r,o,u,s){void 0===s&&(s={});var f,c,h,a=this;return a=t.call(this,"tkhd",n,function(t){var n,i,e,r;return{trackEnabled:null===(n=null==t?void 0:t.trackEnabled)||void 0===n||n,trackInMovie:null===(i=null==t?void 0:t.trackInMovie)||void 0===i||i,trackInPreview:null===(e=null==t?void 0:t.trackInPreview)||void 0===e||e,trackSizeIsAspectRatio:null!==(r=null==t?void 0:t.trackSizeIsAspectRatio)&&void 0!==r&&r}}(s))||this,a.creationTime=i.creation,a.modificationTime=i.modification,a.trackId=e,a.duration=i.duration,a.volume=r,a.width=o,a.height=u,a.layer=null!==(f=s.layer)&&void 0!==f?f:0,a.alternateGroup=null!==(c=s.alternateGroup)&&void 0!==c?c:0,a.matrix=null!==(h=s.matrix)&&void 0!==h?h:Os,a}return du(n,t),p.defineProperty(n.prototype,"bitSize",{get:function(){return 0===this.version?32:64},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"creationTime",{get:function(){return this.DA},set:function(t){if(!Eu(t,this.bitSize))throw new g("Provided sequence number does not fit in ".concat(this.bitSize," bits."));this.DA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"modificationTime",{get:function(){return this.NA},set:function(t){if(!Eu(t,this.bitSize))throw new g("Provided sequence number does not fit in ".concat(this.bitSize," bits."));this.NA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"trackId",{get:function(){return this.WA},set:function(t){if(0===t)throw new g("trackId cannot be 0.");if(!Eu(t,32))throw new g("trackId cannot exceed 32 bits.");this.WA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"duration",{get:function(){return this.LA},set:function(t){if(!Eu(t,this.bitSize))throw new g("Provided sequence number does not fit in ".concat(this.bitSize," bits."));this.LA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"volume",{get:function(){return this.qA},set:function(t){if(!Eu(Iu(t,8),16))throw new g("Provided volume does not fit in 16 bits (fixed 8.8).");this.qA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"width",{get:function(){return this.KA},set:function(t){if(!Eu(Iu(t,16),32))throw new g("Provided width does not fit in 32 bits (fixed 16.16).");this.KA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"height",{get:function(){return this.jA},set:function(t){if(!Eu(Iu(t,16),32))throw new g("Provided height does not fit in 32 bits (fixed 16.16).");this.jA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"layer",{get:function(){return this.QA},set:function(t){if(!Eu(t,16))throw new g("Provided layer does not fit in 16 bits.");this.QA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"alternateGroup",{get:function(){return this.JA},set:function(t){if(!Eu(t,16))throw new g("Provided alternateGroup does not fit in 16 bits.");this.JA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"matrix",{get:function(){return this.YA},set:function(t){if(0!==t.u||0!==t.v||1!==t.w)throw new g("(u, v, w) does not match the required (0, 0, 1)");this.YA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+this.bitSize/8*3+4+4+8+2+2+2+2+36+4+4},n.prototype.serializeFlags=function(t){t.writer.writeUInt(0,20),t.writer.writeBool(this.flags.trackSizeIsAspectRatio),t.writer.writeBool(this.flags.trackInPreview),t.writer.writeBool(this.flags.trackInMovie),t.writer.writeBool(this.flags.trackEnabled)},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),this.serializeTkhdContent(n),n.writer.writeUInt(0,32),n.writer.writeUInt(0,32),n.writer.writeUInt(this.layer,16),n.writer.writeUInt(this.alternateGroup,16),n.writer.writeUInt(Iu(this.volume,8),16),n.writer.writeUInt(0,16),Ns(this.matrix,n),n.writer.writeUInt(Iu(this.width,16),32),n.writer.writeUInt(Iu(this.height,16),32)},n}(Ou),$s=function(t){function n(n,i,e,r,o,u){return t.call(this,0,n,i,e,r,o,u)||this}return du(n,t),n.prototype.serializeTkhdContent=function(t){t.writer.writeUInt(this.creationTime,32),t.writer.writeUInt(this.modificationTime,32),t.writer.writeUInt(this.trackId,32),t.writer.writeUInt(0,32),t.writer.writeUInt(this.duration,32)},n}(Gs),Zs=function(t){function n(n,i,e,r,o,u){return t.call(this,1,n,i,e,r,o,u)||this}return du(n,t),n.prototype.serializeTkhdContent=function(t){t.writer.writeUInt(this.creationTime.getHighBitsUnsigned(),32),t.writer.writeUInt(this.creationTime.getLowBitsUnsigned(),32),t.writer.writeUInt(this.modificationTime.getHighBitsUnsigned(),32),t.writer.writeUInt(this.modificationTime.getLowBitsUnsigned(),32),t.writer.writeUInt(this.trackId,32),t.writer.writeUInt(0,32),t.writer.writeUInt(this.duration.getHighBitsUnsigned(),32),t.writer.writeUInt(this.duration.getLowBitsUnsigned(),32)},n}(Gs);function Js(t){var n,i,e,r,o=t.data,u=Zu(o.nextUint32()),s=u.version,f=u.flags,c=f.isSet(8),h=f.isSet(4),a=f.isSet(2),v=f.isSet(1);0===s?(n=o.nextUint32(),i=o.nextUint32(),e=o.nextUint32(),o.skip(4),r=o.nextUint32()):(n=o.nextUint64(),i=o.nextUint64(),e=o.nextUint32(),o.skip(4),r=o.nextUint64()),o.skip(8);var d=o.nextInt16(),l=o.nextInt16(),w=Ru(o.nextInt16(),8);o.skip(2);var b=ts(o),g=Ru(o.nextUint32(),16),m=Ru(o.nextUint32(),16);return 0===s?new $s({creation:n,modification:i,duration:r},e,w,g,m,{layer:d,matrix:b,alternateGroup:l,trackSizeIsAspectRatio:c,trackEnabled:v,trackInPreview:h,trackInMovie:a}):new Zs({creation:n,modification:i,duration:r},e,w,g,m,{layer:d,matrix:b,alternateGroup:l,trackSizeIsAspectRatio:c,trackEnabled:v,trackInPreview:h,trackInMovie:a})}var Qs=function(t){function n(){return t.call(this,"trak")||this}return du(n,t),n}(ss);function tf(t){for(var n=new Qs,i=0,e=Gu(t.data);i<e.length;i++){var r=e[i];Yu(r,"tkhd")?n.boxes.push(Js(r)):Yu(r,"mdia")?n.boxes.push(Es(r)):Yu(r,"edts")?n.boxes.push(bs(r)):n.boxes.push(ns(r))}return n}var nf=function(t){function n(){return t.call(this,"moov")||this}return du(n,t),n}(ss);x(),gt(),x(),gt(),x(),gt();var ef=function(t){function n(n,i,e){void 0===e&&(e=0);var r=t.call(this,"tfdt",i,e)||this;return r.baseMediaDecodeTime=n,r}return du(n,t),p.defineProperty(n.prototype,"bitSize",{get:function(){return 0===this.version?32:64},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"baseMediaDecodeTime",{get:function(){return this.$A},set:function(t){if(!Eu(t,this.bitSize))throw new g("Provided baseMediaDecodeTime does not fit in ".concat(this.bitSize," bits."));this.$A=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+this.bitSize/8},n}(Ou),rf=function(t){function n(n,i){return void 0===i&&(i=0),t.call(this,n,0,i)||this}return du(n,t),n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.baseMediaDecodeTime,32)},n}(ef),of=function(t){function n(n,i){return void 0===i&&(i=0),t.call(this,n,1,i)||this}return du(n,t),n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.baseMediaDecodeTime.getHighBitsUnsigned(),32),n.writer.writeUInt(this.baseMediaDecodeTime.getLowBitsUnsigned(),32)},n}(ef);function uf(t){var n=t.data,i=Zu(n.nextUint32()),e=i.version,r=i.flags;return 0===e?new rf(n.nextUint32(),r.raw):new of(n.nextUint64(),r.raw)}x(),gt();var sf=function(t){function n(n,i){void 0===i&&(i=0);var e=t.call(this,"tfhd",i,function(t){return{baseDataOffsetPresent:void 0!==t.baseDataOffset,sampleDescriptionIndexPresent:void 0!==t.sampleDescriptionIndex,defaultSampleDurationPresent:void 0!==t.defaultSampleDuration,defaultSampleSizePresent:void 0!==t.defaultSampleSize,defaultSampleFlagsPresent:void 0!==t.defaultSampleFlags,durationIsEmpty:t.durationIsEmpty,defaultBaseIsMoof:t.defaultBaseIsMoof}}(n))||this;return e.trackId=n.trackId,e.baseDataOffset=n.baseDataOffset,e.sampleDescriptionIndex=n.sampleDescriptionIndex,e.defaultSampleDuration=n.defaultSampleDuration,e.defaultSampleSize=n.defaultSampleSize,e.defaultSampleFlags=n.defaultSampleFlags,e}return du(n,t),p.defineProperty(n.prototype,"trackId",{get:function(){return this.WA},set:function(t){if(!Eu(t,32))throw new g("Provided track id does not fit in 32 bits.");this.WA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"baseDataOffset",{get:function(){return this.tS},set:function(t){if(void 0===t&&this.flags.baseDataOffsetPresent)throw new g("The base data offset present flag is set.");if(void 0!==t&&!this.flags.baseDataOffsetPresent)throw new g("The base data offset present flag is not set.");if(t&&!Eu(t,64))throw new g("Provided baseDataOffset does not fit in 32 bits.");this.tS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"sampleDescriptionIndex",{get:function(){return this.eS},set:function(t){if(void 0===t&&this.flags.sampleDescriptionIndexPresent)throw new g("The sample description index flag is set.");if(void 0!==t&&!this.flags.sampleDescriptionIndexPresent)throw new g("The sample description index flag is not set.");if(t&&!Eu(t,32))throw new g("Provided sampleDescriptionIndex does not fit in 32 bits.");this.eS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"defaultSampleDuration",{get:function(){return this.GA},set:function(t){if(void 0===t&&this.flags.defaultSampleDurationPresent)throw new g("The default sample duration present flag is set.");if(void 0!==t&&!this.flags.defaultSampleDurationPresent)throw new g("The default sample duration present flag is not set.");if(t&&!Eu(t,32))throw new g("Provided defaultSampleDuration does not fit in 32 bits.");this.GA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"defaultSampleSize",{get:function(){return this.ZA},set:function(t){if(void 0===t&&this.flags.defaultSampleSizePresent)throw new g("The default sample size present flag is set.");if(void 0!==t&&!this.flags.defaultSampleSizePresent)throw new g("The default sample size present flag is not set.");if(t&&!Eu(t,32))throw new g("Provided defaultSampleSize does not fit in 32 bits.");this.ZA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"defaultSampleFlags",{get:function(){return this.HA},set:function(t){if(void 0===t&&this.flags.defaultSampleFlagsPresent)throw new g("The default sample flags present flag is set.");if(void 0!==t&&!this.flags.defaultSampleFlagsPresent)throw new g("The default sample flags present flag is not set.");if((null==t?void 0:t.samplePaddingValue)&&!Eu(t.samplePaddingValue,3))throw new g("Provided sample padding value does not fit in 3 bits.");if((null==t?void 0:t.sampleDegradationPriority)&&!Eu(t.sampleDegradationPriority,16))throw new g("Provided sample degradation priority does not fit in 16 bits.");this.HA=t},enumerable:!1,configurable:!0}),n.prototype.serializeFlags=function(t){t.writer.writeUInt(0,6),t.writer.writeBool(this.flags.defaultBaseIsMoof),t.writer.writeBool(this.flags.durationIsEmpty),t.writer.writeByte(0),t.writer.writeUInt(0,2),t.writer.writeBool(this.flags.defaultSampleFlagsPresent),t.writer.writeBool(this.flags.defaultSampleSizePresent),t.writer.writeBool(this.flags.defaultSampleDurationPresent),t.writer.writeBit(0),t.writer.writeBool(this.flags.sampleDescriptionIndexPresent),t.writer.writeBool(this.flags.baseDataOffsetPresent)},n.prototype.getBoxContentSize=function(){var n=t.prototype.getBoxContentSize.call(this)+4;return this.flags.baseDataOffsetPresent&&(n+=8),this.flags.sampleDescriptionIndexPresent&&(n+=4),this.flags.defaultSampleDurationPresent&&(n+=4),this.flags.defaultSampleSizePresent&&(n+=4),this.flags.defaultSampleFlagsPresent&&(n+=4),n},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.trackId,32),this.flags.baseDataOffsetPresent&&(n.writer.writeUInt(this.baseDataOffset.getHighBitsUnsigned(),32),n.writer.writeUInt(this.baseDataOffset.getLowBitsUnsigned(),32)),this.flags.sampleDescriptionIndexPresent&&n.writer.writeUInt(this.sampleDescriptionIndex,32),this.flags.defaultSampleDurationPresent&&n.writer.writeUInt(this.defaultSampleDuration,32),this.flags.defaultSampleSizePresent&&n.writer.writeUInt(this.defaultSampleSize,32),this.flags.defaultSampleFlagsPresent&&As(this.defaultSampleFlags,n)},n}(Ou);function ff(t){var n=t.data,i=n.nextUint8(),e=new mu(yu.from(n.nextUint8Array(3)));e.skipBits(6);var r=Boolean(e.readBit()),o=Boolean(e.readBit());e.skipBits(10);var u=Boolean(e.readBit()),s=Boolean(e.readBit()),f=Boolean(e.readBit());e.skipBits(1);var c=Boolean(e.readBit()),h=Boolean(e.readBit()),a=n.nextUint32(),v=h?n.nextUint64():void 0,d=c?n.nextUint32():void 0,l=f?n.nextUint32():void 0,w=s?n.nextUint32():void 0,b=u?Qu(new mu(yu.from(n.nextUint8Array(4)))):void 0;return new sf({trackId:a,defaultBaseIsMoof:r,durationIsEmpty:o,baseDataOffset:v,sampleDescriptionIndex:d,defaultSampleDuration:l,defaultSampleSize:w,defaultSampleFlags:b},i)}x(),gt();var cf=function(t){function n(n,i,e){var r=t.call(this,"trun",n,function(t){var n,i,e,r;return{dataOffsetPresent:void 0!==t.dataOffset,firstSampleFlagsPresent:void 0!==t.firstSampleFlags,sampleDurationPresent:null!==(n=t.sampleDurationPresent)&&void 0!==n&&n,sampleSizePresent:null!==(i=t.sampleSizePresent)&&void 0!==i&&i,sampleFlagsPresent:null!==(e=t.sampleFlagsPresent)&&void 0!==e&&e,sampleCompositionTimeOffsetsPresent:null!==(r=t.sampleCompositionTimeOffsetsPresent)&&void 0!==r&&r}}(i))||this;return r.dataOffset=i.dataOffset,r.samples=e,r.firstSampleFlags=i.firstSampleFlags,r}return du(n,t),p.defineProperty(n.prototype,"dataOffset",{get:function(){return this.iS},set:function(t){if(t&&!Eu(t,32))throw new g("Provided data offset does not fit in 32 bits.");this.iS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"firstSampleFlags",{get:function(){return this.sS},set:function(t){if((null==t?void 0:t.samplePaddingValue)&&!Eu(t.samplePaddingValue,3))throw new g("Provided sample padding value does not fit in 3 bits.");if((null==t?void 0:t.sampleDegradationPriority)&&!Eu(t.sampleDegradationPriority,16))throw new g("Provided sample degradation priority does not fit in 16 bits.");this.sS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"samples",{get:function(){return this.nS},set:function(t){var n,i;if(!Eu(t.length,32))throw new g("The sample count cannot be represented in 32 bits.");for(var e=0,r=t;e<r.length;e++){var o=r[e];if(void 0===o.duration&&this.flags.sampleDurationPresent)throw new g("The sample duration present flag is set.");if(void 0!==o.duration&&!this.flags.sampleDurationPresent)throw new g("The sample duration present flag is not set.");if(o.duration&&!Eu(o.duration,32))throw new g("Provided sample duration does not fit in 32 bits.");if(void 0===o.size&&this.flags.sampleSizePresent)throw new g("The sample size present flag is set.");if(void 0!==o.size&&!this.flags.sampleSizePresent)throw new g("The sample size present flag is not set.");if(o.size&&!Eu(o.size,32))throw new g("Provided sample size does not fit in 32 bits.");if(void 0===o.flags&&this.flags.sampleFlagsPresent)throw new g("The sample flags present flag is set.");if(void 0!==o.flags&&!this.flags.sampleFlagsPresent)throw new g("The sample flags present flag is not set.");if((null===(n=o.flags)||void 0===n?void 0:n.samplePaddingValue)&&!Eu(o.flags.samplePaddingValue,3))throw new g("Provided sample padding value does not fit in 3 bits.");if((null===(i=o.flags)||void 0===i?void 0:i.sampleDegradationPriority)&&!Eu(o.flags.sampleDegradationPriority,16))throw new g("Provided sample degradation priority does not fit in 16 bits.");if(void 0===o.compositionTimeOffset&&this.flags.sampleCompositionTimeOffsetsPresent)throw new g("The sample compositionTimeOffset present flag is set.");if(void 0!==o.compositionTimeOffset&&!this.flags.sampleCompositionTimeOffsetsPresent)throw new g("The sample compositionTimeOffset present flag is not set.");if(o.compositionTimeOffset&&!Eu(o.compositionTimeOffset,32))throw new g("Provided sample compositionTimeOffset does not fit in 32 bits.")}this.nS=t},enumerable:!1,configurable:!0}),n.prototype.serializeFlags=function(t){t.writer.writeByte(0),t.writer.writeUInt(0,4),t.writer.writeBool(this.flags.sampleCompositionTimeOffsetsPresent),t.writer.writeBool(this.flags.sampleFlagsPresent),t.writer.writeBool(this.flags.sampleSizePresent),t.writer.writeBool(this.flags.sampleDurationPresent),t.writer.writeUInt(0,5),t.writer.writeBool(this.flags.firstSampleFlagsPresent),t.writer.writeBit(0),t.writer.writeBool(this.flags.dataOffsetPresent)},n.prototype.getBoxContentSize=function(){var n=t.prototype.getBoxContentSize.call(this)+4;return this.flags.dataOffsetPresent&&(n+=4),this.flags.firstSampleFlagsPresent&&(n+=4),this.flags.sampleDurationPresent&&(n+=4*this.samples.length),this.flags.sampleSizePresent&&(n+=4*this.samples.length),this.flags.sampleFlagsPresent&&(n+=4*this.samples.length),this.flags.sampleCompositionTimeOffsetsPresent&&(n+=4*this.samples.length),n},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.samples.length,32),this.flags.dataOffsetPresent&&n.writer.writeUInt(this.dataOffset,32),this.flags.firstSampleFlagsPresent&&As(this.firstSampleFlags,n);for(var i=0,e=this.samples;i<e.length;i++){var r=e[i];this.flags.sampleDurationPresent&&n.writer.writeUInt(r.duration,32),this.flags.sampleSizePresent&&n.writer.writeUInt(r.size,32),this.flags.sampleFlagsPresent&&As(r.flags,n),this.flags.sampleCompositionTimeOffsetsPresent&&(0===this.version?n.writer.writeUInt(r.compositionTimeOffset,32):n.writer.writeInt(r.compositionTimeOffset,32))}},n}(Ou);function hf(t){var n=t.data,i=n.nextUint8(),e=new mu(yu.from(n.nextUint8Array(3)));e.skipBits(12);var r=Boolean(e.readBit()),o=Boolean(e.readBit()),u=Boolean(e.readBit()),s=Boolean(e.readBit());e.skipBits(5);var f=Boolean(e.readBit());e.skipBits(1);var c=Boolean(e.readBit()),h=n.nextUint32(),a={sampleDurationPresent:s,sampleSizePresent:u,sampleFlagsPresent:o,sampleCompositionTimeOffsetsPresent:r};c&&(a.dataOffset=n.nextInt32()),f&&(a.firstSampleFlags=Qu(new mu(yu.from(n.nextUint8Array(4)))));for(var v=[],d=0;d<h;d++){var l={};s&&(l.duration=n.nextUint32()),u&&(l.size=n.nextUint32()),o&&(l.flags=Qu(new mu(yu.from(n.nextUint8Array(4))))),r&&(l.compositionTimeOffset=0===i?n.nextUint32():n.nextInt32()),v.push(l)}return new cf(i,a,v)}var af=function(t){function n(){return t.call(this,"traf")||this}return du(n,t),n}(ss);function vf(t){for(var n=new af,i=0,e=Gu(t.data);i<e.length;i++){var r=e[i];Yu(r,"tfhd")?n.boxes.push(ff(r)):Yu(r,"tfdt")?n.boxes.push(uf(r)):Yu(r,"trun")?n.boxes.push(hf(r)):n.boxes.push(ns(r))}return n}var df=function(t){function n(){return t.call(this,"moof")||this}return du(n,t),n}(ss);x(),gt();!function(t){function n(n){var i=t.call(this,"mfhd",0,0)||this;return i.sequenceNumber=n,i}du(n,t),p.defineProperty(n.prototype,"sequenceNumber",{get:function(){return this.rS},set:function(t){if(!Eu(t,32))throw new g("Provided sequence number does not fit in 32 bits.");this.rS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.sequenceNumber,32)}}(Ou);x(),gt();var lf=function(t){function n(n){var i=t.call(this,"frma")||this;return i.codingName=n,i}return du(n,t),p.defineProperty(n.prototype,"codingName",{get:function(){return this.oS},set:function(t){if(4!==t.length)throw new g("Provided coding name was not 4 characters long.");this.oS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return 4},n.prototype.serializeBoxContent=function(t){t.writer.writeString(this.codingName)},n}(Tu);x(),gt();!function(t){function n(n,i){var e=t.call(this,"pasp")||this;return e.hSpacing=n,e.vSpacing=i,e}du(n,t),p.defineProperty(n.prototype,"hSpacing",{get:function(){return this.hS},set:function(t){if(!Eu(t,32))throw new g("Provided hSpacing does not fit in 32 bits.");this.hS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"vSpacing",{get:function(){return this.aS},set:function(t){if(!Eu(t,32))throw new g("Provided vSpacing does not fit in 32 bits.");this.aS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return 8},n.prototype.serializeBoxContent=function(t){t.writer.writeUInt(this.hSpacing,32),t.writer.writeUInt(this.vSpacing,32)}}(Tu);x(),gt();!function(t){function n(n,i,e){var r=t.call(this,n)||this;return r.sample=i,r.sinf=e,r}du(n,t),n.prototype.getBoxContentSize=function(){return this.sample.getBoxContentSize()+this.sinf.getSize()},n.prototype.serializeBoxContent=function(t){this.sample.serializeBoxContent(t),t.concat(this.sinf.serialize())}}(ss);x(),gt();!function(t){function n(n,i,e){var r=t.call(this,"sinf")||this;return r.schm=i,r.schi=e,r.frma=new lf(n),r}du(n,t),n.prototype.getBoxContentSize=function(){var t,n,i,e;return this.frma.getSize()+(null!==(n=null===(t=this.schm)||void 0===t?void 0:t.getSize())&&void 0!==n?n:0)+(null!==(e=null===(i=this.schi)||void 0===i?void 0:i.getSize())&&void 0!==e?e:0)},n.prototype.serializeBoxContent=function(t){t.concat(this.frma.serialize()),this.schm&&t.concat(this.schm.serialize()),this.schi&&t.concat(this.schi.serialize())}}(Tu);x(),gt();var wf=function(t){function n(n,i,e){var r=t.call(this,"saio",n,void 0===e?0:1)||this;return r.entries=i,r.explicitAuxInfoType=e,r}return du(n,t),p.defineProperty(n.prototype,"bitSize",{get:function(){return 0===this.version?32:64},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"entries",{get:function(){return this.wA},set:function(t){var n=this;if(!Eu(t.length,32))throw new g("Number of entries provided does not fit in 32 bits.");if(t.some((function(t){return!Eu(t,n.bitSize)})))throw new g("Not all provided entries fit in ".concat(this.bitSize," bits."));this.wA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"explicitAuxInfoType",{get:function(){return this.uS},set:function(t){if(void 0===t)this.flags=0;else{if(!Eu(t.auxInfoType,32))throw new g("Provided auxInfoType does not fit in 32 bits.");if(!Eu(t.auxInfoTypeParameter,32))throw new g("Provided auxInfoTypeParameter does not fit in 32 bits.");this.flags=1}this.uS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+(void 0===this.explicitAuxInfoType?0:8)+4+this.entries.length*this.bitSize/8},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),void 0!==this.explicitAuxInfoType&&(n.writer.writeUInt(this.explicitAuxInfoType.auxInfoType,32),n.writer.writeUInt(this.explicitAuxInfoType.auxInfoTypeParameter,32)),n.writer.writeUInt(this.entries.length,32),this.serializeSaioContent(n)},n}(Ou);(function(t){function n(){return null!==t&&t.apply(this,arguments)||this}du(n,t),n.prototype.serializeSaioContent=function(t){for(var n=0,i=this.entries;n<i.length;n++){var e=i[n];t.writer.writeUInt(e,32)}}})(wf),function(t){function n(){return null!==t&&t.apply(this,arguments)||this}du(n,t),n.prototype.serializeSaioContent=function(t){for(var n=0,i=this.entries;n<i.length;n++){var e=i[n];t.writer.writeUInt(e.getHighBitsUnsigned(),32),t.writer.writeUInt(e.getLowBitsUnsigned(),32)}}}(wf);x(),gt();!function(t){function n(n,i,e){var r=t.call(this,"saiz",0,void 0===e?0:1)||this;return r.defaultSampleInfoSize=n,r.sampleInfoSizes=i,r.explicitAuxInfoType=e,r}du(n,t),p.defineProperty(n.prototype,"defaultSampleInfoSize",{get:function(){return this.cS},set:function(t){if(!Eu(t,8))throw new g("Provided defaultSampleInfoSize does not fit in a single byte.");this.cS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"sampleInfoSizes",{get:function(){return this.lS},set:function(t){if(!Eu(t.length,32))throw new g("Number of sampleInfoSizes provided does not fit in 32 bits.");if(t.some((function(t){return!Eu(t,8)})))throw new g("Not all provided sampleInfoSizes fit in a byte.");this.lS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"explicitAuxInfoType",{get:function(){return this.uS},set:function(t){if(void 0===t)this.flags=0;else{if(!Eu(t.auxInfoType,32))throw new g("Provided auxInfoType does not fit in 32 bits.");if(!Eu(t.auxInfoTypeParameter,32))throw new g("Provided auxInfoTypeParameter does not fit in 32 bits.");this.flags=1}this.uS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+(void 0===this.explicitAuxInfoType?0:8)+1+4+(0!==this.defaultSampleInfoSize?0:this.sampleInfoSizes.length)},n.prototype.serializeBoxContent=function(n){if(0!==this.defaultSampleInfoSize&&this.sampleInfoSizes.length>0)throw new g("Both a default size and specific sizes are provided. This is prohibited.");t.prototype.serializeBoxContent.call(this,n),void 0!==this.explicitAuxInfoType&&(n.writer.writeUInt(this.explicitAuxInfoType.auxInfoType,32),n.writer.writeUInt(this.explicitAuxInfoType.auxInfoTypeParameter,32)),n.writer.writeByte(this.defaultSampleInfoSize),n.writer.writeUInt(this.sampleInfoSizes.length,32);for(var i=0,e=this.sampleInfoSizes;i<e.length;i++){var r=e[i];n.writer.writeByte(r)}}}(Ou);x(),gt();!function(t){function n(n){var i=t.call(this,"sdtp",0,0)||this;return i.samples=n,i}du(n,t),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+this.samples.length},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n);for(var i=0,e=this.samples;i<e.length;i++){Ps(e[i],n)}}}(Ou);x(),gt();!function(t){function n(n){return t.call(this,"stsd",n,0)||this}du(n,t),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.boxes.length,32)}}(hs);x(),gt();var bf=function(t){function n(n,i,e){var r=t.call(this,"sgpd",n,0)||this;return r.entries=e,r.groupingType=i,r}return du(n,t),p.defineProperty(n.prototype,"groupingType",{get:function(){return this.dS},set:function(t){if(4!==t.length)throw new g("The provided groupingType does not equal 4 characters.");this.dS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+4},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeString(this.groupingType),this.serializeVersionBoxContent(n),n.writer.writeUInt(this.entries.length,32);for(var i=0,e=this.entries;i<e.length;i++){var r=e[i];this.serializeEntryBoxContent(n,r)}},n.prototype.serializeEntryBoxContent=function(t,n){n.serializeBoxContent(t)},n}(Ou);(function(t){function n(n,i){return t.call(this,0,n,i)||this}du(n,t),n.prototype.serializeVersionBoxContent=function(t){}})(bf),function(t){function n(n,i,e){var r=t.call(this,1,n,e)||this;return r.defaultLength=i,r}du(n,t),p.defineProperty(n.prototype,"defaultLength",{get:function(){return this.fS},set:function(t){if(!Eu(t,32))throw new g("The provided defaultLength does not fit in 32 bits.");this.fS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+this.entries.length*(this.defaultLength||4)},n.prototype.serializeVersionBoxContent=function(t){t.writer.writeUInt(this.defaultLength,32)},n.prototype.serializeEntryBoxContent=function(t,n){0===this.defaultLength&&t.writer.writeUInt(n.getBoxContentSize(),32),n.serializeBoxContent(t)}}(bf),function(t){function n(n,i,e,r){void 0===r&&(r=0);var o=this;if(n<2)throw new g("This constructor is only meant for versions 2 and up.");return(o=t.call(this,n,i,e)||this).defaultSampleDescriptionIndex=r,o}du(n,t),p.defineProperty(n.prototype,"defaultSampleDescriptionIndex",{get:function(){return this.UA},set:function(t){if(!Eu(t,32))throw new g("The provided defaultSampleDescriptionIndex does not fit in 32 bits.");this.UA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4},n.prototype.serializeVersionBoxContent=function(t){t.writer.writeUInt(this.defaultSampleDescriptionIndex,32)}}(bf);x(),gt();(function(t){function n(n){void 0===n&&(n=[]);var i=t.call(this,"stsz",0,0)||this;return i.sampleSizes=n,i}du(n,t),p.defineProperty(n.prototype,"sampleSizes",{get:function(){return this._S},set:function(t){if(!Eu(t.length,32))throw new g("Number of allowed samples cannot fit in 32 bits.");if(t.some((function(t){return!Eu(t,32)})))throw new g("Not all sampleSizes can be represented in 32 bits.");this._S=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+4+4*this.sampleSizes.length},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(0,32),n.writer.writeUInt(this.sampleSizes.length,32);for(var i=0,e=this.sampleSizes;i<e.length;i++){var r=e[i];n.writer.writeUInt(r,32)}}})(Ou),function(t){function n(n,i){void 0===n&&(n=0),void 0===i&&(i=0);var e=t.call(this,"stsz",0,0)||this;return e.defaultSampleSize=n,e.samples=i,e}du(n,t),p.defineProperty(n.prototype,"defaultSampleSize",{get:function(){return this.ZA},set:function(t){if(!Eu(t,32))throw new g("Provided defaultSampleSize does not fit in 32 bits.");this.ZA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"samples",{get:function(){return this.nS},set:function(t){if(!Eu(t,32))throw new g("Number of allowed samples cannot fit in 32 bits.");this.nS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+4},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.defaultSampleSize,32),n.writer.writeUInt(this.samples,32)}}(Ou);x(),gt();!function(t){function n(){return t.call(this,"stbl")||this}du(n,t)}(ss);x(),gt();!function(t){function n(n){var i=t.call(this,"stsc",0,0)||this;return i.entries=n,i}du(n,t),p.defineProperty(n.prototype,"entries",{get:function(){return this.wA},set:function(t){if(!Eu(t.length,32))throw new g("Number of allowed entries cannot fit in 32 bits.");if(t.some((function(t){return!Eu(t.firstChunk,32)||!Eu(t.sampleDescriptionIndex,32)||!Eu(t.samplesPerChunk,32)})))throw new g("Not all entries can be represented in 96 bits.");this.wA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+12*this.entries.length},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.entries.length,32);for(var i=0,e=this.entries;i<e.length;i++){var r=e[i];n.writer.writeUInt(r.firstChunk,32),n.writer.writeUInt(r.samplesPerChunk,32),n.writer.writeUInt(r.sampleDescriptionIndex,32)}}}(Ou);x(),gt();!function(t){function n(){return t.call(this,"schi")||this}du(n,t)}(ss);x(),gt();!function(t){function n(n,i,e){var r=t.call(this,"schm",0,void 0===e?0:1)||this;return r.schemeType=n,r.schemeVersion=i,r.schemeUri=e,r}du(n,t),p.defineProperty(n.prototype,"schemeType",{get:function(){return this.vS},set:function(t){if(4!==t.length)throw new g("The provided schemeType does not have a length of 4.");this.vS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"schemeVersion",{get:function(){return this.gS},set:function(t){if(!Eu(t,32))throw new g("The provided schemeVersion does not fit in 23 bits.");this.gS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"schemeUri",{get:function(){return this.mS},set:function(t){if(t&&4!==t.length)throw new g("The provided schemeUri does not have a length of 4.");this.flags=void 0===t?0:1,this.mS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+4+(void 0===this.schemeUri?0:this.schemeUri.length+1)},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeString(this.schemeType),n.writer.writeUInt(this.schemeVersion,32),this.schemeUri&&(n.writer.writeString(this.schemeUri),n.writer.writeByte(0))}}(Ou);x(),gt();var gf=function(t){function n(n,i,e,r,o,u,s){void 0===s&&(s=0);var f=t.call(this,"sidx",n,s)||this;return f.referenceId=i,f.timescale=e,f.earliestPresentationTime=r,f.firstOffset=o,f.references=u,f}return du(n,t),p.defineProperty(n.prototype,"bitSize",{get:function(){return 0===this.version?32:64},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"referenceId",{get:function(){return this.pS},set:function(t){if(!Eu(t,32))throw new g("Provided referenceId does not fit in 32 bits.");this.pS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"timescale",{get:function(){return this.MA},set:function(t){if(!Eu(t,32))throw new g("Provided timescale does not fit in 32 bits.");this.MA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"earliestPresentationTime",{get:function(){return this.wS},set:function(t){if(!Eu(t,this.bitSize))throw new g("Provided earliestPresentationTime does not fit in ".concat(this.bitSize," bits."));this.wS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"firstOffset",{get:function(){return this.yS},set:function(t){if(!Eu(t,this.bitSize))throw new g("Provided timescale does not fit in ".concat(this.bitSize," bits."));this.yS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"references",{get:function(){return this.bS},set:function(t){if(!Eu(t.length,16))throw new g("The number of provided reference items does not fit in 16 bits.");for(var n=0,i=t;n<i.length;n++){var e=i[n];if(!Eu(e.referencedSize,31))throw new g("Provided referenced size does not fit in 31 bits.");if(!Eu(e.subsegmentDuration,32))throw new g("Provided subsegment duration does not fit in 31 bits.");if(!Eu(e.sapType,3))throw new g("Provided SAP type does not fit in 3 bits.");if(!Eu(e.sapDeltaTime,28))throw new g("Provided SAP delta time does not fit in 28 bits.")}this.bS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+4+this.bitSize/8*2+2+2+12*this.references.length},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.referenceId,32),n.writer.writeUInt(this.timescale,32),this.serializeSidxBoxContent(n),n.writer.writeUInt(0,16),n.writer.writeUInt(this.references.length,16);for(var i=0,e=this.references;i<e.length;i++){var r=e[i];n.writer.writeBit(r.referenceType),n.writer.writeUInt(r.referencedSize,31),n.writer.writeUInt(r.subsegmentDuration,32),n.writer.writeBool(r.startsWithSap),n.writer.writeUInt(r.sapType,3),n.writer.writeUInt(r.sapDeltaTime,28)}},n}(Ou),mf=function(t){function n(n,i,e,r,o,u){return void 0===u&&(u=0),t.call(this,0,n,i,e,r,o,u)||this}return du(n,t),n.prototype.serializeSidxBoxContent=function(t){t.writer.writeUInt(this.earliestPresentationTime,32),t.writer.writeUInt(this.firstOffset,32)},n}(gf),pf=function(t){function n(n,i,e,r,o,u){return void 0===u&&(u=0),t.call(this,1,n,i,e,r,o,u)||this}return du(n,t),n.prototype.serializeSidxBoxContent=function(t){t.writer.writeUInt(this.earliestPresentationTime.getHighBitsUnsigned(),32),t.writer.writeUInt(this.earliestPresentationTime.getLowBitsUnsigned(),32),t.writer.writeUInt(this.firstOffset.getHighBitsUnsigned(),32),t.writer.writeUInt(this.firstOffset.getLowBitsUnsigned(),32)},n}(gf);x(),gt();!function(t){function n(n,i,e){return t.call(this,"styp",n,i,e)||this}du(n,t)}(gs);x(),gt();!function(t){function n(n){void 0===n&&(n=0);var i=t.call(this,"smhd",0,0)||this;return i.balance=n,i}du(n,t),p.defineProperty(n.prototype,"balance",{get:function(){return this.SS},set:function(t){if(t<-1||t>1)throw new g("Provided balance does not fit in the allowed range [-1, 1].");if(!Eu(Iu(t,8),16))throw new g("Provided balance does not fit in 16 bits (fixed 8.8).");this.SS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+2+2},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(Iu(this.balance,8),16),n.writer.writeUInt(0,16)}}(Ou);x(),gt();!function(t){function n(n){var i=t.call(this,"stss",0,0)||this;return i.entries=n,i}du(n,t),p.defineProperty(n.prototype,"entries",{get:function(){return this.wA},set:function(t){if(!Eu(t.length,32))throw new g("Number of allowed entries cannot fit in 32 bits.");if(t.some((function(t){return!Eu(t,32)})))throw new g("Not all entries can be represented in 32 bits.");this.wA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+4*this.entries.length},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.entries.length,32);for(var i=0,e=this.entries;i<e.length;i++){var r=e[i];n.writer.writeUInt(r,32)}}}(Ou);x(),gt();!function(t){function n(n){var i=t.call(this,"stts",0,0)||this;return i.entries=n,i}du(n,t),p.defineProperty(n.prototype,"entries",{get:function(){return this.wA},set:function(t){if(!Eu(t.length,32))throw new g("Number of allowed entries cannot fit in 32 bits.");if(t.some((function(t){return!Eu(t.sampleCount,32)||!Eu(t.sampleDelta,32)})))throw new g("Not all entries can be represented in 64 bits.");this.wA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4+8*this.entries.length},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.entries.length,32);for(var i=0,e=this.entries;i<e.length;i++){var r=e[i];n.writer.writeUInt(r.sampleCount,32),n.writer.writeUInt(r.sampleDelta,32)}}}(Ou);x(),gt();!function(t){function n(n){var i=t.call(this,"trep",0,0)||this;return i.trackId=n,i}du(n,t),p.defineProperty(n.prototype,"trackId",{get:function(){return this.WA},set:function(t){if(!Eu(t,32))throw new g("The provided trackId does not fit in 32 bits.");this.WA=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+4},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.trackId,32)}}(hs);x(),gt();!function(t){function n(){return t.call(this,"udta")||this}du(n,t)}(ss);x(),gt();var yf={red:0,green:0,blue:0};!function(t){function n(n,i){void 0===n&&(n=0),void 0===i&&(i=yf);var e=t.call(this,"vmhd",0,1)||this;return e.graphicsMode=n,e.opColor=i,e}du(n,t),p.defineProperty(n.prototype,"opColor",{get:function(){return this.TS},set:function(t){if(!Eu(t.red,16)||!Eu(t.green,16)||!Eu(t.blue,16))throw new g("Not all colors could be represented in 16 bits.");this.TS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+2+6},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.graphicsMode,16),n.writer.writeUInt(this.opColor.red,16),n.writer.writeUInt(this.opColor.green,16),n.writer.writeUInt(this.opColor.blue,16)}}(Ou);x(),gt();var _f=function(t){function n(n,i,e,r,o){void 0===r&&(r={}),void 0===o&&(o=void 0);var u,s,f,c,h,a=this;return(a=t.call(this,n,i)||this).width=e.width,a.height=e.height,a.horizontalResolution=null!==(u=e.horizontal)&&void 0!==u?u:72,a.verticalResolution=null!==(s=e.vertical)&&void 0!==s?s:72,a.compressorName=null!==(f=r.compressorName)&&void 0!==f?f:"",a.frameCount=null!==(c=r.frameCount)&&void 0!==c?c:1,a.depth=null!==(h=r.depth)&&void 0!==h?h:24,a.clap=r.clap,a.pasp=r.pasp,a.extra=o,a}return du(n,t),p.defineProperty(n.prototype,"width",{get:function(){return this.KA},set:function(t){if(!Eu(t,16))throw new g("Provided width does not fit in 16 bits.");this.KA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"height",{get:function(){return this.jA},set:function(t){if(!Eu(t,16))throw new g("Provided height does not fit in 16 bits.");this.jA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"horizontalResolution",{get:function(){return this.kS},set:function(t){if(!Eu(Iu(t,16),32))throw new g("Provided horizontalResolution does not fit in 32 bits (fixed 16.16).");this.kS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"verticalResolution",{get:function(){return this.ES},set:function(t){if(!Eu(Iu(t,16),32))throw new g("Provided verticalResolution does not fit in 32 bits (fixed 16.16).");this.ES=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"compressorName",{get:function(){return this.xS},set:function(t){if(t.length>31)throw new g("The provided compressorName should at most be 31 characters long.");this.xS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"frameCount",{get:function(){return this.IS},set:function(t){if(!Eu(t,16))throw new g("Provided frameCount does not fit in 16 bits.");this.IS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"depth",{get:function(){return this.RS},set:function(t){if(!Eu(t,16))throw new g("Provided depth does not fit in 16 bits.");this.RS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){var n,i,e,r,o,u;return t.prototype.getBoxContentSize.call(this)+2+2+12+2+2+4+4+4+2+32+2+2+(null!==(i=null===(n=this.clap)||void 0===n?void 0:n.getSize())&&void 0!==i?i:0)+(null!==(r=null===(e=this.pasp)||void 0===e?void 0:e.getSize())&&void 0!==r?r:0)+(null!==(u=null===(o=this.extra)||void 0===o?void 0:o.length)&&void 0!==u?u:0)},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(0,16),n.writer.writeUInt(0,16),n.writer.writeUInt(0,32),n.writer.writeUInt(0,32),n.writer.writeUInt(0,32),n.writer.writeUInt(this.width,16),n.writer.writeUInt(this.height,16),n.writer.writeUInt(Iu(this.horizontalResolution,16),32),n.writer.writeUInt(Iu(this.verticalResolution,16),32),n.writer.writeUInt(0,32),n.writer.writeUInt(this.frameCount,16),n.writer.writeByte(this.compressorName.length),n.writer.writeString(this.compressorName);for(var i=0;i<31-this.compressorName.length;i++)n.writer.writeByte(0);n.writer.writeUInt(this.depth,16),n.writer.writeInt(-1,16),this.clap&&n.concat(this.clap.serialize()),this.pasp&&n.concat(this.pasp.serialize()),this.extra&&ku(n.writer,this.extra)},n}(fs);x(),gt(),x(),gt();!function(t){function n(n){var i=t.call(this,"esds",0,0)||this;return i.esDescriptor=n,i}du(n,t),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+(this.esDescriptor instanceof E?this.esDescriptor.length:this.esDescriptor.getSize())},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),this.esDescriptor instanceof E?n.concat(yu.from(this.esDescriptor)):this.esDescriptor.serialize(n)}}(Ou);x(),gt();!function(t){function n(n,i,e){var r=t.call(this,"mp4a",n,e)||this;return r.esd=i,r}du(n,t),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+this.esd.getSize()},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.concat(this.esd.serialize())}}(cs);x(),gt();!function(t){function n(n,i,e,r){void 0===r&&(r={});var o=t.call(this,"mp4v",n,i,r)||this;return o.esDescriptor=e,o}du(n,t),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+this.esDescriptor.getSize()},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),this.esDescriptor.serialize(n)}}(_f);x(),gt();!function(t){function n(n,i){var e=t.call(this,"mp4s",n)||this;return e.esDescriptor=i,e}du(n,t),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+this.esDescriptor.getSize()},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),this.esDescriptor.serialize(n)}}(fs);x(),gt(),x(),gt();!function(t){function n(n){var i=t.call(this,"avcC")||this;return i.decoderConfig=n,i}du(n,t),n.prototype.getBoxContentSize=function(){return this.decoderConfig.getSize()},n.prototype.serializeBoxContent=function(t){this.decoderConfig.serialize(t)}}(Tu);x(),gt();!function(){function t(t,n,i,e,r,o){void 0===o&&(o=1),this.lengthSizeMinusOne=i,this.version=o,this.profileIndication=t.indication,this.profileCompatibility=t.compatibility,this.levelIndication=n,this.spsSets=e,this.ppsSets=r}p.defineProperty(t.prototype,"version",{get:function(){return this.CS},set:function(t){if(!Eu(t,8))throw new g("Provided version does not fit in 8 bits.");this.CS=t},enumerable:!1,configurable:!0}),p.defineProperty(t.prototype,"profileIndication",{get:function(){return this.PS},set:function(t){if(!Eu(t,8))throw new g("Provided profileIndication does not fit in 8 bits.");this.PS=t},enumerable:!1,configurable:!0}),p.defineProperty(t.prototype,"profileCompatibility",{get:function(){return this.DS},set:function(t){if(!Eu(t,8))throw new g("Provided profileCompatibility does not fit in 8 bits.");this.DS=t},enumerable:!1,configurable:!0}),p.defineProperty(t.prototype,"levelIndication",{get:function(){return this.NS},set:function(t){if(!Eu(t,8))throw new g("Provided levelIndication does not fit in 8 bits.");this.NS=t},enumerable:!1,configurable:!0}),p.defineProperty(t.prototype,"spsSets",{get:function(){return this.MS},set:function(t){if(!Eu(t.length,5))throw new g("Provided number of spsSets exceeds the max (32)");this.MS=t},enumerable:!1,configurable:!0}),p.defineProperty(t.prototype,"ppsSets",{get:function(){return this.LS},set:function(t){if(!Eu(t.length,8))throw new g("Provided number of ppsSets exceeds the max (256)");this.LS=t},enumerable:!1,configurable:!0}),t.prototype.getSize=function(){return 7+2*this.spsSets.length+this.spsSets.reduce((function(t,n){return t+n.length}),0)+2*this.ppsSets.length+this.ppsSets.reduce((function(t,n){return t+n.length}),0)},t.prototype.serialize=function(t){t.writer.writeByte(this.version),t.writer.writeByte(this.profileIndication),t.writer.writeByte(this.profileCompatibility),t.writer.writeByte(this.levelIndication),t.writer.writeBits([1,1,1,1,1,1]),t.writer.writeUInt(this.lengthSizeMinusOne,2),t.writer.writeBits([1,1,1]),t.writer.writeUInt(this.spsSets.length,5);for(var n=0,i=this.spsSets;n<i.length;n++){var e=i[n];t.writer.writeUInt(e.length,16),t.concat(yu.from(e))}t.writer.writeByte(this.ppsSets.length);for(var r=0,o=this.ppsSets;r<o.length;r++){var u=o[r];t.writer.writeUInt(u.length,16),t.concat(yu.from(u))}}}();x(),gt();!function(t){function n(n,i,e,r,o){void 0===r&&(r={}),void 0===o&&(o=void 0);var u=t.call(this,"avc1",n,i,r)||this;return u.configurationBox=e,u.bitrateBox=o,u}du(n,t),n.prototype.getBoxContentSize=function(){var n,i;return t.prototype.getBoxContentSize.call(this)+this.configurationBox.getSize()+(null!==(i=null===(n=this.bitrateBox)||void 0===n?void 0:n.getSize())&&void 0!==i?i:0)},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.concat(this.configurationBox.serialize()),this.bitrateBox&&n.concat(this.bitrateBox.serialize())}}(_f);x(),gt();!function(t){function n(n,i,e){var r=t.call(this,"btrt")||this;return r.bufferSizeDb=n,r.max=i,r.avg=e,r}du(n,t),p.defineProperty(n.prototype,"bufferSizeDb",{get:function(){return this.aA},set:function(t){if(!Eu(t,32))throw new g("Provided bufferSizeDb does not fit in 32 bits.");this.aA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"max",{get:function(){return this.M_},set:function(t){if(!Eu(t,32))throw new g("Provided max does not fit in 32 bits.");this.M_=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"avg",{get:function(){return this.FS},set:function(t){if(!Eu(t,32))throw new g("Provided avg does not fit in 32 bits.");this.FS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return 12},n.prototype.serializeBoxContent=function(t){t.writer.writeUInt(this.bufferSizeDb,32),t.writer.writeUInt(this.max,32),t.writer.writeUInt(this.avg,32)}}(Tu);x(),gt(),x(),gt(),x(),gt();var Sf=function(t){function n(n,i){var e,r,o,u,s=this;if(s=t.call(this,"tenc",n,0)||this,i.perSampleIvSize>0&&(null!==(r=null===(e=i.constantIv)||void 0===e?void 0:e.length)&&void 0!==r?r:0)>0)throw new g("Either perSampleSize should be > 0 or constantIv should be defined. Not both.");return s.kId=i.kId,s.isProtected=null!==(o=i.isProtected)&&void 0!==o?o:1,i.perSampleIvSize>0?s.perSampleIvSize=i.perSampleIvSize:s.constantIv=null!==(u=i.constantIv)&&void 0!==u?u:new E(0),s}return du(n,t),p.defineProperty(n.prototype,"isProtected",{get:function(){return this.VS},set:function(t){if(!Eu(t,8))throw new g("Provided isProtected does not fit in 1 byte.");this.VS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"perSampleIvSize",{get:function(){return this.WS},set:function(t){if(![8,16].includes(t))throw new g("Provided perSampleIvSize does not match any allowed value [8, 16].");this.WS=t,this.US=new E(0)},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"kId",{get:function(){return this.GS},set:function(t){if(16!==t.length)throw new g("Provided kId length is not 16.");this.GS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"constantIv",{get:function(){return this.US},set:function(t){if(![8,16].includes(t.length))throw new g("Provided constant IV length does not match any allowed value [8, 16].");this.US=t,this.WS=0},enumerable:!1,configurable:!0}),n.prototype.getTencHeaderSize=function(){return 20+(this.constantIv.length>0?1+this.constantIv.length:0)},n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+this.getTencHeaderSize()},n.prototype.serializeVersionBoxContent=function(t){t.writer.writeByte(0)},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),this.serializeOwnContent(n)},n.prototype.serializeOwnContent=function(t){t.writer.writeByte(0),this.serializeVersionBoxContent(t),t.writer.writeByte(this.isProtected),t.writer.writeByte(this.perSampleIvSize),ku(t.writer,this.kId),0===this.perSampleIvSize&&(t.writer.writeByte(this.constantIv.length),ku(t.writer,this.constantIv))},n}(Ou),Tf=(function(t){function n(n){return t.call(this,0,n)||this}du(n,t)}(Sf),function(t){function n(n){var i=t.call(this,1,n)||this;return i.cryptByteBlocks=n.cryptByteBlock,i.skipByteBlocks=n.skipByteBlock,i}return du(n,t),p.defineProperty(n.prototype,"cryptByteBlocks",{get:function(){return this.ZS},set:function(t){if(!Eu(t,4))throw new g("Provided cryptByteBlocks does not fit in 4 bits.");this.ZS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"skipByteBlocks",{get:function(){return this.HS},set:function(t){if(!Eu(t,4))throw new g("Provided skipByteBlocks does not fit in 4 bits.");this.HS=t},enumerable:!1,configurable:!0}),n.prototype.serializeVersionBoxContent=function(t){t.writer.writeUInt(this.cryptByteBlocks,4),t.writer.writeUInt(this.skipByteBlocks,4)},n}(Sf));!function(t){function n(n){var i=t.call(this)||this;return i.tencBox=new Tf(n),i}du(n,t),n.prototype.serializeBoxContent=function(t){this.tencBox.serializeOwnContent(t)},n.prototype.getBoxContentSize=function(){return this.tencBox.getTencHeaderSize()}}(Ds);function Ef(t){return void 0!==t.iv}function If(t){return void 0!==t.subsamples}x(),gt();!function(t){function n(n){var i=t.call(this,"senc",0,{useSubsampleEncryption:!1})||this;return i.samples=n,i}du(n,t),p.defineProperty(n.prototype,"samples",{get:function(){return this.nS},set:function(t){var n;if(!Eu(t.length,32))throw new g("The number of samples provided does not fit in 32 bits.");for(var i=0,e=t;i<e.length;i++){var r=e[i];if(Ef(r)&&![8,16].includes(r.iv.length))throw new g("IV of one of the provided samples did not satisfy the required length constraints. [8, 16]");if(void 0===n&&(n=If(r)),!0===n&&!If(r)||!1===n&&If(r))throw new g("Mix of samples with and without subsamples detected.");if(If(r)){if(!Eu(r.subsamples.length,16))throw new g("Subsample length of one of the provided samples does not fit in 16 bits.");for(var o=0,u=r.subsamples;o<u.length;o++){var s=u[o];if(!Eu(s.clearData,16))throw new g("Subsample clearData of one of the provided samples does not fit in 16 bits.");if(!Eu(s.protectedData,23))throw new g("Subsample protectedData of one of the provided samples does not fit in 23 bits.")}}}this.flags.useSubsampleEncryption=null!=n&&n,this.nS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){for(var n=0,i=0,e=this.samples;i<e.length;i++){var r=e[i];Ef(r)&&(n+=r.iv.length),If(r)&&(n+=2+6*r.subsamples.length)}return t.prototype.getBoxContentSize.call(this)+4+n},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeUInt(this.samples.length,32);for(var i=0,e=this.samples;i<e.length;i++){var r=e[i];if(Ef(r)&&ku(n.writer,r.iv),If(r)){n.writer.writeUInt(r.subsamples.length,16);for(var o=0,u=r.subsamples;o<u.length;o++){var s=u[o];n.writer.writeUInt(s.clearData,16),n.writer.writeUInt(s.protectedData,32)}}}},n.prototype.serializeFlags=function(t){t.writer.writeUInt(this.flags.useSubsampleEncryption?2:0,24)}}(Ou);x(),gt(),x(),gt();!function(t){function n(n,i,e,r,o){var u=t.call(this,"emsg",0,0)||this;return u.schemeIdUri=n,u.value=i,u.data=o,u.id=e,u.timescale=r.timescale,u.presentationTimeDelta=r.presentationTimeDelta,u.eventDuration=r.eventDuration,u}du(n,t),p.defineProperty(n.prototype,"timescale",{get:function(){return this.MA},set:function(t){if(!Eu(t,32))throw new g("The provided timescale does not fit in 32 bits.");this.MA=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"presentationTimeDelta",{get:function(){return this.XS},set:function(t){if(!Eu(t,32))throw new g("The provided presentationTimeDelta does not fit in 32 bits.");this.XS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"eventDuration",{get:function(){return this.zS},set:function(t){if(!Eu(t,32))throw new g("The provided eventDuration does not fit in 32 bits.");this.zS=t},enumerable:!1,configurable:!0}),p.defineProperty(n.prototype,"id",{get:function(){return this.qS},set:function(t){if(!Eu(t,32))throw new g("The provided id does not fit in 32 bits.");this.qS=t},enumerable:!1,configurable:!0}),n.prototype.getBoxContentSize=function(){return t.prototype.getBoxContentSize.call(this)+this.schemeIdUri.length+1+this.value.length+1+16+this.data.length},n.prototype.serializeBoxContent=function(n){t.prototype.serializeBoxContent.call(this,n),n.writer.writeString(this.schemeIdUri),n.writer.writeByte(0),n.writer.writeString(this.value),n.writer.writeByte(0),n.writer.writeUInt(this.timescale,32),n.writer.writeUInt(this.presentationTimeDelta,32),n.writer.writeUInt(this.eventDuration,32),n.writer.writeUInt(this.id,32),n.concat(yu.from(this.data))}}(Ou);x(),gt(),x(),gt(),x(),gt();!function(){function t(){this.boxes=[]}t.prototype.serialize=function(){for(var t=new Su,n=0,i=this.boxes;n<i.length;n++){var e=i[n];t.concat(e.serialize())}return t.toRangedBuffer()}}();function kf(t,n){return function(i){var e=new ju(function(t){return new DataView(t.buffer,t.byteOffset,t.byteLength)}(i),new Xu),r=function(t,n){for(var i=t.data,e=t.cursor;e.offset<i.byteLength;){var r=$u(i,e);if(!r.complete)return;if(Yu(r.box,n))return r.box}}(e,t);if(!r)throw new g("".concat(t," box not found"));return n(r)}}kf("moov",(function(t){for(var n=new nf,i=0,e=Gu(t.data);i<e.length;i++){var r=e[i];Yu(r,"mvhd")?n.boxes.push(Ks(r)):Yu(r,"trak")?n.boxes.push(tf(r)):Yu(r,"mvex")?n.boxes.push(qs(r)):Yu(r,"pssh")?n.boxes.push(Ms(r)):n.boxes.push(ns(r))}return n})),kf("sidx",(function(t){var n,i,e=t.data,r=Zu(e.nextUint32()),o=r.version,u=r.flags,s=e.nextUint32(),f=e.nextUint32();0===o?(n=e.nextUint32(),i=e.nextUint32()):(n=e.nextUint64(),i=e.nextUint64()),e.skip(2);for(var c=e.nextUint16(),h=[],a=0;a<c;a++){var v=new mu(yu.from(e.nextUint8Array(12))),d=v.readBit(),l=v.readUInt(31),w=v.readUInt(32),b=Boolean(v.readBit()),g=v.readUInt(3),m=v.readUInt(28);h.push({referenceType:d,referencedSize:l,subsegmentDuration:w,startsWithSap:b,sapType:g,sapDeltaTime:m})}return 0===o?new mf(s,f,n,i,h,u.raw):new pf(s,f,n,i,h,u.raw)})),kf("moof",(function(t){for(var n=new df,i=0,e=Gu(t.data);i<e.length;i++){var r=e[i];Yu(r,"traf")?n.boxes.push(vf(r)):Yu(r,"pssh")?n.boxes.push(Ms(r)):n.boxes.push(ns(r))}return n}));var Rf=kf("pssh",Ms),Of=function(t){function n(n,i){var e;(e=t.call(this)||this).jS=n,e.rT=i,e.$S=!1,e.oT=function(){e.sT()},e.hT=function(t){e._o(new Po(e,t.messageType,cu(e.rT,t.message)))},e.aT=function(){e.$S=!0,e.QS.Mb>0&&(e.QS.Vb(),e._o(new No(e.QS))),e.jS.removeEventListener("keystatuseschange",e.oT),e.jS.removeEventListener("message",e.hT)},e.jS.addEventListener("keystatuseschange",e.oT),e.jS.addEventListener("message",e.hT),e.QS=new su;var r=[];return e.jS.closed&&r.push(J.resolve(e.jS.closed)),e.tT=new fu,r.push(e.tT.Gb),e.Vd=J.race(r).then(e.aT,e.aT),e.sT(),e}_t(n,t);var i=n.prototype;return i.Ws=function(){if(this.$S)return this.Vd;var t=[];return t.push(J.resolve(this.jS.close())),t.push(pn(1e3)),this.tT.rp(J.race(t).catch(Nf)),this.$S=!0,this.Vd},i.eT=function(t,n,i){if(Ut.hg){var e=Rf(Jo(n));if(1===e.version)n=new xs(e.systemId,e.data).serialize().join()}return J.resolve(this.jS.generateRequest(t,n)).catch(Nf)},i.$n=function(t){return J.resolve(this.jS.load(t)).catch(Nf)},i.iT=function(){return J.resolve(this.jS.remove()).catch(Nf)},i.ir=function(t){return J.resolve(this.jS.update(t)).catch(Nf)},i.sT=function(){var t=this;this.QS.Vb(),this.jS.keyStatuses.forEach((function(n,i){t.nT(i,n)})),this._o(new No(this.QS))},i.nT=function(t,n){if("string"==typeof t){var i=t;t=n,n=i}var e=Jo(t);if(this.rT===Jr&&16===e.byteLength&&(Ut.Sg||Ut.ym)){var r=$o(e),o=r.getUint32(0,!0),u=r.getUint16(4,!0),s=r.getUint16(6,!0);r.setUint32(0,o,!1),r.setUint16(4,u,!1),r.setUint16(6,s,!1)}this.rT===Jr&&"status-pending"===n&&(n="usable"),this.QS.Ob(e,n)},Tt(n,[{key:"YS",get:function(){return this.Vd}},{key:"KS",get:function(){return this.jS.expiration}},{key:"wb",get:function(){return this.QS}},{key:"JS",get:function(){return this.jS.sessionId}}]),n}(Eo);function Nf(t){var n;if(t.message){var i=t.message.match(/^SystemCode:0x([0-9a-fA-F]+)$/);i&&(n=0|_(i[1],16))}throw new au(t.message,void 0,n,t)}var Pf=function(){function t(t,n,i){this.cT=t,this.lT=n,this.kd=i}var n=t.prototype;return n.uT=function(t){var n=this;return $t((function(){return Zt(this,(function(i){return[2,new Of(n.cT.createSession(t),n.lT)]}))}))()},n.dT=function(t){return J.resolve(this.cT.setServerCertificate(t))},n.kn=function(t){return J.resolve(t.setMediaKeys(this.cT))},n.fT=function(t){return J.resolve(t.setMediaKeys(null))},n.nr=function(){return J.resolve()},t}(),Af=function(){function t(t,n,i){this._T=t,this.rT=n,this.gT=i}var n=t.prototype;return n.vT=function(){var t=this;return $t((function(){var n;return Zt(this,(function(i){switch(i.label){case 0:return[4,t._T.createMediaKeys()];case 1:return n=i.sent(),[2,new Pf(n,t.rT,t.gT)]}}))}))()},n.mT=function(){return this.gT},Tt(t,[{key:"lT",get:function(){return this._T.keySystem}}]),t}();function Df(t){var n=t.trim(),i=n.indexOf(";");return i<0?n:n.substr(0,i).trim()}function Cf(t,n,i,e){var r=!1;if(!(e.persistentState&&"optional"!==e.persistentState||e.distinctiveIdentifier&&"optional"!==e.distinctiveIdentifier)){var o={audioCapabilities:[],videoCapabilities:[],persistentState:e.persistentState||"optional",distinctiveIdentifier:e.distinctiveIdentifier||"optional",initDataTypes:e.initDataTypes,sessionTypes:["temporary"],label:e.label,yT:e.yT},u=!1;if(e.audioCapabilities){var s=e.audioCapabilities.filter((function(t){return Boolean(t.contentType)}));s.length&&(o.audioCapabilities=s.filter((function(e){return xf(t,n,i,e)})),u=!0,o.audioCapabilities.length&&(r=!0))}if(e.videoCapabilities){var f=e.videoCapabilities.filter((function(t){return Boolean(t.contentType)}));f.length&&(o.videoCapabilities=f.filter((function(e){return xf(t,n,i,e)})),u=!0,o.videoCapabilities.length&&(r=!0))}return u||(r=t(i,"video/mp4")),r?o:void 0}}function xf(t,n,i,e){return!!e.contentType&&(!(e.encryptionScheme&&!fn(n,e.encryptionScheme))&&(!e.robustness&&t(i,Df(e.contentType))))}function Bf(t){if(t.videoCapabilities)for(var n=0,i=t.videoCapabilities;n<i.length;n++){var e=i[n];if(e.contentType)return e.contentType}if(t.audioCapabilities)for(var r=0,o=t.audioCapabilities;r<o.length;r++){var u=o[r];if(u.contentType)return u.contentType}}function Mf(t){for(var n=[],i=0;i<t.length;i++){var e=t[i];e.encryptionScheme&&n.push({contentType:e.contentType,robustness:e.robustness})}return t.concat(n)}function Lf(t){return!(!t.audioCapabilities||!t.audioCapabilities.some(Uf))||!(!t.videoCapabilities||!t.videoCapabilities.some(Uf))}function Uf(t){return!t.robustness}function Ff(t,n){for(var i=[],e=0;e<t.length;e++){var r=t[e];r.robustness?i.push(r):i.push(Xr({},r,{robustness:n}))}return i}x(),gt(),x(),gt();var zf=function(){function t(){}return t.prototype.Qw=function(t,n){return $t((function(){var i,e,r,o,u,s,f;return Zt(this,(function(c){switch(c.label){case 0:for(n=n.filter((function(t){return!t.yT})),i=0;i<n.length;i++)(e=n[i]).audioCapabilities&&(e.audioCapabilities=Mf(e.audioCapabilities)),e.videoCapabilities&&(e.videoCapabilities=Mf(e.videoCapabilities));if(t!==no||!n.some(Lf))return[3,4];r=n.map((function(t){return function(t,n){return Xr({},t,{videoCapabilities:t.videoCapabilities?Ff(t.videoCapabilities,n):void 0,audioCapabilities:t.audioCapabilities?Ff(t.audioCapabilities,n):void 0})}(t,"SW_SECURE_CRYPTO")})),c.label=1;case 1:return c.trys.push([1,3,,4]),[4,v.requestMediaKeySystemAccess(t,r)];case 2:return o=c.sent(),u=o.getConfiguration(),[2,new Af(o,t,u)];case 3:return c.sent(),[3,4];case 4:return[4,v.requestMediaKeySystemAccess(t,n)];case 5:return s=c.sent(),f=s.getConfiguration(),[2,new Af(s,t,f)]}}))}))()},t.bT=function(){return void 0!==v&&"function"==typeof v.requestMediaKeySystemAccess},t}();x(),gt(),x(),gt(),x(),gt(),x(),gt();var Wf=function(t){function n(n,i){var e;return(e=t.call(this)||this).IT=n,e.CT=i,e.$S=!1,e.MT=void 0,e.ET=void 0,e.AT=void 0,e.aT=function(){e.$S=!0,e.ST.Wb(void 0),e.AT&&(e.AT.removeEventListener("mskeyclose",e.aT),e.AT.removeEventListener("mskeymessage",e.PT),e.AT.removeEventListener("mskeyerror",e.Ss),e.AT.removeEventListener("mskeyadded",e.DT))},e.PT=function(t){e.ET&&(e.ET.Wb(void 0),e.ET=void 0),e._o(new Po(e,"license-request",Qo(t.message).buffer,t.destinationURL||void 0))},e.Ss=function(){var t=e.AT&&e.AT.error;if(t){var n=new au("Unknown CDM error",t.code,t.systemCode);if(e.ET)e.ET.Ub(n),e.ET=void 0;else if(e.MT)e.MT.Ub(n),e.MT=void 0;else switch(n.Zb){case MSMediaKeyError.MS_MEDIA_KEYERR_OUTPUT:case MSMediaKeyError.MS_MEDIA_KEYERR_HARDWARECHANGE:e.NT("output-not-allowed");break;default:e.NT("internal-error")}}},e.DT=function(){e.ET&&(e.NT("usable"),e.ET.Wb(void 0),e.ET=void 0),e.MT&&(e.NT("usable"),e.MT.Wb(void 0),e.MT=void 0)},e.ST=new fu,e.TT=new su,e}_t(n,t);var i=n.prototype;return i.eT=function(t,n,i){var e=this;return $t((function(){return Zt(this,(function(t){switch(t.label){case 0:return e.kT(),e.ET=new fu,e.uT(Jo(n),i),[4,e.ET.Gb];case 1:return t.sent(),[2]}}))}))()},i.uT=function(t,n){if(!t)throw new m("Expected initData to be defined but was "+t+".");var i,e=n&&n.playready&&n.playready.xT;return(i=n?this.IT.createSession(this.CT,t,e):this.IT.createSession(this.CT,t)).addEventListener("mskeyclose",this.aT),i.addEventListener("mskeymessage",this.PT),i.addEventListener("mskeyerror",this.Ss),i.addEventListener("mskeyadded",this.DT),this.AT=i,this.NT("status-pending"),i},i.$n=function(t){var n=this;return $t((function(){return Zt(this,(function(t){return n.kT(),[2,!0]}))}))()},i.ir=function(t){var n=this;return $t((function(){var i;return Zt(this,(function(e){switch(e.label){case 0:if(n.MT=new fu,n.kT(),!n.AT)return[2,J.resolve()];if(0===(i=Jo(t)).byteLength)throw new m("Cannot call update with an empty response.");return n.AT.update(i),[4,n.MT.Gb];case 1:return e.sent(),[2]}}))}))()},i.Ws=function(){return!this.$S&&this.AT&&(this.$S=!0,this.AT.close()),this.ST.Gb},i.iT=function(){var t=this;return $t((function(){return Zt(this,(function(n){return t.kT(),[2]}))}))()},i.kT=function(){if(this.$S)throw new m("Already closing or closed.")},i.NT=function(t){this.TT.Vb(),this.TT.Ob(uu,t),this._o(new No(this.TT))},Tt(n,[{key:"JS",get:function(){return this.AT&&this.AT.sessionId||""}},{key:"KS",get:function(){return NaN}},{key:"YS",get:function(){return this.ST.Gb}},{key:"wb",get:function(){return this.TT}}]),n}(Eo),Vf=function(){function t(t,n,i){this.IT=t,this.lT=n,this.kd=i;var e=Bf(i)||"video/mp4";this.CT=Df(e)}var n=t.prototype;return n.uT=function(t){var n=this;return $t((function(){return Zt(this,(function(t){return[2,new Wf(n.IT,n.CT)]}))}))()},n.dT=function(t){return J.resolve(!1)},n.kn=function(t){var n=this,i=function(){t.msSetMediaKeys(n.IT),t.removeEventListener("loadedmetadata",i)};return t.readyState>=1?t.msSetMediaKeys(this.IT):t.addEventListener("loadedmetadata",i),J.resolve()},n.fT=function(t){return J.resolve()},n.nr=function(){return J.resolve()},t}(),Hf=function(){function t(t,n){this.rT=t,this.LT=n}var n=t.prototype;return n.mT=function(){return this.LT},n.vT=function(){var t=new h.MSMediaKeys(this.rT);return J.resolve(new Vf(t,this.rT,this.LT))},Tt(t,[{key:"lT",get:function(){return this.rT}}]),t}(),qf=function(){function t(){}return t.prototype.Qw=function(t,n){try{return J.resolve(function(t,n){if(!Xf())throw new m("Unsupported key system "+t);for(var i=0;i<n.length;i++){var e=n[i],r=Cf(jf,Ro,t,e);if(r)return new Hf(t,r)}throw new m("Unsupported key system configuration for "+t)}(t,n))}catch(t){return J.reject(t)}},t.bT=function(){return Xf()},t}();function Xf(){return void 0!==h.MSMediaKeys&&"function"==typeof h.MSMediaKeys.isTypeSupported}function jf(t,n){return h.MSMediaKeys.isTypeSupported(t,n)}x(),gt(),x(),gt(),x(),gt(),x(),gt();var Yf=function(t){function n(n,i,e){var r;return(r=t.call(this)||this).VT=n,r.CT=i,r.FT=e,r.ST=new fu,r.UT=void 0,r.TT=new su,r.BT=void 0,r.WT=new fu,r.Ss=function(){var t=r.BT&&r.BT.error;if(t){var n=new au("Unknown CDM error",t.code,t.systemCode);r.UT?(r.UT.Ub(n),r.UT=void 0):n.Zb===WebKitMediaKeyError.MEDIA_KEYERR_OUTPUT?r.NT("output-not-allowed"):r.NT("internal-error"),r._o(new Ao)}},r.PT=function(t){r._o(new Po(r,"license-request",Qo(t.message).buffer,"this is a test string"===t.destinationURL?void 0:t.destinationURL))},r.DT=function(){r.UT&&(r.UT.Wb(void 0),r.UT=void 0),r.NT("usable")},r}_t(n,t);var i=n.prototype;return i.eT=function(t,n,i){var e=i&&i.fairplay&&i.fairplay.OT;if(!e)throw new m("Expected FairPlay contentId to be defined but was "+e+".");var r=function(t,n,i){var e=Ko(t),r=2*e.length,o=2*n.length,u=new ArrayBuffer(4+r+4+o+4+i.byteLength),s=new DataView(u),f=new tu;return Xo(s,f,r,!0),jo(s,f,e,!0),Xo(s,f,o,!0),jo(s,f,n,!0),Xo(s,f,i.byteLength,!0),function(t,n,i){Zo(t).set(Zo(i),n.nc),n.Ib(i.byteLength)}(s,f,i),new E(u)}(Jo(n),e,this.FT);return this.BT=this.VT.createSession(this.CT,r),this.BT.addEventListener("webkitkeymessage",this.PT,!1),this.BT.addEventListener("webkitkeyadded",this.DT,!1),this.BT.addEventListener("webkitkeyerror",this.Ss,!1),this.NT("status-pending"),this.WT.Wb(this.BT),this.WT=new fu,J.resolve()},i.$n=function(t){return J.resolve(!0)},i.ir=function(t){var n=this;return $t((function(){var i,e;return Zt(this,(function(r){switch(r.label){case 0:if(0===(i=Jo(t)).byteLength)throw new m("Cannot call update with an empty response.");return n.UT=new fu,(e=n.BT)?[3,2]:[4,n.WT.Gb];case 1:e=r.sent(),r.label=2;case 2:return e.update(i),[4,n.UT.Gb];case 3:return r.sent(),[2]}}))}))()},i.Ws=function(){var t,n=this.BT;return n&&(n.removeEventListener("webkitkeymessage",this.PT,!1),n.removeEventListener("webkitkeyadded",this.DT,!1),n.removeEventListener("webkitkeyerror",this.Ss,!1),n.close()),this.WT.np(),null==(t=this.UT)||t.np(),this.ST.Wb(void 0),this.ST.Gb},i.iT=function(){return J.resolve(void 0)},i.NT=function(t){this.TT.Vb(),this.TT.Ob(uu,t),this._o(new No(this.TT))},Tt(n,[{key:"JS",get:function(){return this.BT?this.BT.sessionId:""}},{key:"KS",get:function(){return NaN}},{key:"YS",get:function(){return this.ST.Gb}},{key:"wb",get:function(){return this.TT}}]),n}(Eo);x(),gt(),x(),gt();var Kf=function(t){return t[t.CONFIGURATION_ERROR=1e3]="CONFIGURATION_ERROR",t[t.LICENSE_ERROR=2e3]="LICENSE_ERROR",t[t.LICENSE_INVALID_DOMAIN=2001]="LICENSE_INVALID_DOMAIN",t[t.LICENSE_INVALID_SOURCE=2002]="LICENSE_INVALID_SOURCE",t[t.LICENSE_EXPIRED=2003]="LICENSE_EXPIRED",t[t.LICENSE_INVALID_FEATURE=2004]="LICENSE_INVALID_FEATURE",t[t.SOURCE_INVALID=3e3]="SOURCE_INVALID",t[t.SOURCE_NOT_SUPPORTED=3001]="SOURCE_NOT_SUPPORTED",t[t.MANIFEST_LOAD_ERROR=4e3]="MANIFEST_LOAD_ERROR",t[t.MANIFEST_CORS_ERROR=4001]="MANIFEST_CORS_ERROR",t[t.MANIFEST_PARSE_ERROR=4002]="MANIFEST_PARSE_ERROR",t[t.MEDIA_NOT_SUPPORTED=5e3]="MEDIA_NOT_SUPPORTED",t[t.MEDIA_LOAD_ERROR=5001]="MEDIA_LOAD_ERROR",t[t.MEDIA_DECODE_ERROR=5002]="MEDIA_DECODE_ERROR",t[t.MEDIA_AVPLAYER_ERROR=5003]="MEDIA_AVPLAYER_ERROR",t[t.MEDIA_ABORTED=5004]="MEDIA_ABORTED",t[t.NETWORK_ERROR=6e3]="NETWORK_ERROR",t[t.NETWORK_TIMEOUT=6001]="NETWORK_TIMEOUT",t[t.CONTENT_PROTECTION_ERROR=7e3]="CONTENT_PROTECTION_ERROR",t[t.CONTENT_PROTECTION_NOT_SUPPORTED=7001]="CONTENT_PROTECTION_NOT_SUPPORTED",t[t.CONTENT_PROTECTION_CONFIGURATION_MISSING=7002]="CONTENT_PROTECTION_CONFIGURATION_MISSING",t[t.CONTENT_PROTECTION_CONFIGURATION_INVALID=7003]="CONTENT_PROTECTION_CONFIGURATION_INVALID",t[t.CONTENT_PROTECTION_INITIALIZATION_INVALID=7004]="CONTENT_PROTECTION_INITIALIZATION_INVALID",t[t.CONTENT_PROTECTION_CERTIFICATE_ERROR=7005]="CONTENT_PROTECTION_CERTIFICATE_ERROR",t[t.CONTENT_PROTECTION_CERTIFICATE_INVALID=7006]="CONTENT_PROTECTION_CERTIFICATE_INVALID",t[t.CONTENT_PROTECTION_LICENSE_ERROR=7007]="CONTENT_PROTECTION_LICENSE_ERROR",t[t.CONTENT_PROTECTION_LICENSE_INVALID=7008]="CONTENT_PROTECTION_LICENSE_INVALID",t[t.CONTENT_PROTECTION_KEY_EXPIRED=7009]="CONTENT_PROTECTION_KEY_EXPIRED",t[t.CONTENT_PROTECTION_KEY_MISSING=7010]="CONTENT_PROTECTION_KEY_MISSING",t[t.CONTENT_PROTECTION_OUTPUT_RESTRICTED=7011]="CONTENT_PROTECTION_OUTPUT_RESTRICTED",t[t.CONTENT_PROTECTION_INTERNAL_ERROR=7012]="CONTENT_PROTECTION_INTERNAL_ERROR",t[t.SUBTITLE_LOAD_ERROR=8e3]="SUBTITLE_LOAD_ERROR",t[t.SUBTITLE_CORS_ERROR=8001]="SUBTITLE_CORS_ERROR",t[t.SUBTITLE_PARSE_ERROR=8002]="SUBTITLE_PARSE_ERROR",t[t.VR_PLATFORM_UNSUPPORTED=9e3]="VR_PLATFORM_UNSUPPORTED",t[t.VR_PRESENTATION_ERROR=9001]="VR_PRESENTATION_ERROR",t[t.AD_ERROR=1e4]="AD_ERROR",t[t.AD_BLOCKER_DETECTED=10001]="AD_BLOCKER_DETECTED",t[t.FULLSCREEN_ERROR=11e3]="FULLSCREEN_ERROR",t[t.PICTURE_IN_PICTURE_ERROR=11001]="PICTURE_IN_PICTURE_ERROR",t[t.CACHE_SOURCE_ERROR=12e3]="CACHE_SOURCE_ERROR",t[t.CACHE_CONTENT_PROTECTION_ERROR=12001]="CACHE_CONTENT_PROTECTION_ERROR",t[t.THEO_LIVE_UNKNOWN_ERROR=13e3]="THEO_LIVE_UNKNOWN_ERROR",t[t.THEO_LIVE_CHANNEL_NOT_FOUND=13001]="THEO_LIVE_CHANNEL_NOT_FOUND",t[t.THEO_LIVE_END_OF_DEMO=13002]="THEO_LIVE_END_OF_DEMO",t[t.THEO_LIVE_ANALYTICS_ERROR=13003]="THEO_LIVE_ANALYTICS_ERROR",t}({}),Gf=function(t){return t[t.CONFIGURATION=1]="CONFIGURATION",t[t.LICENSE=2]="LICENSE",t[t.SOURCE=3]="SOURCE",t[t.MANIFEST=4]="MANIFEST",t[t.MEDIA=5]="MEDIA",t[t.NETWORK=6]="NETWORK",t[t.CONTENT_PROTECTION=7]="CONTENT_PROTECTION",t[t.SUBTITLE=8]="SUBTITLE",t[t.VR=9]="VR",t[t.AD=10]="AD",t[t.FULLSCREEN=11]="FULLSCREEN",t[t.CACHE=12]="CACHE",t[t.THEOLIVE=13]="THEOLIVE",t}({});!function(t){t.fromCode=function(n){var i=y.floor(n/1e3);if(i in t)return i;throw new m("Invalid error code: "+n)}}(Gf||(Gf={}));var $f=function(t){function n(n,i,e){var r;return(r=t.call(this,i,e)||this).code=n,r}return _t(n,t),Tt(n,[{key:"name",get:function(){return"THEOplayerError"}},{key:"category",get:function(){return Gf.fromCode(this.code)}}]),n}(dn),Zf=function(){function t(t,n,i){this.VT=t,this.lT=n,this.kd=i,this.FT=void 0;var e=Bf(i)||"video/mp4";this.CT=Df(e)}var n=t.prototype;return n.getInternalMediaKeys=function(){return this.VT},n.uT=function(t){var n=this;return $t((function(){return Zt(this,(function(t){if(!n.FT)throw new $f(Kf.CONTENT_PROTECTION_CERTIFICATE_ERROR,"No valid certificate was provided.");return[2,new Yf(n.VT,n.CT,n.FT)]}))}))()},n.dT=function(t){return this.FT=Jo(t),J.resolve(!0)},n.kn=function(t){return t.webkitSetMediaKeys(this.VT),J.resolve()},n.fT=function(t){return t.webkitSetMediaKeys(null),J.resolve()},n.nr=function(){return J.resolve()},t}(),Jf=function(){function t(t,n){this.rT=t,this.LT=n}var n=t.prototype;return n.mT=function(){return this.LT},n.vT=function(){var t=new h.WebKitMediaKeys(this.rT);return J.resolve(new Zf(t,this.rT,this.LT))},Tt(t,[{key:"lT",get:function(){return this.rT}}]),t}(),Qf=function(){function t(){}return t.prototype.Qw=function(t,n){try{return J.resolve(function(t,n){if(t!==so)throw new m(t+" is not supported with webkit-prefixed Encrypted Media Extensions.");if(!tc())throw new m("Unsupported key system "+t);for(var i=0;i<n.length;i++){var e=n[i],r=Cf(nc,Oo,t,e);if(r)return new Jf(t,r)}throw new m("Unsupported key system configuration for "+t)}(t,n))}catch(t){return J.reject(t)}},t.bT=function(){return tc()},t}();function tc(){return void 0!==h.WebKitMediaKeys&&"function"==typeof h.WebKitMediaKeys.isTypeSupported}function nc(t,n){return h.WebKitMediaKeys.isTypeSupported(t,n)}x(),gt();var ic=function(){function t(t){this.GT=t}return t.prototype.Qw=function(t,n){var i=this;return $t((function(){var e,r,o;return Zt(this,(function(u){switch(u.label){case 0:e=0,r=i.GT,u.label=1;case 1:if(!(e<r.length))return[3,6];o=r[e],u.label=2;case 2:return u.trys.push([2,4,,5]),[4,o.Qw(t,n)];case 3:return[2,u.sent()];case 4:return u.sent(),[3,5];case 5:return e++,[3,1];case 6:throw new m("Unsupported key system configuration for "+t)}}))}))()},t}();x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt();var ec=function(){function t(t){var n=this;this.HT=[],this.XT=void 0,this.ZT=new an,this.zT=function(){return 0===n.HT.length?n.YT?rc(n.YT,n.ZT.ep).then(n.KT,n.KT):n.KT():n.HT.shift()().then(n.zT)},this.KT=function(){if(0!==n.HT.length)return n.zT();n.XT=void 0},this.YT=t}var n=t.prototype;return n.Qo=function(t,n){var i=this;return new J((function(e){var r=an.hp([i.ZT.ep,n]),o=function(){r.Km()};i.HT.push((function(){var n=rc(t,r.ep);return e(n),n.then(o,o)})),i.XT||(i.XT=i.zT())}))},n.np=function(){return this.qT(!0)},n.yn=function(){return this.YT=void 0,this.qT(!1)},n.qT=function(t){var n=this.XT;return this.ZT.np(),t&&(this.ZT=new an),J.resolve(n)},t}();function rc(t,n){return new J((function(i){return i(t(n))}))}var oc=new ec,uc=function(t){function n(n){var i;return(i=t.call(this)||this).rT=n,i.ET=void 0,i.UT=void 0,i.tA=!1,i.ck=void 0,i.ek=void 0,i.ST=new fu,i.hk="",i.nk=new fu,i.rk=new su,i}_t(n,t);var i=n.prototype;return i.jT=function(){this.UT&&(this.NT("usable"),this.UT.Wb(void 0),this.UT=void 0)},i.QT=function(t){var n=new au("Unknown CDM error",t.errorCode,t.systemCode);this.UT?(this.UT.Ub(n),this.UT=void 0):this.ET?(this.ET.Ub(n),this.ET=void 0):n.Zb===WebKitMediaKeyError.MEDIA_KEYERR_OUTPUT?this.NT("output-restricted"):1===n.Hb?this.NT("expired"):this.NT("internal-error")},i.JT=function(t){0!==t.message.byteLength?(this.ET&&(this.ET.Wb(void 0),this.ET=void 0),this._o(new Po(this,"license-request",cu(this.rT,Qo(t.message).buffer),t.defaultURL||void 0))):this.ET&&(this.ET.Ub("Empty key message"),this.ET=void 0)},i.$T=function(t){this.ek||(this.ek=t,this.nk.Wb(t))},i.Ws=function(){var t=this;return $t((function(){return Zt(this,(function(n){return t.throwIfClosed(),t.UT&&(t.UT.Ub(void 0),t.UT=void 0),t.tA=!0,t.ST.Wb(void 0),[2]}))}))()},i.eT=function(t,n){var i=this;return $t((function(){var t;return Zt(this,(function(e){switch(e.label){case 0:return i.throwIfClosed(),i.ET=new fu,i.ck=Jo(n),(t=i.ek)?[3,2]:[4,i.nk.Gb];case 1:t=e.sent(),e.label=2;case 2:return t.webkitGenerateKeyRequest(i.rT,i.ck),[4,i.ET.Gb];case 3:return e.sent(),[2]}}))}))()},i.$n=function(t){var n=this;return $t((function(){return Zt(this,(function(t){return n.throwIfClosed(),[2,!1]}))}))()},i.iT=function(){var t=this;return $t((function(){return Zt(this,(function(n){return t.throwIfClosed(),[2]}))}))()},i.ir=function(t){var n=this;return $t((function(){return Zt(this,(function(i){switch(i.label){case 0:return n.throwIfClosed(),n.UT=new fu,Ut.Ng||Ut.Rg?[2,oc.Qo($t((function(){return Zt(this,(function(i){switch(i.label){case 0:return[4,n.doUpdate(t)];case 1:return i.sent(),[2]}}))})))]:[4,n.doUpdate(t)];case 1:return i.sent(),[2]}}))}))()},i.doUpdate=function(t){var n=this;return $t((function(){var i;return Zt(this,(function(e){switch(e.label){case 0:return void 0===n.UT?[2]:(i=n.ek)?[3,2]:[4,n.nk.Gb];case 1:i=e.sent(),e.label=2;case 2:return i.webkitAddKey(n.rT,Jo(t),n.ck,n.JS),[4,n.UT.Gb];case 3:return e.sent(),Ut.Rg?[4,pn(500)]:[3,5];case 4:e.sent(),e.label=5;case 5:return[2]}}))}))()},i.throwIfClosed=function(){if(this.tA)throw new m("Already closing or closed.")},i.NT=function(t){this.rk.Vb(),this.rk.Ob(uu,t),this._o(new No(this.rk))},i.lk=function(){var t=this;return $t((function(){var n,i;return Zt(this,(function(e){switch(e.label){case 0:return(i=t.ek)?[3,2]:[4,t.nk.Gb];case 1:i=e.sent(),e.label=2;case 2:if(!(n=i).webkitCancelKeyRequest)return[3,7];e.label=3;case 3:return e.trys.push([3,4,5,7]),n.webkitCancelKeyRequest(t.rT,t.hk),[3,7];case 4:return e.sent(),[3,7];case 5:return[4,pn(500)];case 6:return e.sent(),[7];case 7:return[2]}}))}))()},Tt(n,[{key:"wb",get:function(){return this.rk}},{key:"JS",get:function(){return this.hk},set:function(t){this.hk=t}},{key:"YS",get:function(){return this.ST.Gb}},{key:"KS",get:function(){return NaN}}]),n}(Eo),sc=function(){function t(t,n){var i=this;this.lT=t,this.kd=n,this.ek=void 0,this._k=Yr(),this.vk=[],this.DT=function(t){var n=i.gk(t.sessionId);n&&n.jT()},this.dk=function(t){var n=i.gk(t.sessionId);n&&n.QT(t)},this.fk=function(t){var n=i.gk(t.sessionId);n&&n.JT(t)}}var n=t.prototype;return n.kn=function(t){return this.ek=t,this.ek.addEventListener("webkitkeyadded",this.DT),this.ek.addEventListener("webkitkeyerror",this.dk),this.ek.addEventListener("webkitkeymessage",this.fk),this._k.forEach((function(n,i){return n.$T(t)})),this.vk.forEach((function(n){return n.$T(t)})),J.resolve()},n.fT=function(t){return t.removeEventListener("webkitkeyadded",this.DT),t.removeEventListener("webkitkeyerror",this.dk),t.removeEventListener("webkitkeymessage",this.fk),this.ek=void 0,J.resolve()},n.nr=function(){var t=this;return $t((function(){var n,i;return Zt(this,(function(e){switch(e.label){case 0:n=t._k.entries(),i=n.next(),e.label=1;case 1:return i.done?[3,3]:[4,i.value[1].lk()];case 2:return e.sent(),i=n.next(),[3,1];case 3:return t._k.clear(),[2]}}))}))()},n.uT=function(t,n,i){var e=this;return $t((function(){var t;return Zt(this,(function(n){return t=new uc(e.lT),e.ek&&t.$T(e.ek),e.vk.push(t),[2,t]}))}))()},n.dT=function(t){return J.resolve(!1)},n.gk=function(t){if(t){var n=this._k.get(t);return n||((n=this.vk.shift())?(n.JS=t,this._k.set(t,n),n):void 0)}},t}(),fc=function(){function t(t,n){this.lT=t,this.pk=n}var n=t.prototype;return n.vT=function(){return J.resolve(new sc(this.lT,this.pk))},n.mT=function(){return this.pk},t}(),cc=function(){function t(){}return t.prototype.Qw=function(t,n){try{return J.resolve(function(t,n){if(!cc.bT())throw new m("Unsupported key system "+t);for(var i=0;i<n.length;i++){var e=n[i],r=Cf(hc,Ro,t,e);if(r)return new fc(t,r)}throw new m("Unsupported key system configuration for "+t)}(t,n))}catch(t){return J.reject(t)}},t.bT=function(){return"undefined"!=typeof HTMLMediaElement&&void 0!==HTMLMediaElement.prototype.webkitGenerateKeyRequest&&void 0!==HTMLMediaElement.prototype.webkitAddKey&&void 0!==HTMLMediaElement.prototype.webkitCancelKeyRequest},t}();function hc(t,n){var i=_n();return Boolean(i&&i.canPlayType&&""!==i.canPlayType(n,t))}x(),gt();var ac,vc=function(){function t(){}return t.prototype.Qw=function(t,n){return t===no||t===Jr?J.resolve(void 0):J.reject(new g("DRM configuration not supported"))},t}();function dc(){return ac||(ac=function(){var t=[];Qf.bT()&&t.push(new Qf);zf.bT()&&t.push(new zf);qf.bT()&&t.push(new qf);cc.bT()&&t.push(new cc);Ut.Lg&&t.push(new vc);return new ic(t)}()),ac}x(),gt(),x(),gt();var lc=function(){function t(){this.wk=Yr()}var n=t.prototype;return n.Vb=function(t){this.wk.delete(t)},n.yk=function(){this.wk.clear()},n.Bb=function(t){return this.wk.get(t)},n.Ob=function(t,n){this.wk.set(t,n)},t}(),wc=function(){function t(){}return t.bk=function(){return t.Vm||(t.Vm=bc.bT()?new bc:new lc),t.Vm},t.Vb=function(n){t.bk().Vb(n)},t.yk=function(){t.bk().yk()},t.Bb=function(n){return t.bk().Bb(n)},t.Ob=function(n,i){t.bk().Ob(n,i)},t}();wc.Vm=void 0;var bc=function(t){function n(){return t.apply(this,arguments)||this}_t(n,t);var i=n.prototype;return i.Vb=function(t){self.sessionStorage.removeItem(t)},i.yk=function(){self.sessionStorage.clear()},i.Bb=function(t){var n;return null!=(n=self.sessionStorage.getItem(t))?n:void 0},i.Ob=function(t,n){self.sessionStorage.setItem(t,n)},n.bT=function(){var t="foobar";try{return self.sessionStorage.setItem(t,t),self.sessionStorage.removeItem(t),!0}catch(t){return!1}},n}(wc);x(),gt(),x(),gt();var gc=function(){var t=self.Blob;if(t)try{new t;return function(t){return function(n,i){return new t(n,i)}}(t)}catch(t){}var n=self.BlobBuilder||self.WebKitBlobBuilder||self.MozBlobBuilder||self.MSBlobBuilder;if(n)return function(t){return function(n,i){var e=new t;if(n)for(var r=0;r<n.length;r++){var o=n[r];e.append(o)}return e.getBlob(i&&i.type||"")}}(n)}();function mc(t,n,i){var e=gc([n],{type:"application/octet-stream"}),r=URL.createObjectURL(e),o=function(t,n){var i=t,e=i.indexOf("?");if(e>=0&&(i=i.substr(0,e)),i=i.substr(i.lastIndexOf("/")+1),n){var r=i.indexOf(".");r<0&&(r=i.length),i=i.substr(0,r)+n+i.substr(r)}return i}(t,i),u=a.createElement("a");u.href=r,u.download=o,a.body.appendChild(u),u.click(),a.body.removeChild(u),URL.revokeObjectURL(r)}x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt(),x(),gt();var pc=function(t,n,i){return i=null!=t?k(P(t)):{},function(t,n,i,e){if(n&&"object"==typeof n||"function"==typeof n)for(var r,o=N(n),u=0,s=o.length;u<s;u++)r=o[u],A.call(t,r)||r===i||R(t,r,{get:function(t){return n[t]}.bind(null,r),enumerable:!(e=O(n,r))||e.enumerable});return t}(!n&&t&&t.__esModule?i:R(i,"default",{value:t,enumerable:!0}),t)}(pt());x(),gt();var yc=t,_c=Xt(yc.ReadableStream)&&Xt(yc.WritableStream)&&Xt(yc.TransformStream)&&qt(yc.ReadableStream.prototype.pipeThrough)&&!ri.Cp,Sc=_c?yc.ReadableStream:pc.ReadableStream,Tc=(_c?yc.WritableStream:pc.WritableStream,_c?yc.TransformStream:pc.TransformStream);_c&&yc.ByteLengthQueuingStrategy?yc.ByteLengthQueuingStrategy:pc.ByteLengthQueuingStrategy,_c&&yc.CountQueuingStrategy?yc.CountQueuingStrategy:pc.CountQueuingStrategy;function Ec(t){return function(t){return new Sc({start:function(n){for(var i=0;i<t.length;i++){var e=t[i];n.enqueue(e)}n.close()}})}([t])}function Ic(t){return Ec(function(t){return new E(t)}(t))}function kc(t,n){return function(t,n){var i=n,e=t.getReader(),r=new fu,o=function(){u();var t=new ln;e.cancel(t).catch(Yt),r.Ub(t)},u=function(){i&&(i.Jm(o),i=void 0)};i&&(i.zm?o():i.Qm(o));var s=[],f=function(t){return t.done?(u(),J.resolve(s)):(s.push(t.value),J.resolve(e.read()).then(f))};return J.resolve(e.read()).then(f).then((function(t){u(),r.Wb(t)}),(function(t){u(),r.Ub(t)})),r.Gb}(t,n).then((function(t){return ru(t).buffer}))}function Rc(t,n){var i=n,e=new Tc,r=e.readable,o=e.writable,u=o.getWriter(),s=function(){i&&i.np()};return u.closed.then(s,s),t.then((function(t){return i=void 0,u.releaseLock(),t.pipeTo(o).catch(Yt)}),(function(t){return i=void 0,u.releaseLock(),o.abort(t).catch(Yt)})),r}function Oc(t){return Ko(new E(t))}function Nc(t){return Go(t).buffer}x(),gt();var Pc="content-type",Ac="text/plain;charset=UTF-8",Dc=function(){function t(){}var n=t.prototype;return n.Ck=function(t){return this.Pk(t).then(JSON.parse)},n.Dk=function(t,n){switch(t){case Ar.Ak:return this.Nk(n);case Ar.Sk:return this.Ck(n);case Ar.Tk:return this.Mk();case Ar.Ek:return this.Pk(n);default:throw new m}},t}();function Cc(t,n,i){if(t instanceof Dc)return t;if(t instanceof Sc)return function(t,n){return new Bc({Hw:0,Mk:t,Lk:xc(n)})}(t,i);var e=xc(i),r=J.resolve(t).then((function(t){return function(t,n){if(t){if("string"==typeof t)return{Hw:Ar.Ek,Bk:t,Lk:n||Ac};if(t instanceof ArrayBuffer||iu(t))return{Hw:Ar.Ak,Bk:Vc(t),Lk:n};if(function(t){return Ht(t)&&t.constructor&&t.constructor===p}(t)||Vt(t))return{Hw:Ar.Sk,Bk:t,Lk:n};throw new m("Unsupported BodyInit type")}return{Hw:Ar.Ek,Bk:null,Lk:n}}(t,e)}));return new Bc({Hw:1,Gb:r,Ok:n})}function xc(t){return(t.get(Pc)||"").toLowerCase()}var Bc=function(t){function n(n){var i;return(i=t.call(this)||this).Vk=!1,i.Zk=new fu,i.Zk.Gb.catch(Yt),i.zk(n),i}_t(n,t);var i=n.prototype;return i.Gk=function(){return this.Zk.Gb},i.Pk=function(t){return this.Hk(Mc,t)},i.Ck=function(t){return this.Hk(Uc,t)},i.Nk=function(t){return this.Hk(zc,t)},i.Mk=function(){return this.Xk(function(t){return 0===t.Hw?t.Mk:Rc(t.Gb.then(Wc).then(Ic),t.Ok)}(this.Uk))},i.Hk=function(t,n){if(this.Vk)return J.reject(new m("Already used"));this.Vk=!0;var i=t(this.Uk,n);return this.Zk.rp(i.then(Yt)),i},i.Xk=function(t){if(this.Vk)throw new m("Already used");if(t.locked)throw new m("Body stream is locked");this.Vk=!0;var n=new Tc,i=J.resolve(t.pipeTo(n.writable));return this.Zk.rp(i),n.readable},i.zk=function(t){this.Uk=t,1===t.Hw&&t.Gb.catch(Yt)},i.qk=function(){if(this.Vk)throw new m("Already used");var t=function(t){if(0===t.Hw){var n=Dr(t.Mk.tee(),2),i=n[0],e=n[1];return[{Hw:t.Hw,Mk:i,Lk:t.Lk},{Hw:t.Hw,Mk:e,Lk:t.Lk}]}var r=Dr(t.Ok.op(),2),o=r[0],u=r[1];return[{Hw:t.Hw,Gb:t.Gb,Ok:o},{Hw:t.Hw,Gb:t.Gb,Ok:u}]}(this.Uk),i=t[0],e=t[1];return this.zk(i),new n(e)},Tt(n,[{key:"Fk",get:function(){return this.Vk}},{key:"Wk",get:function(){return 0===this.Uk.Hw}}]),n}(Dc);function Mc(t,n){return 0===t.Hw?kc(t.Mk,n).then(Oc):(n&&t.Ok.rp(n),gn(t.Gb.then(Lc),t.Ok))}function Lc(t){switch(t.Hw){case Ar.Ek:return J.resolve(t.Bk||"");case Ar.Ak:return J.resolve(t.Bk).then(Oc);case Ar.Sk:return J.resolve(t.Bk).then(JSON.stringify)}}function Uc(t,n){return 0===t.Hw?Mc(t,n).then(JSON.parse):(n&&t.Ok.rp(n),gn(t.Gb.then(Fc),t.Ok))}function Fc(t){return t.Hw===Ar.Sk?J.resolve(t.Bk):Lc(t).then(JSON.parse)}function zc(t,n){return 0===t.Hw?kc(t.Mk,n):(n&&t.Ok.rp(n),gn(t.Gb.then(Wc),t.Ok))}function Wc(t){switch(t.Hw){case Ar.Ak:return J.resolve(t.Bk);case Ar.Ek:case Ar.Sk:return Lc(t).then(Nc)}}function Vc(t){return t instanceof ArrayBuffer?t:Qo(Zo(t)).buffer}var Hc=function(t){function n(n){var i;return(i=t.call(this)||this).Yk=n,i}_t(n,t);var i=n.prototype;return i.Gk=function(){return this.Yk.Gk()},i.Pk=function(t){return this.Yk.Pk(t)},i.Ck=function(t){return this.Yk.Ck(t)},i.Nk=function(t){return this.Yk.Nk(t)},i.Mk=function(t){return this.Yk.Mk(t)},i.qk=function(){return this.Yk.qk()},Tt(n,[{key:"Fk",get:function(){return this.Yk.Fk}},{key:"Wk",get:function(){return this.Yk.Wk}}]),n}(Dc);var qc=function(t){function n(n,i){var e,r,o,u,s,f;i?(r=i.$k,o=i.Qk,u=i.Kk,s=i.tE,f=i.eE):(r=[],o=Ar.Ek,u=200,s="OK",f=!1);var c=n.Jk,h=new Cr(n.$k||r),a=n.Qk||o,v=n.iE||(i&&i.Jk===c?i.iE:c.Xu),d=i?i.Yk:null,l=Cc(void 0!==n.jk?n.jk:d,n.Ok||new an,h);return(e=t.call(this,l)||this).$k=h,e.Jk=c,e.iE=v,e.Qk=a,e.Kk=void 0!==n.Kk?n.Kk:u,e.tE=void 0!==n.tE?String(n.tE):s,e.eE=n.eE||f,e}_t(n,t);var i=n.prototype;return i.jk=function(t){return this.Dk(this.Qk,t)},i.Cb=function(){return new n({jk:this.qk(),Jk:this.Jk},this)},n}(Hc),Xc=function(){function t(){}var n=t.prototype;return n.Jk=function(t){var n=function(t){return new qc({jk:null,$k:{},Jk:t,iE:t.Xu,Qk:t.Qk,Kk:0,tE:ko.Xy})}(new Ur(t));return J.resolve(n)},n.LE=function(t){},n.yn=function(){},t}();var jc=function(){function t(t,n){void 0===n&&(n=!0),this.VE=t,this.UE=n}var n=t.prototype;return n.Jk=function(t){var n=this.FE(t);return this.VE.Jk(n)},n.LE=function(t){return this.VE.LE(this.WE(t))},n.FE=function(n){var i=new Ur(n);if(!this.UE){var e=t.GE(i.Xu);i=new Ur({Xu:e},i)}return i},n.WE=function(n){var i=n.Xu;return this.UE||(i=t.GE(i)),{Xu:i,Bk:n.Bk}},n.yn=function(){this.VE.yn()},t.GE=function(t){return Wt.Cw&&lo(t,"http://")?t.replace(":","s:"):t},Tt(t,null,[{key:"BE",get:function(){return t.OE||(t.OE=new t(new Xc)),t.OE}}]),t}();jc.OE=void 0,x(),gt(),x(),gt(),x(),gt(),x(),gt();var Yc=function(t){function n(n,i,e){var r;return(r=t.call(this,n.Jk,null!=e?e:function(t){return"Error while loading "+t.Jk.Xu+", status code "+t.Kk}(n),i)||this).YE=n,r}return _t(n,t),Tt(n,[{key:"name",get:function(){return Fr.HE}},{key:"qE",get:function(){return this.YE}}]),n}(zr);x(),gt();var Kc=function(t){function n(n,i){return t.call(this,n,function(t){return"Request for "+t.Xu+" timed out after "+t.TE+" seconds."}(n),i)||this}return _t(n,t),Tt(n,[{key:"name",get:function(){return Fr.XE}}]),n}(zr);x(),gt();var Gc=self.fetch,$c=self.Request,Zc=self.Response,Jc=self.Headers,Qc=self.ReadableStream,th=self.AbortSignal,nh=self.AbortController,ih=Kt((function(){try{return qt(Gc)&&Xt($c)&&Xt(Zc)&&Xt(Jc)&&"forEach"in Jc.prototype&&kr()}catch(t){return!1}})),eh=["http:","https:"];var rh=Kt((function(){try{return ih()&&Xt(th)&&Xt(nh)&&"signal"in $c.prototype}catch(t){return!1}})),oh=Kt((function(){try{return ih()&&Xt(Qc)&&"body"in Zc.prototype&&!Ut.hg}catch(t){return!1}}));function uh(t,n){var i,e=t.$k.has("content-length")?Number(t.$k.get("content-length")):void 0;return i=t.Wk?function(t,n,i){return t.pipeThrough(new Tc(new sh(n,i)))}(t.Mk(),n,e):function(t,n,i){return fh.apply(this,arguments)}(t.Nk(),n,e),new qc({jk:i,Jk:t.Jk},t)}x(),gt(),x(),gt();var sh=function(){function t(t,n){this.jE=t,this.QE=n,this.KE=0}var n=t.prototype;return n.transform=function(t,n){this.KE+=t.byteLength,this.jE(this.KE,this.QE),n.enqueue(t)},n.flush=function(t){var n;this.jE(this.KE,null!=(n=this.QE)?n:this.KE)},t}();function fh(){return fh=$t((function(t,n,i){var e,r;return Zt(this,(function(o){switch(o.label){case 0:return[4,J.resolve()];case 1:return o.sent(),n(0,i),[4,t];case 2:return e=o.sent(),r=e.byteLength,n(r,null!=i?i:r),[2,e]}}))})),fh.apply(this,arguments)}var ch=function(){function t(t){this.ZT=new an,this.YE=void 0,this.$E=0,this.tx=!1,this.zE=t,this.ZT.rp(t.ep),this.qE=this.JE()}var n=t.prototype;return n.JE=function(){var t=this;return $t((function(){var n,i,e,r,o,u,s,f,c;return Zt(this,(function(h){switch(h.label){case 0:(n=t.zE).TE&&(t.$E=d((function(){t.tx=!0,t.ZT.np()}),n.TE),t.ZT.ep.$m((function(){l(t.$E)})));try{i=Gc(n.Xu,{method:n.SE,headers:n.$k.xk(),body:n.Bk,credentials:n.RE?"include":"same-origin",signal:vh(t.ZT.ep),mode:n.PE,keepalive:n.NE})}catch(t){throw new Wr(n,t)}h.label=1;case 1:return h.trys.push([1,3,,4]),[4,i];case 2:return e=h.sent(),[3,4];case 3:throw r=h.sent(),wn(o=t.ix(r))&&t.ZT.np(),o;case 4:if(u=e.url||n.Xu,s=0===e.status&&"file:"===function(t){return Wt.Bh(t).protocol}(u)?200:e.status,f=new hh(t,e,t.ZT),!function(t){return t.Kk>=200&&t.Kk<=299||304===t.Kk}(c=new qc({jk:f,Jk:n,Qk:n.Qk,$k:dh(e.headers),Kk:s,tE:e.statusText,iE:u})))throw new Yc(c);return n.CE&&(c=uh(c,n.CE)),[2,c]}}))}))()},n.ix=function(t){return function(t){return t instanceof zr}(t)?t:wn(t)?this.tx?new Kc(this.zE):new ln(t.message,t):this.YE?new Yc(this.YE,t):new Wr(this.zE,t)},t}(),hh=function(t){function n(n,i,e){var r;return(r=t.call(this)||this).Zk=new fu,r.nx=n,r.sx=i,r.ZT=e,r.Zk.Gb.catch(Yt),r}_t(n,t);var i=n.prototype;return i.Gk=function(){return this.Zk.Gb},i.Pk=function(t){return this.Hk(this.sx.text(),t)},i.Nk=function(t){return this.Hk(this.sx.arrayBuffer(),t)},i.Mk=function(){var t=this.sx.body;return t?this.Xk(t):Rc(this.Nk().then(Ic),this.ZT)},i.qk=function(){var t=this.sx.clone(),i=Dr(this.ZT.op(),2),e=i[0],r=i[1];return this.ZT=e,new n(this.nx,t,r)},i.Hk=function(t,n){var i=this;n&&this.ZT.rp(n);var e=bn(J.resolve(t),this.ZT.ep).catch((function(t){throw i.nx.ix(t)}));return e=gn(e,this.ZT),this.Zk.rp(e.then(Yt)),e},i.Xk=function(t){var n=this;return new Sc(new lh(t,(function(t){return n.nx.ix(t)}),this.ZT,this.Zk),{highWaterMark:0})},Tt(n,[{key:"Fk",get:function(){return this.sx.bodyUsed}},{key:"Wk",get:function(){return zt(this.sx.body)}}]),n}(Dc),ah="abort";function vh(t){if(rh()){var n=new nh;if(t.zm)n.abort();else if(!t.qm){var i=function(){e(),n.abort()},e=function(){n.signal.removeEventListener(ah,i),t.Jm(i),t.tp(e)};n.signal.addEventListener(ah,i),t.Qm(i),t.$m(e)}return n.signal}}function dh(t){if(function(t){return Ht(t)&&"function"==typeof t.forEach}(t)){var n=new Cr;return t.forEach((function(t,i){Array.isArray(t)&&2===t.length?n.append(t[0],t[1]):n.append(i,t)})),n}return new Cr(t)}var lh=function(){function t(t,n,i,e){this.ox=t,this.hx=n,this.ZT=i,this.Zk=e}var n=t.prototype;return n.start=function(t){this.Od=this.ox.getReader()},n.pull=function(t){var n=this;return $t((function(){var i,e,r;return Zt(this,(function(o){switch(o.label){case 0:return o.trys.push([0,2,,3]),[4,bn(n.Od.read(),n.ZT.ep)];case 1:return i=o.sent(),[3,3];case 2:return e=o.sent(),r=n.hx(e),n.Zk.Ub(r),n.ZT.np(),n.Od.cancel(r).catch(Yt),t.error(r),[2];case 3:return i.done?(n.Zk.Wb(),n.ZT.np(),t.close()):t.enqueue(i.value),[2]}}))}))()},n.cancel=function(t){return this.ZT.np(),this.Zk.Ub(t),this.Od.cancel(t)},t}();x(),gt();var wh=function(){function t(t){var n=this;this.ZT=new an,this.YE=void 0,this.ux=new fu,this.Ax=!1,this.bx=function(){var t;n._x(),null==(t=n.lx)||t.abort()},this.zE=t,this.ZT.rp(t.ep),this.lx=new I,this.JE()}var n=t.prototype;return n.JE=function(){var t=this,n=this.lx,i=this.zE;if(i.ep.zm)return this._x();n.onreadystatechange=function(){return t.vx()},n.onprogress=function(n){return t.jE(n)},n.onload=function(){return t.gx()},n.onloadend=function(){return t.mx()},n.onerror=function(){return t.wx()},n.ontimeout=function(){return t.yx()},n.onabort=function(){return t._x()},n.open(i.SE,i.Xu,!0),n.withCredentials=Boolean(i.RE),"responseType"in n&&i.Qk&&(i.Qk===Ar.Ek?n.responseType="text":n.responseType="arraybuffer"),i.$k.forEach((function(t,i){n.setRequestHeader(i,t)})),i.TE&&(n.timeout=i.TE),this.ZT.ep.Qm(this.bx);var e=i.Bk;e?n.send(e):n.send()},n.vx=function(){var t=this.lx;void 0!==t&&t.readyState>=2&&!this.Ax&&(this.Ax=!0,this.Sx())},n.Sx=function(){var t,n,i=this.lx,e=function(t){var n=new Cr,i=t.replace(/\r?\n[\t ]+/g," ");return i.split(/\r?\n/).forEach((function(t){var i=t.split(":"),e=i.shift().trim();if(e){var r=i.join(":").trim();n.append(e,r)}})),n}(i.getAllResponseHeaders()||""),r=this.zE;this.Tx=new fu,this.YE=new qc({Jk:r,Qk:r.Qk,jk:this.Tx.Gb,Kk:i.status,tE:i.statusText,$k:e,iE:null!=(n=i.responseURL)?n:e.get("X-Request-URL")}),null==(t=this.ux)||t.Wb(this.YE)},n.gx=function(){var t,n=this.lx;if(void 0!==n){var i=n.response;if(!zt(i)){var e=this.zE.Qk;i=e===Ar.Ek?n.responseText:e===Ar.Ak?new ArrayBuffer(0):{}}null==(t=this.Tx)||t.Wb(i)}},n.mx=function(){this.yn()},n.jE=function(t){void 0!==this.lx&&(null==this.zE.CE||this.zE.CE.call(this.zE,t.loaded,t.lengthComputable?t.total:void 0))},n.wx=function(){var t=new g("Network request failed");this.YE?this.Ss(new Yc(this.YE,t)):this.Ss(new Wr(this.zE,t))},n.yx=function(){this.Ss(new Kc(this.zE))},n._x=function(){this.Ss(new ln),this.yn()},n.Ss=function(t){var n,i;null==(n=null!=(i=this.Tx)?i:this.ux)||n.Ub(t)},n.yn=function(){this.lx=void 0,this.YE=void 0,this.ux=void 0,this.Tx=void 0,this.ZT.Km()},Tt(t,[{key:"qE",get:function(){return this.ux.Gb}}]),t}();x(),gt();var bh=function(){function t(){}var n=t.prototype;return n.Jk=function(t){return function(t){if(!ih()||!function(t){try{return eh.indexOf(new self.URL(t,self.location.href).protocol)>=0}catch(t){return!1}}(t.Xu))return!1;if(!oh()&&t.CE)return!1;if(!t.DE&&t.SE!==Mr.POST){if(Ut.Ng&&Ut.wg<=68)return!1;if(Ut.Rg)return!1}return!0}(t)?new ch(t).qE:new wh(t).qE},n.LE=function(t){var n=h.navigator;if(n&&n.sendBeacon)n.sendBeacon(t.Xu,gc([t.Bk],{type:t.Lk}));else{var i=t.Lk?{"Content-type":t.Lk}:void 0;this.Jk(new Ur({SE:Mr.POST,Xu:t.Xu,Bk:t.Bk,$k:i,PE:Lr.yE})).then((function(t){!function(t){t.then(Yt,Yt)}(t.Nk())}),Yt)}},n.yn=function(){},t}();x(),gt(),x(),gt();var gh=function(t){return t[t.kx=1]="kx",t[t.Ex=2]="Ex",t[t.Ek=3]="Ek",t[t.xx=4]="xx",t[t.Ix=9]="Ix",t}({});var mh=function(){function t(){}return t.prototype.Cx=function(t){var n,i=new DOMParser;try{n=i.parseFromString(t,"text/xml")}catch(t){throw new Hr(t)}if(!n||n.getElementsByTagName("parsererror").length>0)throw new Hr;return new Ih(n)},t}(),ph=function(){function t(t){this.Dx=t}var n=t.prototype;return n.Bx=function(t){return this.Dx.isEqualNode(t.Dx)},n.Ox=function(n){return new t(this.Dx.cloneNode(n))},Tt(t,[{key:"Rx",get:function(){return gh.Ex}},{key:"Px",get:function(){var t;return null!=(t=this.Dx.localName)?t:Oh(this.Dx.nodeName)}},{key:"l",get:function(){return this.Dx.nodeName}},{key:"Nx",get:function(){var t;return null!=(t=this.Dx.namespaceURI)?t:void 0}},{key:"Mx",get:function(){var t;return null!=(t=this.Dx.prefix)?t:void 0}},{key:"Lx",get:function(){return this.Dx.nodeValue}}]),t}(),yh=function(){function t(t){this.Vx=void 0,this.Wx=t}var n=t.prototype;return n.Ux=function(t){return this.Fx.filter((function(n){return kh(n)&&n.Gx===t}))},n.Zx=function(t,n){return this.Fx.filter((function(i){return kh(i)&&i.Px===n&&i.Nx===t}))},n.Xx=function(t){this.Wx.appendChild(t.Hx),this.Vx&&this.Vx.push(t)},n.Bx=function(t){return this.Wx.isEqualNode(t.Hx)},Tt(t,[{key:"Fx",get:function(){return void 0===this.Vx&&(this.Vx=function(t){for(var n=[],i=0;i<t.length;i++){var e=Rh(t.item(i));e&&n.push(e)}return n}(this.Wx.childNodes)),this.Vx}},{key:"m",get:function(){return this.Fx.filter(kh)}},{key:"Hx",get:function(){return this.Wx}}]),t}(),_h=function(t){function n(n){return t.call(this,n)||this}_t(n,t);var i=n.prototype;return i.Yx=function(t){if(this.Wx.hasAttribute(t))return this.Wx.getAttribute(t)},i.Kx=function(t,n){if(this.Wx.hasAttributeNS(t,n))return this.Wx.getAttributeNS(t,n)},i.jx=function(t){this.Wx.removeAttribute(t)},i.Qx=function(t,n){this.Wx.removeAttributeNS(t,n)},i.Jx=function(t,n){this.Wx.setAttribute(t,n)},i.$x=function(t,n,i){this.Wx.setAttributeNS(t,n,i)},i.Ox=function(t){return new n(this.Wx.cloneNode(t))},Tt(n,[{key:"Rx",get:function(){return gh.kx}},{key:"Px",get:function(){var t;return null!=(t=this.Wx.localName)?t:Oh(this.Wx.nodeName)}},{key:"Nx",get:function(){var t;return null!=(t=this.Wx.namespaceURI)?t:void 0}},{key:"Mx",get:function(){var t;return null!=(t=this.Wx.prefix)?t:void 0}},{key:"Gx",get:function(){return this.Wx.nodeName}},{key:"zx",get:function(){return function(t){for(var n=[],i=0;i<t.length;i++)n.push(new ph(t.item(i)));return n}(this.Wx.attributes)}},{key:"qx",get:function(){return this.Wx.textContent}}]),n}(yh),Sh=function(){function t(t){this.Wx=t}return t.prototype.Bx=function(t){return this.jk===t.jk},Tt(t,[{key:"jk",get:function(){return this.Wx.nodeValue}},{key:"Hx",get:function(){return this.Wx}}]),t}(),Th=function(t){function n(n){return t.call(this,n)||this}return _t(n,t),n.prototype.Ox=function(t){return new n(this.Wx.cloneNode(t))},Tt(n,[{key:"Rx",get:function(){return gh.Ek}}]),n}(Sh),Eh=function(t){function n(n){return t.call(this,n)||this}return _t(n,t),n.prototype.Ox=function(t){return new n(this.Wx.cloneNode(t))},Tt(n,[{key:"Rx",get:function(){return gh.xx}}]),n}(Sh),Ih=function(t){function n(n){return t.call(this,n)||this}return _t(n,t),n.prototype.Ox=function(t){return new n(this.Wx.cloneNode(t))},Tt(n,[{key:"Rx",get:function(){return gh.Ix}},{key:"tI",get:function(){return new _h(this.Wx.documentElement)}}]),n}(yh);function kh(t){return function(t){return 1===t.Rx}(t)}function Rh(t){switch(t.nodeType){case gh.kx:return new _h(t);case gh.Ek:return new Th(t);case gh.xx:return new Eh(t)}}function Oh(t){var n=t.indexOf(":");return n<0?t:t.substr(n+1)}var Nh=function(t){function n(){var n;return(n=t.apply(this,arguments)||this).eI=void 0,n.sI=oh(),n.rI=Ut.wm||Ut.hg,n.hI=(Ut.wm||Ut.Ng&&Ut.wg<=68||Ut.hg)&&!(Ut.Rg&&Ut.Pg<3),n.vI=void 0,n.gI=new mh,n}return _t(n,t),n.prototype.Cx=function(t){return this.gI.Cx(t)},Tt(n,[{key:"dw",get:function(){return this.eI||(this.eI=new So(dc())),this.eI}},{key:"iI",get:function(){return this.sI}},{key:"nI",get:function(){return this.rI}},{key:"oI",get:function(){return this.hI}},{key:"aI",get:function(){return!1}},{key:"uI",get:function(){return wc.bk()}},{key:"cI",get:function(){return{lI:mc}}},{key:"dI",get:function(){return v.connection&&v.connection.effectiveType||Nr}},{key:"fI",get:function(){return v.connection&&v.connection.type||Pr}},{key:"_I",get:function(){return this.vI||(this.vI=new jc(new bh)),this.vI}}]),n}(Er);jt(new Nh),x(),gt(),x(),gt();x(),gt(),x(),gt(),x(),gt();var Ph=function(t){return t.gE="audio",t.mE="video",t._W="metadata",t}({});x(),gt(),x(),gt();var Ah=function(t){return t.rE="#EXTINF",t.IBt="#EXT-X-MAP",t.p="#EXTM3U",t.en="#EXT-X-VERSION",t.ui="#EXT-X-TARGETDURATION",t.USt="#EXT-X-START",t.li="#EXT-X-INDEPENDENT-SEGMENTS",t.Tk="#EXT-X-STREAM-INF",t.vr="#EXT-X-MEDIA-SEQUENCE",t.if="#EXT-X-ENDLIST",t.sf="#EXT-X-MEDIA",t.ff="#EXT-X-DISCONTINUITY",t.af="#EXT-X-DISCONTINUITY-SEQUENCE",t.tv="#EXT-X-PLAYLIST-TYPE",t.nv="#EXT-X-KEY",t}({}),Dh=function(){function t(t,n){this.Hw="#EXTINF",this.ev=t,this.sv=n}return t.prototype._P=function(){return this.Hw+":"+this.ev+",\n"+this.sv},t}(),Ch=function(){function t(t){this.Hw="#EXT-X-MAP",this.sv=t}return t.prototype._P=function(){return this.Hw+':URI="'+this.sv+'"'},t}(),xh=function(){function t(){this.Hw="#EXTM3U"}return t.prototype._P=function(){return this.Hw},t}(),Bh=function(){function t(t){this.Hw="#EXT-X-VERSION",this.sN=t}return t.prototype._P=function(){return this.Hw+":"+this.sN},t}(),Mh=function(){function t(t){this.Hw="#EXT-X-TARGETDURATION",this.wBt=t}return t.prototype._P=function(){return this.Hw+":"+this.wBt},t}(),Lh=function(){function t(t){this.Hw="#EXT-X-START",this.yOt=t}return t.prototype._P=function(){return this.Hw+":TIME-OFFSET="+this.yOt},t}(),Uh=function(){function t(t,n,i){this.uri=t,this.keyFormat=n,this.keyFormatVersions=i,this.Hw="#EXT-X-KEY"}return t.prototype._P=function(){return this.Hw+':METHOD=SAMPLE-AES,URI="'+this.uri+'",KEYFORMAT="'+this.keyFormat+'",KEYFORMATVERSIONS="'+this.keyFormatVersions+'"'},t}(),Fh=function(){function t(t){this.Hw="#EXT-X-STREAM-INF",this.FG=1,this.sv=t}return t.prototype._P=function(){return this.Hw+":BANDWIDTH="+this.FG+',AUDIO="audio"\n'+this.sv},t}(),zh=function(){function t(t){this.Hw="#EXT-X-MEDIA-SEQUENCE",this.fL=t}return t.prototype._P=function(){return this.Hw+":"+this.fL},t}(),Wh=function(){function t(t){this.Hw="#EXT-X-MEDIA",this.sv=t}return t.prototype._P=function(){var t=Yr();t.set("TYPE","AUDIO"),t.set("GROUP-ID",'"audio"'),t.set("NAME",'"audio"'),t.set("AUTOSELECT","YES"),t.set("DEFAULT","YES"),t.set("CHANNELS",'"2"'),t.set("URI",'"'+this.sv+'"');var n=[];return t.forEach((function(t,i){return n.push(i+"="+t)})),this.Hw+":"+n.join(",")},t}();x(),gt();var Vh=function(){function t(t){this.wA=[],this.wA=t}var n=t.prototype;return n.YN=function(){return this.wA},n.cv=function(t){this.wA.push(t)},n.qVt=function(){for(var t="",n=0,i=this.YN();n<i.length;n++){t+=i[n]._P()+"\n"}return t},n.Km=function(){this.wA.length=0},t}(),Hh=function(t){function n(n,i){var e;return e=t.call(this,[new xh,new Bh(8)])||this,i&&e.cv(new Fh("video/index.m3u8")),n&&e.cv(new Wh("audio/index.m3u8")),e}return _t(n,t),n}(Vh);x(),gt(),x(),gt(),x(),gt();var qh=function(t){return t.mit="HELLO",t.pit="HI_THERE",t.wit="INITIALIZE",t.yit="APPEND_INIT",t.Ait="APPEND_DATA",t.Sit="ACK",t.Tit="REMOVE",t.kit="DESTROY_SESSION",t}({});x(),gt(),x(),gt();var Xh,jh=new Array(256);for(Xh=0;Xh<256;Xh+=1)jh[Xh]=(Xh<16?"0":"")+Xh.toString(16);function Yh(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(t){var n=16*y.random()|0;return("x"===t?n:3&n|8).toString(16)}))}x(),gt();var Kh=function(t){function n(n){var i;return(i=t.call(this,"append")||this).jk=n,i}return _t(n,t),n}(Io),Gh=function(t){function n(){var n;return(n=t.apply(this,arguments)||this).Zxt=0,n.Zp=new E(0),n.tA=!1,n.av=!1,n}_t(n,t);var i=n.prototype;return i.W2=function(t,n){this.Zxt+=n,this.Zp=ru([this.Zp,t]),this._o(new Kh(t))},i.Ws=function(){this.YS||(this._o(new Io("close")),this.tA=!0)},Tt(n,[{key:"yI",get:function(){return this.Zxt}},{key:"jk",get:function(){return this.Zp}},{key:"YS",get:function(){return this.tA}},{key:"dv",get:function(){return this.av},set:function(t){this.av=t}}]),n}(Eo),$h="sync-seg-",Zh=function(){function t(t,n){this.lv=!1,this.wv=!1,this.o=$h+Yh(),this.gv=n?new Gh:void 0,this.kv=t?new Gh:void 0}return t.prototype.Ws=function(){this.gv&&this.gv.Ws(),this.kv&&this.kv.Ws()},Tt(t,[{key:"jv",get:function(){return this.lv},set:function(t){this.lv=t}},{key:"Ad",get:function(){return this.wv},set:function(t){this.wv=t}}]),t}();x(),gt();var Jh=1.1,Qh=function(t){function n(n,i,e){var r;return(r=t.call(this,[new xh,new Bh(8),new Mh(1),new Lh(0)])||this).tw=[],r.wbt=Yr(),r.rw=0,r.sw=function(t){if(t.tF>=en)for(;r.tw.length>0;)r.bw()},e&&r.cv(new Uh(e,"com.apple.streamingkeydelivery","1")),r.Bat=n,r.Lrt=i,r.Lrt.bn("remove",r.sw),r.kw=new zh(0),r.cv(r.kw),r}_t(n,t);var i=n.prototype;return i.LCt=function(){return this.Bat===Ph.mE?this.Lrt.tb:this.Bat===Ph.gE?this.Lrt.nb:void 0},i.Dat=function(t){return this.wbt.get(t)},i.Km=function(){this.tw.length=0,this.kw.fL=0,this.wbt.clear(),this.rw=0},i.YN=function(){return this.cb(),nn(t.prototype.YN.call(this)).concat(nn(this.tw))},i.cb=function(){for(var t=this.Lrt.ab(),n=0;n<t.length;n++){var i=t[n];if(!this.wbt.has(i.o)){var e=void 0;if(this.Bat===Ph.mE?(e=i.gv,i.Ad=!0):(e=i.kv,i.jv=!0),!e)return;this.wbt.set(i.o,e),e.dv&&this.tw.push(new Ch(i.o+"-init")),this.tw.push(new Dh(Jh,i.o)),this.rw+=Jh}}this.lb()},i.lb=function(){for(;this.rw>60;)this.bw()},i.bw=function(){var t=this.tw.shift();void 0!==t&&function(t){return t.Hw===Ah.rE}(t)&&(this.wbt.delete(t.sv),this.rw-=t.ev,this.kw.fL++)},n}(Vh);var ta=function(t){function n(n){var i;return(i=t.call(this,"remove")||this).tF=n,i}return _t(n,t),n}(Io),na=function(t){function n(n,i){var e;return(e=t.call(this)||this).tg=n,e.ng=i,e.ig=[],e.ug=[],e.sg=Yr(),e.lg=Yr(),e.bg=Yr(),e.mg=0,e}_t(n,t);var i=n.prototype;return i.ab=function(){return this.kg?(this.ig=this.ig.filter((function(t){return!(t.Ad&&t.jv)})),nn(this.ig).concat([this.kg],nn(this.ug))):[]},i.Z2=function(t){this.tm(t)},i.W2=function(t){this.tm(t),this.rm(t),this.om(t)},i.iT=function(t){this.tm(t),this.om(t)},i.Km=function(){var t;null==(t=this.kg)||t.Ws(),this.kg=void 0,this.ug.forEach((function(t){return t.Ws()})),this.ug.length=0,this.ig.length=0,this.bg=Yr(),this.mg=0},i.rm=function(t){var n=t.startPts,i=t.totalDuration;this.lg.set(t.mediaType,n+i)},i.sm=function(){if(this.kg){this.kg.Ws(),this.ig.push(this.kg);var t=this.ug.shift(),n=new Zh(this.tg,this.ng);t?(this.kg=t,this.ug.push(n)):this.kg=n}},i.am=function(t){if(this.kg){var n=!this.kg.kv||0===this.kg.kv.yI,i=!this.kg.gv||0===this.kg.gv.yI,e=this.kg.kv&&this.kg.kv.dv,r=this.kg.gv&&this.kg.gv.dv,o=i&&(n&&!(this.kg.jv||this.kg.Ad)||e),u=n&&(i&&!(this.kg.jv||this.kg.Ad)||r);(t===Ph.gE&&!u||t===Ph.mE&&!o)&&(this.sm(),this.sm())}},i.tm=function(t){var n=t.mediaType,i=t.kind,e=this.sg.get(n);if(void 0===e){if(i===qh.yit||i===qh.Ait){var r=[t];this.sg.set(n,r)}}else e.push(t)},i.om=function(t){var n=this.bm(t);for(var i=0;i<n.length;i++){var e=n[i];switch(e.kind){case qh.yit:this.km(e),this.bg=Yr(),this.mg=0;break;case qh.Tit:this.ip(e);break;case qh.Ait:this.up(e)}}},i.km=function(t){var n=t.mediaType;void 0===this.kg?(this.kg=new Zh(this.tg,this.ng),this.ug.push(new Zh(this.tg,this.ng))):this.am(n),n===Ph.mE?(this.ty=t.segment,this.kg.gv.dv=!0):n===Ph.gE&&(this.ny=t.segment,this.kg.kv.dv=!0)},i.up=function(t){var n,i,e=t.mediaType===Ph.gE,r=t.totalDuration,o=null!=(n=this.bg.get(t.mediaType))?n:0;e?(this.kg.kv.W2(t.segment,r),i=o+this.kg.kv.yI):(this.kg.gv.W2(t.segment,r),i=o+this.kg.gv.yI),i>=this.mg+Jh&&(this.bg.set(t.mediaType,i),this.mg+=Jh,this.sm())},i.ip=function(t){this.lg.set(t.mediaType,void 0),this.am(t.mediaType),this.ig.length=0,this._o(new ta(t.endTime))},i.bm=function(t){var n=this;if(t.kind===qh.Tit)return this.hy(t);var i=[];return this.sg.forEach((function(t){if(t&&t.length>0){var e=rn(t,(function(t){return t.kind===qh.Tit}));-1===e&&(e=t.length);for(var r=t.slice(0,e),o=0;o<r.length;o++){var u=r[o];if(!fn(i,u)){var s,f=n.hy(u);if(f.length>0)(s=i).push.apply(s,nn(f));else if(u.kind===qh.Ait)break}}}})),i},i.hy=function(t){var n=this.sg.get(t.mediaType),i=function(t){return t===Ph.mE?Ph.gE:Ph.mE}(t.mediaType);if(!(i===Ph.mE?this.ng:this.tg))return n.splice(0,n.indexOf(t)+1);if(t.kind===qh.yit)return[];var e=this.lg.get(i);if(void 0===e)return[];if(t.kind===qh.Tit){var r=this.by(i);if(r.length>0){var o=n.splice(0,n.indexOf(t));return n.splice(0,1),nn(o).concat(nn(r),[t])}return[]}if(t.startPts<=e){var u=n.splice(0,n.indexOf(t));n.splice(0,1);var s=this.my(t,u,i);return nn(u).concat(nn(s),[t])}return[]},i.my=function(t,n,i){var e=this.sg.get(i);if(!e)return[];var r=t.startPts+t.totalDuration,o=rn(e,(function(t){return t.kind===qh.Tit})),u=o-1;-1===o&&(u=e.length-1);for(var s=u+1,f=0;f<=u&&s===u+1;f++){var c=e[f];c.kind===qh.Ait&&c.startPts>r&&(s=f)}var h=-1;return-1!==rn(n,(function(t){return t.kind===qh.yit}))&&(h=rn(e,(function(t){return t.kind===qh.yit}))),h>s&&(s=h+1),s>0?(e[s-1].kind===qh.yit&&(s-=1),e.splice(0,s)):[]},i.by=function(t){var n=this.sg.get(t);if(n){var i=rn(n,(function(t){return t.kind===qh.Tit}));if(i>=0)return n.splice(0,i+1)}return[]},i.ky=function(){var t="[MEDIABUFFER] endPTS: ";this.lg.forEach((function(n,i){t=t.concat(i+" = "+n+" ")})),Wt.nw(t)},i.OS=function(t,n){var i=t+": [";null==n||n.forEach((function(t){i=i.concat(" "+t.kind+"("+t.mediaType+")")})),i=i.concat(" ]"),Wt.nw(i)},Tt(n,[{key:"nb",get:function(){var t;return null==(t=this.ny)?void 0:t.slice()}},{key:"tb",get:function(){var t;return null==(t=this.ty)?void 0:t.slice()}}]),n}(Eo);var ia=function(){function t(t,n){var i=t.some((function(t){return t.match("audio")})),e=t.some((function(t){return t.match("video")}));this.AS=new na(i,e),this.BS=new Hh(i,e),i&&(this.RT=new Qh(Ph.gE,this.AS,n)),e&&(this.IE=new Qh(Ph.mE,this.AS,n))}var n=t.prototype;return n.ME=function(t){var n,i,e=ea(t);return e===Ph.mE?null==(n=this.IE)?void 0:n.LCt():e===Ph.gE?null==(i=this.RT)?void 0:i.LCt():void 0},n.Dat=function(t){var n,i,e=t.split("/")[1],r=ea(t);return r===Ph.mE?null==(n=this.IE)?void 0:n.Dat(e):r===Ph.gE?null==(i=this.RT)?void 0:i.Dat(e):void 0},n.Z2=function(t){this.AS.Z2(t)},n.W2=function(t){this.AS.W2(t)},n.qlt=function(t){this.AS.iT(t)},n.Km=function(){var t,n;this.AS.Km(),this.BS.Km(),null==(t=this.RT)||t.Km(),null==(n=this.IE)||n.Km()},Tt(t,[{key:"tk",get:function(){return this.BS}},{key:"ik",get:function(){return this.RT}},{key:"uk",get:function(){return this.IE}}]),t}();function ea(t){return t.match(/video/)?Ph.mE:Ph.gE}var ra=function(){function t(t,n){var i=this;this.sk=t,this.ak=n,this.hut=void 0,this.uqt=$t((function(t){var n,e;return Zt(this,(function(r){switch((n=t.data).kind){case qh.wit:i.hut=new ia(n.mediaBufferConfigs,n.fairPlaySdkUri);break;case qh.yit:i.hut.Z2(n);break;case qh.Ait:i.hut.W2(n);break;case qh.Tit:i.hut.qlt(n)}return e={kind:qh.Sit},i.sk.postMessage(e),[2]}))})),this.sk.onmessage=this.uqt}var n=t.prototype;return n.qVt=function(t){return"master.m3u8"===t?this.hut.tk:"video/index.m3u8"===t?this.hut.uk:"audio/index.m3u8"===t?this.hut.ik:void 0},n.mk=function(t){if(t.match(/m3u8/)){var n,i=null==(n=this.qVt(t))?void 0:n.qVt();return new Response(i,{headers:{"Content-Type":"application/x-mpegurl; charset=utf-8"}})}if(t.match($h)){var e={"Content-Type":t.match(/video/)?"video/mp4":"audio/mp4"};if(t.match(/init/)){var r,o=null==(r=this.hut)?void 0:r.ME(t);return new Response(o,{headers:e})}var u=this.Cat(t);if(!u)return new Response(void 0,{status:404,statusText:"Not Found"});var s=function(t){var n,i=function(t){n.enqueue(t.jk)},e=function(){n.close(),t.vn("append",i),t.vn("close",e)};return new self.ReadableStream({start:function(r){(n=r).enqueue(t.jk),t.YS?n.close():(t.bn("append",i),t.bn("close",e))},cancel:function(){t.vn("append",i),t.vn("close",e)}})}(u);return new Response(s,{headers:e})}return new Response(void 0,{status:404,statusText:"Not Found"})},n.Cat=function(t){return this.hut.Dat(t)},n.close=function(){var t;this.sk.close(),null==(t=this.hut)||t.Km()},t}(),oa=function(){function t(){var t=this;this.f9=Yr(),this.uqt=function(n){var i=n.data;if(i.kind===qh.mit){t.kk().catch(Yt);var e=i.port,r=Yh(),o=new ra(e,n.source.id);t.f9.set(r,o);var u=function(n){n.data.kind===qh.kit&&(t.TR(r),e.removeEventListener("message",u))};e.addEventListener("message",u);var s={kind:qh.pit,sessionId:r};e.postMessage(s)}},this.CR=function(n){if(lo(n.request.url,"https://theo.proxy")){var i=new URL(n.request.url).pathname.split("/"),e=i[1],r=i.slice(2).join("/"),o=t.f9.get(e);if(void 0===o){var u=new Response(void 0,{headers:{message:"Given session ["+e+"] not found."},status:404,statusText:"Not Found"});return void n.respondWith(u)}if(void 0===r){var s=new Response(void 0,{headers:{message:"No resource ["+r+"] provided."},status:404,statusText:"Not Found"});return void n.respondWith(s)}var f=o.mk(r);n.respondWith(f)}}}var n=t.prototype;return n.pr=function(t){this.Wzt=t,t.addEventListener("message",this.uqt),t.addEventListener("fetch",this.CR)},n.TR=function(t){var n=this.f9.get(t);n&&n.close(),this.f9.delete(t)},n.kk=function(){var t=this;return $t((function(){var n,i;return Zt(this,(function(e){switch(e.label){case 0:return[4,t.Wzt.clients.matchAll()];case 1:return n=e.sent(),i=n.map((function(t){return t.id})),t.f9.forEach((function(n,e){fn(i,n.ak)||t.TR(e)})),[2]}}))}))()},t}();oa.BR=new oa;var ua=self;ua.addEventListener("install",(function(t){t.waitUntil(ua.skipWaiting())})),ua.addEventListener("activate",(function(t){t.waitUntil(ua.clients.claim())})),oa.BR.pr(ua)}("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof s?s:"undefined"!=typeof global?global:this);