shaka-player 4.9.17 → 4.9.18

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.
@@ -17,9 +17,9 @@ function t(a){var b="undefined"!=typeof Symbol&&Symbol.iterator&&a[Symbol.iterat
17
17
  if("function"==typeof Object.setPrototypeOf)ia=Object.setPrototypeOf;else{var ja;a:{var ka={a:!0},la={};try{la.__proto__=ka;ja=la.a;break a}catch(a){}ja=!1}ia=ja?function(a,b){a.__proto__=b;if(a.__proto__!==b)throw new TypeError(a+" is not extensible");return a}:null}var ma=ia;
18
18
  function na(a,b){a.prototype=ha(b.prototype);a.prototype.constructor=a;if(ma)ma(a,b);else for(var c in b)if("prototype"!=c)if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);d&&Object.defineProperty(a,c,d)}else a[c]=b[c];a.Rl=b.prototype}function oa(){this.o=!1;this.l=null;this.h=void 0;this.g=1;this.j=this.m=0;this.A=this.i=null}function pa(a){if(a.o)throw new TypeError("Generator is already running");a.o=!0}oa.prototype.u=function(a){this.h=a};
19
19
  function qa(a,b){a.i={Dh:b,Nh:!0};a.g=a.m||a.j}oa.prototype.return=function(a){this.i={return:a};this.g=this.j};function E(a,b,c){a.g=c;return{value:b}}oa.prototype.B=function(a){this.g=a};function F(a){a.g=0}function ta(a,b,c){a.m=b;void 0!=c&&(a.j=c)}function ua(a,b){a.m=0;a.j=b||0}function va(a,b,c){a.g=b;a.m=c||0}function wa(a,b){a.m=b||0;b=a.i.Dh;a.i=null;return b}function xa(a){a.A=[a.i];a.m=0;a.j=0}
20
- function ya(a,b){var c=a.A.splice(0)[0];(c=a.i=a.i||c)?c.Nh?a.g=a.m||a.j:void 0!=c.B&&a.j<c.B?(a.g=c.B,a.i=null):a.g=a.j:a.g=b}function za(a){this.g=new oa;this.h=a}function Aa(a,b){pa(a.g);var c=a.g.l;if(c)return Ba(a,"return"in c?c["return"]:function(d){return{value:d,done:!0}},b,a.g.return);a.g.return(b);return Da(a)}
21
- function Ba(a,b,c,d){try{var e=b.call(a.g.l,c);if(!(e instanceof Object))throw new TypeError("Iterator result "+e+" is not an object");if(!e.done)return a.g.o=!1,e;var f=e.value}catch(g){return a.g.l=null,qa(a.g,g),Da(a)}a.g.l=null;d.call(a.g,f);return Da(a)}function Da(a){for(;a.g.g;)try{var b=a.h(a.g);if(b)return a.g.o=!1,{value:b.value,done:!1}}catch(c){a.g.h=void 0,qa(a.g,c)}a.g.o=!1;if(a.g.i){b=a.g.i;a.g.i=null;if(b.Nh)throw b.Dh;return{value:b.return,done:!0}}return{value:void 0,done:!0}}
22
- function Ga(a){this.next=function(b){pa(a.g);a.g.l?b=Ba(a,a.g.l.next,b,a.g.u):(a.g.u(b),b=Da(a));return b};this.throw=function(b){pa(a.g);a.g.l?b=Ba(a,a.g.l["throw"],b,a.g.u):(qa(a.g,b),b=Da(a));return b};this.return=function(b){return Aa(a,b)};this[Symbol.iterator]=function(){return this}}function Ha(a){function b(d){return a.next(d)}function c(d){return a.throw(d)}return new Promise(function(d,e){function f(g){g.done?d(g.value):Promise.resolve(g.value).then(b,c).then(f,e)}f(a.next())})}
20
+ function ya(a,b){var c=a.A.splice(0)[0];(c=a.i=a.i||c)?c.Nh?a.g=a.m||a.j:void 0!=c.B&&a.j<c.B?(a.g=c.B,a.i=null):a.g=a.j:a.g=b}function za(a){this.g=new oa;this.h=a}function Aa(a,b){pa(a.g);var c=a.g.l;if(c)return Ba(a,"return"in c?c["return"]:function(d){return{value:d,done:!0}},b,a.g.return);a.g.return(b);return Ea(a)}
21
+ function Ba(a,b,c,d){try{var e=b.call(a.g.l,c);if(!(e instanceof Object))throw new TypeError("Iterator result "+e+" is not an object");if(!e.done)return a.g.o=!1,e;var f=e.value}catch(g){return a.g.l=null,qa(a.g,g),Ea(a)}a.g.l=null;d.call(a.g,f);return Ea(a)}function Ea(a){for(;a.g.g;)try{var b=a.h(a.g);if(b)return a.g.o=!1,{value:b.value,done:!1}}catch(c){a.g.h=void 0,qa(a.g,c)}a.g.o=!1;if(a.g.i){b=a.g.i;a.g.i=null;if(b.Nh)throw b.Dh;return{value:b.return,done:!0}}return{value:void 0,done:!0}}
22
+ function Ga(a){this.next=function(b){pa(a.g);a.g.l?b=Ba(a,a.g.l.next,b,a.g.u):(a.g.u(b),b=Ea(a));return b};this.throw=function(b){pa(a.g);a.g.l?b=Ba(a,a.g.l["throw"],b,a.g.u):(qa(a.g,b),b=Ea(a));return b};this.return=function(b){return Aa(a,b)};this[Symbol.iterator]=function(){return this}}function Ha(a){function b(d){return a.next(d)}function c(d){return a.throw(d)}return new Promise(function(d,e){function f(g){g.done?d(g.value):Promise.resolve(g.value).then(b,c).then(f,e)}f(a.next())})}
23
23
  function O(a){return Ha(new Ga(new za(a)))}function Ka(){for(var a=Number(this),b=[],c=a;c<arguments.length;c++)b[c-a]=arguments[c];return b}
24
24
  ea("Promise",function(a){function b(g){this.h=0;this.i=void 0;this.g=[];this.o=!1;var h=this.j();try{g(h.resolve,h.reject)}catch(k){h.reject(k)}}function c(){this.g=null}function d(g){return g instanceof b?g:new b(function(h){h(g)})}if(a)return a;c.prototype.h=function(g){if(null==this.g){this.g=[];var h=this;this.i(function(){h.l()})}this.g.push(g)};var e=da.setTimeout;c.prototype.i=function(g){e(g,0)};c.prototype.l=function(){for(;this.g&&this.g.length;){var g=this.g;this.g=[];for(var h=0;h<g.length;++h){var k=
25
25
  g[h];g[h]=null;try{k()}catch(l){this.j(l)}}}this.g=null};c.prototype.j=function(g){this.i(function(){throw g;})};b.prototype.j=function(){function g(l){return function(m){k||(k=!0,l.call(h,m))}}var h=this,k=!1;return{resolve:g(this.H),reject:g(this.l)}};b.prototype.H=function(g){if(g===this)this.l(new TypeError("A Promise cannot resolve to itself"));else if(g instanceof b)this.J(g);else{a:switch(typeof g){case "object":var h=null!=g;break a;case "function":h=!0;break a;default:h=!1}h?this.G(g):this.m(g)}};
@@ -68,10 +68,10 @@ var lb=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^/?#]*)@)?([^/#?]*?)(?::([0-9]+))?(?=
68
68
  Copyright 2006 The Closure Library Authors
69
69
  SPDX-License-Identifier: Apache-2.0
70
70
  */
71
- function mb(a){var b;a instanceof mb?(nb(this,a.Sb),this.Oc=a.Oc,ob(this,a.Vb),pb(this,a.ld),this.pb=a.pb,qb(this,a.g.clone()),this.vc=a.vc):a&&(b=String(a).match(lb))?(nb(this,b[1]||"",!0),this.Oc=rb(b[2]||""),ob(this,b[3]||"",!0),pb(this,b[4]),this.pb=rb(b[5]||"",!0),qb(this,b[6]||"",!0),this.vc=rb(b[7]||"")):this.g=new sb(null)}q=mb.prototype;q.Sb="";q.Oc="";q.Vb="";q.ld=null;q.pb="";q.vc="";
72
- q.toString=function(){var a=[],b=this.Sb;b&&a.push(tb(b,ub,!0),":");if(b=this.Vb){a.push("//");var c=this.Oc;c&&a.push(tb(c,ub,!0),"@");a.push(encodeURIComponent(b).replace(/%25([0-9a-fA-F]{2})/g,"%$1"));b=this.ld;null!=b&&a.push(":",String(b))}if(b=this.pb)this.Vb&&"/"!=b.charAt(0)&&a.push("/"),a.push(tb(b,"/"==b.charAt(0)?vb:wb,!0));(b=this.g.toString())&&a.push("?",b);(b=this.vc)&&a.push("#",tb(b,yb));return a.join("")};
73
- q.resolve=function(a){var b=this.clone();"data"===b.Sb&&(b=new mb);var c=!!a.Sb;c?nb(b,a.Sb):c=!!a.Oc;c?b.Oc=a.Oc:c=!!a.Vb;c?ob(b,a.Vb):c=null!=a.ld;var d=a.pb;if(c)pb(b,a.ld);else if(c=!!a.pb){if("/"!=d.charAt(0))if(this.Vb&&!this.pb)d="/"+d;else{var e=b.pb.lastIndexOf("/");-1!=e&&(d=b.pb.substr(0,e+1)+d)}if(".."==d||"."==d)d="";else if(-1!=d.indexOf("./")||-1!=d.indexOf("/.")){e=0==d.lastIndexOf("/",0);d=d.split("/");for(var f=[],g=0;g<d.length;){var h=d[g++];"."==h?e&&g==d.length&&f.push(""):".."==
74
- h?((1<f.length||1==f.length&&""!=f[0])&&f.pop(),e&&g==d.length&&f.push("")):(f.push(h),e=!0)}d=f.join("/")}}c?b.pb=d:c=""!==a.g.toString();c?qb(b,a.g.clone()):c=!!a.vc;c&&(b.vc=a.vc);return b};q.clone=function(){return new mb(this)};function nb(a,b,c){a.Sb=c?rb(b,!0):b;a.Sb&&(a.Sb=a.Sb.replace(/:$/,""))}function ob(a,b,c){a.Vb=c?rb(b,!0):b}function pb(a,b){if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.ld=b}else a.ld=null}
71
+ function mb(a){var b;a instanceof mb?(nb(this,a.Sb),this.Pc=a.Pc,ob(this,a.Vb),pb(this,a.ld),this.pb=a.pb,qb(this,a.g.clone()),this.xc=a.xc):a&&(b=String(a).match(lb))?(nb(this,b[1]||"",!0),this.Pc=rb(b[2]||""),ob(this,b[3]||"",!0),pb(this,b[4]),this.pb=rb(b[5]||"",!0),qb(this,b[6]||"",!0),this.xc=rb(b[7]||"")):this.g=new sb(null)}q=mb.prototype;q.Sb="";q.Pc="";q.Vb="";q.ld=null;q.pb="";q.xc="";
72
+ q.toString=function(){var a=[],b=this.Sb;b&&a.push(tb(b,ub,!0),":");if(b=this.Vb){a.push("//");var c=this.Pc;c&&a.push(tb(c,ub,!0),"@");a.push(encodeURIComponent(b).replace(/%25([0-9a-fA-F]{2})/g,"%$1"));b=this.ld;null!=b&&a.push(":",String(b))}if(b=this.pb)this.Vb&&"/"!=b.charAt(0)&&a.push("/"),a.push(tb(b,"/"==b.charAt(0)?vb:wb,!0));(b=this.g.toString())&&a.push("?",b);(b=this.xc)&&a.push("#",tb(b,yb));return a.join("")};
73
+ q.resolve=function(a){var b=this.clone();"data"===b.Sb&&(b=new mb);var c=!!a.Sb;c?nb(b,a.Sb):c=!!a.Pc;c?b.Pc=a.Pc:c=!!a.Vb;c?ob(b,a.Vb):c=null!=a.ld;var d=a.pb;if(c)pb(b,a.ld);else if(c=!!a.pb){if("/"!=d.charAt(0))if(this.Vb&&!this.pb)d="/"+d;else{var e=b.pb.lastIndexOf("/");-1!=e&&(d=b.pb.substr(0,e+1)+d)}if(".."==d||"."==d)d="";else if(-1!=d.indexOf("./")||-1!=d.indexOf("/.")){e=0==d.lastIndexOf("/",0);d=d.split("/");for(var f=[],g=0;g<d.length;){var h=d[g++];"."==h?e&&g==d.length&&f.push(""):".."==
74
+ h?((1<f.length||1==f.length&&""!=f[0])&&f.pop(),e&&g==d.length&&f.push("")):(f.push(h),e=!0)}d=f.join("/")}}c?b.pb=d:c=""!==a.g.toString();c?qb(b,a.g.clone()):c=!!a.xc;c&&(b.xc=a.xc);return b};q.clone=function(){return new mb(this)};function nb(a,b,c){a.Sb=c?rb(b,!0):b;a.Sb&&(a.Sb=a.Sb.replace(/:$/,""))}function ob(a,b,c){a.Vb=c?rb(b,!0):b}function pb(a,b){if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.ld=b}else a.ld=null}
75
75
  function qb(a,b,c){b instanceof sb?a.g=b:(c||(b=tb(b,zb)),a.g=new sb(b))}function rb(a,b){return a?b?decodeURI(a):decodeURIComponent(a):""}function tb(a,b,c){return null!=a?(a=encodeURI(a).replace(b,Ab),c&&(a=a.replace(/%25([0-9a-fA-F]{2})/g,"%$1")),a):null}function Ab(a){a=a.charCodeAt(0);return"%"+(a>>4&15).toString(16)+(a&15).toString(16)}var ub=/[#\/\?@]/g,wb=/[#\?:]/g,vb=/[#\?]/g,zb=/[#\?@]/g,yb=/#/g;function sb(a){this.g=a||null}
76
76
  function Bb(a){if(!a.ab&&(a.ab={},a.Md=0,a.g))for(var b=a.g.split("&"),c=0;c<b.length;c++){var d=b[c].indexOf("="),e=null;if(0<=d){var f=b[c].substring(0,d);e=b[c].substring(d+1)}else f=b[c];f=decodeURIComponent(f.replace(/\+/g," "));e=e||"";a.add(f,decodeURIComponent(e.replace(/\+/g," ")))}}q=sb.prototype;q.ab=null;q.Md=null;function Cb(a){Bb(a);return a.Md}q.add=function(a,b){Bb(this);this.g=null;var c=this.ab.hasOwnProperty(a)?this.ab[a]:null;c||(this.ab[a]=c=[]);c.push(b);this.Md++;return this};
77
77
  q.set=function(a,b){Bb(this);this.g=null;this.ab.hasOwnProperty(a)?this.ab[a]=[b]:this.add(a,b);return this};q.get=function(a){Bb(this);return this.ab[a]||[]};q.toString=function(){if(this.g)return this.g;if(!this.ab)return"";var a=[],b;for(b in this.ab)for(var c=encodeURIComponent(b),d=this.ab[b],e=0;e<d.length;e++){var f=c;""!==d[e]&&(f+="="+encodeURIComponent(d[e]));a.push(f)}return this.g=a.join("&")};
@@ -126,7 +126,7 @@ var $c=new Map([["aar","aa"],["abk","ab"],["afr","af"],["aka","ak"],["alb","sq"]
126
126
  q.vh=function(a){var b=this;this.g.clear();a=t(a);for(var c=a.next();!c.done;c=a.next())this.g.add(Xc(c.value));id(this);a=kb(this.g,function(d){return!b.h.has(d)});a.length&&this.dispatchEvent(new S("unknown-locales",(new Map).set("locales",a)));a=kb(this.g,function(d){return b.h.has(d)});a=(new Map).set("locales",a.length?a:[this.j]);this.dispatchEvent(new S("locale-changed",a))};
127
127
  q.Ka=function(a,b,c){a=Xc(a);void 0===c&&(c=jd);var d=this.h.get(a)||new Map;b.forEach(function(e,f){d.has(f)&&c!=jd||d.set(f,e)});this.h.set(a,d);id(this);this.dispatchEvent(new S("locale-updated"));return this};q.ik=function(a){for(var b=t(a.keys()),c=b.next();!c.done;c=b.next())c=c.value,a.set(c,this.resolve(c))};q.resolve=function(a){var b=this.i.get(a);if(b)return b;a=(new Map).set("locales",Array.from(this.g)).set("missing",a);this.dispatchEvent(new S("unknown-localization",a));return""};
128
128
  q.Zi=function(){return this.g};
129
- function id(a){for(var b=a.h,c=a.j,d=a.g,e=new Set,f={},g=t(d),h=g.next();!h.done;f={Tc:f.Tc},h=g.next()){f.Tc=h.value;e.add(f.Tc);e.add(dd(f.Tc));h=kb(b.keys(),function(l){return function(m){return bd(m,l.Tc)}}(f));h.sort();var k=t(h);for(h=k.next();!h.done;h=k.next())e.add(h.value);h=kb(b.keys(),function(l){return function(m){return dd(m)==l.Tc}}(f));h.sort();k=t(h);for(h=k.next();!h.done;h=k.next())e.add(h.value)}e.add(c);c=[];e=t(e);for(h=e.next();!h.done;h=e.next())(h=b.get(h.value))&&c.push(h);
129
+ function id(a){for(var b=a.h,c=a.j,d=a.g,e=new Set,f={},g=t(d),h=g.next();!h.done;f={Uc:f.Uc},h=g.next()){f.Uc=h.value;e.add(f.Uc);e.add(dd(f.Uc));h=kb(b.keys(),function(l){return function(m){return bd(m,l.Uc)}}(f));h.sort();var k=t(h);for(h=k.next();!h.done;h=k.next())e.add(h.value);h=kb(b.keys(),function(l){return function(m){return dd(m)==l.Uc}}(f));h.sort();k=t(h);for(h=k.next();!h.done;h=k.next())e.add(h.value)}e.add(c);c=[];e=t(e);for(h=e.next();!h.done;h=e.next())(h=b.get(h.value))&&c.push(h);
130
130
  c.reverse();a.i.clear();b=t(c);for(h=b.next();!h.done;h=b.next())h.value.forEach(function(l,m){a.i.set(m,l)});b=a.i.keys();e=new Set;c=t(a.g);for(h=c.next();!h.done;h=c.next())h=a.h.get(h.value)||new Map,kd(h,b,e);0<e.size&&(d=(new Map).set("locales",Array.from(d)).set("missing",Array.from(e)),a.dispatchEvent(new S("missing-localizations",d)))}function kd(a,b,c){b=t(b);for(var d=b.next();!d.done;d=b.next())d=d.value,a.get(d)||c.add(d)}P("shaka.ui.Localization",hd);hd.prototype.getCurrentLocales=hd.prototype.Zi;
131
131
  hd.prototype.resolve=hd.prototype.resolve;hd.prototype.resolveDictionary=hd.prototype.ik;hd.prototype.insert=hd.prototype.Ka;hd.prototype.changeLocale=hd.prototype.vh;hd.prototype.release=hd.prototype.release;var jd=1;hd.ConflictResolution={USE_OLD:0,USE_NEW:jd};hd.UNKNOWN_LOCALES="unknown-locales";hd.UNKNOWN_LOCALIZATION="unknown-localization";hd.MISSING_LOCALIZATIONS="missing-localizations";hd.LOCALE_CHANGED="locale-changed";hd.LOCALE_UPDATED="locale-updated";function ld(a){this.g=Math.exp(Math.log(.5)/a);this.i=this.h=0}ld.prototype.sample=function(a,b){var c=Math.pow(this.g,a);b=b*(1-c)+c*this.h;isNaN(b)||(this.h=b,this.i+=a)};function md(a){return a.h/(1-Math.pow(a.g,a.i))};function nd(){this.h=new ld(2);this.j=new ld(5);this.g=0;this.i=128E3;this.l=16E3}nd.prototype.configure=function(a){this.i=a.minTotalBytes;this.l=a.minBytes;this.h.g=Math.exp(Math.log(.5)/a.fastHalfLife);this.j.g=Math.exp(Math.log(.5)/a.slowHalfLife)};nd.prototype.sample=function(a,b){if(!(b<this.l)){var c=8E3*b/a;a/=1E3;this.g+=b;this.h.sample(a,c);this.j.sample(a,c)}};nd.prototype.getBandwidthEstimate=function(a){return this.g<this.i?a:Math.min(md(this.h),md(this.j))};function od(){this.g=new fb}q=od.prototype;q.release=function(){this.qb();this.g=null};q.s=function(a,b,c,d){this.g&&(a=new pd(a,b,c,d),this.g.push(b,a))};q.oa=function(a,b,c,d){function e(g){f.Xa(a,b,e);c(g)}var f=this;this.s(a,b,e,d)};q.Xa=function(a,b,c){if(this.g){var d=this.g.get(b)||[];d=t(d);for(var e=d.next();!e.done;e=d.next())e=e.value,e.target!=a||c!=e.listener&&c||(e.Xa(),this.g.remove(b,e))}};
132
132
  q.qb=function(){if(this.g){var a=this.g,b=[],c;for(c in a.g)b.push.apply(b,x(a.g[c]));a=t(b);for(b=a.next();!b.done;b=a.next())b.value.Xa();this.g.g={}}};P("shaka.util.EventManager",od);od.prototype.removeAll=od.prototype.qb;od.prototype.unlisten=od.prototype.Xa;od.prototype.listenOnce=od.prototype.oa;od.prototype.listen=od.prototype.s;od.prototype.release=od.prototype.release;function pd(a,b,c,d){this.target=a;this.type=b;this.listener=c;this.g=qd(a,d);this.target.addEventListener(b,c,this.g)}
@@ -134,7 +134,7 @@ pd.prototype.Xa=function(){this.target.removeEventListener(this.type,this.listen
134
134
  function rd(a){var b=sd;if(void 0==b){b=!1;try{var c={},d={get:function(){b=!0;return!1}};Object.defineProperty(c,"passive",d);Object.defineProperty(c,"capture",d);d=function(){};a.addEventListener("test",d,c);a.removeEventListener("test",d,c)}catch(e){b=!1}sd=b}return b||!1}var sd=void 0;function td(a){if(ud.has(a))return ud.get(a);if(window.ManagedMediaSource){var b=ManagedMediaSource.isTypeSupported(a);ud.set(a,b);return b}return window.MediaSource?(b=MediaSource.isTypeSupported(a),ud.set(a,b),b):!1}function vd(){return!!window.SourceBuffer&&!!SourceBuffer.prototype&&!!SourceBuffer.prototype.changeType}var ud=new Map;function wd(a,b){this.g=a;this.h=b}wd.prototype.toString=function(){return"v"+this.g+"."+this.h};function xd(a,b){var c=new wd(5,0),d=yd,e=d.g,f=c.h-e.h;(0<(c.g-e.g||f)?d.i:d.h)(d.g,c,a,b)}function zd(a,b,c,d){Ya([c,"has been deprecated and will be removed in",b,". We are currently at version",a,". Additional information:",d].join(" "))}function Ad(a,b,c,d){Xa([c,"has been deprecated and has been removed in",b,". We are now at version",a,". Additional information:",d].join(" "))}var yd=null;function Bd(){}Bd.prototype.extract=function(){};Bd.prototype.decode=function(){return[]};Bd.prototype.clear=function(){};Bd.prototype.getStreams=function(){return[]};function Cd(){}Cd.prototype.init=function(){};Cd.prototype.parse=function(){return[]};function Dd(){}Dd.prototype.init=function(){};Dd.prototype.i=function(){};Dd.prototype.g=function(){};Dd.prototype.j=function(){};P("shaka.media.IClosedCaptionParser",Dd);function Ed(a){this.l=new Cd;if(a=Hd[a.toLowerCase()])this.l=a();this.h=new Bd;if(a=Jd)this.h=a()}Ed.prototype.init=function(a,b){void 0!==b&&b||(this.g(),this.l.init(a))};Ed.prototype.i=function(a){a=this.l.parse(a);a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;var c=Gb(b.packet);0<c.length&&this.h.extract(c,b.pts)}return this.h.decode()};
135
135
  Ed.prototype.g=function(){this.h.clear()};Ed.prototype.j=function(){return this.h.getStreams()};P("shaka.media.ClosedCaptionParser",Ed);Ed.findDecoder=function(){return Jd};Ed.unregisterDecoder=function(){Jd=null};Ed.registerDecoder=function(a){Jd=a};Ed.findParser=function(a){return Hd[a]};Ed.unregisterParser=function(a){delete Hd[a]};Ed.registerParser=function(a,b){Hd[a]=b};var Hd={},Jd=null;function Kd(){this.id="";this.regionAnchorY=this.regionAnchorX=this.viewportAnchorY=this.viewportAnchorX=0;this.height=this.width=100;this.viewportAnchorUnits=this.widthUnits=this.heightUnits=Ld;this.scroll=Md}P("shaka.text.CueRegion",Kd);var Ld=1;Kd.units={PX:0,PERCENTAGE:Ld,LINES:2};var Md="";Kd.scrollMode={NONE:Md,UP:"up"};function Nd(a,b){return"number"===typeof a&&"number"===typeof b&&isNaN(a)&&isNaN(b)?!0:a===b}function Od(a,b){b=a.indexOf(b);-1<b&&a.splice(b,1)}function Pd(a,b,c){c||(c=Nd);if(a.length!=b.length)return!1;b=b.slice();var d={};a=t(a);for(var e=a.next();!e.done;d={Bf:d.Bf},e=a.next()){d.Bf=e.value;e=b.findIndex(function(f){return function(g){return c(f.Bf,g)}}(d));if(-1==e)return!1;b[e]=b[b.length-1];b.pop()}return 0==b.length}
136
136
  function Qd(a,b,c){c||(c=Nd);if(a.length!=b.length)return!1;for(var d=0;d<a.length;d++)if(!c(a[d],b[d]))return!1;return!0};function Rd(a,b,c){this.startTime=a;this.endTime=b;this.payload=c;this.region=new Kd;this.position=null;this.positionAlign=Sd;this.size=0;this.textAlign=Td;this.direction=Ud;this.writingMode=Vd;this.lineInterpretation=Wd;this.line=null;this.lineHeight="";this.lineAlign=Xd;this.displayAlign=Yd;this.fontSize=this.border=this.backgroundImage=this.backgroundColor=this.color="";this.fontWeight=ae;this.fontStyle=be;this.linePadding=this.letterSpacing=this.fontFamily="";this.opacity=1;this.textCombineUpright=
137
- "";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={uc:32,rows:15}}function ce(a,b){a=new Rd(a,b,"");a.lineBreak=!0;return a}Rd.prototype.clone=function(){var a=new Rd(0,0,""),b;for(b in this)a[b]=this[b],a[b]&&a[b].constructor==Array&&(a[b]=a[b].slice());return a};
137
+ "";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={wc:32,rows:15}}function ce(a,b){a=new Rd(a,b,"");a.lineBreak=!0;return a}Rd.prototype.clone=function(){var a=new Rd(0,0,""),b;for(b in this)a[b]=this[b],a[b]&&a[b].constructor==Array&&(a[b]=a[b].slice());return a};
138
138
  function de(a,b){if(a.startTime!=b.startTime||a.endTime!=b.endTime||a.payload!=b.payload)return!1;for(var c in a)if("startTime"!=c&&"endTime"!=c&&"payload"!=c)if("nestedCues"==c){if(!Qd(a.nestedCues,b.nestedCues,de))return!1}else if("region"==c||"cellResolution"==c)for(var d in a[c]){if(a[c][d]!=b[c][d])return!1}else if(Array.isArray(a[c])){if(!Qd(a[c],b[c]))return!1}else if(a[c]!=b[c])return!1;return!0}P("shaka.text.Cue",Rd);Rd.equal=de;Rd.prototype.clone=Rd.prototype.clone;var Sd="auto";
139
139
  Rd.positionAlign={LEFT:"line-left",RIGHT:"line-right",CENTER:"center",AUTO:Sd};var Td="center",ee={LEFT:"left",RIGHT:"right",CENTER:Td,START:"start",END:"end"};Rd.textAlign=ee;var Yd="after",fe={BEFORE:"before",CENTER:"center",AFTER:Yd};Rd.displayAlign=fe;var Ud="ltr";Rd.direction={HORIZONTAL_LEFT_TO_RIGHT:Ud,HORIZONTAL_RIGHT_TO_LEFT:"rtl"};var Vd="horizontal-tb";Rd.writingMode={HORIZONTAL_TOP_TO_BOTTOM:Vd,VERTICAL_LEFT_TO_RIGHT:"vertical-lr",VERTICAL_RIGHT_TO_LEFT:"vertical-rl"};var Wd=0;
140
140
  Rd.lineInterpretation={LINE_NUMBER:Wd,PERCENTAGE:1};var Xd="start",ge={CENTER:"center",START:Xd,END:"end"};Rd.lineAlign=ge;var he={white:"white",lime:"lime",cyan:"cyan",red:"red",yellow:"yellow",magenta:"magenta",blue:"blue",black:"black"};Rd.defaultTextColor=he;var ie={bg_white:"white",bg_lime:"lime",bg_cyan:"cyan",bg_red:"red",bg_yellow:"yellow",bg_magenta:"magenta",bg_blue:"blue",bg_black:"black"};Rd.defaultTextBackgroundColor=ie;var ae=400;Rd.fontWeight={NORMAL:ae,BOLD:700};
@@ -162,7 +162,7 @@ function kf(a,b){var c=Zb(),d=$b("Firefox")&&oc(),e=a.video,f=e&&e.width||0,g=e&
162
162
  if(e){d=nf(e.codecs,e.mimeType);c=we(e.mimeType,d,"audio");if(!td(c))return!1;e.codecs=d}return a.decodingInfos.some(function(h){return!h.supported||b&&(h=h.keySystemAccess)&&h.keySystem!=b?!1:!0})}function of(a){var b=[];for(c in a)b.push(c);b.sort();var c=[];b=t(b);for(var d=b.next();!d.done;d=b.next()){var e=d.value;d=JSON.stringify(e);e=a[e];e instanceof Object?(e=of(e),c.push(d+":"+e)):(e=JSON.stringify(e),c.push(d+":"+e))}return"{"+c.join(",")+"}"}
163
163
  function pf(a,b){var c,d,e,f,g,h,k;return O(function(l){if(1==l.g){c=function(m,n){if(m){var p=Ye(m);p.supported=m.supported&&n.supported;p.powerEfficient=m.powerEfficient&&n.powerEfficient;p.smooth=m.smooth&&n.smooth;n.keySystemAccess&&!p.keySystemAccess&&(p.keySystemAccess=n.keySystemAccess);return p}return n};d=null;e=[];f={};g=t(b);for(h=g.next();!h.done;f={sd:f.sd,td:f.td},h=g.next())k=h.value,f.td=of(k),f.sd=qf,f.sd[f.td]?d=c(d,f.sd[f.td]):e.push(rf(k).then(function(m){return function(n){var p=
164
164
  null;n=t(n||[]);for(var r=n.next();!r.done;r=n.next())p=c(p,r.value);p&&(m.sd[m.td]=p,d=c(d,p))}}(f)));return E(l,Promise.all(e),2)}d&&a.decodingInfos.push(d);F(l)})}
165
- function rf(a){var b=[""];a.video&&(b=Ke(a.video.contentType).split(","));var c=[""];a.audio&&(c=Ke(a.audio.contentType).split(","));var d=[];b=t(b);for(var e=b.next();!e.done;e=b.next()){e=e.value;for(var f={},g=t(c),h=g.next();!h.done;f={pc:f.pc},h=g.next())h=h.value,f.pc=Xe(a),a.video&&(f.pc.video.contentType=te(Je(f.pc.video.contentType),e)),a.audio&&(f.pc.audio.contentType=te(Je(f.pc.audio.contentType),h)),d.push(new Promise(function(k){return function(l,m){navigator.mediaCapabilities.decodingInfo(k.pc).then(function(n){l(n)}).catch(m)}}(f)))}return Promise.all(d).catch(function(){JSON.stringify(a);
165
+ function rf(a){var b=[""];a.video&&(b=Ke(a.video.contentType).split(","));var c=[""];a.audio&&(c=Ke(a.audio.contentType).split(","));var d=[];b=t(b);for(var e=b.next();!e.done;e=b.next()){e=e.value;for(var f={},g=t(c),h=g.next();!h.done;f={rc:f.rc},h=g.next())h=h.value,f.rc=Xe(a),a.video&&(f.rc.video.contentType=te(Je(f.rc.video.contentType),e)),a.audio&&(f.rc.audio.contentType=te(Je(f.rc.audio.contentType),h)),d.push(new Promise(function(k){return function(l,m){navigator.mediaCapabilities.decodingInfo(k.rc).then(function(n){l(n)}).catch(m)}}(f)))}return Promise.all(d).catch(function(){JSON.stringify(a);
166
166
  return null})}
167
167
  function jf(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y;return O(function(B){switch(B.g){case 1:if(e=a.some(function(D){return D.decodingInfos.length}))return B.return();f={};g=t(d);h=g.next();case 2:if(h.done){B.B(4);break}f.Df=h.value;k=!1;l=t(a);m=l.next();case 5:if(m.done){B.B(7);break}n=m.value;p=sf(n,b,c).filter(function(D){return function(K){K=K[0];return(K.keySystemConfiguration&&K.keySystemConfiguration.keySystem)===D.Df}}(f));r=t(p);u=r.next();case 8:if(u.done){B.B(10);break}v=u.value;
168
168
  return E(B,pf(n,v),9);case 9:u=r.next();B.B(8);break;case 10:n.decodingInfos.length&&(k=!0);m=l.next();B.B(5);break;case 7:if(k)return B.return();f={Df:f.Df};h=g.next();B.B(2);break;case 4:w=t(a),m=w.next();case 12:if(m.done){B.B(0);break}A=m.value;z=sf(A,b,c).filter(function(D){D=D[0];D=D.keySystemConfiguration&&D.keySystemConfiguration.keySystem;return!D||!d.includes(D)});C=t(z);u=C.next();case 15:if(u.done){m=w.next();B.B(12);break}y=u.value;return E(B,pf(A,y),16);case 16:u=C.next(),B.B(15)}})}
@@ -219,10 +219,10 @@ Bj:m};!w&&a.j&&a.j(z.headers,c,b);return C},function(z){r&&r.stop();u&&u.stop();
219
219
  function Fg(a,b,c,d){var e=pg(void 0),f={};a=t(a.h);for(var g=a.next();!g.done;f={Ff:f.Ff},g=a.next())f.Ff=g.value,e=e.Qa(function(h){return function(){var k=c.response;k.data&&(k.data=Ib(k.data));return h.Ff(b,k,d)}}(f));return e.Qa(function(){return c},function(h){var k=2;if(h instanceof U){if(7001==h.code)throw h;k=h.severity}throw new U(k,1,1007,h);})}function Hg(a){if(a){var b=a.segment;a=a.stream;if(b&&a&&a.fastSwitching&&b.fe)return!1}return!0}P("shaka.net.NetworkingEngine",vg);
220
220
  vg.prototype.request=vg.prototype.request;vg.prototype.destroy=vg.prototype.destroy;vg.makeRequest=Ag;vg.defaultRetryParameters=function(){return jg()};vg.prototype.clearAllResponseFilters=vg.prototype.Mi;vg.prototype.unregisterResponseFilter=vg.prototype.Ek;vg.prototype.registerResponseFilter=vg.prototype.bk;vg.prototype.clearAllRequestFilters=vg.prototype.Li;vg.prototype.unregisterRequestFilter=vg.prototype.Dk;vg.prototype.registerRequestFilter=vg.prototype.$j;vg.unregisterScheme=function(a){delete yg[a]};
221
221
  vg.registerScheme=wg;vg.prototype.setForceHTTPS=vg.prototype.$g;vg.prototype.setForceHTTP=vg.prototype.Zg;function Bg(){this.g=0}vg.NumBytesRemainingClass=Bg;function Cg(a,b,c){mg.call(this,a,b);this.h=c}na(Cg,mg);vg.PendingRequest=Cg;var Gg=1;vg.RequestType={MANIFEST:0,SEGMENT:Gg,LICENSE:2,APP:3,TIMING:4,SERVER_CERTIFICATE:5,KEY:6,ADS:7,CONTENT_STEERING:8};vg.AdvancedRequestType={INIT_SEGMENT:0,MEDIA_SEGMENT:1,MEDIA_PLAYLIST:2,MASTER_PLAYLIST:3,MPD:4,MSS:5};var xg=3;
222
- vg.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:xg};var yg={};function Ig(a){this.g=!1;this.h=new lg;this.i=a}Ig.prototype.destroy=function(){var a=this;if(this.g)return this.h;this.g=!0;return this.i().then(function(){a.h.resolve()},function(){a.h.resolve()})};function Jg(a,b){if(a.g){if(b instanceof U&&7003==b.code)throw b;throw new U(2,7,7003,b);}};function Kg(a){for(var b=new Map,c=t(Object.keys(a)),d=c.next();!d.done;d=c.next())d=d.value,b.set(d,a[d]);return b}function Lg(a){var b={};a.forEach(function(c,d){b[d]=c});return b};function Mg(a,b){this.h=Lb(a);this.i=b==Ng;this.g=0}q=Mg.prototype;q.Ca=function(){return this.g<this.h.byteLength};q.Ja=function(){return this.g};q.getLength=function(){return this.h.byteLength};q.X=function(){try{var a=this.h.getUint8(this.g);this.g+=1;return a}catch(b){throw Og();}};q.wa=function(){try{var a=this.h.getUint16(this.g,this.i);this.g+=2;return a}catch(b){throw Og();}};q.T=function(){try{var a=this.h.getUint32(this.g,this.i);this.g+=4;return a}catch(b){throw Og();}};
222
+ vg.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:xg};var yg={};function Ig(a){this.g=!1;this.h=new lg;this.i=a}Ig.prototype.destroy=function(){var a=this;if(this.g)return this.h;this.g=!0;return this.i().then(function(){a.h.resolve()},function(){a.h.resolve()})};function Jg(a,b){if(a.g){if(b instanceof U&&7003==b.code)throw b;throw new U(2,7,7003,b);}};function Kg(a){for(var b=new Map,c=t(Object.keys(a)),d=c.next();!d.done;d=c.next())d=d.value,b.set(d,a[d]);return b}function Lg(a){var b={};a.forEach(function(c,d){b[d]=c});return b};function Mg(a,b){this.h=Lb(a);this.i=b==Ng;this.g=0}q=Mg.prototype;q.Ca=function(){return this.g<this.h.byteLength};q.Ja=function(){return this.g};q.getLength=function(){return this.h.byteLength};q.Y=function(){try{var a=this.h.getUint8(this.g);this.g+=1;return a}catch(b){throw Og();}};q.wa=function(){try{var a=this.h.getUint16(this.g,this.i);this.g+=2;return a}catch(b){throw Og();}};q.T=function(){try{var a=this.h.getUint32(this.g,this.i);this.g+=4;return a}catch(b){throw Og();}};
223
223
  q.Xh=function(){try{var a=this.h.getInt32(this.g,this.i);this.g+=4;return a}catch(b){throw Og();}};q.md=function(){try{if(this.i){var a=this.h.getUint32(this.g,!0);var b=this.h.getUint32(this.g+4,!0)}else b=this.h.getUint32(this.g,!1),a=this.h.getUint32(this.g+4,!1)}catch(c){throw Og();}if(2097151<b)throw new U(2,3,3001);this.g+=8;return b*Math.pow(2,32)+a};q.Hb=function(a){if(this.g+a>this.h.byteLength)throw Og();var b=Gb(this.h,this.g,a);this.g+=a;return b};
224
- q.skip=function(a){if(this.g+a>this.h.byteLength)throw Og();this.g+=a};q.jk=function(a){if(this.g<a)throw Og();this.g-=a};q.seek=function(a){if(0>a||a>this.h.byteLength)throw Og();this.g=a};q.Ic=function(){for(var a=this.g;this.Ca()&&0!=this.h.getUint8(this.g);)this.g+=1;a=Gb(this.h,a,this.g-a);this.g+=1;return wc(a)};function Og(){return new U(2,3,3E3)}P("shaka.util.DataViewReader",Mg);Mg.prototype.readTerminatedString=Mg.prototype.Ic;Mg.prototype.seek=Mg.prototype.seek;Mg.prototype.rewind=Mg.prototype.jk;
225
- Mg.prototype.skip=Mg.prototype.skip;Mg.prototype.readBytes=Mg.prototype.Hb;Mg.prototype.readUint64=Mg.prototype.md;Mg.prototype.readInt32=Mg.prototype.Xh;Mg.prototype.readUint32=Mg.prototype.T;Mg.prototype.readUint16=Mg.prototype.wa;Mg.prototype.readUint8=Mg.prototype.X;Mg.prototype.getLength=Mg.prototype.getLength;Mg.prototype.getPosition=Mg.prototype.Ja;Mg.prototype.hasMoreData=Mg.prototype.Ca;var Ng=1;Mg.Endianness={BIG_ENDIAN:0,LITTLE_ENDIAN:Ng};function Pg(){this.i=[];this.h=[];this.g=!1}q=Pg.prototype;q.box=function(a,b){a=Qg(a);this.i[a]=Rg;this.h[a]=b;return this};q.W=function(a,b){a=Qg(a);this.i[a]=Sg;this.h[a]=b;return this};q.stop=function(){this.g=!0};q.parse=function(a,b,c){a=new Mg(a,0);for(this.g=!1;a.Ca()&&!this.g;)this.kd(0,a,b,c)};
224
+ q.skip=function(a){if(this.g+a>this.h.byteLength)throw Og();this.g+=a};q.jk=function(a){if(this.g<a)throw Og();this.g-=a};q.seek=function(a){if(0>a||a>this.h.byteLength)throw Og();this.g=a};q.Jc=function(){for(var a=this.g;this.Ca()&&0!=this.h.getUint8(this.g);)this.g+=1;a=Gb(this.h,a,this.g-a);this.g+=1;return wc(a)};function Og(){return new U(2,3,3E3)}P("shaka.util.DataViewReader",Mg);Mg.prototype.readTerminatedString=Mg.prototype.Jc;Mg.prototype.seek=Mg.prototype.seek;Mg.prototype.rewind=Mg.prototype.jk;
225
+ Mg.prototype.skip=Mg.prototype.skip;Mg.prototype.readBytes=Mg.prototype.Hb;Mg.prototype.readUint64=Mg.prototype.md;Mg.prototype.readInt32=Mg.prototype.Xh;Mg.prototype.readUint32=Mg.prototype.T;Mg.prototype.readUint16=Mg.prototype.wa;Mg.prototype.readUint8=Mg.prototype.Y;Mg.prototype.getLength=Mg.prototype.getLength;Mg.prototype.getPosition=Mg.prototype.Ja;Mg.prototype.hasMoreData=Mg.prototype.Ca;var Ng=1;Mg.Endianness={BIG_ENDIAN:0,LITTLE_ENDIAN:Ng};function Pg(){this.i=[];this.h=[];this.g=!1}q=Pg.prototype;q.box=function(a,b){a=Qg(a);this.i[a]=Rg;this.h[a]=b;return this};q.W=function(a,b){a=Qg(a);this.i[a]=Sg;this.h[a]=b;return this};q.stop=function(){this.g=!0};q.parse=function(a,b,c){a=new Mg(a,0);for(this.g=!1;a.Ca()&&!this.g;)this.kd(0,a,b,c)};
226
226
  q.kd=function(a,b,c,d){var e=b.Ja();if(d&&e+8>b.getLength())this.g=!0;else{var f=b.T(),g=b.T(),h=Tg(g),k=!1;switch(f){case 0:f=b.getLength()-e;break;case 1:if(d&&b.Ja()+8>b.getLength()){this.g=!0;return}f=b.md();k=!0}var l=this.h[g];if(l){var m=null,n=null;if(this.i[g]==Sg){if(d&&b.Ja()+4>b.getLength()){this.g=!0;return}n=b.T();m=n>>>24;n&=16777215}g=e+f;c&&g>b.getLength()&&(g=b.getLength());d&&g>b.getLength()?this.g=!0:(d=g-b.Ja(),b=0<d?b.Hb(d):new Uint8Array(0),b=new Mg(b,0),l({name:h,parser:this,
227
227
  partialOkay:c||!1,version:m,flags:n,reader:b,size:f,start:e+a,has64BitSize:k}))}else b.skip(Math.min(e+f-b.Ja(),b.getLength()-b.Ja()))}};function Ug(a){for(var b=Vg(a);a.reader.Ca()&&!a.parser.g;)a.parser.kd(a.start+b,a.reader,a.partialOkay)}function Wg(a){for(var b=Vg(a),c=a.reader.T(),d=0;d<c&&(a.parser.kd(a.start+b,a.reader,a.partialOkay),!a.parser.g);d++);}function Xg(a){var b=Vg(a);for(a.reader.skip(78);a.reader.Ca()&&!a.parser.g;)a.parser.kd(a.start+b,a.reader,a.partialOkay)}
228
228
  function Yg(a){var b=Vg(a);a.reader.skip(8);var c=a.reader.wa();a.reader.skip(6);2==c?a.reader.skip(48):a.reader.skip(12);for(1==c&&a.reader.skip(16);a.reader.Ca()&&!a.parser.g;)a.parser.kd(a.start+b,a.reader,a.partialOkay)}function Zg(a){return function(b){a(b.reader.Hb(b.reader.getLength()-b.reader.Ja()))}}function Qg(a){var b=0;a=t(a);for(var c=a.next();!c.done;c=a.next())b=b<<8|c.value.charCodeAt(0);return b}function Tg(a){return String.fromCharCode(a>>24&255,a>>16&255,a>>8&255,a&255)}
@@ -246,14 +246,14 @@ function yh(a){var b=/([0-9]+)-([0-9]+)/.exec(a);if(!b)return null;a=Number(b[1]
246
246
  function Eh(a){var b;var c=(b=a.match(/^(\d+)\/(\d+)$/))?Number(b[1])/Number(b[2]):Number(a);return isNaN(c)?null:c}
247
247
  function Fh(a){var b=[];a=Dc(a).split(/\/+(?=(?:[^'"]*['"][^'"]*['"])*[^'"]*$)/);a=t(a);for(var c=a.next();!c.done;c=a.next()){c=c.value;var d=c.match(/^([\w]+)/);if(d){var e=c.match(/(@id='(.*?)')/),f=c.match(/\[(\d+)\]/);b.push({name:d[0],id:e?e[0].match(/'(.*?)'/)[0].replace(/'/gm,""):null,position:f?Number(f[1])-1:null,ec:c.split("/@")[1]||null})}else c.startsWith("@")&&b.length&&(b[b.length-1].ec=c.slice(1))}return b}
248
248
  function Gh(a,b){var c=Fh(b.attributes.sel||"");if(c.length){var d=c[c.length-1],e=b.attributes.pos||null;c=d.position;null===c?c="prepend"===e?0:a.length:"prepend"===e?--c:"after"===e&&++c;e=b.tagName;(d=d.ec)?Hh(a[c],e,d,mh(b)||""):("remove"!==e&&"replace"!==e||a.splice(c,1),"add"!==e&&"replace"!==e||a.splice.apply(a,[c,0].concat(x(b.children))))}}function Hh(a,b,c,d){if("remove"===b)delete a.attributes[c];else if("add"===b||"replace"===b)a.attributes[c]=d}
249
- function Ih(a,b,c){b=void 0===b?!0:b;c=void 0===c?!0:c;var d=document.createElement(a.tagName),e;for(e in a.attributes)d.setAttribute(e,a.attributes[e]);b&&a.parent&&"?xml"!=a.parent.tagName&&Ih(a.parent,!0,!1).appendChild(d);if(c)for(a=t(a.children),b=a.next();!b.done;b=a.next())b=b.value,c=void 0,"string"==typeof b?c=new Text(b):c=Ih(b,!1,!0),d.appendChild(c);return d}var hh=new Map([]);function Jh(a){var b=this;this.G=a;this.J=new Set;this.m=this.u=null;this.ha=this.ba=!1;this.K=0;this.g=null;this.F=new od;this.i=new Map;this.A=new Map;this.l=new lg;this.h=null;this.o=function(c){2==c.severity&&b.l.reject(c);a.onError(c)};this.Z=new Map;this.ea=new Map;this.N=new Ub(function(){return Kh(b)});this.R=!1;this.O=[];this.S=!1;this.L=new Ub(function(){Lh(b)});this.l.catch(function(){});this.j=new Ig(function(){return Mh(b)});this.$=!1;this.H=this.I=null}q=Jh.prototype;q.destroy=function(){return this.j.destroy()};
249
+ function Ih(a,b,c){b=void 0===b?!0:b;c=void 0===c?!0:c;var d=document.createElement(a.tagName),e;for(e in a.attributes)d.setAttribute(e,a.attributes[e]);b&&a.parent&&"?xml"!=a.parent.tagName&&Ih(a.parent,!0,!1).appendChild(d);if(c)for(a=t(a.children),b=a.next();!b.done;b=a.next())b=b.value,c=void 0,"string"==typeof b?c=new Text(b):c=Ih(b,!1,!0),d.appendChild(c);return d}var hh=new Map([]);function Jh(a){var b=this;this.G=a;this.J=new Set;this.m=this.u=null;this.ha=this.ba=!1;this.K=0;this.g=null;this.F=new od;this.i=new Map;this.A=new Map;this.l=new lg;this.h=null;this.o=function(c){2==c.severity&&b.l.reject(c);a.onError(c)};this.X=new Map;this.ea=new Map;this.N=new Ub(function(){return Kh(b)});this.R=!1;this.O=[];this.S=!1;this.L=new Ub(function(){Lh(b)});this.l.catch(function(){});this.j=new Ig(function(){return Mh(b)});this.$=!1;this.H=this.I=null}q=Jh.prototype;q.destroy=function(){return this.j.destroy()};
250
250
  function Mh(a){return O(function(b){switch(b.g){case 1:return a.F.release(),a.F=null,a.l.reject(),a.L.stop(),a.L=null,a.N.stop(),a.N=null,E(b,Nh(a),2);case 2:if(!a.m){b.B(3);break}ta(b,4);return E(b,a.m.setMediaKeys(null),6);case 6:va(b,5);break;case 4:wa(b);case 5:a.m=null;case 3:a.g=null,a.J.clear(),a.u=null,a.A=new Map,a.h=null,a.o=function(){},a.G=null,a.$=!1,a.I=null,F(b)}})}q.configure=function(a){this.h=a;this.L&&this.L.za(this.h.updateExpirationTime)};
251
251
  function Oh(a,b,c){a.ha=!0;a.A=new Map;a.R=c;return Ph(a,b)}function Qh(a,b,c){a.A=new Map;c=t(c);for(var d=c.next();!d.done;d=c.next())a.A.set(d.value,{initData:null,initDataType:null});c=t(a.h.persistentSessionsMetadata);for(d=c.next();!d.done;d=c.next())d=d.value,a.A.set(d.sessionId,{initData:d.initData,initDataType:d.initDataType});a.R=0<a.A.size;return Ph(a,b)}
252
252
  function Rh(a,b,c,d,e,f){var g=new Map;e={audioCapabilities:e,videoCapabilities:f,distinctiveIdentifier:"optional",persistentState:"required",sessionTypes:["persistent-license"],label:b};e.drmInfos=[{keySystem:b,licenseServerUri:c,distinctiveIdentifierRequired:!1,persistentStateRequired:!0,audioRobustness:"",videoRobustness:"",serverCertificate:d,serverCertificateUri:"",initData:null,keyIds:null}];g.set(b,e);return Sh(a,g,[])}
253
253
  function Ph(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z;return O(function(C){if(1==C.g){if(c=Th(a))for(d=t(b),e=d.next();!e.done;e=d.next())f=e.value,f.video&&(f.video.drmInfos=[c]),f.audio&&(f.audio.drmInfos=[c]);g=b.some(function(y){return y.video&&y.video.drmInfos.length||y.audio&&y.audio.drmInfos.length?!0:!1});g||(h=Kg(a.h.servers),Uh(b,h));k=new Set;l=t(b);for(e=l.next();!e.done;e=l.next())for(m=e.value,n=Vh(m),p=t(n),r=p.next();!r.done;r=p.next())u=r.value,k.add(u);v=t(k);for(r=v.next();!r.done;r=
254
254
  v.next())w=r.value,Wh(w,Kg(a.h.servers),Kg(a.h.advanced||{}),a.h.keySystemsMapping);return E(C,jf(b,a.R,a.$,a.h.preferredKeySystems),2)}Jg(a.j);A=g||Object.keys(a.h.servers).length;if(!A)return a.ba=!0,C.return(Promise.resolve());z=Sh(a,void 0,b);return C.return(g?z:z.catch(function(){}))})}
255
255
  function Xh(a){var b;return O(function(c){switch(c.g){case 1:if(a.m.mediaKeys)return c.return();if(!a.I){c.B(2);break}return E(c,a.I,3);case 3:return Jg(a.j),c.return();case 2:return ta(c,4),a.I=a.m.setMediaKeys(a.u),E(c,a.I,6);case 6:va(c,5);break;case 4:b=wa(c),a.o(new U(2,6,6003,b.message));case 5:Jg(a.j),F(c)}})}function Yh(a,b){return O(function(c){if(1==c.g)return E(c,Xh(a),2);Zh(a,b.initDataType,Gb(b.initData));F(c)})}
256
- q.tc=function(a){var b=this;return O(function(c){if(1==c.g){if(!b.u)return b.F.oa(a,"encrypted",function(){b.o(new U(2,6,6010))}),c.return();b.m=a;b.F.oa(b.m,"play",function(){for(var d=t(b.O),e=d.next();!e.done;e=d.next())$h(b,e.value);b.S=!0;b.O=[]});"webkitCurrentPlaybackTargetIsWireless"in b.m&&b.F.s(b.m,"webkitcurrentplaybacktargetiswirelesschanged",function(){return Nh(b)});b.H=b.g?b.g.initData.find(function(d){return 0<d.initData.length})||null:null;return b.H||"com.apple.fps"!==b.g.keySystem||
256
+ q.vc=function(a){var b=this;return O(function(c){if(1==c.g){if(!b.u)return b.F.oa(a,"encrypted",function(){b.o(new U(2,6,6010))}),c.return();b.m=a;b.F.oa(b.m,"play",function(){for(var d=t(b.O),e=d.next();!e.done;e=d.next())$h(b,e.value);b.S=!0;b.O=[]});"webkitCurrentPlaybackTargetIsWireless"in b.m&&b.F.s(b.m,"webkitcurrentplaybacktargetiswirelesschanged",function(){return Nh(b)});b.H=b.g?b.g.initData.find(function(d){return 0<d.initData.length})||null:null;return b.H||"com.apple.fps"!==b.g.keySystem||
257
257
  b.A.size?E(c,Xh(b),2):c.B(2)}ai(b).catch(function(){});b.H||b.A.size||b.h.parseInbandPsshEnabled||b.F.s(b.m,"encrypted",function(d){return Yh(b,d)});F(c)})};
258
258
  function bi(a){var b,c,d,e,f;return O(function(g){switch(g.g){case 1:if(!a.u||!a.g)return g.return();if(!a.g.serverCertificateUri||a.g.serverCertificate&&a.g.serverCertificate.length){g.B(2);break}b=Ag([a.g.serverCertificateUri],a.h.retryParameters);ta(g,3);c=a.G.Zb.request(5,b);return E(g,c.promise,5);case 5:d=g.h;a.g.serverCertificate=Gb(d.data);va(g,4);break;case 3:throw e=wa(g),new U(2,6,6017,e);case 4:if(a.j.g)return g.return();case 2:if(!a.g.serverCertificate||!a.g.serverCertificate.length)return g.return();
259
259
  ta(g,6);return E(g,a.u.setServerCertificate(a.g.serverCertificate),8);case 8:va(g,0);break;case 6:throw f=wa(g),new U(2,6,6004,f.message);}})}function ci(a,b){var c,d,e;return O(function(f){if(1==f.g)return E(f,di(a,b,{initData:null,initDataType:null}),2);if(3!=f.g){c=f.h;if(!c)return f.return();d=[];if(e=a.i.get(c))e.Bb=new lg,d.push(e.Bb);d.push(c.remove());return E(f,Promise.all(d),3)}a.i.delete(c);F(f)})}
@@ -278,17 +278,17 @@ function $h(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v;O(function(w){switch(w.g){case
278
278
  f.headers[h];if(Qb(a.g.keySystem)){var A=xc(g.body,!0,!0);if(A.includes("PlayReadyKeyMessage")){A=ch(A,"PlayReadyKeyMessage");var z=nh(A,"HttpHeader");z=t(z);for(var C=z.next();!C.done;C=z.next()){var y=C.value;C=nh(y,"name")[0];y=nh(y,"value")[0];g.headers[lh(C)]=lh(y)}A=nh(A,"Challenge")[0];g.body=Hc(lh(A))}else g.headers["Content-Type"]="text/xml; charset=utf-8"}k=Date.now();ta(w,2);m=a.G.Zb.request(2,g);return E(w,m.promise,4);case 4:l=w.h;va(w,3);break;case 2:n=wa(w);if(a.j.g)return w.return();
279
279
  p=new U(2,6,6007,n);1==a.i.size?(a.o(p),d&&d.Bb&&d.Bb.reject(p)):(d&&d.Bb&&d.Bb.reject(p),a.i.delete(c),fi(a)&&(a.l.resolve(),a.N.V(.1)));return w.return();case 3:if(a.j.g)return w.return();a.K+=(Date.now()-k)/1E3;a.h.logLicenseExchange&&Gc(l.data);ta(w,5);return E(w,c.update(l.data),7);case 7:va(w,6);break;case 5:return r=wa(w),u=new U(2,6,6008,r.message),a.o(u),d&&d.Bb&&d.Bb.reject(u),w.return();case 6:if(a.j.g)return w.return();v=new S("drmsessionupdate");a.G.onEvent(v);d&&(d.Bb&&d.Bb.resolve(),
280
280
  mi(a,d));F(w)}})}
281
- function oi(a,b){b=b.target;var c=a.i.get(b),d=!1;b.keyStatuses.forEach(function(f,g){if("string"==typeof g){var h=g;g=f;f=h}if(Qb(a.g.keySystem)&&16==g.byteLength&&(Yb()||jc())){h=Lb(g);var k=h.getUint32(0,!0),l=h.getUint16(4,!0),m=h.getUint16(6,!0);h.setUint32(0,k,!1);h.setUint16(4,l,!1);h.setUint16(6,m,!1)}"status-pending"!=f&&(c.loaded=!0);"expired"==f&&(d=!0);g=Jc(g).slice(0,32);a.Z.set(g,f)});var e=b.expiration-Date.now();(0>e||d&&1E3>e)&&c&&!c.Bb&&(a.i.delete(b),b.close().catch(function(){}));fi(a)&&
282
- (a.l.resolve(),a.N.V(pi))}function Kh(a){var b=a.Z,c=a.ea;c.clear();b.forEach(function(d,e){return c.set(e,d)});b=Array.from(c.values());b.length&&b.every(function(d){return"expired"==d})&&a.o(new U(2,6,6014));a.G.bf(Lg(c))}
281
+ function oi(a,b){b=b.target;var c=a.i.get(b),d=!1;b.keyStatuses.forEach(function(f,g){if("string"==typeof g){var h=g;g=f;f=h}if(Qb(a.g.keySystem)&&16==g.byteLength&&(Yb()||jc())){h=Lb(g);var k=h.getUint32(0,!0),l=h.getUint16(4,!0),m=h.getUint16(6,!0);h.setUint32(0,k,!1);h.setUint16(4,l,!1);h.setUint16(6,m,!1)}"status-pending"!=f&&(c.loaded=!0);"expired"==f&&(d=!0);g=Jc(g).slice(0,32);a.X.set(g,f)});var e=b.expiration-Date.now();(0>e||d&&1E3>e)&&c&&!c.Bb&&(a.i.delete(b),b.close().catch(function(){}));fi(a)&&
282
+ (a.l.resolve(),a.N.V(pi))}function Kh(a){var b=a.X,c=a.ea;c.clear();b.forEach(function(d,e){return c.set(e,d)});b=Array.from(c.values());b.length&&b.every(function(d){return"expired"==d})&&a.o(new U(2,6,6014));a.G.bf(Lg(c))}
283
283
  function qi(){var a,b,c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J;return O(function(I){if(1==I.g){a="org.w3.clearkey com.widevine.alpha com.microsoft.playready com.microsoft.playready.hardware com.microsoft.playready.recommendation com.chromecast.playready com.apple.fps.1_0 com.apple.fps".split(" ");b=["SW_SECURE_CRYPTO","SW_SECURE_DECODE","HW_SECURE_CRYPTO","HW_SECURE_DECODE","HW_SECURE_ALL"];c=["150","2000","3000"];d={"com.widevine.alpha":b,"com.microsoft.playready.recommendation":c};e=[{contentType:'video/mp4; codecs="avc1.42E01E"'},
284
- {contentType:'video/webm; codecs="vp8"'}];f=[{contentType:'audio/mp4; codecs="mp4a.40.2"'},{contentType:'audio/webm; codecs="opus"'}];g={videoCapabilities:e,audioCapabilities:f,initDataTypes:["cenc","sinf","skd","keyids"]};h=[null,"cenc","cbcs","cbcs-1-9"];k=new Map;l=function(H,N){var L,M,Q,T,R,ra,sa,Ca;return O(function(Ea){switch(Ea.g){case 1:return ta(Ea,2),E(Ea,N.createMediaKeys(),4);case 4:va(Ea,3);break;case 2:return wa(Ea),Ea.return();case 3:M=(L=N.getConfiguration().sessionTypes)?L.includes("persistent-license"):
284
+ {contentType:'video/webm; codecs="vp8"'}];f=[{contentType:'audio/mp4; codecs="mp4a.40.2"'},{contentType:'audio/webm; codecs="opus"'}];g={videoCapabilities:e,audioCapabilities:f,initDataTypes:["cenc","sinf","skd","keyids"]};h=[null,"cenc","cbcs","cbcs-1-9"];k=new Map;l=function(H,N){var L,M,Q,T,R,ra,sa,Ca;return O(function(Fa){switch(Fa.g){case 1:return ta(Fa,2),E(Fa,N.createMediaKeys(),4);case 4:va(Fa,3);break;case 2:return wa(Fa),Fa.return();case 3:M=(L=N.getConfiguration().sessionTypes)?L.includes("persistent-license"):
285
285
  !1,bc()&&(M=!1),Q=N.getConfiguration().videoCapabilities,T=N.getConfiguration().audioCapabilities,R={persistentState:M,encryptionSchemes:[],videoRobustnessLevels:[],audioRobustnessLevels:[]},k.has(H)&&k.get(H)?R=k.get(H):k.set(H,R),(ra=Q[0].encryptionScheme)&&!R.encryptionSchemes.includes(ra)&&R.encryptionSchemes.push(ra),(sa=Q[0].robustness)&&!R.videoRobustnessLevels.includes(sa)&&R.videoRobustnessLevels.push(sa),(Ca=T[0].robustness)&&!R.audioRobustnessLevels.includes(Ca)&&R.audioRobustnessLevels.push(Ca),
286
- F(Ea)}})};m=function(H,N,L,M){var Q,T,R,ra,sa,Ca,Ea,Ia,Pa;return O(function(Ja){switch(Ja.g){case 1:ta(Ja,2);Q=Xe(g);T=t(Q.videoCapabilities);for(R=T.next();!R.done;R=T.next())ra=R.value,ra.encryptionScheme=N,ra.robustness=L;sa=t(Q.audioCapabilities);for(R=sa.next();!R.done;R=sa.next())Ca=R.value,Ca.encryptionScheme=N,Ca.robustness=M;Ea=Xe(Q);Ea.persistentState="required";Ea.sessionTypes=["persistent-license"];Ia=[Ea,Q];return E(Ja,navigator.requestMediaKeySystemAccess(H,Ia),4);case 4:return Pa=Ja.h,
286
+ F(Fa)}})};m=function(H,N,L,M){var Q,T,R,ra,sa,Ca,Fa,Ia,Pa;return O(function(Ja){switch(Ja.g){case 1:ta(Ja,2);Q=Xe(g);T=t(Q.videoCapabilities);for(R=T.next();!R.done;R=T.next())ra=R.value,ra.encryptionScheme=N,ra.robustness=L;sa=t(Q.audioCapabilities);for(R=sa.next();!R.done;R=sa.next())Ca=R.value,Ca.encryptionScheme=N,Ca.robustness=M;Fa=Xe(Q);Fa.persistentState="required";Fa.sessionTypes=["persistent-license"];Ia=[Fa,Q];return E(Ja,navigator.requestMediaKeySystemAccess(H,Ia),4);case 4:return Pa=Ja.h,
287
287
  E(Ja,l(H,Pa),5);case 5:va(Ja,0);break;case 2:wa(Ja),F(Ja)}})};n=function(H,N,L,M){var Q,T,R;return O(function(ra){switch(ra.g){case 1:return ta(ra,2),Q={type:"media-source",video:{contentType:e[0].contentType,width:640,height:480,bitrate:1,framerate:1},audio:{contentType:f[0].contentType,channels:2,bitrate:1,samplerate:1},keySystemConfiguration:{keySystem:H,video:{encryptionScheme:N,robustness:L},audio:{encryptionScheme:N,robustness:M}}},E(ra,navigator.mediaCapabilities.decodingInfo(Q),4);case 4:return T=
288
288
  ra.h,R=T.keySystemAccess,E(ra,l(H,R),5);case 5:va(ra,0);break;case 2:wa(ra),F(ra)}})};p=t(a);for(r=p.next();!r.done;r=p.next())u=r.value,k.set(u,null);v=[];w=t(h);for(A=w.next();!A.done;A=w.next())for(z=A.value,C=t(a),r=C.next();!r.done;r=C.next())y=r.value,"org.w3.clearkey"===y&&mc()||(v.push(m(y,z,"","")),v.push(n(y,z,"","")));B=t(a);for(r=B.next();!r.done;r=B.next())for(D=r.value,K=t(d[D]||[]),G=K.next();!G.done;G=K.next())J=G.value,v.push(m(D,null,J,"")),v.push(m(D,null,"",J)),v.push(n(D,null,
289
289
  J,"")),v.push(n(D,null,"",J));return E(I,Promise.all(v),2)}return I.return(Lg(k))})}function ri(a){var b;return O(function(c){if(1==c.g)return b=new Promise(function(d,e){(new Ub(e)).V(si)}),ta(c,2),E(c,Promise.race([Promise.all([a.close(),a.closed]),b]),4);if(2!=c.g)return va(c,0);wa(c);F(c)})}
290
290
  function Nh(a){var b;return O(function(c){b=Array.from(a.i.entries());a.i.clear();return E(c,Promise.all(b.map(function(d){d=t(d);var e=d.next().value,f=d.next().value;return O(function(g){if(1==g.g)return ta(g,2),a.ha||a.A.has(e.sessionId)||"persistent-license"!==f.type||a.h.persistentSessionOnlinePlayback?E(g,ri(e),5):E(g,e.remove(),5);if(2!=g.g)return va(g,0);wa(g);F(g)})})),0)})}function Vh(a){return(a.video?a.video.drmInfos:[]).concat(a.audio?a.audio.drmInfos:[])}
291
- function Lh(a){a.i.forEach(function(b,c){var d=b.Lg,e=c.expiration;isNaN(e)&&(e=Infinity);e!=d&&(a.G.onExpirationUpdated(c.sessionId,e),b.Lg=e)})}function fi(a){a=a.i.values();return ib(a,function(b){return b.loaded})}function ei(a){for(var b=t(a.g&&a.g.keyIds||new Set([])),c=b.next();!c.done;c=b.next())if("usable"!==a.Z.get(c.value))return!1;return!0}
291
+ function Lh(a){a.i.forEach(function(b,c){var d=b.Lg,e=c.expiration;isNaN(e)&&(e=Infinity);e!=d&&(a.G.onExpirationUpdated(c.sessionId,e),b.Lg=e)})}function fi(a){a=a.i.values();return ib(a,function(b){return b.loaded})}function ei(a){for(var b=t(a.g&&a.g.keyIds||new Set([])),c=b.next();!c.done;c=b.next())if("usable"!==a.X.get(c.value))return!1;return!0}
292
292
  function Uh(a,b){var c=[];b.forEach(function(d,e){c.push({keySystem:e,licenseServerUri:d,distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,serverCertificateUri:"",initData:[],keyIds:new Set})});a=t(a);for(b=a.next();!b.done;b=a.next())b=b.value,b.video&&(b.video.drmInfos=c),b.audio&&(b.audio.drmInfos=c)}
293
293
  function ki(a,b,c,d,e,f,g){var h=[],k={};a=t(a);for(var l=a.next();!l.done;k={Fa:k.Fa},l=a.next()){k.Fa=l.value;b.includes(k.Fa.encryptionScheme)||b.push(k.Fa.encryptionScheme);"org.w3.clearkey"==k.Fa.keySystem&&k.Fa.licenseServerUri.startsWith("data:application/json;base64,")?h.includes(k.Fa.licenseServerUri)||h.push(k.Fa.licenseServerUri):c.includes(k.Fa.licenseServerUri)||c.push(k.Fa.licenseServerUri);e.includes(k.Fa.serverCertificateUri)||e.push(k.Fa.serverCertificateUri);k.Fa.serverCertificate&&
294
294
  (d.some(function(p){return function(r){return Eb(r,p.Fa.serverCertificate)}}(k))||d.push(k.Fa.serverCertificate));if(k.Fa.initData){l={};for(var m=t(k.Fa.initData),n=m.next();!n.done;l={se:l.se},n=m.next())l.se=n.value,f.some(function(p){return function(r){var u=p.se;return r.keyId&&r.keyId==u.keyId?!0:r.initDataType==u.initDataType&&Eb(r.initData,u.initData)}}(l))||f.push(l.se)}if(k.Fa.keyIds)for(l=t(k.Fa.keyIds),m=l.next();!m.done;m=l.next())g.add(m.value)}if(1==h.length)c.push(h[0]);else if(0<
@@ -310,11 +310,11 @@ function Di(a,b,c,d,e){var f=Ei.value(),g=a.subarray(c.start,c.start+c.size),h=L
310
310
  a=k.getUint32(b);k.setUint32(b,a+1);return e}function Fi(a,b,c){a=Lb(a,b);b=a.getUint32(0);0!=b&&(1==b?(a.setUint32(8,c>>32),a.setUint32(12,c&4294967295)):a.setUint32(0,c))}var Ei=new Nb(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 Gi(a,b,c,d,e,f,g){this.P=a;this.Wa=b;this.Da=c;this.Ig=void 0===d?null:d;this.timescale=void 0===e?null:e;this.g=void 0===f?null:f;this.aesKey=void 0===g?null:g;this.mimeType=this.codecs=null}Gi.prototype.Pb=function(){return this.Wa};Gi.prototype.Nb=function(){return this.Da};Gi.prototype.Sd=function(){return this.g};function Hi(a,b){return a===b?!0:a&&b?a.Pb()==b.Pb()&&a.Nb()==b.Nb()&&Qd(a.P().sort(),b.P().sort())&&Eb(a.Sd(),b.Sd()):a==b}P("shaka.media.InitSegmentReference",Gi);
311
311
  Gi.prototype.getEndByte=Gi.prototype.Nb;Gi.prototype.getStartByte=Gi.prototype.Pb;
312
312
  function Ii(a,b,c,d,e,f,g,h,k,l,m,n,p,r,u,v){l=void 0===l?[]:l;r=void 0===r?Ji:r;this.startTime=a;this.i=this.endTime=b;this.G=c;this.Wa=d;this.Da=e;this.sa=f;this.timestampOffset=g;this.appendWindowStart=h;this.appendWindowEnd=k;this.g=l;this.tilesLayout=void 0===m?"":m;this.A=void 0===n?null:n;this.h=void 0===p?null:p;this.status=r;this.preload=!1;this.l=!0;this.m=!1;this.aesKey=void 0===u?null:u;this.u=null;this.j=0;this.o=void 0===v?!1:v;this.Te=this.fe=!1;a=t(this.g);for(b=a.next();!b.done;b=
313
- a.next())b.value.Sh();this.o&&this.g.length&&this.g[this.g.length-1].Rh();this.F=this.mimeType=this.codecs=null}q=Ii.prototype;q.P=function(){return this.G()};q.getStartTime=function(){return this.startTime};q.aj=function(){return this.endTime};q.Pb=function(){return this.Wa};q.Nb=function(){return this.Da};q.uj=function(){return this.tilesLayout};q.tj=function(){return this.A};q.zc=function(){return this.status};q.Rj=function(){this.status=Ki};q.Hg=function(){this.preload=!0};q.Jj=function(){return this.preload};
313
+ a.next())b.value.Sh();this.o&&this.g.length&&this.g[this.g.length-1].Rh();this.F=this.mimeType=this.codecs=null}q=Ii.prototype;q.P=function(){return this.G()};q.getStartTime=function(){return this.startTime};q.aj=function(){return this.endTime};q.Pb=function(){return this.Wa};q.Nb=function(){return this.Da};q.uj=function(){return this.tilesLayout};q.tj=function(){return this.A};q.Ac=function(){return this.status};q.Rj=function(){this.status=Ki};q.Hg=function(){this.preload=!0};q.Jj=function(){return this.preload};
314
314
  q.Ve=function(){this.l=!1};q.Gj=function(){return this.l};q.Sh=function(){this.fe=!0};q.Ij=function(){return this.fe};q.Rh=function(){this.Te=!0};q.Hj=function(){return this.Te};q.Qh=function(){this.m=!0};q.Cj=function(){return this.m};q.ji=function(a){this.u=a};q.sj=function(){return this.u};q.offset=function(a){this.startTime+=a;this.endTime+=a;this.i+=a;for(var b=t(this.g),c=b.next();!c.done;c=b.next())c=c.value,c.startTime+=a,c.endTime+=a,c.i+=a};
315
315
  q.fh=function(a){null==this.h?Xa("Sync attempted without sync time!"):(a=this.h-a-this.startTime,.001<=Math.abs(a)&&this.offset(a))};q.zk=function(a){this.F=a};q.Sd=function(){return this.F};function Li(a,b){a.sa=b;a=t(a.g);for(var c=a.next();!c.done;c=a.next())Li(c.value,b)}P("shaka.media.SegmentReference",Ii);Ii.prototype.getSegmentData=Ii.prototype.Sd;Ii.prototype.setSegmentData=Ii.prototype.zk;Ii.prototype.syncAgainst=Ii.prototype.fh;Ii.prototype.offset=Ii.prototype.offset;
316
316
  Ii.prototype.getThumbnailSprite=Ii.prototype.sj;Ii.prototype.setThumbnailSprite=Ii.prototype.ji;Ii.prototype.hasByterangeOptimization=Ii.prototype.Cj;Ii.prototype.markAsByterangeOptimization=Ii.prototype.Qh;Ii.prototype.isLastPartial=Ii.prototype.Hj;Ii.prototype.markAsLastPartial=Ii.prototype.Rh;Ii.prototype.isPartial=Ii.prototype.Ij;Ii.prototype.markAsPartial=Ii.prototype.Sh;Ii.prototype.isIndependent=Ii.prototype.Gj;Ii.prototype.markAsNonIndependent=Ii.prototype.Ve;Ii.prototype.isPreload=Ii.prototype.Jj;
317
- Ii.prototype.markAsPreload=Ii.prototype.Hg;Ii.prototype.markAsUnavailable=Ii.prototype.Rj;Ii.prototype.getStatus=Ii.prototype.zc;Ii.prototype.getTileDuration=Ii.prototype.tj;Ii.prototype.getTilesLayout=Ii.prototype.uj;Ii.prototype.getEndByte=Ii.prototype.Nb;Ii.prototype.getStartByte=Ii.prototype.Pb;Ii.prototype.getEndTime=Ii.prototype.aj;Ii.prototype.getStartTime=Ii.prototype.getStartTime;Ii.prototype.getUris=Ii.prototype.P;var Ji=0,Ki=1;Ii.Status={Jk:Ji,Il:Ki,cl:2};function Mi(a){return 1==a.length&&1E-4>a.end(0)-a.start(0)}function Ni(a){return!a||Mi(a)?null:a.length?a.end(a.length-1):null}function Oi(a,b){return!a||!a.length||Mi(a)||b>a.end(a.length-1)?!1:b>=a.start(0)}function Pi(a,b){if(!a||!a.length||Mi(a))return 0;var c=0;a=t(Qi(a));for(var d=a.next();!d.done;d=a.next()){var e=d.value;d=e.start;e=e.end;e>b&&(c+=e-Math.max(d,b))}return c}
317
+ Ii.prototype.markAsPreload=Ii.prototype.Hg;Ii.prototype.markAsUnavailable=Ii.prototype.Rj;Ii.prototype.getStatus=Ii.prototype.Ac;Ii.prototype.getTileDuration=Ii.prototype.tj;Ii.prototype.getTilesLayout=Ii.prototype.uj;Ii.prototype.getEndByte=Ii.prototype.Nb;Ii.prototype.getStartByte=Ii.prototype.Pb;Ii.prototype.getEndTime=Ii.prototype.aj;Ii.prototype.getStartTime=Ii.prototype.getStartTime;Ii.prototype.getUris=Ii.prototype.P;var Ji=0,Ki=1;Ii.Status={Jk:Ji,Il:Ki,cl:2};function Mi(a){return 1==a.length&&1E-4>a.end(0)-a.start(0)}function Ni(a){return!a||Mi(a)?null:a.length?a.end(a.length-1):null}function Oi(a,b){return!a||!a.length||Mi(a)||b>a.end(a.length-1)?!1:b>=a.start(0)}function Pi(a,b){if(!a||!a.length||Mi(a))return 0;var c=0;a=t(Qi(a));for(var d=a.next();!d.done;d=a.next()){var e=d.value;d=e.start;e=e.end;e>b&&(c+=e-Math.max(d,b))}return c}
318
318
  function Ri(a,b,c){if(!a||!a.length||Mi(a))return null;a=Qi(a).findIndex(function(d,e,f){return d.start>b&&(0==e||f[e-1].end-b<=c)});return 0<=a?a:null}function Qi(a){if(!a)return[];for(var b=[],c=0;c<a.length;c++)b.push({start:a.start(c),end:a.end(c)});return b};/*
319
319
  @license
320
320
  Shaka Player
@@ -346,7 +346,7 @@ function fj(a,b){b=void 0===b?!1:b;a=a.toString(16).toUpperCase();return b?a:("0
346
346
  limitations under the License.
347
347
  */
348
348
  function hj(a,b){this.j=a;if(void 0===b?0:b){b=new Uint8Array(a.byteLength);for(var c=0,d=0;d<a.byteLength;d++)2<=d&&3==a[d]&&0==a[d-1]&&0==a[d-2]||(b[c]=a[d],c++);this.j=Gb(b,0,c)}this.i=this.j.byteLength;this.g=this.h=0}function ij(a){var b=a.j.byteLength-a.i,c=new Uint8Array(4),d=Math.min(4,a.i);0!==d&&(c.set(a.j.subarray(b,b+d)),a.h=(new Mg(c,0)).T(),a.g=8*d,a.i-=d)}function jj(a,b){if(a.g<=b){b-=a.g;var c=Math.floor(b/8);b-=8*c;a.g-=c;ij(a)}a.h<<=b;a.g-=b}
349
- function kj(a,b){var c=Math.min(a.g,b),d=a.h>>>32-c;a.g-=c;0<a.g?a.h<<=c:0<a.i&&ij(a);c=b-c;return 0<c?d<<c|kj(a,c):d}function lj(a){var b;for(b=0;b<a.g;++b)if(0!==(a.h&2147483648>>>b))return a.h<<=b,a.g-=b,b;ij(a);return b+lj(a)}function mj(a){jj(a,1+lj(a))}function V(a){var b=lj(a);return kj(a,b+1)-1}function nj(a){a=V(a);return 1&a?1+a>>>1:-1*(a>>>1)}function rj(a){return 1===kj(a,1)}function sj(a){return kj(a,8)}
349
+ function kj(a,b){var c=Math.min(a.g,b),d=a.h>>>32-c;a.g-=c;0<a.g?a.h<<=c:0<a.i&&ij(a);c=b-c;return 0<c?d<<c|kj(a,c):d}function lj(a){var b;for(b=0;b<a.g;++b)if(0!==(a.h&2147483648>>>b))return a.h<<=b,a.g-=b,b;ij(a);return b+lj(a)}function mj(a){jj(a,1+lj(a))}function V(a){var b=lj(a);return kj(a,b+1)-1}function nj(a){a=V(a);return 1&a?1+a>>>1:-1*(a>>>1)}function oj(a){return 1===kj(a,1)}function sj(a){return kj(a,8)}
350
350
  function tj(a,b){for(var c=8,d=8,e=0;e<b;e++)0!==d&&(d=nj(a),d=(c+d+256)%256),c=0===d?c:d}function uj(a){sj(a);V(a);return V(a)}P("shaka.util.ExpGolomb",hj);function vj(){this.I=null;this.J=!1;this.m=this.K=null;this.j=[];this.g=[];this.A=this.F=null;this.i=[];this.h=[];this.G=null;this.l=[];this.H=this.o=this.u=null}q=vj.prototype;q.clearData=function(){this.j=[];this.g=[];this.i=[];this.h=[];this.l=[]};
351
351
  q.parse=function(a){if(564>a.length)return this;for(var b=Math.max(0,wj(a)),c=a.length-(a.length+b)%188,d=!1,e=b;e<c;e+=188)if(71==a[e]){var f=!!(a[e+1]&64),g=((a[e+1]&31)<<8)+a[e+2];if(1<(a[e+3]&48)>>4){var h=e+5+a[e+4];if(h==e+188)continue}else h=e+4;switch(g){case 0:f&&(h+=a[h]+1);this.I=(a[h+10]&31)<<8|a[h+11];break;case 17:case 8191:break;case this.I:f&&(h+=a[h]+1);f=a;g={audio:-1,video:-1,Qe:-1,audioCodec:"",videoCodec:""};var k=h+3+((f[h+1]&15)<<8|f[h+2])-4;for(h+=12+((f[h+10]&15)<<8|f[h+11]);h<
352
352
  k;){var l=(f[h+1]&31)<<8|f[h+2],m=(f[h+3]&15)<<8|f[h+4];switch(f[h]){case 6:if(0<m)for(var n=h+5,p=m;2<p;){var r=f[n+1]+2;switch(f[n]){case 5:var u=yc(f.subarray(n+2,n+r));-1==g.audio&&"Opus"===u?(g.audio=l,g.audioCodec="opus"):-1==g.video&&"AV01"===u&&(g.video=l,g.videoCodec="av1");break;case 106:-1==g.audio&&(g.audio=l,g.audioCodec="ac3");break;case 122:-1==g.audio&&(g.audio=l,g.audioCodec="ec3");break;case 124:-1==g.audio&&(g.audio=l,g.audioCodec="aac");break;case 127:"opus"==g.audioCodec&&(u=
@@ -358,34 +358,34 @@ a.o));a.o=c.dts}a=b[8]+9;if(b.byteLength<=a)return null;c.data=b.subarray(a);ret
358
358
  q.Og=function(a,b,c){var d=a.pts?a.pts/9E4:null;a=a.data;var e=a.byteLength,f=1;"hvc"==this.m&&(f=2);for(var g=c||0,h=[],k=-1,l=0,m,n=0;n<e;++n){var p=a[n];if(p){if(2<=g&&1==p){b&&!h.length&&-1==k&&(p=n-(3<g?3:g),c&&0!=p&&(p=a.subarray(0,p),b.data=Kc(b.data,p),b.fullData=Kc(b.fullData,p)));0<=k?(g=n-((3<g?3:g)+1),h.push({data:a.subarray(k+f,g+1),fullData:a.subarray(k,g+1),type:l,time:d})):b&&!h.length&&(k=n-g,0<k&&(k=a.subarray(0,k),b.data=Kc(b.data,k),b.fullData=Kc(b.fullData,k)));if(n>=e-f)return h;
359
359
  n++;k=n;l="hvc"==this.m?a[n]>>1&63:a[n]&31}g=0}else g++;n>=e-1&&0<=k&&0<=g&&(m={data:a.subarray(k+f,e),fullData:a.subarray(k,e),type:l,time:d})}m&&h.push(m);!h.length&&b&&(b.data=Kc(b.data,a),b.fullData=Kc(b.fullData,a));return h};q.getMetadata=function(){for(var a=[],b=t(this.l),c=b.next();!c.done;c=b.next())c=Kc.apply(Ec,x(c.value)),(c=xj(this,c))&&a.push({cueTime:c.pts?c.pts/9E4:null,data:c.data,frames:Xi(c.data),dts:c.dts,pts:c.pts});return a};
360
360
  q.fc=function(){if(this.i.length&&!this.h.length){for(var a=!1,b=t(this.i),c=b.next();!c.done;c=b.next()){var d=Kc.apply(Ec,x(c.value)),e=xj(this,d);c=this.h.length?this.h[this.h.length-1]:null;e&&null!=e.pts&&null!=e.dts&&(!c||c.pts!=e.pts&&c.dts!=e.dts)?(this.h.length&&e.dts<(c.dts||0)&&(a=!0),this.h.push(e)):this.h.length&&(d=e?e.data:d)&&(c=this.h.pop(),c.data=Kc(c.data,d),this.h.push(c))}a&&(this.h=this.h.sort(function(f,g){var h=(f.pts||0)-(g.pts||0);return(f.dts||0)-(g.dts||0)||h}))}return this.h};
361
- q.bd=function(a){a=void 0===a?!0:a;if(this.j.length&&!this.g.length){for(var b=!1,c=t(this.j),d=c.next();!d.done;d=c.next()){var e=Kc.apply(Ec,x(d.value)),f=xj(this,e);d=this.g.length?this.g[this.g.length-1]:null;f&&null!=f.pts&&null!=f.dts&&(!d||d.pts!=f.pts&&d.dts!=f.dts)?(this.g.length&&f.dts<(d.dts||0)&&(b=!0),this.g.push(f)):this.g.length&&(e=f?f.data:e)&&(d=this.g.pop(),d.data=Kc(d.data,e),this.g.push(d))}if(a){c=[];d=t(this.g);for(e=d.next();!e.done;e=d.next())if(e=e.value,e.nalus=this.Og(e,
362
- g,void 0),e.nalus.length){c.push(e);var g=e.nalus[e.nalus.length-1]}this.g=c}b&&(this.g=this.g.sort(function(h,k){var l=(h.pts||0)-(k.pts||0);return(h.dts||0)-(k.dts||0)||l}))}return a?this.g:(a=this.g,this.g=[],a)};q.getStartTime=function(a){if("audio"==a){a=null;var b=this.fc();b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4);return a}return"video"==a?(a=null,b=this.bd(!1),b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4),a):null};q.Od=function(){return{audio:this.A,video:this.m}};
363
- q.Oe=function(){for(var a=[],b=t(this.bd()),c=b.next();!c.done;c=b.next())a.push.apply(a,x(c.value.nalus));return a};q.zj=function(){xd("TsParser.getVideoResolution","Please use getVideoInfo function instead.");var a=this.wg();return{height:a.height,width:a.width}};q.wg=function(){return"hvc"==this.m?zj(this):Aj(this)};
364
- function Aj(a){var b={height:null,width:null,cb:null};a=a.Oe();if(!a.length)return b;a=a.find(function(p){return 7==p.type});if(!a)return b;a=new hj(a.data);var c=sj(a),d=sj(a),e=sj(a);mj(a);if(Bj.includes(c)){var f=V(a);3===f&&jj(a,1);mj(a);mj(a);jj(a,1);if(rj(a)){f=3!==f?8:12;for(var g=0;g<f;g++)rj(a)&&(6>g?tj(a,16):tj(a,64))}}mj(a);f=V(a);if(0===f)V(a);else if(1===f)for(jj(a,1),mj(a),mj(a),f=V(a),g=0;g<f;g++)mj(a);mj(a);jj(a,1);f=V(a);g=V(a);var h=kj(a,1);0===h&&jj(a,1);jj(a,1);var k=0,l=0,m=0,
365
- n=0;rj(a)&&(k=V(a),l=V(a),m=V(a),n=V(a));b.height=String((2-h)*(g+1)*16-2*m-2*n);b.width=String(16*(f+1)-2*k-2*l);b.cb="avc1."+("0"+c.toString(16).toUpperCase()).slice(-2)+("0"+d.toString(16).toUpperCase()).slice(-2)+("0"+e.toString(16).toUpperCase()).slice(-2);return b}
366
- function zj(a){var b={height:null,width:null,cb:null};a=a.Oe();if(!a.length)return b;a=a.find(function(y){return 33==y.type});if(!a)return b;var c=new hj(a.fullData,!0);sj(c);sj(c);kj(c,4);var d=kj(c,3);rj(c);var e=kj(c,2),f=kj(c,1),g=kj(c,5),h=kj(c,32);a=sj(c);for(var k=sj(c),l=sj(c),m=sj(c),n=sj(c),p=sj(c),r=sj(c),u=[],v=[],w=0;w<d;w++)u.push(rj(c)),v.push(rj(c));if(0<d)for(w=d;8>w;w++)kj(c,2);for(w=0;w<d;w++)u[w]&&kj(c,88),v[w]&&sj(c);V(c);d=V(c);3==d&&kj(c,1);u=V(c);v=V(c);var A=w=0,z=0,C=0;rj(c)&&
361
+ q.cd=function(a){a=void 0===a?!0:a;if(this.j.length&&!this.g.length){for(var b=!1,c=t(this.j),d=c.next();!d.done;d=c.next()){var e=Kc.apply(Ec,x(d.value)),f=xj(this,e);d=this.g.length?this.g[this.g.length-1]:null;f&&null!=f.pts&&null!=f.dts&&(!d||d.pts!=f.pts&&d.dts!=f.dts)?(this.g.length&&f.dts<(d.dts||0)&&(b=!0),this.g.push(f)):this.g.length&&(e=f?f.data:e)&&(d=this.g.pop(),d.data=Kc(d.data,e),this.g.push(d))}if(a){c=[];d=t(this.g);for(e=d.next();!e.done;e=d.next())if(e=e.value,e.nalus=this.Og(e,
362
+ g,void 0),e.nalus.length){c.push(e);var g=e.nalus[e.nalus.length-1]}this.g=c}b&&(this.g=this.g.sort(function(h,k){var l=(h.pts||0)-(k.pts||0);return(h.dts||0)-(k.dts||0)||l}))}return a?this.g:(a=this.g,this.g=[],a)};q.getStartTime=function(a){if("audio"==a){a=null;var b=this.fc();b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4);return a}return"video"==a?(a=null,b=this.cd(!1),b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4),a):null};q.Od=function(){return{audio:this.A,video:this.m}};
363
+ q.Oe=function(){for(var a=[],b=t(this.cd()),c=b.next();!c.done;c=b.next())a.push.apply(a,x(c.value.nalus));return a};q.zj=function(){xd("TsParser.getVideoResolution","Please use getVideoInfo function instead.");var a=this.wg();return{height:a.height,width:a.width}};q.wg=function(){return"hvc"==this.m?zj(this):Aj(this)};
364
+ function Aj(a){var b={height:null,width:null,cb:null};a=a.Oe();if(!a.length)return b;a=a.find(function(p){return 7==p.type});if(!a)return b;a=new hj(a.data);var c=sj(a),d=sj(a),e=sj(a);mj(a);if(Bj.includes(c)){var f=V(a);3===f&&jj(a,1);mj(a);mj(a);jj(a,1);if(oj(a)){f=3!==f?8:12;for(var g=0;g<f;g++)oj(a)&&(6>g?tj(a,16):tj(a,64))}}mj(a);f=V(a);if(0===f)V(a);else if(1===f)for(jj(a,1),mj(a),mj(a),f=V(a),g=0;g<f;g++)mj(a);mj(a);jj(a,1);f=V(a);g=V(a);var h=kj(a,1);0===h&&jj(a,1);jj(a,1);var k=0,l=0,m=0,
365
+ n=0;oj(a)&&(k=V(a),l=V(a),m=V(a),n=V(a));b.height=String((2-h)*(g+1)*16-2*m-2*n);b.width=String(16*(f+1)-2*k-2*l);b.cb="avc1."+("0"+c.toString(16).toUpperCase()).slice(-2)+("0"+d.toString(16).toUpperCase()).slice(-2)+("0"+e.toString(16).toUpperCase()).slice(-2);return b}
366
+ function zj(a){var b={height:null,width:null,cb:null};a=a.Oe();if(!a.length)return b;a=a.find(function(y){return 33==y.type});if(!a)return b;var c=new hj(a.fullData,!0);sj(c);sj(c);kj(c,4);var d=kj(c,3);oj(c);var e=kj(c,2),f=kj(c,1),g=kj(c,5),h=kj(c,32);a=sj(c);for(var k=sj(c),l=sj(c),m=sj(c),n=sj(c),p=sj(c),r=sj(c),u=[],v=[],w=0;w<d;w++)u.push(oj(c)),v.push(oj(c));if(0<d)for(w=d;8>w;w++)kj(c,2);for(w=0;w<d;w++)u[w]&&kj(c,88),v[w]&&sj(c);V(c);d=V(c);3==d&&kj(c,1);u=V(c);v=V(c);var A=w=0,z=0,C=0;oj(c)&&
367
367
  (w+=V(c),A+=V(c),z+=V(c),C+=V(c));b.width=String(u-(w+A)*(1===d||2===d?2:1));b.height=String(v-(z+C)*(1===d?2:1));c=function(y){for(var B=0,D=0;32>D;D++)B|=(y>>D&1)<<31-D;return B>>>0}(h);f=1==f?"H":"L";e="hvc1"+("."+["","A","B","C"][e]+g);e+="."+c.toString(16).toUpperCase();e+="."+f+r;p&&(e+="."+p.toString(16).toUpperCase());n&&(e+="."+n.toString(16).toUpperCase());m&&(e+="."+m.toString(16).toUpperCase());l&&(e+="."+l.toString(16).toUpperCase());k&&(e+="."+k.toString(16).toUpperCase());a&&(e+="."+
368
368
  a.toString(16).toUpperCase());b.cb=e;return b}function yj(a,b){var c=1;for(a>b&&(c=-1);4294967296<Math.abs(b-a);)a+=8589934592*c;return a}function Cj(a){return 0>wj(a)?!1:!0}function wj(a){for(var b=Math.min(1E3,a.length-564),c=0;c<b;){if(71==a[c]&&71==a[c+188]&&71==a[c+376])return c;c++}return-1}P("shaka.util.TsParser",vj);vj.syncOffset=wj;vj.probe=Cj;vj.prototype.getVideoInfo=vj.prototype.wg;vj.prototype.getVideoResolution=vj.prototype.zj;vj.prototype.getVideoNalus=vj.prototype.Oe;
369
- vj.prototype.getCodecs=vj.prototype.Od;vj.prototype.getStartTime=vj.prototype.getStartTime;vj.prototype.getVideoData=vj.prototype.bd;vj.prototype.getAudioData=vj.prototype.fc;vj.prototype.getMetadata=vj.prototype.getMetadata;vj.prototype.parseNalus=vj.prototype.Og;vj.prototype.parseAvcNalus=vj.prototype.Wj;vj.prototype.parse=vj.prototype.parse;vj.prototype.clearData=vj.prototype.clearData;vj.Timescale=9E4;var Bj=[100,110,122,244,44,83,86,118,128,138,139,134];function Dj(a,b,c){this.g=null;this.o=-1;this.l=a;this.i=b;this.m=c;this.j=!1;a:{"undefined"===typeof libDPIModule&&Ya("Could not find LCEVC Library dependencies on this page");if("undefined"!==typeof LCEVCdec)this.h=LCEVCdec;else if("undefined"!==typeof LcevcDil)this.h=LcevcDil,this.j=!0,xd("LcevcDil","lcevc_dil.js is deprecated, please use lcevc_dec.js instead");else{Ya("Could not find LCEVC Library on this page");a=!1;break a}"undefined"===typeof this.h.SupportObject?(Ya("Could not find LCEVC Library on this page"),
369
+ vj.prototype.getCodecs=vj.prototype.Od;vj.prototype.getStartTime=vj.prototype.getStartTime;vj.prototype.getVideoData=vj.prototype.cd;vj.prototype.getAudioData=vj.prototype.fc;vj.prototype.getMetadata=vj.prototype.getMetadata;vj.prototype.parseNalus=vj.prototype.Og;vj.prototype.parseAvcNalus=vj.prototype.Wj;vj.prototype.parse=vj.prototype.parse;vj.prototype.clearData=vj.prototype.clearData;vj.Timescale=9E4;var Bj=[100,110,122,244,44,83,86,118,128,138,139,134];function Dj(a,b,c){this.g=null;this.o=-1;this.l=a;this.i=b;this.m=c;this.j=!1;a:{"undefined"===typeof libDPIModule&&Ya("Could not find LCEVC Library dependencies on this page");if("undefined"!==typeof LCEVCdec)this.h=LCEVCdec;else if("undefined"!==typeof LcevcDil)this.h=LcevcDil,this.j=!0,xd("LcevcDil","lcevc_dil.js is deprecated, please use lcevc_dec.js instead");else{Ya("Could not find LCEVC Library on this page");a=!1;break a}"undefined"===typeof this.h.SupportObject?(Ya("Could not find LCEVC Library on this page"),
370
370
  a=!1):(this.h.SupportObject.SupportStatus||Ya(this.h.SupportObject.SupportError),a="undefined"!==typeof this.h&&"undefined"!==typeof libDPIModule&&this.i instanceof HTMLCanvasElement&&this.h.SupportObject.SupportStatus)}a&&!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 Ej(a){a.g&&a.i.classList.add("shaka-hidden")}
371
- Dj.prototype.release=function(){this.g&&(this.g.close(),this.g=null)};function Fj(a,b,c){var d=Gj,e=Hj;switch(b.mimeType){case "video/webm":d=Ij;break;case "video/mp4":d=Jj}switch(c){case "DASH":e=Kj;break;case "HLS":e=Lj}a.g&&(a.o=b.id,a.g.setLevelSwitching(b.id,!0),a.g.setContainerFormat(d),a.j||a.g.setStreamingFormat(e))}P("shaka.lcevc.Dec",Dj);Dj.prototype.release=Dj.prototype.release;var Gj=0,Ij=1,Jj=2,Lj=0,Kj=1,Hj=-1;function Mj(a,b,c,d){var e=this;this.i=a;this.ba=c;this.A=null;this.H=b;this.h={};this.I={};this.Ea={};this.g=null;this.ha=!1;this.Z=d||null;this.j={};this.u=new od;this.o={};this.J=null;this.N=new lg;this.O="";this.qa=!1;this.l=Nj(this,this.N);this.G=!1;this.K=new Ig(function(){return Oj(e)});this.F=!1;this.$="UNKNOWN";this.Ha=this.Na=!1;this.Ba=new lg;this.m=!1;this.xa=!0;this.ma=this.R=this.na=this.S=this.L=this.ea=null;this.Aa=new lg}
371
+ Dj.prototype.release=function(){this.g&&(this.g.close(),this.g=null)};function Fj(a,b,c){var d=Gj,e=Hj;switch(b.mimeType){case "video/webm":d=Ij;break;case "video/mp4":d=Jj}switch(c){case "DASH":e=Kj;break;case "HLS":e=Lj}a.g&&(a.o=b.id,a.g.setLevelSwitching(b.id,!0),a.g.setContainerFormat(d),a.j||a.g.setStreamingFormat(e))}P("shaka.lcevc.Dec",Dj);Dj.prototype.release=Dj.prototype.release;var Gj=0,Ij=1,Jj=2,Lj=0,Kj=1,Hj=-1;function Mj(a,b,c,d){var e=this;this.i=a;this.ba=c;this.A=null;this.H=b;this.h={};this.I={};this.Ea={};this.g=null;this.ha=!1;this.X=d||null;this.j={};this.u=new od;this.o={};this.J=null;this.N=new lg;this.O="";this.qa=!1;this.l=Nj(this,this.N);this.G=!1;this.K=new Ig(function(){return Oj(e)});this.F=!1;this.$="UNKNOWN";this.Ha=this.Na=!1;this.Ba=new lg;this.m=!1;this.xa=!0;this.ma=this.R=this.na=this.S=this.L=this.ea=null;this.Aa=new lg}
372
372
  function Nj(a,b){if(window.ManagedMediaSource){a.i.disableRemotePlayback=!0;var c=new ManagedMediaSource;a.u.s(c,"startstreaming",function(){a.xa=!0});a.u.s(c,"endstreaming",function(){a.xa=!1});a.u.oa(c,"sourceopen",function(){URL.revokeObjectURL(a.O);b.resolve()});a.u.oa(a.i,"playing",function(){a.qa=!0});a.O=Pj(c);a.i.src=a.O;return c}c=new MediaSource;a.u.oa(c,"sourceopen",function(){URL.revokeObjectURL(a.O);b.resolve()});a.u.oa(a.i,"playing",function(){a.qa=!0});a.O=Pj(c);a.i.src=a.O;return c}
373
373
  function Qj(a,b){var c,d,e,f,g,h,k,l,m,n,p;return O(function(r){if(1==r.g)return a.createSegmentIndex?E(r,a.createSegmentIndex(),2):r.B(2);if(!a.segmentIndex)return r.return(!1);if(0==a.segmentIndex.getNumReferences())return r.return(!0);c=Uc;d=new Set;e=t(a.segmentIndex);for(f=e.next();!f.done;f=e.next())if(g=f.value,h=g.mimeType||a.mimeType||"",k=g.codecs||a.codecs||"",l=h+":"+k,!d.has(l))if(d.add(l),b==c.Ga){if(m=te(h,k),!Ne(m))return r.return(!1)}else if(b==c.ra?k=mf(k):b==c.aa&&(k=nf(k,h)),n=
374
374
  xe(a,h,k),p=ve(h,k),!td(n)&&!ne(p))return r.return(!1);return r.return(!0)})}q=Mj.prototype;q.destroy=function(){return this.K.destroy()};
375
375
  function Oj(a){var b,c,d,e,f,g,h,k;return O(function(l){if(1==l.g){b=[];for(c in a.j)for(d=a.j[c],e=d[0],a.j[c]=d.slice(0,1),e&&b.push(e.p.catch(Ve)),f=t(d.slice(1)),g=f.next();!g.done;g=f.next())h=g.value,h.p.reject(new U(2,7,7003,void 0));a.g&&b.push(a.g.destroy());a.H&&b.push(a.H.destroy());for(k in a.o)b.push(a.o[k].destroy());return E(l,Promise.all(b),2)}a.u&&(a.u.release(),a.u=null);a.i&&(a.i.removeAttribute("src"),a.i.load(),a.i=null);a.A=null;a.l=null;a.g=null;a.H=null;a.h={};a.o={};a.J=null;
376
- a.j={};a.Z=null;a.L=null;a.ba=null;F(l)})}q.init=function(a,b,c,d){b=void 0===b?!1:b;c=void 0===c?"UNKNOWN":c;d=void 0===d?!1:d;var e=this,f,g,h,k,l;return O(function(m){switch(m.g){case 1:return f=Uc,E(m,e.N,2);case 2:e.F=b,e.$=c,e.Na=d,e.Ha=!e.F&&"HLS"==e.$&&!e.Na,e.L=null,g=t(a.keys()),h=g.next();case 3:if(h.done){m.B(0);break}k=h.value;l=a.get(k);return E(m,Rj(e,k,l,l.codecs),6);case 6:e.m?(e.j[f.aa]=[],e.j[f.ra]=[]):e.j[k]=[],h=g.next(),m.B(3)}})};
376
+ a.j={};a.X=null;a.L=null;a.ba=null;F(l)})}q.init=function(a,b,c,d){b=void 0===b?!1:b;c=void 0===c?"UNKNOWN":c;d=void 0===d?!1:d;var e=this,f,g,h,k,l;return O(function(m){switch(m.g){case 1:return f=Uc,E(m,e.N,2);case 2:e.F=b,e.$=c,e.Na=d,e.Ha=!e.F&&"HLS"==e.$&&!e.Na,e.L=null,g=t(a.keys()),h=g.next();case 3:if(h.done){m.B(0);break}k=h.value;l=a.get(k);return E(m,Rj(e,k,l,l.codecs),6);case 6:e.m?(e.j[f.aa]=[],e.j[f.ra]=[]):e.j[k]=[],h=g.next(),m.B(3)}})};
377
377
  function Rj(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v;return O(function(w){switch(w.g){case 1:return e=Uc,f=Sa,g=Ta,E(w,Qj(c,b),2);case 2:g.call(f,w.h,"Type negotiation should happen before MediaSourceEngine.init!");h=te(c.mimeType,d);if(b==e.Ga){Sj(a,h,a.F,c.external);w.B(0);break}k=a.A.forceTransmux;if(!td(h)||!a.F&&ue.includes(h))k=!0;l=ve(c.mimeType,d);if(!k){w.B(4);break}m=Pc(e.aa,(d||"").split(","));n=Pc(e.ra,(d||"").split(","));if(!m||!n){w.B(5);break}a.m=!0;return E(w,Rj(a,e.aa,c,m),6);case 6:return E(w,
378
378
  Rj(a,e.ra,c,n),7);case 7:return w.return();case 5:if(p=ne(l))r=p(),a.o[b]=r,h=r.convertCodecs(b,l);case 4:u=h+a.A.addExtraFeaturesToSourceBuffer(h);Jg(a.K);try{v=a.l.addSourceBuffer(u)}catch(A){throw new U(2,3,3015,A,"The mediaSource_ status was "+a.l.readyState+" expected 'open'",null);}a.F&&(v.mode=Tj);a.u.s(v,"error",function(){var A=a.j[b][0];A.p.reject(new U(2,3,3014,a.i.error?a.i.error.code:0,A.uri))});a.u.s(v,"updateend",function(){return Uj(a,b)});a.h[b]=v;a.I[b]=h;a.Ea[b]=!!c.drmInfos.length;
379
379
  F(w)}})}q.configure=function(a){this.A=a;this.g&&(this.g.A=a.modifyCueCallback)};
380
380
  function Sj(a,b,c,d){a.g||(a.g=new Me(a.H),a.g&&(a.g.A=a.A.modifyCueCallback));var e=a.g;d=d||a.ha;a=a.$;"application/cea-608"==b||"application/cea-708"==b?e.i=null:(e.i=(0,Oe[b])(),e.i.setSequenceMode?e.i.setSequenceMode(c):xd("Text parsers w/ setSequenceMode",'Text parsers should have a "setSequenceMode" method!'),e.i.setManifestType?e.i.setManifestType(a):xd("Text parsers w/ setManifestType",'Text parsers should have a "setManifestType" method!'),e.F=d)}
381
381
  function Vj(a){return a.G?!1:a.l?"ended"==a.l.readyState:!0}function Wj(a,b){a.G||!Object.keys(a.h).length?a=null:b==Sc?a=a.g.g:(a=Xj(a,b),a=!a||Mi(a)?null:1==a.length&&0>a.start(0)?0:a.length?a.start(0):null);return a}function Yj(a,b){return a.G?null:b==Sc?a.g.h:Ni(Xj(a,b))}function Zj(a,b,c){if(a.G)return 0;if(b==Sc)return a=a.g,null==a.h||a.h<c?0:a.h-Math.max(c,a.g);a=Xj(a,b);return Pi(a,c)}
382
382
  q.Mb=function(){var a={total:this.G?[]:Qi(this.i.buffered),audio:this.G?[]:Qi(Xj(this,"audio")),video:this.G?[]:Qi(Xj(this,"video")),text:[]};if(this.g){var b=this.g.g,c=this.g.h;null!=b&&null!=c&&a.text.push({start:b,end:c})}return a};function Xj(a,b){try{return a.h[b].buffered}catch(c){return null}}
383
- function hk(a,b,c,d,e,f){var g=null,h=Gb(c);if(ue.includes(e))f=Xi(h),f.length&&d&&((b=f.find(function(n){return"com.apple.streaming.transportStreamTimestamp"===n.description}))&&b.data&&(g=Math.round(b.data)/1E3),a.ba.cf([{cueTime:d.startTime,data:h,frames:f,dts:d.startTime,pts:d.startTime}],0,d.endTime));else if(e.includes("/mp4")&&d&&0==d.timestampOffset&&d.sa&&d.sa.timescale){var k=d.sa.timescale;if(!isNaN(k)){var l=0,m=!1;(new Pg).box("moof",Ug).box("traf",Ug).W("tfdt",function(n){l=$i(n.reader,
383
+ function ak(a,b,c,d,e,f){var g=null,h=Gb(c);if(ue.includes(e))f=Xi(h),f.length&&d&&((b=f.find(function(n){return"com.apple.streaming.transportStreamTimestamp"===n.description}))&&b.data&&(g=Math.round(b.data)/1E3),a.ba.cf([{cueTime:d.startTime,data:h,frames:f,dts:d.startTime,pts:d.startTime}],0,d.endTime));else if(e.includes("/mp4")&&d&&0==d.timestampOffset&&d.sa&&d.sa.timescale){var k=d.sa.timescale;if(!isNaN(k)){var l=0,m=!1;(new Pg).box("moof",Ug).box("traf",Ug).W("tfdt",function(n){l=$i(n.reader,
384
384
  n.version).baseMediaDecodeTime/k;m=!0;n.parser.stop()}).parse(c,!0);m&&(g=l)}}else e.includes("/mp4")||e.includes("/webm")||!Cj(h)||(a.L?a.L.clearData():a.L=new vj,h=a.L.parse(h),b=h.getStartTime(b),null!=b&&(g=b),h=h.getMetadata(),h.length&&a.ba.cf(h,f,d?d.endTime:null));return g}
385
385
  function ik(a,b,c,d,e,f,g,h,k,l){g=void 0===g?!1:g;h=void 0===h?!1:h;k=void 0===k?!1:k;l=void 0===l?!1:l;var m,n,p,r,u,v,w,A,z,C,y,B,D,K;return O(function(G){switch(G.g){case 1:m=Uc;if(b!=m.Ga){G.B(2);break}if(!a.F){G.B(3);break}return E(G,a.Ba,4);case 4:n=G.h,a.g.u=n;case 3:return E(G,Pe(a.g,c,d?d.startTime:null,d?d.endTime:null,d?d.P()[0]:null),5);case 5:return G.return();case 2:if(l||!a.m){G.B(6);break}return E(G,ik(a,m.aa,c,d,e,f,g,h,k,!0),7);case 7:return E(G,ik(a,m.ra,c,d,e,f,g,h,k,!0),8);case 8:return G.return();
386
- case 6:if(!a.h[b])return G.return();p=a.h[b].timestampOffset;r=a.I[b];a.o[b]&&(r=a.o[b].getOriginalMimeType());d&&(u=hk(a,b,c,d,r,p),null!=u&&(null==a.S&&b==m.ra&&(a.S=u,a.na=d.startTime,null!=a.R&&(v=0,a.na==a.ma&&(v=a.S-a.R),a.Aa.resolve(v))),null==a.R&&b==m.aa&&(a.R=u,a.ma=d.startTime,null!=a.S&&(w=0,a.na==a.ma&&(w=a.S-a.R),a.Aa.resolve(w))),A=d.startTime-u,z=Math.abs(p-A),(.001<=z||g||h)&&(!k||0<A||!p)&&(p=A,a.Ha&&(jk(a,b,function(){return kk(a,b)},null),jk(a,b,function(){return lk(a,b,p)},null))),
386
+ case 6:if(!a.h[b])return G.return();p=a.h[b].timestampOffset;r=a.I[b];a.o[b]&&(r=a.o[b].getOriginalMimeType());d&&(u=ak(a,b,c,d,r,p),null!=u&&(null==a.S&&b==m.ra&&(a.S=u,a.na=d.startTime,null!=a.R&&(v=0,a.na==a.ma&&(v=a.S-a.R),a.Aa.resolve(v))),null==a.R&&b==m.aa&&(a.R=u,a.ma=d.startTime,null!=a.S&&(w=0,a.na==a.ma&&(w=a.S-a.R),a.Aa.resolve(w))),A=d.startTime-u,z=Math.abs(p-A),(.001<=z||g||h)&&(!k||0<A||!p)&&(p=A,a.Ha&&(jk(a,b,function(){return kk(a,b)},null),jk(a,b,function(){return lk(a,b,p)},null))),
387
387
  C=b==m.ra||!(m.ra in a.h),a.F&&C&&a.Ba.resolve(p)));f&&b==m.ra&&(a.g||Sj(a,"application/cea-608",a.F,!1),a.J||(y=r.split(";",1)[0],a.J=new Ed(y)),d?(B=a.J.i(c),B.length&&Te(a.g,B,d.startTime,d.endTime,p)):a.J.init(c,h));if(!a.o[b]){G.B(9);break}return E(G,a.o[b].transmux(c,e,d,a.l.duration,b),10);case 10:c=G.h;case 9:c=mk(a,c,d?d.startTime:null,b,d?d.P()[0]:null);if(!d||!a.F||b==m.Ga){G.B(11);break}if(!g&&!h){G.B(11);break}D=d.startTime;if("HLS"!=a.$||a.m||b!=m.aa||!a.h[m.ra]){G.B(13);break}return E(G,
388
- a.Aa,14);case 14:K=G.h,.1<Math.abs(K)&&(D-=K);case 13:jk(a,b,function(){return kk(a,b)},null),jk(a,b,function(){return lk(a,b,D)},null);case 11:return E(G,jk(a,b,function(){var J=c;if("video"==b&&a.Z){var I=a.Z;I.g&&I.g.appendBuffer(J,"video",I.o,-p)}a.h[b].appendBuffer(J)},d?d.P()[0]:null),15);case 15:F(G)}})}function nk(a,b){var c=Yj(a,"video")||0;Re(a.g,b,c)}function ok(a){a.g&&Re(a.g,"",0)}
388
+ a.Aa,14);case 14:K=G.h,.1<Math.abs(K)&&(D-=K);case 13:jk(a,b,function(){return kk(a,b)},null),jk(a,b,function(){return lk(a,b,D)},null);case 11:return E(G,jk(a,b,function(){var J=c;if("video"==b&&a.X){var I=a.X;I.g&&I.g.appendBuffer(J,"video",I.o,-p)}a.h[b].appendBuffer(J)},d?d.P()[0]:null),15);case 15:F(G)}})}function nk(a,b){var c=Yj(a,"video")||0;Re(a.g,b,c)}function ok(a){a.g&&Re(a.g,"",0)}
389
389
  q.remove=function(a,b,c){var d=this,e;return O(function(f){return 1==f.g?(e=Uc,a==e.Ga?E(f,d.g.remove(b,c),0):E(f,jk(d,a,function(){return pk(d,a,b,c)},null),4)):d.m?E(f,jk(d,e.aa,function(){return pk(d,e.aa,b,c)},null),0):f.B(0)})};function qk(a,b){var c;return O(function(d){return 1==d.g?(c=Uc,b==c.Ga?a.g?E(d,a.g.remove(0,Infinity),0):d.return():E(d,jk(a,b,function(){return pk(a,b,0,a.l.duration)},null),4)):a.m?E(d,jk(a,c.aa,function(){return pk(a,c.aa,0,a.l.duration)},null),0):d.B(0)})}
390
390
  q.flush=function(a){var b=this,c;return O(function(d){return 1==d.g?(c=Uc,a==c.Ga?d.return():E(d,jk(b,a,function(){b.i.currentTime-=.001;Uj(b,a)},null),2)):b.m?E(d,jk(b,c.aa,function(){var e=c.aa;b.i.currentTime-=.001;Uj(b,e)},null),0):d.B(0)})};
391
391
  function rk(a,b,c,d,e,f,g,h,k){var l,m,n;return O(function(p){if(1==p.g){l=Uc;if(b==l.Ga)return f||(a.g.u=c),Qe(a.g,d,e),p.return();m=[];return E(p,sk(a,b,g,h,k),2)}n=p.h;n||(m.push(jk(a,b,function(){return kk(a,b)},null)),a.m&&m.push(jk(a,l.aa,function(){return kk(a,l.aa)},null)));f||(m.push(jk(a,b,function(){return lk(a,b,c)},null)),a.m&&m.push(jk(a,l.aa,function(){return lk(a,l.aa,c)},null)));m.push(jk(a,b,function(){a.h[b].appendWindowStart=0;a.h[b].appendWindowEnd=e;a.h[b].appendWindowStart=
@@ -400,14 +400,14 @@ function yk(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J;return O(fu
400
400
  Promise.all(g),4);case 4:return a.o={},a.h={},w=a.l.duration,a.N=new lg,a.l=Nj(a,a.N),E(I,a.N,5);case 5:!isNaN(w)&&w?a.l.duration=w:!isNaN(a.ea)&&a.ea&&(a.l.duration=a.ea),A=new lg,z=a.l.sourceBuffers,C=b.size,y=0,B=function(){y++;y===C&&(A.resolve(),a.u.Xa(z,"addsourcebuffer",B))},a.u.s(z,"addsourcebuffer",B),D=t(b.keys()),K=D.next();case 6:if(K.done)return a.i.currentTime=d,E(I,A,2);G=K.value;J=b.get(G);return E(I,Rj(a,G,J,J.codecs),9);case 9:a.m?(a.j[c.aa]=[],a.j[c.ra]=[]):a.j[G]=[];K=D.next();
401
401
  I.B(6);break;case 2:xa(I),a.G=!1,Jg(a.K),a.u.oa(a.i,"canplaythrough",function(){a.K.g||(a.i.autoplay=e,f||a.i.play())}),ya(I,0)}})}function zk(a,b){return uk(a,function(){return yk(a,b)})}
402
402
  function sk(a,b,c,d,e){var f,g,h,k,l,m,n,p,r,u,v,w,A,z,C;return O(function(y){if(1==y.g){f=Uc;if(b==f.Ga)return y.return(!1);g=Ie(Ke(a.I[b]));h=Je(a.I[b]);l=!1;m=te(c,d);n=a.A.forceTransmux;if(!td(m)||!a.F&&ue.includes(m))n=!0;n&&(p=ve(c,d),r=ne(p))&&(k=r(),u=Pc(f.aa,(d||"").split(",")),v=Pc(f.ra,(d||"").split(",")),u&&v?(l=!0,w=v,b==f.aa&&(w=u),m=k.convertCodecs(b,ve(c,w))):m=k.convertCodecs(b,p));A=Ie(Ke(m));z=Je(m);if(g===A&&h===z)return y.return(!1);C=!0;if(a.m||l&&k&&!a.o[b])C=!1;if(C&&"smooth"===
403
- a.A.codecSwitchingStrategy&&vd())return E(y,xk(a,b,m,k),3);k&&k.destroy();return E(y,zk(a,e),3)}return y.return(!0)})}function Ak(a,b,c,d){if(b==Sc)var e=!1;else{e=Ie(Ke(a.I[b]));var f=Je(a.I[b]),g=te(c,d),h=a.A.forceTransmux;if(!td(g)||!a.F&&ue.includes(g))h=!0;c=ve(c,d);h&&(h=ne(c))&&(h=h(),g=h.convertCodecs(b,c),h.destroy());b=Ie(Ke(g));g=Je(g);e=e!==b||f!==g}return e?"smooth"!==a.A.codecSwitchingStrategy||!vd()||a.m:!1}var Pj=window.URL.createObjectURL,Tj="sequence";function Bk(a,b,c){this.i=a;this.u=b;this.m=this.j=Infinity;this.g=1;this.h=this.l=null;this.A=0;this.H=!0;this.I=0;this.G=void 0===c?!0:c;this.J=0;this.o=!1;this.F=a}q=Bk.prototype;q.getDuration=function(){return this.j};q.ij=function(){return this.g};q.ii=function(a){this.i=a};q.sb=function(a){this.j=a};q.mj=function(){return this.i};q.ci=function(a){this.A=a};q.Lc=function(a){this.H=a};q.nf=function(a){this.m=a};q.Ne=function(){return this.m};q.Xg=function(a){this.u=a};q.$i=function(){return this.u};
403
+ a.A.codecSwitchingStrategy&&vd())return E(y,xk(a,b,m,k),3);k&&k.destroy();return E(y,zk(a,e),3)}return y.return(!0)})}function Ak(a,b,c,d){if(b==Sc)var e=!1;else{e=Ie(Ke(a.I[b]));var f=Je(a.I[b]),g=te(c,d),h=a.A.forceTransmux;if(!td(g)||!a.F&&ue.includes(g))h=!0;c=ve(c,d);h&&(h=ne(c))&&(h=h(),g=h.convertCodecs(b,c),h.destroy());b=Ie(Ke(g));g=Je(g);e=e!==b||f!==g}return e?"smooth"!==a.A.codecSwitchingStrategy||!vd()||a.m:!1}var Pj=window.URL.createObjectURL,Tj="sequence";function Bk(a,b,c){this.i=a;this.u=b;this.m=this.j=Infinity;this.g=1;this.h=this.l=null;this.A=0;this.H=!0;this.I=0;this.G=void 0===c?!0:c;this.J=0;this.o=!1;this.F=a}q=Bk.prototype;q.getDuration=function(){return this.j};q.ij=function(){return this.g};q.ii=function(a){this.i=a};q.sb=function(a){this.j=a};q.mj=function(){return this.i};q.ci=function(a){this.A=a};q.Mc=function(a){this.H=a};q.nf=function(a){this.m=a};q.Ne=function(){return this.m};q.Xg=function(a){this.u=a};q.$i=function(){return this.u};
404
404
  q.Vh=function(a,b){if(0!=a.length){var c=a[a.length-1].end+b;this.$e(a[0].start+b);this.g=a.reduce(function(d,e){return Math.max(d,e.end-e.start)},this.g);this.h=Math.max(this.h,c);null!=this.i&&this.G&&!this.o&&(this.i=(Date.now()+this.A)/1E3-this.h-this.g)}};
405
405
  q.ce=function(a){if(0!=a.length){var b=a[0].startTime,c=a[0].endTime,d=(Date.now()+this.A)/1E3;a=t(a);for(var e=a.next();!e.done;e=a.next())e=e.value,d<e.startTime||(b=Math.min(b,e.startTime),c=Math.max(c,e.endTime),this.g=Math.max(this.g,e.endTime-e.startTime));this.$e(b);this.h=Math.max(this.h,c);null!=this.i&&this.G&&!this.o&&(this.i=d-this.h-this.g)}};q.Ue=function(){this.o=!0};q.Lj=function(){return this.o};q.ei=function(a){this.F=a};q.cj=function(){return this.F};
406
- q.$e=function(a){this.l=null==this.l?a:Math.min(this.l,a)};q.Jg=function(a){this.g=Math.max(this.g,a)};q.offset=function(a){null!=this.l&&(this.l+=a);null!=this.h&&(this.h+=a)};q.U=function(){return Infinity==this.j&&!this.H};q.Ec=function(){return Infinity!=this.j&&!this.H};q.Cb=function(){return Math.max(this.I,this.ic()-this.m)};q.li=function(a){this.I=a};
407
- q.ic=function(){return this.U()||this.Ec()?Math.min(Math.max(0,(Date.now()+this.A)/1E3-this.g-this.i)+this.J,this.j):this.h?Math.min(this.h,this.j):this.j};q.Rd=function(a){var b=Math.max(this.l,this.I);return Infinity==this.m?Math.ceil(1E3*b)/1E3:Math.max(b,Math.min(this.ic()-this.m+a,this.Ob()))};q.yc=function(){return this.Rd(0)};q.Ob=function(){return Math.max(0,this.ic()-(this.U()||this.Ec()?this.u:0))};q.si=function(){return null==this.i||null!=this.h&&this.G?!1:!0};
408
- q.bi=function(a){this.J=a};P("shaka.media.PresentationTimeline",Bk);Bk.prototype.setAvailabilityTimeOffset=Bk.prototype.bi;Bk.prototype.usingPresentationStartTime=Bk.prototype.si;Bk.prototype.getSeekRangeEnd=Bk.prototype.Ob;Bk.prototype.getSeekRangeStart=Bk.prototype.yc;Bk.prototype.getSafeSeekRangeStart=Bk.prototype.Rd;Bk.prototype.getSegmentAvailabilityEnd=Bk.prototype.ic;Bk.prototype.setUserSeekStart=Bk.prototype.li;Bk.prototype.getSegmentAvailabilityStart=Bk.prototype.Cb;
409
- Bk.prototype.isInProgress=Bk.prototype.Ec;Bk.prototype.isLive=Bk.prototype.U;Bk.prototype.offset=Bk.prototype.offset;Bk.prototype.notifyMaxSegmentDuration=Bk.prototype.Jg;Bk.prototype.notifyMinSegmentStartTime=Bk.prototype.$e;Bk.prototype.getInitialProgramDateTime=Bk.prototype.cj;Bk.prototype.setInitialProgramDateTime=Bk.prototype.ei;Bk.prototype.isStartTimeLocked=Bk.prototype.Lj;Bk.prototype.lockStartTime=Bk.prototype.Ue;Bk.prototype.notifySegments=Bk.prototype.ce;Bk.prototype.notifyTimeRange=Bk.prototype.Vh;
410
- Bk.prototype.getDelay=Bk.prototype.$i;Bk.prototype.setDelay=Bk.prototype.Xg;Bk.prototype.getSegmentAvailabilityDuration=Bk.prototype.Ne;Bk.prototype.setSegmentAvailabilityDuration=Bk.prototype.nf;Bk.prototype.setStatic=Bk.prototype.Lc;Bk.prototype.setClockOffset=Bk.prototype.ci;Bk.prototype.getPresentationStartTime=Bk.prototype.mj;Bk.prototype.setDuration=Bk.prototype.sb;Bk.prototype.setPresentationStartTime=Bk.prototype.ii;Bk.prototype.getMaxSegmentDuration=Bk.prototype.ij;
406
+ q.$e=function(a){this.l=null==this.l?a:Math.min(this.l,a)};q.Jg=function(a){this.g=Math.max(this.g,a)};q.offset=function(a){null!=this.l&&(this.l+=a);null!=this.h&&(this.h+=a)};q.U=function(){return Infinity==this.j&&!this.H};q.Fc=function(){return Infinity!=this.j&&!this.H};q.Cb=function(){return Math.max(this.I,this.jc()-this.m)};q.li=function(a){this.I=a};
407
+ q.jc=function(){return this.U()||this.Fc()?Math.min(Math.max(0,(Date.now()+this.A)/1E3-this.g-this.i)+this.J,this.j):this.h?Math.min(this.h,this.j):this.j};q.Rd=function(a){var b=Math.max(this.l,this.I);return Infinity==this.m?Math.ceil(1E3*b)/1E3:Math.max(b,Math.min(this.jc()-this.m+a,this.Ob()))};q.ic=function(){return this.Rd(0)};q.Ob=function(){return Math.max(0,this.jc()-(this.U()||this.Fc()?this.u:0))};q.si=function(){return null==this.i||null!=this.h&&this.G?!1:!0};
408
+ q.bi=function(a){this.J=a};P("shaka.media.PresentationTimeline",Bk);Bk.prototype.setAvailabilityTimeOffset=Bk.prototype.bi;Bk.prototype.usingPresentationStartTime=Bk.prototype.si;Bk.prototype.getSeekRangeEnd=Bk.prototype.Ob;Bk.prototype.getSeekRangeStart=Bk.prototype.ic;Bk.prototype.getSafeSeekRangeStart=Bk.prototype.Rd;Bk.prototype.getSegmentAvailabilityEnd=Bk.prototype.jc;Bk.prototype.setUserSeekStart=Bk.prototype.li;Bk.prototype.getSegmentAvailabilityStart=Bk.prototype.Cb;
409
+ Bk.prototype.isInProgress=Bk.prototype.Fc;Bk.prototype.isLive=Bk.prototype.U;Bk.prototype.offset=Bk.prototype.offset;Bk.prototype.notifyMaxSegmentDuration=Bk.prototype.Jg;Bk.prototype.notifyMinSegmentStartTime=Bk.prototype.$e;Bk.prototype.getInitialProgramDateTime=Bk.prototype.cj;Bk.prototype.setInitialProgramDateTime=Bk.prototype.ei;Bk.prototype.isStartTimeLocked=Bk.prototype.Lj;Bk.prototype.lockStartTime=Bk.prototype.Ue;Bk.prototype.notifySegments=Bk.prototype.ce;Bk.prototype.notifyTimeRange=Bk.prototype.Vh;
410
+ Bk.prototype.getDelay=Bk.prototype.$i;Bk.prototype.setDelay=Bk.prototype.Xg;Bk.prototype.getSegmentAvailabilityDuration=Bk.prototype.Ne;Bk.prototype.setSegmentAvailabilityDuration=Bk.prototype.nf;Bk.prototype.setStatic=Bk.prototype.Mc;Bk.prototype.setClockOffset=Bk.prototype.ci;Bk.prototype.getPresentationStartTime=Bk.prototype.mj;Bk.prototype.setDuration=Bk.prototype.sb;Bk.prototype.setPresentationStartTime=Bk.prototype.ii;Bk.prototype.getMaxSegmentDuration=Bk.prototype.ij;
411
411
  Bk.prototype.getDuration=Bk.prototype.getDuration;function Ck(a,b,c){this.j=c;this.l=a;this.u=Dk(a);this.g=a.g.currentTime;this.m=Date.now()/1E3;this.h=!1;this.o=0;this.A=b;this.i=function(){}}Ck.prototype.release=function(){this.j=this.l=null;this.i=function(){}};function Ek(a,b){a.i=b}function Fk(a){this.g=a}function Dk(a){if(a.g.paused||0==a.g.playbackRate||0==a.g.buffered.length)var b=!1;else a:{b=a.g.currentTime;a=t(Qi(a.g.buffered));for(var c=a.next();!c.done;c=a.next())if(c=c.value,!(b<c.start-.1||b>c.end-.5)){b=!0;break a}b=!1}return b};function Gk(a,b,c,d,e){var f=this;this.A=e;this.g=a;this.F=b;this.u=c;this.l=new od;this.j=!1;this.H=a.readyState;this.G=this.i=0;this.h=d;this.o=!1;this.l.s(a,"waiting",function(){return Hk(f)});this.m=(new Ub(function(){Hk(f)})).za(this.u.gapJumpTimerTime)}Gk.prototype.release=function(){this.l&&(this.l.release(),this.l=null);null!=this.m&&(this.m.stop(),this.m=null);this.h&&(this.h.release(),this.h=null);this.g=this.F=this.A=null};Gk.prototype.Mg=function(){this.o=!0;Hk(this)};
412
412
  function Hk(a){if(0!=a.g.readyState){if(a.g.seeking){if(!a.j)return}else a.j=!1;if(!a.g.paused||a.g.currentTime==a.i&&(a.g.autoplay||a.g.currentTime!=a.i)){a.g.readyState!=a.H&&(a.H=a.g.readyState);var b;if(!(b=!a.h)){b=a.h;var c=b.l,d=Dk(c),e=c.g.currentTime,f=Date.now()/1E3;if(b.g!=e||b.u!=d)b.m=f,b.g=e,b.u=d,b.h=!1;e=f-b.m;if(d=e>=b.A&&d&&!b.h)b.i(b.g,e),b.h=!0,b.g=c.g.currentTime,b.o++,b.j(new S("stalldetected"));b=!d}if(b&&(b=a.g.currentTime,c=a.g.buffered,d=Ri(c,b,a.u.gapDetectionThreshold),
413
413
  null!=d&&(0!=d||a.o))){e=c.start(d);if(navigator.userAgent.match(/Edge\//)||Zb())e=Math.ceil(100*(e+.01))/100;e>=a.F.Ob()||.001>e-b||(0!=d&&c.end(d-1),a.g.currentTime=e,b==a.i&&(a.i=e),a.G++,a.A(new S("gapjumped")))}}}};function Ik(a,b,c,d){b==HTMLMediaElement.HAVE_NOTHING||a.readyState>=b?d():(b=Jk.value().get(b),c.oa(a,b,d))}var Jk=new Nb(function(){return new Map([[HTMLMediaElement.HAVE_METADATA,"loadedmetadata"],[HTMLMediaElement.HAVE_CURRENT_DATA,"loadeddata"],[HTMLMediaElement.HAVE_FUTURE_DATA,"canplay"],[HTMLMediaElement.HAVE_ENOUGH_DATA,"canplaythrough"]])});function Kk(a,b,c,d){var e=this;this.g=a;this.m=b;this.u=c;this.l=null;this.j=function(){null==e.l&&(e.l=d());return e.l};this.o=!1;this.h=new od;this.i=new Lk(a);Ik(this.g,HTMLMediaElement.HAVE_METADATA,this.h,function(){Mk(e,e.j())})}Kk.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};function Nk(a){return a.o?a.g.currentTime:a.j()}
@@ -415,70 +415,70 @@ function Ok(a,b){0<a.g.readyState?Pk(a.i,b):Ik(a.g,HTMLMediaElement.HAVE_METADAT
415
415
  function Lk(a){var b=this;this.h=a;this.m=10;this.l=this.j=this.i=0;this.g=new Ub(function(){0>=b.i?b.g.stop():b.h.currentTime!=b.j?b.g.stop():(b.h.currentTime=b.l,b.i--)})}Lk.prototype.release=function(){this.g&&(this.g.stop(),this.g=null);this.h=null};function Pk(a,b){a.j=a.h.currentTime;a.l=b;a.i=a.m;a.h.currentTime=b;a.g.za(.1)};function Rk(a){this.h=a;this.j=!1;this.g=null;this.i=new od}q=Rk.prototype;q.Pf=function(){function a(){if(null==b.g||0==b.g&&Infinity!=b.h.duration)b.j=!0;else{var c=b.h.currentTime,d=b.g;0>b.g&&(d=Math.max(0,c+b.g));c!=d?(b.i.oa(b.h,"seeking",function(){b.j=!0}),b.h.currentTime=d):b.j=!0}}var b=this;Ik(this.h,HTMLMediaElement.HAVE_CURRENT_DATA,this.i,function(){a()})};q.release=function(){this.i&&(this.i.release(),this.i=null);this.h=null};q.Qf=function(a){this.g=this.j?this.g:a};
416
416
  q.Ae=function(){return(this.j?this.h.currentTime:this.g)||0};q.oh=function(){return 0};q.nh=function(){return 0};q.Uh=function(){};
417
417
  function Sk(a,b,c,d,e,f){var g=this;this.i=a;this.g=b.presentationTimeline;this.F=b.minBufferTime||0;this.l=c;this.A=e;this.u=null;this.o=Tk(a,c,f);this.j=new Gk(a,b.presentationTimeline,c,this.o,f);this.h=new Kk(a,function(){a:{var h=g.j;h.j=!0;h.o=!1;var k=Nk(g.h);h=Uk(g,k);if(.001<Math.abs(h-k)){k=!1;if(!gc()||gc()&&oc())k=!0;else{var l=Date.now()/1E3;if(!g.u||g.u<l-1)g.u=l,k=!0}if(k){Ok(g.h,h);h=void 0;break a}}g.A();h=void 0}return h},function(h){var k=g.j;k.g.seeking&&!k.j&&(k.j=!0,k.i=h)},
418
- function(){var h=d;null==h?h=Infinity>g.g.getDuration()?g.g.yc():g.g.Ob():0>h&&(h=g.g.Ob()+h);return Vk(g,Wk(g,h))});this.m=new Ub(function(){if(0!=g.i.readyState&&!g.i.paused){var h=Nk(g.h),k=g.g.yc(),l=g.g.Ob();3>l-k&&(k=l-3);h<k&&(h=Uk(g,h),g.i.currentTime=h)}})}q=Sk.prototype;q.Pf=function(){this.m.za(.25)};q.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(){}};
418
+ function(){var h=d;null==h?h=Infinity>g.g.getDuration()?g.g.ic():g.g.Ob():0>h&&(h=g.g.Ob()+h);return Vk(g,Wk(g,h))});this.m=new Ub(function(){if(0!=g.i.readyState&&!g.i.paused){var h=Nk(g.h),k=g.g.ic(),l=g.g.Ob();3>l-k&&(k=l-3);h<k&&(h=Uk(g,h),g.i.currentTime=h)}})}q=Sk.prototype;q.Pf=function(){this.m.za(.25)};q.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(){}};
419
419
  q.Qf=function(a){Ok(this.h,a)};q.Ae=function(){var a=Nk(this.h);return 0<this.i.readyState&&!this.i.paused?Wk(this,a):a};q.oh=function(){return this.o?this.o.o:0};q.nh=function(){return this.j.G};q.Uh=function(){this.j.Mg()};function Vk(a,b){var c=a.g.getDuration();return b>=c?c-a.l.durationBackoff:b}
420
- function Uk(a,b){var c=Math.max(a.F,a.l.rebufferingGoal),d=a.l.safeSeekOffset,e=a.g.yc(),f=a.g.Ob(),g=a.g.getDuration();3>f-e&&(e=f-3);var h=a.g.Rd(c),k=a.g.Rd(d);c=a.g.Rd(c+d);return b>=g?Vk(a,b):b>f?f:b<e?Oi(a.i.buffered,k)?k:c:b>=h||Oi(a.i.buffered,b)?b:c}function Wk(a,b){var c=a.g.yc();if(b<c)return c;a=a.g.Ob();return b>a?a:b}
421
- function Tk(a,b,c){if(!b.stallEnabled)return null;var d=b.stallSkip;b=new Ck(new Fk(a),b.stallThreshold,c);Ek(b,function(){d?a.currentTime+=d:(a.pause(),a.play())});return b};function Xk(a){this.g=a;this.m=null;this.j=0;this.o=!1}q=Xk.prototype;q.getNumReferences=function(){return this.g.length};q.getNumEvicted=function(){return this.j};q.release=function(){this.o||(this.g=[],this.m&&this.m.stop(),this.m=null)};q.Sj=function(){this.o=!0};q.Xc=function(a){for(var b=t(this.g),c=b.next();!c.done;c=b.next())a(c.value)};
420
+ function Uk(a,b){var c=Math.max(a.F,a.l.rebufferingGoal),d=a.l.safeSeekOffset,e=a.g.ic(),f=a.g.Ob(),g=a.g.getDuration();3>f-e&&(e=f-3);var h=a.g.Rd(c),k=a.g.Rd(d);c=a.g.Rd(c+d);return b>=g?Vk(a,b):b>f?f:b<e?Oi(a.i.buffered,k)?k:c:b>=h||Oi(a.i.buffered,b)?b:c}function Wk(a,b){var c=a.g.ic();if(b<c)return c;a=a.g.Ob();return b>a?a:b}
421
+ function Tk(a,b,c){if(!b.stallEnabled)return null;var d=b.stallSkip;b=new Ck(new Fk(a),b.stallThreshold,c);Ek(b,function(){d?a.currentTime+=d:(a.pause(),a.play())});return b};function Xk(a){this.g=a;this.m=null;this.j=0;this.o=!1}q=Xk.prototype;q.getNumReferences=function(){return this.g.length};q.getNumEvicted=function(){return this.j};q.release=function(){this.o||(this.g=[],this.m&&this.m.stop(),this.m=null)};q.Sj=function(){this.o=!0};q.Yc=function(a){for(var b=t(this.g),c=b.next();!c.done;c=b.next())a(c.value)};
422
422
  q.find=function(a){for(var b=this.g.length-1,c=b;0<=c;--c){var d=this.g[c],e=c<b?this.g[c+1].startTime:d.endTime;if(a>=d.startTime&&a<e)return c+this.j}return this.g.length&&a<this.g[0].startTime?this.j:null};q.get=function(a){if(0==this.g.length)return null;a-=this.j;return 0>a||a>=this.g.length?null:this.g[a]};q.offset=function(a){if(!this.o)for(var b=t(this.g),c=b.next();!c.done;c=b.next())c.value.offset(a)};
423
423
  q.Xe=function(a){if(!this.o&&a.length){var b=Math.round(1E3*a[0].startTime)/1E3;this.g=this.g.filter(function(c){return Math.round(1E3*c.startTime)/1E3<b});this.g.push.apply(this.g,x(a))}};q.ae=function(a,b){var c=this;a=a.filter(function(d){return d.endTime>b&&(0==c.g.length||d.endTime>c.g[0].startTime)});this.Xe(a);this.eb(b)};q.eb=function(a){if(!this.o){var b=this.g.length;this.g=this.g.filter(function(c){return c.endTime>a});this.j+=b-this.g.length}};
424
- q.Wc=function(a,b,c){c=void 0===c?!1:c;if(!this.o){for(;this.g.length;)if(this.g[this.g.length-1].startTime>=b)this.g.pop();else break;for(;this.g.length;)if(this.g[0].endTime<=a)this.g.shift(),c||this.j++;else break;0!=this.g.length&&(a=this.g[this.g.length-1],b=new Ii(a.startTime,b,a.G,a.Wa,a.Da,a.sa,a.timestampOffset,a.appendWindowStart,a.appendWindowEnd,a.g,a.tilesLayout,a.A,a.h,a.status,a.aesKey),b.mimeType=a.mimeType,b.codecs=a.codecs,b.j=a.j,this.g[this.g.length-1]=b)}};
424
+ q.Xc=function(a,b,c){c=void 0===c?!1:c;if(!this.o){for(;this.g.length;)if(this.g[this.g.length-1].startTime>=b)this.g.pop();else break;for(;this.g.length;)if(this.g[0].endTime<=a)this.g.shift(),c||this.j++;else break;0!=this.g.length&&(a=this.g[this.g.length-1],b=new Ii(a.startTime,b,a.G,a.Wa,a.Da,a.sa,a.timestampOffset,a.appendWindowStart,a.appendWindowEnd,a.g,a.tilesLayout,a.A,a.h,a.status,a.aesKey),b.mimeType=a.mimeType,b.codecs=a.codecs,b.j=a.j,this.g[this.g.length-1]=b)}};
425
425
  q.tf=function(a,b){var c=this;this.o||(this.m&&this.m.stop(),this.m=new Ub(function(){var d=b();d?c.g.push.apply(c.g,x(d)):(c.m.stop(),c.m=null)}),this.m.za(a))};Xk.prototype[Symbol.iterator]=function(){return this.Wb(0)};
426
426
  Xk.prototype.Wb=function(a,b,c){b=void 0===b?!1:b;c=void 0===c?!1:c;var d=this.find(a);if(null==d)return null;var e=this.get(d);c?d++:d--;var f=-1;if(e&&0<e.g.length)for(var g=e.g.length-1;0<=g;--g){var h=e.g[g];if(a>=h.startTime&&a<h.endTime){if(!b){for(;g&&!h.l;)g--,h=e.g[g];if(!h.l)return Xa("No independent partial segment found!"),null}c?d--:d++;f=g-1;break}}return new Yk(this,d,f,c)};function Zk(a,b,c){a=new Ii(a,a+b,function(){return c},0,null,null,a,a,a+b);return new Xk([a])}
427
- P("shaka.media.SegmentIndex",Xk);Xk.forSingleSegment=Zk;Xk.prototype.getIteratorForTime=Xk.prototype.Wb;Xk.prototype.updateEvery=Xk.prototype.tf;Xk.prototype.fit=Xk.prototype.Wc;Xk.prototype.evict=Xk.prototype.eb;Xk.prototype.mergeAndEvict=Xk.prototype.ae;Xk.prototype.offset=Xk.prototype.offset;Xk.prototype.get=Xk.prototype.get;Xk.prototype.find=Xk.prototype.find;Xk.prototype.markImmutable=Xk.prototype.Sj;Xk.prototype.release=Xk.prototype.release;Xk.prototype.getNumEvicted=Xk.prototype.getNumEvicted;
427
+ P("shaka.media.SegmentIndex",Xk);Xk.forSingleSegment=Zk;Xk.prototype.getIteratorForTime=Xk.prototype.Wb;Xk.prototype.updateEvery=Xk.prototype.tf;Xk.prototype.fit=Xk.prototype.Xc;Xk.prototype.evict=Xk.prototype.eb;Xk.prototype.mergeAndEvict=Xk.prototype.ae;Xk.prototype.offset=Xk.prototype.offset;Xk.prototype.get=Xk.prototype.get;Xk.prototype.find=Xk.prototype.find;Xk.prototype.markImmutable=Xk.prototype.Sj;Xk.prototype.release=Xk.prototype.release;Xk.prototype.getNumEvicted=Xk.prototype.getNumEvicted;
428
428
  Xk.prototype.getNumReferences=Xk.prototype.getNumReferences;function Yk(a,b,c,d){this.i=a;this.h=b;this.g=c;this.reverse=d}Yk.prototype.pd=function(a){this.reverse=a};Yk.prototype.Oi=function(){return this.h};Yk.prototype.current=function(){var a=this.i.get(this.h);a&&0<a.g.length&&a.o&&this.g>=a.g.length&&(this.h++,this.g=0,a=this.i.get(this.h));return a&&0<a.g.length?a.g[this.g]:a};
429
429
  Yk.prototype.next=function(){var a=this.i.get(this.h);this.reverse?a&&0<a.g.length?(this.g--,0>this.g&&(this.h--,this.g=(a=this.i.get(this.h))&&0<a.g.length?a.g.length-1:0)):(this.h--,this.g=0):a&&0<a.g.length?(this.g++,a.o&&this.g==a.g.length&&(this.h++,this.g=0)):(this.h++,this.g=0);a=this.current();return{value:a,done:!a}};P("shaka.media.SegmentIterator",Yk);Yk.prototype.next=Yk.prototype.next;Yk.prototype.current=Yk.prototype.current;Yk.prototype.currentPosition=Yk.prototype.Oi;
430
- Yk.prototype.setReverse=Yk.prototype.pd;function $k(){Xk.call(this,[]);this.h=[]}na($k,Xk);q=$k.prototype;q.clone=function(){var a=new $k;a.h=this.h.slice();return a};q.release=function(){for(var a=t(this.h),b=a.next();!b.done;b=a.next())b.value.release();this.h=[]};q.Xc=function(a){for(var b=t(this.h),c=b.next();!c.done;c=b.next())c.value.Xc(a)};q.find=function(a){for(var b=0,c=t(this.h),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.find(a);if(null!=e)return e+b;b+=d.getNumEvicted()+d.getNumReferences()}return null};
431
- q.get=function(a){for(var b=0,c=t(this.h),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.get(a-b);if(e)return e;e=d.getNumReferences();b+=d.getNumEvicted()+e}return null};q.offset=function(){};q.Xe=function(){};q.eb=function(){};q.ae=function(){};q.Wc=function(){};q.tf=function(){};P("shaka.media.MetaSegmentIndex",$k);$k.prototype.updateEvery=$k.prototype.tf;$k.prototype.fit=$k.prototype.Wc;$k.prototype.mergeAndEvict=$k.prototype.ae;$k.prototype.evict=$k.prototype.eb;$k.prototype.merge=$k.prototype.Xe;
432
- $k.prototype.offset=$k.prototype.offset;$k.prototype.get=$k.prototype.get;$k.prototype.find=$k.prototype.find;$k.prototype.forEachTopLevelReference=$k.prototype.Xc;$k.prototype.release=$k.prototype.release;function al(a){var b=this;this.g=a;this.j=!1;this.i=this.g.Me();this.h=new Ub(function(){b.g.Th(.25*b.i)})}al.prototype.release=function(){this.set(this.xc());this.h&&(this.h.stop(),this.h=null);this.g=null};al.prototype.set=function(a){this.i=a;bl(this)};al.prototype.xc=function(){return this.g.xc()};function bl(a){a.h.stop();var b=a.j?0:a.i;if(0<=b)try{a.g.Me()!=b&&a.g.ah(b);return}catch(c){}a.h.za(.25);0!=a.g.Me()&&a.g.ah(0)};function cl(a){var b=this;this.h=a;this.g=new Set;this.i=(new Ub(function(){dl(b,!1)})).za(.25)}cl.prototype.release=function(){this.i.stop();for(var a=t(this.g),b=a.next();!b.done;b=a.next())b.value.release();this.g.clear()};function dl(a,b){for(var c=t(a.g),d=c.next();!d.done;d=c.next())d.value.j(a.h.currentTime,b)};function el(){this.g=null;this.h=[]}function fl(a,b){var c=0;a.g&&a.g.state==b&&(c+=a.g.duration);a=t(a.h);for(var d=a.next();!d.done;d=a.next())d=d.value,c+=d.state==b?d.duration:0;return c}function gl(a){function b(f){return{timestamp:f.timestamp,state:f.state,duration:f.duration}}for(var c=[],d=t(a.h),e=d.next();!e.done;e=d.next())c.push(b(e.value));a.g&&c.push(b(a.g));return c};function hl(){this.i=this.h=null;this.g=[]}function il(a,b,c){a.i!=b&&(a.i=b,a.g.push({timestamp:Date.now()/1E3,id:b.id,type:"text",fromAdaptation:c,bandwidth:null}))};function jl(){this.Be=this.A=this.F=this.I=this.G=this.u=this.j=this.H=this.m=this.i=this.N=this.O=this.J=this.K=this.L=this.l=this.o=NaN;this.g=new el;this.h=new hl};function kl(a,b,c,d){this.m=a;this.i=b;this.l=c;this.h=new Map;this.j=new Map;this.g=null;this.o=d}function ll(a,b){a.l=b;a=t(a.h.values());for(var c=a.next();!c.done;c=a.next())c.value.g=b}
433
- function ml(a,b,c){c=void 0===c?!1:c;if(a.i.segmentIndex&&(a.g||(a.g=a.i.segmentIndex.Wb(b,!0,a.o)),a.g)){for(c&&a.g.next();a.h.size<a.m;){b=a.g.next().value;if(!b)break;c=!0;b.preload&&null!=b.Da&&(c=!1);2==b.zc()&&(c=!1);c&&b.sa&&nl(a,b.sa);c&&!a.h.has(b)&&(c=new ol(a.l),pl(c,b,a.i),a.h.set(b,c));if(a.i.fastSwitching&&b.fe&&b.Te)break}ql(a)}}function nl(a,b){if(a.i.segmentIndex&&!Array.from(a.j.keys()).some(function(d){return Hi(d,b)})){var c=new ol(a.l);pl(c,b,a.i);a.j.set(b,c)}}
430
+ Yk.prototype.setReverse=Yk.prototype.pd;function $k(){Xk.call(this,[]);this.h=[]}na($k,Xk);q=$k.prototype;q.clone=function(){var a=new $k;a.h=this.h.slice();return a};q.release=function(){for(var a=t(this.h),b=a.next();!b.done;b=a.next())b.value.release();this.h=[]};q.Yc=function(a){for(var b=t(this.h),c=b.next();!c.done;c=b.next())c.value.Yc(a)};q.find=function(a){for(var b=0,c=t(this.h),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.find(a);if(null!=e)return e+b;b+=d.getNumEvicted()+d.getNumReferences()}return null};
431
+ q.get=function(a){for(var b=0,c=t(this.h),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.get(a-b);if(e)return e;e=d.getNumReferences();b+=d.getNumEvicted()+e}return null};q.offset=function(){};q.Xe=function(){};q.eb=function(){};q.ae=function(){};q.Xc=function(){};q.tf=function(){};P("shaka.media.MetaSegmentIndex",$k);$k.prototype.updateEvery=$k.prototype.tf;$k.prototype.fit=$k.prototype.Xc;$k.prototype.mergeAndEvict=$k.prototype.ae;$k.prototype.evict=$k.prototype.eb;$k.prototype.merge=$k.prototype.Xe;
432
+ $k.prototype.offset=$k.prototype.offset;$k.prototype.get=$k.prototype.get;$k.prototype.find=$k.prototype.find;$k.prototype.forEachTopLevelReference=$k.prototype.Yc;$k.prototype.release=$k.prototype.release;function al(a){var b=this;this.g=a;this.j=!1;this.i=this.g.Me();this.h=new Ub(function(){b.g.Th(.25*b.i)})}al.prototype.release=function(){this.set(this.zc());this.h&&(this.h.stop(),this.h=null);this.g=null};al.prototype.set=function(a){this.i=a;bl(this)};al.prototype.zc=function(){return this.g.zc()};function bl(a){a.h.stop();var b=a.j?0:a.i;if(0<=b)try{a.g.Me()!=b&&a.g.ah(b);return}catch(c){}a.h.za(.25);0!=a.g.Me()&&a.g.ah(0)};function cl(a){var b=this;this.h=a;this.g=new Set;this.i=(new Ub(function(){dl(b,!1)})).za(.25)}cl.prototype.release=function(){this.i.stop();for(var a=t(this.g),b=a.next();!b.done;b=a.next())b.value.release();this.g.clear()};function dl(a,b){for(var c=t(a.g),d=c.next();!d.done;d=c.next())d.value.j(a.h.currentTime,b)};function el(){this.g=null;this.h=[]}function fl(a,b){var c=0;a.g&&a.g.state==b&&(c+=a.g.duration);a=t(a.h);for(var d=a.next();!d.done;d=a.next())d=d.value,c+=d.state==b?d.duration:0;return c}function gl(a){function b(f){return{timestamp:f.timestamp,state:f.state,duration:f.duration}}for(var c=[],d=t(a.h),e=d.next();!e.done;e=d.next())c.push(b(e.value));a.g&&c.push(b(a.g));return c};function hl(){this.i=this.h=null;this.g=[]}function il(a,b,c){a.i!=b&&(a.i=b,a.g.push({timestamp:Date.now()/1E3,id:b.id,type:"text",fromAdaptation:c,bandwidth:null}))};function jl(){this.Be=this.A=this.F=this.I=this.G=this.u=this.j=this.H=this.m=this.i=this.N=this.O=this.J=this.K=this.L=this.l=this.o=NaN;this.g=new el;this.h=new hl};function kl(a,b,c,d){this.m=a;this.i=b;this.l=c;this.h=new Map;this.j=new Map;this.g=null;this.o=d}function ll(a,b){a.l=b;a=t(a.h.values());for(var c=a.next();!c.done;c=a.next())c.value.g=b}
433
+ function ml(a,b,c){c=void 0===c?!1:c;if(a.i.segmentIndex&&(a.g||(a.g=a.i.segmentIndex.Wb(b,!0,a.o)),a.g)){for(c&&a.g.next();a.h.size<a.m;){b=a.g.next().value;if(!b)break;c=!0;b.preload&&null!=b.Da&&(c=!1);2==b.Ac()&&(c=!1);c&&b.sa&&nl(a,b.sa);c&&!a.h.has(b)&&(c=new ol(a.l),pl(c,b,a.i),a.h.set(b,c));if(a.i.fastSwitching&&b.fe&&b.Te)break}ql(a)}}function nl(a,b){if(a.i.segmentIndex&&!Array.from(a.j.keys()).some(function(d){return Hi(d,b)})){var c=new ol(a.l);pl(c,b,a.i);a.j.set(b,c)}}
434
434
  function rl(a,b){b=t(b.keys());for(var c=b.next();!c.done;c=b.next())(c=c.value)&&sl(a,c)}function tl(a){rl(a,a.h);rl(a,a.j);a.g=null}kl.prototype.eb=function(a,b){b=void 0===b?!1:b;for(var c=t(this.h.keys()),d=c.next();!d.done;d=c.next())d=d.value,a>d.endTime&&sl(this,d);b&&ql(this)};kl.prototype.pd=function(a){this.o=a;this.g&&this.g.pd(a)};
435
435
  function ql(a){for(var b=Array.from(a.h.keys()),c={},d=t(a.j.keys()),e=d.next();!e.done;c={ue:c.ue},e=d.next())c.ue=e.value,b.some(function(f){return function(g){return Hi(g.sa,f.ue)}}(c))||sl(a,c.ue)}function ul(a,b){a.m=b;for(var c=Array.from(a.h.keys());c.length>b;){var d=c.pop();d&&sl(a,d)}ql(a)}function vl(a,b){b&&b!==a.i&&(tl(a),a.i=b)}function sl(a,b){var c=a.h;b instanceof Gi&&(c=a.j);a=c.get(b);c.delete(b);a&&a.abort()}function ol(a){this.g=a;this.df=this.eh=null}
436
436
  function pl(a,b,c){var d=new Uint8Array(0);a.df=a.g(b,c,function(e){return O(function(f){if(1==f.g)return 0<d.byteLength?d=Kc(d,e):d=e,a.eh?E(f,a.eh(d),3):f.B(0);d=new Uint8Array(0);F(f)})})}ol.prototype.abort=function(){this.df&&this.df.abort()};function wl(a){gb.call(this);var b=this;this.g=new Set;this.i=a;this.h=(new Ub(function(){for(var c=b.i(),d=t(b.g),e=d.next();!e.done;e=d.next())e=e.value,e.endTime<c.start&&(b.g.delete(e),e=new S("regionremove",new Map([["region",e]])),b.dispatchEvent(e))})).za(2)}na(wl,gb);wl.prototype.release=function(){this.g.clear();this.h.stop();gb.prototype.release.call(this)};function xl(a){gb.call(this);this.g=new Map;this.h=a}na(xl,gb);xl.prototype.release=function(){this.g.clear();gb.prototype.release.call(this)};function yl(a,b){var c=a.g.get(b);c||(c={je:[],yh:null,contentType:b},a.g.set(b,c));return c}function zl(a,b,c){var d=yl(a,b.contentType);Al(a,d);a={Ig:b,position:c};d=d.je;b=d.findIndex(function(e){return e.position>=c});0<=b?d.splice(b,d[b].position==c?1:0,a):d.push(a)}
437
437
  xl.prototype.j=function(a){for(var b=t(this.g.values()),c=b.next();!c.done;c=b.next()){c=c.value;a:{var d=c.je;for(var e=d.length-1;0<=e;e--){var f=d[e];if(f.position<=a){d=f.Ig;break a}}d=null}if(e=d)e=c.yh,e=!(e===d||e&&d&&e.bandwidth==d.bandwidth&&e.audioSamplingRate==d.audioSamplingRate&&e.codecs==d.codecs&&e.contentType==d.contentType&&e.frameRate==d.frameRate&&e.height==d.height&&e.mimeType==d.mimeType&&e.channelsCount==d.channelsCount&&e.pixelAspectRatio==d.pixelAspectRatio&&e.width==d.width);
438
438
  if(e)a:{e=a;f=d.contentType;if((f=this.h()[f])&&0<f.length){var g=f[f.length-1].end;if(e>=f[0].start&&e<g){e=!0;break a}}e=!1}e&&(c.yh=d,JSON.stringify(d),c=new S("qualitychange",new Map([["quality",d],["position",a]])),this.dispatchEvent(c))}};function Al(a,b){if((a=a.h()[b.contentType])&&0<a.length){var c=a[0].start,d=a[a.length-1].end,e=b.je;b.je=e.filter(function(f,g){return f.position<=c&&g+1<e.length&&e[g+1].position<=c||f.position>=d?!1:!0})}else b.je=[]};function Bl(a,b,c,d,e){a=Ag(a,d,e);if(0!=b||null!=c)a.headers.Range=c?"bytes="+b+"-"+c:"bytes="+b+"-";return a};function Cl(a,b){var c=this;this.g=b;this.m=a;this.h=null;this.F=1;this.u=this.j=null;this.J=0;this.H=!1;this.i=new Map;this.G=!1;this.K=null;this.A=!1;this.l=new Ig(function(){return Dl(c)});this.L=Date.now()/1E3;this.o=new Map;this.I={projection:null,hfov:null};this.O=0;this.N=Infinity}q=Cl.prototype;q.destroy=function(){return this.l.destroy()};
439
- function Dl(a){var b,c,d,e,f,g,h;return O(function(k){if(1==k.g){b=[];c=t(a.i.values());for(d=c.next();!d.done;d=c.next())e=d.value,El(e),b.push(Fl(e)),e.Y&&(tl(e.Y),e.Y=null);f=t(a.o.values());for(g=f.next();!g.done;g=f.next())h=g.value,tl(h);return E(k,Promise.all(b),2)}a.i.clear();a.o.clear();a.g=null;a.m=null;a.h=null;F(k)})}
440
- q.configure=function(a){this.h=a;this.K=new ig({maxAttempts:Math.max(a.retryParameters.maxAttempts,2),baseDelay:a.retryParameters.baseDelay,backoffFactor:a.retryParameters.backoffFactor,fuzzFactor:a.retryParameters.fuzzFactor,timeout:0,stallTimeout:0,connectionTimeout:0},!0);if(a.disableAudioPrefetch){var b=this.i.get("audio");b&&b.Y&&(tl(b.Y),b.Y=null);b=t(this.o.keys());for(var c=b.next();!c.done;c=b.next())c=c.value,tl(this.o.get(c)),this.o.delete(c)}a.disableTextPrefetch&&(b=this.i.get(Sc))&&
441
- b.Y&&(tl(b.Y),b.Y=null);a.disableVideoPrefetch&&(b=this.i.get("video"))&&b.Y&&(tl(b.Y),b.Y=null);b=t(this.i.keys());for(c=b.next();!c.done;c=b.next())c=this.i.get(c.value),c.Y?(ul(c.Y,a.segmentPrefetchLimit),0<a.segmentPrefetchLimit||(tl(c.Y),c.Y=null)):0<a.segmentPrefetchLimit&&(c.Y=Gl(this,c.stream));a.disableAudioPrefetch||Hl(this)};function Il(a,b,c){a.m.presentationTimeline.U()||(a.O=b,a.N=c)}
439
+ function Dl(a){var b,c,d,e,f,g,h;return O(function(k){if(1==k.g){b=[];c=t(a.i.values());for(d=c.next();!d.done;d=c.next())e=d.value,El(e),b.push(Fl(e)),e.Z&&(tl(e.Z),e.Z=null);f=t(a.o.values());for(g=f.next();!g.done;g=f.next())h=g.value,tl(h);return E(k,Promise.all(b),2)}a.i.clear();a.o.clear();a.g=null;a.m=null;a.h=null;F(k)})}
440
+ q.configure=function(a){this.h=a;this.K=new ig({maxAttempts:Math.max(a.retryParameters.maxAttempts,2),baseDelay:a.retryParameters.baseDelay,backoffFactor:a.retryParameters.backoffFactor,fuzzFactor:a.retryParameters.fuzzFactor,timeout:0,stallTimeout:0,connectionTimeout:0},!0);if(a.disableAudioPrefetch){var b=this.i.get("audio");b&&b.Z&&(tl(b.Z),b.Z=null);b=t(this.o.keys());for(var c=b.next();!c.done;c=b.next())c=c.value,tl(this.o.get(c)),this.o.delete(c)}a.disableTextPrefetch&&(b=this.i.get(Sc))&&
441
+ b.Z&&(tl(b.Z),b.Z=null);a.disableVideoPrefetch&&(b=this.i.get("video"))&&b.Z&&(tl(b.Z),b.Z=null);b=t(this.i.keys());for(c=b.next();!c.done;c=b.next())c=this.i.get(c.value),c.Z?(ul(c.Z,a.segmentPrefetchLimit),0<a.segmentPrefetchLimit||(tl(c.Z),c.Z=null)):0<a.segmentPrefetchLimit&&(c.Z=Gl(this,c.stream));a.disableAudioPrefetch||Hl(this)};function Il(a,b,c){a.m.presentationTimeline.U()||(a.O=b,a.N=c)}
442
442
  q.start=function(a){var b=this;return O(function(c){if(1==c.g)return E(c,Jl(b,a||new Map),2);Jg(b.l);b.G=!0;F(c)})};function Kl(a,b){var c,d,e,f,g,h,k;O(function(l){switch(l.g){case 1:return c=Uc,a.J++,d=a.J,ta(l,2),E(l,qk(a.g.ka,c.Ga),4);case 4:va(l,3);break;case 2:if(e=wa(l),a.g)a.g.onError(e);case 3:f=te(b.mimeType,b.codecs),Sj(a.g.ka,f,a.m.sequenceMode,b.external),g=a.g.ka.H,(h=g.isTextVisible()||a.h.alwaysStreamText)&&a.J==d&&(k=Ll(a,b),a.i.set(c.Ga,k),Ml(a,k,0)),F(l)}})}
443
- function Nl(a){var b=a.i.get(Sc);b&&(El(b),Fl(b).catch(function(){}),a.i.delete(Sc));a.u=null}function Ol(a,b){for(var c=0>a.g.Ra(),d=t(a.i.values()),e=d.next();!e.done;e=d.next())e=e.value,e.ua&&e.ua.pd(c),e.Y&&e.Y.pd(c);d=t(a.o.values());for(e=d.next();!e.done;e=d.next())e.value.pd(c);if(c=a.i.get("video"))if(d=c.stream)if(b)(b=d.trickModeVideo)&&!c.Kc&&(Pl(a,b,!1,0,!1),c.Kc=d);else if(b=c.Kc)c.Kc=null,Pl(a,b,!0,0,!1)}
443
+ function Nl(a){var b=a.i.get(Sc);b&&(El(b),Fl(b).catch(function(){}),a.i.delete(Sc));a.u=null}function Ol(a,b){for(var c=0>a.g.Ra(),d=t(a.i.values()),e=d.next();!e.done;e=d.next())e=e.value,e.ua&&e.ua.pd(c),e.Z&&e.Z.pd(c);d=t(a.o.values());for(e=d.next();!e.done;e=d.next())e.value.pd(c);if(c=a.i.get("video"))if(d=c.stream)if(b)(b=d.trickModeVideo)&&!c.Lc&&(Pl(a,b,!1,0,!1),c.Lc=d);else if(b=c.Lc)c.Lc=null,Pl(a,b,!0,0,!1)}
444
444
  function Ql(a,b,c,d,e,f){c=void 0===c?!1:c;d=void 0===d?0:d;e=void 0===e?!1:e;f=void 0===f?!1:f;a.j=b;a.G&&(b.video&&Pl(a,b.video,c,d,e,f),b.audio&&Pl(a,b.audio,c,d,e,f))}function Rl(a,b){O(function(c){if(1==c.g)return a.u=b,a.G?b.segmentIndex?c.B(2):E(c,b.createSegmentIndex(),2):c.return();Pl(a,b,!0,0,!1);F(c)})}
445
- function Pl(a,b,c,d,e,f){var g=a.i.get(b.type);g||b.type!=Sc?g&&(g.Kc&&(b.trickModeVideo?(g.Kc=b,b=b.trickModeVideo):g.Kc=null),g.stream!=b||e)&&(a.o.has(b)?g.Y=a.o.get(b):g.Y&&vl(g.Y,b),b.type==Sc&&(e=te(b.mimeType,b.codecs),Sj(a.g.ka,e,a.m.sequenceMode,b.external)),a.o.has(g.stream)||g.stream.closeSegmentIndex&&g.stream.closeSegmentIndex(),g.stream=b,g.ua=null,g.ph=!!f,c?g.Kd?g.wf=!0:g.fb?(g.nc=!0,g.Fe=d,g.wf=!0):(El(g),Sl(a,g,!0,d).catch(function(h){if(a.g)a.g.onError(h)})):g.fb||g.Jb||Ml(a,g,
445
+ function Pl(a,b,c,d,e,f){var g=a.i.get(b.type);g||b.type!=Sc?g&&(g.Lc&&(b.trickModeVideo?(g.Lc=b,b=b.trickModeVideo):g.Lc=null),g.stream!=b||e)&&(a.o.has(b)?g.Z=a.o.get(b):g.Z&&vl(g.Z,b),b.type==Sc&&(e=te(b.mimeType,b.codecs),Sj(a.g.ka,e,a.m.sequenceMode,b.external)),a.o.has(g.stream)||g.stream.closeSegmentIndex&&g.stream.closeSegmentIndex(),g.stream=b,g.ua=null,g.ph=!!f,c?g.Kd?g.wf=!0:g.fb?(g.qc=!0,g.Fe=d,g.wf=!0):(El(g),Sl(a,g,!0,d).catch(function(h){if(a.g)a.g.onError(h)})):g.fb||g.Jb||Ml(a,g,
446
446
  0),Tl(a,g).catch(function(h){if(a.g)a.g.onError(h)})):Kl(a,b)}
447
447
  function Tl(a,b){var c,d;return O(function(e){if(1==e.g){if(!b.Ab)return e.return();c=b.stream;d=b.Ab;return c.segmentIndex?e.B(2):E(e,c.createSegmentIndex(),2)}if(b.Ab!=d||b.stream!=c)return e.return();var f=a.g.Le();var g=Yj(a.g.ka,b.type),h=b.stream.segmentIndex.find(b.ob?b.ob.endTime:f),k=null==h?null:b.stream.segmentIndex.get(h);h=k?k.Da?k.Da-k.Wa:null:null;k&&!h&&(h=(k.endTime-k.getStartTime())*(b.stream.bandwidth||0)/8);h?((k=k.sa)&&(h+=(k.Da?k.Da-k.Wa:null)||0),k=a.g.getBandwidthEstimate(),
448
448
  f=8*h/k<(g||0)-f-Math.max(a.m.minBufferTime||0,a.h.rebufferingGoal)||b.Ab.h.g>h?!0:!1):f=!1;f&&b.Ab.abort();F(e)})}
449
- q.ke=function(){if(this.g)for(var a=this.g.Le(),b=t(this.i.keys()),c=b.next();!c.done;c=b.next()){var d=c.value;c=this.i.get(d);var e=this.g.ka;e.G?e=!1:d==Sc?(e=e.g,e=null==e.g||null==e.h?!1:a>=e.g&&a<e.h):(e=Xj(e,d),e=Oi(e,a));if(!e){c.Y&&(c.Y.g=null);if("audio"===c.type){e=t(this.o.values());for(var f=e.next();!f.done;f=e.next())f.value.g=null}c.ua=null;(null!=Yj(this.g.ka,d)||c.fb)&&Ul(this,c);c.Ab&&(c.Ab.abort(),c.Ab=null);d===Sc&&(d=this.g.ka,d.J&&d.J.g());c.ke=!0}}};
450
- function Ul(a,b){b.Kd||b.nc||(b.fb?(b.nc=!0,b.Fe=0):null==Wj(a.g.ka,b.type)?null==b.Jb&&Ml(a,b,0):(El(b),Sl(a,b,!1,0).catch(function(c){if(a.g)a.g.onError(c)})))}
449
+ q.ke=function(){if(this.g)for(var a=this.g.Le(),b=t(this.i.keys()),c=b.next();!c.done;c=b.next()){var d=c.value;c=this.i.get(d);var e=this.g.ka;e.G?e=!1:d==Sc?(e=e.g,e=null==e.g||null==e.h?!1:a>=e.g&&a<e.h):(e=Xj(e,d),e=Oi(e,a));if(!e){c.Z&&(c.Z.g=null);if("audio"===c.type){e=t(this.o.values());for(var f=e.next();!f.done;f=e.next())f.value.g=null}c.ua=null;(null!=Yj(this.g.ka,d)||c.fb)&&Ul(this,c);c.Ab&&(c.Ab.abort(),c.Ab=null);d===Sc&&(d=this.g.ka,d.J&&d.J.g());c.ke=!0}}};
450
+ function Ul(a,b){b.Kd||b.qc||(b.fb?(b.qc=!0,b.Fe=0):null==Wj(a.g.ka,b.type)?null==b.Jb&&Ml(a,b,0):(El(b),Sl(a,b,!1,0).catch(function(c){if(a.g)a.g.onError(c)})))}
451
451
  function Jl(a,b){var c,d,e,f,g,h,k,l,m,n;return O(function(p){if(1==p.g){c=Uc;if(!a.j)throw new U(2,5,5006);d=new Map;e=new Set;a.j.audio&&(d.set(c.aa,a.j.audio),e.add(a.j.audio));a.j.video&&(d.set(c.ra,a.j.video),e.add(a.j.video));a.u&&(d.set(c.Ga,a.u),e.add(a.u));f=a.g.ka;return E(p,f.init(d,a.m.sequenceMode,a.m.type,a.m.ignoreManifestTimestampsInSegmentsMode),2)}Jg(a.l);a.updateDuration();g=t(d.keys());for(h=g.next();!h.done;h=g.next())k=h.value,l=d.get(k),a.i.has(k)||(m=Ll(a,l),b.has(l.id)&&(n=
452
- b.get(l.id),ll(n,function(r,u,v){return Vl(r,u,v||null,a.h.retryParameters,a.g.Zb)}),m.Y=n),a.i.set(k,m),Ml(a,m,0));F(p)})}function Ll(a,b){return{stream:b,type:b.type,ua:null,Y:Gl(a,b),ob:null,fd:null,Fg:null,Dg:null,Cg:null,Kc:null,endOfStream:!1,fb:!1,Jb:null,nc:!1,Fe:0,wf:!1,Kd:!1,ke:!0,Qg:!1,Ud:!1,Ab:null}}
453
- function Gl(a,b){if("video"===b.type&&a.h.disableVideoPrefetch||"audio"===b.type&&a.h.disableAudioPrefetch||b.type===Sc&&("application/cea-608"==b.mimeType||"application/cea-708"==b.mimeType)||b.type===Sc&&a.h.disableTextPrefetch)return null;if(a.o.has(b))return a.o.get(b);var c=a.i.get(b.type);return(c=c&&c.Y)&&b===c.i?c:0<a.h.segmentPrefetchLimit?new kl(a.h.segmentPrefetchLimit,b,function(d,e,f){return Vl(d,e,f||null,a.h.retryParameters,a.g.Zb)},0>a.g.Ra()):null}
454
- function Hl(a){for(var b=a.h.segmentPrefetchLimit,c=a.h.prefetchAudioLanguages,d={},e=t(a.m.variants),f=e.next();!f.done;d={gb:d.gb},f=e.next())if(d.gb=f.value,d.gb.audio)if(a.o.has(d.gb.audio)){if(f=a.o.get(d.gb.audio),ul(f,b),!(0<b&&c.some(function(h){return function(k){return Wc(h.gb.audio.language,k)}}(d)))){var g=a.i.get(d.gb.audio.type);f!==(g&&g.Y)&&tl(f);a.o.delete(d.gb.audio)}}else 0>=b||!c.some(function(h){return function(k){return Wc(h.gb.audio.language,k)}}(d))||!(f=Gl(a,d.gb.audio))||
452
+ b.get(l.id),ll(n,function(r,u,v){return Vl(r,u,v||null,a.h.retryParameters,a.g.Zb)}),m.Z=n),a.i.set(k,m),Ml(a,m,0));F(p)})}function Ll(a,b){return{stream:b,type:b.type,ua:null,Z:Gl(a,b),ob:null,gd:null,Fg:null,Dg:null,Cg:null,Lc:null,endOfStream:!1,fb:!1,Jb:null,qc:!1,Fe:0,wf:!1,Kd:!1,ke:!0,Qg:!1,Ud:!1,Ab:null}}
453
+ function Gl(a,b){if("video"===b.type&&a.h.disableVideoPrefetch||"audio"===b.type&&a.h.disableAudioPrefetch||b.type===Sc&&("application/cea-608"==b.mimeType||"application/cea-708"==b.mimeType)||b.type===Sc&&a.h.disableTextPrefetch)return null;if(a.o.has(b))return a.o.get(b);var c=a.i.get(b.type);return(c=c&&c.Z)&&b===c.i?c:0<a.h.segmentPrefetchLimit?new kl(a.h.segmentPrefetchLimit,b,function(d,e,f){return Vl(d,e,f||null,a.h.retryParameters,a.g.Zb)},0>a.g.Ra()):null}
454
+ function Hl(a){for(var b=a.h.segmentPrefetchLimit,c=a.h.prefetchAudioLanguages,d={},e=t(a.m.variants),f=e.next();!f.done;d={gb:d.gb},f=e.next())if(d.gb=f.value,d.gb.audio)if(a.o.has(d.gb.audio)){if(f=a.o.get(d.gb.audio),ul(f,b),!(0<b&&c.some(function(h){return function(k){return Wc(h.gb.audio.language,k)}}(d)))){var g=a.i.get(d.gb.audio.type);f!==(g&&g.Z)&&tl(f);a.o.delete(d.gb.audio)}}else 0>=b||!c.some(function(h){return function(k){return Wc(h.gb.audio.language,k)}}(d))||!(f=Gl(a,d.gb.audio))||
455
455
  (d.gb.audio.segmentIndex||d.gb.audio.createSegmentIndex(),a.o.set(d.gb.audio,f))}q.updateDuration=function(){var a=this.m.presentationTimeline.getDuration();Infinity>a?this.g.ka.sb(a):this.g.ka.sb(this.h.infiniteLiveStreamDuration?Infinity:Math.pow(2,32))};
456
- function Wl(a,b){var c,d,e,f,g;return O(function(h){switch(h.g){case 1:Jg(a.l);if(b.fb||null==b.Jb||b.Kd)return h.return();b.Jb=null;if(!b.nc){h.B(2);break}return E(h,Sl(a,b,b.wf,b.Fe),3);case 3:return h.return();case 2:if(b.stream.segmentIndex){h.B(4);break}c=b.stream;return E(h,b.stream.createSegmentIndex(),5);case 5:if(c!=b.stream)return c.closeSegmentIndex&&c.closeSegmentIndex(),b.fb||b.Jb||Ml(a,b,0),h.return();case 4:ta(h,6);d=Xl(a,b);null!=d&&(Ml(a,b,d),b.Ud=!1);va(h,7);break;case 6:return e=
456
+ function Wl(a,b){var c,d,e,f,g;return O(function(h){switch(h.g){case 1:Jg(a.l);if(b.fb||null==b.Jb||b.Kd)return h.return();b.Jb=null;if(!b.qc){h.B(2);break}return E(h,Sl(a,b,b.wf,b.Fe),3);case 3:return h.return();case 2:if(b.stream.segmentIndex){h.B(4);break}c=b.stream;return E(h,b.stream.createSegmentIndex(),5);case 5:if(c!=b.stream)return c.closeSegmentIndex&&c.closeSegmentIndex(),b.fb||b.Jb||Ml(a,b,0),h.return();case 4:ta(h,6);d=Xl(a,b);null!=d&&(Ml(a,b,d),b.Ud=!1);va(h,7);break;case 6:return e=
457
457
  wa(h),E(h,Yl(a,b,e),8);case 8:return h.return();case 7:f=Array.from(a.i.values());if(!a.G||!f.every(function(k){return k.endOfStream})){h.B(0);break}return E(h,a.g.ka.endOfStream(),10);case 10:Jg(a.l),g=a.g.ka.getDuration(),0!=g&&g<a.m.presentationTimeline.getDuration()&&a.m.presentationTimeline.sb(g),F(h)}})}
458
458
  function Xl(a,b){if(Zl(b))return nk(a.g.ka,b.stream.originalId||""),null;b.type==Sc&&ok(a.g.ka);if(!a.g.ka.xa&&b.type!=Sc)return a.h.updateIntervalSeconds/2;var c=a.g.Le();if("audio"===b.type)for(var d=t(a.o.keys()),e=d.next();!e.done;e=d.next())e=a.o.get(e.value),e.eb(c,!0),ml(e,c);d=b.ob?b.ob.endTime:c;e=Zj(a.g.ka,b.type,c);var f=Math.max(1,Math.max(a.m.minBufferTime||0,a.h.rebufferingGoal,a.h.bufferingGoal)*a.F),g=a.m.presentationTimeline.getDuration()-d,h=Yj(a.g.ka,b.type);if(1E-6>g&&h)return b.endOfStream=
459
- !0,"video"==b.type&&(a=a.i.get(Sc))&&Zl(a)&&(a.endOfStream=!0),null;b.endOfStream=!1;if(e>=f)return a.h.updateIntervalSeconds/2;e=$l(a,b,c,h);if(!e)return a.h.updateIntervalSeconds;f=Infinity;g=Array.from(a.i.values());g=t(g);for(h=g.next();!h.done;h=g.next())h=h.value,Zl(h)||h.ua&&!h.ua.current()||(f=Math.min(f,h.ob?h.ob.endTime:c));if(d>=f+a.m.presentationTimeline.g)return a.h.updateIntervalSeconds;b.Y&&b.ua&&!a.o.has(b.stream)&&(b.Y.eb(e.startTime),ml(b.Y,e.startTime));am(a,b,c,e).catch(function(){});
459
+ !0,"video"==b.type&&(a=a.i.get(Sc))&&Zl(a)&&(a.endOfStream=!0),null;b.endOfStream=!1;if(e>=f)return a.h.updateIntervalSeconds/2;e=$l(a,b,c,h);if(!e)return a.h.updateIntervalSeconds;f=Infinity;g=Array.from(a.i.values());g=t(g);for(h=g.next();!h.done;h=g.next())h=h.value,Zl(h)||h.ua&&!h.ua.current()||(f=Math.min(f,h.ob?h.ob.endTime:c));if(d>=f+a.m.presentationTimeline.g)return a.h.updateIntervalSeconds;b.Z&&b.ua&&!a.o.has(b.stream)&&(b.Z.eb(e.startTime),ml(b.Z,e.startTime));am(a,b,c,e).catch(function(){});
460
460
  return null}function $l(a,b,c,d){if(b.ua)return b.ua.current();if(b.ob||d)return b.ua=b.stream.segmentIndex.Wb(b.ob?b.ob.endTime:d,!1,0>a.g.Ra()),b.ua&&b.ua.next().value;d=a.h.inaccurateManifestTolerance;var e=Math.max(c-d,0);a=0>a.g.Ra();var f=null;d&&(b.ua=b.stream.segmentIndex.Wb(e,!1,a),f=b.ua&&b.ua.next().value);f||(b.ua=b.stream.segmentIndex.Wb(c,!1,a),f=b.ua&&b.ua.next().value);return f}
461
- function am(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C;return O(function(y){switch(y.g){case 1:e=Uc;f=b.stream;g=b.ua;b.fb=!0;ta(y,2);if(2==d.zc())throw new U(1,1,1011);return E(y,bm(a,b,d),4);case 4:Jg(a.l);if(a.A)return y.return();h="video/mp4"==f.mimeType||"audio/mp4"==f.mimeType;k=window.ReadableStream;if(a.h.lowLatencyMode&&k&&h&&("HLS"!=a.m.type||d.m))return n=new Uint8Array(0),r=p=!1,v=function(B){var D,K,G,J;return O(function(I){switch(I.g){case 1:if(p)return I.return();r=!0;Jg(a.l);if(a.A)return I.return();
462
- ta(I,2);n=cm(n,B);D=!1;K=0;(new Pg).box("mdat",function(H){K=H.size+H.start;D=!0}).parse(n,!1,!0);if(!D){I.B(4);break}G=n.subarray(0,K);n=n.subarray(K);return E(I,dm(a,b,c,f,d,G,!0),5);case 5:b.Y&&b.ua&&ml(b.Y,d.startTime,!0);case 4:va(I,0);break;case 2:u=J=wa(I),F(I)}})},E(y,em(a,b,d,v),9);l=em(a,b,d);return E(y,l,7);case 7:m=y.h;Jg(a.l);if(a.A)return y.return();Jg(a.l);return b.nc?(b.fb=!1,Ml(a,b,0),y.return()):E(y,dm(a,b,c,f,d,m),6);case 9:w=y.h;if(u)throw u;if(r){y.B(10);break}p=!0;Jg(a.l);return a.A?
463
- y.return():b.nc?(b.fb=!1,Ml(a,b,0),y.return()):E(y,dm(a,b,c,f,d,w),10);case 10:b.Y&&b.ua&&ml(b.Y,d.startTime,!0);case 6:Jg(a.l);if(a.A)return y.return();b.ob=d;g.next();b.fb=!1;b.Qg=!1;A=a.g.ka.Mb();z=A[b.type];cb(JSON.stringify(z));b.nc||a.g.Mg(d,b.stream);Ml(a,b,0);va(y,0);break;case 2:C=wa(y);Jg(a.l,C);if(a.A)return y.return();b.fb=!1;if(7001==C.code)b.fb=!1,El(b),Ml(a,b,0),y.B(0);else if(b.type==e.Ga&&a.h.ignoreTextStreamFailures)a.i.delete(e.Ga),y.B(0);else if(3017==C.code)fm(a,b,C),y.B(0);else return b.Ud=
464
- !0,1==C.category&&b.Y&&sl(b.Y,d),C.severity=2,E(y,Yl(a,b,C),0)}})}function gm(a,b,c){var d,e,f,g,h;return O(function(k){if(1==k.g)return d=b,d.cryptoKey?k.B(2):E(k,d.fetchKey(),3);e=d.iv;if(!e)for(e=Gb(new ArrayBuffer(16)),f=d.firstMediaSequenceNumber+c,g=e.byteLength-1;0<=g;g--)e[g]=f&255,f>>=8;"CBC"==b.blockCipherMode?h={name:"AES-CBC",iv:e}:h={name:"AES-CTR",counter:e,length:64};return k.return(window.crypto.subtle.decrypt(h,d.cryptoKey,a))})}
461
+ function am(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C;return O(function(y){switch(y.g){case 1:e=Uc;f=b.stream;g=b.ua;b.fb=!0;ta(y,2);if(2==d.Ac())throw new U(1,1,1011);return E(y,bm(a,b,d),4);case 4:Jg(a.l);if(a.A)return y.return();h="video/mp4"==f.mimeType||"audio/mp4"==f.mimeType;k=window.ReadableStream;if(a.h.lowLatencyMode&&k&&h&&("HLS"!=a.m.type||d.m))return n=new Uint8Array(0),r=p=!1,v=function(B){var D,K,G,J;return O(function(I){switch(I.g){case 1:if(p)return I.return();r=!0;Jg(a.l);if(a.A)return I.return();
462
+ ta(I,2);n=cm(n,B);D=!1;K=0;(new Pg).box("mdat",function(H){K=H.size+H.start;D=!0}).parse(n,!1,!0);if(!D){I.B(4);break}G=n.subarray(0,K);n=n.subarray(K);return E(I,dm(a,b,c,f,d,G,!0),5);case 5:b.Z&&b.ua&&ml(b.Z,d.startTime,!0);case 4:va(I,0);break;case 2:u=J=wa(I),F(I)}})},E(y,em(a,b,d,v),9);l=em(a,b,d);return E(y,l,7);case 7:m=y.h;Jg(a.l);if(a.A)return y.return();Jg(a.l);return b.qc?(b.fb=!1,Ml(a,b,0),y.return()):E(y,dm(a,b,c,f,d,m),6);case 9:w=y.h;if(u)throw u;if(r){y.B(10);break}p=!0;Jg(a.l);return a.A?
463
+ y.return():b.qc?(b.fb=!1,Ml(a,b,0),y.return()):E(y,dm(a,b,c,f,d,w),10);case 10:b.Z&&b.ua&&ml(b.Z,d.startTime,!0);case 6:Jg(a.l);if(a.A)return y.return();b.ob=d;g.next();b.fb=!1;b.Qg=!1;A=a.g.ka.Mb();z=A[b.type];cb(JSON.stringify(z));b.qc||a.g.Mg(d,b.stream);Ml(a,b,0);va(y,0);break;case 2:C=wa(y);Jg(a.l,C);if(a.A)return y.return();b.fb=!1;if(7001==C.code)b.fb=!1,El(b),Ml(a,b,0),y.B(0);else if(b.type==e.Ga&&a.h.ignoreTextStreamFailures)a.i.delete(e.Ga),y.B(0);else if(3017==C.code)fm(a,b,C),y.B(0);else return b.Ud=
464
+ !0,1==C.category&&b.Z&&sl(b.Z,d),C.severity=2,E(y,Yl(a,b,C),0)}})}function gm(a,b,c){var d,e,f,g,h;return O(function(k){if(1==k.g)return d=b,d.cryptoKey?k.B(2):E(k,d.fetchKey(),3);e=d.iv;if(!e)for(e=Gb(new ArrayBuffer(16)),f=d.firstMediaSequenceNumber+c,g=e.byteLength-1;0<=g;g--)e[g]=f&255,f>>=8;"CBC"==b.blockCipherMode?h={name:"AES-CBC",iv:e}:h={name:"AES-CTR",counter:e,length:64};return k.return(window.crypto.subtle.decrypt(h,d.cryptoKey,a))})}
465
465
  function cm(a,b){var c=new Uint8Array(a.length+b.length);c.set(a);c.set(b,a.length);return c}function fm(a,b,c){if(!Array.from(a.i.values()).some(function(e){return e!=b&&e.Qg})){if(0<a.h.maxDisabledTime&&a.g.He(b.stream,a.h.maxDisabledTime))return;var d=Math.round(100*a.F);if(20<d)a.F-=.2;else if(4<d)a.F-=.04;else{b.Ud=!0;a.A=!0;a.g.onError(c);return}b.Qg=!0}Ml(a,b,4)}
466
466
  function bm(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v;return O(function(w){switch(w.g){case 1:d=Uc;e=[];f=Math.max(0,Math.max(c.appendWindowStart,a.O)-.1);g=Math.min(c.appendWindowEnd,a.N)+.01;h=Ie(b.stream.codecs);k=Je(b.stream.mimeType);l=c.timestampOffset;if(l==b.Fg&&f==b.Dg&&g==b.Cg&&h==b.Eg&&k==b.Oh){w.B(2);break}m=b.Eg&&b.Oh&&Ak(a.g.ka,b.type,k,h);if(!m){w.B(3);break}n=null;b.type===d.ra?n=a.i.get(d.aa):b.type===d.aa&&(n=a.i.get(d.ra));if(!n){w.B(3);break}return E(w,Fl(n).catch(function(){}),5);
467
- case 5:n.fd=null,Ul(a,n);case 3:return p=function(){var A,z,C;return O(function(y){if(1==y.g)return A=new Map,a.j.audio&&A.set(d.aa,a.j.audio),a.j.video&&A.set(d.ra,a.j.video),ta(y,2),b.Dg=f,b.Cg=g,b.Eg=h,b.Oh=k,b.Fg=l,z=a.m.sequenceMode||"HLS"==a.m.type,E(y,rk(a.g.ka,b.type,l,f,g,z,c.mimeType||b.stream.mimeType,c.codecs||b.stream.codecs,A),4);if(2!=y.g)return va(y,0);C=wa(y);b.Dg=null;b.Cg=null;b.Eg=null;b.Fg=null;throw C;})},E(w,p(),2);case 2:return Hi(c.sa,b.fd)||(b.fd=c.sa,c.l&&c.sa&&(r=em(a,
468
- b,c.sa),u=function(){var A,z,C,y,B,D,K;return O(function(G){switch(G.g){case 1:return ta(G,2),E(G,r,4);case 4:return A=G.h,Jg(a.l),z=null,C=new Map,y={projection:null,hfov:null},B=new Pg,B.box("moov",Ug).box("trak",Ug).box("mdia",Ug).W("mdhd",function(J){z=aj(J.reader,J.version).timescale}).box("hdlr",function(J){J=J.reader;J.skip(8);switch(J.Ic()){case "soun":C.set(d.aa,z);break;case "vide":C.set(d.ra,z)}z=null}).box("minf",Ug).box("stbl",Ug).W("stsd",Wg).box("encv",Xg).box("avc1",Xg).box("avc3",
469
- Xg).box("hev1",Xg).box("hvc1",Xg).box("dvav",Xg).box("dva1",Xg).box("dvh1",Xg).box("dvhe",Xg).box("vexu",Ug).box("proj",Ug).W("prji",function(J){J=J.reader.Ic();y.projection=J}).box("hfov",function(J){J=J.reader.T()/1E3;y.hfov=J}).parse(A),hm(a,y),C.has(b.type)?c.sa.timescale=C.get(b.type):null!=z&&(c.sa.timescale=z),D=b.stream.closedCaptions&&0<b.stream.closedCaptions.size,E(G,a.g.sh(b.type,A),5);case 5:return E(G,ik(a.g.ka,b.type,A,null,b.stream,D),6);case 6:va(G,0);break;case 2:throw K=wa(G),b.fd=
467
+ case 5:n.gd=null,Ul(a,n);case 3:return p=function(){var A,z,C;return O(function(y){if(1==y.g)return A=new Map,a.j.audio&&A.set(d.aa,a.j.audio),a.j.video&&A.set(d.ra,a.j.video),ta(y,2),b.Dg=f,b.Cg=g,b.Eg=h,b.Oh=k,b.Fg=l,z=a.m.sequenceMode||"HLS"==a.m.type,E(y,rk(a.g.ka,b.type,l,f,g,z,c.mimeType||b.stream.mimeType,c.codecs||b.stream.codecs,A),4);if(2!=y.g)return va(y,0);C=wa(y);b.Dg=null;b.Cg=null;b.Eg=null;b.Fg=null;throw C;})},E(w,p(),2);case 2:return Hi(c.sa,b.gd)||(b.gd=c.sa,c.l&&c.sa&&(r=em(a,
468
+ b,c.sa),u=function(){var A,z,C,y,B,D,K;return O(function(G){switch(G.g){case 1:return ta(G,2),E(G,r,4);case 4:return A=G.h,Jg(a.l),z=null,C=new Map,y={projection:null,hfov:null},B=new Pg,B.box("moov",Ug).box("trak",Ug).box("mdia",Ug).W("mdhd",function(J){z=aj(J.reader,J.version).timescale}).box("hdlr",function(J){J=J.reader;J.skip(8);switch(J.Jc()){case "soun":C.set(d.aa,z);break;case "vide":C.set(d.ra,z)}z=null}).box("minf",Ug).box("stbl",Ug).W("stsd",Wg).box("encv",Xg).box("avc1",Xg).box("avc3",
469
+ Xg).box("hev1",Xg).box("hvc1",Xg).box("dvav",Xg).box("dva1",Xg).box("dvh1",Xg).box("dvhe",Xg).box("vexu",Ug).box("proj",Ug).W("prji",function(J){J=J.reader.Jc();y.projection=J}).box("hfov",function(J){J=J.reader.T()/1E3;y.hfov=J}).parse(A),hm(a,y),C.has(b.type)?c.sa.timescale=C.get(b.type):null!=z&&(c.sa.timescale=z),D=b.stream.closedCaptions&&0<b.stream.closedCaptions.size,E(G,a.g.sh(b.type,A),5);case 5:return E(G,ik(a.g.ka,b.type,A,null,b.stream,D),6);case 6:va(G,0);break;case 2:throw K=wa(G),b.gd=
470
470
  null,K;}})},a.g.Uj(c.startTime,c.sa),e.push(u()))),a.m.sequenceMode&&(v=b.ob?b.ob.j:null,c.j!=v&&e.push(tk(a.g.ka,b.type,c.startTime))),E(w,Promise.all(e),0)}})}
471
- function dm(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h,k,l,m,n,p;return O(function(r){switch(r.g){case 1:h=d.closedCaptions&&0<d.closedCaptions.size;l=null!=d.emsgSchemeIdUris&&0<d.emsgSchemeIdUris.length||a.h.dispatchAllEmsgBoxes;m=a.h.parsePrftBox&&!a.H;if(l||m)k=new Pg;l&&k.W("emsg",function(u){var v=d.emsgSchemeIdUris;if(0===u.version){var w=u.reader.Ic();var A=u.reader.Ic();var z=u.reader.T();var C=u.reader.T();var y=u.reader.T();var B=u.reader.T();var D=e.startTime+C/z}else z=u.reader.T(),D=u.reader.md()/
472
- z+e.timestampOffset,C=D-e.startTime,y=u.reader.T(),B=u.reader.T(),w=u.reader.Ic(),A=u.reader.Ic();u=u.reader.Hb(u.reader.getLength()-u.reader.Ja());if(v&&v.includes(w)||a.h.dispatchAllEmsgBoxes)"urn:mpeg:dash:event:2012"==w?a.g.Vj():(v=(new Map).set("detail",{startTime:D,endTime:D+y/z,schemeIdUri:w,value:A,timescale:z,presentationTimeDelta:C,eventDuration:y,id:B,messageData:u}),v=new S("emsg",v),v.cancelable=!0,a.g.onEvent(v),v.defaultPrevented||"https://aomedia.org/emsg/ID3"!=w&&"https://developer.apple.com/streaming/emsg-id3"!=
471
+ function dm(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h,k,l,m,n,p;return O(function(r){switch(r.g){case 1:h=d.closedCaptions&&0<d.closedCaptions.size;l=null!=d.emsgSchemeIdUris&&0<d.emsgSchemeIdUris.length||a.h.dispatchAllEmsgBoxes;m=a.h.parsePrftBox&&!a.H;if(l||m)k=new Pg;l&&k.W("emsg",function(u){var v=d.emsgSchemeIdUris;if(0===u.version){var w=u.reader.Jc();var A=u.reader.Jc();var z=u.reader.T();var C=u.reader.T();var y=u.reader.T();var B=u.reader.T();var D=e.startTime+C/z}else z=u.reader.T(),D=u.reader.md()/
472
+ z+e.timestampOffset,C=D-e.startTime,y=u.reader.T(),B=u.reader.T(),w=u.reader.Jc(),A=u.reader.Jc();u=u.reader.Hb(u.reader.getLength()-u.reader.Ja());if(v&&v.includes(w)||a.h.dispatchAllEmsgBoxes)"urn:mpeg:dash:event:2012"==w?a.g.Vj():(v=(new Map).set("detail",{startTime:D,endTime:D+y/z,schemeIdUri:w,value:A,timescale:z,presentationTimeDelta:C,eventDuration:y,id:B,messageData:u}),v=new S("emsg",v),v.cancelable=!0,a.g.onEvent(v),v.defaultPrevented||"https://aomedia.org/emsg/ID3"!=w&&"https://developer.apple.com/streaming/emsg-id3"!=
473
473
  w||(w=Xi(u),w.length&&e&&a.g.cf([{cueTime:e.startTime,data:u,frames:w,dts:e.startTime,pts:e.startTime}],0,e.endTime)))});m&&k.W("prft",function(u){if(!a.H&&e.sa.timescale){var v=u.reader,w=u.version;v.T();u=v.T();var A=v.T();u=1E3*u+A/Math.pow(2,32)*1E3;0===w?v=v.T():(w=v.T(),v=v.T(),v=w*Math.pow(2,32)+v);u=(new Date((new Date(Date.UTC(1900,0,1,0,0,0))).getTime()+u)).getTime();v=(new Map).set("detail",{wallClockTime:u,programStartDate:new Date(u-v/e.sa.timescale*1E3)});v=new S("prft",v);a.g.onEvent(v);
474
474
  a.H=!0}});(l||m)&&k.parse(f);return E(r,im(a,b,c),2);case 2:return Jg(a.l),n=b.ke,b.ke=!1,p=b.ph,b.ph=!1,E(r,a.g.sh(b.type,f),3);case 3:return E(r,ik(a.g.ka,b.type,f,e,d,h,n,p,g),4);case 4:Jg(a.l),F(r)}})}function im(a,b,c){var d,e,f,g;return O(function(h){if(1==h.g){d=Math.max(a.h.bufferBehind,a.m.presentationTimeline.g);e=Wj(a.g.ka,b.type);if(null==e)return h.return();f=c-e;g=f-d;return g<=a.h.evictionGoal?h.return():E(h,a.g.ka.remove(b.type,e,e+g),2)}Jg(a.l);F(h)})}
475
475
  function Zl(a){return a&&a.type==Sc&&("application/cea-608"==a.stream.mimeType||"application/cea-708"==a.stream.mimeType)}
476
- function em(a,b,c,d){var e,f,g,h,k;return O(function(l){switch(l.g){case 1:if(e=c.Sd())return l.return(e);f=null;if(b.Y){var m=b.Y,n=m.h;c instanceof Gi&&(n=m.j);n.has(c)?(m=n.get(c),d&&(m.eh=d),f=m.df):f=null}f||(f=Vl(c,b.stream,d||null,a.h.retryParameters,a.g.Zb));g=0;b.ua&&(g=b.ua.h);b.Ab=f;return E(l,f.promise,2);case 2:h=l.h;b.Ab=null;k=h.data;if(!c.aesKey){l.B(3);break}return E(l,gm(k,c.aesKey,g),4);case 4:k=l.h;case 3:return l.return(k)}})}
476
+ function em(a,b,c,d){var e,f,g,h,k;return O(function(l){switch(l.g){case 1:if(e=c.Sd())return l.return(e);f=null;if(b.Z){var m=b.Z,n=m.h;c instanceof Gi&&(n=m.j);n.has(c)?(m=n.get(c),d&&(m.eh=d),f=m.df):f=null}f||(f=Vl(c,b.stream,d||null,a.h.retryParameters,a.g.Zb));g=0;b.ua&&(g=b.ua.h);b.Ab=f;return E(l,f.promise,2);case 2:h=l.h;b.Ab=null;k=h.data;if(!c.aesKey){l.B(3);break}return E(l,gm(k,c.aesKey,g),4);case 4:k=l.h;case 3:return l.return(k)}})}
477
477
  function Vl(a,b,c,d,e){var f=a instanceof Ii?a:void 0,g=f?1:0;a=Bl(a.P(),a.Wa,a.Da,d,c);a.contentType=b.type;return e.request(Gg,a,{type:g,stream:b,segment:f})}
478
- function Sl(a,b,c,d){var e,f;return O(function(g){if(1==g.g)return b.nc=!1,b.wf=!1,b.Fe=0,b.Kd=!0,b.ob=null,b.ua=null,b.Y&&!a.o.has(b.stream)&&tl(b.Y),d?(e=a.g.Le(),f=a.g.ka.getDuration(),E(g,a.g.ka.remove(b.type,e+d,f),3)):E(g,qk(a.g.ka,b.type),4);if(3!=g.g)return Jg(a.l),c?E(g,a.g.ka.flush(b.type),3):g.B(3);Jg(a.l);b.Kd=!1;b.endOfStream=!1;b.fb||b.Jb||Ml(a,b,0);F(g)})}
478
+ function Sl(a,b,c,d){var e,f;return O(function(g){if(1==g.g)return b.qc=!1,b.wf=!1,b.Fe=0,b.Kd=!0,b.ob=null,b.ua=null,b.Z&&!a.o.has(b.stream)&&tl(b.Z),d?(e=a.g.Le(),f=a.g.ka.getDuration(),E(g,a.g.ka.remove(b.type,e+d,f),3)):E(g,qk(a.g.ka,b.type),4);if(3!=g.g)return Jg(a.l),c?E(g,a.g.ka.flush(b.type),3):g.B(3);Jg(a.l);b.Kd=!1;b.endOfStream=!1;b.fb||b.Jb||Ml(a,b,0);F(g)})}
479
479
  function Ml(a,b,c){var d=b.type;if(d!=Sc||a.i.has(d))b.Jb=(new Tb(function(){var e;return O(function(f){if(1==f.g)return ta(f,2),E(f,Wl(a,b),4);if(2!=f.g)return va(f,0);e=wa(f);if(a.g)a.g.onError(e);F(f)})})).V(c)}function El(a){null!=a.Jb&&(a.Jb.stop(),a.Jb=null)}function Fl(a){return O(function(b){return a.Ab?E(b,a.Ab.abort(),0):b.B(0)})}
480
480
  function Yl(a,b,c){var d;return O(function(e){if(1==e.g)return E(e,kg(a.K),2);Jg(a.l);d=0===a.h.maxDisabledTime&&1011==c.code?1:a.h.maxDisabledTime;1===c.category&&0<d&&(c.handled=a.g.He(b.stream,d),c.handled&&(c.severity=1));if(!c.handled||1011!=c.code)a.g.onError(c);c.handled||a.h.failureCallback(c);F(e)})}
481
- function jm(a){var b,c,d,e,f,g;return O(function(h){if(1==h.g){b=Date.now()/1E3;c=a.h.minTimeBetweenRecoveries;if(!a.h.allowMediaSourceRecoveries||b-a.L<c)return h.return(!1);a.L=b;d=Uc;if(e=a.i.get(d.aa))e.fd=null,Ul(a,e),Fl(e).catch(function(){});if(f=a.i.get(d.ra))f.fd=null,Ul(a,f),Fl(f).catch(function(){});g=new Map;a.j.audio&&g.set(d.aa,a.j.audio);a.j.video&&g.set(d.ra,a.j.video);return E(h,zk(a.g.ka,g),2)}return h.return(!0)})}
481
+ function jm(a){var b,c,d,e,f,g;return O(function(h){if(1==h.g){b=Date.now()/1E3;c=a.h.minTimeBetweenRecoveries;if(!a.h.allowMediaSourceRecoveries||b-a.L<c)return h.return(!1);a.L=b;d=Uc;if(e=a.i.get(d.aa))e.gd=null,Ul(a,e),Fl(e).catch(function(){});if(f=a.i.get(d.ra))f.gd=null,Ul(a,f),Fl(f).catch(function(){});g=new Map;a.j.audio&&g.set(d.aa,a.j.audio);a.j.video&&g.set(d.ra,a.j.video);return E(h,zk(a.g.ka,g),2)}return h.return(!0)})}
482
482
  function hm(a,b){if(a.I.projection!=b.projection||a.I.hfov!=b.hfov){if(null!=b.projection||null!=b.hfov){var c=(new Map).set("detail",b);c=new S("spatialvideoinfo",c)}else c=new S("nospatialvideoinfo");c.cancelable=!0;a.g.onEvent(c);a.I=b}};function km(){}
483
483
  function lm(a,b,c,d,e){var f=e in d;var g=f?c.constructor==Object&&0==Object.keys(d).length:c.constructor==Object&&0==Object.keys(c).length;var h=f||g,k=!0,l;for(l in b){var m=e+"."+l,n=f?d[e]:c[l];h||l in c?void 0===b[l]?void 0===n||h?delete a[l]:a[l]=Xe(n):g?a[l]=b[l]:n.constructor==Object&&b[l]&&b[l].constructor==Object?(a[l]||(a[l]=Xe(n)),m=lm(a[l],b[l],n,d,m),k=k&&m):typeof b[l]!=typeof n||null==b[l]||"function"!=typeof b[l]&&b[l].constructor!=n.constructor?(Xa("Invalid config, wrong type for "+m),
484
484
  k=!1):("function"==typeof c[l]&&c[l].length!=b[l].length&&Ya("Unexpected number of arguments for "+m),a[l]=b[l]):(Xa("Invalid config, unrecognized key "+m),k=!1)}return k}function mm(a,b){for(var c={},d=c,e=0,f=0;;){e=a.indexOf(".",e);if(0>e)break;if(0==e||"\\"!=a[e-1])f=a.substring(f,e).replace(/\\\./g,"."),d[f]={},d=d[f],f=e+1;e+=1}d[a.substring(f).replace(/\\\./g,".")]=b;return c}function nm(a,b){return a&&b}
@@ -502,19 +502,19 @@ preferredTextLanguage:"",preferredVariantRole:"",preferredTextRole:"",preferredA
502
502
  playRangeStart:0,playRangeEnd:Infinity,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:g,skipPlayDetection:h,supportsMultipleMediaElements:k}};f.trackSelectionCallback=function(m){return O(function(n){return n.return(ym(m,
503
503
  l.preferredAudioLanguage,l.preferredVideoHdrLevel))})};return l}function zm(a,b,c){var d={".drm.keySystemsMapping":"",".drm.servers":"",".drm.clearKeys":"",".drm.advanced":{distinctiveIdentifierRequired:!1,persistentStateRequired:!1,videoRobustness:"",audioRobustness:"",sessionType:"",serverCertificate:new Uint8Array(0),serverCertificateUri:"",individualizationServer:"",headers:{}}};return lm(a,b,c||vm(),d,"")}
504
504
  function ym(a,b,c){var d=c;"AUTO"==d&&(d=window.matchMedia("(color-gamut: p3)").matches?"PQ":"SDR");var e=a.filter(function(h){return"variant"!=h.type||h.hdr&&h.hdr!=d?!1:!0});c=[];var f=gd(b,e.map(function(h){return h.language}));f&&(c=e.filter(function(h){return Xc(h.language)==f}));0==c.length&&(c=e.filter(function(h){return h.primary}));0==c.length&&(e.map(function(h){return h.language}),c=e);var g=c.filter(function(h){return h.height&&480>=h.height});g.length&&(g.sort(function(h,k){return k.height-
505
- h.height}),c=g.filter(function(h){return h.height==g[0].height}));b=[];c.length&&(e=Math.floor(c.length/2),c.sort(function(h,k){return h.bandwidth-k.bandwidth}),b.push(c[e]));a=t(a);for(c=a.next();!c.done;c=a.next())c=c.value,c.type!=Sc&&"image"!=c.type||b.push(c);return b}function wm(a){return nm([a],a)}function xm(a){return nm([a],a)}P("shaka.util.PlayerConfiguration",um);um.mergeConfigObjects=zm;um.createDefault=vm;function Am(a,b,c,d,e){gb.call(this);this.L=a;this.R=b;this.xa=e.networkingEngine;this.S=d;this.o=null;this.jb=c;this.qa=0;this.Na=e.Vc;this.F=e.Pj;this.Za=e.Qj;this.g=e.config;this.j=this.G=this.h=null;this.ea=!1;this.H=e.Zj;this.ma=!1;this.l=null;this.ba=!1;this.i=this.A=null;this.$=!1;this.K=new Map;this.na=!1;this.Ba=e.Yj;this.Z=new jl;this.m=new lg;this.N=null;this.u=!1;this.Ea=e.Ji;this.ha=null;this.Ha=e.Ii;this.O=!1;this.J=[];this.I=[]}na(Am,gb);
506
- function Bm(a,b,c){(a=b?a.I:a.J)?a.push(c):c()}function Cm(a){if(a.I)for(var b=t(a.I),c=b.next();!c.done;c=b.next())c=c.value,c();a.I=null}function Dm(a,b){a.N=b;a.O=!0;if(a.J){b=t(a.J);for(var c=b.next();!c.done;c=b.next())c=c.value,c()}a.J=null}q=Am.prototype;q.getStartTime=function(){return this.S};q.Zc=function(){return this.L};q.rg=function(){return this.h};function Em(a){a.$=!0;return a.i}function Fm(a){a.ea=!0;return a.j}function Gm(a){a.ma=!0;return a.H}q.getStats=function(){return this.Z};
505
+ h.height}),c=g.filter(function(h){return h.height==g[0].height}));b=[];c.length&&(e=Math.floor(c.length/2),c.sort(function(h,k){return h.bandwidth-k.bandwidth}),b.push(c[e]));a=t(a);for(c=a.next();!c.done;c=a.next())c=c.value,c.type!=Sc&&"image"!=c.type||b.push(c);return b}function wm(a){return nm([a],a)}function xm(a){return nm([a],a)}P("shaka.util.PlayerConfiguration",um);um.mergeConfigObjects=zm;um.createDefault=vm;function Am(a,b,c,d,e){gb.call(this);this.L=a;this.R=b;this.xa=e.networkingEngine;this.S=d;this.o=null;this.jb=c;this.qa=0;this.Na=e.Wc;this.F=e.Pj;this.Za=e.Qj;this.g=e.config;this.j=this.G=this.h=null;this.ea=!1;this.H=e.Zj;this.ma=!1;this.l=null;this.ba=!1;this.i=this.A=null;this.$=!1;this.K=new Map;this.na=!1;this.Ba=e.Yj;this.X=new jl;this.m=new lg;this.N=null;this.u=!1;this.Ea=e.Ji;this.ha=null;this.Ha=e.Ii;this.O=!1;this.J=[];this.I=[]}na(Am,gb);
506
+ function Bm(a,b,c){(a=b?a.I:a.J)?a.push(c):c()}function Cm(a){if(a.I)for(var b=t(a.I),c=b.next();!c.done;c=b.next())c=c.value,c();a.I=null}function Dm(a,b){a.N=b;a.O=!0;if(a.J){b=t(a.J);for(var c=b.next();!c.done;c=b.next())c=c.value,c()}a.J=null}q=Am.prototype;q.getStartTime=function(){return this.S};q.$c=function(){return this.L};q.rg=function(){return this.h};function Em(a){a.$=!0;return a.i}function Fm(a){a.ea=!0;return a.j}function Gm(a){a.ma=!0;return a.H}q.getStats=function(){return this.X};
507
507
  function Hm(a){a.ba=!0;return a.l}function Im(a){a.na=!0;return a.K}
508
508
  q.start=function(){var a=this;(function(){var b;return O(function(c){switch(c.g){case 1:return E(c,Promise.resolve(),2);case 2:return ta(c,3),E(c,Jm(a),5);case 5:return Km(a),E(c,Lm(a),6);case 6:Km(a);a.o||(a.o=new Wf(a.g.preferredAudioLanguage,a.g.preferredVariantRole,a.g.preferredAudioChannelCount,a.g.preferredVideoHdrLevel,a.g.preferSpatialAudio,a.g.preferredVideoLayout,a.g.preferredAudioLabel,a.g.preferredVideoLabel,a.g.mediaSource.codecSwitchingStrategy,a.g.manifest.dash.enableAudioGroups));
509
509
  if(a.Ha){var d=a.g.abrFactory;a.A=d;a.i=d();a.i.configure(a.g.abr)}if(a.Ea){d=a.h.presentationTimeline.U();var e=Ff(a.h.variants);e=a.o.create(e);a.i.configure(a.g.abr);a.i.setVariants(Array.from(e.values()));if(e=a.i.chooseVariant(!0))a.ha=e,e.video&&Mm(a,e.video,d),e.audio&&Mm(a,e.audio,d)}return E(c,void 0,7);case 7:Km(a);a.m.resolve();va(c,0);break;case 3:b=wa(c),a.m.reject(b),F(c)}})})()};q.dispatchEvent=function(a){return this.N?this.N.dispatchEvent(a):gb.prototype.dispatchEvent.call(this,a)};
510
510
  q.onError=function(a){2===a.severity&&(this.m.reject(a),this.destroy());var b=(new Map).set("detail",a);b=new S("error",b);this.dispatchEvent(b);b.defaultPrevented&&(a.handled=!0)};function Km(a){if(a.u)throw new U(2,7,7003);}function Nm(a,b){a.dispatchEvent(new S("onstatechange",(new Map).set("state",b)))}
511
- function Jm(a){var b,c,d,e,f;return O(function(g){if(1==g.g){Nm(a,"manifest-parser");a.j||(a.G=Ai(a.L,a.R),a.j=a.G(),a.j.configure(a.g.manifest));b=Date.now()/1E3;Nm(a,"manifest");if(a.h)return g.B(2);c=a;return E(g,a.j.start(a.L,a.Za),3)}2!=g.g&&(c.h=g.h);d=new S("manifestparsed",void 0);a.dispatchEvent(d);if(0==a.h.variants.length)throw new U(2,4,4036);Om(a.h);e=Date.now()/1E3;f=e-b;a.Z.H=f;F(g)})}
511
+ function Jm(a){var b,c,d,e,f;return O(function(g){if(1==g.g){Nm(a,"manifest-parser");a.j||(a.G=Ai(a.L,a.R),a.j=a.G(),a.j.configure(a.g.manifest));b=Date.now()/1E3;Nm(a,"manifest");if(a.h)return g.B(2);c=a;return E(g,a.j.start(a.L,a.Za),3)}2!=g.g&&(c.h=g.h);d=new S("manifestparsed",void 0);a.dispatchEvent(d);if(0==a.h.variants.length)throw new U(2,4,4036);Om(a.h);e=Date.now()/1E3;f=e-b;a.X.H=f;F(g)})}
512
512
  function Lm(a){var b,c,d,e,f;return O(function(g){switch(g.g){case 1:Nm(a,"drm-engine");a.qa=Date.now()/1E3;a.l=a.Na();a.F.g=a.l;a.l.configure(a.g.drm);var h=a.F;b=df(a.h.variants,h.h.restrictions,h.i);if(!b){g.B(2);break}c=new S("trackschanged",void 0);return E(g,Promise.resolve(),3);case 3:Km(a),a.dispatchEvent(c);case 2:return d=Ff(a.h.variants),E(g,Qh(a.l,d,a.h.offlineSessionIds),4);case 4:return Km(a),E(g,ui(a.F,a.h),5);case 5:e=g.h;if(!e){g.B(0);break}f=new S("trackschanged",void 0);return E(g,
513
513
  Promise.resolve(),7);case 7:a.dispatchEvent(f),F(g)}})}q.configure=function(a,b){a=mm(a,b);zm(this.g,a)};q.getConfiguration=function(){return Xe(this.g)};
514
514
  function Mm(a,b,c){var d,e,f,g,h;O(function(k){if(1==k.g)return d=a.g.streaming.segmentPrefetchLimit||2,e=new kl(d,b,function(l,m,n){return Vl(l,m,n||null,a.g.streaming.retryParameters,a.xa)},!1),a.K.set(b.id,e),E(k,b.createSegmentIndex(),2);f=a.S||0;(h=(g=b.segmentIndex.Wb(f))?g.current():null)||(h=b.segmentIndex.get(0));h&&(c?h.sa&&nl(e,h.sa):ml(e,h.startTime));F(k)})}q.Hk=function(){return this.m};
515
515
  q.destroy=function(){var a=this,b,c,d;return O(function(e){switch(e.g){case 1:a.u=!0;if(!a.j||a.ea){e.B(2);break}return E(e,a.j.stop(),2);case 2:if(!a.i||a.$){e.B(4);break}return E(e,a.i.stop(),4);case 4:a.H&&!a.ma&&a.H.release();if(!a.l||a.ba){e.B(6);break}return E(e,a.l.destroy(),6);case 6:if(0<a.K.size&&!a.na)for(b=t(a.K.values()),c=b.next();!c.done;c=b.next())d=c.value,tl(d);F(e)}})};
516
- function Om(a){function b(c){return c.video&&c.audio||c.video&&c.video.codecs.includes(",")}a.variants.some(b)&&(a.variants=a.variants.filter(b))}P("shaka.media.PreloadManager",Am);Am.prototype.destroy=Am.prototype.destroy;Am.prototype.waitForFinish=Am.prototype.Hk;function Pm(a,b){gb.call(this);var c=this;this.i=a;this.l=b;this.g=new Map;this.m=[{Qc:null,Pc:Qm,Dc:function(d,e){return Rm(c,"enter",d,e)}},{Qc:Sm,Pc:Qm,Dc:function(d,e){return Rm(c,"enter",d,e)}},{Qc:Tm,Pc:Qm,Dc:function(d,e){return Rm(c,"enter",d,e)}},{Qc:Qm,Pc:Sm,Dc:function(d,e){return Rm(c,"exit",d,e)}},{Qc:Qm,Pc:Tm,Dc:function(d,e){return Rm(c,"exit",d,e)}},{Qc:Sm,Pc:Tm,Dc:function(d,e){return Rm(c,"skip",d,e)}},{Qc:Tm,Pc:Sm,Dc:function(d,e){return Rm(c,"skip",d,e)}}];this.h=new od;this.h.s(this.i,
517
- "regionremove",function(d){c.g.delete(d.region)})}na(Pm,gb);Pm.prototype.release=function(){this.i=null;this.g.clear();this.h.release();this.h=null;gb.prototype.release.call(this)};Pm.prototype.j=function(a,b){if(!this.l||0!=a){this.l=!1;for(var c=t(this.i.g),d=c.next();!d.done;d=c.next()){d=d.value;var e=this.g.get(d),f=a<d.startTime?Sm:a>d.endTime?Tm:Qm;this.g.set(d,f);for(var g=t(this.m),h=g.next();!h.done;h=g.next())h=h.value,h.Qc==e&&h.Pc==f&&h.Dc(d,b)}}};
516
+ function Om(a){function b(c){return c.video&&c.audio||c.video&&c.video.codecs.includes(",")}a.variants.some(b)&&(a.variants=a.variants.filter(b))}P("shaka.media.PreloadManager",Am);Am.prototype.destroy=Am.prototype.destroy;Am.prototype.waitForFinish=Am.prototype.Hk;function Pm(a,b){gb.call(this);var c=this;this.i=a;this.l=b;this.g=new Map;this.m=[{Rc:null,Qc:Qm,Ec:function(d,e){return Rm(c,"enter",d,e)}},{Rc:Sm,Qc:Qm,Ec:function(d,e){return Rm(c,"enter",d,e)}},{Rc:Tm,Qc:Qm,Ec:function(d,e){return Rm(c,"enter",d,e)}},{Rc:Qm,Qc:Sm,Ec:function(d,e){return Rm(c,"exit",d,e)}},{Rc:Qm,Qc:Tm,Ec:function(d,e){return Rm(c,"exit",d,e)}},{Rc:Sm,Qc:Tm,Ec:function(d,e){return Rm(c,"skip",d,e)}},{Rc:Tm,Qc:Sm,Ec:function(d,e){return Rm(c,"skip",d,e)}}];this.h=new od;this.h.s(this.i,
517
+ "regionremove",function(d){c.g.delete(d.region)})}na(Pm,gb);Pm.prototype.release=function(){this.i=null;this.g.clear();this.h.release();this.h=null;gb.prototype.release.call(this)};Pm.prototype.j=function(a,b){if(!this.l||0!=a){this.l=!1;for(var c=t(this.i.g),d=c.next();!d.done;d=c.next()){d=d.value;var e=this.g.get(d),f=a<d.startTime?Sm:a>d.endTime?Tm:Qm;this.g.set(d,f);for(var g=t(this.m),h=g.next();!h.done;h=g.next())h=h.value,h.Rc==e&&h.Qc==f&&h.Ec(d,b)}}};
518
518
  function Rm(a,b,c,d){b=new S(b,new Map([["region",c],["seeking",d]]));a.dispatchEvent(b)}var Sm=1,Qm=2,Tm=3;function Um(a,b,c){var d,e,f,g,h,k,l;return O(function(m){switch(m.g){case 1:var n=(new mb(a)).pb.split("/").pop().split(".");d=1==n.length?"":n.pop().toLowerCase();if(e=Vm[d])return m.return(e);f=0;g=Ag([a],c);ta(m,2);g.method="HEAD";return E(m,b.request(f,g).promise,4);case 4:h=m.h;e=h.headers["content-type"];va(m,3);break;case 2:k=wa(m);if(!k||1002!=k.code&&1001!=k.code){m.B(3);break}g.method="GET";return E(m,b.request(f,g).promise,6);case 6:l=m.h,e=l.headers["content-type"];case 3:return m.return(e?
519
519
  e.toLowerCase().split(";").shift():"")}})}
520
520
  var Vm={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"};function Wm(a,b){if(a.lineBreak)return"\n";if(a.nestedCues.length)return a.nestedCues.map(function(g){return Wm(g,a)}).join("");var c=[],d=700<=a.fontWeight,e="italic"==a.fontStyle,f=a.textDecoration.includes("underline");d&&c.push(["b"]);e&&c.push(["i"]);f&&c.push(["u"]);e=a.color;""==e&&b&&(e=b.color);d="";(e=Xm(e))&&(d+="."+e);e=a.backgroundColor;""==e&&b&&(e=b.backgroundColor);(b=Xm(e))&&(d+=".bg_"+b);d&&c.push(["c",d]);return c.reduceRight(function(g,h){var k=t(h);h=k.next().value;k=k.next().value;
@@ -524,18 +524,18 @@ case "yellow":case "#ff0":case "#ffff00":return"yellow";case "magenta":case "#f0
524
524
  function Zm(a){var b=[],c={};a=t(a);for(var d=a.next();!d.done;c={qe:c.qe},d=a.next())c.qe=d.value,b.some(function(e){return function(f){return de(e.qe,f)}}(c))||b.push(c.qe);return b}
525
525
  function $m(a){function b(d){for(var e=5381,f=d.length;f;)e=33*e^d.charCodeAt(--f);return(e>>>0).toString()}if(a.startTime>=a.endTime)return null;var c=new VTTCue(a.startTime,a.endTime,a.payload);c.id=b(a.startTime.toString())+b(a.endTime.toString())+b(a.payload);c.lineAlign=a.lineAlign;c.positionAlign=a.positionAlign;a.size&&(c.size=a.size);try{c.align=a.textAlign}catch(d){}"center"==a.textAlign&&"center"!=c.align&&(c.align="middle");"vertical-lr"==a.writingMode?c.vertical="lr":"vertical-rl"==a.writingMode&&
526
526
  (c.vertical="rl");1==a.lineInterpretation&&(c.snapToLines=!1);null!=a.line&&(c.line=a.line);null!=a.position&&(c.position=a.position);return c};function an(a,b){this.g=null;for(var c=t(Array.from(a.textTracks)),d=c.next();!d.done;d=c.next())d=d.value,"metadata"!==d.kind&&"chapters"!==d.kind&&(d.mode="disabled",d.label==b&&(this.g=d));this.g||(this.g=a.addTextTrack("subtitles",b));this.g.mode="hidden"}q=an.prototype;q.configure=function(){};q.remove=function(a,b){if(!this.g)return!1;bn(this.g,function(c){return c.startTime<b&&c.endTime>a});return!0};
527
- q.append=function(a){var b=Ym(a),c=[];a=this.g.cues?Array.from(this.g.cues):[];var d={};b=t(b);for(var e=b.next();!e.done;d={Sc:d.Sc},e=b.next())d.Sc=e.value,a.some(function(f){return function(g){return g.startTime==f.Sc.startTime&&g.endTime==f.Sc.endTime&&g.text==f.Sc.payload?!0:!1}}(d))||(e=$m(d.Sc))&&c.push(e);a=c.slice().sort(function(f,g){return f.startTime!=g.startTime?f.startTime-g.startTime:f.endTime!=g.endTime?f.endTime-g.startTime:"line"in VTTCue.prototype?c.indexOf(g)-c.indexOf(f):c.indexOf(f)-
527
+ q.append=function(a){var b=Ym(a),c=[];a=this.g.cues?Array.from(this.g.cues):[];var d={};b=t(b);for(var e=b.next();!e.done;d={Tc:d.Tc},e=b.next())d.Tc=e.value,a.some(function(f){return function(g){return g.startTime==f.Tc.startTime&&g.endTime==f.Tc.endTime&&g.text==f.Tc.payload?!0:!1}}(d))||(e=$m(d.Tc))&&c.push(e);a=c.slice().sort(function(f,g){return f.startTime!=g.startTime?f.startTime-g.startTime:f.endTime!=g.endTime?f.endTime-g.startTime:"line"in VTTCue.prototype?c.indexOf(g)-c.indexOf(f):c.indexOf(f)-
528
528
  c.indexOf(g)});a=t(a);for(d=a.next();!d.done;d=a.next())this.g.addCue(d.value)};q.destroy=function(){this.g&&(bn(this.g,function(){return!0}),this.g.mode="disabled");this.g=null;return Promise.resolve()};q.isTextVisible=function(){return"showing"==this.g.mode};q.setTextVisibility=function(a){this.g.mode=a?"showing":"hidden"};
529
529
  function bn(a,b){var c=a.mode;a.mode="showing"==c?"showing":"hidden";for(var d=t(Array.from(a.cues)),e=d.next();!e.done;e=d.next())(e=e.value)&&b(e)&&a.removeCue(e);a.mode=c}P("shaka.text.SimpleTextDisplayer",an);an.prototype.setTextVisibility=an.prototype.setTextVisibility;an.prototype.isTextVisible=an.prototype.isTextVisible;an.prototype.destroy=an.prototype.destroy;an.prototype.append=an.prototype.append;an.prototype.remove=an.prototype.remove;an.prototype.configure=an.prototype.configure;function cn(){}q=cn.prototype;q.configure=function(){};q.remove=function(){};q.append=function(){};q.destroy=function(){};q.isTextVisible=function(){return!1};q.setTextVisibility=function(){};P("shaka.text.StubTextDisplayer",cn);cn.prototype.setTextVisibility=cn.prototype.setTextVisibility;cn.prototype.isTextVisible=cn.prototype.isTextVisible;cn.prototype.destroy=cn.prototype.destroy;cn.prototype.append=cn.prototype.append;cn.prototype.remove=cn.prototype.remove;cn.prototype.configure=cn.prototype.configure;function dn(){}function W(a){return document.createElement(a)}function en(){var a=document.createElement("button");a.setAttribute("type","button");return a}function fn(a){for(;a.firstChild;)a.removeChild(a.firstChild)}P("shaka.util.Dom",dn);dn.removeAllChildren=fn;function gn(a,b,c){var d=this;this.m=!1;this.h=[];this.A=a;this.u=b;this.l=null;this.g=W("div");this.g.classList.add("shaka-text-container");this.g.style.textAlign="center";this.g.style.display="flex";this.g.style.flexDirection="column";this.g.style.alignItems="center";this.g.style.justifyContent="flex-end";this.u.appendChild(this.g);c&&c.captionsUpdatePeriod||xd("UITextDisplayer w/ config","Please migrate to initializing UITextDisplayer with a config.");this.G=(new Ub(function(){d.A.paused||hn(d)})).za(c&&
530
530
  c.captionsUpdatePeriod?c.captionsUpdatePeriod:.25);this.i=new Map;this.j=new od;this.j.s(document,"fullscreenchange",function(){hn(d,!0)});this.j.s(this.A,"seeking",function(){hn(d,!0)});this.j.s(this.A,"resize",function(){var e=d.A,f=e.videoWidth;e=e.videoHeight;f&&e?d.l=f/e:d.l=null});this.o=null;"ResizeObserver"in window&&(this.o=new ResizeObserver(function(){hn(d,!0)}),this.o.observe(this.g));this.F=new Map}q=gn.prototype;q.configure=function(a){this.G&&this.G.za(a.captionsUpdatePeriod)};
531
531
  q.append=function(a){var b=[].concat(x(this.h)),c={};a=t(Zm(a));for(var d=a.next();!d.done;c={re:c.re},d=a.next())c.re=d.value,b.some(function(e){return function(f){return de(f,e.re)}}(c))||this.h.push(c.re);hn(this)};q.destroy=function(){if(!this.g)return Promise.resolve();this.u.removeChild(this.g);this.g=null;this.m=!1;this.h=[];this.G&&this.G.stop();this.i.clear();this.j&&(this.j.release(),this.j=null);this.o&&(this.o.disconnect(),this.o=null);return Promise.resolve()};
532
532
  q.remove=function(a,b){if(!this.g)return!1;var c=this.h.length;this.h=this.h.filter(function(d){return d.startTime<a||d.endTime>=b});hn(this,c>this.h.length);return!0};q.isTextVisible=function(){return this.m};q.setTextVisibility=function(a){this.m=a};function jn(a,b){for(;null!=b;){if(b==a.g)return!0;b=b.parentElement}return!1}
533
- function kn(a,b,c,d,e){var f=!1,g=[],h=[];b=t(b);for(var k=b.next();!k.done;k=b.next()){k=k.value;e.push(k);var l=a.i.get(k),m=k.startTime<=d&&k.endTime>d,n=l?l.zi:null;l&&(g.push(l.Zf),l.Jc&&g.push(l.Jc),m||(f=!0,a.i.delete(k),l=null));m&&(h.push(k),l?jn(a,n)||(f=!0):(ln(a,k,e),l=a.i.get(k),n=l.zi,f=!0));0<k.nestedCues.length&&n&&kn(a,k.nestedCues,n,d,e);e.pop()}if(f){d=t(g);for(e=d.next();!e.done;e=d.next())e=e.value,e.parentElement&&e.parentElement.removeChild(e);h.sort(function(p,r){return p.startTime!=
534
- r.startTime?p.startTime-r.startTime:p.endTime-r.endTime});h=t(h);for(k=h.next();!k.done;k=h.next())d=a.i.get(k.value),d.Jc?(d.Jc.contains(c)&&d.Jc.removeChild(c),c.appendChild(d.Jc),d.Jc.appendChild(d.Zf)):c.appendChild(d.Zf)}}function hn(a,b){if(a.g){var c=a.A.currentTime;if(!a.m||(void 0===b?0:b)){b=t(a.F.values());for(var d=b.next();!d.done;d=b.next())fn(d.value);fn(a.g);a.i.clear();a.F.clear()}a.m&&kn(a,a.h,a.g,c,[])}}
533
+ function kn(a,b,c,d,e){var f=!1,g=[],h=[];b=t(b);for(var k=b.next();!k.done;k=b.next()){k=k.value;e.push(k);var l=a.i.get(k),m=k.startTime<=d&&k.endTime>d,n=l?l.zi:null;l&&(g.push(l.Zf),l.Kc&&g.push(l.Kc),m||(f=!0,a.i.delete(k),l=null));m&&(h.push(k),l?jn(a,n)||(f=!0):(ln(a,k,e),l=a.i.get(k),n=l.zi,f=!0));0<k.nestedCues.length&&n&&kn(a,k.nestedCues,n,d,e);e.pop()}if(f){d=t(g);for(e=d.next();!e.done;e=d.next())e=e.value,e.parentElement&&e.parentElement.removeChild(e);h.sort(function(p,r){return p.startTime!=
534
+ r.startTime?p.startTime-r.startTime:p.endTime-r.endTime});h=t(h);for(k=h.next();!k.done;k=h.next())d=a.i.get(k.value),d.Kc?(d.Kc.contains(c)&&d.Kc.removeChild(c),c.appendChild(d.Kc),d.Kc.appendChild(d.Zf)):c.appendChild(d.Zf)}}function hn(a,b){if(a.g){var c=a.A.currentTime;if(!a.m||(void 0===b?0:b)){b=t(a.F.values());for(var d=b.next();!d.done;d=b.next())fn(d.value);fn(a.g);a.i.clear();a.F.clear()}a.m&&kn(a,a.h,a.g,c,[])}}
535
535
  function ln(a,b,c){var d=1<c.length,e=d?"span":"div";b.lineBreak&&(e="br");b.rubyTag&&(e=b.rubyTag);d=!d&&0<b.nestedCues.length;var f=W(e);"br"!=e&&mn(a,f,b,c,d);c=null;if(b.region&&b.region.id){var g=b.region,h=a.l===4/3?2.5:1.9;c=g.id+"_"+g.width+"x"+g.height+(g.heightUnits==Ld?"%":"px")+"-"+g.viewportAnchorX+"x"+g.viewportAnchorY+(g.viewportAnchorUnits==Ld?"%":"px");if(a.F.has(c))c=a.F.get(c);else{e=W("span");var k=g.heightUnits==Ld?"%":"px",l=g.widthUnits==Ld?"%":"px",m=g.viewportAnchorUnits==
536
536
  Ld?"%":"px";e.id="shaka-text-region---"+c;e.classList.add("shaka-text-region");e.style.position="absolute";e.style.height=2===g.heightUnits?5.33*g.height+"%":g.height+k;e.style.width=2===g.widthUnits?g.width*h+"%":g.width+l;2===g.viewportAnchorUnits?(k=g.viewportAnchorY/75*100,l=g.viewportAnchorX/(a.l===4/3?160:210)*100,k-=g.regionAnchorY*g.height*5.33/100,l-=g.regionAnchorX*g.width*h/100,e.style.top=k+"%",e.style.left=l+"%"):(e.style.top=g.viewportAnchorY-g.regionAnchorY*g.height/100+m,e.style.left=
537
537
  g.viewportAnchorX-g.regionAnchorX*g.width/100+m);0!==g.heightUnits&&0!==g.widthUnits&&0!==g.viewportAnchorUnits&&(g=Math.max(0,Math.min(100-(parseInt(e.style.width.slice(0,-1),10)||0),parseInt(e.style.left.slice(0,-1),10)||0)),e.style.top=Math.max(0,Math.min(100-(parseInt(e.style.height.slice(0,-1),10)||0),parseInt(e.style.top.slice(0,-1),10)||0))+"%",e.style.left=g+"%");e.style.display="flex";e.style.flexDirection="column";e.style.alignItems="center";e.style.justifyContent="before"==b.displayAlign?
538
- "flex-start":"center"==b.displayAlign?"center":"flex-end";a.F.set(c,e);c=e}}e=f;d&&(e=W("span"),e.classList.add("shaka-text-wrapper"),e.style.backgroundColor=b.backgroundColor,e.style.lineHeight="normal",f.appendChild(e));a.i.set(b,{Zf:f,zi:e,Jc:c})}function nn(a){var b=a.direction,c=a.positionAlign;a=a.textAlign;return c!==Sd?c:"left"===a||"start"===a&&b===Ud||"end"===a&&"rtl"===b?"line-left":"right"===a||"start"===a&&"rtl"===b||"end"===a&&b===Ud?"line-right":"center"}
538
+ "flex-start":"center"==b.displayAlign?"center":"flex-end";a.F.set(c,e);c=e}}e=f;d&&(e=W("span"),e.classList.add("shaka-text-wrapper"),e.style.backgroundColor=b.backgroundColor,e.style.lineHeight="normal",f.appendChild(e));a.i.set(b,{Zf:f,zi:e,Kc:c})}function nn(a){var b=a.direction,c=a.positionAlign;a=a.textAlign;return c!==Sd?c:"left"===a||"start"===a&&b===Ud||"end"===a&&"rtl"===b?"line-left":"right"===a||"start"===a&&"rtl"===b||"end"===a&&b===Ud?"line-right":"center"}
539
539
  function mn(a,b,c,d,e){var f=b.style,g=0==c.nestedCues.length,h=1<d.length;f.whiteSpace="pre-wrap";var k=c.payload.replace(/\s+$/g,function(m){return"\u00a0".repeat(m.length)});f.webkitTextStrokeColor=c.textStrokeColor;f.webkitTextStrokeWidth=c.textStrokeWidth;f.color=c.color;f.direction=c.direction;f.opacity=c.opacity;f.paddingLeft=on(c.linePadding,c,a.u);f.paddingRight=on(c.linePadding,c,a.u);f.textCombineUpright=c.textCombineUpright;f.textShadow=c.textShadow;if(c.backgroundImage)f.backgroundImage=
540
540
  "url('"+c.backgroundImage+"')",f.backgroundRepeat="no-repeat",f.backgroundSize="contain",f.backgroundPosition="center",c.backgroundColor&&(f.backgroundColor=c.backgroundColor),f.width="100%",f.height="100%";else{if(c.nestedCues.length)var l=b;else l=W("span"),b.appendChild(l);c.border&&(l.style.border=c.border);!e&&((b=pn(d,function(m){return m.backgroundColor}))?l.style.backgroundColor=b:k&&(l.style.backgroundColor="rgba(0, 0, 0, 0.8)"),b=pn(d,function(m){return m.fontFamily}))&&(l.style.fontFamily=
541
541
  b);k&&(l.textContent=k)}h&&!d[d.length-1].isContainer?f.display="inline":(f.display="flex",f.flexDirection="column",f.alignItems="center",f.justifyContent="before"==c.displayAlign?"flex-start":"center"==c.displayAlign?"center":"flex-end");g||(f.margin="0");f.fontFamily=c.fontFamily;f.fontWeight=c.fontWeight.toString();f.fontStyle=c.fontStyle;f.letterSpacing=c.letterSpacing;f.fontSize=on(c.fontSize,c,a.u);d=c.line;null!=d&&(g=c.lineInterpretation,g==Wd&&(g=1,h=16,a.l&&1>a.l&&(h=32),d=0>d?100+d/h*100:
@@ -551,31 +551,31 @@ function En(a){if(0===a.type)return Fn;if(a=a.stream){var b=a.type;if("video"==b
551
551
  function Jn(a,b){b=a.h.Mb()[b];if(!b.length)return 0;var c=a.h.getCurrentTime();return(a=b.find(function(d){return d.start<=c&&d.end>=c}))?1E3*(a.end-c):0}function Kn(a,b){var c=a.h.Db();if(!c.length)return NaN;a=c[0];c=t(c);for(var d=c.next();!d.done;d=c.next())d=d.value,"variant"===d.type&&d.bandwidth>a.bandwidth&&(a=d);switch(b){case Bn:return a.videoBandwidth||NaN;case vn:return a.audioBandwidth||NaN;default:return a.bandwidth}}
552
552
  function yn(a){function b(n){return 100*c(n/100)}function c(n){return Math.round(n)}function d(n){return!Number.isNaN(n)&&null!=n&&""!==n&&!1!==n}var e=[],f={br:c,d:c,bl:b,dl:b,mtp:b,nor:function(n){return encodeURIComponent(n)},rtp:b,tb:c},g=Object.keys(a||{}).sort();g=t(g);for(var h=g.next();!h.done;h=g.next()){h=h.value;var k=a[h];if(d(k)&&("v"!==h||1!==k)&&("pr"!=h||1!==k)){var l=f[h];l&&(k=l(k));l=typeof k;var m=void 0;m="string"===l&&"ot"!==h&&"sf"!==h&&"st"!==h?h+"="+JSON.stringify(k):"boolean"===
553
553
  l?h:"symbol"===l?h+"="+k.description:h+"="+k;e.push(m)}}return e.join(",")}function Dn(a){var b=Object.keys(a),c={},d=["Object","Request","Session","Status"],e=[{},{},{},{}],f={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};b=t(b);for(var g=b.next();!g.done;g=b.next())g=g.value,e[null!=f[g]?f[g]:1][g]=a[g];for(a=0;a<e.length;a++)(f=yn(e[a]))&&(c["CMCD-"+d[a]]=f);return c}
554
- function zn(a,b){if(!b||a.includes("offline:"))return a;a=new mb(a);a.g.set("CMCD",b);return a.toString()}var xn="m",vn="a",Bn="v",wn="av",Fn="i",Hn="c",Gn="tt";P("shaka.util.CmcdManager.StreamingFormat",{DASH:"d",HLS:"h",Bi:"s",OTHER:"o"});function Ln(a){this.h=a;this.g=null}q=Ln.prototype;q.configure=function(a){this.h=a};q.Ih=function(){return this.h.enabled&&this.h.applyMaximumSuggestedBitrate&&this.g&&this.g.has(Mn)?1E3*this.g.get(Mn):null};q.Hh=function(){return this.h.enabled&&this.g&&this.g.has(Nn)?1E3*this.g.get(Nn):null};q.nj=function(){return this.h.enabled&&this.g&&this.g.has(ao)?this.g.get(ao):null};q.oj=function(){return this.h.enabled&&this.g&&this.g.has(bo)?this.g.get(bo):null};
554
+ function zn(a,b){if(!b||a.includes("offline:"))return a;a=new mb(a);a.g.set("CMCD",b);return a.toString()}var xn="m",vn="a",Bn="v",wn="av",Fn="i",Hn="c",Gn="tt";P("shaka.util.CmcdManager.StreamingFormat",{DASH:"d",HLS:"h",Bi:"s",OTHER:"o"});function Ln(a){this.h=a;this.g=null}q=Ln.prototype;q.configure=function(a){this.h=a};q.Ih=function(){return this.h.enabled&&this.h.applyMaximumSuggestedBitrate&&this.g&&this.g.has(Mn)?1E3*this.g.get(Mn):null};q.Hh=function(){return this.h.enabled&&this.g&&this.g.has(Nn)?1E3*this.g.get(Nn):null};q.nj=function(){return this.h.enabled&&this.g&&this.g.has(On)?this.g.get(On):null};q.oj=function(){return this.h.enabled&&this.g&&this.g.has(bo)?this.g.get(bo):null};
555
555
  q.getBandwidthEstimate=function(a){var b=this.Hh();if(!b)return a;var c=this.h.estimatedThroughputWeightRatio;return 0<c&&1>=c?a*(1-c)+b*c:a};function co(a){return a?"false"===a.toLowerCase()?!1:/^[-0-9]/.test(a)?parseInt(a,10):a.replace(/["]+/g,""):!0}P("shaka.util.CmsdManager",Ln);Ln.prototype.getBandwidthEstimate=Ln.prototype.getBandwidthEstimate;Ln.prototype.getRoundTripTime=Ln.prototype.oj;Ln.prototype.getResponseDelay=Ln.prototype.nj;Ln.prototype.getEstimatedThroughput=Ln.prototype.Hh;
556
- Ln.prototype.getMaxBitrate=Ln.prototype.Ih;var Nn="etp",Mn="mb",ao="rd",bo="rtt";function eo(){this.g=null;this.h=[]}function fo(a,b){return O(function(c){if(1==c.g)return a.g?E(c,new Promise(function(d){return a.h.push(d)}),2):c.B(2);a.g=b;F(c)})}eo.prototype.release=function(){0<this.h.length?this.h.shift()():this.g=null};function X(a,b){gb.call(this);var c=this;this.l=go;this.jf=this.h=null;this.ea=!1;this.xf=new od;this.Gc=new od;this.m=new od;this.Ba=new od;this.Cc=new od;this.G=this.H=this.F=this.I=null;this.yf=0;this.S=new eo;this.ha=this.lh=this.Z=this.i=this.Ha=this.K=this.j=this.jb=this.L=this.mh=this.$=this.O=this.Ac=this.N=this.rf=this.J=this.Za=null;this.Na=!1;this.qa=this.o=null;this.Lf=1E9;this.ie=[];this.R=NaN;this.g=ho(this);this.ba={width:Infinity,height:Infinity};this.gf=new ti(this.g,this.ba,null);
556
+ Ln.prototype.getMaxBitrate=Ln.prototype.Ih;var Nn="etp",Mn="mb",On="rd",bo="rtt";function eo(){this.g=null;this.h=[]}function fo(a,b){return O(function(c){if(1==c.g)return a.g?E(c,new Promise(function(d){return a.h.push(d)}),2):c.B(2);a.g=b;F(c)})}eo.prototype.release=function(){0<this.h.length?this.h.shift()():this.g=null};function X(a,b){gb.call(this);var c=this;this.l=go;this.jf=this.h=null;this.ea=!1;this.xf=new od;this.Hc=new od;this.m=new od;this.Ba=new od;this.Dc=new od;this.G=this.H=this.F=this.I=null;this.yf=0;this.S=new eo;this.ha=this.lh=this.X=this.i=this.Ha=this.K=this.j=this.jb=this.L=this.mh=this.$=this.O=this.Bc=this.N=this.rf=this.J=this.Za=null;this.Na=!1;this.qa=this.o=null;this.Lf=1E9;this.ie=[];this.R=NaN;this.g=ho(this);this.ba={width:Infinity,height:Infinity};this.gf=new ti(this.g,this.ba,null);
557
557
  this.Jf=[];this.u=null;this.xa=new Wf(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.g.manifest.dash.enableAudioGroups);this.Ea=this.g.preferredTextLanguage;this.ee=this.g.preferredTextRole;this.be=this.g.preferForcedSubs;this.$d=[];b&&b(this);this.O=io(this);this.$=new Ln(this.g.cmsd);
558
- this.I=jo(this);this.I.Zg(this.g.streaming.forceHTTP);this.I.$g(this.g.streaming.forceHTTPS);this.Nf=this.ma=this.A=null;this.Mf=new Ub(function(){return O(function(d){if(1==d.g)return c.ma?E(d,c.tc(c.Nf,!0),3):d.B(0);if(4!=d.g)return E(d,c.load(c.ma),4);c.Nf.play();c.ma=null;F(d)})});ko&&(this.A=ko(),this.A.configure(this.g.ads),this.Cc.s(this.A,"ad-started",function(d){var e,f,g;return O(function(h){if(1==h.g){if(c.g.ads.supportsMultipleMediaElements)return h.return();e=d.originalEvent;if(!e)return h.return();
559
- f=google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED;if(e.type!=f)return h.return();c.Mf.stop();if(c.ma)return h.B(0);c.Nf=c.h;g=c;return E(h,c.Bh(!0),3)}g.ma=h.h;F(h)})}),this.Cc.s(this.A,"ad-stopped",function(d){c.g.ads.supportsMultipleMediaElements||(d=d.originalEvent)&&d.type==google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED&&c.Mf.V(.1)}));this.xf.s(window,"online",function(){lo(c);c.Rg()});this.uf=new Ub(function(){return mo(c)});this.na=null;a&&(xd("Player w/ mediaElement","Please migrate from initializing Player with a mediaElement; use the attach method instead."),
560
- this.tc(a,!0))}na(X,gb);function no(a){null!=a.L&&(Ej(a.L),a.L.release(),a.L=null)}function oo(a,b){b.lcevc.enabled?(no(a),null==a.L&&(a.L=new Dj(a.h,a.mh,b.lcevc),a.H&&(a.H.Z=a.L))):no(a)}function po(a,b){return new S(a,b)}q=X.prototype;
561
- q.destroy=function(){var a=this,b,c,d,e,f;return O(function(g){switch(g.g){case 1:if(a.l==qo)return g.return();no(a);b=a.detach();a.l=qo;return E(g,b,2);case 2:c=[];d=t(a.Jf);for(e=d.next();!e.done;e=d.next())f=e.value,f.u||c.push(f.destroy());a.Jf=[];return E(g,Promise.all(c),3);case 3:a.xf&&(a.xf.release(),a.xf=null);a.Gc&&(a.Gc.release(),a.Gc=null);a.m&&(a.m.release(),a.m=null);a.Ba&&(a.Ba.release(),a.Ba=null);a.Cc&&(a.Cc.release(),a.Cc=null);a.qa=null;a.g=null;a.u=null;a.jf=null;a.O=null;a.$=
558
+ this.I=jo(this);this.I.Zg(this.g.streaming.forceHTTP);this.I.$g(this.g.streaming.forceHTTPS);this.Nf=this.ma=this.A=null;this.Mf=new Ub(function(){return O(function(d){if(1==d.g)return c.ma?E(d,c.vc(c.Nf,!0),3):d.B(0);if(4!=d.g)return E(d,c.load(c.ma),4);c.Nf.play();c.ma=null;F(d)})});ko&&(this.A=ko(),this.A.configure(this.g.ads),this.Dc.s(this.A,"ad-started",function(d){var e,f,g;return O(function(h){if(1==h.g){if(c.g.ads.supportsMultipleMediaElements)return h.return();e=d.originalEvent;if(!e)return h.return();
559
+ f=google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED;if(e.type!=f)return h.return();c.Mf.stop();if(c.ma)return h.B(0);c.Nf=c.h;g=c;return E(h,c.Bh(!0),3)}g.ma=h.h;F(h)})}),this.Dc.s(this.A,"ad-stopped",function(d){c.g.ads.supportsMultipleMediaElements||(d=d.originalEvent)&&d.type==google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED&&c.Mf.V(.1)}));this.xf.s(window,"online",function(){lo(c);c.Rg()});this.uf=new Ub(function(){return mo(c)});this.na=null;a&&(xd("Player w/ mediaElement","Please migrate from initializing Player with a mediaElement; use the attach method instead."),
560
+ this.vc(a,!0))}na(X,gb);function no(a){null!=a.L&&(Ej(a.L),a.L.release(),a.L=null)}function oo(a,b){b.lcevc.enabled?(no(a),null==a.L&&(a.L=new Dj(a.h,a.mh,b.lcevc),a.H&&(a.H.X=a.L))):no(a)}function po(a,b){return new S(a,b)}q=X.prototype;
561
+ q.destroy=function(){var a=this,b,c,d,e,f;return O(function(g){switch(g.g){case 1:if(a.l==qo)return g.return();no(a);b=a.detach();a.l=qo;return E(g,b,2);case 2:c=[];d=t(a.Jf);for(e=d.next();!e.done;e=d.next())f=e.value,f.u||c.push(f.destroy());a.Jf=[];return E(g,Promise.all(c),3);case 3:a.xf&&(a.xf.release(),a.xf=null);a.Hc&&(a.Hc.release(),a.Hc=null);a.m&&(a.m.release(),a.m=null);a.Ba&&(a.Ba.release(),a.Ba=null);a.Dc&&(a.Dc.release(),a.Dc=null);a.qa=null;a.g=null;a.u=null;a.jf=null;a.O=null;a.$=
562
562
  null;if(!a.I){g.B(4);break}return E(g,a.I.destroy(),5);case 5:a.I=null;case 4:a.o&&(a.o.release(),a.o=null),gb.prototype.release.call(a),F(g)}})};
563
563
  function ro(){window.Promise||Ya("A Promise implementation or polyfill is required");if(!(window.Promise&&window.Uint8Array&&Array.prototype.forEach)||$b("Trident/"))return!1;var a=mc();return a&&9>a||!(window.MediaKeys&&window.navigator&&window.navigator.requestMediaKeySystemAccess&&window.MediaKeySystemAccess&&window.MediaKeySystemAccess.prototype.getConfiguration)?!1:Vb()?!0:Wb("application/x-mpegurl")}function so(a,b){a.dispatchEvent(po("onstatechange",(new Map).set("state",b)))}
564
- q.tc=function(a,b){b=void 0===b?!0:b;var c=this,d,e,f;return O(function(g){switch(g.g){case 1:if(c.l==qo)throw new U(2,7,7E3);d=c.h&&c.h==a;if(!c.h||c.h==a){g.B(2);break}return E(g,c.detach(),2);case 2:return E(g,to(c,"attach"),4);case 4:if(g.h)return g.return();ta(g,5,6);d||(so(c,"attach"),e=function(){var h=uo(c);h&&vo(c,h)},c.Gc.s(a,"error",e),c.h=a);if(!b||!Vb()||c.H){g.B(6);break}return E(g,wo(c),6);case 6:xa(g);c.S.release();ya(g,0);break;case 5:return f=wa(g),E(g,c.detach(),10);case 10:throw f;
565
- }})};q.qh=function(a){this.mh=a};q.detach=function(a){a=void 0===a?!1:a;var b=this;return O(function(c){if(1==c.g){if(b.l==qo)throw new U(2,7,7E3);return E(c,b.Nc(!1,a),2)}if(3!=c.g)return E(c,to(b,"detach"),3);if(c.h)return c.return();try{b.h&&(b.Gc.qb(),b.h=null),so(b,"detach"),b.A&&!a&&b.A.release()}finally{b.S.release()}F(c)})};function to(a,b){var c;return O(function(d){return 1==d.g?(c=++a.yf,E(d,fo(a.S,b),2)):c!=a.yf?(a.S.release(),d.return(!0)):d.return(!1)})}
566
- q.Nc=function(a,b){a=void 0===a?!0:a;b=void 0===b?!1:b;var c=this,d,e,f,g,h,k,l,m,n;return O(function(p){switch(p.g){case 1:return c.l!=qo&&(c.l=go),E(p,to(c,"unload"),2);case 2:if(p.h)return p.return();ua(p,3);c.Na=!1;so(c,"unload");a&&!Vb()&&(a=!1);no(c);d=c.$d.map(function(r){return r()});c.$d=[];return E(p,Promise.all(d),5);case 5:c.dispatchEvent(po("unloading"));c.Ac&&(c.Ac.release(),c.Ac=null);c.h&&(c.m.qb(),c.Ba.qb());c.uf.stop();c.Za&&(c.Za.release(),c.Za=null);c.rf&&(c.rf.stop(),c.rf=null);
564
+ q.vc=function(a,b){b=void 0===b?!0:b;var c=this,d,e,f;return O(function(g){switch(g.g){case 1:if(c.l==qo)throw new U(2,7,7E3);d=c.h&&c.h==a;if(!c.h||c.h==a){g.B(2);break}return E(g,c.detach(),2);case 2:return E(g,to(c,"attach"),4);case 4:if(g.h)return g.return();ta(g,5,6);d||(so(c,"attach"),e=function(){var h=uo(c);h&&vo(c,h)},c.Hc.s(a,"error",e),c.h=a);if(!b||!Vb()||c.H){g.B(6);break}return E(g,wo(c),6);case 6:xa(g);c.S.release();ya(g,0);break;case 5:return f=wa(g),E(g,c.detach(),10);case 10:throw f;
565
+ }})};q.qh=function(a){this.mh=a};q.detach=function(a){a=void 0===a?!1:a;var b=this;return O(function(c){if(1==c.g){if(b.l==qo)throw new U(2,7,7E3);return E(c,b.Oc(!1,a),2)}if(3!=c.g)return E(c,to(b,"detach"),3);if(c.h)return c.return();try{b.h&&(b.Hc.qb(),b.h=null),so(b,"detach"),b.A&&!a&&b.A.release()}finally{b.S.release()}F(c)})};function to(a,b){var c;return O(function(d){return 1==d.g?(c=++a.yf,E(d,fo(a.S,b),2)):c!=a.yf?(a.S.release(),d.return(!0)):d.return(!1)})}
566
+ q.Oc=function(a,b){a=void 0===a?!0:a;b=void 0===b?!1:b;var c=this,d,e,f,g,h,k,l,m,n;return O(function(p){switch(p.g){case 1:return c.l!=qo&&(c.l=go),E(p,to(c,"unload"),2);case 2:if(p.h)return p.return();ua(p,3);c.Na=!1;so(c,"unload");a&&!Vb()&&(a=!1);no(c);d=c.$d.map(function(r){return r()});c.$d=[];return E(p,Promise.all(d),5);case 5:c.dispatchEvent(po("unloading"));c.Bc&&(c.Bc.release(),c.Bc=null);c.h&&(c.m.qb(),c.Ba.qb());c.uf.stop();c.Za&&(c.Za.release(),c.Za=null);c.rf&&(c.rf.stop(),c.rf=null);
567
567
  if(!c.K){p.B(6);break}return E(p,c.K.stop(),7);case 7:c.K=null,c.Ha=null;case 6:if(!c.o){p.B(8);break}return E(p,c.o.stop(),8);case 8:if(!c.j){p.B(10);break}return E(p,c.j.destroy(),11);case 11:c.j=null;case 10:c.J&&(c.J.release(),c.J=null);c.G&&(c.G.release(),c.G=null);if(!tc("webkit")||!c.F){p.B(12);break}return E(p,c.F.destroy(),13);case 13:c.F=null;case 12:if(!c.H){p.B(14);break}return E(p,c.H.destroy(),15);case 15:c.H=null;case 14:if(c.A&&!b)c.A.onAssetUnload();c.ma&&!b&&(c.ma.destroy(),c.ma=
568
- null);b||c.Mf.stop();c.O&&sn(c.O);c.$&&(c.$.g=null);c.h&&fn(c.h);if(!c.h||!c.h.src){p.B(16);break}return E(p,new Promise(function(r){return(new Ub(r)).V(.1)}),17);case 17:c.h.removeAttribute("src"),c.h.load();case 16:if(!c.F){p.B(18);break}return E(p,c.F.destroy(),19);case 19:c.F=null;case 18:c.na&&c.Z!=c.na.Zc()&&(c.na.u||c.na.destroy(),c.na=null);c.Z=null;c.lh=null;c.N=null;if(c.i){e=t(c.i.variants);for(f=e.next();!f.done;f=e.next())for(g=f.value,h=t([g.audio,g.video]),k=h.next();!k.done;k=h.next())(l=
568
+ null);b||c.Mf.stop();c.O&&sn(c.O);c.$&&(c.$.g=null);c.h&&fn(c.h);if(!c.h||!c.h.src){p.B(16);break}return E(p,new Promise(function(r){return(new Ub(r)).V(.1)}),17);case 17:c.h.removeAttribute("src"),c.h.load();case 16:if(!c.F){p.B(18);break}return E(p,c.F.destroy(),19);case 19:c.F=null;case 18:c.na&&c.X!=c.na.$c()&&(c.na.u||c.na.destroy(),c.na=null);c.X=null;c.lh=null;c.N=null;if(c.i){e=t(c.i.variants);for(f=e.next();!f.done;f=e.next())for(g=f.value,h=t([g.audio,g.video]),k=h.next();!k.done;k=h.next())(l=
569
569
  k.value)&&l.segmentIndex&&l.segmentIndex.release();m=t(c.i.textStreams);for(k=m.next();!k.done;k=m.next())n=k.value,n.segmentIndex&&n.segmentIndex.release()}c.g.streaming.clearDecodingCache&&(qf={},Sb.clear());c.i=null;c.u=new jl;c.Kf=null;c.ie=[];c.R=NaN;xo(c);case 3:xa(p);c.S.release();ya(p,4);break;case 4:if(a&&Vb()&&!c.H)return E(p,wo(c),0);p.B(0)}})};q.Gk=function(a){this.ha=a};
570
- q.load=function(a,b,c){b=void 0===b?null:b;var d=this,e,f,g,h,k,l,m,n,p,r,u,v,w;return O(function(A){switch(A.g){case 1:if(d.l==qo)throw new U(2,7,7E3);e=null;f="";a instanceof Am?(e=a,f=e.Zc()||""):f=a||"";return E(A,fo(d.S,"load"),2);case 2:d.S.release();if(!d.h)throw new U(2,7,7002);if(!d.Z){A.B(3);break}d.Z=f;return E(A,d.Nc(!1),3);case 3:g=++d.yf;h=function(){return O(function(z){if(1==z.g)return d.yf==g?z.B(0):e?E(z,e.destroy(),3):z.B(3);throw new U(2,7,7E3);})};k=function(z,C){return O(function(y){switch(y.g){case 1:return ua(y,
570
+ q.load=function(a,b,c){b=void 0===b?null:b;var d=this,e,f,g,h,k,l,m,n,p,r,u,v,w;return O(function(A){switch(A.g){case 1:if(d.l==qo)throw new U(2,7,7E3);e=null;f="";a instanceof Am?(e=a,f=e.$c()||""):f=a||"";return E(A,fo(d.S,"load"),2);case 2:d.S.release();if(!d.h)throw new U(2,7,7002);if(!d.X){A.B(3);break}d.X=f;return E(A,d.Oc(!1),3);case 3:g=++d.yf;h=function(){return O(function(z){if(1==z.g)return d.yf==g?z.B(0):e?E(z,e.destroy(),3):z.B(3);throw new U(2,7,7E3);})};k=function(z,C){return O(function(y){switch(y.g){case 1:return ua(y,
571
571
  2),E(y,fo(d.S,C),4);case 4:return E(y,h(),5);case 5:return E(y,z(),6);case 6:return E(y,h(),7);case 7:e&&d.g&&(e.g=d.g);case 2:xa(y),d.S.release(),ya(y,0)}})};ta(A,5,6);null==b&&e&&(b=e.getStartTime());d.ha=b;d.Na=!1;d.dispatchEvent(po("loading"));if(e){c=e.R;A.B(8);break}if(c){A.B(8);break}return E(A,k(function(){return O(function(z){if(1==z.g)return E(z,yo(d,f),2);c=z.h;F(z)})},"guessMimeType_"),8);case 8:l=!!e;if(e){Dm(e,d);d.u=e.getStats();A.B(11);break}return E(A,zo(d,f,b,c,!0),12);case 12:(e=
572
- A.h)?(Dm(e,d),d.u=e.getStats(),e.start(),e.m.catch(function(){})):d.u=new jl;case 11:m=!e;n=e?e.jb:Date.now()/1E3;d.u=e?e.getStats():new jl;d.Z=f;d.lh=c||null;if(m)return E(A,k(function(){return O(function(z){return E(z,Ao(d,c),0)})},"initializeSrcEqualsDrmInner_"),20);if(d.H){A.B(15);break}return E(A,k(function(){return O(function(z){return E(z,wo(d),0)})},"initializeMediaSourceEngineInner_"),15);case 15:return E(A,k(function(){return O(function(z){return E(z,e.m,0)})},"waitForFinish"),17);case 17:d.g=
573
- e.getConfiguration();d.gf=e.F;d.Ha=e.G;d.K=Fm(e);d.Ac=Gm(e);d.jb=e.Ba;d.i=e.rg();if(p=e.o)d.xa=p;l&&d.h&&"AUDIO"===d.h.nodeName&&(Bo(d),d.configure("manifest.disableVideo",!0));d.F=Hm(e);return E(A,k(function(){return O(function(z){return E(z,d.F.tc(d.h),0)})},"drmEngine_.attach"),18);case 18:return!(r=e.A)||d.qa&&d.qa==r||(d.o=Em(e),d.qa=e.A,"function"!=typeof d.o.setMediaElement&&(xd("AbrManager w/o setMediaElement","Please use an AbrManager with setMediaElement function."),d.o.setMediaElement=
572
+ A.h)?(Dm(e,d),d.u=e.getStats(),e.start(),e.m.catch(function(){})):d.u=new jl;case 11:m=!e;n=e?e.jb:Date.now()/1E3;d.u=e?e.getStats():new jl;d.X=f;d.lh=c||null;if(m)return E(A,k(function(){return O(function(z){return E(z,Ao(d,c),0)})},"initializeSrcEqualsDrmInner_"),20);if(d.H){A.B(15);break}return E(A,k(function(){return O(function(z){return E(z,wo(d),0)})},"initializeMediaSourceEngineInner_"),15);case 15:return E(A,k(function(){return O(function(z){return E(z,e.m,0)})},"waitForFinish"),17);case 17:d.g=
573
+ e.getConfiguration();d.gf=e.F;d.Ha=e.G;d.K=Fm(e);d.Bc=Gm(e);d.jb=e.Ba;d.i=e.rg();if(p=e.o)d.xa=p;l&&d.h&&"AUDIO"===d.h.nodeName&&(Bo(d),d.configure("manifest.disableVideo",!0));d.F=Hm(e);return E(A,k(function(){return O(function(z){return E(z,d.F.vc(d.h),0)})},"drmEngine_.attach"),18);case 18:return!(r=e.A)||d.qa&&d.qa==r||(d.o=Em(e),d.qa=e.A,"function"!=typeof d.o.setMediaElement&&(xd("AbrManager w/o setMediaElement","Please use an AbrManager with setMediaElement function."),d.o.setMediaElement=
574
574
  function(){}),"function"!=typeof d.o.setCmsdManager&&(xd("AbrManager w/o setCmsdManager","Please use an AbrManager with setCmsdManager function."),d.o.setCmsdManager=function(){}),"function"!=typeof d.o.trySuggestStreams&&(xd("AbrManager w/o trySuggestStreams","Please use an AbrManager with trySuggestStreams function."),d.o.trySuggestStreams=function(){})),u=Im(e),v=e.ha,E(A,k(function(){return O(function(z){return E(z,Co(d,n,v,u),0)})},"loadInner_"),19);case 19:Cm(e);A.B(14);break;case 20:return E(A,
575
- k(function(){return O(function(z){return E(z,Do(d,n,c),0)})},"srcEqualsInner_"),14);case 14:d.dispatchEvent(po("loaded"));case 6:xa(A);if(!e){A.B(22);break}return E(A,e.destroy(),22);case 22:d.na=null;ya(A,0);break;case 5:w=wa(A);if(7E3==w.code){A.B(24);break}return E(A,d.Nc(!1),24);case 24:throw w;}})};
576
- function Bo(a){for(var b=t(a.i.variants),c=b.next();!c.done;c=b.next())c=c.value,c.video&&(c.video.closeSegmentIndex(),c.video=null),c.bandwidth=c.audio&&c.audio.bandwidth?c.audio.bandwidth:0;a.i.variants=a.i.variants.filter(function(d){return d.audio})}q.Ck=function(a,b){a=void 0===a?!0:a;b=void 0===b?!1:b;var c=this,d;return O(function(e){return 1==e.g?E(e,Eo(c),2):3!=e.g?(d=e.h,E(e,c.Nc(a,b),3)):e.return(d)})};
575
+ k(function(){return O(function(z){return E(z,Do(d,n,c),0)})},"srcEqualsInner_"),14);case 14:d.dispatchEvent(po("loaded"));case 6:xa(A);if(!e){A.B(22);break}return E(A,e.destroy(),22);case 22:d.na=null;ya(A,0);break;case 5:w=wa(A);if(7E3==w.code){A.B(24);break}return E(A,d.Oc(!1),24);case 24:throw w;}})};
576
+ function Bo(a){for(var b=t(a.i.variants),c=b.next();!c.done;c=b.next())c=c.value,c.video&&(c.video.closeSegmentIndex(),c.video=null),c.bandwidth=c.audio&&c.audio.bandwidth?c.audio.bandwidth:0;a.i.variants=a.i.variants.filter(function(d){return d.audio})}q.Ck=function(a,b){a=void 0===a?!0:a;b=void 0===b?!1:b;var c=this,d;return O(function(e){return 1==e.g?E(e,Eo(c),2):3!=e.g?(d=e.h,E(e,c.Oc(a,b),3)):e.return(d)})};
577
577
  q.Bh=function(a){a=void 0===a?!1:a;var b=this,c;return O(function(d){return 1==d.g?E(d,Eo(b),2):3!=d.g?(c=d.h,E(d,b.detach(a),3)):d.return(c)})};
578
- function Eo(a){var b,c,d;return O(function(e){if(1==e.g){b=null;if(!(a.i&&a.K&&a.Ha&&a.Z))return e.B(2);c=a.h.currentTime;a.U()&&(c=null);d=Date.now()/1E3;return E(e,Fo(a,a.Z,c,a.lh,d,!0,!1,!1),3)}if(2!=e.g){var f=b=e.h,g=a.K,h=a.Ha;f.h=a.i;f.j=g;f.G=h;f=b;g=a.qa;f.i=a.o;f.A=g;b.o=a.xa;b.start();a.i=null;a.K=null;a.Ha=null;a.o=null;a.qa=null}return e.return(b)})}
578
+ function Eo(a){var b,c,d;return O(function(e){if(1==e.g){b=null;if(!(a.i&&a.K&&a.Ha&&a.X))return e.B(2);c=a.h.currentTime;a.U()&&(c=null);d=Date.now()/1E3;return E(e,Fo(a,a.X,c,a.lh,d,!0,!1,!1),3)}if(2!=e.g){var f=b=e.h,g=a.K,h=a.Ha;f.h=a.i;f.j=g;f.G=h;f=b;g=a.qa;f.i=a.o;f.A=g;b.o=a.xa;b.start();a.i=null;a.K=null;a.Ha=null;a.o=null;a.qa=null}return e.return(b)})}
579
579
  q.preload=function(a,b,c){b=void 0===b?null:b;var d=this,e;return O(function(f){if(1==f.g)return E(f,zo(d,a,b,c),2);(e=f.h)?e.start():vo(d,new U(2,7,7005));return f.return(e)})};function zo(a,b,c,d,e){e=void 0===e?!1:e;var f,g,h,k;return O(function(l){if(1==l.g)return f=Date.now()/1E3,d?l.B(2):E(l,yo(a,b),3);2!=l.g&&(d=l.h);if(g=Go(a,d))return l.return(null);h=!1;k=!0;e&&(a.o&&a.qa==a.g.abrFactory&&(k=!1),a.h&&"AUDIO"===a.h.nodeName&&(h=!0));return l.return(Fo(a,b,c,d||null,f,!e,h,k))})}
580
580
  function Fo(a,b,c,d,e,f,g,h){f=void 0===f?!0:f;g=void 0===g?!1:g;h=void 0===h?!0:h;var k,l,m,n,p,r,u,v,w,A,z,C,y,B,D;return O(function(K){if(1==K.g)return k=null,l=Xe(a.g),g&&(l.manifest.disableVideo=!0),m=function(){return k.O&&k.u?null:k},n=function(){return m()?m().getConfiguration():a.g},p=function(G,J){m()?k.configure(G,J):a.configure(G,J)},Infinity!=a.ba.width||Infinity!=a.ba.height?K.B(2):E(K,uc(),3);2!=K.g&&(r=K.h,a.ba.width=r.width,a.ba.height=r.height);u=new ti(l,a.ba,null);v={networkingEngine:a.I,
581
581
  filter:function(G){var J,I;return O(function(H){if(1==H.g)return E(H,ui(u,G),2);if(4!=H.g){J=H.h;if(!J)return H.B(0);I=po("trackschanged");return E(H,Promise.resolve(),4)}k.dispatchEvent(I);F(H)})},makeTextStreamsForClosedCaptions:function(G){return Ho(a,G)},onTimelineRegionAdded:function(G){var J=k.H;a:{var I=t(J.g);for(var H=I.next();!H.done;H=I.next())if(H=H.value,H.schemeIdUri==G.schemeIdUri&&H.id==G.id&&H.startTime==G.startTime&&H.endTime==G.endTime){I=H;break a}I=null}null==I&&(J.g.add(G),G=
@@ -583,37 +583,37 @@ new S("regionadd",new Map([["region",G]])),J.dispatchEvent(G))},onEvent:function
583
583
  (new Map).set("isLive",a.U());k.dispatchEvent(po("manifestupdated",G));Bm(k,!1,function(){if(a.A)a.A.onManifestUpdated(a.U())})},getBandwidthEstimate:function(){return a.o.getBandwidthEstimate()}};w=new wl(function(){return a.Ta()});w.addEventListener("regionadd",function(G){var J=G.region;Io(a,"timelineregionadded",J,k);Bm(k,!1,function(){if(a.A)a.A.onDashTimedMetadata(J)})});A=null;l.streaming.observeQualityChanges&&(A=new xl(function(){return a.Mb()}),A.addEventListener("qualitychange",function(G){var J=
584
584
  G.quality;G=G.position;J=(new Map).set("mediaQuality",{bandwidth:J.bandwidth,audioSamplingRate:J.audioSamplingRate,codecs:J.codecs,contentType:J.contentType,frameRate:J.frameRate,height:J.height,mimeType:J.mimeType,channelsCount:J.channelsCount,pixelAspectRatio:J.pixelAspectRatio,width:J.width}).set("position",G);a.dispatchEvent(po("mediaqualitychanged",J))}));z=!0;C={Zb:a.I,onError:function(G){return k.onError(G)},bf:function(G){Bm(k,!0,function(){a:{var J=G,I=po("keystatuschanged");a.dispatchEvent(I);
585
585
  var H=Object.keys(J);1==H.length&&""==H[0]&&(H=["00"],J={"00":J[""]});I=1==H.length&&"00"==H[0];var N=!1;if(H.length){H=t(a.i.variants);for(var L=H.next();!L.done;L=H.next()){L=L.value;var M=[];L.audio&&M.push(L.audio);L.video&&M.push(L.video);M=t(M);for(var Q=M.next();!Q.done;Q=M.next()){var T=Q.value;Q=L.allowedByKeySystem;if(T.keyIds.size){L.allowedByKeySystem=!0;T=t(T.keyIds);for(var R=T.next();!R.done;R=T.next())if(R=R.value,(R=J[I?"00":R])||a.F.H)L.allowedByKeySystem=L.allowedByKeySystem&&!!R&&
586
- !yi.includes(R)}Q!=L.allowedByKeySystem&&(N=!0)}}}if(N&&(Jo(a),!Ko(a)))break a;(J=a.j.j)&&!J.allowedByKeySystem&&Lo(a)}})},onExpirationUpdated:function(G,J){var I=po("expirationupdated");k.dispatchEvent(I);if((I=k.j)&&I.onExpirationUpdated)I.onExpirationUpdated(G,J)},onEvent:function(G){k.dispatchEvent(G);"drmsessionupdate"==G.type&&z&&(z=!1,G=Date.now()/1E3-k.qa,(a.u||k.getStats()).j=G,a.L&&Ej(a.L))}};y=jo(a,m);zg(a.I,y);B=function(){return a.Vc(C)};D={config:l,Qj:v,Zj:w,Yj:A,Vc:B,Pj:u,networkingEngine:y,
586
+ !yi.includes(R)}Q!=L.allowedByKeySystem&&(N=!0)}}}if(N&&(Jo(a),!Ko(a)))break a;(J=a.j.j)&&!J.allowedByKeySystem&&Lo(a)}})},onExpirationUpdated:function(G,J){var I=po("expirationupdated");k.dispatchEvent(I);if((I=k.j)&&I.onExpirationUpdated)I.onExpirationUpdated(G,J)},onEvent:function(G){k.dispatchEvent(G);"drmsessionupdate"==G.type&&z&&(z=!1,G=Date.now()/1E3-k.qa,(a.u||k.getStats()).j=G,a.L&&Ej(a.L))}};y=jo(a,m);zg(a.I,y);B=function(){return a.Wc(C)};D={config:l,Qj:v,Zj:w,Yj:A,Wc:B,Pj:u,networkingEngine:y,
587
587
  Ji:f,Ii:h};k=new Am(b,d,e,c,D);a.Jf.push(k);return K.return(k)})}function yo(a,b){var c,d;return O(function(e){if(1==e.g)return c=a.g.manifest.retryParameters,E(e,Um(b,a.I,c),2);d=e.h;"application/x-mpegurl"==d&&hc()&&(d="application/vnd.apple.mpegurl");return e.return(d)})}
588
588
  function Go(a,b){if(!Vb())return!0;if(b){if(""==(a.h||Xb()).canPlayType(b))return!1;if(!(Vb()&&b in Bi))return!0;if(Le(b)){if(a.g.streaming.preferNativeHls)return!0;if(hc()&&(a.g.drm.servers["com.apple.fps"]||a.g.drm.servers["com.apple.fps.1_0"]))return a.g.streaming.useNativeHlsForFairPlay;if(hc())return a.g.streaming.useNativeHlsOnSafari}}return!1}
589
589
  function wo(a){var b,c,d,e,f;return O(function(g){if(1==g.g)return so(a,"media-source"),b=a.g.textDisplayFactory,c=b(),c.configure?c.configure(a.g.textDisplayer):xd("Text displayer w/ configure",'Text displayer should have a "configure" method!'),a.Kf=b,d=Mo(a.h,c,{dj:function(){return a.keySystem()},cf:function(h,k,l){No(a,h,k,l)}},a.L),d.configure(a.g.mediaSource),e=a.g.manifest,f=e.segmentRelativeVttTiming,d.ha=f,E(g,d.N,2);a.H=d;F(g)})}
590
- function Co(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J;return O(function(I){switch(I.g){case 1:so(a,"load");e=a.h;a.J=new al({Me:function(){return e.playbackRate},xc:function(){return e.defaultPlaybackRate},ah:function(H){e.playbackRate=H},Th:function(H){e.currentTime+=H}});f=function(){return Oo(a)};g=function(){return Po(a)};a.m.s(e,"playing",f);a.m.s(e,"pause",f);a.m.s(e,"ended",f);a.m.s(e,"ratechange",g);oo(a,a.g);a.Ea=a.g.preferredTextLanguage;a.ee=a.g.preferredTextRole;a.be=a.g.preferForcedSubs;
590
+ function Co(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J;return O(function(I){switch(I.g){case 1:so(a,"load");e=a.h;a.J=new al({Me:function(){return e.playbackRate},zc:function(){return e.defaultPlaybackRate},ah:function(H){e.playbackRate=H},Th:function(H){e.currentTime+=H}});f=function(){return Oo(a)};g=function(){return Po(a)};a.m.s(e,"playing",f);a.m.s(e,"pause",f);a.m.s(e,"ended",f);a.m.s(e,"ratechange",g);oo(a,a.g);a.Ea=a.g.preferredTextLanguage;a.ee=a.g.preferredTextRole;a.be=a.g.preferForcedSubs;
591
591
  Qo(a.i.presentationTimeline,a.g.playRangeStart,a.g.playRangeEnd);a.o.init(function(H,N,L){a.i&&a.j&&H!=a.j.j&&Ro(a,H,!0,void 0===N?!1:N,void 0===L?0:L)});a.o.setMediaElement(e);a.o.setCmsdManager(a.$);a.j=So(a);a.j.configure(a.g.streaming);a.l=To;e.textTracks&&a.m.s(e.textTracks,"addtrack",function(H){if(H.track)switch(H=H.track,H.kind){case "chapters":Uo(a,H)}});a.dispatchEvent(po("streaming"));h=c;(k=a.j.j)||h||(h=Vo(a,!0));l=[];m=k||h;n=t([m.video,m.audio]);for(p=n.next();!p.done;p=n.next())(r=
592
592
  p.value)&&!r.segmentIndex&&l.push(r.createSegmentIndex());if(!(0<l.length)){I.B(2);break}return E(I,Promise.all(l),2);case 2:if(a.K&&a.K.onInitialVariantChosen)a.K.onInitialVariantChosen(m);Qo(a.i.presentationTimeline,a.g.playRangeStart,a.g.playRangeEnd);Il(a.j,a.g.playRangeStart,a.g.playRangeEnd);u=function(H){a.G=Wo(a,H);a.Za=Xo(a,H);Yo(a,e,Math.max(a.i.minBufferTime,a.g.streaming.rebufferingGoal))};a.g.streaming.startAtSegmentBoundary||u(a.ha);if(k){I.B(4);break}if(!a.g.streaming.startAtSegmentBoundary){I.B(5);
593
- break}v=a.i.presentationTimeline;w=a.ha||a.h.currentTime;A=v.yc();z=v.Ob();w<A?w=A:w>z&&(w=z);return E(I,Zo(h,w),6);case 6:C=I.h,u(C);case 5:Ro(a,h,!0,!1,0);case 4:return a.G.Pf(),y=a.jc().find(function(H){return H.active}),y||((B=Gf(a.i.textStreams,a.Ea,a.ee,a.be)[0]||null)&&il(a.u.h,B,!0),h&&(B?($o(a,h.audio,B)&&(a.ea=!0),a.ea&&a.H.H.setTextVisibility(!0),ap(a)):a.ea=!1),B&&(a.g.streaming.alwaysStreamText||a.Fc())&&Rl(a.j,B)),E(I,a.j.start(d),7);case 7:a.g.abr.enabled&&(a.o.enable(),bp(a));Jo(a);
593
+ break}v=a.i.presentationTimeline;w=a.ha||a.h.currentTime;A=v.ic();z=v.Ob();w<A?w=A:w>z&&(w=z);return E(I,Zo(h,w),6);case 6:C=I.h,u(C);case 5:Ro(a,h,!0,!1,0);case 4:return a.G.Pf(),y=a.kc().find(function(H){return H.active}),y||((B=Gf(a.i.textStreams,a.Ea,a.ee,a.be)[0]||null)&&il(a.u.h,B,!0),h&&(B?($o(a,h.audio,B)&&(a.ea=!0),a.ea&&a.H.H.setTextVisibility(!0),ap(a)):a.ea=!1),B&&(a.g.streaming.alwaysStreamText||a.Gc())&&Rl(a.j,B)),E(I,a.j.start(d),7);case 7:a.g.abr.enabled&&(a.o.enable(),bp(a));Jo(a);
594
594
  Ko(a);a.i.variants.some(function(H){return H.primary});if((D=a.U())&&(a.g.streaming.liveSync||a.i.serviceDescription||a.g.streaming.liveSyncPanicMode)||a.g.streaming.vodDynamicPlaybackRate)K=function(){return cp(a)},a.m.s(e,"timeupdate",K);D||(G=function(){return dp(a)},a.m.s(e,"timeupdate",G),dp(a),a.i.nextUrl&&(0<a.g.streaming.preloadNextUrlWindow&&(J=function(){var H,N;return O(function(L){if(1==L.g){H=a.h.duration-a.h.currentTime;if(isNaN(H)||!(H<=a.g.streaming.preloadNextUrlWindow))return L.B(0);
595
595
  a.m.Xa(e,"timeupdate",J);N=a;return E(L,a.preload(a.i.nextUrl),4)}N.na=L.h;F(L)})},a.m.s(e,"timeupdate",J)),a.m.s(e,"ended",function(){a.load(a.na||a.i.nextUrl)})));if(a.A)a.A.onManifestUpdated(D);a.Na=!0;a.m.oa(e,"loadedmetadata",function(){a.u.m=Date.now()/1E3-b});F(I)}})}
596
- function Ao(a,b){var c,d,e,f,g;return O(function(h){return 1==h.g?(c=Uc,d=Date.now()/1E3,e=!0,a.F=a.Vc({Zb:a.I,onError:function(k){vo(a,k)},bf:function(){},onExpirationUpdated:function(){var k=po("expirationupdated");a.dispatchEvent(k)},onEvent:function(k){a.dispatchEvent(k);"drmsessionupdate"==k.type&&e&&(e=!1,a.u.j=Date.now()/1E3-d)}}),a.F.configure(a.g.drm),f={id:0,language:"und",disabledUntilTime:0,primary:!1,audio:null,video:null,bandwidth:100,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},
596
+ function Ao(a,b){var c,d,e,f,g;return O(function(h){return 1==h.g?(c=Uc,d=Date.now()/1E3,e=!0,a.F=a.Wc({Zb:a.I,onError:function(k){vo(a,k)},bf:function(){},onExpirationUpdated:function(){var k=po("expirationupdated");a.dispatchEvent(k)},onEvent:function(k){a.dispatchEvent(k);"drmsessionupdate"==k.type&&e&&(e=!1,a.u.j=Date.now()/1E3-d)}}),a.F.configure(a.g.drm),f={id:0,language:"und",disabledUntilTime:0,primary:!1,audio:null,video:null,bandwidth:100,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},
597
597
  g={id:0,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:b?Je(b):"",codecs:b?Ke(b):"",encrypted:!0,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:c.ra,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},g.fullMimeTypes.add(te(g.mimeType,
598
- g.codecs)),b.startsWith("audio/")?(g.type=c.aa,f.audio=g):f.video=g,a.F.$=!0,E(h,Qh(a.F,[f],[]),2)):E(h,a.F.tc(a.h),0)})}
599
- function Do(a,b,c){var d,e,f,g,h,k,l,m,n,p,r;return O(function(u){if(1==u.g)return so(a,"src-equals"),d=a.h,a.G=new Rk(d),e=!1,a.$d.push(function(){e=!0}),null!=a.ha&&a.G.Qf(a.ha),a.J=new al({Me:function(){return d.playbackRate},xc:function(){return d.defaultPlaybackRate},ah:function(v){d.playbackRate=v},Th:function(v){d.currentTime+=v}}),f=a.g.streaming.rebufferingGoal,Yo(a,d,f),g=function(){return Oo(a)},h=function(){return Po(a)},a.m.s(d,"playing",g),a.m.s(d,"pause",g),a.m.s(d,"ended",g),a.m.s(d,
598
+ g.codecs)),b.startsWith("audio/")?(g.type=c.aa,f.audio=g):f.video=g,a.F.$=!0,E(h,Qh(a.F,[f],[]),2)):E(h,a.F.vc(a.h),0)})}
599
+ function Do(a,b,c){var d,e,f,g,h,k,l,m,n,p,r;return O(function(u){if(1==u.g)return so(a,"src-equals"),d=a.h,a.G=new Rk(d),e=!1,a.$d.push(function(){e=!0}),null!=a.ha&&a.G.Qf(a.ha),a.J=new al({Me:function(){return d.playbackRate},zc:function(){return d.defaultPlaybackRate},ah:function(v){d.playbackRate=v},Th:function(v){d.currentTime+=v}}),f=a.g.streaming.rebufferingGoal,Yo(a,d,f),g=function(){return Oo(a)},h=function(){return Po(a)},a.m.s(d,"playing",g),a.m.s(d,"pause",g),a.m.s(d,"ended",g),a.m.s(d,
600
600
  "ratechange",h),"none"!=d.preload&&a.m.oa(d,"loadedmetadata",function(){a.u.m=Date.now()/1E3-b}),d.audioTracks&&(a.m.s(d.audioTracks,"addtrack",function(){return Jo(a)}),a.m.s(d.audioTracks,"removetrack",function(){return Jo(a)}),a.m.s(d.audioTracks,"change",function(){return Jo(a)})),d.textTracks&&(a.m.s(d.textTracks,"addtrack",function(v){if(v.track)switch(v=v.track,v.kind){case "metadata":ep(a,v);break;case "chapters":Uo(a,v);break;default:Jo(a)}}),a.m.s(d.textTracks,"removetrack",function(){return Jo(a)}),
601
- a.m.s(d.textTracks,"change",function(){return Jo(a)})),d.src=tn(a.O,a.Z,c),(ac()||dc())&&d.load(),"none"!=d.preload&&!d.autoplay&&Le(c)&&mc()&&d.load(),a.l=fp,a.dispatchEvent(po("streaming")),k=new lg,Ik(d,HTMLMediaElement.HAVE_METADATA,a.m,function(){a.G.Pf();k.resolve()}),Ik(d,HTMLMediaElement.HAVE_CURRENT_DATA,a.m,function(){var v;return O(function(w){if(1==w.g)return gp(a),v=hp(a),v.find(function(A){return"disabled"!=A.mode})?(0<v.length&&(a.ea=!0),w.B(2)):E(w,new Promise(function(A){a.m.oa(d.textTracks,
601
+ a.m.s(d.textTracks,"change",function(){return Jo(a)})),d.src=tn(a.O,a.X,c),(ac()||dc())&&d.load(),"none"!=d.preload&&!d.autoplay&&Le(c)&&mc()&&d.load(),a.l=fp,a.dispatchEvent(po("streaming")),k=new lg,Ik(d,HTMLMediaElement.HAVE_METADATA,a.m,function(){a.G.Pf();k.resolve()}),Ik(d,HTMLMediaElement.HAVE_CURRENT_DATA,a.m,function(){var v;return O(function(w){if(1==w.g)return gp(a),v=hp(a),v.find(function(A){return"disabled"!=A.mode})?(0<v.length&&(a.ea=!0),w.B(2)):E(w,new Promise(function(A){a.m.oa(d.textTracks,
602
602
  "change",A);(new Ub(A)).V(1)}),2);if(e)return w.return();ip(a);F(w)})}),d.error?k.reject(uo(a)):"none"==d.preload&&(Ya('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.'),k.resolve()),a.m.oa(d,"error",function(){k.reject(uo(a))}),l=new Promise(function(v,w){(new Ub(w)).V(a.g.streaming.loadTimeout)}),E(u,Promise.race([k,
603
603
  l]),2);if((m=a.U())&&(a.g.streaming.liveSync||a.g.streaming.liveSyncPanicMode)||a.g.streaming.vodDynamicPlaybackRate)n=function(){return cp(a)},a.m.s(d,"timeupdate",n);m||(p=function(){return dp(a)},a.m.s(d,"timeupdate",p),dp(a));a.A&&(a.A.onManifestUpdated(m),m&&(r=a.Ta().end,a.m.s(d,"progress",function(){var v=a.Ta().end;r!=v&&(a.A.onManifestUpdated(a.U()),r=v)})));a.Na=!0;F(u)})}function gp(a){var b=a.g.preferredAudioLanguage;""!=b&&a.lf(b,a.g.preferredVariantRole)}
604
604
  function ip(a){var b=a.g.preferredTextLanguage;""!=b&&a.Ug(b,a.g.preferredTextRole,a.g.preferForcedSubs)}
605
605
  function ep(a,b){if("metadata"==b.kind){b.mode="hidden";a.m.s(b,"cuechange",function(){if(b.activeCues)for(var d=t(b.activeCues),e=d.next();!e.done;e=d.next())if(e=e.value,jp(a,e.startTime,e.endTime,e.type,e.value),a.A)a.A.onCueMetadataChange(e.value)});var c=(new Ub(function(){var d=kp(a);d=t(d);for(var e=d.next();!e.done;e=d.next())e.value.mode="hidden"})).Pa().V(.5);a.$d.push(function(){c.stop()})}}
606
606
  function No(a,b,c,d){b=t(b);for(var e=b.next();!e.done;e=b.next())if(e=e.value,e.data&&e.cueTime&&e.frames){var f=e.cueTime+c,g=d;g&&f>g&&(g=f);for(var h=t(e.frames),k=h.next();!k.done;k=h.next())jp(a,f,g,"org.id3",k.value);if(a.A)a.A.onHlsTimedMetadata(e,f)}}function jp(a,b,c,d,e){b=(new Map).set("startTime",b).set("endTime",c).set("metadataType",d).set("payload",e);a.dispatchEvent(po("metadata",b))}
607
- function Uo(a,b){if(b&&"chapters"==b.kind){b.mode="hidden";var c=(new Ub(function(){b.mode="hidden"})).Pa().V(.5);a.$d.push(function(){c.stop()})}}q.dk=function(){for(var a=this.S;a.g;)a.release()};q.Vc=function(a){return new Jh(a)};
607
+ function Uo(a,b){if(b&&"chapters"==b.kind){b.mode="hidden";var c=(new Ub(function(){b.mode="hidden"})).Pa().V(.5);a.$d.push(function(){c.stop()})}}q.dk=function(){for(var a=this.S;a.g;)a.release()};q.Wc=function(a){return new Jh(a)};
608
608
  function jo(a,b){function c(e){b()?b().dispatchEvent(e):a.dispatchEvent(e)}function d(e){b()?Bm(b(),!0,e):e()}b||(b=function(){return null});return new vg(function(e,f,g,h){var k=b()?b().i:a.o;k&&k.segmentDownloaded(e,f,g,h)},function(e,f,g){f=(new Map).set("headers",e).set("request",f).set("requestType",g);c(po("downloadheadersreceived",f));d(function(){if(a.$){var h=a.$;if(h.h.enabled){var k=e["cmsd-static"];if(k)try{var l=new Map,m=k.split(",");for(k=0;k<m.length;k++){var n=m[k].split("=");l.set(n[0],
609
609
  co(n[1]))}}catch(w){}if(l=e["cmsd-dynamic"]){try{var p=new Map,r=l.split(";");for(l=1;l<r.length;l++){var u=r[l].split("=");p.set(u[0],co(u[1]))}var v=p}catch(w){v=null}v&&(h.g=v)}}}})},function(e,f,g,h){e=(new Map).set("request",e).set("error",f).set("httpResponseCode",g).set("aborted",h);c(po("downloadfailed",e))},function(e,f,g){d(function(){var h=a.O,k=g;k=void 0===k?{}:k;if(h.g.enabled)if("HEAD"===f.method)An(h,f);else switch(e){case 0:try{if(h.g.enabled){if(k.type){a:{switch(k.type){case 4:var l=
610
610
  "d";break a;case 3:case 2:l="h";break a;case 5:l="s";break a}l=void 0}h.m=l}An(h,f,{ot:xn,su:!h.i})}}catch(M){Za("CMCD_MANIFEST_ERROR","Could not generate manifest CMCD data.",M)}break;case Gg:try{if(h.g.enabled){var m=k.segment;l=0;m&&(l=m.endTime-m.startTime);var n={d:1E3*l,st:h.h.U()?"l":"v"};n.ot=En(k);var p=n.ot===Bn||n.ot===vn||n.ot===wn||n.ot===Gn,r=k.stream;if(r){var u=h.h.Ra();if(p&&(n.bl=In(h,r.type),n.ot!==Gn)){var v=Jn(h,r.type);n.dl=u?v/Math.abs(u):v}r.bandwidth&&(n.br=r.bandwidth/1E3);
611
611
  if(r.segmentIndex&&m){var w=r.segmentIndex.Wb(m.endTime,!0,0>u);if(w){var A=w.next().value;if(A&&A!=m){if(!Qd(m.P(),A.P())){var z=A.P()[0],C=f.uris[0],y=new URL(z),B=new URL(C);if(y.origin!==B.origin)var D=z;else{for(var K=y.pathname.split("/").slice(1),G=B.pathname.split("/").slice(1,-1);K[0]===G[0];)K.shift(),G.shift();for(;G.length;)G.shift(),K.unshift("..");D=K.join("/")}n.nor=D}if((A.Wa||A.Da)&&(m.Wa!=A.Wa||m.Da!=A.Da)){var J=A.Wa+"-";A.Da&&(J+=A.Da);n.nrr=J}}}var I=h.h.Ra()||1,H=Jn(h,r.type)||
612
612
  500,N=r.bandwidth;var L=N?N*(m.endTime-m.startTime)/1E3/(H/I/1E3)*h.g.rtpSafetyFactor:NaN;isNaN(L)||(n.rtp=L)}}p&&n.ot!==Gn&&(n.tb=Kn(h,n.ot)/1E3);An(h,f,n)}}catch(M){Za("CMCD_SEGMENT_ERROR","Could not generate segment CMCD data.",M)}break;case 2:case 5:case 6:An(h,f,{ot:"k"});break;case 4:An(h,f,{ot:"o"})}})},function(e,f,g,h){(e=b()?b().j:a.K)&&e.banLocation&&e.banLocation(h)},function(e,f){f.data&&(e=f.data.byteLength,f=b()?b().getStats():a.u)&&(f.Be=isNaN(f.Be)?e:f.Be+e)})}
613
613
  function Wo(a,b){return new Sk(a.h,a.i,a.g.streaming,b,function(){a.Za&&dl(a.Za,!0);a.j&&a.j.ke();a.N&&lp(a)},function(c){return a.dispatchEvent(c)})}
614
- function Xo(a,b){b=new Pm(a.Ac,a.U()||0<b);b.addEventListener("enter",function(d){Io(a,"timelineregionenter",d.region)});b.addEventListener("exit",function(d){Io(a,"timelineregionexit",d.region)});b.addEventListener("skip",function(d){var e=d.region;d.seeking||(Io(a,"timelineregionenter",e),Io(a,"timelineregionexit",e))});var c=new cl(a.h);c.g.add(b);a.jb&&c.g.add(a.jb);return c}
614
+ function Xo(a,b){b=new Pm(a.Bc,a.U()||0<b);b.addEventListener("enter",function(d){Io(a,"timelineregionenter",d.region)});b.addEventListener("exit",function(d){Io(a,"timelineregionexit",d.region)});b.addEventListener("skip",function(d){var e=d.region;d.seeking||(Io(a,"timelineregionenter",e),Io(a,"timelineregionexit",e))});var c=new cl(a.h);c.g.add(b);a.jb&&c.g.add(a.jb);return c}
615
615
  function Yo(a,b,c){a.N=new eg;a.N.g=gg;hg(a.N,c,Math.min(.5,c/2));xo(a);a.rf=(new Ub(function(){lp(a)})).za(.25);a.m.s(b,"waiting",function(){return lp(a)});a.m.s(b,"stalled",function(){return lp(a)});a.m.s(b,"canplaythrough",function(){return lp(a)});a.m.s(b,"progress",function(){return lp(a)})}
616
- function lp(a){switch(a.l){case fp:if(a.h.ended)var b=!0;else{var c=Ni(a.h.buffered);b=null!=c&&c>=a.h.duration-1}break;case To:a:if(a.h.ended||Vj(a.H))b=!0;else{if(a.i.presentationTimeline.U()){c=a.i.presentationTimeline.ic();var d=Ni(a.h.buffered);if(null!=d&&d>=c){b=!0;break a}}b=!1}break;default:b=!1}d=Pi(a.h.buffered,a.h.currentTime);c=a.N;var e=b,f=c.i.get(c.g);b=c.g;d=e||d>=f?fg:gg;c.g=d;(b=b!=d)&&d===fg&&(c.h=Date.now());b&&xo(a)}function Mo(a,b,c,d){return new Mj(a,b,c,d)}
616
+ function lp(a){switch(a.l){case fp:if(a.h.ended)var b=!0;else{var c=Ni(a.h.buffered);b=null!=c&&c>=a.h.duration-1}break;case To:a:if(a.h.ended||Vj(a.H))b=!0;else{if(a.i.presentationTimeline.U()){c=a.i.presentationTimeline.jc();var d=Ni(a.h.buffered);if(null!=d&&d>=c){b=!0;break a}}b=!1}break;default:b=!1}d=Pi(a.h.buffered,a.h.currentTime);c=a.N;var e=b,f=c.i.get(c.g);b=c.g;d=e||d>=f?fg:gg;c.g=d;(b=b!=d)&&d===fg&&(c.h=Date.now());b&&xo(a)}function Mo(a,b,c,d){return new Mj(a,b,c,d)}
617
617
  function io(a){return new rn({getBandwidthEstimate:function(){return a.o?a.o.getBandwidthEstimate():NaN},Mb:function(){return a.Mb()},getCurrentTime:function(){return a.h?a.h.currentTime:0},Ra:function(){return a.Ra()},hc:function(){return a.hc()},Db:function(){return a.Db()},U:function(){return a.U()}},a.g.cmcd)}
618
618
  function So(a){return new Cl(a.i,{Le:function(){return a.G?a.G.Ae():0},getBandwidthEstimate:function(){return a.o.getBandwidthEstimate()},Ra:function(){return a.Ra()},ka:a.H,Zb:a.I,onError:function(b){return vo(a,b)},onEvent:function(b){return a.dispatchEvent(b)},Vj:function(){a.K&&a.K.update&&a.K.update()},Mg:function(b,c){var d=b.startTime,e=b.endTime,f=c.type,g=c.codecs.includes(",");if(a.G){a.G.Uh();var h=Wj(a.H,f);!a.U()&&a.h.paused&&null!=h&&0<h&&a.G.Ae()<h&&a.G.Qf(h)}lp(a);d=(new Map).set("start",
619
619
  d).set("end",e).set("contentType",f).set("isMuxed",g);a.dispatchEvent(po("segmentappended",d));a.o&&c.fastSwitching&&b.fe&&b.Te&&a.o.trySuggestStreams()},Uj:function(b,c){(c=c.Ig)&&a.jb&&zl(a.jb,c,b)},sh:function(b,c){var d=a.F;if(d.h.parseInbandPsshEnabled&&!d.H&&["audio","video"].includes(b)){c=new $g(Gb(c));var e=0,f=t(c.data);for(b=f.next();!b.done;b=f.next())e+=b.value.length;if(0==e)d=Promise.resolve();else{e=new Uint8Array(e);f=0;c=t(c.data);for(b=c.next();!b.done;b=c.next())b=b.value,e.set(b,
@@ -627,24 +627,24 @@ function mp(a){a.gf=new ti(a.g,a.ba,a.F);if(a.K){var b=Xe(a.g.manifest);a.h&&"AU
627
627
  a.Kf!=b){var c=b();c.configure?c.configure(a.g.textDisplayer):xd("Text displayer w/ configure",'Text displayer should have a "configure" method!');var d=a.H,e=d.H;d.H=c;e&&(c.setTextVisibility(e.isTextVisible()),e.destroy());d.g&&(d.g.j=c);a.Kf=b;a.j&&(b=a.j,(c=b.i.get(Sc))&&Pl(b,c.stream,!0,0,!0))}else b=a.H.H,b.configure&&b.configure(a.g.textDisplayer);a.o&&(a.o.configure(a.g.abr),a.g.abr.enabled?a.o.enable():a.o.disable(),bp(a));a.N&&(b=a.g.streaming.rebufferingGoal,a.i&&(b=Math.max(b,a.i.minBufferTime)),
628
628
  hg(a.N,b,Math.min(.5,b/2)));a.i&&Qo(a.i.presentationTimeline,a.g.playRangeStart,a.g.playRangeEnd);a.A&&a.A.configure(a.g.ads);a.O&&a.O.configure(a.g.cmcd);a.$&&a.$.configure(a.g.cmsd)}q.getConfiguration=function(){var a=ho(this);zm(a,this.g,ho(this));return a};q.kj=function(){var a=ho(this);zm(a,this.g,ho(this));return om(this.g,ho(this))};
629
629
  q.Fh=function(){if(this.h){var a=this.h.buffered.length;a=a?this.h.buffered.end(a-1):0;var b=this.getConfiguration().streaming.bufferingGoal;b=Math.min(this.h.currentTime+b,this.Ta().end);if(a>=b)return 1;if(!(a<=this.h.currentTime)&&a<b)return(a-this.h.currentTime)/(b-this.h.currentTime)}return 0};q.hk=function(){for(var a in this.g)delete this.g[a];zm(this.g,ho(this),ho(this));mp(this)};q.Qd=function(){return this.l};q.sg=function(){return this.i?this.i.type:null};q.jj=function(){return this.h};
630
- q.hc=function(){return this.I};q.Zc=function(){return this.Z};q.Ie=function(){return this.A?this.A:null};q.U=function(){return this.i?this.i.presentationTimeline.U():this.h&&this.h.src?Infinity==this.h.duration:!1};q.Ec=function(){return this.i?this.i.presentationTimeline.Ec():!1};q.dd=function(){if(this.i){var a=this.i.variants;return a.length?!a[0].video:!1}return this.h&&this.h.src?this.h.videoTracks?0==this.h.videoTracks.length:0==this.h.videoHeight:!1};
631
- q.Ta=function(){if(this.i){if(!this.Na&&"HLS"==this.i.type)return{start:0,end:0};var a=this.i.presentationTimeline;return{start:a.yc(),end:a.Ob()}}return this.h&&this.h.src&&(a=this.h.seekable,a.length)?{start:a.start(0),end:a.end(a.length-1)}:{start:0,end:0}};q.Aj=function(){this.U()&&(this.h.currentTime=this.Ta().end)};q.keySystem=function(){var a=this.drmInfo();return a?a.keySystem:""};q.drmInfo=function(){return this.F?this.F.g:null};q.Pd=function(){return this.F?this.F.Pd():Infinity};
630
+ q.hc=function(){return this.I};q.$c=function(){return this.X};q.Ie=function(){return this.A?this.A:null};q.U=function(){return this.i?this.i.presentationTimeline.U():this.h&&this.h.src?Infinity==this.h.duration:!1};q.Fc=function(){return this.i?this.i.presentationTimeline.Fc():!1};q.ed=function(){if(this.i){var a=this.i.variants;return a.length?!a[0].video:!1}return this.h&&this.h.src?this.h.videoTracks?0==this.h.videoTracks.length:0==this.h.videoHeight:!1};
631
+ q.Ta=function(){if(this.i){if(!this.Na&&"HLS"==this.i.type)return{start:0,end:0};var a=this.i.presentationTimeline;return{start:a.ic(),end:a.Ob()}}return this.h&&this.h.src&&(a=this.h.seekable,a.length)?{start:a.start(0),end:a.end(a.length-1)}:{start:0,end:0}};q.Aj=function(){this.U()&&(this.h.currentTime=this.Ta().end)};q.keySystem=function(){var a=this.drmInfo();return a?a.keySystem:""};q.drmInfo=function(){return this.F?this.F.g:null};q.Pd=function(){return this.F?this.F.Pd():Infinity};
632
632
  q.pg=function(){return this.F?this.F.pg():[]};q.Ke=function(){return this.F?this.F.Ke():{}};q.Wd=function(){return this.N?this.N.g==gg:!1};q.Ra=function(){return this.h?this.J?this.J.i:1:0};
633
- q.Mc=function(a){var b=this;0==a?Ya("A trick play rate of 0 is unsupported!"):(this.Ba.qb(),this.h.paused&&this.h.play(),this.J.set(a),this.l==To&&(this.o.playbackRateChanged(a),Ol(this.j,1<Math.abs(a))),this.U()&&this.Ba.s(this.h,"timeupdate",function(){var c=b.h.currentTime,d=b.Ta(),e=b.g.streaming.safeSeekOffset;0<a?Math.floor(c)>=Math.floor(d.end)&&b.Uc():Math.floor(c)<=Math.floor(d.start+e)&&b.Uc()}))};
634
- q.Uc=function(){var a=this.J.xc();this.l==fp&&this.J.set(a);this.l==To&&(this.J.set(a),this.o.playbackRateChanged(a),Ol(this.j,!1));this.Ba.qb()};
633
+ q.Nc=function(a){var b=this;0==a?Ya("A trick play rate of 0 is unsupported!"):(this.Ba.qb(),this.h.paused&&this.h.play(),this.J.set(a),this.l==To&&(this.o.playbackRateChanged(a),Ol(this.j,1<Math.abs(a))),this.U()&&this.Ba.s(this.h,"timeupdate",function(){var c=b.h.currentTime,d=b.Ta(),e=b.g.streaming.safeSeekOffset;0<a?Math.floor(c)>=Math.floor(d.end)&&b.Vc():Math.floor(c)<=Math.floor(d.start+e)&&b.Vc()}))};
634
+ q.Vc=function(){var a=this.J.zc();this.l==fp&&this.J.set(a);this.l==To&&(this.J.set(a),this.o.playbackRateChanged(a),Ol(this.j,!1));this.Ba.qb()};
635
635
  q.Db=function(){if(this.i){for(var a=this.j?this.j.j:null,b=[],c=0,d=t(this.i.variants),e=d.next();!e.done;e=d.next())if(e=e.value,Ef(e)){var f=wf(e);f.active=e==a;f.active||1==c||null==a||e.video!=a.video||e.audio!=a.audio||(f.active=!0);f.active&&c++;b.push(f)}return b}return this.h&&this.h.audioTracks?Array.from(this.h.audioTracks).map(function(g){return Df(g)}):[]};
636
- q.jc=function(){if(this.i){for(var a=this.j?this.j.u:null,b=[],c=t(this.i.textStreams),d=c.next();!d.done;d=c.next()){d=d.value;var e=xf(d);e.active=d==a;b.push(e)}return b}return this.h&&this.h.src&&this.h.textTracks?hp(this).map(function(f){return Bf(f)}):[]};q.Je=function(){var a=this.ie;this.i&&(a=this.i.imageStreams);return a.map(function(b){return yf(b)})};
637
- q.Qi=function(a){var b=this,c,d,e,f;return O(function(g){if(1==g.g){if(b.l!=To&&b.l!=fp)return g.return(null);c=b.ie;b.i&&(c=b.i.imageStreams);return(d=c.find(function(h){return h.id==a}))?d.segmentIndex?g.B(2):E(g,d.createSegmentIndex(),2):g.return(null)}if(4!=g.g)return e=[],d.segmentIndex.Xc(function(h){var k=np(h.tilesLayout||d.tilesLayout);if(k){k=k.rows*k.uc;for(var l=h.i-h.startTime,m=0;m<k;m++)e.push(b.vg(a,h.startTime+l*m/k))}}),E(g,Promise.all(e),4);f=g.h;return g.return(f.filter(function(h){return h}))})};
638
- function np(a){return a?(a=/(\d+)x(\d+)/.exec(a))?{uc:parseInt(a[1],10),rows:parseInt(a[2],10)}:null:null}
639
- q.vg=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y;return O(function(B){if(1==B.g){if(c.l!=To&&c.l!=fp)return B.return(null);d=c.ie;c.i&&(d=c.i.imageStreams);return(e=d.find(function(D){return D.id==a}))?e.segmentIndex?B.B(2):E(B,e.createSegmentIndex(),2):B.return(null)}f=e.segmentIndex.find(b);if(null==f)return B.return(null);g=e.segmentIndex.get(f);h=np(g.tilesLayout||e.tilesLayout);if(!h)return B.return(null);k=e.width||0;l=e.height||0;m=k/h.uc;n=l/h.rows;p=h.uc*h.rows;r=g.i-g.startTime;
640
- u=g.A||r/p;v=g.startTime;A=w=0;1<p&&(z=Math.floor((b-g.startTime)/u),v=g.startTime+z*u,w=z%h.uc*m,A=Math.floor(z/h.uc)*n);C=!1;if(y=g.u)C=!0,n=y.height,w=y.positionX,A=y.positionY,m=y.width;return B.return({segment:g,imageHeight:l,imageWidth:k,height:n,positionX:w,positionY:A,startTime:v,duration:u,uris:g.P(),width:m,sprite:C})})};
636
+ q.kc=function(){if(this.i){for(var a=this.j?this.j.u:null,b=[],c=t(this.i.textStreams),d=c.next();!d.done;d=c.next()){d=d.value;var e=xf(d);e.active=d==a;b.push(e)}return b}return this.h&&this.h.src&&this.h.textTracks?hp(this).map(function(f){return Bf(f)}):[]};q.Je=function(){var a=this.ie;this.i&&(a=this.i.imageStreams);return a.map(function(b){return yf(b)})};
637
+ q.Qi=function(a){var b=this,c,d,e,f;return O(function(g){if(1==g.g){if(b.l!=To&&b.l!=fp)return g.return(null);c=b.ie;b.i&&(c=b.i.imageStreams);return(d=c.find(function(h){return h.id==a}))?d.segmentIndex?g.B(2):E(g,d.createSegmentIndex(),2):g.return(null)}if(4!=g.g)return e=[],d.segmentIndex.Yc(function(h){var k=np(h.tilesLayout||d.tilesLayout);if(k){k=k.rows*k.wc;for(var l=h.i-h.startTime,m=0;m<k;m++)e.push(b.vg(a,h.startTime+l*m/k))}}),E(g,Promise.all(e),4);f=g.h;return g.return(f.filter(function(h){return h}))})};
638
+ function np(a){return a?(a=/(\d+)x(\d+)/.exec(a))?{wc:parseInt(a[1],10),rows:parseInt(a[2],10)}:null:null}
639
+ q.vg=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y;return O(function(B){if(1==B.g){if(c.l!=To&&c.l!=fp)return B.return(null);d=c.ie;c.i&&(d=c.i.imageStreams);return(e=d.find(function(D){return D.id==a}))?e.segmentIndex?B.B(2):E(B,e.createSegmentIndex(),2):B.return(null)}f=e.segmentIndex.find(b);if(null==f)return B.return(null);g=e.segmentIndex.get(f);h=np(g.tilesLayout||e.tilesLayout);if(!h)return B.return(null);k=e.width||0;l=e.height||0;m=k/h.wc;n=l/h.rows;p=h.wc*h.rows;r=g.i-g.startTime;
640
+ u=g.A||r/p;v=g.startTime;A=w=0;1<p&&(z=Math.floor((b-g.startTime)/u),v=g.startTime+z*u,w=z%h.wc*m,A=Math.floor(z/h.wc)*n);C=!1;if(y=g.u)C=!0,n=y.height,w=y.positionX,A=y.positionY,m=y.width;return B.return({segment:g,imageHeight:l,imageWidth:k,height:n,positionX:w,positionY:A,startTime:v,duration:u,uris:g.P(),width:m,sprite:C})})};
641
641
  q.Vg=function(a){if(this.i&&this.j){var b=this.i.textStreams.find(function(d){return d.id==a.id});b&&b!=this.j.u&&(il(this.u.h,b,!1),Rl(this.j,b),op(this),this.Ea=b.language)}else if(this.h&&this.h.src&&this.h.textTracks){b=hp(this);b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,zf(c)==a.id?c.mode=this.ea?"showing":"hidden":c.mode="disabled";op(this)}};
642
642
  q.mf=function(a,b,c){b=void 0===b?!1:b;c=void 0===c?0:c;if(this.i&&this.j){var d=this.i.variants.find(function(f){return f.id==a.id});if(d&&Ef(d)){var e=this.j.j;this.g.abr.enabled&&(e.video!=d.video||e.audio&&d.audio&&e.audio.language==d.audio.language&&e.audio.channelsCount==d.audio.channelsCount)&&Ya("Changing tracks while abr manager is enabled will likely result in the selected track being overriden. Consider disabling abr before calling selectVariantTrack().");Ro(this,d,!1,b,c);this.xa=new Vf(d,
643
- this.g.mediaSource.codecSwitchingStrategy,this.g.manifest.dash.enableAudioGroups);Ko(this)}}else if(this.h&&this.h.audioTracks)for(b=Array.from(this.h.audioTracks),b=t(b),c=b.next();!c.done;c=b.next())if(c=c.value,zf(c)==a.id){pp(this,c);break}};q.Si=function(){return qp(this.Db())};q.rj=function(){return qp(this.jc())};q.Ri=function(){return Array.from(rp(this.Db()))};q.qj=function(){return Array.from(rp(this.jc()))};
643
+ this.g.mediaSource.codecSwitchingStrategy,this.g.manifest.dash.enableAudioGroups);Ko(this)}}else if(this.h&&this.h.audioTracks)for(b=Array.from(this.h.audioTracks),b=t(b),c=b.next();!c.done;c=b.next())if(c=c.value,zf(c)==a.id){pp(this,c);break}};q.Si=function(){return qp(this.Db())};q.rj=function(){return qp(this.kc())};q.Ri=function(){return Array.from(rp(this.Db()))};q.qj=function(){return Array.from(rp(this.kc()))};
644
644
  q.lf=function(a,b,c,d){c=void 0===c?0:c;d=void 0===d?0:d;if(this.i&&this.G){this.xa=new Wf(a,b||"",c,"",!1,"","","",this.g.mediaSource.codecSwitchingStrategy,this.g.manifest.dash.enableAudioGroups);a=function(g,h){return g.video||h.video?g.video&&h.video?Math.abs((g.video.height||0)-(h.video.height||0))+Math.abs((g.video.width||0)-(h.video.width||0)):Infinity:0};b=this.j.j;var e=this.xa.create(this.i.variants);c=null;e=t(e.values());for(var f=e.next();!f.done;f=e.next())if(f=f.value,!c||a(c,b)>a(f,
645
- b))c=f;c!=b&&(c?(a=wf(c),this.mf(a,!0,d)):Lo(this))}else this.h&&this.h.audioTracks&&(d=Gf(this.Db(),a,b||"",!1)[0])&&this.mf(d)};q.Ug=function(a,b,c){c=void 0===c?!1:c;if(this.i&&this.G){if(this.Ea=a,this.ee=b||"",this.be=c,(a=Gf(this.i.textStreams,this.Ea,this.ee,this.be)[0]||null)&&a!=this.j.u&&(il(this.u.h,a,!1),this.g.streaming.alwaysStreamText||this.Fc()))Rl(this.j,a),op(this)}else(a=Gf(this.jc(),a,b||"",c)[0])&&this.Vg(a)};
645
+ b))c=f;c!=b&&(c?(a=wf(c),this.mf(a,!0,d)):Lo(this))}else this.h&&this.h.audioTracks&&(d=Gf(this.Db(),a,b||"",!1)[0])&&this.mf(d)};q.Ug=function(a,b,c){c=void 0===c?!1:c;if(this.i&&this.G){if(this.Ea=a,this.ee=b||"",this.be=c,(a=Gf(this.i.textStreams,this.Ea,this.ee,this.be)[0]||null)&&a!=this.j.u&&(il(this.u.h,a,!1),this.g.streaming.alwaysStreamText||this.Gc()))Rl(this.j,a),op(this)}else(a=Gf(this.kc(),a,b||"",c)[0])&&this.Vg(a)};
646
646
  q.qk=function(a,b,c){b=void 0===b?!0:b;c=void 0===c?0:c;if(this.i&&this.G){for(var d=null,e=t(this.i.variants),f=e.next();!f.done;f=e.next())if(f=f.value,f.audio.label==a){d=f;break}null!=d&&(this.xa=new Wf(d.language,"",0,"",!1,"",a,"",this.g.mediaSource.codecSwitchingStrategy,this.g.manifest.dash.enableAudioGroups),Lo(this,b,c))}else if(this.h&&this.h.audioTracks){c=Array.from(this.h.audioTracks);b=null;c=t(c);for(d=c.next();!d.done;d=c.next())d=d.value,d.label==a&&(b=d);b&&pp(this,b)}};
647
- q.Fc=function(){var a=this.ea;return this.H&&this.l==To?this.H.H.isTextVisible():this.h&&this.h.src&&this.h.textTracks?hp(this).some(function(b){return"showing"==b.mode}):a};q.Gh=function(){return this.h&&this.h.src&&this.h.textTracks?sp(this).map(function(a){return Bf(a)}):[]};
647
+ q.Gc=function(){var a=this.ea;return this.H&&this.l==To?this.H.H.isTextVisible():this.h&&this.h.src&&this.h.textTracks?hp(this).some(function(b){return"showing"==b.mode}):a};q.Gh=function(){return this.h&&this.h.src&&this.h.textTracks?sp(this).map(function(a){return Bf(a)}):[]};
648
648
  q.Ui=function(a){if(!this.h||!this.h.src||!this.h.textTracks)return[];var b=Xc(a),c=sp(this).filter(function(h){return Xc(h.language)==b});if(!c||!c.length)return[];a=[];var d=new Set;c=t(c);for(var e=c.next();!e.done;e=c.next())if((e=e.value)&&e.cues){e=t(e.cues);for(var f=e.next();!f.done;f=e.next()){var g=f.value;(f=g.id)&&""!=f||(f=g.startTime+"-"+g.endTime+"-"+g.text);g={id:f,title:g.text,startTime:g.startTime,endTime:g.endTime};d.has(f)||(a.push(g),d.add(f))}}return a};
649
649
  function hp(a){return Array.from(a.h.textTracks).filter(function(b){return"metadata"!=b.kind&&"chapters"!=b.kind&&"Shaka Player TextTrack"!=b.label})}function kp(a){return Array.from(a.h.textTracks).filter(function(b){return"metadata"==b.kind})}function sp(a){return Array.from(a.h.textTracks).filter(function(b){return"chapters"==b.kind})}
650
650
  q.pf=function(a){a=!!a;if(this.ea!=a){this.ea=a;if(this.l==To)this.H.H.setTextVisibility(a),this.g.streaming.alwaysStreamText||(a?this.j.u||(a=Gf(this.i.textStreams,this.Ea,this.ee,this.be),0<a.length&&(Rl(this.j,a[0]),op(this))):Nl(this.j));else if(this.h&&this.h.src&&this.h.textTracks){var b=hp(this);b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,"disabled"!=c.mode&&(c.mode=a?"showing":"hidden")}ap(this)}};
@@ -655,11 +655,11 @@ q.getStats=function(){if(this.l!=To&&this.l!=fp)return{width:NaN,height:NaN,stre
655
655
  this.u,d=c.video.height||NaN,b.o=c.video.width||NaN,b.l=d);this.U()&&(c=this.Jh().valueOf()+1E3*a.currentTime,this.u.G=(Date.now()-c)/1E3);this.i&&this.i.presentationTimeline&&(this.u.I=this.i.presentationTimeline.g);c=this.o.getBandwidthEstimate();this.u.A=c}this.l==fp&&(c=this.u,b=a.videoHeight||NaN,c.o=a.videoWidth||NaN,c.l=b);var f=this.u;a=f.o;c=f.l;b=f.F;d=f.K;e=f.L;var g=f.J,h=f.O,k=f.N,l=f.A,m=f.i,n=f.m,p=f.H,r=f.j,u=fl(f.g,"playing"),v=fl(f.g,"paused"),w=fl(f.g,"buffering"),A=f.u,z=f.G,C=
656
656
  f.I,y=f.Be,B=gl(f.g),D=[];f=t(f.h.g);for(var K=f.next();!K.done;K=f.next())K=K.value,D.push({timestamp:K.timestamp,id:K.id,type:K.type,fromAdaptation:K.fromAdaptation,bandwidth:K.bandwidth});return{width:a,height:c,streamBandwidth:b,decodedFrames:d,droppedFrames:e,corruptedFrames:g,stallsDetected:h,gapsJumped:k,estimatedBandwidth:l,completionPercent:m,loadLatency:n,manifestTimeSeconds:p,drmTimeSeconds:r,playTime:u,pauseTime:v,bufferingTime:w,licenseTime:A,liveLatency:z,maxSegmentDuration:C,bytesDownloaded:y,
657
657
  stateHistory:B,switchHistory:D}};
658
- q.Ei=function(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h=this,k,l,m,n,p,r,u,v,w,A,z,C;return O(function(y){switch(y.g){case 1:if(h.l!=To&&h.l!=fp)throw new U(1,7,7004);"subtitles"!=c&&"captions"!=c&&Ya("Using a kind value different of `subtitles` or `captions` can cause unwanted issues.");if(d){y.B(2);break}return E(y,tp(h,a),3);case 3:d=y.h;case 2:k=[];h.A&&(k=h.A.getCuePoints());if(h.l!=fp){y.B(4);break}g&&(c="forced");return E(y,up(h,a,b,c,d,f||"",k),5);case 5:l=Xc(b);m=h.jc();if(n=m.find(function(B){return Xc(B.language)==
658
+ q.Ei=function(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h=this,k,l,m,n,p,r,u,v,w,A,z,C;return O(function(y){switch(y.g){case 1:if(h.l!=To&&h.l!=fp)throw new U(1,7,7004);"subtitles"!=c&&"captions"!=c&&Ya("Using a kind value different of `subtitles` or `captions` can cause unwanted issues.");if(d){y.B(2);break}return E(y,tp(h,a),3);case 3:d=y.h;case 2:k=[];h.A&&(k=h.A.getCuePoints());if(h.l!=fp){y.B(4);break}g&&(c="forced");return E(y,up(h,a,b,c,d,f||"",k),5);case 5:l=Xc(b);m=h.kc();if(n=m.find(function(B){return Xc(B.language)==
659
659
  l&&B.label==(f||"")&&B.kind==c}))return Jo(h),y.return(n);throw new U(1,2,2012);case 4:p=Uc;r=h.h.duration;h.i&&(r=h.i.presentationTimeline.getDuration());if(Infinity==r)throw new U(1,4,4033);if(!k.length){y.B(6);break}return E(y,vp(h,a,h.I,h.g.streaming.retryParameters),7);case 7:u=y.h,v=wp(h,u,d,k),w=new Blob([v],{type:"text/vtt"}),a=Pj(w),d="text/vtt";case 6:A={id:h.Lf++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:Zk(0,r,[a]),mimeType:d||"",
660
660
  codecs:e||"",kind:c,encrypted:!1,drmInfos:[],keyIds:new Set,language:b,originalLanguage:b,label:f||null,type:p.Ga,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!!g,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!0,fastSwitching:!1,fullMimeTypes:new Set([te(d||"",e||"")])};z=te(A.mimeType,A.codecs);C=Ne(z);if(!C)throw new U(2,2,2014,d);h.i.textStreams.push(A);Jo(h);return y.return(xf(A))}})};
661
661
  q.Fi=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z;return O(function(C){switch(C.g){case 1:if(c.l!=To&&c.l!=fp)throw new U(1,7,7004);if(b){C.B(2);break}return E(C,tp(c,a),3);case 3:b=C.h;case 2:if("text/vtt"!=b)throw new U(1,2,2017,a);d=Uc;e=c.h.duration;c.i&&(e=c.i.presentationTimeline.getDuration());if(Infinity==e)throw new U(1,4,4045);return E(C,vp(c,a,c.I,c.g.streaming.retryParameters),4);case 4:f=C.h;g=Oe[b];if(!g)throw new U(2,2,2014,b);h=g();k={periodStart:0,segmentStart:0,segmentEnd:e,
662
- vttOffset:0};l=Gb(f);m=h.parseMedia(l,k,a);n=[];p={};r=t(m);for(u=r.next();!u.done;p={Gd:p.Gd,qc:p.qc},u=r.next())p.qc=u.value,p.Gd=null,v=function(y){return function(){null==y.Gd&&(y.Gd=Lc([a],[y.qc.payload]));return y.Gd||[]}}(p),w=new Ii(p.qc.startTime,p.qc.endTime,v,0,null,null,0,0,Infinity),p.qc.payload.includes("#xywh")&&(A=p.qc.payload.split("#xywh=")[1].split(","),4===A.length&&w.ji({height:parseInt(A[3],10),positionX:parseInt(A[0],10),positionY:parseInt(A[1],10),width:parseInt(A[2],10)})),
662
+ vttOffset:0};l=Gb(f);m=h.parseMedia(l,k,a);n=[];p={};r=t(m);for(u=r.next();!u.done;p={Hd:p.Hd,sc:p.sc},u=r.next())p.sc=u.value,p.Hd=null,v=function(y){return function(){null==y.Hd&&(y.Hd=Lc([a],[y.sc.payload]));return y.Hd||[]}}(p),w=new Ii(p.sc.startTime,p.sc.endTime,v,0,null,null,0,0,Infinity),p.sc.payload.includes("#xywh")&&(A=p.sc.payload.split("#xywh=")[1].split(","),4===A.length&&w.ji({height:parseInt(A[3],10),positionX:parseInt(A[0],10),positionY:parseInt(A[1],10),width:parseInt(A[2],10)})),
663
663
  n.push(w);z={id:c.Lf++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Xk(n),mimeType:b||"",codecs:"",kind:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:d.Of,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([te(b||
664
664
  "","")])};c.l==fp?c.ie.push(z):c.i.imageStreams.push(z);Jo(c);return C.return(yf(z))}})};
665
665
  q.Di=function(a,b,c){var d=this,e,f,g,h;return O(function(k){switch(k.g){case 1:if(d.l!=To&&d.l!=fp)throw new U(1,7,7004);if(c){k.B(2);break}return E(k,tp(d,a),3);case 3:c=k.h;case 2:return e=[],d.A&&(e=d.A.getCuePoints()),E(k,up(d,a,b,"chapters",c,"",e),4);case 4:f=k.h;g=d.Gh();h=g.find(function(l){return l.language==b});if(!h){k.B(5);break}return E(k,new Promise(function(l,m){d.m.oa(f,"load",l);d.m.oa(f,"error",function(){m(new U(1,2,2015))})}),6);case 6:return Jo(d),k.return(h);case 5:throw new U(1,
@@ -674,10 +674,10 @@ createSegmentIndex:function(){return Promise.resolve()},segmentIndex:k,mimeType:
674
674
  function Zo(a,b){var c,d,e,f,g;return O(function(h){if(1==h.g)return c=a.audio,d=a.video,e=function(k,l){var m,n,p;return O(function(r){if(1==r.g)return k?E(r,k.createSegmentIndex(),2):r.return(null);n=(m=k.segmentIndex.Wb(l))?m.next().value:null;if(!n)return r.return(null);p=n.startTime;return r.return(p)})},E(h,e(c,b),2);if(3!=h.g)return f=h.h,E(h,e(d,b),3);g=h.h;return null!=g&&null!=f?h.return(Math.max(g,f)):null!=g?h.return(g):null!=f?h.return(f):h.return(b)})}
675
675
  function xo(a){var b=a.Wd();if(a.u&&a.N&&a.G){var c=a.J;c.j=b;bl(c);a.O&&(c=a.O,b||c.i||(c.i=!0),c.i&&b&&(c.j=!0),c.l=b);Oo(a)}b=(new Map).set("buffering",b);a.dispatchEvent(po("buffering",b))}function Po(a){var b=a.h.playbackRate;0!=b&&(a.J&&a.J.set(b),b=po("ratechange"),a.dispatchEvent(b))}
676
676
  function Oo(a){if(a.u&&a.N){var b=a.u.g,c="playing";a.N.g==gg?c="buffering":a.h.paused?c="paused":a.h.ended&&(c="ended");var d=c;if(null==b.g)b.g={timestamp:Date.now()/1E3,state:d,duration:0},b=!0;else{var e=Date.now()/1E3;b.g.duration=e-b.g.timestamp;b.g.state==d?b=!1:(b.h.push(b.g),b.g={timestamp:e,state:d,duration:0},b=!0)}b&&(c=(new Map).set("newstate",c),a.dispatchEvent(po("statechanged",c)))}}
677
- function cp(a){var b=a.h.playbackRate,c=a.U();if(a.g.streaming.vodDynamicPlaybackRate&&!c){var d=a.g.streaming.vodDynamicPlaybackRateLowBufferRate,e=a.Fh();e<=a.g.streaming.vodDynamicPlaybackRateBufferRatio?b!=d&&a.Mc(d):1==e&&b!==a.J.xc()&&a.Uc()}if(c&&(e=a.Ta(),Number.isFinite(e.end)&&!(a.h.currentTime<e.start))){if(a.g.streaming.liveSync){var f=a.g.streaming.liveSyncMaxLatency;var g=a.g.streaming.liveSyncPlaybackRate}else a.i&&a.i.serviceDescription&&(f=a.g.streaming.liveSyncMaxLatency,null!=a.i.serviceDescription.targetLatency?
677
+ function cp(a){var b=a.h.playbackRate,c=a.U();if(a.g.streaming.vodDynamicPlaybackRate&&!c){var d=a.g.streaming.vodDynamicPlaybackRateLowBufferRate,e=a.Fh();e<=a.g.streaming.vodDynamicPlaybackRateBufferRatio?b!=d&&a.Nc(d):1==e&&b!==a.J.zc()&&a.Vc()}if(c&&(e=a.Ta(),Number.isFinite(e.end)&&!(a.h.currentTime<e.start))){if(a.g.streaming.liveSync){var f=a.g.streaming.liveSyncMaxLatency;var g=a.g.streaming.liveSyncPlaybackRate}else a.i&&a.i.serviceDescription&&(f=a.g.streaming.liveSyncMaxLatency,null!=a.i.serviceDescription.targetLatency?
678
678
  f=a.i.serviceDescription.targetLatency+a.g.streaming.liveSyncTargetLatencyTolerance:null!=a.i.serviceDescription.maxLatency&&(f=a.i.serviceDescription.maxLatency),g=a.i.serviceDescription.maxPlaybackRate||a.g.streaming.liveSyncPlaybackRate);if(a.g.streaming.liveSync){var h=a.g.streaming.liveSyncMinLatency;var k=a.g.streaming.liveSyncMinPlaybackRate}else a.i&&a.i.serviceDescription&&(h=a.g.streaming.liveSyncMinLatency,null!=a.i.serviceDescription.targetLatency?h=a.i.serviceDescription.targetLatency-
679
- a.g.streaming.liveSyncTargetLatencyTolerance:null!=a.i.serviceDescription.minLatency&&(h=a.i.serviceDescription.minLatency),k=a.i.serviceDescription.minPlaybackRate||a.g.streaming.liveSyncMinPlaybackRate);c=e.end-a.h.currentTime;d=0;if(a.l==fp){var l=a.h.buffered;0<l.length&&(d=l.end(l.length-1),d=Math.max(g,d-e.end))}e=a.g.streaming.liveSyncPanicMode;l=1E3*a.g.streaming.liveSyncPanicThreshold;var m=Date.now()-a.N.h;e&&!k&&(k=a.g.streaming.liveSyncMinPlaybackRate);e&&k&&m<=l?b!=k&&a.Mc(k):f&&g&&c-
680
- d>f?b!=g&&a.Mc(g):h&&k&&c-d<h?b!=k&&a.Mc(k):b!==a.J.xc()&&a.Uc()}}function dp(a){if(a.h){var b=!1,c=a.h.currentTime/a.h.duration;isNaN(c)||(c=Math.round(100*c),isNaN(a.R)?(a.R=c,b=!0):(c=Math.max(a.R,c),a.R!=c&&(a.R=c,b=!0)));if(b){var d;0==a.R?d=po("started"):25==a.R?d=po("firstquartile"):50==a.R?d=po("midpoint"):75==a.R?d=po("thirdquartile"):100==a.R&&(d=po("complete"));d&&a.dispatchEvent(d)}}}
679
+ a.g.streaming.liveSyncTargetLatencyTolerance:null!=a.i.serviceDescription.minLatency&&(h=a.i.serviceDescription.minLatency),k=a.i.serviceDescription.minPlaybackRate||a.g.streaming.liveSyncMinPlaybackRate);c=e.end-a.h.currentTime;d=0;if(a.l==fp){var l=a.h.buffered;0<l.length&&(d=l.end(l.length-1),d=Math.max(g,d-e.end))}e=a.g.streaming.liveSyncPanicMode;l=1E3*a.g.streaming.liveSyncPanicThreshold;var m=Date.now()-a.N.h;e&&!k&&(k=a.g.streaming.liveSyncMinPlaybackRate);e&&k&&m<=l?b!=k&&a.Nc(k):f&&g&&c-
680
+ d>f?b!=g&&a.Nc(g):h&&k&&c-d<h?b!=k&&a.Nc(k):b!==a.J.zc()&&a.Vc()}}function dp(a){if(a.h){var b=!1,c=a.h.currentTime/a.h.duration;isNaN(c)||(c=Math.round(100*c),isNaN(a.R)?(a.R=c,b=!0):(c=Math.max(a.R,c),a.R!=c&&(a.R=c,b=!0)));if(b){var d;0==a.R?d=po("started"):25==a.R?d=po("firstquartile"):50==a.R?d=po("midpoint"):75==a.R?d=po("thirdquartile"):100==a.R&&(d=po("complete"));d&&a.dispatchEvent(d)}}}
681
681
  function Ko(a){try{xi(a.gf,a.i)}catch(c){return vo(a,c),!1}var b=Ff(a.i.variants);b=a.xa.create(b);a.o.setVariants(Array.from(b.values()));return!0}function Vo(a,b){b=void 0===b?!1:b;return Ko(a)?a.o.chooseVariant(b):null}
682
682
  function mo(a){function b(g){var h="";g.video&&(h+="video:"+g.video.id);g.audio&&(h=h+(h?"&":"")+("audio:"+g.audio.id));return h}for(var c=Date.now()/1E3,d=!1,e=t(a.i.variants),f=e.next();!f.done;f=e.next())f=f.value,0<f.disabledUntilTime&&f.disabledUntilTime<=c&&(f.disabledUntilTime=0,d=!0,eb("Re-enabled variant with "+b(f)));a.i.variants.every(function(g){return 0===g.disabledUntilTime})&&a.uf.stop();d&&Lo(a,!1,void 0,!1,!1)}
683
683
  function Lo(a,b,c,d,e){b=void 0===b?!0:b;c=void 0===c?0:c;d=void 0===d?!1:d;e=void 0===e?!0:e;var f=Vo(a);f&&Ro(a,f,e,b,c,d)}function Ro(a,b,c,d,e,f){f=void 0===f?!1:f;var g=a.j.j;if(b==g)d&&Ql(a.j,b,d,e,!0);else{var h=a.u.h;h.h!=b&&(h.h=b,h.g.push({timestamp:Date.now()/1E3,id:b.id,type:"variant",fromAdaptation:c,bandwidth:b.bandwidth}));Ql(a.j,b,d,e,f,c);d=null;g&&(d=wf(g));b=wf(b);c?(c=(new Map).set("oldTrack",d).set("newTrack",b),a.L&&Fj(a.L,b,a.sg()),c=po("adaptation",c),xp(a,c)):yp(a,d,b)}}
@@ -690,21 +690,21 @@ function Io(a,b,c,d){d=void 0===d?a:d;a=(new Map).set("detail",{schemeIdUri:c.sc
690
690
  function Qo(a,b,c){0<b&&(a.U()||a.li(b));b=a.getDuration();c<b&&(a.U()||a.sb(c))}function xp(a,b){O(function(c){if(1==c.g)return E(c,Promise.resolve(),2);a.l!=qo&&a.dispatchEvent(b);F(c)})}function rp(a){var b=new Set;a=t(a);for(var c=a.next();!c.done;c=a.next())c=c.value,c.language?b.add(Xc(c.language)):b.add("und");return b}
691
691
  function qp(a){var b=new Map,c=new Map;a=t(a);for(var d=a.next();!d.done;d=a.next()){d=d.value;var e="und",f=[];d.language&&(e=Xc(d.language));"variant"==d.type?f=d.audioRoles:f=d.roles;f&&f.length||(f=[""]);b.has(e)||b.set(e,new Set);f=t(f);for(var g=f.next();!g.done;g=f.next())g=g.value,b.get(e).add(g),d.label&&(c.has(e)||c.set(e,new Map),c.get(e).set(g,d.label))}var h=[];b.forEach(function(k,l){k=t(k);for(var m=k.next();!m.done;m=k.next()){m=m.value;var n=null;c.has(l)&&c.get(l).has(m)&&(n=c.get(l).get(m));
692
692
  h.push({language:l,role:m,label:n})}});return h}P("shaka.Player",X);X.prototype.setVideoContainer=X.prototype.dh;X.prototype.getManifestParserFactory=X.prototype.hj;X.prototype.getManifest=X.prototype.rg;X.prototype.retryStreaming=X.prototype.Rg;X.prototype.setMaxHardwareResolution=X.prototype.yk;X.prototype.addChaptersTrack=X.prototype.Di;X.prototype.addThumbnailsTrack=X.prototype.Fi;X.prototype.addTextTrackAsync=X.prototype.Ei;X.prototype.getStats=X.prototype.getStats;
693
- X.prototype.getBufferedInfo=X.prototype.Mb;X.prototype.getSegmentAvailabilityDuration=X.prototype.Ne;X.prototype.getPresentationStartTimeAsDate=X.prototype.Jh;X.prototype.getPlayheadTimeAsDate=X.prototype.lj;X.prototype.setTextTrackVisibility=X.prototype.pf;X.prototype.getChapters=X.prototype.Ui;X.prototype.getChaptersTracks=X.prototype.Gh;X.prototype.isTextTrackVisible=X.prototype.Fc;X.prototype.selectVariantsByLabel=X.prototype.qk;X.prototype.selectTextLanguage=X.prototype.Ug;
694
- X.prototype.selectAudioLanguage=X.prototype.lf;X.prototype.getTextLanguages=X.prototype.qj;X.prototype.getAudioLanguages=X.prototype.Ri;X.prototype.getTextLanguagesAndRoles=X.prototype.rj;X.prototype.getAudioLanguagesAndRoles=X.prototype.Si;X.prototype.selectVariantTrack=X.prototype.mf;X.prototype.selectTextTrack=X.prototype.Vg;X.prototype.getThumbnails=X.prototype.vg;X.prototype.getAllThumbnails=X.prototype.Qi;X.prototype.getImageTracks=X.prototype.Je;X.prototype.getTextTracks=X.prototype.jc;
695
- X.prototype.getVariantTracks=X.prototype.Db;X.prototype.cancelTrickPlay=X.prototype.Uc;X.prototype.trickPlay=X.prototype.Mc;X.prototype.getPlaybackRate=X.prototype.Ra;X.prototype.isBuffering=X.prototype.Wd;X.prototype.getKeyStatuses=X.prototype.Ke;X.prototype.getActiveSessionsMetadata=X.prototype.pg;X.prototype.getExpiration=X.prototype.Pd;X.prototype.drmInfo=X.prototype.drmInfo;X.prototype.keySystem=X.prototype.keySystem;X.prototype.goToLive=X.prototype.Aj;X.prototype.seekRange=X.prototype.Ta;
696
- X.prototype.isAudioOnly=X.prototype.dd;X.prototype.isInProgress=X.prototype.Ec;X.prototype.isLive=X.prototype.U;X.prototype.getAdManager=X.prototype.Ie;X.prototype.getAssetUri=X.prototype.Zc;X.prototype.getNetworkingEngine=X.prototype.hc;X.prototype.getMediaElement=X.prototype.jj;X.prototype.getManifestType=X.prototype.sg;X.prototype.getLoadMode=X.prototype.Qd;X.prototype.resetConfiguration=X.prototype.hk;X.prototype.getBufferFullness=X.prototype.Fh;X.prototype.getNonDefaultConfiguration=X.prototype.kj;
697
- X.prototype.getConfiguration=X.prototype.getConfiguration;X.prototype.configure=X.prototype.configure;X.prototype.releaseAllMutexes=X.prototype.dk;X.prototype.preload=X.prototype.preload;X.prototype.detachAndSavePreload=X.prototype.Bh;X.prototype.unloadAndSavePreload=X.prototype.Ck;X.prototype.load=X.prototype.load;X.prototype.updateStartTime=X.prototype.Gk;X.prototype.unload=X.prototype.Nc;X.prototype.detach=X.prototype.detach;X.prototype.attachCanvas=X.prototype.qh;X.prototype.attach=X.prototype.tc;
693
+ X.prototype.getBufferedInfo=X.prototype.Mb;X.prototype.getSegmentAvailabilityDuration=X.prototype.Ne;X.prototype.getPresentationStartTimeAsDate=X.prototype.Jh;X.prototype.getPlayheadTimeAsDate=X.prototype.lj;X.prototype.setTextTrackVisibility=X.prototype.pf;X.prototype.getChapters=X.prototype.Ui;X.prototype.getChaptersTracks=X.prototype.Gh;X.prototype.isTextTrackVisible=X.prototype.Gc;X.prototype.selectVariantsByLabel=X.prototype.qk;X.prototype.selectTextLanguage=X.prototype.Ug;
694
+ X.prototype.selectAudioLanguage=X.prototype.lf;X.prototype.getTextLanguages=X.prototype.qj;X.prototype.getAudioLanguages=X.prototype.Ri;X.prototype.getTextLanguagesAndRoles=X.prototype.rj;X.prototype.getAudioLanguagesAndRoles=X.prototype.Si;X.prototype.selectVariantTrack=X.prototype.mf;X.prototype.selectTextTrack=X.prototype.Vg;X.prototype.getThumbnails=X.prototype.vg;X.prototype.getAllThumbnails=X.prototype.Qi;X.prototype.getImageTracks=X.prototype.Je;X.prototype.getTextTracks=X.prototype.kc;
695
+ X.prototype.getVariantTracks=X.prototype.Db;X.prototype.cancelTrickPlay=X.prototype.Vc;X.prototype.trickPlay=X.prototype.Nc;X.prototype.getPlaybackRate=X.prototype.Ra;X.prototype.isBuffering=X.prototype.Wd;X.prototype.getKeyStatuses=X.prototype.Ke;X.prototype.getActiveSessionsMetadata=X.prototype.pg;X.prototype.getExpiration=X.prototype.Pd;X.prototype.drmInfo=X.prototype.drmInfo;X.prototype.keySystem=X.prototype.keySystem;X.prototype.goToLive=X.prototype.Aj;X.prototype.seekRange=X.prototype.Ta;
696
+ X.prototype.isAudioOnly=X.prototype.ed;X.prototype.isInProgress=X.prototype.Fc;X.prototype.isLive=X.prototype.U;X.prototype.getAdManager=X.prototype.Ie;X.prototype.getAssetUri=X.prototype.$c;X.prototype.getNetworkingEngine=X.prototype.hc;X.prototype.getMediaElement=X.prototype.jj;X.prototype.getManifestType=X.prototype.sg;X.prototype.getLoadMode=X.prototype.Qd;X.prototype.resetConfiguration=X.prototype.hk;X.prototype.getBufferFullness=X.prototype.Fh;X.prototype.getNonDefaultConfiguration=X.prototype.kj;
697
+ X.prototype.getConfiguration=X.prototype.getConfiguration;X.prototype.configure=X.prototype.configure;X.prototype.releaseAllMutexes=X.prototype.dk;X.prototype.preload=X.prototype.preload;X.prototype.detachAndSavePreload=X.prototype.Bh;X.prototype.unloadAndSavePreload=X.prototype.Ck;X.prototype.load=X.prototype.load;X.prototype.updateStartTime=X.prototype.Gk;X.prototype.unload=X.prototype.Oc;X.prototype.detach=X.prototype.detach;X.prototype.attachCanvas=X.prototype.qh;X.prototype.attach=X.prototype.vc;
698
698
  X.probeSupport=function(a){a=void 0===a?!0:a;var b,c,d,e,f,g,h;return O(function(k){switch(k.g){case 1:b={};if(!a){k.B(2);break}return E(k,qi(),3);case 3:b=k.h;case 2:var l={};if(Vb())for(var m in Bi)l[m]=!0;m=t(["application/dash+xml","application/x-mpegurl","application/vnd.apple.mpegurl","application/vnd.ms-sstr+xml"]);for(var n=m.next();!n.done;n=m.next())n=n.value,l[n]=Vb()?!!Bi[n]:Wb(n);c=l;m='video/mp4; codecs="avc1.42E01E",video/mp4; codecs="avc3.42E01E",video/mp4; codecs="hev1.1.6.L93.90",video/mp4; codecs="hvc1.1.6.L93.90",video/mp4; codecs="hev1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="hvc1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="vp9",video/mp4; codecs="vp09.00.10.08",video/mp4; codecs="av01.0.01M.08",video/mp4; codecs="dvh1.20.01",audio/mp4; codecs="mp4a.40.2",audio/mp4; codecs="ac-3",audio/mp4; codecs="ec-3",audio/mp4; codecs="ac-4.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(x(ue));
699
699
  l={};m=t(m);for(n=m.next();!n.done;n=m.next()){n=n.value;l[n]=Ne(n)?!0:Vb()?td(n)||(ne(n)?!0:!1):Wb(n);var p=n.split(";")[0];l[p]=l[p]||l[n]}d=l;return E(k,uc(),4);case 4:e=k.h;f={manifest:c,media:d,drm:b,hardwareResolution:e};g=zp;for(h in g)f[h]=g[h]();return k.return(f)}})};X.isBrowserSupported=ro;X.setAdManagerFactory=function(a){ko=a};X.registerSupportPlugin=function(a,b){zp[a]=b};X.prototype.destroy=X.prototype.destroy;var qo=0,go=1,To=2,fp=3;
700
- X.LoadMode={DESTROYED:qo,NOT_LOADED:go,MEDIA_SOURCE:To,SRC_EQUALS:fp};X.version="v4.9.17";var Ap=["4","9"];yd=new function(a){this.g=a;this.i=zd;this.h=Ad}(new wd(Number(Ap[0]),Number(Ap[1])));var zp={},ko=null;function Bp(){this.h=[];this.j=this.i=this.g=0};function Cp(a,b,c){var d=this;this.g=a;this.h=b;this.j=c;this.i=!1;this.l=this.h.getVolume();this.m=new od;this.m.s(this.h,google.ima.AdEvent.Type.PAUSED,function(){d.i=!0});this.m.s(this.h,google.ima.AdEvent.Type.RESUMED,function(){d.i=!1})}q=Cp.prototype;q.getDuration=function(){return this.g.getDuration()};q.getMinSuggestedDuration=function(){return this.g.getMinSuggestedDuration()};q.getRemainingTime=function(){return this.h.getRemainingTime()};q.isPaused=function(){return this.i};
700
+ X.LoadMode={DESTROYED:qo,NOT_LOADED:go,MEDIA_SOURCE:To,SRC_EQUALS:fp};X.version="v4.9.18";var Ap=["4","9"];yd=new function(a){this.g=a;this.i=zd;this.h=Ad}(new wd(Number(Ap[0]),Number(Ap[1])));var zp={},ko=null;function Bp(){this.h=[];this.j=this.i=this.g=0};function Cp(a,b,c){var d=this;this.g=a;this.h=b;this.j=c;this.i=!1;this.l=this.h.getVolume();this.m=new od;this.m.s(this.h,google.ima.AdEvent.Type.PAUSED,function(){d.i=!0});this.m.s(this.h,google.ima.AdEvent.Type.RESUMED,function(){d.i=!1})}q=Cp.prototype;q.getDuration=function(){return this.g.getDuration()};q.getMinSuggestedDuration=function(){return this.g.getMinSuggestedDuration()};q.getRemainingTime=function(){return this.h.getRemainingTime()};q.isPaused=function(){return this.i};
701
701
  q.isSkippable=function(){return 0<=this.g.getSkipTimeOffset()};q.getTimeUntilSkippable=function(){var a=this.g.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};q.canSkipNow=function(){return this.h.getAdSkippableState()};q.skip=function(){return this.h.skip()};q.pause=function(){return this.h.pause()};q.play=function(){return this.h.resume()};q.getVolume=function(){return this.h.getVolume()};q.setVolume=function(a){this.j.volume=a;return this.h.setVolume(a)};
702
702
  q.isMuted=function(){return 0==this.h.getVolume()};q.isLinear=function(){return this.g.isLinear()};q.resize=function(a,b){var c=!1,d=this.j;document.fullscreenEnabled?c=!!document.fullscreenElement:d.webkitSupportsFullscreen&&(c=d.webkitDisplayingFullscreen);this.h.resize(a,b,c?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)};q.setMuted=function(a){(this.j.muted=a)?(this.l=this.getVolume(),this.h.setVolume(0)):this.h.setVolume(this.l)};
703
703
  q.getSequenceLength=function(){var a=this.g.getAdPodInfo();return null==a?1:a.getTotalAds()};q.getPositionInSequence=function(){var a=this.g.getAdPodInfo();return null==a?1:a.getAdPosition()};q.getTitle=function(){return this.g.getTitle()};q.getDescription=function(){return this.g.getDescription()};q.getVastMediaBitrate=function(){return this.g.getVastMediaBitrate()};q.getVastMediaHeight=function(){return this.g.getVastMediaHeight()};q.getVastMediaWidth=function(){return this.g.getVastMediaWidth()};
704
704
  q.getAdId=function(){return this.g.getAdId()};q.getCreativeAdId=function(){return this.g.getCreativeAdId()};q.getAdvertiserName=function(){return this.g.getAdvertiserName()};q.getMediaUrl=function(){return this.g.getMediaUrl()};q.getTimeOffset=function(){var a=this.g.getAdPodInfo();return null==a?0:a.getTimeOffset()};q.getPodIndex=function(){var a=this.g.getAdPodInfo();return null==a?0:a.getPodIndex()};q.release=function(){this.h=this.g=null};P("shaka.ads.ClientSideAd",Cp);Cp.prototype.release=Cp.prototype.release;
705
705
  Cp.prototype.getPodIndex=Cp.prototype.getPodIndex;Cp.prototype.getTimeOffset=Cp.prototype.getTimeOffset;Cp.prototype.getMediaUrl=Cp.prototype.getMediaUrl;Cp.prototype.getAdvertiserName=Cp.prototype.getAdvertiserName;Cp.prototype.getCreativeAdId=Cp.prototype.getCreativeAdId;Cp.prototype.getAdId=Cp.prototype.getAdId;Cp.prototype.getVastMediaWidth=Cp.prototype.getVastMediaWidth;Cp.prototype.getVastMediaHeight=Cp.prototype.getVastMediaHeight;Cp.prototype.getVastMediaBitrate=Cp.prototype.getVastMediaBitrate;
706
706
  Cp.prototype.getDescription=Cp.prototype.getDescription;Cp.prototype.getTitle=Cp.prototype.getTitle;Cp.prototype.getPositionInSequence=Cp.prototype.getPositionInSequence;Cp.prototype.getSequenceLength=Cp.prototype.getSequenceLength;Cp.prototype.setMuted=Cp.prototype.setMuted;Cp.prototype.resize=Cp.prototype.resize;Cp.prototype.isLinear=Cp.prototype.isLinear;Cp.prototype.isMuted=Cp.prototype.isMuted;Cp.prototype.setVolume=Cp.prototype.setVolume;Cp.prototype.getVolume=Cp.prototype.getVolume;
707
- Cp.prototype.play=Cp.prototype.play;Cp.prototype.pause=Cp.prototype.pause;Cp.prototype.skip=Cp.prototype.skip;Cp.prototype.canSkipNow=Cp.prototype.canSkipNow;Cp.prototype.getTimeUntilSkippable=Cp.prototype.getTimeUntilSkippable;Cp.prototype.isSkippable=Cp.prototype.isSkippable;Cp.prototype.isPaused=Cp.prototype.isPaused;Cp.prototype.getRemainingTime=Cp.prototype.getRemainingTime;Cp.prototype.getMinSuggestedDuration=Cp.prototype.getMinSuggestedDuration;Cp.prototype.getDuration=Cp.prototype.getDuration;function Dp(a,b,c,d,e){var f=this;this.o=a;this.i=b;this.H=!1;this.A=this.u=null;this.I=NaN;this.m=e;this.j=null;this.h=new od;google.ima.settings.setLocale(c);google.ima.settings.setDisableCustomPlaybackForIOS10Plus(!0);this.G=new google.ima.AdDisplayContainer(this.o,this.i);this.G.initialize();this.l=new google.ima.AdsLoader(this.G);this.l.getSettings().setPlayerType("shaka-player");this.l.getSettings().setPlayerVersion("v4.9.17");this.g=null;this.F=d||new google.ima.AdsRenderingSettings;this.h.s(this.l,
707
+ Cp.prototype.play=Cp.prototype.play;Cp.prototype.pause=Cp.prototype.pause;Cp.prototype.skip=Cp.prototype.skip;Cp.prototype.canSkipNow=Cp.prototype.canSkipNow;Cp.prototype.getTimeUntilSkippable=Cp.prototype.getTimeUntilSkippable;Cp.prototype.isSkippable=Cp.prototype.isSkippable;Cp.prototype.isPaused=Cp.prototype.isPaused;Cp.prototype.getRemainingTime=Cp.prototype.getRemainingTime;Cp.prototype.getMinSuggestedDuration=Cp.prototype.getMinSuggestedDuration;Cp.prototype.getDuration=Cp.prototype.getDuration;function Dp(a,b,c,d,e){var f=this;this.o=a;this.i=b;this.H=!1;this.A=this.u=null;this.I=NaN;this.m=e;this.j=null;this.h=new od;google.ima.settings.setLocale(c);google.ima.settings.setDisableCustomPlaybackForIOS10Plus(!0);this.G=new google.ima.AdDisplayContainer(this.o,this.i);this.G.initialize();this.l=new google.ima.AdsLoader(this.G);this.l.getSettings().setPlayerType("shaka-player");this.l.getSettings().setPlayerVersion("v4.9.18");this.g=null;this.F=d||new google.ima.AdsRenderingSettings;this.h.s(this.l,
708
708
  google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,function(g){Ep(f,g)});this.h.s(this.l,google.ima.AdErrorEvent.Type.AD_ERROR,function(g){Fp(f,g)});this.h.s(this.i,"ended",function(){f.l.contentComplete()});this.h.oa(this.i,"play",function(){f.H=!0})}Dp.prototype.configure=function(a){this.u=a};Dp.prototype.stop=function(){this.g&&this.g.stop();this.o&&fn(this.o)};
709
709
  Dp.prototype.release=function(){this.stop();this.A&&this.A.disconnect();this.h&&this.h.release();this.g&&this.g.destroy();this.l.destroy();this.G.destroy()};function Fp(a,b){b.getError();b=(new Map).set("originalEvent",b);a.m(new S("ad-error",b));Gp(a,null);a.m(new S("ad-cue-points-changed",(new Map).set("cuepoints",[])))}
710
710
  function Ep(a,b){a.m(new S("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.I)));if(a.u.customPlayheadTracker){var c={currentTime:a.i.currentTime};a.g=b.getAdsManager(c,a.F);a.i.muted?a.g.setVolume(0):a.g.setVolume(a.i.volume);a.h.s(a.i,"timeupdate",function(){a.i.duration&&(c.currentTime=a.i.currentTime)});a.h.s(a.i,"volumechange",function(){a.j&&(a.j.setVolume(a.i.volume),a.i.muted&&a.j.setMuted(!0))})}else a.g=b.getAdsManager(a.i,a.F);a.m(new S("ima-ad-manager-loaded",(new Map).set("imaAdManager",
@@ -756,8 +756,8 @@ function cq(a,b){a.i(new S("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-
756
756
  q.release=function(){this.i&&(this.i.release(),this.i=null);this.h&&(this.h.release(),this.h=null);this.g&&(this.g.release(),this.g=null);gb.prototype.release.call(this)};q.onAssetUnload=function(){this.i&&this.i.stop();this.h&&this.h.stop();this.g&&this.g.stop();this.dispatchEvent(new S("ad-stopped"));this.j=new Bp};q.requestClientSideAds=function(a){if(!this.i)throw new U(1,10,10001);var b=this.i;b.g&&b.g.destroy();b.l&&b.l.contentComplete();b.I=Date.now()/1E3;b.l.requestAds(a)};
757
757
  q.updateClientSideAdsRenderingSettings=function(a){if(!this.i)throw new U(1,10,10001);var b=this.i;b.F=a;b.g&&b.g.updateAdsRenderingSettings(b.F)};q.initMediaTailor=function(a,b,c){var d=this;this.h&&this.h.release();this.h=new Qp(a,b,c,function(e){return eq(d,e)})};q.requestMediaTailorStream=function(a,b,c){if(!this.h)throw new U(1,10,10005);var d=this.h;c=void 0===c?"":c;d.l?a=Promise.reject(new U(1,10,10004)):(d.l=new lg,Tp(d,a,b),d.J=c||"",d.S=Date.now()/1E3,a=d.l);return a};
758
758
  q.addMediaTailorTrackingUrl=function(a){if(!this.h)throw new U(1,10,10005);var b=this.h;b.I=a;b.i(new S("ads-loaded",(new Map).set("loadTime",0)))};q.initServerSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.dai)throw new U(2,10,10002);this.g&&this.g.release();this.g=new bq(a,b,this.m,function(d){return eq(c,d)});this.g.configure(this.l)};
759
- q.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new U(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Ya('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.');a.adTagParameters.mpt="shaka-player";a.adTagParameters.mpv="v4.9.17";c=this.g;c.j?a=Promise.reject(new U(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
760
- (c.I=!0),c.j=new lg,c.g.requestStream(a),c.F=b||"",c.H=Date.now()/1E3,a=c.j);return a};q.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new U(1,10,10003);(a.mpt||a.mpv)&&Ya('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.');a.mpt="Shaka Player";a.mpv="v4.9.17";this.g.g.replaceAdTagParameters(a)};
759
+ q.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new U(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Ya('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.');a.adTagParameters.mpt="shaka-player";a.adTagParameters.mpv="v4.9.18";c=this.g;c.j?a=Promise.reject(new U(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
760
+ (c.I=!0),c.j=new lg,c.g.requestStream(a),c.F=b||"",c.H=Date.now()/1E3,a=c.j);return a};q.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new U(1,10,10003);(a.mpt||a.mpv)&&Ya('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.');a.mpt="Shaka Player";a.mpv="v4.9.18";this.g.g.replaceAdTagParameters(a)};
761
761
  q.getServerSideCuePoints=function(){xd("AdManager.getServerSideCuePoints","Please use getCuePoints function.");return this.getCuePoints()};q.getCuePoints=function(){var a=[];this.g&&(a=a.concat(this.g.getCuePoints()));this.h&&(a=a.concat(this.h.getCuePoints()));return a};q.getStats=function(){var a=this.j;return{loadTimes:a.h,started:a.g,playedCompletely:a.i,skipped:a.j}};q.onManifestUpdated=function(a){if(this.h)this.h.onManifestUpdated(a)};
762
762
  q.onDashTimedMetadata=function(a){this.g&&"urn:google:dai:2018"==a.schemeIdUri&&this.g.g.processMetadata(a.schemeIdUri,a.eventNode?a.eventNode.attributes.messageData:null,a.startTime)};q.onHlsTimedMetadata=function(a,b){this.g&&this.g.g.processMetadata("ID3",a.data,b)};q.onCueMetadataChange=function(a){if(this.g)this.g.onCueMetadataChange(a)};
763
763
  function eq(a,b){if(b&&b.type)switch(b.type){case "ads-loaded":a.j.h.push(b.loadTime);break;case "ad-started":a.j.g++;break;case "ad-complete":a.j.i++;break;case "ad-skipped":a.j.j++}a.dispatchEvent(b)}P("shaka.ads.AdManager",dq);dq.prototype.onCueMetadataChange=dq.prototype.onCueMetadataChange;dq.prototype.onHlsTimedMetadata=dq.prototype.onHlsTimedMetadata;dq.prototype.onDashTimedMetadata=dq.prototype.onDashTimedMetadata;dq.prototype.onManifestUpdated=dq.prototype.onManifestUpdated;
@@ -775,27 +775,27 @@ sq=["attach","attachCanvas","detach","load","unload"];function tq(a,b,c,d,e,f,g)
775
775
  p.code);for(m in p)n[m]=p[m];k.reject(n)}else k.resolve()}};this.g={video:{},player:{}};this.J=0;this.i={};this.j=null;vq.add(this)}q=tq.prototype;q.destroy=function(){vq.delete(this);wq(this);xq&&yq(this);this.l&&(this.l.stop(),this.l=null);this.H=this.A=null;this.h=this.m=!1;this.G=this.F=this.j=this.i=this.g=this.o=null;return Promise.resolve()};q.Oa=function(){return this.h};q.hf=function(){return this.K};
776
776
  q.init=function(){if(this.I.length)if(window.chrome&&chrome.cast&&chrome.cast.isAvailable){this.m=!0;this.l.Pa();var a=new chrome.cast.SessionRequest(this.I,[],null,this.L,null);a=new chrome.cast.ApiConfig(a,function(b){for(var c=t(vq),d=c.next();!d.done;d=c.next()){d=d.value;var e=b;d.j=new lg;d.u=!0;zq(d,e)}},function(b){for(var c=t(vq),d=c.next();!d.done;d=c.next())d=d.value,Aq="available"==b,d.l.Pa()},"origin_scoped");chrome.cast.initialize(a,function(){},function(){});Aq&&this.l.V(Bq);(a=xq)&&
777
777
  a.status!=chrome.cast.SessionStatus.STOPPED?(this.j=new lg,this.u=!0,zq(this,a)):xq=null}else window.__onGCastApiAvailable!==Cq&&(Dq=window.__onGCastApiAvailable||null,window.__onGCastApiAvailable=Cq)};q.Wg=function(a){this.o=a;this.h&&Eq(this,{type:"appData",appData:this.o})};
778
- q.cast=function(){var a=this;return O(function(b){if(!a.m)throw new U(1,8,8E3);if(!Aq)throw new U(1,8,8001);if(a.h)throw new U(1,8,8002);a.j=new lg;chrome.cast.requestSession(function(c){return zq(a,c)},function(c){return Fq(a,c)});return E(b,a.j,0)})};function Gq(a){a.h&&chrome.cast.requestSession(function(b){return zq(a,b)},function(b){return Fq(a,b)})}q.Yc=function(){if(this.h){wq(this);if(xq){yq(this);try{xq.stop(function(){},function(){})}catch(a){}xq=null}uq(this)}};
778
+ q.cast=function(){var a=this;return O(function(b){if(!a.m)throw new U(1,8,8E3);if(!Aq)throw new U(1,8,8001);if(a.h)throw new U(1,8,8002);a.j=new lg;chrome.cast.requestSession(function(c){return zq(a,c)},function(c){return Fq(a,c)});return E(b,a.j,0)})};function Gq(a){a.h&&chrome.cast.requestSession(function(b){return zq(a,b)},function(b){return Fq(a,b)})}q.Zc=function(){if(this.h){wq(this);if(xq){yq(this);try{xq.stop(function(){},function(){})}catch(a){}xq=null}uq(this)}};
779
779
  q.get=function(a,b){var c=this;if("video"==a){if(lq.includes(b))return function(){return c.Zh.apply(c,[a,b].concat(x(Ka.apply(0,arguments))))}}else if("player"==a){if(oq[b]&&!this.get("player","isLive")())return function(){};if(rq.includes(b))return function(){return c.Zh.apply(c,[a,b].concat(x(Ka.apply(0,arguments))))};if(sq.includes(b))return function(){return c.ek.apply(c,[a,b].concat(x(Ka.apply(0,arguments))))};if(mq[b]||nq[b])return function(){return c.g[a][b]}}return this.g[a][b]};
780
780
  q.set=function(a,b,c){this.g[a][b]=c;Eq(this,{type:"set",targetName:a,property:b,value:c})};function zq(a,b){var c=a.O();xq=b;b.addUpdateListener(a.F);b.addMessageListener("urn:x-cast:com.google.shaka.v2",a.G);uq(a);Eq(a,{type:"init",initState:c,appData:a.o});a.j.resolve()}function Fq(a,b){var c=8003;switch(b.code){case "cancel":c=8004;break;case "timeout":c=8005;break;case "receiver_unavailable":c=8006}a.j.reject(new U(2,8,c,b))}
781
781
  q.Zh=function(a,b){Eq(this,{type:"call",targetName:a,methodName:b,args:Ka.apply(2,arguments)})};q.ek=function(a,b){var c=Ka.apply(2,arguments),d=new lg,e=this.J.toString();this.J++;this.i[e]=d;try{Eq(this,{type:"asyncCall",targetName:a,methodName:b,args:c,id:e})}catch(f){d.reject(f)}return d};function yq(a){var b=xq;b.removeUpdateListener(a.F);b.removeMessageListener("urn:x-cast:com.google.shaka.v2",a.G)}
782
- function uq(a){var b=xq?"connected"==xq.status:!1;if(a.h&&!b){a.H();for(var c in a.g)a.g[c]={};wq(a)}a.h=b;a.K=b?xq.receiver.friendlyName:"";a.l.Pa()}function wq(a){for(var b in a.i){var c=a.i[b];delete a.i[b];c.reject(new U(1,7,7E3))}}function Eq(a,b){b=fq(b);var c=xq;try{c.sendMessage("urn:x-cast:com.google.shaka.v2",b,function(){},bb)}catch(d){throw b=new U(2,8,8005,d),c=new S("error",(new Map).set("detail",b)),a.A("player",c),a.Yc(),b;}}var Bq=.02,Aq=!1,xq=null,Dq=null,vq=new Set;
782
+ function uq(a){var b=xq?"connected"==xq.status:!1;if(a.h&&!b){a.H();for(var c in a.g)a.g[c]={};wq(a)}a.h=b;a.K=b?xq.receiver.friendlyName:"";a.l.Pa()}function wq(a){for(var b in a.i){var c=a.i[b];delete a.i[b];c.reject(new U(1,7,7E3))}}function Eq(a,b){b=fq(b);var c=xq;try{c.sendMessage("urn:x-cast:com.google.shaka.v2",b,function(){},bb)}catch(d){throw b=new U(2,8,8005,d),c=new S("error",(new Map).set("detail",b)),a.A("player",c),a.Zc(),b;}}var Bq=.02,Aq=!1,xq=null,Dq=null,vq=new Set;
783
783
  function Cq(a){Dq?window.__onGCastApiAvailable=Dq:delete window.__onGCastApiAvailable;Dq=null;if(a)for(var b=t(vq),c=b.next();!c.done;c=b.next())c.value.init();"function"===typeof window.__onGCastApiAvailable&&window.__onGCastApiAvailable(a)};function Hq(a,b,c,d){d=void 0===d?!1:d;gb.call(this);var e=this;this.i=a;this.h=b;this.m=this.o=this.j=this.u=this.l=null;this.G=c;this.F=d;this.A=new Map;this.g=new tq(c,function(){return Iq(e)},function(){return Jq(e)},function(f,g){return Kq(e,f,g)},function(){return Lq(e)},function(){return Mq(e)},d);Nq(this)}na(Hq,gb);q=Hq.prototype;
784
- q.destroy=function(a){a&&this.g.Yc();this.m&&(this.m.release(),this.m=null);a=[];this.h&&(a.push(this.h.destroy()),this.h=null);this.g&&(a.push(this.g.destroy()),this.g=null);this.u=this.l=this.i=null;gb.prototype.release.call(this);return Promise.all(a)};q.kc=function(){return this.l};q.$c=function(){return this.u};q.Uf=function(){return this.g.m&&Aq};q.Oa=function(){return this.g.Oa()};q.hf=function(){return this.g.hf()};
785
- q.cast=function(){var a=this;return O(function(b){return 1==b.g?E(b,a.g.cast(),2):a.h?E(b,a.h.Nc(),0):b.return()})};q.Wg=function(a){this.g.Wg(a)};q.ni=function(){Gq(this.g)};q.Yc=function(){this.g.Yc()};
786
- q.wh=function(a,b){b=void 0===b?!1:b;var c=this;return O(function(d){if(1==d.g){if(a==c.G&&b==c.F)return d.return();c.G=a;c.F=b;c.g.Yc();return E(d,c.g.destroy(),2)}c.g=null;c.g=new tq(a,function(){return Iq(c)},function(){return Jq(c)},function(e,f){return Kq(c,e,f)},function(){return Lq(c)},function(){return Mq(c)},b);c.g.init();F(d)})};
784
+ q.destroy=function(a){a&&this.g.Zc();this.m&&(this.m.release(),this.m=null);a=[];this.h&&(a.push(this.h.destroy()),this.h=null);this.g&&(a.push(this.g.destroy()),this.g=null);this.u=this.l=this.i=null;gb.prototype.release.call(this);return Promise.all(a)};q.lc=function(){return this.l};q.bd=function(){return this.u};q.Uf=function(){return this.g.m&&Aq};q.Oa=function(){return this.g.Oa()};q.hf=function(){return this.g.hf()};
785
+ q.cast=function(){var a=this;return O(function(b){return 1==b.g?E(b,a.g.cast(),2):a.h?E(b,a.h.Oc(),0):b.return()})};q.Wg=function(a){this.g.Wg(a)};q.ni=function(){Gq(this.g)};q.Zc=function(){this.g.Zc()};
786
+ q.wh=function(a,b){b=void 0===b?!1:b;var c=this;return O(function(d){if(1==d.g){if(a==c.G&&b==c.F)return d.return();c.G=a;c.F=b;c.g.Zc();return E(d,c.g.destroy(),2)}c.g=null;c.g=new tq(a,function(){return Iq(c)},function(){return Jq(c)},function(e,f){return Kq(c,e,f)},function(){return Lq(c)},function(){return Mq(c)},b);c.g.init();F(d)})};
787
787
  function Nq(a){a.g.init();a.m=new od;for(var b=t(iq),c=b.next();!c.done;c=b.next())a.m.s(a.i,c.value,function(f){a.g.Oa()||(f=Ua(f),a.j.dispatchEvent(f))});for(var d in Va)a.m.s(a.h,Va[d],function(f){a.g.Oa()||a.o.dispatchEvent(f)});a.l={};b={};for(var e in a.i)b.wd=e,Object.defineProperty(a.l,b.wd,{configurable:!1,enumerable:!0,get:function(f){return function(){return Oq(a,f.wd)}}(b),set:function(f){return function(g){var h=f.wd;a.g.Oa()?a.g.set("video",h,g):a.i[h]=g}}(b)}),b={wd:b.wd};a.u={};Pq(a,
788
788
  function(f){Object.defineProperty(a.u,f,{configurable:!1,enumerable:!0,get:function(){return Qq(a,f)}})});Rq(a);a.j=new gb;a.j.vf=a.l;a.o=new gb;a.o.vf=a.u}function Rq(a){var b=new Map;Pq(a,function(c,d){b.has(d)?(d=b.get(d),c.length<d.length?a.A.set(c,d):a.A.set(d,c)):b.set(d,c)})}
789
789
  function Pq(a,b){function c(k){return"constructor"==k||"function"!=typeof d[k]?!1:!e.has(k)}var d=a.h,e=new Set,f;for(f in d)c(f)&&(e.add(f),b(f,d[f]));a=Object.getPrototypeOf(d);for(f=Object.getPrototypeOf({});a&&a!=f;){for(var g=t(Object.getOwnPropertyNames(a)),h=g.next();!h.done;h=g.next())h=h.value,c(h)&&(e.add(h),b(h,d[h]));a=Object.getPrototypeOf(a)}}
790
- function Mq(a){var b={video:{},player:{},playerAfterLoad:{},manifest:a.h.Zc(),startTime:null};a.i.pause();for(var c=t(kq),d=c.next();!d.done;d=c.next())d=d.value,b.video[d]=a.i[d];a.i.ended||(b.startTime=a.i.currentTime);c=t(pq);for(d=c.next();!d.done;d=c.next()){var e=d.value;d=e[1];e=a.h[e[0]]();b.player[d]=e}c=t(qq);for(d=c.next();!d.done;d=c.next())e=d.value,d=e[1],e=a.h[e[0]](),b.playerAfterLoad[d]=e;return b}function Iq(a){var b=new S("caststatuschanged");a.dispatchEvent(b)}
790
+ function Mq(a){var b={video:{},player:{},playerAfterLoad:{},manifest:a.h.$c(),startTime:null};a.i.pause();for(var c=t(kq),d=c.next();!d.done;d=c.next())d=d.value,b.video[d]=a.i[d];a.i.ended||(b.startTime=a.i.currentTime);c=t(pq);for(d=c.next();!d.done;d=c.next()){var e=d.value;d=e[1];e=a.h[e[0]]();b.player[d]=e}c=t(qq);for(d=c.next();!d.done;d=c.next())e=d.value,d=e[1],e=a.h[e[0]](),b.playerAfterLoad[d]=e;return b}function Iq(a){var b=new S("caststatuschanged");a.dispatchEvent(b)}
791
791
  function Jq(a){var b=new S(a.l.paused?"pause":"play");a.j.dispatchEvent(b)}
792
792
  function Lq(a){for(var b=t(pq),c=b.next();!c.done;c=b.next()){var d=c.value;c=d[1];d=a.g.get("player",d[0])();a.h[c](d)}var e=a.g.get("player","getAssetUri")();d=a.g.get("video","ended");b=Promise.resolve();var f=a.i.autoplay;c=null;d||(c=a.g.get("video","currentTime"));var g;(d=a.g.get("player","getTextTracks")())&&d.length&&(g=d.find(function(l){return l.active}));var h=a.g.get("player","isTextTrackVisible")();e&&(a.i.autoplay=!1,b=a.h.load(e,c));var k={};c=t(kq);for(d=c.next();!d.done;d=c.next())d=
793
793
  d.value,k[d]=a.g.get("video",d);b.then(function(){if(a.i){for(var l=t(kq),m=l.next();!m.done;m=l.next())m=m.value,a.i[m]=k[m];l=t(qq);for(m=l.next();!m.done;m=l.next()){var n=m.value;m=n[1];n=a.g.get("player",n[0])();a.h[m](n)}a.h.pf(h);g&&a.h.Ug(g.language,g.roles,g.forced);a.i.autoplay=f;e&&a.i.play()}},function(l){l=(new Map).set("detail",l);l=new S("error",l);a.h.dispatchEvent(l)})}
794
794
  function Oq(a,b){if("addEventListener"==b)return function(d,e,f){return a.j.addEventListener(d,e,f)};if("removeEventListener"==b)return function(d,e,f){return a.j.removeEventListener(d,e,f)};if(a.g.Oa()&&0==Object.keys(a.g.g.video).length){var c=a.i[b];if("function"!=typeof c)return c}return a.g.Oa()?a.g.get("video",b):(b=a.i[b],"function"==typeof b&&(b=b.bind(a.i)),b)}
795
795
  function Qq(a,b){a.A.has(b)&&(b=a.A.get(b));if("addEventListener"==b)return function(c,d,e){return a.o.addEventListener(c,d,e)};if("removeEventListener"==b)return function(c,d,e){return a.o.removeEventListener(c,d,e)};if("getMediaElement"==b)return function(){return a.l};if("getSharedConfiguration"==b)return a.g.get("player","getConfiguration");if("getNetworkingEngine"==b)return function(){return a.h.hc()};if("getDrmEngine"==b)return function(){return a.h.F};if("getAdManager"==b)return function(){return a.h.Ie()};
796
796
  if("setVideoContainer"==b)return function(c){return a.h.dh(c)};if(a.g.Oa()){if("getManifest"==b||"drmInfo"==b)return function(){Ya(b+"() does not work while casting!");return null};if("attach"==b||"detach"==b)return function(){Ya(b+"() does not work while casting!");return Promise.resolve()}}return a.g.Oa()&&0==Object.keys(a.g.g.video).length&&(mq[b]||nq[b])||!a.g.Oa()?a.h[b].bind(a.h):a.g.get("player",b)}
797
- function Kq(a,b,c){a.g.Oa()&&("video"==b?a.j.dispatchEvent(c):"player"==b&&a.o.dispatchEvent(c))}P("shaka.cast.CastProxy",Hq);Hq.prototype.changeReceiverId=Hq.prototype.wh;Hq.prototype.forceDisconnect=Hq.prototype.Yc;Hq.prototype.suggestDisconnect=Hq.prototype.ni;Hq.prototype.setAppData=Hq.prototype.Wg;Hq.prototype.cast=Hq.prototype.cast;Hq.prototype.receiverName=Hq.prototype.hf;Hq.prototype.isCasting=Hq.prototype.Oa;Hq.prototype.canCast=Hq.prototype.Uf;Hq.prototype.getPlayer=Hq.prototype.$c;
798
- Hq.prototype.getVideo=Hq.prototype.kc;Hq.prototype.destroy=Hq.prototype.destroy;function Sq(a,b,c,d){gb.call(this);var e=this;this.g=a;this.h=b;this.j=new od;this.J={video:a,player:b};this.G=c||function(){};this.K=d||function(f){return f};this.i=null;this.H=!1;this.o=!0;this.m=0;this.F=!1;this.A=!0;this.u=this.l=null;this.I=new Ub(function(){Tq(e)});Uq(this)}na(Sq,gb);q=Sq.prototype;q.isConnected=function(){return this.H};q.Fj=function(){return this.o};q.vk=function(a){this.i=a};q.Ni=function(){this.i=null};
797
+ function Kq(a,b,c){a.g.Oa()&&("video"==b?a.j.dispatchEvent(c):"player"==b&&a.o.dispatchEvent(c))}P("shaka.cast.CastProxy",Hq);Hq.prototype.changeReceiverId=Hq.prototype.wh;Hq.prototype.forceDisconnect=Hq.prototype.Zc;Hq.prototype.suggestDisconnect=Hq.prototype.ni;Hq.prototype.setAppData=Hq.prototype.Wg;Hq.prototype.cast=Hq.prototype.cast;Hq.prototype.receiverName=Hq.prototype.hf;Hq.prototype.isCasting=Hq.prototype.Oa;Hq.prototype.canCast=Hq.prototype.Uf;Hq.prototype.getPlayer=Hq.prototype.bd;
798
+ Hq.prototype.getVideo=Hq.prototype.lc;Hq.prototype.destroy=Hq.prototype.destroy;function Sq(a,b,c,d){gb.call(this);var e=this;this.g=a;this.h=b;this.j=new od;this.J={video:a,player:b};this.G=c||function(){};this.K=d||function(f){return f};this.i=null;this.H=!1;this.o=!0;this.m=0;this.F=!1;this.A=!0;this.u=this.l=null;this.I=new Ub(function(){Tq(e)});Uq(this)}na(Sq,gb);q=Sq.prototype;q.isConnected=function(){return this.H};q.Fj=function(){return this.o};q.vk=function(a){this.i=a};q.Ni=function(){this.i=null};
799
799
  q.wk=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.title=a};q.tk=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.images=[{url:a}]};q.rk=function(a){this.i||(this.i={});this.i.artist=a;this.i.metadataType=cast.receiver.media.MetadataType.MUSIC_TRACK};
800
800
  q.destroy=function(){var a=this,b,c;return O(function(d){if(1==d.g)return a.j&&(a.j.release(),a.j=null),b=[],a.h&&(b.push(a.h.destroy()),a.h=null),a.I&&(a.I.stop(),a.I=null),a.g=null,a.J=null,a.G=null,a.H=!1,a.o=!0,a.l=null,a.u=null,gb.prototype.release.call(a),E(d,Promise.all(b),2);c=cast.receiver.CastReceiverManager.getInstance();c.stop();F(d)})};
801
801
  function Uq(a){var b=cast.receiver.CastReceiverManager.getInstance();b.onSenderConnected=function(){return Vq(a)};b.onSenderDisconnected=function(){return Vq(a)};b.onSystemVolumeChanged=function(){var e=cast.receiver.CastReceiverManager.getInstance().getSystemVolume();e&&Wq(a,{type:"update",update:{video:{volume:e.level,muted:e.muted}}},a.l);Wq(a,{type:"event",targetName:"video",event:{type:"volumechange"}},a.l)};a.u=b.getCastMessageBus("urn:x-cast:com.google.cast.media");a.u.onMessage=function(e){return Xq(a,
@@ -804,10 +804,10 @@ a.j.s(a.g,"ended",function(){(new Ub(function(){a.g&&a.g.ended&&(a.o=!0,$q(a))})
804
804
  function dr(a,b,c){var d,e,f,g,h,k,l,m,n,p;O(function(r){switch(r.g){case 1:for(d in b.player)e=b.player[d],a.h[d](e);a.G(c);f=a.g.autoplay;return b.manifest?(a.g.autoplay=!1,ta(r,5),E(r,a.h.load(b.manifest,b.startTime),7)):E(r,Promise.resolve(),3);case 7:va(r,3);break;case 5:return g=wa(r),h=(new Map).set("detail",g),k=new S("error",h),a.h&&a.h.dispatchEvent(k),r.return();case 3:if(!a.h)return r.return();for(l in b.video)m=b.video[l],a.g[l]=m;for(n in b.playerAfterLoad)p=b.playerAfterLoad[n],a.h[n](p);
805
805
  a.g.autoplay=f;b.manifest&&(a.g.play(),cr(a));F(r)}})}function Zq(a,b,c){a.h&&(Tq(a),Wq(a,{type:"event",targetName:b,event:c},a.l))}
806
806
  function Tq(a){a.I.V(er);for(var b={video:{},player:{}},c=t(jq),d=c.next();!d.done;d=c.next())d=d.value,b.video[d]=a.g[d];if(a.h.U())for(var e in oq)0==a.m%oq[e]&&(b.player[e]=a.h[e]());for(var f in mq)0==a.m%mq[f]&&(b.player[f]=a.h[f]());if(c=cast.receiver.CastReceiverManager.getInstance().getSystemVolume())b.video.volume=c.level,b.video.muted=c.muted;Wq(a,{type:"update",update:b},a.l);for(var g in nq)0==a.m%nq[g]&&(b={player:{}},b.player[g]=a.h[g](),Wq(a,{type:"update",update:b},a.l));a.F&&(a.m+=
807
- 1);br(a)}function br(a){return a.A&&(a.g.duration||a.h.U())?(fr(a),a.A=!1,!0):!1}function fr(a,b){var c={contentId:a.h.Zc(),streamType:a.h.U()?"LIVE":"BUFFERED",contentType:""};a.h.U()||(c.duration=a.g.duration);a.i&&(c.metadata=a.i);cr(a,void 0===b?0:b,c)}
807
+ 1);br(a)}function br(a){return a.A&&(a.g.duration||a.h.U())?(fr(a),a.A=!1,!0):!1}function fr(a,b){var c={contentId:a.h.$c(),streamType:a.h.U()?"LIVE":"BUFFERED",contentType:""};a.h.U()||(c.duration=a.g.duration);a.i&&(c.metadata=a.i);cr(a,void 0===b?0:b,c)}
808
808
  function Yq(a,b){var c=gq(b.data);switch(c.type){case "init":a.m=0;a.F=!1;a.A=!0;dr(a,c.initState,c.appData);Tq(a);break;case "appData":a.G(c.appData);break;case "set":var d=c.targetName,e=c.property;c=c.value;if("video"==d)if(b=cast.receiver.CastReceiverManager.getInstance(),"volume"==e){b.setSystemVolumeLevel(c);break}else if("muted"==e){b.setSystemVolumeMuted(c);break}a.J[d][e]=c;break;case "call":d=a.J[c.targetName];d[c.methodName].apply(d,c.args);break;case "asyncCall":d=c.targetName;e=c.methodName;
809
809
  "player"==d&&"load"==e&&(a.m=0,a.F=!1);var f=c.id,g=b.senderId;b=a.J[d];c=b[e].apply(b,c.args);"player"==d&&"load"==e&&(c=c.then(function(){a.A=!0}));c.then(function(){return gr(a,g,f,null)},function(h){return gr(a,g,f,h)})}}
810
- function Xq(a,b){var c=gq(b.data);switch(c.type){case "PLAY":a.g.play();cr(a);break;case "PAUSE":a.g.pause();cr(a);break;case "SEEK":b=c.currentTime;var d=c.resumeState;null!=b&&(a.g.currentTime=Number(b));d&&"PLAYBACK_START"==d?(a.g.play(),cr(a)):d&&"PLAYBACK_PAUSE"==d&&(a.g.pause(),cr(a));break;case "STOP":a.h.Nc().then(function(){a.h&&cr(a)});break;case "GET_STATUS":fr(a,Number(c.requestId));break;case "VOLUME":d=c.volume;b=d.level;d=d.muted;var e=a.g.volume,f=a.g.muted;null!=b&&(a.g.volume=Number(b));
810
+ function Xq(a,b){var c=gq(b.data);switch(c.type){case "PLAY":a.g.play();cr(a);break;case "PAUSE":a.g.pause();cr(a);break;case "SEEK":b=c.currentTime;var d=c.resumeState;null!=b&&(a.g.currentTime=Number(b));d&&"PLAYBACK_START"==d?(a.g.play(),cr(a)):d&&"PLAYBACK_PAUSE"==d&&(a.g.pause(),cr(a));break;case "STOP":a.h.Oc().then(function(){a.h&&cr(a)});break;case "GET_STATUS":fr(a,Number(c.requestId));break;case "VOLUME":d=c.volume;b=d.level;d=d.muted;var e=a.g.volume,f=a.g.muted;null!=b&&(a.g.volume=Number(b));
811
811
  null!=d&&(a.g.muted=d);e==a.g.volume&&f==a.g.muted||cr(a);break;case "LOAD":a.m=0;a.F=!1;a.A=!1;b=c.media;d=c.currentTime;e=a.K(b.contentId);f=c.autoplay||!0;a.G(b.customData);f&&(a.g.autoplay=!0);a.h.load(e,d).then(function(){a.h&&fr(a)}).catch(function(g){var h="LOAD_FAILED";7==g.category&&7E3==g.code&&(h="LOAD_CANCELLED");Wq(a,{requestId:Number(c.requestId),type:h},a.u)});break;default:Wq(a,{requestId:Number(c.requestId),type:"INVALID_REQUEST",reason:"INVALID_COMMAND"},a.u)}}
812
812
  function gr(a,b,c,d){a.h&&Wq(a,{type:"asyncComplete",id:c,error:d},a.l,b)}function Wq(a,b,c,d){a.H&&(a=fq(b),d?c.getCastChannel(d).send(a):c.broadcast(a))}function cr(a,b,c){c=void 0===c?null:c;var d={mediaSessionId:0,playbackRate:a.g.playbackRate,playerState:a.o?hr:a.h.Wd()?ir:a.g.paused?jr:kr,currentTime:a.g.currentTime,supportedMediaCommands:63,volume:{level:a.g.volume,muted:a.g.muted}};c&&(d.media=c);Wq(a,{requestId:void 0===b?0:b,type:"MEDIA_STATUS",status:[d]},a.u)}
813
813
  P("shaka.cast.CastReceiver",Sq);Sq.prototype.destroy=Sq.prototype.destroy;Sq.prototype.setContentArtist=Sq.prototype.rk;Sq.prototype.setContentImage=Sq.prototype.tk;Sq.prototype.setContentTitle=Sq.prototype.wk;Sq.prototype.clearContentMetadata=Sq.prototype.Ni;Sq.prototype.setContentMetadata=Sq.prototype.vk;Sq.prototype.isIdle=Sq.prototype.Fj;Sq.prototype.isConnected=Sq.prototype.isConnected;var er=.5,ar=5,hr="IDLE",kr="PLAYING",ir="BUFFERING",jr="PAUSED";function lr(a,b,c,d,e){if(d>=e)return null;for(var f=-1,g=-1,h=0;h<c.length;h++)if(c[h].some(function(y){return null!=y&&""!=y.g.trim()})){f=h;break}for(h=c.length-1;0<=h;h--)if(c[h].some(function(y){return null!=y&&""!=y.g.trim()})){g=h;break}if(-1===f||-1===g)return null;for(var k=h=!1,l="white",m="black",n=mr(d,e,h,k,l,m);f<=g;f++){for(var p=c[f],r=-1,u=-1,v=0;v<p.length;v++)if(null!=p[v]&&""!==p[v].g.trim()){r=v;break}for(v=p.length-1;0<=v;v--)if(null!=p[v]&&""!==p[v].g.trim()){u=v;break}if(-1===
@@ -826,7 +826,7 @@ b.skip(1),d=is(b).value,b.skip(1),a.g&&(a.g.H=d&3);else if(152<=c&&159>=c){c=(c&
826
826
  function ls(a,b){for(var c=[],d=0;8>d;d++)1===(b&1)&&a.h[d]&&c.push(d),b>>=1;return c}function ms(a,b,c){var d=null;b=t(ls(a,b));for(var e=b.next();!e.done;e=b.next()){e=e.value;var f=a.h[e];f.isVisible()&&(d=Ur(f,c,a.i));a.h[e]=null}return d}function ns(a){a.g=null;a.h=[null,null,null,null,null,null,null,null]}function os(a,b,c){var d={0:0,1:0,2:1,3:1};a=d[a];b=d[b];c=d[c];return ps[a<<2|b<<1|c]}
827
827
  var qs=new Map([[32," "],[33,"\u00a0"],[37,"\u2026"],[42,"\u0160"],[44,"\u0152"],[48,"\u2588"],[49,"\u2018"],[50,"\u2019"],[51,"\u201c"],[52,"\u201d"],[53,"\u2022"],[57,"\u2122"],[58,"\u0161"],[60,"\u0153"],[61,"\u2120"],[63,"\u0178"],[118,"\u215b"],[119,"\u215c"],[120,"\u215d"],[121,"\u215e"],[122,"\u2502"],[123,"\u2510"],[124,"\u2514"],[125,"\u2500"],[126,"\u2518"],[127,"\u250c"]]),ps="black blue green cyan red magenta yellow white".split(" ");function rs(){this.h=[];this.g=[];this.i=new fs;this.l=0;this.m=new Map([["CC1",new Er(0,0)],["CC2",new Er(0,1)],["CC3",new Er(1,0)],["CC4",new Er(1,1)]]);this.u=this.o=0;this.j=new Map;this.F=!0;this.A=new Set;ss(this)}rs.prototype.clear=function(){this.l=0;this.h=[];this.g=[];var a=this.i;a.i=[];a.h=[];a.g=0;ss(this);a=t(this.j.values());for(var b=a.next();!b.done;b=a.next())ns(b.value)};
828
828
  function ss(a){a.o=0;a.u=0;for(var b=t(a.m.values()),c=b.next();!c.done;c=b.next())c=c.value,c.h=Fr,c.g=c.j,c.m=null,qr(c.i),qr(c.j),qr(c.o);a.F=!0}
829
- rs.prototype.extract=function(a,b){if(this.F){for(var c=t(this.m.values()),d=c.next();!d.done;d=c.next())d.value.l=b;this.F=!1}a=new Mg(a,0);if(!(8>a.getLength())&&181===a.X()&&49===a.wa()&&1195456820===a.T()&&3===a.X()&&(c=a.X(),0!==(c&64)))for(c&=31,a.skip(1),d=0;d<c;d++){var e=a.X(),f=(e&4)>>2,g=a.X(),h=a.X();f&&(e&=3,0===e||1===e?this.h.push({pts:b,type:e,vb:g,Ub:h,order:this.h.length}):(this.g.push({pts:b,type:e,value:g,order:this.g.length}),this.g.push({pts:b,type:2,value:h,order:this.g.length})))}};
829
+ rs.prototype.extract=function(a,b){if(this.F){for(var c=t(this.m.values()),d=c.next();!d.done;d=c.next())d.value.l=b;this.F=!1}a=new Mg(a,0);if(!(8>a.getLength())&&181===a.Y()&&49===a.wa()&&1195456820===a.T()&&3===a.Y()&&(c=a.Y(),0!==(c&64)))for(c&=31,a.skip(1),d=0;d<c;d++){var e=a.Y(),f=(e&4)>>2,g=a.Y(),h=a.Y();f&&(e&=3,0===e||1===e?this.h.push({pts:b,type:e,vb:g,Ub:h,order:this.h.length}):(this.g.push({pts:b,type:e,value:g,order:this.g.length}),this.g.push({pts:b,type:2,value:h,order:this.g.length})))}};
830
830
  rs.prototype.decode=function(){function a(e,f){return e.pts-f.pts||e.order-f.order}var b=[];this.h.sort(a);this.g.sort(a);for(var c=t(this.h),d=c.next();!d.done;d=c.next())(d=ts(this,d.value))&&b.push(d);c=t(this.g);for(d=c.next();!d.done;d=c.next())gs(this.i,d.value);c=t(this.i.i);for(d=c.next();!d.done;d=c.next())d=us(this,d.value),b.push.apply(b,x(d));this.i.i=[];this.h=[];this.g=[];return b};
831
831
  function ts(a,b){var c=b.type;if(16===(b.vb&112)){var d=b.vb>>3&1;0===c?a.o=d:a.u=d}d="CC"+((c<<1|(c?a.u:a.o))+1);c=a.m.get(d);if(255===b.vb&&255===b.Ub||!b.vb&&!b.Ub||!vs(b.vb)||!vs(b.Ub))return 45<=++a.l&&ss(a),null;a.l=0;b.vb&=127;b.Ub&=127;var e=b.vb;if(1<=e&&15>=e||!b.vb&&!b.Ub)return null;e=null;if(16===(b.vb&112))a:{a.A.add(d),d=b.vb;a=b.Ub;if(c.m===(d<<8|a))c.m=null;else if(c.m=d<<8|a,16===(d&240)&&64===(a&192)){b=[11,11,1,2,3,4,12,13,14,15,5,6,7,8,9,10][(d&7)<<1|a>>5&1];var f=(a&30)>>1;d=
832
832
  "white";e=!1;7>f?d=Nr[f]:7===f&&(e=!0);a=1===(a&1);c.h!==Ir&&(f=c.g,c.h===Hr&&b!==f.g&&(c=1+b-f.h,Dr(f,c,1+f.g-f.h,f.h),tr(f,0,c-1),tr(f,b+1,15-b)),f.g=b,f.m=a,f.j=e,f.l=d,f.o="black")}else if(17===(d&247)&&32===(a&240))c.g.m=!1,c.g.j=!1,c.g.l="white",ur(c.g,vr,32),d=!1,b=Nr[(a&14)>>1],"white_italics"===b&&(b="white",d=!0),c.g.m=1===(a&1),c.g.j=d,c.g.l=b;else if(16===(d&247)&&32===(a&240)||23===(d&247)&&45===(a&255))b="black",0===(d&7)&&(b=Mr[(a&14)>>1]),c.g.o=b;else if(17===(d&247)&&48===(a&240))ur(c.g,
@@ -840,7 +840,7 @@ xs.prototype.init=function(a){function b(f){f=f.name;f in zs&&(c.g=zs[f])}var c=
840
840
  function(f){f=aj(f.reader,f.version);e.push(f.timescale)}).box("minf",Ug).box("stbl",Ug).W("stsd",Wg).box("avc1",b).box("avc3",b).box("hev1",b).box("hvc1",b).box("dvav",b).box("dva1",b).box("dvh1",b).box("dvhe",b).box("encv",Xg).box("sinf",Ug).box("frma",function(f){f=dj(f.reader).cb;f in zs&&(c.g=zs[f])}).parse(a,!0);if(!d.length||!e.length||d.length!=e.length)throw new U(2,2,2010);this.g==ys&&Ya("Unable to determine bitstream format for CEA parsing!");d.forEach(function(f,g){c.j.set(f,e[g])})};
841
841
  xs.prototype.parse=function(a){var b=this;if(this.g==ys)return[];var c=[],d=0,e=[];(new Pg).box("moof",function(f){d=f.start;e=[];Ug(f)}).box("traf",function(f){e.push({baseMediaDecodeTime:null,Nd:b.h,Ge:b.i,Wh:[],timescale:9E4});Ug(f)}).W("trun",function(f){var g=e[e.length-1];f=bj(f.reader,f.version,f.flags);g.Wh.push(f)}).W("tfhd",function(f){var g=e[e.length-1];f=Zi(f.reader,f.flags);g.Nd=f.Nd||b.h;g.Ge=f.Ge||b.i;f=f.trackId;b.j.has(f)&&(g.timescale=b.j.get(f))}).W("tfdt",function(f){var g=e[e.length-
842
842
  1];f=$i(f.reader,f.version);g.baseMediaDecodeTime=f.baseMediaDecodeTime}).box("mdat",function(f){for(var g=d-f.start-8,h=f.reader.Ja(),k=t(e),l=k.next();!l.done;l=k.next()){l=l.value;if(null===l.baseMediaDecodeTime)throw Ya("Unable to find base media decode time for CEA captions!"),new U(2,2,2010);f.reader.seek(h);As(b,f.reader,l.baseMediaDecodeTime,l.timescale,l.Nd,l.Ge,g,l.Wh,c)}}).parse(a,!1);return c};
843
- function As(a,b,c,d,e,f,g,h,k){var l=0,m=f,n=h.map(function(u){return u.$h});n=[].concat.apply([],x(n));n.length&&(m=n[0].sampleSize||f);for(b.skip(g+h[0].Pi);b.Ca();){g=b.T();var p=b.X(),r=null;r=!1;h=1;switch(a.g){case Bs:r=p&31;r=6==r;break;case Cs:h=2;b.skip(1);r=p>>1&63;r=39==r||40==r;break;default:return}if(r)for(p=0,l<n.length&&(p=n[l].kf||0),p=(c+p)/d,h=t(ws(b.Hb(g-h))),r=h.next();!r.done;r=h.next())k.push({packet:r.value,pts:p});else try{b.skip(g-h)}catch(u){break}m-=g+4;0==m&&(c=l<n.length?
843
+ function As(a,b,c,d,e,f,g,h,k){var l=0,m=f,n=h.map(function(u){return u.$h});n=[].concat.apply([],x(n));n.length&&(m=n[0].sampleSize||f);for(b.skip(g+h[0].Pi);b.Ca();){g=b.T();var p=b.Y(),r=null;r=!1;h=1;switch(a.g){case Bs:r=p&31;r=6==r;break;case Cs:h=2;b.skip(1);r=p>>1&63;r=39==r||40==r;break;default:return}if(r)for(p=0,l<n.length&&(p=n[l].kf||0),p=(c+p)/d,h=t(ws(b.Hb(g-h))),r=h.next();!r.done;r=h.next())k.push({packet:r.value,pts:p});else try{b.skip(g-h)}catch(u){break}m-=g+4;0==m&&(c=l<n.length?
844
844
  c+(n[l].Sg||e):c+e,l++,l<n.length?m=n[l].sampleSize||f:m=f)}}P("shaka.cea.Mp4CeaParser",xs);var ys=0,Bs=1,Cs=2,zs={avc1:Bs,avc3:Bs,hev1:Cs,hvc1:Cs,dvav:Bs,dva1:Bs,dvh1:Cs,dvhe:Cs};Hd["video/mp4"]=function(){return new xs};function Ds(){this.g=null}Ds.prototype.init=function(){};Ds.prototype.parse=function(a){this.g?this.g.clearData():this.g=new vj;var b=[];a=Gb(a);if(!Cj(a))return b;a=this.g.parse(a);var c=a.Od(),d=a.Oe();a=[];switch(c.video){case "avc":a.push(6);break;case "hvc":a.push(39),a.push(40)}if(!a.length)return b;c=t(d);for(d=c.next();!d.done;d=c.next())if(d=d.value,a.includes(d.type)&&null!=d.time)for(var e=t(ws(d.data)),f=e.next();!f.done;f=e.next())b.push({packet:f.value,pts:d.time});return b};
845
845
  P("shaka.cea.TsCeaParser",Ds);Hd["video/mp2t"]=function(){return new Ds};function Es(a,b,c){var d=Fs(a),e=null;a=[];var f=[],g=null,h=new Set(d.map(function(l){return l.keyId}));h.delete(null);var k="cenc";if(1<h.size)throw new U(2,4,4010);if(!b){f=d.filter(function(l){return"urn:mpeg:dash:sea:2012"==l.nd});if(1<f.length)throw new U(2,4,4050);f.length&&(g=Gs(f[0]));(f=d.find(function(l){return"urn:mpeg:dash:mp4protection:2011"==l.nd}))&&f.encryptionScheme&&(k=f.encryptionScheme);f=d.filter(function(l){return"urn:mpeg:dash:mp4protection:2011"==l.nd?(e=l.init||e,!1):"urn:mpeg:dash:sea:2012"!=
846
846
  l.nd});f.length&&(a=Hs(e,k,f,c,h),0==a.length&&(a=[Mc("",k,e)]))}if(d.length&&!g&&(b||!f.length))for(a=[],b=t(Object.values(c)),c=b.next();!c.done;c=b.next())c=c.value,"org.w3.clearkey"!=c&&a.push(Mc(c,k,e));if(h=Array.from(h)[0]||null)for(k=t(a),b=k.next();!b.done;b=k.next())for(b=t(b.value.initData),c=b.next();!c.done;c=b.next())c.value.keyId=h;return{Ah:h,Nl:e,drmInfos:a,Rf:g,Eh:!0}}
@@ -860,46 +860,46 @@ p)break;else if(r>=p)break;v=Math.ceil((p-r)/u)-1}else{if(Infinity==a)break;else
860
860
  function Ss(a,b,c){b=Ts(a,b);a=null;b=t(b);for(var d=b.next();!d.done&&!(a=oh(d.value,c));d=b.next());return a}
861
861
  function Us(a,b,c,d,e,f){for(var g=uh(a,"http://www.w3.org/1999/xlink","href"),h=uh(a,"http://www.w3.org/1999/xlink","actuate")||"onRequest",k=t(Object.keys(a.attributes)),l=k.next();!l.done;l=k.next()){l=l.value;var m=l.split(":"),n=gh("http://www.w3.org/1999/xlink");m[0]==n&&delete a.attributes[l]}if(5<=f)return ng(new U(2,4,4028));if("onLoad"!=h)return ng(new U(2,4,4027));var p=Lc([d],[g]);return e.request(0,Ag(p,b)).Qa(function(r){r=bh(r.data,a.tagName);if(!r)return ng(new U(2,4,4001,g));for(a.children=
862
862
  [];r.children.length;){var u=r.children.shift();u.tagName&&(u.parent=a);a.children.push(u)}u=t(Object.keys(r.attributes));for(var v=u.next();!v.done;v=u.next())v=v.value,a.attributes[v]=r.attributes[v];return Vs(a,b,c,p[0],e,f+1)})}
863
- function Vs(a,b,c,d,e,f){f=void 0===f?0:f;if(uh(a,"http://www.w3.org/1999/xlink","href")){var g=Us(a,b,c,d,e,f);c&&(g=g.Qa(void 0,function(){return Vs(a,b,c,d,e,f)}));return g}g=[];for(var h={},k=t(jh(a)),l=k.next();!l.done;h={Rc:h.Rc},l=k.next())h.Rc=l.value,"urn:mpeg:dash:resolve-to-zero:2013"==uh(h.Rc,"http://www.w3.org/1999/xlink","href")?a.children=a.children.filter(function(m){return function(n){return n!==m.Rc}}(h)):"SegmentTimeline"!=h.Rc.tagName&&g.push(Vs(h.Rc,b,c,d,e,f));return rg(g).Qa(function(){return a})}
863
+ function Vs(a,b,c,d,e,f){f=void 0===f?0:f;if(uh(a,"http://www.w3.org/1999/xlink","href")){var g=Us(a,b,c,d,e,f);c&&(g=g.Qa(void 0,function(){return Vs(a,b,c,d,e,f)}));return g}g=[];for(var h={},k=t(jh(a)),l=k.next();!l.done;h={Sc:h.Sc},l=k.next())h.Sc=l.value,"urn:mpeg:dash:resolve-to-zero:2013"==uh(h.Sc,"http://www.w3.org/1999/xlink","href")?a.children=a.children.filter(function(m){return function(n){return n!==m.Sc}}(h)):"SegmentTimeline"!=h.Sc.tagName&&g.push(Vs(h.Sc,b,c,d,e,f));return rg(g).Qa(function(){return a})}
864
864
  ;function Ws(a,b,c,d,e,f,g){var h,k=(new Pg).W("sidx",function(l){h=Xs(b,d,e,f,g,c,l)});a&&k.parse(a);if(h)return h;throw new U(2,3,3004);}
865
865
  function Xs(a,b,c,d,e,f,g){var h=[];g.reader.skip(4);var k=g.reader.T();if(0==k)throw new U(2,3,3005);if(0==g.version){var l=g.reader.T();var m=g.reader.T()}else l=g.reader.md(),m=g.reader.md();g.reader.skip(2);var n=g.reader.wa();a=a+g.size+m;for(m=0;m<n;m++){var p=g.reader.T(),r=(p&2147483648)>>>31;p&=2147483647;var u=g.reader.T();g.reader.skip(4);if(1==r)throw new U(2,3,3006);h.push(new Ii(l/k+c,(l+u)/k+c,function(){return f},a,a+p-1,b,c,d,e));l+=u;a+=p}g.parser.stop();return h};function Ys(a){this.h=Lb(a);this.g=new Mg(this.h,0)}Ys.prototype.Ca=function(){return this.g.Ca()};
866
866
  function Zs(a){var b=$s(a);if(7<b.length)throw new U(2,3,3002);var c=0;b=t(b);for(var d=b.next();!d.done;d=b.next())c=256*c+d.value;b=$s(a);a:{d=t(at);for(var e=d.next();!e.done;e=d.next())if(Eb(b,new Uint8Array(e.value))){d=!0;break a}d=!1}if(d)b=a.h.byteLength-a.g.Ja();else{if(8==b.length&&b[1]&224)throw new U(2,3,3001);for(e=d=0;e<b.length;e++){var f=b[e];d=0==e?f&(1<<8-b.length)-1:256*d+f}b=d}b=a.g.Ja()+b<=a.h.byteLength?b:a.h.byteLength-a.g.Ja();d=Lb(a.h,a.g.Ja(),b);a.g.skip(b);return new bt(c,
867
- d)}function $s(a){var b=a.g.Ja(),c=a.g.X();if(0==c)throw new U(2,3,3002);c=8-Math.floor(Math.log2(c));a.g.skip(c-1);return Gb(a.h,b,c)}var at=[[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 bt(a,b){this.id=a;this.g=b}
867
+ d)}function $s(a){var b=a.g.Ja(),c=a.g.Y();if(0==c)throw new U(2,3,3002);c=8-Math.floor(Math.log2(c));a.g.skip(c-1);return Gb(a.h,b,c)}var at=[[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 bt(a,b){this.id=a;this.g=b}
868
868
  function ct(a){if(8<a.g.byteLength)throw new U(2,3,3002);if(8==a.g.byteLength&&a.g.getUint8(0)&224)throw new U(2,3,3001);for(var b=0,c=0;c<a.g.byteLength;c++){var d=a.g.getUint8(c);b=256*b+d}return b};function dt(a,b,c,d,e,f,g,h,k){function l(){return e}var m=[];a=new Ys(a.g);for(var n=null,p=null;a.Ca();){var r=Zs(a);if(187==r.id){var u=et(r);u&&(r=c*u.Fk,u=b+u.ck,null!=n&&m.push(new Ii(n+g,r+g,l,p,u-1,f,g,h,k)),n=r,p=u)}}null!=n&&m.push(new Ii(n+g,d+g,l,p,null,f,g,h,k));return m}
869
869
  function et(a){var b=new Ys(a.g);a=Zs(b);if(179!=a.id)throw new U(2,3,3013);a=ct(a);b=Zs(b);if(183!=b.id)throw new U(2,3,3012);b=new Ys(b.g);for(var c=0;b.Ca();){var d=Zs(b);if(241==d.id){c=ct(d);break}}return{Fk:a,ck:c}};function ft(a,b,c){b=Ss(a,b,"Initialization");if(!b)return null;var d=a.M.Va(),e=b.attributes.sourceURL;e&&(d=Lc(d,[Dc(e)]));e=0;var f=null;if(b=th(b,"range",yh))e=b.start,f=b.end;c=new Gi(function(){return d},e,f,gt(a),null,null,c);c.codecs=a.M.codecs;c.mimeType=a.M.mimeType;return c}
870
- function ht(a,b,c){var d=Number(Rs(a,it,"presentationTimeOffset"))||0,e=Rs(a,it,"timescale"),f=1;e&&(f=Ah(e)||1);var g=d/f||0,h=ft(a,it,c);jt(a,h);var k=Ye(a);return{wc:function(){var l=Ss(k,it,"RepresentationIndex");var m=k.M.Va();l&&(l=Dc(l.attributes.sourceURL))&&(m=Lc(m,[l]));l=kt(k);return lt(k,b,h,m,l.start,l.end,g)}}}
870
+ function ht(a,b,c){var d=Number(Rs(a,it,"presentationTimeOffset"))||0,e=Rs(a,it,"timescale"),f=1;e&&(f=Ah(e)||1);var g=d/f||0,h=ft(a,it,c);jt(a,h);var k=Ye(a);return{yc:function(){var l=Ss(k,it,"RepresentationIndex");var m=k.M.Va();l&&(l=Dc(l.attributes.sourceURL))&&(m=Lc(m,[l]));l=kt(k);return lt(k,b,h,m,l.start,l.end,g)}}}
871
871
  function lt(a,b,c,d,e,f,g){var h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G;return O(function(J){if(1==J.g)return h=a.presentationTimeline,k=!a.Lb||!a.va.Zd,l=a.va.start,m=a.va.duration,n=a.M.mimeType.split("/")[1],p=b,r=null,u=[p(d,e,f,!1),"webm"==n?p(c.P(),c.Wa,c.Da,!0):null],p=null,E(J,Promise.all(u),2);v=J.h;w=v[0];A=v[1]||null;z=null;C=l-g;y=l;B=m?l+m:Infinity;if("mp4"==n)var I=Ws(w,e,d,c,C,y,B);else{I=new Ys(A);if(440786851!=Zs(I).id)throw new U(2,3,3008);var H=Zs(I);if(408125543!=H.id)throw new U(2,
872
872
  3,3009);I=H.g.byteOffset;H=new Ys(H.g);for(var N=null;H.Ca();){var L=Zs(H);if(357149030==L.id){N=L;break}}if(!N)throw new U(2,3,3010);N=new Ys(N.g);L=1E6;for(H=null;N.Ca();){var M=Zs(N);if(2807729==M.id)L=ct(M);else if(17545==M.id)if(4==M.g.byteLength)H=M.g.getFloat32(0);else if(8==M.g.byteLength)H=M.g.getFloat64(0);else throw new U(2,3,3003);}if(null==H)throw new U(2,3,3011);N=L/1E9;H*=N;L=Zs(new Ys(w));if(475249515!=L.id)throw new U(2,3,3007);I=dt(L,I,N,H,d,c,C,y,B)}z=I;D=t(z);for(K=D.next();!K.done;K=
873
- D.next())G=K.value,G.codecs=a.M.codecs,G.mimeType=a.M.mimeType;h.ce(z);r=new Xk(z);k&&r.Wc(y,B,!0);return J.return(r)})}function it(a){return a.od}function kt(a){var b=Ss(a,it,"RepresentationIndex");a=Rs(a,it,"indexRange");a=yh(a||"");b&&(a=th(b,"range",yh,a));return a}function jt(a,b){mt(a,b);if(!kt(a))throw new U(2,4,4002);}function mt(a,b){var c=a.M.mimeType.split("/")[1];if(a.M.contentType!=Sc&&"mp4"!=c&&"webm"!=c)throw new U(2,4,4006);if("webm"==c&&!b)throw new U(2,4,4005);}
874
- function gt(a){var b=a.M;return{bandwidth:a.bandwidth,audioSamplingRate:b.audioSamplingRate,codecs:b.codecs,contentType:b.contentType,frameRate:b.frameRate||null,height:b.height||null,mimeType:b.mimeType,channelsCount:b.jd,pixelAspectRatio:b.pixelAspectRatio||null,width:b.width||null}};function nt(a,b,c){var d=ft(a,ot,c),e=pt(a);if(!e.bb&&!e.timeline&&1<e.gd.length)throw new U(2,4,4002);if(!e.bb&&!a.va.duration&&!e.timeline&&1==e.gd.length)throw new U(2,4,4002);if(e.timeline&&0==e.timeline.length)throw new U(2,4,4002);var f=null,g=null;a.La.id&&a.M.id&&(g=b[a.La.id+","+a.M.id])&&(f=g.segmentIndex);var h=qt(a.va.start,a.va.duration,a.M.Va,e,d,c,a.M.mimeType,a.M.codecs);b=!f;f?f.ae(h,a.presentationTimeline.Cb()):f=new Xk(h);a.presentationTimeline.ce(h);a.Lb&&a.va.Zd||f.Wc(a.va.start,
875
- a.va.duration?a.va.start+a.va.duration:Infinity,b);g&&(g.segmentIndex=f);return{wc:function(){f&&0!=f.getNumReferences()||f.Xe(h);return Promise.resolve(f)}}}function ot(a){return a.bc}function pt(a){var b=rt(a);a=Qs(a,ot);var c=a.le;0==c&&(c=1);var d=0;a.bb?d=a.bb*(c-1):a.timeline&&0<a.timeline.length&&(d=a.timeline[0].start);return{bb:a.bb,startTime:d,le:c,ac:a.ac,timeline:a.timeline,gd:b}}
876
- function qt(a,b,c,d,e,f,g,h){var k=d.gd.length;d.timeline&&d.timeline.length!=d.gd.length&&(k=Math.min(d.timeline.length,d.gd.length));for(var l=a-d.ac,m=b?a+b:Infinity,n=[],p=d.startTime,r={},u=0;u<k;r={Hd:r.Hd,Cd:r.Cd},u++){r.Cd=d.gd[u];var v=p;p=void 0;p=null!=d.bb?v+d.bb:d.timeline?d.timeline[u].end:v+b;r.Hd=null;v=new Ii(a+v,a+p,function(w){return function(){null==w.Hd&&(w.Hd=Lc(c(),[w.Cd.Tj]));return w.Hd}}(r),r.Cd.start,r.Cd.end,e,l,a,m,[],"",null,null,Ji,f);v.codecs=h;v.mimeType=g;n.push(v)}return n}
877
- function rt(a){return[a.M.bc,a.Ia.bc,a.La.bc].filter(We).map(function(b){return kh(b,"SegmentURL")}).reduce(function(b,c){return 0<b.length?b:c}).map(function(b){b.attributes.indexRange&&!a.Ag&&(a.Ag=!0);var c=Dc(b.attributes.media);b=th(b,"mediaRange",yh,{start:0,end:null});return{Tj:c,start:b.start,end:b.end}})};function st(a,b,c,d,e,f,g,h,k){k||a.M.cd||(a.M.cd=Rs(a,tt,"initialization"));var l=a.M.cd?ut(a,g):null,m=vt(a);wt(m);var n=Ye(a);if(m.Vd)return mt(a,l),{wc:function(){var w=Ps(m.Vd,n.M.id,null,null,n.bandwidth||null,null);w=Lc(n.M.Va(),[w]);return lt(n,b,l,w,0,null,m.ac)}};if(m.bb)return d||"image"===a.Ia.contentType||(a.presentationTimeline.Jg(m.bb),a.presentationTimeline.$e(a.va.start)),{wc:function(){return xt(n,m,e,l,f,g,h)}};var p=null;d=d=null;a.La.id&&a.M.id&&(d=a.La.id+","+a.M.id,d=c[d])&&
878
- (p=d.segmentIndex);var r=a.va.start,u=a.va.duration?r+a.va.duration:Infinity,v=!(a.Lb&&a.va.Zd);p?(c=p,yt(c,m,r,u,v,l),c.eb(a.presentationTimeline.Cb())):p=new zt(m,a.M.id,a.bandwidth,a.M.Va,r,u,l,v,g,a.M.Tg);m.timeline&&"image"!==a.Ia.contentType&&a.presentationTimeline.Vh(m.timeline,r);d&&a.Lb&&(d.segmentIndex=p);return{wc:function(){p instanceof zt&&0==p.getNumReferences()&&yt(p,m,r,u,v,l);return Promise.resolve(p)}}}function tt(a){return a.mc}
879
- function vt(a){var b=Qs(a,tt),c=Rs(a,tt,"media"),d=Rs(a,tt,"index");return{bb:b.bb,timescale:b.timescale,le:b.le,ac:b.ac,jh:b.jh,timeline:b.timeline,hd:c&&Dc(c),Vd:d,mimeType:a.M.mimeType,codecs:a.M.codecs}}function wt(a){var b=a.Vd?1:0;b+=a.timeline?1:0;b+=a.bb?1:0;if(0==b)throw new U(2,4,4002);1!=b&&(a.Vd&&(a.timeline=null),a.bb=null);if(!a.Vd&&!a.hd)throw new U(2,4,4002);}
880
- function xt(a,b,c,d,e,f,g){function h(H){var N=(H-v)*u,L=N+b.ac,M=N+n;N=M+u;var Q=Math.min(N,l());M=new Ii(M,Q,function(){var T=L*w;"BigInt"in window&&T>Number.MAX_SAFE_INTEGER&&(T=BigInt(L)*BigInt(w));T=Ps(A,C,H,null,z,T);return Lc(y(),[T])},0,null,d,B,n,l(),[],"",null,null,Ji,f);M.codecs=a.M.codecs;M.mimeType=a.M.mimeType;M.i=N;return M}function k(){var H=[Math.max(m.Cb(),n),Math.min(m.ic(),l())].map(function(N){return N-n});H=[Math.ceil(H[0]/u),Math.ceil(H[1]/u)-1];a.M.Ya&&H[1]++;return H.map(function(N){return N+
881
- v})}function l(){var H=null!=p&&e[p]||r;return H?n+H:Infinity}var m=a.presentationTimeline,n=a.va.start,p=a.La.id,r=a.va.duration,u=b.bb,v=b.le,w=b.timescale,A=b.hd,z=a.bandwidth||null,C=a.M.id,y=a.M.Va,B=n-b.ac,D=k();c=a.Lb?Math.max(D[0],D[1]-c+1):D[0];g=g||D[1];D=[];for(var K=c;K<=g;++K){var G=h(K);D.push(G)}var J=new Xk(D);D=m.ic()<l();K=m.U();if(D||K){var I=Math.max(c,g+1);c=u;a.M.Ya&&(c=.1);J.tf(c,function(){var H=m.Cb();J.eb(H);var N=t(k());N.next();N=N.next().value;for(var L=[];I<=N;){var M=
882
- h(I);L.push(M);I++}return H>l()&&!L.length?null:L})}return Promise.resolve(J)}function ut(a,b){var c=a.M.cd;c||(c=Rs(a,tt,"initialization"));if(!c)return null;c=Dc(c);var d=a.M.id,e=a.bandwidth||null,f=a.M.Va;b=new Gi(function(){var g=Ps(c,d,null,null,e,null);return Lc(f(),[g])},0,null,gt(a),null,null,b);b.codecs=a.M.codecs;b.mimeType=a.M.mimeType;return b}
873
+ D.next())G=K.value,G.codecs=a.M.codecs,G.mimeType=a.M.mimeType;h.ce(z);r=new Xk(z);k&&r.Xc(y,B,!0);return J.return(r)})}function it(a){return a.od}function kt(a){var b=Ss(a,it,"RepresentationIndex");a=Rs(a,it,"indexRange");a=yh(a||"");b&&(a=th(b,"range",yh,a));return a}function jt(a,b){mt(a,b);if(!kt(a))throw new U(2,4,4002);}function mt(a,b){var c=a.M.mimeType.split("/")[1];if(a.M.contentType!=Sc&&"mp4"!=c&&"webm"!=c)throw new U(2,4,4006);if("webm"==c&&!b)throw new U(2,4,4005);}
874
+ function gt(a){var b=a.M;return{bandwidth:a.bandwidth,audioSamplingRate:b.audioSamplingRate,codecs:b.codecs,contentType:b.contentType,frameRate:b.frameRate||null,height:b.height||null,mimeType:b.mimeType,channelsCount:b.jd,pixelAspectRatio:b.pixelAspectRatio||null,width:b.width||null}};function nt(a,b,c){var d=ft(a,ot,c),e=pt(a);if(!e.bb&&!e.timeline&&1<e.hd.length)throw new U(2,4,4002);if(!e.bb&&!a.va.duration&&!e.timeline&&1==e.hd.length)throw new U(2,4,4002);if(e.timeline&&0==e.timeline.length)throw new U(2,4,4002);var f=null,g=null;a.La.id&&a.M.id&&(g=b[a.La.id+","+a.M.id])&&(f=g.segmentIndex);var h=qt(a.va.start,a.va.duration,a.M.Va,e,d,c,a.M.mimeType,a.M.codecs);b=!f;f?f.ae(h,a.presentationTimeline.Cb()):f=new Xk(h);a.presentationTimeline.ce(h);a.Lb&&a.va.Zd||f.Xc(a.va.start,
875
+ a.va.duration?a.va.start+a.va.duration:Infinity,b);g&&(g.segmentIndex=f);return{yc:function(){f&&0!=f.getNumReferences()||f.Xe(h);return Promise.resolve(f)}}}function ot(a){return a.bc}function pt(a){var b=rt(a);a=Qs(a,ot);var c=a.le;0==c&&(c=1);var d=0;a.bb?d=a.bb*(c-1):a.timeline&&0<a.timeline.length&&(d=a.timeline[0].start);return{bb:a.bb,startTime:d,le:c,ac:a.ac,timeline:a.timeline,hd:b}}
876
+ function qt(a,b,c,d,e,f,g,h){var k=d.hd.length;d.timeline&&d.timeline.length!=d.hd.length&&(k=Math.min(d.timeline.length,d.hd.length));for(var l=a-d.ac,m=b?a+b:Infinity,n=[],p=d.startTime,r={},u=0;u<k;r={Ed:r.Ed,Cd:r.Cd},u++){r.Cd=d.hd[u];var v=p;p=void 0;p=null!=d.bb?v+d.bb:d.timeline?d.timeline[u].end:v+b;r.Ed=null;v=new Ii(a+v,a+p,function(w){return function(){null==w.Ed&&(w.Ed=Lc(c(),[w.Cd.Tj]));return w.Ed}}(r),r.Cd.start,r.Cd.end,e,l,a,m,[],"",null,null,Ji,f);v.codecs=h;v.mimeType=g;n.push(v)}return n}
877
+ function rt(a){return[a.M.bc,a.Ia.bc,a.La.bc].filter(We).map(function(b){return kh(b,"SegmentURL")}).reduce(function(b,c){return 0<b.length?b:c}).map(function(b){b.attributes.indexRange&&!a.Ag&&(a.Ag=!0);var c=Dc(b.attributes.media);b=th(b,"mediaRange",yh,{start:0,end:null});return{Tj:c,start:b.start,end:b.end}})};function st(a,b,c,d,e,f,g,h,k){k||a.M.dd||(a.M.dd=Rs(a,tt,"initialization"));var l=a.M.dd?ut(a,g):null,m=vt(a);wt(m);var n=Ye(a);if(m.Vd)return mt(a,l),{yc:function(){var w=Ps(m.Vd,n.M.id,null,null,n.bandwidth||null,null);w=Lc(n.M.Va(),[w]);return lt(n,b,l,w,0,null,m.ac)}};if(m.bb)return d||"image"===a.Ia.contentType||(a.presentationTimeline.Jg(m.bb),a.presentationTimeline.$e(a.va.start)),{yc:function(){return xt(n,m,e,l,f,g,h)}};var p=null;d=d=null;a.La.id&&a.M.id&&(d=a.La.id+","+a.M.id,d=c[d])&&
878
+ (p=d.segmentIndex);var r=a.va.start,u=a.va.duration?r+a.va.duration:Infinity,v=!(a.Lb&&a.va.Zd);p?(c=p,yt(c,m,r,u,v,l),c.eb(a.presentationTimeline.Cb())):p=new zt(m,a.M.id,a.bandwidth,a.M.Va,r,u,l,v,g,a.M.Tg);m.timeline&&"image"!==a.Ia.contentType&&a.presentationTimeline.Vh(m.timeline,r);d&&a.Lb&&(d.segmentIndex=p);return{yc:function(){p instanceof zt&&0==p.getNumReferences()&&yt(p,m,r,u,v,l);return Promise.resolve(p)}}}function tt(a){return a.pc}
879
+ function vt(a){var b=Qs(a,tt),c=Rs(a,tt,"media"),d=Rs(a,tt,"index");return{bb:b.bb,timescale:b.timescale,le:b.le,ac:b.ac,jh:b.jh,timeline:b.timeline,nc:c&&Dc(c),Vd:d,mimeType:a.M.mimeType,codecs:a.M.codecs}}function wt(a){var b=a.Vd?1:0;b+=a.timeline?1:0;b+=a.bb?1:0;if(0==b)throw new U(2,4,4002);1!=b&&(a.Vd&&(a.timeline=null),a.bb=null);if(!a.Vd&&!a.nc)throw new U(2,4,4002);}
880
+ function xt(a,b,c,d,e,f,g){function h(H){var N=(H-v)*u,L=N+b.ac,M=N+n;N=M+u;var Q=Math.min(N,l());M=new Ii(M,Q,function(){var T=L*w;"BigInt"in window&&T>Number.MAX_SAFE_INTEGER&&(T=BigInt(L)*BigInt(w));T=Ps(A,C,H,null,z,T);return Lc(y(),[T])},0,null,d,B,n,l(),[],"",null,null,Ji,f);M.codecs=a.M.codecs;M.mimeType=a.M.mimeType;M.i=N;return M}function k(){var H=[Math.max(m.Cb(),n),Math.min(m.jc(),l())].map(function(N){return N-n});H=[Math.ceil(H[0]/u),Math.ceil(H[1]/u)-1];a.M.Ya&&H[1]++;return H.map(function(N){return N+
881
+ v})}function l(){var H=null!=p&&e[p]||r;return H?n+H:Infinity}var m=a.presentationTimeline,n=a.va.start,p=a.La.id,r=a.va.duration,u=b.bb,v=b.le,w=b.timescale,A=b.nc,z=a.bandwidth||null,C=a.M.id,y=a.M.Va,B=n-b.ac,D=k();c=a.Lb?Math.max(D[0],D[1]-c+1):D[0];g=g||D[1];D=[];for(var K=c;K<=g;++K){var G=h(K);D.push(G)}var J=new Xk(D);D=m.jc()<l();K=m.U();if(D||K){var I=Math.max(c,g+1);c=u;a.M.Ya&&(c=.1);J.tf(c,function(){var H=m.Cb();J.eb(H);var N=t(k());N.next();N=N.next().value;for(var L=[];I<=N;){var M=
882
+ h(I);L.push(M);I++}return H>l()&&!L.length?null:L})}return Promise.resolve(J)}function ut(a,b){var c=a.M.dd;c||(c=Rs(a,tt,"initialization"));if(!c)return null;c=Dc(c);var d=a.M.id,e=a.bandwidth||null,f=a.M.Va;b=new Gi(function(){var g=Ps(c,d,null,null,e,null);return Lc(f(),[g])},0,null,gt(a),null,null,b);b.codecs=a.M.codecs;b.mimeType=a.M.mimeType;return b}
883
883
  function zt(a,b,c,d,e,f,g,h,k,l){Xk.call(this,[]);this.h=a;this.H=b;this.F=c;this.G=d;this.i=e;this.l=f;this.u=g;this.A=k;this.I=l;h&&At(this)}na(zt,Xk);q=zt.prototype;q.getNumReferences=function(){return this.h?this.h.timeline.length:0};q.release=function(){Xk.prototype.release.call(this);this.h=null};
884
884
  q.eb=function(a){if(this.h){for(var b=0,c=this.h.timeline,d=0;d<c.length;d+=1)if(c[d].end+this.i<=a)b+=1;else break;0<b&&(this.h.timeline=c.slice(b),this.g.length>=b&&(this.g=this.g.slice(b)),this.j+=b,0===this.getNumReferences()&&this.release())}};
885
- function yt(a,b,c,d,e,f){Bt(a,f);if(a.h){c=a.h.timeline;a.h.hd=b.hd;if(c.length){var g=c[c.length-1];b=b.timeline.filter(function(h){return h.start>=g.end})}else b=b.timeline.slice();0<b.length&&a.h.timeline.push.apply(a.h.timeline,x(b));a.l!==d&&(a.l=d)}else a.h=b,a.i=c,a.l=d;e&&At(a)}function Bt(a,b){if(a.u!==b){a.u=b;a=t(a.g);for(var c=a.next();!c.done;c=a.next())(c=c.value)&&Li(c,b)}}
885
+ function yt(a,b,c,d,e,f){Bt(a,f);if(a.h){c=a.h.timeline;a.h.nc!==b.nc&&(a.h.nc=b.nc);if(c.length){var g=c[c.length-1];b=b.timeline.filter(function(h){return h.start>=g.end})}else b=b.timeline.slice();0<b.length&&a.h.timeline.push.apply(a.h.timeline,x(b));a.l!==d&&(a.l=d)}else a.h=b,a.i=c,a.l=d;e&&At(a)}function Bt(a,b){if(a.u!==b){a.u=b;a=t(a.g);for(var c=a.next();!c.done;c=a.next())(c=c.value)&&Li(c,b)}}
886
886
  function At(a){if(!a.o){for(var b=a.h.timeline;b.length;)if(b[b.length-1].start>=a.l)b.pop();else break;a.eb(a.i)}}q.find=function(a){if(this.h&&this.h.timeline&&this.h.timeline.length&&a<this.h.timeline[0].start+this.i)return this.j;if(!this.h)return null;var b=this.h.timeline;if(a<this.i||a>=this.l)return null;for(var c=b.length-1,d=0;d<b.length;d++){var e=b[d],f=e.start+this.i;e=d<c?b[d+1].start+this.i:Infinity===this.l?e.end+this.i:this.l;if(a>=f&&a<e)return d+this.j}return null};
887
- q.get=function(a){var b=this;a-=this.j;if(0>a||a>=this.getNumReferences()||!this.h)return null;var c=this.g[a];if(!c){var d=this.h.hd,e=this.h.timeline[a],f=e.pk,g=this.h.jh+e.kh;c=this.i-this.h.ac;var h=this.i+e.end,k=h;a===this.getNumReferences()-1&&Infinity!==this.l&&(k=this.l);for(var l=this.h.codecs,m=this.h.mimeType,n=[],p=(e.end-e.start)/e.Rb,r={},u=0;u<e.Rb;r={Ed:r.Ed,Hf:r.Hf},u++){var v=e.start+p*u,w=v+p;r.Hf=u+1;r.Ed=null;v=new Ii(this.i+v,this.i+w,function(A){return function(){if(!b.h)return[];
888
- null==A.Ed&&(A.Ed=Ct(b.h.hd,b.H,f,b.F,g,A.Hf,b.G));return A.Ed}}(r),0,null,this.u,c,this.i,this.l,[],"",null,null,Ji,this.A);v.codecs=l;v.mimeType=m;0==this.I?0<u&&v.Ve():0!=u%this.I&&v.Ve();n.push(v)}c=new Ii(this.i+e.start,k,function(){return 0<e.Rb?[]:Ct(d,b.H,f,b.F,g,null,b.G)},0,null,this.u,c,this.i,this.l,n,"",null,null,Ji,this.A,0<e.Rb);c.codecs=l;c.mimeType=m;c.i=h;this.g[a]=c}return c};
887
+ q.get=function(a){var b=this;a-=this.j;if(0>a||a>=this.getNumReferences()||!this.h)return null;var c=this.g[a];if(!c){var d=this.h.timeline[a],e=d.pk,f=this.h.jh+d.kh;c=this.i-this.h.ac;var g=this.i+d.end,h=g;a===this.getNumReferences()-1&&Infinity!==this.l&&(h=this.l);for(var k=this.h.codecs,l=this.h.mimeType,m=[],n=(d.end-d.start)/d.Rb,p={},r=0;r<d.Rb;p={Fd:p.Fd,Hf:p.Hf},r++){var u=d.start+n*r,v=u+n;p.Hf=r+1;p.Fd=null;u=new Ii(this.i+u,this.i+v,function(w){return function(){if(!b.h)return[];null==
888
+ w.Fd&&(w.Fd=Ct(b.h.nc,b.H,e,b.F,f,w.Hf,b.G));return w.Fd}}(p),0,null,this.u,c,this.i,this.l,[],"",null,null,Ji,this.A);u.codecs=k;u.mimeType=l;0==this.I?0<r&&u.Ve():0!=r%this.I&&u.Ve();m.push(u)}c=new Ii(this.i+d.start,h,function(){return 0<d.Rb||!b.h?[]:Ct(b.h.nc,b.H,e,b.F,f,null,b.G)},0,null,this.u,c,this.i,this.l,m,"",null,null,Ji,this.A,0<d.Rb);c.codecs=k;c.mimeType=l;c.i=g;this.g[a]=c}return c};
889
889
  function Ct(a,b,c,d,e,f,g){a=Ps(a,b,c,f,d||null,e);return Lc(g(),[a]).map(function(h){return h.toString()})};function Dt(a){var b=Je(a),c=b.split("/")[0];a=Ke(a);return{type:c,mimeType:b,codecs:a,language:null,height:null,width:null,channelCount:null,sampleRate:null,closedCaptions:new Map,oe:null,colorGamut:null}}
890
890
  function Et(a,b){function c(y){w=y.name;var B=y.reader;B.skip(24);var D=B.wa(),K=B.wa();B.skip(50);n=String(D);m=String(K);y.reader.Ca()&&Ug(y)}function d(y){var B=cj(y.reader);p=B.channelCount;r=B.sampleRate;e(y.name)}function e(y){y=y.toLowerCase();switch(y){case "avc1":case "avc3":g.push(y+".42E01E");k=!0;break;case "hev1":case "hvc1":g.push(y+".1.6.L93.90");k=!0;break;case "dvh1":case "dvhe":g.push(y+".05.04");k=!0;break;case "vp09":g.push(y+".00.10.08");k=!0;break;case "av01":g.push(y+".0.01M.08");
891
891
  k=!0;break;case "mp4a":f.push("mp4a.40.2");h=!0;break;case "ac-3":case "ec-3":case "ac-4":case "opus":case "flac":f.push(y),h=!0}}var f=[],g=[],h=!1,k=!1,l=null,m=null,n=null,p=null,r=null,u=null,v=null,w;(new Pg).box("moov",Ug).box("trak",Ug).box("mdia",Ug).W("mdhd",function(y){l=aj(y.reader,y.version).language}).box("minf",Ug).box("stbl",Ug).W("stsd",Wg).box("mp4a",function(y){var B=cj(y.reader);p=B.channelCount;r=B.sampleRate;y.reader.Ca()?Ug(y):e(y.name)}).box("esds",function(y){y=y.reader;for(var B=
892
- "mp4a",D,K;y.Ca();){D=y.X();for(var G=y.X();G&128;)G=y.X();if(3==D)y.wa(),G=y.X(),G&128&&y.wa(),G&64&&y.skip(y.X()),G&32&&y.wa();else if(4==D)K=y.X(),y.skip(12);else if(5==D)break}K&&(B+="."+fj(K),5==D&&y.Ca()&&(D=y.X(),K=(D&248)>>3,31===K&&y.Ca()&&(K=32+((D&7)<<3)+((y.X()&224)>>5)),B+="."+K));f.push(B);h=!0}).box("ac-3",d).box("ec-3",d).box("ac-4",d).box("Opus",d).box("fLaC",d).box("avc1",c).box("avc3",c).box("hev1",c).box("hvc1",c).box("dva1",c).box("dvav",c).box("dvh1",c).box("dvhe",c).box("vp09",
893
- c).box("av01",c).box("avcC",function(y){var B=w||"";switch(w){case "dvav":B="avc3";break;case "dva1":B="avc1"}y=y.reader;y.skip(1);y=B+"."+fj(y.X())+fj(y.X())+fj(y.X());g.push(y);k=!0}).box("hvcC",function(y){var B=w||"";switch(w){case "dvh1":B="hvc1";break;case "dvhe":B="hev1"}var D=y.reader;D.skip(1);y=D.X();var K=["","A","B","C"][y>>6],G=y&31,J=D.T(),I=(y&32)>>5?"H":"L";y=[D.X(),D.X(),D.X(),D.X(),D.X(),D.X()];D=D.X();for(var H=0,N=0;32>N;N++){H|=J&1;if(31==N)break;H<<=1;J>>=1}B=B+("."+K+G)+("."+
894
- fj(H,!0));B+="."+I+D;K="";for(G=y.length;G--;)if((I=y[G])||K)K="."+I.toString(16).toUpperCase()+K;B+=K;g.push(B);k=!0}).box("dvcC",function(y){var B=w||"";switch(w){case "hvc1":B="dvh1";break;case "hev1":B="dvhe";break;case "avc1":B="dva1";break;case "avc3":B="dvav"}var D=y.reader;D.skip(2);y=D.X();D=D.X();g.push(B+"."+gj(y>>1&127)+"."+gj(y<<5&32|D>>3&31));k=!0}).W("vpcC",function(y){var B=w||"",D=y.reader;y=D.X();var K=D.X();D=D.X()>>4&15;g.push(B+"."+gj(y)+"."+gj(K)+"."+gj(D));k=!0}).box("av1C",
895
- function(y){var B=w||"",D=y.reader;D.skip(1);y=D.X();D=D.X();var K=y>>>5,G=(D&64)>>6;g.push(B+"."+K+"."+gj(y&31)+(D>>>7?"H":"M")+"."+gj(2===K&&G?(D&32)>>5?12:10:G?10:8)+"."+((D&16)>>4)+"."+((D&8)>>3)+((D&4)>>2)+(D&3)+"."+gj(1)+"."+gj(1)+"."+gj(1)+".0");k=!0}).box("enca",Yg).box("encv",Xg).box("sinf",Ug).box("frma",function(y){y=dj(y.reader).cb;e(y)}).box("colr",function(y){g=g.map(function(K){if(K.startsWith("av01.")){var G=y.reader,J=G.Ja(),I=G.Hb(4);var H=String.fromCharCode(I[0]);H+=String.fromCharCode(I[1]);
896
- H+=String.fromCharCode(I[2]);H+=String.fromCharCode(I[3]);if("nclx"===H){I=G.wa();H=G.wa();var N=G.wa(),L=G.X()>>7,M=K.split(".");10==M.length&&(M[6]=gj(I),M[7]=gj(H),M[8]=gj(N),M[9]=String(L),K=M.join("."))}G.seek(J)}return K});var B=ej(y.reader),D=B.colorGamut;u=B.oe;v=D}).parse(a||b,!0);if(!f.length&&!g.length)return null;var A=h&&!k,z=new Map;if(k){var C=new Ed("video/mp4");a&&C.init(a);C.i(b);a=t(C.j());for(b=a.next();!b.done;b=a.next())b=b.value,z.set(b,b);C.g()}return{type:A?"audio":"video",
892
+ "mp4a",D,K;y.Ca();){D=y.Y();for(var G=y.Y();G&128;)G=y.Y();if(3==D)y.wa(),G=y.Y(),G&128&&y.wa(),G&64&&y.skip(y.Y()),G&32&&y.wa();else if(4==D)K=y.Y(),y.skip(12);else if(5==D)break}K&&(B+="."+fj(K),5==D&&y.Ca()&&(D=y.Y(),K=(D&248)>>3,31===K&&y.Ca()&&(K=32+((D&7)<<3)+((y.Y()&224)>>5)),B+="."+K));f.push(B);h=!0}).box("ac-3",d).box("ec-3",d).box("ac-4",d).box("Opus",d).box("fLaC",d).box("avc1",c).box("avc3",c).box("hev1",c).box("hvc1",c).box("dva1",c).box("dvav",c).box("dvh1",c).box("dvhe",c).box("vp09",
893
+ c).box("av01",c).box("avcC",function(y){var B=w||"";switch(w){case "dvav":B="avc3";break;case "dva1":B="avc1"}y=y.reader;y.skip(1);y=B+"."+fj(y.Y())+fj(y.Y())+fj(y.Y());g.push(y);k=!0}).box("hvcC",function(y){var B=w||"";switch(w){case "dvh1":B="hvc1";break;case "dvhe":B="hev1"}var D=y.reader;D.skip(1);y=D.Y();var K=["","A","B","C"][y>>6],G=y&31,J=D.T(),I=(y&32)>>5?"H":"L";y=[D.Y(),D.Y(),D.Y(),D.Y(),D.Y(),D.Y()];D=D.Y();for(var H=0,N=0;32>N;N++){H|=J&1;if(31==N)break;H<<=1;J>>=1}B=B+("."+K+G)+("."+
894
+ fj(H,!0));B+="."+I+D;K="";for(G=y.length;G--;)if((I=y[G])||K)K="."+I.toString(16).toUpperCase()+K;B+=K;g.push(B);k=!0}).box("dvcC",function(y){var B=w||"";switch(w){case "hvc1":B="dvh1";break;case "hev1":B="dvhe";break;case "avc1":B="dva1";break;case "avc3":B="dvav"}var D=y.reader;D.skip(2);y=D.Y();D=D.Y();g.push(B+"."+gj(y>>1&127)+"."+gj(y<<5&32|D>>3&31));k=!0}).W("vpcC",function(y){var B=w||"",D=y.reader;y=D.Y();var K=D.Y();D=D.Y()>>4&15;g.push(B+"."+gj(y)+"."+gj(K)+"."+gj(D));k=!0}).box("av1C",
895
+ function(y){var B=w||"",D=y.reader;D.skip(1);y=D.Y();D=D.Y();var K=y>>>5,G=(D&64)>>6;g.push(B+"."+K+"."+gj(y&31)+(D>>>7?"H":"M")+"."+gj(2===K&&G?(D&32)>>5?12:10:G?10:8)+"."+((D&16)>>4)+"."+((D&8)>>3)+((D&4)>>2)+(D&3)+"."+gj(1)+"."+gj(1)+"."+gj(1)+".0");k=!0}).box("enca",Yg).box("encv",Xg).box("sinf",Ug).box("frma",function(y){y=dj(y.reader).cb;e(y)}).box("colr",function(y){g=g.map(function(K){if(K.startsWith("av01.")){var G=y.reader,J=G.Ja(),I=G.Hb(4);var H=String.fromCharCode(I[0]);H+=String.fromCharCode(I[1]);
896
+ H+=String.fromCharCode(I[2]);H+=String.fromCharCode(I[3]);if("nclx"===H){I=G.wa();H=G.wa();var N=G.wa(),L=G.Y()>>7,M=K.split(".");10==M.length&&(M[6]=gj(I),M[7]=gj(H),M[8]=gj(N),M[9]=String(L),K=M.join("."))}G.seek(J)}return K});var B=ej(y.reader),D=B.colorGamut;u=B.oe;v=D}).parse(a||b,!0);if(!f.length&&!g.length)return null;var A=h&&!k,z=new Map;if(k){var C=new Ed("video/mp4");a&&C.init(a);C.i(b);a=t(C.j());for(b=a.next();!b.done;b=a.next())b=b.value,z.set(b,b);C.g()}return{type:A?"audio":"video",
897
897
  mimeType:A?"audio/mp4":"video/mp4",codecs:Ft(f.concat(g)).join(", "),language:l,height:m,width:n,channelCount:p,sampleRate:r,closedCaptions:z,oe:u,colorGamut:v}}function Ft(a){var b=new Set,c=[];a=t(a);for(var d=a.next();!d.done;d=a.next()){d=d.value;var e=Ie(d);b.has(e)||(c.push(d),b.add(e))}b=Tc("audio",c);d=Tc("video",c);a=Tc(Sc,c);d=Gt(d);b=b.concat(d).concat(a);return c.length&&!b.length?c:b}
898
- function Gt(a){if(1>=a.length)return a;var b=a.find(function(c){return c.startsWith("dvh1.")||c.startsWith("dvhe.")||c.startsWith("dav1.")});return b?td('video/mp4; codecs="'+b+'"')?[b]:a.filter(function(c){return c!=b}):a}function Ht(a){var b=null;(new Pg).box("moov",Ug).box("trak",Ug).box("mdia",Ug).box("minf",Ug).box("stbl",Ug).W("stsd",Wg).box("encv",Xg).box("enca",Yg).box("sinf",Ug).box("schi",Ug).W("tenc",function(c){c=c.reader;c.X();c.X();c.X();c.X();b=Jc(c.Hb(16))}).parse(a,!0);return b};function It(a){this.o=null;this.A=a;this.I=new tg;this.i=[];this.h=null;this.m=[];this.F=null;this.H=[];this.G=300;this.l=new Map;this.j=new Map;this.g=null;this.u="UNKNOWN"}It.prototype.configure=function(a){this.o=a};It.prototype.destroy=function(){this.A=this.o=null;this.i=[];this.h=null;this.m=[];this.H=[];this.l.clear();null!=this.g&&(this.g.stop(),this.g=null);return this.I.destroy()};It.prototype.setManifestType=function(a){this.u=a};
898
+ function Gt(a){if(1>=a.length)return a;var b=a.find(function(c){return c.startsWith("dvh1.")||c.startsWith("dvhe.")||c.startsWith("dav1.")});return b?td('video/mp4; codecs="'+b+'"')?[b]:a.filter(function(c){return c!=b}):a}function Ht(a){var b=null;(new Pg).box("moov",Ug).box("trak",Ug).box("mdia",Ug).box("minf",Ug).box("stbl",Ug).W("stsd",Wg).box("encv",Xg).box("enca",Yg).box("sinf",Ug).box("schi",Ug).W("tenc",function(c){c=c.reader;c.Y();c.Y();c.Y();c.Y();b=Jc(c.Hb(16))}).parse(a,!0);return b};function It(a){this.o=null;this.A=a;this.I=new tg;this.i=[];this.h=null;this.m=[];this.F=null;this.H=[];this.G=300;this.l=new Map;this.j=new Map;this.g=null;this.u="UNKNOWN"}It.prototype.configure=function(a){this.o=a};It.prototype.destroy=function(){this.A=this.o=null;this.i=[];this.h=null;this.m=[];this.H=[];this.l.clear();null!=this.g&&(this.g.stop(),this.g=null);return this.I.destroy()};It.prototype.setManifestType=function(a){this.u=a};
899
899
  function Jt(a,b){var c,d,e,f,g,h,k;return O(function(l){if(1==l.g)return c=Lc(a.i,[Kt(a,b)]),d=Ag(c,a.o.retryParameters),e=a.A.networkingEngine.request(8,d),ug(a.I,e),ta(l,2),E(l,e.promise,4);if(2!=l.g)return f=l.h,g=wc(f.data),h=JSON.parse(g),1==h.VERSION&&Lt(a,h,f.uri),va(l,0);if((k=wa(l))&&7001==k.code)return l.return();null!=a.g&&(a.g.stop(),a.g=null);a.g=new Ub(function(){Jt(a,b)});a.g.V(a.G);F(l)})}
900
900
  function Kt(a,b){if(!a.m.length)return b;b=new mb(b);var c=a.F||a.m[0],d=Math.round(a.A.getBandwidthEstimate()),e=b.g;"DASH"==a.u?(e.add("_DASH_pathway",c),e.add("_DASH_throughput",String(d))):"HLS"==a.u&&(e.add("_HLS_pathway",c),e.add("_HLS_throughput",String(d)));Cb(e)&&qb(b,e);return b.toString()}function Lt(a,b,c){null!=a.g&&(a.g.stop(),a.g=null);var d=b["RELOAD-URI"]||c;a.g=new Ub(function(){Jt(a,d)});if(c=b.TTL)a.G=c;a.g.V(a.G);a.m=b["PATHWAY-PRIORITY"]||[];a.H=b["PATHWAY-CLONES"]||[]}
901
901
  function Mt(a,b,c,d){var e=a.l.get(b);e||(e=new Map);e.set(c,d);a.l.set(b,e)}It.prototype.banLocation=function(a){this.j.set(a,Date.now()+6E4)};
902
- function Nt(a,b,c){c=void 0===c?!1:c;b=a.l.get(b)||new Map;for(var d=[],e={},f=t(a.m),g=f.next();!g.done;e={sc:e.sc},g=f.next())if(e.sc=g.value,g=b.get(e.sc))d.push({Pg:e.sc,location:g});else if(g=a.H.find(function(k){return function(l){return l.Xk==k.sc}}(e))){var h=b.get(g["BASE-ID"]);h&&(g["URI-REPLACEMENT"].Ai?(h=new mb(h),ob(h,g["URI-REPLACEMENT"].Ai),d.push({Pg:e.sc,location:h.toString()})):d.push({Pg:e.sc,location:h}))}e=Date.now();f=t(a.j.keys());for(g=f.next();!g.done;g=f.next())g=g.value,
902
+ function Nt(a,b,c){c=void 0===c?!1:c;b=a.l.get(b)||new Map;for(var d=[],e={},f=t(a.m),g=f.next();!g.done;e={uc:e.uc},g=f.next())if(e.uc=g.value,g=b.get(e.uc))d.push({Pg:e.uc,location:g});else if(g=a.H.find(function(k){return function(l){return l.Xk==k.uc}}(e))){var h=b.get(g["BASE-ID"]);h&&(g["URI-REPLACEMENT"].Ai?(h=new mb(h),ob(h,g["URI-REPLACEMENT"].Ai),d.push({Pg:e.uc,location:h.toString()})):d.push({Pg:e.uc,location:h}))}e=Date.now();f=t(a.j.keys());for(g=f.next();!g.done;g=f.next())g=g.value,
903
903
  h=a.j.get(g),e>h&&a.j.delete(g);d=d.filter(function(k){for(var l=t(a.j.keys()),m=l.next();!m.done;m=l.next())if(m.value.includes((new mb(k.location)).Vb))return!1;return!0});d.length&&(a.F=d[0].Pg);d=d.map(function(k){return k.location});if(!d.length&&a.h)for(e=t(a.h.split(",")),g=e.next();!g.done;g=e.next())if(f=b.get(g.value))a.F=a.h,d.push(f);if(!d.length)for(b=t(b.values()),e=b.next();!e.done;e=b.next())d.push(e.value);return c?d:Lc(a.i,d)};function Ot(){this.j=[];this.h=[];this.g=[];this.l=[];this.i=[];this.u=this.o=!1;this.m=new Set}q=Ot.prototype;q.release=function(){for(var a=t(this.h.concat(this.g,this.l,this.i)),b=a.next();!b.done;b=a.next())b=b.value,b.segmentIndex&&b.segmentIndex.release();this.h=[];this.g=[];this.l=[];this.i=[];this.j=[]};q.xj=function(){return this.j};q.ug=function(){return this.l.slice()};q.bj=function(){return this.i};
904
904
  function Pt(a,b){var c=[],d=[],e=[],f=[];a=t(a);for(var g=a.next();!g.done;g=a.next()){var h=g.value;g=new Map(h.audioStreams.map(function(n){return[Qt(n),n]}));var k=new Map(h.videoStreams.map(function(n){return[Rt(n),n]})),l=new Map(h.textStreams.map(function(n){return[St(n),n]}));h=new Map(h.imageStreams.map(function(n){return[Tt(n),n]}));if(b){var m=Ut(Sc);l.set(St(m),m);m=Ut("image");h.set(Tt(m),m)}c.push(g);d.push(k);e.push(l);f.push(h)}return{rh:c,wi:d,oi:e,Mh:f}}
905
905
  q.Xf=function(a,b,c){c=void 0===c?!1:c;var d=this,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q,T,R;return O(function(ra){if(1==ra.g){e=Uc;if(!b&&1==a.length)return f=Pt(a,!1),g=f.rh,h=f.wi,k=f.oi,l=f.Mh,d.h=Array.from(g[0].values()),d.g=Array.from(h[0].values()),d.l=Array.from(k[0].values()),d.i=Array.from(l[0].values()),ra.B(2);m=c?d.m.size:0;n=-1;for(p=0;p<a.length;p++)r=a[p],d.m.has(r.id)||(d.m.add(r.id),-1==n&&(n=p));if(-1==n)return ra.return();u=Pt(a,!0);v=u.rh;w=u.wi;A=u.oi;z=u.Mh;
@@ -920,7 +920,7 @@ d;a.encrypted=a.encrypted||b.encrypted;if(b.closedCaptions)for(a.closedCaptions|
920
920
  b)}function au(a,b){var c=a.roles;c||(c=[]);for(var d=t(b.roles),e=d.next();!e.done;e=d.next())e=e.value,c.includes(e)||c.push(e);a.roles=c;c=t(b.keyIds);for(d=c.next();!d.done;d=c.next())a.keyIds.add(d.value);a.encrypted=a.encrypted&&b.encrypted;a.segments.push.apply(a.segments,x(b.segments));if(b.closedCaptions)for(a.closedCaptions||(a.closedCaptions=new Map),b=t(b.closedCaptions),c=b.next();!c.done;c=b.next())d=t(c.value),c=d.next().value,d=d.next().value,a.closedCaptions.set(c,d)}
921
921
  function fu(a,b,c,d){d=(void 0===d?0:d)?c.matchedStreams:[];b=t(b);for(var e=b.next();!e.done;e=b.next()){e=iu(a,e.value,c);if(!e)return;d.push(e)}c.matchedStreams=d}
922
922
  function iu(a,b,c){var d={audio:Qt,video:Rt,text:St,image:Tt}[c.type],e=null,f=d(c);if(b.has(f))e=b.get(f);else{f={audio:function(l,m){return eu(a,l,m)},video:function(l,m){return eu(a,l,m)},text:ju,image:ku}[c.type];for(var g={audio:lu,video:mu,text:nu,image:ou}[c.type],h=t(b.values()),k=h.next();!k.done;k=h.next())k=k.value,!f(c,k)||c.fastSwitching!=k.fastSwitching||e&&!g(c,e,k)||(e=k)}a.u&&!du(e)&&b.delete(d(e));return e}
923
- function pu(a,b){function c(d){if(!qu.has(d)){var e=Ge(d);qu.set(d,e)}return qu.get(d)}return a.mimeType!=b.mimeType?!1:c(a.codecs)==c(b.codecs)}q.ai=function(a){this.o=a};q.ki=function(a){this.u=a};function eu(a,b,c){return!pu(b,c)&&!a.o||b.drmInfos&&!Ob(b.drmInfos,c.drmInfos)?!1:!0}function ju(a,b){return b.language?a.forced!==b.forced||0==ed(a.language,b.language)||b.kind!=a.kind?!1:!0:!0}function ku(){return!0}
923
+ function pu(a,b){return a.mimeType!=b.mimeType?!1:qu(a.codecs)===qu(b.codecs)}q.ai=function(a){this.o=a};q.ki=function(a){this.u=a};function eu(a,b,c){return!pu(b,c)&&!a.o||b.drmInfos&&!Ob(b.drmInfos,c.drmInfos)?!1:!0}function ju(a,b){return b.language?a.forced!==b.forced||0==ed(a.language,b.language)||b.kind!=a.kind?!1:!0:!0}function ku(){return!0}
924
924
  function lu(a,b,c){var d=pu(a,b),e=pu(a,c);if(d&&!e)return!1;if(!d&&e)return!0;d=ed(a.language,b.language);e=ed(a.language,c.language);if(e>d)return!0;if(e<d)return!1;if(b.label!==c.label){if(a.label===b.label)return!1;if(a.label===c.label)return!0}if(a.roles.length)return d=b.roles.filter(function(f){return a.roles.includes(f)}),e=c.roles.filter(function(f){return a.roles.includes(f)}),e.length>d.length?!0:e.length<d.length?!1:c.roles.length<b.roles.length;if(!c.roles.length&&b.roles.length)return!0;
925
925
  if(c.roles.length&&!b.roles.length)return!1;if(!b.primary&&c.primary)return!0;if(b.primary&&!c.primary)return!1;d=ru(a.channelsCount,b.channelsCount,c.channelsCount);if(d==su)return!0;if(d==tu)return!1;d=ru(a.audioSamplingRate,b.audioSamplingRate,c.audioSamplingRate);return d==su?!0:d==tu?!1:a.bandwidth&&uu(a.bandwidth,b.bandwidth,c.bandwidth)==su?!0:!1}
926
926
  function mu(a,b,c){var d=pu(a,b),e=pu(a,c);if(d&&!e)return!1;if(!d&&e)return!0;d=ru(a.width*a.height,b.width*b.height,c.width*c.height);if(d==su)return!0;if(d==tu)return!1;if(a.frameRate){d=ru(a.frameRate,b.frameRate,c.frameRate);if(d==su)return!0;if(d==tu)return!1}return a.bandwidth&&uu(a.bandwidth,b.bandwidth,c.bandwidth)==su?!0:!1}
@@ -929,476 +929,477 @@ if(c.roles.length&&!b.roles.length)return!1}return c.mimeType!=a.mimeType||c.cod
929
929
  function Zt(a){return{id:0,originalId:"",groupId:null,primary:!1,type:a,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}}
930
930
  function Ut(a){return{id:0,originalId:"",groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Xk([]),mimeType:"",codecs:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"",originalLanguage:null,label:null,type:a,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}}
931
931
  function ru(a,b,c){if(b==a&&a!=c)return tu;if(c==a&&a!=b)return su;if(b>a){if(c<=a||c-a<b-a)return su;if(c-a>b-a)return tu}else{if(c>a)return tu;if(a-c<a-b)return su;if(a-c>a-b)return tu}return vu}function uu(a,b,c){b=Math.abs(a-b);a=Math.abs(a-c);return a<b?su:b<a?tu:vu}function du(a){switch(a.type){case Sc:return!a.language;case "image":return!a.tilesLayout;default:return!1}}
932
- function Rt(a){return JSON.stringify([a.fastSwitching,a.width,a.frameRate,a.codecs,a.mimeType,a.label,a.roles,a.closedCaptions?Array.from(a.closedCaptions.entries()):null,a.bandwidth])}function Qt(a){return JSON.stringify([a.fastSwitching,a.channelsCount,a.language,a.bandwidth,a.label,a.codecs,a.mimeType,a.roles,a.audioSamplingRate,a.primary])}function St(a){return JSON.stringify([a.language,a.label,a.codecs,a.mimeType,a.bandwidth,a.roles])}
933
- function Tt(a){return JSON.stringify([a.width,a.codecs,a.mimeType])}P("shaka.util.PeriodCombiner",Ot);Ot.prototype.setUseStreamOnce=Ot.prototype.ki;Ot.prototype.setAllowMultiTypeVariants=Ot.prototype.ai;Ot.prototype.combinePeriods=Ot.prototype.Xf;Ot.prototype.getImageStreams=Ot.prototype.bj;Ot.prototype.getTextStreams=Ot.prototype.ug;Ot.prototype.getVariants=Ot.prototype.xj;var su=1,vu=0,tu=-1,qu=new Map;function wu(a,b){var c=new DOMParser,d=xu.value()(a);a=null;try{a=c.parseFromString(d,"text/xml")}catch(e){return null}c=a.documentElement;if(!c||c.getElementsByTagName("parsererror").length||c.tagName!=b)return null;if(!("createNodeIterator"in document))return c;for(b=document.createNodeIterator(a,NodeFilter.SHOW_ALL);a=b.nextNode();)if(a instanceof HTMLElement||a instanceof SVGElement)return null;return c}function yu(a,b){try{var c=zc(a);return wu(c,b)}catch(d){return null}}
934
- var xu=new Nb(function(){if("undefined"!==typeof trustedTypes){var a=trustedTypes.createPolicy("shaka-player#xml",{createHTML:function(b){return b}});return function(b){return a.createHTML(b)}}return function(b){return b}});function zu(){var a=this;this.i=this.g=null;this.A=[];this.l=null;this.R=1;this.F=[];this.j={Ze:"",type:"",profiles:[],Yb:null,Ya:0,Va:null,ge:0};this.o=new Map;this.u={};this.N={};this.m=new Ot;this.H=0;this.O=new ld(5);this.I=new Ub(function(){Au(a)});this.L=new tg;this.J=null;this.S=[];this.K=Infinity;this.G=!1;this.h=null}q=zu.prototype;
935
- q.configure=function(a){var b=this.i&&a.dash.updatePeriod!=this.g.dash.updatePeriod&&0<=a.dash.updatePeriod;this.g=a;b&&this.l&&this.l.presentationTimeline.U()&&this.I.Pa();this.h&&this.h.configure(this.g);this.m&&(this.m.ai(this.g.dash.multiTypeVariantsAllowed&&vd()),this.m.ki(this.g.dash.useStreamOnceInPeriodFlattening))};q.start=function(a,b){var c=this,d;return O(function(e){if(1==e.g)return c.G=b.isLowLatencyMode(),c.A=[a],c.i=b,E(e,Bu(c),2);d=e.h;c.i&&Cu(c,d);if(!c.i)throw new U(2,7,7001);return e.return(c.l)})};
936
- q.stop=function(){for(var a=t(Object.values(this.u)),b=a.next();!b.done;b=a.next())b=b.value,b.segmentIndex&&b.segmentIndex.release();this.m&&this.m.release();this.g=this.i=null;this.A=[];this.l=null;this.u={};this.o.clear();this.j={Ze:"",type:"",profiles:[],Yb:null,Ya:0,Va:null,ge:0};this.m=null;null!=this.I&&(this.I.stop(),this.I=null);this.h&&this.h.destroy();return this.L.destroy()};
937
- q.update=function(){var a=this,b;return O(function(c){if(1==c.g)return ta(c,2),E(c,Bu(a),4);if(2!=c.g)return va(c,0);b=wa(c);if(!a.i||!b)return c.return();a.i.onError(b);F(c)})};q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(a){if(this.l&&this.l.presentationTimeline.U()){var b=a.video||a.audio;if(b&&b.segmentIndex){a=this.l.presentationTimeline.ic();var c=b.segmentIndex.find(a);null!=c&&(b=b.segmentIndex.get(c))&&(this.H=b.endTime-a,Cu(this,0))}}};
932
+ function Rt(a){return JSON.stringify([a.fastSwitching,a.width,a.frameRate,qu(a.codecs),a.mimeType,a.label,a.roles,a.closedCaptions?Array.from(a.closedCaptions.entries()):null,a.bandwidth])}function Qt(a){return JSON.stringify([a.fastSwitching,a.channelsCount,a.language,a.bandwidth,a.label,qu(a.codecs),a.mimeType,a.roles,a.audioSamplingRate,a.primary])}function St(a){return JSON.stringify([a.language,a.label,a.codecs,a.mimeType,a.bandwidth,a.roles])}
933
+ function Tt(a){return JSON.stringify([a.width,a.codecs,a.mimeType])}function qu(a){if(!wu.has(a)){var b=Ge(a);wu.set(a,b)}return wu.get(a)}P("shaka.util.PeriodCombiner",Ot);Ot.prototype.setUseStreamOnce=Ot.prototype.ki;Ot.prototype.setAllowMultiTypeVariants=Ot.prototype.ai;Ot.prototype.combinePeriods=Ot.prototype.Xf;Ot.prototype.getImageStreams=Ot.prototype.bj;Ot.prototype.getTextStreams=Ot.prototype.ug;Ot.prototype.getVariants=Ot.prototype.xj;var su=1,vu=0,tu=-1,wu=new Map;function xu(a,b){var c=new DOMParser,d=yu.value()(a);a=null;try{a=c.parseFromString(d,"text/xml")}catch(e){return null}c=a.documentElement;if(!c||c.getElementsByTagName("parsererror").length||c.tagName!=b)return null;if(!("createNodeIterator"in document))return c;for(b=document.createNodeIterator(a,NodeFilter.SHOW_ALL);a=b.nextNode();)if(a instanceof HTMLElement||a instanceof SVGElement)return null;return c}function zu(a,b){try{var c=zc(a);return xu(c,b)}catch(d){return null}}
934
+ var yu=new Nb(function(){if("undefined"!==typeof trustedTypes){var a=trustedTypes.createPolicy("shaka-player#xml",{createHTML:function(b){return b}});return function(b){return a.createHTML(b)}}return function(b){return b}});function Au(){var a=this;this.j=this.g=null;this.A=[];this.i=null;this.S=1;this.F=[];this.l={Ze:"",type:"",profiles:[],Yb:null,Ya:0,Va:null,ge:0};this.o=new Map;this.u={};this.O={};this.m=new Ot;this.H=0;this.R=new ld(5);this.I=new Ub(function(){Bu(a)});this.L=new tg;this.J=null;this.X=[];this.K=Infinity;this.G=!1;this.h=null;this.N=!1}q=Au.prototype;
935
+ q.configure=function(a){var b=this.j&&a.dash.updatePeriod!=this.g.dash.updatePeriod&&0<=a.dash.updatePeriod;this.g=a;b&&this.i&&this.i.presentationTimeline.U()&&this.I.Pa();this.h&&this.h.configure(this.g);this.m&&(this.m.ai(this.g.dash.multiTypeVariantsAllowed&&vd()),this.m.ki(this.g.dash.useStreamOnceInPeriodFlattening))};q.start=function(a,b){var c=this,d;return O(function(e){if(1==e.g)return c.G=b.isLowLatencyMode(),c.A=[a],c.j=b,E(e,Cu(c),2);d=e.h;c.j&&Du(c,d);if(!c.j)throw new U(2,7,7001);return e.return(c.i)})};
936
+ q.stop=function(){for(var a=t(Object.values(this.u)),b=a.next();!b.done;b=a.next())b=b.value,b.segmentIndex&&b.segmentIndex.release();this.m&&this.m.release();this.g=this.j=null;this.A=[];this.i=null;this.u={};this.o.clear();this.l={Ze:"",type:"",profiles:[],Yb:null,Ya:0,Va:null,ge:0};this.m=null;null!=this.I&&(this.I.stop(),this.I=null);this.h&&this.h.destroy();return this.L.destroy()};
937
+ q.update=function(){var a=this,b;return O(function(c){if(1==c.g)return ta(c,2),E(c,Cu(a),4);if(2!=c.g)return va(c,0);b=wa(c);if(!a.j||!b)return c.return();a.j.onError(b);F(c)})};q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(a){if(this.i&&this.i.presentationTimeline.U()){var b=a.video||a.audio;if(b&&b.segmentIndex){a=this.i.presentationTimeline.jc();var c=b.segmentIndex.find(a);null!=c&&(b=b.segmentIndex.get(c))&&(this.H=b.endTime-a,Du(this,0))}}};
938
938
  q.banLocation=function(a){this.h&&this.h.banLocation(a)};
939
- function Bu(a){var b,c,d,e,f,g,h,k,l;return O(function(m){if(1==m.g)return b="MPD",c=Du(a),d=a.A,c.length?(d=c,b="Patch"):1<a.A.length&&a.h&&(e=Nt(a.h,"Location",!0),e.length&&(d=e)),f=Ag(d,a.g.retryParameters),g=Date.now(),E(m,Eu(a,f,0,{type:4}),2);if(3!=m.g){h=m.h;if(!a.i)return m.return(0);h.uri&&h.uri!=h.originalUri&&!a.A.includes(h.uri)&&a.A.unshift(h.uri);return E(m,Fu(a,h.data,h.uri,b),3)}k=Date.now();l=(k-g)/1E3;a.O.sample(1,l);return m.return(l)})}
940
- function Fu(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u;return O(function(v){if(1==v.g){e=b;f=a.g.dash.manifestPreprocessor;g=wm;if(f!=g){xd("manifest.dash.manifestPreprocessor configuration","Please Use manifest.dash.manifestPreprocessorTXml instead.");h=yu(e,d);if(!h)throw new U(2,4,4001,c);f(h);e=Ac(h.outerHTML)}k=bh(e,d);if(!k)throw new U(2,4,4001,c);l=a.g.dash.manifestPreprocessorTXml;m=xm;l!=m&&l(k);if("Patch"===d)return v.return(Gu(a,k));if(n=a.g.dash.disableXlinkProcessing)return v.return(Hu(a,k,c));
941
- p=a.g.dash.xlinkFailGracefully;r=Vs(k,a.g.retryParameters,p,c,a.i.networkingEngine);ug(a.L,r);return E(v,r.promise,2)}u=v.h;return v.return(Hu(a,u,c))})}
942
- function Hu(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q,T,R,ra,sa,Ca,Ea,Ia,Pa,Ja,db,Fa,$a,xb,ad,ye,Fd,Rc,ze,Ae,Be,Gd,oj,dh,pj,qj,eh,Ce;return O(function(rc){switch(rc.g){case 1:a.h&&a.h.l.clear();d=[c];e=[];f=new Map;g=kh(b,"Location");h=t(g);for(k=h.next();!k.done;k=h.next())if(l=k.value,m=l.attributes.serviceLocation,n=mh(l))p=Lc(d,[n])[0],m&&(a.h?Mt(a.h,"Location",m,p):f.set(m,p)),e.push(p);a.h?(r=Nt(a.h,"Location",!0),0<r.length&&(d=a.A=r)):e.length&&(d=a.A=e);a.j.Ze=
943
- b.attributes.id||"";a.j.ge=th(b,"publishTime",wh)||0;a.F=kh(b,"PatchLocation");u=Promise.resolve();if((v=oh(b,"ContentSteering"))&&a.i){w=v.attributes.defaultServiceLocation;if(a.h)a.h.i=d,a.h.h=w;else if(a.h=new It(a.i),a.h.configure(a.g),a.h.setManifestType("DASH"),a.h.i=d,a.h.h=w,A=mh(v))(z=th(v,"queryBeforeStart",Dh,!1))?u=Jt(a.h,A):Jt(a.h,A);C=t(f.keys());for(y=C.next();!y.done;y=C.next())B=y.value,D=f.get(B),Mt(a.h,"Location",B,D)}K=kh(b,"BaseURL");J=!1;if(a.h)for(I=t(K),H=I.next();!H.done;H=
944
- I.next())N=H.value,L=N.attributes.serviceLocation,M=mh(N),L&&M&&(Mt(a.h,"BaseURL",L,M),J=!0);J&&a.h||(Q=K.map(mh),G=Lc(d,Q));T=function(){return a.h&&J?Nt(a.h,"BaseURL"):G?G:[]};a.j.Va=T;R=0;K&&K.length&&(R=th(K[0],"availabilityTimeOffset",Ch)||0);a.j.Ya=R;ra=a.g.dash.ignoreMinBufferTime;sa=0;ra||(sa=th(b,"minBufferTime",xh)||0);a.H=th(b,"minimumUpdatePeriod",xh,-1);Ca=th(b,"availabilityStartTime",wh);Ea=th(b,"timeShiftBufferDepth",xh);Ia=a.g.dash.ignoreSuggestedPresentationDelay;Pa=null;Ia||(Pa=
945
- th(b,"suggestedPresentationDelay",xh));Ja=a.g.dash.ignoreMaxSegmentDuration;db=null;Ja||(db=th(b,"maxSegmentDuration",xh));Fa=b.attributes.type||"static";a.j.type=Fa;if(a.l)for($a=a.l.presentationTimeline,xb=t(Object.values(a.u)),ad=xb.next();!ad.done;ad=xb.next())ye=ad.value,ye.segmentIndex&&ye.segmentIndex.eb($a.Cb());else Fd=a.g.defaultPresentationDelay||1.5*sa,Rc=null!=Pa?Pa:Fd,$a=new Bk(Ca,Rc,a.g.dash.autoCorrectDrift);$a.Lc("static"==Fa);(ze=$a.U())&&!isNaN(a.g.availabilityWindowOverride)&&
946
- (Ea=a.g.availabilityWindowOverride);null==Ea&&(Ea=Infinity);$a.nf(Ea);Ae=b.attributes.profiles||"";a.j.profiles=Ae.split(",");Be={Lb:"static"!=Fa,presentationTimeline:$a,La:null,va:null,Ia:null,M:null,bandwidth:0,Ag:!1,Ya:R,Yb:null,profiles:Ae.split(",")};Gd=Iu(a,Be,T,b);oj=Gd.duration;dh=Gd.periods;"static"!=Fa&&Gd.Ch||$a.sb(oj||Infinity);a.K&&!a.G&&(pj=a.i.isAutoLowLatencyMode())&&(a.i.enableLowLatencyMode(),a.G=a.i.isLowLatencyMode());a.G?$a.bi(a.K):a.K&&Ya("Low-latency DASH 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.");
947
- $a.Jg(db||1);return E(rc,u,2);case 2:return a.G&&(sa=0,qj=null!=Pa?Pa:a.g.defaultPresentationDelay,$a.Xg(qj)),a.l?E(rc,Ju(a,Gd.periods,!1),4):E(rc,a.m.Xf(dh,Be.Lb),6);case 6:a.l={presentationTimeline:$a,variants:a.m.j,textStreams:a.m.ug(),imageStreams:a.m.i,offlineSessionIds:[],minBufferTime:sa||0,sequenceMode:a.g.dash.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,type:"DASH",serviceDescription:Ku(b),nextUrl:Lu(b)};if(!$a.si()){rc.B(7);break}eh=kh(b,"UTCTiming");return E(rc,Mu(a,T,eh),8);
948
- case 8:Ce=rc.h;if(!a.i)return rc.return();$a.ci(Ce);case 7:$a.Ue();case 4:a.i.makeTextStreamsForClosedCaptions(a.l),F(rc)}})}function Ju(a,b,c){var d;return O(function(e){if(1==e.g)return E(e,a.m.Xf(b,!0,c),2);a.l.variants=a.m.j;d=a.m.ug();0<d.length&&(a.l.textStreams=d);a.l.imageStreams=a.m.i;a.i.filter(a.l);F(e)})}
949
- function Gu(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I;return O(function(H){if(1==H.g){c=b.attributes.mpdId;d=th(b,"originalPublishTime",wh);if(!c||c!==a.j.Ze||d!==a.j.ge)throw a.F=[],new U(1,4,4052);e=[];f=[];g=new Set;h=t(jh(b));for(k=h.next();!k.done;k=h.next())if(l=k.value,m=Fh(l.attributes.sel||""),n=m[m.length-1],p=mh(l)||"","MPD"===n.name)if("mediaPresentationDuration"===n.ec){r=mh(l)||"";var N=xh(r);if(null!=N){a.j.Yb=N;for(var L=t(a.o.values()),M=L.next();!M.done;M=L.next())M.value.Yb=
950
- N}}else if("type"===n.ec){a.l.presentationTimeline.Lc("static"==p);a.j.type=p;N=t(a.o.values());for(L=N.next();!L.done;L=N.next())L.value.Lb="dynamic"==p;"static"==p&&(a.H=-1)}else"publishTime"===n.ec?a.j.ge=wh(p)||0:null===n.ec&&"add"===l.tagName&&f.push(l);else if("PatchLocation"===n.name)Gh(a.F,l);else if("Period"===n.name)if("add"===l.tagName)f.push(l);else{if("remove"===l.tagName&&n.id)for(N=n.id,L=t(a.o.keys()),M=L.next();!M.done;M=L.next())if(M=M.value,M.startsWith(N)){var Q=a.o.get(M);Ss(Q,
951
- tt,"SegmentTimeline").children=[];Nu(a,M);a.o.delete(M)}}else if("SegmentTemplate"===n.name){L=Fh(l.attributes.sel||"");N=L[L.length-1];if(N.ec){L=Ou(a,L);M=mh(l)||"";Q=t(L);for(var T=Q.next();!T.done;T=Q.next())T=a.o.get(T.value),Hh(T.M.mc,l.tagName,N.ec,M);N=L}else N=[];u=N;v=t(u);for(w=v.next();!w.done;w=v.next())A=w.value,g.add(A)}else if("SegmentTimeline"===n.name||"S"===n.name){N=Fh(l.attributes.sel||"");N=Ou(a,N);L=t(N);for(M=L.next();!M.done;M=L.next())M=a.o.get(M.value),M=Ss(M,tt,"SegmentTimeline"),
952
- Q=kh(M,"S"),Gh(Q,l),M.children=Q;z=N;C=t(z);for(w=C.next();!w.done;w=C.next())y=w.value,g.add(y)}B=t(g);for(w=B.next();!w.done;w=B.next())D=w.value,Nu(a,D);K=t(f);for(G=K.next();!G.done;G=K.next())J=G.value,e.push.apply(e,x(Iu(a,{Lb:"dynamic"==a.j.type,presentationTimeline:a.l.presentationTimeline,La:null,va:null,Ia:null,M:null,bandwidth:0,Ag:!1,Ya:a.j.Ya,profiles:a.j.profiles,Yb:a.j.Yb},a.j.Va,J).periods));return e.length?E(H,Ju(a,e,!0),2):H.B(2)}"static"==a.j.type&&(I=a.j.Yb,a.l.presentationTimeline.sb(I||
953
- Infinity));F(H)})}function Ou(a,b){var c="",d="",e="";b=t(b);for(var f=b.next();!f.done;f=b.next())f=f.value,"Period"===f.name?c=f.id:"AdaptationSet"===f.name?d=f.id:"Representation"===f.name&&(e=f.id);b=[];if(e)b.push(c+","+e);else for(a=t(a.o.values()),e=a.next();!e.done;e=a.next())e=e.value,e.La.id===c&&e.Ia.id===d&&e.M.id&&b.push(c+","+e.M.id);return b}
954
- function Nu(a,b){var c=a.o.get(b),d=a.u[b];d.segmentIndex&&d.segmentIndex.eb(a.l.presentationTimeline.Cb());try{var e=st(c,function(f,g,h,k){return Pu(a,f,g,h,k)},a.u,!0,a.g.dash.initialSegmentLimit,a.N,c.M.aesKey,null,!0);d.createSegmentIndex=function(){var f;return O(function(g){if(1==g.g){if(d.segmentIndex)return g.B(0);f=d;return E(g,e.wc(),3)}f.segmentIndex=g.h;F(g)})}}catch(f){if(b=c.M.contentType,b!=Sc&&"application"!=b&&"image"!=b||4002!=f.code)throw f;}}
955
- function Ku(a){var b=oh(a,"ServiceDescription");if(!b)return null;a=oh(b,"Latency");b=oh(b,"PlaybackRate");if(!a&&!b)return null;var c={};a&&("target"in a.attributes&&(c.targetLatency=parseInt(a.attributes.target,10)/1E3),"max"in a.attributes&&(c.maxLatency=parseInt(a.attributes.max,10)/1E3),"min"in a.attributes&&(c.minLatency=parseInt(a.attributes.min,10)/1E3));b&&("max"in b.attributes&&(c.maxPlaybackRate=parseFloat(b.attributes.max)),"min"in b.attributes&&(c.minPlaybackRate=parseFloat(b.attributes.min)));
956
- return c}function Lu(a){a=kh(a,"SupplementalProperty");if(!a.length)return null;a=t(a);for(var b=a.next();!b.done;b=a.next())if(b=b.value,"urn:mpeg:dash:chaining:2016"==b.attributes.schemeIdUri)return b.attributes.value;return null}
957
- function Iu(a,b,c,d){var e=b.Yb;e||(e=th(d,"mediaPresentationDuration",xh),a.j.Yb=e);var f=[],g=0;d=kh(d,"Period");for(var h=0;h<d.length;h++){var k=d[h],l=d[h+1],m=th(k,"start",xh,g),n=k.attributes.id,p=th(k,"duration",xh),r=null;if(l){var u=th(l,"start",xh);null!=u&&(r=u-m)}else null!=e&&(r=e-m);null==r&&(r=p);if(!(null!==a.J&&null!==n&&null!==m&&m<a.J)||a.S.includes(n)||h+1==d.length){null!==m&&(null===a.J||m>a.J)&&(a.J=m);g=Qu(a,b,c,{start:m,duration:r,node:k,Zd:null==r||!l});f.push(g);b.La.id&&
958
- r&&(a.N[b.La.id]=r);if(null==r){g=null;break}g=m+r}}a.S=f.map(function(v){return v.id});return null!=e?{periods:f,duration:e,Ch:!1}:{periods:f,duration:g,Ch:!0}}
959
- function Qu(a,b,c,d){b.La=Ru(a,d.node,null,c);b.va=d;b.La.Ya=b.Ya;b.La.id||(b.La.id="__shaka_period_"+d.start);var e=kh(d.node,"EventStream");c=b.presentationTimeline.Cb();e=t(e);for(var f=e.next();!f.done;f=e.next())Su(a,d.start,d.duration,f.value,c);c=kh(d.node,"AdaptationSet").map(function(m){return Tu(a,b,m)}).filter(We);if(b.Lb){d=[];e=t(c);for(f=e.next();!f.done;f=e.next()){f=t(f.value.gk);for(var g=f.next();!g.done;g=f.next())d.push(g.value)}if(d.length!=(new Set(d)).size)throw new U(2,4,4018);
960
- }d=c.filter(function(m){return!m.ih});c=c.filter(function(m){return m.ih});c=t(c);for(e=c.next();!e.done;e=c.next()){e=e.value;f=e.ih.split(" ");g=t(d);for(var h=g.next();!h.done;h=g.next()){var k=h.value;if(f.includes(k.id)){h={};k=t(k.streams);for(var l=k.next();!l.done;h={ye:h.ye},l=k.next())h.ye=l.value,h.ye.trickModeVideo=e.streams.find(function(m){return function(n){return Ge(m.ye.codecs)==Ge(n.codecs)}}(h))}}}c=Uu(a.g.disableAudio,d,"audio");e=Uu(a.g.disableVideo,d,"video");f=Uu(a.g.disableText,
961
- d,Sc);d=Uu(a.g.disableThumbnails,d,"image");if(0===e.length&&0===c.length)throw new U(2,4,4004);return{id:b.La.id,audioStreams:c,videoStreams:e,textStreams:f,imageStreams:d}}function Uu(a,b,c){return a||!b.length?[]:b.reduce(function(d,e){if(e.contentType!=c)return d;d.push.apply(d,x(e.streams));return d},[])}
962
- function Tu(a,b,c){function d(H){switch(H){case 1:case 5:case 6:case 7:return"srgb";case 9:return"rec2020";case 11:case 12:return"p3"}}function e(H){switch(H){case 1:case 6:case 13:case 14:case 15:return"SDR";case 16:return"PQ";case 18:return"HLG"}}b.Ia=Ru(a,c,b.La,null);var f=!1,g=kh(c,"Role"),h=g.map(function(H){return H.attributes.value}).filter(We),k=void 0,l=b.Ia.contentType==Sc;l&&(k="subtitle");g=t(g);for(var m=g.next();!m.done;m=g.next()){m=m.value;var n=m.attributes.schemeIdUri;if(null==
939
+ function Cu(a){var b,c,d,e,f,g,h,k,l;return O(function(m){if(1==m.g)return b="MPD",c=Eu(a),d=a.A,c.length?(d=c,b="Patch"):1<a.A.length&&a.h&&(e=Nt(a.h,"Location",!0),e.length&&(d=e)),f=Ag(d,a.g.retryParameters),g=Date.now(),E(m,Fu(a,f,0,{type:4}),2);if(3!=m.g){h=m.h;if(!a.j)return m.return(0);h.uri&&h.uri!=h.originalUri&&!a.A.includes(h.uri)&&a.A.unshift(h.uri);return E(m,Gu(a,h.data,h.uri,b),3)}k=Date.now();l=(k-g)/1E3;a.R.sample(1,l);return m.return(l)})}
940
+ function Gu(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u;return O(function(v){if(1==v.g){e=b;f=a.g.dash.manifestPreprocessor;g=wm;if(f!=g){xd("manifest.dash.manifestPreprocessor configuration","Please Use manifest.dash.manifestPreprocessorTXml instead.");h=zu(e,d);if(!h)throw new U(2,4,4001,c);f(h);e=Ac(h.outerHTML)}k=bh(e,d);if(!k)throw new U(2,4,4001,c);l=a.g.dash.manifestPreprocessorTXml;m=xm;l!=m&&l(k);if("Patch"===d)return v.return(Hu(a,k));if(n=a.g.dash.disableXlinkProcessing)return v.return(Iu(a,k,c));
941
+ p=a.g.dash.xlinkFailGracefully;r=Vs(k,a.g.retryParameters,p,c,a.j.networkingEngine);ug(a.L,r);return E(v,r.promise,2)}u=v.h;return v.return(Iu(a,u,c))})}
942
+ function Iu(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q,T,R,ra,sa,Ca,Fa,Ia,Pa,Ja,db,Da,$a,xb,ad,ye,Fd,Rc,ze,Ae,Be,Gd,pj,dh,qj,rj,eh,Ce;return O(function(rc){switch(rc.g){case 1:a.h&&a.h.l.clear();d=[c];e=[];f=new Map;g=kh(b,"Location");h=t(g);for(k=h.next();!k.done;k=h.next())if(l=k.value,m=l.attributes.serviceLocation,n=mh(l))p=Lc(d,[n])[0],m&&(a.h?Mt(a.h,"Location",m,p):f.set(m,p)),e.push(p);a.h?(r=Nt(a.h,"Location",!0),0<r.length&&(d=a.A=r)):e.length&&(d=a.A=e);a.l.Ze=
943
+ b.attributes.id||"";a.l.ge=th(b,"publishTime",wh)||0;a.F=kh(b,"PatchLocation");u=Promise.resolve();if((v=oh(b,"ContentSteering"))&&a.j){w=v.attributes.defaultServiceLocation;if(a.h)a.h.i=d,a.h.h=w;else if(a.h=new It(a.j),a.h.configure(a.g),a.h.setManifestType("DASH"),a.h.i=d,a.h.h=w,A=mh(v))(z=th(v,"queryBeforeStart",Dh,!1))?u=Jt(a.h,A):Jt(a.h,A);C=t(f.keys());for(y=C.next();!y.done;y=C.next())B=y.value,D=f.get(B),Mt(a.h,"Location",B,D)}K=kh(b,"BaseURL");J=!1;if(a.h)for(I=t(K),H=I.next();!H.done;H=
944
+ I.next())N=H.value,L=N.attributes.serviceLocation,M=mh(N),L&&M&&(Mt(a.h,"BaseURL",L,M),J=!0);J&&a.h||(Q=K.map(mh),G=Lc(d,Q));T=function(){return a.h&&J?Nt(a.h,"BaseURL"):G?G:[]};a.l.Va=T;R=0;K&&K.length&&(R=th(K[0],"availabilityTimeOffset",Ch)||0);a.l.Ya=R;ra=a.g.dash.ignoreMinBufferTime;sa=0;ra||(sa=th(b,"minBufferTime",xh)||0);a.H=th(b,"minimumUpdatePeriod",xh,-1);Ca=th(b,"availabilityStartTime",wh);Fa=th(b,"timeShiftBufferDepth",xh);Ia=a.g.dash.ignoreSuggestedPresentationDelay;Pa=null;Ia||(Pa=
945
+ th(b,"suggestedPresentationDelay",xh));Ja=a.g.dash.ignoreMaxSegmentDuration;db=null;Ja||(db=th(b,"maxSegmentDuration",xh));Da=b.attributes.type||"static";a.i&&a.i.presentationTimeline&&(a.N=a.i.presentationTimeline.U()&&"static"==Da);a.l.type=Da;if(a.i)for($a=a.i.presentationTimeline,xb=t(Object.values(a.u)),ad=xb.next();!ad.done;ad=xb.next())ye=ad.value,ye.segmentIndex&&ye.segmentIndex.eb($a.Cb());else Fd=a.g.defaultPresentationDelay||1.5*sa,Rc=null!=Pa?Pa:Fd,$a=new Bk(Ca,Rc,a.g.dash.autoCorrectDrift);
946
+ $a.Mc("static"==Da);(ze=$a.U())&&!isNaN(a.g.availabilityWindowOverride)&&(Fa=a.g.availabilityWindowOverride);null==Fa&&(Fa=Infinity);$a.nf(Fa);Ae=b.attributes.profiles||"";a.l.profiles=Ae.split(",");Be={Lb:"static"!=Da,presentationTimeline:$a,La:null,va:null,Ia:null,M:null,bandwidth:0,Ag:!1,Ya:R,Yb:null,profiles:Ae.split(",")};Gd=Ju(a,Be,T,b);pj=Gd.duration;dh=Gd.periods;("static"!=Da||a.N)&&Gd.Ch||$a.sb(pj||Infinity);a.K&&!a.G&&(qj=a.j.isAutoLowLatencyMode())&&(a.j.enableLowLatencyMode(),a.G=a.j.isLowLatencyMode());
947
+ a.G?$a.bi(a.K):a.K&&Ya("Low-latency DASH 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.");$a.Jg(db||1);return E(rc,u,2);case 2:return a.G&&(sa=0,rj=null!=Pa?Pa:a.g.defaultPresentationDelay,$a.Xg(rj)),a.i?E(rc,Ku(a,Gd.periods,!1),4):E(rc,a.m.Xf(dh,Be.Lb),6);case 6:a.i={presentationTimeline:$a,variants:a.m.j,textStreams:a.m.ug(),imageStreams:a.m.i,offlineSessionIds:[],
948
+ minBufferTime:sa||0,sequenceMode:a.g.dash.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,type:"DASH",serviceDescription:Lu(b),nextUrl:Mu(b)};if(!$a.si()){rc.B(7);break}eh=kh(b,"UTCTiming");return E(rc,Nu(a,T,eh),8);case 8:Ce=rc.h;if(!a.j)return rc.return();$a.ci(Ce);case 7:$a.Ue();case 4:a.j.makeTextStreamsForClosedCaptions(a.i),F(rc)}})}
949
+ function Ku(a,b,c){var d;return O(function(e){if(1==e.g)return E(e,a.m.Xf(b,!0,c),2);a.i.variants=a.m.j;d=a.m.ug();0<d.length&&(a.i.textStreams=d);a.i.imageStreams=a.m.i;a.j.filter(a.i);F(e)})}
950
+ function Hu(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I;return O(function(H){if(1==H.g){c=b.attributes.mpdId;d=th(b,"originalPublishTime",wh);if(!c||c!==a.l.Ze||d!==a.l.ge)throw a.F=[],new U(1,4,4052);e=[];f=[];g=new Set;h=t(jh(b));for(k=h.next();!k.done;k=h.next())if(l=k.value,m=Fh(l.attributes.sel||""),n=m[m.length-1],p=mh(l)||"","MPD"===n.name)if("mediaPresentationDuration"===n.ec){r=mh(l)||"";var N=xh(r);if(null!=N){a.l.Yb=N;for(var L=t(a.o.values()),M=L.next();!M.done;M=L.next())M.value.Yb=
951
+ N}}else if("type"===n.ec){a.i.presentationTimeline.Mc("static"==p);a.l.type=p;N=t(a.o.values());for(L=N.next();!L.done;L=N.next())L.value.Lb="dynamic"==p;"static"==p&&(a.H=-1)}else"publishTime"===n.ec?a.l.ge=wh(p)||0:null===n.ec&&"add"===l.tagName&&f.push(l);else if("PatchLocation"===n.name)Gh(a.F,l);else if("Period"===n.name)if("add"===l.tagName)f.push(l);else{if("remove"===l.tagName&&n.id)for(N=n.id,L=t(a.o.keys()),M=L.next();!M.done;M=L.next())if(M=M.value,M.startsWith(N)){var Q=a.o.get(M);Ss(Q,
952
+ tt,"SegmentTimeline").children=[];Ou(a,M);a.o.delete(M)}}else if("SegmentTemplate"===n.name){L=Fh(l.attributes.sel||"");N=L[L.length-1];if(N.ec){L=Pu(a,L);M=mh(l)||"";Q=t(L);for(var T=Q.next();!T.done;T=Q.next())T=a.o.get(T.value),Hh(T.M.pc,l.tagName,N.ec,M);N=L}else N=[];u=N;v=t(u);for(w=v.next();!w.done;w=v.next())A=w.value,g.add(A)}else if("SegmentTimeline"===n.name||"S"===n.name){N=Fh(l.attributes.sel||"");N=Pu(a,N);L=t(N);for(M=L.next();!M.done;M=L.next())M=a.o.get(M.value),M=Ss(M,tt,"SegmentTimeline"),
953
+ Q=kh(M,"S"),Gh(Q,l),M.children=Q;z=N;C=t(z);for(w=C.next();!w.done;w=C.next())y=w.value,g.add(y)}B=t(g);for(w=B.next();!w.done;w=B.next())D=w.value,Ou(a,D);K=t(f);for(G=K.next();!G.done;G=K.next())J=G.value,e.push.apply(e,x(Ju(a,{Lb:"dynamic"==a.l.type,presentationTimeline:a.i.presentationTimeline,La:null,va:null,Ia:null,M:null,bandwidth:0,Ag:!1,Ya:a.l.Ya,profiles:a.l.profiles,Yb:a.l.Yb},a.l.Va,J).periods));return e.length?E(H,Ku(a,e,!0),2):H.B(2)}"static"==a.l.type&&(I=a.l.Yb,a.i.presentationTimeline.sb(I||
954
+ Infinity));F(H)})}function Pu(a,b){var c="",d="",e="";b=t(b);for(var f=b.next();!f.done;f=b.next())f=f.value,"Period"===f.name?c=f.id:"AdaptationSet"===f.name?d=f.id:"Representation"===f.name&&(e=f.id);b=[];if(e)b.push(c+","+e);else for(a=t(a.o.values()),e=a.next();!e.done;e=a.next())e=e.value,e.La.id===c&&e.Ia.id===d&&e.M.id&&b.push(c+","+e.M.id);return b}
955
+ function Ou(a,b){var c=a.o.get(b),d=a.u[b];d.segmentIndex&&d.segmentIndex.eb(a.i.presentationTimeline.Cb());try{var e=st(c,function(f,g,h,k){return Qu(a,f,g,h,k)},a.u,!0,a.g.dash.initialSegmentLimit,a.O,c.M.aesKey,null,!0);d.createSegmentIndex=function(){var f;return O(function(g){if(1==g.g){if(d.segmentIndex)return g.B(0);f=d;return E(g,e.yc(),3)}f.segmentIndex=g.h;F(g)})}}catch(f){if(b=c.M.contentType,b!=Sc&&"application"!=b&&"image"!=b||4002!=f.code)throw f;}}
956
+ function Lu(a){var b=oh(a,"ServiceDescription");if(!b)return null;a=oh(b,"Latency");b=oh(b,"PlaybackRate");if(!a&&!b)return null;var c={};a&&("target"in a.attributes&&(c.targetLatency=parseInt(a.attributes.target,10)/1E3),"max"in a.attributes&&(c.maxLatency=parseInt(a.attributes.max,10)/1E3),"min"in a.attributes&&(c.minLatency=parseInt(a.attributes.min,10)/1E3));b&&("max"in b.attributes&&(c.maxPlaybackRate=parseFloat(b.attributes.max)),"min"in b.attributes&&(c.minPlaybackRate=parseFloat(b.attributes.min)));
957
+ return c}function Mu(a){a=kh(a,"SupplementalProperty");if(!a.length)return null;a=t(a);for(var b=a.next();!b.done;b=a.next())if(b=b.value,"urn:mpeg:dash:chaining:2016"==b.attributes.schemeIdUri)return b.attributes.value;return null}
958
+ function Ju(a,b,c,d){var e=b.Yb;e||(e=th(d,"mediaPresentationDuration",xh),a.l.Yb=e);var f=0;a.i&&a.i.presentationTimeline&&a.N&&(f=a.i.presentationTimeline.ic());var g=[],h=f;d=kh(d,"Period");for(var k=0;k<d.length;k++){var l=d[k],m=d[k+1],n=th(l,"start",xh,h),p=l.attributes.id,r=th(l,"duration",xh),u=null;if(m){var v=th(m,"start",xh);null!=v&&(u=v-n)}else null!=e&&(u=e-n+f);null==u&&(u=r);if(!(null!==a.J&&null!==p&&null!==n&&n<a.J)||a.X.includes(p)||k+1==d.length){null!==n&&(null===a.J||n>a.J)&&
959
+ (a.J=n);h=Ru(a,b,c,{start:n,duration:u,node:l,Zd:null==u||!m});g.push(h);b.La.id&&u&&(a.O[b.La.id]=u);if(null==u){h=null;break}h=n+u}}a.X=g.map(function(w){return w.id});return null!=e?{periods:g,duration:e+f,Ch:!1}:{periods:g,duration:h,Ch:!0}}
960
+ function Ru(a,b,c,d){b.La=Su(a,d.node,null,c);b.va=d;b.La.Ya=b.Ya;b.La.id||(b.La.id="__shaka_period_"+d.start);var e=kh(d.node,"EventStream");c=b.presentationTimeline.Cb();e=t(e);for(var f=e.next();!f.done;f=e.next())Tu(a,d.start,d.duration,f.value,c);c=kh(d.node,"AdaptationSet").map(function(m){return Uu(a,b,m)}).filter(We);if(b.Lb){d=[];e=t(c);for(f=e.next();!f.done;f=e.next()){f=t(f.value.gk);for(var g=f.next();!g.done;g=f.next())d.push(g.value)}if(d.length!=(new Set(d)).size)throw new U(2,4,4018);
961
+ }d=c.filter(function(m){return!m.ih});c=c.filter(function(m){return m.ih});c=t(c);for(e=c.next();!e.done;e=c.next()){e=e.value;f=e.ih.split(" ");g=t(d);for(var h=g.next();!h.done;h=g.next()){var k=h.value;if(f.includes(k.id)){h={};k=t(k.streams);for(var l=k.next();!l.done;h={ye:h.ye},l=k.next())h.ye=l.value,h.ye.trickModeVideo=e.streams.find(function(m){return function(n){return Ge(m.ye.codecs)==Ge(n.codecs)}}(h))}}}c=Vu(a.g.disableAudio,d,"audio");e=Vu(a.g.disableVideo,d,"video");f=Vu(a.g.disableText,
962
+ d,Sc);d=Vu(a.g.disableThumbnails,d,"image");if(0===e.length&&0===c.length)throw new U(2,4,4004);return{id:b.La.id,audioStreams:c,videoStreams:e,textStreams:f,imageStreams:d}}function Vu(a,b,c){return a||!b.length?[]:b.reduce(function(d,e){if(e.contentType!=c)return d;d.push.apply(d,x(e.streams));return d},[])}
963
+ function Uu(a,b,c){function d(H){switch(H){case 1:case 5:case 6:case 7:return"srgb";case 9:return"rec2020";case 11:case 12:return"p3"}}function e(H){switch(H){case 1:case 6:case 13:case 14:case 15:return"SDR";case 16:return"PQ";case 18:return"HLG"}}b.Ia=Su(a,c,b.La,null);var f=!1,g=kh(c,"Role"),h=g.map(function(H){return H.attributes.value}).filter(We),k=void 0,l=b.Ia.contentType==Sc;l&&(k="subtitle");g=t(g);for(var m=g.next();!m.done;m=g.next()){m=m.value;var n=m.attributes.schemeIdUri;if(null==
963
964
  n||"urn:mpeg:dash:role:2011"==n)switch(m=m.attributes.value,m){case "main":f=!0;break;case "caption":case "subtitle":k=m}}var p,r;n=kh(c,"EssentialProperty");g=null;var u=!1;m=!1;n=t(n);for(var v=n.next();!v.done;v=n.next()){v=v.value;var w=v.attributes.schemeIdUri;"http://dashif.org/guidelines/trickmode"==w?g=v.attributes.value:"urn:mpeg:mpegB:cicp:TransferCharacteristics"==w?p=e(parseInt(v.attributes.value,10)):"urn:mpeg:mpegB:cicp:ColourPrimaries"==w?r=d(parseInt(v.attributes.value,10)):"urn:mpeg:mpegB:cicp:MatrixCoefficients"!=
964
965
  w&&("urn:mpeg:dash:ssr:2023"==w&&a.g.dash.enableFastSwitching?u=!0:m=!0)}var A=null;n=kh(c,"SupplementalProperty");n=t(n);for(v=n.next();!v.done;v=n.next())v=v.value,w=v.attributes.schemeIdUri,"http://dashif.org/guidelines/last-segment-number"==w?A=parseInt(v.attributes.value,10)-1:"urn:mpeg:mpegB:cicp:TransferCharacteristics"==w?p=e(parseInt(v.attributes.value,10)):"urn:mpeg:mpegB:cicp:ColourPrimaries"==w&&(r=d(parseInt(v.attributes.value,10)));n=kh(c,"Accessibility");var z=new Map,C;n=t(n);for(v=
965
966
  n.next();!v.done;v=n.next())if(w=v.value,v=w.attributes.schemeIdUri,w=w.attributes.value,"urn:scte:dash:cc:cea-608:2015"==v)if(v=1,null!=w){w=w.split(";");for(var y=t(w),B=y.next();!B.done;B=y.next()){var D=B.value,K=B=void 0;D.includes("=")?(D=D.split("="),B=D[0].startsWith("CC")?D[0]:"CC"+D[0],K=D[1]||"und"):(B="CC"+v,2==w.length?v+=2:v++,K=D);z.set(B,Xc(K))}}else z.set("CC1","und");else if("urn:scte:dash:cc:cea-708:2015"==v)if(v=1,null!=w)for(w=t(w.split(";")),B=w.next();!B.done;B=w.next())B=B.value,
966
967
  D=y=void 0,B.includes("=")?(B=B.split("="),y="svc"+B[0],D=B[1].split(",")[0].split(":").pop()):(y="svc"+v,v++,D=B),z.set(y,Xc(D));else z.set("svc1","und");else"urn:mpeg:dash:role:2011"==v?null!=w&&(h.push(w),"captions"==w&&(k="caption")):"urn:tva:metadata:cs:AudioPurposeCS:2007"==v&&("1"==w?C="visually impaired":"2"==w&&(C="hard of hearing"));if(m)return null;m=kh(c,"ContentProtection");var G=Es(m,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI),J=Xc(b.Ia.language||"und"),I=c.attributes.label;(m=
967
- kh(c,"Label"))&&m.length&&(m=lh(m[0]))&&(I=m);m=kh(c,"Representation");c=m.map(function(H){if(H=Vu(a,b,G,k,J,I,f,h,z,H,C,A))H.hdr=H.hdr||p,H.colorGamut=H.colorGamut||r,H.fastSwitching=u;return H}).filter(function(H){return!!H});if(0==c.length){g="image"==b.Ia.contentType;if(a.g.dash.ignoreEmptyAdaptationSet||l||g)return null;throw new U(2,4,4003);}if(!b.Ia.contentType||"application"==b.Ia.contentType)for(b.Ia.contentType=Wu(c[0].mimeType,c[0].codecs),l=t(c),v=l.next();!v.done;v=l.next())v.value.type=
968
- b.Ia.contentType;l=b.Ia.id||"__fake__"+a.R++;n=t(c);for(v=n.next();!v.done;v=n.next()){v=v.value;w=t(G.drmInfos);for(y=w.next();!y.done;y=w.next())y=y.value,y.keyIds=y.keyIds&&v.keyIds?new Set([].concat(x(y.keyIds),x(v.keyIds))):y.keyIds||v.keyIds;a.g.dash.enableAudioGroups&&(v.groupId=l)}m=m.map(function(H){return H.attributes.id}).filter(We);return{id:l,contentType:b.Ia.contentType,language:J,Ol:f,streams:c,drmInfos:G.drmInfos,ih:g,gk:m}}
969
- function Vu(a,b,c,d,e,f,g,h,k,l,m,n){b.M=Ru(a,l,b.Ia,null);var p=b.M.id;a.K=Math.min(a.K,b.M.Ya);if(!Xu(b.M))return null;var r=b.va.start;b.bandwidth=th(l,"bandwidth",Ah)||0;var u=b.M.contentType,v=u==Sc||"application"==u;u="image"==u;try{var w=void 0;if(c.Rf){var A=b.M.Va,z=Lc(A(),[c.Rf.Mj]),C=Ag(z,a.g.retryParameters);w={bitsKey:128,blockCipherMode:"CBC",iv:c.Rf.iv,firstMediaSequenceNumber:0,fetchKey:function(){var I,H,N;return O(function(L){if(1==L.g)return E(L,Eu(a,C,6),2);if(3!=L.g){I=L.h;if(!I.data||
970
- 16!=I.data.byteLength)throw new U(2,4,4049);H={name:"AES-CBC"};N=w;return E(L,window.crypto.subtle.importKey("raw",I.data,H,!0,["decrypt"]),3)}N.cryptoKey=L.h;w.fetchKey=void 0;F(L)})}}}b.M.aesKey=w;A=function(I,H,N,L){return Pu(a,I,H,N,L)};if(b.M.od)var y=ht(b,A,w);else if(b.M.bc)y=nt(b,a.u,w);else if(b.M.mc)y=st(b,A,a.u,!!a.l,a.g.dash.initialSegmentLimit,a.N,w,n,!1);else{var B=b.va.duration||0,D=b.M.Va;y={wc:function(){var I=Zk(r,B,D());I.Xc(function(H){H.mimeType=b.M.mimeType;H.codecs=b.M.codecs});
968
+ kh(c,"Label"))&&m.length&&(m=lh(m[0]))&&(I=m);m=kh(c,"Representation");c=m.map(function(H){if(H=Wu(a,b,G,k,J,I,f,h,z,H,C,A))H.hdr=H.hdr||p,H.colorGamut=H.colorGamut||r,H.fastSwitching=u;return H}).filter(function(H){return!!H});if(0==c.length){g="image"==b.Ia.contentType;if(a.g.dash.ignoreEmptyAdaptationSet||l||g)return null;throw new U(2,4,4003);}if(!b.Ia.contentType||"application"==b.Ia.contentType)for(b.Ia.contentType=Xu(c[0].mimeType,c[0].codecs),l=t(c),v=l.next();!v.done;v=l.next())v.value.type=
969
+ b.Ia.contentType;l=b.Ia.id||"__fake__"+a.S++;n=t(c);for(v=n.next();!v.done;v=n.next()){v=v.value;w=t(G.drmInfos);for(y=w.next();!y.done;y=w.next())y=y.value,y.keyIds=y.keyIds&&v.keyIds?new Set([].concat(x(y.keyIds),x(v.keyIds))):y.keyIds||v.keyIds;a.g.dash.enableAudioGroups&&(v.groupId=l)}m=m.map(function(H){return H.attributes.id}).filter(We);return{id:l,contentType:b.Ia.contentType,language:J,Ol:f,streams:c,drmInfos:G.drmInfos,ih:g,gk:m}}
970
+ function Wu(a,b,c,d,e,f,g,h,k,l,m,n){b.M=Su(a,l,b.Ia,null);var p=b.M.id;a.K=Math.min(a.K,b.M.Ya);if(!Yu(b.M))return null;var r=b.va.start;b.bandwidth=th(l,"bandwidth",Ah)||0;var u=b.M.contentType,v=u==Sc||"application"==u;u="image"==u;try{var w=void 0;if(c.Rf){var A=b.M.Va,z=Lc(A(),[c.Rf.Mj]),C=Ag(z,a.g.retryParameters);w={bitsKey:128,blockCipherMode:"CBC",iv:c.Rf.iv,firstMediaSequenceNumber:0,fetchKey:function(){var I,H,N;return O(function(L){if(1==L.g)return E(L,Fu(a,C,6),2);if(3!=L.g){I=L.h;if(!I.data||
971
+ 16!=I.data.byteLength)throw new U(2,4,4049);H={name:"AES-CBC"};N=w;return E(L,window.crypto.subtle.importKey("raw",I.data,H,!0,["decrypt"]),3)}N.cryptoKey=L.h;w.fetchKey=void 0;F(L)})}}}b.M.aesKey=w;A=function(I,H,N,L){return Qu(a,I,H,N,L)};if(b.M.od)var y=ht(b,A,w);else if(b.M.bc)y=nt(b,a.u,w);else if(b.M.pc)y=st(b,A,a.u,!!a.i,a.g.dash.initialSegmentLimit,a.O,w,n,!1);else{var B=b.va.duration||0,D=b.M.Va;y={yc:function(){var I=Zk(r,B,D());I.Yc(function(H){H.mimeType=b.M.mimeType;H.codecs=b.M.codecs});
971
972
  return Promise.resolve(I)}}}}catch(I){if((v||u)&&4002==I.code)return null;throw I;}n=kh(l,"ContentProtection");n=Is(n,c,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI);n=new Set(n?[n]:[]);A=!1;kh(l,"SupplementalProperty").some(function(I){return"tag:dolby.com,2018:dash:EC3_ExtensionType:2018"==I.attributes.schemeIdUri&&"JOC"==I.attributes.value})&&(A=!0);z=!1;v&&(z=h.includes("forced_subtitle")||h.includes("forced-subtitle"));var K;if(u&&((l=kh(l,"EssentialProperty").find(function(I){return["http://dashif.org/thumbnail_tile",
972
- "http://dashif.org/guidelines/thumbnail_tile"].includes(I.attributes.schemeIdUri)}))&&(K=l.attributes.value),!K))return null;var G;l=b.M.codecs;b.profiles.includes("http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10")&&(l.includes("hvc1.2.4.L153.B0")||l.includes("hev1.2.4.L153.B0"))&&(G="PQ");v=b.M.id?b.La.id+","+b.M.id:"";a.F.length&&p&&a.o.set(b.La.id+","+p,Yu(b));var J=v&&a.u[v]?a.u[v]:{id:a.R++,originalId:b.M.id,groupId:null,createSegmentIndex:function(){return Promise.resolve()},closeSegmentIndex:function(){J.segmentIndex&&
973
+ "http://dashif.org/guidelines/thumbnail_tile"].includes(I.attributes.schemeIdUri)}))&&(K=l.attributes.value),!K))return null;var G;l=b.M.codecs;b.profiles.includes("http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10")&&(l.includes("hvc1.2.4.L153.B0")||l.includes("hev1.2.4.L153.B0"))&&(G="PQ");v=b.M.id?b.La.id+","+b.M.id:"";a.F.length&&p&&a.o.set(b.La.id+","+p,Zu(b));var J=v&&a.u[v]?a.u[v]:{id:a.S++,originalId:b.M.id,groupId:null,createSegmentIndex:function(){return Promise.resolve()},closeSegmentIndex:function(){J.segmentIndex&&
973
974
  (J.segmentIndex.release(),J.segmentIndex=null)},segmentIndex:null,mimeType:b.M.mimeType,codecs:l,frameRate:b.M.frameRate,pixelAspectRatio:b.M.pixelAspectRatio,bandwidth:b.bandwidth,width:b.M.width,height:b.M.height,kind:d,encrypted:0<c.drmInfos.length,drmInfos:c.drmInfos,keyIds:n,language:e,originalLanguage:b.Ia.language,label:f,type:b.Ia.contentType,primary:g,trickModeVideo:null,emsgSchemeIdUris:b.M.emsgSchemeIdUris,roles:h,forced:z,channelsCount:b.M.jd,audioSamplingRate:b.M.audioSamplingRate,spatialAudio:A,
974
- closedCaptions:k,hdr:G,colorGamut:void 0,videoLayout:void 0,tilesLayout:K,accessibilityPurpose:m,external:!1,fastSwitching:!1,fullMimeTypes:new Set([te(b.M.mimeType,b.M.codecs)])};J.createSegmentIndex=function(){var I;return O(function(H){if(1==H.g){if(J.segmentIndex)return H.B(0);I=J;return E(H,y.wc(),3)}I.segmentIndex=H.h;F(H)})};v&&b.Lb&&!a.u[v]&&(a.u[v]=J);return J}
975
- function Yu(a){for(var b={},c=t(Object.keys(a)),d=c.next();!d.done;d=c.next())if(d=d.value,["period","adaptationSet","representation"].includes(d)){var e=a[d];b[d]={od:null,bc:null,mc:e.mc,Va:e.Va,width:e.width,height:e.height,contentType:e.contentType,mimeType:e.mimeType,language:e.language,codecs:e.codecs,frameRate:e.frameRate,pixelAspectRatio:e.pixelAspectRatio,emsgSchemeIdUris:e.emsgSchemeIdUris,id:e.id,jd:e.jd,audioSamplingRate:e.audioSamplingRate,Ya:e.Ya,cd:e.cd}}else"periodInfo"==d?(e=a[d],
976
- b[d]={start:e.start,duration:e.duration,node:null,Zd:e.Zd}):b[d]=a[d];return b}function Au(a){var b,c;O(function(d){switch(d.g){case 1:return b=0,ta(d,2),E(d,Bu(a),4);case 4:b=d.h;va(d,3);break;case 2:if(c=wa(d),a.i){if(a.g.raiseFatalErrorOnManifestUpdateRequestFailure)return a.i.onError(c),d.return();c.severity=1;a.i.onError(c)}case 3:if(!a.i)return d.return();a.i.onManifestUpdated();Cu(a,b);F(d)}})}
977
- function Cu(a,b){if(!(0>a.H)){var c=a.H;0<=a.g.dash.updatePeriod&&(c=a.g.dash.updatePeriod);a.I.V(Math.max(c-b,md(a.O)))}}
978
- function Ru(a,b,c,d){c=c||{contentType:"",mimeType:"",codecs:"",emsgSchemeIdUris:[],frameRate:void 0,pixelAspectRatio:void 0,jd:null,audioSamplingRate:null,Ya:0,Tg:0};d=d||c.Va;var e=b.attributes.id,f=kh(b,"BaseURL"),g,h=!1;if(a.h)for(var k=t(f),l=k.next();!l.done;l=k.next()){var m=l.value;l=m.attributes.serviceLocation;m=mh(m);l&&m&&(Mt(a.h,e,l,m),h=!0)}h&&a.h||(g=f.map(mh));k=b.attributes.contentType||c.contentType;l=b.attributes.mimeType||c.mimeType;m=[b.attributes.codecs||c.codecs];var n=uh(b,
979
- "urn:scte:dash:scte214-extensions","supplementalCodecs");n&&m.push(n);m=Ft(m).join(",");n=th(b,"frameRate",Eh)||c.frameRate;var p=b.attributes.sar||c.pixelAspectRatio,r=Zu(kh(b,"InbandEventStream"),c.emsgSchemeIdUris),u=kh(b,"AudioChannelConfiguration");u=$u(u)||c.jd;var v=th(b,"audioSamplingRate",Bh)||c.audioSamplingRate;k||(k=Wu(l,m));var w=oh(b,"SegmentBase"),A=oh(b,"SegmentTemplate"),z=w?th(w,"availabilityTimeOffset",Ch)||0:0,C=A?th(A,"availabilityTimeOffset",Ch)||0:0,y=f&&f.length?th(f[0],"availabilityTimeOffset",
980
- Ch)||0:0;z=c.Ya+y+z+C;C=null;(y=oh(b,"SegmentSequenceProperties"))&&(y=oh(y,"SAP"))&&(C=th(y,"cadence",zh));return{Va:function(){return Lc(d(),f.length?a.h&&h?Nt(a.h,e):g?g:[]:[])},od:w||c.od,bc:oh(b,"SegmentList")||c.bc,mc:A||c.mc,width:th(b,"width",Bh)||c.width,height:th(b,"height",Bh)||c.height,contentType:k,mimeType:l,codecs:m,frameRate:n,pixelAspectRatio:p,emsgSchemeIdUris:r,id:e,language:b.attributes.lang,jd:u,audioSamplingRate:v,Ya:z,cd:null,Tg:C||c.Tg}}
981
- function Zu(a,b){b=b.slice();a=t(a);for(var c=a.next();!c.done;c=a.next())c=c.value.attributes.schemeIdUri,b.includes(c)||b.push(c);return b}
982
- function $u(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){var c=b.value;if(b=c.attributes.schemeIdUri)if(c=c.attributes.value)switch(b){case "urn:mpeg:dash:outputChannelPositionList:2012":return c.trim().split(/ +/).length;case "urn:mpeg:dash:23003:3:audio_channel_configuration:2011":case "urn:dts:dash:audio_channel_configuration:2012":b=parseInt(c,10);if(!b)continue;return b;case "tag:dolby.com,2014:dash:audio_channel_configuration:2011":case "urn:dolby:dash:audio_channel_configuration:2011":b=
983
- parseInt(c,16);if(!b)continue;for(a=0;b;)b&1&&++a,b>>=1;return a;case "urn:mpeg:mpegB:cicp:ChannelConfiguration":if(b=[0,1,2,3,4,5,6,8,2,3,4,7,8,24,8,12,10,12,14,12,14],(c=parseInt(c,10))&&0<c&&c<b.length)return b[c]}}return null}function Xu(a){var b=a.od?1:0;b+=a.bc?1:0;b+=a.mc?1:0;if(0==b)return a.contentType==Sc||"application"==a.contentType?!0:!1;1!=b&&(a.od&&(a.bc=null),a.mc=null);return!0}
984
- function av(a,b,c,d){var e,f,g,h,k,l,m;return O(function(n){if(1==n.g)return e=[Dc(c)],f=Lc(b(),e),g=Ag(f,a.g.retryParameters),g.method=d,h=a.i.networkingEngine.request(4,g),ug(a.L,h),E(n,h.promise,2);k=n.h;if("HEAD"==d){if(!k.headers||!k.headers.date)return n.return(0);l=k.headers.date}else l=wc(k.data);m=Date.parse(l);return isNaN(m)?n.return(0):n.return(m-Date.now())})}
985
- function Mu(a,b,c){var d,e,f,g,h,k,l,m;return O(function(n){switch(n.g){case 1:d=c.map(function(p){return{scheme:p.attributes.schemeIdUri,value:p.attributes.value}}),e=a.g.dash.clockSyncUri,!d.length&&e&&d.push({scheme:"urn:mpeg:dash:utc:http-head:2014",value:e}),f=t(d),g=f.next();case 2:if(g.done){n.B(4);break}h=g.value;ta(n,5);k=h.scheme;l=h.value;switch(k){case "urn:mpeg:dash:utc:http-head:2014":case "urn:mpeg:dash:utc:http-head:2012":return n.B(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 n.B(8);
986
- case "urn:mpeg:dash:utc:direct:2014":case "urn:mpeg:dash:utc:direct:2012":return m=Date.parse(l),n.return(isNaN(m)?0:m-Date.now());case "urn:mpeg:dash:utc:http-ntp:2014":case "urn:mpeg:dash:utc:ntp:2014":case "urn:mpeg:dash:utc:sntp:2014":Ya("NTP UTCTiming scheme is not supported");break;default:Ya("Unrecognized scheme in UTCTiming element",k)}n.B(9);break;case 7:return E(n,av(a,b,l,"HEAD"),10);case 10:return n.return(n.h);case 8:return E(n,av(a,b,l,"GET"),11);case 11:return n.return(n.h);case 9:va(n,
975
+ closedCaptions:k,hdr:G,colorGamut:void 0,videoLayout:void 0,tilesLayout:K,accessibilityPurpose:m,external:!1,fastSwitching:!1,fullMimeTypes:new Set([te(b.M.mimeType,b.M.codecs)])};J.createSegmentIndex=function(){var I;return O(function(H){if(1==H.g){if(J.segmentIndex)return H.B(0);I=J;return E(H,y.yc(),3)}I.segmentIndex=H.h;F(H)})};v&&b.Lb&&!a.u[v]&&(a.u[v]=J);return J}
976
+ function Zu(a){for(var b={},c=t(Object.keys(a)),d=c.next();!d.done;d=c.next())if(d=d.value,["period","adaptationSet","representation"].includes(d)){var e=a[d];b[d]={od:null,bc:null,pc:e.pc,Va:e.Va,width:e.width,height:e.height,contentType:e.contentType,mimeType:e.mimeType,language:e.language,codecs:e.codecs,frameRate:e.frameRate,pixelAspectRatio:e.pixelAspectRatio,emsgSchemeIdUris:e.emsgSchemeIdUris,id:e.id,jd:e.jd,audioSamplingRate:e.audioSamplingRate,Ya:e.Ya,dd:e.dd}}else"periodInfo"==d?(e=a[d],
977
+ b[d]={start:e.start,duration:e.duration,node:null,Zd:e.Zd}):b[d]=a[d];return b}function Bu(a){var b,c;O(function(d){switch(d.g){case 1:return b=0,ta(d,2),E(d,Cu(a),4);case 4:b=d.h;va(d,3);break;case 2:if(c=wa(d),a.j){if(a.g.raiseFatalErrorOnManifestUpdateRequestFailure)return a.j.onError(c),d.return();c.severity=1;a.j.onError(c)}case 3:if(!a.j)return d.return();a.j.onManifestUpdated();Du(a,b);F(d)}})}
978
+ function Du(a,b){if(!(0>a.H)){var c=a.H;0<=a.g.dash.updatePeriod&&(c=a.g.dash.updatePeriod);a.I.V(Math.max(c-b,md(a.R)))}}
979
+ function Su(a,b,c,d){c=c||{contentType:"",mimeType:"",codecs:"",emsgSchemeIdUris:[],frameRate:void 0,pixelAspectRatio:void 0,jd:null,audioSamplingRate:null,Ya:0,Tg:0};d=d||c.Va;var e=b.attributes.id,f=kh(b,"BaseURL"),g,h=!1;if(a.h)for(var k=t(f),l=k.next();!l.done;l=k.next()){var m=l.value;l=m.attributes.serviceLocation;m=mh(m);l&&m&&(Mt(a.h,e,l,m),h=!0)}h&&a.h||(g=f.map(mh));k=b.attributes.contentType||c.contentType;l=b.attributes.mimeType||c.mimeType;m=[b.attributes.codecs||c.codecs];var n=uh(b,
980
+ "urn:scte:dash:scte214-extensions","supplementalCodecs");n&&m.push(n);m=Ft(m).join(",");n=th(b,"frameRate",Eh)||c.frameRate;var p=b.attributes.sar||c.pixelAspectRatio,r=$u(kh(b,"InbandEventStream"),c.emsgSchemeIdUris),u=kh(b,"AudioChannelConfiguration");u=av(u)||c.jd;var v=th(b,"audioSamplingRate",Bh)||c.audioSamplingRate;k||(k=Xu(l,m));var w=oh(b,"SegmentBase"),A=oh(b,"SegmentTemplate"),z=w?th(w,"availabilityTimeOffset",Ch)||0:0,C=A?th(A,"availabilityTimeOffset",Ch)||0:0,y=f&&f.length?th(f[0],"availabilityTimeOffset",
981
+ Ch)||0:0;z=c.Ya+y+z+C;C=null;(y=oh(b,"SegmentSequenceProperties"))&&(y=oh(y,"SAP"))&&(C=th(y,"cadence",zh));return{Va:function(){return Lc(d(),f.length?a.h&&h?Nt(a.h,e):g?g:[]:[])},od:w||c.od,bc:oh(b,"SegmentList")||c.bc,pc:A||c.pc,width:th(b,"width",Bh)||c.width,height:th(b,"height",Bh)||c.height,contentType:k,mimeType:l,codecs:m,frameRate:n,pixelAspectRatio:p,emsgSchemeIdUris:r,id:e,language:b.attributes.lang,jd:u,audioSamplingRate:v,Ya:z,dd:null,Tg:C||c.Tg}}
982
+ function $u(a,b){b=b.slice();a=t(a);for(var c=a.next();!c.done;c=a.next())c=c.value.attributes.schemeIdUri,b.includes(c)||b.push(c);return b}
983
+ function av(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){var c=b.value;if(b=c.attributes.schemeIdUri)if(c=c.attributes.value)switch(b){case "urn:mpeg:dash:outputChannelPositionList:2012":return c.trim().split(/ +/).length;case "urn:mpeg:dash:23003:3:audio_channel_configuration:2011":case "urn:dts:dash:audio_channel_configuration:2012":b=parseInt(c,10);if(!b)continue;return b;case "tag:dolby.com,2014:dash:audio_channel_configuration:2011":case "urn:dolby:dash:audio_channel_configuration:2011":b=
984
+ parseInt(c,16);if(!b)continue;for(a=0;b;)b&1&&++a,b>>=1;return a;case "urn:mpeg:mpegB:cicp:ChannelConfiguration":if(b=[0,1,2,3,4,5,6,8,2,3,4,7,8,24,8,12,10,12,14,12,14],(c=parseInt(c,10))&&0<c&&c<b.length)return b[c]}}return null}function Yu(a){var b=a.od?1:0;b+=a.bc?1:0;b+=a.pc?1:0;if(0==b)return a.contentType==Sc||"application"==a.contentType?!0:!1;1!=b&&(a.od&&(a.bc=null),a.pc=null);return!0}
985
+ function bv(a,b,c,d){var e,f,g,h,k,l,m;return O(function(n){if(1==n.g)return e=[Dc(c)],f=Lc(b(),e),g=Ag(f,a.g.retryParameters),g.method=d,h=a.j.networkingEngine.request(4,g),ug(a.L,h),E(n,h.promise,2);k=n.h;if("HEAD"==d){if(!k.headers||!k.headers.date)return n.return(0);l=k.headers.date}else l=wc(k.data);m=Date.parse(l);return isNaN(m)?n.return(0):n.return(m-Date.now())})}
986
+ function Nu(a,b,c){var d,e,f,g,h,k,l,m;return O(function(n){switch(n.g){case 1:d=c.map(function(p){return{scheme:p.attributes.schemeIdUri,value:p.attributes.value}}),e=a.g.dash.clockSyncUri,!d.length&&e&&d.push({scheme:"urn:mpeg:dash:utc:http-head:2014",value:e}),f=t(d),g=f.next();case 2:if(g.done){n.B(4);break}h=g.value;ta(n,5);k=h.scheme;l=h.value;switch(k){case "urn:mpeg:dash:utc:http-head:2014":case "urn:mpeg:dash:utc:http-head:2012":return n.B(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 n.B(8);
987
+ case "urn:mpeg:dash:utc:direct:2014":case "urn:mpeg:dash:utc:direct:2012":return m=Date.parse(l),n.return(isNaN(m)?0:m-Date.now());case "urn:mpeg:dash:utc:http-ntp:2014":case "urn:mpeg:dash:utc:ntp:2014":case "urn:mpeg:dash:utc:sntp:2014":Ya("NTP UTCTiming scheme is not supported");break;default:Ya("Unrecognized scheme in UTCTiming element",k)}n.B(9);break;case 7:return E(n,bv(a,b,l,"HEAD"),10);case 10:return n.return(n.h);case 8:return E(n,bv(a,b,l,"GET"),11);case 11:return n.return(n.h);case 9:va(n,
987
988
  3);break;case 5:wa(n);case 3:g=f.next();n.B(2);break;case 4:return Ya("A UTCTiming element should always be given in live manifests! This content may not play on clients with bad clocks!"),n.return(0)}})}
988
- function Su(a,b,c,d,e){var f=d.attributes.schemeIdUri||"",g=d.attributes.value||"",h=th(d,"timescale",Bh)||1;d=t(kh(d,"Event"));for(var k=d.next();!k.done;k=d.next()){k=k.value;var l=th(k,"presentationTime",Bh)||0,m=th(k,"duration",Bh)||0;l=l/h+b;m=l+m/h;null!=c&&(l=Math.min(l,b+c),m=Math.min(m,b+c));m<e||(k={schemeIdUri:f,value:g,startTime:l,endTime:m,id:k.attributes.id||"",eventElement:Ih(k),eventNode:k},a.i.onTimelineRegionAdded(k))}}
989
- function Pu(a,b,c,d,e){var f,g,h,k;return O(function(l){if(1==l.g)return f=Gg,g=e?0:1,h=Bl(b,c,d,a.g.retryParameters),E(l,Eu(a,h,f,{type:g}),2);k=l.h;return l.return(k.data)})}function Wu(a,b){b=te(a,b);return Ne(b)?Sc:a.split("/")[0]}function Eu(a,b,c,d){b=a.i.networkingEngine.request(c,b,d);ug(a.L,b);return b.promise}
990
- function Du(a){var b=a.j.ge;if(!a.j.Ze||!b||!a.F.length)return[];var c=Date.now()/1E3,d=a.F.filter(function(e){e=Bh(e.attributes.ttl);return!e||b+e>c}).map(mh).filter(We);return d.length?Lc(a.A,d):[]}P("shaka.dash.DashParser",zu);Bi["application/dash+xml"]=function(){return new zu};Bi["video/vnd.mpeg.dash.mpd"]=function(){return new zu};function bv(){}P("shaka.dependencies",bv);bv.has=function(a){return cv.has(a)};bv.add=function(a,b){if(!dv[a])throw Error(a+" is not supported");a==ev?xd("mux.js","mux.js is no longer used in Shaka Player."):cv.set(a,function(){return b})};var ev="muxjs",dv={Pl:ev,ISOBoxer:"ISOBoxer"};bv.Allowed=dv;var cv=new Map([["ISOBoxer",function(){return window.ISOBoxer}]]);function fv(a,b,c){this.type=a;this.g=b;this.segments=c||null}function gv(a,b,c,d){this.id=a;this.name=b;this.attributes=c;this.value=void 0===d?null:d}gv.prototype.toString=function(a){function b(e){return e.name+"="+(isNaN(Number(e.value))?'"'+e.value+'"':e.value)}var c="#"+this.name,d=this.attributes?this.attributes.filter(function(e){return a?!a.has(e.name):!0}).map(b):[];this.value&&d.unshift(this.value);0<d.length&&(c+=":"+d.join(","));return c};
991
- function hv(a){var b=(new Set).add("AUDIO").add("VIDEO").add("SUBTITLES").add("PATHWAY-ID").add("GROUP-ID").add("URI");return a.toString(b)}function iv(a,b){a=a.attributes.filter(function(c){return c.name==b});return a.length?a[0]:null}function Y(a,b,c){return(a=iv(a,b))?a.value:c||null}function jv(a,b){a=iv(a,b);if(!a)throw new U(2,4,4023,b);return a.value}function kv(a,b,c){c=void 0===c?[]:c;this.g=b;this.h=a;this.Rb=c}function lv(a,b){this.name=a;this.value=b};function mv(a,b){return a.filter(function(c){return c.name==b})}function nv(a,b){return a.filter(function(c){return jv(c,"TYPE")==b})}function ov(a,b){a=t(a);for(var c=a.next();!c.done;c=a.next())if(c=c.value,c.name===b)return c;return null}function pv(a,b,c){c=void 0===c?0:c;return(a=ov(a,b))?Number(a.value):c}function qv(a,b,c){return b?rv(a,[b],c):[]}
992
- function rv(a,b,c){if(!b.length)return[];b=Lc(a,b);a=[];b=t(b);for(var d=b.next();!d.done;d=b.next()){var e=a,f=e.push;var g=d.value;if((d=c)&&d.size){g=String(g).replace(/%7B/g,"{").replace(/%7D/g,"}");var h=g.match(/{\$\w*}/g);if(h){h=t(h);for(var k=h.next();!k.done;k=h.next()){k=k.value;var l=k.slice(2,k.length-1),m=d.get(l);if(m)g=g.replace(k,m);else throw new U(2,4,4039,l);}}d=g}else d=g;f.call(e,d)}return a};function sv(){this.g=0}
993
- function tv(a,b){b=wc(b);b=b.replace(/\r\n|\r(?=[^\n]|$)/gm,"\n").trim();var c=b.split(/\n+/m);if(!/^#EXTM3U($|[ \t\n])/m.test(c[0]))throw new U(2,4,4015);b=0;for(var d=!0,e=t(c),f=e.next();!f.done;f=e.next())if(f=f.value,/^#(?!EXT)/m.test(f)||d)d=!1;else if(f=uv(a,f),--a.g,vv.includes(f.name)){b=1;break}else"EXT-X-STREAM-INF"==f.name&&(d=!0);e=[];d=!0;for(f=0;f<c.length;f++){var g=c[f],h=c[f+1];if(/^#(?!EXT)/m.test(g)||d)d=!1;else{g=uv(a,g);if(wv.includes(g.name)){if(1!=b)throw new U(2,4,4017);g=
994
- c.splice(f,c.length-f);c=[];d=[];f=[];h=null;g=t(g);for(var k=g.next();!k.done;k=g.next())k=k.value,/^(#EXT)/.test(k)?(k=uv(a,k),vv.includes(k.name)?e.push(k):"EXT-X-MAP"==k.name?h=k:"EXT-X-PART"==k.name?f.push(k):"EXT-X-PRELOAD-HINT"==k.name?"PART"==Y(k,"TYPE")?f.push(k):"MAP"==Y(k,"TYPE")&&(k.name="EXT-X-MAP",h=k):d.push(k)):/^#(?!EXT)/m.test(k)||(k=k.trim(),h&&d.push(h),c.push(new kv(k,d,f)),d=[],f=[]);f.length&&(h&&d.push(h),c.push(new kv("",d,f)));return new fv(b,e,c)}e.push(g);"EXT-X-STREAM-INF"==
995
- g.name&&(g.attributes.push(new lv("URI",h)),d=!0)}}return new fv(b,e)}function uv(a,b){a=a.g++;var c=b.match(/^#(EXT[^:]*)(?::(.*))?$/);if(!c)throw new U(2,4,4016,b);b=c[1];var d=c[2];c=[];var e;if(d){d=new Kp(d);var f;(f=Mp(d,/^([^,=]+)(?:,|$)/g))&&(e=f[1]);for(var g=/([^=]+)=(?:"([^"]*)"|([^",]*))(?:,|$)/g;f=Mp(d,g);)c.push(new lv(f[1],f[2]||f[3])),Lp(d)}return new gv(a,b,c,e)}
996
- var vv="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".split(" "),wv="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 xv(){}function yv(a){try{var b=zv(a);return pg({uri:a,originalUri:a,data:b.data,headers:{"content-type":b.contentType}})}catch(c){return ng(c)}}
997
- function zv(a){var b=a.split(":");if(2>b.length||"data"!=b[0])throw new U(2,1,1004,a);b=b.slice(1).join(":").split(",");if(2>b.length)throw new U(2,1,1004,a);var c=b[0];a=window.decodeURIComponent(b.slice(1).join(","));b=c.split(";");c=b[0];var d=!1;1<b.length&&"base64"==b[b.length-1]&&(d=!0,b.pop());var e;d?e=Hc(a):e=Ac(a);return{data:e,contentType:c}}P("shaka.net.DataUriPlugin",xv);xv.parse=yv;wg("data",yv);function Av(){var a=this;this.g=this.h=null;this.F=1;this.u=new Map;this.J=new Map;this.O=new Map;this.O.set("video",new Map);this.O.set("audio",new Map);this.O.set(Sc,new Map);this.O.set("image",new Map);this.Ea=new Set;this.i=new Map;this.l=null;this.N="";this.Ba=new sv;this.K=-1;this.$=Infinity;this.Z=this.jb=!1;this.A=new Ub(function(){Bv(a)});this.na=Cv;this.o=null;this.Ha=0;this.m=Infinity;this.xa=this.qa=this.R=0;this.S=new tg;this.H=new Map;this.I=new Map;this.ba=new Map;this.ha=new Map;this.L=
998
- new Map;this.Aa=new Map;this.ma=new Map;this.Za=this.G=!1;this.Na=new ld(5);this.j=null;this.ea=!0}q=Av.prototype;q.configure=function(a){this.g=a;this.j&&this.j.configure(this.g)};q.start=function(a,b){var c=this,d;return O(function(e){return 1==e.g?(c.h=b,c.G=b.isLowLatencyMode(),E(e,Dv(c,[a]),2)):3!=e.g?(d=e.h,c.N=d.uri,E(e,Ev(c,d.data,a),3)):e.return(c.o)})};
989
+ function Tu(a,b,c,d,e){var f=d.attributes.schemeIdUri||"",g=d.attributes.value||"",h=th(d,"timescale",Bh)||1;d=t(kh(d,"Event"));for(var k=d.next();!k.done;k=d.next()){k=k.value;var l=th(k,"presentationTime",Bh)||0,m=th(k,"duration",Bh)||0;l=l/h+b;m=l+m/h;null!=c&&(l=Math.min(l,b+c),m=Math.min(m,b+c));m<e||(k={schemeIdUri:f,value:g,startTime:l,endTime:m,id:k.attributes.id||"",eventElement:Ih(k),eventNode:k},a.j.onTimelineRegionAdded(k))}}
990
+ function Qu(a,b,c,d,e){var f,g,h,k;return O(function(l){if(1==l.g)return f=Gg,g=e?0:1,h=Bl(b,c,d,a.g.retryParameters),E(l,Fu(a,h,f,{type:g}),2);k=l.h;return l.return(k.data)})}function Xu(a,b){b=te(a,b);return Ne(b)?Sc:a.split("/")[0]}function Fu(a,b,c,d){b=a.j.networkingEngine.request(c,b,d);ug(a.L,b);return b.promise}
991
+ function Eu(a){var b=a.l.ge;if(!a.l.Ze||!b||!a.F.length)return[];var c=Date.now()/1E3,d=a.F.filter(function(e){e=Bh(e.attributes.ttl);return!e||b+e>c}).map(mh).filter(We);return d.length?Lc(a.A,d):[]}P("shaka.dash.DashParser",Au);Bi["application/dash+xml"]=function(){return new Au};Bi["video/vnd.mpeg.dash.mpd"]=function(){return new Au};function cv(){}P("shaka.dependencies",cv);cv.has=function(a){return dv.has(a)};cv.add=function(a,b){if(!ev[a])throw Error(a+" is not supported");a==fv?xd("mux.js","mux.js is no longer used in Shaka Player."):dv.set(a,function(){return b})};var fv="muxjs",ev={Pl:fv,ISOBoxer:"ISOBoxer"};cv.Allowed=ev;var dv=new Map([["ISOBoxer",function(){return window.ISOBoxer}]]);function gv(a,b,c){this.type=a;this.g=b;this.segments=c||null}function hv(a,b,c,d){this.id=a;this.name=b;this.attributes=c;this.value=void 0===d?null:d}hv.prototype.toString=function(a){function b(e){return e.name+"="+(isNaN(Number(e.value))?'"'+e.value+'"':e.value)}var c="#"+this.name,d=this.attributes?this.attributes.filter(function(e){return a?!a.has(e.name):!0}).map(b):[];this.value&&d.unshift(this.value);0<d.length&&(c+=":"+d.join(","));return c};
992
+ function iv(a){var b=(new Set).add("AUDIO").add("VIDEO").add("SUBTITLES").add("PATHWAY-ID").add("GROUP-ID").add("URI");return a.toString(b)}function jv(a,b){a=a.attributes.filter(function(c){return c.name==b});return a.length?a[0]:null}function Y(a,b,c){return(a=jv(a,b))?a.value:c||null}function kv(a,b){a=jv(a,b);if(!a)throw new U(2,4,4023,b);return a.value}function lv(a,b,c){c=void 0===c?[]:c;this.g=b;this.h=a;this.Rb=c}function mv(a,b){this.name=a;this.value=b};function nv(a,b){return a.filter(function(c){return c.name==b})}function ov(a,b){return a.filter(function(c){return kv(c,"TYPE")==b})}function pv(a,b){a=t(a);for(var c=a.next();!c.done;c=a.next())if(c=c.value,c.name===b)return c;return null}function qv(a,b,c){c=void 0===c?0:c;return(a=pv(a,b))?Number(a.value):c}function rv(a,b,c){return b?sv(a,[b],c):[]}
993
+ function sv(a,b,c){if(!b.length)return[];b=Lc(a,b);a=[];b=t(b);for(var d=b.next();!d.done;d=b.next()){var e=a,f=e.push;var g=d.value;if((d=c)&&d.size){g=String(g).replace(/%7B/g,"{").replace(/%7D/g,"}");var h=g.match(/{\$\w*}/g);if(h){h=t(h);for(var k=h.next();!k.done;k=h.next()){k=k.value;var l=k.slice(2,k.length-1),m=d.get(l);if(m)g=g.replace(k,m);else throw new U(2,4,4039,l);}}d=g}else d=g;f.call(e,d)}return a};function tv(){this.g=0}
994
+ function uv(a,b){b=wc(b);b=b.replace(/\r\n|\r(?=[^\n]|$)/gm,"\n").trim();var c=b.split(/\n+/m);if(!/^#EXTM3U($|[ \t\n])/m.test(c[0]))throw new U(2,4,4015);b=0;for(var d=!0,e=t(c),f=e.next();!f.done;f=e.next())if(f=f.value,/^#(?!EXT)/m.test(f)||d)d=!1;else if(f=vv(a,f),--a.g,wv.includes(f.name)){b=1;break}else"EXT-X-STREAM-INF"==f.name&&(d=!0);e=[];d=!0;for(f=0;f<c.length;f++){var g=c[f],h=c[f+1];if(/^#(?!EXT)/m.test(g)||d)d=!1;else{g=vv(a,g);if(xv.includes(g.name)){if(1!=b)throw new U(2,4,4017);g=
995
+ c.splice(f,c.length-f);c=[];d=[];f=[];h=null;g=t(g);for(var k=g.next();!k.done;k=g.next())k=k.value,/^(#EXT)/.test(k)?(k=vv(a,k),wv.includes(k.name)?e.push(k):"EXT-X-MAP"==k.name?h=k:"EXT-X-PART"==k.name?f.push(k):"EXT-X-PRELOAD-HINT"==k.name?"PART"==Y(k,"TYPE")?f.push(k):"MAP"==Y(k,"TYPE")&&(k.name="EXT-X-MAP",h=k):d.push(k)):/^#(?!EXT)/m.test(k)||(k=k.trim(),h&&d.push(h),c.push(new lv(k,d,f)),d=[],f=[]);f.length&&(h&&d.push(h),c.push(new lv("",d,f)));return new gv(b,e,c)}e.push(g);"EXT-X-STREAM-INF"==
996
+ g.name&&(g.attributes.push(new mv("URI",h)),d=!0)}}return new gv(b,e)}function vv(a,b){a=a.g++;var c=b.match(/^#(EXT[^:]*)(?::(.*))?$/);if(!c)throw new U(2,4,4016,b);b=c[1];var d=c[2];c=[];var e;if(d){d=new Kp(d);var f;(f=Mp(d,/^([^,=]+)(?:,|$)/g))&&(e=f[1]);for(var g=/([^=]+)=(?:"([^"]*)"|([^",]*))(?:,|$)/g;f=Mp(d,g);)c.push(new mv(f[1],f[2]||f[3])),Lp(d)}return new hv(a,b,c,e)}
997
+ var wv="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".split(" "),xv="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 yv(){}function zv(a){try{var b=Av(a);return pg({uri:a,originalUri:a,data:b.data,headers:{"content-type":b.contentType}})}catch(c){return ng(c)}}
998
+ function Av(a){var b=a.split(":");if(2>b.length||"data"!=b[0])throw new U(2,1,1004,a);b=b.slice(1).join(":").split(",");if(2>b.length)throw new U(2,1,1004,a);var c=b[0];a=window.decodeURIComponent(b.slice(1).join(","));b=c.split(";");c=b[0];var d=!1;1<b.length&&"base64"==b[b.length-1]&&(d=!0,b.pop());var e;d?e=Hc(a):e=Ac(a);return{data:e,contentType:c}}P("shaka.net.DataUriPlugin",yv);yv.parse=zv;wg("data",zv);function Bv(){var a=this;this.g=this.h=null;this.F=1;this.u=new Map;this.J=new Map;this.O=new Map;this.O.set("video",new Map);this.O.set("audio",new Map);this.O.set(Sc,new Map);this.O.set("image",new Map);this.Ea=new Set;this.i=new Map;this.l=null;this.N="";this.Ba=new tv;this.K=-1;this.$=Infinity;this.X=this.jb=!1;this.A=new Ub(function(){Cv(a)});this.na=Dv;this.o=null;this.Ha=0;this.m=Infinity;this.xa=this.qa=this.R=0;this.S=new tg;this.H=new Map;this.I=new Map;this.ba=new Map;this.ha=new Map;this.L=
999
+ new Map;this.Aa=new Map;this.ma=new Map;this.Za=this.G=!1;this.Na=new ld(5);this.j=null;this.ea=!0}q=Bv.prototype;q.configure=function(a){this.g=a;this.j&&this.j.configure(this.g)};q.start=function(a,b){var c=this,d;return O(function(e){return 1==e.g?(c.h=b,c.G=b.isLowLatencyMode(),E(e,Ev(c,[a]),2)):3!=e.g?(d=e.h,c.N=d.uri,E(e,Fv(c,d.data,a),3)):e.return(c.o)})};
999
1000
  q.stop=function(){this.A&&(this.A.stop(),this.A=null);var a=[];this.S&&(a.push(this.S.destroy()),this.S=null);this.g=this.h=null;this.Ea.clear();this.o=null;this.i.clear();this.J.clear();this.I.clear();this.u.clear();this.ba.clear();this.ha.clear();this.L.clear();this.Aa.clear();this.ma.clear();this.j&&this.j.destroy();return Promise.all(a)};
1000
- q.update=function(){var a=this,b,c,d,e,f,g,h,k,l;return O(function(m){if(1==m.g){if(!Fv(a))return m.return();b=[];c=Array.from(a.i.values());a.m=Infinity;d=c.filter(function(n){return n.stream.segmentIndex});e=t(d);for(f=e.next();!f.done;f=e.next())g=f.value,b.push(Gv(a,g));return E(m,Promise.all(b),2)}Hv(a,d.map(function(n){return n.stream}));h=d.some(function(n){return 0==n.Td});d.length&&!h&&(k=Iv,Jv(a,k.Ci),l=d.map(function(n){return n.Xb}),a.l.sb(Math.min.apply(Math,x(l))),a.h.updateDuration());
1001
- h&&Kv(a);F(m)})};function Lv(a,b){return Fv(a)?a.O.get(b.type):b.We}
1002
- function Gv(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q;return O(function(T){if(1==T.g){c=[];d=t(b.P());for(e=d.next();!e.done;e=d.next())f=e.value,g=new mb(f),h=g.g,b.De&&(0<=b.Fb&&h.add("_HLS_msn",String(b.Fb)),0<=b.Gb&&h.add("_HLS_part",String(b.Gb))),b.Ee&&h.add("_HLS_skip","YES"),Cb(h)&&qb(g,h),c.push(g.toString());return E(T,Dv(a,c,!0),2)}if(3!=T.g){k=T.h;if(!b.stream.segmentIndex)return T.return();l=tv(a.Ba,k.data);if(1!=l.type)throw new U(2,4,4017);m=k.uri;m==k.originalUri||
1003
- b.P().includes(m)||b.Yh.push(m);n=mv(l.g,"EXT-X-DEFINE");p=Mv(a,n,m);r=b.stream;u=Lv(a,b);return E(T,Nv(a,l,r.mimeType,b.P,p),3)}v=T.h;w=v.keyIds;A=v.drmInfos;z=function(R,ra){return R.size===ra.size&&[].concat(x(R)).every(function(sa){return ra.has(sa)})};z(r.keyIds,w)||(r.keyIds=w,r.drmInfos=A,a.h.newDrmInfo(r));C=Ov(a,l,u,p,b.P,b.type);y=C.segments;if(B=C.bandwidth)r.bandwidth=B;r.segmentIndex.ae(y,a.l.Cb());y.length&&(D=pv(l.g,"EXT-X-MEDIA-SEQUENCE",0),G=(K=ov(l.g,"EXT-X-SKIP"))?Number(Y(K,"SKIPPED-SEGMENTS")):
1004
- 0,J=Pv(D,y),I=J.Fb,H=J.Gb,b.Fb=I+G,b.Gb=H,N=u.get(D),r.segmentIndex.eb(N));L=r.segmentIndex.g[0]||null;b.Hc=L.startTime;M=y[y.length-1];b.Xb=M.endTime;if(Q=ov(l.g,"EXT-X-ENDLIST"))b.Td=!0;Qv(a,l);F(T)})}q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(){};q.banLocation=function(a){this.j&&this.j.banLocation(a)};
1005
- function Rv(a,b){for(var c=-1==a.K,d=t(b),e=d.next();!e.done;e=d.next()){e=e.value;var f=e.stream.segmentIndex,g=Lv(a,e);if(f=f.g[0]||null){g=t(g);for(var h=g.next();!h.done;h=g.next()){h=t(h.value);var k=h.next().value;if(h.next().value==f.startTime){c&&(a.K=Math.max(a.K,k));e.$f=k;break}}}}if(!(0>a.K))for(b=t(b),e=b.next();!e.done;e=b.next())if(c=e.value,Sv(a,c.type)&&(d=c.stream.segmentIndex))if(e=a.K-c.$f,0<e&&(d.g.splice(0,e),d=d.g[0]||null))d=-d.startTime,c.stream.segmentIndex.offset(d),Tv(a,
1001
+ q.update=function(){var a=this,b,c,d,e,f,g,h,k,l;return O(function(m){if(1==m.g){if(!Gv(a))return m.return();b=[];c=Array.from(a.i.values());a.m=Infinity;d=c.filter(function(n){return n.stream.segmentIndex});e=t(d);for(f=e.next();!f.done;f=e.next())g=f.value,b.push(Hv(a,g));return E(m,Promise.all(b),2)}Iv(a,d.map(function(n){return n.stream}));h=d.some(function(n){return 0==n.Td});d.length&&!h&&(k=Jv,Kv(a,k.Ci),l=d.map(function(n){return n.Xb}),a.l.sb(Math.min.apply(Math,x(l))),a.h.updateDuration());
1002
+ h&&Lv(a);F(m)})};function Mv(a,b){return Gv(a)?a.O.get(b.type):b.We}
1003
+ function Hv(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q;return O(function(T){if(1==T.g){c=[];d=t(b.P());for(e=d.next();!e.done;e=d.next())f=e.value,g=new mb(f),h=g.g,b.De&&(0<=b.Fb&&h.add("_HLS_msn",String(b.Fb)),0<=b.Gb&&h.add("_HLS_part",String(b.Gb))),b.Ee&&h.add("_HLS_skip","YES"),Cb(h)&&qb(g,h),c.push(g.toString());return E(T,Ev(a,c,!0),2)}if(3!=T.g){k=T.h;if(!b.stream.segmentIndex)return T.return();l=uv(a.Ba,k.data);if(1!=l.type)throw new U(2,4,4017);m=k.uri;m==k.originalUri||
1004
+ b.P().includes(m)||b.Yh.push(m);n=nv(l.g,"EXT-X-DEFINE");p=Nv(a,n,m);r=b.stream;u=Mv(a,b);return E(T,Ov(a,l,r.mimeType,b.P,p),3)}v=T.h;w=v.keyIds;A=v.drmInfos;z=function(R,ra){return R.size===ra.size&&[].concat(x(R)).every(function(sa){return ra.has(sa)})};z(r.keyIds,w)||(r.keyIds=w,r.drmInfos=A,a.h.newDrmInfo(r));C=Pv(a,l,u,p,b.P,b.type);y=C.segments;if(B=C.bandwidth)r.bandwidth=B;r.segmentIndex.ae(y,a.l.Cb());y.length&&(D=qv(l.g,"EXT-X-MEDIA-SEQUENCE",0),G=(K=pv(l.g,"EXT-X-SKIP"))?Number(Y(K,"SKIPPED-SEGMENTS")):
1005
+ 0,J=Qv(D,y),I=J.Fb,H=J.Gb,b.Fb=I+G,b.Gb=H,N=u.get(D),r.segmentIndex.eb(N));L=r.segmentIndex.g[0]||null;b.Ic=L.startTime;M=y[y.length-1];b.Xb=M.endTime;if(Q=pv(l.g,"EXT-X-ENDLIST"))b.Td=!0;Rv(a,l);F(T)})}q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(){};q.banLocation=function(a){this.j&&this.j.banLocation(a)};
1006
+ function Sv(a,b){for(var c=-1==a.K,d=t(b),e=d.next();!e.done;e=d.next()){e=e.value;var f=e.stream.segmentIndex,g=Mv(a,e);if(f=f.g[0]||null){g=t(g);for(var h=g.next();!h.done;h=g.next()){h=t(h.value);var k=h.next().value;if(h.next().value==f.startTime){c&&(a.K=Math.max(a.K,k));e.$f=k;break}}}}if(!(0>a.K))for(b=t(b),e=b.next();!e.done;e=b.next())if(c=e.value,Tv(a,c.type)&&(d=c.stream.segmentIndex))if(e=a.K-c.$f,0<e&&(d.g.splice(0,e),d=d.g[0]||null))d=-d.startTime,c.stream.segmentIndex.offset(d),Uv(a,
1006
1007
  c,d)}
1007
- function Uv(a,b){if(Infinity==a.$){b=t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value.stream.segmentIndex.g[0]||null;null!=d&&null!=d.h&&(a.$=Math.min(a.$,d.h))}}b=a.$;if(Infinity!=b)for(d=t(a.i.values()),c=d.next();!c.done;c=d.next())if(c=c.value,!Sv(a,c.type)){var e=c.stream.segmentIndex;if(null!=e){var f=e.g[0]||null;if(null==f.h)Xa("Missing EXT-X-PROGRAM-DATE-TIME for stream",c.P(),"Expect AV sync issues!");else for(Tv(a,c,f.h-b-f.startTime),c=t(e),e=c.next();!e.done;e=c.next())e.value.fh(b)}}}
1008
- function Tv(a,b,c){b.Hc+=c;b.Xb+=c;a=Lv(a,b);for(var d=t(a),e=d.next();!e.done;e=d.next()){var f=t(e.value);e=f.next().value;f=f.next().value;a.set(e,f+c)}b.P()}
1009
- function Ev(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q,T,R,ra,sa,Ca,Ea,Ia,Pa,Ja,db;return O(function(Fa){switch(Fa.g){case 1:d=tv(a.Ba,b);e=mv(d.g,"EXT-X-DEFINE");f=[];g=[];h=[];a.l=new Bk(null,0);a.l.Lc(!0);k=function(){return[c]};if(1==d.type)return a.ea=!1,w=mv(d.g,"EXT-X-DEFINE"),A=Mv(a,w,a.N),E(Fa,Vv(a,d,k,A),7);Wv(a,e);l=mv(d.g,"EXT-X-MEDIA");m=mv(d.g,"EXT-X-STREAM-INF");n=mv(d.g,"EXT-X-IMAGE-STREAM-INF");p=mv(d.g,"EXT-X-I-FRAME-STREAM-INF");r=mv(d.g,"EXT-X-SESSION-KEY");
1010
- u=mv(d.g,"EXT-X-SESSION-DATA");v=mv(d.g,"EXT-X-CONTENT-STEERING");Xv(a,u);return E(Fa,Yv(a,v),4);case 4:return Zv(a,m),$v(a,l),E(Fa,aw(a,m,r,l,k,a.u),5);case 5:return f=Fa.h,g=bw(a,l),E(Fa,cw(a,n,p),6);case 6:h=Fa.h;Fa.B(3);break;case 7:return z=Fa.h,C=z.type,y=z.mimeType,B=z.codecs,D=z.language,K=z.height,G=z.width,J=z.channelCount,I=z.sampleRate,H=z.closedCaptions,N=z.oe,L=z.colorGamut,E(Fa,dw(a,a.F++,A,d,k,B,C,D,!0,"Media Playlist",J,H,null,!1,I,!1,y),8);case 8:M=Fa.h,a.i.set(c,M),"video"==C&&
1011
- ew(M.stream,G,K,null,N,null,L),f.push({id:0,language:Xc(D||"und"),disabledUntilTime:0,primary:!0,audio:"audio"==C?M.stream:null,video:"video"==C?M.stream:null,bandwidth:M.stream.bandwidth||0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});case 3:if(!a.h)throw new U(2,7,7001);1==d.type&&(Fv(a)&&(fw(a,d),Q=a.m,a.A.V(Q)),T=Array.from(a.i.values()),gw(a,T),Kv(a));a.o={presentationTimeline:a.l,variants:f,textStreams:g,imageStreams:h,offlineSessionIds:[],minBufferTime:0,sequenceMode:a.g.hls.sequenceMode,
1012
- ignoreManifestTimestampsInSegmentsMode:a.g.hls.ignoreManifestTimestampsInSegmentsMode,type:"HLS",serviceDescription:null,nextUrl:null};if(a.Z||!a.g.hls.disableCodecGuessing){Fa.B(9);break}R=[];ra=t(a.o.variants);for(sa=ra.next();!sa.done;sa=ra.next())Ca=sa.value,Ca.audio&&""===Ca.audio.codecs&&R.push(Ca.audio.createSegmentIndex()),Ca.video&&""===Ca.video.codecs&&R.push(Ca.video.createSegmentIndex());return E(Fa,Promise.all(R),9);case 9:a.h.makeTextStreamsForClosedCaptions(a.o);if(1==f.length){Ea=
1013
- [];Ia=f[0];Pa=t([Ia.video,Ia.audio]);for(Ja=Pa.next();!Ja.done;Ja=Pa.next())(db=Ja.value)&&!db.segmentIndex&&Ea.push(db.createSegmentIndex());if(0<Ea.length)return E(Fa,Promise.all(Ea),0)}Fa.B(0)}})}
1014
- function Vv(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G;return O(function(J){switch(J.g){case 1:e=Dt(a.g.hls.mediaPlaylistFullMimeType);if(!b.segments.length)return J.return(e);f=b.segments[0];g=qv(c(),f.h,d);h=g[0];k=new mb(h);l=k.pb.split(".").pop();if(m=hw[l])return J.return(Dt(m));n=Gg;p=null;r=iw(a,b,f.g,c,d);a.ba.clear();if(!r){J.B(2);break}u=Bl(r.P(),r.Pb(),r.Nb(),a.g.retryParameters);return E(J,jw(a,u,n,{type:0}),3);case 3:v=J.h,p=v.data;case 2:w=0;A=null;if(z=ov(f.g,"EXT-X-BYTERANGE"))C=
1015
- t(kw(null,z.value)),w=C.next().value,A=C.next().value;y=Bl(g,w,A,a.g.retryParameters);return E(J,jw(a,y,n,{type:1}),4);case 4:B=J.h;(D=B.headers["content-type"])&&(D=D.split(";")[0].toLowerCase());if("ts"==l||"video/mp2t"==D){var I=B.data;var H=Gb(I);H=(new vj).parse(H);var N=H.Od();H=H.wg();var L=[],M=!1,Q=!1;switch(N.audio){case "aac":case "aac-loas":L.push("mp4a.40.2");M=!0;break;case "mp3":L.push("mp4a.40.34");M=!0;break;case "ac3":L.push("ac-3");M=!0;break;case "ec3":L.push("ec-3");M=!0;break;
1008
+ function Vv(a,b){if(Infinity==a.$){b=t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value.stream.segmentIndex.g[0]||null;null!=d&&null!=d.h&&(a.$=Math.min(a.$,d.h))}}b=a.$;if(Infinity!=b)for(d=t(a.i.values()),c=d.next();!c.done;c=d.next())if(c=c.value,!Tv(a,c.type)){var e=c.stream.segmentIndex;if(null!=e){var f=e.g[0]||null;if(null==f.h)Xa("Missing EXT-X-PROGRAM-DATE-TIME for stream",c.P(),"Expect AV sync issues!");else for(Uv(a,c,f.h-b-f.startTime),c=t(e),e=c.next();!e.done;e=c.next())e.value.fh(b)}}}
1009
+ function Uv(a,b,c){b.Ic+=c;b.Xb+=c;a=Mv(a,b);for(var d=t(a),e=d.next();!e.done;e=d.next()){var f=t(e.value);e=f.next().value;f=f.next().value;a.set(e,f+c)}b.P()}
1010
+ function Fv(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q,T,R,ra,sa,Ca,Fa,Ia,Pa,Ja,db;return O(function(Da){switch(Da.g){case 1:d=uv(a.Ba,b);e=nv(d.g,"EXT-X-DEFINE");f=[];g=[];h=[];a.l=new Bk(null,0);a.l.Mc(!0);k=function(){return[c]};if(1==d.type)return a.ea=!1,w=nv(d.g,"EXT-X-DEFINE"),A=Nv(a,w,a.N),E(Da,Wv(a,d,k,A),7);Xv(a,e);l=nv(d.g,"EXT-X-MEDIA");m=nv(d.g,"EXT-X-STREAM-INF");n=nv(d.g,"EXT-X-IMAGE-STREAM-INF");p=nv(d.g,"EXT-X-I-FRAME-STREAM-INF");r=nv(d.g,"EXT-X-SESSION-KEY");
1011
+ u=nv(d.g,"EXT-X-SESSION-DATA");v=nv(d.g,"EXT-X-CONTENT-STEERING");Yv(a,u);return E(Da,Zv(a,v),4);case 4:return $v(a,m),aw(a,l),E(Da,bw(a,m,r,l,k,a.u),5);case 5:return f=Da.h,g=cw(a,l),E(Da,dw(a,n,p),6);case 6:h=Da.h;Da.B(3);break;case 7:return z=Da.h,C=z.type,y=z.mimeType,B=z.codecs,D=z.language,K=z.height,G=z.width,J=z.channelCount,I=z.sampleRate,H=z.closedCaptions,N=z.oe,L=z.colorGamut,E(Da,ew(a,a.F++,A,d,k,B,C,D,!0,"Media Playlist",J,H,null,!1,I,!1,y),8);case 8:M=Da.h,a.i.set(c,M),"video"==C&&
1012
+ fw(M.stream,G,K,null,N,null,L),f.push({id:0,language:Xc(D||"und"),disabledUntilTime:0,primary:!0,audio:"audio"==C?M.stream:null,video:"video"==C?M.stream:null,bandwidth:M.stream.bandwidth||0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});case 3:if(!a.h)throw new U(2,7,7001);1==d.type&&(Gv(a)&&(gw(a,d),Q=a.m,a.A.V(Q)),T=Array.from(a.i.values()),hw(a,T),Lv(a));a.o={presentationTimeline:a.l,variants:f,textStreams:g,imageStreams:h,offlineSessionIds:[],minBufferTime:0,sequenceMode:a.g.hls.sequenceMode,
1013
+ ignoreManifestTimestampsInSegmentsMode:a.g.hls.ignoreManifestTimestampsInSegmentsMode,type:"HLS",serviceDescription:null,nextUrl:null};if(a.X||!a.g.hls.disableCodecGuessing){Da.B(9);break}R=[];ra=t(a.o.variants);for(sa=ra.next();!sa.done;sa=ra.next())Ca=sa.value,Ca.audio&&""===Ca.audio.codecs&&R.push(Ca.audio.createSegmentIndex()),Ca.video&&""===Ca.video.codecs&&R.push(Ca.video.createSegmentIndex());return E(Da,Promise.all(R),9);case 9:a.h.makeTextStreamsForClosedCaptions(a.o);if(1==f.length){Fa=
1014
+ [];Ia=f[0];Pa=t([Ia.video,Ia.audio]);for(Ja=Pa.next();!Ja.done;Ja=Pa.next())(db=Ja.value)&&!db.segmentIndex&&Fa.push(db.createSegmentIndex());if(0<Fa.length)return E(Da,Promise.all(Fa),0)}Da.B(0)}})}
1015
+ function Wv(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G;return O(function(J){switch(J.g){case 1:e=Dt(a.g.hls.mediaPlaylistFullMimeType);if(!b.segments.length)return J.return(e);f=b.segments[0];g=rv(c(),f.h,d);h=g[0];k=new mb(h);l=k.pb.split(".").pop();if(m=iw[l])return J.return(Dt(m));n=Gg;p=null;r=jw(a,b,f.g,c,d);a.ba.clear();if(!r){J.B(2);break}u=Bl(r.P(),r.Pb(),r.Nb(),a.g.retryParameters);return E(J,kw(a,u,n,{type:0}),3);case 3:v=J.h,p=v.data;case 2:w=0;A=null;if(z=pv(f.g,"EXT-X-BYTERANGE"))C=
1016
+ t(lw(null,z.value)),w=C.next().value,A=C.next().value;y=Bl(g,w,A,a.g.retryParameters);return E(J,kw(a,y,n,{type:1}),4);case 4:B=J.h;(D=B.headers["content-type"])&&(D=D.split(";")[0].toLowerCase());if("ts"==l||"video/mp2t"==D){var I=B.data;var H=Gb(I);H=(new vj).parse(H);var N=H.Od();H=H.wg();var L=[],M=!1,Q=!1;switch(N.audio){case "aac":case "aac-loas":L.push("mp4a.40.2");M=!0;break;case "mp3":L.push("mp4a.40.34");M=!0;break;case "ac3":L.push("ac-3");M=!0;break;case "ec3":L.push("ec-3");M=!0;break;
1016
1017
  case "opus":L.push("opus"),M=!0}switch(N.video){case "avc":H.cb?L.push(H.cb):L.push("avc1.42E01E");Q=!0;break;case "hvc":H.cb?L.push(H.cb):L.push("hvc1.1.6.L93.90");Q=!0;break;case "av1":L.push("av01.0.01M.08"),Q=!0}if(L.length){N=M&&!Q;M=new Map;if(Q){Q=new Ed("video/mp2t");Q.i(I);I=t(Q.j());for(var T=I.next();!T.done;T=I.next())T=T.value,M.set(T,T);Q.g()}H={type:N?"audio":"video",mimeType:"video/mp2t",codecs:L.join(", "),language:null,height:H.height,width:H.width,channelCount:null,sampleRate:null,
1017
1018
  closedCaptions:M,oe:null,colorGamut:null}}else H=null;if(K=H)return J.return(K)}else if("mp4"==l||"cmfv"==l||"m4s"==l||"fmp4"==l||"video/mp4"==D||"audio/mp4"==D||"video/iso.segment"==D)if(G=Et(p,B.data))return J.return(G);return J.return(e)}})}
1018
- function Kv(a){if(Fv(a)){if(a.na==lw){for(var b,c=b=Infinity,d=t(a.i.values()),e=d.next();!e.done;e=d.next())e=e.value,e.stream.segmentIndex&&"text"!=e.stream.type&&(b=Math.min(b,e.Xb),c=Math.min(c,e.Hc));b-=c;a.g.hls.useSafariBehaviorForLive&&(b=a.l.u);isNaN(a.g.availabilityWindowOverride)||(b=a.g.availabilityWindowOverride);a.l.nf(b)}}else a.l.sb(mw(a));if(!a.l.o)for(b=t(a.i.values()),c=b.next();!c.done;c=b.next())c=c.value,!c.stream.segmentIndex||"audio"!=c.type&&"video"!=c.type||(c=c.stream.segmentIndex.get(0))&&
1019
- c.h&&a.l.ei(c.h);a.l.Ue()}function Wv(a,b){var c=(new mb(a.N)).g;b=t(b);for(var d=b.next();!d.done;d=b.next()){var e=d.value;d=Y(e,"NAME");var f=Y(e,"VALUE");e=Y(e,"QUERYPARAM");d&&f&&(a.u.has(d)||a.u.set(d,f));e&&(d=c.get(e)[0])&&!a.u.has(d)&&a.u.set(e,d)}}
1020
- function Mv(a,b,c){c=(new mb(c)).g;var d=new Map;b=t(b);for(var e=b.next();!e.done;e=b.next()){var f=e.value,g=Y(f,"NAME"),h=Y(f,"VALUE");e=Y(f,"QUERYPARAM");f=Y(f,"IMPORT");g&&h&&(d.has(g)||d.set(g,h));e&&(g=c.get(e)[0])&&!d.has(g)&&d.set(e,g);f&&(e=a.u.get(f))&&d.set(f,e)}return d}
1021
- function Zv(a,b){b=t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value,e=Y(d,"AUDIO");c=Y(d,"VIDEO");var f=Y(d,"SUBTITLES");d=nw(a,d);if(f){var g=Pc(Sc,d);a.I.set(f,g);Od(d,g)}e&&(f=Pc("audio",d),f||(f=a.g.hls.defaultAudioCodec),a.I.set(e,f));c&&(e=Pc("video",d),e||(e=a.g.hls.defaultVideoCodec),a.I.set(c,e))}}
1022
- function Xv(a,b){b=t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value,e=Y(d,"DATA-ID");c=Y(d,"URI");var f=Y(d,"LANGUAGE");d=Y(d,"VALUE");e=(new Map).set("id",e);c&&e.set("uri",qv([a.N],c,a.u)[0]);f&&e.set("language",f);d&&e.set("value",d);c=new S("sessiondata",e);if(a.h)a.h.onEvent(c)}}
1023
- function Yv(a,b){var c,d,e,f,g,h;return O(function(k){if(!a.h||!a.g)return k.return();d=t(b);for(e=d.next();!e.done;e=d.next())if(f=e.value,g=Y(f,"PATHWAY-ID"),h=Y(f,"SERVER-URI"),g&&h){a.j=new It(a.h);a.j.configure(a.g);a.j.i=[a.N];a.j.setManifestType("HLS");a.j.h=g;c=Jt(a.j,h);break}return E(k,c,0)})}
1024
- function bw(a,b){var c=nv(b,"SUBTITLES");b=c.map(function(g){if(a.g.disableText)return null;try{return ow(a,[g],new Map).stream}catch(h){if(a.g.hls.ignoreTextStreamFailures)return null;throw h;}});c=t(c);for(var d=c.next();!d.done;d=c.next()){var e=jv(d.value,"GROUP-ID");if(d=a.I.get(e))if(e=a.J.get(e)){e=t(e);for(var f=e.next();!f.done;f=e.next())f=f.value,f.stream.codecs=d,f.stream.mimeType=pw(Sc,d)||qw(Sc),rw(f.stream)}}return b.filter(function(g){return g})}
1025
- function rw(a){a.fullMimeTypes=new Set([te(a.mimeType,a.codecs)])}
1026
- function cw(a,b,c){var d,e;return O(function(f){if(1==f.g)return d=b.map(function(g){var h,k,l;return O(function(m){if(1==m.g){if(h=a.g.disableThumbnails)return m.return(null);ta(m,2);return E(m,sw(a,g),4)}if(2!=m.g)return k=m.h,m.return(k.stream);l=wa(m);if(a.g.hls.ignoreImageStreamFailures)return m.return(null);throw l;})}).concat(c.map(function(g){if(a.g.disableThumbnails)return null;try{var h=jv(g,"URI"),k=Y(g,"CODECS")||"";if(a.i.has(h))var l=a.i.get(h);else{var m=Y(g,"LANGUAGE"),n=Y(g,"NAME"),
1027
- p=Y(g,"CHARACTERISTICS"),r=tw(a,a.F++,[h],k,"image",m,!1,n,null,null,p,!1,null,!1),u=Y(g,"RESOLUTION"),v=t(u?u.split("x"):[null,null]),w=v.next().value,A=v.next().value;r.stream.width=Number(w)||void 0;r.stream.height=Number(A)||void 0;var z=Y(g,"BANDWIDTH");z&&(r.stream.bandwidth=Number(z));a.i.set(h,r);l=r}g=l;return"mjpg"!==g.stream.codecs?null:g.stream}catch(C){if(a.g.hls.ignoreImageStreamFailures)return null;throw C;}})),E(f,Promise.all(d),2);e=f.h;return f.return(e.filter(function(g){return g}))})}
1028
- function uw(a,b,c){b=b.filter(function(h){var k=Y(h,"URI")||"";return"SUBTITLES"!=Y(h,"TYPE")&&""!=k});var d={};b=t(b);for(var e=b.next();!e.done;e=b.next()){e=e.value;var f=hv(e);d[f]?d[f].push(e):d[f]=[e]}for(var g in d)ow(a,d[g],c)}
1029
- function aw(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q,T,R,ra,sa,Ca,Ea,Ia,Pa,Ja;return O(function(db){switch(db.g){case 1:g=[];h=new Set;if(!(0<c.length)){db.B(2);break}k=t(c);l=k.next();case 3:if(l.done){db.B(2);break}m=l.value;n=jv(m,"METHOD");p=Y(m,"KEYFORMAT")||"identity";r=null;if("NONE"==n){db.B(4);break}if(vw(n)){u=qv(e(),jv(m,"URI"),f);v=u.sort().join("");a.L.has(v)||(w=Ag(u,a.g.retryParameters),A=jw(a,w,6),a.L.set(v,A));db.B(4);break}if("identity"!=p){r=(z=ww[p])?
1030
- z(m,""):null;db.B(6);break}return E(db,xw(a,m,"",e,null,f),9);case 9:r=db.h;case 6:if(r){if(r.keyIds)for(C=t(r.keyIds),y=C.next();!y.done;y=C.next())B=y.value,h.add(B);g.push(r)}case 4:l=k.next();db.B(3);break;case 2:D={};K=t(b);for(G=K.next();!G.done;G=K.next())J=G.value,I=hv(J),D[I]?D[I].push(J):D[I]=[J];H=[];for(N in D)L=D[N],M=L[0],Q=Y(M,"FRAME-RATE"),T=Number(Y(M,"AVERAGE-BANDWIDTH"))||Number(jv(M,"BANDWIDTH")),R=Y(M,"RESOLUTION"),ra=t(R?R.split("x"):[null,null]),sa=ra.next().value,Ca=ra.next().value,
1031
- Ea=Y(M,"VIDEO-RANGE"),(Ia=Y(M,"REQ-VIDEO-LAYOUT"))&&Ia.includes(",")&&(Pa=Ia.split(",").filter(function(Fa){return"CH-STEREO"==Fa||"CH-MONO"==Fa}),Ia=Pa[0]),Ia=Ia||"CH-MONO",Ja=yw(a,L,d),H.push.apply(H,x(zw(a,Ja.audio,Ja.video,T,sa,Ca,Q,Ea,Ia,g,h)));return db.return(H.filter(function(Fa){return null!=Fa}))}})}
1032
- function yw(a,b,c){for(var d={audio:[],video:[]},e=new Map,f=[],g=!1,h=!1,k=t(b),l=k.next();!l.done;l=k.next()){var m=l.value;l=Y(m,"AUDIO");var n=Y(m,"VIDEO"),p=l||n;p&&(f.includes(p)||f.push(p),(m=Y(m,"PATHWAY-ID"))&&e.set(p,m),l?g=!0:n&&(h=!0))}f.length&&c.length&&(k=c.filter(function(v){return f.includes(jv(v,"GROUP-ID"))}),uw(a,k,e));k=(e=f.sort().join(","))&&a.J.has(e)?a.J.get(e):[];g?d.audio.push.apply(d.audio,x(k)):h&&d.video.push.apply(d.video,x(k));l=!1;var r=b.map(function(v){return jv(v,
1033
- "URI")});h=d.audio.find(function(v){return v&&v.P().find(function(w){return r.includes(w)})});g=nw(a,b[0]);n=Pc("video",g);(p=Pc("audio",g))&&!n?(h="audio",l=0<d.audio.length):!d.audio.length&&!d.video.length&&p&&n?(h="video",g=[[n,p].join()]):d.audio.length&&h?(h="audio",l=!0):h=d.video.length&&!d.audio.length?"audio":"video";if(!l){var u=m=p=n=l=null;!k.length&&(c=c.find(function(v){var w=Y(v,"URI")||"",A=Y(v,"TYPE");v=jv(v,"GROUP-ID");return"SUBTITLES"!=A&&""==w&&f.includes(v)}))&&(l=Y(c,"LANGUAGE"),
1034
- n=Y(c,"NAME"),p=Aw(c),Bw(c),m=Y(c,"CHARACTERISTICS"),u=Cw(c));a=Dw(a,b,g,h,l,n,p,m,u);e&&(a.stream.groupId=e);d[a.stream.type]=[a]}return d}
1035
- function nw(a,b){var c=Y(b,"CODECS")||"";b=Y(b,"SUPPLEMENTAL-CODECS");a.Z=0<c.length;a.Z||a.g.hls.disableCodecGuessing||(c=[],a.g.disableVideo||c.push(a.g.hls.defaultVideoCodec),a.g.disableAudio||c.push(a.g.hls.defaultAudioCodec),c=c.join(","));a=c.split(/\s*,\s*/);b&&(b=b.split(/\s*,\s*/).map(function(d){return d.split("/")[0]}),a.push.apply(a,x(b)));return Ft(a)}function Aw(a){return(a=Y(a,"CHANNELS"))?parseInt(a.split("/")[0],10):null}
1036
- function Cw(a){return(a=Y(a,"SAMPLE-RATE"))?parseInt(a,10):null}function Bw(a){return(a=Y(a,"CHANNELS"))?a.includes("/JOC"):!1}
1037
- function zw(a,b,c,d,e,f,g,h,k,l,m){for(var n=t(c),p=n.next();!p.done;p=n.next())ew(p.value.stream,e,f,g,h,k,null);e=a.g.disableAudio;if(!b.length||e)b=[null];e=a.g.disableVideo;if(!c.length||e)c=[null];e=[];b=t(b);for(f=b.next();!f.done;f=b.next())for(f=f.value,g=t(c),h=g.next();!h.done;h=g.next()){var r=h.value;if(h=f?f.stream:null)h.drmInfos=l,h.keyIds=m;if(k=r?r.stream:null)k.drmInfos=l,k.keyIds=m;k&&!h&&(k.bandwidth=d);!k&&h&&(h.bandwidth=d);n=f?f.stream.drmInfos:null;p=r?r.stream.drmInfos:null;
1019
+ function Lv(a){if(Gv(a)){if(a.na==mw){for(var b,c=b=Infinity,d=t(a.i.values()),e=d.next();!e.done;e=d.next())e=e.value,e.stream.segmentIndex&&"text"!=e.stream.type&&(b=Math.min(b,e.Xb),c=Math.min(c,e.Ic));b-=c;a.g.hls.useSafariBehaviorForLive&&(b=a.l.u);isNaN(a.g.availabilityWindowOverride)||(b=a.g.availabilityWindowOverride);a.l.nf(b)}}else a.l.sb(nw(a));if(!a.l.o)for(b=t(a.i.values()),c=b.next();!c.done;c=b.next())c=c.value,!c.stream.segmentIndex||"audio"!=c.type&&"video"!=c.type||(c=c.stream.segmentIndex.get(0))&&
1020
+ c.h&&a.l.ei(c.h);a.l.Ue()}function Xv(a,b){var c=(new mb(a.N)).g;b=t(b);for(var d=b.next();!d.done;d=b.next()){var e=d.value;d=Y(e,"NAME");var f=Y(e,"VALUE");e=Y(e,"QUERYPARAM");d&&f&&(a.u.has(d)||a.u.set(d,f));e&&(d=c.get(e)[0])&&!a.u.has(d)&&a.u.set(e,d)}}
1021
+ function Nv(a,b,c){c=(new mb(c)).g;var d=new Map;b=t(b);for(var e=b.next();!e.done;e=b.next()){var f=e.value,g=Y(f,"NAME"),h=Y(f,"VALUE");e=Y(f,"QUERYPARAM");f=Y(f,"IMPORT");g&&h&&(d.has(g)||d.set(g,h));e&&(g=c.get(e)[0])&&!d.has(g)&&d.set(e,g);f&&(e=a.u.get(f))&&d.set(f,e)}return d}
1022
+ function $v(a,b){b=t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value,e=Y(d,"AUDIO");c=Y(d,"VIDEO");var f=Y(d,"SUBTITLES");d=ow(a,d);if(f){var g=Pc(Sc,d);a.I.set(f,g);Od(d,g)}e&&(f=Pc("audio",d),f||(f=a.g.hls.defaultAudioCodec),a.I.set(e,f));c&&(e=Pc("video",d),e||(e=a.g.hls.defaultVideoCodec),a.I.set(c,e))}}
1023
+ function Yv(a,b){b=t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value,e=Y(d,"DATA-ID");c=Y(d,"URI");var f=Y(d,"LANGUAGE");d=Y(d,"VALUE");e=(new Map).set("id",e);c&&e.set("uri",rv([a.N],c,a.u)[0]);f&&e.set("language",f);d&&e.set("value",d);c=new S("sessiondata",e);if(a.h)a.h.onEvent(c)}}
1024
+ function Zv(a,b){var c,d,e,f,g,h;return O(function(k){if(!a.h||!a.g)return k.return();d=t(b);for(e=d.next();!e.done;e=d.next())if(f=e.value,g=Y(f,"PATHWAY-ID"),h=Y(f,"SERVER-URI"),g&&h){a.j=new It(a.h);a.j.configure(a.g);a.j.i=[a.N];a.j.setManifestType("HLS");a.j.h=g;c=Jt(a.j,h);break}return E(k,c,0)})}
1025
+ function cw(a,b){var c=ov(b,"SUBTITLES");b=c.map(function(g){if(a.g.disableText)return null;try{return pw(a,[g],new Map).stream}catch(h){if(a.g.hls.ignoreTextStreamFailures)return null;throw h;}});c=t(c);for(var d=c.next();!d.done;d=c.next()){var e=kv(d.value,"GROUP-ID");if(d=a.I.get(e))if(e=a.J.get(e)){e=t(e);for(var f=e.next();!f.done;f=e.next())f=f.value,f.stream.codecs=d,f.stream.mimeType=qw(Sc,d)||rw(Sc),sw(f.stream)}}return b.filter(function(g){return g})}
1026
+ function sw(a){a.fullMimeTypes=new Set([te(a.mimeType,a.codecs)])}
1027
+ function dw(a,b,c){var d,e;return O(function(f){if(1==f.g)return d=b.map(function(g){var h,k,l;return O(function(m){if(1==m.g){if(h=a.g.disableThumbnails)return m.return(null);ta(m,2);return E(m,tw(a,g),4)}if(2!=m.g)return k=m.h,m.return(k.stream);l=wa(m);if(a.g.hls.ignoreImageStreamFailures)return m.return(null);throw l;})}).concat(c.map(function(g){if(a.g.disableThumbnails)return null;try{var h=kv(g,"URI"),k=Y(g,"CODECS")||"";if(a.i.has(h))var l=a.i.get(h);else{var m=Y(g,"LANGUAGE"),n=Y(g,"NAME"),
1028
+ p=Y(g,"CHARACTERISTICS"),r=uw(a,a.F++,[h],k,"image",m,!1,n,null,null,p,!1,null,!1),u=Y(g,"RESOLUTION"),v=t(u?u.split("x"):[null,null]),w=v.next().value,A=v.next().value;r.stream.width=Number(w)||void 0;r.stream.height=Number(A)||void 0;var z=Y(g,"BANDWIDTH");z&&(r.stream.bandwidth=Number(z));a.i.set(h,r);l=r}g=l;return"mjpg"!==g.stream.codecs?null:g.stream}catch(C){if(a.g.hls.ignoreImageStreamFailures)return null;throw C;}})),E(f,Promise.all(d),2);e=f.h;return f.return(e.filter(function(g){return g}))})}
1029
+ function vw(a,b,c){b=b.filter(function(h){var k=Y(h,"URI")||"";return"SUBTITLES"!=Y(h,"TYPE")&&""!=k});var d={};b=t(b);for(var e=b.next();!e.done;e=b.next()){e=e.value;var f=iv(e);d[f]?d[f].push(e):d[f]=[e]}for(var g in d)pw(a,d[g],c)}
1030
+ function bw(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q,T,R,ra,sa,Ca,Fa,Ia,Pa,Ja;return O(function(db){switch(db.g){case 1:g=[];h=new Set;if(!(0<c.length)){db.B(2);break}k=t(c);l=k.next();case 3:if(l.done){db.B(2);break}m=l.value;n=kv(m,"METHOD");p=Y(m,"KEYFORMAT")||"identity";r=null;if("NONE"==n){db.B(4);break}if(ww(n)){u=rv(e(),kv(m,"URI"),f);v=u.sort().join("");a.L.has(v)||(w=Ag(u,a.g.retryParameters),A=kw(a,w,6),a.L.set(v,A));db.B(4);break}if("identity"!=p){r=(z=xw[p])?
1031
+ z(m,""):null;db.B(6);break}return E(db,yw(a,m,"",e,null,f),9);case 9:r=db.h;case 6:if(r){if(r.keyIds)for(C=t(r.keyIds),y=C.next();!y.done;y=C.next())B=y.value,h.add(B);g.push(r)}case 4:l=k.next();db.B(3);break;case 2:D={};K=t(b);for(G=K.next();!G.done;G=K.next())J=G.value,I=iv(J),D[I]?D[I].push(J):D[I]=[J];H=[];for(N in D)L=D[N],M=L[0],Q=Y(M,"FRAME-RATE"),T=Number(Y(M,"AVERAGE-BANDWIDTH"))||Number(kv(M,"BANDWIDTH")),R=Y(M,"RESOLUTION"),ra=t(R?R.split("x"):[null,null]),sa=ra.next().value,Ca=ra.next().value,
1032
+ Fa=Y(M,"VIDEO-RANGE"),(Ia=Y(M,"REQ-VIDEO-LAYOUT"))&&Ia.includes(",")&&(Pa=Ia.split(",").filter(function(Da){return"CH-STEREO"==Da||"CH-MONO"==Da}),Ia=Pa[0]),Ia=Ia||"CH-MONO",Ja=zw(a,L,d),H.push.apply(H,x(Aw(a,Ja.audio,Ja.video,T,sa,Ca,Q,Fa,Ia,g,h)));return db.return(H.filter(function(Da){return null!=Da}))}})}
1033
+ function zw(a,b,c){for(var d={audio:[],video:[]},e=new Map,f=[],g=!1,h=!1,k=t(b),l=k.next();!l.done;l=k.next()){var m=l.value;l=Y(m,"AUDIO");var n=Y(m,"VIDEO"),p=l||n;p&&(f.includes(p)||f.push(p),(m=Y(m,"PATHWAY-ID"))&&e.set(p,m),l?g=!0:n&&(h=!0))}f.length&&c.length&&(k=c.filter(function(v){return f.includes(kv(v,"GROUP-ID"))}),vw(a,k,e));k=(e=f.sort().join(","))&&a.J.has(e)?a.J.get(e):[];g?d.audio.push.apply(d.audio,x(k)):h&&d.video.push.apply(d.video,x(k));l=!1;var r=b.map(function(v){return kv(v,
1034
+ "URI")});h=d.audio.find(function(v){return v&&v.P().find(function(w){return r.includes(w)})});g=ow(a,b[0]);n=Pc("video",g);(p=Pc("audio",g))&&!n?(h="audio",l=0<d.audio.length):!d.audio.length&&!d.video.length&&p&&n?(h="video",g=[[n,p].join()]):d.audio.length&&h?(h="audio",l=!0):h=d.video.length&&!d.audio.length?"audio":"video";if(!l){var u=m=p=n=l=null;!k.length&&(c=c.find(function(v){var w=Y(v,"URI")||"",A=Y(v,"TYPE");v=kv(v,"GROUP-ID");return"SUBTITLES"!=A&&""==w&&f.includes(v)}))&&(l=Y(c,"LANGUAGE"),
1035
+ n=Y(c,"NAME"),p=Bw(c),Cw(c),m=Y(c,"CHARACTERISTICS"),u=Dw(c));a=Ew(a,b,g,h,l,n,p,m,u);e&&(a.stream.groupId=e);d[a.stream.type]=[a]}return d}
1036
+ function ow(a,b){var c=Y(b,"CODECS")||"";b=Y(b,"SUPPLEMENTAL-CODECS");a.X=0<c.length;a.X||a.g.hls.disableCodecGuessing||(c=[],a.g.disableVideo||c.push(a.g.hls.defaultVideoCodec),a.g.disableAudio||c.push(a.g.hls.defaultAudioCodec),c=c.join(","));a=c.split(/\s*,\s*/);b&&(b=b.split(/\s*,\s*/).map(function(d){return d.split("/")[0]}),a.push.apply(a,x(b)));return Ft(a)}function Bw(a){return(a=Y(a,"CHANNELS"))?parseInt(a.split("/")[0],10):null}
1037
+ function Dw(a){return(a=Y(a,"SAMPLE-RATE"))?parseInt(a,10):null}function Cw(a){return(a=Y(a,"CHANNELS"))?a.includes("/JOC"):!1}
1038
+ function Aw(a,b,c,d,e,f,g,h,k,l,m){for(var n=t(c),p=n.next();!p.done;p=n.next())fw(p.value.stream,e,f,g,h,k,null);e=a.g.disableAudio;if(!b.length||e)b=[null];e=a.g.disableVideo;if(!c.length||e)c=[null];e=[];b=t(b);for(f=b.next();!f.done;f=b.next())for(f=f.value,g=t(c),h=g.next();!h.done;h=g.next()){var r=h.value;if(h=f?f.stream:null)h.drmInfos=l,h.keyIds=m;if(k=r?r.stream:null)k.drmInfos=l,k.keyIds=m;k&&!h&&(k.bandwidth=d);!k&&h&&(h.bandwidth=d);n=f?f.stream.drmInfos:null;p=r?r.stream.drmInfos:null;
1038
1039
  r=r?r.P().sort().join(","):"";var u=f?f.P().sort().join(","):"";r=r+" - "+u;h&&k&&!Ob(n,p)||a.Ea.has(r)||(h={id:a.F++,language:h?h.language:"und",disabledUntilTime:0,primary:!!h&&h.primary||!!k&&k.primary,audio:h,video:k,bandwidth:d,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},e.push(h),a.Ea.add(r))}return e}
1039
- function $v(a,b){b=nv(b,"CLOSED-CAPTIONS");a.ea=0==b.length;b=t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value,e=Y(d,"LANGUAGE");c=Xc(e||"und");e||(e=Y(d,"NAME"))&&(c=e);e=jv(d,"GROUP-ID");d=jv(d,"INSTREAM-ID").replace("SERVICE","svc");a.H.get(e)||a.H.set(e,new Map);a.H.get(e).set(d,c)}}
1040
- function ow(a,b,c){for(var d=[],e=[],f=new Map,g=t(b),h=g.next();!h.done;h=g.next()){var k=h.value;h=jv(k,"URI");k=jv(k,"GROUP-ID");d.push(h);e.push(k);f.set(k,h)}g=e.sort().join(",");h=b[0];b="";k=jv(h,"TYPE").toLowerCase();"subtitles"==k&&(k=Sc);if(k==Sc)b=Y(h,"CODECS")||"";else{e=t(e);for(var l=e.next();!l.done;l=e.next())if(l=l.value,a.I.has(l)){b=a.I.get(l);break}}e=d.sort().join(",");if(a.i.has(e))return a.i.get(e);l=a.F++;if(a.j){f=t(f);for(var m=f.next();!m.done;m=f.next()){var n=t(m.value);
1041
- m=n.next().value;n=n.next().value;(m=c.get(m))&&Mt(a.j,l,m,n)}}c=Y(h,"LANGUAGE");f=Y(h,"NAME");m="YES"==Y(h,"DEFAULT");n="audio"==k?Aw(h):null;var p="audio"==k?Bw(h):!1,r=Y(h,"CHARACTERISTICS"),u="YES"==Y(h,"FORCED");h="audio"==k?Cw(h):null;d=tw(a,l,d,b,k,c,m,f,n,null,r,u,h,p);d.stream&&(d.stream.groupId=g);a.J.has(g)?a.J.get(g).push(d):a.J.set(g,[d]);a.i.set(e,d);return d}
1042
- function sw(a,b){var c,d,e,f,g,h,k,l,m,n;return O(function(p){if(1==p.g){c=jv(b,"URI");d=Y(b,"CODECS","jpeg")||"";if(a.i.has(c))return p.return(a.i.get(c));e=Y(b,"LANGUAGE");f=Y(b,"NAME");g=Y(b,"CHARACTERISTICS");h=tw(a,a.F++,[c],d,"image",e,!1,f,null,null,g,!1,null,!1);return(k=Y(b,"RESOLUTION"))?E(p,h.stream.createSegmentIndex(),3):p.B(2)}2!=p.g&&(l=h.stream.segmentIndex.get(0),m=l.tilesLayout)&&(h.stream.width=Number(k.split("x")[0])*Number(m.split("x")[0]),h.stream.height=Number(k.split("x")[1])*
1040
+ function aw(a,b){b=ov(b,"CLOSED-CAPTIONS");a.ea=0==b.length;b=t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value,e=Y(d,"LANGUAGE");c=Xc(e||"und");e||(e=Y(d,"NAME"))&&(c=e);e=kv(d,"GROUP-ID");d=kv(d,"INSTREAM-ID").replace("SERVICE","svc");a.H.get(e)||a.H.set(e,new Map);a.H.get(e).set(d,c)}}
1041
+ function pw(a,b,c){for(var d=[],e=[],f=new Map,g=t(b),h=g.next();!h.done;h=g.next()){var k=h.value;h=kv(k,"URI");k=kv(k,"GROUP-ID");d.push(h);e.push(k);f.set(k,h)}g=e.sort().join(",");h=b[0];b="";k=kv(h,"TYPE").toLowerCase();"subtitles"==k&&(k=Sc);if(k==Sc)b=Y(h,"CODECS")||"";else{e=t(e);for(var l=e.next();!l.done;l=e.next())if(l=l.value,a.I.has(l)){b=a.I.get(l);break}}e=d.sort().join(",");if(a.i.has(e))return a.i.get(e);l=a.F++;if(a.j){f=t(f);for(var m=f.next();!m.done;m=f.next()){var n=t(m.value);
1042
+ m=n.next().value;n=n.next().value;(m=c.get(m))&&Mt(a.j,l,m,n)}}c=Y(h,"LANGUAGE");f=Y(h,"NAME");m="YES"==Y(h,"DEFAULT");n="audio"==k?Bw(h):null;var p="audio"==k?Cw(h):!1,r=Y(h,"CHARACTERISTICS"),u="YES"==Y(h,"FORCED");h="audio"==k?Dw(h):null;d=uw(a,l,d,b,k,c,m,f,n,null,r,u,h,p);d.stream&&(d.stream.groupId=g);a.J.has(g)?a.J.get(g).push(d):a.J.set(g,[d]);a.i.set(e,d);return d}
1043
+ function tw(a,b){var c,d,e,f,g,h,k,l,m,n;return O(function(p){if(1==p.g){c=kv(b,"URI");d=Y(b,"CODECS","jpeg")||"";if(a.i.has(c))return p.return(a.i.get(c));e=Y(b,"LANGUAGE");f=Y(b,"NAME");g=Y(b,"CHARACTERISTICS");h=uw(a,a.F++,[c],d,"image",e,!1,f,null,null,g,!1,null,!1);return(k=Y(b,"RESOLUTION"))?E(p,h.stream.createSegmentIndex(),3):p.B(2)}2!=p.g&&(l=h.stream.segmentIndex.get(0),m=l.tilesLayout)&&(h.stream.width=Number(k.split("x")[0])*Number(m.split("x")[0]),h.stream.height=Number(k.split("x")[1])*
1043
1044
  Number(m.split("x")[1]));if(n=Y(b,"BANDWIDTH"))h.stream.bandwidth=Number(n);a.i.set(c,h);return p.return(h)})}
1044
- function Dw(a,b,c,d,e,f,g,h,k){for(var l=a.F++,m=[],n=t(b),p=n.next();!p.done;p=n.next()){var r=p.value;p=jv(r,"URI");r=Y(r,"PATHWAY-ID");a.j&&r&&Mt(a.j,l,r,p);m.push(p)}n=m.sort().join(",");if(a.i.has(n))return a.i.get(n);a:{b=Y(b[0],"CLOSED-CAPTIONS");if("video"==d)if(b){if("NONE"!=b){b=a.H.get(b);break a}a.ea=!1}else if(!b&&a.H.size)for(b=t(a.H.keys()).next();!b.done;){b=a.H.get(b.value);break a}b=null}c=Oc(d,c);d=tw(a,l,m,c,d,e,!1,f,g,b,h,!1,k,!1);a.i.set(n,d);return d}
1045
- function tw(a,b,c,d,e,f,g,h,k,l,m,n,p,r){function u(B){var D,K,G,J,I,H,N,L,M,Q,T,R,ra,sa,Ca,Ea,Ia,Pa,Ja,db,Fa,$a;return O(function(xb){switch(xb.g){case 1:return D=Uc,K=z.P(),E(xb,Dv(a,z.P(),!0),2);case 2:G=xb.h;if(B.aborted)return xb.return();J=G.uri;J==G.originalUri||K.includes(J)||A.push(J);I=tv(a.Ba,G.data);if(1!=I.type)throw new U(2,4,4017);H=mv(I.g,"EXT-X-DEFINE");N=Mv(a,H,J);L=void 0;M=!1;if(!(!a.Z&&a.g.hls.disableCodecGuessing||a.ea&&e==D.ra&&!a.g.hls.disableClosedCaptionsDetection)){xb.B(3);
1046
- break}if(Q=0<I.segments.length)T=I.segments[0],ov(T.g,"EXT-X-GAP")&&(Q=!1);if(!Q){xb.B(3);break}a.ea=!1;return E(xb,Vv(a,I,v,N),5);case 5:R=xb.h,!R.closedCaptions.size||l&&l.size==R.closedCaptions.size||(l=R.closedCaptions,M=!0),!a.Z&&a.g.hls.disableCodecGuessing&&(L=R.mimeType,d=R.codecs);case 3:return ra=Fv(a),E(xb,dw(a,0,N,I,v,d,e,f,g,h,k,l,m,n,p,r,L),6);case 6:sa=xb.h;if(B.aborted)return xb.return();Ca=sa.stream;Fv(a)&&!ra&&fw(a,I);z.Hc=sa.Hc;z.Xb=sa.Xb;z.Ee=sa.Ee;z.De=sa.De;z.Td=sa.Td;z.We=sa.We;
1047
- z.Fb=sa.Fb;z.Gb=sa.Gb;z.Gg=!0;w.segmentIndex=Ca.segmentIndex;w.encrypted=Ca.encrypted;w.drmInfos=Ca.drmInfos;w.keyIds=Ca.keyIds;w.mimeType=Ca.mimeType;w.bandwidth=w.bandwidth||Ca.bandwidth;w.codecs=w.codecs||Ca.codecs;w.closedCaptions=w.closedCaptions||Ca.closedCaptions;rw(w);w.drmInfos.length&&a.h.newDrmInfo(w);a.o&&M&&a.h.makeTextStreamsForClosedCaptions(a.o);if(e==D.ra||e==D.aa)for(Ea=t(a.i.values()),Ia=Ea.next();!Ia.done;Ia=Ea.next())Pa=Ia.value,Pa.Gg||Pa.type!=e||(Pa.stream.mimeType=Ca.mimeType,
1048
- rw(Pa.stream));e==D.Ga&&(Ja=Ca.segmentIndex.get(0))&&Ja.sa&&(w.mimeType="application/mp4",rw(w));Ew(a)&&(a.jb?gw(a,[z]):(a.jb=!0,db=Array.from(a.i.values()),Fa=db.filter(function(ad){return ad.stream.segmentIndex}),gw(a,Fa),Kv(a),$a=a.m,0<$a&&a.A.V($a)));F(xb)}})}function v(){return a.j&&1<c.length?Nt(a.j,b):A.concat(rv([a.N],c,a.u))}var w=Fw(a,d,e,f,g,h,k,l,m,n,p,r),A=[],z={stream:w,type:e,Yh:A,P:v,Hc:0,Xb:0,We:new Map,Ee:!1,De:!1,Td:!1,$f:-1,Fb:-1,Gb:-1,Gg:!1},C=null,y=new AbortController;w.createSegmentIndex=
1049
- function(){if(C)return C;y=new AbortController;return C=new Promise(function(B){B(u(y.signal))})};w.closeSegmentIndex=function(){C&&!w.segmentIndex&&y.abort();w.segmentIndex&&(w.segmentIndex.release(),w.segmentIndex=null);C=null};return z}function mw(a){var b=Infinity;a=t(a.i.values());for(var c=a.next();!c.done;c=a.next())c=c.value,c.stream.segmentIndex&&"text"!=c.stream.type&&(b=Math.min(b,c.Xb));return b}
1050
- function Hv(a,b){var c=[];b=t(b);for(var d=b.next();!d.done;d=b.next())d=d.value,d.segmentIndex&&d.segmentIndex.Xc(function(e){c.push(e)});a.l.ce(c)}function gw(a,b){if(!Fv(a))for(var c=mw(a),d=t(b),e=d.next();!e.done;e=d.next())e.value.stream.segmentIndex.Wc(0,c);Hv(a,b.map(function(f){return f.stream}));a.g.hls.ignoreManifestProgramDateTime?Rv(a,b):(Uv(a,b),0<a.g.hls.ignoreManifestProgramDateTimeForTypes.length&&Rv(a,b))}
1051
- function Sv(a,b){return a.g.hls.ignoreManifestProgramDateTime?!0:a.g.hls.ignoreManifestProgramDateTimeForTypes.includes(b)}function Ew(a){if(!a.o)return!1;var b=[],c=[];a=t(a.o.variants);for(var d=a.next();!d.done;d=a.next())d=d.value,d.video&&b.push(d.video),d.audio&&c.push(d.audio);return 0<b.length&&!b.some(function(e){return e.segmentIndex})||0<c.length&&!c.some(function(e){return e.segmentIndex})?!1:!0}
1052
- function dw(a,b,c,d,e,f,g,h,k,l,m,n,p,r,u,v,w){var A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q,T,R,ra,sa,Ca,Ea;return O(function(Ia){switch(Ia.g){case 1:var Pa=ov(d.g,"EXT-X-PLAYLIST-TYPE"),Ja=ov(d.g,"EXT-X-ENDLIST");Ja=Pa&&"VOD"==Pa.value||Ja;Pa=Pa&&"EVENT"==Pa.value&&!Ja;Pa=!Ja&&!Pa;Ja?Jv(a,Cv):Pa?Jv(a,lw):Jv(a,Gw);Fv(a)&&Qv(a,d);A=Fv(a)?a.O.get(g):new Map;z=Ov(a,d,A,c,e,g);C=z.segments;y=z.bandwidth;if(w){Ia.B(2);break}return E(Ia,Hw(a,g,f,C),3);case 3:w=Ia.h;case 2:return E(Ia,Nv(a,d,w,e,c),4);case 4:B=Ia.h;
1053
- D=B.drmInfos;K=B.keyIds;G=B.encrypted;J=B.Gi;if(G&&!D.length&&!J)throw new U(2,4,4026);I=Fw(a,f,g,h,k,l,m,n,p,r,u,v);I.encrypted=G;I.drmInfos=D;I.keyIds=K;I.mimeType=w;y&&(I.bandwidth=y);rw(I);Fv(a)&&Qv(a,d);H=C[0].startTime;N=C[C.length-1];L=N.endTime;M=new Xk(C);I.segmentIndex=M;T=(Q=ov(d.g,"EXT-X-SERVER-CONTROL"))?null!=iv(Q,"CAN-SKIP-UNTIL"):!1;R=Q?null!=iv(Q,"CAN-BLOCK-RELOAD"):!1;ra=pv(d.g,"EXT-X-MEDIA-SEQUENCE",0);sa=Pv(ra,C);Ca=sa.Fb;Ea=sa.Gb;return Ia.return({stream:I,type:g,Yh:[],P:e,Hc:H,
1054
- Xb:L,Ee:T,De:R,Td:!1,$f:-1,Fb:Ca,Gb:Ea,We:A,Gg:!1})}})}function Pv(a,b){a=a+b.length-1;var c=-1;if(!b.length)return a++,{Fb:a,Gb:c};b=b[b.length-1];var d=b.g;if(!b.g.length)return a++,b.m&&(c=0),{Fb:a,Gb:c};c=d.length-1;d[d.length-1].preload||(a++,c=0);return{Fb:a,Gb:c}}
1055
- function Fw(a,b,c,d,e,f,g,h,k,l,m,n){var p=pw(c,b)||qw(c),r=[];if(k){k=t(k.split(","));for(var u=k.next();!u.done;u=k.next())r.push(u.value)}k=void 0;u=null;c==Sc?k=r.includes("public.accessibility.transcribes-spoken-dialog")&&r.includes("public.accessibility.describes-music-and-sound")?"caption":"subtitle":r.includes("public.accessibility.describes-video")&&(u="visually impaired");r.length||"subtitle"!==k||r.push("subtitle");a={id:a.F++,originalId:f,groupId:null,createSegmentIndex:function(){return Promise.resolve()},
1045
+ function Ew(a,b,c,d,e,f,g,h,k){for(var l=a.F++,m=[],n=t(b),p=n.next();!p.done;p=n.next()){var r=p.value;p=kv(r,"URI");r=Y(r,"PATHWAY-ID");a.j&&r&&Mt(a.j,l,r,p);m.push(p)}n=m.sort().join(",");if(a.i.has(n))return a.i.get(n);a:{b=Y(b[0],"CLOSED-CAPTIONS");if("video"==d)if(b){if("NONE"!=b){b=a.H.get(b);break a}a.ea=!1}else if(!b&&a.H.size)for(b=t(a.H.keys()).next();!b.done;){b=a.H.get(b.value);break a}b=null}c=Oc(d,c);d=uw(a,l,m,c,d,e,!1,f,g,b,h,!1,k,!1);a.i.set(n,d);return d}
1046
+ function uw(a,b,c,d,e,f,g,h,k,l,m,n,p,r){function u(B){var D,K,G,J,I,H,N,L,M,Q,T,R,ra,sa,Ca,Fa,Ia,Pa,Ja,db,Da,$a;return O(function(xb){switch(xb.g){case 1:return D=Uc,K=z.P(),E(xb,Ev(a,z.P(),!0),2);case 2:G=xb.h;if(B.aborted)return xb.return();J=G.uri;J==G.originalUri||K.includes(J)||A.push(J);I=uv(a.Ba,G.data);if(1!=I.type)throw new U(2,4,4017);H=nv(I.g,"EXT-X-DEFINE");N=Nv(a,H,J);L=void 0;M=!1;if(!(!a.X&&a.g.hls.disableCodecGuessing||a.ea&&e==D.ra&&!a.g.hls.disableClosedCaptionsDetection)){xb.B(3);
1047
+ break}if(Q=0<I.segments.length)T=I.segments[0],pv(T.g,"EXT-X-GAP")&&(Q=!1);if(!Q){xb.B(3);break}a.ea=!1;return E(xb,Wv(a,I,v,N),5);case 5:R=xb.h,!R.closedCaptions.size||l&&l.size==R.closedCaptions.size||(l=R.closedCaptions,M=!0),!a.X&&a.g.hls.disableCodecGuessing&&(L=R.mimeType,d=R.codecs);case 3:return ra=Gv(a),E(xb,ew(a,0,N,I,v,d,e,f,g,h,k,l,m,n,p,r,L),6);case 6:sa=xb.h;if(B.aborted)return xb.return();Ca=sa.stream;Gv(a)&&!ra&&gw(a,I);z.Ic=sa.Ic;z.Xb=sa.Xb;z.Ee=sa.Ee;z.De=sa.De;z.Td=sa.Td;z.We=sa.We;
1048
+ z.Fb=sa.Fb;z.Gb=sa.Gb;z.Gg=!0;w.segmentIndex=Ca.segmentIndex;w.encrypted=Ca.encrypted;w.drmInfos=Ca.drmInfos;w.keyIds=Ca.keyIds;w.mimeType=Ca.mimeType;w.bandwidth=w.bandwidth||Ca.bandwidth;w.codecs=w.codecs||Ca.codecs;w.closedCaptions=w.closedCaptions||Ca.closedCaptions;sw(w);w.drmInfos.length&&a.h.newDrmInfo(w);a.o&&M&&a.h.makeTextStreamsForClosedCaptions(a.o);if(e==D.ra||e==D.aa)for(Fa=t(a.i.values()),Ia=Fa.next();!Ia.done;Ia=Fa.next())Pa=Ia.value,Pa.Gg||Pa.type!=e||(Pa.stream.mimeType=Ca.mimeType,
1049
+ sw(Pa.stream));e==D.Ga&&(Ja=Ca.segmentIndex.get(0))&&Ja.sa&&(w.mimeType="application/mp4",sw(w));Fw(a)&&(a.jb?hw(a,[z]):(a.jb=!0,db=Array.from(a.i.values()),Da=db.filter(function(ad){return ad.stream.segmentIndex}),hw(a,Da),Lv(a),$a=a.m,0<$a&&a.A.V($a)));F(xb)}})}function v(){return a.j&&1<c.length?Nt(a.j,b):A.concat(sv([a.N],c,a.u))}var w=Gw(a,d,e,f,g,h,k,l,m,n,p,r),A=[],z={stream:w,type:e,Yh:A,P:v,Ic:0,Xb:0,We:new Map,Ee:!1,De:!1,Td:!1,$f:-1,Fb:-1,Gb:-1,Gg:!1},C=null,y=new AbortController;w.createSegmentIndex=
1050
+ function(){if(C)return C;y=new AbortController;return C=new Promise(function(B){B(u(y.signal))})};w.closeSegmentIndex=function(){C&&!w.segmentIndex&&y.abort();w.segmentIndex&&(w.segmentIndex.release(),w.segmentIndex=null);C=null};return z}function nw(a){var b=Infinity;a=t(a.i.values());for(var c=a.next();!c.done;c=a.next())c=c.value,c.stream.segmentIndex&&"text"!=c.stream.type&&(b=Math.min(b,c.Xb));return b}
1051
+ function Iv(a,b){var c=[];b=t(b);for(var d=b.next();!d.done;d=b.next())d=d.value,d.segmentIndex&&d.segmentIndex.Yc(function(e){c.push(e)});a.l.ce(c)}function hw(a,b){if(!Gv(a))for(var c=nw(a),d=t(b),e=d.next();!e.done;e=d.next())e.value.stream.segmentIndex.Xc(0,c);Iv(a,b.map(function(f){return f.stream}));a.g.hls.ignoreManifestProgramDateTime?Sv(a,b):(Vv(a,b),0<a.g.hls.ignoreManifestProgramDateTimeForTypes.length&&Sv(a,b))}
1052
+ function Tv(a,b){return a.g.hls.ignoreManifestProgramDateTime?!0:a.g.hls.ignoreManifestProgramDateTimeForTypes.includes(b)}function Fw(a){if(!a.o)return!1;var b=[],c=[];a=t(a.o.variants);for(var d=a.next();!d.done;d=a.next())d=d.value,d.video&&b.push(d.video),d.audio&&c.push(d.audio);return 0<b.length&&!b.some(function(e){return e.segmentIndex})||0<c.length&&!c.some(function(e){return e.segmentIndex})?!1:!0}
1053
+ function ew(a,b,c,d,e,f,g,h,k,l,m,n,p,r,u,v,w){var A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q,T,R,ra,sa,Ca,Fa;return O(function(Ia){switch(Ia.g){case 1:var Pa=pv(d.g,"EXT-X-PLAYLIST-TYPE"),Ja=pv(d.g,"EXT-X-ENDLIST");Ja=Pa&&"VOD"==Pa.value||Ja;Pa=Pa&&"EVENT"==Pa.value&&!Ja;Pa=!Ja&&!Pa;Ja?Kv(a,Dv):Pa?Kv(a,mw):Kv(a,Hw);Gv(a)&&Rv(a,d);A=Gv(a)?a.O.get(g):new Map;z=Pv(a,d,A,c,e,g);C=z.segments;y=z.bandwidth;if(w){Ia.B(2);break}return E(Ia,Iw(a,g,f,C),3);case 3:w=Ia.h;case 2:return E(Ia,Ov(a,d,w,e,c),4);case 4:B=Ia.h;
1054
+ D=B.drmInfos;K=B.keyIds;G=B.encrypted;J=B.Gi;if(G&&!D.length&&!J)throw new U(2,4,4026);I=Gw(a,f,g,h,k,l,m,n,p,r,u,v);I.encrypted=G;I.drmInfos=D;I.keyIds=K;I.mimeType=w;y&&(I.bandwidth=y);sw(I);Gv(a)&&Rv(a,d);H=C[0].startTime;N=C[C.length-1];L=N.endTime;M=new Xk(C);I.segmentIndex=M;T=(Q=pv(d.g,"EXT-X-SERVER-CONTROL"))?null!=jv(Q,"CAN-SKIP-UNTIL"):!1;R=Q?null!=jv(Q,"CAN-BLOCK-RELOAD"):!1;ra=qv(d.g,"EXT-X-MEDIA-SEQUENCE",0);sa=Qv(ra,C);Ca=sa.Fb;Fa=sa.Gb;return Ia.return({stream:I,type:g,Yh:[],P:e,Ic:H,
1055
+ Xb:L,Ee:T,De:R,Td:!1,$f:-1,Fb:Ca,Gb:Fa,We:A,Gg:!1})}})}function Qv(a,b){a=a+b.length-1;var c=-1;if(!b.length)return a++,{Fb:a,Gb:c};b=b[b.length-1];var d=b.g;if(!b.g.length)return a++,b.m&&(c=0),{Fb:a,Gb:c};c=d.length-1;d[d.length-1].preload||(a++,c=0);return{Fb:a,Gb:c}}
1056
+ function Gw(a,b,c,d,e,f,g,h,k,l,m,n){var p=qw(c,b)||rw(c),r=[];if(k){k=t(k.split(","));for(var u=k.next();!u.done;u=k.next())r.push(u.value)}k=void 0;u=null;c==Sc?k=r.includes("public.accessibility.transcribes-spoken-dialog")&&r.includes("public.accessibility.describes-music-and-sound")?"caption":"subtitle":r.includes("public.accessibility.describes-video")&&(u="visually impaired");r.length||"subtitle"!==k||r.push("subtitle");a={id:a.F++,originalId:f,groupId:null,createSegmentIndex:function(){return Promise.resolve()},
1056
1057
  segmentIndex:null,mimeType:p,codecs:b,kind:c==Sc?"subtitle":void 0,encrypted:!1,drmInfos:[],keyIds:new Set,language:Xc(d||"und"),originalLanguage:d,label:f,type:c,primary:e,trickModeVideo:null,emsgSchemeIdUris:null,frameRate:void 0,pixelAspectRatio:void 0,width:void 0,height:void 0,bandwidth:void 0,roles:r,forced:l,channelsCount:g,audioSamplingRate:m,spatialAudio:n,closedCaptions:h,hdr:void 0,colorGamut:void 0,videoLayout:void 0,tilesLayout:void 0,accessibilityPurpose:u,external:!1,fastSwitching:!1,
1057
- fullMimeTypes:new Set};rw(a);return a}
1058
- function Nv(a,b,c,d,e){var f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q,T;return O(function(R){switch(R.g){case 1:f=new Map;if(b.segments)for(g=t(b.segments),h=g.next();!h.done;h=g.next())if(k=h.value,l=mv(k.g,"EXT-X-KEY"),m=null,l.length)for(m=iw(a,b,k.g,d,e),n=t(l),p=n.next();!p.done;p=n.next())r=p.value,f.set(r,m);v=u=!1;w=[];A=new Set;z=t(f);C=z.next();case 2:if(C.done){R.B(4);break}y=C.value;B=t(y);D=B.next().value;K=B.next().value;G=D;J=K;I=jv(G,"METHOD");if("NONE"==I){R.B(3);break}u=
1059
- !0;H=Y(G,"KEYFORMAT")||"identity";N=null;if(vw(I)){v=!0;R.B(3);break}if("identity"!=H){N=(L=ww[H])?L(G,c):null;R.B(6);break}return E(R,xw(a,G,c,d,J,e),8);case 8:N=R.h;case 6:if(N){if(N.keyIds)for(M=t(N.keyIds),Q=M.next();!Q.done;Q=M.next())T=Q.value,A.add(T);w.push(N)}case 3:C=z.next();R.B(2);break;case 4:return R.return({drmInfos:w,keyIds:A,encrypted:u,Gi:v})}})}
1060
- function Iw(a,b,c,d,e){if(!window.crypto||!window.crypto.subtle)throw Ya("Web Crypto API is not available to decrypt AES. (Web Crypto only exists in secure origins like https)"),new U(2,4,4042);var f=0,g=Y(b,"IV","");if(g){var h=Ic(g.substr(2));if(16!=h.byteLength)throw new U(2,4,4048);}else f=pv(c.g,"EXT-X-MEDIA-SEQUENCE",0);c=b.toString()+"-"+f;if(!a.ha.has(c)){var k={bitsKey:128,blockCipherMode:"CBC",iv:h,firstMediaSequenceNumber:f};switch(jv(b,"METHOD")){case "AES-256":k.bitsKey=256;break;case "AES-256-CTR":k.bitsKey=
1061
- 256,k.blockCipherMode="CTR"}k.fetchKey=function(){var l,m,n,p,r,u,v;return O(function(w){if(1==w.g)return l=qv(d(),jv(b,"URI"),e),m=l.sort().join(""),a.L.has(m)||(n=Ag(l,a.g.retryParameters),p=jw(a,n,6),a.L.set(m,p)),E(w,a.L.get(m),2);if(3!=w.g){r=w.h;if(!r.data||r.data.byteLength!=k.bitsKey/8)throw new U(2,4,4049);u={name:"CTR"==k.blockCipherMode?"AES-CTR":"AES-CBC",length:k.bitsKey};v=k;return E(w,window.crypto.subtle.importKey("raw",r.data,u,!0,["decrypt"]),3)}v.cryptoKey=w.h;k.fetchKey=void 0;
1058
+ fullMimeTypes:new Set};sw(a);return a}
1059
+ function Ov(a,b,c,d,e){var f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M,Q,T;return O(function(R){switch(R.g){case 1:f=new Map;if(b.segments)for(g=t(b.segments),h=g.next();!h.done;h=g.next())if(k=h.value,l=nv(k.g,"EXT-X-KEY"),m=null,l.length)for(m=jw(a,b,k.g,d,e),n=t(l),p=n.next();!p.done;p=n.next())r=p.value,f.set(r,m);v=u=!1;w=[];A=new Set;z=t(f);C=z.next();case 2:if(C.done){R.B(4);break}y=C.value;B=t(y);D=B.next().value;K=B.next().value;G=D;J=K;I=kv(G,"METHOD");if("NONE"==I){R.B(3);break}u=
1060
+ !0;H=Y(G,"KEYFORMAT")||"identity";N=null;if(ww(I)){v=!0;R.B(3);break}if("identity"!=H){N=(L=xw[H])?L(G,c):null;R.B(6);break}return E(R,yw(a,G,c,d,J,e),8);case 8:N=R.h;case 6:if(N){if(N.keyIds)for(M=t(N.keyIds),Q=M.next();!Q.done;Q=M.next())T=Q.value,A.add(T);w.push(N)}case 3:C=z.next();R.B(2);break;case 4:return R.return({drmInfos:w,keyIds:A,encrypted:u,Gi:v})}})}
1061
+ function Jw(a,b,c,d,e){if(!window.crypto||!window.crypto.subtle)throw Ya("Web Crypto API is not available to decrypt AES. (Web Crypto only exists in secure origins like https)"),new U(2,4,4042);var f=0,g=Y(b,"IV","");if(g){var h=Ic(g.substr(2));if(16!=h.byteLength)throw new U(2,4,4048);}else f=qv(c.g,"EXT-X-MEDIA-SEQUENCE",0);c=b.toString()+"-"+f;if(!a.ha.has(c)){var k={bitsKey:128,blockCipherMode:"CBC",iv:h,firstMediaSequenceNumber:f};switch(kv(b,"METHOD")){case "AES-256":k.bitsKey=256;break;case "AES-256-CTR":k.bitsKey=
1062
+ 256,k.blockCipherMode="CTR"}k.fetchKey=function(){var l,m,n,p,r,u,v;return O(function(w){if(1==w.g)return l=rv(d(),kv(b,"URI"),e),m=l.sort().join(""),a.L.has(m)||(n=Ag(l,a.g.retryParameters),p=kw(a,n,6),a.L.set(m,p)),E(w,a.L.get(m),2);if(3!=w.g){r=w.h;if(!r.data||r.data.byteLength!=k.bitsKey/8)throw new U(2,4,4049);u={name:"CTR"==k.blockCipherMode?"AES-CTR":"AES-CBC",length:k.bitsKey};v=k;return E(w,window.crypto.subtle.importKey("raw",r.data,u,!0,["decrypt"]),3)}v.cryptoKey=w.h;k.fetchKey=void 0;
1062
1063
  F(w)})};a.ha.set(c,k)}return a.ha.get(c)}
1063
- function Qv(a,b){var c=Infinity,d=b.segments;if(d.length)for(var e=d.length-1;0<=e;){var f=ov(d[e].g,"EXTINF");if(f){c=Number(f.value.split(",")[0]);break}e--}d=ov(b.g,"EXT-X-TARGETDURATION");if(!d)throw new U(2,4,4024,"EXT-X-TARGETDURATION");d=Number(d.value);if(e=ov(b.g,"EXT-X-PART-INF"))a.R=Number(jv(e,"PART-TARGET"));b=ov(b.g,"EXT-X-SERVER-CONTROL");a.G&&a.R?(a.m=a.Za?5*a.R<=c?Math.min(a.R,a.m):Math.min(c,a.m):Math.min(a.R,a.m),a.xa=b?Number(jv(b,"PART-HOLD-BACK")):0):(a.m=Math.min(c,a.m),c=b?
1064
- iv(b,"HOLD-BACK"):null,a.qa=c?Number(c.value):0);a.Ha=Math.max(d,a.Ha)}function fw(a,b){if(a.g.defaultPresentationDelay)b=a.g.defaultPresentationDelay;else if(a.xa)b=a.xa;else if(a.qa)b=a.qa;else{b=b.segments.length;var c=a.g.hls.liveSegmentsDelay;c>b-2&&(c=Math.max(1,b-2));b=a.Ha*c}a.l.ii(0);a.l.Xg(b);a.l.Lc(!1)}
1065
- function iw(a,b,c,d,e){var f=ov(c,"EXT-X-MAP");if(!f)return null;var g=jv(f,"URI"),h=qv(d(),g,e);g=[h.toString(),Y(f,"BYTERANGE","")].join("-");if(!a.ba.has(g)){var k=void 0,l=null;c=t(c);for(var m=c.next();!m.done;m=c.next())m=m.value,"EXT-X-KEY"==m.name?vw(jv(m,"METHOD"))&&m.id<f.id&&(k=Iw(a,m,b,d,e)):"EXT-X-BYTERANGE"==m.name&&m.id<f.id&&(l=m);b=Jw(h,f,l,k);a.ba.set(g,b)}return a.ba.get(g)}
1066
- function Jw(a,b,c,d){var e=0,f=null;b=Y(b,"BYTERANGE");!b&&c&&(b=c.value);b&&(e=b.split("@"),f=Number(e[0]),e=Number(e[1]),f=e+f-1,d&&(c=f+1-e,c%16&&(f+=16-c%16)));return new Gi(function(){return a},e,f,null,null,null,d)}
1067
- function Kw(a,b,c,d,e,f,g,h,k){var l=d.g,m=ov(l,"EXTINF"),n=0,p=0,r=null;d.Rb.length&&!a.G&&Ya("Low-latency HLS 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.");var u=null;if(!a.g.hls.ignoreManifestProgramDateTime){var v=ov(l,"EXT-X-PROGRAM-DATE-TIME");v&&v.value&&(u=wh(v.value))}var w=Ji;ov(l,"EXT-X-GAP")&&(w=2);if(!m){if(0==d.Rb.length)throw new U(2,4,4024,"EXTINF");
1068
- if(!a.G)return null}var A=[];v=!1;var z=null,C=!1,y=!1;if(a.G&&d.Rb.length){n=b&&window.ReadableStream&&a.g.hls.allowLowLatencyByteRangeOptimization;for(var B=u,D={},K=0;K<d.Rb.length;D={Fd:D.Fd,we:D.we},K++){var G=d.Rb[K],J=0==K?c:A[A.length-1],I=0==K?e:J.endTime,H=Number(Y(G,"DURATION"))||a.R;if(H){var N=I+H,L=0,M=null;"EXT-X-PRELOAD-HINT"==G.name?(L=(L=Y(G,"BYTERANGE-START"))?Number(L):0,(J=Y(G,"BYTERANGE-LENGTH"))?M=L+Number(J)-1:L&&(M=Number.MAX_SAFE_INTEGER)):(L=Y(G,"BYTERANGE"),M=t(kw(J,L)),
1069
- L=M.next().value,M=M.next().value);D.we=Y(G,"URI");if(D.we){J=Ji;"YES"==Y(G,"GAP")&&(J=2,C=!0);D.Fd=null;var Q=function(R){return function(){null==R.Fd&&(R.Fd=qv(h(),R.we,f));return R.Fd}}(D);n&&0<=L&&null!=M&&(z=Q,v=!0);I=new Ii(I,N,Q,L,M,b,0,0,Infinity,[],"",null,B,J,k);"EXT-X-PRELOAD-HINT"==G.name&&(I.Hg(),y=!0);"YES"!=Y(G,"INDEPENDENT")&&0<K&&I.Ve();A.push(I);B&&(B+=H)}}}}if(m){m=Number(m.value.split(",")[0]);if(0==m)return null;n=e+m}else if(A.length)n=A[A.length-1].endTime;else return null;
1070
- v&&(C||0!=A[0].Wa?(v=!1,z=null):A=[]);(m=ov(l,"EXT-X-BYTERANGE"))?(r=t(kw(c,m.value)),p=r.next().value,r=r.next().value):A.length&&(p=A[0].Wa,r=A[A.length-1].Da);c="";m=null;"image"==g&&(c="1x1",g=ov(l,"EXT-X-TILES"))&&(c=jv(g,"LAYOUT"),(g=Y(g,"DURATION"))&&(m=Number(g)));var T=null;b=new Ii(e,n,function(){if(z)return z();null==T&&(T=qv(h(),d.h,f));return T||[]},p,r,b,0,0,Infinity,A,c,m,u,w,k,0<A.length&&!!d.h);v&&(a.Za=!0,b.Qh(),y&&b.Hg());return b}
1071
- function kw(a,b){var c=0,d=null;b&&(c=b.split("@"),b=Number(c[0]),c=c[1]?Number(c[1]):a.Da+1,d=c+b-1);return[c,d]}
1072
- function Ov(a,b,c,d,e,f){var g=b.segments,h=void 0,k=pv(b.g,"EXT-X-DISCONTINUITY-SEQUENCE",0),l=pv(b.g,"EXT-X-MEDIA-SEQUENCE",0),m=ov(b.g,"EXT-X-SKIP"),n=m?Number(Y(m,"SKIPPED-SEGMENTS")):0,p=l+n,r=0;Fv(a)&&c.has(p)&&(r=c.get(p));0===r&&a.na==lw&&0<c.size&&!c.has(p)&&(r=a.l.Cb());var u=[],v=null;m=[];for(var w=0;w<g.length;w++){var A=g[w],z=0==w?r:v.endTime;p=l+n+w;ov(A.g,"EXT-X-DISCONTINUITY")&&k++;var C=t(A.g);for(var y=C.next();!y.done;y=C.next())y=y.value,"EXT-X-KEY"==y.name&&(vw(jv(y,"METHOD"))?
1073
- h=Iw(a,y,b,e,d):h=void 0);c.set(p,z);C=iw(a,b,A.g,e,d);!a.G&&a.h.isAutoLowLatencyMode()&&(a.h.enableLowLatencyMode(),a.G=a.h.isLowLatencyMode());if(z=Kw(a,C,v,A,z,d,f,e,h))(v=pv(A.g,"EXT-X-BITRATE"))?m.push({bitrate:v,duration:z.endTime-z.startTime}):m.length&&(v=m.pop(),v.duration+=z.endTime-z.startTime,m.push(v)),v=z,z.j=k,Sv(a,f)&&null!=a.K&&p<a.K||u.push(z)}b=void 0;m.length&&(b=m.reduce(function(B,D){return B+D.duration},0),b=Math.round(m.reduce(function(B,D){return B+D.bitrate*D.duration},0)/
1064
+ function Rv(a,b){var c=Infinity,d=b.segments;if(d.length)for(var e=d.length-1;0<=e;){var f=pv(d[e].g,"EXTINF");if(f){c=Number(f.value.split(",")[0]);break}e--}d=pv(b.g,"EXT-X-TARGETDURATION");if(!d)throw new U(2,4,4024,"EXT-X-TARGETDURATION");d=Number(d.value);if(e=pv(b.g,"EXT-X-PART-INF"))a.R=Number(kv(e,"PART-TARGET"));b=pv(b.g,"EXT-X-SERVER-CONTROL");a.G&&a.R?(a.m=a.Za?5*a.R<=c?Math.min(a.R,a.m):Math.min(c,a.m):Math.min(a.R,a.m),a.xa=b?Number(kv(b,"PART-HOLD-BACK")):0):(a.m=Math.min(c,a.m),c=b?
1065
+ jv(b,"HOLD-BACK"):null,a.qa=c?Number(c.value):0);a.Ha=Math.max(d,a.Ha)}function gw(a,b){if(a.g.defaultPresentationDelay)b=a.g.defaultPresentationDelay;else if(a.xa)b=a.xa;else if(a.qa)b=a.qa;else{b=b.segments.length;var c=a.g.hls.liveSegmentsDelay;c>b-2&&(c=Math.max(1,b-2));b=a.Ha*c}a.l.ii(0);a.l.Xg(b);a.l.Mc(!1)}
1066
+ function jw(a,b,c,d,e){var f=pv(c,"EXT-X-MAP");if(!f)return null;var g=kv(f,"URI"),h=rv(d(),g,e);g=[h.toString(),Y(f,"BYTERANGE","")].join("-");if(!a.ba.has(g)){var k=void 0,l=null;c=t(c);for(var m=c.next();!m.done;m=c.next())m=m.value,"EXT-X-KEY"==m.name?ww(kv(m,"METHOD"))&&m.id<f.id&&(k=Jw(a,m,b,d,e)):"EXT-X-BYTERANGE"==m.name&&m.id<f.id&&(l=m);b=Kw(h,f,l,k);a.ba.set(g,b)}return a.ba.get(g)}
1067
+ function Kw(a,b,c,d){var e=0,f=null;b=Y(b,"BYTERANGE");!b&&c&&(b=c.value);b&&(e=b.split("@"),f=Number(e[0]),e=Number(e[1]),f=e+f-1,d&&(c=f+1-e,c%16&&(f+=16-c%16)));return new Gi(function(){return a},e,f,null,null,null,d)}
1068
+ function Lw(a,b,c,d,e,f,g,h,k){var l=d.g,m=pv(l,"EXTINF"),n=0,p=0,r=null;d.Rb.length&&!a.G&&Ya("Low-latency HLS 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.");var u=null;if(!a.g.hls.ignoreManifestProgramDateTime){var v=pv(l,"EXT-X-PROGRAM-DATE-TIME");v&&v.value&&(u=wh(v.value))}var w=Ji;pv(l,"EXT-X-GAP")&&(w=2);if(!m){if(0==d.Rb.length)throw new U(2,4,4024,"EXTINF");
1069
+ if(!a.G)return null}var A=[];v=!1;var z=null,C=!1,y=!1;if(a.G&&d.Rb.length){n=b&&window.ReadableStream&&a.g.hls.allowLowLatencyByteRangeOptimization;for(var B=u,D={},K=0;K<d.Rb.length;D={Gd:D.Gd,we:D.we},K++){var G=d.Rb[K],J=0==K?c:A[A.length-1],I=0==K?e:J.endTime,H=Number(Y(G,"DURATION"))||a.R;if(H){var N=I+H,L=0,M=null;"EXT-X-PRELOAD-HINT"==G.name?(L=(L=Y(G,"BYTERANGE-START"))?Number(L):0,(J=Y(G,"BYTERANGE-LENGTH"))?M=L+Number(J)-1:L&&(M=Number.MAX_SAFE_INTEGER)):(L=Y(G,"BYTERANGE"),M=t(lw(J,L)),
1070
+ L=M.next().value,M=M.next().value);D.we=Y(G,"URI");if(D.we){J=Ji;"YES"==Y(G,"GAP")&&(J=2,C=!0);D.Gd=null;var Q=function(R){return function(){null==R.Gd&&(R.Gd=rv(h(),R.we,f));return R.Gd}}(D);n&&0<=L&&null!=M&&(z=Q,v=!0);I=new Ii(I,N,Q,L,M,b,0,0,Infinity,[],"",null,B,J,k);"EXT-X-PRELOAD-HINT"==G.name&&(I.Hg(),y=!0);"YES"!=Y(G,"INDEPENDENT")&&0<K&&I.Ve();A.push(I);B&&(B+=H)}}}}if(m){m=Number(m.value.split(",")[0]);if(0==m)return null;n=e+m}else if(A.length)n=A[A.length-1].endTime;else return null;
1071
+ v&&(C||0!=A[0].Wa?(v=!1,z=null):A=[]);(m=pv(l,"EXT-X-BYTERANGE"))?(r=t(lw(c,m.value)),p=r.next().value,r=r.next().value):A.length&&(p=A[0].Wa,r=A[A.length-1].Da);c="";m=null;"image"==g&&(c="1x1",g=pv(l,"EXT-X-TILES"))&&(c=kv(g,"LAYOUT"),(g=Y(g,"DURATION"))&&(m=Number(g)));var T=null;b=new Ii(e,n,function(){if(z)return z();null==T&&(T=rv(h(),d.h,f));return T||[]},p,r,b,0,0,Infinity,A,c,m,u,w,k,0<A.length&&!!d.h);v&&(a.Za=!0,b.Qh(),y&&b.Hg());return b}
1072
+ function lw(a,b){var c=0,d=null;b&&(c=b.split("@"),b=Number(c[0]),c=c[1]?Number(c[1]):a.Da+1,d=c+b-1);return[c,d]}
1073
+ function Pv(a,b,c,d,e,f){var g=b.segments,h=void 0,k=qv(b.g,"EXT-X-DISCONTINUITY-SEQUENCE",0),l=qv(b.g,"EXT-X-MEDIA-SEQUENCE",0),m=pv(b.g,"EXT-X-SKIP"),n=m?Number(Y(m,"SKIPPED-SEGMENTS")):0,p=l+n,r=0;Gv(a)&&c.has(p)&&(r=c.get(p));0===r&&a.na==mw&&0<c.size&&!c.has(p)&&(r=a.l.Cb());var u=[],v=null;m=[];for(var w=0;w<g.length;w++){var A=g[w],z=0==w?r:v.endTime;p=l+n+w;pv(A.g,"EXT-X-DISCONTINUITY")&&k++;var C=t(A.g);for(var y=C.next();!y.done;y=C.next())y=y.value,"EXT-X-KEY"==y.name&&(ww(kv(y,"METHOD"))?
1074
+ h=Jw(a,y,b,e,d):h=void 0);c.set(p,z);C=jw(a,b,A.g,e,d);!a.G&&a.h.isAutoLowLatencyMode()&&(a.h.enableLowLatencyMode(),a.G=a.h.isLowLatencyMode());if(z=Lw(a,C,v,A,z,d,f,e,h))(v=qv(A.g,"EXT-X-BITRATE"))?m.push({bitrate:v,duration:z.endTime-z.startTime}):m.length&&(v=m.pop(),v.duration+=z.endTime-z.startTime,m.push(v)),v=z,z.j=k,Tv(a,f)&&null!=a.K&&p<a.K||u.push(z)}b=void 0;m.length&&(b=m.reduce(function(B,D){return B+D.duration},0),b=Math.round(m.reduce(function(B,D){return B+D.bitrate*D.duration},0)/
1074
1075
  b*1E3));if(m=u.some(function(B){return null!=B.h}))for(c={},d=0;d<u.length;c={vd:c.vd,ud:c.ud,pe:c.pe,cc:c.cc,rd:c.rd},d++)if(c.cc=u[d],null==c.cc.h)for(c.ud=0,c.vd=d,e=function(B){return function(){var D=u[B.vd];if(D){if(null!=D.h)return D.h+B.ud;B.ud-=D.endTime-D.startTime;B.vd+=1}return null}}(c),c.rd=0,c.pe=d,g=function(B){return function(){var D=u[B.pe];if(D){D!=B.cc&&(B.rd+=D.endTime-D.startTime);if(null!=D.h)return D.h+B.rd;--B.pe}return null}}(c);null==c.cc.h;)c.cc.h=g(),null==c.cc.h&&(c.cc.h=
1075
- e());if(m)for(c=t(u),d=c.next();!d.done;d=c.next())for(e=d.value,d=e.h,e=t(e.g),g=e.next();!g.done;g=e.next())g=g.value,g.h=d,d+=g.endTime-g.startTime;c=a.$;if(m&&Infinity!=c&&!Sv(a,f))for(a=t(u),d=a.next();!d.done;d=a.next())d.value.fh(c);return{segments:u,bandwidth:b}}function pw(a,b){if(a==Sc){if("vtt"==b||"wvtt"==b)return"text/vtt";if(b&&""!==b)return"application/mp4"}return"image"!=a||b&&"jpeg"!=b?"audio"==a&&"mp4a.40.34"==b?"audio/mpeg":"mjpg"==b?"application/mp4":null:"image/jpeg"}
1076
- function qw(a){return a==Sc?"text/vtt":Lw[a].mp4}
1077
- function Hw(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v,w,A;return O(function(z){switch(z.g){case 1:e=Gg;f=Math.trunc((d.length-1)/2);for(g=d[f];2==g.status&&f<d.length;)f++,g=d[f];if(2==g.status)return z.return(qw(b));h=g.P();k=new mb(h[0]);l=k.pb.split(".").pop();m=Lw[b];if((n=m[l])||(n=hw[l])||(n=pw(b,c)))return z.return(n);r=1;u=Ag(h,a.g.retryParameters);ta(z,2);u.method="HEAD";return E(z,jw(a,u,e,{type:r}),4);case 4:v=z.h;p=v.headers["content-type"];va(z,3);break;case 2:w=wa(z);if(!w||1002!=w.code&&
1078
- 1001!=w.code){z.B(3);break}u.method="GET";return E(z,jw(a,u,e,{type:r}),6);case 6:A=z.h,p=A.headers["content-type"];case 3:return p?z.return(p.toLowerCase().split(";")[0]):z.return(qw(b))}})}function ew(a,b,c,d,e,f,g){a&&(a.width=Number(b)||void 0,a.height=Number(c)||void 0,a.frameRate=Number(d)||void 0,a.hdr=e||void 0,a.videoLayout=f||void 0,a.colorGamut=g||void 0)}function Dv(a,b,c){return jw(a,Ag(b,a.g.retryParameters),0,{type:c?2:3})}
1079
- function Bv(a){var b,c,d,e,f,g;O(function(h){switch(h.g){case 1:if(!a.h)return h.return();ta(h,2);b=Date.now();return E(h,a.update(),4);case 4:c=Date.now();Fv(a)&&(d=(c-b)/1E3,a.Na.sample(1,d),e=a.m,f=Math.max(0,e-md(a.Na)),a.A.V(f));va(h,3);break;case 2:g=wa(h);if(!a.h)return h.return();if(a.g.raiseFatalErrorOnManifestUpdateRequestFailure)return a.h.onError(g),h.return();g.severity=1;a.h.onError(g);a.A.V(.1);case 3:if(!a.h)return h.return();a.h.onManifestUpdated();F(h)}})}
1080
- function Fv(a){return a.na!=Cv}function Jv(a,b){a.na=b;a.l&&a.l.Lc(!Fv(a));Fv(a)||a.A.stop()}function jw(a,b,c,d){if(!a.S)throw new U(2,7,7001);b=a.h.networkingEngine.request(c,b,d);ug(a.S,b);return b.promise}function vw(a){return"AES-128"==a||"AES-256"==a||"AES-256-CTR"==a}
1081
- function xw(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,u,v,w,A,z,C,y;return O(function(B){switch(B.g){case 1:if("video/mp2t"==c)throw new U(2,4,4040);if(tc())throw new U(2,4,4041);g=jv(b,"METHOD");h=["SAMPLE-AES","SAMPLE-AES-CTR"];if(!h.includes(g))return B.return(null);k=qv(d(),jv(b,"URI"),f);if(k[0].startsWith("data:text/plain;base64,")){l=Jc(Hc(k[0].split("data:text/plain;base64,").pop()));B.B(2);break}m=k.sort().join("");a.Aa.has(m)||(n=Ag(k,a.g.retryParameters),p=jw(a,n,6),a.Aa.set(m,p));return E(B,a.Aa.get(m),
1082
- 3);case 3:r=B.h,l=Jc(r.data);case 2:u="00000000000000000000000000000000";if(!e){B.B(4);break}if(a.ma.has(e)){v=a.ma.get(e);B.B(5);break}w=Bl(e.P(),e.Pb(),e.Nb(),a.g.retryParameters);A=Gg;return E(B,jw(a,w,A,{type:0}),6);case 6:z=B.h,v=Ht(z.data),a.ma.set(e,v);case 5:v&&(u=v);case 4:return C=new Map,C.set(u,l),y="cenc","SAMPLE-AES"==g&&(y="cbcs"),B.return(Nc(C,y))}})}P("shaka.hls.HlsParser",Av);
1083
- var hw={aac:"audio/aac",ac3:"audio/ac3",ec3:"audio/ec3",mp3:"audio/mpeg"},Lw={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",
1084
- 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"}},ww={"com.apple.streamingkeydelivery":function(a,b){if("video/mp2t"==b)throw new U(2,4,4040);if(tc())throw new U(2,4,4041);a=jv(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(a))return null;b="cenc";"SAMPLE-AES"==a&&(b="cbcs");return Mc("com.apple.fps",b,[{initDataType:"sinf",initData:new Uint8Array(0),keyId:null}])},"urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":function(a){var b=
1085
- jv(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;var c="cenc";"SAMPLE-AES"==b&&(c="cbcs");b=jv(a,"URI");b=zv(b.split("?")[0]);b=Gb(b.data);c=Mc("com.widevine.alpha",c,[{initDataType:"cenc",initData:b}]);if(a=Y(a,"KEYID"))c.keyIds=new Set([a.toLowerCase().substr(2)]);return c},"com.microsoft.playready":function(a){var b=jv(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;var c="cenc";"SAMPLE-AES"==b&&(c="cbcs");a=jv(a,"URI");a=zv(a.split("?")[0]);a=
1086
- Gb(a.data);b=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);a=ah(a,b,new Set,0);return Mc("com.microsoft.playready",c,[{initDataType:"cenc",initData:a}])}},Cv="VOD",Gw="EVENT",lw="LIVE",Iv={Ci:Cv,Rk:Gw,Zk:lw};Bi["application/x-mpegurl"]=function(){return new Av};Bi["application/vnd.apple.mpegurl"]=function(){return new Av};function Mw(a){var b=0,c=Lb(a),d=c.getUint32(b,!0);if(d!=a.byteLength)return[];a:{a=b+6;for(b=[];a<c.byteLength-1;){d=c.getUint16(a,!0);a+=2;var e=c.getUint16(a,!0);a+=2;if(0!=(e&1)||e+a>c.byteLength){c=[];break a}var f=Gb(c,a,e);b.push({type:d,value:f});a+=e}c=b}return c}function Nw(a){if(a=Ow(a))a:{a=t(nh(a,"DATA"));for(var b=a.next();!b.done;b=a.next())if(b=oh(b.value,"LA_URL")){a=lh(b);break a}a=""}else a="";return a}
1087
- function Ow(a){a=Hc(lh(a));a=Mw(a).filter(function(b){return b.type===Pw})[0];if(!a)return null;a=xc(a.value,!0);return(a=ch(a,"WRMHEADER"))?a:null}var Pw=1,Qw=(new Map).set("com.microsoft.playready",Nw).set("com.microsoft.playready.recommendation",Nw).set("com.microsoft.playready.software",Nw).set("com.microsoft.playready.hardware",Nw);function Rw(a){if(!dx){dx=!0;var b=new Uint8Array([105,115,111,109]),c=new Uint8Array([97,118,99,49]),d=new Uint8Array([0,0,0,1]);ex=fx("ftyp",b,d,b,c);b=fx("dref",gx);hx=fx("dinf",b)}this.g=a}
1088
- function ix(a){for(var b=[],c=t(a.g),d=c.next();!d.done;d=c.next()){var e=b,f=e.push;var g=d.value;d=fx;var h=g.id+1;var k=g.stream.width||0,l=g.stream.height||0;"audio"==g.type&&(l=k=0);var m=g.duration*g.timescale,n=Math.floor(m/(jx+1));m=Math.floor(m%(jx+1));h=new Uint8Array([1,0,0,7,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(x(kx(h,4)),[0,0,0,0],x(kx(n,4)),x(kx(m,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],x(kx(k,2)),[0,0],x(kx(l,
1089
- 2)),[0,0]));h=fx("tkhd",h);k=fx;n=g.duration*g.timescale;l=Math.floor(n/(jx+1));n=Math.floor(n%(jx+1));m=g.stream.language;m=m.charCodeAt(0)-96<<10|m.charCodeAt(1)-96<<5|m.charCodeAt(2)-96;l=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(x(kx(g.timescale,4)),x(kx(l,4)),x(kx(n,4)),x(kx(m,2)),[0,0]));l=fx("mdhd",l);n=g;m=new Uint8Array([]);switch(n.type){case "video":m=lx;break;case "audio":m=mx}n=fx("hdlr",m);a:{switch(g.type){case "video":g=fx("minf",fx("vmhd",nx),hx,ox(g));break a;
1090
- case "audio":g=fx("minf",fx("smhd",px),hx,ox(g));break a}g=new Uint8Array([])}g=k("mdia",l,n,g);d=d("trak",h,g);f.call(e,d)}b=Kc.apply(Ec,x(b));f=a.g[0];c=fx;d=f.duration*f.timescale;e=Math.floor(d/(jx+1));d=Math.floor(d%(jx+1));e=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(x(kx(f.timescale,4)),x(kx(e,4)),x(kx(d,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,
1091
- 255]));e=fx("mvhd",e);d=[];a=t(a.g);for(k=a.next();!k.done;k=a.next())g=d,h=g.push,k=new Uint8Array([0,0,0,0].concat(x(kx(k.value.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1])),k=fx("trex",k),h.call(g,k);a=Kc.apply(Ec,x(d));a=fx("mvex",a);d=[];if(f.encrypted){f=t(f.stream.drmInfos);for(g=f.next();!g.done;g=f.next())if(g=g.value,g.initData)for(g=t(g.initData),h=g.next();!h.done;h=g.next())d.push(h.value.initData);f=Kc.apply(Ec,x(d))}else f=new Uint8Array([]);a=c("moov",e,b,a,f);b=new Uint8Array(ex.byteLength+
1092
- a.byteLength);b.set(ex);b.set(a,ex.byteLength);return b}
1093
- function ox(a){var b=fx,c=new Uint8Array([]);switch(a.type){case "video":if(a.codecs.includes("avc1")){c=a.stream.width||0;var d=a.stream.height||0;if(0<a.Ma.byteLength)var e=fx("avcC",a.Ma);else{e=fx;for(var f=7,g=[],h=[],k=0,l=0,m=0,n=0;n<a.ub.length;n++){var p=qx(a.ub[n]);switch(p[0]&31){case 7:g.push(p);f+=p.length+2;break;case 8:h.push(p),f+=p.length+2}}0<g.length&&(k=g[0][1],m=g[0][2],l=g[0][3]);f=new Uint8Array(f);n=0;f[n++]=1;f[n++]=k;f[n++]=m;f[n++]=l;f[n++]=255;f[n++]=224|g.length;for(k=
1094
- 0;k<g.length;k++)f[n++]=(g[k].length&65280)>>8,f[n++]=g[k].length&255,f.set(g[k],n),n+=g[k].length;f[n++]=h.length;for(g=0;g<h.length;g++)f[n++]=(h[g].length&65280)>>8,f[n++]=h[g].length&255,f.set(h[g],n),n+=h[g].length;e=e("avcC",f)}c=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(x(kx(c,2)),x(kx(d,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]));d="avc1";h=rx(a);g=new Uint8Array([]);
1095
- a.encrypted&&(g=sx(a),d="encv");c=fx(d,c,e,h,g)}else a.codecs.includes("hvc1")&&(d=a.stream.width||0,e=a.stream.height||0,c=new Uint8Array([]),0<a.Ma.byteLength&&(c=fx("hvcC",a.Ma)),d=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(x(kx(d,2)),x(kx(e,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])),e="hvc1",h=rx(a),g=new Uint8Array([]),a.encrypted&&(g=sx(a),e="encv"),c=fx(e,d,
1096
- c,h,g));break;case "audio":if(a.codecs.includes("mp3"))a=fx(".mp3",tx(a));else if(a.codecs.includes("ac-3"))c=fx("dac3",a.ya),d="ac-3",e=new Uint8Array([]),a.encrypted&&(e=sx(a),d="enca"),a=fx(d,tx(a),c,e);else if(a.codecs.includes("ec-3"))c=fx("dec3",a.ya),d="ec-3",e=new Uint8Array([]),a.encrypted&&(e=sx(a),d="enca"),a=fx(d,tx(a),c,e);else if(a.codecs.includes("opus"))c=fx("dOps",a.ya),d="Opus",e=new Uint8Array([]),a.encrypted&&(e=sx(a),d="enca"),a=fx(d,tx(a),c,e);else{if(0<a.ya.byteLength)c=fx("esds",
1097
- a.ya);else{c=fx;d=a.id+1;e=a.stream.channelsCount||2;g=a.stream.audioSamplingRate||44100;k=Oc("audio",a.codecs.split(","));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};h=l[g];if("mp4a.40.5"===k||"mp4a.40.29"===k)h=l[2*g];g=parseInt(k.split(".").pop(),10);d=new Uint8Array([0,0,0,0,3,25].concat(x(kx(d,2)),[0,4,17,64,21,0,0,0,0,0,0,0,0,0,0,0,5,2,g<<3|h>>>1,h<<7|e<<3,6,1,2]));c=c("esds",d)}d="mp4a";e=new Uint8Array([]);a.encrypted&&(e=sx(a),d="enca");
1098
- a=fx(d,tx(a),c,e)}c=a}a=fx("stsd",ux,c);return b("stbl",a,fx("stts",vx),fx("stsc",wx),fx("stsz",xx),fx("stco",yx))}function rx(a){if(!a.Sa&&!a.Ua)return new Uint8Array([]);var b=a.Ua;a=new Uint8Array([].concat(x(kx(a.Sa,4)),x(kx(b,4))));return fx("pasp",a)}function tx(a){return new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,a.stream.channelsCount||2,0,16,0,0,0,0].concat(x(kx(a.stream.audioSamplingRate||44100,2)),[0,0]))}
1099
- function sx(a){var b=fx;var c=a.codecs.substring(0,a.codecs.indexOf("."));for(var d=0,e=0;e<c.length;e+=1)d|=c.charCodeAt(e)<<8*(c.length-e-1);c=new Uint8Array([].concat(x(kx(d,4))));c=fx("frma",c);d=new Uint8Array([0,0,0,0,99,101,110,99,0,1,0,0]);d=fx("schm",d);e=fx;var f=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]);a=t(a.stream.drmInfos);for(var g=a.next();!g.done;g=a.next())if((g=g.value)&&g.keyIds&&g.keyIds.size){g=t(g.keyIds);for(var h=g.next();!h.done;h=g.next())f=qx(h.value)}a=new Uint8Array([0,
1100
- 0,0,0,0,0,1,8]);f=fx("tenc",a,f);return b("sinf",c,d,e("schi",f))}
1101
- function zx(a){var b=[];a=t(a.g);for(var c=a.next();!c.done;c=a.next()){c=c.value;var d=b.push,e=d.apply;var f=fx;var g=new Uint8Array([0,0,0,0].concat(x(kx(c.data?c.data.Ib:0,4))));g=fx("mfhd",g);var h;var k=c.data?c.data.rb:[];var l=new Uint8Array(4+k.length);for(h=0;h<k.length;h++){var m=k[h].flags;l[h+4]=m.ib<<4|m.mb<<2|m.kb}k=fx("sdtp",l);var n=k.length+92;l=fx;h=new Uint8Array([0,0,0,58].concat(x(kx(c.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0]));h=fx("tfhd",h);m=c.data?c.data.baseMediaDecodeTime:
1102
- 0;var p=Math.floor(m%(jx+1));m=new Uint8Array([1,0,0,0].concat(x(kx(Math.floor(m/(jx+1)),4)),x(kx(p,4))));m=fx("tfdt",m);var r=n;n=c.data?c.data.rb:[];p=n.length;var u=12+16*p,v=new Uint8Array(u);r+=8+u;v.set(["video"===c.type?1:0,0,15,1].concat(x(kx(p,4)),x(kx(r,4))),0);for(r=0;r<p;r++){var w=n[r];u=kx(w.duration,4);var A=kx(w.size,4),z=w.flags;w=kx(w.wb,4);v.set([].concat(x(u),x(A),[z.xb<<2|z.ib,z.mb<<6|z.kb<<4|z.yb,z.hb&61440,z.hb&15],x(w)),12+16*r)}n=fx("trun",v);k=l("traf",h,m,n,k);f=f("moof",
1103
- g,k);e.call(d,b,[f,Ax(c)])}return Kc.apply(Ec,x(b))}function Ax(a){a=(a.data?a.data.rb:[]).map(function(b){return b.data});a=Kc.apply(Ec,x(a));return fx("mdat",a)}function kx(a,b){var c=[];for(--b;0<=b;b--)c.push(a>>8*b&255);return c}function qx(a){for(var b=new Uint8Array(a.length/2),c=0;c<a.length/2;c+=1)b[c]=parseInt(String(a[2*c]+a[2*c+1]),16);return b}
1104
- function fx(a){var b=Ka.apply(1,arguments),c=Bx[a];c||(c=[a.charCodeAt(0),a.charCodeAt(1),a.charCodeAt(2),a.charCodeAt(3)],Bx[a]=c);for(var d=8,e=b.length-1;0<=e;e--)d+=b[e].byteLength;e=new Uint8Array(d);e[0]=d>>24&255;e[1]=d>>16&255;e[2]=d>>8&255;e[3]=d&255;e.set(c,4);c=0;for(d=8;c<b.length;c++)e.set(b[c],d),d+=b[c].byteLength;return e}
1105
- var dx=!1,jx=Math.pow(2,32)-1,Bx={},lx=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]),mx=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]),vx=new Uint8Array([0,0,0,0,0,0,0,0]),wx=new Uint8Array([0,0,0,0,0,0,0,0]),yx=new Uint8Array([0,0,0,0,0,0,0,0]),xx=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),nx=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0]),px=new Uint8Array([0,
1106
- 0,0,0,0,0,0,0]),ux=new Uint8Array([0,0,0,0,0,0,0,1]),ex=new Uint8Array([]),gx=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),hx=new Uint8Array([]);function Cx(){var a=this;this.h=this.g=null;this.l=[];this.j=null;this.u=1;this.i=null;this.F=new ld(5);this.o=new Ub(function(){Dx(a)});this.A=new tg;this.m=new Map}q=Cx.prototype;q.configure=function(a){this.g=a};q.start=function(a,b){var c=this;return O(function(d){if(1==d.g)return c.l=[a],c.h=b,E(d,Ex(c),2);if(!c.h)throw new U(2,7,7001);return d.return(c.j)})};
1107
- function Dx(a){var b;O(function(c){switch(c.g){case 1:return ta(c,2),E(c,Ex(a),4);case 4:va(c,3);break;case 2:b=wa(c),a.h&&(b.severity=1,a.h.onError(b));case 3:if(!a.h)return c.return();F(c)}})}q.stop=function(){this.g=this.h=null;this.l=[];this.j=null;null!=this.o&&(this.o.stop(),this.o=null);this.m.clear();return this.A.destroy()};
1108
- q.update=function(){var a=this,b;return O(function(c){if(1==c.g)return ta(c,2),E(c,Ex(a),4);if(2!=c.g)return va(c,0);b=wa(c);if(!a.h||!b)return c.return();a.h.onError(b);F(c)})};q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(){};q.banLocation=function(){};
1109
- function Ex(a){var b,c,d,e,f,g,h;return O(function(k){if(1==k.g)return b=Ag(a.l,a.g.retryParameters),c=a.h.networkingEngine,d=Date.now(),e=c.request(0,b,{type:5}),ug(a.A,e),E(k,e.promise,2);f=k.h;if(!a.h)return k.return();f.uri&&!a.l.includes(f.uri)&&a.l.unshift(f.uri);var l=f.uri,m=f.data,n=a.g.mss.manifestPreprocessor;if(n!=wm){xd("manifest.mss.manifestPreprocessor configuration","Please Use manifest.mss.manifestPreprocessorTXml instead.");m=yu(m,"SmoothStreamingMedia");if(!m)throw new U(2,4,4046,
1110
- l);n(m);m=Ac(m.outerHTML)}var p=bh(m,"SmoothStreamingMedia");if(!p)throw new U(2,4,4046,l);l=a.g.mss.manifestPreprocessorTXml;l!=xm&&l(p);a.i||(a.i=new Bk(null,0));if(l=th(p,"IsLive",Dh,!1))throw new U(2,4,4047);a.i.Lc(!l);n=th(p,"TimeScale",Bh,1E7);m=th(p,"DVRWindowLength",Bh);l&&(0===m||isNaN(m))&&(m=Infinity);var r=th(p,"CanSeek",Dh,!1);0===m&&r&&(m=Infinity);r=null;m&&0<m&&(r=m/n);l&&!isNaN(a.g.availabilityWindowOverride)&&(r=a.g.availabilityWindowOverride);null==r&&(r=Infinity);a.i.nf(r);m=th(p,
1111
- "Duration",Bh,Infinity);l||a.i.sb(m/n);l={variants:[],textStreams:[],timescale:n,duration:m/n};r=kh(p,"Protection");var u;n=a.g.mss.keySystemsBySystemId;m=[];r=t(r);for(u=r.next();!u.done;u=r.next())m=m.concat(kh(u.value,"ProtectionHeader"));if(m.length){r=[];for(u=0;u<m.length;u++){var v=m[u],w=v.attributes.SystemID.toLowerCase(),A=n[w];if(A){var z=Ow(v);if(z)a:{z=t(nh(z,"DATA"));for(var C=z.next();!C.done;C=z.next())if(C=oh(C.value,"KID")){z=Hc(lh(C));z=new Uint8Array([z[3],z[2],z[1],z[0],z[5],
1112
- z[4],z[7],z[6]].concat(x(z.slice(8))));z=Jc(z);break a}z=null}else z=null;C=Hc(lh(v));w=Ic(w.replace(/-/g,""));w=[{initData:ah(C,w,new Set,0),initDataType:"cenc",keyId:z}];w=Mc(A,"cenc",w);z&&w.keyIds.add(z);if(A=Qw.get(A))w.licenseServerUri=A(v);r.push(w)}}n=r}else n=[];u=n;r=[];n=[];m=[];p=kh(p,"StreamIndex");p=t(p);for(v=p.next();!v.done;v=p.next()){v=v.value;A=kh(v,"QualityLevel");w=l.timescale;z=l.duration;C=kh(v,"c");for(var y=[],B=0,D=0;D<C.length;++D){var K=C[D],G=C[D+1],J=th(K,"t",Bh),I=
1113
- th(K,"d",Bh);K=th(K,"r",zh);if(!I)break;J=null!=J?J:B;K=K||0;if(0>K)if(G){G=th(G,"t",Bh);if(null==G)break;else if(J>=G)break;K=Math.ceil((G-J)/I)-1}else{if(Infinity==z)break;else if(J/w>=z)break;K=Math.ceil((z*w-J)/I)-1}for(G=0;G<=K;++G)B=J+I,y.push({start:J/w,end:B/w,kh:J}),J=B}w=y;A=t(A);for(z=A.next();!z.done;z=A.next())(z=Fx(a,v,z.value,w,u,l))&&("audio"!=z.type||a.g.disableAudio?"video"!=z.type||a.g.disableVideo?z.type!=Sc||a.g.disableText||m.push(z):n.push(z):r.push(z))}p=[];r=t(0<r.length?
1076
+ e());if(m)for(c=t(u),d=c.next();!d.done;d=c.next())for(e=d.value,d=e.h,e=t(e.g),g=e.next();!g.done;g=e.next())g=g.value,g.h=d,d+=g.endTime-g.startTime;c=a.$;if(m&&Infinity!=c&&!Tv(a,f))for(a=t(u),d=a.next();!d.done;d=a.next())d.value.fh(c);return{segments:u,bandwidth:b}}function qw(a,b){if(a==Sc){if("vtt"==b||"wvtt"==b)return"text/vtt";if(b&&""!==b)return"application/mp4"}return"image"!=a||b&&"jpeg"!=b?"audio"==a&&"mp4a.40.34"==b?"audio/mpeg":"mjpg"==b?"application/mp4":null:"image/jpeg"}
1077
+ function rw(a){return a==Sc?"text/vtt":Mw[a].mp4}
1078
+ function Iw(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v,w,A;return O(function(z){switch(z.g){case 1:e=Gg;f=Math.trunc((d.length-1)/2);for(g=d[f];2==g.status&&f<d.length;)f++,g=d[f];if(2==g.status)return z.return(rw(b));h=g.P();k=new mb(h[0]);l=k.pb.split(".").pop();m=Mw[b];if((n=m[l])||(n=iw[l])||(n=qw(b,c)))return z.return(n);r=1;u=Ag(h,a.g.retryParameters);ta(z,2);u.method="HEAD";return E(z,kw(a,u,e,{type:r}),4);case 4:v=z.h;p=v.headers["content-type"];va(z,3);break;case 2:w=wa(z);if(!w||1002!=w.code&&
1079
+ 1001!=w.code){z.B(3);break}u.method="GET";return E(z,kw(a,u,e,{type:r}),6);case 6:A=z.h,p=A.headers["content-type"];case 3:return p?z.return(p.toLowerCase().split(";")[0]):z.return(rw(b))}})}function fw(a,b,c,d,e,f,g){a&&(a.width=Number(b)||void 0,a.height=Number(c)||void 0,a.frameRate=Number(d)||void 0,a.hdr=e||void 0,a.videoLayout=f||void 0,a.colorGamut=g||void 0)}function Ev(a,b,c){return kw(a,Ag(b,a.g.retryParameters),0,{type:c?2:3})}
1080
+ function Cv(a){var b,c,d,e,f,g;O(function(h){switch(h.g){case 1:if(!a.h)return h.return();ta(h,2);b=Date.now();return E(h,a.update(),4);case 4:c=Date.now();Gv(a)&&(d=(c-b)/1E3,a.Na.sample(1,d),e=a.m,f=Math.max(0,e-md(a.Na)),a.A.V(f));va(h,3);break;case 2:g=wa(h);if(!a.h)return h.return();if(a.g.raiseFatalErrorOnManifestUpdateRequestFailure)return a.h.onError(g),h.return();g.severity=1;a.h.onError(g);a.A.V(.1);case 3:if(!a.h)return h.return();a.h.onManifestUpdated();F(h)}})}
1081
+ function Gv(a){return a.na!=Dv}function Kv(a,b){a.na=b;a.l&&a.l.Mc(!Gv(a));Gv(a)||a.A.stop()}function kw(a,b,c,d){if(!a.S)throw new U(2,7,7001);b=a.h.networkingEngine.request(c,b,d);ug(a.S,b);return b.promise}function ww(a){return"AES-128"==a||"AES-256"==a||"AES-256-CTR"==a}
1082
+ function yw(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,u,v,w,A,z,C,y;return O(function(B){switch(B.g){case 1:if("video/mp2t"==c)throw new U(2,4,4040);if(tc())throw new U(2,4,4041);g=kv(b,"METHOD");h=["SAMPLE-AES","SAMPLE-AES-CTR"];if(!h.includes(g))return B.return(null);k=rv(d(),kv(b,"URI"),f);if(k[0].startsWith("data:text/plain;base64,")){l=Jc(Hc(k[0].split("data:text/plain;base64,").pop()));B.B(2);break}m=k.sort().join("");a.Aa.has(m)||(n=Ag(k,a.g.retryParameters),p=kw(a,n,6),a.Aa.set(m,p));return E(B,a.Aa.get(m),
1083
+ 3);case 3:r=B.h,l=Jc(r.data);case 2:u="00000000000000000000000000000000";if(!e){B.B(4);break}if(a.ma.has(e)){v=a.ma.get(e);B.B(5);break}w=Bl(e.P(),e.Pb(),e.Nb(),a.g.retryParameters);A=Gg;return E(B,kw(a,w,A,{type:0}),6);case 6:z=B.h,v=Ht(z.data),a.ma.set(e,v);case 5:v&&(u=v);case 4:return C=new Map,C.set(u,l),y="cenc","SAMPLE-AES"==g&&(y="cbcs"),B.return(Nc(C,y))}})}P("shaka.hls.HlsParser",Bv);
1084
+ var iw={aac:"audio/aac",ac3:"audio/ac3",ec3:"audio/ec3",mp3:"audio/mpeg"},Mw={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",
1085
+ 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"}},xw={"com.apple.streamingkeydelivery":function(a,b){if("video/mp2t"==b)throw new U(2,4,4040);if(tc())throw new U(2,4,4041);a=kv(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(a))return null;b="cenc";"SAMPLE-AES"==a&&(b="cbcs");return Mc("com.apple.fps",b,[{initDataType:"sinf",initData:new Uint8Array(0),keyId:null}])},"urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":function(a){var b=
1086
+ kv(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;var c="cenc";"SAMPLE-AES"==b&&(c="cbcs");b=kv(a,"URI");b=Av(b.split("?")[0]);b=Gb(b.data);c=Mc("com.widevine.alpha",c,[{initDataType:"cenc",initData:b}]);if(a=Y(a,"KEYID"))c.keyIds=new Set([a.toLowerCase().substr(2)]);return c},"com.microsoft.playready":function(a){var b=kv(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;var c="cenc";"SAMPLE-AES"==b&&(c="cbcs");a=kv(a,"URI");a=Av(a.split("?")[0]);a=
1087
+ Gb(a.data);b=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);a=ah(a,b,new Set,0);return Mc("com.microsoft.playready",c,[{initDataType:"cenc",initData:a}])}},Dv="VOD",Hw="EVENT",mw="LIVE",Jv={Ci:Dv,Rk:Hw,Zk:mw};Bi["application/x-mpegurl"]=function(){return new Bv};Bi["application/vnd.apple.mpegurl"]=function(){return new Bv};function Nw(a){var b=0,c=Lb(a),d=c.getUint32(b,!0);if(d!=a.byteLength)return[];a:{a=b+6;for(b=[];a<c.byteLength-1;){d=c.getUint16(a,!0);a+=2;var e=c.getUint16(a,!0);a+=2;if(0!=(e&1)||e+a>c.byteLength){c=[];break a}var f=Gb(c,a,e);b.push({type:d,value:f});a+=e}c=b}return c}function Ow(a){if(a=Pw(a))a:{a=t(nh(a,"DATA"));for(var b=a.next();!b.done;b=a.next())if(b=oh(b.value,"LA_URL")){a=lh(b);break a}a=""}else a="";return a}
1088
+ function Pw(a){a=Hc(lh(a));a=Nw(a).filter(function(b){return b.type===Qw})[0];if(!a)return null;a=xc(a.value,!0);return(a=ch(a,"WRMHEADER"))?a:null}var Qw=1,Rw=(new Map).set("com.microsoft.playready",Ow).set("com.microsoft.playready.recommendation",Ow).set("com.microsoft.playready.software",Ow).set("com.microsoft.playready.hardware",Ow);function Sw(a){if(!ex){ex=!0;var b=new Uint8Array([105,115,111,109]),c=new Uint8Array([97,118,99,49]),d=new Uint8Array([0,0,0,1]);fx=gx("ftyp",b,d,b,c);b=gx("dref",hx);ix=gx("dinf",b)}this.g=a}
1089
+ function jx(a){for(var b=[],c=t(a.g),d=c.next();!d.done;d=c.next()){var e=b,f=e.push;var g=d.value;d=gx;var h=g.id+1;var k=g.stream.width||0,l=g.stream.height||0;"audio"==g.type&&(l=k=0);var m=g.duration*g.timescale,n=Math.floor(m/(kx+1));m=Math.floor(m%(kx+1));h=new Uint8Array([1,0,0,7,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(x(lx(h,4)),[0,0,0,0],x(lx(n,4)),x(lx(m,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],x(lx(k,2)),[0,0],x(lx(l,
1090
+ 2)),[0,0]));h=gx("tkhd",h);k=gx;n=g.duration*g.timescale;l=Math.floor(n/(kx+1));n=Math.floor(n%(kx+1));m=g.stream.language;m=m.charCodeAt(0)-96<<10|m.charCodeAt(1)-96<<5|m.charCodeAt(2)-96;l=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(x(lx(g.timescale,4)),x(lx(l,4)),x(lx(n,4)),x(lx(m,2)),[0,0]));l=gx("mdhd",l);n=g;m=new Uint8Array([]);switch(n.type){case "video":m=mx;break;case "audio":m=nx}n=gx("hdlr",m);a:{switch(g.type){case "video":g=gx("minf",gx("vmhd",ox),ix,px(g));break a;
1091
+ case "audio":g=gx("minf",gx("smhd",qx),ix,px(g));break a}g=new Uint8Array([])}g=k("mdia",l,n,g);d=d("trak",h,g);f.call(e,d)}b=Kc.apply(Ec,x(b));f=a.g[0];c=gx;d=f.duration*f.timescale;e=Math.floor(d/(kx+1));d=Math.floor(d%(kx+1));e=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(x(lx(f.timescale,4)),x(lx(e,4)),x(lx(d,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,
1092
+ 255]));e=gx("mvhd",e);d=[];a=t(a.g);for(k=a.next();!k.done;k=a.next())g=d,h=g.push,k=new Uint8Array([0,0,0,0].concat(x(lx(k.value.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1])),k=gx("trex",k),h.call(g,k);a=Kc.apply(Ec,x(d));a=gx("mvex",a);d=[];if(f.encrypted){f=t(f.stream.drmInfos);for(g=f.next();!g.done;g=f.next())if(g=g.value,g.initData)for(g=t(g.initData),h=g.next();!h.done;h=g.next())d.push(h.value.initData);f=Kc.apply(Ec,x(d))}else f=new Uint8Array([]);a=c("moov",e,b,a,f);b=new Uint8Array(fx.byteLength+
1093
+ a.byteLength);b.set(fx);b.set(a,fx.byteLength);return b}
1094
+ function px(a){var b=gx,c=new Uint8Array([]);switch(a.type){case "video":if(a.codecs.includes("avc1")){c=a.stream.width||0;var d=a.stream.height||0;if(0<a.Ma.byteLength)var e=gx("avcC",a.Ma);else{e=gx;for(var f=7,g=[],h=[],k=0,l=0,m=0,n=0;n<a.ub.length;n++){var p=rx(a.ub[n]);switch(p[0]&31){case 7:g.push(p);f+=p.length+2;break;case 8:h.push(p),f+=p.length+2}}0<g.length&&(k=g[0][1],m=g[0][2],l=g[0][3]);f=new Uint8Array(f);n=0;f[n++]=1;f[n++]=k;f[n++]=m;f[n++]=l;f[n++]=255;f[n++]=224|g.length;for(k=
1095
+ 0;k<g.length;k++)f[n++]=(g[k].length&65280)>>8,f[n++]=g[k].length&255,f.set(g[k],n),n+=g[k].length;f[n++]=h.length;for(g=0;g<h.length;g++)f[n++]=(h[g].length&65280)>>8,f[n++]=h[g].length&255,f.set(h[g],n),n+=h[g].length;e=e("avcC",f)}c=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(x(lx(c,2)),x(lx(d,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]));d="avc1";h=sx(a);g=new Uint8Array([]);
1096
+ a.encrypted&&(g=tx(a),d="encv");c=gx(d,c,e,h,g)}else a.codecs.includes("hvc1")&&(d=a.stream.width||0,e=a.stream.height||0,c=new Uint8Array([]),0<a.Ma.byteLength&&(c=gx("hvcC",a.Ma)),d=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(x(lx(d,2)),x(lx(e,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])),e="hvc1",h=sx(a),g=new Uint8Array([]),a.encrypted&&(g=tx(a),e="encv"),c=gx(e,d,
1097
+ c,h,g));break;case "audio":if(a.codecs.includes("mp3"))a=gx(".mp3",ux(a));else if(a.codecs.includes("ac-3"))c=gx("dac3",a.ya),d="ac-3",e=new Uint8Array([]),a.encrypted&&(e=tx(a),d="enca"),a=gx(d,ux(a),c,e);else if(a.codecs.includes("ec-3"))c=gx("dec3",a.ya),d="ec-3",e=new Uint8Array([]),a.encrypted&&(e=tx(a),d="enca"),a=gx(d,ux(a),c,e);else if(a.codecs.includes("opus"))c=gx("dOps",a.ya),d="Opus",e=new Uint8Array([]),a.encrypted&&(e=tx(a),d="enca"),a=gx(d,ux(a),c,e);else{if(0<a.ya.byteLength)c=gx("esds",
1098
+ a.ya);else{c=gx;d=a.id+1;e=a.stream.channelsCount||2;g=a.stream.audioSamplingRate||44100;k=Oc("audio",a.codecs.split(","));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};h=l[g];if("mp4a.40.5"===k||"mp4a.40.29"===k)h=l[2*g];g=parseInt(k.split(".").pop(),10);d=new Uint8Array([0,0,0,0,3,25].concat(x(lx(d,2)),[0,4,17,64,21,0,0,0,0,0,0,0,0,0,0,0,5,2,g<<3|h>>>1,h<<7|e<<3,6,1,2]));c=c("esds",d)}d="mp4a";e=new Uint8Array([]);a.encrypted&&(e=tx(a),d="enca");
1099
+ a=gx(d,ux(a),c,e)}c=a}a=gx("stsd",vx,c);return b("stbl",a,gx("stts",wx),gx("stsc",xx),gx("stsz",yx),gx("stco",zx))}function sx(a){if(!a.Sa&&!a.Ua)return new Uint8Array([]);var b=a.Ua;a=new Uint8Array([].concat(x(lx(a.Sa,4)),x(lx(b,4))));return gx("pasp",a)}function ux(a){return new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,a.stream.channelsCount||2,0,16,0,0,0,0].concat(x(lx(a.stream.audioSamplingRate||44100,2)),[0,0]))}
1100
+ function tx(a){var b=gx;var c=a.codecs.substring(0,a.codecs.indexOf("."));for(var d=0,e=0;e<c.length;e+=1)d|=c.charCodeAt(e)<<8*(c.length-e-1);c=new Uint8Array([].concat(x(lx(d,4))));c=gx("frma",c);d=new Uint8Array([0,0,0,0,99,101,110,99,0,1,0,0]);d=gx("schm",d);e=gx;var f=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0]);a=t(a.stream.drmInfos);for(var g=a.next();!g.done;g=a.next())if((g=g.value)&&g.keyIds&&g.keyIds.size){g=t(g.keyIds);for(var h=g.next();!h.done;h=g.next())f=rx(h.value)}a=new Uint8Array([0,
1101
+ 0,0,0,0,0,1,8]);f=gx("tenc",a,f);return b("sinf",c,d,e("schi",f))}
1102
+ function Ax(a){var b=[];a=t(a.g);for(var c=a.next();!c.done;c=a.next()){c=c.value;var d=b.push,e=d.apply;var f=gx;var g=new Uint8Array([0,0,0,0].concat(x(lx(c.data?c.data.Ib:0,4))));g=gx("mfhd",g);var h;var k=c.data?c.data.rb:[];var l=new Uint8Array(4+k.length);for(h=0;h<k.length;h++){var m=k[h].flags;l[h+4]=m.ib<<4|m.mb<<2|m.kb}k=gx("sdtp",l);var n=k.length+92;l=gx;h=new Uint8Array([0,0,0,58].concat(x(lx(c.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0]));h=gx("tfhd",h);m=c.data?c.data.baseMediaDecodeTime:
1103
+ 0;var p=Math.floor(m%(kx+1));m=new Uint8Array([1,0,0,0].concat(x(lx(Math.floor(m/(kx+1)),4)),x(lx(p,4))));m=gx("tfdt",m);var r=n;n=c.data?c.data.rb:[];p=n.length;var u=12+16*p,v=new Uint8Array(u);r+=8+u;v.set(["video"===c.type?1:0,0,15,1].concat(x(lx(p,4)),x(lx(r,4))),0);for(r=0;r<p;r++){var w=n[r];u=lx(w.duration,4);var A=lx(w.size,4),z=w.flags;w=lx(w.wb,4);v.set([].concat(x(u),x(A),[z.xb<<2|z.ib,z.mb<<6|z.kb<<4|z.yb,z.hb&61440,z.hb&15],x(w)),12+16*r)}n=gx("trun",v);k=l("traf",h,m,n,k);f=f("moof",
1104
+ g,k);e.call(d,b,[f,Bx(c)])}return Kc.apply(Ec,x(b))}function Bx(a){a=(a.data?a.data.rb:[]).map(function(b){return b.data});a=Kc.apply(Ec,x(a));return gx("mdat",a)}function lx(a,b){var c=[];for(--b;0<=b;b--)c.push(a>>8*b&255);return c}function rx(a){for(var b=new Uint8Array(a.length/2),c=0;c<a.length/2;c+=1)b[c]=parseInt(String(a[2*c]+a[2*c+1]),16);return b}
1105
+ function gx(a){var b=Ka.apply(1,arguments),c=Cx[a];c||(c=[a.charCodeAt(0),a.charCodeAt(1),a.charCodeAt(2),a.charCodeAt(3)],Cx[a]=c);for(var d=8,e=b.length-1;0<=e;e--)d+=b[e].byteLength;e=new Uint8Array(d);e[0]=d>>24&255;e[1]=d>>16&255;e[2]=d>>8&255;e[3]=d&255;e.set(c,4);c=0;for(d=8;c<b.length;c++)e.set(b[c],d),d+=b[c].byteLength;return e}
1106
+ var ex=!1,kx=Math.pow(2,32)-1,Cx={},mx=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]),nx=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]),wx=new Uint8Array([0,0,0,0,0,0,0,0]),xx=new Uint8Array([0,0,0,0,0,0,0,0]),zx=new Uint8Array([0,0,0,0,0,0,0,0]),yx=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),ox=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0]),qx=new Uint8Array([0,
1107
+ 0,0,0,0,0,0,0]),vx=new Uint8Array([0,0,0,0,0,0,0,1]),fx=new Uint8Array([]),hx=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),ix=new Uint8Array([]);function Dx(){var a=this;this.h=this.g=null;this.l=[];this.j=null;this.u=1;this.i=null;this.F=new ld(5);this.o=new Ub(function(){Ex(a)});this.A=new tg;this.m=new Map}q=Dx.prototype;q.configure=function(a){this.g=a};q.start=function(a,b){var c=this;return O(function(d){if(1==d.g)return c.l=[a],c.h=b,E(d,Fx(c),2);if(!c.h)throw new U(2,7,7001);return d.return(c.j)})};
1108
+ function Ex(a){var b;O(function(c){switch(c.g){case 1:return ta(c,2),E(c,Fx(a),4);case 4:va(c,3);break;case 2:b=wa(c),a.h&&(b.severity=1,a.h.onError(b));case 3:if(!a.h)return c.return();F(c)}})}q.stop=function(){this.g=this.h=null;this.l=[];this.j=null;null!=this.o&&(this.o.stop(),this.o=null);this.m.clear();return this.A.destroy()};
1109
+ q.update=function(){var a=this,b;return O(function(c){if(1==c.g)return ta(c,2),E(c,Fx(a),4);if(2!=c.g)return va(c,0);b=wa(c);if(!a.h||!b)return c.return();a.h.onError(b);F(c)})};q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(){};q.banLocation=function(){};
1110
+ function Fx(a){var b,c,d,e,f,g,h;return O(function(k){if(1==k.g)return b=Ag(a.l,a.g.retryParameters),c=a.h.networkingEngine,d=Date.now(),e=c.request(0,b,{type:5}),ug(a.A,e),E(k,e.promise,2);f=k.h;if(!a.h)return k.return();f.uri&&!a.l.includes(f.uri)&&a.l.unshift(f.uri);var l=f.uri,m=f.data,n=a.g.mss.manifestPreprocessor;if(n!=wm){xd("manifest.mss.manifestPreprocessor configuration","Please Use manifest.mss.manifestPreprocessorTXml instead.");m=zu(m,"SmoothStreamingMedia");if(!m)throw new U(2,4,4046,
1111
+ l);n(m);m=Ac(m.outerHTML)}var p=bh(m,"SmoothStreamingMedia");if(!p)throw new U(2,4,4046,l);l=a.g.mss.manifestPreprocessorTXml;l!=xm&&l(p);a.i||(a.i=new Bk(null,0));if(l=th(p,"IsLive",Dh,!1))throw new U(2,4,4047);a.i.Mc(!l);n=th(p,"TimeScale",Bh,1E7);m=th(p,"DVRWindowLength",Bh);l&&(0===m||isNaN(m))&&(m=Infinity);var r=th(p,"CanSeek",Dh,!1);0===m&&r&&(m=Infinity);r=null;m&&0<m&&(r=m/n);l&&!isNaN(a.g.availabilityWindowOverride)&&(r=a.g.availabilityWindowOverride);null==r&&(r=Infinity);a.i.nf(r);m=th(p,
1112
+ "Duration",Bh,Infinity);l||a.i.sb(m/n);l={variants:[],textStreams:[],timescale:n,duration:m/n};r=kh(p,"Protection");var u;n=a.g.mss.keySystemsBySystemId;m=[];r=t(r);for(u=r.next();!u.done;u=r.next())m=m.concat(kh(u.value,"ProtectionHeader"));if(m.length){r=[];for(u=0;u<m.length;u++){var v=m[u],w=v.attributes.SystemID.toLowerCase(),A=n[w];if(A){var z=Pw(v);if(z)a:{z=t(nh(z,"DATA"));for(var C=z.next();!C.done;C=z.next())if(C=oh(C.value,"KID")){z=Hc(lh(C));z=new Uint8Array([z[3],z[2],z[1],z[0],z[5],
1113
+ z[4],z[7],z[6]].concat(x(z.slice(8))));z=Jc(z);break a}z=null}else z=null;C=Hc(lh(v));w=Ic(w.replace(/-/g,""));w=[{initData:ah(C,w,new Set,0),initDataType:"cenc",keyId:z}];w=Mc(A,"cenc",w);z&&w.keyIds.add(z);if(A=Rw.get(A))w.licenseServerUri=A(v);r.push(w)}}n=r}else n=[];u=n;r=[];n=[];m=[];p=kh(p,"StreamIndex");p=t(p);for(v=p.next();!v.done;v=p.next()){v=v.value;A=kh(v,"QualityLevel");w=l.timescale;z=l.duration;C=kh(v,"c");for(var y=[],B=0,D=0;D<C.length;++D){var K=C[D],G=C[D+1],J=th(K,"t",Bh),I=
1114
+ th(K,"d",Bh);K=th(K,"r",zh);if(!I)break;J=null!=J?J:B;K=K||0;if(0>K)if(G){G=th(G,"t",Bh);if(null==G)break;else if(J>=G)break;K=Math.ceil((G-J)/I)-1}else{if(Infinity==z)break;else if(J/w>=z)break;K=Math.ceil((z*w-J)/I)-1}for(G=0;G<=K;++G)B=J+I,y.push({start:J/w,end:B/w,kh:J}),J=B}w=y;A=t(A);for(z=A.next();!z.done;z=A.next())(z=Gx(a,v,z.value,w,u,l))&&("audio"!=z.type||a.g.disableAudio?"video"!=z.type||a.g.disableVideo?z.type!=Sc||a.g.disableText||m.push(z):n.push(z):r.push(z))}p=[];r=t(0<r.length?
1114
1115
  r:[null]);for(u=r.next();!u.done;u=r.next())for(u=u.value,v=t(0<n.length?n:[null]),z=v.next();!z.done;z=v.next())A=p,w=A.push,z=z.value,C=0,u&&u.bandwidth&&0<u.bandwidth&&(C+=u.bandwidth),z&&z.bandwidth&&0<z.bandwidth&&(C+=z.bandwidth),z={id:a.u++,language:u?u.language:"und",disabledUntilTime:0,primary:!!u&&u.primary||!!z&&z.primary,audio:u,video:z,bandwidth:C,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},w.call(A,z);l.variants=p;l.textStreams=m;a.j?(a.j.variants=l.variants,a.j.textStreams=
1115
1116
  l.textStreams,a.h.filter(a.j)):(a.j={presentationTimeline:a.i,variants:l.variants,textStreams:l.textStreams,imageStreams:[],offlineSessionIds:[],minBufferTime:0,sequenceMode:a.g.mss.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,type:"MSS",serviceDescription:null,nextUrl:null},a.i.Ue());Promise.resolve();g=Date.now();h=(g-d)/1E3;a.F.sample(1,h);F(k)})}
1116
- function Fx(a,b,c,d,e,f){var g=b.attributes.Type;if("audio"!==g&&"video"!==g&&"text"!==g)return Ya("Ignoring unrecognized type:",g),null;var h=b.attributes.Language,k=a.u++,l=th(c,"Bitrate",Ah),m=th(c,"MaxWidth",Ah),n=th(c,"MaxHeight",Ah),p=th(c,"Channels",Ah),r=th(c,"SamplingRate",Ah),u=f.duration;d.length&&(u=d[d.length-1].end-d[0].start);var v=a.i.getDuration();a.i.sb(Math.min(u,v));var w={id:k,originalId:b.attributes.Name||String(k),groupId:null,createSegmentIndex:function(){return Promise.resolve()},
1117
+ function Gx(a,b,c,d,e,f){var g=b.attributes.Type;if("audio"!==g&&"video"!==g&&"text"!==g)return Ya("Ignoring unrecognized type:",g),null;var h=b.attributes.Language,k=a.u++,l=th(c,"Bitrate",Ah),m=th(c,"MaxWidth",Ah),n=th(c,"MaxHeight",Ah),p=th(c,"Channels",Ah),r=th(c,"SamplingRate",Ah),u=f.duration;d.length&&(u=d[d.length-1].end-d[0].start);var v=a.i.getDuration();a.i.sb(Math.min(u,v));var w={id:k,originalId:b.attributes.Name||String(k),groupId:null,createSegmentIndex:function(){return Promise.resolve()},
1117
1118
  closeSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:"",codecs:"",frameRate:void 0,pixelAspectRatio:void 0,bandwidth:l||0,width:m||void 0,height:n||void 0,kind:"",encrypted:0<e.length,drmInfos:e,keyIds:new Set,language:Xc(h||"und"),originalLanguage:h,label:"",type:"",primary:!1,trickModeVideo:null,emsgSchemeIdUris:[],roles:[],forced:!1,channelsCount:p,audioSamplingRate:r,spatialAudio:!1,closedCaptions:null,hdr:void 0,colorGamut:void 0,videoLayout:void 0,tilesLayout:void 0,
1118
- matchedStreams:[],mssPrivateData:{duration:u,timescale:f.timescale,codecPrivateData:null},accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set};if(e=b.attributes.Subtype)(e=Gx[e])&&w.roles.push(e),"main"===e&&(w.primary=!0);e=c.attributes.FourCC;if(null===e||""===e)e=b.attributes.FourCC;if(!e)if("audio"===g)e="AAC";else if("video"===g)return Ya('FourCC is not defined whereas it is required for a QualityLevel element for a StreamIndex of type "video"'),null;if(!Hx.includes(e.toUpperCase()))return Ya("Codec not supported:",
1119
- e),null;c=Ix(c,g,e,w);w.mssPrivateData.codecPrivateData=c;switch(g){case "audio":if(!c)return Ya("Quality unsupported without CodecPrivateData",g),null;w.type="audio";w.mimeType="mss/audio/mp4";w.codecs=Jx(e,c);break;case "video":if(!c)return Ya("Quality unsupported without CodecPrivateData",g),null;w.type="video";w.mimeType="mss/video/mp4";w.codecs=Kx(c);break;case "text":if(w.type=Sc,w.mimeType="application/mp4","TTML"===e||"DFXP"===e)w.codecs="stpp"}w.fullMimeTypes.add(te(w.mimeType,w.codecs));
1120
- w.createSegmentIndex=function(){if(w.segmentIndex)return Promise.resolve();if(a.m.has(w.id))var A=a.m.get(w.id);else A=[],"video"==w.type&&(A=w.mssPrivateData.codecPrivateData.split("00000001").slice(1)),A={id:w.id,type:w.type,codecs:w.codecs,encrypted:w.encrypted,timescale:w.mssPrivateData.timescale,duration:w.mssPrivateData.duration,ub:A,ya:new Uint8Array([]),Ma:new Uint8Array([]),Sa:0,Ua:0,data:null,stream:w},A=ix(new Rw([A])),a.m.set(w.id,A);A=Lx(a,new Gi(function(){return[]},0,null,null,void 0,
1119
+ matchedStreams:[],mssPrivateData:{duration:u,timescale:f.timescale,codecPrivateData:null},accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set};if(e=b.attributes.Subtype)(e=Hx[e])&&w.roles.push(e),"main"===e&&(w.primary=!0);e=c.attributes.FourCC;if(null===e||""===e)e=b.attributes.FourCC;if(!e)if("audio"===g)e="AAC";else if("video"===g)return Ya('FourCC is not defined whereas it is required for a QualityLevel element for a StreamIndex of type "video"'),null;if(!Ix.includes(e.toUpperCase()))return Ya("Codec not supported:",
1120
+ e),null;c=Jx(c,g,e,w);w.mssPrivateData.codecPrivateData=c;switch(g){case "audio":if(!c)return Ya("Quality unsupported without CodecPrivateData",g),null;w.type="audio";w.mimeType="mss/audio/mp4";w.codecs=Kx(e,c);break;case "video":if(!c)return Ya("Quality unsupported without CodecPrivateData",g),null;w.type="video";w.mimeType="mss/video/mp4";w.codecs=Lx(c);break;case "text":if(w.type=Sc,w.mimeType="application/mp4","TTML"===e||"DFXP"===e)w.codecs="stpp"}w.fullMimeTypes.add(te(w.mimeType,w.codecs));
1121
+ w.createSegmentIndex=function(){if(w.segmentIndex)return Promise.resolve();if(a.m.has(w.id))var A=a.m.get(w.id);else A=[],"video"==w.type&&(A=w.mssPrivateData.codecPrivateData.split("00000001").slice(1)),A={id:w.id,type:w.type,codecs:w.codecs,encrypted:w.encrypted,timescale:w.mssPrivateData.timescale,duration:w.mssPrivateData.duration,ub:A,ya:new Uint8Array([]),Ma:new Uint8Array([]),Sa:0,Ua:0,data:null,stream:w},A=jx(new Sw([A])),a.m.set(w.id,A);A=Mx(a,new Gi(function(){return[]},0,null,null,void 0,
1121
1122
  A),w,b,d);w.segmentIndex=new Xk(A);return Promise.resolve()};w.closeSegmentIndex=function(){w.segmentIndex&&(w.segmentIndex.release(),w.segmentIndex=null)};return w}
1122
- function Ix(a,b,c,d){if(a=a.attributes.CodecPrivateData)return a;if("audio"!==b)return null;b=d.channelsCount||2;a=d.audioSamplingRate||44100;var e={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};d=e[a];if("AACH"===c)return c=new Uint8Array(4),a=e[2*a],c[0]=40|d>>1,c[1]=d<<7|b<<3|a>>1,c[2]=a<<7|8,c[3]=0,b=new Uint16Array(2),b[0]=(c[0]<<8)+c[1],b[1]=(c[2]<<8)+c[3],b[0].toString(16)+b[1].toString(16);c=new Uint8Array(2);c[0]=16|d>>1;c[1]=d<<7|b<<3;
1123
- b=new Uint16Array(1);b[0]=(c[0]<<8)+c[1];return b[0].toString(16)}function Jx(a,b){var c=0;"AACH"===a&&(c=5);b?0===c&&(c=(parseInt(b.substr(0,2),16)&248)>>3):(c=2,"AACH"===a&&(c=5));return"mp4a.40."+c}function Kx(a){var b=/00000001[0-9]7/.exec(a);return b.length&&a?"avc1."+a.substr(a.indexOf(b[0])+10,6):""}
1124
- function Lx(a,b,c,d,e){var f=d.attributes.Url.replace("{bitrate}",String(c.bandwidth));d=[];var g={};e=t(e);for(var h=e.next();!h.done;g={Dd:g.Dd},h=e.next())g.Dd=h.value,d.push(new Ii(g.Dd.start,g.Dd.end,function(k){return function(){return Lc(a.l,[f.replace("{start time}",String(k.Dd.kh))])}}(g),0,null,b,0,0,c.mssPrivateData.duration));return d}P("shaka.mss.MssParser",Cx);var Hx="AAC AACL AACH AACP AVC1 H264 TTML DFXP".split(" "),Gx={CAPT:"main",SUBT:"alternate",DESC:"main"};
1125
- Bi["application/vnd.ms-sstr+xml"]=function(){return new Cx};function Mx(a,b,c,d,e,f){if(200<=c&&299>=c&&202!=c)return{uri:e||d,originalUri:d,data:b,status:c,headers:a,fromCache:!!a["x-shaka-from-cache"]};var g=null;try{g=zc(b)}catch(h){}throw new U(401==c||403==c?2:1,1,1001,d,c,g,a,f,e||d);};function Nx(){}function Ox(a,b,c,d,e){var f=new Px;Kg(b.headers).forEach(function(l,m){f.append(m,l)});var g=new Qx,h={uh:!1,ri:!1};a=Rx(a,c,{body:b.body||void 0,headers:f,method:b.method,signal:g.signal,credentials:b.allowCrossSiteCredentials?"include":void 0},h,d,e,b.streamDataCallback);a=new mg(a,function(){h.uh=!0;g.abort();return Promise.resolve()});if(b=b.retryParameters.timeout){var k=new Ub(function(){h.ri=!0;g.abort()});k.V(b/1E3);a.finally(function(){k.stop()})}return a}
1126
- function Rx(a,b,c,d,e,f,g){var h,k,l,m,n,p,r,u,v,w,A,z,C;return O(function(y){switch(y.g){case 1:return h=Sx,k=Tx,p=n=0,r=Date.now(),ta(y,2),E(y,h(a,c),4);case 4:l=y.h;f(Ux(l.headers));if("HEAD"==c.method){y.B(5);break}u=l.clone().body.getReader();w=(v=l.headers.get("Content-Length"))?parseInt(v,10):0;A=function(B){function D(){var K,G,J;return O(function(I){switch(I.g){case 1:return ta(I,2),E(I,u.read(),4);case 4:K=I.h;va(I,3);break;case 2:return wa(I),I.return();case 3:if(K.done){I.B(5);break}n+=
1127
- K.value.byteLength;if(!g){I.B(5);break}return E(I,g(K.value),5);case 5:G=Date.now();if(100<G-r||K.done)J=K.done?0:w-n,e(G-r,n-p,J),p=n,r=G;K.done?B.close():(B.enqueue(K.value),D());F(I)}})}D()};new k({start:A});return E(y,l.arrayBuffer(),6);case 6:m=y.h;case 5:va(y,3);break;case 2:z=wa(y);if(d.uh)throw new U(1,1,7001,a,b);if(d.ri)throw new U(1,1,1003,a,b);throw new U(1,1,1002,a,z,b);case 3:return C=Ux(l.headers),y.return(Mx(C,m,l.status,a,l.url,b))}})}
1128
- function Ux(a){var b={};a.forEach(function(c,d){b[d.trim()]=c});return b}function Vx(){if(window.ReadableStream)try{new ReadableStream({})}catch(a){return!1}else return!1;if(window.Response){if(!(new Response("")).body)return!1}else return!1;return!(!window.fetch||"polyfill"in window.fetch||!window.AbortController)}P("shaka.net.HttpFetchPlugin",Nx);Nx.isSupported=Vx;Nx.parse=Ox;var Sx=window.fetch,Qx=window.AbortController,Tx=window.ReadableStream,Px=window.Headers;
1129
- Vx()&&(wg("http",Ox,2,!0),wg("https",Ox,2,!0),wg("blob",Ox,2,!0));function Wx(){}
1130
- function Xx(a,b,c,d,e){var f=new Yx,g=Date.now(),h=0,k=new Promise(function(l,m){f.open(b.method,a,!0);f.responseType="arraybuffer";f.timeout=b.retryParameters.timeout;f.withCredentials=b.allowCrossSiteCredentials;f.onabort=function(){m(new U(1,1,7001,a,c))};var n=!1;f.onreadystatechange=function(){if(2==f.readyState&&!n){var r=Zx(f);e(r);n=!0}};f.onload=function(r){var u=Zx(f),v=f.response;try{d(Date.now()-g,r.loaded-h,0);var w=Mx(u,v,f.status,a,f.responseURL,c);l(w)}catch(A){m(A)}};f.onerror=function(r){m(new U(1,
1123
+ function Jx(a,b,c,d){if(a=a.attributes.CodecPrivateData)return a;if("audio"!==b)return null;b=d.channelsCount||2;a=d.audioSamplingRate||44100;var e={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};d=e[a];if("AACH"===c)return c=new Uint8Array(4),a=e[2*a],c[0]=40|d>>1,c[1]=d<<7|b<<3|a>>1,c[2]=a<<7|8,c[3]=0,b=new Uint16Array(2),b[0]=(c[0]<<8)+c[1],b[1]=(c[2]<<8)+c[3],b[0].toString(16)+b[1].toString(16);c=new Uint8Array(2);c[0]=16|d>>1;c[1]=d<<7|b<<3;
1124
+ b=new Uint16Array(1);b[0]=(c[0]<<8)+c[1];return b[0].toString(16)}function Kx(a,b){var c=0;"AACH"===a&&(c=5);b?0===c&&(c=(parseInt(b.substr(0,2),16)&248)>>3):(c=2,"AACH"===a&&(c=5));return"mp4a.40."+c}function Lx(a){var b=/00000001[0-9]7/.exec(a);return b.length&&a?"avc1."+a.substr(a.indexOf(b[0])+10,6):""}
1125
+ function Mx(a,b,c,d,e){var f=d.attributes.Url.replace("{bitrate}",String(c.bandwidth));d=[];var g={};e=t(e);for(var h=e.next();!h.done;g={Dd:g.Dd},h=e.next())g.Dd=h.value,d.push(new Ii(g.Dd.start,g.Dd.end,function(k){return function(){return Lc(a.l,[f.replace("{start time}",String(k.Dd.kh))])}}(g),0,null,b,0,0,c.mssPrivateData.duration));return d}P("shaka.mss.MssParser",Dx);var Ix="AAC AACL AACH AACP AVC1 H264 TTML DFXP".split(" "),Hx={CAPT:"main",SUBT:"alternate",DESC:"main"};
1126
+ Bi["application/vnd.ms-sstr+xml"]=function(){return new Dx};function Nx(a,b,c,d,e,f){if(200<=c&&299>=c&&202!=c)return{uri:e||d,originalUri:d,data:b,status:c,headers:a,fromCache:!!a["x-shaka-from-cache"]};var g=null;try{g=zc(b)}catch(h){}throw new U(401==c||403==c?2:1,1,1001,d,c,g,a,f,e||d);};function Ox(){}function Px(a,b,c,d,e){var f=new Qx;Kg(b.headers).forEach(function(l,m){f.append(m,l)});var g=new Rx,h={uh:!1,ri:!1};a=Sx(a,c,{body:b.body||void 0,headers:f,method:b.method,signal:g.signal,credentials:b.allowCrossSiteCredentials?"include":void 0},h,d,e,b.streamDataCallback);a=new mg(a,function(){h.uh=!0;g.abort();return Promise.resolve()});if(b=b.retryParameters.timeout){var k=new Ub(function(){h.ri=!0;g.abort()});k.V(b/1E3);a.finally(function(){k.stop()})}return a}
1127
+ function Sx(a,b,c,d,e,f,g){var h,k,l,m,n,p,r,u,v,w,A,z,C;return O(function(y){switch(y.g){case 1:return h=Tx,k=Ux,p=n=0,r=Date.now(),ta(y,2),E(y,h(a,c),4);case 4:l=y.h;f(Vx(l.headers));if("HEAD"==c.method){y.B(5);break}u=l.clone().body.getReader();w=(v=l.headers.get("Content-Length"))?parseInt(v,10):0;A=function(B){function D(){var K,G,J;return O(function(I){switch(I.g){case 1:return ta(I,2),E(I,u.read(),4);case 4:K=I.h;va(I,3);break;case 2:return wa(I),I.return();case 3:if(K.done){I.B(5);break}n+=
1128
+ K.value.byteLength;if(!g){I.B(5);break}return E(I,g(K.value),5);case 5:G=Date.now();if(100<G-r||K.done)J=K.done?0:w-n,e(G-r,n-p,J),p=n,r=G;K.done?B.close():(B.enqueue(K.value),D());F(I)}})}D()};new k({start:A});return E(y,l.arrayBuffer(),6);case 6:m=y.h;case 5:va(y,3);break;case 2:z=wa(y);if(d.uh)throw new U(1,1,7001,a,b);if(d.ri)throw new U(1,1,1003,a,b);throw new U(1,1,1002,a,z,b);case 3:return C=Vx(l.headers),y.return(Nx(C,m,l.status,a,l.url,b))}})}
1129
+ function Vx(a){var b={};a.forEach(function(c,d){b[d.trim()]=c});return b}function Wx(){if(window.ReadableStream)try{new ReadableStream({})}catch(a){return!1}else return!1;if(window.Response){if(!(new Response("")).body)return!1}else return!1;return!(!window.fetch||"polyfill"in window.fetch||!window.AbortController)}P("shaka.net.HttpFetchPlugin",Ox);Ox.isSupported=Wx;Ox.parse=Px;var Tx=window.fetch,Rx=window.AbortController,Ux=window.ReadableStream,Qx=window.Headers;
1130
+ Wx()&&(wg("http",Px,2,!0),wg("https",Px,2,!0),wg("blob",Px,2,!0));function Xx(){}
1131
+ function Yx(a,b,c,d,e){var f=new Zx,g=Date.now(),h=0,k=new Promise(function(l,m){f.open(b.method,a,!0);f.responseType="arraybuffer";f.timeout=b.retryParameters.timeout;f.withCredentials=b.allowCrossSiteCredentials;f.onabort=function(){m(new U(1,1,7001,a,c))};var n=!1;f.onreadystatechange=function(){if(2==f.readyState&&!n){var r=$x(f);e(r);n=!0}};f.onload=function(r){var u=$x(f),v=f.response;try{d(Date.now()-g,r.loaded-h,0);var w=Nx(u,v,f.status,a,f.responseURL,c);l(w)}catch(A){m(A)}};f.onerror=function(r){m(new U(1,
1131
1132
  1,1002,a,r,c))};f.ontimeout=function(){m(new U(1,1,1003,a,c))};f.onprogress=function(r){var u=Date.now();if(100<u-g||r.lengthComputable&&r.loaded==r.total)d(u-g,r.loaded-h,4==f.readyState?0:r.total-r.loaded),h=r.loaded,g=u};for(var p in b.headers)f.setRequestHeader(p.toLowerCase(),b.headers[p]);f.send(b.body)});return new mg(k,function(){f.abort();return Promise.resolve()})}
1132
- function Zx(a){var b=a.getAllResponseHeaders().trim().split("\r\n");a={};b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value.split(": "),a[c[0].toLowerCase()]=c.slice(1).join(": ");return a}P("shaka.net.HttpXHRPlugin",Wx);Wx.parse=Xx;var Yx=window.XMLHttpRequest;wg("http",Xx,1,!0);wg("https",Xx,1,!0);wg("blob",Xx,1,!0);function $x(a,b,c,d){this.g=a;this.i=b;this.groupId=c;this.h=d}function ay(a){return a.P().map(function(b){return"{"+encodeURI(b)+"}"}).join("")+":"+a.Wa+":"+a.Da}function by(a,b){return Bl(a.g.P(),a.g.Wa,a.g.Da,b.streaming.retryParameters)};function cy(){this.h=this.j=this.i=0;this.g=new Map;this.l=0}function dy(a,b){a.i+=b;var c=a.l;a.l++;a.g.set(c,b);return c}cy.prototype.close=function(a,b){if(this.g.has(a)){var c=this.g.get(a);this.g.delete(a);this.j+=c;this.h+=b}};function ey(a){var b=this;this.o=a;this.j=new Map;this.i=new Ig(function(){return fy(b).catch(function(){})});this.h=[];this.m=function(){};this.l=function(){};this.g=new cy}ey.prototype.destroy=function(){return this.i.destroy()};function gy(a,b,c){a.m=b;a.l=c}function fy(a){var b=a.h.map(function(c){return c()});a.h=[];return Promise.all(b)}
1133
- function hy(a,b,c,d,e,f){Jg(a.i);var g=(a.j.get(b)||Promise.resolve()).then(function(){var h,k,l,m,n,p,r;return O(function(u){if(1==u.g)return E(u,iy(a,c),2);h=u.h;if(a.i.g)throw new U(2,9,7001);if(e)for(m in k=Gb(h),l=new $g(k),l.data)n=Number(m),p=l.data[n],r=l.g[n],a.l(p,r);a.g.close(d,h.byteLength);var v=a.g;a.m(0==v.i?0:v.j/v.i,a.g.h);return u.return(f(h))})});a.j.set(b,g)}function jy(a){return O(function(b){return 1==b.g?E(b,Promise.all(a.j.values()),2):b.return(a.g.h)})}
1134
- function iy(a,b){var c,d,e,f;return O(function(g){if(1==g.g)return c=Gg,d=a.o.request(c,b),e=function(){return d.abort()},a.h.push(e),E(g,d.promise,2);f=g.h;Od(a.h,e);return g.return(f.data)})};function ky(a,b){var c=this;this.i=a;this.h=a.objectStore(b);this.g=new lg;a.onabort=function(d){d.preventDefault();c.g.reject()};a.onerror=function(d){d.preventDefault();c.g.reject()};a.oncomplete=function(){c.g.resolve()}}ky.prototype.abort=function(){var a=this;return O(function(b){if(1==b.g){try{a.i.abort()}catch(c){}ta(b,2);return E(b,a.g,4)}if(2!=b.g)return va(b,0);wa(b);F(b)})};
1135
- function ly(a,b){return new Promise(function(c,d){var e=a.h.openCursor();e.onerror=d;e.onsuccess=function(){var f;return O(function(g){if(1==g.g){if(null==e.result)return c(),g.return();f=e.result;return E(g,b(f.key,f.value,f),2)}f.continue();F(g)})}})}ky.prototype.store=function(){return this.h};ky.prototype.promise=function(){return this.g};function my(a){this.h=a;this.g=[]}my.prototype.destroy=function(){return Promise.all(this.g.map(function(a){return a.abort()}))};function ny(a,b){return oy(a,b,"readwrite")}function oy(a,b,c){c=a.h.transaction([b],c);var d=new ky(c,b);a.g.push(d);d.promise().then(function(){Od(a.g,d)},function(){Od(a.g,d)});return d};function py(a,b,c){this.h=new my(a);this.i=b;this.g=c}q=py.prototype;q.destroy=function(){return this.h.destroy()};q.hasFixedKeySpace=function(){return!0};q.addSegments=function(){return qy(this.i)};q.removeSegments=function(a,b){return ry(this,this.i,a,b)};q.getSegments=function(a){var b=this,c;return O(function(d){if(1==d.g)return E(d,sy(b,b.i,a),2);c=d.h;return d.return(c.map(function(e){return b.xh(e)}))})};q.addManifests=function(){return qy(this.g)};
1136
- q.updateManifest=function(){return Promise.reject(new U(2,9,9016,"Cannot modify values in "+this.g))};function ty(a,b,c){a=ny(a.h,a.g);var d=a.store();d.get(b).onsuccess=function(){d.put(c,b)};return a.promise()}q.updateManifestExpiration=function(a,b){var c=ny(this.h,this.g),d=c.store();d.get(a).onsuccess=function(e){if(e=e.target.result)e.expiration=b,d.put(e,a)};return c.promise()};q.removeManifests=function(a,b){return ry(this,this.g,a,b)};
1137
- q.getManifests=function(a){var b=this,c;return O(function(d){if(1==d.g)return E(d,sy(b,b.g,a),2);c=d.h;return d.return(Promise.all(c.map(function(e){return b.Ld(e)})))})};q.getAllManifests=function(){var a=this,b,c;return O(function(d){return 1==d.g?(b=oy(a.h,a.g,"readonly"),c=new Map,E(d,ly(b,function(e,f){var g;return O(function(h){if(1==h.g)return E(h,a.Ld(f),2);g=h.h;c.set(e,g);F(h)})}),2)):3!=d.g?E(d,b.promise(),3):d.return(c)})};q.xh=function(a){return a};q.Ld=function(a){return Promise.resolve(a)};
1138
- function qy(a){return Promise.reject(new U(2,9,9011,"Cannot add new value to "+a))}q.add=function(a,b){var c=this,d,e,f,g,h,k,l;return O(function(m){if(1==m.g){d=ny(c.h,a);e=d.store();f=[];g={};h=t(b);for(k=h.next();!k.done;g={xe:g.xe},k=h.next())l=k.value,g.xe=e.add(l),g.xe.onsuccess=function(n){return function(){f.push(n.xe.result)}}(g);return E(m,d.promise(),2)}return m.return(f)})};
1139
- function ry(a,b,c,d){a=ny(a.h,b);b=a.store();var e={};c=t(c);for(var f=c.next();!f.done;e={ve:e.ve},f=c.next())e.ve=f.value,b.delete(e.ve).onsuccess=function(g){return function(){return d(g.ve)}}(e);return a.promise()}
1140
- function sy(a,b,c){var d,e,f,g,h,k,l;return O(function(m){if(1==m.g){d=oy(a.h,b,"readonly");e=d.store();f={};g=[];h={};k=t(c);for(l=k.next();!l.done;h={Bd:h.Bd,xd:h.xd},l=k.next())h.xd=l.value,h.Bd=e.get(h.xd),h.Bd.onsuccess=function(n){return function(){void 0==n.Bd.result&&g.push(n.xd);f[n.xd]=n.Bd.result}}(h);return E(m,d.promise(),2)}if(g.length)throw new U(2,9,9012,"Could not find values for "+g);return m.return(c.map(function(n){return f[n]}))})};function uy(a){this.g=new my(a)}uy.prototype.destroy=function(){return this.g.destroy()};uy.prototype.getAll=function(){var a=this,b,c;return O(function(d){return 1==d.g?(b=oy(a.g,"session-ids","readonly"),c=[],E(d,ly(b,function(e,f){c.push(f)}),2)):3!=d.g?E(d,b.promise(),3):d.return(c)})};uy.prototype.add=function(a){var b=ny(this.g,"session-ids"),c=b.store();a=t(a);for(var d=a.next();!d.done;d=a.next())c.add(d.value);return b.promise()};
1141
- uy.prototype.remove=function(a){var b=this,c;return O(function(d){return 1==d.g?(c=ny(b.g,"session-ids"),E(d,ly(c,function(e,f,g){a.includes(f.sessionId)&&g.delete()}),2)):E(d,c.promise(),0)})};function vy(){this.g=new Map}vy.prototype.destroy=function(){for(var a=[],b=t(this.g.values()),c=b.next();!c.done;c=b.next())a.push(c.value.destroy());this.g.clear();return Promise.all(a)};vy.prototype.init=function(){var a=this;wy.forEach(function(e,f){(e=e())&&a.g.set(f,e)});for(var b=[],c=t(this.g.values()),d=c.next();!d.done;d=c.next())b.push(d.value.init());return Promise.all(b)};
1142
- function xy(a){var b=null;a.g.forEach(function(c,d){c.getCells().forEach(function(e,f){e.hasFixedKeySpace()||b||(b={path:{Eb:d,$a:f},$a:e})})});if(b)return b;throw new U(2,9,9013,"Could not find a cell that supports add-operations");}function yy(a,b){a.g.forEach(function(c,d){c.getCells().forEach(function(e,f){b({Eb:d,$a:f},e)})})}
1143
- function zy(a,b,c){a=a.g.get(b);if(!a)throw new U(2,9,9013,"Could not find mechanism with name "+b);b=a.getCells().get(c);if(!b)throw new U(2,9,9013,"Could not find cell with name "+c);return b}function Ay(a,b){a.g.forEach(function(c){b(c.getEmeSessionCell())})}function By(a){var b=Array.from(a.g.keys());if(!b.length)throw new U(2,9,9E3,"No supported storage mechanisms found");return a.g.get(b[0]).getEmeSessionCell()}
1144
- function Cy(a){var b,c,d;return O(function(e){return 1==e.g?(b=Array.from(a.g.values()),c=0<b.length,c||(d=wy,d.forEach(function(f){(f=f())&&b.push(f)})),E(e,Promise.all(b.map(function(f){return f.erase()})),2)):c?e.B(0):E(e,Promise.all(b.map(function(f){return f.destroy()})),0)})}function Dy(a,b){wy.set(a,b)}P("shaka.offline.StorageMuxer",vy);vy.unregister=function(a){wy.delete(a)};vy.register=Dy;vy.prototype.destroy=vy.prototype.destroy;var wy=new Map;function Ey(){py.apply(this,arguments)}na(Ey,py);Ey.prototype.updateManifestExpiration=function(a,b){var c=this,d,e,f;return O(function(g){d=ny(c.h,c.g);e=d.store();f=new lg;e.get(a).onsuccess=function(h){(h=h.target.result)?(h.expiration=b,e.put(h),f.resolve()):f.reject(new U(2,9,9012,"Could not find values for "+a))};return E(g,Promise.all([d.promise(),f]),0)})};
1145
- Ey.prototype.Ld=function(a){var b,c,d,e,f,g;return O(function(h){if(1==h.g){b=[];for(c=0;c<a.periods.length;++c)d=c==a.periods.length-1?a.duration:a.periods[c+1].startTime,e=d-a.periods[c].startTime,f=Fy(a.periods[c],e),b.push(f);return E(h,Yt(b),2)}g=h.h;return h.return({creationTime:0,originalManifestUri:a.originalManifestUri,duration:a.duration,size:a.size,expiration:null==a.expiration?Infinity:a.expiration,streams:g,sessionIds:a.sessionIds,drmInfo:a.drmInfo,appMetadata:a.appMetadata,sequenceMode:!1})})};
1146
- function Fy(a,b){Gy(a);for(var c=t(a.streams),d=c.next();!d.done;d=c.next());return a.streams.map(function(e){return Hy(e,a.startTime,b)})}
1147
- function Hy(a,b,c){var d=a.initSegmentUri?Iy(a.initSegmentUri):null,e=b+a.presentationTimeOffset,f=b+c;return{id:a.id,originalId:null,groupId:null,primary:a.primary,type:a.contentType,mimeType:a.mimeType,codecs:a.codecs,frameRate:a.frameRate,pixelAspectRatio:void 0,hdr:void 0,colorGamut:void 0,videoLayout:void 0,kind:a.kind,language:a.language,originalLanguage:a.language||null,label:a.label,width:a.width,height:a.height,initSegmentKey:d,encrypted:a.encrypted,keyIds:new Set([a.keyId]),segments:a.segments.map(function(g){var h=
1148
- Iy(g.uri);return{startTime:b+g.startTime,endTime:b+g.endTime,dataKey:h,initSegmentKey:d,appendWindowStart:b,appendWindowEnd:f,timestampOffset:e,tilesLayout:"",mimeType:null,codecs:null}}),variantIds:a.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0,external:!1,fastSwitching:!1}}Ey.prototype.xh=function(a){return{data:a.data}};
1149
- function Iy(a){var b;if((b=/^offline:[0-9]+\/[0-9]+\/([0-9]+)$/.exec(a))||(b=/^offline:segment\/([0-9]+)$/.exec(a)))return Number(b[1]);throw new U(2,9,9004,"Could not parse uri "+a);}
1150
- function Gy(a){var b=a.streams.filter(function(h){return"audio"==h.contentType});a=a.streams.filter(function(h){return"video"==h.contentType});if(!b.every(function(h){return h.variantIds})||!a.every(function(h){return h.variantIds})){for(var c=t(b),d=c.next();!d.done;d=c.next())d.value.variantIds=[];c=t(a);for(d=c.next();!d.done;d=c.next())d.value.variantIds=[];c=0;if(a.length&&!b.length){var e=c++,f=t(a);for(d=f.next();!d.done;d=f.next())d.value.variantIds.push(e)}if(!a.length&&b.length)for(e=c++,
1151
- f=t(b),d=f.next();!d.done;d=f.next())d.value.variantIds.push(e);if(a.length&&b.length)for(b=t(b),d=b.next();!d.done;d=b.next())for(d=d.value,e=t(a),f=e.next();!f.done;f=e.next()){f=f.value;var g=c++;d.variantIds.push(g);f.variantIds.push(g)}}};function Jy(){py.apply(this,arguments)}na(Jy,py);
1152
- Jy.prototype.Ld=function(a){var b,c,d,e,f,g;return O(function(h){if(1==h.g){b=[];for(c=0;c<a.periods.length;++c){d=c==a.periods.length-1?a.duration:a.periods[c+1].startTime;e=d-a.periods[c].startTime;for(var k=a.periods[c],l=[],m=t(k.streams),n=m.next();!n.done;n=m.next())n=n.value,0!=n.variantIds.length&&l.push(Ky(n,k.startTime,k.startTime+e));f=l;b.push(f)}return E(h,Yt(b),2)}g=h.h;return h.return({appMetadata:a.appMetadata,creationTime:0,drmInfo:a.drmInfo,duration:a.duration,expiration:null==a.expiration?
1133
+ function $x(a){var b=a.getAllResponseHeaders().trim().split("\r\n");a={};b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value.split(": "),a[c[0].toLowerCase()]=c.slice(1).join(": ");return a}P("shaka.net.HttpXHRPlugin",Xx);Xx.parse=Yx;var Zx=window.XMLHttpRequest;wg("http",Yx,1,!0);wg("https",Yx,1,!0);wg("blob",Yx,1,!0);function ay(a,b,c,d){this.g=a;this.i=b;this.groupId=c;this.h=d}function by(a){return a.P().map(function(b){return"{"+encodeURI(b)+"}"}).join("")+":"+a.Wa+":"+a.Da}function cy(a,b){return Bl(a.g.P(),a.g.Wa,a.g.Da,b.streaming.retryParameters)};function dy(){this.h=this.j=this.i=0;this.g=new Map;this.l=0}function ey(a,b){a.i+=b;var c=a.l;a.l++;a.g.set(c,b);return c}dy.prototype.close=function(a,b){if(this.g.has(a)){var c=this.g.get(a);this.g.delete(a);this.j+=c;this.h+=b}};function fy(a){var b=this;this.o=a;this.j=new Map;this.i=new Ig(function(){return gy(b).catch(function(){})});this.h=[];this.m=function(){};this.l=function(){};this.g=new dy}fy.prototype.destroy=function(){return this.i.destroy()};function hy(a,b,c){a.m=b;a.l=c}function gy(a){var b=a.h.map(function(c){return c()});a.h=[];return Promise.all(b)}
1134
+ function iy(a,b,c,d,e,f){Jg(a.i);var g=(a.j.get(b)||Promise.resolve()).then(function(){var h,k,l,m,n,p,r;return O(function(u){if(1==u.g)return E(u,jy(a,c),2);h=u.h;if(a.i.g)throw new U(2,9,7001);if(e)for(m in k=Gb(h),l=new $g(k),l.data)n=Number(m),p=l.data[n],r=l.g[n],a.l(p,r);a.g.close(d,h.byteLength);var v=a.g;a.m(0==v.i?0:v.j/v.i,a.g.h);return u.return(f(h))})});a.j.set(b,g)}function ky(a){return O(function(b){return 1==b.g?E(b,Promise.all(a.j.values()),2):b.return(a.g.h)})}
1135
+ function jy(a,b){var c,d,e,f;return O(function(g){if(1==g.g)return c=Gg,d=a.o.request(c,b),e=function(){return d.abort()},a.h.push(e),E(g,d.promise,2);f=g.h;Od(a.h,e);return g.return(f.data)})};function ly(a,b){var c=this;this.i=a;this.h=a.objectStore(b);this.g=new lg;a.onabort=function(d){d.preventDefault();c.g.reject()};a.onerror=function(d){d.preventDefault();c.g.reject()};a.oncomplete=function(){c.g.resolve()}}ly.prototype.abort=function(){var a=this;return O(function(b){if(1==b.g){try{a.i.abort()}catch(c){}ta(b,2);return E(b,a.g,4)}if(2!=b.g)return va(b,0);wa(b);F(b)})};
1136
+ function my(a,b){return new Promise(function(c,d){var e=a.h.openCursor();e.onerror=d;e.onsuccess=function(){var f;return O(function(g){if(1==g.g){if(null==e.result)return c(),g.return();f=e.result;return E(g,b(f.key,f.value,f),2)}f.continue();F(g)})}})}ly.prototype.store=function(){return this.h};ly.prototype.promise=function(){return this.g};function ny(a){this.h=a;this.g=[]}ny.prototype.destroy=function(){return Promise.all(this.g.map(function(a){return a.abort()}))};function oy(a,b){return py(a,b,"readwrite")}function py(a,b,c){c=a.h.transaction([b],c);var d=new ly(c,b);a.g.push(d);d.promise().then(function(){Od(a.g,d)},function(){Od(a.g,d)});return d};function qy(a,b,c){this.h=new ny(a);this.i=b;this.g=c}q=qy.prototype;q.destroy=function(){return this.h.destroy()};q.hasFixedKeySpace=function(){return!0};q.addSegments=function(){return ry(this.i)};q.removeSegments=function(a,b){return sy(this,this.i,a,b)};q.getSegments=function(a){var b=this,c;return O(function(d){if(1==d.g)return E(d,ty(b,b.i,a),2);c=d.h;return d.return(c.map(function(e){return b.xh(e)}))})};q.addManifests=function(){return ry(this.g)};
1137
+ q.updateManifest=function(){return Promise.reject(new U(2,9,9016,"Cannot modify values in "+this.g))};function uy(a,b,c){a=oy(a.h,a.g);var d=a.store();d.get(b).onsuccess=function(){d.put(c,b)};return a.promise()}q.updateManifestExpiration=function(a,b){var c=oy(this.h,this.g),d=c.store();d.get(a).onsuccess=function(e){if(e=e.target.result)e.expiration=b,d.put(e,a)};return c.promise()};q.removeManifests=function(a,b){return sy(this,this.g,a,b)};
1138
+ q.getManifests=function(a){var b=this,c;return O(function(d){if(1==d.g)return E(d,ty(b,b.g,a),2);c=d.h;return d.return(Promise.all(c.map(function(e){return b.Ld(e)})))})};q.getAllManifests=function(){var a=this,b,c;return O(function(d){return 1==d.g?(b=py(a.h,a.g,"readonly"),c=new Map,E(d,my(b,function(e,f){var g;return O(function(h){if(1==h.g)return E(h,a.Ld(f),2);g=h.h;c.set(e,g);F(h)})}),2)):3!=d.g?E(d,b.promise(),3):d.return(c)})};q.xh=function(a){return a};q.Ld=function(a){return Promise.resolve(a)};
1139
+ function ry(a){return Promise.reject(new U(2,9,9011,"Cannot add new value to "+a))}q.add=function(a,b){var c=this,d,e,f,g,h,k,l;return O(function(m){if(1==m.g){d=oy(c.h,a);e=d.store();f=[];g={};h=t(b);for(k=h.next();!k.done;g={xe:g.xe},k=h.next())l=k.value,g.xe=e.add(l),g.xe.onsuccess=function(n){return function(){f.push(n.xe.result)}}(g);return E(m,d.promise(),2)}return m.return(f)})};
1140
+ function sy(a,b,c,d){a=oy(a.h,b);b=a.store();var e={};c=t(c);for(var f=c.next();!f.done;e={ve:e.ve},f=c.next())e.ve=f.value,b.delete(e.ve).onsuccess=function(g){return function(){return d(g.ve)}}(e);return a.promise()}
1141
+ function ty(a,b,c){var d,e,f,g,h,k,l;return O(function(m){if(1==m.g){d=py(a.h,b,"readonly");e=d.store();f={};g=[];h={};k=t(c);for(l=k.next();!l.done;h={Bd:h.Bd,xd:h.xd},l=k.next())h.xd=l.value,h.Bd=e.get(h.xd),h.Bd.onsuccess=function(n){return function(){void 0==n.Bd.result&&g.push(n.xd);f[n.xd]=n.Bd.result}}(h);return E(m,d.promise(),2)}if(g.length)throw new U(2,9,9012,"Could not find values for "+g);return m.return(c.map(function(n){return f[n]}))})};function vy(a){this.g=new ny(a)}vy.prototype.destroy=function(){return this.g.destroy()};vy.prototype.getAll=function(){var a=this,b,c;return O(function(d){return 1==d.g?(b=py(a.g,"session-ids","readonly"),c=[],E(d,my(b,function(e,f){c.push(f)}),2)):3!=d.g?E(d,b.promise(),3):d.return(c)})};vy.prototype.add=function(a){var b=oy(this.g,"session-ids"),c=b.store();a=t(a);for(var d=a.next();!d.done;d=a.next())c.add(d.value);return b.promise()};
1142
+ vy.prototype.remove=function(a){var b=this,c;return O(function(d){return 1==d.g?(c=oy(b.g,"session-ids"),E(d,my(c,function(e,f,g){a.includes(f.sessionId)&&g.delete()}),2)):E(d,c.promise(),0)})};function wy(){this.g=new Map}wy.prototype.destroy=function(){for(var a=[],b=t(this.g.values()),c=b.next();!c.done;c=b.next())a.push(c.value.destroy());this.g.clear();return Promise.all(a)};wy.prototype.init=function(){var a=this;xy.forEach(function(e,f){(e=e())&&a.g.set(f,e)});for(var b=[],c=t(this.g.values()),d=c.next();!d.done;d=c.next())b.push(d.value.init());return Promise.all(b)};
1143
+ function yy(a){var b=null;a.g.forEach(function(c,d){c.getCells().forEach(function(e,f){e.hasFixedKeySpace()||b||(b={path:{Eb:d,$a:f},$a:e})})});if(b)return b;throw new U(2,9,9013,"Could not find a cell that supports add-operations");}function zy(a,b){a.g.forEach(function(c,d){c.getCells().forEach(function(e,f){b({Eb:d,$a:f},e)})})}
1144
+ function Ay(a,b,c){a=a.g.get(b);if(!a)throw new U(2,9,9013,"Could not find mechanism with name "+b);b=a.getCells().get(c);if(!b)throw new U(2,9,9013,"Could not find cell with name "+c);return b}function By(a,b){a.g.forEach(function(c){b(c.getEmeSessionCell())})}function Cy(a){var b=Array.from(a.g.keys());if(!b.length)throw new U(2,9,9E3,"No supported storage mechanisms found");return a.g.get(b[0]).getEmeSessionCell()}
1145
+ function Dy(a){var b,c,d;return O(function(e){return 1==e.g?(b=Array.from(a.g.values()),c=0<b.length,c||(d=xy,d.forEach(function(f){(f=f())&&b.push(f)})),E(e,Promise.all(b.map(function(f){return f.erase()})),2)):c?e.B(0):E(e,Promise.all(b.map(function(f){return f.destroy()})),0)})}function Ey(a,b){xy.set(a,b)}P("shaka.offline.StorageMuxer",wy);wy.unregister=function(a){xy.delete(a)};wy.register=Ey;wy.prototype.destroy=wy.prototype.destroy;var xy=new Map;function Fy(){qy.apply(this,arguments)}na(Fy,qy);Fy.prototype.updateManifestExpiration=function(a,b){var c=this,d,e,f;return O(function(g){d=oy(c.h,c.g);e=d.store();f=new lg;e.get(a).onsuccess=function(h){(h=h.target.result)?(h.expiration=b,e.put(h),f.resolve()):f.reject(new U(2,9,9012,"Could not find values for "+a))};return E(g,Promise.all([d.promise(),f]),0)})};
1146
+ Fy.prototype.Ld=function(a){var b,c,d,e,f,g;return O(function(h){if(1==h.g){b=[];for(c=0;c<a.periods.length;++c)d=c==a.periods.length-1?a.duration:a.periods[c+1].startTime,e=d-a.periods[c].startTime,f=Gy(a.periods[c],e),b.push(f);return E(h,Yt(b),2)}g=h.h;return h.return({creationTime:0,originalManifestUri:a.originalManifestUri,duration:a.duration,size:a.size,expiration:null==a.expiration?Infinity:a.expiration,streams:g,sessionIds:a.sessionIds,drmInfo:a.drmInfo,appMetadata:a.appMetadata,sequenceMode:!1})})};
1147
+ function Gy(a,b){Hy(a);for(var c=t(a.streams),d=c.next();!d.done;d=c.next());return a.streams.map(function(e){return Iy(e,a.startTime,b)})}
1148
+ function Iy(a,b,c){var d=a.initSegmentUri?Jy(a.initSegmentUri):null,e=b+a.presentationTimeOffset,f=b+c;return{id:a.id,originalId:null,groupId:null,primary:a.primary,type:a.contentType,mimeType:a.mimeType,codecs:a.codecs,frameRate:a.frameRate,pixelAspectRatio:void 0,hdr:void 0,colorGamut:void 0,videoLayout:void 0,kind:a.kind,language:a.language,originalLanguage:a.language||null,label:a.label,width:a.width,height:a.height,initSegmentKey:d,encrypted:a.encrypted,keyIds:new Set([a.keyId]),segments:a.segments.map(function(g){var h=
1149
+ Jy(g.uri);return{startTime:b+g.startTime,endTime:b+g.endTime,dataKey:h,initSegmentKey:d,appendWindowStart:b,appendWindowEnd:f,timestampOffset:e,tilesLayout:"",mimeType:null,codecs:null}}),variantIds:a.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0,external:!1,fastSwitching:!1}}Fy.prototype.xh=function(a){return{data:a.data}};
1150
+ function Jy(a){var b;if((b=/^offline:[0-9]+\/[0-9]+\/([0-9]+)$/.exec(a))||(b=/^offline:segment\/([0-9]+)$/.exec(a)))return Number(b[1]);throw new U(2,9,9004,"Could not parse uri "+a);}
1151
+ function Hy(a){var b=a.streams.filter(function(h){return"audio"==h.contentType});a=a.streams.filter(function(h){return"video"==h.contentType});if(!b.every(function(h){return h.variantIds})||!a.every(function(h){return h.variantIds})){for(var c=t(b),d=c.next();!d.done;d=c.next())d.value.variantIds=[];c=t(a);for(d=c.next();!d.done;d=c.next())d.value.variantIds=[];c=0;if(a.length&&!b.length){var e=c++,f=t(a);for(d=f.next();!d.done;d=f.next())d.value.variantIds.push(e)}if(!a.length&&b.length)for(e=c++,
1152
+ f=t(b),d=f.next();!d.done;d=f.next())d.value.variantIds.push(e);if(a.length&&b.length)for(b=t(b),d=b.next();!d.done;d=b.next())for(d=d.value,e=t(a),f=e.next();!f.done;f=e.next()){f=f.value;var g=c++;d.variantIds.push(g);f.variantIds.push(g)}}};function Ky(){qy.apply(this,arguments)}na(Ky,qy);
1153
+ Ky.prototype.Ld=function(a){var b,c,d,e,f,g;return O(function(h){if(1==h.g){b=[];for(c=0;c<a.periods.length;++c){d=c==a.periods.length-1?a.duration:a.periods[c+1].startTime;e=d-a.periods[c].startTime;for(var k=a.periods[c],l=[],m=t(k.streams),n=m.next();!n.done;n=m.next())n=n.value,0!=n.variantIds.length&&l.push(Ly(n,k.startTime,k.startTime+e));f=l;b.push(f)}return E(h,Yt(b),2)}g=h.h;return h.return({appMetadata:a.appMetadata,creationTime:0,drmInfo:a.drmInfo,duration:a.duration,expiration:null==a.expiration?
1153
1154
  Infinity:a.expiration,originalManifestUri:a.originalManifestUri,sessionIds:a.sessionIds,size:a.size,streams:g,sequenceMode:!1})})};
1154
- function Ky(a,b,c){return{id:a.id,originalId:a.originalId,groupId:null,primary:a.primary,type:a.contentType,mimeType:a.mimeType,codecs:a.codecs,frameRate:a.frameRate,pixelAspectRatio:a.pixelAspectRatio,hdr:void 0,colorGamut:void 0,videoLayout:void 0,kind:a.kind,language:a.language,originalLanguage:a.language||null,label:a.label,width:a.width,height:a.height,encrypted:a.encrypted,keyIds:new Set([a.keyId]),segments:a.segments.map(function(d){return{startTime:b+d.startTime,endTime:b+d.endTime,initSegmentKey:a.initSegmentKey,
1155
- appendWindowStart:b,appendWindowEnd:c,timestampOffset:b-a.presentationTimeOffset,dataKey:d.dataKey,tilesLayout:"",mimeType:null,codecs:null}}),variantIds:a.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0,external:!1,fastSwitching:!1}};function Ly(){py.apply(this,arguments)}na(Ly,py);q=Ly.prototype;q.hasFixedKeySpace=function(){return!1};q.addSegments=function(a){return this.add(this.i,a)};q.addManifests=function(a){return this.add(this.g,a)};q.updateManifest=function(a,b){return ty(this,a,b)};q.Ld=function(a){null==a.expiration&&(a.expiration=Infinity);return Promise.resolve(a)};function My(){this.m=this.j=this.i=this.h=this.g=this.l=null}q=My.prototype;
1156
- q.init=function(){var a=this,b=new lg,c=!1,d=new Ub(function(){c=!0;b.reject(new U(2,9,9017))});d.V(5);var e=window.indexedDB.open("shaka_offline_db",5);e.onsuccess=function(){if(!c){var f=e.result;a.l=f;var g=f.objectStoreNames;g=g.contains("manifest")&&g.contains("segment")?new Ey(f,"segment","manifest"):null;a.g=g;g=f.objectStoreNames;g=g.contains("manifest-v2")&&g.contains("segment-v2")?new Jy(f,"segment-v2","manifest-v2"):null;a.h=g;g=f.objectStoreNames;g=g.contains("manifest-v3")&&g.contains("segment-v3")?
1157
- new Jy(f,"segment-v3","manifest-v3"):null;a.i=g;g=f.objectStoreNames;g=g.contains("manifest-v5")&&g.contains("segment-v5")?new Ly(f,"segment-v5","manifest-v5"):null;a.j=g;f=f.objectStoreNames.contains("session-ids")?new uy(f):null;a.m=f;d.stop();b.resolve()}};e.onupgradeneeded=function(){for(var f=e.result,g=t(["segment-v5","manifest-v5","session-ids"]),h=g.next();!h.done;h=g.next())h=h.value,f.objectStoreNames.contains(h)||f.createObjectStore(h,{autoIncrement:!0})};e.onerror=function(f){c||(b.reject(new U(2,
1155
+ function Ly(a,b,c){return{id:a.id,originalId:a.originalId,groupId:null,primary:a.primary,type:a.contentType,mimeType:a.mimeType,codecs:a.codecs,frameRate:a.frameRate,pixelAspectRatio:a.pixelAspectRatio,hdr:void 0,colorGamut:void 0,videoLayout:void 0,kind:a.kind,language:a.language,originalLanguage:a.language||null,label:a.label,width:a.width,height:a.height,encrypted:a.encrypted,keyIds:new Set([a.keyId]),segments:a.segments.map(function(d){return{startTime:b+d.startTime,endTime:b+d.endTime,initSegmentKey:a.initSegmentKey,
1156
+ appendWindowStart:b,appendWindowEnd:c,timestampOffset:b-a.presentationTimeOffset,dataKey:d.dataKey,tilesLayout:"",mimeType:null,codecs:null}}),variantIds:a.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0,external:!1,fastSwitching:!1}};function My(){qy.apply(this,arguments)}na(My,qy);q=My.prototype;q.hasFixedKeySpace=function(){return!1};q.addSegments=function(a){return this.add(this.i,a)};q.addManifests=function(a){return this.add(this.g,a)};q.updateManifest=function(a,b){return uy(this,a,b)};q.Ld=function(a){null==a.expiration&&(a.expiration=Infinity);return Promise.resolve(a)};function Ny(){this.m=this.j=this.i=this.h=this.g=this.l=null}q=Ny.prototype;
1157
+ q.init=function(){var a=this,b=new lg,c=!1,d=new Ub(function(){c=!0;b.reject(new U(2,9,9017))});d.V(5);var e=window.indexedDB.open("shaka_offline_db",5);e.onsuccess=function(){if(!c){var f=e.result;a.l=f;var g=f.objectStoreNames;g=g.contains("manifest")&&g.contains("segment")?new Fy(f,"segment","manifest"):null;a.g=g;g=f.objectStoreNames;g=g.contains("manifest-v2")&&g.contains("segment-v2")?new Ky(f,"segment-v2","manifest-v2"):null;a.h=g;g=f.objectStoreNames;g=g.contains("manifest-v3")&&g.contains("segment-v3")?
1158
+ new Ky(f,"segment-v3","manifest-v3"):null;a.i=g;g=f.objectStoreNames;g=g.contains("manifest-v5")&&g.contains("segment-v5")?new My(f,"segment-v5","manifest-v5"):null;a.j=g;f=f.objectStoreNames.contains("session-ids")?new vy(f):null;a.m=f;d.stop();b.resolve()}};e.onupgradeneeded=function(){for(var f=e.result,g=t(["segment-v5","manifest-v5","session-ids"]),h=g.next();!h.done;h=g.next())h=h.value,f.objectStoreNames.contains(h)||f.createObjectStore(h,{autoIncrement:!0})};e.onerror=function(f){c||(b.reject(new U(2,
1158
1159
  9,9001,e.error)),d.stop(),f.preventDefault())};return b};q.destroy=function(){var a=this;return O(function(b){switch(b.g){case 1:if(!a.g){b.B(2);break}return E(b,a.g.destroy(),2);case 2:if(!a.h){b.B(4);break}return E(b,a.h.destroy(),4);case 4:if(!a.i){b.B(6);break}return E(b,a.i.destroy(),6);case 6:if(!a.j){b.B(8);break}return E(b,a.j.destroy(),8);case 8:if(!a.m){b.B(10);break}return E(b,a.m.destroy(),10);case 10:a.l&&a.l.close(),F(b)}})};
1159
1160
  q.getCells=function(){var a=new Map;this.g&&a.set("v1",this.g);this.h&&a.set("v2",this.h);this.i&&a.set("v3",this.i);this.j&&a.set("v5",this.j);return a};q.getEmeSessionCell=function(){return this.m};
1160
- q.erase=function(){var a=this;return O(function(b){switch(b.g){case 1:if(!a.g){b.B(2);break}return E(b,a.g.destroy(),2);case 2:if(!a.h){b.B(4);break}return E(b,a.h.destroy(),4);case 4:if(!a.i){b.B(6);break}return E(b,a.i.destroy(),6);case 6:if(!a.j){b.B(8);break}return E(b,a.j.destroy(),8);case 8:return a.l&&a.l.close(),E(b,Ny(),10);case 10:return a.l=null,a.g=null,a.h=null,a.i=null,a.j=null,E(b,a.init(),0)}})};
1161
- function Ny(){var a=new lg,b=window.indexedDB.deleteDatabase("shaka_offline_db");b.onblocked=function(){};b.onsuccess=function(){a.resolve()};b.onerror=function(c){a.reject(new U(2,9,9001,b.error));c.preventDefault()};return a}Dy("idb",function(){return gc()||Zb()||!window.indexedDB?null:new My});function Oy(a,b,c,d){this.g=a;this.i=b;this.h=c;this.l=d;this.j=["offline:",a,"/",b,"/",c,"/",d].join("")}Oy.prototype.Eb=function(){return this.i};Oy.prototype.$a=function(){return this.h};Oy.prototype.key=function(){return this.l};Oy.prototype.toString=function(){return this.j};
1162
- function Py(a){a=/^offline:([a-z]+)\/([^/]+)\/([^/]+)\/([0-9]+)$/.exec(a);if(null==a)return null;var b=a[1];if("manifest"!=b&&"segment"!=b)return null;var c=a[2];if(!c)return null;var d=a[3];return d&&null!=b?new Oy(b,c,d,Number(a[4])):null};function Qy(a,b){this.h=a;this.g=b}
1163
- function Ry(a,b){var c=new Bk(null,0);c.sb(b.duration);var d=b.streams.filter(function(l){return"audio"==l.type}),e=b.streams.filter(function(l){return"video"==l.type});d=Sy(a,d,e,c);e=b.streams.filter(function(l){return l.type==Sc}).map(function(l){return Ty(a,l,c)});var f=b.streams.filter(function(l){return"image"==l.type}).map(function(l){return Ty(a,l,c)}),g=b.drmInfo?[b.drmInfo]:[];if(b.drmInfo)for(var h=t(d.values()),k=h.next();!k.done;k=h.next())k=k.value,k.audio&&k.audio.encrypted&&(k.audio.drmInfos=
1161
+ q.erase=function(){var a=this;return O(function(b){switch(b.g){case 1:if(!a.g){b.B(2);break}return E(b,a.g.destroy(),2);case 2:if(!a.h){b.B(4);break}return E(b,a.h.destroy(),4);case 4:if(!a.i){b.B(6);break}return E(b,a.i.destroy(),6);case 6:if(!a.j){b.B(8);break}return E(b,a.j.destroy(),8);case 8:return a.l&&a.l.close(),E(b,Oy(),10);case 10:return a.l=null,a.g=null,a.h=null,a.i=null,a.j=null,E(b,a.init(),0)}})};
1162
+ function Oy(){var a=new lg,b=window.indexedDB.deleteDatabase("shaka_offline_db");b.onblocked=function(){};b.onsuccess=function(){a.resolve()};b.onerror=function(c){a.reject(new U(2,9,9001,b.error));c.preventDefault()};return a}Ey("idb",function(){return gc()||Zb()||!window.indexedDB?null:new Ny});function Py(a,b,c,d){this.g=a;this.i=b;this.h=c;this.l=d;this.j=["offline:",a,"/",b,"/",c,"/",d].join("")}Py.prototype.Eb=function(){return this.i};Py.prototype.$a=function(){return this.h};Py.prototype.key=function(){return this.l};Py.prototype.toString=function(){return this.j};
1163
+ function Qy(a){a=/^offline:([a-z]+)\/([^/]+)\/([^/]+)\/([0-9]+)$/.exec(a);if(null==a)return null;var b=a[1];if("manifest"!=b&&"segment"!=b)return null;var c=a[2];if(!c)return null;var d=a[3];return d&&null!=b?new Py(b,c,d,Number(a[4])):null};function Ry(a,b){this.h=a;this.g=b}
1164
+ function Sy(a,b){var c=new Bk(null,0);c.sb(b.duration);var d=b.streams.filter(function(l){return"audio"==l.type}),e=b.streams.filter(function(l){return"video"==l.type});d=Ty(a,d,e,c);e=b.streams.filter(function(l){return l.type==Sc}).map(function(l){return Uy(a,l,c)});var f=b.streams.filter(function(l){return"image"==l.type}).map(function(l){return Uy(a,l,c)}),g=b.drmInfo?[b.drmInfo]:[];if(b.drmInfo)for(var h=t(d.values()),k=h.next();!k.done;k=h.next())k=k.value,k.audio&&k.audio.encrypted&&(k.audio.drmInfos=
1164
1165
  g),k.video&&k.video.encrypted&&(k.video.drmInfos=g);return{presentationTimeline:c,minBufferTime:2,offlineSessionIds:b.sessionIds,variants:Array.from(d.values()),textStreams:e,imageStreams:f,sequenceMode:b.sequenceMode||!1,ignoreManifestTimestampsInSegmentsMode:!1,type:b.type||"UNKNOWN",serviceDescription:null,nextUrl:null}}
1165
- function Sy(a,b,c,d){for(var e=new Set,f=t(b),g=f.next();!g.done;g=f.next()){var h=t(g.value.variantIds);for(g=h.next();!g.done;g=h.next())e.add(g.value)}f=t(c);for(g=f.next();!g.done;g=f.next())for(h=t(g.value.variantIds),g=h.next();!g.done;g=h.next())e.add(g.value);f=new Map;e=t(e);for(g=e.next();!g.done;g=e.next())g=g.value,f.set(g,{id:g,language:"",disabledUntilTime:0,primary:!1,audio:null,video:null,bandwidth:0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});b=t(b);for(e=b.next();!e.done;e=
1166
- b.next())for(e=e.value,g=Ty(a,e,d),h=t(e.variantIds),e=h.next();!e.done;e=h.next())e=f.get(e.value),e.language=g.language,e.primary=e.primary||g.primary,e.audio=g;c=t(c);for(b=c.next();!b.done;b=c.next())for(e=b.value,b=Ty(a,e,d),g=t(e.variantIds),e=g.next();!e.done;e=g.next())e=f.get(e.value),e.primary=e.primary||b.primary,e.video=b;return f}
1167
- function Ty(a,b,c){var d=b.segments.map(function(e){return Uy(a,e,b)});c.ce(d);return{id:b.id,originalId:b.originalId,groupId:b.groupId,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Xk(d),mimeType:b.mimeType,codecs:b.codecs,width:b.width||void 0,height:b.height||void 0,frameRate:b.frameRate,pixelAspectRatio:b.pixelAspectRatio,hdr:b.hdr,colorGamut:b.colorGamut,videoLayout:b.videoLayout,kind:b.kind,encrypted:b.encrypted,drmInfos:[],keyIds:b.keyIds,language:b.language,originalLanguage:b.originalLanguage||
1166
+ function Ty(a,b,c,d){for(var e=new Set,f=t(b),g=f.next();!g.done;g=f.next()){var h=t(g.value.variantIds);for(g=h.next();!g.done;g=h.next())e.add(g.value)}f=t(c);for(g=f.next();!g.done;g=f.next())for(h=t(g.value.variantIds),g=h.next();!g.done;g=h.next())e.add(g.value);f=new Map;e=t(e);for(g=e.next();!g.done;g=e.next())g=g.value,f.set(g,{id:g,language:"",disabledUntilTime:0,primary:!1,audio:null,video:null,bandwidth:0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});b=t(b);for(e=b.next();!e.done;e=
1167
+ b.next())for(e=e.value,g=Uy(a,e,d),h=t(e.variantIds),e=h.next();!e.done;e=h.next())e=f.get(e.value),e.language=g.language,e.primary=e.primary||g.primary,e.audio=g;c=t(c);for(b=c.next();!b.done;b=c.next())for(e=b.value,b=Uy(a,e,d),g=t(e.variantIds),e=g.next();!e.done;e=g.next())e=f.get(e.value),e.primary=e.primary||b.primary,e.video=b;return f}
1168
+ function Uy(a,b,c){var d=b.segments.map(function(e){return Vy(a,e,b)});c.ce(d);return{id:b.id,originalId:b.originalId,groupId:b.groupId,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Xk(d),mimeType:b.mimeType,codecs:b.codecs,width:b.width||void 0,height:b.height||void 0,frameRate:b.frameRate,pixelAspectRatio:b.pixelAspectRatio,hdr:b.hdr,colorGamut:b.colorGamut,videoLayout:b.videoLayout,kind:b.kind,encrypted:b.encrypted,drmInfos:[],keyIds:b.keyIds,language:b.language,originalLanguage:b.originalLanguage||
1168
1169
  null,label:b.label,type:b.type,primary:b.primary,trickModeVideo:null,emsgSchemeIdUris:null,roles:b.roles,forced:b.forced,channelsCount:b.channelsCount,audioSamplingRate:b.audioSamplingRate,spatialAudio:b.spatialAudio,closedCaptions:b.closedCaptions,tilesLayout:b.tilesLayout,accessibilityPurpose:null,external:b.external,fastSwitching:b.fastSwitching,fullMimeTypes:new Set([te(b.mimeType,b.codecs)])}}
1169
- function Uy(a,b,c){var d=new Oy("segment",a.h,a.g,b.dataKey);a=new Ii(b.startTime,b.endTime,function(){return[d.toString()]},0,null,null!=b.initSegmentKey?Vy(a,b.initSegmentKey):null,b.timestampOffset,b.appendWindowStart,b.appendWindowEnd,[],b.tilesLayout||"");a.mimeType=b.mimeType||c.mimeType||"";a.codecs=b.codecs||c.codecs||"";return a}function Vy(a,b){var c=new Oy("segment",a.h,a.g,b);return new Gi(function(){return[c.toString()]},0,null)};function Wy(){this.g=null}q=Wy.prototype;q.configure=function(){};
1170
- q.start=function(a,b){var c=this,d,e,f,g,h,k,l;return O(function(m){switch(m.g){case 1:d=Py(a);c.g=d;if(null==d||"manifest"!=d.g)throw new U(2,1,9004,a);e=new vy;ua(m,2);return E(m,e.init(),4);case 4:return E(m,zy(e,d.Eb(),d.$a()),5);case 5:return f=m.h,E(m,f.getManifests([d.key()]),6);case 6:return g=m.h,h=g[0],k=new Qy(d.Eb(),d.$a()),l=Ry(k,h),b.makeTextStreamsForClosedCaptions(l),m.return(l);case 2:return xa(m),E(m,e.destroy(),7);case 7:ya(m,0)}})};q.stop=function(){return Promise.resolve()};
1170
+ function Vy(a,b,c){var d=new Py("segment",a.h,a.g,b.dataKey);a=new Ii(b.startTime,b.endTime,function(){return[d.toString()]},0,null,null!=b.initSegmentKey?Wy(a,b.initSegmentKey):null,b.timestampOffset,b.appendWindowStart,b.appendWindowEnd,[],b.tilesLayout||"");a.mimeType=b.mimeType||c.mimeType||"";a.codecs=b.codecs||c.codecs||"";return a}function Wy(a,b){var c=new Py("segment",a.h,a.g,b);return new Gi(function(){return[c.toString()]},0,null)};function Xy(){this.g=null}q=Xy.prototype;q.configure=function(){};
1171
+ q.start=function(a,b){var c=this,d,e,f,g,h,k,l;return O(function(m){switch(m.g){case 1:d=Qy(a);c.g=d;if(null==d||"manifest"!=d.g)throw new U(2,1,9004,a);e=new wy;ua(m,2);return E(m,e.init(),4);case 4:return E(m,Ay(e,d.Eb(),d.$a()),5);case 5:return f=m.h,E(m,f.getManifests([d.key()]),6);case 6:return g=m.h,h=g[0],k=new Ry(d.Eb(),d.$a()),l=Sy(k,h),b.makeTextStreamsForClosedCaptions(l),m.return(l);case 2:return xa(m),E(m,e.destroy(),7);case 7:ya(m,0)}})};q.stop=function(){return Promise.resolve()};
1171
1172
  q.update=function(){};
1172
- q.onExpirationUpdated=function(a,b){var c=this,d,e,f,g,h,k,l;return O(function(m){switch(m.g){case 1:return d=c.g,e=new vy,ta(m,2,3),E(m,e.init(),5);case 5:return E(m,zy(e,d.Eb(),d.$a()),6);case 6:return f=m.h,E(m,f.getManifests([d.key()]),7);case 7:g=m.h;h=g[0];k=h.sessionIds.includes(a);l=void 0==h.expiration||h.expiration>b;if(!k||!l){m.B(3);break}return E(m,f.updateManifestExpiration(d.key(),b),3);case 3:return xa(m),E(m,e.destroy(),10);case 10:ya(m,0);break;case 2:wa(m),m.B(3)}})};
1173
- q.onInitialVariantChosen=function(){};q.banLocation=function(){};Bi["application/x-offline-manifest"]=function(){return new Wy};function Xy(){}function Yy(a){var b=Py(a);b&&"manifest"==b.g?(a={uri:a,originalUri:a,data:new ArrayBuffer(0),headers:{"content-type":"application/x-offline-manifest"}},a=pg(a)):a=b&&"segment"==b.g?Zy(b.key(),b):ng(new U(2,1,9004,a));return a}
1174
- function Zy(a,b){var c=new vy;return pg(void 0).Qa(function(){return c.init()}).Qa(function(){return zy(c,b.Eb(),b.$a())}).Qa(function(d){return d.getSegments([b.key()])}).Qa(function(d){return{uri:b,data:d[0].data,headers:{}}}).finally(function(){return c.destroy()})}P("shaka.offline.OfflineScheme",Xy);Xy.plugin=Yy;wg("offline",Yy);function $y(a,b,c){var d,e,f,g,h,k;return O(function(l){switch(l.g){case 1:d=[];for(var m=[],n=t(c),p=n.next();!p.done;p=n.next()){p=p.value;for(var r=!1,u=t(m),v=u.next();!v.done;v=u.next())if(v=v.value,az(v.info,p)){v.sessionIds.push(p.sessionId);r=!0;break}r||m.push({info:p,sessionIds:[p.sessionId]})}e=t(m);f=e.next();case 2:if(f.done){l.B(4);break}g=f.value;h=bz(a,b,g);return E(l,h,5);case 5:k=l.h;d=d.concat(k);f=e.next();l.B(2);break;case 4:return l.return(d)}})}
1175
- function bz(a,b,c){var d,e;return O(function(f){switch(f.g){case 1:return d=new Jh({Zb:b,onError:function(){},bf:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),ta(f,2),d.configure(a),E(f,Rh(d,c.info.keySystem,c.info.licenseUri,c.info.serverCertificate,c.info.audioCapabilities,c.info.videoCapabilities),4);case 4:va(f,3);break;case 2:return wa(f),E(f,d.destroy(),5);case 5:return f.return([]);case 3:return e=[],E(f,Promise.all(c.sessionIds.map(function(g){return O(function(h){if(1==
1176
- h.g)return ta(h,2),E(h,ci(d,g),4);if(2!=h.g)return e.push(g),va(h,0);wa(h);F(h)})})),6);case 6:return E(f,d.destroy(),7);case 7:return f.return(e)}})}function az(a,b){function c(d,e){return d.robustness==e.robustness&&d.contentType==e.contentType}return a.keySystem==b.keySystem&&a.licenseUri==b.licenseUri&&Pd(a.audioCapabilities,b.audioCapabilities,c)&&Pd(a.videoCapabilities,b.videoCapabilities,c)};function cz(a,b,c){var d=b.presentationTimeline.getDuration();b=dz(b);return{offlineUri:null,originalManifestUri:a,duration:d,size:0,expiration:Infinity,tracks:b,appMetadata:c,isIncomplete:!1}}function ez(a,b){var c=Ry(new Qy(a.Eb(),a.$a()),b),d=b.appMetadata||{};c=dz(c);return{offlineUri:a.toString(),originalManifestUri:b.originalManifestUri,duration:b.duration,size:b.size,expiration:b.expiration,tracks:c,appMetadata:d,isIncomplete:b.isIncomplete||!1}}
1177
- function dz(a){var b=[],c=Ff(a.variants);c=t(c);for(var d=c.next();!d.done;d=c.next())b.push(wf(d.value));a=t(a.textStreams);for(c=a.next();!c.done;c=a.next())b.push(xf(c.value));return b};function fz(){this.g={}}function gz(a,b){var c=b.audio,d=b.video;c&&!d&&(a.g[c.id]=c.bandwidth||b.bandwidth);!c&&d&&(a.g[d.id]=d.bandwidth||b.bandwidth);if(c&&d){var e=c.bandwidth||393216,f=d.bandwidth||b.bandwidth-e;0>=f&&(f=b.bandwidth);a.g[c.id]=e;a.g[d.id]=f}}function hz(a,b){a.g[b.id]=b.bandwidth||2048}function iz(a,b){a=a.g[b];null==a&&(a=0);return a};function jz(a){var b=this;if(a&&a.constructor!=X)throw new U(2,9,9008);this.g=this.h=null;a?(this.h=a.g,this.g=a.hc()):(this.h=vm(),this.g=new vg);this.i=[];this.j=[];var c=!a;this.l=new Ig(function(){var d,e,f,g,h;return O(function(k){switch(k.g){case 1:return E(k,Promise.all(b.j.map(function(l){return fy(l)})),2);case 2:d=function(){};e=[];f=t(b.i);for(g=f.next();!g.done;g=f.next())h=g.value,e.push(h.then(d,d));return E(k,Promise.all(e),3);case 3:if(!c){k.B(4);break}return E(k,b.g.destroy(),4);
1178
- case 4:b.h=null,b.g=null,F(k)}})})}function kz(){if(Vb())a:{var a=t(wy.values());for(var b=a.next();!b.done;b=a.next())if(b=b.value,b=b()){b.destroy();a=!0;break a}a=!1}else a=!1;return a}q=jz.prototype;q.destroy=function(){return this.l.destroy()};q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=mm(a,b));return zm(this.h,a)};q.getConfiguration=function(){var a=vm();zm(a,this.h,vm());return a};q.hc=function(){return this.g};
1179
- q.store=function(a,b,c){var d=this,e=this.getConfiguration(),f=new ey(this.g);this.j.push(f);b=lz(this,a,b||{},function(){var g;return O(function(h){if(1==h.g)return c?h.B(2):E(h,Um(a,d.g,e.manifest.retryParameters),3);2!=h.g&&(c=h.h);g=Ai(a,c||null);return h.return(g())})},e,f);b=new mg(b,function(){return fy(f)});b.finally(function(){Od(d.j,f)});return mz(this,b)};
1180
- function lz(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,u,v,w,A,z,C;return O(function(y){switch(y.g){case 1:return nz(),h=g=null,k=new vy,n=m=l=null,ta(y,2,3),E(y,d(),5);case 5:return g=y.h,E(y,oz(a,b,g,e),6);case 6:p=y.h;pz(a);r=!p.presentationTimeline.U()&&!p.presentationTimeline.Ec();if(!r)throw new U(2,9,9005,b);return E(y,a.Vc(p,function(B){n=n||B},e),7);case 7:h=y.h;pz(a);if(n)throw n;return E(y,qz(p,h,e),8);case 8:return E(y,k.init(),9);case 9:return pz(a),E(y,xy(k),10);case 10:return l=y.h,pz(a),u=rz(h,
1181
- p,b,c,e,f),v=u.Oj,w=u.hh,E(y,l.$a.addManifests([v]),11);case 11:A=y.h;pz(a);m=A[0];pz(a);if(n)throw n;return E(y,sz(a,w,m,v,f,e,l.$a,p,h),12);case 12:return pz(a),tz(p,v,h,e),E(y,l.$a.updateManifest(m,v),13);case 13:return pz(a),z=new Oy("manifest",l.path.Eb,l.path.$a,m),y.return(ez(z,v));case 3:return xa(y),E(y,k.destroy(),14);case 14:if(!g){y.B(15);break}return E(y,g.stop(),15);case 15:if(!h){y.B(17);break}return E(y,h.destroy(),17);case 17:ya(y,0);break;case 2:C=wa(y);if(null==m){y.B(19);break}return E(y,
1182
- uz(m),19);case 19:throw n||C;}})}
1183
- function sz(a,b,c,d,e,f,g,h,k){var l,m,n,p,r,u,v,w,A,z;return O(function(C){switch(C.g){case 1:l={};m=0;n=function(y,B){var D,K,G,J,I,H,N;return O(function(L){if(1==L.g){D={};K=t(y);for(G=K.next();!G.done;D={rc:D.rc},G=K.next())D.rc=G.value,J=by(D.rc,f),I=D.rc.i,H=D.rc.h,N=function(M){return function(Q){var T,R,ra;return O(function(sa){if(1==sa.g)return E(sa,g.addSegments([{data:Q}]),2);T=sa.h;pz(a);R=M.rc.g;ra=ay(R);l[ra]=T[0];m+=Q.byteLength;F(sa)})}}(D),hy(e,D.rc.groupId,J,I,H,N);return E(L,jy(e),
1184
- 2)}if(!B)return L.B(0);pz(a);tz(h,d,k,f);return E(L,g.updateManifest(c,d),0)})};p=!1;ta(C,2);if(!vz(h)||!p||wz(h)){C.B(4);break}return E(C,n(b.filter(function(y){return y.h}),!0),5);case 5:return pz(a),b=b.filter(function(y){return!y.h}),r=l,u=m,l={},m=0,E(C,xz(g,c,d,r,u,function(){return pz(a)}),6);case 6:pz(a);case 4:if(p){C.B(7);break}return E(C,n(b,!1),8);case 8:return pz(a),v=l,w=m,l={},m=0,E(C,xz(g,c,d,v,w,function(){return pz(a)}),9);case 9:pz(a);case 7:va(C,0);break;case 2:return A=wa(C),
1185
- z=Object.values(l),E(C,g.removeSegments(z,function(){}),10);case 10:throw A;}})}function uz(a){var b,c,d,e;return O(function(f){switch(f.g){case 1:return b=new vy,E(f,b.init(),2);case 2:return E(f,xy(b),3);case 3:return c=f.h,d=new Oy("manifest",c.path.Eb,c.path.$a,a),E(f,b.destroy(),4);case 4:return e=new jz,E(f,e.remove(d.toString()),0)}})}
1186
- function xz(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,u,v,w;return O(function(A){switch(A.g){case 1:g=!1;ta(A,2);h=!0;k=t(c.streams);for(l=k.next();!l.done;l=k.next())for(m=l.value,n=t(m.segments),p=n.next();!p.done;p=n.next())r=p.value,u=r.pendingSegmentRefId?d[r.pendingSegmentRefId]:null,null!=u&&(r.dataKey=u,r.pendingSegmentRefId=void 0),u=r.pendingInitSegmentRefId?d[r.pendingInitSegmentRefId]:null,null!=u&&(r.initSegmentKey=u,r.pendingInitSegmentRefId=void 0),r.pendingSegmentRefId&&(h=!1),r.pendingInitSegmentRefId&&
1187
- (h=!1);c.size+=e;h&&(c.isIncomplete=!1);return E(A,a.updateManifest(b,c),4);case 4:g=!0;f();va(A,0);break;case 2:return v=wa(A),E(A,uz(b),5);case 5:if(g){A.B(6);break}w=Object.values(d);return E(A,a.removeSegments(w,function(){}),6);case 6:throw v;}})}
1188
- function qz(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M;return O(function(Q){switch(Q.g){case 1:return d={width:Infinity,height:Infinity},bf(a,c.restrictions,d),E(Q,ff(b,a,c.offline.usePersistentLicense,c.drm.preferredKeySystems),2);case 2:e=[];f=c.preferredDecodingAttributes;g=c.preferredVideoCodecs;h=c.preferredAudioCodecs;$e(a,g,h,f);k=t(a.variants);for(l=k.next();!l.done;l=k.next())m=l.value,e.push(wf(m));n=t(a.textStreams);for(p=n.next();!p.done;p=n.next())r=p.value,e.push(xf(r));
1173
+ q.onExpirationUpdated=function(a,b){var c=this,d,e,f,g,h,k,l;return O(function(m){switch(m.g){case 1:return d=c.g,e=new wy,ta(m,2,3),E(m,e.init(),5);case 5:return E(m,Ay(e,d.Eb(),d.$a()),6);case 6:return f=m.h,E(m,f.getManifests([d.key()]),7);case 7:g=m.h;h=g[0];k=h.sessionIds.includes(a);l=void 0==h.expiration||h.expiration>b;if(!k||!l){m.B(3);break}return E(m,f.updateManifestExpiration(d.key(),b),3);case 3:return xa(m),E(m,e.destroy(),10);case 10:ya(m,0);break;case 2:wa(m),m.B(3)}})};
1174
+ q.onInitialVariantChosen=function(){};q.banLocation=function(){};Bi["application/x-offline-manifest"]=function(){return new Xy};function Yy(){}function Zy(a){var b=Qy(a);b&&"manifest"==b.g?(a={uri:a,originalUri:a,data:new ArrayBuffer(0),headers:{"content-type":"application/x-offline-manifest"}},a=pg(a)):a=b&&"segment"==b.g?$y(b.key(),b):ng(new U(2,1,9004,a));return a}
1175
+ function $y(a,b){var c=new wy;return pg(void 0).Qa(function(){return c.init()}).Qa(function(){return Ay(c,b.Eb(),b.$a())}).Qa(function(d){return d.getSegments([b.key()])}).Qa(function(d){return{uri:b,data:d[0].data,headers:{}}}).finally(function(){return c.destroy()})}P("shaka.offline.OfflineScheme",Yy);Yy.plugin=Zy;wg("offline",Zy);function az(a,b,c){var d,e,f,g,h,k;return O(function(l){switch(l.g){case 1:d=[];for(var m=[],n=t(c),p=n.next();!p.done;p=n.next()){p=p.value;for(var r=!1,u=t(m),v=u.next();!v.done;v=u.next())if(v=v.value,bz(v.info,p)){v.sessionIds.push(p.sessionId);r=!0;break}r||m.push({info:p,sessionIds:[p.sessionId]})}e=t(m);f=e.next();case 2:if(f.done){l.B(4);break}g=f.value;h=cz(a,b,g);return E(l,h,5);case 5:k=l.h;d=d.concat(k);f=e.next();l.B(2);break;case 4:return l.return(d)}})}
1176
+ function cz(a,b,c){var d,e;return O(function(f){switch(f.g){case 1:return d=new Jh({Zb:b,onError:function(){},bf:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),ta(f,2),d.configure(a),E(f,Rh(d,c.info.keySystem,c.info.licenseUri,c.info.serverCertificate,c.info.audioCapabilities,c.info.videoCapabilities),4);case 4:va(f,3);break;case 2:return wa(f),E(f,d.destroy(),5);case 5:return f.return([]);case 3:return e=[],E(f,Promise.all(c.sessionIds.map(function(g){return O(function(h){if(1==
1177
+ h.g)return ta(h,2),E(h,ci(d,g),4);if(2!=h.g)return e.push(g),va(h,0);wa(h);F(h)})})),6);case 6:return E(f,d.destroy(),7);case 7:return f.return(e)}})}function bz(a,b){function c(d,e){return d.robustness==e.robustness&&d.contentType==e.contentType}return a.keySystem==b.keySystem&&a.licenseUri==b.licenseUri&&Pd(a.audioCapabilities,b.audioCapabilities,c)&&Pd(a.videoCapabilities,b.videoCapabilities,c)};function dz(a,b,c){var d=b.presentationTimeline.getDuration();b=ez(b);return{offlineUri:null,originalManifestUri:a,duration:d,size:0,expiration:Infinity,tracks:b,appMetadata:c,isIncomplete:!1}}function fz(a,b){var c=Sy(new Ry(a.Eb(),a.$a()),b),d=b.appMetadata||{};c=ez(c);return{offlineUri:a.toString(),originalManifestUri:b.originalManifestUri,duration:b.duration,size:b.size,expiration:b.expiration,tracks:c,appMetadata:d,isIncomplete:b.isIncomplete||!1}}
1178
+ function ez(a){var b=[],c=Ff(a.variants);c=t(c);for(var d=c.next();!d.done;d=c.next())b.push(wf(d.value));a=t(a.textStreams);for(c=a.next();!c.done;c=a.next())b.push(xf(c.value));return b};function gz(){this.g={}}function hz(a,b){var c=b.audio,d=b.video;c&&!d&&(a.g[c.id]=c.bandwidth||b.bandwidth);!c&&d&&(a.g[d.id]=d.bandwidth||b.bandwidth);if(c&&d){var e=c.bandwidth||393216,f=d.bandwidth||b.bandwidth-e;0>=f&&(f=b.bandwidth);a.g[c.id]=e;a.g[d.id]=f}}function iz(a,b){a.g[b.id]=b.bandwidth||2048}function jz(a,b){a=a.g[b];null==a&&(a=0);return a};function kz(a){var b=this;if(a&&a.constructor!=X)throw new U(2,9,9008);this.g=this.h=null;a?(this.h=a.g,this.g=a.hc()):(this.h=vm(),this.g=new vg);this.i=[];this.j=[];var c=!a;this.l=new Ig(function(){var d,e,f,g,h;return O(function(k){switch(k.g){case 1:return E(k,Promise.all(b.j.map(function(l){return gy(l)})),2);case 2:d=function(){};e=[];f=t(b.i);for(g=f.next();!g.done;g=f.next())h=g.value,e.push(h.then(d,d));return E(k,Promise.all(e),3);case 3:if(!c){k.B(4);break}return E(k,b.g.destroy(),4);
1179
+ case 4:b.h=null,b.g=null,F(k)}})})}function lz(){if(Vb())a:{var a=t(xy.values());for(var b=a.next();!b.done;b=a.next())if(b=b.value,b=b()){b.destroy();a=!0;break a}a=!1}else a=!1;return a}q=kz.prototype;q.destroy=function(){return this.l.destroy()};q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=mm(a,b));return zm(this.h,a)};q.getConfiguration=function(){var a=vm();zm(a,this.h,vm());return a};q.hc=function(){return this.g};
1180
+ q.store=function(a,b,c){var d=this,e=this.getConfiguration(),f=new fy(this.g);this.j.push(f);b=mz(this,a,b||{},function(){var g;return O(function(h){if(1==h.g)return c?h.B(2):E(h,Um(a,d.g,e.manifest.retryParameters),3);2!=h.g&&(c=h.h);g=Ai(a,c||null);return h.return(g())})},e,f);b=new mg(b,function(){return gy(f)});b.finally(function(){Od(d.j,f)});return nz(this,b)};
1181
+ function mz(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,u,v,w,A,z,C;return O(function(y){switch(y.g){case 1:return oz(),h=g=null,k=new wy,n=m=l=null,ta(y,2,3),E(y,d(),5);case 5:return g=y.h,E(y,pz(a,b,g,e),6);case 6:p=y.h;qz(a);r=!p.presentationTimeline.U()&&!p.presentationTimeline.Fc();if(!r)throw new U(2,9,9005,b);return E(y,a.Wc(p,function(B){n=n||B},e),7);case 7:h=y.h;qz(a);if(n)throw n;return E(y,rz(p,h,e),8);case 8:return E(y,k.init(),9);case 9:return qz(a),E(y,yy(k),10);case 10:return l=y.h,qz(a),u=sz(h,
1182
+ p,b,c,e,f),v=u.Oj,w=u.hh,E(y,l.$a.addManifests([v]),11);case 11:A=y.h;qz(a);m=A[0];qz(a);if(n)throw n;return E(y,tz(a,w,m,v,f,e,l.$a,p,h),12);case 12:return qz(a),uz(p,v,h,e),E(y,l.$a.updateManifest(m,v),13);case 13:return qz(a),z=new Py("manifest",l.path.Eb,l.path.$a,m),y.return(fz(z,v));case 3:return xa(y),E(y,k.destroy(),14);case 14:if(!g){y.B(15);break}return E(y,g.stop(),15);case 15:if(!h){y.B(17);break}return E(y,h.destroy(),17);case 17:ya(y,0);break;case 2:C=wa(y);if(null==m){y.B(19);break}return E(y,
1183
+ vz(m),19);case 19:throw n||C;}})}
1184
+ function tz(a,b,c,d,e,f,g,h,k){var l,m,n,p,r,u,v,w,A,z;return O(function(C){switch(C.g){case 1:l={};m=0;n=function(y,B){var D,K,G,J,I,H,N;return O(function(L){if(1==L.g){D={};K=t(y);for(G=K.next();!G.done;D={tc:D.tc},G=K.next())D.tc=G.value,J=cy(D.tc,f),I=D.tc.i,H=D.tc.h,N=function(M){return function(Q){var T,R,ra;return O(function(sa){if(1==sa.g)return E(sa,g.addSegments([{data:Q}]),2);T=sa.h;qz(a);R=M.tc.g;ra=by(R);l[ra]=T[0];m+=Q.byteLength;F(sa)})}}(D),iy(e,D.tc.groupId,J,I,H,N);return E(L,ky(e),
1185
+ 2)}if(!B)return L.B(0);qz(a);uz(h,d,k,f);return E(L,g.updateManifest(c,d),0)})};p=!1;ta(C,2);if(!wz(h)||!p||xz(h)){C.B(4);break}return E(C,n(b.filter(function(y){return y.h}),!0),5);case 5:return qz(a),b=b.filter(function(y){return!y.h}),r=l,u=m,l={},m=0,E(C,yz(g,c,d,r,u,function(){return qz(a)}),6);case 6:qz(a);case 4:if(p){C.B(7);break}return E(C,n(b,!1),8);case 8:return qz(a),v=l,w=m,l={},m=0,E(C,yz(g,c,d,v,w,function(){return qz(a)}),9);case 9:qz(a);case 7:va(C,0);break;case 2:return A=wa(C),
1186
+ z=Object.values(l),E(C,g.removeSegments(z,function(){}),10);case 10:throw A;}})}function vz(a){var b,c,d,e;return O(function(f){switch(f.g){case 1:return b=new wy,E(f,b.init(),2);case 2:return E(f,yy(b),3);case 3:return c=f.h,d=new Py("manifest",c.path.Eb,c.path.$a,a),E(f,b.destroy(),4);case 4:return e=new kz,E(f,e.remove(d.toString()),0)}})}
1187
+ function yz(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,u,v,w;return O(function(A){switch(A.g){case 1:g=!1;ta(A,2);h=!0;k=t(c.streams);for(l=k.next();!l.done;l=k.next())for(m=l.value,n=t(m.segments),p=n.next();!p.done;p=n.next())r=p.value,u=r.pendingSegmentRefId?d[r.pendingSegmentRefId]:null,null!=u&&(r.dataKey=u,r.pendingSegmentRefId=void 0),u=r.pendingInitSegmentRefId?d[r.pendingInitSegmentRefId]:null,null!=u&&(r.initSegmentKey=u,r.pendingInitSegmentRefId=void 0),r.pendingSegmentRefId&&(h=!1),r.pendingInitSegmentRefId&&
1188
+ (h=!1);c.size+=e;h&&(c.isIncomplete=!1);return E(A,a.updateManifest(b,c),4);case 4:g=!0;f();va(A,0);break;case 2:return v=wa(A),E(A,vz(b),5);case 5:if(g){A.B(6);break}w=Object.values(d);return E(A,a.removeSegments(w,function(){}),6);case 6:throw v;}})}
1189
+ function rz(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y,B,D,K,G,J,I,H,N,L,M;return O(function(Q){switch(Q.g){case 1:return d={width:Infinity,height:Infinity},bf(a,c.restrictions,d),E(Q,ff(b,a,c.offline.usePersistentLicense,c.drm.preferredKeySystems),2);case 2:e=[];f=c.preferredDecodingAttributes;g=c.preferredVideoCodecs;h=c.preferredAudioCodecs;$e(a,g,h,f);k=t(a.variants);for(l=k.next();!l.done;l=k.next())m=l.value,e.push(wf(m));n=t(a.textStreams);for(p=n.next();!p.done;p=n.next())r=p.value,e.push(xf(r));
1189
1190
  u=t(a.imageStreams);for(v=u.next();!v.done;v=u.next())w=v.value,e.push(yf(w));return E(Q,c.offline.trackSelectionCallback(e),3);case 3:A=Q.h;z=a.presentationTimeline.getDuration();C=0;y=t(A);for(B=y.next();!B.done;B=y.next())D=B.value,K=D.bandwidth*z/8,C+=K;ta(Q,4);return E(Q,c.offline.downloadSizeCallback(C),6);case 6:G=Q.h;if(!G)throw new U(2,9,9014);va(Q,5);break;case 4:J=wa(Q);if(J instanceof U)throw J;throw new U(2,9,9015);case 5:I=new Set;H=new Set;N=new Set;L=t(A);for(B=L.next();!B.done;B=
1190
- L.next())M=B.value,"variant"==M.type&&I.add(M.id),"text"==M.type&&H.add(M.id),"image"==M.type&&N.add(M.id);a.variants=a.variants.filter(function(T){return I.has(T.id)});a.textStreams=a.textStreams.filter(function(T){return H.has(T.id)});a.imageStreams=a.imageStreams.filter(function(T){return N.has(T.id)});yz(a);F(Q)}})}
1191
- function rz(a,b,c,d,e,f){var g=cz(c,b,d),h=e.offline.progressCallback;gy(f,function(r,u){g.size=u;h(g,r)},function(r,u){k&&e.offline.usePersistentLicense&&l==u&&Zh(a,"cenc",r)});var k=vz(b)&&!wz(b),l=null;k&&(l=zz.get(a.g.keySystem));for(var m=new fz,n=t(b.textStreams),p=n.next();!p.done;p=n.next())m.g[p.value.id]=52;n=t(b.imageStreams);for(p=n.next();!p.done;p=n.next())hz(m,p.value);p=t(b.variants);for(n=p.next();!n.done;n=p.next())gz(m,n.value);m=Az(f,m,b,e);f=m.streams;m=m.hh;p=a.g;n=e.offline.usePersistentLicense;
1192
- p&&n&&(p.initData=[]);return{Oj:{creationTime:Date.now(),originalManifestUri:c,duration:b.presentationTimeline.getDuration(),size:0,expiration:a.Pd(),streams:f,sessionIds:n?hi(a):[],drmInfo:p,appMetadata:d,isIncomplete:!0,sequenceMode:b.sequenceMode,type:b.type},hh:m}}function vz(a){return a.variants.some(function(b){var c=b.audio&&b.audio.encrypted;return b.video&&b.video.encrypted||c})}
1193
- function wz(a){return a.variants.some(function(b){return(b.video?b.video.drmInfos:[]).concat(b.audio?b.audio.drmInfos:[]).some(function(c){return c.initData&&c.initData.length})})}function tz(a,b,c,d){b.expiration=c.Pd();c=hi(c);b.sessionIds=d.offline.usePersistentLicense?c:[];if(vz(a)&&d.offline.usePersistentLicense&&!c.length)throw new U(2,9,9007);}q.remove=function(a){return Bz(this,Cz(this,a))};
1194
- function Cz(a,b){var c,d,e,f,g,h;return O(function(k){switch(k.g){case 1:nz();c=Py(b);if(null==c||"manifest"!=c.g)throw new U(2,9,9004,b);d=c;e=new vy;ua(k,2);return E(k,e.init(),4);case 4:return E(k,zy(e,d.Eb(),d.$a()),5);case 5:return f=k.h,E(k,f.getManifests([d.key()]),6);case 6:return g=k.h,h=g[0],E(k,Promise.all([Dz(a,h,e),Ez(f,d,h)]),2);case 2:return xa(k),E(k,e.destroy(),8);case 8:ya(k,0)}})}
1195
- function Fz(a,b){for(var c=[],d=t(a.streams),e=d.next();!e.done;e=d.next())e=e.value,b&&"video"==e.type?c.push({contentType:te(e.mimeType,e.codecs),robustness:a.drmInfo.videoRobustness}):b||"audio"!=e.type||c.push({contentType:te(e.mimeType,e.codecs),robustness:a.drmInfo.audioRobustness});return c}function Dz(a,b,c){return O(function(d){return E(d,Gz(a.g,a.h.drm,c,b),0)})}
1196
- function Ez(a,b,c){function d(){}var e=Hz(c);ez(b,c);return Promise.all([a.removeSegments(e,d),a.removeManifests([b.key()],d)])}q.fk=function(){return Bz(this,Iz(this))};
1197
- function Iz(a){var b,c,d,e,f,g,h,k,l,m;return O(function(n){switch(n.g){case 1:return nz(),b=a.g,c=a.h.drm,d=new vy,e=!1,ua(n,2),E(n,d.init(),4);case 4:f=[],Ay(d,function(p){return f.push(p)}),g=t(f),h=g.next();case 5:if(h.done){n.B(2);break}k=h.value;return E(n,k.getAll(),8);case 8:return l=n.h,E(n,$y(c,b,l),9);case 9:return m=n.h,E(n,k.remove(m),10);case 10:m.length!=l.length&&(e=!0);h=g.next();n.B(5);break;case 2:return xa(n),E(n,d.destroy(),11);case 11:ya(n,3);break;case 3:return n.return(!e)}})}
1198
- q.list=function(){return Bz(this,Jz())};function Jz(){var a,b,c;return O(function(d){switch(d.g){case 1:return nz(),a=[],b=new vy,ua(d,2),E(d,b.init(),4);case 4:return c=Promise.resolve(),yy(b,function(e,f){c=c.then(function(){var g;return O(function(h){if(1==h.g)return E(h,f.getAllManifests(),2);g=h.h;g.forEach(function(k,l){k=ez(new Oy("manifest",e.Eb,e.$a,l),k);a.push(k)});F(h)})})}),E(d,c,2);case 2:return xa(d),E(d,b.destroy(),6);case 6:ya(d,3);break;case 3:return d.return(a)}})}
1199
- function oz(a,b,c,d){var e,f,g,h,k;return O(function(l){if(1==l.g)return e=null,f=a.g,g={networkingEngine:f,filter:function(){return Promise.resolve()},makeTextStreamsForClosedCaptions:function(){},onTimelineRegionAdded:function(){},onEvent:function(){},onError:function(m){e=m},isLowLatencyMode:function(){return!1},isAutoLowLatencyMode:function(){return!1},enableLowLatencyMode:function(){},updateDuration:function(){},newDrmInfo:function(){},onManifestUpdated:function(){},getBandwidthEstimate:function(){return d.abr.defaultBandwidthEstimate}},
1200
- c.configure(d.manifest),pz(a),E(l,c.start(b,g),2);if(3!=l.g)return h=l.h,pz(a),k=Kz(h),E(l,Promise.all(hb(k,function(m){return m.createSegmentIndex()})),3);pz(a);if(e)throw e;return l.return(h)})}q.Vc=function(a,b,c){var d=this,e;return O(function(f){return 1==f.g?(e=new Jh({Zb:d.g,onError:b,bf:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),e.configure(c.drm),E(f,Oh(e,a.variants,c.offline.usePersistentLicense),2)):3!=f.g?E(f,ai(e),3):f.return(e)})};
1201
- function Az(a,b,c,d){var e=new Map,f=Kz(c),g=new Map;f=t(f);for(var h=f.next();!h.done;h=f.next()){h=h.value;var k=Lz(a,b,c,h,d,e);g.set(h.id,k)}a=t(c.variants);for(b=a.next();!b.done;b=a.next())b=b.value,b.audio&&g.get(b.audio.id).variantIds.push(b.id),b.video&&g.get(b.video.id).variantIds.push(b.id);return{streams:Array.from(g.values()),hh:Array.from(e.values())}}
1202
- function Lz(a,b,c,d,e,f){var g={id:d.id,originalId:d.originalId,groupId:d.groupId,primary:d.primary,type:d.type,mimeType:d.mimeType,codecs:d.codecs,frameRate:d.frameRate,pixelAspectRatio:d.pixelAspectRatio,hdr:d.hdr,colorGamut:d.colorGamut,videoLayout:d.videoLayout,kind:d.kind,language:d.language,originalLanguage:d.originalLanguage,label:d.label,width:d.width||null,height:d.height||null,encrypted:d.encrypted,keyIds:d.keyIds,segments:[],variantIds:[],roles:d.roles,forced:d.forced,channelsCount:d.channelsCount,
1203
- audioSamplingRate:d.audioSamplingRate,spatialAudio:d.spatialAudio,closedCaptions:d.closedCaptions,tilesLayout:d.tilesLayout,external:d.external,fastSwitching:d.fastSwitching},h=e.offline.numberOfParallelDownloads,k=0;Mz(d,c.presentationTimeline.Cb(),function(l){var m=ay(l),n=void 0;if(!f.has(m)){var p=l.endTime-l.startTime;p=iz(b,d.id)*p;p=dy(a.g,p);f.set(m,new $x(l,p,k,!1))}l.sa&&(n=ay(l.sa),f.has(n)||(p=.5*iz(b,d.id),p=dy(a.g,p),f.set(n,new $x(l.sa,p,k,!0))));g.segments.push({pendingInitSegmentRefId:n,
1204
- initSegmentKey:n?0:null,startTime:l.startTime,endTime:l.endTime,appendWindowStart:l.appendWindowStart,appendWindowEnd:l.appendWindowEnd,timestampOffset:l.timestampOffset,tilesLayout:l.tilesLayout,pendingSegmentRefId:m,dataKey:0,mimeType:l.mimeType,codecs:l.codecs});k=(k+1)%h});return g}function Mz(a,b,c){b=a.segmentIndex.find(b);if(null!=b)for(var d=a.segmentIndex.get(b);d;)c(d),d=a.segmentIndex.get(++b)}function pz(a){if(a.l.g)throw new U(2,9,7001);}function nz(){if(!kz())throw new U(2,9,9E3);}
1205
- function Bz(a,b){return O(function(c){if(1==c.g)return a.i.push(b),ua(c,2),E(c,b,4);if(2!=c.g)return c.return(c.h);xa(c);Od(a.i,b);return ya(c,0)})}function mz(a,b){var c=b.promise;a.i.push(c);return b.finally(function(){Od(a.i,c)})}function Hz(a){var b=new Set;a=t(a.streams);for(var c=a.next();!c.done;c=a.next()){c=t(c.value.segments);for(var d=c.next();!d.done;d=c.next())d=d.value,null!=d.initSegmentKey&&b.add(d.initSegmentKey),b.add(d.dataKey)}return Array.from(b)}
1206
- function Gz(a,b,c,d){var e,f,g;return O(function(h){if(1==h.g){if(!d.drmInfo)return h.return();e=By(c);f=d.sessionIds.map(function(k){return{sessionId:k,keySystem:d.drmInfo.keySystem,licenseUri:d.drmInfo.licenseServerUri,serverCertificate:d.drmInfo.serverCertificate,audioCapabilities:Fz(d,!1),videoCapabilities:Fz(d,!0)}});return E(h,$y(b,a,f),2)}return 3!=h.g?(g=h.h,E(h,e.remove(g),3)):E(h,e.add(f.filter(function(k){return!g.includes(k.sessionId)})),0)})}
1207
- function Kz(a){for(var b=new Set,c=t(a.textStreams),d=c.next();!d.done;d=c.next())b.add(d.value);c=t(a.imageStreams);for(d=c.next();!d.done;d=c.next())b.add(d.value);a=t(a.variants);for(c=a.next();!c.done;c=a.next())c=c.value,c.audio&&b.add(c.audio),c.video&&b.add(c.video);return b}
1208
- function yz(a){a.variants.map(function(f){return f.video});var b=new Set(a.variants.map(function(f){return f.audio}));a=a.textStreams;for(var c=t(b),d=c.next();!d.done;d=c.next()){d=t(b);for(var e=d.next();!e.done;e=d.next());}b=t(a);for(c=b.next();!c.done;c=b.next())for(c=t(a),d=c.next();!d.done;d=c.next());}P("shaka.offline.Storage",jz);jz.deleteAll=function(){var a;return O(function(b){return 1==b.g?(a=new vy,ua(b,2),E(b,Cy(a),2)):5!=b.g?(xa(b),E(b,a.destroy(),5)):ya(b,0)})};
1209
- jz.prototype.list=jz.prototype.list;jz.prototype.removeEmeSessions=jz.prototype.fk;jz.prototype.remove=jz.prototype.remove;jz.prototype.store=jz.prototype.store;jz.prototype.getNetworkingEngine=jz.prototype.hc;jz.prototype.getConfiguration=jz.prototype.getConfiguration;jz.prototype.configure=jz.prototype.configure;jz.prototype.destroy=jz.prototype.destroy;jz.support=kz;
1210
- var zz=(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");zp.offline=kz;function Nz(){}function Oz(){for(var a=t(Pz),b=a.next();!b.done;b=a.next()){b=b.value;try{b.callback()}catch(c){Ya("Error installing polyfill!",c)}}}function Qz(a,b){a={priority:b||0,callback:a};for(b=0;b<Pz.length;b++)if(Pz[b].priority<a.priority){Pz.splice(b,0,a);return}Pz.push(a)}P("shaka.polyfill",Nz);Nz.register=Qz;Nz.installAll=Oz;var Pz=[];function Rz(){this.g=new Sz}function Tz(){window.AbortController||(window.AbortController=Rz,window.AbortSignal=Sz)}Rz.prototype.abort=function(a){var b=this.g;if(!b.h){b.h=!0;b.g=a;void 0===b.g&&(b.g=new DOMException("signal is aborted without reason","AbortError"));a=new S("abort");if(b.onabort)b.onabort(a);b.dispatchEvent(a)}};da.Object.defineProperties(Rz.prototype,{signal:{configurable:!0,enumerable:!0,get:function(){return this.g}}});Nz.AbortController=Rz;Rz.install=Tz;
1211
- function Sz(){gb.call(this);this.h=!1;this.g=void 0;this.onabort=null}na(Sz,gb);da.Object.defineProperties(Sz.prototype,{aborted:{configurable:!0,enumerable:!0,get:function(){return this.h}},reason:{configurable:!0,enumerable:!0,get:function(){return this.g}}});Qz(Tz);function Uz(){}function Vz(){if(!Object.getOwnPropertyDescriptor(Element.prototype,"ariaHidden"))for(var a=t(["ariaHidden","ariaLabel","ariaPressed","ariaSelected"]),b=a.next();!b.done;b=a.next())Wz(b.value)}function Wz(a){var b="aria-"+a.toLowerCase().replace(/^aria/,"");Object.defineProperty(Element.prototype,a,{get:function(){return this.getAttribute(b)},set:function(c){null==c||void 0==c?this.removeAttribute(b):this.setAttribute(b,c)}})}Nz.Aria=Uz;Uz.install=Vz;Qz(Vz);function Xz(){}function Yz(){Zz()}Nz.EncryptionScheme=Xz;Xz.install=Yz;Qz(Yz,-2);function $z(){}
1212
- function aA(){if(window.Document){var a=Element.prototype;a.requestFullscreen=a.requestFullscreen||a.mozRequestFullScreen||a.msRequestFullscreen||a.webkitRequestFullscreen;a=Document.prototype;a.exitFullscreen=a.exitFullscreen||a.mozCancelFullScreen||a.msExitFullscreen||a.webkitCancelFullScreen;"fullscreenElement"in document||(Object.defineProperty(document,"fullscreenElement",{get:function(){return document.mozFullScreenElement||document.msFullscreenElement||document.webkitCurrentFullScreenElement||document.webkitFullscreenElement}}),
1213
- Object.defineProperty(document,"fullscreenEnabled",{get:function(){return document.mozFullScreenEnabled||document.msFullscreenEnabled||document.webkitFullscreenEnabled}}));document.addEventListener("webkitfullscreenchange",bA);document.addEventListener("webkitfullscreenerror",bA);document.addEventListener("mozfullscreenchange",bA);document.addEventListener("mozfullscreenerror",bA);document.addEventListener("MSFullscreenChange",bA);document.addEventListener("MSFullscreenError",bA)}}
1214
- function bA(a){var b=a.type.replace(/^(webkit|moz|MS)/,"").toLowerCase(),c=document.createEvent("Event");c.initEvent(b,a.bubbles,a.cancelable);a.target.dispatchEvent(c)}Nz.Fullscreen=$z;$z.install=aA;Qz(aA);function cA(){}function dA(){var a=!0;!gc()||gc()&&oc()||gc()&&$b("Fuchsia")||(a=!1);if(hc()||kc()||jc()||dc()||ac()||$b("PC=EOS")||lc())a=!1;a&&navigator.mediaCapabilities||(navigator.mediaCapabilities||(navigator.mediaCapabilities={}),eA=navigator.mediaCapabilities,navigator.mediaCapabilities.decodingInfo=fA)}
1215
- function fA(a){var b,c,d,e,f,g,h,k,l,m,n;return O(function(p){switch(p.g){case 1:b={supported:!1,powerEfficient:!0,smooth:!0,keySystemAccess:null,configuration:a};c=a.video;d=a.audio;if("media-source"!=a.type){if("file"==a.type){if(c&&(e=c.contentType,f=Wb(e),!f)||d&&(g=d.contentType,h=Wb(g),!h))return p.return(b)}else return p.return(b);p.B(2);break}if(!Vb())return p.return(b);if(!c){p.B(3);break}return E(p,gA(c),4);case 4:if(k=p.h,!k)return p.return(b);case 3:if(d){var r=d.contentType;gc()&&d.spatialRendering&&
1216
- (r+="; spatialRendering=true");l=td(r);if(!l)return p.return(b)}case 2:if(!a.keySystemConfiguration)return b.supported=!0,p.return(b);m=a.keySystemConfiguration;return E(p,hA(c,d,m),6);case 6:if(n=p.h)b.supported=!0,b.keySystemAccess=n;case 5:return p.return(b)}})}
1217
- function gA(a){var b,c;return O(function(d){return 1==d.g?gc()?E(d,iA(a),3):ac()?(b=a.contentType,a.width&&a.height&&(b+="; width="+a.width,b+="; height="+a.height),a.framerate&&(b+="; framerate="+a.framerate),a.bitrate&&(b+="; bitrate="+a.bitrate),d.return(td(b))):d.B(2):2!=d.g?(c=d.h,d.return(c)):d.return(td(a.contentType))})}
1218
- function hA(a,b,c){var d,e,f,g,h,k,l,m,n;return O(function(p){switch(p.g){case 1:d=[];e=[];c.audio&&(f={robustness:c.audio.robustness||"",contentType:b.contentType},ac()&&b.contentType.includes('codecs="ac-3"')&&(f.contentType='audio/mp4; codecs="ec-3"'),c.audio.encryptionScheme&&(f.encryptionScheme=c.audio.encryptionScheme),d.push(f));c.video&&(g={robustness:c.video.robustness||"",contentType:a.contentType},c.video.encryptionScheme&&(g.encryptionScheme=c.video.encryptionScheme),e.push(g));h={initDataTypes:[c.initDataType],
1191
+ L.next())M=B.value,"variant"==M.type&&I.add(M.id),"text"==M.type&&H.add(M.id),"image"==M.type&&N.add(M.id);a.variants=a.variants.filter(function(T){return I.has(T.id)});a.textStreams=a.textStreams.filter(function(T){return H.has(T.id)});a.imageStreams=a.imageStreams.filter(function(T){return N.has(T.id)});zz(a);F(Q)}})}
1192
+ function sz(a,b,c,d,e,f){var g=dz(c,b,d),h=e.offline.progressCallback;hy(f,function(r,u){g.size=u;h(g,r)},function(r,u){k&&e.offline.usePersistentLicense&&l==u&&Zh(a,"cenc",r)});var k=wz(b)&&!xz(b),l=null;k&&(l=Az.get(a.g.keySystem));for(var m=new gz,n=t(b.textStreams),p=n.next();!p.done;p=n.next())m.g[p.value.id]=52;n=t(b.imageStreams);for(p=n.next();!p.done;p=n.next())iz(m,p.value);p=t(b.variants);for(n=p.next();!n.done;n=p.next())hz(m,n.value);m=Bz(f,m,b,e);f=m.streams;m=m.hh;p=a.g;n=e.offline.usePersistentLicense;
1193
+ p&&n&&(p.initData=[]);return{Oj:{creationTime:Date.now(),originalManifestUri:c,duration:b.presentationTimeline.getDuration(),size:0,expiration:a.Pd(),streams:f,sessionIds:n?hi(a):[],drmInfo:p,appMetadata:d,isIncomplete:!0,sequenceMode:b.sequenceMode,type:b.type},hh:m}}function wz(a){return a.variants.some(function(b){var c=b.audio&&b.audio.encrypted;return b.video&&b.video.encrypted||c})}
1194
+ function xz(a){return a.variants.some(function(b){return(b.video?b.video.drmInfos:[]).concat(b.audio?b.audio.drmInfos:[]).some(function(c){return c.initData&&c.initData.length})})}function uz(a,b,c,d){b.expiration=c.Pd();c=hi(c);b.sessionIds=d.offline.usePersistentLicense?c:[];if(wz(a)&&d.offline.usePersistentLicense&&!c.length)throw new U(2,9,9007);}q.remove=function(a){return Cz(this,Dz(this,a))};
1195
+ function Dz(a,b){var c,d,e,f,g,h;return O(function(k){switch(k.g){case 1:oz();c=Qy(b);if(null==c||"manifest"!=c.g)throw new U(2,9,9004,b);d=c;e=new wy;ua(k,2);return E(k,e.init(),4);case 4:return E(k,Ay(e,d.Eb(),d.$a()),5);case 5:return f=k.h,E(k,f.getManifests([d.key()]),6);case 6:return g=k.h,h=g[0],E(k,Promise.all([Ez(a,h,e),Fz(f,d,h)]),2);case 2:return xa(k),E(k,e.destroy(),8);case 8:ya(k,0)}})}
1196
+ function Gz(a,b){for(var c=[],d=t(a.streams),e=d.next();!e.done;e=d.next())e=e.value,b&&"video"==e.type?c.push({contentType:te(e.mimeType,e.codecs),robustness:a.drmInfo.videoRobustness}):b||"audio"!=e.type||c.push({contentType:te(e.mimeType,e.codecs),robustness:a.drmInfo.audioRobustness});return c}function Ez(a,b,c){return O(function(d){return E(d,Hz(a.g,a.h.drm,c,b),0)})}
1197
+ function Fz(a,b,c){function d(){}var e=Iz(c);fz(b,c);return Promise.all([a.removeSegments(e,d),a.removeManifests([b.key()],d)])}q.fk=function(){return Cz(this,Jz(this))};
1198
+ function Jz(a){var b,c,d,e,f,g,h,k,l,m;return O(function(n){switch(n.g){case 1:return oz(),b=a.g,c=a.h.drm,d=new wy,e=!1,ua(n,2),E(n,d.init(),4);case 4:f=[],By(d,function(p){return f.push(p)}),g=t(f),h=g.next();case 5:if(h.done){n.B(2);break}k=h.value;return E(n,k.getAll(),8);case 8:return l=n.h,E(n,az(c,b,l),9);case 9:return m=n.h,E(n,k.remove(m),10);case 10:m.length!=l.length&&(e=!0);h=g.next();n.B(5);break;case 2:return xa(n),E(n,d.destroy(),11);case 11:ya(n,3);break;case 3:return n.return(!e)}})}
1199
+ q.list=function(){return Cz(this,Kz())};function Kz(){var a,b,c;return O(function(d){switch(d.g){case 1:return oz(),a=[],b=new wy,ua(d,2),E(d,b.init(),4);case 4:return c=Promise.resolve(),zy(b,function(e,f){c=c.then(function(){var g;return O(function(h){if(1==h.g)return E(h,f.getAllManifests(),2);g=h.h;g.forEach(function(k,l){k=fz(new Py("manifest",e.Eb,e.$a,l),k);a.push(k)});F(h)})})}),E(d,c,2);case 2:return xa(d),E(d,b.destroy(),6);case 6:ya(d,3);break;case 3:return d.return(a)}})}
1200
+ function pz(a,b,c,d){var e,f,g,h,k;return O(function(l){if(1==l.g)return e=null,f=a.g,g={networkingEngine:f,filter:function(){return Promise.resolve()},makeTextStreamsForClosedCaptions:function(){},onTimelineRegionAdded:function(){},onEvent:function(){},onError:function(m){e=m},isLowLatencyMode:function(){return!1},isAutoLowLatencyMode:function(){return!1},enableLowLatencyMode:function(){},updateDuration:function(){},newDrmInfo:function(){},onManifestUpdated:function(){},getBandwidthEstimate:function(){return d.abr.defaultBandwidthEstimate}},
1201
+ c.configure(d.manifest),qz(a),E(l,c.start(b,g),2);if(3!=l.g)return h=l.h,qz(a),k=Lz(h),E(l,Promise.all(hb(k,function(m){return m.createSegmentIndex()})),3);qz(a);if(e)throw e;return l.return(h)})}q.Wc=function(a,b,c){var d=this,e;return O(function(f){return 1==f.g?(e=new Jh({Zb:d.g,onError:b,bf:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),e.configure(c.drm),E(f,Oh(e,a.variants,c.offline.usePersistentLicense),2)):3!=f.g?E(f,ai(e),3):f.return(e)})};
1202
+ function Bz(a,b,c,d){var e=new Map,f=Lz(c),g=new Map;f=t(f);for(var h=f.next();!h.done;h=f.next()){h=h.value;var k=Mz(a,b,c,h,d,e);g.set(h.id,k)}a=t(c.variants);for(b=a.next();!b.done;b=a.next())b=b.value,b.audio&&g.get(b.audio.id).variantIds.push(b.id),b.video&&g.get(b.video.id).variantIds.push(b.id);return{streams:Array.from(g.values()),hh:Array.from(e.values())}}
1203
+ function Mz(a,b,c,d,e,f){var g={id:d.id,originalId:d.originalId,groupId:d.groupId,primary:d.primary,type:d.type,mimeType:d.mimeType,codecs:d.codecs,frameRate:d.frameRate,pixelAspectRatio:d.pixelAspectRatio,hdr:d.hdr,colorGamut:d.colorGamut,videoLayout:d.videoLayout,kind:d.kind,language:d.language,originalLanguage:d.originalLanguage,label:d.label,width:d.width||null,height:d.height||null,encrypted:d.encrypted,keyIds:d.keyIds,segments:[],variantIds:[],roles:d.roles,forced:d.forced,channelsCount:d.channelsCount,
1204
+ audioSamplingRate:d.audioSamplingRate,spatialAudio:d.spatialAudio,closedCaptions:d.closedCaptions,tilesLayout:d.tilesLayout,external:d.external,fastSwitching:d.fastSwitching},h=e.offline.numberOfParallelDownloads,k=0;Nz(d,c.presentationTimeline.Cb(),function(l){var m=by(l),n=void 0;if(!f.has(m)){var p=l.endTime-l.startTime;p=jz(b,d.id)*p;p=ey(a.g,p);f.set(m,new ay(l,p,k,!1))}l.sa&&(n=by(l.sa),f.has(n)||(p=.5*jz(b,d.id),p=ey(a.g,p),f.set(n,new ay(l.sa,p,k,!0))));g.segments.push({pendingInitSegmentRefId:n,
1205
+ initSegmentKey:n?0:null,startTime:l.startTime,endTime:l.endTime,appendWindowStart:l.appendWindowStart,appendWindowEnd:l.appendWindowEnd,timestampOffset:l.timestampOffset,tilesLayout:l.tilesLayout,pendingSegmentRefId:m,dataKey:0,mimeType:l.mimeType,codecs:l.codecs});k=(k+1)%h});return g}function Nz(a,b,c){b=a.segmentIndex.find(b);if(null!=b)for(var d=a.segmentIndex.get(b);d;)c(d),d=a.segmentIndex.get(++b)}function qz(a){if(a.l.g)throw new U(2,9,7001);}function oz(){if(!lz())throw new U(2,9,9E3);}
1206
+ function Cz(a,b){return O(function(c){if(1==c.g)return a.i.push(b),ua(c,2),E(c,b,4);if(2!=c.g)return c.return(c.h);xa(c);Od(a.i,b);return ya(c,0)})}function nz(a,b){var c=b.promise;a.i.push(c);return b.finally(function(){Od(a.i,c)})}function Iz(a){var b=new Set;a=t(a.streams);for(var c=a.next();!c.done;c=a.next()){c=t(c.value.segments);for(var d=c.next();!d.done;d=c.next())d=d.value,null!=d.initSegmentKey&&b.add(d.initSegmentKey),b.add(d.dataKey)}return Array.from(b)}
1207
+ function Hz(a,b,c,d){var e,f,g;return O(function(h){if(1==h.g){if(!d.drmInfo)return h.return();e=Cy(c);f=d.sessionIds.map(function(k){return{sessionId:k,keySystem:d.drmInfo.keySystem,licenseUri:d.drmInfo.licenseServerUri,serverCertificate:d.drmInfo.serverCertificate,audioCapabilities:Gz(d,!1),videoCapabilities:Gz(d,!0)}});return E(h,az(b,a,f),2)}return 3!=h.g?(g=h.h,E(h,e.remove(g),3)):E(h,e.add(f.filter(function(k){return!g.includes(k.sessionId)})),0)})}
1208
+ function Lz(a){for(var b=new Set,c=t(a.textStreams),d=c.next();!d.done;d=c.next())b.add(d.value);c=t(a.imageStreams);for(d=c.next();!d.done;d=c.next())b.add(d.value);a=t(a.variants);for(c=a.next();!c.done;c=a.next())c=c.value,c.audio&&b.add(c.audio),c.video&&b.add(c.video);return b}
1209
+ function zz(a){a.variants.map(function(f){return f.video});var b=new Set(a.variants.map(function(f){return f.audio}));a=a.textStreams;for(var c=t(b),d=c.next();!d.done;d=c.next()){d=t(b);for(var e=d.next();!e.done;e=d.next());}b=t(a);for(c=b.next();!c.done;c=b.next())for(c=t(a),d=c.next();!d.done;d=c.next());}P("shaka.offline.Storage",kz);kz.deleteAll=function(){var a;return O(function(b){return 1==b.g?(a=new wy,ua(b,2),E(b,Dy(a),2)):5!=b.g?(xa(b),E(b,a.destroy(),5)):ya(b,0)})};
1210
+ kz.prototype.list=kz.prototype.list;kz.prototype.removeEmeSessions=kz.prototype.fk;kz.prototype.remove=kz.prototype.remove;kz.prototype.store=kz.prototype.store;kz.prototype.getNetworkingEngine=kz.prototype.hc;kz.prototype.getConfiguration=kz.prototype.getConfiguration;kz.prototype.configure=kz.prototype.configure;kz.prototype.destroy=kz.prototype.destroy;kz.support=lz;
1211
+ var Az=(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");zp.offline=lz;function Oz(){}function Pz(){for(var a=t(Qz),b=a.next();!b.done;b=a.next()){b=b.value;try{b.callback()}catch(c){Ya("Error installing polyfill!",c)}}}function Rz(a,b){a={priority:b||0,callback:a};for(b=0;b<Qz.length;b++)if(Qz[b].priority<a.priority){Qz.splice(b,0,a);return}Qz.push(a)}P("shaka.polyfill",Oz);Oz.register=Rz;Oz.installAll=Pz;var Qz=[];function Sz(){this.g=new Tz}function Uz(){window.AbortController||(window.AbortController=Sz,window.AbortSignal=Tz)}Sz.prototype.abort=function(a){var b=this.g;if(!b.h){b.h=!0;b.g=a;void 0===b.g&&(b.g=new DOMException("signal is aborted without reason","AbortError"));a=new S("abort");if(b.onabort)b.onabort(a);b.dispatchEvent(a)}};da.Object.defineProperties(Sz.prototype,{signal:{configurable:!0,enumerable:!0,get:function(){return this.g}}});Oz.AbortController=Sz;Sz.install=Uz;
1212
+ function Tz(){gb.call(this);this.h=!1;this.g=void 0;this.onabort=null}na(Tz,gb);da.Object.defineProperties(Tz.prototype,{aborted:{configurable:!0,enumerable:!0,get:function(){return this.h}},reason:{configurable:!0,enumerable:!0,get:function(){return this.g}}});Rz(Uz);function Vz(){}function Wz(){if(!Object.getOwnPropertyDescriptor(Element.prototype,"ariaHidden"))for(var a=t(["ariaHidden","ariaLabel","ariaPressed","ariaSelected"]),b=a.next();!b.done;b=a.next())Xz(b.value)}function Xz(a){var b="aria-"+a.toLowerCase().replace(/^aria/,"");Object.defineProperty(Element.prototype,a,{get:function(){return this.getAttribute(b)},set:function(c){null==c||void 0==c?this.removeAttribute(b):this.setAttribute(b,c)}})}Oz.Aria=Vz;Vz.install=Wz;Rz(Wz);function Yz(){}function Zz(){$z()}Oz.EncryptionScheme=Yz;Yz.install=Zz;Rz(Zz,-2);function aA(){}
1213
+ function bA(){if(window.Document){var a=Element.prototype;a.requestFullscreen=a.requestFullscreen||a.mozRequestFullScreen||a.msRequestFullscreen||a.webkitRequestFullscreen;a=Document.prototype;a.exitFullscreen=a.exitFullscreen||a.mozCancelFullScreen||a.msExitFullscreen||a.webkitCancelFullScreen;"fullscreenElement"in document||(Object.defineProperty(document,"fullscreenElement",{get:function(){return document.mozFullScreenElement||document.msFullscreenElement||document.webkitCurrentFullScreenElement||document.webkitFullscreenElement}}),
1214
+ Object.defineProperty(document,"fullscreenEnabled",{get:function(){return document.mozFullScreenEnabled||document.msFullscreenEnabled||document.webkitFullscreenEnabled}}));document.addEventListener("webkitfullscreenchange",cA);document.addEventListener("webkitfullscreenerror",cA);document.addEventListener("mozfullscreenchange",cA);document.addEventListener("mozfullscreenerror",cA);document.addEventListener("MSFullscreenChange",cA);document.addEventListener("MSFullscreenError",cA)}}
1215
+ function cA(a){var b=a.type.replace(/^(webkit|moz|MS)/,"").toLowerCase(),c=document.createEvent("Event");c.initEvent(b,a.bubbles,a.cancelable);a.target.dispatchEvent(c)}Oz.Fullscreen=aA;aA.install=bA;Rz(bA);function dA(){}function eA(){var a=!0;!gc()||gc()&&oc()||gc()&&$b("Fuchsia")||(a=!1);if(hc()||kc()||jc()||dc()||ac()||$b("PC=EOS")||lc())a=!1;a&&navigator.mediaCapabilities||(navigator.mediaCapabilities||(navigator.mediaCapabilities={}),fA=navigator.mediaCapabilities,navigator.mediaCapabilities.decodingInfo=gA)}
1216
+ function gA(a){var b,c,d,e,f,g,h,k,l,m,n;return O(function(p){switch(p.g){case 1:b={supported:!1,powerEfficient:!0,smooth:!0,keySystemAccess:null,configuration:a};c=a.video;d=a.audio;if("media-source"!=a.type){if("file"==a.type){if(c&&(e=c.contentType,f=Wb(e),!f)||d&&(g=d.contentType,h=Wb(g),!h))return p.return(b)}else return p.return(b);p.B(2);break}if(!Vb())return p.return(b);if(!c){p.B(3);break}return E(p,hA(c),4);case 4:if(k=p.h,!k)return p.return(b);case 3:if(d){var r=d.contentType;gc()&&d.spatialRendering&&
1217
+ (r+="; spatialRendering=true");l=td(r);if(!l)return p.return(b)}case 2:if(!a.keySystemConfiguration)return b.supported=!0,p.return(b);m=a.keySystemConfiguration;return E(p,iA(c,d,m),6);case 6:if(n=p.h)b.supported=!0,b.keySystemAccess=n;case 5:return p.return(b)}})}
1218
+ function hA(a){var b,c;return O(function(d){return 1==d.g?gc()?E(d,jA(a),3):ac()?(b=a.contentType,a.width&&a.height&&(b+="; width="+a.width,b+="; height="+a.height),a.framerate&&(b+="; framerate="+a.framerate),a.bitrate&&(b+="; bitrate="+a.bitrate),d.return(td(b))):d.B(2):2!=d.g?(c=d.h,d.return(c)):d.return(td(a.contentType))})}
1219
+ function iA(a,b,c){var d,e,f,g,h,k,l,m,n;return O(function(p){switch(p.g){case 1:d=[];e=[];c.audio&&(f={robustness:c.audio.robustness||"",contentType:b.contentType},ac()&&b.contentType.includes('codecs="ac-3"')&&(f.contentType='audio/mp4; codecs="ec-3"'),c.audio.encryptionScheme&&(f.encryptionScheme=c.audio.encryptionScheme),d.push(f));c.video&&(g={robustness:c.video.robustness||"",contentType:a.contentType},c.video.encryptionScheme&&(g.encryptionScheme=c.video.encryptionScheme),e.push(g));h={initDataTypes:[c.initDataType],
1219
1220
  distinctiveIdentifier:c.distinctiveIdentifier,persistentState:c.persistentState,sessionTypes:c.sessionTypes};d.length&&(h.audioCapabilities=d);e.length&&(h.videoCapabilities=e);k=a?a.contentType:"";l=b?b.contentType:"";m=c.keySystem;n=null;ta(p,2);if(Sb.has(k+"#"+l+"#"+m)){n=Sb.get(k+"#"+l+"#"+m)||null;p.B(4);break}return E(p,navigator.requestMediaKeySystemAccess(c.keySystem,[h]),5);case 5:n=p.h,Sb.set(k+"#"+l+"#"+m,n);case 4:va(p,3);break;case 2:wa(p);case 3:return p.return(n)}})}
1220
- function iA(a){var b,c;return O(function(d){if(1==d.g){if(!(window.cast&&cast.__platform__&&cast.__platform__.canDisplayType))return d.return(td(a.contentType));b=a.contentType;a.width&&a.height&&(b+="; width="+a.width+"; height="+a.height);a.framerate&&(b+="; framerate="+a.framerate);"pq"===a.transferFunction&&(b+="; eotf=smpte2084");c=!1;return b in jA?(c=jA[b],d.B(2)):E(d,cast.__platform__.canDisplayType(b),3)}2!=d.g&&(c=d.h,jA[b]=c);return d.return(c)})}Nz.MediaCapabilities=cA;cA.install=dA;
1221
- var eA=null;cA.originalMcap=eA;var jA={};cA.memoizedCanDisplayTypeRequests_=jA;Qz(dA,-1);function kA(){}function lA(){var a=mc();if(window.MediaSource||window.ManagedMediaSource)a?10>=a?window.MediaSource=null:12>=a?(mA(),nA()):15>=a&&mA():$b("DT_STB_BCM")?(mA(),nA()):(cc()||bc()||$b("Tizen 4"))&&oA();(window.MediaSource||window.ManagedMediaSource)&&pA();window.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&qA()}
1222
- function mA(){var a=MediaSource.prototype.addSourceBuffer;MediaSource.prototype.addSourceBuffer=function(){var b=a.apply(this,Ka.apply(0,arguments));b.abort=function(){};return b}}function nA(){var a=SourceBuffer.prototype.remove;SourceBuffer.prototype.remove=function(b,c){return a.call(this,b,c-.001)}}
1223
- function pA(){var a=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(c){return"mp2t"!=Ee(c)&&a(c)};if(window.ManagedMediaSource){var b=ManagedMediaSource.isTypeSupported.bind(ManagedMediaSource);window.ManagedMediaSource.isTypeSupported=function(c){return"mp2t"!=Ee(c)&&b(c)}}}
1224
- function oA(){var a=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(c){return"opus"!=Ie(c)&&a(c)};if(window.ManagedMediaSource){var b=ManagedMediaSource.isTypeSupported.bind(ManagedMediaSource);window.ManagedMediaSource.isTypeSupported=function(c){return"opus"!=Ie(c)&&b(c)}}}
1225
- function qA(){var a=MediaSource.isTypeSupported;dc()||(MediaSource.isTypeSupported=function(b){var c=b.split(/ *; */),d=c.findIndex(function(g){return g.startsWith("codecs=")});if(0>d)return a(b);var e=c[d].replace("codecs=","").replace(/"/g,"").split(/\s*,\s*/),f=e.findIndex(function(g){return g.startsWith("vp09")});0<=f&&(e[f]="vp9",c[d]='codecs="'+e.join(",")+'"',b=c.join("; "));return a(b)})}Nz.MediaSource=kA;kA.install=lA;Qz(lA);function rA(){}function sA(){screen.orientation&&screen.orientation.unlock||(void 0!=screen.orientation?tA():void 0!=window.orientation&&uA())}function tA(){void 0===screen.orientation.lock&&(screen.orientation.lock=function(){return Promise.resolve()});void 0===screen.orientation.unlock&&(screen.orientation.unlock=function(){})}
1226
- function uA(){function a(){switch(window.orientation){case -90:b.type="landscape-secondary";b.angle=270;break;case 0:b.type="portrait-primary";b.angle=0;break;case 90:b.type="landscape-primary";b.angle=90;break;case 180:b.type="portrait-secondary",b.angle=180}}var b=new vA;screen.orientation=b;a();window.addEventListener("orientationchange",function(){a();var c=new S("change");b.dispatchEvent(c)})}Nz.Orientation=rA;rA.install=sA;function vA(){gb.call(this);this.type="";this.angle=0}na(vA,gb);
1227
- vA.prototype.lock=function(a){function b(d){return screen.lockOrientation?screen.lockOrientation(d):screen.mozLockOrientation?screen.mozLockOrientation(d):screen.msLockOrientation?screen.msLockOrientation(d):!1}var c=!1;switch(a){case "natural":c=b("default");break;case "any":c=!0;this.unlock();break;default:c=b(a)}if(c)return Promise.resolve();a=Error("screen.orientation.lock() is not available on this device");a.name="NotSupportedError";a.code=DOMException.NOT_SUPPORTED_ERR;return Promise.reject(a)};
1228
- vA.prototype.unlock=function(){screen.unlockOrientation?screen.unlockOrientation():screen.mozUnlockOrientation?screen.mozUnlockOrientation():screen.msUnlockOrientation&&screen.msUnlockOrientation()};Qz(sA);function wA(){}var xA,yA,zA,AA,BA,CA;function DA(a,b){try{var c=new EA(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}}function FA(a){var b=this.mediaKeys;b&&b!=a&&GA(b,null);delete this.mediaKeys;return(this.mediaKeys=a)?GA(a,this):Promise.resolve()}
1229
- function HA(a){a=Gb(a.initData);if(Lb(a).getUint32(0,!0)+4!=a.byteLength)throw new RangeError("Malformed FairPlay init data");a=xc(a.subarray(4),!0);a=Ac(a);var b=new Event("encrypted");b.initDataType="skd";b.initData=Ib(a);this.dispatchEvent(b)}Nz.PatchedMediaKeysApple=wA;
1230
- wA.uninstall=function(){xA&&(xA=!1,Object.defineProperty(HTMLMediaElement.prototype,"mediaKeys",yA),HTMLMediaElement.prototype.setMediaKeys=zA,window.MediaKeys=AA,window.MediaKeySystemAccess=BA,navigator.requestMediaKeySystemAccess=CA,yA=CA=zA=BA=AA=null,window.shakaMediaKeysPolyfill="")};
1231
- wA.install=function(a){if(window.HTMLVideoElement&&window.WebKitMediaKeys){if(void 0===a?0:a)xA=!0,yA=Object.getOwnPropertyDescriptor(HTMLMediaElement.prototype,"mediaKeys"),zA=HTMLMediaElement.prototype.setMediaKeys,AA=window.MediaKeys,BA=window.MediaKeySystemAccess,CA=navigator.requestMediaKeySystemAccess;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=FA;window.MediaKeys=IA;window.MediaKeySystemAccess=EA;navigator.requestMediaKeySystemAccess=
1232
- DA;window.shakaMediaKeysPolyfill=JA}};
1233
- function EA(a,b){this.keySystem=a;if(a.startsWith("com.apple.fps"))for(a=t(b),b=a.next();!b.done;b=a.next()){var c=b.value;if("required"==c.persistentState)b=null;else{b={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:c.initDataTypes,sessionTypes:["temporary"],label:c.label};var d=!1,e=!1;if(c.audioCapabilities)for(var f=t(c.audioCapabilities),g=f.next();!g.done;g=f.next())g=g.value,g.contentType&&(d=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,
1221
+ function jA(a){var b,c;return O(function(d){if(1==d.g){if(!(window.cast&&cast.__platform__&&cast.__platform__.canDisplayType))return d.return(td(a.contentType));b=a.contentType;a.width&&a.height&&(b+="; width="+a.width+"; height="+a.height);a.framerate&&(b+="; framerate="+a.framerate);"pq"===a.transferFunction&&(b+="; eotf=smpte2084");c=!1;return b in kA?(c=kA[b],d.B(2)):E(d,cast.__platform__.canDisplayType(b),3)}2!=d.g&&(c=d.h,kA[b]=c);return d.return(c)})}Oz.MediaCapabilities=dA;dA.install=eA;
1222
+ var fA=null;dA.originalMcap=fA;var kA={};dA.memoizedCanDisplayTypeRequests_=kA;Rz(eA,-1);function lA(){}function mA(){var a=mc();if(window.MediaSource||window.ManagedMediaSource)a?10>=a?window.MediaSource=null:12>=a?(nA(),oA()):15>=a&&nA():$b("DT_STB_BCM")?(nA(),oA()):(cc()||bc()||$b("Tizen 4"))&&pA();(window.MediaSource||window.ManagedMediaSource)&&qA();window.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&rA()}
1223
+ function nA(){var a=MediaSource.prototype.addSourceBuffer;MediaSource.prototype.addSourceBuffer=function(){var b=a.apply(this,Ka.apply(0,arguments));b.abort=function(){};return b}}function oA(){var a=SourceBuffer.prototype.remove;SourceBuffer.prototype.remove=function(b,c){return a.call(this,b,c-.001)}}
1224
+ function qA(){var a=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(c){return"mp2t"!=Ee(c)&&a(c)};if(window.ManagedMediaSource){var b=ManagedMediaSource.isTypeSupported.bind(ManagedMediaSource);window.ManagedMediaSource.isTypeSupported=function(c){return"mp2t"!=Ee(c)&&b(c)}}}
1225
+ function pA(){var a=MediaSource.isTypeSupported.bind(MediaSource);MediaSource.isTypeSupported=function(c){return"opus"!=Ie(c)&&a(c)};if(window.ManagedMediaSource){var b=ManagedMediaSource.isTypeSupported.bind(ManagedMediaSource);window.ManagedMediaSource.isTypeSupported=function(c){return"opus"!=Ie(c)&&b(c)}}}
1226
+ function rA(){var a=MediaSource.isTypeSupported;dc()||(MediaSource.isTypeSupported=function(b){var c=b.split(/ *; */),d=c.findIndex(function(g){return g.startsWith("codecs=")});if(0>d)return a(b);var e=c[d].replace("codecs=","").replace(/"/g,"").split(/\s*,\s*/),f=e.findIndex(function(g){return g.startsWith("vp09")});0<=f&&(e[f]="vp9",c[d]='codecs="'+e.join(",")+'"',b=c.join("; "));return a(b)})}Oz.MediaSource=lA;lA.install=mA;Rz(mA);function sA(){}function tA(){screen.orientation&&screen.orientation.unlock||(void 0!=screen.orientation?uA():void 0!=window.orientation&&vA())}function uA(){void 0===screen.orientation.lock&&(screen.orientation.lock=function(){return Promise.resolve()});void 0===screen.orientation.unlock&&(screen.orientation.unlock=function(){})}
1227
+ function vA(){function a(){switch(window.orientation){case -90:b.type="landscape-secondary";b.angle=270;break;case 0:b.type="portrait-primary";b.angle=0;break;case 90:b.type="landscape-primary";b.angle=90;break;case 180:b.type="portrait-secondary",b.angle=180}}var b=new wA;screen.orientation=b;a();window.addEventListener("orientationchange",function(){a();var c=new S("change");b.dispatchEvent(c)})}Oz.Orientation=sA;sA.install=tA;function wA(){gb.call(this);this.type="";this.angle=0}na(wA,gb);
1228
+ wA.prototype.lock=function(a){function b(d){return screen.lockOrientation?screen.lockOrientation(d):screen.mozLockOrientation?screen.mozLockOrientation(d):screen.msLockOrientation?screen.msLockOrientation(d):!1}var c=!1;switch(a){case "natural":c=b("default");break;case "any":c=!0;this.unlock();break;default:c=b(a)}if(c)return Promise.resolve();a=Error("screen.orientation.lock() is not available on this device");a.name="NotSupportedError";a.code=DOMException.NOT_SUPPORTED_ERR;return Promise.reject(a)};
1229
+ wA.prototype.unlock=function(){screen.unlockOrientation?screen.unlockOrientation():screen.mozUnlockOrientation?screen.mozUnlockOrientation():screen.msUnlockOrientation&&screen.msUnlockOrientation()};Rz(tA);function xA(){}var yA,zA,AA,BA,CA,DA;function EA(a,b){try{var c=new FA(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}}function GA(a){var b=this.mediaKeys;b&&b!=a&&HA(b,null);delete this.mediaKeys;return(this.mediaKeys=a)?HA(a,this):Promise.resolve()}
1230
+ function IA(a){a=Gb(a.initData);if(Lb(a).getUint32(0,!0)+4!=a.byteLength)throw new RangeError("Malformed FairPlay init data");a=xc(a.subarray(4),!0);a=Ac(a);var b=new Event("encrypted");b.initDataType="skd";b.initData=Ib(a);this.dispatchEvent(b)}Oz.PatchedMediaKeysApple=xA;
1231
+ xA.uninstall=function(){yA&&(yA=!1,Object.defineProperty(HTMLMediaElement.prototype,"mediaKeys",zA),HTMLMediaElement.prototype.setMediaKeys=AA,window.MediaKeys=BA,window.MediaKeySystemAccess=CA,navigator.requestMediaKeySystemAccess=DA,zA=DA=AA=CA=BA=null,window.shakaMediaKeysPolyfill="")};
1232
+ xA.install=function(a){if(window.HTMLVideoElement&&window.WebKitMediaKeys){if(void 0===a?0:a)yA=!0,zA=Object.getOwnPropertyDescriptor(HTMLMediaElement.prototype,"mediaKeys"),AA=HTMLMediaElement.prototype.setMediaKeys,BA=window.MediaKeys,CA=window.MediaKeySystemAccess,DA=navigator.requestMediaKeySystemAccess;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=GA;window.MediaKeys=JA;window.MediaKeySystemAccess=FA;navigator.requestMediaKeySystemAccess=
1233
+ EA;window.shakaMediaKeysPolyfill=KA}};
1234
+ function FA(a,b){this.keySystem=a;if(a.startsWith("com.apple.fps"))for(a=t(b),b=a.next();!b.done;b=a.next()){var c=b.value;if("required"==c.persistentState)b=null;else{b={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:c.initDataTypes,sessionTypes:["temporary"],label:c.label};var d=!1,e=!1;if(c.audioCapabilities)for(var f=t(c.audioCapabilities),g=f.next();!g.done;g=f.next())g=g.value,g.contentType&&(d=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,
1234
1235
  g.contentType.split(";")[0])&&(b.audioCapabilities.push(g),e=!0));if(c.videoCapabilities)for(c=t(c.videoCapabilities),g=c.next();!g.done;g=c.next())f=g.value,f.contentType&&(d=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,f.contentType.split(";")[0])&&(b.videoCapabilities.push(f),e=!0));d||(e=WebKitMediaKeys.isTypeSupported(this.keySystem,"video/mp4"));b=e?b:null}if(b){this.g=b;return}}a=Error("Unsupported keySystem");a.name="NotSupportedError";a.code=DOMException.NOT_SUPPORTED_ERR;throw a;}
1235
- EA.prototype.createMediaKeys=function(){var a=new IA(this.keySystem);return Promise.resolve(a)};EA.prototype.getConfiguration=function(){return this.g};function IA(a){this.h=new WebKitMediaKeys(a);this.g=new od}IA.prototype.createSession=function(a){a=a||"temporary";if("temporary"!=a)throw new TypeError("Session type "+a+" is unsupported on this platform.");return new KA(this.h,a)};IA.prototype.setServerCertificate=function(){return Promise.resolve(!1)};
1236
- function GA(a,b){a.g.qb();if(!b)return Promise.resolve();a.g.s(b,"webkitneedkey",HA);try{return Ik(b,HTMLMediaElement.HAVE_METADATA,a.g,function(){b.webkitSetMediaKeys(a.h)}),Promise.resolve()}catch(c){return Promise.reject(c)}}IA.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function KA(a){gb.call(this);this.i=null;this.l=a;this.g=this.h=null;this.j=new od;this.sessionId="";this.expiration=NaN;this.closed=new lg;this.keyStatuses=new LA}na(KA,gb);q=KA.prototype;
1237
- q.generateRequest=function(a,b){var c=this;this.h=new lg;try{var d=this.l.createSession("video/mp4",Gb(b));this.i=d;this.sessionId=d.sessionId||"";this.j.s(this.i,"webkitkeymessage",function(e){c.h&&(c.h.resolve(),c.h=null);e=(new Map).set("messageType",void 0==c.keyStatuses.zc()?"license-request":"license-renewal").set("message",Ib(e.message));e=new S("message",e);c.dispatchEvent(e)});this.j.s(d,"webkitkeyadded",function(){c.g&&(MA(c,"usable"),c.g.resolve(),c.g=null)});this.j.s(d,"webkitkeyerror",
1238
- function(){var e=Error("EME PatchedMediaKeysApple key error");e.errorCode=c.i.error;if(null!=c.h)c.h.reject(e),c.h=null;else if(null!=c.g)c.g.reject(e),c.g=null;else switch(c.i.error.code){case WebKitMediaKeyError.MEDIA_KEYERR_OUTPUT:case WebKitMediaKeyError.MEDIA_KEYERR_HARDWARECHANGE:MA(c,"output-not-allowed");break;default:MA(c,"internal-error")}});MA(this,"status-pending")}catch(e){this.h.reject(e)}return this.h};q.load=function(){return Promise.reject(Error("MediaKeySession.load not yet supported"))};
1239
- q.update=function(a){this.g=new lg;try{this.i.update(Gb(a))}catch(b){this.g.reject(b)}return this.g};q.close=function(){try{this.i.close(),this.closed.resolve(),this.j.qb()}catch(a){this.closed.reject(a)}return this.closed};q.remove=function(){return Promise.reject(Error("MediaKeySession.remove is only applicable for persistent licenses, which are not supported on this platform"))};function MA(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new S("keystatuseschange");a.dispatchEvent(b)}
1240
- function LA(){this.size=0;this.g=void 0}q=LA.prototype;q.zc=function(){return this.g};q.forEach=function(a){this.g&&a(this.g,Rb.value())};q.get=function(a){if(this.has(a))return this.g};q.has=function(a){var b=Rb.value();return this.g&&Eb(a,b)?!0:!1};q.entries=function(){};q.keys=function(){};q.values=function(){};var JA="apple";function NA(){}function OA(){window.MediaKeys&&(!MediaKeys.prototype.setServerCertificate||bc()||$b("Tizen 4")||$b("Tizen 5.0")||ec())&&(MediaKeys.prototype.setServerCertificate=PA)}function PA(){return Promise.resolve(!1)}Nz.PatchedMediaKeysCert=NA;NA.install=OA;Qz(OA);function QA(){}function RA(){!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=SA,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=TA,window.MediaKeys=UA,window.MediaKeySystemAccess=VA,window.shakaMediaKeysPolyfill=WA)}function SA(){return Promise.reject(Error("The key system specified is not supported."))}
1241
- function TA(a){return null==a?Promise.resolve():Promise.reject(Error("MediaKeys not supported."))}Nz.PatchedMediaKeysNop=QA;QA.install=RA;function UA(){throw new TypeError("Illegal constructor.");}UA.prototype.createSession=function(){};UA.prototype.setServerCertificate=function(){};UA.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function VA(){this.keySystem="";throw new TypeError("Illegal constructor.");}VA.prototype.getConfiguration=function(){};
1242
- VA.prototype.createMediaKeys=function(){};var WA="nop";Qz(RA,-10);function XA(){}
1243
- function YA(){if(!(!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration)){if(HTMLMediaElement.prototype.webkitGenerateKeyRequest)ZA="webkit";else if(!HTMLMediaElement.prototype.generateKeyRequest)return;navigator.requestMediaKeySystemAccess=$A;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=aB;window.MediaKeys=bB;window.MediaKeySystemAccess=cB;window.shakaMediaKeysPolyfill=dB}}
1244
- function eB(a){var b=ZA;return b?b+a.charAt(0).toUpperCase()+a.slice(1):a}function $A(a,b){try{var c=new cB(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}}function aB(a){var b=this.mediaKeys;b&&b!=a&&fB(b,null);delete this.mediaKeys;(this.mediaKeys=a)&&fB(a,this);return Promise.resolve()}Nz.PatchedMediaKeysWebkit=XA;XA.install=YA;
1245
- function cB(a,b){this.g=this.keySystem=a;var c=!1;"org.w3.clearkey"==a&&(this.g="webkit-org.w3.clearkey",c=!1);var d=!1;var e=document.getElementsByTagName("video");e=e.length?e[0]:document.createElement("video");b=t(b);for(var f=b.next();!f.done;f=b.next()){f=f.value;var g={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:f.initDataTypes,sessionTypes:["temporary"],label:f.label},h=!1;if(f.audioCapabilities)for(var k=t(f.audioCapabilities),
1236
+ FA.prototype.createMediaKeys=function(){var a=new JA(this.keySystem);return Promise.resolve(a)};FA.prototype.getConfiguration=function(){return this.g};function JA(a){this.h=new WebKitMediaKeys(a);this.g=new od}JA.prototype.createSession=function(a){a=a||"temporary";if("temporary"!=a)throw new TypeError("Session type "+a+" is unsupported on this platform.");return new LA(this.h,a)};JA.prototype.setServerCertificate=function(){return Promise.resolve(!1)};
1237
+ function HA(a,b){a.g.qb();if(!b)return Promise.resolve();a.g.s(b,"webkitneedkey",IA);try{return Ik(b,HTMLMediaElement.HAVE_METADATA,a.g,function(){b.webkitSetMediaKeys(a.h)}),Promise.resolve()}catch(c){return Promise.reject(c)}}JA.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function LA(a){gb.call(this);this.i=null;this.l=a;this.g=this.h=null;this.j=new od;this.sessionId="";this.expiration=NaN;this.closed=new lg;this.keyStatuses=new MA}na(LA,gb);q=LA.prototype;
1238
+ q.generateRequest=function(a,b){var c=this;this.h=new lg;try{var d=this.l.createSession("video/mp4",Gb(b));this.i=d;this.sessionId=d.sessionId||"";this.j.s(this.i,"webkitkeymessage",function(e){c.h&&(c.h.resolve(),c.h=null);e=(new Map).set("messageType",void 0==c.keyStatuses.Ac()?"license-request":"license-renewal").set("message",Ib(e.message));e=new S("message",e);c.dispatchEvent(e)});this.j.s(d,"webkitkeyadded",function(){c.g&&(NA(c,"usable"),c.g.resolve(),c.g=null)});this.j.s(d,"webkitkeyerror",
1239
+ function(){var e=Error("EME PatchedMediaKeysApple key error");e.errorCode=c.i.error;if(null!=c.h)c.h.reject(e),c.h=null;else if(null!=c.g)c.g.reject(e),c.g=null;else switch(c.i.error.code){case WebKitMediaKeyError.MEDIA_KEYERR_OUTPUT:case WebKitMediaKeyError.MEDIA_KEYERR_HARDWARECHANGE:NA(c,"output-not-allowed");break;default:NA(c,"internal-error")}});NA(this,"status-pending")}catch(e){this.h.reject(e)}return this.h};q.load=function(){return Promise.reject(Error("MediaKeySession.load not yet supported"))};
1240
+ q.update=function(a){this.g=new lg;try{this.i.update(Gb(a))}catch(b){this.g.reject(b)}return this.g};q.close=function(){try{this.i.close(),this.closed.resolve(),this.j.qb()}catch(a){this.closed.reject(a)}return this.closed};q.remove=function(){return Promise.reject(Error("MediaKeySession.remove is only applicable for persistent licenses, which are not supported on this platform"))};function NA(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new S("keystatuseschange");a.dispatchEvent(b)}
1241
+ function MA(){this.size=0;this.g=void 0}q=MA.prototype;q.Ac=function(){return this.g};q.forEach=function(a){this.g&&a(this.g,Rb.value())};q.get=function(a){if(this.has(a))return this.g};q.has=function(a){var b=Rb.value();return this.g&&Eb(a,b)?!0:!1};q.entries=function(){};q.keys=function(){};q.values=function(){};var KA="apple";function OA(){}function PA(){window.MediaKeys&&(!MediaKeys.prototype.setServerCertificate||bc()||$b("Tizen 4")||$b("Tizen 5.0")||ec())&&(MediaKeys.prototype.setServerCertificate=QA)}function QA(){return Promise.resolve(!1)}Oz.PatchedMediaKeysCert=OA;OA.install=PA;Rz(PA);function RA(){}function SA(){!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=TA,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=UA,window.MediaKeys=VA,window.MediaKeySystemAccess=WA,window.shakaMediaKeysPolyfill=XA)}function TA(){return Promise.reject(Error("The key system specified is not supported."))}
1242
+ function UA(a){return null==a?Promise.resolve():Promise.reject(Error("MediaKeys not supported."))}Oz.PatchedMediaKeysNop=RA;RA.install=SA;function VA(){throw new TypeError("Illegal constructor.");}VA.prototype.createSession=function(){};VA.prototype.setServerCertificate=function(){};VA.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function WA(){this.keySystem="";throw new TypeError("Illegal constructor.");}WA.prototype.getConfiguration=function(){};
1243
+ WA.prototype.createMediaKeys=function(){};var XA="nop";Rz(SA,-10);function YA(){}
1244
+ function ZA(){if(!(!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration)){if(HTMLMediaElement.prototype.webkitGenerateKeyRequest)$A="webkit";else if(!HTMLMediaElement.prototype.generateKeyRequest)return;navigator.requestMediaKeySystemAccess=aB;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=bB;window.MediaKeys=cB;window.MediaKeySystemAccess=dB;window.shakaMediaKeysPolyfill=eB}}
1245
+ function fB(a){var b=$A;return b?b+a.charAt(0).toUpperCase()+a.slice(1):a}function aB(a,b){try{var c=new dB(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}}function bB(a){var b=this.mediaKeys;b&&b!=a&&gB(b,null);delete this.mediaKeys;(this.mediaKeys=a)&&gB(a,this);return Promise.resolve()}Oz.PatchedMediaKeysWebkit=YA;YA.install=ZA;
1246
+ function dB(a,b){this.g=this.keySystem=a;var c=!1;"org.w3.clearkey"==a&&(this.g="webkit-org.w3.clearkey",c=!1);var d=!1;var e=document.getElementsByTagName("video");e=e.length?e[0]:document.createElement("video");b=t(b);for(var f=b.next();!f.done;f=b.next()){f=f.value;var g={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:f.initDataTypes,sessionTypes:["temporary"],label:f.label},h=!1;if(f.audioCapabilities)for(var k=t(f.audioCapabilities),
1246
1247
  l=k.next();!l.done;l=k.next())l=l.value,l.contentType&&(h=!0,e.canPlayType(l.contentType.split(";")[0],this.g)&&(g.audioCapabilities.push(l),d=!0));if(f.videoCapabilities)for(k=t(f.videoCapabilities),l=k.next();!l.done;l=k.next())l=l.value,l.contentType&&(h=!0,e.canPlayType(l.contentType,this.g)&&(g.videoCapabilities.push(l),d=!0));h||(d=e.canPlayType("video/mp4",this.g)||e.canPlayType("video/webm",this.g));"required"==f.persistentState&&(c?(g.persistentState="required",g.sessionTypes=["persistent-license"]):
1247
- d=!1);if(d){this.h=g;return}}c="Unsupported keySystem";if("org.w3.clearkey"==a||"com.widevine.alpha"==a)c="None of the requested configurations were supported.";a=Error(c);a.name="NotSupportedError";a.code=DOMException.NOT_SUPPORTED_ERR;throw a;}cB.prototype.createMediaKeys=function(){var a=new bB(this.g);return Promise.resolve(a)};cB.prototype.getConfiguration=function(){return this.h};function bB(a){this.l=a;this.h=null;this.g=new od;this.i=[];this.j=new Map}
1248
- function fB(a,b){a.h=b;a.g.qb();var c=ZA;b&&(a.g.s(b,c+"needkey",function(d){var e=new CustomEvent("encrypted");e.initDataType="cenc";e.initData=Ib(d.initData);a.h.dispatchEvent(e)}),a.g.s(b,c+"keymessage",function(d){var e=gB(a,d.sessionId);e&&(d=(new Map).set("messageType",void 0==e.keyStatuses.zc()?"licenserequest":"licenserenewal").set("message",d.message),d=new S("message",d),e.h&&(e.h.resolve(),e.h=null),e.dispatchEvent(d))}),a.g.s(b,c+"keyadded",function(d){if(d=gB(a,d.sessionId))hB(d,"usable"),
1249
- d.g&&d.g.resolve(),d.g=null}),a.g.s(b,c+"keyerror",function(d){var e=gB(a,d.sessionId);if(e){var f=Error("EME v0.1b key error"),g=d.errorCode;g.systemCode=d.systemCode;f.errorCode=g;!d.sessionId&&e.h?(45==d.systemCode&&(f.message="Unsupported session type."),e.h.reject(f),e.h=null):d.sessionId&&e.g?(e.g.reject(f),e.g=null):(f=d.systemCode,d.errorCode.code==MediaKeyError.MEDIA_KEYERR_OUTPUT?hB(e,"output-restricted"):1==f?hB(e,"expired"):hB(e,"internal-error"))}}))}
1250
- bB.prototype.createSession=function(a){a=a||"temporary";if("temporary"!=a&&"persistent-license"!=a)throw new TypeError("Session type "+a+" is unsupported on this platform.");var b=this.h||document.createElement("video");b.src||(b.src="about:blank");a=new iB(b,this.l,a);this.i.push(a);return a};bB.prototype.setServerCertificate=function(){return Promise.resolve(!1)};bB.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};
1251
- function gB(a,b){var c=a.j.get(b);return c?c:(c=a.i.shift())?(c.sessionId=b,a.j.set(b,c),c):null}function iB(a,b,c){gb.call(this);this.j=a;this.m=!1;this.g=this.h=null;this.i=b;this.l=c;this.sessionId="";this.expiration=NaN;this.closed=new lg;this.keyStatuses=new jB}na(iB,gb);
1252
- function kB(a,b,c){if(a.m)return Promise.reject(Error("The session is already initialized."));a.m=!0;try{if("persistent-license"==a.l)if(c)var d=Gb(Ac("LOAD_SESSION|"+c));else{var e=Ac("PERSISTENT|");d=Kc(e,b)}else d=Gb(b)}catch(g){return Promise.reject(g)}a.h=new lg;var f=eB("generateKeyRequest");try{a.j[f](a.i,d)}catch(g){if("InvalidStateError"!=g.name)return a.h=null,Promise.reject(g);(new Ub(function(){try{a.j[f](a.i,d)}catch(h){a.h.reject(h),a.h=null}})).V(.01)}return a.h}
1253
- function lB(a,b,c){if(a.g)a.g.then(function(){return lB(a,b,c)}).catch(function(){return lB(a,b,c)});else{a.g=b;if("webkit-org.w3.clearkey"==a.i){var d=wc(c);var e=JSON.parse(d);"oct"!=e.keys[0].kty&&(a.g.reject(Error("Response is not a valid JSON Web Key Set.")),a.g=null);d=Hc(e.keys[0].k);e=Hc(e.keys[0].kid)}else d=Gb(c),e=null;var f=eB("addKey");try{a.j[f](a.i,d,e,a.sessionId)}catch(g){a.g.reject(g),a.g=null}}}
1254
- function hB(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new S("keystatuseschange");a.dispatchEvent(b)}q=iB.prototype;q.generateRequest=function(a,b){return kB(this,b,null)};q.load=function(a){return"persistent-license"==this.l?kB(this,null,a):Promise.reject(Error("Not a persistent session."))};q.update=function(a){var b=new lg;lB(this,b,a);return b};
1255
- q.close=function(){if("persistent-license"!=this.l){if(!this.sessionId)return this.closed.reject(Error("The session is not callable.")),this.closed;var a=eB("cancelKeyRequest");try{this.j[a](this.i,this.sessionId)}catch(b){}}this.closed.resolve();return this.closed};q.remove=function(){return"persistent-license"!=this.l?Promise.reject(Error("Not a persistent session.")):this.close()};function jB(){this.size=0;this.g=void 0}q=jB.prototype;q.zc=function(){return this.g};
1256
- q.forEach=function(a){this.g&&a(this.g,Rb.value())};q.get=function(a){if(this.has(a))return this.g};q.has=function(a){var b=Rb.value();return this.g&&Eb(a,b)?!0:!1};q.entries=function(){};q.keys=function(){};q.values=function(){};var ZA="",dB="webkit";Qz(YA);function mB(){}function nB(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;a.requestPictureInPicture&&document.exitPictureInPicture||!a.webkitSupportsPresentationMode||(document.pictureInPictureEnabled=!0,document.pictureInPictureElement=null,a.requestPictureInPicture=oB,Object.defineProperty(a,"disablePictureInPicture",{get:pB,set:qB,enumerable:!0,configurable:!0}),document.exitPictureInPicture=rB,document.addEventListener("webkitpresentationmodechanged",sB,!0))}}
1257
- function sB(a){a=a.target;if("picture-in-picture"==a.webkitPresentationMode){document.pictureInPictureElement=a;var b=new Event("enterpictureinpicture");a.dispatchEvent(b)}else document.pictureInPictureElement==a&&(document.pictureInPictureElement=null),b=new Event("leavepictureinpicture"),a.dispatchEvent(b)}
1258
- function oB(){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 rB(){var a=document.pictureInPictureElement;return a?(a.webkitSetPresentationMode("inline"),document.pictureInPictureElement=null,Promise.resolve()):Promise.reject(Error("No picture in picture element found"))}
1259
- function pB(){return this.hasAttribute("disablePictureInPicture")?!0:!this.webkitSupportsPresentationMode("picture-in-picture")}function qB(a){a?this.setAttribute("disablePictureInPicture",""):this.removeAttribute("disablePictureInPicture")}Nz.PiPWebkit=mB;mB.install=nB;Qz(nB);function tB(){}function uB(){window.crypto&&("randomUUID"in window.crypto||(window.crypto.randomUUID=vB))}function vB(){var a=URL.createObjectURL(new Blob),b=a.toString();URL.revokeObjectURL(a);return b.substr(b.lastIndexOf("/")+1)}Nz.RandomUUID=tB;tB.install=uB;Qz(uB);function wB(){}function xB(){var a=Symbol.prototype;"description"in a||Object.defineProperty(a,"description",{get:yB})}function yB(){var a=/\((.*)\)/.exec(this.toString());return a?a[1]:void 0}Nz.Symbol=wB;wB.install=xB;Qz(xB);function zB(){}function AB(){if(window.HTMLMediaElement){var a=HTMLMediaElement.prototype.play;HTMLMediaElement.prototype.play=function(){var b=a.apply(this);b&&b.catch(function(){});return b}}}Nz.VideoPlayPromise=zB;zB.install=AB;Qz(AB);function BB(){}function CB(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;!a.getVideoPlaybackQuality&&("webkitDroppedFrameCount"in a||ec())&&(a.getVideoPlaybackQuality=DB)}}function DB(){return{droppedVideoFrames:this.webkitDroppedFrameCount,totalVideoFrames:this.webkitDecodedFrameCount,corruptedVideoFrames:0,creationTime:NaN,totalFrameDelay:0}}Nz.VideoPlaybackQuality=BB;BB.install=CB;Qz(CB);function EB(){}function FB(){if(!window.VTTCue&&window.TextTrackCue){var a=null,b=TextTrackCue.length;if(3==b)a=GB;else if(6==b)a=HB;else{try{var c=!!GB(1,2,"")}catch(d){c=!1}c&&(a=GB)}a&&(window.VTTCue=function(d,e,f){return a(d,e,f)})}}function GB(a,b,c){return new window.TextTrackCue(a,b,c)}function HB(a,b,c){return new window.TextTrackCue(a+"-"+b+"-"+c,a,b,c)}Nz.VTTCue=EB;EB.install=FB;Qz(FB);function IB(){}IB.prototype.parseInit=function(){};IB.prototype.setSequenceMode=function(){};IB.prototype.setManifestType=function(){};IB.prototype.parseMedia=function(a,b){var c=null,d=[];a=wc(a).split(/\r?\n/);a=t(a);for(var e=a.next();!e.done;e=a.next())if((e=e.value)&&!/^\s+$/.test(e)&&(e=JB.exec(e))){var f=KB.exec(e[1]);f=60*parseInt(f[1],10)+parseFloat(f[2].replace(",","."));e=new Rd(f,b.segmentEnd?b.segmentEnd:f+2,e[2]);c&&(c.endTime=f,d.push(c));c=e}c&&d.push(c);return d};
1260
- P("shaka.text.LrcTextParser",IB);IB.prototype.parseMedia=IB.prototype.parseMedia;IB.prototype.setManifestType=IB.prototype.setManifestType;IB.prototype.setSequenceMode=IB.prototype.setSequenceMode;IB.prototype.parseInit=IB.prototype.parseInit;var JB=/^\[(\d{1,2}:\d{1,2}(?:[.,]\d{1,3})?)\](.*)/,KB=/^(\d+):(\d{1,2}(?:[.,]\d{1,3})?)$/;Oe["application/x-subtitle-lrc"]=function(){return new IB};function LB(){}LB.prototype.parseInit=function(){};LB.prototype.setSequenceMode=function(){};LB.prototype.setManifestType=function(){};
1261
- LB.prototype.parseMedia=function(a,b,c){var d=wc(a);a=[];if(""==d)return a;var e=ch(d,"tt");if(!e)throw new U(2,2,2005,"Failed to parse TTML.");d=nh(e,"body")[0];if(!d)return[];var f=vh(e,MB,"frameRate"),g=vh(e,MB,"subFrameRate"),h=vh(e,MB,"frameRateMultiplier"),k=vh(e,MB,"tickRate"),l=vh(e,MB,"cellResolution"),m=e.attributes["xml:space"]||"default",n=vh(e,NB,"extent");if("default"!=m&&"preserve"!=m)throw new U(2,2,2005,"Invalid xml:space value: "+m);m="default"==m;f=new OB(f,g,h,k);l=l?(l=/^(\d+) (\d+)$/.exec(l))?
1262
- {uc:parseInt(l[1],10),rows:parseInt(l[2],10)}:null:null;g=(g=nh(e,"metadata")[0])?g.children:[];h=nh(e,"style");e=nh(e,"region");k=[];for(var p=t(e),r=p.next();!r.done;r=p.next()){var u=r.value;r=new Kd;var v=u.attributes["xml:id"];if(v){r.id=v;var w=null;n&&(w=PB.exec(n)||QB.exec(n));v=w?Number(w[1]):null;w=w?Number(w[2]):null;var A,z=RB(u,h,"extent");if(z){var C=(A=PB.exec(z))||QB.exec(z);null!=C&&(r.width=Number(C[1]),r.height=Number(C[2]),A||(null!=v&&(r.width=100*r.width/v),null!=w&&(r.height=
1263
- 100*r.height/w)),r.widthUnits=A||null!=v?Ld:0,r.heightUnits=A||null!=w?Ld:0)}if(u=RB(u,h,"origin"))if(C=(A=PB.exec(u))||QB.exec(u),null!=C)r.viewportAnchorX=Number(C[1]),r.viewportAnchorY=Number(C[2]),A?z||(r.width=100-r.viewportAnchorX,r.widthUnits=Ld,r.height=100-r.viewportAnchorY,r.heightUnits=Ld):(null!=w&&(r.viewportAnchorY=100*r.viewportAnchorY/w),null!=v&&(r.viewportAnchorX=100*r.viewportAnchorX/v)),r.viewportAnchorUnits=A||null!=v?Ld:0}else r=null;r&&k.push(r)}if(kh(d,"p").length)throw new U(2,
1264
- 2,2001,"<p> can only be inside <div> in TTML");n=t(kh(d,"div"));for(p=n.next();!p.done;p=n.next())if(kh(p.value,"span").length)throw new U(2,2,2001,"<span> can only be inside <p> in TTML");if(b=SB(d,b,f,g,h,e,k,m,l,null,!1,c))b.backgroundColor||(b.backgroundColor="transparent"),a.push(b);return a};
1265
- function SB(a,b,c,d,e,f,g,h,k,l,m,n){var p=l;if(ih(a)){if(!m)return null;var r={tagName:"span",children:[lh(a)],attributes:{},parent:null}}else r=a;for(var u=null,v=t(TB),w=v.next();!w.done&&!(u=UB(r,"backgroundImage",d,"#",w.value)[0]);w=v.next());v=null;var A=vh(r,TB,"backgroundImage");n&&A&&!A.startsWith("#")&&(w=new mb(n),A=new mb(A),(w=w.resolve(A).toString())&&(v=w));if("p"==a.tagName||u||v)m=!0;a=m;w="default"==(r.attributes["xml:space"]||(h?"default":"preserve"));A=r.children.every(ih);h=
1266
- [];if(!A)for(var z=t(r.children),C=z.next();!C.done;C=z.next())(C=SB(C.value,b,c,d,e,f,g,w,k,r,m,n))&&h.push(C);d=null!=l;n=lh(r);n=r.children.length&&n&&/\S/.test(n);C=r.attributes.begin||r.attributes.end||r.attributes.dur;if(!(C||n||"br"==r.tagName||0!=h.length||d&&!w))return null;z=VB(r,c);n=z.start;for(z=z.end;p&&p.tagName&&"tt"!=p.tagName;)z=WB(p,c,n,z),n=z.start,z=z.end,p=p.parent;null==n&&(n=0);n+=b.periodStart;z=null==z?Infinity:z+b.periodStart;n=Math.max(n,b.segmentStart);z=Math.min(z,b.segmentEnd);
1267
- if(!C&&0<h.length)for(n=Infinity,z=0,b=t(h),c=b.next();!c.done;c=b.next())c=c.value,n=Math.min(n,c.startTime),z=Math.max(z,c.endTime);if("br"==r.tagName)return e=new Rd(n,z,""),e.lineBreak=!0,e;b="";A&&(b=Dc(lh(r)||""),w&&(b=b.replace(/\s+/g," ")));b=new Rd(n,z,b);b.nestedCues=h;m||(b.isContainer=!0);k&&(b.cellResolution=k);k=UB(r,"region",f,"")[0];if(r.attributes.region&&k&&k.attributes["xml:id"]){var y=k.attributes["xml:id"];b.region=g.filter(function(B){return B.id==y})[0]}g=k;l&&d&&!r.attributes.region&&
1268
- !r.attributes.style&&(g=UB(l,"region",f,"")[0]);XB(b,r,g,u,v,e,a,0==h.length);return b}
1269
- function XB(a,b,c,d,e,f,g,h){g=g||h;"rtl"==YB(b,c,f,"direction",g)&&(a.direction="rtl");h=YB(b,c,f,"writingMode",g);"tb"==h||"tblr"==h?a.writingMode="vertical-lr":"tbrl"==h?a.writingMode="vertical-rl":"rltb"==h||"rl"==h?a.direction="rtl":h&&(a.direction=Ud);(h=YB(b,c,f,"textAlign",!0))?(a.positionAlign=ZB[h],a.lineAlign=$B[h],a.textAlign=ee[h.toUpperCase()]):a.textAlign=Td;if(h=YB(b,c,f,"displayAlign",!0))a.displayAlign=fe[h.toUpperCase()];if(h=YB(b,c,f,"color",g))a.color=h;if(h=YB(b,c,f,"backgroundColor",
1270
- g))a.backgroundColor=h;if(h=YB(b,c,f,"border",g))a.border=h;if(h=YB(b,c,f,"fontFamily",g))switch(h){case "monospaceSerif":a.fontFamily="Courier New,Liberation Mono,Courier,monospace";break;case "proportionalSansSerif":a.fontFamily="Arial,Helvetica,Liberation Sans,sans-serif";break;case "sansSerif":a.fontFamily="sans-serif";break;case "monospaceSansSerif":a.fontFamily="Consolas,monospace";break;case "proportionalSerif":a.fontFamily="serif";break;default:a.fontFamily=h.split(",").filter(function(k){return"default"!=
1271
- k}).join(",")}(h=YB(b,c,f,"fontWeight",g))&&"bold"==h&&(a.fontWeight=700);h=YB(b,c,f,"wrapOption",g);a.wrapLine=h&&"noWrap"==h?!1:!0;(h=YB(b,c,f,"lineHeight",g))&&h.match(aC)&&(a.lineHeight=h);(h=YB(b,c,f,"fontSize",g))&&(h.match(aC)||h.match(bC))&&(a.fontSize=h);if(h=YB(b,c,f,"fontStyle",g))a.fontStyle=je[h.toUpperCase()];d?(e=d.attributes.imageType||d.attributes.imagetype,h=d.attributes.encoding,d=lh(d).trim(),"PNG"==e&&"Base64"==h&&d&&(a.backgroundImage="data:image/png;base64,"+d)):e&&(a.backgroundImage=
1272
- e);if(d=YB(b,c,f,"textOutline",g))d=d.split(" "),d[0].match(aC)?a.textStrokeColor=a.color:(a.textStrokeColor=d[0],d.shift()),d[0]&&d[0].match(aC)?a.textStrokeWidth=d[0]:a.textStrokeColor="";(d=YB(b,c,f,"letterSpacing",g))&&d.match(aC)&&(a.letterSpacing=d);(d=YB(b,c,f,"linePadding",g))&&d.match(aC)&&(a.linePadding=d);if(d=YB(b,c,f,"opacity",g))a.opacity=parseFloat(d);(d=RB(c,f,"textDecoration"))&&cC(a,d);(d=dC(b,f,"textDecoration"))&&cC(a,d);if(d=YB(b,c,f,"textCombine",g))a.textCombineUpright=d;switch(YB(b,
1248
+ d=!1);if(d){this.h=g;return}}c="Unsupported keySystem";if("org.w3.clearkey"==a||"com.widevine.alpha"==a)c="None of the requested configurations were supported.";a=Error(c);a.name="NotSupportedError";a.code=DOMException.NOT_SUPPORTED_ERR;throw a;}dB.prototype.createMediaKeys=function(){var a=new cB(this.g);return Promise.resolve(a)};dB.prototype.getConfiguration=function(){return this.h};function cB(a){this.l=a;this.h=null;this.g=new od;this.i=[];this.j=new Map}
1249
+ function gB(a,b){a.h=b;a.g.qb();var c=$A;b&&(a.g.s(b,c+"needkey",function(d){var e=new CustomEvent("encrypted");e.initDataType="cenc";e.initData=Ib(d.initData);a.h.dispatchEvent(e)}),a.g.s(b,c+"keymessage",function(d){var e=hB(a,d.sessionId);e&&(d=(new Map).set("messageType",void 0==e.keyStatuses.Ac()?"licenserequest":"licenserenewal").set("message",d.message),d=new S("message",d),e.h&&(e.h.resolve(),e.h=null),e.dispatchEvent(d))}),a.g.s(b,c+"keyadded",function(d){if(d=hB(a,d.sessionId))iB(d,"usable"),
1250
+ d.g&&d.g.resolve(),d.g=null}),a.g.s(b,c+"keyerror",function(d){var e=hB(a,d.sessionId);if(e){var f=Error("EME v0.1b key error"),g=d.errorCode;g.systemCode=d.systemCode;f.errorCode=g;!d.sessionId&&e.h?(45==d.systemCode&&(f.message="Unsupported session type."),e.h.reject(f),e.h=null):d.sessionId&&e.g?(e.g.reject(f),e.g=null):(f=d.systemCode,d.errorCode.code==MediaKeyError.MEDIA_KEYERR_OUTPUT?iB(e,"output-restricted"):1==f?iB(e,"expired"):iB(e,"internal-error"))}}))}
1251
+ cB.prototype.createSession=function(a){a=a||"temporary";if("temporary"!=a&&"persistent-license"!=a)throw new TypeError("Session type "+a+" is unsupported on this platform.");var b=this.h||document.createElement("video");b.src||(b.src="about:blank");a=new jB(b,this.l,a);this.i.push(a);return a};cB.prototype.setServerCertificate=function(){return Promise.resolve(!1)};cB.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};
1252
+ function hB(a,b){var c=a.j.get(b);return c?c:(c=a.i.shift())?(c.sessionId=b,a.j.set(b,c),c):null}function jB(a,b,c){gb.call(this);this.j=a;this.m=!1;this.g=this.h=null;this.i=b;this.l=c;this.sessionId="";this.expiration=NaN;this.closed=new lg;this.keyStatuses=new kB}na(jB,gb);
1253
+ function lB(a,b,c){if(a.m)return Promise.reject(Error("The session is already initialized."));a.m=!0;try{if("persistent-license"==a.l)if(c)var d=Gb(Ac("LOAD_SESSION|"+c));else{var e=Ac("PERSISTENT|");d=Kc(e,b)}else d=Gb(b)}catch(g){return Promise.reject(g)}a.h=new lg;var f=fB("generateKeyRequest");try{a.j[f](a.i,d)}catch(g){if("InvalidStateError"!=g.name)return a.h=null,Promise.reject(g);(new Ub(function(){try{a.j[f](a.i,d)}catch(h){a.h.reject(h),a.h=null}})).V(.01)}return a.h}
1254
+ function mB(a,b,c){if(a.g)a.g.then(function(){return mB(a,b,c)}).catch(function(){return mB(a,b,c)});else{a.g=b;if("webkit-org.w3.clearkey"==a.i){var d=wc(c);var e=JSON.parse(d);"oct"!=e.keys[0].kty&&(a.g.reject(Error("Response is not a valid JSON Web Key Set.")),a.g=null);d=Hc(e.keys[0].k);e=Hc(e.keys[0].kid)}else d=Gb(c),e=null;var f=fB("addKey");try{a.j[f](a.i,d,e,a.sessionId)}catch(g){a.g.reject(g),a.g=null}}}
1255
+ function iB(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new S("keystatuseschange");a.dispatchEvent(b)}q=jB.prototype;q.generateRequest=function(a,b){return lB(this,b,null)};q.load=function(a){return"persistent-license"==this.l?lB(this,null,a):Promise.reject(Error("Not a persistent session."))};q.update=function(a){var b=new lg;mB(this,b,a);return b};
1256
+ q.close=function(){if("persistent-license"!=this.l){if(!this.sessionId)return this.closed.reject(Error("The session is not callable.")),this.closed;var a=fB("cancelKeyRequest");try{this.j[a](this.i,this.sessionId)}catch(b){}}this.closed.resolve();return this.closed};q.remove=function(){return"persistent-license"!=this.l?Promise.reject(Error("Not a persistent session.")):this.close()};function kB(){this.size=0;this.g=void 0}q=kB.prototype;q.Ac=function(){return this.g};
1257
+ q.forEach=function(a){this.g&&a(this.g,Rb.value())};q.get=function(a){if(this.has(a))return this.g};q.has=function(a){var b=Rb.value();return this.g&&Eb(a,b)?!0:!1};q.entries=function(){};q.keys=function(){};q.values=function(){};var $A="",eB="webkit";Rz(ZA);function nB(){}function oB(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;a.requestPictureInPicture&&document.exitPictureInPicture||!a.webkitSupportsPresentationMode||(document.pictureInPictureEnabled=!0,document.pictureInPictureElement=null,a.requestPictureInPicture=pB,Object.defineProperty(a,"disablePictureInPicture",{get:qB,set:rB,enumerable:!0,configurable:!0}),document.exitPictureInPicture=sB,document.addEventListener("webkitpresentationmodechanged",tB,!0))}}
1258
+ function tB(a){a=a.target;if("picture-in-picture"==a.webkitPresentationMode){document.pictureInPictureElement=a;var b=new Event("enterpictureinpicture");a.dispatchEvent(b)}else document.pictureInPictureElement==a&&(document.pictureInPictureElement=null),b=new Event("leavepictureinpicture"),a.dispatchEvent(b)}
1259
+ function pB(){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 sB(){var a=document.pictureInPictureElement;return a?(a.webkitSetPresentationMode("inline"),document.pictureInPictureElement=null,Promise.resolve()):Promise.reject(Error("No picture in picture element found"))}
1260
+ function qB(){return this.hasAttribute("disablePictureInPicture")?!0:!this.webkitSupportsPresentationMode("picture-in-picture")}function rB(a){a?this.setAttribute("disablePictureInPicture",""):this.removeAttribute("disablePictureInPicture")}Oz.PiPWebkit=nB;nB.install=oB;Rz(oB);function uB(){}function vB(){window.crypto&&("randomUUID"in window.crypto||(window.crypto.randomUUID=wB))}function wB(){var a=URL.createObjectURL(new Blob),b=a.toString();URL.revokeObjectURL(a);return b.substr(b.lastIndexOf("/")+1)}Oz.RandomUUID=uB;uB.install=vB;Rz(vB);function xB(){}function yB(){var a=Symbol.prototype;"description"in a||Object.defineProperty(a,"description",{get:zB})}function zB(){var a=/\((.*)\)/.exec(this.toString());return a?a[1]:void 0}Oz.Symbol=xB;xB.install=yB;Rz(yB);function AB(){}function BB(){if(window.HTMLMediaElement){var a=HTMLMediaElement.prototype.play;HTMLMediaElement.prototype.play=function(){var b=a.apply(this);b&&b.catch(function(){});return b}}}Oz.VideoPlayPromise=AB;AB.install=BB;Rz(BB);function CB(){}function DB(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;!a.getVideoPlaybackQuality&&("webkitDroppedFrameCount"in a||ec())&&(a.getVideoPlaybackQuality=EB)}}function EB(){return{droppedVideoFrames:this.webkitDroppedFrameCount,totalVideoFrames:this.webkitDecodedFrameCount,corruptedVideoFrames:0,creationTime:NaN,totalFrameDelay:0}}Oz.VideoPlaybackQuality=CB;CB.install=DB;Rz(DB);function FB(){}function GB(){if(!window.VTTCue&&window.TextTrackCue){var a=null,b=TextTrackCue.length;if(3==b)a=HB;else if(6==b)a=IB;else{try{var c=!!HB(1,2,"")}catch(d){c=!1}c&&(a=HB)}a&&(window.VTTCue=function(d,e,f){return a(d,e,f)})}}function HB(a,b,c){return new window.TextTrackCue(a,b,c)}function IB(a,b,c){return new window.TextTrackCue(a+"-"+b+"-"+c,a,b,c)}Oz.VTTCue=FB;FB.install=GB;Rz(GB);function JB(){}JB.prototype.parseInit=function(){};JB.prototype.setSequenceMode=function(){};JB.prototype.setManifestType=function(){};JB.prototype.parseMedia=function(a,b){var c=null,d=[];a=wc(a).split(/\r?\n/);a=t(a);for(var e=a.next();!e.done;e=a.next())if((e=e.value)&&!/^\s+$/.test(e)&&(e=KB.exec(e))){var f=LB.exec(e[1]);f=60*parseInt(f[1],10)+parseFloat(f[2].replace(",","."));e=new Rd(f,b.segmentEnd?b.segmentEnd:f+2,e[2]);c&&(c.endTime=f,d.push(c));c=e}c&&d.push(c);return d};
1261
+ P("shaka.text.LrcTextParser",JB);JB.prototype.parseMedia=JB.prototype.parseMedia;JB.prototype.setManifestType=JB.prototype.setManifestType;JB.prototype.setSequenceMode=JB.prototype.setSequenceMode;JB.prototype.parseInit=JB.prototype.parseInit;var KB=/^\[(\d{1,2}:\d{1,2}(?:[.,]\d{1,3})?)\](.*)/,LB=/^(\d+):(\d{1,2}(?:[.,]\d{1,3})?)$/;Oe["application/x-subtitle-lrc"]=function(){return new JB};function MB(){}MB.prototype.parseInit=function(){};MB.prototype.setSequenceMode=function(){};MB.prototype.setManifestType=function(){};
1262
+ MB.prototype.parseMedia=function(a,b,c){var d=wc(a);a=[];if(""==d)return a;var e=ch(d,"tt");if(!e)throw new U(2,2,2005,"Failed to parse TTML.");d=nh(e,"body")[0];if(!d)return[];var f=vh(e,NB,"frameRate"),g=vh(e,NB,"subFrameRate"),h=vh(e,NB,"frameRateMultiplier"),k=vh(e,NB,"tickRate"),l=vh(e,NB,"cellResolution"),m=e.attributes["xml:space"]||"default",n=vh(e,OB,"extent");if("default"!=m&&"preserve"!=m)throw new U(2,2,2005,"Invalid xml:space value: "+m);m="default"==m;f=new PB(f,g,h,k);l=l?(l=/^(\d+) (\d+)$/.exec(l))?
1263
+ {wc:parseInt(l[1],10),rows:parseInt(l[2],10)}:null:null;g=(g=nh(e,"metadata")[0])?g.children:[];h=nh(e,"style");e=nh(e,"region");k=[];for(var p=t(e),r=p.next();!r.done;r=p.next()){var u=r.value;r=new Kd;var v=u.attributes["xml:id"];if(v){r.id=v;var w=null;n&&(w=QB.exec(n)||RB.exec(n));v=w?Number(w[1]):null;w=w?Number(w[2]):null;var A,z=SB(u,h,"extent");if(z){var C=(A=QB.exec(z))||RB.exec(z);null!=C&&(r.width=Number(C[1]),r.height=Number(C[2]),A||(null!=v&&(r.width=100*r.width/v),null!=w&&(r.height=
1264
+ 100*r.height/w)),r.widthUnits=A||null!=v?Ld:0,r.heightUnits=A||null!=w?Ld:0)}if(u=SB(u,h,"origin"))if(C=(A=QB.exec(u))||RB.exec(u),null!=C)r.viewportAnchorX=Number(C[1]),r.viewportAnchorY=Number(C[2]),A?z||(r.width=100-r.viewportAnchorX,r.widthUnits=Ld,r.height=100-r.viewportAnchorY,r.heightUnits=Ld):(null!=w&&(r.viewportAnchorY=100*r.viewportAnchorY/w),null!=v&&(r.viewportAnchorX=100*r.viewportAnchorX/v)),r.viewportAnchorUnits=A||null!=v?Ld:0}else r=null;r&&k.push(r)}if(kh(d,"p").length)throw new U(2,
1265
+ 2,2001,"<p> can only be inside <div> in TTML");n=t(kh(d,"div"));for(p=n.next();!p.done;p=n.next())if(kh(p.value,"span").length)throw new U(2,2,2001,"<span> can only be inside <p> in TTML");if(b=TB(d,b,f,g,h,e,k,m,l,null,!1,c))b.backgroundColor||(b.backgroundColor="transparent"),a.push(b);return a};
1266
+ function TB(a,b,c,d,e,f,g,h,k,l,m,n){var p=l;if(ih(a)){if(!m)return null;var r={tagName:"span",children:[lh(a)],attributes:{},parent:null}}else r=a;for(var u=null,v=t(UB),w=v.next();!w.done&&!(u=VB(r,"backgroundImage",d,"#",w.value)[0]);w=v.next());v=null;var A=vh(r,UB,"backgroundImage");n&&A&&!A.startsWith("#")&&(w=new mb(n),A=new mb(A),(w=w.resolve(A).toString())&&(v=w));if("p"==a.tagName||u||v)m=!0;a=m;w="default"==(r.attributes["xml:space"]||(h?"default":"preserve"));A=r.children.every(ih);h=
1267
+ [];if(!A)for(var z=t(r.children),C=z.next();!C.done;C=z.next())(C=TB(C.value,b,c,d,e,f,g,w,k,r,m,n))&&h.push(C);d=null!=l;n=lh(r);n=r.children.length&&n&&/\S/.test(n);C=r.attributes.begin||r.attributes.end||r.attributes.dur;if(!(C||n||"br"==r.tagName||0!=h.length||d&&!w))return null;z=WB(r,c);n=z.start;for(z=z.end;p&&p.tagName&&"tt"!=p.tagName;)z=XB(p,c,n,z),n=z.start,z=z.end,p=p.parent;null==n&&(n=0);n+=b.periodStart;z=null==z?Infinity:z+b.periodStart;n=Math.max(n,b.segmentStart);z=Math.min(z,b.segmentEnd);
1268
+ if(!C&&0<h.length)for(n=Infinity,z=0,b=t(h),c=b.next();!c.done;c=b.next())c=c.value,n=Math.min(n,c.startTime),z=Math.max(z,c.endTime);if("br"==r.tagName)return e=new Rd(n,z,""),e.lineBreak=!0,e;b="";A&&(b=Dc(lh(r)||""),w&&(b=b.replace(/\s+/g," ")));b=new Rd(n,z,b);b.nestedCues=h;m||(b.isContainer=!0);k&&(b.cellResolution=k);k=VB(r,"region",f,"")[0];if(r.attributes.region&&k&&k.attributes["xml:id"]){var y=k.attributes["xml:id"];b.region=g.filter(function(B){return B.id==y})[0]}g=k;l&&d&&!r.attributes.region&&
1269
+ !r.attributes.style&&(g=VB(l,"region",f,"")[0]);YB(b,r,g,u,v,e,a,0==h.length);return b}
1270
+ function YB(a,b,c,d,e,f,g,h){g=g||h;"rtl"==ZB(b,c,f,"direction",g)&&(a.direction="rtl");h=ZB(b,c,f,"writingMode",g);"tb"==h||"tblr"==h?a.writingMode="vertical-lr":"tbrl"==h?a.writingMode="vertical-rl":"rltb"==h||"rl"==h?a.direction="rtl":h&&(a.direction=Ud);(h=ZB(b,c,f,"textAlign",!0))?(a.positionAlign=$B[h],a.lineAlign=aC[h],a.textAlign=ee[h.toUpperCase()]):a.textAlign=Td;if(h=ZB(b,c,f,"displayAlign",!0))a.displayAlign=fe[h.toUpperCase()];if(h=ZB(b,c,f,"color",g))a.color=h;if(h=ZB(b,c,f,"backgroundColor",
1271
+ g))a.backgroundColor=h;if(h=ZB(b,c,f,"border",g))a.border=h;if(h=ZB(b,c,f,"fontFamily",g))switch(h){case "monospaceSerif":a.fontFamily="Courier New,Liberation Mono,Courier,monospace";break;case "proportionalSansSerif":a.fontFamily="Arial,Helvetica,Liberation Sans,sans-serif";break;case "sansSerif":a.fontFamily="sans-serif";break;case "monospaceSansSerif":a.fontFamily="Consolas,monospace";break;case "proportionalSerif":a.fontFamily="serif";break;default:a.fontFamily=h.split(",").filter(function(k){return"default"!=
1272
+ k}).join(",")}(h=ZB(b,c,f,"fontWeight",g))&&"bold"==h&&(a.fontWeight=700);h=ZB(b,c,f,"wrapOption",g);a.wrapLine=h&&"noWrap"==h?!1:!0;(h=ZB(b,c,f,"lineHeight",g))&&h.match(bC)&&(a.lineHeight=h);(h=ZB(b,c,f,"fontSize",g))&&(h.match(bC)||h.match(cC))&&(a.fontSize=h);if(h=ZB(b,c,f,"fontStyle",g))a.fontStyle=je[h.toUpperCase()];d?(e=d.attributes.imageType||d.attributes.imagetype,h=d.attributes.encoding,d=lh(d).trim(),"PNG"==e&&"Base64"==h&&d&&(a.backgroundImage="data:image/png;base64,"+d)):e&&(a.backgroundImage=
1273
+ e);if(d=ZB(b,c,f,"textOutline",g))d=d.split(" "),d[0].match(bC)?a.textStrokeColor=a.color:(a.textStrokeColor=d[0],d.shift()),d[0]&&d[0].match(bC)?a.textStrokeWidth=d[0]:a.textStrokeColor="";(d=ZB(b,c,f,"letterSpacing",g))&&d.match(bC)&&(a.letterSpacing=d);(d=ZB(b,c,f,"linePadding",g))&&d.match(bC)&&(a.linePadding=d);if(d=ZB(b,c,f,"opacity",g))a.opacity=parseFloat(d);(d=SB(c,f,"textDecoration"))&&dC(a,d);(d=eC(b,f,"textDecoration"))&&dC(a,d);if(d=ZB(b,c,f,"textCombine",g))a.textCombineUpright=d;switch(ZB(b,
1273
1274
  c,f,"ruby",g)){case "container":a.rubyTag="ruby";break;case "text":a.rubyTag="rt"}}
1274
- function cC(a,b){b=t(b.split(" "));for(var c=b.next();!c.done;c=b.next())switch(c.value){case "underline":a.textDecoration.includes("underline")||a.textDecoration.push("underline");break;case "noUnderline":a.textDecoration.includes("underline")&&Od(a.textDecoration,"underline");break;case "lineThrough":a.textDecoration.includes("lineThrough")||a.textDecoration.push("lineThrough");break;case "noLineThrough":a.textDecoration.includes("lineThrough")&&Od(a.textDecoration,"lineThrough");break;case "overline":a.textDecoration.includes("overline")||
1275
- a.textDecoration.push("overline");break;case "noOverline":a.textDecoration.includes("overline")&&Od(a.textDecoration,"overline")}}function YB(a,b,c,d,e){e=void 0===e?!0:e;return(a=dC(a,c,d))?a:e?RB(b,c,d):null}function RB(a,b,c){if(!a)return null;var d=vh(a,NB,c);return d?d:eC(a,b,c)}function dC(a,b,c){var d=vh(a,NB,c);return d?d:eC(a,b,c)}
1276
- function eC(a,b,c){a=UB(a,"style",b,"");for(var d=null,e=0;e<a.length;e++){var f=uh(a[e],"urn:ebu:tt:style",c);f||(f=vh(a[e],NB,c));f||(f=dC(a[e],b,c));f&&(d=f)}return d}function UB(a,b,c,d,e){var f=[];if(!a||1>c.length)return f;var g=a;for(a=null;!a&&!(a=e?uh(g,e,b):g.attributes[b])&&(g=g.parent,g););if(b=a)for(b=t(b.split(" ")),e=b.next();!e.done;e=b.next())for(e=e.value,a=t(c),g=a.next();!g.done;g=a.next())if(g=g.value,d+g.attributes["xml:id"]==e){f.push(g);break}return f}
1277
- function WB(a,b,c,d){a=VB(a,b);null==c?c=a.start:null!=a.start&&(c+=a.start);null==d?d=a.end:null!=a.start&&(d+=a.start);return{start:c,end:d}}function VB(a,b){var c=fC(a.attributes.begin,b),d=fC(a.attributes.end,b);a=fC(a.attributes.dur,b);null==d&&null!=a&&(d=c+a);return{start:c,end:d}}
1278
- function fC(a,b){var c=null;if(gC.test(a)){a=gC.exec(a);c=Number(a[1]);var d=Number(a[2]),e=Number(a[3]),f=Number(a[4]);f+=(Number(a[5])||0)/b.h;e+=f/b.frameRate;c=e+60*d+3600*c}else if(hC.test(a))c=iC(hC,a);else if(jC.test(a))c=iC(jC,a);else if(kC.test(a))a=kC.exec(a),c=Number(a[1])/b.frameRate;else if(lC.test(a))a=lC.exec(a),c=Number(a[1])/b.g;else if(mC.test(a))c=iC(mC,a);else if(a)throw new U(2,2,2001,"Could not parse cue time range in TTML");return c}
1279
- function iC(a,b){a=a.exec(b);return null==a||""==a[0]?null:(Number(a[4])||0)/1E3+(Number(a[3])||0)+60*(Number(a[2])||0)+3600*(Number(a[1])||0)}P("shaka.text.TtmlTextParser",LB);LB.prototype.parseMedia=LB.prototype.parseMedia;LB.prototype.setManifestType=LB.prototype.setManifestType;LB.prototype.setSequenceMode=LB.prototype.setSequenceMode;LB.prototype.parseInit=LB.prototype.parseInit;
1280
- function OB(a,b,c,d){this.frameRate=Number(a)||30;this.h=Number(b)||1;this.g=Number(d);0==this.g&&(this.g=a?this.frameRate*this.h:1);c&&(a=/^(\d+) (\d+)$/g.exec(c))&&(this.frameRate*=Number(a[1])/Number(a[2]))}
1281
- var PB=/^(\d{1,2}(?:\.\d+)?|100(?:\.0+)?)% (\d{1,2}(?:\.\d+)?|100(?:\.0+)?)%$/,bC=/^(\d{1,4}(?:\.\d+)?|100)%$/,aC=/^(\d+px|\d+em|\d*\.?\d+c)$/,QB=/^(\d+)px (\d+)px$/,gC=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,hC=/^(?:(\d{2,}):)?(\d{2}):(\d{2})$/,jC=/^(?:(\d{2,}):)?(\d{2}):(\d{2}\.\d+)$/,kC=/^(\d*(?:\.\d*)?)f$/,lC=/^(\d*(?:\.\d*)?)t$/,mC=RegExp("^(?:(\\d*(?:\\.\\d*)?)h)?(?:(\\d*(?:\\.\\d*)?)m)?(?:(\\d*(?:\\.\\d*)?)s)?(?:(\\d*(?:\\.\\d*)?)ms)?$"),$B={left:Xd,center:"center",right:"end",start:Xd,
1282
- end:"end"},ZB={left:"line-left",center:"center",right:"line-right"},MB=["http://www.w3.org/ns/ttml#parameter","http://www.w3.org/2006/10/ttaf1#parameter"],NB=["http://www.w3.org/ns/ttml#styling","http://www.w3.org/2006/10/ttaf1#styling"],TB=["http://www.smpte-ra.org/schemas/2052-1/2010/smpte-tt","http://www.smpte-ra.org/schemas/2052-1/2013/smpte-tt"];Oe["application/ttml+xml"]=function(){return new LB};function nC(){this.g=new LB}nC.prototype.parseInit=function(a){var b=!1;(new Pg).box("moov",Ug).box("trak",Ug).box("mdia",Ug).box("minf",Ug).box("stbl",Ug).W("stsd",Wg).box("stpp",function(c){b=!0;c.parser.stop()}).parse(a);if(!b)throw new U(2,2,2007);};nC.prototype.setSequenceMode=function(){};nC.prototype.setManifestType=function(){};
1283
- nC.prototype.parseMedia=function(a,b,c){var d=this,e=!1,f=[];(new Pg).box("mdat",Zg(function(g){e=!0;f=f.concat(d.g.parseMedia(g,b,c))})).parse(a,!1);if(!e)throw new U(2,2,2007);return f};P("shaka.text.Mp4TtmlParser",nC);nC.prototype.parseMedia=nC.prototype.parseMedia;nC.prototype.setManifestType=nC.prototype.setManifestType;nC.prototype.setSequenceMode=nC.prototype.setSequenceMode;nC.prototype.parseInit=nC.prototype.parseInit;Oe['application/mp4; codecs="stpp"']=function(){return new nC};
1284
- Oe['application/mp4; codecs="stpp.ttml"']=function(){return new nC};Oe['application/mp4; codecs="stpp.ttml.im1t"']=function(){return new nC};Oe['application/mp4; codecs="stpp.ttml.im2t"']=function(){return new nC};Oe['application/mp4; codecs="stpp.ttml.etd1"']=function(){return new nC};Oe['application/mp4; codecs="stpp.ttml.etd1|im1t"']=function(){return new nC};Oe['application/mp4; codecs="stpp.ttml.im1t|etd1"']=function(){return new nC};Oe['application/mp4; codecs="stpp.TTML.im1t"']=function(){return new nC};function oC(){this.h=!1;this.g="UNKNOWN"}oC.prototype.parseInit=function(){};oC.prototype.setSequenceMode=function(a){this.h=a};oC.prototype.setManifestType=function(a){this.g=a};
1285
- oC.prototype.parseMedia=function(a,b){a=wc(a);a=a.replace(/\r\n|\r(?=[^\n]|$)/gm,"\n");var c=a.split(/\n{2,}/m);if(!/^WEBVTT($|[ \t\n])/m.test(c[0]))throw new U(2,2,2E3);a=b.vttOffset;if(c[0].includes("X-TIMESTAMP-MAP")&&"HLS"==this.g)if(this.h){var d=c[0];a=d.match(/LOCAL:((?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{3}))/m);d=d.match(/MPEGTS:(\d+)/m);if(!a||!d)throw new U(2,2,2E3);a=pC(new Kp(a[1]));if(null==a)throw new U(2,2,2E3);a=b.periodStart+Number(d[1])/9E4-a}else a=b.segmentStart;b=[];d=t(c[0].split("\n"));
1275
+ function dC(a,b){b=t(b.split(" "));for(var c=b.next();!c.done;c=b.next())switch(c.value){case "underline":a.textDecoration.includes("underline")||a.textDecoration.push("underline");break;case "noUnderline":a.textDecoration.includes("underline")&&Od(a.textDecoration,"underline");break;case "lineThrough":a.textDecoration.includes("lineThrough")||a.textDecoration.push("lineThrough");break;case "noLineThrough":a.textDecoration.includes("lineThrough")&&Od(a.textDecoration,"lineThrough");break;case "overline":a.textDecoration.includes("overline")||
1276
+ a.textDecoration.push("overline");break;case "noOverline":a.textDecoration.includes("overline")&&Od(a.textDecoration,"overline")}}function ZB(a,b,c,d,e){e=void 0===e?!0:e;return(a=eC(a,c,d))?a:e?SB(b,c,d):null}function SB(a,b,c){if(!a)return null;var d=vh(a,OB,c);return d?d:fC(a,b,c)}function eC(a,b,c){var d=vh(a,OB,c);return d?d:fC(a,b,c)}
1277
+ function fC(a,b,c){a=VB(a,"style",b,"");for(var d=null,e=0;e<a.length;e++){var f=uh(a[e],"urn:ebu:tt:style",c);f||(f=vh(a[e],OB,c));f||(f=eC(a[e],b,c));f&&(d=f)}return d}function VB(a,b,c,d,e){var f=[];if(!a||1>c.length)return f;var g=a;for(a=null;!a&&!(a=e?uh(g,e,b):g.attributes[b])&&(g=g.parent,g););if(b=a)for(b=t(b.split(" ")),e=b.next();!e.done;e=b.next())for(e=e.value,a=t(c),g=a.next();!g.done;g=a.next())if(g=g.value,d+g.attributes["xml:id"]==e){f.push(g);break}return f}
1278
+ function XB(a,b,c,d){a=WB(a,b);null==c?c=a.start:null!=a.start&&(c+=a.start);null==d?d=a.end:null!=a.start&&(d+=a.start);return{start:c,end:d}}function WB(a,b){var c=gC(a.attributes.begin,b),d=gC(a.attributes.end,b);a=gC(a.attributes.dur,b);null==d&&null!=a&&(d=c+a);return{start:c,end:d}}
1279
+ function gC(a,b){var c=null;if(hC.test(a)){a=hC.exec(a);c=Number(a[1]);var d=Number(a[2]),e=Number(a[3]),f=Number(a[4]);f+=(Number(a[5])||0)/b.h;e+=f/b.frameRate;c=e+60*d+3600*c}else if(iC.test(a))c=jC(iC,a);else if(kC.test(a))c=jC(kC,a);else if(lC.test(a))a=lC.exec(a),c=Number(a[1])/b.frameRate;else if(mC.test(a))a=mC.exec(a),c=Number(a[1])/b.g;else if(nC.test(a))c=jC(nC,a);else if(a)throw new U(2,2,2001,"Could not parse cue time range in TTML");return c}
1280
+ function jC(a,b){a=a.exec(b);return null==a||""==a[0]?null:(Number(a[4])||0)/1E3+(Number(a[3])||0)+60*(Number(a[2])||0)+3600*(Number(a[1])||0)}P("shaka.text.TtmlTextParser",MB);MB.prototype.parseMedia=MB.prototype.parseMedia;MB.prototype.setManifestType=MB.prototype.setManifestType;MB.prototype.setSequenceMode=MB.prototype.setSequenceMode;MB.prototype.parseInit=MB.prototype.parseInit;
1281
+ function PB(a,b,c,d){this.frameRate=Number(a)||30;this.h=Number(b)||1;this.g=Number(d);0==this.g&&(this.g=a?this.frameRate*this.h:1);c&&(a=/^(\d+) (\d+)$/g.exec(c))&&(this.frameRate*=Number(a[1])/Number(a[2]))}
1282
+ var QB=/^(\d{1,2}(?:\.\d+)?|100(?:\.0+)?)% (\d{1,2}(?:\.\d+)?|100(?:\.0+)?)%$/,cC=/^(\d{1,4}(?:\.\d+)?|100)%$/,bC=/^(\d+px|\d+em|\d*\.?\d+c)$/,RB=/^(\d+)px (\d+)px$/,hC=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,iC=/^(?:(\d{2,}):)?(\d{2}):(\d{2})$/,kC=/^(?:(\d{2,}):)?(\d{2}):(\d{2}\.\d+)$/,lC=/^(\d*(?:\.\d*)?)f$/,mC=/^(\d*(?:\.\d*)?)t$/,nC=RegExp("^(?:(\\d*(?:\\.\\d*)?)h)?(?:(\\d*(?:\\.\\d*)?)m)?(?:(\\d*(?:\\.\\d*)?)s)?(?:(\\d*(?:\\.\\d*)?)ms)?$"),aC={left:Xd,center:"center",right:"end",start:Xd,
1283
+ end:"end"},$B={left:"line-left",center:"center",right:"line-right"},NB=["http://www.w3.org/ns/ttml#parameter","http://www.w3.org/2006/10/ttaf1#parameter"],OB=["http://www.w3.org/ns/ttml#styling","http://www.w3.org/2006/10/ttaf1#styling"],UB=["http://www.smpte-ra.org/schemas/2052-1/2010/smpte-tt","http://www.smpte-ra.org/schemas/2052-1/2013/smpte-tt"];Oe["application/ttml+xml"]=function(){return new MB};function oC(){this.g=new MB}oC.prototype.parseInit=function(a){var b=!1;(new Pg).box("moov",Ug).box("trak",Ug).box("mdia",Ug).box("minf",Ug).box("stbl",Ug).W("stsd",Wg).box("stpp",function(c){b=!0;c.parser.stop()}).parse(a);if(!b)throw new U(2,2,2007);};oC.prototype.setSequenceMode=function(){};oC.prototype.setManifestType=function(){};
1284
+ oC.prototype.parseMedia=function(a,b,c){var d=this,e=!1,f=[];(new Pg).box("mdat",Zg(function(g){e=!0;f=f.concat(d.g.parseMedia(g,b,c))})).parse(a,!1);if(!e)throw new U(2,2,2007);return f};P("shaka.text.Mp4TtmlParser",oC);oC.prototype.parseMedia=oC.prototype.parseMedia;oC.prototype.setManifestType=oC.prototype.setManifestType;oC.prototype.setSequenceMode=oC.prototype.setSequenceMode;oC.prototype.parseInit=oC.prototype.parseInit;Oe['application/mp4; codecs="stpp"']=function(){return new oC};
1285
+ Oe['application/mp4; codecs="stpp.ttml"']=function(){return new oC};Oe['application/mp4; codecs="stpp.ttml.im1t"']=function(){return new oC};Oe['application/mp4; codecs="stpp.ttml.im2t"']=function(){return new oC};Oe['application/mp4; codecs="stpp.ttml.etd1"']=function(){return new oC};Oe['application/mp4; codecs="stpp.ttml.etd1|im1t"']=function(){return new oC};Oe['application/mp4; codecs="stpp.ttml.im1t|etd1"']=function(){return new oC};Oe['application/mp4; codecs="stpp.TTML.im1t"']=function(){return new oC};function pC(){this.h=!1;this.g="UNKNOWN"}pC.prototype.parseInit=function(){};pC.prototype.setSequenceMode=function(a){this.h=a};pC.prototype.setManifestType=function(a){this.g=a};
1286
+ pC.prototype.parseMedia=function(a,b){a=wc(a);a=a.replace(/\r\n|\r(?=[^\n]|$)/gm,"\n");var c=a.split(/\n{2,}/m);if(!/^WEBVTT($|[ \t\n])/m.test(c[0]))throw new U(2,2,2E3);a=b.vttOffset;if(c[0].includes("X-TIMESTAMP-MAP")&&"HLS"==this.g)if(this.h){var d=c[0];a=d.match(/LOCAL:((?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{3}))/m);d=d.match(/MPEGTS:(\d+)/m);if(!a||!d)throw new U(2,2,2E3);a=qC(new Kp(a[1]));if(null==a)throw new U(2,2,2E3);a=b.periodStart+Number(d[1])/9E4-a}else a=b.segmentStart;b=[];d=t(c[0].split("\n"));
1286
1287
  for(var e=d.next();!e.done;e=d.next())if(e=e.value,/^Region:/.test(e)){e=new Kp(e);var f=new Kd;Np(e);Lp(e);for(var g=Np(e);g;){var h=f,k=g;(g=/^id=(.*)$/.exec(k))?h.id=g[1]:(g=/^width=(\d{1,2}|100)%$/.exec(k))?h.width=Number(g[1]):(g=/^lines=(\d+)$/.exec(k))?(h.height=Number(g[1]),h.heightUnits=2):(g=/^regionanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(k))?(h.regionAnchorX=Number(g[1]),h.regionAnchorY=Number(g[2])):(g=/^viewportanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(k))?(h.viewportAnchorX=Number(g[1]),
1287
- h.viewportAnchorY=Number(g[2])):/^scroll=up$/.exec(k)&&(h.scroll="up");Lp(e);g=Np(e)}b.push(f)}d=new Map;qC(d);e=[];c=t(c.slice(1));for(f=c.next();!f.done;f=c.next()){f=f.value.split("\n");if((1!=f.length||f[0])&&!/^NOTE($|[ \t])/.test(f[0])&&"STYLE"==f[0]){h=[];g=-1;for(k=1;k<f.length;k++)f[k].includes("::cue")&&(h.push([]),g=h.length-1),-1!=g&&(h[g].push(f[k]),f[k].includes("}")&&(g=-1));h=t(h);for(g=h.next();!g.done;g=h.next()){var l=g.value;g="global";(k=l[0].match(/\((.*)\)/))&&(g=k.pop());k=
1288
+ h.viewportAnchorY=Number(g[2])):/^scroll=up$/.exec(k)&&(h.scroll="up");Lp(e);g=Np(e)}b.push(f)}d=new Map;rC(d);e=[];c=t(c.slice(1));for(f=c.next();!f.done;f=c.next()){f=f.value.split("\n");if((1!=f.length||f[0])&&!/^NOTE($|[ \t])/.test(f[0])&&"STYLE"==f[0]){h=[];g=-1;for(k=1;k<f.length;k++)f[k].includes("::cue")&&(h.push([]),g=h.length-1),-1!=g&&(h[g].push(f[k]),f[k].includes("}")&&(g=-1));h=t(h);for(g=h.next();!g.done;g=h.next()){var l=g.value;g="global";(k=l[0].match(/\((.*)\)/))&&(g=k.pop());k=
1288
1289
  l.slice(1,-1);l[0].includes("}")&&(l=/\{(.*?)\}/.exec(l[0]))&&(k=l[1].split(";"));(l=d.get(g))||(l=new Rd(0,0,""));for(var m=!1,n=0;n<k.length;n++){var p=/^\s*([^:]+):\s*(.*)/.exec(k[n]);if(p){var r=p[2].trim().replace(";","");switch(p[1].trim()){case "background-color":case "background":m=!0;l.backgroundColor=r;break;case "color":m=!0;l.color=r;break;case "font-family":m=!0;l.fontFamily=r;break;case "font-size":m=!0;l.fontSize=r;break;case "font-weight":if(700<=parseInt(r,10)||"bold"==r)m=!0,l.fontWeight=
1289
1290
  700;break;case "font-style":switch(r){case "normal":m=!0;l.fontStyle=be;break;case "italic":m=!0;l.fontStyle="italic";break;case "oblique":m=!0,l.fontStyle="oblique"}break;case "opacity":m=!0;l.opacity=parseFloat(r);break;case "text-combine-upright":m=!0;l.textCombineUpright=r;break;case "text-shadow":m=!0;l.textShadow=r;break;case "white-space":m=!0,l.wrapLine="noWrap"!=r}}}m&&d.set(g,l)}}m=a;if(1==f.length&&!f[0]||/^NOTE($|[ \t])/.test(f[0])||"STYLE"==f[0]||"REGION"==f[0])f=null;else if(h=null,
1290
- f[0].includes("--\x3e")||(h=f[0],f.splice(0,1)),g=new Kp(f[0]),k=pC(g),n=Mp(g,/[ \t]+--\x3e[ \t]+/g),l=pC(g),null==k||null==n||null==l)Ya("Failed to parse VTT time code. Cue skipped:",h,f),f=null;else{k+=m;l+=m;f=f.slice(1).join("\n").trim();d.has("global")?(m=d.get("global").clone(),m.startTime=k,m.endTime=l,m.payload=""):m=new Rd(k,l,"");Lp(g);for(k=Np(g);k;)rC(m,k,b),Lp(g),k=Np(g);sC(f,m,d);null!=h&&(m.id=h);f=m}f&&e.push(f)}return e};
1291
- function qC(a){for(var b=t(Object.entries(he)),c=b.next();!c.done;c=b.next()){var d=t(c.value);c=d.next().value;d=d.next().value;var e=new Rd(0,0,"");e.color=d;a.set("."+c,e)}b=t(Object.entries(ie));for(c=b.next();!c.done;c=b.next())d=t(c.value),c=d.next().value,d=d.next().value,e=new Rd(0,0,""),e.backgroundColor=d,a.set("."+c,e)}
1292
- function sC(a,b,c){if(a.includes("<")){0===c.size&&qC(c);var d=a;a=[];for(var e=-1,f=0;f<d.length;f++)"<"===d[f]?e=f+1:">"===d[f]&&0<e&&(e=d.substr(e,f-e),e.match(tC)&&a.push(e),e=-1);a=t(a);for(f=a.next();!f.done;f=a.next())f=f.value,d=d.replace("<"+f+">",'<div time="'+f+'">'),d+="</div>";a=d;a:{f=a;e=[];var g=-1;a="";d=!1;for(var h=0;h<f.length;h++)if("/"===f[h]){var k=f.indexOf(">",h);if(-1===k){a=f;break a}if((k=f.substring(h+1,k))&&"v"==k){d=!0;var l=null;e.length&&(l=e[e.length-1]);if(l){if(l===
1293
- k)a+="/"+k+">";else{if(!l.startsWith("v")){a+=f[h];continue}a+="/"+l+">"}h+=k.length+1}else a+=f[h]}else a+=f[h]}else"<"===f[h]?(g=h+1,"v"!=f[g]&&(g=-1)):">"===f[h]&&0<g&&(e.push(f.substr(g,h-g)),g=-1),a+=f[h];f=t(e);for(e=f.next();!e.done;e=f.next())e=e.value,g=e.replace(" ",".voice-"),a=a.replace("<"+e+">","<"+g+">"),a=a.replace("</"+e+">","</"+g+">"),d||(a+="</"+g+">")}a=uC(a);try{var m=ch("<span>"+a+"</span>","span")}catch(n){}if(m)if(m=m.children,1!=m.length||m[0].tagName)for(m=t(m),a=m.next();!a.done;a=
1294
- m.next())vC(a.value,b,c);else b.payload=Dc(a);else b.payload=Dc(a)}else b.payload=Dc(a)}function uC(a){var b={"< ":""," >":" &gt;"},c=/(< +>|<\s|\s>)/g,d=RegExp(c.source);return a&&d.test(a)?a.replace(c,function(e){return b[e]||""}):a||""}function wC(a,b){return a&&0<a.length?a:b}
1295
- function vC(a,b,c){var d=b.clone();d.nestedCues=[];d.payload="";d.rubyTag="";d.line=null;d.region=new Kd;d.position=null;d.size=0;if(a.tagName)for(var e=t(a.tagName.split(/(?=[ .])+/g)),f=e.next();!f.done;f=e.next()){var g=f=f.value;if(g.startsWith(".voice-")){var h=g.split("-").pop();g='v[voice="'+h+'"]';c.has(g)||(g="v[voice="+h+"]")}c.has(g)&&(g=c.get(g))&&(d.backgroundColor=wC(g.backgroundColor,d.backgroundColor),d.color=wC(g.color,d.color),d.fontFamily=wC(g.fontFamily,d.fontFamily),d.fontSize=
1296
- wC(g.fontSize,d.fontSize),d.textShadow=wC(g.textShadow,d.textShadow),d.fontWeight=g.fontWeight,d.fontStyle=g.fontStyle,d.opacity=g.opacity,d.rubyTag=g.rubyTag,d.textCombineUpright=g.textCombineUpright,d.wrapLine=g.wrapLine);switch(f){case "br":d=ce(d.startTime,d.endTime);b.nestedCues.push(d);return;case "b":d.fontWeight=700;break;case "i":d.fontStyle="italic";break;case "u":d.textDecoration.push("underline");break;case "font":if(f=a.attributes.color)d.color=f;break;case "div":f=a.attributes.time;
1297
- if(!f)break;if(f=pC(new Kp(f)))d.startTime=f;break;case "ruby":case "rp":case "rt":d.rubyTag=f}}e=a.children;if(ih(a)||1==e.length&&ih(e[0]))for(c=lh(a).split("\n"),a=!0,c=t(c),e=c.next();!e.done;e=c.next())e=e.value,a||(a=ce(d.startTime,d.endTime),b.nestedCues.push(a)),0<e.length&&(a=d.clone(),a.payload=Dc(e),b.nestedCues.push(a)),a=!1;else for(b.nestedCues.push(d),b=t(e),a=b.next();!a.done;a=b.next())vC(a.value,d,c)}
1298
- function rC(a,b,c){var d;if(d=/^align:(start|middle|center|end|left|right)$/.exec(b))b=d[1],"middle"==b?a.textAlign=Td:a.textAlign=ee[b.toUpperCase()];else if(d=/^vertical:(lr|rl)$/.exec(b))a.writingMode="lr"==d[1]?"vertical-lr":"vertical-rl";else if(d=/^size:([\d.]+)%$/.exec(b))a.size=Number(d[1]);else if(d=/^position:([\d.]+)%(?:,(line-left|line-right|middle|center|start|end|auto))?$/.exec(b))a.position=Number(d[1]),d[2]&&(b=d[2],a.positionAlign="line-left"==b||"start"==b?"line-left":"line-right"==
1299
- b||"end"==b?"line-right":"center"==b||"middle"==b?"center":Sd);else if(d=/^region:(.*)$/.exec(b)){if(b=xC(c,d[1]))a.region=b}else if(c=/^line:([\d.]+)%(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=1,a.line=Number(c[1]),c[2]&&(a.lineAlign=ge[c[2].toUpperCase()]);else if(c=/^line:(-?\d+)(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=Wd,a.line=Number(c[1]),c[2]&&(a.lineAlign=ge[c[2].toUpperCase()])}
1300
- function xC(a,b){a=a.filter(function(c){return c.id==b});return a.length?a[0]:null}function pC(a){a=Mp(a,tC);if(null==a)return null;var b=Number(a[2]),c=Number(a[3]);return 59<b||59<c?null:Number(a[4])/1E3+c+60*b+3600*(Number(a[1])||0)}P("shaka.text.VttTextParser",oC);oC.prototype.parseMedia=oC.prototype.parseMedia;oC.prototype.setManifestType=oC.prototype.setManifestType;oC.prototype.setSequenceMode=oC.prototype.setSequenceMode;oC.prototype.parseInit=oC.prototype.parseInit;var tC=/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g;
1301
- Oe["text/vtt"]=function(){return new oC};Oe['text/vtt; codecs="vtt"']=function(){return new oC};Oe['text/vtt; codecs="wvtt"']=function(){return new oC};function yC(){this.g=null}yC.prototype.parseInit=function(a){var b=this,c=!1;(new Pg).box("moov",Ug).box("trak",Ug).box("mdia",Ug).W("mdhd",function(d){d=aj(d.reader,d.version);b.g=d.timescale}).box("minf",Ug).box("stbl",Ug).W("stsd",Wg).box("wvtt",function(){c=!0}).parse(a);if(!this.g)throw new U(2,2,2008);if(!c)throw new U(2,2,2008);};yC.prototype.setSequenceMode=function(){};yC.prototype.setManifestType=function(){};
1302
- yC.prototype.parseMedia=function(a,b){if(!a.length)return[];if(!this.g)throw new U(2,2,2008);var c=0,d=[],e,f=[],g=!1,h=!1,k=!1,l=null;(new Pg).box("moof",Ug).box("traf",Ug).W("tfdt",function(C){g=!0;c=$i(C.reader,C.version).baseMediaDecodeTime}).W("tfhd",function(C){l=Zi(C.reader,C.flags).Nd}).W("trun",function(C){h=!0;d=bj(C.reader,C.version,C.flags).$h}).box("mdat",Zg(function(C){k=!0;e=C})).parse(a,!1);if(!k&&!g&&!h)throw new U(2,2,2008);a=c;for(var m=new Mg(e,0),n=t(d),p=n.next();!p.done;p=n.next()){p=
1303
- p.value;var r=p.Sg||l,u=p.kf?c+p.kf:a;a=u+(r||0);var v=0;do{var w=m.T();v+=w;var A=m.T(),z=null;"vttc"==Tg(A)?8<w&&(z=m.Hb(w-8)):m.skip(w-8);r&&z&&(w=zC(z,b.periodStart+u/this.g,b.periodStart+a/this.g),f.push(w))}while(p.sampleSize&&v<p.sampleSize)}return f.filter(We)};function zC(a,b,c){var d,e,f;(new Pg).box("payl",Zg(function(g){d=wc(g)})).box("iden",Zg(function(g){e=wc(g)})).box("sttg",Zg(function(g){f=wc(g)})).parse(a);return d?AC(d,e,f,b,c):null}
1304
- function AC(a,b,c,d,e){d=new Rd(d,e,"");sC(a,d,new Map);b&&(d.id=b);if(c)for(a=new Kp(c),b=Np(a);b;)rC(d,b,[]),Lp(a),b=Np(a);return d}P("shaka.text.Mp4VttParser",yC);yC.prototype.parseMedia=yC.prototype.parseMedia;yC.prototype.setManifestType=yC.prototype.setManifestType;yC.prototype.setSequenceMode=yC.prototype.setSequenceMode;yC.prototype.parseInit=yC.prototype.parseInit;Oe['application/mp4; codecs="wvtt"']=function(){return new yC};function BC(){}BC.prototype.parseInit=function(){};BC.prototype.setSequenceMode=function(){};BC.prototype.setManifestType=function(){};BC.prototype.parseMedia=function(a){var b=wc(a).replace(/\r+/g,"");b=b.trim();a=[];if(""==b)return a;b=t(b.split("\n\n"));for(var c=b.next();!c.done;c=b.next()){c=c.value.split("\n");var d=new Kp(c[0]),e=CC(d),f=Mp(d,/,/g);d=CC(d);if(null==e||null==f||null==d)throw new U(2,2,2001,"Could not parse cue time range in SubViewer");a.push(new Rd(e,d,c.slice(1).join("\n").trim()))}return a};
1305
- function CC(a){a=Mp(a,/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g);if(null==a)return null;var b=Number(a[2]),c=Number(a[3]);return 59<b||59<c?null:Number(a[4])/1E3+c+60*b+3600*(Number(a[1])||0)}P("shaka.text.SbvTextParser",BC);BC.prototype.parseMedia=BC.prototype.parseMedia;BC.prototype.setManifestType=BC.prototype.setManifestType;BC.prototype.setSequenceMode=BC.prototype.setSequenceMode;BC.prototype.parseInit=BC.prototype.parseInit;Oe["text/x-subviewer"]=function(){return new BC};function DC(){this.g=new oC}DC.prototype.parseInit=function(){};DC.prototype.setSequenceMode=function(){};DC.prototype.setManifestType=function(){};DC.prototype.parseMedia=function(a,b,c){a=wc(a);a=EC(a);a=Gb(Ac(a));return this.g.parseMedia(a,b,c)};
1306
- function EC(a){var b="WEBVTT\n\n";if(""==a)return b;a=a.replace(/\r+/g,"");a=a.trim();a=t(a.split("\n\n"));for(var c=a.next();!c.done;c=a.next())c=c.value.split(/\n/),c[0].match(/\d+/)&&c.shift(),c[0]=c[0].replace(/,/g,"."),b+=c.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 b}P("shaka.text.SrtTextParser",DC);DC.srt2webvtt=EC;DC.prototype.parseMedia=DC.prototype.parseMedia;
1307
- DC.prototype.setManifestType=DC.prototype.setManifestType;DC.prototype.setSequenceMode=DC.prototype.setSequenceMode;DC.prototype.parseInit=DC.prototype.parseInit;Oe["text/srt"]=function(){return new DC};function FC(){}FC.prototype.parseInit=function(){};FC.prototype.setSequenceMode=function(){};FC.prototype.setManifestType=function(){};
1308
- FC.prototype.parseMedia=function(a){var b="",c="",d=null,e=null;e=wc(a).split(/\r?\n\s*\r?\n/);a=t(e);for(e=a.next();!e.done;e=a.next()){var f=e.value;e=f;if(f=GC.exec(f))d=f[1],e=f[2];"V4 Styles"==d||"V4+ Styles"==d?(b=e,b=c?b+("\n"+e):e):"Events"==d&&(c=c?c+("\n"+e):e)}d=[];e=null;b=t(b.split(/\r?\n/));for(f=b.next();!f.done;f=b.next())if(a=f.value,!/^\s*;/.test(a)&&(f=HC.exec(a)))if(a=f[1].trim(),f=f[2].trim(),"Format"==a)e=f.split(IC);else if("Style"==a){a=f.split(IC);f={};for(var g=0;g<e.length&&
1309
- g<a.length;g++)f[e[g]]=a[g];d.push(f)}e=[];b=null;a={};c=t(c.split(/\r?\n/));for(f=c.next();!f.done;a={Gf:a.Gf},f=c.next())if(f=f.value,!/^\s*;/.test(f)&&(g=HC.exec(f)))if(f=g[1].trim(),g=g[2].trim(),"Format"==f)b=g.split(IC);else if("Dialogue"==f){g=g.split(IC);f={};for(var h=0;h<b.length&&h<g.length;h++)f[b[h]]=g[h];h=JC(f.Start);var k=JC(f.End);g=new Rd(h,k,g.slice(b.length-1).join(",").replace(/\\N/g,"\n").replace(/\{[^}]+\}/g,""));a.Gf=f.Style;(f=d.find(function(l){return function(m){return m.Name==
1310
- l.Gf}}(a)))&&KC(g,f);e.push(g)}return e};
1311
- function KC(a,b){var c=b.Fontname;c&&(a.fontFamily=c);if(c=b.Fontsize)a.fontSize=c+"px";if(c=b.PrimaryColour)if(c=LC(c))a.color=c;if(c=b.BackColour)if(c=LC(c))a.backgroundColor=c;b.Bold&&(a.fontWeight=700);b.Italic&&(a.fontStyle="italic");b.Underline&&a.textDecoration.push("underline");if(c=b.Spacing)a.letterSpacing=c+"px";if(c=b.Alignment)switch(parseInt(c,10)){case 1:a.displayAlign=Yd;a.textAlign="start";break;case 2:a.displayAlign=Yd;a.textAlign=Td;break;case 3:a.displayAlign=Yd;a.textAlign="end";
1291
+ f[0].includes("--\x3e")||(h=f[0],f.splice(0,1)),g=new Kp(f[0]),k=qC(g),n=Mp(g,/[ \t]+--\x3e[ \t]+/g),l=qC(g),null==k||null==n||null==l)Ya("Failed to parse VTT time code. Cue skipped:",h,f),f=null;else{k+=m;l+=m;f=f.slice(1).join("\n").trim();d.has("global")?(m=d.get("global").clone(),m.startTime=k,m.endTime=l,m.payload=""):m=new Rd(k,l,"");Lp(g);for(k=Np(g);k;)sC(m,k,b),Lp(g),k=Np(g);tC(f,m,d);null!=h&&(m.id=h);f=m}f&&e.push(f)}return e};
1292
+ function rC(a){for(var b=t(Object.entries(he)),c=b.next();!c.done;c=b.next()){var d=t(c.value);c=d.next().value;d=d.next().value;var e=new Rd(0,0,"");e.color=d;a.set("."+c,e)}b=t(Object.entries(ie));for(c=b.next();!c.done;c=b.next())d=t(c.value),c=d.next().value,d=d.next().value,e=new Rd(0,0,""),e.backgroundColor=d,a.set("."+c,e)}
1293
+ function tC(a,b,c){if(a.includes("<")){0===c.size&&rC(c);var d=a;a=[];for(var e=-1,f=0;f<d.length;f++)"<"===d[f]?e=f+1:">"===d[f]&&0<e&&(e=d.substr(e,f-e),e.match(uC)&&a.push(e),e=-1);a=t(a);for(f=a.next();!f.done;f=a.next())f=f.value,d=d.replace("<"+f+">",'<div time="'+f+'">'),d+="</div>";a=d;a:{f=a;e=[];var g=-1;a="";d=!1;for(var h=0;h<f.length;h++)if("/"===f[h]){var k=f.indexOf(">",h);if(-1===k){a=f;break a}if((k=f.substring(h+1,k))&&"v"==k){d=!0;var l=null;e.length&&(l=e[e.length-1]);if(l){if(l===
1294
+ k)a+="/"+k+">";else{if(!l.startsWith("v")){a+=f[h];continue}a+="/"+l+">"}h+=k.length+1}else a+=f[h]}else a+=f[h]}else"<"===f[h]?(g=h+1,"v"!=f[g]&&(g=-1)):">"===f[h]&&0<g&&(e.push(f.substr(g,h-g)),g=-1),a+=f[h];f=t(e);for(e=f.next();!e.done;e=f.next())e=e.value,g=e.replace(" ",".voice-"),a=a.replace("<"+e+">","<"+g+">"),a=a.replace("</"+e+">","</"+g+">"),d||(a+="</"+g+">")}a=vC(a);try{var m=ch("<span>"+a+"</span>","span")}catch(n){}if(m)if(m=m.children,1!=m.length||m[0].tagName)for(m=t(m),a=m.next();!a.done;a=
1295
+ m.next())wC(a.value,b,c);else b.payload=Dc(a);else b.payload=Dc(a)}else b.payload=Dc(a)}function vC(a){var b={"< ":""," >":" &gt;"},c=/(< +>|<\s|\s>)/g,d=RegExp(c.source);return a&&d.test(a)?a.replace(c,function(e){return b[e]||""}):a||""}function xC(a,b){return a&&0<a.length?a:b}
1296
+ function wC(a,b,c){var d=b.clone();d.nestedCues=[];d.payload="";d.rubyTag="";d.line=null;d.region=new Kd;d.position=null;d.size=0;if(a.tagName)for(var e=t(a.tagName.split(/(?=[ .])+/g)),f=e.next();!f.done;f=e.next()){var g=f=f.value;if(g.startsWith(".voice-")){var h=g.split("-").pop();g='v[voice="'+h+'"]';c.has(g)||(g="v[voice="+h+"]")}c.has(g)&&(g=c.get(g))&&(d.backgroundColor=xC(g.backgroundColor,d.backgroundColor),d.color=xC(g.color,d.color),d.fontFamily=xC(g.fontFamily,d.fontFamily),d.fontSize=
1297
+ xC(g.fontSize,d.fontSize),d.textShadow=xC(g.textShadow,d.textShadow),d.fontWeight=g.fontWeight,d.fontStyle=g.fontStyle,d.opacity=g.opacity,d.rubyTag=g.rubyTag,d.textCombineUpright=g.textCombineUpright,d.wrapLine=g.wrapLine);switch(f){case "br":d=ce(d.startTime,d.endTime);b.nestedCues.push(d);return;case "b":d.fontWeight=700;break;case "i":d.fontStyle="italic";break;case "u":d.textDecoration.push("underline");break;case "font":if(f=a.attributes.color)d.color=f;break;case "div":f=a.attributes.time;
1298
+ if(!f)break;if(f=qC(new Kp(f)))d.startTime=f;break;case "ruby":case "rp":case "rt":d.rubyTag=f}}e=a.children;if(ih(a)||1==e.length&&ih(e[0]))for(c=lh(a).split("\n"),a=!0,c=t(c),e=c.next();!e.done;e=c.next())e=e.value,a||(a=ce(d.startTime,d.endTime),b.nestedCues.push(a)),0<e.length&&(a=d.clone(),a.payload=Dc(e),b.nestedCues.push(a)),a=!1;else for(b.nestedCues.push(d),b=t(e),a=b.next();!a.done;a=b.next())wC(a.value,d,c)}
1299
+ function sC(a,b,c){var d;if(d=/^align:(start|middle|center|end|left|right)$/.exec(b))b=d[1],"middle"==b?a.textAlign=Td:a.textAlign=ee[b.toUpperCase()];else if(d=/^vertical:(lr|rl)$/.exec(b))a.writingMode="lr"==d[1]?"vertical-lr":"vertical-rl";else if(d=/^size:([\d.]+)%$/.exec(b))a.size=Number(d[1]);else if(d=/^position:([\d.]+)%(?:,(line-left|line-right|middle|center|start|end|auto))?$/.exec(b))a.position=Number(d[1]),d[2]&&(b=d[2],a.positionAlign="line-left"==b||"start"==b?"line-left":"line-right"==
1300
+ b||"end"==b?"line-right":"center"==b||"middle"==b?"center":Sd);else if(d=/^region:(.*)$/.exec(b)){if(b=yC(c,d[1]))a.region=b}else if(c=/^line:([\d.]+)%(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=1,a.line=Number(c[1]),c[2]&&(a.lineAlign=ge[c[2].toUpperCase()]);else if(c=/^line:(-?\d+)(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=Wd,a.line=Number(c[1]),c[2]&&(a.lineAlign=ge[c[2].toUpperCase()])}
1301
+ function yC(a,b){a=a.filter(function(c){return c.id==b});return a.length?a[0]:null}function qC(a){a=Mp(a,uC);if(null==a)return null;var b=Number(a[2]),c=Number(a[3]);return 59<b||59<c?null:Number(a[4])/1E3+c+60*b+3600*(Number(a[1])||0)}P("shaka.text.VttTextParser",pC);pC.prototype.parseMedia=pC.prototype.parseMedia;pC.prototype.setManifestType=pC.prototype.setManifestType;pC.prototype.setSequenceMode=pC.prototype.setSequenceMode;pC.prototype.parseInit=pC.prototype.parseInit;var uC=/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g;
1302
+ Oe["text/vtt"]=function(){return new pC};Oe['text/vtt; codecs="vtt"']=function(){return new pC};Oe['text/vtt; codecs="wvtt"']=function(){return new pC};function zC(){this.g=null}zC.prototype.parseInit=function(a){var b=this,c=!1;(new Pg).box("moov",Ug).box("trak",Ug).box("mdia",Ug).W("mdhd",function(d){d=aj(d.reader,d.version);b.g=d.timescale}).box("minf",Ug).box("stbl",Ug).W("stsd",Wg).box("wvtt",function(){c=!0}).parse(a);if(!this.g)throw new U(2,2,2008);if(!c)throw new U(2,2,2008);};zC.prototype.setSequenceMode=function(){};zC.prototype.setManifestType=function(){};
1303
+ zC.prototype.parseMedia=function(a,b){if(!a.length)return[];if(!this.g)throw new U(2,2,2008);var c=0,d=[],e,f=[],g=!1,h=!1,k=!1,l=null;(new Pg).box("moof",Ug).box("traf",Ug).W("tfdt",function(C){g=!0;c=$i(C.reader,C.version).baseMediaDecodeTime}).W("tfhd",function(C){l=Zi(C.reader,C.flags).Nd}).W("trun",function(C){h=!0;d=bj(C.reader,C.version,C.flags).$h}).box("mdat",Zg(function(C){k=!0;e=C})).parse(a,!1);if(!k&&!g&&!h)throw new U(2,2,2008);a=c;for(var m=new Mg(e,0),n=t(d),p=n.next();!p.done;p=n.next()){p=
1304
+ p.value;var r=p.Sg||l,u=p.kf?c+p.kf:a;a=u+(r||0);var v=0;do{var w=m.T();v+=w;var A=m.T(),z=null;"vttc"==Tg(A)?8<w&&(z=m.Hb(w-8)):m.skip(w-8);r&&z&&(w=AC(z,b.periodStart+u/this.g,b.periodStart+a/this.g),f.push(w))}while(p.sampleSize&&v<p.sampleSize)}return f.filter(We)};function AC(a,b,c){var d,e,f;(new Pg).box("payl",Zg(function(g){d=wc(g)})).box("iden",Zg(function(g){e=wc(g)})).box("sttg",Zg(function(g){f=wc(g)})).parse(a);return d?BC(d,e,f,b,c):null}
1305
+ function BC(a,b,c,d,e){d=new Rd(d,e,"");tC(a,d,new Map);b&&(d.id=b);if(c)for(a=new Kp(c),b=Np(a);b;)sC(d,b,[]),Lp(a),b=Np(a);return d}P("shaka.text.Mp4VttParser",zC);zC.prototype.parseMedia=zC.prototype.parseMedia;zC.prototype.setManifestType=zC.prototype.setManifestType;zC.prototype.setSequenceMode=zC.prototype.setSequenceMode;zC.prototype.parseInit=zC.prototype.parseInit;Oe['application/mp4; codecs="wvtt"']=function(){return new zC};function CC(){}CC.prototype.parseInit=function(){};CC.prototype.setSequenceMode=function(){};CC.prototype.setManifestType=function(){};CC.prototype.parseMedia=function(a){var b=wc(a).replace(/\r+/g,"");b=b.trim();a=[];if(""==b)return a;b=t(b.split("\n\n"));for(var c=b.next();!c.done;c=b.next()){c=c.value.split("\n");var d=new Kp(c[0]),e=DC(d),f=Mp(d,/,/g);d=DC(d);if(null==e||null==f||null==d)throw new U(2,2,2001,"Could not parse cue time range in SubViewer");a.push(new Rd(e,d,c.slice(1).join("\n").trim()))}return a};
1306
+ function DC(a){a=Mp(a,/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g);if(null==a)return null;var b=Number(a[2]),c=Number(a[3]);return 59<b||59<c?null:Number(a[4])/1E3+c+60*b+3600*(Number(a[1])||0)}P("shaka.text.SbvTextParser",CC);CC.prototype.parseMedia=CC.prototype.parseMedia;CC.prototype.setManifestType=CC.prototype.setManifestType;CC.prototype.setSequenceMode=CC.prototype.setSequenceMode;CC.prototype.parseInit=CC.prototype.parseInit;Oe["text/x-subviewer"]=function(){return new CC};function EC(){this.g=new pC}EC.prototype.parseInit=function(){};EC.prototype.setSequenceMode=function(){};EC.prototype.setManifestType=function(){};EC.prototype.parseMedia=function(a,b,c){a=wc(a);a=FC(a);a=Gb(Ac(a));return this.g.parseMedia(a,b,c)};
1307
+ function FC(a){var b="WEBVTT\n\n";if(""==a)return b;a=a.replace(/\r+/g,"");a=a.trim();a=t(a.split("\n\n"));for(var c=a.next();!c.done;c=a.next())c=c.value.split(/\n/),c[0].match(/\d+/)&&c.shift(),c[0]=c[0].replace(/,/g,"."),b+=c.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 b}P("shaka.text.SrtTextParser",EC);EC.srt2webvtt=FC;EC.prototype.parseMedia=EC.prototype.parseMedia;
1308
+ EC.prototype.setManifestType=EC.prototype.setManifestType;EC.prototype.setSequenceMode=EC.prototype.setSequenceMode;EC.prototype.parseInit=EC.prototype.parseInit;Oe["text/srt"]=function(){return new EC};function GC(){}GC.prototype.parseInit=function(){};GC.prototype.setSequenceMode=function(){};GC.prototype.setManifestType=function(){};
1309
+ GC.prototype.parseMedia=function(a){var b="",c="",d=null,e=null;e=wc(a).split(/\r?\n\s*\r?\n/);a=t(e);for(e=a.next();!e.done;e=a.next()){var f=e.value;e=f;if(f=HC.exec(f))d=f[1],e=f[2];"V4 Styles"==d||"V4+ Styles"==d?(b=e,b=c?b+("\n"+e):e):"Events"==d&&(c=c?c+("\n"+e):e)}d=[];e=null;b=t(b.split(/\r?\n/));for(f=b.next();!f.done;f=b.next())if(a=f.value,!/^\s*;/.test(a)&&(f=IC.exec(a)))if(a=f[1].trim(),f=f[2].trim(),"Format"==a)e=f.split(JC);else if("Style"==a){a=f.split(JC);f={};for(var g=0;g<e.length&&
1310
+ g<a.length;g++)f[e[g]]=a[g];d.push(f)}e=[];b=null;a={};c=t(c.split(/\r?\n/));for(f=c.next();!f.done;a={Gf:a.Gf},f=c.next())if(f=f.value,!/^\s*;/.test(f)&&(g=IC.exec(f)))if(f=g[1].trim(),g=g[2].trim(),"Format"==f)b=g.split(JC);else if("Dialogue"==f){g=g.split(JC);f={};for(var h=0;h<b.length&&h<g.length;h++)f[b[h]]=g[h];h=KC(f.Start);var k=KC(f.End);g=new Rd(h,k,g.slice(b.length-1).join(",").replace(/\\N/g,"\n").replace(/\{[^}]+\}/g,""));a.Gf=f.Style;(f=d.find(function(l){return function(m){return m.Name==
1311
+ l.Gf}}(a)))&&LC(g,f);e.push(g)}return e};
1312
+ function LC(a,b){var c=b.Fontname;c&&(a.fontFamily=c);if(c=b.Fontsize)a.fontSize=c+"px";if(c=b.PrimaryColour)if(c=MC(c))a.color=c;if(c=b.BackColour)if(c=MC(c))a.backgroundColor=c;b.Bold&&(a.fontWeight=700);b.Italic&&(a.fontStyle="italic");b.Underline&&a.textDecoration.push("underline");if(c=b.Spacing)a.letterSpacing=c+"px";if(c=b.Alignment)switch(parseInt(c,10)){case 1:a.displayAlign=Yd;a.textAlign="start";break;case 2:a.displayAlign=Yd;a.textAlign=Td;break;case 3:a.displayAlign=Yd;a.textAlign="end";
1312
1313
  break;case 5:a.displayAlign="before";a.textAlign="start";break;case 6:a.displayAlign="before";a.textAlign=Td;break;case 7:a.displayAlign="before";a.textAlign="end";break;case 9:a.displayAlign="center";a.textAlign="start";break;case 10:a.displayAlign="center";a.textAlign=Td;break;case 11:a.displayAlign="center",a.textAlign="end"}if(b=b.AlphaLevel)a.opacity=parseFloat(b)}
1313
- function LC(a){a=parseInt(a.replace("&H",""),16);return 0<=a?"rgba("+(a&255)+","+(a>>8&255)+","+(a>>16&255)+","+(a>>24&255^255)/255+")":null}function JC(a){a=MC.exec(a);return 3600*(a[1]?parseInt(a[1].replace(":",""),10):0)+60*parseInt(a[2],10)+parseFloat(a[3])}P("shaka.text.SsaTextParser",FC);FC.prototype.parseMedia=FC.prototype.parseMedia;FC.prototype.setManifestType=FC.prototype.setManifestType;FC.prototype.setSequenceMode=FC.prototype.setSequenceMode;FC.prototype.parseInit=FC.prototype.parseInit;
1314
- var GC=/^\s*\[([^\]]+)\]\r?\n([\s\S]*)/,HC=/^\s*([^:]+):\s*(.*)/,IC=/\s*,\s*/,MC=/^(\d+:)?(\d{1,2}):(\d{1,2}(?:[.]\d{1,3})?)?$/;Oe["text/x-ssa"]=function(){return new FC};function NC(a,b){var c=a[b+1]&1?7:9;return b+c<=a.length&&(a=((a[b+3]&3)<<11|a[b+4]<<3|(a[b+5]&224)>>>5)-c,0<a)?{Pe:c,ia:a}:null}function OC(a,b){var c=[96E3,88200,64E3,48E3,44100,32E3,24E3,22050,16E3,12E3,11025,8E3,7350],d=(a[b+2]&60)>>>2;if(d>c.length-1)return null;var e=((a[b+2]&192)>>>6)+1,f=(a[b+2]&1)<<2;f|=(a[b+3]&192)>>>6;return{sampleRate:c[d],channelCount:f,cb:"mp4a.40."+e}}
1315
- function PC(a,b){if(b+1<a.length&&255===a[b]&&240===(a[b+1]&246)){var c=a[b+1]&1?7:9;if(b+c>=a.length)return!1;var d=(a[b+3]&3)<<11|a[b+4]<<3|(a[b+5]&224)>>>5;if(d<=c)return!1;b+=d;return b===a.length||b+1<a.length&&255===a[b]&&240===(a[b+1]&246)}return!1}
1316
- function QC(a,b){switch(a){case "mp4a.40.2":if(1===b)return new Uint8Array([0,200,0,128,35,128]);if(2===b)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(3===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);if(4===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);if(5===b)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===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,
1317
- 2,0,178,0,32,8,224]);break;default:if(1===b)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===b||3===b)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};function RC(a){this.i=a;this.h=0;this.g=new Map}q=RC.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/aac"==a.toLowerCase().split(";")[0]?td(this.convertCodecs("audio",a)):!1};q.convertCodecs=function(a,b){return"audio/aac"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="'+(Ke(b)||"mp4a.40.2")+'"':b};q.getOriginalMimeType=function(){return this.i};
1318
- q.transmux=function(a,b,c,d){for(var e=Gb(a),f=Yi(e),g=f.length;g<e.length&&!PC(e,g);g++);a=1E3*c.endTime;f=Xi(f);f.length&&c&&(f=f.find(function(m){return"com.apple.streaming.transportStreamTimestamp"===m.description}))&&(a=f.data);f=OC(e,g);if(!f)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));b.audioSamplingRate=f.sampleRate;b.channelsCount=f.channelCount;for(var h=[];g<e.length;){var k=NC(e,g);if(!k)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));var l=k.Pe+k.ia;g+l<=e.length&&h.push({data:e.subarray(g+
1319
- k.Pe,g+l),size:k.ia,duration:1024,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}});g+=l}c=f.sampleRate;a=Math.floor(a*c/1E3);d={id:b.id,type:"audio",codecs:f.cb,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:c,duration:d,ub:[],ya:new Uint8Array([]),Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.h,baseMediaDecodeTime:a,rb:h},stream:b};c=new Rw([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=ix(c),this.g.set(b.id,d));b=zx(c);this.h++;b=Kc(d,b);return Promise.resolve(b)};
1320
- P("shaka.transmuxer.AacTransmuxer",RC);RC.prototype.transmux=RC.prototype.transmux;RC.prototype.getOriginalMimeType=RC.prototype.getOriginalMimeType;RC.prototype.convertCodecs=RC.prototype.convertCodecs;RC.prototype.isSupported=RC.prototype.isSupported;RC.prototype.destroy=RC.prototype.destroy;le("audio/aac",function(){return new RC("audio/aac")},re);function SC(a,b){if(b+8>a.length||11!==a[b]||119!==a[b+1])return null;var c=a[b+4]>>6;if(3<=c)return null;var d=a[b+4]&63,e=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,
1314
+ function MC(a){a=parseInt(a.replace("&H",""),16);return 0<=a?"rgba("+(a&255)+","+(a>>8&255)+","+(a>>16&255)+","+(a>>24&255^255)/255+")":null}function KC(a){a=NC.exec(a);return 3600*(a[1]?parseInt(a[1].replace(":",""),10):0)+60*parseInt(a[2],10)+parseFloat(a[3])}P("shaka.text.SsaTextParser",GC);GC.prototype.parseMedia=GC.prototype.parseMedia;GC.prototype.setManifestType=GC.prototype.setManifestType;GC.prototype.setSequenceMode=GC.prototype.setSequenceMode;GC.prototype.parseInit=GC.prototype.parseInit;
1315
+ var HC=/^\s*\[([^\]]+)\]\r?\n([\s\S]*)/,IC=/^\s*([^:]+):\s*(.*)/,JC=/\s*,\s*/,NC=/^(\d+:)?(\d{1,2}):(\d{1,2}(?:[.]\d{1,3})?)?$/;Oe["text/x-ssa"]=function(){return new GC};function OC(a,b){var c=a[b+1]&1?7:9;return b+c<=a.length&&(a=((a[b+3]&3)<<11|a[b+4]<<3|(a[b+5]&224)>>>5)-c,0<a)?{Pe:c,ia:a}:null}function PC(a,b){var c=[96E3,88200,64E3,48E3,44100,32E3,24E3,22050,16E3,12E3,11025,8E3,7350],d=(a[b+2]&60)>>>2;if(d>c.length-1)return null;var e=((a[b+2]&192)>>>6)+1,f=(a[b+2]&1)<<2;f|=(a[b+3]&192)>>>6;return{sampleRate:c[d],channelCount:f,cb:"mp4a.40."+e}}
1316
+ function QC(a,b){if(b+1<a.length&&255===a[b]&&240===(a[b+1]&246)){var c=a[b+1]&1?7:9;if(b+c>=a.length)return!1;var d=(a[b+3]&3)<<11|a[b+4]<<3|(a[b+5]&224)>>>5;if(d<=c)return!1;b+=d;return b===a.length||b+1<a.length&&255===a[b]&&240===(a[b+1]&246)}return!1}
1317
+ function RC(a,b){switch(a){case "mp4a.40.2":if(1===b)return new Uint8Array([0,200,0,128,35,128]);if(2===b)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(3===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);if(4===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);if(5===b)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===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,
1318
+ 2,0,178,0,32,8,224]);break;default:if(1===b)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===b||3===b)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};function SC(a){this.i=a;this.h=0;this.g=new Map}q=SC.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/aac"==a.toLowerCase().split(";")[0]?td(this.convertCodecs("audio",a)):!1};q.convertCodecs=function(a,b){return"audio/aac"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="'+(Ke(b)||"mp4a.40.2")+'"':b};q.getOriginalMimeType=function(){return this.i};
1319
+ q.transmux=function(a,b,c,d){for(var e=Gb(a),f=Yi(e),g=f.length;g<e.length&&!QC(e,g);g++);a=1E3*c.endTime;f=Xi(f);f.length&&c&&(f=f.find(function(m){return"com.apple.streaming.transportStreamTimestamp"===m.description}))&&(a=f.data);f=PC(e,g);if(!f)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));b.audioSamplingRate=f.sampleRate;b.channelsCount=f.channelCount;for(var h=[];g<e.length;){var k=OC(e,g);if(!k)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));var l=k.Pe+k.ia;g+l<=e.length&&h.push({data:e.subarray(g+
1320
+ k.Pe,g+l),size:k.ia,duration:1024,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}});g+=l}c=f.sampleRate;a=Math.floor(a*c/1E3);d={id:b.id,type:"audio",codecs:f.cb,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:c,duration:d,ub:[],ya:new Uint8Array([]),Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.h,baseMediaDecodeTime:a,rb:h},stream:b};c=new Sw([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=jx(c),this.g.set(b.id,d));b=Ax(c);this.h++;b=Kc(d,b);return Promise.resolve(b)};
1321
+ P("shaka.transmuxer.AacTransmuxer",SC);SC.prototype.transmux=SC.prototype.transmux;SC.prototype.getOriginalMimeType=SC.prototype.getOriginalMimeType;SC.prototype.convertCodecs=SC.prototype.convertCodecs;SC.prototype.isSupported=SC.prototype.isSupported;SC.prototype.destroy=SC.prototype.destroy;le("audio/aac",function(){return new SC("audio/aac")},re);function TC(a,b){if(b+8>a.length||11!==a[b]||119!==a[b+1])return null;var c=a[b+4]>>6;if(3<=c)return null;var d=a[b+4]&63,e=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,
1321
1322
  1024,1114,1536,1024,1115,1536,1152,1253,1728,1152,1254,1728,1280,1393,1920,1280,1394,1920][3*d+c];if(b+e>a.length)return null;var f=a[b+6]>>5,g=0;2===f?g+=2:(f&1&&1!==f&&(g+=2),f&4&&(g+=2));g=(a[b+6]<<8|a[b+7])>>12-g&1;var h=a[b+5]&7;a=new Uint8Array([c<<6|a[b+5]>>3<<1|h>>2,(h&3)<<6|f<<3|g<<2|d>>4,d<<4&224]);return{sampleRate:[48E3,44100,32E3][c],channelCount:[2,1,2,3,3,4,4,5][f]+g,ya:a,ia:e}}
1322
- function TC(a,b){if(11===a[b]&&119===a[b+1]){var c=0,d=5;b+=d;for(var e,f;0<d;){f=a[b];var g=Math.min(d,8),h=8-g;e=4278190080>>>24+h<<h;e=(f&e)>>h;c=c?c<<g|e:e;b+=1;d-=g}if(16>c)return!0}return!1};function UC(a){this.i=a;this.h=0;this.g=new Map}q=UC.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/ac3"==a.toLowerCase().split(";")[0]?td(this.convertCodecs("audio",a)):!1};q.convertCodecs=function(a,b){return"audio/ac3"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="ac-3"':b};q.getOriginalMimeType=function(){return this.i};
1323
- q.transmux=function(a,b,c,d){a=Gb(a);for(var e=Yi(a),f=e.length;f<a.length&&!TC(a,f);f++);var g=1E3*c.endTime;e=Xi(e);e.length&&c&&(e=e.find(function(m){return"com.apple.streaming.transportStreamTimestamp"===m.description}))&&(g=e.data);e=0;for(var h=new Uint8Array([]),k=[];f<a.length;){var l=SC(a,f);if(!l)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));b.audioSamplingRate=l.sampleRate;b.channelsCount=l.channelCount;e=l.sampleRate;h=l.ya;k.push({data:a.subarray(f,f+l.ia),size:l.ia,duration:1536,
1324
- wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}});f+=l.ia}c=Math.floor(g*e/1E3);d={id:b.id,type:"audio",codecs:"ac-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:e,duration:d,ub:[],ya:h,Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.h,baseMediaDecodeTime:c,rb:k},stream:b};c=new Rw([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=ix(c),this.g.set(b.id,d));b=zx(c);this.h++;b=Kc(d,b);return Promise.resolve(b)};P("shaka.transmuxer.Ac3Transmuxer",UC);UC.prototype.transmux=UC.prototype.transmux;
1325
- UC.prototype.getOriginalMimeType=UC.prototype.getOriginalMimeType;UC.prototype.convertCodecs=UC.prototype.convertCodecs;UC.prototype.isSupported=UC.prototype.isSupported;UC.prototype.destroy=UC.prototype.destroy;le("audio/ac3",function(){return new UC("audio/ac3")},re);function VC(a,b){if(b+8>a.length||2935!==(a[b]<<8|a[b+1]<<0))return null;var c=new hj(a.subarray(b+2));jj(c,2);jj(c,3);var d=kj(c,11)+1<<1,e=kj(c,2);if(3==e){e=kj(c,2);e=[24E3,22060,16E3][e];var f=3}else e=[48E3,44100,32E3][e],f=kj(c,2);var g=kj(c,3),h=kj(c,1);c=kj(c,5);if(b+d>a.byteLength)return null;a=Math.floor(d*e/(16*[1,2,3,6][f]));a=new Uint8Array([(a&8160)>>5,(a&31)<<3,e<<6|c<<1|0,0|g<<1|h<<0,0]);return{sampleRate:e,channelCount:[2,1,2,3,3,4,4,5][g]+h,ya:a,ia:d}};function WC(a){this.i=a;this.h=0;this.g=new Map}q=WC.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/ec3"==a.toLowerCase().split(";")[0]?td(this.convertCodecs("audio",a)):!1};q.convertCodecs=function(a,b){return"audio/ec3"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="ec-3"':b};q.getOriginalMimeType=function(){return this.i};
1326
- q.transmux=function(a,b,c,d){a=Gb(a);for(var e=Yi(a),f=e.length;f<a.length&&2935!==(a[f]<<8|a[f+1]<<0);f++);var g=1E3*c.endTime;e=Xi(e);e.length&&c&&(e=e.find(function(m){return"com.apple.streaming.transportStreamTimestamp"===m.description}))&&(g=e.data);e=0;for(var h=new Uint8Array([]),k=[];f<a.length;){var l=VC(a,f);if(!l)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));b.audioSamplingRate=l.sampleRate;b.channelsCount=l.channelCount;e=l.sampleRate;h=l.ya;k.push({data:a.subarray(f,f+l.ia),
1327
- size:l.ia,duration:1536,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}});f+=l.ia}c=Math.floor(g*e/1E3);d={id:b.id,type:"audio",codecs:"ec-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:e,duration:d,ub:[],ya:h,Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.h,baseMediaDecodeTime:c,rb:k},stream:b};c=new Rw([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=ix(c),this.g.set(b.id,d));b=zx(c);this.h++;b=Kc(d,b);return Promise.resolve(b)};P("shaka.transmuxer.Ec3Transmuxer",WC);WC.prototype.transmux=WC.prototype.transmux;
1328
- WC.prototype.getOriginalMimeType=WC.prototype.getOriginalMimeType;WC.prototype.convertCodecs=WC.prototype.convertCodecs;WC.prototype.isSupported=WC.prototype.isSupported;WC.prototype.destroy=WC.prototype.destroy;le("audio/ec3",function(){return new WC("audio/ec3")},re);function XC(a){if(!a.length)return null;var b=a.find(function(v){return 7==v.type});a=a.find(function(v){return 8==v.type});if(!b||!a)return null;var c=new hj(b.data),d=sj(c);sj(c);sj(c);mj(c);if(YC.includes(d)&&(d=V(c),3===d&&jj(c,1),mj(c),mj(c),jj(c,1),rj(c))){d=3!==d?8:12;for(var e=0;e<d;e++)rj(c)&&(6>e?tj(c,16):tj(c,64))}mj(c);d=V(c);if(0===d)V(c);else if(1===d)for(jj(c,1),mj(c),mj(c),d=V(c),e=0;e<d;e++)mj(c);mj(c);jj(c,1);var f=V(c),g=V(c),h=kj(c,1);0===h&&jj(c,1);jj(c,1);var k=0,l=0,m=0,n=0;
1329
- rj(c)&&(k=V(c),l=V(c),m=V(c),n=V(c));e=d=1;if(rj(c)&&rj(c)){var p=sj(c),r=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2],u=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1];0<p&&16>=p?(d=r[p-1],e=u[p-1]):255===p&&(d=kj(c,16),e=kj(c,16))}c=(2-h)*(g+1)*16-2*m-2*n;f=16*(f+1)-2*k-2*l;k=[];b=b.fullData;k.push(b.byteLength>>>8&255);k.push(b.byteLength&255);k=k.concat.apply(k,x(b));b=[];a=a.fullData;b.push(a.byteLength>>>8&255);b.push(a.byteLength&255);b=b.concat.apply(b,x(a));a=new Uint8Array([1,k[3],k[4],
1323
+ function UC(a,b){if(11===a[b]&&119===a[b+1]){var c=0,d=5;b+=d;for(var e,f;0<d;){f=a[b];var g=Math.min(d,8),h=8-g;e=4278190080>>>24+h<<h;e=(f&e)>>h;c=c?c<<g|e:e;b+=1;d-=g}if(16>c)return!0}return!1};function VC(a){this.i=a;this.h=0;this.g=new Map}q=VC.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/ac3"==a.toLowerCase().split(";")[0]?td(this.convertCodecs("audio",a)):!1};q.convertCodecs=function(a,b){return"audio/ac3"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="ac-3"':b};q.getOriginalMimeType=function(){return this.i};
1324
+ q.transmux=function(a,b,c,d){a=Gb(a);for(var e=Yi(a),f=e.length;f<a.length&&!UC(a,f);f++);var g=1E3*c.endTime;e=Xi(e);e.length&&c&&(e=e.find(function(m){return"com.apple.streaming.transportStreamTimestamp"===m.description}))&&(g=e.data);e=0;for(var h=new Uint8Array([]),k=[];f<a.length;){var l=TC(a,f);if(!l)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));b.audioSamplingRate=l.sampleRate;b.channelsCount=l.channelCount;e=l.sampleRate;h=l.ya;k.push({data:a.subarray(f,f+l.ia),size:l.ia,duration:1536,
1325
+ wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}});f+=l.ia}c=Math.floor(g*e/1E3);d={id:b.id,type:"audio",codecs:"ac-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:e,duration:d,ub:[],ya:h,Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.h,baseMediaDecodeTime:c,rb:k},stream:b};c=new Sw([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=jx(c),this.g.set(b.id,d));b=Ax(c);this.h++;b=Kc(d,b);return Promise.resolve(b)};P("shaka.transmuxer.Ac3Transmuxer",VC);VC.prototype.transmux=VC.prototype.transmux;
1326
+ VC.prototype.getOriginalMimeType=VC.prototype.getOriginalMimeType;VC.prototype.convertCodecs=VC.prototype.convertCodecs;VC.prototype.isSupported=VC.prototype.isSupported;VC.prototype.destroy=VC.prototype.destroy;le("audio/ac3",function(){return new VC("audio/ac3")},re);function WC(a,b){if(b+8>a.length||2935!==(a[b]<<8|a[b+1]<<0))return null;var c=new hj(a.subarray(b+2));jj(c,2);jj(c,3);var d=kj(c,11)+1<<1,e=kj(c,2);if(3==e){e=kj(c,2);e=[24E3,22060,16E3][e];var f=3}else e=[48E3,44100,32E3][e],f=kj(c,2);var g=kj(c,3),h=kj(c,1);c=kj(c,5);if(b+d>a.byteLength)return null;a=Math.floor(d*e/(16*[1,2,3,6][f]));a=new Uint8Array([(a&8160)>>5,(a&31)<<3,e<<6|c<<1|0,0|g<<1|h<<0,0]);return{sampleRate:e,channelCount:[2,1,2,3,3,4,4,5][g]+h,ya:a,ia:d}};function XC(a){this.i=a;this.h=0;this.g=new Map}q=XC.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/ec3"==a.toLowerCase().split(";")[0]?td(this.convertCodecs("audio",a)):!1};q.convertCodecs=function(a,b){return"audio/ec3"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="ec-3"':b};q.getOriginalMimeType=function(){return this.i};
1327
+ q.transmux=function(a,b,c,d){a=Gb(a);for(var e=Yi(a),f=e.length;f<a.length&&2935!==(a[f]<<8|a[f+1]<<0);f++);var g=1E3*c.endTime;e=Xi(e);e.length&&c&&(e=e.find(function(m){return"com.apple.streaming.transportStreamTimestamp"===m.description}))&&(g=e.data);e=0;for(var h=new Uint8Array([]),k=[];f<a.length;){var l=WC(a,f);if(!l)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));b.audioSamplingRate=l.sampleRate;b.channelsCount=l.channelCount;e=l.sampleRate;h=l.ya;k.push({data:a.subarray(f,f+l.ia),
1328
+ size:l.ia,duration:1536,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}});f+=l.ia}c=Math.floor(g*e/1E3);d={id:b.id,type:"audio",codecs:"ec-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:e,duration:d,ub:[],ya:h,Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.h,baseMediaDecodeTime:c,rb:k},stream:b};c=new Sw([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=jx(c),this.g.set(b.id,d));b=Ax(c);this.h++;b=Kc(d,b);return Promise.resolve(b)};P("shaka.transmuxer.Ec3Transmuxer",XC);XC.prototype.transmux=XC.prototype.transmux;
1329
+ XC.prototype.getOriginalMimeType=XC.prototype.getOriginalMimeType;XC.prototype.convertCodecs=XC.prototype.convertCodecs;XC.prototype.isSupported=XC.prototype.isSupported;XC.prototype.destroy=XC.prototype.destroy;le("audio/ec3",function(){return new XC("audio/ec3")},re);function YC(a){if(!a.length)return null;var b=a.find(function(v){return 7==v.type});a=a.find(function(v){return 8==v.type});if(!b||!a)return null;var c=new hj(b.data),d=sj(c);sj(c);sj(c);mj(c);if(ZC.includes(d)&&(d=V(c),3===d&&jj(c,1),mj(c),mj(c),jj(c,1),oj(c))){d=3!==d?8:12;for(var e=0;e<d;e++)oj(c)&&(6>e?tj(c,16):tj(c,64))}mj(c);d=V(c);if(0===d)V(c);else if(1===d)for(jj(c,1),mj(c),mj(c),d=V(c),e=0;e<d;e++)mj(c);mj(c);jj(c,1);var f=V(c),g=V(c),h=kj(c,1);0===h&&jj(c,1);jj(c,1);var k=0,l=0,m=0,n=0;
1330
+ oj(c)&&(k=V(c),l=V(c),m=V(c),n=V(c));e=d=1;if(oj(c)&&oj(c)){var p=sj(c),r=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2],u=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1];0<p&&16>=p?(d=r[p-1],e=u[p-1]):255===p&&(d=kj(c,16),e=kj(c,16))}c=(2-h)*(g+1)*16-2*m-2*n;f=16*(f+1)-2*k-2*l;k=[];b=b.fullData;k.push(b.byteLength>>>8&255);k.push(b.byteLength&255);k=k.concat.apply(k,x(b));b=[];a=a.fullData;b.push(a.byteLength>>>8&255);b.push(a.byteLength&255);b=b.concat.apply(b,x(a));a=new Uint8Array([1,k[3],k[4],
1330
1331
  k[5],255,225].concat(k,[1],b));return{height:c,width:f,Ma:a,Sa:d,Ua:e}}
1331
- function ZC(a){var b=!1,c=[],d=a.find(function(k){return 7==k.type}),e=!1;a=t(a);for(var f=a.next();!f.done;f=a.next()){f=f.value;var g=!1;switch(f.type){case 1:g=e=!0;var h=f.data;d&&4<h.length&&(h=uj(new hj(h)),2===h||4===h||7===h||9===h)&&(b=!0);break;case 5:b=g=e=!0;break;case 6:g=!0;break;case 7:g=!0;break;case 8:g=!0;break;case 9:e=g=!0;break;case 12:g=!0;break;default:g=!1}e&&g&&(g=f.fullData.byteLength,h=new Uint8Array(4),h[0]=g>>24&255,h[1]=g>>16&255,h[2]=g>>8&255,h[3]=g&255,c.push(h),c.push(f.fullData))}return c.length?
1332
- {data:Kc.apply(Ec,x(c)),Yd:b}:null}var YC=[100,110,122,244,44,83,86,118,128,138,139,134];function $C(a){if(!a.length)return null;var b=a.find(function(g){return 32==g.type}),c=a.find(function(g){return 33==g.type}),d=a.find(function(g){return 34==g.type});if(!b||!c||!d)return null;var e=aD(b.fullData);a=bD(c.fullData);var f=cD(d.fullData);b=dD(b.fullData,c.fullData,d.fullData,{Kg:e.Kg,gh:e.gh,ng:a.ng,og:a.og,hg:a.hg,mg:a.mg,ig:a.ig,jg:a.jg,kg:a.kg,lg:a.lg,ag:a.ag,cg:a.cg,dg:a.dg,eg:a.eg,fg:a.fg,gg:a.gg,Yf:a.Yf,Ye:a.Ye,Wf:a.Wf,Tf:a.Tf,Sf:a.Sf,Ng:f.Ng});return{height:a.height,width:a.width,
1333
- Ma:b,Sa:a.nk,Ua:a.lk}}function aD(a){var b=new hj(a,!0);sj(b);sj(b);kj(b,4);kj(b,2);kj(b,6);a=kj(b,3);b=rj(b);return{Kg:a+1,gh:b}}
1334
- function bD(a){a=new hj(a,!0);sj(a);sj(a);var b=0,c=0,d=0,e=0;kj(a,4);var f=kj(a,3);rj(a);for(var g=kj(a,2),h=kj(a,1),k=kj(a,5),l=sj(a),m=sj(a),n=sj(a),p=sj(a),r=sj(a),u=sj(a),v=sj(a),w=sj(a),A=sj(a),z=sj(a),C=sj(a),y=[],B=[],D=0;D<f;D++)y.push(rj(a)),B.push(rj(a));if(0<f)for(D=f;8>D;D++)kj(a,2);for(D=0;D<f;D++)y[D]&&kj(a,88),B[D]&&sj(a);V(a);y=V(a);3==y&&kj(a,1);B=V(a);D=V(a);rj(a)&&(b+=V(a),c+=V(a),d+=V(a),e+=V(a));var K=V(a),G=V(a),J=V(a);if(rj(a))for(var I=0;I<=f;I++)V(a),V(a),V(a);else V(a),
1335
- V(a),V(a);V(a);V(a);V(a);V(a);V(a);V(a);if(rj(a)&&rj(a))for(I=0;4>I;I++)for(var H=0;H<(3===I?2:6);H++)if(rj(a)){var N=Math.min(64,1<<4+(I<<1));1<I&&nj(a);for(var L=0;L<N;L++)nj(a)}else V(a);rj(a);rj(a);rj(a)&&(sj(a),V(a),V(a),rj(a));I=V(a);for(N=H=0;N<I;N++)if(L=!1,0!==N&&(L=rj(a)),L){N===I&&V(a);rj(a);V(a);for(var M=L=0;M<=H;M++){var Q=rj(a),T=!1;Q||(T=rj(a));(Q||T)&&L++}H=L}else{M=V(a);L=V(a);H=M+L;for(Q=0;Q<M;Q++)V(a),rj(a);for(M=0;M<L;M++)V(a),rj(a)}if(rj(a))for(I=V(a),H=0;H<I;H++){for(N=0;N<
1336
- J+4;N++)kj(a,1);kj(a,1)}I=J=1;H=0;rj(a);rj(a);if(rj(a)){rj(a)&&(N=sj(a),L=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2],M=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1],0<N&&16>=N?(J=L[N-1],I=M[N-1]):255===N&&(J=kj(a,16),I=kj(a,16)));rj(a)&&rj(a);rj(a)&&(kj(a,3),rj(a),rj(a)&&(sj(a),sj(a),sj(a)));rj(a)&&(V(a),V(a));rj(a);rj(a);rj(a);if(N=rj(a))V(a),V(a),V(a),V(a);if(rj(a)&&(kj(a,32),kj(a,32),rj(a)&&V(a),rj(a))){M=!1;N=rj(a);L=rj(a);if(N||L){if(M=rj(a))sj(a),kj(a,5),rj(a),kj(a,5);kj(a,4);kj(a,4);M&&
1337
- kj(a,4);kj(a,5);kj(a,5);kj(a,5)}for(Q=0;Q<=f;Q++){var R=!0;T=1;rj(a)||(R=rj(a));var ra=!1;R?V(a):ra=rj(a);ra||(T=V(a)+1);if(N){for(R=0;R<T;R++)V(a),V(a),M&&(V(a),V(a));rj(a)}if(L){for(R=0;R<T;R++)V(a),V(a),M&&(V(a),V(a));rj(a)}}}rj(a)&&(rj(a),rj(a),rj(a),H=V(a),V(a),V(a),V(a),V(a))}return{hg:C,ng:g,og:h,mg:k,ig:l,jg:m,kg:n,lg:p,ag:r,cg:u,dg:v,eg:w,fg:A,gg:z,Ye:H,Yf:0,Wf:y,Tf:K,Sf:G,width:B-(b+c)*(1===y||2===y?2:1),height:D-(d+e)*(1===y?2:1),nk:J,lk:I}}
1338
- function cD(a){var b=new hj(a,!0);sj(b);sj(b);V(b);V(b);rj(b);rj(b);kj(b,3);rj(b);rj(b);V(b);V(b);nj(b);rj(b);rj(b);rj(b)&&V(b);nj(b);nj(b);rj(b);rj(b);rj(b);rj(b);a=rj(b);b=rj(b);var c=1;b&&a?c=0:b?c=3:a&&(c=2);return{Ng:c}}
1339
- function dD(a,b,c,d){var e=new Uint8Array(23+(5+a.byteLength)+(5+b.byteLength)+(5+c.byteLength));e[0]=1;e[1]=(d.ng&3)<<6|(d.og?1:0)<<5|d.mg&31;e[2]=d.ig;e[3]=d.jg;e[4]=d.kg;e[5]=d.lg;e[6]=d.ag;e[7]=d.cg;e[8]=d.dg;e[9]=d.eg;e[10]=d.fg;e[11]=d.gg;e[12]=d.hg;e[13]=240|(d.Ye&3840)>>8;e[14]=d.Ye&255;e[15]=252|d.Ng&3;e[16]=252|d.Wf&3;e[17]=248|d.Tf&7;e[18]=248|d.Sf&7;e[19]=0;e[20]=0;e[21]=(d.Yf&3)<<6|(d.Kg&7)<<3|(d.gh?1:0)<<2|3;e[22]=3;e[23]=160;e[24]=0;e[25]=1;e[26]=(a.byteLength&65280)>>8;e[27]=(a.byteLength&
1340
- 255)>>0;e.set(a,28);e[23+(5+a.byteLength)]=161;e[a.byteLength+29]=0;e[a.byteLength+30]=1;e[a.byteLength+31]=(b.byteLength&65280)>>8;e[a.byteLength+32]=(b.byteLength&255)>>0;e.set(b,a.byteLength+33);e[23+(a.byteLength+10+b.byteLength)]=162;e[a.byteLength+10+b.byteLength+24]=0;e[a.byteLength+10+b.byteLength+25]=1;e[a.byteLength+10+b.byteLength+26]=(c.byteLength&65280)>>8;e[a.byteLength+10+b.byteLength+27]=(c.byteLength&255)>>0;e.set(c,a.byteLength+10+b.byteLength+28);return e};function eD(a,b){var c=a[b+1]>>3&3,d=a[b+1]>>1&3,e=a[b+2]>>4&15,f=a[b+2]>>2&3;if(1!==c&&0!==e&&15!==e&&3!==f){var g=a[b+3]>>6;e=1E3*fD[14*(3===c?3-d:3===d?3:4)+e-1];f=gD[3*(3===c?0:2===c?1:2)+f];c=hD[c][d];var h=iD[d],k=Math.floor(c*e/f+(a[b+2]>>1&1))*h,l=(navigator.userAgent||"").match(/Chrome\/(\d+)/i);(l=l?parseInt(l[1],10):0)&&87>=l&&2===d&&224E3<=e&&0===g&&(a[b+3]|=128);return{sampleRate:f,channelCount:3===g?1:2,ia:k,kk:8*c*h}}return null}
1341
- function jD(a,b){return 255===a[b]&&224===(a[b+1]&224)&&0!==(a[b+1]&6)}function kD(a,b){if(b+1<a.length&&jD(a,b)){var c=eD(a,b),d=4;c&&c.ia&&(d=c.ia);b+=d;return b===a.length||b+1<a.length&&jD(a,b)}return!1}
1342
- var fD=[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],gD=[44100,48E3,32E3,22050,24E3,16E3,11025,12E3,8E3],hD=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],iD=[0,1,1,4];function lD(a){this.i=a;this.h=0;this.g=new Map}q=lD.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/mpeg"==a.toLowerCase().split(";")[0]?td(this.convertCodecs("audio",a)):!1};q.convertCodecs=function(a,b){return"audio/mpeg"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="mp3"':b};q.getOriginalMimeType=function(){return this.i};
1343
- q.transmux=function(a,b,c,d){for(var e=Gb(a),f=Yi(e).length;f<e.length&&!kD(e,f);f++);var g;for(a=[];f<e.length;){var h=eD(e,f);if(!h)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));g||(g=h);f+h.ia<=e.length&&a.push({data:e.subarray(f,f+h.ia),size:h.ia,duration:1152,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}});f+=h.ia}if(!g)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));c=9E4*g.kk/g.sampleRate*this.h;d={id:b.id,type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:g.sampleRate,
1344
- duration:d,ub:[],ya:new Uint8Array([]),Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.h,baseMediaDecodeTime:c,rb:a},stream:b};g=new Rw([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=ix(g),this.g.set(b.id,d));b=zx(g);this.h++;b=Kc(d,b);return Promise.resolve(b)};P("shaka.transmuxer.Mp3Transmuxer",lD);lD.prototype.transmux=lD.prototype.transmux;lD.prototype.getOriginalMimeType=lD.prototype.getOriginalMimeType;lD.prototype.convertCodecs=lD.prototype.convertCodecs;lD.prototype.isSupported=lD.prototype.isSupported;
1345
- lD.prototype.destroy=lD.prototype.destroy;le("audio/mpeg",function(){return new lD("audio/mpeg")},re);function mD(a){this.h=a;this.g=null}q=mD.prototype;q.destroy=function(){};q.isSupported=function(a){if("video/mp2t"!=a.toLowerCase().split(";")[0])return!1;var b=Ke(a).split(","),c=Pc("audio",b);b=Pc("video",b);return!c||b||"mp3"!=Ge(c)?!1:td(this.convertCodecs("audio",a))};q.convertCodecs=function(a,b){return"video/mp2t"==b.toLowerCase().split(";")[0]?"audio/mpeg":b};q.getOriginalMimeType=function(){return this.h};
1346
- q.transmux=function(a,b,c,d,e){this.g?this.g.clearData():this.g=new vj;a=Gb(a);a=this.g.parse(a);if("mp3"!=a.Od().audio||"audio"!=e)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));c=new Uint8Array([]);e=t(a.fc());for(a=e.next();!a.done;a=e.next())if(a=a.value.data)for(b=0;b<a.length;)(d=eD(a,b))?(b+d.ia<=a.length&&(c=Kc(c,a.subarray(b,b+d.ia))),b+=d.ia):b++;return Promise.resolve(c)};P("shaka.transmuxer.MpegTsTransmuxer",mD);mD.prototype.transmux=mD.prototype.transmux;
1347
- mD.prototype.getOriginalMimeType=mD.prototype.getOriginalMimeType;mD.prototype.convertCodecs=mD.prototype.convertCodecs;mD.prototype.isSupported=mD.prototype.isSupported;mD.prototype.destroy=mD.prototype.destroy;le("video/mp2t",function(){return new mD("video/mp2t")},qe);/*
1332
+ function $C(a){var b=!1,c=[],d=a.find(function(k){return 7==k.type}),e=!1;a=t(a);for(var f=a.next();!f.done;f=a.next()){f=f.value;var g=!1;switch(f.type){case 1:g=e=!0;var h=f.data;d&&4<h.length&&(h=uj(new hj(h)),2===h||4===h||7===h||9===h)&&(b=!0);break;case 5:b=g=e=!0;break;case 6:g=!0;break;case 7:g=!0;break;case 8:g=!0;break;case 9:e=g=!0;break;case 12:g=!0;break;default:g=!1}e&&g&&(g=f.fullData.byteLength,h=new Uint8Array(4),h[0]=g>>24&255,h[1]=g>>16&255,h[2]=g>>8&255,h[3]=g&255,c.push(h),c.push(f.fullData))}return c.length?
1333
+ {data:Kc.apply(Ec,x(c)),Yd:b}:null}var ZC=[100,110,122,244,44,83,86,118,128,138,139,134];function aD(a){if(!a.length)return null;var b=a.find(function(g){return 32==g.type}),c=a.find(function(g){return 33==g.type}),d=a.find(function(g){return 34==g.type});if(!b||!c||!d)return null;var e=bD(b.fullData);a=cD(c.fullData);var f=dD(d.fullData);b=eD(b.fullData,c.fullData,d.fullData,{Kg:e.Kg,gh:e.gh,ng:a.ng,og:a.og,hg:a.hg,mg:a.mg,ig:a.ig,jg:a.jg,kg:a.kg,lg:a.lg,ag:a.ag,cg:a.cg,dg:a.dg,eg:a.eg,fg:a.fg,gg:a.gg,Yf:a.Yf,Ye:a.Ye,Wf:a.Wf,Tf:a.Tf,Sf:a.Sf,Ng:f.Ng});return{height:a.height,width:a.width,
1334
+ Ma:b,Sa:a.nk,Ua:a.lk}}function bD(a){var b=new hj(a,!0);sj(b);sj(b);kj(b,4);kj(b,2);kj(b,6);a=kj(b,3);b=oj(b);return{Kg:a+1,gh:b}}
1335
+ function cD(a){a=new hj(a,!0);sj(a);sj(a);var b=0,c=0,d=0,e=0;kj(a,4);var f=kj(a,3);oj(a);for(var g=kj(a,2),h=kj(a,1),k=kj(a,5),l=sj(a),m=sj(a),n=sj(a),p=sj(a),r=sj(a),u=sj(a),v=sj(a),w=sj(a),A=sj(a),z=sj(a),C=sj(a),y=[],B=[],D=0;D<f;D++)y.push(oj(a)),B.push(oj(a));if(0<f)for(D=f;8>D;D++)kj(a,2);for(D=0;D<f;D++)y[D]&&kj(a,88),B[D]&&sj(a);V(a);y=V(a);3==y&&kj(a,1);B=V(a);D=V(a);oj(a)&&(b+=V(a),c+=V(a),d+=V(a),e+=V(a));var K=V(a),G=V(a),J=V(a);if(oj(a))for(var I=0;I<=f;I++)V(a),V(a),V(a);else V(a),
1336
+ V(a),V(a);V(a);V(a);V(a);V(a);V(a);V(a);if(oj(a)&&oj(a))for(I=0;4>I;I++)for(var H=0;H<(3===I?2:6);H++)if(oj(a)){var N=Math.min(64,1<<4+(I<<1));1<I&&nj(a);for(var L=0;L<N;L++)nj(a)}else V(a);oj(a);oj(a);oj(a)&&(sj(a),V(a),V(a),oj(a));I=V(a);for(N=H=0;N<I;N++)if(L=!1,0!==N&&(L=oj(a)),L){N===I&&V(a);oj(a);V(a);for(var M=L=0;M<=H;M++){var Q=oj(a),T=!1;Q||(T=oj(a));(Q||T)&&L++}H=L}else{M=V(a);L=V(a);H=M+L;for(Q=0;Q<M;Q++)V(a),oj(a);for(M=0;M<L;M++)V(a),oj(a)}if(oj(a))for(I=V(a),H=0;H<I;H++){for(N=0;N<
1337
+ J+4;N++)kj(a,1);kj(a,1)}I=J=1;H=0;oj(a);oj(a);if(oj(a)){oj(a)&&(N=sj(a),L=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2],M=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1],0<N&&16>=N?(J=L[N-1],I=M[N-1]):255===N&&(J=kj(a,16),I=kj(a,16)));oj(a)&&oj(a);oj(a)&&(kj(a,3),oj(a),oj(a)&&(sj(a),sj(a),sj(a)));oj(a)&&(V(a),V(a));oj(a);oj(a);oj(a);if(N=oj(a))V(a),V(a),V(a),V(a);if(oj(a)&&(kj(a,32),kj(a,32),oj(a)&&V(a),oj(a))){M=!1;N=oj(a);L=oj(a);if(N||L){if(M=oj(a))sj(a),kj(a,5),oj(a),kj(a,5);kj(a,4);kj(a,4);M&&
1338
+ kj(a,4);kj(a,5);kj(a,5);kj(a,5)}for(Q=0;Q<=f;Q++){var R=!0;T=1;oj(a)||(R=oj(a));var ra=!1;R?V(a):ra=oj(a);ra||(T=V(a)+1);if(N){for(R=0;R<T;R++)V(a),V(a),M&&(V(a),V(a));oj(a)}if(L){for(R=0;R<T;R++)V(a),V(a),M&&(V(a),V(a));oj(a)}}}oj(a)&&(oj(a),oj(a),oj(a),H=V(a),V(a),V(a),V(a),V(a))}return{hg:C,ng:g,og:h,mg:k,ig:l,jg:m,kg:n,lg:p,ag:r,cg:u,dg:v,eg:w,fg:A,gg:z,Ye:H,Yf:0,Wf:y,Tf:K,Sf:G,width:B-(b+c)*(1===y||2===y?2:1),height:D-(d+e)*(1===y?2:1),nk:J,lk:I}}
1339
+ function dD(a){var b=new hj(a,!0);sj(b);sj(b);V(b);V(b);oj(b);oj(b);kj(b,3);oj(b);oj(b);V(b);V(b);nj(b);oj(b);oj(b);oj(b)&&V(b);nj(b);nj(b);oj(b);oj(b);oj(b);oj(b);a=oj(b);b=oj(b);var c=1;b&&a?c=0:b?c=3:a&&(c=2);return{Ng:c}}
1340
+ function eD(a,b,c,d){var e=new Uint8Array(23+(5+a.byteLength)+(5+b.byteLength)+(5+c.byteLength));e[0]=1;e[1]=(d.ng&3)<<6|(d.og?1:0)<<5|d.mg&31;e[2]=d.ig;e[3]=d.jg;e[4]=d.kg;e[5]=d.lg;e[6]=d.ag;e[7]=d.cg;e[8]=d.dg;e[9]=d.eg;e[10]=d.fg;e[11]=d.gg;e[12]=d.hg;e[13]=240|(d.Ye&3840)>>8;e[14]=d.Ye&255;e[15]=252|d.Ng&3;e[16]=252|d.Wf&3;e[17]=248|d.Tf&7;e[18]=248|d.Sf&7;e[19]=0;e[20]=0;e[21]=(d.Yf&3)<<6|(d.Kg&7)<<3|(d.gh?1:0)<<2|3;e[22]=3;e[23]=160;e[24]=0;e[25]=1;e[26]=(a.byteLength&65280)>>8;e[27]=(a.byteLength&
1341
+ 255)>>0;e.set(a,28);e[23+(5+a.byteLength)]=161;e[a.byteLength+29]=0;e[a.byteLength+30]=1;e[a.byteLength+31]=(b.byteLength&65280)>>8;e[a.byteLength+32]=(b.byteLength&255)>>0;e.set(b,a.byteLength+33);e[23+(a.byteLength+10+b.byteLength)]=162;e[a.byteLength+10+b.byteLength+24]=0;e[a.byteLength+10+b.byteLength+25]=1;e[a.byteLength+10+b.byteLength+26]=(c.byteLength&65280)>>8;e[a.byteLength+10+b.byteLength+27]=(c.byteLength&255)>>0;e.set(c,a.byteLength+10+b.byteLength+28);return e};function fD(a,b){var c=a[b+1]>>3&3,d=a[b+1]>>1&3,e=a[b+2]>>4&15,f=a[b+2]>>2&3;if(1!==c&&0!==e&&15!==e&&3!==f){var g=a[b+3]>>6;e=1E3*gD[14*(3===c?3-d:3===d?3:4)+e-1];f=hD[3*(3===c?0:2===c?1:2)+f];c=iD[c][d];var h=jD[d],k=Math.floor(c*e/f+(a[b+2]>>1&1))*h,l=(navigator.userAgent||"").match(/Chrome\/(\d+)/i);(l=l?parseInt(l[1],10):0)&&87>=l&&2===d&&224E3<=e&&0===g&&(a[b+3]|=128);return{sampleRate:f,channelCount:3===g?1:2,ia:k,kk:8*c*h}}return null}
1342
+ function kD(a,b){return 255===a[b]&&224===(a[b+1]&224)&&0!==(a[b+1]&6)}function lD(a,b){if(b+1<a.length&&kD(a,b)){var c=fD(a,b),d=4;c&&c.ia&&(d=c.ia);b+=d;return b===a.length||b+1<a.length&&kD(a,b)}return!1}
1343
+ var gD=[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],hD=[44100,48E3,32E3,22050,24E3,16E3,11025,12E3,8E3],iD=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],jD=[0,1,1,4];function mD(a){this.i=a;this.h=0;this.g=new Map}q=mD.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/mpeg"==a.toLowerCase().split(";")[0]?td(this.convertCodecs("audio",a)):!1};q.convertCodecs=function(a,b){return"audio/mpeg"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="mp3"':b};q.getOriginalMimeType=function(){return this.i};
1344
+ q.transmux=function(a,b,c,d){for(var e=Gb(a),f=Yi(e).length;f<e.length&&!lD(e,f);f++);var g;for(a=[];f<e.length;){var h=fD(e,f);if(!h)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));g||(g=h);f+h.ia<=e.length&&a.push({data:e.subarray(f,f+h.ia),size:h.ia,duration:1152,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}});f+=h.ia}if(!g)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));c=9E4*g.kk/g.sampleRate*this.h;d={id:b.id,type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:g.sampleRate,
1345
+ duration:d,ub:[],ya:new Uint8Array([]),Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.h,baseMediaDecodeTime:c,rb:a},stream:b};g=new Sw([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=jx(g),this.g.set(b.id,d));b=Ax(g);this.h++;b=Kc(d,b);return Promise.resolve(b)};P("shaka.transmuxer.Mp3Transmuxer",mD);mD.prototype.transmux=mD.prototype.transmux;mD.prototype.getOriginalMimeType=mD.prototype.getOriginalMimeType;mD.prototype.convertCodecs=mD.prototype.convertCodecs;mD.prototype.isSupported=mD.prototype.isSupported;
1346
+ mD.prototype.destroy=mD.prototype.destroy;le("audio/mpeg",function(){return new mD("audio/mpeg")},re);function nD(a){this.h=a;this.g=null}q=nD.prototype;q.destroy=function(){};q.isSupported=function(a){if("video/mp2t"!=a.toLowerCase().split(";")[0])return!1;var b=Ke(a).split(","),c=Pc("audio",b);b=Pc("video",b);return!c||b||"mp3"!=Ge(c)?!1:td(this.convertCodecs("audio",a))};q.convertCodecs=function(a,b){return"video/mp2t"==b.toLowerCase().split(";")[0]?"audio/mpeg":b};q.getOriginalMimeType=function(){return this.h};
1347
+ q.transmux=function(a,b,c,d,e){this.g?this.g.clearData():this.g=new vj;a=Gb(a);a=this.g.parse(a);if("mp3"!=a.Od().audio||"audio"!=e)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));c=new Uint8Array([]);e=t(a.fc());for(a=e.next();!a.done;a=e.next())if(a=a.value.data)for(b=0;b<a.length;)(d=fD(a,b))?(b+d.ia<=a.length&&(c=Kc(c,a.subarray(b,b+d.ia))),b+=d.ia):b++;return Promise.resolve(c)};P("shaka.transmuxer.MpegTsTransmuxer",nD);nD.prototype.transmux=nD.prototype.transmux;
1348
+ nD.prototype.getOriginalMimeType=nD.prototype.getOriginalMimeType;nD.prototype.convertCodecs=nD.prototype.convertCodecs;nD.prototype.isSupported=nD.prototype.isSupported;nD.prototype.destroy=nD.prototype.destroy;le("video/mp2t",function(){return new nD("video/mp2t")},qe);/*
1348
1349
  @license
1349
1350
  MSS Transmuxer
1350
1351
  Copyright 2015 Dash Industry Forum
1351
1352
  SPDX-License-Identifier: BSD-3-Clause
1352
1353
  */
1353
- function nD(a){this.h=a;(this.g=cv.get("ISOBoxer")())&&oD(this)}
1354
- function oD(a){function b(){this._procFullBox();this.flags&1&&(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(c){this._procEntryField(c,"InitializationVector","data",8);this.flags&2&&(this._procEntryField(c,"NumberOfEntries","uint",16),this._procSubEntries(c,"clearAndCryptedData",c.NumberOfEntries,function(d){this._procEntryField(d,"BytesOfClearData",
1354
+ function oD(a){this.h=a;(this.g=dv.get("ISOBoxer")())&&pD(this)}
1355
+ function pD(a){function b(){this._procFullBox();this.flags&1&&(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(c){this._procEntryField(c,"InitializationVector","data",8);this.flags&2&&(this._procEntryField(c,"NumberOfEntries","uint",16),this._procSubEntries(c,"clearAndCryptedData",c.NumberOfEntries,function(d){this._procEntryField(d,"BytesOfClearData",
1355
1356
  "uint",16);this._procEntryField(d,"BytesOfEncryptedData","uint",32)}))})}a.g.addBoxProcessor("saio",function(){this._procFullBox();this.flags&1&&(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)});a.g.addBoxProcessor("saiz",function(){this._procFullBox();this.flags&1&&(this._procField("aux_info_type","uint",32),this._procField("aux_info_type_parameter",
1356
- "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)});a.g.addBoxProcessor("senc",b);a.g.addBoxProcessor("uuid",function(){for(var c=!0,d=0;16>d;d++)this.usertype[d]!==pD[d]&&(c=!1);c&&(this._parsing&&(this.type="sepiff"),b.call(this))})}q=nD.prototype;q.destroy=function(){};
1357
+ "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)});a.g.addBoxProcessor("senc",b);a.g.addBoxProcessor("uuid",function(){for(var c=!0,d=0;16>d;d++)this.usertype[d]!==qD[d]&&(c=!1);c&&(this._parsing&&(this.type="sepiff"),b.call(this))})}q=oD.prototype;q.destroy=function(){};
1357
1358
  q.isSupported=function(a,b){var c=a.startsWith("mss/");if(!this.g||!c)return!1;if(b)return td(this.convertCodecs(b,a));b=this.convertCodecs("audio",a);a=this.convertCodecs("video",a);return td(b)||td(a)};q.convertCodecs=function(a,b){return b.replace("mss/","")};q.getOriginalMimeType=function(){return this.h};
1358
1359
  q.transmux=function(a,b,c){if(!c)return Promise.resolve(Gb(a));if(!b.mssPrivateData)return Promise.reject(new U(2,3,3020,c?c.P()[0]:null));try{var d,e=this.g.parseBuffer(a),f=e.fetch("tfhd");f.track_ID=b.id+1;var g=e.fetch("tfdt"),h=e.fetch("traf");null===g&&(g=this.g.createFullBox("tfdt",h,f),g.version=1,g.flags=0,g.baseMediaDecodeTime=Math.floor(c.startTime*b.mssPrivateData.timescale));var k=e.fetch("trun"),l=e.fetch("tfxd");l&&l._parent.boxes.splice(l._parent.boxes.indexOf(l),1);var m=e.fetch("tfrf");
1359
1360
  m&&m._parent.boxes.splice(m._parent.boxes.indexOf(m),1);var n=e.fetch("sepiff");if(null!==n){n.type="senc";n.usertype=void 0;var p=e.fetch("saio");if(null===p){p=this.g.createFullBox("saio",h);p.version=0;p.flags=0;p.entry_count=1;p.offset=[0];var r=this.g.createFullBox("saiz",h);r.version=0;r.flags=0;r.sample_count=n.sample_count;r.default_sample_info_size=0;r.sample_info_size=[];if(n.flags&2)for(d=0;d<n.sample_count;d+=1)r.sample_info_size[d]=10+6*n.entry[d].NumberOfEntries;else r.default_sample_info_size=
1360
- 8}}f.flags&=16777214;f.flags|=131072;k.flags|=1;var u=e.fetch("moof");k.data_offset=u.getLength()+8;var v=e.fetch("saio");null!==v&&(v.offset[0]=qD(u,"traf")+qD(h,"senc")+16);var w=Gb(e.write());return Promise.resolve(w)}catch(A){return A instanceof U?Promise.reject(A):Promise.reject(new U(2,3,3022,c?c.P()[0]:null))}};function qD(a,b){for(var c=8,d=0;d<a.boxes.length&&a.boxes[d].type!==b;d++)c+=a.boxes[d].size;return c}P("shaka.transmuxer.MssTransmuxer",nD);nD.prototype.transmux=nD.prototype.transmux;
1361
- nD.prototype.getOriginalMimeType=nD.prototype.getOriginalMimeType;nD.prototype.convertCodecs=nD.prototype.convertCodecs;nD.prototype.isSupported=nD.prototype.isSupported;nD.prototype.destroy=nD.prototype.destroy;var pD=new Uint8Array([162,57,79,82,90,155,79,20,162,68,108,66,124,100,141,244]);le("mss/audio/mp4",function(){return new nD("mss/audio/mp4")},re);le("mss/video/mp4",function(){return new nD("mss/video/mp4")},re);function rD(a){this.l=a;this.g=0;this.i=new Map;this.h=this.j=null}q=rD.prototype;q.destroy=function(){this.i.clear();this.h&&this.h.destroy()};
1362
- q.isSupported=function(a,b){if("video/mp2t"!=a.toLowerCase().split(";")[0])return!1;var c=a;b&&(c=this.convertCodecs(b,a));var d=Ke(c).split(",");c=Pc("audio",d);d=Pc("video",d);if(c&&(c=Ge(c),!sD.includes(c))||d&&(c=Ge(d),!tD.includes(c)))return!1;if(b)return td(this.convertCodecs(b,a));b=this.convertCodecs("audio",a);a=this.convertCodecs("video",a);return td(b)||td(a)};
1361
+ 8}}f.flags&=16777214;f.flags|=131072;k.flags|=1;var u=e.fetch("moof");k.data_offset=u.getLength()+8;var v=e.fetch("saio");null!==v&&(v.offset[0]=rD(u,"traf")+rD(h,"senc")+16);var w=Gb(e.write());return Promise.resolve(w)}catch(A){return A instanceof U?Promise.reject(A):Promise.reject(new U(2,3,3022,c?c.P()[0]:null))}};function rD(a,b){for(var c=8,d=0;d<a.boxes.length&&a.boxes[d].type!==b;d++)c+=a.boxes[d].size;return c}P("shaka.transmuxer.MssTransmuxer",oD);oD.prototype.transmux=oD.prototype.transmux;
1362
+ oD.prototype.getOriginalMimeType=oD.prototype.getOriginalMimeType;oD.prototype.convertCodecs=oD.prototype.convertCodecs;oD.prototype.isSupported=oD.prototype.isSupported;oD.prototype.destroy=oD.prototype.destroy;var qD=new Uint8Array([162,57,79,82,90,155,79,20,162,68,108,66,124,100,141,244]);le("mss/audio/mp4",function(){return new oD("mss/audio/mp4")},re);le("mss/video/mp4",function(){return new oD("mss/video/mp4")},re);function sD(a){this.l=a;this.g=0;this.i=new Map;this.h=this.j=null}q=sD.prototype;q.destroy=function(){this.i.clear();this.h&&this.h.destroy()};
1363
+ q.isSupported=function(a,b){if("video/mp2t"!=a.toLowerCase().split(";")[0])return!1;var c=a;b&&(c=this.convertCodecs(b,a));var d=Ke(c).split(",");c=Pc("audio",d);d=Pc("video",d);if(c&&(c=Ge(c),!tD.includes(c))||d&&(c=Ge(d),!uD.includes(c)))return!1;if(b)return td(this.convertCodecs(b,a));b=this.convertCodecs("audio",a);a=this.convertCodecs("video",a);return td(b)||td(a)};
1363
1364
  q.convertCodecs=function(a,b){return"video/mp2t"==b.toLowerCase().split(";")[0]?(b=Ke(b).replace("mp4a.40.34","mp3").split(",").map(function(c){return nf(c,"audio/mp4")}).map(mf).join(","),"audio"==a?'audio/mp4; codecs="'+b+'"':'video/mp4; codecs="'+b+'"'):b};q.getOriginalMimeType=function(){return this.l};
1364
- q.transmux=function(a,b,c,d,e){var f=Gb(a);if("audio"==e&&!Cj(f)){for(var g=Yi(f),h=g.length;h<f.length;h++)if(kD(f,h))return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));for(h=g.length;h<f.length;h++)if(PC(f,h))return this.h||(this.h=new RC("audio/aac")),this.h.transmux(a,b,c,d,e);return Promise.reject(new U(2,3,3018,c?c.P()[0]:null))}this.j?this.j.clearData():this.j=new vj;var k=this.j.parse(f),l=[],m=k.Od();try{var n=null;if("video"==e){switch(m.video){case "avc":var p=[],r=null,u=[],v=k.bd();
1365
- if(!v.length)throw new U(2,3,3023,c?c.P()[0]:null);for(var w=0;w<v.length;w++){var A=v[w],z=A.nalus;u.push.apply(u,x(z));var C=ZC(z);if(C){null==r&&(r=A.dts);var y=void 0;y=w+1<v.length?(v[w+1].dts||0)-(A.dts||0):1<v.length?(A.dts||0)-(v[w-1].dts||0):9E4*(c.endTime-c.startTime);p.push({data:C.data,size:C.data.byteLength,duration:y,wb:Math.round((A.pts||0)-(A.dts||0)),flags:{xb:0,mb:0,kb:0,hb:0,ib:C.Yd?2:1,yb:C.Yd?0:1}})}}var B=XC(u);if(!B||null==r)throw new U(2,3,3018,c?c.P()[0]:null);b.height=B.height;
1366
- b.width=B.width;n={id:b.id,type:"video",codecs:"avc1",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:9E4,duration:d,ub:[],ya:new Uint8Array([]),Ma:B.Ma,Sa:B.Sa,Ua:B.Ua,data:{Ib:this.g,baseMediaDecodeTime:r,rb:p},stream:b};break;case "hvc":var D=[],K=null,G=[],J=k.bd();if(!J.length)throw new U(2,3,3023,c?c.P()[0]:null);for(var I=0;I<J.length;I++){var H=J[I],N=H.nalus;G.push.apply(G,x(N));for(var L=!1,M=[],Q=!1,T=t(N),R=T.next();!R.done;R=T.next()){var ra=R.value;switch(ra.type){case 1:case 0:var sa=
1367
- Q=!0;break;case 19:case 20:case 21:L=sa=Q=!0;break;case 32:sa=!0;break;case 33:sa=!0;break;case 34:sa=!0;break;case 35:Q=sa=!0;break;case 39:case 40:sa=!0;break;default:sa=!1}if(Q&&sa){var Ca=ra.fullData.byteLength,Ea=new Uint8Array(4);Ea[0]=Ca>>24&255;Ea[1]=Ca>>16&255;Ea[2]=Ca>>8&255;Ea[3]=Ca&255;M.push(Ea);M.push(ra.fullData)}}var Ia=M.length?{data:Kc.apply(Ec,x(M)),Yd:L}:null;if(Ia){null==K&&null!=H.dts&&(K=H.dts);var Pa=void 0;Pa=I+1<J.length?(J[I+1].dts||0)-(H.dts||0):1<J.length?(H.dts||0)-(J[I-
1368
- 1].dts||0):9E4*(c.endTime-c.startTime);D.push({data:Ia.data,size:Ia.data.byteLength,duration:Pa,wb:Math.round((H.pts||0)-(H.dts||0)),flags:{xb:0,mb:0,kb:0,hb:0,ib:Ia.Yd?2:1,yb:Ia.Yd?0:1}})}}var Ja=$C(G);if(!Ja||null==K)throw new U(2,3,3018,c?c.P()[0]:null);b.height=Ja.height;b.width=Ja.width;n={id:b.id,type:"video",codecs:"hvc1",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:9E4,duration:d,ub:[],ya:new Uint8Array([]),Ma:Ja.Ma,Sa:Ja.Sa,Ua:Ja.Ua,data:{Ib:this.g,baseMediaDecodeTime:K,rb:D},stream:b}}n&&
1369
- (l.push(n),n=null)}if("audio"==e){switch(m.audio){case "aac":for(var db=[],Fa,$a=null,xb=t(k.fc()),ad=xb.next();!ad.done;ad=xb.next()){var ye=ad.value,Fd=ye.data;if(Fd){var Rc=0;Fa=OC(Fd,Rc);if(!Fa)throw new U(2,3,3018,c?c.P()[0]:null);b.audioSamplingRate=Fa.sampleRate;b.channelsCount=Fa.channelCount;null==$a&&null!==ye.pts&&($a=ye.pts);for(;Rc<Fd.length;){var ze=NC(Fd,Rc);if(ze){var Ae=ze.Pe+ze.ia;Rc+Ae<=Fd.length&&db.push({data:Fd.subarray(Rc+ze.Pe,Rc+Ae),size:ze.ia,duration:1024,wb:0,flags:{xb:0,
1370
- mb:0,kb:0,hb:0,ib:2,yb:0}});Rc+=Ae}else Rc++}}}if(!Fa||null==$a){if(!k.bd().length)throw new U(2,3,3018,c?c.P()[0]:null);$a=9E4*c.startTime;var Be=Pc("audio",b.codecs.split(","));if(!Be||!b.channelsCount||!b.audioSamplingRate)throw new U(2,3,3018,c?c.P()[0]:null);Fa={sampleRate:b.audioSamplingRate,channelCount:b.channelsCount,cb:Be};var Gd=QC(Be,b.channelsCount);if(!Gd)throw new U(2,3,3018,c?c.P()[0]:null);for(var oj=$a+9E4*(c.endTime-c.startTime),dh=$a;dh<oj;)db.push({data:Gd,size:Gd.byteLength,
1371
- duration:1024,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}}),dh+=1024/Fa.sampleRate*9E4}var pj=Fa.sampleRate,qj=$a/9E4*pj;n={id:b.id,type:"audio",codecs:Fa.cb,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:pj,duration:d,ub:[],ya:new Uint8Array([]),Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.g,baseMediaDecodeTime:qj,rb:db},stream:b};break;case "ac3":for(var eh=[],Ce=0,rc=new Uint8Array([]),ak=null,Sw=t(k.fc()),On=Sw.next();!On.done;On=Sw.next()){var Pn=On.value,Qn=Pn.data;null==ak&&null!==Pn.pts&&
1372
- (ak=Pn.pts);for(var Mf=0;Mf<Qn.length;){var Zd=SC(Qn,Mf);Zd?(b.audioSamplingRate=Zd.sampleRate,b.channelsCount=Zd.channelCount,Ce=Zd.sampleRate,rc=Zd.ya,eh.push({data:Qn.subarray(Mf,Mf+Zd.ia),size:Zd.ia,duration:1536,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}}),Mf+=Zd.ia):Mf++}}if(0==Ce||0==rc.byteLength||null==ak)throw new U(2,3,3018,c?c.P()[0]:null);var MG=ak/9E4*Ce;n={id:b.id,type:"audio",codecs:"ac-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:Ce,duration:d,ub:[],ya:rc,Ma:new Uint8Array([]),
1373
- Sa:0,Ua:0,data:{Ib:this.g,baseMediaDecodeTime:MG,rb:eh},stream:b};break;case "ec3":for(var Tw=[],bk=0,Rn=new Uint8Array([]),ck=null,Uw=t(k.fc()),Sn=Uw.next();!Sn.done;Sn=Uw.next()){var Tn=Sn.value,Un=Tn.data;null==ck&&null!==Tn.pts&&(ck=Tn.pts);for(var Nf=0;Nf<Un.length;){var $d=VC(Un,Nf);$d?(b.audioSamplingRate=$d.sampleRate,b.channelsCount=$d.channelCount,bk=$d.sampleRate,Rn=$d.ya,Tw.push({data:Un.subarray(Nf,Nf+$d.ia),size:$d.ia,duration:1536,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}}),Nf+=$d.ia):
1374
- Nf++}}if(0==bk||0==Rn.byteLength||null==ck)throw new U(2,3,3018,c?c.P()[0]:null);var NG=ck/9E4*bk;n={id:b.id,type:"audio",codecs:"ec-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:bk,duration:d,ub:[],ya:Rn,Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.g,baseMediaDecodeTime:NG,rb:Tw},stream:b};break;case "mp3":for(var Vw=[],dk,ek=null,Ww=t(k.fc()),Vn=Ww.next();!Vn.done;Vn=Ww.next()){var Wn=Vn.value,rh=Wn.data;if(rh){null==ek&&null!==Wn.pts&&(ek=Wn.pts);for(var Fe=0;Fe<rh.length;){var Of=eD(rh,
1375
- Fe);Of?(dk||(dk=Of),Fe+Of.ia<=rh.length&&Vw.push({data:rh.subarray(Fe,Fe+Of.ia),size:Of.ia,duration:1152,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}}),Fe+=Of.ia):Fe++}}}if(!dk||null==ek)throw new U(2,3,3018,c?c.P()[0]:null);var Xw=dk.sampleRate,OG=ek/9E4*Xw;n={id:b.id,type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:Xw,duration:d,ub:[],ya:new Uint8Array([]),Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.g,baseMediaDecodeTime:OG,rb:Vw},stream:b};break;case "opus":var Yw=
1376
- [],fk=null,cd=k.H;if(!cd)throw new U(2,3,3018,c?c.P()[0]:null);var Hb=[];switch(cd.Ki){case 1:case 2:Hb=[0];break;case 0:Hb=[255,1,1,0,1];break;case 128:Hb=[255,2,0,0,1];break;case 3:Hb=[1,2,1,0,2,1];break;case 4:Hb=[1,2,2,0,1,2,3];break;case 5:Hb=[1,3,2,0,4,1,2,3];break;case 6:Hb=[1,4,2,0,4,1,2,3,5];break;case 7:Hb=[1,4,2,0,4,1,2,3,5,6];break;case 8:Hb=[1,5,3,0,6,1,2,3,4,5,7];break;case 130:Hb=[1,1,2,0,1];break;case 131:Hb=[1,1,3,0,1,2];break;case 132:Hb=[1,1,4,0,1,2,3];break;case 133:Hb=[1,1,5,
1377
- 0,1,2,3,4];break;case 134:Hb=[1,1,6,0,1,2,3,4,5];break;case 135:Hb=[1,1,7,0,1,2,3,4,5,6];break;case 136:Hb=[1,1,8,0,1,2,3,4,5,6,7]}var Zw=new Uint8Array([0,cd.channelCount,0,0,cd.sampleRate>>>24&255,cd.sampleRate>>>17&255,cd.sampleRate>>>8&255,cd.sampleRate>>>0&255,0,0].concat(x(Hb)));for(var $w=cd.sampleRate,ax=t(k.fc()),Xn=ax.next();!Xn.done;Xn=ax.next()){var Yn=Xn.value,Pf=Yn.data;null==fk&&null!==Yn.pts&&(fk=Yn.pts);for(var sh=0;sh<Pf.length;){for(var PG=0!==(Pf[sh+1]&16),QG=0!==(Pf[sh+1]&8),
1378
- Id=sh+2,gk=0;255===Pf[Id];)gk+=255,Id+=1;gk+=Pf[Id];Id+=1;Id+=PG?2:0;Id+=QG?2:0;var bx=Pf.slice(Id,Id+gk);Yw.push({data:bx,size:bx.byteLength,duration:960,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}});sh=Id+gk}}if(0==Zw.byteLength||null==fk)throw new U(2,3,3018,c?c.P()[0]:null);b.audioSamplingRate=cd.sampleRate;b.channelsCount=cd.channelCount;var RG=fk/9E4*$w;n={id:b.id,type:"audio",codecs:"opus",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:$w,duration:d,ub:[],ya:Zw,Ma:new Uint8Array([]),Sa:0,
1379
- Ua:0,data:{Ib:this.g,baseMediaDecodeTime:RG,rb:Yw},stream:b}}n&&(l.push(n),n=null)}}catch(Zn){return Zn&&3023==Zn.code?Promise.resolve(new Uint8Array([])):Promise.reject(Zn)}if(!l.length)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));var cx=new Rw(l);if(this.i.has(b.id))var $n=this.i.get(b.id);else $n=ix(cx),this.i.set(b.id,$n);var SG=zx(cx);this.g++;var TG=Kc($n,SG);return Promise.resolve(TG)};P("shaka.transmuxer.TsTransmuxer",rD);rD.prototype.transmux=rD.prototype.transmux;
1380
- rD.prototype.getOriginalMimeType=rD.prototype.getOriginalMimeType;rD.prototype.convertCodecs=rD.prototype.convertCodecs;rD.prototype.isSupported=rD.prototype.isSupported;rD.prototype.destroy=rD.prototype.destroy;var sD=["aac","ac-3","ec-3","mp3","opus"],tD=["avc","hevc"];le("video/mp2t",function(){return new rD("video/mp2t")},pe);/*
1365
+ q.transmux=function(a,b,c,d,e){var f=Gb(a);if("audio"==e&&!Cj(f)){for(var g=Yi(f),h=g.length;h<f.length;h++)if(lD(f,h))return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));for(h=g.length;h<f.length;h++)if(QC(f,h))return this.h||(this.h=new SC("audio/aac")),this.h.transmux(a,b,c,d,e);return Promise.reject(new U(2,3,3018,c?c.P()[0]:null))}this.j?this.j.clearData():this.j=new vj;var k=this.j.parse(f),l=[],m=k.Od();try{var n=null;if("video"==e){switch(m.video){case "avc":var p=[],r=null,u=[],v=k.cd();
1366
+ if(!v.length)throw new U(2,3,3023,c?c.P()[0]:null);for(var w=0;w<v.length;w++){var A=v[w],z=A.nalus;u.push.apply(u,x(z));var C=$C(z);if(C){null==r&&(r=A.dts);var y=void 0;y=w+1<v.length?(v[w+1].dts||0)-(A.dts||0):1<v.length?(A.dts||0)-(v[w-1].dts||0):9E4*(c.endTime-c.startTime);p.push({data:C.data,size:C.data.byteLength,duration:y,wb:Math.round((A.pts||0)-(A.dts||0)),flags:{xb:0,mb:0,kb:0,hb:0,ib:C.Yd?2:1,yb:C.Yd?0:1}})}}var B=YC(u);if(!B||null==r)throw new U(2,3,3018,c?c.P()[0]:null);b.height=B.height;
1367
+ b.width=B.width;n={id:b.id,type:"video",codecs:"avc1",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:9E4,duration:d,ub:[],ya:new Uint8Array([]),Ma:B.Ma,Sa:B.Sa,Ua:B.Ua,data:{Ib:this.g,baseMediaDecodeTime:r,rb:p},stream:b};break;case "hvc":var D=[],K=null,G=[],J=k.cd();if(!J.length)throw new U(2,3,3023,c?c.P()[0]:null);for(var I=0;I<J.length;I++){var H=J[I],N=H.nalus;G.push.apply(G,x(N));for(var L=!1,M=[],Q=!1,T=t(N),R=T.next();!R.done;R=T.next()){var ra=R.value;switch(ra.type){case 1:case 0:var sa=
1368
+ Q=!0;break;case 19:case 20:case 21:L=sa=Q=!0;break;case 32:sa=!0;break;case 33:sa=!0;break;case 34:sa=!0;break;case 35:Q=sa=!0;break;case 39:case 40:sa=!0;break;default:sa=!1}if(Q&&sa){var Ca=ra.fullData.byteLength,Fa=new Uint8Array(4);Fa[0]=Ca>>24&255;Fa[1]=Ca>>16&255;Fa[2]=Ca>>8&255;Fa[3]=Ca&255;M.push(Fa);M.push(ra.fullData)}}var Ia=M.length?{data:Kc.apply(Ec,x(M)),Yd:L}:null;if(Ia){null==K&&null!=H.dts&&(K=H.dts);var Pa=void 0;Pa=I+1<J.length?(J[I+1].dts||0)-(H.dts||0):1<J.length?(H.dts||0)-(J[I-
1369
+ 1].dts||0):9E4*(c.endTime-c.startTime);D.push({data:Ia.data,size:Ia.data.byteLength,duration:Pa,wb:Math.round((H.pts||0)-(H.dts||0)),flags:{xb:0,mb:0,kb:0,hb:0,ib:Ia.Yd?2:1,yb:Ia.Yd?0:1}})}}var Ja=aD(G);if(!Ja||null==K)throw new U(2,3,3018,c?c.P()[0]:null);b.height=Ja.height;b.width=Ja.width;n={id:b.id,type:"video",codecs:"hvc1",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:9E4,duration:d,ub:[],ya:new Uint8Array([]),Ma:Ja.Ma,Sa:Ja.Sa,Ua:Ja.Ua,data:{Ib:this.g,baseMediaDecodeTime:K,rb:D},stream:b}}n&&
1370
+ (l.push(n),n=null)}if("audio"==e){switch(m.audio){case "aac":for(var db=[],Da,$a=null,xb=t(k.fc()),ad=xb.next();!ad.done;ad=xb.next()){var ye=ad.value,Fd=ye.data;if(Fd){var Rc=0;Da=PC(Fd,Rc);if(!Da)throw new U(2,3,3018,c?c.P()[0]:null);b.audioSamplingRate=Da.sampleRate;b.channelsCount=Da.channelCount;null==$a&&null!==ye.pts&&($a=ye.pts);for(;Rc<Fd.length;){var ze=OC(Fd,Rc);if(ze){var Ae=ze.Pe+ze.ia;Rc+Ae<=Fd.length&&db.push({data:Fd.subarray(Rc+ze.Pe,Rc+Ae),size:ze.ia,duration:1024,wb:0,flags:{xb:0,
1371
+ mb:0,kb:0,hb:0,ib:2,yb:0}});Rc+=Ae}else Rc++}}}if(!Da||null==$a){if(!k.cd().length)throw new U(2,3,3018,c?c.P()[0]:null);$a=9E4*c.startTime;var Be=Pc("audio",b.codecs.split(","));if(!Be||!b.channelsCount||!b.audioSamplingRate)throw new U(2,3,3018,c?c.P()[0]:null);Da={sampleRate:b.audioSamplingRate,channelCount:b.channelsCount,cb:Be};var Gd=RC(Be,b.channelsCount);if(!Gd)throw new U(2,3,3018,c?c.P()[0]:null);for(var pj=$a+9E4*(c.endTime-c.startTime),dh=$a;dh<pj;)db.push({data:Gd,size:Gd.byteLength,
1372
+ duration:1024,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}}),dh+=1024/Da.sampleRate*9E4}var qj=Da.sampleRate,rj=$a/9E4*qj;n={id:b.id,type:"audio",codecs:Da.cb,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:qj,duration:d,ub:[],ya:new Uint8Array([]),Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.g,baseMediaDecodeTime:rj,rb:db},stream:b};break;case "ac3":for(var eh=[],Ce=0,rc=new Uint8Array([]),bk=null,Tw=t(k.fc()),Pn=Tw.next();!Pn.done;Pn=Tw.next()){var Qn=Pn.value,Rn=Qn.data;null==bk&&null!==Qn.pts&&
1373
+ (bk=Qn.pts);for(var Mf=0;Mf<Rn.length;){var Zd=TC(Rn,Mf);Zd?(b.audioSamplingRate=Zd.sampleRate,b.channelsCount=Zd.channelCount,Ce=Zd.sampleRate,rc=Zd.ya,eh.push({data:Rn.subarray(Mf,Mf+Zd.ia),size:Zd.ia,duration:1536,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}}),Mf+=Zd.ia):Mf++}}if(0==Ce||0==rc.byteLength||null==bk)throw new U(2,3,3018,c?c.P()[0]:null);var NG=bk/9E4*Ce;n={id:b.id,type:"audio",codecs:"ac-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:Ce,duration:d,ub:[],ya:rc,Ma:new Uint8Array([]),
1374
+ Sa:0,Ua:0,data:{Ib:this.g,baseMediaDecodeTime:NG,rb:eh},stream:b};break;case "ec3":for(var Uw=[],ck=0,Sn=new Uint8Array([]),dk=null,Vw=t(k.fc()),Tn=Vw.next();!Tn.done;Tn=Vw.next()){var Un=Tn.value,Vn=Un.data;null==dk&&null!==Un.pts&&(dk=Un.pts);for(var Nf=0;Nf<Vn.length;){var $d=WC(Vn,Nf);$d?(b.audioSamplingRate=$d.sampleRate,b.channelsCount=$d.channelCount,ck=$d.sampleRate,Sn=$d.ya,Uw.push({data:Vn.subarray(Nf,Nf+$d.ia),size:$d.ia,duration:1536,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}}),Nf+=$d.ia):
1375
+ Nf++}}if(0==ck||0==Sn.byteLength||null==dk)throw new U(2,3,3018,c?c.P()[0]:null);var OG=dk/9E4*ck;n={id:b.id,type:"audio",codecs:"ec-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:ck,duration:d,ub:[],ya:Sn,Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.g,baseMediaDecodeTime:OG,rb:Uw},stream:b};break;case "mp3":for(var Ww=[],ek,fk=null,Xw=t(k.fc()),Wn=Xw.next();!Wn.done;Wn=Xw.next()){var Xn=Wn.value,rh=Xn.data;if(rh){null==fk&&null!==Xn.pts&&(fk=Xn.pts);for(var Fe=0;Fe<rh.length;){var Of=fD(rh,
1376
+ Fe);Of?(ek||(ek=Of),Fe+Of.ia<=rh.length&&Ww.push({data:rh.subarray(Fe,Fe+Of.ia),size:Of.ia,duration:1152,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}}),Fe+=Of.ia):Fe++}}}if(!ek||null==fk)throw new U(2,3,3018,c?c.P()[0]:null);var Yw=ek.sampleRate,PG=fk/9E4*Yw;n={id:b.id,type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:Yw,duration:d,ub:[],ya:new Uint8Array([]),Ma:new Uint8Array([]),Sa:0,Ua:0,data:{Ib:this.g,baseMediaDecodeTime:PG,rb:Ww},stream:b};break;case "opus":var Zw=
1377
+ [],gk=null,cd=k.H;if(!cd)throw new U(2,3,3018,c?c.P()[0]:null);var Hb=[];switch(cd.Ki){case 1:case 2:Hb=[0];break;case 0:Hb=[255,1,1,0,1];break;case 128:Hb=[255,2,0,0,1];break;case 3:Hb=[1,2,1,0,2,1];break;case 4:Hb=[1,2,2,0,1,2,3];break;case 5:Hb=[1,3,2,0,4,1,2,3];break;case 6:Hb=[1,4,2,0,4,1,2,3,5];break;case 7:Hb=[1,4,2,0,4,1,2,3,5,6];break;case 8:Hb=[1,5,3,0,6,1,2,3,4,5,7];break;case 130:Hb=[1,1,2,0,1];break;case 131:Hb=[1,1,3,0,1,2];break;case 132:Hb=[1,1,4,0,1,2,3];break;case 133:Hb=[1,1,5,
1378
+ 0,1,2,3,4];break;case 134:Hb=[1,1,6,0,1,2,3,4,5];break;case 135:Hb=[1,1,7,0,1,2,3,4,5,6];break;case 136:Hb=[1,1,8,0,1,2,3,4,5,6,7]}var $w=new Uint8Array([0,cd.channelCount,0,0,cd.sampleRate>>>24&255,cd.sampleRate>>>17&255,cd.sampleRate>>>8&255,cd.sampleRate>>>0&255,0,0].concat(x(Hb)));for(var ax=cd.sampleRate,bx=t(k.fc()),Yn=bx.next();!Yn.done;Yn=bx.next()){var Zn=Yn.value,Pf=Zn.data;null==gk&&null!==Zn.pts&&(gk=Zn.pts);for(var sh=0;sh<Pf.length;){for(var QG=0!==(Pf[sh+1]&16),RG=0!==(Pf[sh+1]&8),
1379
+ Id=sh+2,hk=0;255===Pf[Id];)hk+=255,Id+=1;hk+=Pf[Id];Id+=1;Id+=QG?2:0;Id+=RG?2:0;var cx=Pf.slice(Id,Id+hk);Zw.push({data:cx,size:cx.byteLength,duration:960,wb:0,flags:{xb:0,mb:0,kb:0,hb:0,ib:2,yb:0}});sh=Id+hk}}if(0==$w.byteLength||null==gk)throw new U(2,3,3018,c?c.P()[0]:null);b.audioSamplingRate=cd.sampleRate;b.channelsCount=cd.channelCount;var SG=gk/9E4*ax;n={id:b.id,type:"audio",codecs:"opus",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:ax,duration:d,ub:[],ya:$w,Ma:new Uint8Array([]),Sa:0,
1380
+ Ua:0,data:{Ib:this.g,baseMediaDecodeTime:SG,rb:Zw},stream:b}}n&&(l.push(n),n=null)}}catch($n){return $n&&3023==$n.code?Promise.resolve(new Uint8Array([])):Promise.reject($n)}if(!l.length)return Promise.reject(new U(2,3,3018,c?c.P()[0]:null));var dx=new Sw(l);if(this.i.has(b.id))var ao=this.i.get(b.id);else ao=jx(dx),this.i.set(b.id,ao);var TG=Ax(dx);this.g++;var UG=Kc(ao,TG);return Promise.resolve(UG)};P("shaka.transmuxer.TsTransmuxer",sD);sD.prototype.transmux=sD.prototype.transmux;
1381
+ sD.prototype.getOriginalMimeType=sD.prototype.getOriginalMimeType;sD.prototype.convertCodecs=sD.prototype.convertCodecs;sD.prototype.isSupported=sD.prototype.isSupported;sD.prototype.destroy=sD.prototype.destroy;var tD=["aac","ac-3","ec-3","mp3","opus"],uD=["avc","hevc"];le("video/mp2t",function(){return new sD("video/mp2t")},pe);/*
1381
1382
  @license
1382
1383
  EME Encryption Scheme Polyfill
1383
1384
  Copyright 2019 Google LLC
1384
1385
  SPDX-License-Identifier: Apache-2.0
1385
1386
  */
1386
- function uD(){}var vD;
1387
- function wD(){vD||navigator.emeEncryptionSchemePolyfilled?console.debug("EmeEncryptionSchemePolyfill: Already installed."):navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration?(vD=navigator.requestMediaKeySystemAccess,console.debug("EmeEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.requestMediaKeySystemAccess=xD,navigator.emeEncryptionSchemePolyfilled=!0):console.debug("EmeEncryptionSchemePolyfill: EME not found")}
1388
- function xD(a,b){var c=this,d;return O(function(e){if(1==e.g)return console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess'),E(e,vD.call(c,a,b),2);d=e.h;if(yD(d))return console.debug("EmeEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.requestMediaKeySystemAccess=vD,e.return(d);console.debug("EmeEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");navigator.requestMediaKeySystemAccess=zD;return e.return(zD.call(c,
1387
+ function vD(){}var wD;
1388
+ function xD(){wD||navigator.emeEncryptionSchemePolyfilled?console.debug("EmeEncryptionSchemePolyfill: Already installed."):navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration?(wD=navigator.requestMediaKeySystemAccess,console.debug("EmeEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.requestMediaKeySystemAccess=yD,navigator.emeEncryptionSchemePolyfilled=!0):console.debug("EmeEncryptionSchemePolyfill: EME not found")}
1389
+ function yD(a,b){var c=this,d;return O(function(e){if(1==e.g)return console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess'),E(e,wD.call(c,a,b),2);d=e.h;if(zD(d))return console.debug("EmeEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.requestMediaKeySystemAccess=wD,e.return(d);console.debug("EmeEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");navigator.requestMediaKeySystemAccess=AD;return e.return(AD.call(c,
1389
1390
  a,b))})}
1390
- function zD(a,b){var c=this,d,e,f,g,h,k,l,m,n,p,r,u;return O(function(v){if(1==v.g){console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess');d=AD(a);e=[];f=t(b);for(g=f.next();!g.done;g=f.next())h=g.value,k=BD(h.videoCapabilities,d),l=BD(h.audioCapabilities,d),h.videoCapabilities&&h.videoCapabilities.length&&!k.length||h.audioCapabilities&&h.audioCapabilities.length&&!l.length||(m=Object.assign({},h),m.videoCapabilities=k,m.audioCapabilities=l,e.push(m));if(!e.length)throw n=Error("Unsupported keySystem or supportedConfigurations."),
1391
- n.name="NotSupportedError",n.code=DOMException.NOT_SUPPORTED_ERR,n;return E(v,vD.call(c,a,e),2)}p=v.h;u=r=null;e[0]&&(e[0].videoCapabilities&&(r=e[0].videoCapabilities[0].encryptionScheme),e[0].audioCapabilities&&(u=e[0].audioCapabilities[0].encryptionScheme));return v.return(new CD(p,r,u))})}function BD(a,b){return a?a.filter(function(c){return DD(c.encryptionScheme,b)}):a}P("EmeEncryptionSchemePolyfill",uD);uD.install=wD;function ED(){}var FD;
1392
- function GD(){FD||navigator.mediaCapabilitiesEncryptionSchemePolyfilled?console.debug("McEncryptionSchemePolyfill: Already installed."):navigator.mediaCapabilities?(FD=navigator.mediaCapabilities.decodingInfo,console.debug("McEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.mediaCapabilities.decodingInfo=HD,navigator.mediaCapabilitiesEncryptionSchemePolyfilled=!0):console.debug("McEncryptionSchemePolyfill: MediaCapabilities not found")}
1393
- function HD(a){var b=this,c,d,e;return O(function(f){switch(f.g){case 1:return console.assert(b==navigator.mediaCapabilities,'bad "this" for decodingInfo'),E(f,FD.call(b,a),2);case 2:c=f.h;if(!a.keySystemConfiguration)return f.return(c);if((d=c.keySystemAccess)&&yD(d))return console.debug("McEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.mediaCapabilities.decodingInfo=FD,f.return(c);console.debug("McEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");
1394
- navigator.mediaCapabilities.decodingInfo=ID;if(d){f.B(3);break}e=c;return E(f,JD(a),4);case 4:return e.keySystemAccess=f.h,f.return(c);case 3:return f.return(ID.call(b,a))}})}
1395
- function ID(a){var b=this,c,d,e,f,g,h,k,l;return O(function(m){switch(m.g){case 1:return console.assert(b==navigator.mediaCapabilities,'bad "this" for decodingInfo'),d=c=null,!a.keySystemConfiguration||(e=a.keySystemConfiguration,f=e.keySystem,d=e.audio&&e.audio.encryptionScheme,c=e.video&&e.video.encryptionScheme,g=AD(f),h={powerEfficient:!1,smooth:!1,supported:!1,keySystemAccess:null,configuration:a},DD(d,g)&&DD(c,g))?E(m,FD.call(b,a),2):m.return(h);case 2:k=m.h;if(k.keySystemAccess){k.keySystemAccess=
1396
- new CD(k.keySystemAccess,c,d);m.B(3);break}if(!a.keySystemConfiguration){m.B(3);break}l=k;return E(m,JD(a),5);case 5:l.keySystemAccess=m.h;case 3:return m.return(k)}})}
1397
- function JD(a){var b,c;return O(function(d){if(1==d.g){var e=a.keySystemConfiguration,f=[],g=[];e.audio&&f.push({robustness:e.audio.robustness||"",contentType:a.audio.contentType,encryptionScheme:e.audio.encryptionScheme});e.video&&g.push({robustness:e.video.robustness||"",contentType:a.video.contentType,encryptionScheme:e.video.encryptionScheme});e={initDataTypes:e.initDataType?[e.initDataType]:[],distinctiveIdentifier:e.distinctiveIdentifier,persistentState:e.persistentState,sessionTypes:e.sessionTypes};
1398
- f.length&&(e.audioCapabilities=f);g.length&&(e.videoCapabilities=g);b=e;return E(d,navigator.requestMediaKeySystemAccess(a.keySystemConfiguration.keySystem,[b]),2)}c=d.h;return d.return(c)})}P("McEncryptionSchemePolyfill",ED);ED.install=GD;function CD(a,b,c){this.g=a;this.i=b||null;this.h=c||null;this.keySystem=a.keySystem}
1399
- CD.prototype.getConfiguration=function(){var a=this.g.getConfiguration();if(a.videoCapabilities)for(var b=t(a.videoCapabilities),c=b.next();!c.done;c=b.next())c.value.encryptionScheme=this.i;if(a.audioCapabilities)for(b=t(a.audioCapabilities),c=b.next();!c.done;c=b.next())c.value.encryptionScheme=this.h;return a};CD.prototype.createMediaKeys=function(){return this.g.createMediaKeys()};
1400
- function AD(a){if(a.startsWith("com.widevine")||a.startsWith("com.microsoft")||a.startsWith("com.chromecast")||a.startsWith("com.adobe")||a.startsWith("org.w3"))return"cenc";if(a.startsWith("com.apple"))return"cbcs";console.warn("EmeEncryptionSchemePolyfill: Unknown key system:",a,"Please contribute!");return null}function yD(a){a=a.getConfiguration();var b=a.audioCapabilities&&a.audioCapabilities[0];return(a=a.videoCapabilities&&a.videoCapabilities[0]||b)&&void 0!==a.encryptionScheme?!0:!1}
1401
- function DD(a,b){if(!a||a==b)return!0;if("cbcs"==a||"cbcs-1-9"==a)if(KD||LD)return!0;return!1}function MD(){}function Zz(){wD();GD()}P("EncryptionSchemePolyfills",MD);MD.install=Zz;var LD=navigator.userAgent.includes("CrKey"),KD=100<=parseInt(navigator.userAgent.split("Firefox/").pop(),10);"undefined"!==typeof module&&module.exports&&(module.exports=MD);/*
1391
+ function AD(a,b){var c=this,d,e,f,g,h,k,l,m,n,p,r,u;return O(function(v){if(1==v.g){console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess');d=BD(a);e=[];f=t(b);for(g=f.next();!g.done;g=f.next())h=g.value,k=CD(h.videoCapabilities,d),l=CD(h.audioCapabilities,d),h.videoCapabilities&&h.videoCapabilities.length&&!k.length||h.audioCapabilities&&h.audioCapabilities.length&&!l.length||(m=Object.assign({},h),m.videoCapabilities=k,m.audioCapabilities=l,e.push(m));if(!e.length)throw n=Error("Unsupported keySystem or supportedConfigurations."),
1392
+ n.name="NotSupportedError",n.code=DOMException.NOT_SUPPORTED_ERR,n;return E(v,wD.call(c,a,e),2)}p=v.h;u=r=null;e[0]&&(e[0].videoCapabilities&&(r=e[0].videoCapabilities[0].encryptionScheme),e[0].audioCapabilities&&(u=e[0].audioCapabilities[0].encryptionScheme));return v.return(new DD(p,r,u))})}function CD(a,b){return a?a.filter(function(c){return ED(c.encryptionScheme,b)}):a}P("EmeEncryptionSchemePolyfill",vD);vD.install=xD;function FD(){}var GD;
1393
+ function HD(){GD||navigator.mediaCapabilitiesEncryptionSchemePolyfilled?console.debug("McEncryptionSchemePolyfill: Already installed."):navigator.mediaCapabilities?(GD=navigator.mediaCapabilities.decodingInfo,console.debug("McEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.mediaCapabilities.decodingInfo=ID,navigator.mediaCapabilitiesEncryptionSchemePolyfilled=!0):console.debug("McEncryptionSchemePolyfill: MediaCapabilities not found")}
1394
+ function ID(a){var b=this,c,d,e;return O(function(f){switch(f.g){case 1:return console.assert(b==navigator.mediaCapabilities,'bad "this" for decodingInfo'),E(f,GD.call(b,a),2);case 2:c=f.h;if(!a.keySystemConfiguration)return f.return(c);if((d=c.keySystemAccess)&&zD(d))return console.debug("McEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.mediaCapabilities.decodingInfo=GD,f.return(c);console.debug("McEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");
1395
+ navigator.mediaCapabilities.decodingInfo=JD;if(d){f.B(3);break}e=c;return E(f,KD(a),4);case 4:return e.keySystemAccess=f.h,f.return(c);case 3:return f.return(JD.call(b,a))}})}
1396
+ function JD(a){var b=this,c,d,e,f,g,h,k,l;return O(function(m){switch(m.g){case 1:return console.assert(b==navigator.mediaCapabilities,'bad "this" for decodingInfo'),d=c=null,!a.keySystemConfiguration||(e=a.keySystemConfiguration,f=e.keySystem,d=e.audio&&e.audio.encryptionScheme,c=e.video&&e.video.encryptionScheme,g=BD(f),h={powerEfficient:!1,smooth:!1,supported:!1,keySystemAccess:null,configuration:a},ED(d,g)&&ED(c,g))?E(m,GD.call(b,a),2):m.return(h);case 2:k=m.h;if(k.keySystemAccess){k.keySystemAccess=
1397
+ new DD(k.keySystemAccess,c,d);m.B(3);break}if(!a.keySystemConfiguration){m.B(3);break}l=k;return E(m,KD(a),5);case 5:l.keySystemAccess=m.h;case 3:return m.return(k)}})}
1398
+ function KD(a){var b,c;return O(function(d){if(1==d.g){var e=a.keySystemConfiguration,f=[],g=[];e.audio&&f.push({robustness:e.audio.robustness||"",contentType:a.audio.contentType,encryptionScheme:e.audio.encryptionScheme});e.video&&g.push({robustness:e.video.robustness||"",contentType:a.video.contentType,encryptionScheme:e.video.encryptionScheme});e={initDataTypes:e.initDataType?[e.initDataType]:[],distinctiveIdentifier:e.distinctiveIdentifier,persistentState:e.persistentState,sessionTypes:e.sessionTypes};
1399
+ f.length&&(e.audioCapabilities=f);g.length&&(e.videoCapabilities=g);b=e;return E(d,navigator.requestMediaKeySystemAccess(a.keySystemConfiguration.keySystem,[b]),2)}c=d.h;return d.return(c)})}P("McEncryptionSchemePolyfill",FD);FD.install=HD;function DD(a,b,c){this.g=a;this.i=b||null;this.h=c||null;this.keySystem=a.keySystem}
1400
+ DD.prototype.getConfiguration=function(){var a=this.g.getConfiguration();if(a.videoCapabilities)for(var b=t(a.videoCapabilities),c=b.next();!c.done;c=b.next())c.value.encryptionScheme=this.i;if(a.audioCapabilities)for(b=t(a.audioCapabilities),c=b.next();!c.done;c=b.next())c.value.encryptionScheme=this.h;return a};DD.prototype.createMediaKeys=function(){return this.g.createMediaKeys()};
1401
+ function BD(a){if(a.startsWith("com.widevine")||a.startsWith("com.microsoft")||a.startsWith("com.chromecast")||a.startsWith("com.adobe")||a.startsWith("org.w3"))return"cenc";if(a.startsWith("com.apple"))return"cbcs";console.warn("EmeEncryptionSchemePolyfill: Unknown key system:",a,"Please contribute!");return null}function zD(a){a=a.getConfiguration();var b=a.audioCapabilities&&a.audioCapabilities[0];return(a=a.videoCapabilities&&a.videoCapabilities[0]||b)&&void 0!==a.encryptionScheme?!0:!1}
1402
+ function ED(a,b){if(!a||a==b)return!0;if("cbcs"==a||"cbcs-1-9"==a)if(LD||MD)return!0;return!1}function ND(){}function $z(){xD();HD()}P("EncryptionSchemePolyfills",ND);ND.install=$z;var MD=navigator.userAgent.includes("CrKey"),LD=100<=parseInt(navigator.userAgent.split("Firefox/").pop(),10);"undefined"!==typeof module&&module.exports&&(module.exports=ND);/*
1402
1403
  @license
1403
1404
  Copyright 2013 Ali Al Dallal
1404
1405
 
@@ -1422,7 +1423,7 @@ function DD(a,b){if(!a||a==b)return!0;if("cbcs"==a||"cbcs-1-9"==a)if(KD||LD)retu
1422
1423
  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
1423
1424
  SOFTWARE.
1424
1425
  */
1425
- for(var ND={ach:{C:"Lwo",D:"Acholi"},ady:{C:"\u0410\u0434\u044b\u0433\u044d\u0431\u0437\u044d",D:"Adyghe"},af:{C:"Afrikaans",D:"Afrikaans"},"af-NA":{C:"Afrikaans (Namibia)",D:"Afrikaans (Namibia)"},"af-ZA":{C:"Afrikaans (South Africa)",D:"Afrikaans (South Africa)"},ak:{C:"T\u0255\u0265i",D:"Akan"},ar:{C:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",D:"Arabic"},"ar-AR":{C:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",D:"Arabic"},"ar-MA":{C:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",D:"Arabic (Morocco)"},
1426
+ for(var OD={ach:{C:"Lwo",D:"Acholi"},ady:{C:"\u0410\u0434\u044b\u0433\u044d\u0431\u0437\u044d",D:"Adyghe"},af:{C:"Afrikaans",D:"Afrikaans"},"af-NA":{C:"Afrikaans (Namibia)",D:"Afrikaans (Namibia)"},"af-ZA":{C:"Afrikaans (South Africa)",D:"Afrikaans (South Africa)"},ak:{C:"T\u0255\u0265i",D:"Akan"},ar:{C:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",D:"Arabic"},"ar-AR":{C:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",D:"Arabic"},"ar-MA":{C:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",D:"Arabic (Morocco)"},
1426
1427
  "ar-SA":{C:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629 (\u0627\u0644\u0633\u0639\u0648\u062f\u064a\u0629)",D:"Arabic (Saudi Arabia)"},"ay-BO":{C:"Aymar aru",D:"Aymara"},az:{C:"Az\u0259rbaycan dili",D:"Azerbaijani"},"az-AZ":{C:"Az\u0259rbaycan dili",D:"Azerbaijani"},"be-BY":{C:"\u0411\u0435\u043b\u0430\u0440\u0443\u0441\u043a\u0430\u044f",D:"Belarusian"},bg:{C:"\u0411\u044a\u043b\u0433\u0430\u0440\u0441\u043a\u0438",D:"Bulgarian"},"bg-BG":{C:"\u0411\u044a\u043b\u0433\u0430\u0440\u0441\u043a\u0438",
1427
1428
  D:"Bulgarian"},bn:{C:"\u09ac\u09be\u0982\u09b2\u09be",D:"Bengali"},"bn-IN":{C:"\u09ac\u09be\u0982\u09b2\u09be (\u09ad\u09be\u09b0\u09a4)",D:"Bengali (India)"},"bn-BD":{C:"\u09ac\u09be\u0982\u09b2\u09be(\u09ac\u09be\u0982\u09b2\u09be\u09a6\u09c7\u09b6)",D:"Bengali (Bangladesh)"},"bs-BA":{C:"Bosanski",D:"Bosnian"},ca:{C:"Catal\u00e0",D:"Catalan"},"ca-ES":{C:"Catal\u00e0",D:"Catalan"},cak:{C:"Maya Kaqchikel",D:"Kaqchikel"},"ck-US":{C:"\u13e3\u13b3\u13a9 (tsalagi)",D:"Cherokee"},cs:{C:"\u010ce\u0161tina",
1428
1429
  D:"Czech"},"cs-CZ":{C:"\u010ce\u0161tina",D:"Czech"},cy:{C:"Cymraeg",D:"Welsh"},"cy-GB":{C:"Cymraeg",D:"Welsh"},da:{C:"Dansk",D:"Danish"},"da-DK":{C:"Dansk",D:"Danish"},de:{C:"Deutsch",D:"German"},"de-AT":{C:"Deutsch (\u00d6sterreich)",D:"German (Austria)"},"de-DE":{C:"Deutsch (Deutschland)",D:"German (Germany)"},"de-CH":{C:"Deutsch (Schweiz)",D:"German (Switzerland)"},dsb:{C:"Dolnoserb\u0161\u0107ina",D:"Lower Sorbian"},el:{C:"\u0395\u03bb\u03bb\u03b7\u03bd\u03b9\u03ba\u03ac",D:"Greek"},"el-GR":{C:"\u0395\u03bb\u03bb\u03b7\u03bd\u03b9\u03ba\u03ac",
@@ -1443,114 +1444,114 @@ D:"Slovak"},"sk-SK":{C:"Sloven\u010dina (Slovakia)",D:"Slovak (Slovakia)"},sl:{C
1443
1444
  sw:{C:"Kiswahili",D:"Swahili"},"sw-KE":{C:"Kiswahili",D:"Swahili (Kenya)"},ta:{C:"\u0ba4\u0bae\u0bbf\u0bb4\u0bcd",D:"Tamil"},"ta-IN":{C:"\u0ba4\u0bae\u0bbf\u0bb4\u0bcd",D:"Tamil"},te:{C:"\u0c24\u0c46\u0c32\u0c41\u0c17\u0c41",D:"Telugu"},"te-IN":{C:"\u0c24\u0c46\u0c32\u0c41\u0c17\u0c41",D:"Telugu"},tg:{C:"\u0437\u0430\u0431\u043e\u0301\u043d\u0438 \u0442\u043e\u04b7\u0438\u043a\u04e3\u0301",D:"Tajik"},"tg-TJ":{C:"\u0442\u043e\u04b7\u0438\u043a\u04e3",D:"Tajik"},th:{C:"\u0e20\u0e32\u0e29\u0e32\u0e44\u0e17\u0e22",
1444
1445
  D:"Thai"},"th-TH":{C:"\u0e20\u0e32\u0e29\u0e32\u0e44\u0e17\u0e22 (\u0e1b\u0e23\u0e30\u0e40\u0e17\u0e28\u0e44\u0e17\u0e22)",D:"Thai (Thailand)"},tl:{C:"Filipino",D:"Filipino"},"tl-PH":{C:"Filipino",D:"Filipino"},tlh:{C:"tlhIngan-Hol",D:"Klingon"},tr:{C:"T\u00fcrk\u00e7e",D:"Turkish"},"tr-TR":{C:"T\u00fcrk\u00e7e",D:"Turkish"},"tt-RU":{C:"\u0442\u0430\u0442\u0430\u0440\u0447\u0430",D:"Tatar"},uk:{C:"\u0423\u043a\u0440\u0430\u0457\u043d\u0441\u044c\u043a\u0430",D:"Ukrainian"},"uk-UA":{C:"\u0423\u043a\u0440\u0430\u0457\u043d\u0441\u044c\u043a\u0430",
1445
1446
  D:"Ukrainian"},ur:{C:"\u0627\u0631\u062f\u0648",D:"Urdu"},"ur-PK":{C:"\u0627\u0631\u062f\u0648",D:"Urdu"},uz:{C:"O'zbek",D:"Uzbek"},"uz-UZ":{C:"O'zbek",D:"Uzbek"},vi:{C:"Ti\u1ebfng Vi\u1ec7t",D:"Vietnamese"},"vi-VN":{C:"Ti\u1ebfng Vi\u1ec7t",D:"Vietnamese"},"xh-ZA":{C:"isiXhosa",D:"Xhosa"},yi:{C:"\u05d9\u05d9\u05b4\u05d3\u05d9\u05e9",D:"Yiddish"},"yi-DE":{C:"\u05d9\u05d9\u05b4\u05d3\u05d9\u05e9 (German)",D:"Yiddish (German)"},zh:{C:"\u4e2d\u6587",D:"Chinese"},"zh-HANS":{C:"\u4e2d\u6587\u7b80\u4f53",
1446
- D:"Chinese Simplified"},"zh-HANT":{C:"\u4e2d\u6587\u7e41\u9ad4",D:"Chinese Traditional"},"zh-CN":{C:"\u4e2d\u6587\uff08\u4e2d\u56fd\uff09",D:"Chinese Simplified (China)"},"zh-HK":{C:"\u4e2d\u6587\uff08\u9999\u6e2f\uff09",D:"Chinese Traditional (Hong Kong)"},"zh-SG":{C:"\u4e2d\u6587\uff08\u65b0\u52a0\u5761\uff09",D:"Chinese Simplified (Singapore)"},"zh-TW":{C:"\u4e2d\u6587\uff08\u53f0\u7063\uff09",D:"Chinese Traditional (Taiwan)"},"zu-ZA":{C:"isiZulu",D:"Zulu"}},OD=t(Object.keys(ND)),PD=OD.next();!PD.done;PD=
1447
- OD.next()){var QD=PD.value;ND[QD.toLowerCase()]=ND[QD]};function RD(a,b){var c=this;this.parent=a;this.controls=b;this.eventManager=new od;this.localization=this.controls.qa;this.player=this.controls.$c();this.video=this.controls.kc();this.adManager=this.player.Ie();this.ad=b.getAd();this.eventManager.s(this.adManager,"ad-started",function(d){c.ad=d.ad});this.eventManager.s(this.adManager,"ad-stopped",function(){c.ad=null})}
1448
- RD.prototype.release=function(){this.eventManager.release();this.ad=this.adManager=this.video=this.player=this.localization=this.eventManager=this.controls=this.parent=null};P("shaka.ui.Element",RD);RD.prototype.release=RD.prototype.release;function SD(a){return TD(a,"shaka-back-to-overflow-button")}function TD(a,b){a=a.getElementsByClassName(b);return a.length?a[0]:null}function UD(a){a&&(a=TD(a,"shaka-chosen-item"))&&a.parentElement.focus()}function VD(){var a=W("i");a.classList.add("material-icons-round");a.classList.add("shaka-chosen-item");a.textContent="done";a.ariaHidden="true";return a}function WD(a,b){a&&(b?a.classList.remove("shaka-hidden"):a.classList.add("shaka-hidden"))}
1449
- function XD(a,b){var c=Math.floor(a/3600),d=Math.floor(a/60%60);a=Math.floor(a%60);10>a&&(a="0"+a);a=d+":"+a;b&&(10>d&&(a="0"+a),a=c+":"+a);return a};function YD(a,b){RD.call(this,a,b);var c=this;this.i=W("div");this.i.classList.add("shaka-ad-counter");this.parent.appendChild(this.i);this.h=W("span");this.h.classList.add("shaka-ad-counter-span");this.i.appendChild(this.h);this.g=new Ub(function(){var d=Math.round(c.ad.getRemainingTime()),e=c.ad.getDuration();-1!=d&&-1!=e&&(0<d?(d=XD(e-d,!1)+" / "+XD(e,!1),1<c.ad.getSequenceLength()?c.h.textContent=d:(e=c.localization.resolve("AD_TIME"),c.h.textContent=e.replace("[AD_TIME]",d))):(c.g.stop(),c.h.textContent=
1450
- ""))});this.eventManager.s(this.localization,"locale-updated",function(){});this.eventManager.s(this.localization,"locale-changed",function(){});this.eventManager.s(this.adManager,"ad-started",function(){c.g.Pa();c.g.za(.5)});this.eventManager.s(this.adManager,"ad-stopped",function(){c.g.stop();c.h.textContent=""});this.ad&&(this.g.Pa(),this.g.za(.5))}na(YD,RD);YD.prototype.release=function(){this.g.stop();this.g=null;RD.prototype.release.call(this)};P("shaka.ui.AdCounter",YD);function ZD(a,b){RD.call(this,a,b);var c=this;this.g=W("div");this.g.classList.add("shaka-ad-position");WD(this.g,!1);this.parent.appendChild(this.g);this.h=W("span");this.h.classList.add("shaka-ad-position-span");this.g.appendChild(this.h);this.eventManager.s(this.localization,"locale-updated",function(){c.ad&&$D(c)});this.eventManager.s(this.localization,"locale-changed",function(){c.ad&&$D(c)});this.eventManager.s(this.adManager,"ad-started",function(){$D(c)});this.eventManager.s(this.adManager,
1451
- "ad-stopped",function(){c.h.textContent="";WD(c.g,!1)});this.ad&&$D(this)}na(ZD,RD);function $D(a){var b=a.ad.getSequenceLength();if(1<b){var c=a.ad.getPositionInSequence();a.h.textContent=a.localization.resolve("AD_PROGRESS").replace("[AD_ON]",String(c)).replace("[NUM_ADS]",String(b));WD(a.g,!0)}}P("shaka.ui.AdPosition",ZD);function aE(a,b){RD.call(this,a,b);var c=this;this.button=en();this.parent.appendChild(this.button);this.eventManager.s(this.localization,"locale-updated",function(){c.g()});this.eventManager.s(this.localization,"locale-changed",function(){c.g()});this.eventManager.s(this.video,"play",function(){c.g();c.h()});this.eventManager.s(this.video,"pause",function(){c.g();c.h()});this.eventManager.s(this.video,"seeking",function(){c.g();c.h()});this.eventManager.s(this.adManager,"ad-paused",function(){c.g();
1452
- c.h()});this.eventManager.s(this.adManager,"ad-resumed",function(){c.g();c.h()});this.eventManager.s(this.adManager,"ad-started",function(){c.g();c.h()});this.eventManager.s(this.adManager,"ad-stopped",function(){c.g();c.h()});this.eventManager.s(this.button,"click",function(){c.ad&&c.ad.isLinear()?bE(c.controls):cE(c.controls)});this.ad&&(this.g(),this.h())}na(aE,RD);aE.prototype.isPaused=function(){if(this.ad&&this.ad.isLinear())var a=this.ad.isPaused();else a=this.controls,a=a.A.paused&&!a.$;return a};
1453
- aE.prototype.isEnded=function(){return this.ad&&this.ad.isLinear()?!1:this.video.ended};aE.prototype.g=function(){};aE.prototype.h=function(){};P("shaka.ui.PlayButton",aE);function dE(a,b){aE.call(this,a,b);this.button.classList.add("shaka-play-button");this.button.classList.add("shaka-no-propagation");this.h();this.g()}na(dE,aE);dE.prototype.h=function(){this.isPaused()?this.button.setAttribute("icon","play"):this.button.setAttribute("icon","pause")};dE.prototype.g=function(){var a=this.isPaused()?"PLAY":"PAUSE";this.button.ariaLabel=this.localization.resolve(a)};P("shaka.ui.BigPlayButton",dE);function eE(a,b){RD.call(this,a,b);var c=this;this.j=this.controls.g;this.h=this.controls.h;this.i=[];this.g=W("div");this.g.classList.add("shaka-no-propagation");this.g.classList.add("shaka-context-menu");this.g.classList.add("shaka-hidden");this.h.appendChild(this.g);this.eventManager.s(this.h,"contextmenu",function(d){if(c.g.classList.contains("shaka-hidden")){d.preventDefault();var e=c.h.getBoundingClientRect();c.g.style.left=d.clientX-e.left+"px";c.g.style.top=d.clientY-e.top+"px";WD(c.g,!0)}else WD(c.g,
1454
- !1)});this.eventManager.s(window,"click",function(){WD(c.g,!1)});fE(this)}na(eE,RD);eE.prototype.release=function(){this.h=null;for(var a=t(this.i),b=a.next();!b.done;b=a.next())b.value.release();this.i=[];RD.prototype.release.call(this)};function gE(a,b){hE.set(a,b)}function fE(a){for(var b=t(a.j.contextMenuElements),c=b.next();!c.done;c=b.next()){c=c.value;var d=hE.get(c);d?a.i.push(d.create(a.g,a.controls)):Ya("Unrecognized context menu element:",c)}}P("shaka.ui.ContextMenu",eE);
1455
- eE.registerElement=gE;var hE=new Map;function iE(a,b){RD.call(this,a,b);var c=this;this.m=null;this.o=!1;this.j=new Ub(function(){0!=parseInt(c.h.textContent,10)&&(c.video.currentTime=c.controls.qg()+parseInt(c.h.textContent,10));c.g.style.opacity="0";c.o=!1;c.h.textContent="0s"});this.g=W("div");this.parent.appendChild(this.g);this.eventManager.s(this.g,"touchend",function(d){c.controls.lc()&&(c.controls.Jd()?(d.preventDefault(),c.controls.Bc()):0<c.controls.g.tapSeekDistance&&((d.preventDefault(),d=c.controls.g.tapSeekDistance,c.o)?
1456
- c.m+1E3>Date.now()&&(c.j.stop(),c.m=Date.now(),c.h.textContent=(c.l?parseInt(c.h.textContent,10)-d:parseInt(c.h.textContent,10)+d).toString()+"s",c.g.style.opacity="1",c.j.V(1)):(c.o=!0,c.m=Date.now(),c.j.V(1))))});this.h=W("span");this.h.textContent="0s";this.g.appendChild(this.h);this.i=W("span");this.i.classList.add("shaka-forward-rewind-container-icon");this.g.appendChild(this.i);this.l=!1}na(iE,RD);P("shaka.ui.HiddenSeekButton",iE);function jE(a,b){iE.call(this,a,b);this.g.classList.add("shaka-fast-foward-container");this.i.textContent="fast_forward";this.l=!1}na(jE,iE);P("shaka.ui.HiddenFastForwardButton",jE);function kE(a,b){iE.call(this,a,b);this.g.classList.add("shaka-rewind-container");this.i.textContent="fast_rewind";this.l=!0}na(kE,iE);P("shaka.ui.HiddenRewindButton",kE);function lE(a,b,c,d){RD.call(this,a,b);var e=this;this.container=W("div");this.container.classList.add("shaka-range-container");this.container.classList.add.apply(this.container.classList,x(c));this.h=!1;this.bar=document.createElement("input");this.G=new Ub(function(){e.onChangeEnd();e.h=!1});this.bar.classList.add("shaka-range-element");this.bar.classList.add.apply(this.bar.classList,x(d));this.bar.type="range";this.bar.step="any";this.bar.min="0";this.bar.max="1";this.bar.value="0";this.container.appendChild(this.bar);
1457
- this.parent.appendChild(this.container);this.eventManager.s(this.bar,"mousedown",function(f){e.controls.lc()&&(e.h=!0,e.onChangeStart());f.stopPropagation()});this.eventManager.s(this.bar,"touchstart",function(f){e.controls.lc()&&(e.h=!0,mE(e,f),e.onChangeStart());f.stopPropagation()});this.eventManager.s(this.bar,"input",function(){e.onChange()});this.eventManager.s(this.bar,"touchmove",function(f){e.h&&(mE(e,f),e.onChange());f.stopPropagation()});this.eventManager.s(this.bar,"touchend",function(f){e.h&&
1458
- (e.h=!1,mE(e,f),e.onChangeEnd());f.stopPropagation()});this.eventManager.s(this.bar,"touchcancel",function(f){e.h&&(e.h=!1,mE(e,f),e.onChangeEnd());f.stopPropagation()});this.eventManager.s(this.bar,"mouseup",function(f){e.h&&(e.h=!1,e.onChangeEnd());f.stopPropagation()});this.eventManager.s(this.bar,"blur",function(){e.h&&(e.h=!1,e.onChangeEnd())});this.eventManager.s(this.bar,"contextmenu",function(f){f.preventDefault();f.stopPropagation()})}na(lE,RD);q=lE.prototype;
1459
- q.release=function(){this.G&&(this.G.stop(),this.G=null);RD.prototype.release.call(this)};q.setRange=function(a,b){this.bar.min=a;this.bar.max=b};q.onChangeStart=function(){};q.onChange=function(){};q.onChangeEnd=function(){};q.changeTo=function(a){this.h||(this.h=!0,this.onChangeStart());var b=parseFloat(this.bar.min),c=parseFloat(this.bar.max);this.bar.value=a>c?c:a<b?b:a;this.onChange();this.G.V(.5)};q.getValue=function(){return parseFloat(this.bar.value)};
1460
- q.setValue=function(a){this.h||(this.bar.value=a)};function mE(a,b){b.preventDefault();var c=b.changedTouches[0],d=a.bar.getBoundingClientRect();b=parseFloat(a.bar.min);var e=parseFloat(a.bar.max);c=b+(e-b)/d.width*(c.clientX-d.left);c<b?c=b:c>e&&(c=e);a.bar.value=c}P("shaka.ui.RangeElement",lE);lE.prototype.setValue=lE.prototype.setValue;lE.prototype.getValue=lE.prototype.getValue;lE.prototype.changeTo=lE.prototype.changeTo;lE.prototype.onChangeEnd=lE.prototype.onChangeEnd;
1461
- lE.prototype.onChange=lE.prototype.onChange;lE.prototype.onChangeStart=lE.prototype.onChangeStart;lE.prototype.setRange=lE.prototype.setRange;function nE(a,b){lE.call(this,a,b,["shaka-seek-bar-container"],["shaka-seek-bar","shaka-no-propagation","shaka-show-controls-on-mouse-over"]);var c=this;this.F=W("div");this.F.classList.add("shaka-ad-markers");this.container.insertBefore(this.F,this.container.childNodes[0]);this.H=this.controls.g;this.o=new Ub(function(){var d=c.getValue();c.player.U()||d==c.video.duration&&(d-=.001);c.video.currentTime=d});this.I=new Ub(function(){oE(c)});this.K=!1;this.i=W("div");this.i.id="shaka-player-ui-thumbnail-container";
1462
- this.g=W("img");this.g.id="shaka-player-ui-thumbnail-image";this.g.draggable=!1;this.u=W("div");this.u.id="shaka-player-ui-thumbnail-time";this.i.appendChild(this.g);this.i.appendChild(this.u);this.container.appendChild(this.i);this.j=this.l=null;this.J=!1;this.m=new Ub(function(){pE(c)});this.A=[];this.eventManager.s(this.localization,"locale-updated",function(){return qE(c)});this.eventManager.s(this.localization,"locale-changed",function(){return qE(c)});this.eventManager.s(this.adManager,"ad-started",
1463
- function(){rE(c)||WD(c.container,!1)});this.eventManager.s(this.adManager,"ad-stopped",function(){rE(c)&&WD(c.container,!0)});this.eventManager.s(this.adManager,"ad-cue-points-changed",function(d){c.A=d.cuepoints;sE(c)});this.eventManager.s(this.player,"unloading",function(){c.A=[];sE(c);c.j&&(c.j.abort(),c.j=null);c.l=null;pE(c)});this.eventManager.s(this.bar,"mousemove",function(d){if(c.player.Je().length){var e=c.bar.getBoundingClientRect(),f=parseFloat(c.bar.min);d=d.clientX-e.left;tE(c,d,Math.round(f+
1464
- (parseFloat(c.bar.max)-f)/e.width*d))}else pE(c)});this.eventManager.s(this.container,"mouseleave",function(){c.m.stop();c.m.V(.25)});this.setValue(this.video.currentTime);this.update();qE(this);this.ad&&WD(this.container,!1)}na(nE,lE);q=nE.prototype;q.release=function(){this.o&&(this.o.stop(),this.o=null,this.I.stop(),this.I=null);lE.prototype.release.call(this)};q.onChangeStart=function(){this.K=!this.video.paused;this.controls.bh(!0);this.video.pause();this.m.stop();this.J=!0};
1465
- q.onChange=function(){if(this.video.duration)if(this.update(),this.o.V(.125),this.player.Je().length){var a=parseFloat(this.bar.min),b=parseFloat(this.bar.max),c=this.bar.getBoundingClientRect(),d=Math.round(this.getValue());tE(this,(d-a)/((b-a)/c.width),d)}else pE(this)};q.onChangeEnd=function(){this.o.Pa();this.controls.bh(!1);this.K&&this.video.play();this.J&&(this.J=!1,this.m.stop(),this.m.V(.25))};q.isShowing=function(){return!this.container.classList.contains("shaka-hidden")};
1466
- q.update=function(){var a=this.H.seekBarColors,b=this.getValue(),c=this.video.buffered.length,d=c?this.video.buffered.start(0):0,e=c?this.video.buffered.end(c-1):0,f=this.player.Ta(),g=f.end-f.start;this.setRange(f.start,f.end);rE(this)?(WD(this.container,!0),0==c?this.container.style.background=a.base:(c=(Math.max(d,f.start)-f.start)/g||0,e=(Math.min(e,f.end)-f.start)/g||0,b=(Math.min(Math.max(b,f.start),f.end)-f.start)/g||0,this.container.style.background="linear-gradient("+["to right",(this.H.showUnbufferedStart?
1467
- a.base:a.played)+" "+100*c+"%",a.played+" "+100*c+"%",a.played+" "+100*b+"%",a.buffered+" "+100*b+"%",a.buffered+" "+100*e+"%",a.base+" "+100*e+"%"].join()+")")):WD(this.container,!1)};
1468
- function oE(a){if(a.A.length){for(var b=a.player.Ta(),c=b.end-b.start,d=["to right"],e=[],f=a.H.seekBarColors.adBreaks,g=!1,h=t(a.A),k=h.next();!k.done;k=h.next())if(k=k.value,-1!=k.start||k.end||(g=!0),k.start>=b.start&&k.start<b.end&&!(k.end&&k.end>b.end)){var l=(k.start-b.start)/c||0,m=l+.01;k.end&&(m=(k.end-b.start)/c||0);e.push({start:l,end:m})}b=t(e);for(k=b.next();!k.done;k=b.next())c=k.value,d.push("transparent "+100*c.start+"%"),d.push(f+" "+100*c.start+"%"),d.push(f+" "+100*c.end+"%"),d.push("transparent "+
1469
- 100*c.end+"%");g&&(d.push("transparent 99%"),d.push(f+" 99%"));a.F.style.background="linear-gradient("+d.join(",")+")"}else a.F.style.background="transparent"}function sE(a){oE(a);var b=a.player.Ta();b=b.end-b.start;a.player.U()&&5<b&&a.I.za(1)}function rE(a){var b=a.player.Ta();b=b.end-b.start;return a.player.U()&&5>b?!1:null==a.ad||!a.ad.isLinear()}function qE(a){a.bar.ariaLabel=a.localization.resolve("SEEK")}
1470
- function tE(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y;O(function(B){switch(B.g){case 1:d=uE(a);if(!d)return pE(a),B.return();0>c&&(c=0);e=a.player.Ta();f=Math.max(Math.ceil(e.start),Math.min(Math.floor(e.end),c));return E(B,a.player.vg(d.id,f),2);case 2:g=B.h;if(!g||!g.uris.length)return pE(a),B.return();a.player.U()?(h=e.end-c,a.u.textContent=1>h?a.localization.resolve("LIVE"):"-"+vE(h)):a.u.textContent=vE(c);k=-10;l=a.i.clientWidth;m=Math.floor(9*l/16);a.i.style.height=m+"px";a.i.style.top=
1447
+ D:"Chinese Simplified"},"zh-HANT":{C:"\u4e2d\u6587\u7e41\u9ad4",D:"Chinese Traditional"},"zh-CN":{C:"\u4e2d\u6587\uff08\u4e2d\u56fd\uff09",D:"Chinese Simplified (China)"},"zh-HK":{C:"\u4e2d\u6587\uff08\u9999\u6e2f\uff09",D:"Chinese Traditional (Hong Kong)"},"zh-SG":{C:"\u4e2d\u6587\uff08\u65b0\u52a0\u5761\uff09",D:"Chinese Simplified (Singapore)"},"zh-TW":{C:"\u4e2d\u6587\uff08\u53f0\u7063\uff09",D:"Chinese Traditional (Taiwan)"},"zu-ZA":{C:"isiZulu",D:"Zulu"}},PD=t(Object.keys(OD)),QD=PD.next();!QD.done;QD=
1448
+ PD.next()){var RD=QD.value;OD[RD.toLowerCase()]=OD[RD]};function SD(a,b){var c=this;this.parent=a;this.controls=b;this.eventManager=new od;this.localization=this.controls.qa;this.player=this.controls.bd();this.video=this.controls.lc();this.adManager=this.player.Ie();this.ad=b.getAd();this.eventManager.s(this.adManager,"ad-started",function(d){c.ad=d.ad});this.eventManager.s(this.adManager,"ad-stopped",function(){c.ad=null})}
1449
+ SD.prototype.release=function(){this.eventManager.release();this.ad=this.adManager=this.video=this.player=this.localization=this.eventManager=this.controls=this.parent=null};P("shaka.ui.Element",SD);SD.prototype.release=SD.prototype.release;function TD(a){return UD(a,"shaka-back-to-overflow-button")}function UD(a,b){a=a.getElementsByClassName(b);return a.length?a[0]:null}function VD(a){a&&(a=UD(a,"shaka-chosen-item"))&&a.parentElement.focus()}function WD(){var a=W("i");a.classList.add("material-icons-round");a.classList.add("shaka-chosen-item");a.textContent="done";a.ariaHidden="true";return a}function XD(a,b){a&&(b?a.classList.remove("shaka-hidden"):a.classList.add("shaka-hidden"))}
1450
+ function YD(a,b){var c=Math.floor(a/3600),d=Math.floor(a/60%60);a=Math.floor(a%60);10>a&&(a="0"+a);a=d+":"+a;b&&(10>d&&(a="0"+a),a=c+":"+a);return a};function ZD(a,b){SD.call(this,a,b);var c=this;this.i=W("div");this.i.classList.add("shaka-ad-counter");this.parent.appendChild(this.i);this.h=W("span");this.h.classList.add("shaka-ad-counter-span");this.i.appendChild(this.h);this.g=new Ub(function(){var d=Math.round(c.ad.getRemainingTime()),e=c.ad.getDuration();-1!=d&&-1!=e&&(0<d?(d=YD(e-d,!1)+" / "+YD(e,!1),1<c.ad.getSequenceLength()?c.h.textContent=d:(e=c.localization.resolve("AD_TIME"),c.h.textContent=e.replace("[AD_TIME]",d))):(c.g.stop(),c.h.textContent=
1451
+ ""))});this.eventManager.s(this.localization,"locale-updated",function(){});this.eventManager.s(this.localization,"locale-changed",function(){});this.eventManager.s(this.adManager,"ad-started",function(){c.g.Pa();c.g.za(.5)});this.eventManager.s(this.adManager,"ad-stopped",function(){c.g.stop();c.h.textContent=""});this.ad&&(this.g.Pa(),this.g.za(.5))}na(ZD,SD);ZD.prototype.release=function(){this.g.stop();this.g=null;SD.prototype.release.call(this)};P("shaka.ui.AdCounter",ZD);function $D(a,b){SD.call(this,a,b);var c=this;this.g=W("div");this.g.classList.add("shaka-ad-position");XD(this.g,!1);this.parent.appendChild(this.g);this.h=W("span");this.h.classList.add("shaka-ad-position-span");this.g.appendChild(this.h);this.eventManager.s(this.localization,"locale-updated",function(){c.ad&&aE(c)});this.eventManager.s(this.localization,"locale-changed",function(){c.ad&&aE(c)});this.eventManager.s(this.adManager,"ad-started",function(){aE(c)});this.eventManager.s(this.adManager,
1452
+ "ad-stopped",function(){c.h.textContent="";XD(c.g,!1)});this.ad&&aE(this)}na($D,SD);function aE(a){var b=a.ad.getSequenceLength();if(1<b){var c=a.ad.getPositionInSequence();a.h.textContent=a.localization.resolve("AD_PROGRESS").replace("[AD_ON]",String(c)).replace("[NUM_ADS]",String(b));XD(a.g,!0)}}P("shaka.ui.AdPosition",$D);function bE(a,b){SD.call(this,a,b);var c=this;this.button=en();this.parent.appendChild(this.button);this.eventManager.s(this.localization,"locale-updated",function(){c.g()});this.eventManager.s(this.localization,"locale-changed",function(){c.g()});this.eventManager.s(this.video,"play",function(){c.g();c.h()});this.eventManager.s(this.video,"pause",function(){c.g();c.h()});this.eventManager.s(this.video,"seeking",function(){c.g();c.h()});this.eventManager.s(this.adManager,"ad-paused",function(){c.g();
1453
+ c.h()});this.eventManager.s(this.adManager,"ad-resumed",function(){c.g();c.h()});this.eventManager.s(this.adManager,"ad-started",function(){c.g();c.h()});this.eventManager.s(this.adManager,"ad-stopped",function(){c.g();c.h()});this.eventManager.s(this.button,"click",function(){c.ad&&c.ad.isLinear()?cE(c.controls):dE(c.controls)});this.ad&&(this.g(),this.h())}na(bE,SD);bE.prototype.isPaused=function(){if(this.ad&&this.ad.isLinear())var a=this.ad.isPaused();else a=this.controls,a=a.A.paused&&!a.$;return a};
1454
+ bE.prototype.isEnded=function(){return this.ad&&this.ad.isLinear()?!1:this.video.ended};bE.prototype.g=function(){};bE.prototype.h=function(){};P("shaka.ui.PlayButton",bE);function eE(a,b){bE.call(this,a,b);this.button.classList.add("shaka-play-button");this.button.classList.add("shaka-no-propagation");this.h();this.g()}na(eE,bE);eE.prototype.h=function(){this.isPaused()?this.button.setAttribute("icon","play"):this.button.setAttribute("icon","pause")};eE.prototype.g=function(){var a=this.isPaused()?"PLAY":"PAUSE";this.button.ariaLabel=this.localization.resolve(a)};P("shaka.ui.BigPlayButton",eE);function fE(a,b){SD.call(this,a,b);var c=this;this.j=this.controls.g;this.h=this.controls.h;this.i=[];this.g=W("div");this.g.classList.add("shaka-no-propagation");this.g.classList.add("shaka-context-menu");this.g.classList.add("shaka-hidden");this.h.appendChild(this.g);this.eventManager.s(this.h,"contextmenu",function(d){if(c.g.classList.contains("shaka-hidden")){d.preventDefault();var e=c.h.getBoundingClientRect();c.g.style.left=d.clientX-e.left+"px";c.g.style.top=d.clientY-e.top+"px";XD(c.g,!0)}else XD(c.g,
1455
+ !1)});this.eventManager.s(window,"click",function(){XD(c.g,!1)});gE(this)}na(fE,SD);fE.prototype.release=function(){this.h=null;for(var a=t(this.i),b=a.next();!b.done;b=a.next())b.value.release();this.i=[];SD.prototype.release.call(this)};function hE(a,b){iE.set(a,b)}function gE(a){for(var b=t(a.j.contextMenuElements),c=b.next();!c.done;c=b.next()){c=c.value;var d=iE.get(c);d?a.i.push(d.create(a.g,a.controls)):Ya("Unrecognized context menu element:",c)}}P("shaka.ui.ContextMenu",fE);
1456
+ fE.registerElement=hE;var iE=new Map;function jE(a,b){SD.call(this,a,b);var c=this;this.m=null;this.o=!1;this.j=new Ub(function(){0!=parseInt(c.h.textContent,10)&&(c.video.currentTime=c.controls.qg()+parseInt(c.h.textContent,10));c.g.style.opacity="0";c.o=!1;c.h.textContent="0s"});this.g=W("div");this.parent.appendChild(this.g);this.eventManager.s(this.g,"touchend",function(d){c.controls.mc()&&(c.controls.Jd()?(d.preventDefault(),c.controls.Cc()):0<c.controls.g.tapSeekDistance&&((d.preventDefault(),d=c.controls.g.tapSeekDistance,c.o)?
1457
+ c.m+1E3>Date.now()&&(c.j.stop(),c.m=Date.now(),c.h.textContent=(c.l?parseInt(c.h.textContent,10)-d:parseInt(c.h.textContent,10)+d).toString()+"s",c.g.style.opacity="1",c.j.V(1)):(c.o=!0,c.m=Date.now(),c.j.V(1))))});this.h=W("span");this.h.textContent="0s";this.g.appendChild(this.h);this.i=W("span");this.i.classList.add("shaka-forward-rewind-container-icon");this.g.appendChild(this.i);this.l=!1}na(jE,SD);P("shaka.ui.HiddenSeekButton",jE);function kE(a,b){jE.call(this,a,b);this.g.classList.add("shaka-fast-foward-container");this.i.textContent="fast_forward";this.l=!1}na(kE,jE);P("shaka.ui.HiddenFastForwardButton",kE);function lE(a,b){jE.call(this,a,b);this.g.classList.add("shaka-rewind-container");this.i.textContent="fast_rewind";this.l=!0}na(lE,jE);P("shaka.ui.HiddenRewindButton",lE);function mE(a,b,c,d){SD.call(this,a,b);var e=this;this.container=W("div");this.container.classList.add("shaka-range-container");this.container.classList.add.apply(this.container.classList,x(c));this.h=!1;this.bar=document.createElement("input");this.G=new Ub(function(){e.onChangeEnd();e.h=!1});this.bar.classList.add("shaka-range-element");this.bar.classList.add.apply(this.bar.classList,x(d));this.bar.type="range";this.bar.step="any";this.bar.min="0";this.bar.max="1";this.bar.value="0";this.container.appendChild(this.bar);
1458
+ this.parent.appendChild(this.container);this.eventManager.s(this.bar,"mousedown",function(f){e.controls.mc()&&(e.h=!0,e.onChangeStart());f.stopPropagation()});this.eventManager.s(this.bar,"touchstart",function(f){e.controls.mc()&&(e.h=!0,nE(e,f),e.onChangeStart());f.stopPropagation()});this.eventManager.s(this.bar,"input",function(){e.onChange()});this.eventManager.s(this.bar,"touchmove",function(f){e.h&&(nE(e,f),e.onChange());f.stopPropagation()});this.eventManager.s(this.bar,"touchend",function(f){e.h&&
1459
+ (e.h=!1,nE(e,f),e.onChangeEnd());f.stopPropagation()});this.eventManager.s(this.bar,"touchcancel",function(f){e.h&&(e.h=!1,nE(e,f),e.onChangeEnd());f.stopPropagation()});this.eventManager.s(this.bar,"mouseup",function(f){e.h&&(e.h=!1,e.onChangeEnd());f.stopPropagation()});this.eventManager.s(this.bar,"blur",function(){e.h&&(e.h=!1,e.onChangeEnd())});this.eventManager.s(this.bar,"contextmenu",function(f){f.preventDefault();f.stopPropagation()})}na(mE,SD);q=mE.prototype;
1460
+ q.release=function(){this.G&&(this.G.stop(),this.G=null);SD.prototype.release.call(this)};q.setRange=function(a,b){this.bar.min=a;this.bar.max=b};q.onChangeStart=function(){};q.onChange=function(){};q.onChangeEnd=function(){};q.changeTo=function(a){this.h||(this.h=!0,this.onChangeStart());var b=parseFloat(this.bar.min),c=parseFloat(this.bar.max);this.bar.value=a>c?c:a<b?b:a;this.onChange();this.G.V(.5)};q.getValue=function(){return parseFloat(this.bar.value)};
1461
+ q.setValue=function(a){this.h||(this.bar.value=a)};function nE(a,b){b.preventDefault();var c=b.changedTouches[0],d=a.bar.getBoundingClientRect();b=parseFloat(a.bar.min);var e=parseFloat(a.bar.max);c=b+(e-b)/d.width*(c.clientX-d.left);c<b?c=b:c>e&&(c=e);a.bar.value=c}P("shaka.ui.RangeElement",mE);mE.prototype.setValue=mE.prototype.setValue;mE.prototype.getValue=mE.prototype.getValue;mE.prototype.changeTo=mE.prototype.changeTo;mE.prototype.onChangeEnd=mE.prototype.onChangeEnd;
1462
+ mE.prototype.onChange=mE.prototype.onChange;mE.prototype.onChangeStart=mE.prototype.onChangeStart;mE.prototype.setRange=mE.prototype.setRange;function oE(a,b){mE.call(this,a,b,["shaka-seek-bar-container"],["shaka-seek-bar","shaka-no-propagation","shaka-show-controls-on-mouse-over"]);var c=this;this.F=W("div");this.F.classList.add("shaka-ad-markers");this.container.insertBefore(this.F,this.container.childNodes[0]);this.H=this.controls.g;this.o=new Ub(function(){var d=c.getValue();c.player.U()||d==c.video.duration&&(d-=.001);c.video.currentTime=d});this.I=new Ub(function(){pE(c)});this.K=!1;this.i=W("div");this.i.id="shaka-player-ui-thumbnail-container";
1463
+ this.g=W("img");this.g.id="shaka-player-ui-thumbnail-image";this.g.draggable=!1;this.u=W("div");this.u.id="shaka-player-ui-thumbnail-time";this.i.appendChild(this.g);this.i.appendChild(this.u);this.container.appendChild(this.i);this.j=this.l=null;this.J=!1;this.m=new Ub(function(){qE(c)});this.A=[];this.eventManager.s(this.localization,"locale-updated",function(){return rE(c)});this.eventManager.s(this.localization,"locale-changed",function(){return rE(c)});this.eventManager.s(this.adManager,"ad-started",
1464
+ function(){sE(c)||XD(c.container,!1)});this.eventManager.s(this.adManager,"ad-stopped",function(){sE(c)&&XD(c.container,!0)});this.eventManager.s(this.adManager,"ad-cue-points-changed",function(d){c.A=d.cuepoints;tE(c)});this.eventManager.s(this.player,"unloading",function(){c.A=[];tE(c);c.j&&(c.j.abort(),c.j=null);c.l=null;qE(c)});this.eventManager.s(this.bar,"mousemove",function(d){if(c.player.Je().length){var e=c.bar.getBoundingClientRect(),f=parseFloat(c.bar.min);d=d.clientX-e.left;uE(c,d,Math.round(f+
1465
+ (parseFloat(c.bar.max)-f)/e.width*d))}else qE(c)});this.eventManager.s(this.container,"mouseleave",function(){c.m.stop();c.m.V(.25)});this.setValue(this.video.currentTime);this.update();rE(this);this.ad&&XD(this.container,!1)}na(oE,mE);q=oE.prototype;q.release=function(){this.o&&(this.o.stop(),this.o=null,this.I.stop(),this.I=null);mE.prototype.release.call(this)};q.onChangeStart=function(){this.K=!this.video.paused;this.controls.bh(!0);this.video.pause();this.m.stop();this.J=!0};
1466
+ q.onChange=function(){if(this.video.duration)if(this.update(),this.o.V(.125),this.player.Je().length){var a=parseFloat(this.bar.min),b=parseFloat(this.bar.max),c=this.bar.getBoundingClientRect(),d=Math.round(this.getValue());uE(this,(d-a)/((b-a)/c.width),d)}else qE(this)};q.onChangeEnd=function(){this.o.Pa();this.controls.bh(!1);this.K&&this.video.play();this.J&&(this.J=!1,this.m.stop(),this.m.V(.25))};q.isShowing=function(){return!this.container.classList.contains("shaka-hidden")};
1467
+ q.update=function(){var a=this.H.seekBarColors,b=this.getValue(),c=this.video.buffered.length,d=c?this.video.buffered.start(0):0,e=c?this.video.buffered.end(c-1):0,f=this.player.Ta(),g=f.end-f.start;this.setRange(f.start,f.end);sE(this)?(XD(this.container,!0),0==c?this.container.style.background=a.base:(c=(Math.max(d,f.start)-f.start)/g||0,e=(Math.min(e,f.end)-f.start)/g||0,b=(Math.min(Math.max(b,f.start),f.end)-f.start)/g||0,this.container.style.background="linear-gradient("+["to right",(this.H.showUnbufferedStart?
1468
+ a.base:a.played)+" "+100*c+"%",a.played+" "+100*c+"%",a.played+" "+100*b+"%",a.buffered+" "+100*b+"%",a.buffered+" "+100*e+"%",a.base+" "+100*e+"%"].join()+")")):XD(this.container,!1)};
1469
+ function pE(a){if(a.A.length){for(var b=a.player.Ta(),c=b.end-b.start,d=["to right"],e=[],f=a.H.seekBarColors.adBreaks,g=!1,h=t(a.A),k=h.next();!k.done;k=h.next())if(k=k.value,-1!=k.start||k.end||(g=!0),k.start>=b.start&&k.start<b.end&&!(k.end&&k.end>b.end)){var l=(k.start-b.start)/c||0,m=l+.01;k.end&&(m=(k.end-b.start)/c||0);e.push({start:l,end:m})}b=t(e);for(k=b.next();!k.done;k=b.next())c=k.value,d.push("transparent "+100*c.start+"%"),d.push(f+" "+100*c.start+"%"),d.push(f+" "+100*c.end+"%"),d.push("transparent "+
1470
+ 100*c.end+"%");g&&(d.push("transparent 99%"),d.push(f+" 99%"));a.F.style.background="linear-gradient("+d.join(",")+")"}else a.F.style.background="transparent"}function tE(a){pE(a);var b=a.player.Ta();b=b.end-b.start;a.player.U()&&5<b&&a.I.za(1)}function sE(a){var b=a.player.Ta();b=b.end-b.start;return a.player.U()&&5>b?!1:null==a.ad||!a.ad.isLinear()}function rE(a){a.bar.ariaLabel=a.localization.resolve("SEEK")}
1471
+ function uE(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y;O(function(B){switch(B.g){case 1:d=vE(a);if(!d)return qE(a),B.return();0>c&&(c=0);e=a.player.Ta();f=Math.max(Math.ceil(e.start),Math.min(Math.floor(e.end),c));return E(B,a.player.vg(d.id,f),2);case 2:g=B.h;if(!g||!g.uris.length)return qE(a),B.return();a.player.U()?(h=e.end-c,a.u.textContent=1>h?a.localization.resolve("LIVE"):"-"+wE(h)):a.u.textContent=wE(c);k=-10;l=a.i.clientWidth;m=Math.floor(9*l/16);a.i.style.height=m+"px";a.i.style.top=
1471
1472
  -(m-k)+"px";n=Math.min(a.bar.offsetWidth-l,Math.max(0,b-l/2));a.i.style.left=n+"px";a.i.style.visibility="visible";p=g.uris[0].split("#xywh=")[0];if(a.l&&p===a.l.uris[0].split("#xywh=")[0]&&g.segment.Pb()==a.l.segment.Pb()&&g.segment.Nb()==a.l.segment.Nb()){B.B(3);break}a.l=g;a.j&&(a.j.abort(),a.j=null);if("mjpg"!=d.codecs&&!p.startsWith("offline:")){B.B(4);break}a.g.src='data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg"/>';ta(B,5);r=Gg;u=Bl(g.segment.P(),g.segment.Pb(),g.segment.Nb(),a.player.getConfiguration().streaming.retryParameters);
1472
1473
  a.j=a.player.hc().request(r,u,{type:1});return E(B,a.j.promise,7);case 7:v=B.h;a.j=null;"mjpg"==d.codecs?(w=(new Pg).box("mdat",Zg(function(D){p=URL.createObjectURL(new Blob([D],{type:"image/jpeg"}))})),w.parse(v.data,!1)):(A=d.mimeType||"image/jpeg",z=new Blob([v.data],{type:A}),p=URL.createObjectURL(z));va(B,4);break;case 5:C=wa(B);if(7001==C.code)return B.return();throw C;case 4:try{a.i.removeChild(a.g)}catch(D){}a.g=W("img");a.g.id="shaka-player-ui-thumbnail-image";a.g.draggable=!1;a.g.src=p;
1473
1474
  a.g.onload=function(){p.startsWith("blob:")&&URL.revokeObjectURL(p)};a.i.insertBefore(a.g,a.i.firstChild);case 3:y=l/g.width,g.imageHeight?a.g.height=g.imageHeight:g.sprite||(a.g.style.height="100%",a.g.style.objectFit="contain"),g.imageWidth?a.g.width=g.imageWidth:g.sprite||(a.g.style.width="100%",a.g.style.objectFit="contain"),a.g.style.left="-"+y*g.positionX+"px",a.g.style.top="-"+y*g.positionY+"px",a.g.style.transform="scale("+y+")",a.g.style.transformOrigin="left top",m=Math.floor(l*g.height/
1474
1475
  g.width),a.i.style.height=m+"px",a.i.style.top=-(m-k)+"px",F(B)}})}
1475
- function uE(a){var b=a.player.Je();if(!b.length)return null;for(var c={},d=t(["image/avif","image/webp","image/jpeg","image/png","image/svg+xml"]),e=d.next();!e.done;c={Cf:c.Cf,Af:c.Af},e=d.next())if(c.Cf=e.value,c.Af=a.player.getStats().estimatedBandwidth,(e=b.filter(function(f){return function(g){return g.mimeType.toLowerCase()===f.Cf&&g.bandwidth<.01*f.Af}}(c)).sort(function(f,g){return g.bandwidth-f.bandwidth}))&&e.length)return e[0];return b.find(function(f){return"application/mp4"==f.mimeType&&
1476
- "mjpg"==f.codecs})||b[0]}function pE(a){a.i.style.visibility="hidden";a.u.textContent=""}function vE(a){var b=Math.round(a);a=Math.floor(b/3600);var c=Math.floor((b-3600*a)/60);b=b-3600*a-60*c;10>b&&(b="0"+b);return 0<a?(10>c&&(c="0"+c),a+":"+c+":"+b):c+":"+b}P("shaka.ui.SeekBar",nE);function wE(){}wE.prototype.create=function(a,b){return new nE(a,b)};nE.Factory=wE;function xE(a,b){RD.call(this,a,b);var c=this;this.j=W("div");this.j.classList.add("shaka-skip-ad-container");this.parent.appendChild(this.j);this.h=W("div");this.h.classList.add("shaka-skip-ad-counter");WD(this.h,!1);this.j.appendChild(this.h);this.g=en();this.g.classList.add("shaka-skip-ad-button");this.g.disabled=!0;WD(this.g,!1);this.g.classList.add("shaka-no-propagation");this.j.appendChild(this.g);yE(this);this.i=new Ub(function(){var d=Math.round(c.ad.getTimeUntilSkippable());0<d?c.h.textContent=
1477
- d:(c.i.stop(),WD(c.h,!1))});this.eventManager.s(this.localization,"locale-updated",function(){yE(c)});this.eventManager.s(this.localization,"locale-changed",function(){yE(c)});this.eventManager.s(this.adManager,"ad-started",function(){zE(c)});this.eventManager.s(this.adManager,"ad-skip-state-changed",function(){c.ad.canSkipNow()&&(c.g.disabled=!1,c.i.stop(),WD(c.h,!1))});this.eventManager.s(this.adManager,"ad-stopped",function(){c.i.stop();c.g.disabled=!0;WD(c.g,!1);WD(c.h,!1)});this.eventManager.s(this.g,
1478
- "click",function(){c.ad.skip()});this.ad&&zE(this)}na(xE,RD);xE.prototype.release=function(){this.i.stop();this.i=null;RD.prototype.release.call(this)};function yE(a){a.g.textContent=a.localization.resolve("SKIP_AD")}function zE(a){a.ad.isSkippable()&&(WD(a.g,!0),WD(a.h,!0),a.h.textContent="",a.i.Pa(),a.i.za(.5))}P("shaka.ui.SkipAdButton",xE);/*
1476
+ function vE(a){var b=a.player.Je();if(!b.length)return null;for(var c={},d=t(["image/avif","image/webp","image/jpeg","image/png","image/svg+xml"]),e=d.next();!e.done;c={Cf:c.Cf,Af:c.Af},e=d.next())if(c.Cf=e.value,c.Af=a.player.getStats().estimatedBandwidth,(e=b.filter(function(f){return function(g){return g.mimeType.toLowerCase()===f.Cf&&g.bandwidth<.01*f.Af}}(c)).sort(function(f,g){return g.bandwidth-f.bandwidth}))&&e.length)return e[0];return b.find(function(f){return"application/mp4"==f.mimeType&&
1477
+ "mjpg"==f.codecs})||b[0]}function qE(a){a.i.style.visibility="hidden";a.u.textContent=""}function wE(a){var b=Math.round(a);a=Math.floor(b/3600);var c=Math.floor((b-3600*a)/60);b=b-3600*a-60*c;10>b&&(b="0"+b);return 0<a?(10>c&&(c="0"+c),a+":"+c+":"+b):c+":"+b}P("shaka.ui.SeekBar",oE);function xE(){}xE.prototype.create=function(a,b){return new oE(a,b)};oE.Factory=xE;function yE(a,b){SD.call(this,a,b);var c=this;this.j=W("div");this.j.classList.add("shaka-skip-ad-container");this.parent.appendChild(this.j);this.h=W("div");this.h.classList.add("shaka-skip-ad-counter");XD(this.h,!1);this.j.appendChild(this.h);this.g=en();this.g.classList.add("shaka-skip-ad-button");this.g.disabled=!0;XD(this.g,!1);this.g.classList.add("shaka-no-propagation");this.j.appendChild(this.g);zE(this);this.i=new Ub(function(){var d=Math.round(c.ad.getTimeUntilSkippable());0<d?c.h.textContent=
1478
+ d:(c.i.stop(),XD(c.h,!1))});this.eventManager.s(this.localization,"locale-updated",function(){zE(c)});this.eventManager.s(this.localization,"locale-changed",function(){zE(c)});this.eventManager.s(this.adManager,"ad-started",function(){AE(c)});this.eventManager.s(this.adManager,"ad-skip-state-changed",function(){c.ad.canSkipNow()&&(c.g.disabled=!1,c.i.stop(),XD(c.h,!1))});this.eventManager.s(this.adManager,"ad-stopped",function(){c.i.stop();c.g.disabled=!0;XD(c.g,!1);XD(c.h,!1)});this.eventManager.s(this.g,
1479
+ "click",function(){c.ad.skip()});this.ad&&AE(this)}na(yE,SD);yE.prototype.release=function(){this.i.stop();this.i=null;SD.prototype.release.call(this)};function zE(a){a.g.textContent=a.localization.resolve("SKIP_AD")}function AE(a){a.ad.isSkippable()&&(XD(a.g,!0),XD(a.h,!0),a.h.textContent="",a.i.Pa(),a.i.za(.5))}P("shaka.ui.SkipAdButton",yE);/*
1479
1480
  @license
1480
1481
  glMatrix: https://github.com/toji/gl-matrix/
1481
1482
  Copyright 2015-2021, Brandon Jones, Colin MacKenzie IV
1482
1483
  SPDX-License-Identifier: MIT
1483
1484
  */
1484
- function AE(){var a=new Float32Array(16);a[0]=1;a[5]=1;a[10]=1;a[15]=1;return a}function BE(a,b,c){b=1/Math.tan(b/2);a[0]=b/c;a[1]=0;a[2]=0;a[3]=0;a[4]=0;a[5]=b;a[6]=0;a[7]=0;a[8]=0;a[9]=0;a[11]=-1;a[12]=0;a[13]=0;a[15]=0;c=1/-99.9;a[10]=100.1*c;a[14]=20*c}
1485
- function CE(a,b,c){var d=b[0],e=b[1],f=b[2],g=b[3],h=b[4],k=b[5],l=b[6],m=b[7],n=b[8],p=b[9],r=b[10],u=b[11],v=b[12],w=b[13],A=b[14];b=b[15];var z=c[0],C=c[1],y=c[2],B=c[3];a[0]=z*d+C*h+y*n+B*v;a[1]=z*e+C*k+y*p+B*w;a[2]=z*f+C*l+y*r+B*A;a[3]=z*g+C*m+y*u+B*b;z=c[4];C=c[5];y=c[6];B=c[7];a[4]=z*d+C*h+y*n+B*v;a[5]=z*e+C*k+y*p+B*w;a[6]=z*f+C*l+y*r+B*A;a[7]=z*g+C*m+y*u+B*b;z=c[8];C=c[9];y=c[10];B=c[11];a[8]=z*d+C*h+y*n+B*v;a[9]=z*e+C*k+y*p+B*w;a[10]=z*f+C*l+y*r+B*A;a[11]=z*g+C*m+y*u+B*b;z=c[12];C=c[13];
1485
+ function BE(){var a=new Float32Array(16);a[0]=1;a[5]=1;a[10]=1;a[15]=1;return a}function CE(a,b,c){b=1/Math.tan(b/2);a[0]=b/c;a[1]=0;a[2]=0;a[3]=0;a[4]=0;a[5]=b;a[6]=0;a[7]=0;a[8]=0;a[9]=0;a[11]=-1;a[12]=0;a[13]=0;a[15]=0;c=1/-99.9;a[10]=100.1*c;a[14]=20*c}
1486
+ function DE(a,b,c){var d=b[0],e=b[1],f=b[2],g=b[3],h=b[4],k=b[5],l=b[6],m=b[7],n=b[8],p=b[9],r=b[10],u=b[11],v=b[12],w=b[13],A=b[14];b=b[15];var z=c[0],C=c[1],y=c[2],B=c[3];a[0]=z*d+C*h+y*n+B*v;a[1]=z*e+C*k+y*p+B*w;a[2]=z*f+C*l+y*r+B*A;a[3]=z*g+C*m+y*u+B*b;z=c[4];C=c[5];y=c[6];B=c[7];a[4]=z*d+C*h+y*n+B*v;a[5]=z*e+C*k+y*p+B*w;a[6]=z*f+C*l+y*r+B*A;a[7]=z*g+C*m+y*u+B*b;z=c[8];C=c[9];y=c[10];B=c[11];a[8]=z*d+C*h+y*n+B*v;a[9]=z*e+C*k+y*p+B*w;a[10]=z*f+C*l+y*r+B*A;a[11]=z*g+C*m+y*u+B*b;z=c[12];C=c[13];
1486
1487
  y=c[14];B=c[15];a[12]=z*d+C*h+y*n+B*v;a[13]=z*e+C*k+y*p+B*w;a[14]=z*f+C*l+y*r+B*A;a[15]=z*g+C*m+y*u+B*b}
1487
- function DE(a,b){var c=new Float32Array(3),d=b[0],e=b[1],f=b[2],g=b[4],h=b[5],k=b[6],l=b[8],m=b[9],n=b[10];c[0]=Math.sqrt(d*d+e*e+f*f);c[1]=Math.sqrt(g*g+h*h+k*k);c[2]=Math.sqrt(l*l+m*m+n*n);k=1/c[0];l=1/c[1];m=1/c[2];g=b[0]*k;c=b[1]*l;d=b[2]*m;e=b[4]*k;h=b[5]*l;f=b[6]*m;k*=b[8];l*=b[9];b=b[10]*m;m=g+h+b;0<m?(b=2*Math.sqrt(m+1),a[3]=.25*b,a[0]=(f-l)/b,a[1]=(k-d)/b,a[2]=(c-e)/b):g>h&&g>b?(b=2*Math.sqrt(1+g-h-b),a[3]=(f-l)/b,a[0]=.25*b,a[1]=(c+e)/b,a[2]=(k+d)/b):h>b?(b=2*Math.sqrt(1+h-g-b),a[3]=(k-
1488
- d)/b,a[0]=(c+e)/b,a[1]=.25*b,a[2]=(f+l)/b):(b=2*Math.sqrt(1+b-g-h),a[3]=(c-e)/b,a[0]=(k+d)/b,a[1]=(f+l)/b,a[2]=.25*b)}function EE(a,b){var c=b[0],d=b[1],e=b[2];b=b[3];var f=c+c,g=d+d,h=e+e;c*=f;var k=d*f;d*=g;var l=e*f,m=e*g;e*=h;f*=b;g*=b;b*=h;a[0]=1-d-e;a[1]=k+b;a[2]=l-g;a[3]=0;a[4]=k-b;a[5]=1-c-e;a[6]=m+f;a[7]=0;a[8]=l+g;a[9]=m-f;a[10]=1-c-d;a[11]=0;a[12]=0;a[13]=0;a[14]=0;a[15]=1};function FE(){var a=new Float32Array(4);a[3]=1;return a}function GE(a,b){var c=b[0],d=b[1],e=b[2];b=b[3];var f=c*c+d*d+e*e+b*b;0<f&&(f=1/Math.sqrt(f));a[0]=c*f;a[1]=d*f;a[2]=e*f;a[3]=b*f};function HE(a,b,c,d,e){this.m=a;this.ma=b;this.l=c;this.g=d;this.o=new od;this.L=FE();this.h=FE();this.ha=this.Aa=this.ea=this.j=null;this.G=AE();this.I=AE();this.N=AE();this.$=AE();this.A=null;this.O=!1;this.J=this.u=null;this.na=this.qa=0;this.ba=this.R=this.S=this.K=null;this.H=0;this.i=75;this.Z=0;this.F=e;IE(this)}HE.prototype.release=function(){this.o&&(this.o.release(),this.o=null);this.u&&(this.u.stop(),this.u=null);this.J&&(this.J.stop(),this.J=null)};
1489
- HE.prototype.qd=function(){(this.O=!this.O)||this.g.viewport(0,0,this.l.width,this.l.height);JE(this,!1)};
1490
- function IE(a){KE(a);LE(a);ME(a);NE(a);OE(a);a.o.oa(a.m,"loadeddata",function(){var b;a.o.s(a.m,"canplaythrough",function(){JE(a)});a.o.s(a.m,"playing",function(){a.u&&a.u.stop();if(!b){var c=a.ma.Db();c=t(c);for(var d=c.next();!d.done;d=c.next())(d=d.value.frameRate)&&(!b||b<d)&&(b=d)}b||(b=60);JE(a);a.u=(new Ub(function(){JE(a)})).Pa().za(1/b)});a.o.s(a.m,"pause",function(){a.u&&a.u.stop();a.u=null;JE(a)});a.o.s(a.m,"seeked",function(){JE(a)});a.o.s(document,"visibilitychange",function(){JE(a)})})}
1491
- function KE(a){var b=a.G,c=[0,0,0],d=[1,0,0],e=[0,1,0],f=c[0],g=c[1];c=c[2];var h=e[0];var k=e[1];var l=e[2];var m=d[0];e=d[1];var n=d[2];if(1E-6>Math.abs(f-m)&&1E-6>Math.abs(g-e)&&1E-6>Math.abs(c-n))for(f=0;16>f;f++)b[f]=0==f%5?1:0;else{d=f-m;e=g-e;m=c-n;var p=1/Math.sqrt(d*d+e*e+m*m);d*=p;e*=p;m*=p;n=k*m-l*e;l=l*d-h*m;h=h*e-k*d;(p=Math.sqrt(n*n+l*l+h*h))?(p=1/p,n*=p,l*=p,h*=p):h=l=n=0;k=e*h-m*l;var r=m*n-d*h;var u=d*l-e*n;(p=Math.sqrt(k*k+r*r+u*u))?(p=1/p,k*=p,r*=p,u*=p):u=r=k=0;b[0]=n;b[1]=k;b[2]=
1492
- d;b[3]=0;b[4]=l;b[5]=r;b[6]=e;b[7]=0;b[8]=h;b[9]=u;b[10]=m;b[11]=0;b[12]=-(n*f+l*g+h*c);b[13]=-(k*f+r*g+u*c);b[14]=-(d*f+e*g+m*c);b[15]=1}DE(a.L,a.G);a=b=a.$;c=[4,4,4];f=c[0];g=c[1];c=c[2];b[0]=a[0]*f;b[1]=a[1]*f;b[2]=a[2]*f;b[3]=a[3]*f;b[4]=a[4]*g;b[5]=a[5]*g;b[6]=a[6]*g;b[7]=a[7]*g;b[8]=a[8]*c;b[9]=a[9]*c;b[10]=a[10]*c;b[11]=a[11]*c;b[12]=a[12];b[13]=a[13];b[14]=a[14];b[15]=a[15]}
1493
- function LE(a){PE(a);a.g.viewport(0,0,a.g.drawingBufferWidth,a.g.drawingBufferHeight);a.g.clearColor(0,0,0,1);a.g.enable(a.g.CULL_FACE);a.g.cullFace(a.g.FRONT);a.g.clear(a.g.COLOR_BUFFER_BIT)}
1494
- function ME(a){var b=QE(a,a.g.VERTEX_SHADER),c=QE(a,a.g.FRAGMENT_SHADER);a.j=a.g.createProgram();a.g.attachShader(a.j,b);a.g.attachShader(a.j,c);a.g.linkProgram(a.j);"cubemap"==a.F?(a.S=a.g.getAttribLocation(a.j,"aVertexPosition"),a.R=a.g.getAttribLocation(a.j,"aTextureCoord")):(a.S=a.g.getAttribLocation(a.j,"a_vPosition"),a.g.enableVertexAttribArray(a.S),a.R=a.g.getAttribLocation(a.j,"a_TexCoordinate"),a.g.enableVertexAttribArray(a.R))}
1495
- function QE(a,b){switch(b){case a.g.VERTEX_SHADER:var c="cubemap"==a.F?"attribute vec4 aVertexPosition;\nattribute vec2 aTextureCoord;\nuniform mat4 uModelViewMatrix;\nuniform mat4 uProjectionMatrix;\nvarying highp vec2 vTextureCoord;\nvarying highp vec3 vLighting;\nvoid main(void) {\n gl_Position = uProjectionMatrix * uModelViewMatrix * aVertexPosition;\n vTextureCoord = aTextureCoord;\n}":"attribute vec4 a_vPosition;\n// Per-vertex texture coordinate info\nattribute vec2 a_TexCoordinate;\nuniform mat4 u_VPMatrix;\n// Passed into the fragment shader.\nvarying vec2 v_TexCoordinate;\nvarying vec3 pass_position;\nvoid main()\n{\n gl_Position = u_VPMatrix * a_vPosition;\n // Pass through texture coord\n v_TexCoordinate = a_TexCoordinate;\n pass_position = a_vPosition.xyz;\n}";
1488
+ function EE(a,b){var c=new Float32Array(3),d=b[0],e=b[1],f=b[2],g=b[4],h=b[5],k=b[6],l=b[8],m=b[9],n=b[10];c[0]=Math.sqrt(d*d+e*e+f*f);c[1]=Math.sqrt(g*g+h*h+k*k);c[2]=Math.sqrt(l*l+m*m+n*n);k=1/c[0];l=1/c[1];m=1/c[2];g=b[0]*k;c=b[1]*l;d=b[2]*m;e=b[4]*k;h=b[5]*l;f=b[6]*m;k*=b[8];l*=b[9];b=b[10]*m;m=g+h+b;0<m?(b=2*Math.sqrt(m+1),a[3]=.25*b,a[0]=(f-l)/b,a[1]=(k-d)/b,a[2]=(c-e)/b):g>h&&g>b?(b=2*Math.sqrt(1+g-h-b),a[3]=(f-l)/b,a[0]=.25*b,a[1]=(c+e)/b,a[2]=(k+d)/b):h>b?(b=2*Math.sqrt(1+h-g-b),a[3]=(k-
1489
+ d)/b,a[0]=(c+e)/b,a[1]=.25*b,a[2]=(f+l)/b):(b=2*Math.sqrt(1+b-g-h),a[3]=(c-e)/b,a[0]=(k+d)/b,a[1]=(f+l)/b,a[2]=.25*b)}function FE(a,b){var c=b[0],d=b[1],e=b[2];b=b[3];var f=c+c,g=d+d,h=e+e;c*=f;var k=d*f;d*=g;var l=e*f,m=e*g;e*=h;f*=b;g*=b;b*=h;a[0]=1-d-e;a[1]=k+b;a[2]=l-g;a[3]=0;a[4]=k-b;a[5]=1-c-e;a[6]=m+f;a[7]=0;a[8]=l+g;a[9]=m-f;a[10]=1-c-d;a[11]=0;a[12]=0;a[13]=0;a[14]=0;a[15]=1};function GE(){var a=new Float32Array(4);a[3]=1;return a}function HE(a,b){var c=b[0],d=b[1],e=b[2];b=b[3];var f=c*c+d*d+e*e+b*b;0<f&&(f=1/Math.sqrt(f));a[0]=c*f;a[1]=d*f;a[2]=e*f;a[3]=b*f};function IE(a,b,c,d,e){this.m=a;this.ma=b;this.l=c;this.g=d;this.o=new od;this.L=GE();this.h=GE();this.ha=this.Aa=this.ea=this.j=null;this.G=BE();this.I=BE();this.N=BE();this.$=BE();this.A=null;this.O=!1;this.J=this.u=null;this.na=this.qa=0;this.ba=this.R=this.S=this.K=null;this.H=0;this.i=75;this.X=0;this.F=e;JE(this)}IE.prototype.release=function(){this.o&&(this.o.release(),this.o=null);this.u&&(this.u.stop(),this.u=null);this.J&&(this.J.stop(),this.J=null)};
1490
+ IE.prototype.qd=function(){(this.O=!this.O)||this.g.viewport(0,0,this.l.width,this.l.height);KE(this,!1)};
1491
+ function JE(a){LE(a);ME(a);NE(a);OE(a);PE(a);a.o.oa(a.m,"loadeddata",function(){var b;a.o.s(a.m,"canplaythrough",function(){KE(a)});a.o.s(a.m,"playing",function(){a.u&&a.u.stop();if(!b){var c=a.ma.Db();c=t(c);for(var d=c.next();!d.done;d=c.next())(d=d.value.frameRate)&&(!b||b<d)&&(b=d)}b||(b=60);KE(a);a.u=(new Ub(function(){KE(a)})).Pa().za(1/b)});a.o.s(a.m,"pause",function(){a.u&&a.u.stop();a.u=null;KE(a)});a.o.s(a.m,"seeked",function(){KE(a)});a.o.s(document,"visibilitychange",function(){KE(a)})})}
1492
+ function LE(a){var b=a.G,c=[0,0,0],d=[1,0,0],e=[0,1,0],f=c[0],g=c[1];c=c[2];var h=e[0];var k=e[1];var l=e[2];var m=d[0];e=d[1];var n=d[2];if(1E-6>Math.abs(f-m)&&1E-6>Math.abs(g-e)&&1E-6>Math.abs(c-n))for(f=0;16>f;f++)b[f]=0==f%5?1:0;else{d=f-m;e=g-e;m=c-n;var p=1/Math.sqrt(d*d+e*e+m*m);d*=p;e*=p;m*=p;n=k*m-l*e;l=l*d-h*m;h=h*e-k*d;(p=Math.sqrt(n*n+l*l+h*h))?(p=1/p,n*=p,l*=p,h*=p):h=l=n=0;k=e*h-m*l;var r=m*n-d*h;var u=d*l-e*n;(p=Math.sqrt(k*k+r*r+u*u))?(p=1/p,k*=p,r*=p,u*=p):u=r=k=0;b[0]=n;b[1]=k;b[2]=
1493
+ d;b[3]=0;b[4]=l;b[5]=r;b[6]=e;b[7]=0;b[8]=h;b[9]=u;b[10]=m;b[11]=0;b[12]=-(n*f+l*g+h*c);b[13]=-(k*f+r*g+u*c);b[14]=-(d*f+e*g+m*c);b[15]=1}EE(a.L,a.G);a=b=a.$;c=[4,4,4];f=c[0];g=c[1];c=c[2];b[0]=a[0]*f;b[1]=a[1]*f;b[2]=a[2]*f;b[3]=a[3]*f;b[4]=a[4]*g;b[5]=a[5]*g;b[6]=a[6]*g;b[7]=a[7]*g;b[8]=a[8]*c;b[9]=a[9]*c;b[10]=a[10]*c;b[11]=a[11]*c;b[12]=a[12];b[13]=a[13];b[14]=a[14];b[15]=a[15]}
1494
+ function ME(a){QE(a);a.g.viewport(0,0,a.g.drawingBufferWidth,a.g.drawingBufferHeight);a.g.clearColor(0,0,0,1);a.g.enable(a.g.CULL_FACE);a.g.cullFace(a.g.FRONT);a.g.clear(a.g.COLOR_BUFFER_BIT)}
1495
+ function NE(a){var b=RE(a,a.g.VERTEX_SHADER),c=RE(a,a.g.FRAGMENT_SHADER);a.j=a.g.createProgram();a.g.attachShader(a.j,b);a.g.attachShader(a.j,c);a.g.linkProgram(a.j);"cubemap"==a.F?(a.S=a.g.getAttribLocation(a.j,"aVertexPosition"),a.R=a.g.getAttribLocation(a.j,"aTextureCoord")):(a.S=a.g.getAttribLocation(a.j,"a_vPosition"),a.g.enableVertexAttribArray(a.S),a.R=a.g.getAttribLocation(a.j,"a_TexCoordinate"),a.g.enableVertexAttribArray(a.R))}
1496
+ function RE(a,b){switch(b){case a.g.VERTEX_SHADER:var c="cubemap"==a.F?"attribute vec4 aVertexPosition;\nattribute vec2 aTextureCoord;\nuniform mat4 uModelViewMatrix;\nuniform mat4 uProjectionMatrix;\nvarying highp vec2 vTextureCoord;\nvarying highp vec3 vLighting;\nvoid main(void) {\n gl_Position = uProjectionMatrix * uModelViewMatrix * aVertexPosition;\n vTextureCoord = aTextureCoord;\n}":"attribute vec4 a_vPosition;\n// Per-vertex texture coordinate info\nattribute vec2 a_TexCoordinate;\nuniform mat4 u_VPMatrix;\n// Passed into the fragment shader.\nvarying vec2 v_TexCoordinate;\nvarying vec3 pass_position;\nvoid main()\n{\n gl_Position = u_VPMatrix * a_vPosition;\n // Pass through texture coord\n v_TexCoordinate = a_TexCoordinate;\n pass_position = a_vPosition.xyz;\n}";
1496
1497
  break;case a.g.FRAGMENT_SHADER:c="cubemap"==a.F?"varying highp vec2 vTextureCoord;\nuniform sampler2D uSampler;\nvoid main(void) {\n highp vec4 texelColor = texture2D(uSampler, vTextureCoord);\n gl_FragColor = vec4(texelColor.rgb , texelColor.a);\n}":"precision highp float;\n#define PI 3.141592653589793238462643383279\nvarying vec2 v_TexCoordinate;\nvarying vec3 pass_position;\nuniform sampler2D uSampler;\nvoid main(void) {\nhighp float xValue =\n (PI + atan(pass_position.z, pass_position.x)) / (2.0 * PI);\n vec2 tc = vec2(xValue, v_TexCoordinate.t);\n tc = vec2(tc.x , tc.y);\nhighp vec4 texelColor =\n texture2D(uSampler, tc);\n gl_FragColor = vec4(texelColor.rgb, texelColor.a);\n}";
1497
1498
  break;default:return null}b=a.g.createShader(b);a.g.shaderSource(b,c);a.g.compileShader(b);return b}
1498
- function NE(a){if("cubemap"==a.F)var b={ti:[-1,-1,-1,-1,-1,1,-1,1,1,-1,1,-1,-1,1,-1,-1,1,1,1,1,1,1,1,-1,-1,-1,1,1,-1,1,1,1,1,-1,1,1,1,-1,-1,1,1,-1,1,1,1,1,-1,1,-1,-1,-1,1,-1,-1,1,-1,1,-1,-1,1,-1,-1,-1,-1,1,-1,1,1,-1,1,-1,-1],pi:[2/3,.5,1/3,.5,1/3,0,2/3,0,2/3,.5,2/3,0,1,0,1,.5,1,1,2/3,1,2/3,.5,1,.5,0,.5,0,0,1/3,0,1/3,.5,0,.5,1/3,.5,1/3,1,0,1,1/3,1,1/3,.5,2/3,.5,2/3,1],indices:[0,1,2,0,2,3,4,5,6,4,6,7,8,9,10,8,10,11,12,13,14,12,14,15,16,17,18,16,18,19,20,21,22,20,22,23]};else{b=[];for(var c=[],d=[],
1499
+ function OE(a){if("cubemap"==a.F)var b={ti:[-1,-1,-1,-1,-1,1,-1,1,1,-1,1,-1,-1,1,-1,-1,1,1,1,1,1,1,1,-1,-1,-1,1,1,-1,1,1,1,1,-1,1,1,1,-1,-1,1,1,-1,1,1,1,1,-1,1,-1,-1,-1,1,-1,-1,1,-1,1,-1,-1,1,-1,-1,-1,-1,1,-1,1,1,-1,1,-1,-1],pi:[2/3,.5,1/3,.5,1/3,0,2/3,0,2/3,.5,2/3,0,1,0,1,.5,1,1,2/3,1,2/3,.5,1,.5,0,.5,0,0,1/3,0,1/3,.5,0,.5,1/3,.5,1/3,1,0,1,1/3,1,1/3,.5,2/3,.5,2/3,1],indices:[0,1,2,0,2,3,4,5,6,4,6,7,8,9,10,8,10,11,12,13,14,12,14,15,16,17,18,16,18,19,20,21,22,20,22,23]};else{b=[];for(var c=[],d=[],
1499
1500
  e=0;100>=e;e++){var f=e/100,g=f*Math.PI,h=Math.sin(g);g=Math.cos(g);for(var k=0;100>=k;k++){var l=k/100,m=l*Math.PI*2;b.push(-1*Math.cos(m)*h,g,Math.sin(m)*h);c.push(l);c.push(f)}}for(e=0;100>e;e++)for(f=0;100>f;f++)h=101*e+f,g=h+1,k=101*(e+1)+f,l=k+1,d.push(h,k,g),d.push(g,k,l);b={ti:b,pi:c,indices:d}}a.K=b;a.ea=a.g.createBuffer();a.g.bindBuffer(a.g.ARRAY_BUFFER,a.ea);a.g.bufferData(a.g.ARRAY_BUFFER,new Float32Array(a.K.ti),a.g.STATIC_DRAW);a.Aa=a.g.createBuffer();a.g.bindBuffer(a.g.ARRAY_BUFFER,
1500
1501
  a.Aa);a.g.bufferData(a.g.ARRAY_BUFFER,new Float32Array(a.K.pi),a.g.STATIC_DRAW);a.ha=a.g.createBuffer();a.g.bindBuffer(a.g.ELEMENT_ARRAY_BUFFER,a.ha);a.g.bufferData(a.g.ELEMENT_ARRAY_BUFFER,new Uint16Array(a.K.indices),a.g.STATIC_DRAW)}
1501
- function OE(a){a.ba=a.g.createTexture();a.g.bindTexture(a.g.TEXTURE_2D,a.ba);a.g.texParameteri(a.g.TEXTURE_2D,a.g.TEXTURE_WRAP_S,a.g.CLAMP_TO_EDGE);a.g.texParameteri(a.g.TEXTURE_2D,a.g.TEXTURE_WRAP_T,a.g.CLAMP_TO_EDGE);a.g.texParameteri(a.g.TEXTURE_2D,a.g.TEXTURE_MIN_FILTER,a.g.NEAREST);a.g.texParameteri(a.g.TEXTURE_2D,a.g.TEXTURE_MAG_FILTER,a.g.NEAREST)}
1502
- function JE(a,b){b=void 0===b?!0:b;var c=a.ma.Qd()==To;!a.m||2>a.m.readyState||!c&&0==a.m.playbackRate||(BE(a.I,a.i*Math.PI/180,1.5625),"cubemap"==a.F?BE(a.I,a.i*Math.PI/180,2.5):BE(a.I,a.i*Math.PI/180,1.5625),a.g.useProgram(a.j),a.g.clear(a.g.COLOR_BUFFER_BIT),PE(a),b&&(a.g.activeTexture(a.g.TEXTURE0),a.g.bindTexture(a.g.TEXTURE_2D,a.ba),a.g.pixelStorei(a.g.UNPACK_PREMULTIPLY_ALPHA_WEBGL,0),a.g.texImage2D(a.g.TEXTURE_2D,0,a.g.RGBA,a.g.RGBA,a.g.UNSIGNED_BYTE,a.m)),"equirectangular"==a.F&&(CE(a.N,
1503
- a.G,a.$),CE(a.N,a.I,a.N)),a.g.bindBuffer(a.g.ARRAY_BUFFER,a.ea),a.g.vertexAttribPointer(a.S,3,a.g.FLOAT,!1,0,0),a.g.enableVertexAttribArray(a.S),a.g.bindBuffer(a.g.ARRAY_BUFFER,a.Aa),a.g.vertexAttribPointer(a.R,2,a.g.FLOAT,!1,0,0),a.g.enableVertexAttribArray(a.R),a.g.bindBuffer(a.g.ELEMENT_ARRAY_BUFFER,a.ha),"cubemap"==a.F?(a.g.uniformMatrix4fv(a.g.getUniformLocation(a.j,"uProjectionMatrix"),!1,a.I),a.g.uniformMatrix4fv(a.g.getUniformLocation(a.j,"uModelViewMatrix"),!1,a.N)):a.g.uniformMatrix4fv(a.g.getUniformLocation(a.j,
1502
+ function PE(a){a.ba=a.g.createTexture();a.g.bindTexture(a.g.TEXTURE_2D,a.ba);a.g.texParameteri(a.g.TEXTURE_2D,a.g.TEXTURE_WRAP_S,a.g.CLAMP_TO_EDGE);a.g.texParameteri(a.g.TEXTURE_2D,a.g.TEXTURE_WRAP_T,a.g.CLAMP_TO_EDGE);a.g.texParameteri(a.g.TEXTURE_2D,a.g.TEXTURE_MIN_FILTER,a.g.NEAREST);a.g.texParameteri(a.g.TEXTURE_2D,a.g.TEXTURE_MAG_FILTER,a.g.NEAREST)}
1503
+ function KE(a,b){b=void 0===b?!0:b;var c=a.ma.Qd()==To;!a.m||2>a.m.readyState||!c&&0==a.m.playbackRate||(CE(a.I,a.i*Math.PI/180,1.5625),"cubemap"==a.F?CE(a.I,a.i*Math.PI/180,2.5):CE(a.I,a.i*Math.PI/180,1.5625),a.g.useProgram(a.j),a.g.clear(a.g.COLOR_BUFFER_BIT),QE(a),b&&(a.g.activeTexture(a.g.TEXTURE0),a.g.bindTexture(a.g.TEXTURE_2D,a.ba),a.g.pixelStorei(a.g.UNPACK_PREMULTIPLY_ALPHA_WEBGL,0),a.g.texImage2D(a.g.TEXTURE_2D,0,a.g.RGBA,a.g.RGBA,a.g.UNSIGNED_BYTE,a.m)),"equirectangular"==a.F&&(DE(a.N,
1504
+ a.G,a.$),DE(a.N,a.I,a.N)),a.g.bindBuffer(a.g.ARRAY_BUFFER,a.ea),a.g.vertexAttribPointer(a.S,3,a.g.FLOAT,!1,0,0),a.g.enableVertexAttribArray(a.S),a.g.bindBuffer(a.g.ARRAY_BUFFER,a.Aa),a.g.vertexAttribPointer(a.R,2,a.g.FLOAT,!1,0,0),a.g.enableVertexAttribArray(a.R),a.g.bindBuffer(a.g.ELEMENT_ARRAY_BUFFER,a.ha),"cubemap"==a.F?(a.g.uniformMatrix4fv(a.g.getUniformLocation(a.j,"uProjectionMatrix"),!1,a.I),a.g.uniformMatrix4fv(a.g.getUniformLocation(a.j,"uModelViewMatrix"),!1,a.N)):a.g.uniformMatrix4fv(a.g.getUniformLocation(a.j,
1504
1505
  "u_VPMatrix"),!1,a.N),a.g.uniform1i(a.g.getUniformLocation(a.j,"uSampler"),0),a.O&&a.g.viewport(0,0,a.l.width/2,a.l.height),a.g.drawElements(a.g.TRIANGLES,a.K.indices.length,a.g.UNSIGNED_SHORT,0),a.O&&(a.g.viewport(a.l.width/2,0,a.l.width/2,a.l.height),a.g.drawElements(a.g.TRIANGLES,a.K.indices.length,a.g.UNSIGNED_SHORT,0)))}
1505
- function PE(a){var b=a.m.videoWidth;b||(b=a.l.scrollWidth);var c=a.m.videoHeight;c||(c=a.l.scrollHeight);if(a.qa!==b||a.na!==c){a.l.width=b;a.l.height=c;a.qa=b;a.na=c;var d=b/c,e=a.I,f=-d,g=1/(d-f);e[0]=0*g;e[1]=0;e[2]=0;e[3]=0;e[4]=0;e[5]=0;e[6]=0;e[7]=0;e[8]=(d+f)*g;e[9]=0;e[10]=-1;e[11]=-1;e[12]=0;e[13]=0;e[14]=-0;e[15]=0;a.I=e;a.g.viewport(0,0,b,c)}}
1506
- function RE(a,b,c,d){var e=90*Math.PI/180;var f="cubemap"==a.F?a.N:a.G;var g=Math.sin(b);b=Math.cos(b);var h=f[0],k=f[1],l=f[2],m=f[3],n=f[8],p=f[9],r=f[10],u=f[11];f!==f&&(f[4]=f[4],f[5]=f[5],f[6]=f[6],f[7]=f[7],f[12]=f[12],f[13]=f[13],f[14]=f[14],f[15]=f[15]);f[0]=h*b-n*g;f[1]=k*b-p*g;f[2]=l*b-r*g;f[3]=m*b-u*g;f[8]=h*g+n*b;f[9]=k*g+p*b;f[10]=l*g+r*b;f[11]=m*g+u*b;a.H+=c;a.H<e&&a.H>-e?(e=AE(),g=AE(),b=-1*c,c=Math.sin(b),b=Math.cos(b),h=g[4],k=g[5],l=g[6],m=g[7],n=g[8],p=g[9],r=g[10],u=g[11],g!==
1507
- e&&(e[0]=g[0],e[1]=g[1],e[2]=g[2],e[3]=g[3],e[12]=g[12],e[13]=g[13],e[14]=g[14],e[15]=g[15]),e[4]=h*b+n*c,e[5]=k*b+p*c,e[6]=l*b+r*c,e[7]=m*b+u*c,e[8]=n*b-h*c,e[9]=p*b-k*c,e[10]=r*b-l*c,e[11]=u*b-m*c,CE(f,e,f)):a.H-=c;c=AE();e=AE();g=Math.sin(d);d=Math.cos(d);b=e[0];h=e[1];k=e[2];l=e[3];m=e[4];n=e[5];p=e[6];r=e[7];e!==c&&(c[8]=e[8],c[9]=e[9],c[10]=e[10],c[11]=e[11],c[12]=e[12],c[13]=e[13],c[14]=e[14],c[15]=e[15]);c[0]=b*d+m*g;c[1]=h*d+n*g;c[2]=k*d+p*g;c[3]=l*d+r*g;c[4]=m*d-b*g;c[5]=n*d-h*g;c[6]=p*
1508
- d-k*g;c[7]=r*d-l*g;CE(f,c,f);JE(a,!1)}function SE(a,b){if(void 0===b||b)DE(a.h,a.G),a.Z=0,a.A=FE(),a.A[0]=(a.h[0]-a.L[0])/20,a.A[1]=(a.h[1]-a.L[1])/20,a.A[2]=(a.h[2]-a.L[2])/20,a.A[3]=(a.h[3]-a.L[3])/20;a.h[0]-=a.A[0];a.h[1]-=a.A[1];a.h[2]-=a.A[2];a.h[3]-=a.A[3];b=AE();GE(a.h,a.h);EE(b,a.h);a.G=b;a.J&&(a.J.stop(),a.J=null);20>a.Z?a.J=(new Ub(function(){SE(a,!1);a.H=0;a.Z++;JE(a,!1)})).V(.025):(EE(b,a.L),a.G=b)};function TE(a,b,c,d,e){gb.call(this);var f=this;this.i=a;this.m=b;this.L=c;this.K=d;this.u=e;this.o=new od;this.h=new od;this.G=UE(this);this.g=null;this.j=!1;this.J=this.I=this.H=this.F=this.A=0;this.l=null;this.o.s(d,"loading",function(){f.g&&SE(f.g);VE(f)});this.o.s(d,"spatialvideoinfo",function(g){switch(g.detail.projection){case "hequ":f.l="equirectangular";break;case "fish":f.l="equirectangular";break;default:f.l=null}VE(f)});this.o.s(d,"nospatialvideoinfo",function(){f.l=null;VE(f)});this.o.s(d,
1509
- "unloading",function(){f.l=null;VE(f)});VE(this)}na(TE,gb);q=TE.prototype;q.release=function(){this.o&&(this.o.release(),this.o=null);this.h&&(this.h.release(),this.h=null);this.g&&(this.g.release(),this.g=null);gb.prototype.release.call(this)};q.configure=function(a){this.u=a;VE(this)};q.Vf=function(){return!!this.G};q.Qb=function(){return!!this.g};q.qd=function(){this.g?this.g.qd():Ya("Not playing VR content")};q.zg=function(a){this.g?RE(this.g,a*WE,0,0):Ya("Not playing VR content")};
1510
- q.xg=function(a){this.g?RE(this.g,0,a*WE,0):Ya("Not playing VR content")};q.yg=function(a){this.g?RE(this.g,0,0,a*WE):Ya("Not playing VR content")};
1511
- function VE(a){if(a.m)if(a.u.displayInVrMode||a.l){var b=a.l||a.u.defaultVrProjectionMode;a.g?a.g.F!=b&&(a.h.qb(),a.g.release(),XE(a,b)):(a.m.style.display="",XE(a,b),a.dispatchEvent(new S("vrstatuschanged",(new Map).set("newStatus",a.Qb()))))}else a.u.displayInVrMode||a.l||!a.g||(a.m.style.display="none",a.h.qb(),a.g.release(),a.g=null,a.dispatchEvent(new S("vrstatuschanged",(new Map).set("newStatus",a.Qb()))))}function XE(a,b){a.G&&a.m&&(a.g=new HE(a.L,a.K,a.m,a.G,b),YE(a))}
1512
- function UE(a){if(!a.m||pc())return null;for(var b=t(["webgl2","webgl"]),c=b.next();!c.done;c=b.next())if(c=a.m.getContext(c.value))return c;return null}
1513
- function YE(a){a.h.s(a.i,"mousedown",function(d){if(!a.j){var e=d.clientX;d=d.clientY;a.j=!0;a.A=e;a.F=d}});0<navigator.maxTouchPoints&&a.h.s(a.i,"touchstart",function(d){if(!a.j){var e=d.touches[0].clientX;d=d.touches[0].clientY;a.j=!0;a.A=e;a.F=d}});a.h.s(a.i,"wheel",function(d){if(!a.j){var e=a.g,f=d.deltaY;f/=50;20<=e.i&&100>=e.i&&(e.i+=f);20>e.i?e.i=20:100<e.i&&(e.i=100);JE(e,!1);d.preventDefault();d.stopPropagation()}});a.h.s(a.i,"mousemove",function(d){a.j&&ZE(a,d.clientX,d.clientY)});0<navigator.maxTouchPoints&&
1514
- a.h.s(a.i,"touchmove",function(d){a.j&&ZE(a,d.touches[0].clientX,d.touches[0].clientY);d.preventDefault()});a.h.s(a.i,"mouseleave",function(){a.j=!1});a.h.s(a.i,"mouseup",function(){a.j=!1});0<navigator.maxTouchPoints&&a.h.s(a.i,"touchend",function(){a.j=!1});var b=!1;if(window.DeviceOrientationEvent)if("function"==typeof DeviceMotionEvent.requestPermission){var c=function(){DeviceMotionEvent.requestPermission().then(function(d){"granted"!==d||b||(b=!0,$E(a))})};DeviceMotionEvent.requestPermission().then(function(d){a.h.Xa(a.i,
1515
- "click",c);a.h.Xa(a.i,"mouseup",c);0<navigator.maxTouchPoints&&a.h.Xa(a.i,"touchend",c);"granted"!==d?(a.h.oa(a.i,"click",c),a.h.oa(a.i,"mouseup",c),0<navigator.maxTouchPoints&&a.h.oa(a.i,"touchend",c)):(b=!0,$E(a))}).catch(function(){a.h.Xa(a.i,"click",c);a.h.Xa(a.i,"mouseup",c);0<navigator.maxTouchPoints&&a.h.Xa(a.i,"touchend",c);a.h.oa(a.i,"click",c);a.h.oa(a.i,"mouseup",c);0<navigator.maxTouchPoints&&a.h.oa(a.i,"touchend",c)})}else b=!0,$E(a)}
1516
- function $E(a){a.h.s(window,"deviceorientation",function(b){var c=(b.alpha||0)-a.H,d=(b.beta||0)-a.I,e=(b.gamma||0)-a.J;if(10<Math.abs(c)||10<Math.abs(d)||5<Math.abs(e))d=e=c=0;a.H=b.alpha||0;a.I=b.beta||0;a.J=b.gamma||0;b=screen.orientation.angle;90==b||-90==b?RE(a.g,c*WE*-1,e*WE*-1,0):RE(a.g,c*WE*-1,d*WE,0)})}function ZE(a,b,c){var d=-.6*Math.PI/180;RE(a.g,(b-a.A)*d,-1*(c-a.F)*d,0);a.A=b;a.F=c}var WE=Math.PI/180;function Z(a,b,c,d,e){gb.call(this);var f=this;this.S=!0;this.g=e;this.F=new Hq(c,a,this.g.castReceiverAppId,this.g.castAndroidReceiverCompatible);this.na=!0;this.A=this.F.kc();this.o=c;this.H=this.F.$c();this.ma=a;this.j=b;this.Gc=d;this.Ba=this.H.Ie();this.l=this.m=null;this.$=!1;this.J=[];this.jb=[];this.Za=!1;this.R=new Ub(function(){f.j.style.cursor="none";f.Za=!1;aF(f)});this.ea=new Ub(function(){f.h.removeAttribute("shown");f.L.V(2)});this.L=new Ub(function(){for(var g=t(f.J),h=g.next();!h.done;h=
1517
- g.next())WD(h.value,!1)});this.xa=new Ub(function(){f.lc()&&bF(f)});this.I=null;this.G=[];this.qa=cF();this.i=new od;this.u=null;this.configure(this.g);dF(this);this.ha=new Set;eF(this);this.xa.za(this.g.refreshTickInSeconds);this.i.s(this.qa,"locale-changed",function(g){f.Ba.setLocale(g.locales[0])})}na(Z,gb);q=Z.prototype;
1518
- q.destroy=function(){var a=this;return O(function(b){switch(b.g){case 1:if(document.pictureInPictureElement!=a.o){b.B(2);break}return E(b,document.exitPictureInPicture(),2);case 2:a.i&&(a.i.release(),a.i=null);a.R&&(a.R.stop(),a.R=null);a.ea&&(a.ea.stop(),a.ea=null);a.L&&(a.L.stop(),a.L=null);a.xa&&(a.xa.stop(),a.xa=null);a.u&&(a.u.release(),a.u=null);fF(a);a.h&&(a.j.removeChild(a.h),a.h=null);if(!a.F){b.B(4);break}return E(b,a.F.destroy(),5);case 5:a.F=null;case 4:if(!a.ma){b.B(6);break}return E(b,
1519
- a.ma.destroy(),7);case 7:a.ma=null;case 6:a.H=null,a.o=null,a.A=null,a.qa=null,a.ha.clear(),gb.prototype.release.call(a),F(b)}})};function fF(a){for(var b=t(a.G),c=b.next();!c.done;c=b.next())c.value.release();a.G=[]}function gF(a,b){hF.set(a,b)}q.Hi=function(a){this.na=a;eF(this)};q.Nj=function(){aF(this)};
1520
- q.configure=function(a){this.g=a;this.F.wh(a.castReceiverAppId,a.castAndroidReceiverCompatible);this.l&&(this.l=null);this.Na&&(this.Na=null);this.Ha&&(this.Ha=null);this.u&&this.u.configure(a);this.h?(fn(this.h),fF(this)):(iF(this),jF(this),this.u=new TE(this.h,this.Gc,this.o,this.H,this.g));this.j.classList.add("shaka-video-container");this.o.classList.add("shaka-video");kF(this);this.g.addBigPlayButton&&lF(this);this.g.customContextMenu&&(this.Ha=new eE(this.Z,this),this.G.push(this.Ha));this.ba||
1521
- mF(this);this.g.seekOnTaps&&(nF(this),oF(this));this.Ea=W("div");this.Ea.classList.add("shaka-server-side-ad-container");this.h.appendChild(this.Ea);pF(this);this.J=Array.from(this.j.getElementsByClassName("shaka-settings-menu"));this.J.push.apply(this.J,x(Array.from(this.j.getElementsByClassName("shaka-overflow-menu"))));qF(this);this.jb=Array.from(this.j.getElementsByClassName("shaka-show-controls-on-mouse-over"));aF(this);a=t(this.j.getElementsByClassName("shaka-no-propagation"));for(var b=a.next();!b.done;b=
1522
- a.next()){b=b.value;var c=function(d){return d.stopPropagation()};this.i.s(b,"click",c);this.i.s(b,"dblclick",c)}};q.Yg=function(a){(this.S=a)?(this.j.setAttribute("shaka-controls","true"),this.o.tabIndex=-1,this.o.controls=!1):this.j.removeAttribute("shaka-controls");aF(this)};q.di=function(a){this.o.controls=a;this.o.tabIndex=a?0:-1;a&&this.Yg(!1)};q.getAd=function(){return this.m};q.Ti=function(){return this.F};q.gj=function(){return this.qa};q.yj=function(){return this.j};q.kc=function(){return this.A};
1523
- q.fj=function(){return this.o};q.$c=function(){return this.H};q.ej=function(){return this.ma};q.Yi=function(){return this.h};q.pj=function(){return this.Ea};q.Vi=function(){return this.O};q.Wi=function(){return this.g};q.Kj=function(){return this.$};q.bh=function(a){this.$=a};q.Ej=function(){return this.na};q.qg=function(){return this.l?this.l.getValue():this.A.currentTime};q.gi=function(a){this.I=a};q.Jd=function(){return this.J.some(function(a){return!a.classList.contains("shaka-hidden")})};
1524
- q.Bc=function(){this.L.Pa()};q.Xd=function(){return document.fullscreenEnabled||this.o.webkitSupportsFullscreen?!0:!1};q.ed=function(){if(document.fullscreenEnabled)return!!document.fullscreenElement;var a=this.o;return a.webkitSupportsFullscreen?a.webkitDisplayingFullscreen:!1};
1525
- function rF(a){var b,c,d;return O(function(e){switch(e.g){case 1:ta(e,2);if(!document.fullscreenEnabled){b=a.o;b.webkitSupportsFullscreen&&b.webkitEnterFullscreen();e.B(4);break}if(!document.pictureInPictureElement){e.B(5);break}return E(e,document.exitPictureInPicture(),5);case 5:return c=a.g.fullScreenElement,E(e,c.requestFullscreen({navigationUI:"hide"}),7);case 7:if(!a.g.forceLandscapeOnFullscreen||!screen.orientation){e.B(4);break}ta(e,9);return E(e,screen.orientation.lock("landscape"),11);case 11:va(e,
1526
- 4,2);break;case 9:wa(e,2);case 4:va(e,0);break;case 2:d=wa(e),a.dispatchEvent(new S("error",(new Map).set("detail",d))),F(e)}})}function sF(a){var b;return O(function(c){if(!document.fullscreenEnabled)return b=a.o,b.webkitSupportsFullscreen&&b.webkitExitFullscreen(),c.B(0);screen.orientation&&screen.orientation.unlock();return E(c,document.exitFullscreen(),0)})}q.qf=function(){var a=this;return O(function(b){return a.ed()?E(b,sF(a),0):E(b,rF(a),0)})};
1506
+ function QE(a){var b=a.m.videoWidth;b||(b=a.l.scrollWidth);var c=a.m.videoHeight;c||(c=a.l.scrollHeight);if(a.qa!==b||a.na!==c){a.l.width=b;a.l.height=c;a.qa=b;a.na=c;var d=b/c,e=a.I,f=-d,g=1/(d-f);e[0]=0*g;e[1]=0;e[2]=0;e[3]=0;e[4]=0;e[5]=0;e[6]=0;e[7]=0;e[8]=(d+f)*g;e[9]=0;e[10]=-1;e[11]=-1;e[12]=0;e[13]=0;e[14]=-0;e[15]=0;a.I=e;a.g.viewport(0,0,b,c)}}
1507
+ function SE(a,b,c,d){var e=90*Math.PI/180;var f="cubemap"==a.F?a.N:a.G;var g=Math.sin(b);b=Math.cos(b);var h=f[0],k=f[1],l=f[2],m=f[3],n=f[8],p=f[9],r=f[10],u=f[11];f!==f&&(f[4]=f[4],f[5]=f[5],f[6]=f[6],f[7]=f[7],f[12]=f[12],f[13]=f[13],f[14]=f[14],f[15]=f[15]);f[0]=h*b-n*g;f[1]=k*b-p*g;f[2]=l*b-r*g;f[3]=m*b-u*g;f[8]=h*g+n*b;f[9]=k*g+p*b;f[10]=l*g+r*b;f[11]=m*g+u*b;a.H+=c;a.H<e&&a.H>-e?(e=BE(),g=BE(),b=-1*c,c=Math.sin(b),b=Math.cos(b),h=g[4],k=g[5],l=g[6],m=g[7],n=g[8],p=g[9],r=g[10],u=g[11],g!==
1508
+ e&&(e[0]=g[0],e[1]=g[1],e[2]=g[2],e[3]=g[3],e[12]=g[12],e[13]=g[13],e[14]=g[14],e[15]=g[15]),e[4]=h*b+n*c,e[5]=k*b+p*c,e[6]=l*b+r*c,e[7]=m*b+u*c,e[8]=n*b-h*c,e[9]=p*b-k*c,e[10]=r*b-l*c,e[11]=u*b-m*c,DE(f,e,f)):a.H-=c;c=BE();e=BE();g=Math.sin(d);d=Math.cos(d);b=e[0];h=e[1];k=e[2];l=e[3];m=e[4];n=e[5];p=e[6];r=e[7];e!==c&&(c[8]=e[8],c[9]=e[9],c[10]=e[10],c[11]=e[11],c[12]=e[12],c[13]=e[13],c[14]=e[14],c[15]=e[15]);c[0]=b*d+m*g;c[1]=h*d+n*g;c[2]=k*d+p*g;c[3]=l*d+r*g;c[4]=m*d-b*g;c[5]=n*d-h*g;c[6]=p*
1509
+ d-k*g;c[7]=r*d-l*g;DE(f,c,f);KE(a,!1)}function TE(a,b){if(void 0===b||b)EE(a.h,a.G),a.X=0,a.A=GE(),a.A[0]=(a.h[0]-a.L[0])/20,a.A[1]=(a.h[1]-a.L[1])/20,a.A[2]=(a.h[2]-a.L[2])/20,a.A[3]=(a.h[3]-a.L[3])/20;a.h[0]-=a.A[0];a.h[1]-=a.A[1];a.h[2]-=a.A[2];a.h[3]-=a.A[3];b=BE();HE(a.h,a.h);FE(b,a.h);a.G=b;a.J&&(a.J.stop(),a.J=null);20>a.X?a.J=(new Ub(function(){TE(a,!1);a.H=0;a.X++;KE(a,!1)})).V(.025):(FE(b,a.L),a.G=b)};function UE(a,b,c,d,e){gb.call(this);var f=this;this.i=a;this.m=b;this.L=c;this.K=d;this.u=e;this.o=new od;this.h=new od;this.G=VE(this);this.g=null;this.j=!1;this.J=this.I=this.H=this.F=this.A=0;this.l=null;this.o.s(d,"loading",function(){f.g&&TE(f.g);WE(f)});this.o.s(d,"spatialvideoinfo",function(g){switch(g.detail.projection){case "hequ":f.l="equirectangular";break;case "fish":f.l="equirectangular";break;default:f.l=null}WE(f)});this.o.s(d,"nospatialvideoinfo",function(){f.l=null;WE(f)});this.o.s(d,
1510
+ "unloading",function(){f.l=null;WE(f)});WE(this)}na(UE,gb);q=UE.prototype;q.release=function(){this.o&&(this.o.release(),this.o=null);this.h&&(this.h.release(),this.h=null);this.g&&(this.g.release(),this.g=null);gb.prototype.release.call(this)};q.configure=function(a){this.u=a;WE(this)};q.Vf=function(){return!!this.G};q.Qb=function(){return!!this.g};q.qd=function(){this.g?this.g.qd():Ya("Not playing VR content")};q.zg=function(a){this.g?SE(this.g,a*XE,0,0):Ya("Not playing VR content")};
1511
+ q.xg=function(a){this.g?SE(this.g,0,a*XE,0):Ya("Not playing VR content")};q.yg=function(a){this.g?SE(this.g,0,0,a*XE):Ya("Not playing VR content")};
1512
+ function WE(a){if(a.m)if(a.u.displayInVrMode||a.l){var b=a.l||a.u.defaultVrProjectionMode;a.g?a.g.F!=b&&(a.h.qb(),a.g.release(),YE(a,b)):(a.m.style.display="",YE(a,b),a.dispatchEvent(new S("vrstatuschanged",(new Map).set("newStatus",a.Qb()))))}else a.u.displayInVrMode||a.l||!a.g||(a.m.style.display="none",a.h.qb(),a.g.release(),a.g=null,a.dispatchEvent(new S("vrstatuschanged",(new Map).set("newStatus",a.Qb()))))}function YE(a,b){a.G&&a.m&&(a.g=new IE(a.L,a.K,a.m,a.G,b),ZE(a))}
1513
+ function VE(a){if(!a.m||pc())return null;for(var b=t(["webgl2","webgl"]),c=b.next();!c.done;c=b.next())if(c=a.m.getContext(c.value))return c;return null}
1514
+ function ZE(a){a.h.s(a.i,"mousedown",function(d){if(!a.j){var e=d.clientX;d=d.clientY;a.j=!0;a.A=e;a.F=d}});0<navigator.maxTouchPoints&&a.h.s(a.i,"touchstart",function(d){if(!a.j){var e=d.touches[0].clientX;d=d.touches[0].clientY;a.j=!0;a.A=e;a.F=d}});a.h.s(a.i,"wheel",function(d){if(!a.j){var e=a.g,f=d.deltaY;f/=50;20<=e.i&&100>=e.i&&(e.i+=f);20>e.i?e.i=20:100<e.i&&(e.i=100);KE(e,!1);d.preventDefault();d.stopPropagation()}});a.h.s(a.i,"mousemove",function(d){a.j&&$E(a,d.clientX,d.clientY)});0<navigator.maxTouchPoints&&
1515
+ a.h.s(a.i,"touchmove",function(d){a.j&&$E(a,d.touches[0].clientX,d.touches[0].clientY);d.preventDefault()});a.h.s(a.i,"mouseleave",function(){a.j=!1});a.h.s(a.i,"mouseup",function(){a.j=!1});0<navigator.maxTouchPoints&&a.h.s(a.i,"touchend",function(){a.j=!1});var b=!1;if(window.DeviceOrientationEvent)if("function"==typeof DeviceMotionEvent.requestPermission){var c=function(){DeviceMotionEvent.requestPermission().then(function(d){"granted"!==d||b||(b=!0,aF(a))})};DeviceMotionEvent.requestPermission().then(function(d){a.h.Xa(a.i,
1516
+ "click",c);a.h.Xa(a.i,"mouseup",c);0<navigator.maxTouchPoints&&a.h.Xa(a.i,"touchend",c);"granted"!==d?(a.h.oa(a.i,"click",c),a.h.oa(a.i,"mouseup",c),0<navigator.maxTouchPoints&&a.h.oa(a.i,"touchend",c)):(b=!0,aF(a))}).catch(function(){a.h.Xa(a.i,"click",c);a.h.Xa(a.i,"mouseup",c);0<navigator.maxTouchPoints&&a.h.Xa(a.i,"touchend",c);a.h.oa(a.i,"click",c);a.h.oa(a.i,"mouseup",c);0<navigator.maxTouchPoints&&a.h.oa(a.i,"touchend",c)})}else b=!0,aF(a)}
1517
+ function aF(a){a.h.s(window,"deviceorientation",function(b){var c=(b.alpha||0)-a.H,d=(b.beta||0)-a.I,e=(b.gamma||0)-a.J;if(10<Math.abs(c)||10<Math.abs(d)||5<Math.abs(e))d=e=c=0;a.H=b.alpha||0;a.I=b.beta||0;a.J=b.gamma||0;b=screen.orientation.angle;90==b||-90==b?SE(a.g,c*XE*-1,e*XE*-1,0):SE(a.g,c*XE*-1,d*XE,0)})}function $E(a,b,c){var d=-.6*Math.PI/180;SE(a.g,(b-a.A)*d,-1*(c-a.F)*d,0);a.A=b;a.F=c}var XE=Math.PI/180;function Z(a,b,c,d,e){gb.call(this);var f=this;this.S=!0;this.g=e;this.F=new Hq(c,a,this.g.castReceiverAppId,this.g.castAndroidReceiverCompatible);this.na=!0;this.A=this.F.lc();this.o=c;this.H=this.F.bd();this.ma=a;this.j=b;this.Hc=d;this.Ba=this.H.Ie();this.l=this.m=null;this.$=!1;this.J=[];this.jb=[];this.Za=!1;this.R=new Ub(function(){f.j.style.cursor="none";f.Za=!1;bF(f)});this.ea=new Ub(function(){f.h.removeAttribute("shown");f.L.V(2)});this.L=new Ub(function(){for(var g=t(f.J),h=g.next();!h.done;h=
1518
+ g.next())XD(h.value,!1)});this.xa=new Ub(function(){f.mc()&&cF(f)});this.I=null;this.G=[];this.qa=dF();this.i=new od;this.u=null;this.configure(this.g);eF(this);this.ha=new Set;fF(this);this.xa.za(this.g.refreshTickInSeconds);this.i.s(this.qa,"locale-changed",function(g){f.Ba.setLocale(g.locales[0])})}na(Z,gb);q=Z.prototype;
1519
+ q.destroy=function(){var a=this;return O(function(b){switch(b.g){case 1:if(document.pictureInPictureElement!=a.o){b.B(2);break}return E(b,document.exitPictureInPicture(),2);case 2:a.i&&(a.i.release(),a.i=null);a.R&&(a.R.stop(),a.R=null);a.ea&&(a.ea.stop(),a.ea=null);a.L&&(a.L.stop(),a.L=null);a.xa&&(a.xa.stop(),a.xa=null);a.u&&(a.u.release(),a.u=null);gF(a);a.h&&(a.j.removeChild(a.h),a.h=null);if(!a.F){b.B(4);break}return E(b,a.F.destroy(),5);case 5:a.F=null;case 4:if(!a.ma){b.B(6);break}return E(b,
1520
+ a.ma.destroy(),7);case 7:a.ma=null;case 6:a.H=null,a.o=null,a.A=null,a.qa=null,a.ha.clear(),gb.prototype.release.call(a),F(b)}})};function gF(a){for(var b=t(a.G),c=b.next();!c.done;c=b.next())c.value.release();a.G=[]}function hF(a,b){iF.set(a,b)}q.Hi=function(a){this.na=a;fF(this)};q.Nj=function(){bF(this)};
1521
+ q.configure=function(a){this.g=a;this.F.wh(a.castReceiverAppId,a.castAndroidReceiverCompatible);this.l&&(this.l=null);this.Na&&(this.Na=null);this.Ha&&(this.Ha=null);this.u&&this.u.configure(a);this.h?(fn(this.h),gF(this)):(jF(this),kF(this),this.u=new UE(this.h,this.Hc,this.o,this.H,this.g));this.j.classList.add("shaka-video-container");this.o.classList.add("shaka-video");lF(this);this.g.addBigPlayButton&&mF(this);this.g.customContextMenu&&(this.Ha=new fE(this.X,this),this.G.push(this.Ha));this.ba||
1522
+ nF(this);this.g.seekOnTaps&&(oF(this),pF(this));this.Ea=W("div");this.Ea.classList.add("shaka-server-side-ad-container");this.h.appendChild(this.Ea);qF(this);this.J=Array.from(this.j.getElementsByClassName("shaka-settings-menu"));this.J.push.apply(this.J,x(Array.from(this.j.getElementsByClassName("shaka-overflow-menu"))));rF(this);this.jb=Array.from(this.j.getElementsByClassName("shaka-show-controls-on-mouse-over"));bF(this);a=t(this.j.getElementsByClassName("shaka-no-propagation"));for(var b=a.next();!b.done;b=
1523
+ a.next()){b=b.value;var c=function(d){return d.stopPropagation()};this.i.s(b,"click",c);this.i.s(b,"dblclick",c)}};q.Yg=function(a){(this.S=a)?(this.j.setAttribute("shaka-controls","true"),this.o.tabIndex=-1,this.o.controls=!1):this.j.removeAttribute("shaka-controls");bF(this)};q.di=function(a){this.o.controls=a;this.o.tabIndex=a?0:-1;a&&this.Yg(!1)};q.getAd=function(){return this.m};q.Ti=function(){return this.F};q.gj=function(){return this.qa};q.yj=function(){return this.j};q.lc=function(){return this.A};
1524
+ q.fj=function(){return this.o};q.bd=function(){return this.H};q.ej=function(){return this.ma};q.Yi=function(){return this.h};q.pj=function(){return this.Ea};q.Vi=function(){return this.O};q.Wi=function(){return this.g};q.Kj=function(){return this.$};q.bh=function(a){this.$=a};q.Ej=function(){return this.na};q.qg=function(){return this.l?this.l.getValue():this.A.currentTime};q.gi=function(a){this.I=a};q.Jd=function(){return this.J.some(function(a){return!a.classList.contains("shaka-hidden")})};
1525
+ q.Cc=function(){this.L.Pa()};q.Xd=function(){return document.fullscreenEnabled||this.o.webkitSupportsFullscreen?!0:!1};q.fd=function(){if(document.fullscreenEnabled)return!!document.fullscreenElement;var a=this.o;return a.webkitSupportsFullscreen?a.webkitDisplayingFullscreen:!1};
1526
+ function sF(a){var b,c,d;return O(function(e){switch(e.g){case 1:ta(e,2);if(!document.fullscreenEnabled){b=a.o;b.webkitSupportsFullscreen&&b.webkitEnterFullscreen();e.B(4);break}if(!document.pictureInPictureElement){e.B(5);break}return E(e,document.exitPictureInPicture(),5);case 5:return c=a.g.fullScreenElement,E(e,c.requestFullscreen({navigationUI:"hide"}),7);case 7:if(!a.g.forceLandscapeOnFullscreen||!screen.orientation){e.B(4);break}ta(e,9);return E(e,screen.orientation.lock("landscape"),11);case 11:va(e,
1527
+ 4,2);break;case 9:wa(e,2);case 4:va(e,0);break;case 2:d=wa(e),a.dispatchEvent(new S("error",(new Map).set("detail",d))),F(e)}})}function tF(a){var b;return O(function(c){if(!document.fullscreenEnabled)return b=a.o,b.webkitSupportsFullscreen&&b.webkitExitFullscreen(),c.B(0);screen.orientation&&screen.orientation.unlock();return E(c,document.exitFullscreen(),0)})}q.qf=function(){var a=this;return O(function(b){return a.fd()?E(b,tF(a),0):E(b,sF(a),0)})};
1527
1528
  q.Re=function(){return this.F.Oa()?!1:"documentPictureInPicture"in window&&this.g.preferDocumentPictureInPicture||document.pictureInPictureEnabled?!this.o.disablePictureInPicture:!1};q.Se=function(){return"documentPictureInPicture"in window&&this.g.preferDocumentPictureInPicture?!!window.documentPictureInPicture.window:!!document.pictureInPictureElement};
1528
- q.me=function(){var a=this,b,c;return O(function(d){if(1==d.g)return ta(d,2),"documentPictureInPicture"in window&&a.g.preferDocumentPictureInPicture?E(d,tF(a),5):document.pictureInPictureElement?E(d,document.exitPictureInPicture(),5):(document.fullscreenElement&&document.exitFullscreen(),b=a.o,E(d,b.requestPictureInPicture(),5));if(2!=d.g)return va(d,0);c=wa(d);a.dispatchEvent(new S("error",(new Map).set("detail",c)));F(d)})};
1529
- function tF(a){var b,c,d,e,f,g;return O(function(h){if(1==h.g){if(window.documentPictureInPicture.window)return window.documentPictureInPicture.window.close(),h.return();b=a.j;c=b.getBoundingClientRect();return E(h,window.documentPictureInPicture.requestWindow({width:c.width,height:c.height}),2)}d=h.h;uF(d);e=b.parentNode||document.body;f=a.j.cloneNode(!0);f.style.visibility="hidden";f.style.height=getComputedStyle(b).height;e.appendChild(f);g=document.createElement("style");g.append("[data-shaka-player-container] {\n width: 100% !important; max-height: 100%}");
1529
+ q.me=function(){var a=this,b,c;return O(function(d){if(1==d.g)return ta(d,2),"documentPictureInPicture"in window&&a.g.preferDocumentPictureInPicture?E(d,uF(a),5):document.pictureInPictureElement?E(d,document.exitPictureInPicture(),5):(document.fullscreenElement&&document.exitFullscreen(),b=a.o,E(d,b.requestPictureInPicture(),5));if(2!=d.g)return va(d,0);c=wa(d);a.dispatchEvent(new S("error",(new Map).set("detail",c)));F(d)})};
1530
+ function uF(a){var b,c,d,e,f,g;return O(function(h){if(1==h.g){if(window.documentPictureInPicture.window)return window.documentPictureInPicture.window.close(),h.return();b=a.j;c=b.getBoundingClientRect();return E(h,window.documentPictureInPicture.requestWindow({width:c.width,height:c.height}),2)}d=h.h;vF(d);e=b.parentNode||document.body;f=a.j.cloneNode(!0);f.style.visibility="hidden";f.style.height=getComputedStyle(b).height;e.appendChild(f);g=document.createElement("style");g.append("[data-shaka-player-container] {\n width: 100% !important; max-height: 100%}");
1530
1531
  d.document.head.append(g);d.document.body.append(b);a.i.oa(d,"pagehide",function(){f.replaceWith(b)});F(h)})}
1531
- function uF(a){var b=[].concat(x(document.styleSheets)).map(function(d){try{return[].concat(x(d.cssRules)).map(function(f){return f.cssText}).join("")}catch(f){var e=document.createElement("link");e.rel="stylesheet";e.type=d.type;e.media=d.media;e.href=d.href;a.document.head.appendChild(e)}return""}).filter(Boolean).join("\n"),c=document.createElement("style");c.textContent=b;a.document.head.appendChild(c)}q.mi=function(){WD(this.K,!0);WD(this.O,!0);this.h.setAttribute("ad-active","true")};
1532
- q.Kh=function(){WD(this.K,!1);WD(this.O,!1);this.h.removeAttribute("ad-active")};function cE(a){a.S&&a.A.duration&&(a.H.Uc(),a.A.paused&&!a.$?a.A.play():a.A.pause())}function bE(a){a.m&&a.m.isPaused()?a.m.play():a.m&&a.m.pause()}
1533
- function iF(a){a.h=W("div");a.h.classList.add("shaka-controls-container");a.j.appendChild(a.h);a.j.setAttribute("shaka-controls","true");a.i.s(a.h,"touchstart",function(b){a.A.duration&&(a.lc()?a.I=Date.now():(vF(a,b),b.cancelable&&b.preventDefault()))},{passive:!1});a.i.s(a.h,"click",function(){wF(a)});a.i.s(a.h,"dblclick",function(){a.g.doubleClickForFullscreen&&a.Xd()&&a.qf()})}
1534
- function lF(a){var b=W("div");b.classList.add("shaka-play-button-container");a.h.appendChild(b);a.Na=new dE(b,a);a.G.push(a.Na)}function kF(a){var b=W("div");b.classList.add("shaka-scrim-container");a.h.appendChild(b)}function xF(a){a.K=W("div");a.K.classList.add("shaka-ad-controls");var b=null!=a.m&&a.m.isLinear();WD(a.K,b);a.N.appendChild(a.K);b=new ZD(a.K,a);a.G.push(b);b=new YD(a.K,a);a.G.push(b);b=new xE(a.K,a);a.G.push(b)}
1535
- function mF(a){a.ba=W("div");a.ba.classList.add("shaka-spinner-container");a.j.appendChild(a.ba);var b=W("div");b.classList.add("shaka-spinner");a.ba.appendChild(b);a=document.createElementNS("http://www.w3.org/2000/svg","svg");a.classList.add("shaka-spinner-svg");a.setAttribute("viewBox","0 0 30 30");b.appendChild(a);b=document.createElementNS("http://www.w3.org/2000/svg","circle");b.classList.add("shaka-spinner-path");b.setAttribute("cx","15");b.setAttribute("cy","15");b.setAttribute("r","14.5");
1536
- b.setAttribute("fill","none");b.setAttribute("stroke-width","1");b.setAttribute("stroke-miterlimit","10");a.appendChild(b)}function nF(a){var b=W("div");b.classList.add("shaka-hidden-fast-forward-container");a.h.appendChild(b);a.Ac=new jE(b,a);a.G.push(a.Ac)}function oF(a){var b=W("div");b.classList.add("shaka-hidden-rewind-container");a.h.appendChild(b);a.Cc=new kE(b,a);a.G.push(a.Cc)}
1537
- function pF(a){a.N=W("div");a.N.classList.add("shaka-bottom-controls");a.N.classList.add("shaka-no-propagation");a.h.appendChild(a.N);a.i.s(a.N,"click",function(d){d.target.closest(".shaka-overflow-button")||a.Bc()});xF(a);a.Z=W("div");a.Z.classList.add("shaka-controls-button-panel");a.Z.classList.add("shaka-show-controls-on-mouse-over");a.g.enableTooltips&&a.Z.classList.add("shaka-tooltips-on");a.N.appendChild(a.Z);for(var b=t(a.g.controlPanelElements),c=b.next();!c.done;c=b.next())c=c.value,hF.get(c)?
1538
- (c=hF.get(c).create(a.Z,a),a.G.push(c)):Ya("Unrecognized control panel element requested:",c)}function qF(a){if(a.g.addSeekBar)a.l=yF.create(a.N,a),a.G.push(a.l);else{a=t(a.J);for(var b=a.next();!b.done;b=a.next())b.value.classList.add("shaka-low-position")}}function jF(a){a.O=W("div");a.O.classList.add("shaka-client-side-ad-container");WD(a.O,!1);a.i.s(a.O,"click",function(){wF(a)});a.j.appendChild(a.O)}
1539
- function dF(a){a.i.s(a.H,"buffering",function(){a.S&&WD(a.ba,a.H.Wd())});a.S&&WD(a.ba,a.H.Wd());a.i.s(window,"keydown",function(b){zF(a,b)});a.i.s(window,"click",function(){return a.Bc()});a.i.s(a,"submenuopen",function(){a.Bc()});a.i.s(a.A,"play",function(){aF(a)});a.i.s(a.A,"pause",function(){aF(a)});a.i.s(a.j,"mousemove",function(b){vF(a,b)});a.i.s(a.j,"touchmove",function(b){vF(a,b)},{passive:!0});a.i.s(a.j,"touchend",function(b){vF(a,b)},{passive:!0});a.i.s(a.j,"mouseleave",function(){a.I||a.R.Pa()});
1540
- a.i.s(a.F,"caststatuschanged",function(){eF(a)});a.i.s(a.u,"vrstatuschanged",function(){a.dispatchEvent(new S("vrstatuschanged"))});a.i.s(a.j,"keydown",function(b){var c=document.activeElement,d=c&&c.classList?c.classList.contains("shaka-volume-bar"):!1,e=c&&c.classList&&c.classList.contains("shaka-seek-bar");a.h.contains(c)&&vF(a,b);if(a.g.enableKeyboardPlaybackControls){c=a.g.keyboardSeekDistance;var f=a.g.keyboardLargeSeekDistance;switch(b.key){case "ArrowLeft":a.l&&e&&!d&&0<c&&(b.preventDefault(),
1541
- AF(a,a.l.getValue()-c));break;case "ArrowRight":a.l&&e&&!d&&0<c&&(b.preventDefault(),AF(a,a.l.getValue()+c));break;case "PageDown":a.l&&e&&0<c&&(b.preventDefault(),AF(a,a.l.getValue()-f));break;case "PageUp":a.l&&e&&0<c&&(b.preventDefault(),AF(a,a.l.getValue()+f));break;case "Home":a.l&&AF(a,a.H.Ta().start);break;case "End":a.l&&AF(a,a.H.Ta().end);break;case "f":a.Xd()&&a.qf();break;case "m":a.m&&a.m.isLinear()?a.m.setMuted(!a.m.isMuted()):a.o.muted=!a.o.muted;break;case "p":a.Re()&&a.me();break;
1542
- case " ":e&&BF(a)}}});a.i.s(a.j,"keyup",function(b){a.ha.delete(b.key)});a.i.s(a.Ba,"ad-started",function(b){a.m=b.ad;a.mi()});a.i.s(a.Ba,"ad-stopped",function(){a.m=null;a.Kh()});screen.orientation&&a.i.s(screen.orientation,"change",function(){return O(function(b){return E(b,CF(a),0)})})}
1543
- function CF(a){return O(function(b){return a.A&&0!=a.A.readyState&&!a.F.Oa()&&a.g.enableFullscreenOnRotation&&a.Xd()?screen.orientation.type.includes("landscape")&&!a.ed()?E(b,rF(a),0):screen.orientation.type.includes("portrait")&&a.ed()?E(b,sF(a),0):b.B(0):b.return()})}
1544
- function vF(a,b){"mousemove"==b.type&&(a.h.classList.remove("shaka-keyboard-navigation"),aF(a));"touchstart"==b.type||"touchmove"==b.type||"touchend"==b.type||"keyup"==b.type?a.I=Date.now():a.I+1E3<Date.now()&&(a.I=null);a.I&&"mousemove"==b.type||(a.j.style.cursor="",a.Za=!0,a.L.stop(),a.lc()||(bF(a),aF(a)),a.R.stop(),"touchend"!=b.type&&"keyup"!=b.type&&a.I||a.R.V(3))}function DF(a){return window.matchMedia("hover: hover").matches?a.jb.some(function(b){return b.matches(":hover")}):!1}
1545
- function aF(a){var b=a.m?a.m.isPaused():!1,c=a.A.paused&&!a.$,d=a.h.classList.contains("shaka-keyboard-navigation");b||(!a.m||!a.m.isLinear())&&c||a.Za||d||DF(a)?(bF(a),a.h.setAttribute("shown","true"),a.ea.stop()):a.ea.V(a.g.fadeDelay)}function wF(a){a.S&&!a.Qb()&&(a.Jd()?a.L.Pa():a.g.singleClickForPlayAndPause&&BF(a))}function BF(a){a.m&&a.m.isLinear()?bE(a):cE(a)}
1546
- function eF(a){var b=a.F.Oa();a.dispatchEvent(new S("caststatuschanged",(new Map).set("newStatus",b)));b?a.h.setAttribute("casting","true"):a.h.removeAttribute("casting")}q.lc=function(){return this.S?null!=this.h.getAttribute("shown")||null!=this.h.getAttribute("casting"):!1};function AF(a,b){a.l.changeTo(b);a.lc()&&bF(a)}
1547
- function bF(a){if(a.l)if(a.l.setValue(a.A.currentTime),a.l.update(),a.l.isShowing())for(var b=t(a.J),c=b.next();!c.done;c=b.next())c.value.classList.remove("shaka-low-position");else for(b=t(a.J),c=b.next();!c.done;c=b.next())c.value.classList.add("shaka-low-position");a.dispatchEvent(new S("timeandseekrangeupdated"))}
1548
- function zF(a,b){a.ha.add(b.key);var c=a.Jd();"Tab"==b.key&&(a.h.classList.add("shaka-keyboard-navigation"),aF(a),a.i.s(window,"mousedown",function(){a.i.Xa(window,"mousedown")}));"Escape"==b.key&&a.L.Pa();c&&a.ha.has("Tab")&&EF(a,b)}
1549
- function EF(a,b){var c=a.J.filter(function(f){return!f.classList.contains("shaka-hidden")});if(c.length){var d=c[0];if(d.childNodes.length){for(c=d.firstElementChild;c&&c.classList.contains("shaka-hidden");)c=c.nextElementSibling;for(d=d.lastElementChild;d&&d.classList.contains("shaka-hidden");)d=d.previousElementSibling;var e=document.activeElement;a.ha.has("Shift")?e==c&&(b.preventDefault(),d.focus()):e==d&&(b.preventDefault(),c.focus())}}}
1550
- q.Bk=function(){var a=new Event("mousemove",{bubbles:!1,cancelable:!1});vF(this,a)};q.Dj=function(){this.I||this.R.Pa()};q.Vf=function(){return this.u.Vf()};q.Qb=function(){return this.u.Qb()};
1551
- q.wj=function(){var a=this.u;if(a.g){a=a.g;DE(a.h,a.G);var b=a.h;a=b[0];var c=b[1],d=b[2];b=b[3];var e=d*d,f=b*b;var g=a*a+c*c+e+f;var h=a*b-c*d;h>.499995*g?(g=Math.PI/2,a=2*Math.atan2(c,a)):h<-.499995*g?(g=-Math.PI/2,a=2*Math.atan2(c,a)):(g=Math.asin(2*(a*d-b*c)),a=Math.atan2(2*(a*b+c*d),1-2*(e+f)));a=180*Math.acos(Math.cos(a)*Math.cos(g))/Math.PI}else Ya("Not playing VR content"),a=null;return a};q.vj=function(){var a=this.u;a.g?a=a.g.i:(Ya("Not playing VR content"),a=null);return a};
1552
- q.Ak=function(a){var b=this.u;b.g?(0>a?(Ya("Field of view should be greater than 0"),a=0):100<a&&(Ya("Field of view should be less than 100"),a=100),b=b.g,b.i=a,JE(b,!1)):Ya("Not playing VR content")};q.qd=function(){this.u.qd()};q.zg=function(a){this.u.zg(a)};q.xg=function(a){this.u.xg(a)};q.yg=function(a){this.u.yg(a)};
1553
- function cF(){var a=new hd("en");a.Ka("ar",new Map([["AD_DURATION","\u0645\u062f\u0629 \u0627\u0644\u0625\u0639\u0644\u0627\u0646"],["AD_PROGRESS","\u0627\u0644\u0625\u0639\u0644\u0627\u0646 [AD_ON] \u0645\u0646 [NUM_ADS]"],["AD_TIME","\u0627\u0644\u0625\u0639\u0644\u0627\u0646: [AD_TIME]"],["AUTO_QUALITY","\u062a\u0644\u0642\u0627\u0626\u064a"],["BACK","\u0631\u062c\u0648\u0639"],["CAPTIONS","\u0627\u0644\u062a\u0631\u062c\u0645\u0629 \u0648\u0627\u0644\u0634\u0631\u062d"],["CAST","\u0625\u0631\u0633\u0627\u0644..."],
1532
+ function vF(a){var b=[].concat(x(document.styleSheets)).map(function(d){try{return[].concat(x(d.cssRules)).map(function(f){return f.cssText}).join("")}catch(f){var e=document.createElement("link");e.rel="stylesheet";e.type=d.type;e.media=d.media;e.href=d.href;a.document.head.appendChild(e)}return""}).filter(Boolean).join("\n"),c=document.createElement("style");c.textContent=b;a.document.head.appendChild(c)}q.mi=function(){XD(this.K,!0);XD(this.O,!0);this.h.setAttribute("ad-active","true")};
1533
+ q.Kh=function(){XD(this.K,!1);XD(this.O,!1);this.h.removeAttribute("ad-active")};function dE(a){a.S&&a.A.duration&&(a.H.Vc(),a.A.paused&&!a.$?a.A.play():a.A.pause())}function cE(a){a.m&&a.m.isPaused()?a.m.play():a.m&&a.m.pause()}
1534
+ function jF(a){a.h=W("div");a.h.classList.add("shaka-controls-container");a.j.appendChild(a.h);a.j.setAttribute("shaka-controls","true");a.i.s(a.h,"touchstart",function(b){a.A.duration&&(a.mc()?a.I=Date.now():(wF(a,b),b.cancelable&&b.preventDefault()))},{passive:!1});a.i.s(a.h,"click",function(){xF(a)});a.i.s(a.h,"dblclick",function(){a.g.doubleClickForFullscreen&&a.Xd()&&a.qf()})}
1535
+ function mF(a){var b=W("div");b.classList.add("shaka-play-button-container");a.h.appendChild(b);a.Na=new eE(b,a);a.G.push(a.Na)}function lF(a){var b=W("div");b.classList.add("shaka-scrim-container");a.h.appendChild(b)}function yF(a){a.K=W("div");a.K.classList.add("shaka-ad-controls");var b=null!=a.m&&a.m.isLinear();XD(a.K,b);a.N.appendChild(a.K);b=new $D(a.K,a);a.G.push(b);b=new ZD(a.K,a);a.G.push(b);b=new yE(a.K,a);a.G.push(b)}
1536
+ function nF(a){a.ba=W("div");a.ba.classList.add("shaka-spinner-container");a.j.appendChild(a.ba);var b=W("div");b.classList.add("shaka-spinner");a.ba.appendChild(b);a=document.createElementNS("http://www.w3.org/2000/svg","svg");a.classList.add("shaka-spinner-svg");a.setAttribute("viewBox","0 0 30 30");b.appendChild(a);b=document.createElementNS("http://www.w3.org/2000/svg","circle");b.classList.add("shaka-spinner-path");b.setAttribute("cx","15");b.setAttribute("cy","15");b.setAttribute("r","14.5");
1537
+ b.setAttribute("fill","none");b.setAttribute("stroke-width","1");b.setAttribute("stroke-miterlimit","10");a.appendChild(b)}function oF(a){var b=W("div");b.classList.add("shaka-hidden-fast-forward-container");a.h.appendChild(b);a.Bc=new kE(b,a);a.G.push(a.Bc)}function pF(a){var b=W("div");b.classList.add("shaka-hidden-rewind-container");a.h.appendChild(b);a.Dc=new lE(b,a);a.G.push(a.Dc)}
1538
+ function qF(a){a.N=W("div");a.N.classList.add("shaka-bottom-controls");a.N.classList.add("shaka-no-propagation");a.h.appendChild(a.N);a.i.s(a.N,"click",function(d){d.target.closest(".shaka-overflow-button")||a.Cc()});yF(a);a.X=W("div");a.X.classList.add("shaka-controls-button-panel");a.X.classList.add("shaka-show-controls-on-mouse-over");a.g.enableTooltips&&a.X.classList.add("shaka-tooltips-on");a.N.appendChild(a.X);for(var b=t(a.g.controlPanelElements),c=b.next();!c.done;c=b.next())c=c.value,iF.get(c)?
1539
+ (c=iF.get(c).create(a.X,a),a.G.push(c)):Ya("Unrecognized control panel element requested:",c)}function rF(a){if(a.g.addSeekBar)a.l=zF.create(a.N,a),a.G.push(a.l);else{a=t(a.J);for(var b=a.next();!b.done;b=a.next())b.value.classList.add("shaka-low-position")}}function kF(a){a.O=W("div");a.O.classList.add("shaka-client-side-ad-container");XD(a.O,!1);a.i.s(a.O,"click",function(){xF(a)});a.j.appendChild(a.O)}
1540
+ function eF(a){a.i.s(a.H,"buffering",function(){a.S&&XD(a.ba,a.H.Wd())});a.S&&XD(a.ba,a.H.Wd());a.i.s(window,"keydown",function(b){AF(a,b)});a.i.s(window,"click",function(){return a.Cc()});a.i.s(a,"submenuopen",function(){a.Cc()});a.i.s(a.A,"play",function(){bF(a)});a.i.s(a.A,"pause",function(){bF(a)});a.i.s(a.j,"mousemove",function(b){wF(a,b)});a.i.s(a.j,"touchmove",function(b){wF(a,b)},{passive:!0});a.i.s(a.j,"touchend",function(b){wF(a,b)},{passive:!0});a.i.s(a.j,"mouseleave",function(){a.I||a.R.Pa()});
1541
+ a.i.s(a.F,"caststatuschanged",function(){fF(a)});a.i.s(a.u,"vrstatuschanged",function(){a.dispatchEvent(new S("vrstatuschanged"))});a.i.s(a.j,"keydown",function(b){var c=document.activeElement,d=c&&c.classList?c.classList.contains("shaka-volume-bar"):!1,e=c&&c.classList&&c.classList.contains("shaka-seek-bar");a.h.contains(c)&&wF(a,b);if(a.g.enableKeyboardPlaybackControls){c=a.g.keyboardSeekDistance;var f=a.g.keyboardLargeSeekDistance;switch(b.key){case "ArrowLeft":a.l&&e&&!d&&0<c&&(b.preventDefault(),
1542
+ BF(a,a.l.getValue()-c));break;case "ArrowRight":a.l&&e&&!d&&0<c&&(b.preventDefault(),BF(a,a.l.getValue()+c));break;case "PageDown":a.l&&e&&0<c&&(b.preventDefault(),BF(a,a.l.getValue()-f));break;case "PageUp":a.l&&e&&0<c&&(b.preventDefault(),BF(a,a.l.getValue()+f));break;case "Home":a.l&&BF(a,a.H.Ta().start);break;case "End":a.l&&BF(a,a.H.Ta().end);break;case "f":a.Xd()&&a.qf();break;case "m":a.m&&a.m.isLinear()?a.m.setMuted(!a.m.isMuted()):a.o.muted=!a.o.muted;break;case "p":a.Re()&&a.me();break;
1543
+ case " ":e&&CF(a)}}});a.i.s(a.j,"keyup",function(b){a.ha.delete(b.key)});a.i.s(a.Ba,"ad-started",function(b){a.m=b.ad;a.mi()});a.i.s(a.Ba,"ad-stopped",function(){a.m=null;a.Kh()});screen.orientation&&a.i.s(screen.orientation,"change",function(){return O(function(b){return E(b,DF(a),0)})})}
1544
+ function DF(a){return O(function(b){return a.A&&0!=a.A.readyState&&!a.F.Oa()&&a.g.enableFullscreenOnRotation&&a.Xd()?screen.orientation.type.includes("landscape")&&!a.fd()?E(b,sF(a),0):screen.orientation.type.includes("portrait")&&a.fd()?E(b,tF(a),0):b.B(0):b.return()})}
1545
+ function wF(a,b){"mousemove"==b.type&&(a.h.classList.remove("shaka-keyboard-navigation"),bF(a));"touchstart"==b.type||"touchmove"==b.type||"touchend"==b.type||"keyup"==b.type?a.I=Date.now():a.I+1E3<Date.now()&&(a.I=null);a.I&&"mousemove"==b.type||(a.j.style.cursor="",a.Za=!0,a.L.stop(),a.mc()||(cF(a),bF(a)),a.R.stop(),"touchend"!=b.type&&"keyup"!=b.type&&a.I||a.R.V(3))}function EF(a){return window.matchMedia("hover: hover").matches?a.jb.some(function(b){return b.matches(":hover")}):!1}
1546
+ function bF(a){var b=a.m?a.m.isPaused():!1,c=a.A.paused&&!a.$,d=a.h.classList.contains("shaka-keyboard-navigation");b||(!a.m||!a.m.isLinear())&&c||a.Za||d||EF(a)?(cF(a),a.h.setAttribute("shown","true"),a.ea.stop()):a.ea.V(a.g.fadeDelay)}function xF(a){a.S&&!a.Qb()&&(a.Jd()?a.L.Pa():a.g.singleClickForPlayAndPause&&CF(a))}function CF(a){a.m&&a.m.isLinear()?cE(a):dE(a)}
1547
+ function fF(a){var b=a.F.Oa();a.dispatchEvent(new S("caststatuschanged",(new Map).set("newStatus",b)));b?a.h.setAttribute("casting","true"):a.h.removeAttribute("casting")}q.mc=function(){return this.S?null!=this.h.getAttribute("shown")||null!=this.h.getAttribute("casting"):!1};function BF(a,b){a.l.changeTo(b);a.mc()&&cF(a)}
1548
+ function cF(a){if(a.l)if(a.l.setValue(a.A.currentTime),a.l.update(),a.l.isShowing())for(var b=t(a.J),c=b.next();!c.done;c=b.next())c.value.classList.remove("shaka-low-position");else for(b=t(a.J),c=b.next();!c.done;c=b.next())c.value.classList.add("shaka-low-position");a.dispatchEvent(new S("timeandseekrangeupdated"))}
1549
+ function AF(a,b){a.ha.add(b.key);var c=a.Jd();"Tab"==b.key&&(a.h.classList.add("shaka-keyboard-navigation"),bF(a),a.i.s(window,"mousedown",function(){a.i.Xa(window,"mousedown")}));"Escape"==b.key&&a.L.Pa();c&&a.ha.has("Tab")&&FF(a,b)}
1550
+ function FF(a,b){var c=a.J.filter(function(f){return!f.classList.contains("shaka-hidden")});if(c.length){var d=c[0];if(d.childNodes.length){for(c=d.firstElementChild;c&&c.classList.contains("shaka-hidden");)c=c.nextElementSibling;for(d=d.lastElementChild;d&&d.classList.contains("shaka-hidden");)d=d.previousElementSibling;var e=document.activeElement;a.ha.has("Shift")?e==c&&(b.preventDefault(),d.focus()):e==d&&(b.preventDefault(),c.focus())}}}
1551
+ q.Bk=function(){var a=new Event("mousemove",{bubbles:!1,cancelable:!1});wF(this,a)};q.Dj=function(){this.I||this.R.Pa()};q.Vf=function(){return this.u.Vf()};q.Qb=function(){return this.u.Qb()};
1552
+ q.wj=function(){var a=this.u;if(a.g){a=a.g;EE(a.h,a.G);var b=a.h;a=b[0];var c=b[1],d=b[2];b=b[3];var e=d*d,f=b*b;var g=a*a+c*c+e+f;var h=a*b-c*d;h>.499995*g?(g=Math.PI/2,a=2*Math.atan2(c,a)):h<-.499995*g?(g=-Math.PI/2,a=2*Math.atan2(c,a)):(g=Math.asin(2*(a*d-b*c)),a=Math.atan2(2*(a*b+c*d),1-2*(e+f)));a=180*Math.acos(Math.cos(a)*Math.cos(g))/Math.PI}else Ya("Not playing VR content"),a=null;return a};q.vj=function(){var a=this.u;a.g?a=a.g.i:(Ya("Not playing VR content"),a=null);return a};
1553
+ q.Ak=function(a){var b=this.u;b.g?(0>a?(Ya("Field of view should be greater than 0"),a=0):100<a&&(Ya("Field of view should be less than 100"),a=100),b=b.g,b.i=a,KE(b,!1)):Ya("Not playing VR content")};q.qd=function(){this.u.qd()};q.zg=function(a){this.u.zg(a)};q.xg=function(a){this.u.xg(a)};q.yg=function(a){this.u.yg(a)};
1554
+ function dF(){var a=new hd("en");a.Ka("ar",new Map([["AD_DURATION","\u0645\u062f\u0629 \u0627\u0644\u0625\u0639\u0644\u0627\u0646"],["AD_PROGRESS","\u0627\u0644\u0625\u0639\u0644\u0627\u0646 [AD_ON] \u0645\u0646 [NUM_ADS]"],["AD_TIME","\u0627\u0644\u0625\u0639\u0644\u0627\u0646: [AD_TIME]"],["AUTO_QUALITY","\u062a\u0644\u0642\u0627\u0626\u064a"],["BACK","\u0631\u062c\u0648\u0639"],["CAPTIONS","\u0627\u0644\u062a\u0631\u062c\u0645\u0629 \u0648\u0627\u0644\u0634\u0631\u062d"],["CAST","\u0625\u0631\u0633\u0627\u0644..."],
1554
1555
  ["ENTER_LOOP_MODE","\u062a\u0643\u0631\u0627\u0631 \u0627\u0644\u0641\u064a\u062f\u064a\u0648 \u0627\u0644\u062d\u0627\u0644\u064a"],["ENTER_PICTURE_IN_PICTURE",'\u0627\u0644\u062f\u062e\u0648\u0644 \u0641\u064a \u0648\u0636\u0639 "\u0646\u0627\u0641\u0630\u0629 \u0636\u0645\u0646 \u0646\u0627\u0641\u0630\u0629"'],["EXIT_FULL_SCREEN","\u0625\u0646\u0647\u0627\u0621 \u0648\u0636\u0639 \u0645\u0644\u0621 \u0627\u0644\u0634\u0627\u0634\u0629"],["EXIT_LOOP_MODE","\u0625\u064a\u0642\u0627\u0641 \u062a\u0643\u0631\u0627\u0631 \u0627\u0644\u0641\u064a\u062f\u064a\u0648 \u0627\u0644\u062d\u0627\u0644\u064a"],
1555
1556
  ["EXIT_PICTURE_IN_PICTURE",'\u0627\u0644\u062e\u0631\u0648\u062c \u0645\u0646 \u0648\u0636\u0639 "\u0646\u0627\u0641\u0630\u0629 \u0636\u0645\u0646 \u0646\u0627\u0641\u0630\u0629"'],["FAST_FORWARD","\u062a\u0642\u062f\u064a\u0645 \u0633\u0631\u064a\u0639"],["FULL_SCREEN","\u0645\u0644\u0621 \u0627\u0644\u0634\u0627\u0634\u0629"],["LANGUAGE","\u0627\u0644\u0644\u063a\u0629"],["LIVE","\u0645\u0628\u0627\u0634\u0631"],["LOOP","\u062a\u0643\u0631\u0627\u0631"],["MORE_SETTINGS","\u0645\u0632\u064a\u062f \u0645\u0646 \u0627\u0644\u0625\u0639\u062f\u0627\u062f\u0627\u062a"],
1556
1557
  ["MULTIPLE_LANGUAGES","\u0644\u063a\u0627\u062a \u0645\u062a\u0639\u062f\u062f\u0629"],["MUTE","\u0643\u062a\u0645 \u0627\u0644\u0635\u0648\u062a"],["NOT_APPLICABLE","\u063a\u064a\u0631 \u0633\u0627\u0631\u064d"],["OFF","\u0625\u064a\u0642\u0627\u0641"],["ON","\u062a\u0634\u063a\u064a\u0644"],["PAUSE","\u0625\u064a\u0642\u0627\u0641 \u0645\u0624\u0642\u062a"],["PICTURE_IN_PICTURE","\u0646\u0627\u0641\u0630\u0629 \u0636\u0645\u0646 \u0627\u0644\u0646\u0627\u0641\u0630\u0629"],["PLAY","\u0627\u0644\u062a\u0634\u063a\u064a\u0644"],
@@ -1611,91 +1612,91 @@ a.Ka("en",new Map([["AD_DURATION","Ad duration"],["AD_PROGRESS","Ad [AD_ON] of [
1611
1612
  ["AD_TIME","\u5ee3\u544a\uff1a[AD_TIME]"],["AUTO_QUALITY","\u81ea\u52d5"],["BACK","\u8fd4\u56de"],["CAPTIONS","\u5b57\u5e55"],["CAST","\u6295\u653e..."],["ENTER_LOOP_MODE","\u5faa\u74b0\u64ad\u653e\u76ee\u524d\u7684\u5f71\u7247"],["ENTER_PICTURE_IN_PICTURE","\u9032\u5165\u5b50\u6bcd\u756b\u9762"],["EXIT_FULL_SCREEN","\u9000\u51fa\u5168\u87a2\u5e55\u6a21\u5f0f"],["EXIT_LOOP_MODE","\u505c\u6b62\u5faa\u74b0\u64ad\u653e\u76ee\u524d\u7684\u5f71\u7247"],["EXIT_PICTURE_IN_PICTURE","\u96e2\u958b\u5b50\u6bcd\u756b\u9762"],
1612
1613
  ["FAST_FORWARD","\u5feb\u8f49"],["FULL_SCREEN","\u5168\u87a2\u5e55"],["LANGUAGE","\u8a9e\u8a00"],["LIVE","\u76f4\u64ad"],["LOOP","\u5faa\u74b0\u64ad\u653e"],["MORE_SETTINGS","\u986f\u793a\u66f4\u591a\u8a2d\u5b9a"],["MULTIPLE_LANGUAGES","\u591a\u7a2e\u8a9e\u8a00"],["MUTE","\u975c\u97f3"],["NOT_APPLICABLE","\u4e0d\u9069\u7528"],["OFF","\u95dc\u9589"],["ON","\u958b\u555f"],["PAUSE","\u66ab\u505c"],["PICTURE_IN_PICTURE","\u5b50\u6bcd\u756b\u9762"],["PLAY","\u64ad\u653e"],["PLAYBACK_RATE","\u64ad\u653e\u901f\u5ea6"],
1613
1614
  ["RESOLUTION","\u89e3\u6790\u5ea6"],["REWIND","\u5012\u8f49"],["SEEK","\u641c\u5c0b"],["SKIP_AD","\u7565\u904e\u5ee3\u544a"],["SKIP_TO_LIVE","\u8df3\u81f3\u5f53\u524d\u76f4\u64ad"],["UNDETERMINED_LANGUAGE","\u4e0d\u660e"],["UNMUTE","\u53d6\u6d88\u975c\u97f3"],["UNRECOGNIZED_LANGUAGE","\u7121\u6cd5\u8fa8\u8b58"],["VOLUME","\u97f3\u91cf"]]));a.vh(navigator.languages||[]);return a}P("shaka.ui.Controls",Z);Z.prototype.incrementRoll=Z.prototype.yg;Z.prototype.incrementPitch=Z.prototype.xg;
1614
- Z.prototype.incrementYaw=Z.prototype.zg;Z.prototype.toggleStereoscopicMode=Z.prototype.qd;Z.prototype.setVRFieldOfView=Z.prototype.Ak;Z.prototype.getVRFieldOfView=Z.prototype.vj;Z.prototype.getVRNorth=Z.prototype.wj;Z.prototype.isPlayingVR=Z.prototype.Qb;Z.prototype.canPlayVR=Z.prototype.Vf;Z.prototype.hideUI=Z.prototype.Dj;Z.prototype.showUI=Z.prototype.Bk;Z.prototype.isOpaque=Z.prototype.lc;Z.prototype.hideAdUI=Z.prototype.Kh;Z.prototype.showAdUI=Z.prototype.mi;Z.prototype.togglePiP=Z.prototype.me;
1615
- Z.prototype.isPiPEnabled=Z.prototype.Se;Z.prototype.isPiPAllowed=Z.prototype.Re;Z.prototype.toggleFullScreen=Z.prototype.qf;Z.prototype.isFullScreenEnabled=Z.prototype.ed;Z.prototype.isFullScreenSupported=Z.prototype.Xd;Z.prototype.hideSettingsMenus=Z.prototype.Bc;Z.prototype.anySettingsMenusAreOpen=Z.prototype.Jd;Z.prototype.setLastTouchEventTime=Z.prototype.gi;Z.prototype.getDisplayTime=Z.prototype.qg;Z.prototype.isCastAllowed=Z.prototype.Ej;Z.prototype.setSeeking=Z.prototype.bh;
1616
- Z.prototype.isSeeking=Z.prototype.Kj;Z.prototype.getConfig=Z.prototype.Wi;Z.prototype.getClientSideAdContainer=Z.prototype.Vi;Z.prototype.getServerSideAdContainer=Z.prototype.pj;Z.prototype.getControlsContainer=Z.prototype.Yi;Z.prototype.getLocalPlayer=Z.prototype.ej;Z.prototype.getPlayer=Z.prototype.$c;Z.prototype.getLocalVideo=Z.prototype.fj;Z.prototype.getVideo=Z.prototype.kc;Z.prototype.getVideoContainer=Z.prototype.yj;Z.prototype.getLocalization=Z.prototype.gj;Z.prototype.getCastProxy=Z.prototype.Ti;
1617
- Z.prototype.getAd=Z.prototype.getAd;Z.prototype.setEnabledNativeControls=Z.prototype.di;Z.prototype.setEnabledShakaControls=Z.prototype.Yg;Z.prototype.configure=Z.prototype.configure;Z.prototype.loadComplete=Z.prototype.Nj;Z.prototype.allowCast=Z.prototype.Hi;Z.registerSeekBar=function(a){yF=a};Z.registerElement=gF;Z.prototype.destroy=Z.prototype.destroy;var hF=new Map,yF=new wE;function FF(a,b){RD.call(this,a,b);var c=this;this.l=this.controls.g;this.j=this.controls.h;this.i=[];this.g=en();this.g.classList.add("shaka-overflow-menu-button");this.g.classList.add("shaka-no-propagation");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");this.g.textContent="more_vert";this.parent.appendChild(this.g);this.h=W("div");this.h.classList.add("shaka-overflow-menu");this.h.classList.add("shaka-no-propagation");this.h.classList.add("shaka-show-controls-on-mouse-over");
1618
- this.h.classList.add("shaka-hidden");this.j.appendChild(this.h);GF(this);this.eventManager.s(this.localization,"locale-updated",function(){HF(c)});this.eventManager.s(this.localization,"locale-changed",function(){HF(c)});this.eventManager.s(this.adManager,"ad-started",function(){c.ad&&c.ad.isLinear()&&WD(c.g,!1)});this.eventManager.s(this.adManager,"ad-stopped",function(){WD(c.g,!0)});this.eventManager.s(this.controls,"submenuopen",function(){WD(c.h,!1)});this.eventManager.s(this.h,"touchstart",function(d){c.controls.gi(Date.now());
1619
- d.stopPropagation()});this.eventManager.s(this.g,"click",function(){IF(c)});HF(this);this.ad&&this.ad.isLinear()&&WD(this.g,!1)}na(FF,RD);FF.prototype.release=function(){this.j=null;for(var a=t(this.i),b=a.next();!b.done;b=a.next())b.value.release();this.i=[];RD.prototype.release.call(this)};function JF(a,b){KF.set(a,b)}
1620
- function GF(a){for(var b=t(a.l.overflowMenuButtons),c=b.next();!c.done;c=b.next())c=c.value,KF.get(c)?(c=KF.get(c),a.i.push(c.create(a.h,a.controls))):Ya("Unrecognized overflow menu element requested:",c)}function IF(a){if(a.controls.Jd())a.controls.Bc();else{WD(a.h,!0);aF(a.controls);var b=function(c){return 0==c.classList.contains("shaka-hidden")};jb(a.h.childNodes,b)&&kb(a.h.childNodes,b)[0].focus()}}function HF(a){a.g.ariaLabel=a.localization.resolve("MORE_SETTINGS")}
1621
- P("shaka.ui.OverflowMenu",FF);FF.registerElement=JF;function LF(){}LF.prototype.create=function(a,b){return new FF(a,b)};gF("overflow_menu",new LF);var KF=new Map;function MF(a,b){RD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-airplay-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.h=W("i");this.h.classList.add("material-icons-round");this.h.textContent="airplay";this.g.appendChild(this.h);window.WebKitPlaybackTargetAvailabilityEvent||this.g.classList.add("shaka-hidden");a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=W("span");a.appendChild(this.j);
1622
- this.i=W("span");this.i.classList.add("shaka-current-selection-span");a.appendChild(this.i);this.g.appendChild(a);this.parent.appendChild(this.g);NF(this);OF(this);this.eventManager.s(this.localization,"locale-updated",function(){NF(c)});this.eventManager.s(this.localization,"locale-changed",function(){NF(c)});this.eventManager.s(this.g,"click",function(){c.controls.kc().webkitShowPlaybackTargetPicker()});a=this.controls.kc();this.eventManager.s(a,"webkitplaybacktargetavailabilitychanged",function(d){var e=
1623
- c.player.Qd()==fp;WD(c.g,"available"==d.availability&&e)});this.eventManager.s(a,"webkitcurrentplaybacktargetiswirelesschanged",function(){OF(c)})}na(MF,RD);function OF(a){var b=a.controls.kc();a.g.ariaPressed=b&&b.webkitCurrentPlaybackTargetIsWireless?"true":"false"}function NF(a){a.g.ariaLabel=a.localization.resolve("AIRPLAY");a.j.textContent=a.localization.resolve("AIRPLAY")}P("shaka.ui.AirPlayButton",MF);function PF(){}PF.prototype.create=function(a,b){return new MF(a,b)};JF("airplay",new PF);
1624
- gF("airplay",new PF);function QF(a,b,c,d){d=void 0===d?null:d;this.i=a;this.j=b;this.h=RF(this);b.dataset.shakaPlayerContainer="";b.ui=this;this.Bg()&&b.classList.add("shaka-mobile");this.g=new Z(a,b,c,d,this.h);this.configure({});c.controls||a.dh(b);b.ui=this;c.ui=this}q=QF.prototype;q.destroy=function(){var a=this;return O(function(b){if(1==b.g)return a.g?E(b,a.g.destroy(),2):b.B(2);if(4!=b.g)return a.g=null,a.i?E(b,a.i.destroy(),4):b.B(4);a.i=null;F(b)})};
1625
- q.Bg=function(){return/(?:iPhone|iPad|iPod|Android)/.test(navigator.userAgent)?!0:hc()&&1<navigator.maxTouchPoints};q.getConfiguration=function(){var a=RF(this);lm(a,this.h,RF(this),{},"");return a};q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=mm(a,b));lm(this.h,a,RF(this),{},"");this.h.castReceiverAppId&&!this.h.overflowMenuButtons.includes("cast")&&this.h.overflowMenuButtons.push("cast");this.g.configure(this.h);this.g.dispatchEvent(new S("uiupdated"))};q.Xi=function(){return this.g};
1615
+ Z.prototype.incrementYaw=Z.prototype.zg;Z.prototype.toggleStereoscopicMode=Z.prototype.qd;Z.prototype.setVRFieldOfView=Z.prototype.Ak;Z.prototype.getVRFieldOfView=Z.prototype.vj;Z.prototype.getVRNorth=Z.prototype.wj;Z.prototype.isPlayingVR=Z.prototype.Qb;Z.prototype.canPlayVR=Z.prototype.Vf;Z.prototype.hideUI=Z.prototype.Dj;Z.prototype.showUI=Z.prototype.Bk;Z.prototype.isOpaque=Z.prototype.mc;Z.prototype.hideAdUI=Z.prototype.Kh;Z.prototype.showAdUI=Z.prototype.mi;Z.prototype.togglePiP=Z.prototype.me;
1616
+ Z.prototype.isPiPEnabled=Z.prototype.Se;Z.prototype.isPiPAllowed=Z.prototype.Re;Z.prototype.toggleFullScreen=Z.prototype.qf;Z.prototype.isFullScreenEnabled=Z.prototype.fd;Z.prototype.isFullScreenSupported=Z.prototype.Xd;Z.prototype.hideSettingsMenus=Z.prototype.Cc;Z.prototype.anySettingsMenusAreOpen=Z.prototype.Jd;Z.prototype.setLastTouchEventTime=Z.prototype.gi;Z.prototype.getDisplayTime=Z.prototype.qg;Z.prototype.isCastAllowed=Z.prototype.Ej;Z.prototype.setSeeking=Z.prototype.bh;
1617
+ Z.prototype.isSeeking=Z.prototype.Kj;Z.prototype.getConfig=Z.prototype.Wi;Z.prototype.getClientSideAdContainer=Z.prototype.Vi;Z.prototype.getServerSideAdContainer=Z.prototype.pj;Z.prototype.getControlsContainer=Z.prototype.Yi;Z.prototype.getLocalPlayer=Z.prototype.ej;Z.prototype.getPlayer=Z.prototype.bd;Z.prototype.getLocalVideo=Z.prototype.fj;Z.prototype.getVideo=Z.prototype.lc;Z.prototype.getVideoContainer=Z.prototype.yj;Z.prototype.getLocalization=Z.prototype.gj;Z.prototype.getCastProxy=Z.prototype.Ti;
1618
+ Z.prototype.getAd=Z.prototype.getAd;Z.prototype.setEnabledNativeControls=Z.prototype.di;Z.prototype.setEnabledShakaControls=Z.prototype.Yg;Z.prototype.configure=Z.prototype.configure;Z.prototype.loadComplete=Z.prototype.Nj;Z.prototype.allowCast=Z.prototype.Hi;Z.registerSeekBar=function(a){zF=a};Z.registerElement=hF;Z.prototype.destroy=Z.prototype.destroy;var iF=new Map,zF=new xE;function GF(a,b){SD.call(this,a,b);var c=this;this.l=this.controls.g;this.j=this.controls.h;this.i=[];this.g=en();this.g.classList.add("shaka-overflow-menu-button");this.g.classList.add("shaka-no-propagation");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");this.g.textContent="more_vert";this.parent.appendChild(this.g);this.h=W("div");this.h.classList.add("shaka-overflow-menu");this.h.classList.add("shaka-no-propagation");this.h.classList.add("shaka-show-controls-on-mouse-over");
1619
+ this.h.classList.add("shaka-hidden");this.j.appendChild(this.h);HF(this);this.eventManager.s(this.localization,"locale-updated",function(){IF(c)});this.eventManager.s(this.localization,"locale-changed",function(){IF(c)});this.eventManager.s(this.adManager,"ad-started",function(){c.ad&&c.ad.isLinear()&&XD(c.g,!1)});this.eventManager.s(this.adManager,"ad-stopped",function(){XD(c.g,!0)});this.eventManager.s(this.controls,"submenuopen",function(){XD(c.h,!1)});this.eventManager.s(this.h,"touchstart",function(d){c.controls.gi(Date.now());
1620
+ d.stopPropagation()});this.eventManager.s(this.g,"click",function(){JF(c)});IF(this);this.ad&&this.ad.isLinear()&&XD(this.g,!1)}na(GF,SD);GF.prototype.release=function(){this.j=null;for(var a=t(this.i),b=a.next();!b.done;b=a.next())b.value.release();this.i=[];SD.prototype.release.call(this)};function KF(a,b){LF.set(a,b)}
1621
+ function HF(a){for(var b=t(a.l.overflowMenuButtons),c=b.next();!c.done;c=b.next())c=c.value,LF.get(c)?(c=LF.get(c),a.i.push(c.create(a.h,a.controls))):Ya("Unrecognized overflow menu element requested:",c)}function JF(a){if(a.controls.Jd())a.controls.Cc();else{XD(a.h,!0);bF(a.controls);var b=function(c){return 0==c.classList.contains("shaka-hidden")};jb(a.h.childNodes,b)&&kb(a.h.childNodes,b)[0].focus()}}function IF(a){a.g.ariaLabel=a.localization.resolve("MORE_SETTINGS")}
1622
+ P("shaka.ui.OverflowMenu",GF);GF.registerElement=KF;function MF(){}MF.prototype.create=function(a,b){return new GF(a,b)};hF("overflow_menu",new MF);var LF=new Map;function NF(a,b){SD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-airplay-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.h=W("i");this.h.classList.add("material-icons-round");this.h.textContent="airplay";this.g.appendChild(this.h);window.WebKitPlaybackTargetAvailabilityEvent||this.g.classList.add("shaka-hidden");a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=W("span");a.appendChild(this.j);
1623
+ this.i=W("span");this.i.classList.add("shaka-current-selection-span");a.appendChild(this.i);this.g.appendChild(a);this.parent.appendChild(this.g);OF(this);PF(this);this.eventManager.s(this.localization,"locale-updated",function(){OF(c)});this.eventManager.s(this.localization,"locale-changed",function(){OF(c)});this.eventManager.s(this.g,"click",function(){c.controls.lc().webkitShowPlaybackTargetPicker()});a=this.controls.lc();this.eventManager.s(a,"webkitplaybacktargetavailabilitychanged",function(d){var e=
1624
+ c.player.Qd()==fp;XD(c.g,"available"==d.availability&&e)});this.eventManager.s(a,"webkitcurrentplaybacktargetiswirelesschanged",function(){PF(c)})}na(NF,SD);function PF(a){var b=a.controls.lc();a.g.ariaPressed=b&&b.webkitCurrentPlaybackTargetIsWireless?"true":"false"}function OF(a){a.g.ariaLabel=a.localization.resolve("AIRPLAY");a.j.textContent=a.localization.resolve("AIRPLAY")}P("shaka.ui.AirPlayButton",NF);function QF(){}QF.prototype.create=function(a,b){return new NF(a,b)};KF("airplay",new QF);
1625
+ hF("airplay",new QF);function RF(a,b,c,d){d=void 0===d?null:d;this.i=a;this.j=b;this.h=SF(this);b.dataset.shakaPlayerContainer="";b.ui=this;this.Bg()&&b.classList.add("shaka-mobile");this.g=new Z(a,b,c,d,this.h);this.configure({});c.controls||a.dh(b);b.ui=this;c.ui=this}q=RF.prototype;q.destroy=function(){var a=this;return O(function(b){if(1==b.g)return a.g?E(b,a.g.destroy(),2):b.B(2);if(4!=b.g)return a.g=null,a.i?E(b,a.i.destroy(),4):b.B(4);a.i=null;F(b)})};
1626
+ q.Bg=function(){return/(?:iPhone|iPad|iPod|Android)/.test(navigator.userAgent)?!0:hc()&&1<navigator.maxTouchPoints};q.getConfiguration=function(){var a=SF(this);lm(a,this.h,SF(this),{},"");return a};q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=mm(a,b));lm(this.h,a,SF(this),{},"");this.h.castReceiverAppId&&!this.h.overflowMenuButtons.includes("cast")&&this.h.overflowMenuButtons.push("cast");this.g.configure(this.h);this.g.dispatchEvent(new S("uiupdated"))};q.Xi=function(){return this.g};
1626
1627
  q.xk=function(a){this.g.Yg(a)};
1627
- function RF(a){var b={controlPanelElements:"play_pause time_and_duration spacer mute volume fullscreen overflow_menu".split(" "),overflowMenuButtons:"captions quality language picture_in_picture cast playback_rate recenter_vr toggle_stereoscopic".split(" "),statisticsList:"width height corruptedFrames decodedFrames droppedFrames drmTimeSeconds licenseTime liveLatency loadLatency bufferingTime manifestTimeSeconds estimatedBandwidth streamBandwidth maxSegmentDuration pauseTime playTime completionPercent bytesDownloaded".split(" "),contextMenuElements:["loop",
1628
+ function SF(a){var b={controlPanelElements:"play_pause time_and_duration spacer mute volume fullscreen overflow_menu".split(" "),overflowMenuButtons:"captions quality language picture_in_picture cast playback_rate recenter_vr toggle_stereoscopic".split(" "),statisticsList:"width height corruptedFrames decodedFrames droppedFrames drmTimeSeconds licenseTime liveLatency loadLatency bufferingTime manifestTimeSeconds estimatedBandwidth streamBandwidth maxSegmentDuration pauseTime playTime completionPercent bytesDownloaded".split(" "),contextMenuElements:["loop",
1628
1629
  "picture_in_picture","statistics"],playbackRates:[.5,.75,1,1.25,1.5,1.75,2],fastForwardRates:[2,4,8,1],rewindRates:[-1,-2,-4,-8],addSeekBar:!0,addBigPlayButton:!1,customContextMenu:!1,castReceiverAppId:"",castAndroidReceiverCompatible:!1,clearBufferOnQualityChange:!0,showUnbufferedStart:!1,seekBarColors:{base:"rgba(255, 255, 255, 0.3)",buffered:"rgba(255, 255, 255, 0.54)",played:"rgb(255, 255, 255)",adBreaks:"rgb(255, 204, 0)"},volumeBarColors:{base:"rgba(255, 255, 255, 0.54)",level:"rgb(255, 255, 255)"},
1629
- trackLabelFormat:SF,textTrackLabelFormat:SF,fadeDelay:0,doubleClickForFullscreen:!0,singleClickForPlayAndPause:!0,enableKeyboardPlaybackControls:!0,enableFullscreenOnRotation:!0,forceLandscapeOnFullscreen:!0,enableTooltips:!1,keyboardSeekDistance:5,keyboardLargeSeekDistance:60,fullScreenElement:a.j,preferDocumentPictureInPicture:!0,showAudioChannelCountVariants:!0,seekOnTaps:!0,tapSeekDistance:10,refreshTickInSeconds:.125,displayInVrMode:!1,defaultVrProjectionMode:"equirectangular"};"remote"in HTMLMediaElement.prototype?
1630
+ trackLabelFormat:TF,textTrackLabelFormat:TF,fadeDelay:0,doubleClickForFullscreen:!0,singleClickForPlayAndPause:!0,enableKeyboardPlaybackControls:!0,enableFullscreenOnRotation:!0,forceLandscapeOnFullscreen:!0,enableTooltips:!1,keyboardSeekDistance:5,keyboardLargeSeekDistance:60,fullScreenElement:a.j,preferDocumentPictureInPicture:!0,showAudioChannelCountVariants:!0,seekOnTaps:!0,tapSeekDistance:10,refreshTickInSeconds:.125,displayInVrMode:!1,defaultVrProjectionMode:"equirectangular"};"remote"in HTMLMediaElement.prototype?
1630
1631
  b.overflowMenuButtons.push("remote"):window.WebKitPlaybackTargetAvailabilityEvent&&b.overflowMenuButtons.push("airplay");a.Bg()&&(b.addBigPlayButton=!0,b.controlPanelElements=b.controlPanelElements.filter(function(c){return"play_pause"!=c&&"volume"!=c}));return b}
1631
- function TF(){var a,b,c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y;return O(function(B){switch(B.g){case 1:Oz();if(!ro())return UF("shaka-ui-load-failed",VF),B.return();a=document.querySelectorAll("[data-shaka-player-container]");b=document.querySelectorAll("[data-shaka-player]");c=document.querySelectorAll("[data-shaka-player-canvas]");d=document.querySelectorAll("[data-shaka-player-vr-canvas]");if(!b.length&&!a.length){B.B(2);break}if(b.length&&!a.length){e=t(b);for(f=e.next();!f.done;f=e.next())g=f.value,
1632
- g.ui||(h=document.createElement("div"),k=g.parentElement,k.replaceChild(h,g),h.appendChild(g),l=WF(h,c,d),m=l.Ph,n=l.xi,XF(h,g,m,n));B.B(2);break}p=t(a);r=p.next();case 4:if(r.done){B.B(2);break}u=r.value;if(u.ui){B.B(5);break}v=null;w=t(b);for(f=w.next();!f.done;f=w.next())if(A=f.value,A.parentElement==u){v=A;break}v||(v=document.createElement("video"),v.setAttribute("playsinline",""),u.appendChild(v));z=WF(u,c,d);C=z.Ph;y=z.xi;ta(B,7);return E(B,XF(u,v,C,y),9);case 9:va(B,5);break;case 7:return wa(B),
1633
- UF("shaka-ui-load-failed",YF),B.return();case 5:r=p.next();B.B(4);break;case 2:UF("shaka-ui-loaded"),F(B)}})}function UF(a,b){var c=null;void 0!=b&&(c={reasonCode:b});a=new CustomEvent(a,{detail:c});document.dispatchEvent(a)}
1634
- function XF(a,b,c,d){var e,f,g,h,k,l,m,n,p;return O(function(r){switch(r.g){case 1:e=new X;f=new QF(e,a,b,d);e.qh(c);g="";h=!1;a.dataset&&a.dataset.shakaPlayerCastReceiverId?(g=a.dataset.shakaPlayerCastReceiverId,h="true"===a.dataset.shakaPlayerCastAndroidReceiverCompatible):b.dataset&&b.dataset.shakaPlayerCastReceiverId&&(g=b.dataset.shakaPlayerCastReceiverId,h="true"===b.dataset.shakaPlayerCastAndroidReceiverCompatible);g.length&&f.configure({castReceiverAppId:g,castAndroidReceiverCompatible:h});
1635
- b.controls&&f.g.di(!0);if(k=b.getAttribute("src"))l=document.createElement("source"),l.setAttribute("src",k),b.appendChild(l),b.removeAttribute("src");m=t(b.querySelectorAll("source"));n=m.next();case 2:if(n.done){r.B(4);break}p=n.value;ta(r,5);return E(r,f.g.$c().load(p.getAttribute("src")),7);case 7:r.B(4);break;case 5:wa(r);case 3:n=m.next();r.B(2);break;case 4:return E(r,e.tc(b),0)}})}
1636
- function WF(a,b,c){var d=null,e=t(b);for(b=e.next();!b.done;b=e.next())if(b=b.value,b.parentElement==a){d=b;break}d||(d=document.createElement("canvas"),d.classList.add("shaka-canvas-container"),a.appendChild(d));e=null;c=t(c);for(b=c.next();!b.done;b=c.next())if(b=b.value,b.parentElement==a){e=b;break}e||(e=document.createElement("canvas"),e.classList.add("shaka-vr-canvas-container"),a.appendChild(e));return{Ph:d,xi:e}}P("shaka.ui.Overlay",QF);QF.prototype.setEnabled=QF.prototype.xk;
1637
- QF.prototype.getControls=QF.prototype.Xi;QF.prototype.configure=QF.prototype.configure;QF.prototype.getConfiguration=QF.prototype.getConfiguration;QF.prototype.isMobile=QF.prototype.Bg;QF.prototype.destroy=QF.prototype.destroy;var SF=0;QF.TrackLabelFormat={LANGUAGE:SF,ROLE:1,LANGUAGE_ROLE:2,LABEL:3};var VF=0,YF=1;QF.FailReasonCode={NO_BROWSER_SUPPORT:VF,PLAYER_FAILED_TO_LOAD:YF};
1638
- "complete"==document.readyState?O(function(a){if(1==a.g)return E(a,Promise.resolve(),2);TF();F(a)}):window.addEventListener("load",TF);function ZF(a,b,c,d,e,f,g,h){function k(K){var G="";5<=K&&(G=" "+f.resolve("SURROUND"));return G}function l(K,G,J,I){K=[K,G];h&&null!=I&&K.push(I);J&&3==g&&K.push(J);return K.join(": ")}function m(K){return"variant"==K.type?K.audioRoles?K.audioRoles.join(", "):void 0:K.roles.join(", ")}var n=a.find(function(K){return 1==K.active}),p=SD(b);fn(b);b.appendChild(p);p=new Map;for(var r=t(a),u=r.next();!u.done;u=r.next())u=u.value,p.has(u.language)||p.set(u.language,new Set),p.get(u.language).add(m(u));
1639
- p=new Set;n=n?l(n.language,m(n),n.label,n.channelsCount):"";r={};a=t(a);for(u=a.next();!u.done;r={Kb:r.Kb},u=a.next()){r.Kb=u.value;u=r.Kb.language;var v=r.Kb.forced,w=f.resolve("SUBTITLE_FORCED"),A=m(r.Kb),z=r.Kb.label,C=r.Kb.channelsCount,y=l(u,A,z,C);if(!p.has(y)){p.add(y);var B=en();B.addEventListener("click",function(K){return function(){c(K.Kb)}}(r));var D=W("span");B.appendChild(D);D.textContent=$F(u,f);switch(g){case SF:h&&(D.textContent+=k(C));v&&(D.textContent+=" ("+w+")");break;case 1:h&&
1640
- (D.textContent+=k(C));A?D.textContent=A:(Ya("Track #"+r.Kb.id+" does not have a role, but the UI is configured to only show role."),D.textContent="?");v&&(D.textContent+=" ("+w+")");break;case 2:h&&(D.textContent+=k(C));A&&(D.textContent+=": "+A);v&&(D.textContent+=" ("+w+")");break;case 3:z?D.textContent=z:(Ya("Track #"+r.Kb.id+" does not have a label, but the UI is configured to only show labels."),D.textContent="?")}d&&y==n&&(B.appendChild(VD()),D.classList.add("shaka-chosen-item"),B.ariaSelected=
1641
- "true",e.textContent=D.textContent);b.appendChild(B)}}}function $F(a,b){if(!a&&!b)return"";switch(a){case "mul":return b.resolve("MULTIPLE_LANGUAGES");case "und":return b.resolve("UNDETERMINED_LANGUAGE");case "zxx":return b.resolve("NOT_APPLICABLE")}var c=dd(a);return a in ND?ND[a].C:c in ND?ND[c].C+" ("+a+")":b.resolve("UNRECOGNIZED_LANGUAGE")+" ("+a+")"};function aG(a,b,c){RD.call(this,a,b);var d=this;bG(this,c);cG(this);dG(this);this.eventManager.s(this.button,"click",function(){d.menu.classList.contains("shaka-hidden")?(d.controls.dispatchEvent(new S("submenuopen")),WD(d.menu,!0),UD(d.menu)):WD(d.menu,!1)})}na(aG,RD);
1642
- function bG(a,b){a.button=en();a.button.classList.add("shaka-overflow-button");a.icon=W("i");a.icon.classList.add("material-icons-round");a.icon.textContent=b;a.button.appendChild(a.icon);b=W("label");b.classList.add("shaka-overflow-button-label");b.classList.add("shaka-overflow-menu-only");a.nameSpan=W("span");b.appendChild(a.nameSpan);a.currentSelection=W("span");a.currentSelection.classList.add("shaka-current-selection-span");b.appendChild(a.currentSelection);a.button.appendChild(b);a.parent.appendChild(a.button)}
1643
- function cG(a){a.menu=W("div");a.menu.classList.add("shaka-no-propagation");a.menu.classList.add("shaka-show-controls-on-mouse-over");a.menu.classList.add("shaka-settings-menu");a.menu.classList.add("shaka-hidden");a.backButton=en();a.backButton.classList.add("shaka-back-to-overflow-button");a.menu.appendChild(a.backButton);a.eventManager.s(a.backButton,"click",function(){a.controls.Bc()});var b=W("i");b.classList.add("material-icons-round");b.textContent="close";a.backButton.appendChild(b);a.backSpan=
1644
- W("span");a.backButton.appendChild(a.backSpan);a.controls.h.appendChild(a.menu)}function dG(a){a.parent.classList.contains("shaka-overflow-menu")&&(a.backButton.firstChild.textContent="arrow_back",a.eventManager.s(a.backButton,"click",function(){function b(c){return 0==c.classList.contains("shaka-hidden")}WD(a.parent,!0);jb(a.parent.childNodes,b)&&kb(a.parent.childNodes,b)[0].focus();aF(a.controls)}))}P("shaka.ui.SettingsMenu",aG);function eG(a,b){aG.call(this,a,b,"language");var c=this;this.button.classList.add("shaka-language-button");this.button.classList.add("shaka-tooltip-status");this.menu.classList.add("shaka-audio-languages");this.eventManager.s(this.localization,"locale-updated",function(){fG(c)});this.eventManager.s(this.localization,"locale-changed",function(){fG(c)});this.eventManager.s(this.player,"loading",function(){gG(c)});this.eventManager.s(this.player,"trackschanged",function(){gG(c)});this.eventManager.s(this.player,
1645
- "variantchanged",function(){hG(c)});fG(this);hG(this)}na(eG,aG);
1646
- function hG(a){var b=a.player.Db();ZF(b,a.menu,function(c){c.channelsCount&&a.controls.g.showAudioChannelCountVariants?a.player.lf(c.language,c.roles[0],c.channelsCount):a.player.lf(c.language,c.roles[0])},!0,a.currentSelection,a.localization,a.controls.g.trackLabelFormat,a.controls.g.showAudioChannelCountVariants);UD(a.menu);a.controls.dispatchEvent(new S("languageselectionupdated"));a.button.setAttribute("shaka-status",a.currentSelection.innerText);WD(a.button,2<a.menu.getElementsByTagName("button").length)}
1647
- function gG(a){var b=0<a.player.Db().length;WD(a.button,b);hG(a)}function fG(a){a.backButton.ariaLabel=a.localization.resolve("BACK");a.button.ariaLabel=a.localization.resolve("LANGUAGE");a.nameSpan.textContent=a.localization.resolve("LANGUAGE");a.backSpan.textContent=a.localization.resolve("LANGUAGE")}P("shaka.ui.AudioLanguageSelection",eG);function iG(){}iG.prototype.create=function(a,b){return new eG(a,b)};JF("language",new iG);gF("language",new iG);function jG(a,b){RD.call(this,a,b);var c=this;this.h=this.controls.F;this.g=en();this.g.classList.add("shaka-cast-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.i=W("i");this.i.classList.add("material-icons-round");this.i.textContent="cast";this.g.appendChild(this.i);a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.l=W("span");a.appendChild(this.l);this.j=W("span");this.j.classList.add("shaka-current-selection-span");
1648
- a.appendChild(this.j);this.g.appendChild(a);this.parent.appendChild(this.g);kG(this);lG(this);this.eventManager.s(this.localization,"locale-updated",function(){kG(c)});this.eventManager.s(this.localization,"locale-changed",function(){kG(c)});this.eventManager.s(this.g,"click",function(){mG(c)});this.eventManager.s(this.controls,"caststatuschanged",function(){lG(c)})}na(jG,RD);
1649
- function mG(a){var b;O(function(c){if(1==c.g){if(a.h.Oa())return a.h.ni(),c.B(0);ta(c,3);a.g.disabled=!0;return E(c,a.h.cast(),5)}if(3!=c.g)return a.g.disabled=!1,va(c,0);b=wa(c);a.g.disabled=!1;8004!=b.code&&a.controls.dispatchEvent(new S("error",(new Map).set("detail",b)));F(c)})}function lG(a){var b=a.h.Uf()&&a.controls.na,c=a.h.Oa();WD(a.g,b);a.i.textContent=c?"cast_connected":"cast";b&&(a.g.ariaPressed=c?"true":"false");nG(a)}
1650
- function nG(a){a.j.textContent=a.h.Oa()?a.h.hf():a.localization.resolve("OFF")}function kG(a){a.g.ariaLabel=a.localization.resolve("CAST");a.l.textContent=a.localization.resolve("CAST");nG(a)}P("shaka.ui.CastButton",jG);function oG(){}oG.prototype.create=function(a,b){return new jG(a,b)};JF("cast",new oG);gF("cast",new oG);function pG(a,b){RD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("material-icons-round");this.g.classList.add("shaka-fast-forward-button");this.g.classList.add("shaka-tooltip-status");this.g.setAttribute("shaka-status","1x");this.g.textContent="fast_forward";this.parent.appendChild(this.g);qG(this);this.h=this.controls.g.fastForwardRates;this.eventManager.s(this.localization,"locale-updated",function(){qG(c)});this.eventManager.s(this.localization,"locale-changed",function(){qG(c)});
1651
- this.eventManager.s(this.g,"click",function(){if(c.video.duration){var d=c.h.indexOf(c.player.Ra())+1;d=d!=c.h.length?c.h[d]:c.h[0];c.player.Mc(d);c.g.setAttribute("shaka-status",d+"x")}})}na(pG,RD);function qG(a){a.g.ariaLabel=a.localization.resolve("FAST_FORWARD")}P("shaka.ui.FastForwardButton",pG);function rG(){}rG.prototype.create=function(a,b){return new pG(a,b)};gF("fast_forward",new rG);function sG(a,b){RD.call(this,a,b);var c=this;this.h=this.controls.o;this.g=en();this.g.classList.add("shaka-fullscreen-button");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");tG(this);this.g.textContent="fullscreen";this.parent.appendChild(this.g);uG(this);this.eventManager.s(this.localization,"locale-updated",function(){uG(c)});this.eventManager.s(this.localization,"locale-changed",function(){uG(c)});this.eventManager.s(this.g,"click",function(){return O(function(d){return E(d,
1652
- c.controls.qf(),0)})});this.eventManager.s(document,"fullscreenchange",function(){c.g.textContent=c.controls.ed()?"fullscreen_exit":"fullscreen";uG(c)});this.eventManager.s(this.h,"loadedmetadata",function(){tG(c)});this.eventManager.s(this.h,"loadeddata",function(){tG(c)})}na(sG,RD);function tG(a){a.controls.Xd()?a.g.classList.remove("shaka-hidden"):a.g.classList.add("shaka-hidden")}function uG(a){a.g.ariaLabel=a.localization.resolve(a.controls.ed()?"EXIT_FULL_SCREEN":"FULL_SCREEN")}
1653
- P("shaka.ui.FullscreenButton",sG);function vG(){}vG.prototype.create=function(a,b){return new sG(a,b)};gF("fullscreen",new vG);function wG(a,b){RD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-loop-button");this.g.classList.add("shaka-tooltip");this.i=W("i");this.i.classList.add("material-icons-round");this.i.textContent="repeat";this.g.appendChild(this.i);a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=W("span");this.j.textContent=this.localization.resolve("LOOP");a.appendChild(this.j);this.l=W("span");this.l.classList.add("shaka-current-selection-span");
1654
- a.appendChild(this.l);this.g.appendChild(a);xG(this);this.parent.appendChild(this.g);this.eventManager.s(this.localization,"locale-updated",function(){xG(c)});this.eventManager.s(this.localization,"locale-changed",function(){xG(c)});this.eventManager.s(this.g,"click",function(){c.video.loop=!c.video.loop;c.h.Pa();c.h.za(1)});this.m=this.video.loop;this.h=new Ub(function(){c.m!=c.video.loop&&(xG(c),c.m=c.video.loop)});this.h.za(1)}na(wG,RD);
1655
- wG.prototype.release=function(){this.h.stop();this.h=null;RD.prototype.release.call(this)};function xG(a){a.j.textContent=a.localization.resolve("LOOP");a.l.textContent=a.localization.resolve(a.video.loop?"ON":"OFF");a.i.textContent=a.video.loop?"repeat_on":"repeat";a.g.ariaLabel=a.localization.resolve(a.video.loop?"EXIT_LOOP_MODE":"ENTER_LOOP_MODE")}P("shaka.ui.LoopButton",wG);function yG(){}yG.prototype.create=function(a,b){return new wG(a,b)};JF("loop",new yG);gF("loop",new yG);gE("loop",new yG);function zG(a,b){RD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-mute-button");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");this.parent.appendChild(this.g);AG(this);BG(this);this.eventManager.s(this.localization,"locale-updated",function(){AG(c)});this.eventManager.s(this.localization,"locale-changed",function(){AG(c)});this.eventManager.s(this.g,"click",function(){c.ad&&c.ad.isLinear()?c.ad.setMuted(!c.ad.isMuted()):c.video.muted=!c.video.muted});
1656
- this.eventManager.s(this.video,"volumechange",function(){AG(c);BG(c)});this.eventManager.s(this.adManager,"ad-volume-changed",function(){AG(c);BG(c)});this.eventManager.s(this.adManager,"ad-muted",function(){AG(c);BG(c)});this.eventManager.s(this.adManager,"ad-stopped",function(){c.ad=null;AG(c);BG(c)})}na(zG,RD);function AG(a){var b=a.ad?a.ad.isMuted()?"UNMUTE":"MUTE":a.video.muted?"UNMUTE":"MUTE";a.g.ariaLabel=a.localization.resolve(b)}
1657
- function BG(a){var b=a.ad?a.ad.isMuted()?"volume_off":"volume_up":a.video.muted?"volume_off":"volume_up";a.g.textContent=b}P("shaka.ui.MuteButton",zG);function CG(){}CG.prototype.create=function(a,b){return new zG(a,b)};gF("mute",new CG);function DG(a,b){RD.call(this,a,b);var c=this;this.l=this.controls.o;this.g=en();this.g.classList.add("shaka-pip-button");this.g.classList.add("shaka-tooltip");this.i=W("i");this.i.classList.add("material-icons-round");this.i.textContent="picture_in_picture_alt";this.g.appendChild(this.i);a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=W("span");this.j.textContent=this.localization.resolve("PICTURE_IN_PICTURE");a.appendChild(this.j);this.h=
1658
- W("span");this.h.classList.add("shaka-current-selection-span");a.appendChild(this.h);this.g.appendChild(a);EG(this);this.parent.appendChild(this.g);this.controls.Re()||WD(this.g,!1);this.eventManager.s(this.localization,"locale-updated",function(){EG(c)});this.eventManager.s(this.localization,"locale-changed",function(){EG(c)});this.eventManager.s(this.g,"click",function(){c.controls.me()});this.eventManager.s(this.l,"enterpictureinpicture",function(){FG(c)});this.eventManager.s(this.l,"leavepictureinpicture",
1659
- function(){GG(c)});this.eventManager.s(this.controls,"caststatuschanged",function(){HG(c)});this.eventManager.s(this.player,"trackschanged",function(){HG(c)});"documentPictureInPicture"in window&&this.eventManager.s(window.documentPictureInPicture,"enter",function(d){FG(c);c.eventManager.oa(d.window,"pagehide",function(){GG(c)})})}na(DG,RD);
1660
- function FG(a){a.i.textContent="branding_watermark";a.g.ariaLabel=a.localization.resolve("EXIT_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve("ON")}function GG(a){a.i.textContent="picture_in_picture_alt";a.g.ariaLabel=a.localization.resolve("ENTER_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve("OFF")}
1661
- function EG(a){a.j.textContent=a.localization.resolve("PICTURE_IN_PICTURE");var b=a.controls.Se();a.g.ariaLabel=a.localization.resolve(b?"EXIT_PICTURE_IN_PICTURE":"ENTER_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve(b?"ON":"OFF")}function HG(a){O(function(b){if(!a.controls.Re())return WD(a.g,!1),a.controls.Se()?E(b,a.controls.me(),0):b.B(0);if(!a.player||!a.player.dd())return WD(a.g,!0),b.B(0);WD(a.g,!1);return a.controls.Se()?E(b,a.controls.me(),0):b.B(0)})}P("shaka.ui.PipButton",DG);
1662
- function IG(){}IG.prototype.create=function(a,b){return new DG(a,b)};JF("picture_in_picture",new IG);gF("picture_in_picture",new IG);gE("picture_in_picture",new IG);function JG(a,b){aG.call(this,a,b,"slow_motion_video");var c=this;this.button.classList.add("shaka-playbackrate-button");this.menu.classList.add("shaka-playback-rates");this.button.classList.add("shaka-tooltip-status");this.eventManager.s(this.localization,"locale-updated",function(){KG(c)});this.eventManager.s(this.localization,"locale-changed",function(){KG(c)});this.eventManager.s(this.player,"loaded",function(){LG(c,c.player.Ra())});this.eventManager.s(this.player,"ratechange",function(){LG(c,
1663
- c.player.Ra())});this.g=new Map(this.controls.g.playbackRates.map(function(d){return[d+"x",d]}));KG(this);UG(this);LG(this,this.player.Ra())}na(JG,aG);function KG(a){a.backButton.ariaLabel=a.localization.resolve("BACK");a.button.ariaLabel=a.localization.resolve("PLAYBACK_RATE");a.nameSpan.textContent=a.localization.resolve("PLAYBACK_RATE");a.backSpan.textContent=a.localization.resolve("PLAYBACK_RATE")}
1664
- function LG(a,b){var c=TD(a.menu,"material-icons-round shaka-chosen-item");if(c){var d=c.parentElement;d.removeAttribute("aria-selected");d.getElementsByTagName("span")[0].classList.remove("shaka-chosen-item");d.removeChild(c)}if(c=Array.from(a.menu.querySelectorAll("span")).find(function(e){return a.g.get(e.textContent)==b}))d=c.parentElement,d.appendChild(VD()),d.ariaSelected="true",c.classList.add("shaka-chosen-item");a.currentSelection.textContent=b+"x";a.button.setAttribute("shaka-status",b+
1665
- "x")}function UG(a){for(var b={},c=t(a.g.keys()),d=c.next();!d.done;b={yd:b.yd},d=c.next()){b.yd=d.value;d=en();var e=W("span");e.textContent=b.yd;d.appendChild(e);a.eventManager.s(d,"click",function(f){return function(){a.video.playbackRate=a.g.get(f.yd);a.video.defaultPlaybackRate=a.g.get(f.yd)}}(b));a.menu.appendChild(d)}UD(a.menu)}P("shaka.ui.PlaybackRateSelection",JG);function VG(){}VG.prototype.create=function(a,b){return new JG(a,b)};JF("playback_rate",new VG);gF("playback_rate",new VG);function WG(a,b){RD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-current-time");XG(this,"0:00");this.parent.appendChild(this.g);this.eventManager.s(this.g,"click",function(){c.player.U()&&(c.video.currentTime=c.player.Ta().end)});this.eventManager.s(this.player,"loading",function(){WD(c.g,!0)});this.eventManager.s(this.controls,"timeandseekrangeupdated",function(){var d=c.controls.$,e=c.controls.qg(),f=c.player.Ta(),g=f.end-f.start;c.player.U()?(e=Math.max(0,Math.floor(f.end-
1666
- e)),g=3600<=g,1<=e||d?(XG(c,"- "+XD(e,g)),c.g.disabled=!1):(XG(c,c.localization.resolve("LIVE")),c.g.disabled=!0)):(d=3600<=g,e=XD(Math.max(0,e-f.start),d),g&&(e+=" / "+XD(g,d)),XG(c,e),c.g.disabled=!0)});this.eventManager.s(this.player,"trackschanged",function(){c.player.U()&&(c.g.ariaLabel=c.localization.resolve("SKIP_TO_LIVE"))});this.eventManager.s(this.adManager,"ad-started",function(){WD(c.g,!1)});this.eventManager.s(this.adManager,"ad-stopped",function(){WD(c.g,!0)})}na(WG,RD);
1667
- function XG(a,b){b!=a.g.textContent&&(a.g.textContent=b)}P("shaka.ui.PresentationTimeTracker",WG);function YG(){}YG.prototype.create=function(a,b){return new WG(a,b)};gF("time_and_duration",new YG);function ZG(a,b){RD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-recenter-vr-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.h=W("i");this.h.classList.add("material-icons-round");this.h.textContent="control_camera";this.g.appendChild(this.h);a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=W("span");a.appendChild(this.j);this.i=W("span");this.i.classList.add("shaka-current-selection-span");
1668
- a.appendChild(this.i);this.g.appendChild(a);this.parent.appendChild(this.g);$G(this);this.eventManager.s(this.localization,"locale-updated",function(){$G(c)});this.eventManager.s(this.localization,"locale-changed",function(){$G(c)});var d=this.controls.u;this.eventManager.s(this.g,"click",function(){d.g?SE(d.g):Ya("Not playing VR content")});this.eventManager.s(d,"vrstatuschanged",function(){WD(c.g,c.controls.Qb())});WD(this.g,this.controls.Qb())}na(ZG,RD);
1669
- function $G(a){a.g.ariaLabel=a.localization.resolve("RECENTER_VR");a.j.textContent=a.localization.resolve("RECENTER_VR")}P("shaka.ui.RecenterVRButton",ZG);function aH(){}aH.prototype.create=function(a,b){return new ZG(a,b)};JF("recenter_vr",new aH);gF("recenter_vr",new aH);function bH(a,b){RD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-remote-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.i=W("i");this.i.classList.add("material-icons-round");a="cast";(b=mc())&&13<=b&&(a="airplay");this.i.textContent=a;this.g.appendChild(this.i);a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.l=W("span");a.appendChild(this.l);this.j=W("span");this.j.classList.add("shaka-current-selection-span");
1670
- a.appendChild(this.j);this.g.appendChild(a);this.parent.appendChild(this.g);this.h=-1;cH(this);WD(this.g,!1);!this.video.remote||this.video.disableRemotePlayback?this.g.classList.add("shaka-hidden"):(this.eventManager.s(this.localization,"locale-updated",function(){cH(c)}),this.eventManager.s(this.localization,"locale-changed",function(){cH(c)}),this.eventManager.s(this.controls,"caststatuschanged",function(){dH(c)}),this.eventManager.s(this.g,"click",function(){c.video.remote.prompt()}),this.eventManager.s(this.video.remote,
1671
- "connect",function(){dH(c)}),this.eventManager.s(this.video.remote,"connecting",function(){dH(c)}),this.eventManager.s(this.video.remote,"disconnect",function(){dH(c)}),this.eventManager.s(this.player,"loaded",function(){dH(c)}),dH(this))}na(bH,RD);bH.prototype.release=function(){this.video.remote&&-1!=this.h&&this.video.remote.cancelWatchAvailability(this.h).catch(function(){});RD.prototype.release.call(this)};
1672
- function dH(a){var b,c;O(function(d){switch(d.g){case 1:if(a.controls.F.Uf()&&a.controls.na){WD(a.g,!1);-1!=a.h&&(a.video.remote.cancelWatchAvailability(a.h),a.h=-1);d.B(0);break}if("disconnected"==a.video.remote.state){b=function(e){a.player?WD(a.g,a.player.Qd()==fp&&e):WD(a.g,!1)};ta(d,7);if(-1==a.h){d.B(9);break}return E(d,a.video.remote.cancelWatchAvailability(a.h),10)}if(-1==a.h){d.B(0);break}return E(d,a.video.remote.cancelWatchAvailability(a.h),6);case 6:a.h=-1;d.B(0);break;case 10:a.h=-1;
1673
- case 9:va(d,8);break;case 7:wa(d);case 8:return ta(d,11),E(d,a.video.remote.watchAvailability(b),13);case 13:c=d.h;a.h=c;va(d,0);break;case 11:wa(d),b(!0),F(d)}})}function cH(a){var b=a.localization.resolve("CAST"),c=mc();c&&13<=c&&(b=a.localization.resolve("AIRPLAY"));a.g.ariaLabel=b;a.l.textContent=b}P("shaka.ui.RemoteButton",bH);function eH(){}eH.prototype.create=function(a,b){return new bH(a,b)};JF("remote",new eH);gF("remote",new eH);function fH(a,b){aG.call(this,a,b,"settings");var c=this;this.button.classList.add("shaka-resolution-button");this.button.classList.add("shaka-tooltip-status");this.menu.classList.add("shaka-resolutions");this.eventManager.s(this.localization,"locale-updated",function(){gH(c)});this.eventManager.s(this.localization,"locale-changed",function(){gH(c)});this.eventManager.s(this.player,"loading",function(){hH(c)});this.eventManager.s(this.player,"variantchanged",function(){hH(c)});this.eventManager.s(this.player,
1674
- "trackschanged",function(){hH(c)});this.eventManager.s(this.player,"abrstatuschanged",function(){hH(c)});hH(this)}na(fH,aG);
1675
- function hH(a){var b=[];a.player.Qd()!=fp&&(b=a.player.Db());var c=b.find(function(k){return k.active});c&&(b=b.filter(function(k){if(k.language!=c.language||a.controls.g.showAudioChannelCountVariants&&k.channelsCount!=c.channelsCount)return!1;var l=a.controls.g.trackLabelFormat;return(1==l||2==l)&&JSON.stringify(k.audioRoles)!=JSON.stringify(c.audioRoles)||3==l&&k.label!=c.label?!1:!0}));b=a.player.dd()?b.filter(function(k,l){return b.findIndex(function(m){return m.bandwidth==k.bandwidth})==l}):
1676
- 1<[].concat(x(new Set(b.map(function(k){return k.audioId})))).length?b.filter(function(k,l){return b.findIndex(function(m){return m.height==k.height&&m.videoBandwidth==k.videoBandwidth&&m.frameRate==k.frameRate&&m.hdr==k.hdr&&m.videoLayout==k.videoLayout})==l}):b.filter(function(k,l){return b.findIndex(function(m){return m.height==k.height&&m.bandwidth==k.bandwidth&&m.frameRate==k.frameRate&&m.hdr==k.hdr&&m.videoLayout==k.videoLayout})==l});a.player.dd()?b.sort(function(k,l){return l.bandwidth-k.bandwidth}):
1677
- b.sort(function(k,l){return l.height==k.height?l.bandwidth-k.bandwidth:l.height-k.height});var d=SD(a.menu);fn(a.menu);a.menu.appendChild(d);d=a.player.getConfiguration().abr.enabled;for(var e={},f=t(b),g=f.next();!g.done;e={Tb:e.Tb},g=f.next()){e.Tb=g.value;g=en();g.classList.add("explicit-resolution");a.eventManager.s(g,"click",function(k){return function(){var l=k.Tb;a.player.configure({abr:{enabled:!1}});a.player.mf(l,a.controls.g.clearBufferOnQualityChange)}}(e));var h=W("span");h.textContent=
1678
- a.player.dd()&&e.Tb.bandwidth?Math.round(e.Tb.bandwidth/1E3)+" kbits/s":e.Tb.height&&e.Tb.width?iH(e.Tb,b):"Unknown";g.appendChild(h);d||e.Tb!=c||(g.ariaSelected="true",g.appendChild(VD()),h.classList.add("shaka-chosen-item"),a.currentSelection.textContent=h.textContent);a.menu.appendChild(g)}e=en();e.classList.add("shaka-enable-abr-button");a.eventManager.s(e,"click",function(){a.player.configure({abr:{enabled:!0}});hH(a)});a.g=W("span");a.g.classList.add("shaka-auto-span");a.g.textContent=a.localization.resolve("AUTO_QUALITY");
1679
- e.appendChild(a.g);d&&(e.ariaSelected="true",e.appendChild(VD()),a.g.classList.add("shaka-chosen-item"),a.currentSelection.textContent=a.localization.resolve("AUTO_QUALITY"));a.button.setAttribute("shaka-status",a.currentSelection.textContent);a.menu.appendChild(e);UD(a.menu);a.controls.dispatchEvent(new S("resolutionselectionupdated"));gH(a);WD(a.button,1<b.length)}
1680
- function iH(a,b){var c=a.height||0,d=a.width||0,e=c;d/c>16/9&&(e=Math.round(9*d/16));c=e+"p";2160==e&&(c="4K");(e=a.frameRate)&&(50<=e||20>=e)&&(c+=Math.round(a.frameRate));if("PQ"==a.hdr||"HLG"==a.hdr)c+=" (HDR)";"CH-STEREO"==a.videoLayout&&(c+=" (3D)");b.some(function(f){return f!=a&&f.height==a.height})&&(c+=" ("+Math.round((a.videoBandwidth||a.bandwidth)/1E3)+" kbits/s)");return c}
1681
- function gH(a){var b=a.player.dd()?"QUALITY":"RESOLUTION";a.button.ariaLabel=a.localization.resolve(b);a.backButton.ariaLabel=a.localization.resolve(b);a.backSpan.textContent=a.localization.resolve(b);a.nameSpan.textContent=a.localization.resolve(b);a.g.textContent=a.localization.resolve("AUTO_QUALITY");a.player.getConfiguration().abr.enabled&&(a.currentSelection.textContent=a.localization.resolve("AUTO_QUALITY"))}P("shaka.ui.ResolutionSelection",fH);function jH(){}
1682
- jH.prototype.create=function(a,b){return new fH(a,b)};JF("quality",new jH);gF("quality",new jH);function kH(a,b){RD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("material-icons-round");this.g.classList.add("shaka-rewind-button");this.g.classList.add("shaka-tooltip-status");this.g.setAttribute("shaka-status",this.localization.resolve("OFF"));this.g.textContent="fast_rewind";this.parent.appendChild(this.g);lH(this);this.h=this.controls.g.rewindRates;this.eventManager.s(this.localization,"locale-updated",function(){lH(c)});this.eventManager.s(this.localization,"locale-changed",function(){lH(c)});
1683
- this.eventManager.s(this.g,"click",function(){if(c.video.duration){var d=c.h.indexOf(c.player.Ra())+1;d=d!=c.h.length?c.h[d]:c.h[0];c.player.Mc(d);c.g.setAttribute("shaka-status",d+"x")}})}na(kH,RD);function lH(a){a.g.ariaLabel=a.localization.resolve("REWIND")}P("shaka.ui.RewindButton",kH);function mH(){}mH.prototype.create=function(a,b){return new kH(a,b)};gF("rewind",new mH);function nH(a,b){aE.call(this,a,b);this.button.classList.add("shaka-small-play-button");this.button.classList.add("material-icons-round");this.button.classList.add("shaka-tooltip");this.h();this.g()}na(nH,aE);nH.prototype.h=function(){this.isEnded()?this.button.textContent="replay":this.button.textContent=this.isPaused()?"play_arrow":"pause"};
1684
- nH.prototype.g=function(){if(this.isEnded())this.button.ariaLabel=this.localization.resolve("REPLAY");else{var a=this.isPaused()?"PLAY":"PAUSE";this.button.ariaLabel=this.localization.resolve(a)}};P("shaka.ui.SmallPlayButton",nH);function oH(){}oH.prototype.create=function(a,b){return new nH(a,b)};gF("play_pause",new oH);function pH(a,b){RD.call(this,a,b);a=W("div");a.classList.add("shaka-spacer");a.ariaHidden="true";this.parent.appendChild(a)}na(pH,RD);P("shaka.ui.Spacer",pH);function qH(){}qH.prototype.create=function(a,b){return new pH(a,b)};gF("spacer",new qH);function rH(a,b){function c(k){return XD(h.g[k],!1)+" (m)"}function d(k){return Math.round(h.g[k]/1E3)+" (kbits/s)"}function e(k){return h.g[k].toFixed(2)+" (s)"}function f(k){return h.g[k]+" (frames)"}function g(k){return h.g[k]+" (px)"}RD.call(this,a,b);var h=this;this.i=en();this.i.classList.add("shaka-statistics-button");this.j=W("i");this.j.classList.add("material-icons-round");this.j.textContent="insert_chart_outlined";this.i.appendChild(this.j);a=W("label");a.classList.add("shaka-overflow-button-label");
1632
+ function UF(){var a,b,c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,C,y;return O(function(B){switch(B.g){case 1:Pz();if(!ro())return VF("shaka-ui-load-failed",WF),B.return();a=document.querySelectorAll("[data-shaka-player-container]");b=document.querySelectorAll("[data-shaka-player]");c=document.querySelectorAll("[data-shaka-player-canvas]");d=document.querySelectorAll("[data-shaka-player-vr-canvas]");if(!b.length&&!a.length){B.B(2);break}if(b.length&&!a.length){e=t(b);for(f=e.next();!f.done;f=e.next())g=f.value,
1633
+ g.ui||(h=document.createElement("div"),k=g.parentElement,k.replaceChild(h,g),h.appendChild(g),l=XF(h,c,d),m=l.Ph,n=l.xi,YF(h,g,m,n));B.B(2);break}p=t(a);r=p.next();case 4:if(r.done){B.B(2);break}u=r.value;if(u.ui){B.B(5);break}v=null;w=t(b);for(f=w.next();!f.done;f=w.next())if(A=f.value,A.parentElement==u){v=A;break}v||(v=document.createElement("video"),v.setAttribute("playsinline",""),u.appendChild(v));z=XF(u,c,d);C=z.Ph;y=z.xi;ta(B,7);return E(B,YF(u,v,C,y),9);case 9:va(B,5);break;case 7:return wa(B),
1634
+ VF("shaka-ui-load-failed",ZF),B.return();case 5:r=p.next();B.B(4);break;case 2:VF("shaka-ui-loaded"),F(B)}})}function VF(a,b){var c=null;void 0!=b&&(c={reasonCode:b});a=new CustomEvent(a,{detail:c});document.dispatchEvent(a)}
1635
+ function YF(a,b,c,d){var e,f,g,h,k,l,m,n,p;return O(function(r){switch(r.g){case 1:e=new X;f=new RF(e,a,b,d);e.qh(c);g="";h=!1;a.dataset&&a.dataset.shakaPlayerCastReceiverId?(g=a.dataset.shakaPlayerCastReceiverId,h="true"===a.dataset.shakaPlayerCastAndroidReceiverCompatible):b.dataset&&b.dataset.shakaPlayerCastReceiverId&&(g=b.dataset.shakaPlayerCastReceiverId,h="true"===b.dataset.shakaPlayerCastAndroidReceiverCompatible);g.length&&f.configure({castReceiverAppId:g,castAndroidReceiverCompatible:h});
1636
+ b.controls&&f.g.di(!0);if(k=b.getAttribute("src"))l=document.createElement("source"),l.setAttribute("src",k),b.appendChild(l),b.removeAttribute("src");m=t(b.querySelectorAll("source"));n=m.next();case 2:if(n.done){r.B(4);break}p=n.value;ta(r,5);return E(r,f.g.bd().load(p.getAttribute("src")),7);case 7:r.B(4);break;case 5:wa(r);case 3:n=m.next();r.B(2);break;case 4:return E(r,e.vc(b),0)}})}
1637
+ function XF(a,b,c){var d=null,e=t(b);for(b=e.next();!b.done;b=e.next())if(b=b.value,b.parentElement==a){d=b;break}d||(d=document.createElement("canvas"),d.classList.add("shaka-canvas-container"),a.appendChild(d));e=null;c=t(c);for(b=c.next();!b.done;b=c.next())if(b=b.value,b.parentElement==a){e=b;break}e||(e=document.createElement("canvas"),e.classList.add("shaka-vr-canvas-container"),a.appendChild(e));return{Ph:d,xi:e}}P("shaka.ui.Overlay",RF);RF.prototype.setEnabled=RF.prototype.xk;
1638
+ RF.prototype.getControls=RF.prototype.Xi;RF.prototype.configure=RF.prototype.configure;RF.prototype.getConfiguration=RF.prototype.getConfiguration;RF.prototype.isMobile=RF.prototype.Bg;RF.prototype.destroy=RF.prototype.destroy;var TF=0;RF.TrackLabelFormat={LANGUAGE:TF,ROLE:1,LANGUAGE_ROLE:2,LABEL:3};var WF=0,ZF=1;RF.FailReasonCode={NO_BROWSER_SUPPORT:WF,PLAYER_FAILED_TO_LOAD:ZF};
1639
+ "complete"==document.readyState?O(function(a){if(1==a.g)return E(a,Promise.resolve(),2);UF();F(a)}):window.addEventListener("load",UF);function $F(a,b,c,d,e,f,g,h){function k(K){var G="";5<=K&&(G=" "+f.resolve("SURROUND"));return G}function l(K,G,J,I){K=[K,G];h&&null!=I&&K.push(I);J&&3==g&&K.push(J);return K.join(": ")}function m(K){return"variant"==K.type?K.audioRoles?K.audioRoles.join(", "):void 0:K.roles.join(", ")}var n=a.find(function(K){return 1==K.active}),p=TD(b);fn(b);b.appendChild(p);p=new Map;for(var r=t(a),u=r.next();!u.done;u=r.next())u=u.value,p.has(u.language)||p.set(u.language,new Set),p.get(u.language).add(m(u));
1640
+ p=new Set;n=n?l(n.language,m(n),n.label,n.channelsCount):"";r={};a=t(a);for(u=a.next();!u.done;r={Kb:r.Kb},u=a.next()){r.Kb=u.value;u=r.Kb.language;var v=r.Kb.forced,w=f.resolve("SUBTITLE_FORCED"),A=m(r.Kb),z=r.Kb.label,C=r.Kb.channelsCount,y=l(u,A,z,C);if(!p.has(y)){p.add(y);var B=en();B.addEventListener("click",function(K){return function(){c(K.Kb)}}(r));var D=W("span");B.appendChild(D);D.textContent=aG(u,f);switch(g){case TF:h&&(D.textContent+=k(C));v&&(D.textContent+=" ("+w+")");break;case 1:h&&
1641
+ (D.textContent+=k(C));A?D.textContent=A:(Ya("Track #"+r.Kb.id+" does not have a role, but the UI is configured to only show role."),D.textContent="?");v&&(D.textContent+=" ("+w+")");break;case 2:h&&(D.textContent+=k(C));A&&(D.textContent+=": "+A);v&&(D.textContent+=" ("+w+")");break;case 3:z?D.textContent=z:(Ya("Track #"+r.Kb.id+" does not have a label, but the UI is configured to only show labels."),D.textContent="?")}d&&y==n&&(B.appendChild(WD()),D.classList.add("shaka-chosen-item"),B.ariaSelected=
1642
+ "true",e.textContent=D.textContent);b.appendChild(B)}}}function aG(a,b){if(!a&&!b)return"";switch(a){case "mul":return b.resolve("MULTIPLE_LANGUAGES");case "und":return b.resolve("UNDETERMINED_LANGUAGE");case "zxx":return b.resolve("NOT_APPLICABLE")}var c=dd(a);return a in OD?OD[a].C:c in OD?OD[c].C+" ("+a+")":b.resolve("UNRECOGNIZED_LANGUAGE")+" ("+a+")"};function bG(a,b,c){SD.call(this,a,b);var d=this;cG(this,c);dG(this);eG(this);this.eventManager.s(this.button,"click",function(){d.menu.classList.contains("shaka-hidden")?(d.controls.dispatchEvent(new S("submenuopen")),XD(d.menu,!0),VD(d.menu)):XD(d.menu,!1)})}na(bG,SD);
1643
+ function cG(a,b){a.button=en();a.button.classList.add("shaka-overflow-button");a.icon=W("i");a.icon.classList.add("material-icons-round");a.icon.textContent=b;a.button.appendChild(a.icon);b=W("label");b.classList.add("shaka-overflow-button-label");b.classList.add("shaka-overflow-menu-only");a.nameSpan=W("span");b.appendChild(a.nameSpan);a.currentSelection=W("span");a.currentSelection.classList.add("shaka-current-selection-span");b.appendChild(a.currentSelection);a.button.appendChild(b);a.parent.appendChild(a.button)}
1644
+ function dG(a){a.menu=W("div");a.menu.classList.add("shaka-no-propagation");a.menu.classList.add("shaka-show-controls-on-mouse-over");a.menu.classList.add("shaka-settings-menu");a.menu.classList.add("shaka-hidden");a.backButton=en();a.backButton.classList.add("shaka-back-to-overflow-button");a.menu.appendChild(a.backButton);a.eventManager.s(a.backButton,"click",function(){a.controls.Cc()});var b=W("i");b.classList.add("material-icons-round");b.textContent="close";a.backButton.appendChild(b);a.backSpan=
1645
+ W("span");a.backButton.appendChild(a.backSpan);a.controls.h.appendChild(a.menu)}function eG(a){a.parent.classList.contains("shaka-overflow-menu")&&(a.backButton.firstChild.textContent="arrow_back",a.eventManager.s(a.backButton,"click",function(){function b(c){return 0==c.classList.contains("shaka-hidden")}XD(a.parent,!0);jb(a.parent.childNodes,b)&&kb(a.parent.childNodes,b)[0].focus();bF(a.controls)}))}P("shaka.ui.SettingsMenu",bG);function fG(a,b){bG.call(this,a,b,"language");var c=this;this.button.classList.add("shaka-language-button");this.button.classList.add("shaka-tooltip-status");this.menu.classList.add("shaka-audio-languages");this.eventManager.s(this.localization,"locale-updated",function(){gG(c)});this.eventManager.s(this.localization,"locale-changed",function(){gG(c)});this.eventManager.s(this.player,"loading",function(){hG(c)});this.eventManager.s(this.player,"trackschanged",function(){hG(c)});this.eventManager.s(this.player,
1646
+ "variantchanged",function(){iG(c)});gG(this);iG(this)}na(fG,bG);
1647
+ function iG(a){var b=a.player.Db();$F(b,a.menu,function(c){c.channelsCount&&a.controls.g.showAudioChannelCountVariants?a.player.lf(c.language,c.roles[0],c.channelsCount):a.player.lf(c.language,c.roles[0])},!0,a.currentSelection,a.localization,a.controls.g.trackLabelFormat,a.controls.g.showAudioChannelCountVariants);VD(a.menu);a.controls.dispatchEvent(new S("languageselectionupdated"));a.button.setAttribute("shaka-status",a.currentSelection.innerText);XD(a.button,2<a.menu.getElementsByTagName("button").length)}
1648
+ function hG(a){var b=0<a.player.Db().length;XD(a.button,b);iG(a)}function gG(a){a.backButton.ariaLabel=a.localization.resolve("BACK");a.button.ariaLabel=a.localization.resolve("LANGUAGE");a.nameSpan.textContent=a.localization.resolve("LANGUAGE");a.backSpan.textContent=a.localization.resolve("LANGUAGE")}P("shaka.ui.AudioLanguageSelection",fG);function jG(){}jG.prototype.create=function(a,b){return new fG(a,b)};KF("language",new jG);hF("language",new jG);function kG(a,b){SD.call(this,a,b);var c=this;this.h=this.controls.F;this.g=en();this.g.classList.add("shaka-cast-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.i=W("i");this.i.classList.add("material-icons-round");this.i.textContent="cast";this.g.appendChild(this.i);a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.l=W("span");a.appendChild(this.l);this.j=W("span");this.j.classList.add("shaka-current-selection-span");
1649
+ a.appendChild(this.j);this.g.appendChild(a);this.parent.appendChild(this.g);lG(this);mG(this);this.eventManager.s(this.localization,"locale-updated",function(){lG(c)});this.eventManager.s(this.localization,"locale-changed",function(){lG(c)});this.eventManager.s(this.g,"click",function(){nG(c)});this.eventManager.s(this.controls,"caststatuschanged",function(){mG(c)})}na(kG,SD);
1650
+ function nG(a){var b;O(function(c){if(1==c.g){if(a.h.Oa())return a.h.ni(),c.B(0);ta(c,3);a.g.disabled=!0;return E(c,a.h.cast(),5)}if(3!=c.g)return a.g.disabled=!1,va(c,0);b=wa(c);a.g.disabled=!1;8004!=b.code&&a.controls.dispatchEvent(new S("error",(new Map).set("detail",b)));F(c)})}function mG(a){var b=a.h.Uf()&&a.controls.na,c=a.h.Oa();XD(a.g,b);a.i.textContent=c?"cast_connected":"cast";b&&(a.g.ariaPressed=c?"true":"false");oG(a)}
1651
+ function oG(a){a.j.textContent=a.h.Oa()?a.h.hf():a.localization.resolve("OFF")}function lG(a){a.g.ariaLabel=a.localization.resolve("CAST");a.l.textContent=a.localization.resolve("CAST");oG(a)}P("shaka.ui.CastButton",kG);function pG(){}pG.prototype.create=function(a,b){return new kG(a,b)};KF("cast",new pG);hF("cast",new pG);function qG(a,b){SD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("material-icons-round");this.g.classList.add("shaka-fast-forward-button");this.g.classList.add("shaka-tooltip-status");this.g.setAttribute("shaka-status","1x");this.g.textContent="fast_forward";this.parent.appendChild(this.g);rG(this);this.h=this.controls.g.fastForwardRates;this.eventManager.s(this.localization,"locale-updated",function(){rG(c)});this.eventManager.s(this.localization,"locale-changed",function(){rG(c)});
1652
+ this.eventManager.s(this.g,"click",function(){if(c.video.duration){var d=c.h.indexOf(c.player.Ra())+1;d=d!=c.h.length?c.h[d]:c.h[0];c.player.Nc(d);c.g.setAttribute("shaka-status",d+"x")}})}na(qG,SD);function rG(a){a.g.ariaLabel=a.localization.resolve("FAST_FORWARD")}P("shaka.ui.FastForwardButton",qG);function sG(){}sG.prototype.create=function(a,b){return new qG(a,b)};hF("fast_forward",new sG);function tG(a,b){SD.call(this,a,b);var c=this;this.h=this.controls.o;this.g=en();this.g.classList.add("shaka-fullscreen-button");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");uG(this);this.g.textContent="fullscreen";this.parent.appendChild(this.g);vG(this);this.eventManager.s(this.localization,"locale-updated",function(){vG(c)});this.eventManager.s(this.localization,"locale-changed",function(){vG(c)});this.eventManager.s(this.g,"click",function(){return O(function(d){return E(d,
1653
+ c.controls.qf(),0)})});this.eventManager.s(document,"fullscreenchange",function(){c.g.textContent=c.controls.fd()?"fullscreen_exit":"fullscreen";vG(c)});this.eventManager.s(this.h,"loadedmetadata",function(){uG(c)});this.eventManager.s(this.h,"loadeddata",function(){uG(c)})}na(tG,SD);function uG(a){a.controls.Xd()?a.g.classList.remove("shaka-hidden"):a.g.classList.add("shaka-hidden")}function vG(a){a.g.ariaLabel=a.localization.resolve(a.controls.fd()?"EXIT_FULL_SCREEN":"FULL_SCREEN")}
1654
+ P("shaka.ui.FullscreenButton",tG);function wG(){}wG.prototype.create=function(a,b){return new tG(a,b)};hF("fullscreen",new wG);function xG(a,b){SD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-loop-button");this.g.classList.add("shaka-tooltip");this.i=W("i");this.i.classList.add("material-icons-round");this.i.textContent="repeat";this.g.appendChild(this.i);a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=W("span");this.j.textContent=this.localization.resolve("LOOP");a.appendChild(this.j);this.l=W("span");this.l.classList.add("shaka-current-selection-span");
1655
+ a.appendChild(this.l);this.g.appendChild(a);yG(this);this.parent.appendChild(this.g);this.eventManager.s(this.localization,"locale-updated",function(){yG(c)});this.eventManager.s(this.localization,"locale-changed",function(){yG(c)});this.eventManager.s(this.g,"click",function(){c.video.loop=!c.video.loop;c.h.Pa();c.h.za(1)});this.m=this.video.loop;this.h=new Ub(function(){c.m!=c.video.loop&&(yG(c),c.m=c.video.loop)});this.h.za(1)}na(xG,SD);
1656
+ xG.prototype.release=function(){this.h.stop();this.h=null;SD.prototype.release.call(this)};function yG(a){a.j.textContent=a.localization.resolve("LOOP");a.l.textContent=a.localization.resolve(a.video.loop?"ON":"OFF");a.i.textContent=a.video.loop?"repeat_on":"repeat";a.g.ariaLabel=a.localization.resolve(a.video.loop?"EXIT_LOOP_MODE":"ENTER_LOOP_MODE")}P("shaka.ui.LoopButton",xG);function zG(){}zG.prototype.create=function(a,b){return new xG(a,b)};KF("loop",new zG);hF("loop",new zG);hE("loop",new zG);function AG(a,b){SD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-mute-button");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");this.parent.appendChild(this.g);BG(this);CG(this);this.eventManager.s(this.localization,"locale-updated",function(){BG(c)});this.eventManager.s(this.localization,"locale-changed",function(){BG(c)});this.eventManager.s(this.g,"click",function(){c.ad&&c.ad.isLinear()?c.ad.setMuted(!c.ad.isMuted()):c.video.muted=!c.video.muted});
1657
+ this.eventManager.s(this.video,"volumechange",function(){BG(c);CG(c)});this.eventManager.s(this.adManager,"ad-volume-changed",function(){BG(c);CG(c)});this.eventManager.s(this.adManager,"ad-muted",function(){BG(c);CG(c)});this.eventManager.s(this.adManager,"ad-stopped",function(){c.ad=null;BG(c);CG(c)})}na(AG,SD);function BG(a){var b=a.ad?a.ad.isMuted()?"UNMUTE":"MUTE":a.video.muted?"UNMUTE":"MUTE";a.g.ariaLabel=a.localization.resolve(b)}
1658
+ function CG(a){var b=a.ad?a.ad.isMuted()?"volume_off":"volume_up":a.video.muted?"volume_off":"volume_up";a.g.textContent=b}P("shaka.ui.MuteButton",AG);function DG(){}DG.prototype.create=function(a,b){return new AG(a,b)};hF("mute",new DG);function EG(a,b){SD.call(this,a,b);var c=this;this.l=this.controls.o;this.g=en();this.g.classList.add("shaka-pip-button");this.g.classList.add("shaka-tooltip");this.i=W("i");this.i.classList.add("material-icons-round");this.i.textContent="picture_in_picture_alt";this.g.appendChild(this.i);a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=W("span");this.j.textContent=this.localization.resolve("PICTURE_IN_PICTURE");a.appendChild(this.j);this.h=
1659
+ W("span");this.h.classList.add("shaka-current-selection-span");a.appendChild(this.h);this.g.appendChild(a);FG(this);this.parent.appendChild(this.g);this.controls.Re()||XD(this.g,!1);this.eventManager.s(this.localization,"locale-updated",function(){FG(c)});this.eventManager.s(this.localization,"locale-changed",function(){FG(c)});this.eventManager.s(this.g,"click",function(){c.controls.me()});this.eventManager.s(this.l,"enterpictureinpicture",function(){GG(c)});this.eventManager.s(this.l,"leavepictureinpicture",
1660
+ function(){HG(c)});this.eventManager.s(this.controls,"caststatuschanged",function(){IG(c)});this.eventManager.s(this.player,"trackschanged",function(){IG(c)});"documentPictureInPicture"in window&&this.eventManager.s(window.documentPictureInPicture,"enter",function(d){GG(c);c.eventManager.oa(d.window,"pagehide",function(){HG(c)})})}na(EG,SD);
1661
+ function GG(a){a.i.textContent="branding_watermark";a.g.ariaLabel=a.localization.resolve("EXIT_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve("ON")}function HG(a){a.i.textContent="picture_in_picture_alt";a.g.ariaLabel=a.localization.resolve("ENTER_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve("OFF")}
1662
+ function FG(a){a.j.textContent=a.localization.resolve("PICTURE_IN_PICTURE");var b=a.controls.Se();a.g.ariaLabel=a.localization.resolve(b?"EXIT_PICTURE_IN_PICTURE":"ENTER_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve(b?"ON":"OFF")}function IG(a){O(function(b){if(!a.controls.Re())return XD(a.g,!1),a.controls.Se()?E(b,a.controls.me(),0):b.B(0);if(!a.player||!a.player.ed())return XD(a.g,!0),b.B(0);XD(a.g,!1);return a.controls.Se()?E(b,a.controls.me(),0):b.B(0)})}P("shaka.ui.PipButton",EG);
1663
+ function JG(){}JG.prototype.create=function(a,b){return new EG(a,b)};KF("picture_in_picture",new JG);hF("picture_in_picture",new JG);hE("picture_in_picture",new JG);function KG(a,b){bG.call(this,a,b,"slow_motion_video");var c=this;this.button.classList.add("shaka-playbackrate-button");this.menu.classList.add("shaka-playback-rates");this.button.classList.add("shaka-tooltip-status");this.eventManager.s(this.localization,"locale-updated",function(){LG(c)});this.eventManager.s(this.localization,"locale-changed",function(){LG(c)});this.eventManager.s(this.player,"loaded",function(){MG(c,c.player.Ra())});this.eventManager.s(this.player,"ratechange",function(){MG(c,
1664
+ c.player.Ra())});this.g=new Map(this.controls.g.playbackRates.map(function(d){return[d+"x",d]}));LG(this);VG(this);MG(this,this.player.Ra())}na(KG,bG);function LG(a){a.backButton.ariaLabel=a.localization.resolve("BACK");a.button.ariaLabel=a.localization.resolve("PLAYBACK_RATE");a.nameSpan.textContent=a.localization.resolve("PLAYBACK_RATE");a.backSpan.textContent=a.localization.resolve("PLAYBACK_RATE")}
1665
+ function MG(a,b){var c=UD(a.menu,"material-icons-round shaka-chosen-item");if(c){var d=c.parentElement;d.removeAttribute("aria-selected");d.getElementsByTagName("span")[0].classList.remove("shaka-chosen-item");d.removeChild(c)}if(c=Array.from(a.menu.querySelectorAll("span")).find(function(e){return a.g.get(e.textContent)==b}))d=c.parentElement,d.appendChild(WD()),d.ariaSelected="true",c.classList.add("shaka-chosen-item");a.currentSelection.textContent=b+"x";a.button.setAttribute("shaka-status",b+
1666
+ "x")}function VG(a){for(var b={},c=t(a.g.keys()),d=c.next();!d.done;b={yd:b.yd},d=c.next()){b.yd=d.value;d=en();var e=W("span");e.textContent=b.yd;d.appendChild(e);a.eventManager.s(d,"click",function(f){return function(){a.video.playbackRate=a.g.get(f.yd);a.video.defaultPlaybackRate=a.g.get(f.yd)}}(b));a.menu.appendChild(d)}VD(a.menu)}P("shaka.ui.PlaybackRateSelection",KG);function WG(){}WG.prototype.create=function(a,b){return new KG(a,b)};KF("playback_rate",new WG);hF("playback_rate",new WG);function XG(a,b){SD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-current-time");YG(this,"0:00");this.parent.appendChild(this.g);this.eventManager.s(this.g,"click",function(){c.player.U()&&(c.video.currentTime=c.player.Ta().end)});this.eventManager.s(this.player,"loading",function(){XD(c.g,!0)});this.eventManager.s(this.controls,"timeandseekrangeupdated",function(){var d=c.controls.$,e=c.controls.qg(),f=c.player.Ta(),g=f.end-f.start;c.player.U()?(e=Math.max(0,Math.floor(f.end-
1667
+ e)),g=3600<=g,1<=e||d?(YG(c,"- "+YD(e,g)),c.g.disabled=!1):(YG(c,c.localization.resolve("LIVE")),c.g.disabled=!0)):(d=3600<=g,e=YD(Math.max(0,e-f.start),d),g&&(e+=" / "+YD(g,d)),YG(c,e),c.g.disabled=!0)});this.eventManager.s(this.player,"trackschanged",function(){c.player.U()&&(c.g.ariaLabel=c.localization.resolve("SKIP_TO_LIVE"))});this.eventManager.s(this.adManager,"ad-started",function(){XD(c.g,!1)});this.eventManager.s(this.adManager,"ad-stopped",function(){XD(c.g,!0)})}na(XG,SD);
1668
+ function YG(a,b){b!=a.g.textContent&&(a.g.textContent=b)}P("shaka.ui.PresentationTimeTracker",XG);function ZG(){}ZG.prototype.create=function(a,b){return new XG(a,b)};hF("time_and_duration",new ZG);function $G(a,b){SD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-recenter-vr-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.h=W("i");this.h.classList.add("material-icons-round");this.h.textContent="control_camera";this.g.appendChild(this.h);a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=W("span");a.appendChild(this.j);this.i=W("span");this.i.classList.add("shaka-current-selection-span");
1669
+ a.appendChild(this.i);this.g.appendChild(a);this.parent.appendChild(this.g);aH(this);this.eventManager.s(this.localization,"locale-updated",function(){aH(c)});this.eventManager.s(this.localization,"locale-changed",function(){aH(c)});var d=this.controls.u;this.eventManager.s(this.g,"click",function(){d.g?TE(d.g):Ya("Not playing VR content")});this.eventManager.s(d,"vrstatuschanged",function(){XD(c.g,c.controls.Qb())});XD(this.g,this.controls.Qb())}na($G,SD);
1670
+ function aH(a){a.g.ariaLabel=a.localization.resolve("RECENTER_VR");a.j.textContent=a.localization.resolve("RECENTER_VR")}P("shaka.ui.RecenterVRButton",$G);function bH(){}bH.prototype.create=function(a,b){return new $G(a,b)};KF("recenter_vr",new bH);hF("recenter_vr",new bH);function cH(a,b){SD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-remote-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.i=W("i");this.i.classList.add("material-icons-round");a="cast";(b=mc())&&13<=b&&(a="airplay");this.i.textContent=a;this.g.appendChild(this.i);a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.l=W("span");a.appendChild(this.l);this.j=W("span");this.j.classList.add("shaka-current-selection-span");
1671
+ a.appendChild(this.j);this.g.appendChild(a);this.parent.appendChild(this.g);this.h=-1;dH(this);XD(this.g,!1);!this.video.remote||this.video.disableRemotePlayback?this.g.classList.add("shaka-hidden"):(this.eventManager.s(this.localization,"locale-updated",function(){dH(c)}),this.eventManager.s(this.localization,"locale-changed",function(){dH(c)}),this.eventManager.s(this.controls,"caststatuschanged",function(){eH(c)}),this.eventManager.s(this.g,"click",function(){c.video.remote.prompt()}),this.eventManager.s(this.video.remote,
1672
+ "connect",function(){eH(c)}),this.eventManager.s(this.video.remote,"connecting",function(){eH(c)}),this.eventManager.s(this.video.remote,"disconnect",function(){eH(c)}),this.eventManager.s(this.player,"loaded",function(){eH(c)}),eH(this))}na(cH,SD);cH.prototype.release=function(){this.video.remote&&-1!=this.h&&this.video.remote.cancelWatchAvailability(this.h).catch(function(){});SD.prototype.release.call(this)};
1673
+ function eH(a){var b,c;O(function(d){switch(d.g){case 1:if(a.controls.F.Uf()&&a.controls.na){XD(a.g,!1);-1!=a.h&&(a.video.remote.cancelWatchAvailability(a.h),a.h=-1);d.B(0);break}if("disconnected"==a.video.remote.state){b=function(e){a.player?XD(a.g,a.player.Qd()==fp&&e):XD(a.g,!1)};ta(d,7);if(-1==a.h){d.B(9);break}return E(d,a.video.remote.cancelWatchAvailability(a.h),10)}if(-1==a.h){d.B(0);break}return E(d,a.video.remote.cancelWatchAvailability(a.h),6);case 6:a.h=-1;d.B(0);break;case 10:a.h=-1;
1674
+ case 9:va(d,8);break;case 7:wa(d);case 8:return ta(d,11),E(d,a.video.remote.watchAvailability(b),13);case 13:c=d.h;a.h=c;va(d,0);break;case 11:wa(d),b(!0),F(d)}})}function dH(a){var b=a.localization.resolve("CAST"),c=mc();c&&13<=c&&(b=a.localization.resolve("AIRPLAY"));a.g.ariaLabel=b;a.l.textContent=b}P("shaka.ui.RemoteButton",cH);function fH(){}fH.prototype.create=function(a,b){return new cH(a,b)};KF("remote",new fH);hF("remote",new fH);function gH(a,b){bG.call(this,a,b,"settings");var c=this;this.button.classList.add("shaka-resolution-button");this.button.classList.add("shaka-tooltip-status");this.menu.classList.add("shaka-resolutions");this.eventManager.s(this.localization,"locale-updated",function(){hH(c)});this.eventManager.s(this.localization,"locale-changed",function(){hH(c)});this.eventManager.s(this.player,"loading",function(){iH(c)});this.eventManager.s(this.player,"variantchanged",function(){iH(c)});this.eventManager.s(this.player,
1675
+ "trackschanged",function(){iH(c)});this.eventManager.s(this.player,"abrstatuschanged",function(){iH(c)});iH(this)}na(gH,bG);
1676
+ function iH(a){var b=[];a.player.Qd()!=fp&&(b=a.player.Db());var c=b.find(function(k){return k.active});c&&(b=b.filter(function(k){if(k.language!=c.language||a.controls.g.showAudioChannelCountVariants&&k.channelsCount!=c.channelsCount)return!1;var l=a.controls.g.trackLabelFormat;return(1==l||2==l)&&JSON.stringify(k.audioRoles)!=JSON.stringify(c.audioRoles)||3==l&&k.label!=c.label?!1:!0}));b=a.player.ed()?b.filter(function(k,l){return b.findIndex(function(m){return m.bandwidth==k.bandwidth})==l}):
1677
+ 1<[].concat(x(new Set(b.map(function(k){return k.audioId})))).length?b.filter(function(k,l){return b.findIndex(function(m){return m.height==k.height&&m.videoBandwidth==k.videoBandwidth&&m.frameRate==k.frameRate&&m.hdr==k.hdr&&m.videoLayout==k.videoLayout})==l}):b.filter(function(k,l){return b.findIndex(function(m){return m.height==k.height&&m.bandwidth==k.bandwidth&&m.frameRate==k.frameRate&&m.hdr==k.hdr&&m.videoLayout==k.videoLayout})==l});a.player.ed()?b.sort(function(k,l){return l.bandwidth-k.bandwidth}):
1678
+ b.sort(function(k,l){return l.height==k.height?l.bandwidth-k.bandwidth:l.height-k.height});var d=TD(a.menu);fn(a.menu);a.menu.appendChild(d);d=a.player.getConfiguration().abr.enabled;for(var e={},f=t(b),g=f.next();!g.done;e={Tb:e.Tb},g=f.next()){e.Tb=g.value;g=en();g.classList.add("explicit-resolution");a.eventManager.s(g,"click",function(k){return function(){var l=k.Tb;a.player.configure({abr:{enabled:!1}});a.player.mf(l,a.controls.g.clearBufferOnQualityChange)}}(e));var h=W("span");h.textContent=
1679
+ a.player.ed()&&e.Tb.bandwidth?Math.round(e.Tb.bandwidth/1E3)+" kbits/s":e.Tb.height&&e.Tb.width?jH(e.Tb,b):"Unknown";g.appendChild(h);d||e.Tb!=c||(g.ariaSelected="true",g.appendChild(WD()),h.classList.add("shaka-chosen-item"),a.currentSelection.textContent=h.textContent);a.menu.appendChild(g)}e=en();e.classList.add("shaka-enable-abr-button");a.eventManager.s(e,"click",function(){a.player.configure({abr:{enabled:!0}});iH(a)});a.g=W("span");a.g.classList.add("shaka-auto-span");a.g.textContent=a.localization.resolve("AUTO_QUALITY");
1680
+ e.appendChild(a.g);d&&(e.ariaSelected="true",e.appendChild(WD()),a.g.classList.add("shaka-chosen-item"),a.currentSelection.textContent=a.localization.resolve("AUTO_QUALITY"));a.button.setAttribute("shaka-status",a.currentSelection.textContent);a.menu.appendChild(e);VD(a.menu);a.controls.dispatchEvent(new S("resolutionselectionupdated"));hH(a);XD(a.button,1<b.length)}
1681
+ function jH(a,b){var c=a.height||0,d=a.width||0,e=c;d/c>16/9&&(e=Math.round(9*d/16));c=e+"p";2160==e&&(c="4K");(e=a.frameRate)&&(50<=e||20>=e)&&(c+=Math.round(a.frameRate));if("PQ"==a.hdr||"HLG"==a.hdr)c+=" (HDR)";"CH-STEREO"==a.videoLayout&&(c+=" (3D)");b.some(function(f){return f!=a&&f.height==a.height})&&(c+=" ("+Math.round((a.videoBandwidth||a.bandwidth)/1E3)+" kbits/s)");return c}
1682
+ function hH(a){var b=a.player.ed()?"QUALITY":"RESOLUTION";a.button.ariaLabel=a.localization.resolve(b);a.backButton.ariaLabel=a.localization.resolve(b);a.backSpan.textContent=a.localization.resolve(b);a.nameSpan.textContent=a.localization.resolve(b);a.g.textContent=a.localization.resolve("AUTO_QUALITY");a.player.getConfiguration().abr.enabled&&(a.currentSelection.textContent=a.localization.resolve("AUTO_QUALITY"))}P("shaka.ui.ResolutionSelection",gH);function kH(){}
1683
+ kH.prototype.create=function(a,b){return new gH(a,b)};KF("quality",new kH);hF("quality",new kH);function lH(a,b){SD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("material-icons-round");this.g.classList.add("shaka-rewind-button");this.g.classList.add("shaka-tooltip-status");this.g.setAttribute("shaka-status",this.localization.resolve("OFF"));this.g.textContent="fast_rewind";this.parent.appendChild(this.g);mH(this);this.h=this.controls.g.rewindRates;this.eventManager.s(this.localization,"locale-updated",function(){mH(c)});this.eventManager.s(this.localization,"locale-changed",function(){mH(c)});
1684
+ this.eventManager.s(this.g,"click",function(){if(c.video.duration){var d=c.h.indexOf(c.player.Ra())+1;d=d!=c.h.length?c.h[d]:c.h[0];c.player.Nc(d);c.g.setAttribute("shaka-status",d+"x")}})}na(lH,SD);function mH(a){a.g.ariaLabel=a.localization.resolve("REWIND")}P("shaka.ui.RewindButton",lH);function nH(){}nH.prototype.create=function(a,b){return new lH(a,b)};hF("rewind",new nH);function oH(a,b){bE.call(this,a,b);this.button.classList.add("shaka-small-play-button");this.button.classList.add("material-icons-round");this.button.classList.add("shaka-tooltip");this.h();this.g()}na(oH,bE);oH.prototype.h=function(){this.isEnded()?this.button.textContent="replay":this.button.textContent=this.isPaused()?"play_arrow":"pause"};
1685
+ oH.prototype.g=function(){if(this.isEnded())this.button.ariaLabel=this.localization.resolve("REPLAY");else{var a=this.isPaused()?"PLAY":"PAUSE";this.button.ariaLabel=this.localization.resolve(a)}};P("shaka.ui.SmallPlayButton",oH);function pH(){}pH.prototype.create=function(a,b){return new oH(a,b)};hF("play_pause",new pH);function qH(a,b){SD.call(this,a,b);a=W("div");a.classList.add("shaka-spacer");a.ariaHidden="true";this.parent.appendChild(a)}na(qH,SD);P("shaka.ui.Spacer",qH);function rH(){}rH.prototype.create=function(a,b){return new qH(a,b)};hF("spacer",new rH);function sH(a,b){function c(k){return YD(h.g[k],!1)+" (m)"}function d(k){return Math.round(h.g[k]/1E3)+" (kbits/s)"}function e(k){return h.g[k].toFixed(2)+" (s)"}function f(k){return h.g[k]+" (frames)"}function g(k){return h.g[k]+" (px)"}SD.call(this,a,b);var h=this;this.i=en();this.i.classList.add("shaka-statistics-button");this.j=W("i");this.j.classList.add("material-icons-round");this.j.textContent="insert_chart_outlined";this.i.appendChild(this.j);a=W("label");a.classList.add("shaka-overflow-button-label");
1685
1686
  this.o=W("span");a.appendChild(this.o);this.m=W("span");this.m.classList.add("shaka-current-selection-span");a.appendChild(this.m);this.i.appendChild(a);this.parent.appendChild(this.i);this.h=W("div");this.h.classList.add("shaka-no-propagation");this.h.classList.add("shaka-show-controls-on-mouse-over");this.h.classList.add("shaka-statistics-container");this.h.classList.add("shaka-hidden");this.controls.h.appendChild(this.h);this.F=[];this.G=["stateHistory","switchHistory"];this.g=this.player.getStats();
1686
1687
  this.u={};this.A={width:g,height:g,completionPercent:function(k){return h.g[k]+" (%)"},bufferingTime:e,drmTimeSeconds:e,licenseTime:e,liveLatency:e,loadLatency:e,manifestTimeSeconds:e,estimatedBandwidth:d,streamBandwidth:d,maxSegmentDuration:c,pauseTime:c,playTime:c,corruptedFrames:f,decodedFrames:f,droppedFrames:f,stallsDetected:function(k){return h.g[k]+" (stalls)"},gapsJumped:function(k){return h.g[k]+" (gaps)"},bytesDownloaded:function(k){k=parseInt(h.g[k],10);return 1E6<k?(k/1E6).toFixed(2)+
1687
- "MB":1E3<k?(k/1E3).toFixed(2)+"KB":k+"B"}};this.l=new Ub(function(){h.g=h.player.getStats();for(var k=t(h.F),l=k.next();!l.done;l=k.next()){l=l.value;var m=h.u[l];m.textContent=h.A[l](l);m&&m.parentElement&&WD(m.parentElement,!isNaN(h.g[l]))}});sH(this);tH(this);this.eventManager.s(this.localization,"locale-updated",function(){sH(h)});this.eventManager.s(this.localization,"locale-changed",function(){sH(h)});this.eventManager.s(this.i,"click",function(){WD(h.parent,!1);h.h.classList.contains("shaka-hidden")?
1688
- (h.j.textContent="insert_chart",h.l.za(.1),WD(h.h,!0)):(h.j.textContent="insert_chart_outlined",h.l.stop(),WD(h.h,!1));sH(h)})}na(rH,RD);function sH(a){a.o.textContent=a.localization.resolve("STATISTICS");a.i.ariaLabel=a.localization.resolve("STATISTICS");a.m.textContent=a.localization.resolve(a.h.classList.contains("shaka-hidden")?"OFF":"ON")}
1689
- function tH(a){for(var b=t(a.controls.g.statisticsList),c=b.next();!c.done;c=b.next())if(c=c.value,c in a.g&&!a.G.includes(c)){var d=a,e=W("div"),f=W("label");f.textContent=c+":";e.appendChild(f);f=W("span");f.textContent=d.A[c](c);e.appendChild(f);d.u[c]=f;d=e;a.h.appendChild(d);a.F.push(c);WD(d.parentElement,!isNaN(a.g[c]))}else Ya("Unrecognized statistic element:",c)}rH.prototype.release=function(){this.l.stop();this.l=null;RD.prototype.release.call(this)};P("shaka.ui.StatisticsButton",rH);
1690
- function uH(){}uH.prototype.create=function(a,b){return new rH(a,b)};JF("statistics",new uH);gE("statistics",new uH);function vH(a,b){aG.call(this,a,b,"closed_caption");var c=this;this.button.classList.add("shaka-caption-button");this.button.classList.add("shaka-tooltip-status");this.menu.classList.add("shaka-text-languages");this.player&&this.player.Fc()?this.button.ariaPressed="true":this.button.ariaPressed="false";wH(this);this.eventManager.s(this.localization,"locale-updated",function(){xH(c);yH(c)});this.eventManager.s(this.localization,"locale-changed",function(){xH(c);yH(c)});this.eventManager.s(this.player,
1691
- "loading",function(){zH(c)});this.eventManager.s(this.player,"texttrackvisibility",function(){AH(c);yH(c)});this.eventManager.s(this.player,"textchanged",function(){yH(c)});this.eventManager.s(this.player,"trackschanged",function(){zH(c)});AH(this);xH(this);yH(this);zH(this)}na(vH,aG);function wH(a){var b=en();b.ariaSelected="true";a.menu.appendChild(b);b.appendChild(VD());a.g=W("span");a.g.classList.add("shaka-auto-span");b.appendChild(a.g)}
1692
- function AH(a){a.player.Fc()?(a.icon.textContent="closed_caption",a.button.ariaPressed="true"):(a.icon.textContent="closed_caption_disabled",a.button.ariaPressed="false");a.controls.dispatchEvent(new S("captionselectionupdated"))}
1693
- function yH(a){var b=a.player.jc();ZF(b,a.menu,function(c){return BH(a,c)},a.player.Fc(),a.currentSelection,a.localization,a.controls.g.textTrackLabelFormat,a.controls.g.showAudioChannelCountVariants);b=en();b.classList.add("shaka-turn-captions-off-button");a.eventManager.s(b,"click",function(){a.player.pf(!1);yH(a)});b.appendChild(a.g);a.menu.appendChild(b);a.player.Fc()||(b.ariaSelected="true",b.appendChild(VD()),a.g.classList.add("shaka-chosen-item"),a.currentSelection.textContent=a.localization.resolve("OFF"));
1694
- a.button.setAttribute("shaka-status",a.currentSelection.textContent);UD(a.menu);a.controls.dispatchEvent(new S("captionselectionupdated"))}function BH(a,b){return O(function(c){a.player.Vg(b);return E(c,a.player.pf(!0),0)})}
1695
- function xH(a){a.button.ariaLabel=a.localization.resolve("CAPTIONS");a.backButton.ariaLabel=a.localization.resolve("BACK");a.nameSpan.textContent=a.localization.resolve("CAPTIONS");a.backSpan.textContent=a.localization.resolve("CAPTIONS");a.g.textContent=a.localization.resolve("OFF")}function zH(a){var b=0<a.player.jc().length;WD(a.button,b);yH(a)}P("shaka.ui.TextSelection",vH);function CH(){}CH.prototype.create=function(a,b){return new vH(a,b)};JF("captions",new CH);gF("captions",new CH);function DH(a,b){RD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-toggle-stereoscopic-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.h=W("i");this.h.classList.add("material-icons-round");this.h.textContent="3d_rotation";this.g.appendChild(this.h);a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=W("span");a.appendChild(this.j);this.i=W("span");this.i.classList.add("shaka-current-selection-span");
1696
- a.appendChild(this.i);this.g.appendChild(a);this.parent.appendChild(this.g);EH(this);this.eventManager.s(this.localization,"locale-updated",function(){EH(c)});this.eventManager.s(this.localization,"locale-changed",function(){EH(c)});var d=this.controls.u;this.eventManager.s(this.g,"click",function(){d.qd()});this.eventManager.s(d,"vrstatuschanged",function(){WD(c.g,c.controls.Qb())});WD(this.g,this.controls.Qb())}na(DH,RD);
1697
- function EH(a){a.g.ariaLabel=a.localization.resolve("TOGGLE_STEREOSCOPIC");a.j.textContent=a.localization.resolve("TOGGLE_STEREOSCOPIC")}P("shaka.ui.ToggleStereoscopicButton",DH);function FH(){}FH.prototype.create=function(a,b){return new DH(a,b)};JF("toggle_stereoscopic",new FH);gF("toggle_stereoscopic",new FH);function GH(a,b){lE.call(this,a,b,["shaka-volume-bar-container"],["shaka-volume-bar"]);var c=this;this.g=this.controls.g;this.setRange(0,100);this.eventManager.s(this.video,"volumechange",function(){return HH(c)});this.eventManager.s(this.adManager,"ad-volume-changed",function(){return IH(c)});this.eventManager.s(this.adManager,"ad-muted",function(){return IH(c)});this.eventManager.s(this.adManager,"ad-stopped",function(){return HH(c)});this.eventManager.s(this.localization,"locale-updated",function(){return JH(c)});
1698
- this.eventManager.s(this.localization,"locale-changed",function(){return JH(c)});HH(this);JH(this);if(this.ad)this.onChange()}na(GH,lE);GH.prototype.onChange=function(){this.ad&&this.ad.isLinear()?this.ad.setVolume(this.getValue()/100):(this.video.volume=this.getValue()/100,this.video.muted=0==this.video.volume?!0:!1)};function HH(a){a.video.muted?a.setValue(0):a.setValue(100*a.video.volume);KH(a)}function IH(a){var b=a.ad.getVolume();a.setValue(100*b);KH(a)}
1699
- function KH(a){var b=a.g.volumeBarColors,c=["to right"];c.push(b.level+a.getValue()+"%");c.push(b.base+a.getValue()+"%");c.push(b.base+"100%");a.container.style.background="linear-gradient("+c.join(",")+")"}function JH(a){a.bar.ariaLabel=a.localization.resolve("VOLUME")}P("shaka.ui.VolumeBar",GH);function LH(){}LH.prototype.create=function(a,b){return new GH(a,b)};gF("volume",new LH);}).call(exportTo,innerGlobal,innerGlobal,undefined);if(typeof exports!="undefined")for(var k in exportTo.shaka)exports[k]=exportTo.shaka[k];else if(typeof define=="function"&&define.amd)define(function(){return exportTo.shaka});else innerGlobal.shaka=exportTo.shaka})();
1688
+ "MB":1E3<k?(k/1E3).toFixed(2)+"KB":k+"B"}};this.l=new Ub(function(){h.g=h.player.getStats();for(var k=t(h.F),l=k.next();!l.done;l=k.next()){l=l.value;var m=h.u[l];m.textContent=h.A[l](l);m&&m.parentElement&&XD(m.parentElement,!isNaN(h.g[l]))}});tH(this);uH(this);this.eventManager.s(this.localization,"locale-updated",function(){tH(h)});this.eventManager.s(this.localization,"locale-changed",function(){tH(h)});this.eventManager.s(this.i,"click",function(){XD(h.parent,!1);h.h.classList.contains("shaka-hidden")?
1689
+ (h.j.textContent="insert_chart",h.l.za(.1),XD(h.h,!0)):(h.j.textContent="insert_chart_outlined",h.l.stop(),XD(h.h,!1));tH(h)})}na(sH,SD);function tH(a){a.o.textContent=a.localization.resolve("STATISTICS");a.i.ariaLabel=a.localization.resolve("STATISTICS");a.m.textContent=a.localization.resolve(a.h.classList.contains("shaka-hidden")?"OFF":"ON")}
1690
+ function uH(a){for(var b=t(a.controls.g.statisticsList),c=b.next();!c.done;c=b.next())if(c=c.value,c in a.g&&!a.G.includes(c)){var d=a,e=W("div"),f=W("label");f.textContent=c+":";e.appendChild(f);f=W("span");f.textContent=d.A[c](c);e.appendChild(f);d.u[c]=f;d=e;a.h.appendChild(d);a.F.push(c);XD(d.parentElement,!isNaN(a.g[c]))}else Ya("Unrecognized statistic element:",c)}sH.prototype.release=function(){this.l.stop();this.l=null;SD.prototype.release.call(this)};P("shaka.ui.StatisticsButton",sH);
1691
+ function vH(){}vH.prototype.create=function(a,b){return new sH(a,b)};KF("statistics",new vH);hE("statistics",new vH);function wH(a,b){bG.call(this,a,b,"closed_caption");var c=this;this.button.classList.add("shaka-caption-button");this.button.classList.add("shaka-tooltip-status");this.menu.classList.add("shaka-text-languages");this.player&&this.player.Gc()?this.button.ariaPressed="true":this.button.ariaPressed="false";xH(this);this.eventManager.s(this.localization,"locale-updated",function(){yH(c);zH(c)});this.eventManager.s(this.localization,"locale-changed",function(){yH(c);zH(c)});this.eventManager.s(this.player,
1692
+ "loading",function(){AH(c)});this.eventManager.s(this.player,"texttrackvisibility",function(){BH(c);zH(c)});this.eventManager.s(this.player,"textchanged",function(){zH(c)});this.eventManager.s(this.player,"trackschanged",function(){AH(c)});BH(this);yH(this);zH(this);AH(this)}na(wH,bG);function xH(a){var b=en();b.ariaSelected="true";a.menu.appendChild(b);b.appendChild(WD());a.g=W("span");a.g.classList.add("shaka-auto-span");b.appendChild(a.g)}
1693
+ function BH(a){a.player.Gc()?(a.icon.textContent="closed_caption",a.button.ariaPressed="true"):(a.icon.textContent="closed_caption_disabled",a.button.ariaPressed="false");a.controls.dispatchEvent(new S("captionselectionupdated"))}
1694
+ function zH(a){var b=a.player.kc();$F(b,a.menu,function(c){return CH(a,c)},a.player.Gc(),a.currentSelection,a.localization,a.controls.g.textTrackLabelFormat,a.controls.g.showAudioChannelCountVariants);b=en();b.classList.add("shaka-turn-captions-off-button");a.eventManager.s(b,"click",function(){a.player.pf(!1);zH(a)});b.appendChild(a.g);a.menu.appendChild(b);a.player.Gc()||(b.ariaSelected="true",b.appendChild(WD()),a.g.classList.add("shaka-chosen-item"),a.currentSelection.textContent=a.localization.resolve("OFF"));
1695
+ a.button.setAttribute("shaka-status",a.currentSelection.textContent);VD(a.menu);a.controls.dispatchEvent(new S("captionselectionupdated"))}function CH(a,b){return O(function(c){a.player.Vg(b);return E(c,a.player.pf(!0),0)})}
1696
+ function yH(a){a.button.ariaLabel=a.localization.resolve("CAPTIONS");a.backButton.ariaLabel=a.localization.resolve("BACK");a.nameSpan.textContent=a.localization.resolve("CAPTIONS");a.backSpan.textContent=a.localization.resolve("CAPTIONS");a.g.textContent=a.localization.resolve("OFF")}function AH(a){var b=0<a.player.kc().length;XD(a.button,b);zH(a)}P("shaka.ui.TextSelection",wH);function DH(){}DH.prototype.create=function(a,b){return new wH(a,b)};KF("captions",new DH);hF("captions",new DH);function EH(a,b){SD.call(this,a,b);var c=this;this.g=en();this.g.classList.add("shaka-toggle-stereoscopic-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.h=W("i");this.h.classList.add("material-icons-round");this.h.textContent="3d_rotation";this.g.appendChild(this.h);a=W("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=W("span");a.appendChild(this.j);this.i=W("span");this.i.classList.add("shaka-current-selection-span");
1697
+ a.appendChild(this.i);this.g.appendChild(a);this.parent.appendChild(this.g);FH(this);this.eventManager.s(this.localization,"locale-updated",function(){FH(c)});this.eventManager.s(this.localization,"locale-changed",function(){FH(c)});var d=this.controls.u;this.eventManager.s(this.g,"click",function(){d.qd()});this.eventManager.s(d,"vrstatuschanged",function(){XD(c.g,c.controls.Qb())});XD(this.g,this.controls.Qb())}na(EH,SD);
1698
+ function FH(a){a.g.ariaLabel=a.localization.resolve("TOGGLE_STEREOSCOPIC");a.j.textContent=a.localization.resolve("TOGGLE_STEREOSCOPIC")}P("shaka.ui.ToggleStereoscopicButton",EH);function GH(){}GH.prototype.create=function(a,b){return new EH(a,b)};KF("toggle_stereoscopic",new GH);hF("toggle_stereoscopic",new GH);function HH(a,b){mE.call(this,a,b,["shaka-volume-bar-container"],["shaka-volume-bar"]);var c=this;this.g=this.controls.g;this.setRange(0,100);this.eventManager.s(this.video,"volumechange",function(){return IH(c)});this.eventManager.s(this.adManager,"ad-volume-changed",function(){return JH(c)});this.eventManager.s(this.adManager,"ad-muted",function(){return JH(c)});this.eventManager.s(this.adManager,"ad-stopped",function(){return IH(c)});this.eventManager.s(this.localization,"locale-updated",function(){return KH(c)});
1699
+ this.eventManager.s(this.localization,"locale-changed",function(){return KH(c)});IH(this);KH(this);if(this.ad)this.onChange()}na(HH,mE);HH.prototype.onChange=function(){this.ad&&this.ad.isLinear()?this.ad.setVolume(this.getValue()/100):(this.video.volume=this.getValue()/100,this.video.muted=0==this.video.volume?!0:!1)};function IH(a){a.video.muted?a.setValue(0):a.setValue(100*a.video.volume);LH(a)}function JH(a){var b=a.ad.getVolume();a.setValue(100*b);LH(a)}
1700
+ function LH(a){var b=a.g.volumeBarColors,c=["to right"];c.push(b.level+a.getValue()+"%");c.push(b.base+a.getValue()+"%");c.push(b.base+"100%");a.container.style.background="linear-gradient("+c.join(",")+")"}function KH(a){a.bar.ariaLabel=a.localization.resolve("VOLUME")}P("shaka.ui.VolumeBar",HH);function MH(){}MH.prototype.create=function(a,b){return new HH(a,b)};hF("volume",new MH);}).call(exportTo,innerGlobal,innerGlobal,undefined);if(typeof exports!="undefined")for(var k in exportTo.shaka)exports[k]=exportTo.shaka[k];else if(typeof define=="function"&&define.amd)define(function(){return exportTo.shaka});else innerGlobal.shaka=exportTo.shaka})();
1700
1701
 
1701
1702
  //# sourceMappingURL=shaka-player.ui.map