senza-sdk 4.2.64-70c0747.0 → 4.2.65-4527e57.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/bundle.js +1 -1
- package/dist/bundle.js.LICENSE.txt +4 -0
- package/package.json +9 -16
- package/src/{implementation/alarmManager.js → alarmManager.js} +52 -15
- package/src/api.js +350 -183
- package/src/{interface/devSequence.js → devSequence.js} +35 -0
- package/src/{implementation/deviceManager.js → deviceManager.js} +65 -4
- package/src/{implementation/lifecycle.js → lifecycle.js} +182 -5
- package/src/{implementation/messageManager.js → messageManager.js} +6 -6
- package/src/{implementation/platformManager.js → platformManager.js} +4 -5
- package/src/{implementation/remotePlayer.js → remotePlayer.js} +139 -7
- package/src/{implementation/senzaShakaPlayer.js → senzaShakaPlayer.js} +114 -25
- package/src/{implementation/utils.js → utils.js} +6 -15
- package/src/implementation/api.js +0 -367
- package/src/interface/alarmManager.js +0 -69
- package/src/interface/api.js +0 -8
- package/src/interface/deviceManager.js +0 -133
- package/src/interface/lifecycle.js +0 -278
- package/src/interface/messageManager.js +0 -46
- package/src/interface/platformManager.js +0 -35
- package/src/interface/remotePlayer.js +0 -441
- package/src/interface/senzaShakaPlayer.js +0 -171
- package/src/interface/utils.js +0 -45
- /package/src/{implementation/SessionInfo.js → SessionInfo.js} +0 -0
- /package/src/{implementation/devHelper.js → devHelper.js} +0 -0
- /package/src/{implementation/eventListenersManager.js → eventListenersManager.js} +0 -0
- /package/src/{implementation/subtitlesUtils.js → subtitlesUtils.js} +0 -0
package/dist/bundle.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/*! For license information please see bundle.js.LICENSE.txt */
|
|
2
|
-
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.senza=t():e.senza=t()}(this,(()=>(()=>{var e={159:(e,t,n)=>{!function(){var e="undefined"!=typeof window?window:n.g,i={};for(var r in function(e,t,n){var i;function r(e){var t=0;return function(){return t<e.length?{done:!1,value:e[t++]}:{done:!0}}}var a="function"==typeof Object.defineProperties?Object.defineProperty:function(e,t,n){return e==Array.prototype||e==Object.prototype||(e[t]=n.value),e},o=function(n){n=["object"==typeof globalThis&&globalThis,n,"object"==typeof e&&e,"object"==typeof self&&self,"object"==typeof t&&t];for(var i=0;i<n.length;++i){var r=n[i];if(r&&r.Math==Math)return r}throw Error("Cannot find global object")}(this);function s(e,t){if(t)e:{var n=o;e=e.split(".");for(var i=0;i<e.length-1;i++){var r=e[i];if(!(r in n))break e;n=n[r]}(t=t(i=n[e=e[e.length-1]]))!=i&&null!=t&&a(n,e,{configurable:!0,writable:!0,value:t})}}function u(e){return(e={next:e})[Symbol.iterator]=function(){return this},e}function l(e){var t="undefined"!=typeof Symbol&&Symbol.iterator&&e[Symbol.iterator];if(t)return t.call(e);if("number"==typeof e.length)return{next:r(e)};throw Error(String(e)+" is not an iterable or ArrayLike")}function c(e){if(!(e instanceof Array)){e=l(e);for(var t,n=[];!(t=e.next()).done;)n.push(t.value);e=n}return e}s("Symbol",(function(e){function t(e,t){this.g=e,a(this,"description",{configurable:!0,writable:!0,value:t})}if(e)return e;t.prototype.toString=function(){return this.g};var n="jscomp_symbol_"+(1e9*Math.random()>>>0)+"_",i=0;return function e(r){if(this instanceof e)throw new TypeError("Symbol is not a constructor");return new t(n+(r||"")+"_"+i++,r)}})),s("Symbol.iterator",(function(e){if(e)return e;e=Symbol("Symbol.iterator");for(var t="Array Int8Array Uint8Array Uint8ClampedArray Int16Array Uint16Array Int32Array Uint32Array Float32Array Float64Array".split(" "),n=0;n<t.length;n++){var i=o[t[n]];"function"==typeof i&&"function"!=typeof i.prototype[e]&&a(i.prototype,e,{configurable:!0,writable:!0,value:function(){return u(r(this))}})}return e}));var d,h="function"==typeof Object.create?Object.create:function(e){function t(){}return t.prototype=e,new t};if("function"==typeof Object.setPrototypeOf)d=Object.setPrototypeOf;else{var f;e:{var p={};try{p.__proto__={a:!0},f=p.a;break e}catch(e){}f=!1}d=f?function(e,t){if(e.__proto__=t,e.__proto__!==t)throw new TypeError(e+" is not extensible");return e}:null}var g=d;function m(e,t){if(e.prototype=h(t.prototype),e.prototype.constructor=e,g)g(e,t);else for(var n in t)if("prototype"!=n)if(Object.defineProperties){var i=Object.getOwnPropertyDescriptor(t,n);i&&Object.defineProperty(e,n,i)}else e[n]=t[n];e.pk=t.prototype}function v(){this.o=!1,this.l=null,this.h=void 0,this.g=1,this.j=this.m=0,this.A=this.i=null}function y(e){if(e.o)throw new TypeError("Generator is already running");e.o=!0}function b(e,t){e.i={vg:t,Ig:!0},e.g=e.m||e.j}function w(e,t,n){return e.g=n,{value:t}}function T(e){e.g=0}function S(e,t,n){e.m=t,null!=n&&(e.j=n)}function x(e,t){e.m=0,e.j=t||0}function A(e,t,n){e.g=t,e.m=n||0}function E(e,t){return e.m=t||0,t=e.i.vg,e.i=null,t}function k(e){e.A=[e.i],e.m=0,e.j=0}function I(e,t){var n=e.A.splice(0)[0];(n=e.i=e.i||n)?n.Ig?e.g=e.m||e.j:null!=n.u&&e.j<n.u?(e.g=n.u,e.i=null):e.g=e.j:e.g=t}function M(e){this.g=new v,this.h=e}function C(e,t,n,i){try{var r=t.call(e.g.l,n);if(!(r instanceof Object))throw new TypeError("Iterator result "+r+" is not an object");if(!r.done)return e.g.o=!1,r;var a=r.value}catch(t){return e.g.l=null,b(e.g,t),D(e)}return e.g.l=null,i.call(e.g,a),D(e)}function D(e){for(;e.g.g;)try{var t=e.h(e.g);if(t)return e.g.o=!1,{value:t.value,done:!1}}catch(t){e.g.h=void 0,b(e.g,t)}if(e.g.o=!1,e.g.i){if(t=e.g.i,e.g.i=null,t.Ig)throw t.vg;return{value:t.return,done:!0}}return{value:void 0,done:!0}}function R(e){this.next=function(t){return y(e.g),e.g.l?t=C(e,e.g.l.next,t,e.g.s):(e.g.s(t),t=D(e)),t},this.throw=function(t){return y(e.g),e.g.l?t=C(e,e.g.l.throw,t,e.g.s):(b(e.g,t),t=D(e)),t},this.return=function(t){return function(e,t){y(e.g);var n=e.g.l;return n?C(e,"return"in n?n.return:function(e){return{value:e,done:!0}},t,e.g.return):(e.g.return(t),D(e))}(e,t)},this[Symbol.iterator]=function(){return this}}function P(e){return function(e){function t(t){return e.next(t)}function n(t){return e.throw(t)}return new Promise((function(i,r){!function e(a){a.done?i(a.value):Promise.resolve(a.value).then(t,n).then(e,r)}(e.next())}))}(new R(new M(e)))}function L(){for(var e=Number(this),t=[],n=e;n<arguments.length;n++)t[n-e]=arguments[n];return t}function N(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function j(e,t){e instanceof String&&(e+="");var n=0,i=!1,r={next:function(){if(!i&&n<e.length){var r=n++;return{value:t(r,e[r]),done:!1}}return i=!0,{done:!0,value:void 0}}};return r[Symbol.iterator]=function(){return r},r}function O(e,t,n){e instanceof String&&(e=String(e));for(var i=e.length,r=0;r<i;r++){var a=e[r];if(t.call(n,a,r,e))return{Gg:r,v:a}}return{Gg:-1,v:void 0}}function U(e,t,n){if(null==e)throw new TypeError("The 'this' value for String.prototype."+n+" must not be null or undefined");if(t instanceof RegExp)throw new TypeError("First argument to String.prototype."+n+" must not be a regular expression");return e+""}v.prototype.s=function(e){this.h=e},v.prototype.return=function(e){this.i={return:e},this.g=this.j},v.prototype.u=function(e){this.g=e},s("Promise",(function(e){function t(e){this.h=0,this.i=void 0,this.g=[],this.o=!1;var t=this.j();try{e(t.resolve,t.reject)}catch(e){t.reject(e)}}function n(){this.g=null}function i(e){return e instanceof t?e:new t((function(t){t(e)}))}if(e)return e;n.prototype.h=function(e){if(null==this.g){this.g=[];var t=this;this.i((function(){t.l()}))}this.g.push(e)};var r=o.setTimeout;n.prototype.i=function(e){r(e,0)},n.prototype.l=function(){for(;this.g&&this.g.length;){var e=this.g;this.g=[];for(var t=0;t<e.length;++t){var n=e[t];e[t]=null;try{n()}catch(e){this.j(e)}}}this.g=null},n.prototype.j=function(e){this.i((function(){throw e}))},t.prototype.j=function(){function e(e){return function(i){n||(n=!0,e.call(t,i))}}var t=this,n=!1;return{resolve:e(this.F),reject:e(this.l)}},t.prototype.F=function(e){if(e===this)this.l(new TypeError("A Promise cannot resolve to itself"));else if(e instanceof t)this.H(e);else{e:switch(typeof e){case"object":var n=null!=e;break e;case"function":n=!0;break e;default:n=!1}n?this.C(e):this.m(e)}},t.prototype.C=function(e){var t=void 0;try{t=e.then}catch(e){return void this.l(e)}"function"==typeof t?this.I(t,e):this.m(e)},t.prototype.l=function(e){this.s(2,e)},t.prototype.m=function(e){this.s(1,e)},t.prototype.s=function(e,t){if(0!=this.h)throw Error("Cannot settle("+e+", "+t+"): Promise already settled in state"+this.h);this.h=e,this.i=t,2===this.h&&this.G(),this.A()},t.prototype.G=function(){var e=this;r((function(){if(e.B()){var t=o.console;void 0!==t&&t.error(e.i)}}),1)},t.prototype.B=function(){if(this.o)return!1;var e=o.CustomEvent,t=o.Event,n=o.dispatchEvent;return void 0===n||("function"==typeof e?e=new e("unhandledrejection",{cancelable:!0}):"function"==typeof t?e=new t("unhandledrejection",{cancelable:!0}):(e=o.document.createEvent("CustomEvent")).initCustomEvent("unhandledrejection",!1,!0,e),e.promise=this,e.reason=this.i,n(e))},t.prototype.A=function(){if(null!=this.g){for(var e=0;e<this.g.length;++e)a.h(this.g[e]);this.g=null}};var a=new n;return t.prototype.H=function(e){var t=this.j();e.Hd(t.resolve,t.reject)},t.prototype.I=function(e,t){var n=this.j();try{e.call(t,n.resolve,n.reject)}catch(e){n.reject(e)}},t.prototype.then=function(e,n){function i(e,t){return"function"==typeof e?function(t){try{r(e(t))}catch(e){a(e)}}:t}var r,a,o=new t((function(e,t){r=e,a=t}));return this.Hd(i(e,r),i(n,a)),o},t.prototype.catch=function(e){return this.then(void 0,e)},t.prototype.Hd=function(e,t){function n(){switch(i.h){case 1:e(i.i);break;case 2:t(i.i);break;default:throw Error("Unexpected state: "+i.h)}}var i=this;null==this.g?a.h(n):this.g.push(n),this.o=!0},t.resolve=i,t.reject=function(e){return new t((function(t,n){n(e)}))},t.race=function(e){return new t((function(t,n){for(var r=l(e),a=r.next();!a.done;a=r.next())i(a.value).Hd(t,n)}))},t.all=function(e){var n=l(e),r=n.next();return r.done?i([]):new t((function(e,t){function a(t){return function(n){o[t]=n,0==--s&&e(o)}}var o=[],s=0;do{o.push(void 0),s++,i(r.value).Hd(a(o.length-1),t),r=n.next()}while(!r.done)}))},t})),s("WeakMap",(function(e){function t(e){if(this.g=(u+=Math.random()+1).toString(),e){e=l(e);for(var t;!(t=e.next()).done;)t=t.value,this.set(t[0],t[1])}}function n(){}function i(e){var t=typeof e;return"object"===t&&null!==e||"function"===t}function r(e){if(!N(e,s)){var t=new n;a(e,s,{value:t})}}function o(e){var t=Object[e];t&&(Object[e]=function(e){return e instanceof n?e:(Object.isExtensible(e)&&r(e),t(e))})}if(function(){if(!e||!Object.seal)return!1;try{var t=Object.seal({}),n=Object.seal({}),i=new e([[t,2],[n,3]]);return 2==i.get(t)&&3==i.get(n)&&(i.delete(t),i.set(n,4),!i.has(t)&&4==i.get(n))}catch(e){return!1}}())return e;var s="$jscomp_hidden_"+Math.random();o("freeze"),o("preventExtensions"),o("seal");var u=0;return t.prototype.set=function(e,t){if(!i(e))throw Error("Invalid WeakMap key");if(r(e),!N(e,s))throw Error("WeakMap key fail: "+e);return e[s][this.g]=t,this},t.prototype.get=function(e){return i(e)&&N(e,s)?e[s][this.g]:void 0},t.prototype.has=function(e){return i(e)&&N(e,s)&&N(e[s],this.g)},t.prototype.delete=function(e){return!!(i(e)&&N(e,s)&&N(e[s],this.g))&&delete e[s][this.g]},t})),s("Map",(function(e){function t(){var e={};return e.Ob=e.next=e.head=e}function n(e,t){var n=e[1];return u((function(){if(n){for(;n.head!=e[1];)n=n.Ob;for(;n.next!=n.head;)return n=n.next,{done:!1,value:t(n)};n=null}return{done:!0,value:void 0}}))}function i(e,t){var n=t&&typeof t;"object"==n||"function"==n?a.has(t)?n=a.get(t):(n=""+ ++o,a.set(t,n)):n="p_"+t;var i=e[0][n];if(i&&N(e[0],n))for(e=0;e<i.length;e++){var r=i[e];if(t!=t&&r.key!=r.key||t===r.key)return{id:n,list:i,index:e,entry:r}}return{id:n,list:i,index:-1,entry:void 0}}function r(e){if(this[0]={},this[1]=t(),this.size=0,e){e=l(e);for(var n;!(n=e.next()).done;)n=n.value,this.set(n[0],n[1])}}if(function(){if(!e||"function"!=typeof e||!e.prototype.entries||"function"!=typeof Object.seal)return!1;try{var t=Object.seal({x:4}),n=new e(l([[t,"s"]]));if("s"!=n.get(t)||1!=n.size||n.get({x:4})||n.set({x:4},"t")!=n||2!=n.size)return!1;var i=n.entries(),r=i.next();return!r.done&&r.value[0]==t&&"s"==r.value[1]&&!((r=i.next()).done||4!=r.value[0].x||"t"!=r.value[1]||!i.next().done)}catch(e){return!1}}())return e;var a=new WeakMap;r.prototype.set=function(e,t){var n=i(this,e=0===e?0:e);return n.list||(n.list=this[0][n.id]=[]),n.entry?n.entry.value=t:(n.entry={next:this[1],Ob:this[1].Ob,head:this[1],key:e,value:t},n.list.push(n.entry),this[1].Ob.next=n.entry,this[1].Ob=n.entry,this.size++),this},r.prototype.delete=function(e){return!(!(e=i(this,e)).entry||!e.list||(e.list.splice(e.index,1),e.list.length||delete this[0][e.id],e.entry.Ob.next=e.entry.next,e.entry.next.Ob=e.entry.Ob,e.entry.head=null,this.size--,0))},r.prototype.clear=function(){this[0]={},this[1]=this[1].Ob=t(),this.size=0},r.prototype.has=function(e){return!!i(this,e).entry},r.prototype.get=function(e){return(e=i(this,e).entry)&&e.value},r.prototype.entries=function(){return n(this,(function(e){return[e.key,e.value]}))},r.prototype.keys=function(){return n(this,(function(e){return e.key}))},r.prototype.values=function(){return n(this,(function(e){return e.value}))},r.prototype.forEach=function(e,t){for(var n,i=this.entries();!(n=i.next()).done;)n=n.value,e.call(t,n[1],n[0],this)},r.prototype[Symbol.iterator]=r.prototype.entries;var o=0;return r})),s("Set",(function(e){function t(e){if(this.g=new Map,e){e=l(e);for(var t;!(t=e.next()).done;)this.add(t.value)}this.size=this.g.size}return function(){if(!e||"function"!=typeof e||!e.prototype.entries||"function"!=typeof Object.seal)return!1;try{var t=Object.seal({x:4}),n=new e(l([t]));if(!n.has(t)||1!=n.size||n.add(t)!=n||1!=n.size||n.add({x:4})!=n||2!=n.size)return!1;var i=n.entries(),r=i.next();return!r.done&&r.value[0]==t&&r.value[1]==t&&!(r=i.next()).done&&r.value[0]!=t&&4==r.value[0].x&&r.value[1]==r.value[0]&&i.next().done}catch(e){return!1}}()?e:(t.prototype.add=function(e){return e=0===e?0:e,this.g.set(e,e),this.size=this.g.size,this},t.prototype.delete=function(e){return e=this.g.delete(e),this.size=this.g.size,e},t.prototype.clear=function(){this.g.clear(),this.size=0},t.prototype.has=function(e){return this.g.has(e)},t.prototype.entries=function(){return this.g.entries()},t.prototype.values=function(){return this.g.values()},t.prototype.keys=t.prototype.values,t.prototype[Symbol.iterator]=t.prototype.values,t.prototype.forEach=function(e,t){var n=this;this.g.forEach((function(i){return e.call(t,i,i,n)}))},t)})),s("Array.prototype.keys",(function(e){return e||function(){return j(this,(function(e){return e}))}})),s("Array.prototype.findIndex",(function(e){return e||function(e,t){return O(this,e,t).Gg}})),s("Array.from",(function(e){return e||function(e,t,n){t=null!=t?t:function(e){return e};var i=[],r="undefined"!=typeof Symbol&&Symbol.iterator&&e[Symbol.iterator];if("function"==typeof r){e=r.call(e);for(var a=0;!(r=e.next()).done;)i.push(t.call(n,r.value,a++))}else for(r=e.length,a=0;a<r;a++)i.push(t.call(n,e[a],a));return i}})),s("Array.prototype.values",(function(e){return e||function(){return j(this,(function(e,t){return t}))}})),s("Object.is",(function(e){return e||function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}})),s("Array.prototype.includes",(function(e){return e||function(e,t){var n=this;n instanceof String&&(n=String(n));var i=n.length;for(0>(t=t||0)&&(t=Math.max(t+i,0));t<i;t++){var r=n[t];if(r===e||Object.is(r,e))return!0}return!1}})),s("String.prototype.includes",(function(e){return e||function(e,t){return-1!==U(this,e,"includes").indexOf(e,t||0)}})),s("String.fromCodePoint",(function(e){return e||function(e){for(var t="",n=0;n<arguments.length;n++){var i=Number(arguments[n]);if(0>i||1114111<i||i!==Math.floor(i))throw new RangeError("invalid_code_point "+i);65535>=i?t+=String.fromCharCode(i):(i-=65536,t+=String.fromCharCode(i>>>10&1023|55296),t+=String.fromCharCode(1023&i|56320))}return t}})),s("WeakSet",(function(e){function t(e){if(this.g=new WeakMap,e){e=l(e);for(var t;!(t=e.next()).done;)this.add(t.value)}}return function(){if(!e||!Object.seal)return!1;try{var t=Object.seal({}),n=Object.seal({}),i=new e([t]);return!(!i.has(t)||i.has(n))&&(i.delete(t),i.add(n),!i.has(t)&&i.has(n))}catch(e){return!1}}()?e:(t.prototype.add=function(e){return this.g.set(e,!0),this},t.prototype.has=function(e){return this.g.has(e)},t.prototype.delete=function(e){return this.g.delete(e)},t)})),s("Array.prototype.find",(function(e){return e||function(e,t){return O(this,e,t).v}})),s("String.prototype.startsWith",(function(e){return e||function(e,t){var n=U(this,e,"startsWith"),i=n.length,r=e.length;t=Math.max(0,Math.min(0|t,n.length));for(var a=0;a<r&&t<i;)if(n[t++]!=e[a++])return!1;return a>=r}})),s("Object.entries",(function(e){return e||function(e){var t,n=[];for(t in e)N(e,t)&&n.push([t,e[t]]);return n}}));var _="function"==typeof Object.assign?Object.assign:function(e,t){for(var n=1;n<arguments.length;n++){var i=arguments[n];if(i)for(var r in i)N(i,r)&&(e[r]=i[r])}return e};s("Object.assign",(function(e){return e||_})),s("Promise.prototype.finally",(function(e){return e||function(e){return this.then((function(t){return Promise.resolve(e()).then((function(){return t}))}),(function(t){return Promise.resolve(e()).then((function(){throw t}))}))}})),s("Array.prototype.entries",(function(e){return e||function(){return j(this,(function(e,t){return[e,t]}))}})),s("Number.isNaN",(function(e){return e||function(e){return"number"==typeof e&&isNaN(e)}})),s("String.prototype.repeat",(function(e){return e||function(e){var t=U(this,null,"repeat");if(0>e||1342177279<e)throw new RangeError("Invalid count value");e|=0;for(var n="";e;)1&e&&(n+=t),(e>>>=1)&&(t+=t);return n}})),s("Number.EPSILON",(function(){return Math.pow(2,-52)})),s("Number.MAX_SAFE_INTEGER",(function(){return 9007199254740991})),s("Number.isFinite",(function(e){return e||function(e){return"number"==typeof e&&!isNaN(e)&&1/0!==e&&-1/0!==e}})),s("Object.values",(function(e){return e||function(e){var t,n=[];for(t in e)N(e,t)&&n.push(e[t]);return n}})),s("Math.log2",(function(e){return e||function(e){return Math.log(e)/Math.LN2}})),s("String.prototype.endsWith",(function(e){return e||function(e,t){var n=U(this,e,"endsWith");void 0===t&&(t=n.length),t=Math.max(0,Math.min(0|t,n.length));for(var i=e.length;0<i&&0<t;)if(n[--t]!=e[--i])return!1;return 0>=i}})),s("Math.trunc",(function(e){return e||function(e){if(e=Number(e),isNaN(e)||1/0===e||-1/0===e||0===e)return e;var t=Math.floor(Math.abs(e));return 0>e?-t:t}}));var B=this||self;function F(e,t){e=e.split(".");var n,i=B;e[0]in i||void 0===i.execScript||i.execScript("var "+e[0]);for(;e.length&&(n=e.shift());)e.length||void 0===t?i=i[n]&&i[n]!==Object.prototype[n]?i[n]:i[n]={}:i[n]=t}function V(){}function H(){}function G(e){this.g=Math.exp(Math.log(.5)/e),this.i=this.h=0}function K(e){return e.h/(1-Math.pow(e.g,e.i))}function X(){this.h=new G(2),this.j=new G(5),this.g=0,this.i=128e3,this.l=16e3}function q(){}function z(){}function W(){}function Y(e){var t=L.apply(1,arguments);$.has(e)||($.add(e),W.apply(q,c(t)))}function J(){}G.prototype.sample=function(e,t){var n=Math.pow(this.g,e);t=t*(1-n)+n*this.h,isNaN(t)||(this.h=t,this.i+=e)},X.prototype.configure=function(e){this.i=e.minTotalBytes,this.l=e.minBytes,this.h.g=Math.exp(Math.log(.5)/e.fastHalfLife),this.j.g=Math.exp(Math.log(.5)/e.slowHalfLife)},X.prototype.sample=function(e,t){if(!(t<this.l)){var n=8e3*t/e;e/=1e3,this.g+=t,this.h.sample(e,n),this.j.sample(e,n)}},X.prototype.getBandwidthEstimate=function(e){return this.g<this.i?e:Math.min(K(this.h),K(this.j))};var $=new Set;function Q(){this.g={}}function Z(){this.g=new Q}function ee(e,t,n,i){this.target=e,this.type=t,this.listener=n,this.g=function(e,t){if(null==t)return!1;if("boolean"==typeof t)return t;var n=new Set(["passive","capture"]);return Object.keys(t).filter((function(e){return!n.has(e)})),function(e){var t=te;if(null==t){t=!1;try{var n={},i={get:function(){return t=!0,!1}};Object.defineProperty(n,"passive",i),Object.defineProperty(n,"capture",i),i=function(){},e.addEventListener("test",i,n),e.removeEventListener("test",i,n)}catch(e){t=!1}te=t}return t||!1}(e)?t:t.capture||!1}(e,i),this.target.addEventListener(t,n,this.g)}e.console&&(W=function(){return console.warn.apply(console,c(L.apply(0,arguments)))},z=function(){console.error.apply(console,c(L.apply(0,arguments)))}),(i=Q.prototype).push=function(e,t){this.g.hasOwnProperty(e)?this.g[e].push(t):this.g[e]=[t]},i.get=function(e){return(e=this.g[e])?e.slice():null},i.remove=function(e,t){e in this.g&&(this.g[e]=this.g[e].filter((function(e){return e!=t})),0==this.g[e].length&&delete this.g[e])},i.forEach=function(e){for(var t in this.g)e(t,this.g[t])},i.size=function(){return Object.keys(this.g).length},i.keys=function(){return Object.keys(this.g)},(i=Z.prototype).release=function(){this.Va(),this.g=null},i.D=function(e,t,n,i){this.g&&(e=new ee(e,t,n,i),this.g.push(t,e))},i.pa=function(e,t,n,i){var r=this;this.D(e,t,(function i(a){r.cb(e,t,i),n(a)}),i)},i.cb=function(e,t,n){if(this.g)for(var i=this.g.get(t)||[],r=(i=l(i)).next();!r.done;r=i.next())(r=r.value).target!=e||n!=r.listener&&n||(r.cb(),this.g.remove(t,r))},i.Va=function(){if(this.g){var e,t=this.g,n=[];for(e in t.g)n.push.apply(n,c(t.g[e]));for(n=(t=l(n)).next();!n.done;n=t.next())n.value.cb();this.g.g={}}},F("shaka.util.EventManager",Z),Z.prototype.removeAll=Z.prototype.Va,Z.prototype.unlisten=Z.prototype.cb,Z.prototype.listenOnce=Z.prototype.pa,Z.prototype.listen=Z.prototype.D,Z.prototype.release=Z.prototype.release,ee.prototype.cb=function(){this.target.removeEventListener(this.type,this.listener,this.g),this.listener=this.target=null,this.g=!1};var te=void 0;function ne(t){if(re.has(t))return re.get(t);var n=e.ManagedMediaSource||e.MediaSource;return!!n&&(n=n.isTypeSupported(t),re.set(t,n),n)}function ie(){var t=e.ManagedSourceBuffer||e.SourceBuffer;return!!t&&!!t.prototype&&!!t.prototype.changeType}var re=new Map;function ae(e,t){this.g=e,this.h=t}function oe(e,t){var n=new ae(5,0),i=le,r=i.g,a=n.h-r.h;(0<(n.g-r.g||a)?i.i:i.h)(i.g,n,e,t)}function se(e,t,n,i){W([n,"has been deprecated and will be removed in",t,". We are currently at version",e,". Additional information:",i].join(" "))}function ue(e,t,n,i){z([n,"has been deprecated and has been removed in",t,". We are now at version",e,". Additional information:",i].join(" "))}ae.prototype.toString=function(){return"v"+this.g+"."+this.h};var le=null;function ce(){}function de(){}function he(){}function fe(e,t){if(!e&&!t)return!0;if(!e||!t||e.byteLength!=t.byteLength)return!1;if((ArrayBuffer.isView(e)?e.buffer:e)==(ArrayBuffer.isView(t)?t.buffer:t)&&(e.byteOffset||0)==(t.byteOffset||0))return!0;var n=ge(e);t=ge(t);for(var i=0;i<e.byteLength;i++)if(n[i]!=t[i])return!1;return!0}function pe(e){return ArrayBuffer.isView(e)?0==e.byteOffset&&e.byteLength==e.buffer.byteLength?e.buffer:new Uint8Array(e).buffer:e}function ge(e,t,n){return ye(e,void 0===t?0:t,n=void 0===n?1/0:n,Uint8Array)}function me(e,t,n){return ye(e,void 0===t?0:t,n=void 0===n?1/0:n,Uint16Array)}function ve(e,t,n){return ye(e,void 0===t?0:t,n=void 0===n?1/0:n,DataView)}function ye(e,t,n,i){var r=ArrayBuffer.isView(e)?e.buffer:e,a=1;"BYTES_PER_ELEMENT"in i&&(a=i.BYTES_PER_ELEMENT);var o=((e.byteOffset||0)+e.byteLength)/a;return new i(r,e=Math.floor(Math.max(0,Math.min(((e.byteOffset||0)+t)/a,o))),Math.floor(Math.min(e+Math.max(n,0),o))-e)}function be(){}function we(e){this.l=new de,(e=Te[e.toLowerCase()])&&(this.l=e()),this.h=new ce,(e=Se)&&(this.h=e())}ce.prototype.extract=function(){},ce.prototype.decode=function(){return[]},ce.prototype.clear=function(){},ce.prototype.getStreams=function(){return[]},de.prototype.init=function(){},de.prototype.parse=function(){return[]},F("shaka.util.BufferUtils",he),he.toDataView=ve,he.toUint16=me,he.toUint8=ge,he.toArrayBuffer=pe,he.equal=fe,be.prototype.init=function(){},be.prototype.i=function(){},be.prototype.g=function(){},be.prototype.j=function(){},F("shaka.media.IClosedCaptionParser",be),we.prototype.init=function(e,t){void 0!==t&&t||this.g(),this.l.init(e)},we.prototype.i=function(e){for(var t=(e=l(e=this.l.parse(e))).next();!t.done;t=e.next()){var n=ge((t=t.value).packet);0<n.length&&this.h.extract(n,t.pts)}return this.h.decode()},we.prototype.g=function(){this.h.clear()},we.prototype.j=function(){return this.h.getStreams()},F("shaka.media.ClosedCaptionParser",we),we.findDecoder=function(){return Se},we.unregisterDecoder=function(){Se=null},we.registerDecoder=function(e){Se=e},we.findParser=function(e){return Te[e]},we.unregisterParser=function(e){delete Te[e]},we.registerParser=function(e,t){Te[e]=t};var Te={},Se=null;function xe(){this.id="",this.regionAnchorY=this.regionAnchorX=this.viewportAnchorY=this.viewportAnchorX=0,this.height=this.width=100,this.viewportAnchorUnits=this.widthUnits=this.heightUnits=Ae,this.scroll=Ee}F("shaka.text.CueRegion",xe);var Ae=1;xe.units={PX:0,PERCENTAGE:Ae,LINES:2};var Ee="";function ke(e,t){return!("number"!=typeof e||"number"!=typeof t||!isNaN(e)||!isNaN(t))||e===t}function Ie(e,t){-1<(t=e.indexOf(t))&&e.splice(t,1)}function Me(e,t,n){if(n||(n=ke),e.length!=t.length)return!1;t=t.slice();for(var i=(e=l(e)).next(),r={};!i.done;r={Jg:void 0},i=e.next()){if(r.Jg=i.value,-1==(i=t.findIndex(function(e){return function(t){return n(e.Jg,t)}}(r))))return!1;t[i]=t[t.length-1],t.pop()}return 0==t.length}function Ce(e,t,n){if(n||(n=ke),e.length!=t.length)return!1;for(var i=0;i<e.length;i++)if(!n(e[i],t[i]))return!1;return!0}function De(e,t,n){var i=L.apply(3,arguments);if(this.severity=e,this.category=t,this.code=n,this.data=i,this.handled=!1,this.message="Shaka Error "+this.code,Re)try{throw Error(this.message||"Shaka Error")}catch(e){this.stack=e.stack}}xe.scrollMode={NONE:Ee,UP:"up"},De.prototype.toString=function(){return"shaka.util.Error "+JSON.stringify(this,null," ")},F("shaka.util.Error",De);var Re=!0;function Pe(e){this.h=e,this.g=void 0}function Le(e,t){return!e.length||!t.length||e===t||0<Ne(e,t).length}function Ne(e,t){if(!e.length)return t;if(!t.length)return e;for(var n=[],i=(e=l(e)).next();!i.done;i=e.next()){i=i.value;for(var r=l(t),a=r.next();!a.done;a=r.next())if(a=a.value,i.keySystem==a.keySystem){r=new Map;for(var o=l((i.initData||[]).concat(a.initData||[])),s=o.next();!s.done;s=o.next())s=s.value,r.set(s.keyId,s);r=Array.from(r.values()),o=i.keyIds&&a.keyIds?new Set([].concat(c(i.keyIds),c(a.keyIds))):i.keyIds||a.keyIds,n.push({keySystem:i.keySystem,licenseServerUri:i.licenseServerUri||a.licenseServerUri,distinctiveIdentifierRequired:i.distinctiveIdentifierRequired||a.distinctiveIdentifierRequired,persistentStateRequired:i.persistentStateRequired||a.persistentStateRequired,videoRobustness:i.videoRobustness||a.videoRobustness,audioRobustness:i.audioRobustness||a.audioRobustness,serverCertificate:i.serverCertificate||a.serverCertificate,serverCertificateUri:i.serverCertificateUri||a.serverCertificateUri,initData:r,keyIds:o});break}}return n}function je(e){return!!e&&!!e.match(/^com\.(microsoft|chromecast)\.playready/)}De.Severity={RECOVERABLE:1,CRITICAL:2},De.Category={NETWORK:1,TEXT:2,MEDIA:3,MANIFEST:4,STREAMING:5,DRM:6,PLAYER:7,CAST:8,STORAGE:9,ADS:10},De.Code={UNSUPPORTED_SCHEME:1e3,BAD_HTTP_STATUS:1001,HTTP_ERROR:1002,TIMEOUT:1003,MALFORMED_DATA_URI:1004,REQUEST_FILTER_ERROR:1006,RESPONSE_FILTER_ERROR:1007,MALFORMED_TEST_URI:1008,UNEXPECTED_TEST_REQUEST:1009,ATTEMPTS_EXHAUSTED:1010,SEGMENT_MISSING:1011,INVALID_TEXT_HEADER:2e3,INVALID_TEXT_CUE:2001,UNABLE_TO_DETECT_ENCODING:2003,BAD_ENCODING:2004,INVALID_XML:2005,INVALID_MP4_TTML:2007,INVALID_MP4_VTT:2008,UNABLE_TO_EXTRACT_CUE_START_TIME:2009,INVALID_MP4_CEA:2010,TEXT_COULD_NOT_GUESS_MIME_TYPE:2011,CANNOT_ADD_EXTERNAL_TEXT_TO_SRC_EQUALS:2012,TEXT_ONLY_WEBVTT_SRC_EQUALS:2013,MISSING_TEXT_PLUGIN:2014,CHAPTERS_TRACK_FAILED:2015,UNSUPPORTED_EXTERNAL_THUMBNAILS_URI:2017,BUFFER_READ_OUT_OF_BOUNDS:3e3,JS_INTEGER_OVERFLOW:3001,EBML_OVERFLOW:3002,EBML_BAD_FLOATING_POINT_SIZE:3003,MP4_SIDX_WRONG_BOX_TYPE:3004,MP4_SIDX_INVALID_TIMESCALE:3005,MP4_SIDX_TYPE_NOT_SUPPORTED:3006,WEBM_CUES_ELEMENT_MISSING:3007,WEBM_EBML_HEADER_ELEMENT_MISSING:3008,WEBM_SEGMENT_ELEMENT_MISSING:3009,WEBM_INFO_ELEMENT_MISSING:3010,WEBM_DURATION_ELEMENT_MISSING:3011,WEBM_CUE_TRACK_POSITIONS_ELEMENT_MISSING:3012,WEBM_CUE_TIME_ELEMENT_MISSING:3013,MEDIA_SOURCE_OPERATION_FAILED:3014,MEDIA_SOURCE_OPERATION_THREW:3015,VIDEO_ERROR:3016,QUOTA_EXCEEDED_ERROR:3017,TRANSMUXING_FAILED:3018,CONTENT_TRANSFORMATION_FAILED:3019,MSS_MISSING_DATA_FOR_TRANSMUXING:3020,MSS_TRANSMUXING_FAILED:3022,TRANSMUXING_NO_VIDEO_DATA:3023,UNABLE_TO_GUESS_MANIFEST_TYPE:4e3,DASH_INVALID_XML:4001,DASH_NO_SEGMENT_INFO:4002,DASH_EMPTY_ADAPTATION_SET:4003,DASH_EMPTY_PERIOD:4004,DASH_WEBM_MISSING_INIT:4005,DASH_UNSUPPORTED_CONTAINER:4006,DASH_PSSH_BAD_ENCODING:4007,DASH_NO_COMMON_KEY_SYSTEM:4008,DASH_MULTIPLE_KEY_IDS_NOT_SUPPORTED:4009,DASH_CONFLICTING_KEY_IDS:4010,RESTRICTIONS_CANNOT_BE_MET:4012,HLS_PLAYLIST_HEADER_MISSING:4015,INVALID_HLS_TAG:4016,HLS_INVALID_PLAYLIST_HIERARCHY:4017,DASH_DUPLICATE_REPRESENTATION_ID:4018,HLS_MULTIPLE_MEDIA_INIT_SECTIONS_FOUND:4020,HLS_REQUIRED_ATTRIBUTE_MISSING:4023,HLS_REQUIRED_TAG_MISSING:4024,HLS_COULD_NOT_GUESS_CODECS:4025,HLS_KEYFORMATS_NOT_SUPPORTED:4026,DASH_UNSUPPORTED_XLINK_ACTUATE:4027,DASH_XLINK_DEPTH_LIMIT:4028,CONTENT_UNSUPPORTED_BY_BROWSER:4032,CANNOT_ADD_EXTERNAL_TEXT_TO_LIVE_STREAM:4033,NO_VARIANTS:4036,PERIOD_FLATTENING_FAILED:4037,INCONSISTENT_DRM_ACROSS_PERIODS:4038,HLS_VARIABLE_NOT_FOUND:4039,HLS_MSE_ENCRYPTED_MP2T_NOT_SUPPORTED:4040,HLS_MSE_ENCRYPTED_LEGACY_APPLE_MEDIA_KEYS_NOT_SUPPORTED:4041,NO_WEB_CRYPTO_API:4042,CANNOT_ADD_EXTERNAL_THUMBNAILS_TO_LIVE_STREAM:4045,MSS_INVALID_XML:4046,MSS_LIVE_CONTENT_NOT_SUPPORTED:4047,AES_128_INVALID_IV_LENGTH:4048,AES_128_INVALID_KEY_LENGTH:4049,DASH_CONFLICTING_AES_128:4050,DASH_UNSUPPORTED_AES_128:4051,DASH_INVALID_PATCH:4052,HLS_EMPTY_MEDIA_PLAYLIST:4053,DASH_MSE_ENCRYPTED_LEGACY_APPLE_MEDIA_KEYS_NOT_SUPPORTED:4054,STREAMING_ENGINE_STARTUP_INVALID_STATE:5006,NO_RECOGNIZED_KEY_SYSTEMS:6e3,REQUESTED_KEY_SYSTEM_CONFIG_UNAVAILABLE:6001,FAILED_TO_CREATE_CDM:6002,FAILED_TO_ATTACH_TO_VIDEO:6003,INVALID_SERVER_CERTIFICATE:6004,FAILED_TO_CREATE_SESSION:6005,FAILED_TO_GENERATE_LICENSE_REQUEST:6006,LICENSE_REQUEST_FAILED:6007,LICENSE_RESPONSE_REJECTED:6008,ENCRYPTED_CONTENT_WITHOUT_DRM_INFO:6010,NO_LICENSE_SERVER_GIVEN:6012,OFFLINE_SESSION_REMOVED:6013,EXPIRED:6014,SERVER_CERTIFICATE_REQUIRED:6015,INIT_DATA_TRANSFORM_ERROR:6016,SERVER_CERTIFICATE_REQUEST_FAILED:6017,MIN_HDCP_VERSION_NOT_MATCH:6018,ERROR_CHECKING_HDCP_VERSION:6019,LOAD_INTERRUPTED:7e3,OPERATION_ABORTED:7001,NO_VIDEO_ELEMENT:7002,OBJECT_DESTROYED:7003,CONTENT_NOT_LOADED:7004,SRC_EQUALS_PRELOAD_NOT_SUPPORTED:7005,CAST_API_UNAVAILABLE:8e3,NO_CAST_RECEIVERS:8001,ALREADY_CASTING:8002,UNEXPECTED_CAST_ERROR:8003,CAST_CANCELED_BY_USER:8004,CAST_CONNECTION_TIMED_OUT:8005,CAST_RECEIVER_APP_UNAVAILABLE:8006,STORAGE_NOT_SUPPORTED:9e3,INDEXED_DB_ERROR:9001,DEPRECATED_OPERATION_ABORTED:9002,REQUESTED_ITEM_NOT_FOUND:9003,MALFORMED_OFFLINE_URI:9004,CANNOT_STORE_LIVE_OFFLINE:9005,NO_INIT_DATA_FOR_OFFLINE:9007,LOCAL_PLAYER_INSTANCE_REQUIRED:9008,NEW_KEY_OPERATION_NOT_SUPPORTED:9011,KEY_NOT_FOUND:9012,MISSING_STORAGE_CELL:9013,STORAGE_LIMIT_REACHED:9014,DOWNLOAD_SIZE_CALLBACK_ERROR:9015,MODIFY_OPERATION_NOT_SUPPORTED:9016,INDEXED_DB_INIT_TIMED_OUT:9017,CS_IMA_SDK_MISSING:1e4,CS_AD_MANAGER_NOT_INITIALIZED:10001,SS_IMA_SDK_MISSING:10002,SS_AD_MANAGER_NOT_INITIALIZED:10003,CURRENT_DAI_REQUEST_NOT_FINISHED:10004,MT_AD_MANAGER_NOT_INITIALIZED:10005,INTERSTITIAL_AD_MANAGER_NOT_INITIALIZED:10006,VAST_INVALID_XML:10007},Pe.prototype.value=function(){return null==this.g&&(this.g=this.h()),this.g};var Oe=new Pe((function(){return pe(new Uint8Array([0]))})),Ue=new Map;function _e(e){this.h=e,this.g=null}function Be(e){this.h=e,this.g=null}function Fe(){var t=e.ManagedMediaSource||e.MediaSource;return!(!t||!t.isTypeSupported)}function Ve(e){return""!=at().canPlayType(e)}function He(){return!!navigator.userAgent.match(/Edge?\//)}function Ge(){return rt("Xbox One")}function Ke(){return rt("Tizen")}function Xe(){return rt("Tizen 3")}function qe(){return rt("Web0S")}function ze(){return rt("CrKey")}function We(){if(!rt("Chrome")||navigator.userAgent.match(/Edge\//))return null;var e=navigator.userAgent.match(/Chrome\/(\d+)/);return e?parseInt(e[1],10):null}function Ye(){return!!navigator.vendor&&navigator.vendor.includes("Apple")&&!Ke()&&!rt("PC=EOS")&&!rt("PC=APL")&&!rt("VirginMedia")&&!Ze()&&!$e()&&!rt("AFT")&&!rt("WPE")&&!rt("DT_STB_BCM")&&!rt("Sky_STB")}function Je(){return rt("PlayStation 5")}function $e(){return rt("PlayStation 4")}function Qe(){return rt("Hisense")||rt("VIDAA")}function Ze(){return rt("SOPOpenBrowser")}function et(){if(!Ye())return null;var e=navigator.userAgent.match(/Version\/(\d+)/);return e||(e=navigator.userAgent.match(/OS (\d+)(?:_\d+)?/))?parseInt(e[1],10):null}function tt(){return navigator.userAgentData&&navigator.userAgentData.platform?"windows"==navigator.userAgentData.platform.toLowerCase():!!navigator.platform&&navigator.platform.toLowerCase().includes("win32")}function nt(){return rt("Android")}function it(){return!!(Ke()||qe()||Ge()||$e()||Je()||rt("AFT")||rt("PC=EOS")||rt("PC=APL")||rt("VirginMedia")||Ze()||rt("WPE")||ze()||Qe()||rt("DT_STB_BCM"))}function rt(e){return(navigator.userAgent||"").includes(e)}function at(){return lt||(ut||(ut=new Be((function(){lt=null}))),(lt=document.getElementsByTagName("video")[0]||document.getElementsByTagName("audio")[0])||(lt=document.createElement("video")),ut.$(1),lt)}function ot(t){return t?t===e.shakaMediaKeysPolyfill:!!e.shakaMediaKeysPolyfill}function st(){var t,n,i,r,a,o,s,u,l,c,d,h,f;return P((function(p){switch(p.g){case 1:if(t={width:1/0,height:1/0},ze()){if(d=e.cast&&cast.__platform__&&cast.__platform__.canDisplayType,t.width=1280,t.height=720,S(p,14),!(h=d)){p.u(16);break}return w(p,cast.__platform__.canDisplayType('video/mp4; codecs="avc1.640028"; width=3840; height=2160'),17)}if(Ke()){t.width=1920,t.height=1080;try{webapis.systeminfo&&webapis.systeminfo.getMaxVideoResolution?(n=webapis.systeminfo.getMaxVideoResolution(),t.width=n.width,t.height=n.height):webapis.productinfo.is8KPanelSupported&&webapis.productinfo.is8KPanelSupported()?(t.width=7680,t.height=4320):webapis.productinfo.isUdPanelSupported&&webapis.productinfo.isUdPanelSupported()&&(t.width=3840,t.height=2160)}catch(e){W("Tizen: Error detecting screen size, default screen size 1920x1080.")}p.u(3);break}if(qe()){try{i=JSON.parse(e.PalmSystem.deviceInfo),t.width=Math.max(1920,i.screenWidth),t.height=Math.max(1080,i.screenHeight)}catch(e){W("WebOS: Error detecting screen size, default screen size 1920x1080."),t.width=1920,t.height=1080}p.u(3);break}if(Qe()){e.Hisense_Get4KSupportState&&e.Hisense_Get4KSupportState()?(t.width=3840,t.height=2160):(t.width=1920,t.height=1080),p.u(3);break}if(!$e()&&!Je()){r=void 0;try{r="undefined"!=typeof Windows?Windows:chrome.webview.hostObjects.sync.Windows}catch(e){}if(r){t.width=1920,t.height=1080;try{a=new r.Media.Protection.ProtectionCapabilities,o=r.Media.Protection.ProtectionCapabilityResult,s=null;do{s=a.isTypeSupported('video/mp4;codecs="hvc1,mp4a";features="decode-res-x=3840,decode-res-y=2160,decode-bitrate=20000,decode-fps=30,decode-bpc=10,display-res-x=3840,display-res-y=2160,display-bpc=8"',"com.microsoft.playready.recommendation")}while(s===o.maybe);s===o.probably&&(t.width=3840,t.height=2160)}catch(e){W("Xbox: Error detecting screen size, default screen size 1920x1080.")}}else Ge()&&(t.width=1920,t.height=1080,W("Xbox: Error detecting screen size, default screen size 1920x1080."));p.u(3);break}return u=!1,S(p,8),w(p,e.msdk.device.getDisplayInfo(),10);case 10:l=p.h,u="4K"===l.resolution,A(p,9);break;case 8:return E(p),S(p,11),w(p,e.msdk.device.getDisplayInfoImmediate(),13);case 13:c=p.h,u="4K"===c.resolution,A(p,9);break;case 11:W("PlayStation: Failed to get the display info:",E(p));case 9:u?(t.width=3840,t.height=2160):(t.width=1920,t.height=1080),p.u(3);break;case 17:h=p.h;case 16:if(h){t.width=3840,t.height=2160,p.u(18);break}if(!(f=d)){p.u(19);break}return w(p,cast.__platform__.canDisplayType('video/mp4; codecs="avc1.640028"; width=1920; height=1080'),20);case 20:f=p.h;case 19:f&&(t.width=1920,t.height=1080);case 18:A(p,3);break;case 14:z("Failed to check canDisplayType:",E(p));case 3:return p.return(t)}}))}_e.prototype.$=function(t){var n=this;this.stop();var i=!0,r=null;return this.g=function(){e.clearTimeout(r),i=!1},r=e.setTimeout((function(){i&&n.h()}),1e3*t),this},_e.prototype.stop=function(){this.g&&(this.g(),this.g=null)},Be.prototype.hc=function(){return this.stop(),this.h(),this},Be.prototype.$=function(e){var t=this;return this.stop(),this.g=new _e((function(){t.h()})).$(e),this},Be.prototype.Ra=function(e){var t=this;return this.stop(),this.g=new _e((function(){t.g.$(e),t.h()})).$(e),this},Be.prototype.stop=function(){this.g&&(this.g.stop(),this.g=null)},F("shaka.util.Timer",Be),Be.prototype.stop=Be.prototype.stop,Be.prototype.tickEvery=Be.prototype.Ra,Be.prototype.tickAfter=Be.prototype.$,Be.prototype.tickNow=Be.prototype.hc;var ut=null,lt=null;function ct(){}function dt(t){if(!t)return"";if(239==(t=ge(t))[0]&&187==t[1]&&191==t[2]&&(t=t.subarray(3)),e.TextDecoder&&!$e())return(t=(new TextDecoder).decode(t)).includes("�")&&z('Decoded string contains an "unknown character" codepoint. That probably means the UTF8 encoding was incorrect!'),t;for(var n="",i=0;i<t.length;++i){var r=65533;if(128&t[i]?t.length>=i+2&&192==(224&t[i])&&128==(192&t[i+1])?(r=(31&t[i])<<6|63&t[i+1],i+=1):t.length>=i+3&&224==(240&t[i])&&128==(192&t[i+1])&&128==(192&t[i+2])?(r=(15&t[i])<<12|(63&t[i+1])<<6|63&t[i+2],i+=2):t.length>=i+4&&240==(241&t[i])&&128==(192&t[i+1])&&128==(192&t[i+2])&&128==(192&t[i+3])&&(r=(7&t[i])<<18|(63&t[i+1])<<12|(63&t[i+2])<<6|63&t[i+3],i+=3):r=t[i],65535>=r)n+=String.fromCharCode(r);else{var a=1023&(r-=65536);n+=String.fromCharCode(55296+(r>>10)),n+=String.fromCharCode(56320+a)}}return n}function ht(e,t,n){if(!e)return"";if(!n&&0!=e.byteLength%2)throw new De(2,2,2004);n=Math.floor(e.byteLength/2);var i=new Uint16Array(n);e=ve(e);for(var r=0;r<n;r++)i[r]=e.getUint16(2*r,t);return mt(i)}function ft(e){function t(e){return n.byteLength<=e||32<=n[e]&&126>=n[e]}if(!e)return"";var n=ge(e);if(239==n[0]&&187==n[1]&&191==n[2])return dt(n);if(254==n[0]&&255==n[1])return ht(n.subarray(2),!1);if(255==n[0]&&254==n[1])return ht(n.subarray(2),!0);if(0==n[0]&&0==n[2])return ht(e,!1);if(0==n[1]&&0==n[3])return ht(e,!0);if(t(0)&&t(1)&&t(2)&&t(3))return dt(e);throw new De(2,2,2003)}function pt(t){if(e.TextEncoder&&!$e()){var n=new TextEncoder;return pe(n.encode(t))}t=encodeURIComponent(t),t=unescape(t),n=new Uint8Array(t.length);for(var i=0;i<t.length;i++)n[i]=t[i].charCodeAt(0);return pe(n)}function gt(e,t){for(var n=new ArrayBuffer(2*e.length),i=new DataView(n),r=0;r<e.length;++r)i.setUint16(2*r,e.charCodeAt(r),t);return n}function mt(e){return yt.value()(e)}function vt(e){var t={"&":"&","<":"<",">":">",""":'"',"'":"'"," ":" ","‎":"","‏":""},n=/&(?:amp|lt|gt|quot|apos|nbsp|lrm|rlm|#[xX]?[0-9a-fA-F]+);/g,i=RegExp(n.source);return e&&i.test(e)?e.replace(n,(function(e){return"#"==e[1]?0<=(e="x"==e[2]||"X"==e[2]?parseInt(e.substring(3),16):parseInt(e.substring(2),10))&&1114111>=e?String.fromCodePoint(e):"":t[e]||"'"})):e||""}F("shaka.util.StringUtils",ct),ct.resetFromCharCode=function(){yt.g=void 0},ct.toUTF16=gt,ct.toUTF8=pt,ct.fromBytesAutoDetect=ft,ct.fromUTF16=ht,ct.fromUTF8=dt;var yt=new Pe((function(){function e(e){try{var t=new Uint8Array(e);return 0<String.fromCharCode.apply(null,t).length}catch(e){return!1}}for(var t={fc:65536};0<t.fc;(t={fc:t.fc}).fc/=2)if(e(t.fc))return function(e){return function(t){for(var n="",i=0;i<t.length;i+=e.fc)n+=String.fromCharCode.apply(null,t.subarray(i,i+e.fc));return n}}(t);return null}));function bt(e){this.h=e||"",this.g=0}function wt(e){Tt(e,/[ \t]+/gm)}function Tt(e,t){return t.lastIndex=e.g,t=null==(t=t.exec(e.h))?null:{position:t.index,length:t[0].length,results:t},e.g==e.h.length||null==t||t.position!=e.g?null:(e.g+=t.length,t.results)}function St(e){return e.g==e.h.length?null:(e=Tt(e,/[^ \t\n]*/gm))?e[0]:null}function xt(e){if(null==(e=Tt(e,Et)))return null;var t=Number(e[2]),n=Number(e[3]);return 59<t||59<n?null:(Number(e[6])||0)/1e3+n+60*t+3600*(Number(e[1])||0)}function At(e){return e?xt(new bt(e)):null}var Et=/(?:(\d{1,}):)?(\d{2}):(\d{2})((\.(\d{1,3})))?/g;function kt(e){var t=new WeakSet;return function e(n){switch(typeof n){case"undefined":case"boolean":case"number":case"string":case"symbol":case"function":return n;default:if(!n||ArrayBuffer.isView(n))return n;if(t.has(n))return null;var i=n.constructor==Array;if(n.constructor!=Object&&!i)return null;t.add(n);var r,a=i?[]:{};for(r in n)a[r]=e(n[r]);return i&&(a.length=n.length),a}}(e)}function It(e){var t,n={};for(t in e)n[t]=e[t];return n}function Mt(e){if(Array.isArray(e)){for(var t=[],n=0;n<e.length;n++){var i=n.toString(),r=e[n];void 0!==r&&(r=Mt(r))&&t.push(i+":"+r)}e="["+t.join(",")+"]"}else if("function"==typeof e)e="";else if(e instanceof Object){for((n=Object.keys(e)).sort(),t=[],i=(n=l(n)).next();!i.done;i=n.next())r=i.value,i=JSON.stringify(r),void 0!==(r=e[r])&&(r=Mt(r))&&t.push(i+":"+r);e="{"+t.join(",")+"}"}else e=JSON.stringify(e);return e}function Ct(e,t){var n=void 0!==n&&n;return Dt(e=ft(e),t,n)}function Dt(e,t,n){return e=function(e,t){function n(){for(var t=i;-1==="\r\n\t>/= ".indexOf(e[i])&&e[i];)i++;return e.slice(t,i)}var i=0;return function r(a,o){o=void 0!==o&&o;for(var s=[];e[i];)if(60==e.charCodeAt(i)){if(47===e.charCodeAt(i+1)){o=i+2,i=e.indexOf(">",i);var u=(o=e.substring(o,i)).indexOf(a);if(-1==u){var l=a.indexOf(".");0<l&&(u=o.indexOf(a.substring(0,l)))}if(-1==u)throw a=e.substring(0,i).split("\n"),Error("Unexpected close tag\nLine: "+(a.length-1)+"\nColumn: "+(a[a.length-1].length+1)+"\nChar: "+e[i]);i+1&&(i+=1);break}if(33===e.charCodeAt(i+1)){if(45==e.charCodeAt(i+2)){for(;-1!==i&&(62!==e.charCodeAt(i)||45!=e.charCodeAt(i-1)||45!=e.charCodeAt(i-2)||-1==i);)i=e.indexOf(">",i+1);-1===i&&(i=e.length)}else if(91===e.charCodeAt(i+2)&&91===e.charCodeAt(i+8)&&"cdata"===e.substr(i+3,5).toLowerCase()){-1==(u=e.indexOf("]]>",i))?(s.push(e.substr(i+9)),i=e.length):(s.push(e.substring(i+9,u)),i=u+3);continue}i++;continue}e:{l=o,i++;var d=n(),h={};for(u=[];62!==e.charCodeAt(i)&&e[i];){var f=e.charCodeAt(i);if(64<f&&91>f||96<f&&123>f){f=n();for(var p=e.charCodeAt(i);p&&39!==p&&34!==p&&!(64<p&&91>p||96<p&&123>p)&&62!==p;)i++,p=e.charCodeAt(i);var g=i+1;if(i=e.indexOf(e[i],g),g=e.slice(g,i),39===p||34===p){if(-1===i){if(l={tagName:d,attributes:h,children:u,parent:null},t)for(d=0;d<u.length;d++)"string"!=typeof u[d]&&(u[d].parent=l);u=l;break e}}else g=null,i--;if(f.startsWith("xmlns:")){p=g;var m=f.split(":")[1];on.set(p,m),sn.set(m,p)}"tt"===d&&"xml:space"===f&&"preserve"===g&&(l=!0),h[f]=g}i++}for(47!==e.charCodeAt(i-1)?(i++,u=r(d,l)):i++,l={tagName:d,attributes:h,children:u,parent:null},d=u.length,h=0;h<d;h++)"string"!=typeof(f=u[h])?t&&(f.parent=l):h==d-1&&"\n"==f&&u.pop();u=l}if(s.push(u),"string"==typeof u)break;"?"===u.tagName[0]&&u.children&&(s.push.apply(s,c(u.children)),u.children=[])}else u=i,-2==(i=e.indexOf("<",i)-1)&&(i=e.length),u=e.slice(u,i+1),o?0<u.length&&s.push(u):(s.length&&1==u.length&&"\n"==u[0]||0<u.trim().length)&&s.push(u),i++;return s}("")}(e,void 0!==n&&n),!t&&e.length?e[0]:(e=e.find((function(e){return t.split(",").includes(e.tagName)})))?e:null}function Rt(e){return on.has(e)?on.get(e):""}function Pt(e){return"string"==typeof e}function Lt(e){var t=[];if(!e.children)return[];for(var n=(e=l(e.children)).next();!n.done;n=e.next())"string"!=typeof(n=n.value)&&t.push(n);return t}function Nt(e,t){var n=[];if(!e.children)return[];for(var i=(e=l(e.children)).next();!i.done;i=e.next())(i=i.value).tagName===t&&n.push(i);return n}function jt(e){return"string"==typeof e?vt(e):""===(e=e.children.reduce((function(e,t){return"string"==typeof t?e+t:e}),""))?null:vt(e)}function Ot(e){return Array.from(e.children).every((function(e){return"string"==typeof e}))?((e=jt(e))&&(e=e.trim()),e):null}function Ut(e,t,n){if(n=void 0===n?[]:n,e.tagName===t&&n.push(e),e.children)for(var i=(e=l(e.children)).next();!i.done;i=e.next())Ut(i.value,t,n);return n}function _t(e,t){return 1!=(e=Nt(e,t)).length?null:e[0]}function Bt(e,t,n){return 1!=(e=Ht(e,t,n)).length?null:e[0]}function Ft(e,t,n,i){i=void 0===i?null:i;var r=null;return null!=(e=e.attributes[t])&&(r=n(e)),null==r?i:r}function Vt(e,t,n){return t=Rt(t),e.attributes[t+":"+n]||null}function Ht(e,t,n){t=Rt(t);var i=[];if(e.children)for(var r=(e=l(e.children)).next();!r.done;r=e.next())(r=r.value)&&r.tagName===t+":"+n&&i.push(r);return i}function Gt(e,t,n){for(var i=(t=l(t)).next();!i.done;i=t.next())if(i=Vt(e,i.value,n))return i;return null}function Kt(e){return e?(/^\d+-\d+-\d+T\d+:\d+:\d+(\.\d+)?$/.test(e)&&(e+="Z"),e=Date.parse(e),isNaN(e)?null:e/1e3):null}function Xt(e){return e&&(e=RegExp("^P(?:([0-9]*)Y)?(?:([0-9]*)M)?(?:([0-9]*)D)?(?:T(?:([0-9]*)H)?(?:([0-9]*)M)?(?:([0-9.]*)S)?)?$").exec(e))?(e=31536e3*Number(e[1]||null)+2592e3*Number(e[2]||null)+86400*Number(e[3]||null)+3600*Number(e[4]||null)+60*Number(e[5]||null)+Number(e[6]||null),isFinite(e)?e:null):null}function qt(e){var t=/([0-9]+)-([0-9]+)/.exec(e);return t?(e=Number(t[1]),isFinite(e)?(t=Number(t[2]),isFinite(t)?{start:e,end:t}:null):null):null}function zt(e){return 0==(e=Number(e))%1?e:null}function Wt(e){return 0==(e=Number(e))%1&&0<e?e:null}function Yt(e){return 0==(e=Number(e))%1&&0<=e?e:null}function Jt(e){return e=Number(e),isNaN(e)?null:e}function $t(e){return!!e&&"true"===e.toLowerCase()}function Qt(e){var t,n=(t=e.match(/^(\d+)\/(\d+)$/))?Number(t[1])/Number(t[2]):Number(e);return isNaN(n)?null:n}function Zt(e){for(var t=[],n=(e=l(e=vt(e).split(/\/+(?=(?:[^'"]*['"][^'"]*['"])*[^'"]*$)/))).next();!n.done;n=e.next()){var i=(n=n.value).match(/^([\w]+)/);if(i){var r=n.match(/(@id='(.*?)')/),a=n.match(/(@t='(\d+)')/),o=n.match(/(@n='(\d+)')/),s=n.match(/\[(\d+)\]/);t.push({name:i[0],id:r?r[0].match(/'(.*?)'/)[0].replace(/'/gm,""):null,t:a?Number(a[0].match(/'(.*?)'/)[0].replace(/'/gm,"")):null,n:o?Number(o[0].match(/'(.*?)'/)[0].replace(/'/gm,"")):null,position:s?Number(s[1])-1:null,Ub:n.split("/@")[1]||null})}else n.startsWith("@")&&t.length&&(t[t.length-1].Ub=n.slice(1))}return t}function en(e,t){var n=Zt(t.attributes.sel||"");if(n.length){var i=n[n.length-1],r=t.attributes.pos||null;null==(n=i.position)&&(null!==i.t&&(n=tn(e,"t",i.t)),null!==i.n&&(n=tn(e,"n",i.n))),null===n?n="prepend"===r?0:e.length:"prepend"===r?--n:"after"===r&&++n,r=t.tagName,(i=i.Ub)&&e[n]?nn(e[n],r,i,Ot(t)||""):("remove"!==r&&"replace"!==r||e.splice(n,1),"add"!==r&&"replace"!==r||e.splice.apply(e,[n,0].concat(c(t.children))))}}function tn(e,t,n){for(var i=0,r=(e=l(e)).next();!r.done;r=e.next()){if(Number(r.value.attributes[t])===n)return i;i++}return null}function nn(e,t,n,i){"remove"===t?delete e.attributes[n]:"add"!==t&&"replace"!==t||(e.attributes[n]=i)}function rn(e){var t="",n=e.tagName.split(":");for(var i in 0<n.length&&(t=n[0],t=sn.has(t)?sn.get(t):""),t=document.createElementNS(t,e.tagName),e.attributes)t.setAttribute(i,e.attributes[i]);for(i=(e=l(e.children)).next();!i.done;i=e.next())n=void 0,n="string"==typeof(i=i.value)?new Text(i):rn(i),t.appendChild(n);return t}function an(e){if(!e)return null;for(var t={tagName:e.tagName,attributes:It(e.attributes),children:[],parent:null},n=(e=l(e.children)).next();!n.done;n=e.next())"string"==typeof(n=n.value)||((n=an(n)).parent=t),t.children.push(n);return t}var on=new Map,sn=new Map;function un(e,t,n){this.startTime=e,this.endTime=t,this.payload=n,this.region=new xe,this.position=null,this.positionAlign=gn,this.size=0,this.textAlign=mn,this.direction=wn,this.writingMode=Tn,this.lineInterpretation=Sn,this.line=null,this.lineHeight="",this.lineAlign=xn,this.displayAlign=yn,this.fontSize=this.border=this.backgroundImage=this.backgroundColor=this.color="",this.fontWeight=In,this.fontStyle=Cn,this.linePadding=this.letterSpacing=this.fontFamily="",this.opacity=1,this.textCombineUpright="",this.textDecoration=[],this.textStrokeWidth=this.textStrokeColor=this.textShadow="",this.wrapLine=!0,this.id="",this.nestedCues=[],this.lineBreak=this.isContainer=!1,this.rubyTag=null,this.cellResolution={lc:32,rows:15}}function ln(e,t){return(e=new un(e,t,"")).lineBreak=!0,e}function cn(e,t){if(e.startTime!=t.startTime||e.endTime!=t.endTime||e.payload!=t.payload)return!1;for(var n in e)if("startTime"!=n&&"endTime"!=n&&"payload"!=n)if("nestedCues"==n){if(!Ce(e.nestedCues,t.nestedCues,cn))return!1}else if("region"==n||"cellResolution"==n){for(var i in e[n])if(e[n][i]!=t[n][i])return!1}else if(Array.isArray(e[n])){if(!Ce(e[n],t[n]))return!1}else if(e[n]!=t[n])return!1;return!0}function dn(e,t){t=void 0===t?new Map:t;var n=e.payload;if(n.includes("<")){0===t.size&&hn(t);var i=n;n=[];for(var r=-1,a=0;a<i.length;a++)"<"===i[a]?r=a+1:">"===i[a]&&0<r&&((r=i.substr(r,a-r)).match(Ln)&&n.push(r),r=-1);for(a=(n=l(n)).next();!a.done;a=n.next())a=a.value,i=i.replace("<"+a+">",'<div time="'+a+'">'),i+="</div>";e:{a=i,r=[];var o=-1;n="",i=!1;for(var s=0;s<a.length;s++)if("/"===a[s]){var u=a.indexOf(">",s);if(-1===u){n=a;break e}if((u=a.substring(s+1,u))&&"v"==u){i=!0;var c=null;if(r.length&&(c=r[r.length-1]),c){if(c===u)n+="/"+u+">";else{if(!c.startsWith("v")){n+=a[s];continue}n+="/"+c+">"}s+=u.length+1}else n+=a[s]}else n+=a[s]}else"<"===a[s]?"v"!=a[o=s+1]&&(o=-1):">"===a[s]&&0<o&&(r.push(a.substr(o,s-o)),o=-1),n+=a[s];for(r=(a=l(r)).next();!r.done;r=a.next())o=(r=r.value).replace(" ",".voice-"),n=(n=n.replace("<"+r+">","<"+o+">")).replace("</"+r+">","</"+o+">"),i||(n+="</"+o+">")}n=function(e){var t={"< ":""," >":" >"},n=/(< +>|<\s|\s>)/g,i=RegExp(n.source);return e&&i.test(e)?e.replace(n,(function(e){return t[e]||""})):e||""}(n),e.payload="";try{var d=Dt("<span>"+n+"</span>","span")}catch(e){}if(d)if(1!=(d=d.children).length||d[0].tagName)for(n=(d=l(d)).next();!n.done;n=d.next())fn(n.value,e,t);else e.payload=vt(n);else e.payload=vt(n)}else e.payload=vt(n)}function hn(e){for(var t=l(Object.entries(En)),n=t.next();!n.done;n=t.next()){var i=l(n.value);n=i.next().value,i=i.next().value;var r=new un(0,0,"");r.color=i,e.set("."+n,r)}for(n=(t=l(Object.entries(kn))).next();!n.done;n=t.next())n=(i=l(n.value)).next().value,i=i.next().value,(r=new un(0,0,"")).backgroundColor=i,e.set("."+n,r)}function fn(e,t,n){var i=t.clone();if(i.nestedCues=[],i.payload="",i.rubyTag="",i.line=null,i.region=new xe,i.position=null,i.size=0,i.textAlign=mn,e.tagName)for(var r=l(e.tagName.split(/(?=[ .])+/g)),a=r.next();!a.done;a=r.next()){var o=a=a.value;if(o.startsWith(".voice-")){var s=o.split("-").pop();o='v[voice="'+s+'"]',n.has(o)||(o="v[voice="+s+"]")}switch(n.has(o)&&(s=i,o=n.get(o))&&(s.backgroundColor=pn(o.backgroundColor,s.backgroundColor),s.color=pn(o.color,s.color),s.fontFamily=pn(o.fontFamily,s.fontFamily),s.fontSize=pn(o.fontSize,s.fontSize),s.textShadow=pn(o.textShadow,s.textShadow),s.fontWeight=o.fontWeight,s.fontStyle=o.fontStyle,s.opacity=o.opacity,s.rubyTag=o.rubyTag,s.textCombineUpright=o.textCombineUpright,s.wrapLine=o.wrapLine),a){case"br":return i=ln(i.startTime,i.endTime),void t.nestedCues.push(i);case"b":i.fontWeight=Mn;break;case"i":i.fontStyle=Dn;break;case"u":i.textDecoration.push(Pn);break;case"font":(a=e.attributes.color)&&(i.color=a);break;case"div":if(!(a=e.attributes.time))break;(a=At(a))&&(i.startTime=a);break;case"ruby":case"rp":case"rt":i.rubyTag=a}}if(r=e.children,Pt(e)||1==r.length&&Pt(r[0]))for(n=jt(e).split("\n"),e=!0,r=(n=l(n)).next();!r.done;r=n.next())r=r.value,e||(e=ln(i.startTime,i.endTime),t.nestedCues.push(e)),0<r.length&&((e=i.clone()).payload=vt(r),t.nestedCues.push(e)),e=!1;else for(t.nestedCues.push(i),e=(t=l(r)).next();!e.done;e=t.next())fn(e.value,i,n)}function pn(e,t){return e&&0<e.length?e:t}un.prototype.clone=function(){var e,t=new un(0,0,"");for(e in this)t[e]=this[e],t[e]&&t[e].constructor==Array&&(t[e]=t[e].slice());return t},F("shaka.text.Cue",un),un.parseCuePayload=dn,un.equal=cn,un.prototype.clone=un.prototype.clone;var gn="auto";un.positionAlign={LEFT:"line-left",RIGHT:"line-right",CENTER:"center",AUTO:gn};var mn="center",vn={LEFT:"left",RIGHT:"right",CENTER:mn,START:"start",END:"end"};un.textAlign=vn;var yn="after",bn={BEFORE:"before",CENTER:"center",AFTER:yn};un.displayAlign=bn;var wn="ltr";un.direction={HORIZONTAL_LEFT_TO_RIGHT:wn,HORIZONTAL_RIGHT_TO_LEFT:"rtl"};var Tn="horizontal-tb";un.writingMode={HORIZONTAL_TOP_TO_BOTTOM:Tn,VERTICAL_LEFT_TO_RIGHT:"vertical-lr",VERTICAL_RIGHT_TO_LEFT:"vertical-rl"};var Sn=0;un.lineInterpretation={LINE_NUMBER:Sn,PERCENTAGE:1};var xn="start",An={CENTER:"center",START:xn,END:"end"};un.lineAlign=An;var En={white:"white",lime:"lime",cyan:"cyan",red:"red",yellow:"yellow",magenta:"magenta",blue:"blue",black:"black"};un.defaultTextColor=En;var kn={bg_white:"white",bg_lime:"lime",bg_cyan:"cyan",bg_red:"red",bg_yellow:"yellow",bg_magenta:"magenta",bg_blue:"blue",bg_black:"black"};un.defaultTextBackgroundColor=kn;var In=400,Mn=700;un.fontWeight={NORMAL:In,BOLD:Mn};var Cn="normal",Dn="italic",Rn={NORMAL:Cn,ITALIC:Dn,OBLIQUE:"oblique"};un.fontStyle=Rn;var Pn="underline";un.textDecoration={UNDERLINE:Pn,LINE_THROUGH:"lineThrough",OVERLINE:"overline"};var Ln=/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g;function Nn(){}function jn(e,t,n){Un[e.toLowerCase().split(";")[0]+"-"+n]={priority:n,he:t}}function On(e,t){for(var n=e.toLowerCase().split(";")[0],i=l([Vn,Fn,Bn,_n]),r=i.next();!r.done;r=i.next())if(r=Un[n+"-"+r.value]){var a=r.he(),o=a.isSupported(e,t);if(a.destroy(),o)return r.he}return null}Nn.prototype.destroy=function(){},F("shaka.transmuxer.TransmuxerEngine",Nn),Nn.findTransmuxer=On,Nn.unregisterTransmuxer=function(e,t){delete Un[e.toLowerCase().split(";")[0]+"-"+t]},Nn.registerTransmuxer=jn,Nn.prototype.destroy=Nn.prototype.destroy;var Un={},_n=1,Bn=2,Fn=3,Vn=4;Nn.PluginPriority={FALLBACK:_n,PREFERRED_SECONDARY:Bn,PREFERRED:Fn,APPLICATION:Vn};var Hn=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^/?#]*)@)?([^/#?]*?)(?::([0-9]+))?(?=[/#?]|$))?([^?#]+)?(?:\\?([^#]*))?(?:#(.*))?$");function Gn(e){var t;e instanceof Gn?(Kn(this,e.Db),this.Cc=e.Cc,Xn(this,e.Fb),qn(this,e.Uc),this.Ua=e.Ua,zn(this,e.g.clone()),this.mc=e.mc):e&&(t=String(e).match(Hn))?(Kn(this,t[1]||"",!0),this.Cc=Wn(t[2]||""),Xn(this,t[3]||"",!0),qn(this,t[4]),this.Ua=Wn(t[5]||"",!0),zn(this,t[6]||"",!0),this.mc=Wn(t[7]||"")):this.g=new ni(null)}function Kn(e,t,n){e.Db=n?Wn(t,!0):t,e.Db&&(e.Db=e.Db.replace(/:$/,""))}function Xn(e,t,n){e.Fb=n?Wn(t,!0):t}function qn(e,t){if(t){if(t=Number(t),isNaN(t)||0>t)throw Error("Bad port number "+t);e.Uc=t}else e.Uc=null}function zn(e,t,n){t instanceof ni?e.g=t:(n||(t=Yn(t,ei)),e.g=new ni(t))}function Wn(e,t){return e?t?decodeURI(e):decodeURIComponent(e):""}function Yn(e,t,n){return null!=e?(e=encodeURI(e).replace(t,Jn),n&&(e=e.replace(/%25([0-9a-fA-F]{2})/g,"%$1")),e):null}function Jn(e){return"%"+((e=e.charCodeAt(0))>>4&15).toString(16)+(15&e).toString(16)}(i=Gn.prototype).Db="",i.Cc="",i.Fb="",i.Uc=null,i.Ua="",i.mc="",i.toString=function(){var e=[],t=this.Db;if(t&&e.push(Yn(t,$n,!0),":"),t=this.Fb){e.push("//");var n=this.Cc;n&&e.push(Yn(n,$n,!0),"@"),e.push(encodeURIComponent(t).replace(/%25([0-9a-fA-F]{2})/g,"%$1")),null!=(t=this.Uc)&&e.push(":",String(t))}return(t=this.Ua)&&(this.Fb&&"/"!=t.charAt(0)&&e.push("/"),e.push(Yn(t,"/"==t.charAt(0)?Zn:Qn,!0))),(t=this.g.toString())&&e.push("?",t),(t=this.mc)&&e.push("#",Yn(t,ti)),e.join("")},i.resolve=function(e){var t=this.clone();"data"===t.Db&&(t=new Gn);var n=!!e.Db;n?Kn(t,e.Db):n=!!e.Cc,n?t.Cc=e.Cc:n=!!e.Fb,n?Xn(t,e.Fb):n=null!=e.Uc;var i=e.Ua;if(n)qn(t,e.Uc);else if(n=!!e.Ua){if("/"!=i.charAt(0))if(this.Fb&&!this.Ua)i="/"+i;else{var r=t.Ua.lastIndexOf("/");-1!=r&&(i=t.Ua.substr(0,r+1)+i)}if(".."==i||"."==i)i="";else if(-1!=i.indexOf("./")||-1!=i.indexOf("/.")){r=0==i.lastIndexOf("/",0),i=i.split("/");for(var a=[],o=0;o<i.length;){var s=i[o++];"."==s?r&&o==i.length&&a.push(""):".."==s?((1<a.length||1==a.length&&""!=a[0])&&a.pop(),r&&o==i.length&&a.push("")):(a.push(s),r=!0)}i=a.join("/")}}return n?t.Ua=i:n=""!==e.g.toString(),n?zn(t,e.g.clone()):n=!!e.mc,n&&(t.mc=e.mc),t},i.clone=function(){return new Gn(this)};var $n=/[#\/\?@]/g,Qn=/[#\?:]/g,Zn=/[#\?]/g,ei=/[#\?@]/g,ti=/#/g;function ni(e){this.g=e||null}function ii(e){if(!e.Pa&&(e.Pa={},e.dd=0,e.g))for(var t=e.g.split("&"),n=0;n<t.length;n++){var i=t[n].indexOf("="),r=null;if(0<=i){var a=t[n].substring(0,i);r=t[n].substring(i+1)}else a=t[n];a=decodeURIComponent(a.replace(/\+/g," ")),r=r||"",e.add(a,decodeURIComponent(r.replace(/\+/g," ")))}}function ri(e){return ii(e),e.dd}function ai(){}function oi(e){return e=mt(ge(e)),btoa(e)}function si(e,t){return t=null==t||t,e=oi(e).replace(/\+/g,"-").replace(/\//g,"_"),t?e:e.replace(/[=]*$/,"")}function ui(t){t=e.atob(t.replace(/-/g,"+").replace(/_/g,"/"));for(var n=new Uint8Array(t.length),i=0;i<t.length;++i)n[i]=t.charCodeAt(i);return n}function li(t){for(var n=t.length/2,i=new Uint8Array(n),r=0;r<n;r++)i[r]=e.parseInt(t.substr(2*r,2),16);return i}function ci(e){var t=ge(e);e="";for(var n=(t=l(t)).next();!n.done;n=t.next())1==(n=(n=n.value).toString(16)).length&&(n="0"+n),e+=n;return e}function di(){for(var e=L.apply(0,arguments),t=0,n=0;n<e.length;++n)t+=e[n].byteLength;t=new Uint8Array(t);for(var i=n=0;i<e.length;++i){var r=e[i];ArrayBuffer.isView(r)&&1===r.BYTES_PER_ELEMENT?t.set(r,n):t.set(ge(r),n),n+=r.byteLength}return t}function hi(e,t,n){if(n=void 0===n?"":n,0==t.length)return e;if(1==e.length&&1==t.length){var i=new Gn(e[0]);return t=new Gn(t[0]),t=i.resolve(t),n&&zn(t,n),[t.toString()]}t=t.map((function(e){return new Gn(e)})),i=[];for(var r=(e=l(e)).next();!r.done;r=e.next()){r=new Gn(r.value);for(var a=l(t),o=a.next();!o.done;o=a.next())o=r.resolve(o.value),n&&zn(o,n),i.push(o.toString())}return i}function fi(e,t,n,i){return e={keySystem:e,encryptionScheme:t,licenseServerUri:"",distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,serverCertificateUri:"",sessionType:"",initData:n||[],keyIds:new Set},i&&(e.keySystemUris=new Set([i])),e}function pi(t,n){n=void 0===n?"cenc":n;var i=[],r=[],a=[];t.forEach((function(e,t){var n=t;22!=n.length&&(n=si(li(t),!1));var o=e;22!=o.length&&(o=si(li(e),!1)),e={kty:"oct",kid:n,k:o},i.push(e),r.push(e.kid),a.push(t)})),t=JSON.stringify({keys:i});var o=JSON.stringify({kids:r});return o=[{initData:ge(pt(o)),initDataType:"keyids"}],{keySystem:"org.w3.clearkey",encryptionScheme:n,licenseServerUri:"data:application/json;base64,"+e.btoa(t),distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,serverCertificateUri:"",sessionType:"",initData:o,keyIds:new Set(a)}}function gi(e,t){if(1==t.length)return t[0];if(null!=(e=mi(e,t)))return e;throw new De(2,4,4025,t)}function mi(e,t){for(var n=l(Ti[e]),i=n.next();!i.done;i=n.next()){i=i.value;for(var r=l(t),a=r.next();!a.done;a=r.next())if(a=a.value,i.test(a.trim()))return a.trim()}return e==yi?"":null}function vi(e,t){for(var n=[],i=(e=l(Ti[e])).next();!i.done;i=e.next()){i=i.value;for(var r=l(t),a=r.next();!a.done;a=r.next())a=a.value,i.test(a.trim())&&n.push(a.trim())}return n}(i=ni.prototype).Pa=null,i.dd=null,i.add=function(e,t){ii(this),this.g=null;var n=this.Pa.hasOwnProperty(e)?this.Pa[e]:null;return n||(this.Pa[e]=n=[]),n.push(t),this.dd++,this},i.set=function(e,t){return ii(this),this.g=null,this.Pa.hasOwnProperty(e)?this.Pa[e]=[t]:this.add(e,t),this},i.get=function(e){return ii(this),this.Pa[e]||[]},i.toString=function(){if(this.g)return this.g;if(!this.Pa)return"";var e,t=[];for(e in this.Pa)for(var n=encodeURIComponent(e),i=this.Pa[e],r=0;r<i.length;r++){var a=n;""!==i[r]&&(a+="="+encodeURIComponent(i[r])),t.push(a)}return this.g=t.join("&")},i.clone=function(){var e=new ni;if(e.g=this.g,this.Pa){var t,n={};for(t in this.Pa)n[t]=this.Pa[t].concat();e.Pa=n,e.dd=this.dd}return e},F("shaka.util.Uint8ArrayUtils",ai),ai.concat=di,ai.toHex=ci,ai.fromHex=li,ai.fromBase64=ui,ai.toBase64=si,ai.toStandardBase64=oi;var yi="text",bi={la:"video",V:"audio",wa:yi,He:"image",kj:"application"},wi=1/15,Ti={audio:[/^vorbis$/,/^Opus$/,/^opus$/,/^fLaC$/,/^flac$/,/^mp4a/,/^[ae]c-3$/,/^ac-4/,/^dts[cex]$/,/^iamf/,/^mhm[12]/],video:[/^avc/,/^hev/,/^hvc/,/^vvc/,/^vvi/,/^vp0?[89]/,/^av01/,/^dvh/,/^dva/,/^dav/],text:[/^vtt$/,/^wvtt/,/^stpp/]};function Si(){}function xi(e,t){var n=e;return t&&!ji.includes(e)&&(n+='; codecs="'+t+'"'),n}function Ai(e,t){return t&&(e+='; codecs="'+t+'"'),e}function Ei(e,t,n){var i=xi(e,t);return On(t=Ai(e,t))?(e=On(t))?(n=(e=e()).convertCodecs(n,t),e.destroy()):n=t:n="video/mp2t"!=e&&"audio"==n?i.replace("video","audio"):i,n}function ki(e,t,n){var i=[t];return Ni.forEach((function(t,r){var a=e[r];"codecs"==r?ji.includes(e.mimeType)||i.push('codecs="'+n+'"'):a&&i.push(t+'="'+a+'"')})),"PQ"==e.hdr&&i.push('eotf="smpte2084"'),i.join(";")}function Ii(e){return e.split(";")[0].split("/")[1]}function Mi(e){var t=Li(e);switch(e=t[0],t=t[1].toLowerCase(),!0){case"mp4a"===e&&"69"===t:case"mp4a"===e&&"6b"===t:case"mp4a"===e&&"40.34"===t:return"mp3";case"mp4a"===e&&"66"===t:case"mp4a"===e&&"67"===t:case"mp4a"===e&&"68"===t:case"mp4a"===e&&"40.2"===t:case"mp4a"===e&&"40.02"===t:case"mp4a"===e&&"40.5"===t:case"mp4a"===e&&"40.05"===t:case"mp4a"===e&&"40.29"===t:case"mp4a"===e&&"40.42"===t:return"aac";case"mp4a"===e&&"a5"===t:return"ac-3";case"mp4a"===e&&"a6"===t:return"ec-3";case"mp4a"===e&&"b2"===t:return"dtsx";case"mp4a"===e&&"a9"===t:return"dtsc";case"vp09"===e:return"vp9";case"avc1"===e:case"avc3"===e:return"avc";case"hvc1"===e:case"hev1"===e:return"hevc";case"vvc1"===e:case"vvi1"===e:return"vvc";case"dvh1"===e:case"dvhe"===e:return t&&t.startsWith("05")?"dovi-p5":"dovi-hevc";case"dvav"===e:case"dva1"===e:return"dovi-avc";case"dav1"===e:return"dovi-av1";case"dvc1"===e:case"dvi1"===e:return"dovi-vvc"}return e}function Ci(e){for(var t=[],n=(e=l(e.split(","))).next();!n.done;n=e.next())n=Li(n.value),t.push(n[0]);return t.sort().join(",")}function Di(e){return e.split(";")[0]}function Ri(e){return(e=e.split(/ *; */)).shift(),(e=e.find((function(e){return e.startsWith("codecs=")})))?e.split("=")[1].replace(/^"|"$/g,""):""}function Pi(e){return"application/x-mpegurl"===e||"application/vnd.apple.mpegurl"===e}function Li(e){var t=(e=e.split("."))[0];return e.shift(),[t,e.join(".")]}F("shaka.util.MimeUtils",Si),Si.getFullTypeWithAllCodecs=Ai,Si.getFullType=xi;var Ni=(new Map).set("codecs","codecs").set("frameRate","framerate").set("bandwidth","bitrate").set("width","width").set("height","height").set("channelsCount","channels"),ji=["audio/aac","audio/ac3","audio/ec3","audio/mpeg"];function Oi(e){this.i=null,this.j=e,this.B=!1,this.l=this.s=0,this.m=1/0,this.h=this.g=null,this.C="",this.A=function(){},this.o=new Map}function Ui(e){return!!Fi[e]||("application/cea-608"==e||"application/cea-708"==e)&&!!Se}function _i(e,t,n){if(e.C=t,t=e.o.get(t))for(var i=l(t.keys()),r=i.next();!r.done;r=i.next())(r=t.get(r.value).filter((function(e){return e.endTime<=n})))&&e.j.append(r)}function Bi(e,t,n){t.startTime+=n,t.endTime+=n;for(var i=(t=l(t.nestedCues)).next();!i.done;i=t.next())Bi(e,i.value,n)}Oi.prototype.destroy=function(){return this.j=this.i=null,this.o.clear(),Promise.resolve()},Oi.prototype.remove=function(e,t){var n=this;return P((function(i){if(1==i.g)return w(i,Promise.resolve(),2);!n.j||!n.j.remove(e,t)||null==n.g||t<=n.g||e>=n.h||(e<=n.g&&t>=n.h?n.g=n.h=null:e<=n.g&&t<n.h?n.g=t:e>n.g&&t>=n.h&&(n.h=e)),T(i)}))},F("shaka.text.TextEngine",Oi),Oi.prototype.destroy=Oi.prototype.destroy,Oi.findParser=function(e){return Fi[e]},Oi.unregisterParser=function(e){delete Fi[e]},Oi.registerParser=function(e,t){Fi[e]=t};var Fi={};function Vi(e,t){return e.concat(t)}function Hi(){}function Gi(e){return null!=e}function Ki(e,t){return Promise.race([t,new Promise((function(t,n){new Be(n).$(e)}))])}function Xi(){}function qi(e,t){return e=Yi(e),t=Yi(t),e.split("-")[0]==t.split("-")[0]}function zi(e,t){return e=Yi(e),t=Yi(t),e=e.split("-"),t=t.split("-"),e[0]==t[0]&&1==e.length&&2==t.length}function Wi(e,t){return e=Yi(e),t=Yi(t),e=e.split("-"),t=t.split("-"),2==e.length&&2==t.length&&e[0]==t[0]}function Yi(e){var t=(e=l(e.split("-x-"))).next().value;t=void 0===t?"":t,e=void 0===(e=e.next().value)?"":e;var n=l(t.split("-"));return t=void 0===(t=n.next().value)?"":t,n=void 0===(n=n.next().value)?"":n,e=e?"x-"+e:"",t=t.toLowerCase(),t=er.get(t)||t,((n=n.toUpperCase())?t+"-"+n:t)+(e?"-"+e:"")}function Ji(e,t){return e=Yi(e),(t=Yi(t))==e?4:zi(t,e)?3:Wi(t,e)?2:zi(e,t)?1:0}function $i(e){var t=e.indexOf("-");return e=(e=0<=t?e.substring(0,t):e).toLowerCase(),er.get(e)||e}function Qi(e){return e.language?Yi(e.language):e.audio&&e.audio.language?Yi(e.audio.language):e.video&&e.video.language?Yi(e.video.language):"und"}function Zi(e,t){e=Yi(e);for(var n=new Set,i=(t=l(t)).next();!i.done;i=t.next())n.add(Yi(i.value));for(i=(t=l(n)).next();!i.done;i=t.next())if((i=i.value)==e)return i;for(i=(t=l(n)).next();!i.done;i=t.next())if(zi(i=i.value,e))return i;for(i=(t=l(n)).next();!i.done;i=t.next())if(Wi(i=i.value,e))return i;for(t=(n=l(n)).next();!t.done;t=n.next())if(zi(e,t=t.value))return t;return null}F("shaka.util.LanguageUtils",Xi),Xi.findClosestLocale=Zi,Xi.getLocaleForVariant=Qi,Xi.getLocaleForText=function(e){return Yi(e.language||"und")},Xi.getBase=$i,Xi.relatedness=Ji,Xi.areSiblings=function(e,t){var n=$i(e),i=$i(t);return e!=n&&t!=i&&n==i},Xi.normalize=Yi,Xi.isSiblingOf=Wi,Xi.isParentOf=zi,Xi.areLanguageCompatible=qi,Xi.areLocaleCompatible=function(e,t){return(e=Yi(e))==Yi(t)};var er=new Map([["aar","aa"],["abk","ab"],["afr","af"],["aka","ak"],["alb","sq"],["amh","am"],["ara","ar"],["arg","an"],["arm","hy"],["asm","as"],["ava","av"],["ave","ae"],["aym","ay"],["aze","az"],["bak","ba"],["bam","bm"],["baq","eu"],["bel","be"],["ben","bn"],["bih","bh"],["bis","bi"],["bod","bo"],["bos","bs"],["bre","br"],["bul","bg"],["bur","my"],["cat","ca"],["ces","cs"],["cha","ch"],["che","ce"],["chi","zh"],["chu","cu"],["chv","cv"],["cor","kw"],["cos","co"],["cre","cr"],["cym","cy"],["cze","cs"],["dan","da"],["deu","de"],["div","dv"],["dut","nl"],["dzo","dz"],["ell","el"],["eng","en"],["epo","eo"],["est","et"],["eus","eu"],["ewe","ee"],["fao","fo"],["fas","fa"],["fij","fj"],["fin","fi"],["fra","fr"],["fre","fr"],["fry","fy"],["ful","ff"],["geo","ka"],["ger","de"],["gla","gd"],["gle","ga"],["glg","gl"],["glv","gv"],["gre","el"],["grn","gn"],["guj","gu"],["hat","ht"],["hau","ha"],["heb","he"],["her","hz"],["hin","hi"],["hmo","ho"],["hrv","hr"],["hun","hu"],["hye","hy"],["ibo","ig"],["ice","is"],["ido","io"],["iii","ii"],["iku","iu"],["ile","ie"],["ina","ia"],["ind","id"],["ipk","ik"],["isl","is"],["ita","it"],["jav","jv"],["jpn","ja"],["kal","kl"],["kan","kn"],["kas","ks"],["kat","ka"],["kau","kr"],["kaz","kk"],["khm","km"],["kik","ki"],["kin","rw"],["kir","ky"],["kom","kv"],["kon","kg"],["kor","ko"],["kua","kj"],["kur","ku"],["lao","lo"],["lat","la"],["lav","lv"],["lim","li"],["lin","ln"],["lit","lt"],["ltz","lb"],["lub","lu"],["lug","lg"],["mac","mk"],["mah","mh"],["mal","ml"],["mao","mi"],["mar","mr"],["may","ms"],["mkd","mk"],["mlg","mg"],["mlt","mt"],["mon","mn"],["mri","mi"],["msa","ms"],["mya","my"],["nau","na"],["nav","nv"],["nbl","nr"],["nde","nd"],["ndo","ng"],["nep","ne"],["nld","nl"],["nno","nn"],["nob","nb"],["nor","no"],["nya","ny"],["oci","oc"],["oji","oj"],["ori","or"],["orm","om"],["oss","os"],["pan","pa"],["per","fa"],["pli","pi"],["pol","pl"],["por","pt"],["pus","ps"],["que","qu"],["roh","rm"],["ron","ro"],["rum","ro"],["run","rn"],["rus","ru"],["sag","sg"],["san","sa"],["sin","si"],["slk","sk"],["slo","sk"],["slv","sl"],["sme","se"],["smo","sm"],["sna","sn"],["snd","sd"],["som","so"],["sot","st"],["spa","es"],["sqi","sq"],["srd","sc"],["srp","sr"],["ssw","ss"],["sun","su"],["swa","sw"],["swe","sv"],["tah","ty"],["tam","ta"],["tat","tt"],["tel","te"],["tgk","tg"],["tgl","tl"],["tha","th"],["tib","bo"],["tir","ti"],["ton","to"],["tsn","tn"],["tso","ts"],["tuk","tk"],["tur","tr"],["twi","tw"],["uig","ug"],["ukr","uk"],["urd","ur"],["uzb","uz"],["ven","ve"],["vie","vi"],["vol","vo"],["wel","cy"],["wln","wa"],["wol","wo"],["xho","xh"],["yid","yi"],["yor","yo"],["zha","za"],["zho","zh"],["zul","zu"]]);function tr(){}function nr(e,t,n,i,r){if(r.length){for(var a=e.textStreams,o=(r=l(r)).next(),s={};!o.done;s={$f:void 0},o=r.next())if(s.$f=o.value,(o=a.filter(function(e){return function(t){return!(!t.codecs.startsWith(e.$f)&&!t.mimeType.startsWith(e.$f))}}(s))).length){a=o;break}e.textStreams=a}if(a=e.variants,(t.length||n.length)&&(a=function(e,t,n){for(var i=(t=l(t)).next(),r={};!i.done;r={rh:void 0},i=t.next())if(r.rh=i.value,i=e.filter(function(e){return function(t){return t.video&&t.video.codecs.startsWith(e.rh)}}(r)),i.length){e=i;break}for(t=(n=l(n)).next(),i={};!t.done;i={kg:void 0},t=n.next())if(i.kg=t.value,t=e.filter(function(e){return function(t){return t.audio&&t.audio.codecs.startsWith(e.kg)}}(i)),t.length){e=t;break}return e}(a,t,n)),i.length){for(t=new Q,a=(n=l(a)).next();!a.done;a=n.next())a=a.value,t.push(String(a.video.width||0),a);var u=[];t.forEach((function(e,t){e=0;for(var n=[],r=(t=l(t)).next(),a={};!r.done;a={Be:void 0},r=t.next())a.Be=r.value,(r=i.filter(function(e){return function(t){return e.Be.decodingInfos[0][t]}}(a)).length)>e?(e=r,n=[a.Be]):r==e&&n.push(a.Be);u.push.apply(u,c(n))})),a=u}for(n=new Set,t=new Set,r=(a=l(a)).next();!r.done;r=a.next())(r=r.value).audio&&n.add(r.audio),r.video&&t.add(r.video);a=Array.from(n).sort((function(e,t){return e.bandwidth-t.bandwidth}));var d=[];for(n=new Map,r=(a=l(a)).next();!r.done;r=a.next()){if(o=(r=r.value).language+(r.channelsCount||0)+(r.audioSamplingRate||0)+r.roles.join(",")+r.label+r.groupId+r.fastSwitching,(s=n.get(o)||[]).length){var h=s[s.length-1],f=Mi(h.codecs),p=Mi(r.codecs);f!=p||r.bandwidth&&h.bandwidth&&!(r.bandwidth>h.bandwidth)||(s.push(r),d.push(r.id))}else s.push(r),d.push(r.id);n.set(o,s)}var g={vp8:1,avc:1,"dovi-avc":.95,vp9:.9,vp09:.9,hevc:.85,"dovi-hevc":.8,"dovi-p5":.75,av01:.7,"dovi-av1":.65,vvc:.6};a=Array.from(t).sort((function(e,t){if(!e.bandwidth||!t.bandwidth||e.bandwidth==t.bandwidth){if(e.codecs&&t.codecs&&e.codecs!=t.codecs&&e.width==t.width){var n=Mi(e.codecs),i=Mi(t.codecs);if(n!=i)return(g[n]||1)-(g[i]||1)}return e.width-t.width}return e.bandwidth-t.bandwidth})),t=ie();var m=[];for(n=new Map,r=(a=l(a)).next();!r.done;r=a.next()){if(r=r.value,o=Math.round(r.frameRate||0)+(r.hdr||"")+r.fastSwitching,(s=n.get(o)||[]).length){if(h=s[s.length-1],!t&&(f=Mi(h.codecs))!==(p=Mi(r.codecs)))continue;r.width>h.width||r.height>h.height?(s.push(r),m.push(r.id)):r.width==h.width&&r.height==h.height&&((f=Mi(h.codecs))!=(p=Mi(r.codecs))||r.bandwidth&&h.bandwidth&&!(r.bandwidth>h.bandwidth)||(s.push(r),m.push(r.id)))}else s.push(r),m.push(r.id);n.set(o,s)}e.variants=e.variants.filter((function(e){var t=e.audio;return e=e.video,!(t&&!d.includes(t.id)||e&&!m.includes(e.id))}))}function ir(e,t,n){function i(e,t,n){return e>=t&&e<=n}var r=e.video;if(r&&r.width&&r.height){var a=r.width,o=r.height;if(o>a&&(a=(o=l([o,a])).next().value,o=o.next().value),!i(a,t.minWidth,Math.min(t.maxWidth,n.width))||!i(o,t.minHeight,Math.min(t.maxHeight,n.height))||!i(r.width*r.height,t.minPixels,t.maxPixels))return!1}return!(e&&e.video&&e.video.frameRate&&!i(e.video.frameRate,t.minFrameRate,t.maxFrameRate)||e&&e.audio&&e.audio.channelsCount&&!i(e.audio.channelsCount,t.minChannelsCount,t.maxChannelsCount)||!i(e.bandwidth,t.minBandwidth,t.maxBandwidth))}function rr(e,t,n,i,r){var a,o;return P((function(s){if(1==s.g)return Ge()&&function(e){for(var t={dvav:"avc3",dva1:"avc1",dvhe:"hev1",dvh1:"hvc1",dvc1:"vvc1",dvi1:"vvi1"},n=new Set,i=(e=l(e)).next();!i.done;i=e.next())(i=i.value).video&&n.add(i.video);for(e=(n=l(n)).next();!e.done;e=n.next()){e=e.value;for(var r=(i=l(Object.keys(t))).next();!r.done;r=i.next())if(r=r.value,e.codecs.includes(r)){e.codecs=e.codecs.replace(r,t[r]);break}}}(t.variants),w(s,sr(t.variants,n,!1,i),2);a=null,e&&(o=e.g)&&(a=o.keySystem),t.variants=t.variants.filter((function(e){var t=function(e,t,n){if(!e.decodingInfos.some((function(e){return!(!e.supported||t&&(e=e.keySystemAccess)&&(n[e.keySystem]||e.keySystem)!=t)})))return!1;var i=Ge(),r=rt("Firefox")&&nt(),a=e.video,o=a&&a.width||0,s=a&&a.height||0;if(i&&a&&(1920<o||1080<s)&&(a.codecs.includes("avc1.")||a.codecs.includes("avc3.")))return!1;if(a){if(i=cr(a.codecs),a.codecs.includes(",")){if(i=cr(i=gi("video",o=a.codecs.split(","))),o=lr(o=gi("audio",o),a.mimeType),!ne(s=Ei(a.mimeType,o,"audio")))return!1;i=[i,o].join()}if(a.codecs!=i){if(!ne(o=Ei(a.mimeType,i,"video")))return!1;a.codecs=i}}if(e=e.audio,r&&e&&e.encrypted&&e.codecs.toLowerCase().includes("opus"))return!1;if(e&&(r=lr(e.codecs,e.mimeType),e.codecs!=r)){if(!ne(a=Ei(e.mimeType,r,"audio")))return!1;e.codecs=r}return!0}(e,a,r);if(!t){var n=[];e.audio&&n.push(xr(e.audio)),e.video&&n.push(xr(e.video))}return t})),T(s)}))}function ar(e,t){var n,i,r,a,o,s,u;return P((function(c){if(1==c.g){for(n=function(e,t){if(e){var n=It(e);return n.supported=e.supported&&t.supported,n.powerEfficient=e.powerEfficient&&t.powerEfficient,n.smooth=e.smooth&&t.smooth,t.keySystemAccess&&!n.keySystemAccess&&(n.keySystemAccess=t.keySystemAccess),n}return t},i=null,r=[],a=l(t),o=a.next(),s={};!o.done;s={cache:void 0,Gd:void 0},o=a.next())u=o.value,s.Gd=Mt(u),s.cache=Ar,s.cache[s.Gd]?i=n(i,s.cache[s.Gd]):r.push(or(u).then(function(e){return function(t){for(var r=null,a=(t=l(t||[])).next();!a.done;a=t.next())r=n(r,a.value);r&&(e.cache[e.Gd]=r,i=n(i,r))}}(s)));return w(c,Promise.all(r),2)}i&&e.decodingInfos.push(i),T(c)}))}function or(e){var t=[""];e.video&&(t=Ri(e.video.contentType).split(","));var n=[""];e.audio&&(n=Ri(e.audio.contentType).split(","));for(var i=[],r=(t=l(t)).next();!r.done;r=t.next()){r=r.value;for(var a=l(n),o=a.next(),s={};!o.done;s={Fc:void 0},o=a.next())o=o.value,s.Fc=kt(e),e.video&&(s.Fc.video.contentType=xi(Di(s.Fc.video.contentType),r)),e.audio&&(s.Fc.audio.contentType=xi(Di(s.Fc.audio.contentType),o)),i.push(new Promise(function(e){return function(t,n){Ki(1,navigator.mediaCapabilities.decodingInfo(e.Fc)).then((function(e){t(e)})).catch(n)}}(s)))}return Promise.all(i).catch((function(){return JSON.stringify(e),null}))}function sr(e,t,n,i){var r,a,o,s,u,c,d,h,f,p,g,m,v,y,b,T,S,x;return P((function(A){switch(A.g){case 1:if(e.some((function(e){return e.decodingInfos.length})))return A.return();r=l(i),a=r.next(),o={};case 2:if(a.done){A.u(4);break}o.Tg=a.value,s=!1,u=l(e),c=u.next();case 5:if(c.done){A.u(7);break}d=c.value,h=ur(d,t,n).filter((E=o,function(e){return((e=e[0]).keySystemConfiguration&&e.keySystemConfiguration.keySystem)===E.Tg})),f=l(h),p=f.next();case 8:if(p.done){A.u(10);break}return g=p.value,w(A,ar(d,g),9);case 9:p=f.next(),A.u(8);break;case 10:d.decodingInfos.length&&(s=!0),c=u.next(),A.u(5);break;case 7:if(s)return A.return();o={Tg:void 0},a=r.next(),A.u(2);break;case 4:m=l(e),v=m.next();case 12:if(v.done){A.u(0);break}y=v.value,b=ur(y,t,n).filter((function(e){return!(e=(e=e[0]).keySystemConfiguration&&e.keySystemConfiguration.keySystem)||!i.includes(e)})),T=l(b),S=T.next();case 15:if(S.done){v=m.next(),A.u(12);break}return x=S.value,w(A,ar(y,x),16);case 16:S=T.next(),A.u(15)}var E}))}function ur(e,t,n){var i=e.audio,r=e.video,a=[],o=[];if(r)for(var s=l(r.fullMimeTypes),u=s.next();!u.done;u=s.next()){var c=Ri(u=u.value);if(c.includes(",")&&!i){var d=c.split(","),h=Di(u);c=gi("video",d),h=Ei(h,d=lr(d=gi("audio",d),h),"audio"),o.push({contentType:h,channels:2,bitrate:e.bandwidth||1,samplerate:1,spatialRendering:!1})}if(c=cr(c),u={contentType:Ei(Di(u),c,"video"),width:r.width||64,height:r.height||64,bitrate:r.bandwidth||e.bandwidth||1,framerate:r.frameRate||1},r.hdr)switch(r.hdr){case"SDR":u.transferFunction="srgb";break;case"PQ":u.transferFunction="pq";break;case"HLG":u.transferFunction="hlg"}r.colorGamut&&(u.colorGamut=r.colorGamut),a.push(u)}if(i)for(u=(s=l(i.fullMimeTypes)).next();!u.done;u=s.next())u=Ei(u=Di(c=u.value),c=lr(Ri(c),u),"audio"),o.push({contentType:u,channels:i.channelsCount||2,bitrate:i.bandwidth||e.bandwidth||1,samplerate:i.audioSamplingRate||1,spatialRendering:i.spatialAudio});for(s=[],0==a.length&&a.push(null),0==o.length&&o.push(null),u=(a=l(a)).next();!u.done;u=a.next())for(u=u.value,h=(c=l(o)).next();!h.done;h=c.next())h=h.value,d={type:n?"file":"media-source"},u&&(d.video=u),h&&(d.audio=h),s.push(d);if(!(o=(e.video?e.video.drmInfos:[]).concat(e.audio?e.audio.drmInfos:[])).length)return[s];for(e=[],n=new Map,a=(o=l(o)).next();!a.done;a=o.next())a=a.value,n.get(a.keySystem)||n.set(a.keySystem,[]),n.get(a.keySystem).push(a);for(o=t?"required":"optional",t=t?["persistent-license"]:["temporary"],u=(a=l(n.keys())).next();!u.done;u=a.next()){for(u=u.value,c=[],d=(h=l(s)).next();!d.done;d=h.next()){d=Object.assign({},d.value);for(var f=n.get(u),p={keySystem:u,initDataType:"cenc",persistentState:o,distinctiveIdentifier:"optional",sessionTypes:t},g=(f=l(f)).next();!g.done;g=f.next()){if((g=g.value).initData&&g.initData.length){for(var m=new Set,v=l(g.initData),y=v.next();!y.done;y=v.next())m.add(y.value.initDataType);p.initDataType=g.initData[0].initDataType}g.distinctiveIdentifierRequired&&(p.distinctiveIdentifier="required"),g.persistentStateRequired&&(p.persistentState="required"),g.sessionType&&(p.sessionTypes=[g.sessionType]),i&&(p.audio?(g.encryptionScheme&&(p.audio.encryptionScheme=p.audio.encryptionScheme||g.encryptionScheme),p.audio.robustness=p.audio.robustness||g.audioRobustness):(p.audio={robustness:g.audioRobustness},g.encryptionScheme&&(p.audio.encryptionScheme=g.encryptionScheme)),""==p.audio.robustness&&delete p.audio.robustness),r&&(p.video?(g.encryptionScheme&&(p.video.encryptionScheme=p.video.encryptionScheme||g.encryptionScheme),p.video.robustness=p.video.robustness||g.videoRobustness):(p.video={robustness:g.videoRobustness},g.encryptionScheme&&(p.video.encryptionScheme=g.encryptionScheme)),""==p.video.robustness&&delete p.video.robustness)}d.keySystemConfiguration=p,c.push(d)}e.push(c)}return e}function lr(e,t){return"flac"==e.toLowerCase()?et()?"fLaC":"flac":"opus"===e.toLowerCase()?et()&&"mp4"==Ii(t)?"Opus":"opus":e}function cr(e){if(e.includes("avc1")){var t=e.split(".");if(3==t.length)return e=t.shift()+".",(e+=parseInt(t.shift(),10).toString(16))+("000"+parseInt(t.shift(),10).toString(16)).slice(-4)}else if("vp9"==e)return"vp09.00.41.08";return e}function dr(e){var t=e.audio,n=e.video,i=t?t.mimeType:null,r=n?n.mimeType:null,a=t?t.codecs:null,o=n?n.codecs:null,s=[];o&&s.push(o),a&&s.push(a);var u=[];n&&u.push(n.mimeType),t&&u.push(t.mimeType),u=u[0]||null;var c=[];t&&c.push(t.kind),n&&c.push(n.kind),c=c[0]||null;var d=new Set;if(t)for(var h=l(t.roles),f=h.next();!f.done;f=h.next())d.add(f.value);if(n)for(f=(h=l(n.roles)).next();!f.done;f=h.next())d.add(f.value);return e={id:e.id,active:!1,type:"variant",bandwidth:e.bandwidth,language:e.language,label:null,kind:c,width:null,height:null,frameRate:null,pixelAspectRatio:null,hdr:null,colorGamut:null,videoLayout:null,mimeType:u,audioMimeType:i,videoMimeType:r,codecs:s.join(", "),audioCodec:a,videoCodec:o,primary:e.primary,roles:Array.from(d),audioRoles:null,forced:!1,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,originalTextId:null,originalImageId:null,accessibilityPurpose:null,originalLanguage:null},n&&(e.videoId=n.id,e.originalVideoId=n.originalId,e.width=n.width||null,e.height=n.height||null,e.frameRate=n.frameRate||null,e.pixelAspectRatio=n.pixelAspectRatio||null,e.videoBandwidth=n.bandwidth||null,e.hdr=n.hdr||null,e.colorGamut=n.colorGamut||null,e.videoLayout=n.videoLayout||null,o.includes(",")&&(e.channelsCount=n.channelsCount,e.audioSamplingRate=n.audioSamplingRate,e.spatialAudio=n.spatialAudio,e.originalLanguage=n.originalLanguage)),t&&(e.audioId=t.id,e.originalAudioId=t.originalId,e.channelsCount=t.channelsCount,e.audioSamplingRate=t.audioSamplingRate,e.audioBandwidth=t.bandwidth||null,e.spatialAudio=t.spatialAudio,e.label=t.label,e.audioRoles=t.roles,e.accessibilityPurpose=t.accessibilityPurpose,e.originalLanguage=t.originalLanguage),e}function hr(e){return{id:e.id,active:!1,type:yi,bandwidth:0,language:e.language,label:e.label,kind:e.kind||null,width:null,height:null,frameRate:null,pixelAspectRatio:null,hdr:null,colorGamut:null,videoLayout:null,mimeType:e.mimeType,audioMimeType:null,videoMimeType:null,codecs:e.codecs||null,audioCodec:null,videoCodec:null,primary:e.primary,roles:e.roles,audioRoles:null,forced:e.forced,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,originalTextId:e.originalId,originalImageId:null,accessibilityPurpose:e.accessibilityPurpose,originalLanguage:e.originalLanguage}}function fr(e){var t=e.width||null,n=e.height||null,i=null;e.segmentIndex&&(i=eu(e.segmentIndex));var r=e.tilesLayout;return i&&(r=i.tilesLayout||r),r&&null!=t&&(t/=Number(r.split("x")[0])),r&&null!=n&&(n/=Number(r.split("x")[1])),{id:e.id,active:!1,type:"image",bandwidth:e.bandwidth||0,language:"",label:null,kind:null,width:t,height:n,frameRate:null,pixelAspectRatio:null,hdr:null,colorGamut:null,videoLayout:null,mimeType:e.mimeType,audioMimeType:null,videoMimeType:null,codecs:e.codecs||null,audioCodec:null,videoCodec:null,primary:!1,roles:[],audioRoles:null,forced:!1,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:r||null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,originalTextId:null,originalImageId:e.originalId,accessibilityPurpose:null,originalLanguage:null}}function pr(e){return e.__shaka_id||(e.__shaka_id=Er++),e.__shaka_id}function gr(e){var t=vr(e);return t.active="disabled"!=e.mode,t.type="text",t.originalTextId=e.id,"captions"==e.kind&&(t.mimeType="unknown"),"subtitles"==e.kind&&(t.mimeType="text/vtt"),e.kind&&(t.roles=[e.kind]),"forced"==e.kind&&(t.forced=!0),t}function mr(e){var t=vr(e);return t.active=e.enabled,t.type="variant",t.originalAudioId=e.id,"main"==e.kind&&(t.primary=!0),e.kind&&(t.roles=[e.kind],t.audioRoles=[e.kind],t.label=e.label),t}function vr(e){var t=e.language;return{id:pr(e),active:!1,type:"",bandwidth:0,language:Yi(t||"und"),label:e.label,kind:e.kind,width:null,height:null,frameRate:null,pixelAspectRatio:null,hdr:null,colorGamut:null,videoLayout:null,mimeType:null,audioMimeType:null,videoMimeType:null,codecs:null,audioCodec:null,videoCodec:null,primary:!1,roles:[],forced:!1,audioRoles:null,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,originalTextId:null,originalImageId:null,accessibilityPurpose:null,originalLanguage:t}}function yr(e){return e.allowedByApplication&&e.allowedByKeySystem&&0==e.disabledUntilTime}function br(e){return e.filter((function(e){return yr(e)}))}function wr(e,t,n,i){var r=e,a=e.filter((function(e){return e.primary}));a.length&&(r=a);var o=r.length?r[0].language:"";if(r=r.filter((function(e){return e.language==o})),t){var s=Zi(Yi(t),e.map((function(e){return e.language})));s&&(r=e.filter((function(e){return Yi(e.language)==s})))}if(r=r.filter((function(e){return e.forced==i})),n){if((e=Tr(r,n)).length)return e}else if(e=r.filter((function(e){return 0==e.roles.length})),e.length)return e;return e=r.map((function(e){return e.roles})).reduce(Vi,[]),e.length?Tr(r,e[0]):r}function Tr(e,t){return e.filter((function(e){return e.roles.includes(t)}))}function Sr(e,t){t.length&&(t=t.filter((function(t){return Mi(e.codecs)==Mi(t.codecs)})).sort((function(e,t){return e.bandwidth&&t.bandwidth&&e.bandwidth!=t.bandwidth?e.bandwidth-t.bandwidth:(e.width||0)-(t.width||0)})),e.trickModeVideo=t[0],1<t.length&&(t=t.find((function(t){return e.width==t.width&&e.height==t.height}))))&&(e.trickModeVideo=t)}function xr(e){return"audio"==e.type?"type=audio codecs="+e.codecs+" bandwidth="+e.bandwidth+" channelsCount="+e.channelsCount+" audioSamplingRate="+e.audioSamplingRate:"video"==e.type?"type=video codecs="+e.codecs+" bandwidth="+e.bandwidth+" frameRate="+e.frameRate+" width="+e.width+" height="+e.height:"unexpected stream type"}F("shaka.util.StreamUtils",tr),tr.meetsRestrictions=ir;var Ar={},Er=0,kr=(new Map).set("image/svg+xml",!0).set("image/png",!0).set("image/jpeg",!0).set("image/jpg",!0),Ir=(new Map).set("image/webp","data:image/webp;base64,UklGRjoAAABXRUJQVlA4IC4AAACyAgCdASoCAAIALmk0mk0iIiIiIgBoSygABc6WWgAA/veff/0PP8bA//LwYAAA").set("image/avif","data:image/avif;base64,AAAAIGZ0eXBhdmlmAAAAAGF2aWZtaWYxbWlhZk1BMUIAAADybWV0YQAAAAAAAAAoaGRscgAAAAAAAAAAcGljdAAAAAAAAAAAAAAAAGxpYmF2aWYAAAAADnBpdG0AAAAAAAEAAAAeaWxvYwAAAABEAAABAAEAAAABAAABGgAAAB0AAAAoaWluZgAAAAAAAQAAABppbmZlAgAAAAABAABhdjAxQ29sb3IAAAAAamlwcnAAAABLaXBjbwAAABRpc3BlAAAAAAAAAAIAAAACAAAAEHBpeGkAAAAAAwgICAAAAAxhdjFDgQ0MAAAAABNjb2xybmNseAACAAIAAYAAAAAXaXBtYQAAAAAAAAABAAEEAQKDBAAAACVtZGF0EgAKCBgANogQEAwgMg8f8D///8WfhwB8+ErK42A=");function Mr(){var e=this;this.A=null,this.j=!1,this.i=new X,this.F=new Z,navigator.connection&&navigator.connection.addEventListener&&this.F.D(navigator.connection,"change",(function(){if(e.j&&e.g.useNetworkInformation){e.i=new X,e.g&&e.i.configure(e.g.advanced);var t=e.chooseVariant();t&&navigator.onLine&&e.A(t,e.g.clearBufferSwitch,e.g.safeMarginSwitch)}})),this.s=[],this.B=1,this.G=!1,this.h=this.o=this.g=this.l=null,this.C=new Be((function(){if(e.j&&e.g.restrictToElementSize){var t=e.chooseVariant();t&&e.A(t,e.g.clearBufferSwitch,e.g.safeMarginSwitch)}})),this.m=null}function Cr(e){if(!e.G){var t=e.i;if(!(t.g>=t.i))return;e.G=!0,e.l-=1e3*(e.g.switchInterval-e.g.minTimeToSwitch)}Date.now()-e.l<1e3*e.g.switchInterval||(t=e.chooseVariant(),e.getBandwidthEstimate(),t&&e.A(t,e.g.clearBufferSwitch,e.g.safeMarginSwitch))}function Dr(e,t,n,i,r){if(e.m){var a=e.m.Cg();a&&(n=n.filter((function(e){return!e.bandwidth||!a||e.bandwidth<=a})))}return t&&(n=n.filter((function(e){return ir(e,t,{width:r,height:i})}))),n.sort((function(e,t){return e.bandwidth-t.bandwidth}))}(i=Mr.prototype).stop=function(){this.A=null,this.j=!1,this.s=[],this.B=1,this.o=this.l=null,this.h&&(this.h.disconnect(),this.h=null),this.C.stop(),this.m=null},i.release=function(){this.F.release(),this.C=null},i.init=function(e){this.A=e},i.chooseVariant=function(){var t=1/0,n=1/0;if(this.g.restrictToScreenSize){var i=this.g.ignoreDevicePixelRatio?1:e.devicePixelRatio;t=e.screen.height*i,n=e.screen.width*i}this.h&&this.g.restrictToElementSize&&(i=this.g.ignoreDevicePixelRatio?1:e.devicePixelRatio,t=Math.min(t,this.o.clientHeight*i),n=Math.min(n,this.o.clientWidth*i)),(i=this.s.filter((function(e){return e&&!(e.audio&&e.audio.fastSwitching||e.video&&e.video.fastSwitching)}))).length||(i=this.s);var r=i;if(i.length!=this.s.length&&(r=this.s.filter((function(e){return e&&!!(e.audio&&e.audio.fastSwitching||e.video&&e.video.fastSwitching)}))),i=Dr(this,this.g.restrictions,r,1/0,1/0),1/0!=t||1/0!=n){i=function(e){for(var t=[],n=(e=l(e)).next();!n.done;n=e.next())(n=n.value.video)&&n.height&&n.width&&t.push({height:n.height,width:n.width});return t.sort((function(e,t){return e.width-t.width}))}(i);for(var a=(i=l(i)).next();!a.done;a=i.next())if((a=a.value).height>=t&&a.width>=n){t=a.height,n=a.width;break}i=Dr(this,this.g.restrictions,r,t,n)}for(t=this.getBandwidthEstimate(),r.length&&!i.length&&(i=[(i=Dr(this,null,r,1/0,1/0))[0]]),n=i[0]||null,r=0;r<i.length;r++){a=i[r];for(var o=isNaN(this.B)?1:Math.abs(this.B),s=o*a.bandwidth/this.g.bandwidthDowngradeTarget,u={bandwidth:1/0},c=r+1;c<i.length;c++)if(a.bandwidth!=i[c].bandwidth){u=i[c];break}o=o*u.bandwidth/this.g.bandwidthUpgradeTarget,t>=s&&t<=o&&(n.bandwidth!=a.bandwidth||n.bandwidth==a.bandwidth&&n.video&&a.video&&(n.video.width<a.video.width||n.video.height<a.video.height))&&(n=a)}return this.l=Date.now(),n},i.enable=function(){this.j=!0},i.disable=function(){this.j=!1},i.segmentDownloaded=function(e,t,n){e<this.g.cacheLoadThreshold||(this.i.sample(e,t),n&&null!=this.l&&this.j&&Cr(this))},i.trySuggestStreams=function(){null!=this.l&&this.j&&Cr(this)},i.getBandwidthEstimate=function(){var e=this.g.defaultBandwidthEstimate;return navigator.connection&&navigator.connection.downlink&&this.g.useNetworkInformation&&(e=1e6*navigator.connection.downlink),navigator.connection&&navigator.connection.downlink&&this.g.useNetworkInformation&&this.g.preferNetworkInformationBandwidth?e:(e=this.i.getBandwidthEstimate(e),this.m?this.m.getBandwidthEstimate(e):e)},i.setVariants=function(e){this.s=e},i.playbackRateChanged=function(e){this.B=e},i.setMediaElement=function(t){var n=this;this.o=t,this.h&&(this.h.disconnect(),this.h=null),this.o&&"ResizeObserver"in e&&(this.h=new ResizeObserver((function(){n.C.$(Rr)})),this.h.observe(this.o))},i.setCmsdManager=function(e){this.m=e},i.configure=function(e){this.g=e,this.i&&this.g&&this.i.configure(this.g.advanced)},F("shaka.abr.SimpleAbrManager",Mr),Mr.prototype.configure=Mr.prototype.configure,Mr.prototype.setCmsdManager=Mr.prototype.setCmsdManager,Mr.prototype.setMediaElement=Mr.prototype.setMediaElement,Mr.prototype.playbackRateChanged=Mr.prototype.playbackRateChanged,Mr.prototype.setVariants=Mr.prototype.setVariants,Mr.prototype.getBandwidthEstimate=Mr.prototype.getBandwidthEstimate,Mr.prototype.trySuggestStreams=Mr.prototype.trySuggestStreams,Mr.prototype.segmentDownloaded=Mr.prototype.segmentDownloaded,Mr.prototype.disable=Mr.prototype.disable,Mr.prototype.enable=Mr.prototype.enable,Mr.prototype.chooseVariant=Mr.prototype.chooseVariant,Mr.prototype.init=Mr.prototype.init,Mr.prototype.release=Mr.prototype.release,Mr.prototype.stop=Mr.prototype.stop;var Rr=1;function Pr(e,t,n){for(n=void 0===n||n,this.h=e,this.g=new Set([e]),t=(e=l(t=t||[])).next();!t.done;t=e.next())this.add(t.value,n)}function Lr(e,t){if(e.mimeType!=t.mimeType)return!1;if(e=e.codecs.split(",").map((function(e){return Ci(e)})),t=t.codecs.split(",").map((function(e){return Ci(e)})),e.length!=t.length)return!1;e.sort(),t.sort();for(var n=0;n<e.length;n++)if(e[n]!=t[n])return!1;return!0}function Nr(e,t){if(e=new Set(e),t=new Set(t),e.delete("main"),t.delete("main"),e.size!=t.size)return!1;for(var n=(e=l(e)).next();!n.done;n=e.next())if(!t.has(n.value))return!1;return!0}function jr(e,t){this.g=new Or(e.language,"",e.audio&&e.audio.channelsCount?e.audio.channelsCount:0,e.video&&e.video.hdr?e.video.hdr:"",!(!e.audio||!e.audio.spatialAudio)&&e.audio.spatialAudio,e.video&&e.video.videoLayout?e.video.videoLayout:"","","",t,e.audio&&e.audio.codecs?e.audio.codecs:"")}function Or(e,t,n,i,r,a,o,s,u,l){this.s=e,this.A=t,this.i=n,this.j=i,this.B=r,this.m=a,this.h=o,this.l=s,this.o=u,this.g=l}function Ur(){this.g=Fr,this.i=(new Map).set(Fr,2).set(Br,1),this.h=0}function _r(e,t,n){e.i.set(Fr,n).set(Br,t)}F("shaka.config.AutoShowText",{NEVER:0,ALWAYS:1,IF_PREFERRED_TEXT_LANGUAGE:2,IF_SUBTITLES_MAY_BE_NEEDED:3}),F("shaka.config.CodecSwitchingStrategy",{RELOAD:"reload",SMOOTH:"smooth"}),Pr.prototype.add=function(e,t){var n,i=this.h;if(t=void 0===t||t,!(n=!!i.audio!=!!e.audio||!!i.video!=!!e.video||i.language!=e.language)&&(n=i.audio&&e.audio)){n=i.audio;var r=e.audio;n=!(!((!n.channelsCount||!r.channelsCount||2<n.channelsCount||2<r.channelsCount)&&n.channelsCount!=r.channelsCount||n.spatialAudio!==r.spatialAudio||t&&!Lr(n,r))&&Nr(n.roles,r.roles)&&n.groupId===r.groupId)}return!n&&(n=i.video&&e.video)&&(i=i.video,n=e.video,n=!((!t||Lr(i,n))&&Nr(i.roles,n.roles))),!n&&(this.g.add(e),!0)},Pr.prototype.values=function(){return this.g.values()},jr.prototype.create=function(e){return this.g.create(e)},Or.prototype.create=function(t){var n=[];n=function(e,t){var n=Zi(t=Yi(t),e.map((function(e){return Qi(e)})));return n?e.filter((function(e){return n==Qi(e)})):[]}(t,this.s);var i=t.filter((function(e){return e.primary}));return t=function(e,t){return e.filter((function(e){return!!e.audio&&(t?e.audio.roles.includes(t):0==e.audio.roles.length)}))}(n=n.length?n:i.length?i:t,this.A),t.length&&(n=t),this.m&&(t=function(e,t){return e.filter((function(e){return!e.video||!e.video.videoLayout||e.video.videoLayout==t}))}(n,this.m),t.length&&(n=t)),this.j&&(t=function(t,n){return"AUTO"==n&&(n=e.matchMedia("(color-gamut: p3)").matches?t.some((function(e){return!(!e.video||!e.video.hdr||"HLG"!=e.video.hdr)}))?"HLG":"PQ":"SDR"),t.filter((function(e){return!e.video||!e.video.hdr||e.video.hdr==n}))}(n,this.j),t.length&&(n=t)),this.i&&(t=function(e,t){return e.filter((function(e){return!e.audio||!e.audio.channelsCount||e.audio.channelsCount==t}))}(n,this.i),t.length&&(n=t)),this.h&&(t=function(e,t){return e.filter((function(e){return!(!e.audio||!e.audio.label)&&e.audio.label.toLowerCase()==t.toLowerCase()}))}(n,this.h),t.length&&(n=t)),this.l&&(t=function(e,t){return e.filter((function(e){return!(!e.video||!e.video.label)&&e.video.label.toLowerCase()==t.toLowerCase()}))}(n,this.l),t.length&&(n=t)),t=function(e,t){return e.filter((function(e){return!e.audio||e.audio.spatialAudio==t}))}(n,this.B),t.length&&(n=t),this.g&&(t=function(e,t){return e.filter((function(e){return!e.audio||e.audio.codecs==t}))}(n,this.g),t.length&&(n=t)),new Pr(n[0],n,!("smooth"==this.o&&ie()))};var Br=0,Fr=1;function Vr(e,t){var n=2,i=1e3,r=2,a=.5;this.l=null==e.maxAttempts?n:e.maxAttempts,this.j=null==e.baseDelay?i:e.baseDelay,this.o=null==e.fuzzFactor?a:e.fuzzFactor,this.m=null==e.backoffFactor?r:e.backoffFactor,this.g=0,this.h=this.j,(this.i=void 0!==t&&t)&&(this.g=1)}function Hr(e){var t,n;return P((function(i){if(1==i.g){if(e.g>=e.l){if(!e.i)throw new De(2,7,1010);e.g=1,e.h=e.j}return t=e.g,e.g++,0==t?i.return():(n=e.h*(1+(2*Math.random()-1)*e.o),w(i,new Promise((function(e){new Be(e).$(n/1e3)})),2))}e.h*=e.m,T(i)}))}function Gr(){var e,t,n=new Promise((function(n,i){e=n,t=i}));return n.resolve=e,n.reject=t,n}function Kr(e,t){this.promise=e,this.i=t,this.g=null}function Xr(e){return new Kr(Promise.reject(e),(function(){return Promise.resolve()}))}function qr(){var e=Promise.reject(new De(2,7,7001));return e.catch((function(){})),new Kr(e,(function(){return Promise.resolve()}))}function zr(e){return new Kr(Promise.resolve(e),(function(){return Promise.resolve()}))}function Wr(e){return new Kr(e,(function(){return e.catch((function(){}))}))}function Yr(e){return new Kr(Promise.all(e.map((function(e){return e.promise}))),(function(){return Promise.all(e.map((function(e){return e.abort()})))}))}function Jr(t,n){if(n)if(n instanceof Map)for(var i=l(n.keys()),r=i.next();!r.done;r=i.next())r=r.value,Object.defineProperty(this,r,{value:n.get(r),writable:!0,enumerable:!0});else for(i in n)Object.defineProperty(this,i,{value:n[i],writable:!0,enumerable:!0});this.defaultPrevented=this.cancelable=this.bubbles=!1,this.timeStamp=e.performance&&e.performance.now?e.performance.now():Date.now(),this.type=t,this.isTrusted=!1,this.target=this.currentTarget=null,this.g=!1}function $r(e){var t,n=new Jr(e.type);for(t in e)Object.defineProperty(n,t,{value:e[t],writable:!0,enumerable:!0});return n}Gr.prototype.resolve=function(){},Gr.prototype.reject=function(){},Kr.prototype.abort=function(){return this.g||(this.g=this.i()),this.g},Kr.prototype.finally=function(e){return this.promise.then((function(){return e(!0)}),(function(){return e(!1)})),this},Kr.prototype.Ca=function(e,t){function n(n){return function(s){if(r.g&&n)a.reject(o);else{var u=n?e:t;u?i=function(e,t,n){try{var i=e(t);return i&&i.promise&&i.abort?(n.resolve(i.promise),function(){return i.abort()}):(n.resolve(i),function(){return Promise.resolve(i).then((function(){}),(function(){}))})}catch(e){return n.reject(e),function(){return Promise.resolve()}}}(u,s,a):(n?a.resolve:a.reject)(s)}}}function i(){return a.reject(o),r.abort()}var r=this,a=new Gr;a.catch((function(){}));var o=new De(2,7,7001);return this.promise.then(n(!0),n(!1)),new Kr(a,(function(){return i()}))},o.Object.defineProperties(Kr.prototype,{aborted:{configurable:!0,enumerable:!0,get:function(){return null!==this.g}}}),F("shaka.util.AbortableOperation",Kr),Kr.prototype.chain=Kr.prototype.Ca,Kr.prototype.finally=Kr.prototype.finally,Kr.all=Yr,Kr.prototype.abort=Kr.prototype.abort,Kr.notAbortable=Wr,Kr.completed=zr,Kr.aborted=qr,Kr.failed=Xr,Jr.prototype.preventDefault=function(){this.cancelable&&(this.defaultPrevented=!0)},Jr.prototype.stopImmediatePropagation=function(){this.g=!0},Jr.prototype.stopPropagation=function(){},F("shaka.util.FakeEvent",Jr);var Qr={mj:"abrstatuschanged",nj:"adaptation",oj:"audiotrackchanged",pj:"buffering",qj:"complete",rj:"downloadfailed",sj:"downloadheadersreceived",tj:"drmsessionupdate",vj:"emsg",Pj:"prft",Error:"error",wj:"expirationupdated",xj:"firstquartile",yj:"gapjumped",Bj:"keystatuschanged",Fj:"loaded",Gj:"loading",Ij:"manifestparsed",Jj:"manifestupdated",Kj:"mediaqualitychanged",Lj:"mediasourcerecovered",Metadata:"metadata",Mj:"midpoint",Nj:"nospatialvideoinfo",Oj:"onstatechange",Qj:"ratechange",Sj:"segmentappended",Tj:"sessiondata",Uj:"spatialvideoinfo",Vj:"stalldetected",Wj:"started",Xj:"statechanged",Yj:"streaming",Zj:"textchanged",$j:"texttrackvisibility",ak:"thirdquartile",bk:"timelineregionadded",ck:"timelineregionenter",dk:"timelineregionexit",ek:"trackschanged",gk:"unloading",ik:"variantchanged"};function Zr(){this.ra=new Q,this.re=this}function ea(){this.g=[]}function ta(e,t){e.g.push(t.finally((function(){Ie(e.g,t)})))}function na(e,t,n,i,r,a){Zr.call(this),this.i=!1,this.o=new ea,this.g=new Set,this.h=new Set,this.l=e||null,this.j=t||null,this.B=n||null,this.C=i||null,this.G=r||null,this.F=a||null,this.s=this.A=!1,this.m=16e3}function ia(e,t,n,i){n=n||da;var r=ha[e];(!r||n>=r.priority)&&(ha[e]={priority:n,he:t,Hi:void 0!==i&&i})}function ra(e,t){for(var n=l(e.g),i=n.next();!i.done;i=n.next())t.g.add(i.value);for(n=(e=l(e.h)).next();!n.done;n=e.next())t.h.add(n.value)}function aa(e,t,n){return{uris:e,method:"GET",body:null,headers:{},allowCrossSiteCredentials:!1,retryParameters:t,licenseRequestType:null,sessionId:null,drmInfo:null,initData:null,initDataType:null,streamDataCallback:void 0===n?null:n}}function oa(e,t,n,i,r,a,o,s){e.A&&(n.uris[a]=n.uris[a].replace("https://","http://")),e.s&&(n.uris[a]=n.uris[a].replace("http://","https://")),0<a&&e.G&&e.G(t,i,n.uris[a],n.uris[a-1]);var u=new Gn(n.uris[a]),l=u.Db,c=!1;l||(Kn(u,l=(l=location.protocol).slice(0,-1)),n.uris[a]=u.toString()),l=l.toLowerCase();var d=(l=ha[l])?l.he:null;if(!d)return Xr(new De(2,1,1e3,u));var h,f=l.Hi,p=null,g=null,m=!1,v=!1;return Wr(Hr(r)).Ca((function(){if(e.i)return qr();h=Date.now();var r=0;n.requestStartTime=Date.now();var o=d(n.uris[a],n,t,(function(a,o,u){p&&p.stop(),g&&g.$(l/1e3),e.l&&t==ca&&(r++,n.packetNumber=r,e.l(a,o,sa(i),n),c=!0,s.g=u)}),(function(i){v=!0,n.timeToFirstByte=Date.now()-n.requestStartTime,e.j&&e.j(i,n,t)}),{minBytesForProgressEvents:e.m});if(!f)return o;var u=n.retryParameters.connectionTimeout;u&&(p=new Be((function(){m=!0,o.abort()}))).$(u/1e3);var l=n.retryParameters.stallTimeout;return l&&(g=new Be((function(){m=!0,o.abort()}))),o})).Ca((function(i){p&&p.stop(),g&&g.stop(),null==i.timeMs&&(i.timeMs=Date.now()-h);var r={response:i,mi:c};return!v&&e.j&&e.j(i.headers,n,t),r}),(function(u){if(p&&p.stop(),g&&g.stop(),e.B){var l=null,c=0;u instanceof De&&(l=u,1001==u.code&&(c=u.data[1])),e.B(n,l,c,m)}if(e.i)return qr();if(m&&(u=new De(1,1,1003,n.uris[a],t)),u instanceof De){if(7001==u.code)throw u;if(1010==u.code)throw o;if(1==u.severity)return l=new Jr("retry",l=(new Map).set("error",u)),e.dispatchEvent(l),a=(a+1)%n.uris.length,oa(e,t,n,i,r,a,u,s)}throw u}))}function sa(e){if(e){var t=e.segment;if(e=e.stream,t&&e&&e.fastSwitching&&t.o)return!1}return!0}function ua(){this.g=0}function la(e,t,n){Kr.call(this,e,t),this.h=n}Zr.prototype.addEventListener=function(e,t){this.ra&&this.ra.push(e,t)},Zr.prototype.removeEventListener=function(e,t){this.ra&&this.ra.remove(e,t)},Zr.prototype.dispatchEvent=function(e){if(!this.ra)return!0;var t=this.ra.get(e.type)||[],n=this.ra.get("All");for(n&&(t=t.concat(n)),n=(t=l(t)).next();!n.done;n=t.next()){n=n.value,e.target=this.re,e.currentTarget=this.re;try{n.handleEvent?n.handleEvent(e):n.call(this,e)}catch(e){}if(e.g)break}return e.defaultPrevented},Zr.prototype.release=function(){this.ra=null},ea.prototype.destroy=function(){for(var e=[],t=l(this.g),n=t.next();!n.done;n=t.next())(n=n.value).promise.catch((function(){})),e.push(n.abort());return this.g=[],Promise.all(e)},m(na,Zr),(i=na.prototype).Tf=function(e){this.A=e},i.Uf=function(e){this.s=e},i.Ki=function(e){this.g.add(e)},i.fj=function(e){this.g.delete(e)},i.og=function(){this.g.clear()},i.Li=function(e){this.h.add(e)},i.gj=function(e){this.h.delete(e)},i.pg=function(){this.h.clear()},i.destroy=function(){return this.i=!0,this.g.clear(),this.h.clear(),Zr.prototype.release.call(this),this.o.destroy()},i.request=function(e,t,n){var i=this,r=new ua;if(this.i){var a=Promise.reject(new De(2,7,7001));return a.catch((function(){})),new la(a,(function(){return Promise.resolve()}),r)}t.method=t.method||"GET",t.headers=t.headers||{},t.retryParameters=t.retryParameters?kt(t.retryParameters):{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4},t.uris=kt(t.uris),a=function(e,t,n,i){function r(e){a=a.Ca((function(){return n.body&&(n.body=pe(n.body)),e(t,n,i)}))}var a=zr(void 0);e.C&&r(e.C);for(var o=(e=l(e.g)).next();!o.done;o=e.next())r(o.value);return a.Ca(void 0,(function(e){if(e instanceof De&&7001==e.code)throw e;throw new De(2,1,1006,e)}))}(this,e,t,n);var o=a.Ca((function(){return oa(i,e,t,n,new Vr(t.retryParameters,!1),0,null,r)})),s=o.Ca((function(t){return function(e,t,n,i){for(var r=zr(void 0),a=(e=l(e.h)).next(),o={};!a.done;o={Yg:void 0},a=e.next())o.Yg=a.value,r=r.Ca(function(e){return function(){var r=n.response;return r.data&&(r.data=pe(r.data)),(0,e.Yg)(t,r,i)}}(o));return r.Ca((function(){return n}),(function(e){var t=2;if(e instanceof De){if(7001==e.code)throw e;t=e.severity}throw new De(t,1,1007,e)}))}(i,e,t,n)})),u=Date.now(),c=0;a.promise.then((function(){c=Date.now()-u}),(function(){}));var d=0;o.promise.then((function(){d=Date.now()}),(function(){}));var h=s.Ca((function(r){var a=Date.now()-d,o=r.response;return o.timeMs+=c,o.timeMs+=a,r.mi||!i.l||o.fromCache||"HEAD"==t.method||e!=ca||i.l(o.timeMs,o.data.byteLength,sa(n)),i.F&&i.F(e,o,n),o}),(function(e){throw e&&(e.severity=2),e}));return a=new la(h.promise,(function(){return h.abort()}),r),ta(this.o,a),a},F("shaka.net.NetworkingEngine",na),na.prototype.request=na.prototype.request,na.prototype.destroy=na.prototype.destroy,na.makeRequest=aa,na.defaultRetryParameters=function(){return{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4}},na.prototype.clearAllResponseFilters=na.prototype.pg,na.prototype.unregisterResponseFilter=na.prototype.gj,na.prototype.registerResponseFilter=na.prototype.Li,na.prototype.clearAllRequestFilters=na.prototype.og,na.prototype.unregisterRequestFilter=na.prototype.fj,na.prototype.registerRequestFilter=na.prototype.Ki,na.unregisterScheme=function(e){delete ha[e]},na.registerScheme=ia,na.prototype.setForceHTTPS=na.prototype.Uf,na.prototype.setForceHTTP=na.prototype.Tf,na.NumBytesRemainingClass=ua,m(la,Kr),na.PendingRequest=la;var ca=1;na.RequestType={MANIFEST:0,SEGMENT:ca,LICENSE:2,APP:3,TIMING:4,SERVER_CERTIFICATE:5,KEY:6,ADS:7,CONTENT_STEERING:8},na.AdvancedRequestType={INIT_SEGMENT:0,MEDIA_SEGMENT:1,MEDIA_PLAYLIST:2,MASTER_PLAYLIST:3,MPD:4,MSS:5,MPD_PATCH:6,MEDIATAILOR_SESSION_INFO:7,MEDIATAILOR_TRACKING_INFO:8,MEDIATAILOR_STATIC_RESOURCE:9,MEDIATAILOR_TRACKING_EVENT:10,INTERSTITIAL_ASSET_LIST:11,INTERSTITIAL_AD_URL:12};var da=3;na.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:da};var ha={};function fa(e){this.g=!1,this.h=new Gr,this.i=e}function pa(e,t){if(e.g){if(t instanceof De&&7003==t.code)throw t;throw new De(2,7,7003,t)}}function ga(e,t){for(var n=[],i=(e=l(e)).next();!i.done;i=e.next())n.push(t(i.value));return n}function ma(e){for(var t=new Map,n=l(Object.keys(e)),i=n.next();!i.done;i=n.next())i=i.value,t.set(i,e[i]);return t}function va(e){var t={};return e.forEach((function(e,n){t[n]=e})),t}function ya(e,t){this.h=ve(e),this.i=t==wa,this.g=0}function ba(){return new De(2,3,3e3)}fa.prototype.destroy=function(){var e=this;return this.g?this.h:(this.g=!0,this.i().then((function(){e.h.resolve()}),(function(){e.h.resolve()})))},(i=ya.prototype).sa=function(){return this.g<this.h.byteLength},i.ya=function(){return this.g},i.getLength=function(){return this.h.byteLength},i.T=function(){try{var e=this.h.getUint8(this.g);return this.g+=1,e}catch(e){throw ba()}},i.ma=function(){try{var e=this.h.getUint16(this.g,this.i);return this.g+=2,e}catch(e){throw ba()}},i.P=function(){try{var e=this.h.getUint32(this.g,this.i);return this.g+=4,e}catch(e){throw ba()}},i.Vg=function(){try{var e=this.h.getInt32(this.g,this.i);return this.g+=4,e}catch(e){throw ba()}},i.Vc=function(){try{if(this.i)var e=this.h.getUint32(this.g,!0),t=this.h.getUint32(this.g+4,!0);else t=this.h.getUint32(this.g,!1),e=this.h.getUint32(this.g+4,!1)}catch(e){throw ba()}if(2097151<t)throw new De(2,3,3001);return this.g+=8,t*Math.pow(2,32)+e},i.vb=function(e){if(this.g+e>this.h.byteLength)throw ba();var t=ge(this.h,this.g,e);return this.g+=e,t},i.skip=function(e){if(this.g+e>this.h.byteLength)throw ba();this.g+=e},i.Si=function(e){if(this.g<e)throw ba();this.g-=e},i.seek=function(e){if(0>e||e>this.h.byteLength)throw ba();this.g=e},i.yc=function(){for(var e=this.g;this.sa()&&0!=this.h.getUint8(this.g);)this.g+=1;return e=ge(this.h,e,this.g-e),this.g+=1,dt(e)},F("shaka.util.DataViewReader",ya),ya.prototype.readTerminatedString=ya.prototype.yc,ya.prototype.seek=ya.prototype.seek,ya.prototype.rewind=ya.prototype.Si,ya.prototype.skip=ya.prototype.skip,ya.prototype.readBytes=ya.prototype.vb,ya.prototype.readUint64=ya.prototype.Vc,ya.prototype.readInt32=ya.prototype.Vg,ya.prototype.readUint32=ya.prototype.P,ya.prototype.readUint16=ya.prototype.ma,ya.prototype.readUint8=ya.prototype.T,ya.prototype.getLength=ya.prototype.getLength,ya.prototype.getPosition=ya.prototype.ya,ya.prototype.hasMoreData=ya.prototype.sa;var wa=1;function Ta(){this.i=[],this.h=[],this.g=!1}function Sa(e){for(var t=Ca(e);e.reader.sa()&&!e.parser.g;)e.parser.Sc(e.start+t,e.reader,e.partialOkay)}function xa(e){for(var t=Ca(e),n=e.reader.P(),i=0;i<n&&(e.parser.Sc(e.start+t,e.reader,e.partialOkay),!e.parser.g);i++);}function Aa(e){var t=Ca(e);for(e.reader.skip(78);e.reader.sa()&&!e.parser.g;)e.parser.Sc(e.start+t,e.reader,e.partialOkay)}function Ea(e){var t=Ca(e);e.reader.skip(8);var n=e.reader.ma();for(e.reader.skip(6),2==n?e.reader.skip(48):e.reader.skip(12),1==n&&e.reader.skip(16);e.reader.sa()&&!e.parser.g;)e.parser.Sc(e.start+t,e.reader,e.partialOkay)}function ka(e){return function(t){e(t.reader.vb(t.reader.getLength()-t.reader.ya()))}}function Ia(e){for(var t=0,n=(e=l(e)).next();!n.done;n=e.next())t=t<<8|n.value.charCodeAt(0);return t}function Ma(e){return String.fromCharCode(e>>24&255,e>>16&255,e>>8&255,255&e)}function Ca(e){return 8+(e.has64BitSize?8:0)+(null!=e.flags?4:0)}ya.Endianness={BIG_ENDIAN:0,LITTLE_ENDIAN:wa},(i=Ta.prototype).box=function(e,t){return e=Ia(e),this.i[e]=Da,this.h[e]=t,this},i.R=function(e,t){return e=Ia(e),this.i[e]=Ra,this.h[e]=t,this},i.stop=function(){this.g=!0},i.parse=function(e,t,n){for(e=new ya(e,0),this.g=!1;e.sa()&&!this.g;)this.Sc(0,e,t,n)},i.Sc=function(e,t,n,i){var r=t.ya();if(i&&r+8>t.getLength())this.g=!0;else{var a=t.P(),o=t.P(),s=Ma(o),u=!1;switch(a){case 0:a=t.getLength()-r;break;case 1:if(i&&t.ya()+8>t.getLength())return void(this.g=!0);a=t.Vc(),u=!0}var l=this.h[o];if(l){var c=null,d=null;if(this.i[o]==Ra){if(i&&t.ya()+4>t.getLength())return void(this.g=!0);c=(d=t.P())>>>24,d&=16777215}o=r+a,n&&o>t.getLength()&&(o=t.getLength()),i&&o>t.getLength()?this.g=!0:(i=o-t.ya(),l({name:s,parser:this,partialOkay:n||!1,version:c,flags:d,reader:t=new ya(t=0<i?t.vb(i):new Uint8Array(0),0),size:a,start:r+e,has64BitSize:u}))}else t.skip(Math.min(r+a-t.ya(),t.getLength()-t.ya()))}},F("shaka.util.Mp4Parser",Ta),Ta.headerSize=Ca,Ta.typeToString=Ma,Ta.allData=ka,Ta.audioSampleEntry=Ea,Ta.visualSampleEntry=Aa,Ta.sampleDescription=xa,Ta.children=Sa,Ta.prototype.parseNext=Ta.prototype.Sc,Ta.prototype.parse=Ta.prototype.parse,Ta.prototype.stop=Ta.prototype.stop,Ta.prototype.fullBox=Ta.prototype.R,Ta.prototype.box=Ta.prototype.box;var Da=0,Ra=1;function Pa(e){var t=this;this.g=[],this.h=[],this.data=[],(new Ta).box("moov",Sa).box("moof",Sa).R("pssh",(function(e){if(!(1<e.version)){var n=ge(e.reader.h,-12,e.size);if(t.data.push(n),t.g.push(ci(e.reader.vb(16))),0<e.version){n=e.reader.P();for(var i=0;i<n;i++){var r=ci(e.reader.vb(16));t.h.push(r)}}}})).parse(e)}function La(e,t,n,i){var r=e.length,a=t.length+16+r;0<i&&(a+=4+16*n.size);var o=new Uint8Array(a),s=ve(o),u=0;if(s.setUint32(u,a),u+=4,s.setUint32(u,1886614376),u+=4,1>i?s.setUint32(u,0):s.setUint32(u,16777216),u+=4,o.set(t,u),u+=t.length,0<i)for(s.setUint32(u,n.size),u+=4,n=(t=l(n)).next();!n.done;n=t.next())n=li(n.value),o.set(n,u),u+=n.length;return s.setUint32(u,r),o.set(e,u+4),o}function Na(e){var t=this;this.C=e,this.l=this.A=null,this.ja=this.fa=!1,this.H=0,this.g=null,this.o=new Z,this.i=new Map,this.Y=[],this.B=new Map,this.K=!1,this.m=new Gr,this.h=null,this.s=function(n){2==n.severity&&t.m.reject(n),e.onError(n)},this.aa=new Map,this.ga=new Map,this.L=new Be((function(){return function(e){var t=e.aa,n=e.ga;n.clear(),t.forEach((function(e,t){return n.set(t,e)})),(t=Array.from(n.values())).length&&t.every((function(e){return"expired"==e}))&&e.s(new De(2,6,6014)),e.C.ee(va(n))}(t)})),this.O=!1,this.M=[],this.Z=!1,this.I=new Be((function(){!function(e){e.i.forEach((function(t,n){var i=t.Df,r=n.expiration;isNaN(r)&&(r=1/0),r!=i&&(e.C.onExpirationUpdated(n.sessionId,r),t.Df=r)}))}(t)})),this.m.catch((function(){})),this.j=new fa((function(){return function(e){return P((function(t){switch(t.g){case 1:return e.o.release(),e.o=null,e.m.reject(),e.I.stop(),e.I=null,e.L.stop(),e.L=null,w(t,za(e),2);case 2:if(!e.l){t.u(3);break}return S(t,4),w(t,e.l.setMediaKeys(null),6);case 6:A(t,5);break;case 4:E(t);case 5:e.l=null;case 3:e.g=null,e.A=null,e.B=new Map,e.h=null,e.s=function(){},e.C=null,e.da=!1,e.G=null,T(t)}}))}(t)})),this.da=!1,this.F=this.G=null,this.S=function(){return!1}}function ja(e,t,n){e.B=new Map;for(var i=(n=l(n)).next();!i.done;i=n.next())e.B.set(i.value,{initData:null,initDataType:null});for(i=(n=l(e.h.persistentSessionsMetadata)).next();!i.done;i=n.next())i=i.value,e.B.set(i.sessionId,{initData:i.initData,initDataType:i.initDataType});return e.O=0<e.B.size,Oa(e,t)}function Oa(e,t){var n,i,r,a,o,s,u,c,d,h,f,p,g,m,v,y,b;return P((function(T){if(1==T.g){if(n=function(e){return 0==(e=ma(e.h.clearKeys)).size?null:pi(e)}(e))for(i=l(t),r=i.next();!r.done;r=i.next())(a=r.value).video&&(a.video.drmInfos=[n]),a.audio&&(a.audio.drmInfos=[n]);for((o=t.some((function(e){return!!(e.video&&e.video.drmInfos.length||e.audio&&e.audio.drmInfos.length)})))||(s=ma(e.h.servers),function(e,t){var n=[];for(t.forEach((function(e,t){n.push({keySystem:t,licenseServerUri:e,distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,serverCertificateUri:"",initData:[],keyIds:new Set})})),t=(e=l(e)).next();!t.done;t=e.next())(t=t.value).video&&(t.video.drmInfos=n),t.audio&&(t.audio.drmInfos=n)}(t,s)),u=new Set,c=l(t),d=c.next();!d.done;d=c.next())for(h=d.value,f=Wa(h),p=l(f),g=p.next();!g.done;g=p.next())m=g.value,u.add(m);for(v=l(u),y=v.next();!y.done;y=v.next())$a(y.value,ma(e.h.servers),ma(e.h.advanced||{}),e.h.keySystemsMapping);return w(T,sr(t,e.O,e.da,e.h.preferredKeySystems),2)}return pa(e.j),o||Object.keys(e.h.servers).length?(b=Va(e,void 0,t),T.return(o?b:b.catch((function(){})))):(e.fa=!0,T.return(Promise.resolve()))}))}function Ua(e){var t;return P((function(n){switch(n.g){case 1:if(e.l.mediaKeys)return n.return();if(!e.G){n.u(2);break}return w(n,e.G,3);case 3:return pa(e.j),n.return();case 2:return S(n,4),e.G=e.l.setMediaKeys(e.A),w(n,e.G,6);case 6:A(n,5);break;case 4:t=E(n),e.s(new De(2,6,6003,t.message));case 5:pa(e.j),T(n)}}))}function _a(e){var t,n,i,r;return P((function(a){if(1==a.g)return e.B.size?(e.B.forEach((function(t,n){Ka(e,n,t)})),w(a,e.m,3)):a.u(2);if(2!=a.g){if(0<(e.g&&e.g.keyIds||new Set([])).size&&function(e){for(var t=l(e.g&&e.g.keyIds||new Set([])),n=t.next();!n.done;n=t.next())if("usable"!==e.aa.get(n.value))return!1;return!0}(e))return a.return(e.m);e.K=!1,e.m=new Gr,e.m.catch((function(){}))}for(t=(e.g?e.g.initData:[])||[],n=l(t),i=n.next();!i.done;i=n.next())r=i.value,Ba(e,r.initDataType,r.initData);return Ya(e)&&e.m.resolve(),a.return(e.m)}))}function Ba(e,t,n){if(n.length){if(e.h.ignoreDuplicateInitData){for(var i=e.i.values(),r=(i=l(i)).next();!r.done;r=i.next())if(fe(n,r.value.initData))return;var a=!1;if(e.B.forEach((function(e){!a&&fe(n,e.initData)&&(a=!0)})),a)return}e.K=!0,0<e.i.size&&Ya(e)&&(e.m.resolve(),e.K=!1,e.m=new Gr,e.m.catch((function(){}))),function(e,t,n,i){try{var r=e.A.createSession(i)}catch(t){return void e.s(new De(2,6,6005,t.message))}e.o.D(r,"message",(function(t){e.l&&e.h.delayLicenseRequestUntilPlayed&&e.l.paused&&!e.Z?e.M.push(t):Xa(e,t)})),e.o.D(r,"keystatuseschange",(function(t){return qa(e,t)})),e.i.set(r,{initData:n,initDataType:t,loaded:!1,Df:1/0,nb:null,type:i});try{n=e.h.initDataTransform(n,t,e.g)}catch(n){return t=n,n instanceof De||(t=new De(2,6,6016,n)),void e.s(t)}e.h.logLicenseExchange&&si(n),r.generateRequest(t,n).catch((function(t){if(!e.j.g){e.i.delete(r);var n=t.errorCode;if(n&&n.systemCode){var i=n.systemCode;0>i&&(i+=Math.pow(2,32)),i="0x"+i.toString(16)}e.s(new De(2,6,6006,t.message,t,i))}}))}(e,t,n,e.g.sessionType)}}function Fa(e){return e=ga(e=e.i.keys(),(function(e){return e.sessionId})),Array.from(e)}function Va(e,t,n){var i,r,a,o,s,u,c;return P((function(d){switch(d.g){case 1:if(i=new Map,n.length){r=function(e,t,n){for(var i=l(t),r=i.next();!r.done;r=i.next())for(var a=(r=l(Wa(r.value))).next();!a.done;a=r.next())a=a.value,n.has(a.keySystem)||n.set(a.keySystem,[]),n.get(a.keySystem).push(a);if(1==n.size&&n.has(""))throw new De(2,6,6e3);for(a=(i=l(e.h.preferredKeySystems)).next(),r={};!a.done;r={Ug:void 0},a=i.next()){r.Ug=a.value;for(var o=(a=l(t)).next();!o.done;o=a.next())if(o=o.value.decodingInfos.find(function(e){return function(t){return t.supported&&null!=t.keySystemAccess&&t.keySystemAccess.keySystem==e.Ug}}(r)))return o.keySystemAccess}for(r=(i=l([!0,!1])).next();!r.done;r=i.next())for(r=r.value,o=(a=l(t)).next();!o.done;o=a.next())for(var s=(o=l(o.value.decodingInfos)).next();!s.done;s=o.next())if((s=s.value).supported&&s.keySystemAccess){var u=s.keySystemAccess.keySystem,c=n.get(u);for(!c&&e.h.keySystemsMapping[u]&&(c=n.get(e.h.keySystemsMapping[u])),c=(u=l(c)).next();!c.done;c=u.next())if(!!c.value.licenseServerUri==r)return s.keySystemAccess}return null}(e,n,i),d.u(2);break}return w(d,function(e,t){var n,i,r,a,o,s,u,c,d,h,f,p,g,m,v,y;return P((function(b){switch(b.g){case 1:if(1==t.size&&t.has(""))throw new De(2,6,6e3);for(i=l(t.values()),r=i.next();!r.done;r=i.next())0==(a=r.value).audioCapabilities.length&&delete a.audioCapabilities,0==a.videoCapabilities.length&&delete a.videoCapabilities;o=l(e.h.preferredKeySystems),s=o.next();case 2:if(s.done){b.u(4);break}if(u=s.value,!t.has(u)){b.u(3);break}return c=t.get(u),S(b,6),w(b,navigator.requestMediaKeySystemAccess(u,[c]),8);case 8:return n=b.h,b.return(n);case 6:E(b);case 7:pa(e.j);case 3:s=o.next(),b.u(2);break;case 4:d=l([!0,!1]),h=d.next();case 9:if(h.done){b.u(11);break}f=h.value,p=l(t.keys()),g=p.next();case 12:if(g.done){h=d.next(),b.u(9);break}if(m=g.value,v=t.get(m),y=v.drmInfos.some((function(e){return!!e.licenseServerUri})),y!=f){b.u(13);break}return S(b,15),w(b,navigator.requestMediaKeySystemAccess(m,[v]),17);case 17:return n=b.h,b.return(n);case 15:E(b);case 16:pa(e.j);case 13:g=p.next(),b.u(12);break;case 11:return b.return(n)}}))}(e,t),3);case 3:r=d.h;case 2:if(!(a=r))throw new De(2,6,6001);if(pa(e.j),S(d,4),a.getConfiguration(),o=e.h.keySystemsMapping[a.keySystem]||a.keySystem,n.length){var h=o,f=i.get(o),p=[],g=[],m=[],v=[],y=[],b=new Set,T=new Set;Ja(f,p,g,v,m,y,b,T);var x=e.O?"persistent-license":"temporary";for(h={keySystem:h,encryptionScheme:p[0],licenseServerUri:g[0],distinctiveIdentifierRequired:f[0].distinctiveIdentifierRequired,persistentStateRequired:f[0].persistentStateRequired,sessionType:f[0].sessionType||x,audioRobustness:f[0].audioRobustness||"",videoRobustness:f[0].videoRobustness||"",serverCertificate:v[0],serverCertificateUri:m[0],initData:y,keyIds:b},0<T.size&&(h.keySystemUris=T),T=(f=l(f)).next();!T.done;T=f.next())(T=T.value).distinctiveIdentifierRequired&&(h.distinctiveIdentifierRequired=T.distinctiveIdentifierRequired),T.persistentStateRequired&&(h.persistentStateRequired=T.persistentStateRequired);f=h}else f=o,T=t.get(o),h=[],p=[],g=[],m=[],v=[],y=new Set,Ja(T.drmInfos,h,p,m,g,v,y),f={keySystem:f,encryptionScheme:h[0],licenseServerUri:p[0],distinctiveIdentifierRequired:"required"==T.distinctiveIdentifier,persistentStateRequired:"required"==T.persistentState,sessionType:T.sessionTypes[0]||"temporary",audioRobustness:(T.audioCapabilities?T.audioCapabilities[0].robustness:"")||"",videoRobustness:(T.videoCapabilities?T.videoCapabilities[0].robustness:"")||"",serverCertificate:m[0],serverCertificateUri:g[0],initData:v,keyIds:y};if(e.g=f,!e.g.licenseServerUri)throw new De(2,6,6012,e.g.keySystem);return w(d,a.createMediaKeys(),6);case 6:if(s=d.h,pa(e.j),e.A=s,""==e.h.minHdcpVersion||!("getStatusForPolicy"in e.A)){d.u(7);break}return S(d,8),w(d,e.A.getStatusForPolicy({minHdcpVersion:e.h.minHdcpVersion}),10);case 10:if("usable"!=d.h)throw new De(2,6,6018);pa(e.j),A(d,7,4);break;case 8:if((u=E(d,4))instanceof De)throw u;throw new De(2,6,6019,u.message);case 7:return e.fa=!0,w(d,function(e){var t,n;return P((function(i){switch(i.g){case 1:if(!e.A||!e.g)return i.return();if(!e.g.serverCertificateUri||e.g.serverCertificate&&e.g.serverCertificate.length){i.u(2);break}return t=aa([e.g.serverCertificateUri],e.h.retryParameters),S(i,3),w(i,e.C.Nb.request(5,t,{isPreload:e.S()}).promise,5);case 5:n=i.h,e.g.serverCertificate=ge(n.data),A(i,4);break;case 3:throw new De(2,6,6017,E(i));case 4:if(e.j.g)return i.return();case 2:return e.g.serverCertificate&&e.g.serverCertificate.length?(S(i,6),w(i,e.A.setServerCertificate(e.g.serverCertificate),8)):i.return();case 8:A(i,0);break;case 6:throw new De(2,6,6004,E(i).message)}}))}(e),11);case 11:pa(e.j),A(d,0);break;case 4:if(c=E(d),pa(e.j,c),e.g=null,c instanceof De)throw c;throw new De(2,6,6002,c.message)}}))}function Ha(e){Ya(e)&&e.m.resolve()}function Ga(e,t){new Be((function(){t.loaded=!0,Ha(e)})).$(Za)}function Ka(e,t,n){var i,r,a,o,s,u,l;return P((function(c){switch(c.g){case 1:try{i=e.A.createSession("persistent-license")}catch(t){return r=new De(2,6,6005,t.message),e.s(r),c.return(Promise.reject(r))}return e.o.D(i,"message",(function(t){e.l&&e.h.delayLicenseRequestUntilPlayed&&e.l.paused&&!e.Z?e.M.push(t):Xa(e,t)})),e.o.D(i,"keystatuseschange",(function(t){return qa(e,t)})),a={initData:n.initData,initDataType:n.initDataType,loaded:!1,Df:1/0,nb:null,type:"persistent-license"},e.i.set(i,a),S(c,2),w(c,i.load(t),4);case 4:return o=c.h,pa(e.j),o||(e.i.delete(i),s=e.h.persistentSessionOnlinePlayback?1:2,e.s(new De(s,6,6013)),a.loaded=!0),Ga(e,a),Ha(e),c.return(i);case 2:u=E(c),pa(e.j,u),e.i.delete(i),l=e.h.persistentSessionOnlinePlayback?1:2,e.s(new De(l,6,6005,u.message)),a.loaded=!0,Ha(e);case 3:return c.return(Promise.resolve())}}))}function Xa(e,t){var n,i,r,a,o,s,u,c,d,h,f,p,g,m;P((function(v){switch(v.g){case 1:if(n=t.target,e.h.logLicenseExchange&&si(t.message),i=e.i.get(n),r=e.g.licenseServerUri,a=e.h.advanced[e.g.keySystem],"individualization-request"==t.messageType&&a&&a.individualizationServer&&(r=a.individualizationServer),(o=aa([r],e.h.retryParameters)).body=t.message,o.method="POST",o.licenseRequestType=t.messageType,o.sessionId=n.sessionId,o.drmInfo=e.g,i&&(o.initData=i.initData,o.initDataType=i.initDataType),a&&a.headers)for(s in a.headers)o.headers[s]=a.headers[s];if(je(e.g.keySystem)){var y=ht(o.body,!0,!0);if(y.includes("PlayReadyKeyMessage")){for(var b=Ut(y=Dt(y,"PlayReadyKeyMessage"),"HttpHeader"),x=(b=l(b)).next();!x.done;x=b.next()){var k=x.value;x=Ut(k,"name")[0],k=Ut(k,"value")[0],o.headers[jt(x)]=jt(k)}y=Ut(y,"Challenge")[0],o.body=ui(jt(y))}else o.headers["Content-Type"]="text/xml; charset=utf-8"}return u=Date.now(),S(v,2),d=e.C.Nb.request(2,o,{isPreload:e.S()}),e.Y.push(d),w(v,d.promise,4);case 4:c=v.h,Ie(e.Y,d),A(v,3);break;case 2:return h=E(v),e.j.g||(f=new De(2,6,6007,h),1==e.i.size?(e.s(f),i&&i.nb&&i.nb.reject(f)):(i&&i.nb&&i.nb.reject(f),e.i.delete(n),Ya(e)&&(e.m.resolve(),e.L.$(.1)))),v.return();case 3:return e.j.g?v.return():(e.H+=(Date.now()-u)/1e3,e.h.logLicenseExchange&&si(c.data),S(v,5),w(v,n.update(c.data),7));case 7:A(v,6);break;case 5:return p=E(v),g=new De(2,6,6008,p.message),e.s(g),i&&i.nb&&i.nb.reject(g),v.return();case 6:if(e.j.g)return v.return();m=new Jr("drmsessionupdate"),e.C.onEvent(m),i&&(i.nb&&i.nb.resolve(),Ga(e,i)),T(v)}}))}function qa(e,t){t=t.target;var n=e.i.get(t),i=!1;t.keyStatuses.forEach((function(t,r){if("string"==typeof r){var a=r;r=t,t=a}if(je(e.g.keySystem)&&16==r.byteLength&&(He()||$e())){var o=(a=ve(r)).getUint32(0,!0),s=a.getUint16(4,!0),u=a.getUint16(6,!0);a.setUint32(0,o,!1),a.setUint16(4,s,!1),a.setUint16(6,u,!1)}"status-pending"!=t&&(n.loaded=!0),"expired"==t&&(i=!0),r=ci(r).slice(0,32),e.aa.set(r,t)}));var r=t.expiration-Date.now();(0>r||i&&1e3>r)&&n&&!n.nb&&(e.i.delete(t),t.close().catch((function(){}))),Ya(e)&&(e.m.resolve(),e.L.$(eo))}function za(e){var t;return P((function(n){return t=Array.from(e.i.entries()),e.i.clear(),w(n,Promise.all(t.map((function(t){var n=(t=l(t)).next().value,i=t.next().value;return P((function(t){return 1==t.g?(S(t,2),e.ja||e.B.has(n.sessionId)||"persistent-license"!==i.type||e.h.persistentSessionOnlinePlayback?w(t,function(e){return P((function(t){return 1==t.g?(S(t,2),w(t,Ki(Qa,Promise.all([e.close(),e.closed])),4)):2!=t.g?A(t,0):(E(t),void T(t))}))}(n),5):w(t,n.remove(),5)):2!=t.g?A(t,0):(E(t),void T(t))}))}))),0)}))}function Wa(e){return(e.video?e.video.drmInfos:[]).concat(e.audio?e.audio.drmInfos:[])}function Ya(e){return function(e,t){for(var n=(e=l(e)).next();!n.done;n=e.next())if(!t(n.value))return!1;return!0}(e=e.i.values(),(function(e){return e.loaded}))}function Ja(t,n,i,r,a,o,s,u){for(var d=[],h=(t=l(t)).next(),f={};!h.done;f={ua:void 0},h=t.next()){if(f.ua=h.value,n.includes(f.ua.encryptionScheme)||n.push(f.ua.encryptionScheme),"org.w3.clearkey"==f.ua.keySystem&&f.ua.licenseServerUri.startsWith("data:application/json;base64,")?d.includes(f.ua.licenseServerUri)||d.push(f.ua.licenseServerUri):i.includes(f.ua.licenseServerUri)||i.push(f.ua.licenseServerUri),a.includes(f.ua.serverCertificateUri)||a.push(f.ua.serverCertificateUri),f.ua.serverCertificate&&(r.some(function(e){return function(t){return fe(t,e.ua.serverCertificate)}}(f))||r.push(f.ua.serverCertificate)),f.ua.initData)for(var p=(h=l(f.ua.initData)).next(),g={};!p.done;g={qf:void 0},p=h.next())g.qf=p.value,o.some(function(e){return function(t){var n=e.qf;return!(!t.keyId||t.keyId!=n.keyId)||t.initDataType==n.initDataType&&fe(t.initData,n.initData)}}(g))||o.push(g.qf);if(f.ua.keyIds)for(p=(h=l(f.ua.keyIds)).next();!p.done;p=h.next())s.add(p.value);if(f.ua.keySystemUris&&u)for(h=(f=l(f.ua.keySystemUris)).next();!h.done;h=f.next())u.add(h.value)}if(1==d.length)i.push(d[0]);else if(0<d.length){for(n=[],r=(d=l(d)).next();!r.done;r=d.next())r=e.atob(r.value.split("data:application/json;base64,").pop()),r=JSON.parse(r),n.push.apply(n,c(r.keys));d=JSON.stringify({keys:n}),i.push("data:application/json;base64,"+e.btoa(d))}}function $a(t,n,i,r){var a=t.keySystem;!a||"org.w3.clearkey"==a&&t.licenseServerUri||(n.size&&(n=n.get(a)||"",t.licenseServerUri=n),t.keyIds||(t.keyIds=new Set),(i=i.get(a))&&(t.distinctiveIdentifierRequired||(t.distinctiveIdentifierRequired=i.distinctiveIdentifierRequired),t.persistentStateRequired||(t.persistentStateRequired=i.persistentStateRequired),t.videoRobustness||(t.videoRobustness=i.videoRobustness),t.audioRobustness||(t.audioRobustness=i.audioRobustness),t.serverCertificate||(t.serverCertificate=i.serverCertificate),i.sessionType&&(t.sessionType=i.sessionType),t.serverCertificateUri||(t.serverCertificateUri=i.serverCertificateUri)),r[a]&&(t.keySystem=r[a]),e.cast&&e.cast.__platform__&&"com.microsoft.playready"==a&&(t.keySystem="com.chromecast.playready"))}(i=Na.prototype).destroy=function(){return this.j.destroy()},i.configure=function(e,t){this.h=e,t&&(this.S=t),this.I&&this.I.Ra(this.h.updateExpirationTime)},i.Tb=function(e){var t=this;return P((function(n){if(1==n.g)return t.A?(t.l=e,t.o.pa(t.l,"play",(function(){for(var e=l(t.M),n=e.next();!n.done;n=e.next())Xa(t,n.value);t.Z=!0,t.M=[]})),t.l.remote?(t.o.D(t.l.remote,"connect",(function(){return za(t)})),t.o.D(t.l.remote,"connecting",(function(){return za(t)})),t.o.D(t.l.remote,"disconnect",(function(){return za(t)}))):"webkitCurrentPlaybackTargetIsWireless"in t.l&&t.o.D(t.l,"webkitcurrentplaybacktargetiswirelesschanged",(function(){return za(t)})),t.F=t.g&&t.g.initData.find((function(e){return 0<e.initData.length}))||null,t.F||"com.apple.fps"!==t.g.keySystem||t.B.size?w(n,Ua(t),2):n.u(2)):(t.o.pa(e,"encrypted",(function(){t.s(new De(2,6,6010))})),n.return());_a(t).catch((function(){})),t.F||t.B.size||t.h.parseInbandPsshEnabled||t.o.D(t.l,"encrypted",(function(e){return function(e,t){return P((function(n){if(1==n.g)return w(n,Ua(e),2);Ba(e,t.initDataType,ge(t.initData)),T(n)}))}(t,e)})),T(n)}))},i.jf=function(){var e=this,t=this.i.keys();return t=ga(t,(function(t){var n=e.i.get(t);return{sessionId:t.sessionId,sessionType:n.type,initData:n.initData,initDataType:n.initDataType}})),Array.from(t)},i.gd=function(){for(var e=1/0,t=this.i.keys(),n=(t=l(t)).next();!n.done;n=t.next())n=n.value,isNaN(n.expiration)||(e=Math.min(e,n.expiration));return e},i.Od=function(){return va(this.ga)};var Qa=1,Za=5,eo=.5;function to(e,t,n){this.g=e,this.i=t,this.h=n}function no(e,t){return P((function(n){if(1==n.g)return w(n,function(e,t,n,i){return n=void 0===n?[]:n,i=void 0===i?{}:i,P((function(r){return 1==r.g?w(r,rr(e,t,0<t.offlineSessionIds.length,n,i),2):(function(e){e.textStreams=e.textStreams.filter((function(e){return Ui(e=xi(e.mimeType,e.codecs))}))}(t),w(r,function(e){var t,n,i,r,a,o,s;return P((function(u){switch(u.g){case 1:t=[],n=l(e.imageStreams),i=n.next();case 2:if(i.done){u.u(4);break}if(r=i.value,"application/mp4"==(a=r.mimeType)&&"mjpg"==r.codecs&&(a="image/jpg"),kr.has(a)){u.u(5);break}if(!(o=Ir.get(a))){kr.set(a,!1),u.u(5);break}return w(u,function(e){return new Promise((function(t){var n=new Image;n.src=e,"decode"in n?n.decode().then((function(){t(!0)})).catch((function(){t(!1)})):n.onload=n.onerror=function(){t(2===n.height)}}))}(o),7);case 7:s=u.h,kr.set(a,s);case 5:kr.get(a)&&t.push(r),i=n.next(),u.u(2);break;case 4:e.imageStreams=t,T(u)}}))}(t),0))}))}(e.h,t,e.g.drm.preferredKeySystems,e.g.drm.keySystemsMapping),2);if(e.g.streaming.dontChooseCodecs||nr(t,e.g.preferredVideoCodecs,e.g.preferredAudioCodecs,e.g.preferredDecodingAttributes,e.g.preferredTextFormats),!t.variants.some(yr))throw new De(2,4,4032);return n.return(ro(e,t))}))}function io(e,t){var n=e.g.restrictions;e=e.i;for(var i=!1,r=(t=l(t.variants)).next();!r.done;r=t.next()){var a=(r=r.value).allowedByApplication;r.allowedByApplication=ir(r,n,e),a!=r.allowedByApplication&&(i=!0)}return i}function ro(e,t){var n=io(e,t);if(t){var i=e.h?e.h.g:null;if(i&&e.h.A)for(var r=l(t.variants),a=r.next();!a.done;a=r.next())a=a.value,ao(e,i.keySystem,a.video),ao(e,i.keySystem,a.audio);oo(e,t)}return n}function ao(e,t,n){if(n)for(var i=(n=l(n.drmInfos)).next();!i.done;i=n.next())if((i=i.value).keySystem==t)for(var r=(i=l(i.initData||[])).next();!r.done;r=i.next())r=r.value,Ba(e.h,r.initDataType,r.initData)}function oo(e,t){e=e.h?e.h.Od():{};var n=Object.keys(e);n=n.length&&"00"==n[0];for(var i=!1,r=!1,a=new Set,o=new Set,s=(t=l(t.variants)).next();!s.done;s=t.next()){var u=[];(s=s.value).audio&&u.push(s.audio),s.video&&u.push(s.video);for(var c=(u=l(u)).next();!c.done;c=u.next())if((c=c.value).keyIds.size)for(var d=(c=l(c.keyIds)).next();!d.done;d=c.next()){d=d.value;var h=e[n?"00":d];h?so.includes(h)&&o.add(h):a.add(d)}s.allowedByApplication?s.allowedByKeySystem&&(i=!0):r=!0}if(!i)throw new De(2,4,4012,e={hasAppRestrictions:r,missingKeys:Array.from(a),restrictedKeyStatuses:Array.from(o)})}var so=["output-restricted","internal-error"];function uo(){}function lo(e,t){if(t){var n=co[t.toLowerCase()];if(n)return n}throw new De(2,4,4e3,e,t)}F("shaka.media.ManifestParser",uo),uo.unregisterParserByMime=function(e){delete co[e]},uo.registerParserByMime=function(e,t){co[e]=t},uo.registerParserByExtension=function(){oe("ManifestParser.registerParserByExtension","Please use an ManifestParser with registerParserByMime function.")},uo.AccessibilityPurpose={hk:"visually impaired",zj:"hard of hearing"};var co={};function ho(e,t,n,i,r){var a=po.value(),o=e.subarray(n.start,n.start+n.size),s=ve(o),u=new Uint8Array(n.size+a.byteLength);for(u.set(o,0),(o=ve(u)).setUint32(4,r),u.set(a,n.size),r=s.getUint32(4),o.setUint32(n.size+16,r),fo(u,0,u.byteLength),r=new Uint8Array(e.byteLength+u.byteLength),n=Ge()||He()?n.start:n.start+n.size,a=e.subarray(n),r.set(e.subarray(0,n)),r.set(u,n),r.set(a,n+u.byteLength),i=(e=l(i)).next();!i.done;i=e.next())fo(r,(i=i.value).start,i.size+u.byteLength);return u=ve(r,t.start),t=Ca(t),e=u.getUint32(t),u.setUint32(t,e+1),r}function fo(e,t,n){0!=(t=(e=ve(e,t)).getUint32(0))&&(1==t?(e.setUint32(8,n>>32),e.setUint32(12,4294967295&n)):e.setUint32(0,n))}var po=new Pe((function(){return new Uint8Array([0,0,0,80,115,105,110,102,0,0,0,12,102,114,109,97,0,0,0,0,0,0,0,20,115,99,104,109,0,0,0,0,99,101,110,99,0,1,0,0,0,0,0,40,115,99,104,105,0,0,0,32,116,101,110,99,0,0,0,0,0,0,1,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0])}));function go(e,t,n,i,r,a,o){this.N=e,this.Ja=t,this.va=n,this.Qc=void 0===i?null:i,this.timescale=void 0===r?null:r,this.g=void 0===a?null:a,this.aesKey=void 0===o?null:o,this.mimeType=this.codecs=null}function mo(e,t){return e===t||(e&&t?e.Zb()==t.Zb()&&e.Xb()==t.Xb()&&Ce(e.N().sort(),t.N().sort())&&fe(e.pc(),t.pc()):e==t)}function vo(e,t,n,i,r,a,o,s,u,c,d,h,f,p,g,m){for(c=void 0===c?[]:c,p=void 0===p?bo:p,this.startTime=e,this.j=this.endTime=t,this.C=n,this.Ja=i,this.va=r,this.ba=a,this.timestampOffset=o,this.appendWindowStart=s,this.appendWindowEnd=u,this.g=c,this.tilesLayout=void 0===d?"":d,this.A=void 0===h?null:h,this.h=void 0===f?null:f,this.status=p,this.preload=!1,this.l=!0,this.m=!1,this.aesKey=void 0===g?null:g,this.thumbnailSprite=null,this.i=-1,this.s=void 0!==m&&m,this.F=this.o=!1,t=(e=l(this.g)).next();!t.done;t=e.next())t.value.Ng();this.s&&this.g.length&&this.g[this.g.length-1].Mg(),this.B=this.bandwidth=this.mimeType=this.codecs=null}function yo(e,t){e.ba=t;for(var n=(e=l(e.g)).next();!n.done;n=e.next())yo(n.value,t)}go.prototype.Zb=function(){return this.Ja},go.prototype.Xb=function(){return this.va},go.prototype.pc=function(){return this.g},F("shaka.media.InitSegmentReference",go),go.prototype.getEndByte=go.prototype.Xb,go.prototype.getStartByte=go.prototype.Zb,(i=vo.prototype).N=function(){return this.C()},i.getStartTime=function(){return this.startTime},i.Ph=function(){return this.endTime},i.Zb=function(){return this.Ja},i.Xb=function(){return this.va},i.hi=function(){return this.tilesLayout},i.gi=function(){return this.A},i.$b=function(){return this.status},i.Ai=function(){this.status=wo},i.Af=function(){this.preload=!0},i.isPreload=function(){return this.preload},i.Pc=function(){this.l=!1},i.si=function(){return this.l},i.Ng=function(){this.o=!0},i.ui=function(){return this.o},i.Mg=function(){this.F=!0},i.ti=function(){return this.F},i.Lg=function(){this.m=!0},i.ni=function(){return this.m},i.qe=function(e){this.thumbnailSprite=e},i.fi=function(){return this.thumbnailSprite},i.offset=function(e){this.startTime+=e,this.endTime+=e,this.j+=e;for(var t=l(this.g),n=t.next();!n.done;n=t.next())(n=n.value).startTime+=e,n.endTime+=e,n.j+=e},i.Yf=function(e){null==this.h?z("Sync attempted without sync time!"):(e=this.h-e-this.startTime,.001<=Math.abs(e)&&this.offset(e))},i.cj=function(e){this.B=e},i.pc=function(){return this.B},F("shaka.media.SegmentReference",vo),vo.prototype.getSegmentData=vo.prototype.pc,vo.prototype.setSegmentData=vo.prototype.cj,vo.prototype.syncAgainst=vo.prototype.Yf,vo.prototype.offset=vo.prototype.offset,vo.prototype.getThumbnailSprite=vo.prototype.fi,vo.prototype.setThumbnailSprite=vo.prototype.qe,vo.prototype.hasByterangeOptimization=vo.prototype.ni,vo.prototype.markAsByterangeOptimization=vo.prototype.Lg,vo.prototype.isLastPartial=vo.prototype.ti,vo.prototype.markAsLastPartial=vo.prototype.Mg,vo.prototype.isPartial=vo.prototype.ui,vo.prototype.markAsPartial=vo.prototype.Ng,vo.prototype.isIndependent=vo.prototype.si,vo.prototype.markAsNonIndependent=vo.prototype.Pc,vo.prototype.isPreload=vo.prototype.isPreload,vo.prototype.markAsPreload=vo.prototype.Af,vo.prototype.markAsUnavailable=vo.prototype.Ai,vo.prototype.getStatus=vo.prototype.$b,vo.prototype.getTileDuration=vo.prototype.gi,vo.prototype.getTilesLayout=vo.prototype.hi,vo.prototype.getEndByte=vo.prototype.Xb,vo.prototype.getStartByte=vo.prototype.Zb,vo.prototype.getEndTime=vo.prototype.Ph,vo.prototype.getStartTime=vo.prototype.getStartTime,vo.prototype.getUris=vo.prototype.N;var bo=0,wo=1;function To(e){return 1==e.length&&1e-4>e.end(0)-e.start(0)}function So(e){return!e||To(e)?null:e.length?e.end(e.length-1):null}function xo(e,t){return!(!e||!e.length||To(e)||t>e.end(e.length-1))&&t>=e.start(0)}function Ao(e,t){if(!e||!e.length||To(e))return 0;for(var n=0,i=(e=l(Eo(e))).next();!i.done;i=e.next()){var r=i.value;i=r.start,(r=r.end)>t&&(n+=r-Math.max(i,t))}return n}function Eo(e){if(!e)return[];for(var t=[],n=0;n<e.length;n++)t.push({start:e.start(n),end:e.end(n)});return t}function ko(){}function Io(e,t){var n=document.createElement("source");return n.src=e,n.type=void 0===t?"":t,n}function Mo(e){for(;e.firstChild;)e.removeChild(e.firstChild)}function Co(){}function Do(e,t){return t+10<=e.length&&73===e[t]&&68===e[t+1]&&51===e[t+2]&&255>e[t+3]&&255>e[t+4]&&128>e[t+6]&&128>e[t+7]&&128>e[t+8]&&128>e[t+9]}function Ro(e,t){return t+10<=e.length&&51===e[t]&&68===e[t+1]&&73===e[t+2]&&255>e[t+3]&&255>e[t+4]&&128>e[t+6]&&128>e[t+7]&&128>e[t+8]&&128>e[t+9]}function Po(e,t){var n=(127&e[t])<<21;return n|=(127&e[t+1])<<14,(n|=(127&e[t+2])<<7)|127&e[t+3]}function Lo(e){var t={key:e.type,description:"",data:"",mimeType:null,pictureType:null};if("APIC"===e.type){if(2>e.size||3!==e.data[0])return null;var n=e.data.subarray(1).indexOf(0);if(-1===n)return null;var i=dt(ge(e.data,1,n)),r=e.data[2+n],a=e.data.subarray(3+n).indexOf(0);if(-1===a)return null;var o,s=dt(ge(e.data,3+n,a));return o="--\x3e"===i?dt(ge(e.data,4+n+a)):pe(e.data.subarray(4+n+a)),t.mimeType=i,t.pictureType=r,t.description=s,t.data=o,t}return"TXXX"===e.type||"WXXX"===e.type?2>e.size||3!==e.data[0]||-1===(i=e.data.subarray(1).indexOf(0))?null:(n=dt(ge(e.data,1,i)),e=dt(ge(e.data,2+i)).replace(/\0*$/,""),t.description=n,t.data=e,t):"PRIV"===e.type?2>e.size||-1===(n=e.data.indexOf(0))?null:(n=dt(ge(e.data,0,n)),t.description=n,"com.apple.streaming.transportStreamTimestamp"==n?(n=e.data.subarray(n.length+1),e=1&n[3],n=(n[4]<<23)+(n[5]<<15)+(n[6]<<7)+n[7],n/=45,e&&(n+=47721858.84),t.data=n):(e=pe(e.data.subarray(n.length+1)),t.data=e),t):"T"===e.type[0]?2>e.size||3!==e.data[0]?null:(e=dt(e.data.subarray(1)).replace(/\0*$/,""),t.data=e,t):"W"===e.type[0]?(e=dt(e.data).replace(/\0*$/,""),t.data=e,t):e.data?(t.data=pe(e.data),t):null}function No(e){for(var t=0,n=[];Do(e,t);){var i=Po(e,t+6);for(e[t+5]>>6&1&&(t+=10),i=(t+=10)+i;t+10<i;){var r=e.subarray(t),a=Po(r,4);(a=Lo(r={type:String.fromCharCode(r[0],r[1],r[2],r[3]),size:a,data:r.subarray(10,10+a)}))&&n.push(a),t+=r.size+10}Ro(e,t)&&(t+=10)}return n}function jo(e,t){for(var n=t=void 0===t?0:t,i=0;Do(e,t);)e[t+5]>>6&1&&(i+=10),i+=10,i+=Po(e,t+6),Ro(e,t+10)&&(i+=10),t+=i;return 0<i?e.subarray(n,n+i):new Uint8Array([])}function Oo(e,t){var n=null,i=null,r=null,a=e.P();return 1&t&&(r=e.Vc()),2&t&&e.skip(4),8&t&&(n=e.P()),16&t&&(i=e.P()),{trackId:a,ed:n,Ld:i,jk:r}}function Uo(e,t){return 1==t?(t=e.P(),e=e.P(),{baseMediaDecodeTime:t*Math.pow(2,32)+e}):{baseMediaDecodeTime:e.P()}}function _o(e,t){return 1==t?(e.skip(8),e.skip(8)):(e.skip(4),e.skip(4)),t=e.P(),e.skip(4),e=e.ma(),{timescale:t,language:String.fromCharCode(96+(e>>10))+String.fromCharCode(96+((960&e)>>5))+String.fromCharCode(96+(31&e))}}function Bo(e,t,n){var i=e.P(),r=[],a=null;1&n&&(a=e.P()),4&n&&e.skip(4);for(var o=0;o<i;o++){var s={Of:null,sampleSize:null,me:null};256&n&&(s.Of=e.P()),512&n&&(s.sampleSize=e.P()),1024&n&&e.skip(4),2048&n&&(s.me=0==t?e.P():e.Vg()),r.push(s)}return{nk:i,Zg:r,Ih:a}}function Fo(e){e.skip(6),e.skip(2),e.skip(8);var t=e.ma();return e.skip(2),e.skip(2),e.skip(2),{channelCount:t,sampleRate:e=e.ma()+e.ma()/65536}}function Vo(e){return{codec:Ma(e=e.P())}}function Ho(e,t){return t=void 0!==t&&t,e=e.toString(16).toUpperCase(),t?e:("0"+e).slice(-2)}function Go(e){return(10>e?"0":"")+e}function Ko(e,t){if(this.j=e,void 0!==t&&t){t=new Uint8Array(e.byteLength);for(var n=0,i=0;i<e.byteLength;i++)2<=i&&3==e[i]&&0==e[i-1]&&0==e[i-2]||(t[n]=e[i],n++);this.j=ge(t,0,n)}this.i=this.j.byteLength,this.g=this.h=0}function Xo(e){var t=e.j.byteLength-e.i,n=new Uint8Array(4),i=Math.min(4,e.i);0!==i&&(n.set(e.j.subarray(t,t+i)),e.h=new ya(n,0).P(),e.g=8*i,e.i-=i)}function qo(e,t){if(e.g<=t){t-=e.g;var n=Math.floor(t/8);t-=8*n,e.g-=n,Xo(e)}e.h<<=t,e.g-=t}function zo(e,t){var n=Math.min(e.g,t),i=e.h>>>32-n;return e.g-=n,0<e.g?e.h<<=n:0<e.i&&Xo(e),0<(n=t-n)?i<<n|zo(e,n):i}function Wo(e){var t;for(t=0;t<e.g;++t)if(e.h&2147483648>>>t)return e.h<<=t,e.g-=t,t;return Xo(e),t+Wo(e)}function Yo(e){qo(e,1+Wo(e))}function Jo(e){return zo(e,Wo(e)+1)-1}function $o(e){return 1&(e=Jo(e))?1+e>>>1:-1*(e>>>1)}function Qo(e){return 1===zo(e,1)}function Zo(e){return zo(e,8)}function es(e,t){for(var n=8,i=8,r=0;r<t;r++)0!==i&&(i=(n+(i=$o(e))+256)%256),n=0===i?n:i}function ts(e){return Zo(e),Jo(e),Jo(e)}function ns(){this.G=null,this.H=!1,this.m=this.I=null,this.j=[],this.g=[],this.A=this.B=null,this.i=[],this.h=[],this.C=null,this.l=[],this.F=this.o=this.s=null}function is(e,t){if(1!=(t[0]<<16|t[1]<<8|t[2]))return null;var n={data:new Uint8Array(0),packetLength:t[4]<<8|t[5],pts:null,dts:null,nalus:[]};if(n.packetLength&&n.packetLength>t.byteLength-6)return null;var i=t[7];if(192&i){var r=536870912*(14&t[9])+4194304*(255&t[10])+16384*(254&t[11])+128*(255&t[12])+(254&t[13])/2;null==e.s&&(e.s=r),n.pts=as(r,e.s),e.s=n.pts,n.dts=n.pts,64&i&&(i=536870912*(14&t[14])+4194304*(255&t[15])+16384*(254&t[16])+128*(255&t[17])+(254&t[18])/2,null==e.o&&(e.o=i),n.dts=as(i,e.o)),e.o=n.dts}return e=t[8]+9,t.byteLength<=e?null:(n.data=t.subarray(e),n)}function rs(e){var t=e.sc();return 1<t.length&&(e=t[0].pts,t=t[1].pts,!isNaN(t-e))?String(1/(t-e)*9e4):null}function as(e,t){var n=1;for(e>t&&(n=-1);4294967296<Math.abs(t-e);)e+=8589934592*n;return e}function os(e){return!(0>ss(e))}function ss(e){for(var t=Math.min(1e3,e.length-564),n=0;n<t;){if(71==e[n]&&71==e[n+188]&&71==e[n+376])return n;n++}return-1}vo.Status={lj:bo,fk:wo,Hj:2},F("shaka.util.Dom",ko),ko.removeAllChildren=Mo,F("shaka.util.Id3Utils",Co),Co.getID3Data=jo,Co.getID3Frames=No,F("shaka.util.ExpGolomb",Ko),(i=ns.prototype).clearData=function(){this.j=[],this.g=[],this.i=[],this.h=[],this.l=[]},i.parse=function(e){if(564>e.length)return this;for(var t=Math.max(0,ss(e)),n=e.length-(e.length+t)%188,i=!1,r=t;r<n;r+=188)if(71==e[r]){var a=!!(64&e[r+1]),o=((31&e[r+1])<<8)+e[r+2];if(1<(48&e[r+3])>>4){var s=r+5+e[r+4];if(s==r+188)continue}else s=r+4;switch(o){case 0:a&&(s+=e[s]+1),this.G=(31&e[s+10])<<8|e[s+11];break;case 17:case 8191:break;case this.G:a&&(s+=e[s]+1),o={audio:-1,video:-1,Td:-1,audioCodec:"",videoCodec:""};var u=s+3+((15&(a=e)[s+1])<<8|a[s+2])-4;for(s+=12+((15&a[s+10])<<8|a[s+11]);s<u;){var l=(31&a[s+1])<<8|a[s+2],c=(15&a[s+3])<<8|a[s+4];switch(a[s]){case 6:if(0<c)for(var d=s+5,h=c;2<h;){var f=a[d+1]+2;switch(a[d]){case 5:var p=mt(a.subarray(d+2,d+f));-1==o.audio&&"Opus"===p?(o.audio=l,o.audioCodec="opus"):-1==o.video&&"AV01"===p&&(o.video=l,o.videoCodec="av1");break;case 106:-1==o.audio&&(o.audio=l,o.audioCodec="ac3");break;case 122:-1==o.audio&&(o.audio=l,o.audioCodec="ec3");break;case 124:-1==o.audio&&(o.audio=l,o.audioCodec="aac");break;case 127:"opus"==o.audioCodec&&(p=null,128===a[d+2]&&(p=a[d+3]),null!=p&&(this.F={channelCount:15&p?15&p:2,Fh:p,sampleRate:48e3}))}d+=f,h-=f}break;case 15:-1==o.audio&&(o.audio=l,o.audioCodec="aac");break;case 17:-1==o.audio&&(o.audio=l,o.audioCodec="aac-loas");break;case 21:-1==o.Td&&(o.Td=l);break;case 27:-1==o.video&&(o.video=l,o.videoCodec="avc");break;case 3:case 4:-1==o.audio&&(o.audio=l,o.audioCodec="mp3");break;case 36:-1==o.video&&(o.video=l,o.videoCodec="hvc");break;case 129:-1==o.audio&&(o.audio=l,o.audioCodec="ac3");break;case 132:case 135:-1==o.audio&&(o.audio=l,o.audioCodec="ec3")}s+=c+5}-1!=(a=o).video&&(this.I=a.video,this.m=a.videoCodec),-1!=a.audio&&(this.B=a.audio,this.A=a.audioCodec),-1!=a.Td&&(this.C=a.Td),i&&!this.H&&(i=!1,r=t-188),this.H=!0;break;case this.I:s=e.subarray(s,r+188),a?this.j.push([s]):this.j.length&&this.j[this.j.length-1]&&this.j[this.j.length-1].push(s);break;case this.B:s=e.subarray(s,r+188),a?this.i.push([s]):this.i.length&&this.i[this.i.length-1]&&this.i[this.i.length-1].push(s);break;case this.C:s=e.subarray(s,r+188),a?this.l.push([s]):this.l.length&&this.l[this.l.length-1]&&this.l[this.l.length-1].push(s);break;default:i=!0}}return this},i.Gi=function(e){return oe("TsParser.parseAvcNalus","Please use parseNalus function instead."),this.Gf(e)},i.Gf=function(e,t,n){var i=e.pts?e.pts/9e4:null,r=(e=e.data).byteLength,a=1;"hvc"==this.m&&(a=2);for(var o,s=n||0,u=[],l=-1,c=0,d=0;d<r;++d){var h=e[d];if(h){if(2<=s&&1==h){if(t&&!u.length&&-1==l&&(h=d-(3<s?3:s),n&&0!=h&&(h=e.subarray(0,h),t.data=di(t.data,h),t.fullData=di(t.fullData,h))),0<=l?(s=d-((3<s?3:s)+1),u.push({data:e.subarray(l+a,s+1),fullData:e.subarray(l,s+1),type:c,time:i})):t&&!u.length&&0<(l=d-s)&&(l=e.subarray(0,l),t.data=di(t.data,l),t.fullData=di(t.fullData,l)),d>=r-a)return u;l=++d,c="hvc"==this.m?e[d]>>1&63:31&e[d]}s=0}else s++;d>=r-1&&0<=l&&0<=s&&(o={data:e.subarray(l+a,r),fullData:e.subarray(l,r),type:c,time:i})}return o&&u.push(o),!u.length&&t&&(t.data=di(t.data,e),t.fullData=di(t.fullData,e)),u},i.getMetadata=function(){for(var e=[],t=l(this.l),n=t.next();!n.done;n=t.next())(n=is(this,n=di.apply(ai,c(n.value))))&&e.push({cueTime:n.pts?n.pts/9e4:null,data:n.data,frames:No(n.data),dts:n.dts,pts:n.pts});return e},i.Wb=function(){if(this.i.length&&!this.h.length){for(var e=!1,t=l(this.i),n=t.next();!n.done;n=t.next()){var i=di.apply(ai,c(n.value)),r=is(this,i);n=this.h.length?this.h[this.h.length-1]:null,r&&null!=r.pts&&null!=r.dts&&(!n||n.pts!=r.pts&&n.dts!=r.dts)?(this.h.length&&r.dts<(n.dts||0)&&(e=!0),this.h.push(r)):this.h.length&&(i=r?r.data:i)&&((n=this.h.pop()).data=di(n.data,i),this.h.push(n))}e&&(this.h=this.h.sort((function(e,t){var n=(e.pts||0)-(t.pts||0);return(e.dts||0)-(t.dts||0)||n})))}return this.h},i.sc=function(e){if(e=void 0===e||e,this.j.length&&!this.g.length){for(var t=!1,n=l(this.j),i=n.next();!i.done;i=n.next()){var r=di.apply(ai,c(i.value)),a=is(this,r);i=this.g.length?this.g[this.g.length-1]:null,a&&null!=a.pts&&null!=a.dts&&(!i||i.pts!=a.pts&&i.dts!=a.dts)?(this.g.length&&a.dts<(i.dts||0)&&(t=!0),this.g.push(a)):this.g.length&&(r=a?a.data:r)&&((i=this.g.pop()).data=di(i.data,r),this.g.push(i))}if(e){for(n=[],r=(i=l(this.g)).next();!r.done;r=i.next())if((r=r.value).nalus=this.Gf(r,o,void 0),r.nalus.length){n.push(r);var o=r.nalus[r.nalus.length-1]}this.g=n}t&&(this.g=this.g.sort((function(e,t){var n=(e.pts||0)-(t.pts||0);return(e.dts||0)-(t.dts||0)||n})))}return e?this.g:(e=this.g,this.g=[],e)},i.getStartTime=function(e){if("audio"==e){e=null;var t=this.Wb();return t.length&&(e=t[0],e=Math.min(e.dts,e.pts)/9e4),e}return"video"==e?(e=null,(t=this.sc(!1)).length&&(e=t[0],e=Math.min(e.dts,e.pts)/9e4),e):null},i.fd=function(){return{audio:this.A,video:this.m}},i.Rd=function(){for(var e=[],t=l(this.sc()),n=t.next();!n.done;n=t.next())e.push.apply(e,c(n.value.nalus));return e},i.ki=function(){oe("TsParser.getVideoResolution","Please use getVideoInfo function instead.");var e=this.nf();return{height:e.height,width:e.width}},i.nf=function(){return"hvc"==this.m?function(e){var t={height:null,width:null,codec:null,frameRate:null},n=e.Rd();if(!n.length)return t;if(!(n=n.find((function(e){return 33==e.type}))))return t;var i=new Ko(n.fullData,!0);Zo(i),Zo(i),zo(i,4);var r=zo(i,3);Qo(i);var a=zo(i,2),o=zo(i,1),s=zo(i,5),u=zo(i,32);n=Zo(i);for(var l=Zo(i),c=Zo(i),d=Zo(i),h=Zo(i),f=Zo(i),p=Zo(i),g=[],m=[],v=0;v<r;v++)g.push(Qo(i)),m.push(Qo(i));if(0<r)for(v=r;8>v;v++)zo(i,2);for(v=0;v<r;v++)g[v]&&zo(i,88),m[v]&&Zo(i);Jo(i),3==(r=Jo(i))&&zo(i,1),g=Jo(i),m=Jo(i);var y=v=0,b=0,w=0;return Qo(i)&&(v+=Jo(i),y+=Jo(i),b+=Jo(i),w+=Jo(i)),t.width=String(g-(v+y)*(1===r||2===r?2:1)),t.height=String(m-(b+w)*(1===r?2:1)),i=function(e){for(var t=0,n=0;32>n;n++)t|=(e>>n&1)<<31-n;return t>>>0}(u),o=1==o?"H":"L",a="hvc1."+["","A","B","C"][a]+s,a+="."+i.toString(16).toUpperCase(),a+="."+o+p,f&&(a+="."+f.toString(16).toUpperCase()),h&&(a+="."+h.toString(16).toUpperCase()),d&&(a+="."+d.toString(16).toUpperCase()),c&&(a+="."+c.toString(16).toUpperCase()),l&&(a+="."+l.toString(16).toUpperCase()),n&&(a+="."+n.toString(16).toUpperCase()),t.codec=a,t.frameRate=rs(e),t}(this):function(e){var t={height:null,width:null,codec:null,frameRate:null},n=e.Rd();if(!n.length)return t;if(!(n=n.find((function(e){return 7==e.type}))))return t;var i=Zo(n=new Ko(n.data)),r=Zo(n),a=Zo(n);if(Yo(n),us.includes(i)){var o=Jo(n);if(3===o&&qo(n,1),Yo(n),Yo(n),qo(n,1),Qo(n)){o=3!==o?8:12;for(var s=0;s<o;s++)Qo(n)&&es(n,6>s?16:64)}}if(Yo(n),0===(o=Jo(n)))Jo(n);else if(1===o)for(qo(n,1),Yo(n),Yo(n),o=Jo(n),s=0;s<o;s++)Yo(n);Yo(n),qo(n,1),o=Jo(n),s=Jo(n);var u=zo(n,1);0===u&&qo(n,1),qo(n,1);var l=0,c=0,d=0,h=0;return Qo(n)&&(l=Jo(n),c=Jo(n),d=Jo(n),h=Jo(n)),t.height=String((2-u)*(s+1)*16-2*d-2*h),t.width=String(16*(o+1)-2*l-2*c),t.codec="avc1."+("0"+i.toString(16).toUpperCase()).slice(-2)+("0"+r.toString(16).toUpperCase()).slice(-2)+("0"+a.toString(16).toUpperCase()).slice(-2),t.frameRate=rs(e),t}(this)},F("shaka.util.TsParser",ns),ns.syncOffset=ss,ns.probe=os,ns.prototype.getVideoInfo=ns.prototype.nf,ns.prototype.getVideoResolution=ns.prototype.ki,ns.prototype.getVideoNalus=ns.prototype.Rd,ns.prototype.getCodecs=ns.prototype.fd,ns.prototype.getStartTime=ns.prototype.getStartTime,ns.prototype.getVideoData=ns.prototype.sc,ns.prototype.getAudioData=ns.prototype.Wb,ns.prototype.getMetadata=ns.prototype.getMetadata,ns.prototype.parseNalus=ns.prototype.Gf,ns.prototype.parseAvcNalus=ns.prototype.Gi,ns.prototype.parse=ns.prototype.parse,ns.prototype.clearData=ns.prototype.clearData,ns.Timescale=9e4;var us=[100,110,122,244,44,83,86,118,128,138,139,134];function ls(e,t,n){this.g=null,this.o=-1,this.l=e,this.i=t,this.m=n,this.j=!1;e:{if("undefined"==typeof libDPIModule&&W("Could not find LCEVC Library dependencies on this page"),"undefined"!=typeof LCEVCdec)this.h=LCEVCdec;else{if("undefined"==typeof LcevcDil){W("Could not find LCEVC Library on this page"),e=!1;break e}this.h=LcevcDil,this.j=!0,oe("LcevcDil","lcevc_dil.js is deprecated, please use lcevc_dec.js instead")}void 0===this.h.SupportObject?(W("Could not find LCEVC Library on this page"),e=!1):(this.h.SupportObject.SupportStatus||W(this.h.SupportObject.SupportError),e=void 0!==this.h&&"undefined"!=typeof libDPIModule&&this.i instanceof HTMLCanvasElement&&this.h.SupportObject.SupportStatus)}e&&!this.g&&this.h.SupportObject.webGLSupport(this.i)&&(this.i.classList.remove("shaka-hidden"),this.g=this.j?new this.h.LcevcDil(this.l,this.i,this.m):new this.h.LCEVCdec(this.l,this.i,this.m))}function cs(e){e.g&&e.i.classList.add("shaka-hidden")}function ds(e,t,n){var i=0,r=-1;switch(t.mimeType){case"video/webm":i=1;break;case"video/mp4":i=2}switch(n){case"DASH":r=1;break;case"HLS":r=0}e.g&&(e.o=t.id,e.g.setLevelSwitching(t.id,!0),e.g.setContainerFormat(i),e.j||e.g.setStreamingFormat(r))}function hs(e,t,n,i){var r=this;this.g=e,this.F=n,this.A=null,this.fa=t,this.i={},this.G={},this.Ka={},this.h=null,this.xa=!1,this.da=i||null,this.o={},this.s=new Z,this.j={},this.H=null,this.S=new Gr,this.Aa="",this.Na=!1,this.ta=!0,this.Z=!1,this.B=this.K=null,this.l=fs(this,this.S),this.I=!1,this.L=new fa((function(){return function(e){var t,n,i,r,a,o,s;return P((function(u){if(1==u.g){for(n in t=[],e.o)for(i=e.o[n],r=i[0],e.o[n]=i.slice(0,1),r&&t.push(r.p.catch(Hi)),a=l(i.slice(1)),o=a.next();!o.done;o=a.next())o.value.p.reject(new De(2,7,7003,void 0));return e.h&&t.push(e.h.destroy()),w(u,Promise.all(t),2)}for(s in e.j)e.j[s].destroy();e.s&&(e.s.release(),e.s=null),e.g&&e.B&&e.g.removeChild(e.B),e.g&&e.K&&(e.g.removeChild(e.K),e.g.load(),e.g.disableRemotePlayback=!1),e.g=null,e.K=null,e.B=null,e.A=null,e.l=null,e.h=null,e.fa=null,e.i={},e.j={},e.H=null,e.o={},e.da=null,e.Y={},e.F=null,T(u)}))}(r)})),this.C=!1,this.aa="UNKNOWN",this.Ga=this.La=!1,this.Ba=new Gr,this.m=!1,this.na=null,this.Y={},this.ja=this.M=this.ra=this.O=null,this.ga=new Gr,this.g.remote&&(this.Z="disconnected"!=this.g.remote.state,this.s.D(this.g.remote,"connect",(function(){r.Z="disconnected"!=r.g.remote.state})),this.s.D(this.g.remote,"connecting",(function(){r.Z="disconnected"!=r.g.remote.state})),this.s.D(this.g.remote,"disconnect",(function(){r.Z="disconnected"!=r.g.remote.state})))}function fs(t,n){if(t.ta=!0,e.ManagedMediaSource){t.B||(t.g.disableRemotePlayback=!0);var i=new ManagedMediaSource;t.s.D(i,"startstreaming",(function(){t.ta=!0})),t.s.D(i,"endstreaming",(function(){t.ta=!1}))}else i=new MediaSource;return t.s.pa(i,"sourceopen",(function(){URL.revokeObjectURL(t.Aa),n.resolve()})),t.s.pa(t.g,"playing",(function(){t.Na=!0})),t.Aa=Rs(i),t.g.removeAttribute("src"),t.K&&t.g.removeChild(t.K),t.B&&t.g.removeChild(t.B),t.K=Io(t.Aa),t.g.appendChild(t.K),t.B&&t.g.appendChild(t.B),t.g.load(),i}function ps(e,t,n,i){var r,a,o,s,u,c,d,h,f,p,g,m;return P((function(v){switch(v.g){case 1:return r=bi,a=V,o=H,w(v,function(e,t){var n,i,r,a,o,s,u,c,d,h;return P((function(f){if(1==f.g)return e.createSegmentIndex?w(f,e.createSegmentIndex(),2):f.u(2);if(!e.segmentIndex)return f.return(!1);if(0==e.segmentIndex.getNumReferences())return f.return(!0);for(n=bi,i=new Set,r=l(e.segmentIndex),a=r.next();!a.done;a=r.next())if(o=a.value,s=o.mimeType||e.mimeType||"",u=o.codecs||e.codecs||"",c=s+":"+u,!i.has(c))if(i.add(c),t==n.wa){if(!Ui(xi(s,u)))return f.return(!1)}else if(t==n.la?u=cr(u):t==n.V&&(u=lr(u,s)),d=ki(e,s,u),h=Ai(s,u),!ne(d)&&!On(h))return f.return(!1);return f.return(!0)}))}(n,t),2);case 2:if(o.call(a,v.h,"Type negotiation should happen before MediaSourceEngine.init!"),s=xi(n.mimeType,i),t==r.wa){gs(e,s,e.C,n.external),v.u(0);break}if(u=e.A.forceTransmux,(!ne(s)||!e.C&&ji.includes(s))&&(u=!0),c=Ai(n.mimeType,i),!u){v.u(4);break}if(d=mi(r.V,(i||"").split(",")),h=mi(r.la,(i||"").split(",")),!d||!h){v.u(5);break}return e.m=!0,w(v,ps(e,r.V,n,d),6);case 6:return w(v,ps(e,r.la,n,h),7);case 7:return v.return();case 5:(f=On(c))&&(p=f(),e.j[t]=p,s=p.convertCodecs(t,c));case 4:g=s+e.A.addExtraFeaturesToSourceBuffer(s),pa(e.L);try{m=e.l.addSourceBuffer(g)}catch(t){throw new De(2,3,3015,t,"The mediaSource_ status was "+e.l.readyState+" expected 'open'",null)}e.C&&(m.mode=Ps),e.s.D(m,"error",(function(){var n=e.o[t][0];n.p.reject(new De(2,3,3014,e.g.error?e.g.error.code:0,n.uri))})),e.s.D(m,"updateend",(function(){return Es(e,t)})),e.i[t]=m,e.G[t]=s,e.Ka[t]=!!n.drmInfos.length,T(v)}}))}function gs(e,t,n,i){e.h||(e.h=new Oi(e.fa),e.h&&(e.h.A=e.A.modifyCueCallback));var r=e.h;i=i||e.xa,e=e.aa,"application/cea-608"==t||"application/cea-708"==t?r.i=null:(r.i=(0,Fi[t])(),r.i.setSequenceMode?r.i.setSequenceMode(n):oe("Text parsers w/ setSequenceMode",'Text parsers should have a "setSequenceMode" method!'),r.i.setManifestType?r.i.setManifestType(e):oe("Text parsers w/ setManifestType",'Text parsers should have a "setManifestType" method!'),r.B=i)}function ms(e){return!(e.I||e.l&&"ended"!=e.l.readyState)}function vs(e,t){return e=Object.keys(e.i).length?t==yi?e.h.g:!(e=bs(e,t))||To(e)?null:1==e.length&&0>e.start(0)?0:e.length?e.start(0):null:null}function ys(e,t){return Object.keys(e.i).length?t==yi?e.h.h:So(bs(e,t)):null}function bs(e,t){if(e.I||e.Z)return null;try{return e.i[t].buffered}catch(e){return null}}function ws(e,t,n,i,r,a,o,s,u,c){var d,h,f,p,g,m,v,y,b,S,x,A,E,k;return o=void 0!==o&&o,s=void 0!==s&&s,u=void 0!==u&&u,c=void 0!==c&&c,P((function(I){switch(I.g){case 1:if(t!=(d=bi).wa){I.u(2);break}if("HLS"!=e.aa){I.u(3);break}return w(I,e.Ba,4);case 4:h=I.h,e.h.s=h;case 3:return w(I,function(e,t,n,i,r){var a,o,s,u,c,d,h;return P((function(f){if(1==f.g)return w(f,Promise.resolve(),2);if(!e.i||!e.j)return f.return();if(null==n||null==i)return e.i.parseInit(ge(t)),f.return();for(a=e.B?n:e.s,o={periodStart:e.s,segmentStart:n,segmentEnd:i,vttOffset:a},s=e.i.parseMedia(ge(t),o,r,[]),u=l(s),c=u.next();!c.done;c=u.next())d=c.value,e.A(d,r||null,o);h=s.filter((function(t){return t.startTime>=e.l&&t.startTime<e.m})),e.j.append(h),null==e.g&&(e.g=Math.max(n,e.l)),e.h=Math.min(i,e.m),T(f)}))}(e.h,n,i?i.startTime:null,i?i.endTime:null,i?i.N()[0]:null),5);case 5:return I.return();case 2:if(c||!e.m){I.u(6);break}return w(I,ws(e,d.V,n,i,r,a,o,s,u,!0),7);case 7:return w(I,ws(e,d.la,n,i,r,a,o,s,u,!0),8);case 8:return I.return();case 6:if(!e.i[t])return I.return();if(f=e.i[t].timestampOffset,p=e.G[t],e.j[t]&&(p=e.j[t].getOriginalMimeType()),i&&(g=function(e,t,n,i,r,a){var o=null,s=[],u=ge(n);if(ji.includes(a))(t=No(u)).length&&i&&((n=t.find((function(e){return"com.apple.streaming.transportStreamTimestamp"===e.description})))&&(o=Math.round(n.data)/1e3),e.F.onMetadata([{cueTime:i.startTime,data:u,frames:t,dts:i.startTime,pts:i.startTime}],0,i.endTime));else if(a.includes("/mp4")&&i&&i.ba&&i.ba.timescale){var l=i.ba.timescale;if(!isNaN(l)){var c=0,d=!1;u=new Ta,(null!=r.emsgSchemeIdUris&&0<r.emsgSchemeIdUris.length||e.A.dispatchAllEmsgBoxes)&&u.R("emsg",(function(t){var n=r.emsgSchemeIdUris;if(0===t.version)var a=t.reader.yc(),o=t.reader.yc(),s=t.reader.P(),u=t.reader.P(),l=t.reader.P(),c=t.reader.P(),d=i.startTime+u/s;else s=t.reader.P(),u=(d=t.reader.Vc()/s+i.timestampOffset)-i.startTime,l=t.reader.P(),c=t.reader.P(),a=t.reader.yc(),o=t.reader.yc();t=t.reader.vb(t.reader.getLength()-t.reader.ya()),(n&&n.includes(a)||e.A.dispatchAllEmsgBoxes)&&("urn:mpeg:dash:event:2012"==a?e.F.Fi():(n=d+l/s,(s=new Jr("emsg",s=(new Map).set("detail",{startTime:d,endTime:n,schemeIdUri:a,value:o,timescale:s,presentationTimeDelta:u,eventDuration:l,id:c,messageData:t}))).cancelable=!0,e.F.onEvent(s),s.defaultPrevented||"https://aomedia.org/emsg/ID3"!=a&&"https://developer.apple.com/streaming/emsg-id3"!=a||!(a=No(t)).length||e.F.onMetadata([{cueTime:d,data:t,frames:a,dts:d,pts:d}],0,n)))})),u.R("prft",(function(t){var n=t.reader,i=t.version;n.P(),t=1e3*(t=n.P())+n.P()/Math.pow(2,32)*1e3,0===i?n=n.P():(i=n.P(),n=n.P(),n=i*Math.pow(2,32)+n),t=new Date(new Date(Date.UTC(1900,0,1,0,0,0)).getTime()+t).getTime(),n=new Jr("prft",n=(new Map).set("detail",{wallClockTime:t,programStartDate:new Date(t-n/l*1e3)})),e.F.onEvent(n)})).box("moof",Sa).box("traf",Sa).R("tfdt",(function(e){c=Uo(e.reader,e.version).baseMediaDecodeTime/l,d=!0,e.parser.stop()})).parse(n,!0),d&&0==i.timestampOffset&&(o=c)}}else a.includes("/mp4")||a.includes("/webm")||!os(u)||(e.Y[t]?e.Y[t].clearData():e.Y[t]=new ns,null!=(u=(s=e.Y[t].parse(u)).getStartTime(t))&&(o=u),s=s.getMetadata());return{timestamp:o,metadata:s}}(e,t,n,i,r,p),m=g.timestamp,v=g.metadata,null!=m&&(null==e.O&&t==d.la&&(e.O=m,e.ra=i.startTime,null!=e.M&&(y=0,e.ra==e.ja&&(y=e.O-e.M),e.ga.resolve(y))),null==e.M&&t==d.V&&(e.M=m,e.ja=i.startTime,null!=e.O&&(b=0,e.ra==e.ja&&(b=e.O-e.M),e.ga.resolve(b))),S=i.startTime-m,(.001<=Math.abs(f-S)||o||s)&&(!u||0<S||!f)&&(f=S,e.Ga&&(ks(e,t,(function(){return xs(e,t)}),null),ks(e,t,(function(){return As(e,t,f)}),null))),(t==d.la||!(d.la in e.i))&&e.Ba.resolve(f)),v.length)&&e.F.onMetadata(v,f,i?i.endTime:null),a&&t==d.la&&(e.h||gs(e,"application/cea-608",e.C,!1),e.H||(x=p.split(";",1)[0],e.H=new we(x)),i?(A=e.H.i(n)).length&&function(e,t,n,i,r){for(var a=n+" "+i,o=new Map,s=(t=l(t)).next();!s.done;s=t.next()){var u=s.value;s=u.stream,u=u.cue,o.has(s)||o.set(s,new Map),o.get(s).has(a)||o.get(s).set(a,[]),Bi(e,u,r),u.startTime>=e.l&&u.startTime<e.m&&(o.get(s).get(a).push(u),s==e.C&&e.j.append([u]))}for(a=(r=l(o.keys())).next();!a.done;a=r.next())for(a=a.value,e.o.has(a)||e.o.set(a,new Map),s=(t=l(o.get(a).keys())).next();!s.done;s=t.next())s=s.value,u=o.get(a).get(s),e.o.get(a).set(s,u);e.g=null==e.g?Math.max(n,e.l):Math.min(e.g,Math.max(n,e.l)),e.h=Math.max(e.h,Math.min(i,e.m))}(e.h,A,i.startTime,i.endTime,f):e.H.init(n,s)),!e.j[t]){I.u(9);break}return w(I,e.j[t].transmux(n,r,i,e.l.duration,t),10);case 10:n=I.h;case 9:if(n=function(e,t,n,i,r){var a=null==n,o=e.Ka[i];return n=e.F.Uh(),(a=e.A.insertFakeEncryptionInInit&&a&&o)&&(n=je(n),a=Ke()||Ge()||Ze()||He()&&tt()&&n),a&&"mp4"==Ii(e.G[i])&&(t=function(e,t){function n(){o=!0}function i(e){s.push(e),Sa(e)}var r,a=e=ge(e),o=!1,s=[],u=[];if((new Ta).box("moov",i).box("trak",i).box("mdia",i).box("minf",i).box("stbl",i).R("stsd",(function(e){r=e,s.push(e),xa(e)})).R("encv",n).R("enca",n).R("dvav",(function(e){u.push({box:e,Ta:1701733238})})).R("dva1",(function(e){u.push({box:e,Ta:1701733238})})).R("dvh1",(function(e){u.push({box:e,Ta:1701733238})})).R("dvhe",(function(e){u.push({box:e,Ta:1701733238})})).R("dvc1",(function(e){u.push({box:e,Ta:1701733238})})).R("dvi1",(function(e){u.push({box:e,Ta:1701733238})})).R("hev1",(function(e){u.push({box:e,Ta:1701733238})})).R("hvc1",(function(e){u.push({box:e,Ta:1701733238})})).R("avc1",(function(e){u.push({box:e,Ta:1701733238})})).R("avc3",(function(e){u.push({box:e,Ta:1701733238})})).R("ac-3",(function(e){u.push({box:e,Ta:1701733217})})).R("ec-3",(function(e){u.push({box:e,Ta:1701733217})})).R("ac-4",(function(e){u.push({box:e,Ta:1701733217})})).R("mp4a",(function(e){u.push({box:e,Ta:1701733217})})).parse(e),o)return e;if(0==u.length||!r)throw ci(e),new De(2,3,3019,t);u.reverse();for(var c=(t=l(u)).next();!c.done;c=t.next())c=c.value,a=ho(a,r,c.box,s,c.Ta);return He()&&tt()&&!Ge()?((t=new Uint8Array(e.byteLength+a.byteLength)).set(a),t.set(e,a.byteLength),t):a}(t,r)),t}(e,n,i?i.startTime:null,t,i?i.N()[0]:null),!i||!e.C||t==d.wa){I.u(11);break}if(!o&&!s){I.u(11);break}if(E=i.startTime,"HLS"!=e.aa||e.m||t!=d.V||!e.i[d.la]){I.u(13);break}return w(I,e.ga,14);case 14:k=I.h,.1<Math.abs(k)&&(E-=k);case 13:ks(e,t,(function(){return xs(e,t)}),null),ks(e,t,(function(){return As(e,t,E)}),null);case 11:return w(I,ks(e,t,(function(){var i=n;if("video"==t&&e.da){var r=e.da;r.g&&r.g.appendBuffer(i,"video",r.o,-f)}e.i[t].appendBuffer(i)}),i?i.N()[0]:null),15);case 15:T(I)}}))}function Ts(e,t){var n;return P((function(i){return 1==i.g?t==(n=bi).wa?e.h?w(i,e.h.remove(0,1/0),0):i.return():w(i,ks(e,t,(function(){return Ss(e,t,0,e.l.duration)}),null),4):e.m?w(i,ks(e,n.V,(function(){return Ss(e,n.V,0,e.l.duration)}),null),0):i.u(0)}))}function Ss(e,t,n,i){i<=n?Es(e,t):e.i[t].remove(n,i)}function xs(e,t){var n=e.i[t].appendWindowStart,i=e.i[t].appendWindowEnd;e.i[t].abort(),e.i[t].appendWindowStart=n,e.i[t].appendWindowEnd=i,Es(e,t)}function As(e,t,n){0>n&&(n+=.001),e.i[t].timestampOffset=n,Es(e,t)}function Es(e,t){if(!e.I){var n=e.o[t][0];n&&(n.p.resolve(),Ms(e,t))}}function ks(e,t,n,i){return pa(e.L),n={start:n,p:new Gr,uri:i},e.o[t].push(n),1==e.o[t].length&&Cs(e,t),n.p}function Is(e,t){var n,i,r,a,o,s,u,c,d,h;return P((function(f){switch(f.g){case 1:for(pa(e.L),n=[],i=Object.keys(e.i),r=l(i),a=r.next(),o={};!a.done;o={ready:void 0},a=r.next())s=a.value,o.ready=new Gr,u={start:function(e){return function(){return e.ready.resolve()}}(o),p:o.ready,uri:null},e.o[s].push(u),n.push(o.ready),1==e.o[s].length&&u.start();return S(f,2),w(f,Promise.all(n),4);case 4:A(f,3);break;case 2:throw E(f);case 3:return S(f,5,6),w(f,t(),6);case 6:for(k(f),c=l(i),d=c.next();!d.done;d=c.next())h=d.value,Ms(e,h);I(f,0);break;case 5:throw new De(2,3,3015,E(f),e.g.error||"No error in the media element",null)}}))}function Ms(e,t){e.o[t].shift(),Cs(e,t)}function Cs(e,t){var n=e.o[t][0];if(n)try{n.start()}catch(i){"QuotaExceededError"==i.name?n.p.reject(new De(2,3,3017,t)):n.p.reject(new De(2,3,3015,i,e.g.error||"No error in the media element",n.uri)),Ms(e,t)}}function Ds(e,t){return Is(e,(function(){return function(e,t){var n,i,r,a,o,s,u,c,d,h,f,p,g,m,v,y,b,T;return P((function(S){switch(S.g){case 1:for(o in n=bi,e.I=!0,e.m=!1,i=e.g.currentTime,r=e.g.autoplay,a=e.g.paused,e.Na&&(e.g.autoplay=!1),x(S,2),e.s.Va(),e.j)e.j[o].destroy();for(s in e.i){u=e.i[s];try{e.l.removeSourceBuffer(u)}catch(e){}}return e.j={},e.i={},c=e.l.duration,e.S=new Gr,e.l=fs(e,e.S),w(S,e.S,4);case 4:!isNaN(c)&&c?e.l.duration=c:!isNaN(e.na)&&e.na&&(e.l.duration=e.na),d=new Gr,h=e.l.sourceBuffers,f=t.size,p=0,g=function(){++p===f&&(d.resolve(),e.s.cb(h,"addsourcebuffer",g))},e.s.D(h,"addsourcebuffer",g),m=l(t.keys()),v=m.next();case 5:return v.done?((T=t.get(n.V))&&T.isAudioMuxedInVideo&&(e.m=!0),e.m&&!e.o[n.V]&&(e.o[n.V]=[]),e.g.currentTime=i,w(S,d,2)):(y=v.value,b=t.get(y),w(S,ps(e,y,b,b.codecs),6));case 6:v=m.next(),S.u(5);break;case 2:k(S),e.I=!1,pa(e.L),e.s.pa(e.g,"canplaythrough",(function(){e.L.g||(e.g.autoplay=r,a||e.g.play())})),I(S,0)}}))}(e,t)}))}ls.prototype.release=function(){this.g&&(this.g.close(),this.g=null)},F("shaka.lcevc.Dec",ls),ls.prototype.release=ls.prototype.release,(i=hs.prototype).destroy=function(){return this.L.destroy()},i.init=function(e,t,n,i){t=void 0!==t&&t,n=void 0===n?"UNKNOWN":n,i=void 0!==i&&i;var r,a,o,s,u,c,d=this;return P((function(h){switch(h.g){case 1:return r=bi,w(h,d.S,2);case 2:d.C=t,d.aa=n,d.La=i,d.Ga=!d.C&&"HLS"==d.aa&&!d.La,d.Y={},d.O=null,d.ra=null,d.M=null,d.ja=null,d.ga=new Gr,a=l(e.keys()),o=a.next();case 3:if(o.done){h.u(5);break}return s=o.value,u=e.get(s),w(h,ps(d,s,u,u.codecs),6);case 6:d.m?(d.o[r.V]=[],d.o[r.la]=[]):d.o[s]=[],o=a.next(),h.u(3);break;case 5:(c=e.get(r.V))&&c.isAudioMuxedInVideo&&(d.m=!0),T(h)}}))},i.configure=function(e){this.A=e,this.h&&(this.h.A=e.modifyCueCallback)},i.zb=function(){var e={total:this.I?[]:Eo(this.g.buffered),audio:Eo(bs(this,"audio")),video:Eo(bs(this,"video")),text:[]};if(this.h){var t=this.h.g,n=this.h.h;null!=t&&null!=n&&e.text.push({start:t,end:n})}return e},i.remove=function(e,t,n){var i,r=this;return P((function(a){return 1==a.g?e==(i=bi).wa?w(a,r.h.remove(t,n),0):w(a,ks(r,e,(function(){return Ss(r,e,t,n)}),null),4):r.m?w(a,ks(r,i.V,(function(){return Ss(r,i.V,t,n)}),null),0):a.u(0)}))},i.flush=function(e){var t,n=this;return P((function(i){return 1==i.g?e==(t=bi).wa?i.return():w(i,ks(n,e,(function(){n.g.currentTime-=.001,Es(n,e)}),null),2):n.m?w(i,ks(n,t.V,(function(){var e=t.V;n.g.currentTime-=.001,Es(n,e)}),null),0):i.u(0)}))},i.endOfStream=function(e){var t=this;return P((function(n){return w(n,Is(t,(function(){ms(t)||"closed"===t.l.readyState||(e?t.l.endOfStream(e):t.l.endOfStream())})),0)}))},i.bb=function(e){var t=this;return P((function(n){return w(n,Is(t,(function(){if(e<t.l.duration)for(var n in t.i){var i={start:function(){},p:new Gr,uri:null};t.o[n].unshift(i)}t.l.duration=e,t.na=e})),0)}))},i.getDuration=function(){return this.l.duration};var Rs=e.URL.createObjectURL,Ps="sequence";function Ls(e,t,n){this.i=e,this.C=t,this.o=this.l=1/0,this.h=1,this.g=this.j=null,this.A=0,this.B=!0,this.I=!1,this.H=0,this.F=void 0===n||n,this.G=0,this.s=!1,this.m=e}function Ns(e,t,n){this.j=n,this.l=e,this.s=Os(e),this.g=e.g.currentTime,this.m=Date.now()/1e3,this.h=!1,this.o=0,this.A=t,this.i=function(){}}function js(e){this.g=e}function Os(e){if(e.g.paused||0==e.g.playbackRate||0==e.g.buffered.length)var t=!1;else e:{t=e.g.currentTime;for(var n=(e=l(Eo(e.g.buffered))).next();!n.done;n=e.next())if(!(t<(n=n.value).start-.1||t>n.end-.5)){t=!0;break e}t=!1}return t}function Us(e,t,n,i,r){var a=this;this.A=r,this.g=e,this.B=t,this.m=n,this.l=new Z,this.j=!1,this.F=e.readyState,this.C=this.i=0,this.h=i,this.s=!1,this.l.D(e,"waiting",(function(){return _s(a)})),this.o=new Be((function(){_s(a)})).Ra(this.m.gapJumpTimerTime)}function _s(e){if(0!=e.g.readyState){if(e.g.seeking){if(!e.j)return}else e.j=!1;if(!e.g.paused||e.g.currentTime==e.i&&(e.g.autoplay||e.g.currentTime!=e.i)){var t;if(e.g.readyState!=e.F&&(e.F=e.g.readyState),!(t=!e.h)){var n=(t=e.h).l,i=Os(n),r=n.g.currentTime,a=Date.now()/1e3;t.g==r&&t.s==i||(t.m=a,t.g=r,t.s=i,t.h=!1),(i=(r=a-t.m)>=t.A&&i&&!t.h)&&(t.i(t.g,r),t.h=!0,t.g=n.g.currentTime,t.o++,t.j(new Jr("stalldetected"))),t=!i}t&&(t=e.g.currentTime,i=function(e,t,n){return e&&e.length&&!To(e)&&0<=(e=Eo(e).findIndex((function(e,i,r){return e.start>t&&(0==i||r[i-1].end-t<=n)})))?e:null}(n=e.g.buffered,t,e.m.gapDetectionThreshold),null!=i&&(0!=i||e.s))&&(r=n.start(i),(navigator.userAgent.match(/Edge\//)||Ge()||Ke())&&(r=Math.ceil(100*(r+e.m.gapPadding))/100),r>=e.B.Bb()||.001>r-t||(0!=i&&n.end(i-1),e.g.currentTime=r,t==e.i&&(e.i=r),e.C++,e.A(new Jr("gapjumped"))))}}}function Bs(e,t,n,i){t==HTMLMediaElement.HAVE_NOTHING||e.readyState>=t?i():(t=Fs.value().get(t),n.pa(e,t,i))}(i=Ls.prototype).getDuration=function(){return this.l},i.Wh=function(){return this.h},i.gh=function(e){this.i=e},i.bb=function(e){this.l=e},i.ai=function(){return this.i},i.eh=function(e){this.A=e},i.Bc=function(e){e&&!this.B&&(this.I=!0),this.B=e},i.pe=function(e){this.o=e},i.Qd=function(){return this.o},i.Sf=function(e){this.C=e},i.Oh=function(){return this.C},i.Rg=function(e,t){if(0!=e.length){var n=(Date.now()+this.A)/1e3;if(0!=(e=e.filter((function(e){return e.start+t<n}))).length){var i=e[e.length-1].end+t;this.be(e[0].start+t),this.h=e.reduce((function(e,t){return Math.max(e,t.end-t.start)}),this.h),this.g=Math.max(this.g,i),null!=this.i&&this.F&&!this.s&&(this.i=n-this.g-this.h)}}},i.vd=function(e){if(0!=e.length){for(var t=e[0].startTime,n=e[0].endTime,i=(Date.now()+this.A)/1e3,r=(e=l(e)).next();!r.done;r=e.next())i<(r=r.value).startTime||(t=Math.min(t,r.startTime),n=Math.max(n,r.endTime),this.h=Math.max(this.h,r.endTime-r.startTime));this.be(t),this.g=Math.max(this.g,n),null!=this.i&&this.F&&!this.s&&(this.i=i-this.g-this.h)}},i.Qg=function(e,t){this.be(e),1/0==t||this.U()||(this.g=Math.max(this.g,t))},i.Xh=function(){return this.g},i.Xd=function(){this.s=!0},i.vi=function(){return this.s},i.fh=function(e){this.m=e},i.Th=function(){return this.m},i.be=function(e){null==this.j?this.j=e:this.I||(this.j=Math.min(this.j,e))},i.Bf=function(e){this.h=Math.max(this.h,e)},i.offset=function(e){null!=this.j&&(this.j+=e),null!=this.g&&(this.g+=e)},i.U=function(){return 1/0==this.l&&!this.B},i.uc=function(){return 1/0!=this.l&&!this.B},i.qb=function(){return Math.max(this.H,this.Yb()-this.o)},i.jh=function(e){this.H=e},i.Yb=function(){return this.U()||this.uc()?Math.min(Math.max(0,(Date.now()+this.A)/1e3-this.h-this.i)+this.G,this.l):this.g?Math.min(this.g,this.l):this.l},i.jd=function(e){var t=Math.max(this.j,this.H);return 1/0==this.o?Math.ceil(1e3*t)/1e3:Math.max(t,Math.min(this.Yb()-this.o+e,this.Bb()))},i.Kb=function(){return this.jd(0)},i.Bb=function(){return Math.max(0,this.Yb()-(this.U()||this.uc()?this.C:0))},i.qh=function(){return!(null==this.i||null!=this.g&&this.F)},i.dh=function(e){this.G=e},i.Mh=function(){return this.G},F("shaka.media.PresentationTimeline",Ls),Ls.prototype.getAvailabilityTimeOffset=Ls.prototype.Mh,Ls.prototype.setAvailabilityTimeOffset=Ls.prototype.dh,Ls.prototype.usingPresentationStartTime=Ls.prototype.qh,Ls.prototype.getSeekRangeEnd=Ls.prototype.Bb,Ls.prototype.getSeekRangeStart=Ls.prototype.Kb,Ls.prototype.getSafeSeekRangeStart=Ls.prototype.jd,Ls.prototype.getSegmentAvailabilityEnd=Ls.prototype.Yb,Ls.prototype.setUserSeekStart=Ls.prototype.jh,Ls.prototype.getSegmentAvailabilityStart=Ls.prototype.qb,Ls.prototype.isInProgress=Ls.prototype.uc,Ls.prototype.isLive=Ls.prototype.U,Ls.prototype.offset=Ls.prototype.offset,Ls.prototype.notifyMaxSegmentDuration=Ls.prototype.Bf,Ls.prototype.notifyMinSegmentStartTime=Ls.prototype.be,Ls.prototype.getInitialProgramDateTime=Ls.prototype.Th,Ls.prototype.setInitialProgramDateTime=Ls.prototype.fh,Ls.prototype.isStartTimeLocked=Ls.prototype.vi,Ls.prototype.lockStartTime=Ls.prototype.Xd,Ls.prototype.getMaxSegmentEndTime=Ls.prototype.Xh,Ls.prototype.notifyPeriodDuration=Ls.prototype.Qg,Ls.prototype.notifySegments=Ls.prototype.vd,Ls.prototype.notifyTimeRange=Ls.prototype.Rg,Ls.prototype.getDelay=Ls.prototype.Oh,Ls.prototype.setDelay=Ls.prototype.Sf,Ls.prototype.getSegmentAvailabilityDuration=Ls.prototype.Qd,Ls.prototype.setSegmentAvailabilityDuration=Ls.prototype.pe,Ls.prototype.setStatic=Ls.prototype.Bc,Ls.prototype.setClockOffset=Ls.prototype.eh,Ls.prototype.getPresentationStartTime=Ls.prototype.ai,Ls.prototype.setDuration=Ls.prototype.bb,Ls.prototype.setPresentationStartTime=Ls.prototype.gh,Ls.prototype.getMaxSegmentDuration=Ls.prototype.Wh,Ls.prototype.getDuration=Ls.prototype.getDuration,Ns.prototype.release=function(){this.j=this.l=null,this.i=function(){}},Us.prototype.release=function(){this.l&&(this.l.release(),this.l=null),null!=this.o&&(this.o.stop(),this.o=null),this.h&&(this.h.release(),this.h=null),this.g=this.B=this.A=null},Us.prototype.Ef=function(){this.s=!0,_s(this)};var Fs=new Pe((function(){return new Map([[HTMLMediaElement.HAVE_METADATA,"loadedmetadata"],[HTMLMediaElement.HAVE_CURRENT_DATA,"loadeddata"],[HTMLMediaElement.HAVE_FUTURE_DATA,"canplay"],[HTMLMediaElement.HAVE_ENOUGH_DATA,"canplaythrough"]])}));function Vs(e,t,n,i){var r=this;this.g=e,this.m=t,this.s=n,this.l=null,this.j=function(){return null==r.l&&(r.l=i()),r.l},this.o=!1,this.h=new Z,this.i=new qs(e),Bs(this.g,HTMLMediaElement.HAVE_METADATA,this.h,(function(){Ks(r,r.j())}))}function Hs(e){return e.o?e.g.currentTime:e.j()}function Gs(e,t){0<e.g.readyState?zs(e.i,t):Bs(e.g,HTMLMediaElement.HAVE_METADATA,e.h,(function(){Ks(e,e.j())}))}function Ks(e,t){.001>Math.abs(e.g.currentTime-t)?Xs(e):(e.h.pa(e.g,"seeking",(function(){Xs(e)})),zs(e.i,e.g.currentTime&&0!=e.g.currentTime?e.g.currentTime:t))}function Xs(e){e.o=!0,e.h.D(e.g,"seeking",(function(){return e.m()})),e.s(e.g.currentTime)}function qs(e){var t=this;this.g=e,this.m=10,this.j=this.l=this.i=0,this.h=new Be((function(){0>=t.i||t.g.currentTime!=t.l||t.g.currentTime===t.j?t.h.stop():(t.g.currentTime=t.j,t.i--)}))}function zs(e,t){e.l=e.g.currentTime,e.j=t,e.i=e.m,e.g.currentTime=t,e.h.Ra(.1)}function Ws(e){this.h=e,this.j=!1,this.g=null,this.i=new Z}function Ys(e,t,n,i,r,a){var o=this;this.i=e,this.g=t.presentationTimeline,this.B=t.minBufferTime||0,this.l=n,this.A=r,this.s=null,this.o=function(e,t,n){if(!t.stallEnabled)return null;var i=t.stallSkip;return function(e,t){e.i=t}(t=new Ns(new js(e),t.stallThreshold,n),(function(){i?e.currentTime+=i:(e.pause(),e.play())})),t}(e,n,a),this.j=new Us(e,t.presentationTimeline,n,this.o,a),this.h=new Vs(e,(function(){e:{var e=o.j;e.j=!0,e.s=!1;var t=Hs(o.h);if(e=$s(o,t),.001<Math.abs(e-t)){if(t=!1,!ze()||ze()&&nt())t=!0;else{var n=Date.now()/1e3,i=ze()&&rt("Fuchsia")?3:1;(!o.s||o.s<n-i)&&(o.s=n,t=!0)}if(t){Gs(o.h,e),e=void 0;break e}}o.A(),e=void 0}return e}),(function(e){var t=o.j;t.g.seeking&&!t.j&&(t.j=!0,t.i=e)}),(function(){var e=i;return null==e?e=1/0>o.g.getDuration()?o.g.Kb():o.g.Bb():0>e&&(e=o.g.Bb()+e),Js(o,Qs(o,e))})),this.m=new Be((function(){if(0!=o.i.readyState&&!o.i.paused){var e=Hs(o.h),t=o.g.Kb(),n=o.g.Bb();3>n-t&&(t=n-3),e<t&&(e=$s(o,e),o.i.currentTime=e)}}))}function Js(e,t){var n=e.g.getDuration();return t>=n?n-e.l.durationBackoff:t}function $s(e,t){var n=Math.max(e.B,e.l.rebufferingGoal),i=e.l.safeSeekOffset,r=e.g.Kb(),a=e.g.Bb(),o=e.g.getDuration();3>a-r&&(r=a-3);var s=e.g.jd(n),u=e.g.jd(i);return n=e.g.jd(n+i),t>=o?Js(e,t):t>a?a-e.l.safeSeekEndOffset:t<r?xo(e.i.buffered,u)?u:n:t>=s||xo(e.i.buffered,t)?t:n}function Qs(e,t){var n=e.g.Kb();return t<n?n:t>(e=e.g.Bb())?e:t}function Zs(e){this.g=e,this.m=null,this.i=0,this.o=!1}function eu(e){return e.g[0]||null}function tu(e,t,n){return new Zs([e=new vo(e,e+t,(function(){return n}),0,null,null,e,e,e+t)])}function nu(e,t,n,i){this.i=e,this.h=t,this.g=n,this.reverse=i}function iu(){Zs.call(this,[]),this.h=[]}function ru(e){var t=this;this.g=e,this.j=!1,this.i=this.g.Pd(),this.h=new Be((function(){t.g.Og(.25*t.i)}))}function au(e){e.h.stop();var t=e.j?0:e.i;if(0<=t)try{return void(e.g.Pd()!=t&&e.g.Vf(t))}catch(e){}e.h.Ra(.25),0!=e.g.Pd()&&e.g.Vf(0)}function ou(e){var t=this;this.h=e,this.g=new Set,this.i=new Be((function(){su(t,!1)})).Ra(.25)}function su(e,t){for(var n=l(e.g),i=n.next();!i.done;i=n.next())i.value.j(e.h.currentTime,t)}function uu(){this.g=null,this.h=[]}function lu(e,t){var n=0;e.g&&e.g.state==t&&(n+=e.g.duration);for(var i=(e=l(e.h)).next();!i.done;i=e.next())n+=(i=i.value).state==t?i.duration:0;return n}function cu(){this.i=this.h=null,this.g=[]}function du(e,t,n){e.i!=t&&(e.i=t,e.g.push({timestamp:Date.now()/1e3,id:t.id,type:"text",fromAdaptation:n,bandwidth:null}))}function hu(){this.kc=this.Kg=this.s=this.A=this.I=this.B=this.o=this.j=this.H=this.C=this.i=this.S=this.Y=this.L=this.M=this.O=this.l=this.m=NaN,this.K=0,this.F=this.G=NaN,this.g=new uu,this.h=new cu}function fu(e,t,n,i){this.m=e,this.i=t,this.l=n,this.h=new Map,this.j=new Map,this.g=null,this.o=i}function pu(e,t){e.l=t;for(var n=(e=l(e.h.values())).next();!n.done;n=e.next())n.value.g=t}function gu(e,t,n){if(n=void 0!==n&&n,!e.i.segmentIndex)return Promise.resolve();if(e.g||(e.g=e.i.segmentIndex.Jb(t,!0,e.o)),!e.g)return Promise.resolve();for(n&&e.g.next(),t=[];e.h.size<e.m&&(n=e.g.next().value);){var i=!0;n.isPreload()&&null!=n.va&&(i=!1),2==n.$b()&&(i=!1),n.pc()&&(i=!1),i&&n.ba&&t.push(mu(e,n.ba)),i&&!e.h.has(n)&&(i=new Su(e.l),t.push(xu(i,n,e.i)),e.h.set(n,i))}return bu(e),Promise.all(t)}function mu(e,t){if(!e.i.segmentIndex||t.pc()||Array.from(e.j.keys()).some((function(e){return mo(e,t)})))return Promise.resolve();var n=new Su(e.l),i=xu(n,t,e.i);return e.j.set(t,n),i}function vu(e,t){for(var n=(t=l(t.keys())).next();!n.done;n=t.next())(n=n.value)&&Tu(e,n)}function yu(e){vu(e,e.h),vu(e,e.j),e.g=null}function bu(e){for(var t=Array.from(e.h.keys()),n=l(e.j.keys()),i=n.next(),r={};!i.done;r={rf:void 0},i=n.next())r.rf=i.value,t.some(function(e){return function(t){return mo(t.ba,e.rf)}}(r))||Tu(e,r.rf)}function wu(e,t){e.m=t;for(var n=Array.from(e.h.keys());n.length>t;){var i=n.pop();i&&Tu(e,i)}bu(e)}function Tu(e,t){var n=e.h;t instanceof go&&(n=e.j),e=n.get(t),n.delete(t),e&&e.abort()}function Su(e){this.g=e,this.wd=this.Xf=null}function xu(e,t,n){var i=new Uint8Array(0);return e.wd=e.g(t,n,(function(t){return P((function(n){if(1==n.g)return i=0<i.byteLength?di(i,t):t,e.Xf?w(n,e.Xf(i),3):n.u(0);i=new Uint8Array(0),T(n)}))})),e.wd.promise.catch((function(e){return e instanceof De&&7001==e.code?Promise.resolve():Promise.reject(e)}))}function Au(e){Zr.call(this);var t=this;this.g=new Set,this.i=e,this.h=new Be((function(){for(var e=t.i(),n=l(t.g),i=n.next();!i.done;i=n.next())(i=i.value).endTime<e.start&&(t.g.delete(i),i=new Jr("regionremove",new Map([["region",i]])),t.dispatchEvent(i))})).Ra(2)}function Eu(e){Zr.call(this),this.g=new Map,this.h=e}function ku(e,t,n){return!!((e=e.h()[n])&&0<e.length&&(n=e[e.length-1].end,t>=e[0].start&&t<n))}function Iu(e){var t={bandwidth:e.bandwidth||0,audioSamplingRate:null,codecs:e.codecs,contentType:e.type,frameRate:null,height:null,mimeType:e.mimeType,channelsCount:null,pixelAspectRatio:null,width:null,label:null,roles:e.roles,language:null};return"video"==e.type&&(t.frameRate=e.frameRate||null,t.height=e.height||null,t.pixelAspectRatio=e.pixelAspectRatio||null,t.width=e.width||null),"audio"==e.type&&(t.audioSamplingRate=e.audioSamplingRate,t.channelsCount=e.channelsCount,t.label=e.label||null,t.language=e.language),t}function Mu(e){var t=Di(e);return{type:t.split("/")[0],mimeType:t,codecs:e=Ri(e),language:null,height:null,width:null,channelCount:null,sampleRate:null,closedCaptions:new Map,Cd:null,colorGamut:null,frameRate:null}}function Cu(e){for(var t=new Set,n=[],i=(e=l(e)).next();!i.done;i=e.next()){var r=Ci(i=i.value);t.has(r)||(n.push(i),t.add(r))}return t=vi("audio",n),i=vi("video",n),e=vi(yi,n),i=function(e){if(1>=e.length)return e;var t=e.find((function(e){return e.startsWith("dvav.")||e.startsWith("dva1.")||e.startsWith("dvh1.")||e.startsWith("dvhe.")||e.startsWith("dav1.")||e.startsWith("dvc1.")||e.startsWith("dvi1.")}));return t?ne('video/mp4; codecs="'+t+'"')?[t]:e.filter((function(e){return e!=t})):e}(i),t=t.concat(i).concat(e),n.length&&!t.length?n:t}function Du(t,n,i){var r,a,o,s,u;return P((function(l){if(1==l.g)return(r=n).cryptoKey?l.u(2):w(l,r.fetchKey(),3);if(!(a=r.iv))for(a=ge(new ArrayBuffer(16)),o=r.firstMediaSequenceNumber+i,s=a.byteLength-1;0<=s;s--)a[s]=255&o,o>>=8;return u="CBC"==n.blockCipherMode?{name:"AES-CBC",iv:a}:{name:"AES-CTR",counter:a,length:64},l.return(e.crypto.subtle.decrypt(u,r.cryptoKey,t))}))}function Ru(e,t,n,i,r){return e=aa(e,i,r),0==t&&null==n||(e.headers.Range=n?"bytes="+t+"-"+n:"bytes="+t+"-"),e}function Pu(e,t){var n=this;this.g=t,this.l=e,this.h=null,this.G=new Map,this.B=1,this.s=this.j=null,this.I=0,this.i=new Map,this.F=!1,this.K=null,this.A=!1,this.m=new fa((function(){return function(e){var t,n,i,r,a,o;return P((function(s){if(1==s.g){for(t=[],n=l(e.i.values()),i=n.next();!i.done;i=n.next())Wu(r=i.value),t.push(Yu(r)),r.W&&(yu(r.W),r.W=null);for(a=l(e.o.values()),o=a.next();!o.done;o=a.next())yu(o.value);return w(s,Promise.all(t),2)}e.i.clear(),e.o.clear(),e.g=null,e.l=null,e.h=null,T(s)}))}(n)})),this.L=Date.now()/1e3,this.o=new Map,this.H={projection:null,hfov:null},this.O=0,this.M=1/0,this.C=null}function Lu(e,t){for(var n=0>e.g.ib(),i=l(e.i.values()),r=i.next();!r.done;r=i.next())(r=r.value).ia&&r.ia.Zc(n),r.W&&r.W.Zc(n);for(r=(i=l(e.o.values())).next();!r.done;r=i.next())r.value.Zc(n);(n=e.i.get("video"))&&(i=n.stream)&&(t?(t=i.trickModeVideo)&&!n.dc&&(Ou(e,t,!1,0,!1),n.dc=i):(t=n.dc)&&(n.dc=null,Ou(e,t,!0,0,!1)))}function Nu(e,t,n,i,r,a){n=void 0!==n&&n,i=void 0===i?0:i,r=void 0!==r&&r,a=void 0!==a&&a,e.j=t,e.F&&(t.video&&Ou(e,t.video,n,i,r,a),t.audio&&Ou(e,t.audio,n,i,r,a))}function ju(e,t){P((function(n){if(1==n.g)return e.C=null,e.s=t,e.F?t.segmentIndex?n.u(2):w(n,t.createSegmentIndex(),2):n.return();Ou(e,t,!0,0,!1),T(n)}))}function Ou(e,t,n,i,r,a){var o=e.i.get(t.type);o||t.type!=yi?o&&(o.dc&&(t.trickModeVideo?(o.dc=t,t=t.trickModeVideo):o.dc=null),o.stream!=t||r)&&(e.o.has(t)?o.W=e.o.get(t):o.W&&function(e,t){t&&t!==e.i&&(yu(e),e.i=t)}(o.W,t),t.type==yi&&(r=xi(t.mimeType,t.codecs),gs(e.g.ca,r,e.l.sequenceMode,t.external)),!e.o.has(o.stream)&&o.stream.closeSegmentIndex&&(o.Ea?(r="("+o.type+":"+o.stream.id+")",e.G.has(r)||e.G.set(r,o.stream.closeSegmentIndex)):o.stream.closeSegmentIndex()),r=o.stream.isAudioMuxedInVideo!=t.isAudioMuxedInVideo,o.stream=t,o.ia=null,o.jg=!!a,r?$u(e,!0,!1):(n?o.bd?o.De=!0:o.Ea?(o.jc=!0,o.Kd=i,o.De=!0):(Wu(o),qu(e,o,!0,i).catch((function(t){e.g&&e.g.onError(t)}))):o.Ea||o.eb||zu(e,o,0),function(e,t){var n,i;return P((function(r){if(1==r.g)return t.mb?(n=t.stream,i=t.mb,n.segmentIndex?r.u(2):w(r,n.createSegmentIndex(),2)):r.return();if(t.mb!=i||t.stream!=n)return r.return();var a=e.g.hd(),o=ys(e.g.ca,t.type),s=t.stream.segmentIndex.find(t.Sa?t.Sa.endTime:a),u=null==s?null:t.stream.segmentIndex.get(s);s=u&&u.va?u.va-u.Ja:null,u&&!s&&(s=(u.endTime-u.getStartTime())*(t.stream.bandwidth||0)/8),s?((u=u.ba)&&(s+=(u.va?u.va-u.Ja:null)||0),a=8*s/(u=e.g.getBandwidthEstimate())<(o||0)-a-Math.max(e.l.minBufferTime||0,e.h.rebufferingGoal)||t.mb.h.g>s):a=!1,a&&t.mb.abort(),T(r)}))}(e,o).catch((function(t){e.g&&e.g.onError(t)})))):function(e,t){var n,i,r,a,o;P((function(s){switch(s.g){case 1:return n=bi,e.I++,i=e.I,S(s,2),w(s,Ts(e.g.ca,n.wa),4);case 4:A(s,3);break;case 2:r=E(s),e.g&&e.g.onError(r);case 3:a=xi(t.mimeType,t.codecs),gs(e.g.ca,a,e.l.sequenceMode,t.external),(e.g.ca.fa.isTextVisible()||e.h.alwaysStreamText)&&e.I==i&&(o=_u(e,t),e.i.set(n.wa,o),zu(e,o,0)),T(s)}}))}(e,t)}function Uu(e,t){t.bd||t.jc||(t.Ea?(t.jc=!0,t.Kd=0):null==vs(e.g.ca,t.type)?null==t.eb&&zu(e,t,0):(Wu(t),qu(e,t,!1,0).catch((function(t){e.g&&e.g.onError(t)}))))}function _u(e,t){return{stream:t,type:t.type,ia:null,W:Bu(e,t),Sa:null,Oc:null,Wd:null,wc:null,vc:null,dc:null,endOfStream:!1,Ea:!1,eb:null,jc:!1,Kd:0,De:!1,bd:!1,Xc:!0,Kf:!1,ld:!1,mb:null}}function Bu(e,t){if("video"===t.type&&e.h.disableVideoPrefetch||"audio"===t.type&&e.h.disableAudioPrefetch||t.type===yi&&("application/cea-608"==t.mimeType||"application/cea-708"==t.mimeType)||t.type===yi&&e.h.disableTextPrefetch)return null;if(e.o.has(t))return e.o.get(t);var n=e.i.get(t.type);return(n=n&&n.W)&&t===n.i?n:0<e.h.segmentPrefetchLimit?new fu(e.h.segmentPrefetchLimit,t,(function(t,n,i){return Xu(t,n,i||null,e.h.retryParameters,e.g.Nb)}),0>e.g.ib()):null}function Fu(e,t,n,i,r,a,o,s){var u,l,c,d;return P((function(h){if(1==h.g)return u=bi,l=new Map,e.j.audio&&l.set(u.V,e.j.audio),e.j.video&&l.set(u.la,e.j.video),S(h,2),t.wc=i,t.vc=r,o&&(t.xf=o),s&&(t.yf=s),t.Wd=n,c=e.l.sequenceMode||"HLS"==e.l.type,w(h,function(e,t,n,i,r,a,o,s,u){var l,c;return P((function(d){return 1==d.g?t==(l=bi).wa?(a||(e.h.s=n),function(e,t,n){e.l=t,e.m=n}(e.h,i,r),d.return()):(c=[],w(d,function(e,t,n,i,r){var a,o,s,u,l,c,d,h,f,p,g,m,v,y,b;return P((function(T){return 1==T.g?t==(a=bi).wa?T.return(!1):(o=Mi(Ri(e.G[t])),s=Di(e.G[t]),l=!1,c=xi(n,i),d=e.A.forceTransmux,(!ne(c)||!e.C&&ji.includes(c))&&(d=!0),d&&(h=Ai(n,i),f=On(h))&&(u=f(),p=mi(a.V,(i||"").split(",")),g=mi(a.la,(i||"").split(",")),p&&g?(l=!0,m=g,t==a.V&&(m=p),c=u.convertCodecs(t,Ai(n,m))):c=u.convertCodecs(t,h)),v=Mi(Ri(c)),y=Di(c),o===v&&s===y?(e.j[t]&&!u?(e.j[t].destroy(),delete e.j[t]):!e.j[t]&&u?e.j[t]=u:u&&(e.j[t]&&e.j[t].transmux!=u.transmux?(e.j[t].destroy(),delete e.j[t],e.j[t]=u):u.destroy()),T.return(!1)):(b=!0,(e.m||l&&u&&!e.j[t])&&(b=!1),b&&"smooth"===e.A.codecSwitchingStrategy&&ie()?w(T,function(e,t,n,i){return ks(e,t,(function(){t!==yi&&(ie()&&(e.j[t]&&(e.j[t].destroy(),delete e.j[t]),i&&(e.j[t]=i),e.i[t].changeType(n+e.A.addExtraFeaturesToSourceBuffer(n)),e.G[t]=n),Es(e,t))}),null)}(e,t,c,u),3):(u&&u.destroy(),w(T,Ds(e,r),3)))):T.return(!0)}))}(e,t,o,s,u),2)):(d.h||(c.push(ks(e,t,(function(){return xs(e,t)}),null)),e.m&&c.push(ks(e,l.V,(function(){return xs(e,l.V)}),null))),a||(c.push(ks(e,t,(function(){return As(e,t,n)}),null)),e.m&&c.push(ks(e,l.V,(function(){return As(e,l.V,n)}),null))),c.push(ks(e,t,(function(){e.i[t].appendWindowStart=0,e.i[t].appendWindowEnd=r,e.i[t].appendWindowStart=i,Es(e,t)}),null)),e.m&&c.push(ks(e,l.V,(function(){var t=l.V;e.i[t].appendWindowStart=0,e.i[t].appendWindowEnd=r,e.i[t].appendWindowStart=i,Es(e,t)}),null)),w(d,Promise.all(c),0))}))}(e.g.ca,t.type,n,i,r,c,a.mimeType||t.stream.mimeType,a.codecs||t.stream.codecs,l),4);if(2!=h.g)return A(h,0);throw d=E(h),t.wc=null,t.vc=null,t.xf=null,t.yf=null,t.Wd=null,d}))}function Vu(e,t,n,i,r,a,o,s){var u,l,c,d,h,f;return o=void 0!==o&&o,s=void 0!==s&&s,P((function(p){switch(p.g){case 1:return u=i.closedCaptions&&0<i.closedCaptions.size,e.h.shouldFixTimestampOffset&&(c="video/mp4"==i.mimeType||"audio/mp4"==i.mimeType,d=null,r.ba&&(d=r.ba.timescale),(h=c&&d&&"video"===i.type&&"DASH"==e.l.type)&&(l=new Ta),h&&l.box("moof",Sa).box("traf",Sa).R("tfdt",(function(n){var i,a,o,s,u;return P((function(l){return i=Uo(n.reader,n.version),(a=i.baseMediaDecodeTime)?(o=-a/d,(Number(t.Wd)||0)<o?(s=t.wc,u=t.vc,w(l,Fu(e,t,o,s,u,r),0)):l.u(0)):l.return()}))})),h&&l.parse(a,!1,o)),w(p,Hu(e,t,n),2);case 2:return pa(e.m),f=t.Xc,t.Xc=!1,w(p,e.g.mg(t.type,a),3);case 3:return w(p,ws(e.g.ca,t.type,a,r,i,u,f,s,o),4);case 4:pa(e.m),T(p)}}))}function Hu(e,t,n){var i,r,a,o;return P((function(s){return 1==s.g?((i=t.stream.segmentIndex)instanceof iu&&i.Ha(e.l.presentationTimeline.Kb()),r=Math.max(e.h.bufferBehind*e.B,e.l.presentationTimeline.h),null==(a=vs(e.g.ca,t.type))?(e.C==t&&(e.C=null),s.return()):(o=n-a-r)<=e.h.evictionGoal?s.return():w(s,e.g.ca.remove(t.type,a,a+o),2)):4!=s.g?(pa(e.m),e.C?w(s,Hu(e,e.C,n),4):s.u(0)):(pa(e.m),void T(s))}))}function Gu(e){return e&&e.type==yi&&("application/cea-608"==e.stream.mimeType||"application/cea-708"==e.stream.mimeType)}function Ku(e,t,n,i){var r,a,o,s,u;return P((function(l){switch(l.g){case 1:if(r=n.pc())return l.return(r);if(a=null,t.W){var c=t.W,d=c.h;n instanceof go&&(d=c.j),d.has(n)?(c=d.get(n),i&&(c.Xf=i),a=c.wd):a=null}return a||(a=Xu(n,t.stream,i||null,e.h.retryParameters,e.g.Nb)),o=0,t.ia&&(o=t.ia.h),t.mb=a,w(l,a.promise,2);case 2:if(s=l.h,t.mb=null,u=s.data,!n.aesKey){l.u(3);break}return w(l,Du(u,n.aesKey,o),4);case 4:u=l.h;case 3:return l.return(u)}}))}function Xu(e,t,n,i,r,a){a=void 0!==a&&a;var o=e instanceof vo?e:void 0,s=o?1:0;return(e=Ru(e.N(),e.Ja,e.va,i,n)).contentType=t.type,r.request(ca,e,{type:s,stream:t,segment:o,isPreload:a})}function qu(e,t,n,i){var r,a;return P((function(o){return 1==o.g?(t.jc=!1,t.De=!1,t.Kd=0,t.bd=!0,t.Sa=null,t.ia=null,t.W&&!e.o.has(t.stream)&&yu(t.W),i?(r=e.g.hd(),a=e.g.ca.getDuration(),w(o,e.g.ca.remove(t.type,r+i,a),3)):w(o,Ts(e.g.ca,t.type),4)):3!=o.g?(pa(e.m),n?w(o,e.g.ca.flush(t.type),3):o.u(3)):(pa(e.m),t.bd=!1,t.endOfStream=!1,t.Ea||t.eb||zu(e,t,0),void T(o))}))}function zu(t,n,i){var r=n.type;(r!=yi||t.i.has(r))&&(n.eb=new _e((function(){var i;return P((function(r){return 1==r.g?(S(r,2),w(r,function(t,n){var i,r,a,o,s,u;return P((function(c){switch(c.g){case 1:if(pa(t.m),n.Ea||null==n.eb||n.bd)return c.return();if(n.eb=null,!n.jc){c.u(2);break}return w(c,qu(t,n,n.De,n.Kd),3);case 3:return c.return();case 2:if(function(e,t){for(var n=l(e.G.entries()),i=n.next();!i.done;i=n.next()){var r=l(i.value);i=r.next().value,r=r.next().value,i.includes(t.type)&&(r(),e.G.delete(i))}}(t,n),n.stream.segmentIndex){c.u(4);break}return i=n.stream,S(c,5),w(c,n.stream.createSegmentIndex(),7);case 7:A(c,6);break;case 5:return r=E(c),w(c,Ju(t,n,r),8);case 8:return c.return();case 6:if(i!=n.stream)return i.closeSegmentIndex&&i.closeSegmentIndex(),n.Ea||n.eb||zu(t,n,0),c.return();case 4:S(c,9),a=function(t,n){if(Gu(n))return function(e,t){var n=ys(e,"video")||0;_i(e.h,t,n)}(t.g.ca,n.stream.originalId||""),null;if(n.type==yi&&function(e){e.h&&_i(e.h,"",0)}(t.g.ca),n.stream.isAudioMuxedInVideo)return null;if(!function(e){return e.ta&&!e.Z&&!e.I}(t.g.ca)&&n.type!=yi)return t.h.updateIntervalSeconds/2;var i=t.g.hd();if("audio"===n.type)for(var r=l(t.o.keys()),a=r.next();!a.done;a=r.next())(a=t.o.get(a.value)).Ha(i,!0),gu(a,i);r=n.Sa?n.Sa.endTime:i;var o=function(e,t,n){return t==yi?null==(e=e.h).h||e.h<n?0:e.h-Math.max(n,e.g):Ao(e=bs(e,t),n)}(t.g.ca,n.type,i),s=Math.max(1,Math.max(t.l.minBufferTime||0,t.h.rebufferingGoal,t.h.bufferingGoal)*t.B),u=t.l.presentationTimeline.getDuration()-r;if(a=ys(t.g.ca,n.type),1e-6>u&&a)return n.endOfStream=!0,"video"==n.type&&(t=t.i.get(yi))&&Gu(t)&&(t.endOfStream=!0),null;if(n.endOfStream=!1,o>=s)return t.h.updateIntervalSeconds/2;if(s=!n.ia,a=function(e,t,n,i){if(t.ia)return t.ia.current();if(t.Sa||i)return n=t.Sa?t.Sa.endTime:i,e=0>e.g.ib(),t.stream.segmentIndex&&(t.ia=t.stream.segmentIndex.Jb(n,!1,e)),t.ia&&t.ia.next().value;i=e.l.sequenceMode?0:e.h.inaccurateManifestTolerance;var r=Math.max(n-i,0);e=0>e.g.ib();var a=null;return i&&(t.stream.segmentIndex&&(t.ia=t.stream.segmentIndex.Jb(r,!1,e)),a=t.ia&&t.ia.next().value),a||(t.stream.segmentIndex&&(t.ia=t.stream.segmentIndex.Jb(n,!1,e)),a=t.ia&&t.ia.next().value),a}(t,n,i,a),!a)return t.h.updateIntervalSeconds;o=!1,s&&n.jg&&(o=!0,n.jg=!1),s=1/0;for(var c=(u=l(u=Array.from(t.i.values()))).next();!c.done;c=u.next())Gu(c=c.value)||c.ia&&!c.ia.current()||(s=Math.min(s,c.Sa?c.Sa.endTime:i));return r>=s+t.l.presentationTimeline.h?t.h.updateIntervalSeconds:(n.W&&n.ia&&!t.o.has(n.stream)&&(n.W.Ha(a.startTime),gu(n.W,a.startTime)),function(t,n,i,r,a){var o,s,u,l,c,d,h,f,p,g,m,v,y,b,x;return P((function(k){switch(k.g){case 1:if(o=bi,s=n.stream,u=n.ia,n.Ea=!0,S(k,2),2==r.$b())throw new De(1,1,1011);return w(k,function(e,t,n,i){var r,a,o,s,u,l,c,d,h,f,p,g,m,v,y,b;return P((function(T){switch(T.g){case 1:if(r=bi,a=null==t.Sa,o=[],s=Math.max(0,Math.max(n.appendWindowStart,e.O)-.1),u=Math.min(n.appendWindowEnd,e.M)+.01,l=n.codecs||t.stream.codecs,c=Ci(l),d=Di(n.mimeType||t.stream.mimeType),(h=n.timestampOffset)==t.Wd&&s==t.wc&&u==t.vc&&c==t.xf&&d==t.yf){T.u(2);break}if(f=t.xf&&t.yf&&function(e,t,n,i){if(t==yi)var r=!1;else{r=Mi(Ri(e.G[t]));var a=Di(e.G[t]),o=xi(n,i),s=e.A.forceTransmux;(!ne(o)||!e.C&&ji.includes(o))&&(s=!0),n=Ai(n,i),s&&(s=On(n))&&(o=(s=s()).convertCodecs(t,n),s.destroy()),t=Mi(Ri(o)),o=Di(o),r=r!==t||a!==o}return!!r&&("smooth"!==e.A.codecSwitchingStrategy||!ie()||e.m)}(e.g.ca,t.type,d,l),!f){T.u(3);break}if(p=null,t.type===r.la?p=e.i.get(r.V):t.type===r.V&&(p=e.i.get(r.la)),!p){T.u(3);break}return w(T,Yu(p).catch((function(){})),5);case 5:p.Oc=null,p.wc=null,p.vc=null,Uu(e,p);case 3:return w(T,Fu(e,t,h,s,u,n,c,d),2);case 2:return mo(n.ba,t.Oc)||(t.Oc=n.ba,n.l&&n.ba&&(g=Ku(e,t,n.ba),m=function(){var a,o,s,u,l,c;return P((function(d){switch(d.g){case 1:return S(d,2),w(d,g,4);case 4:return a=d.h,pa(e.m),o=null,s=new Map,u={projection:null,hfov:null},(new Ta).box("moov",Sa).box("trak",Sa).box("mdia",Sa).R("mdhd",(function(e){o=_o(e.reader,e.version).timescale})).box("hdlr",(function(e){switch((e=e.reader).skip(8),e.yc()){case"soun":s.set(r.V,o);break;case"vide":s.set(r.la,o)}o=null})).box("minf",Sa).box("stbl",Sa).R("stsd",xa).box("encv",Aa).box("avc1",Aa).box("avc3",Aa).box("hev1",Aa).box("hvc1",Aa).box("dvav",Aa).box("dva1",Aa).box("dvh1",Aa).box("dvhe",Aa).box("dvc1",Aa).box("dvi1",Aa).box("vexu",Sa).box("proj",Sa).R("prji",(function(e){e=e.reader.yc(),u.projection=e})).box("hfov",(function(e){e=e.reader.P()/1e3,u.hfov=e})).parse(a),function(e,t){if(e.H.projection!=t.projection||e.H.hfov!=t.hfov){if(null!=t.projection||null!=t.hfov){var n=(new Map).set("detail",t);n=new Jr("spatialvideoinfo",n)}else n=new Jr("nospatialvideoinfo");n.cancelable=!0,e.g.onEvent(n),e.H=t}}(e,u),s.has(t.type)?n.ba.timescale=s.get(t.type):null!=o&&(n.ba.timescale=o),l=t.stream.closedCaptions&&0<t.stream.closedCaptions.size,w(d,e.g.mg(t.type,a),5);case 5:return w(d,ws(e.g.ca,t.type,a,null,t.stream,l,t.Xc,i),6);case 6:A(d,0);break;case 2:throw c=E(d),t.Oc=null,c}}))},v=n.startTime,a&&null!=(y=ys(e.g.ca,t.type))&&(v=y),e.g.Ei(v,n.ba),o.push(m()))),b=t.Sa?t.Sa.i:null,n.i!=b&&o.push(function(e,t,n){var i;return P((function(r){return 1==r.g?t==(i=bi).wa?r.return():(t==i.la&&(e.Ba=new Gr),e.C?(ks(e,t,(function(){return xs(e,t)}),null),e.m&&ks(e,i.V,(function(){return xs(e,i.V)}),null),w(r,ks(e,t,(function(){return As(e,t,n)}),null),2)):r.return()):e.m?w(r,ks(e,i.V,(function(){return As(e,i.V,n)}),null),0):r.u(0)}))}(e.g.ca,t.type,n.startTime)),w(T,Promise.all(o),0)}}))}(t,n,r,a),4);case 4:return pa(t.m),t.A?k.return():(l="video/mp4"==s.mimeType||"audio/mp4"==s.mimeType,c=e.ReadableStream,t.h.lowLatencyMode&&t.l.isLowLatency&&c&&l&&("HLS"!=t.l.type||r.m)?(h=new Uint8Array(0),p=f=!1,m=function(e){var o,u,l;return P((function(c){switch(c.g){case 1:if(f)return c.return();if(p=!0,pa(t.m),t.A)return c.return();if(S(c,2),h=function(e,t){var n=new Uint8Array(e.length+t.length);return n.set(e),n.set(t,e.length),n}(h,e),o=!1,u=0,(new Ta).box("mdat",(function(e){u=e.size+e.start,o=!0})).parse(h,!1,!0),!o){c.u(4);break}return l=h.subarray(0,u),h=h.subarray(u),w(c,Vu(t,n,i,s,r,l,!0,a),5);case 5:n.W&&n.ia&&gu(n.W,r.startTime,!0);case 4:A(c,0);break;case 2:g=E(c),T(c)}}))},w(k,Ku(t,n,r,m),9)):w(k,Ku(t,n,r),7));case 7:return d=k.h,pa(t.m),t.A?k.return():(pa(t.m),n.jc?(n.Ea=!1,zu(t,n,0),k.return()):w(k,Vu(t,n,i,s,r,d,!1,a),6));case 9:if(v=k.h,g)throw g;if(p){k.u(10);break}return f=!0,pa(t.m),t.A?k.return():n.jc?(n.Ea=!1,zu(t,n,0),k.return()):w(k,Vu(t,n,i,s,r,v,!1,a),10);case 10:n.W&&n.ia&&gu(n.W,r.startTime,!0);case 6:if(pa(t.m),t.A)return k.return();n.Sa=r,u.next(),n.Ea=!1,n.Kf=!1,y=t.g.ca.zb(),b=y[n.type],JSON.stringify(b),n.jc||t.g.Ef(r,n.stream),zu(t,n,0),A(k,0);break;case 2:if(x=E(k),pa(t.m,x),t.A)return k.return();if(n.Ea=!1,7001==x.code)n.Ea=!1,Wu(n),zu(t,n,0),k.u(0);else{if(n.type!=o.wa||!t.h.ignoreTextStreamFailures)return 3017==x.code?w(k,function(e,t,n){var i,r,a;return P((function(o){if(1==o.g){if(Array.from(e.i.values()).some((function(e){return e!=t&&e.Kf})))return o.u(2);if(i=0===e.h.maxDisabledTime&&1011==n.code?1:e.h.maxDisabledTime,e.g.disableStream(t.stream,i))return o.return();if(20<(r=Math.round(100*e.B)))e.B-=.2;else{if(!(4<r))return t.ld=!0,e.A=!0,e.g.onError(n),o.return();e.B-=.04}return t.Kf=!0,a=e.g.hd(),w(o,Hu(e,t,a),2)}zu(e,t,4),T(o)}))}(t,n,x),0):(n.ld=!0,1==x.category&&n.W&&Tu(n.W,r),x.severity=2,w(k,Ju(t,n,x),0));t.i.delete(o.wa),k.u(0)}}}))}(t,n,i,a,o).catch((function(){})),null)}(t,n),null!=a&&(zu(t,n,a),n.ld=!1),A(c,10);break;case 9:return o=E(c),w(c,Ju(t,n,o),11);case 11:return c.return();case 10:if(s=Array.from(t.i.values()),!t.F||!s.every((function(e){return e.endOfStream}))){c.u(0);break}return w(c,t.g.ca.endOfStream(),13);case 13:pa(t.m),0!=(u=t.g.ca.getDuration())&&u<t.l.presentationTimeline.getDuration()&&t.l.presentationTimeline.bb(u),T(c)}}))}(t,n),4)):2!=r.g?A(r,0):(i=E(r),t.g&&t.g.onError(i),void T(r))}))})).$(i))}function Wu(e){null!=e.eb&&(e.eb.stop(),e.eb=null)}function Yu(e){return P((function(t){return e.mb?w(t,e.mb.abort(),0):t.u(0)}))}function Ju(e,t,n){var i;return P((function(r){if(1==r.g)return w(r,Hr(e.K),2);if(pa(e.m),1===n.category&&1003!=n.code){if(t.dc)return Lu(e,!1),r.return();i=0===e.h.maxDisabledTime&&1011==n.code?1:e.h.maxDisabledTime,n.handled=e.g.disableStream(t.stream,i),n.handled&&(n.severity=1)}n.handled&&1011==n.code||e.g.onError(n),n.handled||e.h.failureCallback(n),T(r)}))}function $u(e,t,n){var i,r,a,o,s,u;return t=void 0!==t&&t,n=void 0===n||n,P((function(l){if(1==l.g){if(i=Date.now()/1e3,r=e.h.minTimeBetweenRecoveries,!t){if(!e.h.allowMediaSourceRecoveries||i-e.L<r)return l.return(!1);e.L=i}return a=bi,(o=e.i.get(a.V))&&(o.Oc=null,o.wc=null,o.vc=null,n&&Uu(e,o),Yu(o).catch((function(){})),o.ia&&o.ia.Mf()),(s=e.i.get(a.la))&&(s.Oc=null,s.wc=null,s.vc=null,n&&Uu(e,s),Yu(s).catch((function(){})),s.ia&&s.ia.Mf()),u=new Map,e.j.audio&&u.set(a.V,e.j.audio),e.j.video&&u.set(a.la,e.j.video),w(l,Ds(e.g.ca,u),2)}return!s||s.Ea||s.eb||zu(e,s,0),!o||o.Ea||o.eb||zu(e,o,0),l.return(!0)}))}function Qu(){}function Zu(e,t,n,i,r){var a,o=r in i,s=o?n.constructor==Object&&0==Object.keys(i).length:n.constructor==Object&&0==Object.keys(n).length,u=o||s,l=!0;for(a in t){var c=r+"."+a,d=o?i[r]:n[a];u||a in n?void 0===t[a]?void 0===d||u?delete e[a]:e[a]=kt(d):s?e[a]=t[a]:d.constructor==Object&&t[a]&&t[a].constructor==Object?(e[a]||(e[a]=kt(d)),c=Zu(e[a],t[a],d,i,c),l=l&&c):typeof t[a]!=typeof d||null==t[a]||"function"!=typeof t[a]&&t[a].constructor!=d.constructor?(z("Invalid config, wrong type for "+c),l=!1):("function"==typeof n[a]&&n[a].length!=t[a].length&&W("Unexpected number of arguments for "+c),e[a]=t[a]):(z("Invalid config, unrecognized key "+c),l=!1)}return l}function el(e,t){for(var n={},i=n,r=0,a=0;!(0>(r=e.indexOf(".",r)));)0!=r&&"\\"==e[r-1]||(i[a=e.substring(a,r).replace(/\\\./g,".")]={},i=i[a],a=r+1),r+=1;return i[e.substring(a).replace(/\\\./g,".")]=t,n}function tl(e,t){return e&&t}function nl(e,t){function n(e){return Array.isArray(e)&&0===e.length}function i(e){return e&&"object"==typeof e&&!Array.isArray(e)}return e=function e(t,r){return Object.keys(t).reduce((function(a,o){var s=t[o];return r.hasOwnProperty(o)?i(s)&&i(r[o])?(s=e(s,r[o]),(0<Object.keys(s).length||!i(s))&&(a[o]=s)):n(s)&&n(r[o])||Number.isNaN(s)&&Number.isNaN(r[o])||s!==r[o]&&(a[o]=s):a[o]=s,a}),{})}(e,t),function e(t){for(var r=l(Object.keys(t)),a=r.next();!a.done;a=r.next())i(t[a=a.value])&&0===Object.keys(t[a]).length||n(t[a])||"function"==typeof t[a]?delete t[a]:i(t[a])&&(e(t[a]),0===Object.keys(t[a]).length&&delete t[a])}(e),e}function il(){}function rl(e){return new Gn(e=ft(e)).Fb}function al(e,t,n){function i(e){ve(a).setUint32(o,e.byteLength,!0),o+=4,a.set(ge(e),o),o+=e.byteLength}if(!n||!n.byteLength)throw new De(2,6,6015);var r;r="string"==typeof t?gt(t,!0):t,e=gt(e=ft(e),!0);var a=new Uint8Array(12+e.byteLength+r.byteLength+n.byteLength),o=0;return i(e),i(r),i(n),a}function ol(e,t,n){return"skd"!==t?e:(t=n.serverCertificate,al(e,n=ft(e).split("skd://").pop(),t))}function sl(e,t){2===e&&(t.headers["Content-Type"]="application/octet-stream")}function ul(){}function ll(){var t=1/0;navigator.connection&&navigator.connection.saveData&&(t=360);var n={retryParameters:{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4},servers:{},clearKeys:{},advanced:{},delayLicenseRequestUntilPlayed:!1,persistentSessionOnlinePlayback:!1,persistentSessionsMetadata:[],initDataTransform:function(e,t,n){return ot()&&"skd"==t&&(t=n.serverCertificate,e=al(e,n=rl(e),t)),e},logLicenseExchange:!1,updateExpirationTime:1,preferredKeySystems:[],keySystemsMapping:{},parseInbandPsshEnabled:Ge(),minHdcpVersion:"",ignoreDuplicateInitData:!rt("Tizen 2")};(Ge()||$e())&&n.preferredKeySystems.push("com.microsoft.playready");var i="reload",r=!1;!ie()||Ke()||$e()||Je()||qe()&&79===We()||!(!ze()||ze()&&nt()||ze()&&rt("Fuchsia"))||tt()&&He()||(i="smooth",r=!0),r={retryParameters:{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4},availabilityWindowOverride:NaN,disableAudio:!1,disableVideo:!1,disableText:!1,disableThumbnails:!1,disableIFrames:!1,defaultPresentationDelay:0,segmentRelativeVttTiming:!1,raiseFatalErrorOnManifestUpdateRequestFailure:!1,continueLoadingWhenPaused:!0,dash:{clockSyncUri:"",ignoreDrmInfo:!1,disableXlinkProcessing:!0,xlinkFailGracefully:!1,ignoreMinBufferTime:!1,autoCorrectDrift:!0,initialSegmentLimit:1e3,ignoreSuggestedPresentationDelay:!1,ignoreEmptyAdaptationSet:!1,ignoreMaxSegmentDuration:!1,keySystemsByURI:{"urn:uuid:1077efec-c0b2-4d02-ace3-3c1e52e2fb4b":"org.w3.clearkey","urn:uuid:e2719d58-a985-b3c9-781a-b030af78d30e":"org.w3.clearkey","urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":"com.widevine.alpha","urn:uuid:9a04f079-9840-4286-ab92-e65be0885f95":"com.microsoft.playready","urn:uuid:79f0049a-4098-8642-ab92-e65be0885f95":"com.microsoft.playready","urn:uuid:94ce86fb-07ff-4f43-adb8-93d2fa968ca2":"com.apple.fps"},manifestPreprocessor:dl,manifestPreprocessorTXml:hl,sequenceMode:!1,multiTypeVariantsAllowed:r,useStreamOnceInPeriodFlattening:!1,updatePeriod:-1,enableFastSwitching:!0},hls:{ignoreTextStreamFailures:!1,ignoreImageStreamFailures:!1,defaultAudioCodec:"mp4a.40.2",defaultVideoCodec:"avc1.42E01E",ignoreManifestProgramDateTime:!1,ignoreManifestProgramDateTimeForTypes:[],mediaPlaylistFullMimeType:'video/mp2t; codecs="avc1.42E01E, mp4a.40.2"',liveSegmentsDelay:3,sequenceMode:!(Xe()||rt("Tizen 2")||qe()&&38===We()||$e()),ignoreManifestTimestampsInSegmentsMode:!1,disableCodecGuessing:!1,disableClosedCaptionsDetection:!1,updatePeriod:-1,allowLowLatencyByteRangeOptimization:!0},mss:{manifestPreprocessor:dl,manifestPreprocessorTXml:hl,sequenceMode:!1,keySystemsBySystemId:{"9a04f079-9840-4286-ab92-e65be0885f95":"com.microsoft.playready","79f0049a-4098-8642-ab92-e65be0885f95":"com.microsoft.playready"}}};var a={retryParameters:{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4},failureCallback:function(e){return tl([e])},rebufferingGoal:2,bufferingGoal:10,bufferBehind:30,evictionGoal:1,ignoreTextStreamFailures:!1,alwaysStreamText:!1,startAtSegmentBoundary:!1,gapDetectionThreshold:.5,gapPadding:.01,gapJumpTimerTime:.25,durationBackoff:1,safeSeekOffset:5,safeSeekEndOffset:0,stallEnabled:!0,stallThreshold:1,stallSkip:.1,useNativeHlsForFairPlay:!0,inaccurateManifestTolerance:2,lowLatencyMode:!1,autoLowLatencyMode:!1,forceHTTP:!1,forceHTTPS:!1,minBytesForProgressEvents:16e3,preferNativeHls:!1,updateIntervalSeconds:1,observeQualityChanges:!1,maxDisabledTime:30,segmentPrefetchLimit:0,prefetchAudioLanguages:[],disableAudioPrefetch:!1,disableTextPrefetch:!1,disableVideoPrefetch:!1,liveSync:{enabled:!1,targetLatency:.5,targetLatencyTolerance:.5,maxPlaybackRate:1.1,minPlaybackRate:.95,panicMode:!1,panicThreshold:60,dynamicTargetLatency:{enabled:!1,stabilityThreshold:60,rebufferIncrement:.5,maxAttempts:10,maxLatency:4,minLatency:1}},allowMediaSourceRecoveries:!0,minTimeBetweenRecoveries:5,vodDynamicPlaybackRate:!1,vodDynamicPlaybackRateLowBufferRate:.95,vodDynamicPlaybackRateBufferRatio:.5,infiniteLiveStreamDuration:!1,preloadNextUrlWindow:30,loadTimeout:30,clearDecodingCache:$e()||Je(),dontChooseCodecs:!1,shouldFixTimestampOffset:qe()||Ke()};(qe()||Ke()||ze()||Qe())&&(a.stallSkip=0),Ke()&&(a.gapPadding=2);var o={trackSelectionCallback:function(e){return P((function(t){return t.return(e)}))},downloadSizeCallback:function(e){var t;return P((function(n){return 1==n.g?navigator.storage&&navigator.storage.estimate?w(n,navigator.storage.estimate(),3):n.return(!0):(t=n.h,n.return(t.usage+e<.95*t.quota))}))},progressCallback:function(e,t){return tl([e,t])},usePersistentLicense:!0,numberOfParallelDownloads:5};t={enabled:!0,useNetworkInformation:!0,defaultBandwidthEstimate:1e6,switchInterval:8,bandwidthUpgradeTarget:.85,bandwidthDowngradeTarget:.95,restrictions:{minWidth:0,maxWidth:1/0,minHeight:0,maxHeight:t,minPixels:0,maxPixels:1/0,minFrameRate:0,maxFrameRate:1/0,minBandwidth:0,maxBandwidth:1/0,minChannelsCount:0,maxChannelsCount:1/0},advanced:{minTotalBytes:128e3,minBytes:16e3,fastHalfLife:2,slowHalfLife:5},restrictToElementSize:!1,restrictToScreenSize:!1,ignoreDevicePixelRatio:!1,clearBufferSwitch:!1,safeMarginSwitch:0,cacheLoadThreshold:20,minTimeToSwitch:Ye()?.5:0,preferNetworkInformationBandwidth:!1},i={codecSwitchingStrategy:i,addExtraFeaturesToSourceBuffer:function(e){return tl([e],"")},forceTransmux:!1,insertFakeEncryptionInInit:!0,modifyCueCallback:function(e,t){return tl([e,t])},dispatchAllEmsgBoxes:!1};var s=!1,u=!1,c=!0;it()&&(u=s=!0,c=!1);var d={drm:n,manifest:r,streaming:a,mediaSource:i,offline:o,abrFactory:function(){return new Mr},abr:t,autoShowText:3,preferredAudioLanguage:"",preferredAudioLabel:"",preferredTextLanguage:"",preferredVariantRole:"",preferredTextRole:"",preferredAudioChannelCount:2,preferredVideoHdrLevel:"AUTO",preferredVideoLayout:"",preferredVideoLabel:"",preferredVideoCodecs:[],preferredAudioCodecs:[],preferredTextFormats:[],preferForcedSubs:!1,preferSpatialAudio:!1,preferredDecodingAttributes:[],restrictions:{minWidth:0,maxWidth:1/0,minHeight:0,maxHeight:1/0,minPixels:0,maxPixels:1/0,minFrameRate:0,maxFrameRate:1/0,minBandwidth:0,maxBandwidth:1/0,minChannelsCount:0,maxChannelsCount:1/0},playRangeStart:0,playRangeEnd:1/0,textDisplayer:{captionsUpdatePeriod:.25},textDisplayFactory:function(){return null},cmcd:{enabled:!1,sessionId:"",contentId:"",rtpSafetyFactor:5,useHeaders:!1,includeKeys:[]},cmsd:{enabled:!0,applyMaximumSuggestedBitrate:!0,estimatedThroughputWeightRatio:.5},lcevc:{enabled:!1,dynamicPerformanceScaling:!0,logLevel:0,drawLogo:!1},ads:{customPlayheadTracker:s,skipPlayDetection:u,supportsMultipleMediaElements:c,disableHLSInterstitial:!1,disableDASHInterstitial:!1},ignoreHardwareResolution:!1};return o.trackSelectionCallback=function(t){return P((function(n){return n.return(function(t,n,i){var r=i;"AUTO"==r&&(r=e.matchMedia("(color-gamut: p3)").matches?"PQ":"SDR");var a=t.filter((function(e){return!("variant"!=e.type||e.hdr&&e.hdr!=r)}));i=[];var o=Zi(n,a.map((function(e){return e.language})));o&&(i=a.filter((function(e){return Yi(e.language)==o}))),0==i.length&&(i=a.filter((function(e){return e.primary}))),0==i.length&&(a.map((function(e){return e.language})),i=a);var s=i.filter((function(e){return e.height&&480>=e.height}));for(s.length&&(s.sort((function(e,t){return t.height-e.height})),i=s.filter((function(e){return e.height==s[0].height}))),n=[],i.length&&(a=Math.floor(i.length/2),i.sort((function(e,t){return e.bandwidth-t.bandwidth})),n.push(i[a])),i=(t=l(t)).next();!i.done;i=t.next())(i=i.value).type!=yi&&"image"!=i.type||n.push(i);return n}(t,d.preferredAudioLanguage,d.preferredVideoHdrLevel))}))},d}function cl(e,t,n){var i={".drm.keySystemsMapping":"",".drm.servers":"",".drm.clearKeys":"",".drm.advanced":{distinctiveIdentifierRequired:!1,persistentStateRequired:!1,videoRobustness:"",audioRobustness:"",sessionType:"",serverCertificate:new Uint8Array(0),serverCertificateUri:"",individualizationServer:"",headers:{}}};return Zu(e,t,n||ll(),i,"")}function dl(e){return tl([e],e)}function hl(e){return tl([e],e)}function fl(e,t,n,i){Zr.call(this),this.M=e,this.Y=t,this.Ba=i.networkingEngine,this.B=n,this.o=null,this.xa=0,this.La=i.Gc,this.F=i.yi,this.Na=i.zi,this.g=i.config,this.j=this.G=this.h=null,this.ga=!1,this.H=i.Ji,this.na=!1,this.l=null,this.da=!1,this.i=this.C=null,this.aa=!1,this.L=new Map,this.ta=!1,this.Aa=i.Ii,this.Z=new hu,this.fa=new Gr,this.m=new Gr,this.O=null,this.s=!1,this.Ka=i.Bh,this.ja=null,this.Ga=i.Ah,this.S=!1,this.K=[],this.I=[],this.A=!0}function pl(e,t,n){(e=t?e.I:e.K)?e.push(n):n()}function gl(e,t){if(e.O=t,e.S=!0,e.K)for(var n=(t=l(e.K)).next();!n.done;n=t.next())(n=n.value)();e.K=null}function ml(e){if(e.s)throw new De(2,7,7003)}function vl(e,t){e.dispatchEvent(new Jr("onstatechange",(new Map).set("state",t)))}function yl(e,t,n){var i,r,a,o,s;return P((function(u){return 1==u.g?(i=e.g.streaming.segmentPrefetchLimit||2,r=new fu(i,t,(function(t,n,i){return Xu(t,n,i||null,e.g.streaming.retryParameters,e.Ba,e.A)}),!1),e.L.set(t.id,r),w(u,t.createSegmentIndex(),2)):(a=e.B||0,(s=(o=t.segmentIndex.Jb(a))?o.current():null)||(s=eu(t.segmentIndex)),s?n?s.ba?w(u,mu(r,s.ba),0):u.u(0):w(u,gu(r,s.startTime),0):u.u(0))}))}function bl(e,t){Zr.call(this);var n=this;this.i=e,this.l=t,this.g=new Map,this.m=[{Ec:null,Dc:Sl,tc:function(e,t){return wl(n,"enter",e,t)}},{Ec:Tl,Dc:Sl,tc:function(e,t){return wl(n,"enter",e,t)}},{Ec:xl,Dc:Sl,tc:function(e,t){return wl(n,"enter",e,t)}},{Ec:Sl,Dc:Tl,tc:function(e,t){return wl(n,"exit",e,t)}},{Ec:Sl,Dc:xl,tc:function(e,t){return wl(n,"exit",e,t)}},{Ec:Tl,Dc:xl,tc:function(e,t){return wl(n,"skip",e,t)}},{Ec:xl,Dc:Tl,tc:function(e,t){return wl(n,"skip",e,t)}}],this.h=new Z,this.h.D(this.i,"regionremove",(function(e){n.g.delete(e.region)}))}function wl(e,t,n,i){t=new Jr(t,new Map([["region",n],["seeking",i]])),e.dispatchEvent(t)}Vs.prototype.release=function(){this.h&&(this.h.release(),this.h=null),null!=this.i&&(this.i.release(),this.i=null),this.m=function(){},this.g=null},qs.prototype.release=function(){this.h&&(this.h.stop(),this.h=null),this.g=null},(i=Ws.prototype).ready=function(){var e=this;Bs(this.h,HTMLMediaElement.HAVE_CURRENT_DATA,this.i,(function(){!function(){if(null==e.g||0==e.g&&1/0!=e.h.duration)e.j=!0;else{var t=e.h.currentTime,n=e.g;0>e.g&&(n=Math.max(0,t+e.g)),t!=n?(e.i.pa(e.h,"seeking",(function(){e.j=!0})),e.h.currentTime=n):e.j=!0}}()}))},i.release=function(){this.i&&(this.i.release(),this.i=null),this.h=null},i.Ie=function(e){this.g=this.j?this.g:e},i.Dd=function(){return(this.j?this.h.currentTime:this.g)||0},i.ig=function(){return 0},i.hg=function(){return 0},i.Pg=function(){},(i=Ys.prototype).ready=function(){this.m.Ra(.25)},i.release=function(){this.h&&(this.h.release(),this.h=null),this.j&&(this.j.release(),this.j=null),this.m&&(this.m.stop(),this.m=null),this.i=this.h=this.g=this.l=null,this.A=function(){}},i.Ie=function(e){Gs(this.h,e)},i.Dd=function(){var e=Hs(this.h);return 0<this.i.readyState&&!this.i.paused?Qs(this,e):e},i.ig=function(){return this.o?this.o.o:0},i.hg=function(){return this.j.C},i.Pg=function(){this.j.Ef()},(i=Zs.prototype).getNumReferences=function(){return this.g.length},i.getNumEvicted=function(){return this.i},i.release=function(){this.o||(this.g=[],this.m&&this.m.stop(),this.m=null)},i.Bi=function(){this.o=!0},i.yb=function(e){for(var t=l(this.g),n=t.next();!n.done;n=t.next())e(n.value)},i.find=function(e){for(var t=this.g.length-1,n=t;0<=n;--n){var i=this.g[n],r=n<t?this.g[n+1].startTime:i.endTime;if(e>=i.startTime&&e<r)return n+this.i}return this.g.length&&e<this.g[0].startTime?this.i:null},i.get=function(e){return 0==this.g.length||0>(e-=this.i)||e>=this.g.length?null:this.g[e]},i.offset=function(e){if(!this.o)for(var t=l(this.g),n=t.next();!n.done;n=t.next())n.value.offset(e)},i.Zd=function(e){if(!this.o&&e.length){var t=Math.round(1e3*e[0].startTime)/1e3;this.g=this.g.filter((function(e){return Math.round(1e3*e.startTime)/1e3<t})),this.g.push.apply(this.g,c(e))}},i.td=function(e,t){var n=this;e=e.filter((function(e){return e.endTime>t&&(0==n.g.length||e.endTime>n.g[0].startTime)})),this.Zd(e),this.Ha(t)},i.Ha=function(e){if(!this.o){var t=this.g.length;this.g=this.g.filter((function(t){return t.endTime>e})),this.i+=t-this.g.length}},i.Kc=function(e,t,n){if(n=void 0!==n&&n,!this.o){for(;this.g.length&&this.g[this.g.length-1].startTime>=t;)this.g.pop();for(;this.g.length&&this.g[0].endTime<=e;)this.g.shift(),n||this.i++;0!=this.g.length&&((t=new vo((e=this.g[this.g.length-1]).startTime,t,e.C,e.Ja,e.va,e.ba,e.timestampOffset,e.appendWindowStart,e.appendWindowEnd,e.g,e.tilesLayout,e.A,e.h,e.status,e.aesKey)).mimeType=e.mimeType,t.codecs=e.codecs,t.i=e.i,this.g[this.g.length-1]=t)}},i.ue=function(e,t){var n=this;this.o||(this.m&&this.m.stop(),this.m=new Be((function(){var e=t();e?n.g.push.apply(n.g,c(e)):(n.m.stop(),n.m=null)})),this.m.Ra(e))},Zs.prototype[Symbol.iterator]=function(){return this.Jb(0)},Zs.prototype.Jb=function(e,t,n){t=void 0!==t&&t,n=void 0!==n&&n;var i=this.find(e);if(null==i)return null;var r=this.get(i);n?i++:i--;var a=-1;if(r&&0<r.g.length)for(var o=r.g.length-1;0<=o;--o){var s=r.g[o];if(e>=s.startTime&&e<s.endTime){if(!t){for(;o&&!s.l;)o--,s=r.g[o];if(!s.l)return z("No independent partial segment found!"),null}n?i--:i++,a=o-1;break}}return new nu(this,i,a,n)},F("shaka.media.SegmentIndex",Zs),Zs.forSingleSegment=tu,Zs.prototype.getIteratorForTime=Zs.prototype.Jb,Zs.prototype.updateEvery=Zs.prototype.ue,Zs.prototype.fit=Zs.prototype.Kc,Zs.prototype.evict=Zs.prototype.Ha,Zs.prototype.mergeAndEvict=Zs.prototype.td,Zs.prototype.offset=Zs.prototype.offset,Zs.prototype.get=Zs.prototype.get,Zs.prototype.find=Zs.prototype.find,Zs.prototype.markImmutable=Zs.prototype.Bi,Zs.prototype.release=Zs.prototype.release,Zs.prototype.getNumEvicted=Zs.prototype.getNumEvicted,Zs.prototype.getNumReferences=Zs.prototype.getNumReferences,(i=nu.prototype).Zc=function(e){this.reverse=e},i.Hh=function(){return this.h},i.current=function(){var e=this.i.get(this.h);return e&&0<e.g.length&&e.s&&this.g>=e.g.length&&(this.h++,this.g=0,e=this.i.get(this.h)),e&&0<e.g.length?e.g[this.g]:e},i.next=function(){var e=this.i.get(this.h);return this.reverse?e&&0<e.g.length?(this.g--,0>this.g&&(this.h--,this.g=(e=this.i.get(this.h))&&0<e.g.length?e.g.length-1:0)):(this.h--,this.g=0):e&&0<e.g.length?(this.g++,e.s&&this.g==e.g.length&&(this.h++,this.g=0)):(this.h++,this.g=0),{value:e=this.current(),done:!e}},i.Mf=function(){var e=this.current();if(e.o&&!e.l&&(e=this.i.get(this.h))&&0<e.g.length)for(var t=e.g[this.g];t.l&&!(0>=this.g);)this.g--,t=e.g[this.g]},F("shaka.media.SegmentIterator",nu),nu.prototype.resetToLastIndependent=nu.prototype.Mf,nu.prototype.next=nu.prototype.next,nu.prototype.current=nu.prototype.current,nu.prototype.currentPosition=nu.prototype.Hh,nu.prototype.setReverse=nu.prototype.Zc,m(iu,Zs),(i=iu.prototype).clone=function(){var e=new iu;return e.h=this.h.slice(),e.i=this.i,e},i.release=function(){for(var e=l(this.h),t=e.next();!t.done;t=e.next())t.value.release();this.h=[]},i.yb=function(e){for(var t=l(this.h),n=t.next();!n.done;n=t.next())n.value.yb(e)},i.find=function(e){for(var t=this.i,n=l(this.h),i=n.next();!i.done;i=n.next()){var r=(i=i.value).find(e);if(null!=r)return r+t;t+=i.getNumEvicted()+i.getNumReferences()}return null},i.get=function(e){for(var t=this.i,n=l(this.h),i=n.next();!i.done;i=n.next()){var r=(i=i.value).get(e-t);if(r)return r;r=i.getNumReferences(),t+=i.getNumEvicted()+r}return null},i.offset=function(){},i.Zd=function(){},i.Ha=function(e){for(var t=l(this.h),n=t.next();!n.done;n=t.next())n.value.Ha(e);for(;1<this.h.length&&0==this.h[0].getNumReferences();)e=this.h.shift(),this.i+=e.getNumEvicted(),e.release()},i.td=function(){},i.Kc=function(){},i.ue=function(){},F("shaka.media.MetaSegmentIndex",iu),iu.prototype.updateEvery=iu.prototype.ue,iu.prototype.fit=iu.prototype.Kc,iu.prototype.mergeAndEvict=iu.prototype.td,iu.prototype.evict=iu.prototype.Ha,iu.prototype.merge=iu.prototype.Zd,iu.prototype.offset=iu.prototype.offset,iu.prototype.get=iu.prototype.get,iu.prototype.find=iu.prototype.find,iu.prototype.forEachTopLevelReference=iu.prototype.yb,iu.prototype.release=iu.prototype.release,ru.prototype.release=function(){this.set(this.oc()),this.h&&(this.h.stop(),this.h=null),this.g=null},ru.prototype.set=function(e){this.i=e,au(this)},ru.prototype.oc=function(){return this.g.oc()},ou.prototype.release=function(){this.i.stop();for(var e=l(this.g),t=e.next();!t.done;t=e.next())t.value.release();this.g.clear()},fu.prototype.Ha=function(e,t){t=void 0!==t&&t;for(var n=l(this.h.keys()),i=n.next();!i.done;i=n.next())e>(i=i.value).endTime&&Tu(this,i);t&&bu(this)},fu.prototype.Zc=function(e){this.o=e,this.g&&this.g.Zc(e)},Su.prototype.abort=function(){this.wd&&this.wd.abort()},m(Au,Zr),Au.prototype.release=function(){this.g.clear(),this.h.stop(),Zr.prototype.release.call(this)},m(Eu,Zr),Eu.prototype.release=function(){this.g.clear(),Zr.prototype.release.call(this)},Eu.prototype.j=function(e){for(var t=l(this.g.values()),n=t.next();!n.done;n=t.next()){var i=(n=n.value).Se;e:{for(var r=n.yd,a=r.length-1;0<=a;a--){var o=r[a];if(o.position<=e){r=o.Qc;break e}}r=null}a=r&&!(i===r||i&&r&&i.bandwidth==r.bandwidth&&i.audioSamplingRate==r.audioSamplingRate&&i.codecs==r.codecs&&i.contentType==r.contentType&&i.frameRate==r.frameRate&&i.height==r.height&&i.mimeType==r.mimeType&&i.channelsCount==r.channelsCount&&i.pixelAspectRatio==r.pixelAspectRatio&&i.width==r.width),o=r&&i&&r.label&&i.label&&i.label!==r.label;var s=r&&i&&r.language&&i.language&&i.language!==r.language;i=r&&i&&r.roles&&i.roles&&!Ce(i.roles,r.roles),(o||s||i)&&ku(this,e,r.contentType)&&(n.Se=r,i=new Jr("audiotrackchange",new Map([["quality",r],["position",e]])),this.dispatchEvent(i)),a&&ku(this,e,r.contentType)&&(n.Se=r,JSON.stringify(r),n=new Jr("qualitychange",new Map([["quality",r],["position",e]])),this.dispatchEvent(n))}},(i=Pu.prototype).destroy=function(){return this.m.destroy()},i.configure=function(e){if(this.h=e,this.K=new Vr({maxAttempts:Math.max(e.retryParameters.maxAttempts,2),baseDelay:e.retryParameters.baseDelay,backoffFactor:e.retryParameters.backoffFactor,fuzzFactor:e.retryParameters.fuzzFactor,timeout:0,stallTimeout:0,connectionTimeout:0},!0),e.disableAudioPrefetch){var t=this.i.get("audio");t&&t.W&&(yu(t.W),t.W=null);for(var n=(t=l(this.o.keys())).next();!n.done;n=t.next())n=n.value,yu(this.o.get(n)),this.o.delete(n)}for(e.disableTextPrefetch&&(t=this.i.get(yi))&&t.W&&(yu(t.W),t.W=null),e.disableVideoPrefetch&&(t=this.i.get("video"))&&t.W&&(yu(t.W),t.W=null),n=(t=l(this.i.keys())).next();!n.done;n=t.next())(n=this.i.get(n.value)).W?(wu(n.W,e.segmentPrefetchLimit),0<e.segmentPrefetchLimit||(yu(n.W),n.W=null)):0<e.segmentPrefetchLimit&&(n.W=Bu(this,n.stream));e.disableAudioPrefetch||function(e){for(var t=e.h.segmentPrefetchLimit,n=e.h.prefetchAudioLanguages,i=l(e.l.variants),r=i.next(),a={};!r.done;a={pb:void 0},r=i.next())if(a.pb=r.value,a.pb.audio)if(e.o.has(a.pb.audio)){if(wu(r=e.o.get(a.pb.audio),t),!(0<t&&n.some(function(e){return function(t){return qi(e.pb.audio.language,t)}}(a)))){var o=e.i.get(a.pb.audio.type);r!==(o&&o.W)&&yu(r),e.o.delete(a.pb.audio)}}else 0>=t||!n.some(function(e){return function(t){return qi(e.pb.audio.language,t)}}(a))||!(r=Bu(e,a.pb.audio))||(a.pb.audio.segmentIndex||a.pb.audio.createSegmentIndex(),e.o.set(a.pb.audio,r))}(this)},i.start=function(e){var t=this;return P((function(n){if(1==n.g)return w(n,function(e,t){var n,i,r,a,o,s,u,c,d;return P((function(h){if(1==h.g){if(n=bi,!e.j)throw new De(2,5,5006);return i=new Map,r=new Set,e.j.audio&&(i.set(n.V,e.j.audio),r.add(e.j.audio)),e.j.video&&(i.set(n.la,e.j.video),r.add(e.j.video)),e.s&&(i.set(n.wa,e.s),r.add(e.s)),w(h,e.g.ca.init(i,e.l.sequenceMode,e.l.type,e.l.ignoreManifestTimestampsInSegmentsMode),2)}for(pa(e.m),e.updateDuration(),a=l(i.keys()),o=a.next();!o.done;o=a.next())s=o.value,u=i.get(s),e.i.has(s)||(c=_u(e,u),t.has(u.id)&&(pu(d=t.get(u.id),(function(t,n,i){return Xu(t,n,i||null,e.h.retryParameters,e.g.Nb)})),c.W=d),e.i.set(s,c),zu(e,c,0));T(h)}))}(t,e||new Map),2);pa(t.m),t.F=!0,T(n)}))},i.Xc=function(){if(this.g)for(var e=this.g.hd(),t=l(this.i.keys()),n=t.next();!n.done;n=t.next()){var i=n.value;n=this.i.get(i);var r=this.g.ca;if(!(r=i==yi?null!=(r=r.h).g&&null!=r.h&&e>=r.g&&e<r.h:xo(r=bs(r,i),e))){if(n.W&&(n.W.g=null),"audio"===n.type)for(var a=(r=l(this.o.values())).next();!a.done;a=r.next())a.value.g=null;n.ia=null,(null!=ys(this.g.ca,i)||n.Ea)&&Uu(this,n),n.mb&&(n.mb.abort(),n.mb=null),i===yi&&(i=this.g.ca).H&&i.H.g(),n.Xc=!0}}},i.updateDuration=function(){var e=this.l.presentationTimeline.getDuration();1/0>e?this.g.ca.bb(e):this.g.ca.bb(this.h.infiniteLiveStreamDuration?1/0:Math.pow(2,32))},F("shaka.util.ConfigUtils",Qu),Qu.getDifferenceFromConfigObjects=nl,Qu.convertToConfigObject=el,Qu.mergeConfigObjects=Zu,F("shaka.util.FairPlayUtils",il),il.commonFairPlayResponse=function(e,t){if(2===e){try{var n=dt(t.data)}catch(e){return}e=!1,"<ckc>"===(n=n.trim()).substr(0,5)&&"</ckc>"===n.substr(-6)&&(n=n.slice(5,-6),e=!0);try{var i=JSON.parse(n);i.ckc&&(n=i.ckc,e=!0),i.CkcMessage&&(n=i.CkcMessage,e=!0),i.License&&(n=i.License,e=!0)}catch(e){}e&&(t.data=pe(ui(n)))}},il.expressplayFairPlayRequest=function(e,t){sl(e,t)},il.conaxFairPlayRequest=function(e,t){sl(e,t)},il.ezdrmFairPlayRequest=function(e,t){sl(e,t)},il.verimatrixFairPlayRequest=function(e,t){2===e&&(e=si(e=ge(t.body)),t.headers["Content-Type"]="application/x-www-form-urlencoded",t.body=pt("spc="+e))},il.expressplayInitDataTransform=function(e,t,n){return ol(e,t,n)},il.conaxInitDataTransform=function(t,n,i){if("skd"!==n)return t;n=i.serverCertificate,i=ft(t).split("skd://").pop().split("?").shift(),i=e.atob(i);var r=new ArrayBuffer(2*i.length);r=me(r);for(var a=0,o=i.length;a<o;a++)r[a]=i.charCodeAt(a);return al(t,r,n)},il.ezdrmInitDataTransform=function(e,t,n){return"skd"!==t?e:(t=n.serverCertificate,al(e,n=ft(e).split(";").pop(),t))},il.verimatrixInitDataTransform=function(e,t,n){return ol(e,t,n)},il.initDataTransform=al,il.defaultGetContentId=rl,il.isFairPlaySupported=function(){var e;return P((function(t){return 1==t.g?(e={initDataTypes:["cenc","sinf","skd"],videoCapabilities:[{contentType:'video/mp4; codecs="avc1.42E01E"'}]},S(t,2),w(t,navigator.requestMediaKeySystemAccess("com.apple.fps",[e]),4)):2!=t.g?t.return(!0):(E(t),t.return(!1))}))},F("shaka.util.PlayerConfiguration",ul),ul.mergeConfigObjects=cl,ul.createDefault=ll,m(fl,Zr),(i=fl.prototype).getStartTime=function(){return this.B},i.Mc=function(){return this.M},i.kf=function(){return this.h},i.getStats=function(){return this.Z},i.start=function(){var e,t=this;P((function(n){switch(n.g){case 1:return w(n,Promise.resolve(),2);case 2:return S(n,3),w(n,function(e){var t,n,i,r;return P((function(a){switch(a.g){case 1:if(vl(e,"manifest-parser"),e.j||(e.G=lo(e.M,e.Y),e.j=e.G(),e.j.configure(e.g.manifest,(function(){return e.A}))),t=Date.now()/1e3,vl(e,"manifest"),e.h){a.u(2);break}return w(a,e.j.start(e.M,e.Na),3);case 3:e.h=a.h;case 2:return e.fa.resolve(),n=new Jr("manifestparsed",void 0),w(a,Promise.resolve(),4);case 4:if(e.dispatchEvent(n),0==e.h.variants.length)throw new De(2,4,4036);!function(e){function t(e){return e.video&&e.audio||e.video&&e.video.codecs.includes(",")}e.variants.some(t)&&(e.variants=e.variants.filter(t))}(e.h),i=Date.now()/1e3,r=i-t,e.Z.H=r,T(a)}}))}(t),5);case 5:return ml(t),w(n,function(e){var t,n,i;return P((function(r){switch(r.g){case 1:if(vl(e,"drm-engine"),e.xa=Date.now()/1e3,e.l=e.La(),e.F.h=e.l,e.l.configure(e.g.drm,(function(){return e.A})),!io(e.F,e.h)){r.u(2);break}return t=new Jr("trackschanged",void 0),w(r,Promise.resolve(),3);case 3:ml(e),e.dispatchEvent(t);case 2:return n=br(e.h.variants),w(r,ja(e.l,n,e.h.offlineSessionIds),4);case 4:return ml(e),w(r,no(e.F,e.h),5);case 5:if(!r.h){r.u(0);break}return i=new Jr("trackschanged",void 0),w(r,Promise.resolve(),7);case 7:e.dispatchEvent(i),T(r)}}))}(t),6);case 6:return ml(t),w(n,function(e){var t,n,i,r,a,o;return P((function(s){return e.o||(e.o=new Or(e.g.preferredAudioLanguage,e.g.preferredVariantRole,e.g.preferredAudioChannelCount,e.g.preferredVideoHdrLevel,e.g.preferSpatialAudio,e.g.preferredVideoLayout,e.g.preferredAudioLabel,e.g.preferredVideoLabel,e.g.mediaSource.codecSwitchingStrategy,"")),e.Ga&&(t=e.g.abrFactory,e.C=t,e.i=t(),e.i.configure(e.g.abr)),e.Ka?(n=e.h.presentationTimeline.U(),i=br(e.h.variants),r=e.o.create(i),e.i.configure(e.g.abr),e.i.setVariants(Array.from(r.values())),(a=e.i.chooseVariant())?(o=[],e.ja=a,a.video&&o.push(yl(e,a.video,n)),a.audio&&o.push(yl(e,a.audio,n)),w(s,Promise.all(o),0)):s.u(0)):s.u(0)}))}(t),7);case 7:return ml(t),w(n,function(e){return P((function(t){return 1==t.g?e.K?w(t,e.m,3):t.u(0):w(t,Promise.all(e.Y.map((function(e){return e.promise}))),0)}))}(t.l),8);case 8:ml(t),t.m.resolve(),A(n,0);break;case 3:(e=E(n))instanceof De&&(7001==e.code||7003==e.code)||t.m.reject(e),T(n)}}))},i.dispatchEvent=function(e){return this.O?this.O.dispatchEvent(e):Zr.prototype.dispatchEvent.call(this,e)},i.onError=function(e){2===e.severity&&(this.m.reject(e),this.destroy());var t=(new Map).set("detail",e);t=new Jr("error",t),this.dispatchEvent(t),t.defaultPrevented&&(e.handled=!0)},i.configure=function(e,t){e=el(e,t),cl(this.g,e)},i.getConfiguration=function(){return kt(this.g)},i.jj=function(){return this.m},i.destroy=function(){var e,t,n=this;return P((function(i){switch(i.g){case 1:if(n.s=!0,!n.j||n.ga){i.u(2);break}return w(i,n.j.stop(),2);case 2:if(!n.i||n.aa){i.u(4);break}return w(i,n.i.stop(),4);case 4:if(n.H&&!n.na&&n.H.release(),!n.l||n.da){i.u(6);break}return w(i,n.l.destroy(),6);case 6:if(0<n.L.size&&!n.ta)for(e=l(n.L.values()),t=e.next();!t.done;t=e.next())yu(t.value);T(i)}}))},F("shaka.media.PreloadManager",fl),fl.prototype.destroy=fl.prototype.destroy,fl.prototype.waitForFinish=fl.prototype.jj,m(bl,Zr),bl.prototype.release=function(){this.i=null,this.g.clear(),this.h.release(),this.h=null,Zr.prototype.release.call(this)},bl.prototype.j=function(e,t){if(!this.l||0!=e){this.l=!1;for(var n=l(this.i.g),i=n.next();!i.done;i=n.next()){i=i.value;var r=this.g.get(i),a=e<i.startTime?Tl:e>i.endTime?xl:Sl;this.g.set(i,a);for(var o=l(this.m),s=o.next();!s.done;s=o.next())(s=s.value).Ec==r&&s.Dc==a&&s.tc(i,t)}}};var Tl=1,Sl=2,xl=3;function Al(e,t,n){var i,r,a,o,s,u,l;return P((function(c){switch(c.g){case 1:var d=new Gn(e).Ua.split("/").pop().split(".");return i=1==d.length?"":d.pop().toLowerCase(),(r=El[i])?c.return(r):(a=0,o=aa([e],n),S(c,2),o.method="HEAD",w(c,t.request(a,o).promise,4));case 4:s=c.h,r=s.headers["content-type"],A(c,3);break;case 2:if(!(u=E(c))||1002!=u.code&&1001!=u.code){c.u(3);break}return o.method="GET",w(c,t.request(a,o).promise,6);case 6:l=c.h,r=l.headers["content-type"];case 3:return c.return(r?r.toLowerCase().split(";").shift():"")}}))}var El={mp4:"video/mp4",m4v:"video/mp4",m4a:"audio/mp4",webm:"video/webm",weba:"audio/webm",mkv:"video/webm",ts:"video/mp2t",ogv:"video/ogg",ogg:"audio/ogg",mpg:"video/mpeg",mpeg:"video/mpeg",m3u8:"application/x-mpegurl",mpd:"application/dash+xml",ism:"application/vnd.ms-sstr+xml",mp3:"audio/mpeg",aac:"audio/aac",flac:"audio/flac",wav:"audio/wav",sbv:"text/x-subviewer",srt:"text/srt",vtt:"text/vtt",webvtt:"text/vtt",ttml:"application/ttml+xml",lrc:"application/x-subtitle-lrc",ssa:"text/x-ssa",ass:"text/x-ssa",jpg:"image/jpeg",png:"image/png",svg:"image/svg+xml",webp:"image/webp",avif:"image/avif"};function kl(e,t){if(e.lineBreak)return"\n";if(e.nestedCues.length)return e.nestedCues.map((function(t){return kl(t,e)})).join("");if(!e.payload)return e.payload;var n=[],i=e.fontWeight>=Mn,r=e.fontStyle==Dn,a=e.textDecoration.includes(Pn);return i&&n.push(["b"]),r&&n.push(["i"]),a&&n.push(["u"]),""==(r=e.color)&&t&&(r=t.color),i="",(r=Il(r))&&(i+="."+r),""==(r=e.backgroundColor)&&t&&(r=t.backgroundColor),(t=Il(r))&&(i+=".bg_"+t),i&&n.push(["c",i]),n.reduceRight((function(e,t){var n=l(t);return"<"+(t=n.next().value)+(void 0===(n=n.next().value)?"":n)+">"+e+"</"+t+">"}),e.payload)}function Il(e){var t=(e=e.toLowerCase()).replace(/\s/g,"").match(/^rgba?\((\d+),(\d+),(\d+),?([^,\s)]+)?/i);switch(t?e="#"+(256|parseInt(t[1],10)).toString(16).slice(1)+(256|parseInt(t[2],10)).toString(16).slice(1)+(256|parseInt(t[3],10)).toString(16).slice(1):e.startsWith("#")&&7<e.length&&(e=e.slice(0,7)),e){case"white":case"#fff":case"#ffffff":return"white";case"lime":case"#0f0":case"#00ff00":return"lime";case"cyan":case"#0ff":case"#00ffff":return"cyan";case"red":case"#f00":case"#ff0000":return"red";case"yellow":case"#ff0":case"#ffff00":return"yellow";case"magenta":case"#f0f":case"#ff00ff":return"magenta";case"blue":case"#00f":case"#0000ff":return"blue";case"black":case"#000":case"#000000":return"black"}return null}function Ml(e,t){for(var n=[],i=(e=l(Cl(e))).next();!i.done;i=e.next())if((i=i.value).isContainer)n.push.apply(n,c(Ml(i.nestedCues,i)));else{var r=i.clone();r.nestedCues=[],r.payload=kl(i,t),n.push(r)}return n}function Cl(e){for(var t=[],n=(e=l(e)).next(),i={};!n.done;i={Pe:void 0},n=e.next())i.Pe=n.value,t.some(function(e){return function(t){return cn(e.Pe,t)}}(i))||t.push(i.Pe);return t}function Dl(e){function t(e){for(var t=5381,n=e.length;n;)t=33*t^e.charCodeAt(--n);return(t>>>0).toString()}if(e.startTime>=e.endTime)return null;var n=new VTTCue(e.startTime,e.endTime,e.payload);n.id=t(e.startTime.toString())+t(e.endTime.toString())+t(e.payload),n.lineAlign=e.lineAlign,n.positionAlign=e.positionAlign,e.size&&(n.size=e.size);try{n.align=e.textAlign}catch(e){}return"center"==e.textAlign&&"center"!=n.align&&(n.align="middle"),"vertical-lr"==e.writingMode?n.vertical="lr":"vertical-rl"==e.writingMode&&(n.vertical="rl"),1==e.lineInterpretation&&(n.snapToLines=!1),null!=e.line&&(n.line=e.line),null!=e.position&&(n.position=e.position),n}function Rl(e){if(1/0===e.endTime||e.endTime<e.startTime)return null;var t=new un(e.startTime,e.endTime,e.text);return t.line="number"==typeof e.line?e.line:null,e.lineAlign&&(t.lineAlign=e.lineAlign),t.lineInterpretation=e.snapToLines?Sn:1,t.position="number"==typeof e.position?e.position:null,e.positionAlign&&(t.positionAlign=e.positionAlign),t.size=e.size,t.textAlign=e.align,"lr"===e.vertical?t.writingMode="vertical-lr":"rl"===e.vertical&&(t.writingMode="vertical-rl"),e.region&&(t.region.id=e.region.id,t.region.height=e.region.lines,t.region.heightUnits=2,t.region.regionAnchorX=e.region.regionAnchorX,t.region.regionAnchorY=e.region.regionAnchorY,t.region.scroll=e.region.scroll,t.region.viewportAnchorX=e.region.viewportAnchorX,t.region.viewportAnchorY=e.region.viewportAnchorY,t.region.viewportAnchorUnits=Ae,t.region.width=e.region.width,t.region.widthUnits=Ae),dn(t),t}function Pl(e,t){this.g=null;for(var n=l(Array.from(e.textTracks)),i=n.next();!i.done;i=n.next())"metadata"!==(i=i.value).kind&&"chapters"!==i.kind&&(i.mode="disabled",i.label==t&&(this.g=i));this.g||(this.g=e.addTextTrack("subtitles",t)),this.g.mode="hidden"}function Ll(e,t){var n=e.mode;e.mode="showing"==n?"showing":"hidden";for(var i=l(Array.from(e.cues)),r=i.next();!r.done;r=i.next())(r=r.value)&&t(r)&&e.removeCue(r);e.mode=n}function Nl(){}function jl(t,n,i){var r=this;document.fullscreenEnabled||W("Using UITextDisplayer in a browser without Fullscreen API support causes subtitles to not be rendered in fullscreen"),this.m=!1,this.h=[],this.A=t,this.s=n,this.l=null,this.g=document.createElement("div"),this.g.classList.add("shaka-text-container"),this.g.style.textAlign="center",this.g.style.display="flex",this.g.style.flexDirection="column",this.g.style.alignItems="center",this.g.style.justifyContent="flex-end",this.s.appendChild(this.g),i&&i.captionsUpdatePeriod||oe("UITextDisplayer w/ config","Please migrate to initializing UITextDisplayer with a config."),this.C=new Be((function(){r.A.paused||_l(r)})).Ra(i&&i.captionsUpdatePeriod?i.captionsUpdatePeriod:.25),this.i=new Map,this.j=new Z,this.j.D(document,"fullscreenchange",(function(){_l(r,!0)})),this.j.D(this.A,"seeking",(function(){_l(r,!0)})),this.j.D(this.A,"resize",(function(){var e=r.A,t=e.videoWidth;e=e.videoHeight,r.l=t&&e?t/e:null})),this.o=null,"ResizeObserver"in e&&(this.o=new ResizeObserver((function(){_l(r,!0)})),this.o.observe(this.g)),this.B=new Map}function Ol(e,t){for(;null!=t;){if(t==e.g)return!0;t=t.parentElement}return!1}function Ul(e,t,n,i,r){for(var a=!1,o=[],s=[],u=(t=l(t)).next();!u.done;u=t.next()){u=u.value,r.push(u);var c=e.i.get(u),d=u.startTime<=i&&u.endTime>i,h=c?c.th:null;c&&(o.push(c.Re),c.Ac&&o.push(c.Ac),d||(a=!0,e.i.delete(u),c=null)),d&&(s.push(u),c?Ol(e,h)||(a=!0):(Bl(e,u,r),h=(c=e.i.get(u)).th,a=!0)),0<u.nestedCues.length&&h&&Ul(e,u.nestedCues,h,i,r),r.pop()}if(a){for(r=(i=l(o)).next();!r.done;r=i.next())(r=r.value).parentElement&&r.parentElement.removeChild(r);for(s.sort((function(e,t){return e.startTime!=t.startTime?e.startTime-t.startTime:e.endTime-t.endTime})),i=(s=l(s)).next();!i.done;i=s.next())(i=e.i.get(i.value)).Ac?(i.Ac.contains(n)&&i.Ac.removeChild(n),n.appendChild(i.Ac),i.Ac.appendChild(i.Re)):n.appendChild(i.Re)}}function _l(e,t){if(e.g){var n=e.A.currentTime;if(!e.m||void 0!==t&&t){for(var i=(t=l(e.B.values())).next();!i.done;i=t.next())Mo(i.value);Mo(e.g),e.i.clear(),e.B.clear()}e.m&&Ul(e,e.h,e.g,n,[])}}function Bl(e,t,n){var i=1<n.length,r=i?"span":"div";t.lineBreak&&(r="br"),t.rubyTag&&(r=t.rubyTag),i=!i&&0<t.nestedCues.length;var a=document.createElement(r);if("br"!=r&&function(e,t,n,i,r){var a=t.style,o=0==n.nestedCues.length,s=1<i.length;a.whiteSpace="pre-wrap";var u=n.payload.replace(/\s+$/g,(function(e){return" ".repeat(e.length)}));if(a.webkitTextStrokeColor=n.textStrokeColor,a.webkitTextStrokeWidth=n.textStrokeWidth,a.color=n.color,a.direction=n.direction,a.opacity=n.opacity,a.paddingLeft=Fl(n.linePadding,n,e.s),a.paddingRight=Fl(n.linePadding,n,e.s),a.textCombineUpright=n.textCombineUpright,a.textShadow=n.textShadow,n.backgroundImage)a.backgroundImage="url('"+n.backgroundImage+"')",a.backgroundRepeat="no-repeat",a.backgroundSize="contain",a.backgroundPosition="center",n.backgroundColor&&(a.backgroundColor=n.backgroundColor),a.width="100%",a.height="100%";else{if(n.nestedCues.length)var l=t;else l=document.createElement("span"),t.appendChild(l);n.border&&(l.style.border=n.border),r||((t=function(e,t){for(var n=e.length-1;0<=n;n--){var i=t(e[n]);if(i||0===i)return i}return null}(i,(function(e){return e.backgroundColor})))?l.style.backgroundColor=t:u&&(l.style.backgroundColor="rgba(0, 0, 0, 0.8)")),u&&(l.textContent=u)}s&&!i[i.length-1].isContainer?a.display="inline":(a.display="flex",a.flexDirection="column",a.alignItems="center","left"==n.textAlign||"start"==n.textAlign?(a.width="100%",a.alignItems="start"):"right"!=n.textAlign&&"end"!=n.textAlign||(a.width="100%",a.alignItems="end"),a.justifyContent="before"==n.displayAlign?"flex-start":"center"==n.displayAlign?"center":"flex-end"),o||(a.margin="0"),a.fontFamily=n.fontFamily,a.fontWeight=n.fontWeight.toString(),a.fontStyle=n.fontStyle,a.letterSpacing=n.letterSpacing,a.fontSize=Fl(n.fontSize,n,e.s),null!=(i=n.line)&&((o=n.lineInterpretation)==Sn&&(o=1,s=16,e.l&&1>e.l&&(s=32),i=0>i?100+i/s*100:i/s*100),1==o&&(a.position="absolute",n.writingMode==Tn?(a.width="100%",n.lineAlign==xn?a.top=i+"%":"end"==n.lineAlign&&(a.bottom=100-i+"%")):"vertical-lr"==n.writingMode?(a.height="100%",n.lineAlign==xn?a.left=i+"%":"end"==n.lineAlign&&(a.right=100-i+"%")):(a.height="100%",n.lineAlign==xn?a.right=i+"%":"end"==n.lineAlign&&(a.left=100-i+"%")))),a.lineHeight=n.lineHeight,e=function(e){var t=e.direction,n=e.positionAlign;return e=e.textAlign,n!==gn?n:"left"===e||"start"===e&&t===wn||"end"===e&&"rtl"===t?"line-left":"right"===e||"start"===e&&"rtl"===t||"end"===e&&t===wn?"line-right":"center"}(n),"line-left"==e?(a.cssFloat="left",null!==n.position&&(a.position="absolute",n.writingMode==Tn?(a.left=n.position+"%",a.width="auto"):a.top=n.position+"%")):"line-right"==e?(a.cssFloat="right",null!==n.position&&(a.position="absolute",n.writingMode==Tn?(a.right=100-n.position+"%",a.width="auto"):a.bottom=n.position+"%")):null!==n.position&&50!=n.position&&(a.position="absolute",n.writingMode==Tn?(a.left=n.position+"%",a.width="auto"):a.top=n.position+"%"),a.textAlign=n.textAlign,a.textDecoration=n.textDecoration.join(" "),a.writingMode=n.writingMode,"writingMode"in document.documentElement.style&&a.writingMode==n.writingMode||(a.webkitWritingMode=n.writingMode),n.size&&(n.writingMode==Tn?a.width=n.size+"%":a.height=n.size+"%")}(e,a,t,n,i),n=null,t.region&&t.region.id){var o=t.region,s=e.l===4/3?2.5:1.9;if(n=o.id+"_"+o.width+"x"+o.height+(o.heightUnits==Ae?"%":"px")+"-"+o.viewportAnchorX+"x"+o.viewportAnchorY+(o.viewportAnchorUnits==Ae?"%":"px"),e.B.has(n))n=e.B.get(n);else{r=document.createElement("span");var u=o.heightUnits==Ae?"%":"px",l=o.widthUnits==Ae?"%":"px",c=o.viewportAnchorUnits==Ae?"%":"px";r.id="shaka-text-region---"+n,r.classList.add("shaka-text-region"),r.style.position="absolute";var d=o.height,h=o.width;2===o.heightUnits&&(d=5.33*o.height,u="%"),2===o.widthUnits&&(h=o.width*s,l="%"),r.style.height=d+u,r.style.width=h+l,2===o.viewportAnchorUnits?(s=o.viewportAnchorY/75*100,u=o.viewportAnchorX/(e.l===4/3?160:210)*100,s-=o.regionAnchorY*d/100,u-=o.regionAnchorX*h/100,r.style.top=s+"%",r.style.left=u+"%"):(r.style.top=o.viewportAnchorY-o.regionAnchorY*d/100+c,r.style.left=o.viewportAnchorX-o.regionAnchorX*h/100+c),0!==o.heightUnits&&0!==o.widthUnits&&0!==o.viewportAnchorUnits&&(o=Math.max(0,Math.min(100-(parseInt(r.style.width.slice(0,-1),10)||0),parseInt(r.style.left.slice(0,-1),10)||0)),r.style.top=Math.max(0,Math.min(100-(parseInt(r.style.height.slice(0,-1),10)||0),parseInt(r.style.top.slice(0,-1),10)||0))+"%",r.style.left=o+"%"),r.style.display="flex",r.style.flexDirection="column",r.style.alignItems="center",r.style.justifyContent="before"==t.displayAlign?"flex-start":"center"==t.displayAlign?"center":"flex-end",e.B.set(n,r),n=r}}r=a,i&&((r=document.createElement("span")).classList.add("shaka-text-wrapper"),r.style.backgroundColor=t.backgroundColor,r.style.lineHeight="normal",a.appendChild(r)),e.i.set(t,{Re:a,th:r,Ac:n})}function Fl(e,t,n){var i=(i=new RegExp(/(\d*\.?\d+)([a-z]+|%+)/).exec(e))?{value:Number(i[1]),unit:i[2]}:null;if(!i)return e;var r=i.value;switch(i.unit){case"%":return r/100*n.clientHeight/t.cellResolution.rows+"px";case"c":return n.clientHeight*r/t.cellResolution.rows+"px";default:return e}}function Vl(e,t){this.h=e,this.g=t,this.i=void 0,this.l=!1,this.o=!0,this.j=this.m=!1}function Hl(t){return t.g.sessionId||(t.g.sessionId=e.crypto.randomUUID()),{v:1,sf:t.i,sid:t.g.sessionId,cid:t.g.contentId,mtp:t.h.getBandwidthEstimate()/1e3}}function Gl(e,t,n){n=void 0===n?{}:n;var i=void 0===i?e.g.useHeaders:i;if(e.g.enabled){Object.assign(n,Hl(e)),n.pr=e.h.ib();var r=n.ot===Wl||n.ot===Yl;if(e.m&&r&&(n.bs=!0,n.su=!0,e.m=!1),null==n.su&&(n.su=e.o),e=function(e,t){var n=e.g.includeKeys;return n.length?Object.keys(t).reduce((function(e,i){return n.includes(i)&&(e[i]=t[i]),e}),{}):t}(e,n),i)i=function(e){for(var t=Object.keys(e),n={},i=["Object","Request","Session","Status"],r=[{},{},{},{}],a={br:0,d:0,ot:0,tb:0,bl:1,dl:1,mtp:1,nor:1,nrr:1,su:1,cid:2,pr:2,sf:2,sid:2,st:2,v:2,bs:3,rtp:3},o=(t=l(t)).next();!o.done;o=t.next())r[null!=a[o=o.value]?a[o]:1][o]=e[o];for(e=0;e<r.length;e++)(a=Xl(r[e]))&&(n["CMCD-"+i[e]]=a);return n}(e),Object.keys(i).length&&Object.assign(t.headers,i);else{var a=Xl(e);a&&(t.uris=t.uris.map((function(e){return ql(e,a)})))}}}function Kl(e,t){if(!(t=e.h.zb()[t]).length)return 0;var n=e.h.getCurrentTime();return(e=t.find((function(e){return e.start<=n&&e.end>=n})))?1e3*(e.end-n):0}function Xl(e){function t(e){return 100*n(e/100)}function n(e){return Math.round(e)}for(var i,r=[],a={br:n,d:n,bl:t,dl:t,mtp:t,nor:function(e){return encodeURIComponent(e)},rtp:t,tb:n},o=Object.keys(e||{}).sort(),s=(o=l(o)).next();!s.done;s=o.next()){var u=e[s=s.value];if(i=u,!(Number.isNaN(i)||null==i||""===i||!1===i||"v"===s&&1===u||"pr"==s&&1===u)){var c,d=a[s];d&&(u=d(u)),c="string"==(d=typeof u)&&"ot"!==s&&"sf"!==s&&"st"!==s?s+"="+JSON.stringify(u):"boolean"===d?s:"symbol"===d?s+"="+u.description:s+"="+u,r.push(c)}}return r.join(",")}function ql(e,t){return!t||e.includes("offline:")?e:((e=new Gn(e)).g.set("CMCD",t),e.toString())}(i=Pl.prototype).configure=function(){},i.remove=function(e,t){return!!this.g&&(Ll(this.g,(function(n){return n.startTime<t&&n.endTime>e})),!0)},i.append=function(e){var t=Ml(e),n=[];e=this.g.cues?Array.from(this.g.cues):[];for(var i=(t=l(t)).next(),r={};!i.done;r={Nc:void 0},i=t.next())r.Nc=i.value,!e.some(function(e){return function(t){return t.startTime==e.Nc.startTime&&t.endTime==e.Nc.endTime&&t.text==e.Nc.payload}}(r))&&r.Nc.payload&&(i=Dl(r.Nc))&&n.push(i);for(t=(e=l(e=n.slice().sort((function(e,t){return e.startTime!=t.startTime?e.startTime-t.startTime:e.endTime!=t.endTime?e.endTime-t.startTime:"line"in VTTCue.prototype?n.indexOf(t)-n.indexOf(e):n.indexOf(e)-n.indexOf(t)})))).next();!t.done;t=e.next())this.g.addCue(t.value)},i.destroy=function(){return this.g&&(Ll(this.g,(function(){return!0})),this.g.mode="disabled"),this.g=null,Promise.resolve()},i.isTextVisible=function(){return"showing"==this.g.mode},i.setTextVisibility=function(e){this.g.mode=e?"showing":"hidden"},i.setTextLanguage=function(){},F("shaka.text.SimpleTextDisplayer",Pl),Pl.prototype.setTextLanguage=Pl.prototype.setTextLanguage,Pl.prototype.setTextVisibility=Pl.prototype.setTextVisibility,Pl.prototype.isTextVisible=Pl.prototype.isTextVisible,Pl.prototype.destroy=Pl.prototype.destroy,Pl.prototype.append=Pl.prototype.append,Pl.prototype.remove=Pl.prototype.remove,Pl.prototype.configure=Pl.prototype.configure,(i=Nl.prototype).configure=function(){},i.remove=function(){},i.append=function(){},i.destroy=function(){},i.isTextVisible=function(){return!1},i.setTextVisibility=function(){},i.setTextLanguage=function(){},F("shaka.text.StubTextDisplayer",Nl),Nl.prototype.setTextLanguage=Nl.prototype.setTextLanguage,Nl.prototype.setTextVisibility=Nl.prototype.setTextVisibility,Nl.prototype.isTextVisible=Nl.prototype.isTextVisible,Nl.prototype.destroy=Nl.prototype.destroy,Nl.prototype.append=Nl.prototype.append,Nl.prototype.remove=Nl.prototype.remove,Nl.prototype.configure=Nl.prototype.configure,(i=jl.prototype).configure=function(e){this.C&&this.C.Ra(e.captionsUpdatePeriod)},i.append=function(e){for(var t=[].concat(c(this.h)),n=(e=l(Cl(e))).next(),i={};!n.done;i={Qe:void 0},n=e.next())i.Qe=n.value,t.some(function(e){return function(t){return cn(t,e.Qe)}}(i))||this.h.push(i.Qe);_l(this)},i.destroy=function(){return this.g?(this.s.removeChild(this.g),this.g=null,this.m=!1,this.h=[],this.C&&this.C.stop(),this.i.clear(),this.j&&(this.j.release(),this.j=null),this.o&&(this.o.disconnect(),this.o=null),Promise.resolve()):Promise.resolve()},i.remove=function(e,t){if(!this.g)return!1;var n=this.h.length;return this.h=this.h.filter((function(n){return n.startTime<e||n.endTime>=t})),_l(this,n>this.h.length),!0},i.isTextVisible=function(){return this.m},i.setTextVisibility=function(e){this.m=e,_l(this,!0)},i.setTextLanguage=function(e){e&&"und"!=e?this.g.setAttribute("lang",e):this.g.setAttribute("lang","")},F("shaka.text.UITextDisplayer",jl),jl.prototype.setTextLanguage=jl.prototype.setTextLanguage,jl.prototype.setTextVisibility=jl.prototype.setTextVisibility,jl.prototype.isTextVisible=jl.prototype.isTextVisible,jl.prototype.remove=jl.prototype.remove,jl.prototype.destroy=jl.prototype.destroy,jl.prototype.append=jl.prototype.append,jl.prototype.configure=jl.prototype.configure,F("shaka.text.WebVttGenerator",(function(){})),Vl.prototype.configure=function(e){this.g=e};var zl="a",Wl="v",Yl="av",Jl="tt",$l="d",Ql="ld",Zl="h",ec="lh";function tc(e){this.h=e,this.g=null}function nc(e){return!e||"false"!==e.toLowerCase()&&(/^[-0-9]/.test(e)?parseInt(e,10):e.replace(/["]+/g,""))}F("shaka.util.CmcdManager.StreamingFormat",{DASH:$l,Dj:Ql,HLS:Zl,Ej:ec,Rj:"s",OTHER:"o"}),(i=tc.prototype).configure=function(e){this.h=e},i.Cg=function(){return this.h.enabled&&this.h.applyMaximumSuggestedBitrate&&this.g&&this.g.has(rc)?1e3*this.g.get(rc):null},i.Ag=function(){return this.h.enabled&&this.g&&this.g.has(ic)?1e3*this.g.get(ic):null},i.bi=function(){return this.h.enabled&&this.g&&this.g.has(ac)?this.g.get(ac):null},i.ci=function(){return this.h.enabled&&this.g&&this.g.has(oc)?this.g.get(oc):null},i.getBandwidthEstimate=function(e){var t=this.Ag();if(!t)return e;var n=this.h.estimatedThroughputWeightRatio;return 0<n&&1>=n?e*(1-n)+t*n:e},F("shaka.util.CmsdManager",tc),tc.prototype.getBandwidthEstimate=tc.prototype.getBandwidthEstimate,tc.prototype.getRoundTripTime=tc.prototype.ci,tc.prototype.getResponseDelay=tc.prototype.bi,tc.prototype.getEstimatedThroughput=tc.prototype.Ag,tc.prototype.getMaxBitrate=tc.prototype.Cg;var ic="etp",rc="mb",ac="rd",oc="rtt";function sc(){this.g=null,this.h=[]}function uc(e,t){return P((function(n){if(1==n.g)return e.g?w(n,new Promise((function(t){return e.h.push(t)})),2):n.u(2);e.g=t,T(n)}))}function lc(t,n,i){n=void 0===n?null:n,Zr.call(this);var r=this;this.m=ad,this.h=null,this.ge=n,this.ja=!1,this.te=new Z,this.od=new Z,this.l=new Z,this.Ga=new Z,this.Na=new Z,this.F=this.I=this.C=this.G=null,this.Ce=0,this.Z=new sc,this.ga=this.Ka=this.Y=this.i=this.La=this.H=this.j=this.ac=this.L=this.gg=this.da=this.O=this.bc=this.M=this.ie=this.K=this.Hb=null,this.Ba=!1,this.ta=this.o=null,this.fg=1e9,this.ud=[],this.eg=-1,this.g=Nc(this),this.S=null,this.Ee=-1,this.Aa=null,this.fa={width:1/0,height:1/0},this.de=new to(this.g,this.fa,null),this.le=[],this.A=null,this.xa=new Or(this.g.preferredAudioLanguage,this.g.preferredVariantRole,this.g.preferredAudioChannelCount,this.g.preferredVideoHdrLevel,this.g.preferSpatialAudio,this.g.preferredVideoLayout,this.g.preferredAudioLabel,this.g.preferredVideoLabel,this.g.mediaSource.codecSwitchingStrategy,""),this.Gb=this.g.preferredTextLanguage,this.sd=this.g.preferredTextRole,this.rd=this.g.preferForcedSubs,this.qd=[],i&&i(this),this.O=function(e){return new Vl({getBandwidthEstimate:function(){return e.o?e.o.getBandwidthEstimate():NaN},zb:function(){return e.zb()},getCurrentTime:function(){return e.h?e.h.currentTime:0},ib:function(){return e.ib()},Ab:function(){return e.Ab()},rc:function(){return e.rc()},U:function(){return e.U()}},e.g.cmcd)}(this),this.da=new tc(this.g.cmsd),this.G=Sc(this),this.G.Tf(this.g.streaming.forceHTTP),this.G.Uf(this.g.streaming.forceHTTPS),this.G.m=this.g.streaming.minBytesForProgressEvents,this.Ib=this.aa=this.s=null,this.Ge=!1,this.Fe=new Be((function(){return P((function(e){return 1==e.g?r.aa?w(e,r.Tb(r.Ib,!0),3):e.u(0):4!=e.g?w(e,r.load(r.aa),4):(r.Ge?r.Ib.pause():r.Ib.play(),r.aa=null,r.Ge=!1,void T(e))}))})),cd&&(this.s=cd(),this.s.configure(this.g.ads),this.Na.D(this.s,"ad-content-pause-requested",(function(e){var t;return P((function(n){if(1==n.g)return r.Fe.stop(),r.aa?n.u(0):(r.Ib=r.h,r.Ge=r.h.ended,t=e.saveLivePosition||!1,w(n,r.tg(!0,t),3));r.aa=n.h,T(n)}))})),this.Na.D(this.s,"ad-content-resume-requested",(function(e){if(e=e.offset||0,r.aa){var t=r.aa;t.B&&e&&(t.B+=e)}r.Fe.$(.1)})),this.Na.D(this.s,"ad-content-attach-requested",(function(){return P((function(e){return r.h||!r.Ib?e.u(0):w(e,r.Tb(r.Ib,!0),0)}))}))),this.te.D(e,"online",(function(){Yc(r),r.Nf()})),this.je=new Be((function(){for(var e=Date.now()/1e3,t=!1,n=!0,i=l(r.i.variants),a=i.next();!a.done;a=i.next())0<(a=a.value).disabledUntilTime&&a.disabledUntilTime<=e&&(a.disabledUntilTime=0,t=!0),0<a.disabledUntilTime&&(n=!1);n&&r.je.stop(),t&&Fc(r,!1,void 0,!1,!1)})),this.na=null,t&&(oe("Player w/ mediaElement","Please migrate from initializing Player with a mediaElement; use the attach method instead."),this.Tb(t,!0)),this.B=null}function cc(e){null!=e.L&&(cs(e.L),e.L.release(),e.L=null)}function dc(e,t){return new Jr(e,t)}function hc(e,t){e.dispatchEvent(dc("onstatechange",(new Map).set("state",t)))}function fc(e,t){var n;return P((function(i){return 1==i.g?(n=++e.Ce,w(i,uc(e.Z,t),2)):n!=e.Ce?(e.Z.release(),i.return(!0)):i.return(!1)}))}function pc(e,t){var n,i;return t=void 0!==t&&t,P((function(r){if(1==r.g)return n=null,e.i&&e.H&&e.La&&e.Y?(i=e.h.currentTime,e.U()&&!t&&(i=null),w(r,mc(e,e.Y,i,e.Ka,!0,!1,!1),3)):r.u(2);if(2!=r.g){n=r.h,e.le.push(n),e.H&&e.H.setMediaElement&&e.H.setMediaElement(null);var a=n,o=e.H,s=e.La;a.h=e.i,a.j=o,a.G=s,a=n,o=e.ta,a.i=e.o,a.C=o,n.o=e.xa,n.start(),e.i=null,e.H=null,e.La=null,e.o=null,e.ta=null}return r.return(n)}))}function gc(e,t,n,i,r){var a,o,s;return r=void 0!==r&&r,P((function(u){return 1==u.g?i?u.u(2):w(u,vc(e,t),3):(2!=u.g&&(i=u.h),function(e,t){if(!Fe())return!0;if(t){if(""==(e.h||at()).canPlayType(t))return!1;if(!Fe()||!(t in co))return!0;if(Pi(t))return Ye()&&(e.g.drm.servers["com.apple.fps"]||e.g.drm.servers["com.apple.fps.1_0"])?e.g.streaming.useNativeHlsForFairPlay:e.g.streaming.preferNativeHls}return!1}(e,i)?u.return(null):(a=!1,o=!0,r&&(e.o&&e.ta==e.g.abrFactory&&(o=!1),e.h&&"AUDIO"===e.h.nodeName&&(a=!0)),s=mc(e,t,n,i||null,!r,a,o),s=r?s.then((function(e){return e.A=!1,e})):s.then((function(t){return e.le.push(t),t})),u.return(s)))}))}function mc(e,t,n,i,r,a,o){var s,u,c,d,h,f,p,g,m,v,y,b,S;return r=void 0===r||r,a=void 0!==a&&a,o=void 0===o||o,P((function(x){return 1==x.g?(s=null,u=kt(e.g),a&&(u.manifest.disableVideo=!0),c=function(){return s.S&&s.s?null:s},d=function(){return c()?c().getConfiguration():e.g},h=function(t,n){c()?s.configure(t,n):e.configure(t,n)},1/0!=e.fa.width||1/0!=e.fa.height||e.g.ignoreHardwareResolution?x.u(2):w(x,st(),3)):(2!=x.g&&(f=x.h,e.fa.width=f.width,e.fa.height=f.height),p=new to(u,e.fa,null),g={networkingEngine:e.G,filter:function(e){var t;return P((function(n){return 1==n.g?w(n,no(p,e),2):4!=n.g?n.h?(t=dc("trackschanged"),w(n,Promise.resolve(),4)):n.u(0):(s.dispatchEvent(t),void T(n))}))},makeTextStreamsForClosedCaptions:function(t){return function(e,t){for(var n=new Set,i=l(t.textStreams),r=i.next();!r.done;r=i.next())"application/cea-608"!=(r=r.value).mimeType&&"application/cea-708"!=r.mimeType||n.add(r.originalId);for(r=(i=l(t.variants)).next();!r.done;r=i.next())if((r=r.value.video)&&r.closedCaptions)for(var a=l(r.closedCaptions.keys()),o=a.next();!o.done;o=a.next())if(o=o.value,!n.has(o)){var s=o.startsWith("CC")?"application/cea-608":"application/cea-708",u=new iu,c=r.closedCaptions.get(o);s={id:e.fg++,originalId:o,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:u,mimeType:s,codecs:"",kind:"caption",encrypted:!1,drmInfos:[],keyIds:new Set,language:c,originalLanguage:c,label:null,type:yi,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:r.roles,forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set([xi(s,"")]),isAudioMuxedInVideo:!1},t.textStreams.push(s),n.add(o)}}(e,t)},onTimelineRegionAdded:function(e){var t=s.H;e:{for(var n=l(t.g),i=n.next();!i.done;i=n.next())if((i=i.value).schemeIdUri==e.schemeIdUri&&i.id==e.id&&i.startTime==e.startTime&&i.endTime==e.endTime){n=i;break e}n=null}null==n&&(t.g.add(e),e=new Jr("regionadd",new Map([["region",e]])),t.dispatchEvent(e))},onEvent:function(e){return s.dispatchEvent(e)},onError:function(e){return s.onError(e)},isLowLatencyMode:function(){return d().streaming.lowLatencyMode},isAutoLowLatencyMode:function(){return d().streaming.autoLowLatencyMode},enableLowLatencyMode:function(){h("streaming.lowLatencyMode",!0)},updateDuration:function(){e.j&&s.S&&e.j.updateDuration()},newDrmInfo:function(e){var t=s.l,n=t?t.g:null;n&&t.A&&ao(p,n.keySystem,e)},onManifestUpdated:function(){var t=(new Map).set("isLive",e.U());s.dispatchEvent(dc("manifestupdated",t)),pl(s,!1,(function(){e.s&&e.s.onManifestUpdated(e.U())}))},getBandwidthEstimate:function(){return e.o.getBandwidthEstimate()},onMetadata:function(t,n,i,r){var a=t;"com.apple.hls.interstitial"==t&&(a="com.apple.quicktime.HLS",t={startTime:n,endTime:i,values:r},e.s)&&e.s.onHLSInterstitialMetadata(e,e.h,t),t=(r=l(r)).next();for(var o={};!t.done;o={If:void 0},t=r.next())o.If=t.value,"ID"!=o.If.name&&pl(s,!1,function(t){return function(){Tc(e,n,i,a,t.If)}}(o))},disableStream:function(t){return e.disableStream(t,e.g.streaming.maxDisabledTime)},addFont:function(t,n){return e.addFont(t,n)}},(m=new Au((function(){return e.Qb()}))).addEventListener("regionadd",(function(t){var n=t.region;$c(e,"timelineregionadded",n,s),pl(s,!1,(function(){e.s&&(e.s.onDashTimedMetadata(n),e.s.onDASHInterstitialMetadata(e,e.h,n))}))})),v=null,u.streaming.observeQualityChanges&&((v=new Eu((function(){return e.zb()}))).addEventListener("qualitychange",(function(t){Qc(e,t.quality,t.position)})),v.addEventListener("audiotrackchange",(function(t){Qc(e,t.quality,t.position,!0)}))),y=!0,b={Nb:e.G,onError:function(e){return s.onError(e)},ee:function(t){pl(s,!0,(function(){var n=t,i=dc("keystatuschanged");e.dispatchEvent(i);var r=Object.keys(n);1==r.length&&""==r[0]&&(r=["00"],n={"00":n[""]}),i=1==r.length&&"00"==r[0];var a=!1;if(r.length)for(var o=(r=l(e.i.variants)).next();!o.done;o=r.next()){var s=[];(o=o.value).audio&&s.push(o.audio),o.video&&s.push(o.video);for(var u=(s=l(s)).next();!u.done;u=s.next()){var c=u.value;if(u=o.allowedByKeySystem,c.keyIds.size){o.allowedByKeySystem=!0;for(var d=(c=l(c.keyIds)).next();!d.done;d=c.next())d=d.value,((d=n[i?"00":d])||e.C.F)&&(o.allowedByKeySystem=o.allowedByKeySystem&&!!d&&!so.includes(d))}u!=o.allowedByKeySystem&&(a=!0)}}a&&(Gc(e),!Bc(e))||(n=e.j.j)&&!n.allowedByKeySystem&&Fc(e)}))},onExpirationUpdated:function(e,t){var n=dc("expirationupdated");s.dispatchEvent(n),(n=s.j)&&n.onExpirationUpdated&&n.onExpirationUpdated(e,t)},onEvent:function(t){s.dispatchEvent(t),"drmsessionupdate"==t.type&&y&&(y=!1,t=Date.now()/1e3-s.xa,(e.A||s.getStats()).j=t,e.L&&cs(e.L))}},S=Sc(e,c),ra(e.G,S),s=new fl(t,i,n,{config:u,zi:g,Ji:m,Ii:v,Gc:function(){return e.Gc(b)},yi:p,networkingEngine:S,Bh:r,Ah:o}),x.return(s))}))}function vc(e,t){var n,i;return P((function(r){return 1==r.g?(n=e.g.manifest.retryParameters,w(r,Al(t,e.G,n),2)):("application/x-mpegurl"==(i=r.h)&&Ye()&&(i="application/vnd.apple.mpegurl"),r.return(i))}))}function yc(e){var t=e.g.textDisplayFactory;t!==e.Ae&&(e.B=t(),e.B.configure?e.B.configure(e.g.textDisplayer):oe("Text displayer w/ configure",'Text displayer should have a "configure" method!'),e.Ae=t,e.B.setTextVisibility(e.ja))}function bc(e){var t,n,i;return P((function(r){if(1==r.g)return hc(e,"media-source"),e.h.removeAttribute("src"),Mo(e.h),yc(e),t=function(e,t,n,i){return new hs(e,t,n,i)}(e.h,e.B,{Uh:function(){return e.keySystem()},onMetadata:function(t,n,i){for(var r=(t=l(t)).next();!r.done;r=t.next())if((r=r.value).data&&"number"==typeof r.cueTime&&r.frames){var a=r.cueTime+n,o=i;o&&a>o&&(o=a);for(var s=l(r.frames),u=s.next();!u.done;u=s.next())Tc(e,a,o,"org.id3",u.value);e.s&&e.s.onHlsTimedMetadata(r,a)}},onEvent:function(t){return e.dispatchEvent(t)},Fi:function(){e.H&&e.H.update&&e.H.update()}},e.L),t.configure(e.g.mediaSource),n=e.g.manifest,i=n.segmentRelativeVttTiming,t.xa=i,w(r,t.S,2);e.I=t,T(r)}))}function wc(e,t,n){function i(){return Oc(e)}e.l.D(t,"playing",i),e.l.D(t,"pause",i),e.l.D(t,"ended",i),e.l.D(t,"ratechange",(function(){var t=e.h.playbackRate;0!=t&&(e.K&&e.K.set(t),t=dc("ratechange"),e.dispatchEvent(t))})),t.remote&&(e.l.D(t.remote,"connect",(function(){return Gc(e)})),e.l.D(t.remote,"connecting",(function(){return Gc(e)})),e.l.D(t.remote,"disconnect",(function(){return P((function(n){if(1==n.g)return e.j&&"disconnected"==t.remote.state?w(n,$u(e.j),2):n.u(2);Gc(e),T(n)}))}))),t.audioTracks&&(e.l.D(t.audioTracks,"addtrack",(function(){return Gc(e)})),e.l.D(t.audioTracks,"removetrack",(function(){return Gc(e)})),e.l.D(t.audioTracks,"change",(function(){return Gc(e)}))),t.textTracks&&(e.l.D(t.textTracks,"addtrack",(function(t){if(t.track)switch(t=t.track,t.kind){case"metadata":!function(e,t){if("metadata"==t.kind){t.mode="hidden",e.l.D(t,"cuechange",(function(){if(t.activeCues)for(var n=l(t.activeCues),i=n.next();!i.done;i=n.next())i=i.value,Tc(e,i.startTime,i.endTime,i.type,i.value),e.s&&e.s.onCueMetadataChange(i.value);if(t.cues){n=[];for(var r=(i=l(t.cues)).next(),a={};!r.done;a={Vb:void 0},r=i.next())a.Vb=r.value,"com.apple.quicktime.HLS"==a.Vb.type&&null!=a.Vb.startTime&&(r=n.find(function(e){return function(t){return t.startTime==e.Vb.startTime&&t.endTime==e.Vb.endTime}}(a)),r||(r={startTime:a.Vb.startTime,endTime:a.Vb.endTime,values:[]},n.push(r)),r.values.push(a.Vb.value));for(i=(n=l(n)).next();!i.done;i=n.next())(i=i.value).values.some((function(e){return"X-ASSET-URI"==e.key||"X-ASSET-LIST"==e.key}))&&e.s&&(i.values.push({key:"CUE",description:"",data:0!=i.startTime||e.U()?"ONCE":"ONCE,PRE",mimeType:null,pictureType:null}),e.s.onHLSInterstitialMetadata(e,e.h,i))}}));var n=new Be((function(){for(var t=function(e){return Array.from(e.h.textTracks).filter((function(e){return"metadata"==e.kind}))}(e),n=(t=l(t)).next();!n.done;n=t.next())n.value.mode="hidden"})).hc().$(.5);e.qd.push((function(){n.stop()}))}}(e,t);break;case"chapters":!function(e,t){if(t&&"chapters"==t.kind){t.mode="hidden";var n=new Be((function(){t.mode="hidden"})).hc().$(.5);e.qd.push((function(){n.stop()}))}}(e,t);break;default:Gc(e)}})),e.l.D(t.textTracks,"removetrack",(function(){return Gc(e)})),e.l.D(t.textTracks,"change",(function(){return Gc(e)}))),"none"!=t.preload&&e.l.pa(t,"loadedmetadata",(function(){e.A.C=Date.now()/1e3-n}))}function Tc(e,t,n,i,r){t=(new Map).set("startTime",t).set("endTime",n).set("metadataType",i).set("payload",r),e.dispatchEvent(dc("metadata",t))}function Sc(e,t){function n(n){t()?t().dispatchEvent(n):e.dispatchEvent(n)}function i(e){t()?pl(t(),!0,e):e()}return t||(t=function(){return null}),new na((function(n,i,r,a){var o=t()?t().i:e.o;o&&o.segmentDownloaded(n,i,r,a)}),(function(t,r,a){n(dc("downloadheadersreceived",r=(new Map).set("headers",t).set("request",r).set("requestType",a))),i((function(){if(e.da){var n=e.da;if(n.h.enabled){var i=t["cmsd-static"];if(i)try{var r=new Map,a=i.split(",");for(i=0;i<a.length;i++){var o=a[i].split("=");r.set(o[0],nc(o[1]))}}catch(e){}if(r=t["cmsd-dynamic"]){try{var s=new Map,u=r.split(";");for(r=1;r<u.length;r++){var l=u[r].split("=");s.set(l[0],nc(l[1]))}var c=s}catch(e){c=null}c&&(n.g=c)}}}}))}),(function(e,t,i,r){n(dc("downloadfailed",e=(new Map).set("request",e).set("error",t).set("httpResponseCode",i).set("aborted",r)))}),(function(t,n,r){i((function(){var i=e.O,a=r;if(a=void 0===a?{}:a,i.g.enabled)if("HEAD"===n.method)Gl(i,n);else switch(t){case 0:try{if(i.g.enabled){if(a.type){e:{switch(a.type){case 4:var o=i.j?Ql:$l;break e;case 3:case 2:o=i.j?ec:Zl;break e;case 5:o="s";break e}o=void 0}i.i=o}Gl(i,n,{ot:"m",su:!i.l})}}catch(e){Y("CMCD_MANIFEST_ERROR","Could not generate manifest CMCD data.",e)}break;case ca:try{if(i.g.enabled){var s=a.segment;o=0,s&&(o=s.endTime-s.startTime);var u={d:1e3*o,st:i.h.U()?"l":"v"};u.ot=function(e){if(0===e.type)return"i";if(e=e.stream){var t=e.type;if("video"==t)return e.codecs&&e.codecs.includes(",")?Yl:Wl;if("audio"==t)return zl;if("text"==t)return"application/mp4"===e.mimeType?Jl:"c"}}(a);var c=u.ot===Wl||u.ot===zl||u.ot===Yl||u.ot===Jl,d=a.stream;if(d){var h=i.h.ib();if(c&&(u.bl=function(e,t){if(!(t=e.h.zb()[t]).length)return NaN;var n=e.h.getCurrentTime();return(e=t.find((function(e){return e.start<=n&&e.end>=n})))?1e3*(e.end-n):NaN}(i,d.type),u.ot!==Jl)){var f=Kl(i,d.type);u.dl=h?f/Math.abs(h):f}if(d.bandwidth&&(u.br=d.bandwidth/1e3),d.segmentIndex&&s){var p=d.segmentIndex.Jb(s.endTime,!0,0>h);if(p){var g=p.next().value;if(g&&g!=s){if(!Ce(s.N(),g.N())){var m=g.N()[0],v=n.uris[0],y=new URL(m),b=new URL(v);if(y.origin!==b.origin)var w=m;else{for(var T=y.pathname.split("/").slice(1),S=b.pathname.split("/").slice(1,-1);T[0]===S[0];)T.shift(),S.shift();for(;S.length;)S.shift(),T.unshift("..");w=T.join("/")}u.nor=w}if((g.Ja||g.va)&&(s.Ja!=g.Ja||s.va!=g.va)){var x=g.Ja+"-";g.va&&(x+=g.va),u.nrr=x}}}var A=i.h.ib()||1,E=Kl(i,d.type)||500,k=d.bandwidth,I=k?k*(s.endTime-s.startTime)/1e3/(E/A/1e3)*i.g.rtpSafetyFactor:NaN;isNaN(I)||(u.rtp=I)}}c&&u.ot!==Jl&&(u.tb=function(e,t){var n=e.h.rc();if(!n.length)return NaN;e=n[0];for(var i=(n=l(n)).next();!i.done;i=n.next())"variant"===(i=i.value).type&&i.bandwidth>e.bandwidth&&(e=i);switch(t){case Wl:return e.videoBandwidth||NaN;case zl:return e.audioBandwidth||NaN;default:return e.bandwidth}}(i,u.ot)/1e3),Gl(i,n,u)}}catch(e){Y("CMCD_SEGMENT_ERROR","Could not generate segment CMCD data.",e)}break;case 2:case 5:case 6:Gl(i,n,{ot:"k"});break;case 4:Gl(i,n,{ot:"o"})}}))}),(function(n,i,r,a){(n=t()?t().j:e.H)&&n.banLocation&&n.banLocation(a)}),(function(n,i){if(i.data){i=i.data.byteLength;var r=t()?t().getStats():e.A;r&&(r.kc=isNaN(r.kc)?i:r.kc+i,0===n&&(r.Kg=i))}}))}function xc(e,t,n){e.M=new Ur,e.M.g=Br,_r(e.M,n,Math.min(.5,n/2)),jc(e),e.ie=new Be((function(){Ac(e)})).Ra(.25),e.l.D(t,"waiting",(function(){return Ac(e)})),e.l.D(t,"stalled",(function(){return Ac(e)})),e.l.D(t,"canplaythrough",(function(){return Ac(e)})),e.l.D(t,"progress",(function(){return Ac(e)}))}function Ac(e){switch(e.m){case sd:if(e.h.ended)var t=!0;else{var n=So(e.h.buffered);t=null!=n&&n>=e.h.duration-1}break;case od:e:if(e.h.ended||ms(e.I))t=!0;else{if(e.i.presentationTimeline.U()){n=e.i.presentationTimeline.Yb();var i=So(e.h.buffered);if(null!=i&&i>=n){t=!0;break e}}t=!1}break;default:t=!1}i=Ao(e.h.buffered,e.h.currentTime);var r=t,a=(n=e.M).i.get(n.g);t=n.g,i=r||i>=a?Fr:Br,n.g=i,(t=t!=i)&&i===Fr&&(n.h=Date.now()),t&&jc(e)}function Ec(e){if(e.de=new to(e.g,e.fa,e.C),e.H){var t=kt(e.g.manifest);e.h&&"AUDIO"===e.h.nodeName&&(t.disableVideo=!0),e.H.configure(t)}if(e.C&&e.C.configure(e.g.drm),e.j){e.j.configure(e.g.streaming);try{e.m!=rd&&ro(e.de,e.i)&&Gc(e)}catch(t){Jc(e,t)}e.o&&Bc(e),!(t=e.j.j)||t.allowedByApplication&&t.allowedByKeySystem||Fc(e)}if(e.G&&(e.G.Tf(e.g.streaming.forceHTTP),e.G.Uf(e.g.streaming.forceHTTPS),e.G.m=e.g.streaming.minBytesForProgressEvents),e.I&&(e.I.configure(e.g.mediaSource),e.I.xa=e.g.manifest.segmentRelativeVttTiming),e.B)if(t=e.g.textDisplayFactory,e.Ae!=t){var n=e.B;if(e.B=t(),e.B.configure?e.B.configure(e.g.textDisplayer):oe("Text displayer w/ configure",'Text displayer should have a "configure" method!'),e.B.setTextLanguage||oe("Text displayer w/ setTextLanguage",'Text displayer should have a "setTextLanguage" method!'),e.B.setTextVisibility(n.isTextVisible()),n.destroy(),e.I){n=e.I;var i=e.B;n.fa=i,n.h&&(n.h.j=i)}e.Ae=t,e.j&&(n=(t=e.j).i.get(yi))&&Ou(t,n.stream,!0,0,!0)}else e.B.configure&&e.B.configure(e.g.textDisplayer);e.o&&(e.o.configure(e.g.abr),e.g.abr.enabled?e.o.enable():e.o.disable(),zc(e)),e.M&&(t=e.g.streaming.rebufferingGoal,e.i&&(t=Math.max(t,e.i.minBufferTime)),_r(e.M,t,Math.min(.5,t/2))),e.i&&ed(e.i.presentationTimeline,e.g.playRangeStart,e.g.playRangeEnd),e.s&&e.s.configure(e.g.ads),e.O&&e.O.configure(e.g.cmcd),e.da&&e.da.configure(e.g.cmsd)}function kc(e){return e&&(e=/(\d+)x(\d+)/.exec(e))?{lc:parseInt(e[1],10),rows:parseInt(e[2],10)}:null}function Ic(e,t){e.l.D(t,"cuechange",(function(){e.B.remove(0,Math.max(0,e.h.currentTime-e.g.streaming.bufferBehind));var n=Array.from(t.activeCues||[]).map(Rl).filter(Gi);e.B.append(n)})),t.mode=document.pictureInPictureElement?"showing":"hidden"}function Mc(e){return Array.from(e.h.textTracks).filter((function(e){return"metadata"!=e.kind&&"chapters"!=e.kind&&"Shaka Player TextTrack"!=e.label}))}function Cc(e){return Array.from(e.h.textTracks).filter((function(e){return"chapters"==e.kind}))}function Dc(e,t){var n;return P((function(i){switch(i.g){case 1:return S(i,2),w(i,Al(t,e.G,e.g.streaming.retryParameters),4);case 4:n=i.h,A(i,3);break;case 2:E(i);case 3:if(n)return i.return(n);throw new De(1,2,2011,t)}}))}function Rc(e,t,n,i,r,a,o){var s,u,l,c;return P((function(d){if(1==d.g)return"text/vtt"!=r||o.length?w(d,Pc(e,t,e.G,e.g.streaming.retryParameters),3):d.u(2);2!=d.g&&(s=d.h,u=Lc(e,s,r,o),l=new Blob([u],{type:"text/vtt"}),t=Rs(l),r="text/vtt"),c=document.createElement("track");var h=e.O,f=t;try{if(h.g.enabled){var p=Hl(h);p.ot="c",p.su=!0;var g=ql(f,Xl(p))}else g=f}catch(e){Y("CMCD_TEXT_TRACK_ERROR","Could not generate text track CMCD data.",e),g=f}return c.src=g,c.label=a,c.kind=i,c.srclang=n,e.h.getAttribute("crossorigin")||e.h.setAttribute("crossorigin","anonymous"),e.h.appendChild(c),d.return(c)}))}function Pc(e,t,n,i){var r,a,o;return P((function(s){if(1==s.g){r=ca,(a=aa([t],i)).method="GET";var u=e.O;try{u.g.enabled&&Gl(u,a,{ot:"c",su:!0})}catch(e){Y("CMCD_TEXT_ERROR","Could not generate text CMCD data.",e)}return w(s,n.request(r,a).promise,2)}return o=s.h,s.return(o.data)}))}function Lc(e,t,n,i){var r=Fi[n];if(r)return n=r(),e={periodStart:0,segmentStart:0,segmentEnd:e.h.duration,vttOffset:0},t=ge(t),function(e,t){function n(e){for(var n=e,i=l(t),r=i.next();!r.done;r=i.next())(r=r.value).end&&r.start<e&&(n+=r.end-r.start);return(10>(e=Math.floor(n/3600))?"0":"")+e+":"+(10>(i=Math.floor(n/60%60))?"0":"")+i+":"+(10>(r=Math.floor(n%60))?"0":"")+r+"."+(100>(n=Math.floor(1e3*n%1e3))?10>n?"00":"0":"")+n}var i=Ml(e);e="WEBVTT\n\n";for(var r=(i=l(i)).next();!r.done;r=i.next())e+=n((r=r.value).startTime)+" --\x3e "+n(r.endTime)+function(e){var t=[];switch(e.textAlign){case"left":t.push("align:left");break;case"right":t.push("align:right");break;case mn:t.push("align:middle");break;case"start":t.push("align:start");break;case"end":t.push("align:end")}switch(e.writingMode){case"vertical-lr":t.push("vertical:lr");break;case"vertical-rl":t.push("vertical:rl")}return t.length?" "+t.join(" "):""}(r)+"\n",e+=r.payload+"\n\n";return e}(t=n.parseMedia(t,e,null,[]),i);throw new De(2,2,2014,n)}function Nc(e){var t=ll();return t.streaming.failureCallback=function(t){if(e.U()){var n=null;1001==t.code||1002==t.code?(n=1,e.g.streaming.lowLatencyMode&&(n=.1)):1003==t.code&&(n=.1),null!=n&&(t.severity=1,e.Nf(n))}},t.textDisplayFactory=function(){if(!e.ge||et()&&!document.fullscreenEnabled)return HTMLMediaElement.prototype.addTextTrack?new Pl(e.h,"Shaka Player TextTrack"):new Nl;var t=e.getConfiguration();return new jl(e.h,e.ge,t.textDisplayer)},t}function jc(e){var t=e.tf();if(e.A&&e.M&&e.F){var n=e.K;if(n.j=t,au(n),e.O&&(n=e.O,t||n.l||(n.l=!0),n.l&&t&&(n.m=!0),n.o=t),Oc(e),n=e.g.streaming.liveSync.dynamicTargetLatency.maxAttempts,e.g.streaming.liveSync.dynamicTargetLatency.enabled&&t&&e.Ee<n){n=e.g.streaming.liveSync.dynamicTargetLatency.maxLatency;var i=e.g.streaming.liveSync.targetLatencyTolerance,r=e.g.streaming.liveSync.dynamicTargetLatency.rebufferIncrement;e.S&&(e.S=Math.min(e.S+ ++e.Ee*r,n-i))}}t=(new Map).set("buffering",t),e.dispatchEvent(dc("buffering",t))}function Oc(e){if(e.A&&e.M){var t=e.A.g,n="playing";e.M.g==Br?n="buffering":e.h.ended?n="ended":e.h.paused&&(n="paused");var i=n;if(null==t.g)t.g={timestamp:Date.now()/1e3,state:i,duration:0},t=!0;else{var r=Date.now()/1e3;t.g.duration=r-t.g.timestamp,t.g.state==i?t=!1:(t.h.push(t.g),t.g={timestamp:r,state:i,duration:0},t=!0)}t&&(n=(new Map).set("newstate",n),e.dispatchEvent(dc("statechanged",n)))}}function Uc(e){var t=e.h.playbackRate,n=e.U();if(e.g.streaming.vodDynamicPlaybackRate&&!n){var i=e.g.streaming.vodDynamicPlaybackRateLowBufferRate,r=e.yg();r<=e.g.streaming.vodDynamicPlaybackRateBufferRatio?t!=i&&e.Bd(i,!1):1==r&&t!==e.K.oc()&&e.$c()}if(n&&(n=e.Qb(),Number.isFinite(n.end)&&!(e.h.currentTime<n.start||e.h.paused))){i=e.g.streaming.liveSync.targetLatencyTolerance,r=e.g.streaming.liveSync.dynamicTargetLatency.enabled;var a=e.g.streaming.liveSync.dynamicTargetLatency.stabilityThreshold;if(e.g.streaming.liveSync&&e.g.streaming.liveSync.enabled)var o=e.g.streaming.liveSync.targetLatency,s=o+i,u=Math.max(0,o-i),l=e.g.streaming.liveSync.maxPlaybackRate,c=e.g.streaming.liveSync.minPlaybackRate;else e.i&&e.i.serviceDescription&&(o=e.i.serviceDescription.targetLatency,null!=e.i.serviceDescription.targetLatency?s=e.i.serviceDescription.targetLatency+i:null!=e.i.serviceDescription.maxLatency&&(s=e.i.serviceDescription.maxLatency),null!=e.i.serviceDescription.targetLatency?u=Math.max(0,e.i.serviceDescription.targetLatency-i):null!=e.i.serviceDescription.minLatency&&(u=e.i.serviceDescription.minLatency),l=e.i.serviceDescription.maxPlaybackRate||e.g.streaming.liveSync.maxPlaybackRate,c=e.i.serviceDescription.minPlaybackRate||e.g.streaming.liveSync.minPlaybackRate);e.S||"number"!=typeof o||(e.S=o);var d=e.g.streaming.liveSync.dynamicTargetLatency.maxAttempts;r&&e.Aa&&null!==e.S&&"number"==typeof o&&e.Ee<d&&Date.now()-e.Aa>1e3*a&&(a=e.g.streaming.liveSync.dynamicTargetLatency.minLatency,e.S=Math.max(e.S-(o-a)/2,a+i),e.Aa=Date.now()),r&&null!==e.S&&(s=e.S+i,u=e.S-i),o=n.end-e.h.currentTime,i=0,e.m==sd&&0<(r=e.h.buffered).length&&(i=r.end(r.length-1),i=Math.max(l,i-n.end)),n=e.g.streaming.liveSync.panicMode,r=1e3*e.g.streaming.liveSync.panicThreshold,a=Date.now()-e.M.h,n&&!c&&(c=e.g.streaming.liveSync.minPlaybackRate),n&&c&&a<=r?t!=c&&e.Bd(c,!1):null!=s&&l&&o-i>s?(t!=l&&e.Bd(l,!1),e.Aa=null):null!=u&&c&&o-i<u?(t!=c&&e.Bd(c,!1),e.Aa=null):t!==e.K.oc()&&(e.$c(),e.Aa=Date.now())}}function _c(e){if(e.h){var t,n=function(t,n){var i=void 0===i?Number.EPSILON:i;if(t===n)i=!0;else{var r=Math.abs(t-n);i=r<=i||i!==Number.EPSILON&&Math.abs(r-i)<=Number.EPSILON}return!!((i||n>t)&&e.eg<t)&&(e.eg=t,!0)},i=e.h.currentTime/e.h.duration;isNaN(i)||(n(0,i*=100)?t=dc("started"):n(25,i)?t=dc("firstquartile"):n(50,i)?t=dc("midpoint"):n(75,i)?t=dc("thirdquartile"):n(100,i)&&(t=dc("complete")),t&&e.dispatchEvent(t))}}function Bc(e){try{oo(e.de,e.i)}catch(t){return Jc(e,t),!1}var t=br(e.i.variants);return t=e.xa.create(t),e.o.setVariants(Array.from(t.values())),!0}function Fc(e,t,n,i,r){var a;t=void 0===t||t,n=void 0===n?0:n,i=void 0!==i&&i,r=void 0===r||r,(a=Bc(e)?e.o.chooseVariant():null)&&Vc(e,a,r,t,n,i)}function Vc(e,t,n,i,r,a){a=void 0!==a&&a;var o=e.j.j;if(t==o)i&&Nu(e.j,t,i,r,!0);else{var s=e.A.h;s.h!=t&&(s.h=t,s.g.push({timestamp:Date.now()/1e3,id:t.id,type:"variant",fromAdaptation:n,bandwidth:t.bandwidth})),Nu(e.j,t,i,r,a,n),i=null,o&&(i=dr(o)),(t=dr(t)).active=!0,n?(n=(new Map).set("oldTrack",i).set("newTrack",t),e.L&&ds(e.L,t,e.lf()),td(e,n=dc("adaptation",n))):Kc(e,i,t)}}function Hc(e,t){var n=Array.from(e.h.audioTracks).find((function(e){return e.enabled}));t.enabled=!0,n&&(t.id!==n.id&&(n.enabled=!1),Kc(e,n=mr(n),t=mr(t)))}function Gc(e){td(e,dc("trackschanged"))}function Kc(e,t,n){t=(new Map).set("oldTrack",t).set("newTrack",n),e.L&&ds(e.L,n,e.lf()),td(e,n=dc("variantchanged",t))}function Xc(e){td(e,dc("textchanged"))}function qc(e){td(e,dc("texttrackvisibility"))}function zc(e){e.g.abr.enabled||Yc(e),td(e,dc("abrstatuschanged",(new Map).set("newStatus",e.g.abr.enabled)))}function Wc(e){var t=e.qc().find((function(e){return e.active}));t&&e.B&&e.B.setTextLanguage&&e.B.setTextLanguage(t.language)}function Yc(e,t){if(t=void 0===t||t,e.m==od){e.je.stop();for(var n=l(e.i.variants),i=n.next();!i.done;i=n.next())i.value.disabledUntilTime=0;t&&Bc(e)}}function Jc(e,t){var n,i,r,a;return P((function(o){switch(o.g){case 1:if(e.m==rd)return o.return();if(1===t.severity&&e.A.K++,n=!0,!(e.Ba&&e.i&&e.j)||3016!=t.code&&3014!=t.code&&3015!=t.code&&3018!=t.code){o.u(2);break}return S(o,3),w(o,$u(e.j),5);case 5:i=o.h,n=!i,i&&(r=dc("mediasourcerecovered"),e.dispatchEvent(r)),A(o,2);break;case 3:E(o),n=!0;case 2:if(!n)return o.return();2===t.severity&&Yc(e,!1),a=dc("error",(new Map).set("detail",t)),e.dispatchEvent(a),a.defaultPrevented&&(t.handled=!0),T(o)}}))}function $c(e,t,n,i){i=void 0===i?e:i,e=(new Map).set("detail",{schemeIdUri:n.schemeIdUri,value:n.value,startTime:n.startTime,endTime:n.endTime,id:n.id,eventElement:n.eventElement,eventNode:n.eventNode}),i.dispatchEvent(dc(t,e))}function Qc(e,t,n,i){i=void 0!==i&&i,t=(new Map).set("mediaQuality",{bandwidth:t.bandwidth,audioSamplingRate:t.audioSamplingRate,codecs:t.codecs,contentType:t.contentType,frameRate:t.frameRate,height:t.height,mimeType:t.mimeType,channelsCount:t.channelsCount,pixelAspectRatio:t.pixelAspectRatio,width:t.width,label:t.label,roles:t.roles,language:t.language}).set("position",n),e.dispatchEvent(dc(i?"audiotrackchanged":"mediaqualitychanged",t))}function Zc(e,t){if(t=void 0===t||t,!e.h.error)return t?new De(2,3,3016):null;var n=e.h.error.code;return t||1!=n?((t=e.h.error.msExtendedCode)&&(0>t&&(t+=Math.pow(2,32)),t=t.toString(16)),new De(2,3,3016,n,t,e.h.error.message)):null}function ed(e,t,n){0<t&&(e.U()||e.jh(t)),n<(t=e.getDuration())&&(e.U()||e.bb(n))}function td(e,t){P((function(n){if(1==n.g)return w(n,Promise.resolve(),2);e.m!=rd&&e.dispatchEvent(t),T(n)}))}function nd(e){for(var t=new Set,n=(e=l(e)).next();!n.done;n=e.next())(n=n.value).language?t.add(Yi(n.language)):t.add("und");return t}function id(e){for(var t=new Map,n=new Map,i=(e=l(e)).next();!i.done;i=e.next()){var r="und",a=[];(i=i.value).language&&(r=Yi(i.language)),(a="variant"==i.type?i.audioRoles:i.roles)&&a.length||(a=[""]),t.has(r)||t.set(r,new Set);for(var o=(a=l(a)).next();!o.done;o=a.next())o=o.value,t.get(r).add(o),i.label&&(n.has(r)||n.set(r,new Map),n.get(r).set(o,i.label))}var s=[];return t.forEach((function(e,t){for(var i=(e=l(e)).next();!i.done;i=e.next()){i=i.value;var r=null;n.has(t)&&n.get(t).has(i)&&(r=n.get(t).get(i)),s.push({language:t,role:i,label:r})}})),s}sc.prototype.release=function(){0<this.h.length?this.h.shift()():this.g=null},m(lc,Zr),(i=lc.prototype).destroy=function(){var e,t=this;return P((function(n){switch(n.g){case 1:return t.m==rd?n.return():(cc(t),e=t.detach(),t.m=rd,w(n,e,2));case 2:return w(n,t.Te(),3);case 3:if(t.te&&(t.te.release(),t.te=null),t.od&&(t.od.release(),t.od=null),t.l&&(t.l.release(),t.l=null),t.Ga&&(t.Ga.release(),t.Ga=null),t.Na&&(t.Na.release(),t.Na=null),t.ta=null,t.g=null,t.A=null,t.ge=null,t.O=null,t.da=null,!t.G){n.u(4);break}return w(n,t.G.destroy(),5);case 5:t.G=null;case 4:t.o&&(t.o.release(),t.o=null),Zr.prototype.release.call(t),T(n)}}))},i.Tb=function(e,t){t=void 0===t||t;var n,i,r,a=this;return P((function(o){switch(o.g){case 1:if(a.m==rd)throw new De(2,7,7e3);if(n=a.h&&a.h==e,!a.h||a.h==e){o.u(2);break}return w(o,a.detach(),2);case 2:return w(o,fc(a,"attach"),4);case 4:if(o.h)return o.return();if(S(o,5,6),n||(hc(a,"attach"),i=function(){var e=Zc(a,!1);e&&Jc(a,e)},a.od.D(e,"error",i),a.h=e),!t||!Fe()||a.I){o.u(6);break}return w(o,bc(a),6);case 6:k(o),a.Z.release(),I(o,0);break;case 5:return r=E(o),w(o,a.detach(),10);case 10:throw r}}))},i.Ch=function(e){this.gg=e},i.detach=function(e){e=void 0!==e&&e;var t=this;return P((function(n){if(1==n.g){if(t.m==rd)throw new De(2,7,7e3);return w(n,t.ic(!1,e),2)}if(3!=n.g)return w(n,fc(t,"detach"),3);if(n.h)return n.return();try{t.h&&(t.od.Va(),t.h=null),hc(t,"detach"),t.s&&!e&&t.s.release()}finally{t.Z.release()}T(n)}))},i.ic=function(e,t){e=void 0===e||e,t=void 0!==t&&t;var n,i,r,a,o,s,u,c,d,h,f=this;return P((function(p){switch(p.g){case 1:return f.m!=rd&&(f.m=ad),w(p,fc(f,"unload"),2);case 2:return p.h?p.return():(x(p,3),f.Ba=!1,hc(f,"unload"),e&&!Fe()&&(e=!1),cc(f),n=f.qd.map((function(e){return e()})),f.qd=[],w(p,Promise.all(n),5));case 5:if(f.dispatchEvent(dc("unloading")),f.bc&&(f.bc.release(),f.bc=null),f.h&&(f.l.Va(),f.Ga.Va()),f.je.stop(),f.Hb&&(f.Hb.release(),f.Hb=null),f.ie&&(f.ie.stop(),f.ie=null),!f.H){p.u(6);break}return w(p,f.H.stop(),7);case 7:f.H=null,f.La=null;case 6:if(!f.o){p.u(8);break}return w(p,f.o.stop(),8);case 8:if(!f.j){p.u(10);break}return w(p,f.j.destroy(),11);case 11:f.j=null;case 10:if(f.K&&(f.K.release(),f.K=null),f.F&&(f.F.release(),f.F=null),!ot("webkit")||!f.C){p.u(12);break}return w(p,f.C.destroy(),13);case 13:f.C=null;case 12:if(!f.I){p.u(14);break}return w(p,f.I.destroy(),15);case 15:f.I=null;case 14:if(f.s&&!t&&f.s.onAssetUnload(),f.aa&&!t&&(f.aa.destroy(),f.aa=null),t||f.Fe.stop(),f.O&&function(e){e.l=!1,e.o=!0,e.m=!1,e.j=!1}(f.O),f.da&&(f.da.g=null),!f.B){p.u(16);break}return w(p,f.B.destroy(),17);case 17:f.B=null;case 16:if(f.h&&(Mo(f.h),f.h.src&&(f.h.removeAttribute("src"),f.h.load())),!f.C){p.u(18);break}return w(p,f.C.destroy(),19);case 19:f.C=null;case 18:if(f.na&&f.Y!=f.na.Mc()&&(f.na.s||f.na.destroy(),f.na=null),f.Y=null,f.Ka=null,f.M=null,f.i){for(i=l(f.i.variants),r=i.next();!r.done;r=i.next())for(a=r.value,o=l([a.audio,a.video]),s=o.next();!s.done;s=o.next())(u=s.value)&&u.segmentIndex&&u.segmentIndex.release();for(c=l(f.i.textStreams),d=c.next();!d.done;d=c.next())(h=d.value).segmentIndex&&h.segmentIndex.release()}f.g&&f.g.streaming.clearDecodingCache&&(Ar={},Ue.clear()),f.i=null,f.A=new hu,f.Ae=null,f.Aa=null,f.S=null,f.Ee=-1,f.ud=[],f.eg=-1,jc(f);case 3:k(p),f.Z.release(),I(p,4);break;case 4:if(e&&Fe()&&!f.I&&f.h)return w(p,bc(f),0);p.u(0)}}))},i.ij=function(e){this.ga=e},i.load=function(t,n,i){n=void 0===n?null:n;var r,a,o,s,u,c,d,h,f,p,g,m,v,y=this;return P((function(b){switch(b.g){case 1:if(y.m==rd)throw new De(2,7,7e3);return r=null,a="",a=t instanceof fl?(r=t).Mc()||"":t||"",w(b,uc(y.Z,"load"),2);case 2:if(y.Z.release(),!y.h)throw new De(2,7,7002);if(!y.Y){b.u(3);break}return y.Y=a,w(b,y.ic(!1),3);case 3:if(o=++y.Ce,s=function(){return P((function(e){if(1==e.g)return y.Ce==o?e.u(0):r?w(e,r.destroy(),3):e.u(3);throw new De(2,7,7e3)}))},u=function(e,t){return P((function(n){switch(n.g){case 1:return x(n,2),w(n,uc(y.Z,t),4);case 4:return w(n,s(),5);case 5:return w(n,e(),6);case 6:return w(n,s(),7);case 7:r&&y.g&&(r.g=y.g);case 2:k(n),y.Z.release(),I(n,0)}}))},S(b,5,6),null==n&&r&&(n=r.getStartTime()),y.ga=n,y.Ba=!1,y.dispatchEvent(dc("loading")),r){i=r.Y,b.u(8);break}if(i){b.u(8);break}return w(b,u((function(){return P((function(e){if(1==e.g)return w(e,vc(y,a),2);i=e.h,T(e)}))}),"guessMimeType_"),8);case 8:if(c=!!r,r){gl(r,y),y.A=r.getStats(),b.u(11);break}return w(b,gc(y,a,n,i,!0),12);case 12:(r=b.h)?(r.A=!1,gl(r,y),y.A=r.getStats(),r.start(),r.m.catch((function(){}))):y.A=new hu;case 11:return d=!r,h=Date.now()/1e3,y.A=r?r.getStats():new hu,y.Y=a,y.Ka=i||null,d?w(b,u((function(){return P((function(e){return w(e,function(e,t){var n,i,r,a,o;return P((function(s){return 1==s.g?(n=bi,i=Date.now()/1e3,r=!0,e.C=e.Gc({Nb:e.G,onError:function(t){Jc(e,t)},ee:function(){},onExpirationUpdated:function(){var t=dc("expirationupdated");e.dispatchEvent(t)},onEvent:function(t){e.dispatchEvent(t),"drmsessionupdate"==t.type&&r&&(r=!1,e.A.j=Date.now()/1e3-i)}}),e.C.configure(e.g.drm),a={id:0,language:"und",disabledUntilTime:0,primary:!1,audio:null,video:null,bandwidth:100,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},(o={id:0,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:t?Di(t):"",codecs:t?Ri(t):"",encrypted:!0,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:n.la,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set,isAudioMuxedInVideo:!1}).fullMimeTypes.add(xi(o.mimeType,o.codecs)),t.startsWith("audio/")?(o.type=n.V,a.audio=o):a.video=o,e.C.da=!0,w(s,ja(e.C,[a],[]),2)):w(s,e.C.Tb(e.h),0)}))}(y,i),0)}))}),"initializeSrcEqualsDrmInner_"),21):w(b,u((function(){return P((function(e){if(1==e.g)return w(e,Promise.race([r.fa,r.m]),2);y.La=r.G;var t=r;t.ga=!0,y.H=t.j,y.i=r.kf(),T(e)}))}),"waitForFinish"),15);case 15:if(y.I){b.u(16);break}return w(b,u((function(){return P((function(e){return w(e,bc(y),0)}))}),"initializeMediaSourceEngineInner_"),16);case 16:return w(b,u((function(){return P((function(e){return w(e,r.m,0)}))}),"waitForFinish"),18);case 18:return y.g=r.getConfiguration(),y.de=r.F,y.H&&y.H.setMediaElement&&y.h&&y.H.setMediaElement(y.h),y.bc=function(e){return e.na=!0,e.H}(r),y.ac=r.Aa,(f=r.o)&&(y.xa=f),c&&y.h&&"AUDIO"===y.h.nodeName&&(function(e){for(var t=l(e.i.variants),n=t.next();!n.done;n=t.next())(n=n.value).video&&(n.video.closeSegmentIndex(),n.video=null),n.bandwidth=n.audio&&n.audio.bandwidth?n.audio.bandwidth:0;e.i.variants=e.i.variants.filter((function(e){return e.audio}))}(y),y.configure("manifest.disableVideo",!0)),y.C=function(e){return e.da=!0,e.l}(r),w(b,u((function(){return P((function(e){return w(e,y.C.Tb(y.h),0)}))}),"drmEngine_.attach"),19);case 19:return!(p=r.C)||y.ta&&y.ta==p||(y.o=function(e){return e.aa=!0,e.i}(r),y.ta=r.C,"function"!=typeof y.o.setMediaElement&&(oe("AbrManager w/o setMediaElement","Please use an AbrManager with setMediaElement function."),y.o.setMediaElement=function(){}),"function"!=typeof y.o.setCmsdManager&&(oe("AbrManager w/o setCmsdManager","Please use an AbrManager with setCmsdManager function."),y.o.setCmsdManager=function(){}),"function"!=typeof y.o.trySuggestStreams&&(oe("AbrManager w/o trySuggestStreams","Please use an AbrManager with trySuggestStreams function."),y.o.trySuggestStreams=function(){})),g=function(e){return e.ta=!0,e.L}(r),m=r.ja,w(b,u((function(){return P((function(e){return w(e,function(e,t,n,i){var r,a,o,s,u,c,d,h,f,p,g,m,v,y,b,S,x,A,E,k;return P((function(I){switch(I.g){case 1:hc(e,"load"),r=e.h,e.K=new ru({Pd:function(){return r.playbackRate},oc:function(){return r.defaultPlaybackRate},Vf:function(e){r.playbackRate=e},Og:function(e){r.currentTime+=e}}),wc(e,r,t),function(e,t){t.lcevc.enabled?(cc(e),null==e.L&&(e.L=new ls(e.h,e.gg,t.lcevc),e.I&&(e.I.da=e.L))):cc(e)}(e,e.g),e.Gb=e.g.preferredTextLanguage,e.sd=e.g.preferredTextRole,e.rd=e.g.preferForcedSubs,ed(e.i.presentationTimeline,e.g.playRangeStart,e.g.playRangeEnd),e.o.init((function(t,n,i){e.i&&e.j&&t!=e.j.j&&Vc(e,t,!0,void 0!==n&&n,void 0===i?0:i)})),e.o.setMediaElement(r),e.o.setCmsdManager(e.da),e.j=function(e){return new Pu(e.i,{hd:function(){return e.F?e.F.Dd():0},getBandwidthEstimate:function(){return e.o.getBandwidthEstimate()},ib:function(){return e.ib()},ca:e.I,Nb:e.G,onError:function(t){return Jc(e,t)},onEvent:function(t){return e.dispatchEvent(t)},Ef:function(t,n){var i=t.startTime;t=t.endTime;var r=n.type;if(n=n.codecs.includes(","),r!=yi){if(e.F){e.F.Pg();var a=vs(e.I,r);!e.U()&&e.h.paused&&null!=a&&0<a&&e.F.Dd()<a&&e.F.Ie(a)}Ac(e)}i=(new Map).set("start",i).set("end",t).set("contentType",r).set("isMuxed",n),e.dispatchEvent(dc("segmentappended",i))},Ei:function(t,n){(n=n.Qc)&&e.ac&&function(e,t,n){var i=function(e,t){var n=e.g.get(t);return n||(n={yd:[],Se:null,contentType:t},e.g.set(t,n)),n}(e,t.contentType);!function(e,t){if((e=e.h()[t.contentType])&&0<e.length){var n=e[0].start,i=e[e.length-1].end,r=t.yd;t.yd=r.filter((function(e,t){return!(e.position<=n&&t+1<r.length&&r[t+1].position<=n||e.position>=i)}))}else t.yd=[]}(e,i),e={Qc:t,position:n},0<=(t=(i=i.yd).findIndex((function(e){return e.position>=n})))?i.splice(t,i[t].position==n?1:0,e):i.push(e)}(e.ac,n,t)},mg:function(t,n){var i=e.C;if(i.h.parseInbandPsshEnabled&&!i.F&&["audio","video"].includes(t)){t=new Pa(ge(n)),n=0;for(var r=l(t.data),a=r.next();!a.done;a=r.next())n+=a.value.length;if(0==n)i=Promise.resolve();else{for(n=new Uint8Array(n),r=0,a=(t=l(t.data)).next();!a.done;a=t.next())a=a.value,n.set(a,r),r+=a.length;Ba(i,"cenc",n),i=i.m}}else i=Promise.resolve();return i},disableStream:function(t,n){return e.disableStream(t,n)}})}(e),e.j.configure(e.g.streaming),e.m=od,e.dispatchEvent(dc("streaming")),a=n;case 2:for((s=e.j.j)||a||(a=Bc(e)?e.o.chooseVariant():null),u=[],c=l([(o=s||a).video,o.audio]),d=c.next();!d.done;d=c.next())(h=d.value)&&!h.segmentIndex&&u.push(h.createSegmentIndex());if(!(0<u.length)){I.u(4);break}return w(I,Promise.all(u),4);case 4:if(!o||0!=o.disabledUntilTime){I.u(2);break}if(e.H&&e.H.onInitialVariantChosen&&e.H.onInitialVariantChosen(o),e.i.isLowLatency&&!e.g.streaming.lowLatencyMode&&W("Low-latency live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details."),e.O&&function(e,t){e.j=t,e.j?e.i==$l?e.i=Ql:e.i==Zl&&(e.i=ec):e.i==Ql?e.i=$l:e.i==ec&&(e.i=Zl)}(e.O,e.i.isLowLatency&&e.g.streaming.lowLatencyMode),ed(e.i.presentationTimeline,e.g.playRangeStart,e.g.playRangeEnd),function(e,t,n){e.l.presentationTimeline.U()||(e.O=t,e.M=n)}(e.j,e.g.playRangeStart,e.g.playRangeEnd),f=function(t){e.F=function(e,t){return new Ys(e.h,e.i,e.g.streaming,t,(function(){e.Hb&&su(e.Hb,!0),e.j&&e.j.Xc(),e.M&&Ac(e)}),(function(t){return e.dispatchEvent(t)}))}(e,t),e.Hb=function(e,t){(t=new bl(e.bc,e.U()||0<t)).addEventListener("enter",(function(t){$c(e,"timelineregionenter",t.region)})),t.addEventListener("exit",(function(t){$c(e,"timelineregionexit",t.region)})),t.addEventListener("skip",(function(t){var n=t.region;t.seeking||($c(e,"timelineregionenter",n),$c(e,"timelineregionexit",n))}));var n=new ou(e.h);return n.g.add(t),e.ac&&n.g.add(e.ac),n}(e,t),xc(e,r,Math.max(e.i.minBufferTime,e.g.streaming.rebufferingGoal))},e.g.streaming.startAtSegmentBoundary||(null==(p=e.ga)&&e.i.startTime&&(p=e.i.startTime),f(p)),s){I.u(7);break}if(!e.g.streaming.startAtSegmentBoundary){I.u(8);break}return g=e.i.presentationTimeline,m=e.ga||e.h.currentTime,null==e.ga&&e.i.startTime&&(m=e.i.startTime),v=g.Kb(),y=g.Bb(),m<v?m=v:m>y&&(m=y),w(I,function(e,t){var n,i,r,a,o;return P((function(s){return 1==s.g?(n=e.audio,i=e.video,r=function(e,t){var n,i,r;return P((function(a){return 1==a.g?e?w(a,e.createSegmentIndex(),2):a.return(null):(i=(n=e.segmentIndex.Jb(t))?n.next().value:null)?(r=i.startTime,a.return(r)):a.return(null)}))},w(s,r(n,t),2)):3!=s.g?(a=s.h,w(s,r(i,t),3)):null!=(o=s.h)&&null!=a?s.return(Math.max(o,a)):null!=o?s.return(o):null!=a?s.return(a):s.return(t)}))}(a,m),9);case 9:b=I.h,f(b);case 8:Vc(e,a,!0,!1,0);case 7:return e.F.ready(),e.qc().find((function(e){return e.active}))||((S=wr(e.i.textStreams,e.Gb,e.sd,e.rd)[0]||null)&&du(e.A.h,S,!0),a&&(S?(function(e,t,n){if(0==e.g.autoShowText)return!1;if(1==e.g.autoShowText)return!0;var i=Yi(e.g.preferredTextLanguage);return n=Yi(n.language),2==e.g.autoShowText?qi(n,i):3==e.g.autoShowText?!!t&&(e=Yi(t.language),qi(n,i)&&!qi(e,n)):(W("Invalid autoShowText setting!"),!1)}(e,a.audio,S)&&(e.ja=!0),e.ja&&e.B.setTextVisibility(!0),qc(e)):e.ja=!1),S&&(e.g.streaming.alwaysStreamText||e.vf())&&(ju(e.j,S),Wc(e))),w(I,e.j.start(i),10);case 10:e.g.abr.enabled&&(e.o.enable(),zc(e)),Gc(e),Bc(e),e.i.variants.some((function(e){return e.primary})),((x=e.U())&&(e.g.streaming.liveSync&&e.g.streaming.liveSync.enabled||e.i.serviceDescription||e.g.streaming.liveSync.panicMode)||e.g.streaming.vodDynamicPlaybackRate)&&(A=function(){return Uc(e)},e.l.D(r,"timeupdate",A)),x||(E=function(){return _c(e)},e.l.D(r,"timeupdate",E),_c(e),e.i.nextUrl&&(0<e.g.streaming.preloadNextUrlWindow&&(k=function(){var t;return P((function(n){if(1==n.g)return t=e.h.duration-e.h.currentTime,!isNaN(t)&&t<=e.g.streaming.preloadNextUrlWindow?(e.l.cb(r,"timeupdate",k),w(n,e.preload(e.i.nextUrl),4)):n.u(0);e.na=n.h,T(n)}))},e.l.D(r,"timeupdate",k)),e.l.D(r,"ended",(function(){e.load(e.na||e.i.nextUrl)})))),e.s&&e.s.onManifestUpdated(x),e.Ba=!0,T(I)}}))}(y,h,m,g),0)}))}),"loadInner_"),20);case 20:!function(e){if(e.I)for(var t=l(e.I),n=t.next();!n.done;n=t.next())(n=n.value)();e.I=null}(r),y.Ka&&et()&&Pi(y.Ka)&&function(t,n,i){t.g&&e.ManagedMediaSource&&t.l&&(t.B&&t.g.removeChild(t.B),t.B=Io(n,i),t.g.appendChild(t.B),t.g.disableRemotePlayback=!1)}(y.I,y.Y,y.Ka),b.u(14);break;case 21:return w(b,u((function(){return P((function(e){return w(e,function(e,t,n){var i,r,a,o,s,u,c,d,h,f,p,g;return P((function(m){switch(m.g){case 1:if(hc(e,"src-equals"),i=e.h,e.F=new Ws(i),r=!1,e.qd.push((function(){r=!0})),null!=e.ga&&e.F.Ie(e.ga),e.K=new ru({Pd:function(){return i.playbackRate},oc:function(){return i.defaultPlaybackRate},Vf:function(e){i.playbackRate=e},Og:function(e){i.currentTime+=e}}),a=e.g.streaming.rebufferingGoal,xc(e,i,a),i.textTracks&&(yc(e),o=function(){var t=Mc(e).find((function(e){return"disabled"!==e.mode}));t&&(t.mode="showing")},s=function(){var t=Mc(e).find((function(e){return"disabled"!==e.mode}));t&&(t.mode="hidden")},e.l.D(i,"enterpictureinpicture",(function(){return o()})),e.l.D(i,"leavepictureinpicture",(function(){return s()})),i.remote?(e.l.D(i.remote,"connect",(function(){return s()})),e.l.D(i.remote,"connecting",(function(){return s()})),e.l.D(i.remote,"disconnect",(function(){return s()}))):"webkitCurrentPlaybackTargetIsWireless"in i&&e.l.D(i,"webkitcurrentplaybacktargetiswirelesschanged",(function(){return s()})),(u=i).webkitSupportsFullscreen&&e.l.D(u,"webkitpresentationmodechanged",(function(){"inline"!=u.webkitPresentationMode?o():s()}))),wc(e,i,t),c=function(e,t,n){try{if(!e.g.enabled)return t;var i=Hl(e);e:{switch(n.toLowerCase()){case"audio/mp4":case"audio/webm":case"audio/ogg":case"audio/mpeg":case"audio/aac":case"audio/flac":case"audio/wav":var r=zl;break e;case"video/webm":case"video/mp4":case"video/mpeg":case"video/mp2t":r=Yl;break e;case"application/x-mpegurl":case"application/vnd.apple.mpegurl":case"application/dash+xml":case"video/vnd.mpeg.dash.mpd":case"application/vnd.ms-sstr+xml":r="m";break e}r=void 0}return i.ot=r,i.su=!0,ql(t,Xl(i))}catch(e){return Y("CMCD_SRC_ERROR","Could not generate src CMCD data.",e),t}}(e.O,e.Y,n),!c.includes("#t=")&&(0<e.g.playRangeStart||isFinite(e.g.playRangeEnd))&&(c+="#t=",0<e.g.playRangeStart&&(c+=e.g.playRangeStart),isFinite(e.g.playRangeEnd)&&(c+=","+e.g.playRangeEnd)),!e.I){m.u(2);break}return w(m,e.I.destroy(),3);case 3:e.I=null;case 2:return Mo(i),i.src=c,(Ke()||qe())&&i.load(),"none"!=i.preload&&!i.autoplay&&Pi(n)&&et()&&i.load(),e.m=sd,e.dispatchEvent(dc("streaming")),d=new Gr,Bs(i,HTMLMediaElement.HAVE_METADATA,e.l,(function(){e.F.ready(),d.resolve()})),Bs(i,HTMLMediaElement.HAVE_CURRENT_DATA,e.l,(function(){var t,n,a,o,s;return P((function(u){if(1==u.g)return function(e){var t=e.g.preferredAudioLanguage;""!=t&&e.$g(t,e.g.preferredVariantRole)}(e),(t=Mc(e)).find((function(e){return"disabled"!=e.mode}))?(0<t.length&&(e.ja=!0,e.B.setTextVisibility(!0)),u.u(2)):w(u,new Promise((function(t){e.l.pa(i.textTracks,"change",t),new Be(t).$(1)})),2);if(r)return u.return();for(n=!1,a=l(t),o=a.next();!o.done;o=a.next())"disabled"!==(s=o.value).mode&&(n?(s.mode="disabled",W("Found more than one enabled text track, disabling it",s)):(Ic(e,s),n=!0));!function(e){var t=e.g.preferredTextLanguage;""!=t&&e.Pf(t,e.g.preferredTextRole,e.g.preferForcedSubs)}(e),T(u)}))})),i.error?d.reject(Zc(e)):"none"==i.preload&&(W('With <video preload="none">, the browser will not load anything until play() is called. We are unable to measure load latency in a meaningful way, and we cannot provide track info yet. Please do not use preload="none" with Shaka Player.'),d.resolve()),e.l.pa(i,"error",(function(){d.reject(Zc(e))})),w(m,Ki(e.g.streaming.loadTimeout,d),4);case 4:((h=e.U())&&(e.g.streaming.liveSync&&e.g.streaming.liveSync.enabled||e.g.streaming.liveSync.panicMode)||e.g.streaming.vodDynamicPlaybackRate)&&(f=function(){return Uc(e)},e.l.D(i,"timeupdate",f)),h||(p=function(){return _c(e)},e.l.D(i,"timeupdate",p),_c(e)),e.s&&(e.s.onManifestUpdated(h),h&&(g=e.Qb().end,e.l.D(i,"progress",(function(){var t=e.Qb().end;g!=t&&(e.s.onManifestUpdated(e.U()),g=t)})))),e.Ba=!0,T(m)}}))}(y,h,i),0)}))}),"srcEqualsInner_"),14);case 14:y.dispatchEvent(dc("loaded"));case 6:if(k(b),!r){b.u(23);break}return w(b,r.destroy(),23);case 23:y.na=null,I(b,0);break;case 5:if(!(v=E(b))||7e3==v.code){b.u(25);break}return w(b,y.ic(!1),25);case 25:throw v}}))},i.ej=function(e,t){e=void 0===e||e,t=void 0!==t&&t;var n,i=this;return P((function(r){return 1==r.g?w(r,pc(i),2):3!=r.g?(n=r.h,w(r,i.ic(e,t),3)):r.return(n)}))},i.tg=function(e,t){e=void 0!==e&&e,t=void 0!==t&&t;var n,i=this;return P((function(r){return 1==r.g?w(r,pc(i,t),2):3!=r.g?(n=r.h,w(r,i.detach(e),3)):r.return(n)}))},i.preload=function(e,t,n){t=void 0===t?null:t;var i,r=this;return P((function(a){return 1==a.g?w(a,gc(r,e,t,n),2):((i=a.h)?i.start():Jc(r,new De(2,7,7005)),a.return(i))}))},i.Te=function(){var e,t,n,i,r=this;return P((function(a){for(e=[],t=l(r.le),n=t.next();!n.done;n=t.next())(i=n.value).s||e.push(i.destroy());return r.le=[],w(a,Promise.all(e),0)}))},i.Ni=function(){for(var e=this.Z;e.g;)e.release()},i.Gc=function(e){return new Na(e)},i.configure=function(e,t){if(2==arguments.length&&"string"==typeof e&&(e=el(e,t)),e.streaming&&"forceTransmuxTS"in e.streaming&&(oe("streaming.forceTransmuxTS configuration","Please Use mediaSource.forceTransmux instead."),e.mediaSource.mediaSource=e.streaming.forceTransmuxTS,delete e.streaming.forceTransmuxTS),e.streaming&&"forceTransmux"in e.streaming&&(oe("streaming.forceTransmux configuration","Please Use mediaSource.forceTransmux instead."),e.mediaSource.mediaSource=e.streaming.forceTransmux,delete e.streaming.forceTransmux),e.streaming&&"useNativeHlsOnSafari"in e.streaming&&(oe("streaming.useNativeHlsOnSafari configuration","Please Use streaming.useNativeHlsForFairPlay or streaming.preferNativeHls instead."),e.streaming.preferNativeHls=e.streaming.useNativeHlsOnSafari&&Ye(),delete e.streaming.useNativeHlsOnSafari),e.streaming&&"boolean"==typeof e.streaming.liveSync){oe("streaming.liveSync","Please Use streaming.liveSync.enabled instead.");var n=e.streaming.liveSync;e.streaming.liveSync={},e.streaming.liveSync.enabled=n}if(e.streaming&&(!e.streaming.liveSync||!("targetLatency"in e.streaming.liveSync))&&("liveSyncMinLatency"in e.streaming||"liveSyncMaxLatency"in e.streaming)){n=e.streaming.liveSyncMinLatency||0;var i=Math.abs((e.streaming.liveSyncMaxLatency||1)-n)/2;e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.targetLatency=n+i,e.streaming.liveSync.targetLatencyTolerance=i}if(e.streaming&&"liveSyncMaxLatency"in e.streaming&&(oe("streaming.liveSyncMaxLatency","Please Use streaming.liveSync.targetLatency and streaming.liveSync.targetLatencyTolerance instead. Or, set the values in your DASH manifest"),delete e.streaming.liveSyncMaxLatency),e.streaming&&"liveSyncMinLatency"in e.streaming&&(oe("streaming.liveSyncMinLatency","Please Use streaming.liveSync.targetLatency and streaming.liveSync.targetLatencyTolerance instead. Or, set the values in your DASH manifest"),delete e.streaming.liveSyncMinLatency),e.streaming&&"liveSyncTargetLatency"in e.streaming&&(oe("streaming.liveSyncTargetLatency","Please Use streaming.liveSync.targetLatency instead."),e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.targetLatency=e.streaming.liveSyncTargetLatency,delete e.streaming.liveSyncTargetLatency),e.streaming&&"liveSyncTargetLatencyTolerance"in e.streaming&&(oe("streaming.liveSyncTargetLatencyTolerance","Please Use streaming.liveSync.targetLatencyTolerance instead."),e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.targetLatencyTolerance=e.streaming.liveSyncTargetLatencyTolerance,delete e.streaming.liveSyncTargetLatencyTolerance),e.streaming&&"liveSyncPlaybackRate"in e.streaming&&(oe("streaming.liveSyncPlaybackRate","Please Use streaming.liveSync.maxPlaybackRate instead."),e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.maxPlaybackRate=e.streaming.liveSyncPlaybackRate,delete e.streaming.liveSyncPlaybackRate),e.streaming&&"liveSyncMinPlaybackRate"in e.streaming&&(oe("streaming.liveSyncMinPlaybackRate","Please Use streaming.liveSync.minPlaybackRate instead."),e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.minPlaybackRate=e.streaming.liveSyncMinPlaybackRate,delete e.streaming.liveSyncMinPlaybackRate),e.streaming&&"liveSyncPanicMode"in e.streaming&&(oe("streaming.liveSyncPanicMode","Please Use streaming.liveSync.panicMode instead."),e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.panicMode=e.streaming.liveSyncPanicMode,delete e.streaming.liveSyncPanicMode),e.streaming&&"liveSyncPanicThreshold"in e.streaming&&(oe("streaming.liveSyncPanicThreshold","Please Use streaming.liveSync.panicThreshold instead."),e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.panicThreshold=e.streaming.liveSyncPanicThreshold,delete e.streaming.liveSyncPanicThreshold),e.mediaSource&&"sourceBufferExtraFeatures"in e.mediaSource){oe("mediaSource.sourceBufferExtraFeatures configuration","Please Use mediaSource.addExtraFeaturesToSourceBuffer() instead.");var r=e.mediaSource.sourceBufferExtraFeatures;e.mediaSource.addExtraFeaturesToSourceBuffer=function(){return r},delete e.mediaSource.sourceBufferExtraFeatures}return e.manifest&&e.manifest.hls&&"useSafariBehaviorForLive"in e.manifest.hls&&(oe("manifest.hls.useSafariBehaviorForLive configuration","Please Use liveSync config to keep on live Edge instead."),delete e.manifest.hls.useSafariBehaviorForLive),e.streaming&&"parsePrftBox"in e.streaming&&(oe("streaming.parsePrftBox configuration","Now fired without needing a configuration."),delete e.streaming.parsePrftBox),e.manifest&&e.manifest.dash&&"enableAudioGroups"in e.manifest.dash&&(oe("manifest.dash.enableAudioGroups configuration","It is now enabled by default and cannot be disabled."),delete e.manifest.dash.enableAudioGroups),e.streaming&&"dispatchAllEmsgBoxes"in e.streaming&&(oe("streaming.dispatchAllEmsgBoxes configuration","Please Use mediaSource.dispatchAllEmsgBoxes instead."),e.mediaSource.dispatchAllEmsgBoxes=e.streaming.dispatchAllEmsgBoxes,delete e.streaming.dispatchAllEmsgBoxes),e.streaming&&e.streaming.lowLatencyMode&&(null==e.streaming.inaccurateManifestTolerance&&(e.streaming.inaccurateManifestTolerance=0),null==e.streaming.rebufferingGoal&&(e.streaming.rebufferingGoal=.01),null==e.streaming.segmentPrefetchLimit&&(e.streaming.segmentPrefetchLimit=2),null==e.streaming.updateIntervalSeconds&&(e.streaming.updateIntervalSeconds=.1),null==e.streaming.maxDisabledTime&&(e.streaming.maxDisabledTime=1),null==e.streaming.retryParameters&&(e.streaming.retryParameters={}),null==e.streaming.retryParameters.baseDelay&&(e.streaming.retryParameters.baseDelay=100),null==e.manifest&&(e.manifest={}),null==e.manifest.dash&&(e.manifest.dash={}),null==e.manifest.dash.autoCorrectDrift&&(e.manifest.dash.autoCorrectDrift=!1),null==e.manifest.retryParameters&&(e.manifest.retryParameters={}),null==e.manifest.retryParameters.baseDelay&&(e.manifest.retryParameters.baseDelay=100),null==e.drm&&(e.drm={}),null==e.drm.retryParameters&&(e.drm.retryParameters={}),null==e.drm.retryParameters.baseDelay&&(e.drm.retryParameters.baseDelay=100)),n=cl(this.g,e,Nc(this)),Ec(this),n},i.getConfiguration=function(){var e=Nc(this);return cl(e,this.g,Nc(this)),e},i.Dg=function(){return cl(Nc(this),this.g,Nc(this)),nl(this.g,Nc(this))},i.yg=function(){if(this.h){var e=this.h.buffered.length;e=e?this.h.buffered.end(e-1):0;var t=this.getConfiguration().streaming.bufferingGoal;if(e>=(t=Math.min(this.h.currentTime+t,this.Qb().end)))return 1;if(!(e<=this.h.currentTime)&&e<t)return(e-this.h.currentTime)/(t-this.h.currentTime)}return 0},i.Ri=function(){for(var e in this.g)delete this.g[e];cl(this.g,Nc(this),Nc(this)),Ec(this)},i.Bg=function(){return this.m},i.lf=function(){return this.i?this.i.type:null},i.Yh=function(){return this.h},i.Ab=function(){return this.G},i.Mc=function(){return this.Y},i.xg=function(){return this.s?this.s:null},i.U=function(){return this.i&&!this.Ia()?this.i.presentationTimeline.U():!(!this.h||!this.h.src)&&1/0==this.h.duration},i.uc=function(){return!!this.i&&this.i.presentationTimeline.uc()},i.oi=function(){if(this.i&&!this.Ia()){var e=this.i.variants;return!!e.length&&!e[0].video}return!(!this.h||!this.h.src)&&(this.h.videoTracks?0==this.h.videoTracks.length:0==this.h.videoHeight)},i.Qb=function(){if(this.i&&!this.Ia()){if(!this.Ba&&"HLS"==this.i.type)return{start:0,end:0};var e=this.i.presentationTimeline;return{start:e.Kb(),end:e.Bb()}}return this.h&&this.h.src&&(e=this.h.seekable).length?{start:e.start(0),end:e.end(e.length-1)}:{start:0,end:0}},i.li=function(){this.U()&&(this.h.currentTime=this.Qb().end)},i.pi=function(){return this.Ba},i.keySystem=function(){var e=this.drmInfo();return e?e.keySystem:""},i.drmInfo=function(){return this.C?this.C.g:null},i.gd=function(){return this.C?this.C.gd():1/0},i.jf=function(){return this.C?this.C.jf():[]},i.Od=function(){return this.C?this.C.Od():{}},i.tf=function(){return!!this.M&&this.M.g==Br},i.ib=function(){return this.h?this.K?this.K.i:1:0},i.Bd=function(e,t){var n=this;t=void 0===t||t,0==e?W("A trick play rate of 0 is unsupported!"):(this.Ga.Va(),this.h.paused&&this.h.play(),this.K.set(e),this.m==od&&(this.o.playbackRateChanged(e),Lu(this.j,t&&1<Math.abs(e))),this.U()&&this.Ga.D(this.h,"timeupdate",(function(){var t=n.h.currentTime,i=n.Qb(),r=n.g.streaming.safeSeekOffset;0<e?Math.floor(t)>=Math.floor(i.end)&&n.$c():Math.floor(t)<=Math.floor(i.start+r)&&n.$c()})))},i.$c=function(){var e=this.K.oc();this.m==sd&&this.K.set(e),this.m==od&&(this.K.set(e),this.o.playbackRateChanged(e),Lu(this.j,!1)),this.Ga.Va()},i.rc=function(){if(this.i&&!this.Ia()){for(var e=this.j?this.j.j:null,t=[],n=0,i=l(this.i.variants),r=i.next();!r.done;r=i.next())if(yr(r=r.value)){var a=dr(r);a.active=r==e,a.active||1==n||null==e||r.video!=e.video||r.audio!=e.audio||(a.active=!0),a.active&&n++,t.push(a)}return t}return this.h&&this.h.audioTracks?Array.from(this.h.audioTracks).map((function(e){return mr(e)})):[]},i.qc=function(){if(this.i&&!this.Ia()){for(var e=this.j?this.j.s:null,t=[],n=l(this.i.textStreams),i=n.next();!i.done;i=n.next()){var r=hr(i=i.value);r.active=i==e,t.push(r)}return t}return this.h&&this.h.src&&this.h.textTracks?Mc(this).map((function(e){return gr(e)})):[]},i.Sh=function(){var e=this.ud;return this.i&&(e=this.i.imageStreams),e.map((function(e){return fr(e)}))},i.Jh=function(e){var t,n,i,r,a=this;return P((function(o){return 1==o.g?a.m!=od&&a.m!=sd?o.return(null):(t=a.ud,a.i&&(t=a.i.imageStreams),(n=t.find((function(t){return t.id==e})))?n.segmentIndex?o.u(2):w(o,n.createSegmentIndex(),2):o.return(null)):4!=o.g?(i=[],n.segmentIndex.yb((function(t){var r=kc(t.tilesLayout||n.tilesLayout);if(r){r=r.rows*r.lc;for(var o=t.j-t.startTime,s=0;s<r;s++)i.push(a.Fg(e,t.startTime+o*s/r))}})),w(o,Promise.all(i),4)):(r=o.h,o.return(r.filter((function(e){return e}))))}))},i.Fg=function(e,t){var n,i,r,a,o,s,u,l,c,d,h,f,p,g,m,v,y,b,T=this;return P((function(S){return 1==S.g?T.m!=od&&T.m!=sd?S.return(null):(n=T.ud,T.i&&(n=T.i.imageStreams),(i=n.find((function(t){return t.id==e})))?i.segmentIndex?S.u(2):w(S,i.createSegmentIndex(),2):S.return(null)):null==(r=i.segmentIndex.find(t))?S.return(null):(a=i.segmentIndex.get(r),(o=kc(a.tilesLayout||i.tilesLayout))?(s=i.width||0,u=i.height||0,l=s/o.lc,c=u/o.rows,d=o.lc*o.rows,h=a.j-a.startTime,f=a.A||h/d,p=a.startTime,m=g=0,1<d&&(v=Math.floor((t-a.startTime)/f),p=a.startTime+v*f,g=v%o.lc*l,m=Math.floor(v/o.lc)*c),y=!1,(b=a.thumbnailSprite)&&(y=!0,c=b.height,g=b.positionX,m=b.positionY,l=b.width),S.return({segment:a,imageHeight:u,imageWidth:s,height:c,positionX:g,positionY:m,startTime:p,duration:f,uris:a.N(),width:l,sprite:y})):S.return(null))}))},i.ah=function(e){var t,n=this;this.i&&this.F&&((t=n.i.textStreams.find((function(t){return t.id==e.id})))&&t!=n.j.s&&(du(n.A.h,t,!1),ju(n.j,t),Xc(n),Wc(n),n.Gb=t.language),!this.Ia())||function(){if(n.h&&n.h.textTracks){var t=Mc(n),i=t.find((function(e){return"disabled"!==e.mode}));(t=t.find((function(t){return pr(t)===e.id})))&&(i!==t&&(i&&(i.mode="disabled",n.l.cb(i,"cuechange"),n.B.remove(0,1/0)),t&&Ic(n,t)),Xc(n),Wc(n))}}()},i.Qf=function(e,t,n){var i=this;t=void 0!==t&&t,n=void 0===n?0:n,this.i&&this.F&&(function(){var r=i.i.variants.find((function(t){return t.id==e.id}));if(r&&yr(r)){var a=i.j.j;i.g.abr.enabled&&(a.video!=r.video||a.audio&&r.audio&&a.audio.language==r.audio.language&&a.audio.channelsCount==r.audio.channelsCount)&&W("Changing tracks while abr manager is enabled will likely result in the selected track being overriden. Consider disabling abr before calling selectVariantTrack()."),i.Ia()?Vc(i,r,!1,!1,0):Vc(i,r,!1,t||!1,n||0),i.xa=new jr(r,i.g.mediaSource.codecSwitchingStrategy),Bc(i)}}(),!this.Ia())||function(){if(i.h&&i.h.audioTracks)for(var t=Array.from(i.h.audioTracks),n=(t=l(t)).next();!n.done;n=t.next())if(pr(n=n.value)==e.id){Hc(i,n);break}}()},i.Lh=function(){return id(this.rc())},i.ei=function(){return id(this.qc())},i.Kh=function(){return Array.from(nd(this.rc()))},i.di=function(){return Array.from(nd(this.qc()))},i.$g=function(e,t,n,i,r){var a=this;n=void 0===n?0:n,i=void 0===i?0:i,r=void 0===r?"":r,this.i&&this.F&&(function(){function o(e,t){return e.video||t.video?e.video&&t.video?Math.abs((e.video.height||0)-(t.video.height||0))+Math.abs((e.video.width||0)-(t.video.width||0)):1/0:0}a.xa=new Or(e,t||"",n||0,"",!1,"","","",a.g.mediaSource.codecSwitchingStrategy,r||"");for(var s=a.j.j,u=a.xa.create(a.i.variants),c=null,d=(u=l(u.values())).next();!d.done;d=u.next())yr(d=d.value)&&(!c||o(c,s)>o(d,s))&&(c=d);c!=s&&(c?(s=dr(c),a.Qf(s,!0,i||0)):Fc(a))}(),!this.Ia())||function(){if(a.h&&a.h.audioTracks){var n=wr(a.rc(),e,t||"",!1)[0];n&&a.Qf(n)}}()},i.Pf=function(e,t,n){var i,r=this;n=void 0!==n&&n,this.i&&this.F&&(function(){r.Gb=e,r.sd=t||"",r.rd=n||!1;var i=wr(r.i.textStreams,r.Gb,r.sd,r.rd)[0]||null;i&&i!=r.j.s&&(du(r.A.h,i,!1),r.g.streaming.alwaysStreamText||r.vf())&&(ju(r.j,i),Xc(r),Wc(r))}(),!this.Ia())||(i=wr(r.qc(),e,t||"",n||!1)[0])&&r.ah(i)},i.Xi=function(e,t,n){var i=this;t=void 0===t||t,n=void 0===n?0:n,this.i&&this.F&&(function(){for(var r=null,a=l(i.i.variants),o=a.next();!o.done;o=a.next())if((o=o.value).audio.label==e){r=o;break}null!=r&&(i.xa=new Or(r.language,"",0,"",!1,"",e,"",i.g.mediaSource.codecSwitchingStrategy,""),Fc(i,t,n))}(),!this.Ia())||function(){if(i.h&&i.h.audioTracks){for(var t=Array.from(i.h.audioTracks),n=null,r=(t=l(t)).next();!r.done;r=t.next())(r=r.value).label==e&&(n=r);n&&Hc(i,n)}}()},i.vf=function(){var e=this.ja;return this.B?this.B.isTextVisible():e},i.zg=function(){return this.h&&this.h.currentSrc&&this.h.textTracks?Cc(this).map((function(e){return gr(e)})):[]},i.Nh=function(e){if(!this.h||!this.h.currentSrc||!this.h.textTracks)return[];var t=Yi(e),n=Cc(this).filter((function(e){return Yi(e.language)==t}));if(!n||!n.length)return[];e=[];for(var i=new Set,r=(n=l(n)).next();!r.done;r=n.next())if((r=r.value)&&r.cues)for(var a=(r=l(r.cues)).next();!a.done;a=r.next()){var o=a.value;(a=o.id)&&""!=a||(a=o.startTime+"-"+o.endTime+"-"+o.text),o={id:a,title:o.text,startTime:o.startTime,endTime:o.endTime},i.has(a)||(e.push(o),i.add(a))}return e},i.hh=function(e){e=!!e,this.ja!=e&&(this.ja=e,this.m==od?(this.B.setTextVisibility(e),this.g.streaming.alwaysStreamText||(e?this.j.s||0<(e=wr(this.i.textStreams,this.Gb,this.sd,this.rd)).length&&(ju(this.j,e[0]),Xc(this),Wc(this)):function(e){var t=e.i.get(yi);t&&(Wu(t),Yu(t).catch((function(){})),e.C=e.i.get(yi),e.i.delete(yi)),e.s=null}(this.j))):this.h&&this.h.src&&this.h.textTracks&&this.B.setTextVisibility(e),qc(this))},i.$h=function(){if(this.F)var e=this.F.Dd();else{if(null==this.ga)return new Date;e=this.ga}if(this.i&&!this.Ia()){var t=this.i.presentationTimeline;return new Date(1e3*((t.m||t.i)+e))}return this.h&&this.h.getStartDate?(t=this.h.getStartDate(),isNaN(t.getTime())?null:new Date(t.getTime()+1e3*e)):null},i.Eg=function(){if(this.i&&!this.Ia()){var e=this.i.presentationTimeline;return new Date(1e3*(e.m||e.i))}return this.h&&this.h.getStartDate?(e=this.h.getStartDate(),isNaN(e.getTime())?null:e):null},i.Qd=function(){return this.U()&&this.i?this.i.presentationTimeline.Qd():null},i.zb=function(){if(this.m==od)return this.I.zb();var e={total:[],audio:[],video:[],text:[]};return this.m==sd&&(e.total=Eo(this.h.buffered)),e},i.getStats=function(){if(this.m!=od&&this.m!=sd)return{width:NaN,height:NaN,streamBandwidth:NaN,decodedFrames:NaN,droppedFrames:NaN,corruptedFrames:NaN,stallsDetected:NaN,gapsJumped:NaN,estimatedBandwidth:NaN,completionPercent:NaN,loadLatency:NaN,manifestTimeSeconds:NaN,drmTimeSeconds:NaN,playTime:NaN,pauseTime:NaN,bufferingTime:NaN,licenseTime:NaN,liveLatency:NaN,maxSegmentDuration:NaN,manifestSizeBytes:NaN,bytesDownloaded:NaN,nonFatalErrorCount:NaN,manifestPeriodCount:NaN,manifestGapCount:NaN,switchHistory:[],stateHistory:[]};Oc(this);var e=this.h,t=e.currentTime/e.duration;if(!isNaN(t)&&!this.U()){var n=this.A;t=Math.round(100*t),n.i=isNaN(n.i)?t:Math.max(n.i,t)}if(this.F&&(this.A.S=this.F.hg(),this.A.Y=this.F.ig()),e.getVideoPlaybackQuality){n=e.getVideoPlaybackQuality(),t=this.A;var i=Number(n.totalVideoFrames);t.O=Number(n.droppedVideoFrames),t.M=i,this.A.L=Number(n.corruptedVideoFrames)}if(n=this.C&&(n=this.C).H?n.H:NaN,this.A.o=n,this.m==od){if(n=this.j.j,t=this.j.s,n){var r=(i=this.K?this.K.i:1)*n.bandwidth;t&&t.bandwidth&&(r+=i*t.bandwidth),this.A.A=r}n&&n.video&&(t=this.A,i=n.video.height||NaN,t.m=n.video.width||NaN,t.l=i),this.U()&&(n=this.Eg().valueOf()+1e3*e.currentTime,this.A.B=(Date.now()-n)/1e3),this.i&&(this.A.G=this.i.periodCount,this.A.F=this.i.gapCount,this.i.presentationTimeline&&(this.A.I=this.i.presentationTimeline.h)),n=this.o.getBandwidthEstimate(),this.A.s=n}this.m==sd&&((n=this.A).kc=isNaN(n.kc)?NaN:n.kc+NaN,n=this.A,t=e.videoHeight||NaN,n.m=e.videoWidth||NaN,n.l=t);var a=this.A;e=a.m,n=a.l,t=a.A,i=a.M,r=a.O;for(var o=a.L,s=a.Y,u=a.S,c=a.s,d=a.i,h=a.C,f=a.H,p=a.j,g=lu(a.g,"playing"),m=lu(a.g,"paused"),v=lu(a.g,"buffering"),y=a.o,b=a.B,w=a.I,T=a.Kg,S=a.kc,x=a.K,A=a.G,E=a.F,k=function(e){function t(e){return{timestamp:e.timestamp,state:e.state,duration:e.duration}}for(var n=[],i=l(e.h),r=i.next();!r.done;r=i.next())n.push(t(r.value));return e.g&&n.push(t(e.g)),n}(a.g),I=[],M=(a=l(a.h.g)).next();!M.done;M=a.next())M=M.value,I.push({timestamp:M.timestamp,id:M.id,type:M.type,fromAdaptation:M.fromAdaptation,bandwidth:M.bandwidth});return{width:e,height:n,streamBandwidth:t,decodedFrames:i,droppedFrames:r,corruptedFrames:o,stallsDetected:s,gapsJumped:u,estimatedBandwidth:c,completionPercent:d,loadLatency:h,manifestTimeSeconds:f,drmTimeSeconds:p,playTime:g,pauseTime:m,bufferingTime:v,licenseTime:y,liveLatency:b,maxSegmentDuration:w,manifestSizeBytes:T,bytesDownloaded:S,nonFatalErrorCount:x,manifestPeriodCount:A,manifestGapCount:E,stateHistory:k,switchHistory:I}},i.xh=function(e,t,n,i,r,a,o){o=void 0!==o&&o;var s,u,l,c,d,h,f,p,g,m,v=this;return P((function(y){switch(y.g){case 1:if(v.m!=od&&v.m!=sd)throw new De(1,7,7004);if("subtitles"!=n&&"captions"!=n&&W("Using a kind value different of `subtitles` or `captions` can cause unwanted issues."),i){y.u(2);break}return w(y,Dc(v,e),3);case 3:i=y.h;case 2:if(s=[],v.s&&(s=v.s.getCuePoints()),v.m!=sd){y.u(4);break}return o&&(n="forced"),w(y,Rc(v,e,t,n,i,a||"",s),5);case 5:if(u=Yi(t),l=v.qc(),c=l.find((function(e){return Yi(e.language)==u&&e.label==(a||"")&&e.kind==n})))return Gc(v),y.return(c);throw new De(1,2,2012);case 4:if(d=bi,h=v.h.duration,v.i&&(h=v.i.presentationTimeline.getDuration()),1/0==h)throw new De(1,4,4033);if(!s.length){y.u(6);break}return w(y,Pc(v,e,v.G,v.g.streaming.retryParameters),7);case 7:f=y.h,p=Lc(v,f,i,s),g=new Blob([p],{type:"text/vtt"}),e=Rs(g),i="text/vtt";case 6:if(m={id:v.fg++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:tu(0,h,[e]),mimeType:i||"",codecs:r||"",kind:n,encrypted:!1,drmInfos:[],keyIds:new Set,language:t,originalLanguage:t,label:a||null,type:d.wa,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!!o,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!0,fastSwitching:!1,fullMimeTypes:new Set([xi(i||"",r||"")]),isAudioMuxedInVideo:!1},!Ui(xi(m.mimeType,m.codecs)))throw new De(2,2,2014,i);return v.i.textStreams.push(m),Gc(v),y.return(hr(m))}}))},i.yh=function(e,t){var n,i,r,a,o,s,u,c,d,h,f,p,g,m,v,y,b,T=this;return P((function(S){switch(S.g){case 1:if(T.m!=od&&T.m!=sd)throw new De(1,7,7004);if(t){S.u(2);break}return w(S,Dc(T,e),3);case 3:t=S.h;case 2:if("text/vtt"!=t)throw new De(1,2,2017,e);if(n=bi,i=T.h.duration,T.i&&(i=T.i.presentationTimeline.getDuration()),1/0==i)throw new De(1,4,4045);return w(S,Pc(T,e,T.G,T.g.streaming.retryParameters),4);case 4:if(r=S.h,!(a=Fi[t]))throw new De(2,2,2014,t);for(o=a(),s={periodStart:0,segmentStart:0,segmentEnd:i,vttOffset:0},u=ge(r),c=o.parseMedia(u,s,e,[]),d=[],h=l(c),f=h.next(),p={};!f.done;p={ze:void 0,Hc:void 0},f=h.next())p.Hc=f.value,p.ze=null,g=function(t){return function(){return null==t.ze&&(t.ze=hi([e],[t.Hc.payload])),t.ze||[]}}(p),m=new vo(p.Hc.startTime,p.Hc.endTime,g,0,null,null,0,0,1/0),p.Hc.payload.includes("#xywh")&&4===(v=p.Hc.payload.split("#xywh=")[1].split(",")).length&&m.qe({height:parseInt(v[3],10),positionX:parseInt(v[0],10),positionY:parseInt(v[1],10),width:parseInt(v[2],10)}),d.push(m);if(y=t,!d.length){S.u(5);break}return w(S,Al(d[0].N()[0],T.G,T.g.manifest.retryParameters),6);case 6:y=S.h;case 5:return b={id:T.fg++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Zs(d),mimeType:y||"",codecs:"",kind:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:n.He,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,tilesLayout:"1x1",accessibilityPurpose:null,external:!0,fastSwitching:!1,fullMimeTypes:new Set([xi(y||"","")]),isAudioMuxedInVideo:!1},T.m==sd?T.ud.push(b):T.i.imageStreams.push(b),Gc(T),S.return(fr(b))}}))},i.wh=function(e,t,n){var i,r,a,o,s=this;return P((function(u){switch(u.g){case 1:if(s.m!=od&&s.m!=sd)throw new De(1,7,7004);if(n){u.u(2);break}return w(u,Dc(s,e),3);case 3:n=u.h;case 2:return i=[],s.s&&(i=s.s.getCuePoints()),w(u,Rc(s,e,t,"chapters",n,"",i),4);case 4:if(r=u.h,a=s.zg(),!(o=a.find((function(e){return e.language==t})))){u.u(5);break}return w(u,new Promise((function(e,t){s.l.pa(r,"load",e),s.l.pa(r,"error",(function(){t(new De(1,2,2015))}))})),6);case 6:return Gc(s),u.return(o);case 5:throw new De(1,2,2012)}}))},i.bj=function(e,t){this.fa.width=e,this.fa.height=t},i.Nf=function(e){if(this.m==od){var t=this.j;if(e=void 0===e?.1:e,t.m.g)t=!1;else if(t.A)t=!1;else{for(var n=l(t.i.values()),i=n.next();!i.done;i=n.next())!(i=i.value).ld||i.Ea||i.eb||(i.ld=!1,zu(t,i,e));t=!0}}else t=!1;return t},i.kf=function(){return W("Shaka Player's internal Manifest structure is NOT covered by semantic versioning compatibility guarantees. It may change at any time! Please consider filing a feature request for whatever you use getManifest() for."),this.i},i.Vh=function(){return this.La},i.Qh=function(){var e={video:null,audio:null,text:null};if(this.m!=od)return e;for(var t=this.j.j,n=this.h.currentTime,i=(t=l([t.video,t.audio,this.j.s])).next();!i.done;i=t.next())if((i=i.value)&&i.segmentIndex){var r=i.segmentIndex.find(n);r={codecs:(r=i.segmentIndex.get(r)).codecs||i.codecs,mimeType:r.mimeType||i.mimeType,bandwidth:r.bandwidth||i.bandwidth},"video"==i.type?(r.width=i.width,r.height=i.height,e.video=r):"audio"==i.type?e.audio=r:i.type==yi&&(e.text=r)}return e},i.kh=function(e){this.ge=e},i.disableStream=function(e,t){if(!this.g.abr.enabled||this.m===rd||!navigator.onLine||0==t||!this.i)return!1;if(this.i.variants.some((function(t){var n=t[e.type];return!(!n||n.id===e.id||t.disabledUntilTime||"audio"==e.type&&e.language!==n.language)}))){for(var n=!1,i=!1,r=l(this.i.variants),a=r.next();!a.done;a=r.next()){var o=(a=a.value)[e.type];o&&(o.id===e.id?(a.disabledUntilTime=Date.now()/1e3+t,n=!0):o.trickModeVideo&&o.trickModeVideo.id==e.id&&(i=!0))}return!(!n&&i||(this.je.Ra(1),t=this.zb().video.reduce((function(e,t){return e+t.end-t.start}),0),Fc(this,!1,t,!0,!1),0))}return!1},i.addFont=function(t,n){var i,r,a,o,s;return P((function(u){if(1==u.g)return"fonts"in document&&"FontFace"in e?w(u,document.fonts.ready,3):u.u(0);if(!("entries"in document.fonts))return u.return();for(i=function(e){for(var t=[],n=(e=e.entries()).next();!1===n.done;)t.push(n.value),n=e.next();return t},r=l(i(document.fonts)),a=r.next();!a.done;a=r.next())if((o=a.value).family==t&&"swap"==o.display)return u.return();s=new FontFace(t,"url("+n+")",{display:"swap"}),document.fonts.add(s),T(u)}))},i.Ia=function(){return!(!this.h||!this.h.remote)&&"disconnected"!=this.h.remote.state},F("shaka.Player",lc),lc.prototype.isRemotePlayback=lc.prototype.Ia,lc.prototype.addFont=lc.prototype.addFont,lc.prototype.setVideoContainer=lc.prototype.kh,lc.prototype.getFetchedPlaybackInfo=lc.prototype.Qh,lc.prototype.getManifestParserFactory=lc.prototype.Vh,lc.prototype.getManifest=lc.prototype.kf,lc.prototype.retryStreaming=lc.prototype.Nf,lc.prototype.setMaxHardwareResolution=lc.prototype.bj,lc.prototype.addChaptersTrack=lc.prototype.wh,lc.prototype.addThumbnailsTrack=lc.prototype.yh,lc.prototype.addTextTrackAsync=lc.prototype.xh,lc.prototype.getStats=lc.prototype.getStats,lc.prototype.getBufferedInfo=lc.prototype.zb,lc.prototype.getSegmentAvailabilityDuration=lc.prototype.Qd,lc.prototype.getPresentationStartTimeAsDate=lc.prototype.Eg,lc.prototype.getPlayheadTimeAsDate=lc.prototype.$h,lc.prototype.setTextTrackVisibility=lc.prototype.hh,lc.prototype.getChapters=lc.prototype.Nh,lc.prototype.getChaptersTracks=lc.prototype.zg,lc.prototype.isTextTrackVisible=lc.prototype.vf,lc.prototype.selectVariantsByLabel=lc.prototype.Xi,lc.prototype.selectTextLanguage=lc.prototype.Pf,lc.prototype.selectAudioLanguage=lc.prototype.$g,lc.prototype.getTextLanguages=lc.prototype.di,lc.prototype.getAudioLanguages=lc.prototype.Kh,lc.prototype.getTextLanguagesAndRoles=lc.prototype.ei,lc.prototype.getAudioLanguagesAndRoles=lc.prototype.Lh,lc.prototype.selectVariantTrack=lc.prototype.Qf,lc.prototype.selectTextTrack=lc.prototype.ah,lc.prototype.getThumbnails=lc.prototype.Fg,lc.prototype.getAllThumbnails=lc.prototype.Jh,lc.prototype.getImageTracks=lc.prototype.Sh,lc.prototype.getTextTracks=lc.prototype.qc,lc.prototype.getVariantTracks=lc.prototype.rc,lc.prototype.cancelTrickPlay=lc.prototype.$c,lc.prototype.trickPlay=lc.prototype.Bd,lc.prototype.getPlaybackRate=lc.prototype.ib,lc.prototype.isBuffering=lc.prototype.tf,lc.prototype.getKeyStatuses=lc.prototype.Od,lc.prototype.getActiveSessionsMetadata=lc.prototype.jf,lc.prototype.getExpiration=lc.prototype.gd,lc.prototype.drmInfo=lc.prototype.drmInfo,lc.prototype.keySystem=lc.prototype.keySystem,lc.prototype.isFullyLoaded=lc.prototype.pi,lc.prototype.goToLive=lc.prototype.li,lc.prototype.seekRange=lc.prototype.Qb,lc.prototype.isAudioOnly=lc.prototype.oi,lc.prototype.isInProgress=lc.prototype.uc,lc.prototype.isLive=lc.prototype.U,lc.prototype.getAdManager=lc.prototype.xg,lc.prototype.getAssetUri=lc.prototype.Mc,lc.prototype.getNetworkingEngine=lc.prototype.Ab,lc.prototype.getMediaElement=lc.prototype.Yh,lc.prototype.getManifestType=lc.prototype.lf,lc.prototype.getLoadMode=lc.prototype.Bg,lc.prototype.resetConfiguration=lc.prototype.Ri,lc.prototype.getBufferFullness=lc.prototype.yg,lc.prototype.getNonDefaultConfiguration=lc.prototype.Dg,lc.prototype.getConfiguration=lc.prototype.getConfiguration,lc.prototype.configure=lc.prototype.configure,lc.prototype.releaseAllMutexes=lc.prototype.Ni,lc.prototype.destroyAllPreloads=lc.prototype.Te,lc.prototype.preload=lc.prototype.preload,lc.prototype.detachAndSavePreload=lc.prototype.tg,lc.prototype.unloadAndSavePreload=lc.prototype.ej,lc.prototype.load=lc.prototype.load,lc.prototype.updateStartTime=lc.prototype.ij,lc.prototype.unload=lc.prototype.ic,lc.prototype.detach=lc.prototype.detach,lc.prototype.attachCanvas=lc.prototype.Ch,lc.prototype.attach=lc.prototype.Tb,lc.probeSupport=function(e){var t,n,i,r,a,o,s;return e=void 0===e||e,P((function(u){switch(u.g){case 1:if(t={},!e){u.u(2);break}return w(u,function(){var e,t,n,i,r,a,o,s,u,c,d,h,f,p,g,m,v,y,b,x,k,I,M,C,D,R,L;return P((function(N){if(1==N.g){for(e="org.w3.clearkey com.widevine.alpha com.widevine.alpha.experiment com.microsoft.playready com.microsoft.playready.hardware com.microsoft.playready.recommendation com.chromecast.playready com.apple.fps.1_0 com.apple.fps".split(" "),n={"com.widevine.alpha":t=["SW_SECURE_CRYPTO","SW_SECURE_DECODE","HW_SECURE_CRYPTO","HW_SECURE_DECODE","HW_SECURE_ALL"],"com.widevine.alpha.experiment":t,"com.microsoft.playready.recommendation":["150","2000","3000"]},a={videoCapabilities:i=[{contentType:'video/mp4; codecs="avc1.42E01E"'},{contentType:'video/webm; codecs="vp8"'}],audioCapabilities:r=[{contentType:'audio/mp4; codecs="mp4a.40.2"'},{contentType:'audio/webm; codecs="opus"'}],initDataTypes:["cenc","sinf","skd","keyids"]},o=[null,"cenc","cbcs","cbcs-1-9"],s=new Map,u=function(e,t){var n,i,r,a,o,u,l,c;return P((function(d){switch(d.g){case 1:return S(d,2),w(d,t.createMediaKeys(),4);case 4:A(d,3);break;case 2:return E(d),d.return();case 3:i=!!(n=t.getConfiguration().sessionTypes)&&n.includes("persistent-license"),Xe()&&(i=!1),r=t.getConfiguration().videoCapabilities,a=t.getConfiguration().audioCapabilities,o={persistentState:i,encryptionSchemes:[],videoRobustnessLevels:[],audioRobustnessLevels:[]},s.has(e)&&s.get(e)?o=s.get(e):s.set(e,o),(u=r[0].encryptionScheme)&&!o.encryptionSchemes.includes(u)&&o.encryptionSchemes.push(u),(l=r[0].robustness)&&!o.videoRobustnessLevels.includes(l)&&o.videoRobustnessLevels.push(l),(c=a[0].robustness)&&!o.audioRobustnessLevels.includes(c)&&o.audioRobustnessLevels.push(c),T(d)}}))},c=function(e,t,n,i){var r,o,s,c,d,h,f,p,g,m;return P((function(v){switch(v.g){case 1:for(S(v,2),r=kt(a),o=l(r.videoCapabilities),s=o.next();!s.done;s=o.next())(c=s.value).encryptionScheme=t,c.robustness=n;for(d=l(r.audioCapabilities),h=d.next();!h.done;h=d.next())(f=h.value).encryptionScheme=t,f.robustness=i;return(p=kt(r)).persistentState="required",p.sessionTypes=["persistent-license"],g=[p,r],w(v,Ki(1,navigator.requestMediaKeySystemAccess(e,g)),4);case 4:return m=v.h,w(v,u(e,m),5);case 5:A(v,0);break;case 2:E(v),T(v)}}))},d=function(e,t,n,a){var o,s,l;return P((function(c){switch(c.g){case 1:return S(c,2),o={type:"media-source",video:{contentType:i[0].contentType,width:640,height:480,bitrate:1,framerate:1},audio:{contentType:r[0].contentType,channels:2,bitrate:1,samplerate:1},keySystemConfiguration:{keySystem:e,video:{encryptionScheme:t,robustness:n},audio:{encryptionScheme:t,robustness:a}}},w(c,Ki(1,navigator.mediaCapabilities.decodingInfo(o)),4);case 4:return s=c.h,l=s.keySystemAccess,w(c,u(e,l),5);case 5:A(c,0);break;case 2:E(c),T(c)}}))},h=l(e),f=h.next();!f.done;f=h.next())p=f.value,s.set(p,null);for(g=[],m=l(o),v=m.next();!v.done;v=m.next())for(y=v.value,b=l(e),x=b.next();!x.done;x=b.next())"org.w3.clearkey"===(k=x.value)&&et()||(g.push(c(k,y,"","")),g.push(d(k,y,"","")));for(I=l(e),M=I.next();!M.done;M=I.next())for(C=M.value,D=l(n[C]||[]),R=D.next();!R.done;R=D.next())L=R.value,g.push(c(C,null,L,"")),g.push(c(C,null,"",L)),g.push(d(C,null,L,"")),g.push(d(C,null,"",L));return w(N,Promise.all(g),2)}return N.return(va(s))}))}(),3);case 3:t=u.h;case 2:var d={};if(Fe())for(var h in co)d[h]=!0;for(var f=(h=l(["application/dash+xml","application/x-mpegurl","application/vnd.apple.mpegurl","application/vnd.ms-sstr+xml"])).next();!f.done;f=h.next())d[f=f.value]=Fe()?!!co[f]:Ve(f);for(n=d,d={},f=(h=l(h='video/mp4; codecs="avc1.42E01E",video/mp4; codecs="avc3.42E01E",video/mp4; codecs="hev1.1.6.L93.90",video/mp4; codecs="hvc1.1.6.L93.90",video/mp4; codecs="hev1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="hvc1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="vp9",video/mp4; codecs="vp09.00.10.08",video/mp4; codecs="av01.0.01M.08",video/mp4; codecs="dvh1.05.01",video/mp4; codecs="dvh1.20.01",audio/mp4; codecs="mp4a.40.2",audio/mp4; codecs="ac-3",audio/mp4; codecs="ec-3",audio/mp4; codecs="ac-4.02.01.01",audio/mp4; codecs="opus",audio/mp4; codecs="flac",audio/mp4; codecs="dtsc",audio/mp4; codecs="dtse",audio/mp4; codecs="dtsx",video/webm; codecs="vp8",video/webm; codecs="vp9",video/webm; codecs="vp09.00.10.08",audio/webm; codecs="vorbis",audio/webm; codecs="opus",video/mp2t; codecs="avc1.42E01E",video/mp2t; codecs="avc3.42E01E",video/mp2t; codecs="hvc1.1.6.L93.90",video/mp2t; codecs="mp4a.40.2",video/mp2t; codecs="ac-3",video/mp2t; codecs="ec-3",text/vtt,application/mp4; codecs="wvtt",application/ttml+xml,application/mp4; codecs="stpp"'.split(",").concat(c(ji)))).next();!f.done;f=h.next()){d[f=f.value]=!!Ui(f)||(Fe()?ne(f)||!!On(f):Ve(f));var p=f.split(";")[0];d[p]=d[p]||d[f]}return i=d,w(u,st(),4);case 4:for(s in r=u.h,a={manifest:n,media:i,drm:t,hardwareResolution:r},o=ld)a[s]=o[s]();return u.return(a)}}))},lc.isBrowserSupported=function(){if(e.Promise||W("A Promise implementation or polyfill is required"),!(e.Promise&&e.Uint8Array&&Array.prototype.forEach)||rt("Trident/"))return!1;var t=et();return!(t&&9>t||!(e.MediaKeys&&e.navigator&&e.navigator.requestMediaKeySystemAccess&&e.MediaKeySystemAccess&&e.MediaKeySystemAccess.prototype.getConfiguration))&&(!!Fe()||Ve("application/x-mpegurl"))},lc.setAdManagerFactory=function(e){cd=e},lc.registerSupportPlugin=function(e,t){ld[e]=t},lc.prototype.destroy=lc.prototype.destroy;var rd=0,ad=1,od=2,sd=3;lc.LoadMode={DESTROYED:rd,NOT_LOADED:ad,MEDIA_SOURCE:od,SRC_EQUALS:sd},lc.version="v4.12.5";var ud=["4","12"];le=new function(e){this.g=e,this.i=se,this.h=ue}(new ae(Number(ud[0]),Number(ud[1])));var ld={},cd=null;function dd(){this.g=[],this.i=this.l=this.j=this.h=0}function hd(e){return e.g.length?e.g.reduce((function(e,t){return e+t}),0)/e.g.length:0}function fd(e,t,n){var i=this;this.g=e,this.h=t,this.j=n,this.i=!1,this.l=this.h.getVolume(),this.m=new Z,this.m.D(this.h,google.ima.AdEvent.Type.PAUSED,(function(){i.i=!0})),this.m.D(this.h,google.ima.AdEvent.Type.RESUMED,(function(){i.i=!1}))}function pd(){}function gd(e,t){var n=[],i=0;null!=t&&(i=t);for(var r=(e=l(Nt(e,"Ad"))).next();!r.done;r=e.next())if((r=_t(r.value,"InLine"))&&(r=_t(r,"Creatives")))for(var a=(r=l(Nt(r,"Creative"))).next();!a.done;a=r.next()){var o=_t(a.value,"Linear");if(o&&(a=null,o.attributes.skipoffset&&(a=At(o.attributes.skipoffset),isNaN(a)&&(a=null)),o=_t(o,"MediaFiles"))){var s=Nt(o,"MediaFile");for(o=s,(s=s.filter((function(e){return"streaming"==e.attributes.delivery}))).length&&(o=s),s=(o=l(o=o.sort((function(e,t){return(parseInt(t.attributes.height,10)||0)-(parseInt(e.attributes.height,10)||0)})))).next();!s.done;s=o.next()){var u=jt(s=s.value);if(u){n.push({id:null,startTime:i,endTime:null,uri:u,mimeType:s.attributes.type||null,isSkippable:null!=a,skipOffset:a,skipFor:null,canJump:!1,resumeOffset:0,playoutLimit:null,once:!0,pre:null==t,post:1/0==t,timelineRange:!1});break}}}}return n}function md(t,n,i,r,a){var o=this;this.s=t,this.i=n,this.F=!1,this.A=this.o=null,this.G=NaN,this.l=a,this.j=null,this.h=new Z,google.ima.settings.setLocale(i),google.ima.settings.setDisableCustomPlaybackForIOS10Plus(!0),this.C=new google.ima.AdDisplayContainer(this.s,this.i),this.C.initialize(),this.m=new google.ima.AdsLoader(this.C),this.m.getSettings().setPlayerType("shaka-player"),this.m.getSettings().setPlayerVersion("v4.12.5"),this.g=null,this.B=r||new google.ima.AdsRenderingSettings,this.h.D(this.m,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,(function(t){!function(t,n){if(t.l(new Jr("ads-loaded",(new Map).set("loadTime",Date.now()/1e3-t.G))),t.o.customPlayheadTracker){var i={currentTime:t.i.currentTime};t.g=n.getAdsManager(i,t.B),t.i.muted?t.g.setVolume(0):t.g.setVolume(t.i.volume),t.h.D(t.i,"timeupdate",(function(){t.i.duration&&(i.currentTime=t.i.currentTime)})),t.h.D(t.i,"volumechange",(function(){t.j&&(t.j.setVolume(t.i.volume),t.i.muted&&t.j.setMuted(!0))}))}else t.g=n.getAdsManager(t.i,t.B);t.l(new Jr("ima-ad-manager-loaded",(new Map).set("imaAdManager",t.g)));var r=t.g.getCuePoints();if(r.length){n=[];for(var a=(r=l(r)).next();!a.done;a=r.next())n.push({start:a.value,end:null});t.l(new Jr("ad-cue-points-changed",(new Map).set("cuepoints",n)))}!function(e){function t(t,n){t=(new Map).set("originalEvent",t),e.l(new Jr(n,t))}e.h.D(e.g,google.ima.AdErrorEvent.Type.AD_ERROR,(function(t){vd(e,t)})),e.h.D(e.g,google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED,(function(t){bd(e,t)})),e.h.D(e.g,google.ima.AdEvent.Type.STARTED,(function(t){bd(e,t)})),e.h.D(e.g,google.ima.AdEvent.Type.FIRST_QUARTILE,(function(e){t(e,"ad-first-quartile")})),e.h.D(e.g,google.ima.AdEvent.Type.MIDPOINT,(function(e){t(e,"ad-midpoint")})),e.h.D(e.g,google.ima.AdEvent.Type.THIRD_QUARTILE,(function(e){t(e,"ad-third-quartile")})),e.h.D(e.g,google.ima.AdEvent.Type.COMPLETE,(function(e){t(e,"ad-complete")})),e.h.D(e.g,google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED,(function(t){wd(e,t)})),e.h.D(e.g,google.ima.AdEvent.Type.ALL_ADS_COMPLETED,(function(t){wd(e,t)})),e.h.D(e.g,google.ima.AdEvent.Type.SKIPPED,(function(e){t(e,"ad-skipped")})),e.h.D(e.g,google.ima.AdEvent.Type.VOLUME_CHANGED,(function(e){t(e,"ad-volume-changed")})),e.h.D(e.g,google.ima.AdEvent.Type.VOLUME_MUTED,(function(e){t(e,"ad-muted")})),e.h.D(e.g,google.ima.AdEvent.Type.PAUSED,(function(n){e.j&&(e.j.i=!0,t(n,"ad-paused"))})),e.h.D(e.g,google.ima.AdEvent.Type.RESUMED,(function(n){e.j&&(e.j.i=!1,t(n,"ad-resumed"))})),e.h.D(e.g,google.ima.AdEvent.Type.SKIPPABLE_STATE_CHANGED,(function(n){e.j&&t(n,"ad-skip-state-changed")})),e.h.D(e.g,google.ima.AdEvent.Type.CLICK,(function(e){t(e,"ad-clicked")})),e.h.D(e.g,google.ima.AdEvent.Type.AD_PROGRESS,(function(e){t(e,"ad-progress")})),e.h.D(e.g,google.ima.AdEvent.Type.AD_BUFFERING,(function(e){t(e,"ad-buffering")})),e.h.D(e.g,google.ima.AdEvent.Type.IMPRESSION,(function(e){t(e,"ad-impression")})),e.h.D(e.g,google.ima.AdEvent.Type.DURATION_CHANGE,(function(e){t(e,"ad-duration-changed")})),e.h.D(e.g,google.ima.AdEvent.Type.USER_CLOSE,(function(e){t(e,"ad-closed")})),e.h.D(e.g,google.ima.AdEvent.Type.LOADED,(function(e){t(e,"ad-loaded")})),e.h.D(e.g,google.ima.AdEvent.Type.ALL_ADS_COMPLETED,(function(e){t(e,"all-ads-completed")})),e.h.D(e.g,google.ima.AdEvent.Type.LINEAR_CHANGED,(function(e){t(e,"ad-linear-changed")})),e.h.D(e.g,google.ima.AdEvent.Type.AD_METADATA,(function(e){t(e,"ad-metadata")})),e.h.D(e.g,google.ima.AdEvent.Type.LOG,(function(e){t(e,"ad-recoverable-error")})),e.h.D(e.g,google.ima.AdEvent.Type.AD_BREAK_READY,(function(e){t(e,"ad-break-ready")})),e.h.D(e.g,google.ima.AdEvent.Type.INTERACTION,(function(e){t(e,"ad-interaction")}))}(t);try{t.g.init(t.i.offsetWidth,t.i.offsetHeight,yd(t)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL),t.h.D(t.i,"loadeddata",(function(){t.g.resize(t.i.offsetWidth,t.i.offsetHeight,yd(t)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)})),"ResizeObserver"in e?(t.A=new ResizeObserver((function(){t.g.resize(t.i.offsetWidth,t.i.offsetHeight,yd(t)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)})),t.A.observe(t.i)):t.h.D(document,"fullscreenchange",(function(){t.g.resize(t.i.offsetWidth,t.i.offsetHeight,yd(t)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)})),t.F||t.o.skipPlayDetection?t.g.start():t.h.pa(t.i,"play",(function(){t.F=!0,t.g.start()}))}catch(e){wd(t,null)}}(o,t)})),this.h.D(this.m,google.ima.AdErrorEvent.Type.AD_ERROR,(function(e){vd(o,e)})),this.h.D(this.i,"ended",(function(){o.m.contentComplete()})),this.h.pa(this.i,"play",(function(){o.F=!0}))}function vd(e,t){t.getError(),t=(new Map).set("originalEvent",t),e.l(new Jr("ad-error",t)),wd(e,null),e.l(new Jr("ad-cue-points-changed",(new Map).set("cuepoints",[])))}function yd(e){return document.fullscreenEnabled?!!document.fullscreenElement:!!(e=e.i).webkitSupportsFullscreen&&e.webkitDisplayingFullscreen}function bd(e,t){var n=t.getAd();n?(e.j=new fd(n,e.g,e.i),t.type!=google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED||e.o.supportsMultipleMediaElements||e.l(new Jr("ad-content-pause-requested")),t=(new Map).set("ad",e.j).set("sdkAdObject",n).set("originalEvent",t),e.l(new Jr("ad-started",t)),e.j.isLinear()&&(e.s.setAttribute("ad-active","true"),e.o.customPlayheadTracker||e.i.pause(),e.i.muted?((t=e.j).l=e.i.volume,t.h.setVolume(0)):e.j.setVolume(e.i.volume))):W("The IMA SDK fired a "+t.type+" event with no associated ad. Unable to play ad!")}function wd(e,t){t&&t.type==google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED&&!e.o.supportsMultipleMediaElements&&e.l(new Jr("ad-content-resume-requested")),e.l(new Jr("ad-stopped",(new Map).set("originalEvent",t))),e.j&&e.j.isLinear()&&(e.s.removeAttribute("ad-active"),e.o.customPlayheadTracker||e.i.ended||e.i.play())}function Td(e,t,n,i,r,a,o,s){this.g=e,this.i=(this.h=t)?n||0:n,this.j=i,this.o=r,this.s=a,this.l=o,this.m=s}function Sd(e,t,n,i){function r(){if(!a.H&&a.l&&!a.B.Ia()){a.l=a.h.currentTime,a.m&&!a.m.pre&&!a.m.post&&a.l<a.m.startTime&&(a.m=null);var e=Ed(a);e&&kd(a,e,1,1,Date.now())}}var a=this;if(this.M=null,this.G=e,this.B=t,this.h=n,this.F=null,this.s=!0,this.o=this.h,this.i=i,this.I=new Set,this.C=new Set,this.A=new Map,this.g=new lc,Md(this),this.K=new Z,this.j=new Z,this.H=!1,this.m=this.l=null,this.K.D(this.h,"timeupdate",(function(){if(!(a.H||a.l||a.B.Ia())){a.l=a.h.currentTime;var e=Ed(a,!0);e&&kd(a,e,1,1,Date.now())}})),this.K.D(this.h,"ended",(function(){r()})),this.L=new Be(r),"requestVideoFrameCallback"in this.h&&!it()){var o=this.h,s=function(){r(),o.requestVideoFrameCallback(s)};o.requestVideoFrameCallback(s)}else this.L.Ra(.025);this.O=new Be((function(){var e,t,n,i,r,o,s,u,c,d,h;return P((function(f){switch(f.g){case 1:if(!a.C.size||null==a.l){f.u(0);break}if((e=a.B.Bg())==rd||e==ad)return f.return();t=!1,n=Array.from(a.C),i=a.B.Qb(),r=l(n),o=r.next();case 3:if(o.done){f.u(5);break}if((s=o.value)==a.m){f.u(4);break}if(u=s.endTime||s.startTime,!(1<=i.start-u)){0<(c=s.startTime-a.l)&&10>=c&&(a.A.has(s)||a.A.set(s,a.g.preload(s.uri,null,s.mimeType||void 0))),f.u(4);break}if(!a.A.has(s)){f.u(7);break}return w(f,a.A.get(s),8);case 8:(d=f.h)&&d.destroy(),a.A.delete(s);case 7:h=JSON.stringify(s),a.I.has(h)&&a.I.delete(h),a.C.delete(s),t=!0;case 4:o=r.next(),f.u(3);break;case 5:t&&Id(a),T(f)}}))})).Ra(1)}function xd(e){if(e.G&&e.M&&!e.H){var t=e.M.supportsMultipleMediaElements,n=e.h;n.webkitSupportsFullscreen&&n.webkitDisplayingFullscreen&&(t=!1),e.s==t&&(e.s=!t,e.s?(e.o=e.h,e.F&&(e.F.parentElement&&e.G.removeChild(e.F),e.F=null)):(e.F||((t=document.createElement(e.h.tagName)).autoplay=!0,t.style.position="absolute",t.style.top="0",t.style.left="0",t.style.width="100%",t.style.height="100%",t.style.backgroundColor="rgb(0, 0, 0)",t.setAttribute("playsinline",""),e.F=t),e.o=e.F))}}function Ad(e,t){for(var n=!1,i=(t=l(t)).next();!i.done;i=t.next()){var r=(i=i.value).id||JSON.stringify(i);if(!e.I.has(r)){if(n=!0,e.I.add(r),e.C.add(i),r=!1,i.pre&&null==e.l)r=!0;else if(0!=i.startTime||i.canJump){if(null!=e.l){var a=i.startTime-e.l;0<a&&10>=a&&(r=!0)}}else r=!0;r&&(e.A.has(i)||e.A.set(i,e.g.preload(i.uri,null,i.mimeType||void 0)))}}n&&Id(e)}function Ed(e,t,n){t=void 0!==t&&t,n=void 0===n?null:n;var i=0,r=null;if(e.C.size&&null!=e.l){var a=e.h.ended,o=Array.from(e.C).sort((function(e,t){return t.startTime-e.startTime})),s=o;for(s=t?o.filter((function(e){return e.pre})):a?o.filter((function(e){return e.post})):o.filter((function(e){return!e.pre&&!e.post})),s=(o=l(s)).next();!s.done;s=o.next()){s=s.value;var u=!1;if(t)u=s.pre;else if(a)u=s.post;else if(!s.pre&&!s.post){var c=e.l-Math.round(1e3*s.startTime)/1e3;0<c&&(1>=c||!s.canJump)&&(u=!(null==n&&e.m&&!e.m.pre&&!e.m.post&&e.m.startTime>=s.startTime))}u&&(!e.m||s.startTime>=e.m.startTime)&&(i==(n||0)?r=s:r&&!s.canJump&&.001<Math.round(1e3*s.startTime)/1e3-Math.round(1e3*r.startTime)/1e3&&(r=s,i=0),i++)}}return r}function kd(e,t,n,i,r,a){var o,s,u,l,c,d,h,f,p,g,m,v,y,b,x,k;a=void 0===a?0:a,P((function(I){switch(I.g){case 1:if(xd(e),e.m=t,o=Date.now(),!e.o.parentElement&&e.G&&e.G.appendChild(e.o),1==i&&1==n&&(n=Array.from(e.C).filter((function(e){return t.pre?e.pre==t.pre:t.post?e.post==t.post:.001>Math.abs(e.startTime-t.startTime)})).length),t.once&&(a++,e.C.delete(t),Id(e)),e.H=!0,!e.s||1!=i){I.u(2);break}return e.i(new Jr("ad-content-pause-requested",(new Map).set("saveLivePosition",!0))),s=new Gr,u=function(t){return P((function(n){if(1==n.g)return"detach"!=t.state?n.u(0):it()?w(n,new Promise((function(e){return new Be(e).$(.1)})),3):n.u(3);s.resolve(),e.j.cb(e.B,"onstatechange",u),T(n)}))},e.j.D(e.B,"onstatechange",u),w(I,s,2);case 2:return e.s||(e.h.pause(),null!=t.resumeOffset&&0!=t.resumeOffset&&(e.h.currentTime+=t.resumeOffset)),l=!1,c=null,d=function(){if(!e.s&&null==t.resumeOffset)if(t.timelineRange&&t.endTime&&1/0!=t.endTime)e.h.currentTime!=t.endTime&&(e.h.currentTime=t.endTime);else{var n=Date.now();e.h.currentTime+=(n-r)/1e3,r=n}},h=function(){var o,s;return P((function(u){if(1==u.g)return d(),c&&c.stop(),(o=Ed(e,t.pre,i-a))?(e.i(new Jr("ad-stopped")),e.j.Va(),kd(e,o,n,++i,r,a),u.u(0)):(t.post&&(e.l=null,e.m=null),e.s?w(u,e.g.detach(),4):w(u,e.g.ic(),4));e.s&&(null==(s=t.resumeOffset)&&(s=t.timelineRange&&t.endTime&&1/0!=t.endTime?t.endTime-(e.l||0):(Date.now()-r)/1e3),e.i(new Jr("ad-content-resume-requested",(new Map).set("offset",s)))),e.i(new Jr("ad-stopped")),e.j.Va(),e.H=!1,e.s?Id(e):(d(),e.h.ended||e.h.play()),xd(e),T(u)}))},f=function(t){return P((function(n){return l?n.return():(l=!0,e.i(new Jr("ad-error",(new Map).set("originalEvent",t))),w(n,h(),0))}))},p=function(){return P((function(t){if(1==t.g)return l?t.return():(l=!0,w(t,h(),2));e.i(new Jr("ad-complete")),T(t)}))},g=function(){return P((function(t){return l?t.return():(l=!0,e.i(new Jr("ad-skipped")),w(t,h(),0))}))},m=new Td(e.o,t.isSkippable,t.skipOffset,t.skipFor,g,n,i,!e.s),e.s||(m.setMuted(e.h.muted),m.setVolume(e.h.volume)),e.i(new Jr("ad-started",(new Map).set("ad",m))),(v=m.canSkipNow())&&e.i(new Jr("ad-skip-state-changed")),e.j.pa(e.g,"error",f),e.j.D(e.o,"timeupdate",(function(){if(e.o.duration){var t=m.canSkipNow();v!=t&&0<m.getRemainingTime()&&0<m.getDuration()&&e.i(new Jr("ad-skip-state-changed")),v=t}})),e.j.pa(e.g,"firstquartile",(function(){d(),e.i(new Jr("ad-first-quartile"))})),e.j.pa(e.g,"midpoint",(function(){d(),e.i(new Jr("ad-midpoint"))})),e.j.pa(e.g,"thirdquartile",(function(){d(),e.i(new Jr("ad-third-quartile"))})),e.j.pa(e.g,"complete",p),e.j.D(e.o,"play",(function(){e.i(new Jr("ad-resumed"))})),e.j.D(e.o,"pause",(function(){var t=e.g.getConfiguration();e.o.currentTime>=t.playRangeEnd?p():e.i(new Jr("ad-paused"))})),e.j.D(e.o,"volumechange",(function(){e.o.muted?e.i(new Jr("ad-muted")):e.i(new Jr("ad-volume-changed"))})),S(I,4),Md(e),t.startTime&&t.endTime&&1/0!=t.endTime&&t.startTime!=t.endTime&&0<(y=t.endTime-t.startTime)&&e.g.configure("playRangeEnd",y),t.playoutLimit&&(c=new Be((function(){m.skip()})).$(t.playoutLimit),e.g.configure("playRangeEnd",t.playoutLimit)),w(I,e.g.Tb(e.o),6);case 6:return e.A.has(t)?w(I,e.A.get(t),10):w(I,e.g.load(t.uri,null,t.mimeType||void 0),8);case 10:return b=I.h,e.A.delete(t),w(I,b?e.g.load(b):e.g.load(t.uri,null,t.mimeType||void 0),8);case 8:t.playoutLimit&&(c&&c.stop(),c=new Be((function(){m.skip()})).$(t.playoutLimit)),x=(Date.now()-o)/1e3,e.i(new Jr("ads-loaded",(new Map).set("loadTime",x))),e.s&&e.h.play(),A(I,0);break;case 4:k=E(I),f(k),T(I)}}))}function Id(e){for(var t=[],n=l(e.C),i=n.next(),r={};!i.done;r={Sb:void 0},i=n.next())i=i.value,r.Sb={start:i.startTime,end:null},i.pre?(r.Sb.start=0,r.Sb.end=null):i.post?(r.Sb.start=-1,r.Sb.end=null):i.timelineRange&&(r.Sb.end=i.endTime),t.find(function(e){return function(t){return e.Sb.start==t.start&&e.Sb.end==t.end}}(r))||t.push(r.Sb);e.i(new Jr("ad-cue-points-changed",(new Map).set("cuepoints",t)))}function Md(e){e.g.configure(e.B.Dg()),e.g.configure("ads.disableHLSInterstitial",!0),e.g.configure("ads.disableDASHInterstitial",!0);var t=e.g.Ab();t.og(),t.pg(),ra(e.B.Ab(),t)}function Cd(e,t,n){var i,r;return P((function(a){return 1==a.g?(i=aa([t],{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4}),w(a,e.B.Ab().request(7,i,n).promise,2)):(r=a.h,a.return(r.data))}))}function Dd(e,t,n,i,r){this.h=e,this.j=At(this.h.skipOffset),this.g=r,this.i=t,this.l=n,this.o=i,this.m=!1}function Rd(e,t,n,i){this.B=e,this.K=t,this.h=n,this.l=null,this.S=NaN,this.i=i,this.I=!1,this.A=null,this.j=[],this.M=[],this.L=this.C=this.g=null,this.F=new Map,this.m=[],this.s=[],this.G="",this.O=!0,this.H="",this.o=new Z}function Pd(e,t){var n,i,r,a,o,s,u,l;P((function(c){return 1==c.g?t.staticResource?(n=Ld(t),e.F.get(n)?c.return():(i={type:9},r=aa([t.staticResource],{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4}),a=e.K.request(7,r,i),S(c,2),e.F.set(n,[]),w(c,a.promise,4))):c.return():2!=c.g?(o=c.h,s=dt(o.data),u=JSON.parse(s),l=u.apps,e.F.set(n,l),A(c,0)):(E(c),e.F.delete(n),void T(c))}))}function Ld(e){return[e.adId,e.adParameters,e.adSystem,e.adTitle,e.creativeAdId,e.creativeId,e.creativeSequence,e.height,e.width,e.staticResource].join("")}function Nd(e){var t=e.h.currentTime;if(0!=t&&null==e.A){for(var n,i,r=l(e.j),a=r.next();!a.done;a=r.next())for(var o=l((a=a.value).ads),s=o.next();!s.done;s=o.next())if(s=s.value,i){if(s.startTimeInSeconds<t&&s.startTimeInSeconds>i.startTimeInSeconds+i.durationInSeconds){i=s,n=a;break}}else s.startTimeInSeconds<t&&(i=s,n=a);n&&i&&!e.M.includes(i.adId)&&(e.A=t,e.h.currentTime=n.startTimeInSeconds)}}function jd(e){if(e.h.duration&&(e.g||e.j.length)){var t=e.h.currentTime,n=!1;if(e.g){n=!0;var i=e.C,r=i.startTimeInSeconds+.5*i.durationInSeconds,a=i.startTimeInSeconds+.75*i.durationInSeconds;t>=i.startTimeInSeconds+.25*i.durationInSeconds&&!e.s.includes("firstQuartile")?(e.s.push("firstQuartile"),_d(e,"firstQuartile")):t>=r&&!e.s.includes("midpoint")?(e.s.push("midpoint"),_d(e,"midpoint")):t>=a&&!e.s.includes("thirdQuartile")&&(e.s.push("thirdQuartile"),_d(e,"thirdQuartile")),i=e.g.getRemainingTime(),r=e.g.getDuration(),e.g.canSkipNow()&&0<i&&0<r&&_d(e,"skipStateChanged"),0<r&&(0>=i||i>r)&&Od(e)}if(!e.g||!e.g.isLinear()){e:for(i=l(e.j),r=i.next();!r.done&&(r=r.value,!e.g||!e.g.isLinear());r=i.next())for(a=0;a<r.ads.length;a++){var o=r.ads[a],s=o.startTimeInSeconds+o.durationInSeconds;if(o.startTimeInSeconds<=t&&s>t){if(e.M.includes(o.adId)){if(e.h.ended)continue;e.h.currentTime=s;break e}Od(e),e.L=r,e.g=new Dd(o,a+1,r.ads.length,!0,e.h),e.C=o,0===a&&_d(e,"breakStart"),Ud(e);break}}if(!e.g)for(r=(i=l(e.j)).next();!r.done&&(r=r.value,!e.g);r=i.next())for(a=0;a<r.nonLinearAdsList.length;a++)if((o=r.nonLinearAdsList[a]).nonLinearAdList.length){s=r.startTimeInSeconds;var u=e.F.get(Ld(o.nonLinearAdList[0]));if(s<=t&&u&&u.length){Od(e),s=e;for(var c=(u=l(u)).next();!c.done;c=u.next())if((c=c.value).data.source.length){var d=document.createElement("img");d.src=c.data.source[0].url,d.style.top=(c.placeholder.top||0)+"%",d.style.height=100-(c.placeholder.top||0)+"%",d.style.left=(c.placeholder.left||0)+"%",d.style.maxWidth=100-(c.placeholder.left||0)+"%",d.style.objectFit="contain",d.style.position="absolute",s.B.appendChild(d)}e.L=r,e.g=new Dd(o,a+1,r.ads.length,!1,e.h),e.C=o,0===a&&_d(e,"breakStart"),Ud(e);break}}n&&!e.g&&(t=e.h.currentTime,e.A&&e.A>t&&(e.h.currentTime=e.A),e.A=null)}}}function Od(e){if(e.g){for(;e.B.lastChild;)e.B.removeChild(e.B.firstChild);e.I||e.M.push(e.C.adId);var t=e.g.m;_d(e,void 0!==t&&t?"skip":"complete");for(var n=(t=l(e.m)).next();!n.done;n=t.next())n=n.value,e.o.cb(n.target,n.type,n.listener);e.m=[],e.s=[],(t=e.g.getPositionInSequence())===(n=e.g.getSequenceLength())&&_d(e,"breakEnd"),e.g=null,e.C=null,e.L=null}}function Ud(e){var t=!1;e.h.paused?t=!0:(_d(e,"impression"),_d(e,"start")),e.m.push({target:e.h,type:"volumechange",listener:function(){e.h.muted&&_d(e,"mute")}}),e.m.push({target:e.h,type:"volumechange",listener:function(){e.h.muted||_d(e,"unmute")}}),e.m.push({target:e.h,type:"play",listener:function(){t?(_d(e,"impression"),_d(e,"start"),t=!1):_d(e,"resume")}}),e.m.push({target:e.h,type:"pause",listener:function(){_d(e,"pause")}});for(var n=l(e.m),i=n.next();!i.done;i=n.next())i=i.value,e.o.D(i.target,i.type,i.listener)}function _d(e,t){var n=e.C.trackingEvents.find((function(e){return e.eventType==t}));if(n||(n=e.L.adBreakTrackingEvents.find((function(e){return e.eventType==t}))),n)for(var i={type:10},r=(n=l(n.beaconUrls)).next();!r.done;r=n.next())(r=r.value)&&""!=r&&((r=aa([r],{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4})).method="POST",e.K.request(7,r,i));switch(t){case"impression":e.i(new Jr("ad-impression"));break;case"start":e.i(new Jr("ad-started",(new Map).set("ad",e.g)));break;case"mute":e.i(new Jr("ad-muted"));break;case"unmute":e.i(new Jr("ad-volume-changed"));break;case"resume":e.i(new Jr("ad-resumed"));break;case"pause":e.i(new Jr("ad-paused"));break;case"firstQuartile":e.i(new Jr("ad-first-quartile"));break;case"midpoint":e.i(new Jr("ad-midpoint"));break;case"thirdQuartile":e.i(new Jr("ad-third-quartile"));break;case"complete":e.i(new Jr("ad-complete")),e.i(new Jr("ad-stopped"));break;case"skip":e.i(new Jr("ad-skipped")),e.i(new Jr("ad-stopped"));break;case"breakStart":e.B.setAttribute("ad-active","true");break;case"breakEnd":e.B.removeAttribute("ad-active");break;case"skipStateChanged":e.i(new Jr("ad-skip-state-changed"))}}function Bd(e,t){this.g=e,this.i=null,this.h=t}function Fd(e,t,n,i){var r=this;this.s=e,this.l=t,this.j=null,this.F=NaN,this.i=i,this.G=!1,this.A=this.m=this.o=null,this.B="",this.C=[],this.h=new Z,(e=new google.ima.dai.api.UiSettings).setLocale(n),this.g=new google.ima.dai.api.StreamManager(this.l,this.s,e),this.i(new Jr("ima-stream-manager-loaded",(new Map).set("imaStreamManager",this.g))),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.LOADED,(function(e){!function(e,t){e.i(new Jr("ads-loaded",(new Map).set("loadTime",Date.now()/1e3-e.F))),t=t.getStreamData().url,e.j.resolve(t),e.j=null,e.G||e.h.D(e.l,"seeked",(function(){var t=e.l.currentTime;if(0!=t){e.g.streamTimeForContentTime(t);var n=e.g.previousCuePointForStreamTime(t);n&&!n.played&&(e.o=t,e.l.currentTime=n.start)}}))}(r,e)})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.ERROR,(function(){r.B.length?r.j.resolve(r.B):r.j.reject("IMA Stream request returned an error and there was no backup asset uri provided."),r.j=null})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.AD_BREAK_STARTED,(function(){})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.STARTED,(function(e){e=e.getAd(),r.m=new Bd(e,r.l),r.A&&(r.m.i=r.A),r.i(new Jr("ad-started",(new Map).set("ad",r.m))),r.s.setAttribute("ad-active","true")})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.AD_BREAK_ENDED,(function(){r.s.removeAttribute("ad-active");var e=r.l.currentTime;r.o&&r.o>e&&(r.l.currentTime=r.o,r.o=null)})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.AD_PROGRESS,(function(e){r.A=e.getStreamData().adProgressData,r.m&&(r.m.i=r.A)})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.FIRST_QUARTILE,(function(){r.i(new Jr("ad-first-quartile"))})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.MIDPOINT,(function(){r.i(new Jr("ad-midpoint"))})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.THIRD_QUARTILE,(function(){r.i(new Jr("ad-third-quartile"))})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.COMPLETE,(function(){r.i(new Jr("ad-complete")),r.i(new Jr("ad-stopped")),r.s.removeAttribute("ad-active"),r.m=null})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.SKIPPED,(function(){r.i(new Jr("ad-skipped")),r.i(new Jr("ad-stopped"))})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.CUEPOINTS_CHANGED,(function(e){var t=e.getStreamData();e=[];for(var n=(t=l(t.cuepoints)).next();!n.done;n=t.next())n=n.value,e.push({start:n.start,end:n.end});r.C=e,r.i(new Jr("ad-cue-points-changed",(new Map).set("cuepoints",e)))}))}function Vd(){Zr.call(this),this.g=this.i=this.j=this.h=null,this.m=new dd,this.o=navigator.language,this.l=null}function Hd(e,t){if(t&&t.type)switch(t.type){case"ads-loaded":e.m.g.push(t.loadTime);break;case"ad-started":e.m.h++;break;case"ad-complete":e.m.j++;break;case"ad-skipped":e.m.l++;break;case"ad-error":e.m.i++}e.dispatchEvent(t)}function Gd(e){return JSON.stringify(e,(function(e,t){if("function"!=typeof t){if(t instanceof Event||t instanceof Jr){var n={};for(i in t)(e=t[i])&&"object"==typeof e?"detail"==i&&(n[i]=e):i in Event||(n[i]=e);return n}if(t instanceof Error){var i=new Set(["name","message","stack"]);for(n in t)i.add(n);for(e=(n=l(Object.getOwnPropertyNames(t))).next();!e.done;e=n.next())i.add(e.value);for(n={},e=(i=l(i)).next();!e.done;e=i.next())n[e=e.value]=t[e];t={__type__:"Error",contents:n}}else if(t instanceof TimeRanges){for(i={__type__:"TimeRanges",length:t.length,start:[],end:[]},n=(t=l(Eo(t))).next();!n.done;n=t.next())e=(n=n.value).end,i.start.push(n.start),i.end.push(e);t=i}else t=ArrayBuffer.isView(t)&&1===t.BYTES_PER_ELEMENT?{__type__:"Uint8Array",entries:Array.from(t)}:"number"==typeof t?isNaN(t)?"NaN":isFinite(t)?t:0>t?"-Infinity":"Infinity":t;return t}}))}function Kd(e){return JSON.parse(e,(function(e,t){if("NaN"==t)var n=NaN;else if("-Infinity"==t)n=-1/0;else if("Infinity"==t)n=1/0;else if(t&&"object"==typeof t&&"TimeRanges"==t.__type__)n=function(e){return{length:e.length,start:function(t){return e.start[t]},end:function(t){return e.end[t]}}}(t);else if(t&&"object"==typeof t&&"Uint8Array"==t.__type__)n=new Uint8Array(t.entries);else if(t&&"object"==typeof t&&"Error"==t.__type__){for(n in e=t.contents,t=Error(e.message),e)t[n]=e[n];n=t}else n=t;return n}))}(i=fd.prototype).needsSkipUI=function(){return!1},i.isClientRendering=function(){return!0},i.isUsingAnotherMediaElement=function(){return!0},i.getDuration=function(){return this.g.getDuration()},i.getMinSuggestedDuration=function(){return this.g.getMinSuggestedDuration()},i.getRemainingTime=function(){return this.h.getRemainingTime()},i.isPaused=function(){return this.i},i.isSkippable=function(){return 0<=this.g.getSkipTimeOffset()},i.getTimeUntilSkippable=function(){var e=this.g.getSkipTimeOffset();return e=this.getRemainingTime()-e,Math.max(e,0)},i.canSkipNow=function(){return this.h.getAdSkippableState()},i.skip=function(){return this.h.skip()},i.pause=function(){return this.h.pause()},i.play=function(){return this.h.resume()},i.getVolume=function(){return this.h.getVolume()},i.setVolume=function(e){return this.j.volume=e,this.h.setVolume(e)},i.isMuted=function(){return 0==this.h.getVolume()},i.isLinear=function(){return this.g.isLinear()},i.resize=function(e,t){var n=!1,i=this.j;document.fullscreenEnabled?n=!!document.fullscreenElement:i.webkitSupportsFullscreen&&(n=i.webkitDisplayingFullscreen),this.h.resize(e,t,n?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)},i.setMuted=function(e){(this.j.muted=e)?(this.l=this.getVolume(),this.h.setVolume(0)):this.h.setVolume(this.l)},i.getSequenceLength=function(){var e=this.g.getAdPodInfo();return null==e?1:e.getTotalAds()},i.getPositionInSequence=function(){var e=this.g.getAdPodInfo();return null==e?1:e.getAdPosition()},i.getTitle=function(){return this.g.getTitle()},i.getDescription=function(){return this.g.getDescription()},i.getVastMediaBitrate=function(){return this.g.getVastMediaBitrate()},i.getVastMediaHeight=function(){return this.g.getVastMediaHeight()},i.getVastMediaWidth=function(){return this.g.getVastMediaWidth()},i.getAdId=function(){return this.g.getAdId()},i.getCreativeAdId=function(){return this.g.getCreativeAdId()},i.getAdvertiserName=function(){return this.g.getAdvertiserName()},i.getMediaUrl=function(){return this.g.getMediaUrl()},i.getTimeOffset=function(){var e=this.g.getAdPodInfo();return null==e?0:e.getTimeOffset()},i.getPodIndex=function(){var e=this.g.getAdPodInfo();return null==e?0:e.getPodIndex()},i.release=function(){this.h=this.g=null},F("shaka.ads.ClientSideAd",fd),fd.prototype.release=fd.prototype.release,fd.prototype.getPodIndex=fd.prototype.getPodIndex,fd.prototype.getTimeOffset=fd.prototype.getTimeOffset,fd.prototype.getMediaUrl=fd.prototype.getMediaUrl,fd.prototype.getAdvertiserName=fd.prototype.getAdvertiserName,fd.prototype.getCreativeAdId=fd.prototype.getCreativeAdId,fd.prototype.getAdId=fd.prototype.getAdId,fd.prototype.getVastMediaWidth=fd.prototype.getVastMediaWidth,fd.prototype.getVastMediaHeight=fd.prototype.getVastMediaHeight,fd.prototype.getVastMediaBitrate=fd.prototype.getVastMediaBitrate,fd.prototype.getDescription=fd.prototype.getDescription,fd.prototype.getTitle=fd.prototype.getTitle,fd.prototype.getPositionInSequence=fd.prototype.getPositionInSequence,fd.prototype.getSequenceLength=fd.prototype.getSequenceLength,fd.prototype.setMuted=fd.prototype.setMuted,fd.prototype.resize=fd.prototype.resize,fd.prototype.isLinear=fd.prototype.isLinear,fd.prototype.isMuted=fd.prototype.isMuted,fd.prototype.setVolume=fd.prototype.setVolume,fd.prototype.getVolume=fd.prototype.getVolume,fd.prototype.play=fd.prototype.play,fd.prototype.pause=fd.prototype.pause,fd.prototype.skip=fd.prototype.skip,fd.prototype.canSkipNow=fd.prototype.canSkipNow,fd.prototype.getTimeUntilSkippable=fd.prototype.getTimeUntilSkippable,fd.prototype.isSkippable=fd.prototype.isSkippable,fd.prototype.isPaused=fd.prototype.isPaused,fd.prototype.getRemainingTime=fd.prototype.getRemainingTime,fd.prototype.getMinSuggestedDuration=fd.prototype.getMinSuggestedDuration,fd.prototype.getDuration=fd.prototype.getDuration,fd.prototype.isUsingAnotherMediaElement=fd.prototype.isUsingAnotherMediaElement,fd.prototype.isClientRendering=fd.prototype.isClientRendering,fd.prototype.needsSkipUI=fd.prototype.needsSkipUI,F("shaka.ads.Utils",pd),pd.ADS_LOADED="ads-loaded",pd.AD_STARTED="ad-started",pd.AD_FIRST_QUARTILE="ad-first-quartile",pd.AD_MIDPOINT="ad-midpoint",pd.AD_THIRD_QUARTILE="ad-third-quartile",pd.AD_COMPLETE="ad-complete",pd.AD_STOPPED="ad-stopped",pd.AD_SKIPPED="ad-skipped",pd.AD_VOLUME_CHANGED="ad-volume-changed",pd.AD_MUTED="ad-muted",pd.AD_PAUSED="ad-paused",pd.AD_RESUMED="ad-resumed",pd.AD_SKIP_STATE_CHANGED="ad-skip-state-changed",pd.CUEPOINTS_CHANGED="ad-cue-points-changed",pd.IMA_AD_MANAGER_LOADED="ima-ad-manager-loaded",pd.IMA_STREAM_MANAGER_LOADED="ima-stream-manager-loaded",pd.AD_CLICKED="ad-clicked",pd.AD_PROGRESS="ad-progress",pd.AD_BUFFERING="ad-buffering",pd.AD_IMPRESSION="ad-impression",pd.AD_DURATION_CHANGED="ad-duration-changed",pd.AD_CLOSED="ad-closed",pd.AD_LOADED="ad-loaded",pd.ALL_ADS_COMPLETED="all-ads-completed",pd.AD_LINEAR_CHANGED="ad-linear-changed",pd.AD_METADATA="ad-metadata",pd.AD_RECOVERABLE_ERROR="ad-recoverable-error",pd.AD_ERROR="ad-error",pd.AD_BREAK_READY="ad-break-ready",pd.AD_INTERACTION="ad-interaction",pd.AD_CONTENT_PAUSE_REQUESTED="ad-content-pause-requested",pd.AD_CONTENT_RESUME_REQUESTED="ad-content-resume-requested",pd.AD_CONTENT_ATTACH_REQUESTED="ad-content-attach-requested",md.prototype.configure=function(e){this.o=e},md.prototype.stop=function(){this.g&&this.g.stop(),this.s&&Mo(this.s)},md.prototype.release=function(){this.stop(),this.A&&this.A.disconnect(),this.h&&this.h.release(),this.g&&this.g.destroy(),this.m.destroy(),this.C.destroy()},(i=Td.prototype).needsSkipUI=function(){return!0},i.isClientRendering=function(){return!0},i.isUsingAnotherMediaElement=function(){return this.m},i.getDuration=function(){var e=this.g.duration;return isNaN(e)?-1:e},i.getMinSuggestedDuration=function(){return this.getDuration()},i.getRemainingTime=function(){var e=this.g.duration;return isNaN(e)?-1:e-this.g.currentTime},i.isPaused=function(){return this.g.paused},i.isSkippable=function(){return this.h&&null!=this.j?this.getDuration()-this.getRemainingTime()<this.i+this.j:this.h},i.getTimeUntilSkippable=function(){if(this.isSkippable()){var e=this.getRemainingTime()+this.i-this.getDuration();return Math.max(e,0)}return Math.max(this.getRemainingTime(),0)},i.canSkipNow=function(){return this.h&&0==this.getTimeUntilSkippable()},i.skip=function(){this.canSkipNow()&&this.o()},i.pause=function(){return this.g.pause()},i.play=function(){return this.g.play()},i.getVolume=function(){return this.g.volume},i.setVolume=function(e){this.g.volume=e},i.isMuted=function(){return this.g.muted},i.isLinear=function(){return!0},i.resize=function(){},i.setMuted=function(e){this.g.muted=e},i.getSequenceLength=function(){return this.s},i.getPositionInSequence=function(){return this.l},i.getTitle=function(){return""},i.getDescription=function(){return""},i.getVastMediaBitrate=function(){return 0},i.getVastMediaHeight=function(){return 0},i.getVastMediaWidth=function(){return 0},i.getAdId=function(){return""},i.getCreativeAdId=function(){return""},i.getAdvertiserName=function(){return""},i.getMediaUrl=function(){return null},i.getTimeOffset=function(){return 0},i.getPodIndex=function(){return 0},i.release=function(){this.g=null},F("shaka.ads.InterstitialAd",Td),Td.prototype.release=Td.prototype.release,Td.prototype.getPodIndex=Td.prototype.getPodIndex,Td.prototype.getTimeOffset=Td.prototype.getTimeOffset,Td.prototype.getMediaUrl=Td.prototype.getMediaUrl,Td.prototype.getAdvertiserName=Td.prototype.getAdvertiserName,Td.prototype.getCreativeAdId=Td.prototype.getCreativeAdId,Td.prototype.getAdId=Td.prototype.getAdId,Td.prototype.getVastMediaWidth=Td.prototype.getVastMediaWidth,Td.prototype.getVastMediaHeight=Td.prototype.getVastMediaHeight,Td.prototype.getVastMediaBitrate=Td.prototype.getVastMediaBitrate,Td.prototype.getDescription=Td.prototype.getDescription,Td.prototype.getTitle=Td.prototype.getTitle,Td.prototype.getPositionInSequence=Td.prototype.getPositionInSequence,Td.prototype.getSequenceLength=Td.prototype.getSequenceLength,Td.prototype.setMuted=Td.prototype.setMuted,Td.prototype.resize=Td.prototype.resize,Td.prototype.isLinear=Td.prototype.isLinear,Td.prototype.isMuted=Td.prototype.isMuted,Td.prototype.setVolume=Td.prototype.setVolume,Td.prototype.getVolume=Td.prototype.getVolume,Td.prototype.play=Td.prototype.play,Td.prototype.pause=Td.prototype.pause,Td.prototype.skip=Td.prototype.skip,Td.prototype.canSkipNow=Td.prototype.canSkipNow,Td.prototype.getTimeUntilSkippable=Td.prototype.getTimeUntilSkippable,Td.prototype.isSkippable=Td.prototype.isSkippable,Td.prototype.isPaused=Td.prototype.isPaused,Td.prototype.getRemainingTime=Td.prototype.getRemainingTime,Td.prototype.getMinSuggestedDuration=Td.prototype.getMinSuggestedDuration,Td.prototype.getDuration=Td.prototype.getDuration,Td.prototype.isUsingAnotherMediaElement=Td.prototype.isUsingAnotherMediaElement,Td.prototype.isClientRendering=Td.prototype.isClientRendering,Td.prototype.needsSkipUI=Td.prototype.needsSkipUI,Sd.prototype.configure=function(e){this.M=e,xd(this)},Sd.prototype.stop=function(){this.j&&this.j.Va(),this.I.clear(),this.C.clear(),this.g.Te(),this.A.clear(),this.g.detach(),this.H=!1,this.m=this.l=null},Sd.prototype.release=function(){this.stop(),this.K&&this.K.release(),this.j&&this.j.release(),this.G&&Mo(this.G),this.L&&(this.L.stop(),this.L=null),this.O&&(this.O.stop(),this.O=null),this.g.destroy()},Sd.prototype.addAdUrlInterstitial=function(e){var t,n,i,r,a,o,s,u,d,h=this;return P((function(f){switch(f.g){case 1:return w(f,Cd(h,e,t={type:12}),2);case 2:if(n=f.h,!(i=Ct(n,"VAST,vmap:VMAP")))throw new De(2,10,10007);if(r=[],"VAST"==i.tagName){r=gd(i,h.l),f.u(3);break}if("vmap:VMAP"!=i.tagName){f.u(3);break}for(var p=[],g=l(Nt(i,"vmap:AdBreak")),m=g.next();!m.done;m=g.next()){var v=m.value,y=v.attributes.timeOffset;y&&(m=null,m="start"==y?0:"end"==y?1/0:At(y),(v=_t(v,"vmap:AdSource"))&&(v=_t(v,"vmap:AdTagURI"))&&(v=jt(v))&&p.push({time:m,uri:v}))}a=l(p),o=a.next();case 5:if(o.done){f.u(3);break}return s=o.value,w(f,Cd(h,s.uri,t),8);case 8:if(u=f.h,!(d=Ct(u,"VAST")))throw new De(2,10,10007);r.push.apply(r,c(gd(d,s.time))),o=a.next(),f.u(5);break;case 3:Ad(h,r),T(f)}}))},(i=Dd.prototype).needsSkipUI=function(){return!0},i.isClientRendering=function(){return!1},i.isUsingAnotherMediaElement=function(){return!1},i.getDuration=function(){return this.h.durationInSeconds},i.getMinSuggestedDuration=function(){return this.getDuration()},i.getRemainingTime=function(){return this.h.startTimeInSeconds+this.h.durationInSeconds-this.g.currentTime},i.isPaused=function(){return this.g.paused},i.isSkippable=function(){return"number"==typeof this.j},i.getTimeUntilSkippable=function(){if("number"!=typeof this.j)return this.getRemainingTime();var e=this.getRemainingTime()+this.j-this.getDuration();return Math.max(e,0)},i.canSkipNow=function(){return 0==this.getTimeUntilSkippable()},i.skip=function(){this.m=!0,this.g.currentTime+=this.getRemainingTime()},i.pause=function(){return this.g.pause()},i.play=function(){return this.g.play()},i.getVolume=function(){return this.g.volume},i.setVolume=function(e){this.g.volume=e},i.isMuted=function(){return this.g.muted},i.isLinear=function(){return this.o},i.resize=function(){},i.setMuted=function(e){this.g.muted=e},i.getSequenceLength=function(){return this.l?this.l:1},i.getPositionInSequence=function(){return this.i?this.i:1},i.getTitle=function(){return this.h.adTitle},i.getDescription=function(){return""},i.getVastMediaBitrate=function(){return 0},i.getVastMediaHeight=function(){return 0},i.getVastMediaWidth=function(){return 0},i.getAdId=function(){return this.h.adId},i.getCreativeAdId=function(){return this.h.creativeId},i.getAdvertiserName=function(){return""},i.getMediaUrl=function(){return null},i.getTimeOffset=function(){return 0},i.getPodIndex=function(){return 0},i.release=function(){this.l=this.i=this.g=this.h=null},F("shaka.ads.MediaTailorAd",Dd),Dd.prototype.release=Dd.prototype.release,Dd.prototype.getPodIndex=Dd.prototype.getPodIndex,Dd.prototype.getTimeOffset=Dd.prototype.getTimeOffset,Dd.prototype.getMediaUrl=Dd.prototype.getMediaUrl,Dd.prototype.getAdvertiserName=Dd.prototype.getAdvertiserName,Dd.prototype.getCreativeAdId=Dd.prototype.getCreativeAdId,Dd.prototype.getAdId=Dd.prototype.getAdId,Dd.prototype.getVastMediaWidth=Dd.prototype.getVastMediaWidth,Dd.prototype.getVastMediaHeight=Dd.prototype.getVastMediaHeight,Dd.prototype.getVastMediaBitrate=Dd.prototype.getVastMediaBitrate,Dd.prototype.getDescription=Dd.prototype.getDescription,Dd.prototype.getTitle=Dd.prototype.getTitle,Dd.prototype.getPositionInSequence=Dd.prototype.getPositionInSequence,Dd.prototype.getSequenceLength=Dd.prototype.getSequenceLength,Dd.prototype.setMuted=Dd.prototype.setMuted,Dd.prototype.resize=Dd.prototype.resize,Dd.prototype.isLinear=Dd.prototype.isLinear,Dd.prototype.isMuted=Dd.prototype.isMuted,Dd.prototype.setVolume=Dd.prototype.setVolume,Dd.prototype.getVolume=Dd.prototype.getVolume,Dd.prototype.play=Dd.prototype.play,Dd.prototype.pause=Dd.prototype.pause,Dd.prototype.skip=Dd.prototype.skip,Dd.prototype.canSkipNow=Dd.prototype.canSkipNow,Dd.prototype.getTimeUntilSkippable=Dd.prototype.getTimeUntilSkippable,Dd.prototype.isSkippable=Dd.prototype.isSkippable,Dd.prototype.isPaused=Dd.prototype.isPaused,Dd.prototype.getRemainingTime=Dd.prototype.getRemainingTime,Dd.prototype.getMinSuggestedDuration=Dd.prototype.getMinSuggestedDuration,Dd.prototype.getDuration=Dd.prototype.getDuration,Dd.prototype.isUsingAnotherMediaElement=Dd.prototype.isUsingAnotherMediaElement,Dd.prototype.isClientRendering=Dd.prototype.isClientRendering,Dd.prototype.needsSkipUI=Dd.prototype.needsSkipUI,Rd.prototype.stop=function(){for(var e=l(this.m),t=e.next();!t.done;t=e.next())t=t.value,this.o.cb(t.target,t.type,t.listener);Od(this),this.m=[],this.s=[],this.G="",this.O=!0,this.H="",this.A=null,this.j=[],this.M=[],this.F.clear()},Rd.prototype.release=function(){this.stop(),this.o&&this.o.release()},Rd.prototype.onManifestUpdated=function(e){this.I=e,""!=this.G&&(function(e,t,n){var i,r,a,o,s,u,c,d,h,f,p,g,m,v,y,b;P((function(x){if(1==x.g)return i={type:8},r=aa([t],{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4}),a=e.K.request(7,r,i),S(x,2),w(x,a.promise,4);if(2!=x.g){if(o=x.h,s=[],u=dt(o.data),0<(c=JSON.parse(u)).avails.length){if(JSON.stringify(e.j)!=JSON.stringify(c.avails)){for(e.j=c.avails,d=l(e.j),h=d.next();!h.done;h=d.next())for(f=h.value,p=l(f.nonLinearAdsList),g=p.next();!g.done;g=p.next())for(m=g.value,v=l(m.nonLinearAdList),y=v.next();!y.done;y=v.next())b=y.value,Pd(e,b);s=e.getCuePoints(),e.i(new Jr("ad-cue-points-changed",(new Map).set("cuepoints",s)))}}else e.j.length&&e.i(new Jr("ad-cue-points-changed",(new Map).set("cuepoints",s))),Od(e),e.j=[];return n&&(e.I||0<s.length)&&function(e){jd(e),e.I||(Nd(e),e.o.D(e.h,"seeked",(function(){Nd(e)})),e.o.D(e.h,"ended",(function(){Od(e)}))),e.o.D(e.h,"timeupdate",(function(){jd(e)}))}(e),A(x,0)}E(x),T(x)}))}(this,this.G,this.O),this.O=!1)},Rd.prototype.getCuePoints=function(){for(var e=[],t=l(this.j),n=t.next();!n.done;n=t.next())for(var i=(n=l(n.value.ads)).next();!i.done;i=n.next())i=i.value,e.push({start:i.startTimeInSeconds,end:i.startTimeInSeconds+i.durationInSeconds});return e},(i=Bd.prototype).needsSkipUI=function(){return!0},i.isClientRendering=function(){return!1},i.isUsingAnotherMediaElement=function(){return!1},i.getDuration=function(){return this.i?this.i.duration:-1},i.getMinSuggestedDuration=function(){return this.getDuration()},i.getRemainingTime=function(){return this.i?this.i.duration-this.i.currentTime:-1},i.isPaused=function(){return this.h.paused},i.isSkippable=function(){return this.g.isSkippable()},i.getTimeUntilSkippable=function(){var e=this.g.getSkipTimeOffset();return e=this.getRemainingTime()-e,Math.max(e,0)},i.canSkipNow=function(){return 0==this.getTimeUntilSkippable()},i.skip=function(){this.h.currentTime+=this.getRemainingTime()},i.pause=function(){return this.h.pause()},i.play=function(){return this.h.play()},i.getVolume=function(){return this.h.volume},i.setVolume=function(e){this.h.volume=e},i.isMuted=function(){return this.h.muted},i.isLinear=function(){return!0},i.resize=function(){},i.setMuted=function(e){this.h.muted=e},i.getSequenceLength=function(){var e=this.g.getAdPodInfo();return null==e?1:e.getTotalAds()},i.getPositionInSequence=function(){var e=this.g.getAdPodInfo();return null==e?1:e.getAdPosition()},i.getTitle=function(){return this.g.getTitle()},i.getDescription=function(){return this.g.getDescription()},i.getVastMediaBitrate=function(){return 0},i.getVastMediaHeight=function(){return this.g.getVastMediaHeight()},i.getVastMediaWidth=function(){return this.g.getVastMediaWidth()},i.getAdId=function(){return this.g.getAdId()},i.getCreativeAdId=function(){return this.g.getCreativeAdId()},i.getAdvertiserName=function(){return this.g.getAdvertiserName()},i.getMediaUrl=function(){return null},i.getTimeOffset=function(){var e=this.g.getAdPodInfo();return null==e?0:e.getTimeOffset()},i.getPodIndex=function(){var e=this.g.getAdPodInfo();return null==e?0:e.getPodIndex()},i.release=function(){this.h=this.i=this.g=null},F("shaka.ads.ServerSideAd",Bd),Bd.prototype.release=Bd.prototype.release,Bd.prototype.getPodIndex=Bd.prototype.getPodIndex,Bd.prototype.getTimeOffset=Bd.prototype.getTimeOffset,Bd.prototype.getMediaUrl=Bd.prototype.getMediaUrl,Bd.prototype.getAdvertiserName=Bd.prototype.getAdvertiserName,Bd.prototype.getCreativeAdId=Bd.prototype.getCreativeAdId,Bd.prototype.getAdId=Bd.prototype.getAdId,Bd.prototype.getVastMediaWidth=Bd.prototype.getVastMediaWidth,Bd.prototype.getVastMediaHeight=Bd.prototype.getVastMediaHeight,Bd.prototype.getVastMediaBitrate=Bd.prototype.getVastMediaBitrate,Bd.prototype.getDescription=Bd.prototype.getDescription,Bd.prototype.getTitle=Bd.prototype.getTitle,Bd.prototype.getPositionInSequence=Bd.prototype.getPositionInSequence,Bd.prototype.getSequenceLength=Bd.prototype.getSequenceLength,Bd.prototype.setMuted=Bd.prototype.setMuted,Bd.prototype.resize=Bd.prototype.resize,Bd.prototype.isLinear=Bd.prototype.isLinear,Bd.prototype.isMuted=Bd.prototype.isMuted,Bd.prototype.setVolume=Bd.prototype.setVolume,Bd.prototype.getVolume=Bd.prototype.getVolume,Bd.prototype.play=Bd.prototype.play,Bd.prototype.pause=Bd.prototype.pause,Bd.prototype.skip=Bd.prototype.skip,Bd.prototype.canSkipNow=Bd.prototype.canSkipNow,Bd.prototype.getTimeUntilSkippable=Bd.prototype.getTimeUntilSkippable,Bd.prototype.isSkippable=Bd.prototype.isSkippable,Bd.prototype.isPaused=Bd.prototype.isPaused,Bd.prototype.getRemainingTime=Bd.prototype.getRemainingTime,Bd.prototype.getMinSuggestedDuration=Bd.prototype.getMinSuggestedDuration,Bd.prototype.getDuration=Bd.prototype.getDuration,Bd.prototype.isUsingAnotherMediaElement=Bd.prototype.isUsingAnotherMediaElement,Bd.prototype.isClientRendering=Bd.prototype.isClientRendering,Bd.prototype.needsSkipUI=Bd.prototype.needsSkipUI,(i=Fd.prototype).configure=function(){},i.stop=function(){this.B="",this.o=null,this.C=[]},i.release=function(){this.stop(),this.h&&this.h.release()},i.onCueMetadataChange=function(e){if(e.key&&e.data){var t={};t[e.key]=e.data,this.g.onTimedMetadata(t)}},i.getCuePoints=function(){return this.C},m(Vd,Zr),(i=Vd.prototype).setLocale=function(e){this.o=e},i.configure=function(e){this.l=e,this.h&&this.h.configure(this.l),this.j&&this.j.configure(this.l),this.g&&this.g.configure(this.l)},i.initInterstitial=function(e,t,n){var i=this;this.h&&this.h.release(),this.h=new Sd(e,t,n,(function(e){return Hd(i,e)})),this.h.configure(this.l)},i.initClientSide=function(t,n,i){var r=this;if(!e.google||!google.ima||!google.ima.AdsLoader)throw new De(2,10,1e4);this.j&&this.j.release(),this.j=new md(t,n,this.o,i,(function(e){return Hd(r,e)})),this.j.configure(this.l)},i.release=function(){this.h&&(this.h.release(),this.h=null),this.j&&(this.j.release(),this.j=null),this.i&&(this.i.release(),this.i=null),this.g&&(this.g.release(),this.g=null),Zr.prototype.release.call(this)},i.onAssetUnload=function(){this.h&&this.h.stop(),this.j&&this.j.stop(),this.i&&this.i.stop(),this.g&&this.g.stop(),this.dispatchEvent(new Jr("ad-stopped")),this.dispatchEvent(new Jr("ad-content-attach-requested")),this.m=new dd},i.requestClientSideAds=function(e){if(!this.j)throw new De(1,10,10001);var t=this.j;t.g&&t.g.destroy(),t.m&&t.m.contentComplete(),t.G=Date.now()/1e3,t.m.requestAds(e)},i.updateClientSideAdsRenderingSettings=function(e){if(!this.j)throw new De(1,10,10001);var t=this.j;t.B=e,t.g&&t.g.updateAdsRenderingSettings(t.B)},i.initMediaTailor=function(e,t,n){var i=this;this.i&&this.i.release(),this.i=new Rd(e,t,n,(function(e){return Hd(i,e)}))},i.requestMediaTailorStream=function(e,t,n){if(!this.i)throw new De(1,10,10005);var i=this.i;return n=void 0===n?"":n,i.l?e=Promise.reject(new De(1,10,10004)):(i.l=new Gr,function(e,t,n){var i,r,a,o,s,u,l,c,d,h,f,p;P((function(g){if(1==g.g)return i={type:7},(r=aa([t],{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4})).method="POST",n&&(a=JSON.stringify(n),r.body=pt(a)),o=e.K.request(7,r,i),S(g,2),w(g,o.promise,4);if(2!=g.g){if(s=g.h,u=dt(s.data),!(l=JSON.parse(u)).manifestUrl||!l.trackingUrl)throw Error("Insufficient data from MediaTailor.");return c=new Gn(t),d=new Gn(l.trackingUrl),e.G=c.resolve(d).toString(),h=Date.now()/1e3,f=h-e.S,e.i(new Jr("ads-loaded",(new Map).set("loadTime",f))),p=new Gn(l.manifestUrl),e.l.resolve(c.resolve(p).toString()),e.l=null,A(g,0)}if(E(g),!e.H.length)return e.l.reject("MediaTailor request returned an error and there was no backup asset uri provided."),e.l=null,g.return();e.l.resolve(e.H),e.l=null,T(g)}))}(i,e,t),i.H=n||"",i.S=Date.now()/1e3,e=i.l),e},i.addMediaTailorTrackingUrl=function(e){if(!this.i)throw new De(1,10,10005);var t=this.i;t.G=e,t.i(new Jr("ads-loaded",(new Map).set("loadTime",0)))},i.initServerSide=function(t,n){var i=this;if(!e.google||!google.ima||!google.ima.dai)throw new De(2,10,10002);this.g&&this.g.release(),this.g=new Fd(t,n,this.o,(function(e){return Hd(i,e)})),this.g.configure(this.l)},i.requestServerSideStream=function(e,t){if(t=void 0===t?"":t,!this.g)throw new De(1,10,10003);e.adTagParameters||(e.adTagParameters={});var n=e.adTagParameters;return(n.mpt||n.mpv)&&W('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.'),e.adTagParameters.mpt="shaka-player",e.adTagParameters.mpv="v4.12.5",(n=this.g).j?e=Promise.reject(new De(1,10,10004)):(e instanceof google.ima.dai.api.LiveStreamRequest&&(n.G=!0),n.j=new Gr,n.g.requestStream(e),n.B=t||"",n.F=Date.now()/1e3,e=n.j),e},i.replaceServerSideAdTagParameters=function(e){if(!this.g)throw new De(1,10,10003);(e.mpt||e.mpv)&&W('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.'),e.mpt="Shaka Player",e.mpv="v4.12.5",this.g.g.replaceAdTagParameters(e)},i.getServerSideCuePoints=function(){return oe("AdManager.getServerSideCuePoints","Please use getCuePoints function."),this.getCuePoints()},i.getCuePoints=function(){var e=[];return this.g&&(e=e.concat(this.g.getCuePoints())),this.i&&(e=e.concat(this.i.getCuePoints())),e},i.getStats=function(){var e=this.m;return{loadTimes:e.g,averageLoadTime:hd(e),started:e.h,playedCompletely:e.j,skipped:e.l,errors:e.i}},i.onManifestUpdated=function(e){this.i&&this.i.onManifestUpdated(e)},i.onDashTimedMetadata=function(e){this.g&&"urn:google:dai:2018"==e.schemeIdUri&&this.g.g.processMetadata(e.schemeIdUri,e.eventNode?e.eventNode.attributes.messageData:null,e.startTime)},i.onHlsTimedMetadata=function(e,t){this.g&&this.g.g.processMetadata("ID3",e.data,t)},i.onCueMetadataChange=function(e){this.g&&this.g.onCueMetadataChange(e)},i.onHLSInterstitialMetadata=function(e,t,n){this.l&&this.l.disableHLSInterstitial||(this.h||this.initInterstitial(null,e,t),this.h&&function(e,t){var n;P((function(i){if(1==i.g)return Md(e),w(i,function(e,t){var n,i,r,a,o,s,u,l,c,d,h,f,p,g,m,v,y,b,T,x,k,I,M,C,D,R,L,N,j,O,U,_,B,F,V,H,G,K,X,q,z;return P((function(P){switch(P.g){case 1:if(n=[],!t)return P.return(n);if(i=t.values.find((function(e){return"X-ASSET-URI"==e.key})),r=t.values.find((function(e){return"X-ASSET-LIST"==e.key})),!i&&!r)return P.return(n);if(a=null,(o=t.values.find((function(e){return"ID"==e.key})))&&(a=o.data),s=null==a?Math.floor(10*t.startTime)/10:t.startTime,(u=t.endTime)&&1/0!=t.endTime&&"number"==typeof t.endTime&&(u=null==a?Math.floor(10*t.endTime)/10:t.endTime),l=t.values.find((function(e){return"X-RESTRICT"==e.key})),d=c=!0,l&&l.data&&(h=l.data,c=!h.includes("SKIP"),d=!h.includes("JUMP")),f=c?0:null,(p=t.values.find((function(e){return"X-ENABLE-SKIP-AFTER"==e.key})))&&(g=p.data,f=parseFloat(g),isNaN(f)&&(f=c?0:null)),m=null,(v=t.values.find((function(e){return"X-ENABLE-SKIP-FOR"==e.key})))&&(y=v.data,m=parseFloat(y),isNaN(f)&&(m=null)),b=null,(T=t.values.find((function(e){return"X-RESUME-OFFSET"==e.key})))&&(x=T.data,b=parseFloat(x),isNaN(b)&&(b=null)),k=null,(I=t.values.find((function(e){return"X-PLAYOUT-LIMIT"==e.key})))&&(M=I.data,k=parseFloat(M),isNaN(k)&&(k=null)),R=D=C=!1,(L=t.values.find((function(e){return"CUE"==e.key})))&&(N=L.data,C=N.includes("ONCE"),D=N.includes("PRE"),R=N.includes("POST")),j=!1,(O=t.values.find((function(e){return"X-TIMELINE-OCCUPIES"==e.key})))?(U=O.data,j=U.includes("RANGE")):!T&&e.B.U()&&(j=!D&&!R),i){if(!(_=i.data))return P.return(n);n.push({id:a,startTime:s,endTime:u,uri:_,mimeType:null,isSkippable:c,skipOffset:f,skipFor:m,canJump:d,resumeOffset:b,playoutLimit:k,once:C,pre:D,post:R,timelineRange:j}),P.u(2);break}if(!r){P.u(2);break}return(B=r.data)?(S(P,4),w(P,Cd(e,B,{type:11}),6)):P.return(n);case 6:for(F=P.h,V=dt(F),H=JSON.parse(V),(G=H["SKIP-CONTROL"])&&("number"==typeof(K=G["ENABLE-SKIP-AFTER"])&&(f=parseFloat(K),isNaN(K)&&(f=c?0:null)),"number"==typeof(X=G["ENABLE-SKIP-FOR"])&&(m=parseFloat(X),isNaN(X)&&(m=null))),q=0;q<H.ASSETS.length;q++)(z=H.ASSETS[q]).URI&&n.push({id:a+"_asset_"+q,startTime:s,endTime:u,uri:z.URI,mimeType:null,isSkippable:c,skipOffset:f,skipFor:m,canJump:d,resumeOffset:b,playoutLimit:k,once:C,pre:D,post:R,timelineRange:j});A(P,2);break;case 4:E(P);case 2:return P.return(n)}}))}(e,t),2);(n=i.h).length?Ad(e,n):W("Unsupported HLS interstitial",t),T(i)}))}(this.h,n))},i.onDASHInterstitialMetadata=function(e,t,n){if(!(this.l&&this.l.disableDASHInterstitial||"urn:mpeg:dash:event:alternativeMPD:2022"!=n.schemeIdUri)&&(this.h||this.initInterstitial(null,e,t),this.h)){e=this.h;for(var i=(t=l(n.eventNode.children)).next();!i.done;i=t.next()){var r=i.value;if("AlternativeMPD"==r.tagName&&(i=r.attributes.uri,r=r.attributes.mode,i)){var a=i,o=r;break}}a?(t="replace"==o,o="insert"==o,(t||o)&&Ad(e,[{id:n.id,startTime:n.startTime,endTime:n.endTime,uri:a,mimeType:null,isSkippable:!1,skipOffset:null,skipFor:null,canJump:!0,resumeOffset:o?0:null,playoutLimit:null,once:!1,pre:!1,post:!1,timelineRange:t&&!o}])):W("Unsupported MPD alternate",n)}},i.addCustomInterstitial=function(e){if(!this.h)throw new De(1,10,10006);Ad(this.h,[e])},i.addAdUrlInterstitial=function(e){if(!this.h)throw new De(1,10,10006);return this.h.addAdUrlInterstitial(e)},F("shaka.ads.AdManager",Vd),Vd.prototype.addAdUrlInterstitial=Vd.prototype.addAdUrlInterstitial,Vd.prototype.addCustomInterstitial=Vd.prototype.addCustomInterstitial,Vd.prototype.onDASHInterstitialMetadata=Vd.prototype.onDASHInterstitialMetadata,Vd.prototype.onHLSInterstitialMetadata=Vd.prototype.onHLSInterstitialMetadata,Vd.prototype.onCueMetadataChange=Vd.prototype.onCueMetadataChange,Vd.prototype.onHlsTimedMetadata=Vd.prototype.onHlsTimedMetadata,Vd.prototype.onDashTimedMetadata=Vd.prototype.onDashTimedMetadata,Vd.prototype.onManifestUpdated=Vd.prototype.onManifestUpdated,Vd.prototype.getStats=Vd.prototype.getStats,Vd.prototype.getCuePoints=Vd.prototype.getCuePoints,Vd.prototype.getServerSideCuePoints=Vd.prototype.getServerSideCuePoints,Vd.prototype.replaceServerSideAdTagParameters=Vd.prototype.replaceServerSideAdTagParameters,Vd.prototype.requestServerSideStream=Vd.prototype.requestServerSideStream,Vd.prototype.initServerSide=Vd.prototype.initServerSide,Vd.prototype.addMediaTailorTrackingUrl=Vd.prototype.addMediaTailorTrackingUrl,Vd.prototype.requestMediaTailorStream=Vd.prototype.requestMediaTailorStream,Vd.prototype.initMediaTailor=Vd.prototype.initMediaTailor,Vd.prototype.updateClientSideAdsRenderingSettings=Vd.prototype.updateClientSideAdsRenderingSettings,Vd.prototype.requestClientSideAds=Vd.prototype.requestClientSideAds,Vd.prototype.onAssetUnload=Vd.prototype.onAssetUnload,Vd.prototype.release=Vd.prototype.release,Vd.prototype.initClientSide=Vd.prototype.initClientSide,Vd.prototype.initInterstitial=Vd.prototype.initInterstitial,Vd.prototype.configure=Vd.prototype.configure,Vd.prototype.setLocale=Vd.prototype.setLocale,Vd.ADS_LOADED="ads-loaded",Vd.AD_STARTED="ad-started",Vd.AD_FIRST_QUARTILE="ad-first-quartile",Vd.AD_MIDPOINT="ad-midpoint",Vd.AD_THIRD_QUARTILE="ad-third-quartile",Vd.AD_COMPLETE="ad-complete",Vd.AD_STOPPED="ad-stopped",Vd.AD_SKIPPED="ad-skipped",Vd.AD_VOLUME_CHANGED="ad-volume-changed",Vd.AD_MUTED="ad-muted",Vd.AD_PAUSED="ad-paused",Vd.AD_RESUMED="ad-resumed",Vd.AD_SKIP_STATE_CHANGED="ad-skip-state-changed",Vd.CUEPOINTS_CHANGED="ad-cue-points-changed",Vd.IMA_AD_MANAGER_LOADED="ima-ad-manager-loaded",Vd.IMA_STREAM_MANAGER_LOADED="ima-stream-manager-loaded",Vd.AD_CLICKED="ad-clicked",Vd.AD_PROGRESS="ad-progress",Vd.AD_BUFFERING="ad-buffering",Vd.AD_IMPRESSION="ad-impression",Vd.AD_DURATION_CHANGED="ad-duration-changed",Vd.AD_CLOSED="ad-closed",Vd.AD_LOADED="ad-loaded",Vd.ALL_ADS_COMPLETED="all-ads-completed",Vd.AD_LINEAR_CHANGED="ad-linear-changed",Vd.AD_METADATA="ad-metadata",Vd.AD_RECOVERABLE_ERROR="ad-recoverable-error",Vd.AD_ERROR="ad-error",Vd.AD_BREAK_READY="ad-break-ready",Vd.AD_INTERACTION="ad-interaction",Vd.AD_CONTENT_PAUSE_REQUESTED="ad-content-pause-requested",Vd.AD_CONTENT_RESUME_REQUESTED="ad-content-resume-requested",Vd.AD_CONTENT_ATTACH_REQUESTED="ad-content-attach-requested",cd=function(){return new Vd};var Xd="ended play playing pause pausing ratechange seeked seeking timeupdate volumechange".split(" "),qd="buffered currentTime duration ended loop muted paused playbackRate seeking videoHeight videoWidth volume".split(" "),zd=["loop","playbackRate"],Wd=["pause","play"],Yd={getAssetUri:2,getAudioLanguages:4,getAudioLanguagesAndRoles:4,getBufferFullness:1,getBufferedInfo:2,getExpiration:2,getKeyStatuses:2,getPlaybackRate:2,getTextLanguages:4,getTextLanguagesAndRoles:4,getImageTracks:2,getThumbnails:2,isAudioOnly:10,isBuffering:1,isInProgress:1,isLive:10,isTextTrackVisible:1,keySystem:10,seekRange:1,getLoadMode:10,getManifestType:10,isFullyLoaded:1},Jd={getConfiguration:4,getStats:5,getTextTracks:2,getVariantTracks:2},$d={getPlayheadTimeAsDate:1,getPresentationStartTimeAsDate:20,getSegmentAvailabilityDuration:20},Qd=[["getConfiguration","configure"]],Zd=[["isTextTrackVisible","setTextTrackVisibility"]],eh="addChaptersTrack addTextTrackAsync addThumbnailsTrack cancelTrickPlay configure getChapters getChaptersTracks resetConfiguration retryStreaming selectAudioLanguage selectTextLanguage selectTextTrack selectVariantTrack selectVariantsByLabel setTextTrackVisibility trickPlay updateStartTime goToLive".split(" "),th=["attach","attachCanvas","detach","load","unload"];function nh(e,t,n,i,r,a,o){var s=this;this.G=e,this.K=o,this.l=new Be(t),this.L=n,this.s=!1,this.A=i,this.F=r,this.M=a,this.h=this.m=!1,this.I="",this.o=null,this.B=function(){return oh(s)},this.C=function(e,t){switch((e=Kd(t)).type){case"event":var n=e.targetName,i=$r(e.event);s.A(n,i);break;case"update":for(i in n=e.update)for(var r in e=s.g[i]||{},n[i])e[r]=n[i][r];s.s&&(s.L(),s.s=!1);break;case"asyncComplete":if(i=e.id,r=e.error,e=s.i[i],delete s.i[i],e)if(r){for(n in i=new De(r.severity,r.category,r.code),r)i[n]=r[n];e.reject(i)}else e.resolve()}},this.g={video:{},player:{}},this.H=0,this.i={},this.j=null,fh.add(this)}function ih(e,t){var n=e.M();dh=t,t.addUpdateListener(e.B),t.addMessageListener("urn:x-cast:com.google.shaka.v2",e.C),oh(e),uh(e,{type:"init",initState:n,appData:e.o}),e.j.resolve()}function rh(e,t){var n=8003;switch(t.code){case"cancel":n=8004;break;case"timeout":n=8005;break;case"receiver_unavailable":n=8006}e.j.reject(new De(2,8,n,t))}function ah(e){var t=dh;t.removeUpdateListener(e.B),t.removeMessageListener("urn:x-cast:com.google.shaka.v2",e.C)}function oh(e){var t=!!dh&&"connected"==dh.status;if(e.h&&!t){for(var n in e.F(),e.g)e.g[n]={};sh(e)}e.h=t,e.I=t?dh.receiver.friendlyName:"",e.l.hc()}function sh(e){for(var t in e.i){var n=e.i[t];delete e.i[t],n.reject(new De(1,7,7e3))}}function uh(e,t){t=Gd(t);var n=dh;try{n.sendMessage("urn:x-cast:com.google.shaka.v2",t,(function(){}),J)}catch(i){throw t=new De(2,8,8005,i),n=new Jr("error",(new Map).set("detail",t)),e.A("player",n),e.Lc(),t}}(i=nh.prototype).destroy=function(){return fh.delete(this),sh(this),dh&&ah(this),this.l&&(this.l.stop(),this.l=null),this.F=this.A=null,this.h=this.m=!1,this.C=this.B=this.j=this.i=this.g=this.o=null,Promise.resolve()},i.jb=function(){return this.h},i.Jf=function(){return this.I},i.init=function(){if(this.G.length)if(e.chrome&&chrome.cast&&chrome.cast.isAvailable){this.m=!0,this.l.hc();var t=new chrome.cast.SessionRequest(this.G,[],null,this.K,null);t=new chrome.cast.ApiConfig(t,(function(e){for(var t=l(fh),n=t.next();!n.done;n=t.next()){var i=e;(n=n.value).j=new Gr,n.s=!0,ih(n,i)}}),(function(e){for(var t=l(fh),n=t.next();!n.done;n=t.next())n=n.value,ch="available"==e,n.l.hc()}),"origin_scoped"),chrome.cast.initialize(t,(function(){}),(function(){})),ch&&this.l.$(lh),(t=dh)&&t.status!=chrome.cast.SessionStatus.STOPPED?(this.j=new Gr,this.s=!0,ih(this,t)):dh=null}else e.__onGCastApiAvailable!==ph&&(hh=e.__onGCastApiAvailable||null,e.__onGCastApiAvailable=ph)},i.Rf=function(e){this.o=e,this.h&&uh(this,{type:"appData",appData:this.o})},i.cast=function(){var e=this;return P((function(t){if(!e.m)throw new De(1,8,8e3);if(!ch)throw new De(1,8,8001);if(e.h)throw new De(1,8,8002);return e.j=new Gr,chrome.cast.requestSession((function(t){return ih(e,t)}),(function(t){return rh(e,t)})),w(t,e.j,0)}))},i.Lc=function(){if(this.h){if(sh(this),dh){ah(this);try{dh.stop((function(){}),(function(){}))}catch(e){}dh=null}oh(this)}},i.get=function(e,t){var n=this;if("video"==e){if(Wd.includes(t))return function(){return n.Xg.apply(n,[e,t].concat(c(L.apply(0,arguments))))}}else if("player"==e){if($d[t]&&!this.get("player","isLive")())return function(){};if(eh.includes(t))return function(){return n.Xg.apply(n,[e,t].concat(c(L.apply(0,arguments))))};if(th.includes(t))return function(){return n.Oi.apply(n,[e,t].concat(c(L.apply(0,arguments))))};if(Yd[t]||Jd[t])return function(){return n.g[e][t]}}return this.g[e][t]},i.set=function(e,t,n){this.g[e][t]=n,uh(this,{type:"set",targetName:e,property:t,value:n})},i.Xg=function(e,t){uh(this,{type:"call",targetName:e,methodName:t,args:L.apply(2,arguments)})},i.Oi=function(e,t){var n=L.apply(2,arguments),i=new Gr,r=this.H.toString();this.H++,this.i[r]=i;try{uh(this,{type:"asyncCall",targetName:e,methodName:t,args:n,id:r})}catch(e){i.reject(e)}return i};var lh=.02,ch=!1,dh=null,hh=null,fh=new Set;function ph(t){if(hh?e.__onGCastApiAvailable=hh:delete e.__onGCastApiAvailable,hh=null,t)for(var n=l(fh),i=n.next();!i.done;i=n.next())i.value.init();"function"==typeof e.__onGCastApiAvailable&&e.__onGCastApiAvailable(t)}function gh(e,t,n,i){i=void 0!==i&&i,Zr.call(this);var r=this;this.i=e,this.h=t,this.m=this.o=this.j=this.s=this.l=null,this.C=n,this.B=i,this.A=new Map,this.g=new nh(n,(function(){return yh(r)}),(function(){return bh(r)}),(function(e,t){return Sh(r,e,t)}),(function(){return wh(r)}),(function(){return vh(r)}),i),function(e){e.g.init(),e.m=new Z;for(var t=l(Xd),n=t.next();!n.done;n=t.next())e.m.D(e.i,n.value,(function(t){e.g.jb()||(t=$r(t),e.j.dispatchEvent(t))}));for(var i in Qr)e.m.D(e.h,Qr[i],(function(t){e.g.jb()||e.o.dispatchEvent(t)}));for(var r in e.l={},t={},e.i)(t={pd:t.pd}).pd=r,Object.defineProperty(e.l,t.pd,{configurable:!1,enumerable:!0,get:function(t){return function(){return Th(e,t.pd)}}(t),set:function(t){return function(n){var i=t.pd;e.g.jb()?e.g.set("video",i,n):e.i[i]=n}}(t)});e.s={},mh(e,(function(t){Object.defineProperty(e.s,t,{configurable:!1,enumerable:!0,get:function(){return function(e,t){if(e.A.has(t)&&(t=e.A.get(t)),"addEventListener"==t)return function(t,n,i){return e.o.addEventListener(t,n,i)};if("removeEventListener"==t)return function(t,n,i){return e.o.removeEventListener(t,n,i)};if("getMediaElement"==t)return function(){return e.l};if("getSharedConfiguration"==t)return e.g.get("player","getConfiguration");if("getNetworkingEngine"==t)return function(){return e.h.Ab()};if("getDrmEngine"==t)return function(){return e.h.C};if("getAdManager"==t)return function(){return e.h.xg()};if("setVideoContainer"==t)return function(t){return e.h.kh(t)};if(e.g.jb()){if("getManifest"==t||"drmInfo"==t)return function(){return W(t+"() does not work while casting!"),null};if("attach"==t||"detach"==t)return function(){return W(t+"() does not work while casting!"),Promise.resolve()}}return e.g.jb()&&0==Object.keys(e.g.g.video).length&&(Yd[t]||Jd[t])||!e.g.jb()?e.h[t].bind(e.h):e.g.get("player",t)}(e,t)}})})),function(e){var t=new Map;mh(e,(function(n,i){t.has(i)?(i=t.get(i),n.length<i.length?e.A.set(n,i):e.A.set(i,n)):t.set(i,n)}))}(e),e.j=new Zr,e.j.re=e.l,e.o=new Zr,e.o.re=e.s}(this)}function mh(e,t){function n(e){return"constructor"!=e&&"function"==typeof r[e]&&!a.has(e)}var i,r=e.h,a=new Set;for(i in r)n(i)&&(a.add(i),t(i,r[i]));for(e=Object.getPrototypeOf(r),i=Object.getPrototypeOf({});e&&e!=i;){for(var o=l(Object.getOwnPropertyNames(e)),s=o.next();!s.done;s=o.next())n(s=s.value)&&(a.add(s),t(s,r[s]));e=Object.getPrototypeOf(e)}}function vh(e){var t={video:{},player:{},playerAfterLoad:{},manifest:e.h.Mc(),startTime:null};e.i.pause();for(var n=l(zd),i=n.next();!i.done;i=n.next())i=i.value,t.video[i]=e.i[i];for(e.i.ended||(t.startTime=e.i.currentTime),i=(n=l(Qd)).next();!i.done;i=n.next()){var r=i.value;i=r[1],r=e.h[r[0]](),t.player[i]=r}for(i=(n=l(Zd)).next();!i.done;i=n.next())i=(r=i.value)[1],r=e.h[r[0]](),t.playerAfterLoad[i]=r;return t}function yh(e){var t=new Jr("caststatuschanged");e.dispatchEvent(t)}function bh(e){var t=new Jr(e.l.paused?"pause":"play");e.j.dispatchEvent(t)}function wh(e){for(var t=l(Qd),n=t.next();!n.done;n=t.next()){var i=n.value;n=i[1],i=e.g.get("player",i[0])(),e.h[n](i)}var r=e.g.get("player","getAssetUri")();i=e.g.get("video","ended"),t=Promise.resolve();var a,o=e.i.autoplay;n=null,i||(n=e.g.get("video","currentTime")),(i=e.g.get("player","getTextTracks")())&&i.length&&(a=i.find((function(e){return e.active})));var s=e.g.get("player","isTextTrackVisible")();r&&(e.i.autoplay=!1,t=e.h.load(r,n));var u={};for(i=(n=l(zd)).next();!i.done;i=n.next())i=i.value,u[i]=e.g.get("video",i);t.then((function(){if(e.i){for(var t=l(zd),n=t.next();!n.done;n=t.next())n=n.value,e.i[n]=u[n];for(n=(t=l(Zd)).next();!n.done;n=t.next()){var i=n.value;n=i[1],i=e.g.get("player",i[0])(),e.h[n](i)}e.h.hh(s),a&&e.h.Pf(a.language,a.roles,a.forced),e.i.autoplay=o,r&&e.i.play()}}),(function(t){t=new Jr("error",t=(new Map).set("detail",t)),e.h.dispatchEvent(t)}))}function Th(e,t){if("addEventListener"==t)return function(t,n,i){return e.j.addEventListener(t,n,i)};if("removeEventListener"==t)return function(t,n,i){return e.j.removeEventListener(t,n,i)};if(e.g.jb()&&0==Object.keys(e.g.g.video).length){var n=e.i[t];if("function"!=typeof n)return n}return e.g.jb()?e.g.get("video",t):("function"==typeof(t=e.i[t])&&(t=t.bind(e.i)),t)}function Sh(e,t,n){e.g.jb()&&("video"==t?e.j.dispatchEvent(n):"player"==t&&e.o.dispatchEvent(n))}function xh(e,t,n,i){Zr.call(this);var r=this;this.g=e,this.h=t,this.j=new Z,this.H={video:e,player:t},this.F=n||function(){},this.I=i||function(e){return e},this.i=null,this.G=!1,this.o=!0,this.m=0,this.B=!1,this.A=!0,this.s=this.l=null,this.C=new Be((function(){Ih(r)})),function(e){var t=cast.receiver.CastReceiverManager.getInstance();t.onSenderConnected=function(){return Ah(e)},t.onSenderDisconnected=function(){return Ah(e)},t.onSystemVolumeChanged=function(){var t=cast.receiver.CastReceiverManager.getInstance().getSystemVolume();t&&Rh(e,{type:"update",update:{video:{volume:t.level,muted:t.muted}}},e.l),Rh(e,{type:"event",targetName:"video",event:{type:"volumechange"}},e.l)},e.s=t.getCastMessageBus("urn:x-cast:com.google.cast.media"),e.s.onMessage=function(t){return function(e,t){var n=Kd(t.data);switch(n.type){case"PLAY":e.g.play(),Ph(e);break;case"PAUSE":e.g.pause(),Ph(e);break;case"SEEK":t=n.currentTime;var i=n.resumeState;null!=t&&(e.g.currentTime=Number(t)),i&&"PLAYBACK_START"==i?(e.g.play(),Ph(e)):i&&"PLAYBACK_PAUSE"==i&&(e.g.pause(),Ph(e));break;case"STOP":e.h.ic().then((function(){e.h&&Ph(e)}));break;case"GET_STATUS":Ch(e,Number(n.requestId));break;case"VOLUME":t=(i=n.volume).level,i=i.muted;var r=e.g.volume,a=e.g.muted;null!=t&&(e.g.volume=Number(t)),null!=i&&(e.g.muted=i),r==e.g.volume&&a==e.g.muted||Ph(e);break;case"LOAD":e.m=0,e.B=!1,e.A=!1,t=n.media,i=n.currentTime,r=e.I(t.contentId),a=n.autoplay||!0,e.F(t.customData),a&&(e.g.autoplay=!0),e.h.load(r,i).then((function(){e.h&&Ch(e)})).catch((function(t){var i="LOAD_FAILED";7==t.category&&7e3==t.code&&(i="LOAD_CANCELLED"),Rh(e,{requestId:Number(n.requestId),type:i},e.s)}));break;default:Rh(e,{requestId:Number(n.requestId),type:"INVALID_REQUEST",reason:"INVALID_COMMAND"},e.s)}}(e,t)},e.l=t.getCastMessageBus("urn:x-cast:com.google.shaka.v2"),e.l.onMessage=function(t){return function(e,t){var n=Kd(t.data);switch(n.type){case"init":e.m=0,e.B=!1,e.A=!0,function(e,t,n){var i,r,a,o,s,u,l,c,d,h;P((function(f){switch(f.g){case 1:for(i in t.player)r=t.player[i],e.h[i](r);return e.F(n),a=e.g.autoplay,t.manifest?(e.g.autoplay=!1,S(f,5),w(f,e.h.load(t.manifest,t.startTime),7)):w(f,Promise.resolve(),3);case 7:A(f,3);break;case 5:return o=E(f),s=(new Map).set("detail",o),u=new Jr("error",s),e.h&&e.h.dispatchEvent(u),f.return();case 3:if(!e.h)return f.return();for(l in t.video)c=t.video[l],e.g[l]=c;for(d in t.playerAfterLoad)h=t.playerAfterLoad[d],e.h[d](h);e.g.autoplay=a,t.manifest&&(e.g.play(),Ph(e)),T(f)}}))}(e,n.initState,n.appData),Ih(e);break;case"appData":e.F(n.appData);break;case"set":var i=n.targetName,r=n.property;if(n=n.value,"video"==i){if(t=cast.receiver.CastReceiverManager.getInstance(),"volume"==r){t.setSystemVolumeLevel(n);break}if("muted"==r){t.setSystemVolumeMuted(n);break}}e.H[i][r]=n;break;case"call":(i=e.H[n.targetName])[n.methodName].apply(i,n.args);break;case"asyncCall":i=n.targetName,r=n.methodName,"player"==i&&"load"==r&&(e.m=0,e.B=!1);var a=n.id,o=t.senderId;n=(t=e.H[i])[r].apply(t,n.args),"player"==i&&"load"==r&&(n=n.then((function(){e.A=!0}))),n.then((function(){return Dh(e,o,a,null)}),(function(t){return Dh(e,o,a,t)}))}}(e,t)},t.start();for(var n=(t=l(Xd)).next();!n.done;n=t.next())e.j.D(e.g,n.value,(function(t){return kh(e,"video",t)}));for(var i in Qr)e.j.D(e.h,Qr[i],(function(t){return kh(e,"player",t)}));e.j.D(e.g,"loadeddata",(function(){e.B=!0})),e.j.D(e.h,"loading",(function(){e.o=!1,Eh(e)})),e.j.D(e.g,"playing",(function(){e.o=!1,Eh(e)})),e.j.D(e.g,"pause",(function(){Eh(e)})),e.j.D(e.h,"unloading",(function(){e.o=!0,Eh(e)})),e.j.D(e.g,"ended",(function(){new Be((function(){e.g&&e.g.ended&&(e.o=!0,Eh(e))})).$(Nh)}))}(this)}function Ah(e){e.m=0,e.A=!0,e.G=0!=cast.receiver.CastReceiverManager.getInstance().getSenders().length,Eh(e)}function Eh(e){var t;P((function(n){return 1==n.g?w(n,Promise.resolve(),2):e.h?(t=new Jr("caststatuschanged"),e.dispatchEvent(t),Mh(e)||Ph(e),void T(n)):n.return()}))}function kh(e,t,n){e.h&&(Ih(e),Rh(e,{type:"event",targetName:t,event:n},e.l))}function Ih(e){e.C.$(Lh);for(var t={video:{},player:{}},n=l(qd),i=n.next();!i.done;i=n.next())i=i.value,t.video[i]=e.g[i];if(e.h.U())for(var r in $d)0==e.m%$d[r]&&(t.player[r]=e.h[r]());for(var a in Yd)0==e.m%Yd[a]&&(t.player[a]=e.h[a]());for(var o in(n=cast.receiver.CastReceiverManager.getInstance().getSystemVolume())&&(t.video.volume=n.level,t.video.muted=n.muted),Rh(e,{type:"update",update:t},e.l),Jd)0==e.m%Jd[o]&&((t={player:{}}).player[o]=e.h[o](),Rh(e,{type:"update",update:t},e.l));e.B&&(e.m+=1),Mh(e)}function Mh(e){return!(!e.A||!e.g.duration&&!e.h.U()||(Ch(e),e.A=!1,0))}function Ch(e,t){var n={contentId:e.h.Mc(),streamType:e.h.U()?"LIVE":"BUFFERED",contentType:""};e.h.U()||(n.duration=e.g.duration),e.i&&(n.metadata=e.i),Ph(e,void 0===t?0:t,n)}function Dh(e,t,n,i){e.h&&Rh(e,{type:"asyncComplete",id:n,error:i},e.l,t)}function Rh(e,t,n,i){e.G&&(e=Gd(t),i?n.getCastChannel(i).send(e):n.broadcast(e))}function Ph(e,t,n){n=void 0===n?null:n;var i={mediaSessionId:0,playbackRate:e.g.playbackRate,playerState:e.o?jh:e.h.tf()?Uh:e.g.paused?_h:Oh,currentTime:e.g.currentTime,supportedMediaCommands:63,volume:{level:e.g.volume,muted:e.g.muted}};n&&(i.media=n),Rh(e,{requestId:void 0===t?0:t,type:"MEDIA_STATUS",status:[i]},e.s)}m(gh,Zr),(i=gh.prototype).destroy=function(e){return e&&this.g.Lc(),this.m&&(this.m.release(),this.m=null),e=[],this.h&&(e.push(this.h.destroy()),this.h=null),this.g&&(e.push(this.g.destroy()),this.g=null),this.s=this.l=this.i=null,Zr.prototype.release.call(this),Promise.all(e)},i.ji=function(){return this.l},i.Zh=function(){return this.s},i.Dh=function(){return this.g.m&&ch},i.jb=function(){return this.g.jb()},i.Jf=function(){return this.g.Jf()},i.cast=function(){var e=this;return P((function(t){return 1==t.g?w(t,e.g.cast(),2):e.h?w(t,e.h.ic(),0):t.return()}))},i.Rf=function(e){this.g.Rf(e)},i.dj=function(){var e;(e=this.g).h&&chrome.cast.requestSession((function(t){return ih(e,t)}),(function(t){return rh(e,t)}))},i.Lc=function(){this.g.Lc()},i.Eh=function(e,t){t=void 0!==t&&t;var n=this;return P((function(i){if(1==i.g)return e==n.C&&t==n.B?i.return():(n.C=e,n.B=t,n.g.Lc(),w(i,n.g.destroy(),2));n.g=null,n.g=new nh(e,(function(){return yh(n)}),(function(){return bh(n)}),(function(e,t){return Sh(n,e,t)}),(function(){return wh(n)}),(function(){return vh(n)}),t),n.g.init(),T(i)}))},F("shaka.cast.CastProxy",gh),gh.prototype.changeReceiverId=gh.prototype.Eh,gh.prototype.forceDisconnect=gh.prototype.Lc,gh.prototype.suggestDisconnect=gh.prototype.dj,gh.prototype.setAppData=gh.prototype.Rf,gh.prototype.cast=gh.prototype.cast,gh.prototype.receiverName=gh.prototype.Jf,gh.prototype.isCasting=gh.prototype.jb,gh.prototype.canCast=gh.prototype.Dh,gh.prototype.getPlayer=gh.prototype.Zh,gh.prototype.getVideo=gh.prototype.ji,gh.prototype.destroy=gh.prototype.destroy,m(xh,Zr),(i=xh.prototype).isConnected=function(){return this.G},i.ri=function(){return this.o},i.$i=function(e){this.i=e},i.Gh=function(){this.i=null},i.aj=function(e){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC}),this.i.title=e},i.Zi=function(e){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC}),this.i.images=[{url:e}]},i.Yi=function(e){this.i||(this.i={}),this.i.artist=e,this.i.metadataType=cast.receiver.media.MetadataType.MUSIC_TRACK},i.destroy=function(){var e,t=this;return P((function(n){if(1==n.g)return t.j&&(t.j.release(),t.j=null),e=[],t.h&&(e.push(t.h.destroy()),t.h=null),t.C&&(t.C.stop(),t.C=null),t.g=null,t.H=null,t.F=null,t.G=!1,t.o=!0,t.l=null,t.s=null,Zr.prototype.release.call(t),w(n,Promise.all(e),2);cast.receiver.CastReceiverManager.getInstance().stop(),T(n)}))},F("shaka.cast.CastReceiver",xh),xh.prototype.destroy=xh.prototype.destroy,xh.prototype.setContentArtist=xh.prototype.Yi,xh.prototype.setContentImage=xh.prototype.Zi,xh.prototype.setContentTitle=xh.prototype.aj,xh.prototype.clearContentMetadata=xh.prototype.Gh,xh.prototype.setContentMetadata=xh.prototype.$i,xh.prototype.isIdle=xh.prototype.ri,xh.prototype.isConnected=xh.prototype.isConnected;var Lh=.5,Nh=5,jh="IDLE",Oh="PLAYING",Uh="BUFFERING",_h="PAUSED";function Bh(e,t,n,i,r){if(i>=r)return null;for(var a=-1,o=-1,s=0;s<n.length;s++)if(n[s].some((function(e){return null!=e&&""!=e.g.trim()}))){a=s;break}for(s=n.length-1;0<=s;s--)if(n[s].some((function(e){return null!=e&&""!=e.g.trim()}))){o=s;break}if(-1===a||-1===o)return null;for(var u=s=!1,l="white",c="black",d=Fh(i,r,s,u,l,c);a<=o;a++){for(var h=n[a],f=-1,p=-1,g=0;g<h.length;g++)if(null!=h[g]&&""!==h[g].g.trim()){f=g;break}for(g=h.length-1;0<=g;g--)if(null!=h[g]&&""!==h[g].g.trim()){p=g;break}if(-1===f||-1===p)h=Vh(i,r),e.nestedCues.push(h);else{for(;f<=p;f++)if(g=h[f]){var m=g.l,v=g.i,y=g.j,b=g.h;m==s&&v==u&&y==l&&b==c||(d.payload&&e.nestedCues.push(d),d=Fh(i,r,m,v,y,b),s=m,u=v,l=y,c=b),d.payload+=g.g}else d.payload+=" ";d.payload&&e.nestedCues.push(d),a!==o&&(d=Vh(i,r),e.nestedCues.push(d)),d=Fh(i,r,s,u,l,c)}}return e.nestedCues.length?{cue:e,stream:t}:null}function Fh(e,t,n,i,r,a){return e=new un(e,t,""),n&&e.textDecoration.push(Pn),i&&(e.fontStyle=Dn),e.color=r,e.backgroundColor=a,e}function Vh(e,t){return(e=new un(e,t,"")).lineBreak=!0,e}function Hh(e,t,n,i,r){this.g=e,this.l=t,this.i=n,this.h=i,this.j=r}function Gh(e,t){this.i=[],this.g=1,this.h=0,this.C=e,this.B=t,this.j=this.m=!1,this.l="white",this.o="black",this.s=this.A=null,Xh(this)}function Kh(e,t,n){var i="CC"+(1+(e.C<<1|e.B)),r=new un(t,n,"");r.lineInterpretation=1;var a=Zh.get(e.g);return a&&(r.line=a),null!=e.s&&null!=e.A&&(r.position=10+Math.min(70,10*e.s)+2.5*e.A),(t=Bh(r,i,e.i,t,n))&&15<e.g+t.cue.nestedCues.length-3&&(a=Zh.get(e.g+3-t.cue.nestedCues.length))&&(r.line=a),t}function Xh(e){Wh(e,0,15),e.g=1}function qh(e,t,n){if(!(32>n||127<n)){var i="";switch(t){case 0:i=Yh.has(n)?Yh.get(n):String.fromCharCode(n);break;case 1:i=Jh.get(n);break;case 2:e.i[e.g].pop(),i=$h.get(n);break;case 3:e.i[e.g].pop(),i=Qh.get(n)}i&&e.i[e.g].push(new Hh(i,e.m,e.j,e.o,e.l))}}function zh(e,t,n,i){if(!(0>n||0>t))if(t>=n)for(--i;0<=i;i--)e.i[t+i]=e.i[n+i].map((function(e){return e}));else for(var r=0;r<i;r++)e.i[t+r]=e.i[n+r].map((function(e){return e}))}function Wh(e,t,n){for(var i=0;i<=n;i++)e.i[t+i]=[]}var Yh=new Map([[39,"’"],[42,"á"],[92,"é"],[92,"é"],[94,"í"],[95,"ó"],[96,"ú"],[123,"ç"],[124,"÷"],[125,"Ñ"],[126,"ñ"],[127,"█"]]),Jh=new Map([[48,"®"],[49,"°"],[50,"½"],[51,"¿"],[52,"™"],[53,"¢"],[54,"£"],[55,"♪"],[56,"à"],[57," "],[58,"è"],[59,"â"],[60,"ê"],[61,"î"],[62,"ô"],[63,"û"]]),$h=new Map([[32,"Á"],[33,"É"],[34,"Ó"],[35,"Ú"],[36,"Ü"],[37,"ü"],[38,"‘"],[39,"¡"],[40,"*"],[41,"'"],[42,"─"],[43,"©"],[44,"℠"],[45,"·"],[46,"“"],[47,"”"],[48,"À"],[49,"Â"],[50,"Ç"],[51,"È"],[52,"Ê"],[53,"Ë"],[54,"ë"],[55,"Î"],[56,"Ï"],[57,"ï"],[58,"Ô"],[59,"Ù"],[60,"ù"],[61,"Û"],[62,"«"],[63,"»"]]),Qh=new Map([[32,"Ã"],[33,"ã"],[34,"Í"],[35,"Ì"],[36,"ì"],[37,"Ò"],[38,"ò"],[39,"Õ"],[40,"õ"],[41,"{"],[42,"}"],[43,"\\"],[44,"^"],[45,"_"],[46,"|"],[47,"~"],[48,"Ä"],[49,"ä"],[50,"Ö"],[51,"ö"],[52,"ß"],[53,"¥"],[54,"¤"],[55,"│"],[56,"Å"],[57,"å"],[58,"Ø"],[59,"ø"],[60,"┌"],[61,"┐"],[62,"└"],[63,"┘"]]),Zh=new Map([[1,10],[2,15.33],[3,20.66],[4,26],[5,31.33],[6,36.66],[7,42],[8,47.33],[9,52.66],[10,58],[11,63.33],[12,68.66],[13,74],[14,79.33],[15,84.66]]);function ef(e,t){this.h=0,this.o=new Gh(e,t),this.i=new Gh(e,t),this.g=this.j=new Gh(e,t),this.l=0,this.m=null}function tf(e,t,n){e.g=e.i;var i=e.g,r=null;return 3!==e.h&&4!==e.h&&(r=Kh(i,e.l,n),(n=e.i).g=0<n.h?n.h:0,Wh(n,0,15),(n=e.j).g=0<n.h?n.h:0,Wh(n,0,15),i.g=15),e.h=3,i.h=t,r}function nf(e){e.h=1,e.g=e.j,e.g.h=0}function rf(e){Y("Cea608DataChannel","CEA-608 text mode entered, but is unsupported"),e.g=e.o,e.h=4}var af="black green blue cyan red yellow magenta black".split(" "),of="white green blue cyan red yellow magenta white_italics".split(" ");function sf(e,t){this.I=t,this.M=e,this.K=this.l=!1,this.m=this.o=this.G=this.L=this.H=0,this.F=2,this.i=[],this.g=this.h=this.j=0,this.C=this.A=!1,this.B="white",this.s="black",uf(this)}function uf(e){e.i=[];for(var t=0;16>t;t++)e.i.push(lf())}function lf(){for(var e=[],t=0;42>t;t++)e.push(null);return e}function cf(e,t){df(e)&&(e.i[e.h][e.g]=new Hh(t,e.C,e.A,e.s,e.B),e.g++)}function df(e){var t=e.g<e.m&&0<=e.g;return e.h<e.o&&0<=e.h&&t}function hf(e,t,n){var i=new un(e.j,t,"");i.textAlign=0===e.F?"left":1===e.F?"right":mn;var r=i.region;switch(e.I&&(r.id+="svc"+e.I),r.id+="win"+e.M,r.height=e.o,r.width=e.m,r.heightUnits=2,r.widthUnits=2,r.viewportAnchorX=e.H,r.viewportAnchorY=e.L,r.viewportAnchorUnits=e.K?Ae:2,e.G){case 0:r.regionAnchorX=0,r.regionAnchorY=0;break;case 1:r.regionAnchorX=50,r.regionAnchorY=0;break;case 2:r.regionAnchorX=100,r.regionAnchorY=0;break;case 3:r.regionAnchorX=0,r.regionAnchorY=50;break;case 4:r.regionAnchorX=50,r.regionAnchorY=50;break;case 5:r.regionAnchorX=100,r.regionAnchorY=50;break;case 6:r.regionAnchorX=0,r.regionAnchorY=100;break;case 7:r.regionAnchorX=50,r.regionAnchorY=100;break;case 8:r.regionAnchorX=100,r.regionAnchorY=100}return(n=Bh(i,"svc"+n,e.i,e.j,t))&&(e.j=t),n}function ff(){this.i=[],this.h=null,this.g=0}function pf(e,t){3===t.type?(e.g=2*(63&t.value)-1,e.h=[]):e.h&&(0<e.g&&(e.h.push(t),e.g--),0===e.g&&(e.i.push(new gf(e.h)),e.h=null,e.g=0))}function gf(e){this.g=0,this.h=e}function mf(e){if(!e.sa())throw new De(2,2,3e3);return e.h[e.g++]}function vf(e){this.i=e,this.h=[null,null,null,null,null,null,null,null],this.g=null}function yf(e,t,n,i){if(128<=n&&135>=n)i=7&n,e.h[i]&&(e.g=e.h[i]);else{if(136===n){n=mf(t).value,t=null;for(var r=(n=l(bf(e,n))).next();!r.done;r=n.next())(r=e.h[r.value]).isVisible()&&(t=hf(r,i,e.i)),uf(r);return t}if(137===n)for(n=(t=l(bf(e,t=mf(t).value))).next();!n.done;n=t.next())(n=e.h[n.value]).isVisible()||(n.j=i),n.display();else{if(138===n){for(n=mf(t).value,t=null,r=(n=l(bf(e,n))).next();!r.done;r=n.next())(r=e.h[r.value]).isVisible()&&(t=hf(r,i,e.i)),r.l=!1;return t}if(139===n){for(n=mf(t).value,t=null,r=(n=l(bf(e,n))).next();!r.done;r=n.next())(r=e.h[r.value]).isVisible()?t=hf(r,i,e.i):r.j=i,r.l=!r.l;return t}if(140===n)return wf(e,t=mf(t).value,i);if(143===n)return i=wf(e,255,i),Tf(e),i;if(144===n)t.skip(1),i=mf(t).value,e.g&&(e.g.A=0<(128&i),e.g.C=0<(64&i));else if(145===n)i=mf(t).value,n=mf(t).value,t.skip(1),e.g&&(t=Sf((48&n)>>4,(12&n)>>2,3&n),e.g.B=Sf((48&i)>>4,(12&i)>>2,3&i),e.g.s=t);else if(146===n)i=mf(t).value,t=mf(t).value,e.g&&((e=e.g).h=15&i,e.g=63&t);else if(151===n)t.skip(1),t.skip(1),i=mf(t).value,t.skip(1),e.g&&(e.g.F=3&i);else if(152<=n&&159>=n){if(n=(15&n)-8,!(r=null!==e.h[n])){var a=new sf(n,e.i);a.j=i,e.h[n]=a}i=mf(t).value,a=mf(t).value;var o=mf(t).value,s=mf(t).value,u=mf(t).value;t=mf(t).value,r&&!(7&t)||((t=e.h[n]).h=0,t.g=0,t.C=!1,t.A=!1,t.B="white",t.s="black"),(t=e.h[n]).l=0<(32&i),t.L=127&a,t.H=o,t.G=(240&s)>>4,t.K=0<(128&a),t.o=1+(15&s),t.m=1+(63&u),e.g=e.h[n]}}}return null}function bf(e,t){for(var n=[],i=0;8>i;i++)!(1&~t)&&e.h[i]&&n.push(i),t>>=1;return n}function wf(e,t,n){for(var i=null,r=(t=l(bf(e,t))).next();!r.done;r=t.next()){r=r.value;var a=e.h[r];a.isVisible()&&(i=hf(a,n,e.i)),e.h[r]=null}return i}function Tf(e){e.g=null,e.h=[null,null,null,null,null,null,null,null]}function Sf(e,t,n){var i={0:0,1:0,2:1,3:1};return Af[(e=i[e])<<2|(t=i[t])<<1|(n=i[n])]}sf.prototype.isVisible=function(){return this.l},sf.prototype.display=function(){this.l=!0},gf.prototype.sa=function(){return this.g<this.h.length},gf.prototype.ya=function(){return this.g},gf.prototype.skip=function(e){if(this.g+e>this.h.length)throw new De(2,2,3e3);this.g+=e};var xf=new Map([[32," "],[33," "],[37,"…"],[42,"Š"],[44,"Œ"],[48,"█"],[49,"‘"],[50,"’"],[51,"“"],[52,"”"],[53,"•"],[57,"™"],[58,"š"],[60,"œ"],[61,"℠"],[63,"Ÿ"],[118,"⅛"],[119,"⅜"],[120,"⅝"],[121,"⅞"],[122,"│"],[123,"┐"],[124,"└"],[125,"─"],[126,"┘"],[127,"┌"]]),Af="black blue green cyan red magenta yellow white".split(" ");function Ef(){this.h=[],this.g=[],this.i=new ff,this.l=0,this.m=new Map([["CC1",new ef(0,0)],["CC2",new ef(0,1)],["CC3",new ef(1,0)],["CC4",new ef(1,1)]]),this.s=this.o=0,this.j=new Map,this.B=!0,this.A=new Set,kf(this)}function kf(e){e.o=0,e.s=0;for(var t=l(e.m.values()),n=t.next();!n.done;n=t.next())(n=n.value).h=0,n.g=n.j,n.m=null,Xh(n.i),Xh(n.j),Xh(n.o);e.B=!0}function If(e,t){var n=t.type;if(16==(112&t.gb)){var i=t.gb>>3&1;0===n?e.o=i:e.s=i}if(i="CC"+(1+(n<<1|(n?e.s:e.o))),n=e.m.get(i),255===t.gb&&255===t.Eb||!t.gb&&!t.Eb||!Cf(t.gb)||!Cf(t.Eb))return 45<=++e.l&&kf(e),null;e.l=0,t.gb&=127,t.Eb&=127;var r=t.gb;if(1<=r&&15>=r||!t.gb&&!t.Eb)return null;if(r=null,16==(112&t.gb))e:{if(e.A.add(i),i=t.gb,e=t.Eb,n.m===(i<<8|e))n.m=null;else if(n.m=i<<8|e,16==(240&i)&&64==(192&e)){t=[11,11,1,2,3,4,12,13,14,15,5,6,7,8,9,10][(7&i)<<1|e>>5&1],i="white",r=!1;var a=null,o=95<e?e-96:e-64;13>=o?i=of[Math.floor(o/2)]:15>=o?r=!0:a=Math.floor((o-16)/2),e=!(1&~e),4!==n.h&&(o=n.g,3===n.h&&t!==o.g&&(zh(o,n=1+t-o.h,1+o.g-o.h,o.h),Wh(o,0,n-1),Wh(o,t+1,15-t)),o.g=t,o.m=e,o.j=r,o.l=i,o.s=a,o.o="black")}else if(17==(247&i)&&32==(240&e))n.g.m=!1,n.g.j=!1,n.g.l="white",qh(n.g,0,32),i=!1,"white_italics"===(t=of[(14&e)>>1])&&(t="white",i=!0),n.g.m=!(1&~e),n.g.j=i,n.g.l=t;else if(16==(247&i)&&32==(240&e)||23==(247&i)&&45==(255&e))t="black",!(7&i)&&(t=af[(14&e)>>1]),n.g.o=t;else if(17==(247&i)&&48==(240&e))qh(n.g,1,e);else if(18==(246&i)&&32==(224&e))qh(n.g,1&i?3:2,e);else{if(20==(246&i)&&32==(240&e)){switch(e=t.pts,i=null,t.Eb){case 32:nf(n);break;case 33:(n=n.g).i[n.g].pop();break;case 37:i=tf(n,2,e);break;case 38:i=tf(n,3,e);break;case 39:i=tf(n,4,e);break;case 40:qh(n.g,0,32);break;case 41:n.h=2,n.g=n.i,n.g.h=0,n.l=e;break;case 42:Xh(n.o),rf(n);break;case 43:rf(n);break;case 44:t=n.i,i=null,4!==n.h&&(i=Kh(t,n.l,e)),Wh(t,0,15);break;case 45:t=n.g,3!==n.h?i=null:(i=Kh(t,n.l,e),zh(t,(r=t.g-t.h+1)-1,r,t.h),Wh(t,0,r-1),Wh(t,t.g,15-t.g),n.l=e);break;case 46:Wh(n.j,0,15);break;case 47:t=null,4!==n.h&&(t=Kh(n.i,n.l,e)),i=n.j,n.j=n.i,n.i=i,nf(n),n.l=e,i=t}r=i;break e}(23==i||31==i)&&33<=e&&35>=e&&(n.g.A=e-32)}r=null}else e=t.Eb,qh(n.g,0,t.gb),qh(n.g,0,e);return r}function Mf(e,t){var n=[];try{for(;t.sa();){var i=mf(t).value,r=(224&i)>>5,a=31&i;if(7===r&&0!=a&&(r=63&mf(t).value),0!=r){e.A.add("svc"+r),e.j.has(r)||e.j.set(r,new vf(r));for(var o=e.j.get(r),s=t.ya();t.ya()-s<a;){r=o;var u=t,l=mf(u),c=l.value,d=l.pts;if(16===c&&(c=c<<16|mf(u).value),0<=c&&31>=c){var h=c,f=d;if((u=r).g){var p=u.g;switch(r=null,h){case 8:!df(p)||0>=p.g&&0>=p.h||(0>=p.g?(p.g=p.m-1,p.h--):p.g--,p.i[p.h][p.g]=null);break;case 13:if(p.isVisible()&&(r=hf(p,f,u.i)),p.h+1>=p.o){for(u=p,h=0,f=1;16>f;f++,h++)u.i[h]=u.i[f];for(f=0;1>f;f++,h++)u.i[h]=lf()}else p.h++;p.g=0;break;case 14:p.isVisible()&&(r=hf(p,f,u.i)),p.i[p.h]=lf(),p.g=0;break;case 12:p.isVisible()&&(r=hf(p,f,u.i)),uf(p),(u=p).h=0,u.g=0}var g=r}else g=null}else if(128<=c&&159>=c)g=yf(r,u,c,d);else{if(4096<=c&&4127>=c)r=u,8<=(u=255&c)&&15>=u?r.skip(1):16<=u&&23>=u?r.skip(2):24<=u&&31>=u&&r.skip(3);else if(4224<=c&&4255>=c)r=u,128<=(u=255&c)&&135>=u?r.skip(4):136<=u&&143>=u&&r.skip(5);else if(32<=c&&127>=c)u=c,r.g&&cf(r.g,127===u?"♪":String.fromCharCode(u));else if(160<=c&&255>=c)r.g&&cf(r.g,String.fromCharCode(c));else if(4128<=c&&4223>=c){if(u=255&c,r.g)if(xf.has(u)){var m=xf.get(u);cf(r.g,m)}else cf(r.g,"_")}else 4256<=c&&4351>=c&&r.g&&cf(r.g,160!=(255&c)?"_":"[CC]");g=null}(r=g)&&n.push(r)}}}}catch(e){if(!(e instanceof De&&3e3===e.code))throw e;Y("CEA708_INVALID_DATA","Buffer read out of bounds / invalid CEA-708 Data.")}return n}function Cf(e){for(var t=0;e;)t^=1&e,e>>=1;return 1===t}function Df(e){for(var t=[],n=e,i=e=0;i<n.length;)2==e&&3==n[i]?(e=0,(n=[].concat(c(n))).splice(i,1),n=new Uint8Array(n)):0==n[i]?e++:e=0,i++;for(e=n,i=0;i<e.length;){for(n=0;255==e[i];)n+=255,i++;n+=e[i++];for(var r=0;255==e[i];)r+=255,i++;r+=e[i++],4==n&&t.push(e.subarray(i,i+r)),i+=r}return t}function Rf(){this.j=new Map,this.i=this.h=0,this.g=Lf}function Pf(e,t,n,i,r,a,o,s,u){var d=0,h=a,f=s.map((function(e){return e.Zg}));for((f=[].concat.apply([],c(f))).length&&(h=f[0].sampleSize||a),t.skip(o+s[0].Ih);t.sa();){o=t.P();var p=t.T(),g=null;switch(g=!1,s=1,e.g){case Nf:g=6==(g=31&p);break;case jf:s=2,t.skip(1),g=39==(g=p>>1&63)||40==g;break;case Of:s=2,t.skip(1),g=23==(g=p>>1&63)||24==g;break;default:return}if(g)for(p=0,d<f.length&&(p=f[d].me||0),p=(n+p)/i,g=(s=l(Df(t.vb(o-s)))).next();!g.done;g=s.next())u.push({packet:g.value,pts:p});else try{t.skip(o-s)}catch(e){break}0==(h-=o+4)&&(n=d<f.length?n+(f[d].Of||r):n+r,h=++d<f.length&&f[d].sampleSize||a)}}Ef.prototype.clear=function(){this.l=0,this.h=[],this.g=[];var e=this.i;e.i=[],e.h=[],e.g=0,kf(this);for(var t=(e=l(this.j.values())).next();!t.done;t=e.next())Tf(t.value)},Ef.prototype.extract=function(e,t){if(this.B){for(var n=l(this.m.values()),i=n.next();!i.done;i=n.next())i.value.l=t;this.B=!1}if(!(8>(e=new ya(e,0)).getLength())&&181===e.T()&&49===e.ma()&&1195456820===e.P()&&3===e.T()&&64&(n=e.T()))for(n&=31,e.skip(1),i=0;i<n;i++){var r=e.T(),a=(4&r)>>2,o=e.T(),s=e.T();a&&(0==(r&=3)||1===r?this.h.push({pts:t,type:r,gb:o,Eb:s,order:this.h.length}):(this.g.push({pts:t,type:r,value:o,order:this.g.length}),this.g.push({pts:t,type:2,value:s,order:this.g.length})))}},Ef.prototype.decode=function(){function e(e,t){return e.pts-t.pts||e.order-t.order}var t=[];this.h.sort(e),this.g.sort(e);for(var n=l(this.h),i=n.next();!i.done;i=n.next())(i=If(this,i.value))&&t.push(i);for(i=(n=l(this.g)).next();!i.done;i=n.next())pf(this.i,i.value);for(i=(n=l(this.i.i)).next();!i.done;i=n.next())i=Mf(this,i.value),t.push.apply(t,c(i));return this.i.i=[],this.h=[],this.g=[],t},Ef.prototype.getStreams=function(){return Array.from(this.A)},F("shaka.cea.CeaDecoder",Ef),Se=function(){return new Ef},Rf.prototype.init=function(e){function t(e){(e=e.name)in Uf&&(n.g=Uf[e])}var n=this,i=[],r=[];if((new Ta).box("moov",Sa).box("mvex",Sa).R("trex",(function(e){var t=e.reader;t.skip(4),t.skip(4),e=t.P(),t=t.P(),n.h=e,n.i=t})).box("trak",Sa).R("tkhd",(function(e){var t=e.reader;1==(e=e.version)?(t.skip(8),t.skip(8)):(t.skip(4),t.skip(4));var n=t.P();1==e?t.skip(8):t.skip(4),t.skip(4),t.skip(8),t.skip(2),t.skip(2),t.skip(2),t.skip(2),t.skip(36),t.ma(),t.ma(),t.ma(),t.ma(),i.push(n)})).box("mdia",Sa).R("mdhd",(function(e){e=_o(e.reader,e.version),r.push(e.timescale)})).box("minf",Sa).box("stbl",Sa).R("stsd",xa).box("avc1",t).box("avc3",t).box("dvav",t).box("dva1",t).box("hev1",t).box("hvc1",t).box("dvh1",t).box("dvhe",t).box("vvc1",t).box("vvi1",t).box("dvc1",t).box("dvi1",t).box("encv",Aa).box("sinf",Sa).box("frma",(function(e){(e=Vo(e.reader).codec)in Uf&&(n.g=Uf[e])})).parse(e,!0),!i.length||!r.length||i.length!=r.length)throw new De(2,2,2010);this.g==Lf&&W("Unable to determine bitstream format for CEA parsing!"),i.forEach((function(e,t){n.j.set(e,r[t])}))},Rf.prototype.parse=function(e){var t=this;if(this.g==Lf)return[];var n=[],i=0,r=[];return(new Ta).box("moof",(function(e){i=e.start,r=[],Sa(e)})).box("traf",(function(e){r.push({baseMediaDecodeTime:null,ed:t.h,Ld:t.i,Sg:[],timescale:9e4}),Sa(e)})).R("trun",(function(e){var t=r[r.length-1];e=Bo(e.reader,e.version,e.flags),t.Sg.push(e)})).R("tfhd",(function(e){var n=r[r.length-1];e=Oo(e.reader,e.flags),n.ed=e.ed||t.h,n.Ld=e.Ld||t.i,e=e.trackId,t.j.has(e)&&(n.timescale=t.j.get(e))})).R("tfdt",(function(e){var t=r[r.length-1];e=Uo(e.reader,e.version),t.baseMediaDecodeTime=e.baseMediaDecodeTime})).box("mdat",(function(e){for(var a=i-e.start-8,o=e.reader.ya(),s=l(r),u=s.next();!u.done;u=s.next()){if(null===(u=u.value).baseMediaDecodeTime)throw W("Unable to find base media decode time for CEA captions!"),new De(2,2,2010);e.reader.seek(o),Pf(t,e.reader,u.baseMediaDecodeTime,u.timescale,u.ed,u.Ld,a,u.Sg,n)}})).parse(e,!1),n},F("shaka.cea.Mp4CeaParser",Rf);var Lf=0,Nf=1,jf=2,Of=3,Uf={avc1:Nf,avc3:Nf,dvav:Nf,dva1:Nf,hev1:jf,hvc1:jf,dvh1:jf,dvhe:jf,vvc1:Of,vvi1:Of,dvc1:Of,dvi1:Of};function _f(){this.g=null}function Bf(t,n,i){var r=function(e){for(var t=[],n=(e=l(e)).next();!n.done;n=e.next())(n=Vf(n.value))&&t.push(n);return t}(t),a=null;t=[];var o=[],s=null,u=new Set(r.map((function(e){return e.keyId})));u.delete(null);var c="cenc";if(1<u.size)throw new De(2,4,4010);if(!n){if(1<(o=r.filter((function(e){return"urn:mpeg:dash:sea:2012"==e.Wc}))).length)throw new De(2,4,4050);o.length&&(s=function(t){if(!e.crypto||!e.crypto.subtle)throw W("Web Crypto API is not available to decrypt AES-128. (Web Crypto only exists in secure origins like https)"),new De(2,4,4042);var n=Bt(t.node,"urn:mpeg:dash:schema:sea:2012","SegmentEncryption");if(!n)throw new De(2,4,4051);if("urn:mpeg:dash:sea:aes128-cbc:2013"!=n.attributes.schemeIdUri)throw new De(2,4,4051);if(!(n=Bt(t.node,"urn:mpeg:dash:schema:sea:2012","CryptoPeriod")))throw new De(2,4,4051);if(t=n.attributes.IV,n=vt(n.attributes.keyUriTemplate),!t||!n)throw new De(2,4,4051);if(16!=(t=li(t.substr(2))).byteLength)throw new De(2,4,4048);return{wi:n,iv:t}}(o[0])),(o=r.find((function(e){return"urn:mpeg:dash:mp4protection:2011"==e.Wc})))&&o.encryptionScheme&&(c=o.encryptionScheme),(o=r.filter((function(e){return"urn:mpeg:dash:mp4protection:2011"==e.Wc?(a=e.init||a,!1):"urn:mpeg:dash:sea:2012"!=e.Wc}))).length&&(t=function(e,t,n,i,r){for(var a=[],o=(n=l(n)).next();!o.done;o=n.next()){var s=i[(o=o.value).Wc];if(s){var u;if((u=Bt(o.node,"urn:microsoft:playready","pro"))&&jt(u)){u=ui(u=jt(u));var c=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);u=[{initData:La(u,c,new Set,0),initDataType:"cenc",keyId:o.keyId}]}else u=null;if(c=null,"urn:uuid:e2719d58-a985-b3c9-781a-b030af78d30e"===o.Wc){c=o;var d=r;if(0==d.size)c=null;else{var h=new Uint8Array([16,119,239,236,192,178,77,2,172,227,60,30,82,226,251,75]);c=[{initData:La(new Uint8Array([]),h,d,1),initDataType:"cenc",keyId:c.keyId}]}}u=fi(s,t,o.init||e||u||c),(s=Gf.get(s))&&(u.licenseServerUri=s(o)),a.push(u)}}return a}(a,c,o,i,u),0==t.length&&(t=[fi("",c,a)]))}if(r.length&&!s&&(n||!o.length))for(t=[],i=(n=l(Object.values(i))).next();!i.done;i=n.next())"org.w3.clearkey"!=(i=i.value)&&t.push(fi(i,c,a));if(u=Array.from(u)[0]||null)for(n=(c=l(t)).next();!n.done;n=c.next())for(i=(n=l(n.value.initData)).next();!i.done;i=n.next())i.value.keyId=u;return{rg:u,kk:a,drmInfos:t,Je:s,wg:!0}}function Ff(e){var t=Bt(e.node,"https://dashif.org/CPS","Laurl");return t&&(t=jt(t))?t:(e=Bt(e.node,"urn:microsoft:playready","pro"))&&jt(e)?(e=function(e){var t=0,n=ve(e),i=n.getUint32(t,!0);if(i!=e.byteLength)return[];e:{for(e=t+6,t=[];e<n.byteLength-1;){i=n.getUint16(e,!0),e+=2;var r=n.getUint16(e,!0);if(e+=2,1&r||r+e>n.byteLength){n=[];break e}var a=ge(n,e,r);t.push({type:i,value:a}),e+=r}n=t}return n}(e=ui(e=jt(e))).filter((function(e){return e.type===Hf}))[0],e&&(e=Dt(e=ht(e.value,!0),"WRMHEADER"))?function(e){for(var t=(e=l(Ut(e,"DATA"))).next();!t.done;t=e.next())if((t=t.value).children)for(var n=(t=l(t.children)).next();!n.done;n=t.next())if("LA_URL"==(n=n.value).tagName)return jt(n);return""}(e):""):""}function Vf(e){var t=e.attributes.schemeIdUri,n=Vt(e,"urn:mpeg:cenc:2013","default_KID"),i=Ht(e,"urn:mpeg:cenc:2013","pssh").map(Ot),r=e.attributes.value;if(!t)return null;if(t=t.toLowerCase(),n&&(n=n.replace(/-/g,"").toLowerCase()).includes(" "))throw new De(2,4,4009);var a=[];try{a=i.map((function(e){return{initDataType:"cenc",initData:ui(e),keyId:null}}))}catch(e){throw new De(2,4,4007)}return{node:e,Wc:t,keyId:n,init:0<a.length?a:null,encryptionScheme:r}}Te["video/mp4"]=function(){return new Rf},_f.prototype.init=function(){},_f.prototype.parse=function(e){this.g?this.g.clearData():this.g=new ns;var t=[];if(!os(e=ge(e)))return t;var n=(e=this.g.parse(e)).fd(),i=e.Rd();switch(e=[],n.video){case"avc":e.push(6);break;case"hvc":e.push(39),e.push(40)}if(!e.length)return t;for(i=(n=l(i)).next();!i.done;i=n.next())if(i=i.value,e.includes(i.type)&&null!=i.time)for(var r=l(Df(i.data)),a=r.next();!a.done;a=r.next())t.push({packet:a.value,pts:i.time});return t},F("shaka.cea.TsCeaParser",_f),Te["video/mp2t"]=function(){return new _f};var Hf=1,Gf=(new Map).set("com.apple.fps",(function(e){if(ot())throw new De(2,4,4054);return(e=Bt(e.node,"https://dashif.org/CPS","Laurl"))&&(e=jt(e))?e:""})).set("com.widevine.alpha",(function(e){var t=Bt(e.node,"https://dashif.org/CPS","Laurl");return t&&(t=jt(t))?t:(e=Bt(e.node,"urn:microsoft","laurl"))&&vt(e.attributes.licenseUrl)||""})).set("com.microsoft.playready",Ff).set("com.microsoft.playready.recommendation",Ff).set("com.microsoft.playready.software",Ff).set("com.microsoft.playready.hardware",Ff).set("org.w3.clearkey",(function(e){var t=Bt(e.node,"https://dashif.org/CPS","Laurl");return t&&(t=jt(t))?t:(e=Bt(e.node,"http://dashif.org/guidelines/clearKey","Laurl"))&&"EME-1.0"===e.attributes.Lic_type&&e&&(e=jt(e))?e:""}));function Kf(t,n,i,r,a,o){var s={RepresentationID:n,Number:i,SubNumber:r,Bandwidth:a,Time:o};return t.replace(/\$(RepresentationID|Number|SubNumber|Bandwidth|Time)?(?:%0([0-9]+)([diouxX]))?\$/g,(function(t,n,i,r){if("$$"==t)return"$";var a=s[n];if(null==a)return t;switch("RepresentationID"==n&&i&&(i=void 0),"Time"==n&&"bigint"!=typeof a&&(.2<=Math.abs(a-Math.round(a))&&W("Calculated $Time$ values must be close to integers"),a=Math.round(a)),r){case void 0:case"d":case"i":case"u":t=a.toString();break;case"o":t=a.toString(8);break;case"x":t=a.toString(16);break;case"X":t=a.toString(16).toUpperCase();break;default:t=a.toString()}return i=e.parseInt(i,10)||1,Array(Math.max(0,i-t.length)+1).join("0")+t}))}function Xf(e,t){var n=zf(e,t,"timescale"),i=1;n&&(i=Wt(n)||1),(n=Wt((n=zf(e,t,"duration"))||""))&&(n/=i);var r=zf(e,t,"startNumber"),a=Number(zf(e,t,"presentationTimeOffset"))||0,o=Yt(r||"");if(null!=r&&null!=o||(o=1),r=null,t=Wf(e,t,"SegmentTimeline")){t=Nt(t,"S"),r=i,e=e.ka.duration||1/0;for(var s=o,u=[],l=-a,c=0;c<t.length;++c){var d=t[c],h=t[c+1],f=Ft(d,"t",Yt),p=Ft(d,"d",Yt),g=Ft(d,"r",zt);if(d=Ft(d,"k",zt)||0,null!=f&&(f-=a),p){if(f=null!=f?f:l,0>(g=g||0))if(h){if(null==(h=Ft(h,"t",Yt)))break;if(f>=h)break;g=Math.ceil((h-f)/p)-1}else{if(1/0==e)break;if(f/r>=e)break;g=Math.ceil((e*r-f)/p)-1}for(0<u.length&&f!=l&&(u[u.length-1].end=f/r),h=0;h<=g;++h)l=f+p,u.push({start:f/r,end:l/r,dg:f,Cb:d,Wi:u.length+s}),f=l}}r=u}return{timescale:i,Qa:n,zd:o,Pb:a/i||0,cg:a,timeline:r}}function qf(e,t){return[t(e.J),t(e.ha),t(e.oa)].filter(Gi)}function zf(e,t,n){t=qf(e,t),e=null;for(var i=(t=l(t)).next();!i.done&&!(e=i.value.attributes[n]);i=t.next());return e}function Wf(e,t,n){t=qf(e,t),e=null;for(var i=(t=l(t)).next();!i.done&&!(e=_t(i.value,n));i=t.next());return e}function Yf(e,t,n,i,r,a){if(a=void 0===a?0:a,Vt(e,"http://www.w3.org/1999/xlink","href")){var o=function(e,t,n,i,r,a){for(var o=Vt(e,"http://www.w3.org/1999/xlink","href"),s=Vt(e,"http://www.w3.org/1999/xlink","actuate")||"onRequest",u=l(Object.keys(e.attributes)),c=u.next();!c.done;c=u.next()){var d=(c=c.value).split(":"),h=Rt("http://www.w3.org/1999/xlink");d[0]==h&&delete e.attributes[c]}if(5<=a)return Xr(new De(2,4,4028));if("onLoad"!=s)return Xr(new De(2,4,4027));var f=hi([i],[o]);return r.request(0,aa(f,t)).Ca((function(i){if(!(i=Ct(i.data,e.tagName)))return Xr(new De(2,4,4001,o));for(e.children=[];i.children.length;){var s=i.children.shift();e.children.push(s)}for(var u=(s=l(Object.keys(i.attributes))).next();!u.done;u=s.next())u=u.value,e.attributes[u]=i.attributes[u];return Yf(e,t,n,f[0],r,a+1)}))}(e,t,n,i,r,a);return n&&(o=o.Ca(void 0,(function(){return Yf(e,t,n,i,r,a)}))),o}o=[];for(var s=l(Lt(e)),u=s.next(),c={};!u.done;c={ad:void 0},u=s.next())c.ad=u.value,"urn:mpeg:dash:resolve-to-zero:2013"==Vt(c.ad,"http://www.w3.org/1999/xlink","href")?e.children=e.children.filter(function(e){return function(t){return t!==e.ad}}(c)):"SegmentTimeline"!=c.ad.tagName&&o.push(Yf(c.ad,t,n,i,r,a));return Yr(o).Ca((function(){return e}))}function Jf(e){this.h=ve(e),this.g=new ya(this.h,0)}function $f(e){var t=Qf(e);if(7<t.length)throw new De(2,3,3002);for(var n=0,i=(t=l(t)).next();!i.done;i=t.next())n=256*n+i.value;t=Qf(e);e:{for(var r=(i=l(Zf)).next();!r.done;r=i.next())if(fe(t,new Uint8Array(r.value))){i=!0;break e}i=!1}if(i)t=e.h.byteLength-e.g.ya();else{if(8==t.length&&224&t[1])throw new De(2,3,3001);for(r=i=0;r<t.length;r++){var a=t[r];i=0==r?a&(1<<8-t.length)-1:256*i+a}t=i}return t=e.g.ya()+t<=e.h.byteLength?t:e.h.byteLength-e.g.ya(),i=ve(e.h,e.g.ya(),t),e.g.skip(t),new ep(n,i)}function Qf(e){var t=e.g.ya(),n=e.g.T();if(0==n)throw new De(2,3,3002);return n=8-Math.floor(Math.log2(n)),e.g.skip(n-1),ge(e.h,t,n)}Jf.prototype.sa=function(){return this.g.sa()};var Zf=[[255],[127,255],[63,255,255],[31,255,255,255],[15,255,255,255,255],[7,255,255,255,255,255],[3,255,255,255,255,255,255],[1,255,255,255,255,255,255,255]];function ep(e,t){this.id=e,this.g=t}function tp(e){if(8<e.g.byteLength)throw new De(2,3,3002);if(8==e.g.byteLength&&224&e.g.getUint8(0))throw new De(2,3,3001);for(var t=0,n=0;n<e.g.byteLength;n++)t=256*t+e.g.getUint8(n);return t}function np(e){var t=new Jf(e.g);if(179!=(e=$f(t)).id)throw new De(2,3,3013);if(e=tp(e),183!=(t=$f(t)).id)throw new De(2,3,3012);t=new Jf(t.g);for(var n=0;t.sa();){var i=$f(t);if(241==i.id){n=tp(i);break}}return{hj:e,Mi:n}}function ip(e,t,n){if(!(t=Wf(e,t,"Initialization")))return null;var i=e.J.Oa(),r=t.attributes.sourceURL;r&&(i=hi(i,[vt(r)],e.ob())),r=0;var a=null;return(t=Ft(t,"range",qt))&&(r=t.start,a=t.end),(n=new go((function(){return i}),r,a,up(e),null,null,n)).codecs=e.J.codecs,n.mimeType=e.J.mimeType,n}function rp(e,t,n,i,r,a,o){var s,u,c,d,h,f,p,g,m,v,y,b,T,S,x,A,E,k;return P((function(I){if(1==I.g)return s=e.presentationTimeline,u=!e.xb||!e.ka.uf,c=e.ka.start,d=e.ka.duration,h=e.J.mimeType.split("/")[1],p=null,g=[(f=t)(i,r,a,!1),"webm"==h?f(n.N(),n.Ja,n.va,!0):null],f=null,w(I,Promise.all(g),2);if(m=I.h,v=m[0],y=m[1]||null,T=c-o,S=c,x=d?c+d:1/0,"mp4"==h)var M=function(e,t,n,i,r,a,o){var s,u=(new Ta).R("sidx",(function(e){s=function(e,t,n,i,r,a,o){var s=[];o.reader.skip(4);var u=o.reader.P();if(0==u)throw new De(2,3,3005);if(0==o.version)var l=o.reader.P(),c=o.reader.P();else l=o.reader.Vc(),c=o.reader.Vc();o.reader.skip(2);var d=o.reader.ma();for(e=e+o.size+c,c=0;c<d;c++){var h=o.reader.P(),f=(2147483648&h)>>>31;h&=2147483647;var p=o.reader.P();if(o.reader.skip(4),1==f)throw new De(2,3,3006);s.push(new vo(l/u+n,(l+p)/u+n,(function(){return a}),e,e+h-1,t,n,i,r)),l+=p,e+=h}return o.parser.stop(),s}(t,i,r,a,o,n,e)}));if(e&&u.parse(e),s)return s;throw new De(2,3,3004)}(v,r,i,n,T,S,x);else{M=v;var C=new Jf(y);if(440786851!=$f(C).id)throw new De(2,3,3008);var D=$f(C);if(408125543!=D.id)throw new De(2,3,3009);C=D.g.byteOffset,D=new Jf(D.g);for(var R=null;D.sa();){var P=$f(D);if(357149030==P.id){R=P;break}}if(!R)throw new De(2,3,3010);for(R=new Jf(R.g),P=1e6,D=null;R.sa();){var L=$f(R);if(2807729==L.id)P=tp(L);else if(17545==L.id)if(4==L.g.byteLength)D=L.g.getFloat32(0);else{if(8!=L.g.byteLength)throw new De(2,3,3003);D=L.g.getFloat64(0)}}if(null==D)throw new De(2,3,3011);if(D*=R=P/1e9,475249515!=(M=$f(new Jf(M))).id)throw new De(2,3,3007);M=function(e,t,n,i,r,a,o,s,u){function l(){return r}var c=[];e=new Jf(e.g);for(var d=null,h=null;e.sa();){var f=$f(e);if(187==f.id){var p=np(f);p&&(f=n*p.hj,p=t+p.Mi,null!=d&&c.push(new vo(d+o,f+o,l,h,p-1,a,o,s,u)),d=f,h=p)}}return null!=d&&c.push(new vo(d+o,i+o,l,h,null,a,o,s,u)),c}(M,C,R,D,i,n,T,S,x)}for(A=l(b=M),E=A.next();!E.done;E=A.next())(k=E.value).codecs=e.J.codecs,k.mimeType=e.J.mimeType,k.bandwidth=e.bandwidth;return s.vd(b),p=new Zs(b),u&&p.Kc(S,x,!0),I.return(p)}))}function ap(e){return e.Yc}function op(e){var t=Wf(e,ap,"RepresentationIndex");return e=qt((e=zf(e,ap,"indexRange"))||""),t&&(e=Ft(t,"range",qt,e)),e}function sp(e,t){var n=e.J.mimeType.split("/")[1];if(e.J.contentType!=yi&&"mp4"!=n&&"webm"!=n)throw new De(2,4,4006);if("webm"==n&&!t)throw new De(2,4,4005)}function up(e){var t=e.J;return{bandwidth:e.bandwidth,audioSamplingRate:t.audioSamplingRate,codecs:t.codecs,contentType:t.contentType,frameRate:t.frameRate||null,height:t.height||null,mimeType:t.mimeType,channelsCount:t.ce,pixelAspectRatio:t.pixelAspectRatio||null,width:t.width||null,label:e.ha.label||null,roles:e.roles||null,language:e.ha.language||null}}function lp(e){return e.Rb}function cp(t,n,i,r,a,o,s,u,c){c||t.J.Ud||(t.J.Ud=zf(t,dp,"initialization"));var d=t.J.Ud?function(e,t){var n=e.J.Ud;if(n||(n=zf(e,dp,"initialization")),!n)return null;n=vt(n);var i=e.J.id,r=e.bandwidth||null,a=e.J.Oa,o=e.ob;return t=new go((function(){var e=Kf(n,i,null,null,r,null);return hi(a(),[e],o())}),0,null,up(e),null,null,t),t.codecs=e.J.codecs,t.mimeType=e.J.mimeType,t}(t,s):null,h=function(e){var t=Xf(e,dp),n=zf(e,dp,"media"),i=zf(e,dp,"index"),r=zf(e,dp,"k"),a=0;return r&&(a=parseInt(r,10)),{Qa:t.Qa,timescale:t.timescale,zd:t.zd,Pb:t.Pb,cg:t.cg,timeline:t.timeline,cc:n&&vt(n),md:i,mimeType:e.J.mimeType,codecs:e.J.codecs,bandwidth:e.bandwidth,Di:a}}(t);!function(e){var t=e.md?1:0;if(t+=e.timeline?1:0,0==(t+=e.Qa?1:0))throw new De(2,4,4002);if(1!=t&&(e.md&&(e.timeline=null),e.Qa=null),!e.md&&!e.cc)throw new De(2,4,4002)}(h);var f=It(t);if(h.md)return sp(t,d),{nc:function(){var e=Kf(h.md,f.J.id,null,null,f.bandwidth||null,null);return e=hi(f.J.Oa(),[e]),rp(f,n,d,e,0,null,h.Pb)}};if(h.Qa)return r||"image"===t.ha.contentType||"text"===t.ha.contentType||(i=t.ka.start,r=t.oa.id,c=t.ka.duration,r=(r=null!=r&&o[r]||c)?i+r:1/0,t.presentationTimeline.Bf(h.Qa),t.presentationTimeline.Qg(i,r)),{nc:function(){return function(t,n,i,r,a,o,s,u){function c(i){var a=(i-y)*v,s=a+n.Pb,l=a+p;a=l+v;var c=Math.min(a,h()),d=[],f=n.Di;if(f)for(var g=(c-l)/f,m={},k=0;k<f;m={mh:void 0},k++){var I=l+g*k,M=I+g;m.mh=k+1,(m=new vo(I,M,function(t){return function(){var n=s*b;return"BigInt"in e&&n>Number.MAX_SAFE_INTEGER&&(n=BigInt(s)*BigInt(b)),n=Kf(w,S,i,t.mh,T,n),hi(x(),[n],A())}}(m),0,null,r,E,p,h(),[],"",null,null,bo,o)).codecs=t.J.codecs,m.mimeType=t.J.mimeType,0==u?0<k&&m.Pc():0!=k%u&&m.Pc(),d.push(m)}return(l=new vo(l,c,(function(){if(f)return[];var t=s*b;return"BigInt"in e&&t>Number.MAX_SAFE_INTEGER&&(t=BigInt(s)*BigInt(b)),t=Kf(w,S,i,null,T,t),hi(x(),[t],A())}),0,null,r,E,p,h(),d,"",null,null,bo,o,0<d.length)).codecs=t.J.codecs,l.mimeType=t.J.mimeType,l.bandwidth=t.bandwidth,l.j=a,l}function d(){var e=[Math.max(f.qb(),p),Math.min(f.Yb(),h())].map((function(e){return e-p}));return e=[Math.ceil(e[0]/v),Math.ceil(e[1]/v)-1],t.J.Wa&&e[1]++,e.map((function(e){return e+y}))}function h(){var e=null!=g&&a[g]||m;return e?p+e:1/0}var f=t.presentationTimeline,p=t.ka.start,g=t.oa.id,m=t.ka.duration,v=n.Qa,y=n.zd,b=n.timescale,w=n.cc,T=t.bandwidth||null,S=t.J.id,x=t.J.Oa,A=t.ob,E=p-n.Pb,k=d();i=t.xb?Math.max(k[0],k[1]-i+1):k[0],s=s||k[1],k=[];for(var I=i;I<=s;++I){var M=c(I);k.push(M)}var C=new Zs(k);if(k=f.Yb()<h(),I=f.U(),k||I){var D=Math.max(i,s+1);i=v,t.J.Wa&&(i=.1),C.ue(i,(function(){var e=f.qb();C.Ha(e);var t=l(d());t.next(),t=t.next().value;for(var n=[];D<=t;){var i=c(D);n.push(i),D++}return e>h()&&!n.length?null:n}))}return Promise.resolve(C)}(f,h,a,d,o,s,u,t.J.oe)}};var p=null;r=r=null,t.oa.id&&t.J.id&&(r=i[r=t.oa.id+","+t.J.id])&&(p=r.segmentIndex);var g=t.ka.start,m=t.ka.duration?g+t.ka.duration:1/0,v=!(t.xb&&t.ka.uf);return p?(fp(i=p,h,g,m,v,d),i.Ha(t.presentationTimeline.qb())):p=new hp(h,t.J.id,t.bandwidth,t.J.Oa,t.ob,g,m,d,v,s,t.J.oe),h.timeline&&"image"!==t.ha.contentType&&"text"!==t.ha.contentType&&t.presentationTimeline.Rg(h.timeline,g),r&&t.xb&&(r.segmentIndex=p),{nc:function(){return p instanceof hp&&0==p.getNumReferences()&&fp(p,h,g,m,v,d),Promise.resolve(p)}}}function dp(e){return e.ec}function hp(e,t,n,i,r,a,o,s,u,l,c){Zs.call(this,[]),this.h=e,this.F=t,this.B=n,this.C=i,this.H=r,this.j=a,this.l=o,this.s=s,this.A=l,this.G=c,u&&pp(this)}function fp(e,t,n,i,r,a){if(function(e,t){if(e.s!==t){e.s=t;for(var n=(e=l(e.g)).next();!n.done;n=e.next())(n=n.value)&&yo(n,t)}}(e,a),e.h){if(n=e.h.timeline,e.h.cc!==t.cc&&(e.h.cc=t.cc),n.length){var o=n[n.length-1];t=t.timeline.filter((function(e){return e.end>o.end}))}else t=t.timeline.slice();0<t.length&&e.h.timeline.push.apply(e.h.timeline,c(t)),e.l!==i&&(e.l=i)}else e.h=t,e.j=n,e.l=i;r&&pp(e)}function pp(e){if(!e.o){for(var t=e.h.timeline;t.length&&t[t.length-1].start>=e.l;)t.pop();e.Ha(e.j)}}function gp(e,t,n,i,r,a,o,s){return e=Kf(e,t,n,a,i||null,r),hi(o(),[e],s()).map((function(e){return e.toString()}))}function mp(e){this.o=null,this.A=e,this.G=new ea,this.i=[],this.h=null,this.m=[],this.B=null,this.F=[],this.C=300,this.l=new Map,this.j=new Map,this.g=null,this.s="UNKNOWN"}function vp(e,t){var n,i,r,a,o,s,u;return P((function(l){return 1==l.g?(n=hi(e.i,[yp(e,t)]),i=aa(n,e.o.retryParameters),r=e.A.networkingEngine.request(8,i),ta(e.G,r),S(l,2),w(l,r.promise,4)):2!=l.g?(a=l.h,o=dt(a.data),1==(s=JSON.parse(o)).VERSION&&function(e,t,n){null!=e.g&&(e.g.stop(),e.g=null);var i=t["RELOAD-URI"]||n;e.g=new Be((function(){vp(e,i)})),(n=t.TTL)&&(e.C=n),e.g.$(e.C),e.m=t["PATHWAY-PRIORITY"]||[],e.F=t["PATHWAY-CLONES"]||[]}(e,s,a.uri),A(l,0)):(u=E(l))&&7001==u.code?l.return():(null!=e.g&&(e.g.stop(),e.g=null),e.g=new Be((function(){vp(e,t)})),e.g.$(e.C),void T(l))}))}function yp(e,t){if(!e.m.length)return t;t=new Gn(t);var n=e.B||e.m[0],i=Math.round(e.A.getBandwidthEstimate()),r=t.g;return"DASH"==e.s?(r.add("_DASH_pathway",n),r.add("_DASH_throughput",String(i))):"HLS"==e.s&&(r.add("_HLS_pathway",n),r.add("_HLS_throughput",String(i))),ri(r)&&zn(t,r),t.toString()}function bp(e,t,n,i){var r=e.l.get(t);r||(r=new Map),r.set(n,i),e.l.set(t,r)}function wp(e,t,n){n=void 0!==n&&n,t=e.l.get(t)||new Map;for(var i=[],r=l(e.m),a=r.next(),o={};!a.done;o={Tc:void 0},a=r.next())if(o.Tc=a.value,a=t.get(o.Tc))i.push({Hf:o.Tc,location:a});else if(a=e.F.find(function(e){return function(t){return t.Aj==e.Tc}}(o))){var s=t.get(a["BASE-ID"]);s&&(a["URI-REPLACEMENT"].uh?(Xn(s=new Gn(s),a["URI-REPLACEMENT"].uh),i.push({Hf:o.Tc,location:s.toString()})):i.push({Hf:o.Tc,location:s}))}for(r=Date.now(),a=(o=l(e.j.keys())).next();!a.done;a=o.next())a=a.value,r>(s=e.j.get(a))&&e.j.delete(a);if(i=i.filter((function(t){for(var n=l(e.j.keys()),i=n.next();!i.done;i=n.next())if(i.value.includes(new Gn(t.location).Fb))return!1;return!0})),i.length&&(e.B=i[0].Hf),i=i.map((function(e){return e.location})),!i.length&&e.h)for(o=(r=l(e.h.split(","))).next();!o.done;o=r.next())(o=t.get(o.value))&&(e.B=e.h,i.push(o));if(!i.length)for(r=(t=l(t.values())).next();!r.done;r=t.next())i.push(r.value);return n?i:hi(e.i,i)}function Tp(){this.l=[],this.h=[],this.g=[],this.j=[],this.i=[],this.s=this.o=!1,this.m=new Set}function Sp(e,t){for(var n=[],i=[],r=[],a=[],o=(e=l(e)).next();!o.done;o=e.next()){var s=o.value;o=new Map(s.audioStreams.map((function(e){return[Wp(e),e]})));var u=new Map(s.videoStreams.map((function(e){return[zp(e),e]}))),c=new Map(s.textStreams.map((function(e){return[Yp(e),e]})));if(s=new Map(s.imageStreams.map((function(e){return[Jp(e),e]}))),t){var d=Gp(yi);c.set(Yp(d),d),d=Gp("image"),s.set(Jp(d),d)}n.push(o),i.push(u),r.push(c),a.push(s)}return{lg:n,sh:i,oh:r,Hg:a}}function xp(e){var t,n,i,r,a,o,s,u,c,d,h,f,p,g,m,v,y,b,T,S,x,A,E,k,I,M,C,D,R;return P((function(P){switch(P.g){case 1:if(t=bi,1==e.length)return P.return(e[0]);for(n=e.map((function(e){return new Map(e.filter((function(e){return e.type===t.V})).map((function(e){return[Wp(e),e]})))})),i=e.map((function(e){return new Map(e.filter((function(e){return e.type===t.la})).map((function(e){return[zp(e),e]})))})),r=e.map((function(e){return new Map(e.filter((function(e){return e.type===t.wa})).map((function(e){return[Yp(e),e]})))})),a=e.map((function(e){return new Map(e.filter((function(e){return e.type===t.He})).map((function(e){return[Jp(e),e]})))})),o=l(r),s=o.next();!s.done;s=o.next())u=s.value,c=Hp(t.wa),u.set(Yp(c),c);for(d=l(a),h=d.next();!h.done;h=d.next())f=h.value,p=Hp(t.He),f.set(Jp(p),p);return w(P,Ap(g=new Tp,[],n,0,Cp,Rp,0),2);case 2:return m=P.h,w(P,Ap(g,[],i,0,Cp,Rp,0),3);case 3:return v=P.h,w(P,Ap(g,[],r,0,Cp,Rp,0),4);case 4:return y=P.h,w(P,Ap(g,[],a,0,Cp,Rp,0),5);case 5:if(b=P.h,T=0,v.length&&m.length)for(E=l(m),k=E.next();!k.done;k=E.next())for(I=k.value,M=l(v),C=M.next();!C.done;C=M.next())D=C.value,R=T++,D.variantIds.push(R),I.variantIds.push(R);else for(S=v.concat(m),x=l(S),A=x.next();!A.done;A=x.next())A.value.variantIds=[T++];return P.return(v.concat(m).concat(y).concat(b))}}))}function Ap(e,t,n,i,r,a,o){var s,u,c,d,h,f,p,g,m,v,y,b,T,S,x,A,E,k;return P((function(I){switch(I.g){case 1:for(s=[],u=0;u<n.length;u++)u>=i?s.push(new Set(n[u].values())):s.push(new Set);c=l(t),d=c.next();case 2:if(d.done){I.u(4);break}return h=d.value,w(I,function(e,t,n,i,r,a,o){return P((function(s){return 1==s.g?(Pp(e,n,t,0<o),t.matchedStreams?t.segmentIndex?w(s,Ep(t,i+o),2):s.u(2):s.return(!1)):(Ip(t,i,r,a,o),s.return(!0))}))}(e,h,n,i,a,s,o),5);case 5:if(!I.h)throw new De(2,4,4037);d=c.next(),I.u(2);break;case 4:for(f=l(s),p=f.next();!p.done;p=f.next())for(g=p.value,m=l(g),v=m.next();!v.done;v=m.next())y=v.value,(b=kp(e,y,n,r,a,s))&&t.push(b);for(T=l(s),S=T.next();!S.done;S=T.next())for(x=S.value,A=l(x),E=A.next(),k={};!E.done;k={Wf:void 0},E=A.next())if(k.Wf=E.value,!qp(k.Wf)&&t.some(function(t){return function(n){return jp(e,t.Wf,n)}}(k)))throw new De(2,4,4037);return I.return(t)}}))}function Ep(e,t){var n,i,r,a,o,s;return P((function(u){if(1==u.g){for(n=[],i=e.matchedStreams,r=t;r<i.length;r++)a=i[r],n.push(a.createSegmentIndex()),a.trickModeVideo&&!a.trickModeVideo.segmentIndex&&n.push(a.trickModeVideo.createSegmentIndex());return w(u,Promise.all(n),2)}if(e.segmentIndex instanceof iu)for(o=t;o<i.length;o++)(s=i[o]).segmentIndex&&e.segmentIndex.h.push(s.segmentIndex);T(u)}))}function kp(e,t,n,i,r,a){if(qp(t))return null;var o=i(t);return Pp(e,n,o),o.createSegmentIndex&&(o.createSegmentIndex=function(){return P((function(e){return o.segmentIndex?e.u(0):(o.segmentIndex=new iu,w(e,Ep(o,0),0))}))}),o.matchedStreams&&o.matchedStreams.length?(Ip(o,0,r,a,0),o):null}function Ip(e,t,n,i,r){var a=e.matchedStreams;for(t+=r;t<a.length;t++){var o=a[t];n(e,o);var s=!0;if("audio"==e.type&&0==Ji(e.language,o.language)&&(s=!1),s&&(i[t-r].delete(o),o.fullMimeTypes))for(s=(o=l(o.fullMimeTypes.values())).next();!s.done;s=o.next())e.fullMimeTypes.add(s.value)}}function Mp(e){var t=Object.assign({},e);return t.originalId=null,t.createSegmentIndex=function(){return Promise.resolve()},t.closeSegmentIndex=function(){if(t.segmentIndex&&(t.segmentIndex.release(),t.segmentIndex=null),t.matchedStreams)for(var e=l(t.matchedStreams),n=e.next();!n.done;n=e.next())(n=n.value).segmentIndex&&(n.segmentIndex.release(),n.segmentIndex=null)},t.roles=t.roles.slice(),t.segmentIndex=null,t.emsgSchemeIdUris=[],t.keyIds=new Set,t.closedCaptions=e.closedCaptions?new Map(e.closedCaptions):null,t.trickModeVideo=null,t}function Cp(e){var t=Object.assign({},e);return t.roles=t.roles.slice(),t.keyIds=new Set,t.segments=[],t.variantIds=[],t.closedCaptions=e.closedCaptions?new Map(e.closedCaptions):null,t}function Dp(e,t){function n(e,t){e||(e=[]);for(var n=(t=l(t)).next();!n.done;n=t.next())n=n.value,e.includes(n)||e.push(n);return e}e.roles=n(e.roles,t.roles),t.emsgSchemeIdUris&&(e.emsgSchemeIdUris=n(e.emsgSchemeIdUris,t.emsgSchemeIdUris));for(var i=l(t.keyIds),r=i.next();!r.done;r=i.next())e.keyIds.add(r.value);if(null==e.originalId?e.originalId=t.originalId:(i=t.originalId||"")&&!e.originalId.endsWith(i)&&(e.originalId+=","+i),i=Ne(e.drmInfos,t.drmInfos),t.drmInfos.length&&e.drmInfos.length&&!i.length)throw new De(2,4,4038);if(e.drmInfos=i,e.encrypted=e.encrypted||t.encrypted,t.closedCaptions)for(e.closedCaptions||(e.closedCaptions=new Map),r=(i=l(t.closedCaptions)).next();!r.done;r=i.next()){var a=l(r.value);r=a.next().value,a=a.next().value,e.closedCaptions.set(r,a)}e.bandwidth&&t.bandwidth&&(e.bandwidth=Math.max(e.bandwidth,t.bandwidth)),t.trickModeVideo?(e.trickModeVideo||(e.trickModeVideo=Mp(t.trickModeVideo),e.trickModeVideo.matchedStreams=[],e.trickModeVideo.createSegmentIndex=function(){if(e.trickModeVideo.segmentIndex)return Promise.resolve();for(var t=new iu,n=l(e.trickModeVideo.matchedStreams),i=n.next();!i.done;i=n.next())t.h.push(i.value.segmentIndex);return e.trickModeVideo.segmentIndex=t,Promise.resolve()}),e.trickModeVideo.matchedStreams.push(t.trickModeVideo),Dp(e.trickModeVideo,t.trickModeVideo)):e.trickModeVideo&&(e.trickModeVideo.matchedStreams.push(t),Dp(e.trickModeVideo,t))}function Rp(e,t){var n=e.roles;n||(n=[]);for(var i=l(t.roles),r=i.next();!r.done;r=i.next())r=r.value,n.includes(r)||n.push(r);for(e.roles=n,i=(n=l(t.keyIds)).next();!i.done;i=n.next())e.keyIds.add(i.value);if(e.encrypted=e.encrypted&&t.encrypted,e.segments.push.apply(e.segments,c(t.segments)),t.closedCaptions)for(e.closedCaptions||(e.closedCaptions=new Map),n=(t=l(t.closedCaptions)).next();!n.done;n=t.next())n=(i=l(n.value)).next().value,i=i.next().value,e.closedCaptions.set(n,i)}function Pp(e,t,n,i){i=void 0!==i&&i?n.matchedStreams:[];for(var r=(t=l(t)).next();!r.done;r=t.next()){if(!(r=Lp(e,r.value,n)))return;i.push(r)}n.matchedStreams=i}function Lp(e,t,n){var i={audio:Wp,video:zp,text:Yp,image:Jp}[n.type],r=null,a=i(n);if(t.has(a))r=t.get(a);else{a={audio:function(t,n){return jp(e,t,n)},video:function(t,n){return jp(e,t,n)},text:Op,image:Up}[n.type];for(var o={audio:_p,video:Bp,text:Fp,image:Vp}[n.type],s=l(t.values()),u=s.next();!u.done;u=s.next())!a(n,u=u.value)||n.fastSwitching!=u.fastSwitching||r&&!o(n,r,u)||(r=u)}return e.s&&!qp(r)&&t.delete(i(r)),r}function Np(e,t){return e.mimeType==t.mimeType&&$p(e.codecs)===$p(t.codecs)}function jp(e,t,n){return!(!Np(t,n)&&!e.o||t.drmInfos&&!Le(t.drmInfos,n.drmInfos))}function Op(e,t){return!t.language||e.forced===t.forced&&0!=Ji(e.language,t.language)&&t.kind==e.kind}function Up(){return!0}function _p(e,t,n){var i=Np(e,t),r=Np(e,n);if(i&&!r)return!1;if(!i&&r)return!0;if(i=Ji(e.language,t.language),(r=Ji(e.language,n.language))>i)return!0;if(r<i)return!1;if(t.label!==n.label){if(e.label===t.label)return!1;if(e.label===n.label)return!0}if(e.roles.length){if(i=t.roles.filter((function(t){return e.roles.includes(t)})),(r=n.roles.filter((function(t){return e.roles.includes(t)}))).length>i.length)return!0;if(r.length<i.length)return!1;if(n.roles.length!==t.roles.length)return n.roles.length<t.roles.length}else{if(!n.roles.length&&t.roles.length)return!0;if(n.roles.length&&!t.roles.length)return!1}return!(t.primary||!n.primary)||!(t.primary&&!n.primary)&&((i=Kp(e.channelsCount,t.channelsCount,n.channelsCount))==Qp||i!=eg&&((i=Kp(e.audioSamplingRate,t.audioSamplingRate,n.audioSamplingRate))==Qp||i!=eg&&!(!e.bandwidth||Xp(e.bandwidth,t.bandwidth,n.bandwidth)!=Qp)))}function Bp(e,t,n){var i=Np(e,t),r=Np(e,n);if(i&&!r)return!1;if(!i&&r)return!0;if((i=Kp(e.width*e.height,t.width*t.height,n.width*n.height))==Qp)return!0;if(i==eg)return!1;if(e.frameRate){if((i=Kp(e.frameRate,t.frameRate,n.frameRate))==Qp)return!0;if(i==eg)return!1}return!(!e.bandwidth||Xp(e.bandwidth,t.bandwidth,n.bandwidth)!=Qp)}function Fp(e,t,n){var i=Ji(e.language,t.language),r=Ji(e.language,n.language);if(r>i)return!0;if(r<i)return!1;if(!t.primary&&n.primary)return!0;if(t.primary&&!n.primary)return!1;if(t.label!==n.label){if(e.label===t.label)return!1;if(e.label===n.label)return!0}if(e.roles.length){if(i=t.roles.filter((function(t){return e.roles.includes(t)})),(r=n.roles.filter((function(t){return e.roles.includes(t)}))).length>i.length)return!0;if(r.length<i.length)return!1}else{if(!n.roles.length&&t.roles.length)return!0;if(n.roles.length&&!t.roles.length)return!1}return n.mimeType==e.mimeType&&n.codecs==e.codecs&&(t.mimeType!=e.mimeType||t.codecs!=e.codecs)}function Vp(e,t,n){return Kp(e.width*e.height,t.width*t.height,n.width*n.height)==Qp}function Hp(e){return{id:0,originalId:"",groupId:null,primary:!1,type:e,mimeType:"",codecs:"",language:"",originalLanguage:null,label:null,width:null,height:null,encrypted:!1,keyIds:new Set,segments:[],variantIds:[],roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,external:!1,fastSwitching:!1,isAudioMuxedInVideo:!1}}function Gp(e){return{id:0,originalId:"",groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Zs([]),mimeType:"",codecs:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"",originalLanguage:null,label:null,type:e,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set,isAudioMuxedInVideo:!1}}function Kp(e,t,n){if(t==e&&e!=n)return eg;if(n==e&&e!=t)return Qp;if(t>e){if(n<=e||n-e<t-e)return Qp;if(n-e>t-e)return eg}else{if(n>e)return eg;if(e-n<e-t)return Qp;if(e-n>e-t)return eg}return Zp}function Xp(e,t,n){return t=Math.abs(e-t),(e=Math.abs(e-n))<t?Qp:t<e?eg:Zp}function qp(e){switch(e.type){case yi:return!e.language;case"image":return!e.tilesLayout;default:return!1}}function zp(e){return JSON.stringify([e.fastSwitching,e.width,e.frameRate,$p(e.codecs),e.mimeType,e.label,e.roles,e.closedCaptions?Array.from(e.closedCaptions.entries()):null,e.bandwidth])}function Wp(e){return JSON.stringify([e.fastSwitching,e.channelsCount,e.language,e.bandwidth,e.label,$p(e.codecs),e.mimeType,e.roles,e.audioSamplingRate,e.primary])}function Yp(e){return JSON.stringify([e.language,e.label,e.codecs,e.mimeType,e.bandwidth,e.roles])}function Jp(e){return JSON.stringify([e.width,e.codecs,e.mimeType])}function $p(e){if(!tg.has(e)){var t=Mi(e);tg.set(e,t)}return tg.get(e)}m(hp,Zs),(i=hp.prototype).getNumReferences=function(){return this.h?this.h.timeline.length:0},i.release=function(){Zs.prototype.release.call(this),this.h=null},i.Ha=function(e){if(this.h){for(var t=0,n=this.h.timeline,i=0;i<n.length&&n[i].end+this.j<=e;i+=1)t+=1;0<t&&(this.h.timeline=n.slice(t),this.g.length>=t&&(this.g=this.g.slice(t)),this.i+=t,0===this.getNumReferences()&&this.release())}},i.find=function(e){if(this.h&&this.h.timeline&&this.h.timeline.length&&e<this.h.timeline[0].start+this.j)return this.i;if(!this.h)return null;var t=this.h.timeline;if(e<this.j||e>=this.l)return null;for(var n=t.length-1,i=0;i<t.length;i++){var r=t[i],a=r.start+this.j;if(r=i<n?t[i+1].start+this.j:1/0===this.l?r.end+this.j:this.l,e>=a&&e<r)return i+this.i}return null},i.get=function(e){var t=this;if(0>(e-=this.i)||e>=this.getNumReferences()||!this.h)return null;var n=this.g[e];if(!n){var i=this.h.timeline[e],r=i.Wi,a=this.h.cg+i.dg;n=this.j-this.h.Pb;var o=this.j+i.end,s=o;e===this.getNumReferences()-1&&1/0!==this.l&&(s=this.l);for(var u=this.h.codecs,l=this.h.mimeType,c=this.h.bandwidth,d=[],h=(i.end-i.start)/i.Cb,f={},p=0;p<i.Cb;f={we:void 0,nh:void 0},p++){var g=i.start+h*p,m=g+h;f.nh=p+1,f.we=null,(f=new vo(this.j+g,this.j+m,function(e){return function(){return t.h?(null==e.we&&(e.we=gp(t.h.cc,t.F,r,t.B,a,e.nh,t.C,t.H)),e.we):[]}}(f),0,null,this.s,n,this.j,this.l,[],"",null,null,bo,this.A)).codecs=u,f.mimeType=l,f.bandwidth=c,0==this.G?0<p&&f.Pc():0!=p%this.G&&f.Pc(),d.push(f)}(n=new vo(this.j+i.start,s,(function(){return 0<i.Cb||!t.h?[]:gp(t.h.cc,t.F,r,t.B,a,null,t.C,t.H)}),0,null,this.s,n,this.j,this.l,d,"",null,null,bo,this.A,0<i.Cb)).codecs=u,n.mimeType=l,n.j=o,n.bandwidth=c,this.g[e]=n}return n},i.yb=function(e){pp(this);for(var t=0;t<this.getNumReferences();t++){var n=this.get(t+this.i);n&&e(n)}},mp.prototype.configure=function(e){this.o=e},mp.prototype.destroy=function(){return this.A=this.o=null,this.i=[],this.h=null,this.m=[],this.F=[],this.l.clear(),null!=this.g&&(this.g.stop(),this.g=null),this.G.destroy()},mp.prototype.setManifestType=function(e){this.s=e},mp.prototype.banLocation=function(e){this.j.set(e,Date.now()+6e4)},(i=Tp.prototype).release=function(){for(var e=l(this.h.concat(this.g,this.j,this.i)),t=e.next();!t.done;t=e.next())(t=t.value).segmentIndex&&t.segmentIndex.release();this.h=[],this.g=[],this.j=[],this.i=[],this.l=[],this.s=this.o=!1,this.m.clear()},i.ii=function(){return this.l},i.mf=function(){return this.j.slice()},i.Rh=function(){return this.i},i.sg=function(e,t){if(e){if("audio"==e.type)for(var n=l(this.h),i=n.next();!i.done;i=n.next())(i=i.value).matchedStreams=i.matchedStreams.filter((function(t){return t!==e}));else if("video"==e.type)for(i=(n=l(this.g)).next();!i.done;i=n.next())(i=i.value).matchedStreams=i.matchedStreams.filter((function(t){return t!==e})),i.trickModeVideo&&(i.trickModeVideo.matchedStreams=i.trickModeVideo.matchedStreams.filter((function(t){return t!==e})));else if(e.type==yi)for(i=(n=l(this.j)).next();!i.done;i=n.next())(i=i.value).matchedStreams=i.matchedStreams.filter((function(t){return t!==e}));else if("image"==e.type)for(i=(n=l(this.i)).next();!i.done;i=n.next())(i=i.value).matchedStreams=i.matchedStreams.filter((function(t){return t!==e}));e.segmentIndex&&e.closeSegmentIndex(),this.m.delete(t)}},i.Ne=function(e,t,n){n=void 0!==n&&n;var i,r,a,o,s,u,c,d,h,f,p,g,m,v,y,b,S,x,A,E,k,I,M,C,D,R,L,N,j,O,U=this;return P((function(P){if(1==P.g){if(i=bi,!t&&1==e.length)return r=Sp(e,!1),a=r.lg,o=r.sh,s=r.oh,u=r.Hg,U.h=Array.from(a[0].values()),U.g=Array.from(o[0].values()),U.j=Array.from(s[0].values()),U.i=Array.from(u[0].values()),P.u(2);for(c=n?U.m.size:0,d=-1,h=0;h<e.length;h++)f=e[h],U.m.has(f.id)||(U.m.add(f.id),-1==d&&(d=h));return-1==d?P.return():(p=Sp(e,!0),g=p.lg,m=p.sh,v=p.oh,y=p.Hg,w(P,Promise.all([Ap(U,U.h,g,d,Mp,Dp,c),Ap(U,U.g,m,d,Mp,Dp,c),Ap(U,U.j,v,d,Mp,Dp,c),Ap(U,U.i,y,d,Mp,Dp,c)]),2))}if(b=0,S=[],U.g.length&&U.h.length)for(M=l(U.h),C=M.next();!C.done;C=M.next())for(D=C.value,R=l(U.g),L=R.next();!L.done;L=R.next())N=L.value,j=Ne(D.drmInfos,N.drmInfos),D.drmInfos.length&&N.drmInfos.length&&!j.length||(O=b++,S.push({id:O,language:D.language,disabledUntilTime:0,primary:D.primary,audio:D,video:N,bandwidth:(D.bandwidth||0)+(N.bandwidth||0),drmInfos:j,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]}));else for(x=U.g.length?U.g:U.h,A=l(x),E=A.next();!E.done;E=A.next())k=E.value,I=b++,S.push({id:I,language:k.language,disabledUntilTime:0,primary:k.primary,audio:k.type==i.V?k:null,video:k.type==i.la?k:null,bandwidth:k.bandwidth||0,drmInfos:k.drmInfos,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});U.l=S,T(P)}))},i.bh=function(e){this.o=e},i.ih=function(e){this.s=e},F("shaka.util.PeriodCombiner",Tp),Tp.prototype.setUseStreamOnce=Tp.prototype.ih,Tp.prototype.setAllowMultiTypeVariants=Tp.prototype.bh,Tp.prototype.combinePeriods=Tp.prototype.Ne,Tp.prototype.deleteStream=Tp.prototype.sg,Tp.prototype.getImageStreams=Tp.prototype.Rh,Tp.prototype.getTextStreams=Tp.prototype.mf,Tp.prototype.getVariants=Tp.prototype.ii;var Qp=1,Zp=0,eg=-1,tg=new Map;function ng(e,t){try{return function(e,t){var n=new DOMParser,i=ig.value()(e);e=null;try{e=n.parseFromString(i,"text/xml")}catch(e){return null}if(!(n=e.documentElement)||n.getElementsByTagName("parsererror").length||n.tagName!=t)return null;if(!("createNodeIterator"in document))return n;for(t=document.createNodeIterator(e,NodeFilter.SHOW_ALL);e=t.nextNode();)if(e instanceof HTMLElement||e instanceof SVGElement)return null;return n}(ft(e),t)}catch(e){return null}}var ig=new Pe((function(){if("undefined"!=typeof trustedTypes){var e=trustedTypes.createPolicy("shaka-player#xml",{createHTML:function(e){return e}});return function(t){return e.createHTML(t)}}return function(e){return e}}));function rg(){var e=this;this.j=this.g=null,this.A=[],this.i=null,this.na=1,this.F=[],this.l={ae:"",type:"",profiles:[],Mb:null,Wa:0,Oa:null,xd:0},this.s=new Map,this.o={},this.B={},this.ja={},this.m=new Tp,this.K=0,this.ra=new G(5),this.L=new Be((function(){e.I&&!e.g.continueLoadingWhenPaused&&(e.G.cb(e.I,"timeupdate"),e.I.paused)?e.G.pa(e.I,"timeupdate",(function(){return yg(e)})):yg(e)})),this.S=new ea,this.O=null,this.C=[],this.da=1/0,this.H=!1,this.h=null,this.M=0,this.ga=!1,this.G=new Z,this.I=null,this.Y=!1,this.aa="",this.fa=function(){return!1},this.Z=[]}function ag(e){var t,n,i,r,a,o,s,u,d,h,f;return P((function(p){return 1==p.g?(t=4,n="MPD",i=function(e){var t=e.l.xd;if(!e.l.ae||!t||!e.F.length)return[];var n=Date.now()/1e3,i=e.F.filter((function(e){return!(e=Yt(e.attributes.ttl))||t+e>n})).map(Ot).filter(Gi);return i.length?hi(e.A,i):[]}(e),r=e.A,i.length?(r=i,n="Patch",t=6):1<e.A.length&&e.h&&(a=wp(e.h,"Location",!0)).length&&(r=a),o=aa(r,e.g.retryParameters),s=Date.now(),w(p,Eg(e,o,0,{type:t}),2)):3!=p.g?(u=p.h,e.j?(u.uri&&u.uri!=u.originalUri&&!e.A.includes(u.uri)&&e.A.unshift(u.uri),d=new Gn(u.uri),e.aa=d.g.toString(),w(p,function(e,t,n,i){var r,a,o,s,u,d,h,f;return P((function(p){if(1==p.g){if(r=t,(a=e.g.dash.manifestPreprocessor)!=dl){if(oe("manifest.dash.manifestPreprocessor configuration","Please Use manifest.dash.manifestPreprocessorTXml instead."),!(o=ng(r,i)))throw new De(2,4,4001,n);a(o),r=pt(o.outerHTML)}if(!(s=Ct(r,i)))throw new De(2,4,4001,n);return(u=e.g.dash.manifestPreprocessorTXml)!=hl&&u(s),"Patch"===i?p.return(function(e,t){var n,i,r,a,o,s,u,d,h,f,p,g,m,v,y,b,S,x,A,E,k,I,M,C;return P((function(D){if(1==D.g){if(n=t.attributes.mpdId,i=Ft(t,"originalPublishTime",Kt),!n||n!==e.l.ae||i!==e.l.xd)throw e.F=[],new De(1,4,4052);for(r=[],a=[],o=new Set,s=l(Lt(t)),u=s.next();!u.done;u=s.next())if(d=u.value,h=Zt(d.attributes.sel||""),f=h[h.length-1],p=Ot(d)||"","MPD"===f.name)if("mediaPresentationDuration"===f.Ub){var R=Xt(Ot(d)||"");if(null!=R){e.l.Mb=R;for(var P=l(e.s.values()),L=P.next();!L.done;L=P.next())L.value.Mb=R}}else if("type"===f.Ub){for(e.i.presentationTimeline.Bc("static"==p),e.l.type=p,P=(R=l(e.s.values())).next();!P.done;P=R.next())P.value.xb="dynamic"==p;"static"==p&&(e.K=-1)}else"publishTime"===f.Ub?e.l.xd=Kt(p)||0:null===f.Ub&&"add"===d.tagName&&a.push(d);else if("PatchLocation"===f.name)en(e.F,d);else if("Period"===f.name)"add"===d.tagName?a.push(d):"remove"===d.tagName&&f.id&&lg(e,f.id);else if("SegmentTemplate"===f.name){if((R=(P=Zt(d.attributes.sel||""))[P.length-1]).Ub){P=cg(e,P),L=Ot(d)||"";for(var N=l(P),j=N.next();!j.done;j=N.next())nn((j=e.s.get(j.value)).J.ec,d.tagName,R.Ub,L);R=P}else R=[];for(g=l(R),m=g.next();!m.done;m=g.next())v=m.value,o.add(v)}else if("SegmentTimeline"===f.name||"S"===f.name){for(R=Zt(d.attributes.sel||""),L=(P=l(R=cg(e,R))).next();!L.done;L=P.next())en(N=Nt(L=Wf(L=e.s.get(L.value),dp,"SegmentTimeline"),"S"),d),L.children=N;for(y=l(R),b=y.next();!b.done;b=y.next())S=b.value,o.add(S)}for(x=l(o),A=x.next();!A.done;A=x.next())E=A.value,dg(e,E);for(k=l(a),I=k.next();!I.done;I=k.next())M=I.value,r.push.apply(r,c(ug(e,M)));return r.length?(e.i.periodCount+=r.length,e.i.gapCount=e.M,w(D,sg(e,r,!0),2)):D.u(2)}"static"==e.l.type&&(C=e.l.Mb,e.i.presentationTimeline.bb(C||1/0)),T(D)}))}(e,s)):e.g.dash.disableXlinkProcessing?p.return(og(e,s,n)):(d=e.g.dash.xlinkFailGracefully,h=Yf(s,e.g.retryParameters,d,n,e.j.networkingEngine),ta(e.S,h),w(p,h.promise,2))}return f=p.h,p.return(og(e,f,n))}))}(e,u.data,u.uri,n),3)):p.return(0)):(h=Date.now(),f=(h-s)/1e3,e.ra.sample(1,f),p.return(f))}))}function og(e,t,n){var i,r,a,o,s,u,c,d,h,f,p,g,m,v,y,b,x,k,I,M,C,D,R,L,N,j,O,U,_,B,F,V,H,G,K,X,q,z,Y,J,$,Q,Z,ee,te,ne,ie,re,ae,oe,se;return P((function(ue){switch(ue.g){case 1:for(e.h&&e.h.l.clear(),i=[n],r=[],a=new Map,o=Nt(t,"Location"),s=l(o),u=s.next();!u.done;u=s.next())c=u.value,d=c.attributes.serviceLocation,(h=Ot(c))&&(f=hi(i,[h])[0],d&&(e.h?bp(e.h,"Location",d,f):a.set(d,f)),r.push(f));if(e.h?0<(p=wp(e.h,"Location",!0)).length&&(i=e.A=p):r.length&&(i=e.A=r),e.l.ae=t.attributes.id||"",e.l.xd=Ft(t,"publishTime",Kt)||0,e.F=Nt(t,"PatchLocation"),g=Promise.resolve(),(m=_t(t,"ContentSteering"))&&e.j)for(v=m.attributes.defaultServiceLocation,e.h?(e.h.i=i,e.h.h=v):(e.h=new mp(e.j),e.h.configure(e.g),e.h.setManifestType("DASH"),e.h.i=i,e.h.h=v,(y=Ot(m))&&(Ft(m,"queryBeforeStart",$t,!1)?g=vp(e.h,y):vp(e.h,y))),b=l(a.keys()),x=b.next();!x.done;x=b.next())k=x.value,I=a.get(k),bp(e.h,"Location",k,I);if(M=Nt(t,"BaseURL"),C=!1,e.h)for(D=l(M),R=D.next();!R.done;R=D.next())L=R.value,N=L.attributes.serviceLocation,j=Ot(L),N&&j&&(bp(e.h,"BaseURL",N,j),C=!0);if(e.Z=null,C&&e.h||(O=M.map(Ot),e.Z=hi(i,O)),U=function(){return e.h&&C?wp(e.h,"BaseURL"):e.Z?e.Z:[]},e.l.Oa=U,_=0,M&&M.length&&(_=Ft(M[0],"availabilityTimeOffset",Jt)||0),e.l.Wa=_,B=e.g.dash.ignoreMinBufferTime,F=0,B||(F=Ft(t,"minBufferTime",Xt)||0),e.K=Ft(t,"minimumUpdatePeriod",Xt,-1),V=Ft(t,"availabilityStartTime",Kt),H=Ft(t,"timeShiftBufferDepth",Xt),G=e.g.dash.ignoreSuggestedPresentationDelay,K=null,G||(K=Ft(t,"suggestedPresentationDelay",Xt)),X=e.g.dash.ignoreMaxSegmentDuration,q=null,X||(q=Ft(t,"maxSegmentDuration",Xt)),z=t.attributes.type||"static",e.i&&e.i.presentationTimeline&&(e.Y=e.i.presentationTimeline.U()&&"static"==z),e.l.type=z,e.i)for(Y=e.i.presentationTimeline,J=l(Object.values(e.o)),$=J.next();!$.done;$=J.next())(Q=$.value).segmentIndex&&Q.segmentIndex.Ha(Y.qb());else Z=e.g.defaultPresentationDelay||1.5*F,Y=new Ls(V,null!=K?K:Z,e.g.dash.autoCorrectDrift);return Y.Bc("static"==z),Y.U()&&!isNaN(e.g.availabilityWindowOverride)&&(H=e.g.availabilityWindowOverride),null==H&&(H=1/0),Y.pe(H),ee=t.attributes.profiles||"",e.l.profiles=ee.split(","),te={xb:"static"!=z,presentationTimeline:Y,oa:null,ka:null,ha:null,J:null,bandwidth:0,pf:!1,Wa:_,Mb:null,profiles:ee.split(","),roles:null,ob:function(){return""}},e.M=0,ne=pg(e,te,U,t,!1),ie=ne.duration,re=ne.periods,("static"!=z||e.Y)&&ne.ug||Y.bb(ie||1/0),e.ga&&!e.H&&e.j.isAutoLowLatencyMode()&&(e.j.enableLowLatencyMode(),e.H=e.j.isLowLatencyMode()),e.H&&Y.dh(e.da),Y.Bf(q||1),w(ue,g,2);case 2:return e.H&&(F=0,ae=null!=K?K:e.g.defaultPresentationDelay,Y.Sf(ae)),e.i?(e.i.periodCount=re.length,e.i.gapCount=e.M,w(ue,sg(e,re,!1),4)):w(ue,e.m.Ne(re,te.xb),6);case 6:if(e.i={presentationTimeline:Y,variants:e.m.l,textStreams:e.m.mf(),imageStreams:e.m.i,offlineSessionIds:[],minBufferTime:F||0,sequenceMode:e.g.dash.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,type:"DASH",serviceDescription:hg(t),nextUrl:fg(t),periodCount:re.length,gapCount:e.M,isLowLatency:e.ga,startTime:null},!Y.qh()){ue.u(7);break}return oe=Nt(t,"UTCTiming"),w(ue,function(e,t,n){var i,r,a,o,s,u,c,d;return P((function(h){switch(h.g){case 1:i=n.map((function(e){return{scheme:e.attributes.schemeIdUri,value:e.attributes.value}})),r=e.g.dash.clockSyncUri,!i.length&&r&&i.push({scheme:"urn:mpeg:dash:utc:http-head:2014",value:r}),a=l(i),o=a.next();case 2:if(o.done){h.u(4);break}switch(s=o.value,S(h,5),u=s.scheme,c=s.value,u){case"urn:mpeg:dash:utc:http-head:2014":case"urn:mpeg:dash:utc:http-head:2012":return h.u(7);case"urn:mpeg:dash:utc:http-xsdate:2014":case"urn:mpeg:dash:utc:http-iso:2014":case"urn:mpeg:dash:utc:http-xsdate:2012":case"urn:mpeg:dash:utc:http-iso:2012":return h.u(8);case"urn:mpeg:dash:utc:direct:2014":case"urn:mpeg:dash:utc:direct:2012":return d=Date.parse(c),h.return(isNaN(d)?0:d-Date.now());case"urn:mpeg:dash:utc:http-ntp:2014":case"urn:mpeg:dash:utc:ntp:2014":case"urn:mpeg:dash:utc:sntp:2014":W("NTP UTCTiming scheme is not supported");break;default:W("Unrecognized scheme in UTCTiming element",u)}h.u(9);break;case 7:return w(h,Tg(e,t,c,"HEAD"),10);case 10:return h.return(h.h);case 8:return w(h,Tg(e,t,c,"GET"),11);case 11:return h.return(h.h);case 9:A(h,3);break;case 5:E(h);case 3:o=a.next(),h.u(2);break;case 4:return W("A UTCTiming element should always be given in live manifests! This content may not play on clients with bad clocks!"),h.return(0)}}))}(e,U,oe),8);case 8:if(se=ue.h,!e.j)return ue.return();Y.eh(se);case 7:Y.Xd();case 4:e.j.makeTextStreamsForClosedCaptions(e.i),function(e){for(var t=Object.keys(e.B).filter((function(t){return!e.C.includes(t)})),n=(t=l(t)).next();!n.done;n=t.next()){n=n.value;for(var i=!0,r=l(e.B[n]),a=r.next();!a.done;a=r.next()){a=a.value;var o=e.o[a];o&&(o.segmentIndex&&0!=o.segmentIndex.getNumReferences()?i=!1:(e.m&&e.m.sg(e.o[a],n),delete e.o[a]))}i&&delete e.B[n]}}(e),T(ue)}}))}function sg(e,t,n){var i;return P((function(r){if(1==r.g)return w(r,e.m.Ne(t,!0,n),2);e.i.variants=e.m.l,0<(i=e.m.mf()).length&&(e.i.textStreams=i),e.i.imageStreams=e.m.i,e.j.filter(e.i),T(r)}))}function ug(e,t){return pg(e,{xb:"dynamic"==e.l.type,presentationTimeline:e.i.presentationTimeline,oa:null,ka:null,ha:null,J:null,bandwidth:0,pf:!1,Wa:e.l.Wa,profiles:e.l.profiles,Mb:e.l.Mb,roles:null,ob:function(){return""}},e.l.Oa,t,!0).periods}function lg(e,t){e.i.periodCount--;for(var n=l(e.s.keys()),i=n.next();!i.done;i=n.next())(i=i.value).startsWith(t)&&(Wf(e.s.get(i),dp,"SegmentTimeline").children=[],dg(e,i),e.s.delete(i));e.C=e.C.filter((function(e){return e!==t}))}function cg(e,t){for(var n="",i="",r=-1,a="",o=(t=l(t)).next();!o.done;o=t.next())"Period"===(o=o.value).name?n=o.id:"AdaptationSet"===o.name?(i=o.id,null!==o.position&&(r=o.position)):"Representation"===o.name&&(a=o.id);if(t=[],a)t.push(n+","+a);else if(i)for(r=l(e.s.values()),e=r.next();!e.done;e=r.next())(e=e.value).oa.id===n&&e.ha.id===i&&e.J.id&&t.push(n+","+e.J.id);else if(-1<r)for(i=l(e.s.values()),e=i.next();!e.done;e=i.next())(e=e.value).oa.id===n&&e.ha.position===r&&e.J.id&&t.push(n+","+e.J.id);return t}function dg(e,t){var n=e.s.get(t),i=e.o[t];i.segmentIndex&&i.segmentIndex.Ha(e.i.presentationTimeline.qb());try{var r=cp(n,(function(t,n,i,r){return xg(e,t,n,i,r)}),e.o,!0,e.g.dash.initialSegmentLimit,e.ja,n.J.aesKey,null,!0);i.createSegmentIndex=function(){return P((function(e){if(1==e.g)return i.segmentIndex?e.u(0):w(e,r.nc(),3);i.segmentIndex=e.h,T(e)}))}}catch(e){if((t=n.J.contentType)!=yi&&"application"!=t&&"image"!=t||4002!=e.code)throw e}}function hg(e){var t=_t(e,"ServiceDescription");if(!t)return null;if(e=_t(t,"Latency"),t=_t(t,"PlaybackRate"),!e&&!t)return null;var n={};return e&&("target"in e.attributes&&(n.targetLatency=parseInt(e.attributes.target,10)/1e3),"max"in e.attributes&&(n.maxLatency=parseInt(e.attributes.max,10)/1e3),"min"in e.attributes&&(n.minLatency=parseInt(e.attributes.min,10)/1e3)),t&&("max"in t.attributes&&(n.maxPlaybackRate=parseFloat(t.attributes.max)),"min"in t.attributes&&(n.minPlaybackRate=parseFloat(t.attributes.min))),n}function fg(e){if(!(e=Nt(e,"SupplementalProperty")).length)return null;for(var t=(e=l(e)).next();!t.done;t=e.next())if("urn:mpeg:dash:chaining:2016"==(t=t.value).attributes.schemeIdUri)return t.attributes.value;return null}function pg(e,t,n,i,r){var a=t.Mb;a||(a=Ft(i,"mediaPresentationDuration",Xt),e.l.Mb=a);var o=0;e.i&&e.i.presentationTimeline&&e.Y&&(o=e.i.presentationTimeline.Kb());var s=[],u=o;i=Nt(i,"Period");for(var c=0;c<i.length;c++){var d=i[c],h=i[c+1],f=Ft(d,"start",Xt,u),p=d.attributes.id,g=Ft(d,"duration",Xt);f=0==c&&0==f&&e.Y?o:f;var m=null;if(h){var v=Ft(h,"start",Xt);null!=v&&(m=v-f+o)}else null!=a&&(m=a-f+o);if(v=wi,m&&g&&Math.abs(m-g)>v&&m>g&&e.M++,null==m&&(m=g),!(null!==e.O&&null!==p&&null!==f&&f<e.O)||e.C.includes(p)||c+1==i.length){if(null!==f&&(null===e.O||f>e.O)&&(e.O=f),u=gg(e,t,n,{start:f,duration:m,node:d,uf:null==m||!h}),s.push(u),t.oa.id&&m&&(e.ja[t.oa.id]=m),null==m){u=null;break}u=f+m}}if(r)for(n=(t=l(s)).next();!n.done;n=t.next())n=n.value.id,e.C.includes(n)||e.C.push(n);else e.C=s.map((function(e){return e.id}));return null!=a?{periods:s,duration:a+o,ug:!1}:{periods:s,duration:u,ug:!0}}function gg(t,n,i,r){n.oa=wg(t,r.node,null,i),n.ka=r,n.oa.Wa=n.Wa,n.oa.id||(n.oa.id="__shaka_period_"+r.start);var a=Nt(r.node,"EventStream");i=n.presentationTimeline.qb();for(var o=(a=l(a)).next();!o.done;o=a.next())Sg(t,r.start,r.duration,o.value,i);for(a=(i=l(i=Nt(r.node,"SupplementalProperty"))).next();!a.done;a=i.next())"urn:mpeg:dash:urlparam:2014"==(a=a.value).attributes.schemeIdUri&&(a=vg(t,a))&&(n.ob=a);if(i=Nt(r.node,"AdaptationSet").map((function(i,r){return function(t,n,i,r){function a(e){var i=e.attributes["dvb:fontFamily"];e=e.attributes["dvb:url"],i&&e&&(e=hi(n.ha.Oa(),[e],n.ob()),t.j.addFont(i,e[0]))}function o(e){switch(e){case 1:case 5:case 6:case 7:return"srgb";case 9:return"rec2020";case 11:case 12:return"p3"}}function s(e){switch(e){case 1:case 6:case 13:case 14:case 15:return"SDR";case 16:return"PQ";case 18:return"HLG"}}n.ha=wg(t,r,n.oa,null),n.ha.position=i;var u=!1,d=(i=Nt(r,"Role")).map((function(e){return e.attributes.value})).filter(Gi),h=void 0,f=n.ha.contentType==yi;f&&(h="subtitle");for(var p=(i=l(i)).next();!p.done;p=i.next()){var g=(p=p.value).attributes.schemeIdUri;if(null==g||"urn:mpeg:dash:role:2011"==g)switch(p=p.attributes.value,p){case"main":u=!0;break;case"caption":case"subtitle":h=p}}var m=Nt(r,"EssentialProperty");i=null;var v=!1;p=null,g=!1;for(var y=(m=l(m)).next();!y.done;y=m.next()){var b=(y=y.value).attributes.schemeIdUri;if("http://dashif.org/guidelines/trickmode"==b)i=y.attributes.value;else if("urn:mpeg:mpegB:cicp:TransferCharacteristics"==b)var S=s(parseInt(y.attributes.value,10));else if("urn:mpeg:mpegB:cicp:ColourPrimaries"==b)var x=o(parseInt(y.attributes.value,10));else"urn:mpeg:mpegB:cicp:MatrixCoefficients"!=b&&("urn:mpeg:dash:ssr:2023"==b&&t.g.dash.enableFastSwitching?v=!0:"urn:dvb:dash:fontdownload:2014"==b?a(y):"urn:mpeg:dash:urlparam:2014"==b&&(p=vg(t,y))||(g=!0))}if(g)return null;var A=null;for(m=(g=l(g=Nt(r,"SupplementalProperty"))).next();!m.done;m=g.next())"http://dashif.org/guidelines/last-segment-number"==(y=(m=m.value).attributes.schemeIdUri)?A=parseInt(m.attributes.value,10)-1:"urn:mpeg:mpegB:cicp:TransferCharacteristics"==y?S=s(parseInt(m.attributes.value,10)):"urn:mpeg:mpegB:cicp:ColourPrimaries"==y?x=o(parseInt(m.attributes.value,10)):"urn:dvb:dash:fontdownload:2014"==y?a(m):"urn:mpeg:dash:urlparam:2014"==y&&(p=vg(t,m));p&&(n.ob=p),p=Nt(r,"Accessibility");var E,k=new Map;for(g=(p=l(p)).next();!g.done;g=p.next())if(g=(m=g.value).attributes.schemeIdUri,m=m.attributes.value,"urn:scte:dash:cc:cea-608:2015"!=g||t.g.disableText)if("urn:scte:dash:cc:cea-708:2015"!=g||t.g.disableText)"urn:mpeg:dash:role:2011"==g?null!=m&&(d.push(m),"captions"==m&&(h="caption")):"urn:tva:metadata:cs:AudioPurposeCS:2007"==g&&("1"==m?E="visually impaired":"2"==m&&(E="hard of hearing"));else if(g=1,null!=m)for(y=(m=l(m.split(";"))).next();!y.done;y=m.next()){b=y.value;var I=y=void 0;b.includes("=")?(y="svc"+(b=b.split("="))[0],I=b[1].split(",")[0].split(":").pop()):(y="svc"+g,g++,I=b),k.set(y,Yi(I))}else k.set("svc1","und");else if(g=1,null!=m)for(b=(y=l(m=m.split(";"))).next();!b.done;b=y.next()){I=b.value;var M=b=void 0;I.includes("=")?(b=(I=I.split("="))[0].startsWith("CC")?I[0]:"CC"+I[0],M=I[1]||"und"):(b="CC"+g,2==m.length?g+=2:g++,M=I),k.set(b,Yi(M))}else k.set("CC1","und");var C=Bf(p=Nt(r,"ContentProtection"),t.g.dash.ignoreDrmInfo,t.g.dash.keySystemsByURI),D=Yi(n.ha.language||"und"),R=n.ha.label;if(r=(p=Nt(r,"Representation")).map((function(i){return(i=function(t,n,i,r,a,o,s,u,l,c,d,h){n.J=wg(t,c,n.ha,null);var f=n.J.id;if(t.da=Math.min(t.da,n.J.Wa),t.ga=0<t.da,!function(e){var t=e.Yc?1:0;return t+=e.Rb?1:0,0==(t+=e.ec?1:0)?e.contentType==yi||"application"==e.contentType:(1!=t&&(e.Yc&&(e.Rb=null),e.ec=null),!0)}(n.J))return null;var p=n.ka.start;n.bandwidth=Ft(c,"bandwidth",Wt)||0,n.roles=u;var g,m,v=Nt(c,"SupplementalProperty"),y=Nt(c,"EssentialProperty"),b=null,S=y.find((function(e){return"urn:mpeg:dash:urlparam:2014"==e.attributes.schemeIdUri}));(S||(S=v.find((function(e){return"urn:mpeg:dash:urlparam:2014"==e.attributes.schemeIdUri}))))&&(b=vg(t,S)),b&&(n.ob=b),b=(S=n.J.contentType)==yi||"application"==S,S="image"==S;try{var x=void 0;if(i.Je){var A=n.J.Oa,E=n.ob,k=aa(hi(A(),[i.Je.wi],E()),t.g.retryParameters);x={bitsKey:128,blockCipherMode:"CBC",iv:i.Je.iv,firstMediaSequenceNumber:0,fetchKey:function(){var n,i,r;return P((function(a){if(1==a.g)return w(a,Eg(t,k,6),2);if(3!=a.g){if(!(n=a.h).data||16!=n.data.byteLength)throw new De(2,4,4049);return i={name:"AES-CBC"},r=x,w(a,e.crypto.subtle.importKey("raw",n.data,i,!0,["decrypt"]),3)}r.cryptoKey=a.h,x.fetchKey=void 0,T(a)}))}}}if(n.J.aesKey=x,A=function(e,n,i,r){return xg(t,e,n,i,r)},n.J.Yc)var I=function(e,t,n){var i=Number(zf(e,ap,"presentationTimeOffset"))||0,r=zf(e,ap,"timescale"),a=1;r&&(a=Wt(r)||1);var o=i/a||0,s=ip(e,ap,n);!function(e,t){if(sp(e,t),!op(e))throw new De(2,4,4002)}(e,s);var u=It(e);return{nc:function(){var e=Wf(u,ap,"RepresentationIndex"),n=u.J.Oa();return e&&(e=vt(e.attributes.sourceURL))&&(n=hi(n,[e],u.ob())),e=op(u),rp(u,t,s,n,e.start,e.end,o)}}}(n,A,x);else if(n.J.Rb)I=function(e,t,n){var i=ip(e,lp,n),r=function(e){var t=function(e){return[e.J.Rb,e.ha.Rb,e.oa.Rb].filter(Gi).map((function(e){return Nt(e,"SegmentURL")})).reduce((function(e,t){return 0<e.length?e:t})).map((function(t){return t.attributes.indexRange&&!e.pf&&(e.pf=!0),{Ci:vt(t.attributes.media),start:(t=Ft(t,"mediaRange",qt,{start:0,end:null})).start,end:t.end}}))}(e),n=(e=Xf(e,lp)).zd;0==n&&(n=1);var i=0;return e.Qa?i=e.Qa*(n-1):e.timeline&&0<e.timeline.length&&(i=e.timeline[0].start),{Qa:e.Qa,startTime:i,zd:n,Pb:e.Pb,timeline:e.timeline,Rc:t}}(e);if(!r.Qa&&!r.timeline&&1<r.Rc.length)throw new De(2,4,4002);if(!r.Qa&&!e.ka.duration&&!r.timeline&&1==r.Rc.length)throw new De(2,4,4002);if(r.timeline&&0==r.timeline.length)throw new De(2,4,4002);var a=null,o=null;e.oa.id&&e.J.id&&(o=t[e.oa.id+","+e.J.id])&&(a=o.segmentIndex);var s=function(e,t,n,i,r,a,o,s,u,l){var c=i.Rc.length;i.timeline&&i.timeline.length!=i.Rc.length&&(c=Math.min(i.timeline.length,i.Rc.length));for(var d=e-i.Pb,h=t?e+t:1/0,f=[],p=i.startTime,g={},m=0;m<c;g={ve:void 0,ne:void 0},m++){g.ne=i.Rc[m];var v=p;p=void 0,p=null!=i.Qa?v+i.Qa:i.timeline?i.timeline[m].end:v+t,g.ve=null,(g=new vo(e+v,e+p,function(e){return function(){return null==e.ve&&(e.ve=hi(n(),[e.ne.Ci],l())),e.ve}}(g),g.ne.start,g.ne.end,r,d,e,h,[],"",null,null,bo,a)).codecs=s,g.mimeType=o,g.bandwidth=u,f.push(g)}return f}(e.ka.start,e.ka.duration,e.J.Oa,r,i,n,e.J.mimeType,e.J.codecs,e.bandwidth,e.ob);return t=!a,a?a.td(s,e.presentationTimeline.qb()):a=new Zs(s),e.presentationTimeline.vd(s),e.xb&&e.ka.uf||a.Kc(e.ka.start,e.ka.duration?e.ka.start+e.ka.duration:1/0,t),o&&(o.segmentIndex=a),{nc:function(){return a&&0!=a.getNumReferences()||a.Zd(s),Promise.resolve(a)}}}(n,t.o,x);else if(n.J.ec)I=cp(n,A,t.o,!!t.i,t.g.dash.initialSegmentLimit,t.ja,x,h,!1);else{var M=n.ka.duration||0,C=n.J.Oa,D=n.J.mimeType,R=n.J.codecs;I={nc:function(){var e=tu(p,M,C());return e.yb((function(e){e.mimeType=D,e.codecs=R})),Promise.resolve(e)}}}}catch(e){if((b||S)&&4002==e.code)return null;throw e}if(c=function(e,t,n,i){var r=Bf(e,n,i);if(t.wg)e=1==t.drmInfos.length&&!t.drmInfos[0].keySystem,n=0==r.drmInfos.length,(0==t.drmInfos.length||e&&!n)&&(t.drmInfos=r.drmInfos),t.wg=!1;else if(0<r.drmInfos.length&&(t.drmInfos=t.drmInfos.filter((function(e){return r.drmInfos.some((function(t){return t.keySystem==e.keySystem}))})),0==t.drmInfos.length))throw new De(2,4,4008);return r.rg||t.rg}(c=Nt(c,"ContentProtection"),i,t.g.dash.ignoreDrmInfo,t.g.dash.keySystemsByURI),c=new Set(c?[c]:[]),h=!1,v.some((function(e){return"tag:dolby.com,2018:dash:EC3_ExtensionType:2018"==e.attributes.schemeIdUri&&"JOC"==e.attributes.value}))&&(h=!0),v=!1,b&&(v=u.includes("forced_subtitle")||u.includes("forced-subtitle")),S&&((y=y.find((function(e){return["http://dashif.org/thumbnail_tile","http://dashif.org/guidelines/thumbnail_tile"].includes(e.attributes.schemeIdUri)})))&&(g=y.attributes.value),!g))return null;b=n.J.codecs,n.profiles.includes("http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10")&&(b.includes("hvc1.2.4.L153.B0")||b.includes("hev1.2.4.L153.B0"))&&(m="PQ"),y=n.J.id?n.oa.id+","+n.J.id:"",t.F.length&&f&&t.s.set(n.oa.id+","+f,function(e){function t(e){return e?((e=It(e)).Yc=null,e.Rb=null,e.ec=an(e.ec),e):null}return(e=It(e)).oa=t(e.oa),e.ha=t(e.ha),e.J=t(e.J),e.ka&&(e.ka=It(e.ka),e.ka.node=null),e}(n));var L=y&&t.o[y]?t.o[y]:{id:t.na++,originalId:n.J.id,groupId:null,createSegmentIndex:function(){return Promise.resolve()},closeSegmentIndex:function(){L.segmentIndex&&(L.segmentIndex.release(),L.segmentIndex=null)},segmentIndex:null,mimeType:n.J.mimeType,codecs:b,frameRate:n.J.frameRate,pixelAspectRatio:n.J.pixelAspectRatio,bandwidth:n.bandwidth,width:n.J.width,height:n.J.height,kind:r,encrypted:0<i.drmInfos.length,drmInfos:i.drmInfos,keyIds:c,language:a,originalLanguage:n.ha.language,label:o,type:n.ha.contentType,primary:s,trickModeVideo:null,emsgSchemeIdUris:n.J.emsgSchemeIdUris,roles:u,forced:v,channelsCount:n.J.ce,audioSamplingRate:n.J.audioSamplingRate,spatialAudio:h,closedCaptions:l,hdr:m,colorGamut:void 0,videoLayout:void 0,tilesLayout:g,accessibilityPurpose:d,external:!1,fastSwitching:!1,fullMimeTypes:new Set([xi(n.J.mimeType,n.J.codecs)]),isAudioMuxedInVideo:!1};return L.createSegmentIndex=function(){var e;return P((function(t){if(1==t.g)return L.segmentIndex?t.u(0):(e=L,w(t,I.nc(),3));e.segmentIndex=t.h,T(t)}))},y&&n.xb&&!t.o[y]&&(n=n.oa.id||"",t.B[n]||(t.B[n]=[]),t.o[y]=L,t.B[n].push(y)),L}(t,n,C,h,D,R,u,d,k,i,E,A))&&(i.hdr=i.hdr||S,i.colorGamut=i.colorGamut||x,i.fastSwitching=v),i})).filter((function(e){return!!e})),0==r.length){if(i="image"==n.ha.contentType,t.g.dash.ignoreEmptyAdaptationSet||f||i)return null;throw new De(2,4,4003)}if(!n.ha.contentType||"application"==n.ha.contentType)for(n.ha.contentType=Ag(r[0].mimeType,r[0].codecs),g=(f=l(r)).next();!g.done;g=f.next())g.value.type=n.ha.contentType;for(f=n.ha.id||"__fake__"+t.na++,m=(g=l(r)).next();!m.done;m=g.next()){for(m=m.value,b=(y=l(C.drmInfos)).next();!b.done;b=y.next())(b=b.value).keyIds=b.keyIds&&m.keyIds?new Set([].concat(c(b.keyIds),c(m.keyIds))):b.keyIds||m.keyIds;m.groupId=f}return p=p.map((function(e){return e.attributes.id})).filter(Gi),{id:f,contentType:n.ha.contentType,language:D,lk:u,streams:r,drmInfos:C.drmInfos,bg:i,Qi:p}}(t,n,r,i)})).filter(Gi),n.xb){for(r=[],o=(a=l(i)).next();!o.done;o=a.next())for(var s=(o=l(o.value.Qi)).next();!s.done;s=o.next())r.push(s.value);if(r.length!=new Set(r).size)throw new De(2,4,4018)}if(r=i.filter((function(e){return!e.bg})),i=i.filter((function(e){return e.bg})),!t.g.disableIFrames)for(a=(i=l(i)).next();!a.done;a=i.next()){o=(a=a.value).bg.split(" ");for(var u=(s=l(r)).next();!u.done;u=s.next())if(u=u.value,o.includes(u.id))for(var d=(u=l(u.streams)).next();!d.done;d=u.next())Sr(d.value,a.streams)}if(i=mg(t.g.disableAudio,r,"audio"),a=mg(t.g.disableVideo,r,"video"),o=mg(t.g.disableText,r,yi),r=mg(t.g.disableThumbnails,r,"image"),0===a.length&&0===i.length)throw new De(2,4,4004);return{id:n.oa.id,audioStreams:i,videoStreams:a,textStreams:o,imageStreams:r}}function mg(e,t,n){return e||!t.length?[]:t.reduce((function(e,t){return t.contentType!=n||e.push.apply(e,c(t.streams)),e}),[])}function vg(e,t){if((t=Bt(t,"urn:mpeg:dash:schema:urlparam:2014","UrlQueryInfo"))&&Ft(t,"useMPDUrlQuery",$t,!1)){var n=t.attributes.queryTemplate;if(n)return function(){return"$querypart$"==n?e.aa:n.split("&").map((function(t){if("$querypart$"==t)return e.aa;var n=/\$query:(.*?)\$/g.exec(t);if(n&&2==n.length){n=n[1];var i=new ni(e.aa).get(n);if(i.length)return n+"="+i[0]}return t})).join("&")}}return null}function yg(e){var t,n;return P((function(i){switch(i.g){case 1:return t=0,S(i,2),w(i,ag(e),4);case 4:t=i.h,A(i,3);break;case 2:if(n=E(i),e.j){if(e.g.raiseFatalErrorOnManifestUpdateRequestFailure)return e.j.onError(n),i.return();n.severity=1,e.j.onError(n)}case 3:if(!e.j)return i.return();e.j.onManifestUpdated(),bg(e,t),T(i)}}))}function bg(e,t){if(!(0>e.K)){var n=e.K;0<=e.g.dash.updatePeriod&&(n=e.g.dash.updatePeriod),e.L.$(Math.max(n-t,K(e.ra)))}}function wg(e,t,n,i){n=n||{contentType:"",mimeType:"",codecs:"",emsgSchemeIdUris:[],frameRate:void 0,pixelAspectRatio:void 0,ce:null,audioSamplingRate:null,Wa:0,oe:0},i=i||n.Oa;var r,a=t.attributes.id,o=Nt(t,"BaseURL"),s=!1;if(e.h)for(var u=l(o),c=u.next();!c.done;c=u.next()){var d=c.value;c=d.attributes.serviceLocation,d=Ot(d),c&&d&&(bp(e.h,a,c,d),s=!0)}s&&e.h||(r=o.map(Ot)),u=t.attributes.contentType||n.contentType,c=t.attributes.mimeType||n.mimeType,d=[t.attributes.codecs||n.codecs];var h=Vt(t,"urn:scte:dash:scte214-extensions","supplementalCodecs");h&&d.push(h),d=Cu(d).join(","),h=Ft(t,"frameRate",Qt)||n.frameRate;var f=t.attributes.sar||n.pixelAspectRatio,p=function(e,t){t=t.slice();for(var n=(e=l(e)).next();!n.done;n=e.next())n=n.value.attributes.schemeIdUri,t.includes(n)||t.push(n);return t}(Nt(t,"InbandEventStream"),n.emsgSchemeIdUris),g=Nt(t,"AudioChannelConfiguration");g=function(e){for(var t=(e=l(e)).next();!t.done;t=e.next()){var n=(t=t.value).attributes.schemeIdUri;if(n&&(t=t.attributes.value))switch(n){case"urn:mpeg:dash:outputChannelPositionList:2012":return t.trim().split(/ +/).length;case"urn:mpeg:dash:23003:3:audio_channel_configuration:2011":case"urn:dts:dash:audio_channel_configuration:2012":if(!(t=parseInt(t,10)))continue;return t;case"tag:dolby.com,2015:dash:audio_channel_configuration:2015":if(n=[2,1,2,2,2,2,1,2,2,1,1,1,1,2,1,1,2,2],!(t=parseInt(t,16)))continue;for(var i=0,r=0;r<n.length;r++)t&1<<r&&(i+=n[r]);if(i)return i;continue;case"tag:dolby.com,2014:dash:audio_channel_configuration:2011":case"urn:dolby:dash:audio_channel_configuration:2011":if(n=[1,1,1,1,1,2,2,1,1,2,2,2,1,2,1,1].reverse(),!(t=parseInt(t,16)))continue;for(r=i=0;r<n.length;r++)t&1<<r&&(i+=n[r]);if(i)return i;continue;case"urn:mpeg:mpegB:cicp:ChannelConfiguration":if(n=[0,1,2,3,4,5,6,8,2,3,4,7,8,24,8,12,10,12,14,12,14],(t=parseInt(t,10))&&0<t&&t<n.length)return n[t]}}return null}(g)||n.ce;var m=Ft(t,"audioSamplingRate",Yt)||n.audioSamplingRate;u||(u=Ag(c,d));var v=_t(t,"SegmentBase"),y=_t(t,"SegmentTemplate"),b=v&&Ft(v,"availabilityTimeOffset",Jt)||0,w=y&&Ft(y,"availabilityTimeOffset",Jt)||0,T=o&&o.length&&Ft(o[0],"availabilityTimeOffset",Jt)||0;b=n.Wa+T+b+w,w=null,(T=_t(t,"SegmentSequenceProperties"))&&(T=_t(T,"SAP"))&&(w=Ft(T,"cadence",zt)),T=t.attributes.label;var S=Nt(t,"Label");return S&&S.length&&jt(S=S[0])&&(T=jt(S)),{Oa:function(){return hi(i(),o.length?e.h&&s?wp(e.h,a):r||[]:[])},Yc:v||n.Yc,Rb:_t(t,"SegmentList")||n.Rb,ec:y||n.ec,width:Ft(t,"width",Yt)||n.width,height:Ft(t,"height",Yt)||n.height,contentType:u,mimeType:c,codecs:d,frameRate:h,pixelAspectRatio:f,emsgSchemeIdUris:p,id:a,language:t.attributes.lang,ce:g,audioSamplingRate:m,Wa:b,Ud:null,oe:w||n.oe,label:T||null}}function Tg(e,t,n,i){var r,a,o,s,u,l,c;return P((function(d){if(1==d.g)return r=[vt(n)],a=hi(t(),r),(o=aa(a,e.g.retryParameters)).method=i,s=e.j.networkingEngine.request(4,o,{isPreload:e.fa()}),ta(e.S,s),w(d,s.promise,2);if(u=d.h,"HEAD"==i){if(!u.headers||!u.headers.date)return d.return(0);l=u.headers.date}else l=dt(u.data);return c=Date.parse(l),isNaN(c)?d.return(0):d.return(c-Date.now())}))}function Sg(e,t,n,i,r){for(var a=i.attributes.schemeIdUri||"",o=i.attributes.value||"",s=Ft(i,"timescale",Yt)||1,u=Ft(i,"presentationTimeOffset",Yt)||0,c=(i=l(Nt(i,"Event"))).next();!c.done;c=i.next()){var d=Ft(c=c.value,"presentationTime",Yt)||0,h=Ft(c,"duration",Yt)||0;h=(d=Math.max((d-u)/s+t,t))+h/s,null!=n&&(d=Math.min(d,t+n),h=Math.min(h,t+n)),h<r||(c={schemeIdUri:a,value:o,startTime:d,endTime:h,id:c.attributes.id||"",eventElement:rn(c),eventNode:an(c)},e.j.onTimelineRegionAdded(c))}}function xg(e,t,n,i,r){var a,o,s,u;return P((function(l){return 1==l.g?(a=ca,o=r?0:1,s=Ru(t,n,i,e.g.retryParameters),w(l,Eg(e,s,a,{type:o}),2)):(u=l.h,l.return(u.data))}))}function Ag(e,t){return Ui(t=xi(e,t))?yi:e.split("/")[0]}function Eg(e,t,n,i){return i||(i={}),i.isPreload=e.fa(),t=e.j.networkingEngine.request(n,t,i),ta(e.S,t),t.promise}function kg(){}(i=rg.prototype).configure=function(e,t){var n=this.j&&e.dash.updatePeriod!=this.g.dash.updatePeriod&&0<=e.dash.updatePeriod;this.g=e,t&&(this.fa=t),n&&this.i&&this.i.presentationTimeline.U()&&this.L.hc(),this.h&&this.h.configure(this.g),this.m&&(this.m.bh(this.g.dash.multiTypeVariantsAllowed&&ie()),this.m.ih(this.g.dash.useStreamOnceInPeriodFlattening))},i.start=function(e,t){var n,i=this;return P((function(r){if(1==r.g)return i.H=t.isLowLatencyMode(),i.A=[e],i.j=t,w(r,ag(i),2);if(n=r.h,i.j&&bg(i,n),!i.j)throw new De(2,7,7001);return r.return(i.i)}))},i.stop=function(){for(var e=l(Object.values(this.o)),t=e.next();!t.done;t=e.next())(t=t.value).segmentIndex&&t.segmentIndex.release();return this.m&&this.m.release(),this.g=this.j=null,this.A=[],this.i=null,this.o={},this.B={},this.s.clear(),this.l={ae:"",type:"",profiles:[],Mb:null,Wa:0,Oa:null,xd:0},this.m=null,null!=this.L&&(this.L.stop(),this.L=null),this.h&&this.h.destroy(),this.G&&(this.G.release(),this.G=null),this.S.destroy()},i.update=function(){var e,t=this;return P((function(n){return 1==n.g?(S(n,2),w(n,ag(t),4)):2!=n.g?A(n,0):(e=E(n),t.j&&e?(t.j.onError(e),void T(n)):n.return())}))},i.onExpirationUpdated=function(){},i.onInitialVariantChosen=function(e){if(this.i&&this.i.presentationTimeline.U()){var t=e.video||e.audio;if(t&&t.segmentIndex){e=this.i.presentationTimeline.Yb();var n=t.segmentIndex.find(e);null!=n&&(t=t.segmentIndex.get(n))&&(this.K=t.endTime-e,bg(this,0))}}},i.banLocation=function(e){this.h&&this.h.banLocation(e)},i.setMediaElement=function(e){this.I=e},F("shaka.dash.DashParser",rg),co["application/dash+xml"]=function(){return new rg},co["video/vnd.mpeg.dash.mpd"]=function(){return new rg},F("shaka.dependencies",kg),kg.has=function(e){return Cg.has(e)},kg.add=function(e,t){if(!Mg[e])throw Error(e+" is not supported");e==Ig?oe("mux.js","mux.js is no longer used in Shaka Player."):Cg.set(e,(function(){return t}))};var Ig="muxjs",Mg={mk:Ig,ISOBoxer:"ISOBoxer"};kg.Allowed=Mg;var Cg=new Map([["ISOBoxer",function(){return e.ISOBoxer}]]);function Dg(e,t,n){this.type=e,this.X=t,this.segments=n||null}function Rg(e,t,n,i){this.id=e,this.name=t,this.attributes=n,this.value=void 0===i?null:i}function Pg(e,t){return t?e.toString():(t=(new Set).add("AUDIO").add("VIDEO").add("SUBTITLES").add("PATHWAY-ID").add("GROUP-ID").add("URI"),e.toString(t))}function Lg(e,t){return(e=e.attributes.filter((function(e){return e.name==t}))).length?e[0]:null}function Ng(e,t,n){return(e=Lg(e,t))?e.value:n||null}function jg(e,t){if(!(e=Lg(e,t)))throw new De(2,4,4023,t);return e.value}function Og(e,t,n){n=void 0===n?[]:n,this.X=t,this.g=e,this.Cb=n}function Ug(e,t){this.name=e,this.value=t}function _g(e,t){return e.filter((function(e){return e.name==t}))}function Bg(e,t){return e.filter((function(e){return jg(e,"TYPE")==t}))}function Fg(e,t){for(var n=(e=l(e)).next();!n.done;n=e.next())if((n=n.value).name===t)return n;return null}function Vg(e,t,n){return n=void 0===n?0:n,(e=Fg(e,t))?Number(e.value):n}function Hg(e,t,n){return t?Gg(e,[t],n):[]}function Gg(e,t,n){if(!t.length)return[];t=hi(e,t),e=[];for(var i=(t=l(t)).next();!i.done;i=t.next())e.push(Kg(i.value,n));return e}function Kg(e,t){if(!t||!t.size)return e;var n=(e=String(e).replace(/%7B/g,"{").replace(/%7D/g,"}")).match(/{\$\w*}/g);if(n)for(var i=(n=l(n)).next();!i.done;i=n.next()){var r=(i=i.value).slice(2,i.length-1),a=t.get(r);if(!a)throw new De(2,4,4039,r);e=e.replace(i,a)}return e}function Xg(){this.g=0}function qg(e,t){var n=(t=(t=dt(t)).replace(/\r\n|\r(?=[^\n]|$)/gm,"\n").trim()).split(/\n+/m);if(!/^#EXTM3U($|[ \t\n])/m.test(n[0]))throw new De(2,4,4015);t=0;for(var i=!0,r=l(n),a=r.next();!a.done;a=r.next())if(a=a.value,/^#(?!EXT)/m.test(a)||i)i=!1;else{if(a=zg(e,a),--e.g,Wg.includes(a.name)){t=1;break}"EXT-X-STREAM-INF"==a.name&&(i=!0)}for(r=[],i=!0,a=0;a<n.length;a++){var o=n[a],s=n[a+1];if(/^#(?!EXT)/m.test(o)||i)i=!1;else{if(o=zg(e,o),Yg.includes(o.name)){if(1!=t)throw new De(2,4,4017);o=n.splice(a,n.length-a),n=[],i=[],a=[],s=null;for(var u=(o=l(o)).next();!u.done;u=o.next())u=u.value,/^(#EXT)/.test(u)?(u=zg(e,u),Wg.includes(u.name)?r.push(u):"EXT-X-MAP"==u.name?s=u:"EXT-X-PART"==u.name?a.push(u):"EXT-X-PRELOAD-HINT"==u.name?"PART"==Ng(u,"TYPE")?a.push(u):"MAP"==Ng(u,"TYPE")&&(u.name="EXT-X-MAP",s=u):i.push(u)):/^#(?!EXT)/m.test(u)||(u=u.trim(),s&&i.push(s),n.push(new Og(u,i,a)),i=[],a=[]);return a.length&&(s&&i.push(s),n.push(new Og("",i,a))),new Dg(t,r,n)}r.push(o),"EXT-X-STREAM-INF"==o.name&&(o.attributes.push(new Ug("URI",s)),i=!0)}}return new Dg(t,r)}function zg(e,t){e=e.g++;var n=t.match(/^#(EXT[^:]*)(?::(.*))?$/);if(!n)throw new De(2,4,4016,t);t=n[1];var i,r=n[2];if(n=[],r){var a;(a=Tt(r=new bt(r),/^([^,=]+)(?:,|$)/g))&&(i=a[1]);for(var o=/([^=]+)=(?:"([^"]*)"|([^",]*))(?:,|$)/g;a=Tt(r,o);)n.push(new Ug(a[1],a[2]||a[3])),wt(r)}return new Rg(e,t,n,i)}Rg.prototype.toString=function(e){var t="#"+this.name,n=this.attributes?this.attributes.filter((function(t){return!e||!e.has(t.name)})).map((function(e){return e.name+"="+(isNaN(Number(e.value))?'"'+e.value+'"':e.value)})):[];return this.value&&n.unshift(this.value),0<n.length&&(t+=":"+n.join(",")),t};var Wg="EXT-X-TARGETDURATION EXT-X-MEDIA-SEQUENCE EXT-X-DISCONTINUITY-SEQUENCE EXT-X-PLAYLIST-TYPE EXT-X-I-FRAMES-ONLY EXT-X-ENDLIST EXT-X-SERVER-CONTROL EXT-X-SKIP EXT-X-PART-INF EXT-X-DATERANGE".split(" "),Yg="EXTINF EXT-X-BYTERANGE EXT-X-DISCONTINUITY EXT-X-PROGRAM-DATE-TIME EXT-X-KEY EXT-X-DATERANGE EXT-X-MAP EXT-X-GAP".split(" ");function Jg(){}function $g(e){try{var t=Qg(e);return zr({uri:e,originalUri:e,data:t.data,headers:{"content-type":t.contentType}})}catch(e){return Xr(e)}}function Qg(t){var n=t.split(":");if(2>n.length||"data"!=n[0])throw new De(2,1,1004,t);if(2>(n=n.slice(1).join(":").split(",")).length)throw new De(2,1,1004,t);var i=n[0];t=e.decodeURIComponent(n.slice(1).join(",")),n=i.split(";"),i=n[0];var r=!1;return 1<n.length&&"base64"==n[n.length-1]&&(r=!0,n.pop()),{data:r?ui(t):pt(t),contentType:i}}function Zg(){var e=this;this.g=this.h=null,this.C=1,this.A=new Map,this.H=new Map,this.O=new Map,this.O.set("video",new Map),this.O.set("audio",new Map),this.O.set(yi,new Map),this.O.set("image",new Map),this.Na=new Set,this.i=new Map,this.l=null,this.M="",this.Ka=new Xg,this.I=-1,this.ga=1/0,this.fa=this.ac=this.bc=!1,this.B=new Be((function(){e.aa&&!e.g.continueLoadingWhenPaused&&(e.Z.cb(e.aa,"timeupdate"),e.aa.paused)?e.Z.pa(e.aa,"timeupdate",(function(){return jm(e)})):jm(e)})),this.xa=Xm,this.m=null,this.La=0,this.o=1/0,this.Ga=this.Ba=this.Y=0,this.da=new ea,this.F=new Map,this.G=new Map,this.ta=new Map,this.ja=new Map,this.L=new Map,this.ra=new Map,this.na=new Map,this.Ib=this.K=!1,this.Gb=new G(5),this.j=null,this.S=!0,this.Aa=new Set,this.Z=new Z,this.s=this.aa=null,this.Hb=function(){return!1}}function em(e,t){return Om(e)?e.O.get(t.type):t.Yd}function tm(e,t){var n,i,r,a,o,s,u,d,h,f,p,g,m,v,y,b,x,k,I,M,C,D,R,L,N,j,O,U,_,B,F,V,H;return P((function(P){switch(P.g){case 1:if(t.stream.isAudioMuxedInVideo)return P.return();for(n=[],i=l(t.N()),r=i.next();!r.done;r=i.next())a=r.value,o=new Gn(a),s=o.g,t.Id&&(0<=t.sb&&s.add("_HLS_msn",String(t.sb)),0<=t.ub&&s.add("_HLS_part",String(t.ub))),t.Jd&&s.add("_HLS_skip","YES"),ri(s)&&zn(o,s),n.push(o.toString());return S(P,2),w(P,Nm(e,n,!0).promise,4);case 4:u=P.h,A(P,3);break;case 2:throw d=E(P),e.h&&e.h.disableStream(t.stream),d;case 3:if(!t.stream.segmentIndex)return P.return();if(1!=(h=qg(e.Ka,u.data)).type)throw new De(2,4,4017);return(f=u.uri)==u.originalUri||t.N().includes(f)||t.Wg.push(f),p=_g(h.X,"EXT-X-DEFINE"),g=am(e,p,f),m=t.stream,v=em(e,t),w(P,wm(e,h,m.mimeType,t.N,g),5);case 5:for(y=P.h,b=y.keyIds,x=y.drmInfos,function(e,t){return e.size===t.size&&[].concat(c(e)).every((function(e){return t.has(e)}))}(m.keyIds,b)||(m.keyIds=b,m.drmInfos=x,e.h.newDrmInfo(m)),k=Cm(e,h,v,g,t.N,t.type),I=k.segments,(M=k.bandwidth)&&(m.bandwidth=M),C=Iu(m),D=l(I),R=D.next();!R.done;R=D.next())(L=R.value).ba&&(L.ba.Qc=C);m.segmentIndex.td(I,e.l.qb()),I.length&&(N=Vg(h.X,"EXT-X-MEDIA-SEQUENCE",0),O=(j=Fg(h.X,"EXT-X-SKIP"))?Number(Ng(j,"SKIPPED-SEGMENTS")):0,U=ym(N,I),_=U.sb,B=U.ub,t.sb=_+O,t.ub=B,F=v.get(N),m.segmentIndex.Ha(F)),(V=eu(m.segmentIndex))&&(t.xc=V.startTime,H=I[I.length-1],t.Lb=H.endTime),Fg(h.X,"EXT-X-ENDLIST")&&(t.kd=!0),xm(e,h),Mm(e,h.X,m.type,g,t.N),T(P)}}))}function nm(e,t,n){n=void 0!==n&&n;for(var i=-1==e.I,r=l(t),a=r.next();!a.done;a=r.next()){var o=(a=a.value).stream.segmentIndex,s=em(e,a);if(o=eu(o))for(var u=(s=l(s)).next();!u.done;u=s.next()){var c=(u=l(u.value)).next().value;if(u.next().value==o.startTime){i&&(e.I=Math.max(e.I,c)),a.Ue=c;break}}}if(!(0>e.I))for(i=(t=l(t)).next();!i.done;i=t.next())(mm(e,(i=i.value).type)||n)&&(r=i.stream.segmentIndex)&&0<(a=e.I-i.Ue)&&(r.g.splice(0,a),r=eu(r))&&(r=-r.startTime,i.stream.segmentIndex.offset(r),im(e,i,r))}function im(e,t,n){t.xc+=n,t.Lb+=n;for(var i=l(e=em(e,t)),r=i.next();!r.done;r=i.next()){var a=l(r.value);r=a.next().value,a=a.next().value,e.set(r,a+n)}t.N()}function rm(e){if(Om(e)){if(e.xa==zm){for(var t=1/0,n=1/0,i=l(e.i.values()),r=i.next();!r.done;r=i.next())(r=r.value).stream.segmentIndex&&"text"!=r.stream.type&&!r.stream.isAudioMuxedInVideo&&(t=Math.min(t,r.Lb),n=Math.min(n,r.xc));t=t-n||0,isNaN(e.g.availabilityWindowOverride)||(t=e.g.availabilityWindowOverride),e.l.pe(t)}}else e.l.bb(fm(e));if(!e.l.s)for(n=(t=l(e.i.values())).next();!n.done;n=t.next())!(n=n.value).stream.segmentIndex||"audio"!=n.type&&"video"!=n.type||(n=eu(n.stream.segmentIndex))&&n.h&&e.l.fh(n.h);e.l.Xd()}function am(e,t,n){n=new Gn(n).g;for(var i=new Map,r=(t=l(t)).next();!r.done;r=t.next()){var a=r.value,o=Ng(a,"NAME"),s=Ng(a,"VALUE");r=Ng(a,"QUERYPARAM"),a=Ng(a,"IMPORT"),o&&s&&(i.has(o)||i.set(o,s)),r&&(o=n.get(r)[0])&&!i.has(o)&&i.set(r,o),a&&(r=e.A.get(a))&&i.set(a,r)}return i}function om(e){var t=new Set([xi(e.mimeType,e.codecs)]);e.segmentIndex&&e.segmentIndex.yb((function(n){n.mimeType&&t.add(xi(n.mimeType,e.codecs))})),e.fullMimeTypes=t}function sm(e,t,n){for(var i={audio:[],video:[]},r=new Map,a=[],o=!1,s=!1,u=l(t),d=u.next();!d.done;d=u.next()){var h=d.value;d=Ng(h,"AUDIO");var f=Ng(h,"VIDEO"),p=d||f;p&&(a.includes(p)||a.push(p),(h=Ng(h,"PATHWAY-ID"))&&r.set(p,h),d?o=!0:f&&(s=!0))}a.length&&n.length&&function(e,t,n){t=t.filter((function(e){var t=Ng(e,"URI")||"";return"SUBTITLES"!=(e=Ng(e,"TYPE"))&&(""!=t||"AUDIO"==e)}));for(var i={},r=(t=l(t)).next();!r.done;r=t.next()){var a=Pg(r=r.value,!e.j);i[a]?i[a].push(r):i[a]=[r]}for(var o in i)cm(e,i[o],n,!1)}(e,n=n.filter((function(e){return a.includes(jg(e,"GROUP-ID"))})),r),n=(r=a.sort().join(","))&&e.H.has(r)?e.H.get(r):[],o?i.audio.push.apply(i.audio,c(n)):s&&i.video.push.apply(i.video,c(n)),o=!1;var g=t.map((function(e){return jg(e,"URI")}));return d=i.audio.find((function(e){return e&&e.N().find((function(e){return g.includes(e)}))})),n=mi("video",s=um(e,t[0])),(u=mi("audio",s))&&!n?(d="audio",o=0<i.audio.length):!i.audio.length&&!i.video.length&&u&&n?(d="video",s=[[n,u].join()]):i.audio.length&&d?(d="audio",o=!0):d=i.video.length&&!i.audio.length?"audio":"video",o||(e=function(e,t,n,i){for(var r=e.C++,a=[],o=l(t),s=o.next();!s.done;s=o.next()){var u=s.value;s=jg(u,"URI"),u=Ng(u,"PATHWAY-ID"),e.j&&u&&bp(e.j,r,u,s),a.push(s)}if(o=a.sort().join(","),e.i.has(o))return e.i.get(o);e:{if(t=Ng(t[0],"CLOSED-CAPTIONS"),"video"==i){if(e.g.disableText){e.S=!1,t=null;break e}if(t){if("NONE"!=t){t=e.F.get(t);break e}e.S=!1}else if(!t&&e.F.size)for(t=l(e.F.keys()).next();!t.done;){t=e.F.get(t.value);break e}}t=null}return i=hm(e,r,a,n=gi(i,n),i,null,!1,null,null,t,null,!1,null,!1),e.i.set(o,i),i}(e,t,s,d),r&&(e.stream.groupId=r),i[e.stream.type]=[e]),i}function um(e,t){var n=Ng(t,"CODECS")||"";return t=Ng(t,"SUPPLEMENTAL-CODECS"),e.fa=0<n.length,e.fa||e.g.hls.disableCodecGuessing||(n=[],e.g.disableVideo||n.push(e.g.hls.defaultVideoCodec),e.g.disableAudio||n.push(e.g.hls.defaultAudioCodec),n=n.join(",")),e=n.split(/\s*,\s*/),t&&(t=t.split(/\s*,\s*/).map((function(e){return e.split("/")[0]})),e.push.apply(e,c(t))),Cu(e)}function lm(e,t,n,i,r,a,o,s,u,c,d,h){for(var f=l(n),p=f.next();!p.done;p=f.next())Lm(p.value.stream,r,a,o,s,u,null);for(r=e.g.disableAudio,t.length&&!r||(t=[null]),r=e.g.disableVideo,n.length&&!r||(n=[null]),r=[],a=(t=l(t)).next();!a.done;a=t.next())for(a=a.value,s=(o=l(n)).next();!s.done;s=o.next()){var g=s.value;(s=a?a.stream:null)&&(s.drmInfos=c,s.keyIds=d),(u=g?g.stream:null)&&(u.drmInfos=c,u.keyIds=d,e.g.disableIFrames||Sr(u,h)),u&&!s&&(u.bandwidth=i),!u&&s&&(s.bandwidth=i),f=a?a.stream.drmInfos:null,p=g?g.stream.drmInfos:null,g=(g=g?g.N().sort().join(","):"")+" - "+(a?a.N().sort().join(","):""),s&&u&&!Le(f,p)||e.Na.has(g)||(s={id:e.C++,language:s?s.language:"und",disabledUntilTime:0,primary:!!s&&s.primary||!!u&&u.primary,audio:s,video:u,bandwidth:i,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},r.push(s),e.Na.add(g))}return r}function cm(e,t,n,i){i=void 0===i||i;for(var r=[],a=[],o=new Map,s=l(t),u=s.next();!u.done;u=s.next()){var c=u.value;u=i?jg(c,"URI"):Ng(c,"URI")||"shaka://hls-muxed",c=jg(c,"GROUP-ID"),r.push(u),a.push(c),o.set(c,u)}if(i=a.sort().join(","),u=t[0],t="","subtitles"==(s=jg(u,"TYPE").toLowerCase())&&(s=yi),s==yi)t=Ng(u,"CODECS")||"";else for(c=(a=l(a)).next();!c.done;c=a.next())if(c=c.value,e.G.has(c)){t=e.G.get(c);break}if(a=r.sort().join(","),e.i.has(a))return e.i.get(a);if(c=e.C++,e.j)for(var d=(o=l(o)).next();!d.done;d=o.next()){var h=l(d.value);d=h.next().value,h=h.next().value,(d=n.get(d))&&bp(e.j,c,d,h)}n=Ng(u,"LANGUAGE"),o=Ng(u,"NAME"),d="YES"==Ng(u,"DEFAULT"),h="audio"==s&&(h=Ng(u,"CHANNELS"))?parseInt(h.split("/")[0],10):null;var f="audio"==s&&!!(f=Ng(u,"CHANNELS"))&&f.includes("/JOC");return(r=hm(e,c,r,t,s,n,d,o,h,null,Ng(u,"CHARACTERISTICS"),"YES"==Ng(u,"FORCED"),u="audio"==s&&(u=Ng(u,"SAMPLE-RATE"))?parseInt(u,10):null,f)).stream&&(r.stream.groupId=i),e.H.has(i)?e.H.get(i).push(r):e.H.set(i,[r]),e.i.set(a,r),r}function dm(e,t){var n="video",i=jg(t,"URI"),r=Ng(t,"CODECS")||"";if("mjpg"==r&&(n="image"),e.i.has(i))return e.i.get(i);var a=Ng(t,"LANGUAGE"),o=Ng(t,"NAME"),s=Ng(t,"CHARACTERISTICS");return n=hm(e,e.C++,[i],r,n,a,!1,o,null,null,s,!1,null,!1),a=l((r=Ng(t,"RESOLUTION"))?r.split("x"):[null,null]),r=a.next().value,a=a.next().value,n.stream.width=Number(r)||void 0,n.stream.height=Number(a)||void 0,(t=Ng(t,"BANDWIDTH"))&&(n.stream.bandwidth=Number(t)),e.i.set(i,n),n}function hm(e,t,n,i,r,a,o,s,u,c,d,h,f,p){function g(){return e.j&&1<n.length?wp(e.j,t):y.concat(Gg([e.M],n,e.A))}var m=bm(e,i,r,a,o,s,u,c,d,h,f,p);n.includes("shaka://hls-muxed")&&(m.isAudioMuxedInVideo=!0,m.mimeType="video/mp2t",om(m));var v,y=[],b={stream:m,type:r,Wg:y,N:g,xc:0,Lb:0,Yd:new Map,Jd:!1,Id:!1,kd:!1,Ue:-1,sb:-1,ub:-1,zf:!1},x=null;return m.createSegmentIndex=function(){return x||(m.isAudioMuxedInVideo?(m.segmentIndex=new Zs([]),Promise.resolve()):(v=Nm(e,b.N(),!0),x=new Promise((function(t){t(function(t){var n,v,x,k,I,M,C,D,R,L,N,j,O,U,_,B,F,V,H,G,K,X;return P((function(P){switch(P.g){case 1:return n=bi,S(P,2),v=b.N(),w(P,t.promise,4);case 4:if(x=P.h,t.aborted)return P.return();if((k=x.uri)==x.originalUri||v.includes(k)||y.push(k),1!=(I=qg(e.Ka,x.data)).type)throw new De(2,4,4017);return M=_g(I.X,"EXT-X-DEFINE"),C=am(e,M,k),D=!1,(!e.fa&&e.g.hls.disableCodecGuessing||e.S&&r==n.la&&!e.g.hls.disableClosedCaptionsDetection)&&0<I.segments.length&&(e.S=!1,D=!0),R=!e.fa&&e.g.hls.disableCodecGuessing,L=Om(e),w(P,vm(e,0,C,I,g,i,r,a,o,s,u,c,d,h,f,p,void 0,D,R),5);case 5:if(N=P.h,t.aborted)return P.return();if(j=N.stream,Sm(e,I),Om(e)&&!L&&Am(e,I),b.xc=N.xc,b.Lb=N.Lb,b.Jd=N.Jd,b.Id=N.Id,b.kd=N.kd,b.Yd=N.Yd,b.sb=N.sb,b.ub=N.ub,b.zf=!0,m.segmentIndex=j.segmentIndex,m.encrypted=j.encrypted,m.drmInfos=j.drmInfos,m.keyIds=j.keyIds,m.mimeType=j.mimeType,m.bandwidth=m.bandwidth||j.bandwidth,m.codecs=m.codecs||j.codecs,m.closedCaptions=m.closedCaptions||j.closedCaptions,m.width=m.width||j.width,m.height=m.height||j.height,m.hdr=m.hdr||j.hdr,m.colorGamut=m.colorGamut||j.colorGamut,m.frameRate=m.frameRate||j.frameRate,"und"==m.language&&"und"!=j.language&&(m.language=j.language),m.language=m.language||j.language,m.channelsCount=m.channelsCount||j.channelsCount,m.audioSamplingRate=m.audioSamplingRate||j.audioSamplingRate,om(m),m.drmInfos.length&&e.h.newDrmInfo(m),O=!1,(!c&&m.closedCaptions||c&&m.closedCaptions&&c.size!=m.closedCaptions.size)&&(O=!0),e.m&&O&&e.h.makeTextStreamsForClosedCaptions(e.m),r==n.la||r==n.V)for(U=l(e.i.values()),_=U.next();!_.done;_=U.next())(B=_.value).zf||B.type!=r||(B.stream.mimeType=j.mimeType,om(B.stream));r==n.wa&&(F=eu(j.segmentIndex))&&F.ba&&(m.mimeType="application/mp4",om(m)),V=Iu(m),m.segmentIndex.yb((function(e){e.ba&&(e.ba.Qc=V)})),function(e){if(!e.m)return!1;for(var t=[],n=[],i=(e=l(e.m.variants)).next();!i.done;i=e.next())(i=i.value).video&&t.push(i.video),i.audio&&n.push(i.audio);return!(0<t.length&&!t.some((function(e){return e.segmentIndex}))||0<n.length&&!n.some((function(e){return e.segmentIndex})))}(e)&&(e.ac?gm(e,[b]):(e.ac=!0,H=Array.from(e.i.values()),G=H.filter((function(e){return e.stream.segmentIndex})),gm(e,G),rm(e),0<(K=e.o)&&e.B.$(K))),Mm(e,I.X,m.type,C,g),e.m&&(e.m.startTime=e.s),A(P,0);break;case 2:if(X=E(P),m.closeSegmentIndex(),7001===X.code)return P.return();if(!e.h.disableStream(m))throw X;T(P)}}))}(v))}))))},m.closeSegmentIndex=function(){x&&!m.segmentIndex&&v.abort(),m.segmentIndex&&(m.segmentIndex.release(),m.segmentIndex=null),x=null},b}function fm(e){for(var t=1/0,n=(e=l(e.i.values())).next();!n.done;n=e.next())(n=n.value).stream.segmentIndex&&"text"!=n.stream.type&&!n.stream.isAudioMuxedInVideo&&(t=Math.min(t,n.Lb));return t}function pm(e,t){for(var n=[],i=(t=l(t)).next();!i.done;i=t.next())(i=i.value).segmentIndex&&i.segmentIndex.yb((function(e){n.push(e)}));e.l.vd(n)}function gm(e,t){if(!Om(e))for(var n=fm(e),i=l(t),r=i.next();!r.done;r=i.next())r.value.stream.segmentIndex.Kc(0,n);pm(e,t.map((function(e){return e.stream}))),n=Om(e)&&!e.bc,e.g.hls.ignoreManifestProgramDateTime||n?nm(e,t,n):(function(e,t){if(1/0==e.ga)for(var n=(t=l(t)).next();!n.done;n=t.next())null!=(n=eu(n.value.stream.segmentIndex))&&null!=n.h&&(e.ga=Math.min(e.ga,n.h));if(1/0!=(t=e.ga))for(var i=(n=l(e.i.values())).next();!i.done;i=n.next())if(!mm(e,(i=i.value).type)){var r=i.stream.segmentIndex;if(null!=r){var a=eu(r);if(a)if(null==a.h)z("Missing EXT-X-PROGRAM-DATE-TIME for stream",i.N(),"Expect AV sync issues!");else for(im(e,i,a.h-t-a.startTime),r=(i=l(r)).next();!r.done;r=i.next())r.value.Yf(t)}}}(e,t),0<e.g.hls.ignoreManifestProgramDateTimeForTypes.length&&nm(e,t))}function mm(e,t){return!!e.g.hls.ignoreManifestProgramDateTime||e.g.hls.ignoreManifestProgramDateTimeForTypes.includes(t)}function vm(e,t,n,i,r,a,o,s,u,c,d,h,f,p,g,m,v,y,b){var T,x,k,I,M,C,D,R,L,N,j,O,U,_,B,F,V,H,G,K,X,q,z,W,Y,J,$,Q,Z;return y=void 0===y||y,b=void 0===b||b,P((function(t){switch(t.g){case 1:if(T=i.segments||[],x=T.every((function(e){return!!Fg(e.X,"EXT-X-GAP")})),!T.length||x)throw new De(2,4,4053);if(function(e,t){var n=Fg(t.X,"EXT-X-PLAYLIST-TYPE");t=Fg(t.X,"EXT-X-ENDLIST"),t=n&&"VOD"==n.value||t,n=n&&"EVENT"==n.value&&!t,n=!t&&!n,Um(e,t?Xm:n?zm:qm)}(e,i),Om(e)&&xm(e,i),k=Om(e)?e.O.get(o):new Map,I=Cm(e,i,k,n,r,o),M=I.segments,C=I.bandwidth,j=N=L=R=D=null,!(0<M.length&&y)){t.u(2);break}return w(t,function(e,t){var n,i,r,a,o,s,u,c,d,h,f,p,g,m,v,y,b,T,S,x,A,E,k;return P((function(I){switch(I.g){case 1:if(n=Mu(e.g.hls.mediaPlaylistFullMimeType),!t.length)return I.return(n);if(i=Pm(e,t),r=i.segment,a=i.segmentIndex,o=r.N(),s=o[0],u=new Gn(s),c=u.Ua.split(".").pop(),d=Vm[c])return I.return(Mu(d));if(h=ca,p=f=null,!(g=r.ba)){I.u(2);break}return m=Ru(g.N(),g.Zb(),g.Xb(),e.g.retryParameters),w(I,_m(e,m,h,{type:0}).promise,3);case 3:if(v=I.h,f=v.data,!g.aesKey){I.u(4);break}return w(I,Du(f,g.aesKey,0),5);case 5:f=I.h;case 4:(p=v.headers["content-type"])&&(p=p.split(";")[0].toLowerCase());case 2:return y=Ru(r.N(),r.Zb(),r.Xb(),e.g.retryParameters),w(I,_m(e,y,h,{type:1}).promise,6);case 6:if(b=I.h,T=b.data,!r.aesKey){I.u(7);break}return w(I,Du(T,r.aesKey,a),8);case 8:T=I.h;case 7:if((S=b.headers["content-type"])&&(S=S.split(";")[0].toLowerCase()),x="mp4 mp4a m4s m4i m4a m4f cmfa mp4v m4v cmfv fmp4".split(" "),A=["audio/mp4","video/mp4","video/iso.segment"],os(ge(T))){var M=T,C=ge(M),D=(C=(new ns).parse(C)).fd();C=C.nf();var R=[],P=!1,L=!1;switch(D.audio){case"aac":case"aac-loas":R.push("mp4a.40.2"),P=!0;break;case"mp3":R.push("mp4a.40.34"),P=!0;break;case"ac3":R.push("ac-3"),P=!0;break;case"ec3":R.push("ec-3"),P=!0;break;case"opus":R.push("opus"),P=!0}switch(D.video){case"avc":C.codec?R.push(C.codec):R.push("avc1.42E01E"),L=!0;break;case"hvc":C.codec?R.push(C.codec):R.push("hvc1.1.6.L93.90"),L=!0;break;case"av1":R.push("av01.0.01M.08"),L=!0}if(R.length){if(D=P&&!L,P=new Map,L){(L=new we("video/mp2t")).i(M);for(var N=(M=l(L.j())).next();!N.done;N=M.next())N=N.value,P.set(N,N);L.g()}C={type:D?"audio":"video",mimeType:"video/mp2t",codecs:R.join(", "),language:null,height:C.height,width:C.width,channelCount:null,sampleRate:null,closedCaptions:P,Cd:null,colorGamut:null,frameRate:C.frameRate}}else C=null;if(E=C)return I.return(E)}else if((x.includes(c)||A.includes(S)||p&&A.includes(p))&&(k=function(e,t){function n(e){a=e.name;var t=e.reader;t.skip(24);var n=t.ma(),i=t.ma();t.skip(50),f=String(n),h=String(i),e.reader.sa()&&Sa(e)}function i(e){var t=Fo(e.reader);p=t.channelCount,g=t.sampleRate,r(e.name)}function r(e){switch(e=e.toLowerCase()){case"avc1":case"avc3":s.push(e+".42E01E"),c=!0;break;case"hev1":case"hvc1":s.push(e+".1.6.L93.90"),c=!0;break;case"dvh1":case"dvhe":s.push(e+".05.04"),c=!0;break;case"vp09":s.push(e+".00.10.08"),c=!0;break;case"av01":s.push(e+".0.01M.08"),c=!0;break;case"mp4a":o.push("mp4a.40.2"),u=!0;break;case"ac-3":case"ec-3":case"ac-4":case"opus":case"flac":o.push(e),u=!0}}var a,o=[],s=[],u=!1,c=!1,d=null,h=null,f=null,p=null,g=null,m=null,v=null;if((new Ta).box("moov",Sa).box("trak",Sa).box("mdia",Sa).R("mdhd",(function(e){d=_o(e.reader,e.version).language})).box("minf",Sa).box("stbl",Sa).R("stsd",xa).box("mp4a",(function(e){var t=Fo(e.reader);p=t.channelCount,g=t.sampleRate,e.reader.sa()?Sa(e):r(e.name)})).box("esds",(function(e){e=e.reader;for(var t,n,i="mp4a";e.sa();){t=e.T();for(var r=e.T();128&r;)r=e.T();if(3==t)e.ma(),128&(r=e.T())&&e.ma(),64&r&&e.skip(e.T()),32&r&&e.ma();else if(4==t)n=e.T(),e.skip(12);else if(5==t)break}n&&(i+="."+Ho(n),5==t&&e.sa()&&(31==(n=(248&(t=e.T()))>>3)&&e.sa()&&(n=32+((7&t)<<3)+((224&e.T())>>5)),i+="."+n)),o.push(i),u=!0})).box("ac-3",i).box("ec-3",i).box("ac-4",i).box("Opus",i).box("fLaC",i).box("avc1",n).box("avc3",n).box("hev1",n).box("hvc1",n).box("dva1",n).box("dvav",n).box("dvh1",n).box("dvhe",n).box("vp09",n).box("av01",n).box("avcC",(function(e){var t=a||"";switch(a){case"dvav":t="avc3";break;case"dva1":t="avc1"}(e=e.reader).skip(1),e=t+"."+Ho(e.T())+Ho(e.T())+Ho(e.T()),s.push(e),c=!0})).box("hvcC",(function(e){var t=a||"";switch(a){case"dvh1":t="hvc1";break;case"dvhe":t="hev1"}var n=e.reader;n.skip(1);var i=["","A","B","C"][(e=n.T())>>6],r=31&e,o=n.P(),u=(32&e)>>5?"H":"L";e=[n.T(),n.T(),n.T(),n.T(),n.T(),n.T()],n=n.T();for(var l=0,d=0;32>d&&(l|=1&o,31!=d);d++)l<<=1,o>>=1;for(t=t+"."+i+r+"."+Ho(l,!0),t+="."+u+n,i="",r=e.length;r--;)((u=e[r])||i)&&(i="."+u.toString(16).toUpperCase()+i);t+=i,s.push(t),c=!0})).box("dvcC",(function(e){var t=a||"";switch(a){case"hvc1":t="dvh1";break;case"hev1":t="dvhe";break;case"avc1":t="dva1";break;case"avc3":t="dvav";break;case"av01":t="dav1"}var n=e.reader;n.skip(2),e=n.T(),n=n.T(),s.push(t+"."+Go(e>>1&127)+"."+Go(e<<5&32|n>>3&31)),c=!0})).box("dvvC",(function(e){var t=a||"";switch(a){case"hvc1":t="dvh1";break;case"hev1":t="dvhe";break;case"avc1":t="dva1";break;case"avc3":t="dvav";break;case"av01":t="dav1"}var n=e.reader;n.skip(2),e=n.T(),n=n.T(),s.push(t+"."+Go(e>>1&127)+"."+Go(e<<5&32|n>>3&31)),c=!0})).R("vpcC",(function(e){var t=a||"",n=e.reader;e=n.T();var i=n.T();n=n.T()>>4&15,s.push(t+"."+Go(e)+"."+Go(i)+"."+Go(n)),c=!0})).box("av1C",(function(e){var t=a||"";"dav1"===a&&(t="av01");var n=e.reader;n.skip(1);var i=(e=n.T())>>>5,r=(64&(n=n.T()))>>6;s.push(t+"."+i+"."+Go(31&e)+(n>>>7?"H":"M")+"."+Go(2===i&&r?(32&n)>>5?12:10:r?10:8)+"."+((16&n)>>4)+"."+((8&n)>>3)+((4&n)>>2)+(3&n)+"."+Go(1)+"."+Go(1)+"."+Go(1)+".0"),c=!0})).box("enca",Ea).box("encv",Aa).box("sinf",Sa).box("frma",(function(e){r(e=Vo(e.reader).codec)})).box("colr",(function(e){s=s.map((function(t){if(t.startsWith("av01.")){var n=e.reader,i=n.ya(),r=n.vb(4),a=String.fromCharCode(r[0]);if(a+=String.fromCharCode(r[1]),a+=String.fromCharCode(r[2]),"nclx"===(a+=String.fromCharCode(r[3]))){r=n.ma(),a=n.ma();var o=n.ma(),s=n.T()>>7,u=t.split(".");10==u.length&&(u[6]=Go(r),u[7]=Go(a),u[8]=Go(o),u[9]=String(s),t=u.join("."))}n.seek(i)}return t}));var t=function(e){var t=null,n=null,i=e.vb(4),r=String.fromCharCode(i[0]);if(r+=String.fromCharCode(i[1]),r+=String.fromCharCode(i[2]),"nclx"===(r+=String.fromCharCode(i[3]))){switch(e.ma()){case 1:case 5:case 6:case 7:t="srgb";break;case 9:t="rec2020";break;case 11:case 12:t="p3"}switch(i=e.ma(),e.ma(),i){case 1:case 6:case 13:case 14:case 15:n="SDR";break;case 16:n="PQ";break;case 18:n="HLG"}}return{colorGamut:t,Cd:n}}(e.reader),n=t.colorGamut;m=t.Cd,v=n})).parse(e||t,!0),!o.length&&!s.length)return null;var y=u&&!c,b=new Map;if(c){var w=new we("video/mp4");e&&w.init(e);try{w.i(t);for(var T=l(w.j()),S=T.next();!S.done;S=T.next()){var x=S.value;b.set(x,x)}}catch(e){}w.g()}return{type:y?"audio":"video",mimeType:y?"audio/mp4":"video/mp4",codecs:Cu(o.concat(s)).join(", "),language:d,height:h,width:f,channelCount:p,sampleRate:g,closedCaptions:b,Cd:m,colorGamut:v,frameRate:null}}(f,T)))return I.return(k);return S?I.return(Mu(S)):p?I.return(Mu(p)):I.return(n)}}))}(e,M),3);case 3:O=t.h,o=O.type,s=O.language,d=O.channelCount,g=O.sampleRate,e.g.disableText||(h=O.closedCaptions),R=O.height,D=O.width,L=O.Cd,N=O.colorGamut,j=O.frameRate,b&&(v=O.mimeType,a=O.codecs);case 2:if(v){t.u(4);break}return w(t,function(e,t,n,i){var r,a,o,s,u,l,c,d,h,f,p,g,m,v;return P((function(y){switch(y.g){case 1:return r=ca,a=Pm(e,i),2==(o=a.segment).status?y.return(Rm(t)):(s=o.N(),u=new Gn(s[0]),l=u.Ua.split(".").pop(),c=Hm[t],(d=c[l])||(d=Vm[l])||(d=Dm(t,n))?y.return(d):(f=1,p=aa(s,e.g.retryParameters),S(y,2),p.method="HEAD",w(y,_m(e,p,r,{type:f}).promise,4)));case 4:g=y.h,h=g.headers["content-type"],A(y,3);break;case 2:if(!(m=E(y))||1002!=m.code&&1001!=m.code){y.u(3);break}return p.method="GET",w(y,_m(e,p,r,{type:f}).promise,6);case 6:v=y.h,h=v.headers["content-type"];case 3:return h?y.return(h.toLowerCase().split(";")[0]):y.return(Rm(t))}}))}(e,o,a,M),5);case 5:v=t.h;case 4:return w(t,wm(e,i,v,r,n),6);case 6:if(U=t.h,_=U.drmInfos,B=U.keyIds,F=U.encrypted,V=U.zh,F&&!_.length&&!V)throw new De(2,4,4026);return(H=bm(e,a,o,s,u,c,d,h,f,p,g,m)).encrypted=F,H.drmInfos=_,H.keyIds=B,H.mimeType=v,C&&(H.bandwidth=C),om(H),"video"==o&&(D||R||L||N)&&Lm(H,D,R,j,L,null,N),Om(e)&&xm(e,i),G=M[0].startTime,K=M[M.length-1],X=K.endTime,q=new Zs(M),H.segmentIndex=q,W=!!(z=Fg(i.X,"EXT-X-SERVER-CONTROL"))&&null!=Lg(z,"CAN-SKIP-UNTIL"),Y=!!z&&null!=Lg(z,"CAN-BLOCK-RELOAD"),J=Vg(i.X,"EXT-X-MEDIA-SEQUENCE",0),$=ym(J,M),Q=$.sb,Z=$.ub,t.return({stream:H,type:o,Wg:[],N:r,xc:G,Lb:X,Jd:W,Id:Y,kd:!1,Ue:-1,sb:Q,ub:Z,Yd:k,zf:!1})}}))}function ym(e,t){e=e+t.length-1;var n=-1;if(!t.length)return{sb:++e,ub:n};var i=(t=t[t.length-1]).g;return t.g.length?(n=i.length-1,i[i.length-1].isPreload()||(e++,n=0),{sb:e,ub:n}):(e++,t.m&&(n=0),{sb:e,ub:n})}function bm(e,t,n,i,r,a,o,s,u,c,d,h){var f=Dm(n,t)||Rm(n),p=[];if(u)for(var g=(u=l(u.split(","))).next();!g.done;g=u.next())p.push(g.value);return u=void 0,g=null,n==yi?u=p.includes("public.accessibility.transcribes-spoken-dialog")&&p.includes("public.accessibility.describes-music-and-sound")?"caption":"subtitle":p.includes("public.accessibility.describes-video")&&(g="visually impaired"),p.length||"subtitle"!==u||p.push("subtitle"),om(e={id:e.C++,originalId:a,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:f,codecs:t,kind:n==yi?"subtitle":void 0,encrypted:!1,drmInfos:[],keyIds:new Set,language:Yi(i||"und"),originalLanguage:i,label:a,type:n,primary:r,trickModeVideo:null,emsgSchemeIdUris:null,frameRate:void 0,pixelAspectRatio:void 0,width:void 0,height:void 0,bandwidth:void 0,roles:p,forced:c,channelsCount:o,audioSamplingRate:d,spatialAudio:h,closedCaptions:s,hdr:void 0,colorGamut:void 0,videoLayout:void 0,tilesLayout:void 0,accessibilityPurpose:g,external:!1,fastSwitching:!1,fullMimeTypes:new Set,isAudioMuxedInVideo:!1}),e}function wm(e,t,n,i,r){var a,o,s,u,c,d,h,f,p,g,m,v,y,b,T,S,x,A,E,k,I,M,C,D,R,L,N,j;return P((function(P){switch(P.g){case 1:if(a=new Map,t.segments)for(o=l(t.segments),s=o.next();!s.done;s=o.next())if(u=s.value,c=_g(u.X,"EXT-X-KEY"),d=null,c.length)for(d=Em(e,t,u.X,i,r),h=l(c),f=h.next();!f.done;f=h.next())p=f.value,a.set(p,d);m=g=!1,v=[],y=new Set,b=l(a),T=b.next();case 2:if(T.done){P.u(4);break}if(S=T.value,x=l(S),A=x.next().value,E=x.next().value,I=E,"NONE"==(M=jg(k=A,"METHOD"))){P.u(3);break}if(g=!0,C=Ng(k,"KEYFORMAT")||"identity",D=null,Bm(M)){m=!0,P.u(3);break}if("identity"!=C){D=(R=Km[C])?R(k,n):null,P.u(6);break}return w(P,Fm(e,k,n,i,I,r),8);case 8:D=P.h;case 6:if(D){if(D.keyIds)for(L=l(D.keyIds),N=L.next();!N.done;N=L.next())j=N.value,y.add(j);v.push(D)}case 3:T=b.next(),P.u(2);break;case 4:return P.return({drmInfos:v,keyIds:y,encrypted:g,zh:m})}}))}function Tm(t,n,i,r,a){if(!e.crypto||!e.crypto.subtle)throw W("Web Crypto API is not available to decrypt AES. (Web Crypto only exists in secure origins like https)"),new De(2,4,4042);var o=0,s=Ng(n,"IV","");if(s){var u=li(s.substr(2));if(16!=u.byteLength)throw new De(2,4,4048)}else o=Vg(i.X,"EXT-X-MEDIA-SEQUENCE",0);if(i=n.toString()+"-"+o,!t.ja.has(i)){var l={bitsKey:128,blockCipherMode:"CBC",iv:u,firstMediaSequenceNumber:o};switch(jg(n,"METHOD")){case"AES-256":l.bitsKey=256;break;case"AES-256-CTR":l.bitsKey=256,l.blockCipherMode="CTR"}l.fetchKey=function(){var i,o,s,u,c,d;return P((function(h){if(1==h.g)return i=Hg(r(),jg(n,"URI"),a),o=i.sort().join(""),t.L.has(o)||(s=aa(i,t.g.retryParameters),u=_m(t,s,6).promise,t.L.set(o,u)),w(h,t.L.get(o),2);if(3!=h.g){if(!(c=h.h).data||c.data.byteLength!=l.bitsKey/8)throw new De(2,4,4049);return d={name:"CTR"==l.blockCipherMode?"AES-CTR":"AES-CBC",length:l.bitsKey},w(h,e.crypto.subtle.importKey("raw",c.data,d,!0,["decrypt"]),3)}l.cryptoKey=h.h,l.fetchKey=void 0,T(h)}))},t.ja.set(i,l)}return t.ja.get(i)}function Sm(e,t){null==e.s&&(t=Fg(t.X,"EXT-X-START"))&&(e.s=Number(jg(t,"TIME-OFFSET")))}function xm(e,t){var n=1/0,i=t.segments;if(i.length)for(var r=i.length-1;0<=r;){var a=Fg(i[r].X,"EXTINF");if(a){n=Number(a.value.split(",")[0]);break}r--}if(!(i=Fg(t.X,"EXT-X-TARGETDURATION")))throw new De(2,4,4024,"EXT-X-TARGETDURATION");i=Number(i.value),(r=Fg(t.X,"EXT-X-PART-INF"))&&(e.Y=Number(jg(r,"PART-TARGET"))),t=Fg(t.X,"EXT-X-SERVER-CONTROL"),e.K&&e.Y?(e.o=e.Ib?5*e.Y<=n?Math.min(e.Y,e.o):Math.min(n,e.o):Math.min(e.Y,e.o),e.Ga=t?Number(jg(t,"PART-HOLD-BACK")):0):(e.o=Math.min(n,e.o),n=t?Lg(t,"HOLD-BACK"):null,e.Ba=n?Number(n.value):0),e.La=Math.max(i,e.La)}function Am(e,t){var n=0;if(e.g.defaultPresentationDelay)n=e.g.defaultPresentationDelay;else if(e.Ga)n=e.Ga;else if(e.Ba)n=e.Ba;else{var i=t.segments.length,r=e.g.hls.liveSegmentsDelay;for(r>i-2&&(r=Math.max(1,i-2)),r=i-r;r<i;r++){var a=Fg(t.segments[r].X,"EXTINF");n=a?n+Math.ceil(Number(a.value.split(",")[0])):n+e.La}}e.s&&0>e.s&&(n=Math.min(-e.s,n),e.s+=n),e.l.gh(0),e.l.Sf(n),e.l.Bc(!1)}function Em(e,t,n,i,r){var a=Fg(n,"EXT-X-MAP");if(!a)return null;var o=jg(a,"URI"),s=Hg(i(),o,r);if(o=[s.toString(),Ng(a,"BYTERANGE","")].join("-"),!e.ta.has(o)){for(var u=void 0,c=null,d=(n=l(n)).next();!d.done;d=n.next())"EXT-X-KEY"==(d=d.value).name?Bm(jg(d,"METHOD"))&&d.id<a.id&&(u=Tm(e,d,t,i,r)):"EXT-X-BYTERANGE"==d.name&&d.id<a.id&&(c=d);t=function(e,t,n,i){var r=0,a=null;return!(t=Ng(t,"BYTERANGE"))&&n&&(t=n.value),t&&(r=t.split("@"),a=Number(r[0]),a=(r=Number(r[1]))+a-1,i&&((n=a+1-r)%16&&(a+=16-n%16))),new go((function(){return e}),r,a,null,null,null,i)}(s,a,c,u),e.ta.set(o,t)}return e.ta.get(o)}function km(t,n,i,r,a,o,s,u,c){function d(e){e=new Gn(e).Ua.split(".").pop();var t=Hm[s][e];return t||(t=Vm[e]),t}var h=r.X,f=Fg(h,"EXTINF"),p=0,g=0,m=null;r.Cb.length&&(t.m.isLowLatency=!0);var v=null;if(!t.g.hls.ignoreManifestProgramDateTime){var y=Fg(h,"EXT-X-PROGRAM-DATE-TIME");y&&y.value&&(v=Kt(y.value),t.bc=!0)}var b=bo;if(Fg(h,"EXT-X-GAP")&&(t.m.gapCount++,b=2),!f){if(0==r.Cb.length)throw new De(2,4,4024,"EXTINF");if(!t.K)return null}var w=[];y=!1;var T=null,S=!1,x=!1;if(t.K&&r.Cb.length){p=n&&e.ReadableStream&&t.g.hls.allowLowLatencyByteRangeOptimization;for(var A=v,E={},k=0;k<r.Cb.length;E={xe:void 0,fe:void 0},k++){var I=r.Cb[k],M=0==k?i:w[w.length-1],C=0==k?a:M.endTime,D=Number(Ng(I,"DURATION"))||t.Y;if(D){var R=C+D,P=0,L=null;if("EXT-X-PRELOAD-HINT"==I.name?(P=(P=Ng(I,"BYTERANGE-START"))?Number(P):0,(M=Ng(I,"BYTERANGE-LENGTH"))?L=P+Number(M)-1:P&&(L=Number.MAX_SAFE_INTEGER)):(P=(L=l(Im(M,P=Ng(I,"BYTERANGE")))).next().value,L=L.next().value),E.fe=Ng(I,"URI"),E.fe){M=bo,"YES"==Ng(I,"GAP")&&(t.m.gapCount++,M=2,S=!0),E.xe=null;var N=function(e){return function(){return null==e.xe&&(e.xe=Hg(u(),e.fe,o)),e.xe}}(E);p&&0<=P&&null!=L&&(T=N,y=!0),C=new vo(C,R,N,P,L,n,0,0,1/0,[],"",null,A,M,c),"EXT-X-PRELOAD-HINT"==I.name&&(C.Af(),x=!0),"YES"!=Ng(I,"INDEPENDENT")&&0<k&&C.Pc(),(E=d(E.fe))&&(C.mimeType=E,Gm.has(E)&&(C.ba=null)),w.push(C),A&&(A+=D)}}}}if(f){if(0==(f=Number(f.value.split(",")[0])))return null;p=a+f}else{if(!w.length)return null;p=w[w.length-1].endTime}y&&(S||0!=w[0].Ja?(y=!1,T=null):w=[]),(f=Fg(h,"EXT-X-BYTERANGE"))?(g=(m=l(Im(i,f.value))).next().value,m=m.next().value):w.length&&(g=w[0].Ja,m=w[w.length-1].va),i="",f=null,"image"==s&&(i="1x1",h=Fg(h,"EXT-X-TILES"))&&(i=jg(h,"LAYOUT"),(h=Ng(h,"DURATION"))&&(f=Number(h)));var j=null;return n=new vo(a,p,(function(){return T?T():(null==j&&(j=Hg(u(),r.g,o)),j||[])}),g,m,n,0,0,1/0,w,i,f,v,b,c,0<w.length&&!!r.g),(a=d(r.g))&&(n.mimeType=a,Gm.has(a)&&(n.ba=null)),y&&(t.Ib=!0,n.Lg(),x&&n.Af()),n}function Im(e,t){var n=0,i=null;return t&&(n=t.split("@"),t=Number(n[0]),i=(n=n[1]?Number(n[1]):e.va+1)+t-1),[n,i]}function Mm(e,t,n,i,r){if("video"==n||"audio"==n){var a=e.l.m;if(a&&!mm(e,n))for(t=(t=_g(t,"EXT-X-DATERANGE")).sort((function(e,t){return(e=jg(e,"START-DATE"))<(t=jg(t,"START-DATE"))?-1:e>t?1:0})),n=0;n<t.length;n++){var o=t[n];try{var s=jg(o,"ID");if(!e.Aa.has(s)){var u=Kt(jg(o,"START-DATE"));if(!isNaN(u)){var c=Math.max(0,u-a),d=null,h=Ng(o,"END-DATE");if(h){var f=Kt(h);if(!isNaN(f)&&0>(d=f-a))continue}if(null==d){var p=Ng(o,"DURATION")||Ng(o,"PLANNED-DURATION");if(p){var g=parseFloat(p);if(isNaN(g)||(d=c+g),0>u-a+g)continue}}var m=Ng(o,"CLASS")||"com.apple.quicktime.HLS",v="YES"==Ng(o,"END-ON-NEXT");if(null==d&&v){for(var y=n+1;y<t.length;y++)if(m==(Ng(t[y],"CLASS")||"com.apple.quicktime.HLS")){var b=Kt(jg(t[y],"START-DATE"));if(!isNaN(b)&&b&&b>u){d=Math.max(0,b-a);break}}if(null==d)continue}y=["CLASS","START-DATE","END-DATE","DURATION","END-ON-NEXT"];for(var w=[],T=l(o.attributes),S=T.next();!S.done;S=T.next()){var x=S.value;if(!y.includes(x.name)){var A=Kg(x.value,i);"X-ASSET-URI"!=x.name&&"X-ASSET-LIST"!=x.name||(A=Hg(r(),x.value,i)[0]),w.push({key:x.name,description:"",data:A,mimeType:null,pictureType:null})}}1<w.length&&e.h.onMetadata(m,c,d,w),e.Aa.add(s)}}}catch(e){}}}}function Cm(e,t,n,i,r,a){var o=t.segments,s=void 0,u=Vg(t.X,"EXT-X-DISCONTINUITY-SEQUENCE",-1),c=Vg(t.X,"EXT-X-MEDIA-SEQUENCE",0),d=Fg(t.X,"EXT-X-SKIP"),h=d?Number(Ng(d,"SKIPPED-SEGMENTS")):0,f=c+h,p=0;Om(e)&&n.has(f)&&(p=n.get(f)),0===p&&e.xa==zm&&0<n.size&&!n.has(f)&&null!=e.l.i&&(p=e.l.qb());var g=[],m=null;d=[];for(var v=0;v<o.length;v++){var y=o[v],b=0==v?p:m.endTime;f=c+h+v,Fg(y.X,"EXT-X-DISCONTINUITY")&&u++;for(var w=l(y.X),T=w.next();!T.done;T=w.next())"EXT-X-KEY"==(T=T.value).name&&(s=Bm(jg(T,"METHOD"))?Tm(e,T,t,r,i):void 0);n.set(f,b),w=Em(e,t,y.X,r,i),!e.K&&e.h.isAutoLowLatencyMode()&&(e.h.enableLowLatencyMode(),e.K=e.h.isLowLatencyMode()),(b=km(e,w,m,y,b,i,a,r,s))&&((m=Vg(y.X,"EXT-X-BITRATE"))?d.push({bitrate:m,duration:b.endTime-b.startTime}):d.length&&((m=d.pop()).duration+=b.endTime-b.startTime,d.push(m)),m=b,b.i=u,mm(e,a)&&null!=e.I&&f<e.I||g.push(b))}if(t=void 0,d.length&&(t=d.reduce((function(e,t){return e+t.duration}),0),t=Math.round(d.reduce((function(e,t){return e+t.bitrate*t.duration}),0)/t*1e3)),d=g.some((function(e){return null!=e.h})))for(n={},i=0;i<g.length;n={Nd:void 0,Md:void 0,Fd:void 0,zc:void 0,Ed:void 0},i++)if(n.zc=g[i],null==n.zc.h)for(n.Md=0,n.Nd=i,r=function(e){return function(){var t=g[e.Nd];if(t){if(null!=t.h)return t.h+e.Md;e.Md-=t.endTime-t.startTime,e.Nd+=1}return null}}(n),n.Ed=0,n.Fd=i,o=function(e){return function(){var t=g[e.Fd];if(t){if(t!=e.zc&&(e.Ed+=t.endTime-t.startTime),null!=t.h)return t.h+e.Ed;--e.Fd}return null}}(n);null==n.zc.h;)n.zc.h=o(),null==n.zc.h&&(n.zc.h=r());if(d)for(i=(n=l(g)).next();!i.done;i=n.next())for(i=(r=i.value).h,o=(r=l(r.g)).next();!o.done;o=r.next())(o=o.value).h=i,i+=o.endTime-o.startTime;if(n=e.ga,d&&1/0!=n&&!mm(e,a))for(a=(e=l(g)).next();!a.done;a=e.next())a.value.Yf(n);return{segments:g,bandwidth:t}}function Dm(e,t){if(e==yi){if("vtt"==t||"wvtt"==t)return"text/vtt";if(t&&""!==t)return"application/mp4"}return"image"!=e||t&&"jpeg"!=t?"audio"==e&&"mp4a.40.34"==t?"audio/mpeg":"mjpg"==t?"application/mp4":null:"image/jpeg"}function Rm(e){return e==yi?"text/vtt":Hm[e].mp4}function Pm(e,t){for(var n=t[e=Om(e)?Math.trunc((t.length-1)/2):0];2==n.$b()&&e+1<t.length;)n=t[++e];return{segment:n,segmentIndex:e}}function Lm(e,t,n,i,r,a,o){e&&(e.width=Number(t)||void 0,e.height=Number(n)||void 0,e.frameRate=Number(i)||void 0,e.hdr=r||void 0,e.videoLayout=a||void 0,e.colorGamut=o||void 0)}function Nm(e,t,n){return _m(e,aa(t,e.g.retryParameters),0,{type:n?2:3})}function jm(e){var t,n,i,r,a,o;return P((function(s){switch(s.g){case 1:return e.h?(S(s,2),t=Date.now(),w(s,e.update(),4)):s.return();case 4:n=Date.now(),Om(e)&&(i=(n-t)/1e3,e.Gb.sample(1,i),r=0<e.g.hls.updatePeriod?e.g.hls.updatePeriod:e.o,a=Math.max(0,r-K(e.Gb)),e.B.$(a)),A(s,3);break;case 2:if(o=E(s),!e.h)return s.return();if(e.g.raiseFatalErrorOnManifestUpdateRequestFailure)return e.h.onError(o),s.return();o.severity=1,e.h.onError(o),e.B.$(.1);case 3:if(!e.h)return s.return();e.h.onManifestUpdated(),T(s)}}))}function Om(e){return e.xa!=Xm}function Um(e,t){e.xa=t,e.l&&e.l.Bc(!Om(e)),Om(e)||e.B.stop()}function _m(e,t,n,i){if(!e.da)throw new De(2,7,7001);return i||(i={}),i.isPreload=e.Hb(),t=e.h.networkingEngine.request(n,t,i),ta(e.da,t),t}function Bm(e){return"AES-128"==e||"AES-256"==e||"AES-256-CTR"==e}function Fm(e,t,n,i,r,a){var o,s,u,l,c,d,h,f,p,g,m,v,y;return P((function(b){switch(b.g){case 1:if("video/mp2t"==n)throw new De(2,4,4040);if(ot())throw new De(2,4,4041);if(o=jg(t,"METHOD"),!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(o))return b.return(null);if((s=Hg(i(),jg(t,"URI"),a))[0].startsWith("data:text/plain;base64,")){u=ci(ui(s[0].split("data:text/plain;base64,").pop())),b.u(2);break}return l=s.sort().join(""),e.ra.has(l)||(c=aa(s,e.g.retryParameters),d=_m(e,c,6).promise,e.ra.set(l,d)),w(b,e.ra.get(l),3);case 3:h=b.h,u=ci(h.data);case 2:if(f="00000000000000000000000000000000",!r){b.u(4);break}if(e.na.has(r)){p=e.na.get(r),b.u(5);break}return g=Ru(r.N(),r.Zb(),r.Xb(),e.g.retryParameters),w(b,_m(e,g,ca,{type:0}).promise,6);case 6:m=b.h,p=function(e){var t=null;return(new Ta).box("moov",Sa).box("trak",Sa).box("mdia",Sa).box("minf",Sa).box("stbl",Sa).R("stsd",xa).box("encv",Aa).box("enca",Ea).box("sinf",Sa).box("schi",Sa).R("tenc",(function(e){(e=e.reader).T(),e.T(),e.T(),e.T(),t=ci(e.vb(16))})).parse(e,!0),t}(m.data),e.na.set(r,p);case 5:p&&(f=p);case 4:return(v=new Map).set(f,u),y="cenc","SAMPLE-AES"==o&&(y="cbcs"),b.return(pi(v,y))}}))}F("shaka.net.DataUriPlugin",Jg),Jg.parse=$g,ia("data",$g),(i=Zg.prototype).configure=function(e,t){var n=this.h&&e.hls.updatePeriod!=this.g.hls.updatePeriod&&0<=e.hls.updatePeriod;this.g=e,t&&(this.Hb=t),this.j&&this.j.configure(this.g),n&&this.m&&this.m.presentationTimeline.U()&&this.B.hc()},i.start=function(e,t){var n,i=this;return P((function(r){return 1==r.g?(i.h=t,i.K=t.isLowLatencyMode(),w(r,Nm(i,[e]).promise,2)):3!=r.g?(n=r.h,i.M=n.uri,w(r,function(e,t,n){var i,r,a,o,s,u,d,h,f,p,g,m,v,y,b,T,x,A,k,I,M,C,D,R,L,N,j,O,U,_,B,F,V;return P((function(H){switch(H.g){case 1:return i=bi,r=qg(e.Ka,t),a=_g(r.X,"EXT-X-DEFINE"),o=[],s=[],u=[],e.l=new Ls(null,0),e.l.Bc(!0),d=function(){return[n]},h=null,f=new Map,1==r.type?(e.S=!1,A=_g(r.X,"EXT-X-DEFINE"),f=am(e,A,e.M),h=i.la,k="",I=new Map,w(H,vm(e,e.C++,f,r,d,"",h,k,!0,"Media Playlist",null,I,null,!1,null,!1),7)):(function(e,t){for(var n=new Gn(e.M).g,i=(t=l(t)).next();!i.done;i=t.next()){var r=i.value;i=Ng(r,"NAME");var a=Ng(r,"VALUE");r=Ng(r,"QUERYPARAM"),i&&a&&(e.A.has(i)||e.A.set(i,a)),r&&(i=n.get(r)[0])&&!e.A.has(i)&&e.A.set(r,i)}}(e,a),p=_g(r.X,"EXT-X-MEDIA"),g=_g(r.X,"EXT-X-STREAM-INF"),m=_g(r.X,"EXT-X-IMAGE-STREAM-INF"),v=_g(r.X,"EXT-X-I-FRAME-STREAM-INF"),y=_g(r.X,"EXT-X-SESSION-KEY"),b=_g(r.X,"EXT-X-SESSION-DATA"),T=_g(r.X,"EXT-X-CONTENT-STEERING"),function(e,t){for(var n=(t=l(t)).next();!n.done;n=t.next()){var i=n.value,r=Ng(i,"DATA-ID");n=Ng(i,"URI");var a=Ng(i,"LANGUAGE");i=Ng(i,"VALUE"),r=(new Map).set("id",r),n&&r.set("uri",Hg([e.M],n,e.A)[0]),a&&r.set("language",a),i&&r.set("value",i),n=new Jr("sessiondata",r),e.h&&e.h.onEvent(n)}}(e,b),w(H,function(e,t){var n,i,r,a,o,s;return P((function(u){if(!e.h||!e.g)return u.return();for(i=l(t),r=i.next();!r.done;r=i.next())if(a=r.value,o=Ng(a,"PATHWAY-ID"),s=Ng(a,"SERVER-URI"),o&&s){e.j=new mp(e.h),e.j.configure(e.g),e.j.i=[e.M],e.j.setManifestType("HLS"),e.j.h=o,n=vp(e.j,s);break}return w(u,n,0)}))}(e,T),4));case 4:return function(e,t){for(var n=(t=l(t)).next();!n.done;n=t.next()){var i=n.value,r=Ng(i,"AUDIO");n=Ng(i,"VIDEO");var a=Ng(i,"SUBTITLES");if(i=um(e,i),a){var o=mi(yi,i);e.G.set(a,o),Ie(i,o)}r&&((a=mi("audio",i))||(a=e.g.hls.defaultAudioCodec),e.G.set(r,a)),n&&((r=mi("video",i))||(r=e.g.hls.defaultVideoCodec),e.G.set(n,r))}}(e,g),function(e,t){t=Bg(t,"CLOSED-CAPTIONS"),e.S=0==t.length;for(var n=(t=l(t)).next();!n.done;n=t.next()){var i=n.value,r=Ng(i,"LANGUAGE");n=Yi(r||"und"),r||(r=Ng(i,"NAME"))&&(n=r),r=jg(i,"GROUP-ID"),i=jg(i,"INSTREAM-ID").replace("SERVICE","svc"),e.F.get(r)||e.F.set(r,new Map),e.F.get(r).set(i,n)}}(e,p),x=function(e,t){return t.map((function(t){return"video"!==(t=dm(e,t)).stream.type?null:t.stream})).filter((function(e){return e}))}(e,v),w(H,function(e,t,n,i,r,a,o){var s,u,d,h,f,p,g,m,v,y,b,T,S,x,A,E,k,I,M,C,D,R,L,N,j,O,U,_,B,F,V,H,G,K,X;return P((function(P){switch(P.g){case 1:if(s=[],u=new Set,!(0<n.length)){P.u(2);break}d=l(n),h=d.next();case 3:if(h.done){P.u(2);break}if(f=h.value,p=jg(f,"METHOD"),g=Ng(f,"KEYFORMAT")||"identity",m=null,"NONE"==p){P.u(4);break}if(Bm(p)){v=Hg(r(),jg(f,"URI"),a),y=v.sort().join(""),e.L.has(y)||(b=aa(v,e.g.retryParameters),T=_m(e,b,6).promise,e.L.set(y,T)),P.u(4);break}if("identity"!=g){m=(S=Km[g])?S(f,""):null,P.u(6);break}return w(P,Fm(e,f,"",r,null,a),9);case 9:m=P.h;case 6:if(m){if(m.keyIds)for(x=l(m.keyIds),A=x.next();!A.done;A=x.next())E=A.value,u.add(E);s.push(m)}case 4:h=d.next(),P.u(3);break;case 2:for(k={},I=l(t),M=I.next();!M.done;M=I.next())C=M.value,D=Pg(C,!e.j),k[D]?k[D].push(C):k[D]=[C];for(L in R=[],k)N=k[L],j=N[0],O=Ng(j,"FRAME-RATE"),U=Number(Ng(j,"AVERAGE-BANDWIDTH"))||Number(jg(j,"BANDWIDTH")),_=Ng(j,"RESOLUTION"),B=l(_?_.split("x"):[null,null]),F=B.next().value,V=B.next().value,H=Ng(j,"VIDEO-RANGE"),(G=Ng(j,"REQ-VIDEO-LAYOUT"))&&G.includes(",")&&(K=G.split(",").filter((function(e){return"CH-STEREO"==e||"CH-MONO"==e})),G=K[0]),G=G||"CH-MONO",X=sm(e,N,i),R.push.apply(R,c(lm(e,X.audio,X.video,U,F,V,O,H,G,s,u,o)));return P.return(R.filter((function(e){return null!=e})))}}))}(e,g,y,p,d,e.A,x),5);case 5:return o=H.h,s=function(e,t){var n=Bg(t,"SUBTITLES");t=n.map((function(t){if(e.g.disableText)return null;try{return cm(e,[t],new Map).stream}catch(t){if(e.g.hls.ignoreTextStreamFailures)return null;throw t}}));for(var i=(n=l(n)).next();!i.done;i=n.next()){var r=jg(i.value,"GROUP-ID");if((i=e.G.get(r))&&(r=e.H.get(r)))for(var a=(r=l(r)).next();!a.done;a=r.next())(a=a.value).stream.codecs=i,a.stream.mimeType=Dm(yi,i)||Rm(yi),om(a.stream)}return t.filter((function(e){return e}))}(e,p),w(H,function(e,t,n){var i,r;return P((function(a){return 1==a.g?(i=t.map((function(t){var n,i;return P((function(r){if(1==r.g)return e.g.disableThumbnails?r.return(null):(S(r,2),w(r,function(e,t){var n,i,r,a,o,s,u,l,c,d;return P((function(h){return 1==h.g?(n=jg(t,"URI"),i=Ng(t,"CODECS","jpeg")||"",e.i.has(n)?h.return(e.i.get(n)):(r=Ng(t,"LANGUAGE"),a=Ng(t,"NAME"),o=Ng(t,"CHARACTERISTICS"),s=hm(e,e.C++,[n],i,"image",r,!1,a,null,null,o,!1,null,!1),(u=Ng(t,"RESOLUTION"))?w(h,s.stream.createSegmentIndex(),3):h.u(2))):(2!=h.g&&(l=eu(s.stream.segmentIndex),c=l.tilesLayout)&&(s.stream.width=Number(u.split("x")[0])*Number(c.split("x")[0]),s.stream.height=Number(u.split("x")[1])*Number(c.split("x")[1])),(d=Ng(t,"BANDWIDTH"))&&(s.stream.bandwidth=Number(d)),e.i.set(n,s),h.return(s))}))}(e,t),4));if(2!=r.g)return n=r.h,r.return(n.stream);if(i=E(r),e.g.hls.ignoreImageStreamFailures)return r.return(null);throw i}))})).concat(n.map((function(t){if(e.g.disableThumbnails)return null;try{var n=dm(e,t);return"image"!==n.stream.type?null:n.stream}catch(t){if(e.g.hls.ignoreImageStreamFailures)return null;throw t}}))),w(a,Promise.all(i),2)):(r=a.h,a.return(r.filter((function(e){return e}))))}))}(e,m,v),6);case 6:u=H.h,H.u(3);break;case 7:M=H.h,e.i.set(n,M),M.stream&&(C=Iu(M.stream),M.stream.segmentIndex.yb((function(e){e.ba&&(e.ba.Qc=C)}))),h=M.stream.type,o.push({id:0,language:Yi(k||"und"),disabledUntilTime:0,primary:!0,audio:"audio"==h?M.stream:null,video:"video"==h?M.stream:null,bandwidth:M.stream.bandwidth||0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});case 3:if(!e.h)throw new De(2,7,7001);if(Sm(e,r),1==r.type&&(Om(e)&&(Am(e,r),D=e.o,e.B.$(D)),R=Array.from(e.i.values()),gm(e,R),rm(e),Mm(e,r.X,h,f,d)),e.m={presentationTimeline:e.l,variants:o,textStreams:s,imageStreams:u,offlineSessionIds:[],minBufferTime:0,sequenceMode:e.g.hls.sequenceMode,ignoreManifestTimestampsInSegmentsMode:e.g.hls.ignoreManifestTimestampsInSegmentsMode,type:"HLS",serviceDescription:null,nextUrl:null,periodCount:1,gapCount:0,isLowLatency:!1,startTime:e.s},e.fa||!e.g.hls.disableCodecGuessing){H.u(8);break}for(L=[],N=l(e.m.variants),j=N.next();!j.done;j=N.next())(O=j.value).audio&&""===O.audio.codecs&&L.push(O.audio.createSegmentIndex()),O.video&&""===O.video.codecs&&L.push(O.video.createSegmentIndex());return w(H,Promise.all(L),8);case 8:if(e.h.makeTextStreamsForClosedCaptions(e.m),1==o.length){for(U=[],_=o[0],B=l([_.video,_.audio]),F=B.next();!F.done;F=B.next())(V=F.value)&&!V.segmentIndex&&U.push(V.createSegmentIndex());if(0<U.length)return w(H,Promise.all(U),0)}H.u(0)}}))}(i,n.data,e),3)):r.return(i.m)}))},i.stop=function(){this.B&&(this.B.stop(),this.B=null);var e=[];return this.da&&(e.push(this.da.destroy()),this.da=null),this.g=this.h=null,this.Na.clear(),this.m=null,this.i.clear(),this.H.clear(),this.G.clear(),this.A.clear(),this.ta.clear(),this.ja.clear(),this.L.clear(),this.ra.clear(),this.na.clear(),this.Aa.clear(),this.j&&this.j.destroy(),this.Z&&(this.Z.release(),this.Z=null),Promise.all(e)},i.update=function(){var e,t,n,i,r,a,o,s,u,d,h,f=this;return P((function(p){if(1==p.g){if(!Om(f))return p.return();for(e=[],t=Array.from(f.i.values()),f.o=1/0,f.m.gapCount=0,n=t.filter((function(e){return e.stream.segmentIndex})),i=l(n),r=i.next();!r.done;r=i.next())a=r.value,e.push(tm(f,a));return w(p,Promise.all(e),2)}for(pm(f,n.map((function(e){return e.stream}))),o=n.some((function(e){return 0==e.kd})),n.length&&!o&&(Um(f,Wm.vh),s=n.map((function(e){return e.Lb})),f.l.bb(Math.min.apply(Math,c(s))),f.h.updateDuration()),o&&rm(f),u=l(n),d=u.next();!d.done;d=u.next())(h=d.value).stream.isAudioMuxedInVideo||!h.stream.segmentIndex||eu(h.stream.segmentIndex)||f.h.disableStream(h.stream);T(p)}))},i.onExpirationUpdated=function(){},i.onInitialVariantChosen=function(){},i.banLocation=function(e){this.j&&this.j.banLocation(e)},i.setMediaElement=function(e){this.aa=e},F("shaka.hls.HlsParser",Zg);var Vm={aac:"audio/aac",ac3:"audio/ac3",ec3:"audio/ec3",mp3:"audio/mpeg"},Hm={audio:{mp4:"audio/mp4",mp4a:"audio/mp4",m4s:"audio/mp4",m4i:"audio/mp4",m4a:"audio/mp4",m4f:"audio/mp4",cmfa:"audio/mp4",ts:"video/mp2t",tsa:"video/mp2t"},video:{mp4:"video/mp4",mp4v:"video/mp4",m4s:"video/mp4",m4i:"video/mp4",m4v:"video/mp4",m4f:"video/mp4",cmfv:"video/mp4",ts:"video/mp2t",tsv:"video/mp2t"},text:{mp4:"application/mp4",m4s:"application/mp4",m4i:"application/mp4",m4f:"application/mp4",cmft:"application/mp4",vtt:"text/vtt",webvtt:"text/vtt",ttml:"application/ttml+xml"},image:{jpg:"image/jpeg",png:"image/png",svg:"image/svg+xml",webp:"image/webp",avif:"image/avif"}},Gm=new Set(["video/mp2t"].concat(c(ji))),Km={"com.apple.streamingkeydelivery":function(e,t){if("video/mp2t"==t)throw new De(2,4,4040);if(ot())throw new De(2,4,4041);if(t=jg(e,"METHOD"),!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(t))return null;var n="cenc";return"SAMPLE-AES"==t&&(n="cbcs"),fi("com.apple.fps",n,[{initDataType:"sinf",initData:new Uint8Array(0),keyId:null}],jg(e,"URI"))},"urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":function(e){var t=jg(e,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(t))return null;var n="cenc";return"SAMPLE-AES"==t&&(n="cbcs"),n=fi("com.widevine.alpha",n,[{initDataType:"cenc",initData:t=ge((t=Qg((t=jg(e,"URI")).split("?")[0])).data)}]),(e=Ng(e,"KEYID"))&&(n.keyIds=new Set([e.toLowerCase().substr(2)])),n},"com.microsoft.playready":function(e){var t=jg(e,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(t))return null;var n="cenc";return"SAMPLE-AES"==t&&(n="cbcs"),fi("com.microsoft.playready",n,[{initDataType:"cenc",initData:e=La(e=ge((e=Qg((e=jg(e,"URI")).split("?")[0])).data),t=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]),new Set,0)}])}},Xm="VOD",qm="EVENT",zm="LIVE",Wm={vh:Xm,uj:qm,Cj:zm};function Ym(e){if(e=Jm(e))e:{for(var t=(e=l(Ut(e,"DATA"))).next();!t.done;t=e.next())if(t=_t(t.value,"LA_URL")){e=jt(t);break e}e=""}else e="";return e}function Jm(e){return(e=function(e){var t=0,n=ve(e),i=n.getUint32(t,!0);if(i!=e.byteLength)return[];e:{for(e=t+6,t=[];e<n.byteLength-1;){i=n.getUint16(e,!0),e+=2;var r=n.getUint16(e,!0);if(e+=2,1&r||r+e>n.byteLength){n=[];break e}var a=ge(n,e,r);t.push({type:i,value:a}),e+=r}n=t}return n}(e=ui(jt(e))).filter((function(e){return e.type===$m}))[0])&&(e=Dt(e=ht(e.value,!0),"WRMHEADER"))?e:null}co["application/x-mpegurl"]=function(){return new Zg},co["application/vnd.apple.mpegurl"]=function(){return new Zg};var $m=1,Qm=(new Map).set("com.microsoft.playready",Ym).set("com.microsoft.playready.recommendation",Ym).set("com.microsoft.playready.software",Ym).set("com.microsoft.playready.hardware",Ym);function Zm(e){if(!cv){cv=!0;var t=new Uint8Array([105,115,111,109]),n=new Uint8Array([97,118,99,49]),i=new Uint8Array([0,0,0,1]);Sv=lv("ftyp",t,i,t,n),t=lv("dref",xv),Av=lv("dinf",t)}this.g=e}function ev(e){for(var t=[],n=l(e.g),i=n.next();!i.done;i=n.next()){var r=t,a=r.push,o=i.value;i=lv;var s=o.id+1,u=o.stream.width||0,d=o.stream.height||0;"audio"==o.type&&(d=u=0);var h=o.duration*o.timescale,f=Math.floor(h/(dv+1));switch(h=Math.floor(h%(dv+1)),s=lv("tkhd",s=new Uint8Array([1,0,0,7,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(c(sv(s,4)),[0,0,0,0],c(sv(f,4)),c(sv(h,4)),[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0],c(sv(u,2)),[0,0],c(sv(d,2)),[0,0]))),u=lv,f=o.duration*o.timescale,d=Math.floor(f/(dv+1)),f=Math.floor(f%(dv+1)),h=(h=o.stream.language).charCodeAt(0)-96<<10|h.charCodeAt(1)-96<<5|h.charCodeAt(2)-96,d=lv("mdhd",d=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(c(sv(o.timescale,4)),c(sv(d,4)),c(sv(f,4)),c(sv(h,2)),[0,0]))),f=o,h=new Uint8Array([]),f.type){case"video":h=fv;break;case"audio":h=pv}f=lv("hdlr",h);e:{switch(o.type){case"video":o=lv("minf",lv("vmhd",bv),Av,tv(o));break e;case"audio":o=lv("minf",lv("smhd",wv),Av,tv(o));break e}o=new Uint8Array([])}i=i("trak",s,o=u("mdia",d,f,o)),a.call(r,i)}for(t=di.apply(ai,c(t)),n=lv,i=(a=e.g[0]).duration*a.timescale,r=Math.floor(i/(dv+1)),i=Math.floor(i%(dv+1)),r=lv("mvhd",r=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(c(sv(a.timescale,4)),c(sv(r,4)),c(sv(i,4)),[0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]))),i=[],u=(e=l(e.g)).next();!u.done;u=e.next())s=(o=i).push,u=lv("trex",u=new Uint8Array([0,0,0,0].concat(c(sv(u.value.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0]))),s.call(o,u);if(e=lv("mvex",e=di.apply(ai,c(i))),i=[],a.encrypted){for(o=(a=l(a.stream.drmInfos)).next();!o.done;o=a.next())if((o=o.value).initData)for(s=(o=l(o.initData)).next();!s.done;s=o.next())i.push(s.value.initData);a=di.apply(ai,c(i))}else a=new Uint8Array([]);return e=n("moov",r,t,e,a),(t=new Uint8Array(Sv.byteLength+e.byteLength)).set(Sv),t.set(e,Sv.byteLength),t}function tv(e){var t=lv,n=new Uint8Array([]);switch(e.type){case"video":if(e.codecs.includes("avc1")){n=e.stream.width||0;var i=e.stream.height||0;if(0<e.za.byteLength)var r=lv("avcC",e.za);else{r=lv;for(var a=7,o=[],s=[],u=0,l=0,d=0,h=0;h<e.fb.length;h++){var f=uv(e.fb[h]);switch(31&f[0]){case 7:o.push(f),a+=f.length+2;break;case 8:s.push(f),a+=f.length+2}}for(0<o.length&&(u=o[0][1],d=o[0][2],l=o[0][3]),h=0,(a=new Uint8Array(a))[h++]=1,a[h++]=u,a[h++]=d,a[h++]=l,a[h++]=255,a[h++]=224|o.length,u=0;u<o.length;u++)a[h++]=(65280&o[u].length)>>8,a[h++]=255&o[u].length,a.set(o[u],h),h+=o[u].length;for(a[h++]=s.length,o=0;o<s.length;o++)a[h++]=(65280&s[o].length)>>8,a[h++]=255&s[o].length,a.set(s[o],h),h+=s[o].length;r=r("avcC",a)}n=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0].concat(c(sv(n,2)),c(sv(i,2)),[0,72,0,0,0,72,0,0,0,0,0,0,0,1,19,118,105,100,101,111,106,115,45,99,111,110,116,114,105,98,45,104,108,115,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17])),i="avc1",s=nv(e),o=new Uint8Array([]),e.encrypted&&(o=rv(e),i="encv"),n=lv(i,n,r,s,o)}else e.codecs.includes("hvc1")&&(i=e.stream.width||0,r=e.stream.height||0,n=new Uint8Array([]),0<e.za.byteLength&&(n=lv("hvcC",e.za)),i=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0].concat(c(sv(i,2)),c(sv(r,2)),[0,72,0,0,0,72,0,0,0,0,0,0,0,1,19,118,105,100,101,111,106,115,45,99,111,110,116,114,105,98,45,104,108,115,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17])),r="hvc1",s=nv(e),o=new Uint8Array([]),e.encrypted&&(o=rv(e),r="encv"),n=lv(r,i,n,s,o));break;case"audio":e.codecs.includes("mp3")?e=lv(".mp3",iv(e)):e.codecs.includes("ac-3")?(n=lv("dac3",e.qa),i="ac-3",r=new Uint8Array([]),e.encrypted&&(r=rv(e),i="enca"),e=lv(i,iv(e),n,r)):e.codecs.includes("ec-3")?(n=lv("dec3",e.qa),i="ec-3",r=new Uint8Array([]),e.encrypted&&(r=rv(e),i="enca"),e=lv(i,iv(e),n,r)):e.codecs.includes("opus")?(n=lv("dOps",e.qa),i="Opus",r=new Uint8Array([]),e.encrypted&&(r=rv(e),i="enca"),e=lv(i,iv(e),n,r)):(0<e.qa.byteLength?n=lv("esds",e.qa):(n=lv,i=e.id+1,r=e.stream.channelsCount||2,o=e.stream.audioSamplingRate||44100,u=gi("audio",e.codecs.split(",")),s=(l={96e3:0,88200:1,64e3:2,48e3:3,44100:4,32e3:5,24e3:6,22050:7,16e3:8,12e3:9,11025:10,8e3:11,7350:12})[o],"mp4a.40.5"!==u&&"mp4a.40.29"!==u||(s=l[2*o]),o=parseInt(u.split(".").pop(),10),n=n("esds",i=new Uint8Array([0,0,0,0,3,25].concat(c(sv(i,2)),[0,4,17,64,21,0,0,0,0,0,0,0,0,0,0,0,5,2,o<<3|s>>>1,s<<7|r<<3,6,1,2])))),i="mp4a",r=new Uint8Array([]),e.encrypted&&(r=rv(e),i="enca"),e=lv(i,iv(e),n,r)),n=e}return t("stbl",e=lv("stsd",Tv,n),lv("stts",gv),lv("stsc",mv),lv("stsz",yv),lv("stco",vv))}function nv(e){if(!e.Da&&!e.Fa)return new Uint8Array([]);var t=e.Fa;return lv("pasp",e=new Uint8Array([].concat(c(sv(e.Da,4)),c(sv(t,4)))))}function iv(e){return new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,e.stream.channelsCount||2,0,16,0,0,0,0].concat(c(sv(e.stream.audioSamplingRate||44100,2)),[0,0]))}function rv(e){for(var t=lv,n=e.codecs.substring(0,e.codecs.indexOf(".")),i=0,r=0;r<n.length;r+=1)i|=n.charCodeAt(r)<<8*(n.length-r-1);n=lv("frma",n=new Uint8Array([].concat(c(sv(i,4))))),i=lv("schm",i=new Uint8Array([0,0,0,0,99,101,110,99,0,1,0,0])),r=lv;for(var a=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),o=(e=l(e.stream.drmInfos)).next();!o.done;o=e.next())if((o=o.value)&&o.keyIds&&o.keyIds.size)for(var s=(o=l(o.keyIds)).next();!s.done;s=o.next())a=uv(s.value);return t("sinf",n,i,r("schi",a=lv("tenc",e=new Uint8Array([0,0,0,0,0,0,1,8]),a)))}function av(e){for(var t=[],n=(e=l(e.g)).next();!n.done;n=e.next()){n=n.value;var i,r=t.push,a=r.apply,o=lv,s=new Uint8Array([0,0,0,0].concat(c(sv(n.data?n.data.wb:0,4))));s=lv("mfhd",s);var u=n.data?n.data.ab:[],d=new Uint8Array(4+u.length);for(i=0;i<u.length;i++){var h=u[i].flags;d[i+4]=h.Ya<<4|h.$a<<2|h.Za}var f=(u=lv("sdtp",d)).length+92;d=lv,i=lv("tfhd",i=new Uint8Array([0,0,0,58].concat(c(sv(n.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0]))),h=n.data?n.data.baseMediaDecodeTime:0;var p=Math.floor(h%(dv+1));h=lv("tfdt",h=new Uint8Array([1,0,0,0].concat(c(sv(Math.floor(h/(dv+1)),4)),c(sv(p,4)))));var g=f,m=12+16*(p=(f=n.data?n.data.ab:[]).length),v=new Uint8Array(m);for(g+=8+m,v.set(["video"===n.type?1:0,0,15,1].concat(c(sv(p,4)),c(sv(g,4))),0),g=0;g<p;g++){var y=f[g];m=sv(y.duration,4);var b=sv(y.size,4),w=y.flags;y=sv(y.hb,4),v.set([].concat(c(m),c(b),[w.kb<<2|w.Ya,w.$a<<6|w.Za<<4|w.lb,61440&w.Xa,15&w.Xa],c(y)),12+16*g)}o=o("moof",s,u=d("traf",i,h,f=lv("trun",v),u)),a.call(r,t,[o,ov(n)])}return di.apply(ai,c(t))}function ov(e){return e=(e.data?e.data.ab:[]).map((function(e){return e.data})),lv("mdat",e=di.apply(ai,c(e)))}function sv(e,t){var n=[];for(--t;0<=t;t--)n.push(e>>8*t&255);return n}function uv(e){for(var t=new Uint8Array(e.length/2),n=0;n<e.length/2;n+=1)t[n]=parseInt(String(e[2*n]+e[2*n+1]),16);return t}function lv(e){var t=L.apply(1,arguments),n=hv[e];n||(n=[e.charCodeAt(0),e.charCodeAt(1),e.charCodeAt(2),e.charCodeAt(3)],hv[e]=n);for(var i=8,r=t.length-1;0<=r;r--)i+=t[r].byteLength;for((r=new Uint8Array(i))[0]=i>>24&255,r[1]=i>>16&255,r[2]=i>>8&255,r[3]=255&i,r.set(n,4),n=0,i=8;n<t.length;n++)r.set(t[n],i),i+=t[n].byteLength;return r}var cv=!1,dv=Math.pow(2,32)-1,hv={},fv=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),pv=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]),gv=new Uint8Array([0,0,0,0,0,0,0,0]),mv=new Uint8Array([0,0,0,0,0,0,0,0]),vv=new Uint8Array([0,0,0,0,0,0,0,0]),yv=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),bv=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0]),wv=new Uint8Array([0,0,0,0,0,0,0,0]),Tv=new Uint8Array([0,0,0,0,0,0,0,1]),Sv=new Uint8Array([]),xv=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),Av=new Uint8Array([]);function Ev(){var e=this;this.h=this.g=null,this.l=[],this.j=null,this.s=1,this.i=null,this.C=new G(5),this.o=new Be((function(){!function(e){var t;P((function(n){switch(n.g){case 1:return S(n,2),w(n,kv(e),4);case 4:A(n,3);break;case 2:t=E(n),e.h&&(t.severity=1,e.h.onError(t));case 3:if(!e.h)return n.return();T(n)}}))}(e)})),this.B=new ea,this.m=new Map,this.A=function(){return!1}}function kv(e){var t,n,i,r,a,o,s;return P((function(u){if(1==u.g)return t=aa(e.l,e.g.retryParameters),n=e.h.networkingEngine,i=Date.now(),r=n.request(0,t,{type:5,isPreload:e.A()}),ta(e.B,r),w(u,r.promise,2);if(a=u.h,!e.h)return u.return();a.uri&&!e.l.includes(a.uri)&&e.l.unshift(a.uri);var d=a.uri,h=a.data,f=e.g.mss.manifestPreprocessor;if(f!=dl){if(oe("manifest.mss.manifestPreprocessor configuration","Please Use manifest.mss.manifestPreprocessorTXml instead."),!(h=ng(h,"SmoothStreamingMedia")))throw new De(2,4,4046,d);f(h),h=pt(h.outerHTML)}var p=Ct(h,"SmoothStreamingMedia");if(!p)throw new De(2,4,4046,d);if((d=e.g.mss.manifestPreprocessorTXml)!=hl&&d(p),e.i||(e.i=new Ls(null,0)),d=Ft(p,"IsLive",$t,!1))throw new De(2,4,4047);e.i.Bc(!d),f=Ft(p,"TimeScale",Yt,1e7),h=Ft(p,"DVRWindowLength",Yt),d&&(0===h||isNaN(h))&&(h=1/0);var g,m=Ft(p,"CanSeek",$t,!1);for(0===h&&m&&(h=1/0),m=null,h&&0<h&&(m=h/f),d&&!isNaN(e.g.availabilityWindowOverride)&&(m=e.g.availabilityWindowOverride),null==m&&(m=1/0),e.i.pe(m),h=Ft(p,"Duration",Yt,1/0),d||e.i.bb(h/f),d={variants:[],textStreams:[],timescale:f,duration:h/f},m=Nt(p,"Protection"),f=e.g.mss.keySystemsBySystemId,h=[],g=(m=l(m)).next();!g.done;g=m.next())h=h.concat(Nt(g.value,"ProtectionHeader"));if(h.length){for(m=[],g=0;g<h.length;g++){var v=h[g],y=v.attributes.SystemID.toLowerCase(),b=f[y];if(b){var S=Jm(v);if(S)e:{for(var x=(S=l(Ut(S,"DATA"))).next();!x.done;x=S.next())if(x=_t(x.value,"KID")){S=ui(jt(x)),S=ci(S=new Uint8Array([S[3],S[2],S[1],S[0],S[5],S[4],S[7],S[6]].concat(c(S.slice(8)))));break e}S=null}else S=null;y=fi(b,"cenc",y=[{initData:La(x=ui(jt(v)),y=li(y.replace(/-/g,"")),new Set,0),initDataType:"cenc",keyId:S}]),S&&y.keyIds.add(S),(b=Qm.get(b))&&(y.licenseServerUri=b(v)),m.push(y)}}f=m}else f=[];for(g=f,m=[],f=[],h=[],v=(p=l(p=Nt(p,"StreamIndex"))).next();!v.done;v=p.next()){b=Nt(v=v.value,"QualityLevel"),y=d.timescale,S=d.duration,x=Nt(v,"c");for(var A=[],E=0,k=0;k<x.length;++k){var I=x[k],M=x[k+1],C=Ft(I,"t",Yt),D=Ft(I,"d",Yt);if(I=Ft(I,"r",zt),!D)break;if(C=null!=C?C:E,(I=I||0)&&I--,0>I)if(M){if(null==(M=Ft(M,"t",Yt)))break;if(C>=M)break;I=Math.ceil((M-C)/D)-1}else{if(1/0==S)break;if(C/y>=S)break;I=Math.ceil((S*y-C)/D)-1}for(M=0;M<=I;++M)E=C+D,A.push({start:C/y,end:E/y,dg:C}),C=E}for(y=A,S=(b=l(b)).next();!S.done;S=b.next())(S=Iv(e,v,S.value,y,g,d))&&("audio"!=S.type||e.g.disableAudio?"video"!=S.type||e.g.disableVideo?S.type!=yi||e.g.disableText||h.push(S):f.push(S):m.push(S))}for(p=[],g=(m=l(0<m.length?m:[null])).next();!g.done;g=m.next())for(g=g.value,A=(v=l(0<f.length?f:[null])).next();!A.done;A=v.next())y=(b=p).push,S=e,x=g,A=A.value,k=0,x&&x.bandwidth&&0<x.bandwidth&&(k+=x.bandwidth),A&&A.bandwidth&&0<A.bandwidth&&(k+=A.bandwidth),S={id:S.s++,language:x?x.language:"und",disabledUntilTime:0,primary:!!x&&x.primary||!!A&&A.primary,audio:x,video:A,bandwidth:k,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},y.call(b,S);d.variants=p,d.textStreams=h,e.j?(e.j.variants=d.variants,e.j.textStreams=d.textStreams,e.h.filter(e.j)):(e.j={presentationTimeline:e.i,variants:d.variants,textStreams:d.textStreams,imageStreams:[],offlineSessionIds:[],minBufferTime:0,sequenceMode:e.g.mss.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,type:"MSS",serviceDescription:null,nextUrl:null,periodCount:1,gapCount:0,isLowLatency:!1,startTime:null},e.i.Xd()),Promise.resolve(),o=Date.now(),s=(o-i)/1e3,e.C.sample(1,s),T(u)}))}function Iv(e,t,n,i,r,a){var o=t.attributes.Type;if("audio"!==o&&"video"!==o&&"text"!==o)return W("Ignoring unrecognized type:",o),null;var s=t.attributes.Language,u=e.s++,c=Ft(n,"Bitrate",Wt),d=Ft(n,"MaxWidth",Wt),h=Ft(n,"MaxHeight",Wt),f=Ft(n,"Channels",Wt),p=Ft(n,"SamplingRate",Wt),g=a.duration;i.length&&(g=i[i.length-1].end-i[0].start);var m=e.i.getDuration();e.i.bb(Math.min(g,m));var v={id:u,originalId:t.attributes.Name||String(u),groupId:null,createSegmentIndex:function(){return Promise.resolve()},closeSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:"",codecs:"",frameRate:void 0,pixelAspectRatio:void 0,bandwidth:c||0,width:d||void 0,height:h||void 0,kind:"",encrypted:0<r.length,drmInfos:r,keyIds:new Set,language:Yi(s||"und"),originalLanguage:s,label:"",type:"",primary:!1,trickModeVideo:null,emsgSchemeIdUris:[],roles:[],forced:!1,channelsCount:f,audioSamplingRate:p,spatialAudio:!1,closedCaptions:null,hdr:void 0,colorGamut:void 0,videoLayout:void 0,tilesLayout:void 0,matchedStreams:[],mssPrivateData:{duration:g,timescale:a.timescale,codecPrivateData:null},accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set,isAudioMuxedInVideo:!1};if((r=t.attributes.Subtype)&&((r=Cv[r])&&v.roles.push(r),"main"===r&&(v.primary=!0)),null!==(r=n.attributes.FourCC)&&""!==r||(r=t.attributes.FourCC),!r)if("audio"===o)r="AAC";else if("video"===o)return W('FourCC is not defined whereas it is required for a QualityLevel element for a StreamIndex of type "video"'),null;if(!Mv.includes(r.toUpperCase()))return W("Codec not supported:",r),null;switch(n=function(e,t,n,i){if(e=e.attributes.CodecPrivateData)return e;if("audio"!==t)return null;t=i.channelsCount||2;var r={96e3:0,88200:1,64e3:2,48e3:3,44100:4,32e3:5,24e3:6,22050:7,16e3:8,12e3:9,11025:10,8e3:11,7350:12};return i=r[e=i.audioSamplingRate||44100],"AACH"===n?(n=new Uint8Array(4),e=r[2*e],n[0]=40|i>>1,n[1]=i<<7|t<<3|e>>1,n[2]=e<<7|8,n[3]=0,(t=new Uint16Array(2))[0]=(n[0]<<8)+n[1],t[1]=(n[2]<<8)+n[3],t[0].toString(16)+t[1].toString(16)):((n=new Uint8Array(2))[0]=16|i>>1,n[1]=i<<7|t<<3,(t=new Uint16Array(1))[0]=(n[0]<<8)+n[1],t[0].toString(16))}(n,o,r,v),v.mssPrivateData.codecPrivateData=n,o){case"audio":if(!n)return W("Quality unsupported without CodecPrivateData",o),null;v.type="audio",v.mimeType="mss/audio/mp4",v.codecs=function(e,t){var n=0;return"AACH"===e&&(n=5),t?0===n&&(n=(248&parseInt(t.substr(0,2),16))>>3):(n=2,"AACH"===e&&(n=5)),"mp4a.40."+n}(r,n);break;case"video":if(!n)return W("Quality unsupported without CodecPrivateData",o),null;v.type="video",v.mimeType="mss/video/mp4",v.codecs=function(e){var t=/00000001[0-9]7/.exec(e);return t.length&&e?"avc1."+e.substr(e.indexOf(t[0])+10,6):""}(n);break;case"text":v.type=yi,v.mimeType="application/mp4",("TTML"===r||"DFXP"===r)&&(v.codecs="stpp")}return v.fullMimeTypes.add(xi(v.mimeType,v.codecs)),v.createSegmentIndex=function(){if(v.segmentIndex)return Promise.resolve();if(e.m.has(v.id))var n=e.m.get(v.id);else n=[],"video"==v.type&&(n=v.mssPrivateData.codecPrivateData.split("00000001").slice(1)),n=ev(new Zm([n={id:v.id,type:v.type,codecs:v.codecs,encrypted:v.encrypted,timescale:v.mssPrivateData.timescale,duration:v.mssPrivateData.duration,fb:n,qa:new Uint8Array([]),za:new Uint8Array([]),Da:0,Fa:0,data:null,stream:v}])),e.m.set(v.id,n);return n=function(e,t,n,i,r){var a=i.attributes.Url.replace("{bitrate}",String(n.bandwidth));i=[];for(var o=(r=l(r)).next(),s={};!o.done;s={se:void 0},o=r.next())s.se=o.value,i.push(new vo(s.se.start,s.se.end,function(t){return function(){return hi(e.l,[a.replace("{start time}",String(t.se.dg))])}}(s),0,null,t,0,0,n.mssPrivateData.duration));return i}(e,new go((function(){return[]}),0,null,Iu(v),v.mssPrivateData.timescale,n),v,t,i),v.segmentIndex=new Zs(n),Promise.resolve()},v.closeSegmentIndex=function(){v.segmentIndex&&(v.segmentIndex.release(),v.segmentIndex=null)},v}(i=Ev.prototype).configure=function(e,t){this.g=e,t&&(this.A=t)},i.start=function(e,t){var n=this;return P((function(i){if(1==i.g)return n.l=[e],n.h=t,w(i,kv(n),2);if(!n.h)throw new De(2,7,7001);return i.return(n.j)}))},i.stop=function(){return this.g=this.h=null,this.l=[],this.j=null,null!=this.o&&(this.o.stop(),this.o=null),this.m.clear(),this.B.destroy()},i.update=function(){var e,t=this;return P((function(n){return 1==n.g?(S(n,2),w(n,kv(t),4)):2!=n.g?A(n,0):(e=E(n),t.h&&e?(t.h.onError(e),void T(n)):n.return())}))},i.onExpirationUpdated=function(){},i.onInitialVariantChosen=function(){},i.banLocation=function(){},i.setMediaElement=function(){},F("shaka.mss.MssParser",Ev);var Mv="AAC AACL AACH AACP AVC1 H264 TTML DFXP".split(" "),Cv={CAPT:"main",SUBT:"alternate",DESC:"main"};function Dv(e,t,n,i,r,a){if(200<=n&&299>=n&&202!=n)return{uri:r||i,originalUri:i,data:t,status:n,headers:e,fromCache:!!e["x-shaka-from-cache"]};var o=null;try{o=ft(t)}catch(e){}throw new De(401==n||403==n?2:1,1,1001,i,n,o,e,a,r||i)}function Rv(){}function Pv(e,t,n,i,r,a){var o=new _v;ma(t.headers).forEach((function(e,t){o.append(t,e)}));var s=new Ov,u={ng:!1,ph:!1};if(e=function(e,t,n,i,r,a,o,s){var u,l,c,d,h,f,p,g,m,v,y,b;return P((function(x){switch(x.g){case 1:return u=jv,l=Uv,f=h=0,p=Date.now(),S(x,2),w(x,u(e,n),4);case 4:if(c=x.h,a(Lv(c.headers)),"HEAD"==n.method){x.u(5);break}return g=c.clone().body.getReader(),v=(m=c.headers.get("Content-Length"))?parseInt(m,10):0,new l({start:function(e){!function t(){var n,i,a,u;return P((function(l){switch(l.g){case 1:return S(l,2),w(l,g.read(),4);case 4:n=l.h,A(l,3);break;case 2:return E(l),l.return();case 3:if(n.done){l.u(5);break}if(h+=n.value.byteLength,!o){l.u(5);break}return w(l,o(n.value),5);case 5:i=Date.now(),a=h-f,(100<i-p&&a>=s||n.done)&&(u=n.done?0:v-h,r(i-p,a,u),f=h,p=i),n.done?e.close():(e.enqueue(n.value),t()),T(l)}}))}()}}),w(x,c.arrayBuffer(),6);case 6:d=x.h;case 5:A(x,3);break;case 2:if(y=E(x),i.ng)throw new De(1,1,7001,e,t);if(i.ph)throw new De(1,1,1003,e,t);throw new De(1,1,1002,e,y,t);case 3:return b=Lv(c.headers),x.return(Dv(b,d,c.status,e,c.url,t))}}))}(e,n,{body:t.body||void 0,headers:o,method:t.method,signal:s.signal,credentials:t.allowCrossSiteCredentials?"include":void 0},u,i,r,t.streamDataCallback,a.minBytesForProgressEvents||0),e=new Kr(e,(function(){return u.ng=!0,s.abort(),Promise.resolve()})),t=t.retryParameters.timeout){var l=new Be((function(){u.ph=!0,s.abort()}));l.$(t/1e3),e.finally((function(){l.stop()}))}return e}function Lv(e){var t={};return e.forEach((function(e,n){t[n.trim()]=e})),t}function Nv(){if(!e.ReadableStream)return!1;try{new ReadableStream({})}catch(e){return!1}return!!e.Response&&!!new Response("").body&&!(!e.fetch||"polyfill"in e.fetch||!e.AbortController)}co["application/vnd.ms-sstr+xml"]=function(){return new Ev},F("shaka.net.HttpFetchPlugin",Rv),Rv.isSupported=Nv,Rv.parse=Pv;var jv=e.fetch,Ov=e.AbortController,Uv=e.ReadableStream,_v=e.Headers;function Bv(){}function Fv(e,t,n,i,r,a){var o=new Hv,s=Date.now(),u=0;return new Kr(new Promise((function(l,c){o.open(t.method,e,!0),o.responseType="arraybuffer",o.timeout=t.retryParameters.timeout,o.withCredentials=t.allowCrossSiteCredentials,o.onabort=function(){c(new De(1,1,7001,e,n))};var d=!1;for(var h in o.onreadystatechange=function(){if(2==o.readyState&&!d){var e=Vv(o);r(e),d=!0}},o.onload=function(t){var r=Vv(o),a=o.response;try{i(Date.now()-s,t.loaded-u,0);var d=Dv(r,a,o.status,e,o.responseURL,n);l(d)}catch(e){c(e)}},o.onerror=function(t){c(new De(1,1,1002,e,t,n))},o.ontimeout=function(){c(new De(1,1,1003,e,n))},o.onprogress=function(e){var t=Date.now(),n=a.minBytesForProgressEvents||0,r=e.loaded-u;(100<t-s&&r>=n||e.lengthComputable&&e.loaded==e.total)&&(i(t-s,r,4==o.readyState?0:e.total-e.loaded),u=e.loaded,s=t)},t.headers)o.setRequestHeader(h.toLowerCase(),t.headers[h]);o.send(t.body)})),(function(){return o.abort(),Promise.resolve()}))}function Vv(e){var t=e.getAllResponseHeaders().trim().split("\r\n");e={};for(var n=(t=l(t)).next();!n.done;n=t.next())e[(n=n.value.split(": "))[0].toLowerCase()]=n.slice(1).join(": ");return e}Nv()&&(ia("http",Pv,2,!0),ia("https",Pv,2,!0),ia("blob",Pv,2,!0)),F("shaka.net.HttpXHRPlugin",Bv),Bv.parse=Fv;var Hv=e.XMLHttpRequest;function Gv(e,t,n,i){this.g=e,this.i=t,this.groupId=n,this.h=i}function Kv(e){return e.N().map((function(e){return"{"+encodeURI(e.split("#xywh=")[0])+"}"})).join("")+":"+e.Ja+":"+e.va}function Xv(e,t){return Ru(e.g.N(),e.g.Ja,e.g.va,t.streaming.retryParameters)}function qv(){this.h=this.j=this.i=0,this.g=new Map,this.l=0}function zv(e,t){e.i+=t;var n=e.l;return e.l++,e.g.set(n,t),n}function Wv(e){var t=this;this.o=e,this.j=new Map,this.i=new fa((function(){return Yv(t).catch((function(){}))})),this.h=[],this.m=function(){},this.l=function(){},this.g=new qv}function Yv(e){var t=e.h.map((function(e){return e()}));return e.h=[],Promise.all(t)}function Jv(e,t,n,i,r,a){pa(e.i);var o=(e.j.get(t)||Promise.resolve()).then((function(){var t,o,s,u,l,c,d;return P((function(h){if(1==h.g)return w(h,function(e,t){var n,i,r,a;return P((function(o){return 1==o.g?(n=ca,i=e.o.request(n,t),r=function(){return i.abort()},e.h.push(r),w(o,i.promise,2)):(a=o.h,Ie(e.h,r),o.return(a.data))}))}(e,n),2);if(t=h.h,e.i.g)throw new De(2,9,7001);if(r)for(u in o=ge(t),(s=new Pa(o)).data)l=Number(u),c=s.data[l],d=s.g[l],e.l(c,d);e.g.close(i,t.byteLength);var f=e.g;return e.m(0==f.i?0:f.j/f.i,e.g.h),h.return(a(t))}))}));e.j.set(t,o)}function $v(e,t){var n=this;this.i=e,this.h=e.objectStore(t),this.g=new Gr,e.onabort=function(e){e.preventDefault(),n.g.reject()},e.onerror=function(e){e.preventDefault(),n.g.reject()},e.oncomplete=function(){n.g.resolve()}}function Qv(e,t){return new Promise((function(n,i){var r=e.h.openCursor();r.onerror=i,r.onsuccess=function(){var e;return P((function(i){if(1==i.g)return null==r.result?(n(),i.return()):(e=r.result,w(i,t(e.key,e.value,e),2));e.continue(),T(i)}))}}))}function Zv(e){this.h=e,this.g=[]}function ey(e,t){return ty(e,t,"readwrite")}function ty(e,t,n){var i=new $v(n=e.h.transaction([t],n),t);return e.g.push(i),i.promise().then((function(){Ie(e.g,i)}),(function(){Ie(e.g,i)})),i}function ny(e,t,n){this.h=new Zv(e),this.i=t,this.g=n}function iy(e){return Promise.reject(new De(2,9,9011,"Cannot add new value to "+e))}function ry(e,t,n,i){t=(e=ey(e.h,t)).store();for(var r=(n=l(n)).next(),a={};!r.done;a={wf:void 0},r=n.next())a.wf=r.value,t.delete(a.wf).onsuccess=function(e){return function(){return i(e.wf)}}(a);return e.promise()}function ay(e,t,n){var i,r,a,o,s,u,c;return P((function(d){if(1==d.g){for(i=ty(e.h,t,"readonly"),r=i.store(),a={},o=[],s=l(n),u=s.next(),c={};!u.done;c={ke:void 0,Vd:void 0},u=s.next())c.Vd=u.value,c.ke=r.get(c.Vd),c.ke.onsuccess=function(e){return function(){null==e.ke.result&&o.push(e.Vd),a[e.Vd]=e.ke.result}}(c);return w(d,i.promise(),2)}if(o.length)throw new De(2,9,9012,"Could not find values for "+o);return d.return(n.map((function(e){return a[e]})))}))}function oy(e){this.g=new Zv(e)}function sy(){this.g=new Map}function uy(e){var t=null;if(e.g.forEach((function(e,n){e.getCells().forEach((function(e,i){e.hasFixedKeySpace()||t||(t={path:{rb:n,Ma:i},Ma:e})}))})),t)return t;throw new De(2,9,9013,"Could not find a cell that supports add-operations")}function ly(e,t,n){if(!(e=e.g.get(t)))throw new De(2,9,9013,"Could not find mechanism with name "+t);if(!(t=e.getCells().get(n)))throw new De(2,9,9013,"Could not find cell with name "+n);return t}function cy(e,t){dy.set(e,t)}ia("http",Fv,1,!0),ia("https",Fv,1,!0),ia("blob",Fv,1,!0),qv.prototype.close=function(e,t){if(this.g.has(e)){var n=this.g.get(e);this.g.delete(e),this.j+=n,this.h+=t}},Wv.prototype.destroy=function(){return this.i.destroy()},$v.prototype.abort=function(){var e=this;return P((function(t){if(1==t.g){try{e.i.abort()}catch(e){}return S(t,2),w(t,e.g,4)}if(2!=t.g)return A(t,0);E(t),T(t)}))},$v.prototype.store=function(){return this.h},$v.prototype.promise=function(){return this.g},Zv.prototype.destroy=function(){return Promise.all(this.g.map((function(e){return e.abort()})))},(i=ny.prototype).destroy=function(){return this.h.destroy()},i.hasFixedKeySpace=function(){return!0},i.addSegments=function(){return iy(this.i)},i.removeSegments=function(e,t){return ry(this,this.i,e,t)},i.getSegments=function(e){var t,n=this;return P((function(i){return 1==i.g?w(i,ay(n,n.i,e),2):(t=i.h,i.return(t.map((function(e){return n.qg(e)}))))}))},i.addManifests=function(){return iy(this.g)},i.updateManifest=function(){return Promise.reject(new De(2,9,9016,"Cannot modify values in "+this.g))},i.updateManifestExpiration=function(e,t){var n=ey(this.h,this.g),i=n.store();return i.get(e).onsuccess=function(n){(n=n.target.result)&&(n.expiration=t,i.put(n,e))},n.promise()},i.removeManifests=function(e,t){return ry(this,this.g,e,t)},i.getManifests=function(e){var t,n=this;return P((function(i){return 1==i.g?w(i,ay(n,n.g,e),2):(t=i.h,i.return(Promise.all(t.map((function(e){return n.cd(e)})))))}))},i.getAllManifests=function(){var e,t,n=this;return P((function(i){return 1==i.g?(e=ty(n.h,n.g,"readonly"),t=new Map,w(i,Qv(e,(function(e,i){var r;return P((function(a){if(1==a.g)return w(a,n.cd(i),2);r=a.h,t.set(e,r),T(a)}))})),2)):3!=i.g?w(i,e.promise(),3):i.return(t)}))},i.qg=function(e){return e},i.cd=function(e){return Promise.resolve(e)},i.add=function(e,t){var n,i,r,a,o,s,u,c=this;return P((function(d){if(1==d.g){for(n=ey(c.h,e),i=n.store(),r=[],a=l(t),o=a.next(),s={};!o.done;s={Lf:void 0},o=a.next())u=o.value,s.Lf=i.add(u),s.Lf.onsuccess=function(e){return function(){r.push(e.Lf.result)}}(s);return w(d,n.promise(),2)}return d.return(r)}))},oy.prototype.destroy=function(){return this.g.destroy()},oy.prototype.getAll=function(){var e,t,n=this;return P((function(i){return 1==i.g?(e=ty(n.g,"session-ids","readonly"),t=[],w(i,Qv(e,(function(e,n){t.push(n)})),2)):3!=i.g?w(i,e.promise(),3):i.return(t)}))},oy.prototype.add=function(e){for(var t=ey(this.g,"session-ids"),n=t.store(),i=(e=l(e)).next();!i.done;i=e.next())n.add(i.value);return t.promise()},oy.prototype.remove=function(e){var t,n=this;return P((function(i){return 1==i.g?w(i,Qv(t=ey(n.g,"session-ids"),(function(t,n,i){e.includes(n.sessionId)&&i.delete()})),2):w(i,t.promise(),0)}))},sy.prototype.destroy=function(){for(var e=[],t=l(this.g.values()),n=t.next();!n.done;n=t.next())e.push(n.value.destroy());return this.g.clear(),Promise.all(e)},sy.prototype.init=function(){var e=this;dy.forEach((function(t,n){(t=t())&&e.g.set(n,t)}));for(var t=[],n=l(this.g.values()),i=n.next();!i.done;i=n.next())t.push(i.value.init());return Promise.all(t)},F("shaka.offline.StorageMuxer",sy),sy.unregister=function(e){dy.delete(e)},sy.register=cy,sy.prototype.destroy=sy.prototype.destroy;var dy=new Map;function hy(){ny.apply(this,arguments)}function fy(e,t){!function(e){var t=e.streams.filter((function(e){return"audio"==e.contentType}));if(e=e.streams.filter((function(e){return"video"==e.contentType})),!t.every((function(e){return e.variantIds}))||!e.every((function(e){return e.variantIds}))){for(var n=l(t),i=n.next();!i.done;i=n.next())i.value.variantIds=[];for(i=(n=l(e)).next();!i.done;i=n.next())i.value.variantIds=[];if(n=0,e.length&&!t.length){i=n++;for(var r=l(e),a=r.next();!a.done;a=r.next())a.value.variantIds.push(i)}if(!e.length&&t.length)for(i=n++,a=(r=l(t)).next();!a.done;a=r.next())a.value.variantIds.push(i);if(e.length&&t.length)for(i=(t=l(t)).next();!i.done;i=t.next())for(i=i.value,a=(r=l(e)).next();!a.done;a=r.next()){a=a.value;var o=n++;i.variantIds.push(o),a.variantIds.push(o)}}}(e);for(var n=l(e.streams),i=n.next();!i.done;i=n.next());return e.streams.map((function(n){return function(e,t,n){var i=e.initSegmentUri?py(e.initSegmentUri):null,r=t+e.presentationTimeOffset,a=t+n;return{id:e.id,originalId:null,groupId:null,primary:e.primary,type:e.contentType,mimeType:e.mimeType,codecs:e.codecs,frameRate:e.frameRate,pixelAspectRatio:void 0,hdr:void 0,colorGamut:void 0,videoLayout:void 0,kind:e.kind,language:e.language,originalLanguage:e.language||null,label:e.label,width:e.width,height:e.height,initSegmentKey:i,encrypted:e.encrypted,keyIds:new Set([e.keyId]),segments:e.segments.map((function(e){var n=py(e.uri);return{startTime:t+e.startTime,endTime:t+e.endTime,dataKey:n,initSegmentKey:i,appendWindowStart:t,appendWindowEnd:a,timestampOffset:r,tilesLayout:"",mimeType:null,codecs:null,thumbnailSprite:null}})),variantIds:e.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0,external:!1,fastSwitching:!1,isAudioMuxedInVideo:!1}}(n,e.startTime,t)}))}function py(e){var t;if((t=/^offline:[0-9]+\/[0-9]+\/([0-9]+)$/.exec(e))||(t=/^offline:segment\/([0-9]+)$/.exec(e)))return Number(t[1]);throw new De(2,9,9004,"Could not parse uri "+e)}function gy(){ny.apply(this,arguments)}function my(e,t,n){return{id:e.id,originalId:e.originalId,groupId:null,primary:e.primary,type:e.contentType,mimeType:e.mimeType,codecs:e.codecs,frameRate:e.frameRate,pixelAspectRatio:e.pixelAspectRatio,hdr:void 0,colorGamut:void 0,videoLayout:void 0,kind:e.kind,language:e.language,originalLanguage:e.language||null,label:e.label,width:e.width,height:e.height,encrypted:e.encrypted,keyIds:new Set([e.keyId]),segments:e.segments.map((function(i){return{startTime:t+i.startTime,endTime:t+i.endTime,initSegmentKey:e.initSegmentKey,appendWindowStart:t,appendWindowEnd:n,timestampOffset:t-e.presentationTimeOffset,dataKey:i.dataKey,tilesLayout:"",mimeType:null,codecs:null,thumbnailSprite:null}})),variantIds:e.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0,external:!1,fastSwitching:!1,isAudioMuxedInVideo:!1}}function vy(){ny.apply(this,arguments)}function yy(){this.m=this.j=this.i=this.h=this.g=this.l=null}function by(e,t,n,i){this.g=e,this.i=t,this.h=n,this.l=i,this.j=["offline:",e,"/",t,"/",n,"/",i].join("")}function wy(e){if(null==(e=/^offline:([a-z]+)\/([^/]+)\/([^/]+)\/([0-9]+)$/.exec(e)))return null;var t=e[1];if("manifest"!=t&&"segment"!=t)return null;var n=e[2];if(!n)return null;var i=e[3];return i&&null!=t?new by(t,n,i,Number(e[4])):null}function Ty(e,t){this.h=e,this.g=t}function Sy(e,t){var n=new Ls(null,0);n.bb(t.duration);var i=t.streams.filter((function(e){return"audio"==e.type})),r=t.streams.filter((function(e){return"video"==e.type}));i=function(e,t,n,i){for(var r=new Set,a=l(t),o=a.next();!o.done;o=a.next())for(var s=(o=l(o.value.variantIds)).next();!s.done;s=o.next())r.add(s.value);for(o=(a=l(n)).next();!o.done;o=a.next())for(s=(o=l(o.value.variantIds)).next();!s.done;s=o.next())r.add(s.value);for(a=new Map,o=(r=l(r)).next();!o.done;o=r.next())o=o.value,a.set(o,{id:o,language:"",disabledUntilTime:0,primary:!1,audio:null,video:null,bandwidth:0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});for(r=(t=l(t)).next();!r.done;r=t.next())for(r=xy(e,o=r.value,i),s=(o=l(o.variantIds)).next();!s.done;s=o.next())(s=a.get(s.value)).language=r.language,s.primary=s.primary||r.primary,s.audio=r;for(t=(n=l(n)).next();!t.done;t=n.next())for(t=xy(e,r=t.value,i),o=(r=l(r.variantIds)).next();!o.done;o=r.next())(o=a.get(o.value)).primary=o.primary||t.primary,o.video=t;return a}(e,i,r,n),r=t.streams.filter((function(e){return e.type==yi})).map((function(t){return xy(e,t,n)}));var a=t.streams.filter((function(e){return"image"==e.type})).map((function(t){return xy(e,t,n)})),o=t.drmInfo?[t.drmInfo]:[];if(t.drmInfo)for(var s=l(i.values()),u=s.next();!u.done;u=s.next())(u=u.value).audio&&u.audio.encrypted&&(u.audio.drmInfos=o),u.video&&u.video.encrypted&&(u.video.drmInfos=o);return{presentationTimeline:n,minBufferTime:2,offlineSessionIds:t.sessionIds,variants:Array.from(i.values()),textStreams:r,imageStreams:a,sequenceMode:t.sequenceMode||!1,ignoreManifestTimestampsInSegmentsMode:!1,type:t.type||"UNKNOWN",serviceDescription:null,nextUrl:null,periodCount:1,gapCount:0,isLowLatency:!1,startTime:null}}function xy(e,t,n){var i=t.segments.map((function(n){return function(e,t,n){var i=new by("segment",e.h,e.g,t.dataKey);return e=new vo(t.startTime,t.endTime,(function(){return[i.toString()]}),0,null,null!=t.initSegmentKey?function(e,t){var n=new by("segment",e.h,e.g,t);return new go((function(){return[n.toString()]}),0,null)}(e,t.initSegmentKey):null,t.timestampOffset,t.appendWindowStart,t.appendWindowEnd,[],t.tilesLayout||""),e.mimeType=t.mimeType||n.mimeType||"",e.codecs=t.codecs||n.codecs||"",t.thumbnailSprite&&e.qe(t.thumbnailSprite),e}(e,n,t)}));return n.vd(i),{id:t.id,originalId:t.originalId,groupId:t.groupId,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Zs(i),mimeType:t.mimeType,codecs:t.codecs,width:t.width||void 0,height:t.height||void 0,frameRate:t.frameRate,pixelAspectRatio:t.pixelAspectRatio,hdr:t.hdr,colorGamut:t.colorGamut,videoLayout:t.videoLayout,kind:t.kind,encrypted:t.encrypted,drmInfos:[],keyIds:t.keyIds,language:t.language,originalLanguage:t.originalLanguage||null,label:t.label,type:t.type,primary:t.primary,trickModeVideo:null,emsgSchemeIdUris:null,roles:t.roles,forced:t.forced,channelsCount:t.channelsCount,audioSamplingRate:t.audioSamplingRate,spatialAudio:t.spatialAudio,closedCaptions:t.closedCaptions,tilesLayout:t.tilesLayout,accessibilityPurpose:null,external:t.external,fastSwitching:t.fastSwitching,fullMimeTypes:new Set([xi(t.mimeType,t.codecs)]),isAudioMuxedInVideo:!1}}function Ay(){this.g=null}function Ey(){}function ky(e){var t=wy(e);return e=t&&"manifest"==t.g?zr(e={uri:e,originalUri:e,data:new ArrayBuffer(0),headers:{"content-type":"application/x-offline-manifest"}}):t&&"segment"==t.g?function(e,t){var n=new sy;return zr(void 0).Ca((function(){return n.init()})).Ca((function(){return ly(n,t.rb(),t.Ma())})).Ca((function(e){return e.getSegments([t.key()])})).Ca((function(e){return{uri:t,data:e[0].data,headers:{}}})).finally((function(){return n.destroy()}))}(t.key(),t):Xr(new De(2,1,9004,e))}function Iy(e,t,n){var i,r,a,o,s,u;return P((function(c){switch(c.g){case 1:i=[];for(var d=[],h=l(n),f=h.next();!f.done;f=h.next()){f=f.value;for(var p=!1,g=l(d),m=g.next();!m.done;m=g.next())if(My((m=m.value).info,f)){m.sessionIds.push(f.sessionId),p=!0;break}p||d.push({info:f,sessionIds:[f.sessionId]})}r=l(d),a=r.next();case 2:if(a.done){c.u(4);break}return o=a.value,s=function(e,t,n){var i,r;return P((function(a){switch(a.g){case 1:return i=new Na({Nb:t,onError:function(){},ee:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),S(a,2),i.configure(e),w(a,function(e,t,n,i,r,a){var o=new Map;return(r={audioCapabilities:r,videoCapabilities:a,distinctiveIdentifier:"optional",persistentState:"required",sessionTypes:["persistent-license"],label:t}).drmInfos=[{keySystem:t,licenseServerUri:n,distinctiveIdentifierRequired:!1,persistentStateRequired:!0,audioRobustness:"",videoRobustness:"",serverCertificate:i,serverCertificateUri:"",initData:null,keyIds:null}],o.set(t,r),Va(e,o,[])}(i,n.info.keySystem,n.info.licenseUri,n.info.serverCertificate,n.info.audioCapabilities,n.info.videoCapabilities),4);case 4:A(a,3);break;case 2:return E(a),w(a,i.destroy(),5);case 5:return a.return([]);case 3:return r=[],w(a,Promise.all(n.sessionIds.map((function(e){return P((function(t){return 1==t.g?(S(t,2),w(t,function(e,t){var n,i,r;return P((function(a){return 1==a.g?w(a,Ka(e,t,{initData:null,initDataType:null}),2):3!=a.g?(n=a.h)?(i=[],(r=e.i.get(n))&&(r.nb=new Gr,i.push(r.nb)),i.push(n.remove()),w(a,Promise.all(i),3)):a.return():(e.i.delete(n),void T(a))}))}(i,e),4)):2!=t.g?(r.push(e),A(t,0)):(E(t),void T(t))}))}))),6);case 6:return w(a,i.destroy(),7);case 7:return a.return(r)}}))}(e,t,o),w(c,s,5);case 5:u=c.h,i=i.concat(u),a=r.next(),c.u(2);break;case 4:return c.return(i)}}))}function My(e,t){function n(e,t){return e.robustness==t.robustness&&e.contentType==t.contentType}return e.keySystem==t.keySystem&&e.licenseUri==t.licenseUri&&Me(e.audioCapabilities,t.audioCapabilities,n)&&Me(e.videoCapabilities,t.videoCapabilities,n)}function Cy(e,t){var n=Sy(new Ty(e.rb(),e.Ma()),t),i=t.appMetadata||{};return n=Dy(n),{offlineUri:e.toString(),originalManifestUri:t.originalManifestUri,duration:t.duration,size:t.size,expiration:t.expiration,tracks:n,appMetadata:i,isIncomplete:t.isIncomplete||!1}}function Dy(e){for(var t=[],n=br(e.variants),i=(n=l(n)).next();!i.done;i=n.next())t.push(dr(i.value));for(n=(e=l(e.textStreams)).next();!n.done;n=e.next())t.push(hr(n.value));return t}function Ry(){this.g={}}function Py(e,t){var n=t.audio,i=t.video;if(n&&!i&&(e.g[n.id]=n.bandwidth||t.bandwidth),!n&&i&&(e.g[i.id]=i.bandwidth||t.bandwidth),n&&i){var r=n.bandwidth||393216,a=i.bandwidth||t.bandwidth-r;0>=a&&(a=t.bandwidth),e.g[n.id]=r,e.g[i.id]=a}}function Ly(e,t){e.g[t.id]=t.bandwidth||2048}function Ny(e,t){return null==(e=e.g[t])&&(e=0),e}function jy(e){var t=this;if(e&&e.constructor!=lc)throw new De(2,9,9008);this.g=this.h=null,e?(this.h=e.g,this.g=e.Ab()):(this.h=ll(),this.g=new na),this.i=[],this.j=[];var n=!e;this.l=new fa((function(){var e,i,r,a,o;return P((function(s){switch(s.g){case 1:return w(s,Promise.all(t.j.map((function(e){return Yv(e)}))),2);case 2:for(e=function(){},i=[],r=l(t.i),a=r.next();!a.done;a=r.next())o=a.value,i.push(o.then(e,e));return w(s,Promise.all(i),3);case 3:if(!n){s.u(4);break}return w(s,t.g.destroy(),4);case 4:t.h=null,t.g=null,T(s)}}))})),this.m=1e9}function Oy(){if(Fe())e:{for(var e=l(dy.values()),t=e.next();!t.done;t=e.next())if(t=(t=t.value)()){t.destroy(),e=!0;break e}e=!1}else e=!1;return e}function Uy(e){var t,n,i;return P((function(r){switch(r.g){case 1:return w(r,(t=new sy).init(),2);case 2:return w(r,uy(t),3);case 3:return n=r.h,i=new by("manifest",n.path.rb,n.path.Ma,e),w(r,t.destroy(),4);case 4:return w(r,(new jy).remove(i.toString()),0)}}))}function _y(e,t,n,i,r,a){var o,s,u,c,d,h,f,p,g,m,v;return P((function(y){switch(y.g){case 1:for(o=!1,S(y,2),s=!0,u=l(n.streams),c=u.next();!c.done;c=u.next())for(d=c.value,h=l(d.segments),f=h.next();!f.done;f=h.next())p=f.value,null!=(g=p.pendingSegmentRefId?i[p.pendingSegmentRefId]:null)&&(p.dataKey=g,p.pendingSegmentRefId=void 0),null!=(g=p.pendingInitSegmentRefId?i[p.pendingInitSegmentRefId]:null)&&(p.initSegmentKey=g,p.pendingInitSegmentRefId=void 0),p.pendingSegmentRefId&&(s=!1),p.pendingInitSegmentRefId&&(s=!1);return n.size+=r,s&&(n.isIncomplete=!1),w(y,e.updateManifest(t,n),4);case 4:o=!0,a(),A(y,0);break;case 2:return m=E(y),w(y,Uy(t),5);case 5:if(o){y.u(6);break}return v=Object.values(i),w(y,e.removeSegments(v,(function(){})),6);case 6:throw m}}))}function By(e){return e.variants.some((function(e){var t=e.audio&&e.audio.encrypted;return e.video&&e.video.encrypted||t}))}function Fy(e){return e.variants.some((function(e){return(e.video?e.video.drmInfos:[]).concat(e.audio?e.audio.drmInfos:[]).some((function(e){return e.initData&&e.initData.length}))}))}function Vy(e,t,n,i){if(t.expiration=n.gd(),n=Fa(n),t.sessionIds=i.offline.usePersistentLicense?n:[],By(e)&&i.offline.usePersistentLicense&&!n.length)throw new De(2,9,9007)}function Hy(e,t){for(var n=[],i=l(e.streams),r=i.next();!r.done;r=i.next())r=r.value,t&&"video"==r.type?n.push({contentType:xi(r.mimeType,r.codecs),robustness:e.drmInfo.videoRobustness}):t||"audio"!=r.type||n.push({contentType:xi(r.mimeType,r.codecs),robustness:e.drmInfo.audioRobustness});return n}function Gy(e,t,n){return P((function(i){return w(i,function(e,t,n,i){var r,a,o;return P((function(s){return 1==s.g?i.drmInfo?(r=function(e){var t=Array.from(e.g.keys());if(!t.length)throw new De(2,9,9e3,"No supported storage mechanisms found");return e.g.get(t[0]).getEmeSessionCell()}(n),a=i.sessionIds.map((function(e){return{sessionId:e,keySystem:i.drmInfo.keySystem,licenseUri:i.drmInfo.licenseServerUri,serverCertificate:i.drmInfo.serverCertificate,audioCapabilities:Hy(i,!1),videoCapabilities:Hy(i,!0)}})),w(s,Iy(t,e,a),2)):s.return():3!=s.g?(o=s.h,w(s,r.remove(o),3)):w(s,r.add(a.filter((function(e){return!o.includes(e.sessionId)}))),0)}))}(e.g,e.h.drm,n,t),0)}))}function Ky(e,t,n){function i(){}var r=function(e){for(var t=new Set,n=(e=l(e.streams)).next();!n.done;n=e.next())for(var i=(n=l(n.value.segments)).next();!i.done;i=n.next())null!=(i=i.value).initSegmentKey&&t.add(i.initSegmentKey),t.add(i.dataKey);return Array.from(t)}(n);return Cy(t,n),Promise.all([e.removeSegments(r,i),e.removeManifests([t.key()],i)])}function Xy(e,t){var n;return P((function(i){switch(i.g){case 1:return S(i,2),w(i,Al(t,e.g,e.h.streaming.retryParameters),4);case 4:n=i.h,A(i,3);break;case 2:E(i);case 3:if(n)return i.return(n);throw new De(1,2,2011,t)}}))}function qy(e,t,n,i,r,a){var o={id:i.id,originalId:i.originalId,groupId:i.groupId,primary:i.primary,type:i.type,mimeType:i.mimeType,codecs:i.codecs,frameRate:i.frameRate,pixelAspectRatio:i.pixelAspectRatio,hdr:i.hdr,colorGamut:i.colorGamut,videoLayout:i.videoLayout,kind:i.kind,language:i.language,originalLanguage:i.originalLanguage,label:i.label,width:i.width||null,height:i.height||null,encrypted:i.encrypted,keyIds:i.keyIds,segments:[],variantIds:[],roles:i.roles,forced:i.forced,channelsCount:i.channelsCount,audioSamplingRate:i.audioSamplingRate,spatialAudio:i.spatialAudio,closedCaptions:i.closedCaptions,tilesLayout:i.tilesLayout,external:i.external,fastSwitching:i.fastSwitching,isAudioMuxedInVideo:i.isAudioMuxedInVideo},s=r.offline.numberOfParallelDownloads,u=0===s?i.id:0;return function(e,t,n){if(null!=(t=e.segmentIndex.find(t)))for(var i=e.segmentIndex.get(t);i;)n(i),i=e.segmentIndex.get(++t)}(i,n.presentationTimeline.qb(),(function(n){var r=Kv(n),l=void 0;if(!a.has(r)){var c=n.endTime-n.startTime;c=Ny(t,i.id)*c,c=zv(e.g,c),a.set(r,new Gv(n,c,u,!1))}n.ba&&(l=Kv(n.ba),a.has(l)||(c=.5*Ny(t,i.id),c=zv(e.g,c),a.set(l,new Gv(n.ba,c,u,!0)))),o.segments.push({pendingInitSegmentRefId:l,initSegmentKey:l?0:null,startTime:n.startTime,endTime:n.endTime,appendWindowStart:n.appendWindowStart,appendWindowEnd:n.appendWindowEnd,timestampOffset:n.timestampOffset,tilesLayout:n.tilesLayout,pendingSegmentRefId:r,dataKey:0,mimeType:n.mimeType,codecs:n.codecs,thumbnailSprite:n.thumbnailSprite}),0!==s&&(u=(u+1)%s)})),o}function zy(e){if(e.l.g)throw new De(2,9,7001)}function Wy(){if(!Oy())throw new De(2,9,9e3)}function Yy(e,t){return P((function(n){return 1==n.g?(e.i.push(t),x(n,2),w(n,t,4)):2!=n.g?n.return(n.h):(k(n),Ie(e.i,t),I(n,0))}))}function Jy(e){for(var t=new Set,n=l(e.variants),i=n.next();!i.done;i=n.next())(i=i.value).audio&&t.add(i.audio),i.video&&t.add(i.video);for(i=(n=l(e.textStreams)).next();!i.done;i=n.next())t.add(i.value);for(n=(e=l(e.imageStreams)).next();!n.done;n=e.next())t.add(n.value);return t}m(hy,ny),hy.prototype.updateManifestExpiration=function(e,t){var n,i,r,a=this;return P((function(o){return n=ey(a.h,a.g),i=n.store(),r=new Gr,i.get(e).onsuccess=function(n){(n=n.target.result)?(n.expiration=t,i.put(n),r.resolve()):r.reject(new De(2,9,9012,"Could not find values for "+e))},w(o,Promise.all([n.promise(),r]),0)}))},hy.prototype.cd=function(e){var t,n,i,r,a,o;return P((function(s){if(1==s.g){for(t=[],n=0;n<e.periods.length;++n)i=n==e.periods.length-1?e.duration:e.periods[n+1].startTime,r=i-e.periods[n].startTime,a=fy(e.periods[n],r),t.push(a);return w(s,xp(t),2)}return o=s.h,s.return({creationTime:0,originalManifestUri:e.originalManifestUri,duration:e.duration,size:e.size,expiration:null==e.expiration?1/0:e.expiration,streams:o,sessionIds:e.sessionIds,drmInfo:e.drmInfo,appMetadata:e.appMetadata,sequenceMode:!1})}))},hy.prototype.qg=function(e){return{data:e.data}},m(gy,ny),gy.prototype.cd=function(e){var t,n,i,r,a,o;return P((function(s){if(1==s.g){for(t=[],n=0;n<e.periods.length;++n){i=n==e.periods.length-1?e.duration:e.periods[n+1].startTime,r=i-e.periods[n].startTime;for(var u=e.periods[n],c=[],d=l(u.streams),h=d.next();!h.done;h=d.next())0!=(h=h.value).variantIds.length&&c.push(my(h,u.startTime,u.startTime+r));a=c,t.push(a)}return w(s,xp(t),2)}return o=s.h,s.return({appMetadata:e.appMetadata,creationTime:0,drmInfo:e.drmInfo,duration:e.duration,expiration:null==e.expiration?1/0:e.expiration,originalManifestUri:e.originalManifestUri,sessionIds:e.sessionIds,size:e.size,streams:o,sequenceMode:!1})}))},m(vy,ny),(i=vy.prototype).hasFixedKeySpace=function(){return!1},i.addSegments=function(e){return this.add(this.i,e)},i.addManifests=function(e){return this.add(this.g,e)},i.updateManifest=function(e,t){return function(e,t,n){var i=(e=ey(e.h,e.g)).store();return i.get(t).onsuccess=function(){i.put(n,t)},e.promise()}(this,e,t)},i.cd=function(e){return null==e.expiration&&(e.expiration=1/0),Promise.resolve(e)},(i=yy.prototype).init=function(){var t=this,n=new Gr,i=!1,r=new Be((function(){i=!0,n.reject(new De(2,9,9017))}));r.$(5);var a=e.indexedDB.open("shaka_offline_db",5);return a.onsuccess=function(){if(!i){var e=a.result;t.l=e;var o=e.objectStoreNames;o=o.contains("manifest")&&o.contains("segment")?new hy(e,"segment","manifest"):null,t.g=o,o=(o=e.objectStoreNames).contains("manifest-v2")&&o.contains("segment-v2")?new gy(e,"segment-v2","manifest-v2"):null,t.h=o,o=(o=e.objectStoreNames).contains("manifest-v3")&&o.contains("segment-v3")?new gy(e,"segment-v3","manifest-v3"):null,t.i=o,o=(o=e.objectStoreNames).contains("manifest-v5")&&o.contains("segment-v5")?new vy(e,"segment-v5","manifest-v5"):null,t.j=o,e=e.objectStoreNames.contains("session-ids")?new oy(e):null,t.m=e,r.stop(),n.resolve()}},a.onupgradeneeded=function(){for(var e=a.result,t=l(["segment-v5","manifest-v5","session-ids"]),n=t.next();!n.done;n=t.next())n=n.value,e.objectStoreNames.contains(n)||e.createObjectStore(n,{autoIncrement:!0})},a.onerror=function(e){i||(n.reject(new De(2,9,9001,a.error)),r.stop(),e.preventDefault())},n},i.destroy=function(){var e=this;return P((function(t){switch(t.g){case 1:if(!e.g){t.u(2);break}return w(t,e.g.destroy(),2);case 2:if(!e.h){t.u(4);break}return w(t,e.h.destroy(),4);case 4:if(!e.i){t.u(6);break}return w(t,e.i.destroy(),6);case 6:if(!e.j){t.u(8);break}return w(t,e.j.destroy(),8);case 8:if(!e.m){t.u(10);break}return w(t,e.m.destroy(),10);case 10:e.l&&e.l.close(),T(t)}}))},i.getCells=function(){var e=new Map;return this.g&&e.set("v1",this.g),this.h&&e.set("v2",this.h),this.i&&e.set("v3",this.i),this.j&&e.set("v5",this.j),e},i.getEmeSessionCell=function(){return this.m},i.erase=function(){var t=this;return P((function(n){switch(n.g){case 1:if(!t.g){n.u(2);break}return w(n,t.g.destroy(),2);case 2:if(!t.h){n.u(4);break}return w(n,t.h.destroy(),4);case 4:if(!t.i){n.u(6);break}return w(n,t.i.destroy(),6);case 6:if(!t.j){n.u(8);break}return w(n,t.j.destroy(),8);case 8:return t.l&&t.l.close(),w(n,function(){var t=new Gr,n=e.indexedDB.deleteDatabase("shaka_offline_db");return n.onblocked=function(){},n.onsuccess=function(){t.resolve()},n.onerror=function(e){t.reject(new De(2,9,9001,n.error)),e.preventDefault()},t}(),10);case 10:return t.l=null,t.g=null,t.h=null,t.i=null,t.j=null,w(n,t.init(),0)}}))},cy("idb",(function(){return(!ze()||ze()&&nt())&&!Ge()&&e.indexedDB?new yy:null})),by.prototype.rb=function(){return this.i},by.prototype.Ma=function(){return this.h},by.prototype.key=function(){return this.l},by.prototype.toString=function(){return this.j},(i=Ay.prototype).configure=function(){},i.start=function(e,t){var n,i,r,a,o,s,u=this;return P((function(l){switch(l.g){case 1:if(n=wy(e),u.g=n,null==n||"manifest"!=n.g)throw new De(2,1,9004,e);return i=new sy,x(l,2),w(l,i.init(),4);case 4:return w(l,ly(i,n.rb(),n.Ma()),5);case 5:return w(l,l.h.getManifests([n.key()]),6);case 6:return r=l.h,a=r[0],o=new Ty(n.rb(),n.Ma()),s=Sy(o,a),t.makeTextStreamsForClosedCaptions(s),l.return(s);case 2:return k(l),w(l,i.destroy(),7);case 7:I(l,0)}}))},i.stop=function(){return Promise.resolve()},i.update=function(){},i.onExpirationUpdated=function(e,t){var n,i,r,a,o,s,u,l=this;return P((function(c){switch(c.g){case 1:return n=l.g,i=new sy,S(c,2,3),w(c,i.init(),5);case 5:return w(c,ly(i,n.rb(),n.Ma()),6);case 6:return w(c,(r=c.h).getManifests([n.key()]),7);case 7:if(a=c.h,o=a[0],s=o.sessionIds.includes(e),u=null==o.expiration||o.expiration>t,!s||!u){c.u(3);break}return w(c,r.updateManifestExpiration(n.key(),t),3);case 3:return k(c),w(c,i.destroy(),10);case 10:I(c,0);break;case 2:E(c),c.u(3)}}))},i.onInitialVariantChosen=function(){},i.banLocation=function(){},i.setMediaElement=function(){},co["application/x-offline-manifest"]=function(){return new Ay},F("shaka.offline.OfflineScheme",Ey),Ey.plugin=ky,ia("offline",ky),(i=jy.prototype).destroy=function(){return this.l.destroy()},i.configure=function(e,t){return 2==arguments.length&&"string"==typeof e&&(e=el(e,t)),cl(this.h,e)},i.getConfiguration=function(){var e=ll();return cl(e,this.h,ll()),e},i.Ab=function(){return this.g},i.store=function(e,t,n,i,r){var a=this,o=this.getConfiguration(),s=new Wv(this.g);return this.j.push(s),t=function(e,t,n,i,r,a,o,s){var u,c,d,h,f,p,g,m,v,y,b,x,M,C,D,R,L,N,j,O,U;return P((function(_){switch(_.g){case 1:return Wy(),c=u=null,d=new sy,p=f=h=null,S(_,2,3),w(_,a(),5);case 5:return u=_.h,w(_,function(e,t,n,i){var r,a,o,s,u;return P((function(l){if(1==l.g)return r=null,a=e.g,o={networkingEngine:a,filter:function(){return Promise.resolve()},makeTextStreamsForClosedCaptions:function(){},onTimelineRegionAdded:function(){},onEvent:function(){},onError:function(e){r=e},isLowLatencyMode:function(){return!1},isAutoLowLatencyMode:function(){return!1},enableLowLatencyMode:function(){},updateDuration:function(){},newDrmInfo:function(){},onManifestUpdated:function(){},getBandwidthEstimate:function(){return i.abr.defaultBandwidthEstimate},onMetadata:function(){},disableStream:function(){},addFont:function(){}},n.configure(i.manifest),zy(e),w(l,n.start(t,o),2);if(3!=l.g)return s=l.h,zy(e),u=Jy(s),w(l,Promise.all(ga(u,(function(e){return e.createSegmentIndex()}))),3);if(zy(e),r)throw r;return l.return(s)}))}(e,t,u,o),6);case 6:if(g=_.h,zy(e),g.presentationTimeline.U()||g.presentationTimeline.uc())throw new De(2,9,9005,t);m=l(i),v=m.next();case 7:if(v.done){_.u(9);break}return y=v.value,w(_,function(e,t,n){var i,r,a,o,s,u,c,d,h,f,p,g,m,v,y;return P((function(b){switch(b.g){case 1:return w(b,Xy(e,t),2);case 2:if("text/vtt"!=(i=b.h))throw new De(1,2,2017,t);return w(b,function(e,t,n){var i,r,a;return P((function(o){return 1==o.g?(i=ca,(r=aa([e],n)).method="GET",w(o,t.request(i,r).promise,2)):(a=o.h,o.return(a.data))}))}(t,e.g,e.h.streaming.retryParameters),3);case 3:if(r=b.h,!(a=Fi[i]))throw new De(2,2,2014,i);for(o=a(),s={periodStart:0,segmentStart:0,segmentEnd:n.presentationTimeline.getDuration(),vttOffset:0},u=ge(r),c=o.parseMedia(u,s,t,[]),d=[],h=l(c),f=h.next(),p={};!f.done;p={ye:void 0,Ic:void 0},f=h.next())p.Ic=f.value,p.ye=null,g=function(e){return function(){return null==e.ye&&(e.ye=hi([t],[e.Ic.payload])),e.ye||[]}}(p),m=new vo(p.Ic.startTime,p.Ic.endTime,g,0,null,null,0,0,1/0),p.Ic.payload.includes("#xywh")&&4===(v=p.Ic.payload.split("#xywh=")[1].split(",")).length&&m.qe({height:parseInt(v[3],10),positionX:parseInt(v[0],10),positionY:parseInt(v[1],10),width:parseInt(v[2],10)}),d.push(m);if(y=i,!d.length){b.u(4);break}return w(b,Al(d[0].N()[0],e.g,e.h.manifest.retryParameters),5);case 5:y=b.h;case 4:return b.return({id:e.m++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Zs(d),mimeType:y||"",codecs:"",kind:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:"image",primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,tilesLayout:"1x1",accessibilityPurpose:null,external:!0,fastSwitching:!1,fullMimeTypes:new Set([xi(y||"","")]),isAudioMuxedInVideo:!1})}}))}(e,y,g),10);case 10:b=_.h,g.imageStreams.push(b),zy(e),v=m.next(),_.u(7);break;case 9:x=l(r),M=x.next();case 11:return M.done?w(_,e.Gc(g,(function(e){p=p||e}),o),15):(C=M.value,w(_,function(e,t,n,i,r,a,o){var s;return P((function(u){if(1==u.g)return a?u.u(2):w(u,Xy(e,n),3);if(2!=u.g&&(a=u.h),s={id:e.m++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:tu(0,t.presentationTimeline.getDuration(),[n]),mimeType:a||"",codecs:o||"",kind:r,encrypted:!1,drmInfos:[],keyIds:new Set,language:i,originalLanguage:i,label:null,type:yi,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!0,fastSwitching:!1,fullMimeTypes:new Set([xi(a||"",o||"")]),isAudioMuxedInVideo:!1},!Ui(xi(s.mimeType,s.codecs)))throw new De(2,2,2014,a);return u.return(s)}))}(e,g,C.uri,C.language,C.kind,C.mime,C.codecs),14));case 14:D=_.h,g.textStreams.push(D),zy(e),M=x.next(),_.u(11);break;case 15:if(c=_.h,zy(e),p)throw p;return w(_,function(e,t,n){var i,r,a,o,s,u,c,d,h,f,p,g,m,v,y,b,x,k,I,M,C,D,R,L,N,j,O,U,_;return P((function(P){switch(P.g){case 1:return i={width:1/0,height:1/0},function(e,t,n){e.variants=e.variants.filter((function(e){return ir(e,t,n)}))}(e,n.restrictions,i),w(P,rr(t,e,n.offline.usePersistentLicense,n.drm.preferredKeySystems,n.drm.keySystemsMapping),2);case 2:for(r=[],a=n.preferredDecodingAttributes,o=n.preferredVideoCodecs,s=n.preferredAudioCodecs,u=n.preferredTextFormats,nr(e,o,s,a,u),c=l(e.variants),d=c.next();!d.done;d=c.next())h=d.value,r.push(dr(h));for(f=l(e.textStreams),p=f.next();!p.done;p=f.next())g=p.value,r.push(hr(g));for(m=l(e.imageStreams),v=m.next();!v.done;v=m.next())y=v.value,r.push(fr(y));return w(P,n.offline.trackSelectionCallback(r),3);case 3:for(b=P.h,x=e.presentationTimeline.getDuration(),k=0,I=l(b),M=I.next();!M.done;M=I.next())C=M.value,D=C.bandwidth*x/8,k+=D;return S(P,4),w(P,n.offline.downloadSizeCallback(k),6);case 6:if(!P.h)throw new De(2,9,9014);A(P,5);break;case 4:if((R=E(P))instanceof De)throw R;throw new De(2,9,9015);case 5:for(L=new Set,N=new Set,j=new Set,O=l(b),U=O.next();!U.done;U=O.next())"variant"==(_=U.value).type&&L.add(_.id),"text"==_.type&&N.add(_.id),"image"==_.type&&j.add(_.id);e.variants=e.variants.filter((function(e){return L.has(e.id)})),e.textStreams=e.textStreams.filter((function(e){return N.has(e.id)})),e.imageStreams=e.imageStreams.filter((function(e){return j.has(e.id)})),function(e){e.variants.map((function(e){return e.video}));var t=new Set(e.variants.map((function(e){return e.audio})));e=e.textStreams;for(var n=l(t),i=n.next();!i.done;i=n.next())for(var r=(i=l(t)).next();!r.done;r=i.next());for(n=(t=l(e)).next();!n.done;n=t.next())for(i=(n=l(e)).next();!i.done;i=n.next());}(e),T(P)}}))}(g,c,o),16);case 16:return w(_,d.init(),17);case 17:return zy(e),w(_,uy(d),18);case 18:return h=_.h,zy(e),R=function(e,t,n,i,r,a){var o=function(e,t,n){return{offlineUri:null,originalManifestUri:e,duration:t.presentationTimeline.getDuration(),size:0,expiration:1/0,tracks:t=Dy(t),appMetadata:n,isIncomplete:!1}}(n,t,i),s=r.offline.progressCallback;!function(e,t,n){e.m=function(e,t){o.size=t,s(o,e)},e.l=n}(a,0,(function(t,n){u&&r.offline.usePersistentLicense&&c==n&&Ba(e,"cenc",t)}));var u=By(t)&&!Fy(t),c=null;u&&(c=$y.get(e.g.keySystem));for(var d=new Ry,h=l(t.textStreams),f=h.next();!f.done;f=h.next())d.g[f.value.id]=52;for(f=(h=l(t.imageStreams)).next();!f.done;f=h.next())Ly(d,f.value);for(f=(h=l(t.variants)).next();!f.done;f=h.next())Py(d,f.value);return d=function(e,t,n,i){for(var r=new Map,a=Jy(n),o=new Map,s=(a=l(a)).next();!s.done;s=a.next()){var u=qy(e,t,n,s=s.value,i,r);o.set(s.id,u)}for(t=(e=l(n.variants)).next();!t.done;t=e.next())(t=t.value).audio&&o.get(t.audio.id).variantIds.push(t.id),t.video&&o.get(t.video.id).variantIds.push(t.id);return{streams:Array.from(o.values()),ag:Array.from(r.values())}}(a,d,t,r),a=d.streams,d=d.ag,h=e.g,f=r.offline.usePersistentLicense,h&&f&&(h.initData=[]),{xi:{creationTime:Date.now(),originalManifestUri:n,duration:t.presentationTimeline.getDuration(),size:0,expiration:e.gd(),streams:a,sessionIds:f?Fa(e):[],drmInfo:h,appMetadata:i,isIncomplete:!0,sequenceMode:t.sequenceMode,type:t.type},ag:d}}(c,g,t,n,o,s),L=R.xi,N=R.ag,w(_,h.Ma.addManifests([L]),19);case 19:if(j=_.h,zy(e),f=j[0],zy(e),p)throw p;return w(_,function(e,t,n,i,r,a,o,s,u){var c,d,h,f,p,g,m,v,y,b;return P((function(x){switch(x.g){case 1:if(c={},d=0,h=function(t,h){var f,p,g,m,v,y,b;return P((function(S){if(1==S.g){for(f=l(t),p=f.next(),g={};!p.done;g={Jc:void 0},p=f.next())g.Jc=p.value,m=Xv(g.Jc,a),v=g.Jc.i,y=g.Jc.h,b=function(t){return function(n){var i,r,a;return P((function(s){if(1==s.g)return w(s,o.addSegments([{data:n}]),2);i=s.h,zy(e),r=t.Jc.g,a=Kv(r),c[a]=i[0],d+=n.byteLength,T(s)}))}}(g),Jv(r,g.Jc.groupId,m,v,y,b);return w(S,function(e){return P((function(t){return 1==t.g?w(t,Promise.all(e.j.values()),2):t.return(e.g.h)}))}(r),2)}return h?(zy(e),Vy(s,i,u,a),w(S,o.updateManifest(n,i),0)):S.u(0)}))},f=!1,S(x,2),!By(s)||!f||Fy(s)){x.u(4);break}return w(x,h(t.filter((function(e){return e.h})),!0),5);case 5:return zy(e),t=t.filter((function(e){return!e.h})),p=c,g=d,c={},d=0,w(x,_y(o,n,i,p,g,(function(){return zy(e)})),6);case 6:zy(e);case 4:if(f){x.u(7);break}return w(x,h(t,!1),8);case 8:return zy(e),m=c,v=d,c={},d=0,w(x,_y(o,n,i,m,v,(function(){return zy(e)})),9);case 9:zy(e);case 7:A(x,0);break;case 2:return y=E(x),b=Object.values(c),w(x,o.removeSegments(b,(function(){})),10);case 10:throw y}}))}(e,N,f,L,s,o,h.Ma,g,c),20);case 20:return zy(e),Vy(g,L,c,o),w(_,h.Ma.updateManifest(f,L),21);case 21:return zy(e),O=new by("manifest",h.path.rb,h.path.Ma,f),_.return(Cy(O,L));case 3:return k(_),w(_,d.destroy(),22);case 22:if(!u){_.u(23);break}return w(_,u.stop(),23);case 23:if(!c){_.u(25);break}return w(_,c.destroy(),25);case 25:I(_,0);break;case 2:if(U=E(_),null==f){_.u(27);break}return w(_,Uy(f),27);case 27:throw p||U}}))}(this,e,t||{},i||[],r||[],(function(){var t;return P((function(i){return 1==i.g?n?i.u(2):w(i,Al(e,a.g,o.manifest.retryParameters),3):(2!=i.g&&(n=i.h),t=lo(e,n||null),i.return(t()))}))}),o,s),(t=new Kr(t,(function(){return Yv(s)}))).finally((function(){Ie(a.j,s)})),function(e,t){var n=t.promise;return e.i.push(n),t.finally((function(){Ie(e.i,n)}))}(this,t)},i.remove=function(e){return Yy(this,function(e,t){var n,i,r,a,o,s;return P((function(u){switch(u.g){case 1:if(Wy(),null==(n=wy(t))||"manifest"!=n.g)throw new De(2,9,9004,t);return i=n,r=new sy,x(u,2),w(u,r.init(),4);case 4:return w(u,ly(r,i.rb(),i.Ma()),5);case 5:return w(u,(a=u.h).getManifests([i.key()]),6);case 6:return o=u.h,s=o[0],w(u,Promise.all([Gy(e,s,r),Ky(a,i,s)]),2);case 2:return k(u),w(u,r.destroy(),8);case 8:I(u,0)}}))}(this,e))},i.Pi=function(){return Yy(this,function(e){var t,n,i,r,a,o,s,u,c,d;return P((function(h){switch(h.g){case 1:return Wy(),t=e.g,n=e.h.drm,i=new sy,r=!1,x(h,2),w(h,i.init(),4);case 4:a=[],function(e){e.g.forEach((function(e){var t;t=e.getEmeSessionCell(),a.push(t)}))}(i),o=l(a),s=o.next();case 5:if(s.done){h.u(2);break}return w(h,(u=s.value).getAll(),8);case 8:return c=h.h,w(h,Iy(n,t,c),9);case 9:return d=h.h,w(h,u.remove(d),10);case 10:d.length!=c.length&&(r=!0),s=o.next(),h.u(5);break;case 2:return k(h),w(h,i.destroy(),11);case 11:I(h,3);break;case 3:return h.return(!r)}}))}(this))},i.list=function(){return Yy(this,P((function(i){switch(i.g){case 1:return Wy(),e=[],t=new sy,x(i,2),w(i,t.init(),4);case 4:return n=Promise.resolve(),function(e,t){e.g.forEach((function(e,n){e.getCells().forEach((function(e,i){t({rb:n,Ma:i},e)}))}))}(t,(function(t,i){n=n.then((function(){return P((function(n){if(1==n.g)return w(n,i.getAllManifests(),2);n.h.forEach((function(n,i){n=Cy(new by("manifest",t.rb,t.Ma,i),n),e.push(n)})),T(n)}))}))})),w(i,n,2);case 2:return k(i),w(i,t.destroy(),6);case 6:I(i,3);break;case 3:return i.return(e)}})));var e,t,n},i.Gc=function(e,t,n){var i,r=this;return P((function(a){return 1==a.g?((i=new Na({Nb:r.g,onError:t,ee:function(){},onExpirationUpdated:function(){},onEvent:function(){}})).configure(n.drm),w(a,function(e,t,n){return e.ja=!0,e.B=new Map,e.O=n,Oa(e,t)}(i,e.variants,n.offline.usePersistentLicense),2)):3!=a.g?w(a,_a(i),3):a.return(i)}))},F("shaka.offline.Storage",jy),jy.deleteAll=function(){var e;return P((function(t){return 1==t.g?(e=new sy,x(t,2),w(t,function(e){var t,n;return P((function(i){return 1==i.g?(t=Array.from(e.g.values()),(n=0<t.length)||dy.forEach((function(e){(e=e())&&t.push(e)})),w(i,Promise.all(t.map((function(e){return e.erase()}))),2)):n?i.u(0):w(i,Promise.all(t.map((function(e){return e.destroy()}))),0)}))}(e),2)):5!=t.g?(k(t),w(t,e.destroy(),5)):I(t,0)}))},jy.prototype.list=jy.prototype.list,jy.prototype.removeEmeSessions=jy.prototype.Pi,jy.prototype.remove=jy.prototype.remove,jy.prototype.store=jy.prototype.store,jy.prototype.getNetworkingEngine=jy.prototype.Ab,jy.prototype.getConfiguration=jy.prototype.getConfiguration,jy.prototype.configure=jy.prototype.configure,jy.prototype.destroy=jy.prototype.destroy,jy.support=Oy;var $y=(new Map).set("org.w3.clearkey","1077efecc0b24d02ace33c1e52e2fb4b").set("com.widevine.alpha","edef8ba979d64acea3c827dcd51d21ed").set("com.microsoft.playready","9a04f07998404286ab92e65be0885f95").set("com.microsoft.playready.recommendation","9a04f07998404286ab92e65be0885f95").set("com.microsoft.playready.software","9a04f07998404286ab92e65be0885f95").set("com.microsoft.playready.hardware","9a04f07998404286ab92e65be0885f95");function Qy(){}function Zy(e,t){for(e={priority:t||0,callback:e},t=0;t<eb.length;t++)if(eb[t].priority<e.priority)return void eb.splice(t,0,e);eb.push(e)}ld.offline=Oy,F("shaka.polyfill",Qy),Qy.register=Zy,Qy.installAll=function(){for(var e=l(eb),t=e.next();!t.done;t=e.next()){t=t.value;try{t.callback()}catch(e){W("Error installing polyfill!",e)}}};var eb=[];function tb(){}function nb(){if(!Object.getOwnPropertyDescriptor(Element.prototype,"ariaHidden"))for(var e=l(["ariaHidden","ariaLabel","ariaPressed","ariaSelected"]),t=e.next();!t.done;t=e.next())ib(t.value)}function ib(e){var t="aria-"+e.toLowerCase().replace(/^aria/,"");Object.defineProperty(Element.prototype,e,{get:function(){return this.getAttribute(t)},set:function(e){null==e||null==e?this.removeAttribute(t):this.setAttribute(t,e)}})}function rb(){}function ab(){$e()||rt("Sky_STB")||mS()}function ob(){}function sb(){if(e.Document){var t=Element.prototype;t.requestFullscreen=t.requestFullscreen||t.mozRequestFullScreen||t.msRequestFullscreen||t.webkitRequestFullscreen,(t=Document.prototype).exitFullscreen=t.exitFullscreen||t.mozCancelFullScreen||t.msExitFullscreen||t.webkitCancelFullScreen,"fullscreenElement"in document||(Object.defineProperty(document,"fullscreenElement",{get:function(){return document.mozFullScreenElement||document.msFullscreenElement||document.webkitCurrentFullScreenElement||document.webkitFullscreenElement}}),Object.defineProperty(document,"fullscreenEnabled",{get:function(){return document.mozFullScreenEnabled||document.msFullscreenEnabled||document.webkitFullscreenEnabled}})),document.addEventListener("webkitfullscreenchange",ub),document.addEventListener("webkitfullscreenerror",ub),document.addEventListener("mozfullscreenchange",ub),document.addEventListener("mozfullscreenerror",ub),document.addEventListener("MSFullscreenChange",ub),document.addEventListener("MSFullscreenError",ub)}}function ub(e){var t=e.type.replace(/^(webkit|moz|MS)/,"").toLowerCase(),n=document.createEvent("Event");n.initEvent(t,e.bubbles,e.cancelable),e.target.dispatchEvent(n)}function lb(){}function cb(){var e=!0;!ze()||ze()&&nt()||ze()&&rt("Fuchsia")||(e=!1),(Ye()||Je()||$e()||qe()||Ke()||rt("PC=EOS")||Qe()||rt("WPE"))&&(e=!1),e&&navigator.mediaCapabilities||(navigator.mediaCapabilities||(navigator.mediaCapabilities={}),hb=navigator.mediaCapabilities,navigator.mediaCapabilities.decodingInfo=db)}function db(t){var n,i,r,a,o;return P((function(s){switch(s.g){case 1:if(n={supported:!1,powerEfficient:!0,smooth:!0,keySystemAccess:null,configuration:t},i=t.video,r=t.audio,"media-source"!=t.type){if("file"!=t.type)return s.return(n);if(i&&!Ve(i.contentType)||r&&!Ve(r.contentType))return s.return(n);s.u(2);break}if(!Fe())return s.return(n);if(!i){s.u(3);break}return w(s,function(t){var n,i;return P((function(r){return 1==r.g?ze()?w(r,function(t){var n,i,r;return P((function(a){if(1==a.g){if(!(e.cast&&cast.__platform__&&cast.__platform__.canDisplayType))return a.return(ne(t.contentType));switch(n=t.contentType,t.width&&t.height&&(1280<t.width||720<t.height)&&(n+="; width="+t.width+"; height="+t.height),t.framerate&&(24>(i=Math.round(t.framerate))||30<i)&&(n+="; framerate="+t.framerate),t.transferFunction||""){case"":case"srgb":break;case"pq":n+="; eotf=smpte2084";break;case"hlg":n+="; eotf=arib-std-b67";break;default:return a.return(!1)}return r=!1,n in bb?(r=bb[n],a.u(2)):w(a,cast.__platform__.canDisplayType(n),3)}return 2!=a.g&&(r=a.h,bb[n]=r),a.return(r)}))}(t),3):Ke()?(n=t.contentType,t.width&&t.height&&(n+="; width="+t.width,n+="; height="+t.height),t.framerate&&(n+="; framerate="+t.framerate),t.bitrate&&(n+="; bitrate="+t.bitrate),r.return(ne(n))):r.u(2):2!=r.g?(i=r.h,r.return(i)):r.return(ne(t.contentType))}))}(i),4);case 4:if(!s.h)return s.return(n);case 3:if(r){var u=r.contentType;if(ze()&&r.spatialRendering&&(u+="; spatialRendering=true"),!ne(u))return s.return(n)}case 2:return t.keySystemConfiguration?(a=t.keySystemConfiguration,w(s,function(e,t,n){var i,r,a,o,s,u,l,c,d,h,f;return P((function(p){switch(p.g){case 1:if(i=[],r=[],n.audio&&(a={robustness:n.audio.robustness||"",contentType:t.contentType},Ke()&&t.contentType.includes('codecs="ac-3"')&&(a.contentType='audio/mp4; codecs="ec-3"'),n.audio.encryptionScheme&&(a.encryptionScheme=n.audio.encryptionScheme),i.push(a)),n.video&&(o={robustness:n.video.robustness||"",contentType:e.contentType},n.video.encryptionScheme&&(o.encryptionScheme=n.video.encryptionScheme),r.push(o)),s={initDataTypes:[n.initDataType],distinctiveIdentifier:n.distinctiveIdentifier,persistentState:n.persistentState,sessionTypes:n.sessionTypes},i.length&&(s.audioCapabilities=i),r.length&&(s.videoCapabilities=r),u=e?e.contentType:"",l=t?t.contentType:"",c=Di(u)+";"+Ci(u),d=Di(l)+";"+Ci(l),h=n.keySystem,f=null,S(p,2),Ue.has(c+"#"+d+"#"+h)){f=Ue.get(c+"#"+d+"#"+h)||null,p.u(4);break}return w(p,navigator.requestMediaKeySystemAccess(n.keySystem,[s]),5);case 5:f=p.h,Ue.set(c+"#"+d+"#"+h,f);case 4:A(p,3);break;case 2:E(p);case 3:return p.return(f)}}))}(i,r,a),6)):(n.supported=!0,s.return(n));case 6:(o=s.h)&&(n.supported=!0,n.keySystemAccess=o);case 5:return s.return(n)}}))}Qy.Aria=tb,tb.install=nb,Zy(nb),Qy.EncryptionScheme=rb,rb.install=ab,Zy(ab,-2),Qy.Fullscreen=ob,ob.install=sb,Zy(sb),Qy.MediaCapabilities=lb,lb.install=cb;var hb=null;lb.originalMcap=hb;var fb,pb,gb,mb,vb,yb,bb={};function wb(){}function Tb(){var t=et();(e.MediaSource||e.ManagedMediaSource)&&(t&&e.MediaSource?10>=t?e.MediaSource=null:12>=t?(Sb(),xb()):15>=t&&Sb():rt("DT_STB_BCM")?(Sb(),xb()):rt("Tizen 2")||Xe()||rt("Tizen 4")?function(){var t=MediaSource.isTypeSupported.bind(MediaSource);if(MediaSource.isTypeSupported=function(e){return"opus"!=Ci(e)&&t(e)},e.ManagedMediaSource){var n=ManagedMediaSource.isTypeSupported.bind(ManagedMediaSource);e.ManagedMediaSource.isTypeSupported=function(e){return"opus"!=Ci(e)&&n(e)}}}():rt("WPE")&&(Sb(),xb())),(e.MediaSource||e.ManagedMediaSource)&&function(){if(e.MediaSource){var t=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(e){return"mp2t"!=Ii(e)&&t(e)}}if(e.ManagedMediaSource){var n=ManagedMediaSource.isTypeSupported.bind(ManagedMediaSource);e.ManagedMediaSource.isTypeSupported=function(e){return"mp2t"!=Ii(e)&&n(e)}}}(),e.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&function(){var e=MediaSource.isTypeSupported;qe()||(MediaSource.isTypeSupported=function(t){var n=t.split(/ *; */),i=n.findIndex((function(e){return e.startsWith("codecs=")}));if(0>i)return e(t);var r=n[i].replace("codecs=","").replace(/"/g,"").split(/\s*,\s*/),a=r.findIndex((function(e){return e.startsWith("vp09")}));return 0<=a&&(r[a]="vp9",n[i]='codecs="'+r.join(",")+'"',t=n.join("; ")),e(t)})}()}function Sb(){var e=MediaSource.prototype.addSourceBuffer;MediaSource.prototype.addSourceBuffer=function(){var t=e.apply(this,L.apply(0,arguments));return t.abort=function(){},t}}function xb(){var e=SourceBuffer.prototype.remove;SourceBuffer.prototype.remove=function(t,n){return e.call(this,t,n-.001)}}function Ab(){}function Eb(){screen.orientation&&screen.orientation.unlock||(null!=screen.orientation?(void 0===screen.orientation.lock&&(screen.orientation.lock=function(){return Promise.resolve()}),void 0===screen.orientation.unlock&&(screen.orientation.unlock=function(){})):null!=e.orientation&&function(){function t(){switch(e.orientation){case-90:n.type="landscape-secondary",n.angle=270;break;case 0:n.type="portrait-primary",n.angle=0;break;case 90:n.type="landscape-primary",n.angle=90;break;case 180:n.type="portrait-secondary",n.angle=180}}var n=new kb;screen.orientation=n,t(),e.addEventListener("orientationchange",(function(){t();var e=new Jr("change");n.dispatchEvent(e)}))}())}function kb(){Zr.call(this),this.type="",this.angle=0}function Ib(){}function Mb(e,t){try{var n=new Rb(e,t);return Promise.resolve(n)}catch(e){return Promise.reject(e)}}function Cb(e){var t=this.mediaKeys;return t&&t!=e&&Lb(t,null),delete this.mediaKeys,(this.mediaKeys=e)?Lb(e,this):Promise.resolve()}function Db(e){if(ve(e=ge(e.initData)).getUint32(0,!0)+4!=e.byteLength)throw new RangeError("Malformed FairPlay init data");e=pt(e=ht(e.subarray(4),!0));var t=new Event("encrypted");t.initDataType="skd",t.initData=pe(e),this.dispatchEvent(t)}function Rb(e,t){if(this.keySystem=e,e.startsWith("com.apple.fps"))for(t=(e=l(t)).next();!t.done;t=e.next()){var n=t.value;if("required"==n.persistentState)t=null;else{t={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:n.initDataTypes,sessionTypes:["temporary"],label:n.label};var i=!1,r=!1;if(n.audioCapabilities)for(var a=l(n.audioCapabilities),o=a.next();!o.done;o=a.next())(o=o.value).contentType&&(i=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,o.contentType.split(";")[0])&&(t.audioCapabilities.push(o),r=!0));if(n.videoCapabilities)for(a=(n=l(n.videoCapabilities)).next();!a.done;a=n.next())(a=a.value).contentType&&(i=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,a.contentType.split(";")[0])&&(t.videoCapabilities.push(a),r=!0));i||(r=WebKitMediaKeys.isTypeSupported(this.keySystem,"video/mp4")),t=r?t:null}if(t)return void(this.g=t)}throw(e=Error("Unsupported keySystem")).name="NotSupportedError",e.code=DOMException.NOT_SUPPORTED_ERR,e}function Pb(e){this.h=new WebKitMediaKeys(e),this.g=new Z}function Lb(e,t){if(e.g.Va(),!t)return Promise.resolve();e.g.D(t,"webkitneedkey",Db);try{return Bs(t,HTMLMediaElement.HAVE_METADATA,e.g,(function(){t.webkitSetMediaKeys(e.h)})),Promise.resolve()}catch(e){return Promise.reject(e)}}function Nb(e){Zr.call(this),this.i=null,this.l=e,this.g=this.h=null,this.j=new Z,this.sessionId="",this.expiration=NaN,this.closed=new Gr,this.keyStatuses=new Ob}function jb(e,t){var n=e.keyStatuses;n.size=null==t?0:1,n.g=t,t=new Jr("keystatuseschange"),e.dispatchEvent(t)}function Ob(){this.size=0,this.g=void 0}lb.memoizedCanDisplayTypeRequests_=bb,Zy(cb,-1),Qy.MediaSource=wb,wb.install=Tb,Zy(Tb),Qy.Orientation=Ab,Ab.install=Eb,m(kb,Zr),kb.prototype.lock=function(e){function t(e){return screen.lockOrientation?screen.lockOrientation(e):screen.mozLockOrientation?screen.mozLockOrientation(e):!!screen.msLockOrientation&&screen.msLockOrientation(e)}var n=!1;switch(e){case"natural":n=t("default");break;case"any":n=!0,this.unlock();break;default:n=t(e)}return n?Promise.resolve():((e=Error("screen.orientation.lock() is not available on this device")).name="NotSupportedError",e.code=DOMException.NOT_SUPPORTED_ERR,Promise.reject(e))},kb.prototype.unlock=function(){screen.unlockOrientation?screen.unlockOrientation():screen.mozUnlockOrientation?screen.mozUnlockOrientation():screen.msUnlockOrientation&&screen.msUnlockOrientation()},Zy(Eb),Qy.PatchedMediaKeysApple=Ib,Ib.uninstall=function(){fb&&(fb=!1,Object.defineProperty(HTMLMediaElement.prototype,"mediaKeys",pb),HTMLMediaElement.prototype.setMediaKeys=gb,e.MediaKeys=mb,e.MediaKeySystemAccess=vb,navigator.requestMediaKeySystemAccess=yb,pb=yb=gb=vb=mb=null,e.shakaMediaKeysPolyfill="")},Ib.install=function(t){e.HTMLVideoElement&&e.WebKitMediaKeys&&(void 0!==t&&t&&(fb=!0,pb=Object.getOwnPropertyDescriptor(HTMLMediaElement.prototype,"mediaKeys"),gb=HTMLMediaElement.prototype.setMediaKeys,mb=e.MediaKeys,vb=e.MediaKeySystemAccess,yb=navigator.requestMediaKeySystemAccess),delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=Cb,e.MediaKeys=Pb,e.MediaKeySystemAccess=Rb,navigator.requestMediaKeySystemAccess=Mb,e.shakaMediaKeysPolyfill=Ub)},Rb.prototype.createMediaKeys=function(){var e=new Pb(this.keySystem);return Promise.resolve(e)},Rb.prototype.getConfiguration=function(){return this.g},Pb.prototype.createSession=function(e){if("temporary"!=(e=e||"temporary"))throw new TypeError("Session type "+e+" is unsupported on this platform.");return new Nb(this.h,e)},Pb.prototype.setServerCertificate=function(){return Promise.resolve(!1)},Pb.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")},m(Nb,Zr),(i=Nb.prototype).generateRequest=function(e,t){var n=this;this.h=new Gr;try{var i=this.l.createSession("video/mp4",ge(t));this.i=i,this.sessionId=i.sessionId||"",this.j.D(this.i,"webkitkeymessage",(function(e){n.h&&(n.h.resolve(),n.h=null),e=new Jr("message",e=(new Map).set("messageType",null==n.keyStatuses.$b()?"license-request":"license-renewal").set("message",pe(e.message))),n.dispatchEvent(e)})),this.j.D(i,"webkitkeyadded",(function(){n.g&&(jb(n,"usable"),n.g.resolve(),n.g=null)})),this.j.D(i,"webkitkeyerror",(function(){var e=Error("EME PatchedMediaKeysApple key error");if(e.errorCode=n.i.error,null!=n.h)n.h.reject(e),n.h=null;else if(null!=n.g)n.g.reject(e),n.g=null;else switch(n.i.error.code){case WebKitMediaKeyError.MEDIA_KEYERR_OUTPUT:case WebKitMediaKeyError.MEDIA_KEYERR_HARDWARECHANGE:jb(n,"output-not-allowed");break;default:jb(n,"internal-error")}})),jb(this,"status-pending")}catch(e){this.h.reject(e)}return this.h},i.load=function(){return Promise.reject(Error("MediaKeySession.load not yet supported"))},i.update=function(e){this.g=new Gr;try{this.i.update(ge(e))}catch(e){this.g.reject(e)}return this.g},i.close=function(){try{this.i.close(),this.closed.resolve(),this.j.Va()}catch(e){this.closed.reject(e)}return this.closed},i.remove=function(){return Promise.reject(Error("MediaKeySession.remove is only applicable for persistent licenses, which are not supported on this platform"))},(i=Ob.prototype).$b=function(){return this.g},i.forEach=function(e){this.g&&e(this.g,Oe.value())},i.get=function(e){if(this.has(e))return this.g},i.has=function(e){var t=Oe.value();return!(!this.g||!fe(e,t))},i.entries=function(){},i.keys=function(){},i.values=function(){};var Ub="apple";function _b(){}function Bb(){e.MediaKeys&&(!MediaKeys.prototype.setServerCertificate||Xe()||rt("Tizen 4")||rt("Tizen 5.0")||qe()&&38===We())&&(MediaKeys.prototype.setServerCertificate=Fb)}function Fb(){return Promise.resolve(!1)}function Vb(){}function Hb(){!e.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=Gb,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=Kb,e.MediaKeys=Xb,e.MediaKeySystemAccess=qb,e.shakaMediaKeysPolyfill=zb)}function Gb(){return Promise.reject(Error("The key system specified is not supported."))}function Kb(e){return null==e?Promise.resolve():Promise.reject(Error("MediaKeys not supported."))}function Xb(){throw new TypeError("Illegal constructor.")}function qb(){throw this.keySystem="",new TypeError("Illegal constructor.")}Qy.PatchedMediaKeysCert=_b,_b.install=Bb,Zy(Bb),Qy.PatchedMediaKeysNop=Vb,Vb.install=Hb,Xb.prototype.createSession=function(){},Xb.prototype.setServerCertificate=function(){},Xb.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")},qb.prototype.getConfiguration=function(){},qb.prototype.createMediaKeys=function(){};var zb="nop";function Wb(){}function Yb(){if(!(!e.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration)){if(HTMLMediaElement.prototype.webkitGenerateKeyRequest)uw="webkit";else if(!HTMLMediaElement.prototype.generateKeyRequest)return;navigator.requestMediaKeySystemAccess=$b,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=Qb,e.MediaKeys=ew,e.MediaKeySystemAccess=Zb,e.shakaMediaKeysPolyfill=lw}}function Jb(e){return uw?uw+e.charAt(0).toUpperCase()+e.slice(1):e}function $b(e,t){try{var n=new Zb(e,t);return Promise.resolve(n)}catch(e){return Promise.reject(e)}}function Qb(e){var t=this.mediaKeys;return t&&t!=e&&tw(t,null),delete this.mediaKeys,(this.mediaKeys=e)&&tw(e,this),Promise.resolve()}function Zb(e,t){this.g=this.keySystem=e;var n=!1;"org.w3.clearkey"==e&&(this.g="webkit-org.w3.clearkey",n=!1);var i=!1,r=document.getElementsByTagName("video");r=r.length?r[0]:document.createElement("video");for(var a=(t=l(t)).next();!a.done;a=t.next()){var o={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:(a=a.value).initDataTypes,sessionTypes:["temporary"],label:a.label},s=!1;if(a.audioCapabilities)for(var u=l(a.audioCapabilities),c=u.next();!c.done;c=u.next())(c=c.value).contentType&&(s=!0,r.canPlayType(c.contentType.split(";")[0],this.g)&&(o.audioCapabilities.push(c),i=!0));if(a.videoCapabilities)for(c=(u=l(a.videoCapabilities)).next();!c.done;c=u.next())(c=c.value).contentType&&(s=!0,r.canPlayType(c.contentType,this.g)&&(o.videoCapabilities.push(c),i=!0));if(s||(i=r.canPlayType("video/mp4",this.g)||r.canPlayType("video/webm",this.g)),"required"==a.persistentState&&(n?(o.persistentState="required",o.sessionTypes=["persistent-license"]):i=!1),i)return void(this.h=o)}throw n="Unsupported keySystem","org.w3.clearkey"!=e&&"com.widevine.alpha"!=e||(n="None of the requested configurations were supported."),(e=Error(n)).name="NotSupportedError",e.code=DOMException.NOT_SUPPORTED_ERR,e}function ew(e){this.l=e,this.h=null,this.g=new Z,this.i=[],this.j=new Map}function tw(e,t){e.h=t,e.g.Va();var n=uw;t&&(e.g.D(t,n+"needkey",(function(t){var n=new CustomEvent("encrypted");n.initDataType="cenc",n.initData=pe(t.initData),e.h.dispatchEvent(n)})),e.g.D(t,n+"keymessage",(function(t){var n=nw(e,t.sessionId);n&&(t=new Jr("message",t=(new Map).set("messageType",null==n.keyStatuses.$b()?"licenserequest":"licenserenewal").set("message",t.message)),n.h&&(n.h.resolve(),n.h=null),n.dispatchEvent(t))})),e.g.D(t,n+"keyadded",(function(t){(t=nw(e,t.sessionId))&&t.ready()})),e.g.D(t,n+"keyerror",(function(t){var n=nw(e,t.sessionId);if(n){var i=Error("EME v0.1b key error"),r=t.errorCode;r.systemCode=t.systemCode,i.errorCode=r,!t.sessionId&&n.h?(45==t.systemCode&&(i.message="Unsupported session type."),n.h.reject(i),n.h=null):t.sessionId&&n.g?(n.g.reject(i),n.g=null):(i=t.systemCode,t.errorCode.code==MediaKeyError.MEDIA_KEYERR_OUTPUT?ow(n,"output-restricted"):ow(n,1==i?"expired":"internal-error"))}})))}function nw(e,t){var n=e.j.get(t);return n||((n=e.i.shift())?(n.sessionId=t,e.j.set(t,n),n):null)}function iw(e,t,n){Zr.call(this),this.j=e,this.m=!1,this.g=this.h=null,this.i=t,this.l=n,this.sessionId="",this.expiration=NaN,this.closed=new Gr,this.keyStatuses=new sw}function rw(e,t,n){if(e.m)return Promise.reject(Error("The session is already initialized."));e.m=!0;try{if("persistent-license"==e.l)if(n)var i=ge(pt("LOAD_SESSION|"+n));else{var r=pt("PERSISTENT|");i=di(r,t)}else i=ge(t)}catch(e){return Promise.reject(e)}e.h=new Gr;var a=Jb("generateKeyRequest");try{e.j[a](e.i,i)}catch(t){if("InvalidStateError"!=t.name)return e.h=null,Promise.reject(t);new Be((function(){try{e.j[a](e.i,i)}catch(t){e.h.reject(t),e.h=null}})).$(.01)}return e.h}function aw(e,t,n){if(e.g)e.g.then((function(){return aw(e,t,n)})).catch((function(){return aw(e,t,n)}));else{if(e.g=t,"webkit-org.w3.clearkey"==e.i){var i=dt(n),r=JSON.parse(i);"oct"!=r.keys[0].kty&&(e.g.reject(Error("Response is not a valid JSON Web Key Set.")),e.g=null),i=ui(r.keys[0].k),r=ui(r.keys[0].kid)}else i=ge(n),r=null;var a=Jb("addKey");try{e.j[a](e.i,i,r,e.sessionId)}catch(t){e.g.reject(t),e.g=null}}}function ow(e,t){var n=e.keyStatuses;n.size=null==t?0:1,n.g=t,t=new Jr("keystatuseschange"),e.dispatchEvent(t)}function sw(){this.size=0,this.g=void 0}Zy(Hb,-10),Qy.PatchedMediaKeysWebkit=Wb,Wb.install=Yb,Zb.prototype.createMediaKeys=function(){var e=new ew(this.g);return Promise.resolve(e)},Zb.prototype.getConfiguration=function(){return this.h},ew.prototype.createSession=function(e){if("temporary"!=(e=e||"temporary")&&"persistent-license"!=e)throw new TypeError("Session type "+e+" is unsupported on this platform.");var t=this.h||document.createElement("video");return t.src||(t.src="about:blank"),e=new iw(t,this.l,e),this.i.push(e),e},ew.prototype.setServerCertificate=function(){return Promise.resolve(!1)},ew.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")},m(iw,Zr),(i=iw.prototype).ready=function(){ow(this,"usable"),this.g&&this.g.resolve(),this.g=null},i.generateRequest=function(e,t){return rw(this,t,null)},i.load=function(e){return"persistent-license"==this.l?rw(this,null,e):Promise.reject(Error("Not a persistent session."))},i.update=function(e){var t=new Gr;return aw(this,t,e),t},i.close=function(){if("persistent-license"!=this.l){if(!this.sessionId)return this.closed.reject(Error("The session is not callable.")),this.closed;var e=Jb("cancelKeyRequest");try{this.j[e](this.i,this.sessionId)}catch(e){}}return this.closed.resolve(),this.closed},i.remove=function(){return"persistent-license"!=this.l?Promise.reject(Error("Not a persistent session.")):this.close()},(i=sw.prototype).$b=function(){return this.g},i.forEach=function(e){this.g&&e(this.g,Oe.value())},i.get=function(e){if(this.has(e))return this.g},i.has=function(e){var t=Oe.value();return!(!this.g||!fe(e,t))},i.entries=function(){},i.keys=function(){},i.values=function(){};var uw="",lw="webkit";function cw(){}function dw(){if(e.HTMLVideoElement){var t=HTMLVideoElement.prototype;t.requestPictureInPicture&&document.exitPictureInPicture||!t.webkitSupportsPresentationMode||(document.pictureInPictureEnabled=!0,document.pictureInPictureElement=null,t.requestPictureInPicture=fw,Object.defineProperty(t,"disablePictureInPicture",{get:gw,set:mw,enumerable:!0,configurable:!0}),document.exitPictureInPicture=pw,document.addEventListener("webkitpresentationmodechanged",hw,!0))}}function hw(e){if("picture-in-picture"==(e=e.target).webkitPresentationMode){document.pictureInPictureElement=e;var t=new Event("enterpictureinpicture");e.dispatchEvent(t)}else document.pictureInPictureElement==e&&(document.pictureInPictureElement=null),t=new Event("leavepictureinpicture"),e.dispatchEvent(t)}function fw(){return this.webkitSupportsPresentationMode("picture-in-picture")?(this.webkitSetPresentationMode("picture-in-picture"),document.pictureInPictureElement=this,Promise.resolve()):Promise.reject(Error("PiP not allowed by video element"))}function pw(){var e=document.pictureInPictureElement;return e?(e.webkitSetPresentationMode("inline"),document.pictureInPictureElement=null,Promise.resolve()):Promise.reject(Error("No picture in picture element found"))}function gw(){return!!this.hasAttribute("disablePictureInPicture")||!this.webkitSupportsPresentationMode("picture-in-picture")}function mw(e){e?this.setAttribute("disablePictureInPicture",""):this.removeAttribute("disablePictureInPicture")}function vw(){}function yw(){e.crypto&&("randomUUID"in e.crypto||(e.crypto.randomUUID=bw))}function bw(){var e=URL.createObjectURL(new Blob),t=e.toString();return URL.revokeObjectURL(e),t.substr(t.lastIndexOf("/")+1)}function ww(){}function Tw(){var e=Symbol.prototype;"description"in e||Object.defineProperty(e,"description",{get:Sw})}function Sw(){var e=/\((.*)\)/.exec(this.toString());return e?e[1]:void 0}function xw(){}function Aw(){if(e.HTMLMediaElement){var t=HTMLMediaElement.prototype.play;HTMLMediaElement.prototype.play=function(){var e=t.apply(this);return e&&e.catch((function(){})),e}}}function Ew(){}function kw(){if(e.HTMLVideoElement){var t=HTMLVideoElement.prototype;!t.getVideoPlaybackQuality&&("webkitDroppedFrameCount"in t||qe()&&38===We())&&(t.getVideoPlaybackQuality=Iw)}}function Iw(){return{droppedVideoFrames:this.webkitDroppedFrameCount,totalVideoFrames:this.webkitDecodedFrameCount,corruptedVideoFrames:0,creationTime:NaN,totalFrameDelay:0}}function Mw(){}function Cw(){if(!e.VTTCue&&e.TextTrackCue){var t=null,n=TextTrackCue.length;if(3==n)t=Dw;else if(6==n)t=Rw;else{try{var i=!!Dw(1,2,"")}catch(e){i=!1}i&&(t=Dw)}t&&(e.VTTCue=function(e,n,i){return t(e,n,i)})}}function Dw(t,n,i){return new e.TextTrackCue(t,n,i)}function Rw(t,n,i){return new e.TextTrackCue(t+"-"+n+"-"+i,t,n,i)}function Pw(){}Zy(Yb),Qy.PiPWebkit=cw,cw.install=dw,Zy(dw),Qy.RandomUUID=vw,vw.install=yw,Zy(yw),Qy.Symbol=ww,ww.install=Tw,Zy(Tw),Qy.VideoPlayPromise=xw,xw.install=Aw,Zy(Aw),Qy.VideoPlaybackQuality=Ew,Ew.install=kw,Zy(kw),Qy.VTTCue=Mw,Mw.install=Cw,Zy(Cw),Pw.prototype.parseInit=function(){},Pw.prototype.setSequenceMode=function(){},Pw.prototype.setManifestType=function(){},Pw.prototype.parseMedia=function(e,t){for(var n=null,i=[],r=(e=l(e=dt(e).split(/\r?\n/))).next();!r.done;r=e.next())if((r=r.value)&&!/^\s+$/.test(r)&&(r=Lw.exec(r))){var a=Nw.exec(r[1]);r=new un(a=60*parseInt(a[1],10)+parseFloat(a[2].replace(",",".")),t.segmentEnd?t.segmentEnd:a+2,r[2]),n&&(n.endTime=a,i.push(n)),n=r}return n&&i.push(n),i},F("shaka.text.LrcTextParser",Pw),Pw.prototype.parseMedia=Pw.prototype.parseMedia,Pw.prototype.setManifestType=Pw.prototype.setManifestType,Pw.prototype.setSequenceMode=Pw.prototype.setSequenceMode,Pw.prototype.parseInit=Pw.prototype.parseInit;var Lw=/^\[(\d{1,2}:\d{1,2}(?:[.,]\d{1,3})?)\](.*)/,Nw=/^(\d+):(\d{1,2}(?:[.,]\d{1,3})?)$/;function jw(){}function Ow(e,t,n,i,r,a,o,s,u,c,d,h,f){var p=c;if(Pt(e)){if(!d)return null;var g={tagName:"span",children:[jt(e)],attributes:{},parent:null}}else g=e;for(var m=null,v=l(cT),y=v.next();!y.done&&!(m=Kw(g,"backgroundImage",i,"#",y.value)[0]);y=v.next());v=null;var b=/^(urn:)(mpeg:[a-z0-9][a-z0-9-]{0,31}:)(subs:)([0-9]+)$/;if((y=Gt(g,cT,"backgroundImage"))&&b.test(y)){if((v=parseInt(y.split(":").pop(),10)-1)>=f.length)return null;v=f[v]}else h&&y&&!y.startsWith("#")&&(b=new Gn(h),y=new Gn(y),(y=b.resolve(y).toString())&&(v=y));if(("p"==e.tagName||m||v)&&(d=!0),e=d,y="default"==(g.attributes["xml:space"]||(s?"default":"preserve")),s=[],!(b=g.children.every(Pt)))for(var w=l(g.children),T=w.next();!T.done;T=w.next())(T=Ow(T.value,t,n,i,r,a,o,y,u,g,d,h,f))&&s.push(T);if(i=null!=c,h=jt(g),h=g.children.length&&h&&/\S/.test(h),!((w=g.attributes.begin||g.attributes.end||g.attributes.dur)||h||"br"==g.tagName||0!=s.length||i&&!y))return null;for(h=(f=qw(g,n)).start,f=f.end;p&&p.tagName&&"tt"!=p.tagName;)h=(f=Xw(p,n,h,f)).start,f=f.end,p=p.parent;if(null==h&&(h=0),h+=t.periodStart,f=null==f?1/0:f+t.periodStart,h=Math.max(h,t.segmentStart),f=Math.min(f,t.segmentEnd),!w&&0<s.length)for(h=1/0,f=0,n=(t=l(s)).next();!n.done;n=t.next())n=n.value,h=Math.min(h,n.startTime),f=Math.max(f,n.endTime);if("br"==g.tagName)return(r=new un(h,f,"")).lineBreak=!0,r;if(t="",b&&(t=vt(jt(g)||""),y&&(t=t.replace(/\s+/g," "))),(t=new un(h,f,t)).nestedCues=s,d||(t.isContainer=!0),u&&(t.cellResolution=u),u=Kw(g,"region",a,"")[0],g.attributes.region&&u&&u.attributes["xml:id"]){var S=u.attributes["xml:id"];t.region=o.filter((function(e){return e.id==S}))[0]}return o=u,c&&i&&!g.attributes.region&&!g.attributes.style&&(o=Kw(c,"region",a,"")[0]),function(e,t,n,i,r,a,o,s){if("rtl"==Fw(t,n,a,"direction",o=o||s)&&(e.direction="rtl"),"tb"==(s=Fw(t,n,a,"writingMode",o))||"tblr"==s?e.writingMode="vertical-lr":"tbrl"==s?e.writingMode="vertical-rl":"rltb"==s||"rl"==s?e.direction="rtl":s&&(e.direction=wn),(s=Fw(t,n,a,"textAlign",!0))?(e.positionAlign=sT[s],e.lineAlign=oT[s],e.textAlign=vn[s.toUpperCase()]):e.textAlign=mn,(s=Fw(t,n,a,"displayAlign",!0))&&(e.displayAlign=bn[s.toUpperCase()]),(s=Fw(t,n,a,"color",o))&&(e.color=_w(s)),(s=Fw(t,n,a,"backgroundColor",o))&&(e.backgroundColor=_w(s)),(s=Fw(t,n,a,"border",o))&&(e.border=s),s=Fw(t,n,a,"fontFamily",o))switch(s){case"monospaceSerif":e.fontFamily="Courier New,Liberation Mono,Courier,monospace";break;case"proportionalSansSerif":e.fontFamily="Arial,Helvetica,Liberation Sans,sans-serif";break;case"sansSerif":e.fontFamily="sans-serif";break;case"monospaceSansSerif":e.fontFamily="Consolas,monospace";break;case"proportionalSerif":e.fontFamily="serif";break;default:e.fontFamily=s.split(",").filter((function(e){return"default"!=e})).join(",")}switch((s=Fw(t,n,a,"fontWeight",o))&&"bold"==s&&(e.fontWeight=Mn),s=Fw(t,n,a,"wrapOption",o),e.wrapLine=!s||"noWrap"!=s,(s=Fw(t,n,a,"lineHeight",o))&&s.match(Qw)&&(e.lineHeight=s),(s=Fw(t,n,a,"fontSize",o))&&(s.match(Qw)||s.match($w))&&(e.fontSize=s),(s=Fw(t,n,a,"fontStyle",o))&&(e.fontStyle=Rn[s.toUpperCase()]),i?(r=i.attributes.imageType||i.attributes.imagetype,s=i.attributes.encoding,i=jt(i).trim(),"PNG"==r&&"Base64"==s&&i&&(e.backgroundImage="data:image/png;base64,"+i)):r&&(e.backgroundImage=r),(i=Fw(t,n,a,"textOutline",o))&&((i=i.split(" "))[0].match(Qw)?e.textStrokeColor=e.color:(e.textStrokeColor=_w(i[0]),i.shift()),i[0]&&i[0].match(Qw)?e.textStrokeWidth=i[0]:e.textStrokeColor=""),(i=Fw(t,n,a,"letterSpacing",o))&&i.match(Qw)&&(e.letterSpacing=i),(i=Fw(t,n,a,"linePadding",o))&&i.match(Qw)&&(e.linePadding=i),(i=Fw(t,n,a,"opacity",o))&&(e.opacity=parseFloat(i)),(i=Vw(n,a,"textDecoration"))&&Bw(e,i),(i=Hw(t,a,"textDecoration"))&&Bw(e,i),(i=Fw(t,n,a,"textCombine",o))&&(e.textCombineUpright=i),Fw(t,n,a,"ruby",o)){case"container":e.rubyTag="ruby";break;case"text":e.rubyTag="rt"}}(t,g,o,m,v,r,e,0==s.length),t}function Uw(e,t,n){var i=new xe,r=e.attributes["xml:id"];if(!r)return null;i.id=r,r=null,n&&(r=Jw.exec(n)||Zw.exec(n)),n=r?Number(r[1]):null,r=r?Number(r[2]):null;var a,o=Vw(e,t,"extent");if(o){var s=(a=Jw.exec(o))||Zw.exec(o);null!=s&&(i.width=Number(s[1]),i.height=Number(s[2]),a||(null!=n&&(i.width=100*i.width/n),null!=r&&(i.height=100*i.height/r)),i.widthUnits=a||null!=n?Ae:0,i.heightUnits=a||null!=r?Ae:0)}return(e=Vw(e,t,"origin"))&&null!=(s=(a=Jw.exec(e))||Zw.exec(e))&&(i.viewportAnchorX=Number(s[1]),i.viewportAnchorY=Number(s[2]),a?o||(i.width=100-i.viewportAnchorX,i.widthUnits=Ae,i.height=100-i.viewportAnchorY,i.heightUnits=Ae):(null!=r&&(i.viewportAnchorY=100*i.viewportAnchorY/r),null!=n&&(i.viewportAnchorX=100*i.viewportAnchorX/n)),i.viewportAnchorUnits=a||null!=n?Ae:0),i}function _w(e){var t=e.match(/rgba\(([^)]+)\)/);return t&&4==(t=t[1].split(",")).length?(t[3]=String(Number(t[3])/255),"rgba("+t.join(",")+")"):e}function Bw(e,t){for(var n=(t=l(t.split(" "))).next();!n.done;n=t.next())switch(n.value){case"underline":e.textDecoration.includes(Pn)||e.textDecoration.push(Pn);break;case"noUnderline":e.textDecoration.includes(Pn)&&Ie(e.textDecoration,Pn);break;case"lineThrough":e.textDecoration.includes("lineThrough")||e.textDecoration.push("lineThrough");break;case"noLineThrough":e.textDecoration.includes("lineThrough")&&Ie(e.textDecoration,"lineThrough");break;case"overline":e.textDecoration.includes("overline")||e.textDecoration.push("overline");break;case"noOverline":e.textDecoration.includes("overline")&&Ie(e.textDecoration,"overline")}}function Fw(e,t,n,i,r){return r=void 0===r||r,(e=Hw(e,n,i))?e:r?Vw(t,n,i):null}function Vw(e,t,n){return e?Gt(e,lT,n)||Gw(e,t,n):null}function Hw(e,t,n){return Gt(e,lT,n)||Gw(e,t,n)}function Gw(e,t,n){e=Kw(e,"style",t,"");for(var i=null,r=0;r<e.length;r++){var a=Vt(e[r],"urn:ebu:tt:style",n);a||(a=Gt(e[r],lT,n)),a||(a=Hw(e[r],t,n)),a&&(i=a)}return i}function Kw(e,t,n,i,r){var a=[];if(!e||1>n.length)return a;var o=e;for(e=null;!e&&!(e=r?Vt(o,r,t):o.attributes[t])&&(o=o.parent););if(t=e)for(r=(t=l(t.split(" "))).next();!r.done;r=t.next())for(r=r.value,o=(e=l(n)).next();!o.done;o=e.next())if(i+(o=o.value).attributes["xml:id"]==r){a.push(o);break}return a}function Xw(e,t,n,i){return e=qw(e,t),null==n?n=e.start:null!=e.start&&(n+=e.start),null==i?i=e.end:null!=e.start&&(i+=e.start),{start:n,end:i}}function qw(e,t){var n=zw(e.attributes.begin,t),i=zw(e.attributes.end,t);return e=zw(e.attributes.dur,t),null==i&&null!=e&&(i=n+e),{start:n,end:i}}function zw(e,t){var n=null;if(eT.test(e)){e=eT.exec(e),n=Number(e[1]);var i=Number(e[2]),r=Number(e[3]),a=Number(e[4]);n=(r+=(a+=(Number(e[5])||0)/t.h)/t.frameRate)+60*i+3600*n}else if(tT.test(e))n=Ww(tT,e);else if(nT.test(e))n=Ww(nT,e);else if(iT.test(e))e=iT.exec(e),n=Number(e[1])/t.frameRate;else if(rT.test(e))e=rT.exec(e),n=Number(e[1])/t.g;else if(aT.test(e))n=Ww(aT,e);else if(e)throw new De(2,2,2001,"Could not parse cue time range in TTML");return n}function Ww(e,t){return null==(e=e.exec(t))||""==e[0]?null:(Number(e[4])||0)/1e3+(Number(e[3])||0)+60*(Number(e[2])||0)+3600*(Number(e[1])||0)}function Yw(e,t,n,i){this.frameRate=Number(e)||30,this.h=Number(t)||1,this.g=Number(i),0==this.g&&(this.g=e?this.frameRate*this.h:1),n&&(e=/^(\d+) (\d+)$/g.exec(n))&&(this.frameRate*=Number(e[1])/Number(e[2]))}Fi["application/x-subtitle-lrc"]=function(){return new Pw},jw.prototype.parseInit=function(){},jw.prototype.setSequenceMode=function(){},jw.prototype.setManifestType=function(){},jw.prototype.parseMedia=function(e,t,n,i){var r=dt(e);if(e=[],""==r)return e;var a=Dt(r,"tt",!0);if(!a)throw new De(2,2,2005,"Failed to parse TTML.");if(!(r=Ut(a,"body")[0]))return[];var o=Gt(a,uT,"frameRate"),s=Gt(a,uT,"subFrameRate"),u=Gt(a,uT,"frameRateMultiplier"),c=Gt(a,uT,"tickRate"),d=Gt(a,uT,"cellResolution"),h=a.attributes["xml:space"]||"default",f=Gt(a,lT,"extent");if("default"!=h&&"preserve"!=h)throw new De(2,2,2005,"Invalid xml:space value: "+h);h="default"==h,o=new Yw(o,s,u,c),d=function(e){return e&&(e=/^(\d+) (\d+)$/.exec(e))?{lc:parseInt(e[1],10),rows:parseInt(e[2],10)}:null}(d),s=((s=Ut(a,"metadata")[0])?s.children:[]).filter((function(e){return"\n"!=e})),u=Ut(a,"style"),c=[];for(var p=l(a=Ut(a,"region")),g=p.next();!g.done;g=p.next())(g=Uw(g.value,u,f))&&c.push(g);if(Nt(r,"p").length)throw new De(2,2,2001,"<p> can only be inside <div> in TTML");for(p=(f=l(Nt(r,"div"))).next();!p.done;p=f.next())if(Nt(p.value,"span").length)throw new De(2,2,2001,"<span> can only be inside <p> in TTML");return(t=Ow(r,t,o,s,u,a,c,h,d,null,!1,n,i))&&(t.backgroundColor||(t.backgroundColor="transparent"),e.push(t)),e},F("shaka.text.TtmlTextParser",jw),jw.prototype.parseMedia=jw.prototype.parseMedia,jw.prototype.setManifestType=jw.prototype.setManifestType,jw.prototype.setSequenceMode=jw.prototype.setSequenceMode,jw.prototype.parseInit=jw.prototype.parseInit;var Jw=/^(\d{1,2}(?:\.\d+)?|100(?:\.0+)?)% (\d{1,2}(?:\.\d+)?|100(?:\.0+)?)%$/,$w=/^(\d{1,4}(?:\.\d+)?|100)%$/,Qw=/^(\d+px|\d+em|\d*\.?\d+c)$/,Zw=/^(\d+)px (\d+)px$/,eT=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,tT=/^(?:(\d{2,}):)?(\d{2}):(\d{2})$/,nT=/^(?:(\d{2,}):)?(\d{2}):(\d{2}\.\d+)$/,iT=/^(\d*(?:\.\d*)?)f$/,rT=/^(\d*(?:\.\d*)?)t$/,aT=RegExp("^(?:(\\d*(?:\\.\\d*)?)h)?(?:(\\d*(?:\\.\\d*)?)m)?(?:(\\d*(?:\\.\\d*)?)s)?(?:(\\d*(?:\\.\\d*)?)ms)?$"),oT={left:xn,center:"center",right:"end",start:xn,end:"end"},sT={left:"line-left",center:"center",right:"line-right"},uT=["http://www.w3.org/ns/ttml#parameter","http://www.w3.org/2006/10/ttaf1#parameter"],lT=["http://www.w3.org/ns/ttml#styling","http://www.w3.org/2006/10/ttaf1#styling"],cT=["http://www.smpte-ra.org/schemas/2052-1/2010/smpte-tt","http://www.smpte-ra.org/schemas/2052-1/2013/smpte-tt"];function dT(){this.g=new jw}function hT(){this.g="UNKNOWN"}function fT(e,t,n){var i;(i=/^align:(start|middle|center|end|left|right)$/.exec(t))?(t=i[1],e.textAlign="middle"==t?mn:vn[t.toUpperCase()]):(i=/^vertical:(lr|rl)$/.exec(t))?e.writingMode="lr"==i[1]?"vertical-lr":"vertical-rl":(i=/^size:([\d.]+)%$/.exec(t))?e.size=Number(i[1]):(i=/^position:([\d.]+)%(?:,(line-left|line-right|middle|center|start|end|auto))?$/.exec(t))?(e.position=Number(i[1]),i[2]&&(t=i[2],e.positionAlign="line-left"==t||"start"==t?"line-left":"line-right"==t||"end"==t?"line-right":"center"==t||"middle"==t?"center":gn)):(i=/^region:(.*)$/.exec(t))?(t=function(e,t){return e=e.filter((function(e){return e.id==t})),e.length?e[0]:null}(n,i[1]))&&(e.region=t):(n=/^line:([\d.]+)%(?:,(start|end|center))?$/.exec(t))?(e.lineInterpretation=1,e.line=Number(n[1]),n[2]&&(e.lineAlign=An[n[2].toUpperCase()])):(n=/^line:(-?\d+)(?:,(start|end|center))?$/.exec(t))&&(e.lineInterpretation=Sn,e.line=Number(n[1]),n[2]&&(e.lineAlign=An[n[2].toUpperCase()]))}function pT(){this.g=null}function gT(e,t,n){var i,r,a;return(new Ta).box("payl",ka((function(e){i=dt(e)}))).box("iden",ka((function(e){r=dt(e)}))).box("sttg",ka((function(e){a=dt(e)}))).parse(e),i?function(e,t,n,i,r){if(dn(e=new un(i,r,e)),t&&(e.id=t),n)for(n=St(t=new bt(n));n;)fT(e,n,[]),wt(t),n=St(t);return e}(i,r,a,t,n):null}function mT(){}function vT(){this.g=new hT}function yT(e){var t="WEBVTT\n\n";if(""==e)return t;for(var n=(e=l((e=(e=e.replace(/\r+/g,"")).trim()).split("\n\n"))).next();!n.done;n=e.next())(n=n.value.split(/\n/))[0].match(/\d+/)&&n.shift(),n[0]=n[0].replace(/,/g,"."),t+=n.join("\n").replace(/{b}/g,"<b>").replace(/{\/b}/g,"</b>").replace(/{i}/g,"<i>").replace(/{\/i}/g,"</i>").replace(/{u}/g,"<u>").replace(/{\/u}/g,"</u>")+"\n\n";return t}function bT(){}function wT(e,t){var n=t.Fontname;if(n&&(e.fontFamily=n),(n=t.Fontsize)&&(e.fontSize=n+"px"),(n=t.PrimaryColour)&&(n=TT(n))&&(e.color=n),(n=t.BackColour)&&(n=TT(n))&&(e.backgroundColor=n),t.Bold&&(e.fontWeight=Mn),t.Italic&&(e.fontStyle=Dn),t.Underline&&e.textDecoration.push(Pn),(n=t.Spacing)&&(e.letterSpacing=n+"px"),n=t.Alignment)switch(parseInt(n,10)){case 1:e.displayAlign=yn,e.textAlign="start";break;case 2:e.displayAlign=yn,e.textAlign=mn;break;case 3:e.displayAlign=yn,e.textAlign="end";break;case 5:e.displayAlign="before",e.textAlign="start";break;case 6:e.displayAlign="before",e.textAlign=mn;break;case 7:e.displayAlign="before",e.textAlign="end";break;case 9:e.displayAlign="center",e.textAlign="start";break;case 10:e.displayAlign="center",e.textAlign=mn;break;case 11:e.displayAlign="center",e.textAlign="end"}(t=t.AlphaLevel)&&(e.opacity=parseFloat(t))}function TT(e){return 0<=(e=parseInt(e.replace("&H",""),16))?"rgba("+(255&e)+","+(e>>8&255)+","+(e>>16&255)+","+(e>>24&255^255)/255+")":null}function ST(e){return 3600*((e=kT.exec(e))[1]?parseInt(e[1].replace(":",""),10):0)+60*parseInt(e[2],10)+parseFloat(e[3])}Fi["application/ttml+xml"]=function(){return new jw},dT.prototype.parseInit=function(e){var t=!1;if((new Ta).box("moov",Sa).box("trak",Sa).box("mdia",Sa).box("minf",Sa).box("stbl",Sa).R("stsd",xa).box("stpp",(function(e){t=!0,e.parser.stop()})).parse(e),!t)throw new De(2,2,2007)},dT.prototype.setSequenceMode=function(){},dT.prototype.setManifestType=function(){},dT.prototype.parseMedia=function(e,t,n){var i=this,r=!1,a=[],o=[];if((new Ta).box("moof",Sa).box("traf",Sa).R("subs",(function(e){o=[];for(var t=e.reader,n=t.P(),i=0;i<n;i++){t.P();for(var r=t.ma(),a=0;a<r;a++)1==e.version?o.push(t.P()):o.push(t.ma()),t.T(),t.T(),t.P()}})).box("mdat",ka((function(e){if(r=!0,o.length){for(var s=ge(e,0,o[0]),u=[],l=o[0],c=1;c<o.length;c++){var d=ge(e,l,o[c]);d=oi(d),u.push("data:image/png;base64,"+d),l+=o[c]}a=a.concat(i.g.parseMedia(s,t,n,u))}else a=a.concat(i.g.parseMedia(e,t,n,[]))}))).parse(e,!1),!r)throw new De(2,2,2007);return a},F("shaka.text.Mp4TtmlParser",dT),dT.prototype.parseMedia=dT.prototype.parseMedia,dT.prototype.setManifestType=dT.prototype.setManifestType,dT.prototype.setSequenceMode=dT.prototype.setSequenceMode,dT.prototype.parseInit=dT.prototype.parseInit,Fi['application/mp4; codecs="stpp"']=function(){return new dT},Fi['application/mp4; codecs="stpp.ttml"']=function(){return new dT},Fi['application/mp4; codecs="stpp.ttml.im1i"']=function(){return new dT},Fi['application/mp4; codecs="stpp.ttml.im1t"']=function(){return new dT},Fi['application/mp4; codecs="stpp.ttml.im2i"']=function(){return new dT},Fi['application/mp4; codecs="stpp.ttml.im2t"']=function(){return new dT},Fi['application/mp4; codecs="stpp.ttml.etd1"']=function(){return new dT},Fi['application/mp4; codecs="stpp.ttml.etd1|im1t"']=function(){return new dT},Fi['application/mp4; codecs="stpp.ttml.im1t|etd1"']=function(){return new dT},Fi['application/mp4; codecs="stpp.TTML.im1t"']=function(){return new dT},hT.prototype.parseInit=function(){},hT.prototype.setSequenceMode=function(){},hT.prototype.setManifestType=function(e){this.g=e},hT.prototype.parseMedia=function(e,t){var n=(e=(e=dt(e)).replace(/\r\n|\r(?=[^\n]|$)/gm,"\n")).split(/\n{2,}/m);if(!/^WEBVTT($|[ \t\n])/m.test(n[0]))throw new De(2,2,2e3);if(e=t.vttOffset,"HLS"==this.g)if(n[0].includes("X-TIMESTAMP-MAP")){var i=n[0];if(e=i.match(/LOCAL:((?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{3}))/m),i=i.match(/MPEGTS:(\d+)/m),!e||!i)throw new De(2,2,2e3);if(null==(e=At(e[1])))throw new De(2,2,2e3);i=Number(i[1]);for(var r=t.segmentStart-t.periodStart;95443.7176888889<=r;)r-=95443.7176888889,i+=8589934592;e=t.periodStart+i/9e4-e}else t.periodStart&&t.vttOffset==t.periodStart&&(e=0);for(t=[],r=(i=l(n[0].split("\n"))).next();!r.done;r=i.next())if(r=r.value,/^Region:/.test(r)){r=new bt(r);var a=new xe;St(r),wt(r);for(var o=St(r);o;){var s=a,u=o;(o=/^id=(.*)$/.exec(u))?s.id=o[1]:(o=/^width=(\d{1,2}|100)%$/.exec(u))?s.width=Number(o[1]):(o=/^lines=(\d+)$/.exec(u))?(s.height=Number(o[1]),s.heightUnits=2):(o=/^regionanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(u))?(s.regionAnchorX=Number(o[1]),s.regionAnchorY=Number(o[2])):(o=/^viewportanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(u))?(s.viewportAnchorX=Number(o[1]),s.viewportAnchorY=Number(o[2])):/^scroll=up$/.exec(u)&&(s.scroll="up"),wt(r),o=St(r)}t.push(a)}for(hn(i=new Map),r=[],a=(n=l(n.slice(1))).next();!a.done;a=n.next()){if((1!=(a=a.value.split("\n")).length||a[0])&&!/^NOTE($|[ \t])/.test(a[0])&&"STYLE"==a[0]){for(s=[],o=-1,u=1;u<a.length;u++)a[u].includes("::cue")&&(s.push([]),o=s.length-1),-1!=o&&(s[o].push(a[u]),a[u].includes("}")&&(o=-1));for(o=(s=l(s)).next();!o.done;o=s.next()){var c=o.value;o="global",(u=c[0].match(/\((.*)\)/))&&(o=u.pop()),u=c.slice(1,-1),c[0].includes("}")&&(c=/\{(.*?)\}/.exec(c[0]))&&(u=c[1].split(";")),(c=i.get(o))||(c=new un(0,0,""));for(var d=!1,h=0;h<u.length;h++){var f=/^\s*([^:]+):\s*(.*)/.exec(u[h]);if(f){var p=f[2].trim().replace(";","");switch(f[1].trim()){case"background-color":case"background":d=!0,c.backgroundColor=p;break;case"color":d=!0,c.color=p;break;case"font-family":d=!0,c.fontFamily=p;break;case"font-size":d=!0,c.fontSize=p;break;case"font-weight":(700<=parseInt(p,10)||"bold"==p)&&(d=!0,c.fontWeight=Mn);break;case"font-style":switch(p){case"normal":d=!0,c.fontStyle=Cn;break;case"italic":d=!0,c.fontStyle=Dn;break;case"oblique":d=!0,c.fontStyle="oblique"}break;case"opacity":d=!0,c.opacity=parseFloat(p);break;case"text-combine-upright":d=!0,c.textCombineUpright=p;break;case"text-shadow":d=!0,c.textShadow=p;break;case"white-space":d=!0,c.wrapLine="noWrap"!=p}}}d&&i.set(o,c)}}if(d=e,1==(c=a).length&&!c[0]||/^NOTE($|[ \t])/.test(c[0])||"STYLE"==c[0]||"REGION"==c[0])a=null;else if(a=null,c[0].includes("--\x3e")||(a=c[0],c.splice(0,1)),o=xt(s=new bt(c[0])),h=Tt(s,/[ \t]+--\x3e[ \t]+/g),u=xt(s),null==o||null==h||null==u)W("Failed to parse VTT time code. Cue skipped:",a,c),a=null;else{for(o+=d,u+=d,d=c.slice(1).join("\n").trim(),i.has("global")?((c=i.get("global").clone()).startTime=o,c.endTime=u,c.payload=d):c=new un(o,u,d),wt(s),o=St(s);o;)fT(c,o,t),wt(s),o=St(s);dn(c,i),null!=a&&(c.id=a),a=c}a&&r.push(a)}return r},F("shaka.text.VttTextParser",hT),hT.prototype.parseMedia=hT.prototype.parseMedia,hT.prototype.setManifestType=hT.prototype.setManifestType,hT.prototype.setSequenceMode=hT.prototype.setSequenceMode,hT.prototype.parseInit=hT.prototype.parseInit,Fi["text/vtt"]=function(){return new hT},Fi['text/vtt; codecs="vtt"']=function(){return new hT},Fi['text/vtt; codecs="wvtt"']=function(){return new hT},pT.prototype.parseInit=function(e){var t=this,n=!1;if((new Ta).box("moov",Sa).box("trak",Sa).box("mdia",Sa).R("mdhd",(function(e){e=_o(e.reader,e.version),t.g=e.timescale})).box("minf",Sa).box("stbl",Sa).R("stsd",xa).box("wvtt",(function(){n=!0})).parse(e),!this.g)throw new De(2,2,2008);if(!n)throw new De(2,2,2008)},pT.prototype.setSequenceMode=function(){},pT.prototype.setManifestType=function(){},pT.prototype.parseMedia=function(e,t){if(!e.length)return[];if(!this.g)throw new De(2,2,2008);var n,i=0,r=[],a=[],o=!1,s=!1,u=!1,c=null;if((new Ta).box("moof",Sa).box("traf",Sa).R("tfdt",(function(e){o=!0,i=Uo(e.reader,e.version).baseMediaDecodeTime})).R("tfhd",(function(e){c=Oo(e.reader,e.flags).ed})).R("trun",(function(e){s=!0,r=Bo(e.reader,e.version,e.flags).Zg})).box("mdat",ka((function(e){u=!0,n=e}))).parse(e,!1),!u&&!o&&!s)throw new De(2,2,2008);e=i;for(var d=new ya(n,0),h=l(r),f=h.next();!f.done;f=h.next()){var p=(f=f.value).Of||c,g=f.me?i+f.me:e;e=g+(p||0);var m=0;do{var v=d.P();m+=v;var y=null;"vttc"==Ma(d.P())?8<v&&(y=d.vb(v-8)):d.skip(v-8),p&&y&&(v=gT(y,t.periodStart+g/this.g,t.periodStart+e/this.g),a.push(v))}while(f.sampleSize&&m<f.sampleSize)}return a.filter(Gi)},F("shaka.text.Mp4VttParser",pT),pT.prototype.parseMedia=pT.prototype.parseMedia,pT.prototype.setManifestType=pT.prototype.setManifestType,pT.prototype.setSequenceMode=pT.prototype.setSequenceMode,pT.prototype.parseInit=pT.prototype.parseInit,Fi['application/mp4; codecs="wvtt"']=function(){return new pT},mT.prototype.parseInit=function(){},mT.prototype.setSequenceMode=function(){},mT.prototype.setManifestType=function(){},mT.prototype.parseMedia=function(e){var t=dt(e).replace(/\r+/g,"");if(e=[],""==(t=t.trim()))return e;for(var n=(t=l(t.split("\n\n"))).next();!n.done;n=t.next()){var i=new bt((n=n.value.split("\n"))[0]),r=xt(i),a=Tt(i,/,/g);if(i=xt(i),null==r||null==a||null==i)throw new De(2,2,2001,"Could not parse cue time range in SubViewer");e.push(new un(r,i,n.slice(1).join("\n").trim()))}return e},F("shaka.text.SbvTextParser",mT),mT.prototype.parseMedia=mT.prototype.parseMedia,mT.prototype.setManifestType=mT.prototype.setManifestType,mT.prototype.setSequenceMode=mT.prototype.setSequenceMode,mT.prototype.parseInit=mT.prototype.parseInit,Fi["text/x-subviewer"]=function(){return new mT},vT.prototype.parseInit=function(){},vT.prototype.setSequenceMode=function(){},vT.prototype.setManifestType=function(){},vT.prototype.parseMedia=function(e,t,n){return e=ge(pt(e=yT(e=dt(e)))),this.g.parseMedia(e,t,n,[])},F("shaka.text.SrtTextParser",vT),vT.srt2webvtt=yT,vT.prototype.parseMedia=vT.prototype.parseMedia,vT.prototype.setManifestType=vT.prototype.setManifestType,vT.prototype.setSequenceMode=vT.prototype.setSequenceMode,vT.prototype.parseInit=vT.prototype.parseInit,Fi["text/srt"]=function(){return new vT},bT.prototype.parseInit=function(){},bT.prototype.setSequenceMode=function(){},bT.prototype.setManifestType=function(){},bT.prototype.parseMedia=function(e){var t="",n="",i=null,r=null;for(r=(e=l(r=dt(e).split(/\r?\n\s*\r?\n/))).next();!r.done;r=e.next()){var a=r.value;r=a,(a=xT.exec(a))&&(i=a[1],r=a[2]),"V4 Styles"==i||"V4+ Styles"==i?(t=r,t=n?t+"\n"+r:r):"Events"==i&&(n=n?n+"\n"+r:r)}for(i=[],r=null,e=(t=l(t.split(/\r?\n/))).next();!e.done;e=t.next())if(e=e.value,!/^\s*;/.test(e)&&(a=AT.exec(e)))if(e=a[1].trim(),a=a[2].trim(),"Format"==e)r=a.split(ET);else if("Style"==e){e=a.split(ET),a={};for(var o=0;o<r.length&&o<e.length;o++)a[r[o]]=e[o];i.push(a)}for(r=[],t=null,a=(n=l(n.split(/\r?\n/))).next(),e={};!a.done;e={lh:void 0},a=n.next())if(a=a.value,!/^\s*;/.test(a)&&(o=AT.exec(a)))if(a=o[1].trim(),o=o[2].trim(),"Format"==a)t=o.split(ET);else if("Dialogue"==a){o=o.split(ET),a={};for(var s=0;s<t.length&&s<o.length;s++)a[t[s]]=o[s];o=new un(s=ST(a.Start),ST(a.End),o.slice(t.length-1).join(",").replace(/\\N/g,"\n").replace(/\{[^}]+\}/g,"")),e.lh=a.Style,(e=i.find(function(e){return function(t){return t.Name==e.lh}}(e)))&&wT(o,e),r.push(o)}return r},F("shaka.text.SsaTextParser",bT),bT.prototype.parseMedia=bT.prototype.parseMedia,bT.prototype.setManifestType=bT.prototype.setManifestType,bT.prototype.setSequenceMode=bT.prototype.setSequenceMode,bT.prototype.parseInit=bT.prototype.parseInit;var xT=/^\s*\[([^\]]+)\]\r?\n([\s\S]*)/,AT=/^\s*([^:]+):\s*(.*)/,ET=/\s*,\s*/,kT=/^(\d+:)?(\d{1,2}):(\d{1,2}(?:[.]\d{1,3})?)?$/;function IT(e,t){var n=1&e[t+1]?7:9;return t+n<=e.length&&0<(e=((3&e[t+3])<<11|e[t+4]<<3|(224&e[t+5])>>>5)-n)?{Sd:n,ea:e}:null}function MT(e,t){var n=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350],i=(60&e[t+2])>>>2;if(i>n.length-1)return null;var r=1+((192&e[t+2])>>>6),a=(1&e[t+2])<<2;return a|=(192&e[t+3])>>>6,{sampleRate:n[i],channelCount:a,codec:"mp4a.40."+r}}function CT(e,t){if(t+1<e.length&&255===e[t]&&240==(246&e[t+1])){var n=1&e[t+1]?7:9;if(t+n>=e.length)return!1;var i=(3&e[t+3])<<11|e[t+4]<<3|(224&e[t+5])>>>5;return!(i<=n)&&((t+=i)===e.length||t+1<e.length&&255===e[t]&&240==(246&e[t+1]))}return!1}function DT(e){this.i=e,this.h=0,this.g=new Map}function RT(e,t){if(t+8>e.length||11!==e[t]||119!==e[t+1])return null;var n=e[t+4]>>6;if(3<=n)return null;var i=63&e[t+4],r=2*[64,69,96,64,70,96,80,87,120,80,88,120,96,104,144,96,105,144,112,121,168,112,122,168,128,139,192,128,140,192,160,174,240,160,175,240,192,208,288,192,209,288,224,243,336,224,244,336,256,278,384,256,279,384,320,348,480,320,349,480,384,417,576,384,418,576,448,487,672,448,488,672,512,557,768,512,558,768,640,696,960,640,697,960,768,835,1152,768,836,1152,896,975,1344,896,976,1344,1024,1114,1536,1024,1115,1536,1152,1253,1728,1152,1254,1728,1280,1393,1920,1280,1394,1920][3*i+n];if(t+r>e.length)return null;var a=e[t+6]>>5,o=0;2===a?o+=2:(1&a&&1!==a&&(o+=2),4&a&&(o+=2)),o=(e[t+6]<<8|e[t+7])>>12-o&1;var s=7&e[t+5];return e=new Uint8Array([n<<6|e[t+5]>>3<<1|s>>2,(3&s)<<6|a<<3|o<<2|i>>4,i<<4&224]),{sampleRate:[48e3,44100,32e3][n],channelCount:[2,1,2,3,3,4,4,5][a]+o,qa:e,ea:r}}function PT(e,t){if(11===e[t]&&119===e[t+1]){var n,i,r=0,a=5;for(t+=a;0<a;){i=e[t];var o=Math.min(a,8),s=8-o;n=(i&(n=4278190080>>>24+s<<s))>>s,r=r?r<<o|n:n,t+=1,a-=o}if(16>r)return!0}return!1}function LT(e){this.i=e,this.h=0,this.g=new Map}function NT(e,t){if(t+8>e.length||2935!=(e[t]<<8|e[t+1]))return null;var n=new Ko(e.subarray(t+2));qo(n,2),qo(n,3);var i=zo(n,11)+1<<1,r=zo(n,2);if(3==r){r=[24e3,22060,16e3][r=zo(n,2)];var a=3}else r=[48e3,44100,32e3][r],a=zo(n,2);var o=zo(n,3),s=zo(n,1);return n=zo(n,5),t+i>e.byteLength?null:(e=Math.floor(i*r/(16*[1,2,3,6][a])),e=new Uint8Array([(8160&e)>>5,(31&e)<<3,r<<6|n<<1,o<<1|s,0]),{sampleRate:r,channelCount:[2,1,2,3,3,4,4,5][o]+s,qa:e,ea:i})}function jT(e){this.i=e,this.h=0,this.g=new Map}function OT(e){for(var t=!1,n=[],i=e.find((function(e){return 7==e.type})),r=!1,a=(e=l(e)).next();!a.done;a=e.next()){var o=!1;switch((a=a.value).type){case 1:o=r=!0;var s=a.data;i&&4<s.length&&(2===(s=ts(new Ko(s)))||4===s||7===s||9===s)&&(t=!0);break;case 5:t=o=r=!0;break;case 6:case 7:case 8:case 12:o=!0;break;case 9:r=o=!0;break;default:o=!1}r&&o&&(o=a.fullData.byteLength,(s=new Uint8Array(4))[0]=o>>24&255,s[1]=o>>16&255,s[2]=o>>8&255,s[3]=255&o,n.push(s),n.push(a.fullData))}return n.length?{data:di.apply(ai,c(n)),nd:t}:null}Fi["text/x-ssa"]=function(){return new bT},(i=DT.prototype).destroy=function(){this.g.clear()},i.isSupported=function(e){return"audio/aac"==e.toLowerCase().split(";")[0]&&ne(this.convertCodecs("audio",e))},i.convertCodecs=function(e,t){return"audio/aac"==t.toLowerCase().split(";")[0]?'audio/mp4; codecs="'+(Ri(t)||"mp4a.40.2")+'"':t},i.getOriginalMimeType=function(){return this.i},i.transmux=function(e,t,n,i){for(var r=ge(e),a=jo(r),o=a.length;o<r.length&&!CT(r,o);o++);if(e=1e3*n.endTime,(a=No(a)).length&&n&&(a=a.find((function(e){return"com.apple.streaming.transportStreamTimestamp"===e.description})))&&(e=a.data),!(a=MT(r,o)))return Promise.reject(new De(2,3,3018,n?n.N()[0]:null));t.audioSamplingRate=a.sampleRate,t.channelsCount=a.channelCount;for(var s=[];o<r.length;){var u=IT(r,o);if(!u)return Promise.reject(new De(2,3,3018,n?n.N()[0]:null));var l=u.Sd+u.ea;o+l<=r.length&&s.push({data:r.subarray(o+u.Sd,o+l),size:u.ea,duration:1024,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),o+=l}return r=a.sampleRate,e=Math.floor(e*r/1e3),i=new Zm([i={id:t.id,type:"audio",codecs:a.codec,encrypted:t.encrypted&&0<t.drmInfos.length,timescale:r,duration:i,fb:[],qa:new Uint8Array([]),za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.h,baseMediaDecodeTime:e,ab:s},stream:t}]),n=t.id+"_"+n.i,this.g.has(n)?t=this.g.get(n):(t=ev(i),this.g.set(n,t)),n=av(i),this.h++,t=di(t,n),Promise.resolve(t)},F("shaka.transmuxer.AacTransmuxer",DT),DT.prototype.transmux=DT.prototype.transmux,DT.prototype.getOriginalMimeType=DT.prototype.getOriginalMimeType,DT.prototype.convertCodecs=DT.prototype.convertCodecs,DT.prototype.isSupported=DT.prototype.isSupported,DT.prototype.destroy=DT.prototype.destroy,jn("audio/aac",(function(){return new DT("audio/aac")}),_n),(i=LT.prototype).destroy=function(){this.g.clear()},i.isSupported=function(e){return"audio/ac3"==e.toLowerCase().split(";")[0]&&ne(this.convertCodecs("audio",e))},i.convertCodecs=function(e,t){return"audio/ac3"==t.toLowerCase().split(";")[0]?'audio/mp4; codecs="ac-3"':t},i.getOriginalMimeType=function(){return this.i},i.transmux=function(e,t,n,i){for(var r=jo(e=ge(e)),a=r.length;a<e.length&&!PT(e,a);a++);var o=1e3*n.endTime;(r=No(r)).length&&n&&(r=r.find((function(e){return"com.apple.streaming.transportStreamTimestamp"===e.description})))&&(o=r.data),r=0;for(var s=new Uint8Array([]),u=[];a<e.length;){var l=RT(e,a);if(!l)return Promise.reject(new De(2,3,3018,n?n.N()[0]:null));t.audioSamplingRate=l.sampleRate,t.channelsCount=l.channelCount,r=l.sampleRate,s=l.qa,u.push({data:e.subarray(a,a+l.ea),size:l.ea,duration:1536,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),a+=l.ea}return e=Math.floor(o*r/1e3),i=new Zm([i={id:t.id,type:"audio",codecs:"ac-3",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:r,duration:i,fb:[],qa:s,za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.h,baseMediaDecodeTime:e,ab:u},stream:t}]),n=t.id+"_"+n.i,this.g.has(n)?t=this.g.get(n):(t=ev(i),this.g.set(n,t)),n=av(i),this.h++,t=di(t,n),Promise.resolve(t)},F("shaka.transmuxer.Ac3Transmuxer",LT),LT.prototype.transmux=LT.prototype.transmux,LT.prototype.getOriginalMimeType=LT.prototype.getOriginalMimeType,LT.prototype.convertCodecs=LT.prototype.convertCodecs,LT.prototype.isSupported=LT.prototype.isSupported,LT.prototype.destroy=LT.prototype.destroy,jn("audio/ac3",(function(){return new LT("audio/ac3")}),_n),(i=jT.prototype).destroy=function(){this.g.clear()},i.isSupported=function(e){return"audio/ec3"==e.toLowerCase().split(";")[0]&&ne(this.convertCodecs("audio",e))},i.convertCodecs=function(e,t){return"audio/ec3"==t.toLowerCase().split(";")[0]?'audio/mp4; codecs="ec-3"':t},i.getOriginalMimeType=function(){return this.i},i.transmux=function(e,t,n,i){for(var r=jo(e=ge(e)),a=r.length;a<e.length&&2935!=(e[a]<<8|e[a+1]);a++);var o=1e3*n.endTime;(r=No(r)).length&&n&&(r=r.find((function(e){return"com.apple.streaming.transportStreamTimestamp"===e.description})))&&(o=r.data),r=0;for(var s=new Uint8Array([]),u=[];a<e.length;){var l=NT(e,a);if(!l)return Promise.reject(new De(2,3,3018,n?n.N()[0]:null));t.audioSamplingRate=l.sampleRate,t.channelsCount=l.channelCount,r=l.sampleRate,s=l.qa,u.push({data:e.subarray(a,a+l.ea),size:l.ea,duration:1536,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),a+=l.ea}return e=Math.floor(o*r/1e3),i=new Zm([i={id:t.id,type:"audio",codecs:"ec-3",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:r,duration:i,fb:[],qa:s,za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.h,baseMediaDecodeTime:e,ab:u},stream:t}]),n=t.id+"_"+n.i,this.g.has(n)?t=this.g.get(n):(t=ev(i),this.g.set(n,t)),n=av(i),this.h++,t=di(t,n),Promise.resolve(t)},F("shaka.transmuxer.Ec3Transmuxer",jT),jT.prototype.transmux=jT.prototype.transmux,jT.prototype.getOriginalMimeType=jT.prototype.getOriginalMimeType,jT.prototype.convertCodecs=jT.prototype.convertCodecs,jT.prototype.isSupported=jT.prototype.isSupported,jT.prototype.destroy=jT.prototype.destroy,jn("audio/ec3",(function(){return new jT("audio/ec3")}),_n);var UT=[100,110,122,244,44,83,86,118,128,138,139,134];function _T(e,t){var n=e[t+1]>>3&3,i=e[t+1]>>1&3,r=e[t+2]>>4&15,a=e[t+2]>>2&3;if(1!==n&&0!==r&&15!==r&&3!==a){var o=e[t+3]>>6;r=1e3*VT[14*(3===n?3-i:3===i?3:4)+r-1],a=HT[3*(3===n?0:2===n?1:2)+a],n=GT[n][i];var s=KT[i],u=Math.floor(n*r/a+(e[t+2]>>1&1))*s,l=(navigator.userAgent||"").match(/Chrome\/(\d+)/i);return(l=l?parseInt(l[1],10):0)&&87>=l&&2===i&&224e3<=r&&0===o&&(e[t+3]|=128),{sampleRate:a,channelCount:3===o?1:2,ea:u,Ti:8*n*s}}return null}function BT(e,t){return!(255!==e[t]||224&~e[t+1]||!(6&e[t+1]))}function FT(e,t){if(t+1<e.length&&BT(e,t)){var n=_T(e,t),i=4;return n&&n.ea&&(i=n.ea),(t+=i)===e.length||t+1<e.length&&BT(e,t)}return!1}var VT=[32,64,96,128,160,192,224,256,288,320,352,384,416,448,32,48,56,64,80,96,112,128,160,192,224,256,320,384,32,40,48,56,64,80,96,112,128,160,192,224,256,320,32,48,56,64,80,96,112,128,144,160,176,192,224,256,8,16,24,32,40,48,56,64,80,96,112,128,144,160],HT=[44100,48e3,32e3,22050,24e3,16e3,11025,12e3,8e3],GT=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],KT=[0,1,1,4];function XT(e){this.i=e,this.h=0,this.g=new Map}function qT(e){this.h=e,this.g=null}function zT(e){this.h=e,(this.g=Cg.get("ISOBoxer")())&&function(e){function t(){this._procFullBox(),1&this.flags&&(this._procField("AlgorithmID","uint",24),this._procField("IV_size","uint",8),this._procFieldArray("KID",16,"uint",8)),this._procField("sample_count","uint",32),this._procEntries("entry",this.sample_count,(function(e){this._procEntryField(e,"InitializationVector","data",8),2&this.flags&&(this._procEntryField(e,"NumberOfEntries","uint",16),this._procSubEntries(e,"clearAndCryptedData",e.NumberOfEntries,(function(e){this._procEntryField(e,"BytesOfClearData","uint",16),this._procEntryField(e,"BytesOfEncryptedData","uint",32)})))}))}e.g.addBoxProcessor("saio",(function(){this._procFullBox(),1&this.flags&&(this._procField("aux_info_type","uint",32),this._procField("aux_info_type_parameter","uint",32)),this._procField("entry_count","uint",32),this._procFieldArray("offset",this.entry_count,"uint",1===this.version?64:32)})),e.g.addBoxProcessor("saiz",(function(){this._procFullBox(),1&this.flags&&(this._procField("aux_info_type","uint",32),this._procField("aux_info_type_parameter","uint",32)),this._procField("default_sample_info_size","uint",8),this._procField("sample_count","uint",32),0===this.default_sample_info_size&&this._procFieldArray("sample_info_size",this.sample_count,"uint",8)})),e.g.addBoxProcessor("senc",t),e.g.addBoxProcessor("uuid",(function(){for(var e=!0,n=0;16>n;n++)this.usertype[n]!==YT[n]&&(e=!1);e&&(this._parsing&&(this.type="sepiff"),t.call(this))}))}(this)}function WT(e,t){for(var n=8,i=0;i<e.boxes.length&&e.boxes[i].type!==t;i++)n+=e.boxes[i].size;return n}(i=XT.prototype).destroy=function(){this.g.clear()},i.isSupported=function(e){return"audio/mpeg"==e.toLowerCase().split(";")[0]&&ne(this.convertCodecs("audio",e))},i.convertCodecs=function(e,t){return"audio/mpeg"==t.toLowerCase().split(";")[0]?'audio/mp4; codecs="mp3"':t},i.getOriginalMimeType=function(){return this.i},i.transmux=function(e,t,n,i){for(var r=ge(e),a=jo(r).length;a<r.length&&!FT(r,a);a++);var o;for(e=[];a<r.length;){var s=_T(r,a);if(!s)return Promise.reject(new De(2,3,3018,n?n.N()[0]:null));o||(o=s),a+s.ea<=r.length&&e.push({data:r.subarray(a,a+s.ea),size:s.ea,duration:1152,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),a+=s.ea}return o?(r=9e4*o.Ti/o.sampleRate*this.h,i=new Zm([i={id:t.id,type:"audio",codecs:"mp3",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:o.sampleRate,duration:i,fb:[],qa:new Uint8Array([]),za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.h,baseMediaDecodeTime:r,ab:e},stream:t}]),n=t.id+"_"+n.i,this.g.has(n)?t=this.g.get(n):(t=ev(i),this.g.set(n,t)),n=av(i),this.h++,t=di(t,n),Promise.resolve(t)):Promise.reject(new De(2,3,3018,n?n.N()[0]:null))},F("shaka.transmuxer.Mp3Transmuxer",XT),XT.prototype.transmux=XT.prototype.transmux,XT.prototype.getOriginalMimeType=XT.prototype.getOriginalMimeType,XT.prototype.convertCodecs=XT.prototype.convertCodecs,XT.prototype.isSupported=XT.prototype.isSupported,XT.prototype.destroy=XT.prototype.destroy,jn("audio/mpeg",(function(){return new XT("audio/mpeg")}),_n),(i=qT.prototype).destroy=function(){},i.isSupported=function(e){if("video/mp2t"!=e.toLowerCase().split(";")[0])return!1;var t=Ri(e).split(","),n=mi("audio",t);return t=mi("video",t),!(!n||t||"mp3"!=Mi(n))&&ne(this.convertCodecs("audio",e))},i.convertCodecs=function(e,t){return"video/mp2t"==t.toLowerCase().split(";")[0]?"audio/mpeg":t},i.getOriginalMimeType=function(){return this.h},i.transmux=function(e,t,n,i,r){if(this.g?this.g.clearData():this.g=new ns,e=ge(e),"mp3"!=(e=this.g.parse(e)).fd().audio||"audio"!=r)return Promise.reject(new De(2,3,3018,n?n.N()[0]:null));for(n=new Uint8Array([]),r=l(e.Wb()),e=r.next();!e.done;e=r.next())if(e=e.value.data)for(t=0;t<e.length;)(i=_T(e,t))?(t+i.ea<=e.length&&(n=di(n,e.subarray(t,t+i.ea))),t+=i.ea):t++;return Promise.resolve(n)},F("shaka.transmuxer.MpegTsTransmuxer",qT),qT.prototype.transmux=qT.prototype.transmux,qT.prototype.getOriginalMimeType=qT.prototype.getOriginalMimeType,qT.prototype.convertCodecs=qT.prototype.convertCodecs,qT.prototype.isSupported=qT.prototype.isSupported,qT.prototype.destroy=qT.prototype.destroy,jn("video/mp2t",(function(){return new qT("video/mp2t")}),Bn),(i=zT.prototype).destroy=function(){},i.isSupported=function(e,t){var n=e.startsWith("mss/");return!(!this.g||!n)&&(t?ne(this.convertCodecs(t,e)):(t=this.convertCodecs("audio",e),e=this.convertCodecs("video",e),ne(t)||ne(e)))},i.convertCodecs=function(e,t){return t.replace("mss/","")},i.getOriginalMimeType=function(){return this.h},i.transmux=function(e,t,n){if(!n)return Promise.resolve(ge(e));if(!t.mssPrivateData)return Promise.reject(new De(2,3,3020,n?n.N()[0]:null));try{var i,r=this.g.parseBuffer(e),a=r.fetch("tfhd");a.track_ID=t.id+1;var o=r.fetch("tfdt"),s=r.fetch("traf");null===o&&((o=this.g.createFullBox("tfdt",s,a)).version=1,o.flags=0,o.baseMediaDecodeTime=Math.floor(n.startTime*t.mssPrivateData.timescale));var u=r.fetch("trun"),l=r.fetch("tfxd");l&&l._parent.boxes.splice(l._parent.boxes.indexOf(l),1);var c=r.fetch("tfrf");c&&c._parent.boxes.splice(c._parent.boxes.indexOf(c),1);var d=r.fetch("sepiff");if(null!==d){d.type="senc",d.usertype=void 0;var h=r.fetch("saio");if(null===h){(h=this.g.createFullBox("saio",s)).version=0,h.flags=0,h.entry_count=1,h.offset=[0];var f=this.g.createFullBox("saiz",s);if(f.version=0,f.flags=0,f.sample_count=d.sample_count,f.default_sample_info_size=0,f.sample_info_size=[],2&d.flags)for(i=0;i<d.sample_count;i+=1)f.sample_info_size[i]=10+6*d.entry[i].NumberOfEntries;else f.default_sample_info_size=8}}a.flags&=16777214,a.flags|=131072,u.flags|=1;var p=r.fetch("moof");u.data_offset=p.getLength()+8;var g=r.fetch("saio");null!==g&&(g.offset[0]=WT(p,"traf")+WT(s,"senc")+16);var m=ge(r.write());return Promise.resolve(m)}catch(e){return e instanceof De?Promise.reject(e):Promise.reject(new De(2,3,3022,n?n.N()[0]:null))}},F("shaka.transmuxer.MssTransmuxer",zT),zT.prototype.transmux=zT.prototype.transmux,zT.prototype.getOriginalMimeType=zT.prototype.getOriginalMimeType,zT.prototype.convertCodecs=zT.prototype.convertCodecs,zT.prototype.isSupported=zT.prototype.isSupported,zT.prototype.destroy=zT.prototype.destroy;var YT=new Uint8Array([162,57,79,82,90,155,79,20,162,68,108,66,124,100,141,244]);function JT(e){this.l=e,this.g=0,this.i=new Map,this.h=this.j=null}jn("mss/audio/mp4",(function(){return new zT("mss/audio/mp4")}),_n),jn("mss/video/mp4",(function(){return new zT("mss/video/mp4")}),_n),(i=JT.prototype).destroy=function(){this.i.clear(),this.h&&this.h.destroy()},i.isSupported=function(e,t){if("video/mp2t"!=e.toLowerCase().split(";")[0])return!1;var n=e;t&&(n=this.convertCodecs(t,e));var i=Ri(n).split(",");return n=mi("audio",i),i=mi("video",i),!(n&&(n=Mi(n),!ZT.includes(n))||i&&(n=Mi(i),!eS.includes(n)))&&(t?ne(this.convertCodecs(t,e)):(t=this.convertCodecs("audio",e),e=this.convertCodecs("video",e),ne(t)||ne(e)))},i.convertCodecs=function(e,t){return"video/mp2t"==t.toLowerCase().split(";")[0]?(t=Ri(t).replace("mp4a.40.34","mp3").split(",").map((function(e){return lr(e,"audio/mp4")})).map(cr).join(","),"audio"==e?'audio/mp4; codecs="'+t+'"':'video/mp4; codecs="'+t+'"'):t},i.getOriginalMimeType=function(){return this.l},i.transmux=function(e,t,n,i,r){var a=ge(e);if("audio"==r&&!os(a)){for(var o=jo(a),s=o.length;s<a.length;s++)if(FT(a,s))return Promise.reject(new De(2,3,3018,n?n.N()[0]:null));for(s=o.length;s<a.length;s++)if(CT(a,s))return this.h||(this.h=new DT("audio/aac")),this.h.transmux(e,t,n,i,r);return Promise.reject(new De(2,3,3018,n?n.N()[0]:null))}this.j?this.j.clearData():this.j=new ns;var u=this.j.parse(a),d=[],h=u.fd();try{var f=null;if("video"==r){switch(h.video){case"avc":var p=[],g=null,m=[],v=u.sc();if(!v.length)throw new De(2,3,3023,n?n.N()[0]:null);for(var y=0;y<v.length;y++){var b=v[y],w=b.nalus;m.push.apply(m,c(w));var T,S=OT(w);if(S)null==g&&(g=b.dts),T=y+1<v.length?(v[y+1].dts||0)-(b.dts||0):1<v.length?(b.dts||0)-(v[y-1].dts||0):9e4*(n.endTime-n.startTime),p.push({data:S.data,size:S.data.byteLength,duration:T,hb:Math.round((b.pts||0)-(b.dts||0)),flags:{kb:0,$a:0,Za:0,Xa:0,Ya:S.nd?2:1,lb:S.nd?0:1}})}var x=function(e){if(!e.length)return null;var t=e.find((function(e){return 7==e.type}));if(e=e.find((function(e){return 8==e.type})),!t||!e)return null;var n=new Ko(t.data),i=Zo(n);if(Zo(n),Zo(n),Yo(n),UT.includes(i)&&(3===(i=Jo(n))&&qo(n,1),Yo(n),Yo(n),qo(n,1),Qo(n))){i=3!==i?8:12;for(var r=0;r<i;r++)Qo(n)&&es(n,6>r?16:64)}if(Yo(n),0===(i=Jo(n)))Jo(n);else if(1===i)for(qo(n,1),Yo(n),Yo(n),i=Jo(n),r=0;r<i;r++)Yo(n);Yo(n),qo(n,1);var a=Jo(n),o=Jo(n),s=zo(n,1);0===s&&qo(n,1),qo(n,1);var u=0,l=0,d=0,h=0;if(Qo(n)&&(u=Jo(n),l=Jo(n),d=Jo(n),h=Jo(n)),r=i=1,Qo(n)&&Qo(n)){var f=Zo(n);0<f&&16>=f?(i=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2][f-1],r=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1][f-1]):255===f&&(i=zo(n,16),r=zo(n,16))}return n=(2-s)*(o+1)*16-2*d-2*h,a=16*(a+1)-2*u-2*l,u=[],t=t.fullData,u.push(t.byteLength>>>8&255),u.push(255&t.byteLength),u=u.concat.apply(u,c(t)),t=[],e=e.fullData,t.push(e.byteLength>>>8&255),t.push(255&e.byteLength),t=t.concat.apply(t,c(e)),{height:n,width:a,za:e=new Uint8Array([1,u[3],u[4],u[5],255,225].concat(u,[1],t)),Da:i,Fa:r}}(m);if(!x||null==g)throw new De(2,3,3018,n?n.N()[0]:null);t.height=x.height,t.width=x.width,f={id:t.id,type:"video",codecs:"avc1",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:9e4,duration:i,fb:[],qa:new Uint8Array([]),za:x.za,Da:x.Da,Fa:x.Fa,data:{wb:this.g,baseMediaDecodeTime:g,ab:p},stream:t};break;case"hvc":var A=[],E=null,k=[],I=u.sc();if(!I.length)throw new De(2,3,3023,n?n.N()[0]:null);for(var M=0;M<I.length;M++){var C=I[M],D=C.nalus;k.push.apply(k,c(D));for(var R=!1,P=[],L=!1,N=l(D),j=N.next();!j.done;j=N.next()){var O=j.value;switch(O.type){case 1:case 0:var U=L=!0;break;case 19:case 20:case 21:R=U=L=!0;break;case 32:case 33:case 34:case 39:case 40:U=!0;break;case 35:L=U=!0;break;default:U=!1}if(L&&U){var _=O.fullData.byteLength,B=new Uint8Array(4);B[0]=_>>24&255,B[1]=_>>16&255,B[2]=_>>8&255,B[3]=255&_,P.push(B),P.push(O.fullData)}}var F,V=P.length?{data:di.apply(ai,c(P)),nd:R}:null;if(V)null==E&&null!=C.dts&&(E=C.dts),F=M+1<I.length?(I[M+1].dts||0)-(C.dts||0):1<I.length?(C.dts||0)-(I[M-1].dts||0):9e4*(n.endTime-n.startTime),A.push({data:V.data,size:V.data.byteLength,duration:F,hb:Math.round((C.pts||0)-(C.dts||0)),flags:{kb:0,$a:0,Za:0,Xa:0,Ya:V.nd?2:1,lb:V.nd?0:1}})}var H=function(e){if(!e.length)return null;var t=e.find((function(e){return 32==e.type})),n=e.find((function(e){return 33==e.type})),i=e.find((function(e){return 34==e.type}));if(!t||!n||!i)return null;var r=function(e){var t=new Ko(e,!0);return Zo(t),Zo(t),zo(t,4),zo(t,2),zo(t,6),{Cf:(e=zo(t,3))+1,Zf:t=Qo(t)}}(t.fullData);e=function(e){Zo(e=new Ko(e,!0)),Zo(e);var t=0,n=0,i=0,r=0;zo(e,4);var a=zo(e,3);Qo(e);for(var o=zo(e,2),s=zo(e,1),u=zo(e,5),l=Zo(e),c=Zo(e),d=Zo(e),h=Zo(e),f=Zo(e),p=Zo(e),g=Zo(e),m=Zo(e),v=Zo(e),y=Zo(e),b=Zo(e),w=[],T=[],S=0;S<a;S++)w.push(Qo(e)),T.push(Qo(e));if(0<a)for(S=a;8>S;S++)zo(e,2);for(S=0;S<a;S++)w[S]&&zo(e,88),T[S]&&Zo(e);Jo(e),3==(w=Jo(e))&&zo(e,1),T=Jo(e),S=Jo(e),Qo(e)&&(t+=Jo(e),n+=Jo(e),i+=Jo(e),r+=Jo(e));var x=Jo(e),A=Jo(e),E=Jo(e);if(Qo(e))for(var k=0;k<=a;k++)Jo(e),Jo(e),Jo(e);else Jo(e),Jo(e),Jo(e);if(Jo(e),Jo(e),Jo(e),Jo(e),Jo(e),Jo(e),Qo(e)&&Qo(e))for(k=0;4>k;k++)for(var I=0;I<(3===k?2:6);I++)if(Qo(e)){var M=Math.min(64,1<<4+(k<<1));1<k&&$o(e);for(var C=0;C<M;C++)$o(e)}else Jo(e);for(Qo(e),Qo(e),Qo(e)&&(Zo(e),Jo(e),Jo(e),Qo(e)),k=Jo(e),M=I=0;M<k;M++)if(C=!1,0!==M&&(C=Qo(e)),C){M===k&&Jo(e),Qo(e),Jo(e);for(var D=C=0;D<=I;D++){var R=Qo(e),P=!1;R||(P=Qo(e)),(R||P)&&C++}I=C}else{for(I=(D=Jo(e))+(C=Jo(e)),R=0;R<D;R++)Jo(e),Qo(e);for(D=0;D<C;D++)Jo(e),Qo(e)}if(Qo(e))for(k=Jo(e),I=0;I<k;I++){for(M=0;M<E+4;M++)zo(e,1);zo(e,1)}if(k=E=1,I=0,Qo(e),Qo(e),Qo(e)){if(Qo(e)&&(C=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2],D=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1],0<(M=Zo(e))&&16>=M?(E=C[M-1],k=D[M-1]):255===M&&(E=zo(e,16),k=zo(e,16))),Qo(e)&&Qo(e),Qo(e)&&(zo(e,3),Qo(e),Qo(e)&&(Zo(e),Zo(e),Zo(e))),Qo(e)&&(Jo(e),Jo(e)),Qo(e),Qo(e),Qo(e),(M=Qo(e))&&(Jo(e),Jo(e),Jo(e),Jo(e)),Qo(e)&&(zo(e,32),zo(e,32),Qo(e)&&Jo(e),Qo(e)))for(D=!1,M=Qo(e),C=Qo(e),(M||C)&&((D=Qo(e))&&(Zo(e),zo(e,5),Qo(e),zo(e,5)),zo(e,4),zo(e,4),D&&zo(e,4),zo(e,5),zo(e,5),zo(e,5)),R=0;R<=a;R++){var L=!0;P=1,Qo(e)||(L=Qo(e));var N=!1;if(L?Jo(e):N=Qo(e),N||(P=Jo(e)+1),M){for(L=0;L<P;L++)Jo(e),Jo(e),D&&(Jo(e),Jo(e));Qo(e)}if(C){for(L=0;L<P;L++)Jo(e),Jo(e),D&&(Jo(e),Jo(e));Qo(e)}}Qo(e)&&(Qo(e),Qo(e),Qo(e),I=Jo(e),Jo(e),Jo(e),Jo(e),Jo(e))}return{af:b,gf:o,hf:s,ff:u,bf:l,cf:c,df:d,ef:h,Ve:f,We:p,Xe:g,Ye:m,Ze:v,$e:y,$d:I,Oe:0,Me:w,Le:x,Ke:A,width:T-(t+n)*(1===w||2===w?2:1),height:S-(i+r)*(1===w?2:1),Vi:E,Ui:k}}(n.fullData);var a=function(e){var t=new Ko(e,!0);Zo(t),Zo(t),Jo(t),Jo(t),Qo(t),Qo(t),zo(t,3),Qo(t),Qo(t),Jo(t),Jo(t),$o(t),Qo(t),Qo(t),Qo(t)&&Jo(t),$o(t),$o(t),Qo(t),Qo(t),Qo(t),Qo(t),e=Qo(t);var n=1;return(t=Qo(t))&&e?n=0:t?n=3:e&&(n=2),{Ff:n}}(i.fullData);return t=function(e,t,n,i){var r=new Uint8Array(23+(5+e.byteLength)+(5+t.byteLength)+(5+n.byteLength));return r[0]=1,r[1]=(3&i.gf)<<6|(i.hf?1:0)<<5|31&i.ff,r[2]=i.bf,r[3]=i.cf,r[4]=i.df,r[5]=i.ef,r[6]=i.Ve,r[7]=i.We,r[8]=i.Xe,r[9]=i.Ye,r[10]=i.Ze,r[11]=i.$e,r[12]=i.af,r[13]=240|(3840&i.$d)>>8,r[14]=255&i.$d,r[15]=252|3&i.Ff,r[16]=252|3&i.Me,r[17]=248|7&i.Le,r[18]=248|7&i.Ke,r[19]=0,r[20]=0,r[21]=(3&i.Oe)<<6|(7&i.Cf)<<3|(i.Zf?1:0)<<2|3,r[22]=3,r[23]=160,r[24]=0,r[25]=1,r[26]=(65280&e.byteLength)>>8,r[27]=255&e.byteLength,r.set(e,28),r[23+(5+e.byteLength)]=161,r[e.byteLength+29]=0,r[e.byteLength+30]=1,r[e.byteLength+31]=(65280&t.byteLength)>>8,r[e.byteLength+32]=255&t.byteLength,r.set(t,e.byteLength+33),r[23+(e.byteLength+10+t.byteLength)]=162,r[e.byteLength+10+t.byteLength+24]=0,r[e.byteLength+10+t.byteLength+25]=1,r[e.byteLength+10+t.byteLength+26]=(65280&n.byteLength)>>8,r[e.byteLength+10+t.byteLength+27]=255&n.byteLength,r.set(n,e.byteLength+10+t.byteLength+28),r}(t.fullData,n.fullData,i.fullData,{Cf:r.Cf,Zf:r.Zf,gf:e.gf,hf:e.hf,af:e.af,ff:e.ff,bf:e.bf,cf:e.cf,df:e.df,ef:e.ef,Ve:e.Ve,We:e.We,Xe:e.Xe,Ye:e.Ye,Ze:e.Ze,$e:e.$e,Oe:e.Oe,$d:e.$d,Me:e.Me,Le:e.Le,Ke:e.Ke,Ff:a.Ff}),{height:e.height,width:e.width,za:t,Da:e.Vi,Fa:e.Ui}}(k);if(!H||null==E)throw new De(2,3,3018,n?n.N()[0]:null);t.height=H.height,t.width=H.width,f={id:t.id,type:"video",codecs:"hvc1",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:9e4,duration:i,fb:[],qa:new Uint8Array([]),za:H.za,Da:H.Da,Fa:H.Fa,data:{wb:this.g,baseMediaDecodeTime:E,ab:A},stream:t}}f&&(d.push(f),f=null)}if("audio"==r){switch(h.audio){case"aac":for(var G,K=[],X=null,q=l(u.Wb()),z=q.next();!z.done;z=q.next()){var W=z.value,Y=W.data;if(Y){var J=0;if(!(G=MT(Y,J)))throw new De(2,3,3018,n?n.N()[0]:null);for(t.audioSamplingRate=G.sampleRate,t.channelsCount=G.channelCount,null==X&&null!==W.pts&&(X=W.pts);J<Y.length;){var $=IT(Y,J);if($){var Q=$.Sd+$.ea;J+Q<=Y.length&&K.push({data:Y.subarray(J+$.Sd,J+Q),size:$.ea,duration:1024,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),J+=Q}else J++}}}if(!G||null==X){if(!u.sc().length)throw new De(2,3,3018,n?n.N()[0]:null);X=9e4*n.startTime;var Z=mi("audio",t.codecs.split(","));if(!Z||!t.channelsCount||!t.audioSamplingRate)throw new De(2,3,3018,n?n.N()[0]:null);G={sampleRate:t.audioSamplingRate,channelCount:t.channelsCount,codec:Z};var ee=function(e,t){if("mp4a.40.2"===e){if(1===t)return new Uint8Array([0,200,0,128,35,128]);if(2===t)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(3===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);if(4===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);if(5===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,56]);if(6===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,0,178,0,32,8,224])}else{if(1===t)return new Uint8Array([1,64,34,128,163,78,230,128,186,8,0,0,0,28,6,241,193,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(2===t||3===t)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94])}return null}(Z,t.channelsCount);if(!ee)throw new De(2,3,3018,n?n.N()[0]:null);for(var te=X+9e4*(n.endTime-n.startTime),ne=X;ne<te;)K.push({data:ee,size:ee.byteLength,duration:1024,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),ne+=1024/G.sampleRate*9e4}var ie=G.sampleRate,re=X/9e4*ie;f={id:t.id,type:"audio",codecs:G.codec,encrypted:t.encrypted&&0<t.drmInfos.length,timescale:ie,duration:i,fb:[],qa:new Uint8Array([]),za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.g,baseMediaDecodeTime:re,ab:K},stream:t};break;case"ac3":for(var ae=[],oe=0,se=new Uint8Array([]),ue=null,le=l(u.Wb()),ce=le.next();!ce.done;ce=le.next()){var de=ce.value,he=de.data;null==ue&&null!==de.pts&&(ue=de.pts);for(var fe=0;fe<he.length;){var pe=RT(he,fe);pe?(t.audioSamplingRate=pe.sampleRate,t.channelsCount=pe.channelCount,oe=pe.sampleRate,se=pe.qa,ae.push({data:he.subarray(fe,fe+pe.ea),size:pe.ea,duration:1536,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),fe+=pe.ea):fe++}}if(0==oe||0==se.byteLength||null==ue)throw new De(2,3,3018,n?n.N()[0]:null);var me=ue/9e4*oe;f={id:t.id,type:"audio",codecs:"ac-3",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:oe,duration:i,fb:[],qa:se,za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.g,baseMediaDecodeTime:me,ab:ae},stream:t};break;case"ec3":for(var ve=[],ye=0,be=new Uint8Array([]),we=null,Te=l(u.Wb()),Se=Te.next();!Se.done;Se=Te.next()){var xe=Se.value,Ae=xe.data;null==we&&null!==xe.pts&&(we=xe.pts);for(var Ee=0;Ee<Ae.length;){var ke=NT(Ae,Ee);ke?(t.audioSamplingRate=ke.sampleRate,t.channelsCount=ke.channelCount,ye=ke.sampleRate,be=ke.qa,ve.push({data:Ae.subarray(Ee,Ee+ke.ea),size:ke.ea,duration:1536,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),Ee+=ke.ea):Ee++}}if(0==ye||0==be.byteLength||null==we)throw new De(2,3,3018,n?n.N()[0]:null);var Ie=we/9e4*ye;f={id:t.id,type:"audio",codecs:"ec-3",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:ye,duration:i,fb:[],qa:be,za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.g,baseMediaDecodeTime:Ie,ab:ve},stream:t};break;case"mp3":for(var Me,Ce=[],Re=null,Pe=l(u.Wb()),Le=Pe.next();!Le.done;Le=Pe.next()){var Ne=Le.value,je=Ne.data;if(je){null==Re&&null!==Ne.pts&&(Re=Ne.pts);for(var Oe=0;Oe<je.length;){var Ue=_T(je,Oe);Ue?(Me||(Me=Ue),Oe+Ue.ea<=je.length&&Ce.push({data:je.subarray(Oe,Oe+Ue.ea),size:Ue.ea,duration:1152,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),Oe+=Ue.ea):Oe++}}}if(!Me||null==Re)throw new De(2,3,3018,n?n.N()[0]:null);var _e=Me.sampleRate,Be=Re/9e4*_e;f={id:t.id,type:"audio",codecs:"mp3",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:_e,duration:i,fb:[],qa:new Uint8Array([]),za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.g,baseMediaDecodeTime:Be,ab:Ce},stream:t};break;case"opus":var Fe=[],Ve=null,He=u.F;if(!He)throw new De(2,3,3018,n?n.N()[0]:null);var Ge=[];switch(He.Fh){case 1:case 2:Ge=[0];break;case 0:Ge=[255,1,1,0,1];break;case 128:Ge=[255,2,0,0,1];break;case 3:Ge=[1,2,1,0,2,1];break;case 4:Ge=[1,2,2,0,1,2,3];break;case 5:Ge=[1,3,2,0,4,1,2,3];break;case 6:Ge=[1,4,2,0,4,1,2,3,5];break;case 7:Ge=[1,4,2,0,4,1,2,3,5,6];break;case 8:Ge=[1,5,3,0,6,1,2,3,4,5,7];break;case 130:Ge=[1,1,2,0,1];break;case 131:Ge=[1,1,3,0,1,2];break;case 132:Ge=[1,1,4,0,1,2,3];break;case 133:Ge=[1,1,5,0,1,2,3,4];break;case 134:Ge=[1,1,6,0,1,2,3,4,5];break;case 135:Ge=[1,1,7,0,1,2,3,4,5,6];break;case 136:Ge=[1,1,8,0,1,2,3,4,5,6,7]}for(var Ke=new Uint8Array([0,He.channelCount,0,0,He.sampleRate>>>24&255,He.sampleRate>>>17&255,He.sampleRate>>>8&255,He.sampleRate>>>0&255,0,0].concat(c(Ge))),Xe=He.sampleRate,qe=l(u.Wb()),ze=qe.next();!ze.done;ze=qe.next()){var We=ze.value,Ye=We.data;null==Ve&&null!==We.pts&&(Ve=We.pts);for(var Je=0;Je<Ye.length;){for(var $e=!!(16&Ye[Je+1]),Qe=!!(8&Ye[Je+1]),Ze=Je+2,et=0;255===Ye[Ze];)et+=255,Ze+=1;et+=Ye[Ze],Ze+=1,Ze+=$e?2:0,Ze+=Qe?2:0;var tt=Ye.slice(Ze,Ze+et);Fe.push({data:tt,size:tt.byteLength,duration:960,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),Je=Ze+et}}if(0==Ke.byteLength||null==Ve)throw new De(2,3,3018,n?n.N()[0]:null);t.audioSamplingRate=He.sampleRate,t.channelsCount=He.channelCount;var nt=Ve/9e4*Xe;f={id:t.id,type:"audio",codecs:"opus",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:Xe,duration:i,fb:[],qa:Ke,za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.g,baseMediaDecodeTime:nt,ab:Fe},stream:t}}f&&(d.push(f),f=null)}}catch(e){return e&&3023==e.code?Promise.resolve(new Uint8Array([])):Promise.reject(e)}if(!d.length)return Promise.reject(new De(2,3,3018,n?n.N()[0]:null));var it=new Zm(d),rt=t.id+"_"+n.i;if(this.i.has(rt))var at=this.i.get(rt);else at=ev(it),this.i.set(rt,at);var ot=av(it);this.g++;var st=di(at,ot);return Promise.resolve(st)},F("shaka.transmuxer.TsTransmuxer",JT),JT.prototype.transmux=JT.prototype.transmux,JT.prototype.getOriginalMimeType=JT.prototype.getOriginalMimeType,JT.prototype.convertCodecs=JT.prototype.convertCodecs,JT.prototype.isSupported=JT.prototype.isSupported,JT.prototype.destroy=JT.prototype.destroy;var $T,QT,ZT=["aac","ac-3","ec-3","mp3","opus"],eS=["avc","hevc"];function tS(){}function nS(){$T||navigator.emeEncryptionSchemePolyfilled?console.debug("EmeEncryptionSchemePolyfill: Already installed."):navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration?($T=navigator.requestMediaKeySystemAccess,console.debug("EmeEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.requestMediaKeySystemAccess=iS,navigator.emeEncryptionSchemePolyfilled=!0):console.debug("EmeEncryptionSchemePolyfill: EME not found")}function iS(e,t){var n,i=this;return P((function(r){return 1==r.g?(console.assert(i==navigator,'bad "this" for requestMediaKeySystemAccess'),w(r,$T.call(i,e,t),2)):fS(n=r.h)?(console.debug("EmeEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.requestMediaKeySystemAccess=$T,r.return(n)):(console.debug("EmeEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support."),navigator.requestMediaKeySystemAccess=rS,r.return(rS.call(i,e,t)))}))}function rS(e,t){var n,i,r,a,o,s,u,c,d,h,f,p,g=this;return P((function(m){if(1==m.g){for(console.assert(g==navigator,'bad "this" for requestMediaKeySystemAccess'),n=hS(e),i=[],r=l(t),a=r.next();!a.done;a=r.next())o=a.value,s=aS(o.videoCapabilities,n),u=aS(o.audioCapabilities,n),o.videoCapabilities&&o.videoCapabilities.length&&!s.length||o.audioCapabilities&&o.audioCapabilities.length&&!u.length||((c=Object.assign({},o)).videoCapabilities=s,c.audioCapabilities=u,i.push(c));if(!i.length)throw(d=Error("Unsupported keySystem or supportedConfigurations.")).name="NotSupportedError",d.code=DOMException.NOT_SUPPORTED_ERR,d;return w(m,$T.call(g,e,i),2)}return h=m.h,p=f=null,i[0]&&(i[0].videoCapabilities&&(f=i[0].videoCapabilities[0].encryptionScheme),i[0].audioCapabilities&&(p=i[0].audioCapabilities[0].encryptionScheme)),m.return(new dS(h,f,p))}))}function aS(e,t){return e?e.filter((function(e){return pS(e.encryptionScheme,t)})):e}function oS(){}function sS(){QT||navigator.mediaCapabilitiesEncryptionSchemePolyfilled?console.debug("McEncryptionSchemePolyfill: Already installed."):navigator.mediaCapabilities?(QT=navigator.mediaCapabilities.decodingInfo,console.debug("McEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.mediaCapabilities.decodingInfo=uS,navigator.mediaCapabilitiesEncryptionSchemePolyfilled=!0):console.debug("McEncryptionSchemePolyfill: MediaCapabilities not found")}function uS(e){var t,n,i=this;return P((function(r){switch(r.g){case 1:return console.assert(i==navigator.mediaCapabilities,'bad "this" for decodingInfo'),w(r,QT.call(i,e),2);case 2:if(t=r.h,!e.keySystemConfiguration)return r.return(t);if((n=t.keySystemAccess)&&fS(n))return console.debug("McEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.mediaCapabilities.decodingInfo=QT,r.return(t);if(console.debug("McEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support."),navigator.mediaCapabilities.decodingInfo=lS,n){r.u(3);break}return w(r,cS(e),4);case 4:return t.keySystemAccess=r.h,r.return(t);case 3:return r.return(lS.call(i,e))}}))}function lS(e){var t,n,i,r,a,o,s,u=this;return P((function(l){switch(l.g){case 1:return console.assert(u==navigator.mediaCapabilities,'bad "this" for decodingInfo'),n=t=null,!e.keySystemConfiguration||(i=e.keySystemConfiguration,r=i.keySystem,n=i.audio&&i.audio.encryptionScheme,t=i.video&&i.video.encryptionScheme,a=hS(r),o={powerEfficient:!1,smooth:!1,supported:!1,keySystemAccess:null,configuration:e},pS(n,a)&&pS(t,a))?w(l,QT.call(u,e),2):l.return(o);case 2:if((s=l.h).keySystemAccess){s.keySystemAccess=new dS(s.keySystemAccess,t,n),l.u(3);break}if(!e.keySystemConfiguration){l.u(3);break}return w(l,cS(e),5);case 5:s.keySystemAccess=l.h;case 3:return l.return(s)}}))}function cS(e){var t,n;return P((function(i){if(1==i.g){var r=e.keySystemConfiguration,a=[],o=[];return r.audio&&a.push({robustness:r.audio.robustness||"",contentType:e.audio.contentType,encryptionScheme:r.audio.encryptionScheme}),r.video&&o.push({robustness:r.video.robustness||"",contentType:e.video.contentType,encryptionScheme:r.video.encryptionScheme}),r={initDataTypes:r.initDataType?[r.initDataType]:[],distinctiveIdentifier:r.distinctiveIdentifier,persistentState:r.persistentState,sessionTypes:r.sessionTypes},a.length&&(r.audioCapabilities=a),o.length&&(r.videoCapabilities=o),t=r,w(i,navigator.requestMediaKeySystemAccess(e.keySystemConfiguration.keySystem,[t]),2)}return n=i.h,i.return(n)}))}function dS(e,t,n){this.g=e,this.i=t||null,this.h=n||null,this.keySystem=e.keySystem}function hS(e){return e.startsWith("com.widevine")||e.startsWith("com.microsoft")||e.startsWith("com.chromecast")||e.startsWith("com.adobe")||e.startsWith("org.w3")?"cenc":e.startsWith("com.apple")?"cbcs":(console.warn("EmeEncryptionSchemePolyfill: Unknown key system:",e,"Please contribute!"),null)}function fS(e){var t=(e=e.getConfiguration()).audioCapabilities&&e.audioCapabilities[0];return!(!(e=e.videoCapabilities&&e.videoCapabilities[0]||t)||void 0===e.encryptionScheme)}function pS(e,t){return!e||e==t||!("cbcs"!=e&&"cbcs-1-9"!=e||!(bS||SS||yS))}function gS(){}function mS(){nS(),sS()}jn("video/mp2t",(function(){return new JT("video/mp2t")}),Fn),F("EmeEncryptionSchemePolyfill",tS),tS.install=nS,F("McEncryptionSchemePolyfill",oS),oS.install=sS,dS.prototype.getConfiguration=function(){var e=this.g.getConfiguration();if(e.videoCapabilities)for(var t=l(e.videoCapabilities),n=t.next();!n.done;n=t.next())n.value.encryptionScheme=this.i;if(e.audioCapabilities)for(n=(t=l(e.audioCapabilities)).next();!n.done;n=t.next())n.value.encryptionScheme=this.h;return e},dS.prototype.createMediaKeys=function(){return this.g.createMediaKeys()},F("EncryptionSchemePolyfills",gS),gS.install=mS;var vS,yS=navigator.userAgent.includes("CrKey"),bS=100<=parseInt(navigator.userAgent.split("Firefox/").pop(),10),wS=navigator.userAgent||"";if(wS.includes("Web0S")){var TS=wS.match(/Chrome\/(\d+)/);vS=!!TS&&79<=parseInt(TS[1],10)}else vS=!1;var SS=vS;void 0!==n&&n.exports&&(n.exports=gS)}.call(i,e,e,void 0),i.shaka)t[r]=i.shaka[r]}()}},t={};function n(i){var r=t[i];if(void 0!==r)return r.exports;var a=t[i]={exports:{}};return e[i](a,a.exports,n),a.exports}n.d=(e,t)=>{for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var i={};return(()=>{"use strict";n.r(i),n.d(i,{ClientAssertionError:()=>j,ShakaPlayer:()=>G,alarmManager:()=>B,auth:()=>M,deviceManager:()=>F,envInfo:()=>L,getClientAssertion:()=>O,getPlatformInfo:()=>D,init:()=>C,initSequence:()=>A,isRunningE2E:()=>R,lifecycle:()=>U,messageManager:()=>H,platformManager:()=>V,remotePlayer:()=>_,shaka:()=>K,showSequence:()=>E,uiReady:()=>P,writeLicenseResponse:()=>N});var e={};n.r(e),n.d(e,{ClientAssertionError:()=>j,ShakaPlayer:()=>G,alarmManager:()=>B,auth:()=>M,deviceManager:()=>F,envInfo:()=>L,getClientAssertion:()=>O,getPlatformInfo:()=>D,init:()=>C,initSequence:()=>A,isRunningE2E:()=>R,lifecycle:()=>U,messageManager:()=>H,platformManager:()=>V,remotePlayer:()=>_,shaka:()=>K,showSequence:()=>E,uiReady:()=>P,writeLicenseResponse:()=>N});const t=JSON.parse('{"rE":"4.2.64-70c0747.0"}'),{rE:r}=t;class a{constructor(e){this.logFields=e}debug(...e){console.debug(this.formatLogString(e))}log(...e){console.log(this.formatLogString(e))}info(...e){console.info(this.formatLogString(e))}warn(...e){console.warn(this.formatLogString(e))}error(...e){console.error(this.formatLogString(e))}metrics(e){console.info(`[hs-sdk] [metrics] ${JSON.stringify(e)}`)}withFields(e){return new a({...this.logFields,...e})}formatLogString(e){let t="[hs-sdk] "+e.join(" ");return this.logFields&&(t+=" [log-fields] "+JSON.stringify(this.logFields)),t}}const o=new a({sdkVersion:r});function s(e,...t){return console.log(`Called "${e}" with args:`,...t||[],"This feature is only supported E2E."),Promise.resolve()}class u extends EventTarget{ConnectReason=Object.freeze({UNKNOWN:"unknown",INITIAL_CONNECTION:"initial_connection",APPLICATION_RELOAD:"reload_app",UI_RELEASE:"ui_release",UI_TERMINATION:"ui_termination",WEBRTC_ERROR:"webrtc_error",UI_WATCHDOG:"ui_watchdog"});UiState=Object.freeze({UNKNOWN:"unknown",FOREGROUND:"foreground",IN_TRANSITION_TO_FOREGROUND:"inTransitionToForeground",BACKGROUND:"background",IN_TRANSITION_TO_BACKGROUND:"inTransitionToBackground"});constructor(){super()}configure(e){}getConfiguration(){return{autoBackground:{enabled:!1,timeout:{playing:0,idle:0}}}}get state(){return this._state=this.UiState.UNKNOWN,this._state}get connectReason(){return this.ConnectReason.UNKNOWN}get triggerEvent(){return{}}set autoBackground(e){s("lifecycle.autoBackground",e)}get autoBackground(){return!1}set autoBackgroundDelay(e){s("lifecycle.autoBackgroundDelay",e)}get autoBackgroundDelay(){return 0}set autoBackgroundOnUIDelay(e){s("lifecycle.autoBackgroundOnUIDelay",e)}get autoBackgroundOnUIDelay(){return 0}getState(){o.warn("lifecycle getState is not supported if NOT running e2e")}moveToForeground(){return s("lifecycle.moveToForeground")}moveToBackground(){return s("lifecycle.moveToBackground")}switchTenant(e){return s("lifecycle.switchTenant",e)}exitApplication(){return s("lifecycle.exitApplication")}addEventListener(e,t,n){super.addEventListener(e,t,n)}removeEventListener(e,t,n){super.removeEventListener(e,t,n)}}const l={};class c extends EventTarget{constructor(){super(),l.level=0,l.quality=0,l.ssid="unknown",l.bssid="unknown"}get deviceInfo(){return o.log("getDeviceInfo running locally, returning dummy info"),{deviceId:"123456789",modelNumber:"ABC",connectionId:"dummy",community:"LocalDev",tenant:"XXXXXX",clientIp:"0.0.0.0",countryCode:"XX",connectionType:"simulator"}}get wifiInfo(){return l}reboot(){return s("DeviceManager.reboot")}clearWifi(){return s("DeviceManager.clearWifi")}sendDataToDevice(e){return s("DeviceManager.sendDataToDevice",e)}async factoryReset(e=!0){return s("DeviceManager.factoryReset",e)}async getWifiInfo(){return Promise.resolve({})}}class d extends EventTarget{constructor(){super()}get appConfig(){return{}}setTimezone(e){s("PlatformManager.setTimezone",e)}}class h extends EventTarget{constructor(){super()}addEventListener(e,t){s("AlarmManager.addEventListener",e,t)}removeEventListener(e,t){s("AlarmManager.removeEventListener",e,t)}addAlarm(e,t,n="",i=0,r=0){s("AlarmManager.addAlarm",e,t,n,i,r)}deleteAlarm(e){s("AlarmManager.deleteAlarm",e)}deleteAllAlarms(){s("AlarmManager.deleteAllAlarms")}getActiveAlarms(){return s("AlarmManager.getActiveAlarms")}}class f extends EventTarget{constructor(){super()}async registerGroups(e){return s("MessageManager.registerGroups",e)}}Error;class p extends EventTarget{constructor(){super(),this.LoadMode=Object.freeze({NOT_LOADED:"notLoaded",LOADING:"loading",LOADED:"loaded",UNLOADING:"unloading"})}getConfiguration(){return{preferredAudioLanguage:"",preferredSubtitlesLanguage:""}}configure(e){s("RemotePlayer.configure",e)}registerVideoElement(e){this.attach(e)}attach(e){s("RemotePlayer.attach",e)}detach(){s("RemotePlayer.detach")}async load(e,t){return s("RemotePlayer.load",e,t)}async play(){return s("RemotePlayer.play")}async pause(){return s("RemotePlayer.pause")}async stop(){return s("RemotePlayer.stop")}getAssetUri(){return""}getLoadMode(){return this.LoadMode.NOT_LOADED}getTextTracks(){return[]}getAudioTracks(){return[]}async selectAudioTrack(e){return s("RemotePlayer.selectAudioTrack",e)}async selectTextTrack(e){return s("RemotePlayer.selectTextTrack",e)}setTextTrackVisibility(e){return s("RemotePlayer.setTextTrackVisibility",e)}get currentTime(){return 0}set currentTime(e){s("RemotePlayer.currentTime",e)}get duration(){return 0}get textTrackVisibility(){return!1}getPresentationStartTimeAsDate(){return null}async unload(){return s("RemotePlayer.unload")}}var g=n(159);g.util.Error.Category.SENZA_PLAYER_ERROR=50,g.util.Error.Code.SENZA_PLAYER_ERROR=10500;const m={...g};class v extends g.Player{constructor(e,t,n){super(e,t,n)}async attach(e,t=!0){await super.attach(e,t)}async detach(e=!1){return super.detach(e)}async unload(e=!0,t=!1){return super.unload(e,t)}getTextLanguages(){return super.getTextLanguages()}getAudioLanguages(){return super.getAudioLanguages()}selectAudioLanguage(e,t){super.selectAudioLanguage(e,t)}selectTextLanguage(e,t){super.selectTextLanguage(e,t)}setTextTrackVisibility(e){super.setTextTrackVisibility(e)}get isInRemotePlayback(){return!1}async load(e,t,n){return super.load(e,t,n)}async destroy(){return super.destroy()}configure(e){return super.configure(e)}}m.Player=v;const y={BACK:27,HOME:36,LEFT:37,RIGHT:39,UP:38,DOWN:40,ENTER:13},b={root:{top:"5vh",left:"82vw",height:"90vh",fontSize:"16px",width:"16vw",position:"fixed",zIndex:1e4,overflow:"hidden",visibility:"hidden"},item:{backgroundColor:"white",color:"black",fontSize:"12px",display:"flex",padding:"6px",border:"1px solid black",borderTop:"none"},item_key:{borderTopLeftRadius:"6px",borderTopRightRadius:"6px",marginTop:"20px",borderBottom:"3px solid black"},component:{fontWeight:"bold",width:"5vw"},component_key:{fontWeight:"normal",color:"darkgray"},id:{textAlign:"left",fontWeight:"normal",flex:1},id_key:{fontWeight:"bold"},time:{fontVariantNumeric:"tabular-nums",width:"3vw"},time_key:{fontWeight:"bold"}};let w=performance.now();const T=(e,t)=>"key"===t?new Date(e).toLocaleTimeString("en-US",{hour12:!1}):`${(e/1e3).toFixed(2)}s`,S=(e,t,n)=>{Object.entries(e).forEach((([e,i])=>{Object.getOwnPropertyNames(Object.getPrototypeOf(i)).forEach((r=>{if(n&&n(r))return;const a=i[r];"function"==typeof a&&(i[r]=function(...n){return t(e,r,...n),a.apply(this,n)})}))}))},x=(e,t)=>{e.innerHTML="",t.forEach(((n,i)=>{const r=document.createElement("div");Object.assign(r.style,{...b.item,...b[`item_${n?.component}`]}),["component","id","time"].forEach((e=>{if(n[e]){const t=document.createElement("div");Object.assign(t.style,b[e],b[`${e}_${n.component}`]),t.textContent="time"===e?T(n.time,n.component):n[e],r.appendChild(t)}})),e.appendChild(r),i===t.length-1&&r.scrollIntoView({behavior:"smooth"})}))},A=e=>{if(!e)return void o.error("No components to sequence");let t=document.getElementById("sequence-container");if(t)return;t=(()=>{const e=document.createElement("div");return e.id="sequence-container",Object.assign(e.style,b.root),document.body.appendChild(e),e})();const n=new Proxy([],{set:(e,i,r)=>(e[i]=r,"length"!==i&&x(t,n),!0)});window.printSequence=()=>(e=>{const t=e.map((e=>{const t=e.separator?"\n":"",n=e?.time?` ${T(e.time,e?.component)}`:"";if(e.args){const i=e.args.map((e=>"object"==typeof e?"object":e)).join(", ");return`${t}${e.component}.${e.id}(${i})${n}`}return`\n${e.component}: ${e.id}${n}`}));o.log("sequence:\n",t.join("\n"))})(n),((e,t)=>{t.push({component:"key",id:"BOOT",time:Date.now()}),S(e,((e,n,...i)=>{t.push({component:e,id:n,args:i,time:performance.now()-w})}),(e=>e.startsWith("_")||e.startsWith("get"))),(e=>{window.addEventListener("keydown",(t=>{var n;e.push({component:"key",id:(n=t.keyCode,Object.entries(y).find((([,e])=>e===n))?.[0]||String(n)),time:Date.now()}),w=performance.now()}))})(t),o.log("Sequence initialized.")})(e,n),x(t,n)},E=(e=!0)=>{const t=document.getElementById("sequence-container");t?t.style.visibility=e?"visible":"hidden":o.error("Sequence not initialized")},{rE:k}=t;let I;const M={getToken:async function(){return window.senzaSDKImplementation?window.senzaSDKImplementation.auth.getToken():Promise.resolve(I)},forceTokenUpdate:function(){if(I=null,window.senzaSDKImplementation)return window.senzaSDKImplementation.auth.forceTokenUpdate();o.error("forceTokenUpdate: window.cefQuery is undefined")},getClientAssertion:O};async function C(){o.log(`init interface ${k}`),window.senzaSDKImplementation?await window.senzaSDKImplementation.init(k,E,A):s("init"),window.close=()=>{o.warn("window.close is disabled on Senza platform. Use lifecycle.exitApplication() instead.")}}function D(){return window.senzaSDKImplementation?window.senzaSDKImplementation.getPlatformInfo():{version:"X.X.XX-X",pod:"ui-streamer-X.X.XX-X-QWERT-ASDFG-XXX-XXXXXX-XXXXX",podIP:"0.0.0.0",sessionInfo:{userAgent:"SynamediaSenza/XX.YY.ZZ",connectionId:"dummy",deviceId:"123456789",community:"LocalDev",tenant:"XXXXXX",tenantId:"XXXXXX",manifest:{transcontainer:"X.X.XX-X"},settings:{webUI:{backendHeaders:{Authorization:"Bearer dummytoken"}}},homeSessionInfo:{tenantId:"XXXXXX",community:"LocalDev"}}}}function R(){return!("undefined"==typeof window||!window.senzaSDKImplementation)}function P(){if(window.senzaSDKImplementation)return window.senzaSDKImplementation.uiReady();o.error("uiReady: window.cefQuery is undefined")}const L={remoteBrowserIp:window?.diagnostics?.()?.podIP||"127.0.0.1",sdkVersion:k,sdkBackendVersion:window?.senzaSDKImplementation?.version||"N/A"};function N(e,t,n,i){if(window?.senzaSDKImplementation)return window.senzaSDKImplementation.writeLicenseResponse(e,t,n,i);o.error("writeLicenseResponse: window.cefQuery is undefined")}class j extends Error{constructor(e,t){super(t),this.code=e}}function O(){if(window?.senzaSDKImplementation)return window.senzaSDKImplementation.auth.getClientAssertion();o.warn("getClientAssertion is not supported if NOT running e2e")}let U,_,B,F,V,H,G,K;R()?(U=window.senzaSDKImplementation.lifecycle,_=window.senzaSDKImplementation.remotePlayer,B=window.senzaSDKImplementation.alarmManager,F=window.senzaSDKImplementation.deviceManager,V=window.senzaSDKImplementation.platformManager,H=window.senzaSDKImplementation.messageManager,G=window.senzaSDKImplementation.ShakaPlayer,K=window.senzaSDKImplementation.shaka):(o.warn("Senza SDK is not running in E2E environment. Some features may not work as expected."),U=new u,_=new p,B=new h,F=new c,V=new d,H=new f,G=v,K=m),"undefined"!=typeof window&&(window.hs=e,window.senza=window.senza||e)})(),i})()));
|
|
2
|
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t():"function"==typeof define&&define.amd?define([],t):"object"==typeof exports?exports.senza=t():e.senza=t()}(this,(()=>(()=>{var e={5177:function(e,t,n){!function(e){"use strict";e.defineLocale("af",{months:"Januarie_Februarie_Maart_April_Mei_Junie_Julie_Augustus_September_Oktober_November_Desember".split("_"),monthsShort:"Jan_Feb_Mrt_Apr_Mei_Jun_Jul_Aug_Sep_Okt_Nov_Des".split("_"),weekdays:"Sondag_Maandag_Dinsdag_Woensdag_Donderdag_Vrydag_Saterdag".split("_"),weekdaysShort:"Son_Maa_Din_Woe_Don_Vry_Sat".split("_"),weekdaysMin:"So_Ma_Di_Wo_Do_Vr_Sa".split("_"),meridiemParse:/vm|nm/i,isPM:function(e){return/^nm$/i.test(e)},meridiem:function(e,t,n){return e<12?n?"vm":"VM":n?"nm":"NM"},longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Vandag om] LT",nextDay:"[Môre om] LT",nextWeek:"dddd [om] LT",lastDay:"[Gister om] LT",lastWeek:"[Laas] dddd [om] LT",sameElse:"L"},relativeTime:{future:"oor %s",past:"%s gelede",s:"'n paar sekondes",ss:"%d sekondes",m:"'n minuut",mm:"%d minute",h:"'n uur",hh:"%d ure",d:"'n dag",dd:"%d dae",M:"'n maand",MM:"%d maande",y:"'n jaar",yy:"%d jaar"},dayOfMonthOrdinalParse:/\d{1,2}(ste|de)/,ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}(n(5093))},1488:function(e,t,n){!function(e){"use strict";var t=function(e){return 0===e?0:1===e?1:2===e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5},n={s:["أقل من ثانية","ثانية واحدة",["ثانيتان","ثانيتين"],"%d ثوان","%d ثانية","%d ثانية"],m:["أقل من دقيقة","دقيقة واحدة",["دقيقتان","دقيقتين"],"%d دقائق","%d دقيقة","%d دقيقة"],h:["أقل من ساعة","ساعة واحدة",["ساعتان","ساعتين"],"%d ساعات","%d ساعة","%d ساعة"],d:["أقل من يوم","يوم واحد",["يومان","يومين"],"%d أيام","%d يومًا","%d يوم"],M:["أقل من شهر","شهر واحد",["شهران","شهرين"],"%d أشهر","%d شهرا","%d شهر"],y:["أقل من عام","عام واحد",["عامان","عامين"],"%d أعوام","%d عامًا","%d عام"]},i=function(e){return function(i,r,a,s){var o=t(i),u=n[e][t(i)];return 2===o&&(u=u[r?0:1]),u.replace(/%d/i,i)}},r=["جانفي","فيفري","مارس","أفريل","ماي","جوان","جويلية","أوت","سبتمبر","أكتوبر","نوفمبر","ديسمبر"];e.defineLocale("ar-dz",{months:r,monthsShort:r,weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"D/M/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},meridiemParse:/ص|م/,isPM:function(e){return"م"===e},meridiem:function(e,t,n){return e<12?"ص":"م"},calendar:{sameDay:"[اليوم عند الساعة] LT",nextDay:"[غدًا عند الساعة] LT",nextWeek:"dddd [عند الساعة] LT",lastDay:"[أمس عند الساعة] LT",lastWeek:"dddd [عند الساعة] LT",sameElse:"L"},relativeTime:{future:"بعد %s",past:"منذ %s",s:i("s"),ss:i("s"),m:i("m"),mm:i("m"),h:i("h"),hh:i("h"),d:i("d"),dd:i("d"),M:i("M"),MM:i("M"),y:i("y"),yy:i("y")},postformat:function(e){return e.replace(/,/g,"،")},week:{dow:0,doy:4}})}(n(5093))},8676:function(e,t,n){!function(e){"use strict";e.defineLocale("ar-kw",{months:"يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر".split("_"),monthsShort:"يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر".split("_"),weekdays:"الأحد_الإتنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"احد_اتنين_ثلاثاء_اربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",ss:"%d ثانية",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},week:{dow:0,doy:12}})}(n(5093))},2353:function(e,t,n){!function(e){"use strict";var t={1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9",0:"0"},n=function(e){return 0===e?0:1===e?1:2===e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5},i={s:["أقل من ثانية","ثانية واحدة",["ثانيتان","ثانيتين"],"%d ثوان","%d ثانية","%d ثانية"],m:["أقل من دقيقة","دقيقة واحدة",["دقيقتان","دقيقتين"],"%d دقائق","%d دقيقة","%d دقيقة"],h:["أقل من ساعة","ساعة واحدة",["ساعتان","ساعتين"],"%d ساعات","%d ساعة","%d ساعة"],d:["أقل من يوم","يوم واحد",["يومان","يومين"],"%d أيام","%d يومًا","%d يوم"],M:["أقل من شهر","شهر واحد",["شهران","شهرين"],"%d أشهر","%d شهرا","%d شهر"],y:["أقل من عام","عام واحد",["عامان","عامين"],"%d أعوام","%d عامًا","%d عام"]},r=function(e){return function(t,r,a,s){var o=n(t),u=i[e][n(t)];return 2===o&&(u=u[r?0:1]),u.replace(/%d/i,t)}},a=["يناير","فبراير","مارس","أبريل","مايو","يونيو","يوليو","أغسطس","سبتمبر","أكتوبر","نوفمبر","ديسمبر"];e.defineLocale("ar-ly",{months:a,monthsShort:a,weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"D/M/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},meridiemParse:/ص|م/,isPM:function(e){return"م"===e},meridiem:function(e,t,n){return e<12?"ص":"م"},calendar:{sameDay:"[اليوم عند الساعة] LT",nextDay:"[غدًا عند الساعة] LT",nextWeek:"dddd [عند الساعة] LT",lastDay:"[أمس عند الساعة] LT",lastWeek:"dddd [عند الساعة] LT",sameElse:"L"},relativeTime:{future:"بعد %s",past:"منذ %s",s:r("s"),ss:r("s"),m:r("m"),mm:r("m"),h:r("h"),hh:r("h"),d:r("d"),dd:r("d"),M:r("M"),MM:r("M"),y:r("y"),yy:r("y")},preparse:function(e){return e.replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]})).replace(/,/g,"،")},week:{dow:6,doy:12}})}(n(5093))},4496:function(e,t,n){!function(e){"use strict";e.defineLocale("ar-ma",{months:"يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر".split("_"),monthsShort:"يناير_فبراير_مارس_أبريل_ماي_يونيو_يوليوز_غشت_شتنبر_أكتوبر_نونبر_دجنبر".split("_"),weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"احد_اثنين_ثلاثاء_اربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",ss:"%d ثانية",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},week:{dow:1,doy:4}})}(n(5093))},6947:function(e,t,n){!function(e){"use strict";var t={1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩",0:"٠"},n={"١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","٠":"0"};e.defineLocale("ar-ps",{months:"كانون الثاني_شباط_آذار_نيسان_أيّار_حزيران_تمّوز_آب_أيلول_تشري الأوّل_تشرين الثاني_كانون الأوّل".split("_"),monthsShort:"ك٢_شباط_آذار_نيسان_أيّار_حزيران_تمّوز_آب_أيلول_ت١_ت٢_ك١".split("_"),weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},meridiemParse:/ص|م/,isPM:function(e){return"م"===e},meridiem:function(e,t,n){return e<12?"ص":"م"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",ss:"%d ثانية",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},preparse:function(e){return e.replace(/[٣٤٥٦٧٨٩٠]/g,(function(e){return n[e]})).split("").reverse().join("").replace(/[١٢](?![\u062a\u0643])/g,(function(e){return n[e]})).split("").reverse().join("").replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]})).replace(/,/g,"،")},week:{dow:0,doy:6}})}(n(5093))},2682:function(e,t,n){!function(e){"use strict";var t={1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩",0:"٠"},n={"١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","٠":"0"};e.defineLocale("ar-sa",{months:"يناير_فبراير_مارس_أبريل_مايو_يونيو_يوليو_أغسطس_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),monthsShort:"يناير_فبراير_مارس_أبريل_مايو_يونيو_يوليو_أغسطس_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},meridiemParse:/ص|م/,isPM:function(e){return"م"===e},meridiem:function(e,t,n){return e<12?"ص":"م"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",ss:"%d ثانية",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},preparse:function(e){return e.replace(/[١٢٣٤٥٦٧٨٩٠]/g,(function(e){return n[e]})).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]})).replace(/,/g,"،")},week:{dow:0,doy:6}})}(n(5093))},9756:function(e,t,n){!function(e){"use strict";e.defineLocale("ar-tn",{months:"جانفي_فيفري_مارس_أفريل_ماي_جوان_جويلية_أوت_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),monthsShort:"جانفي_فيفري_مارس_أفريل_ماي_جوان_جويلية_أوت_سبتمبر_أكتوبر_نوفمبر_ديسمبر".split("_"),weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[اليوم على الساعة] LT",nextDay:"[غدا على الساعة] LT",nextWeek:"dddd [على الساعة] LT",lastDay:"[أمس على الساعة] LT",lastWeek:"dddd [على الساعة] LT",sameElse:"L"},relativeTime:{future:"في %s",past:"منذ %s",s:"ثوان",ss:"%d ثانية",m:"دقيقة",mm:"%d دقائق",h:"ساعة",hh:"%d ساعات",d:"يوم",dd:"%d أيام",M:"شهر",MM:"%d أشهر",y:"سنة",yy:"%d سنوات"},week:{dow:1,doy:4}})}(n(5093))},1509:function(e,t,n){!function(e){"use strict";var t={1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩",0:"٠"},n={"١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","٠":"0"},i=function(e){return 0===e?0:1===e?1:2===e?2:e%100>=3&&e%100<=10?3:e%100>=11?4:5},r={s:["أقل من ثانية","ثانية واحدة",["ثانيتان","ثانيتين"],"%d ثوان","%d ثانية","%d ثانية"],m:["أقل من دقيقة","دقيقة واحدة",["دقيقتان","دقيقتين"],"%d دقائق","%d دقيقة","%d دقيقة"],h:["أقل من ساعة","ساعة واحدة",["ساعتان","ساعتين"],"%d ساعات","%d ساعة","%d ساعة"],d:["أقل من يوم","يوم واحد",["يومان","يومين"],"%d أيام","%d يومًا","%d يوم"],M:["أقل من شهر","شهر واحد",["شهران","شهرين"],"%d أشهر","%d شهرا","%d شهر"],y:["أقل من عام","عام واحد",["عامان","عامين"],"%d أعوام","%d عامًا","%d عام"]},a=function(e){return function(t,n,a,s){var o=i(t),u=r[e][i(t)];return 2===o&&(u=u[n?0:1]),u.replace(/%d/i,t)}},s=["يناير","فبراير","مارس","أبريل","مايو","يونيو","يوليو","أغسطس","سبتمبر","أكتوبر","نوفمبر","ديسمبر"];e.defineLocale("ar",{months:s,monthsShort:s,weekdays:"الأحد_الإثنين_الثلاثاء_الأربعاء_الخميس_الجمعة_السبت".split("_"),weekdaysShort:"أحد_إثنين_ثلاثاء_أربعاء_خميس_جمعة_سبت".split("_"),weekdaysMin:"ح_ن_ث_ر_خ_ج_س".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"D/M/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},meridiemParse:/ص|م/,isPM:function(e){return"م"===e},meridiem:function(e,t,n){return e<12?"ص":"م"},calendar:{sameDay:"[اليوم عند الساعة] LT",nextDay:"[غدًا عند الساعة] LT",nextWeek:"dddd [عند الساعة] LT",lastDay:"[أمس عند الساعة] LT",lastWeek:"dddd [عند الساعة] LT",sameElse:"L"},relativeTime:{future:"بعد %s",past:"منذ %s",s:a("s"),ss:a("s"),m:a("m"),mm:a("m"),h:a("h"),hh:a("h"),d:a("d"),dd:a("d"),M:a("M"),MM:a("M"),y:a("y"),yy:a("y")},preparse:function(e){return e.replace(/[١٢٣٤٥٦٧٨٩٠]/g,(function(e){return n[e]})).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]})).replace(/,/g,"،")},week:{dow:6,doy:12}})}(n(5093))},5533:function(e,t,n){!function(e){"use strict";var t={1:"-inci",5:"-inci",8:"-inci",70:"-inci",80:"-inci",2:"-nci",7:"-nci",20:"-nci",50:"-nci",3:"-üncü",4:"-üncü",100:"-üncü",6:"-ncı",9:"-uncu",10:"-uncu",30:"-uncu",60:"-ıncı",90:"-ıncı"};e.defineLocale("az",{months:"yanvar_fevral_mart_aprel_may_iyun_iyul_avqust_sentyabr_oktyabr_noyabr_dekabr".split("_"),monthsShort:"yan_fev_mar_apr_may_iyn_iyl_avq_sen_okt_noy_dek".split("_"),weekdays:"Bazar_Bazar ertəsi_Çərşənbə axşamı_Çərşənbə_Cümə axşamı_Cümə_Şənbə".split("_"),weekdaysShort:"Baz_BzE_ÇAx_Çər_CAx_Cüm_Şən".split("_"),weekdaysMin:"Bz_BE_ÇA_Çə_CA_Cü_Şə".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[bugün saat] LT",nextDay:"[sabah saat] LT",nextWeek:"[gələn həftə] dddd [saat] LT",lastDay:"[dünən] LT",lastWeek:"[keçən həftə] dddd [saat] LT",sameElse:"L"},relativeTime:{future:"%s sonra",past:"%s əvvəl",s:"bir neçə saniyə",ss:"%d saniyə",m:"bir dəqiqə",mm:"%d dəqiqə",h:"bir saat",hh:"%d saat",d:"bir gün",dd:"%d gün",M:"bir ay",MM:"%d ay",y:"bir il",yy:"%d il"},meridiemParse:/gecə|səhər|gündüz|axşam/,isPM:function(e){return/^(gündüz|axşam)$/.test(e)},meridiem:function(e,t,n){return e<4?"gecə":e<12?"səhər":e<17?"gündüz":"axşam"},dayOfMonthOrdinalParse:/\d{1,2}-(ıncı|inci|nci|üncü|ncı|uncu)/,ordinal:function(e){if(0===e)return e+"-ıncı";var n=e%10;return e+(t[n]||t[e%100-n]||t[e>=100?100:null])},week:{dow:1,doy:7}})}(n(5093))},8959:function(e,t,n){!function(e){"use strict";function t(e,t,n){return"m"===n?t?"хвіліна":"хвіліну":"h"===n?t?"гадзіна":"гадзіну":e+" "+(i=+e,r={ss:t?"секунда_секунды_секунд":"секунду_секунды_секунд",mm:t?"хвіліна_хвіліны_хвілін":"хвіліну_хвіліны_хвілін",hh:t?"гадзіна_гадзіны_гадзін":"гадзіну_гадзіны_гадзін",dd:"дзень_дні_дзён",MM:"месяц_месяцы_месяцаў",yy:"год_гады_гадоў"}[n].split("_"),i%10==1&&i%100!=11?r[0]:i%10>=2&&i%10<=4&&(i%100<10||i%100>=20)?r[1]:r[2]);var i,r}e.defineLocale("be",{months:{format:"студзеня_лютага_сакавіка_красавіка_траўня_чэрвеня_ліпеня_жніўня_верасня_кастрычніка_лістапада_снежня".split("_"),standalone:"студзень_люты_сакавік_красавік_травень_чэрвень_ліпень_жнівень_верасень_кастрычнік_лістапад_снежань".split("_")},monthsShort:"студ_лют_сак_крас_трав_чэрв_ліп_жнів_вер_каст_ліст_снеж".split("_"),weekdays:{format:"нядзелю_панядзелак_аўторак_сераду_чацвер_пятніцу_суботу".split("_"),standalone:"нядзеля_панядзелак_аўторак_серада_чацвер_пятніца_субота".split("_"),isFormat:/\[ ?[Ууў] ?(?:мінулую|наступную)? ?\] ?dddd/},weekdaysShort:"нд_пн_ат_ср_чц_пт_сб".split("_"),weekdaysMin:"нд_пн_ат_ср_чц_пт_сб".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY г.",LLL:"D MMMM YYYY г., HH:mm",LLLL:"dddd, D MMMM YYYY г., HH:mm"},calendar:{sameDay:"[Сёння ў] LT",nextDay:"[Заўтра ў] LT",lastDay:"[Учора ў] LT",nextWeek:function(){return"[У] dddd [ў] LT"},lastWeek:function(){switch(this.day()){case 0:case 3:case 5:case 6:return"[У мінулую] dddd [ў] LT";case 1:case 2:case 4:return"[У мінулы] dddd [ў] LT"}},sameElse:"L"},relativeTime:{future:"праз %s",past:"%s таму",s:"некалькі секунд",m:t,mm:t,h:t,hh:t,d:"дзень",dd:t,M:"месяц",MM:t,y:"год",yy:t},meridiemParse:/ночы|раніцы|дня|вечара/,isPM:function(e){return/^(дня|вечара)$/.test(e)},meridiem:function(e,t,n){return e<4?"ночы":e<12?"раніцы":e<17?"дня":"вечара"},dayOfMonthOrdinalParse:/\d{1,2}-(і|ы|га)/,ordinal:function(e,t){switch(t){case"M":case"d":case"DDD":case"w":case"W":return e%10!=2&&e%10!=3||e%100==12||e%100==13?e+"-ы":e+"-і";case"D":return e+"-га";default:return e}},week:{dow:1,doy:7}})}(n(5093))},7777:function(e,t,n){!function(e){"use strict";e.defineLocale("bg",{months:"януари_февруари_март_април_май_юни_юли_август_септември_октомври_ноември_декември".split("_"),monthsShort:"яну_фев_мар_апр_май_юни_юли_авг_сеп_окт_ное_дек".split("_"),weekdays:"неделя_понеделник_вторник_сряда_четвъртък_петък_събота".split("_"),weekdaysShort:"нед_пон_вто_сря_чет_пет_съб".split("_"),weekdaysMin:"нд_пн_вт_ср_чт_пт_сб".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"D.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY H:mm",LLLL:"dddd, D MMMM YYYY H:mm"},calendar:{sameDay:"[Днес в] LT",nextDay:"[Утре в] LT",nextWeek:"dddd [в] LT",lastDay:"[Вчера в] LT",lastWeek:function(){switch(this.day()){case 0:case 3:case 6:return"[Миналата] dddd [в] LT";case 1:case 2:case 4:case 5:return"[Миналия] dddd [в] LT"}},sameElse:"L"},relativeTime:{future:"след %s",past:"преди %s",s:"няколко секунди",ss:"%d секунди",m:"минута",mm:"%d минути",h:"час",hh:"%d часа",d:"ден",dd:"%d дена",w:"седмица",ww:"%d седмици",M:"месец",MM:"%d месеца",y:"година",yy:"%d години"},dayOfMonthOrdinalParse:/\d{1,2}-(ев|ен|ти|ви|ри|ми)/,ordinal:function(e){var t=e%10,n=e%100;return 0===e?e+"-ев":0===n?e+"-ен":n>10&&n<20?e+"-ти":1===t?e+"-ви":2===t?e+"-ри":7===t||8===t?e+"-ми":e+"-ти"},week:{dow:1,doy:7}})}(n(5093))},4903:function(e,t,n){!function(e){"use strict";e.defineLocale("bm",{months:"Zanwuyekalo_Fewuruyekalo_Marisikalo_Awirilikalo_Mɛkalo_Zuwɛnkalo_Zuluyekalo_Utikalo_Sɛtanburukalo_ɔkutɔburukalo_Nowanburukalo_Desanburukalo".split("_"),monthsShort:"Zan_Few_Mar_Awi_Mɛ_Zuw_Zul_Uti_Sɛt_ɔku_Now_Des".split("_"),weekdays:"Kari_Ntɛnɛn_Tarata_Araba_Alamisa_Juma_Sibiri".split("_"),weekdaysShort:"Kar_Ntɛ_Tar_Ara_Ala_Jum_Sib".split("_"),weekdaysMin:"Ka_Nt_Ta_Ar_Al_Ju_Si".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"MMMM [tile] D [san] YYYY",LLL:"MMMM [tile] D [san] YYYY [lɛrɛ] HH:mm",LLLL:"dddd MMMM [tile] D [san] YYYY [lɛrɛ] HH:mm"},calendar:{sameDay:"[Bi lɛrɛ] LT",nextDay:"[Sini lɛrɛ] LT",nextWeek:"dddd [don lɛrɛ] LT",lastDay:"[Kunu lɛrɛ] LT",lastWeek:"dddd [tɛmɛnen lɛrɛ] LT",sameElse:"L"},relativeTime:{future:"%s kɔnɔ",past:"a bɛ %s bɔ",s:"sanga dama dama",ss:"sekondi %d",m:"miniti kelen",mm:"miniti %d",h:"lɛrɛ kelen",hh:"lɛrɛ %d",d:"tile kelen",dd:"tile %d",M:"kalo kelen",MM:"kalo %d",y:"san kelen",yy:"san %d"},week:{dow:1,doy:4}})}(n(5093))},7357:function(e,t,n){!function(e){"use strict";var t={1:"১",2:"২",3:"৩",4:"৪",5:"৫",6:"৬",7:"৭",8:"৮",9:"৯",0:"০"},n={"১":"1","২":"2","৩":"3","৪":"4","৫":"5","৬":"6","৭":"7","৮":"8","৯":"9","০":"0"};e.defineLocale("bn-bd",{months:"জানুয়ারি_ফেব্রুয়ারি_মার্চ_এপ্রিল_মে_জুন_জুলাই_আগস্ট_সেপ্টেম্বর_অক্টোবর_নভেম্বর_ডিসেম্বর".split("_"),monthsShort:"জানু_ফেব্রু_মার্চ_এপ্রিল_মে_জুন_জুলাই_আগস্ট_সেপ্ট_অক্টো_নভে_ডিসে".split("_"),weekdays:"রবিবার_সোমবার_মঙ্গলবার_বুধবার_বৃহস্পতিবার_শুক্রবার_শনিবার".split("_"),weekdaysShort:"রবি_সোম_মঙ্গল_বুধ_বৃহস্পতি_শুক্র_শনি".split("_"),weekdaysMin:"রবি_সোম_মঙ্গল_বুধ_বৃহ_শুক্র_শনি".split("_"),longDateFormat:{LT:"A h:mm সময়",LTS:"A h:mm:ss সময়",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm সময়",LLLL:"dddd, D MMMM YYYY, A h:mm সময়"},calendar:{sameDay:"[আজ] LT",nextDay:"[আগামীকাল] LT",nextWeek:"dddd, LT",lastDay:"[গতকাল] LT",lastWeek:"[গত] dddd, LT",sameElse:"L"},relativeTime:{future:"%s পরে",past:"%s আগে",s:"কয়েক সেকেন্ড",ss:"%d সেকেন্ড",m:"এক মিনিট",mm:"%d মিনিট",h:"এক ঘন্টা",hh:"%d ঘন্টা",d:"এক দিন",dd:"%d দিন",M:"এক মাস",MM:"%d মাস",y:"এক বছর",yy:"%d বছর"},preparse:function(e){return e.replace(/[১২৩৪৫৬৭৮৯০]/g,(function(e){return n[e]}))},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]}))},meridiemParse:/রাত|ভোর|সকাল|দুপুর|বিকাল|সন্ধ্যা|রাত/,meridiemHour:function(e,t){return 12===e&&(e=0),"রাত"===t?e<4?e:e+12:"ভোর"===t||"সকাল"===t?e:"দুপুর"===t?e>=3?e:e+12:"বিকাল"===t||"সন্ধ্যা"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"রাত":e<6?"ভোর":e<12?"সকাল":e<15?"দুপুর":e<18?"বিকাল":e<20?"সন্ধ্যা":"রাত"},week:{dow:0,doy:6}})}(n(5093))},1290:function(e,t,n){!function(e){"use strict";var t={1:"১",2:"২",3:"৩",4:"৪",5:"৫",6:"৬",7:"৭",8:"৮",9:"৯",0:"০"},n={"১":"1","২":"2","৩":"3","৪":"4","৫":"5","৬":"6","৭":"7","৮":"8","৯":"9","০":"0"};e.defineLocale("bn",{months:"জানুয়ারি_ফেব্রুয়ারি_মার্চ_এপ্রিল_মে_জুন_জুলাই_আগস্ট_সেপ্টেম্বর_অক্টোবর_নভেম্বর_ডিসেম্বর".split("_"),monthsShort:"জানু_ফেব্রু_মার্চ_এপ্রিল_মে_জুন_জুলাই_আগস্ট_সেপ্ট_অক্টো_নভে_ডিসে".split("_"),weekdays:"রবিবার_সোমবার_মঙ্গলবার_বুধবার_বৃহস্পতিবার_শুক্রবার_শনিবার".split("_"),weekdaysShort:"রবি_সোম_মঙ্গল_বুধ_বৃহস্পতি_শুক্র_শনি".split("_"),weekdaysMin:"রবি_সোম_মঙ্গল_বুধ_বৃহ_শুক্র_শনি".split("_"),longDateFormat:{LT:"A h:mm সময়",LTS:"A h:mm:ss সময়",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm সময়",LLLL:"dddd, D MMMM YYYY, A h:mm সময়"},calendar:{sameDay:"[আজ] LT",nextDay:"[আগামীকাল] LT",nextWeek:"dddd, LT",lastDay:"[গতকাল] LT",lastWeek:"[গত] dddd, LT",sameElse:"L"},relativeTime:{future:"%s পরে",past:"%s আগে",s:"কয়েক সেকেন্ড",ss:"%d সেকেন্ড",m:"এক মিনিট",mm:"%d মিনিট",h:"এক ঘন্টা",hh:"%d ঘন্টা",d:"এক দিন",dd:"%d দিন",M:"এক মাস",MM:"%d মাস",y:"এক বছর",yy:"%d বছর"},preparse:function(e){return e.replace(/[১২৩৪৫৬৭৮৯০]/g,(function(e){return n[e]}))},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]}))},meridiemParse:/রাত|সকাল|দুপুর|বিকাল|রাত/,meridiemHour:function(e,t){return 12===e&&(e=0),"রাত"===t&&e>=4||"দুপুর"===t&&e<5||"বিকাল"===t?e+12:e},meridiem:function(e,t,n){return e<4?"রাত":e<10?"সকাল":e<17?"দুপুর":e<20?"বিকাল":"রাত"},week:{dow:0,doy:6}})}(n(5093))},1545:function(e,t,n){!function(e){"use strict";var t={1:"༡",2:"༢",3:"༣",4:"༤",5:"༥",6:"༦",7:"༧",8:"༨",9:"༩",0:"༠"},n={"༡":"1","༢":"2","༣":"3","༤":"4","༥":"5","༦":"6","༧":"7","༨":"8","༩":"9","༠":"0"};e.defineLocale("bo",{months:"ཟླ་བ་དང་པོ_ཟླ་བ་གཉིས་པ_ཟླ་བ་གསུམ་པ_ཟླ་བ་བཞི་པ_ཟླ་བ་ལྔ་པ_ཟླ་བ་དྲུག་པ_ཟླ་བ་བདུན་པ_ཟླ་བ་བརྒྱད་པ_ཟླ་བ་དགུ་པ_ཟླ་བ་བཅུ་པ_ཟླ་བ་བཅུ་གཅིག་པ_ཟླ་བ་བཅུ་གཉིས་པ".split("_"),monthsShort:"ཟླ་1_ཟླ་2_ཟླ་3_ཟླ་4_ཟླ་5_ཟླ་6_ཟླ་7_ཟླ་8_ཟླ་9_ཟླ་10_ཟླ་11_ཟླ་12".split("_"),monthsShortRegex:/^(ཟླ་\d{1,2})/,monthsParseExact:!0,weekdays:"གཟའ་ཉི་མ་_གཟའ་ཟླ་བ་_གཟའ་མིག་དམར་_གཟའ་ལྷག་པ་_གཟའ་ཕུར་བུ_གཟའ་པ་སངས་_གཟའ་སྤེན་པ་".split("_"),weekdaysShort:"ཉི་མ་_ཟླ་བ་_མིག་དམར་_ལྷག་པ་_ཕུར་བུ_པ་སངས་_སྤེན་པ་".split("_"),weekdaysMin:"ཉི_ཟླ_མིག_ལྷག_ཕུར_སངས_སྤེན".split("_"),longDateFormat:{LT:"A h:mm",LTS:"A h:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm",LLLL:"dddd, D MMMM YYYY, A h:mm"},calendar:{sameDay:"[དི་རིང] LT",nextDay:"[སང་ཉིན] LT",nextWeek:"[བདུན་ཕྲག་རྗེས་མ], LT",lastDay:"[ཁ་སང] LT",lastWeek:"[བདུན་ཕྲག་མཐའ་མ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s ལ་",past:"%s སྔན་ལ",s:"ལམ་སང",ss:"%d སྐར་ཆ།",m:"སྐར་མ་གཅིག",mm:"%d སྐར་མ",h:"ཆུ་ཚོད་གཅིག",hh:"%d ཆུ་ཚོད",d:"ཉིན་གཅིག",dd:"%d ཉིན་",M:"ཟླ་བ་གཅིག",MM:"%d ཟླ་བ",y:"ལོ་གཅིག",yy:"%d ལོ"},preparse:function(e){return e.replace(/[༡༢༣༤༥༦༧༨༩༠]/g,(function(e){return n[e]}))},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]}))},meridiemParse:/མཚན་མོ|ཞོགས་ཀས|ཉིན་གུང|དགོང་དག|མཚན་མོ/,meridiemHour:function(e,t){return 12===e&&(e=0),"མཚན་མོ"===t&&e>=4||"ཉིན་གུང"===t&&e<5||"དགོང་དག"===t?e+12:e},meridiem:function(e,t,n){return e<4?"མཚན་མོ":e<10?"ཞོགས་ཀས":e<17?"ཉིན་གུང":e<20?"དགོང་དག":"མཚན་མོ"},week:{dow:0,doy:6}})}(n(5093))},1470:function(e,t,n){!function(e){"use strict";function t(e,t,n){return e+" "+function(e,t){return 2===t?function(e){var t={m:"v",b:"v",d:"z"};return void 0===t[e.charAt(0)]?e:t[e.charAt(0)]+e.substring(1)}(e):e}({mm:"munutenn",MM:"miz",dd:"devezh"}[n],e)}function n(e){return e>9?n(e%10):e}var i=[/^gen/i,/^c[ʼ\']hwe/i,/^meu/i,/^ebr/i,/^mae/i,/^(mez|eve)/i,/^gou/i,/^eos/i,/^gwe/i,/^her/i,/^du/i,/^ker/i],r=/^(genver|c[ʼ\']hwevrer|meurzh|ebrel|mae|mezheven|gouere|eost|gwengolo|here|du|kerzu|gen|c[ʼ\']hwe|meu|ebr|mae|eve|gou|eos|gwe|her|du|ker)/i,a=[/^Su/i,/^Lu/i,/^Me([^r]|$)/i,/^Mer/i,/^Ya/i,/^Gw/i,/^Sa/i];e.defineLocale("br",{months:"Genver_Cʼhwevrer_Meurzh_Ebrel_Mae_Mezheven_Gouere_Eost_Gwengolo_Here_Du_Kerzu".split("_"),monthsShort:"Gen_Cʼhwe_Meu_Ebr_Mae_Eve_Gou_Eos_Gwe_Her_Du_Ker".split("_"),weekdays:"Sul_Lun_Meurzh_Mercʼher_Yaou_Gwener_Sadorn".split("_"),weekdaysShort:"Sul_Lun_Meu_Mer_Yao_Gwe_Sad".split("_"),weekdaysMin:"Su_Lu_Me_Mer_Ya_Gw_Sa".split("_"),weekdaysParse:a,fullWeekdaysParse:[/^sul/i,/^lun/i,/^meurzh/i,/^merc[ʼ\']her/i,/^yaou/i,/^gwener/i,/^sadorn/i],shortWeekdaysParse:[/^Sul/i,/^Lun/i,/^Meu/i,/^Mer/i,/^Yao/i,/^Gwe/i,/^Sad/i],minWeekdaysParse:a,monthsRegex:r,monthsShortRegex:r,monthsStrictRegex:/^(genver|c[ʼ\']hwevrer|meurzh|ebrel|mae|mezheven|gouere|eost|gwengolo|here|du|kerzu)/i,monthsShortStrictRegex:/^(gen|c[ʼ\']hwe|meu|ebr|mae|eve|gou|eos|gwe|her|du|ker)/i,monthsParse:i,longMonthsParse:i,shortMonthsParse:i,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [a viz] MMMM YYYY",LLL:"D [a viz] MMMM YYYY HH:mm",LLLL:"dddd, D [a viz] MMMM YYYY HH:mm"},calendar:{sameDay:"[Hiziv da] LT",nextDay:"[Warcʼhoazh da] LT",nextWeek:"dddd [da] LT",lastDay:"[Decʼh da] LT",lastWeek:"dddd [paset da] LT",sameElse:"L"},relativeTime:{future:"a-benn %s",past:"%s ʼzo",s:"un nebeud segondennoù",ss:"%d eilenn",m:"ur vunutenn",mm:t,h:"un eur",hh:"%d eur",d:"un devezh",dd:t,M:"ur miz",MM:t,y:"ur bloaz",yy:function(e){switch(n(e)){case 1:case 3:case 4:case 5:case 9:return e+" bloaz";default:return e+" vloaz"}}},dayOfMonthOrdinalParse:/\d{1,2}(añ|vet)/,ordinal:function(e){return e+(1===e?"añ":"vet")},week:{dow:1,doy:4},meridiemParse:/a.m.|g.m./,isPM:function(e){return"g.m."===e},meridiem:function(e,t,n){return e<12?"a.m.":"g.m."}})}(n(5093))},4429:function(e,t,n){!function(e){"use strict";function t(e,t,n){var i=e+" ";switch(n){case"ss":return i+(1===e?"sekunda":2===e||3===e||4===e?"sekunde":"sekundi");case"mm":return i+(1===e?"minuta":2===e||3===e||4===e?"minute":"minuta");case"h":return"jedan sat";case"hh":return i+(1===e?"sat":2===e||3===e||4===e?"sata":"sati");case"dd":return i+(1===e?"dan":"dana");case"MM":return i+(1===e?"mjesec":2===e||3===e||4===e?"mjeseca":"mjeseci");case"yy":return i+(1===e?"godina":2===e||3===e||4===e?"godine":"godina")}}e.defineLocale("bs",{months:"januar_februar_mart_april_maj_juni_juli_august_septembar_oktobar_novembar_decembar".split("_"),monthsShort:"jan._feb._mar._apr._maj._jun._jul._aug._sep._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sri._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd, D. MMMM YYYY H:mm"},calendar:{sameDay:"[danas u] LT",nextDay:"[sutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedjelju] [u] LT";case 3:return"[u] [srijedu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[jučer u] LT",lastWeek:function(){switch(this.day()){case 0:case 3:return"[prošlu] dddd [u] LT";case 6:return"[prošle] [subote] [u] LT";case 1:case 2:case 4:case 5:return"[prošli] dddd [u] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"prije %s",s:"par sekundi",ss:t,m:function(e,t,n,i){if("m"===n)return t?"jedna minuta":i?"jednu minutu":"jedne minute"},mm:t,h:t,hh:t,d:"dan",dd:t,M:"mjesec",MM:t,y:"godinu",yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(5093))},7306:function(e,t,n){!function(e){"use strict";e.defineLocale("ca",{months:{standalone:"gener_febrer_març_abril_maig_juny_juliol_agost_setembre_octubre_novembre_desembre".split("_"),format:"de gener_de febrer_de març_d'abril_de maig_de juny_de juliol_d'agost_de setembre_d'octubre_de novembre_de desembre".split("_"),isFormat:/D[oD]?(\s)+MMMM/},monthsShort:"gen._febr._març_abr._maig_juny_jul._ag._set._oct._nov._des.".split("_"),monthsParseExact:!0,weekdays:"diumenge_dilluns_dimarts_dimecres_dijous_divendres_dissabte".split("_"),weekdaysShort:"dg._dl._dt._dc._dj._dv._ds.".split("_"),weekdaysMin:"dg_dl_dt_dc_dj_dv_ds".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM [de] YYYY",ll:"D MMM YYYY",LLL:"D MMMM [de] YYYY [a les] H:mm",lll:"D MMM YYYY, H:mm",LLLL:"dddd D MMMM [de] YYYY [a les] H:mm",llll:"ddd D MMM YYYY, H:mm"},calendar:{sameDay:function(){return"[avui a "+(1!==this.hours()?"les":"la")+"] LT"},nextDay:function(){return"[demà a "+(1!==this.hours()?"les":"la")+"] LT"},nextWeek:function(){return"dddd [a "+(1!==this.hours()?"les":"la")+"] LT"},lastDay:function(){return"[ahir a "+(1!==this.hours()?"les":"la")+"] LT"},lastWeek:function(){return"[el] dddd [passat a "+(1!==this.hours()?"les":"la")+"] LT"},sameElse:"L"},relativeTime:{future:"d'aquí %s",past:"fa %s",s:"uns segons",ss:"%d segons",m:"un minut",mm:"%d minuts",h:"una hora",hh:"%d hores",d:"un dia",dd:"%d dies",M:"un mes",MM:"%d mesos",y:"un any",yy:"%d anys"},dayOfMonthOrdinalParse:/\d{1,2}(r|n|t|è|a)/,ordinal:function(e,t){var n=1===e?"r":2===e?"n":3===e?"r":4===e?"t":"è";return"w"!==t&&"W"!==t||(n="a"),e+n},week:{dow:1,doy:4}})}(n(5093))},6464:function(e,t,n){!function(e){"use strict";var t={standalone:"leden_únor_březen_duben_květen_červen_červenec_srpen_září_říjen_listopad_prosinec".split("_"),format:"ledna_února_března_dubna_května_června_července_srpna_září_října_listopadu_prosince".split("_"),isFormat:/DD?[o.]?(\[[^\[\]]*\]|\s)+MMMM/},n="led_úno_bře_dub_kvě_čvn_čvc_srp_zář_říj_lis_pro".split("_"),i=[/^led/i,/^úno/i,/^bře/i,/^dub/i,/^kvě/i,/^(čvn|červen$|června)/i,/^(čvc|červenec|července)/i,/^srp/i,/^zář/i,/^říj/i,/^lis/i,/^pro/i],r=/^(leden|únor|březen|duben|květen|červenec|července|červen|června|srpen|září|říjen|listopad|prosinec|led|úno|bře|dub|kvě|čvn|čvc|srp|zář|říj|lis|pro)/i;function a(e){return e>1&&e<5&&1!=~~(e/10)}function s(e,t,n,i){var r=e+" ";switch(n){case"s":return t||i?"pár sekund":"pár sekundami";case"ss":return t||i?r+(a(e)?"sekundy":"sekund"):r+"sekundami";case"m":return t?"minuta":i?"minutu":"minutou";case"mm":return t||i?r+(a(e)?"minuty":"minut"):r+"minutami";case"h":return t?"hodina":i?"hodinu":"hodinou";case"hh":return t||i?r+(a(e)?"hodiny":"hodin"):r+"hodinami";case"d":return t||i?"den":"dnem";case"dd":return t||i?r+(a(e)?"dny":"dní"):r+"dny";case"M":return t||i?"měsíc":"měsícem";case"MM":return t||i?r+(a(e)?"měsíce":"měsíců"):r+"měsíci";case"y":return t||i?"rok":"rokem";case"yy":return t||i?r+(a(e)?"roky":"let"):r+"lety"}}e.defineLocale("cs",{months:t,monthsShort:n,monthsRegex:r,monthsShortRegex:r,monthsStrictRegex:/^(leden|ledna|února|únor|březen|března|duben|dubna|květen|května|červenec|července|červen|června|srpen|srpna|září|říjen|října|listopadu|listopad|prosinec|prosince)/i,monthsShortStrictRegex:/^(led|úno|bře|dub|kvě|čvn|čvc|srp|zář|říj|lis|pro)/i,monthsParse:i,longMonthsParse:i,shortMonthsParse:i,weekdays:"neděle_pondělí_úterý_středa_čtvrtek_pátek_sobota".split("_"),weekdaysShort:"ne_po_út_st_čt_pá_so".split("_"),weekdaysMin:"ne_po_út_st_čt_pá_so".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd D. MMMM YYYY H:mm",l:"D. M. YYYY"},calendar:{sameDay:"[dnes v] LT",nextDay:"[zítra v] LT",nextWeek:function(){switch(this.day()){case 0:return"[v neděli v] LT";case 1:case 2:return"[v] dddd [v] LT";case 3:return"[ve středu v] LT";case 4:return"[ve čtvrtek v] LT";case 5:return"[v pátek v] LT";case 6:return"[v sobotu v] LT"}},lastDay:"[včera v] LT",lastWeek:function(){switch(this.day()){case 0:return"[minulou neděli v] LT";case 1:case 2:return"[minulé] dddd [v] LT";case 3:return"[minulou středu v] LT";case 4:case 5:return"[minulý] dddd [v] LT";case 6:return"[minulou sobotu v] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"před %s",s,ss:s,m:s,mm:s,h:s,hh:s,d:s,dd:s,M:s,MM:s,y:s,yy:s},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},3635:function(e,t,n){!function(e){"use strict";e.defineLocale("cv",{months:"кӑрлач_нарӑс_пуш_ака_май_ҫӗртме_утӑ_ҫурла_авӑн_юпа_чӳк_раштав".split("_"),monthsShort:"кӑр_нар_пуш_ака_май_ҫӗр_утӑ_ҫур_авн_юпа_чӳк_раш".split("_"),weekdays:"вырсарникун_тунтикун_ытларикун_юнкун_кӗҫнерникун_эрнекун_шӑматкун".split("_"),weekdaysShort:"выр_тун_ытл_юн_кӗҫ_эрн_шӑм".split("_"),weekdaysMin:"вр_тн_ыт_юн_кҫ_эр_шм".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD-MM-YYYY",LL:"YYYY [ҫулхи] MMMM [уйӑхӗн] D[-мӗшӗ]",LLL:"YYYY [ҫулхи] MMMM [уйӑхӗн] D[-мӗшӗ], HH:mm",LLLL:"dddd, YYYY [ҫулхи] MMMM [уйӑхӗн] D[-мӗшӗ], HH:mm"},calendar:{sameDay:"[Паян] LT [сехетре]",nextDay:"[Ыран] LT [сехетре]",lastDay:"[Ӗнер] LT [сехетре]",nextWeek:"[Ҫитес] dddd LT [сехетре]",lastWeek:"[Иртнӗ] dddd LT [сехетре]",sameElse:"L"},relativeTime:{future:function(e){return e+(/сехет$/i.exec(e)?"рен":/ҫул$/i.exec(e)?"тан":"ран")},past:"%s каялла",s:"пӗр-ик ҫеккунт",ss:"%d ҫеккунт",m:"пӗр минут",mm:"%d минут",h:"пӗр сехет",hh:"%d сехет",d:"пӗр кун",dd:"%d кун",M:"пӗр уйӑх",MM:"%d уйӑх",y:"пӗр ҫул",yy:"%d ҫул"},dayOfMonthOrdinalParse:/\d{1,2}-мӗш/,ordinal:"%d-мӗш",week:{dow:1,doy:7}})}(n(5093))},4226:function(e,t,n){!function(e){"use strict";e.defineLocale("cy",{months:"Ionawr_Chwefror_Mawrth_Ebrill_Mai_Mehefin_Gorffennaf_Awst_Medi_Hydref_Tachwedd_Rhagfyr".split("_"),monthsShort:"Ion_Chwe_Maw_Ebr_Mai_Meh_Gor_Aws_Med_Hyd_Tach_Rhag".split("_"),weekdays:"Dydd Sul_Dydd Llun_Dydd Mawrth_Dydd Mercher_Dydd Iau_Dydd Gwener_Dydd Sadwrn".split("_"),weekdaysShort:"Sul_Llun_Maw_Mer_Iau_Gwe_Sad".split("_"),weekdaysMin:"Su_Ll_Ma_Me_Ia_Gw_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Heddiw am] LT",nextDay:"[Yfory am] LT",nextWeek:"dddd [am] LT",lastDay:"[Ddoe am] LT",lastWeek:"dddd [diwethaf am] LT",sameElse:"L"},relativeTime:{future:"mewn %s",past:"%s yn ôl",s:"ychydig eiliadau",ss:"%d eiliad",m:"munud",mm:"%d munud",h:"awr",hh:"%d awr",d:"diwrnod",dd:"%d diwrnod",M:"mis",MM:"%d mis",y:"blwyddyn",yy:"%d flynedd"},dayOfMonthOrdinalParse:/\d{1,2}(fed|ain|af|il|ydd|ed|eg)/,ordinal:function(e){var t="";return e>20?t=40===e||50===e||60===e||80===e||100===e?"fed":"ain":e>0&&(t=["","af","il","ydd","ydd","ed","ed","ed","fed","fed","fed","eg","fed","eg","eg","fed","eg","eg","fed","eg","fed"][e]),e+t},week:{dow:1,doy:4}})}(n(5093))},3601:function(e,t,n){!function(e){"use strict";e.defineLocale("da",{months:"januar_februar_marts_april_maj_juni_juli_august_september_oktober_november_december".split("_"),monthsShort:"jan_feb_mar_apr_maj_jun_jul_aug_sep_okt_nov_dec".split("_"),weekdays:"søndag_mandag_tirsdag_onsdag_torsdag_fredag_lørdag".split("_"),weekdaysShort:"søn_man_tir_ons_tor_fre_lør".split("_"),weekdaysMin:"sø_ma_ti_on_to_fr_lø".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd [d.] D. MMMM YYYY [kl.] HH:mm"},calendar:{sameDay:"[i dag kl.] LT",nextDay:"[i morgen kl.] LT",nextWeek:"på dddd [kl.] LT",lastDay:"[i går kl.] LT",lastWeek:"[i] dddd[s kl.] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"%s siden",s:"få sekunder",ss:"%d sekunder",m:"et minut",mm:"%d minutter",h:"en time",hh:"%d timer",d:"en dag",dd:"%d dage",M:"en måned",MM:"%d måneder",y:"et år",yy:"%d år"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},6111:function(e,t,n){!function(e){"use strict";function t(e,t,n,i){var r={m:["eine Minute","einer Minute"],h:["eine Stunde","einer Stunde"],d:["ein Tag","einem Tag"],dd:[e+" Tage",e+" Tagen"],w:["eine Woche","einer Woche"],M:["ein Monat","einem Monat"],MM:[e+" Monate",e+" Monaten"],y:["ein Jahr","einem Jahr"],yy:[e+" Jahre",e+" Jahren"]};return t?r[n][0]:r[n][1]}e.defineLocale("de-at",{months:"Jänner_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jän._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.".split("_"),monthsParseExact:!0,weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},calendar:{sameDay:"[heute um] LT [Uhr]",sameElse:"L",nextDay:"[morgen um] LT [Uhr]",nextWeek:"dddd [um] LT [Uhr]",lastDay:"[gestern um] LT [Uhr]",lastWeek:"[letzten] dddd [um] LT [Uhr]"},relativeTime:{future:"in %s",past:"vor %s",s:"ein paar Sekunden",ss:"%d Sekunden",m:t,mm:"%d Minuten",h:t,hh:"%d Stunden",d:t,dd:t,w:t,ww:"%d Wochen",M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},4697:function(e,t,n){!function(e){"use strict";function t(e,t,n,i){var r={m:["eine Minute","einer Minute"],h:["eine Stunde","einer Stunde"],d:["ein Tag","einem Tag"],dd:[e+" Tage",e+" Tagen"],w:["eine Woche","einer Woche"],M:["ein Monat","einem Monat"],MM:[e+" Monate",e+" Monaten"],y:["ein Jahr","einem Jahr"],yy:[e+" Jahre",e+" Jahren"]};return t?r[n][0]:r[n][1]}e.defineLocale("de-ch",{months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.".split("_"),monthsParseExact:!0,weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},calendar:{sameDay:"[heute um] LT [Uhr]",sameElse:"L",nextDay:"[morgen um] LT [Uhr]",nextWeek:"dddd [um] LT [Uhr]",lastDay:"[gestern um] LT [Uhr]",lastWeek:"[letzten] dddd [um] LT [Uhr]"},relativeTime:{future:"in %s",past:"vor %s",s:"ein paar Sekunden",ss:"%d Sekunden",m:t,mm:"%d Minuten",h:t,hh:"%d Stunden",d:t,dd:t,w:t,ww:"%d Wochen",M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},7853:function(e,t,n){!function(e){"use strict";function t(e,t,n,i){var r={m:["eine Minute","einer Minute"],h:["eine Stunde","einer Stunde"],d:["ein Tag","einem Tag"],dd:[e+" Tage",e+" Tagen"],w:["eine Woche","einer Woche"],M:["ein Monat","einem Monat"],MM:[e+" Monate",e+" Monaten"],y:["ein Jahr","einem Jahr"],yy:[e+" Jahre",e+" Jahren"]};return t?r[n][0]:r[n][1]}e.defineLocale("de",{months:"Januar_Februar_März_April_Mai_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Feb._März_Apr._Mai_Juni_Juli_Aug._Sep._Okt._Nov._Dez.".split("_"),monthsParseExact:!0,weekdays:"Sonntag_Montag_Dienstag_Mittwoch_Donnerstag_Freitag_Samstag".split("_"),weekdaysShort:"So._Mo._Di._Mi._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mo_Di_Mi_Do_Fr_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY HH:mm",LLLL:"dddd, D. MMMM YYYY HH:mm"},calendar:{sameDay:"[heute um] LT [Uhr]",sameElse:"L",nextDay:"[morgen um] LT [Uhr]",nextWeek:"dddd [um] LT [Uhr]",lastDay:"[gestern um] LT [Uhr]",lastWeek:"[letzten] dddd [um] LT [Uhr]"},relativeTime:{future:"in %s",past:"vor %s",s:"ein paar Sekunden",ss:"%d Sekunden",m:t,mm:"%d Minuten",h:t,hh:"%d Stunden",d:t,dd:t,w:t,ww:"%d Wochen",M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},708:function(e,t,n){!function(e){"use strict";var t=["ޖެނުއަރީ","ފެބްރުއަރީ","މާރިޗު","އޭޕްރީލު","މޭ","ޖޫން","ޖުލައި","އޯގަސްޓު","ސެޕްޓެމްބަރު","އޮކްޓޯބަރު","ނޮވެމްބަރު","ޑިސެމްބަރު"],n=["އާދިއްތަ","ހޯމަ","އަންގާރަ","ބުދަ","ބުރާސްފަތި","ހުކުރު","ހޮނިހިރު"];e.defineLocale("dv",{months:t,monthsShort:t,weekdays:n,weekdaysShort:n,weekdaysMin:"އާދި_ހޯމަ_އަން_ބުދަ_ބުރާ_ހުކު_ހޮނި".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"D/M/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},meridiemParse:/މކ|މފ/,isPM:function(e){return"މފ"===e},meridiem:function(e,t,n){return e<12?"މކ":"މފ"},calendar:{sameDay:"[މިއަދު] LT",nextDay:"[މާދަމާ] LT",nextWeek:"dddd LT",lastDay:"[އިއްޔެ] LT",lastWeek:"[ފާއިތުވި] dddd LT",sameElse:"L"},relativeTime:{future:"ތެރޭގައި %s",past:"ކުރިން %s",s:"ސިކުންތުކޮޅެއް",ss:"d% ސިކުންތު",m:"މިނިޓެއް",mm:"މިނިޓު %d",h:"ގަޑިއިރެއް",hh:"ގަޑިއިރު %d",d:"ދުވަހެއް",dd:"ދުވަސް %d",M:"މަހެއް",MM:"މަސް %d",y:"އަހަރެއް",yy:"އަހަރު %d"},preparse:function(e){return e.replace(/،/g,",")},postformat:function(e){return e.replace(/,/g,"،")},week:{dow:7,doy:12}})}(n(5093))},4691:function(e,t,n){!function(e){"use strict";e.defineLocale("el",{monthsNominativeEl:"Ιανουάριος_Φεβρουάριος_Μάρτιος_Απρίλιος_Μάιος_Ιούνιος_Ιούλιος_Αύγουστος_Σεπτέμβριος_Οκτώβριος_Νοέμβριος_Δεκέμβριος".split("_"),monthsGenitiveEl:"Ιανουαρίου_Φεβρουαρίου_Μαρτίου_Απριλίου_Μαΐου_Ιουνίου_Ιουλίου_Αυγούστου_Σεπτεμβρίου_Οκτωβρίου_Νοεμβρίου_Δεκεμβρίου".split("_"),months:function(e,t){return e?"string"==typeof t&&/D/.test(t.substring(0,t.indexOf("MMMM")))?this._monthsGenitiveEl[e.month()]:this._monthsNominativeEl[e.month()]:this._monthsNominativeEl},monthsShort:"Ιαν_Φεβ_Μαρ_Απρ_Μαϊ_Ιουν_Ιουλ_Αυγ_Σεπ_Οκτ_Νοε_Δεκ".split("_"),weekdays:"Κυριακή_Δευτέρα_Τρίτη_Τετάρτη_Πέμπτη_Παρασκευή_Σάββατο".split("_"),weekdaysShort:"Κυρ_Δευ_Τρι_Τετ_Πεμ_Παρ_Σαβ".split("_"),weekdaysMin:"Κυ_Δε_Τρ_Τε_Πε_Πα_Σα".split("_"),meridiem:function(e,t,n){return e>11?n?"μμ":"ΜΜ":n?"πμ":"ΠΜ"},isPM:function(e){return"μ"===(e+"").toLowerCase()[0]},meridiemParse:/[ΠΜ]\.?Μ?\.?/i,longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendarEl:{sameDay:"[Σήμερα {}] LT",nextDay:"[Αύριο {}] LT",nextWeek:"dddd [{}] LT",lastDay:"[Χθες {}] LT",lastWeek:function(){return 6===this.day()?"[το προηγούμενο] dddd [{}] LT":"[την προηγούμενη] dddd [{}] LT"},sameElse:"L"},calendar:function(e,t){var n,i=this._calendarEl[e],r=t&&t.hours();return n=i,("undefined"!=typeof Function&&n instanceof Function||"[object Function]"===Object.prototype.toString.call(n))&&(i=i.apply(t)),i.replace("{}",r%12==1?"στη":"στις")},relativeTime:{future:"σε %s",past:"%s πριν",s:"λίγα δευτερόλεπτα",ss:"%d δευτερόλεπτα",m:"ένα λεπτό",mm:"%d λεπτά",h:"μία ώρα",hh:"%d ώρες",d:"μία μέρα",dd:"%d μέρες",M:"ένας μήνας",MM:"%d μήνες",y:"ένας χρόνος",yy:"%d χρόνια"},dayOfMonthOrdinalParse:/\d{1,2}η/,ordinal:"%dη",week:{dow:1,doy:4}})}(n(5093))},3872:function(e,t,n){!function(e){"use strict";e.defineLocale("en-au",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:0,doy:4}})}(n(5093))},8298:function(e,t,n){!function(e){"use strict";e.defineLocale("en-ca",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"YYYY-MM-DD",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")}})}(n(5093))},6195:function(e,t,n){!function(e){"use strict";e.defineLocale("en-gb",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:1,doy:4}})}(n(5093))},6584:function(e,t,n){!function(e){"use strict";e.defineLocale("en-ie",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:1,doy:4}})}(n(5093))},5543:function(e,t,n){!function(e){"use strict";e.defineLocale("en-il",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")}})}(n(5093))},9033:function(e,t,n){!function(e){"use strict";e.defineLocale("en-in",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:0,doy:6}})}(n(5093))},9402:function(e,t,n){!function(e){"use strict";e.defineLocale("en-nz",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:1,doy:4}})}(n(5093))},3004:function(e,t,n){!function(e){"use strict";e.defineLocale("en-sg",{months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),weekdaysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),weekdaysMin:"Su_Mo_Tu_We_Th_Fr_Sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:1,doy:4}})}(n(5093))},2934:function(e,t,n){!function(e){"use strict";e.defineLocale("eo",{months:"januaro_februaro_marto_aprilo_majo_junio_julio_aŭgusto_septembro_oktobro_novembro_decembro".split("_"),monthsShort:"jan_feb_mart_apr_maj_jun_jul_aŭg_sept_okt_nov_dec".split("_"),weekdays:"dimanĉo_lundo_mardo_merkredo_ĵaŭdo_vendredo_sabato".split("_"),weekdaysShort:"dim_lun_mard_merk_ĵaŭ_ven_sab".split("_"),weekdaysMin:"di_lu_ma_me_ĵa_ve_sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"[la] D[-an de] MMMM, YYYY",LLL:"[la] D[-an de] MMMM, YYYY HH:mm",LLLL:"dddd[n], [la] D[-an de] MMMM, YYYY HH:mm",llll:"ddd, [la] D[-an de] MMM, YYYY HH:mm"},meridiemParse:/[ap]\.t\.m/i,isPM:function(e){return"p"===e.charAt(0).toLowerCase()},meridiem:function(e,t,n){return e>11?n?"p.t.m.":"P.T.M.":n?"a.t.m.":"A.T.M."},calendar:{sameDay:"[Hodiaŭ je] LT",nextDay:"[Morgaŭ je] LT",nextWeek:"dddd[n je] LT",lastDay:"[Hieraŭ je] LT",lastWeek:"[pasintan] dddd[n je] LT",sameElse:"L"},relativeTime:{future:"post %s",past:"antaŭ %s",s:"kelkaj sekundoj",ss:"%d sekundoj",m:"unu minuto",mm:"%d minutoj",h:"unu horo",hh:"%d horoj",d:"unu tago",dd:"%d tagoj",M:"unu monato",MM:"%d monatoj",y:"unu jaro",yy:"%d jaroj"},dayOfMonthOrdinalParse:/\d{1,2}a/,ordinal:"%da",week:{dow:1,doy:7}})}(n(5093))},838:function(e,t,n){!function(e){"use strict";var t="ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.".split("_"),n="ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),i=[/^ene/i,/^feb/i,/^mar/i,/^abr/i,/^may/i,/^jun/i,/^jul/i,/^ago/i,/^sep/i,/^oct/i,/^nov/i,/^dic/i],r=/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i;e.defineLocale("es-do",{months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),monthsShort:function(e,i){return e?/-MMM-/.test(i)?n[e.month()]:t[e.month()]:t},monthsRegex:r,monthsShortRegex:r,monthsStrictRegex:/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,monthsShortStrictRegex:/^(ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i,monthsParse:i,longMonthsParse:i,shortMonthsParse:i,weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY h:mm A",LLLL:"dddd, D [de] MMMM [de] YYYY h:mm A"},calendar:{sameDay:function(){return"[hoy a la"+(1!==this.hours()?"s":"")+"] LT"},nextDay:function(){return"[mañana a la"+(1!==this.hours()?"s":"")+"] LT"},nextWeek:function(){return"dddd [a la"+(1!==this.hours()?"s":"")+"] LT"},lastDay:function(){return"[ayer a la"+(1!==this.hours()?"s":"")+"] LT"},lastWeek:function(){return"[el] dddd [pasado a la"+(1!==this.hours()?"s":"")+"] LT"},sameElse:"L"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",ss:"%d segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",w:"una semana",ww:"%d semanas",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(5093))},7730:function(e,t,n){!function(e){"use strict";var t="ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.".split("_"),n="ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),i=[/^ene/i,/^feb/i,/^mar/i,/^abr/i,/^may/i,/^jun/i,/^jul/i,/^ago/i,/^sep/i,/^oct/i,/^nov/i,/^dic/i],r=/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i;e.defineLocale("es-mx",{months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),monthsShort:function(e,i){return e?/-MMM-/.test(i)?n[e.month()]:t[e.month()]:t},monthsRegex:r,monthsShortRegex:r,monthsStrictRegex:/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,monthsShortStrictRegex:/^(ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i,monthsParse:i,longMonthsParse:i,shortMonthsParse:i,weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY H:mm",LLLL:"dddd, D [de] MMMM [de] YYYY H:mm"},calendar:{sameDay:function(){return"[hoy a la"+(1!==this.hours()?"s":"")+"] LT"},nextDay:function(){return"[mañana a la"+(1!==this.hours()?"s":"")+"] LT"},nextWeek:function(){return"dddd [a la"+(1!==this.hours()?"s":"")+"] LT"},lastDay:function(){return"[ayer a la"+(1!==this.hours()?"s":"")+"] LT"},lastWeek:function(){return"[el] dddd [pasado a la"+(1!==this.hours()?"s":"")+"] LT"},sameElse:"L"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",ss:"%d segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",w:"una semana",ww:"%d semanas",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:0,doy:4},invalidDate:"Fecha inválida"})}(n(5093))},6575:function(e,t,n){!function(e){"use strict";var t="ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.".split("_"),n="ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),i=[/^ene/i,/^feb/i,/^mar/i,/^abr/i,/^may/i,/^jun/i,/^jul/i,/^ago/i,/^sep/i,/^oct/i,/^nov/i,/^dic/i],r=/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i;e.defineLocale("es-us",{months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),monthsShort:function(e,i){return e?/-MMM-/.test(i)?n[e.month()]:t[e.month()]:t},monthsRegex:r,monthsShortRegex:r,monthsStrictRegex:/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,monthsShortStrictRegex:/^(ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i,monthsParse:i,longMonthsParse:i,shortMonthsParse:i,weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"MM/DD/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY h:mm A",LLLL:"dddd, D [de] MMMM [de] YYYY h:mm A"},calendar:{sameDay:function(){return"[hoy a la"+(1!==this.hours()?"s":"")+"] LT"},nextDay:function(){return"[mañana a la"+(1!==this.hours()?"s":"")+"] LT"},nextWeek:function(){return"dddd [a la"+(1!==this.hours()?"s":"")+"] LT"},lastDay:function(){return"[ayer a la"+(1!==this.hours()?"s":"")+"] LT"},lastWeek:function(){return"[el] dddd [pasado a la"+(1!==this.hours()?"s":"")+"] LT"},sameElse:"L"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",ss:"%d segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",w:"una semana",ww:"%d semanas",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:0,doy:6}})}(n(5093))},7650:function(e,t,n){!function(e){"use strict";var t="ene._feb._mar._abr._may._jun._jul._ago._sep._oct._nov._dic.".split("_"),n="ene_feb_mar_abr_may_jun_jul_ago_sep_oct_nov_dic".split("_"),i=[/^ene/i,/^feb/i,/^mar/i,/^abr/i,/^may/i,/^jun/i,/^jul/i,/^ago/i,/^sep/i,/^oct/i,/^nov/i,/^dic/i],r=/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre|ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i;e.defineLocale("es",{months:"enero_febrero_marzo_abril_mayo_junio_julio_agosto_septiembre_octubre_noviembre_diciembre".split("_"),monthsShort:function(e,i){return e?/-MMM-/.test(i)?n[e.month()]:t[e.month()]:t},monthsRegex:r,monthsShortRegex:r,monthsStrictRegex:/^(enero|febrero|marzo|abril|mayo|junio|julio|agosto|septiembre|octubre|noviembre|diciembre)/i,monthsShortStrictRegex:/^(ene\.?|feb\.?|mar\.?|abr\.?|may\.?|jun\.?|jul\.?|ago\.?|sep\.?|oct\.?|nov\.?|dic\.?)/i,monthsParse:i,longMonthsParse:i,shortMonthsParse:i,weekdays:"domingo_lunes_martes_miércoles_jueves_viernes_sábado".split("_"),weekdaysShort:"dom._lun._mar._mié._jue._vie._sáb.".split("_"),weekdaysMin:"do_lu_ma_mi_ju_vi_sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY H:mm",LLLL:"dddd, D [de] MMMM [de] YYYY H:mm"},calendar:{sameDay:function(){return"[hoy a la"+(1!==this.hours()?"s":"")+"] LT"},nextDay:function(){return"[mañana a la"+(1!==this.hours()?"s":"")+"] LT"},nextWeek:function(){return"dddd [a la"+(1!==this.hours()?"s":"")+"] LT"},lastDay:function(){return"[ayer a la"+(1!==this.hours()?"s":"")+"] LT"},lastWeek:function(){return"[el] dddd [pasado a la"+(1!==this.hours()?"s":"")+"] LT"},sameElse:"L"},relativeTime:{future:"en %s",past:"hace %s",s:"unos segundos",ss:"%d segundos",m:"un minuto",mm:"%d minutos",h:"una hora",hh:"%d horas",d:"un día",dd:"%d días",w:"una semana",ww:"%d semanas",M:"un mes",MM:"%d meses",y:"un año",yy:"%d años"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4},invalidDate:"Fecha inválida"})}(n(5093))},3035:function(e,t,n){!function(e){"use strict";function t(e,t,n,i){var r={s:["mõne sekundi","mõni sekund","paar sekundit"],ss:[e+"sekundi",e+"sekundit"],m:["ühe minuti","üks minut"],mm:[e+" minuti",e+" minutit"],h:["ühe tunni","tund aega","üks tund"],hh:[e+" tunni",e+" tundi"],d:["ühe päeva","üks päev"],M:["kuu aja","kuu aega","üks kuu"],MM:[e+" kuu",e+" kuud"],y:["ühe aasta","aasta","üks aasta"],yy:[e+" aasta",e+" aastat"]};return t?r[n][2]?r[n][2]:r[n][1]:i?r[n][0]:r[n][1]}e.defineLocale("et",{months:"jaanuar_veebruar_märts_aprill_mai_juuni_juuli_august_september_oktoober_november_detsember".split("_"),monthsShort:"jaan_veebr_märts_apr_mai_juuni_juuli_aug_sept_okt_nov_dets".split("_"),weekdays:"pühapäev_esmaspäev_teisipäev_kolmapäev_neljapäev_reede_laupäev".split("_"),weekdaysShort:"P_E_T_K_N_R_L".split("_"),weekdaysMin:"P_E_T_K_N_R_L".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd, D. MMMM YYYY H:mm"},calendar:{sameDay:"[Täna,] LT",nextDay:"[Homme,] LT",nextWeek:"[Järgmine] dddd LT",lastDay:"[Eile,] LT",lastWeek:"[Eelmine] dddd LT",sameElse:"L"},relativeTime:{future:"%s pärast",past:"%s tagasi",s:t,ss:t,m:t,mm:t,h:t,hh:t,d:t,dd:"%d päeva",M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},3508:function(e,t,n){!function(e){"use strict";e.defineLocale("eu",{months:"urtarrila_otsaila_martxoa_apirila_maiatza_ekaina_uztaila_abuztua_iraila_urria_azaroa_abendua".split("_"),monthsShort:"urt._ots._mar._api._mai._eka._uzt._abu._ira._urr._aza._abe.".split("_"),monthsParseExact:!0,weekdays:"igandea_astelehena_asteartea_asteazkena_osteguna_ostirala_larunbata".split("_"),weekdaysShort:"ig._al._ar._az._og._ol._lr.".split("_"),weekdaysMin:"ig_al_ar_az_og_ol_lr".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"YYYY[ko] MMMM[ren] D[a]",LLL:"YYYY[ko] MMMM[ren] D[a] HH:mm",LLLL:"dddd, YYYY[ko] MMMM[ren] D[a] HH:mm",l:"YYYY-M-D",ll:"YYYY[ko] MMM D[a]",lll:"YYYY[ko] MMM D[a] HH:mm",llll:"ddd, YYYY[ko] MMM D[a] HH:mm"},calendar:{sameDay:"[gaur] LT[etan]",nextDay:"[bihar] LT[etan]",nextWeek:"dddd LT[etan]",lastDay:"[atzo] LT[etan]",lastWeek:"[aurreko] dddd LT[etan]",sameElse:"L"},relativeTime:{future:"%s barru",past:"duela %s",s:"segundo batzuk",ss:"%d segundo",m:"minutu bat",mm:"%d minutu",h:"ordu bat",hh:"%d ordu",d:"egun bat",dd:"%d egun",M:"hilabete bat",MM:"%d hilabete",y:"urte bat",yy:"%d urte"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(5093))},119:function(e,t,n){!function(e){"use strict";var t={1:"۱",2:"۲",3:"۳",4:"۴",5:"۵",6:"۶",7:"۷",8:"۸",9:"۹",0:"۰"},n={"۱":"1","۲":"2","۳":"3","۴":"4","۵":"5","۶":"6","۷":"7","۸":"8","۹":"9","۰":"0"};e.defineLocale("fa",{months:"ژانویه_فوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر".split("_"),monthsShort:"ژانویه_فوریه_مارس_آوریل_مه_ژوئن_ژوئیه_اوت_سپتامبر_اکتبر_نوامبر_دسامبر".split("_"),weekdays:"یکشنبه_دوشنبه_سهشنبه_چهارشنبه_پنجشنبه_جمعه_شنبه".split("_"),weekdaysShort:"یکشنبه_دوشنبه_سهشنبه_چهارشنبه_پنجشنبه_جمعه_شنبه".split("_"),weekdaysMin:"ی_د_س_چ_پ_ج_ش".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},meridiemParse:/قبل از ظهر|بعد از ظهر/,isPM:function(e){return/بعد از ظهر/.test(e)},meridiem:function(e,t,n){return e<12?"قبل از ظهر":"بعد از ظهر"},calendar:{sameDay:"[امروز ساعت] LT",nextDay:"[فردا ساعت] LT",nextWeek:"dddd [ساعت] LT",lastDay:"[دیروز ساعت] LT",lastWeek:"dddd [پیش] [ساعت] LT",sameElse:"L"},relativeTime:{future:"در %s",past:"%s پیش",s:"چند ثانیه",ss:"%d ثانیه",m:"یک دقیقه",mm:"%d دقیقه",h:"یک ساعت",hh:"%d ساعت",d:"یک روز",dd:"%d روز",M:"یک ماه",MM:"%d ماه",y:"یک سال",yy:"%d سال"},preparse:function(e){return e.replace(/[۰-۹]/g,(function(e){return n[e]})).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]})).replace(/,/g,"،")},dayOfMonthOrdinalParse:/\d{1,2}م/,ordinal:"%dم",week:{dow:6,doy:12}})}(n(5093))},527:function(e,t,n){!function(e){"use strict";var t="nolla yksi kaksi kolme neljä viisi kuusi seitsemän kahdeksan yhdeksän".split(" "),n=["nolla","yhden","kahden","kolmen","neljän","viiden","kuuden",t[7],t[8],t[9]];function i(e,i,r,a){var s="";switch(r){case"s":return a?"muutaman sekunnin":"muutama sekunti";case"ss":s=a?"sekunnin":"sekuntia";break;case"m":return a?"minuutin":"minuutti";case"mm":s=a?"minuutin":"minuuttia";break;case"h":return a?"tunnin":"tunti";case"hh":s=a?"tunnin":"tuntia";break;case"d":return a?"päivän":"päivä";case"dd":s=a?"päivän":"päivää";break;case"M":return a?"kuukauden":"kuukausi";case"MM":s=a?"kuukauden":"kuukautta";break;case"y":return a?"vuoden":"vuosi";case"yy":s=a?"vuoden":"vuotta"}return function(e,i){return e<10?i?n[e]:t[e]:e}(e,a)+" "+s}e.defineLocale("fi",{months:"tammikuu_helmikuu_maaliskuu_huhtikuu_toukokuu_kesäkuu_heinäkuu_elokuu_syyskuu_lokakuu_marraskuu_joulukuu".split("_"),monthsShort:"tammi_helmi_maalis_huhti_touko_kesä_heinä_elo_syys_loka_marras_joulu".split("_"),weekdays:"sunnuntai_maanantai_tiistai_keskiviikko_torstai_perjantai_lauantai".split("_"),weekdaysShort:"su_ma_ti_ke_to_pe_la".split("_"),weekdaysMin:"su_ma_ti_ke_to_pe_la".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD.MM.YYYY",LL:"Do MMMM[ta] YYYY",LLL:"Do MMMM[ta] YYYY, [klo] HH.mm",LLLL:"dddd, Do MMMM[ta] YYYY, [klo] HH.mm",l:"D.M.YYYY",ll:"Do MMM YYYY",lll:"Do MMM YYYY, [klo] HH.mm",llll:"ddd, Do MMM YYYY, [klo] HH.mm"},calendar:{sameDay:"[tänään] [klo] LT",nextDay:"[huomenna] [klo] LT",nextWeek:"dddd [klo] LT",lastDay:"[eilen] [klo] LT",lastWeek:"[viime] dddd[na] [klo] LT",sameElse:"L"},relativeTime:{future:"%s päästä",past:"%s sitten",s:i,ss:i,m:i,mm:i,h:i,hh:i,d:i,dd:i,M:i,MM:i,y:i,yy:i},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},5995:function(e,t,n){!function(e){"use strict";e.defineLocale("fil",{months:"Enero_Pebrero_Marso_Abril_Mayo_Hunyo_Hulyo_Agosto_Setyembre_Oktubre_Nobyembre_Disyembre".split("_"),monthsShort:"Ene_Peb_Mar_Abr_May_Hun_Hul_Ago_Set_Okt_Nob_Dis".split("_"),weekdays:"Linggo_Lunes_Martes_Miyerkules_Huwebes_Biyernes_Sabado".split("_"),weekdaysShort:"Lin_Lun_Mar_Miy_Huw_Biy_Sab".split("_"),weekdaysMin:"Li_Lu_Ma_Mi_Hu_Bi_Sab".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"MM/D/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY HH:mm",LLLL:"dddd, MMMM DD, YYYY HH:mm"},calendar:{sameDay:"LT [ngayong araw]",nextDay:"[Bukas ng] LT",nextWeek:"LT [sa susunod na] dddd",lastDay:"LT [kahapon]",lastWeek:"LT [noong nakaraang] dddd",sameElse:"L"},relativeTime:{future:"sa loob ng %s",past:"%s ang nakalipas",s:"ilang segundo",ss:"%d segundo",m:"isang minuto",mm:"%d minuto",h:"isang oras",hh:"%d oras",d:"isang araw",dd:"%d araw",M:"isang buwan",MM:"%d buwan",y:"isang taon",yy:"%d taon"},dayOfMonthOrdinalParse:/\d{1,2}/,ordinal:function(e){return e},week:{dow:1,doy:4}})}(n(5093))},2477:function(e,t,n){!function(e){"use strict";e.defineLocale("fo",{months:"januar_februar_mars_apríl_mai_juni_juli_august_september_oktober_november_desember".split("_"),monthsShort:"jan_feb_mar_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_"),weekdays:"sunnudagur_mánadagur_týsdagur_mikudagur_hósdagur_fríggjadagur_leygardagur".split("_"),weekdaysShort:"sun_mán_týs_mik_hós_frí_ley".split("_"),weekdaysMin:"su_má_tý_mi_hó_fr_le".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D. MMMM, YYYY HH:mm"},calendar:{sameDay:"[Í dag kl.] LT",nextDay:"[Í morgin kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[Í gjár kl.] LT",lastWeek:"[síðstu] dddd [kl] LT",sameElse:"L"},relativeTime:{future:"um %s",past:"%s síðani",s:"fá sekund",ss:"%d sekundir",m:"ein minuttur",mm:"%d minuttir",h:"ein tími",hh:"%d tímar",d:"ein dagur",dd:"%d dagar",M:"ein mánaður",MM:"%d mánaðir",y:"eitt ár",yy:"%d ár"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},6435:function(e,t,n){!function(e){"use strict";e.defineLocale("fr-ca",{months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),monthsParseExact:!0,weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Aujourd’hui à] LT",nextDay:"[Demain à] LT",nextWeek:"dddd [à] LT",lastDay:"[Hier à] LT",lastWeek:"dddd [dernier à] LT",sameElse:"L"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",ss:"%d secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},dayOfMonthOrdinalParse:/\d{1,2}(er|e)/,ordinal:function(e,t){switch(t){default:case"M":case"Q":case"D":case"DDD":case"d":return e+(1===e?"er":"e");case"w":case"W":return e+(1===e?"re":"e")}}})}(n(5093))},7892:function(e,t,n){!function(e){"use strict";e.defineLocale("fr-ch",{months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),monthsParseExact:!0,weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Aujourd’hui à] LT",nextDay:"[Demain à] LT",nextWeek:"dddd [à] LT",lastDay:"[Hier à] LT",lastWeek:"dddd [dernier à] LT",sameElse:"L"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",ss:"%d secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},dayOfMonthOrdinalParse:/\d{1,2}(er|e)/,ordinal:function(e,t){switch(t){default:case"M":case"Q":case"D":case"DDD":case"d":return e+(1===e?"er":"e");case"w":case"W":return e+(1===e?"re":"e")}},week:{dow:1,doy:4}})}(n(5093))},5498:function(e,t,n){!function(e){"use strict";var t=/(janv\.?|févr\.?|mars|avr\.?|mai|juin|juil\.?|août|sept\.?|oct\.?|nov\.?|déc\.?|janvier|février|mars|avril|mai|juin|juillet|août|septembre|octobre|novembre|décembre)/i,n=[/^janv/i,/^févr/i,/^mars/i,/^avr/i,/^mai/i,/^juin/i,/^juil/i,/^août/i,/^sept/i,/^oct/i,/^nov/i,/^déc/i];e.defineLocale("fr",{months:"janvier_février_mars_avril_mai_juin_juillet_août_septembre_octobre_novembre_décembre".split("_"),monthsShort:"janv._févr._mars_avr._mai_juin_juil._août_sept._oct._nov._déc.".split("_"),monthsRegex:t,monthsShortRegex:t,monthsStrictRegex:/^(janvier|février|mars|avril|mai|juin|juillet|août|septembre|octobre|novembre|décembre)/i,monthsShortStrictRegex:/(janv\.?|févr\.?|mars|avr\.?|mai|juin|juil\.?|août|sept\.?|oct\.?|nov\.?|déc\.?)/i,monthsParse:n,longMonthsParse:n,shortMonthsParse:n,weekdays:"dimanche_lundi_mardi_mercredi_jeudi_vendredi_samedi".split("_"),weekdaysShort:"dim._lun._mar._mer._jeu._ven._sam.".split("_"),weekdaysMin:"di_lu_ma_me_je_ve_sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Aujourd’hui à] LT",nextDay:"[Demain à] LT",nextWeek:"dddd [à] LT",lastDay:"[Hier à] LT",lastWeek:"dddd [dernier à] LT",sameElse:"L"},relativeTime:{future:"dans %s",past:"il y a %s",s:"quelques secondes",ss:"%d secondes",m:"une minute",mm:"%d minutes",h:"une heure",hh:"%d heures",d:"un jour",dd:"%d jours",w:"une semaine",ww:"%d semaines",M:"un mois",MM:"%d mois",y:"un an",yy:"%d ans"},dayOfMonthOrdinalParse:/\d{1,2}(er|)/,ordinal:function(e,t){switch(t){case"D":return e+(1===e?"er":"");default:case"M":case"Q":case"DDD":case"d":return e+(1===e?"er":"e");case"w":case"W":return e+(1===e?"re":"e")}},week:{dow:1,doy:4}})}(n(5093))},7071:function(e,t,n){!function(e){"use strict";var t="jan._feb._mrt._apr._mai_jun._jul._aug._sep._okt._nov._des.".split("_"),n="jan_feb_mrt_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_");e.defineLocale("fy",{months:"jannewaris_febrewaris_maart_april_maaie_juny_july_augustus_septimber_oktober_novimber_desimber".split("_"),monthsShort:function(e,i){return e?/-MMM-/.test(i)?n[e.month()]:t[e.month()]:t},monthsParseExact:!0,weekdays:"snein_moandei_tiisdei_woansdei_tongersdei_freed_sneon".split("_"),weekdaysShort:"si._mo._ti._wo._to._fr._so.".split("_"),weekdaysMin:"Si_Mo_Ti_Wo_To_Fr_So".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD-MM-YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[hjoed om] LT",nextDay:"[moarn om] LT",nextWeek:"dddd [om] LT",lastDay:"[juster om] LT",lastWeek:"[ôfrûne] dddd [om] LT",sameElse:"L"},relativeTime:{future:"oer %s",past:"%s lyn",s:"in pear sekonden",ss:"%d sekonden",m:"ien minút",mm:"%d minuten",h:"ien oere",hh:"%d oeren",d:"ien dei",dd:"%d dagen",M:"ien moanne",MM:"%d moannen",y:"ien jier",yy:"%d jierren"},dayOfMonthOrdinalParse:/\d{1,2}(ste|de)/,ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}(n(5093))},1734:function(e,t,n){!function(e){"use strict";e.defineLocale("ga",{months:["Eanáir","Feabhra","Márta","Aibreán","Bealtaine","Meitheamh","Iúil","Lúnasa","Meán Fómhair","Deireadh Fómhair","Samhain","Nollaig"],monthsShort:["Ean","Feabh","Márt","Aib","Beal","Meith","Iúil","Lún","M.F.","D.F.","Samh","Noll"],monthsParseExact:!0,weekdays:["Dé Domhnaigh","Dé Luain","Dé Máirt","Dé Céadaoin","Déardaoin","Dé hAoine","Dé Sathairn"],weekdaysShort:["Domh","Luan","Máirt","Céad","Déar","Aoine","Sath"],weekdaysMin:["Do","Lu","Má","Cé","Dé","A","Sa"],longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Inniu ag] LT",nextDay:"[Amárach ag] LT",nextWeek:"dddd [ag] LT",lastDay:"[Inné ag] LT",lastWeek:"dddd [seo caite] [ag] LT",sameElse:"L"},relativeTime:{future:"i %s",past:"%s ó shin",s:"cúpla soicind",ss:"%d soicind",m:"nóiméad",mm:"%d nóiméad",h:"uair an chloig",hh:"%d uair an chloig",d:"lá",dd:"%d lá",M:"mí",MM:"%d míonna",y:"bliain",yy:"%d bliain"},dayOfMonthOrdinalParse:/\d{1,2}(d|na|mh)/,ordinal:function(e){return e+(1===e?"d":e%10==2?"na":"mh")},week:{dow:1,doy:4}})}(n(5093))},217:function(e,t,n){!function(e){"use strict";e.defineLocale("gd",{months:["Am Faoilleach","An Gearran","Am Màrt","An Giblean","An Cèitean","An t-Ògmhios","An t-Iuchar","An Lùnastal","An t-Sultain","An Dàmhair","An t-Samhain","An Dùbhlachd"],monthsShort:["Faoi","Gear","Màrt","Gibl","Cèit","Ògmh","Iuch","Lùn","Sult","Dàmh","Samh","Dùbh"],monthsParseExact:!0,weekdays:["Didòmhnaich","Diluain","Dimàirt","Diciadain","Diardaoin","Dihaoine","Disathairne"],weekdaysShort:["Did","Dil","Dim","Dic","Dia","Dih","Dis"],weekdaysMin:["Dò","Lu","Mà","Ci","Ar","Ha","Sa"],longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[An-diugh aig] LT",nextDay:"[A-màireach aig] LT",nextWeek:"dddd [aig] LT",lastDay:"[An-dè aig] LT",lastWeek:"dddd [seo chaidh] [aig] LT",sameElse:"L"},relativeTime:{future:"ann an %s",past:"bho chionn %s",s:"beagan diogan",ss:"%d diogan",m:"mionaid",mm:"%d mionaidean",h:"uair",hh:"%d uairean",d:"latha",dd:"%d latha",M:"mìos",MM:"%d mìosan",y:"bliadhna",yy:"%d bliadhna"},dayOfMonthOrdinalParse:/\d{1,2}(d|na|mh)/,ordinal:function(e){return e+(1===e?"d":e%10==2?"na":"mh")},week:{dow:1,doy:4}})}(n(5093))},7329:function(e,t,n){!function(e){"use strict";e.defineLocale("gl",{months:"xaneiro_febreiro_marzo_abril_maio_xuño_xullo_agosto_setembro_outubro_novembro_decembro".split("_"),monthsShort:"xan._feb._mar._abr._mai._xuñ._xul._ago._set._out._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"domingo_luns_martes_mércores_xoves_venres_sábado".split("_"),weekdaysShort:"dom._lun._mar._mér._xov._ven._sáb.".split("_"),weekdaysMin:"do_lu_ma_mé_xo_ve_sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY H:mm",LLLL:"dddd, D [de] MMMM [de] YYYY H:mm"},calendar:{sameDay:function(){return"[hoxe "+(1!==this.hours()?"ás":"á")+"] LT"},nextDay:function(){return"[mañá "+(1!==this.hours()?"ás":"á")+"] LT"},nextWeek:function(){return"dddd ["+(1!==this.hours()?"ás":"a")+"] LT"},lastDay:function(){return"[onte "+(1!==this.hours()?"á":"a")+"] LT"},lastWeek:function(){return"[o] dddd [pasado "+(1!==this.hours()?"ás":"a")+"] LT"},sameElse:"L"},relativeTime:{future:function(e){return 0===e.indexOf("un")?"n"+e:"en "+e},past:"hai %s",s:"uns segundos",ss:"%d segundos",m:"un minuto",mm:"%d minutos",h:"unha hora",hh:"%d horas",d:"un día",dd:"%d días",M:"un mes",MM:"%d meses",y:"un ano",yy:"%d anos"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(5093))},2124:function(e,t,n){!function(e){"use strict";function t(e,t,n,i){var r={s:["थोडया सॅकंडांनी","थोडे सॅकंड"],ss:[e+" सॅकंडांनी",e+" सॅकंड"],m:["एका मिणटान","एक मिनूट"],mm:[e+" मिणटांनी",e+" मिणटां"],h:["एका वरान","एक वर"],hh:[e+" वरांनी",e+" वरां"],d:["एका दिसान","एक दीस"],dd:[e+" दिसांनी",e+" दीस"],M:["एका म्हयन्यान","एक म्हयनो"],MM:[e+" म्हयन्यानी",e+" म्हयने"],y:["एका वर्सान","एक वर्स"],yy:[e+" वर्सांनी",e+" वर्सां"]};return i?r[n][0]:r[n][1]}e.defineLocale("gom-deva",{months:{standalone:"जानेवारी_फेब्रुवारी_मार्च_एप्रील_मे_जून_जुलय_ऑगस्ट_सप्टेंबर_ऑक्टोबर_नोव्हेंबर_डिसेंबर".split("_"),format:"जानेवारीच्या_फेब्रुवारीच्या_मार्चाच्या_एप्रीलाच्या_मेयाच्या_जूनाच्या_जुलयाच्या_ऑगस्टाच्या_सप्टेंबराच्या_ऑक्टोबराच्या_नोव्हेंबराच्या_डिसेंबराच्या".split("_"),isFormat:/MMMM(\s)+D[oD]?/},monthsShort:"जाने._फेब्रु._मार्च_एप्री._मे_जून_जुल._ऑग._सप्टें._ऑक्टो._नोव्हें._डिसें.".split("_"),monthsParseExact:!0,weekdays:"आयतार_सोमार_मंगळार_बुधवार_बिरेस्तार_सुक्रार_शेनवार".split("_"),weekdaysShort:"आयत._सोम._मंगळ._बुध._ब्रेस्त._सुक्र._शेन.".split("_"),weekdaysMin:"आ_सो_मं_बु_ब्रे_सु_शे".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"A h:mm [वाजतां]",LTS:"A h:mm:ss [वाजतां]",L:"DD-MM-YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY A h:mm [वाजतां]",LLLL:"dddd, MMMM Do, YYYY, A h:mm [वाजतां]",llll:"ddd, D MMM YYYY, A h:mm [वाजतां]"},calendar:{sameDay:"[आयज] LT",nextDay:"[फाल्यां] LT",nextWeek:"[फुडलो] dddd[,] LT",lastDay:"[काल] LT",lastWeek:"[फाटलो] dddd[,] LT",sameElse:"L"},relativeTime:{future:"%s",past:"%s आदीं",s:t,ss:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}(वेर)/,ordinal:function(e,t){return"D"===t?e+"वेर":e},week:{dow:0,doy:3},meridiemParse:/राती|सकाळीं|दनपारां|सांजे/,meridiemHour:function(e,t){return 12===e&&(e=0),"राती"===t?e<4?e:e+12:"सकाळीं"===t?e:"दनपारां"===t?e>12?e:e+12:"सांजे"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"राती":e<12?"सकाळीं":e<16?"दनपारां":e<20?"सांजे":"राती"}})}(n(5093))},3383:function(e,t,n){!function(e){"use strict";function t(e,t,n,i){var r={s:["thoddea sekondamni","thodde sekond"],ss:[e+" sekondamni",e+" sekond"],m:["eka mintan","ek minut"],mm:[e+" mintamni",e+" mintam"],h:["eka voran","ek vor"],hh:[e+" voramni",e+" voram"],d:["eka disan","ek dis"],dd:[e+" disamni",e+" dis"],M:["eka mhoinean","ek mhoino"],MM:[e+" mhoineamni",e+" mhoine"],y:["eka vorsan","ek voros"],yy:[e+" vorsamni",e+" vorsam"]};return i?r[n][0]:r[n][1]}e.defineLocale("gom-latn",{months:{standalone:"Janer_Febrer_Mars_Abril_Mai_Jun_Julai_Agost_Setembr_Otubr_Novembr_Dezembr".split("_"),format:"Janerachea_Febrerachea_Marsachea_Abrilachea_Maiachea_Junachea_Julaiachea_Agostachea_Setembrachea_Otubrachea_Novembrachea_Dezembrachea".split("_"),isFormat:/MMMM(\s)+D[oD]?/},monthsShort:"Jan._Feb._Mars_Abr._Mai_Jun_Jul._Ago._Set._Otu._Nov._Dez.".split("_"),monthsParseExact:!0,weekdays:"Aitar_Somar_Mongllar_Budhvar_Birestar_Sukrar_Son'var".split("_"),weekdaysShort:"Ait._Som._Mon._Bud._Bre._Suk._Son.".split("_"),weekdaysMin:"Ai_Sm_Mo_Bu_Br_Su_Sn".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"A h:mm [vazta]",LTS:"A h:mm:ss [vazta]",L:"DD-MM-YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY A h:mm [vazta]",LLLL:"dddd, MMMM Do, YYYY, A h:mm [vazta]",llll:"ddd, D MMM YYYY, A h:mm [vazta]"},calendar:{sameDay:"[Aiz] LT",nextDay:"[Faleam] LT",nextWeek:"[Fuddlo] dddd[,] LT",lastDay:"[Kal] LT",lastWeek:"[Fattlo] dddd[,] LT",sameElse:"L"},relativeTime:{future:"%s",past:"%s adim",s:t,ss:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}(er)/,ordinal:function(e,t){return"D"===t?e+"er":e},week:{dow:0,doy:3},meridiemParse:/rati|sokallim|donparam|sanje/,meridiemHour:function(e,t){return 12===e&&(e=0),"rati"===t?e<4?e:e+12:"sokallim"===t?e:"donparam"===t?e>12?e:e+12:"sanje"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"rati":e<12?"sokallim":e<16?"donparam":e<20?"sanje":"rati"}})}(n(5093))},5050:function(e,t,n){!function(e){"use strict";var t={1:"૧",2:"૨",3:"૩",4:"૪",5:"૫",6:"૬",7:"૭",8:"૮",9:"૯",0:"૦"},n={"૧":"1","૨":"2","૩":"3","૪":"4","૫":"5","૬":"6","૭":"7","૮":"8","૯":"9","૦":"0"};e.defineLocale("gu",{months:"જાન્યુઆરી_ફેબ્રુઆરી_માર્ચ_એપ્રિલ_મે_જૂન_જુલાઈ_ઑગસ્ટ_સપ્ટેમ્બર_ઑક્ટ્બર_નવેમ્બર_ડિસેમ્બર".split("_"),monthsShort:"જાન્યુ._ફેબ્રુ._માર્ચ_એપ્રિ._મે_જૂન_જુલા._ઑગ._સપ્ટે._ઑક્ટ્._નવે._ડિસે.".split("_"),monthsParseExact:!0,weekdays:"રવિવાર_સોમવાર_મંગળવાર_બુધ્વાર_ગુરુવાર_શુક્રવાર_શનિવાર".split("_"),weekdaysShort:"રવિ_સોમ_મંગળ_બુધ્_ગુરુ_શુક્ર_શનિ".split("_"),weekdaysMin:"ર_સો_મં_બુ_ગુ_શુ_શ".split("_"),longDateFormat:{LT:"A h:mm વાગ્યે",LTS:"A h:mm:ss વાગ્યે",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm વાગ્યે",LLLL:"dddd, D MMMM YYYY, A h:mm વાગ્યે"},calendar:{sameDay:"[આજ] LT",nextDay:"[કાલે] LT",nextWeek:"dddd, LT",lastDay:"[ગઇકાલે] LT",lastWeek:"[પાછલા] dddd, LT",sameElse:"L"},relativeTime:{future:"%s મા",past:"%s પહેલા",s:"અમુક પળો",ss:"%d સેકંડ",m:"એક મિનિટ",mm:"%d મિનિટ",h:"એક કલાક",hh:"%d કલાક",d:"એક દિવસ",dd:"%d દિવસ",M:"એક મહિનો",MM:"%d મહિનો",y:"એક વર્ષ",yy:"%d વર્ષ"},preparse:function(e){return e.replace(/[૧૨૩૪૫૬૭૮૯૦]/g,(function(e){return n[e]}))},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]}))},meridiemParse:/રાત|બપોર|સવાર|સાંજ/,meridiemHour:function(e,t){return 12===e&&(e=0),"રાત"===t?e<4?e:e+12:"સવાર"===t?e:"બપોર"===t?e>=10?e:e+12:"સાંજ"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"રાત":e<10?"સવાર":e<17?"બપોર":e<20?"સાંજ":"રાત"},week:{dow:0,doy:6}})}(n(5093))},1713:function(e,t,n){!function(e){"use strict";e.defineLocale("he",{months:"ינואר_פברואר_מרץ_אפריל_מאי_יוני_יולי_אוגוסט_ספטמבר_אוקטובר_נובמבר_דצמבר".split("_"),monthsShort:"ינו׳_פבר׳_מרץ_אפר׳_מאי_יוני_יולי_אוג׳_ספט׳_אוק׳_נוב׳_דצמ׳".split("_"),weekdays:"ראשון_שני_שלישי_רביעי_חמישי_שישי_שבת".split("_"),weekdaysShort:"א׳_ב׳_ג׳_ד׳_ה׳_ו׳_ש׳".split("_"),weekdaysMin:"א_ב_ג_ד_ה_ו_ש".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [ב]MMMM YYYY",LLL:"D [ב]MMMM YYYY HH:mm",LLLL:"dddd, D [ב]MMMM YYYY HH:mm",l:"D/M/YYYY",ll:"D MMM YYYY",lll:"D MMM YYYY HH:mm",llll:"ddd, D MMM YYYY HH:mm"},calendar:{sameDay:"[היום ב־]LT",nextDay:"[מחר ב־]LT",nextWeek:"dddd [בשעה] LT",lastDay:"[אתמול ב־]LT",lastWeek:"[ביום] dddd [האחרון בשעה] LT",sameElse:"L"},relativeTime:{future:"בעוד %s",past:"לפני %s",s:"מספר שניות",ss:"%d שניות",m:"דקה",mm:"%d דקות",h:"שעה",hh:function(e){return 2===e?"שעתיים":e+" שעות"},d:"יום",dd:function(e){return 2===e?"יומיים":e+" ימים"},M:"חודש",MM:function(e){return 2===e?"חודשיים":e+" חודשים"},y:"שנה",yy:function(e){return 2===e?"שנתיים":e%10==0&&10!==e?e+" שנה":e+" שנים"}},meridiemParse:/אחה"צ|לפנה"צ|אחרי הצהריים|לפני הצהריים|לפנות בוקר|בבוקר|בערב/i,isPM:function(e){return/^(אחה"צ|אחרי הצהריים|בערב)$/.test(e)},meridiem:function(e,t,n){return e<5?"לפנות בוקר":e<10?"בבוקר":e<12?n?'לפנה"צ':"לפני הצהריים":e<18?n?'אחה"צ':"אחרי הצהריים":"בערב"}})}(n(5093))},3861:function(e,t,n){!function(e){"use strict";var t={1:"१",2:"२",3:"३",4:"४",5:"५",6:"६",7:"७",8:"८",9:"९",0:"०"},n={"१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9","०":"0"},i=[/^जन/i,/^फ़र|फर/i,/^मार्च/i,/^अप्रै/i,/^मई/i,/^जून/i,/^जुल/i,/^अग/i,/^सितं|सित/i,/^अक्टू/i,/^नव|नवं/i,/^दिसं|दिस/i];e.defineLocale("hi",{months:{format:"जनवरी_फ़रवरी_मार्च_अप्रैल_मई_जून_जुलाई_अगस्त_सितम्बर_अक्टूबर_नवम्बर_दिसम्बर".split("_"),standalone:"जनवरी_फरवरी_मार्च_अप्रैल_मई_जून_जुलाई_अगस्त_सितंबर_अक्टूबर_नवंबर_दिसंबर".split("_")},monthsShort:"जन._फ़र._मार्च_अप्रै._मई_जून_जुल._अग._सित._अक्टू._नव._दिस.".split("_"),weekdays:"रविवार_सोमवार_मंगलवार_बुधवार_गुरूवार_शुक्रवार_शनिवार".split("_"),weekdaysShort:"रवि_सोम_मंगल_बुध_गुरू_शुक्र_शनि".split("_"),weekdaysMin:"र_सो_मं_बु_गु_शु_श".split("_"),longDateFormat:{LT:"A h:mm बजे",LTS:"A h:mm:ss बजे",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm बजे",LLLL:"dddd, D MMMM YYYY, A h:mm बजे"},monthsParse:i,longMonthsParse:i,shortMonthsParse:[/^जन/i,/^फ़र/i,/^मार्च/i,/^अप्रै/i,/^मई/i,/^जून/i,/^जुल/i,/^अग/i,/^सित/i,/^अक्टू/i,/^नव/i,/^दिस/i],monthsRegex:/^(जनवरी|जन\.?|फ़रवरी|फरवरी|फ़र\.?|मार्च?|अप्रैल|अप्रै\.?|मई?|जून?|जुलाई|जुल\.?|अगस्त|अग\.?|सितम्बर|सितंबर|सित\.?|अक्टूबर|अक्टू\.?|नवम्बर|नवंबर|नव\.?|दिसम्बर|दिसंबर|दिस\.?)/i,monthsShortRegex:/^(जनवरी|जन\.?|फ़रवरी|फरवरी|फ़र\.?|मार्च?|अप्रैल|अप्रै\.?|मई?|जून?|जुलाई|जुल\.?|अगस्त|अग\.?|सितम्बर|सितंबर|सित\.?|अक्टूबर|अक्टू\.?|नवम्बर|नवंबर|नव\.?|दिसम्बर|दिसंबर|दिस\.?)/i,monthsStrictRegex:/^(जनवरी?|फ़रवरी|फरवरी?|मार्च?|अप्रैल?|मई?|जून?|जुलाई?|अगस्त?|सितम्बर|सितंबर|सित?\.?|अक्टूबर|अक्टू\.?|नवम्बर|नवंबर?|दिसम्बर|दिसंबर?)/i,monthsShortStrictRegex:/^(जन\.?|फ़र\.?|मार्च?|अप्रै\.?|मई?|जून?|जुल\.?|अग\.?|सित\.?|अक्टू\.?|नव\.?|दिस\.?)/i,calendar:{sameDay:"[आज] LT",nextDay:"[कल] LT",nextWeek:"dddd, LT",lastDay:"[कल] LT",lastWeek:"[पिछले] dddd, LT",sameElse:"L"},relativeTime:{future:"%s में",past:"%s पहले",s:"कुछ ही क्षण",ss:"%d सेकंड",m:"एक मिनट",mm:"%d मिनट",h:"एक घंटा",hh:"%d घंटे",d:"एक दिन",dd:"%d दिन",M:"एक महीने",MM:"%d महीने",y:"एक वर्ष",yy:"%d वर्ष"},preparse:function(e){return e.replace(/[१२३४५६७८९०]/g,(function(e){return n[e]}))},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]}))},meridiemParse:/रात|सुबह|दोपहर|शाम/,meridiemHour:function(e,t){return 12===e&&(e=0),"रात"===t?e<4?e:e+12:"सुबह"===t?e:"दोपहर"===t?e>=10?e:e+12:"शाम"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"रात":e<10?"सुबह":e<17?"दोपहर":e<20?"शाम":"रात"},week:{dow:0,doy:6}})}(n(5093))},6308:function(e,t,n){!function(e){"use strict";function t(e,t,n){var i=e+" ";switch(n){case"ss":return i+(1===e?"sekunda":2===e||3===e||4===e?"sekunde":"sekundi");case"m":return t?"jedna minuta":"jedne minute";case"mm":return i+(1===e?"minuta":2===e||3===e||4===e?"minute":"minuta");case"h":return t?"jedan sat":"jednog sata";case"hh":return i+(1===e?"sat":2===e||3===e||4===e?"sata":"sati");case"dd":return i+(1===e?"dan":"dana");case"MM":return i+(1===e?"mjesec":2===e||3===e||4===e?"mjeseca":"mjeseci");case"yy":return i+(1===e?"godina":2===e||3===e||4===e?"godine":"godina")}}e.defineLocale("hr",{months:{format:"siječnja_veljače_ožujka_travnja_svibnja_lipnja_srpnja_kolovoza_rujna_listopada_studenoga_prosinca".split("_"),standalone:"siječanj_veljača_ožujak_travanj_svibanj_lipanj_srpanj_kolovoz_rujan_listopad_studeni_prosinac".split("_")},monthsShort:"sij._velj._ožu._tra._svi._lip._srp._kol._ruj._lis._stu._pro.".split("_"),monthsParseExact:!0,weekdays:"nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sri._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"Do MMMM YYYY",LLL:"Do MMMM YYYY H:mm",LLLL:"dddd, Do MMMM YYYY H:mm"},calendar:{sameDay:"[danas u] LT",nextDay:"[sutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedjelju] [u] LT";case 3:return"[u] [srijedu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[jučer u] LT",lastWeek:function(){switch(this.day()){case 0:return"[prošlu] [nedjelju] [u] LT";case 3:return"[prošlu] [srijedu] [u] LT";case 6:return"[prošle] [subote] [u] LT";case 1:case 2:case 4:case 5:return"[prošli] dddd [u] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"prije %s",s:"par sekundi",ss:t,m:t,mm:t,h:t,hh:t,d:"dan",dd:t,M:"mjesec",MM:t,y:"godinu",yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(5093))},609:function(e,t,n){!function(e){"use strict";var t="vasárnap hétfőn kedden szerdán csütörtökön pénteken szombaton".split(" ");function n(e,t,n,i){var r=e;switch(n){case"s":return i||t?"néhány másodperc":"néhány másodperce";case"ss":return r+(i||t)?" másodperc":" másodperce";case"m":return"egy"+(i||t?" perc":" perce");case"mm":return r+(i||t?" perc":" perce");case"h":return"egy"+(i||t?" óra":" órája");case"hh":return r+(i||t?" óra":" órája");case"d":return"egy"+(i||t?" nap":" napja");case"dd":return r+(i||t?" nap":" napja");case"M":return"egy"+(i||t?" hónap":" hónapja");case"MM":return r+(i||t?" hónap":" hónapja");case"y":return"egy"+(i||t?" év":" éve");case"yy":return r+(i||t?" év":" éve")}return""}function i(e){return(e?"":"[múlt] ")+"["+t[this.day()]+"] LT[-kor]"}e.defineLocale("hu",{months:"január_február_március_április_május_június_július_augusztus_szeptember_október_november_december".split("_"),monthsShort:"jan._feb._márc._ápr._máj._jún._júl._aug._szept._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"vasárnap_hétfő_kedd_szerda_csütörtök_péntek_szombat".split("_"),weekdaysShort:"vas_hét_kedd_sze_csüt_pén_szo".split("_"),weekdaysMin:"v_h_k_sze_cs_p_szo".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"YYYY.MM.DD.",LL:"YYYY. MMMM D.",LLL:"YYYY. MMMM D. H:mm",LLLL:"YYYY. MMMM D., dddd H:mm"},meridiemParse:/de|du/i,isPM:function(e){return"u"===e.charAt(1).toLowerCase()},meridiem:function(e,t,n){return e<12?!0===n?"de":"DE":!0===n?"du":"DU"},calendar:{sameDay:"[ma] LT[-kor]",nextDay:"[holnap] LT[-kor]",nextWeek:function(){return i.call(this,!0)},lastDay:"[tegnap] LT[-kor]",lastWeek:function(){return i.call(this,!1)},sameElse:"L"},relativeTime:{future:"%s múlva",past:"%s",s:n,ss:n,m:n,mm:n,h:n,hh:n,d:n,dd:n,M:n,MM:n,y:n,yy:n},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},7160:function(e,t,n){!function(e){"use strict";e.defineLocale("hy-am",{months:{format:"հունվարի_փետրվարի_մարտի_ապրիլի_մայիսի_հունիսի_հուլիսի_օգոստոսի_սեպտեմբերի_հոկտեմբերի_նոյեմբերի_դեկտեմբերի".split("_"),standalone:"հունվար_փետրվար_մարտ_ապրիլ_մայիս_հունիս_հուլիս_օգոստոս_սեպտեմբեր_հոկտեմբեր_նոյեմբեր_դեկտեմբեր".split("_")},monthsShort:"հնվ_փտր_մրտ_ապր_մյս_հնս_հլս_օգս_սպտ_հկտ_նմբ_դկտ".split("_"),weekdays:"կիրակի_երկուշաբթի_երեքշաբթի_չորեքշաբթի_հինգշաբթի_ուրբաթ_շաբաթ".split("_"),weekdaysShort:"կրկ_երկ_երք_չրք_հնգ_ուրբ_շբթ".split("_"),weekdaysMin:"կրկ_երկ_երք_չրք_հնգ_ուրբ_շբթ".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY թ.",LLL:"D MMMM YYYY թ., HH:mm",LLLL:"dddd, D MMMM YYYY թ., HH:mm"},calendar:{sameDay:"[այսօր] LT",nextDay:"[վաղը] LT",lastDay:"[երեկ] LT",nextWeek:function(){return"dddd [օրը ժամը] LT"},lastWeek:function(){return"[անցած] dddd [օրը ժամը] LT"},sameElse:"L"},relativeTime:{future:"%s հետո",past:"%s առաջ",s:"մի քանի վայրկյան",ss:"%d վայրկյան",m:"րոպե",mm:"%d րոպե",h:"ժամ",hh:"%d ժամ",d:"օր",dd:"%d օր",M:"ամիս",MM:"%d ամիս",y:"տարի",yy:"%d տարի"},meridiemParse:/գիշերվա|առավոտվա|ցերեկվա|երեկոյան/,isPM:function(e){return/^(ցերեկվա|երեկոյան)$/.test(e)},meridiem:function(e){return e<4?"գիշերվա":e<12?"առավոտվա":e<17?"ցերեկվա":"երեկոյան"},dayOfMonthOrdinalParse:/\d{1,2}|\d{1,2}-(ին|րդ)/,ordinal:function(e,t){switch(t){case"DDD":case"w":case"W":case"DDDo":return 1===e?e+"-ին":e+"-րդ";default:return e}},week:{dow:1,doy:7}})}(n(5093))},4063:function(e,t,n){!function(e){"use strict";e.defineLocale("id",{months:"Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_November_Desember".split("_"),monthsShort:"Jan_Feb_Mar_Apr_Mei_Jun_Jul_Agt_Sep_Okt_Nov_Des".split("_"),weekdays:"Minggu_Senin_Selasa_Rabu_Kamis_Jumat_Sabtu".split("_"),weekdaysShort:"Min_Sen_Sel_Rab_Kam_Jum_Sab".split("_"),weekdaysMin:"Mg_Sn_Sl_Rb_Km_Jm_Sb".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},meridiemParse:/pagi|siang|sore|malam/,meridiemHour:function(e,t){return 12===e&&(e=0),"pagi"===t?e:"siang"===t?e>=11?e:e+12:"sore"===t||"malam"===t?e+12:void 0},meridiem:function(e,t,n){return e<11?"pagi":e<15?"siang":e<19?"sore":"malam"},calendar:{sameDay:"[Hari ini pukul] LT",nextDay:"[Besok pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kemarin pukul] LT",lastWeek:"dddd [lalu pukul] LT",sameElse:"L"},relativeTime:{future:"dalam %s",past:"%s yang lalu",s:"beberapa detik",ss:"%d detik",m:"semenit",mm:"%d menit",h:"sejam",hh:"%d jam",d:"sehari",dd:"%d hari",M:"sebulan",MM:"%d bulan",y:"setahun",yy:"%d tahun"},week:{dow:0,doy:6}})}(n(5093))},9374:function(e,t,n){!function(e){"use strict";function t(e){return e%100==11||e%10!=1}function n(e,n,i,r){var a=e+" ";switch(i){case"s":return n||r?"nokkrar sekúndur":"nokkrum sekúndum";case"ss":return t(e)?a+(n||r?"sekúndur":"sekúndum"):a+"sekúnda";case"m":return n?"mínúta":"mínútu";case"mm":return t(e)?a+(n||r?"mínútur":"mínútum"):n?a+"mínúta":a+"mínútu";case"hh":return t(e)?a+(n||r?"klukkustundir":"klukkustundum"):a+"klukkustund";case"d":return n?"dagur":r?"dag":"degi";case"dd":return t(e)?n?a+"dagar":a+(r?"daga":"dögum"):n?a+"dagur":a+(r?"dag":"degi");case"M":return n?"mánuður":r?"mánuð":"mánuði";case"MM":return t(e)?n?a+"mánuðir":a+(r?"mánuði":"mánuðum"):n?a+"mánuður":a+(r?"mánuð":"mánuði");case"y":return n||r?"ár":"ári";case"yy":return t(e)?a+(n||r?"ár":"árum"):a+(n||r?"ár":"ári")}}e.defineLocale("is",{months:"janúar_febrúar_mars_apríl_maí_júní_júlí_ágúst_september_október_nóvember_desember".split("_"),monthsShort:"jan_feb_mar_apr_maí_jún_júl_ágú_sep_okt_nóv_des".split("_"),weekdays:"sunnudagur_mánudagur_þriðjudagur_miðvikudagur_fimmtudagur_föstudagur_laugardagur".split("_"),weekdaysShort:"sun_mán_þri_mið_fim_fös_lau".split("_"),weekdaysMin:"Su_Má_Þr_Mi_Fi_Fö_La".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY [kl.] H:mm",LLLL:"dddd, D. MMMM YYYY [kl.] H:mm"},calendar:{sameDay:"[í dag kl.] LT",nextDay:"[á morgun kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[í gær kl.] LT",lastWeek:"[síðasta] dddd [kl.] LT",sameElse:"L"},relativeTime:{future:"eftir %s",past:"fyrir %s síðan",s:n,ss:n,m:n,mm:n,h:"klukkustund",hh:n,d:n,dd:n,M:n,MM:n,y:n,yy:n},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},1827:function(e,t,n){!function(e){"use strict";e.defineLocale("it-ch",{months:"gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre".split("_"),monthsShort:"gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic".split("_"),weekdays:"domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato".split("_"),weekdaysShort:"dom_lun_mar_mer_gio_ven_sab".split("_"),weekdaysMin:"do_lu_ma_me_gi_ve_sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[Oggi alle] LT",nextDay:"[Domani alle] LT",nextWeek:"dddd [alle] LT",lastDay:"[Ieri alle] LT",lastWeek:function(){return 0===this.day()?"[la scorsa] dddd [alle] LT":"[lo scorso] dddd [alle] LT"},sameElse:"L"},relativeTime:{future:function(e){return(/^[0-9].+$/.test(e)?"tra":"in")+" "+e},past:"%s fa",s:"alcuni secondi",ss:"%d secondi",m:"un minuto",mm:"%d minuti",h:"un'ora",hh:"%d ore",d:"un giorno",dd:"%d giorni",M:"un mese",MM:"%d mesi",y:"un anno",yy:"%d anni"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(5093))},8383:function(e,t,n){!function(e){"use strict";e.defineLocale("it",{months:"gennaio_febbraio_marzo_aprile_maggio_giugno_luglio_agosto_settembre_ottobre_novembre_dicembre".split("_"),monthsShort:"gen_feb_mar_apr_mag_giu_lug_ago_set_ott_nov_dic".split("_"),weekdays:"domenica_lunedì_martedì_mercoledì_giovedì_venerdì_sabato".split("_"),weekdaysShort:"dom_lun_mar_mer_gio_ven_sab".split("_"),weekdaysMin:"do_lu_ma_me_gi_ve_sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:function(){return"[Oggi a"+(this.hours()>1?"lle ":0===this.hours()?" ":"ll'")+"]LT"},nextDay:function(){return"[Domani a"+(this.hours()>1?"lle ":0===this.hours()?" ":"ll'")+"]LT"},nextWeek:function(){return"dddd [a"+(this.hours()>1?"lle ":0===this.hours()?" ":"ll'")+"]LT"},lastDay:function(){return"[Ieri a"+(this.hours()>1?"lle ":0===this.hours()?" ":"ll'")+"]LT"},lastWeek:function(){return 0===this.day()?"[La scorsa] dddd [a"+(this.hours()>1?"lle ":0===this.hours()?" ":"ll'")+"]LT":"[Lo scorso] dddd [a"+(this.hours()>1?"lle ":0===this.hours()?" ":"ll'")+"]LT"},sameElse:"L"},relativeTime:{future:"tra %s",past:"%s fa",s:"alcuni secondi",ss:"%d secondi",m:"un minuto",mm:"%d minuti",h:"un'ora",hh:"%d ore",d:"un giorno",dd:"%d giorni",w:"una settimana",ww:"%d settimane",M:"un mese",MM:"%d mesi",y:"un anno",yy:"%d anni"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(5093))},3827:function(e,t,n){!function(e){"use strict";e.defineLocale("ja",{eras:[{since:"2019-05-01",offset:1,name:"令和",narrow:"㋿",abbr:"R"},{since:"1989-01-08",until:"2019-04-30",offset:1,name:"平成",narrow:"㍻",abbr:"H"},{since:"1926-12-25",until:"1989-01-07",offset:1,name:"昭和",narrow:"㍼",abbr:"S"},{since:"1912-07-30",until:"1926-12-24",offset:1,name:"大正",narrow:"㍽",abbr:"T"},{since:"1873-01-01",until:"1912-07-29",offset:6,name:"明治",narrow:"㍾",abbr:"M"},{since:"0001-01-01",until:"1873-12-31",offset:1,name:"西暦",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"紀元前",narrow:"BC",abbr:"BC"}],eraYearOrdinalRegex:/(元|\d+)年/,eraYearOrdinalParse:function(e,t){return"元"===t[1]?1:parseInt(t[1]||e,10)},months:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"日曜日_月曜日_火曜日_水曜日_木曜日_金曜日_土曜日".split("_"),weekdaysShort:"日_月_火_水_木_金_土".split("_"),weekdaysMin:"日_月_火_水_木_金_土".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY/MM/DD",LL:"YYYY年M月D日",LLL:"YYYY年M月D日 HH:mm",LLLL:"YYYY年M月D日 dddd HH:mm",l:"YYYY/MM/DD",ll:"YYYY年M月D日",lll:"YYYY年M月D日 HH:mm",llll:"YYYY年M月D日(ddd) HH:mm"},meridiemParse:/午前|午後/i,isPM:function(e){return"午後"===e},meridiem:function(e,t,n){return e<12?"午前":"午後"},calendar:{sameDay:"[今日] LT",nextDay:"[明日] LT",nextWeek:function(e){return e.week()!==this.week()?"[来週]dddd LT":"dddd LT"},lastDay:"[昨日] LT",lastWeek:function(e){return this.week()!==e.week()?"[先週]dddd LT":"dddd LT"},sameElse:"L"},dayOfMonthOrdinalParse:/\d{1,2}日/,ordinal:function(e,t){switch(t){case"y":return 1===e?"元年":e+"年";case"d":case"D":case"DDD":return e+"日";default:return e}},relativeTime:{future:"%s後",past:"%s前",s:"数秒",ss:"%d秒",m:"1分",mm:"%d分",h:"1時間",hh:"%d時間",d:"1日",dd:"%d日",M:"1ヶ月",MM:"%dヶ月",y:"1年",yy:"%d年"}})}(n(5093))},9722:function(e,t,n){!function(e){"use strict";e.defineLocale("jv",{months:"Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_Nopember_Desember".split("_"),monthsShort:"Jan_Feb_Mar_Apr_Mei_Jun_Jul_Ags_Sep_Okt_Nop_Des".split("_"),weekdays:"Minggu_Senen_Seloso_Rebu_Kemis_Jemuwah_Septu".split("_"),weekdaysShort:"Min_Sen_Sel_Reb_Kem_Jem_Sep".split("_"),weekdaysMin:"Mg_Sn_Sl_Rb_Km_Jm_Sp".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},meridiemParse:/enjing|siyang|sonten|ndalu/,meridiemHour:function(e,t){return 12===e&&(e=0),"enjing"===t?e:"siyang"===t?e>=11?e:e+12:"sonten"===t||"ndalu"===t?e+12:void 0},meridiem:function(e,t,n){return e<11?"enjing":e<15?"siyang":e<19?"sonten":"ndalu"},calendar:{sameDay:"[Dinten puniko pukul] LT",nextDay:"[Mbenjang pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kala wingi pukul] LT",lastWeek:"dddd [kepengker pukul] LT",sameElse:"L"},relativeTime:{future:"wonten ing %s",past:"%s ingkang kepengker",s:"sawetawis detik",ss:"%d detik",m:"setunggal menit",mm:"%d menit",h:"setunggal jam",hh:"%d jam",d:"sedinten",dd:"%d dinten",M:"sewulan",MM:"%d wulan",y:"setaun",yy:"%d taun"},week:{dow:1,doy:7}})}(n(5093))},1794:function(e,t,n){!function(e){"use strict";e.defineLocale("ka",{months:"იანვარი_თებერვალი_მარტი_აპრილი_მაისი_ივნისი_ივლისი_აგვისტო_სექტემბერი_ოქტომბერი_ნოემბერი_დეკემბერი".split("_"),monthsShort:"იან_თებ_მარ_აპრ_მაი_ივნ_ივლ_აგვ_სექ_ოქტ_ნოე_დეკ".split("_"),weekdays:{standalone:"კვირა_ორშაბათი_სამშაბათი_ოთხშაბათი_ხუთშაბათი_პარასკევი_შაბათი".split("_"),format:"კვირას_ორშაბათს_სამშაბათს_ოთხშაბათს_ხუთშაბათს_პარასკევს_შაბათს".split("_"),isFormat:/(წინა|შემდეგ)/},weekdaysShort:"კვი_ორშ_სამ_ოთხ_ხუთ_პარ_შაბ".split("_"),weekdaysMin:"კვ_ორ_სა_ოთ_ხუ_პა_შა".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[დღეს] LT[-ზე]",nextDay:"[ხვალ] LT[-ზე]",lastDay:"[გუშინ] LT[-ზე]",nextWeek:"[შემდეგ] dddd LT[-ზე]",lastWeek:"[წინა] dddd LT-ზე",sameElse:"L"},relativeTime:{future:function(e){return e.replace(/(წამ|წუთ|საათ|წელ|დღ|თვ)(ი|ე)/,(function(e,t,n){return"ი"===n?t+"ში":t+n+"ში"}))},past:function(e){return/(წამი|წუთი|საათი|დღე|თვე)/.test(e)?e.replace(/(ი|ე)$/,"ის წინ"):/წელი/.test(e)?e.replace(/წელი$/,"წლის წინ"):e},s:"რამდენიმე წამი",ss:"%d წამი",m:"წუთი",mm:"%d წუთი",h:"საათი",hh:"%d საათი",d:"დღე",dd:"%d დღე",M:"თვე",MM:"%d თვე",y:"წელი",yy:"%d წელი"},dayOfMonthOrdinalParse:/0|1-ლი|მე-\d{1,2}|\d{1,2}-ე/,ordinal:function(e){return 0===e?e:1===e?e+"-ლი":e<20||e<=100&&e%20==0||e%100==0?"მე-"+e:e+"-ე"},week:{dow:1,doy:7}})}(n(5093))},7088:function(e,t,n){!function(e){"use strict";var t={0:"-ші",1:"-ші",2:"-ші",3:"-ші",4:"-ші",5:"-ші",6:"-шы",7:"-ші",8:"-ші",9:"-шы",10:"-шы",20:"-шы",30:"-шы",40:"-шы",50:"-ші",60:"-шы",70:"-ші",80:"-ші",90:"-шы",100:"-ші"};e.defineLocale("kk",{months:"қаңтар_ақпан_наурыз_сәуір_мамыр_маусым_шілде_тамыз_қыркүйек_қазан_қараша_желтоқсан".split("_"),monthsShort:"қаң_ақп_нау_сәу_мам_мау_шіл_там_қыр_қаз_қар_жел".split("_"),weekdays:"жексенбі_дүйсенбі_сейсенбі_сәрсенбі_бейсенбі_жұма_сенбі".split("_"),weekdaysShort:"жек_дүй_сей_сәр_бей_жұм_сен".split("_"),weekdaysMin:"жк_дй_сй_ср_бй_жм_сн".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Бүгін сағат] LT",nextDay:"[Ертең сағат] LT",nextWeek:"dddd [сағат] LT",lastDay:"[Кеше сағат] LT",lastWeek:"[Өткен аптаның] dddd [сағат] LT",sameElse:"L"},relativeTime:{future:"%s ішінде",past:"%s бұрын",s:"бірнеше секунд",ss:"%d секунд",m:"бір минут",mm:"%d минут",h:"бір сағат",hh:"%d сағат",d:"бір күн",dd:"%d күн",M:"бір ай",MM:"%d ай",y:"бір жыл",yy:"%d жыл"},dayOfMonthOrdinalParse:/\d{1,2}-(ші|шы)/,ordinal:function(e){return e+(t[e]||t[e%10]||t[e>=100?100:null])},week:{dow:1,doy:7}})}(n(5093))},6870:function(e,t,n){!function(e){"use strict";var t={1:"១",2:"២",3:"៣",4:"៤",5:"៥",6:"៦",7:"៧",8:"៨",9:"៩",0:"០"},n={"១":"1","២":"2","៣":"3","៤":"4","៥":"5","៦":"6","៧":"7","៨":"8","៩":"9","០":"0"};e.defineLocale("km",{months:"មករា_កុម្ភៈ_មីនា_មេសា_ឧសភា_មិថុនា_កក្កដា_សីហា_កញ្ញា_តុលា_វិច្ឆិកា_ធ្នូ".split("_"),monthsShort:"មករា_កុម្ភៈ_មីនា_មេសា_ឧសភា_មិថុនា_កក្កដា_សីហា_កញ្ញា_តុលា_វិច្ឆិកា_ធ្នូ".split("_"),weekdays:"អាទិត្យ_ច័ន្ទ_អង្គារ_ពុធ_ព្រហស្បតិ៍_សុក្រ_សៅរ៍".split("_"),weekdaysShort:"អា_ច_អ_ព_ព្រ_សុ_ស".split("_"),weekdaysMin:"អា_ច_អ_ព_ព្រ_សុ_ស".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},meridiemParse:/ព្រឹក|ល្ងាច/,isPM:function(e){return"ល្ងាច"===e},meridiem:function(e,t,n){return e<12?"ព្រឹក":"ល្ងាច"},calendar:{sameDay:"[ថ្ងៃនេះ ម៉ោង] LT",nextDay:"[ស្អែក ម៉ោង] LT",nextWeek:"dddd [ម៉ោង] LT",lastDay:"[ម្សិលមិញ ម៉ោង] LT",lastWeek:"dddd [សប្តាហ៍មុន] [ម៉ោង] LT",sameElse:"L"},relativeTime:{future:"%sទៀត",past:"%sមុន",s:"ប៉ុន្មានវិនាទី",ss:"%d វិនាទី",m:"មួយនាទី",mm:"%d នាទី",h:"មួយម៉ោង",hh:"%d ម៉ោង",d:"មួយថ្ងៃ",dd:"%d ថ្ងៃ",M:"មួយខែ",MM:"%d ខែ",y:"មួយឆ្នាំ",yy:"%d ឆ្នាំ"},dayOfMonthOrdinalParse:/ទី\d{1,2}/,ordinal:"ទី%d",preparse:function(e){return e.replace(/[១២៣៤៥៦៧៨៩០]/g,(function(e){return n[e]}))},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]}))},week:{dow:1,doy:4}})}(n(5093))},4451:function(e,t,n){!function(e){"use strict";var t={1:"೧",2:"೨",3:"೩",4:"೪",5:"೫",6:"೬",7:"೭",8:"೮",9:"೯",0:"೦"},n={"೧":"1","೨":"2","೩":"3","೪":"4","೫":"5","೬":"6","೭":"7","೮":"8","೯":"9","೦":"0"};e.defineLocale("kn",{months:"ಜನವರಿ_ಫೆಬ್ರವರಿ_ಮಾರ್ಚ್_ಏಪ್ರಿಲ್_ಮೇ_ಜೂನ್_ಜುಲೈ_ಆಗಸ್ಟ್_ಸೆಪ್ಟೆಂಬರ್_ಅಕ್ಟೋಬರ್_ನವೆಂಬರ್_ಡಿಸೆಂಬರ್".split("_"),monthsShort:"ಜನ_ಫೆಬ್ರ_ಮಾರ್ಚ್_ಏಪ್ರಿಲ್_ಮೇ_ಜೂನ್_ಜುಲೈ_ಆಗಸ್ಟ್_ಸೆಪ್ಟೆಂ_ಅಕ್ಟೋ_ನವೆಂ_ಡಿಸೆಂ".split("_"),monthsParseExact:!0,weekdays:"ಭಾನುವಾರ_ಸೋಮವಾರ_ಮಂಗಳವಾರ_ಬುಧವಾರ_ಗುರುವಾರ_ಶುಕ್ರವಾರ_ಶನಿವಾರ".split("_"),weekdaysShort:"ಭಾನು_ಸೋಮ_ಮಂಗಳ_ಬುಧ_ಗುರು_ಶುಕ್ರ_ಶನಿ".split("_"),weekdaysMin:"ಭಾ_ಸೋ_ಮಂ_ಬು_ಗು_ಶು_ಶ".split("_"),longDateFormat:{LT:"A h:mm",LTS:"A h:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm",LLLL:"dddd, D MMMM YYYY, A h:mm"},calendar:{sameDay:"[ಇಂದು] LT",nextDay:"[ನಾಳೆ] LT",nextWeek:"dddd, LT",lastDay:"[ನಿನ್ನೆ] LT",lastWeek:"[ಕೊನೆಯ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s ನಂತರ",past:"%s ಹಿಂದೆ",s:"ಕೆಲವು ಕ್ಷಣಗಳು",ss:"%d ಸೆಕೆಂಡುಗಳು",m:"ಒಂದು ನಿಮಿಷ",mm:"%d ನಿಮಿಷ",h:"ಒಂದು ಗಂಟೆ",hh:"%d ಗಂಟೆ",d:"ಒಂದು ದಿನ",dd:"%d ದಿನ",M:"ಒಂದು ತಿಂಗಳು",MM:"%d ತಿಂಗಳು",y:"ಒಂದು ವರ್ಷ",yy:"%d ವರ್ಷ"},preparse:function(e){return e.replace(/[೧೨೩೪೫೬೭೮೯೦]/g,(function(e){return n[e]}))},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]}))},meridiemParse:/ರಾತ್ರಿ|ಬೆಳಿಗ್ಗೆ|ಮಧ್ಯಾಹ್ನ|ಸಂಜೆ/,meridiemHour:function(e,t){return 12===e&&(e=0),"ರಾತ್ರಿ"===t?e<4?e:e+12:"ಬೆಳಿಗ್ಗೆ"===t?e:"ಮಧ್ಯಾಹ್ನ"===t?e>=10?e:e+12:"ಸಂಜೆ"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"ರಾತ್ರಿ":e<10?"ಬೆಳಿಗ್ಗೆ":e<17?"ಮಧ್ಯಾಹ್ನ":e<20?"ಸಂಜೆ":"ರಾತ್ರಿ"},dayOfMonthOrdinalParse:/\d{1,2}(ನೇ)/,ordinal:function(e){return e+"ನೇ"},week:{dow:0,doy:6}})}(n(5093))},3164:function(e,t,n){!function(e){"use strict";e.defineLocale("ko",{months:"1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월".split("_"),monthsShort:"1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월".split("_"),weekdays:"일요일_월요일_화요일_수요일_목요일_금요일_토요일".split("_"),weekdaysShort:"일_월_화_수_목_금_토".split("_"),weekdaysMin:"일_월_화_수_목_금_토".split("_"),longDateFormat:{LT:"A h:mm",LTS:"A h:mm:ss",L:"YYYY.MM.DD.",LL:"YYYY년 MMMM D일",LLL:"YYYY년 MMMM D일 A h:mm",LLLL:"YYYY년 MMMM D일 dddd A h:mm",l:"YYYY.MM.DD.",ll:"YYYY년 MMMM D일",lll:"YYYY년 MMMM D일 A h:mm",llll:"YYYY년 MMMM D일 dddd A h:mm"},calendar:{sameDay:"오늘 LT",nextDay:"내일 LT",nextWeek:"dddd LT",lastDay:"어제 LT",lastWeek:"지난주 dddd LT",sameElse:"L"},relativeTime:{future:"%s 후",past:"%s 전",s:"몇 초",ss:"%d초",m:"1분",mm:"%d분",h:"한 시간",hh:"%d시간",d:"하루",dd:"%d일",M:"한 달",MM:"%d달",y:"일 년",yy:"%d년"},dayOfMonthOrdinalParse:/\d{1,2}(일|월|주)/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"일";case"M":return e+"월";case"w":case"W":return e+"주";default:return e}},meridiemParse:/오전|오후/,isPM:function(e){return"오후"===e},meridiem:function(e,t,n){return e<12?"오전":"오후"}})}(n(5093))},6181:function(e,t,n){!function(e){"use strict";function t(e,t,n,i){var r={s:["çend sanîye","çend sanîyeyan"],ss:[e+" sanîye",e+" sanîyeyan"],m:["deqîqeyek","deqîqeyekê"],mm:[e+" deqîqe",e+" deqîqeyan"],h:["saetek","saetekê"],hh:[e+" saet",e+" saetan"],d:["rojek","rojekê"],dd:[e+" roj",e+" rojan"],w:["hefteyek","hefteyekê"],ww:[e+" hefte",e+" hefteyan"],M:["mehek","mehekê"],MM:[e+" meh",e+" mehan"],y:["salek","salekê"],yy:[e+" sal",e+" salan"]};return t?r[n][0]:r[n][1]}e.defineLocale("ku-kmr",{months:"Rêbendan_Sibat_Adar_Nîsan_Gulan_Hezîran_Tîrmeh_Tebax_Îlon_Cotmeh_Mijdar_Berfanbar".split("_"),monthsShort:"Rêb_Sib_Ada_Nîs_Gul_Hez_Tîr_Teb_Îlo_Cot_Mij_Ber".split("_"),monthsParseExact:!0,weekdays:"Yekşem_Duşem_Sêşem_Çarşem_Pêncşem_În_Şemî".split("_"),weekdaysShort:"Yek_Du_Sê_Çar_Pên_În_Şem".split("_"),weekdaysMin:"Ye_Du_Sê_Ça_Pê_În_Şe".split("_"),meridiem:function(e,t,n){return e<12?n?"bn":"BN":n?"pn":"PN"},meridiemParse:/bn|BN|pn|PN/,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"Do MMMM[a] YYYY[an]",LLL:"Do MMMM[a] YYYY[an] HH:mm",LLLL:"dddd, Do MMMM[a] YYYY[an] HH:mm",ll:"Do MMM[.] YYYY[an]",lll:"Do MMM[.] YYYY[an] HH:mm",llll:"ddd[.], Do MMM[.] YYYY[an] HH:mm"},calendar:{sameDay:"[Îro di saet] LT [de]",nextDay:"[Sibê di saet] LT [de]",nextWeek:"dddd [di saet] LT [de]",lastDay:"[Duh di saet] LT [de]",lastWeek:"dddd[a borî di saet] LT [de]",sameElse:"L"},relativeTime:{future:"di %s de",past:"berî %s",s:t,ss:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,w:t,ww:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}(?:yê|ê|\.)/,ordinal:function(e,t){var n=t.toLowerCase();return n.includes("w")||n.includes("m")?e+".":e+function(e){var t=(e=""+e).substring(e.length-1),n=e.length>1?e.substring(e.length-2):"";return 12==n||13==n||"2"!=t&&"3"!=t&&"50"!=n&&"70"!=t&&"80"!=t?"ê":"yê"}(e)},week:{dow:1,doy:4}})}(n(5093))},8174:function(e,t,n){!function(e){"use strict";var t={1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩",0:"٠"},n={"١":"1","٢":"2","٣":"3","٤":"4","٥":"5","٦":"6","٧":"7","٨":"8","٩":"9","٠":"0"},i=["کانونی دووەم","شوبات","ئازار","نیسان","ئایار","حوزەیران","تەمموز","ئاب","ئەیلوول","تشرینی یەكەم","تشرینی دووەم","كانونی یەکەم"];e.defineLocale("ku",{months:i,monthsShort:i,weekdays:"یهكشهممه_دووشهممه_سێشهممه_چوارشهممه_پێنجشهممه_ههینی_شهممه".split("_"),weekdaysShort:"یهكشهم_دووشهم_سێشهم_چوارشهم_پێنجشهم_ههینی_شهممه".split("_"),weekdaysMin:"ی_د_س_چ_پ_ه_ش".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},meridiemParse:/ئێواره|بهیانی/,isPM:function(e){return/ئێواره/.test(e)},meridiem:function(e,t,n){return e<12?"بهیانی":"ئێواره"},calendar:{sameDay:"[ئهمرۆ كاتژمێر] LT",nextDay:"[بهیانی كاتژمێر] LT",nextWeek:"dddd [كاتژمێر] LT",lastDay:"[دوێنێ كاتژمێر] LT",lastWeek:"dddd [كاتژمێر] LT",sameElse:"L"},relativeTime:{future:"له %s",past:"%s",s:"چهند چركهیهك",ss:"چركه %d",m:"یهك خولهك",mm:"%d خولهك",h:"یهك كاتژمێر",hh:"%d كاتژمێر",d:"یهك ڕۆژ",dd:"%d ڕۆژ",M:"یهك مانگ",MM:"%d مانگ",y:"یهك ساڵ",yy:"%d ساڵ"},preparse:function(e){return e.replace(/[١٢٣٤٥٦٧٨٩٠]/g,(function(e){return n[e]})).replace(/،/g,",")},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]})).replace(/,/g,"،")},week:{dow:6,doy:12}})}(n(5093))},8474:function(e,t,n){!function(e){"use strict";var t={0:"-чү",1:"-чи",2:"-чи",3:"-чү",4:"-чү",5:"-чи",6:"-чы",7:"-чи",8:"-чи",9:"-чу",10:"-чу",20:"-чы",30:"-чу",40:"-чы",50:"-чү",60:"-чы",70:"-чи",80:"-чи",90:"-чу",100:"-чү"};e.defineLocale("ky",{months:"январь_февраль_март_апрель_май_июнь_июль_август_сентябрь_октябрь_ноябрь_декабрь".split("_"),monthsShort:"янв_фев_март_апр_май_июнь_июль_авг_сен_окт_ноя_дек".split("_"),weekdays:"Жекшемби_Дүйшөмбү_Шейшемби_Шаршемби_Бейшемби_Жума_Ишемби".split("_"),weekdaysShort:"Жек_Дүй_Шей_Шар_Бей_Жум_Ише".split("_"),weekdaysMin:"Жк_Дй_Шй_Шр_Бй_Жм_Иш".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Бүгүн саат] LT",nextDay:"[Эртең саат] LT",nextWeek:"dddd [саат] LT",lastDay:"[Кечээ саат] LT",lastWeek:"[Өткөн аптанын] dddd [күнү] [саат] LT",sameElse:"L"},relativeTime:{future:"%s ичинде",past:"%s мурун",s:"бирнече секунд",ss:"%d секунд",m:"бир мүнөт",mm:"%d мүнөт",h:"бир саат",hh:"%d саат",d:"бир күн",dd:"%d күн",M:"бир ай",MM:"%d ай",y:"бир жыл",yy:"%d жыл"},dayOfMonthOrdinalParse:/\d{1,2}-(чи|чы|чү|чу)/,ordinal:function(e){return e+(t[e]||t[e%10]||t[e>=100?100:null])},week:{dow:1,doy:7}})}(n(5093))},9680:function(e,t,n){!function(e){"use strict";function t(e,t,n,i){var r={m:["eng Minutt","enger Minutt"],h:["eng Stonn","enger Stonn"],d:["een Dag","engem Dag"],M:["ee Mount","engem Mount"],y:["ee Joer","engem Joer"]};return t?r[n][0]:r[n][1]}function n(e){if(e=parseInt(e,10),isNaN(e))return!1;if(e<0)return!0;if(e<10)return 4<=e&&e<=7;if(e<100){var t=e%10;return n(0===t?e/10:t)}if(e<1e4){for(;e>=10;)e/=10;return n(e)}return n(e/=1e3)}e.defineLocale("lb",{months:"Januar_Februar_Mäerz_Abrëll_Mee_Juni_Juli_August_September_Oktober_November_Dezember".split("_"),monthsShort:"Jan._Febr._Mrz._Abr._Mee_Jun._Jul._Aug._Sept._Okt._Nov._Dez.".split("_"),monthsParseExact:!0,weekdays:"Sonndeg_Méindeg_Dënschdeg_Mëttwoch_Donneschdeg_Freideg_Samschdeg".split("_"),weekdaysShort:"So._Mé._Dë._Më._Do._Fr._Sa.".split("_"),weekdaysMin:"So_Mé_Dë_Më_Do_Fr_Sa".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm [Auer]",LTS:"H:mm:ss [Auer]",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm [Auer]",LLLL:"dddd, D. MMMM YYYY H:mm [Auer]"},calendar:{sameDay:"[Haut um] LT",sameElse:"L",nextDay:"[Muer um] LT",nextWeek:"dddd [um] LT",lastDay:"[Gëschter um] LT",lastWeek:function(){switch(this.day()){case 2:case 4:return"[Leschten] dddd [um] LT";default:return"[Leschte] dddd [um] LT"}}},relativeTime:{future:function(e){return n(e.substr(0,e.indexOf(" ")))?"a "+e:"an "+e},past:function(e){return n(e.substr(0,e.indexOf(" ")))?"viru "+e:"virun "+e},s:"e puer Sekonnen",ss:"%d Sekonnen",m:t,mm:"%d Minutten",h:t,hh:"%d Stonnen",d:t,dd:"%d Deeg",M:t,MM:"%d Méint",y:t,yy:"%d Joer"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},5867:function(e,t,n){!function(e){"use strict";e.defineLocale("lo",{months:"ມັງກອນ_ກຸມພາ_ມີນາ_ເມສາ_ພຶດສະພາ_ມິຖຸນາ_ກໍລະກົດ_ສິງຫາ_ກັນຍາ_ຕຸລາ_ພະຈິກ_ທັນວາ".split("_"),monthsShort:"ມັງກອນ_ກຸມພາ_ມີນາ_ເມສາ_ພຶດສະພາ_ມິຖຸນາ_ກໍລະກົດ_ສິງຫາ_ກັນຍາ_ຕຸລາ_ພະຈິກ_ທັນວາ".split("_"),weekdays:"ອາທິດ_ຈັນ_ອັງຄານ_ພຸດ_ພະຫັດ_ສຸກ_ເສົາ".split("_"),weekdaysShort:"ທິດ_ຈັນ_ອັງຄານ_ພຸດ_ພະຫັດ_ສຸກ_ເສົາ".split("_"),weekdaysMin:"ທ_ຈ_ອຄ_ພ_ພຫ_ສກ_ສ".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"ວັນdddd D MMMM YYYY HH:mm"},meridiemParse:/ຕອນເຊົ້າ|ຕອນແລງ/,isPM:function(e){return"ຕອນແລງ"===e},meridiem:function(e,t,n){return e<12?"ຕອນເຊົ້າ":"ຕອນແລງ"},calendar:{sameDay:"[ມື້ນີ້ເວລາ] LT",nextDay:"[ມື້ອື່ນເວລາ] LT",nextWeek:"[ວັນ]dddd[ໜ້າເວລາ] LT",lastDay:"[ມື້ວານນີ້ເວລາ] LT",lastWeek:"[ວັນ]dddd[ແລ້ວນີ້ເວລາ] LT",sameElse:"L"},relativeTime:{future:"ອີກ %s",past:"%sຜ່ານມາ",s:"ບໍ່ເທົ່າໃດວິນາທີ",ss:"%d ວິນາທີ",m:"1 ນາທີ",mm:"%d ນາທີ",h:"1 ຊົ່ວໂມງ",hh:"%d ຊົ່ວໂມງ",d:"1 ມື້",dd:"%d ມື້",M:"1 ເດືອນ",MM:"%d ເດືອນ",y:"1 ປີ",yy:"%d ປີ"},dayOfMonthOrdinalParse:/(ທີ່)\d{1,2}/,ordinal:function(e){return"ທີ່"+e}})}(n(5093))},5766:function(e,t,n){!function(e){"use strict";var t={ss:"sekundė_sekundžių_sekundes",m:"minutė_minutės_minutę",mm:"minutės_minučių_minutes",h:"valanda_valandos_valandą",hh:"valandos_valandų_valandas",d:"diena_dienos_dieną",dd:"dienos_dienų_dienas",M:"mėnuo_mėnesio_mėnesį",MM:"mėnesiai_mėnesių_mėnesius",y:"metai_metų_metus",yy:"metai_metų_metus"};function n(e,t,n,i){return t?r(n)[0]:i?r(n)[1]:r(n)[2]}function i(e){return e%10==0||e>10&&e<20}function r(e){return t[e].split("_")}function a(e,t,a,s){var o=e+" ";return 1===e?o+n(0,t,a[0],s):t?o+(i(e)?r(a)[1]:r(a)[0]):s?o+r(a)[1]:o+(i(e)?r(a)[1]:r(a)[2])}e.defineLocale("lt",{months:{format:"sausio_vasario_kovo_balandžio_gegužės_birželio_liepos_rugpjūčio_rugsėjo_spalio_lapkričio_gruodžio".split("_"),standalone:"sausis_vasaris_kovas_balandis_gegužė_birželis_liepa_rugpjūtis_rugsėjis_spalis_lapkritis_gruodis".split("_"),isFormat:/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?|MMMM?(\[[^\[\]]*\]|\s)+D[oD]?/},monthsShort:"sau_vas_kov_bal_geg_bir_lie_rgp_rgs_spa_lap_grd".split("_"),weekdays:{format:"sekmadienį_pirmadienį_antradienį_trečiadienį_ketvirtadienį_penktadienį_šeštadienį".split("_"),standalone:"sekmadienis_pirmadienis_antradienis_trečiadienis_ketvirtadienis_penktadienis_šeštadienis".split("_"),isFormat:/dddd HH:mm/},weekdaysShort:"Sek_Pir_Ant_Tre_Ket_Pen_Šeš".split("_"),weekdaysMin:"S_P_A_T_K_Pn_Š".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"YYYY [m.] MMMM D [d.]",LLL:"YYYY [m.] MMMM D [d.], HH:mm [val.]",LLLL:"YYYY [m.] MMMM D [d.], dddd, HH:mm [val.]",l:"YYYY-MM-DD",ll:"YYYY [m.] MMMM D [d.]",lll:"YYYY [m.] MMMM D [d.], HH:mm [val.]",llll:"YYYY [m.] MMMM D [d.], ddd, HH:mm [val.]"},calendar:{sameDay:"[Šiandien] LT",nextDay:"[Rytoj] LT",nextWeek:"dddd LT",lastDay:"[Vakar] LT",lastWeek:"[Praėjusį] dddd LT",sameElse:"L"},relativeTime:{future:"po %s",past:"prieš %s",s:function(e,t,n,i){return t?"kelios sekundės":i?"kelių sekundžių":"kelias sekundes"},ss:a,m:n,mm:a,h:n,hh:a,d:n,dd:a,M:n,MM:a,y:n,yy:a},dayOfMonthOrdinalParse:/\d{1,2}-oji/,ordinal:function(e){return e+"-oji"},week:{dow:1,doy:4}})}(n(5093))},9532:function(e,t,n){!function(e){"use strict";var t={ss:"sekundes_sekundēm_sekunde_sekundes".split("_"),m:"minūtes_minūtēm_minūte_minūtes".split("_"),mm:"minūtes_minūtēm_minūte_minūtes".split("_"),h:"stundas_stundām_stunda_stundas".split("_"),hh:"stundas_stundām_stunda_stundas".split("_"),d:"dienas_dienām_diena_dienas".split("_"),dd:"dienas_dienām_diena_dienas".split("_"),M:"mēneša_mēnešiem_mēnesis_mēneši".split("_"),MM:"mēneša_mēnešiem_mēnesis_mēneši".split("_"),y:"gada_gadiem_gads_gadi".split("_"),yy:"gada_gadiem_gads_gadi".split("_")};function n(e,t,n){return n?t%10==1&&t%100!=11?e[2]:e[3]:t%10==1&&t%100!=11?e[0]:e[1]}function i(e,i,r){return e+" "+n(t[r],e,i)}function r(e,i,r){return n(t[r],e,i)}e.defineLocale("lv",{months:"janvāris_februāris_marts_aprīlis_maijs_jūnijs_jūlijs_augusts_septembris_oktobris_novembris_decembris".split("_"),monthsShort:"jan_feb_mar_apr_mai_jūn_jūl_aug_sep_okt_nov_dec".split("_"),weekdays:"svētdiena_pirmdiena_otrdiena_trešdiena_ceturtdiena_piektdiena_sestdiena".split("_"),weekdaysShort:"Sv_P_O_T_C_Pk_S".split("_"),weekdaysMin:"Sv_P_O_T_C_Pk_S".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY.",LL:"YYYY. [gada] D. MMMM",LLL:"YYYY. [gada] D. MMMM, HH:mm",LLLL:"YYYY. [gada] D. MMMM, dddd, HH:mm"},calendar:{sameDay:"[Šodien pulksten] LT",nextDay:"[Rīt pulksten] LT",nextWeek:"dddd [pulksten] LT",lastDay:"[Vakar pulksten] LT",lastWeek:"[Pagājušā] dddd [pulksten] LT",sameElse:"L"},relativeTime:{future:"pēc %s",past:"pirms %s",s:function(e,t){return t?"dažas sekundes":"dažām sekundēm"},ss:i,m:r,mm:i,h:r,hh:i,d:r,dd:i,M:r,MM:i,y:r,yy:i},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},8076:function(e,t,n){!function(e){"use strict";var t={words:{ss:["sekund","sekunda","sekundi"],m:["jedan minut","jednog minuta"],mm:["minut","minuta","minuta"],h:["jedan sat","jednog sata"],hh:["sat","sata","sati"],dd:["dan","dana","dana"],MM:["mjesec","mjeseca","mjeseci"],yy:["godina","godine","godina"]},correctGrammaticalCase:function(e,t){return 1===e?t[0]:e>=2&&e<=4?t[1]:t[2]},translate:function(e,n,i){var r=t.words[i];return 1===i.length?n?r[0]:r[1]:e+" "+t.correctGrammaticalCase(e,r)}};e.defineLocale("me",{months:"januar_februar_mart_april_maj_jun_jul_avgust_septembar_oktobar_novembar_decembar".split("_"),monthsShort:"jan._feb._mar._apr._maj_jun_jul_avg._sep._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sri._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd, D. MMMM YYYY H:mm"},calendar:{sameDay:"[danas u] LT",nextDay:"[sjutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedjelju] [u] LT";case 3:return"[u] [srijedu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[juče u] LT",lastWeek:function(){return["[prošle] [nedjelje] [u] LT","[prošlog] [ponedjeljka] [u] LT","[prošlog] [utorka] [u] LT","[prošle] [srijede] [u] LT","[prošlog] [četvrtka] [u] LT","[prošlog] [petka] [u] LT","[prošle] [subote] [u] LT"][this.day()]},sameElse:"L"},relativeTime:{future:"za %s",past:"prije %s",s:"nekoliko sekundi",ss:t.translate,m:t.translate,mm:t.translate,h:t.translate,hh:t.translate,d:"dan",dd:t.translate,M:"mjesec",MM:t.translate,y:"godinu",yy:t.translate},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(5093))},1848:function(e,t,n){!function(e){"use strict";e.defineLocale("mi",{months:"Kohi-tāte_Hui-tanguru_Poutū-te-rangi_Paenga-whāwhā_Haratua_Pipiri_Hōngoingoi_Here-turi-kōkā_Mahuru_Whiringa-ā-nuku_Whiringa-ā-rangi_Hakihea".split("_"),monthsShort:"Kohi_Hui_Pou_Pae_Hara_Pipi_Hōngoi_Here_Mahu_Whi-nu_Whi-ra_Haki".split("_"),monthsRegex:/(?:['a-z\u0101\u014D\u016B]+\-?){1,3}/i,monthsStrictRegex:/(?:['a-z\u0101\u014D\u016B]+\-?){1,3}/i,monthsShortRegex:/(?:['a-z\u0101\u014D\u016B]+\-?){1,3}/i,monthsShortStrictRegex:/(?:['a-z\u0101\u014D\u016B]+\-?){1,2}/i,weekdays:"Rātapu_Mane_Tūrei_Wenerei_Tāite_Paraire_Hātarei".split("_"),weekdaysShort:"Ta_Ma_Tū_We_Tāi_Pa_Hā".split("_"),weekdaysMin:"Ta_Ma_Tū_We_Tāi_Pa_Hā".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [i] HH:mm",LLLL:"dddd, D MMMM YYYY [i] HH:mm"},calendar:{sameDay:"[i teie mahana, i] LT",nextDay:"[apopo i] LT",nextWeek:"dddd [i] LT",lastDay:"[inanahi i] LT",lastWeek:"dddd [whakamutunga i] LT",sameElse:"L"},relativeTime:{future:"i roto i %s",past:"%s i mua",s:"te hēkona ruarua",ss:"%d hēkona",m:"he meneti",mm:"%d meneti",h:"te haora",hh:"%d haora",d:"he ra",dd:"%d ra",M:"he marama",MM:"%d marama",y:"he tau",yy:"%d tau"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(5093))},306:function(e,t,n){!function(e){"use strict";e.defineLocale("mk",{months:"јануари_февруари_март_април_мај_јуни_јули_август_септември_октомври_ноември_декември".split("_"),monthsShort:"јан_фев_мар_апр_мај_јун_јул_авг_сеп_окт_ное_дек".split("_"),weekdays:"недела_понеделник_вторник_среда_четврток_петок_сабота".split("_"),weekdaysShort:"нед_пон_вто_сре_чет_пет_саб".split("_"),weekdaysMin:"нe_пo_вт_ср_че_пе_сa".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"D.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY H:mm",LLLL:"dddd, D MMMM YYYY H:mm"},calendar:{sameDay:"[Денес во] LT",nextDay:"[Утре во] LT",nextWeek:"[Во] dddd [во] LT",lastDay:"[Вчера во] LT",lastWeek:function(){switch(this.day()){case 0:case 3:case 6:return"[Изминатата] dddd [во] LT";case 1:case 2:case 4:case 5:return"[Изминатиот] dddd [во] LT"}},sameElse:"L"},relativeTime:{future:"за %s",past:"пред %s",s:"неколку секунди",ss:"%d секунди",m:"една минута",mm:"%d минути",h:"еден час",hh:"%d часа",d:"еден ден",dd:"%d дена",M:"еден месец",MM:"%d месеци",y:"една година",yy:"%d години"},dayOfMonthOrdinalParse:/\d{1,2}-(ев|ен|ти|ви|ри|ми)/,ordinal:function(e){var t=e%10,n=e%100;return 0===e?e+"-ев":0===n?e+"-ен":n>10&&n<20?e+"-ти":1===t?e+"-ви":2===t?e+"-ри":7===t||8===t?e+"-ми":e+"-ти"},week:{dow:1,doy:7}})}(n(5093))},3739:function(e,t,n){!function(e){"use strict";e.defineLocale("ml",{months:"ജനുവരി_ഫെബ്രുവരി_മാർച്ച്_ഏപ്രിൽ_മേയ്_ജൂൺ_ജൂലൈ_ഓഗസ്റ്റ്_സെപ്റ്റംബർ_ഒക്ടോബർ_നവംബർ_ഡിസംബർ".split("_"),monthsShort:"ജനു._ഫെബ്രു._മാർ._ഏപ്രി._മേയ്_ജൂൺ_ജൂലൈ._ഓഗ._സെപ്റ്റ._ഒക്ടോ._നവം._ഡിസം.".split("_"),monthsParseExact:!0,weekdays:"ഞായറാഴ്ച_തിങ്കളാഴ്ച_ചൊവ്വാഴ്ച_ബുധനാഴ്ച_വ്യാഴാഴ്ച_വെള്ളിയാഴ്ച_ശനിയാഴ്ച".split("_"),weekdaysShort:"ഞായർ_തിങ്കൾ_ചൊവ്വ_ബുധൻ_വ്യാഴം_വെള്ളി_ശനി".split("_"),weekdaysMin:"ഞാ_തി_ചൊ_ബു_വ്യാ_വെ_ശ".split("_"),longDateFormat:{LT:"A h:mm -നു",LTS:"A h:mm:ss -നു",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm -നു",LLLL:"dddd, D MMMM YYYY, A h:mm -നു"},calendar:{sameDay:"[ഇന്ന്] LT",nextDay:"[നാളെ] LT",nextWeek:"dddd, LT",lastDay:"[ഇന്നലെ] LT",lastWeek:"[കഴിഞ്ഞ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s കഴിഞ്ഞ്",past:"%s മുൻപ്",s:"അൽപ നിമിഷങ്ങൾ",ss:"%d സെക്കൻഡ്",m:"ഒരു മിനിറ്റ്",mm:"%d മിനിറ്റ്",h:"ഒരു മണിക്കൂർ",hh:"%d മണിക്കൂർ",d:"ഒരു ദിവസം",dd:"%d ദിവസം",M:"ഒരു മാസം",MM:"%d മാസം",y:"ഒരു വർഷം",yy:"%d വർഷം"},meridiemParse:/രാത്രി|രാവിലെ|ഉച്ച കഴിഞ്ഞ്|വൈകുന്നേരം|രാത്രി/i,meridiemHour:function(e,t){return 12===e&&(e=0),"രാത്രി"===t&&e>=4||"ഉച്ച കഴിഞ്ഞ്"===t||"വൈകുന്നേരം"===t?e+12:e},meridiem:function(e,t,n){return e<4?"രാത്രി":e<12?"രാവിലെ":e<17?"ഉച്ച കഴിഞ്ഞ്":e<20?"വൈകുന്നേരം":"രാത്രി"}})}(n(5093))},9053:function(e,t,n){!function(e){"use strict";function t(e,t,n,i){switch(n){case"s":return t?"хэдхэн секунд":"хэдхэн секундын";case"ss":return e+(t?" секунд":" секундын");case"m":case"mm":return e+(t?" минут":" минутын");case"h":case"hh":return e+(t?" цаг":" цагийн");case"d":case"dd":return e+(t?" өдөр":" өдрийн");case"M":case"MM":return e+(t?" сар":" сарын");case"y":case"yy":return e+(t?" жил":" жилийн");default:return e}}e.defineLocale("mn",{months:"Нэгдүгээр сар_Хоёрдугаар сар_Гуравдугаар сар_Дөрөвдүгээр сар_Тавдугаар сар_Зургадугаар сар_Долдугаар сар_Наймдугаар сар_Есдүгээр сар_Аравдугаар сар_Арван нэгдүгээр сар_Арван хоёрдугаар сар".split("_"),monthsShort:"1 сар_2 сар_3 сар_4 сар_5 сар_6 сар_7 сар_8 сар_9 сар_10 сар_11 сар_12 сар".split("_"),monthsParseExact:!0,weekdays:"Ням_Даваа_Мягмар_Лхагва_Пүрэв_Баасан_Бямба".split("_"),weekdaysShort:"Ням_Дав_Мяг_Лха_Пүр_Баа_Бям".split("_"),weekdaysMin:"Ня_Да_Мя_Лх_Пү_Ба_Бя".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"YYYY оны MMMMын D",LLL:"YYYY оны MMMMын D HH:mm",LLLL:"dddd, YYYY оны MMMMын D HH:mm"},meridiemParse:/ҮӨ|ҮХ/i,isPM:function(e){return"ҮХ"===e},meridiem:function(e,t,n){return e<12?"ҮӨ":"ҮХ"},calendar:{sameDay:"[Өнөөдөр] LT",nextDay:"[Маргааш] LT",nextWeek:"[Ирэх] dddd LT",lastDay:"[Өчигдөр] LT",lastWeek:"[Өнгөрсөн] dddd LT",sameElse:"L"},relativeTime:{future:"%s дараа",past:"%s өмнө",s:t,ss:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2} өдөр/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+" өдөр";default:return e}}})}(n(5093))},6169:function(e,t,n){!function(e){"use strict";var t={1:"१",2:"२",3:"३",4:"४",5:"५",6:"६",7:"७",8:"८",9:"९",0:"०"},n={"१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9","०":"0"};function i(e,t,n,i){var r="";if(t)switch(n){case"s":r="काही सेकंद";break;case"ss":r="%d सेकंद";break;case"m":r="एक मिनिट";break;case"mm":r="%d मिनिटे";break;case"h":r="एक तास";break;case"hh":r="%d तास";break;case"d":r="एक दिवस";break;case"dd":r="%d दिवस";break;case"M":r="एक महिना";break;case"MM":r="%d महिने";break;case"y":r="एक वर्ष";break;case"yy":r="%d वर्षे"}else switch(n){case"s":r="काही सेकंदां";break;case"ss":r="%d सेकंदां";break;case"m":r="एका मिनिटा";break;case"mm":r="%d मिनिटां";break;case"h":r="एका तासा";break;case"hh":r="%d तासां";break;case"d":r="एका दिवसा";break;case"dd":r="%d दिवसां";break;case"M":r="एका महिन्या";break;case"MM":r="%d महिन्यां";break;case"y":r="एका वर्षा";break;case"yy":r="%d वर्षां"}return r.replace(/%d/i,e)}e.defineLocale("mr",{months:"जानेवारी_फेब्रुवारी_मार्च_एप्रिल_मे_जून_जुलै_ऑगस्ट_सप्टेंबर_ऑक्टोबर_नोव्हेंबर_डिसेंबर".split("_"),monthsShort:"जाने._फेब्रु._मार्च._एप्रि._मे._जून._जुलै._ऑग._सप्टें._ऑक्टो._नोव्हें._डिसें.".split("_"),monthsParseExact:!0,weekdays:"रविवार_सोमवार_मंगळवार_बुधवार_गुरूवार_शुक्रवार_शनिवार".split("_"),weekdaysShort:"रवि_सोम_मंगळ_बुध_गुरू_शुक्र_शनि".split("_"),weekdaysMin:"र_सो_मं_बु_गु_शु_श".split("_"),longDateFormat:{LT:"A h:mm वाजता",LTS:"A h:mm:ss वाजता",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm वाजता",LLLL:"dddd, D MMMM YYYY, A h:mm वाजता"},calendar:{sameDay:"[आज] LT",nextDay:"[उद्या] LT",nextWeek:"dddd, LT",lastDay:"[काल] LT",lastWeek:"[मागील] dddd, LT",sameElse:"L"},relativeTime:{future:"%sमध्ये",past:"%sपूर्वी",s:i,ss:i,m:i,mm:i,h:i,hh:i,d:i,dd:i,M:i,MM:i,y:i,yy:i},preparse:function(e){return e.replace(/[१२३४५६७८९०]/g,(function(e){return n[e]}))},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]}))},meridiemParse:/पहाटे|सकाळी|दुपारी|सायंकाळी|रात्री/,meridiemHour:function(e,t){return 12===e&&(e=0),"पहाटे"===t||"सकाळी"===t?e:"दुपारी"===t||"सायंकाळी"===t||"रात्री"===t?e>=12?e:e+12:void 0},meridiem:function(e,t,n){return e>=0&&e<6?"पहाटे":e<12?"सकाळी":e<17?"दुपारी":e<20?"सायंकाळी":"रात्री"},week:{dow:0,doy:6}})}(n(5093))},2297:function(e,t,n){!function(e){"use strict";e.defineLocale("ms-my",{months:"Januari_Februari_Mac_April_Mei_Jun_Julai_Ogos_September_Oktober_November_Disember".split("_"),monthsShort:"Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ogs_Sep_Okt_Nov_Dis".split("_"),weekdays:"Ahad_Isnin_Selasa_Rabu_Khamis_Jumaat_Sabtu".split("_"),weekdaysShort:"Ahd_Isn_Sel_Rab_Kha_Jum_Sab".split("_"),weekdaysMin:"Ah_Is_Sl_Rb_Km_Jm_Sb".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},meridiemParse:/pagi|tengahari|petang|malam/,meridiemHour:function(e,t){return 12===e&&(e=0),"pagi"===t?e:"tengahari"===t?e>=11?e:e+12:"petang"===t||"malam"===t?e+12:void 0},meridiem:function(e,t,n){return e<11?"pagi":e<15?"tengahari":e<19?"petang":"malam"},calendar:{sameDay:"[Hari ini pukul] LT",nextDay:"[Esok pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kelmarin pukul] LT",lastWeek:"dddd [lepas pukul] LT",sameElse:"L"},relativeTime:{future:"dalam %s",past:"%s yang lepas",s:"beberapa saat",ss:"%d saat",m:"seminit",mm:"%d minit",h:"sejam",hh:"%d jam",d:"sehari",dd:"%d hari",M:"sebulan",MM:"%d bulan",y:"setahun",yy:"%d tahun"},week:{dow:1,doy:7}})}(n(5093))},3386:function(e,t,n){!function(e){"use strict";e.defineLocale("ms",{months:"Januari_Februari_Mac_April_Mei_Jun_Julai_Ogos_September_Oktober_November_Disember".split("_"),monthsShort:"Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ogs_Sep_Okt_Nov_Dis".split("_"),weekdays:"Ahad_Isnin_Selasa_Rabu_Khamis_Jumaat_Sabtu".split("_"),weekdaysShort:"Ahd_Isn_Sel_Rab_Kha_Jum_Sab".split("_"),weekdaysMin:"Ah_Is_Sl_Rb_Km_Jm_Sb".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [pukul] HH.mm",LLLL:"dddd, D MMMM YYYY [pukul] HH.mm"},meridiemParse:/pagi|tengahari|petang|malam/,meridiemHour:function(e,t){return 12===e&&(e=0),"pagi"===t?e:"tengahari"===t?e>=11?e:e+12:"petang"===t||"malam"===t?e+12:void 0},meridiem:function(e,t,n){return e<11?"pagi":e<15?"tengahari":e<19?"petang":"malam"},calendar:{sameDay:"[Hari ini pukul] LT",nextDay:"[Esok pukul] LT",nextWeek:"dddd [pukul] LT",lastDay:"[Kelmarin pukul] LT",lastWeek:"dddd [lepas pukul] LT",sameElse:"L"},relativeTime:{future:"dalam %s",past:"%s yang lepas",s:"beberapa saat",ss:"%d saat",m:"seminit",mm:"%d minit",h:"sejam",hh:"%d jam",d:"sehari",dd:"%d hari",M:"sebulan",MM:"%d bulan",y:"setahun",yy:"%d tahun"},week:{dow:1,doy:7}})}(n(5093))},7075:function(e,t,n){!function(e){"use strict";e.defineLocale("mt",{months:"Jannar_Frar_Marzu_April_Mejju_Ġunju_Lulju_Awwissu_Settembru_Ottubru_Novembru_Diċembru".split("_"),monthsShort:"Jan_Fra_Mar_Apr_Mej_Ġun_Lul_Aww_Set_Ott_Nov_Diċ".split("_"),weekdays:"Il-Ħadd_It-Tnejn_It-Tlieta_L-Erbgħa_Il-Ħamis_Il-Ġimgħa_Is-Sibt".split("_"),weekdaysShort:"Ħad_Tne_Tli_Erb_Ħam_Ġim_Sib".split("_"),weekdaysMin:"Ħa_Tn_Tl_Er_Ħa_Ġi_Si".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Illum fil-]LT",nextDay:"[Għada fil-]LT",nextWeek:"dddd [fil-]LT",lastDay:"[Il-bieraħ fil-]LT",lastWeek:"dddd [li għadda] [fil-]LT",sameElse:"L"},relativeTime:{future:"f’ %s",past:"%s ilu",s:"ftit sekondi",ss:"%d sekondi",m:"minuta",mm:"%d minuti",h:"siegħa",hh:"%d siegħat",d:"ġurnata",dd:"%d ġranet",M:"xahar",MM:"%d xhur",y:"sena",yy:"%d sni"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(5093))},2264:function(e,t,n){!function(e){"use strict";var t={1:"၁",2:"၂",3:"၃",4:"၄",5:"၅",6:"၆",7:"၇",8:"၈",9:"၉",0:"၀"},n={"၁":"1","၂":"2","၃":"3","၄":"4","၅":"5","၆":"6","၇":"7","၈":"8","၉":"9","၀":"0"};e.defineLocale("my",{months:"ဇန်နဝါရီ_ဖေဖော်ဝါရီ_မတ်_ဧပြီ_မေ_ဇွန်_ဇူလိုင်_သြဂုတ်_စက်တင်ဘာ_အောက်တိုဘာ_နိုဝင်ဘာ_ဒီဇင်ဘာ".split("_"),monthsShort:"ဇန်_ဖေ_မတ်_ပြီ_မေ_ဇွန်_လိုင်_သြ_စက်_အောက်_နို_ဒီ".split("_"),weekdays:"တနင်္ဂနွေ_တနင်္လာ_အင်္ဂါ_ဗုဒ္ဓဟူး_ကြာသပတေး_သောကြာ_စနေ".split("_"),weekdaysShort:"နွေ_လာ_ဂါ_ဟူး_ကြာ_သော_နေ".split("_"),weekdaysMin:"နွေ_လာ_ဂါ_ဟူး_ကြာ_သော_နေ".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[ယနေ.] LT [မှာ]",nextDay:"[မနက်ဖြန်] LT [မှာ]",nextWeek:"dddd LT [မှာ]",lastDay:"[မနေ.က] LT [မှာ]",lastWeek:"[ပြီးခဲ့သော] dddd LT [မှာ]",sameElse:"L"},relativeTime:{future:"လာမည့် %s မှာ",past:"လွန်ခဲ့သော %s က",s:"စက္ကန်.အနည်းငယ်",ss:"%d စက္ကန့်",m:"တစ်မိနစ်",mm:"%d မိနစ်",h:"တစ်နာရီ",hh:"%d နာရီ",d:"တစ်ရက်",dd:"%d ရက်",M:"တစ်လ",MM:"%d လ",y:"တစ်နှစ်",yy:"%d နှစ်"},preparse:function(e){return e.replace(/[၁၂၃၄၅၆၇၈၉၀]/g,(function(e){return n[e]}))},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]}))},week:{dow:1,doy:4}})}(n(5093))},2274:function(e,t,n){!function(e){"use strict";e.defineLocale("nb",{months:"januar_februar_mars_april_mai_juni_juli_august_september_oktober_november_desember".split("_"),monthsShort:"jan._feb._mars_apr._mai_juni_juli_aug._sep._okt._nov._des.".split("_"),monthsParseExact:!0,weekdays:"søndag_mandag_tirsdag_onsdag_torsdag_fredag_lørdag".split("_"),weekdaysShort:"sø._ma._ti._on._to._fr._lø.".split("_"),weekdaysMin:"sø_ma_ti_on_to_fr_lø".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY [kl.] HH:mm",LLLL:"dddd D. MMMM YYYY [kl.] HH:mm"},calendar:{sameDay:"[i dag kl.] LT",nextDay:"[i morgen kl.] LT",nextWeek:"dddd [kl.] LT",lastDay:"[i går kl.] LT",lastWeek:"[forrige] dddd [kl.] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"%s siden",s:"noen sekunder",ss:"%d sekunder",m:"ett minutt",mm:"%d minutter",h:"én time",hh:"%d timer",d:"én dag",dd:"%d dager",w:"én uke",ww:"%d uker",M:"én måned",MM:"%d måneder",y:"ett år",yy:"%d år"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},8235:function(e,t,n){!function(e){"use strict";var t={1:"१",2:"२",3:"३",4:"४",5:"५",6:"६",7:"७",8:"८",9:"९",0:"०"},n={"१":"1","२":"2","३":"3","४":"4","५":"5","६":"6","७":"7","८":"8","९":"9","०":"0"};e.defineLocale("ne",{months:"जनवरी_फेब्रुवरी_मार्च_अप्रिल_मई_जुन_जुलाई_अगष्ट_सेप्टेम्बर_अक्टोबर_नोभेम्बर_डिसेम्बर".split("_"),monthsShort:"जन._फेब्रु._मार्च_अप्रि._मई_जुन_जुलाई._अग._सेप्ट._अक्टो._नोभे._डिसे.".split("_"),monthsParseExact:!0,weekdays:"आइतबार_सोमबार_मङ्गलबार_बुधबार_बिहिबार_शुक्रबार_शनिबार".split("_"),weekdaysShort:"आइत._सोम._मङ्गल._बुध._बिहि._शुक्र._शनि.".split("_"),weekdaysMin:"आ._सो._मं._बु._बि._शु._श.".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"Aको h:mm बजे",LTS:"Aको h:mm:ss बजे",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, Aको h:mm बजे",LLLL:"dddd, D MMMM YYYY, Aको h:mm बजे"},preparse:function(e){return e.replace(/[१२३४५६७८९०]/g,(function(e){return n[e]}))},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]}))},meridiemParse:/राति|बिहान|दिउँसो|साँझ/,meridiemHour:function(e,t){return 12===e&&(e=0),"राति"===t?e<4?e:e+12:"बिहान"===t?e:"दिउँसो"===t?e>=10?e:e+12:"साँझ"===t?e+12:void 0},meridiem:function(e,t,n){return e<3?"राति":e<12?"बिहान":e<16?"दिउँसो":e<20?"साँझ":"राति"},calendar:{sameDay:"[आज] LT",nextDay:"[भोलि] LT",nextWeek:"[आउँदो] dddd[,] LT",lastDay:"[हिजो] LT",lastWeek:"[गएको] dddd[,] LT",sameElse:"L"},relativeTime:{future:"%sमा",past:"%s अगाडि",s:"केही क्षण",ss:"%d सेकेण्ड",m:"एक मिनेट",mm:"%d मिनेट",h:"एक घण्टा",hh:"%d घण्टा",d:"एक दिन",dd:"%d दिन",M:"एक महिना",MM:"%d महिना",y:"एक बर्ष",yy:"%d बर्ष"},week:{dow:0,doy:6}})}(n(5093))},3784:function(e,t,n){!function(e){"use strict";var t="jan._feb._mrt._apr._mei_jun._jul._aug._sep._okt._nov._dec.".split("_"),n="jan_feb_mrt_apr_mei_jun_jul_aug_sep_okt_nov_dec".split("_"),i=[/^jan/i,/^feb/i,/^(maart|mrt\.?)$/i,/^apr/i,/^mei$/i,/^jun[i.]?$/i,/^jul[i.]?$/i,/^aug/i,/^sep/i,/^okt/i,/^nov/i,/^dec/i],r=/^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december|jan\.?|feb\.?|mrt\.?|apr\.?|ju[nl]\.?|aug\.?|sep\.?|okt\.?|nov\.?|dec\.?)/i;e.defineLocale("nl-be",{months:"januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december".split("_"),monthsShort:function(e,i){return e?/-MMM-/.test(i)?n[e.month()]:t[e.month()]:t},monthsRegex:r,monthsShortRegex:r,monthsStrictRegex:/^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december)/i,monthsShortStrictRegex:/^(jan\.?|feb\.?|mrt\.?|apr\.?|mei|ju[nl]\.?|aug\.?|sep\.?|okt\.?|nov\.?|dec\.?)/i,monthsParse:i,longMonthsParse:i,shortMonthsParse:i,weekdays:"zondag_maandag_dinsdag_woensdag_donderdag_vrijdag_zaterdag".split("_"),weekdaysShort:"zo._ma._di._wo._do._vr._za.".split("_"),weekdaysMin:"zo_ma_di_wo_do_vr_za".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[vandaag om] LT",nextDay:"[morgen om] LT",nextWeek:"dddd [om] LT",lastDay:"[gisteren om] LT",lastWeek:"[afgelopen] dddd [om] LT",sameElse:"L"},relativeTime:{future:"over %s",past:"%s geleden",s:"een paar seconden",ss:"%d seconden",m:"één minuut",mm:"%d minuten",h:"één uur",hh:"%d uur",d:"één dag",dd:"%d dagen",M:"één maand",MM:"%d maanden",y:"één jaar",yy:"%d jaar"},dayOfMonthOrdinalParse:/\d{1,2}(ste|de)/,ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}(n(5093))},2572:function(e,t,n){!function(e){"use strict";var t="jan._feb._mrt._apr._mei_jun._jul._aug._sep._okt._nov._dec.".split("_"),n="jan_feb_mrt_apr_mei_jun_jul_aug_sep_okt_nov_dec".split("_"),i=[/^jan/i,/^feb/i,/^(maart|mrt\.?)$/i,/^apr/i,/^mei$/i,/^jun[i.]?$/i,/^jul[i.]?$/i,/^aug/i,/^sep/i,/^okt/i,/^nov/i,/^dec/i],r=/^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december|jan\.?|feb\.?|mrt\.?|apr\.?|ju[nl]\.?|aug\.?|sep\.?|okt\.?|nov\.?|dec\.?)/i;e.defineLocale("nl",{months:"januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december".split("_"),monthsShort:function(e,i){return e?/-MMM-/.test(i)?n[e.month()]:t[e.month()]:t},monthsRegex:r,monthsShortRegex:r,monthsStrictRegex:/^(januari|februari|maart|april|mei|ju[nl]i|augustus|september|oktober|november|december)/i,monthsShortStrictRegex:/^(jan\.?|feb\.?|mrt\.?|apr\.?|mei|ju[nl]\.?|aug\.?|sep\.?|okt\.?|nov\.?|dec\.?)/i,monthsParse:i,longMonthsParse:i,shortMonthsParse:i,weekdays:"zondag_maandag_dinsdag_woensdag_donderdag_vrijdag_zaterdag".split("_"),weekdaysShort:"zo._ma._di._wo._do._vr._za.".split("_"),weekdaysMin:"zo_ma_di_wo_do_vr_za".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD-MM-YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[vandaag om] LT",nextDay:"[morgen om] LT",nextWeek:"dddd [om] LT",lastDay:"[gisteren om] LT",lastWeek:"[afgelopen] dddd [om] LT",sameElse:"L"},relativeTime:{future:"over %s",past:"%s geleden",s:"een paar seconden",ss:"%d seconden",m:"één minuut",mm:"%d minuten",h:"één uur",hh:"%d uur",d:"één dag",dd:"%d dagen",w:"één week",ww:"%d weken",M:"één maand",MM:"%d maanden",y:"één jaar",yy:"%d jaar"},dayOfMonthOrdinalParse:/\d{1,2}(ste|de)/,ordinal:function(e){return e+(1===e||8===e||e>=20?"ste":"de")},week:{dow:1,doy:4}})}(n(5093))},4566:function(e,t,n){!function(e){"use strict";e.defineLocale("nn",{months:"januar_februar_mars_april_mai_juni_juli_august_september_oktober_november_desember".split("_"),monthsShort:"jan._feb._mars_apr._mai_juni_juli_aug._sep._okt._nov._des.".split("_"),monthsParseExact:!0,weekdays:"sundag_måndag_tysdag_onsdag_torsdag_fredag_laurdag".split("_"),weekdaysShort:"su._må._ty._on._to._fr._lau.".split("_"),weekdaysMin:"su_må_ty_on_to_fr_la".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY [kl.] H:mm",LLLL:"dddd D. MMMM YYYY [kl.] HH:mm"},calendar:{sameDay:"[I dag klokka] LT",nextDay:"[I morgon klokka] LT",nextWeek:"dddd [klokka] LT",lastDay:"[I går klokka] LT",lastWeek:"[Føregåande] dddd [klokka] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"%s sidan",s:"nokre sekund",ss:"%d sekund",m:"eit minutt",mm:"%d minutt",h:"ein time",hh:"%d timar",d:"ein dag",dd:"%d dagar",w:"ei veke",ww:"%d veker",M:"ein månad",MM:"%d månader",y:"eit år",yy:"%d år"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},9330:function(e,t,n){!function(e){"use strict";e.defineLocale("oc-lnc",{months:{standalone:"genièr_febrièr_març_abril_mai_junh_julhet_agost_setembre_octòbre_novembre_decembre".split("_"),format:"de genièr_de febrièr_de març_d'abril_de mai_de junh_de julhet_d'agost_de setembre_d'octòbre_de novembre_de decembre".split("_"),isFormat:/D[oD]?(\s)+MMMM/},monthsShort:"gen._febr._març_abr._mai_junh_julh._ago._set._oct._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"dimenge_diluns_dimars_dimècres_dijòus_divendres_dissabte".split("_"),weekdaysShort:"dg._dl._dm._dc._dj._dv._ds.".split("_"),weekdaysMin:"dg_dl_dm_dc_dj_dv_ds".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM [de] YYYY",ll:"D MMM YYYY",LLL:"D MMMM [de] YYYY [a] H:mm",lll:"D MMM YYYY, H:mm",LLLL:"dddd D MMMM [de] YYYY [a] H:mm",llll:"ddd D MMM YYYY, H:mm"},calendar:{sameDay:"[uèi a] LT",nextDay:"[deman a] LT",nextWeek:"dddd [a] LT",lastDay:"[ièr a] LT",lastWeek:"dddd [passat a] LT",sameElse:"L"},relativeTime:{future:"d'aquí %s",past:"fa %s",s:"unas segondas",ss:"%d segondas",m:"una minuta",mm:"%d minutas",h:"una ora",hh:"%d oras",d:"un jorn",dd:"%d jorns",M:"un mes",MM:"%d meses",y:"un an",yy:"%d ans"},dayOfMonthOrdinalParse:/\d{1,2}(r|n|t|è|a)/,ordinal:function(e,t){var n=1===e?"r":2===e?"n":3===e?"r":4===e?"t":"è";return"w"!==t&&"W"!==t||(n="a"),e+n},week:{dow:1,doy:4}})}(n(5093))},9849:function(e,t,n){!function(e){"use strict";var t={1:"੧",2:"੨",3:"੩",4:"੪",5:"੫",6:"੬",7:"੭",8:"੮",9:"੯",0:"੦"},n={"੧":"1","੨":"2","੩":"3","੪":"4","੫":"5","੬":"6","੭":"7","੮":"8","੯":"9","੦":"0"};e.defineLocale("pa-in",{months:"ਜਨਵਰੀ_ਫ਼ਰਵਰੀ_ਮਾਰਚ_ਅਪ੍ਰੈਲ_ਮਈ_ਜੂਨ_ਜੁਲਾਈ_ਅਗਸਤ_ਸਤੰਬਰ_ਅਕਤੂਬਰ_ਨਵੰਬਰ_ਦਸੰਬਰ".split("_"),monthsShort:"ਜਨਵਰੀ_ਫ਼ਰਵਰੀ_ਮਾਰਚ_ਅਪ੍ਰੈਲ_ਮਈ_ਜੂਨ_ਜੁਲਾਈ_ਅਗਸਤ_ਸਤੰਬਰ_ਅਕਤੂਬਰ_ਨਵੰਬਰ_ਦਸੰਬਰ".split("_"),weekdays:"ਐਤਵਾਰ_ਸੋਮਵਾਰ_ਮੰਗਲਵਾਰ_ਬੁਧਵਾਰ_ਵੀਰਵਾਰ_ਸ਼ੁੱਕਰਵਾਰ_ਸ਼ਨੀਚਰਵਾਰ".split("_"),weekdaysShort:"ਐਤ_ਸੋਮ_ਮੰਗਲ_ਬੁਧ_ਵੀਰ_ਸ਼ੁਕਰ_ਸ਼ਨੀ".split("_"),weekdaysMin:"ਐਤ_ਸੋਮ_ਮੰਗਲ_ਬੁਧ_ਵੀਰ_ਸ਼ੁਕਰ_ਸ਼ਨੀ".split("_"),longDateFormat:{LT:"A h:mm ਵਜੇ",LTS:"A h:mm:ss ਵਜੇ",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm ਵਜੇ",LLLL:"dddd, D MMMM YYYY, A h:mm ਵਜੇ"},calendar:{sameDay:"[ਅਜ] LT",nextDay:"[ਕਲ] LT",nextWeek:"[ਅਗਲਾ] dddd, LT",lastDay:"[ਕਲ] LT",lastWeek:"[ਪਿਛਲੇ] dddd, LT",sameElse:"L"},relativeTime:{future:"%s ਵਿੱਚ",past:"%s ਪਿਛਲੇ",s:"ਕੁਝ ਸਕਿੰਟ",ss:"%d ਸਕਿੰਟ",m:"ਇਕ ਮਿੰਟ",mm:"%d ਮਿੰਟ",h:"ਇੱਕ ਘੰਟਾ",hh:"%d ਘੰਟੇ",d:"ਇੱਕ ਦਿਨ",dd:"%d ਦਿਨ",M:"ਇੱਕ ਮਹੀਨਾ",MM:"%d ਮਹੀਨੇ",y:"ਇੱਕ ਸਾਲ",yy:"%d ਸਾਲ"},preparse:function(e){return e.replace(/[੧੨੩੪੫੬੭੮੯੦]/g,(function(e){return n[e]}))},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]}))},meridiemParse:/ਰਾਤ|ਸਵੇਰ|ਦੁਪਹਿਰ|ਸ਼ਾਮ/,meridiemHour:function(e,t){return 12===e&&(e=0),"ਰਾਤ"===t?e<4?e:e+12:"ਸਵੇਰ"===t?e:"ਦੁਪਹਿਰ"===t?e>=10?e:e+12:"ਸ਼ਾਮ"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"ਰਾਤ":e<10?"ਸਵੇਰ":e<17?"ਦੁਪਹਿਰ":e<20?"ਸ਼ਾਮ":"ਰਾਤ"},week:{dow:0,doy:6}})}(n(5093))},4418:function(e,t,n){!function(e){"use strict";var t="styczeń_luty_marzec_kwiecień_maj_czerwiec_lipiec_sierpień_wrzesień_październik_listopad_grudzień".split("_"),n="stycznia_lutego_marca_kwietnia_maja_czerwca_lipca_sierpnia_września_października_listopada_grudnia".split("_"),i=[/^sty/i,/^lut/i,/^mar/i,/^kwi/i,/^maj/i,/^cze/i,/^lip/i,/^sie/i,/^wrz/i,/^paź/i,/^lis/i,/^gru/i];function r(e){return e%10<5&&e%10>1&&~~(e/10)%10!=1}function a(e,t,n){var i=e+" ";switch(n){case"ss":return i+(r(e)?"sekundy":"sekund");case"m":return t?"minuta":"minutę";case"mm":return i+(r(e)?"minuty":"minut");case"h":return t?"godzina":"godzinę";case"hh":return i+(r(e)?"godziny":"godzin");case"ww":return i+(r(e)?"tygodnie":"tygodni");case"MM":return i+(r(e)?"miesiące":"miesięcy");case"yy":return i+(r(e)?"lata":"lat")}}e.defineLocale("pl",{months:function(e,i){return e?/D MMMM/.test(i)?n[e.month()]:t[e.month()]:t},monthsShort:"sty_lut_mar_kwi_maj_cze_lip_sie_wrz_paź_lis_gru".split("_"),monthsParse:i,longMonthsParse:i,shortMonthsParse:i,weekdays:"niedziela_poniedziałek_wtorek_środa_czwartek_piątek_sobota".split("_"),weekdaysShort:"ndz_pon_wt_śr_czw_pt_sob".split("_"),weekdaysMin:"Nd_Pn_Wt_Śr_Cz_Pt_So".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Dziś o] LT",nextDay:"[Jutro o] LT",nextWeek:function(){switch(this.day()){case 0:return"[W niedzielę o] LT";case 2:return"[We wtorek o] LT";case 3:return"[W środę o] LT";case 6:return"[W sobotę o] LT";default:return"[W] dddd [o] LT"}},lastDay:"[Wczoraj o] LT",lastWeek:function(){switch(this.day()){case 0:return"[W zeszłą niedzielę o] LT";case 3:return"[W zeszłą środę o] LT";case 6:return"[W zeszłą sobotę o] LT";default:return"[W zeszły] dddd [o] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"%s temu",s:"kilka sekund",ss:a,m:a,mm:a,h:a,hh:a,d:"1 dzień",dd:"%d dni",w:"tydzień",ww:a,M:"miesiąc",MM:a,y:"rok",yy:a},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},8303:function(e,t,n){!function(e){"use strict";e.defineLocale("pt-br",{months:"janeiro_fevereiro_março_abril_maio_junho_julho_agosto_setembro_outubro_novembro_dezembro".split("_"),monthsShort:"jan_fev_mar_abr_mai_jun_jul_ago_set_out_nov_dez".split("_"),weekdays:"domingo_segunda-feira_terça-feira_quarta-feira_quinta-feira_sexta-feira_sábado".split("_"),weekdaysShort:"dom_seg_ter_qua_qui_sex_sáb".split("_"),weekdaysMin:"do_2ª_3ª_4ª_5ª_6ª_sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY [às] HH:mm",LLLL:"dddd, D [de] MMMM [de] YYYY [às] HH:mm"},calendar:{sameDay:"[Hoje às] LT",nextDay:"[Amanhã às] LT",nextWeek:"dddd [às] LT",lastDay:"[Ontem às] LT",lastWeek:function(){return 0===this.day()||6===this.day()?"[Último] dddd [às] LT":"[Última] dddd [às] LT"},sameElse:"L"},relativeTime:{future:"em %s",past:"há %s",s:"poucos segundos",ss:"%d segundos",m:"um minuto",mm:"%d minutos",h:"uma hora",hh:"%d horas",d:"um dia",dd:"%d dias",M:"um mês",MM:"%d meses",y:"um ano",yy:"%d anos"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",invalidDate:"Data inválida"})}(n(5093))},9834:function(e,t,n){!function(e){"use strict";e.defineLocale("pt",{months:"janeiro_fevereiro_março_abril_maio_junho_julho_agosto_setembro_outubro_novembro_dezembro".split("_"),monthsShort:"jan_fev_mar_abr_mai_jun_jul_ago_set_out_nov_dez".split("_"),weekdays:"Domingo_Segunda-feira_Terça-feira_Quarta-feira_Quinta-feira_Sexta-feira_Sábado".split("_"),weekdaysShort:"Dom_Seg_Ter_Qua_Qui_Sex_Sáb".split("_"),weekdaysMin:"Do_2ª_3ª_4ª_5ª_6ª_Sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D [de] MMMM [de] YYYY",LLL:"D [de] MMMM [de] YYYY HH:mm",LLLL:"dddd, D [de] MMMM [de] YYYY HH:mm"},calendar:{sameDay:"[Hoje às] LT",nextDay:"[Amanhã às] LT",nextWeek:"dddd [às] LT",lastDay:"[Ontem às] LT",lastWeek:function(){return 0===this.day()||6===this.day()?"[Último] dddd [às] LT":"[Última] dddd [às] LT"},sameElse:"L"},relativeTime:{future:"em %s",past:"há %s",s:"segundos",ss:"%d segundos",m:"um minuto",mm:"%d minutos",h:"uma hora",hh:"%d horas",d:"um dia",dd:"%d dias",w:"uma semana",ww:"%d semanas",M:"um mês",MM:"%d meses",y:"um ano",yy:"%d anos"},dayOfMonthOrdinalParse:/\d{1,2}º/,ordinal:"%dº",week:{dow:1,doy:4}})}(n(5093))},4457:function(e,t,n){!function(e){"use strict";function t(e,t,n){var i=" ";return(e%100>=20||e>=100&&e%100==0)&&(i=" de "),e+i+{ss:"secunde",mm:"minute",hh:"ore",dd:"zile",ww:"săptămâni",MM:"luni",yy:"ani"}[n]}e.defineLocale("ro",{months:"ianuarie_februarie_martie_aprilie_mai_iunie_iulie_august_septembrie_octombrie_noiembrie_decembrie".split("_"),monthsShort:"ian._feb._mart._apr._mai_iun._iul._aug._sept._oct._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"duminică_luni_marți_miercuri_joi_vineri_sâmbătă".split("_"),weekdaysShort:"Dum_Lun_Mar_Mie_Joi_Vin_Sâm".split("_"),weekdaysMin:"Du_Lu_Ma_Mi_Jo_Vi_Sâ".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY H:mm",LLLL:"dddd, D MMMM YYYY H:mm"},calendar:{sameDay:"[azi la] LT",nextDay:"[mâine la] LT",nextWeek:"dddd [la] LT",lastDay:"[ieri la] LT",lastWeek:"[fosta] dddd [la] LT",sameElse:"L"},relativeTime:{future:"peste %s",past:"%s în urmă",s:"câteva secunde",ss:t,m:"un minut",mm:t,h:"o oră",hh:t,d:"o zi",dd:t,w:"o săptămână",ww:t,M:"o lună",MM:t,y:"un an",yy:t},week:{dow:1,doy:7}})}(n(5093))},2271:function(e,t,n){!function(e){"use strict";function t(e,t,n){return"m"===n?t?"минута":"минуту":e+" "+(i=+e,r={ss:t?"секунда_секунды_секунд":"секунду_секунды_секунд",mm:t?"минута_минуты_минут":"минуту_минуты_минут",hh:"час_часа_часов",dd:"день_дня_дней",ww:"неделя_недели_недель",MM:"месяц_месяца_месяцев",yy:"год_года_лет"}[n].split("_"),i%10==1&&i%100!=11?r[0]:i%10>=2&&i%10<=4&&(i%100<10||i%100>=20)?r[1]:r[2]);var i,r}var n=[/^янв/i,/^фев/i,/^мар/i,/^апр/i,/^ма[йя]/i,/^июн/i,/^июл/i,/^авг/i,/^сен/i,/^окт/i,/^ноя/i,/^дек/i];e.defineLocale("ru",{months:{format:"января_февраля_марта_апреля_мая_июня_июля_августа_сентября_октября_ноября_декабря".split("_"),standalone:"январь_февраль_март_апрель_май_июнь_июль_август_сентябрь_октябрь_ноябрь_декабрь".split("_")},monthsShort:{format:"янв._февр._мар._апр._мая_июня_июля_авг._сент._окт._нояб._дек.".split("_"),standalone:"янв._февр._март_апр._май_июнь_июль_авг._сент._окт._нояб._дек.".split("_")},weekdays:{standalone:"воскресенье_понедельник_вторник_среда_четверг_пятница_суббота".split("_"),format:"воскресенье_понедельник_вторник_среду_четверг_пятницу_субботу".split("_"),isFormat:/\[ ?[Вв] ?(?:прошлую|следующую|эту)? ?] ?dddd/},weekdaysShort:"вс_пн_вт_ср_чт_пт_сб".split("_"),weekdaysMin:"вс_пн_вт_ср_чт_пт_сб".split("_"),monthsParse:n,longMonthsParse:n,shortMonthsParse:n,monthsRegex:/^(январ[ья]|янв\.?|феврал[ья]|февр?\.?|марта?|мар\.?|апрел[ья]|апр\.?|ма[йя]|июн[ья]|июн\.?|июл[ья]|июл\.?|августа?|авг\.?|сентябр[ья]|сент?\.?|октябр[ья]|окт\.?|ноябр[ья]|нояб?\.?|декабр[ья]|дек\.?)/i,monthsShortRegex:/^(январ[ья]|янв\.?|феврал[ья]|февр?\.?|марта?|мар\.?|апрел[ья]|апр\.?|ма[йя]|июн[ья]|июн\.?|июл[ья]|июл\.?|августа?|авг\.?|сентябр[ья]|сент?\.?|октябр[ья]|окт\.?|ноябр[ья]|нояб?\.?|декабр[ья]|дек\.?)/i,monthsStrictRegex:/^(январ[яь]|феврал[яь]|марта?|апрел[яь]|ма[яй]|июн[яь]|июл[яь]|августа?|сентябр[яь]|октябр[яь]|ноябр[яь]|декабр[яь])/i,monthsShortStrictRegex:/^(янв\.|февр?\.|мар[т.]|апр\.|ма[яй]|июн[ья.]|июл[ья.]|авг\.|сент?\.|окт\.|нояб?\.|дек\.)/i,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY г.",LLL:"D MMMM YYYY г., H:mm",LLLL:"dddd, D MMMM YYYY г., H:mm"},calendar:{sameDay:"[Сегодня, в] LT",nextDay:"[Завтра, в] LT",lastDay:"[Вчера, в] LT",nextWeek:function(e){if(e.week()===this.week())return 2===this.day()?"[Во] dddd, [в] LT":"[В] dddd, [в] LT";switch(this.day()){case 0:return"[В следующее] dddd, [в] LT";case 1:case 2:case 4:return"[В следующий] dddd, [в] LT";case 3:case 5:case 6:return"[В следующую] dddd, [в] LT"}},lastWeek:function(e){if(e.week()===this.week())return 2===this.day()?"[Во] dddd, [в] LT":"[В] dddd, [в] LT";switch(this.day()){case 0:return"[В прошлое] dddd, [в] LT";case 1:case 2:case 4:return"[В прошлый] dddd, [в] LT";case 3:case 5:case 6:return"[В прошлую] dddd, [в] LT"}},sameElse:"L"},relativeTime:{future:"через %s",past:"%s назад",s:"несколько секунд",ss:t,m:t,mm:t,h:"час",hh:t,d:"день",dd:t,w:"неделя",ww:t,M:"месяц",MM:t,y:"год",yy:t},meridiemParse:/ночи|утра|дня|вечера/i,isPM:function(e){return/^(дня|вечера)$/.test(e)},meridiem:function(e,t,n){return e<4?"ночи":e<12?"утра":e<17?"дня":"вечера"},dayOfMonthOrdinalParse:/\d{1,2}-(й|го|я)/,ordinal:function(e,t){switch(t){case"M":case"d":case"DDD":return e+"-й";case"D":return e+"-го";case"w":case"W":return e+"-я";default:return e}},week:{dow:1,doy:4}})}(n(5093))},1221:function(e,t,n){!function(e){"use strict";var t=["جنوري","فيبروري","مارچ","اپريل","مئي","جون","جولاءِ","آگسٽ","سيپٽمبر","آڪٽوبر","نومبر","ڊسمبر"],n=["آچر","سومر","اڱارو","اربع","خميس","جمع","ڇنڇر"];e.defineLocale("sd",{months:t,monthsShort:t,weekdays:n,weekdaysShort:n,weekdaysMin:n,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd، D MMMM YYYY HH:mm"},meridiemParse:/صبح|شام/,isPM:function(e){return"شام"===e},meridiem:function(e,t,n){return e<12?"صبح":"شام"},calendar:{sameDay:"[اڄ] LT",nextDay:"[سڀاڻي] LT",nextWeek:"dddd [اڳين هفتي تي] LT",lastDay:"[ڪالهه] LT",lastWeek:"[گزريل هفتي] dddd [تي] LT",sameElse:"L"},relativeTime:{future:"%s پوء",past:"%s اڳ",s:"چند سيڪنڊ",ss:"%d سيڪنڊ",m:"هڪ منٽ",mm:"%d منٽ",h:"هڪ ڪلاڪ",hh:"%d ڪلاڪ",d:"هڪ ڏينهن",dd:"%d ڏينهن",M:"هڪ مهينو",MM:"%d مهينا",y:"هڪ سال",yy:"%d سال"},preparse:function(e){return e.replace(/،/g,",")},postformat:function(e){return e.replace(/,/g,"،")},week:{dow:1,doy:4}})}(n(5093))},3478:function(e,t,n){!function(e){"use strict";e.defineLocale("se",{months:"ođđajagemánnu_guovvamánnu_njukčamánnu_cuoŋománnu_miessemánnu_geassemánnu_suoidnemánnu_borgemánnu_čakčamánnu_golggotmánnu_skábmamánnu_juovlamánnu".split("_"),monthsShort:"ođđj_guov_njuk_cuo_mies_geas_suoi_borg_čakč_golg_skáb_juov".split("_"),weekdays:"sotnabeaivi_vuossárga_maŋŋebárga_gaskavahkku_duorastat_bearjadat_lávvardat".split("_"),weekdaysShort:"sotn_vuos_maŋ_gask_duor_bear_láv".split("_"),weekdaysMin:"s_v_m_g_d_b_L".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"MMMM D. [b.] YYYY",LLL:"MMMM D. [b.] YYYY [ti.] HH:mm",LLLL:"dddd, MMMM D. [b.] YYYY [ti.] HH:mm"},calendar:{sameDay:"[otne ti] LT",nextDay:"[ihttin ti] LT",nextWeek:"dddd [ti] LT",lastDay:"[ikte ti] LT",lastWeek:"[ovddit] dddd [ti] LT",sameElse:"L"},relativeTime:{future:"%s geažes",past:"maŋit %s",s:"moadde sekunddat",ss:"%d sekunddat",m:"okta minuhta",mm:"%d minuhtat",h:"okta diimmu",hh:"%d diimmut",d:"okta beaivi",dd:"%d beaivvit",M:"okta mánnu",MM:"%d mánut",y:"okta jahki",yy:"%d jagit"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},7538:function(e,t,n){!function(e){"use strict";e.defineLocale("si",{months:"ජනවාරි_පෙබරවාරි_මාර්තු_අප්රේල්_මැයි_ජූනි_ජූලි_අගෝස්තු_සැප්තැම්බර්_ඔක්තෝබර්_නොවැම්බර්_දෙසැම්බර්".split("_"),monthsShort:"ජන_පෙබ_මාර්_අප්_මැයි_ජූනි_ජූලි_අගෝ_සැප්_ඔක්_නොවැ_දෙසැ".split("_"),weekdays:"ඉරිදා_සඳුදා_අඟහරුවාදා_බදාදා_බ්රහස්පතින්දා_සිකුරාදා_සෙනසුරාදා".split("_"),weekdaysShort:"ඉරි_සඳු_අඟ_බදා_බ්රහ_සිකු_සෙන".split("_"),weekdaysMin:"ඉ_ස_අ_බ_බ්ර_සි_සෙ".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"a h:mm",LTS:"a h:mm:ss",L:"YYYY/MM/DD",LL:"YYYY MMMM D",LLL:"YYYY MMMM D, a h:mm",LLLL:"YYYY MMMM D [වැනි] dddd, a h:mm:ss"},calendar:{sameDay:"[අද] LT[ට]",nextDay:"[හෙට] LT[ට]",nextWeek:"dddd LT[ට]",lastDay:"[ඊයේ] LT[ට]",lastWeek:"[පසුගිය] dddd LT[ට]",sameElse:"L"},relativeTime:{future:"%sකින්",past:"%sකට පෙර",s:"තත්පර කිහිපය",ss:"තත්පර %d",m:"මිනිත්තුව",mm:"මිනිත්තු %d",h:"පැය",hh:"පැය %d",d:"දිනය",dd:"දින %d",M:"මාසය",MM:"මාස %d",y:"වසර",yy:"වසර %d"},dayOfMonthOrdinalParse:/\d{1,2} වැනි/,ordinal:function(e){return e+" වැනි"},meridiemParse:/පෙර වරු|පස් වරු|පෙ.ව|ප.ව./,isPM:function(e){return"ප.ව."===e||"පස් වරු"===e},meridiem:function(e,t,n){return e>11?n?"ප.ව.":"පස් වරු":n?"පෙ.ව.":"පෙර වරු"}})}(n(5093))},5784:function(e,t,n){!function(e){"use strict";var t="január_február_marec_apríl_máj_jún_júl_august_september_október_november_december".split("_"),n="jan_feb_mar_apr_máj_jún_júl_aug_sep_okt_nov_dec".split("_");function i(e){return e>1&&e<5}function r(e,t,n,r){var a=e+" ";switch(n){case"s":return t||r?"pár sekúnd":"pár sekundami";case"ss":return t||r?a+(i(e)?"sekundy":"sekúnd"):a+"sekundami";case"m":return t?"minúta":r?"minútu":"minútou";case"mm":return t||r?a+(i(e)?"minúty":"minút"):a+"minútami";case"h":return t?"hodina":r?"hodinu":"hodinou";case"hh":return t||r?a+(i(e)?"hodiny":"hodín"):a+"hodinami";case"d":return t||r?"deň":"dňom";case"dd":return t||r?a+(i(e)?"dni":"dní"):a+"dňami";case"M":return t||r?"mesiac":"mesiacom";case"MM":return t||r?a+(i(e)?"mesiace":"mesiacov"):a+"mesiacmi";case"y":return t||r?"rok":"rokom";case"yy":return t||r?a+(i(e)?"roky":"rokov"):a+"rokmi"}}e.defineLocale("sk",{months:t,monthsShort:n,weekdays:"nedeľa_pondelok_utorok_streda_štvrtok_piatok_sobota".split("_"),weekdaysShort:"ne_po_ut_st_št_pi_so".split("_"),weekdaysMin:"ne_po_ut_st_št_pi_so".split("_"),longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD.MM.YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd D. MMMM YYYY H:mm"},calendar:{sameDay:"[dnes o] LT",nextDay:"[zajtra o] LT",nextWeek:function(){switch(this.day()){case 0:return"[v nedeľu o] LT";case 1:case 2:return"[v] dddd [o] LT";case 3:return"[v stredu o] LT";case 4:return"[vo štvrtok o] LT";case 5:return"[v piatok o] LT";case 6:return"[v sobotu o] LT"}},lastDay:"[včera o] LT",lastWeek:function(){switch(this.day()){case 0:return"[minulú nedeľu o] LT";case 1:case 2:case 4:case 5:return"[minulý] dddd [o] LT";case 3:return"[minulú stredu o] LT";case 6:return"[minulú sobotu o] LT"}},sameElse:"L"},relativeTime:{future:"za %s",past:"pred %s",s:r,ss:r,m:r,mm:r,h:r,hh:r,d:r,dd:r,M:r,MM:r,y:r,yy:r},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},6637:function(e,t,n){!function(e){"use strict";function t(e,t,n,i){var r=e+" ";switch(n){case"s":return t||i?"nekaj sekund":"nekaj sekundami";case"ss":return r+(1===e?t?"sekundo":"sekundi":2===e?t||i?"sekundi":"sekundah":e<5?t||i?"sekunde":"sekundah":"sekund");case"m":return t?"ena minuta":"eno minuto";case"mm":return r+(1===e?t?"minuta":"minuto":2===e?t||i?"minuti":"minutama":e<5?t||i?"minute":"minutami":t||i?"minut":"minutami");case"h":return t?"ena ura":"eno uro";case"hh":return r+(1===e?t?"ura":"uro":2===e?t||i?"uri":"urama":e<5?t||i?"ure":"urami":t||i?"ur":"urami");case"d":return t||i?"en dan":"enim dnem";case"dd":return r+(1===e?t||i?"dan":"dnem":2===e?t||i?"dni":"dnevoma":t||i?"dni":"dnevi");case"M":return t||i?"en mesec":"enim mesecem";case"MM":return r+(1===e?t||i?"mesec":"mesecem":2===e?t||i?"meseca":"mesecema":e<5?t||i?"mesece":"meseci":t||i?"mesecev":"meseci");case"y":return t||i?"eno leto":"enim letom";case"yy":return r+(1===e?t||i?"leto":"letom":2===e?t||i?"leti":"letoma":e<5?t||i?"leta":"leti":t||i?"let":"leti")}}e.defineLocale("sl",{months:"januar_februar_marec_april_maj_junij_julij_avgust_september_oktober_november_december".split("_"),monthsShort:"jan._feb._mar._apr._maj._jun._jul._avg._sep._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"nedelja_ponedeljek_torek_sreda_četrtek_petek_sobota".split("_"),weekdaysShort:"ned._pon._tor._sre._čet._pet._sob.".split("_"),weekdaysMin:"ne_po_to_sr_če_pe_so".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD. MM. YYYY",LL:"D. MMMM YYYY",LLL:"D. MMMM YYYY H:mm",LLLL:"dddd, D. MMMM YYYY H:mm"},calendar:{sameDay:"[danes ob] LT",nextDay:"[jutri ob] LT",nextWeek:function(){switch(this.day()){case 0:return"[v] [nedeljo] [ob] LT";case 3:return"[v] [sredo] [ob] LT";case 6:return"[v] [soboto] [ob] LT";case 1:case 2:case 4:case 5:return"[v] dddd [ob] LT"}},lastDay:"[včeraj ob] LT",lastWeek:function(){switch(this.day()){case 0:return"[prejšnjo] [nedeljo] [ob] LT";case 3:return"[prejšnjo] [sredo] [ob] LT";case 6:return"[prejšnjo] [soboto] [ob] LT";case 1:case 2:case 4:case 5:return"[prejšnji] dddd [ob] LT"}},sameElse:"L"},relativeTime:{future:"čez %s",past:"pred %s",s:t,ss:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(5093))},6794:function(e,t,n){!function(e){"use strict";e.defineLocale("sq",{months:"Janar_Shkurt_Mars_Prill_Maj_Qershor_Korrik_Gusht_Shtator_Tetor_Nëntor_Dhjetor".split("_"),monthsShort:"Jan_Shk_Mar_Pri_Maj_Qer_Kor_Gus_Sht_Tet_Nën_Dhj".split("_"),weekdays:"E Diel_E Hënë_E Martë_E Mërkurë_E Enjte_E Premte_E Shtunë".split("_"),weekdaysShort:"Die_Hën_Mar_Mër_Enj_Pre_Sht".split("_"),weekdaysMin:"D_H_Ma_Më_E_P_Sh".split("_"),weekdaysParseExact:!0,meridiemParse:/PD|MD/,isPM:function(e){return"M"===e.charAt(0)},meridiem:function(e,t,n){return e<12?"PD":"MD"},longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Sot në] LT",nextDay:"[Nesër në] LT",nextWeek:"dddd [në] LT",lastDay:"[Dje në] LT",lastWeek:"dddd [e kaluar në] LT",sameElse:"L"},relativeTime:{future:"në %s",past:"%s më parë",s:"disa sekonda",ss:"%d sekonda",m:"një minutë",mm:"%d minuta",h:"një orë",hh:"%d orë",d:"një ditë",dd:"%d ditë",M:"një muaj",MM:"%d muaj",y:"një vit",yy:"%d vite"},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},3322:function(e,t,n){!function(e){"use strict";var t={words:{ss:["секунда","секунде","секунди"],m:["један минут","једног минута"],mm:["минут","минута","минута"],h:["један сат","једног сата"],hh:["сат","сата","сати"],d:["један дан","једног дана"],dd:["дан","дана","дана"],M:["један месец","једног месеца"],MM:["месец","месеца","месеци"],y:["једну годину","једне године"],yy:["годину","године","година"]},correctGrammaticalCase:function(e,t){return e%10>=1&&e%10<=4&&(e%100<10||e%100>=20)?e%10==1?t[0]:t[1]:t[2]},translate:function(e,n,i,r){var a,s=t.words[i];return 1===i.length?"y"===i&&n?"једна година":r||n?s[0]:s[1]:(a=t.correctGrammaticalCase(e,s),"yy"===i&&n&&"годину"===a?e+" година":e+" "+a)}};e.defineLocale("sr-cyrl",{months:"јануар_фебруар_март_април_мај_јун_јул_август_септембар_октобар_новембар_децембар".split("_"),monthsShort:"јан._феб._мар._апр._мај_јун_јул_авг._сеп._окт._нов._дец.".split("_"),monthsParseExact:!0,weekdays:"недеља_понедељак_уторак_среда_четвртак_петак_субота".split("_"),weekdaysShort:"нед._пон._уто._сре._чет._пет._суб.".split("_"),weekdaysMin:"не_по_ут_ср_че_пе_су".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"D. M. YYYY.",LL:"D. MMMM YYYY.",LLL:"D. MMMM YYYY. H:mm",LLLL:"dddd, D. MMMM YYYY. H:mm"},calendar:{sameDay:"[данас у] LT",nextDay:"[сутра у] LT",nextWeek:function(){switch(this.day()){case 0:return"[у] [недељу] [у] LT";case 3:return"[у] [среду] [у] LT";case 6:return"[у] [суботу] [у] LT";case 1:case 2:case 4:case 5:return"[у] dddd [у] LT"}},lastDay:"[јуче у] LT",lastWeek:function(){return["[прошле] [недеље] [у] LT","[прошлог] [понедељка] [у] LT","[прошлог] [уторка] [у] LT","[прошле] [среде] [у] LT","[прошлог] [четвртка] [у] LT","[прошлог] [петка] [у] LT","[прошле] [суботе] [у] LT"][this.day()]},sameElse:"L"},relativeTime:{future:"за %s",past:"пре %s",s:"неколико секунди",ss:t.translate,m:t.translate,mm:t.translate,h:t.translate,hh:t.translate,d:t.translate,dd:t.translate,M:t.translate,MM:t.translate,y:t.translate,yy:t.translate},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(5093))},5719:function(e,t,n){!function(e){"use strict";var t={words:{ss:["sekunda","sekunde","sekundi"],m:["jedan minut","jednog minuta"],mm:["minut","minuta","minuta"],h:["jedan sat","jednog sata"],hh:["sat","sata","sati"],d:["jedan dan","jednog dana"],dd:["dan","dana","dana"],M:["jedan mesec","jednog meseca"],MM:["mesec","meseca","meseci"],y:["jednu godinu","jedne godine"],yy:["godinu","godine","godina"]},correctGrammaticalCase:function(e,t){return e%10>=1&&e%10<=4&&(e%100<10||e%100>=20)?e%10==1?t[0]:t[1]:t[2]},translate:function(e,n,i,r){var a,s=t.words[i];return 1===i.length?"y"===i&&n?"jedna godina":r||n?s[0]:s[1]:(a=t.correctGrammaticalCase(e,s),"yy"===i&&n&&"godinu"===a?e+" godina":e+" "+a)}};e.defineLocale("sr",{months:"januar_februar_mart_april_maj_jun_jul_avgust_septembar_oktobar_novembar_decembar".split("_"),monthsShort:"jan._feb._mar._apr._maj_jun_jul_avg._sep._okt._nov._dec.".split("_"),monthsParseExact:!0,weekdays:"nedelja_ponedeljak_utorak_sreda_četvrtak_petak_subota".split("_"),weekdaysShort:"ned._pon._uto._sre._čet._pet._sub.".split("_"),weekdaysMin:"ne_po_ut_sr_če_pe_su".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"D. M. YYYY.",LL:"D. MMMM YYYY.",LLL:"D. MMMM YYYY. H:mm",LLLL:"dddd, D. MMMM YYYY. H:mm"},calendar:{sameDay:"[danas u] LT",nextDay:"[sutra u] LT",nextWeek:function(){switch(this.day()){case 0:return"[u] [nedelju] [u] LT";case 3:return"[u] [sredu] [u] LT";case 6:return"[u] [subotu] [u] LT";case 1:case 2:case 4:case 5:return"[u] dddd [u] LT"}},lastDay:"[juče u] LT",lastWeek:function(){return["[prošle] [nedelje] [u] LT","[prošlog] [ponedeljka] [u] LT","[prošlog] [utorka] [u] LT","[prošle] [srede] [u] LT","[prošlog] [četvrtka] [u] LT","[prošlog] [petka] [u] LT","[prošle] [subote] [u] LT"][this.day()]},sameElse:"L"},relativeTime:{future:"za %s",past:"pre %s",s:"nekoliko sekundi",ss:t.translate,m:t.translate,mm:t.translate,h:t.translate,hh:t.translate,d:t.translate,dd:t.translate,M:t.translate,MM:t.translate,y:t.translate,yy:t.translate},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:7}})}(n(5093))},6e3:function(e,t,n){!function(e){"use strict";e.defineLocale("ss",{months:"Bhimbidvwane_Indlovana_Indlov'lenkhulu_Mabasa_Inkhwekhweti_Inhlaba_Kholwane_Ingci_Inyoni_Imphala_Lweti_Ingongoni".split("_"),monthsShort:"Bhi_Ina_Inu_Mab_Ink_Inh_Kho_Igc_Iny_Imp_Lwe_Igo".split("_"),weekdays:"Lisontfo_Umsombuluko_Lesibili_Lesitsatfu_Lesine_Lesihlanu_Umgcibelo".split("_"),weekdaysShort:"Lis_Umb_Lsb_Les_Lsi_Lsh_Umg".split("_"),weekdaysMin:"Li_Us_Lb_Lt_Ls_Lh_Ug".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[Namuhla nga] LT",nextDay:"[Kusasa nga] LT",nextWeek:"dddd [nga] LT",lastDay:"[Itolo nga] LT",lastWeek:"dddd [leliphelile] [nga] LT",sameElse:"L"},relativeTime:{future:"nga %s",past:"wenteka nga %s",s:"emizuzwana lomcane",ss:"%d mzuzwana",m:"umzuzu",mm:"%d emizuzu",h:"lihora",hh:"%d emahora",d:"lilanga",dd:"%d emalanga",M:"inyanga",MM:"%d tinyanga",y:"umnyaka",yy:"%d iminyaka"},meridiemParse:/ekuseni|emini|entsambama|ebusuku/,meridiem:function(e,t,n){return e<11?"ekuseni":e<15?"emini":e<19?"entsambama":"ebusuku"},meridiemHour:function(e,t){return 12===e&&(e=0),"ekuseni"===t?e:"emini"===t?e>=11?e:e+12:"entsambama"===t||"ebusuku"===t?0===e?0:e+12:void 0},dayOfMonthOrdinalParse:/\d{1,2}/,ordinal:"%d",week:{dow:1,doy:4}})}(n(5093))},1011:function(e,t,n){!function(e){"use strict";e.defineLocale("sv",{months:"januari_februari_mars_april_maj_juni_juli_augusti_september_oktober_november_december".split("_"),monthsShort:"jan_feb_mar_apr_maj_jun_jul_aug_sep_okt_nov_dec".split("_"),weekdays:"söndag_måndag_tisdag_onsdag_torsdag_fredag_lördag".split("_"),weekdaysShort:"sön_mån_tis_ons_tor_fre_lör".split("_"),weekdaysMin:"sö_må_ti_on_to_fr_lö".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"D MMMM YYYY",LLL:"D MMMM YYYY [kl.] HH:mm",LLLL:"dddd D MMMM YYYY [kl.] HH:mm",lll:"D MMM YYYY HH:mm",llll:"ddd D MMM YYYY HH:mm"},calendar:{sameDay:"[Idag] LT",nextDay:"[Imorgon] LT",lastDay:"[Igår] LT",nextWeek:"[På] dddd LT",lastWeek:"[I] dddd[s] LT",sameElse:"L"},relativeTime:{future:"om %s",past:"för %s sedan",s:"några sekunder",ss:"%d sekunder",m:"en minut",mm:"%d minuter",h:"en timme",hh:"%d timmar",d:"en dag",dd:"%d dagar",M:"en månad",MM:"%d månader",y:"ett år",yy:"%d år"},dayOfMonthOrdinalParse:/\d{1,2}(\:e|\:a)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?":e":1===t||2===t?":a":":e")},week:{dow:1,doy:4}})}(n(5093))},748:function(e,t,n){!function(e){"use strict";e.defineLocale("sw",{months:"Januari_Februari_Machi_Aprili_Mei_Juni_Julai_Agosti_Septemba_Oktoba_Novemba_Desemba".split("_"),monthsShort:"Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ago_Sep_Okt_Nov_Des".split("_"),weekdays:"Jumapili_Jumatatu_Jumanne_Jumatano_Alhamisi_Ijumaa_Jumamosi".split("_"),weekdaysShort:"Jpl_Jtat_Jnne_Jtan_Alh_Ijm_Jmos".split("_"),weekdaysMin:"J2_J3_J4_J5_Al_Ij_J1".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"hh:mm A",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[leo saa] LT",nextDay:"[kesho saa] LT",nextWeek:"[wiki ijayo] dddd [saat] LT",lastDay:"[jana] LT",lastWeek:"[wiki iliyopita] dddd [saat] LT",sameElse:"L"},relativeTime:{future:"%s baadaye",past:"tokea %s",s:"hivi punde",ss:"sekunde %d",m:"dakika moja",mm:"dakika %d",h:"saa limoja",hh:"masaa %d",d:"siku moja",dd:"siku %d",M:"mwezi mmoja",MM:"miezi %d",y:"mwaka mmoja",yy:"miaka %d"},week:{dow:1,doy:7}})}(n(5093))},1025:function(e,t,n){!function(e){"use strict";var t={1:"௧",2:"௨",3:"௩",4:"௪",5:"௫",6:"௬",7:"௭",8:"௮",9:"௯",0:"௦"},n={"௧":"1","௨":"2","௩":"3","௪":"4","௫":"5","௬":"6","௭":"7","௮":"8","௯":"9","௦":"0"};e.defineLocale("ta",{months:"ஜனவரி_பிப்ரவரி_மார்ச்_ஏப்ரல்_மே_ஜூன்_ஜூலை_ஆகஸ்ட்_செப்டெம்பர்_அக்டோபர்_நவம்பர்_டிசம்பர்".split("_"),monthsShort:"ஜனவரி_பிப்ரவரி_மார்ச்_ஏப்ரல்_மே_ஜூன்_ஜூலை_ஆகஸ்ட்_செப்டெம்பர்_அக்டோபர்_நவம்பர்_டிசம்பர்".split("_"),weekdays:"ஞாயிற்றுக்கிழமை_திங்கட்கிழமை_செவ்வாய்கிழமை_புதன்கிழமை_வியாழக்கிழமை_வெள்ளிக்கிழமை_சனிக்கிழமை".split("_"),weekdaysShort:"ஞாயிறு_திங்கள்_செவ்வாய்_புதன்_வியாழன்_வெள்ளி_சனி".split("_"),weekdaysMin:"ஞா_தி_செ_பு_வி_வெ_ச".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, HH:mm",LLLL:"dddd, D MMMM YYYY, HH:mm"},calendar:{sameDay:"[இன்று] LT",nextDay:"[நாளை] LT",nextWeek:"dddd, LT",lastDay:"[நேற்று] LT",lastWeek:"[கடந்த வாரம்] dddd, LT",sameElse:"L"},relativeTime:{future:"%s இல்",past:"%s முன்",s:"ஒரு சில விநாடிகள்",ss:"%d விநாடிகள்",m:"ஒரு நிமிடம்",mm:"%d நிமிடங்கள்",h:"ஒரு மணி நேரம்",hh:"%d மணி நேரம்",d:"ஒரு நாள்",dd:"%d நாட்கள்",M:"ஒரு மாதம்",MM:"%d மாதங்கள்",y:"ஒரு வருடம்",yy:"%d ஆண்டுகள்"},dayOfMonthOrdinalParse:/\d{1,2}வது/,ordinal:function(e){return e+"வது"},preparse:function(e){return e.replace(/[௧௨௩௪௫௬௭௮௯௦]/g,(function(e){return n[e]}))},postformat:function(e){return e.replace(/\d/g,(function(e){return t[e]}))},meridiemParse:/யாமம்|வைகறை|காலை|நண்பகல்|எற்பாடு|மாலை/,meridiem:function(e,t,n){return e<2?" யாமம்":e<6?" வைகறை":e<10?" காலை":e<14?" நண்பகல்":e<18?" எற்பாடு":e<22?" மாலை":" யாமம்"},meridiemHour:function(e,t){return 12===e&&(e=0),"யாமம்"===t?e<2?e:e+12:"வைகறை"===t||"காலை"===t||"நண்பகல்"===t&&e>=10?e:e+12},week:{dow:0,doy:6}})}(n(5093))},1885:function(e,t,n){!function(e){"use strict";e.defineLocale("te",{months:"జనవరి_ఫిబ్రవరి_మార్చి_ఏప్రిల్_మే_జూన్_జులై_ఆగస్టు_సెప్టెంబర్_అక్టోబర్_నవంబర్_డిసెంబర్".split("_"),monthsShort:"జన._ఫిబ్ర._మార్చి_ఏప్రి._మే_జూన్_జులై_ఆగ._సెప్._అక్టో._నవ._డిసె.".split("_"),monthsParseExact:!0,weekdays:"ఆదివారం_సోమవారం_మంగళవారం_బుధవారం_గురువారం_శుక్రవారం_శనివారం".split("_"),weekdaysShort:"ఆది_సోమ_మంగళ_బుధ_గురు_శుక్ర_శని".split("_"),weekdaysMin:"ఆ_సో_మం_బు_గు_శు_శ".split("_"),longDateFormat:{LT:"A h:mm",LTS:"A h:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY, A h:mm",LLLL:"dddd, D MMMM YYYY, A h:mm"},calendar:{sameDay:"[నేడు] LT",nextDay:"[రేపు] LT",nextWeek:"dddd, LT",lastDay:"[నిన్న] LT",lastWeek:"[గత] dddd, LT",sameElse:"L"},relativeTime:{future:"%s లో",past:"%s క్రితం",s:"కొన్ని క్షణాలు",ss:"%d సెకన్లు",m:"ఒక నిమిషం",mm:"%d నిమిషాలు",h:"ఒక గంట",hh:"%d గంటలు",d:"ఒక రోజు",dd:"%d రోజులు",M:"ఒక నెల",MM:"%d నెలలు",y:"ఒక సంవత్సరం",yy:"%d సంవత్సరాలు"},dayOfMonthOrdinalParse:/\d{1,2}వ/,ordinal:"%dవ",meridiemParse:/రాత్రి|ఉదయం|మధ్యాహ్నం|సాయంత్రం/,meridiemHour:function(e,t){return 12===e&&(e=0),"రాత్రి"===t?e<4?e:e+12:"ఉదయం"===t?e:"మధ్యాహ్నం"===t?e>=10?e:e+12:"సాయంత్రం"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"రాత్రి":e<10?"ఉదయం":e<17?"మధ్యాహ్నం":e<20?"సాయంత్రం":"రాత్రి"},week:{dow:0,doy:6}})}(n(5093))},8861:function(e,t,n){!function(e){"use strict";e.defineLocale("tet",{months:"Janeiru_Fevereiru_Marsu_Abril_Maiu_Juñu_Jullu_Agustu_Setembru_Outubru_Novembru_Dezembru".split("_"),monthsShort:"Jan_Fev_Mar_Abr_Mai_Jun_Jul_Ago_Set_Out_Nov_Dez".split("_"),weekdays:"Domingu_Segunda_Tersa_Kuarta_Kinta_Sesta_Sabadu".split("_"),weekdaysShort:"Dom_Seg_Ters_Kua_Kint_Sest_Sab".split("_"),weekdaysMin:"Do_Seg_Te_Ku_Ki_Ses_Sa".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Ohin iha] LT",nextDay:"[Aban iha] LT",nextWeek:"dddd [iha] LT",lastDay:"[Horiseik iha] LT",lastWeek:"dddd [semana kotuk] [iha] LT",sameElse:"L"},relativeTime:{future:"iha %s",past:"%s liuba",s:"segundu balun",ss:"segundu %d",m:"minutu ida",mm:"minutu %d",h:"oras ida",hh:"oras %d",d:"loron ida",dd:"loron %d",M:"fulan ida",MM:"fulan %d",y:"tinan ida",yy:"tinan %d"},dayOfMonthOrdinalParse:/\d{1,2}(st|nd|rd|th)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:1,doy:4}})}(n(5093))},6571:function(e,t,n){!function(e){"use strict";var t={0:"-ум",1:"-ум",2:"-юм",3:"-юм",4:"-ум",5:"-ум",6:"-ум",7:"-ум",8:"-ум",9:"-ум",10:"-ум",12:"-ум",13:"-ум",20:"-ум",30:"-юм",40:"-ум",50:"-ум",60:"-ум",70:"-ум",80:"-ум",90:"-ум",100:"-ум"};e.defineLocale("tg",{months:{format:"январи_феврали_марти_апрели_майи_июни_июли_августи_сентябри_октябри_ноябри_декабри".split("_"),standalone:"январ_феврал_март_апрел_май_июн_июл_август_сентябр_октябр_ноябр_декабр".split("_")},monthsShort:"янв_фев_мар_апр_май_июн_июл_авг_сен_окт_ноя_дек".split("_"),weekdays:"якшанбе_душанбе_сешанбе_чоршанбе_панҷшанбе_ҷумъа_шанбе".split("_"),weekdaysShort:"яшб_дшб_сшб_чшб_пшб_ҷум_шнб".split("_"),weekdaysMin:"яш_дш_сш_чш_пш_ҷм_шб".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[Имрӯз соати] LT",nextDay:"[Фардо соати] LT",lastDay:"[Дирӯз соати] LT",nextWeek:"dddd[и] [ҳафтаи оянда соати] LT",lastWeek:"dddd[и] [ҳафтаи гузашта соати] LT",sameElse:"L"},relativeTime:{future:"баъди %s",past:"%s пеш",s:"якчанд сония",m:"як дақиқа",mm:"%d дақиқа",h:"як соат",hh:"%d соат",d:"як рӯз",dd:"%d рӯз",M:"як моҳ",MM:"%d моҳ",y:"як сол",yy:"%d сол"},meridiemParse:/шаб|субҳ|рӯз|бегоҳ/,meridiemHour:function(e,t){return 12===e&&(e=0),"шаб"===t?e<4?e:e+12:"субҳ"===t?e:"рӯз"===t?e>=11?e:e+12:"бегоҳ"===t?e+12:void 0},meridiem:function(e,t,n){return e<4?"шаб":e<11?"субҳ":e<16?"рӯз":e<19?"бегоҳ":"шаб"},dayOfMonthOrdinalParse:/\d{1,2}-(ум|юм)/,ordinal:function(e){return e+(t[e]||t[e%10]||t[e>=100?100:null])},week:{dow:1,doy:7}})}(n(5093))},5802:function(e,t,n){!function(e){"use strict";e.defineLocale("th",{months:"มกราคม_กุมภาพันธ์_มีนาคม_เมษายน_พฤษภาคม_มิถุนายน_กรกฎาคม_สิงหาคม_กันยายน_ตุลาคม_พฤศจิกายน_ธันวาคม".split("_"),monthsShort:"ม.ค._ก.พ._มี.ค._เม.ย._พ.ค._มิ.ย._ก.ค._ส.ค._ก.ย._ต.ค._พ.ย._ธ.ค.".split("_"),monthsParseExact:!0,weekdays:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัสบดี_ศุกร์_เสาร์".split("_"),weekdaysShort:"อาทิตย์_จันทร์_อังคาร_พุธ_พฤหัส_ศุกร์_เสาร์".split("_"),weekdaysMin:"อา._จ._อ._พ._พฤ._ศ._ส.".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"H:mm",LTS:"H:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY เวลา H:mm",LLLL:"วันddddที่ D MMMM YYYY เวลา H:mm"},meridiemParse:/ก่อนเที่ยง|หลังเที่ยง/,isPM:function(e){return"หลังเที่ยง"===e},meridiem:function(e,t,n){return e<12?"ก่อนเที่ยง":"หลังเที่ยง"},calendar:{sameDay:"[วันนี้ เวลา] LT",nextDay:"[พรุ่งนี้ เวลา] LT",nextWeek:"dddd[หน้า เวลา] LT",lastDay:"[เมื่อวานนี้ เวลา] LT",lastWeek:"[วัน]dddd[ที่แล้ว เวลา] LT",sameElse:"L"},relativeTime:{future:"อีก %s",past:"%sที่แล้ว",s:"ไม่กี่วินาที",ss:"%d วินาที",m:"1 นาที",mm:"%d นาที",h:"1 ชั่วโมง",hh:"%d ชั่วโมง",d:"1 วัน",dd:"%d วัน",w:"1 สัปดาห์",ww:"%d สัปดาห์",M:"1 เดือน",MM:"%d เดือน",y:"1 ปี",yy:"%d ปี"}})}(n(5093))},9527:function(e,t,n){!function(e){"use strict";var t={1:"'inji",5:"'inji",8:"'inji",70:"'inji",80:"'inji",2:"'nji",7:"'nji",20:"'nji",50:"'nji",3:"'ünji",4:"'ünji",100:"'ünji",6:"'njy",9:"'unjy",10:"'unjy",30:"'unjy",60:"'ynjy",90:"'ynjy"};e.defineLocale("tk",{months:"Ýanwar_Fewral_Mart_Aprel_Maý_Iýun_Iýul_Awgust_Sentýabr_Oktýabr_Noýabr_Dekabr".split("_"),monthsShort:"Ýan_Few_Mar_Apr_Maý_Iýn_Iýl_Awg_Sen_Okt_Noý_Dek".split("_"),weekdays:"Ýekşenbe_Duşenbe_Sişenbe_Çarşenbe_Penşenbe_Anna_Şenbe".split("_"),weekdaysShort:"Ýek_Duş_Siş_Çar_Pen_Ann_Şen".split("_"),weekdaysMin:"Ýk_Dş_Sş_Çr_Pn_An_Şn".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[bugün sagat] LT",nextDay:"[ertir sagat] LT",nextWeek:"[indiki] dddd [sagat] LT",lastDay:"[düýn] LT",lastWeek:"[geçen] dddd [sagat] LT",sameElse:"L"},relativeTime:{future:"%s soň",past:"%s öň",s:"birnäçe sekunt",m:"bir minut",mm:"%d minut",h:"bir sagat",hh:"%d sagat",d:"bir gün",dd:"%d gün",M:"bir aý",MM:"%d aý",y:"bir ýyl",yy:"%d ýyl"},ordinal:function(e,n){switch(n){case"d":case"D":case"Do":case"DD":return e;default:if(0===e)return e+"'unjy";var i=e%10;return e+(t[i]||t[e%100-i]||t[e>=100?100:null])}},week:{dow:1,doy:7}})}(n(5093))},9231:function(e,t,n){!function(e){"use strict";e.defineLocale("tl-ph",{months:"Enero_Pebrero_Marso_Abril_Mayo_Hunyo_Hulyo_Agosto_Setyembre_Oktubre_Nobyembre_Disyembre".split("_"),monthsShort:"Ene_Peb_Mar_Abr_May_Hun_Hul_Ago_Set_Okt_Nob_Dis".split("_"),weekdays:"Linggo_Lunes_Martes_Miyerkules_Huwebes_Biyernes_Sabado".split("_"),weekdaysShort:"Lin_Lun_Mar_Miy_Huw_Biy_Sab".split("_"),weekdaysMin:"Li_Lu_Ma_Mi_Hu_Bi_Sab".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"MM/D/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY HH:mm",LLLL:"dddd, MMMM DD, YYYY HH:mm"},calendar:{sameDay:"LT [ngayong araw]",nextDay:"[Bukas ng] LT",nextWeek:"LT [sa susunod na] dddd",lastDay:"LT [kahapon]",lastWeek:"LT [noong nakaraang] dddd",sameElse:"L"},relativeTime:{future:"sa loob ng %s",past:"%s ang nakalipas",s:"ilang segundo",ss:"%d segundo",m:"isang minuto",mm:"%d minuto",h:"isang oras",hh:"%d oras",d:"isang araw",dd:"%d araw",M:"isang buwan",MM:"%d buwan",y:"isang taon",yy:"%d taon"},dayOfMonthOrdinalParse:/\d{1,2}/,ordinal:function(e){return e},week:{dow:1,doy:4}})}(n(5093))},1052:function(e,t,n){!function(e){"use strict";var t="pagh_wa’_cha’_wej_loS_vagh_jav_Soch_chorgh_Hut".split("_");function n(e,n,i,r){var a=function(e){var n=Math.floor(e%1e3/100),i=Math.floor(e%100/10),r=e%10,a="";return n>0&&(a+=t[n]+"vatlh"),i>0&&(a+=(""!==a?" ":"")+t[i]+"maH"),r>0&&(a+=(""!==a?" ":"")+t[r]),""===a?"pagh":a}(e);switch(i){case"ss":return a+" lup";case"mm":return a+" tup";case"hh":return a+" rep";case"dd":return a+" jaj";case"MM":return a+" jar";case"yy":return a+" DIS"}}e.defineLocale("tlh",{months:"tera’ jar wa’_tera’ jar cha’_tera’ jar wej_tera’ jar loS_tera’ jar vagh_tera’ jar jav_tera’ jar Soch_tera’ jar chorgh_tera’ jar Hut_tera’ jar wa’maH_tera’ jar wa’maH wa’_tera’ jar wa’maH cha’".split("_"),monthsShort:"jar wa’_jar cha’_jar wej_jar loS_jar vagh_jar jav_jar Soch_jar chorgh_jar Hut_jar wa’maH_jar wa’maH wa’_jar wa’maH cha’".split("_"),monthsParseExact:!0,weekdays:"lojmItjaj_DaSjaj_povjaj_ghItlhjaj_loghjaj_buqjaj_ghInjaj".split("_"),weekdaysShort:"lojmItjaj_DaSjaj_povjaj_ghItlhjaj_loghjaj_buqjaj_ghInjaj".split("_"),weekdaysMin:"lojmItjaj_DaSjaj_povjaj_ghItlhjaj_loghjaj_buqjaj_ghInjaj".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[DaHjaj] LT",nextDay:"[wa’leS] LT",nextWeek:"LLL",lastDay:"[wa’Hu’] LT",lastWeek:"LLL",sameElse:"L"},relativeTime:{future:function(e){var t=e;return-1!==e.indexOf("jaj")?t.slice(0,-3)+"leS":-1!==e.indexOf("jar")?t.slice(0,-3)+"waQ":-1!==e.indexOf("DIS")?t.slice(0,-3)+"nem":t+" pIq"},past:function(e){var t=e;return-1!==e.indexOf("jaj")?t.slice(0,-3)+"Hu’":-1!==e.indexOf("jar")?t.slice(0,-3)+"wen":-1!==e.indexOf("DIS")?t.slice(0,-3)+"ben":t+" ret"},s:"puS lup",ss:n,m:"wa’ tup",mm:n,h:"wa’ rep",hh:n,d:"wa’ jaj",dd:n,M:"wa’ jar",MM:n,y:"wa’ DIS",yy:n},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},5096:function(e,t,n){!function(e){"use strict";var t={1:"'inci",5:"'inci",8:"'inci",70:"'inci",80:"'inci",2:"'nci",7:"'nci",20:"'nci",50:"'nci",3:"'üncü",4:"'üncü",100:"'üncü",6:"'ncı",9:"'uncu",10:"'uncu",30:"'uncu",60:"'ıncı",90:"'ıncı"};e.defineLocale("tr",{months:"Ocak_Şubat_Mart_Nisan_Mayıs_Haziran_Temmuz_Ağustos_Eylül_Ekim_Kasım_Aralık".split("_"),monthsShort:"Oca_Şub_Mar_Nis_May_Haz_Tem_Ağu_Eyl_Eki_Kas_Ara".split("_"),weekdays:"Pazar_Pazartesi_Salı_Çarşamba_Perşembe_Cuma_Cumartesi".split("_"),weekdaysShort:"Paz_Pzt_Sal_Çar_Per_Cum_Cmt".split("_"),weekdaysMin:"Pz_Pt_Sa_Ça_Pe_Cu_Ct".split("_"),meridiem:function(e,t,n){return e<12?n?"öö":"ÖÖ":n?"ös":"ÖS"},meridiemParse:/öö|ÖÖ|ös|ÖS/,isPM:function(e){return"ös"===e||"ÖS"===e},longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[bugün saat] LT",nextDay:"[yarın saat] LT",nextWeek:"[gelecek] dddd [saat] LT",lastDay:"[dün] LT",lastWeek:"[geçen] dddd [saat] LT",sameElse:"L"},relativeTime:{future:"%s sonra",past:"%s önce",s:"birkaç saniye",ss:"%d saniye",m:"bir dakika",mm:"%d dakika",h:"bir saat",hh:"%d saat",d:"bir gün",dd:"%d gün",w:"bir hafta",ww:"%d hafta",M:"bir ay",MM:"%d ay",y:"bir yıl",yy:"%d yıl"},ordinal:function(e,n){switch(n){case"d":case"D":case"Do":case"DD":return e;default:if(0===e)return e+"'ıncı";var i=e%10;return e+(t[i]||t[e%100-i]||t[e>=100?100:null])}},week:{dow:1,doy:7}})}(n(5093))},9846:function(e,t,n){!function(e){"use strict";function t(e,t,n,i){var r={s:["viensas secunds","'iensas secunds"],ss:[e+" secunds",e+" secunds"],m:["'n míut","'iens míut"],mm:[e+" míuts",e+" míuts"],h:["'n þora","'iensa þora"],hh:[e+" þoras",e+" þoras"],d:["'n ziua","'iensa ziua"],dd:[e+" ziuas",e+" ziuas"],M:["'n mes","'iens mes"],MM:[e+" mesen",e+" mesen"],y:["'n ar","'iens ar"],yy:[e+" ars",e+" ars"]};return i||t?r[n][0]:r[n][1]}e.defineLocale("tzl",{months:"Januar_Fevraglh_Març_Avrïu_Mai_Gün_Julia_Guscht_Setemvar_Listopäts_Noemvar_Zecemvar".split("_"),monthsShort:"Jan_Fev_Mar_Avr_Mai_Gün_Jul_Gus_Set_Lis_Noe_Zec".split("_"),weekdays:"Súladi_Lúneçi_Maitzi_Márcuri_Xhúadi_Viénerçi_Sáturi".split("_"),weekdaysShort:"Súl_Lún_Mai_Már_Xhú_Vié_Sát".split("_"),weekdaysMin:"Sú_Lú_Ma_Má_Xh_Vi_Sá".split("_"),longDateFormat:{LT:"HH.mm",LTS:"HH.mm.ss",L:"DD.MM.YYYY",LL:"D. MMMM [dallas] YYYY",LLL:"D. MMMM [dallas] YYYY HH.mm",LLLL:"dddd, [li] D. MMMM [dallas] YYYY HH.mm"},meridiemParse:/d\'o|d\'a/i,isPM:function(e){return"d'o"===e.toLowerCase()},meridiem:function(e,t,n){return e>11?n?"d'o":"D'O":n?"d'a":"D'A"},calendar:{sameDay:"[oxhi à] LT",nextDay:"[demà à] LT",nextWeek:"dddd [à] LT",lastDay:"[ieiri à] LT",lastWeek:"[sür el] dddd [lasteu à] LT",sameElse:"L"},relativeTime:{future:"osprei %s",past:"ja%s",s:t,ss:t,m:t,mm:t,h:t,hh:t,d:t,dd:t,M:t,MM:t,y:t,yy:t},dayOfMonthOrdinalParse:/\d{1,2}\./,ordinal:"%d.",week:{dow:1,doy:4}})}(n(5093))},7711:function(e,t,n){!function(e){"use strict";e.defineLocale("tzm-latn",{months:"innayr_brˤayrˤ_marˤsˤ_ibrir_mayyw_ywnyw_ywlywz_ɣwšt_šwtanbir_ktˤwbrˤ_nwwanbir_dwjnbir".split("_"),monthsShort:"innayr_brˤayrˤ_marˤsˤ_ibrir_mayyw_ywnyw_ywlywz_ɣwšt_šwtanbir_ktˤwbrˤ_nwwanbir_dwjnbir".split("_"),weekdays:"asamas_aynas_asinas_akras_akwas_asimwas_asiḍyas".split("_"),weekdaysShort:"asamas_aynas_asinas_akras_akwas_asimwas_asiḍyas".split("_"),weekdaysMin:"asamas_aynas_asinas_akras_akwas_asimwas_asiḍyas".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[asdkh g] LT",nextDay:"[aska g] LT",nextWeek:"dddd [g] LT",lastDay:"[assant g] LT",lastWeek:"dddd [g] LT",sameElse:"L"},relativeTime:{future:"dadkh s yan %s",past:"yan %s",s:"imik",ss:"%d imik",m:"minuḍ",mm:"%d minuḍ",h:"saɛa",hh:"%d tassaɛin",d:"ass",dd:"%d ossan",M:"ayowr",MM:"%d iyyirn",y:"asgas",yy:"%d isgasn"},week:{dow:6,doy:12}})}(n(5093))},1765:function(e,t,n){!function(e){"use strict";e.defineLocale("tzm",{months:"ⵉⵏⵏⴰⵢⵔ_ⴱⵕⴰⵢⵕ_ⵎⴰⵕⵚ_ⵉⴱⵔⵉⵔ_ⵎⴰⵢⵢⵓ_ⵢⵓⵏⵢⵓ_ⵢⵓⵍⵢⵓⵣ_ⵖⵓⵛⵜ_ⵛⵓⵜⴰⵏⴱⵉⵔ_ⴽⵟⵓⴱⵕ_ⵏⵓⵡⴰⵏⴱⵉⵔ_ⴷⵓⵊⵏⴱⵉⵔ".split("_"),monthsShort:"ⵉⵏⵏⴰⵢⵔ_ⴱⵕⴰⵢⵕ_ⵎⴰⵕⵚ_ⵉⴱⵔⵉⵔ_ⵎⴰⵢⵢⵓ_ⵢⵓⵏⵢⵓ_ⵢⵓⵍⵢⵓⵣ_ⵖⵓⵛⵜ_ⵛⵓⵜⴰⵏⴱⵉⵔ_ⴽⵟⵓⴱⵕ_ⵏⵓⵡⴰⵏⴱⵉⵔ_ⴷⵓⵊⵏⴱⵉⵔ".split("_"),weekdays:"ⴰⵙⴰⵎⴰⵙ_ⴰⵢⵏⴰⵙ_ⴰⵙⵉⵏⴰⵙ_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ".split("_"),weekdaysShort:"ⴰⵙⴰⵎⴰⵙ_ⴰⵢⵏⴰⵙ_ⴰⵙⵉⵏⴰⵙ_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ".split("_"),weekdaysMin:"ⴰⵙⴰⵎⴰⵙ_ⴰⵢⵏⴰⵙ_ⴰⵙⵉⵏⴰⵙ_ⴰⴽⵔⴰⵙ_ⴰⴽⵡⴰⵙ_ⴰⵙⵉⵎⵡⴰⵙ_ⴰⵙⵉⴹⵢⴰⵙ".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd D MMMM YYYY HH:mm"},calendar:{sameDay:"[ⴰⵙⴷⵅ ⴴ] LT",nextDay:"[ⴰⵙⴽⴰ ⴴ] LT",nextWeek:"dddd [ⴴ] LT",lastDay:"[ⴰⵚⴰⵏⵜ ⴴ] LT",lastWeek:"dddd [ⴴ] LT",sameElse:"L"},relativeTime:{future:"ⴷⴰⴷⵅ ⵙ ⵢⴰⵏ %s",past:"ⵢⴰⵏ %s",s:"ⵉⵎⵉⴽ",ss:"%d ⵉⵎⵉⴽ",m:"ⵎⵉⵏⵓⴺ",mm:"%d ⵎⵉⵏⵓⴺ",h:"ⵙⴰⵄⴰ",hh:"%d ⵜⴰⵙⵙⴰⵄⵉⵏ",d:"ⴰⵙⵙ",dd:"%d oⵙⵙⴰⵏ",M:"ⴰⵢoⵓⵔ",MM:"%d ⵉⵢⵢⵉⵔⵏ",y:"ⴰⵙⴳⴰⵙ",yy:"%d ⵉⵙⴳⴰⵙⵏ"},week:{dow:6,doy:12}})}(n(5093))},8414:function(e,t,n){!function(e){"use strict";e.defineLocale("ug-cn",{months:"يانۋار_فېۋرال_مارت_ئاپرېل_ماي_ئىيۇن_ئىيۇل_ئاۋغۇست_سېنتەبىر_ئۆكتەبىر_نويابىر_دېكابىر".split("_"),monthsShort:"يانۋار_فېۋرال_مارت_ئاپرېل_ماي_ئىيۇن_ئىيۇل_ئاۋغۇست_سېنتەبىر_ئۆكتەبىر_نويابىر_دېكابىر".split("_"),weekdays:"يەكشەنبە_دۈشەنبە_سەيشەنبە_چارشەنبە_پەيشەنبە_جۈمە_شەنبە".split("_"),weekdaysShort:"يە_دۈ_سە_چا_پە_جۈ_شە".split("_"),weekdaysMin:"يە_دۈ_سە_چا_پە_جۈ_شە".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY-MM-DD",LL:"YYYY-يىلىM-ئاينىڭD-كۈنى",LLL:"YYYY-يىلىM-ئاينىڭD-كۈنى، HH:mm",LLLL:"dddd، YYYY-يىلىM-ئاينىڭD-كۈنى، HH:mm"},meridiemParse:/يېرىم كېچە|سەھەر|چۈشتىن بۇرۇن|چۈش|چۈشتىن كېيىن|كەچ/,meridiemHour:function(e,t){return 12===e&&(e=0),"يېرىم كېچە"===t||"سەھەر"===t||"چۈشتىن بۇرۇن"===t?e:"چۈشتىن كېيىن"===t||"كەچ"===t?e+12:e>=11?e:e+12},meridiem:function(e,t,n){var i=100*e+t;return i<600?"يېرىم كېچە":i<900?"سەھەر":i<1130?"چۈشتىن بۇرۇن":i<1230?"چۈش":i<1800?"چۈشتىن كېيىن":"كەچ"},calendar:{sameDay:"[بۈگۈن سائەت] LT",nextDay:"[ئەتە سائەت] LT",nextWeek:"[كېلەركى] dddd [سائەت] LT",lastDay:"[تۆنۈگۈن] LT",lastWeek:"[ئالدىنقى] dddd [سائەت] LT",sameElse:"L"},relativeTime:{future:"%s كېيىن",past:"%s بۇرۇن",s:"نەچچە سېكونت",ss:"%d سېكونت",m:"بىر مىنۇت",mm:"%d مىنۇت",h:"بىر سائەت",hh:"%d سائەت",d:"بىر كۈن",dd:"%d كۈن",M:"بىر ئاي",MM:"%d ئاي",y:"بىر يىل",yy:"%d يىل"},dayOfMonthOrdinalParse:/\d{1,2}(-كۈنى|-ئاي|-ھەپتە)/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"-كۈنى";case"w":case"W":return e+"-ھەپتە";default:return e}},preparse:function(e){return e.replace(/،/g,",")},postformat:function(e){return e.replace(/,/g,"،")},week:{dow:1,doy:7}})}(n(5093))},6618:function(e,t,n){!function(e){"use strict";function t(e,t,n){return"m"===n?t?"хвилина":"хвилину":"h"===n?t?"година":"годину":e+" "+(i=+e,r={ss:t?"секунда_секунди_секунд":"секунду_секунди_секунд",mm:t?"хвилина_хвилини_хвилин":"хвилину_хвилини_хвилин",hh:t?"година_години_годин":"годину_години_годин",dd:"день_дні_днів",MM:"місяць_місяці_місяців",yy:"рік_роки_років"}[n].split("_"),i%10==1&&i%100!=11?r[0]:i%10>=2&&i%10<=4&&(i%100<10||i%100>=20)?r[1]:r[2]);var i,r}function n(e){return function(){return e+"о"+(11===this.hours()?"б":"")+"] LT"}}e.defineLocale("uk",{months:{format:"січня_лютого_березня_квітня_травня_червня_липня_серпня_вересня_жовтня_листопада_грудня".split("_"),standalone:"січень_лютий_березень_квітень_травень_червень_липень_серпень_вересень_жовтень_листопад_грудень".split("_")},monthsShort:"січ_лют_бер_квіт_трав_черв_лип_серп_вер_жовт_лист_груд".split("_"),weekdays:function(e,t){var n={nominative:"неділя_понеділок_вівторок_середа_четвер_п’ятниця_субота".split("_"),accusative:"неділю_понеділок_вівторок_середу_четвер_п’ятницю_суботу".split("_"),genitive:"неділі_понеділка_вівторка_середи_четверга_п’ятниці_суботи".split("_")};return!0===e?n.nominative.slice(1,7).concat(n.nominative.slice(0,1)):e?n[/(\[[ВвУу]\]) ?dddd/.test(t)?"accusative":/\[?(?:минулої|наступної)? ?\] ?dddd/.test(t)?"genitive":"nominative"][e.day()]:n.nominative},weekdaysShort:"нд_пн_вт_ср_чт_пт_сб".split("_"),weekdaysMin:"нд_пн_вт_ср_чт_пт_сб".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD.MM.YYYY",LL:"D MMMM YYYY р.",LLL:"D MMMM YYYY р., HH:mm",LLLL:"dddd, D MMMM YYYY р., HH:mm"},calendar:{sameDay:n("[Сьогодні "),nextDay:n("[Завтра "),lastDay:n("[Вчора "),nextWeek:n("[У] dddd ["),lastWeek:function(){switch(this.day()){case 0:case 3:case 5:case 6:return n("[Минулої] dddd [").call(this);case 1:case 2:case 4:return n("[Минулого] dddd [").call(this)}},sameElse:"L"},relativeTime:{future:"за %s",past:"%s тому",s:"декілька секунд",ss:t,m:t,mm:t,h:"годину",hh:t,d:"день",dd:t,M:"місяць",MM:t,y:"рік",yy:t},meridiemParse:/ночі|ранку|дня|вечора/,isPM:function(e){return/^(дня|вечора)$/.test(e)},meridiem:function(e,t,n){return e<4?"ночі":e<12?"ранку":e<17?"дня":"вечора"},dayOfMonthOrdinalParse:/\d{1,2}-(й|го)/,ordinal:function(e,t){switch(t){case"M":case"d":case"DDD":case"w":case"W":return e+"-й";case"D":return e+"-го";default:return e}},week:{dow:1,doy:7}})}(n(5093))},158:function(e,t,n){!function(e){"use strict";var t=["جنوری","فروری","مارچ","اپریل","مئی","جون","جولائی","اگست","ستمبر","اکتوبر","نومبر","دسمبر"],n=["اتوار","پیر","منگل","بدھ","جمعرات","جمعہ","ہفتہ"];e.defineLocale("ur",{months:t,monthsShort:t,weekdays:n,weekdaysShort:n,weekdaysMin:n,longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd، D MMMM YYYY HH:mm"},meridiemParse:/صبح|شام/,isPM:function(e){return"شام"===e},meridiem:function(e,t,n){return e<12?"صبح":"شام"},calendar:{sameDay:"[آج بوقت] LT",nextDay:"[کل بوقت] LT",nextWeek:"dddd [بوقت] LT",lastDay:"[گذشتہ روز بوقت] LT",lastWeek:"[گذشتہ] dddd [بوقت] LT",sameElse:"L"},relativeTime:{future:"%s بعد",past:"%s قبل",s:"چند سیکنڈ",ss:"%d سیکنڈ",m:"ایک منٹ",mm:"%d منٹ",h:"ایک گھنٹہ",hh:"%d گھنٹے",d:"ایک دن",dd:"%d دن",M:"ایک ماہ",MM:"%d ماہ",y:"ایک سال",yy:"%d سال"},preparse:function(e){return e.replace(/،/g,",")},postformat:function(e){return e.replace(/,/g,"،")},week:{dow:1,doy:4}})}(n(5093))},2475:function(e,t,n){!function(e){"use strict";e.defineLocale("uz-latn",{months:"Yanvar_Fevral_Mart_Aprel_May_Iyun_Iyul_Avgust_Sentabr_Oktabr_Noyabr_Dekabr".split("_"),monthsShort:"Yan_Fev_Mar_Apr_May_Iyun_Iyul_Avg_Sen_Okt_Noy_Dek".split("_"),weekdays:"Yakshanba_Dushanba_Seshanba_Chorshanba_Payshanba_Juma_Shanba".split("_"),weekdaysShort:"Yak_Dush_Sesh_Chor_Pay_Jum_Shan".split("_"),weekdaysMin:"Ya_Du_Se_Cho_Pa_Ju_Sha".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"D MMMM YYYY, dddd HH:mm"},calendar:{sameDay:"[Bugun soat] LT [da]",nextDay:"[Ertaga] LT [da]",nextWeek:"dddd [kuni soat] LT [da]",lastDay:"[Kecha soat] LT [da]",lastWeek:"[O'tgan] dddd [kuni soat] LT [da]",sameElse:"L"},relativeTime:{future:"Yaqin %s ichida",past:"Bir necha %s oldin",s:"soniya",ss:"%d soniya",m:"bir daqiqa",mm:"%d daqiqa",h:"bir soat",hh:"%d soat",d:"bir kun",dd:"%d kun",M:"bir oy",MM:"%d oy",y:"bir yil",yy:"%d yil"},week:{dow:1,doy:7}})}(n(5093))},7609:function(e,t,n){!function(e){"use strict";e.defineLocale("uz",{months:"январ_феврал_март_апрел_май_июн_июл_август_сентябр_октябр_ноябр_декабр".split("_"),monthsShort:"янв_фев_мар_апр_май_июн_июл_авг_сен_окт_ноя_дек".split("_"),weekdays:"Якшанба_Душанба_Сешанба_Чоршанба_Пайшанба_Жума_Шанба".split("_"),weekdaysShort:"Якш_Душ_Сеш_Чор_Пай_Жум_Шан".split("_"),weekdaysMin:"Як_Ду_Се_Чо_Па_Жу_Ша".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"D MMMM YYYY, dddd HH:mm"},calendar:{sameDay:"[Бугун соат] LT [да]",nextDay:"[Эртага] LT [да]",nextWeek:"dddd [куни соат] LT [да]",lastDay:"[Кеча соат] LT [да]",lastWeek:"[Утган] dddd [куни соат] LT [да]",sameElse:"L"},relativeTime:{future:"Якин %s ичида",past:"Бир неча %s олдин",s:"фурсат",ss:"%d фурсат",m:"бир дакика",mm:"%d дакика",h:"бир соат",hh:"%d соат",d:"бир кун",dd:"%d кун",M:"бир ой",MM:"%d ой",y:"бир йил",yy:"%d йил"},week:{dow:1,doy:7}})}(n(5093))},1135:function(e,t,n){!function(e){"use strict";e.defineLocale("vi",{months:"tháng 1_tháng 2_tháng 3_tháng 4_tháng 5_tháng 6_tháng 7_tháng 8_tháng 9_tháng 10_tháng 11_tháng 12".split("_"),monthsShort:"Thg 01_Thg 02_Thg 03_Thg 04_Thg 05_Thg 06_Thg 07_Thg 08_Thg 09_Thg 10_Thg 11_Thg 12".split("_"),monthsParseExact:!0,weekdays:"chủ nhật_thứ hai_thứ ba_thứ tư_thứ năm_thứ sáu_thứ bảy".split("_"),weekdaysShort:"CN_T2_T3_T4_T5_T6_T7".split("_"),weekdaysMin:"CN_T2_T3_T4_T5_T6_T7".split("_"),weekdaysParseExact:!0,meridiemParse:/sa|ch/i,isPM:function(e){return/^ch$/i.test(e)},meridiem:function(e,t,n){return e<12?n?"sa":"SA":n?"ch":"CH"},longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"D MMMM [năm] YYYY",LLL:"D MMMM [năm] YYYY HH:mm",LLLL:"dddd, D MMMM [năm] YYYY HH:mm",l:"DD/M/YYYY",ll:"D MMM YYYY",lll:"D MMM YYYY HH:mm",llll:"ddd, D MMM YYYY HH:mm"},calendar:{sameDay:"[Hôm nay lúc] LT",nextDay:"[Ngày mai lúc] LT",nextWeek:"dddd [tuần tới lúc] LT",lastDay:"[Hôm qua lúc] LT",lastWeek:"dddd [tuần trước lúc] LT",sameElse:"L"},relativeTime:{future:"%s tới",past:"%s trước",s:"vài giây",ss:"%d giây",m:"một phút",mm:"%d phút",h:"một giờ",hh:"%d giờ",d:"một ngày",dd:"%d ngày",w:"một tuần",ww:"%d tuần",M:"một tháng",MM:"%d tháng",y:"một năm",yy:"%d năm"},dayOfMonthOrdinalParse:/\d{1,2}/,ordinal:function(e){return e},week:{dow:1,doy:4}})}(n(5093))},4051:function(e,t,n){!function(e){"use strict";e.defineLocale("x-pseudo",{months:"J~áñúá~rý_F~ébrú~árý_~Márc~h_Áp~ríl_~Máý_~Júñé~_Júl~ý_Áú~gúst~_Sép~témb~ér_Ó~ctób~ér_Ñ~óvém~bér_~Décé~mbér".split("_"),monthsShort:"J~áñ_~Féb_~Már_~Ápr_~Máý_~Júñ_~Júl_~Áúg_~Sép_~Óct_~Ñóv_~Déc".split("_"),monthsParseExact:!0,weekdays:"S~úñdá~ý_Mó~ñdáý~_Túé~sdáý~_Wéd~ñésd~áý_T~húrs~dáý_~Fríd~áý_S~átúr~dáý".split("_"),weekdaysShort:"S~úñ_~Móñ_~Túé_~Wéd_~Thú_~Frí_~Sát".split("_"),weekdaysMin:"S~ú_Mó~_Tú_~Wé_T~h_Fr~_Sá".split("_"),weekdaysParseExact:!0,longDateFormat:{LT:"HH:mm",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY HH:mm",LLLL:"dddd, D MMMM YYYY HH:mm"},calendar:{sameDay:"[T~ódá~ý át] LT",nextDay:"[T~ómó~rró~w át] LT",nextWeek:"dddd [át] LT",lastDay:"[Ý~ést~érdá~ý át] LT",lastWeek:"[L~ást] dddd [át] LT",sameElse:"L"},relativeTime:{future:"í~ñ %s",past:"%s á~gó",s:"á ~féw ~sécó~ñds",ss:"%d s~écóñ~ds",m:"á ~míñ~úté",mm:"%d m~íñú~tés",h:"á~ñ hó~úr",hh:"%d h~óúrs",d:"á ~dáý",dd:"%d d~áýs",M:"á ~móñ~th",MM:"%d m~óñt~hs",y:"á ~ýéár",yy:"%d ý~éárs"},dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10;return e+(1==~~(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")},week:{dow:1,doy:4}})}(n(5093))},2218:function(e,t,n){!function(e){"use strict";e.defineLocale("yo",{months:"Sẹ́rẹ́_Èrèlè_Ẹrẹ̀nà_Ìgbé_Èbibi_Òkùdu_Agẹmo_Ògún_Owewe_Ọ̀wàrà_Bélú_Ọ̀pẹ̀̀".split("_"),monthsShort:"Sẹ́r_Èrl_Ẹrn_Ìgb_Èbi_Òkù_Agẹ_Ògú_Owe_Ọ̀wà_Bél_Ọ̀pẹ̀̀".split("_"),weekdays:"Àìkú_Ajé_Ìsẹ́gun_Ọjọ́rú_Ọjọ́bọ_Ẹtì_Àbámẹ́ta".split("_"),weekdaysShort:"Àìk_Ajé_Ìsẹ́_Ọjr_Ọjb_Ẹtì_Àbá".split("_"),weekdaysMin:"Àì_Aj_Ìs_Ọr_Ọb_Ẹt_Àb".split("_"),longDateFormat:{LT:"h:mm A",LTS:"h:mm:ss A",L:"DD/MM/YYYY",LL:"D MMMM YYYY",LLL:"D MMMM YYYY h:mm A",LLLL:"dddd, D MMMM YYYY h:mm A"},calendar:{sameDay:"[Ònì ni] LT",nextDay:"[Ọ̀la ni] LT",nextWeek:"dddd [Ọsẹ̀ tón'bọ] [ni] LT",lastDay:"[Àna ni] LT",lastWeek:"dddd [Ọsẹ̀ tólọ́] [ni] LT",sameElse:"L"},relativeTime:{future:"ní %s",past:"%s kọjá",s:"ìsẹjú aayá die",ss:"aayá %d",m:"ìsẹjú kan",mm:"ìsẹjú %d",h:"wákati kan",hh:"wákati %d",d:"ọjọ́ kan",dd:"ọjọ́ %d",M:"osù kan",MM:"osù %d",y:"ọdún kan",yy:"ọdún %d"},dayOfMonthOrdinalParse:/ọjọ́\s\d{1,2}/,ordinal:"ọjọ́ %d",week:{dow:1,doy:4}})}(n(5093))},2648:function(e,t,n){!function(e){"use strict";e.defineLocale("zh-cn",{months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"),weekdaysShort:"周日_周一_周二_周三_周四_周五_周六".split("_"),weekdaysMin:"日_一_二_三_四_五_六".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY/MM/DD",LL:"YYYY年M月D日",LLL:"YYYY年M月D日Ah点mm分",LLLL:"YYYY年M月D日ddddAh点mm分",l:"YYYY/M/D",ll:"YYYY年M月D日",lll:"YYYY年M月D日 HH:mm",llll:"YYYY年M月D日dddd HH:mm"},meridiemParse:/凌晨|早上|上午|中午|下午|晚上/,meridiemHour:function(e,t){return 12===e&&(e=0),"凌晨"===t||"早上"===t||"上午"===t?e:"下午"===t||"晚上"===t?e+12:e>=11?e:e+12},meridiem:function(e,t,n){var i=100*e+t;return i<600?"凌晨":i<900?"早上":i<1130?"上午":i<1230?"中午":i<1800?"下午":"晚上"},calendar:{sameDay:"[今天]LT",nextDay:"[明天]LT",nextWeek:function(e){return e.week()!==this.week()?"[下]dddLT":"[本]dddLT"},lastDay:"[昨天]LT",lastWeek:function(e){return this.week()!==e.week()?"[上]dddLT":"[本]dddLT"},sameElse:"L"},dayOfMonthOrdinalParse:/\d{1,2}(日|月|周)/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"日";case"M":return e+"月";case"w":case"W":return e+"周";default:return e}},relativeTime:{future:"%s后",past:"%s前",s:"几秒",ss:"%d 秒",m:"1 分钟",mm:"%d 分钟",h:"1 小时",hh:"%d 小时",d:"1 天",dd:"%d 天",w:"1 周",ww:"%d 周",M:"1 个月",MM:"%d 个月",y:"1 年",yy:"%d 年"},week:{dow:1,doy:4}})}(n(5093))},1632:function(e,t,n){!function(e){"use strict";e.defineLocale("zh-hk",{months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"),weekdaysShort:"週日_週一_週二_週三_週四_週五_週六".split("_"),weekdaysMin:"日_一_二_三_四_五_六".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY/MM/DD",LL:"YYYY年M月D日",LLL:"YYYY年M月D日 HH:mm",LLLL:"YYYY年M月D日dddd HH:mm",l:"YYYY/M/D",ll:"YYYY年M月D日",lll:"YYYY年M月D日 HH:mm",llll:"YYYY年M月D日dddd HH:mm"},meridiemParse:/凌晨|早上|上午|中午|下午|晚上/,meridiemHour:function(e,t){return 12===e&&(e=0),"凌晨"===t||"早上"===t||"上午"===t?e:"中午"===t?e>=11?e:e+12:"下午"===t||"晚上"===t?e+12:void 0},meridiem:function(e,t,n){var i=100*e+t;return i<600?"凌晨":i<900?"早上":i<1200?"上午":1200===i?"中午":i<1800?"下午":"晚上"},calendar:{sameDay:"[今天]LT",nextDay:"[明天]LT",nextWeek:"[下]ddddLT",lastDay:"[昨天]LT",lastWeek:"[上]ddddLT",sameElse:"L"},dayOfMonthOrdinalParse:/\d{1,2}(日|月|週)/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"日";case"M":return e+"月";case"w":case"W":return e+"週";default:return e}},relativeTime:{future:"%s後",past:"%s前",s:"幾秒",ss:"%d 秒",m:"1 分鐘",mm:"%d 分鐘",h:"1 小時",hh:"%d 小時",d:"1 天",dd:"%d 天",M:"1 個月",MM:"%d 個月",y:"1 年",yy:"%d 年"}})}(n(5093))},1541:function(e,t,n){!function(e){"use strict";e.defineLocale("zh-mo",{months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"),weekdaysShort:"週日_週一_週二_週三_週四_週五_週六".split("_"),weekdaysMin:"日_一_二_三_四_五_六".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"DD/MM/YYYY",LL:"YYYY年M月D日",LLL:"YYYY年M月D日 HH:mm",LLLL:"YYYY年M月D日dddd HH:mm",l:"D/M/YYYY",ll:"YYYY年M月D日",lll:"YYYY年M月D日 HH:mm",llll:"YYYY年M月D日dddd HH:mm"},meridiemParse:/凌晨|早上|上午|中午|下午|晚上/,meridiemHour:function(e,t){return 12===e&&(e=0),"凌晨"===t||"早上"===t||"上午"===t?e:"中午"===t?e>=11?e:e+12:"下午"===t||"晚上"===t?e+12:void 0},meridiem:function(e,t,n){var i=100*e+t;return i<600?"凌晨":i<900?"早上":i<1130?"上午":i<1230?"中午":i<1800?"下午":"晚上"},calendar:{sameDay:"[今天] LT",nextDay:"[明天] LT",nextWeek:"[下]dddd LT",lastDay:"[昨天] LT",lastWeek:"[上]dddd LT",sameElse:"L"},dayOfMonthOrdinalParse:/\d{1,2}(日|月|週)/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"日";case"M":return e+"月";case"w":case"W":return e+"週";default:return e}},relativeTime:{future:"%s內",past:"%s前",s:"幾秒",ss:"%d 秒",m:"1 分鐘",mm:"%d 分鐘",h:"1 小時",hh:"%d 小時",d:"1 天",dd:"%d 天",M:"1 個月",MM:"%d 個月",y:"1 年",yy:"%d 年"}})}(n(5093))},304:function(e,t,n){!function(e){"use strict";e.defineLocale("zh-tw",{months:"一月_二月_三月_四月_五月_六月_七月_八月_九月_十月_十一月_十二月".split("_"),monthsShort:"1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),weekdays:"星期日_星期一_星期二_星期三_星期四_星期五_星期六".split("_"),weekdaysShort:"週日_週一_週二_週三_週四_週五_週六".split("_"),weekdaysMin:"日_一_二_三_四_五_六".split("_"),longDateFormat:{LT:"HH:mm",LTS:"HH:mm:ss",L:"YYYY/MM/DD",LL:"YYYY年M月D日",LLL:"YYYY年M月D日 HH:mm",LLLL:"YYYY年M月D日dddd HH:mm",l:"YYYY/M/D",ll:"YYYY年M月D日",lll:"YYYY年M月D日 HH:mm",llll:"YYYY年M月D日dddd HH:mm"},meridiemParse:/凌晨|早上|上午|中午|下午|晚上/,meridiemHour:function(e,t){return 12===e&&(e=0),"凌晨"===t||"早上"===t||"上午"===t?e:"中午"===t?e>=11?e:e+12:"下午"===t||"晚上"===t?e+12:void 0},meridiem:function(e,t,n){var i=100*e+t;return i<600?"凌晨":i<900?"早上":i<1130?"上午":i<1230?"中午":i<1800?"下午":"晚上"},calendar:{sameDay:"[今天] LT",nextDay:"[明天] LT",nextWeek:"[下]dddd LT",lastDay:"[昨天] LT",lastWeek:"[上]dddd LT",sameElse:"L"},dayOfMonthOrdinalParse:/\d{1,2}(日|月|週)/,ordinal:function(e,t){switch(t){case"d":case"D":case"DDD":return e+"日";case"M":return e+"月";case"w":case"W":return e+"週";default:return e}},relativeTime:{future:"%s後",past:"%s前",s:"幾秒",ss:"%d 秒",m:"1 分鐘",mm:"%d 分鐘",h:"1 小時",hh:"%d 小時",d:"1 天",dd:"%d 天",M:"1 個月",MM:"%d 個月",y:"1 年",yy:"%d 年"}})}(n(5093))},5358:(e,t,n)=>{var i={"./af":5177,"./af.js":5177,"./ar":1509,"./ar-dz":1488,"./ar-dz.js":1488,"./ar-kw":8676,"./ar-kw.js":8676,"./ar-ly":2353,"./ar-ly.js":2353,"./ar-ma":4496,"./ar-ma.js":4496,"./ar-ps":6947,"./ar-ps.js":6947,"./ar-sa":2682,"./ar-sa.js":2682,"./ar-tn":9756,"./ar-tn.js":9756,"./ar.js":1509,"./az":5533,"./az.js":5533,"./be":8959,"./be.js":8959,"./bg":7777,"./bg.js":7777,"./bm":4903,"./bm.js":4903,"./bn":1290,"./bn-bd":7357,"./bn-bd.js":7357,"./bn.js":1290,"./bo":1545,"./bo.js":1545,"./br":1470,"./br.js":1470,"./bs":4429,"./bs.js":4429,"./ca":7306,"./ca.js":7306,"./cs":6464,"./cs.js":6464,"./cv":3635,"./cv.js":3635,"./cy":4226,"./cy.js":4226,"./da":3601,"./da.js":3601,"./de":7853,"./de-at":6111,"./de-at.js":6111,"./de-ch":4697,"./de-ch.js":4697,"./de.js":7853,"./dv":708,"./dv.js":708,"./el":4691,"./el.js":4691,"./en-au":3872,"./en-au.js":3872,"./en-ca":8298,"./en-ca.js":8298,"./en-gb":6195,"./en-gb.js":6195,"./en-ie":6584,"./en-ie.js":6584,"./en-il":5543,"./en-il.js":5543,"./en-in":9033,"./en-in.js":9033,"./en-nz":9402,"./en-nz.js":9402,"./en-sg":3004,"./en-sg.js":3004,"./eo":2934,"./eo.js":2934,"./es":7650,"./es-do":838,"./es-do.js":838,"./es-mx":7730,"./es-mx.js":7730,"./es-us":6575,"./es-us.js":6575,"./es.js":7650,"./et":3035,"./et.js":3035,"./eu":3508,"./eu.js":3508,"./fa":119,"./fa.js":119,"./fi":527,"./fi.js":527,"./fil":5995,"./fil.js":5995,"./fo":2477,"./fo.js":2477,"./fr":5498,"./fr-ca":6435,"./fr-ca.js":6435,"./fr-ch":7892,"./fr-ch.js":7892,"./fr.js":5498,"./fy":7071,"./fy.js":7071,"./ga":1734,"./ga.js":1734,"./gd":217,"./gd.js":217,"./gl":7329,"./gl.js":7329,"./gom-deva":2124,"./gom-deva.js":2124,"./gom-latn":3383,"./gom-latn.js":3383,"./gu":5050,"./gu.js":5050,"./he":1713,"./he.js":1713,"./hi":3861,"./hi.js":3861,"./hr":6308,"./hr.js":6308,"./hu":609,"./hu.js":609,"./hy-am":7160,"./hy-am.js":7160,"./id":4063,"./id.js":4063,"./is":9374,"./is.js":9374,"./it":8383,"./it-ch":1827,"./it-ch.js":1827,"./it.js":8383,"./ja":3827,"./ja.js":3827,"./jv":9722,"./jv.js":9722,"./ka":1794,"./ka.js":1794,"./kk":7088,"./kk.js":7088,"./km":6870,"./km.js":6870,"./kn":4451,"./kn.js":4451,"./ko":3164,"./ko.js":3164,"./ku":8174,"./ku-kmr":6181,"./ku-kmr.js":6181,"./ku.js":8174,"./ky":8474,"./ky.js":8474,"./lb":9680,"./lb.js":9680,"./lo":5867,"./lo.js":5867,"./lt":5766,"./lt.js":5766,"./lv":9532,"./lv.js":9532,"./me":8076,"./me.js":8076,"./mi":1848,"./mi.js":1848,"./mk":306,"./mk.js":306,"./ml":3739,"./ml.js":3739,"./mn":9053,"./mn.js":9053,"./mr":6169,"./mr.js":6169,"./ms":3386,"./ms-my":2297,"./ms-my.js":2297,"./ms.js":3386,"./mt":7075,"./mt.js":7075,"./my":2264,"./my.js":2264,"./nb":2274,"./nb.js":2274,"./ne":8235,"./ne.js":8235,"./nl":2572,"./nl-be":3784,"./nl-be.js":3784,"./nl.js":2572,"./nn":4566,"./nn.js":4566,"./oc-lnc":9330,"./oc-lnc.js":9330,"./pa-in":9849,"./pa-in.js":9849,"./pl":4418,"./pl.js":4418,"./pt":9834,"./pt-br":8303,"./pt-br.js":8303,"./pt.js":9834,"./ro":4457,"./ro.js":4457,"./ru":2271,"./ru.js":2271,"./sd":1221,"./sd.js":1221,"./se":3478,"./se.js":3478,"./si":7538,"./si.js":7538,"./sk":5784,"./sk.js":5784,"./sl":6637,"./sl.js":6637,"./sq":6794,"./sq.js":6794,"./sr":5719,"./sr-cyrl":3322,"./sr-cyrl.js":3322,"./sr.js":5719,"./ss":6e3,"./ss.js":6e3,"./sv":1011,"./sv.js":1011,"./sw":748,"./sw.js":748,"./ta":1025,"./ta.js":1025,"./te":1885,"./te.js":1885,"./tet":8861,"./tet.js":8861,"./tg":6571,"./tg.js":6571,"./th":5802,"./th.js":5802,"./tk":9527,"./tk.js":9527,"./tl-ph":9231,"./tl-ph.js":9231,"./tlh":1052,"./tlh.js":1052,"./tr":5096,"./tr.js":5096,"./tzl":9846,"./tzl.js":9846,"./tzm":1765,"./tzm-latn":7711,"./tzm-latn.js":7711,"./tzm.js":1765,"./ug-cn":8414,"./ug-cn.js":8414,"./uk":6618,"./uk.js":6618,"./ur":158,"./ur.js":158,"./uz":7609,"./uz-latn":2475,"./uz-latn.js":2475,"./uz.js":7609,"./vi":1135,"./vi.js":1135,"./x-pseudo":4051,"./x-pseudo.js":4051,"./yo":2218,"./yo.js":2218,"./zh-cn":2648,"./zh-cn.js":2648,"./zh-hk":1632,"./zh-hk.js":1632,"./zh-mo":1541,"./zh-mo.js":1541,"./zh-tw":304,"./zh-tw.js":304};function r(e){var t=a(e);return n(t)}function a(e){if(!n.o(i,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return i[e]}r.keys=function(){return Object.keys(i)},r.resolve=a,e.exports=r,r.id=5358},5093:function(e,t,n){(e=n.nmd(e)).exports=function(){"use strict";var t,i;function r(){return t.apply(null,arguments)}function a(e){return e instanceof Array||"[object Array]"===Object.prototype.toString.call(e)}function s(e){return null!=e&&"[object Object]"===Object.prototype.toString.call(e)}function o(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function u(e){if(Object.getOwnPropertyNames)return 0===Object.getOwnPropertyNames(e).length;var t;for(t in e)if(o(e,t))return!1;return!0}function d(e){return void 0===e}function l(e){return"number"==typeof e||"[object Number]"===Object.prototype.toString.call(e)}function c(e){return e instanceof Date||"[object Date]"===Object.prototype.toString.call(e)}function h(e,t){var n,i=[],r=e.length;for(n=0;n<r;++n)i.push(t(e[n],n));return i}function m(e,t){for(var n in t)o(t,n)&&(e[n]=t[n]);return o(t,"toString")&&(e.toString=t.toString),o(t,"valueOf")&&(e.valueOf=t.valueOf),e}function f(e,t,n,i){return Ct(e,t,n,i,!0).utc()}function p(e){return null==e._pf&&(e._pf={empty:!1,unusedTokens:[],unusedInput:[],overflow:-2,charsLeftOver:0,nullInput:!1,invalidEra:null,invalidMonth:null,invalidFormat:!1,userInvalidated:!1,iso:!1,parsedDateParts:[],era:null,meridiem:null,rfc2822:!1,weekdayMismatch:!1}),e._pf}function g(e){var t=null,n=!1,r=e._d&&!isNaN(e._d.getTime());return r&&(t=p(e),n=i.call(t.parsedDateParts,(function(e){return null!=e})),r=t.overflow<0&&!t.empty&&!t.invalidEra&&!t.invalidMonth&&!t.invalidWeekday&&!t.weekdayMismatch&&!t.nullInput&&!t.invalidFormat&&!t.userInvalidated&&(!t.meridiem||t.meridiem&&n),e._strict&&(r=r&&0===t.charsLeftOver&&0===t.unusedTokens.length&&void 0===t.bigHour)),null!=Object.isFrozen&&Object.isFrozen(e)?r:(e._isValid=r,e._isValid)}function y(e){var t=f(NaN);return null!=e?m(p(t),e):p(t).userInvalidated=!0,t}i=Array.prototype.some?Array.prototype.some:function(e){var t,n=Object(this),i=n.length>>>0;for(t=0;t<i;t++)if(t in n&&e.call(this,n[t],t,n))return!0;return!1};var _=r.momentProperties=[],v=!1;function M(e,t){var n,i,r,a=_.length;if(d(t._isAMomentObject)||(e._isAMomentObject=t._isAMomentObject),d(t._i)||(e._i=t._i),d(t._f)||(e._f=t._f),d(t._l)||(e._l=t._l),d(t._strict)||(e._strict=t._strict),d(t._tzm)||(e._tzm=t._tzm),d(t._isUTC)||(e._isUTC=t._isUTC),d(t._offset)||(e._offset=t._offset),d(t._pf)||(e._pf=p(t)),d(t._locale)||(e._locale=t._locale),a>0)for(n=0;n<a;n++)d(r=t[i=_[n]])||(e[i]=r);return e}function w(e){M(this,e),this._d=new Date(null!=e._d?e._d.getTime():NaN),this.isValid()||(this._d=new Date(NaN)),!1===v&&(v=!0,r.updateOffset(this),v=!1)}function b(e){return e instanceof w||null!=e&&null!=e._isAMomentObject}function T(e){!1===r.suppressDeprecationWarnings&&"undefined"!=typeof console&&console.warn&&console.warn("Deprecation warning: "+e)}function L(e,t){var n=!0;return m((function(){if(null!=r.deprecationHandler&&r.deprecationHandler(null,e),n){var i,a,s,u=[],d=arguments.length;for(a=0;a<d;a++){if(i="","object"==typeof arguments[a]){for(s in i+="\n["+a+"] ",arguments[0])o(arguments[0],s)&&(i+=s+": "+arguments[0][s]+", ");i=i.slice(0,-2)}else i=arguments[a];u.push(i)}T(e+"\nArguments: "+Array.prototype.slice.call(u).join("")+"\n"+(new Error).stack),n=!1}return t.apply(this,arguments)}),t)}var S,k={};function D(e,t){null!=r.deprecationHandler&&r.deprecationHandler(e,t),k[e]||(T(t),k[e]=!0)}function x(e){return"undefined"!=typeof Function&&e instanceof Function||"[object Function]"===Object.prototype.toString.call(e)}function A(e,t){var n,i=m({},e);for(n in t)o(t,n)&&(s(e[n])&&s(t[n])?(i[n]={},m(i[n],e[n]),m(i[n],t[n])):null!=t[n]?i[n]=t[n]:delete i[n]);for(n in e)o(e,n)&&!o(t,n)&&s(e[n])&&(i[n]=m({},i[n]));return i}function Y(e){null!=e&&this.set(e)}r.suppressDeprecationWarnings=!1,r.deprecationHandler=null,S=Object.keys?Object.keys:function(e){var t,n=[];for(t in e)o(e,t)&&n.push(t);return n};function E(e,t,n){var i=""+Math.abs(e),r=t-i.length;return(e>=0?n?"+":"":"-")+Math.pow(10,Math.max(0,r)).toString().substr(1)+i}var I=/(\[[^\[]*\])|(\\)?([Hh]mm(ss)?|Mo|MM?M?M?|Do|DDDo|DD?D?D?|ddd?d?|do?|w[o|w]?|W[o|W]?|Qo?|N{1,5}|YYYYYY|YYYYY|YYYY|YY|y{2,4}|yo?|gg(ggg?)?|GG(GGG?)?|e|E|a|A|hh?|HH?|kk?|mm?|ss?|S{1,9}|x|X|zz?|ZZ?|.)/g,P=/(\[[^\[]*\])|(\\)?(LTS|LT|LL?L?L?|l{1,4})/g,C={},j={};function O(e,t,n,i){var r=i;"string"==typeof i&&(r=function(){return this[i]()}),e&&(j[e]=r),t&&(j[t[0]]=function(){return E(r.apply(this,arguments),t[1],t[2])}),n&&(j[n]=function(){return this.localeData().ordinal(r.apply(this,arguments),e)})}function R(e,t){return e.isValid()?(t=N(t,e.localeData()),C[t]=C[t]||function(e){var t,n,i,r=e.match(I);for(t=0,n=r.length;t<n;t++)j[r[t]]?r[t]=j[r[t]]:r[t]=(i=r[t]).match(/\[[\s\S]/)?i.replace(/^\[|\]$/g,""):i.replace(/\\/g,"");return function(t){var i,a="";for(i=0;i<n;i++)a+=x(r[i])?r[i].call(t,e):r[i];return a}}(t),C[t](e)):e.localeData().invalidDate()}function N(e,t){var n=5;function i(e){return t.longDateFormat(e)||e}for(P.lastIndex=0;n>=0&&P.test(e);)e=e.replace(P,i),P.lastIndex=0,n-=1;return e}var H={D:"date",dates:"date",date:"date",d:"day",days:"day",day:"day",e:"weekday",weekdays:"weekday",weekday:"weekday",E:"isoWeekday",isoweekdays:"isoWeekday",isoweekday:"isoWeekday",DDD:"dayOfYear",dayofyears:"dayOfYear",dayofyear:"dayOfYear",h:"hour",hours:"hour",hour:"hour",ms:"millisecond",milliseconds:"millisecond",millisecond:"millisecond",m:"minute",minutes:"minute",minute:"minute",M:"month",months:"month",month:"month",Q:"quarter",quarters:"quarter",quarter:"quarter",s:"second",seconds:"second",second:"second",gg:"weekYear",weekyears:"weekYear",weekyear:"weekYear",GG:"isoWeekYear",isoweekyears:"isoWeekYear",isoweekyear:"isoWeekYear",w:"week",weeks:"week",week:"week",W:"isoWeek",isoweeks:"isoWeek",isoweek:"isoWeek",y:"year",years:"year",year:"year"};function U(e){return"string"==typeof e?H[e]||H[e.toLowerCase()]:void 0}function F(e){var t,n,i={};for(n in e)o(e,n)&&(t=U(n))&&(i[t]=e[n]);return i}var B={date:9,day:11,weekday:11,isoWeekday:11,dayOfYear:4,hour:13,millisecond:16,minute:14,month:8,quarter:7,second:15,weekYear:1,isoWeekYear:1,week:5,isoWeek:5,year:1};var W,z=/\d/,V=/\d\d/,G=/\d{3}/,q=/\d{4}/,$=/[+-]?\d{6}/,K=/\d\d?/,J=/\d\d\d\d?/,X=/\d\d\d\d\d\d?/,Q=/\d{1,3}/,Z=/\d{1,4}/,ee=/[+-]?\d{1,6}/,te=/\d+/,ne=/[+-]?\d+/,ie=/Z|[+-]\d\d:?\d\d/gi,re=/Z|[+-]\d\d(?::?\d\d)?/gi,ae=/[0-9]{0,256}['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFF07\uFF10-\uFFEF]{1,256}|[\u0600-\u06FF\/]{1,256}(\s*?[\u0600-\u06FF]{1,256}){1,2}/i,se=/^[1-9]\d?/,oe=/^([1-9]\d|\d)/;function ue(e,t,n){W[e]=x(t)?t:function(e,i){return e&&n?n:t}}function de(e,t){return o(W,e)?W[e](t._strict,t._locale):new RegExp(le(e.replace("\\","").replace(/\\(\[)|\\(\])|\[([^\]\[]*)\]|\\(.)/g,(function(e,t,n,i,r){return t||n||i||r}))))}function le(e){return e.replace(/[-\/\\^$*+?.()|[\]{}]/g,"\\$&")}function ce(e){return e<0?Math.ceil(e)||0:Math.floor(e)}function he(e){var t=+e,n=0;return 0!==t&&isFinite(t)&&(n=ce(t)),n}W={};var me={};function fe(e,t){var n,i,r=t;for("string"==typeof e&&(e=[e]),l(t)&&(r=function(e,n){n[t]=he(e)}),i=e.length,n=0;n<i;n++)me[e[n]]=r}function pe(e,t){fe(e,(function(e,n,i,r){i._w=i._w||{},t(e,i._w,i,r)}))}function ge(e,t,n){null!=t&&o(me,e)&&me[e](t,n._a,n,e)}function ye(e){return e%4==0&&e%100!=0||e%400==0}var _e=0,ve=1,Me=2,we=3,be=4,Te=5,Le=6,Se=7,ke=8;function De(e){return ye(e)?366:365}O("Y",0,0,(function(){var e=this.year();return e<=9999?E(e,4):"+"+e})),O(0,["YY",2],0,(function(){return this.year()%100})),O(0,["YYYY",4],0,"year"),O(0,["YYYYY",5],0,"year"),O(0,["YYYYYY",6,!0],0,"year"),ue("Y",ne),ue("YY",K,V),ue("YYYY",Z,q),ue("YYYYY",ee,$),ue("YYYYYY",ee,$),fe(["YYYYY","YYYYYY"],_e),fe("YYYY",(function(e,t){t[_e]=2===e.length?r.parseTwoDigitYear(e):he(e)})),fe("YY",(function(e,t){t[_e]=r.parseTwoDigitYear(e)})),fe("Y",(function(e,t){t[_e]=parseInt(e,10)})),r.parseTwoDigitYear=function(e){return he(e)+(he(e)>68?1900:2e3)};var xe,Ae=Ye("FullYear",!0);function Ye(e,t){return function(n){return null!=n?(Ie(this,e,n),r.updateOffset(this,t),this):Ee(this,e)}}function Ee(e,t){if(!e.isValid())return NaN;var n=e._d,i=e._isUTC;switch(t){case"Milliseconds":return i?n.getUTCMilliseconds():n.getMilliseconds();case"Seconds":return i?n.getUTCSeconds():n.getSeconds();case"Minutes":return i?n.getUTCMinutes():n.getMinutes();case"Hours":return i?n.getUTCHours():n.getHours();case"Date":return i?n.getUTCDate():n.getDate();case"Day":return i?n.getUTCDay():n.getDay();case"Month":return i?n.getUTCMonth():n.getMonth();case"FullYear":return i?n.getUTCFullYear():n.getFullYear();default:return NaN}}function Ie(e,t,n){var i,r,a,s,o;if(e.isValid()&&!isNaN(n)){switch(i=e._d,r=e._isUTC,t){case"Milliseconds":return void(r?i.setUTCMilliseconds(n):i.setMilliseconds(n));case"Seconds":return void(r?i.setUTCSeconds(n):i.setSeconds(n));case"Minutes":return void(r?i.setUTCMinutes(n):i.setMinutes(n));case"Hours":return void(r?i.setUTCHours(n):i.setHours(n));case"Date":return void(r?i.setUTCDate(n):i.setDate(n));case"FullYear":break;default:return}a=n,s=e.month(),o=29!==(o=e.date())||1!==s||ye(a)?o:28,r?i.setUTCFullYear(a,s,o):i.setFullYear(a,s,o)}}function Pe(e,t){if(isNaN(e)||isNaN(t))return NaN;var n,i=(t%(n=12)+n)%n;return e+=(t-i)/12,1===i?ye(e)?29:28:31-i%7%2}xe=Array.prototype.indexOf?Array.prototype.indexOf:function(e){var t;for(t=0;t<this.length;++t)if(this[t]===e)return t;return-1},O("M",["MM",2],"Mo",(function(){return this.month()+1})),O("MMM",0,0,(function(e){return this.localeData().monthsShort(this,e)})),O("MMMM",0,0,(function(e){return this.localeData().months(this,e)})),ue("M",K,se),ue("MM",K,V),ue("MMM",(function(e,t){return t.monthsShortRegex(e)})),ue("MMMM",(function(e,t){return t.monthsRegex(e)})),fe(["M","MM"],(function(e,t){t[ve]=he(e)-1})),fe(["MMM","MMMM"],(function(e,t,n,i){var r=n._locale.monthsParse(e,i,n._strict);null!=r?t[ve]=r:p(n).invalidMonth=e}));var Ce="January_February_March_April_May_June_July_August_September_October_November_December".split("_"),je="Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),Oe=/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/,Re=ae,Ne=ae;function He(e,t,n){var i,r,a,s=e.toLocaleLowerCase();if(!this._monthsParse)for(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[],i=0;i<12;++i)a=f([2e3,i]),this._shortMonthsParse[i]=this.monthsShort(a,"").toLocaleLowerCase(),this._longMonthsParse[i]=this.months(a,"").toLocaleLowerCase();return n?"MMM"===t?-1!==(r=xe.call(this._shortMonthsParse,s))?r:null:-1!==(r=xe.call(this._longMonthsParse,s))?r:null:"MMM"===t?-1!==(r=xe.call(this._shortMonthsParse,s))||-1!==(r=xe.call(this._longMonthsParse,s))?r:null:-1!==(r=xe.call(this._longMonthsParse,s))||-1!==(r=xe.call(this._shortMonthsParse,s))?r:null}function Ue(e,t){if(!e.isValid())return e;if("string"==typeof t)if(/^\d+$/.test(t))t=he(t);else if(!l(t=e.localeData().monthsParse(t)))return e;var n=t,i=e.date();return i=i<29?i:Math.min(i,Pe(e.year(),n)),e._isUTC?e._d.setUTCMonth(n,i):e._d.setMonth(n,i),e}function Fe(e){return null!=e?(Ue(this,e),r.updateOffset(this,!0),this):Ee(this,"Month")}function Be(){function e(e,t){return t.length-e.length}var t,n,i,r,a=[],s=[],o=[];for(t=0;t<12;t++)n=f([2e3,t]),i=le(this.monthsShort(n,"")),r=le(this.months(n,"")),a.push(i),s.push(r),o.push(r),o.push(i);a.sort(e),s.sort(e),o.sort(e),this._monthsRegex=new RegExp("^("+o.join("|")+")","i"),this._monthsShortRegex=this._monthsRegex,this._monthsStrictRegex=new RegExp("^("+s.join("|")+")","i"),this._monthsShortStrictRegex=new RegExp("^("+a.join("|")+")","i")}function We(e,t,n,i,r,a,s){var o;return e<100&&e>=0?(o=new Date(e+400,t,n,i,r,a,s),isFinite(o.getFullYear())&&o.setFullYear(e)):o=new Date(e,t,n,i,r,a,s),o}function ze(e){var t,n;return e<100&&e>=0?((n=Array.prototype.slice.call(arguments))[0]=e+400,t=new Date(Date.UTC.apply(null,n)),isFinite(t.getUTCFullYear())&&t.setUTCFullYear(e)):t=new Date(Date.UTC.apply(null,arguments)),t}function Ve(e,t,n){var i=7+t-n;return-(7+ze(e,0,i).getUTCDay()-t)%7+i-1}function Ge(e,t,n,i,r){var a,s,o=1+7*(t-1)+(7+n-i)%7+Ve(e,i,r);return o<=0?s=De(a=e-1)+o:o>De(e)?(a=e+1,s=o-De(e)):(a=e,s=o),{year:a,dayOfYear:s}}function qe(e,t,n){var i,r,a=Ve(e.year(),t,n),s=Math.floor((e.dayOfYear()-a-1)/7)+1;return s<1?i=s+$e(r=e.year()-1,t,n):s>$e(e.year(),t,n)?(i=s-$e(e.year(),t,n),r=e.year()+1):(r=e.year(),i=s),{week:i,year:r}}function $e(e,t,n){var i=Ve(e,t,n),r=Ve(e+1,t,n);return(De(e)-i+r)/7}O("w",["ww",2],"wo","week"),O("W",["WW",2],"Wo","isoWeek"),ue("w",K,se),ue("ww",K,V),ue("W",K,se),ue("WW",K,V),pe(["w","ww","W","WW"],(function(e,t,n,i){t[i.substr(0,1)]=he(e)}));function Ke(e,t){return e.slice(t,7).concat(e.slice(0,t))}O("d",0,"do","day"),O("dd",0,0,(function(e){return this.localeData().weekdaysMin(this,e)})),O("ddd",0,0,(function(e){return this.localeData().weekdaysShort(this,e)})),O("dddd",0,0,(function(e){return this.localeData().weekdays(this,e)})),O("e",0,0,"weekday"),O("E",0,0,"isoWeekday"),ue("d",K),ue("e",K),ue("E",K),ue("dd",(function(e,t){return t.weekdaysMinRegex(e)})),ue("ddd",(function(e,t){return t.weekdaysShortRegex(e)})),ue("dddd",(function(e,t){return t.weekdaysRegex(e)})),pe(["dd","ddd","dddd"],(function(e,t,n,i){var r=n._locale.weekdaysParse(e,i,n._strict);null!=r?t.d=r:p(n).invalidWeekday=e})),pe(["d","e","E"],(function(e,t,n,i){t[i]=he(e)}));var Je="Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),Xe="Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),Qe="Su_Mo_Tu_We_Th_Fr_Sa".split("_"),Ze=ae,et=ae,tt=ae;function nt(e,t,n){var i,r,a,s=e.toLocaleLowerCase();if(!this._weekdaysParse)for(this._weekdaysParse=[],this._shortWeekdaysParse=[],this._minWeekdaysParse=[],i=0;i<7;++i)a=f([2e3,1]).day(i),this._minWeekdaysParse[i]=this.weekdaysMin(a,"").toLocaleLowerCase(),this._shortWeekdaysParse[i]=this.weekdaysShort(a,"").toLocaleLowerCase(),this._weekdaysParse[i]=this.weekdays(a,"").toLocaleLowerCase();return n?"dddd"===t?-1!==(r=xe.call(this._weekdaysParse,s))?r:null:"ddd"===t?-1!==(r=xe.call(this._shortWeekdaysParse,s))?r:null:-1!==(r=xe.call(this._minWeekdaysParse,s))?r:null:"dddd"===t?-1!==(r=xe.call(this._weekdaysParse,s))||-1!==(r=xe.call(this._shortWeekdaysParse,s))||-1!==(r=xe.call(this._minWeekdaysParse,s))?r:null:"ddd"===t?-1!==(r=xe.call(this._shortWeekdaysParse,s))||-1!==(r=xe.call(this._weekdaysParse,s))||-1!==(r=xe.call(this._minWeekdaysParse,s))?r:null:-1!==(r=xe.call(this._minWeekdaysParse,s))||-1!==(r=xe.call(this._weekdaysParse,s))||-1!==(r=xe.call(this._shortWeekdaysParse,s))?r:null}function it(){function e(e,t){return t.length-e.length}var t,n,i,r,a,s=[],o=[],u=[],d=[];for(t=0;t<7;t++)n=f([2e3,1]).day(t),i=le(this.weekdaysMin(n,"")),r=le(this.weekdaysShort(n,"")),a=le(this.weekdays(n,"")),s.push(i),o.push(r),u.push(a),d.push(i),d.push(r),d.push(a);s.sort(e),o.sort(e),u.sort(e),d.sort(e),this._weekdaysRegex=new RegExp("^("+d.join("|")+")","i"),this._weekdaysShortRegex=this._weekdaysRegex,this._weekdaysMinRegex=this._weekdaysRegex,this._weekdaysStrictRegex=new RegExp("^("+u.join("|")+")","i"),this._weekdaysShortStrictRegex=new RegExp("^("+o.join("|")+")","i"),this._weekdaysMinStrictRegex=new RegExp("^("+s.join("|")+")","i")}function rt(){return this.hours()%12||12}function at(e,t){O(e,0,0,(function(){return this.localeData().meridiem(this.hours(),this.minutes(),t)}))}function st(e,t){return t._meridiemParse}O("H",["HH",2],0,"hour"),O("h",["hh",2],0,rt),O("k",["kk",2],0,(function(){return this.hours()||24})),O("hmm",0,0,(function(){return""+rt.apply(this)+E(this.minutes(),2)})),O("hmmss",0,0,(function(){return""+rt.apply(this)+E(this.minutes(),2)+E(this.seconds(),2)})),O("Hmm",0,0,(function(){return""+this.hours()+E(this.minutes(),2)})),O("Hmmss",0,0,(function(){return""+this.hours()+E(this.minutes(),2)+E(this.seconds(),2)})),at("a",!0),at("A",!1),ue("a",st),ue("A",st),ue("H",K,oe),ue("h",K,se),ue("k",K,se),ue("HH",K,V),ue("hh",K,V),ue("kk",K,V),ue("hmm",J),ue("hmmss",X),ue("Hmm",J),ue("Hmmss",X),fe(["H","HH"],we),fe(["k","kk"],(function(e,t,n){var i=he(e);t[we]=24===i?0:i})),fe(["a","A"],(function(e,t,n){n._isPm=n._locale.isPM(e),n._meridiem=e})),fe(["h","hh"],(function(e,t,n){t[we]=he(e),p(n).bigHour=!0})),fe("hmm",(function(e,t,n){var i=e.length-2;t[we]=he(e.substr(0,i)),t[be]=he(e.substr(i)),p(n).bigHour=!0})),fe("hmmss",(function(e,t,n){var i=e.length-4,r=e.length-2;t[we]=he(e.substr(0,i)),t[be]=he(e.substr(i,2)),t[Te]=he(e.substr(r)),p(n).bigHour=!0})),fe("Hmm",(function(e,t,n){var i=e.length-2;t[we]=he(e.substr(0,i)),t[be]=he(e.substr(i))})),fe("Hmmss",(function(e,t,n){var i=e.length-4,r=e.length-2;t[we]=he(e.substr(0,i)),t[be]=he(e.substr(i,2)),t[Te]=he(e.substr(r))}));var ot=Ye("Hours",!0);var ut,dt={calendar:{sameDay:"[Today at] LT",nextDay:"[Tomorrow at] LT",nextWeek:"dddd [at] LT",lastDay:"[Yesterday at] LT",lastWeek:"[Last] dddd [at] LT",sameElse:"L"},longDateFormat:{LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},invalidDate:"Invalid date",ordinal:"%d",dayOfMonthOrdinalParse:/\d{1,2}/,relativeTime:{future:"in %s",past:"%s ago",s:"a few seconds",ss:"%d seconds",m:"a minute",mm:"%d minutes",h:"an hour",hh:"%d hours",d:"a day",dd:"%d days",w:"a week",ww:"%d weeks",M:"a month",MM:"%d months",y:"a year",yy:"%d years"},months:Ce,monthsShort:je,week:{dow:0,doy:6},weekdays:Je,weekdaysMin:Qe,weekdaysShort:Xe,meridiemParse:/[ap]\.?m?\.?/i},lt={},ct={};function ht(e,t){var n,i=Math.min(e.length,t.length);for(n=0;n<i;n+=1)if(e[n]!==t[n])return n;return i}function mt(e){return e?e.toLowerCase().replace("_","-"):e}function ft(t){var i=null;if(void 0===lt[t]&&e&&e.exports&&function(e){return!(!e||!e.match("^[^/\\\\]*$"))}(t))try{i=ut._abbr,n(5358)("./"+t),pt(i)}catch(e){lt[t]=null}return lt[t]}function pt(e,t){var n;return e&&((n=d(t)?yt(e):gt(e,t))?ut=n:"undefined"!=typeof console&&console.warn&&console.warn("Locale "+e+" not found. Did you forget to load it?")),ut._abbr}function gt(e,t){if(null!==t){var n,i=dt;if(t.abbr=e,null!=lt[e])D("defineLocaleOverride","use moment.updateLocale(localeName, config) to change an existing locale. moment.defineLocale(localeName, config) should only be used for creating a new locale See http://momentjs.com/guides/#/warnings/define-locale/ for more info."),i=lt[e]._config;else if(null!=t.parentLocale)if(null!=lt[t.parentLocale])i=lt[t.parentLocale]._config;else{if(null==(n=ft(t.parentLocale)))return ct[t.parentLocale]||(ct[t.parentLocale]=[]),ct[t.parentLocale].push({name:e,config:t}),null;i=n._config}return lt[e]=new Y(A(i,t)),ct[e]&&ct[e].forEach((function(e){gt(e.name,e.config)})),pt(e),lt[e]}return delete lt[e],null}function yt(e){var t;if(e&&e._locale&&e._locale._abbr&&(e=e._locale._abbr),!e)return ut;if(!a(e)){if(t=ft(e))return t;e=[e]}return function(e){for(var t,n,i,r,a=0;a<e.length;){for(t=(r=mt(e[a]).split("-")).length,n=(n=mt(e[a+1]))?n.split("-"):null;t>0;){if(i=ft(r.slice(0,t).join("-")))return i;if(n&&n.length>=t&&ht(r,n)>=t-1)break;t--}a++}return ut}(e)}function _t(e){var t,n=e._a;return n&&-2===p(e).overflow&&(t=n[ve]<0||n[ve]>11?ve:n[Me]<1||n[Me]>Pe(n[_e],n[ve])?Me:n[we]<0||n[we]>24||24===n[we]&&(0!==n[be]||0!==n[Te]||0!==n[Le])?we:n[be]<0||n[be]>59?be:n[Te]<0||n[Te]>59?Te:n[Le]<0||n[Le]>999?Le:-1,p(e)._overflowDayOfYear&&(t<_e||t>Me)&&(t=Me),p(e)._overflowWeeks&&-1===t&&(t=Se),p(e)._overflowWeekday&&-1===t&&(t=ke),p(e).overflow=t),e}var vt=/^\s*((?:[+-]\d{6}|\d{4})-(?:\d\d-\d\d|W\d\d-\d|W\d\d|\d\d\d|\d\d))(?:(T| )(\d\d(?::\d\d(?::\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,Mt=/^\s*((?:[+-]\d{6}|\d{4})(?:\d\d\d\d|W\d\d\d|W\d\d|\d\d\d|\d\d|))(?:(T| )(\d\d(?:\d\d(?:\d\d(?:[.,]\d+)?)?)?)([+-]\d\d(?::?\d\d)?|\s*Z)?)?$/,wt=/Z|[+-]\d\d(?::?\d\d)?/,bt=[["YYYYYY-MM-DD",/[+-]\d{6}-\d\d-\d\d/],["YYYY-MM-DD",/\d{4}-\d\d-\d\d/],["GGGG-[W]WW-E",/\d{4}-W\d\d-\d/],["GGGG-[W]WW",/\d{4}-W\d\d/,!1],["YYYY-DDD",/\d{4}-\d{3}/],["YYYY-MM",/\d{4}-\d\d/,!1],["YYYYYYMMDD",/[+-]\d{10}/],["YYYYMMDD",/\d{8}/],["GGGG[W]WWE",/\d{4}W\d{3}/],["GGGG[W]WW",/\d{4}W\d{2}/,!1],["YYYYDDD",/\d{7}/],["YYYYMM",/\d{6}/,!1],["YYYY",/\d{4}/,!1]],Tt=[["HH:mm:ss.SSSS",/\d\d:\d\d:\d\d\.\d+/],["HH:mm:ss,SSSS",/\d\d:\d\d:\d\d,\d+/],["HH:mm:ss",/\d\d:\d\d:\d\d/],["HH:mm",/\d\d:\d\d/],["HHmmss.SSSS",/\d\d\d\d\d\d\.\d+/],["HHmmss,SSSS",/\d\d\d\d\d\d,\d+/],["HHmmss",/\d\d\d\d\d\d/],["HHmm",/\d\d\d\d/],["HH",/\d\d/]],Lt=/^\/?Date\((-?\d+)/i,St=/^(?:(Mon|Tue|Wed|Thu|Fri|Sat|Sun),?\s)?(\d{1,2})\s(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec)\s(\d{2,4})\s(\d\d):(\d\d)(?::(\d\d))?\s(?:(UT|GMT|[ECMP][SD]T)|([Zz])|([+-]\d{4}))$/,kt={UT:0,GMT:0,EDT:-240,EST:-300,CDT:-300,CST:-360,MDT:-360,MST:-420,PDT:-420,PST:-480};function Dt(e){var t,n,i,r,a,s,o=e._i,u=vt.exec(o)||Mt.exec(o),d=bt.length,l=Tt.length;if(u){for(p(e).iso=!0,t=0,n=d;t<n;t++)if(bt[t][1].exec(u[1])){r=bt[t][0],i=!1!==bt[t][2];break}if(null==r)return void(e._isValid=!1);if(u[3]){for(t=0,n=l;t<n;t++)if(Tt[t][1].exec(u[3])){a=(u[2]||" ")+Tt[t][0];break}if(null==a)return void(e._isValid=!1)}if(!i&&null!=a)return void(e._isValid=!1);if(u[4]){if(!wt.exec(u[4]))return void(e._isValid=!1);s="Z"}e._f=r+(a||"")+(s||""),It(e)}else e._isValid=!1}function xt(e){var t=parseInt(e,10);return t<=49?2e3+t:t<=999?1900+t:t}function At(e){var t,n,i,r,a,s,o,u,d=St.exec(e._i.replace(/\([^()]*\)|[\n\t]/g," ").replace(/(\s\s+)/g," ").replace(/^\s\s*/,"").replace(/\s\s*$/,""));if(d){if(n=d[4],i=d[3],r=d[2],a=d[5],s=d[6],o=d[7],u=[xt(n),je.indexOf(i),parseInt(r,10),parseInt(a,10),parseInt(s,10)],o&&u.push(parseInt(o,10)),t=u,!function(e,t,n){return!e||Xe.indexOf(e)===new Date(t[0],t[1],t[2]).getDay()||(p(n).weekdayMismatch=!0,n._isValid=!1,!1)}(d[1],t,e))return;e._a=t,e._tzm=function(e,t,n){if(e)return kt[e];if(t)return 0;var i=parseInt(n,10),r=i%100;return(i-r)/100*60+r}(d[8],d[9],d[10]),e._d=ze.apply(null,e._a),e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),p(e).rfc2822=!0}else e._isValid=!1}function Yt(e,t,n){return null!=e?e:null!=t?t:n}function Et(e){var t,n,i,a,s,o=[];if(!e._d){for(i=function(e){var t=new Date(r.now());return e._useUTC?[t.getUTCFullYear(),t.getUTCMonth(),t.getUTCDate()]:[t.getFullYear(),t.getMonth(),t.getDate()]}(e),e._w&&null==e._a[Me]&&null==e._a[ve]&&function(e){var t,n,i,r,a,s,o,u,d;null!=(t=e._w).GG||null!=t.W||null!=t.E?(a=1,s=4,n=Yt(t.GG,e._a[_e],qe(jt(),1,4).year),i=Yt(t.W,1),((r=Yt(t.E,1))<1||r>7)&&(u=!0)):(a=e._locale._week.dow,s=e._locale._week.doy,d=qe(jt(),a,s),n=Yt(t.gg,e._a[_e],d.year),i=Yt(t.w,d.week),null!=t.d?((r=t.d)<0||r>6)&&(u=!0):null!=t.e?(r=t.e+a,(t.e<0||t.e>6)&&(u=!0)):r=a),i<1||i>$e(n,a,s)?p(e)._overflowWeeks=!0:null!=u?p(e)._overflowWeekday=!0:(o=Ge(n,i,r,a,s),e._a[_e]=o.year,e._dayOfYear=o.dayOfYear)}(e),null!=e._dayOfYear&&(s=Yt(e._a[_e],i[_e]),(e._dayOfYear>De(s)||0===e._dayOfYear)&&(p(e)._overflowDayOfYear=!0),n=ze(s,0,e._dayOfYear),e._a[ve]=n.getUTCMonth(),e._a[Me]=n.getUTCDate()),t=0;t<3&&null==e._a[t];++t)e._a[t]=o[t]=i[t];for(;t<7;t++)e._a[t]=o[t]=null==e._a[t]?2===t?1:0:e._a[t];24===e._a[we]&&0===e._a[be]&&0===e._a[Te]&&0===e._a[Le]&&(e._nextDay=!0,e._a[we]=0),e._d=(e._useUTC?ze:We).apply(null,o),a=e._useUTC?e._d.getUTCDay():e._d.getDay(),null!=e._tzm&&e._d.setUTCMinutes(e._d.getUTCMinutes()-e._tzm),e._nextDay&&(e._a[we]=24),e._w&&void 0!==e._w.d&&e._w.d!==a&&(p(e).weekdayMismatch=!0)}}function It(e){if(e._f!==r.ISO_8601)if(e._f!==r.RFC_2822){e._a=[],p(e).empty=!0;var t,n,i,a,s,o,u,d=""+e._i,l=d.length,c=0;for(u=(i=N(e._f,e._locale).match(I)||[]).length,t=0;t<u;t++)a=i[t],(n=(d.match(de(a,e))||[])[0])&&((s=d.substr(0,d.indexOf(n))).length>0&&p(e).unusedInput.push(s),d=d.slice(d.indexOf(n)+n.length),c+=n.length),j[a]?(n?p(e).empty=!1:p(e).unusedTokens.push(a),ge(a,n,e)):e._strict&&!n&&p(e).unusedTokens.push(a);p(e).charsLeftOver=l-c,d.length>0&&p(e).unusedInput.push(d),e._a[we]<=12&&!0===p(e).bigHour&&e._a[we]>0&&(p(e).bigHour=void 0),p(e).parsedDateParts=e._a.slice(0),p(e).meridiem=e._meridiem,e._a[we]=function(e,t,n){var i;return null==n?t:null!=e.meridiemHour?e.meridiemHour(t,n):null!=e.isPM?((i=e.isPM(n))&&t<12&&(t+=12),i||12!==t||(t=0),t):t}(e._locale,e._a[we],e._meridiem),null!==(o=p(e).era)&&(e._a[_e]=e._locale.erasConvertYear(o,e._a[_e])),Et(e),_t(e)}else At(e);else Dt(e)}function Pt(e){var t=e._i,n=e._f;return e._locale=e._locale||yt(e._l),null===t||void 0===n&&""===t?y({nullInput:!0}):("string"==typeof t&&(e._i=t=e._locale.preparse(t)),b(t)?new w(_t(t)):(c(t)?e._d=t:a(n)?function(e){var t,n,i,r,a,s,o=!1,u=e._f.length;if(0===u)return p(e).invalidFormat=!0,void(e._d=new Date(NaN));for(r=0;r<u;r++)a=0,s=!1,t=M({},e),null!=e._useUTC&&(t._useUTC=e._useUTC),t._f=e._f[r],It(t),g(t)&&(s=!0),a+=p(t).charsLeftOver,a+=10*p(t).unusedTokens.length,p(t).score=a,o?a<i&&(i=a,n=t):(null==i||a<i||s)&&(i=a,n=t,s&&(o=!0));m(e,n||t)}(e):n?It(e):function(e){var t=e._i;d(t)?e._d=new Date(r.now()):c(t)?e._d=new Date(t.valueOf()):"string"==typeof t?function(e){var t=Lt.exec(e._i);null===t?(Dt(e),!1===e._isValid&&(delete e._isValid,At(e),!1===e._isValid&&(delete e._isValid,e._strict?e._isValid=!1:r.createFromInputFallback(e)))):e._d=new Date(+t[1])}(e):a(t)?(e._a=h(t.slice(0),(function(e){return parseInt(e,10)})),Et(e)):s(t)?function(e){if(!e._d){var t=F(e._i),n=void 0===t.day?t.date:t.day;e._a=h([t.year,t.month,n,t.hour,t.minute,t.second,t.millisecond],(function(e){return e&&parseInt(e,10)})),Et(e)}}(e):l(t)?e._d=new Date(t):r.createFromInputFallback(e)}(e),g(e)||(e._d=null),e))}function Ct(e,t,n,i,r){var o,d={};return!0!==t&&!1!==t||(i=t,t=void 0),!0!==n&&!1!==n||(i=n,n=void 0),(s(e)&&u(e)||a(e)&&0===e.length)&&(e=void 0),d._isAMomentObject=!0,d._useUTC=d._isUTC=r,d._l=n,d._i=e,d._f=t,d._strict=i,(o=new w(_t(Pt(d))))._nextDay&&(o.add(1,"d"),o._nextDay=void 0),o}function jt(e,t,n,i){return Ct(e,t,n,i,!1)}r.createFromInputFallback=L("value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged. Please refer to http://momentjs.com/guides/#/warnings/js-date/ for more info.",(function(e){e._d=new Date(e._i+(e._useUTC?" UTC":""))})),r.ISO_8601=function(){},r.RFC_2822=function(){};var Ot=L("moment().min is deprecated, use moment.max instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var e=jt.apply(null,arguments);return this.isValid()&&e.isValid()?e<this?this:e:y()})),Rt=L("moment().max is deprecated, use moment.min instead. http://momentjs.com/guides/#/warnings/min-max/",(function(){var e=jt.apply(null,arguments);return this.isValid()&&e.isValid()?e>this?this:e:y()}));function Nt(e,t){var n,i;if(1===t.length&&a(t[0])&&(t=t[0]),!t.length)return jt();for(n=t[0],i=1;i<t.length;++i)t[i].isValid()&&!t[i][e](n)||(n=t[i]);return n}var Ht=["year","quarter","month","week","day","hour","minute","second","millisecond"];function Ut(e){var t=F(e),n=t.year||0,i=t.quarter||0,r=t.month||0,a=t.week||t.isoWeek||0,s=t.day||0,u=t.hour||0,d=t.minute||0,l=t.second||0,c=t.millisecond||0;this._isValid=function(e){var t,n,i=!1,r=Ht.length;for(t in e)if(o(e,t)&&(-1===xe.call(Ht,t)||null!=e[t]&&isNaN(e[t])))return!1;for(n=0;n<r;++n)if(e[Ht[n]]){if(i)return!1;parseFloat(e[Ht[n]])!==he(e[Ht[n]])&&(i=!0)}return!0}(t),this._milliseconds=+c+1e3*l+6e4*d+1e3*u*60*60,this._days=+s+7*a,this._months=+r+3*i+12*n,this._data={},this._locale=yt(),this._bubble()}function Ft(e){return e instanceof Ut}function Bt(e){return e<0?-1*Math.round(-1*e):Math.round(e)}function Wt(e,t){O(e,0,0,(function(){var e=this.utcOffset(),n="+";return e<0&&(e=-e,n="-"),n+E(~~(e/60),2)+t+E(~~e%60,2)}))}Wt("Z",":"),Wt("ZZ",""),ue("Z",re),ue("ZZ",re),fe(["Z","ZZ"],(function(e,t,n){n._useUTC=!0,n._tzm=Vt(re,e)}));var zt=/([\+\-]|\d\d)/gi;function Vt(e,t){var n,i,r=(t||"").match(e);return null===r?null:0===(i=60*(n=((r[r.length-1]||[])+"").match(zt)||["-",0,0])[1]+he(n[2]))?0:"+"===n[0]?i:-i}function Gt(e,t){var n,i;return t._isUTC?(n=t.clone(),i=(b(e)||c(e)?e.valueOf():jt(e).valueOf())-n.valueOf(),n._d.setTime(n._d.valueOf()+i),r.updateOffset(n,!1),n):jt(e).local()}function qt(e){return-Math.round(e._d.getTimezoneOffset())}function $t(){return!!this.isValid()&&this._isUTC&&0===this._offset}r.updateOffset=function(){};var Kt=/^(-|\+)?(?:(\d*)[. ])?(\d+):(\d+)(?::(\d+)(\.\d*)?)?$/,Jt=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;function Xt(e,t){var n,i,r,a,s,u,d=e,c=null;return Ft(e)?d={ms:e._milliseconds,d:e._days,M:e._months}:l(e)||!isNaN(+e)?(d={},t?d[t]=+e:d.milliseconds=+e):(c=Kt.exec(e))?(n="-"===c[1]?-1:1,d={y:0,d:he(c[Me])*n,h:he(c[we])*n,m:he(c[be])*n,s:he(c[Te])*n,ms:he(Bt(1e3*c[Le]))*n}):(c=Jt.exec(e))?(n="-"===c[1]?-1:1,d={y:Qt(c[2],n),M:Qt(c[3],n),w:Qt(c[4],n),d:Qt(c[5],n),h:Qt(c[6],n),m:Qt(c[7],n),s:Qt(c[8],n)}):null==d?d={}:"object"==typeof d&&("from"in d||"to"in d)&&(a=jt(d.from),s=jt(d.to),r=a.isValid()&&s.isValid()?(s=Gt(s,a),a.isBefore(s)?u=Zt(a,s):((u=Zt(s,a)).milliseconds=-u.milliseconds,u.months=-u.months),u):{milliseconds:0,months:0},(d={}).ms=r.milliseconds,d.M=r.months),i=new Ut(d),Ft(e)&&o(e,"_locale")&&(i._locale=e._locale),Ft(e)&&o(e,"_isValid")&&(i._isValid=e._isValid),i}function Qt(e,t){var n=e&&parseFloat(e.replace(",","."));return(isNaN(n)?0:n)*t}function Zt(e,t){var n={};return n.months=t.month()-e.month()+12*(t.year()-e.year()),e.clone().add(n.months,"M").isAfter(t)&&--n.months,n.milliseconds=+t-+e.clone().add(n.months,"M"),n}function en(e,t){return function(n,i){var r;return null===i||isNaN(+i)||(D(t,"moment()."+t+"(period, number) is deprecated. Please use moment()."+t+"(number, period). See http://momentjs.com/guides/#/warnings/add-inverted-param/ for more info."),r=n,n=i,i=r),tn(this,Xt(n,i),e),this}}function tn(e,t,n,i){var a=t._milliseconds,s=Bt(t._days),o=Bt(t._months);e.isValid()&&(i=null==i||i,o&&Ue(e,Ee(e,"Month")+o*n),s&&Ie(e,"Date",Ee(e,"Date")+s*n),a&&e._d.setTime(e._d.valueOf()+a*n),i&&r.updateOffset(e,s||o))}Xt.fn=Ut.prototype,Xt.invalid=function(){return Xt(NaN)};var nn=en(1,"add"),rn=en(-1,"subtract");function an(e){return"string"==typeof e||e instanceof String}function sn(e){return b(e)||c(e)||an(e)||l(e)||function(e){var t=a(e),n=!1;return t&&(n=0===e.filter((function(t){return!l(t)&&an(e)})).length),t&&n}(e)||function(e){var t,n,i=s(e)&&!u(e),r=!1,a=["years","year","y","months","month","M","days","day","d","dates","date","D","hours","hour","h","minutes","minute","m","seconds","second","s","milliseconds","millisecond","ms"],d=a.length;for(t=0;t<d;t+=1)n=a[t],r=r||o(e,n);return i&&r}(e)||null==e}function on(e,t){if(e.date()<t.date())return-on(t,e);var n=12*(t.year()-e.year())+(t.month()-e.month()),i=e.clone().add(n,"months");return-(n+(t-i<0?(t-i)/(i-e.clone().add(n-1,"months")):(t-i)/(e.clone().add(n+1,"months")-i)))||0}function un(e){var t;return void 0===e?this._locale._abbr:(null!=(t=yt(e))&&(this._locale=t),this)}r.defaultFormat="YYYY-MM-DDTHH:mm:ssZ",r.defaultFormatUtc="YYYY-MM-DDTHH:mm:ss[Z]";var dn=L("moment().lang() is deprecated. Instead, use moment().localeData() to get the language configuration. Use moment().locale() to change languages.",(function(e){return void 0===e?this.localeData():this.locale(e)}));function ln(){return this._locale}var cn=1e3,hn=6e4,mn=36e5,fn=126227808e5;function pn(e,t){return(e%t+t)%t}function gn(e,t,n){return e<100&&e>=0?new Date(e+400,t,n)-fn:new Date(e,t,n).valueOf()}function yn(e,t,n){return e<100&&e>=0?Date.UTC(e+400,t,n)-fn:Date.UTC(e,t,n)}function _n(e,t){return t.erasAbbrRegex(e)}function vn(){var e,t,n,i,r,a=[],s=[],o=[],u=[],d=this.eras();for(e=0,t=d.length;e<t;++e)n=le(d[e].name),i=le(d[e].abbr),r=le(d[e].narrow),s.push(n),a.push(i),o.push(r),u.push(n),u.push(i),u.push(r);this._erasRegex=new RegExp("^("+u.join("|")+")","i"),this._erasNameRegex=new RegExp("^("+s.join("|")+")","i"),this._erasAbbrRegex=new RegExp("^("+a.join("|")+")","i"),this._erasNarrowRegex=new RegExp("^("+o.join("|")+")","i")}function Mn(e,t){O(0,[e,e.length],0,t)}function wn(e,t,n,i,r){var a;return null==e?qe(this,i,r).year:(t>(a=$e(e,i,r))&&(t=a),bn.call(this,e,t,n,i,r))}function bn(e,t,n,i,r){var a=Ge(e,t,n,i,r),s=ze(a.year,0,a.dayOfYear);return this.year(s.getUTCFullYear()),this.month(s.getUTCMonth()),this.date(s.getUTCDate()),this}O("N",0,0,"eraAbbr"),O("NN",0,0,"eraAbbr"),O("NNN",0,0,"eraAbbr"),O("NNNN",0,0,"eraName"),O("NNNNN",0,0,"eraNarrow"),O("y",["y",1],"yo","eraYear"),O("y",["yy",2],0,"eraYear"),O("y",["yyy",3],0,"eraYear"),O("y",["yyyy",4],0,"eraYear"),ue("N",_n),ue("NN",_n),ue("NNN",_n),ue("NNNN",(function(e,t){return t.erasNameRegex(e)})),ue("NNNNN",(function(e,t){return t.erasNarrowRegex(e)})),fe(["N","NN","NNN","NNNN","NNNNN"],(function(e,t,n,i){var r=n._locale.erasParse(e,i,n._strict);r?p(n).era=r:p(n).invalidEra=e})),ue("y",te),ue("yy",te),ue("yyy",te),ue("yyyy",te),ue("yo",(function(e,t){return t._eraYearOrdinalRegex||te})),fe(["y","yy","yyy","yyyy"],_e),fe(["yo"],(function(e,t,n,i){var r;n._locale._eraYearOrdinalRegex&&(r=e.match(n._locale._eraYearOrdinalRegex)),n._locale.eraYearOrdinalParse?t[_e]=n._locale.eraYearOrdinalParse(e,r):t[_e]=parseInt(e,10)})),O(0,["gg",2],0,(function(){return this.weekYear()%100})),O(0,["GG",2],0,(function(){return this.isoWeekYear()%100})),Mn("gggg","weekYear"),Mn("ggggg","weekYear"),Mn("GGGG","isoWeekYear"),Mn("GGGGG","isoWeekYear"),ue("G",ne),ue("g",ne),ue("GG",K,V),ue("gg",K,V),ue("GGGG",Z,q),ue("gggg",Z,q),ue("GGGGG",ee,$),ue("ggggg",ee,$),pe(["gggg","ggggg","GGGG","GGGGG"],(function(e,t,n,i){t[i.substr(0,2)]=he(e)})),pe(["gg","GG"],(function(e,t,n,i){t[i]=r.parseTwoDigitYear(e)})),O("Q",0,"Qo","quarter"),ue("Q",z),fe("Q",(function(e,t){t[ve]=3*(he(e)-1)})),O("D",["DD",2],"Do","date"),ue("D",K,se),ue("DD",K,V),ue("Do",(function(e,t){return e?t._dayOfMonthOrdinalParse||t._ordinalParse:t._dayOfMonthOrdinalParseLenient})),fe(["D","DD"],Me),fe("Do",(function(e,t){t[Me]=he(e.match(K)[0])}));var Tn=Ye("Date",!0);O("DDD",["DDDD",3],"DDDo","dayOfYear"),ue("DDD",Q),ue("DDDD",G),fe(["DDD","DDDD"],(function(e,t,n){n._dayOfYear=he(e)})),O("m",["mm",2],0,"minute"),ue("m",K,oe),ue("mm",K,V),fe(["m","mm"],be);var Ln=Ye("Minutes",!1);O("s",["ss",2],0,"second"),ue("s",K,oe),ue("ss",K,V),fe(["s","ss"],Te);var Sn,kn,Dn=Ye("Seconds",!1);for(O("S",0,0,(function(){return~~(this.millisecond()/100)})),O(0,["SS",2],0,(function(){return~~(this.millisecond()/10)})),O(0,["SSS",3],0,"millisecond"),O(0,["SSSS",4],0,(function(){return 10*this.millisecond()})),O(0,["SSSSS",5],0,(function(){return 100*this.millisecond()})),O(0,["SSSSSS",6],0,(function(){return 1e3*this.millisecond()})),O(0,["SSSSSSS",7],0,(function(){return 1e4*this.millisecond()})),O(0,["SSSSSSSS",8],0,(function(){return 1e5*this.millisecond()})),O(0,["SSSSSSSSS",9],0,(function(){return 1e6*this.millisecond()})),ue("S",Q,z),ue("SS",Q,V),ue("SSS",Q,G),Sn="SSSS";Sn.length<=9;Sn+="S")ue(Sn,te);function xn(e,t){t[Le]=he(1e3*("0."+e))}for(Sn="S";Sn.length<=9;Sn+="S")fe(Sn,xn);kn=Ye("Milliseconds",!1),O("z",0,0,"zoneAbbr"),O("zz",0,0,"zoneName");var An=w.prototype;function Yn(e){return e}An.add=nn,An.calendar=function(e,t){1===arguments.length&&(arguments[0]?sn(arguments[0])?(e=arguments[0],t=void 0):function(e){var t,n=s(e)&&!u(e),i=!1,r=["sameDay","nextDay","lastDay","nextWeek","lastWeek","sameElse"];for(t=0;t<r.length;t+=1)i=i||o(e,r[t]);return n&&i}(arguments[0])&&(t=arguments[0],e=void 0):(e=void 0,t=void 0));var n=e||jt(),i=Gt(n,this).startOf("day"),a=r.calendarFormat(this,i)||"sameElse",d=t&&(x(t[a])?t[a].call(this,n):t[a]);return this.format(d||this.localeData().calendar(a,this,jt(n)))},An.clone=function(){return new w(this)},An.diff=function(e,t,n){var i,r,a;if(!this.isValid())return NaN;if(!(i=Gt(e,this)).isValid())return NaN;switch(r=6e4*(i.utcOffset()-this.utcOffset()),t=U(t)){case"year":a=on(this,i)/12;break;case"month":a=on(this,i);break;case"quarter":a=on(this,i)/3;break;case"second":a=(this-i)/1e3;break;case"minute":a=(this-i)/6e4;break;case"hour":a=(this-i)/36e5;break;case"day":a=(this-i-r)/864e5;break;case"week":a=(this-i-r)/6048e5;break;default:a=this-i}return n?a:ce(a)},An.endOf=function(e){var t,n;if(void 0===(e=U(e))||"millisecond"===e||!this.isValid())return this;switch(n=this._isUTC?yn:gn,e){case"year":t=n(this.year()+1,0,1)-1;break;case"quarter":t=n(this.year(),this.month()-this.month()%3+3,1)-1;break;case"month":t=n(this.year(),this.month()+1,1)-1;break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday()+7)-1;break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1)+7)-1;break;case"day":case"date":t=n(this.year(),this.month(),this.date()+1)-1;break;case"hour":t=this._d.valueOf(),t+=mn-pn(t+(this._isUTC?0:this.utcOffset()*hn),mn)-1;break;case"minute":t=this._d.valueOf(),t+=hn-pn(t,hn)-1;break;case"second":t=this._d.valueOf(),t+=cn-pn(t,cn)-1}return this._d.setTime(t),r.updateOffset(this,!0),this},An.format=function(e){e||(e=this.isUtc()?r.defaultFormatUtc:r.defaultFormat);var t=R(this,e);return this.localeData().postformat(t)},An.from=function(e,t){return this.isValid()&&(b(e)&&e.isValid()||jt(e).isValid())?Xt({to:this,from:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},An.fromNow=function(e){return this.from(jt(),e)},An.to=function(e,t){return this.isValid()&&(b(e)&&e.isValid()||jt(e).isValid())?Xt({from:this,to:e}).locale(this.locale()).humanize(!t):this.localeData().invalidDate()},An.toNow=function(e){return this.to(jt(),e)},An.get=function(e){return x(this[e=U(e)])?this[e]():this},An.invalidAt=function(){return p(this).overflow},An.isAfter=function(e,t){var n=b(e)?e:jt(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=U(t)||"millisecond")?this.valueOf()>n.valueOf():n.valueOf()<this.clone().startOf(t).valueOf())},An.isBefore=function(e,t){var n=b(e)?e:jt(e);return!(!this.isValid()||!n.isValid())&&("millisecond"===(t=U(t)||"millisecond")?this.valueOf()<n.valueOf():this.clone().endOf(t).valueOf()<n.valueOf())},An.isBetween=function(e,t,n,i){var r=b(e)?e:jt(e),a=b(t)?t:jt(t);return!!(this.isValid()&&r.isValid()&&a.isValid())&&("("===(i=i||"()")[0]?this.isAfter(r,n):!this.isBefore(r,n))&&(")"===i[1]?this.isBefore(a,n):!this.isAfter(a,n))},An.isSame=function(e,t){var n,i=b(e)?e:jt(e);return!(!this.isValid()||!i.isValid())&&("millisecond"===(t=U(t)||"millisecond")?this.valueOf()===i.valueOf():(n=i.valueOf(),this.clone().startOf(t).valueOf()<=n&&n<=this.clone().endOf(t).valueOf()))},An.isSameOrAfter=function(e,t){return this.isSame(e,t)||this.isAfter(e,t)},An.isSameOrBefore=function(e,t){return this.isSame(e,t)||this.isBefore(e,t)},An.isValid=function(){return g(this)},An.lang=dn,An.locale=un,An.localeData=ln,An.max=Rt,An.min=Ot,An.parsingFlags=function(){return m({},p(this))},An.set=function(e,t){if("object"==typeof e){var n,i=function(e){var t,n=[];for(t in e)o(e,t)&&n.push({unit:t,priority:B[t]});return n.sort((function(e,t){return e.priority-t.priority})),n}(e=F(e)),r=i.length;for(n=0;n<r;n++)this[i[n].unit](e[i[n].unit])}else if(x(this[e=U(e)]))return this[e](t);return this},An.startOf=function(e){var t,n;if(void 0===(e=U(e))||"millisecond"===e||!this.isValid())return this;switch(n=this._isUTC?yn:gn,e){case"year":t=n(this.year(),0,1);break;case"quarter":t=n(this.year(),this.month()-this.month()%3,1);break;case"month":t=n(this.year(),this.month(),1);break;case"week":t=n(this.year(),this.month(),this.date()-this.weekday());break;case"isoWeek":t=n(this.year(),this.month(),this.date()-(this.isoWeekday()-1));break;case"day":case"date":t=n(this.year(),this.month(),this.date());break;case"hour":t=this._d.valueOf(),t-=pn(t+(this._isUTC?0:this.utcOffset()*hn),mn);break;case"minute":t=this._d.valueOf(),t-=pn(t,hn);break;case"second":t=this._d.valueOf(),t-=pn(t,cn)}return this._d.setTime(t),r.updateOffset(this,!0),this},An.subtract=rn,An.toArray=function(){var e=this;return[e.year(),e.month(),e.date(),e.hour(),e.minute(),e.second(),e.millisecond()]},An.toObject=function(){var e=this;return{years:e.year(),months:e.month(),date:e.date(),hours:e.hours(),minutes:e.minutes(),seconds:e.seconds(),milliseconds:e.milliseconds()}},An.toDate=function(){return new Date(this.valueOf())},An.toISOString=function(e){if(!this.isValid())return null;var t=!0!==e,n=t?this.clone().utc():this;return n.year()<0||n.year()>9999?R(n,t?"YYYYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYYYY-MM-DD[T]HH:mm:ss.SSSZ"):x(Date.prototype.toISOString)?t?this.toDate().toISOString():new Date(this.valueOf()+60*this.utcOffset()*1e3).toISOString().replace("Z",R(n,"Z")):R(n,t?"YYYY-MM-DD[T]HH:mm:ss.SSS[Z]":"YYYY-MM-DD[T]HH:mm:ss.SSSZ")},An.inspect=function(){if(!this.isValid())return"moment.invalid(/* "+this._i+" */)";var e,t,n,i="moment",r="";return this.isLocal()||(i=0===this.utcOffset()?"moment.utc":"moment.parseZone",r="Z"),e="["+i+'("]',t=0<=this.year()&&this.year()<=9999?"YYYY":"YYYYYY",n=r+'[")]',this.format(e+t+"-MM-DD[T]HH:mm:ss.SSS"+n)},"undefined"!=typeof Symbol&&null!=Symbol.for&&(An[Symbol.for("nodejs.util.inspect.custom")]=function(){return"Moment<"+this.format()+">"}),An.toJSON=function(){return this.isValid()?this.toISOString():null},An.toString=function(){return this.clone().locale("en").format("ddd MMM DD YYYY HH:mm:ss [GMT]ZZ")},An.unix=function(){return Math.floor(this.valueOf()/1e3)},An.valueOf=function(){return this._d.valueOf()-6e4*(this._offset||0)},An.creationData=function(){return{input:this._i,format:this._f,locale:this._locale,isUTC:this._isUTC,strict:this._strict}},An.eraName=function(){var e,t,n,i=this.localeData().eras();for(e=0,t=i.length;e<t;++e){if(n=this.clone().startOf("day").valueOf(),i[e].since<=n&&n<=i[e].until)return i[e].name;if(i[e].until<=n&&n<=i[e].since)return i[e].name}return""},An.eraNarrow=function(){var e,t,n,i=this.localeData().eras();for(e=0,t=i.length;e<t;++e){if(n=this.clone().startOf("day").valueOf(),i[e].since<=n&&n<=i[e].until)return i[e].narrow;if(i[e].until<=n&&n<=i[e].since)return i[e].narrow}return""},An.eraAbbr=function(){var e,t,n,i=this.localeData().eras();for(e=0,t=i.length;e<t;++e){if(n=this.clone().startOf("day").valueOf(),i[e].since<=n&&n<=i[e].until)return i[e].abbr;if(i[e].until<=n&&n<=i[e].since)return i[e].abbr}return""},An.eraYear=function(){var e,t,n,i,a=this.localeData().eras();for(e=0,t=a.length;e<t;++e)if(n=a[e].since<=a[e].until?1:-1,i=this.clone().startOf("day").valueOf(),a[e].since<=i&&i<=a[e].until||a[e].until<=i&&i<=a[e].since)return(this.year()-r(a[e].since).year())*n+a[e].offset;return this.year()},An.year=Ae,An.isLeapYear=function(){return ye(this.year())},An.weekYear=function(e){return wn.call(this,e,this.week(),this.weekday()+this.localeData()._week.dow,this.localeData()._week.dow,this.localeData()._week.doy)},An.isoWeekYear=function(e){return wn.call(this,e,this.isoWeek(),this.isoWeekday(),1,4)},An.quarter=An.quarters=function(e){return null==e?Math.ceil((this.month()+1)/3):this.month(3*(e-1)+this.month()%3)},An.month=Fe,An.daysInMonth=function(){return Pe(this.year(),this.month())},An.week=An.weeks=function(e){var t=this.localeData().week(this);return null==e?t:this.add(7*(e-t),"d")},An.isoWeek=An.isoWeeks=function(e){var t=qe(this,1,4).week;return null==e?t:this.add(7*(e-t),"d")},An.weeksInYear=function(){var e=this.localeData()._week;return $e(this.year(),e.dow,e.doy)},An.weeksInWeekYear=function(){var e=this.localeData()._week;return $e(this.weekYear(),e.dow,e.doy)},An.isoWeeksInYear=function(){return $e(this.year(),1,4)},An.isoWeeksInISOWeekYear=function(){return $e(this.isoWeekYear(),1,4)},An.date=Tn,An.day=An.days=function(e){if(!this.isValid())return null!=e?this:NaN;var t=Ee(this,"Day");return null!=e?(e=function(e,t){return"string"!=typeof e?e:isNaN(e)?"number"==typeof(e=t.weekdaysParse(e))?e:null:parseInt(e,10)}(e,this.localeData()),this.add(e-t,"d")):t},An.weekday=function(e){if(!this.isValid())return null!=e?this:NaN;var t=(this.day()+7-this.localeData()._week.dow)%7;return null==e?t:this.add(e-t,"d")},An.isoWeekday=function(e){if(!this.isValid())return null!=e?this:NaN;if(null!=e){var t=function(e,t){return"string"==typeof e?t.weekdaysParse(e)%7||7:isNaN(e)?null:e}(e,this.localeData());return this.day(this.day()%7?t:t-7)}return this.day()||7},An.dayOfYear=function(e){var t=Math.round((this.clone().startOf("day")-this.clone().startOf("year"))/864e5)+1;return null==e?t:this.add(e-t,"d")},An.hour=An.hours=ot,An.minute=An.minutes=Ln,An.second=An.seconds=Dn,An.millisecond=An.milliseconds=kn,An.utcOffset=function(e,t,n){var i,a=this._offset||0;if(!this.isValid())return null!=e?this:NaN;if(null!=e){if("string"==typeof e){if(null===(e=Vt(re,e)))return this}else Math.abs(e)<16&&!n&&(e*=60);return!this._isUTC&&t&&(i=qt(this)),this._offset=e,this._isUTC=!0,null!=i&&this.add(i,"m"),a!==e&&(!t||this._changeInProgress?tn(this,Xt(e-a,"m"),1,!1):this._changeInProgress||(this._changeInProgress=!0,r.updateOffset(this,!0),this._changeInProgress=null)),this}return this._isUTC?a:qt(this)},An.utc=function(e){return this.utcOffset(0,e)},An.local=function(e){return this._isUTC&&(this.utcOffset(0,e),this._isUTC=!1,e&&this.subtract(qt(this),"m")),this},An.parseZone=function(){if(null!=this._tzm)this.utcOffset(this._tzm,!1,!0);else if("string"==typeof this._i){var e=Vt(ie,this._i);null!=e?this.utcOffset(e):this.utcOffset(0,!0)}return this},An.hasAlignedHourOffset=function(e){return!!this.isValid()&&(e=e?jt(e).utcOffset():0,(this.utcOffset()-e)%60==0)},An.isDST=function(){return this.utcOffset()>this.clone().month(0).utcOffset()||this.utcOffset()>this.clone().month(5).utcOffset()},An.isLocal=function(){return!!this.isValid()&&!this._isUTC},An.isUtcOffset=function(){return!!this.isValid()&&this._isUTC},An.isUtc=$t,An.isUTC=$t,An.zoneAbbr=function(){return this._isUTC?"UTC":""},An.zoneName=function(){return this._isUTC?"Coordinated Universal Time":""},An.dates=L("dates accessor is deprecated. Use date instead.",Tn),An.months=L("months accessor is deprecated. Use month instead",Fe),An.years=L("years accessor is deprecated. Use year instead",Ae),An.zone=L("moment().zone is deprecated, use moment().utcOffset instead. http://momentjs.com/guides/#/warnings/zone/",(function(e,t){return null!=e?("string"!=typeof e&&(e=-e),this.utcOffset(e,t),this):-this.utcOffset()})),An.isDSTShifted=L("isDSTShifted is deprecated. See http://momentjs.com/guides/#/warnings/dst-shifted/ for more information",(function(){if(!d(this._isDSTShifted))return this._isDSTShifted;var e,t={};return M(t,this),(t=Pt(t))._a?(e=t._isUTC?f(t._a):jt(t._a),this._isDSTShifted=this.isValid()&&function(e,t,n){var i,r=Math.min(e.length,t.length),a=Math.abs(e.length-t.length),s=0;for(i=0;i<r;i++)(n&&e[i]!==t[i]||!n&&he(e[i])!==he(t[i]))&&s++;return s+a}(t._a,e.toArray())>0):this._isDSTShifted=!1,this._isDSTShifted}));var En=Y.prototype;function In(e,t,n,i){var r=yt(),a=f().set(i,t);return r[n](a,e)}function Pn(e,t,n){if(l(e)&&(t=e,e=void 0),e=e||"",null!=t)return In(e,t,n,"month");var i,r=[];for(i=0;i<12;i++)r[i]=In(e,i,n,"month");return r}function Cn(e,t,n,i){"boolean"==typeof e?(l(t)&&(n=t,t=void 0),t=t||""):(n=t=e,e=!1,l(t)&&(n=t,t=void 0),t=t||"");var r,a=yt(),s=e?a._week.dow:0,o=[];if(null!=n)return In(t,(n+s)%7,i,"day");for(r=0;r<7;r++)o[r]=In(t,(r+s)%7,i,"day");return o}En.calendar=function(e,t,n){var i=this._calendar[e]||this._calendar.sameElse;return x(i)?i.call(t,n):i},En.longDateFormat=function(e){var t=this._longDateFormat[e],n=this._longDateFormat[e.toUpperCase()];return t||!n?t:(this._longDateFormat[e]=n.match(I).map((function(e){return"MMMM"===e||"MM"===e||"DD"===e||"dddd"===e?e.slice(1):e})).join(""),this._longDateFormat[e])},En.invalidDate=function(){return this._invalidDate},En.ordinal=function(e){return this._ordinal.replace("%d",e)},En.preparse=Yn,En.postformat=Yn,En.relativeTime=function(e,t,n,i){var r=this._relativeTime[n];return x(r)?r(e,t,n,i):r.replace(/%d/i,e)},En.pastFuture=function(e,t){var n=this._relativeTime[e>0?"future":"past"];return x(n)?n(t):n.replace(/%s/i,t)},En.set=function(e){var t,n;for(n in e)o(e,n)&&(x(t=e[n])?this[n]=t:this["_"+n]=t);this._config=e,this._dayOfMonthOrdinalParseLenient=new RegExp((this._dayOfMonthOrdinalParse.source||this._ordinalParse.source)+"|"+/\d{1,2}/.source)},En.eras=function(e,t){var n,i,a,s=this._eras||yt("en")._eras;for(n=0,i=s.length;n<i;++n)switch("string"==typeof s[n].since&&(a=r(s[n].since).startOf("day"),s[n].since=a.valueOf()),typeof s[n].until){case"undefined":s[n].until=1/0;break;case"string":a=r(s[n].until).startOf("day").valueOf(),s[n].until=a.valueOf()}return s},En.erasParse=function(e,t,n){var i,r,a,s,o,u=this.eras();for(e=e.toUpperCase(),i=0,r=u.length;i<r;++i)if(a=u[i].name.toUpperCase(),s=u[i].abbr.toUpperCase(),o=u[i].narrow.toUpperCase(),n)switch(t){case"N":case"NN":case"NNN":if(s===e)return u[i];break;case"NNNN":if(a===e)return u[i];break;case"NNNNN":if(o===e)return u[i]}else if([a,s,o].indexOf(e)>=0)return u[i]},En.erasConvertYear=function(e,t){var n=e.since<=e.until?1:-1;return void 0===t?r(e.since).year():r(e.since).year()+(t-e.offset)*n},En.erasAbbrRegex=function(e){return o(this,"_erasAbbrRegex")||vn.call(this),e?this._erasAbbrRegex:this._erasRegex},En.erasNameRegex=function(e){return o(this,"_erasNameRegex")||vn.call(this),e?this._erasNameRegex:this._erasRegex},En.erasNarrowRegex=function(e){return o(this,"_erasNarrowRegex")||vn.call(this),e?this._erasNarrowRegex:this._erasRegex},En.months=function(e,t){return e?a(this._months)?this._months[e.month()]:this._months[(this._months.isFormat||Oe).test(t)?"format":"standalone"][e.month()]:a(this._months)?this._months:this._months.standalone},En.monthsShort=function(e,t){return e?a(this._monthsShort)?this._monthsShort[e.month()]:this._monthsShort[Oe.test(t)?"format":"standalone"][e.month()]:a(this._monthsShort)?this._monthsShort:this._monthsShort.standalone},En.monthsParse=function(e,t,n){var i,r,a;if(this._monthsParseExact)return He.call(this,e,t,n);for(this._monthsParse||(this._monthsParse=[],this._longMonthsParse=[],this._shortMonthsParse=[]),i=0;i<12;i++){if(r=f([2e3,i]),n&&!this._longMonthsParse[i]&&(this._longMonthsParse[i]=new RegExp("^"+this.months(r,"").replace(".","")+"$","i"),this._shortMonthsParse[i]=new RegExp("^"+this.monthsShort(r,"").replace(".","")+"$","i")),n||this._monthsParse[i]||(a="^"+this.months(r,"")+"|^"+this.monthsShort(r,""),this._monthsParse[i]=new RegExp(a.replace(".",""),"i")),n&&"MMMM"===t&&this._longMonthsParse[i].test(e))return i;if(n&&"MMM"===t&&this._shortMonthsParse[i].test(e))return i;if(!n&&this._monthsParse[i].test(e))return i}},En.monthsRegex=function(e){return this._monthsParseExact?(o(this,"_monthsRegex")||Be.call(this),e?this._monthsStrictRegex:this._monthsRegex):(o(this,"_monthsRegex")||(this._monthsRegex=Ne),this._monthsStrictRegex&&e?this._monthsStrictRegex:this._monthsRegex)},En.monthsShortRegex=function(e){return this._monthsParseExact?(o(this,"_monthsRegex")||Be.call(this),e?this._monthsShortStrictRegex:this._monthsShortRegex):(o(this,"_monthsShortRegex")||(this._monthsShortRegex=Re),this._monthsShortStrictRegex&&e?this._monthsShortStrictRegex:this._monthsShortRegex)},En.week=function(e){return qe(e,this._week.dow,this._week.doy).week},En.firstDayOfYear=function(){return this._week.doy},En.firstDayOfWeek=function(){return this._week.dow},En.weekdays=function(e,t){var n=a(this._weekdays)?this._weekdays:this._weekdays[e&&!0!==e&&this._weekdays.isFormat.test(t)?"format":"standalone"];return!0===e?Ke(n,this._week.dow):e?n[e.day()]:n},En.weekdaysMin=function(e){return!0===e?Ke(this._weekdaysMin,this._week.dow):e?this._weekdaysMin[e.day()]:this._weekdaysMin},En.weekdaysShort=function(e){return!0===e?Ke(this._weekdaysShort,this._week.dow):e?this._weekdaysShort[e.day()]:this._weekdaysShort},En.weekdaysParse=function(e,t,n){var i,r,a;if(this._weekdaysParseExact)return nt.call(this,e,t,n);for(this._weekdaysParse||(this._weekdaysParse=[],this._minWeekdaysParse=[],this._shortWeekdaysParse=[],this._fullWeekdaysParse=[]),i=0;i<7;i++){if(r=f([2e3,1]).day(i),n&&!this._fullWeekdaysParse[i]&&(this._fullWeekdaysParse[i]=new RegExp("^"+this.weekdays(r,"").replace(".","\\.?")+"$","i"),this._shortWeekdaysParse[i]=new RegExp("^"+this.weekdaysShort(r,"").replace(".","\\.?")+"$","i"),this._minWeekdaysParse[i]=new RegExp("^"+this.weekdaysMin(r,"").replace(".","\\.?")+"$","i")),this._weekdaysParse[i]||(a="^"+this.weekdays(r,"")+"|^"+this.weekdaysShort(r,"")+"|^"+this.weekdaysMin(r,""),this._weekdaysParse[i]=new RegExp(a.replace(".",""),"i")),n&&"dddd"===t&&this._fullWeekdaysParse[i].test(e))return i;if(n&&"ddd"===t&&this._shortWeekdaysParse[i].test(e))return i;if(n&&"dd"===t&&this._minWeekdaysParse[i].test(e))return i;if(!n&&this._weekdaysParse[i].test(e))return i}},En.weekdaysRegex=function(e){return this._weekdaysParseExact?(o(this,"_weekdaysRegex")||it.call(this),e?this._weekdaysStrictRegex:this._weekdaysRegex):(o(this,"_weekdaysRegex")||(this._weekdaysRegex=Ze),this._weekdaysStrictRegex&&e?this._weekdaysStrictRegex:this._weekdaysRegex)},En.weekdaysShortRegex=function(e){return this._weekdaysParseExact?(o(this,"_weekdaysRegex")||it.call(this),e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex):(o(this,"_weekdaysShortRegex")||(this._weekdaysShortRegex=et),this._weekdaysShortStrictRegex&&e?this._weekdaysShortStrictRegex:this._weekdaysShortRegex)},En.weekdaysMinRegex=function(e){return this._weekdaysParseExact?(o(this,"_weekdaysRegex")||it.call(this),e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex):(o(this,"_weekdaysMinRegex")||(this._weekdaysMinRegex=tt),this._weekdaysMinStrictRegex&&e?this._weekdaysMinStrictRegex:this._weekdaysMinRegex)},En.isPM=function(e){return"p"===(e+"").toLowerCase().charAt(0)},En.meridiem=function(e,t,n){return e>11?n?"pm":"PM":n?"am":"AM"},pt("en",{eras:[{since:"0001-01-01",until:1/0,offset:1,name:"Anno Domini",narrow:"AD",abbr:"AD"},{since:"0000-12-31",until:-1/0,offset:1,name:"Before Christ",narrow:"BC",abbr:"BC"}],dayOfMonthOrdinalParse:/\d{1,2}(th|st|nd|rd)/,ordinal:function(e){var t=e%10;return e+(1===he(e%100/10)?"th":1===t?"st":2===t?"nd":3===t?"rd":"th")}}),r.lang=L("moment.lang is deprecated. Use moment.locale instead.",pt),r.langData=L("moment.langData is deprecated. Use moment.localeData instead.",yt);var jn=Math.abs;function On(e,t,n,i){var r=Xt(t,n);return e._milliseconds+=i*r._milliseconds,e._days+=i*r._days,e._months+=i*r._months,e._bubble()}function Rn(e){return e<0?Math.floor(e):Math.ceil(e)}function Nn(e){return 4800*e/146097}function Hn(e){return 146097*e/4800}function Un(e){return function(){return this.as(e)}}var Fn=Un("ms"),Bn=Un("s"),Wn=Un("m"),zn=Un("h"),Vn=Un("d"),Gn=Un("w"),qn=Un("M"),$n=Un("Q"),Kn=Un("y"),Jn=Fn;function Xn(e){return function(){return this.isValid()?this._data[e]:NaN}}var Qn=Xn("milliseconds"),Zn=Xn("seconds"),ei=Xn("minutes"),ti=Xn("hours"),ni=Xn("days"),ii=Xn("months"),ri=Xn("years");var ai=Math.round,si={ss:44,s:45,m:45,h:22,d:26,w:null,M:11};function oi(e,t,n,i,r){return r.relativeTime(t||1,!!n,e,i)}var ui=Math.abs;function di(e){return(e>0)-(e<0)||+e}function li(){if(!this.isValid())return this.localeData().invalidDate();var e,t,n,i,r,a,s,o,u=ui(this._milliseconds)/1e3,d=ui(this._days),l=ui(this._months),c=this.asSeconds();return c?(e=ce(u/60),t=ce(e/60),u%=60,e%=60,n=ce(l/12),l%=12,i=u?u.toFixed(3).replace(/\.?0+$/,""):"",r=c<0?"-":"",a=di(this._months)!==di(c)?"-":"",s=di(this._days)!==di(c)?"-":"",o=di(this._milliseconds)!==di(c)?"-":"",r+"P"+(n?a+n+"Y":"")+(l?a+l+"M":"")+(d?s+d+"D":"")+(t||e||u?"T":"")+(t?o+t+"H":"")+(e?o+e+"M":"")+(u?o+i+"S":"")):"P0D"}var ci=Ut.prototype;return ci.isValid=function(){return this._isValid},ci.abs=function(){var e=this._data;return this._milliseconds=jn(this._milliseconds),this._days=jn(this._days),this._months=jn(this._months),e.milliseconds=jn(e.milliseconds),e.seconds=jn(e.seconds),e.minutes=jn(e.minutes),e.hours=jn(e.hours),e.months=jn(e.months),e.years=jn(e.years),this},ci.add=function(e,t){return On(this,e,t,1)},ci.subtract=function(e,t){return On(this,e,t,-1)},ci.as=function(e){if(!this.isValid())return NaN;var t,n,i=this._milliseconds;if("month"===(e=U(e))||"quarter"===e||"year"===e)switch(t=this._days+i/864e5,n=this._months+Nn(t),e){case"month":return n;case"quarter":return n/3;case"year":return n/12}else switch(t=this._days+Math.round(Hn(this._months)),e){case"week":return t/7+i/6048e5;case"day":return t+i/864e5;case"hour":return 24*t+i/36e5;case"minute":return 1440*t+i/6e4;case"second":return 86400*t+i/1e3;case"millisecond":return Math.floor(864e5*t)+i;default:throw new Error("Unknown unit "+e)}},ci.asMilliseconds=Fn,ci.asSeconds=Bn,ci.asMinutes=Wn,ci.asHours=zn,ci.asDays=Vn,ci.asWeeks=Gn,ci.asMonths=qn,ci.asQuarters=$n,ci.asYears=Kn,ci.valueOf=Jn,ci._bubble=function(){var e,t,n,i,r,a=this._milliseconds,s=this._days,o=this._months,u=this._data;return a>=0&&s>=0&&o>=0||a<=0&&s<=0&&o<=0||(a+=864e5*Rn(Hn(o)+s),s=0,o=0),u.milliseconds=a%1e3,e=ce(a/1e3),u.seconds=e%60,t=ce(e/60),u.minutes=t%60,n=ce(t/60),u.hours=n%24,s+=ce(n/24),o+=r=ce(Nn(s)),s-=Rn(Hn(r)),i=ce(o/12),o%=12,u.days=s,u.months=o,u.years=i,this},ci.clone=function(){return Xt(this)},ci.get=function(e){return e=U(e),this.isValid()?this[e+"s"]():NaN},ci.milliseconds=Qn,ci.seconds=Zn,ci.minutes=ei,ci.hours=ti,ci.days=ni,ci.weeks=function(){return ce(this.days()/7)},ci.months=ii,ci.years=ri,ci.humanize=function(e,t){if(!this.isValid())return this.localeData().invalidDate();var n,i,r=!1,a=si;return"object"==typeof e&&(t=e,e=!1),"boolean"==typeof e&&(r=e),"object"==typeof t&&(a=Object.assign({},si,t),null!=t.s&&null==t.ss&&(a.ss=t.s-1)),i=function(e,t,n,i){var r=Xt(e).abs(),a=ai(r.as("s")),s=ai(r.as("m")),o=ai(r.as("h")),u=ai(r.as("d")),d=ai(r.as("M")),l=ai(r.as("w")),c=ai(r.as("y")),h=a<=n.ss&&["s",a]||a<n.s&&["ss",a]||s<=1&&["m"]||s<n.m&&["mm",s]||o<=1&&["h"]||o<n.h&&["hh",o]||u<=1&&["d"]||u<n.d&&["dd",u];return null!=n.w&&(h=h||l<=1&&["w"]||l<n.w&&["ww",l]),(h=h||d<=1&&["M"]||d<n.M&&["MM",d]||c<=1&&["y"]||["yy",c])[2]=t,h[3]=+e>0,h[4]=i,oi.apply(null,h)}(this,!r,a,n=this.localeData()),r&&(i=n.pastFuture(+this,i)),n.postformat(i)},ci.toISOString=li,ci.toString=li,ci.toJSON=li,ci.locale=un,ci.localeData=ln,ci.toIsoString=L("toIsoString() is deprecated. Please use toISOString() instead (notice the capitals)",li),ci.lang=dn,O("X",0,0,"unix"),O("x",0,0,"valueOf"),ue("x",ne),ue("X",/[+-]?\d+(\.\d{1,3})?/),fe("X",(function(e,t,n){n._d=new Date(1e3*parseFloat(e))})),fe("x",(function(e,t,n){n._d=new Date(he(e))})),r.version="2.30.1",t=jt,r.fn=An,r.min=function(){return Nt("isBefore",[].slice.call(arguments,0))},r.max=function(){return Nt("isAfter",[].slice.call(arguments,0))},r.now=function(){return Date.now?Date.now():+new Date},r.utc=f,r.unix=function(e){return jt(1e3*e)},r.months=function(e,t){return Pn(e,t,"months")},r.isDate=c,r.locale=pt,r.invalid=y,r.duration=Xt,r.isMoment=b,r.weekdays=function(e,t,n){return Cn(e,t,n,"weekdays")},r.parseZone=function(){return jt.apply(null,arguments).parseZone()},r.localeData=yt,r.isDuration=Ft,r.monthsShort=function(e,t){return Pn(e,t,"monthsShort")},r.weekdaysMin=function(e,t,n){return Cn(e,t,n,"weekdaysMin")},r.defineLocale=gt,r.updateLocale=function(e,t){if(null!=t){var n,i,r=dt;null!=lt[e]&&null!=lt[e].parentLocale?lt[e].set(A(lt[e]._config,t)):(null!=(i=ft(e))&&(r=i._config),t=A(r,t),null==i&&(t.abbr=e),(n=new Y(t)).parentLocale=lt[e],lt[e]=n),pt(e)}else null!=lt[e]&&(null!=lt[e].parentLocale?(lt[e]=lt[e].parentLocale,e===pt()&&pt(e)):null!=lt[e]&&delete lt[e]);return lt[e]},r.locales=function(){return S(lt)},r.weekdaysShort=function(e,t,n){return Cn(e,t,n,"weekdaysShort")},r.normalizeUnits=U,r.relativeTimeRounding=function(e){return void 0===e?ai:"function"==typeof e&&(ai=e,!0)},r.relativeTimeThreshold=function(e,t){return void 0!==si[e]&&(void 0===t?si[e]:(si[e]=t,"s"===e&&(si.ss=t-1),!0))},r.calendarFormat=function(e,t){var n=e.diff(t,"days",!0);return n<-6?"sameElse":n<-1?"lastWeek":n<0?"lastDay":n<1?"sameDay":n<2?"nextDay":n<7?"nextWeek":"sameElse"},r.prototype=An,r.HTML5_FMT={DATETIME_LOCAL:"YYYY-MM-DDTHH:mm",DATETIME_LOCAL_SECONDS:"YYYY-MM-DDTHH:mm:ss",DATETIME_LOCAL_MS:"YYYY-MM-DDTHH:mm:ss.SSS",DATE:"YYYY-MM-DD",TIME:"HH:mm",TIME_SECONDS:"HH:mm:ss",TIME_MS:"HH:mm:ss.SSS",WEEK:"GGGG-[W]WW",MONTH:"YYYY-MM"},r}()},3159:(e,t,n)=>{!function(){var e="undefined"!=typeof window?window:n.g,i={};for(var r in function(e,t,n){var i;function r(e){var t=0;return function(){return t<e.length?{done:!1,value:e[t++]}:{done:!0}}}var a="function"==typeof Object.defineProperties?Object.defineProperty:function(e,t,n){return e==Array.prototype||e==Object.prototype||(e[t]=n.value),e},s=function(n){n=["object"==typeof globalThis&&globalThis,n,"object"==typeof e&&e,"object"==typeof self&&self,"object"==typeof t&&t];for(var i=0;i<n.length;++i){var r=n[i];if(r&&r.Math==Math)return r}throw Error("Cannot find global object")}(this);function o(e,t){if(t)e:{var n=s;e=e.split(".");for(var i=0;i<e.length-1;i++){var r=e[i];if(!(r in n))break e;n=n[r]}(t=t(i=n[e=e[e.length-1]]))!=i&&null!=t&&a(n,e,{configurable:!0,writable:!0,value:t})}}function u(e){return(e={next:e})[Symbol.iterator]=function(){return this},e}function d(e){var t="undefined"!=typeof Symbol&&Symbol.iterator&&e[Symbol.iterator];if(t)return t.call(e);if("number"==typeof e.length)return{next:r(e)};throw Error(String(e)+" is not an iterable or ArrayLike")}function l(e){if(!(e instanceof Array)){e=d(e);for(var t,n=[];!(t=e.next()).done;)n.push(t.value);e=n}return e}o("Symbol",(function(e){function t(e,t){this.g=e,a(this,"description",{configurable:!0,writable:!0,value:t})}if(e)return e;t.prototype.toString=function(){return this.g};var n="jscomp_symbol_"+(1e9*Math.random()>>>0)+"_",i=0;return function e(r){if(this instanceof e)throw new TypeError("Symbol is not a constructor");return new t(n+(r||"")+"_"+i++,r)}})),o("Symbol.iterator",(function(e){if(e)return e;e=Symbol("Symbol.iterator");for(var t="Array Int8Array Uint8Array Uint8ClampedArray Int16Array Uint16Array Int32Array Uint32Array Float32Array Float64Array".split(" "),n=0;n<t.length;n++){var i=s[t[n]];"function"==typeof i&&"function"!=typeof i.prototype[e]&&a(i.prototype,e,{configurable:!0,writable:!0,value:function(){return u(r(this))}})}return e}));var c,h="function"==typeof Object.create?Object.create:function(e){function t(){}return t.prototype=e,new t};if("function"==typeof Object.setPrototypeOf)c=Object.setPrototypeOf;else{var m;e:{var f={};try{f.__proto__={a:!0},m=f.a;break e}catch(e){}m=!1}c=m?function(e,t){if(e.__proto__=t,e.__proto__!==t)throw new TypeError(e+" is not extensible");return e}:null}var p=c;function g(e,t){if(e.prototype=h(t.prototype),e.prototype.constructor=e,p)p(e,t);else for(var n in t)if("prototype"!=n)if(Object.defineProperties){var i=Object.getOwnPropertyDescriptor(t,n);i&&Object.defineProperty(e,n,i)}else e[n]=t[n];e.pk=t.prototype}function y(){this.o=!1,this.l=null,this.h=void 0,this.g=1,this.j=this.m=0,this.A=this.i=null}function _(e){if(e.o)throw new TypeError("Generator is already running");e.o=!0}function v(e,t){e.i={vg:t,Ig:!0},e.g=e.m||e.j}function M(e,t,n){return e.g=n,{value:t}}function w(e){e.g=0}function b(e,t,n){e.m=t,null!=n&&(e.j=n)}function T(e,t){e.m=0,e.j=t||0}function L(e,t,n){e.g=t,e.m=n||0}function S(e,t){return e.m=t||0,t=e.i.vg,e.i=null,t}function k(e){e.A=[e.i],e.m=0,e.j=0}function D(e,t){var n=e.A.splice(0)[0];(n=e.i=e.i||n)?n.Ig?e.g=e.m||e.j:null!=n.u&&e.j<n.u?(e.g=n.u,e.i=null):e.g=e.j:e.g=t}function x(e){this.g=new y,this.h=e}function A(e,t,n,i){try{var r=t.call(e.g.l,n);if(!(r instanceof Object))throw new TypeError("Iterator result "+r+" is not an object");if(!r.done)return e.g.o=!1,r;var a=r.value}catch(t){return e.g.l=null,v(e.g,t),Y(e)}return e.g.l=null,i.call(e.g,a),Y(e)}function Y(e){for(;e.g.g;)try{var t=e.h(e.g);if(t)return e.g.o=!1,{value:t.value,done:!1}}catch(t){e.g.h=void 0,v(e.g,t)}if(e.g.o=!1,e.g.i){if(t=e.g.i,e.g.i=null,t.Ig)throw t.vg;return{value:t.return,done:!0}}return{value:void 0,done:!0}}function E(e){this.next=function(t){return _(e.g),e.g.l?t=A(e,e.g.l.next,t,e.g.s):(e.g.s(t),t=Y(e)),t},this.throw=function(t){return _(e.g),e.g.l?t=A(e,e.g.l.throw,t,e.g.s):(v(e.g,t),t=Y(e)),t},this.return=function(t){return function(e,t){_(e.g);var n=e.g.l;return n?A(e,"return"in n?n.return:function(e){return{value:e,done:!0}},t,e.g.return):(e.g.return(t),Y(e))}(e,t)},this[Symbol.iterator]=function(){return this}}function I(e){return function(e){function t(t){return e.next(t)}function n(t){return e.throw(t)}return new Promise((function(i,r){!function e(a){a.done?i(a.value):Promise.resolve(a.value).then(t,n).then(e,r)}(e.next())}))}(new E(new x(e)))}function P(){for(var e=Number(this),t=[],n=e;n<arguments.length;n++)t[n-e]=arguments[n];return t}function C(e,t){return Object.prototype.hasOwnProperty.call(e,t)}function j(e,t){e instanceof String&&(e+="");var n=0,i=!1,r={next:function(){if(!i&&n<e.length){var r=n++;return{value:t(r,e[r]),done:!1}}return i=!0,{done:!0,value:void 0}}};return r[Symbol.iterator]=function(){return r},r}function O(e,t,n){e instanceof String&&(e=String(e));for(var i=e.length,r=0;r<i;r++){var a=e[r];if(t.call(n,a,r,e))return{Gg:r,v:a}}return{Gg:-1,v:void 0}}function R(e,t,n){if(null==e)throw new TypeError("The 'this' value for String.prototype."+n+" must not be null or undefined");if(t instanceof RegExp)throw new TypeError("First argument to String.prototype."+n+" must not be a regular expression");return e+""}y.prototype.s=function(e){this.h=e},y.prototype.return=function(e){this.i={return:e},this.g=this.j},y.prototype.u=function(e){this.g=e},o("Promise",(function(e){function t(e){this.h=0,this.i=void 0,this.g=[],this.o=!1;var t=this.j();try{e(t.resolve,t.reject)}catch(e){t.reject(e)}}function n(){this.g=null}function i(e){return e instanceof t?e:new t((function(t){t(e)}))}if(e)return e;n.prototype.h=function(e){if(null==this.g){this.g=[];var t=this;this.i((function(){t.l()}))}this.g.push(e)};var r=s.setTimeout;n.prototype.i=function(e){r(e,0)},n.prototype.l=function(){for(;this.g&&this.g.length;){var e=this.g;this.g=[];for(var t=0;t<e.length;++t){var n=e[t];e[t]=null;try{n()}catch(e){this.j(e)}}}this.g=null},n.prototype.j=function(e){this.i((function(){throw e}))},t.prototype.j=function(){function e(e){return function(i){n||(n=!0,e.call(t,i))}}var t=this,n=!1;return{resolve:e(this.F),reject:e(this.l)}},t.prototype.F=function(e){if(e===this)this.l(new TypeError("A Promise cannot resolve to itself"));else if(e instanceof t)this.H(e);else{e:switch(typeof e){case"object":var n=null!=e;break e;case"function":n=!0;break e;default:n=!1}n?this.C(e):this.m(e)}},t.prototype.C=function(e){var t=void 0;try{t=e.then}catch(e){return void this.l(e)}"function"==typeof t?this.I(t,e):this.m(e)},t.prototype.l=function(e){this.s(2,e)},t.prototype.m=function(e){this.s(1,e)},t.prototype.s=function(e,t){if(0!=this.h)throw Error("Cannot settle("+e+", "+t+"): Promise already settled in state"+this.h);this.h=e,this.i=t,2===this.h&&this.G(),this.A()},t.prototype.G=function(){var e=this;r((function(){if(e.B()){var t=s.console;void 0!==t&&t.error(e.i)}}),1)},t.prototype.B=function(){if(this.o)return!1;var e=s.CustomEvent,t=s.Event,n=s.dispatchEvent;return void 0===n||("function"==typeof e?e=new e("unhandledrejection",{cancelable:!0}):"function"==typeof t?e=new t("unhandledrejection",{cancelable:!0}):(e=s.document.createEvent("CustomEvent")).initCustomEvent("unhandledrejection",!1,!0,e),e.promise=this,e.reason=this.i,n(e))},t.prototype.A=function(){if(null!=this.g){for(var e=0;e<this.g.length;++e)a.h(this.g[e]);this.g=null}};var a=new n;return t.prototype.H=function(e){var t=this.j();e.Hd(t.resolve,t.reject)},t.prototype.I=function(e,t){var n=this.j();try{e.call(t,n.resolve,n.reject)}catch(e){n.reject(e)}},t.prototype.then=function(e,n){function i(e,t){return"function"==typeof e?function(t){try{r(e(t))}catch(e){a(e)}}:t}var r,a,s=new t((function(e,t){r=e,a=t}));return this.Hd(i(e,r),i(n,a)),s},t.prototype.catch=function(e){return this.then(void 0,e)},t.prototype.Hd=function(e,t){function n(){switch(i.h){case 1:e(i.i);break;case 2:t(i.i);break;default:throw Error("Unexpected state: "+i.h)}}var i=this;null==this.g?a.h(n):this.g.push(n),this.o=!0},t.resolve=i,t.reject=function(e){return new t((function(t,n){n(e)}))},t.race=function(e){return new t((function(t,n){for(var r=d(e),a=r.next();!a.done;a=r.next())i(a.value).Hd(t,n)}))},t.all=function(e){var n=d(e),r=n.next();return r.done?i([]):new t((function(e,t){function a(t){return function(n){s[t]=n,0==--o&&e(s)}}var s=[],o=0;do{s.push(void 0),o++,i(r.value).Hd(a(s.length-1),t),r=n.next()}while(!r.done)}))},t})),o("WeakMap",(function(e){function t(e){if(this.g=(u+=Math.random()+1).toString(),e){e=d(e);for(var t;!(t=e.next()).done;)t=t.value,this.set(t[0],t[1])}}function n(){}function i(e){var t=typeof e;return"object"===t&&null!==e||"function"===t}function r(e){if(!C(e,o)){var t=new n;a(e,o,{value:t})}}function s(e){var t=Object[e];t&&(Object[e]=function(e){return e instanceof n?e:(Object.isExtensible(e)&&r(e),t(e))})}if(function(){if(!e||!Object.seal)return!1;try{var t=Object.seal({}),n=Object.seal({}),i=new e([[t,2],[n,3]]);return 2==i.get(t)&&3==i.get(n)&&(i.delete(t),i.set(n,4),!i.has(t)&&4==i.get(n))}catch(e){return!1}}())return e;var o="$jscomp_hidden_"+Math.random();s("freeze"),s("preventExtensions"),s("seal");var u=0;return t.prototype.set=function(e,t){if(!i(e))throw Error("Invalid WeakMap key");if(r(e),!C(e,o))throw Error("WeakMap key fail: "+e);return e[o][this.g]=t,this},t.prototype.get=function(e){return i(e)&&C(e,o)?e[o][this.g]:void 0},t.prototype.has=function(e){return i(e)&&C(e,o)&&C(e[o],this.g)},t.prototype.delete=function(e){return!!(i(e)&&C(e,o)&&C(e[o],this.g))&&delete e[o][this.g]},t})),o("Map",(function(e){function t(){var e={};return e.Ob=e.next=e.head=e}function n(e,t){var n=e[1];return u((function(){if(n){for(;n.head!=e[1];)n=n.Ob;for(;n.next!=n.head;)return n=n.next,{done:!1,value:t(n)};n=null}return{done:!0,value:void 0}}))}function i(e,t){var n=t&&typeof t;"object"==n||"function"==n?a.has(t)?n=a.get(t):(n=""+ ++s,a.set(t,n)):n="p_"+t;var i=e[0][n];if(i&&C(e[0],n))for(e=0;e<i.length;e++){var r=i[e];if(t!=t&&r.key!=r.key||t===r.key)return{id:n,list:i,index:e,entry:r}}return{id:n,list:i,index:-1,entry:void 0}}function r(e){if(this[0]={},this[1]=t(),this.size=0,e){e=d(e);for(var n;!(n=e.next()).done;)n=n.value,this.set(n[0],n[1])}}if(function(){if(!e||"function"!=typeof e||!e.prototype.entries||"function"!=typeof Object.seal)return!1;try{var t=Object.seal({x:4}),n=new e(d([[t,"s"]]));if("s"!=n.get(t)||1!=n.size||n.get({x:4})||n.set({x:4},"t")!=n||2!=n.size)return!1;var i=n.entries(),r=i.next();return!r.done&&r.value[0]==t&&"s"==r.value[1]&&!((r=i.next()).done||4!=r.value[0].x||"t"!=r.value[1]||!i.next().done)}catch(e){return!1}}())return e;var a=new WeakMap;r.prototype.set=function(e,t){var n=i(this,e=0===e?0:e);return n.list||(n.list=this[0][n.id]=[]),n.entry?n.entry.value=t:(n.entry={next:this[1],Ob:this[1].Ob,head:this[1],key:e,value:t},n.list.push(n.entry),this[1].Ob.next=n.entry,this[1].Ob=n.entry,this.size++),this},r.prototype.delete=function(e){return!(!(e=i(this,e)).entry||!e.list||(e.list.splice(e.index,1),e.list.length||delete this[0][e.id],e.entry.Ob.next=e.entry.next,e.entry.next.Ob=e.entry.Ob,e.entry.head=null,this.size--,0))},r.prototype.clear=function(){this[0]={},this[1]=this[1].Ob=t(),this.size=0},r.prototype.has=function(e){return!!i(this,e).entry},r.prototype.get=function(e){return(e=i(this,e).entry)&&e.value},r.prototype.entries=function(){return n(this,(function(e){return[e.key,e.value]}))},r.prototype.keys=function(){return n(this,(function(e){return e.key}))},r.prototype.values=function(){return n(this,(function(e){return e.value}))},r.prototype.forEach=function(e,t){for(var n,i=this.entries();!(n=i.next()).done;)n=n.value,e.call(t,n[1],n[0],this)},r.prototype[Symbol.iterator]=r.prototype.entries;var s=0;return r})),o("Set",(function(e){function t(e){if(this.g=new Map,e){e=d(e);for(var t;!(t=e.next()).done;)this.add(t.value)}this.size=this.g.size}return function(){if(!e||"function"!=typeof e||!e.prototype.entries||"function"!=typeof Object.seal)return!1;try{var t=Object.seal({x:4}),n=new e(d([t]));if(!n.has(t)||1!=n.size||n.add(t)!=n||1!=n.size||n.add({x:4})!=n||2!=n.size)return!1;var i=n.entries(),r=i.next();return!r.done&&r.value[0]==t&&r.value[1]==t&&!(r=i.next()).done&&r.value[0]!=t&&4==r.value[0].x&&r.value[1]==r.value[0]&&i.next().done}catch(e){return!1}}()?e:(t.prototype.add=function(e){return e=0===e?0:e,this.g.set(e,e),this.size=this.g.size,this},t.prototype.delete=function(e){return e=this.g.delete(e),this.size=this.g.size,e},t.prototype.clear=function(){this.g.clear(),this.size=0},t.prototype.has=function(e){return this.g.has(e)},t.prototype.entries=function(){return this.g.entries()},t.prototype.values=function(){return this.g.values()},t.prototype.keys=t.prototype.values,t.prototype[Symbol.iterator]=t.prototype.values,t.prototype.forEach=function(e,t){var n=this;this.g.forEach((function(i){return e.call(t,i,i,n)}))},t)})),o("Array.prototype.keys",(function(e){return e||function(){return j(this,(function(e){return e}))}})),o("Array.prototype.findIndex",(function(e){return e||function(e,t){return O(this,e,t).Gg}})),o("Array.from",(function(e){return e||function(e,t,n){t=null!=t?t:function(e){return e};var i=[],r="undefined"!=typeof Symbol&&Symbol.iterator&&e[Symbol.iterator];if("function"==typeof r){e=r.call(e);for(var a=0;!(r=e.next()).done;)i.push(t.call(n,r.value,a++))}else for(r=e.length,a=0;a<r;a++)i.push(t.call(n,e[a],a));return i}})),o("Array.prototype.values",(function(e){return e||function(){return j(this,(function(e,t){return t}))}})),o("Object.is",(function(e){return e||function(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}})),o("Array.prototype.includes",(function(e){return e||function(e,t){var n=this;n instanceof String&&(n=String(n));var i=n.length;for(0>(t=t||0)&&(t=Math.max(t+i,0));t<i;t++){var r=n[t];if(r===e||Object.is(r,e))return!0}return!1}})),o("String.prototype.includes",(function(e){return e||function(e,t){return-1!==R(this,e,"includes").indexOf(e,t||0)}})),o("String.fromCodePoint",(function(e){return e||function(e){for(var t="",n=0;n<arguments.length;n++){var i=Number(arguments[n]);if(0>i||1114111<i||i!==Math.floor(i))throw new RangeError("invalid_code_point "+i);65535>=i?t+=String.fromCharCode(i):(i-=65536,t+=String.fromCharCode(i>>>10&1023|55296),t+=String.fromCharCode(1023&i|56320))}return t}})),o("WeakSet",(function(e){function t(e){if(this.g=new WeakMap,e){e=d(e);for(var t;!(t=e.next()).done;)this.add(t.value)}}return function(){if(!e||!Object.seal)return!1;try{var t=Object.seal({}),n=Object.seal({}),i=new e([t]);return!(!i.has(t)||i.has(n))&&(i.delete(t),i.add(n),!i.has(t)&&i.has(n))}catch(e){return!1}}()?e:(t.prototype.add=function(e){return this.g.set(e,!0),this},t.prototype.has=function(e){return this.g.has(e)},t.prototype.delete=function(e){return this.g.delete(e)},t)})),o("Array.prototype.find",(function(e){return e||function(e,t){return O(this,e,t).v}})),o("String.prototype.startsWith",(function(e){return e||function(e,t){var n=R(this,e,"startsWith"),i=n.length,r=e.length;t=Math.max(0,Math.min(0|t,n.length));for(var a=0;a<r&&t<i;)if(n[t++]!=e[a++])return!1;return a>=r}})),o("Object.entries",(function(e){return e||function(e){var t,n=[];for(t in e)C(e,t)&&n.push([t,e[t]]);return n}}));var N="function"==typeof Object.assign?Object.assign:function(e,t){for(var n=1;n<arguments.length;n++){var i=arguments[n];if(i)for(var r in i)C(i,r)&&(e[r]=i[r])}return e};o("Object.assign",(function(e){return e||N})),o("Promise.prototype.finally",(function(e){return e||function(e){return this.then((function(t){return Promise.resolve(e()).then((function(){return t}))}),(function(t){return Promise.resolve(e()).then((function(){throw t}))}))}})),o("Array.prototype.entries",(function(e){return e||function(){return j(this,(function(e,t){return[e,t]}))}})),o("Number.isNaN",(function(e){return e||function(e){return"number"==typeof e&&isNaN(e)}})),o("String.prototype.repeat",(function(e){return e||function(e){var t=R(this,null,"repeat");if(0>e||1342177279<e)throw new RangeError("Invalid count value");e|=0;for(var n="";e;)1&e&&(n+=t),(e>>>=1)&&(t+=t);return n}})),o("Number.EPSILON",(function(){return Math.pow(2,-52)})),o("Number.MAX_SAFE_INTEGER",(function(){return 9007199254740991})),o("Number.isFinite",(function(e){return e||function(e){return"number"==typeof e&&!isNaN(e)&&1/0!==e&&-1/0!==e}})),o("Object.values",(function(e){return e||function(e){var t,n=[];for(t in e)C(e,t)&&n.push(e[t]);return n}})),o("Math.log2",(function(e){return e||function(e){return Math.log(e)/Math.LN2}})),o("String.prototype.endsWith",(function(e){return e||function(e,t){var n=R(this,e,"endsWith");void 0===t&&(t=n.length),t=Math.max(0,Math.min(0|t,n.length));for(var i=e.length;0<i&&0<t;)if(n[--t]!=e[--i])return!1;return 0>=i}})),o("Math.trunc",(function(e){return e||function(e){if(e=Number(e),isNaN(e)||1/0===e||-1/0===e||0===e)return e;var t=Math.floor(Math.abs(e));return 0>e?-t:t}}));var H=this||self;function U(e,t){e=e.split(".");var n,i=H;e[0]in i||void 0===i.execScript||i.execScript("var "+e[0]);for(;e.length&&(n=e.shift());)e.length||void 0===t?i=i[n]&&i[n]!==Object.prototype[n]?i[n]:i[n]={}:i[n]=t}function F(){}function B(){}function W(e){this.g=Math.exp(Math.log(.5)/e),this.i=this.h=0}function z(e){return e.h/(1-Math.pow(e.g,e.i))}function V(){this.h=new W(2),this.j=new W(5),this.g=0,this.i=128e3,this.l=16e3}function G(){}function q(){}function $(){}function K(e){var t=P.apply(1,arguments);X.has(e)||(X.add(e),$.apply(G,l(t)))}function J(){}W.prototype.sample=function(e,t){var n=Math.pow(this.g,e);t=t*(1-n)+n*this.h,isNaN(t)||(this.h=t,this.i+=e)},V.prototype.configure=function(e){this.i=e.minTotalBytes,this.l=e.minBytes,this.h.g=Math.exp(Math.log(.5)/e.fastHalfLife),this.j.g=Math.exp(Math.log(.5)/e.slowHalfLife)},V.prototype.sample=function(e,t){if(!(t<this.l)){var n=8e3*t/e;e/=1e3,this.g+=t,this.h.sample(e,n),this.j.sample(e,n)}},V.prototype.getBandwidthEstimate=function(e){return this.g<this.i?e:Math.min(z(this.h),z(this.j))};var X=new Set;function Q(){this.g={}}function Z(){this.g=new Q}function ee(e,t,n,i){this.target=e,this.type=t,this.listener=n,this.g=function(e,t){if(null==t)return!1;if("boolean"==typeof t)return t;var n=new Set(["passive","capture"]);return Object.keys(t).filter((function(e){return!n.has(e)})),function(e){var t=te;if(null==t){t=!1;try{var n={},i={get:function(){return t=!0,!1}};Object.defineProperty(n,"passive",i),Object.defineProperty(n,"capture",i),i=function(){},e.addEventListener("test",i,n),e.removeEventListener("test",i,n)}catch(e){t=!1}te=t}return t||!1}(e)?t:t.capture||!1}(e,i),this.target.addEventListener(t,n,this.g)}e.console&&($=function(){return console.warn.apply(console,l(P.apply(0,arguments)))},q=function(){console.error.apply(console,l(P.apply(0,arguments)))}),(i=Q.prototype).push=function(e,t){this.g.hasOwnProperty(e)?this.g[e].push(t):this.g[e]=[t]},i.get=function(e){return(e=this.g[e])?e.slice():null},i.remove=function(e,t){e in this.g&&(this.g[e]=this.g[e].filter((function(e){return e!=t})),0==this.g[e].length&&delete this.g[e])},i.forEach=function(e){for(var t in this.g)e(t,this.g[t])},i.size=function(){return Object.keys(this.g).length},i.keys=function(){return Object.keys(this.g)},(i=Z.prototype).release=function(){this.Va(),this.g=null},i.D=function(e,t,n,i){this.g&&(e=new ee(e,t,n,i),this.g.push(t,e))},i.pa=function(e,t,n,i){var r=this;this.D(e,t,(function i(a){r.cb(e,t,i),n(a)}),i)},i.cb=function(e,t,n){if(this.g)for(var i=this.g.get(t)||[],r=(i=d(i)).next();!r.done;r=i.next())(r=r.value).target!=e||n!=r.listener&&n||(r.cb(),this.g.remove(t,r))},i.Va=function(){if(this.g){var e,t=this.g,n=[];for(e in t.g)n.push.apply(n,l(t.g[e]));for(n=(t=d(n)).next();!n.done;n=t.next())n.value.cb();this.g.g={}}},U("shaka.util.EventManager",Z),Z.prototype.removeAll=Z.prototype.Va,Z.prototype.unlisten=Z.prototype.cb,Z.prototype.listenOnce=Z.prototype.pa,Z.prototype.listen=Z.prototype.D,Z.prototype.release=Z.prototype.release,ee.prototype.cb=function(){this.target.removeEventListener(this.type,this.listener,this.g),this.listener=this.target=null,this.g=!1};var te=void 0;function ne(t){if(re.has(t))return re.get(t);var n=e.ManagedMediaSource||e.MediaSource;return!!n&&(n=n.isTypeSupported(t),re.set(t,n),n)}function ie(){var t=e.ManagedSourceBuffer||e.SourceBuffer;return!!t&&!!t.prototype&&!!t.prototype.changeType}var re=new Map;function ae(e,t){this.g=e,this.h=t}function se(e,t){var n=new ae(5,0),i=de,r=i.g,a=n.h-r.h;(0<(n.g-r.g||a)?i.i:i.h)(i.g,n,e,t)}function oe(e,t,n,i){$([n,"has been deprecated and will be removed in",t,". We are currently at version",e,". Additional information:",i].join(" "))}function ue(e,t,n,i){q([n,"has been deprecated and has been removed in",t,". We are now at version",e,". Additional information:",i].join(" "))}ae.prototype.toString=function(){return"v"+this.g+"."+this.h};var de=null;function le(){}function ce(){}function he(){}function me(e,t){if(!e&&!t)return!0;if(!e||!t||e.byteLength!=t.byteLength)return!1;if((ArrayBuffer.isView(e)?e.buffer:e)==(ArrayBuffer.isView(t)?t.buffer:t)&&(e.byteOffset||0)==(t.byteOffset||0))return!0;var n=pe(e);t=pe(t);for(var i=0;i<e.byteLength;i++)if(n[i]!=t[i])return!1;return!0}function fe(e){return ArrayBuffer.isView(e)?0==e.byteOffset&&e.byteLength==e.buffer.byteLength?e.buffer:new Uint8Array(e).buffer:e}function pe(e,t,n){return _e(e,void 0===t?0:t,n=void 0===n?1/0:n,Uint8Array)}function ge(e,t,n){return _e(e,void 0===t?0:t,n=void 0===n?1/0:n,Uint16Array)}function ye(e,t,n){return _e(e,void 0===t?0:t,n=void 0===n?1/0:n,DataView)}function _e(e,t,n,i){var r=ArrayBuffer.isView(e)?e.buffer:e,a=1;"BYTES_PER_ELEMENT"in i&&(a=i.BYTES_PER_ELEMENT);var s=((e.byteOffset||0)+e.byteLength)/a;return new i(r,e=Math.floor(Math.max(0,Math.min(((e.byteOffset||0)+t)/a,s))),Math.floor(Math.min(e+Math.max(n,0),s))-e)}function ve(){}function Me(e){this.l=new ce,(e=we[e.toLowerCase()])&&(this.l=e()),this.h=new le,(e=be)&&(this.h=e())}le.prototype.extract=function(){},le.prototype.decode=function(){return[]},le.prototype.clear=function(){},le.prototype.getStreams=function(){return[]},ce.prototype.init=function(){},ce.prototype.parse=function(){return[]},U("shaka.util.BufferUtils",he),he.toDataView=ye,he.toUint16=ge,he.toUint8=pe,he.toArrayBuffer=fe,he.equal=me,ve.prototype.init=function(){},ve.prototype.i=function(){},ve.prototype.g=function(){},ve.prototype.j=function(){},U("shaka.media.IClosedCaptionParser",ve),Me.prototype.init=function(e,t){void 0!==t&&t||this.g(),this.l.init(e)},Me.prototype.i=function(e){for(var t=(e=d(e=this.l.parse(e))).next();!t.done;t=e.next()){var n=pe((t=t.value).packet);0<n.length&&this.h.extract(n,t.pts)}return this.h.decode()},Me.prototype.g=function(){this.h.clear()},Me.prototype.j=function(){return this.h.getStreams()},U("shaka.media.ClosedCaptionParser",Me),Me.findDecoder=function(){return be},Me.unregisterDecoder=function(){be=null},Me.registerDecoder=function(e){be=e},Me.findParser=function(e){return we[e]},Me.unregisterParser=function(e){delete we[e]},Me.registerParser=function(e,t){we[e]=t};var we={},be=null;function Te(){this.id="",this.regionAnchorY=this.regionAnchorX=this.viewportAnchorY=this.viewportAnchorX=0,this.height=this.width=100,this.viewportAnchorUnits=this.widthUnits=this.heightUnits=Le,this.scroll=Se}U("shaka.text.CueRegion",Te);var Le=1;Te.units={PX:0,PERCENTAGE:Le,LINES:2};var Se="";function ke(e,t){return!("number"!=typeof e||"number"!=typeof t||!isNaN(e)||!isNaN(t))||e===t}function De(e,t){-1<(t=e.indexOf(t))&&e.splice(t,1)}function xe(e,t,n){if(n||(n=ke),e.length!=t.length)return!1;t=t.slice();for(var i=(e=d(e)).next(),r={};!i.done;r={Jg:void 0},i=e.next()){if(r.Jg=i.value,-1==(i=t.findIndex(function(e){return function(t){return n(e.Jg,t)}}(r))))return!1;t[i]=t[t.length-1],t.pop()}return 0==t.length}function Ae(e,t,n){if(n||(n=ke),e.length!=t.length)return!1;for(var i=0;i<e.length;i++)if(!n(e[i],t[i]))return!1;return!0}function Ye(e,t,n){var i=P.apply(3,arguments);if(this.severity=e,this.category=t,this.code=n,this.data=i,this.handled=!1,this.message="Shaka Error "+this.code,Ee)try{throw Error(this.message||"Shaka Error")}catch(e){this.stack=e.stack}}Te.scrollMode={NONE:Se,UP:"up"},Ye.prototype.toString=function(){return"shaka.util.Error "+JSON.stringify(this,null," ")},U("shaka.util.Error",Ye);var Ee=!0;function Ie(e){this.h=e,this.g=void 0}function Pe(e,t){return!e.length||!t.length||e===t||0<Ce(e,t).length}function Ce(e,t){if(!e.length)return t;if(!t.length)return e;for(var n=[],i=(e=d(e)).next();!i.done;i=e.next()){i=i.value;for(var r=d(t),a=r.next();!a.done;a=r.next())if(a=a.value,i.keySystem==a.keySystem){r=new Map;for(var s=d((i.initData||[]).concat(a.initData||[])),o=s.next();!o.done;o=s.next())o=o.value,r.set(o.keyId,o);r=Array.from(r.values()),s=i.keyIds&&a.keyIds?new Set([].concat(l(i.keyIds),l(a.keyIds))):i.keyIds||a.keyIds,n.push({keySystem:i.keySystem,licenseServerUri:i.licenseServerUri||a.licenseServerUri,distinctiveIdentifierRequired:i.distinctiveIdentifierRequired||a.distinctiveIdentifierRequired,persistentStateRequired:i.persistentStateRequired||a.persistentStateRequired,videoRobustness:i.videoRobustness||a.videoRobustness,audioRobustness:i.audioRobustness||a.audioRobustness,serverCertificate:i.serverCertificate||a.serverCertificate,serverCertificateUri:i.serverCertificateUri||a.serverCertificateUri,initData:r,keyIds:s});break}}return n}function je(e){return!!e&&!!e.match(/^com\.(microsoft|chromecast)\.playready/)}Ye.Severity={RECOVERABLE:1,CRITICAL:2},Ye.Category={NETWORK:1,TEXT:2,MEDIA:3,MANIFEST:4,STREAMING:5,DRM:6,PLAYER:7,CAST:8,STORAGE:9,ADS:10},Ye.Code={UNSUPPORTED_SCHEME:1e3,BAD_HTTP_STATUS:1001,HTTP_ERROR:1002,TIMEOUT:1003,MALFORMED_DATA_URI:1004,REQUEST_FILTER_ERROR:1006,RESPONSE_FILTER_ERROR:1007,MALFORMED_TEST_URI:1008,UNEXPECTED_TEST_REQUEST:1009,ATTEMPTS_EXHAUSTED:1010,SEGMENT_MISSING:1011,INVALID_TEXT_HEADER:2e3,INVALID_TEXT_CUE:2001,UNABLE_TO_DETECT_ENCODING:2003,BAD_ENCODING:2004,INVALID_XML:2005,INVALID_MP4_TTML:2007,INVALID_MP4_VTT:2008,UNABLE_TO_EXTRACT_CUE_START_TIME:2009,INVALID_MP4_CEA:2010,TEXT_COULD_NOT_GUESS_MIME_TYPE:2011,CANNOT_ADD_EXTERNAL_TEXT_TO_SRC_EQUALS:2012,TEXT_ONLY_WEBVTT_SRC_EQUALS:2013,MISSING_TEXT_PLUGIN:2014,CHAPTERS_TRACK_FAILED:2015,UNSUPPORTED_EXTERNAL_THUMBNAILS_URI:2017,BUFFER_READ_OUT_OF_BOUNDS:3e3,JS_INTEGER_OVERFLOW:3001,EBML_OVERFLOW:3002,EBML_BAD_FLOATING_POINT_SIZE:3003,MP4_SIDX_WRONG_BOX_TYPE:3004,MP4_SIDX_INVALID_TIMESCALE:3005,MP4_SIDX_TYPE_NOT_SUPPORTED:3006,WEBM_CUES_ELEMENT_MISSING:3007,WEBM_EBML_HEADER_ELEMENT_MISSING:3008,WEBM_SEGMENT_ELEMENT_MISSING:3009,WEBM_INFO_ELEMENT_MISSING:3010,WEBM_DURATION_ELEMENT_MISSING:3011,WEBM_CUE_TRACK_POSITIONS_ELEMENT_MISSING:3012,WEBM_CUE_TIME_ELEMENT_MISSING:3013,MEDIA_SOURCE_OPERATION_FAILED:3014,MEDIA_SOURCE_OPERATION_THREW:3015,VIDEO_ERROR:3016,QUOTA_EXCEEDED_ERROR:3017,TRANSMUXING_FAILED:3018,CONTENT_TRANSFORMATION_FAILED:3019,MSS_MISSING_DATA_FOR_TRANSMUXING:3020,MSS_TRANSMUXING_FAILED:3022,TRANSMUXING_NO_VIDEO_DATA:3023,UNABLE_TO_GUESS_MANIFEST_TYPE:4e3,DASH_INVALID_XML:4001,DASH_NO_SEGMENT_INFO:4002,DASH_EMPTY_ADAPTATION_SET:4003,DASH_EMPTY_PERIOD:4004,DASH_WEBM_MISSING_INIT:4005,DASH_UNSUPPORTED_CONTAINER:4006,DASH_PSSH_BAD_ENCODING:4007,DASH_NO_COMMON_KEY_SYSTEM:4008,DASH_MULTIPLE_KEY_IDS_NOT_SUPPORTED:4009,DASH_CONFLICTING_KEY_IDS:4010,RESTRICTIONS_CANNOT_BE_MET:4012,HLS_PLAYLIST_HEADER_MISSING:4015,INVALID_HLS_TAG:4016,HLS_INVALID_PLAYLIST_HIERARCHY:4017,DASH_DUPLICATE_REPRESENTATION_ID:4018,HLS_MULTIPLE_MEDIA_INIT_SECTIONS_FOUND:4020,HLS_REQUIRED_ATTRIBUTE_MISSING:4023,HLS_REQUIRED_TAG_MISSING:4024,HLS_COULD_NOT_GUESS_CODECS:4025,HLS_KEYFORMATS_NOT_SUPPORTED:4026,DASH_UNSUPPORTED_XLINK_ACTUATE:4027,DASH_XLINK_DEPTH_LIMIT:4028,CONTENT_UNSUPPORTED_BY_BROWSER:4032,CANNOT_ADD_EXTERNAL_TEXT_TO_LIVE_STREAM:4033,NO_VARIANTS:4036,PERIOD_FLATTENING_FAILED:4037,INCONSISTENT_DRM_ACROSS_PERIODS:4038,HLS_VARIABLE_NOT_FOUND:4039,HLS_MSE_ENCRYPTED_MP2T_NOT_SUPPORTED:4040,HLS_MSE_ENCRYPTED_LEGACY_APPLE_MEDIA_KEYS_NOT_SUPPORTED:4041,NO_WEB_CRYPTO_API:4042,CANNOT_ADD_EXTERNAL_THUMBNAILS_TO_LIVE_STREAM:4045,MSS_INVALID_XML:4046,MSS_LIVE_CONTENT_NOT_SUPPORTED:4047,AES_128_INVALID_IV_LENGTH:4048,AES_128_INVALID_KEY_LENGTH:4049,DASH_CONFLICTING_AES_128:4050,DASH_UNSUPPORTED_AES_128:4051,DASH_INVALID_PATCH:4052,HLS_EMPTY_MEDIA_PLAYLIST:4053,DASH_MSE_ENCRYPTED_LEGACY_APPLE_MEDIA_KEYS_NOT_SUPPORTED:4054,STREAMING_ENGINE_STARTUP_INVALID_STATE:5006,NO_RECOGNIZED_KEY_SYSTEMS:6e3,REQUESTED_KEY_SYSTEM_CONFIG_UNAVAILABLE:6001,FAILED_TO_CREATE_CDM:6002,FAILED_TO_ATTACH_TO_VIDEO:6003,INVALID_SERVER_CERTIFICATE:6004,FAILED_TO_CREATE_SESSION:6005,FAILED_TO_GENERATE_LICENSE_REQUEST:6006,LICENSE_REQUEST_FAILED:6007,LICENSE_RESPONSE_REJECTED:6008,ENCRYPTED_CONTENT_WITHOUT_DRM_INFO:6010,NO_LICENSE_SERVER_GIVEN:6012,OFFLINE_SESSION_REMOVED:6013,EXPIRED:6014,SERVER_CERTIFICATE_REQUIRED:6015,INIT_DATA_TRANSFORM_ERROR:6016,SERVER_CERTIFICATE_REQUEST_FAILED:6017,MIN_HDCP_VERSION_NOT_MATCH:6018,ERROR_CHECKING_HDCP_VERSION:6019,LOAD_INTERRUPTED:7e3,OPERATION_ABORTED:7001,NO_VIDEO_ELEMENT:7002,OBJECT_DESTROYED:7003,CONTENT_NOT_LOADED:7004,SRC_EQUALS_PRELOAD_NOT_SUPPORTED:7005,CAST_API_UNAVAILABLE:8e3,NO_CAST_RECEIVERS:8001,ALREADY_CASTING:8002,UNEXPECTED_CAST_ERROR:8003,CAST_CANCELED_BY_USER:8004,CAST_CONNECTION_TIMED_OUT:8005,CAST_RECEIVER_APP_UNAVAILABLE:8006,STORAGE_NOT_SUPPORTED:9e3,INDEXED_DB_ERROR:9001,DEPRECATED_OPERATION_ABORTED:9002,REQUESTED_ITEM_NOT_FOUND:9003,MALFORMED_OFFLINE_URI:9004,CANNOT_STORE_LIVE_OFFLINE:9005,NO_INIT_DATA_FOR_OFFLINE:9007,LOCAL_PLAYER_INSTANCE_REQUIRED:9008,NEW_KEY_OPERATION_NOT_SUPPORTED:9011,KEY_NOT_FOUND:9012,MISSING_STORAGE_CELL:9013,STORAGE_LIMIT_REACHED:9014,DOWNLOAD_SIZE_CALLBACK_ERROR:9015,MODIFY_OPERATION_NOT_SUPPORTED:9016,INDEXED_DB_INIT_TIMED_OUT:9017,CS_IMA_SDK_MISSING:1e4,CS_AD_MANAGER_NOT_INITIALIZED:10001,SS_IMA_SDK_MISSING:10002,SS_AD_MANAGER_NOT_INITIALIZED:10003,CURRENT_DAI_REQUEST_NOT_FINISHED:10004,MT_AD_MANAGER_NOT_INITIALIZED:10005,INTERSTITIAL_AD_MANAGER_NOT_INITIALIZED:10006,VAST_INVALID_XML:10007},Ie.prototype.value=function(){return null==this.g&&(this.g=this.h()),this.g};var Oe=new Ie((function(){return fe(new Uint8Array([0]))})),Re=new Map;function Ne(e){this.h=e,this.g=null}function He(e){this.h=e,this.g=null}function Ue(){var t=e.ManagedMediaSource||e.MediaSource;return!(!t||!t.isTypeSupported)}function Fe(e){return""!=at().canPlayType(e)}function Be(){return!!navigator.userAgent.match(/Edge?\//)}function We(){return rt("Xbox One")}function ze(){return rt("Tizen")}function Ve(){return rt("Tizen 3")}function Ge(){return rt("Web0S")}function qe(){return rt("CrKey")}function $e(){if(!rt("Chrome")||navigator.userAgent.match(/Edge\//))return null;var e=navigator.userAgent.match(/Chrome\/(\d+)/);return e?parseInt(e[1],10):null}function Ke(){return!!navigator.vendor&&navigator.vendor.includes("Apple")&&!ze()&&!rt("PC=EOS")&&!rt("PC=APL")&&!rt("VirginMedia")&&!Ze()&&!Xe()&&!rt("AFT")&&!rt("WPE")&&!rt("DT_STB_BCM")&&!rt("Sky_STB")}function Je(){return rt("PlayStation 5")}function Xe(){return rt("PlayStation 4")}function Qe(){return rt("Hisense")||rt("VIDAA")}function Ze(){return rt("SOPOpenBrowser")}function et(){if(!Ke())return null;var e=navigator.userAgent.match(/Version\/(\d+)/);return e||(e=navigator.userAgent.match(/OS (\d+)(?:_\d+)?/))?parseInt(e[1],10):null}function tt(){return navigator.userAgentData&&navigator.userAgentData.platform?"windows"==navigator.userAgentData.platform.toLowerCase():!!navigator.platform&&navigator.platform.toLowerCase().includes("win32")}function nt(){return rt("Android")}function it(){return!!(ze()||Ge()||We()||Xe()||Je()||rt("AFT")||rt("PC=EOS")||rt("PC=APL")||rt("VirginMedia")||Ze()||rt("WPE")||qe()||Qe()||rt("DT_STB_BCM"))}function rt(e){return(navigator.userAgent||"").includes(e)}function at(){return dt||(ut||(ut=new He((function(){dt=null}))),(dt=document.getElementsByTagName("video")[0]||document.getElementsByTagName("audio")[0])||(dt=document.createElement("video")),ut.$(1),dt)}function st(t){return t?t===e.shakaMediaKeysPolyfill:!!e.shakaMediaKeysPolyfill}function ot(){var t,n,i,r,a,s,o,u,d,l,c,h,m;return I((function(f){switch(f.g){case 1:if(t={width:1/0,height:1/0},qe()){if(c=e.cast&&cast.__platform__&&cast.__platform__.canDisplayType,t.width=1280,t.height=720,b(f,14),!(h=c)){f.u(16);break}return M(f,cast.__platform__.canDisplayType('video/mp4; codecs="avc1.640028"; width=3840; height=2160'),17)}if(ze()){t.width=1920,t.height=1080;try{webapis.systeminfo&&webapis.systeminfo.getMaxVideoResolution?(n=webapis.systeminfo.getMaxVideoResolution(),t.width=n.width,t.height=n.height):webapis.productinfo.is8KPanelSupported&&webapis.productinfo.is8KPanelSupported()?(t.width=7680,t.height=4320):webapis.productinfo.isUdPanelSupported&&webapis.productinfo.isUdPanelSupported()&&(t.width=3840,t.height=2160)}catch(e){$("Tizen: Error detecting screen size, default screen size 1920x1080.")}f.u(3);break}if(Ge()){try{i=JSON.parse(e.PalmSystem.deviceInfo),t.width=Math.max(1920,i.screenWidth),t.height=Math.max(1080,i.screenHeight)}catch(e){$("WebOS: Error detecting screen size, default screen size 1920x1080."),t.width=1920,t.height=1080}f.u(3);break}if(Qe()){e.Hisense_Get4KSupportState&&e.Hisense_Get4KSupportState()?(t.width=3840,t.height=2160):(t.width=1920,t.height=1080),f.u(3);break}if(!Xe()&&!Je()){r=void 0;try{r="undefined"!=typeof Windows?Windows:chrome.webview.hostObjects.sync.Windows}catch(e){}if(r){t.width=1920,t.height=1080;try{a=new r.Media.Protection.ProtectionCapabilities,s=r.Media.Protection.ProtectionCapabilityResult,o=null;do{o=a.isTypeSupported('video/mp4;codecs="hvc1,mp4a";features="decode-res-x=3840,decode-res-y=2160,decode-bitrate=20000,decode-fps=30,decode-bpc=10,display-res-x=3840,display-res-y=2160,display-bpc=8"',"com.microsoft.playready.recommendation")}while(o===s.maybe);o===s.probably&&(t.width=3840,t.height=2160)}catch(e){$("Xbox: Error detecting screen size, default screen size 1920x1080.")}}else We()&&(t.width=1920,t.height=1080,$("Xbox: Error detecting screen size, default screen size 1920x1080."));f.u(3);break}return u=!1,b(f,8),M(f,e.msdk.device.getDisplayInfo(),10);case 10:d=f.h,u="4K"===d.resolution,L(f,9);break;case 8:return S(f),b(f,11),M(f,e.msdk.device.getDisplayInfoImmediate(),13);case 13:l=f.h,u="4K"===l.resolution,L(f,9);break;case 11:$("PlayStation: Failed to get the display info:",S(f));case 9:u?(t.width=3840,t.height=2160):(t.width=1920,t.height=1080),f.u(3);break;case 17:h=f.h;case 16:if(h){t.width=3840,t.height=2160,f.u(18);break}if(!(m=c)){f.u(19);break}return M(f,cast.__platform__.canDisplayType('video/mp4; codecs="avc1.640028"; width=1920; height=1080'),20);case 20:m=f.h;case 19:m&&(t.width=1920,t.height=1080);case 18:L(f,3);break;case 14:q("Failed to check canDisplayType:",S(f));case 3:return f.return(t)}}))}Ne.prototype.$=function(t){var n=this;this.stop();var i=!0,r=null;return this.g=function(){e.clearTimeout(r),i=!1},r=e.setTimeout((function(){i&&n.h()}),1e3*t),this},Ne.prototype.stop=function(){this.g&&(this.g(),this.g=null)},He.prototype.hc=function(){return this.stop(),this.h(),this},He.prototype.$=function(e){var t=this;return this.stop(),this.g=new Ne((function(){t.h()})).$(e),this},He.prototype.Ra=function(e){var t=this;return this.stop(),this.g=new Ne((function(){t.g.$(e),t.h()})).$(e),this},He.prototype.stop=function(){this.g&&(this.g.stop(),this.g=null)},U("shaka.util.Timer",He),He.prototype.stop=He.prototype.stop,He.prototype.tickEvery=He.prototype.Ra,He.prototype.tickAfter=He.prototype.$,He.prototype.tickNow=He.prototype.hc;var ut=null,dt=null;function lt(){}function ct(t){if(!t)return"";if(239==(t=pe(t))[0]&&187==t[1]&&191==t[2]&&(t=t.subarray(3)),e.TextDecoder&&!Xe())return(t=(new TextDecoder).decode(t)).includes("�")&&q('Decoded string contains an "unknown character" codepoint. That probably means the UTF8 encoding was incorrect!'),t;for(var n="",i=0;i<t.length;++i){var r=65533;if(128&t[i]?t.length>=i+2&&192==(224&t[i])&&128==(192&t[i+1])?(r=(31&t[i])<<6|63&t[i+1],i+=1):t.length>=i+3&&224==(240&t[i])&&128==(192&t[i+1])&&128==(192&t[i+2])?(r=(15&t[i])<<12|(63&t[i+1])<<6|63&t[i+2],i+=2):t.length>=i+4&&240==(241&t[i])&&128==(192&t[i+1])&&128==(192&t[i+2])&&128==(192&t[i+3])&&(r=(7&t[i])<<18|(63&t[i+1])<<12|(63&t[i+2])<<6|63&t[i+3],i+=3):r=t[i],65535>=r)n+=String.fromCharCode(r);else{var a=1023&(r-=65536);n+=String.fromCharCode(55296+(r>>10)),n+=String.fromCharCode(56320+a)}}return n}function ht(e,t,n){if(!e)return"";if(!n&&0!=e.byteLength%2)throw new Ye(2,2,2004);n=Math.floor(e.byteLength/2);var i=new Uint16Array(n);e=ye(e);for(var r=0;r<n;r++)i[r]=e.getUint16(2*r,t);return gt(i)}function mt(e){function t(e){return n.byteLength<=e||32<=n[e]&&126>=n[e]}if(!e)return"";var n=pe(e);if(239==n[0]&&187==n[1]&&191==n[2])return ct(n);if(254==n[0]&&255==n[1])return ht(n.subarray(2),!1);if(255==n[0]&&254==n[1])return ht(n.subarray(2),!0);if(0==n[0]&&0==n[2])return ht(e,!1);if(0==n[1]&&0==n[3])return ht(e,!0);if(t(0)&&t(1)&&t(2)&&t(3))return ct(e);throw new Ye(2,2,2003)}function ft(t){if(e.TextEncoder&&!Xe()){var n=new TextEncoder;return fe(n.encode(t))}t=encodeURIComponent(t),t=unescape(t),n=new Uint8Array(t.length);for(var i=0;i<t.length;i++)n[i]=t[i].charCodeAt(0);return fe(n)}function pt(e,t){for(var n=new ArrayBuffer(2*e.length),i=new DataView(n),r=0;r<e.length;++r)i.setUint16(2*r,e.charCodeAt(r),t);return n}function gt(e){return _t.value()(e)}function yt(e){var t={"&":"&","<":"<",">":">",""":'"',"'":"'"," ":" ","‎":"","‏":""},n=/&(?:amp|lt|gt|quot|apos|nbsp|lrm|rlm|#[xX]?[0-9a-fA-F]+);/g,i=RegExp(n.source);return e&&i.test(e)?e.replace(n,(function(e){return"#"==e[1]?0<=(e="x"==e[2]||"X"==e[2]?parseInt(e.substring(3),16):parseInt(e.substring(2),10))&&1114111>=e?String.fromCodePoint(e):"":t[e]||"'"})):e||""}U("shaka.util.StringUtils",lt),lt.resetFromCharCode=function(){_t.g=void 0},lt.toUTF16=pt,lt.toUTF8=ft,lt.fromBytesAutoDetect=mt,lt.fromUTF16=ht,lt.fromUTF8=ct;var _t=new Ie((function(){function e(e){try{var t=new Uint8Array(e);return 0<String.fromCharCode.apply(null,t).length}catch(e){return!1}}for(var t={fc:65536};0<t.fc;(t={fc:t.fc}).fc/=2)if(e(t.fc))return function(e){return function(t){for(var n="",i=0;i<t.length;i+=e.fc)n+=String.fromCharCode.apply(null,t.subarray(i,i+e.fc));return n}}(t);return null}));function vt(e){this.h=e||"",this.g=0}function Mt(e){wt(e,/[ \t]+/gm)}function wt(e,t){return t.lastIndex=e.g,t=null==(t=t.exec(e.h))?null:{position:t.index,length:t[0].length,results:t},e.g==e.h.length||null==t||t.position!=e.g?null:(e.g+=t.length,t.results)}function bt(e){return e.g==e.h.length?null:(e=wt(e,/[^ \t\n]*/gm))?e[0]:null}function Tt(e){if(null==(e=wt(e,St)))return null;var t=Number(e[2]),n=Number(e[3]);return 59<t||59<n?null:(Number(e[6])||0)/1e3+n+60*t+3600*(Number(e[1])||0)}function Lt(e){return e?Tt(new vt(e)):null}var St=/(?:(\d{1,}):)?(\d{2}):(\d{2})((\.(\d{1,3})))?/g;function kt(e){var t=new WeakSet;return function e(n){switch(typeof n){case"undefined":case"boolean":case"number":case"string":case"symbol":case"function":return n;default:if(!n||ArrayBuffer.isView(n))return n;if(t.has(n))return null;var i=n.constructor==Array;if(n.constructor!=Object&&!i)return null;t.add(n);var r,a=i?[]:{};for(r in n)a[r]=e(n[r]);return i&&(a.length=n.length),a}}(e)}function Dt(e){var t,n={};for(t in e)n[t]=e[t];return n}function xt(e){if(Array.isArray(e)){for(var t=[],n=0;n<e.length;n++){var i=n.toString(),r=e[n];void 0!==r&&(r=xt(r))&&t.push(i+":"+r)}e="["+t.join(",")+"]"}else if("function"==typeof e)e="";else if(e instanceof Object){for((n=Object.keys(e)).sort(),t=[],i=(n=d(n)).next();!i.done;i=n.next())r=i.value,i=JSON.stringify(r),void 0!==(r=e[r])&&(r=xt(r))&&t.push(i+":"+r);e="{"+t.join(",")+"}"}else e=JSON.stringify(e);return e}function At(e,t){var n=void 0!==n&&n;return Yt(e=mt(e),t,n)}function Yt(e,t,n){return e=function(e,t){function n(){for(var t=i;-1==="\r\n\t>/= ".indexOf(e[i])&&e[i];)i++;return e.slice(t,i)}var i=0;return function r(a,s){s=void 0!==s&&s;for(var o=[];e[i];)if(60==e.charCodeAt(i)){if(47===e.charCodeAt(i+1)){s=i+2,i=e.indexOf(">",i);var u=(s=e.substring(s,i)).indexOf(a);if(-1==u){var d=a.indexOf(".");0<d&&(u=s.indexOf(a.substring(0,d)))}if(-1==u)throw a=e.substring(0,i).split("\n"),Error("Unexpected close tag\nLine: "+(a.length-1)+"\nColumn: "+(a[a.length-1].length+1)+"\nChar: "+e[i]);i+1&&(i+=1);break}if(33===e.charCodeAt(i+1)){if(45==e.charCodeAt(i+2)){for(;-1!==i&&(62!==e.charCodeAt(i)||45!=e.charCodeAt(i-1)||45!=e.charCodeAt(i-2)||-1==i);)i=e.indexOf(">",i+1);-1===i&&(i=e.length)}else if(91===e.charCodeAt(i+2)&&91===e.charCodeAt(i+8)&&"cdata"===e.substr(i+3,5).toLowerCase()){-1==(u=e.indexOf("]]>",i))?(o.push(e.substr(i+9)),i=e.length):(o.push(e.substring(i+9,u)),i=u+3);continue}i++;continue}e:{d=s,i++;var c=n(),h={};for(u=[];62!==e.charCodeAt(i)&&e[i];){var m=e.charCodeAt(i);if(64<m&&91>m||96<m&&123>m){m=n();for(var f=e.charCodeAt(i);f&&39!==f&&34!==f&&!(64<f&&91>f||96<f&&123>f)&&62!==f;)i++,f=e.charCodeAt(i);var p=i+1;if(i=e.indexOf(e[i],p),p=e.slice(p,i),39===f||34===f){if(-1===i){if(d={tagName:c,attributes:h,children:u,parent:null},t)for(c=0;c<u.length;c++)"string"!=typeof u[c]&&(u[c].parent=d);u=d;break e}}else p=null,i--;if(m.startsWith("xmlns:")){f=p;var g=m.split(":")[1];sn.set(f,g),on.set(g,f)}"tt"===c&&"xml:space"===m&&"preserve"===p&&(d=!0),h[m]=p}i++}for(47!==e.charCodeAt(i-1)?(i++,u=r(c,d)):i++,d={tagName:c,attributes:h,children:u,parent:null},c=u.length,h=0;h<c;h++)"string"!=typeof(m=u[h])?t&&(m.parent=d):h==c-1&&"\n"==m&&u.pop();u=d}if(o.push(u),"string"==typeof u)break;"?"===u.tagName[0]&&u.children&&(o.push.apply(o,l(u.children)),u.children=[])}else u=i,-2==(i=e.indexOf("<",i)-1)&&(i=e.length),u=e.slice(u,i+1),s?0<u.length&&o.push(u):(o.length&&1==u.length&&"\n"==u[0]||0<u.trim().length)&&o.push(u),i++;return o}("")}(e,void 0!==n&&n),!t&&e.length?e[0]:(e=e.find((function(e){return t.split(",").includes(e.tagName)})))?e:null}function Et(e){return sn.has(e)?sn.get(e):""}function It(e){return"string"==typeof e}function Pt(e){var t=[];if(!e.children)return[];for(var n=(e=d(e.children)).next();!n.done;n=e.next())"string"!=typeof(n=n.value)&&t.push(n);return t}function Ct(e,t){var n=[];if(!e.children)return[];for(var i=(e=d(e.children)).next();!i.done;i=e.next())(i=i.value).tagName===t&&n.push(i);return n}function jt(e){return"string"==typeof e?yt(e):""===(e=e.children.reduce((function(e,t){return"string"==typeof t?e+t:e}),""))?null:yt(e)}function Ot(e){return Array.from(e.children).every((function(e){return"string"==typeof e}))?((e=jt(e))&&(e=e.trim()),e):null}function Rt(e,t,n){if(n=void 0===n?[]:n,e.tagName===t&&n.push(e),e.children)for(var i=(e=d(e.children)).next();!i.done;i=e.next())Rt(i.value,t,n);return n}function Nt(e,t){return 1!=(e=Ct(e,t)).length?null:e[0]}function Ht(e,t,n){return 1!=(e=Bt(e,t,n)).length?null:e[0]}function Ut(e,t,n,i){i=void 0===i?null:i;var r=null;return null!=(e=e.attributes[t])&&(r=n(e)),null==r?i:r}function Ft(e,t,n){return t=Et(t),e.attributes[t+":"+n]||null}function Bt(e,t,n){t=Et(t);var i=[];if(e.children)for(var r=(e=d(e.children)).next();!r.done;r=e.next())(r=r.value)&&r.tagName===t+":"+n&&i.push(r);return i}function Wt(e,t,n){for(var i=(t=d(t)).next();!i.done;i=t.next())if(i=Ft(e,i.value,n))return i;return null}function zt(e){return e?(/^\d+-\d+-\d+T\d+:\d+:\d+(\.\d+)?$/.test(e)&&(e+="Z"),e=Date.parse(e),isNaN(e)?null:e/1e3):null}function Vt(e){return e&&(e=RegExp("^P(?:([0-9]*)Y)?(?:([0-9]*)M)?(?:([0-9]*)D)?(?:T(?:([0-9]*)H)?(?:([0-9]*)M)?(?:([0-9.]*)S)?)?$").exec(e))?(e=31536e3*Number(e[1]||null)+2592e3*Number(e[2]||null)+86400*Number(e[3]||null)+3600*Number(e[4]||null)+60*Number(e[5]||null)+Number(e[6]||null),isFinite(e)?e:null):null}function Gt(e){var t=/([0-9]+)-([0-9]+)/.exec(e);return t?(e=Number(t[1]),isFinite(e)?(t=Number(t[2]),isFinite(t)?{start:e,end:t}:null):null):null}function qt(e){return 0==(e=Number(e))%1?e:null}function $t(e){return 0==(e=Number(e))%1&&0<e?e:null}function Kt(e){return 0==(e=Number(e))%1&&0<=e?e:null}function Jt(e){return e=Number(e),isNaN(e)?null:e}function Xt(e){return!!e&&"true"===e.toLowerCase()}function Qt(e){var t,n=(t=e.match(/^(\d+)\/(\d+)$/))?Number(t[1])/Number(t[2]):Number(e);return isNaN(n)?null:n}function Zt(e){for(var t=[],n=(e=d(e=yt(e).split(/\/+(?=(?:[^'"]*['"][^'"]*['"])*[^'"]*$)/))).next();!n.done;n=e.next()){var i=(n=n.value).match(/^([\w]+)/);if(i){var r=n.match(/(@id='(.*?)')/),a=n.match(/(@t='(\d+)')/),s=n.match(/(@n='(\d+)')/),o=n.match(/\[(\d+)\]/);t.push({name:i[0],id:r?r[0].match(/'(.*?)'/)[0].replace(/'/gm,""):null,t:a?Number(a[0].match(/'(.*?)'/)[0].replace(/'/gm,"")):null,n:s?Number(s[0].match(/'(.*?)'/)[0].replace(/'/gm,"")):null,position:o?Number(o[1])-1:null,Ub:n.split("/@")[1]||null})}else n.startsWith("@")&&t.length&&(t[t.length-1].Ub=n.slice(1))}return t}function en(e,t){var n=Zt(t.attributes.sel||"");if(n.length){var i=n[n.length-1],r=t.attributes.pos||null;null==(n=i.position)&&(null!==i.t&&(n=tn(e,"t",i.t)),null!==i.n&&(n=tn(e,"n",i.n))),null===n?n="prepend"===r?0:e.length:"prepend"===r?--n:"after"===r&&++n,r=t.tagName,(i=i.Ub)&&e[n]?nn(e[n],r,i,Ot(t)||""):("remove"!==r&&"replace"!==r||e.splice(n,1),"add"!==r&&"replace"!==r||e.splice.apply(e,[n,0].concat(l(t.children))))}}function tn(e,t,n){for(var i=0,r=(e=d(e)).next();!r.done;r=e.next()){if(Number(r.value.attributes[t])===n)return i;i++}return null}function nn(e,t,n,i){"remove"===t?delete e.attributes[n]:"add"!==t&&"replace"!==t||(e.attributes[n]=i)}function rn(e){var t="",n=e.tagName.split(":");for(var i in 0<n.length&&(t=n[0],t=on.has(t)?on.get(t):""),t=document.createElementNS(t,e.tagName),e.attributes)t.setAttribute(i,e.attributes[i]);for(i=(e=d(e.children)).next();!i.done;i=e.next())n=void 0,n="string"==typeof(i=i.value)?new Text(i):rn(i),t.appendChild(n);return t}function an(e){if(!e)return null;for(var t={tagName:e.tagName,attributes:Dt(e.attributes),children:[],parent:null},n=(e=d(e.children)).next();!n.done;n=e.next())"string"==typeof(n=n.value)||((n=an(n)).parent=t),t.children.push(n);return t}var sn=new Map,on=new Map;function un(e,t,n){this.startTime=e,this.endTime=t,this.payload=n,this.region=new Te,this.position=null,this.positionAlign=pn,this.size=0,this.textAlign=gn,this.direction=Mn,this.writingMode=wn,this.lineInterpretation=bn,this.line=null,this.lineHeight="",this.lineAlign=Tn,this.displayAlign=_n,this.fontSize=this.border=this.backgroundImage=this.backgroundColor=this.color="",this.fontWeight=Dn,this.fontStyle=An,this.linePadding=this.letterSpacing=this.fontFamily="",this.opacity=1,this.textCombineUpright="",this.textDecoration=[],this.textStrokeWidth=this.textStrokeColor=this.textShadow="",this.wrapLine=!0,this.id="",this.nestedCues=[],this.lineBreak=this.isContainer=!1,this.rubyTag=null,this.cellResolution={lc:32,rows:15}}function dn(e,t){return(e=new un(e,t,"")).lineBreak=!0,e}function ln(e,t){if(e.startTime!=t.startTime||e.endTime!=t.endTime||e.payload!=t.payload)return!1;for(var n in e)if("startTime"!=n&&"endTime"!=n&&"payload"!=n)if("nestedCues"==n){if(!Ae(e.nestedCues,t.nestedCues,ln))return!1}else if("region"==n||"cellResolution"==n){for(var i in e[n])if(e[n][i]!=t[n][i])return!1}else if(Array.isArray(e[n])){if(!Ae(e[n],t[n]))return!1}else if(e[n]!=t[n])return!1;return!0}function cn(e,t){t=void 0===t?new Map:t;var n=e.payload;if(n.includes("<")){0===t.size&&hn(t);var i=n;n=[];for(var r=-1,a=0;a<i.length;a++)"<"===i[a]?r=a+1:">"===i[a]&&0<r&&((r=i.substr(r,a-r)).match(Pn)&&n.push(r),r=-1);for(a=(n=d(n)).next();!a.done;a=n.next())a=a.value,i=i.replace("<"+a+">",'<div time="'+a+'">'),i+="</div>";e:{a=i,r=[];var s=-1;n="",i=!1;for(var o=0;o<a.length;o++)if("/"===a[o]){var u=a.indexOf(">",o);if(-1===u){n=a;break e}if((u=a.substring(o+1,u))&&"v"==u){i=!0;var l=null;if(r.length&&(l=r[r.length-1]),l){if(l===u)n+="/"+u+">";else{if(!l.startsWith("v")){n+=a[o];continue}n+="/"+l+">"}o+=u.length+1}else n+=a[o]}else n+=a[o]}else"<"===a[o]?"v"!=a[s=o+1]&&(s=-1):">"===a[o]&&0<s&&(r.push(a.substr(s,o-s)),s=-1),n+=a[o];for(r=(a=d(r)).next();!r.done;r=a.next())s=(r=r.value).replace(" ",".voice-"),n=(n=n.replace("<"+r+">","<"+s+">")).replace("</"+r+">","</"+s+">"),i||(n+="</"+s+">")}n=function(e){var t={"< ":""," >":" >"},n=/(< +>|<\s|\s>)/g,i=RegExp(n.source);return e&&i.test(e)?e.replace(n,(function(e){return t[e]||""})):e||""}(n),e.payload="";try{var c=Yt("<span>"+n+"</span>","span")}catch(e){}if(c)if(1!=(c=c.children).length||c[0].tagName)for(n=(c=d(c)).next();!n.done;n=c.next())mn(n.value,e,t);else e.payload=yt(n);else e.payload=yt(n)}else e.payload=yt(n)}function hn(e){for(var t=d(Object.entries(Sn)),n=t.next();!n.done;n=t.next()){var i=d(n.value);n=i.next().value,i=i.next().value;var r=new un(0,0,"");r.color=i,e.set("."+n,r)}for(n=(t=d(Object.entries(kn))).next();!n.done;n=t.next())n=(i=d(n.value)).next().value,i=i.next().value,(r=new un(0,0,"")).backgroundColor=i,e.set("."+n,r)}function mn(e,t,n){var i=t.clone();if(i.nestedCues=[],i.payload="",i.rubyTag="",i.line=null,i.region=new Te,i.position=null,i.size=0,i.textAlign=gn,e.tagName)for(var r=d(e.tagName.split(/(?=[ .])+/g)),a=r.next();!a.done;a=r.next()){var s=a=a.value;if(s.startsWith(".voice-")){var o=s.split("-").pop();s='v[voice="'+o+'"]',n.has(s)||(s="v[voice="+o+"]")}switch(n.has(s)&&(o=i,s=n.get(s))&&(o.backgroundColor=fn(s.backgroundColor,o.backgroundColor),o.color=fn(s.color,o.color),o.fontFamily=fn(s.fontFamily,o.fontFamily),o.fontSize=fn(s.fontSize,o.fontSize),o.textShadow=fn(s.textShadow,o.textShadow),o.fontWeight=s.fontWeight,o.fontStyle=s.fontStyle,o.opacity=s.opacity,o.rubyTag=s.rubyTag,o.textCombineUpright=s.textCombineUpright,o.wrapLine=s.wrapLine),a){case"br":return i=dn(i.startTime,i.endTime),void t.nestedCues.push(i);case"b":i.fontWeight=xn;break;case"i":i.fontStyle=Yn;break;case"u":i.textDecoration.push(In);break;case"font":(a=e.attributes.color)&&(i.color=a);break;case"div":if(!(a=e.attributes.time))break;(a=Lt(a))&&(i.startTime=a);break;case"ruby":case"rp":case"rt":i.rubyTag=a}}if(r=e.children,It(e)||1==r.length&&It(r[0]))for(n=jt(e).split("\n"),e=!0,r=(n=d(n)).next();!r.done;r=n.next())r=r.value,e||(e=dn(i.startTime,i.endTime),t.nestedCues.push(e)),0<r.length&&((e=i.clone()).payload=yt(r),t.nestedCues.push(e)),e=!1;else for(t.nestedCues.push(i),e=(t=d(r)).next();!e.done;e=t.next())mn(e.value,i,n)}function fn(e,t){return e&&0<e.length?e:t}un.prototype.clone=function(){var e,t=new un(0,0,"");for(e in this)t[e]=this[e],t[e]&&t[e].constructor==Array&&(t[e]=t[e].slice());return t},U("shaka.text.Cue",un),un.parseCuePayload=cn,un.equal=ln,un.prototype.clone=un.prototype.clone;var pn="auto";un.positionAlign={LEFT:"line-left",RIGHT:"line-right",CENTER:"center",AUTO:pn};var gn="center",yn={LEFT:"left",RIGHT:"right",CENTER:gn,START:"start",END:"end"};un.textAlign=yn;var _n="after",vn={BEFORE:"before",CENTER:"center",AFTER:_n};un.displayAlign=vn;var Mn="ltr";un.direction={HORIZONTAL_LEFT_TO_RIGHT:Mn,HORIZONTAL_RIGHT_TO_LEFT:"rtl"};var wn="horizontal-tb";un.writingMode={HORIZONTAL_TOP_TO_BOTTOM:wn,VERTICAL_LEFT_TO_RIGHT:"vertical-lr",VERTICAL_RIGHT_TO_LEFT:"vertical-rl"};var bn=0;un.lineInterpretation={LINE_NUMBER:bn,PERCENTAGE:1};var Tn="start",Ln={CENTER:"center",START:Tn,END:"end"};un.lineAlign=Ln;var Sn={white:"white",lime:"lime",cyan:"cyan",red:"red",yellow:"yellow",magenta:"magenta",blue:"blue",black:"black"};un.defaultTextColor=Sn;var kn={bg_white:"white",bg_lime:"lime",bg_cyan:"cyan",bg_red:"red",bg_yellow:"yellow",bg_magenta:"magenta",bg_blue:"blue",bg_black:"black"};un.defaultTextBackgroundColor=kn;var Dn=400,xn=700;un.fontWeight={NORMAL:Dn,BOLD:xn};var An="normal",Yn="italic",En={NORMAL:An,ITALIC:Yn,OBLIQUE:"oblique"};un.fontStyle=En;var In="underline";un.textDecoration={UNDERLINE:In,LINE_THROUGH:"lineThrough",OVERLINE:"overline"};var Pn=/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g;function Cn(){}function jn(e,t,n){Rn[e.toLowerCase().split(";")[0]+"-"+n]={priority:n,he:t}}function On(e,t){for(var n=e.toLowerCase().split(";")[0],i=d([Fn,Un,Hn,Nn]),r=i.next();!r.done;r=i.next())if(r=Rn[n+"-"+r.value]){var a=r.he(),s=a.isSupported(e,t);if(a.destroy(),s)return r.he}return null}Cn.prototype.destroy=function(){},U("shaka.transmuxer.TransmuxerEngine",Cn),Cn.findTransmuxer=On,Cn.unregisterTransmuxer=function(e,t){delete Rn[e.toLowerCase().split(";")[0]+"-"+t]},Cn.registerTransmuxer=jn,Cn.prototype.destroy=Cn.prototype.destroy;var Rn={},Nn=1,Hn=2,Un=3,Fn=4;Cn.PluginPriority={FALLBACK:Nn,PREFERRED_SECONDARY:Hn,PREFERRED:Un,APPLICATION:Fn};var Bn=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^/?#]*)@)?([^/#?]*?)(?::([0-9]+))?(?=[/#?]|$))?([^?#]+)?(?:\\?([^#]*))?(?:#(.*))?$");function Wn(e){var t;e instanceof Wn?(zn(this,e.Db),this.Cc=e.Cc,Vn(this,e.Fb),Gn(this,e.Uc),this.Ua=e.Ua,qn(this,e.g.clone()),this.mc=e.mc):e&&(t=String(e).match(Bn))?(zn(this,t[1]||"",!0),this.Cc=$n(t[2]||""),Vn(this,t[3]||"",!0),Gn(this,t[4]),this.Ua=$n(t[5]||"",!0),qn(this,t[6]||"",!0),this.mc=$n(t[7]||"")):this.g=new ni(null)}function zn(e,t,n){e.Db=n?$n(t,!0):t,e.Db&&(e.Db=e.Db.replace(/:$/,""))}function Vn(e,t,n){e.Fb=n?$n(t,!0):t}function Gn(e,t){if(t){if(t=Number(t),isNaN(t)||0>t)throw Error("Bad port number "+t);e.Uc=t}else e.Uc=null}function qn(e,t,n){t instanceof ni?e.g=t:(n||(t=Kn(t,ei)),e.g=new ni(t))}function $n(e,t){return e?t?decodeURI(e):decodeURIComponent(e):""}function Kn(e,t,n){return null!=e?(e=encodeURI(e).replace(t,Jn),n&&(e=e.replace(/%25([0-9a-fA-F]{2})/g,"%$1")),e):null}function Jn(e){return"%"+((e=e.charCodeAt(0))>>4&15).toString(16)+(15&e).toString(16)}(i=Wn.prototype).Db="",i.Cc="",i.Fb="",i.Uc=null,i.Ua="",i.mc="",i.toString=function(){var e=[],t=this.Db;if(t&&e.push(Kn(t,Xn,!0),":"),t=this.Fb){e.push("//");var n=this.Cc;n&&e.push(Kn(n,Xn,!0),"@"),e.push(encodeURIComponent(t).replace(/%25([0-9a-fA-F]{2})/g,"%$1")),null!=(t=this.Uc)&&e.push(":",String(t))}return(t=this.Ua)&&(this.Fb&&"/"!=t.charAt(0)&&e.push("/"),e.push(Kn(t,"/"==t.charAt(0)?Zn:Qn,!0))),(t=this.g.toString())&&e.push("?",t),(t=this.mc)&&e.push("#",Kn(t,ti)),e.join("")},i.resolve=function(e){var t=this.clone();"data"===t.Db&&(t=new Wn);var n=!!e.Db;n?zn(t,e.Db):n=!!e.Cc,n?t.Cc=e.Cc:n=!!e.Fb,n?Vn(t,e.Fb):n=null!=e.Uc;var i=e.Ua;if(n)Gn(t,e.Uc);else if(n=!!e.Ua){if("/"!=i.charAt(0))if(this.Fb&&!this.Ua)i="/"+i;else{var r=t.Ua.lastIndexOf("/");-1!=r&&(i=t.Ua.substr(0,r+1)+i)}if(".."==i||"."==i)i="";else if(-1!=i.indexOf("./")||-1!=i.indexOf("/.")){r=0==i.lastIndexOf("/",0),i=i.split("/");for(var a=[],s=0;s<i.length;){var o=i[s++];"."==o?r&&s==i.length&&a.push(""):".."==o?((1<a.length||1==a.length&&""!=a[0])&&a.pop(),r&&s==i.length&&a.push("")):(a.push(o),r=!0)}i=a.join("/")}}return n?t.Ua=i:n=""!==e.g.toString(),n?qn(t,e.g.clone()):n=!!e.mc,n&&(t.mc=e.mc),t},i.clone=function(){return new Wn(this)};var Xn=/[#\/\?@]/g,Qn=/[#\?:]/g,Zn=/[#\?]/g,ei=/[#\?@]/g,ti=/#/g;function ni(e){this.g=e||null}function ii(e){if(!e.Pa&&(e.Pa={},e.dd=0,e.g))for(var t=e.g.split("&"),n=0;n<t.length;n++){var i=t[n].indexOf("="),r=null;if(0<=i){var a=t[n].substring(0,i);r=t[n].substring(i+1)}else a=t[n];a=decodeURIComponent(a.replace(/\+/g," ")),r=r||"",e.add(a,decodeURIComponent(r.replace(/\+/g," ")))}}function ri(e){return ii(e),e.dd}function ai(){}function si(e){return e=gt(pe(e)),btoa(e)}function oi(e,t){return t=null==t||t,e=si(e).replace(/\+/g,"-").replace(/\//g,"_"),t?e:e.replace(/[=]*$/,"")}function ui(t){t=e.atob(t.replace(/-/g,"+").replace(/_/g,"/"));for(var n=new Uint8Array(t.length),i=0;i<t.length;++i)n[i]=t.charCodeAt(i);return n}function di(t){for(var n=t.length/2,i=new Uint8Array(n),r=0;r<n;r++)i[r]=e.parseInt(t.substr(2*r,2),16);return i}function li(e){var t=pe(e);e="";for(var n=(t=d(t)).next();!n.done;n=t.next())1==(n=(n=n.value).toString(16)).length&&(n="0"+n),e+=n;return e}function ci(){for(var e=P.apply(0,arguments),t=0,n=0;n<e.length;++n)t+=e[n].byteLength;t=new Uint8Array(t);for(var i=n=0;i<e.length;++i){var r=e[i];ArrayBuffer.isView(r)&&1===r.BYTES_PER_ELEMENT?t.set(r,n):t.set(pe(r),n),n+=r.byteLength}return t}function hi(e,t,n){if(n=void 0===n?"":n,0==t.length)return e;if(1==e.length&&1==t.length){var i=new Wn(e[0]);return t=new Wn(t[0]),t=i.resolve(t),n&&qn(t,n),[t.toString()]}t=t.map((function(e){return new Wn(e)})),i=[];for(var r=(e=d(e)).next();!r.done;r=e.next()){r=new Wn(r.value);for(var a=d(t),s=a.next();!s.done;s=a.next())s=r.resolve(s.value),n&&qn(s,n),i.push(s.toString())}return i}function mi(e,t,n,i){return e={keySystem:e,encryptionScheme:t,licenseServerUri:"",distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,serverCertificateUri:"",sessionType:"",initData:n||[],keyIds:new Set},i&&(e.keySystemUris=new Set([i])),e}function fi(t,n){n=void 0===n?"cenc":n;var i=[],r=[],a=[];t.forEach((function(e,t){var n=t;22!=n.length&&(n=oi(di(t),!1));var s=e;22!=s.length&&(s=oi(di(e),!1)),e={kty:"oct",kid:n,k:s},i.push(e),r.push(e.kid),a.push(t)})),t=JSON.stringify({keys:i});var s=JSON.stringify({kids:r});return s=[{initData:pe(ft(s)),initDataType:"keyids"}],{keySystem:"org.w3.clearkey",encryptionScheme:n,licenseServerUri:"data:application/json;base64,"+e.btoa(t),distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,serverCertificateUri:"",sessionType:"",initData:s,keyIds:new Set(a)}}function pi(e,t){if(1==t.length)return t[0];if(null!=(e=gi(e,t)))return e;throw new Ye(2,4,4025,t)}function gi(e,t){for(var n=d(wi[e]),i=n.next();!i.done;i=n.next()){i=i.value;for(var r=d(t),a=r.next();!a.done;a=r.next())if(a=a.value,i.test(a.trim()))return a.trim()}return e==_i?"":null}function yi(e,t){for(var n=[],i=(e=d(wi[e])).next();!i.done;i=e.next()){i=i.value;for(var r=d(t),a=r.next();!a.done;a=r.next())a=a.value,i.test(a.trim())&&n.push(a.trim())}return n}(i=ni.prototype).Pa=null,i.dd=null,i.add=function(e,t){ii(this),this.g=null;var n=this.Pa.hasOwnProperty(e)?this.Pa[e]:null;return n||(this.Pa[e]=n=[]),n.push(t),this.dd++,this},i.set=function(e,t){return ii(this),this.g=null,this.Pa.hasOwnProperty(e)?this.Pa[e]=[t]:this.add(e,t),this},i.get=function(e){return ii(this),this.Pa[e]||[]},i.toString=function(){if(this.g)return this.g;if(!this.Pa)return"";var e,t=[];for(e in this.Pa)for(var n=encodeURIComponent(e),i=this.Pa[e],r=0;r<i.length;r++){var a=n;""!==i[r]&&(a+="="+encodeURIComponent(i[r])),t.push(a)}return this.g=t.join("&")},i.clone=function(){var e=new ni;if(e.g=this.g,this.Pa){var t,n={};for(t in this.Pa)n[t]=this.Pa[t].concat();e.Pa=n,e.dd=this.dd}return e},U("shaka.util.Uint8ArrayUtils",ai),ai.concat=ci,ai.toHex=li,ai.fromHex=di,ai.fromBase64=ui,ai.toBase64=oi,ai.toStandardBase64=si;var _i="text",vi={la:"video",V:"audio",wa:_i,He:"image",kj:"application"},Mi=1/15,wi={audio:[/^vorbis$/,/^Opus$/,/^opus$/,/^fLaC$/,/^flac$/,/^mp4a/,/^[ae]c-3$/,/^ac-4/,/^dts[cex]$/,/^iamf/,/^mhm[12]/],video:[/^avc/,/^hev/,/^hvc/,/^vvc/,/^vvi/,/^vp0?[89]/,/^av01/,/^dvh/,/^dva/,/^dav/],text:[/^vtt$/,/^wvtt/,/^stpp/]};function bi(){}function Ti(e,t){var n=e;return t&&!ji.includes(e)&&(n+='; codecs="'+t+'"'),n}function Li(e,t){return t&&(e+='; codecs="'+t+'"'),e}function Si(e,t,n){var i=Ti(e,t);return On(t=Li(e,t))?(e=On(t))?(n=(e=e()).convertCodecs(n,t),e.destroy()):n=t:n="video/mp2t"!=e&&"audio"==n?i.replace("video","audio"):i,n}function ki(e,t,n){var i=[t];return Ci.forEach((function(t,r){var a=e[r];"codecs"==r?ji.includes(e.mimeType)||i.push('codecs="'+n+'"'):a&&i.push(t+'="'+a+'"')})),"PQ"==e.hdr&&i.push('eotf="smpte2084"'),i.join(";")}function Di(e){return e.split(";")[0].split("/")[1]}function xi(e){var t=Pi(e);switch(e=t[0],t=t[1].toLowerCase(),!0){case"mp4a"===e&&"69"===t:case"mp4a"===e&&"6b"===t:case"mp4a"===e&&"40.34"===t:return"mp3";case"mp4a"===e&&"66"===t:case"mp4a"===e&&"67"===t:case"mp4a"===e&&"68"===t:case"mp4a"===e&&"40.2"===t:case"mp4a"===e&&"40.02"===t:case"mp4a"===e&&"40.5"===t:case"mp4a"===e&&"40.05"===t:case"mp4a"===e&&"40.29"===t:case"mp4a"===e&&"40.42"===t:return"aac";case"mp4a"===e&&"a5"===t:return"ac-3";case"mp4a"===e&&"a6"===t:return"ec-3";case"mp4a"===e&&"b2"===t:return"dtsx";case"mp4a"===e&&"a9"===t:return"dtsc";case"vp09"===e:return"vp9";case"avc1"===e:case"avc3"===e:return"avc";case"hvc1"===e:case"hev1"===e:return"hevc";case"vvc1"===e:case"vvi1"===e:return"vvc";case"dvh1"===e:case"dvhe"===e:return t&&t.startsWith("05")?"dovi-p5":"dovi-hevc";case"dvav"===e:case"dva1"===e:return"dovi-avc";case"dav1"===e:return"dovi-av1";case"dvc1"===e:case"dvi1"===e:return"dovi-vvc"}return e}function Ai(e){for(var t=[],n=(e=d(e.split(","))).next();!n.done;n=e.next())n=Pi(n.value),t.push(n[0]);return t.sort().join(",")}function Yi(e){return e.split(";")[0]}function Ei(e){return(e=e.split(/ *; */)).shift(),(e=e.find((function(e){return e.startsWith("codecs=")})))?e.split("=")[1].replace(/^"|"$/g,""):""}function Ii(e){return"application/x-mpegurl"===e||"application/vnd.apple.mpegurl"===e}function Pi(e){var t=(e=e.split("."))[0];return e.shift(),[t,e.join(".")]}U("shaka.util.MimeUtils",bi),bi.getFullTypeWithAllCodecs=Li,bi.getFullType=Ti;var Ci=(new Map).set("codecs","codecs").set("frameRate","framerate").set("bandwidth","bitrate").set("width","width").set("height","height").set("channelsCount","channels"),ji=["audio/aac","audio/ac3","audio/ec3","audio/mpeg"];function Oi(e){this.i=null,this.j=e,this.B=!1,this.l=this.s=0,this.m=1/0,this.h=this.g=null,this.C="",this.A=function(){},this.o=new Map}function Ri(e){return!!Ui[e]||("application/cea-608"==e||"application/cea-708"==e)&&!!be}function Ni(e,t,n){if(e.C=t,t=e.o.get(t))for(var i=d(t.keys()),r=i.next();!r.done;r=i.next())(r=t.get(r.value).filter((function(e){return e.endTime<=n})))&&e.j.append(r)}function Hi(e,t,n){t.startTime+=n,t.endTime+=n;for(var i=(t=d(t.nestedCues)).next();!i.done;i=t.next())Hi(e,i.value,n)}Oi.prototype.destroy=function(){return this.j=this.i=null,this.o.clear(),Promise.resolve()},Oi.prototype.remove=function(e,t){var n=this;return I((function(i){if(1==i.g)return M(i,Promise.resolve(),2);!n.j||!n.j.remove(e,t)||null==n.g||t<=n.g||e>=n.h||(e<=n.g&&t>=n.h?n.g=n.h=null:e<=n.g&&t<n.h?n.g=t:e>n.g&&t>=n.h&&(n.h=e)),w(i)}))},U("shaka.text.TextEngine",Oi),Oi.prototype.destroy=Oi.prototype.destroy,Oi.findParser=function(e){return Ui[e]},Oi.unregisterParser=function(e){delete Ui[e]},Oi.registerParser=function(e,t){Ui[e]=t};var Ui={};function Fi(e,t){return e.concat(t)}function Bi(){}function Wi(e){return null!=e}function zi(e,t){return Promise.race([t,new Promise((function(t,n){new He(n).$(e)}))])}function Vi(){}function Gi(e,t){return e=Ki(e),t=Ki(t),e.split("-")[0]==t.split("-")[0]}function qi(e,t){return e=Ki(e),t=Ki(t),e=e.split("-"),t=t.split("-"),e[0]==t[0]&&1==e.length&&2==t.length}function $i(e,t){return e=Ki(e),t=Ki(t),e=e.split("-"),t=t.split("-"),2==e.length&&2==t.length&&e[0]==t[0]}function Ki(e){var t=(e=d(e.split("-x-"))).next().value;t=void 0===t?"":t,e=void 0===(e=e.next().value)?"":e;var n=d(t.split("-"));return t=void 0===(t=n.next().value)?"":t,n=void 0===(n=n.next().value)?"":n,e=e?"x-"+e:"",t=t.toLowerCase(),t=er.get(t)||t,((n=n.toUpperCase())?t+"-"+n:t)+(e?"-"+e:"")}function Ji(e,t){return e=Ki(e),(t=Ki(t))==e?4:qi(t,e)?3:$i(t,e)?2:qi(e,t)?1:0}function Xi(e){var t=e.indexOf("-");return e=(e=0<=t?e.substring(0,t):e).toLowerCase(),er.get(e)||e}function Qi(e){return e.language?Ki(e.language):e.audio&&e.audio.language?Ki(e.audio.language):e.video&&e.video.language?Ki(e.video.language):"und"}function Zi(e,t){e=Ki(e);for(var n=new Set,i=(t=d(t)).next();!i.done;i=t.next())n.add(Ki(i.value));for(i=(t=d(n)).next();!i.done;i=t.next())if((i=i.value)==e)return i;for(i=(t=d(n)).next();!i.done;i=t.next())if(qi(i=i.value,e))return i;for(i=(t=d(n)).next();!i.done;i=t.next())if($i(i=i.value,e))return i;for(t=(n=d(n)).next();!t.done;t=n.next())if(qi(e,t=t.value))return t;return null}U("shaka.util.LanguageUtils",Vi),Vi.findClosestLocale=Zi,Vi.getLocaleForVariant=Qi,Vi.getLocaleForText=function(e){return Ki(e.language||"und")},Vi.getBase=Xi,Vi.relatedness=Ji,Vi.areSiblings=function(e,t){var n=Xi(e),i=Xi(t);return e!=n&&t!=i&&n==i},Vi.normalize=Ki,Vi.isSiblingOf=$i,Vi.isParentOf=qi,Vi.areLanguageCompatible=Gi,Vi.areLocaleCompatible=function(e,t){return(e=Ki(e))==Ki(t)};var er=new Map([["aar","aa"],["abk","ab"],["afr","af"],["aka","ak"],["alb","sq"],["amh","am"],["ara","ar"],["arg","an"],["arm","hy"],["asm","as"],["ava","av"],["ave","ae"],["aym","ay"],["aze","az"],["bak","ba"],["bam","bm"],["baq","eu"],["bel","be"],["ben","bn"],["bih","bh"],["bis","bi"],["bod","bo"],["bos","bs"],["bre","br"],["bul","bg"],["bur","my"],["cat","ca"],["ces","cs"],["cha","ch"],["che","ce"],["chi","zh"],["chu","cu"],["chv","cv"],["cor","kw"],["cos","co"],["cre","cr"],["cym","cy"],["cze","cs"],["dan","da"],["deu","de"],["div","dv"],["dut","nl"],["dzo","dz"],["ell","el"],["eng","en"],["epo","eo"],["est","et"],["eus","eu"],["ewe","ee"],["fao","fo"],["fas","fa"],["fij","fj"],["fin","fi"],["fra","fr"],["fre","fr"],["fry","fy"],["ful","ff"],["geo","ka"],["ger","de"],["gla","gd"],["gle","ga"],["glg","gl"],["glv","gv"],["gre","el"],["grn","gn"],["guj","gu"],["hat","ht"],["hau","ha"],["heb","he"],["her","hz"],["hin","hi"],["hmo","ho"],["hrv","hr"],["hun","hu"],["hye","hy"],["ibo","ig"],["ice","is"],["ido","io"],["iii","ii"],["iku","iu"],["ile","ie"],["ina","ia"],["ind","id"],["ipk","ik"],["isl","is"],["ita","it"],["jav","jv"],["jpn","ja"],["kal","kl"],["kan","kn"],["kas","ks"],["kat","ka"],["kau","kr"],["kaz","kk"],["khm","km"],["kik","ki"],["kin","rw"],["kir","ky"],["kom","kv"],["kon","kg"],["kor","ko"],["kua","kj"],["kur","ku"],["lao","lo"],["lat","la"],["lav","lv"],["lim","li"],["lin","ln"],["lit","lt"],["ltz","lb"],["lub","lu"],["lug","lg"],["mac","mk"],["mah","mh"],["mal","ml"],["mao","mi"],["mar","mr"],["may","ms"],["mkd","mk"],["mlg","mg"],["mlt","mt"],["mon","mn"],["mri","mi"],["msa","ms"],["mya","my"],["nau","na"],["nav","nv"],["nbl","nr"],["nde","nd"],["ndo","ng"],["nep","ne"],["nld","nl"],["nno","nn"],["nob","nb"],["nor","no"],["nya","ny"],["oci","oc"],["oji","oj"],["ori","or"],["orm","om"],["oss","os"],["pan","pa"],["per","fa"],["pli","pi"],["pol","pl"],["por","pt"],["pus","ps"],["que","qu"],["roh","rm"],["ron","ro"],["rum","ro"],["run","rn"],["rus","ru"],["sag","sg"],["san","sa"],["sin","si"],["slk","sk"],["slo","sk"],["slv","sl"],["sme","se"],["smo","sm"],["sna","sn"],["snd","sd"],["som","so"],["sot","st"],["spa","es"],["sqi","sq"],["srd","sc"],["srp","sr"],["ssw","ss"],["sun","su"],["swa","sw"],["swe","sv"],["tah","ty"],["tam","ta"],["tat","tt"],["tel","te"],["tgk","tg"],["tgl","tl"],["tha","th"],["tib","bo"],["tir","ti"],["ton","to"],["tsn","tn"],["tso","ts"],["tuk","tk"],["tur","tr"],["twi","tw"],["uig","ug"],["ukr","uk"],["urd","ur"],["uzb","uz"],["ven","ve"],["vie","vi"],["vol","vo"],["wel","cy"],["wln","wa"],["wol","wo"],["xho","xh"],["yid","yi"],["yor","yo"],["zha","za"],["zho","zh"],["zul","zu"]]);function tr(){}function nr(e,t,n,i,r){if(r.length){for(var a=e.textStreams,s=(r=d(r)).next(),o={};!s.done;o={$f:void 0},s=r.next())if(o.$f=s.value,(s=a.filter(function(e){return function(t){return!(!t.codecs.startsWith(e.$f)&&!t.mimeType.startsWith(e.$f))}}(o))).length){a=s;break}e.textStreams=a}if(a=e.variants,(t.length||n.length)&&(a=function(e,t,n){for(var i=(t=d(t)).next(),r={};!i.done;r={rh:void 0},i=t.next())if(r.rh=i.value,i=e.filter(function(e){return function(t){return t.video&&t.video.codecs.startsWith(e.rh)}}(r)),i.length){e=i;break}for(t=(n=d(n)).next(),i={};!t.done;i={kg:void 0},t=n.next())if(i.kg=t.value,t=e.filter(function(e){return function(t){return t.audio&&t.audio.codecs.startsWith(e.kg)}}(i)),t.length){e=t;break}return e}(a,t,n)),i.length){for(t=new Q,a=(n=d(a)).next();!a.done;a=n.next())a=a.value,t.push(String(a.video.width||0),a);var u=[];t.forEach((function(e,t){e=0;for(var n=[],r=(t=d(t)).next(),a={};!r.done;a={Be:void 0},r=t.next())a.Be=r.value,(r=i.filter(function(e){return function(t){return e.Be.decodingInfos[0][t]}}(a)).length)>e?(e=r,n=[a.Be]):r==e&&n.push(a.Be);u.push.apply(u,l(n))})),a=u}for(n=new Set,t=new Set,r=(a=d(a)).next();!r.done;r=a.next())(r=r.value).audio&&n.add(r.audio),r.video&&t.add(r.video);a=Array.from(n).sort((function(e,t){return e.bandwidth-t.bandwidth}));var c=[];for(n=new Map,r=(a=d(a)).next();!r.done;r=a.next()){if(s=(r=r.value).language+(r.channelsCount||0)+(r.audioSamplingRate||0)+r.roles.join(",")+r.label+r.groupId+r.fastSwitching,(o=n.get(s)||[]).length){var h=o[o.length-1],m=xi(h.codecs),f=xi(r.codecs);m!=f||r.bandwidth&&h.bandwidth&&!(r.bandwidth>h.bandwidth)||(o.push(r),c.push(r.id))}else o.push(r),c.push(r.id);n.set(s,o)}var p={vp8:1,avc:1,"dovi-avc":.95,vp9:.9,vp09:.9,hevc:.85,"dovi-hevc":.8,"dovi-p5":.75,av01:.7,"dovi-av1":.65,vvc:.6};a=Array.from(t).sort((function(e,t){if(!e.bandwidth||!t.bandwidth||e.bandwidth==t.bandwidth){if(e.codecs&&t.codecs&&e.codecs!=t.codecs&&e.width==t.width){var n=xi(e.codecs),i=xi(t.codecs);if(n!=i)return(p[n]||1)-(p[i]||1)}return e.width-t.width}return e.bandwidth-t.bandwidth})),t=ie();var g=[];for(n=new Map,r=(a=d(a)).next();!r.done;r=a.next()){if(r=r.value,s=Math.round(r.frameRate||0)+(r.hdr||"")+r.fastSwitching,(o=n.get(s)||[]).length){if(h=o[o.length-1],!t&&(m=xi(h.codecs))!==(f=xi(r.codecs)))continue;r.width>h.width||r.height>h.height?(o.push(r),g.push(r.id)):r.width==h.width&&r.height==h.height&&((m=xi(h.codecs))!=(f=xi(r.codecs))||r.bandwidth&&h.bandwidth&&!(r.bandwidth>h.bandwidth)||(o.push(r),g.push(r.id)))}else o.push(r),g.push(r.id);n.set(s,o)}e.variants=e.variants.filter((function(e){var t=e.audio;return e=e.video,!(t&&!c.includes(t.id)||e&&!g.includes(e.id))}))}function ir(e,t,n){function i(e,t,n){return e>=t&&e<=n}var r=e.video;if(r&&r.width&&r.height){var a=r.width,s=r.height;if(s>a&&(a=(s=d([s,a])).next().value,s=s.next().value),!i(a,t.minWidth,Math.min(t.maxWidth,n.width))||!i(s,t.minHeight,Math.min(t.maxHeight,n.height))||!i(r.width*r.height,t.minPixels,t.maxPixels))return!1}return!(e&&e.video&&e.video.frameRate&&!i(e.video.frameRate,t.minFrameRate,t.maxFrameRate)||e&&e.audio&&e.audio.channelsCount&&!i(e.audio.channelsCount,t.minChannelsCount,t.maxChannelsCount)||!i(e.bandwidth,t.minBandwidth,t.maxBandwidth))}function rr(e,t,n,i,r){var a,s;return I((function(o){if(1==o.g)return We()&&function(e){for(var t={dvav:"avc3",dva1:"avc1",dvhe:"hev1",dvh1:"hvc1",dvc1:"vvc1",dvi1:"vvi1"},n=new Set,i=(e=d(e)).next();!i.done;i=e.next())(i=i.value).video&&n.add(i.video);for(e=(n=d(n)).next();!e.done;e=n.next()){e=e.value;for(var r=(i=d(Object.keys(t))).next();!r.done;r=i.next())if(r=r.value,e.codecs.includes(r)){e.codecs=e.codecs.replace(r,t[r]);break}}}(t.variants),M(o,or(t.variants,n,!1,i),2);a=null,e&&(s=e.g)&&(a=s.keySystem),t.variants=t.variants.filter((function(e){var t=function(e,t,n){if(!e.decodingInfos.some((function(e){return!(!e.supported||t&&(e=e.keySystemAccess)&&(n[e.keySystem]||e.keySystem)!=t)})))return!1;var i=We(),r=rt("Firefox")&&nt(),a=e.video,s=a&&a.width||0,o=a&&a.height||0;if(i&&a&&(1920<s||1080<o)&&(a.codecs.includes("avc1.")||a.codecs.includes("avc3.")))return!1;if(a){if(i=lr(a.codecs),a.codecs.includes(",")){if(i=lr(i=pi("video",s=a.codecs.split(","))),s=dr(s=pi("audio",s),a.mimeType),!ne(o=Si(a.mimeType,s,"audio")))return!1;i=[i,s].join()}if(a.codecs!=i){if(!ne(s=Si(a.mimeType,i,"video")))return!1;a.codecs=i}}if(e=e.audio,r&&e&&e.encrypted&&e.codecs.toLowerCase().includes("opus"))return!1;if(e&&(r=dr(e.codecs,e.mimeType),e.codecs!=r)){if(!ne(a=Si(e.mimeType,r,"audio")))return!1;e.codecs=r}return!0}(e,a,r);if(!t){var n=[];e.audio&&n.push(Tr(e.audio)),e.video&&n.push(Tr(e.video))}return t})),w(o)}))}function ar(e,t){var n,i,r,a,s,o,u;return I((function(l){if(1==l.g){for(n=function(e,t){if(e){var n=Dt(e);return n.supported=e.supported&&t.supported,n.powerEfficient=e.powerEfficient&&t.powerEfficient,n.smooth=e.smooth&&t.smooth,t.keySystemAccess&&!n.keySystemAccess&&(n.keySystemAccess=t.keySystemAccess),n}return t},i=null,r=[],a=d(t),s=a.next(),o={};!s.done;o={cache:void 0,Gd:void 0},s=a.next())u=s.value,o.Gd=xt(u),o.cache=Lr,o.cache[o.Gd]?i=n(i,o.cache[o.Gd]):r.push(sr(u).then(function(e){return function(t){for(var r=null,a=(t=d(t||[])).next();!a.done;a=t.next())r=n(r,a.value);r&&(e.cache[e.Gd]=r,i=n(i,r))}}(o)));return M(l,Promise.all(r),2)}i&&e.decodingInfos.push(i),w(l)}))}function sr(e){var t=[""];e.video&&(t=Ei(e.video.contentType).split(","));var n=[""];e.audio&&(n=Ei(e.audio.contentType).split(","));for(var i=[],r=(t=d(t)).next();!r.done;r=t.next()){r=r.value;for(var a=d(n),s=a.next(),o={};!s.done;o={Fc:void 0},s=a.next())s=s.value,o.Fc=kt(e),e.video&&(o.Fc.video.contentType=Ti(Yi(o.Fc.video.contentType),r)),e.audio&&(o.Fc.audio.contentType=Ti(Yi(o.Fc.audio.contentType),s)),i.push(new Promise(function(e){return function(t,n){zi(1,navigator.mediaCapabilities.decodingInfo(e.Fc)).then((function(e){t(e)})).catch(n)}}(o)))}return Promise.all(i).catch((function(){return JSON.stringify(e),null}))}function or(e,t,n,i){var r,a,s,o,u,l,c,h,m,f,p,g,y,_,v,w,b,T;return I((function(L){switch(L.g){case 1:if(e.some((function(e){return e.decodingInfos.length})))return L.return();r=d(i),a=r.next(),s={};case 2:if(a.done){L.u(4);break}s.Tg=a.value,o=!1,u=d(e),l=u.next();case 5:if(l.done){L.u(7);break}c=l.value,h=ur(c,t,n).filter((S=s,function(e){return((e=e[0]).keySystemConfiguration&&e.keySystemConfiguration.keySystem)===S.Tg})),m=d(h),f=m.next();case 8:if(f.done){L.u(10);break}return p=f.value,M(L,ar(c,p),9);case 9:f=m.next(),L.u(8);break;case 10:c.decodingInfos.length&&(o=!0),l=u.next(),L.u(5);break;case 7:if(o)return L.return();s={Tg:void 0},a=r.next(),L.u(2);break;case 4:g=d(e),y=g.next();case 12:if(y.done){L.u(0);break}_=y.value,v=ur(_,t,n).filter((function(e){return!(e=(e=e[0]).keySystemConfiguration&&e.keySystemConfiguration.keySystem)||!i.includes(e)})),w=d(v),b=w.next();case 15:if(b.done){y=g.next(),L.u(12);break}return T=b.value,M(L,ar(_,T),16);case 16:b=w.next(),L.u(15)}var S}))}function ur(e,t,n){var i=e.audio,r=e.video,a=[],s=[];if(r)for(var o=d(r.fullMimeTypes),u=o.next();!u.done;u=o.next()){var l=Ei(u=u.value);if(l.includes(",")&&!i){var c=l.split(","),h=Yi(u);l=pi("video",c),h=Si(h,c=dr(c=pi("audio",c),h),"audio"),s.push({contentType:h,channels:2,bitrate:e.bandwidth||1,samplerate:1,spatialRendering:!1})}if(l=lr(l),u={contentType:Si(Yi(u),l,"video"),width:r.width||64,height:r.height||64,bitrate:r.bandwidth||e.bandwidth||1,framerate:r.frameRate||1},r.hdr)switch(r.hdr){case"SDR":u.transferFunction="srgb";break;case"PQ":u.transferFunction="pq";break;case"HLG":u.transferFunction="hlg"}r.colorGamut&&(u.colorGamut=r.colorGamut),a.push(u)}if(i)for(u=(o=d(i.fullMimeTypes)).next();!u.done;u=o.next())u=Si(u=Yi(l=u.value),l=dr(Ei(l),u),"audio"),s.push({contentType:u,channels:i.channelsCount||2,bitrate:i.bandwidth||e.bandwidth||1,samplerate:i.audioSamplingRate||1,spatialRendering:i.spatialAudio});for(o=[],0==a.length&&a.push(null),0==s.length&&s.push(null),u=(a=d(a)).next();!u.done;u=a.next())for(u=u.value,h=(l=d(s)).next();!h.done;h=l.next())h=h.value,c={type:n?"file":"media-source"},u&&(c.video=u),h&&(c.audio=h),o.push(c);if(!(s=(e.video?e.video.drmInfos:[]).concat(e.audio?e.audio.drmInfos:[])).length)return[o];for(e=[],n=new Map,a=(s=d(s)).next();!a.done;a=s.next())a=a.value,n.get(a.keySystem)||n.set(a.keySystem,[]),n.get(a.keySystem).push(a);for(s=t?"required":"optional",t=t?["persistent-license"]:["temporary"],u=(a=d(n.keys())).next();!u.done;u=a.next()){for(u=u.value,l=[],c=(h=d(o)).next();!c.done;c=h.next()){c=Object.assign({},c.value);for(var m=n.get(u),f={keySystem:u,initDataType:"cenc",persistentState:s,distinctiveIdentifier:"optional",sessionTypes:t},p=(m=d(m)).next();!p.done;p=m.next()){if((p=p.value).initData&&p.initData.length){for(var g=new Set,y=d(p.initData),_=y.next();!_.done;_=y.next())g.add(_.value.initDataType);f.initDataType=p.initData[0].initDataType}p.distinctiveIdentifierRequired&&(f.distinctiveIdentifier="required"),p.persistentStateRequired&&(f.persistentState="required"),p.sessionType&&(f.sessionTypes=[p.sessionType]),i&&(f.audio?(p.encryptionScheme&&(f.audio.encryptionScheme=f.audio.encryptionScheme||p.encryptionScheme),f.audio.robustness=f.audio.robustness||p.audioRobustness):(f.audio={robustness:p.audioRobustness},p.encryptionScheme&&(f.audio.encryptionScheme=p.encryptionScheme)),""==f.audio.robustness&&delete f.audio.robustness),r&&(f.video?(p.encryptionScheme&&(f.video.encryptionScheme=f.video.encryptionScheme||p.encryptionScheme),f.video.robustness=f.video.robustness||p.videoRobustness):(f.video={robustness:p.videoRobustness},p.encryptionScheme&&(f.video.encryptionScheme=p.encryptionScheme)),""==f.video.robustness&&delete f.video.robustness)}c.keySystemConfiguration=f,l.push(c)}e.push(l)}return e}function dr(e,t){return"flac"==e.toLowerCase()?et()?"fLaC":"flac":"opus"===e.toLowerCase()?et()&&"mp4"==Di(t)?"Opus":"opus":e}function lr(e){if(e.includes("avc1")){var t=e.split(".");if(3==t.length)return e=t.shift()+".",(e+=parseInt(t.shift(),10).toString(16))+("000"+parseInt(t.shift(),10).toString(16)).slice(-4)}else if("vp9"==e)return"vp09.00.41.08";return e}function cr(e){var t=e.audio,n=e.video,i=t?t.mimeType:null,r=n?n.mimeType:null,a=t?t.codecs:null,s=n?n.codecs:null,o=[];s&&o.push(s),a&&o.push(a);var u=[];n&&u.push(n.mimeType),t&&u.push(t.mimeType),u=u[0]||null;var l=[];t&&l.push(t.kind),n&&l.push(n.kind),l=l[0]||null;var c=new Set;if(t)for(var h=d(t.roles),m=h.next();!m.done;m=h.next())c.add(m.value);if(n)for(m=(h=d(n.roles)).next();!m.done;m=h.next())c.add(m.value);return e={id:e.id,active:!1,type:"variant",bandwidth:e.bandwidth,language:e.language,label:null,kind:l,width:null,height:null,frameRate:null,pixelAspectRatio:null,hdr:null,colorGamut:null,videoLayout:null,mimeType:u,audioMimeType:i,videoMimeType:r,codecs:o.join(", "),audioCodec:a,videoCodec:s,primary:e.primary,roles:Array.from(c),audioRoles:null,forced:!1,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,originalTextId:null,originalImageId:null,accessibilityPurpose:null,originalLanguage:null},n&&(e.videoId=n.id,e.originalVideoId=n.originalId,e.width=n.width||null,e.height=n.height||null,e.frameRate=n.frameRate||null,e.pixelAspectRatio=n.pixelAspectRatio||null,e.videoBandwidth=n.bandwidth||null,e.hdr=n.hdr||null,e.colorGamut=n.colorGamut||null,e.videoLayout=n.videoLayout||null,s.includes(",")&&(e.channelsCount=n.channelsCount,e.audioSamplingRate=n.audioSamplingRate,e.spatialAudio=n.spatialAudio,e.originalLanguage=n.originalLanguage)),t&&(e.audioId=t.id,e.originalAudioId=t.originalId,e.channelsCount=t.channelsCount,e.audioSamplingRate=t.audioSamplingRate,e.audioBandwidth=t.bandwidth||null,e.spatialAudio=t.spatialAudio,e.label=t.label,e.audioRoles=t.roles,e.accessibilityPurpose=t.accessibilityPurpose,e.originalLanguage=t.originalLanguage),e}function hr(e){return{id:e.id,active:!1,type:_i,bandwidth:0,language:e.language,label:e.label,kind:e.kind||null,width:null,height:null,frameRate:null,pixelAspectRatio:null,hdr:null,colorGamut:null,videoLayout:null,mimeType:e.mimeType,audioMimeType:null,videoMimeType:null,codecs:e.codecs||null,audioCodec:null,videoCodec:null,primary:e.primary,roles:e.roles,audioRoles:null,forced:e.forced,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,originalTextId:e.originalId,originalImageId:null,accessibilityPurpose:e.accessibilityPurpose,originalLanguage:e.originalLanguage}}function mr(e){var t=e.width||null,n=e.height||null,i=null;e.segmentIndex&&(i=eu(e.segmentIndex));var r=e.tilesLayout;return i&&(r=i.tilesLayout||r),r&&null!=t&&(t/=Number(r.split("x")[0])),r&&null!=n&&(n/=Number(r.split("x")[1])),{id:e.id,active:!1,type:"image",bandwidth:e.bandwidth||0,language:"",label:null,kind:null,width:t,height:n,frameRate:null,pixelAspectRatio:null,hdr:null,colorGamut:null,videoLayout:null,mimeType:e.mimeType,audioMimeType:null,videoMimeType:null,codecs:e.codecs||null,audioCodec:null,videoCodec:null,primary:!1,roles:[],audioRoles:null,forced:!1,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:r||null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,originalTextId:null,originalImageId:e.originalId,accessibilityPurpose:null,originalLanguage:null}}function fr(e){return e.__shaka_id||(e.__shaka_id=Sr++),e.__shaka_id}function pr(e){var t=yr(e);return t.active="disabled"!=e.mode,t.type="text",t.originalTextId=e.id,"captions"==e.kind&&(t.mimeType="unknown"),"subtitles"==e.kind&&(t.mimeType="text/vtt"),e.kind&&(t.roles=[e.kind]),"forced"==e.kind&&(t.forced=!0),t}function gr(e){var t=yr(e);return t.active=e.enabled,t.type="variant",t.originalAudioId=e.id,"main"==e.kind&&(t.primary=!0),e.kind&&(t.roles=[e.kind],t.audioRoles=[e.kind],t.label=e.label),t}function yr(e){var t=e.language;return{id:fr(e),active:!1,type:"",bandwidth:0,language:Ki(t||"und"),label:e.label,kind:e.kind,width:null,height:null,frameRate:null,pixelAspectRatio:null,hdr:null,colorGamut:null,videoLayout:null,mimeType:null,audioMimeType:null,videoMimeType:null,codecs:null,audioCodec:null,videoCodec:null,primary:!1,roles:[],forced:!1,audioRoles:null,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,originalTextId:null,originalImageId:null,accessibilityPurpose:null,originalLanguage:t}}function _r(e){return e.allowedByApplication&&e.allowedByKeySystem&&0==e.disabledUntilTime}function vr(e){return e.filter((function(e){return _r(e)}))}function Mr(e,t,n,i){var r=e,a=e.filter((function(e){return e.primary}));a.length&&(r=a);var s=r.length?r[0].language:"";if(r=r.filter((function(e){return e.language==s})),t){var o=Zi(Ki(t),e.map((function(e){return e.language})));o&&(r=e.filter((function(e){return Ki(e.language)==o})))}if(r=r.filter((function(e){return e.forced==i})),n){if((e=wr(r,n)).length)return e}else if(e=r.filter((function(e){return 0==e.roles.length})),e.length)return e;return e=r.map((function(e){return e.roles})).reduce(Fi,[]),e.length?wr(r,e[0]):r}function wr(e,t){return e.filter((function(e){return e.roles.includes(t)}))}function br(e,t){t.length&&(t=t.filter((function(t){return xi(e.codecs)==xi(t.codecs)})).sort((function(e,t){return e.bandwidth&&t.bandwidth&&e.bandwidth!=t.bandwidth?e.bandwidth-t.bandwidth:(e.width||0)-(t.width||0)})),e.trickModeVideo=t[0],1<t.length&&(t=t.find((function(t){return e.width==t.width&&e.height==t.height}))))&&(e.trickModeVideo=t)}function Tr(e){return"audio"==e.type?"type=audio codecs="+e.codecs+" bandwidth="+e.bandwidth+" channelsCount="+e.channelsCount+" audioSamplingRate="+e.audioSamplingRate:"video"==e.type?"type=video codecs="+e.codecs+" bandwidth="+e.bandwidth+" frameRate="+e.frameRate+" width="+e.width+" height="+e.height:"unexpected stream type"}U("shaka.util.StreamUtils",tr),tr.meetsRestrictions=ir;var Lr={},Sr=0,kr=(new Map).set("image/svg+xml",!0).set("image/png",!0).set("image/jpeg",!0).set("image/jpg",!0),Dr=(new Map).set("image/webp","data:image/webp;base64,UklGRjoAAABXRUJQVlA4IC4AAACyAgCdASoCAAIALmk0mk0iIiIiIgBoSygABc6WWgAA/veff/0PP8bA//LwYAAA").set("image/avif","data:image/avif;base64,AAAAIGZ0eXBhdmlmAAAAAGF2aWZtaWYxbWlhZk1BMUIAAADybWV0YQAAAAAAAAAoaGRscgAAAAAAAAAAcGljdAAAAAAAAAAAAAAAAGxpYmF2aWYAAAAADnBpdG0AAAAAAAEAAAAeaWxvYwAAAABEAAABAAEAAAABAAABGgAAAB0AAAAoaWluZgAAAAAAAQAAABppbmZlAgAAAAABAABhdjAxQ29sb3IAAAAAamlwcnAAAABLaXBjbwAAABRpc3BlAAAAAAAAAAIAAAACAAAAEHBpeGkAAAAAAwgICAAAAAxhdjFDgQ0MAAAAABNjb2xybmNseAACAAIAAYAAAAAXaXBtYQAAAAAAAAABAAEEAQKDBAAAACVtZGF0EgAKCBgANogQEAwgMg8f8D///8WfhwB8+ErK42A=");function xr(){var e=this;this.A=null,this.j=!1,this.i=new V,this.F=new Z,navigator.connection&&navigator.connection.addEventListener&&this.F.D(navigator.connection,"change",(function(){if(e.j&&e.g.useNetworkInformation){e.i=new V,e.g&&e.i.configure(e.g.advanced);var t=e.chooseVariant();t&&navigator.onLine&&e.A(t,e.g.clearBufferSwitch,e.g.safeMarginSwitch)}})),this.s=[],this.B=1,this.G=!1,this.h=this.o=this.g=this.l=null,this.C=new He((function(){if(e.j&&e.g.restrictToElementSize){var t=e.chooseVariant();t&&e.A(t,e.g.clearBufferSwitch,e.g.safeMarginSwitch)}})),this.m=null}function Ar(e){if(!e.G){var t=e.i;if(!(t.g>=t.i))return;e.G=!0,e.l-=1e3*(e.g.switchInterval-e.g.minTimeToSwitch)}Date.now()-e.l<1e3*e.g.switchInterval||(t=e.chooseVariant(),e.getBandwidthEstimate(),t&&e.A(t,e.g.clearBufferSwitch,e.g.safeMarginSwitch))}function Yr(e,t,n,i,r){if(e.m){var a=e.m.Cg();a&&(n=n.filter((function(e){return!e.bandwidth||!a||e.bandwidth<=a})))}return t&&(n=n.filter((function(e){return ir(e,t,{width:r,height:i})}))),n.sort((function(e,t){return e.bandwidth-t.bandwidth}))}(i=xr.prototype).stop=function(){this.A=null,this.j=!1,this.s=[],this.B=1,this.o=this.l=null,this.h&&(this.h.disconnect(),this.h=null),this.C.stop(),this.m=null},i.release=function(){this.F.release(),this.C=null},i.init=function(e){this.A=e},i.chooseVariant=function(){var t=1/0,n=1/0;if(this.g.restrictToScreenSize){var i=this.g.ignoreDevicePixelRatio?1:e.devicePixelRatio;t=e.screen.height*i,n=e.screen.width*i}this.h&&this.g.restrictToElementSize&&(i=this.g.ignoreDevicePixelRatio?1:e.devicePixelRatio,t=Math.min(t,this.o.clientHeight*i),n=Math.min(n,this.o.clientWidth*i)),(i=this.s.filter((function(e){return e&&!(e.audio&&e.audio.fastSwitching||e.video&&e.video.fastSwitching)}))).length||(i=this.s);var r=i;if(i.length!=this.s.length&&(r=this.s.filter((function(e){return e&&!!(e.audio&&e.audio.fastSwitching||e.video&&e.video.fastSwitching)}))),i=Yr(this,this.g.restrictions,r,1/0,1/0),1/0!=t||1/0!=n){i=function(e){for(var t=[],n=(e=d(e)).next();!n.done;n=e.next())(n=n.value.video)&&n.height&&n.width&&t.push({height:n.height,width:n.width});return t.sort((function(e,t){return e.width-t.width}))}(i);for(var a=(i=d(i)).next();!a.done;a=i.next())if((a=a.value).height>=t&&a.width>=n){t=a.height,n=a.width;break}i=Yr(this,this.g.restrictions,r,t,n)}for(t=this.getBandwidthEstimate(),r.length&&!i.length&&(i=[(i=Yr(this,null,r,1/0,1/0))[0]]),n=i[0]||null,r=0;r<i.length;r++){a=i[r];for(var s=isNaN(this.B)?1:Math.abs(this.B),o=s*a.bandwidth/this.g.bandwidthDowngradeTarget,u={bandwidth:1/0},l=r+1;l<i.length;l++)if(a.bandwidth!=i[l].bandwidth){u=i[l];break}s=s*u.bandwidth/this.g.bandwidthUpgradeTarget,t>=o&&t<=s&&(n.bandwidth!=a.bandwidth||n.bandwidth==a.bandwidth&&n.video&&a.video&&(n.video.width<a.video.width||n.video.height<a.video.height))&&(n=a)}return this.l=Date.now(),n},i.enable=function(){this.j=!0},i.disable=function(){this.j=!1},i.segmentDownloaded=function(e,t,n){e<this.g.cacheLoadThreshold||(this.i.sample(e,t),n&&null!=this.l&&this.j&&Ar(this))},i.trySuggestStreams=function(){null!=this.l&&this.j&&Ar(this)},i.getBandwidthEstimate=function(){var e=this.g.defaultBandwidthEstimate;return navigator.connection&&navigator.connection.downlink&&this.g.useNetworkInformation&&(e=1e6*navigator.connection.downlink),navigator.connection&&navigator.connection.downlink&&this.g.useNetworkInformation&&this.g.preferNetworkInformationBandwidth?e:(e=this.i.getBandwidthEstimate(e),this.m?this.m.getBandwidthEstimate(e):e)},i.setVariants=function(e){this.s=e},i.playbackRateChanged=function(e){this.B=e},i.setMediaElement=function(t){var n=this;this.o=t,this.h&&(this.h.disconnect(),this.h=null),this.o&&"ResizeObserver"in e&&(this.h=new ResizeObserver((function(){n.C.$(Er)})),this.h.observe(this.o))},i.setCmsdManager=function(e){this.m=e},i.configure=function(e){this.g=e,this.i&&this.g&&this.i.configure(this.g.advanced)},U("shaka.abr.SimpleAbrManager",xr),xr.prototype.configure=xr.prototype.configure,xr.prototype.setCmsdManager=xr.prototype.setCmsdManager,xr.prototype.setMediaElement=xr.prototype.setMediaElement,xr.prototype.playbackRateChanged=xr.prototype.playbackRateChanged,xr.prototype.setVariants=xr.prototype.setVariants,xr.prototype.getBandwidthEstimate=xr.prototype.getBandwidthEstimate,xr.prototype.trySuggestStreams=xr.prototype.trySuggestStreams,xr.prototype.segmentDownloaded=xr.prototype.segmentDownloaded,xr.prototype.disable=xr.prototype.disable,xr.prototype.enable=xr.prototype.enable,xr.prototype.chooseVariant=xr.prototype.chooseVariant,xr.prototype.init=xr.prototype.init,xr.prototype.release=xr.prototype.release,xr.prototype.stop=xr.prototype.stop;var Er=1;function Ir(e,t,n){for(n=void 0===n||n,this.h=e,this.g=new Set([e]),t=(e=d(t=t||[])).next();!t.done;t=e.next())this.add(t.value,n)}function Pr(e,t){if(e.mimeType!=t.mimeType)return!1;if(e=e.codecs.split(",").map((function(e){return Ai(e)})),t=t.codecs.split(",").map((function(e){return Ai(e)})),e.length!=t.length)return!1;e.sort(),t.sort();for(var n=0;n<e.length;n++)if(e[n]!=t[n])return!1;return!0}function Cr(e,t){if(e=new Set(e),t=new Set(t),e.delete("main"),t.delete("main"),e.size!=t.size)return!1;for(var n=(e=d(e)).next();!n.done;n=e.next())if(!t.has(n.value))return!1;return!0}function jr(e,t){this.g=new Or(e.language,"",e.audio&&e.audio.channelsCount?e.audio.channelsCount:0,e.video&&e.video.hdr?e.video.hdr:"",!(!e.audio||!e.audio.spatialAudio)&&e.audio.spatialAudio,e.video&&e.video.videoLayout?e.video.videoLayout:"","","",t,e.audio&&e.audio.codecs?e.audio.codecs:"")}function Or(e,t,n,i,r,a,s,o,u,d){this.s=e,this.A=t,this.i=n,this.j=i,this.B=r,this.m=a,this.h=s,this.l=o,this.o=u,this.g=d}function Rr(){this.g=Ur,this.i=(new Map).set(Ur,2).set(Hr,1),this.h=0}function Nr(e,t,n){e.i.set(Ur,n).set(Hr,t)}U("shaka.config.AutoShowText",{NEVER:0,ALWAYS:1,IF_PREFERRED_TEXT_LANGUAGE:2,IF_SUBTITLES_MAY_BE_NEEDED:3}),U("shaka.config.CodecSwitchingStrategy",{RELOAD:"reload",SMOOTH:"smooth"}),Ir.prototype.add=function(e,t){var n,i=this.h;if(t=void 0===t||t,!(n=!!i.audio!=!!e.audio||!!i.video!=!!e.video||i.language!=e.language)&&(n=i.audio&&e.audio)){n=i.audio;var r=e.audio;n=!(!((!n.channelsCount||!r.channelsCount||2<n.channelsCount||2<r.channelsCount)&&n.channelsCount!=r.channelsCount||n.spatialAudio!==r.spatialAudio||t&&!Pr(n,r))&&Cr(n.roles,r.roles)&&n.groupId===r.groupId)}return!n&&(n=i.video&&e.video)&&(i=i.video,n=e.video,n=!((!t||Pr(i,n))&&Cr(i.roles,n.roles))),!n&&(this.g.add(e),!0)},Ir.prototype.values=function(){return this.g.values()},jr.prototype.create=function(e){return this.g.create(e)},Or.prototype.create=function(t){var n=[];n=function(e,t){var n=Zi(t=Ki(t),e.map((function(e){return Qi(e)})));return n?e.filter((function(e){return n==Qi(e)})):[]}(t,this.s);var i=t.filter((function(e){return e.primary}));return t=function(e,t){return e.filter((function(e){return!!e.audio&&(t?e.audio.roles.includes(t):0==e.audio.roles.length)}))}(n=n.length?n:i.length?i:t,this.A),t.length&&(n=t),this.m&&(t=function(e,t){return e.filter((function(e){return!e.video||!e.video.videoLayout||e.video.videoLayout==t}))}(n,this.m),t.length&&(n=t)),this.j&&(t=function(t,n){return"AUTO"==n&&(n=e.matchMedia("(color-gamut: p3)").matches?t.some((function(e){return!(!e.video||!e.video.hdr||"HLG"!=e.video.hdr)}))?"HLG":"PQ":"SDR"),t.filter((function(e){return!e.video||!e.video.hdr||e.video.hdr==n}))}(n,this.j),t.length&&(n=t)),this.i&&(t=function(e,t){return e.filter((function(e){return!e.audio||!e.audio.channelsCount||e.audio.channelsCount==t}))}(n,this.i),t.length&&(n=t)),this.h&&(t=function(e,t){return e.filter((function(e){return!(!e.audio||!e.audio.label)&&e.audio.label.toLowerCase()==t.toLowerCase()}))}(n,this.h),t.length&&(n=t)),this.l&&(t=function(e,t){return e.filter((function(e){return!(!e.video||!e.video.label)&&e.video.label.toLowerCase()==t.toLowerCase()}))}(n,this.l),t.length&&(n=t)),t=function(e,t){return e.filter((function(e){return!e.audio||e.audio.spatialAudio==t}))}(n,this.B),t.length&&(n=t),this.g&&(t=function(e,t){return e.filter((function(e){return!e.audio||e.audio.codecs==t}))}(n,this.g),t.length&&(n=t)),new Ir(n[0],n,!("smooth"==this.o&&ie()))};var Hr=0,Ur=1;function Fr(e,t){var n=2,i=1e3,r=2,a=.5;this.l=null==e.maxAttempts?n:e.maxAttempts,this.j=null==e.baseDelay?i:e.baseDelay,this.o=null==e.fuzzFactor?a:e.fuzzFactor,this.m=null==e.backoffFactor?r:e.backoffFactor,this.g=0,this.h=this.j,(this.i=void 0!==t&&t)&&(this.g=1)}function Br(e){var t,n;return I((function(i){if(1==i.g){if(e.g>=e.l){if(!e.i)throw new Ye(2,7,1010);e.g=1,e.h=e.j}return t=e.g,e.g++,0==t?i.return():(n=e.h*(1+(2*Math.random()-1)*e.o),M(i,new Promise((function(e){new He(e).$(n/1e3)})),2))}e.h*=e.m,w(i)}))}function Wr(){var e,t,n=new Promise((function(n,i){e=n,t=i}));return n.resolve=e,n.reject=t,n}function zr(e,t){this.promise=e,this.i=t,this.g=null}function Vr(e){return new zr(Promise.reject(e),(function(){return Promise.resolve()}))}function Gr(){var e=Promise.reject(new Ye(2,7,7001));return e.catch((function(){})),new zr(e,(function(){return Promise.resolve()}))}function qr(e){return new zr(Promise.resolve(e),(function(){return Promise.resolve()}))}function $r(e){return new zr(e,(function(){return e.catch((function(){}))}))}function Kr(e){return new zr(Promise.all(e.map((function(e){return e.promise}))),(function(){return Promise.all(e.map((function(e){return e.abort()})))}))}function Jr(t,n){if(n)if(n instanceof Map)for(var i=d(n.keys()),r=i.next();!r.done;r=i.next())r=r.value,Object.defineProperty(this,r,{value:n.get(r),writable:!0,enumerable:!0});else for(i in n)Object.defineProperty(this,i,{value:n[i],writable:!0,enumerable:!0});this.defaultPrevented=this.cancelable=this.bubbles=!1,this.timeStamp=e.performance&&e.performance.now?e.performance.now():Date.now(),this.type=t,this.isTrusted=!1,this.target=this.currentTarget=null,this.g=!1}function Xr(e){var t,n=new Jr(e.type);for(t in e)Object.defineProperty(n,t,{value:e[t],writable:!0,enumerable:!0});return n}Wr.prototype.resolve=function(){},Wr.prototype.reject=function(){},zr.prototype.abort=function(){return this.g||(this.g=this.i()),this.g},zr.prototype.finally=function(e){return this.promise.then((function(){return e(!0)}),(function(){return e(!1)})),this},zr.prototype.Ca=function(e,t){function n(n){return function(o){if(r.g&&n)a.reject(s);else{var u=n?e:t;u?i=function(e,t,n){try{var i=e(t);return i&&i.promise&&i.abort?(n.resolve(i.promise),function(){return i.abort()}):(n.resolve(i),function(){return Promise.resolve(i).then((function(){}),(function(){}))})}catch(e){return n.reject(e),function(){return Promise.resolve()}}}(u,o,a):(n?a.resolve:a.reject)(o)}}}function i(){return a.reject(s),r.abort()}var r=this,a=new Wr;a.catch((function(){}));var s=new Ye(2,7,7001);return this.promise.then(n(!0),n(!1)),new zr(a,(function(){return i()}))},s.Object.defineProperties(zr.prototype,{aborted:{configurable:!0,enumerable:!0,get:function(){return null!==this.g}}}),U("shaka.util.AbortableOperation",zr),zr.prototype.chain=zr.prototype.Ca,zr.prototype.finally=zr.prototype.finally,zr.all=Kr,zr.prototype.abort=zr.prototype.abort,zr.notAbortable=$r,zr.completed=qr,zr.aborted=Gr,zr.failed=Vr,Jr.prototype.preventDefault=function(){this.cancelable&&(this.defaultPrevented=!0)},Jr.prototype.stopImmediatePropagation=function(){this.g=!0},Jr.prototype.stopPropagation=function(){},U("shaka.util.FakeEvent",Jr);var Qr={mj:"abrstatuschanged",nj:"adaptation",oj:"audiotrackchanged",pj:"buffering",qj:"complete",rj:"downloadfailed",sj:"downloadheadersreceived",tj:"drmsessionupdate",vj:"emsg",Pj:"prft",Error:"error",wj:"expirationupdated",xj:"firstquartile",yj:"gapjumped",Bj:"keystatuschanged",Fj:"loaded",Gj:"loading",Ij:"manifestparsed",Jj:"manifestupdated",Kj:"mediaqualitychanged",Lj:"mediasourcerecovered",Metadata:"metadata",Mj:"midpoint",Nj:"nospatialvideoinfo",Oj:"onstatechange",Qj:"ratechange",Sj:"segmentappended",Tj:"sessiondata",Uj:"spatialvideoinfo",Vj:"stalldetected",Wj:"started",Xj:"statechanged",Yj:"streaming",Zj:"textchanged",$j:"texttrackvisibility",ak:"thirdquartile",bk:"timelineregionadded",ck:"timelineregionenter",dk:"timelineregionexit",ek:"trackschanged",gk:"unloading",ik:"variantchanged"};function Zr(){this.ra=new Q,this.re=this}function ea(){this.g=[]}function ta(e,t){e.g.push(t.finally((function(){De(e.g,t)})))}function na(e,t,n,i,r,a){Zr.call(this),this.i=!1,this.o=new ea,this.g=new Set,this.h=new Set,this.l=e||null,this.j=t||null,this.B=n||null,this.C=i||null,this.G=r||null,this.F=a||null,this.s=this.A=!1,this.m=16e3}function ia(e,t,n,i){n=n||ca;var r=ha[e];(!r||n>=r.priority)&&(ha[e]={priority:n,he:t,Hi:void 0!==i&&i})}function ra(e,t){for(var n=d(e.g),i=n.next();!i.done;i=n.next())t.g.add(i.value);for(n=(e=d(e.h)).next();!n.done;n=e.next())t.h.add(n.value)}function aa(e,t,n){return{uris:e,method:"GET",body:null,headers:{},allowCrossSiteCredentials:!1,retryParameters:t,licenseRequestType:null,sessionId:null,drmInfo:null,initData:null,initDataType:null,streamDataCallback:void 0===n?null:n}}function sa(e,t,n,i,r,a,s,o){e.A&&(n.uris[a]=n.uris[a].replace("https://","http://")),e.s&&(n.uris[a]=n.uris[a].replace("http://","https://")),0<a&&e.G&&e.G(t,i,n.uris[a],n.uris[a-1]);var u=new Wn(n.uris[a]),d=u.Db,l=!1;d||(zn(u,d=(d=location.protocol).slice(0,-1)),n.uris[a]=u.toString()),d=d.toLowerCase();var c=(d=ha[d])?d.he:null;if(!c)return Vr(new Ye(2,1,1e3,u));var h,m=d.Hi,f=null,p=null,g=!1,y=!1;return $r(Br(r)).Ca((function(){if(e.i)return Gr();h=Date.now();var r=0;n.requestStartTime=Date.now();var s=c(n.uris[a],n,t,(function(a,s,u){f&&f.stop(),p&&p.$(d/1e3),e.l&&t==la&&(r++,n.packetNumber=r,e.l(a,s,oa(i),n),l=!0,o.g=u)}),(function(i){y=!0,n.timeToFirstByte=Date.now()-n.requestStartTime,e.j&&e.j(i,n,t)}),{minBytesForProgressEvents:e.m});if(!m)return s;var u=n.retryParameters.connectionTimeout;u&&(f=new He((function(){g=!0,s.abort()}))).$(u/1e3);var d=n.retryParameters.stallTimeout;return d&&(p=new He((function(){g=!0,s.abort()}))),s})).Ca((function(i){f&&f.stop(),p&&p.stop(),null==i.timeMs&&(i.timeMs=Date.now()-h);var r={response:i,mi:l};return!y&&e.j&&e.j(i.headers,n,t),r}),(function(u){if(f&&f.stop(),p&&p.stop(),e.B){var d=null,l=0;u instanceof Ye&&(d=u,1001==u.code&&(l=u.data[1])),e.B(n,d,l,g)}if(e.i)return Gr();if(g&&(u=new Ye(1,1,1003,n.uris[a],t)),u instanceof Ye){if(7001==u.code)throw u;if(1010==u.code)throw s;if(1==u.severity)return d=new Jr("retry",d=(new Map).set("error",u)),e.dispatchEvent(d),a=(a+1)%n.uris.length,sa(e,t,n,i,r,a,u,o)}throw u}))}function oa(e){if(e){var t=e.segment;if(e=e.stream,t&&e&&e.fastSwitching&&t.o)return!1}return!0}function ua(){this.g=0}function da(e,t,n){zr.call(this,e,t),this.h=n}Zr.prototype.addEventListener=function(e,t){this.ra&&this.ra.push(e,t)},Zr.prototype.removeEventListener=function(e,t){this.ra&&this.ra.remove(e,t)},Zr.prototype.dispatchEvent=function(e){if(!this.ra)return!0;var t=this.ra.get(e.type)||[],n=this.ra.get("All");for(n&&(t=t.concat(n)),n=(t=d(t)).next();!n.done;n=t.next()){n=n.value,e.target=this.re,e.currentTarget=this.re;try{n.handleEvent?n.handleEvent(e):n.call(this,e)}catch(e){}if(e.g)break}return e.defaultPrevented},Zr.prototype.release=function(){this.ra=null},ea.prototype.destroy=function(){for(var e=[],t=d(this.g),n=t.next();!n.done;n=t.next())(n=n.value).promise.catch((function(){})),e.push(n.abort());return this.g=[],Promise.all(e)},g(na,Zr),(i=na.prototype).Tf=function(e){this.A=e},i.Uf=function(e){this.s=e},i.Ki=function(e){this.g.add(e)},i.fj=function(e){this.g.delete(e)},i.og=function(){this.g.clear()},i.Li=function(e){this.h.add(e)},i.gj=function(e){this.h.delete(e)},i.pg=function(){this.h.clear()},i.destroy=function(){return this.i=!0,this.g.clear(),this.h.clear(),Zr.prototype.release.call(this),this.o.destroy()},i.request=function(e,t,n){var i=this,r=new ua;if(this.i){var a=Promise.reject(new Ye(2,7,7001));return a.catch((function(){})),new da(a,(function(){return Promise.resolve()}),r)}t.method=t.method||"GET",t.headers=t.headers||{},t.retryParameters=t.retryParameters?kt(t.retryParameters):{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4},t.uris=kt(t.uris),a=function(e,t,n,i){function r(e){a=a.Ca((function(){return n.body&&(n.body=fe(n.body)),e(t,n,i)}))}var a=qr(void 0);e.C&&r(e.C);for(var s=(e=d(e.g)).next();!s.done;s=e.next())r(s.value);return a.Ca(void 0,(function(e){if(e instanceof Ye&&7001==e.code)throw e;throw new Ye(2,1,1006,e)}))}(this,e,t,n);var s=a.Ca((function(){return sa(i,e,t,n,new Fr(t.retryParameters,!1),0,null,r)})),o=s.Ca((function(t){return function(e,t,n,i){for(var r=qr(void 0),a=(e=d(e.h)).next(),s={};!a.done;s={Yg:void 0},a=e.next())s.Yg=a.value,r=r.Ca(function(e){return function(){var r=n.response;return r.data&&(r.data=fe(r.data)),(0,e.Yg)(t,r,i)}}(s));return r.Ca((function(){return n}),(function(e){var t=2;if(e instanceof Ye){if(7001==e.code)throw e;t=e.severity}throw new Ye(t,1,1007,e)}))}(i,e,t,n)})),u=Date.now(),l=0;a.promise.then((function(){l=Date.now()-u}),(function(){}));var c=0;s.promise.then((function(){c=Date.now()}),(function(){}));var h=o.Ca((function(r){var a=Date.now()-c,s=r.response;return s.timeMs+=l,s.timeMs+=a,r.mi||!i.l||s.fromCache||"HEAD"==t.method||e!=la||i.l(s.timeMs,s.data.byteLength,oa(n)),i.F&&i.F(e,s,n),s}),(function(e){throw e&&(e.severity=2),e}));return a=new da(h.promise,(function(){return h.abort()}),r),ta(this.o,a),a},U("shaka.net.NetworkingEngine",na),na.prototype.request=na.prototype.request,na.prototype.destroy=na.prototype.destroy,na.makeRequest=aa,na.defaultRetryParameters=function(){return{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4}},na.prototype.clearAllResponseFilters=na.prototype.pg,na.prototype.unregisterResponseFilter=na.prototype.gj,na.prototype.registerResponseFilter=na.prototype.Li,na.prototype.clearAllRequestFilters=na.prototype.og,na.prototype.unregisterRequestFilter=na.prototype.fj,na.prototype.registerRequestFilter=na.prototype.Ki,na.unregisterScheme=function(e){delete ha[e]},na.registerScheme=ia,na.prototype.setForceHTTPS=na.prototype.Uf,na.prototype.setForceHTTP=na.prototype.Tf,na.NumBytesRemainingClass=ua,g(da,zr),na.PendingRequest=da;var la=1;na.RequestType={MANIFEST:0,SEGMENT:la,LICENSE:2,APP:3,TIMING:4,SERVER_CERTIFICATE:5,KEY:6,ADS:7,CONTENT_STEERING:8},na.AdvancedRequestType={INIT_SEGMENT:0,MEDIA_SEGMENT:1,MEDIA_PLAYLIST:2,MASTER_PLAYLIST:3,MPD:4,MSS:5,MPD_PATCH:6,MEDIATAILOR_SESSION_INFO:7,MEDIATAILOR_TRACKING_INFO:8,MEDIATAILOR_STATIC_RESOURCE:9,MEDIATAILOR_TRACKING_EVENT:10,INTERSTITIAL_ASSET_LIST:11,INTERSTITIAL_AD_URL:12};var ca=3;na.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:ca};var ha={};function ma(e){this.g=!1,this.h=new Wr,this.i=e}function fa(e,t){if(e.g){if(t instanceof Ye&&7003==t.code)throw t;throw new Ye(2,7,7003,t)}}function pa(e,t){for(var n=[],i=(e=d(e)).next();!i.done;i=e.next())n.push(t(i.value));return n}function ga(e){for(var t=new Map,n=d(Object.keys(e)),i=n.next();!i.done;i=n.next())i=i.value,t.set(i,e[i]);return t}function ya(e){var t={};return e.forEach((function(e,n){t[n]=e})),t}function _a(e,t){this.h=ye(e),this.i=t==Ma,this.g=0}function va(){return new Ye(2,3,3e3)}ma.prototype.destroy=function(){var e=this;return this.g?this.h:(this.g=!0,this.i().then((function(){e.h.resolve()}),(function(){e.h.resolve()})))},(i=_a.prototype).sa=function(){return this.g<this.h.byteLength},i.ya=function(){return this.g},i.getLength=function(){return this.h.byteLength},i.T=function(){try{var e=this.h.getUint8(this.g);return this.g+=1,e}catch(e){throw va()}},i.ma=function(){try{var e=this.h.getUint16(this.g,this.i);return this.g+=2,e}catch(e){throw va()}},i.P=function(){try{var e=this.h.getUint32(this.g,this.i);return this.g+=4,e}catch(e){throw va()}},i.Vg=function(){try{var e=this.h.getInt32(this.g,this.i);return this.g+=4,e}catch(e){throw va()}},i.Vc=function(){try{if(this.i)var e=this.h.getUint32(this.g,!0),t=this.h.getUint32(this.g+4,!0);else t=this.h.getUint32(this.g,!1),e=this.h.getUint32(this.g+4,!1)}catch(e){throw va()}if(2097151<t)throw new Ye(2,3,3001);return this.g+=8,t*Math.pow(2,32)+e},i.vb=function(e){if(this.g+e>this.h.byteLength)throw va();var t=pe(this.h,this.g,e);return this.g+=e,t},i.skip=function(e){if(this.g+e>this.h.byteLength)throw va();this.g+=e},i.Si=function(e){if(this.g<e)throw va();this.g-=e},i.seek=function(e){if(0>e||e>this.h.byteLength)throw va();this.g=e},i.yc=function(){for(var e=this.g;this.sa()&&0!=this.h.getUint8(this.g);)this.g+=1;return e=pe(this.h,e,this.g-e),this.g+=1,ct(e)},U("shaka.util.DataViewReader",_a),_a.prototype.readTerminatedString=_a.prototype.yc,_a.prototype.seek=_a.prototype.seek,_a.prototype.rewind=_a.prototype.Si,_a.prototype.skip=_a.prototype.skip,_a.prototype.readBytes=_a.prototype.vb,_a.prototype.readUint64=_a.prototype.Vc,_a.prototype.readInt32=_a.prototype.Vg,_a.prototype.readUint32=_a.prototype.P,_a.prototype.readUint16=_a.prototype.ma,_a.prototype.readUint8=_a.prototype.T,_a.prototype.getLength=_a.prototype.getLength,_a.prototype.getPosition=_a.prototype.ya,_a.prototype.hasMoreData=_a.prototype.sa;var Ma=1;function wa(){this.i=[],this.h=[],this.g=!1}function ba(e){for(var t=Aa(e);e.reader.sa()&&!e.parser.g;)e.parser.Sc(e.start+t,e.reader,e.partialOkay)}function Ta(e){for(var t=Aa(e),n=e.reader.P(),i=0;i<n&&(e.parser.Sc(e.start+t,e.reader,e.partialOkay),!e.parser.g);i++);}function La(e){var t=Aa(e);for(e.reader.skip(78);e.reader.sa()&&!e.parser.g;)e.parser.Sc(e.start+t,e.reader,e.partialOkay)}function Sa(e){var t=Aa(e);e.reader.skip(8);var n=e.reader.ma();for(e.reader.skip(6),2==n?e.reader.skip(48):e.reader.skip(12),1==n&&e.reader.skip(16);e.reader.sa()&&!e.parser.g;)e.parser.Sc(e.start+t,e.reader,e.partialOkay)}function ka(e){return function(t){e(t.reader.vb(t.reader.getLength()-t.reader.ya()))}}function Da(e){for(var t=0,n=(e=d(e)).next();!n.done;n=e.next())t=t<<8|n.value.charCodeAt(0);return t}function xa(e){return String.fromCharCode(e>>24&255,e>>16&255,e>>8&255,255&e)}function Aa(e){return 8+(e.has64BitSize?8:0)+(null!=e.flags?4:0)}_a.Endianness={BIG_ENDIAN:0,LITTLE_ENDIAN:Ma},(i=wa.prototype).box=function(e,t){return e=Da(e),this.i[e]=Ya,this.h[e]=t,this},i.R=function(e,t){return e=Da(e),this.i[e]=Ea,this.h[e]=t,this},i.stop=function(){this.g=!0},i.parse=function(e,t,n){for(e=new _a(e,0),this.g=!1;e.sa()&&!this.g;)this.Sc(0,e,t,n)},i.Sc=function(e,t,n,i){var r=t.ya();if(i&&r+8>t.getLength())this.g=!0;else{var a=t.P(),s=t.P(),o=xa(s),u=!1;switch(a){case 0:a=t.getLength()-r;break;case 1:if(i&&t.ya()+8>t.getLength())return void(this.g=!0);a=t.Vc(),u=!0}var d=this.h[s];if(d){var l=null,c=null;if(this.i[s]==Ea){if(i&&t.ya()+4>t.getLength())return void(this.g=!0);l=(c=t.P())>>>24,c&=16777215}s=r+a,n&&s>t.getLength()&&(s=t.getLength()),i&&s>t.getLength()?this.g=!0:(i=s-t.ya(),d({name:o,parser:this,partialOkay:n||!1,version:l,flags:c,reader:t=new _a(t=0<i?t.vb(i):new Uint8Array(0),0),size:a,start:r+e,has64BitSize:u}))}else t.skip(Math.min(r+a-t.ya(),t.getLength()-t.ya()))}},U("shaka.util.Mp4Parser",wa),wa.headerSize=Aa,wa.typeToString=xa,wa.allData=ka,wa.audioSampleEntry=Sa,wa.visualSampleEntry=La,wa.sampleDescription=Ta,wa.children=ba,wa.prototype.parseNext=wa.prototype.Sc,wa.prototype.parse=wa.prototype.parse,wa.prototype.stop=wa.prototype.stop,wa.prototype.fullBox=wa.prototype.R,wa.prototype.box=wa.prototype.box;var Ya=0,Ea=1;function Ia(e){var t=this;this.g=[],this.h=[],this.data=[],(new wa).box("moov",ba).box("moof",ba).R("pssh",(function(e){if(!(1<e.version)){var n=pe(e.reader.h,-12,e.size);if(t.data.push(n),t.g.push(li(e.reader.vb(16))),0<e.version){n=e.reader.P();for(var i=0;i<n;i++){var r=li(e.reader.vb(16));t.h.push(r)}}}})).parse(e)}function Pa(e,t,n,i){var r=e.length,a=t.length+16+r;0<i&&(a+=4+16*n.size);var s=new Uint8Array(a),o=ye(s),u=0;if(o.setUint32(u,a),u+=4,o.setUint32(u,1886614376),u+=4,1>i?o.setUint32(u,0):o.setUint32(u,16777216),u+=4,s.set(t,u),u+=t.length,0<i)for(o.setUint32(u,n.size),u+=4,n=(t=d(n)).next();!n.done;n=t.next())n=di(n.value),s.set(n,u),u+=n.length;return o.setUint32(u,r),s.set(e,u+4),s}function Ca(e){var t=this;this.C=e,this.l=this.A=null,this.ja=this.fa=!1,this.H=0,this.g=null,this.o=new Z,this.i=new Map,this.Y=[],this.B=new Map,this.K=!1,this.m=new Wr,this.h=null,this.s=function(n){2==n.severity&&t.m.reject(n),e.onError(n)},this.aa=new Map,this.ga=new Map,this.L=new He((function(){return function(e){var t=e.aa,n=e.ga;n.clear(),t.forEach((function(e,t){return n.set(t,e)})),(t=Array.from(n.values())).length&&t.every((function(e){return"expired"==e}))&&e.s(new Ye(2,6,6014)),e.C.ee(ya(n))}(t)})),this.O=!1,this.M=[],this.Z=!1,this.I=new He((function(){!function(e){e.i.forEach((function(t,n){var i=t.Df,r=n.expiration;isNaN(r)&&(r=1/0),r!=i&&(e.C.onExpirationUpdated(n.sessionId,r),t.Df=r)}))}(t)})),this.m.catch((function(){})),this.j=new ma((function(){return function(e){return I((function(t){switch(t.g){case 1:return e.o.release(),e.o=null,e.m.reject(),e.I.stop(),e.I=null,e.L.stop(),e.L=null,M(t,qa(e),2);case 2:if(!e.l){t.u(3);break}return b(t,4),M(t,e.l.setMediaKeys(null),6);case 6:L(t,5);break;case 4:S(t);case 5:e.l=null;case 3:e.g=null,e.A=null,e.B=new Map,e.h=null,e.s=function(){},e.C=null,e.da=!1,e.G=null,w(t)}}))}(t)})),this.da=!1,this.F=this.G=null,this.S=function(){return!1}}function ja(e,t,n){e.B=new Map;for(var i=(n=d(n)).next();!i.done;i=n.next())e.B.set(i.value,{initData:null,initDataType:null});for(i=(n=d(e.h.persistentSessionsMetadata)).next();!i.done;i=n.next())i=i.value,e.B.set(i.sessionId,{initData:i.initData,initDataType:i.initDataType});return e.O=0<e.B.size,Oa(e,t)}function Oa(e,t){var n,i,r,a,s,o,u,l,c,h,m,f,p,g,y,_,v;return I((function(w){if(1==w.g){if(n=function(e){return 0==(e=ga(e.h.clearKeys)).size?null:fi(e)}(e))for(i=d(t),r=i.next();!r.done;r=i.next())(a=r.value).video&&(a.video.drmInfos=[n]),a.audio&&(a.audio.drmInfos=[n]);for((s=t.some((function(e){return!!(e.video&&e.video.drmInfos.length||e.audio&&e.audio.drmInfos.length)})))||(o=ga(e.h.servers),function(e,t){var n=[];for(t.forEach((function(e,t){n.push({keySystem:t,licenseServerUri:e,distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,serverCertificateUri:"",initData:[],keyIds:new Set})})),t=(e=d(e)).next();!t.done;t=e.next())(t=t.value).video&&(t.video.drmInfos=n),t.audio&&(t.audio.drmInfos=n)}(t,o)),u=new Set,l=d(t),c=l.next();!c.done;c=l.next())for(h=c.value,m=$a(h),f=d(m),p=f.next();!p.done;p=f.next())g=p.value,u.add(g);for(y=d(u),_=y.next();!_.done;_=y.next())Xa(_.value,ga(e.h.servers),ga(e.h.advanced||{}),e.h.keySystemsMapping);return M(w,or(t,e.O,e.da,e.h.preferredKeySystems),2)}return fa(e.j),s||Object.keys(e.h.servers).length?(v=Fa(e,void 0,t),w.return(s?v:v.catch((function(){})))):(e.fa=!0,w.return(Promise.resolve()))}))}function Ra(e){var t;return I((function(n){switch(n.g){case 1:if(e.l.mediaKeys)return n.return();if(!e.G){n.u(2);break}return M(n,e.G,3);case 3:return fa(e.j),n.return();case 2:return b(n,4),e.G=e.l.setMediaKeys(e.A),M(n,e.G,6);case 6:L(n,5);break;case 4:t=S(n),e.s(new Ye(2,6,6003,t.message));case 5:fa(e.j),w(n)}}))}function Na(e){var t,n,i,r;return I((function(a){if(1==a.g)return e.B.size?(e.B.forEach((function(t,n){za(e,n,t)})),M(a,e.m,3)):a.u(2);if(2!=a.g){if(0<(e.g&&e.g.keyIds||new Set([])).size&&function(e){for(var t=d(e.g&&e.g.keyIds||new Set([])),n=t.next();!n.done;n=t.next())if("usable"!==e.aa.get(n.value))return!1;return!0}(e))return a.return(e.m);e.K=!1,e.m=new Wr,e.m.catch((function(){}))}for(t=(e.g?e.g.initData:[])||[],n=d(t),i=n.next();!i.done;i=n.next())r=i.value,Ha(e,r.initDataType,r.initData);return Ka(e)&&e.m.resolve(),a.return(e.m)}))}function Ha(e,t,n){if(n.length){if(e.h.ignoreDuplicateInitData){for(var i=e.i.values(),r=(i=d(i)).next();!r.done;r=i.next())if(me(n,r.value.initData))return;var a=!1;if(e.B.forEach((function(e){!a&&me(n,e.initData)&&(a=!0)})),a)return}e.K=!0,0<e.i.size&&Ka(e)&&(e.m.resolve(),e.K=!1,e.m=new Wr,e.m.catch((function(){}))),function(e,t,n,i){try{var r=e.A.createSession(i)}catch(t){return void e.s(new Ye(2,6,6005,t.message))}e.o.D(r,"message",(function(t){e.l&&e.h.delayLicenseRequestUntilPlayed&&e.l.paused&&!e.Z?e.M.push(t):Va(e,t)})),e.o.D(r,"keystatuseschange",(function(t){return Ga(e,t)})),e.i.set(r,{initData:n,initDataType:t,loaded:!1,Df:1/0,nb:null,type:i});try{n=e.h.initDataTransform(n,t,e.g)}catch(n){return t=n,n instanceof Ye||(t=new Ye(2,6,6016,n)),void e.s(t)}e.h.logLicenseExchange&&oi(n),r.generateRequest(t,n).catch((function(t){if(!e.j.g){e.i.delete(r);var n=t.errorCode;if(n&&n.systemCode){var i=n.systemCode;0>i&&(i+=Math.pow(2,32)),i="0x"+i.toString(16)}e.s(new Ye(2,6,6006,t.message,t,i))}}))}(e,t,n,e.g.sessionType)}}function Ua(e){return e=pa(e=e.i.keys(),(function(e){return e.sessionId})),Array.from(e)}function Fa(e,t,n){var i,r,a,s,o,u,l;return I((function(c){switch(c.g){case 1:if(i=new Map,n.length){r=function(e,t,n){for(var i=d(t),r=i.next();!r.done;r=i.next())for(var a=(r=d($a(r.value))).next();!a.done;a=r.next())a=a.value,n.has(a.keySystem)||n.set(a.keySystem,[]),n.get(a.keySystem).push(a);if(1==n.size&&n.has(""))throw new Ye(2,6,6e3);for(a=(i=d(e.h.preferredKeySystems)).next(),r={};!a.done;r={Ug:void 0},a=i.next()){r.Ug=a.value;for(var s=(a=d(t)).next();!s.done;s=a.next())if(s=s.value.decodingInfos.find(function(e){return function(t){return t.supported&&null!=t.keySystemAccess&&t.keySystemAccess.keySystem==e.Ug}}(r)))return s.keySystemAccess}for(r=(i=d([!0,!1])).next();!r.done;r=i.next())for(r=r.value,s=(a=d(t)).next();!s.done;s=a.next())for(var o=(s=d(s.value.decodingInfos)).next();!o.done;o=s.next())if((o=o.value).supported&&o.keySystemAccess){var u=o.keySystemAccess.keySystem,l=n.get(u);for(!l&&e.h.keySystemsMapping[u]&&(l=n.get(e.h.keySystemsMapping[u])),l=(u=d(l)).next();!l.done;l=u.next())if(!!l.value.licenseServerUri==r)return o.keySystemAccess}return null}(e,n,i),c.u(2);break}return M(c,function(e,t){var n,i,r,a,s,o,u,l,c,h,m,f,p,g,y,_;return I((function(v){switch(v.g){case 1:if(1==t.size&&t.has(""))throw new Ye(2,6,6e3);for(i=d(t.values()),r=i.next();!r.done;r=i.next())0==(a=r.value).audioCapabilities.length&&delete a.audioCapabilities,0==a.videoCapabilities.length&&delete a.videoCapabilities;s=d(e.h.preferredKeySystems),o=s.next();case 2:if(o.done){v.u(4);break}if(u=o.value,!t.has(u)){v.u(3);break}return l=t.get(u),b(v,6),M(v,navigator.requestMediaKeySystemAccess(u,[l]),8);case 8:return n=v.h,v.return(n);case 6:S(v);case 7:fa(e.j);case 3:o=s.next(),v.u(2);break;case 4:c=d([!0,!1]),h=c.next();case 9:if(h.done){v.u(11);break}m=h.value,f=d(t.keys()),p=f.next();case 12:if(p.done){h=c.next(),v.u(9);break}if(g=p.value,y=t.get(g),_=y.drmInfos.some((function(e){return!!e.licenseServerUri})),_!=m){v.u(13);break}return b(v,15),M(v,navigator.requestMediaKeySystemAccess(g,[y]),17);case 17:return n=v.h,v.return(n);case 15:S(v);case 16:fa(e.j);case 13:p=f.next(),v.u(12);break;case 11:return v.return(n)}}))}(e,t),3);case 3:r=c.h;case 2:if(!(a=r))throw new Ye(2,6,6001);if(fa(e.j),b(c,4),a.getConfiguration(),s=e.h.keySystemsMapping[a.keySystem]||a.keySystem,n.length){var h=s,m=i.get(s),f=[],p=[],g=[],y=[],_=[],v=new Set,w=new Set;Ja(m,f,p,y,g,_,v,w);var T=e.O?"persistent-license":"temporary";for(h={keySystem:h,encryptionScheme:f[0],licenseServerUri:p[0],distinctiveIdentifierRequired:m[0].distinctiveIdentifierRequired,persistentStateRequired:m[0].persistentStateRequired,sessionType:m[0].sessionType||T,audioRobustness:m[0].audioRobustness||"",videoRobustness:m[0].videoRobustness||"",serverCertificate:y[0],serverCertificateUri:g[0],initData:_,keyIds:v},0<w.size&&(h.keySystemUris=w),w=(m=d(m)).next();!w.done;w=m.next())(w=w.value).distinctiveIdentifierRequired&&(h.distinctiveIdentifierRequired=w.distinctiveIdentifierRequired),w.persistentStateRequired&&(h.persistentStateRequired=w.persistentStateRequired);m=h}else m=s,w=t.get(s),h=[],f=[],p=[],g=[],y=[],_=new Set,Ja(w.drmInfos,h,f,g,p,y,_),m={keySystem:m,encryptionScheme:h[0],licenseServerUri:f[0],distinctiveIdentifierRequired:"required"==w.distinctiveIdentifier,persistentStateRequired:"required"==w.persistentState,sessionType:w.sessionTypes[0]||"temporary",audioRobustness:(w.audioCapabilities?w.audioCapabilities[0].robustness:"")||"",videoRobustness:(w.videoCapabilities?w.videoCapabilities[0].robustness:"")||"",serverCertificate:g[0],serverCertificateUri:p[0],initData:y,keyIds:_};if(e.g=m,!e.g.licenseServerUri)throw new Ye(2,6,6012,e.g.keySystem);return M(c,a.createMediaKeys(),6);case 6:if(o=c.h,fa(e.j),e.A=o,""==e.h.minHdcpVersion||!("getStatusForPolicy"in e.A)){c.u(7);break}return b(c,8),M(c,e.A.getStatusForPolicy({minHdcpVersion:e.h.minHdcpVersion}),10);case 10:if("usable"!=c.h)throw new Ye(2,6,6018);fa(e.j),L(c,7,4);break;case 8:if((u=S(c,4))instanceof Ye)throw u;throw new Ye(2,6,6019,u.message);case 7:return e.fa=!0,M(c,function(e){var t,n;return I((function(i){switch(i.g){case 1:if(!e.A||!e.g)return i.return();if(!e.g.serverCertificateUri||e.g.serverCertificate&&e.g.serverCertificate.length){i.u(2);break}return t=aa([e.g.serverCertificateUri],e.h.retryParameters),b(i,3),M(i,e.C.Nb.request(5,t,{isPreload:e.S()}).promise,5);case 5:n=i.h,e.g.serverCertificate=pe(n.data),L(i,4);break;case 3:throw new Ye(2,6,6017,S(i));case 4:if(e.j.g)return i.return();case 2:return e.g.serverCertificate&&e.g.serverCertificate.length?(b(i,6),M(i,e.A.setServerCertificate(e.g.serverCertificate),8)):i.return();case 8:L(i,0);break;case 6:throw new Ye(2,6,6004,S(i).message)}}))}(e),11);case 11:fa(e.j),L(c,0);break;case 4:if(l=S(c),fa(e.j,l),e.g=null,l instanceof Ye)throw l;throw new Ye(2,6,6002,l.message)}}))}function Ba(e){Ka(e)&&e.m.resolve()}function Wa(e,t){new He((function(){t.loaded=!0,Ba(e)})).$(Za)}function za(e,t,n){var i,r,a,s,o,u,d;return I((function(l){switch(l.g){case 1:try{i=e.A.createSession("persistent-license")}catch(t){return r=new Ye(2,6,6005,t.message),e.s(r),l.return(Promise.reject(r))}return e.o.D(i,"message",(function(t){e.l&&e.h.delayLicenseRequestUntilPlayed&&e.l.paused&&!e.Z?e.M.push(t):Va(e,t)})),e.o.D(i,"keystatuseschange",(function(t){return Ga(e,t)})),a={initData:n.initData,initDataType:n.initDataType,loaded:!1,Df:1/0,nb:null,type:"persistent-license"},e.i.set(i,a),b(l,2),M(l,i.load(t),4);case 4:return s=l.h,fa(e.j),s||(e.i.delete(i),o=e.h.persistentSessionOnlinePlayback?1:2,e.s(new Ye(o,6,6013)),a.loaded=!0),Wa(e,a),Ba(e),l.return(i);case 2:u=S(l),fa(e.j,u),e.i.delete(i),d=e.h.persistentSessionOnlinePlayback?1:2,e.s(new Ye(d,6,6005,u.message)),a.loaded=!0,Ba(e);case 3:return l.return(Promise.resolve())}}))}function Va(e,t){var n,i,r,a,s,o,u,l,c,h,m,f,p,g;I((function(y){switch(y.g){case 1:if(n=t.target,e.h.logLicenseExchange&&oi(t.message),i=e.i.get(n),r=e.g.licenseServerUri,a=e.h.advanced[e.g.keySystem],"individualization-request"==t.messageType&&a&&a.individualizationServer&&(r=a.individualizationServer),(s=aa([r],e.h.retryParameters)).body=t.message,s.method="POST",s.licenseRequestType=t.messageType,s.sessionId=n.sessionId,s.drmInfo=e.g,i&&(s.initData=i.initData,s.initDataType=i.initDataType),a&&a.headers)for(o in a.headers)s.headers[o]=a.headers[o];if(je(e.g.keySystem)){var _=ht(s.body,!0,!0);if(_.includes("PlayReadyKeyMessage")){for(var v=Rt(_=Yt(_,"PlayReadyKeyMessage"),"HttpHeader"),T=(v=d(v)).next();!T.done;T=v.next()){var k=T.value;T=Rt(k,"name")[0],k=Rt(k,"value")[0],s.headers[jt(T)]=jt(k)}_=Rt(_,"Challenge")[0],s.body=ui(jt(_))}else s.headers["Content-Type"]="text/xml; charset=utf-8"}return u=Date.now(),b(y,2),c=e.C.Nb.request(2,s,{isPreload:e.S()}),e.Y.push(c),M(y,c.promise,4);case 4:l=y.h,De(e.Y,c),L(y,3);break;case 2:return h=S(y),e.j.g||(m=new Ye(2,6,6007,h),1==e.i.size?(e.s(m),i&&i.nb&&i.nb.reject(m)):(i&&i.nb&&i.nb.reject(m),e.i.delete(n),Ka(e)&&(e.m.resolve(),e.L.$(.1)))),y.return();case 3:return e.j.g?y.return():(e.H+=(Date.now()-u)/1e3,e.h.logLicenseExchange&&oi(l.data),b(y,5),M(y,n.update(l.data),7));case 7:L(y,6);break;case 5:return f=S(y),p=new Ye(2,6,6008,f.message),e.s(p),i&&i.nb&&i.nb.reject(p),y.return();case 6:if(e.j.g)return y.return();g=new Jr("drmsessionupdate"),e.C.onEvent(g),i&&(i.nb&&i.nb.resolve(),Wa(e,i)),w(y)}}))}function Ga(e,t){t=t.target;var n=e.i.get(t),i=!1;t.keyStatuses.forEach((function(t,r){if("string"==typeof r){var a=r;r=t,t=a}if(je(e.g.keySystem)&&16==r.byteLength&&(Be()||Xe())){var s=(a=ye(r)).getUint32(0,!0),o=a.getUint16(4,!0),u=a.getUint16(6,!0);a.setUint32(0,s,!1),a.setUint16(4,o,!1),a.setUint16(6,u,!1)}"status-pending"!=t&&(n.loaded=!0),"expired"==t&&(i=!0),r=li(r).slice(0,32),e.aa.set(r,t)}));var r=t.expiration-Date.now();(0>r||i&&1e3>r)&&n&&!n.nb&&(e.i.delete(t),t.close().catch((function(){}))),Ka(e)&&(e.m.resolve(),e.L.$(es))}function qa(e){var t;return I((function(n){return t=Array.from(e.i.entries()),e.i.clear(),M(n,Promise.all(t.map((function(t){var n=(t=d(t)).next().value,i=t.next().value;return I((function(t){return 1==t.g?(b(t,2),e.ja||e.B.has(n.sessionId)||"persistent-license"!==i.type||e.h.persistentSessionOnlinePlayback?M(t,function(e){return I((function(t){return 1==t.g?(b(t,2),M(t,zi(Qa,Promise.all([e.close(),e.closed])),4)):2!=t.g?L(t,0):(S(t),void w(t))}))}(n),5):M(t,n.remove(),5)):2!=t.g?L(t,0):(S(t),void w(t))}))}))),0)}))}function $a(e){return(e.video?e.video.drmInfos:[]).concat(e.audio?e.audio.drmInfos:[])}function Ka(e){return function(e,t){for(var n=(e=d(e)).next();!n.done;n=e.next())if(!t(n.value))return!1;return!0}(e=e.i.values(),(function(e){return e.loaded}))}function Ja(t,n,i,r,a,s,o,u){for(var c=[],h=(t=d(t)).next(),m={};!h.done;m={ua:void 0},h=t.next()){if(m.ua=h.value,n.includes(m.ua.encryptionScheme)||n.push(m.ua.encryptionScheme),"org.w3.clearkey"==m.ua.keySystem&&m.ua.licenseServerUri.startsWith("data:application/json;base64,")?c.includes(m.ua.licenseServerUri)||c.push(m.ua.licenseServerUri):i.includes(m.ua.licenseServerUri)||i.push(m.ua.licenseServerUri),a.includes(m.ua.serverCertificateUri)||a.push(m.ua.serverCertificateUri),m.ua.serverCertificate&&(r.some(function(e){return function(t){return me(t,e.ua.serverCertificate)}}(m))||r.push(m.ua.serverCertificate)),m.ua.initData)for(var f=(h=d(m.ua.initData)).next(),p={};!f.done;p={qf:void 0},f=h.next())p.qf=f.value,s.some(function(e){return function(t){var n=e.qf;return!(!t.keyId||t.keyId!=n.keyId)||t.initDataType==n.initDataType&&me(t.initData,n.initData)}}(p))||s.push(p.qf);if(m.ua.keyIds)for(f=(h=d(m.ua.keyIds)).next();!f.done;f=h.next())o.add(f.value);if(m.ua.keySystemUris&&u)for(h=(m=d(m.ua.keySystemUris)).next();!h.done;h=m.next())u.add(h.value)}if(1==c.length)i.push(c[0]);else if(0<c.length){for(n=[],r=(c=d(c)).next();!r.done;r=c.next())r=e.atob(r.value.split("data:application/json;base64,").pop()),r=JSON.parse(r),n.push.apply(n,l(r.keys));c=JSON.stringify({keys:n}),i.push("data:application/json;base64,"+e.btoa(c))}}function Xa(t,n,i,r){var a=t.keySystem;!a||"org.w3.clearkey"==a&&t.licenseServerUri||(n.size&&(n=n.get(a)||"",t.licenseServerUri=n),t.keyIds||(t.keyIds=new Set),(i=i.get(a))&&(t.distinctiveIdentifierRequired||(t.distinctiveIdentifierRequired=i.distinctiveIdentifierRequired),t.persistentStateRequired||(t.persistentStateRequired=i.persistentStateRequired),t.videoRobustness||(t.videoRobustness=i.videoRobustness),t.audioRobustness||(t.audioRobustness=i.audioRobustness),t.serverCertificate||(t.serverCertificate=i.serverCertificate),i.sessionType&&(t.sessionType=i.sessionType),t.serverCertificateUri||(t.serverCertificateUri=i.serverCertificateUri)),r[a]&&(t.keySystem=r[a]),e.cast&&e.cast.__platform__&&"com.microsoft.playready"==a&&(t.keySystem="com.chromecast.playready"))}(i=Ca.prototype).destroy=function(){return this.j.destroy()},i.configure=function(e,t){this.h=e,t&&(this.S=t),this.I&&this.I.Ra(this.h.updateExpirationTime)},i.Tb=function(e){var t=this;return I((function(n){if(1==n.g)return t.A?(t.l=e,t.o.pa(t.l,"play",(function(){for(var e=d(t.M),n=e.next();!n.done;n=e.next())Va(t,n.value);t.Z=!0,t.M=[]})),t.l.remote?(t.o.D(t.l.remote,"connect",(function(){return qa(t)})),t.o.D(t.l.remote,"connecting",(function(){return qa(t)})),t.o.D(t.l.remote,"disconnect",(function(){return qa(t)}))):"webkitCurrentPlaybackTargetIsWireless"in t.l&&t.o.D(t.l,"webkitcurrentplaybacktargetiswirelesschanged",(function(){return qa(t)})),t.F=t.g&&t.g.initData.find((function(e){return 0<e.initData.length}))||null,t.F||"com.apple.fps"!==t.g.keySystem||t.B.size?M(n,Ra(t),2):n.u(2)):(t.o.pa(e,"encrypted",(function(){t.s(new Ye(2,6,6010))})),n.return());Na(t).catch((function(){})),t.F||t.B.size||t.h.parseInbandPsshEnabled||t.o.D(t.l,"encrypted",(function(e){return function(e,t){return I((function(n){if(1==n.g)return M(n,Ra(e),2);Ha(e,t.initDataType,pe(t.initData)),w(n)}))}(t,e)})),w(n)}))},i.jf=function(){var e=this,t=this.i.keys();return t=pa(t,(function(t){var n=e.i.get(t);return{sessionId:t.sessionId,sessionType:n.type,initData:n.initData,initDataType:n.initDataType}})),Array.from(t)},i.gd=function(){for(var e=1/0,t=this.i.keys(),n=(t=d(t)).next();!n.done;n=t.next())n=n.value,isNaN(n.expiration)||(e=Math.min(e,n.expiration));return e},i.Od=function(){return ya(this.ga)};var Qa=1,Za=5,es=.5;function ts(e,t,n){this.g=e,this.i=t,this.h=n}function ns(e,t){return I((function(n){if(1==n.g)return M(n,function(e,t,n,i){return n=void 0===n?[]:n,i=void 0===i?{}:i,I((function(r){return 1==r.g?M(r,rr(e,t,0<t.offlineSessionIds.length,n,i),2):(function(e){e.textStreams=e.textStreams.filter((function(e){return Ri(e=Ti(e.mimeType,e.codecs))}))}(t),M(r,function(e){var t,n,i,r,a,s,o;return I((function(u){switch(u.g){case 1:t=[],n=d(e.imageStreams),i=n.next();case 2:if(i.done){u.u(4);break}if(r=i.value,"application/mp4"==(a=r.mimeType)&&"mjpg"==r.codecs&&(a="image/jpg"),kr.has(a)){u.u(5);break}if(!(s=Dr.get(a))){kr.set(a,!1),u.u(5);break}return M(u,function(e){return new Promise((function(t){var n=new Image;n.src=e,"decode"in n?n.decode().then((function(){t(!0)})).catch((function(){t(!1)})):n.onload=n.onerror=function(){t(2===n.height)}}))}(s),7);case 7:o=u.h,kr.set(a,o);case 5:kr.get(a)&&t.push(r),i=n.next(),u.u(2);break;case 4:e.imageStreams=t,w(u)}}))}(t),0))}))}(e.h,t,e.g.drm.preferredKeySystems,e.g.drm.keySystemsMapping),2);if(e.g.streaming.dontChooseCodecs||nr(t,e.g.preferredVideoCodecs,e.g.preferredAudioCodecs,e.g.preferredDecodingAttributes,e.g.preferredTextFormats),!t.variants.some(_r))throw new Ye(2,4,4032);return n.return(rs(e,t))}))}function is(e,t){var n=e.g.restrictions;e=e.i;for(var i=!1,r=(t=d(t.variants)).next();!r.done;r=t.next()){var a=(r=r.value).allowedByApplication;r.allowedByApplication=ir(r,n,e),a!=r.allowedByApplication&&(i=!0)}return i}function rs(e,t){var n=is(e,t);if(t){var i=e.h?e.h.g:null;if(i&&e.h.A)for(var r=d(t.variants),a=r.next();!a.done;a=r.next())a=a.value,as(e,i.keySystem,a.video),as(e,i.keySystem,a.audio);ss(e,t)}return n}function as(e,t,n){if(n)for(var i=(n=d(n.drmInfos)).next();!i.done;i=n.next())if((i=i.value).keySystem==t)for(var r=(i=d(i.initData||[])).next();!r.done;r=i.next())r=r.value,Ha(e.h,r.initDataType,r.initData)}function ss(e,t){e=e.h?e.h.Od():{};var n=Object.keys(e);n=n.length&&"00"==n[0];for(var i=!1,r=!1,a=new Set,s=new Set,o=(t=d(t.variants)).next();!o.done;o=t.next()){var u=[];(o=o.value).audio&&u.push(o.audio),o.video&&u.push(o.video);for(var l=(u=d(u)).next();!l.done;l=u.next())if((l=l.value).keyIds.size)for(var c=(l=d(l.keyIds)).next();!c.done;c=l.next()){c=c.value;var h=e[n?"00":c];h?os.includes(h)&&s.add(h):a.add(c)}o.allowedByApplication?o.allowedByKeySystem&&(i=!0):r=!0}if(!i)throw new Ye(2,4,4012,e={hasAppRestrictions:r,missingKeys:Array.from(a),restrictedKeyStatuses:Array.from(s)})}var os=["output-restricted","internal-error"];function us(){}function ds(e,t){if(t){var n=ls[t.toLowerCase()];if(n)return n}throw new Ye(2,4,4e3,e,t)}U("shaka.media.ManifestParser",us),us.unregisterParserByMime=function(e){delete ls[e]},us.registerParserByMime=function(e,t){ls[e]=t},us.registerParserByExtension=function(){se("ManifestParser.registerParserByExtension","Please use an ManifestParser with registerParserByMime function.")},us.AccessibilityPurpose={hk:"visually impaired",zj:"hard of hearing"};var ls={};function cs(e,t,n,i,r){var a=ms.value(),s=e.subarray(n.start,n.start+n.size),o=ye(s),u=new Uint8Array(n.size+a.byteLength);for(u.set(s,0),(s=ye(u)).setUint32(4,r),u.set(a,n.size),r=o.getUint32(4),s.setUint32(n.size+16,r),hs(u,0,u.byteLength),r=new Uint8Array(e.byteLength+u.byteLength),n=We()||Be()?n.start:n.start+n.size,a=e.subarray(n),r.set(e.subarray(0,n)),r.set(u,n),r.set(a,n+u.byteLength),i=(e=d(i)).next();!i.done;i=e.next())hs(r,(i=i.value).start,i.size+u.byteLength);return u=ye(r,t.start),t=Aa(t),e=u.getUint32(t),u.setUint32(t,e+1),r}function hs(e,t,n){0!=(t=(e=ye(e,t)).getUint32(0))&&(1==t?(e.setUint32(8,n>>32),e.setUint32(12,4294967295&n)):e.setUint32(0,n))}var ms=new Ie((function(){return new Uint8Array([0,0,0,80,115,105,110,102,0,0,0,12,102,114,109,97,0,0,0,0,0,0,0,20,115,99,104,109,0,0,0,0,99,101,110,99,0,1,0,0,0,0,0,40,115,99,104,105,0,0,0,32,116,101,110,99,0,0,0,0,0,0,1,8,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0])}));function fs(e,t,n,i,r,a,s){this.N=e,this.Ja=t,this.va=n,this.Qc=void 0===i?null:i,this.timescale=void 0===r?null:r,this.g=void 0===a?null:a,this.aesKey=void 0===s?null:s,this.mimeType=this.codecs=null}function ps(e,t){return e===t||(e&&t?e.Zb()==t.Zb()&&e.Xb()==t.Xb()&&Ae(e.N().sort(),t.N().sort())&&me(e.pc(),t.pc()):e==t)}function gs(e,t,n,i,r,a,s,o,u,l,c,h,m,f,p,g){for(l=void 0===l?[]:l,f=void 0===f?_s:f,this.startTime=e,this.j=this.endTime=t,this.C=n,this.Ja=i,this.va=r,this.ba=a,this.timestampOffset=s,this.appendWindowStart=o,this.appendWindowEnd=u,this.g=l,this.tilesLayout=void 0===c?"":c,this.A=void 0===h?null:h,this.h=void 0===m?null:m,this.status=f,this.preload=!1,this.l=!0,this.m=!1,this.aesKey=void 0===p?null:p,this.thumbnailSprite=null,this.i=-1,this.s=void 0!==g&&g,this.F=this.o=!1,t=(e=d(this.g)).next();!t.done;t=e.next())t.value.Ng();this.s&&this.g.length&&this.g[this.g.length-1].Mg(),this.B=this.bandwidth=this.mimeType=this.codecs=null}function ys(e,t){e.ba=t;for(var n=(e=d(e.g)).next();!n.done;n=e.next())ys(n.value,t)}fs.prototype.Zb=function(){return this.Ja},fs.prototype.Xb=function(){return this.va},fs.prototype.pc=function(){return this.g},U("shaka.media.InitSegmentReference",fs),fs.prototype.getEndByte=fs.prototype.Xb,fs.prototype.getStartByte=fs.prototype.Zb,(i=gs.prototype).N=function(){return this.C()},i.getStartTime=function(){return this.startTime},i.Ph=function(){return this.endTime},i.Zb=function(){return this.Ja},i.Xb=function(){return this.va},i.hi=function(){return this.tilesLayout},i.gi=function(){return this.A},i.$b=function(){return this.status},i.Ai=function(){this.status=vs},i.Af=function(){this.preload=!0},i.isPreload=function(){return this.preload},i.Pc=function(){this.l=!1},i.si=function(){return this.l},i.Ng=function(){this.o=!0},i.ui=function(){return this.o},i.Mg=function(){this.F=!0},i.ti=function(){return this.F},i.Lg=function(){this.m=!0},i.ni=function(){return this.m},i.qe=function(e){this.thumbnailSprite=e},i.fi=function(){return this.thumbnailSprite},i.offset=function(e){this.startTime+=e,this.endTime+=e,this.j+=e;for(var t=d(this.g),n=t.next();!n.done;n=t.next())(n=n.value).startTime+=e,n.endTime+=e,n.j+=e},i.Yf=function(e){null==this.h?q("Sync attempted without sync time!"):(e=this.h-e-this.startTime,.001<=Math.abs(e)&&this.offset(e))},i.cj=function(e){this.B=e},i.pc=function(){return this.B},U("shaka.media.SegmentReference",gs),gs.prototype.getSegmentData=gs.prototype.pc,gs.prototype.setSegmentData=gs.prototype.cj,gs.prototype.syncAgainst=gs.prototype.Yf,gs.prototype.offset=gs.prototype.offset,gs.prototype.getThumbnailSprite=gs.prototype.fi,gs.prototype.setThumbnailSprite=gs.prototype.qe,gs.prototype.hasByterangeOptimization=gs.prototype.ni,gs.prototype.markAsByterangeOptimization=gs.prototype.Lg,gs.prototype.isLastPartial=gs.prototype.ti,gs.prototype.markAsLastPartial=gs.prototype.Mg,gs.prototype.isPartial=gs.prototype.ui,gs.prototype.markAsPartial=gs.prototype.Ng,gs.prototype.isIndependent=gs.prototype.si,gs.prototype.markAsNonIndependent=gs.prototype.Pc,gs.prototype.isPreload=gs.prototype.isPreload,gs.prototype.markAsPreload=gs.prototype.Af,gs.prototype.markAsUnavailable=gs.prototype.Ai,gs.prototype.getStatus=gs.prototype.$b,gs.prototype.getTileDuration=gs.prototype.gi,gs.prototype.getTilesLayout=gs.prototype.hi,gs.prototype.getEndByte=gs.prototype.Xb,gs.prototype.getStartByte=gs.prototype.Zb,gs.prototype.getEndTime=gs.prototype.Ph,gs.prototype.getStartTime=gs.prototype.getStartTime,gs.prototype.getUris=gs.prototype.N;var _s=0,vs=1;function Ms(e){return 1==e.length&&1e-4>e.end(0)-e.start(0)}function ws(e){return!e||Ms(e)?null:e.length?e.end(e.length-1):null}function bs(e,t){return!(!e||!e.length||Ms(e)||t>e.end(e.length-1))&&t>=e.start(0)}function Ts(e,t){if(!e||!e.length||Ms(e))return 0;for(var n=0,i=(e=d(Ls(e))).next();!i.done;i=e.next()){var r=i.value;i=r.start,(r=r.end)>t&&(n+=r-Math.max(i,t))}return n}function Ls(e){if(!e)return[];for(var t=[],n=0;n<e.length;n++)t.push({start:e.start(n),end:e.end(n)});return t}function Ss(){}function ks(e,t){var n=document.createElement("source");return n.src=e,n.type=void 0===t?"":t,n}function Ds(e){for(;e.firstChild;)e.removeChild(e.firstChild)}function xs(){}function As(e,t){return t+10<=e.length&&73===e[t]&&68===e[t+1]&&51===e[t+2]&&255>e[t+3]&&255>e[t+4]&&128>e[t+6]&&128>e[t+7]&&128>e[t+8]&&128>e[t+9]}function Ys(e,t){return t+10<=e.length&&51===e[t]&&68===e[t+1]&&73===e[t+2]&&255>e[t+3]&&255>e[t+4]&&128>e[t+6]&&128>e[t+7]&&128>e[t+8]&&128>e[t+9]}function Es(e,t){var n=(127&e[t])<<21;return n|=(127&e[t+1])<<14,(n|=(127&e[t+2])<<7)|127&e[t+3]}function Is(e){var t={key:e.type,description:"",data:"",mimeType:null,pictureType:null};if("APIC"===e.type){if(2>e.size||3!==e.data[0])return null;var n=e.data.subarray(1).indexOf(0);if(-1===n)return null;var i=ct(pe(e.data,1,n)),r=e.data[2+n],a=e.data.subarray(3+n).indexOf(0);if(-1===a)return null;var s,o=ct(pe(e.data,3+n,a));return s="--\x3e"===i?ct(pe(e.data,4+n+a)):fe(e.data.subarray(4+n+a)),t.mimeType=i,t.pictureType=r,t.description=o,t.data=s,t}return"TXXX"===e.type||"WXXX"===e.type?2>e.size||3!==e.data[0]||-1===(i=e.data.subarray(1).indexOf(0))?null:(n=ct(pe(e.data,1,i)),e=ct(pe(e.data,2+i)).replace(/\0*$/,""),t.description=n,t.data=e,t):"PRIV"===e.type?2>e.size||-1===(n=e.data.indexOf(0))?null:(n=ct(pe(e.data,0,n)),t.description=n,"com.apple.streaming.transportStreamTimestamp"==n?(n=e.data.subarray(n.length+1),e=1&n[3],n=(n[4]<<23)+(n[5]<<15)+(n[6]<<7)+n[7],n/=45,e&&(n+=47721858.84),t.data=n):(e=fe(e.data.subarray(n.length+1)),t.data=e),t):"T"===e.type[0]?2>e.size||3!==e.data[0]?null:(e=ct(e.data.subarray(1)).replace(/\0*$/,""),t.data=e,t):"W"===e.type[0]?(e=ct(e.data).replace(/\0*$/,""),t.data=e,t):e.data?(t.data=fe(e.data),t):null}function Ps(e){for(var t=0,n=[];As(e,t);){var i=Es(e,t+6);for(e[t+5]>>6&1&&(t+=10),i=(t+=10)+i;t+10<i;){var r=e.subarray(t),a=Es(r,4);(a=Is(r={type:String.fromCharCode(r[0],r[1],r[2],r[3]),size:a,data:r.subarray(10,10+a)}))&&n.push(a),t+=r.size+10}Ys(e,t)&&(t+=10)}return n}function Cs(e,t){for(var n=t=void 0===t?0:t,i=0;As(e,t);)e[t+5]>>6&1&&(i+=10),i+=10,i+=Es(e,t+6),Ys(e,t+10)&&(i+=10),t+=i;return 0<i?e.subarray(n,n+i):new Uint8Array([])}function js(e,t){var n=null,i=null,r=null,a=e.P();return 1&t&&(r=e.Vc()),2&t&&e.skip(4),8&t&&(n=e.P()),16&t&&(i=e.P()),{trackId:a,ed:n,Ld:i,jk:r}}function Os(e,t){return 1==t?(t=e.P(),e=e.P(),{baseMediaDecodeTime:t*Math.pow(2,32)+e}):{baseMediaDecodeTime:e.P()}}function Rs(e,t){return 1==t?(e.skip(8),e.skip(8)):(e.skip(4),e.skip(4)),t=e.P(),e.skip(4),e=e.ma(),{timescale:t,language:String.fromCharCode(96+(e>>10))+String.fromCharCode(96+((960&e)>>5))+String.fromCharCode(96+(31&e))}}function Ns(e,t,n){var i=e.P(),r=[],a=null;1&n&&(a=e.P()),4&n&&e.skip(4);for(var s=0;s<i;s++){var o={Of:null,sampleSize:null,me:null};256&n&&(o.Of=e.P()),512&n&&(o.sampleSize=e.P()),1024&n&&e.skip(4),2048&n&&(o.me=0==t?e.P():e.Vg()),r.push(o)}return{nk:i,Zg:r,Ih:a}}function Hs(e){e.skip(6),e.skip(2),e.skip(8);var t=e.ma();return e.skip(2),e.skip(2),e.skip(2),{channelCount:t,sampleRate:e=e.ma()+e.ma()/65536}}function Us(e){return{codec:xa(e=e.P())}}function Fs(e,t){return t=void 0!==t&&t,e=e.toString(16).toUpperCase(),t?e:("0"+e).slice(-2)}function Bs(e){return(10>e?"0":"")+e}function Ws(e,t){if(this.j=e,void 0!==t&&t){t=new Uint8Array(e.byteLength);for(var n=0,i=0;i<e.byteLength;i++)2<=i&&3==e[i]&&0==e[i-1]&&0==e[i-2]||(t[n]=e[i],n++);this.j=pe(t,0,n)}this.i=this.j.byteLength,this.g=this.h=0}function zs(e){var t=e.j.byteLength-e.i,n=new Uint8Array(4),i=Math.min(4,e.i);0!==i&&(n.set(e.j.subarray(t,t+i)),e.h=new _a(n,0).P(),e.g=8*i,e.i-=i)}function Vs(e,t){if(e.g<=t){t-=e.g;var n=Math.floor(t/8);t-=8*n,e.g-=n,zs(e)}e.h<<=t,e.g-=t}function Gs(e,t){var n=Math.min(e.g,t),i=e.h>>>32-n;return e.g-=n,0<e.g?e.h<<=n:0<e.i&&zs(e),0<(n=t-n)?i<<n|Gs(e,n):i}function qs(e){var t;for(t=0;t<e.g;++t)if(e.h&2147483648>>>t)return e.h<<=t,e.g-=t,t;return zs(e),t+qs(e)}function $s(e){Vs(e,1+qs(e))}function Ks(e){return Gs(e,qs(e)+1)-1}function Js(e){return 1&(e=Ks(e))?1+e>>>1:-1*(e>>>1)}function Xs(e){return 1===Gs(e,1)}function Qs(e){return Gs(e,8)}function Zs(e,t){for(var n=8,i=8,r=0;r<t;r++)0!==i&&(i=(n+(i=Js(e))+256)%256),n=0===i?n:i}function eo(e){return Qs(e),Ks(e),Ks(e)}function to(){this.G=null,this.H=!1,this.m=this.I=null,this.j=[],this.g=[],this.A=this.B=null,this.i=[],this.h=[],this.C=null,this.l=[],this.F=this.o=this.s=null}function no(e,t){if(1!=(t[0]<<16|t[1]<<8|t[2]))return null;var n={data:new Uint8Array(0),packetLength:t[4]<<8|t[5],pts:null,dts:null,nalus:[]};if(n.packetLength&&n.packetLength>t.byteLength-6)return null;var i=t[7];if(192&i){var r=536870912*(14&t[9])+4194304*(255&t[10])+16384*(254&t[11])+128*(255&t[12])+(254&t[13])/2;null==e.s&&(e.s=r),n.pts=ro(r,e.s),e.s=n.pts,n.dts=n.pts,64&i&&(i=536870912*(14&t[14])+4194304*(255&t[15])+16384*(254&t[16])+128*(255&t[17])+(254&t[18])/2,null==e.o&&(e.o=i),n.dts=ro(i,e.o)),e.o=n.dts}return e=t[8]+9,t.byteLength<=e?null:(n.data=t.subarray(e),n)}function io(e){var t=e.sc();return 1<t.length&&(e=t[0].pts,t=t[1].pts,!isNaN(t-e))?String(1/(t-e)*9e4):null}function ro(e,t){var n=1;for(e>t&&(n=-1);4294967296<Math.abs(t-e);)e+=8589934592*n;return e}function ao(e){return!(0>so(e))}function so(e){for(var t=Math.min(1e3,e.length-564),n=0;n<t;){if(71==e[n]&&71==e[n+188]&&71==e[n+376])return n;n++}return-1}gs.Status={lj:_s,fk:vs,Hj:2},U("shaka.util.Dom",Ss),Ss.removeAllChildren=Ds,U("shaka.util.Id3Utils",xs),xs.getID3Data=Cs,xs.getID3Frames=Ps,U("shaka.util.ExpGolomb",Ws),(i=to.prototype).clearData=function(){this.j=[],this.g=[],this.i=[],this.h=[],this.l=[]},i.parse=function(e){if(564>e.length)return this;for(var t=Math.max(0,so(e)),n=e.length-(e.length+t)%188,i=!1,r=t;r<n;r+=188)if(71==e[r]){var a=!!(64&e[r+1]),s=((31&e[r+1])<<8)+e[r+2];if(1<(48&e[r+3])>>4){var o=r+5+e[r+4];if(o==r+188)continue}else o=r+4;switch(s){case 0:a&&(o+=e[o]+1),this.G=(31&e[o+10])<<8|e[o+11];break;case 17:case 8191:break;case this.G:a&&(o+=e[o]+1),s={audio:-1,video:-1,Td:-1,audioCodec:"",videoCodec:""};var u=o+3+((15&(a=e)[o+1])<<8|a[o+2])-4;for(o+=12+((15&a[o+10])<<8|a[o+11]);o<u;){var d=(31&a[o+1])<<8|a[o+2],l=(15&a[o+3])<<8|a[o+4];switch(a[o]){case 6:if(0<l)for(var c=o+5,h=l;2<h;){var m=a[c+1]+2;switch(a[c]){case 5:var f=gt(a.subarray(c+2,c+m));-1==s.audio&&"Opus"===f?(s.audio=d,s.audioCodec="opus"):-1==s.video&&"AV01"===f&&(s.video=d,s.videoCodec="av1");break;case 106:-1==s.audio&&(s.audio=d,s.audioCodec="ac3");break;case 122:-1==s.audio&&(s.audio=d,s.audioCodec="ec3");break;case 124:-1==s.audio&&(s.audio=d,s.audioCodec="aac");break;case 127:"opus"==s.audioCodec&&(f=null,128===a[c+2]&&(f=a[c+3]),null!=f&&(this.F={channelCount:15&f?15&f:2,Fh:f,sampleRate:48e3}))}c+=m,h-=m}break;case 15:-1==s.audio&&(s.audio=d,s.audioCodec="aac");break;case 17:-1==s.audio&&(s.audio=d,s.audioCodec="aac-loas");break;case 21:-1==s.Td&&(s.Td=d);break;case 27:-1==s.video&&(s.video=d,s.videoCodec="avc");break;case 3:case 4:-1==s.audio&&(s.audio=d,s.audioCodec="mp3");break;case 36:-1==s.video&&(s.video=d,s.videoCodec="hvc");break;case 129:-1==s.audio&&(s.audio=d,s.audioCodec="ac3");break;case 132:case 135:-1==s.audio&&(s.audio=d,s.audioCodec="ec3")}o+=l+5}-1!=(a=s).video&&(this.I=a.video,this.m=a.videoCodec),-1!=a.audio&&(this.B=a.audio,this.A=a.audioCodec),-1!=a.Td&&(this.C=a.Td),i&&!this.H&&(i=!1,r=t-188),this.H=!0;break;case this.I:o=e.subarray(o,r+188),a?this.j.push([o]):this.j.length&&this.j[this.j.length-1]&&this.j[this.j.length-1].push(o);break;case this.B:o=e.subarray(o,r+188),a?this.i.push([o]):this.i.length&&this.i[this.i.length-1]&&this.i[this.i.length-1].push(o);break;case this.C:o=e.subarray(o,r+188),a?this.l.push([o]):this.l.length&&this.l[this.l.length-1]&&this.l[this.l.length-1].push(o);break;default:i=!0}}return this},i.Gi=function(e){return se("TsParser.parseAvcNalus","Please use parseNalus function instead."),this.Gf(e)},i.Gf=function(e,t,n){var i=e.pts?e.pts/9e4:null,r=(e=e.data).byteLength,a=1;"hvc"==this.m&&(a=2);for(var s,o=n||0,u=[],d=-1,l=0,c=0;c<r;++c){var h=e[c];if(h){if(2<=o&&1==h){if(t&&!u.length&&-1==d&&(h=c-(3<o?3:o),n&&0!=h&&(h=e.subarray(0,h),t.data=ci(t.data,h),t.fullData=ci(t.fullData,h))),0<=d?(o=c-((3<o?3:o)+1),u.push({data:e.subarray(d+a,o+1),fullData:e.subarray(d,o+1),type:l,time:i})):t&&!u.length&&0<(d=c-o)&&(d=e.subarray(0,d),t.data=ci(t.data,d),t.fullData=ci(t.fullData,d)),c>=r-a)return u;d=++c,l="hvc"==this.m?e[c]>>1&63:31&e[c]}o=0}else o++;c>=r-1&&0<=d&&0<=o&&(s={data:e.subarray(d+a,r),fullData:e.subarray(d,r),type:l,time:i})}return s&&u.push(s),!u.length&&t&&(t.data=ci(t.data,e),t.fullData=ci(t.fullData,e)),u},i.getMetadata=function(){for(var e=[],t=d(this.l),n=t.next();!n.done;n=t.next())(n=no(this,n=ci.apply(ai,l(n.value))))&&e.push({cueTime:n.pts?n.pts/9e4:null,data:n.data,frames:Ps(n.data),dts:n.dts,pts:n.pts});return e},i.Wb=function(){if(this.i.length&&!this.h.length){for(var e=!1,t=d(this.i),n=t.next();!n.done;n=t.next()){var i=ci.apply(ai,l(n.value)),r=no(this,i);n=this.h.length?this.h[this.h.length-1]:null,r&&null!=r.pts&&null!=r.dts&&(!n||n.pts!=r.pts&&n.dts!=r.dts)?(this.h.length&&r.dts<(n.dts||0)&&(e=!0),this.h.push(r)):this.h.length&&(i=r?r.data:i)&&((n=this.h.pop()).data=ci(n.data,i),this.h.push(n))}e&&(this.h=this.h.sort((function(e,t){var n=(e.pts||0)-(t.pts||0);return(e.dts||0)-(t.dts||0)||n})))}return this.h},i.sc=function(e){if(e=void 0===e||e,this.j.length&&!this.g.length){for(var t=!1,n=d(this.j),i=n.next();!i.done;i=n.next()){var r=ci.apply(ai,l(i.value)),a=no(this,r);i=this.g.length?this.g[this.g.length-1]:null,a&&null!=a.pts&&null!=a.dts&&(!i||i.pts!=a.pts&&i.dts!=a.dts)?(this.g.length&&a.dts<(i.dts||0)&&(t=!0),this.g.push(a)):this.g.length&&(r=a?a.data:r)&&((i=this.g.pop()).data=ci(i.data,r),this.g.push(i))}if(e){for(n=[],r=(i=d(this.g)).next();!r.done;r=i.next())if((r=r.value).nalus=this.Gf(r,s,void 0),r.nalus.length){n.push(r);var s=r.nalus[r.nalus.length-1]}this.g=n}t&&(this.g=this.g.sort((function(e,t){var n=(e.pts||0)-(t.pts||0);return(e.dts||0)-(t.dts||0)||n})))}return e?this.g:(e=this.g,this.g=[],e)},i.getStartTime=function(e){if("audio"==e){e=null;var t=this.Wb();return t.length&&(e=t[0],e=Math.min(e.dts,e.pts)/9e4),e}return"video"==e?(e=null,(t=this.sc(!1)).length&&(e=t[0],e=Math.min(e.dts,e.pts)/9e4),e):null},i.fd=function(){return{audio:this.A,video:this.m}},i.Rd=function(){for(var e=[],t=d(this.sc()),n=t.next();!n.done;n=t.next())e.push.apply(e,l(n.value.nalus));return e},i.ki=function(){se("TsParser.getVideoResolution","Please use getVideoInfo function instead.");var e=this.nf();return{height:e.height,width:e.width}},i.nf=function(){return"hvc"==this.m?function(e){var t={height:null,width:null,codec:null,frameRate:null},n=e.Rd();if(!n.length)return t;if(!(n=n.find((function(e){return 33==e.type}))))return t;var i=new Ws(n.fullData,!0);Qs(i),Qs(i),Gs(i,4);var r=Gs(i,3);Xs(i);var a=Gs(i,2),s=Gs(i,1),o=Gs(i,5),u=Gs(i,32);n=Qs(i);for(var d=Qs(i),l=Qs(i),c=Qs(i),h=Qs(i),m=Qs(i),f=Qs(i),p=[],g=[],y=0;y<r;y++)p.push(Xs(i)),g.push(Xs(i));if(0<r)for(y=r;8>y;y++)Gs(i,2);for(y=0;y<r;y++)p[y]&&Gs(i,88),g[y]&&Qs(i);Ks(i),3==(r=Ks(i))&&Gs(i,1),p=Ks(i),g=Ks(i);var _=y=0,v=0,M=0;return Xs(i)&&(y+=Ks(i),_+=Ks(i),v+=Ks(i),M+=Ks(i)),t.width=String(p-(y+_)*(1===r||2===r?2:1)),t.height=String(g-(v+M)*(1===r?2:1)),i=function(e){for(var t=0,n=0;32>n;n++)t|=(e>>n&1)<<31-n;return t>>>0}(u),s=1==s?"H":"L",a="hvc1."+["","A","B","C"][a]+o,a+="."+i.toString(16).toUpperCase(),a+="."+s+f,m&&(a+="."+m.toString(16).toUpperCase()),h&&(a+="."+h.toString(16).toUpperCase()),c&&(a+="."+c.toString(16).toUpperCase()),l&&(a+="."+l.toString(16).toUpperCase()),d&&(a+="."+d.toString(16).toUpperCase()),n&&(a+="."+n.toString(16).toUpperCase()),t.codec=a,t.frameRate=io(e),t}(this):function(e){var t={height:null,width:null,codec:null,frameRate:null},n=e.Rd();if(!n.length)return t;if(!(n=n.find((function(e){return 7==e.type}))))return t;var i=Qs(n=new Ws(n.data)),r=Qs(n),a=Qs(n);if($s(n),oo.includes(i)){var s=Ks(n);if(3===s&&Vs(n,1),$s(n),$s(n),Vs(n,1),Xs(n)){s=3!==s?8:12;for(var o=0;o<s;o++)Xs(n)&&Zs(n,6>o?16:64)}}if($s(n),0===(s=Ks(n)))Ks(n);else if(1===s)for(Vs(n,1),$s(n),$s(n),s=Ks(n),o=0;o<s;o++)$s(n);$s(n),Vs(n,1),s=Ks(n),o=Ks(n);var u=Gs(n,1);0===u&&Vs(n,1),Vs(n,1);var d=0,l=0,c=0,h=0;return Xs(n)&&(d=Ks(n),l=Ks(n),c=Ks(n),h=Ks(n)),t.height=String((2-u)*(o+1)*16-2*c-2*h),t.width=String(16*(s+1)-2*d-2*l),t.codec="avc1."+("0"+i.toString(16).toUpperCase()).slice(-2)+("0"+r.toString(16).toUpperCase()).slice(-2)+("0"+a.toString(16).toUpperCase()).slice(-2),t.frameRate=io(e),t}(this)},U("shaka.util.TsParser",to),to.syncOffset=so,to.probe=ao,to.prototype.getVideoInfo=to.prototype.nf,to.prototype.getVideoResolution=to.prototype.ki,to.prototype.getVideoNalus=to.prototype.Rd,to.prototype.getCodecs=to.prototype.fd,to.prototype.getStartTime=to.prototype.getStartTime,to.prototype.getVideoData=to.prototype.sc,to.prototype.getAudioData=to.prototype.Wb,to.prototype.getMetadata=to.prototype.getMetadata,to.prototype.parseNalus=to.prototype.Gf,to.prototype.parseAvcNalus=to.prototype.Gi,to.prototype.parse=to.prototype.parse,to.prototype.clearData=to.prototype.clearData,to.Timescale=9e4;var oo=[100,110,122,244,44,83,86,118,128,138,139,134];function uo(e,t,n){this.g=null,this.o=-1,this.l=e,this.i=t,this.m=n,this.j=!1;e:{if("undefined"==typeof libDPIModule&&$("Could not find LCEVC Library dependencies on this page"),"undefined"!=typeof LCEVCdec)this.h=LCEVCdec;else{if("undefined"==typeof LcevcDil){$("Could not find LCEVC Library on this page"),e=!1;break e}this.h=LcevcDil,this.j=!0,se("LcevcDil","lcevc_dil.js is deprecated, please use lcevc_dec.js instead")}void 0===this.h.SupportObject?($("Could not find LCEVC Library on this page"),e=!1):(this.h.SupportObject.SupportStatus||$(this.h.SupportObject.SupportError),e=void 0!==this.h&&"undefined"!=typeof libDPIModule&&this.i instanceof HTMLCanvasElement&&this.h.SupportObject.SupportStatus)}e&&!this.g&&this.h.SupportObject.webGLSupport(this.i)&&(this.i.classList.remove("shaka-hidden"),this.g=this.j?new this.h.LcevcDil(this.l,this.i,this.m):new this.h.LCEVCdec(this.l,this.i,this.m))}function lo(e){e.g&&e.i.classList.add("shaka-hidden")}function co(e,t,n){var i=0,r=-1;switch(t.mimeType){case"video/webm":i=1;break;case"video/mp4":i=2}switch(n){case"DASH":r=1;break;case"HLS":r=0}e.g&&(e.o=t.id,e.g.setLevelSwitching(t.id,!0),e.g.setContainerFormat(i),e.j||e.g.setStreamingFormat(r))}function ho(e,t,n,i){var r=this;this.g=e,this.F=n,this.A=null,this.fa=t,this.i={},this.G={},this.Ka={},this.h=null,this.xa=!1,this.da=i||null,this.o={},this.s=new Z,this.j={},this.H=null,this.S=new Wr,this.Aa="",this.Na=!1,this.ta=!0,this.Z=!1,this.B=this.K=null,this.l=mo(this,this.S),this.I=!1,this.L=new ma((function(){return function(e){var t,n,i,r,a,s,o;return I((function(u){if(1==u.g){for(n in t=[],e.o)for(i=e.o[n],r=i[0],e.o[n]=i.slice(0,1),r&&t.push(r.p.catch(Bi)),a=d(i.slice(1)),s=a.next();!s.done;s=a.next())s.value.p.reject(new Ye(2,7,7003,void 0));return e.h&&t.push(e.h.destroy()),M(u,Promise.all(t),2)}for(o in e.j)e.j[o].destroy();e.s&&(e.s.release(),e.s=null),e.g&&e.B&&e.g.removeChild(e.B),e.g&&e.K&&(e.g.removeChild(e.K),e.g.load(),e.g.disableRemotePlayback=!1),e.g=null,e.K=null,e.B=null,e.A=null,e.l=null,e.h=null,e.fa=null,e.i={},e.j={},e.H=null,e.o={},e.da=null,e.Y={},e.F=null,w(u)}))}(r)})),this.C=!1,this.aa="UNKNOWN",this.Ga=this.La=!1,this.Ba=new Wr,this.m=!1,this.na=null,this.Y={},this.ja=this.M=this.ra=this.O=null,this.ga=new Wr,this.g.remote&&(this.Z="disconnected"!=this.g.remote.state,this.s.D(this.g.remote,"connect",(function(){r.Z="disconnected"!=r.g.remote.state})),this.s.D(this.g.remote,"connecting",(function(){r.Z="disconnected"!=r.g.remote.state})),this.s.D(this.g.remote,"disconnect",(function(){r.Z="disconnected"!=r.g.remote.state})))}function mo(t,n){if(t.ta=!0,e.ManagedMediaSource){t.B||(t.g.disableRemotePlayback=!0);var i=new ManagedMediaSource;t.s.D(i,"startstreaming",(function(){t.ta=!0})),t.s.D(i,"endstreaming",(function(){t.ta=!1}))}else i=new MediaSource;return t.s.pa(i,"sourceopen",(function(){URL.revokeObjectURL(t.Aa),n.resolve()})),t.s.pa(t.g,"playing",(function(){t.Na=!0})),t.Aa=Eo(i),t.g.removeAttribute("src"),t.K&&t.g.removeChild(t.K),t.B&&t.g.removeChild(t.B),t.K=ks(t.Aa),t.g.appendChild(t.K),t.B&&t.g.appendChild(t.B),t.g.load(),i}function fo(e,t,n,i){var r,a,s,o,u,l,c,h,m,f,p,g;return I((function(y){switch(y.g){case 1:return r=vi,a=F,s=B,M(y,function(e,t){var n,i,r,a,s,o,u,l,c,h;return I((function(m){if(1==m.g)return e.createSegmentIndex?M(m,e.createSegmentIndex(),2):m.u(2);if(!e.segmentIndex)return m.return(!1);if(0==e.segmentIndex.getNumReferences())return m.return(!0);for(n=vi,i=new Set,r=d(e.segmentIndex),a=r.next();!a.done;a=r.next())if(s=a.value,o=s.mimeType||e.mimeType||"",u=s.codecs||e.codecs||"",l=o+":"+u,!i.has(l))if(i.add(l),t==n.wa){if(!Ri(Ti(o,u)))return m.return(!1)}else if(t==n.la?u=lr(u):t==n.V&&(u=dr(u,o)),c=ki(e,o,u),h=Li(o,u),!ne(c)&&!On(h))return m.return(!1);return m.return(!0)}))}(n,t),2);case 2:if(s.call(a,y.h,"Type negotiation should happen before MediaSourceEngine.init!"),o=Ti(n.mimeType,i),t==r.wa){po(e,o,e.C,n.external),y.u(0);break}if(u=e.A.forceTransmux,(!ne(o)||!e.C&&ji.includes(o))&&(u=!0),l=Li(n.mimeType,i),!u){y.u(4);break}if(c=gi(r.V,(i||"").split(",")),h=gi(r.la,(i||"").split(",")),!c||!h){y.u(5);break}return e.m=!0,M(y,fo(e,r.V,n,c),6);case 6:return M(y,fo(e,r.la,n,h),7);case 7:return y.return();case 5:(m=On(l))&&(f=m(),e.j[t]=f,o=f.convertCodecs(t,l));case 4:p=o+e.A.addExtraFeaturesToSourceBuffer(o),fa(e.L);try{g=e.l.addSourceBuffer(p)}catch(t){throw new Ye(2,3,3015,t,"The mediaSource_ status was "+e.l.readyState+" expected 'open'",null)}e.C&&(g.mode=Io),e.s.D(g,"error",(function(){var n=e.o[t][0];n.p.reject(new Ye(2,3,3014,e.g.error?e.g.error.code:0,n.uri))})),e.s.D(g,"updateend",(function(){return So(e,t)})),e.i[t]=g,e.G[t]=o,e.Ka[t]=!!n.drmInfos.length,w(y)}}))}function po(e,t,n,i){e.h||(e.h=new Oi(e.fa),e.h&&(e.h.A=e.A.modifyCueCallback));var r=e.h;i=i||e.xa,e=e.aa,"application/cea-608"==t||"application/cea-708"==t?r.i=null:(r.i=(0,Ui[t])(),r.i.setSequenceMode?r.i.setSequenceMode(n):se("Text parsers w/ setSequenceMode",'Text parsers should have a "setSequenceMode" method!'),r.i.setManifestType?r.i.setManifestType(e):se("Text parsers w/ setManifestType",'Text parsers should have a "setManifestType" method!'),r.B=i)}function go(e){return!(e.I||e.l&&"ended"!=e.l.readyState)}function yo(e,t){return e=Object.keys(e.i).length?t==_i?e.h.g:!(e=vo(e,t))||Ms(e)?null:1==e.length&&0>e.start(0)?0:e.length?e.start(0):null:null}function _o(e,t){return Object.keys(e.i).length?t==_i?e.h.h:ws(vo(e,t)):null}function vo(e,t){if(e.I||e.Z)return null;try{return e.i[t].buffered}catch(e){return null}}function Mo(e,t,n,i,r,a,s,o,u,l){var c,h,m,f,p,g,y,_,v,b,T,L,S,k;return s=void 0!==s&&s,o=void 0!==o&&o,u=void 0!==u&&u,l=void 0!==l&&l,I((function(D){switch(D.g){case 1:if(t!=(c=vi).wa){D.u(2);break}if("HLS"!=e.aa){D.u(3);break}return M(D,e.Ba,4);case 4:h=D.h,e.h.s=h;case 3:return M(D,function(e,t,n,i,r){var a,s,o,u,l,c,h;return I((function(m){if(1==m.g)return M(m,Promise.resolve(),2);if(!e.i||!e.j)return m.return();if(null==n||null==i)return e.i.parseInit(pe(t)),m.return();for(a=e.B?n:e.s,s={periodStart:e.s,segmentStart:n,segmentEnd:i,vttOffset:a},o=e.i.parseMedia(pe(t),s,r,[]),u=d(o),l=u.next();!l.done;l=u.next())c=l.value,e.A(c,r||null,s);h=o.filter((function(t){return t.startTime>=e.l&&t.startTime<e.m})),e.j.append(h),null==e.g&&(e.g=Math.max(n,e.l)),e.h=Math.min(i,e.m),w(m)}))}(e.h,n,i?i.startTime:null,i?i.endTime:null,i?i.N()[0]:null),5);case 5:return D.return();case 2:if(l||!e.m){D.u(6);break}return M(D,Mo(e,c.V,n,i,r,a,s,o,u,!0),7);case 7:return M(D,Mo(e,c.la,n,i,r,a,s,o,u,!0),8);case 8:return D.return();case 6:if(!e.i[t])return D.return();if(m=e.i[t].timestampOffset,f=e.G[t],e.j[t]&&(f=e.j[t].getOriginalMimeType()),i&&(p=function(e,t,n,i,r,a){var s=null,o=[],u=pe(n);if(ji.includes(a))(t=Ps(u)).length&&i&&((n=t.find((function(e){return"com.apple.streaming.transportStreamTimestamp"===e.description})))&&(s=Math.round(n.data)/1e3),e.F.onMetadata([{cueTime:i.startTime,data:u,frames:t,dts:i.startTime,pts:i.startTime}],0,i.endTime));else if(a.includes("/mp4")&&i&&i.ba&&i.ba.timescale){var d=i.ba.timescale;if(!isNaN(d)){var l=0,c=!1;u=new wa,(null!=r.emsgSchemeIdUris&&0<r.emsgSchemeIdUris.length||e.A.dispatchAllEmsgBoxes)&&u.R("emsg",(function(t){var n=r.emsgSchemeIdUris;if(0===t.version)var a=t.reader.yc(),s=t.reader.yc(),o=t.reader.P(),u=t.reader.P(),d=t.reader.P(),l=t.reader.P(),c=i.startTime+u/o;else o=t.reader.P(),u=(c=t.reader.Vc()/o+i.timestampOffset)-i.startTime,d=t.reader.P(),l=t.reader.P(),a=t.reader.yc(),s=t.reader.yc();t=t.reader.vb(t.reader.getLength()-t.reader.ya()),(n&&n.includes(a)||e.A.dispatchAllEmsgBoxes)&&("urn:mpeg:dash:event:2012"==a?e.F.Fi():(n=c+d/o,(o=new Jr("emsg",o=(new Map).set("detail",{startTime:c,endTime:n,schemeIdUri:a,value:s,timescale:o,presentationTimeDelta:u,eventDuration:d,id:l,messageData:t}))).cancelable=!0,e.F.onEvent(o),o.defaultPrevented||"https://aomedia.org/emsg/ID3"!=a&&"https://developer.apple.com/streaming/emsg-id3"!=a||!(a=Ps(t)).length||e.F.onMetadata([{cueTime:c,data:t,frames:a,dts:c,pts:c}],0,n)))})),u.R("prft",(function(t){var n=t.reader,i=t.version;n.P(),t=1e3*(t=n.P())+n.P()/Math.pow(2,32)*1e3,0===i?n=n.P():(i=n.P(),n=n.P(),n=i*Math.pow(2,32)+n),t=new Date(new Date(Date.UTC(1900,0,1,0,0,0)).getTime()+t).getTime(),n=new Jr("prft",n=(new Map).set("detail",{wallClockTime:t,programStartDate:new Date(t-n/d*1e3)})),e.F.onEvent(n)})).box("moof",ba).box("traf",ba).R("tfdt",(function(e){l=Os(e.reader,e.version).baseMediaDecodeTime/d,c=!0,e.parser.stop()})).parse(n,!0),c&&0==i.timestampOffset&&(s=l)}}else a.includes("/mp4")||a.includes("/webm")||!ao(u)||(e.Y[t]?e.Y[t].clearData():e.Y[t]=new to,null!=(u=(o=e.Y[t].parse(u)).getStartTime(t))&&(s=u),o=o.getMetadata());return{timestamp:s,metadata:o}}(e,t,n,i,r,f),g=p.timestamp,y=p.metadata,null!=g&&(null==e.O&&t==c.la&&(e.O=g,e.ra=i.startTime,null!=e.M&&(_=0,e.ra==e.ja&&(_=e.O-e.M),e.ga.resolve(_))),null==e.M&&t==c.V&&(e.M=g,e.ja=i.startTime,null!=e.O&&(v=0,e.ra==e.ja&&(v=e.O-e.M),e.ga.resolve(v))),b=i.startTime-g,(.001<=Math.abs(m-b)||s||o)&&(!u||0<b||!m)&&(m=b,e.Ga&&(ko(e,t,(function(){return To(e,t)}),null),ko(e,t,(function(){return Lo(e,t,m)}),null))),(t==c.la||!(c.la in e.i))&&e.Ba.resolve(m)),y.length)&&e.F.onMetadata(y,m,i?i.endTime:null),a&&t==c.la&&(e.h||po(e,"application/cea-608",e.C,!1),e.H||(T=f.split(";",1)[0],e.H=new Me(T)),i?(L=e.H.i(n)).length&&function(e,t,n,i,r){for(var a=n+" "+i,s=new Map,o=(t=d(t)).next();!o.done;o=t.next()){var u=o.value;o=u.stream,u=u.cue,s.has(o)||s.set(o,new Map),s.get(o).has(a)||s.get(o).set(a,[]),Hi(e,u,r),u.startTime>=e.l&&u.startTime<e.m&&(s.get(o).get(a).push(u),o==e.C&&e.j.append([u]))}for(a=(r=d(s.keys())).next();!a.done;a=r.next())for(a=a.value,e.o.has(a)||e.o.set(a,new Map),o=(t=d(s.get(a).keys())).next();!o.done;o=t.next())o=o.value,u=s.get(a).get(o),e.o.get(a).set(o,u);e.g=null==e.g?Math.max(n,e.l):Math.min(e.g,Math.max(n,e.l)),e.h=Math.max(e.h,Math.min(i,e.m))}(e.h,L,i.startTime,i.endTime,m):e.H.init(n,o)),!e.j[t]){D.u(9);break}return M(D,e.j[t].transmux(n,r,i,e.l.duration,t),10);case 10:n=D.h;case 9:if(n=function(e,t,n,i,r){var a=null==n,s=e.Ka[i];return n=e.F.Uh(),(a=e.A.insertFakeEncryptionInInit&&a&&s)&&(n=je(n),a=ze()||We()||Ze()||Be()&&tt()&&n),a&&"mp4"==Di(e.G[i])&&(t=function(e,t){function n(){s=!0}function i(e){o.push(e),ba(e)}var r,a=e=pe(e),s=!1,o=[],u=[];if((new wa).box("moov",i).box("trak",i).box("mdia",i).box("minf",i).box("stbl",i).R("stsd",(function(e){r=e,o.push(e),Ta(e)})).R("encv",n).R("enca",n).R("dvav",(function(e){u.push({box:e,Ta:1701733238})})).R("dva1",(function(e){u.push({box:e,Ta:1701733238})})).R("dvh1",(function(e){u.push({box:e,Ta:1701733238})})).R("dvhe",(function(e){u.push({box:e,Ta:1701733238})})).R("dvc1",(function(e){u.push({box:e,Ta:1701733238})})).R("dvi1",(function(e){u.push({box:e,Ta:1701733238})})).R("hev1",(function(e){u.push({box:e,Ta:1701733238})})).R("hvc1",(function(e){u.push({box:e,Ta:1701733238})})).R("avc1",(function(e){u.push({box:e,Ta:1701733238})})).R("avc3",(function(e){u.push({box:e,Ta:1701733238})})).R("ac-3",(function(e){u.push({box:e,Ta:1701733217})})).R("ec-3",(function(e){u.push({box:e,Ta:1701733217})})).R("ac-4",(function(e){u.push({box:e,Ta:1701733217})})).R("mp4a",(function(e){u.push({box:e,Ta:1701733217})})).parse(e),s)return e;if(0==u.length||!r)throw li(e),new Ye(2,3,3019,t);u.reverse();for(var l=(t=d(u)).next();!l.done;l=t.next())l=l.value,a=cs(a,r,l.box,o,l.Ta);return Be()&&tt()&&!We()?((t=new Uint8Array(e.byteLength+a.byteLength)).set(a),t.set(e,a.byteLength),t):a}(t,r)),t}(e,n,i?i.startTime:null,t,i?i.N()[0]:null),!i||!e.C||t==c.wa){D.u(11);break}if(!s&&!o){D.u(11);break}if(S=i.startTime,"HLS"!=e.aa||e.m||t!=c.V||!e.i[c.la]){D.u(13);break}return M(D,e.ga,14);case 14:k=D.h,.1<Math.abs(k)&&(S-=k);case 13:ko(e,t,(function(){return To(e,t)}),null),ko(e,t,(function(){return Lo(e,t,S)}),null);case 11:return M(D,ko(e,t,(function(){var i=n;if("video"==t&&e.da){var r=e.da;r.g&&r.g.appendBuffer(i,"video",r.o,-m)}e.i[t].appendBuffer(i)}),i?i.N()[0]:null),15);case 15:w(D)}}))}function wo(e,t){var n;return I((function(i){return 1==i.g?t==(n=vi).wa?e.h?M(i,e.h.remove(0,1/0),0):i.return():M(i,ko(e,t,(function(){return bo(e,t,0,e.l.duration)}),null),4):e.m?M(i,ko(e,n.V,(function(){return bo(e,n.V,0,e.l.duration)}),null),0):i.u(0)}))}function bo(e,t,n,i){i<=n?So(e,t):e.i[t].remove(n,i)}function To(e,t){var n=e.i[t].appendWindowStart,i=e.i[t].appendWindowEnd;e.i[t].abort(),e.i[t].appendWindowStart=n,e.i[t].appendWindowEnd=i,So(e,t)}function Lo(e,t,n){0>n&&(n+=.001),e.i[t].timestampOffset=n,So(e,t)}function So(e,t){if(!e.I){var n=e.o[t][0];n&&(n.p.resolve(),xo(e,t))}}function ko(e,t,n,i){return fa(e.L),n={start:n,p:new Wr,uri:i},e.o[t].push(n),1==e.o[t].length&&Ao(e,t),n.p}function Do(e,t){var n,i,r,a,s,o,u,l,c,h;return I((function(m){switch(m.g){case 1:for(fa(e.L),n=[],i=Object.keys(e.i),r=d(i),a=r.next(),s={};!a.done;s={ready:void 0},a=r.next())o=a.value,s.ready=new Wr,u={start:function(e){return function(){return e.ready.resolve()}}(s),p:s.ready,uri:null},e.o[o].push(u),n.push(s.ready),1==e.o[o].length&&u.start();return b(m,2),M(m,Promise.all(n),4);case 4:L(m,3);break;case 2:throw S(m);case 3:return b(m,5,6),M(m,t(),6);case 6:for(k(m),l=d(i),c=l.next();!c.done;c=l.next())h=c.value,xo(e,h);D(m,0);break;case 5:throw new Ye(2,3,3015,S(m),e.g.error||"No error in the media element",null)}}))}function xo(e,t){e.o[t].shift(),Ao(e,t)}function Ao(e,t){var n=e.o[t][0];if(n)try{n.start()}catch(i){"QuotaExceededError"==i.name?n.p.reject(new Ye(2,3,3017,t)):n.p.reject(new Ye(2,3,3015,i,e.g.error||"No error in the media element",n.uri)),xo(e,t)}}function Yo(e,t){return Do(e,(function(){return function(e,t){var n,i,r,a,s,o,u,l,c,h,m,f,p,g,y,_,v,w;return I((function(b){switch(b.g){case 1:for(s in n=vi,e.I=!0,e.m=!1,i=e.g.currentTime,r=e.g.autoplay,a=e.g.paused,e.Na&&(e.g.autoplay=!1),T(b,2),e.s.Va(),e.j)e.j[s].destroy();for(o in e.i){u=e.i[o];try{e.l.removeSourceBuffer(u)}catch(e){}}return e.j={},e.i={},l=e.l.duration,e.S=new Wr,e.l=mo(e,e.S),M(b,e.S,4);case 4:!isNaN(l)&&l?e.l.duration=l:!isNaN(e.na)&&e.na&&(e.l.duration=e.na),c=new Wr,h=e.l.sourceBuffers,m=t.size,f=0,p=function(){++f===m&&(c.resolve(),e.s.cb(h,"addsourcebuffer",p))},e.s.D(h,"addsourcebuffer",p),g=d(t.keys()),y=g.next();case 5:return y.done?((w=t.get(n.V))&&w.isAudioMuxedInVideo&&(e.m=!0),e.m&&!e.o[n.V]&&(e.o[n.V]=[]),e.g.currentTime=i,M(b,c,2)):(_=y.value,v=t.get(_),M(b,fo(e,_,v,v.codecs),6));case 6:y=g.next(),b.u(5);break;case 2:k(b),e.I=!1,fa(e.L),e.s.pa(e.g,"canplaythrough",(function(){e.L.g||(e.g.autoplay=r,a||e.g.play())})),D(b,0)}}))}(e,t)}))}uo.prototype.release=function(){this.g&&(this.g.close(),this.g=null)},U("shaka.lcevc.Dec",uo),uo.prototype.release=uo.prototype.release,(i=ho.prototype).destroy=function(){return this.L.destroy()},i.init=function(e,t,n,i){t=void 0!==t&&t,n=void 0===n?"UNKNOWN":n,i=void 0!==i&&i;var r,a,s,o,u,l,c=this;return I((function(h){switch(h.g){case 1:return r=vi,M(h,c.S,2);case 2:c.C=t,c.aa=n,c.La=i,c.Ga=!c.C&&"HLS"==c.aa&&!c.La,c.Y={},c.O=null,c.ra=null,c.M=null,c.ja=null,c.ga=new Wr,a=d(e.keys()),s=a.next();case 3:if(s.done){h.u(5);break}return o=s.value,u=e.get(o),M(h,fo(c,o,u,u.codecs),6);case 6:c.m?(c.o[r.V]=[],c.o[r.la]=[]):c.o[o]=[],s=a.next(),h.u(3);break;case 5:(l=e.get(r.V))&&l.isAudioMuxedInVideo&&(c.m=!0),w(h)}}))},i.configure=function(e){this.A=e,this.h&&(this.h.A=e.modifyCueCallback)},i.zb=function(){var e={total:this.I?[]:Ls(this.g.buffered),audio:Ls(vo(this,"audio")),video:Ls(vo(this,"video")),text:[]};if(this.h){var t=this.h.g,n=this.h.h;null!=t&&null!=n&&e.text.push({start:t,end:n})}return e},i.remove=function(e,t,n){var i,r=this;return I((function(a){return 1==a.g?e==(i=vi).wa?M(a,r.h.remove(t,n),0):M(a,ko(r,e,(function(){return bo(r,e,t,n)}),null),4):r.m?M(a,ko(r,i.V,(function(){return bo(r,i.V,t,n)}),null),0):a.u(0)}))},i.flush=function(e){var t,n=this;return I((function(i){return 1==i.g?e==(t=vi).wa?i.return():M(i,ko(n,e,(function(){n.g.currentTime-=.001,So(n,e)}),null),2):n.m?M(i,ko(n,t.V,(function(){var e=t.V;n.g.currentTime-=.001,So(n,e)}),null),0):i.u(0)}))},i.endOfStream=function(e){var t=this;return I((function(n){return M(n,Do(t,(function(){go(t)||"closed"===t.l.readyState||(e?t.l.endOfStream(e):t.l.endOfStream())})),0)}))},i.bb=function(e){var t=this;return I((function(n){return M(n,Do(t,(function(){if(e<t.l.duration)for(var n in t.i){var i={start:function(){},p:new Wr,uri:null};t.o[n].unshift(i)}t.l.duration=e,t.na=e})),0)}))},i.getDuration=function(){return this.l.duration};var Eo=e.URL.createObjectURL,Io="sequence";function Po(e,t,n){this.i=e,this.C=t,this.o=this.l=1/0,this.h=1,this.g=this.j=null,this.A=0,this.B=!0,this.I=!1,this.H=0,this.F=void 0===n||n,this.G=0,this.s=!1,this.m=e}function Co(e,t,n){this.j=n,this.l=e,this.s=Oo(e),this.g=e.g.currentTime,this.m=Date.now()/1e3,this.h=!1,this.o=0,this.A=t,this.i=function(){}}function jo(e){this.g=e}function Oo(e){if(e.g.paused||0==e.g.playbackRate||0==e.g.buffered.length)var t=!1;else e:{t=e.g.currentTime;for(var n=(e=d(Ls(e.g.buffered))).next();!n.done;n=e.next())if(!(t<(n=n.value).start-.1||t>n.end-.5)){t=!0;break e}t=!1}return t}function Ro(e,t,n,i,r){var a=this;this.A=r,this.g=e,this.B=t,this.m=n,this.l=new Z,this.j=!1,this.F=e.readyState,this.C=this.i=0,this.h=i,this.s=!1,this.l.D(e,"waiting",(function(){return No(a)})),this.o=new He((function(){No(a)})).Ra(this.m.gapJumpTimerTime)}function No(e){if(0!=e.g.readyState){if(e.g.seeking){if(!e.j)return}else e.j=!1;if(!e.g.paused||e.g.currentTime==e.i&&(e.g.autoplay||e.g.currentTime!=e.i)){var t;if(e.g.readyState!=e.F&&(e.F=e.g.readyState),!(t=!e.h)){var n=(t=e.h).l,i=Oo(n),r=n.g.currentTime,a=Date.now()/1e3;t.g==r&&t.s==i||(t.m=a,t.g=r,t.s=i,t.h=!1),(i=(r=a-t.m)>=t.A&&i&&!t.h)&&(t.i(t.g,r),t.h=!0,t.g=n.g.currentTime,t.o++,t.j(new Jr("stalldetected"))),t=!i}t&&(t=e.g.currentTime,i=function(e,t,n){return e&&e.length&&!Ms(e)&&0<=(e=Ls(e).findIndex((function(e,i,r){return e.start>t&&(0==i||r[i-1].end-t<=n)})))?e:null}(n=e.g.buffered,t,e.m.gapDetectionThreshold),null!=i&&(0!=i||e.s))&&(r=n.start(i),(navigator.userAgent.match(/Edge\//)||We()||ze())&&(r=Math.ceil(100*(r+e.m.gapPadding))/100),r>=e.B.Bb()||.001>r-t||(0!=i&&n.end(i-1),e.g.currentTime=r,t==e.i&&(e.i=r),e.C++,e.A(new Jr("gapjumped"))))}}}function Ho(e,t,n,i){t==HTMLMediaElement.HAVE_NOTHING||e.readyState>=t?i():(t=Uo.value().get(t),n.pa(e,t,i))}(i=Po.prototype).getDuration=function(){return this.l},i.Wh=function(){return this.h},i.gh=function(e){this.i=e},i.bb=function(e){this.l=e},i.ai=function(){return this.i},i.eh=function(e){this.A=e},i.Bc=function(e){e&&!this.B&&(this.I=!0),this.B=e},i.pe=function(e){this.o=e},i.Qd=function(){return this.o},i.Sf=function(e){this.C=e},i.Oh=function(){return this.C},i.Rg=function(e,t){if(0!=e.length){var n=(Date.now()+this.A)/1e3;if(0!=(e=e.filter((function(e){return e.start+t<n}))).length){var i=e[e.length-1].end+t;this.be(e[0].start+t),this.h=e.reduce((function(e,t){return Math.max(e,t.end-t.start)}),this.h),this.g=Math.max(this.g,i),null!=this.i&&this.F&&!this.s&&(this.i=n-this.g-this.h)}}},i.vd=function(e){if(0!=e.length){for(var t=e[0].startTime,n=e[0].endTime,i=(Date.now()+this.A)/1e3,r=(e=d(e)).next();!r.done;r=e.next())i<(r=r.value).startTime||(t=Math.min(t,r.startTime),n=Math.max(n,r.endTime),this.h=Math.max(this.h,r.endTime-r.startTime));this.be(t),this.g=Math.max(this.g,n),null!=this.i&&this.F&&!this.s&&(this.i=i-this.g-this.h)}},i.Qg=function(e,t){this.be(e),1/0==t||this.U()||(this.g=Math.max(this.g,t))},i.Xh=function(){return this.g},i.Xd=function(){this.s=!0},i.vi=function(){return this.s},i.fh=function(e){this.m=e},i.Th=function(){return this.m},i.be=function(e){null==this.j?this.j=e:this.I||(this.j=Math.min(this.j,e))},i.Bf=function(e){this.h=Math.max(this.h,e)},i.offset=function(e){null!=this.j&&(this.j+=e),null!=this.g&&(this.g+=e)},i.U=function(){return 1/0==this.l&&!this.B},i.uc=function(){return 1/0!=this.l&&!this.B},i.qb=function(){return Math.max(this.H,this.Yb()-this.o)},i.jh=function(e){this.H=e},i.Yb=function(){return this.U()||this.uc()?Math.min(Math.max(0,(Date.now()+this.A)/1e3-this.h-this.i)+this.G,this.l):this.g?Math.min(this.g,this.l):this.l},i.jd=function(e){var t=Math.max(this.j,this.H);return 1/0==this.o?Math.ceil(1e3*t)/1e3:Math.max(t,Math.min(this.Yb()-this.o+e,this.Bb()))},i.Kb=function(){return this.jd(0)},i.Bb=function(){return Math.max(0,this.Yb()-(this.U()||this.uc()?this.C:0))},i.qh=function(){return!(null==this.i||null!=this.g&&this.F)},i.dh=function(e){this.G=e},i.Mh=function(){return this.G},U("shaka.media.PresentationTimeline",Po),Po.prototype.getAvailabilityTimeOffset=Po.prototype.Mh,Po.prototype.setAvailabilityTimeOffset=Po.prototype.dh,Po.prototype.usingPresentationStartTime=Po.prototype.qh,Po.prototype.getSeekRangeEnd=Po.prototype.Bb,Po.prototype.getSeekRangeStart=Po.prototype.Kb,Po.prototype.getSafeSeekRangeStart=Po.prototype.jd,Po.prototype.getSegmentAvailabilityEnd=Po.prototype.Yb,Po.prototype.setUserSeekStart=Po.prototype.jh,Po.prototype.getSegmentAvailabilityStart=Po.prototype.qb,Po.prototype.isInProgress=Po.prototype.uc,Po.prototype.isLive=Po.prototype.U,Po.prototype.offset=Po.prototype.offset,Po.prototype.notifyMaxSegmentDuration=Po.prototype.Bf,Po.prototype.notifyMinSegmentStartTime=Po.prototype.be,Po.prototype.getInitialProgramDateTime=Po.prototype.Th,Po.prototype.setInitialProgramDateTime=Po.prototype.fh,Po.prototype.isStartTimeLocked=Po.prototype.vi,Po.prototype.lockStartTime=Po.prototype.Xd,Po.prototype.getMaxSegmentEndTime=Po.prototype.Xh,Po.prototype.notifyPeriodDuration=Po.prototype.Qg,Po.prototype.notifySegments=Po.prototype.vd,Po.prototype.notifyTimeRange=Po.prototype.Rg,Po.prototype.getDelay=Po.prototype.Oh,Po.prototype.setDelay=Po.prototype.Sf,Po.prototype.getSegmentAvailabilityDuration=Po.prototype.Qd,Po.prototype.setSegmentAvailabilityDuration=Po.prototype.pe,Po.prototype.setStatic=Po.prototype.Bc,Po.prototype.setClockOffset=Po.prototype.eh,Po.prototype.getPresentationStartTime=Po.prototype.ai,Po.prototype.setDuration=Po.prototype.bb,Po.prototype.setPresentationStartTime=Po.prototype.gh,Po.prototype.getMaxSegmentDuration=Po.prototype.Wh,Po.prototype.getDuration=Po.prototype.getDuration,Co.prototype.release=function(){this.j=this.l=null,this.i=function(){}},Ro.prototype.release=function(){this.l&&(this.l.release(),this.l=null),null!=this.o&&(this.o.stop(),this.o=null),this.h&&(this.h.release(),this.h=null),this.g=this.B=this.A=null},Ro.prototype.Ef=function(){this.s=!0,No(this)};var Uo=new Ie((function(){return new Map([[HTMLMediaElement.HAVE_METADATA,"loadedmetadata"],[HTMLMediaElement.HAVE_CURRENT_DATA,"loadeddata"],[HTMLMediaElement.HAVE_FUTURE_DATA,"canplay"],[HTMLMediaElement.HAVE_ENOUGH_DATA,"canplaythrough"]])}));function Fo(e,t,n,i){var r=this;this.g=e,this.m=t,this.s=n,this.l=null,this.j=function(){return null==r.l&&(r.l=i()),r.l},this.o=!1,this.h=new Z,this.i=new Go(e),Ho(this.g,HTMLMediaElement.HAVE_METADATA,this.h,(function(){zo(r,r.j())}))}function Bo(e){return e.o?e.g.currentTime:e.j()}function Wo(e,t){0<e.g.readyState?qo(e.i,t):Ho(e.g,HTMLMediaElement.HAVE_METADATA,e.h,(function(){zo(e,e.j())}))}function zo(e,t){.001>Math.abs(e.g.currentTime-t)?Vo(e):(e.h.pa(e.g,"seeking",(function(){Vo(e)})),qo(e.i,e.g.currentTime&&0!=e.g.currentTime?e.g.currentTime:t))}function Vo(e){e.o=!0,e.h.D(e.g,"seeking",(function(){return e.m()})),e.s(e.g.currentTime)}function Go(e){var t=this;this.g=e,this.m=10,this.j=this.l=this.i=0,this.h=new He((function(){0>=t.i||t.g.currentTime!=t.l||t.g.currentTime===t.j?t.h.stop():(t.g.currentTime=t.j,t.i--)}))}function qo(e,t){e.l=e.g.currentTime,e.j=t,e.i=e.m,e.g.currentTime=t,e.h.Ra(.1)}function $o(e){this.h=e,this.j=!1,this.g=null,this.i=new Z}function Ko(e,t,n,i,r,a){var s=this;this.i=e,this.g=t.presentationTimeline,this.B=t.minBufferTime||0,this.l=n,this.A=r,this.s=null,this.o=function(e,t,n){if(!t.stallEnabled)return null;var i=t.stallSkip;return function(e,t){e.i=t}(t=new Co(new jo(e),t.stallThreshold,n),(function(){i?e.currentTime+=i:(e.pause(),e.play())})),t}(e,n,a),this.j=new Ro(e,t.presentationTimeline,n,this.o,a),this.h=new Fo(e,(function(){e:{var e=s.j;e.j=!0,e.s=!1;var t=Bo(s.h);if(e=Xo(s,t),.001<Math.abs(e-t)){if(t=!1,!qe()||qe()&&nt())t=!0;else{var n=Date.now()/1e3,i=qe()&&rt("Fuchsia")?3:1;(!s.s||s.s<n-i)&&(s.s=n,t=!0)}if(t){Wo(s.h,e),e=void 0;break e}}s.A(),e=void 0}return e}),(function(e){var t=s.j;t.g.seeking&&!t.j&&(t.j=!0,t.i=e)}),(function(){var e=i;return null==e?e=1/0>s.g.getDuration()?s.g.Kb():s.g.Bb():0>e&&(e=s.g.Bb()+e),Jo(s,Qo(s,e))})),this.m=new He((function(){if(0!=s.i.readyState&&!s.i.paused){var e=Bo(s.h),t=s.g.Kb(),n=s.g.Bb();3>n-t&&(t=n-3),e<t&&(e=Xo(s,e),s.i.currentTime=e)}}))}function Jo(e,t){var n=e.g.getDuration();return t>=n?n-e.l.durationBackoff:t}function Xo(e,t){var n=Math.max(e.B,e.l.rebufferingGoal),i=e.l.safeSeekOffset,r=e.g.Kb(),a=e.g.Bb(),s=e.g.getDuration();3>a-r&&(r=a-3);var o=e.g.jd(n),u=e.g.jd(i);return n=e.g.jd(n+i),t>=s?Jo(e,t):t>a?a-e.l.safeSeekEndOffset:t<r?bs(e.i.buffered,u)?u:n:t>=o||bs(e.i.buffered,t)?t:n}function Qo(e,t){var n=e.g.Kb();return t<n?n:t>(e=e.g.Bb())?e:t}function Zo(e){this.g=e,this.m=null,this.i=0,this.o=!1}function eu(e){return e.g[0]||null}function tu(e,t,n){return new Zo([e=new gs(e,e+t,(function(){return n}),0,null,null,e,e,e+t)])}function nu(e,t,n,i){this.i=e,this.h=t,this.g=n,this.reverse=i}function iu(){Zo.call(this,[]),this.h=[]}function ru(e){var t=this;this.g=e,this.j=!1,this.i=this.g.Pd(),this.h=new He((function(){t.g.Og(.25*t.i)}))}function au(e){e.h.stop();var t=e.j?0:e.i;if(0<=t)try{return void(e.g.Pd()!=t&&e.g.Vf(t))}catch(e){}e.h.Ra(.25),0!=e.g.Pd()&&e.g.Vf(0)}function su(e){var t=this;this.h=e,this.g=new Set,this.i=new He((function(){ou(t,!1)})).Ra(.25)}function ou(e,t){for(var n=d(e.g),i=n.next();!i.done;i=n.next())i.value.j(e.h.currentTime,t)}function uu(){this.g=null,this.h=[]}function du(e,t){var n=0;e.g&&e.g.state==t&&(n+=e.g.duration);for(var i=(e=d(e.h)).next();!i.done;i=e.next())n+=(i=i.value).state==t?i.duration:0;return n}function lu(){this.i=this.h=null,this.g=[]}function cu(e,t,n){e.i!=t&&(e.i=t,e.g.push({timestamp:Date.now()/1e3,id:t.id,type:"text",fromAdaptation:n,bandwidth:null}))}function hu(){this.kc=this.Kg=this.s=this.A=this.I=this.B=this.o=this.j=this.H=this.C=this.i=this.S=this.Y=this.L=this.M=this.O=this.l=this.m=NaN,this.K=0,this.F=this.G=NaN,this.g=new uu,this.h=new lu}function mu(e,t,n,i){this.m=e,this.i=t,this.l=n,this.h=new Map,this.j=new Map,this.g=null,this.o=i}function fu(e,t){e.l=t;for(var n=(e=d(e.h.values())).next();!n.done;n=e.next())n.value.g=t}function pu(e,t,n){if(n=void 0!==n&&n,!e.i.segmentIndex)return Promise.resolve();if(e.g||(e.g=e.i.segmentIndex.Jb(t,!0,e.o)),!e.g)return Promise.resolve();for(n&&e.g.next(),t=[];e.h.size<e.m&&(n=e.g.next().value);){var i=!0;n.isPreload()&&null!=n.va&&(i=!1),2==n.$b()&&(i=!1),n.pc()&&(i=!1),i&&n.ba&&t.push(gu(e,n.ba)),i&&!e.h.has(n)&&(i=new bu(e.l),t.push(Tu(i,n,e.i)),e.h.set(n,i))}return vu(e),Promise.all(t)}function gu(e,t){if(!e.i.segmentIndex||t.pc()||Array.from(e.j.keys()).some((function(e){return ps(e,t)})))return Promise.resolve();var n=new bu(e.l),i=Tu(n,t,e.i);return e.j.set(t,n),i}function yu(e,t){for(var n=(t=d(t.keys())).next();!n.done;n=t.next())(n=n.value)&&wu(e,n)}function _u(e){yu(e,e.h),yu(e,e.j),e.g=null}function vu(e){for(var t=Array.from(e.h.keys()),n=d(e.j.keys()),i=n.next(),r={};!i.done;r={rf:void 0},i=n.next())r.rf=i.value,t.some(function(e){return function(t){return ps(t.ba,e.rf)}}(r))||wu(e,r.rf)}function Mu(e,t){e.m=t;for(var n=Array.from(e.h.keys());n.length>t;){var i=n.pop();i&&wu(e,i)}vu(e)}function wu(e,t){var n=e.h;t instanceof fs&&(n=e.j),e=n.get(t),n.delete(t),e&&e.abort()}function bu(e){this.g=e,this.wd=this.Xf=null}function Tu(e,t,n){var i=new Uint8Array(0);return e.wd=e.g(t,n,(function(t){return I((function(n){if(1==n.g)return i=0<i.byteLength?ci(i,t):t,e.Xf?M(n,e.Xf(i),3):n.u(0);i=new Uint8Array(0),w(n)}))})),e.wd.promise.catch((function(e){return e instanceof Ye&&7001==e.code?Promise.resolve():Promise.reject(e)}))}function Lu(e){Zr.call(this);var t=this;this.g=new Set,this.i=e,this.h=new He((function(){for(var e=t.i(),n=d(t.g),i=n.next();!i.done;i=n.next())(i=i.value).endTime<e.start&&(t.g.delete(i),i=new Jr("regionremove",new Map([["region",i]])),t.dispatchEvent(i))})).Ra(2)}function Su(e){Zr.call(this),this.g=new Map,this.h=e}function ku(e,t,n){return!!((e=e.h()[n])&&0<e.length&&(n=e[e.length-1].end,t>=e[0].start&&t<n))}function Du(e){var t={bandwidth:e.bandwidth||0,audioSamplingRate:null,codecs:e.codecs,contentType:e.type,frameRate:null,height:null,mimeType:e.mimeType,channelsCount:null,pixelAspectRatio:null,width:null,label:null,roles:e.roles,language:null};return"video"==e.type&&(t.frameRate=e.frameRate||null,t.height=e.height||null,t.pixelAspectRatio=e.pixelAspectRatio||null,t.width=e.width||null),"audio"==e.type&&(t.audioSamplingRate=e.audioSamplingRate,t.channelsCount=e.channelsCount,t.label=e.label||null,t.language=e.language),t}function xu(e){var t=Yi(e);return{type:t.split("/")[0],mimeType:t,codecs:e=Ei(e),language:null,height:null,width:null,channelCount:null,sampleRate:null,closedCaptions:new Map,Cd:null,colorGamut:null,frameRate:null}}function Au(e){for(var t=new Set,n=[],i=(e=d(e)).next();!i.done;i=e.next()){var r=Ai(i=i.value);t.has(r)||(n.push(i),t.add(r))}return t=yi("audio",n),i=yi("video",n),e=yi(_i,n),i=function(e){if(1>=e.length)return e;var t=e.find((function(e){return e.startsWith("dvav.")||e.startsWith("dva1.")||e.startsWith("dvh1.")||e.startsWith("dvhe.")||e.startsWith("dav1.")||e.startsWith("dvc1.")||e.startsWith("dvi1.")}));return t?ne('video/mp4; codecs="'+t+'"')?[t]:e.filter((function(e){return e!=t})):e}(i),t=t.concat(i).concat(e),n.length&&!t.length?n:t}function Yu(t,n,i){var r,a,s,o,u;return I((function(d){if(1==d.g)return(r=n).cryptoKey?d.u(2):M(d,r.fetchKey(),3);if(!(a=r.iv))for(a=pe(new ArrayBuffer(16)),s=r.firstMediaSequenceNumber+i,o=a.byteLength-1;0<=o;o--)a[o]=255&s,s>>=8;return u="CBC"==n.blockCipherMode?{name:"AES-CBC",iv:a}:{name:"AES-CTR",counter:a,length:64},d.return(e.crypto.subtle.decrypt(u,r.cryptoKey,t))}))}function Eu(e,t,n,i,r){return e=aa(e,i,r),0==t&&null==n||(e.headers.Range=n?"bytes="+t+"-"+n:"bytes="+t+"-"),e}function Iu(e,t){var n=this;this.g=t,this.l=e,this.h=null,this.G=new Map,this.B=1,this.s=this.j=null,this.I=0,this.i=new Map,this.F=!1,this.K=null,this.A=!1,this.m=new ma((function(){return function(e){var t,n,i,r,a,s;return I((function(o){if(1==o.g){for(t=[],n=d(e.i.values()),i=n.next();!i.done;i=n.next())$u(r=i.value),t.push(Ku(r)),r.W&&(_u(r.W),r.W=null);for(a=d(e.o.values()),s=a.next();!s.done;s=a.next())_u(s.value);return M(o,Promise.all(t),2)}e.i.clear(),e.o.clear(),e.g=null,e.l=null,e.h=null,w(o)}))}(n)})),this.L=Date.now()/1e3,this.o=new Map,this.H={projection:null,hfov:null},this.O=0,this.M=1/0,this.C=null}function Pu(e,t){for(var n=0>e.g.ib(),i=d(e.i.values()),r=i.next();!r.done;r=i.next())(r=r.value).ia&&r.ia.Zc(n),r.W&&r.W.Zc(n);for(r=(i=d(e.o.values())).next();!r.done;r=i.next())r.value.Zc(n);(n=e.i.get("video"))&&(i=n.stream)&&(t?(t=i.trickModeVideo)&&!n.dc&&(Ou(e,t,!1,0,!1),n.dc=i):(t=n.dc)&&(n.dc=null,Ou(e,t,!0,0,!1)))}function Cu(e,t,n,i,r,a){n=void 0!==n&&n,i=void 0===i?0:i,r=void 0!==r&&r,a=void 0!==a&&a,e.j=t,e.F&&(t.video&&Ou(e,t.video,n,i,r,a),t.audio&&Ou(e,t.audio,n,i,r,a))}function ju(e,t){I((function(n){if(1==n.g)return e.C=null,e.s=t,e.F?t.segmentIndex?n.u(2):M(n,t.createSegmentIndex(),2):n.return();Ou(e,t,!0,0,!1),w(n)}))}function Ou(e,t,n,i,r,a){var s=e.i.get(t.type);s||t.type!=_i?s&&(s.dc&&(t.trickModeVideo?(s.dc=t,t=t.trickModeVideo):s.dc=null),s.stream!=t||r)&&(e.o.has(t)?s.W=e.o.get(t):s.W&&function(e,t){t&&t!==e.i&&(_u(e),e.i=t)}(s.W,t),t.type==_i&&(r=Ti(t.mimeType,t.codecs),po(e.g.ca,r,e.l.sequenceMode,t.external)),!e.o.has(s.stream)&&s.stream.closeSegmentIndex&&(s.Ea?(r="("+s.type+":"+s.stream.id+")",e.G.has(r)||e.G.set(r,s.stream.closeSegmentIndex)):s.stream.closeSegmentIndex()),r=s.stream.isAudioMuxedInVideo!=t.isAudioMuxedInVideo,s.stream=t,s.ia=null,s.jg=!!a,r?Xu(e,!0,!1):(n?s.bd?s.De=!0:s.Ea?(s.jc=!0,s.Kd=i,s.De=!0):($u(s),Gu(e,s,!0,i).catch((function(t){e.g&&e.g.onError(t)}))):s.Ea||s.eb||qu(e,s,0),function(e,t){var n,i;return I((function(r){if(1==r.g)return t.mb?(n=t.stream,i=t.mb,n.segmentIndex?r.u(2):M(r,n.createSegmentIndex(),2)):r.return();if(t.mb!=i||t.stream!=n)return r.return();var a=e.g.hd(),s=_o(e.g.ca,t.type),o=t.stream.segmentIndex.find(t.Sa?t.Sa.endTime:a),u=null==o?null:t.stream.segmentIndex.get(o);o=u&&u.va?u.va-u.Ja:null,u&&!o&&(o=(u.endTime-u.getStartTime())*(t.stream.bandwidth||0)/8),o?((u=u.ba)&&(o+=(u.va?u.va-u.Ja:null)||0),a=8*o/(u=e.g.getBandwidthEstimate())<(s||0)-a-Math.max(e.l.minBufferTime||0,e.h.rebufferingGoal)||t.mb.h.g>o):a=!1,a&&t.mb.abort(),w(r)}))}(e,s).catch((function(t){e.g&&e.g.onError(t)})))):function(e,t){var n,i,r,a,s;I((function(o){switch(o.g){case 1:return n=vi,e.I++,i=e.I,b(o,2),M(o,wo(e.g.ca,n.wa),4);case 4:L(o,3);break;case 2:r=S(o),e.g&&e.g.onError(r);case 3:a=Ti(t.mimeType,t.codecs),po(e.g.ca,a,e.l.sequenceMode,t.external),(e.g.ca.fa.isTextVisible()||e.h.alwaysStreamText)&&e.I==i&&(s=Nu(e,t),e.i.set(n.wa,s),qu(e,s,0)),w(o)}}))}(e,t)}function Ru(e,t){t.bd||t.jc||(t.Ea?(t.jc=!0,t.Kd=0):null==yo(e.g.ca,t.type)?null==t.eb&&qu(e,t,0):($u(t),Gu(e,t,!1,0).catch((function(t){e.g&&e.g.onError(t)}))))}function Nu(e,t){return{stream:t,type:t.type,ia:null,W:Hu(e,t),Sa:null,Oc:null,Wd:null,wc:null,vc:null,dc:null,endOfStream:!1,Ea:!1,eb:null,jc:!1,Kd:0,De:!1,bd:!1,Xc:!0,Kf:!1,ld:!1,mb:null}}function Hu(e,t){if("video"===t.type&&e.h.disableVideoPrefetch||"audio"===t.type&&e.h.disableAudioPrefetch||t.type===_i&&("application/cea-608"==t.mimeType||"application/cea-708"==t.mimeType)||t.type===_i&&e.h.disableTextPrefetch)return null;if(e.o.has(t))return e.o.get(t);var n=e.i.get(t.type);return(n=n&&n.W)&&t===n.i?n:0<e.h.segmentPrefetchLimit?new mu(e.h.segmentPrefetchLimit,t,(function(t,n,i){return Vu(t,n,i||null,e.h.retryParameters,e.g.Nb)}),0>e.g.ib()):null}function Uu(e,t,n,i,r,a,s,o){var u,d,l,c;return I((function(h){if(1==h.g)return u=vi,d=new Map,e.j.audio&&d.set(u.V,e.j.audio),e.j.video&&d.set(u.la,e.j.video),b(h,2),t.wc=i,t.vc=r,s&&(t.xf=s),o&&(t.yf=o),t.Wd=n,l=e.l.sequenceMode||"HLS"==e.l.type,M(h,function(e,t,n,i,r,a,s,o,u){var d,l;return I((function(c){return 1==c.g?t==(d=vi).wa?(a||(e.h.s=n),function(e,t,n){e.l=t,e.m=n}(e.h,i,r),c.return()):(l=[],M(c,function(e,t,n,i,r){var a,s,o,u,d,l,c,h,m,f,p,g,y,_,v;return I((function(w){return 1==w.g?t==(a=vi).wa?w.return(!1):(s=xi(Ei(e.G[t])),o=Yi(e.G[t]),d=!1,l=Ti(n,i),c=e.A.forceTransmux,(!ne(l)||!e.C&&ji.includes(l))&&(c=!0),c&&(h=Li(n,i),m=On(h))&&(u=m(),f=gi(a.V,(i||"").split(",")),p=gi(a.la,(i||"").split(",")),f&&p?(d=!0,g=p,t==a.V&&(g=f),l=u.convertCodecs(t,Li(n,g))):l=u.convertCodecs(t,h)),y=xi(Ei(l)),_=Yi(l),s===y&&o===_?(e.j[t]&&!u?(e.j[t].destroy(),delete e.j[t]):!e.j[t]&&u?e.j[t]=u:u&&(e.j[t]&&e.j[t].transmux!=u.transmux?(e.j[t].destroy(),delete e.j[t],e.j[t]=u):u.destroy()),w.return(!1)):(v=!0,(e.m||d&&u&&!e.j[t])&&(v=!1),v&&"smooth"===e.A.codecSwitchingStrategy&&ie()?M(w,function(e,t,n,i){return ko(e,t,(function(){t!==_i&&(ie()&&(e.j[t]&&(e.j[t].destroy(),delete e.j[t]),i&&(e.j[t]=i),e.i[t].changeType(n+e.A.addExtraFeaturesToSourceBuffer(n)),e.G[t]=n),So(e,t))}),null)}(e,t,l,u),3):(u&&u.destroy(),M(w,Yo(e,r),3)))):w.return(!0)}))}(e,t,s,o,u),2)):(c.h||(l.push(ko(e,t,(function(){return To(e,t)}),null)),e.m&&l.push(ko(e,d.V,(function(){return To(e,d.V)}),null))),a||(l.push(ko(e,t,(function(){return Lo(e,t,n)}),null)),e.m&&l.push(ko(e,d.V,(function(){return Lo(e,d.V,n)}),null))),l.push(ko(e,t,(function(){e.i[t].appendWindowStart=0,e.i[t].appendWindowEnd=r,e.i[t].appendWindowStart=i,So(e,t)}),null)),e.m&&l.push(ko(e,d.V,(function(){var t=d.V;e.i[t].appendWindowStart=0,e.i[t].appendWindowEnd=r,e.i[t].appendWindowStart=i,So(e,t)}),null)),M(c,Promise.all(l),0))}))}(e.g.ca,t.type,n,i,r,l,a.mimeType||t.stream.mimeType,a.codecs||t.stream.codecs,d),4);if(2!=h.g)return L(h,0);throw c=S(h),t.wc=null,t.vc=null,t.xf=null,t.yf=null,t.Wd=null,c}))}function Fu(e,t,n,i,r,a,s,o){var u,d,l,c,h,m;return s=void 0!==s&&s,o=void 0!==o&&o,I((function(f){switch(f.g){case 1:return u=i.closedCaptions&&0<i.closedCaptions.size,e.h.shouldFixTimestampOffset&&(l="video/mp4"==i.mimeType||"audio/mp4"==i.mimeType,c=null,r.ba&&(c=r.ba.timescale),(h=l&&c&&"video"===i.type&&"DASH"==e.l.type)&&(d=new wa),h&&d.box("moof",ba).box("traf",ba).R("tfdt",(function(n){var i,a,s,o,u;return I((function(d){return i=Os(n.reader,n.version),(a=i.baseMediaDecodeTime)?(s=-a/c,(Number(t.Wd)||0)<s?(o=t.wc,u=t.vc,M(d,Uu(e,t,s,o,u,r),0)):d.u(0)):d.return()}))})),h&&d.parse(a,!1,s)),M(f,Bu(e,t,n),2);case 2:return fa(e.m),m=t.Xc,t.Xc=!1,M(f,e.g.mg(t.type,a),3);case 3:return M(f,Mo(e.g.ca,t.type,a,r,i,u,m,o,s),4);case 4:fa(e.m),w(f)}}))}function Bu(e,t,n){var i,r,a,s;return I((function(o){return 1==o.g?((i=t.stream.segmentIndex)instanceof iu&&i.Ha(e.l.presentationTimeline.Kb()),r=Math.max(e.h.bufferBehind*e.B,e.l.presentationTimeline.h),null==(a=yo(e.g.ca,t.type))?(e.C==t&&(e.C=null),o.return()):(s=n-a-r)<=e.h.evictionGoal?o.return():M(o,e.g.ca.remove(t.type,a,a+s),2)):4!=o.g?(fa(e.m),e.C?M(o,Bu(e,e.C,n),4):o.u(0)):(fa(e.m),void w(o))}))}function Wu(e){return e&&e.type==_i&&("application/cea-608"==e.stream.mimeType||"application/cea-708"==e.stream.mimeType)}function zu(e,t,n,i){var r,a,s,o,u;return I((function(d){switch(d.g){case 1:if(r=n.pc())return d.return(r);if(a=null,t.W){var l=t.W,c=l.h;n instanceof fs&&(c=l.j),c.has(n)?(l=c.get(n),i&&(l.Xf=i),a=l.wd):a=null}return a||(a=Vu(n,t.stream,i||null,e.h.retryParameters,e.g.Nb)),s=0,t.ia&&(s=t.ia.h),t.mb=a,M(d,a.promise,2);case 2:if(o=d.h,t.mb=null,u=o.data,!n.aesKey){d.u(3);break}return M(d,Yu(u,n.aesKey,s),4);case 4:u=d.h;case 3:return d.return(u)}}))}function Vu(e,t,n,i,r,a){a=void 0!==a&&a;var s=e instanceof gs?e:void 0,o=s?1:0;return(e=Eu(e.N(),e.Ja,e.va,i,n)).contentType=t.type,r.request(la,e,{type:o,stream:t,segment:s,isPreload:a})}function Gu(e,t,n,i){var r,a;return I((function(s){return 1==s.g?(t.jc=!1,t.De=!1,t.Kd=0,t.bd=!0,t.Sa=null,t.ia=null,t.W&&!e.o.has(t.stream)&&_u(t.W),i?(r=e.g.hd(),a=e.g.ca.getDuration(),M(s,e.g.ca.remove(t.type,r+i,a),3)):M(s,wo(e.g.ca,t.type),4)):3!=s.g?(fa(e.m),n?M(s,e.g.ca.flush(t.type),3):s.u(3)):(fa(e.m),t.bd=!1,t.endOfStream=!1,t.Ea||t.eb||qu(e,t,0),void w(s))}))}function qu(t,n,i){var r=n.type;(r!=_i||t.i.has(r))&&(n.eb=new Ne((function(){var i;return I((function(r){return 1==r.g?(b(r,2),M(r,function(t,n){var i,r,a,s,o,u;return I((function(l){switch(l.g){case 1:if(fa(t.m),n.Ea||null==n.eb||n.bd)return l.return();if(n.eb=null,!n.jc){l.u(2);break}return M(l,Gu(t,n,n.De,n.Kd),3);case 3:return l.return();case 2:if(function(e,t){for(var n=d(e.G.entries()),i=n.next();!i.done;i=n.next()){var r=d(i.value);i=r.next().value,r=r.next().value,i.includes(t.type)&&(r(),e.G.delete(i))}}(t,n),n.stream.segmentIndex){l.u(4);break}return i=n.stream,b(l,5),M(l,n.stream.createSegmentIndex(),7);case 7:L(l,6);break;case 5:return r=S(l),M(l,Ju(t,n,r),8);case 8:return l.return();case 6:if(i!=n.stream)return i.closeSegmentIndex&&i.closeSegmentIndex(),n.Ea||n.eb||qu(t,n,0),l.return();case 4:b(l,9),a=function(t,n){if(Wu(n))return function(e,t){var n=_o(e,"video")||0;Ni(e.h,t,n)}(t.g.ca,n.stream.originalId||""),null;if(n.type==_i&&function(e){e.h&&Ni(e.h,"",0)}(t.g.ca),n.stream.isAudioMuxedInVideo)return null;if(!function(e){return e.ta&&!e.Z&&!e.I}(t.g.ca)&&n.type!=_i)return t.h.updateIntervalSeconds/2;var i=t.g.hd();if("audio"===n.type)for(var r=d(t.o.keys()),a=r.next();!a.done;a=r.next())(a=t.o.get(a.value)).Ha(i,!0),pu(a,i);r=n.Sa?n.Sa.endTime:i;var s=function(e,t,n){return t==_i?null==(e=e.h).h||e.h<n?0:e.h-Math.max(n,e.g):Ts(e=vo(e,t),n)}(t.g.ca,n.type,i),o=Math.max(1,Math.max(t.l.minBufferTime||0,t.h.rebufferingGoal,t.h.bufferingGoal)*t.B),u=t.l.presentationTimeline.getDuration()-r;if(a=_o(t.g.ca,n.type),1e-6>u&&a)return n.endOfStream=!0,"video"==n.type&&(t=t.i.get(_i))&&Wu(t)&&(t.endOfStream=!0),null;if(n.endOfStream=!1,s>=o)return t.h.updateIntervalSeconds/2;if(o=!n.ia,a=function(e,t,n,i){if(t.ia)return t.ia.current();if(t.Sa||i)return n=t.Sa?t.Sa.endTime:i,e=0>e.g.ib(),t.stream.segmentIndex&&(t.ia=t.stream.segmentIndex.Jb(n,!1,e)),t.ia&&t.ia.next().value;i=e.l.sequenceMode?0:e.h.inaccurateManifestTolerance;var r=Math.max(n-i,0);e=0>e.g.ib();var a=null;return i&&(t.stream.segmentIndex&&(t.ia=t.stream.segmentIndex.Jb(r,!1,e)),a=t.ia&&t.ia.next().value),a||(t.stream.segmentIndex&&(t.ia=t.stream.segmentIndex.Jb(n,!1,e)),a=t.ia&&t.ia.next().value),a}(t,n,i,a),!a)return t.h.updateIntervalSeconds;s=!1,o&&n.jg&&(s=!0,n.jg=!1),o=1/0;for(var l=(u=d(u=Array.from(t.i.values()))).next();!l.done;l=u.next())Wu(l=l.value)||l.ia&&!l.ia.current()||(o=Math.min(o,l.Sa?l.Sa.endTime:i));return r>=o+t.l.presentationTimeline.h?t.h.updateIntervalSeconds:(n.W&&n.ia&&!t.o.has(n.stream)&&(n.W.Ha(a.startTime),pu(n.W,a.startTime)),function(t,n,i,r,a){var s,o,u,d,l,c,h,m,f,p,g,y,_,v,T;return I((function(k){switch(k.g){case 1:if(s=vi,o=n.stream,u=n.ia,n.Ea=!0,b(k,2),2==r.$b())throw new Ye(1,1,1011);return M(k,function(e,t,n,i){var r,a,s,o,u,d,l,c,h,m,f,p,g,y,_,v;return I((function(w){switch(w.g){case 1:if(r=vi,a=null==t.Sa,s=[],o=Math.max(0,Math.max(n.appendWindowStart,e.O)-.1),u=Math.min(n.appendWindowEnd,e.M)+.01,d=n.codecs||t.stream.codecs,l=Ai(d),c=Yi(n.mimeType||t.stream.mimeType),(h=n.timestampOffset)==t.Wd&&o==t.wc&&u==t.vc&&l==t.xf&&c==t.yf){w.u(2);break}if(m=t.xf&&t.yf&&function(e,t,n,i){if(t==_i)var r=!1;else{r=xi(Ei(e.G[t]));var a=Yi(e.G[t]),s=Ti(n,i),o=e.A.forceTransmux;(!ne(s)||!e.C&&ji.includes(s))&&(o=!0),n=Li(n,i),o&&(o=On(n))&&(s=(o=o()).convertCodecs(t,n),o.destroy()),t=xi(Ei(s)),s=Yi(s),r=r!==t||a!==s}return!!r&&("smooth"!==e.A.codecSwitchingStrategy||!ie()||e.m)}(e.g.ca,t.type,c,d),!m){w.u(3);break}if(f=null,t.type===r.la?f=e.i.get(r.V):t.type===r.V&&(f=e.i.get(r.la)),!f){w.u(3);break}return M(w,Ku(f).catch((function(){})),5);case 5:f.Oc=null,f.wc=null,f.vc=null,Ru(e,f);case 3:return M(w,Uu(e,t,h,o,u,n,l,c),2);case 2:return ps(n.ba,t.Oc)||(t.Oc=n.ba,n.l&&n.ba&&(p=zu(e,t,n.ba),g=function(){var a,s,o,u,d,l;return I((function(c){switch(c.g){case 1:return b(c,2),M(c,p,4);case 4:return a=c.h,fa(e.m),s=null,o=new Map,u={projection:null,hfov:null},(new wa).box("moov",ba).box("trak",ba).box("mdia",ba).R("mdhd",(function(e){s=Rs(e.reader,e.version).timescale})).box("hdlr",(function(e){switch((e=e.reader).skip(8),e.yc()){case"soun":o.set(r.V,s);break;case"vide":o.set(r.la,s)}s=null})).box("minf",ba).box("stbl",ba).R("stsd",Ta).box("encv",La).box("avc1",La).box("avc3",La).box("hev1",La).box("hvc1",La).box("dvav",La).box("dva1",La).box("dvh1",La).box("dvhe",La).box("dvc1",La).box("dvi1",La).box("vexu",ba).box("proj",ba).R("prji",(function(e){e=e.reader.yc(),u.projection=e})).box("hfov",(function(e){e=e.reader.P()/1e3,u.hfov=e})).parse(a),function(e,t){if(e.H.projection!=t.projection||e.H.hfov!=t.hfov){if(null!=t.projection||null!=t.hfov){var n=(new Map).set("detail",t);n=new Jr("spatialvideoinfo",n)}else n=new Jr("nospatialvideoinfo");n.cancelable=!0,e.g.onEvent(n),e.H=t}}(e,u),o.has(t.type)?n.ba.timescale=o.get(t.type):null!=s&&(n.ba.timescale=s),d=t.stream.closedCaptions&&0<t.stream.closedCaptions.size,M(c,e.g.mg(t.type,a),5);case 5:return M(c,Mo(e.g.ca,t.type,a,null,t.stream,d,t.Xc,i),6);case 6:L(c,0);break;case 2:throw l=S(c),t.Oc=null,l}}))},y=n.startTime,a&&null!=(_=_o(e.g.ca,t.type))&&(y=_),e.g.Ei(y,n.ba),s.push(g()))),v=t.Sa?t.Sa.i:null,n.i!=v&&s.push(function(e,t,n){var i;return I((function(r){return 1==r.g?t==(i=vi).wa?r.return():(t==i.la&&(e.Ba=new Wr),e.C?(ko(e,t,(function(){return To(e,t)}),null),e.m&&ko(e,i.V,(function(){return To(e,i.V)}),null),M(r,ko(e,t,(function(){return Lo(e,t,n)}),null),2)):r.return()):e.m?M(r,ko(e,i.V,(function(){return Lo(e,i.V,n)}),null),0):r.u(0)}))}(e.g.ca,t.type,n.startTime)),M(w,Promise.all(s),0)}}))}(t,n,r,a),4);case 4:return fa(t.m),t.A?k.return():(d="video/mp4"==o.mimeType||"audio/mp4"==o.mimeType,l=e.ReadableStream,t.h.lowLatencyMode&&t.l.isLowLatency&&l&&d&&("HLS"!=t.l.type||r.m)?(h=new Uint8Array(0),f=m=!1,g=function(e){var s,u,d;return I((function(l){switch(l.g){case 1:if(m)return l.return();if(f=!0,fa(t.m),t.A)return l.return();if(b(l,2),h=function(e,t){var n=new Uint8Array(e.length+t.length);return n.set(e),n.set(t,e.length),n}(h,e),s=!1,u=0,(new wa).box("mdat",(function(e){u=e.size+e.start,s=!0})).parse(h,!1,!0),!s){l.u(4);break}return d=h.subarray(0,u),h=h.subarray(u),M(l,Fu(t,n,i,o,r,d,!0,a),5);case 5:n.W&&n.ia&&pu(n.W,r.startTime,!0);case 4:L(l,0);break;case 2:p=S(l),w(l)}}))},M(k,zu(t,n,r,g),9)):M(k,zu(t,n,r),7));case 7:return c=k.h,fa(t.m),t.A?k.return():(fa(t.m),n.jc?(n.Ea=!1,qu(t,n,0),k.return()):M(k,Fu(t,n,i,o,r,c,!1,a),6));case 9:if(y=k.h,p)throw p;if(f){k.u(10);break}return m=!0,fa(t.m),t.A?k.return():n.jc?(n.Ea=!1,qu(t,n,0),k.return()):M(k,Fu(t,n,i,o,r,y,!1,a),10);case 10:n.W&&n.ia&&pu(n.W,r.startTime,!0);case 6:if(fa(t.m),t.A)return k.return();n.Sa=r,u.next(),n.Ea=!1,n.Kf=!1,_=t.g.ca.zb(),v=_[n.type],JSON.stringify(v),n.jc||t.g.Ef(r,n.stream),qu(t,n,0),L(k,0);break;case 2:if(T=S(k),fa(t.m,T),t.A)return k.return();if(n.Ea=!1,7001==T.code)n.Ea=!1,$u(n),qu(t,n,0),k.u(0);else{if(n.type!=s.wa||!t.h.ignoreTextStreamFailures)return 3017==T.code?M(k,function(e,t,n){var i,r,a;return I((function(s){if(1==s.g){if(Array.from(e.i.values()).some((function(e){return e!=t&&e.Kf})))return s.u(2);if(i=0===e.h.maxDisabledTime&&1011==n.code?1:e.h.maxDisabledTime,e.g.disableStream(t.stream,i))return s.return();if(20<(r=Math.round(100*e.B)))e.B-=.2;else{if(!(4<r))return t.ld=!0,e.A=!0,e.g.onError(n),s.return();e.B-=.04}return t.Kf=!0,a=e.g.hd(),M(s,Bu(e,t,a),2)}qu(e,t,4),w(s)}))}(t,n,T),0):(n.ld=!0,1==T.category&&n.W&&wu(n.W,r),T.severity=2,M(k,Ju(t,n,T),0));t.i.delete(s.wa),k.u(0)}}}))}(t,n,i,a,s).catch((function(){})),null)}(t,n),null!=a&&(qu(t,n,a),n.ld=!1),L(l,10);break;case 9:return s=S(l),M(l,Ju(t,n,s),11);case 11:return l.return();case 10:if(o=Array.from(t.i.values()),!t.F||!o.every((function(e){return e.endOfStream}))){l.u(0);break}return M(l,t.g.ca.endOfStream(),13);case 13:fa(t.m),0!=(u=t.g.ca.getDuration())&&u<t.l.presentationTimeline.getDuration()&&t.l.presentationTimeline.bb(u),w(l)}}))}(t,n),4)):2!=r.g?L(r,0):(i=S(r),t.g&&t.g.onError(i),void w(r))}))})).$(i))}function $u(e){null!=e.eb&&(e.eb.stop(),e.eb=null)}function Ku(e){return I((function(t){return e.mb?M(t,e.mb.abort(),0):t.u(0)}))}function Ju(e,t,n){var i;return I((function(r){if(1==r.g)return M(r,Br(e.K),2);if(fa(e.m),1===n.category&&1003!=n.code){if(t.dc)return Pu(e,!1),r.return();i=0===e.h.maxDisabledTime&&1011==n.code?1:e.h.maxDisabledTime,n.handled=e.g.disableStream(t.stream,i),n.handled&&(n.severity=1)}n.handled&&1011==n.code||e.g.onError(n),n.handled||e.h.failureCallback(n),w(r)}))}function Xu(e,t,n){var i,r,a,s,o,u;return t=void 0!==t&&t,n=void 0===n||n,I((function(d){if(1==d.g){if(i=Date.now()/1e3,r=e.h.minTimeBetweenRecoveries,!t){if(!e.h.allowMediaSourceRecoveries||i-e.L<r)return d.return(!1);e.L=i}return a=vi,(s=e.i.get(a.V))&&(s.Oc=null,s.wc=null,s.vc=null,n&&Ru(e,s),Ku(s).catch((function(){})),s.ia&&s.ia.Mf()),(o=e.i.get(a.la))&&(o.Oc=null,o.wc=null,o.vc=null,n&&Ru(e,o),Ku(o).catch((function(){})),o.ia&&o.ia.Mf()),u=new Map,e.j.audio&&u.set(a.V,e.j.audio),e.j.video&&u.set(a.la,e.j.video),M(d,Yo(e.g.ca,u),2)}return!o||o.Ea||o.eb||qu(e,o,0),!s||s.Ea||s.eb||qu(e,s,0),d.return(!0)}))}function Qu(){}function Zu(e,t,n,i,r){var a,s=r in i,o=s?n.constructor==Object&&0==Object.keys(i).length:n.constructor==Object&&0==Object.keys(n).length,u=s||o,d=!0;for(a in t){var l=r+"."+a,c=s?i[r]:n[a];u||a in n?void 0===t[a]?void 0===c||u?delete e[a]:e[a]=kt(c):o?e[a]=t[a]:c.constructor==Object&&t[a]&&t[a].constructor==Object?(e[a]||(e[a]=kt(c)),l=Zu(e[a],t[a],c,i,l),d=d&&l):typeof t[a]!=typeof c||null==t[a]||"function"!=typeof t[a]&&t[a].constructor!=c.constructor?(q("Invalid config, wrong type for "+l),d=!1):("function"==typeof n[a]&&n[a].length!=t[a].length&&$("Unexpected number of arguments for "+l),e[a]=t[a]):(q("Invalid config, unrecognized key "+l),d=!1)}return d}function ed(e,t){for(var n={},i=n,r=0,a=0;!(0>(r=e.indexOf(".",r)));)0!=r&&"\\"==e[r-1]||(i[a=e.substring(a,r).replace(/\\\./g,".")]={},i=i[a],a=r+1),r+=1;return i[e.substring(a).replace(/\\\./g,".")]=t,n}function td(e,t){return e&&t}function nd(e,t){function n(e){return Array.isArray(e)&&0===e.length}function i(e){return e&&"object"==typeof e&&!Array.isArray(e)}return e=function e(t,r){return Object.keys(t).reduce((function(a,s){var o=t[s];return r.hasOwnProperty(s)?i(o)&&i(r[s])?(o=e(o,r[s]),(0<Object.keys(o).length||!i(o))&&(a[s]=o)):n(o)&&n(r[s])||Number.isNaN(o)&&Number.isNaN(r[s])||o!==r[s]&&(a[s]=o):a[s]=o,a}),{})}(e,t),function e(t){for(var r=d(Object.keys(t)),a=r.next();!a.done;a=r.next())i(t[a=a.value])&&0===Object.keys(t[a]).length||n(t[a])||"function"==typeof t[a]?delete t[a]:i(t[a])&&(e(t[a]),0===Object.keys(t[a]).length&&delete t[a])}(e),e}function id(){}function rd(e){return new Wn(e=mt(e)).Fb}function ad(e,t,n){function i(e){ye(a).setUint32(s,e.byteLength,!0),s+=4,a.set(pe(e),s),s+=e.byteLength}if(!n||!n.byteLength)throw new Ye(2,6,6015);var r;r="string"==typeof t?pt(t,!0):t,e=pt(e=mt(e),!0);var a=new Uint8Array(12+e.byteLength+r.byteLength+n.byteLength),s=0;return i(e),i(r),i(n),a}function sd(e,t,n){return"skd"!==t?e:(t=n.serverCertificate,ad(e,n=mt(e).split("skd://").pop(),t))}function od(e,t){2===e&&(t.headers["Content-Type"]="application/octet-stream")}function ud(){}function dd(){var t=1/0;navigator.connection&&navigator.connection.saveData&&(t=360);var n={retryParameters:{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4},servers:{},clearKeys:{},advanced:{},delayLicenseRequestUntilPlayed:!1,persistentSessionOnlinePlayback:!1,persistentSessionsMetadata:[],initDataTransform:function(e,t,n){return st()&&"skd"==t&&(t=n.serverCertificate,e=ad(e,n=rd(e),t)),e},logLicenseExchange:!1,updateExpirationTime:1,preferredKeySystems:[],keySystemsMapping:{},parseInbandPsshEnabled:We(),minHdcpVersion:"",ignoreDuplicateInitData:!rt("Tizen 2")};(We()||Xe())&&n.preferredKeySystems.push("com.microsoft.playready");var i="reload",r=!1;!ie()||ze()||Xe()||Je()||Ge()&&79===$e()||!(!qe()||qe()&&nt()||qe()&&rt("Fuchsia"))||tt()&&Be()||(i="smooth",r=!0),r={retryParameters:{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4},availabilityWindowOverride:NaN,disableAudio:!1,disableVideo:!1,disableText:!1,disableThumbnails:!1,disableIFrames:!1,defaultPresentationDelay:0,segmentRelativeVttTiming:!1,raiseFatalErrorOnManifestUpdateRequestFailure:!1,continueLoadingWhenPaused:!0,dash:{clockSyncUri:"",ignoreDrmInfo:!1,disableXlinkProcessing:!0,xlinkFailGracefully:!1,ignoreMinBufferTime:!1,autoCorrectDrift:!0,initialSegmentLimit:1e3,ignoreSuggestedPresentationDelay:!1,ignoreEmptyAdaptationSet:!1,ignoreMaxSegmentDuration:!1,keySystemsByURI:{"urn:uuid:1077efec-c0b2-4d02-ace3-3c1e52e2fb4b":"org.w3.clearkey","urn:uuid:e2719d58-a985-b3c9-781a-b030af78d30e":"org.w3.clearkey","urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":"com.widevine.alpha","urn:uuid:9a04f079-9840-4286-ab92-e65be0885f95":"com.microsoft.playready","urn:uuid:79f0049a-4098-8642-ab92-e65be0885f95":"com.microsoft.playready","urn:uuid:94ce86fb-07ff-4f43-adb8-93d2fa968ca2":"com.apple.fps"},manifestPreprocessor:cd,manifestPreprocessorTXml:hd,sequenceMode:!1,multiTypeVariantsAllowed:r,useStreamOnceInPeriodFlattening:!1,updatePeriod:-1,enableFastSwitching:!0},hls:{ignoreTextStreamFailures:!1,ignoreImageStreamFailures:!1,defaultAudioCodec:"mp4a.40.2",defaultVideoCodec:"avc1.42E01E",ignoreManifestProgramDateTime:!1,ignoreManifestProgramDateTimeForTypes:[],mediaPlaylistFullMimeType:'video/mp2t; codecs="avc1.42E01E, mp4a.40.2"',liveSegmentsDelay:3,sequenceMode:!(Ve()||rt("Tizen 2")||Ge()&&38===$e()||Xe()),ignoreManifestTimestampsInSegmentsMode:!1,disableCodecGuessing:!1,disableClosedCaptionsDetection:!1,updatePeriod:-1,allowLowLatencyByteRangeOptimization:!0},mss:{manifestPreprocessor:cd,manifestPreprocessorTXml:hd,sequenceMode:!1,keySystemsBySystemId:{"9a04f079-9840-4286-ab92-e65be0885f95":"com.microsoft.playready","79f0049a-4098-8642-ab92-e65be0885f95":"com.microsoft.playready"}}};var a={retryParameters:{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4},failureCallback:function(e){return td([e])},rebufferingGoal:2,bufferingGoal:10,bufferBehind:30,evictionGoal:1,ignoreTextStreamFailures:!1,alwaysStreamText:!1,startAtSegmentBoundary:!1,gapDetectionThreshold:.5,gapPadding:.01,gapJumpTimerTime:.25,durationBackoff:1,safeSeekOffset:5,safeSeekEndOffset:0,stallEnabled:!0,stallThreshold:1,stallSkip:.1,useNativeHlsForFairPlay:!0,inaccurateManifestTolerance:2,lowLatencyMode:!1,autoLowLatencyMode:!1,forceHTTP:!1,forceHTTPS:!1,minBytesForProgressEvents:16e3,preferNativeHls:!1,updateIntervalSeconds:1,observeQualityChanges:!1,maxDisabledTime:30,segmentPrefetchLimit:0,prefetchAudioLanguages:[],disableAudioPrefetch:!1,disableTextPrefetch:!1,disableVideoPrefetch:!1,liveSync:{enabled:!1,targetLatency:.5,targetLatencyTolerance:.5,maxPlaybackRate:1.1,minPlaybackRate:.95,panicMode:!1,panicThreshold:60,dynamicTargetLatency:{enabled:!1,stabilityThreshold:60,rebufferIncrement:.5,maxAttempts:10,maxLatency:4,minLatency:1}},allowMediaSourceRecoveries:!0,minTimeBetweenRecoveries:5,vodDynamicPlaybackRate:!1,vodDynamicPlaybackRateLowBufferRate:.95,vodDynamicPlaybackRateBufferRatio:.5,infiniteLiveStreamDuration:!1,preloadNextUrlWindow:30,loadTimeout:30,clearDecodingCache:Xe()||Je(),dontChooseCodecs:!1,shouldFixTimestampOffset:Ge()||ze()};(Ge()||ze()||qe()||Qe())&&(a.stallSkip=0),ze()&&(a.gapPadding=2);var s={trackSelectionCallback:function(e){return I((function(t){return t.return(e)}))},downloadSizeCallback:function(e){var t;return I((function(n){return 1==n.g?navigator.storage&&navigator.storage.estimate?M(n,navigator.storage.estimate(),3):n.return(!0):(t=n.h,n.return(t.usage+e<.95*t.quota))}))},progressCallback:function(e,t){return td([e,t])},usePersistentLicense:!0,numberOfParallelDownloads:5};t={enabled:!0,useNetworkInformation:!0,defaultBandwidthEstimate:1e6,switchInterval:8,bandwidthUpgradeTarget:.85,bandwidthDowngradeTarget:.95,restrictions:{minWidth:0,maxWidth:1/0,minHeight:0,maxHeight:t,minPixels:0,maxPixels:1/0,minFrameRate:0,maxFrameRate:1/0,minBandwidth:0,maxBandwidth:1/0,minChannelsCount:0,maxChannelsCount:1/0},advanced:{minTotalBytes:128e3,minBytes:16e3,fastHalfLife:2,slowHalfLife:5},restrictToElementSize:!1,restrictToScreenSize:!1,ignoreDevicePixelRatio:!1,clearBufferSwitch:!1,safeMarginSwitch:0,cacheLoadThreshold:20,minTimeToSwitch:Ke()?.5:0,preferNetworkInformationBandwidth:!1},i={codecSwitchingStrategy:i,addExtraFeaturesToSourceBuffer:function(e){return td([e],"")},forceTransmux:!1,insertFakeEncryptionInInit:!0,modifyCueCallback:function(e,t){return td([e,t])},dispatchAllEmsgBoxes:!1};var o=!1,u=!1,l=!0;it()&&(u=o=!0,l=!1);var c={drm:n,manifest:r,streaming:a,mediaSource:i,offline:s,abrFactory:function(){return new xr},abr:t,autoShowText:3,preferredAudioLanguage:"",preferredAudioLabel:"",preferredTextLanguage:"",preferredVariantRole:"",preferredTextRole:"",preferredAudioChannelCount:2,preferredVideoHdrLevel:"AUTO",preferredVideoLayout:"",preferredVideoLabel:"",preferredVideoCodecs:[],preferredAudioCodecs:[],preferredTextFormats:[],preferForcedSubs:!1,preferSpatialAudio:!1,preferredDecodingAttributes:[],restrictions:{minWidth:0,maxWidth:1/0,minHeight:0,maxHeight:1/0,minPixels:0,maxPixels:1/0,minFrameRate:0,maxFrameRate:1/0,minBandwidth:0,maxBandwidth:1/0,minChannelsCount:0,maxChannelsCount:1/0},playRangeStart:0,playRangeEnd:1/0,textDisplayer:{captionsUpdatePeriod:.25},textDisplayFactory:function(){return null},cmcd:{enabled:!1,sessionId:"",contentId:"",rtpSafetyFactor:5,useHeaders:!1,includeKeys:[]},cmsd:{enabled:!0,applyMaximumSuggestedBitrate:!0,estimatedThroughputWeightRatio:.5},lcevc:{enabled:!1,dynamicPerformanceScaling:!0,logLevel:0,drawLogo:!1},ads:{customPlayheadTracker:o,skipPlayDetection:u,supportsMultipleMediaElements:l,disableHLSInterstitial:!1,disableDASHInterstitial:!1},ignoreHardwareResolution:!1};return s.trackSelectionCallback=function(t){return I((function(n){return n.return(function(t,n,i){var r=i;"AUTO"==r&&(r=e.matchMedia("(color-gamut: p3)").matches?"PQ":"SDR");var a=t.filter((function(e){return!("variant"!=e.type||e.hdr&&e.hdr!=r)}));i=[];var s=Zi(n,a.map((function(e){return e.language})));s&&(i=a.filter((function(e){return Ki(e.language)==s}))),0==i.length&&(i=a.filter((function(e){return e.primary}))),0==i.length&&(a.map((function(e){return e.language})),i=a);var o=i.filter((function(e){return e.height&&480>=e.height}));for(o.length&&(o.sort((function(e,t){return t.height-e.height})),i=o.filter((function(e){return e.height==o[0].height}))),n=[],i.length&&(a=Math.floor(i.length/2),i.sort((function(e,t){return e.bandwidth-t.bandwidth})),n.push(i[a])),i=(t=d(t)).next();!i.done;i=t.next())(i=i.value).type!=_i&&"image"!=i.type||n.push(i);return n}(t,c.preferredAudioLanguage,c.preferredVideoHdrLevel))}))},c}function ld(e,t,n){var i={".drm.keySystemsMapping":"",".drm.servers":"",".drm.clearKeys":"",".drm.advanced":{distinctiveIdentifierRequired:!1,persistentStateRequired:!1,videoRobustness:"",audioRobustness:"",sessionType:"",serverCertificate:new Uint8Array(0),serverCertificateUri:"",individualizationServer:"",headers:{}}};return Zu(e,t,n||dd(),i,"")}function cd(e){return td([e],e)}function hd(e){return td([e],e)}function md(e,t,n,i){Zr.call(this),this.M=e,this.Y=t,this.Ba=i.networkingEngine,this.B=n,this.o=null,this.xa=0,this.La=i.Gc,this.F=i.yi,this.Na=i.zi,this.g=i.config,this.j=this.G=this.h=null,this.ga=!1,this.H=i.Ji,this.na=!1,this.l=null,this.da=!1,this.i=this.C=null,this.aa=!1,this.L=new Map,this.ta=!1,this.Aa=i.Ii,this.Z=new hu,this.fa=new Wr,this.m=new Wr,this.O=null,this.s=!1,this.Ka=i.Bh,this.ja=null,this.Ga=i.Ah,this.S=!1,this.K=[],this.I=[],this.A=!0}function fd(e,t,n){(e=t?e.I:e.K)?e.push(n):n()}function pd(e,t){if(e.O=t,e.S=!0,e.K)for(var n=(t=d(e.K)).next();!n.done;n=t.next())(n=n.value)();e.K=null}function gd(e){if(e.s)throw new Ye(2,7,7003)}function yd(e,t){e.dispatchEvent(new Jr("onstatechange",(new Map).set("state",t)))}function _d(e,t,n){var i,r,a,s,o;return I((function(u){return 1==u.g?(i=e.g.streaming.segmentPrefetchLimit||2,r=new mu(i,t,(function(t,n,i){return Vu(t,n,i||null,e.g.streaming.retryParameters,e.Ba,e.A)}),!1),e.L.set(t.id,r),M(u,t.createSegmentIndex(),2)):(a=e.B||0,(o=(s=t.segmentIndex.Jb(a))?s.current():null)||(o=eu(t.segmentIndex)),o?n?o.ba?M(u,gu(r,o.ba),0):u.u(0):M(u,pu(r,o.startTime),0):u.u(0))}))}function vd(e,t){Zr.call(this);var n=this;this.i=e,this.l=t,this.g=new Map,this.m=[{Ec:null,Dc:bd,tc:function(e,t){return Md(n,"enter",e,t)}},{Ec:wd,Dc:bd,tc:function(e,t){return Md(n,"enter",e,t)}},{Ec:Td,Dc:bd,tc:function(e,t){return Md(n,"enter",e,t)}},{Ec:bd,Dc:wd,tc:function(e,t){return Md(n,"exit",e,t)}},{Ec:bd,Dc:Td,tc:function(e,t){return Md(n,"exit",e,t)}},{Ec:wd,Dc:Td,tc:function(e,t){return Md(n,"skip",e,t)}},{Ec:Td,Dc:wd,tc:function(e,t){return Md(n,"skip",e,t)}}],this.h=new Z,this.h.D(this.i,"regionremove",(function(e){n.g.delete(e.region)}))}function Md(e,t,n,i){t=new Jr(t,new Map([["region",n],["seeking",i]])),e.dispatchEvent(t)}Fo.prototype.release=function(){this.h&&(this.h.release(),this.h=null),null!=this.i&&(this.i.release(),this.i=null),this.m=function(){},this.g=null},Go.prototype.release=function(){this.h&&(this.h.stop(),this.h=null),this.g=null},(i=$o.prototype).ready=function(){var e=this;Ho(this.h,HTMLMediaElement.HAVE_CURRENT_DATA,this.i,(function(){!function(){if(null==e.g||0==e.g&&1/0!=e.h.duration)e.j=!0;else{var t=e.h.currentTime,n=e.g;0>e.g&&(n=Math.max(0,t+e.g)),t!=n?(e.i.pa(e.h,"seeking",(function(){e.j=!0})),e.h.currentTime=n):e.j=!0}}()}))},i.release=function(){this.i&&(this.i.release(),this.i=null),this.h=null},i.Ie=function(e){this.g=this.j?this.g:e},i.Dd=function(){return(this.j?this.h.currentTime:this.g)||0},i.ig=function(){return 0},i.hg=function(){return 0},i.Pg=function(){},(i=Ko.prototype).ready=function(){this.m.Ra(.25)},i.release=function(){this.h&&(this.h.release(),this.h=null),this.j&&(this.j.release(),this.j=null),this.m&&(this.m.stop(),this.m=null),this.i=this.h=this.g=this.l=null,this.A=function(){}},i.Ie=function(e){Wo(this.h,e)},i.Dd=function(){var e=Bo(this.h);return 0<this.i.readyState&&!this.i.paused?Qo(this,e):e},i.ig=function(){return this.o?this.o.o:0},i.hg=function(){return this.j.C},i.Pg=function(){this.j.Ef()},(i=Zo.prototype).getNumReferences=function(){return this.g.length},i.getNumEvicted=function(){return this.i},i.release=function(){this.o||(this.g=[],this.m&&this.m.stop(),this.m=null)},i.Bi=function(){this.o=!0},i.yb=function(e){for(var t=d(this.g),n=t.next();!n.done;n=t.next())e(n.value)},i.find=function(e){for(var t=this.g.length-1,n=t;0<=n;--n){var i=this.g[n],r=n<t?this.g[n+1].startTime:i.endTime;if(e>=i.startTime&&e<r)return n+this.i}return this.g.length&&e<this.g[0].startTime?this.i:null},i.get=function(e){return 0==this.g.length||0>(e-=this.i)||e>=this.g.length?null:this.g[e]},i.offset=function(e){if(!this.o)for(var t=d(this.g),n=t.next();!n.done;n=t.next())n.value.offset(e)},i.Zd=function(e){if(!this.o&&e.length){var t=Math.round(1e3*e[0].startTime)/1e3;this.g=this.g.filter((function(e){return Math.round(1e3*e.startTime)/1e3<t})),this.g.push.apply(this.g,l(e))}},i.td=function(e,t){var n=this;e=e.filter((function(e){return e.endTime>t&&(0==n.g.length||e.endTime>n.g[0].startTime)})),this.Zd(e),this.Ha(t)},i.Ha=function(e){if(!this.o){var t=this.g.length;this.g=this.g.filter((function(t){return t.endTime>e})),this.i+=t-this.g.length}},i.Kc=function(e,t,n){if(n=void 0!==n&&n,!this.o){for(;this.g.length&&this.g[this.g.length-1].startTime>=t;)this.g.pop();for(;this.g.length&&this.g[0].endTime<=e;)this.g.shift(),n||this.i++;0!=this.g.length&&((t=new gs((e=this.g[this.g.length-1]).startTime,t,e.C,e.Ja,e.va,e.ba,e.timestampOffset,e.appendWindowStart,e.appendWindowEnd,e.g,e.tilesLayout,e.A,e.h,e.status,e.aesKey)).mimeType=e.mimeType,t.codecs=e.codecs,t.i=e.i,this.g[this.g.length-1]=t)}},i.ue=function(e,t){var n=this;this.o||(this.m&&this.m.stop(),this.m=new He((function(){var e=t();e?n.g.push.apply(n.g,l(e)):(n.m.stop(),n.m=null)})),this.m.Ra(e))},Zo.prototype[Symbol.iterator]=function(){return this.Jb(0)},Zo.prototype.Jb=function(e,t,n){t=void 0!==t&&t,n=void 0!==n&&n;var i=this.find(e);if(null==i)return null;var r=this.get(i);n?i++:i--;var a=-1;if(r&&0<r.g.length)for(var s=r.g.length-1;0<=s;--s){var o=r.g[s];if(e>=o.startTime&&e<o.endTime){if(!t){for(;s&&!o.l;)s--,o=r.g[s];if(!o.l)return q("No independent partial segment found!"),null}n?i--:i++,a=s-1;break}}return new nu(this,i,a,n)},U("shaka.media.SegmentIndex",Zo),Zo.forSingleSegment=tu,Zo.prototype.getIteratorForTime=Zo.prototype.Jb,Zo.prototype.updateEvery=Zo.prototype.ue,Zo.prototype.fit=Zo.prototype.Kc,Zo.prototype.evict=Zo.prototype.Ha,Zo.prototype.mergeAndEvict=Zo.prototype.td,Zo.prototype.offset=Zo.prototype.offset,Zo.prototype.get=Zo.prototype.get,Zo.prototype.find=Zo.prototype.find,Zo.prototype.markImmutable=Zo.prototype.Bi,Zo.prototype.release=Zo.prototype.release,Zo.prototype.getNumEvicted=Zo.prototype.getNumEvicted,Zo.prototype.getNumReferences=Zo.prototype.getNumReferences,(i=nu.prototype).Zc=function(e){this.reverse=e},i.Hh=function(){return this.h},i.current=function(){var e=this.i.get(this.h);return e&&0<e.g.length&&e.s&&this.g>=e.g.length&&(this.h++,this.g=0,e=this.i.get(this.h)),e&&0<e.g.length?e.g[this.g]:e},i.next=function(){var e=this.i.get(this.h);return this.reverse?e&&0<e.g.length?(this.g--,0>this.g&&(this.h--,this.g=(e=this.i.get(this.h))&&0<e.g.length?e.g.length-1:0)):(this.h--,this.g=0):e&&0<e.g.length?(this.g++,e.s&&this.g==e.g.length&&(this.h++,this.g=0)):(this.h++,this.g=0),{value:e=this.current(),done:!e}},i.Mf=function(){var e=this.current();if(e.o&&!e.l&&(e=this.i.get(this.h))&&0<e.g.length)for(var t=e.g[this.g];t.l&&!(0>=this.g);)this.g--,t=e.g[this.g]},U("shaka.media.SegmentIterator",nu),nu.prototype.resetToLastIndependent=nu.prototype.Mf,nu.prototype.next=nu.prototype.next,nu.prototype.current=nu.prototype.current,nu.prototype.currentPosition=nu.prototype.Hh,nu.prototype.setReverse=nu.prototype.Zc,g(iu,Zo),(i=iu.prototype).clone=function(){var e=new iu;return e.h=this.h.slice(),e.i=this.i,e},i.release=function(){for(var e=d(this.h),t=e.next();!t.done;t=e.next())t.value.release();this.h=[]},i.yb=function(e){for(var t=d(this.h),n=t.next();!n.done;n=t.next())n.value.yb(e)},i.find=function(e){for(var t=this.i,n=d(this.h),i=n.next();!i.done;i=n.next()){var r=(i=i.value).find(e);if(null!=r)return r+t;t+=i.getNumEvicted()+i.getNumReferences()}return null},i.get=function(e){for(var t=this.i,n=d(this.h),i=n.next();!i.done;i=n.next()){var r=(i=i.value).get(e-t);if(r)return r;r=i.getNumReferences(),t+=i.getNumEvicted()+r}return null},i.offset=function(){},i.Zd=function(){},i.Ha=function(e){for(var t=d(this.h),n=t.next();!n.done;n=t.next())n.value.Ha(e);for(;1<this.h.length&&0==this.h[0].getNumReferences();)e=this.h.shift(),this.i+=e.getNumEvicted(),e.release()},i.td=function(){},i.Kc=function(){},i.ue=function(){},U("shaka.media.MetaSegmentIndex",iu),iu.prototype.updateEvery=iu.prototype.ue,iu.prototype.fit=iu.prototype.Kc,iu.prototype.mergeAndEvict=iu.prototype.td,iu.prototype.evict=iu.prototype.Ha,iu.prototype.merge=iu.prototype.Zd,iu.prototype.offset=iu.prototype.offset,iu.prototype.get=iu.prototype.get,iu.prototype.find=iu.prototype.find,iu.prototype.forEachTopLevelReference=iu.prototype.yb,iu.prototype.release=iu.prototype.release,ru.prototype.release=function(){this.set(this.oc()),this.h&&(this.h.stop(),this.h=null),this.g=null},ru.prototype.set=function(e){this.i=e,au(this)},ru.prototype.oc=function(){return this.g.oc()},su.prototype.release=function(){this.i.stop();for(var e=d(this.g),t=e.next();!t.done;t=e.next())t.value.release();this.g.clear()},mu.prototype.Ha=function(e,t){t=void 0!==t&&t;for(var n=d(this.h.keys()),i=n.next();!i.done;i=n.next())e>(i=i.value).endTime&&wu(this,i);t&&vu(this)},mu.prototype.Zc=function(e){this.o=e,this.g&&this.g.Zc(e)},bu.prototype.abort=function(){this.wd&&this.wd.abort()},g(Lu,Zr),Lu.prototype.release=function(){this.g.clear(),this.h.stop(),Zr.prototype.release.call(this)},g(Su,Zr),Su.prototype.release=function(){this.g.clear(),Zr.prototype.release.call(this)},Su.prototype.j=function(e){for(var t=d(this.g.values()),n=t.next();!n.done;n=t.next()){var i=(n=n.value).Se;e:{for(var r=n.yd,a=r.length-1;0<=a;a--){var s=r[a];if(s.position<=e){r=s.Qc;break e}}r=null}a=r&&!(i===r||i&&r&&i.bandwidth==r.bandwidth&&i.audioSamplingRate==r.audioSamplingRate&&i.codecs==r.codecs&&i.contentType==r.contentType&&i.frameRate==r.frameRate&&i.height==r.height&&i.mimeType==r.mimeType&&i.channelsCount==r.channelsCount&&i.pixelAspectRatio==r.pixelAspectRatio&&i.width==r.width),s=r&&i&&r.label&&i.label&&i.label!==r.label;var o=r&&i&&r.language&&i.language&&i.language!==r.language;i=r&&i&&r.roles&&i.roles&&!Ae(i.roles,r.roles),(s||o||i)&&ku(this,e,r.contentType)&&(n.Se=r,i=new Jr("audiotrackchange",new Map([["quality",r],["position",e]])),this.dispatchEvent(i)),a&&ku(this,e,r.contentType)&&(n.Se=r,JSON.stringify(r),n=new Jr("qualitychange",new Map([["quality",r],["position",e]])),this.dispatchEvent(n))}},(i=Iu.prototype).destroy=function(){return this.m.destroy()},i.configure=function(e){if(this.h=e,this.K=new Fr({maxAttempts:Math.max(e.retryParameters.maxAttempts,2),baseDelay:e.retryParameters.baseDelay,backoffFactor:e.retryParameters.backoffFactor,fuzzFactor:e.retryParameters.fuzzFactor,timeout:0,stallTimeout:0,connectionTimeout:0},!0),e.disableAudioPrefetch){var t=this.i.get("audio");t&&t.W&&(_u(t.W),t.W=null);for(var n=(t=d(this.o.keys())).next();!n.done;n=t.next())n=n.value,_u(this.o.get(n)),this.o.delete(n)}for(e.disableTextPrefetch&&(t=this.i.get(_i))&&t.W&&(_u(t.W),t.W=null),e.disableVideoPrefetch&&(t=this.i.get("video"))&&t.W&&(_u(t.W),t.W=null),n=(t=d(this.i.keys())).next();!n.done;n=t.next())(n=this.i.get(n.value)).W?(Mu(n.W,e.segmentPrefetchLimit),0<e.segmentPrefetchLimit||(_u(n.W),n.W=null)):0<e.segmentPrefetchLimit&&(n.W=Hu(this,n.stream));e.disableAudioPrefetch||function(e){for(var t=e.h.segmentPrefetchLimit,n=e.h.prefetchAudioLanguages,i=d(e.l.variants),r=i.next(),a={};!r.done;a={pb:void 0},r=i.next())if(a.pb=r.value,a.pb.audio)if(e.o.has(a.pb.audio)){if(Mu(r=e.o.get(a.pb.audio),t),!(0<t&&n.some(function(e){return function(t){return Gi(e.pb.audio.language,t)}}(a)))){var s=e.i.get(a.pb.audio.type);r!==(s&&s.W)&&_u(r),e.o.delete(a.pb.audio)}}else 0>=t||!n.some(function(e){return function(t){return Gi(e.pb.audio.language,t)}}(a))||!(r=Hu(e,a.pb.audio))||(a.pb.audio.segmentIndex||a.pb.audio.createSegmentIndex(),e.o.set(a.pb.audio,r))}(this)},i.start=function(e){var t=this;return I((function(n){if(1==n.g)return M(n,function(e,t){var n,i,r,a,s,o,u,l,c;return I((function(h){if(1==h.g){if(n=vi,!e.j)throw new Ye(2,5,5006);return i=new Map,r=new Set,e.j.audio&&(i.set(n.V,e.j.audio),r.add(e.j.audio)),e.j.video&&(i.set(n.la,e.j.video),r.add(e.j.video)),e.s&&(i.set(n.wa,e.s),r.add(e.s)),M(h,e.g.ca.init(i,e.l.sequenceMode,e.l.type,e.l.ignoreManifestTimestampsInSegmentsMode),2)}for(fa(e.m),e.updateDuration(),a=d(i.keys()),s=a.next();!s.done;s=a.next())o=s.value,u=i.get(o),e.i.has(o)||(l=Nu(e,u),t.has(u.id)&&(fu(c=t.get(u.id),(function(t,n,i){return Vu(t,n,i||null,e.h.retryParameters,e.g.Nb)})),l.W=c),e.i.set(o,l),qu(e,l,0));w(h)}))}(t,e||new Map),2);fa(t.m),t.F=!0,w(n)}))},i.Xc=function(){if(this.g)for(var e=this.g.hd(),t=d(this.i.keys()),n=t.next();!n.done;n=t.next()){var i=n.value;n=this.i.get(i);var r=this.g.ca;if(!(r=i==_i?null!=(r=r.h).g&&null!=r.h&&e>=r.g&&e<r.h:bs(r=vo(r,i),e))){if(n.W&&(n.W.g=null),"audio"===n.type)for(var a=(r=d(this.o.values())).next();!a.done;a=r.next())a.value.g=null;n.ia=null,(null!=_o(this.g.ca,i)||n.Ea)&&Ru(this,n),n.mb&&(n.mb.abort(),n.mb=null),i===_i&&(i=this.g.ca).H&&i.H.g(),n.Xc=!0}}},i.updateDuration=function(){var e=this.l.presentationTimeline.getDuration();1/0>e?this.g.ca.bb(e):this.g.ca.bb(this.h.infiniteLiveStreamDuration?1/0:Math.pow(2,32))},U("shaka.util.ConfigUtils",Qu),Qu.getDifferenceFromConfigObjects=nd,Qu.convertToConfigObject=ed,Qu.mergeConfigObjects=Zu,U("shaka.util.FairPlayUtils",id),id.commonFairPlayResponse=function(e,t){if(2===e){try{var n=ct(t.data)}catch(e){return}e=!1,"<ckc>"===(n=n.trim()).substr(0,5)&&"</ckc>"===n.substr(-6)&&(n=n.slice(5,-6),e=!0);try{var i=JSON.parse(n);i.ckc&&(n=i.ckc,e=!0),i.CkcMessage&&(n=i.CkcMessage,e=!0),i.License&&(n=i.License,e=!0)}catch(e){}e&&(t.data=fe(ui(n)))}},id.expressplayFairPlayRequest=function(e,t){od(e,t)},id.conaxFairPlayRequest=function(e,t){od(e,t)},id.ezdrmFairPlayRequest=function(e,t){od(e,t)},id.verimatrixFairPlayRequest=function(e,t){2===e&&(e=oi(e=pe(t.body)),t.headers["Content-Type"]="application/x-www-form-urlencoded",t.body=ft("spc="+e))},id.expressplayInitDataTransform=function(e,t,n){return sd(e,t,n)},id.conaxInitDataTransform=function(t,n,i){if("skd"!==n)return t;n=i.serverCertificate,i=mt(t).split("skd://").pop().split("?").shift(),i=e.atob(i);var r=new ArrayBuffer(2*i.length);r=ge(r);for(var a=0,s=i.length;a<s;a++)r[a]=i.charCodeAt(a);return ad(t,r,n)},id.ezdrmInitDataTransform=function(e,t,n){return"skd"!==t?e:(t=n.serverCertificate,ad(e,n=mt(e).split(";").pop(),t))},id.verimatrixInitDataTransform=function(e,t,n){return sd(e,t,n)},id.initDataTransform=ad,id.defaultGetContentId=rd,id.isFairPlaySupported=function(){var e;return I((function(t){return 1==t.g?(e={initDataTypes:["cenc","sinf","skd"],videoCapabilities:[{contentType:'video/mp4; codecs="avc1.42E01E"'}]},b(t,2),M(t,navigator.requestMediaKeySystemAccess("com.apple.fps",[e]),4)):2!=t.g?t.return(!0):(S(t),t.return(!1))}))},U("shaka.util.PlayerConfiguration",ud),ud.mergeConfigObjects=ld,ud.createDefault=dd,g(md,Zr),(i=md.prototype).getStartTime=function(){return this.B},i.Mc=function(){return this.M},i.kf=function(){return this.h},i.getStats=function(){return this.Z},i.start=function(){var e,t=this;I((function(n){switch(n.g){case 1:return M(n,Promise.resolve(),2);case 2:return b(n,3),M(n,function(e){var t,n,i,r;return I((function(a){switch(a.g){case 1:if(yd(e,"manifest-parser"),e.j||(e.G=ds(e.M,e.Y),e.j=e.G(),e.j.configure(e.g.manifest,(function(){return e.A}))),t=Date.now()/1e3,yd(e,"manifest"),e.h){a.u(2);break}return M(a,e.j.start(e.M,e.Na),3);case 3:e.h=a.h;case 2:return e.fa.resolve(),n=new Jr("manifestparsed",void 0),M(a,Promise.resolve(),4);case 4:if(e.dispatchEvent(n),0==e.h.variants.length)throw new Ye(2,4,4036);!function(e){function t(e){return e.video&&e.audio||e.video&&e.video.codecs.includes(",")}e.variants.some(t)&&(e.variants=e.variants.filter(t))}(e.h),i=Date.now()/1e3,r=i-t,e.Z.H=r,w(a)}}))}(t),5);case 5:return gd(t),M(n,function(e){var t,n,i;return I((function(r){switch(r.g){case 1:if(yd(e,"drm-engine"),e.xa=Date.now()/1e3,e.l=e.La(),e.F.h=e.l,e.l.configure(e.g.drm,(function(){return e.A})),!is(e.F,e.h)){r.u(2);break}return t=new Jr("trackschanged",void 0),M(r,Promise.resolve(),3);case 3:gd(e),e.dispatchEvent(t);case 2:return n=vr(e.h.variants),M(r,ja(e.l,n,e.h.offlineSessionIds),4);case 4:return gd(e),M(r,ns(e.F,e.h),5);case 5:if(!r.h){r.u(0);break}return i=new Jr("trackschanged",void 0),M(r,Promise.resolve(),7);case 7:e.dispatchEvent(i),w(r)}}))}(t),6);case 6:return gd(t),M(n,function(e){var t,n,i,r,a,s;return I((function(o){return e.o||(e.o=new Or(e.g.preferredAudioLanguage,e.g.preferredVariantRole,e.g.preferredAudioChannelCount,e.g.preferredVideoHdrLevel,e.g.preferSpatialAudio,e.g.preferredVideoLayout,e.g.preferredAudioLabel,e.g.preferredVideoLabel,e.g.mediaSource.codecSwitchingStrategy,"")),e.Ga&&(t=e.g.abrFactory,e.C=t,e.i=t(),e.i.configure(e.g.abr)),e.Ka?(n=e.h.presentationTimeline.U(),i=vr(e.h.variants),r=e.o.create(i),e.i.configure(e.g.abr),e.i.setVariants(Array.from(r.values())),(a=e.i.chooseVariant())?(s=[],e.ja=a,a.video&&s.push(_d(e,a.video,n)),a.audio&&s.push(_d(e,a.audio,n)),M(o,Promise.all(s),0)):o.u(0)):o.u(0)}))}(t),7);case 7:return gd(t),M(n,function(e){return I((function(t){return 1==t.g?e.K?M(t,e.m,3):t.u(0):M(t,Promise.all(e.Y.map((function(e){return e.promise}))),0)}))}(t.l),8);case 8:gd(t),t.m.resolve(),L(n,0);break;case 3:(e=S(n))instanceof Ye&&(7001==e.code||7003==e.code)||t.m.reject(e),w(n)}}))},i.dispatchEvent=function(e){return this.O?this.O.dispatchEvent(e):Zr.prototype.dispatchEvent.call(this,e)},i.onError=function(e){2===e.severity&&(this.m.reject(e),this.destroy());var t=(new Map).set("detail",e);t=new Jr("error",t),this.dispatchEvent(t),t.defaultPrevented&&(e.handled=!0)},i.configure=function(e,t){e=ed(e,t),ld(this.g,e)},i.getConfiguration=function(){return kt(this.g)},i.jj=function(){return this.m},i.destroy=function(){var e,t,n=this;return I((function(i){switch(i.g){case 1:if(n.s=!0,!n.j||n.ga){i.u(2);break}return M(i,n.j.stop(),2);case 2:if(!n.i||n.aa){i.u(4);break}return M(i,n.i.stop(),4);case 4:if(n.H&&!n.na&&n.H.release(),!n.l||n.da){i.u(6);break}return M(i,n.l.destroy(),6);case 6:if(0<n.L.size&&!n.ta)for(e=d(n.L.values()),t=e.next();!t.done;t=e.next())_u(t.value);w(i)}}))},U("shaka.media.PreloadManager",md),md.prototype.destroy=md.prototype.destroy,md.prototype.waitForFinish=md.prototype.jj,g(vd,Zr),vd.prototype.release=function(){this.i=null,this.g.clear(),this.h.release(),this.h=null,Zr.prototype.release.call(this)},vd.prototype.j=function(e,t){if(!this.l||0!=e){this.l=!1;for(var n=d(this.i.g),i=n.next();!i.done;i=n.next()){i=i.value;var r=this.g.get(i),a=e<i.startTime?wd:e>i.endTime?Td:bd;this.g.set(i,a);for(var s=d(this.m),o=s.next();!o.done;o=s.next())(o=o.value).Ec==r&&o.Dc==a&&o.tc(i,t)}}};var wd=1,bd=2,Td=3;function Ld(e,t,n){var i,r,a,s,o,u,d;return I((function(l){switch(l.g){case 1:var c=new Wn(e).Ua.split("/").pop().split(".");return i=1==c.length?"":c.pop().toLowerCase(),(r=Sd[i])?l.return(r):(a=0,s=aa([e],n),b(l,2),s.method="HEAD",M(l,t.request(a,s).promise,4));case 4:o=l.h,r=o.headers["content-type"],L(l,3);break;case 2:if(!(u=S(l))||1002!=u.code&&1001!=u.code){l.u(3);break}return s.method="GET",M(l,t.request(a,s).promise,6);case 6:d=l.h,r=d.headers["content-type"];case 3:return l.return(r?r.toLowerCase().split(";").shift():"")}}))}var Sd={mp4:"video/mp4",m4v:"video/mp4",m4a:"audio/mp4",webm:"video/webm",weba:"audio/webm",mkv:"video/webm",ts:"video/mp2t",ogv:"video/ogg",ogg:"audio/ogg",mpg:"video/mpeg",mpeg:"video/mpeg",m3u8:"application/x-mpegurl",mpd:"application/dash+xml",ism:"application/vnd.ms-sstr+xml",mp3:"audio/mpeg",aac:"audio/aac",flac:"audio/flac",wav:"audio/wav",sbv:"text/x-subviewer",srt:"text/srt",vtt:"text/vtt",webvtt:"text/vtt",ttml:"application/ttml+xml",lrc:"application/x-subtitle-lrc",ssa:"text/x-ssa",ass:"text/x-ssa",jpg:"image/jpeg",png:"image/png",svg:"image/svg+xml",webp:"image/webp",avif:"image/avif"};function kd(e,t){if(e.lineBreak)return"\n";if(e.nestedCues.length)return e.nestedCues.map((function(t){return kd(t,e)})).join("");if(!e.payload)return e.payload;var n=[],i=e.fontWeight>=xn,r=e.fontStyle==Yn,a=e.textDecoration.includes(In);return i&&n.push(["b"]),r&&n.push(["i"]),a&&n.push(["u"]),""==(r=e.color)&&t&&(r=t.color),i="",(r=Dd(r))&&(i+="."+r),""==(r=e.backgroundColor)&&t&&(r=t.backgroundColor),(t=Dd(r))&&(i+=".bg_"+t),i&&n.push(["c",i]),n.reduceRight((function(e,t){var n=d(t);return"<"+(t=n.next().value)+(void 0===(n=n.next().value)?"":n)+">"+e+"</"+t+">"}),e.payload)}function Dd(e){var t=(e=e.toLowerCase()).replace(/\s/g,"").match(/^rgba?\((\d+),(\d+),(\d+),?([^,\s)]+)?/i);switch(t?e="#"+(256|parseInt(t[1],10)).toString(16).slice(1)+(256|parseInt(t[2],10)).toString(16).slice(1)+(256|parseInt(t[3],10)).toString(16).slice(1):e.startsWith("#")&&7<e.length&&(e=e.slice(0,7)),e){case"white":case"#fff":case"#ffffff":return"white";case"lime":case"#0f0":case"#00ff00":return"lime";case"cyan":case"#0ff":case"#00ffff":return"cyan";case"red":case"#f00":case"#ff0000":return"red";case"yellow":case"#ff0":case"#ffff00":return"yellow";case"magenta":case"#f0f":case"#ff00ff":return"magenta";case"blue":case"#00f":case"#0000ff":return"blue";case"black":case"#000":case"#000000":return"black"}return null}function xd(e,t){for(var n=[],i=(e=d(Ad(e))).next();!i.done;i=e.next())if((i=i.value).isContainer)n.push.apply(n,l(xd(i.nestedCues,i)));else{var r=i.clone();r.nestedCues=[],r.payload=kd(i,t),n.push(r)}return n}function Ad(e){for(var t=[],n=(e=d(e)).next(),i={};!n.done;i={Pe:void 0},n=e.next())i.Pe=n.value,t.some(function(e){return function(t){return ln(e.Pe,t)}}(i))||t.push(i.Pe);return t}function Yd(e){function t(e){for(var t=5381,n=e.length;n;)t=33*t^e.charCodeAt(--n);return(t>>>0).toString()}if(e.startTime>=e.endTime)return null;var n=new VTTCue(e.startTime,e.endTime,e.payload);n.id=t(e.startTime.toString())+t(e.endTime.toString())+t(e.payload),n.lineAlign=e.lineAlign,n.positionAlign=e.positionAlign,e.size&&(n.size=e.size);try{n.align=e.textAlign}catch(e){}return"center"==e.textAlign&&"center"!=n.align&&(n.align="middle"),"vertical-lr"==e.writingMode?n.vertical="lr":"vertical-rl"==e.writingMode&&(n.vertical="rl"),1==e.lineInterpretation&&(n.snapToLines=!1),null!=e.line&&(n.line=e.line),null!=e.position&&(n.position=e.position),n}function Ed(e){if(1/0===e.endTime||e.endTime<e.startTime)return null;var t=new un(e.startTime,e.endTime,e.text);return t.line="number"==typeof e.line?e.line:null,e.lineAlign&&(t.lineAlign=e.lineAlign),t.lineInterpretation=e.snapToLines?bn:1,t.position="number"==typeof e.position?e.position:null,e.positionAlign&&(t.positionAlign=e.positionAlign),t.size=e.size,t.textAlign=e.align,"lr"===e.vertical?t.writingMode="vertical-lr":"rl"===e.vertical&&(t.writingMode="vertical-rl"),e.region&&(t.region.id=e.region.id,t.region.height=e.region.lines,t.region.heightUnits=2,t.region.regionAnchorX=e.region.regionAnchorX,t.region.regionAnchorY=e.region.regionAnchorY,t.region.scroll=e.region.scroll,t.region.viewportAnchorX=e.region.viewportAnchorX,t.region.viewportAnchorY=e.region.viewportAnchorY,t.region.viewportAnchorUnits=Le,t.region.width=e.region.width,t.region.widthUnits=Le),cn(t),t}function Id(e,t){this.g=null;for(var n=d(Array.from(e.textTracks)),i=n.next();!i.done;i=n.next())"metadata"!==(i=i.value).kind&&"chapters"!==i.kind&&(i.mode="disabled",i.label==t&&(this.g=i));this.g||(this.g=e.addTextTrack("subtitles",t)),this.g.mode="hidden"}function Pd(e,t){var n=e.mode;e.mode="showing"==n?"showing":"hidden";for(var i=d(Array.from(e.cues)),r=i.next();!r.done;r=i.next())(r=r.value)&&t(r)&&e.removeCue(r);e.mode=n}function Cd(){}function jd(t,n,i){var r=this;document.fullscreenEnabled||$("Using UITextDisplayer in a browser without Fullscreen API support causes subtitles to not be rendered in fullscreen"),this.m=!1,this.h=[],this.A=t,this.s=n,this.l=null,this.g=document.createElement("div"),this.g.classList.add("shaka-text-container"),this.g.style.textAlign="center",this.g.style.display="flex",this.g.style.flexDirection="column",this.g.style.alignItems="center",this.g.style.justifyContent="flex-end",this.s.appendChild(this.g),i&&i.captionsUpdatePeriod||se("UITextDisplayer w/ config","Please migrate to initializing UITextDisplayer with a config."),this.C=new He((function(){r.A.paused||Nd(r)})).Ra(i&&i.captionsUpdatePeriod?i.captionsUpdatePeriod:.25),this.i=new Map,this.j=new Z,this.j.D(document,"fullscreenchange",(function(){Nd(r,!0)})),this.j.D(this.A,"seeking",(function(){Nd(r,!0)})),this.j.D(this.A,"resize",(function(){var e=r.A,t=e.videoWidth;e=e.videoHeight,r.l=t&&e?t/e:null})),this.o=null,"ResizeObserver"in e&&(this.o=new ResizeObserver((function(){Nd(r,!0)})),this.o.observe(this.g)),this.B=new Map}function Od(e,t){for(;null!=t;){if(t==e.g)return!0;t=t.parentElement}return!1}function Rd(e,t,n,i,r){for(var a=!1,s=[],o=[],u=(t=d(t)).next();!u.done;u=t.next()){u=u.value,r.push(u);var l=e.i.get(u),c=u.startTime<=i&&u.endTime>i,h=l?l.th:null;l&&(s.push(l.Re),l.Ac&&s.push(l.Ac),c||(a=!0,e.i.delete(u),l=null)),c&&(o.push(u),l?Od(e,h)||(a=!0):(Hd(e,u,r),h=(l=e.i.get(u)).th,a=!0)),0<u.nestedCues.length&&h&&Rd(e,u.nestedCues,h,i,r),r.pop()}if(a){for(r=(i=d(s)).next();!r.done;r=i.next())(r=r.value).parentElement&&r.parentElement.removeChild(r);for(o.sort((function(e,t){return e.startTime!=t.startTime?e.startTime-t.startTime:e.endTime-t.endTime})),i=(o=d(o)).next();!i.done;i=o.next())(i=e.i.get(i.value)).Ac?(i.Ac.contains(n)&&i.Ac.removeChild(n),n.appendChild(i.Ac),i.Ac.appendChild(i.Re)):n.appendChild(i.Re)}}function Nd(e,t){if(e.g){var n=e.A.currentTime;if(!e.m||void 0!==t&&t){for(var i=(t=d(e.B.values())).next();!i.done;i=t.next())Ds(i.value);Ds(e.g),e.i.clear(),e.B.clear()}e.m&&Rd(e,e.h,e.g,n,[])}}function Hd(e,t,n){var i=1<n.length,r=i?"span":"div";t.lineBreak&&(r="br"),t.rubyTag&&(r=t.rubyTag),i=!i&&0<t.nestedCues.length;var a=document.createElement(r);if("br"!=r&&function(e,t,n,i,r){var a=t.style,s=0==n.nestedCues.length,o=1<i.length;a.whiteSpace="pre-wrap";var u=n.payload.replace(/\s+$/g,(function(e){return" ".repeat(e.length)}));if(a.webkitTextStrokeColor=n.textStrokeColor,a.webkitTextStrokeWidth=n.textStrokeWidth,a.color=n.color,a.direction=n.direction,a.opacity=n.opacity,a.paddingLeft=Ud(n.linePadding,n,e.s),a.paddingRight=Ud(n.linePadding,n,e.s),a.textCombineUpright=n.textCombineUpright,a.textShadow=n.textShadow,n.backgroundImage)a.backgroundImage="url('"+n.backgroundImage+"')",a.backgroundRepeat="no-repeat",a.backgroundSize="contain",a.backgroundPosition="center",n.backgroundColor&&(a.backgroundColor=n.backgroundColor),a.width="100%",a.height="100%";else{if(n.nestedCues.length)var d=t;else d=document.createElement("span"),t.appendChild(d);n.border&&(d.style.border=n.border),r||((t=function(e,t){for(var n=e.length-1;0<=n;n--){var i=t(e[n]);if(i||0===i)return i}return null}(i,(function(e){return e.backgroundColor})))?d.style.backgroundColor=t:u&&(d.style.backgroundColor="rgba(0, 0, 0, 0.8)")),u&&(d.textContent=u)}o&&!i[i.length-1].isContainer?a.display="inline":(a.display="flex",a.flexDirection="column",a.alignItems="center","left"==n.textAlign||"start"==n.textAlign?(a.width="100%",a.alignItems="start"):"right"!=n.textAlign&&"end"!=n.textAlign||(a.width="100%",a.alignItems="end"),a.justifyContent="before"==n.displayAlign?"flex-start":"center"==n.displayAlign?"center":"flex-end"),s||(a.margin="0"),a.fontFamily=n.fontFamily,a.fontWeight=n.fontWeight.toString(),a.fontStyle=n.fontStyle,a.letterSpacing=n.letterSpacing,a.fontSize=Ud(n.fontSize,n,e.s),null!=(i=n.line)&&((s=n.lineInterpretation)==bn&&(s=1,o=16,e.l&&1>e.l&&(o=32),i=0>i?100+i/o*100:i/o*100),1==s&&(a.position="absolute",n.writingMode==wn?(a.width="100%",n.lineAlign==Tn?a.top=i+"%":"end"==n.lineAlign&&(a.bottom=100-i+"%")):"vertical-lr"==n.writingMode?(a.height="100%",n.lineAlign==Tn?a.left=i+"%":"end"==n.lineAlign&&(a.right=100-i+"%")):(a.height="100%",n.lineAlign==Tn?a.right=i+"%":"end"==n.lineAlign&&(a.left=100-i+"%")))),a.lineHeight=n.lineHeight,e=function(e){var t=e.direction,n=e.positionAlign;return e=e.textAlign,n!==pn?n:"left"===e||"start"===e&&t===Mn||"end"===e&&"rtl"===t?"line-left":"right"===e||"start"===e&&"rtl"===t||"end"===e&&t===Mn?"line-right":"center"}(n),"line-left"==e?(a.cssFloat="left",null!==n.position&&(a.position="absolute",n.writingMode==wn?(a.left=n.position+"%",a.width="auto"):a.top=n.position+"%")):"line-right"==e?(a.cssFloat="right",null!==n.position&&(a.position="absolute",n.writingMode==wn?(a.right=100-n.position+"%",a.width="auto"):a.bottom=n.position+"%")):null!==n.position&&50!=n.position&&(a.position="absolute",n.writingMode==wn?(a.left=n.position+"%",a.width="auto"):a.top=n.position+"%"),a.textAlign=n.textAlign,a.textDecoration=n.textDecoration.join(" "),a.writingMode=n.writingMode,"writingMode"in document.documentElement.style&&a.writingMode==n.writingMode||(a.webkitWritingMode=n.writingMode),n.size&&(n.writingMode==wn?a.width=n.size+"%":a.height=n.size+"%")}(e,a,t,n,i),n=null,t.region&&t.region.id){var s=t.region,o=e.l===4/3?2.5:1.9;if(n=s.id+"_"+s.width+"x"+s.height+(s.heightUnits==Le?"%":"px")+"-"+s.viewportAnchorX+"x"+s.viewportAnchorY+(s.viewportAnchorUnits==Le?"%":"px"),e.B.has(n))n=e.B.get(n);else{r=document.createElement("span");var u=s.heightUnits==Le?"%":"px",d=s.widthUnits==Le?"%":"px",l=s.viewportAnchorUnits==Le?"%":"px";r.id="shaka-text-region---"+n,r.classList.add("shaka-text-region"),r.style.position="absolute";var c=s.height,h=s.width;2===s.heightUnits&&(c=5.33*s.height,u="%"),2===s.widthUnits&&(h=s.width*o,d="%"),r.style.height=c+u,r.style.width=h+d,2===s.viewportAnchorUnits?(o=s.viewportAnchorY/75*100,u=s.viewportAnchorX/(e.l===4/3?160:210)*100,o-=s.regionAnchorY*c/100,u-=s.regionAnchorX*h/100,r.style.top=o+"%",r.style.left=u+"%"):(r.style.top=s.viewportAnchorY-s.regionAnchorY*c/100+l,r.style.left=s.viewportAnchorX-s.regionAnchorX*h/100+l),0!==s.heightUnits&&0!==s.widthUnits&&0!==s.viewportAnchorUnits&&(s=Math.max(0,Math.min(100-(parseInt(r.style.width.slice(0,-1),10)||0),parseInt(r.style.left.slice(0,-1),10)||0)),r.style.top=Math.max(0,Math.min(100-(parseInt(r.style.height.slice(0,-1),10)||0),parseInt(r.style.top.slice(0,-1),10)||0))+"%",r.style.left=s+"%"),r.style.display="flex",r.style.flexDirection="column",r.style.alignItems="center",r.style.justifyContent="before"==t.displayAlign?"flex-start":"center"==t.displayAlign?"center":"flex-end",e.B.set(n,r),n=r}}r=a,i&&((r=document.createElement("span")).classList.add("shaka-text-wrapper"),r.style.backgroundColor=t.backgroundColor,r.style.lineHeight="normal",a.appendChild(r)),e.i.set(t,{Re:a,th:r,Ac:n})}function Ud(e,t,n){var i=(i=new RegExp(/(\d*\.?\d+)([a-z]+|%+)/).exec(e))?{value:Number(i[1]),unit:i[2]}:null;if(!i)return e;var r=i.value;switch(i.unit){case"%":return r/100*n.clientHeight/t.cellResolution.rows+"px";case"c":return n.clientHeight*r/t.cellResolution.rows+"px";default:return e}}function Fd(e,t){this.h=e,this.g=t,this.i=void 0,this.l=!1,this.o=!0,this.j=this.m=!1}function Bd(t){return t.g.sessionId||(t.g.sessionId=e.crypto.randomUUID()),{v:1,sf:t.i,sid:t.g.sessionId,cid:t.g.contentId,mtp:t.h.getBandwidthEstimate()/1e3}}function Wd(e,t,n){n=void 0===n?{}:n;var i=void 0===i?e.g.useHeaders:i;if(e.g.enabled){Object.assign(n,Bd(e)),n.pr=e.h.ib();var r=n.ot===$d||n.ot===Kd;if(e.m&&r&&(n.bs=!0,n.su=!0,e.m=!1),null==n.su&&(n.su=e.o),e=function(e,t){var n=e.g.includeKeys;return n.length?Object.keys(t).reduce((function(e,i){return n.includes(i)&&(e[i]=t[i]),e}),{}):t}(e,n),i)i=function(e){for(var t=Object.keys(e),n={},i=["Object","Request","Session","Status"],r=[{},{},{},{}],a={br:0,d:0,ot:0,tb:0,bl:1,dl:1,mtp:1,nor:1,nrr:1,su:1,cid:2,pr:2,sf:2,sid:2,st:2,v:2,bs:3,rtp:3},s=(t=d(t)).next();!s.done;s=t.next())r[null!=a[s=s.value]?a[s]:1][s]=e[s];for(e=0;e<r.length;e++)(a=Vd(r[e]))&&(n["CMCD-"+i[e]]=a);return n}(e),Object.keys(i).length&&Object.assign(t.headers,i);else{var a=Vd(e);a&&(t.uris=t.uris.map((function(e){return Gd(e,a)})))}}}function zd(e,t){if(!(t=e.h.zb()[t]).length)return 0;var n=e.h.getCurrentTime();return(e=t.find((function(e){return e.start<=n&&e.end>=n})))?1e3*(e.end-n):0}function Vd(e){function t(e){return 100*n(e/100)}function n(e){return Math.round(e)}for(var i,r=[],a={br:n,d:n,bl:t,dl:t,mtp:t,nor:function(e){return encodeURIComponent(e)},rtp:t,tb:n},s=Object.keys(e||{}).sort(),o=(s=d(s)).next();!o.done;o=s.next()){var u=e[o=o.value];if(i=u,!(Number.isNaN(i)||null==i||""===i||!1===i||"v"===o&&1===u||"pr"==o&&1===u)){var l,c=a[o];c&&(u=c(u)),l="string"==(c=typeof u)&&"ot"!==o&&"sf"!==o&&"st"!==o?o+"="+JSON.stringify(u):"boolean"===c?o:"symbol"===c?o+"="+u.description:o+"="+u,r.push(l)}}return r.join(",")}function Gd(e,t){return!t||e.includes("offline:")?e:((e=new Wn(e)).g.set("CMCD",t),e.toString())}(i=Id.prototype).configure=function(){},i.remove=function(e,t){return!!this.g&&(Pd(this.g,(function(n){return n.startTime<t&&n.endTime>e})),!0)},i.append=function(e){var t=xd(e),n=[];e=this.g.cues?Array.from(this.g.cues):[];for(var i=(t=d(t)).next(),r={};!i.done;r={Nc:void 0},i=t.next())r.Nc=i.value,!e.some(function(e){return function(t){return t.startTime==e.Nc.startTime&&t.endTime==e.Nc.endTime&&t.text==e.Nc.payload}}(r))&&r.Nc.payload&&(i=Yd(r.Nc))&&n.push(i);for(t=(e=d(e=n.slice().sort((function(e,t){return e.startTime!=t.startTime?e.startTime-t.startTime:e.endTime!=t.endTime?e.endTime-t.startTime:"line"in VTTCue.prototype?n.indexOf(t)-n.indexOf(e):n.indexOf(e)-n.indexOf(t)})))).next();!t.done;t=e.next())this.g.addCue(t.value)},i.destroy=function(){return this.g&&(Pd(this.g,(function(){return!0})),this.g.mode="disabled"),this.g=null,Promise.resolve()},i.isTextVisible=function(){return"showing"==this.g.mode},i.setTextVisibility=function(e){this.g.mode=e?"showing":"hidden"},i.setTextLanguage=function(){},U("shaka.text.SimpleTextDisplayer",Id),Id.prototype.setTextLanguage=Id.prototype.setTextLanguage,Id.prototype.setTextVisibility=Id.prototype.setTextVisibility,Id.prototype.isTextVisible=Id.prototype.isTextVisible,Id.prototype.destroy=Id.prototype.destroy,Id.prototype.append=Id.prototype.append,Id.prototype.remove=Id.prototype.remove,Id.prototype.configure=Id.prototype.configure,(i=Cd.prototype).configure=function(){},i.remove=function(){},i.append=function(){},i.destroy=function(){},i.isTextVisible=function(){return!1},i.setTextVisibility=function(){},i.setTextLanguage=function(){},U("shaka.text.StubTextDisplayer",Cd),Cd.prototype.setTextLanguage=Cd.prototype.setTextLanguage,Cd.prototype.setTextVisibility=Cd.prototype.setTextVisibility,Cd.prototype.isTextVisible=Cd.prototype.isTextVisible,Cd.prototype.destroy=Cd.prototype.destroy,Cd.prototype.append=Cd.prototype.append,Cd.prototype.remove=Cd.prototype.remove,Cd.prototype.configure=Cd.prototype.configure,(i=jd.prototype).configure=function(e){this.C&&this.C.Ra(e.captionsUpdatePeriod)},i.append=function(e){for(var t=[].concat(l(this.h)),n=(e=d(Ad(e))).next(),i={};!n.done;i={Qe:void 0},n=e.next())i.Qe=n.value,t.some(function(e){return function(t){return ln(t,e.Qe)}}(i))||this.h.push(i.Qe);Nd(this)},i.destroy=function(){return this.g?(this.s.removeChild(this.g),this.g=null,this.m=!1,this.h=[],this.C&&this.C.stop(),this.i.clear(),this.j&&(this.j.release(),this.j=null),this.o&&(this.o.disconnect(),this.o=null),Promise.resolve()):Promise.resolve()},i.remove=function(e,t){if(!this.g)return!1;var n=this.h.length;return this.h=this.h.filter((function(n){return n.startTime<e||n.endTime>=t})),Nd(this,n>this.h.length),!0},i.isTextVisible=function(){return this.m},i.setTextVisibility=function(e){this.m=e,Nd(this,!0)},i.setTextLanguage=function(e){e&&"und"!=e?this.g.setAttribute("lang",e):this.g.setAttribute("lang","")},U("shaka.text.UITextDisplayer",jd),jd.prototype.setTextLanguage=jd.prototype.setTextLanguage,jd.prototype.setTextVisibility=jd.prototype.setTextVisibility,jd.prototype.isTextVisible=jd.prototype.isTextVisible,jd.prototype.remove=jd.prototype.remove,jd.prototype.destroy=jd.prototype.destroy,jd.prototype.append=jd.prototype.append,jd.prototype.configure=jd.prototype.configure,U("shaka.text.WebVttGenerator",(function(){})),Fd.prototype.configure=function(e){this.g=e};var qd="a",$d="v",Kd="av",Jd="tt",Xd="d",Qd="ld",Zd="h",el="lh";function tl(e){this.h=e,this.g=null}function nl(e){return!e||"false"!==e.toLowerCase()&&(/^[-0-9]/.test(e)?parseInt(e,10):e.replace(/["]+/g,""))}U("shaka.util.CmcdManager.StreamingFormat",{DASH:Xd,Dj:Qd,HLS:Zd,Ej:el,Rj:"s",OTHER:"o"}),(i=tl.prototype).configure=function(e){this.h=e},i.Cg=function(){return this.h.enabled&&this.h.applyMaximumSuggestedBitrate&&this.g&&this.g.has(rl)?1e3*this.g.get(rl):null},i.Ag=function(){return this.h.enabled&&this.g&&this.g.has(il)?1e3*this.g.get(il):null},i.bi=function(){return this.h.enabled&&this.g&&this.g.has(al)?this.g.get(al):null},i.ci=function(){return this.h.enabled&&this.g&&this.g.has(sl)?this.g.get(sl):null},i.getBandwidthEstimate=function(e){var t=this.Ag();if(!t)return e;var n=this.h.estimatedThroughputWeightRatio;return 0<n&&1>=n?e*(1-n)+t*n:e},U("shaka.util.CmsdManager",tl),tl.prototype.getBandwidthEstimate=tl.prototype.getBandwidthEstimate,tl.prototype.getRoundTripTime=tl.prototype.ci,tl.prototype.getResponseDelay=tl.prototype.bi,tl.prototype.getEstimatedThroughput=tl.prototype.Ag,tl.prototype.getMaxBitrate=tl.prototype.Cg;var il="etp",rl="mb",al="rd",sl="rtt";function ol(){this.g=null,this.h=[]}function ul(e,t){return I((function(n){if(1==n.g)return e.g?M(n,new Promise((function(t){return e.h.push(t)})),2):n.u(2);e.g=t,w(n)}))}function dl(t,n,i){n=void 0===n?null:n,Zr.call(this);var r=this;this.m=ac,this.h=null,this.ge=n,this.ja=!1,this.te=new Z,this.od=new Z,this.l=new Z,this.Ga=new Z,this.Na=new Z,this.F=this.I=this.C=this.G=null,this.Ce=0,this.Z=new ol,this.ga=this.Ka=this.Y=this.i=this.La=this.H=this.j=this.ac=this.L=this.gg=this.da=this.O=this.bc=this.M=this.ie=this.K=this.Hb=null,this.Ba=!1,this.ta=this.o=null,this.fg=1e9,this.ud=[],this.eg=-1,this.g=Cl(this),this.S=null,this.Ee=-1,this.Aa=null,this.fa={width:1/0,height:1/0},this.de=new ts(this.g,this.fa,null),this.le=[],this.A=null,this.xa=new Or(this.g.preferredAudioLanguage,this.g.preferredVariantRole,this.g.preferredAudioChannelCount,this.g.preferredVideoHdrLevel,this.g.preferSpatialAudio,this.g.preferredVideoLayout,this.g.preferredAudioLabel,this.g.preferredVideoLabel,this.g.mediaSource.codecSwitchingStrategy,""),this.Gb=this.g.preferredTextLanguage,this.sd=this.g.preferredTextRole,this.rd=this.g.preferForcedSubs,this.qd=[],i&&i(this),this.O=function(e){return new Fd({getBandwidthEstimate:function(){return e.o?e.o.getBandwidthEstimate():NaN},zb:function(){return e.zb()},getCurrentTime:function(){return e.h?e.h.currentTime:0},ib:function(){return e.ib()},Ab:function(){return e.Ab()},rc:function(){return e.rc()},U:function(){return e.U()}},e.g.cmcd)}(this),this.da=new tl(this.g.cmsd),this.G=bl(this),this.G.Tf(this.g.streaming.forceHTTP),this.G.Uf(this.g.streaming.forceHTTPS),this.G.m=this.g.streaming.minBytesForProgressEvents,this.Ib=this.aa=this.s=null,this.Ge=!1,this.Fe=new He((function(){return I((function(e){return 1==e.g?r.aa?M(e,r.Tb(r.Ib,!0),3):e.u(0):4!=e.g?M(e,r.load(r.aa),4):(r.Ge?r.Ib.pause():r.Ib.play(),r.aa=null,r.Ge=!1,void w(e))}))})),lc&&(this.s=lc(),this.s.configure(this.g.ads),this.Na.D(this.s,"ad-content-pause-requested",(function(e){var t;return I((function(n){if(1==n.g)return r.Fe.stop(),r.aa?n.u(0):(r.Ib=r.h,r.Ge=r.h.ended,t=e.saveLivePosition||!1,M(n,r.tg(!0,t),3));r.aa=n.h,w(n)}))})),this.Na.D(this.s,"ad-content-resume-requested",(function(e){if(e=e.offset||0,r.aa){var t=r.aa;t.B&&e&&(t.B+=e)}r.Fe.$(.1)})),this.Na.D(this.s,"ad-content-attach-requested",(function(){return I((function(e){return r.h||!r.Ib?e.u(0):M(e,r.Tb(r.Ib,!0),0)}))}))),this.te.D(e,"online",(function(){Kl(r),r.Nf()})),this.je=new He((function(){for(var e=Date.now()/1e3,t=!1,n=!0,i=d(r.i.variants),a=i.next();!a.done;a=i.next())0<(a=a.value).disabledUntilTime&&a.disabledUntilTime<=e&&(a.disabledUntilTime=0,t=!0),0<a.disabledUntilTime&&(n=!1);n&&r.je.stop(),t&&Ul(r,!1,void 0,!1,!1)})),this.na=null,t&&(se("Player w/ mediaElement","Please migrate from initializing Player with a mediaElement; use the attach method instead."),this.Tb(t,!0)),this.B=null}function ll(e){null!=e.L&&(lo(e.L),e.L.release(),e.L=null)}function cl(e,t){return new Jr(e,t)}function hl(e,t){e.dispatchEvent(cl("onstatechange",(new Map).set("state",t)))}function ml(e,t){var n;return I((function(i){return 1==i.g?(n=++e.Ce,M(i,ul(e.Z,t),2)):n!=e.Ce?(e.Z.release(),i.return(!0)):i.return(!1)}))}function fl(e,t){var n,i;return t=void 0!==t&&t,I((function(r){if(1==r.g)return n=null,e.i&&e.H&&e.La&&e.Y?(i=e.h.currentTime,e.U()&&!t&&(i=null),M(r,gl(e,e.Y,i,e.Ka,!0,!1,!1),3)):r.u(2);if(2!=r.g){n=r.h,e.le.push(n),e.H&&e.H.setMediaElement&&e.H.setMediaElement(null);var a=n,s=e.H,o=e.La;a.h=e.i,a.j=s,a.G=o,a=n,s=e.ta,a.i=e.o,a.C=s,n.o=e.xa,n.start(),e.i=null,e.H=null,e.La=null,e.o=null,e.ta=null}return r.return(n)}))}function pl(e,t,n,i,r){var a,s,o;return r=void 0!==r&&r,I((function(u){return 1==u.g?i?u.u(2):M(u,yl(e,t),3):(2!=u.g&&(i=u.h),function(e,t){if(!Ue())return!0;if(t){if(""==(e.h||at()).canPlayType(t))return!1;if(!Ue()||!(t in ls))return!0;if(Ii(t))return Ke()&&(e.g.drm.servers["com.apple.fps"]||e.g.drm.servers["com.apple.fps.1_0"])?e.g.streaming.useNativeHlsForFairPlay:e.g.streaming.preferNativeHls}return!1}(e,i)?u.return(null):(a=!1,s=!0,r&&(e.o&&e.ta==e.g.abrFactory&&(s=!1),e.h&&"AUDIO"===e.h.nodeName&&(a=!0)),o=gl(e,t,n,i||null,!r,a,s),o=r?o.then((function(e){return e.A=!1,e})):o.then((function(t){return e.le.push(t),t})),u.return(o)))}))}function gl(e,t,n,i,r,a,s){var o,u,l,c,h,m,f,p,g,y,_,v,b;return r=void 0===r||r,a=void 0!==a&&a,s=void 0===s||s,I((function(T){return 1==T.g?(o=null,u=kt(e.g),a&&(u.manifest.disableVideo=!0),l=function(){return o.S&&o.s?null:o},c=function(){return l()?l().getConfiguration():e.g},h=function(t,n){l()?o.configure(t,n):e.configure(t,n)},1/0!=e.fa.width||1/0!=e.fa.height||e.g.ignoreHardwareResolution?T.u(2):M(T,ot(),3)):(2!=T.g&&(m=T.h,e.fa.width=m.width,e.fa.height=m.height),f=new ts(u,e.fa,null),p={networkingEngine:e.G,filter:function(e){var t;return I((function(n){return 1==n.g?M(n,ns(f,e),2):4!=n.g?n.h?(t=cl("trackschanged"),M(n,Promise.resolve(),4)):n.u(0):(o.dispatchEvent(t),void w(n))}))},makeTextStreamsForClosedCaptions:function(t){return function(e,t){for(var n=new Set,i=d(t.textStreams),r=i.next();!r.done;r=i.next())"application/cea-608"!=(r=r.value).mimeType&&"application/cea-708"!=r.mimeType||n.add(r.originalId);for(r=(i=d(t.variants)).next();!r.done;r=i.next())if((r=r.value.video)&&r.closedCaptions)for(var a=d(r.closedCaptions.keys()),s=a.next();!s.done;s=a.next())if(s=s.value,!n.has(s)){var o=s.startsWith("CC")?"application/cea-608":"application/cea-708",u=new iu,l=r.closedCaptions.get(s);o={id:e.fg++,originalId:s,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:u,mimeType:o,codecs:"",kind:"caption",encrypted:!1,drmInfos:[],keyIds:new Set,language:l,originalLanguage:l,label:null,type:_i,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:r.roles,forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set([Ti(o,"")]),isAudioMuxedInVideo:!1},t.textStreams.push(o),n.add(s)}}(e,t)},onTimelineRegionAdded:function(e){var t=o.H;e:{for(var n=d(t.g),i=n.next();!i.done;i=n.next())if((i=i.value).schemeIdUri==e.schemeIdUri&&i.id==e.id&&i.startTime==e.startTime&&i.endTime==e.endTime){n=i;break e}n=null}null==n&&(t.g.add(e),e=new Jr("regionadd",new Map([["region",e]])),t.dispatchEvent(e))},onEvent:function(e){return o.dispatchEvent(e)},onError:function(e){return o.onError(e)},isLowLatencyMode:function(){return c().streaming.lowLatencyMode},isAutoLowLatencyMode:function(){return c().streaming.autoLowLatencyMode},enableLowLatencyMode:function(){h("streaming.lowLatencyMode",!0)},updateDuration:function(){e.j&&o.S&&e.j.updateDuration()},newDrmInfo:function(e){var t=o.l,n=t?t.g:null;n&&t.A&&as(f,n.keySystem,e)},onManifestUpdated:function(){var t=(new Map).set("isLive",e.U());o.dispatchEvent(cl("manifestupdated",t)),fd(o,!1,(function(){e.s&&e.s.onManifestUpdated(e.U())}))},getBandwidthEstimate:function(){return e.o.getBandwidthEstimate()},onMetadata:function(t,n,i,r){var a=t;"com.apple.hls.interstitial"==t&&(a="com.apple.quicktime.HLS",t={startTime:n,endTime:i,values:r},e.s)&&e.s.onHLSInterstitialMetadata(e,e.h,t),t=(r=d(r)).next();for(var s={};!t.done;s={If:void 0},t=r.next())s.If=t.value,"ID"!=s.If.name&&fd(o,!1,function(t){return function(){wl(e,n,i,a,t.If)}}(s))},disableStream:function(t){return e.disableStream(t,e.g.streaming.maxDisabledTime)},addFont:function(t,n){return e.addFont(t,n)}},(g=new Lu((function(){return e.Qb()}))).addEventListener("regionadd",(function(t){var n=t.region;Xl(e,"timelineregionadded",n,o),fd(o,!1,(function(){e.s&&(e.s.onDashTimedMetadata(n),e.s.onDASHInterstitialMetadata(e,e.h,n))}))})),y=null,u.streaming.observeQualityChanges&&((y=new Su((function(){return e.zb()}))).addEventListener("qualitychange",(function(t){Ql(e,t.quality,t.position)})),y.addEventListener("audiotrackchange",(function(t){Ql(e,t.quality,t.position,!0)}))),_=!0,v={Nb:e.G,onError:function(e){return o.onError(e)},ee:function(t){fd(o,!0,(function(){var n=t,i=cl("keystatuschanged");e.dispatchEvent(i);var r=Object.keys(n);1==r.length&&""==r[0]&&(r=["00"],n={"00":n[""]}),i=1==r.length&&"00"==r[0];var a=!1;if(r.length)for(var s=(r=d(e.i.variants)).next();!s.done;s=r.next()){var o=[];(s=s.value).audio&&o.push(s.audio),s.video&&o.push(s.video);for(var u=(o=d(o)).next();!u.done;u=o.next()){var l=u.value;if(u=s.allowedByKeySystem,l.keyIds.size){s.allowedByKeySystem=!0;for(var c=(l=d(l.keyIds)).next();!c.done;c=l.next())c=c.value,((c=n[i?"00":c])||e.C.F)&&(s.allowedByKeySystem=s.allowedByKeySystem&&!!c&&!os.includes(c))}u!=s.allowedByKeySystem&&(a=!0)}}a&&(Wl(e),!Hl(e))||(n=e.j.j)&&!n.allowedByKeySystem&&Ul(e)}))},onExpirationUpdated:function(e,t){var n=cl("expirationupdated");o.dispatchEvent(n),(n=o.j)&&n.onExpirationUpdated&&n.onExpirationUpdated(e,t)},onEvent:function(t){o.dispatchEvent(t),"drmsessionupdate"==t.type&&_&&(_=!1,t=Date.now()/1e3-o.xa,(e.A||o.getStats()).j=t,e.L&&lo(e.L))}},b=bl(e,l),ra(e.G,b),o=new md(t,i,n,{config:u,zi:p,Ji:g,Ii:y,Gc:function(){return e.Gc(v)},yi:f,networkingEngine:b,Bh:r,Ah:s}),T.return(o))}))}function yl(e,t){var n,i;return I((function(r){return 1==r.g?(n=e.g.manifest.retryParameters,M(r,Ld(t,e.G,n),2)):("application/x-mpegurl"==(i=r.h)&&Ke()&&(i="application/vnd.apple.mpegurl"),r.return(i))}))}function _l(e){var t=e.g.textDisplayFactory;t!==e.Ae&&(e.B=t(),e.B.configure?e.B.configure(e.g.textDisplayer):se("Text displayer w/ configure",'Text displayer should have a "configure" method!'),e.Ae=t,e.B.setTextVisibility(e.ja))}function vl(e){var t,n,i;return I((function(r){if(1==r.g)return hl(e,"media-source"),e.h.removeAttribute("src"),Ds(e.h),_l(e),t=function(e,t,n,i){return new ho(e,t,n,i)}(e.h,e.B,{Uh:function(){return e.keySystem()},onMetadata:function(t,n,i){for(var r=(t=d(t)).next();!r.done;r=t.next())if((r=r.value).data&&"number"==typeof r.cueTime&&r.frames){var a=r.cueTime+n,s=i;s&&a>s&&(s=a);for(var o=d(r.frames),u=o.next();!u.done;u=o.next())wl(e,a,s,"org.id3",u.value);e.s&&e.s.onHlsTimedMetadata(r,a)}},onEvent:function(t){return e.dispatchEvent(t)},Fi:function(){e.H&&e.H.update&&e.H.update()}},e.L),t.configure(e.g.mediaSource),n=e.g.manifest,i=n.segmentRelativeVttTiming,t.xa=i,M(r,t.S,2);e.I=t,w(r)}))}function Ml(e,t,n){function i(){return Ol(e)}e.l.D(t,"playing",i),e.l.D(t,"pause",i),e.l.D(t,"ended",i),e.l.D(t,"ratechange",(function(){var t=e.h.playbackRate;0!=t&&(e.K&&e.K.set(t),t=cl("ratechange"),e.dispatchEvent(t))})),t.remote&&(e.l.D(t.remote,"connect",(function(){return Wl(e)})),e.l.D(t.remote,"connecting",(function(){return Wl(e)})),e.l.D(t.remote,"disconnect",(function(){return I((function(n){if(1==n.g)return e.j&&"disconnected"==t.remote.state?M(n,Xu(e.j),2):n.u(2);Wl(e),w(n)}))}))),t.audioTracks&&(e.l.D(t.audioTracks,"addtrack",(function(){return Wl(e)})),e.l.D(t.audioTracks,"removetrack",(function(){return Wl(e)})),e.l.D(t.audioTracks,"change",(function(){return Wl(e)}))),t.textTracks&&(e.l.D(t.textTracks,"addtrack",(function(t){if(t.track)switch(t=t.track,t.kind){case"metadata":!function(e,t){if("metadata"==t.kind){t.mode="hidden",e.l.D(t,"cuechange",(function(){if(t.activeCues)for(var n=d(t.activeCues),i=n.next();!i.done;i=n.next())i=i.value,wl(e,i.startTime,i.endTime,i.type,i.value),e.s&&e.s.onCueMetadataChange(i.value);if(t.cues){n=[];for(var r=(i=d(t.cues)).next(),a={};!r.done;a={Vb:void 0},r=i.next())a.Vb=r.value,"com.apple.quicktime.HLS"==a.Vb.type&&null!=a.Vb.startTime&&(r=n.find(function(e){return function(t){return t.startTime==e.Vb.startTime&&t.endTime==e.Vb.endTime}}(a)),r||(r={startTime:a.Vb.startTime,endTime:a.Vb.endTime,values:[]},n.push(r)),r.values.push(a.Vb.value));for(i=(n=d(n)).next();!i.done;i=n.next())(i=i.value).values.some((function(e){return"X-ASSET-URI"==e.key||"X-ASSET-LIST"==e.key}))&&e.s&&(i.values.push({key:"CUE",description:"",data:0!=i.startTime||e.U()?"ONCE":"ONCE,PRE",mimeType:null,pictureType:null}),e.s.onHLSInterstitialMetadata(e,e.h,i))}}));var n=new He((function(){for(var t=function(e){return Array.from(e.h.textTracks).filter((function(e){return"metadata"==e.kind}))}(e),n=(t=d(t)).next();!n.done;n=t.next())n.value.mode="hidden"})).hc().$(.5);e.qd.push((function(){n.stop()}))}}(e,t);break;case"chapters":!function(e,t){if(t&&"chapters"==t.kind){t.mode="hidden";var n=new He((function(){t.mode="hidden"})).hc().$(.5);e.qd.push((function(){n.stop()}))}}(e,t);break;default:Wl(e)}})),e.l.D(t.textTracks,"removetrack",(function(){return Wl(e)})),e.l.D(t.textTracks,"change",(function(){return Wl(e)}))),"none"!=t.preload&&e.l.pa(t,"loadedmetadata",(function(){e.A.C=Date.now()/1e3-n}))}function wl(e,t,n,i,r){t=(new Map).set("startTime",t).set("endTime",n).set("metadataType",i).set("payload",r),e.dispatchEvent(cl("metadata",t))}function bl(e,t){function n(n){t()?t().dispatchEvent(n):e.dispatchEvent(n)}function i(e){t()?fd(t(),!0,e):e()}return t||(t=function(){return null}),new na((function(n,i,r,a){var s=t()?t().i:e.o;s&&s.segmentDownloaded(n,i,r,a)}),(function(t,r,a){n(cl("downloadheadersreceived",r=(new Map).set("headers",t).set("request",r).set("requestType",a))),i((function(){if(e.da){var n=e.da;if(n.h.enabled){var i=t["cmsd-static"];if(i)try{var r=new Map,a=i.split(",");for(i=0;i<a.length;i++){var s=a[i].split("=");r.set(s[0],nl(s[1]))}}catch(e){}if(r=t["cmsd-dynamic"]){try{var o=new Map,u=r.split(";");for(r=1;r<u.length;r++){var d=u[r].split("=");o.set(d[0],nl(d[1]))}var l=o}catch(e){l=null}l&&(n.g=l)}}}}))}),(function(e,t,i,r){n(cl("downloadfailed",e=(new Map).set("request",e).set("error",t).set("httpResponseCode",i).set("aborted",r)))}),(function(t,n,r){i((function(){var i=e.O,a=r;if(a=void 0===a?{}:a,i.g.enabled)if("HEAD"===n.method)Wd(i,n);else switch(t){case 0:try{if(i.g.enabled){if(a.type){e:{switch(a.type){case 4:var s=i.j?Qd:Xd;break e;case 3:case 2:s=i.j?el:Zd;break e;case 5:s="s";break e}s=void 0}i.i=s}Wd(i,n,{ot:"m",su:!i.l})}}catch(e){K("CMCD_MANIFEST_ERROR","Could not generate manifest CMCD data.",e)}break;case la:try{if(i.g.enabled){var o=a.segment;s=0,o&&(s=o.endTime-o.startTime);var u={d:1e3*s,st:i.h.U()?"l":"v"};u.ot=function(e){if(0===e.type)return"i";if(e=e.stream){var t=e.type;if("video"==t)return e.codecs&&e.codecs.includes(",")?Kd:$d;if("audio"==t)return qd;if("text"==t)return"application/mp4"===e.mimeType?Jd:"c"}}(a);var l=u.ot===$d||u.ot===qd||u.ot===Kd||u.ot===Jd,c=a.stream;if(c){var h=i.h.ib();if(l&&(u.bl=function(e,t){if(!(t=e.h.zb()[t]).length)return NaN;var n=e.h.getCurrentTime();return(e=t.find((function(e){return e.start<=n&&e.end>=n})))?1e3*(e.end-n):NaN}(i,c.type),u.ot!==Jd)){var m=zd(i,c.type);u.dl=h?m/Math.abs(h):m}if(c.bandwidth&&(u.br=c.bandwidth/1e3),c.segmentIndex&&o){var f=c.segmentIndex.Jb(o.endTime,!0,0>h);if(f){var p=f.next().value;if(p&&p!=o){if(!Ae(o.N(),p.N())){var g=p.N()[0],y=n.uris[0],_=new URL(g),v=new URL(y);if(_.origin!==v.origin)var M=g;else{for(var w=_.pathname.split("/").slice(1),b=v.pathname.split("/").slice(1,-1);w[0]===b[0];)w.shift(),b.shift();for(;b.length;)b.shift(),w.unshift("..");M=w.join("/")}u.nor=M}if((p.Ja||p.va)&&(o.Ja!=p.Ja||o.va!=p.va)){var T=p.Ja+"-";p.va&&(T+=p.va),u.nrr=T}}}var L=i.h.ib()||1,S=zd(i,c.type)||500,k=c.bandwidth,D=k?k*(o.endTime-o.startTime)/1e3/(S/L/1e3)*i.g.rtpSafetyFactor:NaN;isNaN(D)||(u.rtp=D)}}l&&u.ot!==Jd&&(u.tb=function(e,t){var n=e.h.rc();if(!n.length)return NaN;e=n[0];for(var i=(n=d(n)).next();!i.done;i=n.next())"variant"===(i=i.value).type&&i.bandwidth>e.bandwidth&&(e=i);switch(t){case $d:return e.videoBandwidth||NaN;case qd:return e.audioBandwidth||NaN;default:return e.bandwidth}}(i,u.ot)/1e3),Wd(i,n,u)}}catch(e){K("CMCD_SEGMENT_ERROR","Could not generate segment CMCD data.",e)}break;case 2:case 5:case 6:Wd(i,n,{ot:"k"});break;case 4:Wd(i,n,{ot:"o"})}}))}),(function(n,i,r,a){(n=t()?t().j:e.H)&&n.banLocation&&n.banLocation(a)}),(function(n,i){if(i.data){i=i.data.byteLength;var r=t()?t().getStats():e.A;r&&(r.kc=isNaN(r.kc)?i:r.kc+i,0===n&&(r.Kg=i))}}))}function Tl(e,t,n){e.M=new Rr,e.M.g=Hr,Nr(e.M,n,Math.min(.5,n/2)),jl(e),e.ie=new He((function(){Ll(e)})).Ra(.25),e.l.D(t,"waiting",(function(){return Ll(e)})),e.l.D(t,"stalled",(function(){return Ll(e)})),e.l.D(t,"canplaythrough",(function(){return Ll(e)})),e.l.D(t,"progress",(function(){return Ll(e)}))}function Ll(e){switch(e.m){case oc:if(e.h.ended)var t=!0;else{var n=ws(e.h.buffered);t=null!=n&&n>=e.h.duration-1}break;case sc:e:if(e.h.ended||go(e.I))t=!0;else{if(e.i.presentationTimeline.U()){n=e.i.presentationTimeline.Yb();var i=ws(e.h.buffered);if(null!=i&&i>=n){t=!0;break e}}t=!1}break;default:t=!1}i=Ts(e.h.buffered,e.h.currentTime);var r=t,a=(n=e.M).i.get(n.g);t=n.g,i=r||i>=a?Ur:Hr,n.g=i,(t=t!=i)&&i===Ur&&(n.h=Date.now()),t&&jl(e)}function Sl(e){if(e.de=new ts(e.g,e.fa,e.C),e.H){var t=kt(e.g.manifest);e.h&&"AUDIO"===e.h.nodeName&&(t.disableVideo=!0),e.H.configure(t)}if(e.C&&e.C.configure(e.g.drm),e.j){e.j.configure(e.g.streaming);try{e.m!=rc&&rs(e.de,e.i)&&Wl(e)}catch(t){Jl(e,t)}e.o&&Hl(e),!(t=e.j.j)||t.allowedByApplication&&t.allowedByKeySystem||Ul(e)}if(e.G&&(e.G.Tf(e.g.streaming.forceHTTP),e.G.Uf(e.g.streaming.forceHTTPS),e.G.m=e.g.streaming.minBytesForProgressEvents),e.I&&(e.I.configure(e.g.mediaSource),e.I.xa=e.g.manifest.segmentRelativeVttTiming),e.B)if(t=e.g.textDisplayFactory,e.Ae!=t){var n=e.B;if(e.B=t(),e.B.configure?e.B.configure(e.g.textDisplayer):se("Text displayer w/ configure",'Text displayer should have a "configure" method!'),e.B.setTextLanguage||se("Text displayer w/ setTextLanguage",'Text displayer should have a "setTextLanguage" method!'),e.B.setTextVisibility(n.isTextVisible()),n.destroy(),e.I){n=e.I;var i=e.B;n.fa=i,n.h&&(n.h.j=i)}e.Ae=t,e.j&&(n=(t=e.j).i.get(_i))&&Ou(t,n.stream,!0,0,!0)}else e.B.configure&&e.B.configure(e.g.textDisplayer);e.o&&(e.o.configure(e.g.abr),e.g.abr.enabled?e.o.enable():e.o.disable(),ql(e)),e.M&&(t=e.g.streaming.rebufferingGoal,e.i&&(t=Math.max(t,e.i.minBufferTime)),Nr(e.M,t,Math.min(.5,t/2))),e.i&&ec(e.i.presentationTimeline,e.g.playRangeStart,e.g.playRangeEnd),e.s&&e.s.configure(e.g.ads),e.O&&e.O.configure(e.g.cmcd),e.da&&e.da.configure(e.g.cmsd)}function kl(e){return e&&(e=/(\d+)x(\d+)/.exec(e))?{lc:parseInt(e[1],10),rows:parseInt(e[2],10)}:null}function Dl(e,t){e.l.D(t,"cuechange",(function(){e.B.remove(0,Math.max(0,e.h.currentTime-e.g.streaming.bufferBehind));var n=Array.from(t.activeCues||[]).map(Ed).filter(Wi);e.B.append(n)})),t.mode=document.pictureInPictureElement?"showing":"hidden"}function xl(e){return Array.from(e.h.textTracks).filter((function(e){return"metadata"!=e.kind&&"chapters"!=e.kind&&"Shaka Player TextTrack"!=e.label}))}function Al(e){return Array.from(e.h.textTracks).filter((function(e){return"chapters"==e.kind}))}function Yl(e,t){var n;return I((function(i){switch(i.g){case 1:return b(i,2),M(i,Ld(t,e.G,e.g.streaming.retryParameters),4);case 4:n=i.h,L(i,3);break;case 2:S(i);case 3:if(n)return i.return(n);throw new Ye(1,2,2011,t)}}))}function El(e,t,n,i,r,a,s){var o,u,d,l;return I((function(c){if(1==c.g)return"text/vtt"!=r||s.length?M(c,Il(e,t,e.G,e.g.streaming.retryParameters),3):c.u(2);2!=c.g&&(o=c.h,u=Pl(e,o,r,s),d=new Blob([u],{type:"text/vtt"}),t=Eo(d),r="text/vtt"),l=document.createElement("track");var h=e.O,m=t;try{if(h.g.enabled){var f=Bd(h);f.ot="c",f.su=!0;var p=Gd(m,Vd(f))}else p=m}catch(e){K("CMCD_TEXT_TRACK_ERROR","Could not generate text track CMCD data.",e),p=m}return l.src=p,l.label=a,l.kind=i,l.srclang=n,e.h.getAttribute("crossorigin")||e.h.setAttribute("crossorigin","anonymous"),e.h.appendChild(l),c.return(l)}))}function Il(e,t,n,i){var r,a,s;return I((function(o){if(1==o.g){r=la,(a=aa([t],i)).method="GET";var u=e.O;try{u.g.enabled&&Wd(u,a,{ot:"c",su:!0})}catch(e){K("CMCD_TEXT_ERROR","Could not generate text CMCD data.",e)}return M(o,n.request(r,a).promise,2)}return s=o.h,o.return(s.data)}))}function Pl(e,t,n,i){var r=Ui[n];if(r)return n=r(),e={periodStart:0,segmentStart:0,segmentEnd:e.h.duration,vttOffset:0},t=pe(t),function(e,t){function n(e){for(var n=e,i=d(t),r=i.next();!r.done;r=i.next())(r=r.value).end&&r.start<e&&(n+=r.end-r.start);return(10>(e=Math.floor(n/3600))?"0":"")+e+":"+(10>(i=Math.floor(n/60%60))?"0":"")+i+":"+(10>(r=Math.floor(n%60))?"0":"")+r+"."+(100>(n=Math.floor(1e3*n%1e3))?10>n?"00":"0":"")+n}var i=xd(e);e="WEBVTT\n\n";for(var r=(i=d(i)).next();!r.done;r=i.next())e+=n((r=r.value).startTime)+" --\x3e "+n(r.endTime)+function(e){var t=[];switch(e.textAlign){case"left":t.push("align:left");break;case"right":t.push("align:right");break;case gn:t.push("align:middle");break;case"start":t.push("align:start");break;case"end":t.push("align:end")}switch(e.writingMode){case"vertical-lr":t.push("vertical:lr");break;case"vertical-rl":t.push("vertical:rl")}return t.length?" "+t.join(" "):""}(r)+"\n",e+=r.payload+"\n\n";return e}(t=n.parseMedia(t,e,null,[]),i);throw new Ye(2,2,2014,n)}function Cl(e){var t=dd();return t.streaming.failureCallback=function(t){if(e.U()){var n=null;1001==t.code||1002==t.code?(n=1,e.g.streaming.lowLatencyMode&&(n=.1)):1003==t.code&&(n=.1),null!=n&&(t.severity=1,e.Nf(n))}},t.textDisplayFactory=function(){if(!e.ge||et()&&!document.fullscreenEnabled)return HTMLMediaElement.prototype.addTextTrack?new Id(e.h,"Shaka Player TextTrack"):new Cd;var t=e.getConfiguration();return new jd(e.h,e.ge,t.textDisplayer)},t}function jl(e){var t=e.tf();if(e.A&&e.M&&e.F){var n=e.K;if(n.j=t,au(n),e.O&&(n=e.O,t||n.l||(n.l=!0),n.l&&t&&(n.m=!0),n.o=t),Ol(e),n=e.g.streaming.liveSync.dynamicTargetLatency.maxAttempts,e.g.streaming.liveSync.dynamicTargetLatency.enabled&&t&&e.Ee<n){n=e.g.streaming.liveSync.dynamicTargetLatency.maxLatency;var i=e.g.streaming.liveSync.targetLatencyTolerance,r=e.g.streaming.liveSync.dynamicTargetLatency.rebufferIncrement;e.S&&(e.S=Math.min(e.S+ ++e.Ee*r,n-i))}}t=(new Map).set("buffering",t),e.dispatchEvent(cl("buffering",t))}function Ol(e){if(e.A&&e.M){var t=e.A.g,n="playing";e.M.g==Hr?n="buffering":e.h.ended?n="ended":e.h.paused&&(n="paused");var i=n;if(null==t.g)t.g={timestamp:Date.now()/1e3,state:i,duration:0},t=!0;else{var r=Date.now()/1e3;t.g.duration=r-t.g.timestamp,t.g.state==i?t=!1:(t.h.push(t.g),t.g={timestamp:r,state:i,duration:0},t=!0)}t&&(n=(new Map).set("newstate",n),e.dispatchEvent(cl("statechanged",n)))}}function Rl(e){var t=e.h.playbackRate,n=e.U();if(e.g.streaming.vodDynamicPlaybackRate&&!n){var i=e.g.streaming.vodDynamicPlaybackRateLowBufferRate,r=e.yg();r<=e.g.streaming.vodDynamicPlaybackRateBufferRatio?t!=i&&e.Bd(i,!1):1==r&&t!==e.K.oc()&&e.$c()}if(n&&(n=e.Qb(),Number.isFinite(n.end)&&!(e.h.currentTime<n.start||e.h.paused))){i=e.g.streaming.liveSync.targetLatencyTolerance,r=e.g.streaming.liveSync.dynamicTargetLatency.enabled;var a=e.g.streaming.liveSync.dynamicTargetLatency.stabilityThreshold;if(e.g.streaming.liveSync&&e.g.streaming.liveSync.enabled)var s=e.g.streaming.liveSync.targetLatency,o=s+i,u=Math.max(0,s-i),d=e.g.streaming.liveSync.maxPlaybackRate,l=e.g.streaming.liveSync.minPlaybackRate;else e.i&&e.i.serviceDescription&&(s=e.i.serviceDescription.targetLatency,null!=e.i.serviceDescription.targetLatency?o=e.i.serviceDescription.targetLatency+i:null!=e.i.serviceDescription.maxLatency&&(o=e.i.serviceDescription.maxLatency),null!=e.i.serviceDescription.targetLatency?u=Math.max(0,e.i.serviceDescription.targetLatency-i):null!=e.i.serviceDescription.minLatency&&(u=e.i.serviceDescription.minLatency),d=e.i.serviceDescription.maxPlaybackRate||e.g.streaming.liveSync.maxPlaybackRate,l=e.i.serviceDescription.minPlaybackRate||e.g.streaming.liveSync.minPlaybackRate);e.S||"number"!=typeof s||(e.S=s);var c=e.g.streaming.liveSync.dynamicTargetLatency.maxAttempts;r&&e.Aa&&null!==e.S&&"number"==typeof s&&e.Ee<c&&Date.now()-e.Aa>1e3*a&&(a=e.g.streaming.liveSync.dynamicTargetLatency.minLatency,e.S=Math.max(e.S-(s-a)/2,a+i),e.Aa=Date.now()),r&&null!==e.S&&(o=e.S+i,u=e.S-i),s=n.end-e.h.currentTime,i=0,e.m==oc&&0<(r=e.h.buffered).length&&(i=r.end(r.length-1),i=Math.max(d,i-n.end)),n=e.g.streaming.liveSync.panicMode,r=1e3*e.g.streaming.liveSync.panicThreshold,a=Date.now()-e.M.h,n&&!l&&(l=e.g.streaming.liveSync.minPlaybackRate),n&&l&&a<=r?t!=l&&e.Bd(l,!1):null!=o&&d&&s-i>o?(t!=d&&e.Bd(d,!1),e.Aa=null):null!=u&&l&&s-i<u?(t!=l&&e.Bd(l,!1),e.Aa=null):t!==e.K.oc()&&(e.$c(),e.Aa=Date.now())}}function Nl(e){if(e.h){var t,n=function(t,n){var i=void 0===i?Number.EPSILON:i;if(t===n)i=!0;else{var r=Math.abs(t-n);i=r<=i||i!==Number.EPSILON&&Math.abs(r-i)<=Number.EPSILON}return!!((i||n>t)&&e.eg<t)&&(e.eg=t,!0)},i=e.h.currentTime/e.h.duration;isNaN(i)||(n(0,i*=100)?t=cl("started"):n(25,i)?t=cl("firstquartile"):n(50,i)?t=cl("midpoint"):n(75,i)?t=cl("thirdquartile"):n(100,i)&&(t=cl("complete")),t&&e.dispatchEvent(t))}}function Hl(e){try{ss(e.de,e.i)}catch(t){return Jl(e,t),!1}var t=vr(e.i.variants);return t=e.xa.create(t),e.o.setVariants(Array.from(t.values())),!0}function Ul(e,t,n,i,r){var a;t=void 0===t||t,n=void 0===n?0:n,i=void 0!==i&&i,r=void 0===r||r,(a=Hl(e)?e.o.chooseVariant():null)&&Fl(e,a,r,t,n,i)}function Fl(e,t,n,i,r,a){a=void 0!==a&&a;var s=e.j.j;if(t==s)i&&Cu(e.j,t,i,r,!0);else{var o=e.A.h;o.h!=t&&(o.h=t,o.g.push({timestamp:Date.now()/1e3,id:t.id,type:"variant",fromAdaptation:n,bandwidth:t.bandwidth})),Cu(e.j,t,i,r,a,n),i=null,s&&(i=cr(s)),(t=cr(t)).active=!0,n?(n=(new Map).set("oldTrack",i).set("newTrack",t),e.L&&co(e.L,t,e.lf()),tc(e,n=cl("adaptation",n))):zl(e,i,t)}}function Bl(e,t){var n=Array.from(e.h.audioTracks).find((function(e){return e.enabled}));t.enabled=!0,n&&(t.id!==n.id&&(n.enabled=!1),zl(e,n=gr(n),t=gr(t)))}function Wl(e){tc(e,cl("trackschanged"))}function zl(e,t,n){t=(new Map).set("oldTrack",t).set("newTrack",n),e.L&&co(e.L,n,e.lf()),tc(e,n=cl("variantchanged",t))}function Vl(e){tc(e,cl("textchanged"))}function Gl(e){tc(e,cl("texttrackvisibility"))}function ql(e){e.g.abr.enabled||Kl(e),tc(e,cl("abrstatuschanged",(new Map).set("newStatus",e.g.abr.enabled)))}function $l(e){var t=e.qc().find((function(e){return e.active}));t&&e.B&&e.B.setTextLanguage&&e.B.setTextLanguage(t.language)}function Kl(e,t){if(t=void 0===t||t,e.m==sc){e.je.stop();for(var n=d(e.i.variants),i=n.next();!i.done;i=n.next())i.value.disabledUntilTime=0;t&&Hl(e)}}function Jl(e,t){var n,i,r,a;return I((function(s){switch(s.g){case 1:if(e.m==rc)return s.return();if(1===t.severity&&e.A.K++,n=!0,!(e.Ba&&e.i&&e.j)||3016!=t.code&&3014!=t.code&&3015!=t.code&&3018!=t.code){s.u(2);break}return b(s,3),M(s,Xu(e.j),5);case 5:i=s.h,n=!i,i&&(r=cl("mediasourcerecovered"),e.dispatchEvent(r)),L(s,2);break;case 3:S(s),n=!0;case 2:if(!n)return s.return();2===t.severity&&Kl(e,!1),a=cl("error",(new Map).set("detail",t)),e.dispatchEvent(a),a.defaultPrevented&&(t.handled=!0),w(s)}}))}function Xl(e,t,n,i){i=void 0===i?e:i,e=(new Map).set("detail",{schemeIdUri:n.schemeIdUri,value:n.value,startTime:n.startTime,endTime:n.endTime,id:n.id,eventElement:n.eventElement,eventNode:n.eventNode}),i.dispatchEvent(cl(t,e))}function Ql(e,t,n,i){i=void 0!==i&&i,t=(new Map).set("mediaQuality",{bandwidth:t.bandwidth,audioSamplingRate:t.audioSamplingRate,codecs:t.codecs,contentType:t.contentType,frameRate:t.frameRate,height:t.height,mimeType:t.mimeType,channelsCount:t.channelsCount,pixelAspectRatio:t.pixelAspectRatio,width:t.width,label:t.label,roles:t.roles,language:t.language}).set("position",n),e.dispatchEvent(cl(i?"audiotrackchanged":"mediaqualitychanged",t))}function Zl(e,t){if(t=void 0===t||t,!e.h.error)return t?new Ye(2,3,3016):null;var n=e.h.error.code;return t||1!=n?((t=e.h.error.msExtendedCode)&&(0>t&&(t+=Math.pow(2,32)),t=t.toString(16)),new Ye(2,3,3016,n,t,e.h.error.message)):null}function ec(e,t,n){0<t&&(e.U()||e.jh(t)),n<(t=e.getDuration())&&(e.U()||e.bb(n))}function tc(e,t){I((function(n){if(1==n.g)return M(n,Promise.resolve(),2);e.m!=rc&&e.dispatchEvent(t),w(n)}))}function nc(e){for(var t=new Set,n=(e=d(e)).next();!n.done;n=e.next())(n=n.value).language?t.add(Ki(n.language)):t.add("und");return t}function ic(e){for(var t=new Map,n=new Map,i=(e=d(e)).next();!i.done;i=e.next()){var r="und",a=[];(i=i.value).language&&(r=Ki(i.language)),(a="variant"==i.type?i.audioRoles:i.roles)&&a.length||(a=[""]),t.has(r)||t.set(r,new Set);for(var s=(a=d(a)).next();!s.done;s=a.next())s=s.value,t.get(r).add(s),i.label&&(n.has(r)||n.set(r,new Map),n.get(r).set(s,i.label))}var o=[];return t.forEach((function(e,t){for(var i=(e=d(e)).next();!i.done;i=e.next()){i=i.value;var r=null;n.has(t)&&n.get(t).has(i)&&(r=n.get(t).get(i)),o.push({language:t,role:i,label:r})}})),o}ol.prototype.release=function(){0<this.h.length?this.h.shift()():this.g=null},g(dl,Zr),(i=dl.prototype).destroy=function(){var e,t=this;return I((function(n){switch(n.g){case 1:return t.m==rc?n.return():(ll(t),e=t.detach(),t.m=rc,M(n,e,2));case 2:return M(n,t.Te(),3);case 3:if(t.te&&(t.te.release(),t.te=null),t.od&&(t.od.release(),t.od=null),t.l&&(t.l.release(),t.l=null),t.Ga&&(t.Ga.release(),t.Ga=null),t.Na&&(t.Na.release(),t.Na=null),t.ta=null,t.g=null,t.A=null,t.ge=null,t.O=null,t.da=null,!t.G){n.u(4);break}return M(n,t.G.destroy(),5);case 5:t.G=null;case 4:t.o&&(t.o.release(),t.o=null),Zr.prototype.release.call(t),w(n)}}))},i.Tb=function(e,t){t=void 0===t||t;var n,i,r,a=this;return I((function(s){switch(s.g){case 1:if(a.m==rc)throw new Ye(2,7,7e3);if(n=a.h&&a.h==e,!a.h||a.h==e){s.u(2);break}return M(s,a.detach(),2);case 2:return M(s,ml(a,"attach"),4);case 4:if(s.h)return s.return();if(b(s,5,6),n||(hl(a,"attach"),i=function(){var e=Zl(a,!1);e&&Jl(a,e)},a.od.D(e,"error",i),a.h=e),!t||!Ue()||a.I){s.u(6);break}return M(s,vl(a),6);case 6:k(s),a.Z.release(),D(s,0);break;case 5:return r=S(s),M(s,a.detach(),10);case 10:throw r}}))},i.Ch=function(e){this.gg=e},i.detach=function(e){e=void 0!==e&&e;var t=this;return I((function(n){if(1==n.g){if(t.m==rc)throw new Ye(2,7,7e3);return M(n,t.ic(!1,e),2)}if(3!=n.g)return M(n,ml(t,"detach"),3);if(n.h)return n.return();try{t.h&&(t.od.Va(),t.h=null),hl(t,"detach"),t.s&&!e&&t.s.release()}finally{t.Z.release()}w(n)}))},i.ic=function(e,t){e=void 0===e||e,t=void 0!==t&&t;var n,i,r,a,s,o,u,l,c,h,m=this;return I((function(f){switch(f.g){case 1:return m.m!=rc&&(m.m=ac),M(f,ml(m,"unload"),2);case 2:return f.h?f.return():(T(f,3),m.Ba=!1,hl(m,"unload"),e&&!Ue()&&(e=!1),ll(m),n=m.qd.map((function(e){return e()})),m.qd=[],M(f,Promise.all(n),5));case 5:if(m.dispatchEvent(cl("unloading")),m.bc&&(m.bc.release(),m.bc=null),m.h&&(m.l.Va(),m.Ga.Va()),m.je.stop(),m.Hb&&(m.Hb.release(),m.Hb=null),m.ie&&(m.ie.stop(),m.ie=null),!m.H){f.u(6);break}return M(f,m.H.stop(),7);case 7:m.H=null,m.La=null;case 6:if(!m.o){f.u(8);break}return M(f,m.o.stop(),8);case 8:if(!m.j){f.u(10);break}return M(f,m.j.destroy(),11);case 11:m.j=null;case 10:if(m.K&&(m.K.release(),m.K=null),m.F&&(m.F.release(),m.F=null),!st("webkit")||!m.C){f.u(12);break}return M(f,m.C.destroy(),13);case 13:m.C=null;case 12:if(!m.I){f.u(14);break}return M(f,m.I.destroy(),15);case 15:m.I=null;case 14:if(m.s&&!t&&m.s.onAssetUnload(),m.aa&&!t&&(m.aa.destroy(),m.aa=null),t||m.Fe.stop(),m.O&&function(e){e.l=!1,e.o=!0,e.m=!1,e.j=!1}(m.O),m.da&&(m.da.g=null),!m.B){f.u(16);break}return M(f,m.B.destroy(),17);case 17:m.B=null;case 16:if(m.h&&(Ds(m.h),m.h.src&&(m.h.removeAttribute("src"),m.h.load())),!m.C){f.u(18);break}return M(f,m.C.destroy(),19);case 19:m.C=null;case 18:if(m.na&&m.Y!=m.na.Mc()&&(m.na.s||m.na.destroy(),m.na=null),m.Y=null,m.Ka=null,m.M=null,m.i){for(i=d(m.i.variants),r=i.next();!r.done;r=i.next())for(a=r.value,s=d([a.audio,a.video]),o=s.next();!o.done;o=s.next())(u=o.value)&&u.segmentIndex&&u.segmentIndex.release();for(l=d(m.i.textStreams),c=l.next();!c.done;c=l.next())(h=c.value).segmentIndex&&h.segmentIndex.release()}m.g&&m.g.streaming.clearDecodingCache&&(Lr={},Re.clear()),m.i=null,m.A=new hu,m.Ae=null,m.Aa=null,m.S=null,m.Ee=-1,m.ud=[],m.eg=-1,jl(m);case 3:k(f),m.Z.release(),D(f,4);break;case 4:if(e&&Ue()&&!m.I&&m.h)return M(f,vl(m),0);f.u(0)}}))},i.ij=function(e){this.ga=e},i.load=function(t,n,i){n=void 0===n?null:n;var r,a,s,o,u,l,c,h,m,f,p,g,y,_=this;return I((function(v){switch(v.g){case 1:if(_.m==rc)throw new Ye(2,7,7e3);return r=null,a="",a=t instanceof md?(r=t).Mc()||"":t||"",M(v,ul(_.Z,"load"),2);case 2:if(_.Z.release(),!_.h)throw new Ye(2,7,7002);if(!_.Y){v.u(3);break}return _.Y=a,M(v,_.ic(!1),3);case 3:if(s=++_.Ce,o=function(){return I((function(e){if(1==e.g)return _.Ce==s?e.u(0):r?M(e,r.destroy(),3):e.u(3);throw new Ye(2,7,7e3)}))},u=function(e,t){return I((function(n){switch(n.g){case 1:return T(n,2),M(n,ul(_.Z,t),4);case 4:return M(n,o(),5);case 5:return M(n,e(),6);case 6:return M(n,o(),7);case 7:r&&_.g&&(r.g=_.g);case 2:k(n),_.Z.release(),D(n,0)}}))},b(v,5,6),null==n&&r&&(n=r.getStartTime()),_.ga=n,_.Ba=!1,_.dispatchEvent(cl("loading")),r){i=r.Y,v.u(8);break}if(i){v.u(8);break}return M(v,u((function(){return I((function(e){if(1==e.g)return M(e,yl(_,a),2);i=e.h,w(e)}))}),"guessMimeType_"),8);case 8:if(l=!!r,r){pd(r,_),_.A=r.getStats(),v.u(11);break}return M(v,pl(_,a,n,i,!0),12);case 12:(r=v.h)?(r.A=!1,pd(r,_),_.A=r.getStats(),r.start(),r.m.catch((function(){}))):_.A=new hu;case 11:return c=!r,h=Date.now()/1e3,_.A=r?r.getStats():new hu,_.Y=a,_.Ka=i||null,c?M(v,u((function(){return I((function(e){return M(e,function(e,t){var n,i,r,a,s;return I((function(o){return 1==o.g?(n=vi,i=Date.now()/1e3,r=!0,e.C=e.Gc({Nb:e.G,onError:function(t){Jl(e,t)},ee:function(){},onExpirationUpdated:function(){var t=cl("expirationupdated");e.dispatchEvent(t)},onEvent:function(t){e.dispatchEvent(t),"drmsessionupdate"==t.type&&r&&(r=!1,e.A.j=Date.now()/1e3-i)}}),e.C.configure(e.g.drm),a={id:0,language:"und",disabledUntilTime:0,primary:!1,audio:null,video:null,bandwidth:100,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},(s={id:0,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:t?Yi(t):"",codecs:t?Ei(t):"",encrypted:!0,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:n.la,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set,isAudioMuxedInVideo:!1}).fullMimeTypes.add(Ti(s.mimeType,s.codecs)),t.startsWith("audio/")?(s.type=n.V,a.audio=s):a.video=s,e.C.da=!0,M(o,ja(e.C,[a],[]),2)):M(o,e.C.Tb(e.h),0)}))}(_,i),0)}))}),"initializeSrcEqualsDrmInner_"),21):M(v,u((function(){return I((function(e){if(1==e.g)return M(e,Promise.race([r.fa,r.m]),2);_.La=r.G;var t=r;t.ga=!0,_.H=t.j,_.i=r.kf(),w(e)}))}),"waitForFinish"),15);case 15:if(_.I){v.u(16);break}return M(v,u((function(){return I((function(e){return M(e,vl(_),0)}))}),"initializeMediaSourceEngineInner_"),16);case 16:return M(v,u((function(){return I((function(e){return M(e,r.m,0)}))}),"waitForFinish"),18);case 18:return _.g=r.getConfiguration(),_.de=r.F,_.H&&_.H.setMediaElement&&_.h&&_.H.setMediaElement(_.h),_.bc=function(e){return e.na=!0,e.H}(r),_.ac=r.Aa,(m=r.o)&&(_.xa=m),l&&_.h&&"AUDIO"===_.h.nodeName&&(function(e){for(var t=d(e.i.variants),n=t.next();!n.done;n=t.next())(n=n.value).video&&(n.video.closeSegmentIndex(),n.video=null),n.bandwidth=n.audio&&n.audio.bandwidth?n.audio.bandwidth:0;e.i.variants=e.i.variants.filter((function(e){return e.audio}))}(_),_.configure("manifest.disableVideo",!0)),_.C=function(e){return e.da=!0,e.l}(r),M(v,u((function(){return I((function(e){return M(e,_.C.Tb(_.h),0)}))}),"drmEngine_.attach"),19);case 19:return!(f=r.C)||_.ta&&_.ta==f||(_.o=function(e){return e.aa=!0,e.i}(r),_.ta=r.C,"function"!=typeof _.o.setMediaElement&&(se("AbrManager w/o setMediaElement","Please use an AbrManager with setMediaElement function."),_.o.setMediaElement=function(){}),"function"!=typeof _.o.setCmsdManager&&(se("AbrManager w/o setCmsdManager","Please use an AbrManager with setCmsdManager function."),_.o.setCmsdManager=function(){}),"function"!=typeof _.o.trySuggestStreams&&(se("AbrManager w/o trySuggestStreams","Please use an AbrManager with trySuggestStreams function."),_.o.trySuggestStreams=function(){})),p=function(e){return e.ta=!0,e.L}(r),g=r.ja,M(v,u((function(){return I((function(e){return M(e,function(e,t,n,i){var r,a,s,o,u,l,c,h,m,f,p,g,y,_,v,b,T,L,S,k;return I((function(D){switch(D.g){case 1:hl(e,"load"),r=e.h,e.K=new ru({Pd:function(){return r.playbackRate},oc:function(){return r.defaultPlaybackRate},Vf:function(e){r.playbackRate=e},Og:function(e){r.currentTime+=e}}),Ml(e,r,t),function(e,t){t.lcevc.enabled?(ll(e),null==e.L&&(e.L=new uo(e.h,e.gg,t.lcevc),e.I&&(e.I.da=e.L))):ll(e)}(e,e.g),e.Gb=e.g.preferredTextLanguage,e.sd=e.g.preferredTextRole,e.rd=e.g.preferForcedSubs,ec(e.i.presentationTimeline,e.g.playRangeStart,e.g.playRangeEnd),e.o.init((function(t,n,i){e.i&&e.j&&t!=e.j.j&&Fl(e,t,!0,void 0!==n&&n,void 0===i?0:i)})),e.o.setMediaElement(r),e.o.setCmsdManager(e.da),e.j=function(e){return new Iu(e.i,{hd:function(){return e.F?e.F.Dd():0},getBandwidthEstimate:function(){return e.o.getBandwidthEstimate()},ib:function(){return e.ib()},ca:e.I,Nb:e.G,onError:function(t){return Jl(e,t)},onEvent:function(t){return e.dispatchEvent(t)},Ef:function(t,n){var i=t.startTime;t=t.endTime;var r=n.type;if(n=n.codecs.includes(","),r!=_i){if(e.F){e.F.Pg();var a=yo(e.I,r);!e.U()&&e.h.paused&&null!=a&&0<a&&e.F.Dd()<a&&e.F.Ie(a)}Ll(e)}i=(new Map).set("start",i).set("end",t).set("contentType",r).set("isMuxed",n),e.dispatchEvent(cl("segmentappended",i))},Ei:function(t,n){(n=n.Qc)&&e.ac&&function(e,t,n){var i=function(e,t){var n=e.g.get(t);return n||(n={yd:[],Se:null,contentType:t},e.g.set(t,n)),n}(e,t.contentType);!function(e,t){if((e=e.h()[t.contentType])&&0<e.length){var n=e[0].start,i=e[e.length-1].end,r=t.yd;t.yd=r.filter((function(e,t){return!(e.position<=n&&t+1<r.length&&r[t+1].position<=n||e.position>=i)}))}else t.yd=[]}(e,i),e={Qc:t,position:n},0<=(t=(i=i.yd).findIndex((function(e){return e.position>=n})))?i.splice(t,i[t].position==n?1:0,e):i.push(e)}(e.ac,n,t)},mg:function(t,n){var i=e.C;if(i.h.parseInbandPsshEnabled&&!i.F&&["audio","video"].includes(t)){t=new Ia(pe(n)),n=0;for(var r=d(t.data),a=r.next();!a.done;a=r.next())n+=a.value.length;if(0==n)i=Promise.resolve();else{for(n=new Uint8Array(n),r=0,a=(t=d(t.data)).next();!a.done;a=t.next())a=a.value,n.set(a,r),r+=a.length;Ha(i,"cenc",n),i=i.m}}else i=Promise.resolve();return i},disableStream:function(t,n){return e.disableStream(t,n)}})}(e),e.j.configure(e.g.streaming),e.m=sc,e.dispatchEvent(cl("streaming")),a=n;case 2:for((o=e.j.j)||a||(a=Hl(e)?e.o.chooseVariant():null),u=[],l=d([(s=o||a).video,s.audio]),c=l.next();!c.done;c=l.next())(h=c.value)&&!h.segmentIndex&&u.push(h.createSegmentIndex());if(!(0<u.length)){D.u(4);break}return M(D,Promise.all(u),4);case 4:if(!s||0!=s.disabledUntilTime){D.u(2);break}if(e.H&&e.H.onInitialVariantChosen&&e.H.onInitialVariantChosen(s),e.i.isLowLatency&&!e.g.streaming.lowLatencyMode&&$("Low-latency live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details."),e.O&&function(e,t){e.j=t,e.j?e.i==Xd?e.i=Qd:e.i==Zd&&(e.i=el):e.i==Qd?e.i=Xd:e.i==el&&(e.i=Zd)}(e.O,e.i.isLowLatency&&e.g.streaming.lowLatencyMode),ec(e.i.presentationTimeline,e.g.playRangeStart,e.g.playRangeEnd),function(e,t,n){e.l.presentationTimeline.U()||(e.O=t,e.M=n)}(e.j,e.g.playRangeStart,e.g.playRangeEnd),m=function(t){e.F=function(e,t){return new Ko(e.h,e.i,e.g.streaming,t,(function(){e.Hb&&ou(e.Hb,!0),e.j&&e.j.Xc(),e.M&&Ll(e)}),(function(t){return e.dispatchEvent(t)}))}(e,t),e.Hb=function(e,t){(t=new vd(e.bc,e.U()||0<t)).addEventListener("enter",(function(t){Xl(e,"timelineregionenter",t.region)})),t.addEventListener("exit",(function(t){Xl(e,"timelineregionexit",t.region)})),t.addEventListener("skip",(function(t){var n=t.region;t.seeking||(Xl(e,"timelineregionenter",n),Xl(e,"timelineregionexit",n))}));var n=new su(e.h);return n.g.add(t),e.ac&&n.g.add(e.ac),n}(e,t),Tl(e,r,Math.max(e.i.minBufferTime,e.g.streaming.rebufferingGoal))},e.g.streaming.startAtSegmentBoundary||(null==(f=e.ga)&&e.i.startTime&&(f=e.i.startTime),m(f)),o){D.u(7);break}if(!e.g.streaming.startAtSegmentBoundary){D.u(8);break}return p=e.i.presentationTimeline,g=e.ga||e.h.currentTime,null==e.ga&&e.i.startTime&&(g=e.i.startTime),y=p.Kb(),_=p.Bb(),g<y?g=y:g>_&&(g=_),M(D,function(e,t){var n,i,r,a,s;return I((function(o){return 1==o.g?(n=e.audio,i=e.video,r=function(e,t){var n,i,r;return I((function(a){return 1==a.g?e?M(a,e.createSegmentIndex(),2):a.return(null):(i=(n=e.segmentIndex.Jb(t))?n.next().value:null)?(r=i.startTime,a.return(r)):a.return(null)}))},M(o,r(n,t),2)):3!=o.g?(a=o.h,M(o,r(i,t),3)):null!=(s=o.h)&&null!=a?o.return(Math.max(s,a)):null!=s?o.return(s):null!=a?o.return(a):o.return(t)}))}(a,g),9);case 9:v=D.h,m(v);case 8:Fl(e,a,!0,!1,0);case 7:return e.F.ready(),e.qc().find((function(e){return e.active}))||((b=Mr(e.i.textStreams,e.Gb,e.sd,e.rd)[0]||null)&&cu(e.A.h,b,!0),a&&(b?(function(e,t,n){if(0==e.g.autoShowText)return!1;if(1==e.g.autoShowText)return!0;var i=Ki(e.g.preferredTextLanguage);return n=Ki(n.language),2==e.g.autoShowText?Gi(n,i):3==e.g.autoShowText?!!t&&(e=Ki(t.language),Gi(n,i)&&!Gi(e,n)):($("Invalid autoShowText setting!"),!1)}(e,a.audio,b)&&(e.ja=!0),e.ja&&e.B.setTextVisibility(!0),Gl(e)):e.ja=!1),b&&(e.g.streaming.alwaysStreamText||e.vf())&&(ju(e.j,b),$l(e))),M(D,e.j.start(i),10);case 10:e.g.abr.enabled&&(e.o.enable(),ql(e)),Wl(e),Hl(e),e.i.variants.some((function(e){return e.primary})),((T=e.U())&&(e.g.streaming.liveSync&&e.g.streaming.liveSync.enabled||e.i.serviceDescription||e.g.streaming.liveSync.panicMode)||e.g.streaming.vodDynamicPlaybackRate)&&(L=function(){return Rl(e)},e.l.D(r,"timeupdate",L)),T||(S=function(){return Nl(e)},e.l.D(r,"timeupdate",S),Nl(e),e.i.nextUrl&&(0<e.g.streaming.preloadNextUrlWindow&&(k=function(){var t;return I((function(n){if(1==n.g)return t=e.h.duration-e.h.currentTime,!isNaN(t)&&t<=e.g.streaming.preloadNextUrlWindow?(e.l.cb(r,"timeupdate",k),M(n,e.preload(e.i.nextUrl),4)):n.u(0);e.na=n.h,w(n)}))},e.l.D(r,"timeupdate",k)),e.l.D(r,"ended",(function(){e.load(e.na||e.i.nextUrl)})))),e.s&&e.s.onManifestUpdated(T),e.Ba=!0,w(D)}}))}(_,h,g,p),0)}))}),"loadInner_"),20);case 20:!function(e){if(e.I)for(var t=d(e.I),n=t.next();!n.done;n=t.next())(n=n.value)();e.I=null}(r),_.Ka&&et()&&Ii(_.Ka)&&function(t,n,i){t.g&&e.ManagedMediaSource&&t.l&&(t.B&&t.g.removeChild(t.B),t.B=ks(n,i),t.g.appendChild(t.B),t.g.disableRemotePlayback=!1)}(_.I,_.Y,_.Ka),v.u(14);break;case 21:return M(v,u((function(){return I((function(e){return M(e,function(e,t,n){var i,r,a,s,o,u,l,c,h,m,f,p;return I((function(g){switch(g.g){case 1:if(hl(e,"src-equals"),i=e.h,e.F=new $o(i),r=!1,e.qd.push((function(){r=!0})),null!=e.ga&&e.F.Ie(e.ga),e.K=new ru({Pd:function(){return i.playbackRate},oc:function(){return i.defaultPlaybackRate},Vf:function(e){i.playbackRate=e},Og:function(e){i.currentTime+=e}}),a=e.g.streaming.rebufferingGoal,Tl(e,i,a),i.textTracks&&(_l(e),s=function(){var t=xl(e).find((function(e){return"disabled"!==e.mode}));t&&(t.mode="showing")},o=function(){var t=xl(e).find((function(e){return"disabled"!==e.mode}));t&&(t.mode="hidden")},e.l.D(i,"enterpictureinpicture",(function(){return s()})),e.l.D(i,"leavepictureinpicture",(function(){return o()})),i.remote?(e.l.D(i.remote,"connect",(function(){return o()})),e.l.D(i.remote,"connecting",(function(){return o()})),e.l.D(i.remote,"disconnect",(function(){return o()}))):"webkitCurrentPlaybackTargetIsWireless"in i&&e.l.D(i,"webkitcurrentplaybacktargetiswirelesschanged",(function(){return o()})),(u=i).webkitSupportsFullscreen&&e.l.D(u,"webkitpresentationmodechanged",(function(){"inline"!=u.webkitPresentationMode?s():o()}))),Ml(e,i,t),l=function(e,t,n){try{if(!e.g.enabled)return t;var i=Bd(e);e:{switch(n.toLowerCase()){case"audio/mp4":case"audio/webm":case"audio/ogg":case"audio/mpeg":case"audio/aac":case"audio/flac":case"audio/wav":var r=qd;break e;case"video/webm":case"video/mp4":case"video/mpeg":case"video/mp2t":r=Kd;break e;case"application/x-mpegurl":case"application/vnd.apple.mpegurl":case"application/dash+xml":case"video/vnd.mpeg.dash.mpd":case"application/vnd.ms-sstr+xml":r="m";break e}r=void 0}return i.ot=r,i.su=!0,Gd(t,Vd(i))}catch(e){return K("CMCD_SRC_ERROR","Could not generate src CMCD data.",e),t}}(e.O,e.Y,n),!l.includes("#t=")&&(0<e.g.playRangeStart||isFinite(e.g.playRangeEnd))&&(l+="#t=",0<e.g.playRangeStart&&(l+=e.g.playRangeStart),isFinite(e.g.playRangeEnd)&&(l+=","+e.g.playRangeEnd)),!e.I){g.u(2);break}return M(g,e.I.destroy(),3);case 3:e.I=null;case 2:return Ds(i),i.src=l,(ze()||Ge())&&i.load(),"none"!=i.preload&&!i.autoplay&&Ii(n)&&et()&&i.load(),e.m=oc,e.dispatchEvent(cl("streaming")),c=new Wr,Ho(i,HTMLMediaElement.HAVE_METADATA,e.l,(function(){e.F.ready(),c.resolve()})),Ho(i,HTMLMediaElement.HAVE_CURRENT_DATA,e.l,(function(){var t,n,a,s,o;return I((function(u){if(1==u.g)return function(e){var t=e.g.preferredAudioLanguage;""!=t&&e.$g(t,e.g.preferredVariantRole)}(e),(t=xl(e)).find((function(e){return"disabled"!=e.mode}))?(0<t.length&&(e.ja=!0,e.B.setTextVisibility(!0)),u.u(2)):M(u,new Promise((function(t){e.l.pa(i.textTracks,"change",t),new He(t).$(1)})),2);if(r)return u.return();for(n=!1,a=d(t),s=a.next();!s.done;s=a.next())"disabled"!==(o=s.value).mode&&(n?(o.mode="disabled",$("Found more than one enabled text track, disabling it",o)):(Dl(e,o),n=!0));!function(e){var t=e.g.preferredTextLanguage;""!=t&&e.Pf(t,e.g.preferredTextRole,e.g.preferForcedSubs)}(e),w(u)}))})),i.error?c.reject(Zl(e)):"none"==i.preload&&($('With <video preload="none">, the browser will not load anything until play() is called. We are unable to measure load latency in a meaningful way, and we cannot provide track info yet. Please do not use preload="none" with Shaka Player.'),c.resolve()),e.l.pa(i,"error",(function(){c.reject(Zl(e))})),M(g,zi(e.g.streaming.loadTimeout,c),4);case 4:((h=e.U())&&(e.g.streaming.liveSync&&e.g.streaming.liveSync.enabled||e.g.streaming.liveSync.panicMode)||e.g.streaming.vodDynamicPlaybackRate)&&(m=function(){return Rl(e)},e.l.D(i,"timeupdate",m)),h||(f=function(){return Nl(e)},e.l.D(i,"timeupdate",f),Nl(e)),e.s&&(e.s.onManifestUpdated(h),h&&(p=e.Qb().end,e.l.D(i,"progress",(function(){var t=e.Qb().end;p!=t&&(e.s.onManifestUpdated(e.U()),p=t)})))),e.Ba=!0,w(g)}}))}(_,h,i),0)}))}),"srcEqualsInner_"),14);case 14:_.dispatchEvent(cl("loaded"));case 6:if(k(v),!r){v.u(23);break}return M(v,r.destroy(),23);case 23:_.na=null,D(v,0);break;case 5:if(!(y=S(v))||7e3==y.code){v.u(25);break}return M(v,_.ic(!1),25);case 25:throw y}}))},i.ej=function(e,t){e=void 0===e||e,t=void 0!==t&&t;var n,i=this;return I((function(r){return 1==r.g?M(r,fl(i),2):3!=r.g?(n=r.h,M(r,i.ic(e,t),3)):r.return(n)}))},i.tg=function(e,t){e=void 0!==e&&e,t=void 0!==t&&t;var n,i=this;return I((function(r){return 1==r.g?M(r,fl(i,t),2):3!=r.g?(n=r.h,M(r,i.detach(e),3)):r.return(n)}))},i.preload=function(e,t,n){t=void 0===t?null:t;var i,r=this;return I((function(a){return 1==a.g?M(a,pl(r,e,t,n),2):((i=a.h)?i.start():Jl(r,new Ye(2,7,7005)),a.return(i))}))},i.Te=function(){var e,t,n,i,r=this;return I((function(a){for(e=[],t=d(r.le),n=t.next();!n.done;n=t.next())(i=n.value).s||e.push(i.destroy());return r.le=[],M(a,Promise.all(e),0)}))},i.Ni=function(){for(var e=this.Z;e.g;)e.release()},i.Gc=function(e){return new Ca(e)},i.configure=function(e,t){if(2==arguments.length&&"string"==typeof e&&(e=ed(e,t)),e.streaming&&"forceTransmuxTS"in e.streaming&&(se("streaming.forceTransmuxTS configuration","Please Use mediaSource.forceTransmux instead."),e.mediaSource.mediaSource=e.streaming.forceTransmuxTS,delete e.streaming.forceTransmuxTS),e.streaming&&"forceTransmux"in e.streaming&&(se("streaming.forceTransmux configuration","Please Use mediaSource.forceTransmux instead."),e.mediaSource.mediaSource=e.streaming.forceTransmux,delete e.streaming.forceTransmux),e.streaming&&"useNativeHlsOnSafari"in e.streaming&&(se("streaming.useNativeHlsOnSafari configuration","Please Use streaming.useNativeHlsForFairPlay or streaming.preferNativeHls instead."),e.streaming.preferNativeHls=e.streaming.useNativeHlsOnSafari&&Ke(),delete e.streaming.useNativeHlsOnSafari),e.streaming&&"boolean"==typeof e.streaming.liveSync){se("streaming.liveSync","Please Use streaming.liveSync.enabled instead.");var n=e.streaming.liveSync;e.streaming.liveSync={},e.streaming.liveSync.enabled=n}if(e.streaming&&(!e.streaming.liveSync||!("targetLatency"in e.streaming.liveSync))&&("liveSyncMinLatency"in e.streaming||"liveSyncMaxLatency"in e.streaming)){n=e.streaming.liveSyncMinLatency||0;var i=Math.abs((e.streaming.liveSyncMaxLatency||1)-n)/2;e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.targetLatency=n+i,e.streaming.liveSync.targetLatencyTolerance=i}if(e.streaming&&"liveSyncMaxLatency"in e.streaming&&(se("streaming.liveSyncMaxLatency","Please Use streaming.liveSync.targetLatency and streaming.liveSync.targetLatencyTolerance instead. Or, set the values in your DASH manifest"),delete e.streaming.liveSyncMaxLatency),e.streaming&&"liveSyncMinLatency"in e.streaming&&(se("streaming.liveSyncMinLatency","Please Use streaming.liveSync.targetLatency and streaming.liveSync.targetLatencyTolerance instead. Or, set the values in your DASH manifest"),delete e.streaming.liveSyncMinLatency),e.streaming&&"liveSyncTargetLatency"in e.streaming&&(se("streaming.liveSyncTargetLatency","Please Use streaming.liveSync.targetLatency instead."),e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.targetLatency=e.streaming.liveSyncTargetLatency,delete e.streaming.liveSyncTargetLatency),e.streaming&&"liveSyncTargetLatencyTolerance"in e.streaming&&(se("streaming.liveSyncTargetLatencyTolerance","Please Use streaming.liveSync.targetLatencyTolerance instead."),e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.targetLatencyTolerance=e.streaming.liveSyncTargetLatencyTolerance,delete e.streaming.liveSyncTargetLatencyTolerance),e.streaming&&"liveSyncPlaybackRate"in e.streaming&&(se("streaming.liveSyncPlaybackRate","Please Use streaming.liveSync.maxPlaybackRate instead."),e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.maxPlaybackRate=e.streaming.liveSyncPlaybackRate,delete e.streaming.liveSyncPlaybackRate),e.streaming&&"liveSyncMinPlaybackRate"in e.streaming&&(se("streaming.liveSyncMinPlaybackRate","Please Use streaming.liveSync.minPlaybackRate instead."),e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.minPlaybackRate=e.streaming.liveSyncMinPlaybackRate,delete e.streaming.liveSyncMinPlaybackRate),e.streaming&&"liveSyncPanicMode"in e.streaming&&(se("streaming.liveSyncPanicMode","Please Use streaming.liveSync.panicMode instead."),e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.panicMode=e.streaming.liveSyncPanicMode,delete e.streaming.liveSyncPanicMode),e.streaming&&"liveSyncPanicThreshold"in e.streaming&&(se("streaming.liveSyncPanicThreshold","Please Use streaming.liveSync.panicThreshold instead."),e.streaming.liveSync=e.streaming.liveSync||{},e.streaming.liveSync.panicThreshold=e.streaming.liveSyncPanicThreshold,delete e.streaming.liveSyncPanicThreshold),e.mediaSource&&"sourceBufferExtraFeatures"in e.mediaSource){se("mediaSource.sourceBufferExtraFeatures configuration","Please Use mediaSource.addExtraFeaturesToSourceBuffer() instead.");var r=e.mediaSource.sourceBufferExtraFeatures;e.mediaSource.addExtraFeaturesToSourceBuffer=function(){return r},delete e.mediaSource.sourceBufferExtraFeatures}return e.manifest&&e.manifest.hls&&"useSafariBehaviorForLive"in e.manifest.hls&&(se("manifest.hls.useSafariBehaviorForLive configuration","Please Use liveSync config to keep on live Edge instead."),delete e.manifest.hls.useSafariBehaviorForLive),e.streaming&&"parsePrftBox"in e.streaming&&(se("streaming.parsePrftBox configuration","Now fired without needing a configuration."),delete e.streaming.parsePrftBox),e.manifest&&e.manifest.dash&&"enableAudioGroups"in e.manifest.dash&&(se("manifest.dash.enableAudioGroups configuration","It is now enabled by default and cannot be disabled."),delete e.manifest.dash.enableAudioGroups),e.streaming&&"dispatchAllEmsgBoxes"in e.streaming&&(se("streaming.dispatchAllEmsgBoxes configuration","Please Use mediaSource.dispatchAllEmsgBoxes instead."),e.mediaSource.dispatchAllEmsgBoxes=e.streaming.dispatchAllEmsgBoxes,delete e.streaming.dispatchAllEmsgBoxes),e.streaming&&e.streaming.lowLatencyMode&&(null==e.streaming.inaccurateManifestTolerance&&(e.streaming.inaccurateManifestTolerance=0),null==e.streaming.rebufferingGoal&&(e.streaming.rebufferingGoal=.01),null==e.streaming.segmentPrefetchLimit&&(e.streaming.segmentPrefetchLimit=2),null==e.streaming.updateIntervalSeconds&&(e.streaming.updateIntervalSeconds=.1),null==e.streaming.maxDisabledTime&&(e.streaming.maxDisabledTime=1),null==e.streaming.retryParameters&&(e.streaming.retryParameters={}),null==e.streaming.retryParameters.baseDelay&&(e.streaming.retryParameters.baseDelay=100),null==e.manifest&&(e.manifest={}),null==e.manifest.dash&&(e.manifest.dash={}),null==e.manifest.dash.autoCorrectDrift&&(e.manifest.dash.autoCorrectDrift=!1),null==e.manifest.retryParameters&&(e.manifest.retryParameters={}),null==e.manifest.retryParameters.baseDelay&&(e.manifest.retryParameters.baseDelay=100),null==e.drm&&(e.drm={}),null==e.drm.retryParameters&&(e.drm.retryParameters={}),null==e.drm.retryParameters.baseDelay&&(e.drm.retryParameters.baseDelay=100)),n=ld(this.g,e,Cl(this)),Sl(this),n},i.getConfiguration=function(){var e=Cl(this);return ld(e,this.g,Cl(this)),e},i.Dg=function(){return ld(Cl(this),this.g,Cl(this)),nd(this.g,Cl(this))},i.yg=function(){if(this.h){var e=this.h.buffered.length;e=e?this.h.buffered.end(e-1):0;var t=this.getConfiguration().streaming.bufferingGoal;if(e>=(t=Math.min(this.h.currentTime+t,this.Qb().end)))return 1;if(!(e<=this.h.currentTime)&&e<t)return(e-this.h.currentTime)/(t-this.h.currentTime)}return 0},i.Ri=function(){for(var e in this.g)delete this.g[e];ld(this.g,Cl(this),Cl(this)),Sl(this)},i.Bg=function(){return this.m},i.lf=function(){return this.i?this.i.type:null},i.Yh=function(){return this.h},i.Ab=function(){return this.G},i.Mc=function(){return this.Y},i.xg=function(){return this.s?this.s:null},i.U=function(){return this.i&&!this.Ia()?this.i.presentationTimeline.U():!(!this.h||!this.h.src)&&1/0==this.h.duration},i.uc=function(){return!!this.i&&this.i.presentationTimeline.uc()},i.oi=function(){if(this.i&&!this.Ia()){var e=this.i.variants;return!!e.length&&!e[0].video}return!(!this.h||!this.h.src)&&(this.h.videoTracks?0==this.h.videoTracks.length:0==this.h.videoHeight)},i.Qb=function(){if(this.i&&!this.Ia()){if(!this.Ba&&"HLS"==this.i.type)return{start:0,end:0};var e=this.i.presentationTimeline;return{start:e.Kb(),end:e.Bb()}}return this.h&&this.h.src&&(e=this.h.seekable).length?{start:e.start(0),end:e.end(e.length-1)}:{start:0,end:0}},i.li=function(){this.U()&&(this.h.currentTime=this.Qb().end)},i.pi=function(){return this.Ba},i.keySystem=function(){var e=this.drmInfo();return e?e.keySystem:""},i.drmInfo=function(){return this.C?this.C.g:null},i.gd=function(){return this.C?this.C.gd():1/0},i.jf=function(){return this.C?this.C.jf():[]},i.Od=function(){return this.C?this.C.Od():{}},i.tf=function(){return!!this.M&&this.M.g==Hr},i.ib=function(){return this.h?this.K?this.K.i:1:0},i.Bd=function(e,t){var n=this;t=void 0===t||t,0==e?$("A trick play rate of 0 is unsupported!"):(this.Ga.Va(),this.h.paused&&this.h.play(),this.K.set(e),this.m==sc&&(this.o.playbackRateChanged(e),Pu(this.j,t&&1<Math.abs(e))),this.U()&&this.Ga.D(this.h,"timeupdate",(function(){var t=n.h.currentTime,i=n.Qb(),r=n.g.streaming.safeSeekOffset;0<e?Math.floor(t)>=Math.floor(i.end)&&n.$c():Math.floor(t)<=Math.floor(i.start+r)&&n.$c()})))},i.$c=function(){var e=this.K.oc();this.m==oc&&this.K.set(e),this.m==sc&&(this.K.set(e),this.o.playbackRateChanged(e),Pu(this.j,!1)),this.Ga.Va()},i.rc=function(){if(this.i&&!this.Ia()){for(var e=this.j?this.j.j:null,t=[],n=0,i=d(this.i.variants),r=i.next();!r.done;r=i.next())if(_r(r=r.value)){var a=cr(r);a.active=r==e,a.active||1==n||null==e||r.video!=e.video||r.audio!=e.audio||(a.active=!0),a.active&&n++,t.push(a)}return t}return this.h&&this.h.audioTracks?Array.from(this.h.audioTracks).map((function(e){return gr(e)})):[]},i.qc=function(){if(this.i&&!this.Ia()){for(var e=this.j?this.j.s:null,t=[],n=d(this.i.textStreams),i=n.next();!i.done;i=n.next()){var r=hr(i=i.value);r.active=i==e,t.push(r)}return t}return this.h&&this.h.src&&this.h.textTracks?xl(this).map((function(e){return pr(e)})):[]},i.Sh=function(){var e=this.ud;return this.i&&(e=this.i.imageStreams),e.map((function(e){return mr(e)}))},i.Jh=function(e){var t,n,i,r,a=this;return I((function(s){return 1==s.g?a.m!=sc&&a.m!=oc?s.return(null):(t=a.ud,a.i&&(t=a.i.imageStreams),(n=t.find((function(t){return t.id==e})))?n.segmentIndex?s.u(2):M(s,n.createSegmentIndex(),2):s.return(null)):4!=s.g?(i=[],n.segmentIndex.yb((function(t){var r=kl(t.tilesLayout||n.tilesLayout);if(r){r=r.rows*r.lc;for(var s=t.j-t.startTime,o=0;o<r;o++)i.push(a.Fg(e,t.startTime+s*o/r))}})),M(s,Promise.all(i),4)):(r=s.h,s.return(r.filter((function(e){return e}))))}))},i.Fg=function(e,t){var n,i,r,a,s,o,u,d,l,c,h,m,f,p,g,y,_,v,w=this;return I((function(b){return 1==b.g?w.m!=sc&&w.m!=oc?b.return(null):(n=w.ud,w.i&&(n=w.i.imageStreams),(i=n.find((function(t){return t.id==e})))?i.segmentIndex?b.u(2):M(b,i.createSegmentIndex(),2):b.return(null)):null==(r=i.segmentIndex.find(t))?b.return(null):(a=i.segmentIndex.get(r),(s=kl(a.tilesLayout||i.tilesLayout))?(o=i.width||0,u=i.height||0,d=o/s.lc,l=u/s.rows,c=s.lc*s.rows,h=a.j-a.startTime,m=a.A||h/c,f=a.startTime,g=p=0,1<c&&(y=Math.floor((t-a.startTime)/m),f=a.startTime+y*m,p=y%s.lc*d,g=Math.floor(y/s.lc)*l),_=!1,(v=a.thumbnailSprite)&&(_=!0,l=v.height,p=v.positionX,g=v.positionY,d=v.width),b.return({segment:a,imageHeight:u,imageWidth:o,height:l,positionX:p,positionY:g,startTime:f,duration:m,uris:a.N(),width:d,sprite:_})):b.return(null))}))},i.ah=function(e){var t,n=this;this.i&&this.F&&((t=n.i.textStreams.find((function(t){return t.id==e.id})))&&t!=n.j.s&&(cu(n.A.h,t,!1),ju(n.j,t),Vl(n),$l(n),n.Gb=t.language),!this.Ia())||function(){if(n.h&&n.h.textTracks){var t=xl(n),i=t.find((function(e){return"disabled"!==e.mode}));(t=t.find((function(t){return fr(t)===e.id})))&&(i!==t&&(i&&(i.mode="disabled",n.l.cb(i,"cuechange"),n.B.remove(0,1/0)),t&&Dl(n,t)),Vl(n),$l(n))}}()},i.Qf=function(e,t,n){var i=this;t=void 0!==t&&t,n=void 0===n?0:n,this.i&&this.F&&(function(){var r=i.i.variants.find((function(t){return t.id==e.id}));if(r&&_r(r)){var a=i.j.j;i.g.abr.enabled&&(a.video!=r.video||a.audio&&r.audio&&a.audio.language==r.audio.language&&a.audio.channelsCount==r.audio.channelsCount)&&$("Changing tracks while abr manager is enabled will likely result in the selected track being overriden. Consider disabling abr before calling selectVariantTrack()."),i.Ia()?Fl(i,r,!1,!1,0):Fl(i,r,!1,t||!1,n||0),i.xa=new jr(r,i.g.mediaSource.codecSwitchingStrategy),Hl(i)}}(),!this.Ia())||function(){if(i.h&&i.h.audioTracks)for(var t=Array.from(i.h.audioTracks),n=(t=d(t)).next();!n.done;n=t.next())if(fr(n=n.value)==e.id){Bl(i,n);break}}()},i.Lh=function(){return ic(this.rc())},i.ei=function(){return ic(this.qc())},i.Kh=function(){return Array.from(nc(this.rc()))},i.di=function(){return Array.from(nc(this.qc()))},i.$g=function(e,t,n,i,r){var a=this;n=void 0===n?0:n,i=void 0===i?0:i,r=void 0===r?"":r,this.i&&this.F&&(function(){function s(e,t){return e.video||t.video?e.video&&t.video?Math.abs((e.video.height||0)-(t.video.height||0))+Math.abs((e.video.width||0)-(t.video.width||0)):1/0:0}a.xa=new Or(e,t||"",n||0,"",!1,"","","",a.g.mediaSource.codecSwitchingStrategy,r||"");for(var o=a.j.j,u=a.xa.create(a.i.variants),l=null,c=(u=d(u.values())).next();!c.done;c=u.next())_r(c=c.value)&&(!l||s(l,o)>s(c,o))&&(l=c);l!=o&&(l?(o=cr(l),a.Qf(o,!0,i||0)):Ul(a))}(),!this.Ia())||function(){if(a.h&&a.h.audioTracks){var n=Mr(a.rc(),e,t||"",!1)[0];n&&a.Qf(n)}}()},i.Pf=function(e,t,n){var i,r=this;n=void 0!==n&&n,this.i&&this.F&&(function(){r.Gb=e,r.sd=t||"",r.rd=n||!1;var i=Mr(r.i.textStreams,r.Gb,r.sd,r.rd)[0]||null;i&&i!=r.j.s&&(cu(r.A.h,i,!1),r.g.streaming.alwaysStreamText||r.vf())&&(ju(r.j,i),Vl(r),$l(r))}(),!this.Ia())||(i=Mr(r.qc(),e,t||"",n||!1)[0])&&r.ah(i)},i.Xi=function(e,t,n){var i=this;t=void 0===t||t,n=void 0===n?0:n,this.i&&this.F&&(function(){for(var r=null,a=d(i.i.variants),s=a.next();!s.done;s=a.next())if((s=s.value).audio.label==e){r=s;break}null!=r&&(i.xa=new Or(r.language,"",0,"",!1,"",e,"",i.g.mediaSource.codecSwitchingStrategy,""),Ul(i,t,n))}(),!this.Ia())||function(){if(i.h&&i.h.audioTracks){for(var t=Array.from(i.h.audioTracks),n=null,r=(t=d(t)).next();!r.done;r=t.next())(r=r.value).label==e&&(n=r);n&&Bl(i,n)}}()},i.vf=function(){var e=this.ja;return this.B?this.B.isTextVisible():e},i.zg=function(){return this.h&&this.h.currentSrc&&this.h.textTracks?Al(this).map((function(e){return pr(e)})):[]},i.Nh=function(e){if(!this.h||!this.h.currentSrc||!this.h.textTracks)return[];var t=Ki(e),n=Al(this).filter((function(e){return Ki(e.language)==t}));if(!n||!n.length)return[];e=[];for(var i=new Set,r=(n=d(n)).next();!r.done;r=n.next())if((r=r.value)&&r.cues)for(var a=(r=d(r.cues)).next();!a.done;a=r.next()){var s=a.value;(a=s.id)&&""!=a||(a=s.startTime+"-"+s.endTime+"-"+s.text),s={id:a,title:s.text,startTime:s.startTime,endTime:s.endTime},i.has(a)||(e.push(s),i.add(a))}return e},i.hh=function(e){e=!!e,this.ja!=e&&(this.ja=e,this.m==sc?(this.B.setTextVisibility(e),this.g.streaming.alwaysStreamText||(e?this.j.s||0<(e=Mr(this.i.textStreams,this.Gb,this.sd,this.rd)).length&&(ju(this.j,e[0]),Vl(this),$l(this)):function(e){var t=e.i.get(_i);t&&($u(t),Ku(t).catch((function(){})),e.C=e.i.get(_i),e.i.delete(_i)),e.s=null}(this.j))):this.h&&this.h.src&&this.h.textTracks&&this.B.setTextVisibility(e),Gl(this))},i.$h=function(){if(this.F)var e=this.F.Dd();else{if(null==this.ga)return new Date;e=this.ga}if(this.i&&!this.Ia()){var t=this.i.presentationTimeline;return new Date(1e3*((t.m||t.i)+e))}return this.h&&this.h.getStartDate?(t=this.h.getStartDate(),isNaN(t.getTime())?null:new Date(t.getTime()+1e3*e)):null},i.Eg=function(){if(this.i&&!this.Ia()){var e=this.i.presentationTimeline;return new Date(1e3*(e.m||e.i))}return this.h&&this.h.getStartDate?(e=this.h.getStartDate(),isNaN(e.getTime())?null:e):null},i.Qd=function(){return this.U()&&this.i?this.i.presentationTimeline.Qd():null},i.zb=function(){if(this.m==sc)return this.I.zb();var e={total:[],audio:[],video:[],text:[]};return this.m==oc&&(e.total=Ls(this.h.buffered)),e},i.getStats=function(){if(this.m!=sc&&this.m!=oc)return{width:NaN,height:NaN,streamBandwidth:NaN,decodedFrames:NaN,droppedFrames:NaN,corruptedFrames:NaN,stallsDetected:NaN,gapsJumped:NaN,estimatedBandwidth:NaN,completionPercent:NaN,loadLatency:NaN,manifestTimeSeconds:NaN,drmTimeSeconds:NaN,playTime:NaN,pauseTime:NaN,bufferingTime:NaN,licenseTime:NaN,liveLatency:NaN,maxSegmentDuration:NaN,manifestSizeBytes:NaN,bytesDownloaded:NaN,nonFatalErrorCount:NaN,manifestPeriodCount:NaN,manifestGapCount:NaN,switchHistory:[],stateHistory:[]};Ol(this);var e=this.h,t=e.currentTime/e.duration;if(!isNaN(t)&&!this.U()){var n=this.A;t=Math.round(100*t),n.i=isNaN(n.i)?t:Math.max(n.i,t)}if(this.F&&(this.A.S=this.F.hg(),this.A.Y=this.F.ig()),e.getVideoPlaybackQuality){n=e.getVideoPlaybackQuality(),t=this.A;var i=Number(n.totalVideoFrames);t.O=Number(n.droppedVideoFrames),t.M=i,this.A.L=Number(n.corruptedVideoFrames)}if(n=this.C&&(n=this.C).H?n.H:NaN,this.A.o=n,this.m==sc){if(n=this.j.j,t=this.j.s,n){var r=(i=this.K?this.K.i:1)*n.bandwidth;t&&t.bandwidth&&(r+=i*t.bandwidth),this.A.A=r}n&&n.video&&(t=this.A,i=n.video.height||NaN,t.m=n.video.width||NaN,t.l=i),this.U()&&(n=this.Eg().valueOf()+1e3*e.currentTime,this.A.B=(Date.now()-n)/1e3),this.i&&(this.A.G=this.i.periodCount,this.A.F=this.i.gapCount,this.i.presentationTimeline&&(this.A.I=this.i.presentationTimeline.h)),n=this.o.getBandwidthEstimate(),this.A.s=n}this.m==oc&&((n=this.A).kc=isNaN(n.kc)?NaN:n.kc+NaN,n=this.A,t=e.videoHeight||NaN,n.m=e.videoWidth||NaN,n.l=t);var a=this.A;e=a.m,n=a.l,t=a.A,i=a.M,r=a.O;for(var s=a.L,o=a.Y,u=a.S,l=a.s,c=a.i,h=a.C,m=a.H,f=a.j,p=du(a.g,"playing"),g=du(a.g,"paused"),y=du(a.g,"buffering"),_=a.o,v=a.B,M=a.I,w=a.Kg,b=a.kc,T=a.K,L=a.G,S=a.F,k=function(e){function t(e){return{timestamp:e.timestamp,state:e.state,duration:e.duration}}for(var n=[],i=d(e.h),r=i.next();!r.done;r=i.next())n.push(t(r.value));return e.g&&n.push(t(e.g)),n}(a.g),D=[],x=(a=d(a.h.g)).next();!x.done;x=a.next())x=x.value,D.push({timestamp:x.timestamp,id:x.id,type:x.type,fromAdaptation:x.fromAdaptation,bandwidth:x.bandwidth});return{width:e,height:n,streamBandwidth:t,decodedFrames:i,droppedFrames:r,corruptedFrames:s,stallsDetected:o,gapsJumped:u,estimatedBandwidth:l,completionPercent:c,loadLatency:h,manifestTimeSeconds:m,drmTimeSeconds:f,playTime:p,pauseTime:g,bufferingTime:y,licenseTime:_,liveLatency:v,maxSegmentDuration:M,manifestSizeBytes:w,bytesDownloaded:b,nonFatalErrorCount:T,manifestPeriodCount:L,manifestGapCount:S,stateHistory:k,switchHistory:D}},i.xh=function(e,t,n,i,r,a,s){s=void 0!==s&&s;var o,u,d,l,c,h,m,f,p,g,y=this;return I((function(_){switch(_.g){case 1:if(y.m!=sc&&y.m!=oc)throw new Ye(1,7,7004);if("subtitles"!=n&&"captions"!=n&&$("Using a kind value different of `subtitles` or `captions` can cause unwanted issues."),i){_.u(2);break}return M(_,Yl(y,e),3);case 3:i=_.h;case 2:if(o=[],y.s&&(o=y.s.getCuePoints()),y.m!=oc){_.u(4);break}return s&&(n="forced"),M(_,El(y,e,t,n,i,a||"",o),5);case 5:if(u=Ki(t),d=y.qc(),l=d.find((function(e){return Ki(e.language)==u&&e.label==(a||"")&&e.kind==n})))return Wl(y),_.return(l);throw new Ye(1,2,2012);case 4:if(c=vi,h=y.h.duration,y.i&&(h=y.i.presentationTimeline.getDuration()),1/0==h)throw new Ye(1,4,4033);if(!o.length){_.u(6);break}return M(_,Il(y,e,y.G,y.g.streaming.retryParameters),7);case 7:m=_.h,f=Pl(y,m,i,o),p=new Blob([f],{type:"text/vtt"}),e=Eo(p),i="text/vtt";case 6:if(g={id:y.fg++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:tu(0,h,[e]),mimeType:i||"",codecs:r||"",kind:n,encrypted:!1,drmInfos:[],keyIds:new Set,language:t,originalLanguage:t,label:a||null,type:c.wa,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!!s,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!0,fastSwitching:!1,fullMimeTypes:new Set([Ti(i||"",r||"")]),isAudioMuxedInVideo:!1},!Ri(Ti(g.mimeType,g.codecs)))throw new Ye(2,2,2014,i);return y.i.textStreams.push(g),Wl(y),_.return(hr(g))}}))},i.yh=function(e,t){var n,i,r,a,s,o,u,l,c,h,m,f,p,g,y,_,v,w=this;return I((function(b){switch(b.g){case 1:if(w.m!=sc&&w.m!=oc)throw new Ye(1,7,7004);if(t){b.u(2);break}return M(b,Yl(w,e),3);case 3:t=b.h;case 2:if("text/vtt"!=t)throw new Ye(1,2,2017,e);if(n=vi,i=w.h.duration,w.i&&(i=w.i.presentationTimeline.getDuration()),1/0==i)throw new Ye(1,4,4045);return M(b,Il(w,e,w.G,w.g.streaming.retryParameters),4);case 4:if(r=b.h,!(a=Ui[t]))throw new Ye(2,2,2014,t);for(s=a(),o={periodStart:0,segmentStart:0,segmentEnd:i,vttOffset:0},u=pe(r),l=s.parseMedia(u,o,e,[]),c=[],h=d(l),m=h.next(),f={};!m.done;f={ze:void 0,Hc:void 0},m=h.next())f.Hc=m.value,f.ze=null,p=function(t){return function(){return null==t.ze&&(t.ze=hi([e],[t.Hc.payload])),t.ze||[]}}(f),g=new gs(f.Hc.startTime,f.Hc.endTime,p,0,null,null,0,0,1/0),f.Hc.payload.includes("#xywh")&&4===(y=f.Hc.payload.split("#xywh=")[1].split(",")).length&&g.qe({height:parseInt(y[3],10),positionX:parseInt(y[0],10),positionY:parseInt(y[1],10),width:parseInt(y[2],10)}),c.push(g);if(_=t,!c.length){b.u(5);break}return M(b,Ld(c[0].N()[0],w.G,w.g.manifest.retryParameters),6);case 6:_=b.h;case 5:return v={id:w.fg++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Zo(c),mimeType:_||"",codecs:"",kind:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:n.He,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,tilesLayout:"1x1",accessibilityPurpose:null,external:!0,fastSwitching:!1,fullMimeTypes:new Set([Ti(_||"","")]),isAudioMuxedInVideo:!1},w.m==oc?w.ud.push(v):w.i.imageStreams.push(v),Wl(w),b.return(mr(v))}}))},i.wh=function(e,t,n){var i,r,a,s,o=this;return I((function(u){switch(u.g){case 1:if(o.m!=sc&&o.m!=oc)throw new Ye(1,7,7004);if(n){u.u(2);break}return M(u,Yl(o,e),3);case 3:n=u.h;case 2:return i=[],o.s&&(i=o.s.getCuePoints()),M(u,El(o,e,t,"chapters",n,"",i),4);case 4:if(r=u.h,a=o.zg(),!(s=a.find((function(e){return e.language==t})))){u.u(5);break}return M(u,new Promise((function(e,t){o.l.pa(r,"load",e),o.l.pa(r,"error",(function(){t(new Ye(1,2,2015))}))})),6);case 6:return Wl(o),u.return(s);case 5:throw new Ye(1,2,2012)}}))},i.bj=function(e,t){this.fa.width=e,this.fa.height=t},i.Nf=function(e){if(this.m==sc){var t=this.j;if(e=void 0===e?.1:e,t.m.g)t=!1;else if(t.A)t=!1;else{for(var n=d(t.i.values()),i=n.next();!i.done;i=n.next())!(i=i.value).ld||i.Ea||i.eb||(i.ld=!1,qu(t,i,e));t=!0}}else t=!1;return t},i.kf=function(){return $("Shaka Player's internal Manifest structure is NOT covered by semantic versioning compatibility guarantees. It may change at any time! Please consider filing a feature request for whatever you use getManifest() for."),this.i},i.Vh=function(){return this.La},i.Qh=function(){var e={video:null,audio:null,text:null};if(this.m!=sc)return e;for(var t=this.j.j,n=this.h.currentTime,i=(t=d([t.video,t.audio,this.j.s])).next();!i.done;i=t.next())if((i=i.value)&&i.segmentIndex){var r=i.segmentIndex.find(n);r={codecs:(r=i.segmentIndex.get(r)).codecs||i.codecs,mimeType:r.mimeType||i.mimeType,bandwidth:r.bandwidth||i.bandwidth},"video"==i.type?(r.width=i.width,r.height=i.height,e.video=r):"audio"==i.type?e.audio=r:i.type==_i&&(e.text=r)}return e},i.kh=function(e){this.ge=e},i.disableStream=function(e,t){if(!this.g.abr.enabled||this.m===rc||!navigator.onLine||0==t||!this.i)return!1;if(this.i.variants.some((function(t){var n=t[e.type];return!(!n||n.id===e.id||t.disabledUntilTime||"audio"==e.type&&e.language!==n.language)}))){for(var n=!1,i=!1,r=d(this.i.variants),a=r.next();!a.done;a=r.next()){var s=(a=a.value)[e.type];s&&(s.id===e.id?(a.disabledUntilTime=Date.now()/1e3+t,n=!0):s.trickModeVideo&&s.trickModeVideo.id==e.id&&(i=!0))}return!(!n&&i||(this.je.Ra(1),t=this.zb().video.reduce((function(e,t){return e+t.end-t.start}),0),Ul(this,!1,t,!0,!1),0))}return!1},i.addFont=function(t,n){var i,r,a,s,o;return I((function(u){if(1==u.g)return"fonts"in document&&"FontFace"in e?M(u,document.fonts.ready,3):u.u(0);if(!("entries"in document.fonts))return u.return();for(i=function(e){for(var t=[],n=(e=e.entries()).next();!1===n.done;)t.push(n.value),n=e.next();return t},r=d(i(document.fonts)),a=r.next();!a.done;a=r.next())if((s=a.value).family==t&&"swap"==s.display)return u.return();o=new FontFace(t,"url("+n+")",{display:"swap"}),document.fonts.add(o),w(u)}))},i.Ia=function(){return!(!this.h||!this.h.remote)&&"disconnected"!=this.h.remote.state},U("shaka.Player",dl),dl.prototype.isRemotePlayback=dl.prototype.Ia,dl.prototype.addFont=dl.prototype.addFont,dl.prototype.setVideoContainer=dl.prototype.kh,dl.prototype.getFetchedPlaybackInfo=dl.prototype.Qh,dl.prototype.getManifestParserFactory=dl.prototype.Vh,dl.prototype.getManifest=dl.prototype.kf,dl.prototype.retryStreaming=dl.prototype.Nf,dl.prototype.setMaxHardwareResolution=dl.prototype.bj,dl.prototype.addChaptersTrack=dl.prototype.wh,dl.prototype.addThumbnailsTrack=dl.prototype.yh,dl.prototype.addTextTrackAsync=dl.prototype.xh,dl.prototype.getStats=dl.prototype.getStats,dl.prototype.getBufferedInfo=dl.prototype.zb,dl.prototype.getSegmentAvailabilityDuration=dl.prototype.Qd,dl.prototype.getPresentationStartTimeAsDate=dl.prototype.Eg,dl.prototype.getPlayheadTimeAsDate=dl.prototype.$h,dl.prototype.setTextTrackVisibility=dl.prototype.hh,dl.prototype.getChapters=dl.prototype.Nh,dl.prototype.getChaptersTracks=dl.prototype.zg,dl.prototype.isTextTrackVisible=dl.prototype.vf,dl.prototype.selectVariantsByLabel=dl.prototype.Xi,dl.prototype.selectTextLanguage=dl.prototype.Pf,dl.prototype.selectAudioLanguage=dl.prototype.$g,dl.prototype.getTextLanguages=dl.prototype.di,dl.prototype.getAudioLanguages=dl.prototype.Kh,dl.prototype.getTextLanguagesAndRoles=dl.prototype.ei,dl.prototype.getAudioLanguagesAndRoles=dl.prototype.Lh,dl.prototype.selectVariantTrack=dl.prototype.Qf,dl.prototype.selectTextTrack=dl.prototype.ah,dl.prototype.getThumbnails=dl.prototype.Fg,dl.prototype.getAllThumbnails=dl.prototype.Jh,dl.prototype.getImageTracks=dl.prototype.Sh,dl.prototype.getTextTracks=dl.prototype.qc,dl.prototype.getVariantTracks=dl.prototype.rc,dl.prototype.cancelTrickPlay=dl.prototype.$c,dl.prototype.trickPlay=dl.prototype.Bd,dl.prototype.getPlaybackRate=dl.prototype.ib,dl.prototype.isBuffering=dl.prototype.tf,dl.prototype.getKeyStatuses=dl.prototype.Od,dl.prototype.getActiveSessionsMetadata=dl.prototype.jf,dl.prototype.getExpiration=dl.prototype.gd,dl.prototype.drmInfo=dl.prototype.drmInfo,dl.prototype.keySystem=dl.prototype.keySystem,dl.prototype.isFullyLoaded=dl.prototype.pi,dl.prototype.goToLive=dl.prototype.li,dl.prototype.seekRange=dl.prototype.Qb,dl.prototype.isAudioOnly=dl.prototype.oi,dl.prototype.isInProgress=dl.prototype.uc,dl.prototype.isLive=dl.prototype.U,dl.prototype.getAdManager=dl.prototype.xg,dl.prototype.getAssetUri=dl.prototype.Mc,dl.prototype.getNetworkingEngine=dl.prototype.Ab,dl.prototype.getMediaElement=dl.prototype.Yh,dl.prototype.getManifestType=dl.prototype.lf,dl.prototype.getLoadMode=dl.prototype.Bg,dl.prototype.resetConfiguration=dl.prototype.Ri,dl.prototype.getBufferFullness=dl.prototype.yg,dl.prototype.getNonDefaultConfiguration=dl.prototype.Dg,dl.prototype.getConfiguration=dl.prototype.getConfiguration,dl.prototype.configure=dl.prototype.configure,dl.prototype.releaseAllMutexes=dl.prototype.Ni,dl.prototype.destroyAllPreloads=dl.prototype.Te,dl.prototype.preload=dl.prototype.preload,dl.prototype.detachAndSavePreload=dl.prototype.tg,dl.prototype.unloadAndSavePreload=dl.prototype.ej,dl.prototype.load=dl.prototype.load,dl.prototype.updateStartTime=dl.prototype.ij,dl.prototype.unload=dl.prototype.ic,dl.prototype.detach=dl.prototype.detach,dl.prototype.attachCanvas=dl.prototype.Ch,dl.prototype.attach=dl.prototype.Tb,dl.probeSupport=function(e){var t,n,i,r,a,s,o;return e=void 0===e||e,I((function(u){switch(u.g){case 1:if(t={},!e){u.u(2);break}return M(u,function(){var e,t,n,i,r,a,s,o,u,l,c,h,m,f,p,g,y,_,v,T,k,D,x,A,Y,E,P;return I((function(C){if(1==C.g){for(e="org.w3.clearkey com.widevine.alpha com.widevine.alpha.experiment com.microsoft.playready com.microsoft.playready.hardware com.microsoft.playready.recommendation com.chromecast.playready com.apple.fps.1_0 com.apple.fps".split(" "),n={"com.widevine.alpha":t=["SW_SECURE_CRYPTO","SW_SECURE_DECODE","HW_SECURE_CRYPTO","HW_SECURE_DECODE","HW_SECURE_ALL"],"com.widevine.alpha.experiment":t,"com.microsoft.playready.recommendation":["150","2000","3000"]},a={videoCapabilities:i=[{contentType:'video/mp4; codecs="avc1.42E01E"'},{contentType:'video/webm; codecs="vp8"'}],audioCapabilities:r=[{contentType:'audio/mp4; codecs="mp4a.40.2"'},{contentType:'audio/webm; codecs="opus"'}],initDataTypes:["cenc","sinf","skd","keyids"]},s=[null,"cenc","cbcs","cbcs-1-9"],o=new Map,u=function(e,t){var n,i,r,a,s,u,d,l;return I((function(c){switch(c.g){case 1:return b(c,2),M(c,t.createMediaKeys(),4);case 4:L(c,3);break;case 2:return S(c),c.return();case 3:i=!!(n=t.getConfiguration().sessionTypes)&&n.includes("persistent-license"),Ve()&&(i=!1),r=t.getConfiguration().videoCapabilities,a=t.getConfiguration().audioCapabilities,s={persistentState:i,encryptionSchemes:[],videoRobustnessLevels:[],audioRobustnessLevels:[]},o.has(e)&&o.get(e)?s=o.get(e):o.set(e,s),(u=r[0].encryptionScheme)&&!s.encryptionSchemes.includes(u)&&s.encryptionSchemes.push(u),(d=r[0].robustness)&&!s.videoRobustnessLevels.includes(d)&&s.videoRobustnessLevels.push(d),(l=a[0].robustness)&&!s.audioRobustnessLevels.includes(l)&&s.audioRobustnessLevels.push(l),w(c)}}))},l=function(e,t,n,i){var r,s,o,l,c,h,m,f,p,g;return I((function(y){switch(y.g){case 1:for(b(y,2),r=kt(a),s=d(r.videoCapabilities),o=s.next();!o.done;o=s.next())(l=o.value).encryptionScheme=t,l.robustness=n;for(c=d(r.audioCapabilities),h=c.next();!h.done;h=c.next())(m=h.value).encryptionScheme=t,m.robustness=i;return(f=kt(r)).persistentState="required",f.sessionTypes=["persistent-license"],p=[f,r],M(y,zi(1,navigator.requestMediaKeySystemAccess(e,p)),4);case 4:return g=y.h,M(y,u(e,g),5);case 5:L(y,0);break;case 2:S(y),w(y)}}))},c=function(e,t,n,a){var s,o,d;return I((function(l){switch(l.g){case 1:return b(l,2),s={type:"media-source",video:{contentType:i[0].contentType,width:640,height:480,bitrate:1,framerate:1},audio:{contentType:r[0].contentType,channels:2,bitrate:1,samplerate:1},keySystemConfiguration:{keySystem:e,video:{encryptionScheme:t,robustness:n},audio:{encryptionScheme:t,robustness:a}}},M(l,zi(1,navigator.mediaCapabilities.decodingInfo(s)),4);case 4:return o=l.h,d=o.keySystemAccess,M(l,u(e,d),5);case 5:L(l,0);break;case 2:S(l),w(l)}}))},h=d(e),m=h.next();!m.done;m=h.next())f=m.value,o.set(f,null);for(p=[],g=d(s),y=g.next();!y.done;y=g.next())for(_=y.value,v=d(e),T=v.next();!T.done;T=v.next())"org.w3.clearkey"===(k=T.value)&&et()||(p.push(l(k,_,"","")),p.push(c(k,_,"","")));for(D=d(e),x=D.next();!x.done;x=D.next())for(A=x.value,Y=d(n[A]||[]),E=Y.next();!E.done;E=Y.next())P=E.value,p.push(l(A,null,P,"")),p.push(l(A,null,"",P)),p.push(c(A,null,P,"")),p.push(c(A,null,"",P));return M(C,Promise.all(p),2)}return C.return(ya(o))}))}(),3);case 3:t=u.h;case 2:var c={};if(Ue())for(var h in ls)c[h]=!0;for(var m=(h=d(["application/dash+xml","application/x-mpegurl","application/vnd.apple.mpegurl","application/vnd.ms-sstr+xml"])).next();!m.done;m=h.next())c[m=m.value]=Ue()?!!ls[m]:Fe(m);for(n=c,c={},m=(h=d(h='video/mp4; codecs="avc1.42E01E",video/mp4; codecs="avc3.42E01E",video/mp4; codecs="hev1.1.6.L93.90",video/mp4; codecs="hvc1.1.6.L93.90",video/mp4; codecs="hev1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="hvc1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="vp9",video/mp4; codecs="vp09.00.10.08",video/mp4; codecs="av01.0.01M.08",video/mp4; codecs="dvh1.05.01",video/mp4; codecs="dvh1.20.01",audio/mp4; codecs="mp4a.40.2",audio/mp4; codecs="ac-3",audio/mp4; codecs="ec-3",audio/mp4; codecs="ac-4.02.01.01",audio/mp4; codecs="opus",audio/mp4; codecs="flac",audio/mp4; codecs="dtsc",audio/mp4; codecs="dtse",audio/mp4; codecs="dtsx",video/webm; codecs="vp8",video/webm; codecs="vp9",video/webm; codecs="vp09.00.10.08",audio/webm; codecs="vorbis",audio/webm; codecs="opus",video/mp2t; codecs="avc1.42E01E",video/mp2t; codecs="avc3.42E01E",video/mp2t; codecs="hvc1.1.6.L93.90",video/mp2t; codecs="mp4a.40.2",video/mp2t; codecs="ac-3",video/mp2t; codecs="ec-3",text/vtt,application/mp4; codecs="wvtt",application/ttml+xml,application/mp4; codecs="stpp"'.split(",").concat(l(ji)))).next();!m.done;m=h.next()){c[m=m.value]=!!Ri(m)||(Ue()?ne(m)||!!On(m):Fe(m));var f=m.split(";")[0];c[f]=c[f]||c[m]}return i=c,M(u,ot(),4);case 4:for(o in r=u.h,a={manifest:n,media:i,drm:t,hardwareResolution:r},s=dc)a[o]=s[o]();return u.return(a)}}))},dl.isBrowserSupported=function(){if(e.Promise||$("A Promise implementation or polyfill is required"),!(e.Promise&&e.Uint8Array&&Array.prototype.forEach)||rt("Trident/"))return!1;var t=et();return!(t&&9>t||!(e.MediaKeys&&e.navigator&&e.navigator.requestMediaKeySystemAccess&&e.MediaKeySystemAccess&&e.MediaKeySystemAccess.prototype.getConfiguration))&&(!!Ue()||Fe("application/x-mpegurl"))},dl.setAdManagerFactory=function(e){lc=e},dl.registerSupportPlugin=function(e,t){dc[e]=t},dl.prototype.destroy=dl.prototype.destroy;var rc=0,ac=1,sc=2,oc=3;dl.LoadMode={DESTROYED:rc,NOT_LOADED:ac,MEDIA_SOURCE:sc,SRC_EQUALS:oc},dl.version="v4.12.5";var uc=["4","12"];de=new function(e){this.g=e,this.i=oe,this.h=ue}(new ae(Number(uc[0]),Number(uc[1])));var dc={},lc=null;function cc(){this.g=[],this.i=this.l=this.j=this.h=0}function hc(e){return e.g.length?e.g.reduce((function(e,t){return e+t}),0)/e.g.length:0}function mc(e,t,n){var i=this;this.g=e,this.h=t,this.j=n,this.i=!1,this.l=this.h.getVolume(),this.m=new Z,this.m.D(this.h,google.ima.AdEvent.Type.PAUSED,(function(){i.i=!0})),this.m.D(this.h,google.ima.AdEvent.Type.RESUMED,(function(){i.i=!1}))}function fc(){}function pc(e,t){var n=[],i=0;null!=t&&(i=t);for(var r=(e=d(Ct(e,"Ad"))).next();!r.done;r=e.next())if((r=Nt(r.value,"InLine"))&&(r=Nt(r,"Creatives")))for(var a=(r=d(Ct(r,"Creative"))).next();!a.done;a=r.next()){var s=Nt(a.value,"Linear");if(s&&(a=null,s.attributes.skipoffset&&(a=Lt(s.attributes.skipoffset),isNaN(a)&&(a=null)),s=Nt(s,"MediaFiles"))){var o=Ct(s,"MediaFile");for(s=o,(o=o.filter((function(e){return"streaming"==e.attributes.delivery}))).length&&(s=o),o=(s=d(s=s.sort((function(e,t){return(parseInt(t.attributes.height,10)||0)-(parseInt(e.attributes.height,10)||0)})))).next();!o.done;o=s.next()){var u=jt(o=o.value);if(u){n.push({id:null,startTime:i,endTime:null,uri:u,mimeType:o.attributes.type||null,isSkippable:null!=a,skipOffset:a,skipFor:null,canJump:!1,resumeOffset:0,playoutLimit:null,once:!0,pre:null==t,post:1/0==t,timelineRange:!1});break}}}}return n}function gc(t,n,i,r,a){var s=this;this.s=t,this.i=n,this.F=!1,this.A=this.o=null,this.G=NaN,this.l=a,this.j=null,this.h=new Z,google.ima.settings.setLocale(i),google.ima.settings.setDisableCustomPlaybackForIOS10Plus(!0),this.C=new google.ima.AdDisplayContainer(this.s,this.i),this.C.initialize(),this.m=new google.ima.AdsLoader(this.C),this.m.getSettings().setPlayerType("shaka-player"),this.m.getSettings().setPlayerVersion("v4.12.5"),this.g=null,this.B=r||new google.ima.AdsRenderingSettings,this.h.D(this.m,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,(function(t){!function(t,n){if(t.l(new Jr("ads-loaded",(new Map).set("loadTime",Date.now()/1e3-t.G))),t.o.customPlayheadTracker){var i={currentTime:t.i.currentTime};t.g=n.getAdsManager(i,t.B),t.i.muted?t.g.setVolume(0):t.g.setVolume(t.i.volume),t.h.D(t.i,"timeupdate",(function(){t.i.duration&&(i.currentTime=t.i.currentTime)})),t.h.D(t.i,"volumechange",(function(){t.j&&(t.j.setVolume(t.i.volume),t.i.muted&&t.j.setMuted(!0))}))}else t.g=n.getAdsManager(t.i,t.B);t.l(new Jr("ima-ad-manager-loaded",(new Map).set("imaAdManager",t.g)));var r=t.g.getCuePoints();if(r.length){n=[];for(var a=(r=d(r)).next();!a.done;a=r.next())n.push({start:a.value,end:null});t.l(new Jr("ad-cue-points-changed",(new Map).set("cuepoints",n)))}!function(e){function t(t,n){t=(new Map).set("originalEvent",t),e.l(new Jr(n,t))}e.h.D(e.g,google.ima.AdErrorEvent.Type.AD_ERROR,(function(t){yc(e,t)})),e.h.D(e.g,google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED,(function(t){vc(e,t)})),e.h.D(e.g,google.ima.AdEvent.Type.STARTED,(function(t){vc(e,t)})),e.h.D(e.g,google.ima.AdEvent.Type.FIRST_QUARTILE,(function(e){t(e,"ad-first-quartile")})),e.h.D(e.g,google.ima.AdEvent.Type.MIDPOINT,(function(e){t(e,"ad-midpoint")})),e.h.D(e.g,google.ima.AdEvent.Type.THIRD_QUARTILE,(function(e){t(e,"ad-third-quartile")})),e.h.D(e.g,google.ima.AdEvent.Type.COMPLETE,(function(e){t(e,"ad-complete")})),e.h.D(e.g,google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED,(function(t){Mc(e,t)})),e.h.D(e.g,google.ima.AdEvent.Type.ALL_ADS_COMPLETED,(function(t){Mc(e,t)})),e.h.D(e.g,google.ima.AdEvent.Type.SKIPPED,(function(e){t(e,"ad-skipped")})),e.h.D(e.g,google.ima.AdEvent.Type.VOLUME_CHANGED,(function(e){t(e,"ad-volume-changed")})),e.h.D(e.g,google.ima.AdEvent.Type.VOLUME_MUTED,(function(e){t(e,"ad-muted")})),e.h.D(e.g,google.ima.AdEvent.Type.PAUSED,(function(n){e.j&&(e.j.i=!0,t(n,"ad-paused"))})),e.h.D(e.g,google.ima.AdEvent.Type.RESUMED,(function(n){e.j&&(e.j.i=!1,t(n,"ad-resumed"))})),e.h.D(e.g,google.ima.AdEvent.Type.SKIPPABLE_STATE_CHANGED,(function(n){e.j&&t(n,"ad-skip-state-changed")})),e.h.D(e.g,google.ima.AdEvent.Type.CLICK,(function(e){t(e,"ad-clicked")})),e.h.D(e.g,google.ima.AdEvent.Type.AD_PROGRESS,(function(e){t(e,"ad-progress")})),e.h.D(e.g,google.ima.AdEvent.Type.AD_BUFFERING,(function(e){t(e,"ad-buffering")})),e.h.D(e.g,google.ima.AdEvent.Type.IMPRESSION,(function(e){t(e,"ad-impression")})),e.h.D(e.g,google.ima.AdEvent.Type.DURATION_CHANGE,(function(e){t(e,"ad-duration-changed")})),e.h.D(e.g,google.ima.AdEvent.Type.USER_CLOSE,(function(e){t(e,"ad-closed")})),e.h.D(e.g,google.ima.AdEvent.Type.LOADED,(function(e){t(e,"ad-loaded")})),e.h.D(e.g,google.ima.AdEvent.Type.ALL_ADS_COMPLETED,(function(e){t(e,"all-ads-completed")})),e.h.D(e.g,google.ima.AdEvent.Type.LINEAR_CHANGED,(function(e){t(e,"ad-linear-changed")})),e.h.D(e.g,google.ima.AdEvent.Type.AD_METADATA,(function(e){t(e,"ad-metadata")})),e.h.D(e.g,google.ima.AdEvent.Type.LOG,(function(e){t(e,"ad-recoverable-error")})),e.h.D(e.g,google.ima.AdEvent.Type.AD_BREAK_READY,(function(e){t(e,"ad-break-ready")})),e.h.D(e.g,google.ima.AdEvent.Type.INTERACTION,(function(e){t(e,"ad-interaction")}))}(t);try{t.g.init(t.i.offsetWidth,t.i.offsetHeight,_c(t)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL),t.h.D(t.i,"loadeddata",(function(){t.g.resize(t.i.offsetWidth,t.i.offsetHeight,_c(t)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)})),"ResizeObserver"in e?(t.A=new ResizeObserver((function(){t.g.resize(t.i.offsetWidth,t.i.offsetHeight,_c(t)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)})),t.A.observe(t.i)):t.h.D(document,"fullscreenchange",(function(){t.g.resize(t.i.offsetWidth,t.i.offsetHeight,_c(t)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)})),t.F||t.o.skipPlayDetection?t.g.start():t.h.pa(t.i,"play",(function(){t.F=!0,t.g.start()}))}catch(e){Mc(t,null)}}(s,t)})),this.h.D(this.m,google.ima.AdErrorEvent.Type.AD_ERROR,(function(e){yc(s,e)})),this.h.D(this.i,"ended",(function(){s.m.contentComplete()})),this.h.pa(this.i,"play",(function(){s.F=!0}))}function yc(e,t){t.getError(),t=(new Map).set("originalEvent",t),e.l(new Jr("ad-error",t)),Mc(e,null),e.l(new Jr("ad-cue-points-changed",(new Map).set("cuepoints",[])))}function _c(e){return document.fullscreenEnabled?!!document.fullscreenElement:!!(e=e.i).webkitSupportsFullscreen&&e.webkitDisplayingFullscreen}function vc(e,t){var n=t.getAd();n?(e.j=new mc(n,e.g,e.i),t.type!=google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED||e.o.supportsMultipleMediaElements||e.l(new Jr("ad-content-pause-requested")),t=(new Map).set("ad",e.j).set("sdkAdObject",n).set("originalEvent",t),e.l(new Jr("ad-started",t)),e.j.isLinear()&&(e.s.setAttribute("ad-active","true"),e.o.customPlayheadTracker||e.i.pause(),e.i.muted?((t=e.j).l=e.i.volume,t.h.setVolume(0)):e.j.setVolume(e.i.volume))):$("The IMA SDK fired a "+t.type+" event with no associated ad. Unable to play ad!")}function Mc(e,t){t&&t.type==google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED&&!e.o.supportsMultipleMediaElements&&e.l(new Jr("ad-content-resume-requested")),e.l(new Jr("ad-stopped",(new Map).set("originalEvent",t))),e.j&&e.j.isLinear()&&(e.s.removeAttribute("ad-active"),e.o.customPlayheadTracker||e.i.ended||e.i.play())}function wc(e,t,n,i,r,a,s,o){this.g=e,this.i=(this.h=t)?n||0:n,this.j=i,this.o=r,this.s=a,this.l=s,this.m=o}function bc(e,t,n,i){function r(){if(!a.H&&a.l&&!a.B.Ia()){a.l=a.h.currentTime,a.m&&!a.m.pre&&!a.m.post&&a.l<a.m.startTime&&(a.m=null);var e=Sc(a);e&&kc(a,e,1,1,Date.now())}}var a=this;if(this.M=null,this.G=e,this.B=t,this.h=n,this.F=null,this.s=!0,this.o=this.h,this.i=i,this.I=new Set,this.C=new Set,this.A=new Map,this.g=new dl,xc(this),this.K=new Z,this.j=new Z,this.H=!1,this.m=this.l=null,this.K.D(this.h,"timeupdate",(function(){if(!(a.H||a.l||a.B.Ia())){a.l=a.h.currentTime;var e=Sc(a,!0);e&&kc(a,e,1,1,Date.now())}})),this.K.D(this.h,"ended",(function(){r()})),this.L=new He(r),"requestVideoFrameCallback"in this.h&&!it()){var s=this.h,o=function(){r(),s.requestVideoFrameCallback(o)};s.requestVideoFrameCallback(o)}else this.L.Ra(.025);this.O=new He((function(){var e,t,n,i,r,s,o,u,l,c,h;return I((function(m){switch(m.g){case 1:if(!a.C.size||null==a.l){m.u(0);break}if((e=a.B.Bg())==rc||e==ac)return m.return();t=!1,n=Array.from(a.C),i=a.B.Qb(),r=d(n),s=r.next();case 3:if(s.done){m.u(5);break}if((o=s.value)==a.m){m.u(4);break}if(u=o.endTime||o.startTime,!(1<=i.start-u)){0<(l=o.startTime-a.l)&&10>=l&&(a.A.has(o)||a.A.set(o,a.g.preload(o.uri,null,o.mimeType||void 0))),m.u(4);break}if(!a.A.has(o)){m.u(7);break}return M(m,a.A.get(o),8);case 8:(c=m.h)&&c.destroy(),a.A.delete(o);case 7:h=JSON.stringify(o),a.I.has(h)&&a.I.delete(h),a.C.delete(o),t=!0;case 4:s=r.next(),m.u(3);break;case 5:t&&Dc(a),w(m)}}))})).Ra(1)}function Tc(e){if(e.G&&e.M&&!e.H){var t=e.M.supportsMultipleMediaElements,n=e.h;n.webkitSupportsFullscreen&&n.webkitDisplayingFullscreen&&(t=!1),e.s==t&&(e.s=!t,e.s?(e.o=e.h,e.F&&(e.F.parentElement&&e.G.removeChild(e.F),e.F=null)):(e.F||((t=document.createElement(e.h.tagName)).autoplay=!0,t.style.position="absolute",t.style.top="0",t.style.left="0",t.style.width="100%",t.style.height="100%",t.style.backgroundColor="rgb(0, 0, 0)",t.setAttribute("playsinline",""),e.F=t),e.o=e.F))}}function Lc(e,t){for(var n=!1,i=(t=d(t)).next();!i.done;i=t.next()){var r=(i=i.value).id||JSON.stringify(i);if(!e.I.has(r)){if(n=!0,e.I.add(r),e.C.add(i),r=!1,i.pre&&null==e.l)r=!0;else if(0!=i.startTime||i.canJump){if(null!=e.l){var a=i.startTime-e.l;0<a&&10>=a&&(r=!0)}}else r=!0;r&&(e.A.has(i)||e.A.set(i,e.g.preload(i.uri,null,i.mimeType||void 0)))}}n&&Dc(e)}function Sc(e,t,n){t=void 0!==t&&t,n=void 0===n?null:n;var i=0,r=null;if(e.C.size&&null!=e.l){var a=e.h.ended,s=Array.from(e.C).sort((function(e,t){return t.startTime-e.startTime})),o=s;for(o=t?s.filter((function(e){return e.pre})):a?s.filter((function(e){return e.post})):s.filter((function(e){return!e.pre&&!e.post})),o=(s=d(o)).next();!o.done;o=s.next()){o=o.value;var u=!1;if(t)u=o.pre;else if(a)u=o.post;else if(!o.pre&&!o.post){var l=e.l-Math.round(1e3*o.startTime)/1e3;0<l&&(1>=l||!o.canJump)&&(u=!(null==n&&e.m&&!e.m.pre&&!e.m.post&&e.m.startTime>=o.startTime))}u&&(!e.m||o.startTime>=e.m.startTime)&&(i==(n||0)?r=o:r&&!o.canJump&&.001<Math.round(1e3*o.startTime)/1e3-Math.round(1e3*r.startTime)/1e3&&(r=o,i=0),i++)}}return r}function kc(e,t,n,i,r,a){var s,o,u,d,l,c,h,m,f,p,g,y,_,v,T,k;a=void 0===a?0:a,I((function(D){switch(D.g){case 1:if(Tc(e),e.m=t,s=Date.now(),!e.o.parentElement&&e.G&&e.G.appendChild(e.o),1==i&&1==n&&(n=Array.from(e.C).filter((function(e){return t.pre?e.pre==t.pre:t.post?e.post==t.post:.001>Math.abs(e.startTime-t.startTime)})).length),t.once&&(a++,e.C.delete(t),Dc(e)),e.H=!0,!e.s||1!=i){D.u(2);break}return e.i(new Jr("ad-content-pause-requested",(new Map).set("saveLivePosition",!0))),o=new Wr,u=function(t){return I((function(n){if(1==n.g)return"detach"!=t.state?n.u(0):it()?M(n,new Promise((function(e){return new He(e).$(.1)})),3):n.u(3);o.resolve(),e.j.cb(e.B,"onstatechange",u),w(n)}))},e.j.D(e.B,"onstatechange",u),M(D,o,2);case 2:return e.s||(e.h.pause(),null!=t.resumeOffset&&0!=t.resumeOffset&&(e.h.currentTime+=t.resumeOffset)),d=!1,l=null,c=function(){if(!e.s&&null==t.resumeOffset)if(t.timelineRange&&t.endTime&&1/0!=t.endTime)e.h.currentTime!=t.endTime&&(e.h.currentTime=t.endTime);else{var n=Date.now();e.h.currentTime+=(n-r)/1e3,r=n}},h=function(){var s,o;return I((function(u){if(1==u.g)return c(),l&&l.stop(),(s=Sc(e,t.pre,i-a))?(e.i(new Jr("ad-stopped")),e.j.Va(),kc(e,s,n,++i,r,a),u.u(0)):(t.post&&(e.l=null,e.m=null),e.s?M(u,e.g.detach(),4):M(u,e.g.ic(),4));e.s&&(null==(o=t.resumeOffset)&&(o=t.timelineRange&&t.endTime&&1/0!=t.endTime?t.endTime-(e.l||0):(Date.now()-r)/1e3),e.i(new Jr("ad-content-resume-requested",(new Map).set("offset",o)))),e.i(new Jr("ad-stopped")),e.j.Va(),e.H=!1,e.s?Dc(e):(c(),e.h.ended||e.h.play()),Tc(e),w(u)}))},m=function(t){return I((function(n){return d?n.return():(d=!0,e.i(new Jr("ad-error",(new Map).set("originalEvent",t))),M(n,h(),0))}))},f=function(){return I((function(t){if(1==t.g)return d?t.return():(d=!0,M(t,h(),2));e.i(new Jr("ad-complete")),w(t)}))},p=function(){return I((function(t){return d?t.return():(d=!0,e.i(new Jr("ad-skipped")),M(t,h(),0))}))},g=new wc(e.o,t.isSkippable,t.skipOffset,t.skipFor,p,n,i,!e.s),e.s||(g.setMuted(e.h.muted),g.setVolume(e.h.volume)),e.i(new Jr("ad-started",(new Map).set("ad",g))),(y=g.canSkipNow())&&e.i(new Jr("ad-skip-state-changed")),e.j.pa(e.g,"error",m),e.j.D(e.o,"timeupdate",(function(){if(e.o.duration){var t=g.canSkipNow();y!=t&&0<g.getRemainingTime()&&0<g.getDuration()&&e.i(new Jr("ad-skip-state-changed")),y=t}})),e.j.pa(e.g,"firstquartile",(function(){c(),e.i(new Jr("ad-first-quartile"))})),e.j.pa(e.g,"midpoint",(function(){c(),e.i(new Jr("ad-midpoint"))})),e.j.pa(e.g,"thirdquartile",(function(){c(),e.i(new Jr("ad-third-quartile"))})),e.j.pa(e.g,"complete",f),e.j.D(e.o,"play",(function(){e.i(new Jr("ad-resumed"))})),e.j.D(e.o,"pause",(function(){var t=e.g.getConfiguration();e.o.currentTime>=t.playRangeEnd?f():e.i(new Jr("ad-paused"))})),e.j.D(e.o,"volumechange",(function(){e.o.muted?e.i(new Jr("ad-muted")):e.i(new Jr("ad-volume-changed"))})),b(D,4),xc(e),t.startTime&&t.endTime&&1/0!=t.endTime&&t.startTime!=t.endTime&&0<(_=t.endTime-t.startTime)&&e.g.configure("playRangeEnd",_),t.playoutLimit&&(l=new He((function(){g.skip()})).$(t.playoutLimit),e.g.configure("playRangeEnd",t.playoutLimit)),M(D,e.g.Tb(e.o),6);case 6:return e.A.has(t)?M(D,e.A.get(t),10):M(D,e.g.load(t.uri,null,t.mimeType||void 0),8);case 10:return v=D.h,e.A.delete(t),M(D,v?e.g.load(v):e.g.load(t.uri,null,t.mimeType||void 0),8);case 8:t.playoutLimit&&(l&&l.stop(),l=new He((function(){g.skip()})).$(t.playoutLimit)),T=(Date.now()-s)/1e3,e.i(new Jr("ads-loaded",(new Map).set("loadTime",T))),e.s&&e.h.play(),L(D,0);break;case 4:k=S(D),m(k),w(D)}}))}function Dc(e){for(var t=[],n=d(e.C),i=n.next(),r={};!i.done;r={Sb:void 0},i=n.next())i=i.value,r.Sb={start:i.startTime,end:null},i.pre?(r.Sb.start=0,r.Sb.end=null):i.post?(r.Sb.start=-1,r.Sb.end=null):i.timelineRange&&(r.Sb.end=i.endTime),t.find(function(e){return function(t){return e.Sb.start==t.start&&e.Sb.end==t.end}}(r))||t.push(r.Sb);e.i(new Jr("ad-cue-points-changed",(new Map).set("cuepoints",t)))}function xc(e){e.g.configure(e.B.Dg()),e.g.configure("ads.disableHLSInterstitial",!0),e.g.configure("ads.disableDASHInterstitial",!0);var t=e.g.Ab();t.og(),t.pg(),ra(e.B.Ab(),t)}function Ac(e,t,n){var i,r;return I((function(a){return 1==a.g?(i=aa([t],{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4}),M(a,e.B.Ab().request(7,i,n).promise,2)):(r=a.h,a.return(r.data))}))}function Yc(e,t,n,i,r){this.h=e,this.j=Lt(this.h.skipOffset),this.g=r,this.i=t,this.l=n,this.o=i,this.m=!1}function Ec(e,t,n,i){this.B=e,this.K=t,this.h=n,this.l=null,this.S=NaN,this.i=i,this.I=!1,this.A=null,this.j=[],this.M=[],this.L=this.C=this.g=null,this.F=new Map,this.m=[],this.s=[],this.G="",this.O=!0,this.H="",this.o=new Z}function Ic(e,t){var n,i,r,a,s,o,u,d;I((function(l){return 1==l.g?t.staticResource?(n=Pc(t),e.F.get(n)?l.return():(i={type:9},r=aa([t.staticResource],{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4}),a=e.K.request(7,r,i),b(l,2),e.F.set(n,[]),M(l,a.promise,4))):l.return():2!=l.g?(s=l.h,o=ct(s.data),u=JSON.parse(o),d=u.apps,e.F.set(n,d),L(l,0)):(S(l),e.F.delete(n),void w(l))}))}function Pc(e){return[e.adId,e.adParameters,e.adSystem,e.adTitle,e.creativeAdId,e.creativeId,e.creativeSequence,e.height,e.width,e.staticResource].join("")}function Cc(e){var t=e.h.currentTime;if(0!=t&&null==e.A){for(var n,i,r=d(e.j),a=r.next();!a.done;a=r.next())for(var s=d((a=a.value).ads),o=s.next();!o.done;o=s.next())if(o=o.value,i){if(o.startTimeInSeconds<t&&o.startTimeInSeconds>i.startTimeInSeconds+i.durationInSeconds){i=o,n=a;break}}else o.startTimeInSeconds<t&&(i=o,n=a);n&&i&&!e.M.includes(i.adId)&&(e.A=t,e.h.currentTime=n.startTimeInSeconds)}}function jc(e){if(e.h.duration&&(e.g||e.j.length)){var t=e.h.currentTime,n=!1;if(e.g){n=!0;var i=e.C,r=i.startTimeInSeconds+.5*i.durationInSeconds,a=i.startTimeInSeconds+.75*i.durationInSeconds;t>=i.startTimeInSeconds+.25*i.durationInSeconds&&!e.s.includes("firstQuartile")?(e.s.push("firstQuartile"),Nc(e,"firstQuartile")):t>=r&&!e.s.includes("midpoint")?(e.s.push("midpoint"),Nc(e,"midpoint")):t>=a&&!e.s.includes("thirdQuartile")&&(e.s.push("thirdQuartile"),Nc(e,"thirdQuartile")),i=e.g.getRemainingTime(),r=e.g.getDuration(),e.g.canSkipNow()&&0<i&&0<r&&Nc(e,"skipStateChanged"),0<r&&(0>=i||i>r)&&Oc(e)}if(!e.g||!e.g.isLinear()){e:for(i=d(e.j),r=i.next();!r.done&&(r=r.value,!e.g||!e.g.isLinear());r=i.next())for(a=0;a<r.ads.length;a++){var s=r.ads[a],o=s.startTimeInSeconds+s.durationInSeconds;if(s.startTimeInSeconds<=t&&o>t){if(e.M.includes(s.adId)){if(e.h.ended)continue;e.h.currentTime=o;break e}Oc(e),e.L=r,e.g=new Yc(s,a+1,r.ads.length,!0,e.h),e.C=s,0===a&&Nc(e,"breakStart"),Rc(e);break}}if(!e.g)for(r=(i=d(e.j)).next();!r.done&&(r=r.value,!e.g);r=i.next())for(a=0;a<r.nonLinearAdsList.length;a++)if((s=r.nonLinearAdsList[a]).nonLinearAdList.length){o=r.startTimeInSeconds;var u=e.F.get(Pc(s.nonLinearAdList[0]));if(o<=t&&u&&u.length){Oc(e),o=e;for(var l=(u=d(u)).next();!l.done;l=u.next())if((l=l.value).data.source.length){var c=document.createElement("img");c.src=l.data.source[0].url,c.style.top=(l.placeholder.top||0)+"%",c.style.height=100-(l.placeholder.top||0)+"%",c.style.left=(l.placeholder.left||0)+"%",c.style.maxWidth=100-(l.placeholder.left||0)+"%",c.style.objectFit="contain",c.style.position="absolute",o.B.appendChild(c)}e.L=r,e.g=new Yc(s,a+1,r.ads.length,!1,e.h),e.C=s,0===a&&Nc(e,"breakStart"),Rc(e);break}}n&&!e.g&&(t=e.h.currentTime,e.A&&e.A>t&&(e.h.currentTime=e.A),e.A=null)}}}function Oc(e){if(e.g){for(;e.B.lastChild;)e.B.removeChild(e.B.firstChild);e.I||e.M.push(e.C.adId);var t=e.g.m;Nc(e,void 0!==t&&t?"skip":"complete");for(var n=(t=d(e.m)).next();!n.done;n=t.next())n=n.value,e.o.cb(n.target,n.type,n.listener);e.m=[],e.s=[],(t=e.g.getPositionInSequence())===(n=e.g.getSequenceLength())&&Nc(e,"breakEnd"),e.g=null,e.C=null,e.L=null}}function Rc(e){var t=!1;e.h.paused?t=!0:(Nc(e,"impression"),Nc(e,"start")),e.m.push({target:e.h,type:"volumechange",listener:function(){e.h.muted&&Nc(e,"mute")}}),e.m.push({target:e.h,type:"volumechange",listener:function(){e.h.muted||Nc(e,"unmute")}}),e.m.push({target:e.h,type:"play",listener:function(){t?(Nc(e,"impression"),Nc(e,"start"),t=!1):Nc(e,"resume")}}),e.m.push({target:e.h,type:"pause",listener:function(){Nc(e,"pause")}});for(var n=d(e.m),i=n.next();!i.done;i=n.next())i=i.value,e.o.D(i.target,i.type,i.listener)}function Nc(e,t){var n=e.C.trackingEvents.find((function(e){return e.eventType==t}));if(n||(n=e.L.adBreakTrackingEvents.find((function(e){return e.eventType==t}))),n)for(var i={type:10},r=(n=d(n.beaconUrls)).next();!r.done;r=n.next())(r=r.value)&&""!=r&&((r=aa([r],{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4})).method="POST",e.K.request(7,r,i));switch(t){case"impression":e.i(new Jr("ad-impression"));break;case"start":e.i(new Jr("ad-started",(new Map).set("ad",e.g)));break;case"mute":e.i(new Jr("ad-muted"));break;case"unmute":e.i(new Jr("ad-volume-changed"));break;case"resume":e.i(new Jr("ad-resumed"));break;case"pause":e.i(new Jr("ad-paused"));break;case"firstQuartile":e.i(new Jr("ad-first-quartile"));break;case"midpoint":e.i(new Jr("ad-midpoint"));break;case"thirdQuartile":e.i(new Jr("ad-third-quartile"));break;case"complete":e.i(new Jr("ad-complete")),e.i(new Jr("ad-stopped"));break;case"skip":e.i(new Jr("ad-skipped")),e.i(new Jr("ad-stopped"));break;case"breakStart":e.B.setAttribute("ad-active","true");break;case"breakEnd":e.B.removeAttribute("ad-active");break;case"skipStateChanged":e.i(new Jr("ad-skip-state-changed"))}}function Hc(e,t){this.g=e,this.i=null,this.h=t}function Uc(e,t,n,i){var r=this;this.s=e,this.l=t,this.j=null,this.F=NaN,this.i=i,this.G=!1,this.A=this.m=this.o=null,this.B="",this.C=[],this.h=new Z,(e=new google.ima.dai.api.UiSettings).setLocale(n),this.g=new google.ima.dai.api.StreamManager(this.l,this.s,e),this.i(new Jr("ima-stream-manager-loaded",(new Map).set("imaStreamManager",this.g))),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.LOADED,(function(e){!function(e,t){e.i(new Jr("ads-loaded",(new Map).set("loadTime",Date.now()/1e3-e.F))),t=t.getStreamData().url,e.j.resolve(t),e.j=null,e.G||e.h.D(e.l,"seeked",(function(){var t=e.l.currentTime;if(0!=t){e.g.streamTimeForContentTime(t);var n=e.g.previousCuePointForStreamTime(t);n&&!n.played&&(e.o=t,e.l.currentTime=n.start)}}))}(r,e)})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.ERROR,(function(){r.B.length?r.j.resolve(r.B):r.j.reject("IMA Stream request returned an error and there was no backup asset uri provided."),r.j=null})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.AD_BREAK_STARTED,(function(){})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.STARTED,(function(e){e=e.getAd(),r.m=new Hc(e,r.l),r.A&&(r.m.i=r.A),r.i(new Jr("ad-started",(new Map).set("ad",r.m))),r.s.setAttribute("ad-active","true")})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.AD_BREAK_ENDED,(function(){r.s.removeAttribute("ad-active");var e=r.l.currentTime;r.o&&r.o>e&&(r.l.currentTime=r.o,r.o=null)})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.AD_PROGRESS,(function(e){r.A=e.getStreamData().adProgressData,r.m&&(r.m.i=r.A)})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.FIRST_QUARTILE,(function(){r.i(new Jr("ad-first-quartile"))})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.MIDPOINT,(function(){r.i(new Jr("ad-midpoint"))})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.THIRD_QUARTILE,(function(){r.i(new Jr("ad-third-quartile"))})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.COMPLETE,(function(){r.i(new Jr("ad-complete")),r.i(new Jr("ad-stopped")),r.s.removeAttribute("ad-active"),r.m=null})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.SKIPPED,(function(){r.i(new Jr("ad-skipped")),r.i(new Jr("ad-stopped"))})),this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.CUEPOINTS_CHANGED,(function(e){var t=e.getStreamData();e=[];for(var n=(t=d(t.cuepoints)).next();!n.done;n=t.next())n=n.value,e.push({start:n.start,end:n.end});r.C=e,r.i(new Jr("ad-cue-points-changed",(new Map).set("cuepoints",e)))}))}function Fc(){Zr.call(this),this.g=this.i=this.j=this.h=null,this.m=new cc,this.o=navigator.language,this.l=null}function Bc(e,t){if(t&&t.type)switch(t.type){case"ads-loaded":e.m.g.push(t.loadTime);break;case"ad-started":e.m.h++;break;case"ad-complete":e.m.j++;break;case"ad-skipped":e.m.l++;break;case"ad-error":e.m.i++}e.dispatchEvent(t)}function Wc(e){return JSON.stringify(e,(function(e,t){if("function"!=typeof t){if(t instanceof Event||t instanceof Jr){var n={};for(i in t)(e=t[i])&&"object"==typeof e?"detail"==i&&(n[i]=e):i in Event||(n[i]=e);return n}if(t instanceof Error){var i=new Set(["name","message","stack"]);for(n in t)i.add(n);for(e=(n=d(Object.getOwnPropertyNames(t))).next();!e.done;e=n.next())i.add(e.value);for(n={},e=(i=d(i)).next();!e.done;e=i.next())n[e=e.value]=t[e];t={__type__:"Error",contents:n}}else if(t instanceof TimeRanges){for(i={__type__:"TimeRanges",length:t.length,start:[],end:[]},n=(t=d(Ls(t))).next();!n.done;n=t.next())e=(n=n.value).end,i.start.push(n.start),i.end.push(e);t=i}else t=ArrayBuffer.isView(t)&&1===t.BYTES_PER_ELEMENT?{__type__:"Uint8Array",entries:Array.from(t)}:"number"==typeof t?isNaN(t)?"NaN":isFinite(t)?t:0>t?"-Infinity":"Infinity":t;return t}}))}function zc(e){return JSON.parse(e,(function(e,t){if("NaN"==t)var n=NaN;else if("-Infinity"==t)n=-1/0;else if("Infinity"==t)n=1/0;else if(t&&"object"==typeof t&&"TimeRanges"==t.__type__)n=function(e){return{length:e.length,start:function(t){return e.start[t]},end:function(t){return e.end[t]}}}(t);else if(t&&"object"==typeof t&&"Uint8Array"==t.__type__)n=new Uint8Array(t.entries);else if(t&&"object"==typeof t&&"Error"==t.__type__){for(n in e=t.contents,t=Error(e.message),e)t[n]=e[n];n=t}else n=t;return n}))}(i=mc.prototype).needsSkipUI=function(){return!1},i.isClientRendering=function(){return!0},i.isUsingAnotherMediaElement=function(){return!0},i.getDuration=function(){return this.g.getDuration()},i.getMinSuggestedDuration=function(){return this.g.getMinSuggestedDuration()},i.getRemainingTime=function(){return this.h.getRemainingTime()},i.isPaused=function(){return this.i},i.isSkippable=function(){return 0<=this.g.getSkipTimeOffset()},i.getTimeUntilSkippable=function(){var e=this.g.getSkipTimeOffset();return e=this.getRemainingTime()-e,Math.max(e,0)},i.canSkipNow=function(){return this.h.getAdSkippableState()},i.skip=function(){return this.h.skip()},i.pause=function(){return this.h.pause()},i.play=function(){return this.h.resume()},i.getVolume=function(){return this.h.getVolume()},i.setVolume=function(e){return this.j.volume=e,this.h.setVolume(e)},i.isMuted=function(){return 0==this.h.getVolume()},i.isLinear=function(){return this.g.isLinear()},i.resize=function(e,t){var n=!1,i=this.j;document.fullscreenEnabled?n=!!document.fullscreenElement:i.webkitSupportsFullscreen&&(n=i.webkitDisplayingFullscreen),this.h.resize(e,t,n?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)},i.setMuted=function(e){(this.j.muted=e)?(this.l=this.getVolume(),this.h.setVolume(0)):this.h.setVolume(this.l)},i.getSequenceLength=function(){var e=this.g.getAdPodInfo();return null==e?1:e.getTotalAds()},i.getPositionInSequence=function(){var e=this.g.getAdPodInfo();return null==e?1:e.getAdPosition()},i.getTitle=function(){return this.g.getTitle()},i.getDescription=function(){return this.g.getDescription()},i.getVastMediaBitrate=function(){return this.g.getVastMediaBitrate()},i.getVastMediaHeight=function(){return this.g.getVastMediaHeight()},i.getVastMediaWidth=function(){return this.g.getVastMediaWidth()},i.getAdId=function(){return this.g.getAdId()},i.getCreativeAdId=function(){return this.g.getCreativeAdId()},i.getAdvertiserName=function(){return this.g.getAdvertiserName()},i.getMediaUrl=function(){return this.g.getMediaUrl()},i.getTimeOffset=function(){var e=this.g.getAdPodInfo();return null==e?0:e.getTimeOffset()},i.getPodIndex=function(){var e=this.g.getAdPodInfo();return null==e?0:e.getPodIndex()},i.release=function(){this.h=this.g=null},U("shaka.ads.ClientSideAd",mc),mc.prototype.release=mc.prototype.release,mc.prototype.getPodIndex=mc.prototype.getPodIndex,mc.prototype.getTimeOffset=mc.prototype.getTimeOffset,mc.prototype.getMediaUrl=mc.prototype.getMediaUrl,mc.prototype.getAdvertiserName=mc.prototype.getAdvertiserName,mc.prototype.getCreativeAdId=mc.prototype.getCreativeAdId,mc.prototype.getAdId=mc.prototype.getAdId,mc.prototype.getVastMediaWidth=mc.prototype.getVastMediaWidth,mc.prototype.getVastMediaHeight=mc.prototype.getVastMediaHeight,mc.prototype.getVastMediaBitrate=mc.prototype.getVastMediaBitrate,mc.prototype.getDescription=mc.prototype.getDescription,mc.prototype.getTitle=mc.prototype.getTitle,mc.prototype.getPositionInSequence=mc.prototype.getPositionInSequence,mc.prototype.getSequenceLength=mc.prototype.getSequenceLength,mc.prototype.setMuted=mc.prototype.setMuted,mc.prototype.resize=mc.prototype.resize,mc.prototype.isLinear=mc.prototype.isLinear,mc.prototype.isMuted=mc.prototype.isMuted,mc.prototype.setVolume=mc.prototype.setVolume,mc.prototype.getVolume=mc.prototype.getVolume,mc.prototype.play=mc.prototype.play,mc.prototype.pause=mc.prototype.pause,mc.prototype.skip=mc.prototype.skip,mc.prototype.canSkipNow=mc.prototype.canSkipNow,mc.prototype.getTimeUntilSkippable=mc.prototype.getTimeUntilSkippable,mc.prototype.isSkippable=mc.prototype.isSkippable,mc.prototype.isPaused=mc.prototype.isPaused,mc.prototype.getRemainingTime=mc.prototype.getRemainingTime,mc.prototype.getMinSuggestedDuration=mc.prototype.getMinSuggestedDuration,mc.prototype.getDuration=mc.prototype.getDuration,mc.prototype.isUsingAnotherMediaElement=mc.prototype.isUsingAnotherMediaElement,mc.prototype.isClientRendering=mc.prototype.isClientRendering,mc.prototype.needsSkipUI=mc.prototype.needsSkipUI,U("shaka.ads.Utils",fc),fc.ADS_LOADED="ads-loaded",fc.AD_STARTED="ad-started",fc.AD_FIRST_QUARTILE="ad-first-quartile",fc.AD_MIDPOINT="ad-midpoint",fc.AD_THIRD_QUARTILE="ad-third-quartile",fc.AD_COMPLETE="ad-complete",fc.AD_STOPPED="ad-stopped",fc.AD_SKIPPED="ad-skipped",fc.AD_VOLUME_CHANGED="ad-volume-changed",fc.AD_MUTED="ad-muted",fc.AD_PAUSED="ad-paused",fc.AD_RESUMED="ad-resumed",fc.AD_SKIP_STATE_CHANGED="ad-skip-state-changed",fc.CUEPOINTS_CHANGED="ad-cue-points-changed",fc.IMA_AD_MANAGER_LOADED="ima-ad-manager-loaded",fc.IMA_STREAM_MANAGER_LOADED="ima-stream-manager-loaded",fc.AD_CLICKED="ad-clicked",fc.AD_PROGRESS="ad-progress",fc.AD_BUFFERING="ad-buffering",fc.AD_IMPRESSION="ad-impression",fc.AD_DURATION_CHANGED="ad-duration-changed",fc.AD_CLOSED="ad-closed",fc.AD_LOADED="ad-loaded",fc.ALL_ADS_COMPLETED="all-ads-completed",fc.AD_LINEAR_CHANGED="ad-linear-changed",fc.AD_METADATA="ad-metadata",fc.AD_RECOVERABLE_ERROR="ad-recoverable-error",fc.AD_ERROR="ad-error",fc.AD_BREAK_READY="ad-break-ready",fc.AD_INTERACTION="ad-interaction",fc.AD_CONTENT_PAUSE_REQUESTED="ad-content-pause-requested",fc.AD_CONTENT_RESUME_REQUESTED="ad-content-resume-requested",fc.AD_CONTENT_ATTACH_REQUESTED="ad-content-attach-requested",gc.prototype.configure=function(e){this.o=e},gc.prototype.stop=function(){this.g&&this.g.stop(),this.s&&Ds(this.s)},gc.prototype.release=function(){this.stop(),this.A&&this.A.disconnect(),this.h&&this.h.release(),this.g&&this.g.destroy(),this.m.destroy(),this.C.destroy()},(i=wc.prototype).needsSkipUI=function(){return!0},i.isClientRendering=function(){return!0},i.isUsingAnotherMediaElement=function(){return this.m},i.getDuration=function(){var e=this.g.duration;return isNaN(e)?-1:e},i.getMinSuggestedDuration=function(){return this.getDuration()},i.getRemainingTime=function(){var e=this.g.duration;return isNaN(e)?-1:e-this.g.currentTime},i.isPaused=function(){return this.g.paused},i.isSkippable=function(){return this.h&&null!=this.j?this.getDuration()-this.getRemainingTime()<this.i+this.j:this.h},i.getTimeUntilSkippable=function(){if(this.isSkippable()){var e=this.getRemainingTime()+this.i-this.getDuration();return Math.max(e,0)}return Math.max(this.getRemainingTime(),0)},i.canSkipNow=function(){return this.h&&0==this.getTimeUntilSkippable()},i.skip=function(){this.canSkipNow()&&this.o()},i.pause=function(){return this.g.pause()},i.play=function(){return this.g.play()},i.getVolume=function(){return this.g.volume},i.setVolume=function(e){this.g.volume=e},i.isMuted=function(){return this.g.muted},i.isLinear=function(){return!0},i.resize=function(){},i.setMuted=function(e){this.g.muted=e},i.getSequenceLength=function(){return this.s},i.getPositionInSequence=function(){return this.l},i.getTitle=function(){return""},i.getDescription=function(){return""},i.getVastMediaBitrate=function(){return 0},i.getVastMediaHeight=function(){return 0},i.getVastMediaWidth=function(){return 0},i.getAdId=function(){return""},i.getCreativeAdId=function(){return""},i.getAdvertiserName=function(){return""},i.getMediaUrl=function(){return null},i.getTimeOffset=function(){return 0},i.getPodIndex=function(){return 0},i.release=function(){this.g=null},U("shaka.ads.InterstitialAd",wc),wc.prototype.release=wc.prototype.release,wc.prototype.getPodIndex=wc.prototype.getPodIndex,wc.prototype.getTimeOffset=wc.prototype.getTimeOffset,wc.prototype.getMediaUrl=wc.prototype.getMediaUrl,wc.prototype.getAdvertiserName=wc.prototype.getAdvertiserName,wc.prototype.getCreativeAdId=wc.prototype.getCreativeAdId,wc.prototype.getAdId=wc.prototype.getAdId,wc.prototype.getVastMediaWidth=wc.prototype.getVastMediaWidth,wc.prototype.getVastMediaHeight=wc.prototype.getVastMediaHeight,wc.prototype.getVastMediaBitrate=wc.prototype.getVastMediaBitrate,wc.prototype.getDescription=wc.prototype.getDescription,wc.prototype.getTitle=wc.prototype.getTitle,wc.prototype.getPositionInSequence=wc.prototype.getPositionInSequence,wc.prototype.getSequenceLength=wc.prototype.getSequenceLength,wc.prototype.setMuted=wc.prototype.setMuted,wc.prototype.resize=wc.prototype.resize,wc.prototype.isLinear=wc.prototype.isLinear,wc.prototype.isMuted=wc.prototype.isMuted,wc.prototype.setVolume=wc.prototype.setVolume,wc.prototype.getVolume=wc.prototype.getVolume,wc.prototype.play=wc.prototype.play,wc.prototype.pause=wc.prototype.pause,wc.prototype.skip=wc.prototype.skip,wc.prototype.canSkipNow=wc.prototype.canSkipNow,wc.prototype.getTimeUntilSkippable=wc.prototype.getTimeUntilSkippable,wc.prototype.isSkippable=wc.prototype.isSkippable,wc.prototype.isPaused=wc.prototype.isPaused,wc.prototype.getRemainingTime=wc.prototype.getRemainingTime,wc.prototype.getMinSuggestedDuration=wc.prototype.getMinSuggestedDuration,wc.prototype.getDuration=wc.prototype.getDuration,wc.prototype.isUsingAnotherMediaElement=wc.prototype.isUsingAnotherMediaElement,wc.prototype.isClientRendering=wc.prototype.isClientRendering,wc.prototype.needsSkipUI=wc.prototype.needsSkipUI,bc.prototype.configure=function(e){this.M=e,Tc(this)},bc.prototype.stop=function(){this.j&&this.j.Va(),this.I.clear(),this.C.clear(),this.g.Te(),this.A.clear(),this.g.detach(),this.H=!1,this.m=this.l=null},bc.prototype.release=function(){this.stop(),this.K&&this.K.release(),this.j&&this.j.release(),this.G&&Ds(this.G),this.L&&(this.L.stop(),this.L=null),this.O&&(this.O.stop(),this.O=null),this.g.destroy()},bc.prototype.addAdUrlInterstitial=function(e){var t,n,i,r,a,s,o,u,c,h=this;return I((function(m){switch(m.g){case 1:return M(m,Ac(h,e,t={type:12}),2);case 2:if(n=m.h,!(i=At(n,"VAST,vmap:VMAP")))throw new Ye(2,10,10007);if(r=[],"VAST"==i.tagName){r=pc(i,h.l),m.u(3);break}if("vmap:VMAP"!=i.tagName){m.u(3);break}for(var f=[],p=d(Ct(i,"vmap:AdBreak")),g=p.next();!g.done;g=p.next()){var y=g.value,_=y.attributes.timeOffset;_&&(g=null,g="start"==_?0:"end"==_?1/0:Lt(_),(y=Nt(y,"vmap:AdSource"))&&(y=Nt(y,"vmap:AdTagURI"))&&(y=jt(y))&&f.push({time:g,uri:y}))}a=d(f),s=a.next();case 5:if(s.done){m.u(3);break}return o=s.value,M(m,Ac(h,o.uri,t),8);case 8:if(u=m.h,!(c=At(u,"VAST")))throw new Ye(2,10,10007);r.push.apply(r,l(pc(c,o.time))),s=a.next(),m.u(5);break;case 3:Lc(h,r),w(m)}}))},(i=Yc.prototype).needsSkipUI=function(){return!0},i.isClientRendering=function(){return!1},i.isUsingAnotherMediaElement=function(){return!1},i.getDuration=function(){return this.h.durationInSeconds},i.getMinSuggestedDuration=function(){return this.getDuration()},i.getRemainingTime=function(){return this.h.startTimeInSeconds+this.h.durationInSeconds-this.g.currentTime},i.isPaused=function(){return this.g.paused},i.isSkippable=function(){return"number"==typeof this.j},i.getTimeUntilSkippable=function(){if("number"!=typeof this.j)return this.getRemainingTime();var e=this.getRemainingTime()+this.j-this.getDuration();return Math.max(e,0)},i.canSkipNow=function(){return 0==this.getTimeUntilSkippable()},i.skip=function(){this.m=!0,this.g.currentTime+=this.getRemainingTime()},i.pause=function(){return this.g.pause()},i.play=function(){return this.g.play()},i.getVolume=function(){return this.g.volume},i.setVolume=function(e){this.g.volume=e},i.isMuted=function(){return this.g.muted},i.isLinear=function(){return this.o},i.resize=function(){},i.setMuted=function(e){this.g.muted=e},i.getSequenceLength=function(){return this.l?this.l:1},i.getPositionInSequence=function(){return this.i?this.i:1},i.getTitle=function(){return this.h.adTitle},i.getDescription=function(){return""},i.getVastMediaBitrate=function(){return 0},i.getVastMediaHeight=function(){return 0},i.getVastMediaWidth=function(){return 0},i.getAdId=function(){return this.h.adId},i.getCreativeAdId=function(){return this.h.creativeId},i.getAdvertiserName=function(){return""},i.getMediaUrl=function(){return null},i.getTimeOffset=function(){return 0},i.getPodIndex=function(){return 0},i.release=function(){this.l=this.i=this.g=this.h=null},U("shaka.ads.MediaTailorAd",Yc),Yc.prototype.release=Yc.prototype.release,Yc.prototype.getPodIndex=Yc.prototype.getPodIndex,Yc.prototype.getTimeOffset=Yc.prototype.getTimeOffset,Yc.prototype.getMediaUrl=Yc.prototype.getMediaUrl,Yc.prototype.getAdvertiserName=Yc.prototype.getAdvertiserName,Yc.prototype.getCreativeAdId=Yc.prototype.getCreativeAdId,Yc.prototype.getAdId=Yc.prototype.getAdId,Yc.prototype.getVastMediaWidth=Yc.prototype.getVastMediaWidth,Yc.prototype.getVastMediaHeight=Yc.prototype.getVastMediaHeight,Yc.prototype.getVastMediaBitrate=Yc.prototype.getVastMediaBitrate,Yc.prototype.getDescription=Yc.prototype.getDescription,Yc.prototype.getTitle=Yc.prototype.getTitle,Yc.prototype.getPositionInSequence=Yc.prototype.getPositionInSequence,Yc.prototype.getSequenceLength=Yc.prototype.getSequenceLength,Yc.prototype.setMuted=Yc.prototype.setMuted,Yc.prototype.resize=Yc.prototype.resize,Yc.prototype.isLinear=Yc.prototype.isLinear,Yc.prototype.isMuted=Yc.prototype.isMuted,Yc.prototype.setVolume=Yc.prototype.setVolume,Yc.prototype.getVolume=Yc.prototype.getVolume,Yc.prototype.play=Yc.prototype.play,Yc.prototype.pause=Yc.prototype.pause,Yc.prototype.skip=Yc.prototype.skip,Yc.prototype.canSkipNow=Yc.prototype.canSkipNow,Yc.prototype.getTimeUntilSkippable=Yc.prototype.getTimeUntilSkippable,Yc.prototype.isSkippable=Yc.prototype.isSkippable,Yc.prototype.isPaused=Yc.prototype.isPaused,Yc.prototype.getRemainingTime=Yc.prototype.getRemainingTime,Yc.prototype.getMinSuggestedDuration=Yc.prototype.getMinSuggestedDuration,Yc.prototype.getDuration=Yc.prototype.getDuration,Yc.prototype.isUsingAnotherMediaElement=Yc.prototype.isUsingAnotherMediaElement,Yc.prototype.isClientRendering=Yc.prototype.isClientRendering,Yc.prototype.needsSkipUI=Yc.prototype.needsSkipUI,Ec.prototype.stop=function(){for(var e=d(this.m),t=e.next();!t.done;t=e.next())t=t.value,this.o.cb(t.target,t.type,t.listener);Oc(this),this.m=[],this.s=[],this.G="",this.O=!0,this.H="",this.A=null,this.j=[],this.M=[],this.F.clear()},Ec.prototype.release=function(){this.stop(),this.o&&this.o.release()},Ec.prototype.onManifestUpdated=function(e){this.I=e,""!=this.G&&(function(e,t,n){var i,r,a,s,o,u,l,c,h,m,f,p,g,y,_,v;I((function(T){if(1==T.g)return i={type:8},r=aa([t],{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4}),a=e.K.request(7,r,i),b(T,2),M(T,a.promise,4);if(2!=T.g){if(s=T.h,o=[],u=ct(s.data),0<(l=JSON.parse(u)).avails.length){if(JSON.stringify(e.j)!=JSON.stringify(l.avails)){for(e.j=l.avails,c=d(e.j),h=c.next();!h.done;h=c.next())for(m=h.value,f=d(m.nonLinearAdsList),p=f.next();!p.done;p=f.next())for(g=p.value,y=d(g.nonLinearAdList),_=y.next();!_.done;_=y.next())v=_.value,Ic(e,v);o=e.getCuePoints(),e.i(new Jr("ad-cue-points-changed",(new Map).set("cuepoints",o)))}}else e.j.length&&e.i(new Jr("ad-cue-points-changed",(new Map).set("cuepoints",o))),Oc(e),e.j=[];return n&&(e.I||0<o.length)&&function(e){jc(e),e.I||(Cc(e),e.o.D(e.h,"seeked",(function(){Cc(e)})),e.o.D(e.h,"ended",(function(){Oc(e)}))),e.o.D(e.h,"timeupdate",(function(){jc(e)}))}(e),L(T,0)}S(T),w(T)}))}(this,this.G,this.O),this.O=!1)},Ec.prototype.getCuePoints=function(){for(var e=[],t=d(this.j),n=t.next();!n.done;n=t.next())for(var i=(n=d(n.value.ads)).next();!i.done;i=n.next())i=i.value,e.push({start:i.startTimeInSeconds,end:i.startTimeInSeconds+i.durationInSeconds});return e},(i=Hc.prototype).needsSkipUI=function(){return!0},i.isClientRendering=function(){return!1},i.isUsingAnotherMediaElement=function(){return!1},i.getDuration=function(){return this.i?this.i.duration:-1},i.getMinSuggestedDuration=function(){return this.getDuration()},i.getRemainingTime=function(){return this.i?this.i.duration-this.i.currentTime:-1},i.isPaused=function(){return this.h.paused},i.isSkippable=function(){return this.g.isSkippable()},i.getTimeUntilSkippable=function(){var e=this.g.getSkipTimeOffset();return e=this.getRemainingTime()-e,Math.max(e,0)},i.canSkipNow=function(){return 0==this.getTimeUntilSkippable()},i.skip=function(){this.h.currentTime+=this.getRemainingTime()},i.pause=function(){return this.h.pause()},i.play=function(){return this.h.play()},i.getVolume=function(){return this.h.volume},i.setVolume=function(e){this.h.volume=e},i.isMuted=function(){return this.h.muted},i.isLinear=function(){return!0},i.resize=function(){},i.setMuted=function(e){this.h.muted=e},i.getSequenceLength=function(){var e=this.g.getAdPodInfo();return null==e?1:e.getTotalAds()},i.getPositionInSequence=function(){var e=this.g.getAdPodInfo();return null==e?1:e.getAdPosition()},i.getTitle=function(){return this.g.getTitle()},i.getDescription=function(){return this.g.getDescription()},i.getVastMediaBitrate=function(){return 0},i.getVastMediaHeight=function(){return this.g.getVastMediaHeight()},i.getVastMediaWidth=function(){return this.g.getVastMediaWidth()},i.getAdId=function(){return this.g.getAdId()},i.getCreativeAdId=function(){return this.g.getCreativeAdId()},i.getAdvertiserName=function(){return this.g.getAdvertiserName()},i.getMediaUrl=function(){return null},i.getTimeOffset=function(){var e=this.g.getAdPodInfo();return null==e?0:e.getTimeOffset()},i.getPodIndex=function(){var e=this.g.getAdPodInfo();return null==e?0:e.getPodIndex()},i.release=function(){this.h=this.i=this.g=null},U("shaka.ads.ServerSideAd",Hc),Hc.prototype.release=Hc.prototype.release,Hc.prototype.getPodIndex=Hc.prototype.getPodIndex,Hc.prototype.getTimeOffset=Hc.prototype.getTimeOffset,Hc.prototype.getMediaUrl=Hc.prototype.getMediaUrl,Hc.prototype.getAdvertiserName=Hc.prototype.getAdvertiserName,Hc.prototype.getCreativeAdId=Hc.prototype.getCreativeAdId,Hc.prototype.getAdId=Hc.prototype.getAdId,Hc.prototype.getVastMediaWidth=Hc.prototype.getVastMediaWidth,Hc.prototype.getVastMediaHeight=Hc.prototype.getVastMediaHeight,Hc.prototype.getVastMediaBitrate=Hc.prototype.getVastMediaBitrate,Hc.prototype.getDescription=Hc.prototype.getDescription,Hc.prototype.getTitle=Hc.prototype.getTitle,Hc.prototype.getPositionInSequence=Hc.prototype.getPositionInSequence,Hc.prototype.getSequenceLength=Hc.prototype.getSequenceLength,Hc.prototype.setMuted=Hc.prototype.setMuted,Hc.prototype.resize=Hc.prototype.resize,Hc.prototype.isLinear=Hc.prototype.isLinear,Hc.prototype.isMuted=Hc.prototype.isMuted,Hc.prototype.setVolume=Hc.prototype.setVolume,Hc.prototype.getVolume=Hc.prototype.getVolume,Hc.prototype.play=Hc.prototype.play,Hc.prototype.pause=Hc.prototype.pause,Hc.prototype.skip=Hc.prototype.skip,Hc.prototype.canSkipNow=Hc.prototype.canSkipNow,Hc.prototype.getTimeUntilSkippable=Hc.prototype.getTimeUntilSkippable,Hc.prototype.isSkippable=Hc.prototype.isSkippable,Hc.prototype.isPaused=Hc.prototype.isPaused,Hc.prototype.getRemainingTime=Hc.prototype.getRemainingTime,Hc.prototype.getMinSuggestedDuration=Hc.prototype.getMinSuggestedDuration,Hc.prototype.getDuration=Hc.prototype.getDuration,Hc.prototype.isUsingAnotherMediaElement=Hc.prototype.isUsingAnotherMediaElement,Hc.prototype.isClientRendering=Hc.prototype.isClientRendering,Hc.prototype.needsSkipUI=Hc.prototype.needsSkipUI,(i=Uc.prototype).configure=function(){},i.stop=function(){this.B="",this.o=null,this.C=[]},i.release=function(){this.stop(),this.h&&this.h.release()},i.onCueMetadataChange=function(e){if(e.key&&e.data){var t={};t[e.key]=e.data,this.g.onTimedMetadata(t)}},i.getCuePoints=function(){return this.C},g(Fc,Zr),(i=Fc.prototype).setLocale=function(e){this.o=e},i.configure=function(e){this.l=e,this.h&&this.h.configure(this.l),this.j&&this.j.configure(this.l),this.g&&this.g.configure(this.l)},i.initInterstitial=function(e,t,n){var i=this;this.h&&this.h.release(),this.h=new bc(e,t,n,(function(e){return Bc(i,e)})),this.h.configure(this.l)},i.initClientSide=function(t,n,i){var r=this;if(!e.google||!google.ima||!google.ima.AdsLoader)throw new Ye(2,10,1e4);this.j&&this.j.release(),this.j=new gc(t,n,this.o,i,(function(e){return Bc(r,e)})),this.j.configure(this.l)},i.release=function(){this.h&&(this.h.release(),this.h=null),this.j&&(this.j.release(),this.j=null),this.i&&(this.i.release(),this.i=null),this.g&&(this.g.release(),this.g=null),Zr.prototype.release.call(this)},i.onAssetUnload=function(){this.h&&this.h.stop(),this.j&&this.j.stop(),this.i&&this.i.stop(),this.g&&this.g.stop(),this.dispatchEvent(new Jr("ad-stopped")),this.dispatchEvent(new Jr("ad-content-attach-requested")),this.m=new cc},i.requestClientSideAds=function(e){if(!this.j)throw new Ye(1,10,10001);var t=this.j;t.g&&t.g.destroy(),t.m&&t.m.contentComplete(),t.G=Date.now()/1e3,t.m.requestAds(e)},i.updateClientSideAdsRenderingSettings=function(e){if(!this.j)throw new Ye(1,10,10001);var t=this.j;t.B=e,t.g&&t.g.updateAdsRenderingSettings(t.B)},i.initMediaTailor=function(e,t,n){var i=this;this.i&&this.i.release(),this.i=new Ec(e,t,n,(function(e){return Bc(i,e)}))},i.requestMediaTailorStream=function(e,t,n){if(!this.i)throw new Ye(1,10,10005);var i=this.i;return n=void 0===n?"":n,i.l?e=Promise.reject(new Ye(1,10,10004)):(i.l=new Wr,function(e,t,n){var i,r,a,s,o,u,d,l,c,h,m,f;I((function(p){if(1==p.g)return i={type:7},(r=aa([t],{maxAttempts:2,baseDelay:1e3,backoffFactor:2,fuzzFactor:.5,timeout:3e4,stallTimeout:5e3,connectionTimeout:1e4})).method="POST",n&&(a=JSON.stringify(n),r.body=ft(a)),s=e.K.request(7,r,i),b(p,2),M(p,s.promise,4);if(2!=p.g){if(o=p.h,u=ct(o.data),!(d=JSON.parse(u)).manifestUrl||!d.trackingUrl)throw Error("Insufficient data from MediaTailor.");return l=new Wn(t),c=new Wn(d.trackingUrl),e.G=l.resolve(c).toString(),h=Date.now()/1e3,m=h-e.S,e.i(new Jr("ads-loaded",(new Map).set("loadTime",m))),f=new Wn(d.manifestUrl),e.l.resolve(l.resolve(f).toString()),e.l=null,L(p,0)}if(S(p),!e.H.length)return e.l.reject("MediaTailor request returned an error and there was no backup asset uri provided."),e.l=null,p.return();e.l.resolve(e.H),e.l=null,w(p)}))}(i,e,t),i.H=n||"",i.S=Date.now()/1e3,e=i.l),e},i.addMediaTailorTrackingUrl=function(e){if(!this.i)throw new Ye(1,10,10005);var t=this.i;t.G=e,t.i(new Jr("ads-loaded",(new Map).set("loadTime",0)))},i.initServerSide=function(t,n){var i=this;if(!e.google||!google.ima||!google.ima.dai)throw new Ye(2,10,10002);this.g&&this.g.release(),this.g=new Uc(t,n,this.o,(function(e){return Bc(i,e)})),this.g.configure(this.l)},i.requestServerSideStream=function(e,t){if(t=void 0===t?"":t,!this.g)throw new Ye(1,10,10003);e.adTagParameters||(e.adTagParameters={});var n=e.adTagParameters;return(n.mpt||n.mpv)&&$('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.'),e.adTagParameters.mpt="shaka-player",e.adTagParameters.mpv="v4.12.5",(n=this.g).j?e=Promise.reject(new Ye(1,10,10004)):(e instanceof google.ima.dai.api.LiveStreamRequest&&(n.G=!0),n.j=new Wr,n.g.requestStream(e),n.B=t||"",n.F=Date.now()/1e3,e=n.j),e},i.replaceServerSideAdTagParameters=function(e){if(!this.g)throw new Ye(1,10,10003);(e.mpt||e.mpv)&&$('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.'),e.mpt="Shaka Player",e.mpv="v4.12.5",this.g.g.replaceAdTagParameters(e)},i.getServerSideCuePoints=function(){return se("AdManager.getServerSideCuePoints","Please use getCuePoints function."),this.getCuePoints()},i.getCuePoints=function(){var e=[];return this.g&&(e=e.concat(this.g.getCuePoints())),this.i&&(e=e.concat(this.i.getCuePoints())),e},i.getStats=function(){var e=this.m;return{loadTimes:e.g,averageLoadTime:hc(e),started:e.h,playedCompletely:e.j,skipped:e.l,errors:e.i}},i.onManifestUpdated=function(e){this.i&&this.i.onManifestUpdated(e)},i.onDashTimedMetadata=function(e){this.g&&"urn:google:dai:2018"==e.schemeIdUri&&this.g.g.processMetadata(e.schemeIdUri,e.eventNode?e.eventNode.attributes.messageData:null,e.startTime)},i.onHlsTimedMetadata=function(e,t){this.g&&this.g.g.processMetadata("ID3",e.data,t)},i.onCueMetadataChange=function(e){this.g&&this.g.onCueMetadataChange(e)},i.onHLSInterstitialMetadata=function(e,t,n){this.l&&this.l.disableHLSInterstitial||(this.h||this.initInterstitial(null,e,t),this.h&&function(e,t){var n;I((function(i){if(1==i.g)return xc(e),M(i,function(e,t){var n,i,r,a,s,o,u,d,l,c,h,m,f,p,g,y,_,v,w,T,k,D,x,A,Y,E,P,C,j,O,R,N,H,U,F,B,W,z,V,G,q;return I((function(I){switch(I.g){case 1:if(n=[],!t)return I.return(n);if(i=t.values.find((function(e){return"X-ASSET-URI"==e.key})),r=t.values.find((function(e){return"X-ASSET-LIST"==e.key})),!i&&!r)return I.return(n);if(a=null,(s=t.values.find((function(e){return"ID"==e.key})))&&(a=s.data),o=null==a?Math.floor(10*t.startTime)/10:t.startTime,(u=t.endTime)&&1/0!=t.endTime&&"number"==typeof t.endTime&&(u=null==a?Math.floor(10*t.endTime)/10:t.endTime),d=t.values.find((function(e){return"X-RESTRICT"==e.key})),c=l=!0,d&&d.data&&(h=d.data,l=!h.includes("SKIP"),c=!h.includes("JUMP")),m=l?0:null,(f=t.values.find((function(e){return"X-ENABLE-SKIP-AFTER"==e.key})))&&(p=f.data,m=parseFloat(p),isNaN(m)&&(m=l?0:null)),g=null,(y=t.values.find((function(e){return"X-ENABLE-SKIP-FOR"==e.key})))&&(_=y.data,g=parseFloat(_),isNaN(m)&&(g=null)),v=null,(w=t.values.find((function(e){return"X-RESUME-OFFSET"==e.key})))&&(T=w.data,v=parseFloat(T),isNaN(v)&&(v=null)),k=null,(D=t.values.find((function(e){return"X-PLAYOUT-LIMIT"==e.key})))&&(x=D.data,k=parseFloat(x),isNaN(k)&&(k=null)),E=Y=A=!1,(P=t.values.find((function(e){return"CUE"==e.key})))&&(C=P.data,A=C.includes("ONCE"),Y=C.includes("PRE"),E=C.includes("POST")),j=!1,(O=t.values.find((function(e){return"X-TIMELINE-OCCUPIES"==e.key})))?(R=O.data,j=R.includes("RANGE")):!w&&e.B.U()&&(j=!Y&&!E),i){if(!(N=i.data))return I.return(n);n.push({id:a,startTime:o,endTime:u,uri:N,mimeType:null,isSkippable:l,skipOffset:m,skipFor:g,canJump:c,resumeOffset:v,playoutLimit:k,once:A,pre:Y,post:E,timelineRange:j}),I.u(2);break}if(!r){I.u(2);break}return(H=r.data)?(b(I,4),M(I,Ac(e,H,{type:11}),6)):I.return(n);case 6:for(U=I.h,F=ct(U),B=JSON.parse(F),(W=B["SKIP-CONTROL"])&&("number"==typeof(z=W["ENABLE-SKIP-AFTER"])&&(m=parseFloat(z),isNaN(z)&&(m=l?0:null)),"number"==typeof(V=W["ENABLE-SKIP-FOR"])&&(g=parseFloat(V),isNaN(V)&&(g=null))),G=0;G<B.ASSETS.length;G++)(q=B.ASSETS[G]).URI&&n.push({id:a+"_asset_"+G,startTime:o,endTime:u,uri:q.URI,mimeType:null,isSkippable:l,skipOffset:m,skipFor:g,canJump:c,resumeOffset:v,playoutLimit:k,once:A,pre:Y,post:E,timelineRange:j});L(I,2);break;case 4:S(I);case 2:return I.return(n)}}))}(e,t),2);(n=i.h).length?Lc(e,n):$("Unsupported HLS interstitial",t),w(i)}))}(this.h,n))},i.onDASHInterstitialMetadata=function(e,t,n){if(!(this.l&&this.l.disableDASHInterstitial||"urn:mpeg:dash:event:alternativeMPD:2022"!=n.schemeIdUri)&&(this.h||this.initInterstitial(null,e,t),this.h)){e=this.h;for(var i=(t=d(n.eventNode.children)).next();!i.done;i=t.next()){var r=i.value;if("AlternativeMPD"==r.tagName&&(i=r.attributes.uri,r=r.attributes.mode,i)){var a=i,s=r;break}}a?(t="replace"==s,s="insert"==s,(t||s)&&Lc(e,[{id:n.id,startTime:n.startTime,endTime:n.endTime,uri:a,mimeType:null,isSkippable:!1,skipOffset:null,skipFor:null,canJump:!0,resumeOffset:s?0:null,playoutLimit:null,once:!1,pre:!1,post:!1,timelineRange:t&&!s}])):$("Unsupported MPD alternate",n)}},i.addCustomInterstitial=function(e){if(!this.h)throw new Ye(1,10,10006);Lc(this.h,[e])},i.addAdUrlInterstitial=function(e){if(!this.h)throw new Ye(1,10,10006);return this.h.addAdUrlInterstitial(e)},U("shaka.ads.AdManager",Fc),Fc.prototype.addAdUrlInterstitial=Fc.prototype.addAdUrlInterstitial,Fc.prototype.addCustomInterstitial=Fc.prototype.addCustomInterstitial,Fc.prototype.onDASHInterstitialMetadata=Fc.prototype.onDASHInterstitialMetadata,Fc.prototype.onHLSInterstitialMetadata=Fc.prototype.onHLSInterstitialMetadata,Fc.prototype.onCueMetadataChange=Fc.prototype.onCueMetadataChange,Fc.prototype.onHlsTimedMetadata=Fc.prototype.onHlsTimedMetadata,Fc.prototype.onDashTimedMetadata=Fc.prototype.onDashTimedMetadata,Fc.prototype.onManifestUpdated=Fc.prototype.onManifestUpdated,Fc.prototype.getStats=Fc.prototype.getStats,Fc.prototype.getCuePoints=Fc.prototype.getCuePoints,Fc.prototype.getServerSideCuePoints=Fc.prototype.getServerSideCuePoints,Fc.prototype.replaceServerSideAdTagParameters=Fc.prototype.replaceServerSideAdTagParameters,Fc.prototype.requestServerSideStream=Fc.prototype.requestServerSideStream,Fc.prototype.initServerSide=Fc.prototype.initServerSide,Fc.prototype.addMediaTailorTrackingUrl=Fc.prototype.addMediaTailorTrackingUrl,Fc.prototype.requestMediaTailorStream=Fc.prototype.requestMediaTailorStream,Fc.prototype.initMediaTailor=Fc.prototype.initMediaTailor,Fc.prototype.updateClientSideAdsRenderingSettings=Fc.prototype.updateClientSideAdsRenderingSettings,Fc.prototype.requestClientSideAds=Fc.prototype.requestClientSideAds,Fc.prototype.onAssetUnload=Fc.prototype.onAssetUnload,Fc.prototype.release=Fc.prototype.release,Fc.prototype.initClientSide=Fc.prototype.initClientSide,Fc.prototype.initInterstitial=Fc.prototype.initInterstitial,Fc.prototype.configure=Fc.prototype.configure,Fc.prototype.setLocale=Fc.prototype.setLocale,Fc.ADS_LOADED="ads-loaded",Fc.AD_STARTED="ad-started",Fc.AD_FIRST_QUARTILE="ad-first-quartile",Fc.AD_MIDPOINT="ad-midpoint",Fc.AD_THIRD_QUARTILE="ad-third-quartile",Fc.AD_COMPLETE="ad-complete",Fc.AD_STOPPED="ad-stopped",Fc.AD_SKIPPED="ad-skipped",Fc.AD_VOLUME_CHANGED="ad-volume-changed",Fc.AD_MUTED="ad-muted",Fc.AD_PAUSED="ad-paused",Fc.AD_RESUMED="ad-resumed",Fc.AD_SKIP_STATE_CHANGED="ad-skip-state-changed",Fc.CUEPOINTS_CHANGED="ad-cue-points-changed",Fc.IMA_AD_MANAGER_LOADED="ima-ad-manager-loaded",Fc.IMA_STREAM_MANAGER_LOADED="ima-stream-manager-loaded",Fc.AD_CLICKED="ad-clicked",Fc.AD_PROGRESS="ad-progress",Fc.AD_BUFFERING="ad-buffering",Fc.AD_IMPRESSION="ad-impression",Fc.AD_DURATION_CHANGED="ad-duration-changed",Fc.AD_CLOSED="ad-closed",Fc.AD_LOADED="ad-loaded",Fc.ALL_ADS_COMPLETED="all-ads-completed",Fc.AD_LINEAR_CHANGED="ad-linear-changed",Fc.AD_METADATA="ad-metadata",Fc.AD_RECOVERABLE_ERROR="ad-recoverable-error",Fc.AD_ERROR="ad-error",Fc.AD_BREAK_READY="ad-break-ready",Fc.AD_INTERACTION="ad-interaction",Fc.AD_CONTENT_PAUSE_REQUESTED="ad-content-pause-requested",Fc.AD_CONTENT_RESUME_REQUESTED="ad-content-resume-requested",Fc.AD_CONTENT_ATTACH_REQUESTED="ad-content-attach-requested",lc=function(){return new Fc};var Vc="ended play playing pause pausing ratechange seeked seeking timeupdate volumechange".split(" "),Gc="buffered currentTime duration ended loop muted paused playbackRate seeking videoHeight videoWidth volume".split(" "),qc=["loop","playbackRate"],$c=["pause","play"],Kc={getAssetUri:2,getAudioLanguages:4,getAudioLanguagesAndRoles:4,getBufferFullness:1,getBufferedInfo:2,getExpiration:2,getKeyStatuses:2,getPlaybackRate:2,getTextLanguages:4,getTextLanguagesAndRoles:4,getImageTracks:2,getThumbnails:2,isAudioOnly:10,isBuffering:1,isInProgress:1,isLive:10,isTextTrackVisible:1,keySystem:10,seekRange:1,getLoadMode:10,getManifestType:10,isFullyLoaded:1},Jc={getConfiguration:4,getStats:5,getTextTracks:2,getVariantTracks:2},Xc={getPlayheadTimeAsDate:1,getPresentationStartTimeAsDate:20,getSegmentAvailabilityDuration:20},Qc=[["getConfiguration","configure"]],Zc=[["isTextTrackVisible","setTextTrackVisibility"]],eh="addChaptersTrack addTextTrackAsync addThumbnailsTrack cancelTrickPlay configure getChapters getChaptersTracks resetConfiguration retryStreaming selectAudioLanguage selectTextLanguage selectTextTrack selectVariantTrack selectVariantsByLabel setTextTrackVisibility trickPlay updateStartTime goToLive".split(" "),th=["attach","attachCanvas","detach","load","unload"];function nh(e,t,n,i,r,a,s){var o=this;this.G=e,this.K=s,this.l=new He(t),this.L=n,this.s=!1,this.A=i,this.F=r,this.M=a,this.h=this.m=!1,this.I="",this.o=null,this.B=function(){return sh(o)},this.C=function(e,t){switch((e=zc(t)).type){case"event":var n=e.targetName,i=Xr(e.event);o.A(n,i);break;case"update":for(i in n=e.update)for(var r in e=o.g[i]||{},n[i])e[r]=n[i][r];o.s&&(o.L(),o.s=!1);break;case"asyncComplete":if(i=e.id,r=e.error,e=o.i[i],delete o.i[i],e)if(r){for(n in i=new Ye(r.severity,r.category,r.code),r)i[n]=r[n];e.reject(i)}else e.resolve()}},this.g={video:{},player:{}},this.H=0,this.i={},this.j=null,mh.add(this)}function ih(e,t){var n=e.M();ch=t,t.addUpdateListener(e.B),t.addMessageListener("urn:x-cast:com.google.shaka.v2",e.C),sh(e),uh(e,{type:"init",initState:n,appData:e.o}),e.j.resolve()}function rh(e,t){var n=8003;switch(t.code){case"cancel":n=8004;break;case"timeout":n=8005;break;case"receiver_unavailable":n=8006}e.j.reject(new Ye(2,8,n,t))}function ah(e){var t=ch;t.removeUpdateListener(e.B),t.removeMessageListener("urn:x-cast:com.google.shaka.v2",e.C)}function sh(e){var t=!!ch&&"connected"==ch.status;if(e.h&&!t){for(var n in e.F(),e.g)e.g[n]={};oh(e)}e.h=t,e.I=t?ch.receiver.friendlyName:"",e.l.hc()}function oh(e){for(var t in e.i){var n=e.i[t];delete e.i[t],n.reject(new Ye(1,7,7e3))}}function uh(e,t){t=Wc(t);var n=ch;try{n.sendMessage("urn:x-cast:com.google.shaka.v2",t,(function(){}),J)}catch(i){throw t=new Ye(2,8,8005,i),n=new Jr("error",(new Map).set("detail",t)),e.A("player",n),e.Lc(),t}}(i=nh.prototype).destroy=function(){return mh.delete(this),oh(this),ch&&ah(this),this.l&&(this.l.stop(),this.l=null),this.F=this.A=null,this.h=this.m=!1,this.C=this.B=this.j=this.i=this.g=this.o=null,Promise.resolve()},i.jb=function(){return this.h},i.Jf=function(){return this.I},i.init=function(){if(this.G.length)if(e.chrome&&chrome.cast&&chrome.cast.isAvailable){this.m=!0,this.l.hc();var t=new chrome.cast.SessionRequest(this.G,[],null,this.K,null);t=new chrome.cast.ApiConfig(t,(function(e){for(var t=d(mh),n=t.next();!n.done;n=t.next()){var i=e;(n=n.value).j=new Wr,n.s=!0,ih(n,i)}}),(function(e){for(var t=d(mh),n=t.next();!n.done;n=t.next())n=n.value,lh="available"==e,n.l.hc()}),"origin_scoped"),chrome.cast.initialize(t,(function(){}),(function(){})),lh&&this.l.$(dh),(t=ch)&&t.status!=chrome.cast.SessionStatus.STOPPED?(this.j=new Wr,this.s=!0,ih(this,t)):ch=null}else e.__onGCastApiAvailable!==fh&&(hh=e.__onGCastApiAvailable||null,e.__onGCastApiAvailable=fh)},i.Rf=function(e){this.o=e,this.h&&uh(this,{type:"appData",appData:this.o})},i.cast=function(){var e=this;return I((function(t){if(!e.m)throw new Ye(1,8,8e3);if(!lh)throw new Ye(1,8,8001);if(e.h)throw new Ye(1,8,8002);return e.j=new Wr,chrome.cast.requestSession((function(t){return ih(e,t)}),(function(t){return rh(e,t)})),M(t,e.j,0)}))},i.Lc=function(){if(this.h){if(oh(this),ch){ah(this);try{ch.stop((function(){}),(function(){}))}catch(e){}ch=null}sh(this)}},i.get=function(e,t){var n=this;if("video"==e){if($c.includes(t))return function(){return n.Xg.apply(n,[e,t].concat(l(P.apply(0,arguments))))}}else if("player"==e){if(Xc[t]&&!this.get("player","isLive")())return function(){};if(eh.includes(t))return function(){return n.Xg.apply(n,[e,t].concat(l(P.apply(0,arguments))))};if(th.includes(t))return function(){return n.Oi.apply(n,[e,t].concat(l(P.apply(0,arguments))))};if(Kc[t]||Jc[t])return function(){return n.g[e][t]}}return this.g[e][t]},i.set=function(e,t,n){this.g[e][t]=n,uh(this,{type:"set",targetName:e,property:t,value:n})},i.Xg=function(e,t){uh(this,{type:"call",targetName:e,methodName:t,args:P.apply(2,arguments)})},i.Oi=function(e,t){var n=P.apply(2,arguments),i=new Wr,r=this.H.toString();this.H++,this.i[r]=i;try{uh(this,{type:"asyncCall",targetName:e,methodName:t,args:n,id:r})}catch(e){i.reject(e)}return i};var dh=.02,lh=!1,ch=null,hh=null,mh=new Set;function fh(t){if(hh?e.__onGCastApiAvailable=hh:delete e.__onGCastApiAvailable,hh=null,t)for(var n=d(mh),i=n.next();!i.done;i=n.next())i.value.init();"function"==typeof e.__onGCastApiAvailable&&e.__onGCastApiAvailable(t)}function ph(e,t,n,i){i=void 0!==i&&i,Zr.call(this);var r=this;this.i=e,this.h=t,this.m=this.o=this.j=this.s=this.l=null,this.C=n,this.B=i,this.A=new Map,this.g=new nh(n,(function(){return _h(r)}),(function(){return vh(r)}),(function(e,t){return bh(r,e,t)}),(function(){return Mh(r)}),(function(){return yh(r)}),i),function(e){e.g.init(),e.m=new Z;for(var t=d(Vc),n=t.next();!n.done;n=t.next())e.m.D(e.i,n.value,(function(t){e.g.jb()||(t=Xr(t),e.j.dispatchEvent(t))}));for(var i in Qr)e.m.D(e.h,Qr[i],(function(t){e.g.jb()||e.o.dispatchEvent(t)}));for(var r in e.l={},t={},e.i)(t={pd:t.pd}).pd=r,Object.defineProperty(e.l,t.pd,{configurable:!1,enumerable:!0,get:function(t){return function(){return wh(e,t.pd)}}(t),set:function(t){return function(n){var i=t.pd;e.g.jb()?e.g.set("video",i,n):e.i[i]=n}}(t)});e.s={},gh(e,(function(t){Object.defineProperty(e.s,t,{configurable:!1,enumerable:!0,get:function(){return function(e,t){if(e.A.has(t)&&(t=e.A.get(t)),"addEventListener"==t)return function(t,n,i){return e.o.addEventListener(t,n,i)};if("removeEventListener"==t)return function(t,n,i){return e.o.removeEventListener(t,n,i)};if("getMediaElement"==t)return function(){return e.l};if("getSharedConfiguration"==t)return e.g.get("player","getConfiguration");if("getNetworkingEngine"==t)return function(){return e.h.Ab()};if("getDrmEngine"==t)return function(){return e.h.C};if("getAdManager"==t)return function(){return e.h.xg()};if("setVideoContainer"==t)return function(t){return e.h.kh(t)};if(e.g.jb()){if("getManifest"==t||"drmInfo"==t)return function(){return $(t+"() does not work while casting!"),null};if("attach"==t||"detach"==t)return function(){return $(t+"() does not work while casting!"),Promise.resolve()}}return e.g.jb()&&0==Object.keys(e.g.g.video).length&&(Kc[t]||Jc[t])||!e.g.jb()?e.h[t].bind(e.h):e.g.get("player",t)}(e,t)}})})),function(e){var t=new Map;gh(e,(function(n,i){t.has(i)?(i=t.get(i),n.length<i.length?e.A.set(n,i):e.A.set(i,n)):t.set(i,n)}))}(e),e.j=new Zr,e.j.re=e.l,e.o=new Zr,e.o.re=e.s}(this)}function gh(e,t){function n(e){return"constructor"!=e&&"function"==typeof r[e]&&!a.has(e)}var i,r=e.h,a=new Set;for(i in r)n(i)&&(a.add(i),t(i,r[i]));for(e=Object.getPrototypeOf(r),i=Object.getPrototypeOf({});e&&e!=i;){for(var s=d(Object.getOwnPropertyNames(e)),o=s.next();!o.done;o=s.next())n(o=o.value)&&(a.add(o),t(o,r[o]));e=Object.getPrototypeOf(e)}}function yh(e){var t={video:{},player:{},playerAfterLoad:{},manifest:e.h.Mc(),startTime:null};e.i.pause();for(var n=d(qc),i=n.next();!i.done;i=n.next())i=i.value,t.video[i]=e.i[i];for(e.i.ended||(t.startTime=e.i.currentTime),i=(n=d(Qc)).next();!i.done;i=n.next()){var r=i.value;i=r[1],r=e.h[r[0]](),t.player[i]=r}for(i=(n=d(Zc)).next();!i.done;i=n.next())i=(r=i.value)[1],r=e.h[r[0]](),t.playerAfterLoad[i]=r;return t}function _h(e){var t=new Jr("caststatuschanged");e.dispatchEvent(t)}function vh(e){var t=new Jr(e.l.paused?"pause":"play");e.j.dispatchEvent(t)}function Mh(e){for(var t=d(Qc),n=t.next();!n.done;n=t.next()){var i=n.value;n=i[1],i=e.g.get("player",i[0])(),e.h[n](i)}var r=e.g.get("player","getAssetUri")();i=e.g.get("video","ended"),t=Promise.resolve();var a,s=e.i.autoplay;n=null,i||(n=e.g.get("video","currentTime")),(i=e.g.get("player","getTextTracks")())&&i.length&&(a=i.find((function(e){return e.active})));var o=e.g.get("player","isTextTrackVisible")();r&&(e.i.autoplay=!1,t=e.h.load(r,n));var u={};for(i=(n=d(qc)).next();!i.done;i=n.next())i=i.value,u[i]=e.g.get("video",i);t.then((function(){if(e.i){for(var t=d(qc),n=t.next();!n.done;n=t.next())n=n.value,e.i[n]=u[n];for(n=(t=d(Zc)).next();!n.done;n=t.next()){var i=n.value;n=i[1],i=e.g.get("player",i[0])(),e.h[n](i)}e.h.hh(o),a&&e.h.Pf(a.language,a.roles,a.forced),e.i.autoplay=s,r&&e.i.play()}}),(function(t){t=new Jr("error",t=(new Map).set("detail",t)),e.h.dispatchEvent(t)}))}function wh(e,t){if("addEventListener"==t)return function(t,n,i){return e.j.addEventListener(t,n,i)};if("removeEventListener"==t)return function(t,n,i){return e.j.removeEventListener(t,n,i)};if(e.g.jb()&&0==Object.keys(e.g.g.video).length){var n=e.i[t];if("function"!=typeof n)return n}return e.g.jb()?e.g.get("video",t):("function"==typeof(t=e.i[t])&&(t=t.bind(e.i)),t)}function bh(e,t,n){e.g.jb()&&("video"==t?e.j.dispatchEvent(n):"player"==t&&e.o.dispatchEvent(n))}function Th(e,t,n,i){Zr.call(this);var r=this;this.g=e,this.h=t,this.j=new Z,this.H={video:e,player:t},this.F=n||function(){},this.I=i||function(e){return e},this.i=null,this.G=!1,this.o=!0,this.m=0,this.B=!1,this.A=!0,this.s=this.l=null,this.C=new He((function(){Dh(r)})),function(e){var t=cast.receiver.CastReceiverManager.getInstance();t.onSenderConnected=function(){return Lh(e)},t.onSenderDisconnected=function(){return Lh(e)},t.onSystemVolumeChanged=function(){var t=cast.receiver.CastReceiverManager.getInstance().getSystemVolume();t&&Eh(e,{type:"update",update:{video:{volume:t.level,muted:t.muted}}},e.l),Eh(e,{type:"event",targetName:"video",event:{type:"volumechange"}},e.l)},e.s=t.getCastMessageBus("urn:x-cast:com.google.cast.media"),e.s.onMessage=function(t){return function(e,t){var n=zc(t.data);switch(n.type){case"PLAY":e.g.play(),Ih(e);break;case"PAUSE":e.g.pause(),Ih(e);break;case"SEEK":t=n.currentTime;var i=n.resumeState;null!=t&&(e.g.currentTime=Number(t)),i&&"PLAYBACK_START"==i?(e.g.play(),Ih(e)):i&&"PLAYBACK_PAUSE"==i&&(e.g.pause(),Ih(e));break;case"STOP":e.h.ic().then((function(){e.h&&Ih(e)}));break;case"GET_STATUS":Ah(e,Number(n.requestId));break;case"VOLUME":t=(i=n.volume).level,i=i.muted;var r=e.g.volume,a=e.g.muted;null!=t&&(e.g.volume=Number(t)),null!=i&&(e.g.muted=i),r==e.g.volume&&a==e.g.muted||Ih(e);break;case"LOAD":e.m=0,e.B=!1,e.A=!1,t=n.media,i=n.currentTime,r=e.I(t.contentId),a=n.autoplay||!0,e.F(t.customData),a&&(e.g.autoplay=!0),e.h.load(r,i).then((function(){e.h&&Ah(e)})).catch((function(t){var i="LOAD_FAILED";7==t.category&&7e3==t.code&&(i="LOAD_CANCELLED"),Eh(e,{requestId:Number(n.requestId),type:i},e.s)}));break;default:Eh(e,{requestId:Number(n.requestId),type:"INVALID_REQUEST",reason:"INVALID_COMMAND"},e.s)}}(e,t)},e.l=t.getCastMessageBus("urn:x-cast:com.google.shaka.v2"),e.l.onMessage=function(t){return function(e,t){var n=zc(t.data);switch(n.type){case"init":e.m=0,e.B=!1,e.A=!0,function(e,t,n){var i,r,a,s,o,u,d,l,c,h;I((function(m){switch(m.g){case 1:for(i in t.player)r=t.player[i],e.h[i](r);return e.F(n),a=e.g.autoplay,t.manifest?(e.g.autoplay=!1,b(m,5),M(m,e.h.load(t.manifest,t.startTime),7)):M(m,Promise.resolve(),3);case 7:L(m,3);break;case 5:return s=S(m),o=(new Map).set("detail",s),u=new Jr("error",o),e.h&&e.h.dispatchEvent(u),m.return();case 3:if(!e.h)return m.return();for(d in t.video)l=t.video[d],e.g[d]=l;for(c in t.playerAfterLoad)h=t.playerAfterLoad[c],e.h[c](h);e.g.autoplay=a,t.manifest&&(e.g.play(),Ih(e)),w(m)}}))}(e,n.initState,n.appData),Dh(e);break;case"appData":e.F(n.appData);break;case"set":var i=n.targetName,r=n.property;if(n=n.value,"video"==i){if(t=cast.receiver.CastReceiverManager.getInstance(),"volume"==r){t.setSystemVolumeLevel(n);break}if("muted"==r){t.setSystemVolumeMuted(n);break}}e.H[i][r]=n;break;case"call":(i=e.H[n.targetName])[n.methodName].apply(i,n.args);break;case"asyncCall":i=n.targetName,r=n.methodName,"player"==i&&"load"==r&&(e.m=0,e.B=!1);var a=n.id,s=t.senderId;n=(t=e.H[i])[r].apply(t,n.args),"player"==i&&"load"==r&&(n=n.then((function(){e.A=!0}))),n.then((function(){return Yh(e,s,a,null)}),(function(t){return Yh(e,s,a,t)}))}}(e,t)},t.start();for(var n=(t=d(Vc)).next();!n.done;n=t.next())e.j.D(e.g,n.value,(function(t){return kh(e,"video",t)}));for(var i in Qr)e.j.D(e.h,Qr[i],(function(t){return kh(e,"player",t)}));e.j.D(e.g,"loadeddata",(function(){e.B=!0})),e.j.D(e.h,"loading",(function(){e.o=!1,Sh(e)})),e.j.D(e.g,"playing",(function(){e.o=!1,Sh(e)})),e.j.D(e.g,"pause",(function(){Sh(e)})),e.j.D(e.h,"unloading",(function(){e.o=!0,Sh(e)})),e.j.D(e.g,"ended",(function(){new He((function(){e.g&&e.g.ended&&(e.o=!0,Sh(e))})).$(Ch)}))}(this)}function Lh(e){e.m=0,e.A=!0,e.G=0!=cast.receiver.CastReceiverManager.getInstance().getSenders().length,Sh(e)}function Sh(e){var t;I((function(n){return 1==n.g?M(n,Promise.resolve(),2):e.h?(t=new Jr("caststatuschanged"),e.dispatchEvent(t),xh(e)||Ih(e),void w(n)):n.return()}))}function kh(e,t,n){e.h&&(Dh(e),Eh(e,{type:"event",targetName:t,event:n},e.l))}function Dh(e){e.C.$(Ph);for(var t={video:{},player:{}},n=d(Gc),i=n.next();!i.done;i=n.next())i=i.value,t.video[i]=e.g[i];if(e.h.U())for(var r in Xc)0==e.m%Xc[r]&&(t.player[r]=e.h[r]());for(var a in Kc)0==e.m%Kc[a]&&(t.player[a]=e.h[a]());for(var s in(n=cast.receiver.CastReceiverManager.getInstance().getSystemVolume())&&(t.video.volume=n.level,t.video.muted=n.muted),Eh(e,{type:"update",update:t},e.l),Jc)0==e.m%Jc[s]&&((t={player:{}}).player[s]=e.h[s](),Eh(e,{type:"update",update:t},e.l));e.B&&(e.m+=1),xh(e)}function xh(e){return!(!e.A||!e.g.duration&&!e.h.U()||(Ah(e),e.A=!1,0))}function Ah(e,t){var n={contentId:e.h.Mc(),streamType:e.h.U()?"LIVE":"BUFFERED",contentType:""};e.h.U()||(n.duration=e.g.duration),e.i&&(n.metadata=e.i),Ih(e,void 0===t?0:t,n)}function Yh(e,t,n,i){e.h&&Eh(e,{type:"asyncComplete",id:n,error:i},e.l,t)}function Eh(e,t,n,i){e.G&&(e=Wc(t),i?n.getCastChannel(i).send(e):n.broadcast(e))}function Ih(e,t,n){n=void 0===n?null:n;var i={mediaSessionId:0,playbackRate:e.g.playbackRate,playerState:e.o?jh:e.h.tf()?Rh:e.g.paused?Nh:Oh,currentTime:e.g.currentTime,supportedMediaCommands:63,volume:{level:e.g.volume,muted:e.g.muted}};n&&(i.media=n),Eh(e,{requestId:void 0===t?0:t,type:"MEDIA_STATUS",status:[i]},e.s)}g(ph,Zr),(i=ph.prototype).destroy=function(e){return e&&this.g.Lc(),this.m&&(this.m.release(),this.m=null),e=[],this.h&&(e.push(this.h.destroy()),this.h=null),this.g&&(e.push(this.g.destroy()),this.g=null),this.s=this.l=this.i=null,Zr.prototype.release.call(this),Promise.all(e)},i.ji=function(){return this.l},i.Zh=function(){return this.s},i.Dh=function(){return this.g.m&&lh},i.jb=function(){return this.g.jb()},i.Jf=function(){return this.g.Jf()},i.cast=function(){var e=this;return I((function(t){return 1==t.g?M(t,e.g.cast(),2):e.h?M(t,e.h.ic(),0):t.return()}))},i.Rf=function(e){this.g.Rf(e)},i.dj=function(){var e;(e=this.g).h&&chrome.cast.requestSession((function(t){return ih(e,t)}),(function(t){return rh(e,t)}))},i.Lc=function(){this.g.Lc()},i.Eh=function(e,t){t=void 0!==t&&t;var n=this;return I((function(i){if(1==i.g)return e==n.C&&t==n.B?i.return():(n.C=e,n.B=t,n.g.Lc(),M(i,n.g.destroy(),2));n.g=null,n.g=new nh(e,(function(){return _h(n)}),(function(){return vh(n)}),(function(e,t){return bh(n,e,t)}),(function(){return Mh(n)}),(function(){return yh(n)}),t),n.g.init(),w(i)}))},U("shaka.cast.CastProxy",ph),ph.prototype.changeReceiverId=ph.prototype.Eh,ph.prototype.forceDisconnect=ph.prototype.Lc,ph.prototype.suggestDisconnect=ph.prototype.dj,ph.prototype.setAppData=ph.prototype.Rf,ph.prototype.cast=ph.prototype.cast,ph.prototype.receiverName=ph.prototype.Jf,ph.prototype.isCasting=ph.prototype.jb,ph.prototype.canCast=ph.prototype.Dh,ph.prototype.getPlayer=ph.prototype.Zh,ph.prototype.getVideo=ph.prototype.ji,ph.prototype.destroy=ph.prototype.destroy,g(Th,Zr),(i=Th.prototype).isConnected=function(){return this.G},i.ri=function(){return this.o},i.$i=function(e){this.i=e},i.Gh=function(){this.i=null},i.aj=function(e){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC}),this.i.title=e},i.Zi=function(e){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC}),this.i.images=[{url:e}]},i.Yi=function(e){this.i||(this.i={}),this.i.artist=e,this.i.metadataType=cast.receiver.media.MetadataType.MUSIC_TRACK},i.destroy=function(){var e,t=this;return I((function(n){if(1==n.g)return t.j&&(t.j.release(),t.j=null),e=[],t.h&&(e.push(t.h.destroy()),t.h=null),t.C&&(t.C.stop(),t.C=null),t.g=null,t.H=null,t.F=null,t.G=!1,t.o=!0,t.l=null,t.s=null,Zr.prototype.release.call(t),M(n,Promise.all(e),2);cast.receiver.CastReceiverManager.getInstance().stop(),w(n)}))},U("shaka.cast.CastReceiver",Th),Th.prototype.destroy=Th.prototype.destroy,Th.prototype.setContentArtist=Th.prototype.Yi,Th.prototype.setContentImage=Th.prototype.Zi,Th.prototype.setContentTitle=Th.prototype.aj,Th.prototype.clearContentMetadata=Th.prototype.Gh,Th.prototype.setContentMetadata=Th.prototype.$i,Th.prototype.isIdle=Th.prototype.ri,Th.prototype.isConnected=Th.prototype.isConnected;var Ph=.5,Ch=5,jh="IDLE",Oh="PLAYING",Rh="BUFFERING",Nh="PAUSED";function Hh(e,t,n,i,r){if(i>=r)return null;for(var a=-1,s=-1,o=0;o<n.length;o++)if(n[o].some((function(e){return null!=e&&""!=e.g.trim()}))){a=o;break}for(o=n.length-1;0<=o;o--)if(n[o].some((function(e){return null!=e&&""!=e.g.trim()}))){s=o;break}if(-1===a||-1===s)return null;for(var u=o=!1,d="white",l="black",c=Uh(i,r,o,u,d,l);a<=s;a++){for(var h=n[a],m=-1,f=-1,p=0;p<h.length;p++)if(null!=h[p]&&""!==h[p].g.trim()){m=p;break}for(p=h.length-1;0<=p;p--)if(null!=h[p]&&""!==h[p].g.trim()){f=p;break}if(-1===m||-1===f)h=Fh(i,r),e.nestedCues.push(h);else{for(;m<=f;m++)if(p=h[m]){var g=p.l,y=p.i,_=p.j,v=p.h;g==o&&y==u&&_==d&&v==l||(c.payload&&e.nestedCues.push(c),c=Uh(i,r,g,y,_,v),o=g,u=y,d=_,l=v),c.payload+=p.g}else c.payload+=" ";c.payload&&e.nestedCues.push(c),a!==s&&(c=Fh(i,r),e.nestedCues.push(c)),c=Uh(i,r,o,u,d,l)}}return e.nestedCues.length?{cue:e,stream:t}:null}function Uh(e,t,n,i,r,a){return e=new un(e,t,""),n&&e.textDecoration.push(In),i&&(e.fontStyle=Yn),e.color=r,e.backgroundColor=a,e}function Fh(e,t){return(e=new un(e,t,"")).lineBreak=!0,e}function Bh(e,t,n,i,r){this.g=e,this.l=t,this.i=n,this.h=i,this.j=r}function Wh(e,t){this.i=[],this.g=1,this.h=0,this.C=e,this.B=t,this.j=this.m=!1,this.l="white",this.o="black",this.s=this.A=null,Vh(this)}function zh(e,t,n){var i="CC"+(1+(e.C<<1|e.B)),r=new un(t,n,"");r.lineInterpretation=1;var a=Zh.get(e.g);return a&&(r.line=a),null!=e.s&&null!=e.A&&(r.position=10+Math.min(70,10*e.s)+2.5*e.A),(t=Hh(r,i,e.i,t,n))&&15<e.g+t.cue.nestedCues.length-3&&(a=Zh.get(e.g+3-t.cue.nestedCues.length))&&(r.line=a),t}function Vh(e){$h(e,0,15),e.g=1}function Gh(e,t,n){if(!(32>n||127<n)){var i="";switch(t){case 0:i=Kh.has(n)?Kh.get(n):String.fromCharCode(n);break;case 1:i=Jh.get(n);break;case 2:e.i[e.g].pop(),i=Xh.get(n);break;case 3:e.i[e.g].pop(),i=Qh.get(n)}i&&e.i[e.g].push(new Bh(i,e.m,e.j,e.o,e.l))}}function qh(e,t,n,i){if(!(0>n||0>t))if(t>=n)for(--i;0<=i;i--)e.i[t+i]=e.i[n+i].map((function(e){return e}));else for(var r=0;r<i;r++)e.i[t+r]=e.i[n+r].map((function(e){return e}))}function $h(e,t,n){for(var i=0;i<=n;i++)e.i[t+i]=[]}var Kh=new Map([[39,"’"],[42,"á"],[92,"é"],[92,"é"],[94,"í"],[95,"ó"],[96,"ú"],[123,"ç"],[124,"÷"],[125,"Ñ"],[126,"ñ"],[127,"█"]]),Jh=new Map([[48,"®"],[49,"°"],[50,"½"],[51,"¿"],[52,"™"],[53,"¢"],[54,"£"],[55,"♪"],[56,"à"],[57," "],[58,"è"],[59,"â"],[60,"ê"],[61,"î"],[62,"ô"],[63,"û"]]),Xh=new Map([[32,"Á"],[33,"É"],[34,"Ó"],[35,"Ú"],[36,"Ü"],[37,"ü"],[38,"‘"],[39,"¡"],[40,"*"],[41,"'"],[42,"─"],[43,"©"],[44,"℠"],[45,"·"],[46,"“"],[47,"”"],[48,"À"],[49,"Â"],[50,"Ç"],[51,"È"],[52,"Ê"],[53,"Ë"],[54,"ë"],[55,"Î"],[56,"Ï"],[57,"ï"],[58,"Ô"],[59,"Ù"],[60,"ù"],[61,"Û"],[62,"«"],[63,"»"]]),Qh=new Map([[32,"Ã"],[33,"ã"],[34,"Í"],[35,"Ì"],[36,"ì"],[37,"Ò"],[38,"ò"],[39,"Õ"],[40,"õ"],[41,"{"],[42,"}"],[43,"\\"],[44,"^"],[45,"_"],[46,"|"],[47,"~"],[48,"Ä"],[49,"ä"],[50,"Ö"],[51,"ö"],[52,"ß"],[53,"¥"],[54,"¤"],[55,"│"],[56,"Å"],[57,"å"],[58,"Ø"],[59,"ø"],[60,"┌"],[61,"┐"],[62,"└"],[63,"┘"]]),Zh=new Map([[1,10],[2,15.33],[3,20.66],[4,26],[5,31.33],[6,36.66],[7,42],[8,47.33],[9,52.66],[10,58],[11,63.33],[12,68.66],[13,74],[14,79.33],[15,84.66]]);function em(e,t){this.h=0,this.o=new Wh(e,t),this.i=new Wh(e,t),this.g=this.j=new Wh(e,t),this.l=0,this.m=null}function tm(e,t,n){e.g=e.i;var i=e.g,r=null;return 3!==e.h&&4!==e.h&&(r=zh(i,e.l,n),(n=e.i).g=0<n.h?n.h:0,$h(n,0,15),(n=e.j).g=0<n.h?n.h:0,$h(n,0,15),i.g=15),e.h=3,i.h=t,r}function nm(e){e.h=1,e.g=e.j,e.g.h=0}function im(e){K("Cea608DataChannel","CEA-608 text mode entered, but is unsupported"),e.g=e.o,e.h=4}var rm="black green blue cyan red yellow magenta black".split(" "),am="white green blue cyan red yellow magenta white_italics".split(" ");function sm(e,t){this.I=t,this.M=e,this.K=this.l=!1,this.m=this.o=this.G=this.L=this.H=0,this.F=2,this.i=[],this.g=this.h=this.j=0,this.C=this.A=!1,this.B="white",this.s="black",om(this)}function om(e){e.i=[];for(var t=0;16>t;t++)e.i.push(um())}function um(){for(var e=[],t=0;42>t;t++)e.push(null);return e}function dm(e,t){lm(e)&&(e.i[e.h][e.g]=new Bh(t,e.C,e.A,e.s,e.B),e.g++)}function lm(e){var t=e.g<e.m&&0<=e.g;return e.h<e.o&&0<=e.h&&t}function cm(e,t,n){var i=new un(e.j,t,"");i.textAlign=0===e.F?"left":1===e.F?"right":gn;var r=i.region;switch(e.I&&(r.id+="svc"+e.I),r.id+="win"+e.M,r.height=e.o,r.width=e.m,r.heightUnits=2,r.widthUnits=2,r.viewportAnchorX=e.H,r.viewportAnchorY=e.L,r.viewportAnchorUnits=e.K?Le:2,e.G){case 0:r.regionAnchorX=0,r.regionAnchorY=0;break;case 1:r.regionAnchorX=50,r.regionAnchorY=0;break;case 2:r.regionAnchorX=100,r.regionAnchorY=0;break;case 3:r.regionAnchorX=0,r.regionAnchorY=50;break;case 4:r.regionAnchorX=50,r.regionAnchorY=50;break;case 5:r.regionAnchorX=100,r.regionAnchorY=50;break;case 6:r.regionAnchorX=0,r.regionAnchorY=100;break;case 7:r.regionAnchorX=50,r.regionAnchorY=100;break;case 8:r.regionAnchorX=100,r.regionAnchorY=100}return(n=Hh(i,"svc"+n,e.i,e.j,t))&&(e.j=t),n}function hm(){this.i=[],this.h=null,this.g=0}function mm(e,t){3===t.type?(e.g=2*(63&t.value)-1,e.h=[]):e.h&&(0<e.g&&(e.h.push(t),e.g--),0===e.g&&(e.i.push(new fm(e.h)),e.h=null,e.g=0))}function fm(e){this.g=0,this.h=e}function pm(e){if(!e.sa())throw new Ye(2,2,3e3);return e.h[e.g++]}function gm(e){this.i=e,this.h=[null,null,null,null,null,null,null,null],this.g=null}function ym(e,t,n,i){if(128<=n&&135>=n)i=7&n,e.h[i]&&(e.g=e.h[i]);else{if(136===n){n=pm(t).value,t=null;for(var r=(n=d(_m(e,n))).next();!r.done;r=n.next())(r=e.h[r.value]).isVisible()&&(t=cm(r,i,e.i)),om(r);return t}if(137===n)for(n=(t=d(_m(e,t=pm(t).value))).next();!n.done;n=t.next())(n=e.h[n.value]).isVisible()||(n.j=i),n.display();else{if(138===n){for(n=pm(t).value,t=null,r=(n=d(_m(e,n))).next();!r.done;r=n.next())(r=e.h[r.value]).isVisible()&&(t=cm(r,i,e.i)),r.l=!1;return t}if(139===n){for(n=pm(t).value,t=null,r=(n=d(_m(e,n))).next();!r.done;r=n.next())(r=e.h[r.value]).isVisible()?t=cm(r,i,e.i):r.j=i,r.l=!r.l;return t}if(140===n)return vm(e,t=pm(t).value,i);if(143===n)return i=vm(e,255,i),Mm(e),i;if(144===n)t.skip(1),i=pm(t).value,e.g&&(e.g.A=0<(128&i),e.g.C=0<(64&i));else if(145===n)i=pm(t).value,n=pm(t).value,t.skip(1),e.g&&(t=wm((48&n)>>4,(12&n)>>2,3&n),e.g.B=wm((48&i)>>4,(12&i)>>2,3&i),e.g.s=t);else if(146===n)i=pm(t).value,t=pm(t).value,e.g&&((e=e.g).h=15&i,e.g=63&t);else if(151===n)t.skip(1),t.skip(1),i=pm(t).value,t.skip(1),e.g&&(e.g.F=3&i);else if(152<=n&&159>=n){if(n=(15&n)-8,!(r=null!==e.h[n])){var a=new sm(n,e.i);a.j=i,e.h[n]=a}i=pm(t).value,a=pm(t).value;var s=pm(t).value,o=pm(t).value,u=pm(t).value;t=pm(t).value,r&&!(7&t)||((t=e.h[n]).h=0,t.g=0,t.C=!1,t.A=!1,t.B="white",t.s="black"),(t=e.h[n]).l=0<(32&i),t.L=127&a,t.H=s,t.G=(240&o)>>4,t.K=0<(128&a),t.o=1+(15&o),t.m=1+(63&u),e.g=e.h[n]}}}return null}function _m(e,t){for(var n=[],i=0;8>i;i++)!(1&~t)&&e.h[i]&&n.push(i),t>>=1;return n}function vm(e,t,n){for(var i=null,r=(t=d(_m(e,t))).next();!r.done;r=t.next()){r=r.value;var a=e.h[r];a.isVisible()&&(i=cm(a,n,e.i)),e.h[r]=null}return i}function Mm(e){e.g=null,e.h=[null,null,null,null,null,null,null,null]}function wm(e,t,n){var i={0:0,1:0,2:1,3:1};return Tm[(e=i[e])<<2|(t=i[t])<<1|(n=i[n])]}sm.prototype.isVisible=function(){return this.l},sm.prototype.display=function(){this.l=!0},fm.prototype.sa=function(){return this.g<this.h.length},fm.prototype.ya=function(){return this.g},fm.prototype.skip=function(e){if(this.g+e>this.h.length)throw new Ye(2,2,3e3);this.g+=e};var bm=new Map([[32," "],[33," "],[37,"…"],[42,"Š"],[44,"Œ"],[48,"█"],[49,"‘"],[50,"’"],[51,"“"],[52,"”"],[53,"•"],[57,"™"],[58,"š"],[60,"œ"],[61,"℠"],[63,"Ÿ"],[118,"⅛"],[119,"⅜"],[120,"⅝"],[121,"⅞"],[122,"│"],[123,"┐"],[124,"└"],[125,"─"],[126,"┘"],[127,"┌"]]),Tm="black blue green cyan red magenta yellow white".split(" ");function Lm(){this.h=[],this.g=[],this.i=new hm,this.l=0,this.m=new Map([["CC1",new em(0,0)],["CC2",new em(0,1)],["CC3",new em(1,0)],["CC4",new em(1,1)]]),this.s=this.o=0,this.j=new Map,this.B=!0,this.A=new Set,Sm(this)}function Sm(e){e.o=0,e.s=0;for(var t=d(e.m.values()),n=t.next();!n.done;n=t.next())(n=n.value).h=0,n.g=n.j,n.m=null,Vh(n.i),Vh(n.j),Vh(n.o);e.B=!0}function km(e,t){var n=t.type;if(16==(112&t.gb)){var i=t.gb>>3&1;0===n?e.o=i:e.s=i}if(i="CC"+(1+(n<<1|(n?e.s:e.o))),n=e.m.get(i),255===t.gb&&255===t.Eb||!t.gb&&!t.Eb||!xm(t.gb)||!xm(t.Eb))return 45<=++e.l&&Sm(e),null;e.l=0,t.gb&=127,t.Eb&=127;var r=t.gb;if(1<=r&&15>=r||!t.gb&&!t.Eb)return null;if(r=null,16==(112&t.gb))e:{if(e.A.add(i),i=t.gb,e=t.Eb,n.m===(i<<8|e))n.m=null;else if(n.m=i<<8|e,16==(240&i)&&64==(192&e)){t=[11,11,1,2,3,4,12,13,14,15,5,6,7,8,9,10][(7&i)<<1|e>>5&1],i="white",r=!1;var a=null,s=95<e?e-96:e-64;13>=s?i=am[Math.floor(s/2)]:15>=s?r=!0:a=Math.floor((s-16)/2),e=!(1&~e),4!==n.h&&(s=n.g,3===n.h&&t!==s.g&&(qh(s,n=1+t-s.h,1+s.g-s.h,s.h),$h(s,0,n-1),$h(s,t+1,15-t)),s.g=t,s.m=e,s.j=r,s.l=i,s.s=a,s.o="black")}else if(17==(247&i)&&32==(240&e))n.g.m=!1,n.g.j=!1,n.g.l="white",Gh(n.g,0,32),i=!1,"white_italics"===(t=am[(14&e)>>1])&&(t="white",i=!0),n.g.m=!(1&~e),n.g.j=i,n.g.l=t;else if(16==(247&i)&&32==(240&e)||23==(247&i)&&45==(255&e))t="black",!(7&i)&&(t=rm[(14&e)>>1]),n.g.o=t;else if(17==(247&i)&&48==(240&e))Gh(n.g,1,e);else if(18==(246&i)&&32==(224&e))Gh(n.g,1&i?3:2,e);else{if(20==(246&i)&&32==(240&e)){switch(e=t.pts,i=null,t.Eb){case 32:nm(n);break;case 33:(n=n.g).i[n.g].pop();break;case 37:i=tm(n,2,e);break;case 38:i=tm(n,3,e);break;case 39:i=tm(n,4,e);break;case 40:Gh(n.g,0,32);break;case 41:n.h=2,n.g=n.i,n.g.h=0,n.l=e;break;case 42:Vh(n.o),im(n);break;case 43:im(n);break;case 44:t=n.i,i=null,4!==n.h&&(i=zh(t,n.l,e)),$h(t,0,15);break;case 45:t=n.g,3!==n.h?i=null:(i=zh(t,n.l,e),qh(t,(r=t.g-t.h+1)-1,r,t.h),$h(t,0,r-1),$h(t,t.g,15-t.g),n.l=e);break;case 46:$h(n.j,0,15);break;case 47:t=null,4!==n.h&&(t=zh(n.i,n.l,e)),i=n.j,n.j=n.i,n.i=i,nm(n),n.l=e,i=t}r=i;break e}(23==i||31==i)&&33<=e&&35>=e&&(n.g.A=e-32)}r=null}else e=t.Eb,Gh(n.g,0,t.gb),Gh(n.g,0,e);return r}function Dm(e,t){var n=[];try{for(;t.sa();){var i=pm(t).value,r=(224&i)>>5,a=31&i;if(7===r&&0!=a&&(r=63&pm(t).value),0!=r){e.A.add("svc"+r),e.j.has(r)||e.j.set(r,new gm(r));for(var s=e.j.get(r),o=t.ya();t.ya()-o<a;){r=s;var u=t,d=pm(u),l=d.value,c=d.pts;if(16===l&&(l=l<<16|pm(u).value),0<=l&&31>=l){var h=l,m=c;if((u=r).g){var f=u.g;switch(r=null,h){case 8:!lm(f)||0>=f.g&&0>=f.h||(0>=f.g?(f.g=f.m-1,f.h--):f.g--,f.i[f.h][f.g]=null);break;case 13:if(f.isVisible()&&(r=cm(f,m,u.i)),f.h+1>=f.o){for(u=f,h=0,m=1;16>m;m++,h++)u.i[h]=u.i[m];for(m=0;1>m;m++,h++)u.i[h]=um()}else f.h++;f.g=0;break;case 14:f.isVisible()&&(r=cm(f,m,u.i)),f.i[f.h]=um(),f.g=0;break;case 12:f.isVisible()&&(r=cm(f,m,u.i)),om(f),(u=f).h=0,u.g=0}var p=r}else p=null}else if(128<=l&&159>=l)p=ym(r,u,l,c);else{if(4096<=l&&4127>=l)r=u,8<=(u=255&l)&&15>=u?r.skip(1):16<=u&&23>=u?r.skip(2):24<=u&&31>=u&&r.skip(3);else if(4224<=l&&4255>=l)r=u,128<=(u=255&l)&&135>=u?r.skip(4):136<=u&&143>=u&&r.skip(5);else if(32<=l&&127>=l)u=l,r.g&&dm(r.g,127===u?"♪":String.fromCharCode(u));else if(160<=l&&255>=l)r.g&&dm(r.g,String.fromCharCode(l));else if(4128<=l&&4223>=l){if(u=255&l,r.g)if(bm.has(u)){var g=bm.get(u);dm(r.g,g)}else dm(r.g,"_")}else 4256<=l&&4351>=l&&r.g&&dm(r.g,160!=(255&l)?"_":"[CC]");p=null}(r=p)&&n.push(r)}}}}catch(e){if(!(e instanceof Ye&&3e3===e.code))throw e;K("CEA708_INVALID_DATA","Buffer read out of bounds / invalid CEA-708 Data.")}return n}function xm(e){for(var t=0;e;)t^=1&e,e>>=1;return 1===t}function Am(e){for(var t=[],n=e,i=e=0;i<n.length;)2==e&&3==n[i]?(e=0,(n=[].concat(l(n))).splice(i,1),n=new Uint8Array(n)):0==n[i]?e++:e=0,i++;for(e=n,i=0;i<e.length;){for(n=0;255==e[i];)n+=255,i++;n+=e[i++];for(var r=0;255==e[i];)r+=255,i++;r+=e[i++],4==n&&t.push(e.subarray(i,i+r)),i+=r}return t}function Ym(){this.j=new Map,this.i=this.h=0,this.g=Im}function Em(e,t,n,i,r,a,s,o,u){var c=0,h=a,m=o.map((function(e){return e.Zg}));for((m=[].concat.apply([],l(m))).length&&(h=m[0].sampleSize||a),t.skip(s+o[0].Ih);t.sa();){s=t.P();var f=t.T(),p=null;switch(p=!1,o=1,e.g){case Pm:p=6==(p=31&f);break;case Cm:o=2,t.skip(1),p=39==(p=f>>1&63)||40==p;break;case jm:o=2,t.skip(1),p=23==(p=f>>1&63)||24==p;break;default:return}if(p)for(f=0,c<m.length&&(f=m[c].me||0),f=(n+f)/i,p=(o=d(Am(t.vb(s-o)))).next();!p.done;p=o.next())u.push({packet:p.value,pts:f});else try{t.skip(s-o)}catch(e){break}0==(h-=s+4)&&(n=c<m.length?n+(m[c].Of||r):n+r,h=++c<m.length&&m[c].sampleSize||a)}}Lm.prototype.clear=function(){this.l=0,this.h=[],this.g=[];var e=this.i;e.i=[],e.h=[],e.g=0,Sm(this);for(var t=(e=d(this.j.values())).next();!t.done;t=e.next())Mm(t.value)},Lm.prototype.extract=function(e,t){if(this.B){for(var n=d(this.m.values()),i=n.next();!i.done;i=n.next())i.value.l=t;this.B=!1}if(!(8>(e=new _a(e,0)).getLength())&&181===e.T()&&49===e.ma()&&1195456820===e.P()&&3===e.T()&&64&(n=e.T()))for(n&=31,e.skip(1),i=0;i<n;i++){var r=e.T(),a=(4&r)>>2,s=e.T(),o=e.T();a&&(0==(r&=3)||1===r?this.h.push({pts:t,type:r,gb:s,Eb:o,order:this.h.length}):(this.g.push({pts:t,type:r,value:s,order:this.g.length}),this.g.push({pts:t,type:2,value:o,order:this.g.length})))}},Lm.prototype.decode=function(){function e(e,t){return e.pts-t.pts||e.order-t.order}var t=[];this.h.sort(e),this.g.sort(e);for(var n=d(this.h),i=n.next();!i.done;i=n.next())(i=km(this,i.value))&&t.push(i);for(i=(n=d(this.g)).next();!i.done;i=n.next())mm(this.i,i.value);for(i=(n=d(this.i.i)).next();!i.done;i=n.next())i=Dm(this,i.value),t.push.apply(t,l(i));return this.i.i=[],this.h=[],this.g=[],t},Lm.prototype.getStreams=function(){return Array.from(this.A)},U("shaka.cea.CeaDecoder",Lm),be=function(){return new Lm},Ym.prototype.init=function(e){function t(e){(e=e.name)in Om&&(n.g=Om[e])}var n=this,i=[],r=[];if((new wa).box("moov",ba).box("mvex",ba).R("trex",(function(e){var t=e.reader;t.skip(4),t.skip(4),e=t.P(),t=t.P(),n.h=e,n.i=t})).box("trak",ba).R("tkhd",(function(e){var t=e.reader;1==(e=e.version)?(t.skip(8),t.skip(8)):(t.skip(4),t.skip(4));var n=t.P();1==e?t.skip(8):t.skip(4),t.skip(4),t.skip(8),t.skip(2),t.skip(2),t.skip(2),t.skip(2),t.skip(36),t.ma(),t.ma(),t.ma(),t.ma(),i.push(n)})).box("mdia",ba).R("mdhd",(function(e){e=Rs(e.reader,e.version),r.push(e.timescale)})).box("minf",ba).box("stbl",ba).R("stsd",Ta).box("avc1",t).box("avc3",t).box("dvav",t).box("dva1",t).box("hev1",t).box("hvc1",t).box("dvh1",t).box("dvhe",t).box("vvc1",t).box("vvi1",t).box("dvc1",t).box("dvi1",t).box("encv",La).box("sinf",ba).box("frma",(function(e){(e=Us(e.reader).codec)in Om&&(n.g=Om[e])})).parse(e,!0),!i.length||!r.length||i.length!=r.length)throw new Ye(2,2,2010);this.g==Im&&$("Unable to determine bitstream format for CEA parsing!"),i.forEach((function(e,t){n.j.set(e,r[t])}))},Ym.prototype.parse=function(e){var t=this;if(this.g==Im)return[];var n=[],i=0,r=[];return(new wa).box("moof",(function(e){i=e.start,r=[],ba(e)})).box("traf",(function(e){r.push({baseMediaDecodeTime:null,ed:t.h,Ld:t.i,Sg:[],timescale:9e4}),ba(e)})).R("trun",(function(e){var t=r[r.length-1];e=Ns(e.reader,e.version,e.flags),t.Sg.push(e)})).R("tfhd",(function(e){var n=r[r.length-1];e=js(e.reader,e.flags),n.ed=e.ed||t.h,n.Ld=e.Ld||t.i,e=e.trackId,t.j.has(e)&&(n.timescale=t.j.get(e))})).R("tfdt",(function(e){var t=r[r.length-1];e=Os(e.reader,e.version),t.baseMediaDecodeTime=e.baseMediaDecodeTime})).box("mdat",(function(e){for(var a=i-e.start-8,s=e.reader.ya(),o=d(r),u=o.next();!u.done;u=o.next()){if(null===(u=u.value).baseMediaDecodeTime)throw $("Unable to find base media decode time for CEA captions!"),new Ye(2,2,2010);e.reader.seek(s),Em(t,e.reader,u.baseMediaDecodeTime,u.timescale,u.ed,u.Ld,a,u.Sg,n)}})).parse(e,!1),n},U("shaka.cea.Mp4CeaParser",Ym);var Im=0,Pm=1,Cm=2,jm=3,Om={avc1:Pm,avc3:Pm,dvav:Pm,dva1:Pm,hev1:Cm,hvc1:Cm,dvh1:Cm,dvhe:Cm,vvc1:jm,vvi1:jm,dvc1:jm,dvi1:jm};function Rm(){this.g=null}function Nm(t,n,i){var r=function(e){for(var t=[],n=(e=d(e)).next();!n.done;n=e.next())(n=Um(n.value))&&t.push(n);return t}(t),a=null;t=[];var s=[],o=null,u=new Set(r.map((function(e){return e.keyId})));u.delete(null);var l="cenc";if(1<u.size)throw new Ye(2,4,4010);if(!n){if(1<(s=r.filter((function(e){return"urn:mpeg:dash:sea:2012"==e.Wc}))).length)throw new Ye(2,4,4050);s.length&&(o=function(t){if(!e.crypto||!e.crypto.subtle)throw $("Web Crypto API is not available to decrypt AES-128. (Web Crypto only exists in secure origins like https)"),new Ye(2,4,4042);var n=Ht(t.node,"urn:mpeg:dash:schema:sea:2012","SegmentEncryption");if(!n)throw new Ye(2,4,4051);if("urn:mpeg:dash:sea:aes128-cbc:2013"!=n.attributes.schemeIdUri)throw new Ye(2,4,4051);if(!(n=Ht(t.node,"urn:mpeg:dash:schema:sea:2012","CryptoPeriod")))throw new Ye(2,4,4051);if(t=n.attributes.IV,n=yt(n.attributes.keyUriTemplate),!t||!n)throw new Ye(2,4,4051);if(16!=(t=di(t.substr(2))).byteLength)throw new Ye(2,4,4048);return{wi:n,iv:t}}(s[0])),(s=r.find((function(e){return"urn:mpeg:dash:mp4protection:2011"==e.Wc})))&&s.encryptionScheme&&(l=s.encryptionScheme),(s=r.filter((function(e){return"urn:mpeg:dash:mp4protection:2011"==e.Wc?(a=e.init||a,!1):"urn:mpeg:dash:sea:2012"!=e.Wc}))).length&&(t=function(e,t,n,i,r){for(var a=[],s=(n=d(n)).next();!s.done;s=n.next()){var o=i[(s=s.value).Wc];if(o){var u;if((u=Ht(s.node,"urn:microsoft:playready","pro"))&&jt(u)){u=ui(u=jt(u));var l=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);u=[{initData:Pa(u,l,new Set,0),initDataType:"cenc",keyId:s.keyId}]}else u=null;if(l=null,"urn:uuid:e2719d58-a985-b3c9-781a-b030af78d30e"===s.Wc){l=s;var c=r;if(0==c.size)l=null;else{var h=new Uint8Array([16,119,239,236,192,178,77,2,172,227,60,30,82,226,251,75]);l=[{initData:Pa(new Uint8Array([]),h,c,1),initDataType:"cenc",keyId:l.keyId}]}}u=mi(o,t,s.init||e||u||l),(o=Bm.get(o))&&(u.licenseServerUri=o(s)),a.push(u)}}return a}(a,l,s,i,u),0==t.length&&(t=[mi("",l,a)]))}if(r.length&&!o&&(n||!s.length))for(t=[],i=(n=d(Object.values(i))).next();!i.done;i=n.next())"org.w3.clearkey"!=(i=i.value)&&t.push(mi(i,l,a));if(u=Array.from(u)[0]||null)for(n=(l=d(t)).next();!n.done;n=l.next())for(i=(n=d(n.value.initData)).next();!i.done;i=n.next())i.value.keyId=u;return{rg:u,kk:a,drmInfos:t,Je:o,wg:!0}}function Hm(e){var t=Ht(e.node,"https://dashif.org/CPS","Laurl");return t&&(t=jt(t))?t:(e=Ht(e.node,"urn:microsoft:playready","pro"))&&jt(e)?(e=function(e){var t=0,n=ye(e),i=n.getUint32(t,!0);if(i!=e.byteLength)return[];e:{for(e=t+6,t=[];e<n.byteLength-1;){i=n.getUint16(e,!0),e+=2;var r=n.getUint16(e,!0);if(e+=2,1&r||r+e>n.byteLength){n=[];break e}var a=pe(n,e,r);t.push({type:i,value:a}),e+=r}n=t}return n}(e=ui(e=jt(e))).filter((function(e){return e.type===Fm}))[0],e&&(e=Yt(e=ht(e.value,!0),"WRMHEADER"))?function(e){for(var t=(e=d(Rt(e,"DATA"))).next();!t.done;t=e.next())if((t=t.value).children)for(var n=(t=d(t.children)).next();!n.done;n=t.next())if("LA_URL"==(n=n.value).tagName)return jt(n);return""}(e):""):""}function Um(e){var t=e.attributes.schemeIdUri,n=Ft(e,"urn:mpeg:cenc:2013","default_KID"),i=Bt(e,"urn:mpeg:cenc:2013","pssh").map(Ot),r=e.attributes.value;if(!t)return null;if(t=t.toLowerCase(),n&&(n=n.replace(/-/g,"").toLowerCase()).includes(" "))throw new Ye(2,4,4009);var a=[];try{a=i.map((function(e){return{initDataType:"cenc",initData:ui(e),keyId:null}}))}catch(e){throw new Ye(2,4,4007)}return{node:e,Wc:t,keyId:n,init:0<a.length?a:null,encryptionScheme:r}}we["video/mp4"]=function(){return new Ym},Rm.prototype.init=function(){},Rm.prototype.parse=function(e){this.g?this.g.clearData():this.g=new to;var t=[];if(!ao(e=pe(e)))return t;var n=(e=this.g.parse(e)).fd(),i=e.Rd();switch(e=[],n.video){case"avc":e.push(6);break;case"hvc":e.push(39),e.push(40)}if(!e.length)return t;for(i=(n=d(i)).next();!i.done;i=n.next())if(i=i.value,e.includes(i.type)&&null!=i.time)for(var r=d(Am(i.data)),a=r.next();!a.done;a=r.next())t.push({packet:a.value,pts:i.time});return t},U("shaka.cea.TsCeaParser",Rm),we["video/mp2t"]=function(){return new Rm};var Fm=1,Bm=(new Map).set("com.apple.fps",(function(e){if(st())throw new Ye(2,4,4054);return(e=Ht(e.node,"https://dashif.org/CPS","Laurl"))&&(e=jt(e))?e:""})).set("com.widevine.alpha",(function(e){var t=Ht(e.node,"https://dashif.org/CPS","Laurl");return t&&(t=jt(t))?t:(e=Ht(e.node,"urn:microsoft","laurl"))&&yt(e.attributes.licenseUrl)||""})).set("com.microsoft.playready",Hm).set("com.microsoft.playready.recommendation",Hm).set("com.microsoft.playready.software",Hm).set("com.microsoft.playready.hardware",Hm).set("org.w3.clearkey",(function(e){var t=Ht(e.node,"https://dashif.org/CPS","Laurl");return t&&(t=jt(t))?t:(e=Ht(e.node,"http://dashif.org/guidelines/clearKey","Laurl"))&&"EME-1.0"===e.attributes.Lic_type&&e&&(e=jt(e))?e:""}));function Wm(t,n,i,r,a,s){var o={RepresentationID:n,Number:i,SubNumber:r,Bandwidth:a,Time:s};return t.replace(/\$(RepresentationID|Number|SubNumber|Bandwidth|Time)?(?:%0([0-9]+)([diouxX]))?\$/g,(function(t,n,i,r){if("$$"==t)return"$";var a=o[n];if(null==a)return t;switch("RepresentationID"==n&&i&&(i=void 0),"Time"==n&&"bigint"!=typeof a&&(.2<=Math.abs(a-Math.round(a))&&$("Calculated $Time$ values must be close to integers"),a=Math.round(a)),r){case void 0:case"d":case"i":case"u":t=a.toString();break;case"o":t=a.toString(8);break;case"x":t=a.toString(16);break;case"X":t=a.toString(16).toUpperCase();break;default:t=a.toString()}return i=e.parseInt(i,10)||1,Array(Math.max(0,i-t.length)+1).join("0")+t}))}function zm(e,t){var n=Gm(e,t,"timescale"),i=1;n&&(i=$t(n)||1),(n=$t((n=Gm(e,t,"duration"))||""))&&(n/=i);var r=Gm(e,t,"startNumber"),a=Number(Gm(e,t,"presentationTimeOffset"))||0,s=Kt(r||"");if(null!=r&&null!=s||(s=1),r=null,t=qm(e,t,"SegmentTimeline")){t=Ct(t,"S"),r=i,e=e.ka.duration||1/0;for(var o=s,u=[],d=-a,l=0;l<t.length;++l){var c=t[l],h=t[l+1],m=Ut(c,"t",Kt),f=Ut(c,"d",Kt),p=Ut(c,"r",qt);if(c=Ut(c,"k",qt)||0,null!=m&&(m-=a),f){if(m=null!=m?m:d,0>(p=p||0))if(h){if(null==(h=Ut(h,"t",Kt)))break;if(m>=h)break;p=Math.ceil((h-m)/f)-1}else{if(1/0==e)break;if(m/r>=e)break;p=Math.ceil((e*r-m)/f)-1}for(0<u.length&&m!=d&&(u[u.length-1].end=m/r),h=0;h<=p;++h)d=m+f,u.push({start:m/r,end:d/r,dg:m,Cb:c,Wi:u.length+o}),m=d}}r=u}return{timescale:i,Qa:n,zd:s,Pb:a/i||0,cg:a,timeline:r}}function Vm(e,t){return[t(e.J),t(e.ha),t(e.oa)].filter(Wi)}function Gm(e,t,n){t=Vm(e,t),e=null;for(var i=(t=d(t)).next();!i.done&&!(e=i.value.attributes[n]);i=t.next());return e}function qm(e,t,n){t=Vm(e,t),e=null;for(var i=(t=d(t)).next();!i.done&&!(e=Nt(i.value,n));i=t.next());return e}function $m(e,t,n,i,r,a){if(a=void 0===a?0:a,Ft(e,"http://www.w3.org/1999/xlink","href")){var s=function(e,t,n,i,r,a){for(var s=Ft(e,"http://www.w3.org/1999/xlink","href"),o=Ft(e,"http://www.w3.org/1999/xlink","actuate")||"onRequest",u=d(Object.keys(e.attributes)),l=u.next();!l.done;l=u.next()){var c=(l=l.value).split(":"),h=Et("http://www.w3.org/1999/xlink");c[0]==h&&delete e.attributes[l]}if(5<=a)return Vr(new Ye(2,4,4028));if("onLoad"!=o)return Vr(new Ye(2,4,4027));var m=hi([i],[s]);return r.request(0,aa(m,t)).Ca((function(i){if(!(i=At(i.data,e.tagName)))return Vr(new Ye(2,4,4001,s));for(e.children=[];i.children.length;){var o=i.children.shift();e.children.push(o)}for(var u=(o=d(Object.keys(i.attributes))).next();!u.done;u=o.next())u=u.value,e.attributes[u]=i.attributes[u];return $m(e,t,n,m[0],r,a+1)}))}(e,t,n,i,r,a);return n&&(s=s.Ca(void 0,(function(){return $m(e,t,n,i,r,a)}))),s}s=[];for(var o=d(Pt(e)),u=o.next(),l={};!u.done;l={ad:void 0},u=o.next())l.ad=u.value,"urn:mpeg:dash:resolve-to-zero:2013"==Ft(l.ad,"http://www.w3.org/1999/xlink","href")?e.children=e.children.filter(function(e){return function(t){return t!==e.ad}}(l)):"SegmentTimeline"!=l.ad.tagName&&s.push($m(l.ad,t,n,i,r,a));return Kr(s).Ca((function(){return e}))}function Km(e){this.h=ye(e),this.g=new _a(this.h,0)}function Jm(e){var t=Xm(e);if(7<t.length)throw new Ye(2,3,3002);for(var n=0,i=(t=d(t)).next();!i.done;i=t.next())n=256*n+i.value;t=Xm(e);e:{for(var r=(i=d(Qm)).next();!r.done;r=i.next())if(me(t,new Uint8Array(r.value))){i=!0;break e}i=!1}if(i)t=e.h.byteLength-e.g.ya();else{if(8==t.length&&224&t[1])throw new Ye(2,3,3001);for(r=i=0;r<t.length;r++){var a=t[r];i=0==r?a&(1<<8-t.length)-1:256*i+a}t=i}return t=e.g.ya()+t<=e.h.byteLength?t:e.h.byteLength-e.g.ya(),i=ye(e.h,e.g.ya(),t),e.g.skip(t),new Zm(n,i)}function Xm(e){var t=e.g.ya(),n=e.g.T();if(0==n)throw new Ye(2,3,3002);return n=8-Math.floor(Math.log2(n)),e.g.skip(n-1),pe(e.h,t,n)}Km.prototype.sa=function(){return this.g.sa()};var Qm=[[255],[127,255],[63,255,255],[31,255,255,255],[15,255,255,255,255],[7,255,255,255,255,255],[3,255,255,255,255,255,255],[1,255,255,255,255,255,255,255]];function Zm(e,t){this.id=e,this.g=t}function ef(e){if(8<e.g.byteLength)throw new Ye(2,3,3002);if(8==e.g.byteLength&&224&e.g.getUint8(0))throw new Ye(2,3,3001);for(var t=0,n=0;n<e.g.byteLength;n++)t=256*t+e.g.getUint8(n);return t}function tf(e){var t=new Km(e.g);if(179!=(e=Jm(t)).id)throw new Ye(2,3,3013);if(e=ef(e),183!=(t=Jm(t)).id)throw new Ye(2,3,3012);t=new Km(t.g);for(var n=0;t.sa();){var i=Jm(t);if(241==i.id){n=ef(i);break}}return{hj:e,Mi:n}}function nf(e,t,n){if(!(t=qm(e,t,"Initialization")))return null;var i=e.J.Oa(),r=t.attributes.sourceURL;r&&(i=hi(i,[yt(r)],e.ob())),r=0;var a=null;return(t=Ut(t,"range",Gt))&&(r=t.start,a=t.end),(n=new fs((function(){return i}),r,a,uf(e),null,null,n)).codecs=e.J.codecs,n.mimeType=e.J.mimeType,n}function rf(e,t,n,i,r,a,s){var o,u,l,c,h,m,f,p,g,y,_,v,w,b,T,L,S,k;return I((function(D){if(1==D.g)return o=e.presentationTimeline,u=!e.xb||!e.ka.uf,l=e.ka.start,c=e.ka.duration,h=e.J.mimeType.split("/")[1],f=null,p=[(m=t)(i,r,a,!1),"webm"==h?m(n.N(),n.Ja,n.va,!0):null],m=null,M(D,Promise.all(p),2);if(g=D.h,y=g[0],_=g[1]||null,w=l-s,b=l,T=c?l+c:1/0,"mp4"==h)var x=function(e,t,n,i,r,a,s){var o,u=(new wa).R("sidx",(function(e){o=function(e,t,n,i,r,a,s){var o=[];s.reader.skip(4);var u=s.reader.P();if(0==u)throw new Ye(2,3,3005);if(0==s.version)var d=s.reader.P(),l=s.reader.P();else d=s.reader.Vc(),l=s.reader.Vc();s.reader.skip(2);var c=s.reader.ma();for(e=e+s.size+l,l=0;l<c;l++){var h=s.reader.P(),m=(2147483648&h)>>>31;h&=2147483647;var f=s.reader.P();if(s.reader.skip(4),1==m)throw new Ye(2,3,3006);o.push(new gs(d/u+n,(d+f)/u+n,(function(){return a}),e,e+h-1,t,n,i,r)),d+=f,e+=h}return s.parser.stop(),o}(t,i,r,a,s,n,e)}));if(e&&u.parse(e),o)return o;throw new Ye(2,3,3004)}(y,r,i,n,w,b,T);else{x=y;var A=new Km(_);if(440786851!=Jm(A).id)throw new Ye(2,3,3008);var Y=Jm(A);if(408125543!=Y.id)throw new Ye(2,3,3009);A=Y.g.byteOffset,Y=new Km(Y.g);for(var E=null;Y.sa();){var I=Jm(Y);if(357149030==I.id){E=I;break}}if(!E)throw new Ye(2,3,3010);for(E=new Km(E.g),I=1e6,Y=null;E.sa();){var P=Jm(E);if(2807729==P.id)I=ef(P);else if(17545==P.id)if(4==P.g.byteLength)Y=P.g.getFloat32(0);else{if(8!=P.g.byteLength)throw new Ye(2,3,3003);Y=P.g.getFloat64(0)}}if(null==Y)throw new Ye(2,3,3011);if(Y*=E=I/1e9,475249515!=(x=Jm(new Km(x))).id)throw new Ye(2,3,3007);x=function(e,t,n,i,r,a,s,o,u){function d(){return r}var l=[];e=new Km(e.g);for(var c=null,h=null;e.sa();){var m=Jm(e);if(187==m.id){var f=tf(m);f&&(m=n*f.hj,f=t+f.Mi,null!=c&&l.push(new gs(c+s,m+s,d,h,f-1,a,s,o,u)),c=m,h=f)}}return null!=c&&l.push(new gs(c+s,i+s,d,h,null,a,s,o,u)),l}(x,A,E,Y,i,n,w,b,T)}for(L=d(v=x),S=L.next();!S.done;S=L.next())(k=S.value).codecs=e.J.codecs,k.mimeType=e.J.mimeType,k.bandwidth=e.bandwidth;return o.vd(v),f=new Zo(v),u&&f.Kc(b,T,!0),D.return(f)}))}function af(e){return e.Yc}function sf(e){var t=qm(e,af,"RepresentationIndex");return e=Gt((e=Gm(e,af,"indexRange"))||""),t&&(e=Ut(t,"range",Gt,e)),e}function of(e,t){var n=e.J.mimeType.split("/")[1];if(e.J.contentType!=_i&&"mp4"!=n&&"webm"!=n)throw new Ye(2,4,4006);if("webm"==n&&!t)throw new Ye(2,4,4005)}function uf(e){var t=e.J;return{bandwidth:e.bandwidth,audioSamplingRate:t.audioSamplingRate,codecs:t.codecs,contentType:t.contentType,frameRate:t.frameRate||null,height:t.height||null,mimeType:t.mimeType,channelsCount:t.ce,pixelAspectRatio:t.pixelAspectRatio||null,width:t.width||null,label:e.ha.label||null,roles:e.roles||null,language:e.ha.language||null}}function df(e){return e.Rb}function lf(t,n,i,r,a,s,o,u,l){l||t.J.Ud||(t.J.Ud=Gm(t,cf,"initialization"));var c=t.J.Ud?function(e,t){var n=e.J.Ud;if(n||(n=Gm(e,cf,"initialization")),!n)return null;n=yt(n);var i=e.J.id,r=e.bandwidth||null,a=e.J.Oa,s=e.ob;return t=new fs((function(){var e=Wm(n,i,null,null,r,null);return hi(a(),[e],s())}),0,null,uf(e),null,null,t),t.codecs=e.J.codecs,t.mimeType=e.J.mimeType,t}(t,o):null,h=function(e){var t=zm(e,cf),n=Gm(e,cf,"media"),i=Gm(e,cf,"index"),r=Gm(e,cf,"k"),a=0;return r&&(a=parseInt(r,10)),{Qa:t.Qa,timescale:t.timescale,zd:t.zd,Pb:t.Pb,cg:t.cg,timeline:t.timeline,cc:n&&yt(n),md:i,mimeType:e.J.mimeType,codecs:e.J.codecs,bandwidth:e.bandwidth,Di:a}}(t);!function(e){var t=e.md?1:0;if(t+=e.timeline?1:0,0==(t+=e.Qa?1:0))throw new Ye(2,4,4002);if(1!=t&&(e.md&&(e.timeline=null),e.Qa=null),!e.md&&!e.cc)throw new Ye(2,4,4002)}(h);var m=Dt(t);if(h.md)return of(t,c),{nc:function(){var e=Wm(h.md,m.J.id,null,null,m.bandwidth||null,null);return e=hi(m.J.Oa(),[e]),rf(m,n,c,e,0,null,h.Pb)}};if(h.Qa)return r||"image"===t.ha.contentType||"text"===t.ha.contentType||(i=t.ka.start,r=t.oa.id,l=t.ka.duration,r=(r=null!=r&&s[r]||l)?i+r:1/0,t.presentationTimeline.Bf(h.Qa),t.presentationTimeline.Qg(i,r)),{nc:function(){return function(t,n,i,r,a,s,o,u){function l(i){var a=(i-_)*y,o=a+n.Pb,d=a+f;a=d+y;var l=Math.min(a,h()),c=[],m=n.Di;if(m)for(var p=(l-d)/m,g={},k=0;k<m;g={mh:void 0},k++){var D=d+p*k,x=D+p;g.mh=k+1,(g=new gs(D,x,function(t){return function(){var n=o*v;return"BigInt"in e&&n>Number.MAX_SAFE_INTEGER&&(n=BigInt(o)*BigInt(v)),n=Wm(M,b,i,t.mh,w,n),hi(T(),[n],L())}}(g),0,null,r,S,f,h(),[],"",null,null,_s,s)).codecs=t.J.codecs,g.mimeType=t.J.mimeType,0==u?0<k&&g.Pc():0!=k%u&&g.Pc(),c.push(g)}return(d=new gs(d,l,(function(){if(m)return[];var t=o*v;return"BigInt"in e&&t>Number.MAX_SAFE_INTEGER&&(t=BigInt(o)*BigInt(v)),t=Wm(M,b,i,null,w,t),hi(T(),[t],L())}),0,null,r,S,f,h(),c,"",null,null,_s,s,0<c.length)).codecs=t.J.codecs,d.mimeType=t.J.mimeType,d.bandwidth=t.bandwidth,d.j=a,d}function c(){var e=[Math.max(m.qb(),f),Math.min(m.Yb(),h())].map((function(e){return e-f}));return e=[Math.ceil(e[0]/y),Math.ceil(e[1]/y)-1],t.J.Wa&&e[1]++,e.map((function(e){return e+_}))}function h(){var e=null!=p&&a[p]||g;return e?f+e:1/0}var m=t.presentationTimeline,f=t.ka.start,p=t.oa.id,g=t.ka.duration,y=n.Qa,_=n.zd,v=n.timescale,M=n.cc,w=t.bandwidth||null,b=t.J.id,T=t.J.Oa,L=t.ob,S=f-n.Pb,k=c();i=t.xb?Math.max(k[0],k[1]-i+1):k[0],o=o||k[1],k=[];for(var D=i;D<=o;++D){var x=l(D);k.push(x)}var A=new Zo(k);if(k=m.Yb()<h(),D=m.U(),k||D){var Y=Math.max(i,o+1);i=y,t.J.Wa&&(i=.1),A.ue(i,(function(){var e=m.qb();A.Ha(e);var t=d(c());t.next(),t=t.next().value;for(var n=[];Y<=t;){var i=l(Y);n.push(i),Y++}return e>h()&&!n.length?null:n}))}return Promise.resolve(A)}(m,h,a,c,s,o,u,t.J.oe)}};var f=null;r=r=null,t.oa.id&&t.J.id&&(r=i[r=t.oa.id+","+t.J.id])&&(f=r.segmentIndex);var p=t.ka.start,g=t.ka.duration?p+t.ka.duration:1/0,y=!(t.xb&&t.ka.uf);return f?(mf(i=f,h,p,g,y,c),i.Ha(t.presentationTimeline.qb())):f=new hf(h,t.J.id,t.bandwidth,t.J.Oa,t.ob,p,g,c,y,o,t.J.oe),h.timeline&&"image"!==t.ha.contentType&&"text"!==t.ha.contentType&&t.presentationTimeline.Rg(h.timeline,p),r&&t.xb&&(r.segmentIndex=f),{nc:function(){return f instanceof hf&&0==f.getNumReferences()&&mf(f,h,p,g,y,c),Promise.resolve(f)}}}function cf(e){return e.ec}function hf(e,t,n,i,r,a,s,o,u,d,l){Zo.call(this,[]),this.h=e,this.F=t,this.B=n,this.C=i,this.H=r,this.j=a,this.l=s,this.s=o,this.A=d,this.G=l,u&&ff(this)}function mf(e,t,n,i,r,a){if(function(e,t){if(e.s!==t){e.s=t;for(var n=(e=d(e.g)).next();!n.done;n=e.next())(n=n.value)&&ys(n,t)}}(e,a),e.h){if(n=e.h.timeline,e.h.cc!==t.cc&&(e.h.cc=t.cc),n.length){var s=n[n.length-1];t=t.timeline.filter((function(e){return e.end>s.end}))}else t=t.timeline.slice();0<t.length&&e.h.timeline.push.apply(e.h.timeline,l(t)),e.l!==i&&(e.l=i)}else e.h=t,e.j=n,e.l=i;r&&ff(e)}function ff(e){if(!e.o){for(var t=e.h.timeline;t.length&&t[t.length-1].start>=e.l;)t.pop();e.Ha(e.j)}}function pf(e,t,n,i,r,a,s,o){return e=Wm(e,t,n,a,i||null,r),hi(s(),[e],o()).map((function(e){return e.toString()}))}function gf(e){this.o=null,this.A=e,this.G=new ea,this.i=[],this.h=null,this.m=[],this.B=null,this.F=[],this.C=300,this.l=new Map,this.j=new Map,this.g=null,this.s="UNKNOWN"}function yf(e,t){var n,i,r,a,s,o,u;return I((function(d){return 1==d.g?(n=hi(e.i,[_f(e,t)]),i=aa(n,e.o.retryParameters),r=e.A.networkingEngine.request(8,i),ta(e.G,r),b(d,2),M(d,r.promise,4)):2!=d.g?(a=d.h,s=ct(a.data),1==(o=JSON.parse(s)).VERSION&&function(e,t,n){null!=e.g&&(e.g.stop(),e.g=null);var i=t["RELOAD-URI"]||n;e.g=new He((function(){yf(e,i)})),(n=t.TTL)&&(e.C=n),e.g.$(e.C),e.m=t["PATHWAY-PRIORITY"]||[],e.F=t["PATHWAY-CLONES"]||[]}(e,o,a.uri),L(d,0)):(u=S(d))&&7001==u.code?d.return():(null!=e.g&&(e.g.stop(),e.g=null),e.g=new He((function(){yf(e,t)})),e.g.$(e.C),void w(d))}))}function _f(e,t){if(!e.m.length)return t;t=new Wn(t);var n=e.B||e.m[0],i=Math.round(e.A.getBandwidthEstimate()),r=t.g;return"DASH"==e.s?(r.add("_DASH_pathway",n),r.add("_DASH_throughput",String(i))):"HLS"==e.s&&(r.add("_HLS_pathway",n),r.add("_HLS_throughput",String(i))),ri(r)&&qn(t,r),t.toString()}function vf(e,t,n,i){var r=e.l.get(t);r||(r=new Map),r.set(n,i),e.l.set(t,r)}function Mf(e,t,n){n=void 0!==n&&n,t=e.l.get(t)||new Map;for(var i=[],r=d(e.m),a=r.next(),s={};!a.done;s={Tc:void 0},a=r.next())if(s.Tc=a.value,a=t.get(s.Tc))i.push({Hf:s.Tc,location:a});else if(a=e.F.find(function(e){return function(t){return t.Aj==e.Tc}}(s))){var o=t.get(a["BASE-ID"]);o&&(a["URI-REPLACEMENT"].uh?(Vn(o=new Wn(o),a["URI-REPLACEMENT"].uh),i.push({Hf:s.Tc,location:o.toString()})):i.push({Hf:s.Tc,location:o}))}for(r=Date.now(),a=(s=d(e.j.keys())).next();!a.done;a=s.next())a=a.value,r>(o=e.j.get(a))&&e.j.delete(a);if(i=i.filter((function(t){for(var n=d(e.j.keys()),i=n.next();!i.done;i=n.next())if(i.value.includes(new Wn(t.location).Fb))return!1;return!0})),i.length&&(e.B=i[0].Hf),i=i.map((function(e){return e.location})),!i.length&&e.h)for(s=(r=d(e.h.split(","))).next();!s.done;s=r.next())(s=t.get(s.value))&&(e.B=e.h,i.push(s));if(!i.length)for(r=(t=d(t.values())).next();!r.done;r=t.next())i.push(r.value);return n?i:hi(e.i,i)}function wf(){this.l=[],this.h=[],this.g=[],this.j=[],this.i=[],this.s=this.o=!1,this.m=new Set}function bf(e,t){for(var n=[],i=[],r=[],a=[],s=(e=d(e)).next();!s.done;s=e.next()){var o=s.value;s=new Map(o.audioStreams.map((function(e){return[$f(e),e]})));var u=new Map(o.videoStreams.map((function(e){return[qf(e),e]}))),l=new Map(o.textStreams.map((function(e){return[Kf(e),e]})));if(o=new Map(o.imageStreams.map((function(e){return[Jf(e),e]}))),t){var c=Wf(_i);l.set(Kf(c),c),c=Wf("image"),o.set(Jf(c),c)}n.push(s),i.push(u),r.push(l),a.push(o)}return{lg:n,sh:i,oh:r,Hg:a}}function Tf(e){var t,n,i,r,a,s,o,u,l,c,h,m,f,p,g,y,_,v,w,b,T,L,S,k,D,x,A,Y,E;return I((function(I){switch(I.g){case 1:if(t=vi,1==e.length)return I.return(e[0]);for(n=e.map((function(e){return new Map(e.filter((function(e){return e.type===t.V})).map((function(e){return[$f(e),e]})))})),i=e.map((function(e){return new Map(e.filter((function(e){return e.type===t.la})).map((function(e){return[qf(e),e]})))})),r=e.map((function(e){return new Map(e.filter((function(e){return e.type===t.wa})).map((function(e){return[Kf(e),e]})))})),a=e.map((function(e){return new Map(e.filter((function(e){return e.type===t.He})).map((function(e){return[Jf(e),e]})))})),s=d(r),o=s.next();!o.done;o=s.next())u=o.value,l=Bf(t.wa),u.set(Kf(l),l);for(c=d(a),h=c.next();!h.done;h=c.next())m=h.value,f=Bf(t.He),m.set(Jf(f),f);return M(I,Lf(p=new wf,[],n,0,Af,Ef,0),2);case 2:return g=I.h,M(I,Lf(p,[],i,0,Af,Ef,0),3);case 3:return y=I.h,M(I,Lf(p,[],r,0,Af,Ef,0),4);case 4:return _=I.h,M(I,Lf(p,[],a,0,Af,Ef,0),5);case 5:if(v=I.h,w=0,y.length&&g.length)for(S=d(g),k=S.next();!k.done;k=S.next())for(D=k.value,x=d(y),A=x.next();!A.done;A=x.next())Y=A.value,E=w++,Y.variantIds.push(E),D.variantIds.push(E);else for(b=y.concat(g),T=d(b),L=T.next();!L.done;L=T.next())L.value.variantIds=[w++];return I.return(y.concat(g).concat(_).concat(v))}}))}function Lf(e,t,n,i,r,a,s){var o,u,l,c,h,m,f,p,g,y,_,v,w,b,T,L,S,k;return I((function(D){switch(D.g){case 1:for(o=[],u=0;u<n.length;u++)u>=i?o.push(new Set(n[u].values())):o.push(new Set);l=d(t),c=l.next();case 2:if(c.done){D.u(4);break}return h=c.value,M(D,function(e,t,n,i,r,a,s){return I((function(o){return 1==o.g?(If(e,n,t,0<s),t.matchedStreams?t.segmentIndex?M(o,Sf(t,i+s),2):o.u(2):o.return(!1)):(Df(t,i,r,a,s),o.return(!0))}))}(e,h,n,i,a,o,s),5);case 5:if(!D.h)throw new Ye(2,4,4037);c=l.next(),D.u(2);break;case 4:for(m=d(o),f=m.next();!f.done;f=m.next())for(p=f.value,g=d(p),y=g.next();!y.done;y=g.next())_=y.value,(v=kf(e,_,n,r,a,o))&&t.push(v);for(w=d(o),b=w.next();!b.done;b=w.next())for(T=b.value,L=d(T),S=L.next(),k={};!S.done;k={Wf:void 0},S=L.next())if(k.Wf=S.value,!Gf(k.Wf)&&t.some(function(t){return function(n){return jf(e,t.Wf,n)}}(k)))throw new Ye(2,4,4037);return D.return(t)}}))}function Sf(e,t){var n,i,r,a,s,o;return I((function(u){if(1==u.g){for(n=[],i=e.matchedStreams,r=t;r<i.length;r++)a=i[r],n.push(a.createSegmentIndex()),a.trickModeVideo&&!a.trickModeVideo.segmentIndex&&n.push(a.trickModeVideo.createSegmentIndex());return M(u,Promise.all(n),2)}if(e.segmentIndex instanceof iu)for(s=t;s<i.length;s++)(o=i[s]).segmentIndex&&e.segmentIndex.h.push(o.segmentIndex);w(u)}))}function kf(e,t,n,i,r,a){if(Gf(t))return null;var s=i(t);return If(e,n,s),s.createSegmentIndex&&(s.createSegmentIndex=function(){return I((function(e){return s.segmentIndex?e.u(0):(s.segmentIndex=new iu,M(e,Sf(s,0),0))}))}),s.matchedStreams&&s.matchedStreams.length?(Df(s,0,r,a,0),s):null}function Df(e,t,n,i,r){var a=e.matchedStreams;for(t+=r;t<a.length;t++){var s=a[t];n(e,s);var o=!0;if("audio"==e.type&&0==Ji(e.language,s.language)&&(o=!1),o&&(i[t-r].delete(s),s.fullMimeTypes))for(o=(s=d(s.fullMimeTypes.values())).next();!o.done;o=s.next())e.fullMimeTypes.add(o.value)}}function xf(e){var t=Object.assign({},e);return t.originalId=null,t.createSegmentIndex=function(){return Promise.resolve()},t.closeSegmentIndex=function(){if(t.segmentIndex&&(t.segmentIndex.release(),t.segmentIndex=null),t.matchedStreams)for(var e=d(t.matchedStreams),n=e.next();!n.done;n=e.next())(n=n.value).segmentIndex&&(n.segmentIndex.release(),n.segmentIndex=null)},t.roles=t.roles.slice(),t.segmentIndex=null,t.emsgSchemeIdUris=[],t.keyIds=new Set,t.closedCaptions=e.closedCaptions?new Map(e.closedCaptions):null,t.trickModeVideo=null,t}function Af(e){var t=Object.assign({},e);return t.roles=t.roles.slice(),t.keyIds=new Set,t.segments=[],t.variantIds=[],t.closedCaptions=e.closedCaptions?new Map(e.closedCaptions):null,t}function Yf(e,t){function n(e,t){e||(e=[]);for(var n=(t=d(t)).next();!n.done;n=t.next())n=n.value,e.includes(n)||e.push(n);return e}e.roles=n(e.roles,t.roles),t.emsgSchemeIdUris&&(e.emsgSchemeIdUris=n(e.emsgSchemeIdUris,t.emsgSchemeIdUris));for(var i=d(t.keyIds),r=i.next();!r.done;r=i.next())e.keyIds.add(r.value);if(null==e.originalId?e.originalId=t.originalId:(i=t.originalId||"")&&!e.originalId.endsWith(i)&&(e.originalId+=","+i),i=Ce(e.drmInfos,t.drmInfos),t.drmInfos.length&&e.drmInfos.length&&!i.length)throw new Ye(2,4,4038);if(e.drmInfos=i,e.encrypted=e.encrypted||t.encrypted,t.closedCaptions)for(e.closedCaptions||(e.closedCaptions=new Map),r=(i=d(t.closedCaptions)).next();!r.done;r=i.next()){var a=d(r.value);r=a.next().value,a=a.next().value,e.closedCaptions.set(r,a)}e.bandwidth&&t.bandwidth&&(e.bandwidth=Math.max(e.bandwidth,t.bandwidth)),t.trickModeVideo?(e.trickModeVideo||(e.trickModeVideo=xf(t.trickModeVideo),e.trickModeVideo.matchedStreams=[],e.trickModeVideo.createSegmentIndex=function(){if(e.trickModeVideo.segmentIndex)return Promise.resolve();for(var t=new iu,n=d(e.trickModeVideo.matchedStreams),i=n.next();!i.done;i=n.next())t.h.push(i.value.segmentIndex);return e.trickModeVideo.segmentIndex=t,Promise.resolve()}),e.trickModeVideo.matchedStreams.push(t.trickModeVideo),Yf(e.trickModeVideo,t.trickModeVideo)):e.trickModeVideo&&(e.trickModeVideo.matchedStreams.push(t),Yf(e.trickModeVideo,t))}function Ef(e,t){var n=e.roles;n||(n=[]);for(var i=d(t.roles),r=i.next();!r.done;r=i.next())r=r.value,n.includes(r)||n.push(r);for(e.roles=n,i=(n=d(t.keyIds)).next();!i.done;i=n.next())e.keyIds.add(i.value);if(e.encrypted=e.encrypted&&t.encrypted,e.segments.push.apply(e.segments,l(t.segments)),t.closedCaptions)for(e.closedCaptions||(e.closedCaptions=new Map),n=(t=d(t.closedCaptions)).next();!n.done;n=t.next())n=(i=d(n.value)).next().value,i=i.next().value,e.closedCaptions.set(n,i)}function If(e,t,n,i){i=void 0!==i&&i?n.matchedStreams:[];for(var r=(t=d(t)).next();!r.done;r=t.next()){if(!(r=Pf(e,r.value,n)))return;i.push(r)}n.matchedStreams=i}function Pf(e,t,n){var i={audio:$f,video:qf,text:Kf,image:Jf}[n.type],r=null,a=i(n);if(t.has(a))r=t.get(a);else{a={audio:function(t,n){return jf(e,t,n)},video:function(t,n){return jf(e,t,n)},text:Of,image:Rf}[n.type];for(var s={audio:Nf,video:Hf,text:Uf,image:Ff}[n.type],o=d(t.values()),u=o.next();!u.done;u=o.next())!a(n,u=u.value)||n.fastSwitching!=u.fastSwitching||r&&!s(n,r,u)||(r=u)}return e.s&&!Gf(r)&&t.delete(i(r)),r}function Cf(e,t){return e.mimeType==t.mimeType&&Xf(e.codecs)===Xf(t.codecs)}function jf(e,t,n){return!(!Cf(t,n)&&!e.o||t.drmInfos&&!Pe(t.drmInfos,n.drmInfos))}function Of(e,t){return!t.language||e.forced===t.forced&&0!=Ji(e.language,t.language)&&t.kind==e.kind}function Rf(){return!0}function Nf(e,t,n){var i=Cf(e,t),r=Cf(e,n);if(i&&!r)return!1;if(!i&&r)return!0;if(i=Ji(e.language,t.language),(r=Ji(e.language,n.language))>i)return!0;if(r<i)return!1;if(t.label!==n.label){if(e.label===t.label)return!1;if(e.label===n.label)return!0}if(e.roles.length){if(i=t.roles.filter((function(t){return e.roles.includes(t)})),(r=n.roles.filter((function(t){return e.roles.includes(t)}))).length>i.length)return!0;if(r.length<i.length)return!1;if(n.roles.length!==t.roles.length)return n.roles.length<t.roles.length}else{if(!n.roles.length&&t.roles.length)return!0;if(n.roles.length&&!t.roles.length)return!1}return!(t.primary||!n.primary)||!(t.primary&&!n.primary)&&((i=zf(e.channelsCount,t.channelsCount,n.channelsCount))==Qf||i!=ep&&((i=zf(e.audioSamplingRate,t.audioSamplingRate,n.audioSamplingRate))==Qf||i!=ep&&!(!e.bandwidth||Vf(e.bandwidth,t.bandwidth,n.bandwidth)!=Qf)))}function Hf(e,t,n){var i=Cf(e,t),r=Cf(e,n);if(i&&!r)return!1;if(!i&&r)return!0;if((i=zf(e.width*e.height,t.width*t.height,n.width*n.height))==Qf)return!0;if(i==ep)return!1;if(e.frameRate){if((i=zf(e.frameRate,t.frameRate,n.frameRate))==Qf)return!0;if(i==ep)return!1}return!(!e.bandwidth||Vf(e.bandwidth,t.bandwidth,n.bandwidth)!=Qf)}function Uf(e,t,n){var i=Ji(e.language,t.language),r=Ji(e.language,n.language);if(r>i)return!0;if(r<i)return!1;if(!t.primary&&n.primary)return!0;if(t.primary&&!n.primary)return!1;if(t.label!==n.label){if(e.label===t.label)return!1;if(e.label===n.label)return!0}if(e.roles.length){if(i=t.roles.filter((function(t){return e.roles.includes(t)})),(r=n.roles.filter((function(t){return e.roles.includes(t)}))).length>i.length)return!0;if(r.length<i.length)return!1}else{if(!n.roles.length&&t.roles.length)return!0;if(n.roles.length&&!t.roles.length)return!1}return n.mimeType==e.mimeType&&n.codecs==e.codecs&&(t.mimeType!=e.mimeType||t.codecs!=e.codecs)}function Ff(e,t,n){return zf(e.width*e.height,t.width*t.height,n.width*n.height)==Qf}function Bf(e){return{id:0,originalId:"",groupId:null,primary:!1,type:e,mimeType:"",codecs:"",language:"",originalLanguage:null,label:null,width:null,height:null,encrypted:!1,keyIds:new Set,segments:[],variantIds:[],roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,external:!1,fastSwitching:!1,isAudioMuxedInVideo:!1}}function Wf(e){return{id:0,originalId:"",groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Zo([]),mimeType:"",codecs:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"",originalLanguage:null,label:null,type:e,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set,isAudioMuxedInVideo:!1}}function zf(e,t,n){if(t==e&&e!=n)return ep;if(n==e&&e!=t)return Qf;if(t>e){if(n<=e||n-e<t-e)return Qf;if(n-e>t-e)return ep}else{if(n>e)return ep;if(e-n<e-t)return Qf;if(e-n>e-t)return ep}return Zf}function Vf(e,t,n){return t=Math.abs(e-t),(e=Math.abs(e-n))<t?Qf:t<e?ep:Zf}function Gf(e){switch(e.type){case _i:return!e.language;case"image":return!e.tilesLayout;default:return!1}}function qf(e){return JSON.stringify([e.fastSwitching,e.width,e.frameRate,Xf(e.codecs),e.mimeType,e.label,e.roles,e.closedCaptions?Array.from(e.closedCaptions.entries()):null,e.bandwidth])}function $f(e){return JSON.stringify([e.fastSwitching,e.channelsCount,e.language,e.bandwidth,e.label,Xf(e.codecs),e.mimeType,e.roles,e.audioSamplingRate,e.primary])}function Kf(e){return JSON.stringify([e.language,e.label,e.codecs,e.mimeType,e.bandwidth,e.roles])}function Jf(e){return JSON.stringify([e.width,e.codecs,e.mimeType])}function Xf(e){if(!tp.has(e)){var t=xi(e);tp.set(e,t)}return tp.get(e)}g(hf,Zo),(i=hf.prototype).getNumReferences=function(){return this.h?this.h.timeline.length:0},i.release=function(){Zo.prototype.release.call(this),this.h=null},i.Ha=function(e){if(this.h){for(var t=0,n=this.h.timeline,i=0;i<n.length&&n[i].end+this.j<=e;i+=1)t+=1;0<t&&(this.h.timeline=n.slice(t),this.g.length>=t&&(this.g=this.g.slice(t)),this.i+=t,0===this.getNumReferences()&&this.release())}},i.find=function(e){if(this.h&&this.h.timeline&&this.h.timeline.length&&e<this.h.timeline[0].start+this.j)return this.i;if(!this.h)return null;var t=this.h.timeline;if(e<this.j||e>=this.l)return null;for(var n=t.length-1,i=0;i<t.length;i++){var r=t[i],a=r.start+this.j;if(r=i<n?t[i+1].start+this.j:1/0===this.l?r.end+this.j:this.l,e>=a&&e<r)return i+this.i}return null},i.get=function(e){var t=this;if(0>(e-=this.i)||e>=this.getNumReferences()||!this.h)return null;var n=this.g[e];if(!n){var i=this.h.timeline[e],r=i.Wi,a=this.h.cg+i.dg;n=this.j-this.h.Pb;var s=this.j+i.end,o=s;e===this.getNumReferences()-1&&1/0!==this.l&&(o=this.l);for(var u=this.h.codecs,d=this.h.mimeType,l=this.h.bandwidth,c=[],h=(i.end-i.start)/i.Cb,m={},f=0;f<i.Cb;m={we:void 0,nh:void 0},f++){var p=i.start+h*f,g=p+h;m.nh=f+1,m.we=null,(m=new gs(this.j+p,this.j+g,function(e){return function(){return t.h?(null==e.we&&(e.we=pf(t.h.cc,t.F,r,t.B,a,e.nh,t.C,t.H)),e.we):[]}}(m),0,null,this.s,n,this.j,this.l,[],"",null,null,_s,this.A)).codecs=u,m.mimeType=d,m.bandwidth=l,0==this.G?0<f&&m.Pc():0!=f%this.G&&m.Pc(),c.push(m)}(n=new gs(this.j+i.start,o,(function(){return 0<i.Cb||!t.h?[]:pf(t.h.cc,t.F,r,t.B,a,null,t.C,t.H)}),0,null,this.s,n,this.j,this.l,c,"",null,null,_s,this.A,0<i.Cb)).codecs=u,n.mimeType=d,n.j=s,n.bandwidth=l,this.g[e]=n}return n},i.yb=function(e){ff(this);for(var t=0;t<this.getNumReferences();t++){var n=this.get(t+this.i);n&&e(n)}},gf.prototype.configure=function(e){this.o=e},gf.prototype.destroy=function(){return this.A=this.o=null,this.i=[],this.h=null,this.m=[],this.F=[],this.l.clear(),null!=this.g&&(this.g.stop(),this.g=null),this.G.destroy()},gf.prototype.setManifestType=function(e){this.s=e},gf.prototype.banLocation=function(e){this.j.set(e,Date.now()+6e4)},(i=wf.prototype).release=function(){for(var e=d(this.h.concat(this.g,this.j,this.i)),t=e.next();!t.done;t=e.next())(t=t.value).segmentIndex&&t.segmentIndex.release();this.h=[],this.g=[],this.j=[],this.i=[],this.l=[],this.s=this.o=!1,this.m.clear()},i.ii=function(){return this.l},i.mf=function(){return this.j.slice()},i.Rh=function(){return this.i},i.sg=function(e,t){if(e){if("audio"==e.type)for(var n=d(this.h),i=n.next();!i.done;i=n.next())(i=i.value).matchedStreams=i.matchedStreams.filter((function(t){return t!==e}));else if("video"==e.type)for(i=(n=d(this.g)).next();!i.done;i=n.next())(i=i.value).matchedStreams=i.matchedStreams.filter((function(t){return t!==e})),i.trickModeVideo&&(i.trickModeVideo.matchedStreams=i.trickModeVideo.matchedStreams.filter((function(t){return t!==e})));else if(e.type==_i)for(i=(n=d(this.j)).next();!i.done;i=n.next())(i=i.value).matchedStreams=i.matchedStreams.filter((function(t){return t!==e}));else if("image"==e.type)for(i=(n=d(this.i)).next();!i.done;i=n.next())(i=i.value).matchedStreams=i.matchedStreams.filter((function(t){return t!==e}));e.segmentIndex&&e.closeSegmentIndex(),this.m.delete(t)}},i.Ne=function(e,t,n){n=void 0!==n&&n;var i,r,a,s,o,u,l,c,h,m,f,p,g,y,_,v,b,T,L,S,k,D,x,A,Y,E,P,C,j,O,R=this;return I((function(I){if(1==I.g){if(i=vi,!t&&1==e.length)return r=bf(e,!1),a=r.lg,s=r.sh,o=r.oh,u=r.Hg,R.h=Array.from(a[0].values()),R.g=Array.from(s[0].values()),R.j=Array.from(o[0].values()),R.i=Array.from(u[0].values()),I.u(2);for(l=n?R.m.size:0,c=-1,h=0;h<e.length;h++)m=e[h],R.m.has(m.id)||(R.m.add(m.id),-1==c&&(c=h));return-1==c?I.return():(f=bf(e,!0),p=f.lg,g=f.sh,y=f.oh,_=f.Hg,M(I,Promise.all([Lf(R,R.h,p,c,xf,Yf,l),Lf(R,R.g,g,c,xf,Yf,l),Lf(R,R.j,y,c,xf,Yf,l),Lf(R,R.i,_,c,xf,Yf,l)]),2))}if(v=0,b=[],R.g.length&&R.h.length)for(x=d(R.h),A=x.next();!A.done;A=x.next())for(Y=A.value,E=d(R.g),P=E.next();!P.done;P=E.next())C=P.value,j=Ce(Y.drmInfos,C.drmInfos),Y.drmInfos.length&&C.drmInfos.length&&!j.length||(O=v++,b.push({id:O,language:Y.language,disabledUntilTime:0,primary:Y.primary,audio:Y,video:C,bandwidth:(Y.bandwidth||0)+(C.bandwidth||0),drmInfos:j,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]}));else for(T=R.g.length?R.g:R.h,L=d(T),S=L.next();!S.done;S=L.next())k=S.value,D=v++,b.push({id:D,language:k.language,disabledUntilTime:0,primary:k.primary,audio:k.type==i.V?k:null,video:k.type==i.la?k:null,bandwidth:k.bandwidth||0,drmInfos:k.drmInfos,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});R.l=b,w(I)}))},i.bh=function(e){this.o=e},i.ih=function(e){this.s=e},U("shaka.util.PeriodCombiner",wf),wf.prototype.setUseStreamOnce=wf.prototype.ih,wf.prototype.setAllowMultiTypeVariants=wf.prototype.bh,wf.prototype.combinePeriods=wf.prototype.Ne,wf.prototype.deleteStream=wf.prototype.sg,wf.prototype.getImageStreams=wf.prototype.Rh,wf.prototype.getTextStreams=wf.prototype.mf,wf.prototype.getVariants=wf.prototype.ii;var Qf=1,Zf=0,ep=-1,tp=new Map;function np(e,t){try{return function(e,t){var n=new DOMParser,i=ip.value()(e);e=null;try{e=n.parseFromString(i,"text/xml")}catch(e){return null}if(!(n=e.documentElement)||n.getElementsByTagName("parsererror").length||n.tagName!=t)return null;if(!("createNodeIterator"in document))return n;for(t=document.createNodeIterator(e,NodeFilter.SHOW_ALL);e=t.nextNode();)if(e instanceof HTMLElement||e instanceof SVGElement)return null;return n}(mt(e),t)}catch(e){return null}}var ip=new Ie((function(){if("undefined"!=typeof trustedTypes){var e=trustedTypes.createPolicy("shaka-player#xml",{createHTML:function(e){return e}});return function(t){return e.createHTML(t)}}return function(e){return e}}));function rp(){var e=this;this.j=this.g=null,this.A=[],this.i=null,this.na=1,this.F=[],this.l={ae:"",type:"",profiles:[],Mb:null,Wa:0,Oa:null,xd:0},this.s=new Map,this.o={},this.B={},this.ja={},this.m=new wf,this.K=0,this.ra=new W(5),this.L=new He((function(){e.I&&!e.g.continueLoadingWhenPaused&&(e.G.cb(e.I,"timeupdate"),e.I.paused)?e.G.pa(e.I,"timeupdate",(function(){return _p(e)})):_p(e)})),this.S=new ea,this.O=null,this.C=[],this.da=1/0,this.H=!1,this.h=null,this.M=0,this.ga=!1,this.G=new Z,this.I=null,this.Y=!1,this.aa="",this.fa=function(){return!1},this.Z=[]}function ap(e){var t,n,i,r,a,s,o,u,c,h,m;return I((function(f){return 1==f.g?(t=4,n="MPD",i=function(e){var t=e.l.xd;if(!e.l.ae||!t||!e.F.length)return[];var n=Date.now()/1e3,i=e.F.filter((function(e){return!(e=Kt(e.attributes.ttl))||t+e>n})).map(Ot).filter(Wi);return i.length?hi(e.A,i):[]}(e),r=e.A,i.length?(r=i,n="Patch",t=6):1<e.A.length&&e.h&&(a=Mf(e.h,"Location",!0)).length&&(r=a),s=aa(r,e.g.retryParameters),o=Date.now(),M(f,Sp(e,s,0,{type:t}),2)):3!=f.g?(u=f.h,e.j?(u.uri&&u.uri!=u.originalUri&&!e.A.includes(u.uri)&&e.A.unshift(u.uri),c=new Wn(u.uri),e.aa=c.g.toString(),M(f,function(e,t,n,i){var r,a,s,o,u,c,h,m;return I((function(f){if(1==f.g){if(r=t,(a=e.g.dash.manifestPreprocessor)!=cd){if(se("manifest.dash.manifestPreprocessor configuration","Please Use manifest.dash.manifestPreprocessorTXml instead."),!(s=np(r,i)))throw new Ye(2,4,4001,n);a(s),r=ft(s.outerHTML)}if(!(o=At(r,i)))throw new Ye(2,4,4001,n);return(u=e.g.dash.manifestPreprocessorTXml)!=hd&&u(o),"Patch"===i?f.return(function(e,t){var n,i,r,a,s,o,u,c,h,m,f,p,g,y,_,v,b,T,L,S,k,D,x,A;return I((function(Y){if(1==Y.g){if(n=t.attributes.mpdId,i=Ut(t,"originalPublishTime",zt),!n||n!==e.l.ae||i!==e.l.xd)throw e.F=[],new Ye(1,4,4052);for(r=[],a=[],s=new Set,o=d(Pt(t)),u=o.next();!u.done;u=o.next())if(c=u.value,h=Zt(c.attributes.sel||""),m=h[h.length-1],f=Ot(c)||"","MPD"===m.name)if("mediaPresentationDuration"===m.Ub){var E=Vt(Ot(c)||"");if(null!=E){e.l.Mb=E;for(var I=d(e.s.values()),P=I.next();!P.done;P=I.next())P.value.Mb=E}}else if("type"===m.Ub){for(e.i.presentationTimeline.Bc("static"==f),e.l.type=f,I=(E=d(e.s.values())).next();!I.done;I=E.next())I.value.xb="dynamic"==f;"static"==f&&(e.K=-1)}else"publishTime"===m.Ub?e.l.xd=zt(f)||0:null===m.Ub&&"add"===c.tagName&&a.push(c);else if("PatchLocation"===m.name)en(e.F,c);else if("Period"===m.name)"add"===c.tagName?a.push(c):"remove"===c.tagName&&m.id&&dp(e,m.id);else if("SegmentTemplate"===m.name){if((E=(I=Zt(c.attributes.sel||""))[I.length-1]).Ub){I=lp(e,I),P=Ot(c)||"";for(var C=d(I),j=C.next();!j.done;j=C.next())nn((j=e.s.get(j.value)).J.ec,c.tagName,E.Ub,P);E=I}else E=[];for(p=d(E),g=p.next();!g.done;g=p.next())y=g.value,s.add(y)}else if("SegmentTimeline"===m.name||"S"===m.name){for(E=Zt(c.attributes.sel||""),P=(I=d(E=lp(e,E))).next();!P.done;P=I.next())en(C=Ct(P=qm(P=e.s.get(P.value),cf,"SegmentTimeline"),"S"),c),P.children=C;for(_=d(E),v=_.next();!v.done;v=_.next())b=v.value,s.add(b)}for(T=d(s),L=T.next();!L.done;L=T.next())S=L.value,cp(e,S);for(k=d(a),D=k.next();!D.done;D=k.next())x=D.value,r.push.apply(r,l(up(e,x)));return r.length?(e.i.periodCount+=r.length,e.i.gapCount=e.M,M(Y,op(e,r,!0),2)):Y.u(2)}"static"==e.l.type&&(A=e.l.Mb,e.i.presentationTimeline.bb(A||1/0)),w(Y)}))}(e,o)):e.g.dash.disableXlinkProcessing?f.return(sp(e,o,n)):(c=e.g.dash.xlinkFailGracefully,h=$m(o,e.g.retryParameters,c,n,e.j.networkingEngine),ta(e.S,h),M(f,h.promise,2))}return m=f.h,f.return(sp(e,m,n))}))}(e,u.data,u.uri,n),3)):f.return(0)):(h=Date.now(),m=(h-o)/1e3,e.ra.sample(1,m),f.return(m))}))}function sp(e,t,n){var i,r,a,s,o,u,l,c,h,m,f,p,g,y,_,v,T,k,D,x,A,Y,E,P,C,j,O,R,N,H,U,F,B,W,z,V,G,q,K,J,X,Q,Z,ee,te,ne,ie,re,ae,se,oe;return I((function(ue){switch(ue.g){case 1:for(e.h&&e.h.l.clear(),i=[n],r=[],a=new Map,s=Ct(t,"Location"),o=d(s),u=o.next();!u.done;u=o.next())l=u.value,c=l.attributes.serviceLocation,(h=Ot(l))&&(m=hi(i,[h])[0],c&&(e.h?vf(e.h,"Location",c,m):a.set(c,m)),r.push(m));if(e.h?0<(f=Mf(e.h,"Location",!0)).length&&(i=e.A=f):r.length&&(i=e.A=r),e.l.ae=t.attributes.id||"",e.l.xd=Ut(t,"publishTime",zt)||0,e.F=Ct(t,"PatchLocation"),p=Promise.resolve(),(g=Nt(t,"ContentSteering"))&&e.j)for(y=g.attributes.defaultServiceLocation,e.h?(e.h.i=i,e.h.h=y):(e.h=new gf(e.j),e.h.configure(e.g),e.h.setManifestType("DASH"),e.h.i=i,e.h.h=y,(_=Ot(g))&&(Ut(g,"queryBeforeStart",Xt,!1)?p=yf(e.h,_):yf(e.h,_))),v=d(a.keys()),T=v.next();!T.done;T=v.next())k=T.value,D=a.get(k),vf(e.h,"Location",k,D);if(x=Ct(t,"BaseURL"),A=!1,e.h)for(Y=d(x),E=Y.next();!E.done;E=Y.next())P=E.value,C=P.attributes.serviceLocation,j=Ot(P),C&&j&&(vf(e.h,"BaseURL",C,j),A=!0);if(e.Z=null,A&&e.h||(O=x.map(Ot),e.Z=hi(i,O)),R=function(){return e.h&&A?Mf(e.h,"BaseURL"):e.Z?e.Z:[]},e.l.Oa=R,N=0,x&&x.length&&(N=Ut(x[0],"availabilityTimeOffset",Jt)||0),e.l.Wa=N,H=e.g.dash.ignoreMinBufferTime,U=0,H||(U=Ut(t,"minBufferTime",Vt)||0),e.K=Ut(t,"minimumUpdatePeriod",Vt,-1),F=Ut(t,"availabilityStartTime",zt),B=Ut(t,"timeShiftBufferDepth",Vt),W=e.g.dash.ignoreSuggestedPresentationDelay,z=null,W||(z=Ut(t,"suggestedPresentationDelay",Vt)),V=e.g.dash.ignoreMaxSegmentDuration,G=null,V||(G=Ut(t,"maxSegmentDuration",Vt)),q=t.attributes.type||"static",e.i&&e.i.presentationTimeline&&(e.Y=e.i.presentationTimeline.U()&&"static"==q),e.l.type=q,e.i)for(K=e.i.presentationTimeline,J=d(Object.values(e.o)),X=J.next();!X.done;X=J.next())(Q=X.value).segmentIndex&&Q.segmentIndex.Ha(K.qb());else Z=e.g.defaultPresentationDelay||1.5*U,K=new Po(F,null!=z?z:Z,e.g.dash.autoCorrectDrift);return K.Bc("static"==q),K.U()&&!isNaN(e.g.availabilityWindowOverride)&&(B=e.g.availabilityWindowOverride),null==B&&(B=1/0),K.pe(B),ee=t.attributes.profiles||"",e.l.profiles=ee.split(","),te={xb:"static"!=q,presentationTimeline:K,oa:null,ka:null,ha:null,J:null,bandwidth:0,pf:!1,Wa:N,Mb:null,profiles:ee.split(","),roles:null,ob:function(){return""}},e.M=0,ne=fp(e,te,R,t,!1),ie=ne.duration,re=ne.periods,("static"!=q||e.Y)&&ne.ug||K.bb(ie||1/0),e.ga&&!e.H&&e.j.isAutoLowLatencyMode()&&(e.j.enableLowLatencyMode(),e.H=e.j.isLowLatencyMode()),e.H&&K.dh(e.da),K.Bf(G||1),M(ue,p,2);case 2:return e.H&&(U=0,ae=null!=z?z:e.g.defaultPresentationDelay,K.Sf(ae)),e.i?(e.i.periodCount=re.length,e.i.gapCount=e.M,M(ue,op(e,re,!1),4)):M(ue,e.m.Ne(re,te.xb),6);case 6:if(e.i={presentationTimeline:K,variants:e.m.l,textStreams:e.m.mf(),imageStreams:e.m.i,offlineSessionIds:[],minBufferTime:U||0,sequenceMode:e.g.dash.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,type:"DASH",serviceDescription:hp(t),nextUrl:mp(t),periodCount:re.length,gapCount:e.M,isLowLatency:e.ga,startTime:null},!K.qh()){ue.u(7);break}return se=Ct(t,"UTCTiming"),M(ue,function(e,t,n){var i,r,a,s,o,u,l,c;return I((function(h){switch(h.g){case 1:i=n.map((function(e){return{scheme:e.attributes.schemeIdUri,value:e.attributes.value}})),r=e.g.dash.clockSyncUri,!i.length&&r&&i.push({scheme:"urn:mpeg:dash:utc:http-head:2014",value:r}),a=d(i),s=a.next();case 2:if(s.done){h.u(4);break}switch(o=s.value,b(h,5),u=o.scheme,l=o.value,u){case"urn:mpeg:dash:utc:http-head:2014":case"urn:mpeg:dash:utc:http-head:2012":return h.u(7);case"urn:mpeg:dash:utc:http-xsdate:2014":case"urn:mpeg:dash:utc:http-iso:2014":case"urn:mpeg:dash:utc:http-xsdate:2012":case"urn:mpeg:dash:utc:http-iso:2012":return h.u(8);case"urn:mpeg:dash:utc:direct:2014":case"urn:mpeg:dash:utc:direct:2012":return c=Date.parse(l),h.return(isNaN(c)?0:c-Date.now());case"urn:mpeg:dash:utc:http-ntp:2014":case"urn:mpeg:dash:utc:ntp:2014":case"urn:mpeg:dash:utc:sntp:2014":$("NTP UTCTiming scheme is not supported");break;default:$("Unrecognized scheme in UTCTiming element",u)}h.u(9);break;case 7:return M(h,wp(e,t,l,"HEAD"),10);case 10:return h.return(h.h);case 8:return M(h,wp(e,t,l,"GET"),11);case 11:return h.return(h.h);case 9:L(h,3);break;case 5:S(h);case 3:s=a.next(),h.u(2);break;case 4:return $("A UTCTiming element should always be given in live manifests! This content may not play on clients with bad clocks!"),h.return(0)}}))}(e,R,se),8);case 8:if(oe=ue.h,!e.j)return ue.return();K.eh(oe);case 7:K.Xd();case 4:e.j.makeTextStreamsForClosedCaptions(e.i),function(e){for(var t=Object.keys(e.B).filter((function(t){return!e.C.includes(t)})),n=(t=d(t)).next();!n.done;n=t.next()){n=n.value;for(var i=!0,r=d(e.B[n]),a=r.next();!a.done;a=r.next()){a=a.value;var s=e.o[a];s&&(s.segmentIndex&&0!=s.segmentIndex.getNumReferences()?i=!1:(e.m&&e.m.sg(e.o[a],n),delete e.o[a]))}i&&delete e.B[n]}}(e),w(ue)}}))}function op(e,t,n){var i;return I((function(r){if(1==r.g)return M(r,e.m.Ne(t,!0,n),2);e.i.variants=e.m.l,0<(i=e.m.mf()).length&&(e.i.textStreams=i),e.i.imageStreams=e.m.i,e.j.filter(e.i),w(r)}))}function up(e,t){return fp(e,{xb:"dynamic"==e.l.type,presentationTimeline:e.i.presentationTimeline,oa:null,ka:null,ha:null,J:null,bandwidth:0,pf:!1,Wa:e.l.Wa,profiles:e.l.profiles,Mb:e.l.Mb,roles:null,ob:function(){return""}},e.l.Oa,t,!0).periods}function dp(e,t){e.i.periodCount--;for(var n=d(e.s.keys()),i=n.next();!i.done;i=n.next())(i=i.value).startsWith(t)&&(qm(e.s.get(i),cf,"SegmentTimeline").children=[],cp(e,i),e.s.delete(i));e.C=e.C.filter((function(e){return e!==t}))}function lp(e,t){for(var n="",i="",r=-1,a="",s=(t=d(t)).next();!s.done;s=t.next())"Period"===(s=s.value).name?n=s.id:"AdaptationSet"===s.name?(i=s.id,null!==s.position&&(r=s.position)):"Representation"===s.name&&(a=s.id);if(t=[],a)t.push(n+","+a);else if(i)for(r=d(e.s.values()),e=r.next();!e.done;e=r.next())(e=e.value).oa.id===n&&e.ha.id===i&&e.J.id&&t.push(n+","+e.J.id);else if(-1<r)for(i=d(e.s.values()),e=i.next();!e.done;e=i.next())(e=e.value).oa.id===n&&e.ha.position===r&&e.J.id&&t.push(n+","+e.J.id);return t}function cp(e,t){var n=e.s.get(t),i=e.o[t];i.segmentIndex&&i.segmentIndex.Ha(e.i.presentationTimeline.qb());try{var r=lf(n,(function(t,n,i,r){return Tp(e,t,n,i,r)}),e.o,!0,e.g.dash.initialSegmentLimit,e.ja,n.J.aesKey,null,!0);i.createSegmentIndex=function(){return I((function(e){if(1==e.g)return i.segmentIndex?e.u(0):M(e,r.nc(),3);i.segmentIndex=e.h,w(e)}))}}catch(e){if((t=n.J.contentType)!=_i&&"application"!=t&&"image"!=t||4002!=e.code)throw e}}function hp(e){var t=Nt(e,"ServiceDescription");if(!t)return null;if(e=Nt(t,"Latency"),t=Nt(t,"PlaybackRate"),!e&&!t)return null;var n={};return e&&("target"in e.attributes&&(n.targetLatency=parseInt(e.attributes.target,10)/1e3),"max"in e.attributes&&(n.maxLatency=parseInt(e.attributes.max,10)/1e3),"min"in e.attributes&&(n.minLatency=parseInt(e.attributes.min,10)/1e3)),t&&("max"in t.attributes&&(n.maxPlaybackRate=parseFloat(t.attributes.max)),"min"in t.attributes&&(n.minPlaybackRate=parseFloat(t.attributes.min))),n}function mp(e){if(!(e=Ct(e,"SupplementalProperty")).length)return null;for(var t=(e=d(e)).next();!t.done;t=e.next())if("urn:mpeg:dash:chaining:2016"==(t=t.value).attributes.schemeIdUri)return t.attributes.value;return null}function fp(e,t,n,i,r){var a=t.Mb;a||(a=Ut(i,"mediaPresentationDuration",Vt),e.l.Mb=a);var s=0;e.i&&e.i.presentationTimeline&&e.Y&&(s=e.i.presentationTimeline.Kb());var o=[],u=s;i=Ct(i,"Period");for(var l=0;l<i.length;l++){var c=i[l],h=i[l+1],m=Ut(c,"start",Vt,u),f=c.attributes.id,p=Ut(c,"duration",Vt);m=0==l&&0==m&&e.Y?s:m;var g=null;if(h){var y=Ut(h,"start",Vt);null!=y&&(g=y-m+s)}else null!=a&&(g=a-m+s);if(y=Mi,g&&p&&Math.abs(g-p)>y&&g>p&&e.M++,null==g&&(g=p),!(null!==e.O&&null!==f&&null!==m&&m<e.O)||e.C.includes(f)||l+1==i.length){if(null!==m&&(null===e.O||m>e.O)&&(e.O=m),u=pp(e,t,n,{start:m,duration:g,node:c,uf:null==g||!h}),o.push(u),t.oa.id&&g&&(e.ja[t.oa.id]=g),null==g){u=null;break}u=m+g}}if(r)for(n=(t=d(o)).next();!n.done;n=t.next())n=n.value.id,e.C.includes(n)||e.C.push(n);else e.C=o.map((function(e){return e.id}));return null!=a?{periods:o,duration:a+s,ug:!1}:{periods:o,duration:u,ug:!0}}function pp(t,n,i,r){n.oa=Mp(t,r.node,null,i),n.ka=r,n.oa.Wa=n.Wa,n.oa.id||(n.oa.id="__shaka_period_"+r.start);var a=Ct(r.node,"EventStream");i=n.presentationTimeline.qb();for(var s=(a=d(a)).next();!s.done;s=a.next())bp(t,r.start,r.duration,s.value,i);for(a=(i=d(i=Ct(r.node,"SupplementalProperty"))).next();!a.done;a=i.next())"urn:mpeg:dash:urlparam:2014"==(a=a.value).attributes.schemeIdUri&&(a=yp(t,a))&&(n.ob=a);if(i=Ct(r.node,"AdaptationSet").map((function(i,r){return function(t,n,i,r){function a(e){var i=e.attributes["dvb:fontFamily"];e=e.attributes["dvb:url"],i&&e&&(e=hi(n.ha.Oa(),[e],n.ob()),t.j.addFont(i,e[0]))}function s(e){switch(e){case 1:case 5:case 6:case 7:return"srgb";case 9:return"rec2020";case 11:case 12:return"p3"}}function o(e){switch(e){case 1:case 6:case 13:case 14:case 15:return"SDR";case 16:return"PQ";case 18:return"HLG"}}n.ha=Mp(t,r,n.oa,null),n.ha.position=i;var u=!1,c=(i=Ct(r,"Role")).map((function(e){return e.attributes.value})).filter(Wi),h=void 0,m=n.ha.contentType==_i;m&&(h="subtitle");for(var f=(i=d(i)).next();!f.done;f=i.next()){var p=(f=f.value).attributes.schemeIdUri;if(null==p||"urn:mpeg:dash:role:2011"==p)switch(f=f.attributes.value,f){case"main":u=!0;break;case"caption":case"subtitle":h=f}}var g=Ct(r,"EssentialProperty");i=null;var y=!1;f=null,p=!1;for(var _=(g=d(g)).next();!_.done;_=g.next()){var v=(_=_.value).attributes.schemeIdUri;if("http://dashif.org/guidelines/trickmode"==v)i=_.attributes.value;else if("urn:mpeg:mpegB:cicp:TransferCharacteristics"==v)var b=o(parseInt(_.attributes.value,10));else if("urn:mpeg:mpegB:cicp:ColourPrimaries"==v)var T=s(parseInt(_.attributes.value,10));else"urn:mpeg:mpegB:cicp:MatrixCoefficients"!=v&&("urn:mpeg:dash:ssr:2023"==v&&t.g.dash.enableFastSwitching?y=!0:"urn:dvb:dash:fontdownload:2014"==v?a(_):"urn:mpeg:dash:urlparam:2014"==v&&(f=yp(t,_))||(p=!0))}if(p)return null;var L=null;for(g=(p=d(p=Ct(r,"SupplementalProperty"))).next();!g.done;g=p.next())"http://dashif.org/guidelines/last-segment-number"==(_=(g=g.value).attributes.schemeIdUri)?L=parseInt(g.attributes.value,10)-1:"urn:mpeg:mpegB:cicp:TransferCharacteristics"==_?b=o(parseInt(g.attributes.value,10)):"urn:mpeg:mpegB:cicp:ColourPrimaries"==_?T=s(parseInt(g.attributes.value,10)):"urn:dvb:dash:fontdownload:2014"==_?a(g):"urn:mpeg:dash:urlparam:2014"==_&&(f=yp(t,g));f&&(n.ob=f),f=Ct(r,"Accessibility");var S,k=new Map;for(p=(f=d(f)).next();!p.done;p=f.next())if(p=(g=p.value).attributes.schemeIdUri,g=g.attributes.value,"urn:scte:dash:cc:cea-608:2015"!=p||t.g.disableText)if("urn:scte:dash:cc:cea-708:2015"!=p||t.g.disableText)"urn:mpeg:dash:role:2011"==p?null!=g&&(c.push(g),"captions"==g&&(h="caption")):"urn:tva:metadata:cs:AudioPurposeCS:2007"==p&&("1"==g?S="visually impaired":"2"==g&&(S="hard of hearing"));else if(p=1,null!=g)for(_=(g=d(g.split(";"))).next();!_.done;_=g.next()){v=_.value;var D=_=void 0;v.includes("=")?(_="svc"+(v=v.split("="))[0],D=v[1].split(",")[0].split(":").pop()):(_="svc"+p,p++,D=v),k.set(_,Ki(D))}else k.set("svc1","und");else if(p=1,null!=g)for(v=(_=d(g=g.split(";"))).next();!v.done;v=_.next()){D=v.value;var x=v=void 0;D.includes("=")?(v=(D=D.split("="))[0].startsWith("CC")?D[0]:"CC"+D[0],x=D[1]||"und"):(v="CC"+p,2==g.length?p+=2:p++,x=D),k.set(v,Ki(x))}else k.set("CC1","und");var A=Nm(f=Ct(r,"ContentProtection"),t.g.dash.ignoreDrmInfo,t.g.dash.keySystemsByURI),Y=Ki(n.ha.language||"und"),E=n.ha.label;if(r=(f=Ct(r,"Representation")).map((function(i){return(i=function(t,n,i,r,a,s,o,u,d,l,c,h){n.J=Mp(t,l,n.ha,null);var m=n.J.id;if(t.da=Math.min(t.da,n.J.Wa),t.ga=0<t.da,!function(e){var t=e.Yc?1:0;return t+=e.Rb?1:0,0==(t+=e.ec?1:0)?e.contentType==_i||"application"==e.contentType:(1!=t&&(e.Yc&&(e.Rb=null),e.ec=null),!0)}(n.J))return null;var f=n.ka.start;n.bandwidth=Ut(l,"bandwidth",$t)||0,n.roles=u;var p,g,y=Ct(l,"SupplementalProperty"),_=Ct(l,"EssentialProperty"),v=null,b=_.find((function(e){return"urn:mpeg:dash:urlparam:2014"==e.attributes.schemeIdUri}));(b||(b=y.find((function(e){return"urn:mpeg:dash:urlparam:2014"==e.attributes.schemeIdUri}))))&&(v=yp(t,b)),v&&(n.ob=v),v=(b=n.J.contentType)==_i||"application"==b,b="image"==b;try{var T=void 0;if(i.Je){var L=n.J.Oa,S=n.ob,k=aa(hi(L(),[i.Je.wi],S()),t.g.retryParameters);T={bitsKey:128,blockCipherMode:"CBC",iv:i.Je.iv,firstMediaSequenceNumber:0,fetchKey:function(){var n,i,r;return I((function(a){if(1==a.g)return M(a,Sp(t,k,6),2);if(3!=a.g){if(!(n=a.h).data||16!=n.data.byteLength)throw new Ye(2,4,4049);return i={name:"AES-CBC"},r=T,M(a,e.crypto.subtle.importKey("raw",n.data,i,!0,["decrypt"]),3)}r.cryptoKey=a.h,T.fetchKey=void 0,w(a)}))}}}if(n.J.aesKey=T,L=function(e,n,i,r){return Tp(t,e,n,i,r)},n.J.Yc)var D=function(e,t,n){var i=Number(Gm(e,af,"presentationTimeOffset"))||0,r=Gm(e,af,"timescale"),a=1;r&&(a=$t(r)||1);var s=i/a||0,o=nf(e,af,n);!function(e,t){if(of(e,t),!sf(e))throw new Ye(2,4,4002)}(e,o);var u=Dt(e);return{nc:function(){var e=qm(u,af,"RepresentationIndex"),n=u.J.Oa();return e&&(e=yt(e.attributes.sourceURL))&&(n=hi(n,[e],u.ob())),e=sf(u),rf(u,t,o,n,e.start,e.end,s)}}}(n,L,T);else if(n.J.Rb)D=function(e,t,n){var i=nf(e,df,n),r=function(e){var t=function(e){return[e.J.Rb,e.ha.Rb,e.oa.Rb].filter(Wi).map((function(e){return Ct(e,"SegmentURL")})).reduce((function(e,t){return 0<e.length?e:t})).map((function(t){return t.attributes.indexRange&&!e.pf&&(e.pf=!0),{Ci:yt(t.attributes.media),start:(t=Ut(t,"mediaRange",Gt,{start:0,end:null})).start,end:t.end}}))}(e),n=(e=zm(e,df)).zd;0==n&&(n=1);var i=0;return e.Qa?i=e.Qa*(n-1):e.timeline&&0<e.timeline.length&&(i=e.timeline[0].start),{Qa:e.Qa,startTime:i,zd:n,Pb:e.Pb,timeline:e.timeline,Rc:t}}(e);if(!r.Qa&&!r.timeline&&1<r.Rc.length)throw new Ye(2,4,4002);if(!r.Qa&&!e.ka.duration&&!r.timeline&&1==r.Rc.length)throw new Ye(2,4,4002);if(r.timeline&&0==r.timeline.length)throw new Ye(2,4,4002);var a=null,s=null;e.oa.id&&e.J.id&&(s=t[e.oa.id+","+e.J.id])&&(a=s.segmentIndex);var o=function(e,t,n,i,r,a,s,o,u,d){var l=i.Rc.length;i.timeline&&i.timeline.length!=i.Rc.length&&(l=Math.min(i.timeline.length,i.Rc.length));for(var c=e-i.Pb,h=t?e+t:1/0,m=[],f=i.startTime,p={},g=0;g<l;p={ve:void 0,ne:void 0},g++){p.ne=i.Rc[g];var y=f;f=void 0,f=null!=i.Qa?y+i.Qa:i.timeline?i.timeline[g].end:y+t,p.ve=null,(p=new gs(e+y,e+f,function(e){return function(){return null==e.ve&&(e.ve=hi(n(),[e.ne.Ci],d())),e.ve}}(p),p.ne.start,p.ne.end,r,c,e,h,[],"",null,null,_s,a)).codecs=o,p.mimeType=s,p.bandwidth=u,m.push(p)}return m}(e.ka.start,e.ka.duration,e.J.Oa,r,i,n,e.J.mimeType,e.J.codecs,e.bandwidth,e.ob);return t=!a,a?a.td(o,e.presentationTimeline.qb()):a=new Zo(o),e.presentationTimeline.vd(o),e.xb&&e.ka.uf||a.Kc(e.ka.start,e.ka.duration?e.ka.start+e.ka.duration:1/0,t),s&&(s.segmentIndex=a),{nc:function(){return a&&0!=a.getNumReferences()||a.Zd(o),Promise.resolve(a)}}}(n,t.o,T);else if(n.J.ec)D=lf(n,L,t.o,!!t.i,t.g.dash.initialSegmentLimit,t.ja,T,h,!1);else{var x=n.ka.duration||0,A=n.J.Oa,Y=n.J.mimeType,E=n.J.codecs;D={nc:function(){var e=tu(f,x,A());return e.yb((function(e){e.mimeType=Y,e.codecs=E})),Promise.resolve(e)}}}}catch(e){if((v||b)&&4002==e.code)return null;throw e}if(l=function(e,t,n,i){var r=Nm(e,n,i);if(t.wg)e=1==t.drmInfos.length&&!t.drmInfos[0].keySystem,n=0==r.drmInfos.length,(0==t.drmInfos.length||e&&!n)&&(t.drmInfos=r.drmInfos),t.wg=!1;else if(0<r.drmInfos.length&&(t.drmInfos=t.drmInfos.filter((function(e){return r.drmInfos.some((function(t){return t.keySystem==e.keySystem}))})),0==t.drmInfos.length))throw new Ye(2,4,4008);return r.rg||t.rg}(l=Ct(l,"ContentProtection"),i,t.g.dash.ignoreDrmInfo,t.g.dash.keySystemsByURI),l=new Set(l?[l]:[]),h=!1,y.some((function(e){return"tag:dolby.com,2018:dash:EC3_ExtensionType:2018"==e.attributes.schemeIdUri&&"JOC"==e.attributes.value}))&&(h=!0),y=!1,v&&(y=u.includes("forced_subtitle")||u.includes("forced-subtitle")),b&&((_=_.find((function(e){return["http://dashif.org/thumbnail_tile","http://dashif.org/guidelines/thumbnail_tile"].includes(e.attributes.schemeIdUri)})))&&(p=_.attributes.value),!p))return null;v=n.J.codecs,n.profiles.includes("http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10")&&(v.includes("hvc1.2.4.L153.B0")||v.includes("hev1.2.4.L153.B0"))&&(g="PQ"),_=n.J.id?n.oa.id+","+n.J.id:"",t.F.length&&m&&t.s.set(n.oa.id+","+m,function(e){function t(e){return e?((e=Dt(e)).Yc=null,e.Rb=null,e.ec=an(e.ec),e):null}return(e=Dt(e)).oa=t(e.oa),e.ha=t(e.ha),e.J=t(e.J),e.ka&&(e.ka=Dt(e.ka),e.ka.node=null),e}(n));var P=_&&t.o[_]?t.o[_]:{id:t.na++,originalId:n.J.id,groupId:null,createSegmentIndex:function(){return Promise.resolve()},closeSegmentIndex:function(){P.segmentIndex&&(P.segmentIndex.release(),P.segmentIndex=null)},segmentIndex:null,mimeType:n.J.mimeType,codecs:v,frameRate:n.J.frameRate,pixelAspectRatio:n.J.pixelAspectRatio,bandwidth:n.bandwidth,width:n.J.width,height:n.J.height,kind:r,encrypted:0<i.drmInfos.length,drmInfos:i.drmInfos,keyIds:l,language:a,originalLanguage:n.ha.language,label:s,type:n.ha.contentType,primary:o,trickModeVideo:null,emsgSchemeIdUris:n.J.emsgSchemeIdUris,roles:u,forced:y,channelsCount:n.J.ce,audioSamplingRate:n.J.audioSamplingRate,spatialAudio:h,closedCaptions:d,hdr:g,colorGamut:void 0,videoLayout:void 0,tilesLayout:p,accessibilityPurpose:c,external:!1,fastSwitching:!1,fullMimeTypes:new Set([Ti(n.J.mimeType,n.J.codecs)]),isAudioMuxedInVideo:!1};return P.createSegmentIndex=function(){var e;return I((function(t){if(1==t.g)return P.segmentIndex?t.u(0):(e=P,M(t,D.nc(),3));e.segmentIndex=t.h,w(t)}))},_&&n.xb&&!t.o[_]&&(n=n.oa.id||"",t.B[n]||(t.B[n]=[]),t.o[_]=P,t.B[n].push(_)),P}(t,n,A,h,Y,E,u,c,k,i,S,L))&&(i.hdr=i.hdr||b,i.colorGamut=i.colorGamut||T,i.fastSwitching=y),i})).filter((function(e){return!!e})),0==r.length){if(i="image"==n.ha.contentType,t.g.dash.ignoreEmptyAdaptationSet||m||i)return null;throw new Ye(2,4,4003)}if(!n.ha.contentType||"application"==n.ha.contentType)for(n.ha.contentType=Lp(r[0].mimeType,r[0].codecs),p=(m=d(r)).next();!p.done;p=m.next())p.value.type=n.ha.contentType;for(m=n.ha.id||"__fake__"+t.na++,g=(p=d(r)).next();!g.done;g=p.next()){for(g=g.value,v=(_=d(A.drmInfos)).next();!v.done;v=_.next())(v=v.value).keyIds=v.keyIds&&g.keyIds?new Set([].concat(l(v.keyIds),l(g.keyIds))):v.keyIds||g.keyIds;g.groupId=m}return f=f.map((function(e){return e.attributes.id})).filter(Wi),{id:m,contentType:n.ha.contentType,language:Y,lk:u,streams:r,drmInfos:A.drmInfos,bg:i,Qi:f}}(t,n,r,i)})).filter(Wi),n.xb){for(r=[],s=(a=d(i)).next();!s.done;s=a.next())for(var o=(s=d(s.value.Qi)).next();!o.done;o=s.next())r.push(o.value);if(r.length!=new Set(r).size)throw new Ye(2,4,4018)}if(r=i.filter((function(e){return!e.bg})),i=i.filter((function(e){return e.bg})),!t.g.disableIFrames)for(a=(i=d(i)).next();!a.done;a=i.next()){s=(a=a.value).bg.split(" ");for(var u=(o=d(r)).next();!u.done;u=o.next())if(u=u.value,s.includes(u.id))for(var c=(u=d(u.streams)).next();!c.done;c=u.next())br(c.value,a.streams)}if(i=gp(t.g.disableAudio,r,"audio"),a=gp(t.g.disableVideo,r,"video"),s=gp(t.g.disableText,r,_i),r=gp(t.g.disableThumbnails,r,"image"),0===a.length&&0===i.length)throw new Ye(2,4,4004);return{id:n.oa.id,audioStreams:i,videoStreams:a,textStreams:s,imageStreams:r}}function gp(e,t,n){return e||!t.length?[]:t.reduce((function(e,t){return t.contentType!=n||e.push.apply(e,l(t.streams)),e}),[])}function yp(e,t){if((t=Ht(t,"urn:mpeg:dash:schema:urlparam:2014","UrlQueryInfo"))&&Ut(t,"useMPDUrlQuery",Xt,!1)){var n=t.attributes.queryTemplate;if(n)return function(){return"$querypart$"==n?e.aa:n.split("&").map((function(t){if("$querypart$"==t)return e.aa;var n=/\$query:(.*?)\$/g.exec(t);if(n&&2==n.length){n=n[1];var i=new ni(e.aa).get(n);if(i.length)return n+"="+i[0]}return t})).join("&")}}return null}function _p(e){var t,n;return I((function(i){switch(i.g){case 1:return t=0,b(i,2),M(i,ap(e),4);case 4:t=i.h,L(i,3);break;case 2:if(n=S(i),e.j){if(e.g.raiseFatalErrorOnManifestUpdateRequestFailure)return e.j.onError(n),i.return();n.severity=1,e.j.onError(n)}case 3:if(!e.j)return i.return();e.j.onManifestUpdated(),vp(e,t),w(i)}}))}function vp(e,t){if(!(0>e.K)){var n=e.K;0<=e.g.dash.updatePeriod&&(n=e.g.dash.updatePeriod),e.L.$(Math.max(n-t,z(e.ra)))}}function Mp(e,t,n,i){n=n||{contentType:"",mimeType:"",codecs:"",emsgSchemeIdUris:[],frameRate:void 0,pixelAspectRatio:void 0,ce:null,audioSamplingRate:null,Wa:0,oe:0},i=i||n.Oa;var r,a=t.attributes.id,s=Ct(t,"BaseURL"),o=!1;if(e.h)for(var u=d(s),l=u.next();!l.done;l=u.next()){var c=l.value;l=c.attributes.serviceLocation,c=Ot(c),l&&c&&(vf(e.h,a,l,c),o=!0)}o&&e.h||(r=s.map(Ot)),u=t.attributes.contentType||n.contentType,l=t.attributes.mimeType||n.mimeType,c=[t.attributes.codecs||n.codecs];var h=Ft(t,"urn:scte:dash:scte214-extensions","supplementalCodecs");h&&c.push(h),c=Au(c).join(","),h=Ut(t,"frameRate",Qt)||n.frameRate;var m=t.attributes.sar||n.pixelAspectRatio,f=function(e,t){t=t.slice();for(var n=(e=d(e)).next();!n.done;n=e.next())n=n.value.attributes.schemeIdUri,t.includes(n)||t.push(n);return t}(Ct(t,"InbandEventStream"),n.emsgSchemeIdUris),p=Ct(t,"AudioChannelConfiguration");p=function(e){for(var t=(e=d(e)).next();!t.done;t=e.next()){var n=(t=t.value).attributes.schemeIdUri;if(n&&(t=t.attributes.value))switch(n){case"urn:mpeg:dash:outputChannelPositionList:2012":return t.trim().split(/ +/).length;case"urn:mpeg:dash:23003:3:audio_channel_configuration:2011":case"urn:dts:dash:audio_channel_configuration:2012":if(!(t=parseInt(t,10)))continue;return t;case"tag:dolby.com,2015:dash:audio_channel_configuration:2015":if(n=[2,1,2,2,2,2,1,2,2,1,1,1,1,2,1,1,2,2],!(t=parseInt(t,16)))continue;for(var i=0,r=0;r<n.length;r++)t&1<<r&&(i+=n[r]);if(i)return i;continue;case"tag:dolby.com,2014:dash:audio_channel_configuration:2011":case"urn:dolby:dash:audio_channel_configuration:2011":if(n=[1,1,1,1,1,2,2,1,1,2,2,2,1,2,1,1].reverse(),!(t=parseInt(t,16)))continue;for(r=i=0;r<n.length;r++)t&1<<r&&(i+=n[r]);if(i)return i;continue;case"urn:mpeg:mpegB:cicp:ChannelConfiguration":if(n=[0,1,2,3,4,5,6,8,2,3,4,7,8,24,8,12,10,12,14,12,14],(t=parseInt(t,10))&&0<t&&t<n.length)return n[t]}}return null}(p)||n.ce;var g=Ut(t,"audioSamplingRate",Kt)||n.audioSamplingRate;u||(u=Lp(l,c));var y=Nt(t,"SegmentBase"),_=Nt(t,"SegmentTemplate"),v=y&&Ut(y,"availabilityTimeOffset",Jt)||0,M=_&&Ut(_,"availabilityTimeOffset",Jt)||0,w=s&&s.length&&Ut(s[0],"availabilityTimeOffset",Jt)||0;v=n.Wa+w+v+M,M=null,(w=Nt(t,"SegmentSequenceProperties"))&&(w=Nt(w,"SAP"))&&(M=Ut(w,"cadence",qt)),w=t.attributes.label;var b=Ct(t,"Label");return b&&b.length&&jt(b=b[0])&&(w=jt(b)),{Oa:function(){return hi(i(),s.length?e.h&&o?Mf(e.h,a):r||[]:[])},Yc:y||n.Yc,Rb:Nt(t,"SegmentList")||n.Rb,ec:_||n.ec,width:Ut(t,"width",Kt)||n.width,height:Ut(t,"height",Kt)||n.height,contentType:u,mimeType:l,codecs:c,frameRate:h,pixelAspectRatio:m,emsgSchemeIdUris:f,id:a,language:t.attributes.lang,ce:p,audioSamplingRate:g,Wa:v,Ud:null,oe:M||n.oe,label:w||null}}function wp(e,t,n,i){var r,a,s,o,u,d,l;return I((function(c){if(1==c.g)return r=[yt(n)],a=hi(t(),r),(s=aa(a,e.g.retryParameters)).method=i,o=e.j.networkingEngine.request(4,s,{isPreload:e.fa()}),ta(e.S,o),M(c,o.promise,2);if(u=c.h,"HEAD"==i){if(!u.headers||!u.headers.date)return c.return(0);d=u.headers.date}else d=ct(u.data);return l=Date.parse(d),isNaN(l)?c.return(0):c.return(l-Date.now())}))}function bp(e,t,n,i,r){for(var a=i.attributes.schemeIdUri||"",s=i.attributes.value||"",o=Ut(i,"timescale",Kt)||1,u=Ut(i,"presentationTimeOffset",Kt)||0,l=(i=d(Ct(i,"Event"))).next();!l.done;l=i.next()){var c=Ut(l=l.value,"presentationTime",Kt)||0,h=Ut(l,"duration",Kt)||0;h=(c=Math.max((c-u)/o+t,t))+h/o,null!=n&&(c=Math.min(c,t+n),h=Math.min(h,t+n)),h<r||(l={schemeIdUri:a,value:s,startTime:c,endTime:h,id:l.attributes.id||"",eventElement:rn(l),eventNode:an(l)},e.j.onTimelineRegionAdded(l))}}function Tp(e,t,n,i,r){var a,s,o,u;return I((function(d){return 1==d.g?(a=la,s=r?0:1,o=Eu(t,n,i,e.g.retryParameters),M(d,Sp(e,o,a,{type:s}),2)):(u=d.h,d.return(u.data))}))}function Lp(e,t){return Ri(t=Ti(e,t))?_i:e.split("/")[0]}function Sp(e,t,n,i){return i||(i={}),i.isPreload=e.fa(),t=e.j.networkingEngine.request(n,t,i),ta(e.S,t),t.promise}function kp(){}(i=rp.prototype).configure=function(e,t){var n=this.j&&e.dash.updatePeriod!=this.g.dash.updatePeriod&&0<=e.dash.updatePeriod;this.g=e,t&&(this.fa=t),n&&this.i&&this.i.presentationTimeline.U()&&this.L.hc(),this.h&&this.h.configure(this.g),this.m&&(this.m.bh(this.g.dash.multiTypeVariantsAllowed&&ie()),this.m.ih(this.g.dash.useStreamOnceInPeriodFlattening))},i.start=function(e,t){var n,i=this;return I((function(r){if(1==r.g)return i.H=t.isLowLatencyMode(),i.A=[e],i.j=t,M(r,ap(i),2);if(n=r.h,i.j&&vp(i,n),!i.j)throw new Ye(2,7,7001);return r.return(i.i)}))},i.stop=function(){for(var e=d(Object.values(this.o)),t=e.next();!t.done;t=e.next())(t=t.value).segmentIndex&&t.segmentIndex.release();return this.m&&this.m.release(),this.g=this.j=null,this.A=[],this.i=null,this.o={},this.B={},this.s.clear(),this.l={ae:"",type:"",profiles:[],Mb:null,Wa:0,Oa:null,xd:0},this.m=null,null!=this.L&&(this.L.stop(),this.L=null),this.h&&this.h.destroy(),this.G&&(this.G.release(),this.G=null),this.S.destroy()},i.update=function(){var e,t=this;return I((function(n){return 1==n.g?(b(n,2),M(n,ap(t),4)):2!=n.g?L(n,0):(e=S(n),t.j&&e?(t.j.onError(e),void w(n)):n.return())}))},i.onExpirationUpdated=function(){},i.onInitialVariantChosen=function(e){if(this.i&&this.i.presentationTimeline.U()){var t=e.video||e.audio;if(t&&t.segmentIndex){e=this.i.presentationTimeline.Yb();var n=t.segmentIndex.find(e);null!=n&&(t=t.segmentIndex.get(n))&&(this.K=t.endTime-e,vp(this,0))}}},i.banLocation=function(e){this.h&&this.h.banLocation(e)},i.setMediaElement=function(e){this.I=e},U("shaka.dash.DashParser",rp),ls["application/dash+xml"]=function(){return new rp},ls["video/vnd.mpeg.dash.mpd"]=function(){return new rp},U("shaka.dependencies",kp),kp.has=function(e){return Ap.has(e)},kp.add=function(e,t){if(!xp[e])throw Error(e+" is not supported");e==Dp?se("mux.js","mux.js is no longer used in Shaka Player."):Ap.set(e,(function(){return t}))};var Dp="muxjs",xp={mk:Dp,ISOBoxer:"ISOBoxer"};kp.Allowed=xp;var Ap=new Map([["ISOBoxer",function(){return e.ISOBoxer}]]);function Yp(e,t,n){this.type=e,this.X=t,this.segments=n||null}function Ep(e,t,n,i){this.id=e,this.name=t,this.attributes=n,this.value=void 0===i?null:i}function Ip(e,t){return t?e.toString():(t=(new Set).add("AUDIO").add("VIDEO").add("SUBTITLES").add("PATHWAY-ID").add("GROUP-ID").add("URI"),e.toString(t))}function Pp(e,t){return(e=e.attributes.filter((function(e){return e.name==t}))).length?e[0]:null}function Cp(e,t,n){return(e=Pp(e,t))?e.value:n||null}function jp(e,t){if(!(e=Pp(e,t)))throw new Ye(2,4,4023,t);return e.value}function Op(e,t,n){n=void 0===n?[]:n,this.X=t,this.g=e,this.Cb=n}function Rp(e,t){this.name=e,this.value=t}function Np(e,t){return e.filter((function(e){return e.name==t}))}function Hp(e,t){return e.filter((function(e){return jp(e,"TYPE")==t}))}function Up(e,t){for(var n=(e=d(e)).next();!n.done;n=e.next())if((n=n.value).name===t)return n;return null}function Fp(e,t,n){return n=void 0===n?0:n,(e=Up(e,t))?Number(e.value):n}function Bp(e,t,n){return t?Wp(e,[t],n):[]}function Wp(e,t,n){if(!t.length)return[];t=hi(e,t),e=[];for(var i=(t=d(t)).next();!i.done;i=t.next())e.push(zp(i.value,n));return e}function zp(e,t){if(!t||!t.size)return e;var n=(e=String(e).replace(/%7B/g,"{").replace(/%7D/g,"}")).match(/{\$\w*}/g);if(n)for(var i=(n=d(n)).next();!i.done;i=n.next()){var r=(i=i.value).slice(2,i.length-1),a=t.get(r);if(!a)throw new Ye(2,4,4039,r);e=e.replace(i,a)}return e}function Vp(){this.g=0}function Gp(e,t){var n=(t=(t=ct(t)).replace(/\r\n|\r(?=[^\n]|$)/gm,"\n").trim()).split(/\n+/m);if(!/^#EXTM3U($|[ \t\n])/m.test(n[0]))throw new Ye(2,4,4015);t=0;for(var i=!0,r=d(n),a=r.next();!a.done;a=r.next())if(a=a.value,/^#(?!EXT)/m.test(a)||i)i=!1;else{if(a=qp(e,a),--e.g,$p.includes(a.name)){t=1;break}"EXT-X-STREAM-INF"==a.name&&(i=!0)}for(r=[],i=!0,a=0;a<n.length;a++){var s=n[a],o=n[a+1];if(/^#(?!EXT)/m.test(s)||i)i=!1;else{if(s=qp(e,s),Kp.includes(s.name)){if(1!=t)throw new Ye(2,4,4017);s=n.splice(a,n.length-a),n=[],i=[],a=[],o=null;for(var u=(s=d(s)).next();!u.done;u=s.next())u=u.value,/^(#EXT)/.test(u)?(u=qp(e,u),$p.includes(u.name)?r.push(u):"EXT-X-MAP"==u.name?o=u:"EXT-X-PART"==u.name?a.push(u):"EXT-X-PRELOAD-HINT"==u.name?"PART"==Cp(u,"TYPE")?a.push(u):"MAP"==Cp(u,"TYPE")&&(u.name="EXT-X-MAP",o=u):i.push(u)):/^#(?!EXT)/m.test(u)||(u=u.trim(),o&&i.push(o),n.push(new Op(u,i,a)),i=[],a=[]);return a.length&&(o&&i.push(o),n.push(new Op("",i,a))),new Yp(t,r,n)}r.push(s),"EXT-X-STREAM-INF"==s.name&&(s.attributes.push(new Rp("URI",o)),i=!0)}}return new Yp(t,r)}function qp(e,t){e=e.g++;var n=t.match(/^#(EXT[^:]*)(?::(.*))?$/);if(!n)throw new Ye(2,4,4016,t);t=n[1];var i,r=n[2];if(n=[],r){var a;(a=wt(r=new vt(r),/^([^,=]+)(?:,|$)/g))&&(i=a[1]);for(var s=/([^=]+)=(?:"([^"]*)"|([^",]*))(?:,|$)/g;a=wt(r,s);)n.push(new Rp(a[1],a[2]||a[3])),Mt(r)}return new Ep(e,t,n,i)}Ep.prototype.toString=function(e){var t="#"+this.name,n=this.attributes?this.attributes.filter((function(t){return!e||!e.has(t.name)})).map((function(e){return e.name+"="+(isNaN(Number(e.value))?'"'+e.value+'"':e.value)})):[];return this.value&&n.unshift(this.value),0<n.length&&(t+=":"+n.join(",")),t};var $p="EXT-X-TARGETDURATION EXT-X-MEDIA-SEQUENCE EXT-X-DISCONTINUITY-SEQUENCE EXT-X-PLAYLIST-TYPE EXT-X-I-FRAMES-ONLY EXT-X-ENDLIST EXT-X-SERVER-CONTROL EXT-X-SKIP EXT-X-PART-INF EXT-X-DATERANGE".split(" "),Kp="EXTINF EXT-X-BYTERANGE EXT-X-DISCONTINUITY EXT-X-PROGRAM-DATE-TIME EXT-X-KEY EXT-X-DATERANGE EXT-X-MAP EXT-X-GAP".split(" ");function Jp(){}function Xp(e){try{var t=Qp(e);return qr({uri:e,originalUri:e,data:t.data,headers:{"content-type":t.contentType}})}catch(e){return Vr(e)}}function Qp(t){var n=t.split(":");if(2>n.length||"data"!=n[0])throw new Ye(2,1,1004,t);if(2>(n=n.slice(1).join(":").split(",")).length)throw new Ye(2,1,1004,t);var i=n[0];t=e.decodeURIComponent(n.slice(1).join(",")),n=i.split(";"),i=n[0];var r=!1;return 1<n.length&&"base64"==n[n.length-1]&&(r=!0,n.pop()),{data:r?ui(t):ft(t),contentType:i}}function Zp(){var e=this;this.g=this.h=null,this.C=1,this.A=new Map,this.H=new Map,this.O=new Map,this.O.set("video",new Map),this.O.set("audio",new Map),this.O.set(_i,new Map),this.O.set("image",new Map),this.Na=new Set,this.i=new Map,this.l=null,this.M="",this.Ka=new Vp,this.I=-1,this.ga=1/0,this.fa=this.ac=this.bc=!1,this.B=new He((function(){e.aa&&!e.g.continueLoadingWhenPaused&&(e.Z.cb(e.aa,"timeupdate"),e.aa.paused)?e.Z.pa(e.aa,"timeupdate",(function(){return jg(e)})):jg(e)})),this.xa=Vg,this.m=null,this.La=0,this.o=1/0,this.Ga=this.Ba=this.Y=0,this.da=new ea,this.F=new Map,this.G=new Map,this.ta=new Map,this.ja=new Map,this.L=new Map,this.ra=new Map,this.na=new Map,this.Ib=this.K=!1,this.Gb=new W(5),this.j=null,this.S=!0,this.Aa=new Set,this.Z=new Z,this.s=this.aa=null,this.Hb=function(){return!1}}function eg(e,t){return Og(e)?e.O.get(t.type):t.Yd}function tg(e,t){var n,i,r,a,s,o,u,c,h,m,f,p,g,y,_,v,T,k,D,x,A,Y,E,P,C,j,O,R,N,H,U,F,B;return I((function(I){switch(I.g){case 1:if(t.stream.isAudioMuxedInVideo)return I.return();for(n=[],i=d(t.N()),r=i.next();!r.done;r=i.next())a=r.value,s=new Wn(a),o=s.g,t.Id&&(0<=t.sb&&o.add("_HLS_msn",String(t.sb)),0<=t.ub&&o.add("_HLS_part",String(t.ub))),t.Jd&&o.add("_HLS_skip","YES"),ri(o)&&qn(s,o),n.push(s.toString());return b(I,2),M(I,Cg(e,n,!0).promise,4);case 4:u=I.h,L(I,3);break;case 2:throw c=S(I),e.h&&e.h.disableStream(t.stream),c;case 3:if(!t.stream.segmentIndex)return I.return();if(1!=(h=Gp(e.Ka,u.data)).type)throw new Ye(2,4,4017);return(m=u.uri)==u.originalUri||t.N().includes(m)||t.Wg.push(m),f=Np(h.X,"EXT-X-DEFINE"),p=ag(e,f,m),g=t.stream,y=eg(e,t),M(I,Mg(e,h,g.mimeType,t.N,p),5);case 5:for(_=I.h,v=_.keyIds,T=_.drmInfos,function(e,t){return e.size===t.size&&[].concat(l(e)).every((function(e){return t.has(e)}))}(g.keyIds,v)||(g.keyIds=v,g.drmInfos=T,e.h.newDrmInfo(g)),k=Ag(e,h,y,p,t.N,t.type),D=k.segments,(x=k.bandwidth)&&(g.bandwidth=x),A=Du(g),Y=d(D),E=Y.next();!E.done;E=Y.next())(P=E.value).ba&&(P.ba.Qc=A);g.segmentIndex.td(D,e.l.qb()),D.length&&(C=Fp(h.X,"EXT-X-MEDIA-SEQUENCE",0),O=(j=Up(h.X,"EXT-X-SKIP"))?Number(Cp(j,"SKIPPED-SEGMENTS")):0,R=_g(C,D),N=R.sb,H=R.ub,t.sb=N+O,t.ub=H,U=y.get(C),g.segmentIndex.Ha(U)),(F=eu(g.segmentIndex))&&(t.xc=F.startTime,B=D[D.length-1],t.Lb=B.endTime),Up(h.X,"EXT-X-ENDLIST")&&(t.kd=!0),Tg(e,h),xg(e,h.X,g.type,p,t.N),w(I)}}))}function ng(e,t,n){n=void 0!==n&&n;for(var i=-1==e.I,r=d(t),a=r.next();!a.done;a=r.next()){var s=(a=a.value).stream.segmentIndex,o=eg(e,a);if(s=eu(s))for(var u=(o=d(o)).next();!u.done;u=o.next()){var l=(u=d(u.value)).next().value;if(u.next().value==s.startTime){i&&(e.I=Math.max(e.I,l)),a.Ue=l;break}}}if(!(0>e.I))for(i=(t=d(t)).next();!i.done;i=t.next())(gg(e,(i=i.value).type)||n)&&(r=i.stream.segmentIndex)&&0<(a=e.I-i.Ue)&&(r.g.splice(0,a),r=eu(r))&&(r=-r.startTime,i.stream.segmentIndex.offset(r),ig(e,i,r))}function ig(e,t,n){t.xc+=n,t.Lb+=n;for(var i=d(e=eg(e,t)),r=i.next();!r.done;r=i.next()){var a=d(r.value);r=a.next().value,a=a.next().value,e.set(r,a+n)}t.N()}function rg(e){if(Og(e)){if(e.xa==qg){for(var t=1/0,n=1/0,i=d(e.i.values()),r=i.next();!r.done;r=i.next())(r=r.value).stream.segmentIndex&&"text"!=r.stream.type&&!r.stream.isAudioMuxedInVideo&&(t=Math.min(t,r.Lb),n=Math.min(n,r.xc));t=t-n||0,isNaN(e.g.availabilityWindowOverride)||(t=e.g.availabilityWindowOverride),e.l.pe(t)}}else e.l.bb(mg(e));if(!e.l.s)for(n=(t=d(e.i.values())).next();!n.done;n=t.next())!(n=n.value).stream.segmentIndex||"audio"!=n.type&&"video"!=n.type||(n=eu(n.stream.segmentIndex))&&n.h&&e.l.fh(n.h);e.l.Xd()}function ag(e,t,n){n=new Wn(n).g;for(var i=new Map,r=(t=d(t)).next();!r.done;r=t.next()){var a=r.value,s=Cp(a,"NAME"),o=Cp(a,"VALUE");r=Cp(a,"QUERYPARAM"),a=Cp(a,"IMPORT"),s&&o&&(i.has(s)||i.set(s,o)),r&&(s=n.get(r)[0])&&!i.has(s)&&i.set(r,s),a&&(r=e.A.get(a))&&i.set(a,r)}return i}function sg(e){var t=new Set([Ti(e.mimeType,e.codecs)]);e.segmentIndex&&e.segmentIndex.yb((function(n){n.mimeType&&t.add(Ti(n.mimeType,e.codecs))})),e.fullMimeTypes=t}function og(e,t,n){for(var i={audio:[],video:[]},r=new Map,a=[],s=!1,o=!1,u=d(t),c=u.next();!c.done;c=u.next()){var h=c.value;c=Cp(h,"AUDIO");var m=Cp(h,"VIDEO"),f=c||m;f&&(a.includes(f)||a.push(f),(h=Cp(h,"PATHWAY-ID"))&&r.set(f,h),c?s=!0:m&&(o=!0))}a.length&&n.length&&function(e,t,n){t=t.filter((function(e){var t=Cp(e,"URI")||"";return"SUBTITLES"!=(e=Cp(e,"TYPE"))&&(""!=t||"AUDIO"==e)}));for(var i={},r=(t=d(t)).next();!r.done;r=t.next()){var a=Ip(r=r.value,!e.j);i[a]?i[a].push(r):i[a]=[r]}for(var s in i)lg(e,i[s],n,!1)}(e,n=n.filter((function(e){return a.includes(jp(e,"GROUP-ID"))})),r),n=(r=a.sort().join(","))&&e.H.has(r)?e.H.get(r):[],s?i.audio.push.apply(i.audio,l(n)):o&&i.video.push.apply(i.video,l(n)),s=!1;var p=t.map((function(e){return jp(e,"URI")}));return c=i.audio.find((function(e){return e&&e.N().find((function(e){return p.includes(e)}))})),n=gi("video",o=ug(e,t[0])),(u=gi("audio",o))&&!n?(c="audio",s=0<i.audio.length):!i.audio.length&&!i.video.length&&u&&n?(c="video",o=[[n,u].join()]):i.audio.length&&c?(c="audio",s=!0):c=i.video.length&&!i.audio.length?"audio":"video",s||(e=function(e,t,n,i){for(var r=e.C++,a=[],s=d(t),o=s.next();!o.done;o=s.next()){var u=o.value;o=jp(u,"URI"),u=Cp(u,"PATHWAY-ID"),e.j&&u&&vf(e.j,r,u,o),a.push(o)}if(s=a.sort().join(","),e.i.has(s))return e.i.get(s);e:{if(t=Cp(t[0],"CLOSED-CAPTIONS"),"video"==i){if(e.g.disableText){e.S=!1,t=null;break e}if(t){if("NONE"!=t){t=e.F.get(t);break e}e.S=!1}else if(!t&&e.F.size)for(t=d(e.F.keys()).next();!t.done;){t=e.F.get(t.value);break e}}t=null}return i=hg(e,r,a,n=pi(i,n),i,null,!1,null,null,t,null,!1,null,!1),e.i.set(s,i),i}(e,t,o,c),r&&(e.stream.groupId=r),i[e.stream.type]=[e]),i}function ug(e,t){var n=Cp(t,"CODECS")||"";return t=Cp(t,"SUPPLEMENTAL-CODECS"),e.fa=0<n.length,e.fa||e.g.hls.disableCodecGuessing||(n=[],e.g.disableVideo||n.push(e.g.hls.defaultVideoCodec),e.g.disableAudio||n.push(e.g.hls.defaultAudioCodec),n=n.join(",")),e=n.split(/\s*,\s*/),t&&(t=t.split(/\s*,\s*/).map((function(e){return e.split("/")[0]})),e.push.apply(e,l(t))),Au(e)}function dg(e,t,n,i,r,a,s,o,u,l,c,h){for(var m=d(n),f=m.next();!f.done;f=m.next())Pg(f.value.stream,r,a,s,o,u,null);for(r=e.g.disableAudio,t.length&&!r||(t=[null]),r=e.g.disableVideo,n.length&&!r||(n=[null]),r=[],a=(t=d(t)).next();!a.done;a=t.next())for(a=a.value,o=(s=d(n)).next();!o.done;o=s.next()){var p=o.value;(o=a?a.stream:null)&&(o.drmInfos=l,o.keyIds=c),(u=p?p.stream:null)&&(u.drmInfos=l,u.keyIds=c,e.g.disableIFrames||br(u,h)),u&&!o&&(u.bandwidth=i),!u&&o&&(o.bandwidth=i),m=a?a.stream.drmInfos:null,f=p?p.stream.drmInfos:null,p=(p=p?p.N().sort().join(","):"")+" - "+(a?a.N().sort().join(","):""),o&&u&&!Pe(m,f)||e.Na.has(p)||(o={id:e.C++,language:o?o.language:"und",disabledUntilTime:0,primary:!!o&&o.primary||!!u&&u.primary,audio:o,video:u,bandwidth:i,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},r.push(o),e.Na.add(p))}return r}function lg(e,t,n,i){i=void 0===i||i;for(var r=[],a=[],s=new Map,o=d(t),u=o.next();!u.done;u=o.next()){var l=u.value;u=i?jp(l,"URI"):Cp(l,"URI")||"shaka://hls-muxed",l=jp(l,"GROUP-ID"),r.push(u),a.push(l),s.set(l,u)}if(i=a.sort().join(","),u=t[0],t="","subtitles"==(o=jp(u,"TYPE").toLowerCase())&&(o=_i),o==_i)t=Cp(u,"CODECS")||"";else for(l=(a=d(a)).next();!l.done;l=a.next())if(l=l.value,e.G.has(l)){t=e.G.get(l);break}if(a=r.sort().join(","),e.i.has(a))return e.i.get(a);if(l=e.C++,e.j)for(var c=(s=d(s)).next();!c.done;c=s.next()){var h=d(c.value);c=h.next().value,h=h.next().value,(c=n.get(c))&&vf(e.j,l,c,h)}n=Cp(u,"LANGUAGE"),s=Cp(u,"NAME"),c="YES"==Cp(u,"DEFAULT"),h="audio"==o&&(h=Cp(u,"CHANNELS"))?parseInt(h.split("/")[0],10):null;var m="audio"==o&&!!(m=Cp(u,"CHANNELS"))&&m.includes("/JOC");return(r=hg(e,l,r,t,o,n,c,s,h,null,Cp(u,"CHARACTERISTICS"),"YES"==Cp(u,"FORCED"),u="audio"==o&&(u=Cp(u,"SAMPLE-RATE"))?parseInt(u,10):null,m)).stream&&(r.stream.groupId=i),e.H.has(i)?e.H.get(i).push(r):e.H.set(i,[r]),e.i.set(a,r),r}function cg(e,t){var n="video",i=jp(t,"URI"),r=Cp(t,"CODECS")||"";if("mjpg"==r&&(n="image"),e.i.has(i))return e.i.get(i);var a=Cp(t,"LANGUAGE"),s=Cp(t,"NAME"),o=Cp(t,"CHARACTERISTICS");return n=hg(e,e.C++,[i],r,n,a,!1,s,null,null,o,!1,null,!1),a=d((r=Cp(t,"RESOLUTION"))?r.split("x"):[null,null]),r=a.next().value,a=a.next().value,n.stream.width=Number(r)||void 0,n.stream.height=Number(a)||void 0,(t=Cp(t,"BANDWIDTH"))&&(n.stream.bandwidth=Number(t)),e.i.set(i,n),n}function hg(e,t,n,i,r,a,s,o,u,l,c,h,m,f){function p(){return e.j&&1<n.length?Mf(e.j,t):_.concat(Wp([e.M],n,e.A))}var g=vg(e,i,r,a,s,o,u,l,c,h,m,f);n.includes("shaka://hls-muxed")&&(g.isAudioMuxedInVideo=!0,g.mimeType="video/mp2t",sg(g));var y,_=[],v={stream:g,type:r,Wg:_,N:p,xc:0,Lb:0,Yd:new Map,Jd:!1,Id:!1,kd:!1,Ue:-1,sb:-1,ub:-1,zf:!1},T=null;return g.createSegmentIndex=function(){return T||(g.isAudioMuxedInVideo?(g.segmentIndex=new Zo([]),Promise.resolve()):(y=Cg(e,v.N(),!0),T=new Promise((function(t){t(function(t){var n,y,T,k,D,x,A,Y,E,P,C,j,O,R,N,H,U,F,B,W,z,V;return I((function(I){switch(I.g){case 1:return n=vi,b(I,2),y=v.N(),M(I,t.promise,4);case 4:if(T=I.h,t.aborted)return I.return();if((k=T.uri)==T.originalUri||y.includes(k)||_.push(k),1!=(D=Gp(e.Ka,T.data)).type)throw new Ye(2,4,4017);return x=Np(D.X,"EXT-X-DEFINE"),A=ag(e,x,k),Y=!1,(!e.fa&&e.g.hls.disableCodecGuessing||e.S&&r==n.la&&!e.g.hls.disableClosedCaptionsDetection)&&0<D.segments.length&&(e.S=!1,Y=!0),E=!e.fa&&e.g.hls.disableCodecGuessing,P=Og(e),M(I,yg(e,0,A,D,p,i,r,a,s,o,u,l,c,h,m,f,void 0,Y,E),5);case 5:if(C=I.h,t.aborted)return I.return();if(j=C.stream,bg(e,D),Og(e)&&!P&&Lg(e,D),v.xc=C.xc,v.Lb=C.Lb,v.Jd=C.Jd,v.Id=C.Id,v.kd=C.kd,v.Yd=C.Yd,v.sb=C.sb,v.ub=C.ub,v.zf=!0,g.segmentIndex=j.segmentIndex,g.encrypted=j.encrypted,g.drmInfos=j.drmInfos,g.keyIds=j.keyIds,g.mimeType=j.mimeType,g.bandwidth=g.bandwidth||j.bandwidth,g.codecs=g.codecs||j.codecs,g.closedCaptions=g.closedCaptions||j.closedCaptions,g.width=g.width||j.width,g.height=g.height||j.height,g.hdr=g.hdr||j.hdr,g.colorGamut=g.colorGamut||j.colorGamut,g.frameRate=g.frameRate||j.frameRate,"und"==g.language&&"und"!=j.language&&(g.language=j.language),g.language=g.language||j.language,g.channelsCount=g.channelsCount||j.channelsCount,g.audioSamplingRate=g.audioSamplingRate||j.audioSamplingRate,sg(g),g.drmInfos.length&&e.h.newDrmInfo(g),O=!1,(!l&&g.closedCaptions||l&&g.closedCaptions&&l.size!=g.closedCaptions.size)&&(O=!0),e.m&&O&&e.h.makeTextStreamsForClosedCaptions(e.m),r==n.la||r==n.V)for(R=d(e.i.values()),N=R.next();!N.done;N=R.next())(H=N.value).zf||H.type!=r||(H.stream.mimeType=j.mimeType,sg(H.stream));r==n.wa&&(U=eu(j.segmentIndex))&&U.ba&&(g.mimeType="application/mp4",sg(g)),F=Du(g),g.segmentIndex.yb((function(e){e.ba&&(e.ba.Qc=F)})),function(e){if(!e.m)return!1;for(var t=[],n=[],i=(e=d(e.m.variants)).next();!i.done;i=e.next())(i=i.value).video&&t.push(i.video),i.audio&&n.push(i.audio);return!(0<t.length&&!t.some((function(e){return e.segmentIndex}))||0<n.length&&!n.some((function(e){return e.segmentIndex})))}(e)&&(e.ac?pg(e,[v]):(e.ac=!0,B=Array.from(e.i.values()),W=B.filter((function(e){return e.stream.segmentIndex})),pg(e,W),rg(e),0<(z=e.o)&&e.B.$(z))),xg(e,D.X,g.type,A,p),e.m&&(e.m.startTime=e.s),L(I,0);break;case 2:if(V=S(I),g.closeSegmentIndex(),7001===V.code)return I.return();if(!e.h.disableStream(g))throw V;w(I)}}))}(y))}))))},g.closeSegmentIndex=function(){T&&!g.segmentIndex&&y.abort(),g.segmentIndex&&(g.segmentIndex.release(),g.segmentIndex=null),T=null},v}function mg(e){for(var t=1/0,n=(e=d(e.i.values())).next();!n.done;n=e.next())(n=n.value).stream.segmentIndex&&"text"!=n.stream.type&&!n.stream.isAudioMuxedInVideo&&(t=Math.min(t,n.Lb));return t}function fg(e,t){for(var n=[],i=(t=d(t)).next();!i.done;i=t.next())(i=i.value).segmentIndex&&i.segmentIndex.yb((function(e){n.push(e)}));e.l.vd(n)}function pg(e,t){if(!Og(e))for(var n=mg(e),i=d(t),r=i.next();!r.done;r=i.next())r.value.stream.segmentIndex.Kc(0,n);fg(e,t.map((function(e){return e.stream}))),n=Og(e)&&!e.bc,e.g.hls.ignoreManifestProgramDateTime||n?ng(e,t,n):(function(e,t){if(1/0==e.ga)for(var n=(t=d(t)).next();!n.done;n=t.next())null!=(n=eu(n.value.stream.segmentIndex))&&null!=n.h&&(e.ga=Math.min(e.ga,n.h));if(1/0!=(t=e.ga))for(var i=(n=d(e.i.values())).next();!i.done;i=n.next())if(!gg(e,(i=i.value).type)){var r=i.stream.segmentIndex;if(null!=r){var a=eu(r);if(a)if(null==a.h)q("Missing EXT-X-PROGRAM-DATE-TIME for stream",i.N(),"Expect AV sync issues!");else for(ig(e,i,a.h-t-a.startTime),r=(i=d(r)).next();!r.done;r=i.next())r.value.Yf(t)}}}(e,t),0<e.g.hls.ignoreManifestProgramDateTimeForTypes.length&&ng(e,t))}function gg(e,t){return!!e.g.hls.ignoreManifestProgramDateTime||e.g.hls.ignoreManifestProgramDateTimeForTypes.includes(t)}function yg(e,t,n,i,r,a,s,o,u,l,c,h,m,f,p,g,y,_,v){var w,T,k,D,x,A,Y,E,P,C,j,O,R,N,H,U,F,B,W,z,V,G,q,$,K,J,X,Q,Z;return _=void 0===_||_,v=void 0===v||v,I((function(t){switch(t.g){case 1:if(w=i.segments||[],T=w.every((function(e){return!!Up(e.X,"EXT-X-GAP")})),!w.length||T)throw new Ye(2,4,4053);if(function(e,t){var n=Up(t.X,"EXT-X-PLAYLIST-TYPE");t=Up(t.X,"EXT-X-ENDLIST"),t=n&&"VOD"==n.value||t,n=n&&"EVENT"==n.value&&!t,n=!t&&!n,Rg(e,t?Vg:n?qg:Gg)}(e,i),Og(e)&&Tg(e,i),k=Og(e)?e.O.get(s):new Map,D=Ag(e,i,k,n,r,s),x=D.segments,A=D.bandwidth,j=C=P=E=Y=null,!(0<x.length&&_)){t.u(2);break}return M(t,function(e,t){var n,i,r,a,s,o,u,l,c,h,m,f,p,g,y,_,v,w,b,T,L,S,k;return I((function(D){switch(D.g){case 1:if(n=xu(e.g.hls.mediaPlaylistFullMimeType),!t.length)return D.return(n);if(i=Ig(e,t),r=i.segment,a=i.segmentIndex,s=r.N(),o=s[0],u=new Wn(o),l=u.Ua.split(".").pop(),c=Fg[l])return D.return(xu(c));if(h=la,f=m=null,!(p=r.ba)){D.u(2);break}return g=Eu(p.N(),p.Zb(),p.Xb(),e.g.retryParameters),M(D,Ng(e,g,h,{type:0}).promise,3);case 3:if(y=D.h,m=y.data,!p.aesKey){D.u(4);break}return M(D,Yu(m,p.aesKey,0),5);case 5:m=D.h;case 4:(f=y.headers["content-type"])&&(f=f.split(";")[0].toLowerCase());case 2:return _=Eu(r.N(),r.Zb(),r.Xb(),e.g.retryParameters),M(D,Ng(e,_,h,{type:1}).promise,6);case 6:if(v=D.h,w=v.data,!r.aesKey){D.u(7);break}return M(D,Yu(w,r.aesKey,a),8);case 8:w=D.h;case 7:if((b=v.headers["content-type"])&&(b=b.split(";")[0].toLowerCase()),T="mp4 mp4a m4s m4i m4a m4f cmfa mp4v m4v cmfv fmp4".split(" "),L=["audio/mp4","video/mp4","video/iso.segment"],ao(pe(w))){var x=w,A=pe(x),Y=(A=(new to).parse(A)).fd();A=A.nf();var E=[],I=!1,P=!1;switch(Y.audio){case"aac":case"aac-loas":E.push("mp4a.40.2"),I=!0;break;case"mp3":E.push("mp4a.40.34"),I=!0;break;case"ac3":E.push("ac-3"),I=!0;break;case"ec3":E.push("ec-3"),I=!0;break;case"opus":E.push("opus"),I=!0}switch(Y.video){case"avc":A.codec?E.push(A.codec):E.push("avc1.42E01E"),P=!0;break;case"hvc":A.codec?E.push(A.codec):E.push("hvc1.1.6.L93.90"),P=!0;break;case"av1":E.push("av01.0.01M.08"),P=!0}if(E.length){if(Y=I&&!P,I=new Map,P){(P=new Me("video/mp2t")).i(x);for(var C=(x=d(P.j())).next();!C.done;C=x.next())C=C.value,I.set(C,C);P.g()}A={type:Y?"audio":"video",mimeType:"video/mp2t",codecs:E.join(", "),language:null,height:A.height,width:A.width,channelCount:null,sampleRate:null,closedCaptions:I,Cd:null,colorGamut:null,frameRate:A.frameRate}}else A=null;if(S=A)return D.return(S)}else if((T.includes(l)||L.includes(b)||f&&L.includes(f))&&(k=function(e,t){function n(e){a=e.name;var t=e.reader;t.skip(24);var n=t.ma(),i=t.ma();t.skip(50),m=String(n),h=String(i),e.reader.sa()&&ba(e)}function i(e){var t=Hs(e.reader);f=t.channelCount,p=t.sampleRate,r(e.name)}function r(e){switch(e=e.toLowerCase()){case"avc1":case"avc3":o.push(e+".42E01E"),l=!0;break;case"hev1":case"hvc1":o.push(e+".1.6.L93.90"),l=!0;break;case"dvh1":case"dvhe":o.push(e+".05.04"),l=!0;break;case"vp09":o.push(e+".00.10.08"),l=!0;break;case"av01":o.push(e+".0.01M.08"),l=!0;break;case"mp4a":s.push("mp4a.40.2"),u=!0;break;case"ac-3":case"ec-3":case"ac-4":case"opus":case"flac":s.push(e),u=!0}}var a,s=[],o=[],u=!1,l=!1,c=null,h=null,m=null,f=null,p=null,g=null,y=null;if((new wa).box("moov",ba).box("trak",ba).box("mdia",ba).R("mdhd",(function(e){c=Rs(e.reader,e.version).language})).box("minf",ba).box("stbl",ba).R("stsd",Ta).box("mp4a",(function(e){var t=Hs(e.reader);f=t.channelCount,p=t.sampleRate,e.reader.sa()?ba(e):r(e.name)})).box("esds",(function(e){e=e.reader;for(var t,n,i="mp4a";e.sa();){t=e.T();for(var r=e.T();128&r;)r=e.T();if(3==t)e.ma(),128&(r=e.T())&&e.ma(),64&r&&e.skip(e.T()),32&r&&e.ma();else if(4==t)n=e.T(),e.skip(12);else if(5==t)break}n&&(i+="."+Fs(n),5==t&&e.sa()&&(31==(n=(248&(t=e.T()))>>3)&&e.sa()&&(n=32+((7&t)<<3)+((224&e.T())>>5)),i+="."+n)),s.push(i),u=!0})).box("ac-3",i).box("ec-3",i).box("ac-4",i).box("Opus",i).box("fLaC",i).box("avc1",n).box("avc3",n).box("hev1",n).box("hvc1",n).box("dva1",n).box("dvav",n).box("dvh1",n).box("dvhe",n).box("vp09",n).box("av01",n).box("avcC",(function(e){var t=a||"";switch(a){case"dvav":t="avc3";break;case"dva1":t="avc1"}(e=e.reader).skip(1),e=t+"."+Fs(e.T())+Fs(e.T())+Fs(e.T()),o.push(e),l=!0})).box("hvcC",(function(e){var t=a||"";switch(a){case"dvh1":t="hvc1";break;case"dvhe":t="hev1"}var n=e.reader;n.skip(1);var i=["","A","B","C"][(e=n.T())>>6],r=31&e,s=n.P(),u=(32&e)>>5?"H":"L";e=[n.T(),n.T(),n.T(),n.T(),n.T(),n.T()],n=n.T();for(var d=0,c=0;32>c&&(d|=1&s,31!=c);c++)d<<=1,s>>=1;for(t=t+"."+i+r+"."+Fs(d,!0),t+="."+u+n,i="",r=e.length;r--;)((u=e[r])||i)&&(i="."+u.toString(16).toUpperCase()+i);t+=i,o.push(t),l=!0})).box("dvcC",(function(e){var t=a||"";switch(a){case"hvc1":t="dvh1";break;case"hev1":t="dvhe";break;case"avc1":t="dva1";break;case"avc3":t="dvav";break;case"av01":t="dav1"}var n=e.reader;n.skip(2),e=n.T(),n=n.T(),o.push(t+"."+Bs(e>>1&127)+"."+Bs(e<<5&32|n>>3&31)),l=!0})).box("dvvC",(function(e){var t=a||"";switch(a){case"hvc1":t="dvh1";break;case"hev1":t="dvhe";break;case"avc1":t="dva1";break;case"avc3":t="dvav";break;case"av01":t="dav1"}var n=e.reader;n.skip(2),e=n.T(),n=n.T(),o.push(t+"."+Bs(e>>1&127)+"."+Bs(e<<5&32|n>>3&31)),l=!0})).R("vpcC",(function(e){var t=a||"",n=e.reader;e=n.T();var i=n.T();n=n.T()>>4&15,o.push(t+"."+Bs(e)+"."+Bs(i)+"."+Bs(n)),l=!0})).box("av1C",(function(e){var t=a||"";"dav1"===a&&(t="av01");var n=e.reader;n.skip(1);var i=(e=n.T())>>>5,r=(64&(n=n.T()))>>6;o.push(t+"."+i+"."+Bs(31&e)+(n>>>7?"H":"M")+"."+Bs(2===i&&r?(32&n)>>5?12:10:r?10:8)+"."+((16&n)>>4)+"."+((8&n)>>3)+((4&n)>>2)+(3&n)+"."+Bs(1)+"."+Bs(1)+"."+Bs(1)+".0"),l=!0})).box("enca",Sa).box("encv",La).box("sinf",ba).box("frma",(function(e){r(e=Us(e.reader).codec)})).box("colr",(function(e){o=o.map((function(t){if(t.startsWith("av01.")){var n=e.reader,i=n.ya(),r=n.vb(4),a=String.fromCharCode(r[0]);if(a+=String.fromCharCode(r[1]),a+=String.fromCharCode(r[2]),"nclx"===(a+=String.fromCharCode(r[3]))){r=n.ma(),a=n.ma();var s=n.ma(),o=n.T()>>7,u=t.split(".");10==u.length&&(u[6]=Bs(r),u[7]=Bs(a),u[8]=Bs(s),u[9]=String(o),t=u.join("."))}n.seek(i)}return t}));var t=function(e){var t=null,n=null,i=e.vb(4),r=String.fromCharCode(i[0]);if(r+=String.fromCharCode(i[1]),r+=String.fromCharCode(i[2]),"nclx"===(r+=String.fromCharCode(i[3]))){switch(e.ma()){case 1:case 5:case 6:case 7:t="srgb";break;case 9:t="rec2020";break;case 11:case 12:t="p3"}switch(i=e.ma(),e.ma(),i){case 1:case 6:case 13:case 14:case 15:n="SDR";break;case 16:n="PQ";break;case 18:n="HLG"}}return{colorGamut:t,Cd:n}}(e.reader),n=t.colorGamut;g=t.Cd,y=n})).parse(e||t,!0),!s.length&&!o.length)return null;var _=u&&!l,v=new Map;if(l){var M=new Me("video/mp4");e&&M.init(e);try{M.i(t);for(var w=d(M.j()),b=w.next();!b.done;b=w.next()){var T=b.value;v.set(T,T)}}catch(e){}M.g()}return{type:_?"audio":"video",mimeType:_?"audio/mp4":"video/mp4",codecs:Au(s.concat(o)).join(", "),language:c,height:h,width:m,channelCount:f,sampleRate:p,closedCaptions:v,Cd:g,colorGamut:y,frameRate:null}}(m,w)))return D.return(k);return b?D.return(xu(b)):f?D.return(xu(f)):D.return(n)}}))}(e,x),3);case 3:O=t.h,s=O.type,o=O.language,c=O.channelCount,p=O.sampleRate,e.g.disableText||(h=O.closedCaptions),E=O.height,Y=O.width,P=O.Cd,C=O.colorGamut,j=O.frameRate,v&&(y=O.mimeType,a=O.codecs);case 2:if(y){t.u(4);break}return M(t,function(e,t,n,i){var r,a,s,o,u,d,l,c,h,m,f,p,g,y;return I((function(_){switch(_.g){case 1:return r=la,a=Ig(e,i),2==(s=a.segment).status?_.return(Eg(t)):(o=s.N(),u=new Wn(o[0]),d=u.Ua.split(".").pop(),l=Bg[t],(c=l[d])||(c=Fg[d])||(c=Yg(t,n))?_.return(c):(m=1,f=aa(o,e.g.retryParameters),b(_,2),f.method="HEAD",M(_,Ng(e,f,r,{type:m}).promise,4)));case 4:p=_.h,h=p.headers["content-type"],L(_,3);break;case 2:if(!(g=S(_))||1002!=g.code&&1001!=g.code){_.u(3);break}return f.method="GET",M(_,Ng(e,f,r,{type:m}).promise,6);case 6:y=_.h,h=y.headers["content-type"];case 3:return h?_.return(h.toLowerCase().split(";")[0]):_.return(Eg(t))}}))}(e,s,a,x),5);case 5:y=t.h;case 4:return M(t,Mg(e,i,y,r,n),6);case 6:if(R=t.h,N=R.drmInfos,H=R.keyIds,U=R.encrypted,F=R.zh,U&&!N.length&&!F)throw new Ye(2,4,4026);return(B=vg(e,a,s,o,u,l,c,h,m,f,p,g)).encrypted=U,B.drmInfos=N,B.keyIds=H,B.mimeType=y,A&&(B.bandwidth=A),sg(B),"video"==s&&(Y||E||P||C)&&Pg(B,Y,E,j,P,null,C),Og(e)&&Tg(e,i),W=x[0].startTime,z=x[x.length-1],V=z.endTime,G=new Zo(x),B.segmentIndex=G,$=!!(q=Up(i.X,"EXT-X-SERVER-CONTROL"))&&null!=Pp(q,"CAN-SKIP-UNTIL"),K=!!q&&null!=Pp(q,"CAN-BLOCK-RELOAD"),J=Fp(i.X,"EXT-X-MEDIA-SEQUENCE",0),X=_g(J,x),Q=X.sb,Z=X.ub,t.return({stream:B,type:s,Wg:[],N:r,xc:W,Lb:V,Jd:$,Id:K,kd:!1,Ue:-1,sb:Q,ub:Z,Yd:k,zf:!1})}}))}function _g(e,t){e=e+t.length-1;var n=-1;if(!t.length)return{sb:++e,ub:n};var i=(t=t[t.length-1]).g;return t.g.length?(n=i.length-1,i[i.length-1].isPreload()||(e++,n=0),{sb:e,ub:n}):(e++,t.m&&(n=0),{sb:e,ub:n})}function vg(e,t,n,i,r,a,s,o,u,l,c,h){var m=Yg(n,t)||Eg(n),f=[];if(u)for(var p=(u=d(u.split(","))).next();!p.done;p=u.next())f.push(p.value);return u=void 0,p=null,n==_i?u=f.includes("public.accessibility.transcribes-spoken-dialog")&&f.includes("public.accessibility.describes-music-and-sound")?"caption":"subtitle":f.includes("public.accessibility.describes-video")&&(p="visually impaired"),f.length||"subtitle"!==u||f.push("subtitle"),sg(e={id:e.C++,originalId:a,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:m,codecs:t,kind:n==_i?"subtitle":void 0,encrypted:!1,drmInfos:[],keyIds:new Set,language:Ki(i||"und"),originalLanguage:i,label:a,type:n,primary:r,trickModeVideo:null,emsgSchemeIdUris:null,frameRate:void 0,pixelAspectRatio:void 0,width:void 0,height:void 0,bandwidth:void 0,roles:f,forced:l,channelsCount:s,audioSamplingRate:c,spatialAudio:h,closedCaptions:o,hdr:void 0,colorGamut:void 0,videoLayout:void 0,tilesLayout:void 0,accessibilityPurpose:p,external:!1,fastSwitching:!1,fullMimeTypes:new Set,isAudioMuxedInVideo:!1}),e}function Mg(e,t,n,i,r){var a,s,o,u,l,c,h,m,f,p,g,y,_,v,w,b,T,L,S,k,D,x,A,Y,E,P,C,j;return I((function(I){switch(I.g){case 1:if(a=new Map,t.segments)for(s=d(t.segments),o=s.next();!o.done;o=s.next())if(u=o.value,l=Np(u.X,"EXT-X-KEY"),c=null,l.length)for(c=Sg(e,t,u.X,i,r),h=d(l),m=h.next();!m.done;m=h.next())f=m.value,a.set(f,c);g=p=!1,y=[],_=new Set,v=d(a),w=v.next();case 2:if(w.done){I.u(4);break}if(b=w.value,T=d(b),L=T.next().value,S=T.next().value,D=S,"NONE"==(x=jp(k=L,"METHOD"))){I.u(3);break}if(p=!0,A=Cp(k,"KEYFORMAT")||"identity",Y=null,Hg(x)){g=!0,I.u(3);break}if("identity"!=A){Y=(E=zg[A])?E(k,n):null,I.u(6);break}return M(I,Ug(e,k,n,i,D,r),8);case 8:Y=I.h;case 6:if(Y){if(Y.keyIds)for(P=d(Y.keyIds),C=P.next();!C.done;C=P.next())j=C.value,_.add(j);y.push(Y)}case 3:w=v.next(),I.u(2);break;case 4:return I.return({drmInfos:y,keyIds:_,encrypted:p,zh:g})}}))}function wg(t,n,i,r,a){if(!e.crypto||!e.crypto.subtle)throw $("Web Crypto API is not available to decrypt AES. (Web Crypto only exists in secure origins like https)"),new Ye(2,4,4042);var s=0,o=Cp(n,"IV","");if(o){var u=di(o.substr(2));if(16!=u.byteLength)throw new Ye(2,4,4048)}else s=Fp(i.X,"EXT-X-MEDIA-SEQUENCE",0);if(i=n.toString()+"-"+s,!t.ja.has(i)){var d={bitsKey:128,blockCipherMode:"CBC",iv:u,firstMediaSequenceNumber:s};switch(jp(n,"METHOD")){case"AES-256":d.bitsKey=256;break;case"AES-256-CTR":d.bitsKey=256,d.blockCipherMode="CTR"}d.fetchKey=function(){var i,s,o,u,l,c;return I((function(h){if(1==h.g)return i=Bp(r(),jp(n,"URI"),a),s=i.sort().join(""),t.L.has(s)||(o=aa(i,t.g.retryParameters),u=Ng(t,o,6).promise,t.L.set(s,u)),M(h,t.L.get(s),2);if(3!=h.g){if(!(l=h.h).data||l.data.byteLength!=d.bitsKey/8)throw new Ye(2,4,4049);return c={name:"CTR"==d.blockCipherMode?"AES-CTR":"AES-CBC",length:d.bitsKey},M(h,e.crypto.subtle.importKey("raw",l.data,c,!0,["decrypt"]),3)}d.cryptoKey=h.h,d.fetchKey=void 0,w(h)}))},t.ja.set(i,d)}return t.ja.get(i)}function bg(e,t){null==e.s&&(t=Up(t.X,"EXT-X-START"))&&(e.s=Number(jp(t,"TIME-OFFSET")))}function Tg(e,t){var n=1/0,i=t.segments;if(i.length)for(var r=i.length-1;0<=r;){var a=Up(i[r].X,"EXTINF");if(a){n=Number(a.value.split(",")[0]);break}r--}if(!(i=Up(t.X,"EXT-X-TARGETDURATION")))throw new Ye(2,4,4024,"EXT-X-TARGETDURATION");i=Number(i.value),(r=Up(t.X,"EXT-X-PART-INF"))&&(e.Y=Number(jp(r,"PART-TARGET"))),t=Up(t.X,"EXT-X-SERVER-CONTROL"),e.K&&e.Y?(e.o=e.Ib?5*e.Y<=n?Math.min(e.Y,e.o):Math.min(n,e.o):Math.min(e.Y,e.o),e.Ga=t?Number(jp(t,"PART-HOLD-BACK")):0):(e.o=Math.min(n,e.o),n=t?Pp(t,"HOLD-BACK"):null,e.Ba=n?Number(n.value):0),e.La=Math.max(i,e.La)}function Lg(e,t){var n=0;if(e.g.defaultPresentationDelay)n=e.g.defaultPresentationDelay;else if(e.Ga)n=e.Ga;else if(e.Ba)n=e.Ba;else{var i=t.segments.length,r=e.g.hls.liveSegmentsDelay;for(r>i-2&&(r=Math.max(1,i-2)),r=i-r;r<i;r++){var a=Up(t.segments[r].X,"EXTINF");n=a?n+Math.ceil(Number(a.value.split(",")[0])):n+e.La}}e.s&&0>e.s&&(n=Math.min(-e.s,n),e.s+=n),e.l.gh(0),e.l.Sf(n),e.l.Bc(!1)}function Sg(e,t,n,i,r){var a=Up(n,"EXT-X-MAP");if(!a)return null;var s=jp(a,"URI"),o=Bp(i(),s,r);if(s=[o.toString(),Cp(a,"BYTERANGE","")].join("-"),!e.ta.has(s)){for(var u=void 0,l=null,c=(n=d(n)).next();!c.done;c=n.next())"EXT-X-KEY"==(c=c.value).name?Hg(jp(c,"METHOD"))&&c.id<a.id&&(u=wg(e,c,t,i,r)):"EXT-X-BYTERANGE"==c.name&&c.id<a.id&&(l=c);t=function(e,t,n,i){var r=0,a=null;return!(t=Cp(t,"BYTERANGE"))&&n&&(t=n.value),t&&(r=t.split("@"),a=Number(r[0]),a=(r=Number(r[1]))+a-1,i&&((n=a+1-r)%16&&(a+=16-n%16))),new fs((function(){return e}),r,a,null,null,null,i)}(o,a,l,u),e.ta.set(s,t)}return e.ta.get(s)}function kg(t,n,i,r,a,s,o,u,l){function c(e){e=new Wn(e).Ua.split(".").pop();var t=Bg[o][e];return t||(t=Fg[e]),t}var h=r.X,m=Up(h,"EXTINF"),f=0,p=0,g=null;r.Cb.length&&(t.m.isLowLatency=!0);var y=null;if(!t.g.hls.ignoreManifestProgramDateTime){var _=Up(h,"EXT-X-PROGRAM-DATE-TIME");_&&_.value&&(y=zt(_.value),t.bc=!0)}var v=_s;if(Up(h,"EXT-X-GAP")&&(t.m.gapCount++,v=2),!m){if(0==r.Cb.length)throw new Ye(2,4,4024,"EXTINF");if(!t.K)return null}var M=[];_=!1;var w=null,b=!1,T=!1;if(t.K&&r.Cb.length){f=n&&e.ReadableStream&&t.g.hls.allowLowLatencyByteRangeOptimization;for(var L=y,S={},k=0;k<r.Cb.length;S={xe:void 0,fe:void 0},k++){var D=r.Cb[k],x=0==k?i:M[M.length-1],A=0==k?a:x.endTime,Y=Number(Cp(D,"DURATION"))||t.Y;if(Y){var E=A+Y,I=0,P=null;if("EXT-X-PRELOAD-HINT"==D.name?(I=(I=Cp(D,"BYTERANGE-START"))?Number(I):0,(x=Cp(D,"BYTERANGE-LENGTH"))?P=I+Number(x)-1:I&&(P=Number.MAX_SAFE_INTEGER)):(I=(P=d(Dg(x,I=Cp(D,"BYTERANGE")))).next().value,P=P.next().value),S.fe=Cp(D,"URI"),S.fe){x=_s,"YES"==Cp(D,"GAP")&&(t.m.gapCount++,x=2,b=!0),S.xe=null;var C=function(e){return function(){return null==e.xe&&(e.xe=Bp(u(),e.fe,s)),e.xe}}(S);f&&0<=I&&null!=P&&(w=C,_=!0),A=new gs(A,E,C,I,P,n,0,0,1/0,[],"",null,L,x,l),"EXT-X-PRELOAD-HINT"==D.name&&(A.Af(),T=!0),"YES"!=Cp(D,"INDEPENDENT")&&0<k&&A.Pc(),(S=c(S.fe))&&(A.mimeType=S,Wg.has(S)&&(A.ba=null)),M.push(A),L&&(L+=Y)}}}}if(m){if(0==(m=Number(m.value.split(",")[0])))return null;f=a+m}else{if(!M.length)return null;f=M[M.length-1].endTime}_&&(b||0!=M[0].Ja?(_=!1,w=null):M=[]),(m=Up(h,"EXT-X-BYTERANGE"))?(p=(g=d(Dg(i,m.value))).next().value,g=g.next().value):M.length&&(p=M[0].Ja,g=M[M.length-1].va),i="",m=null,"image"==o&&(i="1x1",h=Up(h,"EXT-X-TILES"))&&(i=jp(h,"LAYOUT"),(h=Cp(h,"DURATION"))&&(m=Number(h)));var j=null;return n=new gs(a,f,(function(){return w?w():(null==j&&(j=Bp(u(),r.g,s)),j||[])}),p,g,n,0,0,1/0,M,i,m,y,v,l,0<M.length&&!!r.g),(a=c(r.g))&&(n.mimeType=a,Wg.has(a)&&(n.ba=null)),_&&(t.Ib=!0,n.Lg(),T&&n.Af()),n}function Dg(e,t){var n=0,i=null;return t&&(n=t.split("@"),t=Number(n[0]),i=(n=n[1]?Number(n[1]):e.va+1)+t-1),[n,i]}function xg(e,t,n,i,r){if("video"==n||"audio"==n){var a=e.l.m;if(a&&!gg(e,n))for(t=(t=Np(t,"EXT-X-DATERANGE")).sort((function(e,t){return(e=jp(e,"START-DATE"))<(t=jp(t,"START-DATE"))?-1:e>t?1:0})),n=0;n<t.length;n++){var s=t[n];try{var o=jp(s,"ID");if(!e.Aa.has(o)){var u=zt(jp(s,"START-DATE"));if(!isNaN(u)){var l=Math.max(0,u-a),c=null,h=Cp(s,"END-DATE");if(h){var m=zt(h);if(!isNaN(m)&&0>(c=m-a))continue}if(null==c){var f=Cp(s,"DURATION")||Cp(s,"PLANNED-DURATION");if(f){var p=parseFloat(f);if(isNaN(p)||(c=l+p),0>u-a+p)continue}}var g=Cp(s,"CLASS")||"com.apple.quicktime.HLS",y="YES"==Cp(s,"END-ON-NEXT");if(null==c&&y){for(var _=n+1;_<t.length;_++)if(g==(Cp(t[_],"CLASS")||"com.apple.quicktime.HLS")){var v=zt(jp(t[_],"START-DATE"));if(!isNaN(v)&&v&&v>u){c=Math.max(0,v-a);break}}if(null==c)continue}_=["CLASS","START-DATE","END-DATE","DURATION","END-ON-NEXT"];for(var M=[],w=d(s.attributes),b=w.next();!b.done;b=w.next()){var T=b.value;if(!_.includes(T.name)){var L=zp(T.value,i);"X-ASSET-URI"!=T.name&&"X-ASSET-LIST"!=T.name||(L=Bp(r(),T.value,i)[0]),M.push({key:T.name,description:"",data:L,mimeType:null,pictureType:null})}}1<M.length&&e.h.onMetadata(g,l,c,M),e.Aa.add(o)}}}catch(e){}}}}function Ag(e,t,n,i,r,a){var s=t.segments,o=void 0,u=Fp(t.X,"EXT-X-DISCONTINUITY-SEQUENCE",-1),l=Fp(t.X,"EXT-X-MEDIA-SEQUENCE",0),c=Up(t.X,"EXT-X-SKIP"),h=c?Number(Cp(c,"SKIPPED-SEGMENTS")):0,m=l+h,f=0;Og(e)&&n.has(m)&&(f=n.get(m)),0===f&&e.xa==qg&&0<n.size&&!n.has(m)&&null!=e.l.i&&(f=e.l.qb());var p=[],g=null;c=[];for(var y=0;y<s.length;y++){var _=s[y],v=0==y?f:g.endTime;m=l+h+y,Up(_.X,"EXT-X-DISCONTINUITY")&&u++;for(var M=d(_.X),w=M.next();!w.done;w=M.next())"EXT-X-KEY"==(w=w.value).name&&(o=Hg(jp(w,"METHOD"))?wg(e,w,t,r,i):void 0);n.set(m,v),M=Sg(e,t,_.X,r,i),!e.K&&e.h.isAutoLowLatencyMode()&&(e.h.enableLowLatencyMode(),e.K=e.h.isLowLatencyMode()),(v=kg(e,M,g,_,v,i,a,r,o))&&((g=Fp(_.X,"EXT-X-BITRATE"))?c.push({bitrate:g,duration:v.endTime-v.startTime}):c.length&&((g=c.pop()).duration+=v.endTime-v.startTime,c.push(g)),g=v,v.i=u,gg(e,a)&&null!=e.I&&m<e.I||p.push(v))}if(t=void 0,c.length&&(t=c.reduce((function(e,t){return e+t.duration}),0),t=Math.round(c.reduce((function(e,t){return e+t.bitrate*t.duration}),0)/t*1e3)),c=p.some((function(e){return null!=e.h})))for(n={},i=0;i<p.length;n={Nd:void 0,Md:void 0,Fd:void 0,zc:void 0,Ed:void 0},i++)if(n.zc=p[i],null==n.zc.h)for(n.Md=0,n.Nd=i,r=function(e){return function(){var t=p[e.Nd];if(t){if(null!=t.h)return t.h+e.Md;e.Md-=t.endTime-t.startTime,e.Nd+=1}return null}}(n),n.Ed=0,n.Fd=i,s=function(e){return function(){var t=p[e.Fd];if(t){if(t!=e.zc&&(e.Ed+=t.endTime-t.startTime),null!=t.h)return t.h+e.Ed;--e.Fd}return null}}(n);null==n.zc.h;)n.zc.h=s(),null==n.zc.h&&(n.zc.h=r());if(c)for(i=(n=d(p)).next();!i.done;i=n.next())for(i=(r=i.value).h,s=(r=d(r.g)).next();!s.done;s=r.next())(s=s.value).h=i,i+=s.endTime-s.startTime;if(n=e.ga,c&&1/0!=n&&!gg(e,a))for(a=(e=d(p)).next();!a.done;a=e.next())a.value.Yf(n);return{segments:p,bandwidth:t}}function Yg(e,t){if(e==_i){if("vtt"==t||"wvtt"==t)return"text/vtt";if(t&&""!==t)return"application/mp4"}return"image"!=e||t&&"jpeg"!=t?"audio"==e&&"mp4a.40.34"==t?"audio/mpeg":"mjpg"==t?"application/mp4":null:"image/jpeg"}function Eg(e){return e==_i?"text/vtt":Bg[e].mp4}function Ig(e,t){for(var n=t[e=Og(e)?Math.trunc((t.length-1)/2):0];2==n.$b()&&e+1<t.length;)n=t[++e];return{segment:n,segmentIndex:e}}function Pg(e,t,n,i,r,a,s){e&&(e.width=Number(t)||void 0,e.height=Number(n)||void 0,e.frameRate=Number(i)||void 0,e.hdr=r||void 0,e.videoLayout=a||void 0,e.colorGamut=s||void 0)}function Cg(e,t,n){return Ng(e,aa(t,e.g.retryParameters),0,{type:n?2:3})}function jg(e){var t,n,i,r,a,s;return I((function(o){switch(o.g){case 1:return e.h?(b(o,2),t=Date.now(),M(o,e.update(),4)):o.return();case 4:n=Date.now(),Og(e)&&(i=(n-t)/1e3,e.Gb.sample(1,i),r=0<e.g.hls.updatePeriod?e.g.hls.updatePeriod:e.o,a=Math.max(0,r-z(e.Gb)),e.B.$(a)),L(o,3);break;case 2:if(s=S(o),!e.h)return o.return();if(e.g.raiseFatalErrorOnManifestUpdateRequestFailure)return e.h.onError(s),o.return();s.severity=1,e.h.onError(s),e.B.$(.1);case 3:if(!e.h)return o.return();e.h.onManifestUpdated(),w(o)}}))}function Og(e){return e.xa!=Vg}function Rg(e,t){e.xa=t,e.l&&e.l.Bc(!Og(e)),Og(e)||e.B.stop()}function Ng(e,t,n,i){if(!e.da)throw new Ye(2,7,7001);return i||(i={}),i.isPreload=e.Hb(),t=e.h.networkingEngine.request(n,t,i),ta(e.da,t),t}function Hg(e){return"AES-128"==e||"AES-256"==e||"AES-256-CTR"==e}function Ug(e,t,n,i,r,a){var s,o,u,d,l,c,h,m,f,p,g,y,_;return I((function(v){switch(v.g){case 1:if("video/mp2t"==n)throw new Ye(2,4,4040);if(st())throw new Ye(2,4,4041);if(s=jp(t,"METHOD"),!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(s))return v.return(null);if((o=Bp(i(),jp(t,"URI"),a))[0].startsWith("data:text/plain;base64,")){u=li(ui(o[0].split("data:text/plain;base64,").pop())),v.u(2);break}return d=o.sort().join(""),e.ra.has(d)||(l=aa(o,e.g.retryParameters),c=Ng(e,l,6).promise,e.ra.set(d,c)),M(v,e.ra.get(d),3);case 3:h=v.h,u=li(h.data);case 2:if(m="00000000000000000000000000000000",!r){v.u(4);break}if(e.na.has(r)){f=e.na.get(r),v.u(5);break}return p=Eu(r.N(),r.Zb(),r.Xb(),e.g.retryParameters),M(v,Ng(e,p,la,{type:0}).promise,6);case 6:g=v.h,f=function(e){var t=null;return(new wa).box("moov",ba).box("trak",ba).box("mdia",ba).box("minf",ba).box("stbl",ba).R("stsd",Ta).box("encv",La).box("enca",Sa).box("sinf",ba).box("schi",ba).R("tenc",(function(e){(e=e.reader).T(),e.T(),e.T(),e.T(),t=li(e.vb(16))})).parse(e,!0),t}(g.data),e.na.set(r,f);case 5:f&&(m=f);case 4:return(y=new Map).set(m,u),_="cenc","SAMPLE-AES"==s&&(_="cbcs"),v.return(fi(y,_))}}))}U("shaka.net.DataUriPlugin",Jp),Jp.parse=Xp,ia("data",Xp),(i=Zp.prototype).configure=function(e,t){var n=this.h&&e.hls.updatePeriod!=this.g.hls.updatePeriod&&0<=e.hls.updatePeriod;this.g=e,t&&(this.Hb=t),this.j&&this.j.configure(this.g),n&&this.m&&this.m.presentationTimeline.U()&&this.B.hc()},i.start=function(e,t){var n,i=this;return I((function(r){return 1==r.g?(i.h=t,i.K=t.isLowLatencyMode(),M(r,Cg(i,[e]).promise,2)):3!=r.g?(n=r.h,i.M=n.uri,M(r,function(e,t,n){var i,r,a,s,o,u,c,h,m,f,p,g,y,_,v,w,T,L,k,D,x,A,Y,E,P,C,j,O,R,N,H,U,F;return I((function(B){switch(B.g){case 1:return i=vi,r=Gp(e.Ka,t),a=Np(r.X,"EXT-X-DEFINE"),s=[],o=[],u=[],e.l=new Po(null,0),e.l.Bc(!0),c=function(){return[n]},h=null,m=new Map,1==r.type?(e.S=!1,L=Np(r.X,"EXT-X-DEFINE"),m=ag(e,L,e.M),h=i.la,k="",D=new Map,M(B,yg(e,e.C++,m,r,c,"",h,k,!0,"Media Playlist",null,D,null,!1,null,!1),7)):(function(e,t){for(var n=new Wn(e.M).g,i=(t=d(t)).next();!i.done;i=t.next()){var r=i.value;i=Cp(r,"NAME");var a=Cp(r,"VALUE");r=Cp(r,"QUERYPARAM"),i&&a&&(e.A.has(i)||e.A.set(i,a)),r&&(i=n.get(r)[0])&&!e.A.has(i)&&e.A.set(r,i)}}(e,a),f=Np(r.X,"EXT-X-MEDIA"),p=Np(r.X,"EXT-X-STREAM-INF"),g=Np(r.X,"EXT-X-IMAGE-STREAM-INF"),y=Np(r.X,"EXT-X-I-FRAME-STREAM-INF"),_=Np(r.X,"EXT-X-SESSION-KEY"),v=Np(r.X,"EXT-X-SESSION-DATA"),w=Np(r.X,"EXT-X-CONTENT-STEERING"),function(e,t){for(var n=(t=d(t)).next();!n.done;n=t.next()){var i=n.value,r=Cp(i,"DATA-ID");n=Cp(i,"URI");var a=Cp(i,"LANGUAGE");i=Cp(i,"VALUE"),r=(new Map).set("id",r),n&&r.set("uri",Bp([e.M],n,e.A)[0]),a&&r.set("language",a),i&&r.set("value",i),n=new Jr("sessiondata",r),e.h&&e.h.onEvent(n)}}(e,v),M(B,function(e,t){var n,i,r,a,s,o;return I((function(u){if(!e.h||!e.g)return u.return();for(i=d(t),r=i.next();!r.done;r=i.next())if(a=r.value,s=Cp(a,"PATHWAY-ID"),o=Cp(a,"SERVER-URI"),s&&o){e.j=new gf(e.h),e.j.configure(e.g),e.j.i=[e.M],e.j.setManifestType("HLS"),e.j.h=s,n=yf(e.j,o);break}return M(u,n,0)}))}(e,w),4));case 4:return function(e,t){for(var n=(t=d(t)).next();!n.done;n=t.next()){var i=n.value,r=Cp(i,"AUDIO");n=Cp(i,"VIDEO");var a=Cp(i,"SUBTITLES");if(i=ug(e,i),a){var s=gi(_i,i);e.G.set(a,s),De(i,s)}r&&((a=gi("audio",i))||(a=e.g.hls.defaultAudioCodec),e.G.set(r,a)),n&&((r=gi("video",i))||(r=e.g.hls.defaultVideoCodec),e.G.set(n,r))}}(e,p),function(e,t){t=Hp(t,"CLOSED-CAPTIONS"),e.S=0==t.length;for(var n=(t=d(t)).next();!n.done;n=t.next()){var i=n.value,r=Cp(i,"LANGUAGE");n=Ki(r||"und"),r||(r=Cp(i,"NAME"))&&(n=r),r=jp(i,"GROUP-ID"),i=jp(i,"INSTREAM-ID").replace("SERVICE","svc"),e.F.get(r)||e.F.set(r,new Map),e.F.get(r).set(i,n)}}(e,f),T=function(e,t){return t.map((function(t){return"video"!==(t=cg(e,t)).stream.type?null:t.stream})).filter((function(e){return e}))}(e,y),M(B,function(e,t,n,i,r,a,s){var o,u,c,h,m,f,p,g,y,_,v,w,b,T,L,S,k,D,x,A,Y,E,P,C,j,O,R,N,H,U,F,B,W,z,V;return I((function(I){switch(I.g){case 1:if(o=[],u=new Set,!(0<n.length)){I.u(2);break}c=d(n),h=c.next();case 3:if(h.done){I.u(2);break}if(m=h.value,f=jp(m,"METHOD"),p=Cp(m,"KEYFORMAT")||"identity",g=null,"NONE"==f){I.u(4);break}if(Hg(f)){y=Bp(r(),jp(m,"URI"),a),_=y.sort().join(""),e.L.has(_)||(v=aa(y,e.g.retryParameters),w=Ng(e,v,6).promise,e.L.set(_,w)),I.u(4);break}if("identity"!=p){g=(b=zg[p])?b(m,""):null,I.u(6);break}return M(I,Ug(e,m,"",r,null,a),9);case 9:g=I.h;case 6:if(g){if(g.keyIds)for(T=d(g.keyIds),L=T.next();!L.done;L=T.next())S=L.value,u.add(S);o.push(g)}case 4:h=c.next(),I.u(3);break;case 2:for(k={},D=d(t),x=D.next();!x.done;x=D.next())A=x.value,Y=Ip(A,!e.j),k[Y]?k[Y].push(A):k[Y]=[A];for(P in E=[],k)C=k[P],j=C[0],O=Cp(j,"FRAME-RATE"),R=Number(Cp(j,"AVERAGE-BANDWIDTH"))||Number(jp(j,"BANDWIDTH")),N=Cp(j,"RESOLUTION"),H=d(N?N.split("x"):[null,null]),U=H.next().value,F=H.next().value,B=Cp(j,"VIDEO-RANGE"),(W=Cp(j,"REQ-VIDEO-LAYOUT"))&&W.includes(",")&&(z=W.split(",").filter((function(e){return"CH-STEREO"==e||"CH-MONO"==e})),W=z[0]),W=W||"CH-MONO",V=og(e,C,i),E.push.apply(E,l(dg(e,V.audio,V.video,R,U,F,O,B,W,o,u,s)));return I.return(E.filter((function(e){return null!=e})))}}))}(e,p,_,f,c,e.A,T),5);case 5:return s=B.h,o=function(e,t){var n=Hp(t,"SUBTITLES");t=n.map((function(t){if(e.g.disableText)return null;try{return lg(e,[t],new Map).stream}catch(t){if(e.g.hls.ignoreTextStreamFailures)return null;throw t}}));for(var i=(n=d(n)).next();!i.done;i=n.next()){var r=jp(i.value,"GROUP-ID");if((i=e.G.get(r))&&(r=e.H.get(r)))for(var a=(r=d(r)).next();!a.done;a=r.next())(a=a.value).stream.codecs=i,a.stream.mimeType=Yg(_i,i)||Eg(_i),sg(a.stream)}return t.filter((function(e){return e}))}(e,f),M(B,function(e,t,n){var i,r;return I((function(a){return 1==a.g?(i=t.map((function(t){var n,i;return I((function(r){if(1==r.g)return e.g.disableThumbnails?r.return(null):(b(r,2),M(r,function(e,t){var n,i,r,a,s,o,u,d,l,c;return I((function(h){return 1==h.g?(n=jp(t,"URI"),i=Cp(t,"CODECS","jpeg")||"",e.i.has(n)?h.return(e.i.get(n)):(r=Cp(t,"LANGUAGE"),a=Cp(t,"NAME"),s=Cp(t,"CHARACTERISTICS"),o=hg(e,e.C++,[n],i,"image",r,!1,a,null,null,s,!1,null,!1),(u=Cp(t,"RESOLUTION"))?M(h,o.stream.createSegmentIndex(),3):h.u(2))):(2!=h.g&&(d=eu(o.stream.segmentIndex),l=d.tilesLayout)&&(o.stream.width=Number(u.split("x")[0])*Number(l.split("x")[0]),o.stream.height=Number(u.split("x")[1])*Number(l.split("x")[1])),(c=Cp(t,"BANDWIDTH"))&&(o.stream.bandwidth=Number(c)),e.i.set(n,o),h.return(o))}))}(e,t),4));if(2!=r.g)return n=r.h,r.return(n.stream);if(i=S(r),e.g.hls.ignoreImageStreamFailures)return r.return(null);throw i}))})).concat(n.map((function(t){if(e.g.disableThumbnails)return null;try{var n=cg(e,t);return"image"!==n.stream.type?null:n.stream}catch(t){if(e.g.hls.ignoreImageStreamFailures)return null;throw t}}))),M(a,Promise.all(i),2)):(r=a.h,a.return(r.filter((function(e){return e}))))}))}(e,g,y),6);case 6:u=B.h,B.u(3);break;case 7:x=B.h,e.i.set(n,x),x.stream&&(A=Du(x.stream),x.stream.segmentIndex.yb((function(e){e.ba&&(e.ba.Qc=A)}))),h=x.stream.type,s.push({id:0,language:Ki(k||"und"),disabledUntilTime:0,primary:!0,audio:"audio"==h?x.stream:null,video:"video"==h?x.stream:null,bandwidth:x.stream.bandwidth||0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});case 3:if(!e.h)throw new Ye(2,7,7001);if(bg(e,r),1==r.type&&(Og(e)&&(Lg(e,r),Y=e.o,e.B.$(Y)),E=Array.from(e.i.values()),pg(e,E),rg(e),xg(e,r.X,h,m,c)),e.m={presentationTimeline:e.l,variants:s,textStreams:o,imageStreams:u,offlineSessionIds:[],minBufferTime:0,sequenceMode:e.g.hls.sequenceMode,ignoreManifestTimestampsInSegmentsMode:e.g.hls.ignoreManifestTimestampsInSegmentsMode,type:"HLS",serviceDescription:null,nextUrl:null,periodCount:1,gapCount:0,isLowLatency:!1,startTime:e.s},e.fa||!e.g.hls.disableCodecGuessing){B.u(8);break}for(P=[],C=d(e.m.variants),j=C.next();!j.done;j=C.next())(O=j.value).audio&&""===O.audio.codecs&&P.push(O.audio.createSegmentIndex()),O.video&&""===O.video.codecs&&P.push(O.video.createSegmentIndex());return M(B,Promise.all(P),8);case 8:if(e.h.makeTextStreamsForClosedCaptions(e.m),1==s.length){for(R=[],N=s[0],H=d([N.video,N.audio]),U=H.next();!U.done;U=H.next())(F=U.value)&&!F.segmentIndex&&R.push(F.createSegmentIndex());if(0<R.length)return M(B,Promise.all(R),0)}B.u(0)}}))}(i,n.data,e),3)):r.return(i.m)}))},i.stop=function(){this.B&&(this.B.stop(),this.B=null);var e=[];return this.da&&(e.push(this.da.destroy()),this.da=null),this.g=this.h=null,this.Na.clear(),this.m=null,this.i.clear(),this.H.clear(),this.G.clear(),this.A.clear(),this.ta.clear(),this.ja.clear(),this.L.clear(),this.ra.clear(),this.na.clear(),this.Aa.clear(),this.j&&this.j.destroy(),this.Z&&(this.Z.release(),this.Z=null),Promise.all(e)},i.update=function(){var e,t,n,i,r,a,s,o,u,c,h,m=this;return I((function(f){if(1==f.g){if(!Og(m))return f.return();for(e=[],t=Array.from(m.i.values()),m.o=1/0,m.m.gapCount=0,n=t.filter((function(e){return e.stream.segmentIndex})),i=d(n),r=i.next();!r.done;r=i.next())a=r.value,e.push(tg(m,a));return M(f,Promise.all(e),2)}for(fg(m,n.map((function(e){return e.stream}))),s=n.some((function(e){return 0==e.kd})),n.length&&!s&&(Rg(m,$g.vh),o=n.map((function(e){return e.Lb})),m.l.bb(Math.min.apply(Math,l(o))),m.h.updateDuration()),s&&rg(m),u=d(n),c=u.next();!c.done;c=u.next())(h=c.value).stream.isAudioMuxedInVideo||!h.stream.segmentIndex||eu(h.stream.segmentIndex)||m.h.disableStream(h.stream);w(f)}))},i.onExpirationUpdated=function(){},i.onInitialVariantChosen=function(){},i.banLocation=function(e){this.j&&this.j.banLocation(e)},i.setMediaElement=function(e){this.aa=e},U("shaka.hls.HlsParser",Zp);var Fg={aac:"audio/aac",ac3:"audio/ac3",ec3:"audio/ec3",mp3:"audio/mpeg"},Bg={audio:{mp4:"audio/mp4",mp4a:"audio/mp4",m4s:"audio/mp4",m4i:"audio/mp4",m4a:"audio/mp4",m4f:"audio/mp4",cmfa:"audio/mp4",ts:"video/mp2t",tsa:"video/mp2t"},video:{mp4:"video/mp4",mp4v:"video/mp4",m4s:"video/mp4",m4i:"video/mp4",m4v:"video/mp4",m4f:"video/mp4",cmfv:"video/mp4",ts:"video/mp2t",tsv:"video/mp2t"},text:{mp4:"application/mp4",m4s:"application/mp4",m4i:"application/mp4",m4f:"application/mp4",cmft:"application/mp4",vtt:"text/vtt",webvtt:"text/vtt",ttml:"application/ttml+xml"},image:{jpg:"image/jpeg",png:"image/png",svg:"image/svg+xml",webp:"image/webp",avif:"image/avif"}},Wg=new Set(["video/mp2t"].concat(l(ji))),zg={"com.apple.streamingkeydelivery":function(e,t){if("video/mp2t"==t)throw new Ye(2,4,4040);if(st())throw new Ye(2,4,4041);if(t=jp(e,"METHOD"),!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(t))return null;var n="cenc";return"SAMPLE-AES"==t&&(n="cbcs"),mi("com.apple.fps",n,[{initDataType:"sinf",initData:new Uint8Array(0),keyId:null}],jp(e,"URI"))},"urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":function(e){var t=jp(e,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(t))return null;var n="cenc";return"SAMPLE-AES"==t&&(n="cbcs"),n=mi("com.widevine.alpha",n,[{initDataType:"cenc",initData:t=pe((t=Qp((t=jp(e,"URI")).split("?")[0])).data)}]),(e=Cp(e,"KEYID"))&&(n.keyIds=new Set([e.toLowerCase().substr(2)])),n},"com.microsoft.playready":function(e){var t=jp(e,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(t))return null;var n="cenc";return"SAMPLE-AES"==t&&(n="cbcs"),mi("com.microsoft.playready",n,[{initDataType:"cenc",initData:e=Pa(e=pe((e=Qp((e=jp(e,"URI")).split("?")[0])).data),t=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]),new Set,0)}])}},Vg="VOD",Gg="EVENT",qg="LIVE",$g={vh:Vg,uj:Gg,Cj:qg};function Kg(e){if(e=Jg(e))e:{for(var t=(e=d(Rt(e,"DATA"))).next();!t.done;t=e.next())if(t=Nt(t.value,"LA_URL")){e=jt(t);break e}e=""}else e="";return e}function Jg(e){return(e=function(e){var t=0,n=ye(e),i=n.getUint32(t,!0);if(i!=e.byteLength)return[];e:{for(e=t+6,t=[];e<n.byteLength-1;){i=n.getUint16(e,!0),e+=2;var r=n.getUint16(e,!0);if(e+=2,1&r||r+e>n.byteLength){n=[];break e}var a=pe(n,e,r);t.push({type:i,value:a}),e+=r}n=t}return n}(e=ui(jt(e))).filter((function(e){return e.type===Xg}))[0])&&(e=Yt(e=ht(e.value,!0),"WRMHEADER"))?e:null}ls["application/x-mpegurl"]=function(){return new Zp},ls["application/vnd.apple.mpegurl"]=function(){return new Zp};var Xg=1,Qg=(new Map).set("com.microsoft.playready",Kg).set("com.microsoft.playready.recommendation",Kg).set("com.microsoft.playready.software",Kg).set("com.microsoft.playready.hardware",Kg);function Zg(e){if(!ly){ly=!0;var t=new Uint8Array([105,115,111,109]),n=new Uint8Array([97,118,99,49]),i=new Uint8Array([0,0,0,1]);by=dy("ftyp",t,i,t,n),t=dy("dref",Ty),Ly=dy("dinf",t)}this.g=e}function ey(e){for(var t=[],n=d(e.g),i=n.next();!i.done;i=n.next()){var r=t,a=r.push,s=i.value;i=dy;var o=s.id+1,u=s.stream.width||0,c=s.stream.height||0;"audio"==s.type&&(c=u=0);var h=s.duration*s.timescale,m=Math.floor(h/(cy+1));switch(h=Math.floor(h%(cy+1)),o=dy("tkhd",o=new Uint8Array([1,0,0,7,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(l(oy(o,4)),[0,0,0,0],l(oy(m,4)),l(oy(h,4)),[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0],l(oy(u,2)),[0,0],l(oy(c,2)),[0,0]))),u=dy,m=s.duration*s.timescale,c=Math.floor(m/(cy+1)),m=Math.floor(m%(cy+1)),h=(h=s.stream.language).charCodeAt(0)-96<<10|h.charCodeAt(1)-96<<5|h.charCodeAt(2)-96,c=dy("mdhd",c=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(l(oy(s.timescale,4)),l(oy(c,4)),l(oy(m,4)),l(oy(h,2)),[0,0]))),m=s,h=new Uint8Array([]),m.type){case"video":h=my;break;case"audio":h=fy}m=dy("hdlr",h);e:{switch(s.type){case"video":s=dy("minf",dy("vmhd",vy),Ly,ty(s));break e;case"audio":s=dy("minf",dy("smhd",My),Ly,ty(s));break e}s=new Uint8Array([])}i=i("trak",o,s=u("mdia",c,m,s)),a.call(r,i)}for(t=ci.apply(ai,l(t)),n=dy,i=(a=e.g[0]).duration*a.timescale,r=Math.floor(i/(cy+1)),i=Math.floor(i%(cy+1)),r=dy("mvhd",r=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(l(oy(a.timescale,4)),l(oy(r,4)),l(oy(i,4)),[0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,255]))),i=[],u=(e=d(e.g)).next();!u.done;u=e.next())o=(s=i).push,u=dy("trex",u=new Uint8Array([0,0,0,0].concat(l(oy(u.value.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0]))),o.call(s,u);if(e=dy("mvex",e=ci.apply(ai,l(i))),i=[],a.encrypted){for(s=(a=d(a.stream.drmInfos)).next();!s.done;s=a.next())if((s=s.value).initData)for(o=(s=d(s.initData)).next();!o.done;o=s.next())i.push(o.value.initData);a=ci.apply(ai,l(i))}else a=new Uint8Array([]);return e=n("moov",r,t,e,a),(t=new Uint8Array(by.byteLength+e.byteLength)).set(by),t.set(e,by.byteLength),t}function ty(e){var t=dy,n=new Uint8Array([]);switch(e.type){case"video":if(e.codecs.includes("avc1")){n=e.stream.width||0;var i=e.stream.height||0;if(0<e.za.byteLength)var r=dy("avcC",e.za);else{r=dy;for(var a=7,s=[],o=[],u=0,d=0,c=0,h=0;h<e.fb.length;h++){var m=uy(e.fb[h]);switch(31&m[0]){case 7:s.push(m),a+=m.length+2;break;case 8:o.push(m),a+=m.length+2}}for(0<s.length&&(u=s[0][1],c=s[0][2],d=s[0][3]),h=0,(a=new Uint8Array(a))[h++]=1,a[h++]=u,a[h++]=c,a[h++]=d,a[h++]=255,a[h++]=224|s.length,u=0;u<s.length;u++)a[h++]=(65280&s[u].length)>>8,a[h++]=255&s[u].length,a.set(s[u],h),h+=s[u].length;for(a[h++]=o.length,s=0;s<o.length;s++)a[h++]=(65280&o[s].length)>>8,a[h++]=255&o[s].length,a.set(o[s],h),h+=o[s].length;r=r("avcC",a)}n=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0].concat(l(oy(n,2)),l(oy(i,2)),[0,72,0,0,0,72,0,0,0,0,0,0,0,1,19,118,105,100,101,111,106,115,45,99,111,110,116,114,105,98,45,104,108,115,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17])),i="avc1",o=ny(e),s=new Uint8Array([]),e.encrypted&&(s=ry(e),i="encv"),n=dy(i,n,r,o,s)}else e.codecs.includes("hvc1")&&(i=e.stream.width||0,r=e.stream.height||0,n=new Uint8Array([]),0<e.za.byteLength&&(n=dy("hvcC",e.za)),i=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0].concat(l(oy(i,2)),l(oy(r,2)),[0,72,0,0,0,72,0,0,0,0,0,0,0,1,19,118,105,100,101,111,106,115,45,99,111,110,116,114,105,98,45,104,108,115,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17])),r="hvc1",o=ny(e),s=new Uint8Array([]),e.encrypted&&(s=ry(e),r="encv"),n=dy(r,i,n,o,s));break;case"audio":e.codecs.includes("mp3")?e=dy(".mp3",iy(e)):e.codecs.includes("ac-3")?(n=dy("dac3",e.qa),i="ac-3",r=new Uint8Array([]),e.encrypted&&(r=ry(e),i="enca"),e=dy(i,iy(e),n,r)):e.codecs.includes("ec-3")?(n=dy("dec3",e.qa),i="ec-3",r=new Uint8Array([]),e.encrypted&&(r=ry(e),i="enca"),e=dy(i,iy(e),n,r)):e.codecs.includes("opus")?(n=dy("dOps",e.qa),i="Opus",r=new Uint8Array([]),e.encrypted&&(r=ry(e),i="enca"),e=dy(i,iy(e),n,r)):(0<e.qa.byteLength?n=dy("esds",e.qa):(n=dy,i=e.id+1,r=e.stream.channelsCount||2,s=e.stream.audioSamplingRate||44100,u=pi("audio",e.codecs.split(",")),o=(d={96e3:0,88200:1,64e3:2,48e3:3,44100:4,32e3:5,24e3:6,22050:7,16e3:8,12e3:9,11025:10,8e3:11,7350:12})[s],"mp4a.40.5"!==u&&"mp4a.40.29"!==u||(o=d[2*s]),s=parseInt(u.split(".").pop(),10),n=n("esds",i=new Uint8Array([0,0,0,0,3,25].concat(l(oy(i,2)),[0,4,17,64,21,0,0,0,0,0,0,0,0,0,0,0,5,2,s<<3|o>>>1,o<<7|r<<3,6,1,2])))),i="mp4a",r=new Uint8Array([]),e.encrypted&&(r=ry(e),i="enca"),e=dy(i,iy(e),n,r)),n=e}return t("stbl",e=dy("stsd",wy,n),dy("stts",py),dy("stsc",gy),dy("stsz",_y),dy("stco",yy))}function ny(e){if(!e.Da&&!e.Fa)return new Uint8Array([]);var t=e.Fa;return dy("pasp",e=new Uint8Array([].concat(l(oy(e.Da,4)),l(oy(t,4)))))}function iy(e){return new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,e.stream.channelsCount||2,0,16,0,0,0,0].concat(l(oy(e.stream.audioSamplingRate||44100,2)),[0,0]))}function ry(e){for(var t=dy,n=e.codecs.substring(0,e.codecs.indexOf(".")),i=0,r=0;r<n.length;r+=1)i|=n.charCodeAt(r)<<8*(n.length-r-1);n=dy("frma",n=new Uint8Array([].concat(l(oy(i,4))))),i=dy("schm",i=new Uint8Array([0,0,0,0,99,101,110,99,0,1,0,0])),r=dy;for(var a=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]),s=(e=d(e.stream.drmInfos)).next();!s.done;s=e.next())if((s=s.value)&&s.keyIds&&s.keyIds.size)for(var o=(s=d(s.keyIds)).next();!o.done;o=s.next())a=uy(o.value);return t("sinf",n,i,r("schi",a=dy("tenc",e=new Uint8Array([0,0,0,0,0,0,1,8]),a)))}function ay(e){for(var t=[],n=(e=d(e.g)).next();!n.done;n=e.next()){n=n.value;var i,r=t.push,a=r.apply,s=dy,o=new Uint8Array([0,0,0,0].concat(l(oy(n.data?n.data.wb:0,4))));o=dy("mfhd",o);var u=n.data?n.data.ab:[],c=new Uint8Array(4+u.length);for(i=0;i<u.length;i++){var h=u[i].flags;c[i+4]=h.Ya<<4|h.$a<<2|h.Za}var m=(u=dy("sdtp",c)).length+92;c=dy,i=dy("tfhd",i=new Uint8Array([0,0,0,58].concat(l(oy(n.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0]))),h=n.data?n.data.baseMediaDecodeTime:0;var f=Math.floor(h%(cy+1));h=dy("tfdt",h=new Uint8Array([1,0,0,0].concat(l(oy(Math.floor(h/(cy+1)),4)),l(oy(f,4)))));var p=m,g=12+16*(f=(m=n.data?n.data.ab:[]).length),y=new Uint8Array(g);for(p+=8+g,y.set(["video"===n.type?1:0,0,15,1].concat(l(oy(f,4)),l(oy(p,4))),0),p=0;p<f;p++){var _=m[p];g=oy(_.duration,4);var v=oy(_.size,4),M=_.flags;_=oy(_.hb,4),y.set([].concat(l(g),l(v),[M.kb<<2|M.Ya,M.$a<<6|M.Za<<4|M.lb,61440&M.Xa,15&M.Xa],l(_)),12+16*p)}s=s("moof",o,u=c("traf",i,h,m=dy("trun",y),u)),a.call(r,t,[s,sy(n)])}return ci.apply(ai,l(t))}function sy(e){return e=(e.data?e.data.ab:[]).map((function(e){return e.data})),dy("mdat",e=ci.apply(ai,l(e)))}function oy(e,t){var n=[];for(--t;0<=t;t--)n.push(e>>8*t&255);return n}function uy(e){for(var t=new Uint8Array(e.length/2),n=0;n<e.length/2;n+=1)t[n]=parseInt(String(e[2*n]+e[2*n+1]),16);return t}function dy(e){var t=P.apply(1,arguments),n=hy[e];n||(n=[e.charCodeAt(0),e.charCodeAt(1),e.charCodeAt(2),e.charCodeAt(3)],hy[e]=n);for(var i=8,r=t.length-1;0<=r;r--)i+=t[r].byteLength;for((r=new Uint8Array(i))[0]=i>>24&255,r[1]=i>>16&255,r[2]=i>>8&255,r[3]=255&i,r.set(n,4),n=0,i=8;n<t.length;n++)r.set(t[n],i),i+=t[n].byteLength;return r}var ly=!1,cy=Math.pow(2,32)-1,hy={},my=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),fy=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]),py=new Uint8Array([0,0,0,0,0,0,0,0]),gy=new Uint8Array([0,0,0,0,0,0,0,0]),yy=new Uint8Array([0,0,0,0,0,0,0,0]),_y=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),vy=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0]),My=new Uint8Array([0,0,0,0,0,0,0,0]),wy=new Uint8Array([0,0,0,0,0,0,0,1]),by=new Uint8Array([]),Ty=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),Ly=new Uint8Array([]);function Sy(){var e=this;this.h=this.g=null,this.l=[],this.j=null,this.s=1,this.i=null,this.C=new W(5),this.o=new He((function(){!function(e){var t;I((function(n){switch(n.g){case 1:return b(n,2),M(n,ky(e),4);case 4:L(n,3);break;case 2:t=S(n),e.h&&(t.severity=1,e.h.onError(t));case 3:if(!e.h)return n.return();w(n)}}))}(e)})),this.B=new ea,this.m=new Map,this.A=function(){return!1}}function ky(e){var t,n,i,r,a,s,o;return I((function(u){if(1==u.g)return t=aa(e.l,e.g.retryParameters),n=e.h.networkingEngine,i=Date.now(),r=n.request(0,t,{type:5,isPreload:e.A()}),ta(e.B,r),M(u,r.promise,2);if(a=u.h,!e.h)return u.return();a.uri&&!e.l.includes(a.uri)&&e.l.unshift(a.uri);var c=a.uri,h=a.data,m=e.g.mss.manifestPreprocessor;if(m!=cd){if(se("manifest.mss.manifestPreprocessor configuration","Please Use manifest.mss.manifestPreprocessorTXml instead."),!(h=np(h,"SmoothStreamingMedia")))throw new Ye(2,4,4046,c);m(h),h=ft(h.outerHTML)}var f=At(h,"SmoothStreamingMedia");if(!f)throw new Ye(2,4,4046,c);if((c=e.g.mss.manifestPreprocessorTXml)!=hd&&c(f),e.i||(e.i=new Po(null,0)),c=Ut(f,"IsLive",Xt,!1))throw new Ye(2,4,4047);e.i.Bc(!c),m=Ut(f,"TimeScale",Kt,1e7),h=Ut(f,"DVRWindowLength",Kt),c&&(0===h||isNaN(h))&&(h=1/0);var p,g=Ut(f,"CanSeek",Xt,!1);for(0===h&&g&&(h=1/0),g=null,h&&0<h&&(g=h/m),c&&!isNaN(e.g.availabilityWindowOverride)&&(g=e.g.availabilityWindowOverride),null==g&&(g=1/0),e.i.pe(g),h=Ut(f,"Duration",Kt,1/0),c||e.i.bb(h/m),c={variants:[],textStreams:[],timescale:m,duration:h/m},g=Ct(f,"Protection"),m=e.g.mss.keySystemsBySystemId,h=[],p=(g=d(g)).next();!p.done;p=g.next())h=h.concat(Ct(p.value,"ProtectionHeader"));if(h.length){for(g=[],p=0;p<h.length;p++){var y=h[p],_=y.attributes.SystemID.toLowerCase(),v=m[_];if(v){var b=Jg(y);if(b)e:{for(var T=(b=d(Rt(b,"DATA"))).next();!T.done;T=b.next())if(T=Nt(T.value,"KID")){b=ui(jt(T)),b=li(b=new Uint8Array([b[3],b[2],b[1],b[0],b[5],b[4],b[7],b[6]].concat(l(b.slice(8)))));break e}b=null}else b=null;_=mi(v,"cenc",_=[{initData:Pa(T=ui(jt(y)),_=di(_.replace(/-/g,"")),new Set,0),initDataType:"cenc",keyId:b}]),b&&_.keyIds.add(b),(v=Qg.get(v))&&(_.licenseServerUri=v(y)),g.push(_)}}m=g}else m=[];for(p=m,g=[],m=[],h=[],y=(f=d(f=Ct(f,"StreamIndex"))).next();!y.done;y=f.next()){v=Ct(y=y.value,"QualityLevel"),_=c.timescale,b=c.duration,T=Ct(y,"c");for(var L=[],S=0,k=0;k<T.length;++k){var D=T[k],x=T[k+1],A=Ut(D,"t",Kt),Y=Ut(D,"d",Kt);if(D=Ut(D,"r",qt),!Y)break;if(A=null!=A?A:S,(D=D||0)&&D--,0>D)if(x){if(null==(x=Ut(x,"t",Kt)))break;if(A>=x)break;D=Math.ceil((x-A)/Y)-1}else{if(1/0==b)break;if(A/_>=b)break;D=Math.ceil((b*_-A)/Y)-1}for(x=0;x<=D;++x)S=A+Y,L.push({start:A/_,end:S/_,dg:A}),A=S}for(_=L,b=(v=d(v)).next();!b.done;b=v.next())(b=Dy(e,y,b.value,_,p,c))&&("audio"!=b.type||e.g.disableAudio?"video"!=b.type||e.g.disableVideo?b.type!=_i||e.g.disableText||h.push(b):m.push(b):g.push(b))}for(f=[],p=(g=d(0<g.length?g:[null])).next();!p.done;p=g.next())for(p=p.value,L=(y=d(0<m.length?m:[null])).next();!L.done;L=y.next())_=(v=f).push,b=e,T=p,L=L.value,k=0,T&&T.bandwidth&&0<T.bandwidth&&(k+=T.bandwidth),L&&L.bandwidth&&0<L.bandwidth&&(k+=L.bandwidth),b={id:b.s++,language:T?T.language:"und",disabledUntilTime:0,primary:!!T&&T.primary||!!L&&L.primary,audio:T,video:L,bandwidth:k,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},_.call(v,b);c.variants=f,c.textStreams=h,e.j?(e.j.variants=c.variants,e.j.textStreams=c.textStreams,e.h.filter(e.j)):(e.j={presentationTimeline:e.i,variants:c.variants,textStreams:c.textStreams,imageStreams:[],offlineSessionIds:[],minBufferTime:0,sequenceMode:e.g.mss.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,type:"MSS",serviceDescription:null,nextUrl:null,periodCount:1,gapCount:0,isLowLatency:!1,startTime:null},e.i.Xd()),Promise.resolve(),s=Date.now(),o=(s-i)/1e3,e.C.sample(1,o),w(u)}))}function Dy(e,t,n,i,r,a){var s=t.attributes.Type;if("audio"!==s&&"video"!==s&&"text"!==s)return $("Ignoring unrecognized type:",s),null;var o=t.attributes.Language,u=e.s++,l=Ut(n,"Bitrate",$t),c=Ut(n,"MaxWidth",$t),h=Ut(n,"MaxHeight",$t),m=Ut(n,"Channels",$t),f=Ut(n,"SamplingRate",$t),p=a.duration;i.length&&(p=i[i.length-1].end-i[0].start);var g=e.i.getDuration();e.i.bb(Math.min(p,g));var y={id:u,originalId:t.attributes.Name||String(u),groupId:null,createSegmentIndex:function(){return Promise.resolve()},closeSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:"",codecs:"",frameRate:void 0,pixelAspectRatio:void 0,bandwidth:l||0,width:c||void 0,height:h||void 0,kind:"",encrypted:0<r.length,drmInfos:r,keyIds:new Set,language:Ki(o||"und"),originalLanguage:o,label:"",type:"",primary:!1,trickModeVideo:null,emsgSchemeIdUris:[],roles:[],forced:!1,channelsCount:m,audioSamplingRate:f,spatialAudio:!1,closedCaptions:null,hdr:void 0,colorGamut:void 0,videoLayout:void 0,tilesLayout:void 0,matchedStreams:[],mssPrivateData:{duration:p,timescale:a.timescale,codecPrivateData:null},accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set,isAudioMuxedInVideo:!1};if((r=t.attributes.Subtype)&&((r=Ay[r])&&y.roles.push(r),"main"===r&&(y.primary=!0)),null!==(r=n.attributes.FourCC)&&""!==r||(r=t.attributes.FourCC),!r)if("audio"===s)r="AAC";else if("video"===s)return $('FourCC is not defined whereas it is required for a QualityLevel element for a StreamIndex of type "video"'),null;if(!xy.includes(r.toUpperCase()))return $("Codec not supported:",r),null;switch(n=function(e,t,n,i){if(e=e.attributes.CodecPrivateData)return e;if("audio"!==t)return null;t=i.channelsCount||2;var r={96e3:0,88200:1,64e3:2,48e3:3,44100:4,32e3:5,24e3:6,22050:7,16e3:8,12e3:9,11025:10,8e3:11,7350:12};return i=r[e=i.audioSamplingRate||44100],"AACH"===n?(n=new Uint8Array(4),e=r[2*e],n[0]=40|i>>1,n[1]=i<<7|t<<3|e>>1,n[2]=e<<7|8,n[3]=0,(t=new Uint16Array(2))[0]=(n[0]<<8)+n[1],t[1]=(n[2]<<8)+n[3],t[0].toString(16)+t[1].toString(16)):((n=new Uint8Array(2))[0]=16|i>>1,n[1]=i<<7|t<<3,(t=new Uint16Array(1))[0]=(n[0]<<8)+n[1],t[0].toString(16))}(n,s,r,y),y.mssPrivateData.codecPrivateData=n,s){case"audio":if(!n)return $("Quality unsupported without CodecPrivateData",s),null;y.type="audio",y.mimeType="mss/audio/mp4",y.codecs=function(e,t){var n=0;return"AACH"===e&&(n=5),t?0===n&&(n=(248&parseInt(t.substr(0,2),16))>>3):(n=2,"AACH"===e&&(n=5)),"mp4a.40."+n}(r,n);break;case"video":if(!n)return $("Quality unsupported without CodecPrivateData",s),null;y.type="video",y.mimeType="mss/video/mp4",y.codecs=function(e){var t=/00000001[0-9]7/.exec(e);return t.length&&e?"avc1."+e.substr(e.indexOf(t[0])+10,6):""}(n);break;case"text":y.type=_i,y.mimeType="application/mp4",("TTML"===r||"DFXP"===r)&&(y.codecs="stpp")}return y.fullMimeTypes.add(Ti(y.mimeType,y.codecs)),y.createSegmentIndex=function(){if(y.segmentIndex)return Promise.resolve();if(e.m.has(y.id))var n=e.m.get(y.id);else n=[],"video"==y.type&&(n=y.mssPrivateData.codecPrivateData.split("00000001").slice(1)),n=ey(new Zg([n={id:y.id,type:y.type,codecs:y.codecs,encrypted:y.encrypted,timescale:y.mssPrivateData.timescale,duration:y.mssPrivateData.duration,fb:n,qa:new Uint8Array([]),za:new Uint8Array([]),Da:0,Fa:0,data:null,stream:y}])),e.m.set(y.id,n);return n=function(e,t,n,i,r){var a=i.attributes.Url.replace("{bitrate}",String(n.bandwidth));i=[];for(var s=(r=d(r)).next(),o={};!s.done;o={se:void 0},s=r.next())o.se=s.value,i.push(new gs(o.se.start,o.se.end,function(t){return function(){return hi(e.l,[a.replace("{start time}",String(t.se.dg))])}}(o),0,null,t,0,0,n.mssPrivateData.duration));return i}(e,new fs((function(){return[]}),0,null,Du(y),y.mssPrivateData.timescale,n),y,t,i),y.segmentIndex=new Zo(n),Promise.resolve()},y.closeSegmentIndex=function(){y.segmentIndex&&(y.segmentIndex.release(),y.segmentIndex=null)},y}(i=Sy.prototype).configure=function(e,t){this.g=e,t&&(this.A=t)},i.start=function(e,t){var n=this;return I((function(i){if(1==i.g)return n.l=[e],n.h=t,M(i,ky(n),2);if(!n.h)throw new Ye(2,7,7001);return i.return(n.j)}))},i.stop=function(){return this.g=this.h=null,this.l=[],this.j=null,null!=this.o&&(this.o.stop(),this.o=null),this.m.clear(),this.B.destroy()},i.update=function(){var e,t=this;return I((function(n){return 1==n.g?(b(n,2),M(n,ky(t),4)):2!=n.g?L(n,0):(e=S(n),t.h&&e?(t.h.onError(e),void w(n)):n.return())}))},i.onExpirationUpdated=function(){},i.onInitialVariantChosen=function(){},i.banLocation=function(){},i.setMediaElement=function(){},U("shaka.mss.MssParser",Sy);var xy="AAC AACL AACH AACP AVC1 H264 TTML DFXP".split(" "),Ay={CAPT:"main",SUBT:"alternate",DESC:"main"};function Yy(e,t,n,i,r,a){if(200<=n&&299>=n&&202!=n)return{uri:r||i,originalUri:i,data:t,status:n,headers:e,fromCache:!!e["x-shaka-from-cache"]};var s=null;try{s=mt(t)}catch(e){}throw new Ye(401==n||403==n?2:1,1,1001,i,n,s,e,a,r||i)}function Ey(){}function Iy(e,t,n,i,r,a){var s=new Ny;ga(t.headers).forEach((function(e,t){s.append(t,e)}));var o=new Oy,u={ng:!1,ph:!1};if(e=function(e,t,n,i,r,a,s,o){var u,d,l,c,h,m,f,p,g,y,_,v;return I((function(T){switch(T.g){case 1:return u=jy,d=Ry,m=h=0,f=Date.now(),b(T,2),M(T,u(e,n),4);case 4:if(l=T.h,a(Py(l.headers)),"HEAD"==n.method){T.u(5);break}return p=l.clone().body.getReader(),y=(g=l.headers.get("Content-Length"))?parseInt(g,10):0,new d({start:function(e){!function t(){var n,i,a,u;return I((function(d){switch(d.g){case 1:return b(d,2),M(d,p.read(),4);case 4:n=d.h,L(d,3);break;case 2:return S(d),d.return();case 3:if(n.done){d.u(5);break}if(h+=n.value.byteLength,!s){d.u(5);break}return M(d,s(n.value),5);case 5:i=Date.now(),a=h-m,(100<i-f&&a>=o||n.done)&&(u=n.done?0:y-h,r(i-f,a,u),m=h,f=i),n.done?e.close():(e.enqueue(n.value),t()),w(d)}}))}()}}),M(T,l.arrayBuffer(),6);case 6:c=T.h;case 5:L(T,3);break;case 2:if(_=S(T),i.ng)throw new Ye(1,1,7001,e,t);if(i.ph)throw new Ye(1,1,1003,e,t);throw new Ye(1,1,1002,e,_,t);case 3:return v=Py(l.headers),T.return(Yy(v,c,l.status,e,l.url,t))}}))}(e,n,{body:t.body||void 0,headers:s,method:t.method,signal:o.signal,credentials:t.allowCrossSiteCredentials?"include":void 0},u,i,r,t.streamDataCallback,a.minBytesForProgressEvents||0),e=new zr(e,(function(){return u.ng=!0,o.abort(),Promise.resolve()})),t=t.retryParameters.timeout){var d=new He((function(){u.ph=!0,o.abort()}));d.$(t/1e3),e.finally((function(){d.stop()}))}return e}function Py(e){var t={};return e.forEach((function(e,n){t[n.trim()]=e})),t}function Cy(){if(!e.ReadableStream)return!1;try{new ReadableStream({})}catch(e){return!1}return!!e.Response&&!!new Response("").body&&!(!e.fetch||"polyfill"in e.fetch||!e.AbortController)}ls["application/vnd.ms-sstr+xml"]=function(){return new Sy},U("shaka.net.HttpFetchPlugin",Ey),Ey.isSupported=Cy,Ey.parse=Iy;var jy=e.fetch,Oy=e.AbortController,Ry=e.ReadableStream,Ny=e.Headers;function Hy(){}function Uy(e,t,n,i,r,a){var s=new By,o=Date.now(),u=0;return new zr(new Promise((function(d,l){s.open(t.method,e,!0),s.responseType="arraybuffer",s.timeout=t.retryParameters.timeout,s.withCredentials=t.allowCrossSiteCredentials,s.onabort=function(){l(new Ye(1,1,7001,e,n))};var c=!1;for(var h in s.onreadystatechange=function(){if(2==s.readyState&&!c){var e=Fy(s);r(e),c=!0}},s.onload=function(t){var r=Fy(s),a=s.response;try{i(Date.now()-o,t.loaded-u,0);var c=Yy(r,a,s.status,e,s.responseURL,n);d(c)}catch(e){l(e)}},s.onerror=function(t){l(new Ye(1,1,1002,e,t,n))},s.ontimeout=function(){l(new Ye(1,1,1003,e,n))},s.onprogress=function(e){var t=Date.now(),n=a.minBytesForProgressEvents||0,r=e.loaded-u;(100<t-o&&r>=n||e.lengthComputable&&e.loaded==e.total)&&(i(t-o,r,4==s.readyState?0:e.total-e.loaded),u=e.loaded,o=t)},t.headers)s.setRequestHeader(h.toLowerCase(),t.headers[h]);s.send(t.body)})),(function(){return s.abort(),Promise.resolve()}))}function Fy(e){var t=e.getAllResponseHeaders().trim().split("\r\n");e={};for(var n=(t=d(t)).next();!n.done;n=t.next())e[(n=n.value.split(": "))[0].toLowerCase()]=n.slice(1).join(": ");return e}Cy()&&(ia("http",Iy,2,!0),ia("https",Iy,2,!0),ia("blob",Iy,2,!0)),U("shaka.net.HttpXHRPlugin",Hy),Hy.parse=Uy;var By=e.XMLHttpRequest;function Wy(e,t,n,i){this.g=e,this.i=t,this.groupId=n,this.h=i}function zy(e){return e.N().map((function(e){return"{"+encodeURI(e.split("#xywh=")[0])+"}"})).join("")+":"+e.Ja+":"+e.va}function Vy(e,t){return Eu(e.g.N(),e.g.Ja,e.g.va,t.streaming.retryParameters)}function Gy(){this.h=this.j=this.i=0,this.g=new Map,this.l=0}function qy(e,t){e.i+=t;var n=e.l;return e.l++,e.g.set(n,t),n}function $y(e){var t=this;this.o=e,this.j=new Map,this.i=new ma((function(){return Ky(t).catch((function(){}))})),this.h=[],this.m=function(){},this.l=function(){},this.g=new Gy}function Ky(e){var t=e.h.map((function(e){return e()}));return e.h=[],Promise.all(t)}function Jy(e,t,n,i,r,a){fa(e.i);var s=(e.j.get(t)||Promise.resolve()).then((function(){var t,s,o,u,d,l,c;return I((function(h){if(1==h.g)return M(h,function(e,t){var n,i,r,a;return I((function(s){return 1==s.g?(n=la,i=e.o.request(n,t),r=function(){return i.abort()},e.h.push(r),M(s,i.promise,2)):(a=s.h,De(e.h,r),s.return(a.data))}))}(e,n),2);if(t=h.h,e.i.g)throw new Ye(2,9,7001);if(r)for(u in s=pe(t),(o=new Ia(s)).data)d=Number(u),l=o.data[d],c=o.g[d],e.l(l,c);e.g.close(i,t.byteLength);var m=e.g;return e.m(0==m.i?0:m.j/m.i,e.g.h),h.return(a(t))}))}));e.j.set(t,s)}function Xy(e,t){var n=this;this.i=e,this.h=e.objectStore(t),this.g=new Wr,e.onabort=function(e){e.preventDefault(),n.g.reject()},e.onerror=function(e){e.preventDefault(),n.g.reject()},e.oncomplete=function(){n.g.resolve()}}function Qy(e,t){return new Promise((function(n,i){var r=e.h.openCursor();r.onerror=i,r.onsuccess=function(){var e;return I((function(i){if(1==i.g)return null==r.result?(n(),i.return()):(e=r.result,M(i,t(e.key,e.value,e),2));e.continue(),w(i)}))}}))}function Zy(e){this.h=e,this.g=[]}function e_(e,t){return t_(e,t,"readwrite")}function t_(e,t,n){var i=new Xy(n=e.h.transaction([t],n),t);return e.g.push(i),i.promise().then((function(){De(e.g,i)}),(function(){De(e.g,i)})),i}function n_(e,t,n){this.h=new Zy(e),this.i=t,this.g=n}function i_(e){return Promise.reject(new Ye(2,9,9011,"Cannot add new value to "+e))}function r_(e,t,n,i){t=(e=e_(e.h,t)).store();for(var r=(n=d(n)).next(),a={};!r.done;a={wf:void 0},r=n.next())a.wf=r.value,t.delete(a.wf).onsuccess=function(e){return function(){return i(e.wf)}}(a);return e.promise()}function a_(e,t,n){var i,r,a,s,o,u,l;return I((function(c){if(1==c.g){for(i=t_(e.h,t,"readonly"),r=i.store(),a={},s=[],o=d(n),u=o.next(),l={};!u.done;l={ke:void 0,Vd:void 0},u=o.next())l.Vd=u.value,l.ke=r.get(l.Vd),l.ke.onsuccess=function(e){return function(){null==e.ke.result&&s.push(e.Vd),a[e.Vd]=e.ke.result}}(l);return M(c,i.promise(),2)}if(s.length)throw new Ye(2,9,9012,"Could not find values for "+s);return c.return(n.map((function(e){return a[e]})))}))}function s_(e){this.g=new Zy(e)}function o_(){this.g=new Map}function u_(e){var t=null;if(e.g.forEach((function(e,n){e.getCells().forEach((function(e,i){e.hasFixedKeySpace()||t||(t={path:{rb:n,Ma:i},Ma:e})}))})),t)return t;throw new Ye(2,9,9013,"Could not find a cell that supports add-operations")}function d_(e,t,n){if(!(e=e.g.get(t)))throw new Ye(2,9,9013,"Could not find mechanism with name "+t);if(!(t=e.getCells().get(n)))throw new Ye(2,9,9013,"Could not find cell with name "+n);return t}function l_(e,t){c_.set(e,t)}ia("http",Uy,1,!0),ia("https",Uy,1,!0),ia("blob",Uy,1,!0),Gy.prototype.close=function(e,t){if(this.g.has(e)){var n=this.g.get(e);this.g.delete(e),this.j+=n,this.h+=t}},$y.prototype.destroy=function(){return this.i.destroy()},Xy.prototype.abort=function(){var e=this;return I((function(t){if(1==t.g){try{e.i.abort()}catch(e){}return b(t,2),M(t,e.g,4)}if(2!=t.g)return L(t,0);S(t),w(t)}))},Xy.prototype.store=function(){return this.h},Xy.prototype.promise=function(){return this.g},Zy.prototype.destroy=function(){return Promise.all(this.g.map((function(e){return e.abort()})))},(i=n_.prototype).destroy=function(){return this.h.destroy()},i.hasFixedKeySpace=function(){return!0},i.addSegments=function(){return i_(this.i)},i.removeSegments=function(e,t){return r_(this,this.i,e,t)},i.getSegments=function(e){var t,n=this;return I((function(i){return 1==i.g?M(i,a_(n,n.i,e),2):(t=i.h,i.return(t.map((function(e){return n.qg(e)}))))}))},i.addManifests=function(){return i_(this.g)},i.updateManifest=function(){return Promise.reject(new Ye(2,9,9016,"Cannot modify values in "+this.g))},i.updateManifestExpiration=function(e,t){var n=e_(this.h,this.g),i=n.store();return i.get(e).onsuccess=function(n){(n=n.target.result)&&(n.expiration=t,i.put(n,e))},n.promise()},i.removeManifests=function(e,t){return r_(this,this.g,e,t)},i.getManifests=function(e){var t,n=this;return I((function(i){return 1==i.g?M(i,a_(n,n.g,e),2):(t=i.h,i.return(Promise.all(t.map((function(e){return n.cd(e)})))))}))},i.getAllManifests=function(){var e,t,n=this;return I((function(i){return 1==i.g?(e=t_(n.h,n.g,"readonly"),t=new Map,M(i,Qy(e,(function(e,i){var r;return I((function(a){if(1==a.g)return M(a,n.cd(i),2);r=a.h,t.set(e,r),w(a)}))})),2)):3!=i.g?M(i,e.promise(),3):i.return(t)}))},i.qg=function(e){return e},i.cd=function(e){return Promise.resolve(e)},i.add=function(e,t){var n,i,r,a,s,o,u,l=this;return I((function(c){if(1==c.g){for(n=e_(l.h,e),i=n.store(),r=[],a=d(t),s=a.next(),o={};!s.done;o={Lf:void 0},s=a.next())u=s.value,o.Lf=i.add(u),o.Lf.onsuccess=function(e){return function(){r.push(e.Lf.result)}}(o);return M(c,n.promise(),2)}return c.return(r)}))},s_.prototype.destroy=function(){return this.g.destroy()},s_.prototype.getAll=function(){var e,t,n=this;return I((function(i){return 1==i.g?(e=t_(n.g,"session-ids","readonly"),t=[],M(i,Qy(e,(function(e,n){t.push(n)})),2)):3!=i.g?M(i,e.promise(),3):i.return(t)}))},s_.prototype.add=function(e){for(var t=e_(this.g,"session-ids"),n=t.store(),i=(e=d(e)).next();!i.done;i=e.next())n.add(i.value);return t.promise()},s_.prototype.remove=function(e){var t,n=this;return I((function(i){return 1==i.g?M(i,Qy(t=e_(n.g,"session-ids"),(function(t,n,i){e.includes(n.sessionId)&&i.delete()})),2):M(i,t.promise(),0)}))},o_.prototype.destroy=function(){for(var e=[],t=d(this.g.values()),n=t.next();!n.done;n=t.next())e.push(n.value.destroy());return this.g.clear(),Promise.all(e)},o_.prototype.init=function(){var e=this;c_.forEach((function(t,n){(t=t())&&e.g.set(n,t)}));for(var t=[],n=d(this.g.values()),i=n.next();!i.done;i=n.next())t.push(i.value.init());return Promise.all(t)},U("shaka.offline.StorageMuxer",o_),o_.unregister=function(e){c_.delete(e)},o_.register=l_,o_.prototype.destroy=o_.prototype.destroy;var c_=new Map;function h_(){n_.apply(this,arguments)}function m_(e,t){!function(e){var t=e.streams.filter((function(e){return"audio"==e.contentType}));if(e=e.streams.filter((function(e){return"video"==e.contentType})),!t.every((function(e){return e.variantIds}))||!e.every((function(e){return e.variantIds}))){for(var n=d(t),i=n.next();!i.done;i=n.next())i.value.variantIds=[];for(i=(n=d(e)).next();!i.done;i=n.next())i.value.variantIds=[];if(n=0,e.length&&!t.length){i=n++;for(var r=d(e),a=r.next();!a.done;a=r.next())a.value.variantIds.push(i)}if(!e.length&&t.length)for(i=n++,a=(r=d(t)).next();!a.done;a=r.next())a.value.variantIds.push(i);if(e.length&&t.length)for(i=(t=d(t)).next();!i.done;i=t.next())for(i=i.value,a=(r=d(e)).next();!a.done;a=r.next()){a=a.value;var s=n++;i.variantIds.push(s),a.variantIds.push(s)}}}(e);for(var n=d(e.streams),i=n.next();!i.done;i=n.next());return e.streams.map((function(n){return function(e,t,n){var i=e.initSegmentUri?f_(e.initSegmentUri):null,r=t+e.presentationTimeOffset,a=t+n;return{id:e.id,originalId:null,groupId:null,primary:e.primary,type:e.contentType,mimeType:e.mimeType,codecs:e.codecs,frameRate:e.frameRate,pixelAspectRatio:void 0,hdr:void 0,colorGamut:void 0,videoLayout:void 0,kind:e.kind,language:e.language,originalLanguage:e.language||null,label:e.label,width:e.width,height:e.height,initSegmentKey:i,encrypted:e.encrypted,keyIds:new Set([e.keyId]),segments:e.segments.map((function(e){var n=f_(e.uri);return{startTime:t+e.startTime,endTime:t+e.endTime,dataKey:n,initSegmentKey:i,appendWindowStart:t,appendWindowEnd:a,timestampOffset:r,tilesLayout:"",mimeType:null,codecs:null,thumbnailSprite:null}})),variantIds:e.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0,external:!1,fastSwitching:!1,isAudioMuxedInVideo:!1}}(n,e.startTime,t)}))}function f_(e){var t;if((t=/^offline:[0-9]+\/[0-9]+\/([0-9]+)$/.exec(e))||(t=/^offline:segment\/([0-9]+)$/.exec(e)))return Number(t[1]);throw new Ye(2,9,9004,"Could not parse uri "+e)}function p_(){n_.apply(this,arguments)}function g_(e,t,n){return{id:e.id,originalId:e.originalId,groupId:null,primary:e.primary,type:e.contentType,mimeType:e.mimeType,codecs:e.codecs,frameRate:e.frameRate,pixelAspectRatio:e.pixelAspectRatio,hdr:void 0,colorGamut:void 0,videoLayout:void 0,kind:e.kind,language:e.language,originalLanguage:e.language||null,label:e.label,width:e.width,height:e.height,encrypted:e.encrypted,keyIds:new Set([e.keyId]),segments:e.segments.map((function(i){return{startTime:t+i.startTime,endTime:t+i.endTime,initSegmentKey:e.initSegmentKey,appendWindowStart:t,appendWindowEnd:n,timestampOffset:t-e.presentationTimeOffset,dataKey:i.dataKey,tilesLayout:"",mimeType:null,codecs:null,thumbnailSprite:null}})),variantIds:e.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0,external:!1,fastSwitching:!1,isAudioMuxedInVideo:!1}}function y_(){n_.apply(this,arguments)}function __(){this.m=this.j=this.i=this.h=this.g=this.l=null}function v_(e,t,n,i){this.g=e,this.i=t,this.h=n,this.l=i,this.j=["offline:",e,"/",t,"/",n,"/",i].join("")}function M_(e){if(null==(e=/^offline:([a-z]+)\/([^/]+)\/([^/]+)\/([0-9]+)$/.exec(e)))return null;var t=e[1];if("manifest"!=t&&"segment"!=t)return null;var n=e[2];if(!n)return null;var i=e[3];return i&&null!=t?new v_(t,n,i,Number(e[4])):null}function w_(e,t){this.h=e,this.g=t}function b_(e,t){var n=new Po(null,0);n.bb(t.duration);var i=t.streams.filter((function(e){return"audio"==e.type})),r=t.streams.filter((function(e){return"video"==e.type}));i=function(e,t,n,i){for(var r=new Set,a=d(t),s=a.next();!s.done;s=a.next())for(var o=(s=d(s.value.variantIds)).next();!o.done;o=s.next())r.add(o.value);for(s=(a=d(n)).next();!s.done;s=a.next())for(o=(s=d(s.value.variantIds)).next();!o.done;o=s.next())r.add(o.value);for(a=new Map,s=(r=d(r)).next();!s.done;s=r.next())s=s.value,a.set(s,{id:s,language:"",disabledUntilTime:0,primary:!1,audio:null,video:null,bandwidth:0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});for(r=(t=d(t)).next();!r.done;r=t.next())for(r=T_(e,s=r.value,i),o=(s=d(s.variantIds)).next();!o.done;o=s.next())(o=a.get(o.value)).language=r.language,o.primary=o.primary||r.primary,o.audio=r;for(t=(n=d(n)).next();!t.done;t=n.next())for(t=T_(e,r=t.value,i),s=(r=d(r.variantIds)).next();!s.done;s=r.next())(s=a.get(s.value)).primary=s.primary||t.primary,s.video=t;return a}(e,i,r,n),r=t.streams.filter((function(e){return e.type==_i})).map((function(t){return T_(e,t,n)}));var a=t.streams.filter((function(e){return"image"==e.type})).map((function(t){return T_(e,t,n)})),s=t.drmInfo?[t.drmInfo]:[];if(t.drmInfo)for(var o=d(i.values()),u=o.next();!u.done;u=o.next())(u=u.value).audio&&u.audio.encrypted&&(u.audio.drmInfos=s),u.video&&u.video.encrypted&&(u.video.drmInfos=s);return{presentationTimeline:n,minBufferTime:2,offlineSessionIds:t.sessionIds,variants:Array.from(i.values()),textStreams:r,imageStreams:a,sequenceMode:t.sequenceMode||!1,ignoreManifestTimestampsInSegmentsMode:!1,type:t.type||"UNKNOWN",serviceDescription:null,nextUrl:null,periodCount:1,gapCount:0,isLowLatency:!1,startTime:null}}function T_(e,t,n){var i=t.segments.map((function(n){return function(e,t,n){var i=new v_("segment",e.h,e.g,t.dataKey);return e=new gs(t.startTime,t.endTime,(function(){return[i.toString()]}),0,null,null!=t.initSegmentKey?function(e,t){var n=new v_("segment",e.h,e.g,t);return new fs((function(){return[n.toString()]}),0,null)}(e,t.initSegmentKey):null,t.timestampOffset,t.appendWindowStart,t.appendWindowEnd,[],t.tilesLayout||""),e.mimeType=t.mimeType||n.mimeType||"",e.codecs=t.codecs||n.codecs||"",t.thumbnailSprite&&e.qe(t.thumbnailSprite),e}(e,n,t)}));return n.vd(i),{id:t.id,originalId:t.originalId,groupId:t.groupId,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Zo(i),mimeType:t.mimeType,codecs:t.codecs,width:t.width||void 0,height:t.height||void 0,frameRate:t.frameRate,pixelAspectRatio:t.pixelAspectRatio,hdr:t.hdr,colorGamut:t.colorGamut,videoLayout:t.videoLayout,kind:t.kind,encrypted:t.encrypted,drmInfos:[],keyIds:t.keyIds,language:t.language,originalLanguage:t.originalLanguage||null,label:t.label,type:t.type,primary:t.primary,trickModeVideo:null,emsgSchemeIdUris:null,roles:t.roles,forced:t.forced,channelsCount:t.channelsCount,audioSamplingRate:t.audioSamplingRate,spatialAudio:t.spatialAudio,closedCaptions:t.closedCaptions,tilesLayout:t.tilesLayout,accessibilityPurpose:null,external:t.external,fastSwitching:t.fastSwitching,fullMimeTypes:new Set([Ti(t.mimeType,t.codecs)]),isAudioMuxedInVideo:!1}}function L_(){this.g=null}function S_(){}function k_(e){var t=M_(e);return e=t&&"manifest"==t.g?qr(e={uri:e,originalUri:e,data:new ArrayBuffer(0),headers:{"content-type":"application/x-offline-manifest"}}):t&&"segment"==t.g?function(e,t){var n=new o_;return qr(void 0).Ca((function(){return n.init()})).Ca((function(){return d_(n,t.rb(),t.Ma())})).Ca((function(e){return e.getSegments([t.key()])})).Ca((function(e){return{uri:t,data:e[0].data,headers:{}}})).finally((function(){return n.destroy()}))}(t.key(),t):Vr(new Ye(2,1,9004,e))}function D_(e,t,n){var i,r,a,s,o,u;return I((function(l){switch(l.g){case 1:i=[];for(var c=[],h=d(n),m=h.next();!m.done;m=h.next()){m=m.value;for(var f=!1,p=d(c),g=p.next();!g.done;g=p.next())if(x_((g=g.value).info,m)){g.sessionIds.push(m.sessionId),f=!0;break}f||c.push({info:m,sessionIds:[m.sessionId]})}r=d(c),a=r.next();case 2:if(a.done){l.u(4);break}return s=a.value,o=function(e,t,n){var i,r;return I((function(a){switch(a.g){case 1:return i=new Ca({Nb:t,onError:function(){},ee:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),b(a,2),i.configure(e),M(a,function(e,t,n,i,r,a){var s=new Map;return(r={audioCapabilities:r,videoCapabilities:a,distinctiveIdentifier:"optional",persistentState:"required",sessionTypes:["persistent-license"],label:t}).drmInfos=[{keySystem:t,licenseServerUri:n,distinctiveIdentifierRequired:!1,persistentStateRequired:!0,audioRobustness:"",videoRobustness:"",serverCertificate:i,serverCertificateUri:"",initData:null,keyIds:null}],s.set(t,r),Fa(e,s,[])}(i,n.info.keySystem,n.info.licenseUri,n.info.serverCertificate,n.info.audioCapabilities,n.info.videoCapabilities),4);case 4:L(a,3);break;case 2:return S(a),M(a,i.destroy(),5);case 5:return a.return([]);case 3:return r=[],M(a,Promise.all(n.sessionIds.map((function(e){return I((function(t){return 1==t.g?(b(t,2),M(t,function(e,t){var n,i,r;return I((function(a){return 1==a.g?M(a,za(e,t,{initData:null,initDataType:null}),2):3!=a.g?(n=a.h)?(i=[],(r=e.i.get(n))&&(r.nb=new Wr,i.push(r.nb)),i.push(n.remove()),M(a,Promise.all(i),3)):a.return():(e.i.delete(n),void w(a))}))}(i,e),4)):2!=t.g?(r.push(e),L(t,0)):(S(t),void w(t))}))}))),6);case 6:return M(a,i.destroy(),7);case 7:return a.return(r)}}))}(e,t,s),M(l,o,5);case 5:u=l.h,i=i.concat(u),a=r.next(),l.u(2);break;case 4:return l.return(i)}}))}function x_(e,t){function n(e,t){return e.robustness==t.robustness&&e.contentType==t.contentType}return e.keySystem==t.keySystem&&e.licenseUri==t.licenseUri&&xe(e.audioCapabilities,t.audioCapabilities,n)&&xe(e.videoCapabilities,t.videoCapabilities,n)}function A_(e,t){var n=b_(new w_(e.rb(),e.Ma()),t),i=t.appMetadata||{};return n=Y_(n),{offlineUri:e.toString(),originalManifestUri:t.originalManifestUri,duration:t.duration,size:t.size,expiration:t.expiration,tracks:n,appMetadata:i,isIncomplete:t.isIncomplete||!1}}function Y_(e){for(var t=[],n=vr(e.variants),i=(n=d(n)).next();!i.done;i=n.next())t.push(cr(i.value));for(n=(e=d(e.textStreams)).next();!n.done;n=e.next())t.push(hr(n.value));return t}function E_(){this.g={}}function I_(e,t){var n=t.audio,i=t.video;if(n&&!i&&(e.g[n.id]=n.bandwidth||t.bandwidth),!n&&i&&(e.g[i.id]=i.bandwidth||t.bandwidth),n&&i){var r=n.bandwidth||393216,a=i.bandwidth||t.bandwidth-r;0>=a&&(a=t.bandwidth),e.g[n.id]=r,e.g[i.id]=a}}function P_(e,t){e.g[t.id]=t.bandwidth||2048}function C_(e,t){return null==(e=e.g[t])&&(e=0),e}function j_(e){var t=this;if(e&&e.constructor!=dl)throw new Ye(2,9,9008);this.g=this.h=null,e?(this.h=e.g,this.g=e.Ab()):(this.h=dd(),this.g=new na),this.i=[],this.j=[];var n=!e;this.l=new ma((function(){var e,i,r,a,s;return I((function(o){switch(o.g){case 1:return M(o,Promise.all(t.j.map((function(e){return Ky(e)}))),2);case 2:for(e=function(){},i=[],r=d(t.i),a=r.next();!a.done;a=r.next())s=a.value,i.push(s.then(e,e));return M(o,Promise.all(i),3);case 3:if(!n){o.u(4);break}return M(o,t.g.destroy(),4);case 4:t.h=null,t.g=null,w(o)}}))})),this.m=1e9}function O_(){if(Ue())e:{for(var e=d(c_.values()),t=e.next();!t.done;t=e.next())if(t=(t=t.value)()){t.destroy(),e=!0;break e}e=!1}else e=!1;return e}function R_(e){var t,n,i;return I((function(r){switch(r.g){case 1:return M(r,(t=new o_).init(),2);case 2:return M(r,u_(t),3);case 3:return n=r.h,i=new v_("manifest",n.path.rb,n.path.Ma,e),M(r,t.destroy(),4);case 4:return M(r,(new j_).remove(i.toString()),0)}}))}function N_(e,t,n,i,r,a){var s,o,u,l,c,h,m,f,p,g,y;return I((function(_){switch(_.g){case 1:for(s=!1,b(_,2),o=!0,u=d(n.streams),l=u.next();!l.done;l=u.next())for(c=l.value,h=d(c.segments),m=h.next();!m.done;m=h.next())f=m.value,null!=(p=f.pendingSegmentRefId?i[f.pendingSegmentRefId]:null)&&(f.dataKey=p,f.pendingSegmentRefId=void 0),null!=(p=f.pendingInitSegmentRefId?i[f.pendingInitSegmentRefId]:null)&&(f.initSegmentKey=p,f.pendingInitSegmentRefId=void 0),f.pendingSegmentRefId&&(o=!1),f.pendingInitSegmentRefId&&(o=!1);return n.size+=r,o&&(n.isIncomplete=!1),M(_,e.updateManifest(t,n),4);case 4:s=!0,a(),L(_,0);break;case 2:return g=S(_),M(_,R_(t),5);case 5:if(s){_.u(6);break}return y=Object.values(i),M(_,e.removeSegments(y,(function(){})),6);case 6:throw g}}))}function H_(e){return e.variants.some((function(e){var t=e.audio&&e.audio.encrypted;return e.video&&e.video.encrypted||t}))}function U_(e){return e.variants.some((function(e){return(e.video?e.video.drmInfos:[]).concat(e.audio?e.audio.drmInfos:[]).some((function(e){return e.initData&&e.initData.length}))}))}function F_(e,t,n,i){if(t.expiration=n.gd(),n=Ua(n),t.sessionIds=i.offline.usePersistentLicense?n:[],H_(e)&&i.offline.usePersistentLicense&&!n.length)throw new Ye(2,9,9007)}function B_(e,t){for(var n=[],i=d(e.streams),r=i.next();!r.done;r=i.next())r=r.value,t&&"video"==r.type?n.push({contentType:Ti(r.mimeType,r.codecs),robustness:e.drmInfo.videoRobustness}):t||"audio"!=r.type||n.push({contentType:Ti(r.mimeType,r.codecs),robustness:e.drmInfo.audioRobustness});return n}function W_(e,t,n){return I((function(i){return M(i,function(e,t,n,i){var r,a,s;return I((function(o){return 1==o.g?i.drmInfo?(r=function(e){var t=Array.from(e.g.keys());if(!t.length)throw new Ye(2,9,9e3,"No supported storage mechanisms found");return e.g.get(t[0]).getEmeSessionCell()}(n),a=i.sessionIds.map((function(e){return{sessionId:e,keySystem:i.drmInfo.keySystem,licenseUri:i.drmInfo.licenseServerUri,serverCertificate:i.drmInfo.serverCertificate,audioCapabilities:B_(i,!1),videoCapabilities:B_(i,!0)}})),M(o,D_(t,e,a),2)):o.return():3!=o.g?(s=o.h,M(o,r.remove(s),3)):M(o,r.add(a.filter((function(e){return!s.includes(e.sessionId)}))),0)}))}(e.g,e.h.drm,n,t),0)}))}function z_(e,t,n){function i(){}var r=function(e){for(var t=new Set,n=(e=d(e.streams)).next();!n.done;n=e.next())for(var i=(n=d(n.value.segments)).next();!i.done;i=n.next())null!=(i=i.value).initSegmentKey&&t.add(i.initSegmentKey),t.add(i.dataKey);return Array.from(t)}(n);return A_(t,n),Promise.all([e.removeSegments(r,i),e.removeManifests([t.key()],i)])}function V_(e,t){var n;return I((function(i){switch(i.g){case 1:return b(i,2),M(i,Ld(t,e.g,e.h.streaming.retryParameters),4);case 4:n=i.h,L(i,3);break;case 2:S(i);case 3:if(n)return i.return(n);throw new Ye(1,2,2011,t)}}))}function G_(e,t,n,i,r,a){var s={id:i.id,originalId:i.originalId,groupId:i.groupId,primary:i.primary,type:i.type,mimeType:i.mimeType,codecs:i.codecs,frameRate:i.frameRate,pixelAspectRatio:i.pixelAspectRatio,hdr:i.hdr,colorGamut:i.colorGamut,videoLayout:i.videoLayout,kind:i.kind,language:i.language,originalLanguage:i.originalLanguage,label:i.label,width:i.width||null,height:i.height||null,encrypted:i.encrypted,keyIds:i.keyIds,segments:[],variantIds:[],roles:i.roles,forced:i.forced,channelsCount:i.channelsCount,audioSamplingRate:i.audioSamplingRate,spatialAudio:i.spatialAudio,closedCaptions:i.closedCaptions,tilesLayout:i.tilesLayout,external:i.external,fastSwitching:i.fastSwitching,isAudioMuxedInVideo:i.isAudioMuxedInVideo},o=r.offline.numberOfParallelDownloads,u=0===o?i.id:0;return function(e,t,n){if(null!=(t=e.segmentIndex.find(t)))for(var i=e.segmentIndex.get(t);i;)n(i),i=e.segmentIndex.get(++t)}(i,n.presentationTimeline.qb(),(function(n){var r=zy(n),d=void 0;if(!a.has(r)){var l=n.endTime-n.startTime;l=C_(t,i.id)*l,l=qy(e.g,l),a.set(r,new Wy(n,l,u,!1))}n.ba&&(d=zy(n.ba),a.has(d)||(l=.5*C_(t,i.id),l=qy(e.g,l),a.set(d,new Wy(n.ba,l,u,!0)))),s.segments.push({pendingInitSegmentRefId:d,initSegmentKey:d?0:null,startTime:n.startTime,endTime:n.endTime,appendWindowStart:n.appendWindowStart,appendWindowEnd:n.appendWindowEnd,timestampOffset:n.timestampOffset,tilesLayout:n.tilesLayout,pendingSegmentRefId:r,dataKey:0,mimeType:n.mimeType,codecs:n.codecs,thumbnailSprite:n.thumbnailSprite}),0!==o&&(u=(u+1)%o)})),s}function q_(e){if(e.l.g)throw new Ye(2,9,7001)}function $_(){if(!O_())throw new Ye(2,9,9e3)}function K_(e,t){return I((function(n){return 1==n.g?(e.i.push(t),T(n,2),M(n,t,4)):2!=n.g?n.return(n.h):(k(n),De(e.i,t),D(n,0))}))}function J_(e){for(var t=new Set,n=d(e.variants),i=n.next();!i.done;i=n.next())(i=i.value).audio&&t.add(i.audio),i.video&&t.add(i.video);for(i=(n=d(e.textStreams)).next();!i.done;i=n.next())t.add(i.value);for(n=(e=d(e.imageStreams)).next();!n.done;n=e.next())t.add(n.value);return t}g(h_,n_),h_.prototype.updateManifestExpiration=function(e,t){var n,i,r,a=this;return I((function(s){return n=e_(a.h,a.g),i=n.store(),r=new Wr,i.get(e).onsuccess=function(n){(n=n.target.result)?(n.expiration=t,i.put(n),r.resolve()):r.reject(new Ye(2,9,9012,"Could not find values for "+e))},M(s,Promise.all([n.promise(),r]),0)}))},h_.prototype.cd=function(e){var t,n,i,r,a,s;return I((function(o){if(1==o.g){for(t=[],n=0;n<e.periods.length;++n)i=n==e.periods.length-1?e.duration:e.periods[n+1].startTime,r=i-e.periods[n].startTime,a=m_(e.periods[n],r),t.push(a);return M(o,Tf(t),2)}return s=o.h,o.return({creationTime:0,originalManifestUri:e.originalManifestUri,duration:e.duration,size:e.size,expiration:null==e.expiration?1/0:e.expiration,streams:s,sessionIds:e.sessionIds,drmInfo:e.drmInfo,appMetadata:e.appMetadata,sequenceMode:!1})}))},h_.prototype.qg=function(e){return{data:e.data}},g(p_,n_),p_.prototype.cd=function(e){var t,n,i,r,a,s;return I((function(o){if(1==o.g){for(t=[],n=0;n<e.periods.length;++n){i=n==e.periods.length-1?e.duration:e.periods[n+1].startTime,r=i-e.periods[n].startTime;for(var u=e.periods[n],l=[],c=d(u.streams),h=c.next();!h.done;h=c.next())0!=(h=h.value).variantIds.length&&l.push(g_(h,u.startTime,u.startTime+r));a=l,t.push(a)}return M(o,Tf(t),2)}return s=o.h,o.return({appMetadata:e.appMetadata,creationTime:0,drmInfo:e.drmInfo,duration:e.duration,expiration:null==e.expiration?1/0:e.expiration,originalManifestUri:e.originalManifestUri,sessionIds:e.sessionIds,size:e.size,streams:s,sequenceMode:!1})}))},g(y_,n_),(i=y_.prototype).hasFixedKeySpace=function(){return!1},i.addSegments=function(e){return this.add(this.i,e)},i.addManifests=function(e){return this.add(this.g,e)},i.updateManifest=function(e,t){return function(e,t,n){var i=(e=e_(e.h,e.g)).store();return i.get(t).onsuccess=function(){i.put(n,t)},e.promise()}(this,e,t)},i.cd=function(e){return null==e.expiration&&(e.expiration=1/0),Promise.resolve(e)},(i=__.prototype).init=function(){var t=this,n=new Wr,i=!1,r=new He((function(){i=!0,n.reject(new Ye(2,9,9017))}));r.$(5);var a=e.indexedDB.open("shaka_offline_db",5);return a.onsuccess=function(){if(!i){var e=a.result;t.l=e;var s=e.objectStoreNames;s=s.contains("manifest")&&s.contains("segment")?new h_(e,"segment","manifest"):null,t.g=s,s=(s=e.objectStoreNames).contains("manifest-v2")&&s.contains("segment-v2")?new p_(e,"segment-v2","manifest-v2"):null,t.h=s,s=(s=e.objectStoreNames).contains("manifest-v3")&&s.contains("segment-v3")?new p_(e,"segment-v3","manifest-v3"):null,t.i=s,s=(s=e.objectStoreNames).contains("manifest-v5")&&s.contains("segment-v5")?new y_(e,"segment-v5","manifest-v5"):null,t.j=s,e=e.objectStoreNames.contains("session-ids")?new s_(e):null,t.m=e,r.stop(),n.resolve()}},a.onupgradeneeded=function(){for(var e=a.result,t=d(["segment-v5","manifest-v5","session-ids"]),n=t.next();!n.done;n=t.next())n=n.value,e.objectStoreNames.contains(n)||e.createObjectStore(n,{autoIncrement:!0})},a.onerror=function(e){i||(n.reject(new Ye(2,9,9001,a.error)),r.stop(),e.preventDefault())},n},i.destroy=function(){var e=this;return I((function(t){switch(t.g){case 1:if(!e.g){t.u(2);break}return M(t,e.g.destroy(),2);case 2:if(!e.h){t.u(4);break}return M(t,e.h.destroy(),4);case 4:if(!e.i){t.u(6);break}return M(t,e.i.destroy(),6);case 6:if(!e.j){t.u(8);break}return M(t,e.j.destroy(),8);case 8:if(!e.m){t.u(10);break}return M(t,e.m.destroy(),10);case 10:e.l&&e.l.close(),w(t)}}))},i.getCells=function(){var e=new Map;return this.g&&e.set("v1",this.g),this.h&&e.set("v2",this.h),this.i&&e.set("v3",this.i),this.j&&e.set("v5",this.j),e},i.getEmeSessionCell=function(){return this.m},i.erase=function(){var t=this;return I((function(n){switch(n.g){case 1:if(!t.g){n.u(2);break}return M(n,t.g.destroy(),2);case 2:if(!t.h){n.u(4);break}return M(n,t.h.destroy(),4);case 4:if(!t.i){n.u(6);break}return M(n,t.i.destroy(),6);case 6:if(!t.j){n.u(8);break}return M(n,t.j.destroy(),8);case 8:return t.l&&t.l.close(),M(n,function(){var t=new Wr,n=e.indexedDB.deleteDatabase("shaka_offline_db");return n.onblocked=function(){},n.onsuccess=function(){t.resolve()},n.onerror=function(e){t.reject(new Ye(2,9,9001,n.error)),e.preventDefault()},t}(),10);case 10:return t.l=null,t.g=null,t.h=null,t.i=null,t.j=null,M(n,t.init(),0)}}))},l_("idb",(function(){return(!qe()||qe()&&nt())&&!We()&&e.indexedDB?new __:null})),v_.prototype.rb=function(){return this.i},v_.prototype.Ma=function(){return this.h},v_.prototype.key=function(){return this.l},v_.prototype.toString=function(){return this.j},(i=L_.prototype).configure=function(){},i.start=function(e,t){var n,i,r,a,s,o,u=this;return I((function(d){switch(d.g){case 1:if(n=M_(e),u.g=n,null==n||"manifest"!=n.g)throw new Ye(2,1,9004,e);return i=new o_,T(d,2),M(d,i.init(),4);case 4:return M(d,d_(i,n.rb(),n.Ma()),5);case 5:return M(d,d.h.getManifests([n.key()]),6);case 6:return r=d.h,a=r[0],s=new w_(n.rb(),n.Ma()),o=b_(s,a),t.makeTextStreamsForClosedCaptions(o),d.return(o);case 2:return k(d),M(d,i.destroy(),7);case 7:D(d,0)}}))},i.stop=function(){return Promise.resolve()},i.update=function(){},i.onExpirationUpdated=function(e,t){var n,i,r,a,s,o,u,d=this;return I((function(l){switch(l.g){case 1:return n=d.g,i=new o_,b(l,2,3),M(l,i.init(),5);case 5:return M(l,d_(i,n.rb(),n.Ma()),6);case 6:return M(l,(r=l.h).getManifests([n.key()]),7);case 7:if(a=l.h,s=a[0],o=s.sessionIds.includes(e),u=null==s.expiration||s.expiration>t,!o||!u){l.u(3);break}return M(l,r.updateManifestExpiration(n.key(),t),3);case 3:return k(l),M(l,i.destroy(),10);case 10:D(l,0);break;case 2:S(l),l.u(3)}}))},i.onInitialVariantChosen=function(){},i.banLocation=function(){},i.setMediaElement=function(){},ls["application/x-offline-manifest"]=function(){return new L_},U("shaka.offline.OfflineScheme",S_),S_.plugin=k_,ia("offline",k_),(i=j_.prototype).destroy=function(){return this.l.destroy()},i.configure=function(e,t){return 2==arguments.length&&"string"==typeof e&&(e=ed(e,t)),ld(this.h,e)},i.getConfiguration=function(){var e=dd();return ld(e,this.h,dd()),e},i.Ab=function(){return this.g},i.store=function(e,t,n,i,r){var a=this,s=this.getConfiguration(),o=new $y(this.g);return this.j.push(o),t=function(e,t,n,i,r,a,s,o){var u,l,c,h,m,f,p,g,y,_,v,T,x,A,Y,E,P,C,j,O,R;return I((function(N){switch(N.g){case 1:return $_(),l=u=null,c=new o_,f=m=h=null,b(N,2,3),M(N,a(),5);case 5:return u=N.h,M(N,function(e,t,n,i){var r,a,s,o,u;return I((function(d){if(1==d.g)return r=null,a=e.g,s={networkingEngine:a,filter:function(){return Promise.resolve()},makeTextStreamsForClosedCaptions:function(){},onTimelineRegionAdded:function(){},onEvent:function(){},onError:function(e){r=e},isLowLatencyMode:function(){return!1},isAutoLowLatencyMode:function(){return!1},enableLowLatencyMode:function(){},updateDuration:function(){},newDrmInfo:function(){},onManifestUpdated:function(){},getBandwidthEstimate:function(){return i.abr.defaultBandwidthEstimate},onMetadata:function(){},disableStream:function(){},addFont:function(){}},n.configure(i.manifest),q_(e),M(d,n.start(t,s),2);if(3!=d.g)return o=d.h,q_(e),u=J_(o),M(d,Promise.all(pa(u,(function(e){return e.createSegmentIndex()}))),3);if(q_(e),r)throw r;return d.return(o)}))}(e,t,u,s),6);case 6:if(p=N.h,q_(e),p.presentationTimeline.U()||p.presentationTimeline.uc())throw new Ye(2,9,9005,t);g=d(i),y=g.next();case 7:if(y.done){N.u(9);break}return _=y.value,M(N,function(e,t,n){var i,r,a,s,o,u,l,c,h,m,f,p,g,y,_;return I((function(v){switch(v.g){case 1:return M(v,V_(e,t),2);case 2:if("text/vtt"!=(i=v.h))throw new Ye(1,2,2017,t);return M(v,function(e,t,n){var i,r,a;return I((function(s){return 1==s.g?(i=la,(r=aa([e],n)).method="GET",M(s,t.request(i,r).promise,2)):(a=s.h,s.return(a.data))}))}(t,e.g,e.h.streaming.retryParameters),3);case 3:if(r=v.h,!(a=Ui[i]))throw new Ye(2,2,2014,i);for(s=a(),o={periodStart:0,segmentStart:0,segmentEnd:n.presentationTimeline.getDuration(),vttOffset:0},u=pe(r),l=s.parseMedia(u,o,t,[]),c=[],h=d(l),m=h.next(),f={};!m.done;f={ye:void 0,Ic:void 0},m=h.next())f.Ic=m.value,f.ye=null,p=function(e){return function(){return null==e.ye&&(e.ye=hi([t],[e.Ic.payload])),e.ye||[]}}(f),g=new gs(f.Ic.startTime,f.Ic.endTime,p,0,null,null,0,0,1/0),f.Ic.payload.includes("#xywh")&&4===(y=f.Ic.payload.split("#xywh=")[1].split(",")).length&&g.qe({height:parseInt(y[3],10),positionX:parseInt(y[0],10),positionY:parseInt(y[1],10),width:parseInt(y[2],10)}),c.push(g);if(_=i,!c.length){v.u(4);break}return M(v,Ld(c[0].N()[0],e.g,e.h.manifest.retryParameters),5);case 5:_=v.h;case 4:return v.return({id:e.m++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Zo(c),mimeType:_||"",codecs:"",kind:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:"image",primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,tilesLayout:"1x1",accessibilityPurpose:null,external:!0,fastSwitching:!1,fullMimeTypes:new Set([Ti(_||"","")]),isAudioMuxedInVideo:!1})}}))}(e,_,p),10);case 10:v=N.h,p.imageStreams.push(v),q_(e),y=g.next(),N.u(7);break;case 9:T=d(r),x=T.next();case 11:return x.done?M(N,e.Gc(p,(function(e){f=f||e}),s),15):(A=x.value,M(N,function(e,t,n,i,r,a,s){var o;return I((function(u){if(1==u.g)return a?u.u(2):M(u,V_(e,n),3);if(2!=u.g&&(a=u.h),o={id:e.m++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:tu(0,t.presentationTimeline.getDuration(),[n]),mimeType:a||"",codecs:s||"",kind:r,encrypted:!1,drmInfos:[],keyIds:new Set,language:i,originalLanguage:i,label:null,type:_i,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!0,fastSwitching:!1,fullMimeTypes:new Set([Ti(a||"",s||"")]),isAudioMuxedInVideo:!1},!Ri(Ti(o.mimeType,o.codecs)))throw new Ye(2,2,2014,a);return u.return(o)}))}(e,p,A.uri,A.language,A.kind,A.mime,A.codecs),14));case 14:Y=N.h,p.textStreams.push(Y),q_(e),x=T.next(),N.u(11);break;case 15:if(l=N.h,q_(e),f)throw f;return M(N,function(e,t,n){var i,r,a,s,o,u,l,c,h,m,f,p,g,y,_,v,T,k,D,x,A,Y,E,P,C,j,O,R,N;return I((function(I){switch(I.g){case 1:return i={width:1/0,height:1/0},function(e,t,n){e.variants=e.variants.filter((function(e){return ir(e,t,n)}))}(e,n.restrictions,i),M(I,rr(t,e,n.offline.usePersistentLicense,n.drm.preferredKeySystems,n.drm.keySystemsMapping),2);case 2:for(r=[],a=n.preferredDecodingAttributes,s=n.preferredVideoCodecs,o=n.preferredAudioCodecs,u=n.preferredTextFormats,nr(e,s,o,a,u),l=d(e.variants),c=l.next();!c.done;c=l.next())h=c.value,r.push(cr(h));for(m=d(e.textStreams),f=m.next();!f.done;f=m.next())p=f.value,r.push(hr(p));for(g=d(e.imageStreams),y=g.next();!y.done;y=g.next())_=y.value,r.push(mr(_));return M(I,n.offline.trackSelectionCallback(r),3);case 3:for(v=I.h,T=e.presentationTimeline.getDuration(),k=0,D=d(v),x=D.next();!x.done;x=D.next())A=x.value,Y=A.bandwidth*T/8,k+=Y;return b(I,4),M(I,n.offline.downloadSizeCallback(k),6);case 6:if(!I.h)throw new Ye(2,9,9014);L(I,5);break;case 4:if((E=S(I))instanceof Ye)throw E;throw new Ye(2,9,9015);case 5:for(P=new Set,C=new Set,j=new Set,O=d(v),R=O.next();!R.done;R=O.next())"variant"==(N=R.value).type&&P.add(N.id),"text"==N.type&&C.add(N.id),"image"==N.type&&j.add(N.id);e.variants=e.variants.filter((function(e){return P.has(e.id)})),e.textStreams=e.textStreams.filter((function(e){return C.has(e.id)})),e.imageStreams=e.imageStreams.filter((function(e){return j.has(e.id)})),function(e){e.variants.map((function(e){return e.video}));var t=new Set(e.variants.map((function(e){return e.audio})));e=e.textStreams;for(var n=d(t),i=n.next();!i.done;i=n.next())for(var r=(i=d(t)).next();!r.done;r=i.next());for(n=(t=d(e)).next();!n.done;n=t.next())for(i=(n=d(e)).next();!i.done;i=n.next());}(e),w(I)}}))}(p,l,s),16);case 16:return M(N,c.init(),17);case 17:return q_(e),M(N,u_(c),18);case 18:return h=N.h,q_(e),E=function(e,t,n,i,r,a){var s=function(e,t,n){return{offlineUri:null,originalManifestUri:e,duration:t.presentationTimeline.getDuration(),size:0,expiration:1/0,tracks:t=Y_(t),appMetadata:n,isIncomplete:!1}}(n,t,i),o=r.offline.progressCallback;!function(e,t,n){e.m=function(e,t){s.size=t,o(s,e)},e.l=n}(a,0,(function(t,n){u&&r.offline.usePersistentLicense&&l==n&&Ha(e,"cenc",t)}));var u=H_(t)&&!U_(t),l=null;u&&(l=X_.get(e.g.keySystem));for(var c=new E_,h=d(t.textStreams),m=h.next();!m.done;m=h.next())c.g[m.value.id]=52;for(m=(h=d(t.imageStreams)).next();!m.done;m=h.next())P_(c,m.value);for(m=(h=d(t.variants)).next();!m.done;m=h.next())I_(c,m.value);return c=function(e,t,n,i){for(var r=new Map,a=J_(n),s=new Map,o=(a=d(a)).next();!o.done;o=a.next()){var u=G_(e,t,n,o=o.value,i,r);s.set(o.id,u)}for(t=(e=d(n.variants)).next();!t.done;t=e.next())(t=t.value).audio&&s.get(t.audio.id).variantIds.push(t.id),t.video&&s.get(t.video.id).variantIds.push(t.id);return{streams:Array.from(s.values()),ag:Array.from(r.values())}}(a,c,t,r),a=c.streams,c=c.ag,h=e.g,m=r.offline.usePersistentLicense,h&&m&&(h.initData=[]),{xi:{creationTime:Date.now(),originalManifestUri:n,duration:t.presentationTimeline.getDuration(),size:0,expiration:e.gd(),streams:a,sessionIds:m?Ua(e):[],drmInfo:h,appMetadata:i,isIncomplete:!0,sequenceMode:t.sequenceMode,type:t.type},ag:c}}(l,p,t,n,s,o),P=E.xi,C=E.ag,M(N,h.Ma.addManifests([P]),19);case 19:if(j=N.h,q_(e),m=j[0],q_(e),f)throw f;return M(N,function(e,t,n,i,r,a,s,o,u){var l,c,h,m,f,p,g,y,_,v;return I((function(T){switch(T.g){case 1:if(l={},c=0,h=function(t,h){var m,f,p,g,y,_,v;return I((function(b){if(1==b.g){for(m=d(t),f=m.next(),p={};!f.done;p={Jc:void 0},f=m.next())p.Jc=f.value,g=Vy(p.Jc,a),y=p.Jc.i,_=p.Jc.h,v=function(t){return function(n){var i,r,a;return I((function(o){if(1==o.g)return M(o,s.addSegments([{data:n}]),2);i=o.h,q_(e),r=t.Jc.g,a=zy(r),l[a]=i[0],c+=n.byteLength,w(o)}))}}(p),Jy(r,p.Jc.groupId,g,y,_,v);return M(b,function(e){return I((function(t){return 1==t.g?M(t,Promise.all(e.j.values()),2):t.return(e.g.h)}))}(r),2)}return h?(q_(e),F_(o,i,u,a),M(b,s.updateManifest(n,i),0)):b.u(0)}))},m=!1,b(T,2),!H_(o)||!m||U_(o)){T.u(4);break}return M(T,h(t.filter((function(e){return e.h})),!0),5);case 5:return q_(e),t=t.filter((function(e){return!e.h})),f=l,p=c,l={},c=0,M(T,N_(s,n,i,f,p,(function(){return q_(e)})),6);case 6:q_(e);case 4:if(m){T.u(7);break}return M(T,h(t,!1),8);case 8:return q_(e),g=l,y=c,l={},c=0,M(T,N_(s,n,i,g,y,(function(){return q_(e)})),9);case 9:q_(e);case 7:L(T,0);break;case 2:return _=S(T),v=Object.values(l),M(T,s.removeSegments(v,(function(){})),10);case 10:throw _}}))}(e,C,m,P,o,s,h.Ma,p,l),20);case 20:return q_(e),F_(p,P,l,s),M(N,h.Ma.updateManifest(m,P),21);case 21:return q_(e),O=new v_("manifest",h.path.rb,h.path.Ma,m),N.return(A_(O,P));case 3:return k(N),M(N,c.destroy(),22);case 22:if(!u){N.u(23);break}return M(N,u.stop(),23);case 23:if(!l){N.u(25);break}return M(N,l.destroy(),25);case 25:D(N,0);break;case 2:if(R=S(N),null==m){N.u(27);break}return M(N,R_(m),27);case 27:throw f||R}}))}(this,e,t||{},i||[],r||[],(function(){var t;return I((function(i){return 1==i.g?n?i.u(2):M(i,Ld(e,a.g,s.manifest.retryParameters),3):(2!=i.g&&(n=i.h),t=ds(e,n||null),i.return(t()))}))}),s,o),(t=new zr(t,(function(){return Ky(o)}))).finally((function(){De(a.j,o)})),function(e,t){var n=t.promise;return e.i.push(n),t.finally((function(){De(e.i,n)}))}(this,t)},i.remove=function(e){return K_(this,function(e,t){var n,i,r,a,s,o;return I((function(u){switch(u.g){case 1:if($_(),null==(n=M_(t))||"manifest"!=n.g)throw new Ye(2,9,9004,t);return i=n,r=new o_,T(u,2),M(u,r.init(),4);case 4:return M(u,d_(r,i.rb(),i.Ma()),5);case 5:return M(u,(a=u.h).getManifests([i.key()]),6);case 6:return s=u.h,o=s[0],M(u,Promise.all([W_(e,o,r),z_(a,i,o)]),2);case 2:return k(u),M(u,r.destroy(),8);case 8:D(u,0)}}))}(this,e))},i.Pi=function(){return K_(this,function(e){var t,n,i,r,a,s,o,u,l,c;return I((function(h){switch(h.g){case 1:return $_(),t=e.g,n=e.h.drm,i=new o_,r=!1,T(h,2),M(h,i.init(),4);case 4:a=[],function(e){e.g.forEach((function(e){var t;t=e.getEmeSessionCell(),a.push(t)}))}(i),s=d(a),o=s.next();case 5:if(o.done){h.u(2);break}return M(h,(u=o.value).getAll(),8);case 8:return l=h.h,M(h,D_(n,t,l),9);case 9:return c=h.h,M(h,u.remove(c),10);case 10:c.length!=l.length&&(r=!0),o=s.next(),h.u(5);break;case 2:return k(h),M(h,i.destroy(),11);case 11:D(h,3);break;case 3:return h.return(!r)}}))}(this))},i.list=function(){return K_(this,I((function(i){switch(i.g){case 1:return $_(),e=[],t=new o_,T(i,2),M(i,t.init(),4);case 4:return n=Promise.resolve(),function(e,t){e.g.forEach((function(e,n){e.getCells().forEach((function(e,i){t({rb:n,Ma:i},e)}))}))}(t,(function(t,i){n=n.then((function(){return I((function(n){if(1==n.g)return M(n,i.getAllManifests(),2);n.h.forEach((function(n,i){n=A_(new v_("manifest",t.rb,t.Ma,i),n),e.push(n)})),w(n)}))}))})),M(i,n,2);case 2:return k(i),M(i,t.destroy(),6);case 6:D(i,3);break;case 3:return i.return(e)}})));var e,t,n},i.Gc=function(e,t,n){var i,r=this;return I((function(a){return 1==a.g?((i=new Ca({Nb:r.g,onError:t,ee:function(){},onExpirationUpdated:function(){},onEvent:function(){}})).configure(n.drm),M(a,function(e,t,n){return e.ja=!0,e.B=new Map,e.O=n,Oa(e,t)}(i,e.variants,n.offline.usePersistentLicense),2)):3!=a.g?M(a,Na(i),3):a.return(i)}))},U("shaka.offline.Storage",j_),j_.deleteAll=function(){var e;return I((function(t){return 1==t.g?(e=new o_,T(t,2),M(t,function(e){var t,n;return I((function(i){return 1==i.g?(t=Array.from(e.g.values()),(n=0<t.length)||c_.forEach((function(e){(e=e())&&t.push(e)})),M(i,Promise.all(t.map((function(e){return e.erase()}))),2)):n?i.u(0):M(i,Promise.all(t.map((function(e){return e.destroy()}))),0)}))}(e),2)):5!=t.g?(k(t),M(t,e.destroy(),5)):D(t,0)}))},j_.prototype.list=j_.prototype.list,j_.prototype.removeEmeSessions=j_.prototype.Pi,j_.prototype.remove=j_.prototype.remove,j_.prototype.store=j_.prototype.store,j_.prototype.getNetworkingEngine=j_.prototype.Ab,j_.prototype.getConfiguration=j_.prototype.getConfiguration,j_.prototype.configure=j_.prototype.configure,j_.prototype.destroy=j_.prototype.destroy,j_.support=O_;var X_=(new Map).set("org.w3.clearkey","1077efecc0b24d02ace33c1e52e2fb4b").set("com.widevine.alpha","edef8ba979d64acea3c827dcd51d21ed").set("com.microsoft.playready","9a04f07998404286ab92e65be0885f95").set("com.microsoft.playready.recommendation","9a04f07998404286ab92e65be0885f95").set("com.microsoft.playready.software","9a04f07998404286ab92e65be0885f95").set("com.microsoft.playready.hardware","9a04f07998404286ab92e65be0885f95");function Q_(){}function Z_(e,t){for(e={priority:t||0,callback:e},t=0;t<ev.length;t++)if(ev[t].priority<e.priority)return void ev.splice(t,0,e);ev.push(e)}dc.offline=O_,U("shaka.polyfill",Q_),Q_.register=Z_,Q_.installAll=function(){for(var e=d(ev),t=e.next();!t.done;t=e.next()){t=t.value;try{t.callback()}catch(e){$("Error installing polyfill!",e)}}};var ev=[];function tv(){}function nv(){if(!Object.getOwnPropertyDescriptor(Element.prototype,"ariaHidden"))for(var e=d(["ariaHidden","ariaLabel","ariaPressed","ariaSelected"]),t=e.next();!t.done;t=e.next())iv(t.value)}function iv(e){var t="aria-"+e.toLowerCase().replace(/^aria/,"");Object.defineProperty(Element.prototype,e,{get:function(){return this.getAttribute(t)},set:function(e){null==e||null==e?this.removeAttribute(t):this.setAttribute(t,e)}})}function rv(){}function av(){Xe()||rt("Sky_STB")||gb()}function sv(){}function ov(){if(e.Document){var t=Element.prototype;t.requestFullscreen=t.requestFullscreen||t.mozRequestFullScreen||t.msRequestFullscreen||t.webkitRequestFullscreen,(t=Document.prototype).exitFullscreen=t.exitFullscreen||t.mozCancelFullScreen||t.msExitFullscreen||t.webkitCancelFullScreen,"fullscreenElement"in document||(Object.defineProperty(document,"fullscreenElement",{get:function(){return document.mozFullScreenElement||document.msFullscreenElement||document.webkitCurrentFullScreenElement||document.webkitFullscreenElement}}),Object.defineProperty(document,"fullscreenEnabled",{get:function(){return document.mozFullScreenEnabled||document.msFullscreenEnabled||document.webkitFullscreenEnabled}})),document.addEventListener("webkitfullscreenchange",uv),document.addEventListener("webkitfullscreenerror",uv),document.addEventListener("mozfullscreenchange",uv),document.addEventListener("mozfullscreenerror",uv),document.addEventListener("MSFullscreenChange",uv),document.addEventListener("MSFullscreenError",uv)}}function uv(e){var t=e.type.replace(/^(webkit|moz|MS)/,"").toLowerCase(),n=document.createEvent("Event");n.initEvent(t,e.bubbles,e.cancelable),e.target.dispatchEvent(n)}function dv(){}function lv(){var e=!0;!qe()||qe()&&nt()||qe()&&rt("Fuchsia")||(e=!1),(Ke()||Je()||Xe()||Ge()||ze()||rt("PC=EOS")||Qe()||rt("WPE"))&&(e=!1),e&&navigator.mediaCapabilities||(navigator.mediaCapabilities||(navigator.mediaCapabilities={}),hv=navigator.mediaCapabilities,navigator.mediaCapabilities.decodingInfo=cv)}function cv(t){var n,i,r,a,s;return I((function(o){switch(o.g){case 1:if(n={supported:!1,powerEfficient:!0,smooth:!0,keySystemAccess:null,configuration:t},i=t.video,r=t.audio,"media-source"!=t.type){if("file"!=t.type)return o.return(n);if(i&&!Fe(i.contentType)||r&&!Fe(r.contentType))return o.return(n);o.u(2);break}if(!Ue())return o.return(n);if(!i){o.u(3);break}return M(o,function(t){var n,i;return I((function(r){return 1==r.g?qe()?M(r,function(t){var n,i,r;return I((function(a){if(1==a.g){if(!(e.cast&&cast.__platform__&&cast.__platform__.canDisplayType))return a.return(ne(t.contentType));switch(n=t.contentType,t.width&&t.height&&(1280<t.width||720<t.height)&&(n+="; width="+t.width+"; height="+t.height),t.framerate&&(24>(i=Math.round(t.framerate))||30<i)&&(n+="; framerate="+t.framerate),t.transferFunction||""){case"":case"srgb":break;case"pq":n+="; eotf=smpte2084";break;case"hlg":n+="; eotf=arib-std-b67";break;default:return a.return(!1)}return r=!1,n in vv?(r=vv[n],a.u(2)):M(a,cast.__platform__.canDisplayType(n),3)}return 2!=a.g&&(r=a.h,vv[n]=r),a.return(r)}))}(t),3):ze()?(n=t.contentType,t.width&&t.height&&(n+="; width="+t.width,n+="; height="+t.height),t.framerate&&(n+="; framerate="+t.framerate),t.bitrate&&(n+="; bitrate="+t.bitrate),r.return(ne(n))):r.u(2):2!=r.g?(i=r.h,r.return(i)):r.return(ne(t.contentType))}))}(i),4);case 4:if(!o.h)return o.return(n);case 3:if(r){var u=r.contentType;if(qe()&&r.spatialRendering&&(u+="; spatialRendering=true"),!ne(u))return o.return(n)}case 2:return t.keySystemConfiguration?(a=t.keySystemConfiguration,M(o,function(e,t,n){var i,r,a,s,o,u,d,l,c,h,m;return I((function(f){switch(f.g){case 1:if(i=[],r=[],n.audio&&(a={robustness:n.audio.robustness||"",contentType:t.contentType},ze()&&t.contentType.includes('codecs="ac-3"')&&(a.contentType='audio/mp4; codecs="ec-3"'),n.audio.encryptionScheme&&(a.encryptionScheme=n.audio.encryptionScheme),i.push(a)),n.video&&(s={robustness:n.video.robustness||"",contentType:e.contentType},n.video.encryptionScheme&&(s.encryptionScheme=n.video.encryptionScheme),r.push(s)),o={initDataTypes:[n.initDataType],distinctiveIdentifier:n.distinctiveIdentifier,persistentState:n.persistentState,sessionTypes:n.sessionTypes},i.length&&(o.audioCapabilities=i),r.length&&(o.videoCapabilities=r),u=e?e.contentType:"",d=t?t.contentType:"",l=Yi(u)+";"+Ai(u),c=Yi(d)+";"+Ai(d),h=n.keySystem,m=null,b(f,2),Re.has(l+"#"+c+"#"+h)){m=Re.get(l+"#"+c+"#"+h)||null,f.u(4);break}return M(f,navigator.requestMediaKeySystemAccess(n.keySystem,[o]),5);case 5:m=f.h,Re.set(l+"#"+c+"#"+h,m);case 4:L(f,3);break;case 2:S(f);case 3:return f.return(m)}}))}(i,r,a),6)):(n.supported=!0,o.return(n));case 6:(s=o.h)&&(n.supported=!0,n.keySystemAccess=s);case 5:return o.return(n)}}))}Q_.Aria=tv,tv.install=nv,Z_(nv),Q_.EncryptionScheme=rv,rv.install=av,Z_(av,-2),Q_.Fullscreen=sv,sv.install=ov,Z_(ov),Q_.MediaCapabilities=dv,dv.install=lv;var hv=null;dv.originalMcap=hv;var mv,fv,pv,gv,yv,_v,vv={};function Mv(){}function wv(){var t=et();(e.MediaSource||e.ManagedMediaSource)&&(t&&e.MediaSource?10>=t?e.MediaSource=null:12>=t?(bv(),Tv()):15>=t&&bv():rt("DT_STB_BCM")?(bv(),Tv()):rt("Tizen 2")||Ve()||rt("Tizen 4")?function(){var t=MediaSource.isTypeSupported.bind(MediaSource);if(MediaSource.isTypeSupported=function(e){return"opus"!=Ai(e)&&t(e)},e.ManagedMediaSource){var n=ManagedMediaSource.isTypeSupported.bind(ManagedMediaSource);e.ManagedMediaSource.isTypeSupported=function(e){return"opus"!=Ai(e)&&n(e)}}}():rt("WPE")&&(bv(),Tv())),(e.MediaSource||e.ManagedMediaSource)&&function(){if(e.MediaSource){var t=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(e){return"mp2t"!=Di(e)&&t(e)}}if(e.ManagedMediaSource){var n=ManagedMediaSource.isTypeSupported.bind(ManagedMediaSource);e.ManagedMediaSource.isTypeSupported=function(e){return"mp2t"!=Di(e)&&n(e)}}}(),e.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&function(){var e=MediaSource.isTypeSupported;Ge()||(MediaSource.isTypeSupported=function(t){var n=t.split(/ *; */),i=n.findIndex((function(e){return e.startsWith("codecs=")}));if(0>i)return e(t);var r=n[i].replace("codecs=","").replace(/"/g,"").split(/\s*,\s*/),a=r.findIndex((function(e){return e.startsWith("vp09")}));return 0<=a&&(r[a]="vp9",n[i]='codecs="'+r.join(",")+'"',t=n.join("; ")),e(t)})}()}function bv(){var e=MediaSource.prototype.addSourceBuffer;MediaSource.prototype.addSourceBuffer=function(){var t=e.apply(this,P.apply(0,arguments));return t.abort=function(){},t}}function Tv(){var e=SourceBuffer.prototype.remove;SourceBuffer.prototype.remove=function(t,n){return e.call(this,t,n-.001)}}function Lv(){}function Sv(){screen.orientation&&screen.orientation.unlock||(null!=screen.orientation?(void 0===screen.orientation.lock&&(screen.orientation.lock=function(){return Promise.resolve()}),void 0===screen.orientation.unlock&&(screen.orientation.unlock=function(){})):null!=e.orientation&&function(){function t(){switch(e.orientation){case-90:n.type="landscape-secondary",n.angle=270;break;case 0:n.type="portrait-primary",n.angle=0;break;case 90:n.type="landscape-primary",n.angle=90;break;case 180:n.type="portrait-secondary",n.angle=180}}var n=new kv;screen.orientation=n,t(),e.addEventListener("orientationchange",(function(){t();var e=new Jr("change");n.dispatchEvent(e)}))}())}function kv(){Zr.call(this),this.type="",this.angle=0}function Dv(){}function xv(e,t){try{var n=new Ev(e,t);return Promise.resolve(n)}catch(e){return Promise.reject(e)}}function Av(e){var t=this.mediaKeys;return t&&t!=e&&Pv(t,null),delete this.mediaKeys,(this.mediaKeys=e)?Pv(e,this):Promise.resolve()}function Yv(e){if(ye(e=pe(e.initData)).getUint32(0,!0)+4!=e.byteLength)throw new RangeError("Malformed FairPlay init data");e=ft(e=ht(e.subarray(4),!0));var t=new Event("encrypted");t.initDataType="skd",t.initData=fe(e),this.dispatchEvent(t)}function Ev(e,t){if(this.keySystem=e,e.startsWith("com.apple.fps"))for(t=(e=d(t)).next();!t.done;t=e.next()){var n=t.value;if("required"==n.persistentState)t=null;else{t={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:n.initDataTypes,sessionTypes:["temporary"],label:n.label};var i=!1,r=!1;if(n.audioCapabilities)for(var a=d(n.audioCapabilities),s=a.next();!s.done;s=a.next())(s=s.value).contentType&&(i=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,s.contentType.split(";")[0])&&(t.audioCapabilities.push(s),r=!0));if(n.videoCapabilities)for(a=(n=d(n.videoCapabilities)).next();!a.done;a=n.next())(a=a.value).contentType&&(i=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,a.contentType.split(";")[0])&&(t.videoCapabilities.push(a),r=!0));i||(r=WebKitMediaKeys.isTypeSupported(this.keySystem,"video/mp4")),t=r?t:null}if(t)return void(this.g=t)}throw(e=Error("Unsupported keySystem")).name="NotSupportedError",e.code=DOMException.NOT_SUPPORTED_ERR,e}function Iv(e){this.h=new WebKitMediaKeys(e),this.g=new Z}function Pv(e,t){if(e.g.Va(),!t)return Promise.resolve();e.g.D(t,"webkitneedkey",Yv);try{return Ho(t,HTMLMediaElement.HAVE_METADATA,e.g,(function(){t.webkitSetMediaKeys(e.h)})),Promise.resolve()}catch(e){return Promise.reject(e)}}function Cv(e){Zr.call(this),this.i=null,this.l=e,this.g=this.h=null,this.j=new Z,this.sessionId="",this.expiration=NaN,this.closed=new Wr,this.keyStatuses=new Ov}function jv(e,t){var n=e.keyStatuses;n.size=null==t?0:1,n.g=t,t=new Jr("keystatuseschange"),e.dispatchEvent(t)}function Ov(){this.size=0,this.g=void 0}dv.memoizedCanDisplayTypeRequests_=vv,Z_(lv,-1),Q_.MediaSource=Mv,Mv.install=wv,Z_(wv),Q_.Orientation=Lv,Lv.install=Sv,g(kv,Zr),kv.prototype.lock=function(e){function t(e){return screen.lockOrientation?screen.lockOrientation(e):screen.mozLockOrientation?screen.mozLockOrientation(e):!!screen.msLockOrientation&&screen.msLockOrientation(e)}var n=!1;switch(e){case"natural":n=t("default");break;case"any":n=!0,this.unlock();break;default:n=t(e)}return n?Promise.resolve():((e=Error("screen.orientation.lock() is not available on this device")).name="NotSupportedError",e.code=DOMException.NOT_SUPPORTED_ERR,Promise.reject(e))},kv.prototype.unlock=function(){screen.unlockOrientation?screen.unlockOrientation():screen.mozUnlockOrientation?screen.mozUnlockOrientation():screen.msUnlockOrientation&&screen.msUnlockOrientation()},Z_(Sv),Q_.PatchedMediaKeysApple=Dv,Dv.uninstall=function(){mv&&(mv=!1,Object.defineProperty(HTMLMediaElement.prototype,"mediaKeys",fv),HTMLMediaElement.prototype.setMediaKeys=pv,e.MediaKeys=gv,e.MediaKeySystemAccess=yv,navigator.requestMediaKeySystemAccess=_v,fv=_v=pv=yv=gv=null,e.shakaMediaKeysPolyfill="")},Dv.install=function(t){e.HTMLVideoElement&&e.WebKitMediaKeys&&(void 0!==t&&t&&(mv=!0,fv=Object.getOwnPropertyDescriptor(HTMLMediaElement.prototype,"mediaKeys"),pv=HTMLMediaElement.prototype.setMediaKeys,gv=e.MediaKeys,yv=e.MediaKeySystemAccess,_v=navigator.requestMediaKeySystemAccess),delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=Av,e.MediaKeys=Iv,e.MediaKeySystemAccess=Ev,navigator.requestMediaKeySystemAccess=xv,e.shakaMediaKeysPolyfill=Rv)},Ev.prototype.createMediaKeys=function(){var e=new Iv(this.keySystem);return Promise.resolve(e)},Ev.prototype.getConfiguration=function(){return this.g},Iv.prototype.createSession=function(e){if("temporary"!=(e=e||"temporary"))throw new TypeError("Session type "+e+" is unsupported on this platform.");return new Cv(this.h,e)},Iv.prototype.setServerCertificate=function(){return Promise.resolve(!1)},Iv.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")},g(Cv,Zr),(i=Cv.prototype).generateRequest=function(e,t){var n=this;this.h=new Wr;try{var i=this.l.createSession("video/mp4",pe(t));this.i=i,this.sessionId=i.sessionId||"",this.j.D(this.i,"webkitkeymessage",(function(e){n.h&&(n.h.resolve(),n.h=null),e=new Jr("message",e=(new Map).set("messageType",null==n.keyStatuses.$b()?"license-request":"license-renewal").set("message",fe(e.message))),n.dispatchEvent(e)})),this.j.D(i,"webkitkeyadded",(function(){n.g&&(jv(n,"usable"),n.g.resolve(),n.g=null)})),this.j.D(i,"webkitkeyerror",(function(){var e=Error("EME PatchedMediaKeysApple key error");if(e.errorCode=n.i.error,null!=n.h)n.h.reject(e),n.h=null;else if(null!=n.g)n.g.reject(e),n.g=null;else switch(n.i.error.code){case WebKitMediaKeyError.MEDIA_KEYERR_OUTPUT:case WebKitMediaKeyError.MEDIA_KEYERR_HARDWARECHANGE:jv(n,"output-not-allowed");break;default:jv(n,"internal-error")}})),jv(this,"status-pending")}catch(e){this.h.reject(e)}return this.h},i.load=function(){return Promise.reject(Error("MediaKeySession.load not yet supported"))},i.update=function(e){this.g=new Wr;try{this.i.update(pe(e))}catch(e){this.g.reject(e)}return this.g},i.close=function(){try{this.i.close(),this.closed.resolve(),this.j.Va()}catch(e){this.closed.reject(e)}return this.closed},i.remove=function(){return Promise.reject(Error("MediaKeySession.remove is only applicable for persistent licenses, which are not supported on this platform"))},(i=Ov.prototype).$b=function(){return this.g},i.forEach=function(e){this.g&&e(this.g,Oe.value())},i.get=function(e){if(this.has(e))return this.g},i.has=function(e){var t=Oe.value();return!(!this.g||!me(e,t))},i.entries=function(){},i.keys=function(){},i.values=function(){};var Rv="apple";function Nv(){}function Hv(){e.MediaKeys&&(!MediaKeys.prototype.setServerCertificate||Ve()||rt("Tizen 4")||rt("Tizen 5.0")||Ge()&&38===$e())&&(MediaKeys.prototype.setServerCertificate=Uv)}function Uv(){return Promise.resolve(!1)}function Fv(){}function Bv(){!e.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=Wv,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=zv,e.MediaKeys=Vv,e.MediaKeySystemAccess=Gv,e.shakaMediaKeysPolyfill=qv)}function Wv(){return Promise.reject(Error("The key system specified is not supported."))}function zv(e){return null==e?Promise.resolve():Promise.reject(Error("MediaKeys not supported."))}function Vv(){throw new TypeError("Illegal constructor.")}function Gv(){throw this.keySystem="",new TypeError("Illegal constructor.")}Q_.PatchedMediaKeysCert=Nv,Nv.install=Hv,Z_(Hv),Q_.PatchedMediaKeysNop=Fv,Fv.install=Bv,Vv.prototype.createSession=function(){},Vv.prototype.setServerCertificate=function(){},Vv.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")},Gv.prototype.getConfiguration=function(){},Gv.prototype.createMediaKeys=function(){};var qv="nop";function $v(){}function Kv(){if(!(!e.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration)){if(HTMLMediaElement.prototype.webkitGenerateKeyRequest)uM="webkit";else if(!HTMLMediaElement.prototype.generateKeyRequest)return;navigator.requestMediaKeySystemAccess=Xv,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=Qv,e.MediaKeys=eM,e.MediaKeySystemAccess=Zv,e.shakaMediaKeysPolyfill=dM}}function Jv(e){return uM?uM+e.charAt(0).toUpperCase()+e.slice(1):e}function Xv(e,t){try{var n=new Zv(e,t);return Promise.resolve(n)}catch(e){return Promise.reject(e)}}function Qv(e){var t=this.mediaKeys;return t&&t!=e&&tM(t,null),delete this.mediaKeys,(this.mediaKeys=e)&&tM(e,this),Promise.resolve()}function Zv(e,t){this.g=this.keySystem=e;var n=!1;"org.w3.clearkey"==e&&(this.g="webkit-org.w3.clearkey",n=!1);var i=!1,r=document.getElementsByTagName("video");r=r.length?r[0]:document.createElement("video");for(var a=(t=d(t)).next();!a.done;a=t.next()){var s={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:(a=a.value).initDataTypes,sessionTypes:["temporary"],label:a.label},o=!1;if(a.audioCapabilities)for(var u=d(a.audioCapabilities),l=u.next();!l.done;l=u.next())(l=l.value).contentType&&(o=!0,r.canPlayType(l.contentType.split(";")[0],this.g)&&(s.audioCapabilities.push(l),i=!0));if(a.videoCapabilities)for(l=(u=d(a.videoCapabilities)).next();!l.done;l=u.next())(l=l.value).contentType&&(o=!0,r.canPlayType(l.contentType,this.g)&&(s.videoCapabilities.push(l),i=!0));if(o||(i=r.canPlayType("video/mp4",this.g)||r.canPlayType("video/webm",this.g)),"required"==a.persistentState&&(n?(s.persistentState="required",s.sessionTypes=["persistent-license"]):i=!1),i)return void(this.h=s)}throw n="Unsupported keySystem","org.w3.clearkey"!=e&&"com.widevine.alpha"!=e||(n="None of the requested configurations were supported."),(e=Error(n)).name="NotSupportedError",e.code=DOMException.NOT_SUPPORTED_ERR,e}function eM(e){this.l=e,this.h=null,this.g=new Z,this.i=[],this.j=new Map}function tM(e,t){e.h=t,e.g.Va();var n=uM;t&&(e.g.D(t,n+"needkey",(function(t){var n=new CustomEvent("encrypted");n.initDataType="cenc",n.initData=fe(t.initData),e.h.dispatchEvent(n)})),e.g.D(t,n+"keymessage",(function(t){var n=nM(e,t.sessionId);n&&(t=new Jr("message",t=(new Map).set("messageType",null==n.keyStatuses.$b()?"licenserequest":"licenserenewal").set("message",t.message)),n.h&&(n.h.resolve(),n.h=null),n.dispatchEvent(t))})),e.g.D(t,n+"keyadded",(function(t){(t=nM(e,t.sessionId))&&t.ready()})),e.g.D(t,n+"keyerror",(function(t){var n=nM(e,t.sessionId);if(n){var i=Error("EME v0.1b key error"),r=t.errorCode;r.systemCode=t.systemCode,i.errorCode=r,!t.sessionId&&n.h?(45==t.systemCode&&(i.message="Unsupported session type."),n.h.reject(i),n.h=null):t.sessionId&&n.g?(n.g.reject(i),n.g=null):(i=t.systemCode,t.errorCode.code==MediaKeyError.MEDIA_KEYERR_OUTPUT?sM(n,"output-restricted"):sM(n,1==i?"expired":"internal-error"))}})))}function nM(e,t){var n=e.j.get(t);return n||((n=e.i.shift())?(n.sessionId=t,e.j.set(t,n),n):null)}function iM(e,t,n){Zr.call(this),this.j=e,this.m=!1,this.g=this.h=null,this.i=t,this.l=n,this.sessionId="",this.expiration=NaN,this.closed=new Wr,this.keyStatuses=new oM}function rM(e,t,n){if(e.m)return Promise.reject(Error("The session is already initialized."));e.m=!0;try{if("persistent-license"==e.l)if(n)var i=pe(ft("LOAD_SESSION|"+n));else{var r=ft("PERSISTENT|");i=ci(r,t)}else i=pe(t)}catch(e){return Promise.reject(e)}e.h=new Wr;var a=Jv("generateKeyRequest");try{e.j[a](e.i,i)}catch(t){if("InvalidStateError"!=t.name)return e.h=null,Promise.reject(t);new He((function(){try{e.j[a](e.i,i)}catch(t){e.h.reject(t),e.h=null}})).$(.01)}return e.h}function aM(e,t,n){if(e.g)e.g.then((function(){return aM(e,t,n)})).catch((function(){return aM(e,t,n)}));else{if(e.g=t,"webkit-org.w3.clearkey"==e.i){var i=ct(n),r=JSON.parse(i);"oct"!=r.keys[0].kty&&(e.g.reject(Error("Response is not a valid JSON Web Key Set.")),e.g=null),i=ui(r.keys[0].k),r=ui(r.keys[0].kid)}else i=pe(n),r=null;var a=Jv("addKey");try{e.j[a](e.i,i,r,e.sessionId)}catch(t){e.g.reject(t),e.g=null}}}function sM(e,t){var n=e.keyStatuses;n.size=null==t?0:1,n.g=t,t=new Jr("keystatuseschange"),e.dispatchEvent(t)}function oM(){this.size=0,this.g=void 0}Z_(Bv,-10),Q_.PatchedMediaKeysWebkit=$v,$v.install=Kv,Zv.prototype.createMediaKeys=function(){var e=new eM(this.g);return Promise.resolve(e)},Zv.prototype.getConfiguration=function(){return this.h},eM.prototype.createSession=function(e){if("temporary"!=(e=e||"temporary")&&"persistent-license"!=e)throw new TypeError("Session type "+e+" is unsupported on this platform.");var t=this.h||document.createElement("video");return t.src||(t.src="about:blank"),e=new iM(t,this.l,e),this.i.push(e),e},eM.prototype.setServerCertificate=function(){return Promise.resolve(!1)},eM.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")},g(iM,Zr),(i=iM.prototype).ready=function(){sM(this,"usable"),this.g&&this.g.resolve(),this.g=null},i.generateRequest=function(e,t){return rM(this,t,null)},i.load=function(e){return"persistent-license"==this.l?rM(this,null,e):Promise.reject(Error("Not a persistent session."))},i.update=function(e){var t=new Wr;return aM(this,t,e),t},i.close=function(){if("persistent-license"!=this.l){if(!this.sessionId)return this.closed.reject(Error("The session is not callable.")),this.closed;var e=Jv("cancelKeyRequest");try{this.j[e](this.i,this.sessionId)}catch(e){}}return this.closed.resolve(),this.closed},i.remove=function(){return"persistent-license"!=this.l?Promise.reject(Error("Not a persistent session.")):this.close()},(i=oM.prototype).$b=function(){return this.g},i.forEach=function(e){this.g&&e(this.g,Oe.value())},i.get=function(e){if(this.has(e))return this.g},i.has=function(e){var t=Oe.value();return!(!this.g||!me(e,t))},i.entries=function(){},i.keys=function(){},i.values=function(){};var uM="",dM="webkit";function lM(){}function cM(){if(e.HTMLVideoElement){var t=HTMLVideoElement.prototype;t.requestPictureInPicture&&document.exitPictureInPicture||!t.webkitSupportsPresentationMode||(document.pictureInPictureEnabled=!0,document.pictureInPictureElement=null,t.requestPictureInPicture=mM,Object.defineProperty(t,"disablePictureInPicture",{get:pM,set:gM,enumerable:!0,configurable:!0}),document.exitPictureInPicture=fM,document.addEventListener("webkitpresentationmodechanged",hM,!0))}}function hM(e){if("picture-in-picture"==(e=e.target).webkitPresentationMode){document.pictureInPictureElement=e;var t=new Event("enterpictureinpicture");e.dispatchEvent(t)}else document.pictureInPictureElement==e&&(document.pictureInPictureElement=null),t=new Event("leavepictureinpicture"),e.dispatchEvent(t)}function mM(){return this.webkitSupportsPresentationMode("picture-in-picture")?(this.webkitSetPresentationMode("picture-in-picture"),document.pictureInPictureElement=this,Promise.resolve()):Promise.reject(Error("PiP not allowed by video element"))}function fM(){var e=document.pictureInPictureElement;return e?(e.webkitSetPresentationMode("inline"),document.pictureInPictureElement=null,Promise.resolve()):Promise.reject(Error("No picture in picture element found"))}function pM(){return!!this.hasAttribute("disablePictureInPicture")||!this.webkitSupportsPresentationMode("picture-in-picture")}function gM(e){e?this.setAttribute("disablePictureInPicture",""):this.removeAttribute("disablePictureInPicture")}function yM(){}function _M(){e.crypto&&("randomUUID"in e.crypto||(e.crypto.randomUUID=vM))}function vM(){var e=URL.createObjectURL(new Blob),t=e.toString();return URL.revokeObjectURL(e),t.substr(t.lastIndexOf("/")+1)}function MM(){}function wM(){var e=Symbol.prototype;"description"in e||Object.defineProperty(e,"description",{get:bM})}function bM(){var e=/\((.*)\)/.exec(this.toString());return e?e[1]:void 0}function TM(){}function LM(){if(e.HTMLMediaElement){var t=HTMLMediaElement.prototype.play;HTMLMediaElement.prototype.play=function(){var e=t.apply(this);return e&&e.catch((function(){})),e}}}function SM(){}function kM(){if(e.HTMLVideoElement){var t=HTMLVideoElement.prototype;!t.getVideoPlaybackQuality&&("webkitDroppedFrameCount"in t||Ge()&&38===$e())&&(t.getVideoPlaybackQuality=DM)}}function DM(){return{droppedVideoFrames:this.webkitDroppedFrameCount,totalVideoFrames:this.webkitDecodedFrameCount,corruptedVideoFrames:0,creationTime:NaN,totalFrameDelay:0}}function xM(){}function AM(){if(!e.VTTCue&&e.TextTrackCue){var t=null,n=TextTrackCue.length;if(3==n)t=YM;else if(6==n)t=EM;else{try{var i=!!YM(1,2,"")}catch(e){i=!1}i&&(t=YM)}t&&(e.VTTCue=function(e,n,i){return t(e,n,i)})}}function YM(t,n,i){return new e.TextTrackCue(t,n,i)}function EM(t,n,i){return new e.TextTrackCue(t+"-"+n+"-"+i,t,n,i)}function IM(){}Z_(Kv),Q_.PiPWebkit=lM,lM.install=cM,Z_(cM),Q_.RandomUUID=yM,yM.install=_M,Z_(_M),Q_.Symbol=MM,MM.install=wM,Z_(wM),Q_.VideoPlayPromise=TM,TM.install=LM,Z_(LM),Q_.VideoPlaybackQuality=SM,SM.install=kM,Z_(kM),Q_.VTTCue=xM,xM.install=AM,Z_(AM),IM.prototype.parseInit=function(){},IM.prototype.setSequenceMode=function(){},IM.prototype.setManifestType=function(){},IM.prototype.parseMedia=function(e,t){for(var n=null,i=[],r=(e=d(e=ct(e).split(/\r?\n/))).next();!r.done;r=e.next())if((r=r.value)&&!/^\s+$/.test(r)&&(r=PM.exec(r))){var a=CM.exec(r[1]);r=new un(a=60*parseInt(a[1],10)+parseFloat(a[2].replace(",",".")),t.segmentEnd?t.segmentEnd:a+2,r[2]),n&&(n.endTime=a,i.push(n)),n=r}return n&&i.push(n),i},U("shaka.text.LrcTextParser",IM),IM.prototype.parseMedia=IM.prototype.parseMedia,IM.prototype.setManifestType=IM.prototype.setManifestType,IM.prototype.setSequenceMode=IM.prototype.setSequenceMode,IM.prototype.parseInit=IM.prototype.parseInit;var PM=/^\[(\d{1,2}:\d{1,2}(?:[.,]\d{1,3})?)\](.*)/,CM=/^(\d+):(\d{1,2}(?:[.,]\d{1,3})?)$/;function jM(){}function OM(e,t,n,i,r,a,s,o,u,l,c,h,m){var f=l;if(It(e)){if(!c)return null;var p={tagName:"span",children:[jt(e)],attributes:{},parent:null}}else p=e;for(var g=null,y=d(lw),_=y.next();!_.done&&!(g=zM(p,"backgroundImage",i,"#",_.value)[0]);_=y.next());y=null;var v=/^(urn:)(mpeg:[a-z0-9][a-z0-9-]{0,31}:)(subs:)([0-9]+)$/;if((_=Wt(p,lw,"backgroundImage"))&&v.test(_)){if((y=parseInt(_.split(":").pop(),10)-1)>=m.length)return null;y=m[y]}else h&&_&&!_.startsWith("#")&&(v=new Wn(h),_=new Wn(_),(_=v.resolve(_).toString())&&(y=_));if(("p"==e.tagName||g||y)&&(c=!0),e=c,_="default"==(p.attributes["xml:space"]||(o?"default":"preserve")),o=[],!(v=p.children.every(It)))for(var M=d(p.children),w=M.next();!w.done;w=M.next())(w=OM(w.value,t,n,i,r,a,s,_,u,p,c,h,m))&&o.push(w);if(i=null!=l,h=jt(p),h=p.children.length&&h&&/\S/.test(h),!((M=p.attributes.begin||p.attributes.end||p.attributes.dur)||h||"br"==p.tagName||0!=o.length||i&&!_))return null;for(h=(m=GM(p,n)).start,m=m.end;f&&f.tagName&&"tt"!=f.tagName;)h=(m=VM(f,n,h,m)).start,m=m.end,f=f.parent;if(null==h&&(h=0),h+=t.periodStart,m=null==m?1/0:m+t.periodStart,h=Math.max(h,t.segmentStart),m=Math.min(m,t.segmentEnd),!M&&0<o.length)for(h=1/0,m=0,n=(t=d(o)).next();!n.done;n=t.next())n=n.value,h=Math.min(h,n.startTime),m=Math.max(m,n.endTime);if("br"==p.tagName)return(r=new un(h,m,"")).lineBreak=!0,r;if(t="",v&&(t=yt(jt(p)||""),_&&(t=t.replace(/\s+/g," "))),(t=new un(h,m,t)).nestedCues=o,c||(t.isContainer=!0),u&&(t.cellResolution=u),u=zM(p,"region",a,"")[0],p.attributes.region&&u&&u.attributes["xml:id"]){var b=u.attributes["xml:id"];t.region=s.filter((function(e){return e.id==b}))[0]}return s=u,l&&i&&!p.attributes.region&&!p.attributes.style&&(s=zM(l,"region",a,"")[0]),function(e,t,n,i,r,a,s,o){if("rtl"==UM(t,n,a,"direction",s=s||o)&&(e.direction="rtl"),"tb"==(o=UM(t,n,a,"writingMode",s))||"tblr"==o?e.writingMode="vertical-lr":"tbrl"==o?e.writingMode="vertical-rl":"rltb"==o||"rl"==o?e.direction="rtl":o&&(e.direction=Mn),(o=UM(t,n,a,"textAlign",!0))?(e.positionAlign=ow[o],e.lineAlign=sw[o],e.textAlign=yn[o.toUpperCase()]):e.textAlign=gn,(o=UM(t,n,a,"displayAlign",!0))&&(e.displayAlign=vn[o.toUpperCase()]),(o=UM(t,n,a,"color",s))&&(e.color=NM(o)),(o=UM(t,n,a,"backgroundColor",s))&&(e.backgroundColor=NM(o)),(o=UM(t,n,a,"border",s))&&(e.border=o),o=UM(t,n,a,"fontFamily",s))switch(o){case"monospaceSerif":e.fontFamily="Courier New,Liberation Mono,Courier,monospace";break;case"proportionalSansSerif":e.fontFamily="Arial,Helvetica,Liberation Sans,sans-serif";break;case"sansSerif":e.fontFamily="sans-serif";break;case"monospaceSansSerif":e.fontFamily="Consolas,monospace";break;case"proportionalSerif":e.fontFamily="serif";break;default:e.fontFamily=o.split(",").filter((function(e){return"default"!=e})).join(",")}switch((o=UM(t,n,a,"fontWeight",s))&&"bold"==o&&(e.fontWeight=xn),o=UM(t,n,a,"wrapOption",s),e.wrapLine=!o||"noWrap"!=o,(o=UM(t,n,a,"lineHeight",s))&&o.match(QM)&&(e.lineHeight=o),(o=UM(t,n,a,"fontSize",s))&&(o.match(QM)||o.match(XM))&&(e.fontSize=o),(o=UM(t,n,a,"fontStyle",s))&&(e.fontStyle=En[o.toUpperCase()]),i?(r=i.attributes.imageType||i.attributes.imagetype,o=i.attributes.encoding,i=jt(i).trim(),"PNG"==r&&"Base64"==o&&i&&(e.backgroundImage="data:image/png;base64,"+i)):r&&(e.backgroundImage=r),(i=UM(t,n,a,"textOutline",s))&&((i=i.split(" "))[0].match(QM)?e.textStrokeColor=e.color:(e.textStrokeColor=NM(i[0]),i.shift()),i[0]&&i[0].match(QM)?e.textStrokeWidth=i[0]:e.textStrokeColor=""),(i=UM(t,n,a,"letterSpacing",s))&&i.match(QM)&&(e.letterSpacing=i),(i=UM(t,n,a,"linePadding",s))&&i.match(QM)&&(e.linePadding=i),(i=UM(t,n,a,"opacity",s))&&(e.opacity=parseFloat(i)),(i=FM(n,a,"textDecoration"))&&HM(e,i),(i=BM(t,a,"textDecoration"))&&HM(e,i),(i=UM(t,n,a,"textCombine",s))&&(e.textCombineUpright=i),UM(t,n,a,"ruby",s)){case"container":e.rubyTag="ruby";break;case"text":e.rubyTag="rt"}}(t,p,s,g,y,r,e,0==o.length),t}function RM(e,t,n){var i=new Te,r=e.attributes["xml:id"];if(!r)return null;i.id=r,r=null,n&&(r=JM.exec(n)||ZM.exec(n)),n=r?Number(r[1]):null,r=r?Number(r[2]):null;var a,s=FM(e,t,"extent");if(s){var o=(a=JM.exec(s))||ZM.exec(s);null!=o&&(i.width=Number(o[1]),i.height=Number(o[2]),a||(null!=n&&(i.width=100*i.width/n),null!=r&&(i.height=100*i.height/r)),i.widthUnits=a||null!=n?Le:0,i.heightUnits=a||null!=r?Le:0)}return(e=FM(e,t,"origin"))&&null!=(o=(a=JM.exec(e))||ZM.exec(e))&&(i.viewportAnchorX=Number(o[1]),i.viewportAnchorY=Number(o[2]),a?s||(i.width=100-i.viewportAnchorX,i.widthUnits=Le,i.height=100-i.viewportAnchorY,i.heightUnits=Le):(null!=r&&(i.viewportAnchorY=100*i.viewportAnchorY/r),null!=n&&(i.viewportAnchorX=100*i.viewportAnchorX/n)),i.viewportAnchorUnits=a||null!=n?Le:0),i}function NM(e){var t=e.match(/rgba\(([^)]+)\)/);return t&&4==(t=t[1].split(",")).length?(t[3]=String(Number(t[3])/255),"rgba("+t.join(",")+")"):e}function HM(e,t){for(var n=(t=d(t.split(" "))).next();!n.done;n=t.next())switch(n.value){case"underline":e.textDecoration.includes(In)||e.textDecoration.push(In);break;case"noUnderline":e.textDecoration.includes(In)&&De(e.textDecoration,In);break;case"lineThrough":e.textDecoration.includes("lineThrough")||e.textDecoration.push("lineThrough");break;case"noLineThrough":e.textDecoration.includes("lineThrough")&&De(e.textDecoration,"lineThrough");break;case"overline":e.textDecoration.includes("overline")||e.textDecoration.push("overline");break;case"noOverline":e.textDecoration.includes("overline")&&De(e.textDecoration,"overline")}}function UM(e,t,n,i,r){return r=void 0===r||r,(e=BM(e,n,i))?e:r?FM(t,n,i):null}function FM(e,t,n){return e?Wt(e,dw,n)||WM(e,t,n):null}function BM(e,t,n){return Wt(e,dw,n)||WM(e,t,n)}function WM(e,t,n){e=zM(e,"style",t,"");for(var i=null,r=0;r<e.length;r++){var a=Ft(e[r],"urn:ebu:tt:style",n);a||(a=Wt(e[r],dw,n)),a||(a=BM(e[r],t,n)),a&&(i=a)}return i}function zM(e,t,n,i,r){var a=[];if(!e||1>n.length)return a;var s=e;for(e=null;!e&&!(e=r?Ft(s,r,t):s.attributes[t])&&(s=s.parent););if(t=e)for(r=(t=d(t.split(" "))).next();!r.done;r=t.next())for(r=r.value,s=(e=d(n)).next();!s.done;s=e.next())if(i+(s=s.value).attributes["xml:id"]==r){a.push(s);break}return a}function VM(e,t,n,i){return e=GM(e,t),null==n?n=e.start:null!=e.start&&(n+=e.start),null==i?i=e.end:null!=e.start&&(i+=e.start),{start:n,end:i}}function GM(e,t){var n=qM(e.attributes.begin,t),i=qM(e.attributes.end,t);return e=qM(e.attributes.dur,t),null==i&&null!=e&&(i=n+e),{start:n,end:i}}function qM(e,t){var n=null;if(ew.test(e)){e=ew.exec(e),n=Number(e[1]);var i=Number(e[2]),r=Number(e[3]),a=Number(e[4]);n=(r+=(a+=(Number(e[5])||0)/t.h)/t.frameRate)+60*i+3600*n}else if(tw.test(e))n=$M(tw,e);else if(nw.test(e))n=$M(nw,e);else if(iw.test(e))e=iw.exec(e),n=Number(e[1])/t.frameRate;else if(rw.test(e))e=rw.exec(e),n=Number(e[1])/t.g;else if(aw.test(e))n=$M(aw,e);else if(e)throw new Ye(2,2,2001,"Could not parse cue time range in TTML");return n}function $M(e,t){return null==(e=e.exec(t))||""==e[0]?null:(Number(e[4])||0)/1e3+(Number(e[3])||0)+60*(Number(e[2])||0)+3600*(Number(e[1])||0)}function KM(e,t,n,i){this.frameRate=Number(e)||30,this.h=Number(t)||1,this.g=Number(i),0==this.g&&(this.g=e?this.frameRate*this.h:1),n&&(e=/^(\d+) (\d+)$/g.exec(n))&&(this.frameRate*=Number(e[1])/Number(e[2]))}Ui["application/x-subtitle-lrc"]=function(){return new IM},jM.prototype.parseInit=function(){},jM.prototype.setSequenceMode=function(){},jM.prototype.setManifestType=function(){},jM.prototype.parseMedia=function(e,t,n,i){var r=ct(e);if(e=[],""==r)return e;var a=Yt(r,"tt",!0);if(!a)throw new Ye(2,2,2005,"Failed to parse TTML.");if(!(r=Rt(a,"body")[0]))return[];var s=Wt(a,uw,"frameRate"),o=Wt(a,uw,"subFrameRate"),u=Wt(a,uw,"frameRateMultiplier"),l=Wt(a,uw,"tickRate"),c=Wt(a,uw,"cellResolution"),h=a.attributes["xml:space"]||"default",m=Wt(a,dw,"extent");if("default"!=h&&"preserve"!=h)throw new Ye(2,2,2005,"Invalid xml:space value: "+h);h="default"==h,s=new KM(s,o,u,l),c=function(e){return e&&(e=/^(\d+) (\d+)$/.exec(e))?{lc:parseInt(e[1],10),rows:parseInt(e[2],10)}:null}(c),o=((o=Rt(a,"metadata")[0])?o.children:[]).filter((function(e){return"\n"!=e})),u=Rt(a,"style"),l=[];for(var f=d(a=Rt(a,"region")),p=f.next();!p.done;p=f.next())(p=RM(p.value,u,m))&&l.push(p);if(Ct(r,"p").length)throw new Ye(2,2,2001,"<p> can only be inside <div> in TTML");for(f=(m=d(Ct(r,"div"))).next();!f.done;f=m.next())if(Ct(f.value,"span").length)throw new Ye(2,2,2001,"<span> can only be inside <p> in TTML");return(t=OM(r,t,s,o,u,a,l,h,c,null,!1,n,i))&&(t.backgroundColor||(t.backgroundColor="transparent"),e.push(t)),e},U("shaka.text.TtmlTextParser",jM),jM.prototype.parseMedia=jM.prototype.parseMedia,jM.prototype.setManifestType=jM.prototype.setManifestType,jM.prototype.setSequenceMode=jM.prototype.setSequenceMode,jM.prototype.parseInit=jM.prototype.parseInit;var JM=/^(\d{1,2}(?:\.\d+)?|100(?:\.0+)?)% (\d{1,2}(?:\.\d+)?|100(?:\.0+)?)%$/,XM=/^(\d{1,4}(?:\.\d+)?|100)%$/,QM=/^(\d+px|\d+em|\d*\.?\d+c)$/,ZM=/^(\d+)px (\d+)px$/,ew=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,tw=/^(?:(\d{2,}):)?(\d{2}):(\d{2})$/,nw=/^(?:(\d{2,}):)?(\d{2}):(\d{2}\.\d+)$/,iw=/^(\d*(?:\.\d*)?)f$/,rw=/^(\d*(?:\.\d*)?)t$/,aw=RegExp("^(?:(\\d*(?:\\.\\d*)?)h)?(?:(\\d*(?:\\.\\d*)?)m)?(?:(\\d*(?:\\.\\d*)?)s)?(?:(\\d*(?:\\.\\d*)?)ms)?$"),sw={left:Tn,center:"center",right:"end",start:Tn,end:"end"},ow={left:"line-left",center:"center",right:"line-right"},uw=["http://www.w3.org/ns/ttml#parameter","http://www.w3.org/2006/10/ttaf1#parameter"],dw=["http://www.w3.org/ns/ttml#styling","http://www.w3.org/2006/10/ttaf1#styling"],lw=["http://www.smpte-ra.org/schemas/2052-1/2010/smpte-tt","http://www.smpte-ra.org/schemas/2052-1/2013/smpte-tt"];function cw(){this.g=new jM}function hw(){this.g="UNKNOWN"}function mw(e,t,n){var i;(i=/^align:(start|middle|center|end|left|right)$/.exec(t))?(t=i[1],e.textAlign="middle"==t?gn:yn[t.toUpperCase()]):(i=/^vertical:(lr|rl)$/.exec(t))?e.writingMode="lr"==i[1]?"vertical-lr":"vertical-rl":(i=/^size:([\d.]+)%$/.exec(t))?e.size=Number(i[1]):(i=/^position:([\d.]+)%(?:,(line-left|line-right|middle|center|start|end|auto))?$/.exec(t))?(e.position=Number(i[1]),i[2]&&(t=i[2],e.positionAlign="line-left"==t||"start"==t?"line-left":"line-right"==t||"end"==t?"line-right":"center"==t||"middle"==t?"center":pn)):(i=/^region:(.*)$/.exec(t))?(t=function(e,t){return e=e.filter((function(e){return e.id==t})),e.length?e[0]:null}(n,i[1]))&&(e.region=t):(n=/^line:([\d.]+)%(?:,(start|end|center))?$/.exec(t))?(e.lineInterpretation=1,e.line=Number(n[1]),n[2]&&(e.lineAlign=Ln[n[2].toUpperCase()])):(n=/^line:(-?\d+)(?:,(start|end|center))?$/.exec(t))&&(e.lineInterpretation=bn,e.line=Number(n[1]),n[2]&&(e.lineAlign=Ln[n[2].toUpperCase()]))}function fw(){this.g=null}function pw(e,t,n){var i,r,a;return(new wa).box("payl",ka((function(e){i=ct(e)}))).box("iden",ka((function(e){r=ct(e)}))).box("sttg",ka((function(e){a=ct(e)}))).parse(e),i?function(e,t,n,i,r){if(cn(e=new un(i,r,e)),t&&(e.id=t),n)for(n=bt(t=new vt(n));n;)mw(e,n,[]),Mt(t),n=bt(t);return e}(i,r,a,t,n):null}function gw(){}function yw(){this.g=new hw}function _w(e){var t="WEBVTT\n\n";if(""==e)return t;for(var n=(e=d((e=(e=e.replace(/\r+/g,"")).trim()).split("\n\n"))).next();!n.done;n=e.next())(n=n.value.split(/\n/))[0].match(/\d+/)&&n.shift(),n[0]=n[0].replace(/,/g,"."),t+=n.join("\n").replace(/{b}/g,"<b>").replace(/{\/b}/g,"</b>").replace(/{i}/g,"<i>").replace(/{\/i}/g,"</i>").replace(/{u}/g,"<u>").replace(/{\/u}/g,"</u>")+"\n\n";return t}function vw(){}function Mw(e,t){var n=t.Fontname;if(n&&(e.fontFamily=n),(n=t.Fontsize)&&(e.fontSize=n+"px"),(n=t.PrimaryColour)&&(n=ww(n))&&(e.color=n),(n=t.BackColour)&&(n=ww(n))&&(e.backgroundColor=n),t.Bold&&(e.fontWeight=xn),t.Italic&&(e.fontStyle=Yn),t.Underline&&e.textDecoration.push(In),(n=t.Spacing)&&(e.letterSpacing=n+"px"),n=t.Alignment)switch(parseInt(n,10)){case 1:e.displayAlign=_n,e.textAlign="start";break;case 2:e.displayAlign=_n,e.textAlign=gn;break;case 3:e.displayAlign=_n,e.textAlign="end";break;case 5:e.displayAlign="before",e.textAlign="start";break;case 6:e.displayAlign="before",e.textAlign=gn;break;case 7:e.displayAlign="before",e.textAlign="end";break;case 9:e.displayAlign="center",e.textAlign="start";break;case 10:e.displayAlign="center",e.textAlign=gn;break;case 11:e.displayAlign="center",e.textAlign="end"}(t=t.AlphaLevel)&&(e.opacity=parseFloat(t))}function ww(e){return 0<=(e=parseInt(e.replace("&H",""),16))?"rgba("+(255&e)+","+(e>>8&255)+","+(e>>16&255)+","+(e>>24&255^255)/255+")":null}function bw(e){return 3600*((e=kw.exec(e))[1]?parseInt(e[1].replace(":",""),10):0)+60*parseInt(e[2],10)+parseFloat(e[3])}Ui["application/ttml+xml"]=function(){return new jM},cw.prototype.parseInit=function(e){var t=!1;if((new wa).box("moov",ba).box("trak",ba).box("mdia",ba).box("minf",ba).box("stbl",ba).R("stsd",Ta).box("stpp",(function(e){t=!0,e.parser.stop()})).parse(e),!t)throw new Ye(2,2,2007)},cw.prototype.setSequenceMode=function(){},cw.prototype.setManifestType=function(){},cw.prototype.parseMedia=function(e,t,n){var i=this,r=!1,a=[],s=[];if((new wa).box("moof",ba).box("traf",ba).R("subs",(function(e){s=[];for(var t=e.reader,n=t.P(),i=0;i<n;i++){t.P();for(var r=t.ma(),a=0;a<r;a++)1==e.version?s.push(t.P()):s.push(t.ma()),t.T(),t.T(),t.P()}})).box("mdat",ka((function(e){if(r=!0,s.length){for(var o=pe(e,0,s[0]),u=[],d=s[0],l=1;l<s.length;l++){var c=pe(e,d,s[l]);c=si(c),u.push("data:image/png;base64,"+c),d+=s[l]}a=a.concat(i.g.parseMedia(o,t,n,u))}else a=a.concat(i.g.parseMedia(e,t,n,[]))}))).parse(e,!1),!r)throw new Ye(2,2,2007);return a},U("shaka.text.Mp4TtmlParser",cw),cw.prototype.parseMedia=cw.prototype.parseMedia,cw.prototype.setManifestType=cw.prototype.setManifestType,cw.prototype.setSequenceMode=cw.prototype.setSequenceMode,cw.prototype.parseInit=cw.prototype.parseInit,Ui['application/mp4; codecs="stpp"']=function(){return new cw},Ui['application/mp4; codecs="stpp.ttml"']=function(){return new cw},Ui['application/mp4; codecs="stpp.ttml.im1i"']=function(){return new cw},Ui['application/mp4; codecs="stpp.ttml.im1t"']=function(){return new cw},Ui['application/mp4; codecs="stpp.ttml.im2i"']=function(){return new cw},Ui['application/mp4; codecs="stpp.ttml.im2t"']=function(){return new cw},Ui['application/mp4; codecs="stpp.ttml.etd1"']=function(){return new cw},Ui['application/mp4; codecs="stpp.ttml.etd1|im1t"']=function(){return new cw},Ui['application/mp4; codecs="stpp.ttml.im1t|etd1"']=function(){return new cw},Ui['application/mp4; codecs="stpp.TTML.im1t"']=function(){return new cw},hw.prototype.parseInit=function(){},hw.prototype.setSequenceMode=function(){},hw.prototype.setManifestType=function(e){this.g=e},hw.prototype.parseMedia=function(e,t){var n=(e=(e=ct(e)).replace(/\r\n|\r(?=[^\n]|$)/gm,"\n")).split(/\n{2,}/m);if(!/^WEBVTT($|[ \t\n])/m.test(n[0]))throw new Ye(2,2,2e3);if(e=t.vttOffset,"HLS"==this.g)if(n[0].includes("X-TIMESTAMP-MAP")){var i=n[0];if(e=i.match(/LOCAL:((?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{3}))/m),i=i.match(/MPEGTS:(\d+)/m),!e||!i)throw new Ye(2,2,2e3);if(null==(e=Lt(e[1])))throw new Ye(2,2,2e3);i=Number(i[1]);for(var r=t.segmentStart-t.periodStart;95443.7176888889<=r;)r-=95443.7176888889,i+=8589934592;e=t.periodStart+i/9e4-e}else t.periodStart&&t.vttOffset==t.periodStart&&(e=0);for(t=[],r=(i=d(n[0].split("\n"))).next();!r.done;r=i.next())if(r=r.value,/^Region:/.test(r)){r=new vt(r);var a=new Te;bt(r),Mt(r);for(var s=bt(r);s;){var o=a,u=s;(s=/^id=(.*)$/.exec(u))?o.id=s[1]:(s=/^width=(\d{1,2}|100)%$/.exec(u))?o.width=Number(s[1]):(s=/^lines=(\d+)$/.exec(u))?(o.height=Number(s[1]),o.heightUnits=2):(s=/^regionanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(u))?(o.regionAnchorX=Number(s[1]),o.regionAnchorY=Number(s[2])):(s=/^viewportanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(u))?(o.viewportAnchorX=Number(s[1]),o.viewportAnchorY=Number(s[2])):/^scroll=up$/.exec(u)&&(o.scroll="up"),Mt(r),s=bt(r)}t.push(a)}for(hn(i=new Map),r=[],a=(n=d(n.slice(1))).next();!a.done;a=n.next()){if((1!=(a=a.value.split("\n")).length||a[0])&&!/^NOTE($|[ \t])/.test(a[0])&&"STYLE"==a[0]){for(o=[],s=-1,u=1;u<a.length;u++)a[u].includes("::cue")&&(o.push([]),s=o.length-1),-1!=s&&(o[s].push(a[u]),a[u].includes("}")&&(s=-1));for(s=(o=d(o)).next();!s.done;s=o.next()){var l=s.value;s="global",(u=l[0].match(/\((.*)\)/))&&(s=u.pop()),u=l.slice(1,-1),l[0].includes("}")&&(l=/\{(.*?)\}/.exec(l[0]))&&(u=l[1].split(";")),(l=i.get(s))||(l=new un(0,0,""));for(var c=!1,h=0;h<u.length;h++){var m=/^\s*([^:]+):\s*(.*)/.exec(u[h]);if(m){var f=m[2].trim().replace(";","");switch(m[1].trim()){case"background-color":case"background":c=!0,l.backgroundColor=f;break;case"color":c=!0,l.color=f;break;case"font-family":c=!0,l.fontFamily=f;break;case"font-size":c=!0,l.fontSize=f;break;case"font-weight":(700<=parseInt(f,10)||"bold"==f)&&(c=!0,l.fontWeight=xn);break;case"font-style":switch(f){case"normal":c=!0,l.fontStyle=An;break;case"italic":c=!0,l.fontStyle=Yn;break;case"oblique":c=!0,l.fontStyle="oblique"}break;case"opacity":c=!0,l.opacity=parseFloat(f);break;case"text-combine-upright":c=!0,l.textCombineUpright=f;break;case"text-shadow":c=!0,l.textShadow=f;break;case"white-space":c=!0,l.wrapLine="noWrap"!=f}}}c&&i.set(s,l)}}if(c=e,1==(l=a).length&&!l[0]||/^NOTE($|[ \t])/.test(l[0])||"STYLE"==l[0]||"REGION"==l[0])a=null;else if(a=null,l[0].includes("--\x3e")||(a=l[0],l.splice(0,1)),s=Tt(o=new vt(l[0])),h=wt(o,/[ \t]+--\x3e[ \t]+/g),u=Tt(o),null==s||null==h||null==u)$("Failed to parse VTT time code. Cue skipped:",a,l),a=null;else{for(s+=c,u+=c,c=l.slice(1).join("\n").trim(),i.has("global")?((l=i.get("global").clone()).startTime=s,l.endTime=u,l.payload=c):l=new un(s,u,c),Mt(o),s=bt(o);s;)mw(l,s,t),Mt(o),s=bt(o);cn(l,i),null!=a&&(l.id=a),a=l}a&&r.push(a)}return r},U("shaka.text.VttTextParser",hw),hw.prototype.parseMedia=hw.prototype.parseMedia,hw.prototype.setManifestType=hw.prototype.setManifestType,hw.prototype.setSequenceMode=hw.prototype.setSequenceMode,hw.prototype.parseInit=hw.prototype.parseInit,Ui["text/vtt"]=function(){return new hw},Ui['text/vtt; codecs="vtt"']=function(){return new hw},Ui['text/vtt; codecs="wvtt"']=function(){return new hw},fw.prototype.parseInit=function(e){var t=this,n=!1;if((new wa).box("moov",ba).box("trak",ba).box("mdia",ba).R("mdhd",(function(e){e=Rs(e.reader,e.version),t.g=e.timescale})).box("minf",ba).box("stbl",ba).R("stsd",Ta).box("wvtt",(function(){n=!0})).parse(e),!this.g)throw new Ye(2,2,2008);if(!n)throw new Ye(2,2,2008)},fw.prototype.setSequenceMode=function(){},fw.prototype.setManifestType=function(){},fw.prototype.parseMedia=function(e,t){if(!e.length)return[];if(!this.g)throw new Ye(2,2,2008);var n,i=0,r=[],a=[],s=!1,o=!1,u=!1,l=null;if((new wa).box("moof",ba).box("traf",ba).R("tfdt",(function(e){s=!0,i=Os(e.reader,e.version).baseMediaDecodeTime})).R("tfhd",(function(e){l=js(e.reader,e.flags).ed})).R("trun",(function(e){o=!0,r=Ns(e.reader,e.version,e.flags).Zg})).box("mdat",ka((function(e){u=!0,n=e}))).parse(e,!1),!u&&!s&&!o)throw new Ye(2,2,2008);e=i;for(var c=new _a(n,0),h=d(r),m=h.next();!m.done;m=h.next()){var f=(m=m.value).Of||l,p=m.me?i+m.me:e;e=p+(f||0);var g=0;do{var y=c.P();g+=y;var _=null;"vttc"==xa(c.P())?8<y&&(_=c.vb(y-8)):c.skip(y-8),f&&_&&(y=pw(_,t.periodStart+p/this.g,t.periodStart+e/this.g),a.push(y))}while(m.sampleSize&&g<m.sampleSize)}return a.filter(Wi)},U("shaka.text.Mp4VttParser",fw),fw.prototype.parseMedia=fw.prototype.parseMedia,fw.prototype.setManifestType=fw.prototype.setManifestType,fw.prototype.setSequenceMode=fw.prototype.setSequenceMode,fw.prototype.parseInit=fw.prototype.parseInit,Ui['application/mp4; codecs="wvtt"']=function(){return new fw},gw.prototype.parseInit=function(){},gw.prototype.setSequenceMode=function(){},gw.prototype.setManifestType=function(){},gw.prototype.parseMedia=function(e){var t=ct(e).replace(/\r+/g,"");if(e=[],""==(t=t.trim()))return e;for(var n=(t=d(t.split("\n\n"))).next();!n.done;n=t.next()){var i=new vt((n=n.value.split("\n"))[0]),r=Tt(i),a=wt(i,/,/g);if(i=Tt(i),null==r||null==a||null==i)throw new Ye(2,2,2001,"Could not parse cue time range in SubViewer");e.push(new un(r,i,n.slice(1).join("\n").trim()))}return e},U("shaka.text.SbvTextParser",gw),gw.prototype.parseMedia=gw.prototype.parseMedia,gw.prototype.setManifestType=gw.prototype.setManifestType,gw.prototype.setSequenceMode=gw.prototype.setSequenceMode,gw.prototype.parseInit=gw.prototype.parseInit,Ui["text/x-subviewer"]=function(){return new gw},yw.prototype.parseInit=function(){},yw.prototype.setSequenceMode=function(){},yw.prototype.setManifestType=function(){},yw.prototype.parseMedia=function(e,t,n){return e=pe(ft(e=_w(e=ct(e)))),this.g.parseMedia(e,t,n,[])},U("shaka.text.SrtTextParser",yw),yw.srt2webvtt=_w,yw.prototype.parseMedia=yw.prototype.parseMedia,yw.prototype.setManifestType=yw.prototype.setManifestType,yw.prototype.setSequenceMode=yw.prototype.setSequenceMode,yw.prototype.parseInit=yw.prototype.parseInit,Ui["text/srt"]=function(){return new yw},vw.prototype.parseInit=function(){},vw.prototype.setSequenceMode=function(){},vw.prototype.setManifestType=function(){},vw.prototype.parseMedia=function(e){var t="",n="",i=null,r=null;for(r=(e=d(r=ct(e).split(/\r?\n\s*\r?\n/))).next();!r.done;r=e.next()){var a=r.value;r=a,(a=Tw.exec(a))&&(i=a[1],r=a[2]),"V4 Styles"==i||"V4+ Styles"==i?(t=r,t=n?t+"\n"+r:r):"Events"==i&&(n=n?n+"\n"+r:r)}for(i=[],r=null,e=(t=d(t.split(/\r?\n/))).next();!e.done;e=t.next())if(e=e.value,!/^\s*;/.test(e)&&(a=Lw.exec(e)))if(e=a[1].trim(),a=a[2].trim(),"Format"==e)r=a.split(Sw);else if("Style"==e){e=a.split(Sw),a={};for(var s=0;s<r.length&&s<e.length;s++)a[r[s]]=e[s];i.push(a)}for(r=[],t=null,a=(n=d(n.split(/\r?\n/))).next(),e={};!a.done;e={lh:void 0},a=n.next())if(a=a.value,!/^\s*;/.test(a)&&(s=Lw.exec(a)))if(a=s[1].trim(),s=s[2].trim(),"Format"==a)t=s.split(Sw);else if("Dialogue"==a){s=s.split(Sw),a={};for(var o=0;o<t.length&&o<s.length;o++)a[t[o]]=s[o];s=new un(o=bw(a.Start),bw(a.End),s.slice(t.length-1).join(",").replace(/\\N/g,"\n").replace(/\{[^}]+\}/g,"")),e.lh=a.Style,(e=i.find(function(e){return function(t){return t.Name==e.lh}}(e)))&&Mw(s,e),r.push(s)}return r},U("shaka.text.SsaTextParser",vw),vw.prototype.parseMedia=vw.prototype.parseMedia,vw.prototype.setManifestType=vw.prototype.setManifestType,vw.prototype.setSequenceMode=vw.prototype.setSequenceMode,vw.prototype.parseInit=vw.prototype.parseInit;var Tw=/^\s*\[([^\]]+)\]\r?\n([\s\S]*)/,Lw=/^\s*([^:]+):\s*(.*)/,Sw=/\s*,\s*/,kw=/^(\d+:)?(\d{1,2}):(\d{1,2}(?:[.]\d{1,3})?)?$/;function Dw(e,t){var n=1&e[t+1]?7:9;return t+n<=e.length&&0<(e=((3&e[t+3])<<11|e[t+4]<<3|(224&e[t+5])>>>5)-n)?{Sd:n,ea:e}:null}function xw(e,t){var n=[96e3,88200,64e3,48e3,44100,32e3,24e3,22050,16e3,12e3,11025,8e3,7350],i=(60&e[t+2])>>>2;if(i>n.length-1)return null;var r=1+((192&e[t+2])>>>6),a=(1&e[t+2])<<2;return a|=(192&e[t+3])>>>6,{sampleRate:n[i],channelCount:a,codec:"mp4a.40."+r}}function Aw(e,t){if(t+1<e.length&&255===e[t]&&240==(246&e[t+1])){var n=1&e[t+1]?7:9;if(t+n>=e.length)return!1;var i=(3&e[t+3])<<11|e[t+4]<<3|(224&e[t+5])>>>5;return!(i<=n)&&((t+=i)===e.length||t+1<e.length&&255===e[t]&&240==(246&e[t+1]))}return!1}function Yw(e){this.i=e,this.h=0,this.g=new Map}function Ew(e,t){if(t+8>e.length||11!==e[t]||119!==e[t+1])return null;var n=e[t+4]>>6;if(3<=n)return null;var i=63&e[t+4],r=2*[64,69,96,64,70,96,80,87,120,80,88,120,96,104,144,96,105,144,112,121,168,112,122,168,128,139,192,128,140,192,160,174,240,160,175,240,192,208,288,192,209,288,224,243,336,224,244,336,256,278,384,256,279,384,320,348,480,320,349,480,384,417,576,384,418,576,448,487,672,448,488,672,512,557,768,512,558,768,640,696,960,640,697,960,768,835,1152,768,836,1152,896,975,1344,896,976,1344,1024,1114,1536,1024,1115,1536,1152,1253,1728,1152,1254,1728,1280,1393,1920,1280,1394,1920][3*i+n];if(t+r>e.length)return null;var a=e[t+6]>>5,s=0;2===a?s+=2:(1&a&&1!==a&&(s+=2),4&a&&(s+=2)),s=(e[t+6]<<8|e[t+7])>>12-s&1;var o=7&e[t+5];return e=new Uint8Array([n<<6|e[t+5]>>3<<1|o>>2,(3&o)<<6|a<<3|s<<2|i>>4,i<<4&224]),{sampleRate:[48e3,44100,32e3][n],channelCount:[2,1,2,3,3,4,4,5][a]+s,qa:e,ea:r}}function Iw(e,t){if(11===e[t]&&119===e[t+1]){var n,i,r=0,a=5;for(t+=a;0<a;){i=e[t];var s=Math.min(a,8),o=8-s;n=(i&(n=4278190080>>>24+o<<o))>>o,r=r?r<<s|n:n,t+=1,a-=s}if(16>r)return!0}return!1}function Pw(e){this.i=e,this.h=0,this.g=new Map}function Cw(e,t){if(t+8>e.length||2935!=(e[t]<<8|e[t+1]))return null;var n=new Ws(e.subarray(t+2));Vs(n,2),Vs(n,3);var i=Gs(n,11)+1<<1,r=Gs(n,2);if(3==r){r=[24e3,22060,16e3][r=Gs(n,2)];var a=3}else r=[48e3,44100,32e3][r],a=Gs(n,2);var s=Gs(n,3),o=Gs(n,1);return n=Gs(n,5),t+i>e.byteLength?null:(e=Math.floor(i*r/(16*[1,2,3,6][a])),e=new Uint8Array([(8160&e)>>5,(31&e)<<3,r<<6|n<<1,s<<1|o,0]),{sampleRate:r,channelCount:[2,1,2,3,3,4,4,5][s]+o,qa:e,ea:i})}function jw(e){this.i=e,this.h=0,this.g=new Map}function Ow(e){for(var t=!1,n=[],i=e.find((function(e){return 7==e.type})),r=!1,a=(e=d(e)).next();!a.done;a=e.next()){var s=!1;switch((a=a.value).type){case 1:s=r=!0;var o=a.data;i&&4<o.length&&(2===(o=eo(new Ws(o)))||4===o||7===o||9===o)&&(t=!0);break;case 5:t=s=r=!0;break;case 6:case 7:case 8:case 12:s=!0;break;case 9:r=s=!0;break;default:s=!1}r&&s&&(s=a.fullData.byteLength,(o=new Uint8Array(4))[0]=s>>24&255,o[1]=s>>16&255,o[2]=s>>8&255,o[3]=255&s,n.push(o),n.push(a.fullData))}return n.length?{data:ci.apply(ai,l(n)),nd:t}:null}Ui["text/x-ssa"]=function(){return new vw},(i=Yw.prototype).destroy=function(){this.g.clear()},i.isSupported=function(e){return"audio/aac"==e.toLowerCase().split(";")[0]&&ne(this.convertCodecs("audio",e))},i.convertCodecs=function(e,t){return"audio/aac"==t.toLowerCase().split(";")[0]?'audio/mp4; codecs="'+(Ei(t)||"mp4a.40.2")+'"':t},i.getOriginalMimeType=function(){return this.i},i.transmux=function(e,t,n,i){for(var r=pe(e),a=Cs(r),s=a.length;s<r.length&&!Aw(r,s);s++);if(e=1e3*n.endTime,(a=Ps(a)).length&&n&&(a=a.find((function(e){return"com.apple.streaming.transportStreamTimestamp"===e.description})))&&(e=a.data),!(a=xw(r,s)))return Promise.reject(new Ye(2,3,3018,n?n.N()[0]:null));t.audioSamplingRate=a.sampleRate,t.channelsCount=a.channelCount;for(var o=[];s<r.length;){var u=Dw(r,s);if(!u)return Promise.reject(new Ye(2,3,3018,n?n.N()[0]:null));var d=u.Sd+u.ea;s+d<=r.length&&o.push({data:r.subarray(s+u.Sd,s+d),size:u.ea,duration:1024,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),s+=d}return r=a.sampleRate,e=Math.floor(e*r/1e3),i=new Zg([i={id:t.id,type:"audio",codecs:a.codec,encrypted:t.encrypted&&0<t.drmInfos.length,timescale:r,duration:i,fb:[],qa:new Uint8Array([]),za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.h,baseMediaDecodeTime:e,ab:o},stream:t}]),n=t.id+"_"+n.i,this.g.has(n)?t=this.g.get(n):(t=ey(i),this.g.set(n,t)),n=ay(i),this.h++,t=ci(t,n),Promise.resolve(t)},U("shaka.transmuxer.AacTransmuxer",Yw),Yw.prototype.transmux=Yw.prototype.transmux,Yw.prototype.getOriginalMimeType=Yw.prototype.getOriginalMimeType,Yw.prototype.convertCodecs=Yw.prototype.convertCodecs,Yw.prototype.isSupported=Yw.prototype.isSupported,Yw.prototype.destroy=Yw.prototype.destroy,jn("audio/aac",(function(){return new Yw("audio/aac")}),Nn),(i=Pw.prototype).destroy=function(){this.g.clear()},i.isSupported=function(e){return"audio/ac3"==e.toLowerCase().split(";")[0]&&ne(this.convertCodecs("audio",e))},i.convertCodecs=function(e,t){return"audio/ac3"==t.toLowerCase().split(";")[0]?'audio/mp4; codecs="ac-3"':t},i.getOriginalMimeType=function(){return this.i},i.transmux=function(e,t,n,i){for(var r=Cs(e=pe(e)),a=r.length;a<e.length&&!Iw(e,a);a++);var s=1e3*n.endTime;(r=Ps(r)).length&&n&&(r=r.find((function(e){return"com.apple.streaming.transportStreamTimestamp"===e.description})))&&(s=r.data),r=0;for(var o=new Uint8Array([]),u=[];a<e.length;){var d=Ew(e,a);if(!d)return Promise.reject(new Ye(2,3,3018,n?n.N()[0]:null));t.audioSamplingRate=d.sampleRate,t.channelsCount=d.channelCount,r=d.sampleRate,o=d.qa,u.push({data:e.subarray(a,a+d.ea),size:d.ea,duration:1536,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),a+=d.ea}return e=Math.floor(s*r/1e3),i=new Zg([i={id:t.id,type:"audio",codecs:"ac-3",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:r,duration:i,fb:[],qa:o,za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.h,baseMediaDecodeTime:e,ab:u},stream:t}]),n=t.id+"_"+n.i,this.g.has(n)?t=this.g.get(n):(t=ey(i),this.g.set(n,t)),n=ay(i),this.h++,t=ci(t,n),Promise.resolve(t)},U("shaka.transmuxer.Ac3Transmuxer",Pw),Pw.prototype.transmux=Pw.prototype.transmux,Pw.prototype.getOriginalMimeType=Pw.prototype.getOriginalMimeType,Pw.prototype.convertCodecs=Pw.prototype.convertCodecs,Pw.prototype.isSupported=Pw.prototype.isSupported,Pw.prototype.destroy=Pw.prototype.destroy,jn("audio/ac3",(function(){return new Pw("audio/ac3")}),Nn),(i=jw.prototype).destroy=function(){this.g.clear()},i.isSupported=function(e){return"audio/ec3"==e.toLowerCase().split(";")[0]&&ne(this.convertCodecs("audio",e))},i.convertCodecs=function(e,t){return"audio/ec3"==t.toLowerCase().split(";")[0]?'audio/mp4; codecs="ec-3"':t},i.getOriginalMimeType=function(){return this.i},i.transmux=function(e,t,n,i){for(var r=Cs(e=pe(e)),a=r.length;a<e.length&&2935!=(e[a]<<8|e[a+1]);a++);var s=1e3*n.endTime;(r=Ps(r)).length&&n&&(r=r.find((function(e){return"com.apple.streaming.transportStreamTimestamp"===e.description})))&&(s=r.data),r=0;for(var o=new Uint8Array([]),u=[];a<e.length;){var d=Cw(e,a);if(!d)return Promise.reject(new Ye(2,3,3018,n?n.N()[0]:null));t.audioSamplingRate=d.sampleRate,t.channelsCount=d.channelCount,r=d.sampleRate,o=d.qa,u.push({data:e.subarray(a,a+d.ea),size:d.ea,duration:1536,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),a+=d.ea}return e=Math.floor(s*r/1e3),i=new Zg([i={id:t.id,type:"audio",codecs:"ec-3",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:r,duration:i,fb:[],qa:o,za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.h,baseMediaDecodeTime:e,ab:u},stream:t}]),n=t.id+"_"+n.i,this.g.has(n)?t=this.g.get(n):(t=ey(i),this.g.set(n,t)),n=ay(i),this.h++,t=ci(t,n),Promise.resolve(t)},U("shaka.transmuxer.Ec3Transmuxer",jw),jw.prototype.transmux=jw.prototype.transmux,jw.prototype.getOriginalMimeType=jw.prototype.getOriginalMimeType,jw.prototype.convertCodecs=jw.prototype.convertCodecs,jw.prototype.isSupported=jw.prototype.isSupported,jw.prototype.destroy=jw.prototype.destroy,jn("audio/ec3",(function(){return new jw("audio/ec3")}),Nn);var Rw=[100,110,122,244,44,83,86,118,128,138,139,134];function Nw(e,t){var n=e[t+1]>>3&3,i=e[t+1]>>1&3,r=e[t+2]>>4&15,a=e[t+2]>>2&3;if(1!==n&&0!==r&&15!==r&&3!==a){var s=e[t+3]>>6;r=1e3*Fw[14*(3===n?3-i:3===i?3:4)+r-1],a=Bw[3*(3===n?0:2===n?1:2)+a],n=Ww[n][i];var o=zw[i],u=Math.floor(n*r/a+(e[t+2]>>1&1))*o,d=(navigator.userAgent||"").match(/Chrome\/(\d+)/i);return(d=d?parseInt(d[1],10):0)&&87>=d&&2===i&&224e3<=r&&0===s&&(e[t+3]|=128),{sampleRate:a,channelCount:3===s?1:2,ea:u,Ti:8*n*o}}return null}function Hw(e,t){return!(255!==e[t]||224&~e[t+1]||!(6&e[t+1]))}function Uw(e,t){if(t+1<e.length&&Hw(e,t)){var n=Nw(e,t),i=4;return n&&n.ea&&(i=n.ea),(t+=i)===e.length||t+1<e.length&&Hw(e,t)}return!1}var Fw=[32,64,96,128,160,192,224,256,288,320,352,384,416,448,32,48,56,64,80,96,112,128,160,192,224,256,320,384,32,40,48,56,64,80,96,112,128,160,192,224,256,320,32,48,56,64,80,96,112,128,144,160,176,192,224,256,8,16,24,32,40,48,56,64,80,96,112,128,144,160],Bw=[44100,48e3,32e3,22050,24e3,16e3,11025,12e3,8e3],Ww=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],zw=[0,1,1,4];function Vw(e){this.i=e,this.h=0,this.g=new Map}function Gw(e){this.h=e,this.g=null}function qw(e){this.h=e,(this.g=Ap.get("ISOBoxer")())&&function(e){function t(){this._procFullBox(),1&this.flags&&(this._procField("AlgorithmID","uint",24),this._procField("IV_size","uint",8),this._procFieldArray("KID",16,"uint",8)),this._procField("sample_count","uint",32),this._procEntries("entry",this.sample_count,(function(e){this._procEntryField(e,"InitializationVector","data",8),2&this.flags&&(this._procEntryField(e,"NumberOfEntries","uint",16),this._procSubEntries(e,"clearAndCryptedData",e.NumberOfEntries,(function(e){this._procEntryField(e,"BytesOfClearData","uint",16),this._procEntryField(e,"BytesOfEncryptedData","uint",32)})))}))}e.g.addBoxProcessor("saio",(function(){this._procFullBox(),1&this.flags&&(this._procField("aux_info_type","uint",32),this._procField("aux_info_type_parameter","uint",32)),this._procField("entry_count","uint",32),this._procFieldArray("offset",this.entry_count,"uint",1===this.version?64:32)})),e.g.addBoxProcessor("saiz",(function(){this._procFullBox(),1&this.flags&&(this._procField("aux_info_type","uint",32),this._procField("aux_info_type_parameter","uint",32)),this._procField("default_sample_info_size","uint",8),this._procField("sample_count","uint",32),0===this.default_sample_info_size&&this._procFieldArray("sample_info_size",this.sample_count,"uint",8)})),e.g.addBoxProcessor("senc",t),e.g.addBoxProcessor("uuid",(function(){for(var e=!0,n=0;16>n;n++)this.usertype[n]!==Kw[n]&&(e=!1);e&&(this._parsing&&(this.type="sepiff"),t.call(this))}))}(this)}function $w(e,t){for(var n=8,i=0;i<e.boxes.length&&e.boxes[i].type!==t;i++)n+=e.boxes[i].size;return n}(i=Vw.prototype).destroy=function(){this.g.clear()},i.isSupported=function(e){return"audio/mpeg"==e.toLowerCase().split(";")[0]&&ne(this.convertCodecs("audio",e))},i.convertCodecs=function(e,t){return"audio/mpeg"==t.toLowerCase().split(";")[0]?'audio/mp4; codecs="mp3"':t},i.getOriginalMimeType=function(){return this.i},i.transmux=function(e,t,n,i){for(var r=pe(e),a=Cs(r).length;a<r.length&&!Uw(r,a);a++);var s;for(e=[];a<r.length;){var o=Nw(r,a);if(!o)return Promise.reject(new Ye(2,3,3018,n?n.N()[0]:null));s||(s=o),a+o.ea<=r.length&&e.push({data:r.subarray(a,a+o.ea),size:o.ea,duration:1152,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),a+=o.ea}return s?(r=9e4*s.Ti/s.sampleRate*this.h,i=new Zg([i={id:t.id,type:"audio",codecs:"mp3",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:s.sampleRate,duration:i,fb:[],qa:new Uint8Array([]),za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.h,baseMediaDecodeTime:r,ab:e},stream:t}]),n=t.id+"_"+n.i,this.g.has(n)?t=this.g.get(n):(t=ey(i),this.g.set(n,t)),n=ay(i),this.h++,t=ci(t,n),Promise.resolve(t)):Promise.reject(new Ye(2,3,3018,n?n.N()[0]:null))},U("shaka.transmuxer.Mp3Transmuxer",Vw),Vw.prototype.transmux=Vw.prototype.transmux,Vw.prototype.getOriginalMimeType=Vw.prototype.getOriginalMimeType,Vw.prototype.convertCodecs=Vw.prototype.convertCodecs,Vw.prototype.isSupported=Vw.prototype.isSupported,Vw.prototype.destroy=Vw.prototype.destroy,jn("audio/mpeg",(function(){return new Vw("audio/mpeg")}),Nn),(i=Gw.prototype).destroy=function(){},i.isSupported=function(e){if("video/mp2t"!=e.toLowerCase().split(";")[0])return!1;var t=Ei(e).split(","),n=gi("audio",t);return t=gi("video",t),!(!n||t||"mp3"!=xi(n))&&ne(this.convertCodecs("audio",e))},i.convertCodecs=function(e,t){return"video/mp2t"==t.toLowerCase().split(";")[0]?"audio/mpeg":t},i.getOriginalMimeType=function(){return this.h},i.transmux=function(e,t,n,i,r){if(this.g?this.g.clearData():this.g=new to,e=pe(e),"mp3"!=(e=this.g.parse(e)).fd().audio||"audio"!=r)return Promise.reject(new Ye(2,3,3018,n?n.N()[0]:null));for(n=new Uint8Array([]),r=d(e.Wb()),e=r.next();!e.done;e=r.next())if(e=e.value.data)for(t=0;t<e.length;)(i=Nw(e,t))?(t+i.ea<=e.length&&(n=ci(n,e.subarray(t,t+i.ea))),t+=i.ea):t++;return Promise.resolve(n)},U("shaka.transmuxer.MpegTsTransmuxer",Gw),Gw.prototype.transmux=Gw.prototype.transmux,Gw.prototype.getOriginalMimeType=Gw.prototype.getOriginalMimeType,Gw.prototype.convertCodecs=Gw.prototype.convertCodecs,Gw.prototype.isSupported=Gw.prototype.isSupported,Gw.prototype.destroy=Gw.prototype.destroy,jn("video/mp2t",(function(){return new Gw("video/mp2t")}),Hn),(i=qw.prototype).destroy=function(){},i.isSupported=function(e,t){var n=e.startsWith("mss/");return!(!this.g||!n)&&(t?ne(this.convertCodecs(t,e)):(t=this.convertCodecs("audio",e),e=this.convertCodecs("video",e),ne(t)||ne(e)))},i.convertCodecs=function(e,t){return t.replace("mss/","")},i.getOriginalMimeType=function(){return this.h},i.transmux=function(e,t,n){if(!n)return Promise.resolve(pe(e));if(!t.mssPrivateData)return Promise.reject(new Ye(2,3,3020,n?n.N()[0]:null));try{var i,r=this.g.parseBuffer(e),a=r.fetch("tfhd");a.track_ID=t.id+1;var s=r.fetch("tfdt"),o=r.fetch("traf");null===s&&((s=this.g.createFullBox("tfdt",o,a)).version=1,s.flags=0,s.baseMediaDecodeTime=Math.floor(n.startTime*t.mssPrivateData.timescale));var u=r.fetch("trun"),d=r.fetch("tfxd");d&&d._parent.boxes.splice(d._parent.boxes.indexOf(d),1);var l=r.fetch("tfrf");l&&l._parent.boxes.splice(l._parent.boxes.indexOf(l),1);var c=r.fetch("sepiff");if(null!==c){c.type="senc",c.usertype=void 0;var h=r.fetch("saio");if(null===h){(h=this.g.createFullBox("saio",o)).version=0,h.flags=0,h.entry_count=1,h.offset=[0];var m=this.g.createFullBox("saiz",o);if(m.version=0,m.flags=0,m.sample_count=c.sample_count,m.default_sample_info_size=0,m.sample_info_size=[],2&c.flags)for(i=0;i<c.sample_count;i+=1)m.sample_info_size[i]=10+6*c.entry[i].NumberOfEntries;else m.default_sample_info_size=8}}a.flags&=16777214,a.flags|=131072,u.flags|=1;var f=r.fetch("moof");u.data_offset=f.getLength()+8;var p=r.fetch("saio");null!==p&&(p.offset[0]=$w(f,"traf")+$w(o,"senc")+16);var g=pe(r.write());return Promise.resolve(g)}catch(e){return e instanceof Ye?Promise.reject(e):Promise.reject(new Ye(2,3,3022,n?n.N()[0]:null))}},U("shaka.transmuxer.MssTransmuxer",qw),qw.prototype.transmux=qw.prototype.transmux,qw.prototype.getOriginalMimeType=qw.prototype.getOriginalMimeType,qw.prototype.convertCodecs=qw.prototype.convertCodecs,qw.prototype.isSupported=qw.prototype.isSupported,qw.prototype.destroy=qw.prototype.destroy;var Kw=new Uint8Array([162,57,79,82,90,155,79,20,162,68,108,66,124,100,141,244]);function Jw(e){this.l=e,this.g=0,this.i=new Map,this.h=this.j=null}jn("mss/audio/mp4",(function(){return new qw("mss/audio/mp4")}),Nn),jn("mss/video/mp4",(function(){return new qw("mss/video/mp4")}),Nn),(i=Jw.prototype).destroy=function(){this.i.clear(),this.h&&this.h.destroy()},i.isSupported=function(e,t){if("video/mp2t"!=e.toLowerCase().split(";")[0])return!1;var n=e;t&&(n=this.convertCodecs(t,e));var i=Ei(n).split(",");return n=gi("audio",i),i=gi("video",i),!(n&&(n=xi(n),!Zw.includes(n))||i&&(n=xi(i),!eb.includes(n)))&&(t?ne(this.convertCodecs(t,e)):(t=this.convertCodecs("audio",e),e=this.convertCodecs("video",e),ne(t)||ne(e)))},i.convertCodecs=function(e,t){return"video/mp2t"==t.toLowerCase().split(";")[0]?(t=Ei(t).replace("mp4a.40.34","mp3").split(",").map((function(e){return dr(e,"audio/mp4")})).map(lr).join(","),"audio"==e?'audio/mp4; codecs="'+t+'"':'video/mp4; codecs="'+t+'"'):t},i.getOriginalMimeType=function(){return this.l},i.transmux=function(e,t,n,i,r){var a=pe(e);if("audio"==r&&!ao(a)){for(var s=Cs(a),o=s.length;o<a.length;o++)if(Uw(a,o))return Promise.reject(new Ye(2,3,3018,n?n.N()[0]:null));for(o=s.length;o<a.length;o++)if(Aw(a,o))return this.h||(this.h=new Yw("audio/aac")),this.h.transmux(e,t,n,i,r);return Promise.reject(new Ye(2,3,3018,n?n.N()[0]:null))}this.j?this.j.clearData():this.j=new to;var u=this.j.parse(a),c=[],h=u.fd();try{var m=null;if("video"==r){switch(h.video){case"avc":var f=[],p=null,g=[],y=u.sc();if(!y.length)throw new Ye(2,3,3023,n?n.N()[0]:null);for(var _=0;_<y.length;_++){var v=y[_],M=v.nalus;g.push.apply(g,l(M));var w,b=Ow(M);if(b)null==p&&(p=v.dts),w=_+1<y.length?(y[_+1].dts||0)-(v.dts||0):1<y.length?(v.dts||0)-(y[_-1].dts||0):9e4*(n.endTime-n.startTime),f.push({data:b.data,size:b.data.byteLength,duration:w,hb:Math.round((v.pts||0)-(v.dts||0)),flags:{kb:0,$a:0,Za:0,Xa:0,Ya:b.nd?2:1,lb:b.nd?0:1}})}var T=function(e){if(!e.length)return null;var t=e.find((function(e){return 7==e.type}));if(e=e.find((function(e){return 8==e.type})),!t||!e)return null;var n=new Ws(t.data),i=Qs(n);if(Qs(n),Qs(n),$s(n),Rw.includes(i)&&(3===(i=Ks(n))&&Vs(n,1),$s(n),$s(n),Vs(n,1),Xs(n))){i=3!==i?8:12;for(var r=0;r<i;r++)Xs(n)&&Zs(n,6>r?16:64)}if($s(n),0===(i=Ks(n)))Ks(n);else if(1===i)for(Vs(n,1),$s(n),$s(n),i=Ks(n),r=0;r<i;r++)$s(n);$s(n),Vs(n,1);var a=Ks(n),s=Ks(n),o=Gs(n,1);0===o&&Vs(n,1),Vs(n,1);var u=0,d=0,c=0,h=0;if(Xs(n)&&(u=Ks(n),d=Ks(n),c=Ks(n),h=Ks(n)),r=i=1,Xs(n)&&Xs(n)){var m=Qs(n);0<m&&16>=m?(i=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2][m-1],r=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1][m-1]):255===m&&(i=Gs(n,16),r=Gs(n,16))}return n=(2-o)*(s+1)*16-2*c-2*h,a=16*(a+1)-2*u-2*d,u=[],t=t.fullData,u.push(t.byteLength>>>8&255),u.push(255&t.byteLength),u=u.concat.apply(u,l(t)),t=[],e=e.fullData,t.push(e.byteLength>>>8&255),t.push(255&e.byteLength),t=t.concat.apply(t,l(e)),{height:n,width:a,za:e=new Uint8Array([1,u[3],u[4],u[5],255,225].concat(u,[1],t)),Da:i,Fa:r}}(g);if(!T||null==p)throw new Ye(2,3,3018,n?n.N()[0]:null);t.height=T.height,t.width=T.width,m={id:t.id,type:"video",codecs:"avc1",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:9e4,duration:i,fb:[],qa:new Uint8Array([]),za:T.za,Da:T.Da,Fa:T.Fa,data:{wb:this.g,baseMediaDecodeTime:p,ab:f},stream:t};break;case"hvc":var L=[],S=null,k=[],D=u.sc();if(!D.length)throw new Ye(2,3,3023,n?n.N()[0]:null);for(var x=0;x<D.length;x++){var A=D[x],Y=A.nalus;k.push.apply(k,l(Y));for(var E=!1,I=[],P=!1,C=d(Y),j=C.next();!j.done;j=C.next()){var O=j.value;switch(O.type){case 1:case 0:var R=P=!0;break;case 19:case 20:case 21:E=R=P=!0;break;case 32:case 33:case 34:case 39:case 40:R=!0;break;case 35:P=R=!0;break;default:R=!1}if(P&&R){var N=O.fullData.byteLength,H=new Uint8Array(4);H[0]=N>>24&255,H[1]=N>>16&255,H[2]=N>>8&255,H[3]=255&N,I.push(H),I.push(O.fullData)}}var U,F=I.length?{data:ci.apply(ai,l(I)),nd:E}:null;if(F)null==S&&null!=A.dts&&(S=A.dts),U=x+1<D.length?(D[x+1].dts||0)-(A.dts||0):1<D.length?(A.dts||0)-(D[x-1].dts||0):9e4*(n.endTime-n.startTime),L.push({data:F.data,size:F.data.byteLength,duration:U,hb:Math.round((A.pts||0)-(A.dts||0)),flags:{kb:0,$a:0,Za:0,Xa:0,Ya:F.nd?2:1,lb:F.nd?0:1}})}var B=function(e){if(!e.length)return null;var t=e.find((function(e){return 32==e.type})),n=e.find((function(e){return 33==e.type})),i=e.find((function(e){return 34==e.type}));if(!t||!n||!i)return null;var r=function(e){var t=new Ws(e,!0);return Qs(t),Qs(t),Gs(t,4),Gs(t,2),Gs(t,6),{Cf:(e=Gs(t,3))+1,Zf:t=Xs(t)}}(t.fullData);e=function(e){Qs(e=new Ws(e,!0)),Qs(e);var t=0,n=0,i=0,r=0;Gs(e,4);var a=Gs(e,3);Xs(e);for(var s=Gs(e,2),o=Gs(e,1),u=Gs(e,5),d=Qs(e),l=Qs(e),c=Qs(e),h=Qs(e),m=Qs(e),f=Qs(e),p=Qs(e),g=Qs(e),y=Qs(e),_=Qs(e),v=Qs(e),M=[],w=[],b=0;b<a;b++)M.push(Xs(e)),w.push(Xs(e));if(0<a)for(b=a;8>b;b++)Gs(e,2);for(b=0;b<a;b++)M[b]&&Gs(e,88),w[b]&&Qs(e);Ks(e),3==(M=Ks(e))&&Gs(e,1),w=Ks(e),b=Ks(e),Xs(e)&&(t+=Ks(e),n+=Ks(e),i+=Ks(e),r+=Ks(e));var T=Ks(e),L=Ks(e),S=Ks(e);if(Xs(e))for(var k=0;k<=a;k++)Ks(e),Ks(e),Ks(e);else Ks(e),Ks(e),Ks(e);if(Ks(e),Ks(e),Ks(e),Ks(e),Ks(e),Ks(e),Xs(e)&&Xs(e))for(k=0;4>k;k++)for(var D=0;D<(3===k?2:6);D++)if(Xs(e)){var x=Math.min(64,1<<4+(k<<1));1<k&&Js(e);for(var A=0;A<x;A++)Js(e)}else Ks(e);for(Xs(e),Xs(e),Xs(e)&&(Qs(e),Ks(e),Ks(e),Xs(e)),k=Ks(e),x=D=0;x<k;x++)if(A=!1,0!==x&&(A=Xs(e)),A){x===k&&Ks(e),Xs(e),Ks(e);for(var Y=A=0;Y<=D;Y++){var E=Xs(e),I=!1;E||(I=Xs(e)),(E||I)&&A++}D=A}else{for(D=(Y=Ks(e))+(A=Ks(e)),E=0;E<Y;E++)Ks(e),Xs(e);for(Y=0;Y<A;Y++)Ks(e),Xs(e)}if(Xs(e))for(k=Ks(e),D=0;D<k;D++){for(x=0;x<S+4;x++)Gs(e,1);Gs(e,1)}if(k=S=1,D=0,Xs(e),Xs(e),Xs(e)){if(Xs(e)&&(A=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2],Y=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1],0<(x=Qs(e))&&16>=x?(S=A[x-1],k=Y[x-1]):255===x&&(S=Gs(e,16),k=Gs(e,16))),Xs(e)&&Xs(e),Xs(e)&&(Gs(e,3),Xs(e),Xs(e)&&(Qs(e),Qs(e),Qs(e))),Xs(e)&&(Ks(e),Ks(e)),Xs(e),Xs(e),Xs(e),(x=Xs(e))&&(Ks(e),Ks(e),Ks(e),Ks(e)),Xs(e)&&(Gs(e,32),Gs(e,32),Xs(e)&&Ks(e),Xs(e)))for(Y=!1,x=Xs(e),A=Xs(e),(x||A)&&((Y=Xs(e))&&(Qs(e),Gs(e,5),Xs(e),Gs(e,5)),Gs(e,4),Gs(e,4),Y&&Gs(e,4),Gs(e,5),Gs(e,5),Gs(e,5)),E=0;E<=a;E++){var P=!0;I=1,Xs(e)||(P=Xs(e));var C=!1;if(P?Ks(e):C=Xs(e),C||(I=Ks(e)+1),x){for(P=0;P<I;P++)Ks(e),Ks(e),Y&&(Ks(e),Ks(e));Xs(e)}if(A){for(P=0;P<I;P++)Ks(e),Ks(e),Y&&(Ks(e),Ks(e));Xs(e)}}Xs(e)&&(Xs(e),Xs(e),Xs(e),D=Ks(e),Ks(e),Ks(e),Ks(e),Ks(e))}return{af:v,gf:s,hf:o,ff:u,bf:d,cf:l,df:c,ef:h,Ve:m,We:f,Xe:p,Ye:g,Ze:y,$e:_,$d:D,Oe:0,Me:M,Le:T,Ke:L,width:w-(t+n)*(1===M||2===M?2:1),height:b-(i+r)*(1===M?2:1),Vi:S,Ui:k}}(n.fullData);var a=function(e){var t=new Ws(e,!0);Qs(t),Qs(t),Ks(t),Ks(t),Xs(t),Xs(t),Gs(t,3),Xs(t),Xs(t),Ks(t),Ks(t),Js(t),Xs(t),Xs(t),Xs(t)&&Ks(t),Js(t),Js(t),Xs(t),Xs(t),Xs(t),Xs(t),e=Xs(t);var n=1;return(t=Xs(t))&&e?n=0:t?n=3:e&&(n=2),{Ff:n}}(i.fullData);return t=function(e,t,n,i){var r=new Uint8Array(23+(5+e.byteLength)+(5+t.byteLength)+(5+n.byteLength));return r[0]=1,r[1]=(3&i.gf)<<6|(i.hf?1:0)<<5|31&i.ff,r[2]=i.bf,r[3]=i.cf,r[4]=i.df,r[5]=i.ef,r[6]=i.Ve,r[7]=i.We,r[8]=i.Xe,r[9]=i.Ye,r[10]=i.Ze,r[11]=i.$e,r[12]=i.af,r[13]=240|(3840&i.$d)>>8,r[14]=255&i.$d,r[15]=252|3&i.Ff,r[16]=252|3&i.Me,r[17]=248|7&i.Le,r[18]=248|7&i.Ke,r[19]=0,r[20]=0,r[21]=(3&i.Oe)<<6|(7&i.Cf)<<3|(i.Zf?1:0)<<2|3,r[22]=3,r[23]=160,r[24]=0,r[25]=1,r[26]=(65280&e.byteLength)>>8,r[27]=255&e.byteLength,r.set(e,28),r[23+(5+e.byteLength)]=161,r[e.byteLength+29]=0,r[e.byteLength+30]=1,r[e.byteLength+31]=(65280&t.byteLength)>>8,r[e.byteLength+32]=255&t.byteLength,r.set(t,e.byteLength+33),r[23+(e.byteLength+10+t.byteLength)]=162,r[e.byteLength+10+t.byteLength+24]=0,r[e.byteLength+10+t.byteLength+25]=1,r[e.byteLength+10+t.byteLength+26]=(65280&n.byteLength)>>8,r[e.byteLength+10+t.byteLength+27]=255&n.byteLength,r.set(n,e.byteLength+10+t.byteLength+28),r}(t.fullData,n.fullData,i.fullData,{Cf:r.Cf,Zf:r.Zf,gf:e.gf,hf:e.hf,af:e.af,ff:e.ff,bf:e.bf,cf:e.cf,df:e.df,ef:e.ef,Ve:e.Ve,We:e.We,Xe:e.Xe,Ye:e.Ye,Ze:e.Ze,$e:e.$e,Oe:e.Oe,$d:e.$d,Me:e.Me,Le:e.Le,Ke:e.Ke,Ff:a.Ff}),{height:e.height,width:e.width,za:t,Da:e.Vi,Fa:e.Ui}}(k);if(!B||null==S)throw new Ye(2,3,3018,n?n.N()[0]:null);t.height=B.height,t.width=B.width,m={id:t.id,type:"video",codecs:"hvc1",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:9e4,duration:i,fb:[],qa:new Uint8Array([]),za:B.za,Da:B.Da,Fa:B.Fa,data:{wb:this.g,baseMediaDecodeTime:S,ab:L},stream:t}}m&&(c.push(m),m=null)}if("audio"==r){switch(h.audio){case"aac":for(var W,z=[],V=null,G=d(u.Wb()),q=G.next();!q.done;q=G.next()){var $=q.value,K=$.data;if(K){var J=0;if(!(W=xw(K,J)))throw new Ye(2,3,3018,n?n.N()[0]:null);for(t.audioSamplingRate=W.sampleRate,t.channelsCount=W.channelCount,null==V&&null!==$.pts&&(V=$.pts);J<K.length;){var X=Dw(K,J);if(X){var Q=X.Sd+X.ea;J+Q<=K.length&&z.push({data:K.subarray(J+X.Sd,J+Q),size:X.ea,duration:1024,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),J+=Q}else J++}}}if(!W||null==V){if(!u.sc().length)throw new Ye(2,3,3018,n?n.N()[0]:null);V=9e4*n.startTime;var Z=gi("audio",t.codecs.split(","));if(!Z||!t.channelsCount||!t.audioSamplingRate)throw new Ye(2,3,3018,n?n.N()[0]:null);W={sampleRate:t.audioSamplingRate,channelCount:t.channelsCount,codec:Z};var ee=function(e,t){if("mp4a.40.2"===e){if(1===t)return new Uint8Array([0,200,0,128,35,128]);if(2===t)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(3===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);if(4===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);if(5===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,56]);if(6===t)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,0,178,0,32,8,224])}else{if(1===t)return new Uint8Array([1,64,34,128,163,78,230,128,186,8,0,0,0,28,6,241,193,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(2===t||3===t)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94])}return null}(Z,t.channelsCount);if(!ee)throw new Ye(2,3,3018,n?n.N()[0]:null);for(var te=V+9e4*(n.endTime-n.startTime),ne=V;ne<te;)z.push({data:ee,size:ee.byteLength,duration:1024,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),ne+=1024/W.sampleRate*9e4}var ie=W.sampleRate,re=V/9e4*ie;m={id:t.id,type:"audio",codecs:W.codec,encrypted:t.encrypted&&0<t.drmInfos.length,timescale:ie,duration:i,fb:[],qa:new Uint8Array([]),za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.g,baseMediaDecodeTime:re,ab:z},stream:t};break;case"ac3":for(var ae=[],se=0,oe=new Uint8Array([]),ue=null,de=d(u.Wb()),le=de.next();!le.done;le=de.next()){var ce=le.value,he=ce.data;null==ue&&null!==ce.pts&&(ue=ce.pts);for(var me=0;me<he.length;){var fe=Ew(he,me);fe?(t.audioSamplingRate=fe.sampleRate,t.channelsCount=fe.channelCount,se=fe.sampleRate,oe=fe.qa,ae.push({data:he.subarray(me,me+fe.ea),size:fe.ea,duration:1536,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),me+=fe.ea):me++}}if(0==se||0==oe.byteLength||null==ue)throw new Ye(2,3,3018,n?n.N()[0]:null);var ge=ue/9e4*se;m={id:t.id,type:"audio",codecs:"ac-3",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:se,duration:i,fb:[],qa:oe,za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.g,baseMediaDecodeTime:ge,ab:ae},stream:t};break;case"ec3":for(var ye=[],_e=0,ve=new Uint8Array([]),Me=null,we=d(u.Wb()),be=we.next();!be.done;be=we.next()){var Te=be.value,Le=Te.data;null==Me&&null!==Te.pts&&(Me=Te.pts);for(var Se=0;Se<Le.length;){var ke=Cw(Le,Se);ke?(t.audioSamplingRate=ke.sampleRate,t.channelsCount=ke.channelCount,_e=ke.sampleRate,ve=ke.qa,ye.push({data:Le.subarray(Se,Se+ke.ea),size:ke.ea,duration:1536,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),Se+=ke.ea):Se++}}if(0==_e||0==ve.byteLength||null==Me)throw new Ye(2,3,3018,n?n.N()[0]:null);var De=Me/9e4*_e;m={id:t.id,type:"audio",codecs:"ec-3",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:_e,duration:i,fb:[],qa:ve,za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.g,baseMediaDecodeTime:De,ab:ye},stream:t};break;case"mp3":for(var xe,Ae=[],Ee=null,Ie=d(u.Wb()),Pe=Ie.next();!Pe.done;Pe=Ie.next()){var Ce=Pe.value,je=Ce.data;if(je){null==Ee&&null!==Ce.pts&&(Ee=Ce.pts);for(var Oe=0;Oe<je.length;){var Re=Nw(je,Oe);Re?(xe||(xe=Re),Oe+Re.ea<=je.length&&Ae.push({data:je.subarray(Oe,Oe+Re.ea),size:Re.ea,duration:1152,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),Oe+=Re.ea):Oe++}}}if(!xe||null==Ee)throw new Ye(2,3,3018,n?n.N()[0]:null);var Ne=xe.sampleRate,He=Ee/9e4*Ne;m={id:t.id,type:"audio",codecs:"mp3",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:Ne,duration:i,fb:[],qa:new Uint8Array([]),za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.g,baseMediaDecodeTime:He,ab:Ae},stream:t};break;case"opus":var Ue=[],Fe=null,Be=u.F;if(!Be)throw new Ye(2,3,3018,n?n.N()[0]:null);var We=[];switch(Be.Fh){case 1:case 2:We=[0];break;case 0:We=[255,1,1,0,1];break;case 128:We=[255,2,0,0,1];break;case 3:We=[1,2,1,0,2,1];break;case 4:We=[1,2,2,0,1,2,3];break;case 5:We=[1,3,2,0,4,1,2,3];break;case 6:We=[1,4,2,0,4,1,2,3,5];break;case 7:We=[1,4,2,0,4,1,2,3,5,6];break;case 8:We=[1,5,3,0,6,1,2,3,4,5,7];break;case 130:We=[1,1,2,0,1];break;case 131:We=[1,1,3,0,1,2];break;case 132:We=[1,1,4,0,1,2,3];break;case 133:We=[1,1,5,0,1,2,3,4];break;case 134:We=[1,1,6,0,1,2,3,4,5];break;case 135:We=[1,1,7,0,1,2,3,4,5,6];break;case 136:We=[1,1,8,0,1,2,3,4,5,6,7]}for(var ze=new Uint8Array([0,Be.channelCount,0,0,Be.sampleRate>>>24&255,Be.sampleRate>>>17&255,Be.sampleRate>>>8&255,Be.sampleRate>>>0&255,0,0].concat(l(We))),Ve=Be.sampleRate,Ge=d(u.Wb()),qe=Ge.next();!qe.done;qe=Ge.next()){var $e=qe.value,Ke=$e.data;null==Fe&&null!==$e.pts&&(Fe=$e.pts);for(var Je=0;Je<Ke.length;){for(var Xe=!!(16&Ke[Je+1]),Qe=!!(8&Ke[Je+1]),Ze=Je+2,et=0;255===Ke[Ze];)et+=255,Ze+=1;et+=Ke[Ze],Ze+=1,Ze+=Xe?2:0,Ze+=Qe?2:0;var tt=Ke.slice(Ze,Ze+et);Ue.push({data:tt,size:tt.byteLength,duration:960,hb:0,flags:{kb:0,$a:0,Za:0,Xa:0,Ya:2,lb:0}}),Je=Ze+et}}if(0==ze.byteLength||null==Fe)throw new Ye(2,3,3018,n?n.N()[0]:null);t.audioSamplingRate=Be.sampleRate,t.channelsCount=Be.channelCount;var nt=Fe/9e4*Ve;m={id:t.id,type:"audio",codecs:"opus",encrypted:t.encrypted&&0<t.drmInfos.length,timescale:Ve,duration:i,fb:[],qa:ze,za:new Uint8Array([]),Da:0,Fa:0,data:{wb:this.g,baseMediaDecodeTime:nt,ab:Ue},stream:t}}m&&(c.push(m),m=null)}}catch(e){return e&&3023==e.code?Promise.resolve(new Uint8Array([])):Promise.reject(e)}if(!c.length)return Promise.reject(new Ye(2,3,3018,n?n.N()[0]:null));var it=new Zg(c),rt=t.id+"_"+n.i;if(this.i.has(rt))var at=this.i.get(rt);else at=ey(it),this.i.set(rt,at);var st=ay(it);this.g++;var ot=ci(at,st);return Promise.resolve(ot)},U("shaka.transmuxer.TsTransmuxer",Jw),Jw.prototype.transmux=Jw.prototype.transmux,Jw.prototype.getOriginalMimeType=Jw.prototype.getOriginalMimeType,Jw.prototype.convertCodecs=Jw.prototype.convertCodecs,Jw.prototype.isSupported=Jw.prototype.isSupported,Jw.prototype.destroy=Jw.prototype.destroy;var Xw,Qw,Zw=["aac","ac-3","ec-3","mp3","opus"],eb=["avc","hevc"];function tb(){}function nb(){Xw||navigator.emeEncryptionSchemePolyfilled?console.debug("EmeEncryptionSchemePolyfill: Already installed."):navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration?(Xw=navigator.requestMediaKeySystemAccess,console.debug("EmeEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.requestMediaKeySystemAccess=ib,navigator.emeEncryptionSchemePolyfilled=!0):console.debug("EmeEncryptionSchemePolyfill: EME not found")}function ib(e,t){var n,i=this;return I((function(r){return 1==r.g?(console.assert(i==navigator,'bad "this" for requestMediaKeySystemAccess'),M(r,Xw.call(i,e,t),2)):mb(n=r.h)?(console.debug("EmeEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.requestMediaKeySystemAccess=Xw,r.return(n)):(console.debug("EmeEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support."),navigator.requestMediaKeySystemAccess=rb,r.return(rb.call(i,e,t)))}))}function rb(e,t){var n,i,r,a,s,o,u,l,c,h,m,f,p=this;return I((function(g){if(1==g.g){for(console.assert(p==navigator,'bad "this" for requestMediaKeySystemAccess'),n=hb(e),i=[],r=d(t),a=r.next();!a.done;a=r.next())s=a.value,o=ab(s.videoCapabilities,n),u=ab(s.audioCapabilities,n),s.videoCapabilities&&s.videoCapabilities.length&&!o.length||s.audioCapabilities&&s.audioCapabilities.length&&!u.length||((l=Object.assign({},s)).videoCapabilities=o,l.audioCapabilities=u,i.push(l));if(!i.length)throw(c=Error("Unsupported keySystem or supportedConfigurations.")).name="NotSupportedError",c.code=DOMException.NOT_SUPPORTED_ERR,c;return M(g,Xw.call(p,e,i),2)}return h=g.h,f=m=null,i[0]&&(i[0].videoCapabilities&&(m=i[0].videoCapabilities[0].encryptionScheme),i[0].audioCapabilities&&(f=i[0].audioCapabilities[0].encryptionScheme)),g.return(new cb(h,m,f))}))}function ab(e,t){return e?e.filter((function(e){return fb(e.encryptionScheme,t)})):e}function sb(){}function ob(){Qw||navigator.mediaCapabilitiesEncryptionSchemePolyfilled?console.debug("McEncryptionSchemePolyfill: Already installed."):navigator.mediaCapabilities?(Qw=navigator.mediaCapabilities.decodingInfo,console.debug("McEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.mediaCapabilities.decodingInfo=ub,navigator.mediaCapabilitiesEncryptionSchemePolyfilled=!0):console.debug("McEncryptionSchemePolyfill: MediaCapabilities not found")}function ub(e){var t,n,i=this;return I((function(r){switch(r.g){case 1:return console.assert(i==navigator.mediaCapabilities,'bad "this" for decodingInfo'),M(r,Qw.call(i,e),2);case 2:if(t=r.h,!e.keySystemConfiguration)return r.return(t);if((n=t.keySystemAccess)&&mb(n))return console.debug("McEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.mediaCapabilities.decodingInfo=Qw,r.return(t);if(console.debug("McEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support."),navigator.mediaCapabilities.decodingInfo=db,n){r.u(3);break}return M(r,lb(e),4);case 4:return t.keySystemAccess=r.h,r.return(t);case 3:return r.return(db.call(i,e))}}))}function db(e){var t,n,i,r,a,s,o,u=this;return I((function(d){switch(d.g){case 1:return console.assert(u==navigator.mediaCapabilities,'bad "this" for decodingInfo'),n=t=null,!e.keySystemConfiguration||(i=e.keySystemConfiguration,r=i.keySystem,n=i.audio&&i.audio.encryptionScheme,t=i.video&&i.video.encryptionScheme,a=hb(r),s={powerEfficient:!1,smooth:!1,supported:!1,keySystemAccess:null,configuration:e},fb(n,a)&&fb(t,a))?M(d,Qw.call(u,e),2):d.return(s);case 2:if((o=d.h).keySystemAccess){o.keySystemAccess=new cb(o.keySystemAccess,t,n),d.u(3);break}if(!e.keySystemConfiguration){d.u(3);break}return M(d,lb(e),5);case 5:o.keySystemAccess=d.h;case 3:return d.return(o)}}))}function lb(e){var t,n;return I((function(i){if(1==i.g){var r=e.keySystemConfiguration,a=[],s=[];return r.audio&&a.push({robustness:r.audio.robustness||"",contentType:e.audio.contentType,encryptionScheme:r.audio.encryptionScheme}),r.video&&s.push({robustness:r.video.robustness||"",contentType:e.video.contentType,encryptionScheme:r.video.encryptionScheme}),r={initDataTypes:r.initDataType?[r.initDataType]:[],distinctiveIdentifier:r.distinctiveIdentifier,persistentState:r.persistentState,sessionTypes:r.sessionTypes},a.length&&(r.audioCapabilities=a),s.length&&(r.videoCapabilities=s),t=r,M(i,navigator.requestMediaKeySystemAccess(e.keySystemConfiguration.keySystem,[t]),2)}return n=i.h,i.return(n)}))}function cb(e,t,n){this.g=e,this.i=t||null,this.h=n||null,this.keySystem=e.keySystem}function hb(e){return e.startsWith("com.widevine")||e.startsWith("com.microsoft")||e.startsWith("com.chromecast")||e.startsWith("com.adobe")||e.startsWith("org.w3")?"cenc":e.startsWith("com.apple")?"cbcs":(console.warn("EmeEncryptionSchemePolyfill: Unknown key system:",e,"Please contribute!"),null)}function mb(e){var t=(e=e.getConfiguration()).audioCapabilities&&e.audioCapabilities[0];return!(!(e=e.videoCapabilities&&e.videoCapabilities[0]||t)||void 0===e.encryptionScheme)}function fb(e,t){return!e||e==t||!("cbcs"!=e&&"cbcs-1-9"!=e||!(vb||bb||_b))}function pb(){}function gb(){nb(),ob()}jn("video/mp2t",(function(){return new Jw("video/mp2t")}),Un),U("EmeEncryptionSchemePolyfill",tb),tb.install=nb,U("McEncryptionSchemePolyfill",sb),sb.install=ob,cb.prototype.getConfiguration=function(){var e=this.g.getConfiguration();if(e.videoCapabilities)for(var t=d(e.videoCapabilities),n=t.next();!n.done;n=t.next())n.value.encryptionScheme=this.i;if(e.audioCapabilities)for(n=(t=d(e.audioCapabilities)).next();!n.done;n=t.next())n.value.encryptionScheme=this.h;return e},cb.prototype.createMediaKeys=function(){return this.g.createMediaKeys()},U("EncryptionSchemePolyfills",pb),pb.install=gb;var yb,_b=navigator.userAgent.includes("CrKey"),vb=100<=parseInt(navigator.userAgent.split("Firefox/").pop(),10),Mb=navigator.userAgent||"";if(Mb.includes("Web0S")){var wb=Mb.match(/Chrome\/(\d+)/);yb=!!wb&&79<=parseInt(wb[1],10)}else yb=!1;var bb=yb;void 0!==n&&n.exports&&(n.exports=pb)}.call(i,e,e,void 0),i.shaka)t[r]=i.shaka[r]}()}},t={};function n(i){var r=t[i];if(void 0!==r)return r.exports;var a=t[i]={id:i,loaded:!1,exports:{}};return e[i].call(a.exports,a,a.exports,n),a.loaded=!0,a.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var i in t)n.o(t,i)&&!n.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n.nmd=e=>(e.paths=[],e.children||(e.children=[]),e);var i={};return(()=>{"use strict";n.r(i),n.d(i,{ClientAssertionError:()=>we,ConnectReason:()=>le,ShakaPlayer:()=>ie,alarmManager:()=>N,auth:()=>de,deviceManager:()=>G,envInfo:()=>ve,getClientAssertion:()=>be,getConnectReason:()=>he,getDeviceInfo:()=>_e,getPlatformInfo:()=>fe,getTriggerEvent:()=>me,init:()=>ce,initSequence:()=>k,isRunningE2E:()=>ge,lifecycle:()=>O,messageManager:()=>J,platformManager:()=>$,remotePlayer:()=>C,setTimezone:()=>pe,shaka:()=>ne,showSequence:()=>D,uiReady:()=>ye,writeLicenseResponse:()=>Me});var e={};n.r(e),n.d(e,{ClientAssertionError:()=>we,ConnectReason:()=>le,ShakaPlayer:()=>ie,alarmManager:()=>N,auth:()=>de,deviceManager:()=>G,envInfo:()=>ve,getClientAssertion:()=>be,getConnectReason:()=>he,getDeviceInfo:()=>_e,getPlatformInfo:()=>fe,getTriggerEvent:()=>me,init:()=>ce,initSequence:()=>k,isRunningE2E:()=>ge,lifecycle:()=>O,messageManager:()=>J,platformManager:()=>$,remotePlayer:()=>C,setTimezone:()=>pe,shaka:()=>ne,showSequence:()=>D,uiReady:()=>ye,writeLicenseResponse:()=>Me});const t={rE:"4.2.64"},r=new class{sessionInfoStr="{}";get sessionInfoObj(){try{return JSON.parse(this.sessionInfoStr)}catch(e){return void d.warn("Failed to parse sessionInfo "+e.message)}}setSessionInfoStr(e){try{JSON.parse(e)}catch(e){throw Error("Failed to parse sessionInfo "+e.message)}this.sessionInfoStr=e}},{rE:a}=t;function s(){return Math.round(1e5*Math.random())+"-"+fe().sessionInfo?.connectionId}class o extends Error{constructor(e,t){super(t),this.code=e,this.msg=t}}class u{constructor(e){this.logFields=e}debug(...e){console.debug(this.formatLogString(e))}log(...e){console.log(this.formatLogString(e))}info(...e){console.info(this.formatLogString(e))}warn(...e){console.warn(this.formatLogString(e))}error(...e){console.error(this.formatLogString(e))}metrics(e){console.info(`[hs-sdk] [metrics] ${JSON.stringify(e)}`)}withFields(e){return new u({...this.logFields,...e})}formatLogString(e){let t="[hs-sdk] "+e.join(" ");return this.logFields&&(t+=" [log-fields] "+JSON.stringify(this.logFields)),t}}const d=new u({sdkVersion:a,url:window?.location?.href??""});async function l(e){if(window.cefQuery)return new Promise(((t,n)=>{const i=s(),r=d.withFields({FCID:i}),a={type:"restRequest",name:e,method:"GET",fcid:i},o={target:"TC",waitForResponse:!0,message:JSON.stringify(a)};let u=0;const l=window.cefQuery({request:JSON.stringify(o),persistent:!1,onSuccess:n=>{u&&clearTimeout(u),r.info(`Got restResponse for ${e}: ${n}`),t(n)},onFailure:(t,i)=>{u&&clearTimeout(u);const a=`failed to get restResponse for ${e}: ${t} ${i}`;r.error(a),n(a)}});u=setTimeout((()=>{window.cefQueryCancel(l);const t=`failed to get restResponse for ${e}: reached timeout of 5000 ms`;r.error(t),n(t)}),5e3)}));d.error("getRestResponse: window.cefQuery is undefined")}function c(e){return new Promise((t=>setTimeout(t,e)))}function h(e){return e&&(clearTimeout(e),e=0),e}function m(){const e=r.sessionInfoObj?.settings?.client?.ui_audio;return e?.enabled&&e?.from_cdn&&e?.ui_sync_enabled}function f(){return!0===r.sessionInfoObj?.settings?.["ui-streamer"]?.allowSubtitlesTranslation}const p=Object.freeze({NONE:0,AUDIO:1,VIDEO:2,SUBTITLE:4}),g=Object.freeze({NON_SEAMLESS:0,SEAMLESS:1}),y=Object.freeze({INIT:"init",PAUSED:"paused",FIRST_SEEK:"firstSeek",FIRST_WAITING:"firstWaiting",WAITING:"waiting",MULTI_SEEK:"multiSeek",DONE:"done"}),_=Object.freeze({PAUSED:"paused",PLAYING_UI:"playingUi",PLAYING_ABR:"playingAbr"}),v={aar:"aa",abk:"ab",afr:"af",aka:"ak",alb:"sq",amh:"am",ara:"ar",arg:"an",arm:"hy",asm:"as",ava:"av",ave:"ae",aym:"ay",aze:"az",bak:"ba",bam:"bm",baq:"eu",bel:"be",ben:"bn",bih:"bh",bis:"bi",bod:"bo",bos:"bs",bre:"br",bul:"bg",bur:"my",cat:"ca",ces:"cs",cha:"ch",che:"ce",chi:"zh",chu:"cu",chv:"cv",cor:"kw",cos:"co",cre:"cr",cym:"cy",dan:"da",deu:"de",div:"dv",dut:"nl",dzo:"dz",ell:"el",eng:"en",epo:"eo",est:"et",eus:"eu",ewe:"ee",fao:"fo",fas:"fa",fij:"fj",fin:"fi",fra:"fr",fre:"fr",fry:"fy",ful:"ff",geo:"ka",ger:"de",gla:"gd",gle:"ga",glg:"gl",glv:"gv",gre:"el",grn:"gn",guj:"gu",hat:"ht",hau:"ha",heb:"he",her:"hz",hin:"hi",hmo:"ho",hrv:"hr",hun:"hu",hye:"hy",ibo:"ig",ice:"is",ido:"io",iii:"ii",iku:"iu",ile:"ie",ina:"ia",ind:"id",ipk:"ik",isl:"is",ita:"it",jav:"jv",jpn:"ja",kal:"kl",kan:"kn",kas:"ks",kat:"ka",kau:"kr",kaz:"kk",khm:"km",kik:"ki",kin:"rw",kir:"ky",kom:"kv",kon:"kg",kor:"ko",kua:"kj",kur:"ku",lao:"lo",lat:"la",lav:"lv",lim:"li",lin:"ln",lit:"lt",ltz:"lb",lub:"lu",lug:"lg",mac:"mk",mah:"mh",mal:"ml",mao:"mi",mar:"mr",may:"ms",mkd:"mk",mlg:"mg",mlt:"mt",mon:"mn",mri:"mi",msa:"ms",mya:"my",nau:"na",nav:"nv",nbl:"nr",nde:"nd",ndo:"ng",nep:"ne",nld:"nl",nno:"nn",nob:"nb",nor:"no",nya:"ny",oci:"oc",oji:"oj",ori:"or",orm:"om",oss:"os",pan:"pa",per:"fa",pli:"pi",pol:"pl",por:"pt",pus:"ps",que:"qu",roh:"rm",ron:"ro",rum:"ro",run:"rn",rus:"ru",sag:"sg",san:"sa",sin:"si",slk:"sk",slo:"sk",slv:"sl",sme:"se",smo:"sm",sna:"sn",snd:"sd",som:"so",sot:"st",spa:"es",sqi:"sq",srd:"sc",srp:"sr",ssw:"ss",sun:"su",swa:"sw",swe:"sv",tah:"ty",tam:"ta",tat:"tt",tel:"te",tgk:"tg",tgl:"tl",tha:"th",tib:"bo",tir:"ti",ton:"to",tsn:"tn",tso:"ts",tuk:"tk",tur:"tr",twi:"tw",uig:"ug",ukr:"uk",urd:"ur",uzb:"uz",ven:"ve",vie:"vi",vol:"vo",wel:"cy",wln:"wa",wol:"wo",xho:"xh",yid:"yi",yor:"yo",zha:"za",zho:"zh",zul:"zu"},M={BACK:27,HOME:36,LEFT:37,RIGHT:39,UP:38,DOWN:40,ENTER:13},w={root:{top:"5vh",left:"82vw",height:"90vh",fontSize:"16px",width:"16vw",position:"fixed",zIndex:1e4,overflow:"hidden",visibility:"hidden"},item:{backgroundColor:"white",color:"black",fontSize:"12px",display:"flex",padding:"6px",border:"1px solid black",borderTop:"none"},item_key:{borderTopLeftRadius:"6px",borderTopRightRadius:"6px",marginTop:"20px",borderBottom:"3px solid black"},component:{fontWeight:"bold",width:"5vw"},component_key:{fontWeight:"normal",color:"darkgray"},id:{textAlign:"left",fontWeight:"normal",flex:1},id_key:{fontWeight:"bold"},time:{fontVariantNumeric:"tabular-nums",width:"3vw"},time_key:{fontWeight:"bold"}};let b=performance.now();const T=(e,t)=>"key"===t?new Date(e).toLocaleTimeString("en-US",{hour12:!1}):`${(e/1e3).toFixed(2)}s`,L=(e,t,n)=>{Object.entries(e).forEach((([e,i])=>{Object.getOwnPropertyNames(Object.getPrototypeOf(i)).forEach((r=>{if(n&&n(r))return;const a=i[r];"function"==typeof a&&(i[r]=function(...n){return t(e,r,...n),a.apply(this,n)})}))}))},S=(e,t)=>{e.innerHTML="",t.forEach(((n,i)=>{const r=document.createElement("div");Object.assign(r.style,{...w.item,...w[`item_${n?.component}`]}),["component","id","time"].forEach((e=>{if(n[e]){const t=document.createElement("div");Object.assign(t.style,w[e],w[`${e}_${n.component}`]),t.textContent="time"===e?T(n.time,n.component):n[e],r.appendChild(t)}})),e.appendChild(r),i===t.length-1&&r.scrollIntoView({behavior:"smooth"})}))},k=e=>{if(!e)return void d.error("No components to sequence");let t=document.getElementById("sequence-container");if(t)return;t=(()=>{const e=document.createElement("div");return e.id="sequence-container",Object.assign(e.style,w.root),document.body.appendChild(e),e})();const n=new Proxy([],{set:(e,i,r)=>(e[i]=r,"length"!==i&&S(t,n),!0)});window.printSequence=()=>(e=>{const t=e.map((e=>{const t=e.separator?"\n":"",n=e?.time?` ${T(e.time,e?.component)}`:"";if(e.args){const i=e.args.map((e=>"object"==typeof e?"object":e)).join(", ");return`${t}${e.component}.${e.id}(${i})${n}`}return`\n${e.component}: ${e.id}${n}`}));d.log("sequence:\n",t.join("\n"))})(n),((e,t)=>{t.push({component:"key",id:"BOOT",time:Date.now()}),L(e,((e,n,...i)=>{t.push({component:e,id:n,args:i,time:performance.now()-b})}),(e=>e.startsWith("_")||e.startsWith("get"))),(e=>{window.addEventListener("keydown",(t=>{var n;e.push({component:"key",id:(n=t.keyCode,Object.entries(M).find((([,e])=>e===n))?.[0]||String(n)),time:Date.now()}),b=performance.now()}))})(t),function(e,t){e.remotePlayer.addEventListener("videoelementattached",(()=>{const n=e.remotePlayer._videoElement;n&&!n._devSequenceRateChangeHandler&&(n._devSequenceRateChangeHandler=()=>{t.push({component:"localPlayer",id:"ratechange="+n.playbackRate,time:performance.now()-b})},n.addEventListener("ratechange",n._devSequenceRateChangeHandler)),n&&!n._devSequencePlayingHandler&&(n._devSequencePlayingHandler=()=>{t.push({component:"localPlayer",id:"playing event",time:performance.now()-b})},n.addEventListener("playing",n._devSequencePlayingHandler))})),e.remotePlayer.addEventListener("playing",(()=>{t.push({component:"remotePlayer",id:"playing event",time:performance.now()-b})}))}(e,t),d.log("Sequence initialized.")})(e,n),S(t,n)},D=(e=!0)=>{const t=document.getElementById("sequence-container");t?t.style.visibility=e?"visible":"hidden":d.error("Sequence not initialized")};class x{constructor(e={}){this.listeners=new Map,this.timeoutMs=e.timeoutMs||5e3}addEventListener(e,t){this.listeners.has(e)||this.listeners.set(e,[]),this.listeners.get(e).push(t)}removeEventListener(e,t){if(!this.listeners.has(e))return;const n=this.listeners.get(e),i=n.indexOf(t);-1!==i&&n.splice(i,1)}async dispatch(e,t={}){const n=this.listeners.get(e)||[];if(0===n.length)return;const i=t instanceof Event?t:new CustomEvent(e,{detail:t}),r=n.map((t=>{try{return Promise.resolve(t(i)).catch((t=>{d.error(`Error in ${e} listener (promise rejection):`,t)}))}catch(t){return d.error(`Error in ${e} listener:`,t),Promise.resolve()}}));try{let t=null;const n=new Promise((n=>{t=setTimeout((()=>{d.warn(`Event dispatch for ${e} timed out after ${this.timeoutMs}ms`),n()}),this.timeoutMs)})),i=Promise.allSettled(r).then((e=>(null!==t&&(clearTimeout(t),t=null),e)));await Promise.race([i,n])}catch(t){d.error(`Error waiting for ${e} listeners to complete:`,t)}}}const A=e=>JSON.parse(JSON.stringify(e));class Y extends Error{constructor(e,t){super(t),this.code=e,this.msg=t}}function E(){const e=window.getPlaybackInfo?window.getPlaybackInfo():JSON.stringify({playbackPosition:0,assetDuration:0});let t;try{t=JSON.parse(e)}catch(n){d.error(`Playback Info parse failed. playbackStr = ${e} error = ${n.message}`),t={playbackPosition:0,assetDuration:0}}return t}function I(e){try{const t=JSON.stringify(e);window.setPlaybackInfo&&window.setPlaybackInfo(t)}catch(e){d.error("Playback Info to json string failed: ",e.message)}}class P extends EventTarget{constructor(){super(),this._config={preferredAudioLanguage:"",preferredSubtitlesLanguage:"",minSuggestedPresentationDelay:0},this._selectedAudioTrack="",this._selectedSubtitlesTrack="",this._availableAudioTracks=[],this._availableTextTracks=[],this._textTrackVisibility=!1,this._ptsSessionId=0,this._videoElement=void 0,this._isInitialized=!1,this._loadStartEventListener=void 0,this._isSeekingByApplication=!1,this._isSeekingByPlatform=!1,this._isPlaying=!1,this._blackoutTime=0,"undefined"!=typeof document&&document.addEventListener("hs/remotePlayerEvent",(e=>{d.info("Got hs/remotePlayerEvent event with detail",JSON.stringify(e?.detail)),this.dispatchEvent(new Event(e?.detail?.eventName))})),"undefined"!=typeof document&&document.addEventListener("hs/playbackInfoEvent",(()=>{d.info("Got hs/playbackInfoEvent"),this._videoElement?m()||O.state!==O.UiState.BACKGROUND&&O.state!==O.UiState.IN_TRANSITION_TO_BACKGROUND||this._syncLocalPlayerWithRemotePlayer():this.dispatchEvent(new Event("timeupdate"))})),"undefined"!=typeof document&&document.addEventListener("hs/playback",(e=>{d.info("Got hs/playback event with detail",JSON.stringify(e?.detail)),this._availabilityStartTime=e?.detail?.availabilityStartTime,this._updateTracks(e?.detail),this.dispatchEvent(new Event("tracksupdate"))})),"undefined"!=typeof document&&document.addEventListener("hs/EOS",(()=>{d.info("Got hs/EOS event"),this.dispatchEvent(new Event("ended"))})),"undefined"!=typeof document&&document.addEventListener("hs/ui_inactive",(()=>{d.info("Got hs/ui_inactive event")})),"undefined"!=typeof document&&document.addEventListener("hs/senzaPlayerSetRate",(e=>{this._videoElement&&(this._isSeekingByApplication?d.info("Skip senzaPlayerSetRate while seek performed"):this._videoElement.playbackRate=e.detail.rate)})),"undefined"!=typeof document&&document.addEventListener("hs/senzaPlayerSetTime",(e=>{if(!this._isAudioSyncEnabled())return;if(this._isSeekingByApplication)return void d.info("Skip senzaPlayerSetTime while seek performed");const t=this._videoElement.currentTime;this._isSeekingByPlatform=!0,this._videoElement.playbackRate=1,this._videoElement.currentTime+=e.detail,d.info(`Adding ${e.detail} seconds, previousTime=${t} currentTime=${this._videoElement.currentTime}`)})),"undefined"!=typeof document&&document.addEventListener("hs/ERR",(e=>{d.info("Got hs/ERR event"),delete e?.detail?.type,delete e?.detail?.eventCode,this.dispatchEvent(new CustomEvent("error",e))})),"undefined"!=typeof document&&document.addEventListener("hs/getLicense",(e=>{d.info("Got hs/getLicense event");const t=e?.detail,n=Uint8Array.from(t.request,(e=>e.charCodeAt(0))),i=new ArrayBuffer(n.byteLength);new Uint8Array(i).set(n),this.licenseRequest=i;const r=t.fcid,a=t.sessionId,s=new CustomEvent("license-request",{detail:{licenseRequest:i}});s.writeLicenseResponse=(e,t)=>{Me(e,t,r,a)},this.dispatchEvent(s)}))}LoadMode=Object.freeze({NOT_LOADED:"notLoaded",LOADING:"loading",LOADED:"loaded",UNLOADING:"unloading"});async _init(e,t){let n={isLoaded:!1,playbackUrl:""};if(window.cefQuery){const e=s(),t=d.withFields({FCID:e}),i={type:"playerState",fcid:e},r={target:"UI-Streamer",waitForResponse:!1,message:JSON.stringify(i)};try{const e=await new Promise(((e,n)=>{window.cefQuery({request:JSON.stringify(r),persistent:!1,onSuccess:n=>{t.log("playerState request successfully returned",n),e(n)},onFailure:(e,i)=>{t.error(`playerState request failed: ${e} ${i}`),n()}})}));n=JSON.parse(e)}catch{t.error("either failed to get or failed to parse player state")}}this._loadMode=n?.isLoaded?this.LoadMode.LOADED:this.LoadMode.NOT_LOADED,this._isPlaying="true"===window?.sessionStorage?.getItem("senzaSdk_isPlaying"),d.info(`RemotePlayer initialized with load mode: ${this._loadMode}, senzaSdk_isPlaying: ${this._isPlaying}`),this._loadedUrl=n?.playbackUrl||"",this._isInitialized=!0,this._remotePlayerConfirmationTimeout=e?.remotePlayerConfirmationTimeout??5e3,this._remotePlayerApiVersion=e?.remotePlayerApiVersion||1,this._multiSeekDelay=e?.multiSeekDelay||250,d.info(`remotePLayer isPlaying=${this._isPlaying}`);let i={};try{i=JSON.parse(t?.playbackMetadata||"{}")}catch(e){d.error(`failed to parse playbackMetadata: ${e.message}`)}this._availabilityStartTime=i.availabilityStartTime,this._updateTracks(i)}_updateTracks(e){if(this._availableAudioTracks=e?.availableAudioTracks||this._availableAudioTracks,this._availableTextTracks=e?.availableSubtitlesTracks||this._availableTextTracks,f()&&"VOD"===e?.assetType&&(this._availableTextTracks=function(e){if(!e||e.length<1)return e;e.sort(((e,t)=>e.lang.toLowerCase()>t.lang.toLowerCase()?1:-1));const t=[{lang:"af",id:"*:af"},{lang:"ar",id:"*:ar"},{lang:"az",id:"*:az"},{lang:"bg",id:"*:bg"},{lang:"bs",id:"*:bs"},{lang:"ca",id:"*:ca"},{lang:"cs",id:"*:cs"},{lang:"cy",id:"*:cy"},{lang:"da",id:"*:da"},{lang:"de",id:"*:de"},{lang:"el",id:"*:el"},{lang:"en",id:"*:en"},{lang:"es",id:"*:es"},{lang:"es-MX",id:"*:es-MX"},{lang:"et",id:"*:et"},{lang:"fi",id:"*:fi"},{lang:"fr",id:"*:fr"},{lang:"fr-CA",id:"*:fr-CA"},{lang:"ga",id:"*:ga"},{lang:"ha",id:"*:ha"},{lang:"he",id:"*:he"},{lang:"hr",id:"*:hr"},{lang:"ht",id:"*:ht"},{lang:"hu",id:"*:hu"},{lang:"id",id:"*:id"},{lang:"is",id:"*:is"},{lang:"it",id:"*:it"},{lang:"kk",id:"*:kk"},{lang:"lt",id:"*:lt"},{lang:"lv",id:"*:lv"},{lang:"mk",id:"*:mk"},{lang:"mn",id:"*:mn"},{lang:"ms",id:"*:ms"},{lang:"mt",id:"*:mt"},{lang:"nl",id:"*:nl"},{lang:"no",id:"*:no"},{lang:"pl",id:"*:pl"},{lang:"pt",id:"*:pt"},{lang:"pt-PT",id:"*:pt-PT"},{lang:"ro",id:"*:ro"},{lang:"ru",id:"*:ru"},{lang:"sk",id:"*:sk"},{lang:"sl",id:"*:sl"},{lang:"so",id:"*:so"},{lang:"sq",id:"*:sq"},{lang:"sr",id:"*:sr"},{lang:"sv",id:"*:sv"},{lang:"sw",id:"*:sw"},{lang:"tl",id:"*:tl"},{lang:"tr",id:"*:tr"},{lang:"uk",id:"*:uk"},{lang:"uz",id:"*:uz"},{lang:"vi",id:"*:vi"},{lang:"zh",id:"*:zh"}],n=[...e];for(const i of t)e.find((e=>e.lang===i.lang))||(i.autoTranslate=!0,n.push(i));return n}(this._availableTextTracks)),this._availableAudioTracks){const e=this._availableAudioTracks.find((e=>!0===e.selected));this._selectedAudioTrack=e?.id||""}if(this._availableTextTracks){const e=this._availableTextTracks.find((e=>!0===e.selected));this._selectedSubtitlesTrack=e?.id||""}}_isAudioSyncEnabled(){return m()&&this._videoElement}getConfiguration(){return A(this._config)}configure(e){Object.entries(e).forEach((([e,t])=>{if(void 0!==this._config[e]){if("preferredSubtitlesLanguage"===e&&!f()&&(n=t,(n?.toString()||"").startsWith("*:")))return void d.warn(`Invalid preferredSubtitlesLanguage ${t}`);this._config[e]=t}var n}))}_changeLoadMode(e){this._loadMode!==e&&(this._loadMode=e,this.dispatchEvent(new Event("onloadmodechange")))}_changePlayMode(e){if(this._isPlaying!==e){const t=new CustomEvent("playModeChange",{detail:{isPlaying:e}});this.dispatchEvent(t)}this._isPlaying=e,window?.sessionStorage?.setItem("senzaSdk_isPlaying",String(e))}_handleVideoFrameInfo(e){const t=s(),n=d.withFields({fcid:t}),i=(e,n)=>{if(!this._isSeekingByApplication){const e={type:"currentFramePTS",fcid:t,currentFramePTS:n.mediaTime.toString(),ptsSessionId:this._ptsSessionId},i={target:"UI-Streamer",waitForResponse:!1,message:JSON.stringify(e)};window.cefQuery({request:JSON.stringify(i),persistent:!1})}this._videoElement?.requestVideoFrameCallback(i)},r=e=>{this._localPlayerLoadCurrentTime=this._videoElement.currentTime,this._ptsSessionId++,d.info("videoElement, loadstart ptsSessionId=",this._ptsSessionId," event=",e)};this._loadStartEventListener=r,n.log("handle_video_frame_pts: requesting video frame info"),this._videoElement!==e&&(e.requestVideoFrameCallback(i),e.addEventListener("loadstart",r))}_syncRemotePlayerWithLocalPlayer(){this._videoElement&&this._seek(this._videoElement.currentTime,!1)}_syncLocalPlayerWithRemotePlayer(){this._videoElement&&(this._videoElement.currentTime=this.currentTime)}_reset(){this._availableAudioTracks=[],this._availableTextTracks=[],this._selectedAudioTrack="",this._selectedSubtitlesTrack="",this._availabilityStartTime=void 0,this._isSeekingByPlatform=!1,this._isSeekingByApplication=!1}_seek(e,t=!0){if(!this._isInitialized)throw new Y(6500,"Cannot call seek() if remote player is not initialized");if(I({playbackPosition:e}),window.cefQuery){if(this._loadMode!==this.LoadMode.LOADED)throw new Y(6001,"Cannot call seek() if player is not loaded");const n=s(),i=d.withFields({FCID:n});i.log("setting remotePlayer currentTime");const r={type:"remotePlayer.seek",class:"remotePlayer",action:"seek",playbackPosition:e,fcid:n},a={target:"TC",waitForResponse:t,message:JSON.stringify(r)};return new Promise(((e,n)=>{let r=0;const s=Date.now(),o=window.cefQuery({request:JSON.stringify(a),persistent:!1,onSuccess:()=>{this._remotePlayerApiVersion>=2&&this.dispatchEvent(new Event("seeking"));const t=Date.now()-s;i.withFields({duration:t}).log(`seek completed successfully after ${t} ms`),r=h(r),e()},onFailure:(e,t)=>{const a=Date.now()-s;i.withFields({duration:a}).log(`seek failed after ${a} ms. Error code: ${e}, error message: ${t}`),r=h(r),n(new Y(e,t))}});if(i.log(`window.cefQuery for seek returned query id ${o}`),t){const e=this._remotePlayerConfirmationTimeout+1e3;r=setTimeout((()=>{i.log(`seek reached timeout of ${e} ms, canceling query id ${o}`),window.cefQueryCancel(o),n(new Y(6e3,`seek reached timeout of ${e} ms`))}),e,o)}}))}return d.error("remotePlayer seek: window.cefQuery is undefined"),Promise.resolve(void 0)}_play(e){if(window.cefQuery){const t=s(),n=d.withFields({FCID:t}),i=this._selectedAudioTrack||this._config.preferredAudioLanguage||"",r=this._selectedSubtitlesTrack||this._config.preferredSubtitlesLanguage||"";if(this._remotePlayerApiVersion>=2&&!this._textTrackVisibility&&e===p.SUBTITLE)return n.log("remotePlayer play: text track visibility is disabled and streamType is only SUBTITLE. returning early with no action."),Promise.resolve(void 0);const a={type:"remotePlayer.play",class:"remotePlayer",action:"play",fcid:t,audioLanguage:i,subtitlesLanguage:r,playbackPosition:this.currentTime};let o=!1;this._remotePlayerApiVersion>=2?(a.switchMode=this._isAudioSyncEnabled()?g.SEAMLESS:g.NON_SEAMLESS,a.streamType=e,o=!0,!this._textTrackVisibility&&a.streamType&p.SUBTITLE&&(a.streamType=a.streamType&~p.SUBTITLE,n.log("remotePlayer play: text track visibility is disabled. Removed SUBTITLE from streamType."))):this.textTrackVisibility||(a.subtitlesLanguage=""),n.log(`remotePlayer play: sending play action remotePlayer._isPlaying: ${this._isPlaying} audioLanguage=${a.audioLanguage} subtitlesLanguage=${a.subtitlesLanguage} textTrackVisibility=${this.textTrackVisibility}`);const u={target:"TC",waitForResponse:o,message:JSON.stringify(a)};return new Promise(((e,t)=>{let i=0;const r=Date.now(),a=window.cefQuery({request:JSON.stringify(u),persistent:!1,onSuccess:()=>{const t=Date.now()-r;n.withFields({duration:t}).log(`play completed successfully after ${t} ms`),i=h(i),e()},onFailure:(e,a)=>{const s=Date.now()-r;n.withFields({duration:s}).log(`play failed after ${s} ms. Error code: ${e}, error message: ${a}`),i=h(i),t(new Y(e,a))}});if(n.log(`window.cefQuery for play returned query id ${a}`),o){const e=this._remotePlayerConfirmationTimeout+1e3;i=setTimeout((()=>{n.log(`play reached timeout of ${e} ms, canceling query id ${a}`),window.cefQueryCancel(a),t(new Y(6e3,`play reached timeout of ${e} ms`))}),e,a)}}))}return d.error("remotePlayer play: window.cefQuery is undefined"),Promise.resolve(void 0)}_pause(){if(window.cefQuery){const e=O.state===O.UiState.FOREGROUND||O.state===O.UiState.IN_TRANSITION_TO_FOREGROUND;if(this._remotePlayerApiVersion>=2&&!this._isAudioSyncEnabled()&&e)return d.info("remotePlayer pause: application in foreground, remote player is not playing."),Promise.resolve();const t=s(),n=d.withFields({FCID:t});n.log("remotePlayer pause: sending pause request");const i={type:"remotePlayer.pause",class:"remotePlayer",action:"pause",fcid:t};this._remotePlayerApiVersion>=2&&(i.streamType=this._isAudioSyncEnabled()&&e?p.AUDIO:p.AUDIO|p.VIDEO|p.SUBTITLE);const r=this._remotePlayerApiVersion>=2,a={target:"TC",waitForResponse:r,message:JSON.stringify(i)};return new Promise(((e,t)=>{let i=0;const s=Date.now(),o=window.cefQuery({request:JSON.stringify(a),persistent:!1,onSuccess:()=>{const t=Date.now()-s;n.withFields({duration:t}).log(`pause completed successfully after ${t} ms`),i=h(i),e()},onFailure:(e,r)=>{const a=Date.now()-s;n.withFields({duration:a}).log(`pause failed after ${a} ms. Error code: ${e}, error message: ${r}`),i=h(i),t(new Y(e,r))}});if(n.log(`window.cefQuery for pause returned query id ${o}`),r){const e=this._remotePlayerConfirmationTimeout+1e3;i=setTimeout((()=>{n.log(`pause reached timeout of ${e} ms, canceling query id ${o}`),window.cefQueryCancel(o),t(new Y(6e3,`pause reached timeout of ${e} ms`))}),e,o)}}))}return d.error("remotePlayer pause: window.cefQuery is undefined"),Promise.resolve(void 0)}_stop(e){if(window.cefQuery){const t=s(),n=d.withFields({FCID:t});n.log(`remotePlayer stop: sending stop action for streamType ${e}`);const i={type:"remotePlayer.stop",class:"remotePlayer",action:"stop",streamType:e,fcid:t},r={target:"TC",waitForResponse:!0,message:JSON.stringify(i)};return new Promise(((e,t)=>{let i=0;const a=Date.now(),s=window.cefQuery({request:JSON.stringify(r),persistent:!1,onSuccess:()=>{const t=Date.now()-a;n.withFields({duration:t}).log(`stop completed successfully after ${t} ms`),i=h(i),e()},onFailure:(e,r)=>{const s=Date.now()-a;n.withFields({duration:s}).log(`stop failed after ${s} ms. Error code: ${e}, error message: ${r}`),i=h(i),t(new Y(e,r))}});n.log(`window.cefQuery for stop returned query id ${s}`);const o=this._remotePlayerConfirmationTimeout+1e3;i=setTimeout((()=>{n.log(`stop reached timeout of ${o} ms, canceling query id ${s}`),window.cefQueryCancel(s),t(new Y(6e3,`stop reached timeout of ${o} ms`))}),o,s)}))}return d.error("remotePlayer stop: window.cefQuery is undefined"),Promise.resolve(void 0)}registerVideoElement(e){this.attach(e)}attach(e){if(!e)return this._videoElement=void 0,void d.warn("video element is undefined, therefore no local/remote player sync will be done");this._videoElement!==e&&(this._videoElement&&this.detach(),m()&&(this._handleVideoFrameInfo(e),this._updateSeekListeners(e)),this._videoElement=e,this.dispatchEvent(new Event("videoelementattached")))}detach(){this._videoElement&&(this._videoElement.removeEventListener("loadstart",this._load_start_event_listener),this._loadStartEventListener=void 0),this._updateSeekListeners(void 0),this._videoElement=void 0}async load(e,t){return this._load(e,t)}async _load(e,t,n=void 0,i=void 0,r=!0){if(!this._isInitialized)throw new Y(6500,"Cannot call load() if remote player is not initialized");if(e&&window.cefQuery){const a=O.state;if(a===O.UiState.BACKGROUND||a===O.UiState.IN_TRANSITION_TO_BACKGROUND)throw new Y(6002,`Cannot call load() while in state '${O.UiState.BACKGROUND}' or '${O.UiState.IN_TRANSITION_TO_BACKGROUND}'`);if(this._loadMode===this.LoadMode.LOADING||this._loadMode===this.LoadMode.UNLOADING)throw new Y(6501,"Cannot call load() while previous load/unload is still in progress");this._abortSetAudioLanguage=!0,this._abortSetSubtitleLanguage=!0,this._abortSeeking=!0,this._blackoutTime=0,r&&this._reset();const o=this._loadMode;return this._changeLoadMode(this.LoadMode.LOADING),this._changePlayMode(!1),new Promise(((a,u)=>{r&&I({playbackPosition:0});const l=s(),c=t??0,m=d.withFields({FCID:l,loadUrl:e,playbackPosition:c}),f=n||this._selectedAudioTrack||this._config.preferredAudioLanguage||"",p=i||this._selectedSubtitlesTrack||this._config.preferredSubtitlesLanguage||"",g={url:e,timeout:this._remotePlayerConfirmationTimeout,autoPlay:!1,playbackPosition:c,fcid:l};this._remotePlayerApiVersion>=2?(g.type="remotePlayer.load",g.class="remotePlayer",g.action="load",g.audioLanguage=f,g.subtitlesLanguage=p,this.getConfiguration().minSuggestedPresentationDelay>0&&(g.cloudPlayerParams={mspd:this.getConfiguration().minSuggestedPresentationDelay})):g.type="setPlayableUri",m.log(`remotePlayer load: sending ${g.type} request. remotePlayer._isPlaying: ${this._isPlaying} audioLanguage=${f} subtitlesLanguage=${p}`);const y={target:"TC",waitForResponse:!0,message:JSON.stringify(g)};let _=0;const v=Date.now(),M=window.cefQuery({request:JSON.stringify(y),persistent:!1,onSuccess:()=>{const n=Date.now()-v;m.withFields({duration:n}).log(`${g.type} completed successfully after ${n} ms`),t>0&&I({playbackPosition:t}),_=h(_),this._changeLoadMode(this.LoadMode.LOADED),this._loadedUrl=e,this.dispatchEvent(new Event("canplay")),a()},onFailure:(e,t)=>{const n=Date.now()-v;m.withFields({duration:n}).log(`${g.type} failed after ${n} ms. Error code: ${e}, error message: ${t}`),_=h(_),99===e?this._changeLoadMode(o):(this._changeLoadMode(this.LoadMode.NOT_LOADED),this._loadedUrl=""),u(new Y(e,t))}});m.log(`window.cefQuery for ${g.type} returned query id ${M}`);const w=this._remotePlayerConfirmationTimeout+1e3;_=setTimeout((()=>{m.log(`${g.type} reached timeout of ${w} ms, canceling query id ${M}`),window.cefQueryCancel(M),this._changeLoadMode(this.LoadMode.NOT_LOADED),this._loadedUrl="",u(new Y(6e3,`load reached timeout of ${w} ms`))}),w,M)}))}d.error("remotePlayer load: either window.cefQuery or url is undefined")}async unload(){if(!this._isInitialized)throw new Y(6500,"Cannot call unload() if remote player is not initialized");if(window.cefQuery){if(this._loadMode===this.LoadMode.LOADING||this._loadMode===this.LoadMode.UNLOADING)throw new Y(6502,"Cannot call unload() while previous unload/load is still in progress");this._abortSetAudioLanguage=!0,this._abortSetSubtitleLanguage=!0,this._abortSeeking=!0;const e=this._loadMode;return this._changeLoadMode(this.LoadMode.UNLOADING),this._changePlayMode(!1),new Promise(((t,n)=>{const i=s(),r=d.withFields({FCID:i});r.log(`remotePlayer unload remotePlayer._isPlaying ${this._isPlaying}`);const a={type:"remotePlayer.unload",class:"remotePlayer",action:"unload",fcid:i},o={target:"TC",waitForResponse:!0,message:JSON.stringify(a)};let u=0;const l=Date.now(),c=window.cefQuery({request:JSON.stringify(o),persistent:!1,onSuccess:()=>{const e=Date.now()-l;r.withFields({duration:e}).log(`unload completed successfully after ${e} ms`),u=h(u),this._reset(),this._changeLoadMode(this.LoadMode.NOT_LOADED),this._loadedUrl=void 0,t()},onFailure:(t,i)=>{const a=Date.now()-l;r.withFields({duration:a}).log(`unload failed after ${a} ms. Error code: ${t}, error message: ${i}`),u=h(u),this._changeLoadMode(e),n(new Y(t,i))}});r.log(`window.cefQuery for unload returned query id ${c}`);const m=this._remotePlayerConfirmationTimeout+1e3;u=setTimeout((()=>{r.log(`unload reached timeout of ${m} ms, canceling query id ${c}`),window.cefQueryCancel(c),this._changeLoadMode(e),n(new Y(6e3,`unload reached timeout of ${m} ms`))}),m,c)}))}d.error("remotePlayer unload: window.cefQuery is undefined")}play(){if(!this._isInitialized)throw new Y(6500,"Cannot call play() if remote player is not initialized");if(window.cefQuery&&this._loadMode!==this.LoadMode.LOADED)throw new Y(6001,"Cannot call play() if player is not loaded");return this._changePlayMode(!0),this._isSetAudioInProgress?(d.info("application requesting play during setAudioLanguage"),this._targetSetAudioPlayingState=_.PLAYING_UI,Promise.resolve(!0)):this._isSetSubtitlesInProgress?(d.info("application requesting play during setSubtitleLanguage"),this._targetSetSubtitlePlayingState=_.PLAYING_UI,Promise.resolve(!0)):this._isSeekingByApplication?(d.info("application requesting play during seek"),this._targetSeekPlayingState=_.PLAYING_UI,Promise.resolve(!0)):this._remotePlayerApiVersion>=2&&!this._isAudioSyncEnabled()?(d.info("play was called but _isAudioSyncEnabled is disabled, ignoring."),Promise.resolve(!0)):this._play(p.AUDIO)}pause(){if(!this._isInitialized)throw new Y(6500,"Cannot call pause() if remote player is not initialized");if(window.cefQuery&&this._loadMode!==this.LoadMode.LOADED)throw new Y(6001,"Cannot call pause() if player is not loaded");return this._changePlayMode(!1),this._isSeekingByApplication?(d.info("application requesting pause during seek"),this._targetSeekPlayingState=_.PAUSED,Promise.resolve(!0)):this._isSetAudioInProgress?(d.info("application requesting pause during setAudioLanguage"),this._targetSetAudioPlayingState=_.PAUSED,Promise.resolve(!0)):this._isSetSubtitlesInProgress?(d.info("application requesting pause during setSubtitleLanguage"),this._targetSetSubtitlePlayingState=_.PAUSED,Promise.resolve(!0)):this._pause()}getAssetUri(){if(!this._isInitialized)throw new Y(6500,"Cannot call getAssetUri() if remote player is not initialized");return this._loadedUrl}getLoadMode(){if(!this._isInitialized)throw new Y(6500,"Cannot call getLoadMode() if remote player is not initialized");return this._loadMode}getTextTracks(){return A(this._availableTextTracks)}getAudioTracks(){return A(this._availableAudioTracks)}selectAudioTrack(e){if(!this._isInitialized)throw new Y(6500,"Cannot call selectAudioTrack() if remote player is not initialized");if(this._loadMode!==this.LoadMode.LOADED)throw new Y(6001,"Cannot call selectAudioTrack() if remote player is not loaded");let t=!1;const n=this._selectedAudioTrack;for(const n of this.getAudioTracks())if(n.id===e){t=!0;break}if(!t)return d.warn(`Invalid audioTrackId ${e}`),Promise.resolve();if(this._selectedAudioTrack===e)return Promise.resolve();switch(this._remotePlayerApiVersion){case 0:case 1:return this._selectedAudioTrack=e,Promise.resolve();case 2:return this._selectAudioTrackV2(e,n);default:return this._atomicSetAudioLanguage(e,n)}}async _selectAudioTrackV2(e,t){const n=this._isPlaying;d.log(`remotePlayer _selectAudioTrackV2: prevAudioTrack=${t} audioTrackId=${e} isPlaying=${this._isPlaying}`);try{this._isPlaying&&await this.pause();let t=this.currentTime;this._videoElement&&(t=this._videoElement.currentTime),await this._load(this._loadedUrl,t,e,void 0,!1),this._selectedAudioTrack=e}catch(t){return void d.warn(`Failed to select audio track ${e}: ${t.message}`)}if(n)try{await this.play()}catch(t){d.info(`Failed to play after selecting audio track ${e}: ${t.message}`)}}async _selectAudioTrackV3(e){if(d.log(`remotePlayer _selectAudioTrackV3: audioTrackId=${e} isPlaying=${this._isPlaying}`),window.cefQuery){const t=s(),n=d.withFields({FCID:t});n.log("remotePlayer _selectAudioTrackV3: sending setAudioLanguage action");const i={type:"remotePlayer.setAudioLanguage",class:"remotePlayer",action:"setAudioLanguage",fcid:t,language:e},r={target:"TC",waitForResponse:!0,message:JSON.stringify(i)};return new Promise(((t,i)=>{let a=0;const s=Date.now(),o=window.cefQuery({request:JSON.stringify(r),persistent:!1,onSuccess:()=>{this._selectedAudioTrack=e;const i=Date.now()-s;n.withFields({duration:i}).log(`setAudioLanguage completed successfully after ${i} ms`),a=h(a),t()},onFailure:(e,t)=>{const r=Date.now()-s;n.withFields({duration:r}).log(`setAudioLanguage failed after ${r} ms. Error code: ${e}, error message: ${t}`),a=h(a),i(new Y(e,t))}});n.log(`window.cefQuery for setAudioLanguage returned query id ${o}`);const u=this._remotePlayerConfirmationTimeout+1e3;a=setTimeout((()=>{n.log(`setAudioLanguage reached timeout of ${u} ms, canceling query id ${o}`),window.cefQueryCancel(o),i(new Y(6e3,`setAudioLanguage reached timeout of ${u} ms`))}),u,o)}))}return d.error("remotePlayer _selectAudioTrackV3: window.cefQuery is undefined"),Promise.resolve(void 0)}selectTextTrack(e){if(!this._isInitialized)throw new Y(6500,"Cannot call selectTextTrack() if remote player is not initialized");if(this._loadMode!==this.LoadMode.LOADED)throw new Y(6001,"Cannot call selectTextTrack() if remote player is not loaded");let t=!1;const n=this._selectedSubtitlesTrack;for(const n of this.getTextTracks())if(n.id===e){t=!0;break}if(!t)return d.warn(`Invalid textTrackId ${e}`),Promise.resolve();if(this._selectedSubtitlesTrack===e)return Promise.resolve();switch(this._remotePlayerApiVersion){case 0:case 1:return this._selectedSubtitlesTrack=e,Promise.resolve();case 2:return this._selectTextTrackV2(e,n);default:return this._atomicSetSubtitleLanguage(e,n)}}async _selectTextTrackV2(e,t){const n=this._isPlaying;d.log(`remotePlayer _selectTextTrackV2: prevTextTrack=${t} textTrackId=${e} isPlaying=${this._isPlaying}`);try{this._isPlaying&&await this.pause();let t=this.currentTime;this._videoElement&&(t=this._videoElement.currentTime),await this._load(this._loadedUrl,t,void 0,e,!1),this._selectedSubtitlesTrack=e}catch(t){return void d.warn(`Failed to select text track ${e}: ${t.message}`)}if(n)try{await this.play()}catch(t){d.info(`Failed to play after selecting text track ${e}: ${t.message}`)}}async _selectTextTrackV3(e){if(window.cefQuery){const t=s(),n=d.withFields({FCID:t});n.log("remotePlayer _selectTextTrackV3: sending setSubtitleLanguage action");const i={type:"remotePlayer.setSubtitleLanguage",class:"remotePlayer",action:"setSubtitleLanguage",fcid:t,language:e},r={target:"TC",waitForResponse:!0,message:JSON.stringify(i)};return new Promise(((t,i)=>{let a=0;const s=Date.now(),o=window.cefQuery({request:JSON.stringify(r),persistent:!1,onSuccess:()=>{this._selectedSubtitlesTrack=e;const i=Date.now()-s;n.withFields({duration:i}).log(`setSubtitleLanguage completed successfully after ${i} ms`),a=h(a),t()},onFailure:(e,t)=>{const r=Date.now()-s;n.withFields({duration:r}).log(`setSubtitleLanguage failed after ${r} ms. Error code: ${e}, error message: ${t}`),a=h(a),i(new Y(e,t))}});n.log(`window.cefQuery for setSubtitleLanguage returned query id ${o}`);const u=this._remotePlayerConfirmationTimeout+1e3;a=setTimeout((()=>{n.log(`setSubtitleLanguage reached timeout of ${u} ms, canceling query id ${o}`),window.cefQueryCancel(o),i(new Y(6e3,`setSubtitleLanguage reached timeout of ${u} ms`))}),u,o)}))}return d.error("remotePlayer _selectTextTrackV3: window.cefQuery is undefined"),Promise.resolve(void 0)}setTextTrackVisibility(e){const t=this._textTrackVisibility;if("boolean"!=typeof e&&0!==e&&1!==e)throw new TypeError("visible parameter must be a boolean or 0/1");const n=!!e;t!==n&&(this._textTrackVisibility=n,this._textTrackVisibility||(this._selectedSubtitlesTrack=""))}setBlackoutTime(e){if(!this._isInitialized)throw new Y(6500,"Cannot call setBlackoutTime() if remote player is not initialized");if(this._loadMode!==this.LoadMode.LOADED)throw new Y(6001,"Cannot call setBlackoutTime() if player is not loaded");if(!(e instanceof Date))throw new TypeError("blackoutTime must be a Date object");const t=(e.getTime()/1e3).toFixed(2);if(window.cefQuery){const e=s(),n=d.withFields({FCID:e});n.log("remotePlayer setBlackoutTime: sending screenBlackout action");const i={type:"remotePlayer.screenBlackout",class:"remotePlayer",action:"screenBlackout",fcid:e,blackoutTime:t},r={target:"TC",waitForResponse:!0,message:JSON.stringify(i)};return new Promise(((e,i)=>{let a=0;const s=Date.now(),o=window.cefQuery({request:JSON.stringify(r),persistent:!1,onSuccess:()=>{this._blackoutTime=t;const i=Date.now()-s;n.withFields({duration:i}).log(`setBlackoutTime completed successfully after ${i} ms`),a=h(a),e()},onFailure:(e,t)=>{const r=Date.now()-s;n.withFields({duration:r}).log(`setBlackoutTime failed after ${r} ms. Error code: ${e}, error message: ${t}`),a=h(a),i(new Y(e,t))}});n.log(`window.cefQuery for setBlackoutTime returned query id ${o}`);const u=this._remotePlayerConfirmationTimeout+1e3;a=setTimeout((()=>{n.log(`setBlackoutTime reached timeout of ${u} ms, canceling query id ${o}`),window.cefQueryCancel(o),i(new Y(6e3,`setBlackoutTime reached timeout of ${u} ms`))}),u,o)}))}return d.error("remotePlayer setBlackoutTime: window.cefQuery is undefined"),Promise.resolve(void 0)}resetBlackoutTime(){if(!this._isInitialized)throw new Y(6500,"Cannot call resetBlackoutTime() if remote player is not initialized");if(this._loadMode!==this.LoadMode.LOADED)throw new Y(6001,"Cannot call resetBlackoutTime() if player is not loaded");if(window.cefQuery){const e=s(),t=d.withFields({FCID:e});t.log("remotePlayer resetBlackoutTime: sending screenBlackout action");const n={type:"remotePlayer.screenBlackout",class:"remotePlayer",action:"screenBlackout",fcid:e,blackoutTime:0},i={target:"TC",waitForResponse:!0,message:JSON.stringify(n)};return new Promise(((e,n)=>{let r=0;const a=Date.now(),s=window.cefQuery({request:JSON.stringify(i),persistent:!1,onSuccess:()=>{this._blackoutTime=0;const n=Date.now()-a;t.withFields({duration:n}).log(`resetBlackoutTime completed successfully after ${n} ms`),r=h(r),e()},onFailure:(e,i)=>{const s=Date.now()-a;t.withFields({duration:s}).log(`resetBlackoutTime failed after ${s} ms. Error code: ${e}, error message: ${i}`),r=h(r),n(new Y(e,i))}});t.log(`window.cefQuery for resetBlackoutTime returned query id ${s}`);const o=this._remotePlayerConfirmationTimeout+1e3;r=setTimeout((()=>{t.log(`resetBlackoutTime reached timeout of ${o} ms, canceling query id ${s}`),window.cefQueryCancel(s),n(new Y(6e3,`resetBlackoutTime reached timeout of ${o} ms`))}),o,s)}))}return d.error("remotePlayer resetBlackoutTime: window.cefQuery is undefined"),Promise.resolve(void 0)}get currentTime(){return E()?.playbackPosition}set currentTime(e){this._videoElement?d.warn("RemotePlayer: currentTime is read-only when video element is attached. Use local player to seek."):(d.info("RemotePlayer not attached, setting currentTime to",e),this._remotePlayerApiVersion>=2?this._startSeeking(e):this._seek(e,!1))}get duration(){return E()?.assetDuration}get textTrackVisibility(){return this._textTrackVisibility}getPresentationStartTimeAsDate(){return void 0===this._availabilityStartTime?null:new Date(1e3*this._availabilityStartTime)}_localPlayerSeekingCb=()=>{this._startSeeking(this._videoElement.currentTime)};_localPlayerSeekedCb=()=>{this._isSeekingByPlatform&&(d.info("Seeked Callback: platform completed seeking"),this._isSeekingByPlatform=!1)};_updateSeekListeners(e){this._videoElement&&(this._videoElement.removeEventListener("seeking",this._localPlayerSeekingCb),this._videoElement.removeEventListener("seeked",this._localPlayerSeekedCb)),e&&(e.addEventListener("seeking",this._localPlayerSeekingCb),e.addEventListener("seeked",this._localPlayerSeekedCb))}async _startSeeking(e){if(!this._isSetAudioInProgress&&!this._isSetSubtitlesInProgress)return!this._isSeekingByPlatform&&(this._pendingSeekPosition=e,0===this._localPlayerLoadCurrentTime&&this._videoElement.currentTime-this._localPlayerLoadCurrentTime>86400)?(d.info(`Seeking ignored for video currentTime init: currentTime: ${this._videoElement.currentTime}, loadCurrentTime: ${this._localPlayerLoadCurrentTime}`),void(this._localPlayerLoadCurrentTime=this._videoElement.currentTime)):void(!(this._remotePlayerApiVersion>=2)||this._isSeekingByPlatform||this._isSeekingByApplication||O.state!==O.UiState.FOREGROUND&&O.state!==O.UiState.IN_TRANSITION_TO_FOREGROUND?d.info(`Seeking: skipping seeking event to currentTime: ${e}, internalSeek: ${this._isSeekingByPlatform}, localPlayerSeek: ${this._isSeekingByApplication}, state: ${O.state}`):this._atomicSeek());d.info("Seeking not supported while setAudioLanguage or setSubtitleLanguage are in progress.")}async _atomicSeek(){d.info("Seeking: local video element seeking start while isPlaying: ",this._isPlaying),this._targetSeekPlayingState=this._isPlaying?_.PLAYING_UI:_.PAUSED,this._videoElement&&(this._videoElement.playbackRate=1,this._ptsSessionId++),this._isSeekingByApplication=!0,this._abortSeeking=!1;let e=this._pendingSeekPosition,t=this._pendingSeekPosition;const n=Date.now();let i=y.INIT;for(;!this._abortSeeking&&i!==y.DONE;)try{switch(i){case y.INIT:i=this._isPlaying?y.PAUSED:y.FIRST_SEEK;break;case y.PAUSED:await this._pause(),i=y.FIRST_SEEK;break;case y.FIRST_SEEK:t=e=this._pendingSeekPosition,await this._seek(t,!0),i=y.FIRST_WAITING;break;case y.FIRST_WAITING:await c(Math.max(this._multiSeekDelay-(Date.now()-n),0)),i=e===this._pendingSeekPosition?y.DONE:y.WAITING;break;case y.WAITING:e=this._pendingSeekPosition,await c(this._multiSeekDelay),i=e===this._pendingSeekPosition?y.MULTI_SEEK:y.WAITING;break;case y.MULTI_SEEK:e=this._pendingSeekPosition,await this._seek(e,!0),i=e===this._pendingSeekPosition?y.DONE:y.WAITING}}catch(e){d.error(`Error during seeking process: ${e.message}`),i=y.DONE}if(!this._abortSeeking)if(this._targetSeekPlayingState===_.PLAYING_UI){if(!this._isAudioSyncEnabled())return Promise.resolve(!0);this._play(p.AUDIO)}else this._targetSeekPlayingState===_.PLAYING_ABR&&O._moveToBackground();this._isSeekingByApplication=!1,d.info("Seeking: local video element seeking end")}async _atomicSetAudioLanguage(e,t){if(this._isSetAudioInProgress)return d.warn(`remotePlayer _atomicSetAudioLanguage: audioTrackId=${e} already in progress, ignoring.`),Promise.resolve();if(this._isSeekingByApplication)return d.warn(`remotePlayer _atomicSetAudioLanguage: audioTrackId=${e} ignored. seeking is already in progress.`),Promise.resolve();let n;this._targetSetAudioPlayingState=this._isPlaying?_.PLAYING_UI:_.PAUSED,d.log(`remotePlayer _atomicSetAudioLanguage: prevAudioTrack=${t} audioTrackId=${e} isPlaying=${this._isPlaying} targetState=${this._targetSetAudioPlayingState}`),this._abortSetAudioLanguage=!1,this._isSetAudioInProgress=!0;try{await this._stop(p.AUDIO)}catch(t){d.warn(`remotePlayer _atomicSetAudioLanguage: audioTrackId=${e} failed on stop with error ${t.message}.`)}if(this._abortSetAudioLanguage)return this._isSetAudioInProgress=!1,d.warn(`remotePlayer _atomicSetAudioLanguage: audioTrackId=${e} aborted right after stop.`),Promise.resolve();try{await this._selectAudioTrackV3(e)}catch(t){d.error(`remotePlayer _atomicSetAudioLanguage: audioTrackId=${e} _selectAudioTrackV3 failed with error ${t.message}.`),this._abortSetAudioLanguage||(n=t)}if(this._abortSetAudioLanguage)return this._isSetAudioInProgress=!1,d.warn(`remotePlayer _atomicSetAudioLanguage: audioTrackId=${e} aborted right after _selectAudioTrackV3.`),Promise.resolve();try{if(this._targetSetAudioPlayingState===_.PLAYING_UI){if(!this._isAudioSyncEnabled())return this._isSetAudioInProgress=!1,Promise.resolve(!0);await this._play(p.AUDIO)}else this._targetSetAudioPlayingState===_.PLAYING_ABR&&await O._moveToBackground()}catch(t){d.error(`remotePlayer _atomicSetAudioLanguage: audioTrackId=${e} play failed with error ${t.message}.`)}return this._isSetAudioInProgress=!1,d.log(`remotePlayer _atomicSetAudioLanguage: audioTrackId=${e} ended.`),n?Promise.reject(n):Promise.resolve()}async _atomicSetSubtitleLanguage(e,t){if(this._isSetSubtitlesInProgress)return d.warn(`remotePlayer _atomicSetSubtitleLanguage: textTrackId=${e} already in progress, ignoring.`),Promise.resolve();if(this._isSeekingByApplication)return d.warn(`remotePlayer _atomicSetSubtitleLanguage: textTrackId=${e} ignored. seeking is already in progress.`),Promise.resolve();let n;this._targetSetSubtitlePlayingState=this._isPlaying?_.PLAYING_UI:_.PAUSED,d.log(`remotePlayer _atomicSetSubtitleLanguage: prevTextTrack=${t} textTrackId=${e} isPlaying=${this._isPlaying} targetState=${this._targetSetSubtitlePlayingState}`),this._abortSetSubtitleLanguage=!1,this._isSetSubtitlesInProgress=!0;try{await this._stop(p.SUBTITLE)}catch(t){d.warn(`remotePlayer _atomicSetSubtitleLanguage: textTrackId=${e} stop failed with error ${t.message}.`)}if(this._abortSetSubtitleLanguage)return this._isSetSubtitlesInProgress=!1,d.warn(`remotePlayer _atomicSetSubtitleLanguage: textTrackId=${e} aborted right after stop.`),Promise.resolve();try{await this._selectTextTrackV3(e)}catch(t){d.error(`remotePlayer _atomicSetSubtitleLanguage: textTrackId=${e} _selectTextTrackV3 failed with error ${t.message}.`),this._abortSetSubtitleLanguage||(n=t)}if(this._abortSetSubtitleLanguage)return this._isSetSubtitlesInProgress=!1,d.warn(`remotePlayer _atomicSetSubtitleLanguage: textTrackId=${e} aborted right after _selectTextTrackV3.`),Promise.resolve();try{if(this._targetSetSubtitlePlayingState===_.PLAYING_UI){if(!this._isAudioSyncEnabled())return this._isSetSubtitlesInProgress=!1,Promise.resolve(!0);await this._play(p.AUDIO)}else this._targetSetSubtitlePlayingState===_.PLAYING_ABR&&await O._moveToBackground()}catch(t){d.error(`remotePlayer _atomicSetSubtitleLanguage: textTrackId=${e} play failed with error ${t.message}.`)}return this._isSetSubtitlesInProgress=!1,d.log(`remotePlayer _atomicSetSubtitleLanguage: textTrackId=${e} ended.`),n?Promise.reject(n):Promise.resolve()}}const C=new P;class j extends EventTarget{ConnectReason=Object.freeze({UNKNOWN:"unknown",INITIAL_CONNECTION:"initial_connection",APPLICATION_RELOAD:"reload_app",UI_RELEASE:"ui_release",UI_TERMINATION:"ui_termination",WEBRTC_ERROR:"webrtc_error",UI_WATCHDOG:"ui_watchdog"});UiState=Object.freeze({UNKNOWN:"unknown",FOREGROUND:"foreground",IN_TRANSITION_TO_FOREGROUND:"inTransitionToForeground",BACKGROUND:"background",IN_TRANSITION_TO_BACKGROUND:"inTransitionToBackground"});constructor(){super(),this._isInitialized=!1,this._inTransition=!1,this._eventManager=new x({timeoutMs:1e4}),this._autoBackground=!1,this._autoBackgroundOnVideoDelay=30,this._autoBackgroundOnUIDelay=-1,"undefined"!=typeof document&&document.addEventListener("hs/uistatechange",(e=>{d.log("Got hs/uistatechange",e.detail);const t=new Event("onstatechange");t.state=e.detail,this._state=t.state,this._isAutoBackgroundEnabled()&&this.state===this.UiState.FOREGROUND&&this._startCountdown(),this.dispatchEvent(t)})),"undefined"!=typeof document&&document.addEventListener("hs/systemInactivity",(e=>{d.log("Got hs/systemInactivity",e.detail);const t=new Event("userinactivity");t.timeout=e.detail.timeout,this.dispatchEvent(t)})),"undefined"!=typeof document&&document.addEventListener("hs/endOfSession",(async()=>{const e=new Event("userdisconnected");await this._eventManager.dispatch("userdisconnected",e),this._sendTerminatingMessage()})),"undefined"!=typeof document&&document.addEventListener("keydown",(()=>{this._isAutoBackgroundEnabled()&&(this.state===this.UiState.BACKGROUND||this.state===this.UiState.IN_TRANSITION_TO_BACKGROUND?this.moveToForeground():this._startCountdown())})),C.addEventListener("playModeChange",(e=>{this._isAutoBackgroundEnabled()&&this.state===this.UiState.FOREGROUND&&(d.log("Resetting auto background timer due to play mode change",e.detail.isPlaying),this._startCountdown(e.detail.isPlaying))}))}async _init(e,t){window.cefQuery&&(this._state=await new Promise((e=>{window.cefQuery({request:"uiState",persistent:!1,onSuccess:t=>{d.log(`uiState request successfully returned '${t}'`),e(t)},onFailure:(t,n)=>{d.error(`uiState request failed: ${t} ${n}`),e(this.UiState.UNKNOWN)}})})),this._connectReason=await new Promise((e=>{const t=s(),n=d.withFields({FCID:t}),i={type:"connectReason",fcid:t},r={target:"UI-Streamer",waitForResponse:!1,message:JSON.stringify(i)};window.cefQuery({request:JSON.stringify(r),persistent:!1,onSuccess:t=>{n.log(`connectReason request successfully returned '${t}'`),e(t)},onFailure:(t,i)=>{n.error(`connectReason request failed: ${t} ${i}`),e(this.ConnectReason.UNKNOWN)}})})),this._triggerEvent={},t.type&&(this._triggerEvent.type=t.type,d.info(`Got trigger event of type ${this._triggerEvent.type}`),"keyPressEvent"===t.type?this._triggerEvent.data={keyValue:t.keyValue}:"alarmFiredEvent"===t.type?this._triggerEvent.data={alarmName:t.alarmName,payload:t.payload}:"userAlertEvent"===t.type?this._triggerEvent.data={eventCode:t.eventCode,message:t.message}:"externalEvent"===t.type?this._triggerEvent.data={eventName:t.eventName,payload:t.payload}:"videoPlaybackEvent"===t.type?this._triggerEvent.data={eventCode:t.eventCode,errorCode:t.errorCode}:"getLicense"===t.type&&d.info("The license request is available on the license-request event which is triggered after uiReady is called")),t.fcid&&(this._triggerEventFcid=t.fcid),this._isInitialized=!0,this._remotePlayerConfirmationTimeout=e?.remotePlayerConfirmationTimeout??5e3,this._remotePlayerApiVersion=e?.remotePlayerApiVersion||1,e?.autoBackground&&(e.autoBackground.overrides&&(this._autoBackgroundOverrides=e.autoBackground.overrides,d.warn(`Using overrides for autoBackground settings: ${JSON.stringify(this._autoBackgroundOverrides)}`)),this.configure({autoBackground:e.autoBackground})))}_isAutoBackgroundEnabled(){return this._autoBackgroundOverrides?.enabled??this._autoBackground}_getAutoBackgroundOnVideoDelay(){const e=this._autoBackgroundOverrides?.timeout?.playing;return void 0!==e?!1===e?-1:e:this._autoBackgroundOnVideoDelay}_getAutoBackgroundOnUIDelay(){const e=this._autoBackgroundOverrides?.timeout?.idle;return void 0!==e?!1===e?-1:e:this._autoBackgroundOnUIDelay}configure(e){if(e?.autoBackground){const{enabled:t,timeout:n}=e.autoBackground;"boolean"==typeof t&&(this._autoBackground=t),n&&(void 0!==n.playing&&(!1===n.playing?this._autoBackgroundOnVideoDelay=-1:"number"==typeof n.playing?this._autoBackgroundOnVideoDelay=n.playing:d.warn("Invalid autoBackground.timeout.playing value, expected number or false")),void 0!==n.idle&&(!1===n.idle?this._autoBackgroundOnUIDelay=-1:"number"==typeof n.idle?this._autoBackgroundOnUIDelay=n.idle:d.warn("Invalid autoBackground.timeout.idle value, expected number or false"))),this._isAutoBackgroundEnabled()?this._startCountdown():this._stopCountdown()}}getConfiguration(){return{autoBackground:{enabled:this._autoBackground,timeout:{playing:!(this._autoBackgroundOnVideoDelay<=0)&&this._autoBackgroundOnVideoDelay,idle:!(this._autoBackgroundOnUIDelay<=0)&&this._autoBackgroundOnUIDelay}}}}_moveToUiStandby(){return window.cefQuery?(this._inTransition=!0,new Promise(((e,t)=>{const n=s(),i={target:"TC",waitForResponse:!1,internalAction:"uiExit",message:JSON.stringify({type:"uiStandbyRequest",fcid:n})},r=d.withFields({FCID:n});r.log("lifecycle moveToUiStandby: sending uiStandbyRequest"),window.cefQuery({request:JSON.stringify(i),persistent:!1,onSuccess:()=>{r.log("[ moveToUiStandby ] moveToUiStandby successfully sent"),this._inTransition=!1,e(!0)},onFailure:(e,n)=>{r.error(`[ moveToUiStandby ] moveToUiStandby failed: ${e} ${n}`),this._inTransition=!1,t(`moveToUiStandby failed: ${e} ${n}`)}})}))):(d.warn("moveToUiStandby was called in local dev"),Promise.resolve(!0))}get state(){return this._isInitialized||(this._state=this.UiState.UNKNOWN),this._state}get connectReason(){return this._isInitialized||(this._connectReason=this.ConnectReason.UNKNOWN),this._connectReason}get triggerEvent(){return this._isInitialized||(this._triggerEvent={}),this._triggerEvent}set autoBackground(e){this._autoBackground=e,this._isAutoBackgroundEnabled()?this._startCountdown():this._stopCountdown()}get autoBackground(){return this._autoBackground}set autoBackgroundDelay(e){this._autoBackgroundOnVideoDelay=e,this._isAutoBackgroundEnabled()&&C._isPlaying&&this._startCountdown()}get autoBackgroundDelay(){return this._autoBackgroundOnVideoDelay}set autoBackgroundOnUIDelay(e){this._autoBackgroundOnUIDelay=e,this._isAutoBackgroundEnabled()&&!C._isPlaying&&this._startCountdown()}get autoBackgroundOnUIDelay(){return this._autoBackgroundOnUIDelay}_startCountdown(e=C._isPlaying){this._stopCountdown();const t=e?this._getAutoBackgroundOnVideoDelay():this._getAutoBackgroundOnUIDelay();t>0?(d.debug("Starting countdown timeout",t,e?"(video)":"(UI)"),this._countdown=setTimeout((()=>{d.debug("Countdown timeout reached, moving to background"),this.moveToBackground()}),1e3*t)):d.debug("Countdown not started - delay is negative or zero")}_stopCountdown(){this._countdown&&(d.debug("Stopping countdown timer"),clearTimeout(this._countdown)),this._countdown=null}getState(){if(window.cefQuery)return new Promise(((e,t)=>{window.cefQuery({request:"uiState",persistent:!1,onSuccess:t=>{d.log(`uiState request successfully returned '${t}'`),e(t)},onFailure:(e,n)=>{d.error(`uiState request failed: ${e} ${n}`),t(n)}})}));d.warn("lifecycle getState is not supported if NOT running e2e")}moveToForeground(){if(window.cefQuery){if(this._inTransition||this._state===this.UiState.FOREGROUND||this._state===this.UiState.IN_TRANSITION_TO_FOREGROUND)return d.warn(`lifecycle moveToForeground: No need to transition to foreground, state: ${this._state} transition: ${this._inTransition}`),Promise.resolve(!1);this._inTransition=!0,N._moveToForegroundCalled();const e=s();return this._remotePlayerApiVersion>=2?new Promise(((e,t)=>{const n=s(),i=d.withFields({FCID:n});i.log(`lifecycle moveToForeground: sending stop action remotePlayer._isPlaying=${C._isPlaying}`);const r={type:"remotePlayer.stop",class:"remotePlayer",action:"stop",streamType:C._isAudioSyncEnabled()?p.VIDEO|p.SUBTITLE:p.AUDIO|p.VIDEO|p.SUBTITLE,fcid:n};let a=0;const u=Date.now(),l=window.cefQuery({request:JSON.stringify({target:"TC",waitForResponse:!0,internalAction:"uiActive",message:JSON.stringify(r)}),persistent:!1,onSuccess:()=>{const t=Date.now()-u;i.withFields({duration:t}).log(`stop completed successfully after ${t} ms`),this._inTransition=!1,a=h(a),e(!0)},onFailure:(e,n)=>{const r=Date.now()-u;i.withFields({duration:r}).log(`stop failed after ${r} ms. Error code: ${e}, error message: ${n}`),this._inTransition=!1,a=h(a),t(new o(e,n))}});i.log(`window.cefQuery for stop returned query id ${l}`);const c=this._remotePlayerConfirmationTimeout+1e3;a=setTimeout((()=>{i.log(`stop reached timeout of ${c} ms, canceling query id ${l}`),this._inTransition=!1,window.cefQueryCancel(l),t(new o(6e3,`stop reached timeout of ${c} ms`))}),c,l)})):new Promise(((t,n)=>{const i=d.withFields({FCID:e});i.log(`lifecycle moveToForeground: sending uiActiveRequest action remotePlayer._isPlaying=${C._isPlaying}`),window.cefQuery({request:JSON.stringify({action:"uiActiveRequest",fcid:e}),persistent:!1,onSuccess:()=>{i.log("uiActiveRequest successfully sent"),this._inTransition=!1,t(!0)},onFailure:(e,t)=>{this._inTransition=!1,i.error(`uiActiveRequest failed: ${e} ${t}`),n(`uiActiveRequest failed: ${e} ${t}`)}})}))}return d.warn("lifecycle moveToForeground: window.cefQuery is undefined"),Promise.resolve(!1)}_moveToBackground(){return window.cefQuery?this._inTransition||this._state===this.UiState.BACKGROUND||this._state===this.UiState.IN_TRANSITION_TO_BACKGROUND?(d.warn(`lifecycle moveToBackground: No need to transition to background, state: ${this._state} transition: ${this._inTransition}`),Promise.resolve(!1)):(m()||C._syncRemotePlayerWithLocalPlayer(),N._moveToBackgroundCalled(),C._isPlaying?(this._inTransition=!0,new Promise(((e,t)=>{const n=s(),i=d.withFields({FCID:n}),r=C.getConfiguration();let a;const u={action:"play",fcid:n,audioLanguage:C._selectedAudioTrack||r.preferredAudioLanguage||"",subtitlesLanguage:C._selectedSubtitlesTrack||r.preferredSubtitlesLanguage||""};this._remotePlayerApiVersion>=2?(u.type="remotePlayer.play",u.class="remotePlayer",u.switchMode=C._isAudioSyncEnabled()?g.SEAMLESS:g.NON_SEAMLESS,u.streamType=C.textTrackVisibility?p.AUDIO|p.VIDEO|p.SUBTITLE:p.AUDIO|p.VIDEO,a={target:"TC",waitForResponse:!0,internalAction:"uiExit",message:JSON.stringify(u)}):(C.textTrackVisibility||(u.subtitlesLanguage=""),a=u),i.log(`lifecycle moveToBackground: sending play action audioLanguage=${u.audioLanguage} subtitlesLanguage=${u.subtitlesLanguage} textTrackVisibility=${C.textTrackVisibility}`);let l=0;const c=Date.now(),m=window.cefQuery({request:JSON.stringify(a),persistent:!1,onSuccess:()=>{const t=Date.now()-c;i.withFields({duration:t}).log(`play completed successfully after ${t} ms`),this._inTransition=!1,l=h(l),e()},onFailure:(e,n)=>{const r=Date.now()-c;i.withFields({duration:r}).log(`play failed after ${r} ms. Error code: ${e}, error message: ${n}`),this._inTransition=!1,l=h(l),t(new o(e,n))}});if(this._remotePlayerApiVersion>=2){i.log(`window.cefQuery for play returned query id ${m}`);const e=this._remotePlayerConfirmationTimeout+1e3;l=setTimeout((()=>{i.log(`play reached timeout of ${e} ms, canceling query id ${m}`),this._inTransition=!1,window.cefQueryCancel(m),t(new o(6e3,`play reached timeout of ${e} ms`))}),e,m)}}))):this._moveToUiStandby()):(d.warn("lifecycle moveToBackground: window.cefQuery is undefined"),Promise.resolve(!1))}moveToBackground(){if(window.cefQuery){if(this._inTransition||this._state===this.UiState.BACKGROUND||this._state===this.UiState.IN_TRANSITION_TO_BACKGROUND)return d.warn(`lifecycle moveToBackground: No need to transition to background, state: ${this._state} transition: ${this._inTransition}`),Promise.resolve(!1);if(C._isSeekingByApplication)return C._targetSeekPlayingState=_.PLAYING_ABR,Promise.resolve(!0);if(C._isSetSubtitlesInProgress)return C._targetSetSubtitlePlayingState=_.PLAYING_ABR,Promise.resolve(!0);if(C._isSetAudioInProgress)return C._targetSetAudioPlayingState=_.PLAYING_ABR,Promise.resolve(!0)}return this._moveToBackground()}switchTenant(e){if(e&&e.length>0){if(e===fe().sessionInfo?.tenantId)return d.warn(`SwitchTenant requires a different tenantId than the current one. CurrentTenantId=${fe().sessionInfo?.tenantId} and tenantId=${e}`),Promise.reject("SwitchTenant requires a different tenantId than the current one");C._blackoutTime=0;const t=fe().sessionInfo?.homeSessionInfo?.tenantInfo?.contentHubTenantId,n=fe().sessionInfo?.homeSessionInfo?.tenantId;return d.log(`SwitchTenant for ${e}`),window.cefQuery?new Promise(((i,r)=>{const a=s(),o=d.withFields({FCID:a}),u={type:"reconnect",fcid:a,session:btoa(JSON.stringify({tenantId:e,...fe().sessionInfo?.tenantId===t&&e!==n&&{returnToTenantId:t}}))},l={target:"TC",waitForResponse:!1,message:JSON.stringify(u)};window.cefQuery({request:JSON.stringify(l),persistent:!1,onSuccess:()=>{o.log("SwitchTenant request successfully sent"),i(!0)},onFailure:(e,t)=>{o.error(`SwitchTenant failed: ${e} ${t}`),r(`SwitchTenant failed: ${e} ${t}`)}})})):(d.warn("SwitchTenant is not supported if NOT running e2e"),Promise.reject("SwitchTenant is not supported if NOT running e2e"))}return d.warn("SwitchTenant requires a valid tenantId string parameter"),Promise.reject("SwitchTenant requires a valid tenantId string parameter")}exitApplication(){return window.cefQuery?new Promise(((e,t)=>{const n=s(),i=d.withFields({FCID:n});let a,o;const u=r.sessionInfoObj;u?.homeSessionInfo&&(u?.returnToTenantId||u?.homeSessionInfo.tenantId!==u?.tenantId)?(o={type:"reconnect",splashUrl:u?.homeSessionInfo.tenantInfo.tenantSettings.applicationSwitchSplashUrl,fcid:n},u?.returnToTenantId&&(u?.returnToTenantId===u?.homeSessionInfo.tenantInfo.contentHubTenantId&&(o.splashUrl=u?.homeSessionInfo.contentHubTenantInfo.tenantSettings.applicationSwitchSplashUrl),o.session=btoa(JSON.stringify({tenantId:u?.returnToTenantId}))),a={target:"TC",waitForResponse:!1,message:JSON.stringify(o)}):(o={type:"launchHomeApplication",fcid:n},a={target:"UI-Streamer",waitForResponse:!1,message:JSON.stringify(o)}),window.cefQuery({request:JSON.stringify(a),persistent:!1,onSuccess:()=>{i.log(`exitApplication request with type: '${o.type}' successfully sent`),e(!0)},onFailure:(e,n)=>{i.error(`exitApplication request with type: '${o.type}' failed: ${e} ${n}`),t(`exitApplication request with type: '${o.type}' failed: ${e} ${n}`)}})})):(d.warn("exitApplication is not supported if NOT running e2e"),Promise.reject("exitApplication is not supported if NOT running e2e"))}addEventListener(e,t,n){"userdisconnected"===e?this._eventManager.addEventListener(e,t):super.addEventListener(e,t,n)}removeEventListener(e,t,n){"userdisconnected"===e?this._eventManager.removeEventListener(e,t):super.removeEventListener(e,t,n)}_sendTerminatingMessage(){if(window.cefQuery){const e={type:"terminating",fcid:s()},t={target:"TC",waitForResponse:!1,message:JSON.stringify(e)};window.cefQuery({request:JSON.stringify(t),persistent:!1,onSuccess:()=>{d.log("Terminating signal sent after userdisconnected event was processed")},onFailure:(e,t)=>{d.error(`Failed to send terminating signal: ${e} ${t}`)}})}}}const O=new j;class R extends EventTarget{constructor(){super(),this._eventManager=new x({timeoutMs:15e3}),"undefined"!=typeof document&&document.addEventListener("hs/alarmFiredEvent",(async e=>{if(e.detail?.alarmName){const t=d.withFields({alarmName:e.detail?.alarmName});t.log("Got hs/alarmFiredEvent",JSON.stringify(e.detail));const n=Date.now();let i;i=O.state===O.UiState.FOREGROUND||O.state===O.UiState.IN_TRANSITION_TO_FOREGROUND?"foreground":"background",this._targetState=i;const r=new CustomEvent(e.detail.alarmName,{detail:e.detail.payload});await this._eventManager.dispatch(e.detail.alarmName,r);const a=Date.now()-n;t.log(`All callbacks for alarm '${e.detail.alarmName}' are finished within ${a}ms`);const s="alarmFiredEvent"===O.triggerEvent.type&&O._triggerEventFcid&&O._triggerEventFcid===e.detail.fcid;if(s&&!this._moveToForegroundHasBeenCalled&&window.cefQuery){t.log("Application is about to be terminated since didn't move to foreground");const e={type:"terminating"},n={target:"TC",waitForResponse:!1,message:JSON.stringify(e)};window.cefQuery({request:JSON.stringify(n),persistent:!1,onSuccess:()=>{t.log("terminating request successfully sent")},onFailure:(e,n)=>{t.error(`terminating request failed: ${e} ${n}`)}})}t.metrics({type:"monitorAlarm",alarmName:e.detail.alarmName,isTriggering:s,sourceState:i,targetState:this._targetState,alarmHandlingDuration:a})}}))}_setDefaultTimeout(e){"number"==typeof e&&e>0?(this._eventManager.timeoutMs=e,d.log(`Alarm event listener timeout set to ${e}ms`)):d.warn(`Invalid timeout value: ${e}. Must be a positive number.`)}addEventListener(e,t){this._eventManager.addEventListener(e,t)}removeEventListener(e,t){this._eventManager.removeEventListener(e,t)}_moveToForegroundCalled(){this._moveToForegroundHasBeenCalled=!0,this._targetState="foreground"}_moveToBackgroundCalled(){this._targetState="background"}addAlarm(e,t,n="",i=0,r=0){if("string"!=typeof n)throw Error("data must be a string");const a=s(),o=d.withFields({alarmName:e,FCID:a});if(o.log(`addAlarm called for ${e} to be fired at ${t} with tolerance of ${i} minutes before and ${r} minutes after`),window.cefQuery){const s={type:"addAlarm",fcid:a,alarmName:e,alarmTime:t,toleranceBefore:Math.trunc(60*i*1e3),toleranceAfter:Math.trunc(60*r*1e3),payload:n},u={target:"TC",waitForResponse:!1,message:JSON.stringify(s)};window.cefQuery({request:JSON.stringify(u),persistent:!1,onSuccess:()=>{o.log("addAlarm request successfully sent")},onFailure:(e,t)=>{o.error(`addAlarm failed: ${e} ${t}`)}})}else o.warn("addAlarm is not supported if NOT running e2e")}deleteAlarm(e){const t=s(),n=d.withFields({alarmName:e,FCID:t});if(n.log(`deleteAlarm called for ${e}`),window.cefQuery){const i={type:"deleteAlarm",fcid:t,alarmName:e},r={target:"TC",waitForResponse:!1,message:JSON.stringify(i)};window.cefQuery({request:JSON.stringify(r),persistent:!1,onSuccess:()=>{n.log("deleteAlarm request successfully sent")},onFailure:(e,t)=>{n.error(`deleteAlarm failed: ${e} ${t}`)}})}else n.warn("deleteAlarm is not supported if NOT running e2e")}deleteAllAlarms(){if(window.cefQuery){const e=s(),t=d.withFields({FCID:e}),n={type:"deleteAllAlarms",fcid:e},i={target:"TC",waitForResponse:!1,message:JSON.stringify(n)};window.cefQuery({request:JSON.stringify(i),persistent:!1,onSuccess:()=>{t.log("deleteAllAlarms request successfully sent")},onFailure:(e,n)=>{t.error(`deleteAllAlarms failed: ${e} ${n}`)}})}else d.warn("deleteAllAlarms is not supported if NOT running e2e")}getActiveAlarms(){throw Error("NOT IMPLEMENTED")}}const N=new R,H={};let U,F,B=0;async function W(){if(!U)try{const e=await l("wifi-ap-data");U=JSON.parse(e)}catch(e){d.error(e)}}async function z(){if(B+5e3<Date.now())try{const e=await l("wifi-status");F=JSON.parse(e),B=Date.now()}catch(e){d.error(e)}}class V extends EventTarget{constructor(){super(),H.level=0,H.quality=0,H.ssid="unknown",H.bssid="unknown","undefined"!=typeof document&&document.addEventListener("wifiSignalReport",(e=>{H.level=e.detail.level,H.quality=e.detail.quality,H.ssid=e.detail.ssid,H.bssid=e.detail.bssid,this.dispatchEvent(new Event("wifiInfoUpdated"))}))}get deviceInfo(){const e=r.sessionInfoObj;return ge()&&e?{deviceId:e.deviceId,modelNumber:e.modelNumber,connectionId:e.connectionId,community:e.community,tenant:e.tenant,clientIp:e?.settings?.["ui-streamer"]?.clientIpOverride||e.clientIp,countryCode:e.general?.location?.["x-country-code"],connectionType:e.connectionType&&"direct"!==e.connectionType?e.connectionType:"device"}:(d.log("getDeviceInfo running locally, returning dummy info"),{deviceId:"123456789",modelNumber:"ABC",connectionId:"dummy",community:"LocalDev",tenant:"XXXXXX",clientIp:"0.0.0.0",countryCode:"XX",connectionType:"simulator"})}get wifiInfo(){return H}reboot(){return new Promise(((e,t)=>{if(window.cefQuery){const n=s(),i=d.withFields({FCID:n}),r={type:"reboot",fcid:n},a={target:"TC",waitForResponse:!1,message:JSON.stringify(r)};window.cefQuery({request:JSON.stringify(a),persistent:!1,onSuccess:()=>{i.log("reboot request successfully sent"),e(!0)},onFailure:(e,n)=>{i.error(`reboot failed: ${e} ${n}`),t(`reboot failed: ${e} ${n}`)}})}else d.warn("reboot is not supported if NOT running e2e"),t("reboot is not supported if NOT running e2e")}))}clearWifi(){return new Promise(((e,t)=>{const n=s(),i=d.withFields({FCID:n}),r={type:"resetWifi",fcid:n},a={target:"TC",waitForResponse:!1,message:JSON.stringify(r)};window.cefQuery({request:JSON.stringify(a),persistent:!1,onSuccess:()=>{i.log("clearWifi successfully sent"),e(!0)},onFailure:(e,n)=>{i.error(`clearWifi failed: ${e} ${n}`),t(`clearWifi failed: ${e} ${n}`)}})}))}sendDataToDevice(e){if("string"!=typeof e)throw new Error("data must be of type 'string'");return new Promise(((t,n)=>{const i=s(),r=d.withFields({FCID:i}),a={type:"externalCommand",data:{command:"forward",payload:e},fcid:i},o={target:"TC",waitForResponse:!1,message:JSON.stringify(a)};window.cefQuery({request:JSON.stringify(o),persistent:!1,onSuccess:()=>{r.log("externalCommand successfully sent"),t()},onFailure:(e,t)=>{r.error(`externalCommand failed: ${e} ${t}`),n(`externalCommand failed: ${e} ${t}`)}})}))}async factoryReset(e=!0){if("boolean"!=typeof e)throw new Error("reboot param must be of type 'boolean'");return new Promise(((t,n)=>{const i=s(),r=d.withFields({FCID:i}),a={type:"factoryReset",fcid:i,reboot:e},o={target:"TC",waitForResponse:!0,message:JSON.stringify(a)};let u=0;const l=window.cefQuery({request:JSON.stringify(o),persistent:!1,onSuccess:()=>{u&&clearTimeout(u),r.log("factoryReset successfully sent"),t(!0)},onFailure:(e,t)=>{u&&clearTimeout(u),r.error(`factoryReset failed: ${e} ${t}`),n(`factoryReset failed: ${e} ${t}`)}});u=setTimeout((()=>{r.error("factoryReset failed: reached timeout of 5000 ms"),window.cefQueryCancel(l),n("factoryReset failed: reached timeout of 5000 ms")}),5e3)}))}async getWifiInfo(){return await Promise.all([W(),z()]),{...U,...F}}}const G=new V;class q extends EventTarget{constructor(){super()}get appConfig(){const e=r.sessionInfoObj,t=e.homeSessionInfo?.appConfig||{};return d.info("PlatformManager get appConfig: \n"+JSON.stringify(t,null,2)),t}setTimezone(e){if(window.cefQuery){const t={message:JSON.stringify({type:"setTimeZone",timezone:e}),waitForResponse:!1,target:"UI-Streamer"};window.cefQuery({request:JSON.stringify(t),persistent:!1,onSuccess:()=>{d.log("PlatformManager timezome is successfully set to",e)},onFailure:(t,n)=>{d.error(`PlatformManager error occurred setting timezone to ${e}: ${t} ${n}`)}})}}}const $=new q;class K extends EventTarget{constructor(){super(),"undefined"!=typeof document&&document.addEventListener("hs/externalEvent",(e=>{d.log("Got hs/externalEvent",JSON.stringify(e.detail)),this.dispatchEvent(new CustomEvent("message",{detail:{eventName:e.detail.eventName,payload:e.detail.payload,fcid:e.detail.fcid}}))}))}async registerGroups(e){return d.log(`register called for ${e}`),new Promise(((t,n)=>{if(window.cefQuery){const i=s(),r=d.withFields({FCID:i}),a={type:"registerGroupEvent",fcid:i,groups:e},o={target:"UI-Streamer",waitForResponse:!1,message:JSON.stringify(a)};window.cefQuery({request:JSON.stringify(o),persistent:!1,onSuccess:()=>{r.log("registerGroupEvent request successfully sent"),t(!0)},onFailure:(e,t)=>{r.error(`registerGroupEvent failed: ${e} ${t}`),n(`registerGroupEvent failed: ${e} ${t}`)}})}else d.warn("registerGroupEvent is not supported if NOT running e2e"),n("registerGroupEvent is not supported if NOT running e2e")}))}}const J=new K;var X=n(3159),Q=n(5093),Z=n.n(Q);X.util.Error.Category.SENZA_PLAYER_ERROR=50,X.util.Error.Code.SENZA_PLAYER_ERROR=10500;const ee=[1100,1101,1102,3401,3402];class te extends X.util.Error{remotePlayerErrorCode=null;constructor(e,t,n,i,r){super(e,t,n,i),this.remotePlayerErrorCode=r,i&&(this.message=i)}}const ne={...X};class ie extends X.Player{static _prevInstance=null;_audioTracksMap={};_textTracksMap={};_playingTimeout=4e3;_playStartTime=null;_shouldStopOnRemotePlayerError=!1;_originalPlay=null;_playPromiseResolve=null;_playPromiseReject=null;_playTimeoutId=null;_videoEventListeners={play:()=>{0===this._playingTimeout&&this.remotePlayer.play().catch((e=>{d.error("Failed to play remote player:",e),this.handleSenzaError(e.code,e.message||"Unknown play error")}))},pause:()=>{this._resetPlayPromise(),this.remotePlayer.pause().catch((e=>{d.error("Failed to pause remote player:",e),this.handleSenzaError(e.code,e.message||"Unknown pause error")})),O.moveToForeground()}};_remotePlayerEventListeners={ended:()=>{d.log("remotePlayer ended"),O.moveToForeground(),this.videoElement&&this.videoElement.dispatchEvent(new Event("ended"))},error:e=>{d.log("remotePlayer error:",e.detail.errorCode,e.detail.message),O.moveToForeground(),this.handleSenzaError(e.detail.errorCode,e.detail.message)},"license-request":async e=>{d.log("remotePlayer","license-request","Got license-request event from remote player");const t=e?.detail?.licenseRequest,n=String.fromCharCode.apply(null,new Uint8Array(t)),i=window.atob(n),r={body:Uint8Array.from(i,(e=>e.charCodeAt(0))).buffer,uris:[this.getConfiguration().drm.servers["com.widevine.alpha"]],method:"POST",originatesFromRemotePlayer:!0},a=await this.getNetworkingEngine().request(ne.net.NetworkingEngine.RequestType.LICENSE,r).promise;let s=a.data;(a.status<200||a.status>=300)&&(s=a.data??String.fromCharCode(new Uint8Array(a.data)),d.error("remotePlayer","license-request","failed to to get response from widevine:",a.status,s)),d.log("remotePlayer","license-request","Writing response to remote player",a.status),e.writeLicenseResponse(a.status,s)},tracksupdate:()=>{this._audioTracksMap={},this._textTracksMap={};const e=C.getAudioTracks();for(const t of e){let e=t.lang;3===e.length&&(e=v[e]||e),this._audioTracksMap[e]=t.id}const t=C.getTextTracks();for(const e of t)if(!e.autoTranslate){let t=e.lang;3===t.length&&(t=v[t]||t),this._textTracksMap[t]=e.id}},playing:async()=>{d.info("remotePlayer playing event received"),this._playingTimeout>0&&null!==this._playTimeoutId&&this._handlePlayingEvent()}};_clearPlayTimeout=()=>{this._playTimeoutId&&(d.info("Clearing play timeout"),clearTimeout(this._playTimeoutId),this._playTimeoutId=null)};_handlePlayingEvent=async()=>{if(this._clearPlayTimeout(),this.videoElement&&this._originalPlay&&this._playPromiseResolve)try{const e=Date.now()-this._playStartTime;d.info(`Time for playback start ${e}ms`),await this._originalPlay.call(this.videoElement),d.info("Video element play resolved successfully"),this._playPromiseResolve()}catch(e){return void this._handlePlayPromiseError(e)}finally{this._playPromiseResolve=null,this._playPromiseReject=null}};_resetPlayPromise=()=>{this._playPromiseResolve&&(d.info("Resolving play promise"),this._playPromiseResolve()),this._playPromiseResolve=null,this._playPromiseReject=null,this._clearPlayTimeout()};_handlePlayPromiseError(e){d.error("Error while waiting for playing event:",e),this._playPromiseReject&&(this._playPromiseReject(e),this._playPromiseResolve=null,this._playPromiseReject=null),this._playTimeoutId&&(clearTimeout(this._playTimeoutId),this._playTimeoutId=null)}_minSuggestedPresentationDelay=15;_updateManifestDelayIfBelowMinimum(e){const t=e.match(/suggestedPresentationDelay="([^"]+)"/);if(t){const n=t[1],i=Z().duration(n).asSeconds();if(d.info(`Found suggestedPresentationDelay in manifest: ${i.toFixed(3)}s`),i<this._minSuggestedPresentationDelay)return e=e.replace(/suggestedPresentationDelay="[^"]+"/,`suggestedPresentationDelay="PT${this._minSuggestedPresentationDelay.toFixed(3)}S"`),d.info(`Updated manifest suggestedPresentationDelay to ${this._minSuggestedPresentationDelay.toFixed(3)}s`),e}else d.info("suggestedPresentationDelay is not defined at the manifest")}constructor(e,t,n){super(e,t,n),ie._prevInstance&&(d.warn("SenzaShakaPlayer constructor: Previous instance of SenzaShakaPlayer wasn't destroyed before the new player was created. Disconnecting the previous instance."),ie._prevInstance._removeRemotePlayerEventListeners(),ie._prevInstance._removeVideoElementEventListeners(),C.detach(),ie._prevInstance=null),this.remotePlayer=C,this._addRemotePlayerEventListeners(),ie._prevInstance=this;const i=fe()?.sessionInfo?.settings?.["ui-streamer"]?.playingEventTimeout;this._playingTimeout=i>=0?1e3*i:this._playingTimeout;const r=fe()?.sessionInfo?.settings?.["ui-streamer"];void 0!==r?.minSuggestedPresentationDelay&&(this._minSuggestedPresentationDelay=r.minSuggestedPresentationDelay,d.info(`Using configured minSuggestedPresentationDelay: ${this._minSuggestedPresentationDelay}s`)),e&&(this._attach(e),d.warn("SenzaShakaPlayer constructor Adding videoElement in the constructor is going to be deprecated in the future. Please use attach method instead.")),this.configure({manifest:{defaultPresentationDelay:this._minSuggestedPresentationDelay}}),C.configure({minSuggestedPresentationDelay:this._minSuggestedPresentationDelay}),this.addEventListener("buffering",(()=>{this.videoElement&&d.info("Buffering at time:",this.videoElement.currentTime)}))}_attach(e){this.videoElement=e,this._playingTimeout>0&&(this._originalPlay=this.videoElement.play,this.videoElement.play=async()=>{if(this._playPromiseResolve||this._playPromiseReject)return void d.warn("play() was called while a play promise is already pending. Ignoring play call.");this._playTimeoutId&&clearTimeout(this._playTimeoutId),this._playStartTime=Date.now();const e=new Promise(((e,t)=>{this._playPromiseResolve=e,this._playPromiseReject=t}));return this._playTimeoutId=setTimeout((()=>{d.error("Playing event timeout reached"),this._handlePlayingEvent()}),this._playingTimeout),await this.remotePlayer.play().catch((e=>{d.error("Failed to play remote player:",e),this.handleSenzaError(e.code,e.message||"Unknown play error")})),e}),this._attachVideoElementToRemotePlayer()}async attach(e,t=!0){await super.attach(e,t),this._attach(e)}async detach(e=!1){this._resetPlayPromise(),this.videoElement&&this._originalPlay&&(this._playPromiseResolve=null,this._playPromiseReject=null,this.videoElement.play=this._originalPlay,this._originalPlay=null),await super.detach(e),this._audioTracksMap={},this._textTracksMap={},this._removeVideoElementEventListeners();try{""!==C.getAssetUri()&&await this.remotePlayer.unload(),this.remotePlayer.detach()}catch(e){d.error("Failed to detach remote player:",e),this.handleSenzaError(e.code,e.message)}this.videoElement=null}async unload(e=!0,t=!1){try{await O.moveToForeground(),this._clearPlayTimeout(),await C.unload()}catch(e){d.error("Failed to unload remote player:",e),this.handleSenzaError(e.code,e.message)}await super.unload(e,t)}getTextLanguages(){return Object.keys(this._textTracksMap)}getAudioLanguages(){return Object.keys(this._audioTracksMap)}selectAudioLanguage(e,t){d.log("Selecting audio language:",e,"with role: ",t),this._audioTracksMap[e]?C.selectAudioTrack(this._audioTracksMap[e]):d.warn(`Language ${e} not found in audio tracks map`),super.selectAudioLanguage(e,t)}selectTextLanguage(e,t){d.log("Selecting text language:",e,"with role:",t),this._textTracksMap[e]?C.selectTextTrack(this._textTracksMap[e]):d.warn(`Language ${e} not found in text tracks map`),super.selectTextLanguage(e,t)}setTextTrackVisibility(e){d.log("Setting text track visibility to:",e),C.setTextTrackVisibility(e),super.setTextTrackVisibility(e)}get isInRemotePlayback(){return O.state===O.UiState.BACKGROUND||O.state===O.UiState.IN_TRANSITION_TO_BACKGROUND}_createSenzaError(e,t,n){return new te(n?X.util.Error.Severity.CRITICAL:X.util.Error.Severity.RECOVERABLE,X.util.Error.Category.SENZA_PLAYER_ERROR,X.util.Error.Code.SENZA_PLAYER_ERROR,t,e)}_isErrorCritical(e){return!ee.includes(e)}handleSenzaError(e,t){const n=this._isErrorCritical(e),i=this._createSenzaError(e,t,n),r=new Map,a=this._shouldStopOnRemotePlayerError&&this.videoElement&&n;if(r.set("detail",i),a){try{d.warn("Stopping local player playback due to critical error"),this.videoElement.pause()}catch(e){d.error("Error while trying to stop video element playback:",e)}this._handlePlayPromiseError(i)}this.dispatchEvent(new X.util.FakeEvent("error",r))}async load(e,t,n){let i,r;const a=new Promise(((e,t)=>{i=e,r=t}));let s=!1;const{defaultInitialLiveOffset:o,minInitialLiveOffset:u}=fe()?.sessionInfo?.settings?.["ui-streamer"]||{};void 0!==t&&0!==t||void 0===o?t<=0&&void 0!==u&&t>-u&&(d.info(`load() was called with startTime=${t}, setting startTime to ${-u}`),t=-u):(d.info(`load() was called with startTime=${t}, setting startTime to ${-o}`),t=-o);const l=async(n,a)=>{if(n===X.net.NetworkingEngine.RequestType.MANIFEST){try{if(a.data&&this._minSuggestedPresentationDelay>0){const e=(new TextDecoder).decode(a.data),t=this._updateManifestDelayIfBelowMinimum(e);if(t){const e=(new TextEncoder).encode(t).buffer;a.data=e}}}catch(e){d.error("Error processing manifest:",e)}if(!s){s=!0;try{await this._remotePlayerLoad(e,t),i()}catch(e){r(e)}}}};this.getNetworkingEngine().registerResponseFilter(l);const c=Promise.all([super.load(e,t,n),a]);let h;const m=new Promise(((e,t)=>{h=setTimeout((()=>{const e=new Error("Manifest load timeout");e.code=8003,t(e)}),15e3)}));try{return await Promise.race([c,m])}catch(e){d.log("Couldn't load player. Error:",e),this.handleSenzaError(e.code,e.message)}finally{this.getNetworkingEngine().unregisterResponseFilter(l),clearTimeout(h)}}async destroy(){return await O.moveToForeground(),ie._prevInstance=null,this._removeRemotePlayerEventListeners(),super.destroy()}addTextTrack(e,t,n,i,r,a,s=!1){d.warn("addTextTrack is deprecated, please use addTextTrackAsync"),super.addTextTrackAsync(e,t,n,i,r,a,s).then((e=>{d.warn("addTextTrackAsync Done"+e)}))}configure(e){if(d.log("configure player with: ",JSON.stringify(e)),void 0!==e.shouldStopOnRemotePlayerError){this._shouldStopOnRemotePlayerError=!!e.shouldStopOnRemotePlayerError;const{shouldStopOnRemotePlayerError:t,...n}=e;e=n}super.configure(e);const t={...e};void 0!==e.preferredTextLanguage&&(t.preferredSubtitlesLanguage=e.preferredTextLanguage),d.log("configure remote player with: ",JSON.stringify(t)),C.configure(t)}_attachVideoElementToRemotePlayer(){try{this.remotePlayer.attach(this.videoElement),this._addVideoElementEventListeners()}catch(e){d.error("Failed to attach remote player:",e),this.handleSenzaError(e.code,e.message)}}async _remotePlayerLoad(e,t){const n=()=>{const e=this.remotePlayer._remotePlayerConfirmationTimeout+2e3;return Promise.race([new Promise((e=>this.remotePlayer.addEventListener("onloadmodechange",e,{once:!0}))),new Promise(((t,n)=>setTimeout((()=>n(`Timeout: Event "onloadmodechange" did not occur within ${e}ms`)),e)))])};if(!this.isInRemotePlayback||C.getAssetUri()!==e){this._audioTracksMap={},this._videoTracksMap={};try{this.remotePlayer.getLoadMode()===this.remotePlayer.LoadMode.UNLOADING&&(d.warn("load() was called while previous unload is still in progress, waiting for unload to finish"),await n()),d.info("Loading remote player with startTime:",t),await this.remotePlayer.load(e,t),d.log("Remote player loaded successfully")}catch(e){d.error("Couldn't load remote player. Error:",e),this.handleSenzaError(e.code,e.message)}}}_addRemotePlayerEventListeners(){for(const[e,t]of Object.entries(this._remotePlayerEventListeners))this.remotePlayer.addEventListener(e,t)}_addVideoElementEventListeners(){if(this.videoElement)for(const[e,t]of Object.entries(this._videoEventListeners))this.videoElement.addEventListener(e,t)}_removeVideoElementEventListeners(){if(this.videoElement)for(const[e,t]of Object.entries(this._videoEventListeners))this.videoElement.removeEventListener(e,t)}_removeRemotePlayerEventListeners(){for(const[e,t]of Object.entries(this._remotePlayerEventListeners))this.remotePlayer.removeEventListener(e,t)}}let re;ne.Player=ie;const ae=e=>{O.state!==O.UiState.BACKGROUND&&O.state!==O.UiState.IN_TRANSITION_TO_BACKGROUND||(re&&clearTimeout(re),re=setTimeout((()=>{O.state!==O.UiState.BACKGROUND&&O.state!==O.UiState.IN_TRANSITION_TO_BACKGROUND||d.log(`${e.type} event received while in '${O.state}' state and there was no call to lifecycle.moveToForeground() for 500 ms. Make sure to call it if you want to move to foreground.`),re=0}),500))};"undefined"!=typeof document&&document.addEventListener("keydown",ae),C.addEventListener("error",ae),C.addEventListener("ended",ae);const{rE:se}=t;let oe;const ue="1.0";"undefined"!=typeof document&&document.addEventListener("keydown",(e=>{d.log(`Got ${e.key} key`)}));const de={getToken:async function(){return oe?Promise.resolve(oe):(d.log("getToken wait for promise updateSession event"),new Promise((e=>{document.addEventListener("updateSession",(t=>{oe=t.detail?.updateObj,d.log(`onUpdateSessionEvent: token= ${oe}`),e(oe)}),{once:!0})})))},forceTokenUpdate:function(){if(oe=null,window.cefQuery){const e=s(),t=d.withFields({FCID:e});t.log("forceTokenUpdate: sending updateSessionRequest");const n={type:"updateSessionRequest",updateKey:"authorization",parentPath:"settings.webUI.backendHeaders.Authorization",fcid:e},i={target:"TC",waitForResponse:!1,message:JSON.stringify(n)};window.cefQuery({request:JSON.stringify(i),persistent:!1,onSuccess:()=>{t.log("updateSessionRequest successfully sent")},onFailure:(e,n)=>{t.error(`updateSessionRequest failed: ${e} ${n}`)}})}else d.error("forceTokenUpdate: window.cefQuery is undefined")},getClientAssertion:be},le=Object.freeze({UNKNOWN:"unknown",INITIAL_CONNECTION:"initial_connection",APPLICATION_RELOAD:"reload_app",UI_RELEASE:"ui_release",UI_TERMINATION:"ui_termination",WEBRTC_ERROR:"webrtc_error",UI_WATCHDOG:"ui_watchdog"});async function ce(){if(d.log(`init ${se}`),window.diagnostics||d.error("[ init ] window.diagnostics is undefined"),window.cefQuery){await new Promise(((e,t)=>{window.cefQuery({request:"apiVersion "+ue,persistent:!1,onSuccess:()=>{d.log("api version compatability check succeeded"),e()},onFailure:(e,n)=>{d.error("api version compatability check failed: "+n),t(n)}})}));const e=await new Promise((e=>{window.cefQuery({request:"sessionInfo",persistent:!1,onSuccess:t=>{d.log("sessionInfo request successfully returned "+t),e(t)},onFailure:(e,t)=>{d.error(`sessionInfo request failed: ${e} ${t}`)}})}));r.setSessionInfoStr(e);const t=JSON.parse(e);oe=t?.settings?.webUI?.backendHeaders?.Authorization,d.log(`authToken: token = ${oe}`),document.addEventListener("updateSession",(e=>{oe=e.detail?.updateObj,d.log(`onUpdateSessionEvent: token = ${oe}`)}));const n=t?.settings?.["ui-streamer"]?.alarmTimeout;n&&N._setDefaultTimeout(n);const i=await new Promise((e=>{const t=s(),n=d.withFields({FCID:t}),i={type:"triggerEvent",fcid:t},r={target:"UI-Streamer",waitForResponse:!1,message:JSON.stringify(i)};window.cefQuery({request:JSON.stringify(r),persistent:!1,onSuccess:t=>{n.log(`triggerEvent request successfully returned '${t}'`),e(t)},onFailure:(t,i)=>{n.error(`triggerEvent request failed: ${t} ${i}`),e("")}})}));let a={};if(i)try{a=JSON.parse(i)}catch(e){d.error(`failed to parse trigger event string ${i}: ${e.message}`)}await O._init(t?.settings?.["ui-streamer"],a),await C._init(t?.settings?.["ui-streamer"],a);const o=t?.settings?.["ui-streamer"]?.devSequence;o&&(k({lifecycle:O,remotePlayer:C}),D(!0))}else oe=fe().sessionInfo?.settings?.webUI?.backendHeaders?.Authorization,d.log(`authToken dummy: token = ${oe}`);window.close=()=>{d.warn("window.close is disabled on Senza platform. Use lifecycle.exitApplication() instead.")}}function he(){return O.connectReason}function me(){return O.triggerEvent}function fe(){if("undefined"==typeof window||!window.diagnostics)return"undefined"==typeof window||window.diagnostics||d.error("[ getPlatformInfo ] window.diagnostics is undefined"),{version:"X.X.XX-X",pod:"ui-streamer-X.X.XX-X-QWERT-ASDFG-XXX-XXXXXX-XXXXX",podIP:"0.0.0.0",sessionInfo:{userAgent:"SynamediaSenza/XX.YY.ZZ",connectionId:"dummy",deviceId:"123456789",community:"LocalDev",tenant:"XXXXXX",tenantId:"XXXXXX",manifest:{transcontainer:"X.X.XX-X"},settings:{webUI:{backendHeaders:{Authorization:"Bearer dummytoken"}}},homeSessionInfo:{tenantId:"XXXXXX",community:"LocalDev"}}};try{const e=window.diagnostics()||{};return e.sessionInfo=r.sessionInfoObj,e}catch(e){d.error("Could not get platform info",e.stack)}}function pe(e){if(window.cefQuery){const t={message:JSON.stringify({type:"setTimeZone",timezone:e}),waitForResponse:!1,target:"UI-Streamer"};window.cefQuery({request:JSON.stringify(t),persistent:!1,onSuccess:()=>{d.log("timezome is successfully set to",e)},onFailure:(t,n)=>{d.error(`error occurred setting timezone to ${e}: ${t} ${n}`)}})}}function ge(){return!("undefined"==typeof window||!window.cefQuery)}function ye(){window.cefQuery?window.cefQuery({request:"uiReady",persistent:!1,onSuccess:()=>{d.log("uiReady request successfully sent")},onFailure:(e,t)=>{d.error(`uiReady request failed: ${e} ${t}`)}}):d.error("uiReady: window.cefQuery is undefined")}function _e(){const e=r.sessionInfoObj;return ge()?{deviceId:e.deviceId,connectionId:e.connectionId,community:e.community,tenant:e.tenant,clientIp:e.clientIp}:(d.log("getDeviceInfo running locally, returning dummy info"),{deviceId:"123456789",connectionId:"dummy",community:"LocalDev",tenant:"XXXXXX",clientIp:"0.0.0.0"})}const ve={remoteBrowserIp:window.diagnostics?window.diagnostics().podIP:"127.0.0.1",sdkVersion:se};function Me(e,t,n,i){if(e>=200&&e<300&&(t=window.btoa(String.fromCharCode.apply(null,new Uint8Array(t)))),window.cefQuery){const r={type:"updateLicense",sessionId:i,fcid:n};r[e>=200&&e<300?"response":"error"]=t;const a={target:"TC",waitForResponse:!1,message:JSON.stringify(r)};window.cefQuery({request:JSON.stringify(a),persistent:!1,onSuccess:()=>{d.log("updateLicense request successfully sent")},onFailure:(e,t)=>{d.error(`updateLicense request failed: ${e} ${t}`)}})}}class we extends Error{constructor(e,t){super(t),this.code=e}}function be(){if(window.cefQuery)return d.log("getClientAssertion is called"),new Promise(((e,t)=>{window.cefQuery({request:"client_assertion",persistent:!1,onSuccess:n=>{try{const t=JSON.parse(n);d.log(`client_assertion request successfully returned ${n}`),e(t)}catch(e){d.error(`Failed to parse client assertion ${n}: ${e.message}`),t(new we(0,"Failed to parse client assertion"))}},onFailure:(e,n)=>{d.log(`client_assertion request failed: ${e} ${n}`),t(new we(e,n))}})}));d.warn("getClientAssertion is not supported if NOT running e2e")}"undefined"!=typeof window&&(window.hs=e,window.senza=window.senza||e)})(),i})()));
|