shaka-player 4.10.13 → 4.10.15

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.
Files changed (65) hide show
  1. package/dist/controls.css +3 -3
  2. package/dist/controls.css.map +1 -1
  3. package/dist/locales.js +187 -48
  4. package/dist/shaka-player.compiled.debug.js +225 -225
  5. package/dist/shaka-player.compiled.debug.map +2 -2
  6. package/dist/shaka-player.compiled.js +681 -680
  7. package/dist/shaka-player.compiled.map +3 -3
  8. package/dist/shaka-player.ui.debug.js +390 -377
  9. package/dist/shaka-player.ui.debug.map +3 -3
  10. package/dist/shaka-player.ui.js +853 -839
  11. package/dist/shaka-player.ui.map +3 -3
  12. package/externs/ima.js +22 -2
  13. package/lib/media/streaming_engine.js +3 -3
  14. package/lib/player.js +1 -1
  15. package/lib/text/simple_text_displayer.js +1 -1
  16. package/lib/text/text_utils.js +12 -3
  17. package/lib/text/ttml_text_parser.js +2 -1
  18. package/lib/text/ui_text_displayer.js +0 -4
  19. package/package.json +1 -1
  20. package/ui/less/containers.less +3 -4
  21. package/ui/less/overflow_menu.less +1 -0
  22. package/ui/less/tooltip.less +1 -1
  23. package/ui/locales/ar-XB.json +11 -0
  24. package/ui/locales/ar.json +11 -0
  25. package/ui/locales/bg.json +11 -0
  26. package/ui/locales/ca.json +11 -0
  27. package/ui/locales/cs.json +11 -0
  28. package/ui/locales/da.json +11 -0
  29. package/ui/locales/de.json +13 -2
  30. package/ui/locales/el.json +11 -0
  31. package/ui/locales/en-GB.json +10 -1
  32. package/ui/locales/en-XA.json +12 -1
  33. package/ui/locales/es-419.json +5 -0
  34. package/ui/locales/es.json +1 -0
  35. package/ui/locales/fa.json +15 -4
  36. package/ui/locales/fi.json +11 -0
  37. package/ui/locales/fil.json +11 -0
  38. package/ui/locales/fr.json +3 -3
  39. package/ui/locales/hi.json +11 -0
  40. package/ui/locales/hr.json +11 -0
  41. package/ui/locales/hu.json +12 -1
  42. package/ui/locales/id.json +11 -0
  43. package/ui/locales/it.json +11 -0
  44. package/ui/locales/iw.json +13 -2
  45. package/ui/locales/ja.json +11 -0
  46. package/ui/locales/ko.json +11 -0
  47. package/ui/locales/lt.json +11 -0
  48. package/ui/locales/lv.json +12 -1
  49. package/ui/locales/nl.json +13 -2
  50. package/ui/locales/no.json +11 -0
  51. package/ui/locales/pl.json +8 -7
  52. package/ui/locales/pt-BR.json +1 -0
  53. package/ui/locales/pt-PT.json +1 -0
  54. package/ui/locales/ro.json +11 -0
  55. package/ui/locales/ru.json +11 -0
  56. package/ui/locales/sk.json +11 -0
  57. package/ui/locales/sl.json +11 -0
  58. package/ui/locales/sr.json +11 -0
  59. package/ui/locales/sv.json +11 -0
  60. package/ui/locales/th.json +12 -1
  61. package/ui/locales/tr.json +11 -0
  62. package/ui/locales/uk.json +12 -1
  63. package/ui/locales/vi.json +13 -2
  64. package/ui/locales/zh-TW.json +11 -0
  65. package/ui/locales/zh.json +12 -1
@@ -9,7 +9,7 @@
9
9
  Copyright The Closure Library Authors.
10
10
  SPDX-License-Identifier: Apache-2.0
11
11
  */
12
- var r;function aa(a){var b=0;return function(){return b<a.length?{done:!1,value:a[b++]}:{done:!0}}}var ba="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(a==Array.prototype||a==Object.prototype)return a;a[b]=c.value;return a};
12
+ var q;function aa(a){var b=0;return function(){return b<a.length?{done:!1,value:a[b++]}:{done:!0}}}var ba="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(a==Array.prototype||a==Object.prototype)return a;a[b]=c.value;return a};
13
13
  function ca(a){a=["object"==typeof globalThis&&globalThis,a,"object"==typeof window&&window,"object"==typeof self&&self,"object"==typeof global&&global];for(var b=0;b<a.length;++b){var c=a[b];if(c&&c.Math==Math)return c}throw Error("Cannot find global object");}var da=ca(this);function ea(a,b){if(b)a:{var c=da;a=a.split(".");for(var d=0;d<a.length-1;d++){var e=a[d];if(!(e in c))break a;c=c[e]}a=a[a.length-1];d=c[a];b=b(d);b!=d&&null!=b&&ba(c,a,{configurable:!0,writable:!0,value:b})}}
14
14
  ea("Symbol",function(a){function b(f){if(this instanceof b)throw new TypeError("Symbol is not a constructor");return new c(d+(f||"")+"_"+e++,f)}function c(f,g){this.g=f;ba(this,"description",{configurable:!0,writable:!0,value:g})}if(a)return a;c.prototype.toString=function(){return this.g};var d="jscomp_symbol_"+(1E9*Math.random()>>>0)+"_",e=0;return b});
15
15
  ea("Symbol.iterator",function(a){if(a)return a;a=Symbol("Symbol.iterator");for(var b="Array Int8Array Uint8Array Uint8ClampedArray Int16Array Uint16Array Int32Array Uint32Array Float32Array Float64Array".split(" "),c=0;c<b.length;c++){var d=da[b[c]];"function"===typeof d&&"function"!=typeof d.prototype[a]&&ba(d.prototype,a,{configurable:!0,writable:!0,value:function(){return fa(aa(this))}})}return a});function fa(a){a={next:a};a[Symbol.iterator]=function(){return this};return a}
@@ -25,8 +25,8 @@ ea("Promise",function(a){function b(g){this.h=0;this.i=void 0;this.g=[];this.o=!
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.F),reject:g(this.l)}};b.prototype.F=function(g){if(g===this)this.l(new TypeError("A Promise cannot resolve to itself"));else if(g instanceof b)this.H(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.C(g):this.m(g)}};
26
26
  b.prototype.C=function(g){var h=void 0;try{h=g.then}catch(k){this.l(k);return}"function"==typeof h?this.I(h,g):this.m(g)};b.prototype.l=function(g){this.s(2,g)};b.prototype.m=function(g){this.s(1,g)};b.prototype.s=function(g,h){if(0!=this.h)throw Error("Cannot settle("+g+", "+h+"): Promise already settled in state"+this.h);this.h=g;this.i=h;2===this.h&&this.G();this.A()};b.prototype.G=function(){var g=this;e(function(){if(g.B()){var h=da.console;"undefined"!==typeof h&&h.error(g.i)}},1)};b.prototype.B=
27
27
  function(){if(this.o)return!1;var g=da.CustomEvent,h=da.Event,k=da.dispatchEvent;if("undefined"===typeof k)return!0;"function"===typeof g?g=new g("unhandledrejection",{cancelable:!0}):"function"===typeof h?g=new h("unhandledrejection",{cancelable:!0}):(g=da.document.createEvent("CustomEvent"),g.initCustomEvent("unhandledrejection",!1,!0,g));g.promise=this;g.reason=this.i;return k(g)};b.prototype.A=function(){if(null!=this.g){for(var g=0;g<this.g.length;++g)f.h(this.g[g]);this.g=null}};var f=new c;
28
- b.prototype.H=function(g){var h=this.j();g.Bd(h.resolve,h.reject)};b.prototype.I=function(g,h){var k=this.j();try{g.call(h,k.resolve,k.reject)}catch(l){k.reject(l)}};b.prototype.then=function(g,h){function k(q,p){return"function"==typeof q?function(w){try{l(q(w))}catch(u){m(u)}}:p}var l,m,n=new b(function(q,p){l=q;m=p});this.Bd(k(g,l),k(h,m));return n};b.prototype.catch=function(g){return this.then(void 0,g)};b.prototype.Bd=function(g,h){function k(){switch(l.h){case 1:g(l.i);break;case 2:h(l.i);
29
- break;default:throw Error("Unexpected state: "+l.h);}}var l=this;null==this.g?f.h(k):this.g.push(k);this.o=!0};b.resolve=d;b.reject=function(g){return new b(function(h,k){k(g)})};b.race=function(g){return new b(function(h,k){for(var l=t(g),m=l.next();!m.done;m=l.next())d(m.value).Bd(h,k)})};b.all=function(g){var h=t(g),k=h.next();return k.done?d([]):new b(function(l,m){function n(w){return function(u){q[w]=u;p--;0==p&&l(q)}}var q=[],p=0;do q.push(void 0),p++,d(k.value).Bd(n(q.length-1),m),k=h.next();
28
+ b.prototype.H=function(g){var h=this.j();g.Bd(h.resolve,h.reject)};b.prototype.I=function(g,h){var k=this.j();try{g.call(h,k.resolve,k.reject)}catch(l){k.reject(l)}};b.prototype.then=function(g,h){function k(p,r){return"function"==typeof p?function(u){try{l(p(u))}catch(v){m(v)}}:r}var l,m,n=new b(function(p,r){l=p;m=r});this.Bd(k(g,l),k(h,m));return n};b.prototype.catch=function(g){return this.then(void 0,g)};b.prototype.Bd=function(g,h){function k(){switch(l.h){case 1:g(l.i);break;case 2:h(l.i);
29
+ break;default:throw Error("Unexpected state: "+l.h);}}var l=this;null==this.g?f.h(k):this.g.push(k);this.o=!0};b.resolve=d;b.reject=function(g){return new b(function(h,k){k(g)})};b.race=function(g){return new b(function(h,k){for(var l=t(g),m=l.next();!m.done;m=l.next())d(m.value).Bd(h,k)})};b.all=function(g){var h=t(g),k=h.next();return k.done?d([]):new b(function(l,m){function n(u){return function(v){p[u]=v;r--;0==r&&l(p)}}var p=[],r=0;do p.push(void 0),r++,d(k.value).Bd(n(p.length-1),m),k=h.next();
30
30
  while(!k.done)})};return b});function Ja(a,b){return Object.prototype.hasOwnProperty.call(a,b)}
31
31
  ea("WeakMap",function(a){function b(k){this.g=(h+=Math.random()+1).toString();if(k){k=t(k);for(var l;!(l=k.next()).done;)l=l.value,this.set(l[0],l[1])}}function c(){}function d(k){var l=typeof k;return"object"===l&&null!==k||"function"===l}function e(k){if(!Ja(k,g)){var l=new c;ba(k,g,{value:l})}}function f(k){var l=Object[k];l&&(Object[k]=function(m){if(m instanceof c)return m;Object.isExtensible(m)&&e(m);return l(m)})}if(function(){if(!a||!Object.seal)return!1;try{var k=Object.seal({}),l=Object.seal({}),
32
32
  m=new a([[k,2],[l,3]]);if(2!=m.get(k)||3!=m.get(l))return!1;m.delete(k);m.set(l,4);return!m.has(k)&&4==m.get(l)}catch(n){return!1}}())return a;var g="$jscomp_hidden_"+Math.random();f("freeze");f("preventExtensions");f("seal");var h=0;b.prototype.set=function(k,l){if(!d(k))throw Error("Invalid WeakMap key");e(k);if(!Ja(k,g))throw Error("WeakMap key fail: "+k);k[g][this.g]=l;return this};b.prototype.get=function(k){return d(k)&&Ja(k,g)?k[g][this.g]:void 0};b.prototype.has=function(k){return d(k)&&Ja(k,
@@ -56,8 +56,8 @@ function S(a,b){a=a.split(".");var c=Oa;a[0]in c||"undefined"==typeof c.execScri
56
56
  Copyright 2016 Google LLC
57
57
  SPDX-License-Identifier: Apache-2.0
58
58
  */
59
- function Pa(){}function Qa(){};function Sa(a){this.g=Math.exp(Math.log(.5)/a);this.i=this.h=0}Sa.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 Ua(a){return a.h/(1-Math.pow(a.g,a.i))};function Va(){this.h=new Sa(2);this.j=new Sa(5);this.g=0;this.i=128E3;this.l=16E3}Va.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)};Va.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)}};Va.prototype.getBandwidthEstimate=function(a){return this.g<this.i?a:Math.min(Ua(this.h),Ua(this.j))};function Wa(){}function Xa(){}function Ya(){}function $a(a){var b=Ia.apply(1,arguments);ab.has(a)||(ab.add(a),Ya.apply(Wa,x(b)))}function cb(){}function db(){}function eb(){}var ab=new Set;window.console&&(Ya=function(){return console.warn.apply(console,x(Ia.apply(0,arguments)))},Xa=function(){console.error.apply(console,x(Ia.apply(0,arguments)))});function fb(){this.g={}}r=fb.prototype;r.push=function(a,b){this.g.hasOwnProperty(a)?this.g[a].push(b):this.g[a]=[b]};r.get=function(a){return(a=this.g[a])?a.slice():null};r.remove=function(a,b){a in this.g&&(this.g[a]=this.g[a].filter(function(c){return c!=b}),0==this.g[a].length&&delete this.g[a])};r.forEach=function(a){for(var b in this.g)a(b,this.g[b])};r.size=function(){return Object.keys(this.g).length};r.keys=function(){return Object.keys(this.g)};function gb(){this.g=new fb}r=gb.prototype;r.release=function(){this.Qa();this.g=null};r.D=function(a,b,c,d){this.g&&(a=new hb(a,b,c,d),this.g.push(b,a))};r.ja=function(a,b,c,d){function e(g){f.jb(a,b,e);c(g)}var f=this;this.D(a,b,e,d)};r.jb=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.jb(),this.g.remove(b,e))}};
60
- r.Qa=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.jb();this.g.g={}}};S("shaka.util.EventManager",gb);gb.prototype.removeAll=gb.prototype.Qa;gb.prototype.unlisten=gb.prototype.jb;gb.prototype.listenOnce=gb.prototype.ja;gb.prototype.listen=gb.prototype.D;gb.prototype.release=gb.prototype.release;function hb(a,b,c,d){this.target=a;this.type=b;this.listener=c;this.g=ib(a,d);this.target.addEventListener(b,c,this.g)}
59
+ function Pa(){}function Qa(){};function Sa(a){this.g=Math.exp(Math.log(.5)/a);this.i=this.h=0}Sa.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 Ua(a){return a.h/(1-Math.pow(a.g,a.i))};function Va(){this.h=new Sa(2);this.j=new Sa(5);this.g=0;this.i=128E3;this.l=16E3}Va.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)};Va.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)}};Va.prototype.getBandwidthEstimate=function(a){return this.g<this.i?a:Math.min(Ua(this.h),Ua(this.j))};function Wa(){}function Xa(){}function Ya(){}function $a(a){var b=Ia.apply(1,arguments);ab.has(a)||(ab.add(a),Ya.apply(Wa,x(b)))}function cb(){}function db(){}function eb(){}var ab=new Set;window.console&&(Ya=function(){return console.warn.apply(console,x(Ia.apply(0,arguments)))},Xa=function(){console.error.apply(console,x(Ia.apply(0,arguments)))});function fb(){this.g={}}q=fb.prototype;q.push=function(a,b){this.g.hasOwnProperty(a)?this.g[a].push(b):this.g[a]=[b]};q.get=function(a){return(a=this.g[a])?a.slice():null};q.remove=function(a,b){a in this.g&&(this.g[a]=this.g[a].filter(function(c){return c!=b}),0==this.g[a].length&&delete this.g[a])};q.forEach=function(a){for(var b in this.g)a(b,this.g[b])};q.size=function(){return Object.keys(this.g).length};q.keys=function(){return Object.keys(this.g)};function gb(){this.g=new fb}q=gb.prototype;q.release=function(){this.Qa();this.g=null};q.D=function(a,b,c,d){this.g&&(a=new hb(a,b,c,d),this.g.push(b,a))};q.ja=function(a,b,c,d){function e(g){f.jb(a,b,e);c(g)}var f=this;this.D(a,b,e,d)};q.jb=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.jb(),this.g.remove(b,e))}};
60
+ q.Qa=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.jb();this.g.g={}}};S("shaka.util.EventManager",gb);gb.prototype.removeAll=gb.prototype.Qa;gb.prototype.unlisten=gb.prototype.jb;gb.prototype.listenOnce=gb.prototype.ja;gb.prototype.listen=gb.prototype.D;gb.prototype.release=gb.prototype.release;function hb(a,b,c,d){this.target=a;this.type=b;this.listener=c;this.g=ib(a,d);this.target.addEventListener(b,c,this.g)}
61
61
  hb.prototype.jb=function(){this.target.removeEventListener(this.type,this.listener,this.g);this.listener=this.target=null;this.g=!1};function ib(a,b){if(void 0==b)return!1;if("boolean"==typeof b)return b;var c=new Set(["passive","capture"]);Object.keys(b).filter(function(d){return!c.has(d)});return jb(a)?b:b.capture||!1}
62
62
  function jb(a){var b=kb;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}kb=b}return b||!1}var kb=void 0;function mb(a){if(nb.has(a))return nb.get(a);if(window.ManagedMediaSource){var b=ManagedMediaSource.isTypeSupported(a);nb.set(a,b);return b}return window.MediaSource?(b=MediaSource.isTypeSupported(a),nb.set(a,b),b):!1}function ob(){return!!window.SourceBuffer&&!!SourceBuffer.prototype&&!!SourceBuffer.prototype.changeType}var nb=new Map;function pb(a,b){this.g=a;this.h=b}pb.prototype.toString=function(){return"v"+this.g+"."+this.h};function qb(a,b){var c=new pb(5,0),d=rb,e=d.g,f=c.h-e.h;(0<(c.g-e.g||f)?d.i:d.h)(d.g,c,a,b)}function sb(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 tb(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 rb=null;function ub(){}ub.prototype.extract=function(){};ub.prototype.decode=function(){return[]};ub.prototype.clear=function(){};ub.prototype.getStreams=function(){return[]};function vb(){}vb.prototype.init=function(){};vb.prototype.parse=function(){return[]};function wb(){}function xb(a,b){if(!a&&!b)return!0;if(!a||!b||a.byteLength!=b.byteLength)return!1;if(yb(a)==yb(b)&&(a.byteOffset||0)==(b.byteOffset||0))return!0;var c=zb(a);b=zb(b);for(var d=0;d<a.byteLength;d++)if(c[d]!=b[d])return!1;return!0}function yb(a){return a instanceof ArrayBuffer?a:a.buffer}function Ab(a){return a instanceof ArrayBuffer?a:0==a.byteOffset&&a.byteLength==a.buffer.byteLength?a.buffer:(new Uint8Array(a)).buffer}
63
63
  function zb(a,b,c){c=void 0===c?Infinity:c;return Cb(a,void 0===b?0:b,c,Uint8Array)}function Db(a,b,c){c=void 0===c?Infinity:c;return Cb(a,void 0===b?0:b,c,Uint16Array)}function Eb(a,b,c){c=void 0===c?Infinity:c;return Cb(a,void 0===b?0:b,c,DataView)}function Cb(a,b,c,d){var e=yb(a),f=1;"BYTES_PER_ELEMENT"in d&&(f=d.BYTES_PER_ELEMENT);var g=((a.byteOffset||0)+a.byteLength)/f;a=Math.floor(Math.max(0,Math.min(((a.byteOffset||0)+b)/f,g)));return new d(e,a,Math.floor(Math.min(a+Math.max(c,0),g))-a)}
@@ -79,14 +79,14 @@ var sc=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^/?#]*)@)?([^/#?]*?)(?::([0-9]+))?(?=
79
79
  Copyright 2006 The Closure Library Authors
80
80
  SPDX-License-Identifier: Apache-2.0
81
81
  */
82
- function tc(a){var b;a instanceof tc?(uc(this,a.Bb),this.vc=a.vc,vc(this,a.Eb),wc(this,a.Lc),this.Pa=a.Pa,xc(this,a.g.clone()),this.hc=a.hc):a&&(b=String(a).match(sc))?(uc(this,b[1]||"",!0),this.vc=yc(b[2]||""),vc(this,b[3]||"",!0),wc(this,b[4]),this.Pa=yc(b[5]||"",!0),xc(this,b[6]||"",!0),this.hc=yc(b[7]||"")):this.g=new zc(null)}r=tc.prototype;r.Bb="";r.vc="";r.Eb="";r.Lc=null;r.Pa="";r.hc="";
83
- r.toString=function(){var a=[],b=this.Bb;b&&a.push(Ac(b,Bc,!0),":");if(b=this.Eb){a.push("//");var c=this.vc;c&&a.push(Ac(c,Bc,!0),"@");a.push(encodeURIComponent(b).replace(/%25([0-9a-fA-F]{2})/g,"%$1"));b=this.Lc;null!=b&&a.push(":",String(b))}if(b=this.Pa)this.Eb&&"/"!=b.charAt(0)&&a.push("/"),a.push(Ac(b,"/"==b.charAt(0)?Cc:Dc,!0));(b=this.g.toString())&&a.push("?",b);(b=this.hc)&&a.push("#",Ac(b,Ec));return a.join("")};
84
- r.resolve=function(a){var b=this.clone();"data"===b.Bb&&(b=new tc);var c=!!a.Bb;c?uc(b,a.Bb):c=!!a.vc;c?b.vc=a.vc:c=!!a.Eb;c?vc(b,a.Eb):c=null!=a.Lc;var d=a.Pa;if(c)wc(b,a.Lc);else if(c=!!a.Pa){if("/"!=d.charAt(0))if(this.Eb&&!this.Pa)d="/"+d;else{var e=b.Pa.lastIndexOf("/");-1!=e&&(d=b.Pa.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(""):".."==
85
- 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.Pa=d:c=""!==a.g.toString();c?xc(b,a.g.clone()):c=!!a.hc;c&&(b.hc=a.hc);return b};r.clone=function(){return new tc(this)};function uc(a,b,c){a.Bb=c?yc(b,!0):b;a.Bb&&(a.Bb=a.Bb.replace(/:$/,""))}function vc(a,b,c){a.Eb=c?yc(b,!0):b}function wc(a,b){if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.Lc=b}else a.Lc=null}
82
+ function tc(a){var b;a instanceof tc?(uc(this,a.Bb),this.vc=a.vc,vc(this,a.Eb),wc(this,a.Mc),this.Pa=a.Pa,xc(this,a.g.clone()),this.hc=a.hc):a&&(b=String(a).match(sc))?(uc(this,b[1]||"",!0),this.vc=yc(b[2]||""),vc(this,b[3]||"",!0),wc(this,b[4]),this.Pa=yc(b[5]||"",!0),xc(this,b[6]||"",!0),this.hc=yc(b[7]||"")):this.g=new zc(null)}q=tc.prototype;q.Bb="";q.vc="";q.Eb="";q.Mc=null;q.Pa="";q.hc="";
83
+ q.toString=function(){var a=[],b=this.Bb;b&&a.push(Ac(b,Bc,!0),":");if(b=this.Eb){a.push("//");var c=this.vc;c&&a.push(Ac(c,Bc,!0),"@");a.push(encodeURIComponent(b).replace(/%25([0-9a-fA-F]{2})/g,"%$1"));b=this.Mc;null!=b&&a.push(":",String(b))}if(b=this.Pa)this.Eb&&"/"!=b.charAt(0)&&a.push("/"),a.push(Ac(b,"/"==b.charAt(0)?Cc:Dc,!0));(b=this.g.toString())&&a.push("?",b);(b=this.hc)&&a.push("#",Ac(b,Ec));return a.join("")};
84
+ q.resolve=function(a){var b=this.clone();"data"===b.Bb&&(b=new tc);var c=!!a.Bb;c?uc(b,a.Bb):c=!!a.vc;c?b.vc=a.vc:c=!!a.Eb;c?vc(b,a.Eb):c=null!=a.Mc;var d=a.Pa;if(c)wc(b,a.Mc);else if(c=!!a.Pa){if("/"!=d.charAt(0))if(this.Eb&&!this.Pa)d="/"+d;else{var e=b.Pa.lastIndexOf("/");-1!=e&&(d=b.Pa.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(""):".."==
85
+ 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.Pa=d:c=""!==a.g.toString();c?xc(b,a.g.clone()):c=!!a.hc;c&&(b.hc=a.hc);return b};q.clone=function(){return new tc(this)};function uc(a,b,c){a.Bb=c?yc(b,!0):b;a.Bb&&(a.Bb=a.Bb.replace(/:$/,""))}function vc(a,b,c){a.Eb=c?yc(b,!0):b}function wc(a,b){if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.Mc=b}else a.Mc=null}
86
86
  function xc(a,b,c){b instanceof zc?a.g=b:(c||(b=Ac(b,Fc)),a.g=new zc(b))}function yc(a,b){return a?b?decodeURI(a):decodeURIComponent(a):""}function Ac(a,b,c){return null!=a?(a=encodeURI(a).replace(b,Gc),c&&(a=a.replace(/%25([0-9a-fA-F]{2})/g,"%$1")),a):null}function Gc(a){a=a.charCodeAt(0);return"%"+(a>>4&15).toString(16)+(a&15).toString(16)}var Bc=/[#\/\?@]/g,Dc=/[#\?:]/g,Cc=/[#\?]/g,Fc=/[#\?@]/g,Ec=/#/g;function zc(a){this.g=a||null}
87
- function Hc(a){if(!a.Ia&&(a.Ia={},a.Wc=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," ")))}}r=zc.prototype;r.Ia=null;r.Wc=null;function Ic(a){Hc(a);return a.Wc}r.add=function(a,b){Hc(this);this.g=null;var c=this.Ia.hasOwnProperty(a)?this.Ia[a]:null;c||(this.Ia[a]=c=[]);c.push(b);this.Wc++;return this};
88
- r.set=function(a,b){Hc(this);this.g=null;this.Ia.hasOwnProperty(a)?this.Ia[a]=[b]:this.add(a,b);return this};r.get=function(a){Hc(this);return this.Ia[a]||[]};r.toString=function(){if(this.g)return this.g;if(!this.Ia)return"";var a=[],b;for(b in this.Ia)for(var c=encodeURIComponent(b),d=this.Ia[b],e=0;e<d.length;e++){var f=c;""!==d[e]&&(f+="="+encodeURIComponent(d[e]));a.push(f)}return this.g=a.join("&")};
89
- r.clone=function(){var a=new zc;a.g=this.g;if(this.Ia){var b={},c;for(c in this.Ia)b[c]=this.Ia[c].concat();a.Ia=b;a.Wc=this.Wc}return a};function T(a,b,c){var d=Ia.apply(3,arguments);this.severity=a;this.category=b;this.code=c;this.data=d;this.handled=!1;this.message="Shaka Error "+this.code;if(Jc)try{throw Error(this.message||"Shaka Error");}catch(e){this.stack=e.stack}}T.prototype.toString=function(){return"shaka.util.Error "+JSON.stringify(this,null," ")};S("shaka.util.Error",T);var Jc=!0;T.Severity={RECOVERABLE:1,CRITICAL:2};T.Category={NETWORK:1,TEXT:2,MEDIA:3,MANIFEST:4,STREAMING:5,DRM:6,PLAYER:7,CAST:8,STORAGE:9,ADS:10};
87
+ function Hc(a){if(!a.Ia&&(a.Ia={},a.Xc=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=zc.prototype;q.Ia=null;q.Xc=null;function Ic(a){Hc(a);return a.Xc}q.add=function(a,b){Hc(this);this.g=null;var c=this.Ia.hasOwnProperty(a)?this.Ia[a]:null;c||(this.Ia[a]=c=[]);c.push(b);this.Xc++;return this};
88
+ q.set=function(a,b){Hc(this);this.g=null;this.Ia.hasOwnProperty(a)?this.Ia[a]=[b]:this.add(a,b);return this};q.get=function(a){Hc(this);return this.Ia[a]||[]};q.toString=function(){if(this.g)return this.g;if(!this.Ia)return"";var a=[],b;for(b in this.Ia)for(var c=encodeURIComponent(b),d=this.Ia[b],e=0;e<d.length;e++){var f=c;""!==d[e]&&(f+="="+encodeURIComponent(d[e]));a.push(f)}return this.g=a.join("&")};
89
+ q.clone=function(){var a=new zc;a.g=this.g;if(this.Ia){var b={},c;for(c in this.Ia)b[c]=this.Ia[c].concat();a.Ia=b;a.Xc=this.Xc}return a};function T(a,b,c){var d=Ia.apply(3,arguments);this.severity=a;this.category=b;this.code=c;this.data=d;this.handled=!1;this.message="Shaka Error "+this.code;if(Jc)try{throw Error(this.message||"Shaka Error");}catch(e){this.stack=e.stack}}T.prototype.toString=function(){return"shaka.util.Error "+JSON.stringify(this,null," ")};S("shaka.util.Error",T);var Jc=!0;T.Severity={RECOVERABLE:1,CRITICAL:2};T.Category={NETWORK:1,TEXT:2,MEDIA:3,MANIFEST:4,STREAMING:5,DRM:6,PLAYER:7,CAST:8,STORAGE:9,ADS:10};
90
90
  T.Code={UNSUPPORTED_SCHEME:1E3,BAD_HTTP_STATUS:1001,HTTP_ERROR:1002,TIMEOUT:1003,MALFORMED_DATA_URI:1004,REQUEST_FILTER_ERROR:1006,RESPONSE_FILTER_ERROR:1007,MALFORMED_TEST_URI:1008,UNEXPECTED_TEST_REQUEST:1009,ATTEMPTS_EXHAUSTED:1010,SEGMENT_MISSING:1011,INVALID_TEXT_HEADER:2E3,INVALID_TEXT_CUE:2001,UNABLE_TO_DETECT_ENCODING:2003,BAD_ENCODING:2004,INVALID_XML:2005,INVALID_MP4_TTML:2007,INVALID_MP4_VTT:2008,UNABLE_TO_EXTRACT_CUE_START_TIME:2009,INVALID_MP4_CEA:2010,TEXT_COULD_NOT_GUESS_MIME_TYPE:2011,
91
91
  CANNOT_ADD_EXTERNAL_TEXT_TO_SRC_EQUALS:2012,TEXT_ONLY_WEBVTT_SRC_EQUALS:2013,MISSING_TEXT_PLUGIN:2014,CHAPTERS_TRACK_FAILED:2015,UNSUPPORTED_EXTERNAL_THUMBNAILS_URI:2017,BUFFER_READ_OUT_OF_BOUNDS:3E3,JS_INTEGER_OVERFLOW:3001,EBML_OVERFLOW:3002,EBML_BAD_FLOATING_POINT_SIZE:3003,MP4_SIDX_WRONG_BOX_TYPE:3004,MP4_SIDX_INVALID_TIMESCALE:3005,MP4_SIDX_TYPE_NOT_SUPPORTED:3006,WEBM_CUES_ELEMENT_MISSING:3007,WEBM_EBML_HEADER_ELEMENT_MISSING:3008,WEBM_SEGMENT_ELEMENT_MISSING:3009,WEBM_INFO_ELEMENT_MISSING:3010,
92
92
  WEBM_DURATION_ELEMENT_MISSING:3011,WEBM_CUE_TRACK_POSITIONS_ELEMENT_MISSING:3012,WEBM_CUE_TIME_ELEMENT_MISSING:3013,MEDIA_SOURCE_OPERATION_FAILED:3014,MEDIA_SOURCE_OPERATION_THREW:3015,VIDEO_ERROR:3016,QUOTA_EXCEEDED_ERROR:3017,TRANSMUXING_FAILED:3018,CONTENT_TRANSFORMATION_FAILED:3019,MSS_MISSING_DATA_FOR_TRANSMUXING:3020,MSS_TRANSMUXING_FAILED:3022,TRANSMUXING_NO_VIDEO_DATA:3023,UNABLE_TO_GUESS_MANIFEST_TYPE:4E3,DASH_INVALID_XML:4001,DASH_NO_SEGMENT_INFO:4002,DASH_EMPTY_ADAPTATION_SET:4003,DASH_EMPTY_PERIOD:4004,
@@ -104,12 +104,12 @@ function ed(){if(!Zc("Chrome")||navigator.userAgent.match(/Edge\//))return null;
104
104
  function hd(){return Zc("SOPOpenBrowser")}function ld(){if(!gd())return null;var a=navigator.userAgent.match(/Version\/(\d+)/);return a?parseInt(a[1],10):(a=navigator.userAgent.match(/OS (\d+)(?:_\d+)?/))?parseInt(a[1],10):null}function md(){return navigator.userAgentData&&navigator.userAgentData.platform?"windows"==navigator.userAgentData.platform.toLowerCase():navigator.platform?navigator.platform.toLowerCase().includes("windows"):!1}function nd(){return Zc("Android")}
105
105
  function od(){return $c()||cd()||Yc()||id()||jd()||Zc("AFT")||Zc("PC=EOS")||Zc("PC=APL")||Zc("VirginMedia")||hd()||Zc("WPE")||fd()||kd()||Zc("DT_STB_BCM")?!0:!1}function Zc(a){return(navigator.userAgent||"").includes(a)}function Vc(){if(pd)return pd;qd||(qd=new Sc(function(){pd=null}));(pd=document.getElementsByTagName("video")[0]||document.getElementsByTagName("audio")[0])||(pd=document.createElement("video"));qd.Z(1);return pd}
106
106
  function rd(a){return a?a===window.shakaMediaKeysPolyfill:!!window.shakaMediaKeysPolyfill}
107
- function sd(){var a,b,c,d,e,f,g,h,k,l,m,n,q,p,w;return O(function(u){switch(u.g){case 1:a={width:Infinity,height:Infinity};if(fd()){n=window.cast&&cast.__platform__&&cast.__platform__.canDisplayType;a.width=1280;a.height=720;ra(u,15);if(!(q=n)){u.u(17);break}return F(u,cast.__platform__.canDisplayType('video/mp4; codecs="avc1.640028"; width=3840; height=2160'),18)}if($c()){a.width=1920;a.height=1080;try{webapis.systeminfo&&webapis.systeminfo.getMaxVideoResolution?(b=webapis.systeminfo.getMaxVideoResolution(),
108
- a.width=b.width,a.height=b.height):webapis.productinfo.is8KPanelSupported&&webapis.productinfo.is8KPanelSupported()?(a.width=7680,a.height=4320):webapis.productinfo.isUdPanelSupported&&webapis.productinfo.isUdPanelSupported()&&(a.width=3840,a.height=2160)}catch(v){Ya("Tizen: Error detecting screen size, default screen size 1920x1080.")}u.u(3);break}if(Yc()){a.width=1920;a.height=1080;try{c=void 0;c="undefined"!==typeof Windows?Windows:chrome.webview.hostObjects.sync.Windows;d=new c.Media.Protection.ProtectionCapabilities;
109
- e=c.Media.Protection.ProtectionCapabilityResult;f=null;do f=d.isTypeSupported('video/mp4;codecs="hvc1,mp4a";features="decode-res-x=3840,decode-res-y=2160,decode-bitrate=20000,decode-fps=30,decode-bpc=10,display-res-x=3840,display-res-y=2160,display-bpc=8"',"com.microsoft.playready.recommendation");while(f===e.maybe);f===e.probably&&(a.width=3840,a.height=2160)}catch(v){Ya("Xbox: Error detecting screen size, default screen size 1920x1080.")}u.u(3);break}if(cd()){try{g=JSON.parse(window.PalmSystem.deviceInfo),
110
- a.width=Math.max(1920,g.screenWidth),a.height=Math.max(1080,g.screenHeight)}catch(v){Ya("WebOS: Error detecting screen size, default screen size 1920x1080."),a.width=1920,a.height=1080}u.u(3);break}if(kd()){window.Hisense_Get4KSupportState&&window.Hisense_Get4KSupportState()?(a.width=3840,a.height=2160):(a.width=1920,a.height=1080);u.u(3);break}if(!id()&&!jd()){u.u(3);break}h=!1;ra(u,9);return F(u,window.msdk.device.getDisplayInfo(),11);case 11:k=u.h;h="4K"===k.resolution;ta(u,10);break;case 9:return ua(u),
111
- ra(u,12),F(u,window.msdk.device.getDisplayInfoImmediate(),14);case 14:l=u.h;h="4K"===l.resolution;ta(u,10);break;case 12:m=ua(u),Ya("PlayStation: Failed to get the display info:",m);case 10:h?(a.width=3840,a.height=2160):(a.width=1920,a.height=1080);u.u(3);break;case 18:q=u.h;case 17:if(q){a.width=3840;a.height=2160;u.u(19);break}if(!(p=n)){u.u(20);break}return F(u,cast.__platform__.canDisplayType('video/mp4; codecs="avc1.640028"; width=1920; height=1080'),21);case 21:p=u.h;case 20:p&&(a.width=1920,
112
- a.height=1080);case 19:ta(u,3);break;case 15:w=ua(u),Xa("Failed to check canDisplayType:",w);case 3:return u.return(a)}})}var qd=null,pd=null;function td(){}
107
+ function sd(){var a,b,c,d,e,f,g,h,k,l,m,n,p,r,u;return O(function(v){switch(v.g){case 1:a={width:Infinity,height:Infinity};if(fd()){n=window.cast&&cast.__platform__&&cast.__platform__.canDisplayType;a.width=1280;a.height=720;ra(v,15);if(!(p=n)){v.u(17);break}return F(v,cast.__platform__.canDisplayType('video/mp4; codecs="avc1.640028"; width=3840; height=2160'),18)}if($c()){a.width=1920;a.height=1080;try{webapis.systeminfo&&webapis.systeminfo.getMaxVideoResolution?(b=webapis.systeminfo.getMaxVideoResolution(),
108
+ a.width=b.width,a.height=b.height):webapis.productinfo.is8KPanelSupported&&webapis.productinfo.is8KPanelSupported()?(a.width=7680,a.height=4320):webapis.productinfo.isUdPanelSupported&&webapis.productinfo.isUdPanelSupported()&&(a.width=3840,a.height=2160)}catch(w){Ya("Tizen: Error detecting screen size, default screen size 1920x1080.")}v.u(3);break}if(Yc()){a.width=1920;a.height=1080;try{c=void 0;c="undefined"!==typeof Windows?Windows:chrome.webview.hostObjects.sync.Windows;d=new c.Media.Protection.ProtectionCapabilities;
109
+ e=c.Media.Protection.ProtectionCapabilityResult;f=null;do f=d.isTypeSupported('video/mp4;codecs="hvc1,mp4a";features="decode-res-x=3840,decode-res-y=2160,decode-bitrate=20000,decode-fps=30,decode-bpc=10,display-res-x=3840,display-res-y=2160,display-bpc=8"',"com.microsoft.playready.recommendation");while(f===e.maybe);f===e.probably&&(a.width=3840,a.height=2160)}catch(w){Ya("Xbox: Error detecting screen size, default screen size 1920x1080.")}v.u(3);break}if(cd()){try{g=JSON.parse(window.PalmSystem.deviceInfo),
110
+ a.width=Math.max(1920,g.screenWidth),a.height=Math.max(1080,g.screenHeight)}catch(w){Ya("WebOS: Error detecting screen size, default screen size 1920x1080."),a.width=1920,a.height=1080}v.u(3);break}if(kd()){window.Hisense_Get4KSupportState&&window.Hisense_Get4KSupportState()?(a.width=3840,a.height=2160):(a.width=1920,a.height=1080);v.u(3);break}if(!id()&&!jd()){v.u(3);break}h=!1;ra(v,9);return F(v,window.msdk.device.getDisplayInfo(),11);case 11:k=v.h;h="4K"===k.resolution;ta(v,10);break;case 9:return ua(v),
111
+ ra(v,12),F(v,window.msdk.device.getDisplayInfoImmediate(),14);case 14:l=v.h;h="4K"===l.resolution;ta(v,10);break;case 12:m=ua(v),Ya("PlayStation: Failed to get the display info:",m);case 10:h?(a.width=3840,a.height=2160):(a.width=1920,a.height=1080);v.u(3);break;case 18:p=v.h;case 17:if(p){a.width=3840;a.height=2160;v.u(19);break}if(!(r=n)){v.u(20);break}return F(v,cast.__platform__.canDisplayType('video/mp4; codecs="avc1.640028"; width=1920; height=1080'),21);case 21:r=v.h;case 20:r&&(a.width=1920,
112
+ a.height=1080);case 19:ta(v,3);break;case 15:u=ua(v),Xa("Failed to check canDisplayType:",u);case 3:return v.return(a)}})}var qd=null,pd=null;function td(){}
113
113
  function ud(a){if(!a)return"";a=zb(a);239==a[0]&&187==a[1]&&191==a[2]&&(a=a.subarray(3));if(window.TextDecoder&&!id())return a=(new TextDecoder).decode(a),a.includes("\ufffd")&&Xa('Decoded string contains an "unknown character" codepoint. That probably means the UTF8 encoding was incorrect!'),a;for(var b="",c=0;c<a.length;++c){var d=65533;0==(a[c]&128)?d=a[c]:a.length>=c+2&&192==(a[c]&224)&&128==(a[c+1]&192)?(d=(a[c]&31)<<6|a[c+1]&63,c+=1):a.length>=c+3&&224==(a[c]&240)&&128==(a[c+1]&192)&&128==
114
114
  (a[c+2]&192)?(d=(a[c]&15)<<12|(a[c+1]&63)<<6|a[c+2]&63,c+=2):a.length>=c+4&&240==(a[c]&241)&&128==(a[c+1]&192)&&128==(a[c+2]&192)&&128==(a[c+3]&192)&&(d=(a[c]&7)<<18|(a[c+1]&63)<<12|(a[c+2]&63)<<6|a[c+3]&63,c+=3);if(65535>=d)b+=String.fromCharCode(d);else{d-=65536;var e=d&1023;b+=String.fromCharCode(55296+(d>>10));b+=String.fromCharCode(56320+e)}}return b}
115
115
  function wd(a,b,c){if(!a)return"";if(!c&&0!=a.byteLength%2)throw new T(2,2,2004);c=Math.floor(a.byteLength/2);var d=new Uint16Array(c);a=Eb(a);for(var e=0;e<c;e++)d[e]=a.getUint16(2*e,b);return xd(d)}
@@ -127,7 +127,7 @@ function fe(a){var b=ge(a);a=b[0];b=b[1].toLowerCase();switch(!0){case "mp4a"===
127
127
  a&&"b2"===b:return"dtsx";case "mp4a"===a&&"a9"===b:return"dtsc";case "avc1"===a:case "avc3"===a:return"avc";case "hvc1"===a:case "hev1"===a:return"hevc";case "vvc1"===a:case "vvi1"===a:return"vvc";case "dvh1"===a:case "dvhe"===a:return"dovi-hevc";case "dvav"===a:case "dva1"===a:return"dovi-avc";case "dav1"===a:return"dovi-av1";case "dvc1"===a:case "dvi1"===a:return"dovi-vvc"}return a}
128
128
  function he(a){var b=[];a=t(a.split(","));for(var c=a.next();!c.done;c=a.next())c=ge(c.value),b.push(c[0]);return b.sort().join(",")}function ie(a){return a.split(";")[0]}function je(a){a=a.split(/ *; */);a.shift();return(a=a.find(function(b){return b.startsWith("codecs=")}))?a.split("=")[1].replace(/^"|"$/g,""):""}function ke(a){return"application/x-mpegurl"===a||"application/vnd.apple.mpegurl"===a}function ge(a){a=a.split(".");var b=a[0];a.shift();return[b,a.join(".")]}
129
129
  S("shaka.util.MimeUtils",Yd);Yd.getFullTypeWithAllCodecs=ae;Yd.getFullType=Zd;var de=(new Map).set("codecs","codecs").set("frameRate","framerate").set("bandwidth","bitrate").set("width","width").set("height","height").set("channelsCount","channels"),$d=["audio/aac","audio/ac3","audio/ec3","audio/mpeg"];function pe(a){this.i=null;this.j=a;this.B=!1;this.l=this.s=0;this.m=Infinity;this.h=this.g=null;this.C="";this.A=function(){};this.o=new Map}function qe(a){return re[a]?!0:"application/cea-608"==a||"application/cea-708"==a?!!Ib:!1}pe.prototype.destroy=function(){this.j=this.i=null;this.o.clear();return Promise.resolve()};
130
- function te(a,b,c,d,e){var f,g,h,k,l,m,n;return O(function(q){if(1==q.g)return F(q,Promise.resolve(),2);if(!a.i||!a.j)return q.return();if(null==c||null==d)return a.i.parseInit(zb(b)),q.return();f=a.B?c:a.s;g={periodStart:a.s,segmentStart:c,segmentEnd:d,vttOffset:f};h=a.i.parseMedia(zb(b),g,e);k=t(h);for(l=k.next();!l.done;l=k.next())m=l.value,a.A(m,e||null,g);n=h.filter(function(p){return p.startTime>=a.l&&p.startTime<a.m});a.j.append(n);null==a.g&&(a.g=Math.max(c,a.l));a.h=Math.min(d,a.m);H(q)})}
130
+ function te(a,b,c,d,e){var f,g,h,k,l,m,n;return O(function(p){if(1==p.g)return F(p,Promise.resolve(),2);if(!a.i||!a.j)return p.return();if(null==c||null==d)return a.i.parseInit(zb(b)),p.return();f=a.B?c:a.s;g={periodStart:a.s,segmentStart:c,segmentEnd:d,vttOffset:f};h=a.i.parseMedia(zb(b),g,e);k=t(h);for(l=k.next();!l.done;l=k.next())m=l.value,a.A(m,e||null,g);n=h.filter(function(r){return r.startTime>=a.l&&r.startTime<a.m});a.j.append(n);null==a.g&&(a.g=Math.max(c,a.l));a.h=Math.min(d,a.m);H(p)})}
131
131
  pe.prototype.remove=function(a,b){var c=this;return O(function(d){if(1==d.g)return F(d,Promise.resolve(),2);!c.j||!c.j.remove(a,b)||null==c.g||b<=c.g||a>=c.h||(a<=c.g&&b>=c.h?c.g=c.h=null:a<=c.g&&b<c.h?c.g=b:a>c.g&&b>=c.h&&(c.h=a));H(d)})};function ue(a,b,c){a.l=b;a.m=c}function ve(a,b,c){a.C=b;if(b=a.o.get(b))for(var d=t(b.keys()),e=d.next();!e.done;e=d.next())(e=b.get(e.value).filter(function(f){return f.endTime<=c}))&&a.j.append(e)}
132
132
  function we(a,b,c){b.startTime+=c;b.endTime+=c;b=t(b.nestedCues);for(var d=b.next();!d.done;d=b.next())we(a,d.value,c)}
133
133
  function xe(a,b,c,d,e){var f=c+" "+d,g=new Map;b=t(b);for(var h=b.next();!h.done;h=b.next()){var k=h.value;h=k.stream;k=k.cue;g.has(h)||g.set(h,new Map);g.get(h).has(f)||g.get(h).set(f,[]);we(a,k,e);k.startTime>=a.l&&k.startTime<a.m&&(g.get(h).get(f).push(k),h==a.C&&a.j.append([k]))}e=t(g.keys());for(f=e.next();!f.done;f=e.next())for(f=f.value,a.o.has(f)||a.o.set(f,new Map),b=t(g.get(f).keys()),h=b.next();!h.done;h=b.next())h=h.value,k=g.get(f).get(h),a.o.get(f).set(h,k);a.g=null==a.g?Math.max(c,
@@ -142,10 +142,10 @@ var Ge=new Map([["aar","aa"],["abk","ab"],["afr","af"],["aka","ak"],["alb","sq"]
142
142
  "mi"],["mar","mr"],["may","ms"],["mkd","mk"],["mlg","mg"],["mlt","mt"],["mon","mn"],["mri","mi"],["msa","ms"],["mya","my"],["nau","na"],["nav","nv"],["nbl","nr"],["nde","nd"],["ndo","ng"],["nep","ne"],["nld","nl"],["nno","nn"],["nob","nb"],["nor","no"],["nya","ny"],["oci","oc"],["oji","oj"],["ori","or"],["orm","om"],["oss","os"],["pan","pa"],["per","fa"],["pli","pi"],["pol","pl"],["por","pt"],["pus","ps"],["que","qu"],["roh","rm"],["ron","ro"],["rum","ro"],["run","rn"],["rus","ru"],["sag","sg"],["san",
143
143
  "sa"],["sin","si"],["slk","sk"],["slo","sk"],["slv","sl"],["sme","se"],["smo","sm"],["sna","sn"],["snd","sd"],["som","so"],["sot","st"],["spa","es"],["sqi","sq"],["srd","sc"],["srp","sr"],["ssw","ss"],["sun","su"],["swa","sw"],["swe","sv"],["tah","ty"],["tam","ta"],["tat","tt"],["tel","te"],["tgk","tg"],["tgl","tl"],["tha","th"],["tib","bo"],["tir","ti"],["ton","to"],["tsn","tn"],["tso","ts"],["tuk","tk"],["tur","tr"],["twi","tw"],["uig","ug"],["ukr","uk"],["urd","ur"],["uzb","uz"],["ven","ve"],["vie",
144
144
  "vi"],["vol","vo"],["wel","cy"],["wln","wa"],["wol","wo"],["xho","xh"],["yid","yi"],["yor","yo"],["zha","za"],["zho","zh"],["zul","zu"]]);function Le(a){function b(d){switch(typeof d){case "undefined":case "boolean":case "number":case "string":case "symbol":case "function":return d;default:if(!d||d.buffer instanceof ArrayBuffer)return d;if(c.has(d))return null;var e=d.constructor==Array;if(d.constructor!=Object&&!e)return null;c.add(d);var f=e?[]:{},g;for(g in d)f[g]=b(d[g]);e&&(f.length=d.length);return f}}var c=new WeakSet;return b(a)}function Me(a){var b={},c;for(c in a)b[c]=a[c];return b};function Ne(){}
145
- function Oe(a,b,c,d){var e=a.variants;if(b.length||c.length)e=Pe(e,b,c);if(d.length){b=new fb;e=t(e);for(c=e.next();!c.done;c=e.next())c=c.value,b.push(String(c.video.width||0),c);var f=[];b.forEach(function(w,u){w=0;var v=[];u=t(u);for(var A=u.next(),z={};!A.done;z={ze:void 0},A=u.next())z.ze=A.value,A=d.filter(function(D){return function(y){return D.ze.decodingInfos[0][y]}}(z)).length,A>w?(w=A,v=[z.ze]):A==w&&v.push(z.ze);f.push.apply(f,x(v))});e=f}c=new Set;b=new Set;e=t(e);for(var g=e.next();!g.done;g=
146
- e.next())g=g.value,g.audio&&c.add(g.audio),g.video&&b.add(g.video);c=Array.from(c).sort(function(w,u){return w.bandwidth-u.bandwidth});var h=[];e=new Map;c=t(c);for(g=c.next();!g.done;g=c.next()){g=g.value;var k=g.language+(g.channelsCount||0)+(g.audioSamplingRate||0)+g.roles.join(",")+g.label+g.groupId+g.fastSwitching,l=e.get(k)||[];if(l.length){var m=l[l.length-1],n=fe(m.codecs),q=fe(g.codecs);n!=q||g.bandwidth&&m.bandwidth&&!(g.bandwidth>m.bandwidth)||(l.push(g),h.push(g.id))}else l.push(g),h.push(g.id);
147
- e.set(k,l)}c=Array.from(b).sort(function(w,u){return w.bandwidth&&u.bandwidth?w.bandwidth-u.bandwidth:w.width-u.width});b=ob();var p=[];e=new Map;c=t(c);for(g=c.next();!g.done;g=c.next()){g=g.value;k=Math.round(g.frameRate||0)+(g.hdr||"")+g.fastSwitching;l=e.get(k)||[];if(l.length){m=l[l.length-1];if(!b&&(n=fe(m.codecs),q=fe(g.codecs),n!==q))continue;g.width>m.width||g.height>m.height?(l.push(g),p.push(g.id)):g.width==m.width&&g.height==m.height&&(n=fe(m.codecs),q=fe(g.codecs),n!=q||g.bandwidth&&
148
- m.bandwidth&&!(g.bandwidth>m.bandwidth)||(l.push(g),p.push(g.id)))}else l.push(g),p.push(g.id);e.set(k,l)}a.variants=a.variants.filter(function(w){var u=w.audio;w=w.video;return u&&!h.includes(u.id)||w&&!p.includes(w.id)?!1:!0})}
145
+ function Oe(a,b,c,d){var e=a.variants;if(b.length||c.length)e=Pe(e,b,c);if(d.length){b=new fb;e=t(e);for(c=e.next();!c.done;c=e.next())c=c.value,b.push(String(c.video.width||0),c);var f=[];b.forEach(function(u,v){u=0;var w=[];v=t(v);for(var A=v.next(),z={};!A.done;z={ze:void 0},A=v.next())z.ze=A.value,A=d.filter(function(D){return function(y){return D.ze.decodingInfos[0][y]}}(z)).length,A>u?(u=A,w=[z.ze]):A==u&&w.push(z.ze);f.push.apply(f,x(w))});e=f}c=new Set;b=new Set;e=t(e);for(var g=e.next();!g.done;g=
146
+ e.next())g=g.value,g.audio&&c.add(g.audio),g.video&&b.add(g.video);c=Array.from(c).sort(function(u,v){return u.bandwidth-v.bandwidth});var h=[];e=new Map;c=t(c);for(g=c.next();!g.done;g=c.next()){g=g.value;var k=g.language+(g.channelsCount||0)+(g.audioSamplingRate||0)+g.roles.join(",")+g.label+g.groupId+g.fastSwitching,l=e.get(k)||[];if(l.length){var m=l[l.length-1],n=fe(m.codecs),p=fe(g.codecs);n!=p||g.bandwidth&&m.bandwidth&&!(g.bandwidth>m.bandwidth)||(l.push(g),h.push(g.id))}else l.push(g),h.push(g.id);
147
+ e.set(k,l)}c=Array.from(b).sort(function(u,v){return u.bandwidth&&v.bandwidth?u.bandwidth-v.bandwidth:u.width-v.width});b=ob();var r=[];e=new Map;c=t(c);for(g=c.next();!g.done;g=c.next()){g=g.value;k=Math.round(g.frameRate||0)+(g.hdr||"")+g.fastSwitching;l=e.get(k)||[];if(l.length){m=l[l.length-1];if(!b&&(n=fe(m.codecs),p=fe(g.codecs),n!==p))continue;g.width>m.width||g.height>m.height?(l.push(g),r.push(g.id)):g.width==m.width&&g.height==m.height&&(n=fe(m.codecs),p=fe(g.codecs),n!=p||g.bandwidth&&
148
+ m.bandwidth&&!(g.bandwidth>m.bandwidth)||(l.push(g),r.push(g.id)))}else l.push(g),r.push(g.id);e.set(k,l)}a.variants=a.variants.filter(function(u){var v=u.audio;u=u.video;return v&&!h.includes(v.id)||u&&!r.includes(u.id)?!1:!0})}
149
149
  function Pe(a,b,c){b=t(b);for(var d=b.next(),e={};!d.done;e={oh:void 0},d=b.next())if(e.oh=d.value,d=a.filter(function(f){return function(g){return g.video&&g.video.codecs.startsWith(f.oh)}}(e)),d.length){a=d;break}c=t(c);b=c.next();for(d={};!b.done;d={ig:void 0},b=c.next())if(d.ig=b.value,b=a.filter(function(f){return function(g){return g.audio&&g.audio.codecs.startsWith(f.ig)}}(d)),b.length){a=b;break}return a}function Qe(a,b,c){a.variants=a.variants.filter(function(d){return Re(d,b,c)})}
150
150
  function Re(a,b,c){function d(h,k,l){return h>=k&&h<=l}var e=a.video;if(e&&e.width&&e.height){var f=e.width,g=e.height;g>f&&(g=t([g,f]),f=g.next().value,g=g.next().value);if(!d(f,b.minWidth,Math.min(b.maxWidth,c.width))||!d(g,b.minHeight,Math.min(b.maxHeight,c.height))||!d(e.width*e.height,b.minPixels,b.maxPixels))return!1}return a&&a.video&&a.video.frameRate&&!d(a.video.frameRate,b.minFrameRate,b.maxFrameRate)||a&&a.audio&&a.audio.channelsCount&&!d(a.audio.channelsCount,b.minChannelsCount,b.maxChannelsCount)||
151
151
  !d(a.bandwidth,b.minBandwidth,b.maxBandwidth)?!1:!0}function Se(a,b,c){var d=!1;a=t(a);for(var e=a.next();!e.done;e=a.next()){e=e.value;var f=e.allowedByApplication;e.allowedByApplication=Re(e,b,c);f!=e.allowedByApplication&&(d=!0)}return d}function Te(a,b,c){c=void 0===c?[]:c;return O(function(d){if(1==d.g)return F(d,Ue(a,b,0<b.offlineSessionIds.length,c),2);Ve(b);return F(d,We(b),0)})}
@@ -153,22 +153,22 @@ function Ue(a,b,c,d){var e,f;return O(function(g){if(1==g.g)return Yc()&&Xe(b.va
153
153
  function Xe(a){var b={dvav:"avc3",dva1:"avc1",dvhe:"hev1",dvh1:"hvc1",dvc1:"vvc1",dvi1:"vvi1"},c=new Set;a=t(a);for(var d=a.next();!d.done;d=a.next())d=d.value,d.video&&c.add(d.video);c=t(c);for(a=c.next();!a.done;a=c.next()){a=a.value;d=t(Object.keys(b));for(var e=d.next();!e.done;e=d.next())if(e=e.value,a.codecs.includes(e)){a.codecs=a.codecs.replace(e,b[e]);break}}}
154
154
  function Ze(a,b){var c=Yc(),d=Zc("Firefox")&&nd(),e=a.video,f=e&&e.width||0,g=e&&e.height||0;if(c&&e&&(1920<f||1080<g)&&(e.codecs.includes("avc1.")||e.codecs.includes("avc3.")))return!1;if(e){c=af(e.codecs);if(e.codecs.includes(",")){f=e.codecs.split(",");c=Rd("video",f);c=af(c);f=Rd("audio",f);f=bf(f,e.mimeType);g=be(e.mimeType,f,"audio");if(!mb(g))return!1;c=[c,f].join()}f=be(e.mimeType,c,"video");if(!mb(f))return!1;e.codecs=c}e=a.audio;if(d&&e&&e.encrypted&&e.codecs.toLowerCase().includes("opus"))return!1;
155
155
  if(e){d=bf(e.codecs,e.mimeType);c=be(e.mimeType,d,"audio");if(!mb(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 cf(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=cf(e),c.push(d+":"+e)):(e=JSON.stringify(e),c.push(d+":"+e))}return"{"+c.join(",")+"}"}
156
- function df(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 q=Me(m);q.supported=m.supported&&n.supported;q.powerEfficient=m.powerEfficient&&n.powerEfficient;q.smooth=m.smooth&&n.smooth;n.keySystemAccess&&!q.keySystemAccess&&(q.keySystemAccess=n.keySystemAccess);return q}return n};d=null;e=[];f=t(b);g=f.next();for(h={};!g.done;h={cache:void 0,zd:void 0},g=f.next())k=g.value,h.zd=cf(k),h.cache=ef,h.cache[h.zd]?d=c(d,h.cache[h.zd]):e.push(ff(k).then(function(m){return function(n){var q=
157
- null;n=t(n||[]);for(var p=n.next();!p.done;p=n.next())q=c(q,p.value);q&&(m.cache[m.zd]=q,d=c(d,q))}}(h)));return F(l,Promise.all(e),2)}d&&a.decodingInfos.push(d);H(l)})}
156
+ function df(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=Me(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=t(b);g=f.next();for(h={};!g.done;h={cache:void 0,zd:void 0},g=f.next())k=g.value,h.zd=cf(k),h.cache=ef,h.cache[h.zd]?d=c(d,h.cache[h.zd]):e.push(ff(k).then(function(m){return function(n){var p=
157
+ null;n=t(n||[]);for(var r=n.next();!r.done;r=n.next())p=c(p,r.value);p&&(m.cache[m.zd]=p,d=c(d,p))}}(h)));return F(l,Promise.all(e),2)}d&&a.decodingInfos.push(d);H(l)})}
158
158
  function ff(a){var b=[""];a.video&&(b=je(a.video.contentType).split(","));var c=[""];a.audio&&(c=je(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=t(c),g=f.next(),h={};!g.done;h={yc:void 0},g=f.next())g=g.value,h.yc=Le(a),a.video&&(h.yc.video.contentType=Zd(ie(h.yc.video.contentType),e)),a.audio&&(h.yc.audio.contentType=Zd(ie(h.yc.audio.contentType),g)),d.push(new Promise(function(k){return function(l,m){navigator.mediaCapabilities.decodingInfo(k.yc).then(function(n){l(n)}).catch(m)}}(h)))}return Promise.all(d).catch(function(){JSON.stringify(a);
159
159
  return null})}
160
- function Ye(a,b,c,d){var e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C;return O(function(E){switch(E.g){case 1:if(e=a.some(function(G){return G.decodingInfos.length}))return E.return();f=t(d);g=f.next();h={};case 2:if(g.done){E.u(4);break}h.Qg=g.value;k=!1;l=t(a);m=l.next();case 5:if(m.done){E.u(7);break}n=m.value;q=gf(n,b,c).filter(function(G){return function(L){L=L[0];return(L.keySystemConfiguration&&L.keySystemConfiguration.keySystem)===G.Qg}}(h));p=t(q);w=p.next();case 8:if(w.done){E.u(10);break}u=w.value;
161
- return F(E,df(n,u),9);case 9:w=p.next();E.u(8);break;case 10:n.decodingInfos.length&&(k=!0);m=l.next();E.u(5);break;case 7:if(k)return E.return();h={Qg:void 0};g=f.next();E.u(2);break;case 4:v=t(a),A=v.next();case 12:if(A.done){E.u(0);break}z=A.value;D=gf(z,b,c).filter(function(G){G=G[0];G=G.keySystemConfiguration&&G.keySystemConfiguration.keySystem;return!G||!d.includes(G)});y=t(D);B=y.next();case 15:if(B.done){A=v.next();E.u(12);break}C=B.value;return F(E,df(z,C),16);case 16:B=y.next(),E.u(15)}})}
160
+ function Ye(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C;return O(function(E){switch(E.g){case 1:if(e=a.some(function(G){return G.decodingInfos.length}))return E.return();f=t(d);g=f.next();h={};case 2:if(g.done){E.u(4);break}h.Qg=g.value;k=!1;l=t(a);m=l.next();case 5:if(m.done){E.u(7);break}n=m.value;p=gf(n,b,c).filter(function(G){return function(L){L=L[0];return(L.keySystemConfiguration&&L.keySystemConfiguration.keySystem)===G.Qg}}(h));r=t(p);u=r.next();case 8:if(u.done){E.u(10);break}v=u.value;
161
+ return F(E,df(n,v),9);case 9:u=r.next();E.u(8);break;case 10:n.decodingInfos.length&&(k=!0);m=l.next();E.u(5);break;case 7:if(k)return E.return();h={Qg:void 0};g=f.next();E.u(2);break;case 4:w=t(a),A=w.next();case 12:if(A.done){E.u(0);break}z=A.value;D=gf(z,b,c).filter(function(G){G=G[0];G=G.keySystemConfiguration&&G.keySystemConfiguration.keySystem;return!G||!d.includes(G)});y=t(D);B=y.next();case 15:if(B.done){A=w.next();E.u(12);break}C=B.value;return F(E,df(z,C),16);case 16:B=y.next(),E.u(15)}})}
162
162
  function gf(a,b,c){var d=a.audio,e=a.video,f=[],g=[];if(e)for(var h=t(e.fullMimeTypes),k=h.next();!k.done;k=h.next()){k=k.value;var l=je(k);if(l.includes(",")&&!d){var m=l.split(","),n=ie(k);l=Rd("video",m);m=Rd("audio",m);m=bf(m,n);n=be(n,m,"audio");g.push({contentType:n,channels:2,bitrate:a.bandwidth||1,samplerate:1,spatialRendering:!1})}l=af(l);k={contentType:be(ie(k),l,"video"),width:e.width||64,height:e.height||64,bitrate:e.bandwidth||a.bandwidth||1,framerate:e.frameRate||1};if(e.hdr)switch(e.hdr){case "SDR":k.transferFunction=
163
163
  "srgb";break;case "PQ":k.transferFunction="pq";break;case "HLG":k.transferFunction="hlg"}e.colorGamut&&(k.colorGamut=e.colorGamut);f.push(k)}if(d)for(h=t(d.fullMimeTypes),k=h.next();!k.done;k=h.next())l=k.value,k=ie(l),l=bf(je(l),k),k=be(k,l,"audio"),g.push({contentType:k,channels:d.channelsCount||2,bitrate:d.bandwidth||a.bandwidth||1,samplerate:d.audioSamplingRate||1,spatialRendering:d.spatialAudio});h=[];0==f.length&&f.push(null);0==g.length&&g.push(null);f=t(f);for(k=f.next();!k.done;k=f.next())for(k=
164
164
  k.value,l=t(g),n=l.next();!n.done;n=l.next())n=n.value,m={type:c?"file":"media-source"},k&&(m.video=k),n&&(m.audio=n),h.push(m);g=(a.video?a.video.drmInfos:[]).concat(a.audio?a.audio.drmInfos:[]);if(!g.length)return[h];a=[];c=new Map;g=t(g);for(f=g.next();!f.done;f=g.next())f=f.value,c.get(f.keySystem)||c.set(f.keySystem,[]),c.get(f.keySystem).push(f);g=b?"required":"optional";b=b?["persistent-license"]:["temporary"];f=t(c.keys());for(k=f.next();!k.done;k=f.next()){k=k.value;l=[];n=t(h);for(m=n.next();!m.done;m=
165
- n.next()){m=Object.assign({},m.value);var q=c.get(k),p={keySystem:k,initDataType:"cenc",persistentState:g,distinctiveIdentifier:"optional",sessionTypes:b};q=t(q);for(var w=q.next();!w.done;w=q.next()){w=w.value;if(w.initData&&w.initData.length){for(var u=new Set,v=t(w.initData),A=v.next();!A.done;A=v.next())u.add(A.value.initDataType);p.initDataType=w.initData[0].initDataType}w.distinctiveIdentifierRequired&&(p.distinctiveIdentifier="required");w.persistentStateRequired&&(p.persistentState="required");
166
- w.sessionType&&(p.sessionTypes=[w.sessionType]);d&&(p.audio?(w.encryptionScheme&&(p.audio.encryptionScheme=p.audio.encryptionScheme||w.encryptionScheme),p.audio.robustness=p.audio.robustness||w.audioRobustness):(p.audio={robustness:w.audioRobustness},w.encryptionScheme&&(p.audio.encryptionScheme=w.encryptionScheme)),""==p.audio.robustness&&delete p.audio.robustness);e&&(p.video?(w.encryptionScheme&&(p.video.encryptionScheme=p.video.encryptionScheme||w.encryptionScheme),p.video.robustness=p.video.robustness||
167
- w.videoRobustness):(p.video={robustness:w.videoRobustness},w.encryptionScheme&&(p.video.encryptionScheme=w.encryptionScheme)),""==p.video.robustness&&delete p.video.robustness)}m.keySystemConfiguration=p;l.push(m)}a.push(l)}return a}function bf(a,b){return"flac"==a.toLowerCase()?ld()?"fLaC":"flac":"opus"===a.toLowerCase()?ld()?"mp4"==ee(b)?"Opus":"opus":"opus":a}
165
+ n.next()){m=Object.assign({},m.value);var p=c.get(k),r={keySystem:k,initDataType:"cenc",persistentState:g,distinctiveIdentifier:"optional",sessionTypes:b};p=t(p);for(var u=p.next();!u.done;u=p.next()){u=u.value;if(u.initData&&u.initData.length){for(var v=new Set,w=t(u.initData),A=w.next();!A.done;A=w.next())v.add(A.value.initDataType);r.initDataType=u.initData[0].initDataType}u.distinctiveIdentifierRequired&&(r.distinctiveIdentifier="required");u.persistentStateRequired&&(r.persistentState="required");
166
+ u.sessionType&&(r.sessionTypes=[u.sessionType]);d&&(r.audio?(u.encryptionScheme&&(r.audio.encryptionScheme=r.audio.encryptionScheme||u.encryptionScheme),r.audio.robustness=r.audio.robustness||u.audioRobustness):(r.audio={robustness:u.audioRobustness},u.encryptionScheme&&(r.audio.encryptionScheme=u.encryptionScheme)),""==r.audio.robustness&&delete r.audio.robustness);e&&(r.video?(u.encryptionScheme&&(r.video.encryptionScheme=r.video.encryptionScheme||u.encryptionScheme),r.video.robustness=r.video.robustness||
167
+ u.videoRobustness):(r.video={robustness:u.videoRobustness},u.encryptionScheme&&(r.video.encryptionScheme=u.encryptionScheme)),""==r.video.robustness&&delete r.video.robustness)}m.keySystemConfiguration=r;l.push(m)}a.push(l)}return a}function bf(a,b){return"flac"==a.toLowerCase()?ld()?"fLaC":"flac":"opus"===a.toLowerCase()?ld()?"mp4"==ee(b)?"Opus":"opus":"opus":a}
168
168
  function af(a){if(a.includes("avc1")){var b=a.split(".");if(3==b.length)return a=b.shift()+".",a+=parseInt(b.shift(),10).toString(16),a+=("000"+parseInt(b.shift(),10).toString(16)).slice(-4)}else if("vp9"==a)return"vp09.00.41.08";return a}function Ve(a){a.textStreams=a.textStreams.filter(function(b){b=Zd(b.mimeType,b.codecs);return qe(b)})}
169
169
  function We(a){var b,c,d,e,f,g,h,k;return O(function(l){switch(l.g){case 1:b=[],c=t(a.imageStreams),d=c.next();case 2:if(d.done){l.u(4);break}e=d.value;f=e.mimeType;"application/mp4"==f&&"mjpg"==e.codecs&&(f="image/jpg");if(hf.has(f)){l.u(5);break}g=jf.get(f);if(!g){hf.set(f,!1);l.u(5);break}return F(l,kf(g),7);case 7:h=l.h,hf.set(f,h);case 5:(k=hf.get(f))&&b.push(e);d=c.next();l.u(2);break;case 4:a.imageStreams=b,H(l)}})}
170
170
  function kf(a){return new Promise(function(b){var c=new Image;c.src=a;"decode"in c?c.decode().then(function(){b(!0)}).catch(function(){b(!1)}):c.onload=c.onerror=function(){b(2===c.height)}})}
171
- function lf(a){var b=a.audio,c=a.video,d=b?b.mimeType:null,e=c?c.mimeType:null,f=b?b.codecs:null,g=c?c.codecs:null,h=[];g&&h.push(g);f&&h.push(f);var k=[];c&&k.push(c.mimeType);b&&k.push(b.mimeType);k=k[0]||null;var l=[];b&&l.push(b.kind);c&&l.push(c.kind);l=l[0]||null;var m=new Set;if(b)for(var n=t(b.roles),q=n.next();!q.done;q=n.next())m.add(q.value);if(c)for(n=t(c.roles),q=n.next();!q.done;q=n.next())m.add(q.value);a={id:a.id,active:!1,type:"variant",bandwidth:a.bandwidth,language:a.language,label:null,
171
+ function lf(a){var b=a.audio,c=a.video,d=b?b.mimeType:null,e=c?c.mimeType:null,f=b?b.codecs:null,g=c?c.codecs:null,h=[];g&&h.push(g);f&&h.push(f);var k=[];c&&k.push(c.mimeType);b&&k.push(b.mimeType);k=k[0]||null;var l=[];b&&l.push(b.kind);c&&l.push(c.kind);l=l[0]||null;var m=new Set;if(b)for(var n=t(b.roles),p=n.next();!p.done;p=n.next())m.add(p.value);if(c)for(n=t(c.roles),p=n.next();!p.done;p=n.next())m.add(p.value);a={id:a.id,active:!1,type:"variant",bandwidth:a.bandwidth,language:a.language,label:null,
172
172
  kind:l,width:null,height:null,frameRate:null,pixelAspectRatio:null,hdr:null,colorGamut:null,videoLayout:null,mimeType:k,audioMimeType:d,videoMimeType:e,codecs:h.join(", "),audioCodec:f,videoCodec:g,primary:a.primary,roles:Array.from(m),audioRoles:null,forced:!1,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,originalTextId:null,originalImageId:null,accessibilityPurpose:null,
173
173
  originalLanguage:null};c&&(a.videoId=c.id,a.originalVideoId=c.originalId,a.width=c.width||null,a.height=c.height||null,a.frameRate=c.frameRate||null,a.pixelAspectRatio=c.pixelAspectRatio||null,a.videoBandwidth=c.bandwidth||null,a.hdr=c.hdr||null,a.colorGamut=c.colorGamut||null,a.videoLayout=c.videoLayout||null,g.includes(",")&&(a.channelsCount=c.channelsCount,a.audioSamplingRate=c.audioSamplingRate,a.spatialAudio=c.spatialAudio,a.originalLanguage=c.originalLanguage));b&&(a.audioId=b.id,a.originalAudioId=
174
174
  b.originalId,a.channelsCount=b.channelsCount,a.audioSamplingRate=b.audioSamplingRate,a.audioBandwidth=b.bandwidth||null,a.spatialAudio=b.spatialAudio,a.label=b.label,a.audioRoles=b.roles,a.accessibilityPurpose=b.accessibilityPurpose,a.originalLanguage=b.originalLanguage);return a}
@@ -182,12 +182,12 @@ originalVideoId:null,originalAudioId:null,originalTextId:null,originalImageId:nu
182
182
  function vf(a,b,c,d){var e=a,f=a.filter(function(k){return k.primary});f.length&&(e=f);var g=e.length?e[0].language:"";e=e.filter(function(k){return k.language==g});if(b){var h=Ke(De(b),a.map(function(k){return k.language}));h&&(e=a.filter(function(k){return De(k.language)==h}))}e=e.filter(function(k){return k.forced==d});if(c){if(a=wf(e,c),a.length)return a}else if(a=e.filter(function(k){return 0==k.roles.length}),a.length)return a;a=e.map(function(k){return k.roles}).reduce(ye,[]);return a.length?
183
183
  wf(e,a[0]):e}function wf(a,b){return a.filter(function(c){return c.roles.includes(b)})}function $e(a){return"audio"==a.type?"type=audio codecs="+a.codecs+" bandwidth="+a.bandwidth+" channelsCount="+a.channelsCount+" audioSamplingRate="+a.audioSamplingRate:"video"==a.type?"type=video codecs="+a.codecs+" bandwidth="+a.bandwidth+" frameRate="+a.frameRate+" width="+a.width+" height="+a.height:"unexpected stream type"}S("shaka.util.StreamUtils",Ne);Ne.meetsRestrictions=Re;
184
184
  var ef={},pf=0,hf=(new Map).set("image/svg+xml",!0).set("image/png",!0).set("image/jpeg",!0).set("image/jpg",!0),jf=(new Map).set("image/webp","data:image/webp;base64,UklGRjoAAABXRUJQVlA4IC4AAACyAgCdASoCAAIALmk0mk0iIiIiIgBoSygABc6WWgAA/veff/0PP8bA//LwYAAA").set("image/avif","data:image/avif;base64,AAAAIGZ0eXBhdmlmAAAAAGF2aWZtaWYxbWlhZk1BMUIAAADybWV0YQAAAAAAAAAoaGRscgAAAAAAAAAAcGljdAAAAAAAAAAAAAAAAGxpYmF2aWYAAAAADnBpdG0AAAAAAAEAAAAeaWxvYwAAAABEAAABAAEAAAABAAABGgAAAB0AAAAoaWluZgAAAAAAAQAAABppbmZlAgAAAAABAABhdjAxQ29sb3IAAAAAamlwcnAAAABLaXBjbwAAABRpc3BlAAAAAAAAAAIAAAACAAAAEHBpeGkAAAAAAwgICAAAAAxhdjFDgQ0MAAAAABNjb2xybmNseAACAAIAAYAAAAAXaXBtYQAAAAAAAAABAAEEAQKDBAAAACVtZGF0EgAKCBgANogQEAwgMg8f8D///8WfhwB8+ErK42A=");function xf(){var a=this;this.A=null;this.j=!1;this.i=new Va;this.F=new gb;navigator.connection&&navigator.connection.addEventListener&&this.F.D(navigator.connection,"change",function(){if(a.j&&a.g.useNetworkInformation){a.i=new Va;a.g&&a.i.configure(a.g.advanced);var b=a.chooseVariant();b&&navigator.onLine&&a.A(b,a.g.clearBufferSwitch,a.g.safeMarginSwitch)}});this.s=[];this.B=1;this.G=!1;this.h=this.o=this.g=this.l=null;this.C=new Sc(function(){if(a.j&&a.g.restrictToElementSize){var b=a.chooseVariant();
185
- b&&a.A(b,a.g.clearBufferSwitch,a.g.safeMarginSwitch)}});this.m=null}r=xf.prototype;r.stop=function(){this.A=null;this.j=!1;this.s=[];this.B=1;this.o=this.l=null;this.h&&(this.h.disconnect(),this.h=null);this.C.stop();this.m=null};r.release=function(){this.F.release();this.C=null};r.init=function(a){this.A=a};
186
- r.chooseVariant=function(){var a=Infinity,b=Infinity;if(this.g.restrictToScreenSize){var c=this.g.ignoreDevicePixelRatio?1:window.devicePixelRatio;a=window.screen.height*c;b=window.screen.width*c}this.h&&this.g.restrictToElementSize&&(c=this.g.ignoreDevicePixelRatio?1:window.devicePixelRatio,a=Math.min(a,this.o.clientHeight*c),b=Math.min(b,this.o.clientWidth*c));c=this.s.filter(function(l){return l&&!(l.audio&&l.audio.fastSwitching||l.video&&l.video.fastSwitching)});c.length||(c=this.s);var d=c;c.length!=
185
+ b&&a.A(b,a.g.clearBufferSwitch,a.g.safeMarginSwitch)}});this.m=null}q=xf.prototype;q.stop=function(){this.A=null;this.j=!1;this.s=[];this.B=1;this.o=this.l=null;this.h&&(this.h.disconnect(),this.h=null);this.C.stop();this.m=null};q.release=function(){this.F.release();this.C=null};q.init=function(a){this.A=a};
186
+ q.chooseVariant=function(){var a=Infinity,b=Infinity;if(this.g.restrictToScreenSize){var c=this.g.ignoreDevicePixelRatio?1:window.devicePixelRatio;a=window.screen.height*c;b=window.screen.width*c}this.h&&this.g.restrictToElementSize&&(c=this.g.ignoreDevicePixelRatio?1:window.devicePixelRatio,a=Math.min(a,this.o.clientHeight*c),b=Math.min(b,this.o.clientWidth*c));c=this.s.filter(function(l){return l&&!(l.audio&&l.audio.fastSwitching||l.video&&l.video.fastSwitching)});c.length||(c=this.s);var d=c;c.length!=
187
187
  this.s.length&&(d=this.s.filter(function(l){return l&&(l.audio&&l.audio.fastSwitching||l.video&&l.video.fastSwitching?!0:!1)}));c=Cf(this,this.g.restrictions,d,Infinity,Infinity);if(Infinity!=a||Infinity!=b){c=Df(c);c=t(c);for(var e=c.next();!e.done;e=c.next())if(e=e.value,e.height>=a&&e.width>=b){a=e.height;b=e.width;break}c=Cf(this,this.g.restrictions,d,a,b)}a=this.getBandwidthEstimate();d.length&&!c.length&&(c=Cf(this,null,d,Infinity,Infinity),c=[c[0]]);b=c[0]||null;for(d=0;d<c.length;d++){e=c[d];
188
- for(var f=isNaN(this.B)?1:Math.abs(this.B),g=f*e.bandwidth/this.g.bandwidthDowngradeTarget,h={bandwidth:Infinity},k=d+1;k<c.length;k++)if(e.bandwidth!=c[k].bandwidth){h=c[k];break}f=f*h.bandwidth/this.g.bandwidthUpgradeTarget;a>=g&&a<=f&&(b.bandwidth!=e.bandwidth||b.bandwidth==e.bandwidth&&b.video&&e.video&&(b.video.width<e.video.width||b.video.height<e.video.height))&&(b=e)}this.l=Date.now();return b};r.enable=function(){this.j=!0};r.disable=function(){this.j=!1};
189
- r.segmentDownloaded=function(a,b,c){a<this.g.cacheLoadThreshold||(this.i.sample(a,b),c&&null!=this.l&&this.j&&Ef(this))};r.trySuggestStreams=function(){null!=this.l&&this.j&&Ef(this)};r.getBandwidthEstimate=function(){var a=this.g.defaultBandwidthEstimate;navigator.connection&&navigator.connection.downlink&&this.g.useNetworkInformation&&(a=1E6*navigator.connection.downlink);a=this.i.getBandwidthEstimate(a);return this.m?this.m.getBandwidthEstimate(a):a};r.setVariants=function(a){this.s=a};
190
- r.playbackRateChanged=function(a){this.B=a};r.setMediaElement=function(a){var b=this;this.o=a;this.h&&(this.h.disconnect(),this.h=null);this.o&&"ResizeObserver"in window&&(this.h=new ResizeObserver(function(){b.C.Z(Ff)}),this.h.observe(this.o))};r.setCmsdManager=function(a){this.m=a};r.configure=function(a){this.g=a;this.i&&this.g&&this.i.configure(this.g.advanced)};
188
+ for(var f=isNaN(this.B)?1:Math.abs(this.B),g=f*e.bandwidth/this.g.bandwidthDowngradeTarget,h={bandwidth:Infinity},k=d+1;k<c.length;k++)if(e.bandwidth!=c[k].bandwidth){h=c[k];break}f=f*h.bandwidth/this.g.bandwidthUpgradeTarget;a>=g&&a<=f&&(b.bandwidth!=e.bandwidth||b.bandwidth==e.bandwidth&&b.video&&e.video&&(b.video.width<e.video.width||b.video.height<e.video.height))&&(b=e)}this.l=Date.now();return b};q.enable=function(){this.j=!0};q.disable=function(){this.j=!1};
189
+ q.segmentDownloaded=function(a,b,c){a<this.g.cacheLoadThreshold||(this.i.sample(a,b),c&&null!=this.l&&this.j&&Ef(this))};q.trySuggestStreams=function(){null!=this.l&&this.j&&Ef(this)};q.getBandwidthEstimate=function(){var a=this.g.defaultBandwidthEstimate;navigator.connection&&navigator.connection.downlink&&this.g.useNetworkInformation&&(a=1E6*navigator.connection.downlink);a=this.i.getBandwidthEstimate(a);return this.m?this.m.getBandwidthEstimate(a):a};q.setVariants=function(a){this.s=a};
190
+ q.playbackRateChanged=function(a){this.B=a};q.setMediaElement=function(a){var b=this;this.o=a;this.h&&(this.h.disconnect(),this.h=null);this.o&&"ResizeObserver"in window&&(this.h=new ResizeObserver(function(){b.C.Z(Ff)}),this.h.observe(this.o))};q.setCmsdManager=function(a){this.m=a};q.configure=function(a){this.g=a;this.i&&this.g&&this.i.configure(this.g.advanced)};
191
191
  function Ef(a){if(!a.G){var b=a.i;if(!(b.g>=b.i))return;a.G=!0;a.l-=1E3*(a.g.switchInterval-a.g.minTimeToSwitch)}Date.now()-a.l<1E3*a.g.switchInterval||(b=a.chooseVariant(),a.getBandwidthEstimate(),b&&a.A(b,a.g.clearBufferSwitch,a.g.safeMarginSwitch))}function Cf(a,b,c,d,e){if(a.m){var f=a.m.zg();f&&(c=c.filter(function(g){return g.bandwidth&&f?g.bandwidth<=f:!0}))}b&&(c=c.filter(function(g){return Re(g,b,{width:e,height:d})}));return c.sort(function(g,h){return g.bandwidth-h.bandwidth})}
192
192
  function Df(a){var b=[];a=t(a);for(var c=a.next();!c.done;c=a.next())(c=c.value.video)&&c.height&&c.width&&b.push({height:c.height,width:c.width});return b.sort(function(d,e){return d.width-e.width})}S("shaka.abr.SimpleAbrManager",xf);xf.prototype.configure=xf.prototype.configure;xf.prototype.setCmsdManager=xf.prototype.setCmsdManager;xf.prototype.setMediaElement=xf.prototype.setMediaElement;xf.prototype.playbackRateChanged=xf.prototype.playbackRateChanged;xf.prototype.setVariants=xf.prototype.setVariants;
193
193
  xf.prototype.getBandwidthEstimate=xf.prototype.getBandwidthEstimate;xf.prototype.trySuggestStreams=xf.prototype.trySuggestStreams;xf.prototype.segmentDownloaded=xf.prototype.segmentDownloaded;xf.prototype.disable=xf.prototype.disable;xf.prototype.enable=xf.prototype.enable;xf.prototype.chooseVariant=xf.prototype.chooseVariant;xf.prototype.init=xf.prototype.init;xf.prototype.release=xf.prototype.release;xf.prototype.stop=xf.prototype.stop;var Ff=1;S("shaka.config.AutoShowText",{NEVER:0,ALWAYS:1,IF_PREFERRED_TEXT_LANGUAGE:2,IF_SUBTITLES_MAY_BE_NEEDED:3});S("shaka.config.CodecSwitchingStrategy",{RELOAD:"reload",SMOOTH:"smooth"});function Gf(a,b,c,d){c=void 0===c?!0:c;d=void 0===d?!1:d;this.h=a;this.g=new Set([a]);b=b||[];a=t(b);for(b=a.next();!b.done;b=a.next())this.add(b.value,c,d)}Gf.prototype.add=function(a,b,c){return Hf(this.h,a,void 0===b?!0:b,void 0===c?!1:c)?(this.g.add(a),!0):!1};
@@ -205,26 +205,26 @@ function ig(a,b,c){try{var d=a(b);if(d&&d.promise&&d.abort)return c.resolve(d.pr
205
205
  function jg(a){var b=new U(a.type),c;for(c in a)Object.defineProperty(b,c,{value:a[c],writable:!0,enumerable:!0});return b}U.prototype.preventDefault=function(){this.cancelable&&(this.defaultPrevented=!0)};U.prototype.stopImmediatePropagation=function(){this.g=!0};U.prototype.stopPropagation=function(){};S("shaka.util.FakeEvent",U);
206
206
  var kg={ij:"abrstatuschanged",jj:"adaptation",kj:"audiotrackchanged",lj:"buffering",mj:"complete",nj:"downloadfailed",oj:"downloadheadersreceived",pj:"drmsessionupdate",rj:"emsg",Ij:"prft",Error:"error",sj:"expirationupdated",tj:"firstquartile",uj:"gapjumped",xj:"keystatuschanged",zj:"loaded",Aj:"loading",Cj:"manifestparsed",Dj:"manifestupdated",Ej:"mediaqualitychanged",Metadata:"metadata",Fj:"midpoint",Gj:"nospatialvideoinfo",Hj:"onstatechange",Jj:"ratechange",Lj:"segmentappended",Mj:"sessiondata",
207
207
  Nj:"spatialvideoinfo",Oj:"stalldetected",Pj:"started",Qj:"statechanged",Rj:"streaming",Sj:"textchanged",Tj:"texttrackvisibility",Uj:"thirdquartile",Vj:"timelineregionadded",Wj:"timelineregionenter",Xj:"timelineregionexit",Yj:"trackschanged",$j:"unloading",bk:"variantchanged"};function lg(){this.ya=new fb;this.le=this}lg.prototype.addEventListener=function(a,b){this.ya&&this.ya.push(a,b)};lg.prototype.removeEventListener=function(a,b){this.ya&&this.ya.remove(a,b)};lg.prototype.dispatchEvent=function(a){if(!this.ya)return!0;var b=this.ya.get(a.type)||[],c=this.ya.get("All");c&&(b=b.concat(c));b=t(b);for(c=b.next();!c.done;c=b.next()){c=c.value;a.target=this.le;a.currentTarget=this.le;try{c.handleEvent?c.handleEvent(a):c.call(this,a)}catch(d){}if(a.g)break}return a.defaultPrevented};
208
- lg.prototype.release=function(){this.ya=null};function mg(){this.g=[]}function ng(a,b){a.g.push(b.finally(function(){Nb(a.g,b)}))}mg.prototype.destroy=function(){for(var a=[],b=t(this.g),c=b.next();!c.done;c=b.next())c=c.value,c.promise.catch(function(){}),a.push(c.abort());this.g=[];return Promise.all(a)};function og(a,b,c,d,e,f){lg.call(this);this.i=!1;this.m=new mg;this.g=new Set;this.h=new Set;this.l=a||null;this.j=b||null;this.A=c||null;this.B=d||null;this.F=e||null;this.C=f||null;this.o=this.s=!1}na(og,lg);r=og.prototype;r.Pf=function(a){this.s=a};r.Qf=function(a){this.o=a};function pg(a,b,c,d){c=c||qg;var e=rg[a];if(!e||c>=e.priority)rg[a]={priority:c,he:b,Di:void 0===d?!1:d}}
209
- function sg(a,b){for(var c=t(a.g),d=c.next();!d.done;d=c.next())b.g.add(d.value);a=t(a.h);for(c=a.next();!c.done;c=a.next())b.h.add(c.value)}r.Gi=function(a){this.g.add(a)};r.bj=function(a){this.g.delete(a)};r.mg=function(){this.g.clear()};r.Hi=function(a){this.h.add(a)};r.cj=function(a){this.h.delete(a)};r.ng=function(){this.h.clear()};
210
- function tg(a,b,c){return{uris:a,method:"GET",body:null,headers:{},allowCrossSiteCredentials:!1,retryParameters:b,licenseRequestType:null,sessionId:null,drmInfo:null,initData:null,initDataType:null,streamDataCallback:void 0===c?null:c}}r.destroy=function(){this.i=!0;this.g.clear();this.h.clear();lg.prototype.release.call(this);return this.m.destroy()};
211
- r.request=function(a,b,c){var d=this,e=new ug;if(this.i){var f=Promise.reject(new T(2,7,7001));f.catch(function(){});return new vg(f,function(){return Promise.resolve()},e)}b.method=b.method||"GET";b.headers=b.headers||{};b.retryParameters=b.retryParameters?Le(b.retryParameters):$f();b.uris=Le(b.uris);f=wg(this,a,b,c);var g=f.Aa(function(){return xg(d,a,b,c,new Zf(b.retryParameters,!1),0,null,e)}),h=g.Aa(function(q){return yg(d,a,q,c)}),k=Date.now(),l=0;f.promise.then(function(){l=Date.now()-k},function(){});
212
- var m=0;g.promise.then(function(){m=Date.now()},function(){});var n=h.Aa(function(q){var p=Date.now()-m,w=q.response;w.timeMs+=l;w.timeMs+=p;q.ii||!d.l||w.fromCache||"HEAD"==b.method||a!=zg||d.l(w.timeMs,w.data.byteLength,Ag(c));d.C&&d.C(a,w,c);return w},function(q){q&&(q.severity=2);throw q;});f=new vg(n.promise,function(){return n.abort()},e);ng(this.m,f);return f};
208
+ lg.prototype.release=function(){this.ya=null};function mg(){this.g=[]}function ng(a,b){a.g.push(b.finally(function(){Nb(a.g,b)}))}mg.prototype.destroy=function(){for(var a=[],b=t(this.g),c=b.next();!c.done;c=b.next())c=c.value,c.promise.catch(function(){}),a.push(c.abort());this.g=[];return Promise.all(a)};function og(a,b,c,d,e,f){lg.call(this);this.i=!1;this.m=new mg;this.g=new Set;this.h=new Set;this.l=a||null;this.j=b||null;this.A=c||null;this.B=d||null;this.F=e||null;this.C=f||null;this.o=this.s=!1}na(og,lg);q=og.prototype;q.Pf=function(a){this.s=a};q.Qf=function(a){this.o=a};function pg(a,b,c,d){c=c||qg;var e=rg[a];if(!e||c>=e.priority)rg[a]={priority:c,he:b,Di:void 0===d?!1:d}}
209
+ function sg(a,b){for(var c=t(a.g),d=c.next();!d.done;d=c.next())b.g.add(d.value);a=t(a.h);for(c=a.next();!c.done;c=a.next())b.h.add(c.value)}q.Gi=function(a){this.g.add(a)};q.bj=function(a){this.g.delete(a)};q.mg=function(){this.g.clear()};q.Hi=function(a){this.h.add(a)};q.cj=function(a){this.h.delete(a)};q.ng=function(){this.h.clear()};
210
+ function tg(a,b,c){return{uris:a,method:"GET",body:null,headers:{},allowCrossSiteCredentials:!1,retryParameters:b,licenseRequestType:null,sessionId:null,drmInfo:null,initData:null,initDataType:null,streamDataCallback:void 0===c?null:c}}q.destroy=function(){this.i=!0;this.g.clear();this.h.clear();lg.prototype.release.call(this);return this.m.destroy()};
211
+ q.request=function(a,b,c){var d=this,e=new ug;if(this.i){var f=Promise.reject(new T(2,7,7001));f.catch(function(){});return new vg(f,function(){return Promise.resolve()},e)}b.method=b.method||"GET";b.headers=b.headers||{};b.retryParameters=b.retryParameters?Le(b.retryParameters):$f();b.uris=Le(b.uris);f=wg(this,a,b,c);var g=f.Aa(function(){return xg(d,a,b,c,new Zf(b.retryParameters,!1),0,null,e)}),h=g.Aa(function(p){return yg(d,a,p,c)}),k=Date.now(),l=0;f.promise.then(function(){l=Date.now()-k},function(){});
212
+ var m=0;g.promise.then(function(){m=Date.now()},function(){});var n=h.Aa(function(p){var r=Date.now()-m,u=p.response;u.timeMs+=l;u.timeMs+=r;p.ii||!d.l||u.fromCache||"HEAD"==b.method||a!=zg||d.l(u.timeMs,u.data.byteLength,Ag(c));d.C&&d.C(a,u,c);return u},function(p){p&&(p.severity=2);throw p;});f=new vg(n.promise,function(){return n.abort()},e);ng(this.m,f);return f};
213
213
  function wg(a,b,c,d){function e(h){f=f.Aa(function(){c.body&&(c.body=Ab(c.body));return h(b,c,d)})}var f=fg(void 0);a.B&&e(a.B);a=t(a.g);for(var g=a.next();!g.done;g=a.next())e(g.value);return f.Aa(void 0,function(h){if(h instanceof T&&7001==h.code)throw h;throw new T(2,1,1006,h);})}
214
- function xg(a,b,c,d,e,f,g,h){a.s&&(c.uris[f]=c.uris[f].replace("https://","http://"));a.o&&(c.uris[f]=c.uris[f].replace("http://","https://"));0<f&&a.F&&a.F(b,d,c.uris[f],c.uris[f-1]);var k=new tc(c.uris[f]),l=k.Bb,m=!1;l||(l=location.protocol,l=l.slice(0,-1),uc(k,l),c.uris[f]=k.toString());l=l.toLowerCase();var n=(l=rg[l])?l.he:null;if(!n)return dg(new T(2,1,1E3,k));var q=l.Di,p=null,w=null,u=!1,v=!1,A;return gg(ag(e)).Aa(function(){if(a.i)return eg();A=Date.now();var z=0;c.requestStartTime=Date.now();
215
- var D=n(c.uris[f],c,b,function(C,E,G){p&&p.stop();w&&w.Z(B/1E3);a.l&&b==zg&&(z++,c.packetNumber=z,a.l(C,E,Ag(d),c),m=!0,h.g=G)},function(C){a.j&&a.j(C,c,b);v=!0;c.timeToFirstByte=Date.now()-c.requestStartTime});if(!q)return D;var y=c.retryParameters.connectionTimeout;y&&(p=new Sc(function(){u=!0;D.abort()}),p.Z(y/1E3));var B=c.retryParameters.stallTimeout;B&&(w=new Sc(function(){u=!0;D.abort()}));return D}).Aa(function(z){p&&p.stop();w&&w.stop();void 0==z.timeMs&&(z.timeMs=Date.now()-A);var D={response:z,
216
- ii:m};!v&&a.j&&a.j(z.headers,c,b);return D},function(z){p&&p.stop();w&&w.stop();if(a.A){var D=null,y=0;z instanceof T&&(D=z,1001==z.code&&(y=z.data[1]));a.A(c,D,y,u)}if(a.i)return eg();u&&(z=new T(1,1,1003,c.uris[f],b));if(z instanceof T){if(7001==z.code)throw z;if(1010==z.code)throw g;if(1==z.severity)return D=(new Map).set("error",z),D=new U("retry",D),a.dispatchEvent(D),f=(f+1)%c.uris.length,xg(a,b,c,d,e,f,z,h)}throw z;})}
214
+ function xg(a,b,c,d,e,f,g,h){a.s&&(c.uris[f]=c.uris[f].replace("https://","http://"));a.o&&(c.uris[f]=c.uris[f].replace("http://","https://"));0<f&&a.F&&a.F(b,d,c.uris[f],c.uris[f-1]);var k=new tc(c.uris[f]),l=k.Bb,m=!1;l||(l=location.protocol,l=l.slice(0,-1),uc(k,l),c.uris[f]=k.toString());l=l.toLowerCase();var n=(l=rg[l])?l.he:null;if(!n)return dg(new T(2,1,1E3,k));var p=l.Di,r=null,u=null,v=!1,w=!1,A;return gg(ag(e)).Aa(function(){if(a.i)return eg();A=Date.now();var z=0;c.requestStartTime=Date.now();
215
+ var D=n(c.uris[f],c,b,function(C,E,G){r&&r.stop();u&&u.Z(B/1E3);a.l&&b==zg&&(z++,c.packetNumber=z,a.l(C,E,Ag(d),c),m=!0,h.g=G)},function(C){a.j&&a.j(C,c,b);w=!0;c.timeToFirstByte=Date.now()-c.requestStartTime});if(!p)return D;var y=c.retryParameters.connectionTimeout;y&&(r=new Sc(function(){v=!0;D.abort()}),r.Z(y/1E3));var B=c.retryParameters.stallTimeout;B&&(u=new Sc(function(){v=!0;D.abort()}));return D}).Aa(function(z){r&&r.stop();u&&u.stop();void 0==z.timeMs&&(z.timeMs=Date.now()-A);var D={response:z,
216
+ ii:m};!w&&a.j&&a.j(z.headers,c,b);return D},function(z){r&&r.stop();u&&u.stop();if(a.A){var D=null,y=0;z instanceof T&&(D=z,1001==z.code&&(y=z.data[1]));a.A(c,D,y,v)}if(a.i)return eg();v&&(z=new T(1,1,1003,c.uris[f],b));if(z instanceof T){if(7001==z.code)throw z;if(1010==z.code)throw g;if(1==z.severity)return D=(new Map).set("error",z),D=new U("retry",D),a.dispatchEvent(D),f=(f+1)%c.uris.length,xg(a,b,c,d,e,f,z,h)}throw z;})}
217
217
  function yg(a,b,c,d){var e=fg(void 0);a=t(a.h);for(var f=a.next(),g={};!f.done;g={Vg:void 0},f=a.next())g.Vg=f.value,e=e.Aa(function(h){return function(){var k=c.response;k.data&&(k.data=Ab(k.data));return(0,h.Vg)(b,k,d)}}(g));return e.Aa(function(){return c},function(h){var k=2;if(h instanceof T){if(7001==h.code)throw h;k=h.severity}throw new T(k,1,1007,h);})}function Ag(a){if(a){var b=a.segment;a=a.stream;if(b&&a&&a.fastSwitching&&b.s)return!1}return!0}S("shaka.net.NetworkingEngine",og);
218
218
  og.prototype.request=og.prototype.request;og.prototype.destroy=og.prototype.destroy;og.makeRequest=tg;og.defaultRetryParameters=function(){return $f()};og.prototype.clearAllResponseFilters=og.prototype.ng;og.prototype.unregisterResponseFilter=og.prototype.cj;og.prototype.registerResponseFilter=og.prototype.Hi;og.prototype.clearAllRequestFilters=og.prototype.mg;og.prototype.unregisterRequestFilter=og.prototype.bj;og.prototype.registerRequestFilter=og.prototype.Gi;og.unregisterScheme=function(a){delete rg[a]};
219
219
  og.registerScheme=pg;og.prototype.setForceHTTPS=og.prototype.Qf;og.prototype.setForceHTTP=og.prototype.Pf;function ug(){this.g=0}og.NumBytesRemainingClass=ug;function vg(a,b,c){cg.call(this,a,b);this.h=c}na(vg,cg);og.PendingRequest=vg;var zg=1;og.RequestType={MANIFEST:0,SEGMENT:zg,LICENSE:2,APP:3,TIMING:4,SERVER_CERTIFICATE:5,KEY:6,ADS:7,CONTENT_STEERING:8};og.AdvancedRequestType={INIT_SEGMENT:0,MEDIA_SEGMENT:1,MEDIA_PLAYLIST:2,MASTER_PLAYLIST:3,MPD:4,MSS:5,MPD_PATCH:6};var qg=3;
220
- og.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:qg};var rg={};function Bg(a){this.g=!1;this.h=new bg;this.i=a}Bg.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 Cg(a,b){if(a.g){if(b instanceof T&&7003==b.code)throw b;throw new T(2,7,7003,b);}};function Dg(a,b){var c=[];a=t(a);for(var d=a.next();!d.done;d=a.next())c.push(b(d.value));return c}function Eg(a,b){a=t(a);for(var c=a.next();!c.done;c=a.next())if(!b(c.value))return!1;return!0};function Fg(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 Hg(a){var b={};a.forEach(function(c,d){b[d]=c});return b};function Ig(a,b){this.h=Eb(a);this.i=b==Jg;this.g=0}r=Ig.prototype;r.pa=function(){return this.g<this.h.byteLength};r.va=function(){return this.g};r.getLength=function(){return this.h.byteLength};r.U=function(){try{var a=this.h.getUint8(this.g);this.g+=1;return a}catch(b){throw Kg();}};r.na=function(){try{var a=this.h.getUint16(this.g,this.i);this.g+=2;return a}catch(b){throw Kg();}};r.R=function(){try{var a=this.h.getUint32(this.g,this.i);this.g+=4;return a}catch(b){throw Kg();}};
221
- r.Sg=function(){try{var a=this.h.getInt32(this.g,this.i);this.g+=4;return a}catch(b){throw Kg();}};r.Mc=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 Kg();}if(2097151<b)throw new T(2,3,3001);this.g+=8;return b*Math.pow(2,32)+a};r.qb=function(a){if(this.g+a>this.h.byteLength)throw Kg();var b=zb(this.h,this.g,a);this.g+=a;return b};
222
- r.skip=function(a){if(this.g+a>this.h.byteLength)throw Kg();this.g+=a};r.Oi=function(a){if(this.g<a)throw Kg();this.g-=a};r.seek=function(a){if(0>a||a>this.h.byteLength)throw Kg();this.g=a};r.qc=function(){for(var a=this.g;this.pa()&&0!=this.h.getUint8(this.g);)this.g+=1;a=zb(this.h,a,this.g-a);this.g+=1;return ud(a)};function Kg(){return new T(2,3,3E3)}S("shaka.util.DataViewReader",Ig);Ig.prototype.readTerminatedString=Ig.prototype.qc;Ig.prototype.seek=Ig.prototype.seek;Ig.prototype.rewind=Ig.prototype.Oi;
223
- Ig.prototype.skip=Ig.prototype.skip;Ig.prototype.readBytes=Ig.prototype.qb;Ig.prototype.readUint64=Ig.prototype.Mc;Ig.prototype.readInt32=Ig.prototype.Sg;Ig.prototype.readUint32=Ig.prototype.R;Ig.prototype.readUint16=Ig.prototype.na;Ig.prototype.readUint8=Ig.prototype.U;Ig.prototype.getLength=Ig.prototype.getLength;Ig.prototype.getPosition=Ig.prototype.va;Ig.prototype.hasMoreData=Ig.prototype.pa;var Jg=1;Ig.Endianness={BIG_ENDIAN:0,LITTLE_ENDIAN:Jg};function Lg(){this.i=[];this.h=[];this.g=!1}r=Lg.prototype;r.box=function(a,b){a=Mg(a);this.i[a]=Ng;this.h[a]=b;return this};r.S=function(a,b){a=Mg(a);this.i[a]=Og;this.h[a]=b;return this};r.stop=function(){this.g=!0};r.parse=function(a,b,c){a=new Ig(a,0);for(this.g=!1;a.pa()&&!this.g;)this.Jc(0,a,b,c)};
224
- r.Jc=function(a,b,c,d){var e=b.va();if(d&&e+8>b.getLength())this.g=!0;else{var f=b.R(),g=b.R(),h=Pg(g),k=!1;switch(f){case 0:f=b.getLength()-e;break;case 1:if(d&&b.va()+8>b.getLength()){this.g=!0;return}f=b.Mc();k=!0}var l=this.h[g];if(l){var m=null,n=null;if(this.i[g]==Og){if(d&&b.va()+4>b.getLength()){this.g=!0;return}n=b.R();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.va(),b=0<d?b.qb(d):new Uint8Array(0),b=new Ig(b,0),l({name:h,parser:this,
225
- partialOkay:c||!1,version:m,flags:n,reader:b,size:f,start:e+a,has64BitSize:k}))}else b.skip(Math.min(e+f-b.va(),b.getLength()-b.va()))}};function Qg(a){for(var b=Rg(a);a.reader.pa()&&!a.parser.g;)a.parser.Jc(a.start+b,a.reader,a.partialOkay)}function Sg(a){for(var b=Rg(a),c=a.reader.R(),d=0;d<c&&(a.parser.Jc(a.start+b,a.reader,a.partialOkay),!a.parser.g);d++);}function Tg(a){var b=Rg(a);for(a.reader.skip(78);a.reader.pa()&&!a.parser.g;)a.parser.Jc(a.start+b,a.reader,a.partialOkay)}
226
- function Wg(a){var b=Rg(a);a.reader.skip(8);var c=a.reader.na();a.reader.skip(6);2==c?a.reader.skip(48):a.reader.skip(12);for(1==c&&a.reader.skip(16);a.reader.pa()&&!a.parser.g;)a.parser.Jc(a.start+b,a.reader,a.partialOkay)}function Xg(a){return function(b){a(b.reader.qb(b.reader.getLength()-b.reader.va()))}}function Mg(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 Pg(a){return String.fromCharCode(a>>24&255,a>>16&255,a>>8&255,a&255)}
227
- function Rg(a){return 8+(a.has64BitSize?8:0)+(null!=a.flags?4:0)}S("shaka.util.Mp4Parser",Lg);Lg.headerSize=Rg;Lg.typeToString=Pg;Lg.allData=Xg;Lg.audioSampleEntry=Wg;Lg.visualSampleEntry=Tg;Lg.sampleDescription=Sg;Lg.children=Qg;Lg.prototype.parseNext=Lg.prototype.Jc;Lg.prototype.parse=Lg.prototype.parse;Lg.prototype.stop=Lg.prototype.stop;Lg.prototype.fullBox=Lg.prototype.S;Lg.prototype.box=Lg.prototype.box;var Ng=0,Og=1;function Yg(a){var b=this;this.g=[];this.h=[];this.data=[];(new Lg).box("moov",Qg).box("moof",Qg).S("pssh",function(c){if(!(1<c.version)){var d=zb(c.reader.h,-12,c.size);b.data.push(d);b.g.push(Id(c.reader.qb(16)));if(0<c.version){d=c.reader.R();for(var e=0;e<d;e++){var f=Id(c.reader.qb(16));b.h.push(f)}}}}).parse(a)}
220
+ og.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:qg};var rg={};function Bg(a){this.g=!1;this.h=new bg;this.i=a}Bg.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 Cg(a,b){if(a.g){if(b instanceof T&&7003==b.code)throw b;throw new T(2,7,7003,b);}};function Dg(a,b){var c=[];a=t(a);for(var d=a.next();!d.done;d=a.next())c.push(b(d.value));return c}function Eg(a,b){a=t(a);for(var c=a.next();!c.done;c=a.next())if(!b(c.value))return!1;return!0};function Fg(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 Hg(a){var b={};a.forEach(function(c,d){b[d]=c});return b};function Ig(a,b){this.h=Eb(a);this.i=b==Jg;this.g=0}q=Ig.prototype;q.pa=function(){return this.g<this.h.byteLength};q.va=function(){return this.g};q.getLength=function(){return this.h.byteLength};q.U=function(){try{var a=this.h.getUint8(this.g);this.g+=1;return a}catch(b){throw Kg();}};q.na=function(){try{var a=this.h.getUint16(this.g,this.i);this.g+=2;return a}catch(b){throw Kg();}};q.R=function(){try{var a=this.h.getUint32(this.g,this.i);this.g+=4;return a}catch(b){throw Kg();}};
221
+ q.Sg=function(){try{var a=this.h.getInt32(this.g,this.i);this.g+=4;return a}catch(b){throw Kg();}};q.Nc=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 Kg();}if(2097151<b)throw new T(2,3,3001);this.g+=8;return b*Math.pow(2,32)+a};q.qb=function(a){if(this.g+a>this.h.byteLength)throw Kg();var b=zb(this.h,this.g,a);this.g+=a;return b};
222
+ q.skip=function(a){if(this.g+a>this.h.byteLength)throw Kg();this.g+=a};q.Oi=function(a){if(this.g<a)throw Kg();this.g-=a};q.seek=function(a){if(0>a||a>this.h.byteLength)throw Kg();this.g=a};q.qc=function(){for(var a=this.g;this.pa()&&0!=this.h.getUint8(this.g);)this.g+=1;a=zb(this.h,a,this.g-a);this.g+=1;return ud(a)};function Kg(){return new T(2,3,3E3)}S("shaka.util.DataViewReader",Ig);Ig.prototype.readTerminatedString=Ig.prototype.qc;Ig.prototype.seek=Ig.prototype.seek;Ig.prototype.rewind=Ig.prototype.Oi;
223
+ Ig.prototype.skip=Ig.prototype.skip;Ig.prototype.readBytes=Ig.prototype.qb;Ig.prototype.readUint64=Ig.prototype.Nc;Ig.prototype.readInt32=Ig.prototype.Sg;Ig.prototype.readUint32=Ig.prototype.R;Ig.prototype.readUint16=Ig.prototype.na;Ig.prototype.readUint8=Ig.prototype.U;Ig.prototype.getLength=Ig.prototype.getLength;Ig.prototype.getPosition=Ig.prototype.va;Ig.prototype.hasMoreData=Ig.prototype.pa;var Jg=1;Ig.Endianness={BIG_ENDIAN:0,LITTLE_ENDIAN:Jg};function Lg(){this.i=[];this.h=[];this.g=!1}q=Lg.prototype;q.box=function(a,b){a=Mg(a);this.i[a]=Ng;this.h[a]=b;return this};q.S=function(a,b){a=Mg(a);this.i[a]=Og;this.h[a]=b;return this};q.stop=function(){this.g=!0};q.parse=function(a,b,c){a=new Ig(a,0);for(this.g=!1;a.pa()&&!this.g;)this.Kc(0,a,b,c)};
224
+ q.Kc=function(a,b,c,d){var e=b.va();if(d&&e+8>b.getLength())this.g=!0;else{var f=b.R(),g=b.R(),h=Pg(g),k=!1;switch(f){case 0:f=b.getLength()-e;break;case 1:if(d&&b.va()+8>b.getLength()){this.g=!0;return}f=b.Nc();k=!0}var l=this.h[g];if(l){var m=null,n=null;if(this.i[g]==Og){if(d&&b.va()+4>b.getLength()){this.g=!0;return}n=b.R();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.va(),b=0<d?b.qb(d):new Uint8Array(0),b=new Ig(b,0),l({name:h,parser:this,
225
+ partialOkay:c||!1,version:m,flags:n,reader:b,size:f,start:e+a,has64BitSize:k}))}else b.skip(Math.min(e+f-b.va(),b.getLength()-b.va()))}};function Qg(a){for(var b=Rg(a);a.reader.pa()&&!a.parser.g;)a.parser.Kc(a.start+b,a.reader,a.partialOkay)}function Sg(a){for(var b=Rg(a),c=a.reader.R(),d=0;d<c&&(a.parser.Kc(a.start+b,a.reader,a.partialOkay),!a.parser.g);d++);}function Tg(a){var b=Rg(a);for(a.reader.skip(78);a.reader.pa()&&!a.parser.g;)a.parser.Kc(a.start+b,a.reader,a.partialOkay)}
226
+ function Wg(a){var b=Rg(a);a.reader.skip(8);var c=a.reader.na();a.reader.skip(6);2==c?a.reader.skip(48):a.reader.skip(12);for(1==c&&a.reader.skip(16);a.reader.pa()&&!a.parser.g;)a.parser.Kc(a.start+b,a.reader,a.partialOkay)}function Xg(a){return function(b){a(b.reader.qb(b.reader.getLength()-b.reader.va()))}}function Mg(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 Pg(a){return String.fromCharCode(a>>24&255,a>>16&255,a>>8&255,a&255)}
227
+ function Rg(a){return 8+(a.has64BitSize?8:0)+(null!=a.flags?4:0)}S("shaka.util.Mp4Parser",Lg);Lg.headerSize=Rg;Lg.typeToString=Pg;Lg.allData=Xg;Lg.audioSampleEntry=Wg;Lg.visualSampleEntry=Tg;Lg.sampleDescription=Sg;Lg.children=Qg;Lg.prototype.parseNext=Lg.prototype.Kc;Lg.prototype.parse=Lg.prototype.parse;Lg.prototype.stop=Lg.prototype.stop;Lg.prototype.fullBox=Lg.prototype.S;Lg.prototype.box=Lg.prototype.box;var Ng=0,Og=1;function Yg(a){var b=this;this.g=[];this.h=[];this.data=[];(new Lg).box("moov",Qg).box("moof",Qg).S("pssh",function(c){if(!(1<c.version)){var d=zb(c.reader.h,-12,c.size);b.data.push(d);b.g.push(Id(c.reader.qb(16)));if(0<c.version){d=c.reader.R();for(var e=0;e<d;e++){var f=Id(c.reader.qb(16));b.h.push(f)}}}}).parse(a)}
228
228
  function Zg(a,b,c,d){var e=a.length,f=b.length+16+e;0<d&&(f+=4+16*c.size);var g=new Uint8Array(f),h=Eb(g),k=0;h.setUint32(k,f);k+=4;h.setUint32(k,1886614376);k+=4;1>d?h.setUint32(k,0):h.setUint32(k,16777216);k+=4;g.set(b,k);k+=b.length;if(0<d)for(h.setUint32(k,c.size),k+=4,b=t(c),c=b.next();!c.done;c=b.next())c=Hd(c.value),g.set(c,k),k+=c.length;h.setUint32(k,e);g.set(a,k+4);return g};/*
229
229
  @license
230
230
  tXml
@@ -233,8 +233,8 @@ function Zg(a,b,c,d){var e=a.length,f=b.length+16+e;0<d&&(f+=4+16*c.size);var g=
233
233
  */
234
234
  function $g(a,b){a=yd(a);return ah(a,b)}function ah(a,b){a=bh(a);return!b&&a.length?a[0]:(a=a.find(function(c){return c.tagName===b}))?a:null}function ch(a){return dh.has(a)?dh.get(a):""}
235
235
  function bh(a){function b(e,f){f=void 0===f?!1:f;for(var g=[];a[d];)if(60==a.charCodeAt(d)){if(47===a.charCodeAt(d+1)){f=d+2;d=a.indexOf(">",d);f=a.substring(f,d);var h=f.indexOf(e);if(-1==h){var k=e.indexOf(".");0<k&&(h=f.indexOf(e.substring(0,k)))}if(-1==h)throw e=a.substring(0,d).split("\n"),Error("Unexpected close tag\nLine: "+(e.length-1)+"\nColumn: "+(e[e.length-1].length+1)+"\nChar: "+a[d]);d+1&&(d+=1);break}else if(33===a.charCodeAt(d+1)){if(45==a.charCodeAt(d+2)){for(;-1!==d&&(62!==a.charCodeAt(d)||
236
- 45!=a.charCodeAt(d-1)||45!=a.charCodeAt(d-2)||-1==d);)d=a.indexOf(">",d+1);-1===d&&(d=a.length)}else if(91===a.charCodeAt(d+2)&&91===a.charCodeAt(d+8)&&"cdata"===a.substr(d+3,5).toLowerCase()){h=a.indexOf("]]\x3e",d);-1==h?(g.push(a.substr(d+9)),d=a.length):(g.push(a.substring(d+9,h)),d=h+3);continue}d++;continue}a:{k=f;d++;var l=c(),m={};for(h=[];62!==a.charCodeAt(d)&&a[d];){var n=a.charCodeAt(d);if(64<n&&91>n||96<n&&123>n){n=c();for(var q=a.charCodeAt(d);q&&39!==q&&34!==q&&!(64<q&&91>q||96<q&&123>
237
- q)&&62!==q;)d++,q=a.charCodeAt(d);var p=d+1;d=a.indexOf(a[d],p);p=a.slice(p,d);if(39===q||34===q){if(-1===d){k={tagName:l,attributes:m,children:h,parent:null};for(l=0;l<h.length;l++)"string"!==typeof h[l]&&(h[l].parent=k);h=k;break a}}else p=null,d--;if(n.startsWith("xmlns:")){q=p;var w=n.split(":")[1];dh.set(q,w);eh.set(w,q)}"tt"===l&&"xml:space"===n&&"preserve"===p&&(k=!0);m[n]=p}d++}47!==a.charCodeAt(d-1)?(d++,h=b(l,k)):d++;k={tagName:l,attributes:m,children:h,parent:null};l=h.length;for(m=0;m<
236
+ 45!=a.charCodeAt(d-1)||45!=a.charCodeAt(d-2)||-1==d);)d=a.indexOf(">",d+1);-1===d&&(d=a.length)}else if(91===a.charCodeAt(d+2)&&91===a.charCodeAt(d+8)&&"cdata"===a.substr(d+3,5).toLowerCase()){h=a.indexOf("]]\x3e",d);-1==h?(g.push(a.substr(d+9)),d=a.length):(g.push(a.substring(d+9,h)),d=h+3);continue}d++;continue}a:{k=f;d++;var l=c(),m={};for(h=[];62!==a.charCodeAt(d)&&a[d];){var n=a.charCodeAt(d);if(64<n&&91>n||96<n&&123>n){n=c();for(var p=a.charCodeAt(d);p&&39!==p&&34!==p&&!(64<p&&91>p||96<p&&123>
237
+ p)&&62!==p;)d++,p=a.charCodeAt(d);var r=d+1;d=a.indexOf(a[d],r);r=a.slice(r,d);if(39===p||34===p){if(-1===d){k={tagName:l,attributes:m,children:h,parent:null};for(l=0;l<h.length;l++)"string"!==typeof h[l]&&(h[l].parent=k);h=k;break a}}else r=null,d--;if(n.startsWith("xmlns:")){p=r;var u=n.split(":")[1];dh.set(p,u);eh.set(u,p)}"tt"===l&&"xml:space"===n&&"preserve"===r&&(k=!0);m[n]=r}d++}47!==a.charCodeAt(d-1)?(d++,h=b(l,k)):d++;k={tagName:l,attributes:m,children:h,parent:null};l=h.length;for(m=0;m<
238
238
  l;m++)n=h[m],"string"!==typeof n?n.parent=k:m==l-1&&"\n"==n&&h.pop();h=k}g.push(h);if("string"===typeof h)break;"?"===h.tagName[0]&&h.children&&(g.push.apply(g,x(h.children)),h.children=[])}else h=d,d=a.indexOf("<",d)-1,-2===d&&(d=a.length),h=a.slice(h,d+1),f?0<h.length&&g.push(h):g.length&&1==h.length&&"\n"==h[0]?g.push(h):0<h.trim().length&&g.push(h),d++;return g}function c(){for(var e=d;-1==="\r\n\t>/= ".indexOf(a[d])&&a[d];)d++;return a.slice(e,d)}var d=0;return b("")}
239
239
  function fh(a){return"string"===typeof a}function gh(a){var b=[];if(!a.children)return[];a=t(a.children);for(var c=a.next();!c.done;c=a.next())c=c.value,"string"!==typeof c&&b.push(c);return b}function hh(a,b){var c=[];if(!a.children)return[];a=t(a.children);for(var d=a.next();!d.done;d=a.next())d=d.value,d.tagName===b&&c.push(d);return c}function ih(a){if("string"===typeof a)return Cd(a);a=a.children.reduce(function(b,c){return"string"===typeof c?b+c:b},"");return""===a?null:Cd(a)}
240
240
  function jh(a){if(!Array.from(a.children).every(function(b){return"string"===typeof b}))return null;(a=ih(a))&&(a=a.trim());return a}function kh(a,b,c){c=void 0===c?[]:c;a.tagName===b&&c.push(a);if(a.children){a=t(a.children);for(var d=a.next();!d.done;d=a.next())kh(d.value,b,c)}return c}function lh(a,b){a=hh(a,b);return 1!=a.length?null:a[0]}function mh(a,b,c){a=nh(a,b,c);return 1!=a.length?null:a[0]}
@@ -247,52 +247,52 @@ null})}else c.startsWith("@")&&b.length&&(b[b.length-1].Sb=c.slice(1))}return b}
247
247
  function Bh(a,b){var c=Ah(b.attributes.sel||"");if(c.length){var d=c[c.length-1],e=b.attributes.pos||null;c=d.position;null==c&&(null!==d.t&&(c=Ch(a,"t",d.t)),null!==d.n&&(c=Ch(a,"n",d.n)));null===c?c="prepend"===e?0:a.length:"prepend"===e?--c:"after"===e&&++c;e=b.tagName;(d=d.Sb)&&a[c]?Dh(a[c],e,d,jh(b)||""):("remove"!==e&&"replace"!==e||a.splice(c,1),"add"!==e&&"replace"!==e||a.splice.apply(a,[c,0].concat(x(b.children))))}}
248
248
  function Ch(a,b,c){var d=0;a=t(a);for(var e=a.next();!e.done;e=a.next()){if(Number(e.value.attributes[b])===c)return d;d++}return null}function Dh(a,b,c,d){if("remove"===b)delete a.attributes[c];else if("add"===b||"replace"===b)a.attributes[c]=d}
249
249
  function Eh(a){var b="",c=a.tagName.split(":");0<c.length&&(b=c[0],b=eh.has(b)?eh.get(b):"");b=document.createElementNS(b,a.tagName);for(var d in a.attributes)b.setAttribute(d,a.attributes[d]);a=t(a.children);for(d=a.next();!d.done;d=a.next())d=d.value,c=void 0,"string"==typeof d?c=new Text(d):c=Eh(d),b.appendChild(c);return b}
250
- function Fh(a){if(!a)return null;var b={tagName:a.tagName,attributes:Me(a.attributes),children:[],parent:null};a=t(a.children);for(var c=a.next();!c.done;c=a.next())c=c.value,"string"===typeof c?b.children.push(c):(c=Fh(c),c.parent=b,b.children.push(c));return b}var dh=new Map,eh=new Map;function Gh(a){var b=this;this.C=a;this.H=new Set;this.m=this.s=null;this.fa=this.da=!1;this.I=0;this.g=null;this.B=new gb;this.i=new Map;this.A=new Map;this.l=new bg;this.h=null;this.o=function(c){2==c.severity&&b.l.reject(c);a.onError(c)};this.Y=new Map;this.ea=new Map;this.L=new Sc(function(){return Hh(b)});this.O=!1;this.N=[];this.T=!1;this.K=new Sc(function(){Ih(b)});this.l.catch(function(){});this.j=new Bg(function(){return Jh(b)});this.ba=!1;this.F=this.G=null}r=Gh.prototype;r.destroy=function(){return this.j.destroy()};
251
- function Jh(a){return O(function(b){switch(b.g){case 1:return a.B.release(),a.B=null,a.l.reject(),a.K.stop(),a.K=null,a.L.stop(),a.L=null,F(b,Kh(a),2);case 2:if(!a.m){b.u(3);break}ra(b,4);return F(b,a.m.setMediaKeys(null),6);case 6:ta(b,5);break;case 4:ua(b);case 5:a.m=null;case 3:a.g=null,a.H.clear(),a.s=null,a.A=new Map,a.h=null,a.o=function(){},a.C=null,a.ba=!1,a.G=null,H(b)}})}r.configure=function(a){this.h=a;this.K&&this.K.Ra(this.h.updateExpirationTime)};
250
+ function Fh(a){if(!a)return null;var b={tagName:a.tagName,attributes:Me(a.attributes),children:[],parent:null};a=t(a.children);for(var c=a.next();!c.done;c=a.next())c=c.value,"string"===typeof c?b.children.push(c):(c=Fh(c),c.parent=b,b.children.push(c));return b}var dh=new Map,eh=new Map;function Gh(a){var b=this;this.C=a;this.H=new Set;this.m=this.s=null;this.fa=this.da=!1;this.I=0;this.g=null;this.B=new gb;this.i=new Map;this.A=new Map;this.l=new bg;this.h=null;this.o=function(c){2==c.severity&&b.l.reject(c);a.onError(c)};this.Y=new Map;this.ea=new Map;this.L=new Sc(function(){return Hh(b)});this.O=!1;this.N=[];this.T=!1;this.K=new Sc(function(){Ih(b)});this.l.catch(function(){});this.j=new Bg(function(){return Jh(b)});this.ba=!1;this.F=this.G=null}q=Gh.prototype;q.destroy=function(){return this.j.destroy()};
251
+ function Jh(a){return O(function(b){switch(b.g){case 1:return a.B.release(),a.B=null,a.l.reject(),a.K.stop(),a.K=null,a.L.stop(),a.L=null,F(b,Kh(a),2);case 2:if(!a.m){b.u(3);break}ra(b,4);return F(b,a.m.setMediaKeys(null),6);case 6:ta(b,5);break;case 4:ua(b);case 5:a.m=null;case 3:a.g=null,a.H.clear(),a.s=null,a.A=new Map,a.h=null,a.o=function(){},a.C=null,a.ba=!1,a.G=null,H(b)}})}q.configure=function(a){this.h=a;this.K&&this.K.Ra(this.h.updateExpirationTime)};
252
252
  function Lh(a,b,c){a.fa=!0;a.A=new Map;a.O=c;return Mh(a,b)}function Nh(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.O=0<a.A.size;return Mh(a,b)}
253
253
  function Oh(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 Ph(a,g,[])}
254
- function Mh(a,b){var c,d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y;return O(function(B){if(1==B.g){if(c=Qh(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(C){return C.video&&C.video.drmInfos.length||C.audio&&C.audio.drmInfos.length?!0:!1});g||(h=Fg(a.h.servers),Rh(b,h));k=new Set;l=t(b);for(m=l.next();!m.done;m=l.next())for(n=m.value,q=Sh(n),p=t(q),w=p.next();!w.done;w=p.next())u=w.value,k.add(u);v=t(k);for(A=v.next();!A.done;A=
255
- v.next())z=A.value,Th(z,Fg(a.h.servers),Fg(a.h.advanced||{}),a.h.keySystemsMapping);return F(B,Ye(b,a.O,a.ba,a.h.preferredKeySystems),2)}Cg(a.j);D=g||Object.keys(a.h.servers).length;if(!D)return a.da=!0,B.return(Promise.resolve());y=Ph(a,void 0,b);return B.return(g?y:y.catch(function(){}))})}
254
+ function Mh(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y;return O(function(B){if(1==B.g){if(c=Qh(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(C){return C.video&&C.video.drmInfos.length||C.audio&&C.audio.drmInfos.length?!0:!1});g||(h=Fg(a.h.servers),Rh(b,h));k=new Set;l=t(b);for(m=l.next();!m.done;m=l.next())for(n=m.value,p=Sh(n),r=t(p),u=r.next();!u.done;u=r.next())v=u.value,k.add(v);w=t(k);for(A=w.next();!A.done;A=
255
+ w.next())z=A.value,Th(z,Fg(a.h.servers),Fg(a.h.advanced||{}),a.h.keySystemsMapping);return F(B,Ye(b,a.O,a.ba,a.h.preferredKeySystems),2)}Cg(a.j);D=g||Object.keys(a.h.servers).length;if(!D)return a.da=!0,B.return(Promise.resolve());y=Ph(a,void 0,b);return B.return(g?y:y.catch(function(){}))})}
256
256
  function Uh(a){var b;return O(function(c){switch(c.g){case 1:if(a.m.mediaKeys)return c.return();if(!a.G){c.u(2);break}return F(c,a.G,3);case 3:return Cg(a.j),c.return();case 2:return ra(c,4),a.G=a.m.setMediaKeys(a.s),F(c,a.G,6);case 6:ta(c,5);break;case 4:b=ua(c),a.o(new T(2,6,6003,b.message));case 5:Cg(a.j),H(c)}})}function Vh(a,b){return O(function(c){if(1==c.g)return F(c,Uh(a),2);Wh(a,b.initDataType,zb(b.initData));H(c)})}
257
- r.Rb=function(a){var b=this;return O(function(c){if(1==c.g){if(!b.s)return b.B.ja(a,"encrypted",function(){b.o(new T(2,6,6010))}),c.return();b.m=a;b.B.ja(b.m,"play",function(){for(var d=t(b.N),e=d.next();!e.done;e=d.next())Xh(b,e.value);b.T=!0;b.N=[]});"webkitCurrentPlaybackTargetIsWireless"in b.m&&b.B.D(b.m,"webkitcurrentplaybacktargetiswirelesschanged",function(){return Kh(b)});b.F=b.g?b.g.initData.find(function(d){return 0<d.initData.length})||null:null;return b.F||"com.apple.fps"!==b.g.keySystem||
257
+ q.Rb=function(a){var b=this;return O(function(c){if(1==c.g){if(!b.s)return b.B.ja(a,"encrypted",function(){b.o(new T(2,6,6010))}),c.return();b.m=a;b.B.ja(b.m,"play",function(){for(var d=t(b.N),e=d.next();!e.done;e=d.next())Xh(b,e.value);b.T=!0;b.N=[]});"webkitCurrentPlaybackTargetIsWireless"in b.m&&b.B.D(b.m,"webkitcurrentplaybacktargetiswirelesschanged",function(){return Kh(b)});b.F=b.g?b.g.initData.find(function(d){return 0<d.initData.length})||null:null;return b.F||"com.apple.fps"!==b.g.keySystem||
258
258
  b.A.size?F(c,Uh(b),2):c.u(2)}Yh(b).catch(function(){});b.F||b.A.size||b.h.parseInbandPsshEnabled||b.B.D(b.m,"encrypted",function(d){return Vh(b,d)});H(c)})};
259
259
  function Zh(a){var b,c,d,e,f;return O(function(g){switch(g.g){case 1:if(!a.s||!a.g)return g.return();if(!a.g.serverCertificateUri||a.g.serverCertificate&&a.g.serverCertificate.length){g.u(2);break}b=tg([a.g.serverCertificateUri],a.h.retryParameters);ra(g,3);c=a.C.Lb.request(5,b);return F(g,c.promise,5);case 5:d=g.h;a.g.serverCertificate=zb(d.data);ta(g,4);break;case 3:throw e=ua(g),new T(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();
260
260
  ra(g,6);return F(g,a.s.setServerCertificate(a.g.serverCertificate),8);case 8:ta(g,0);break;case 6:throw f=ua(g),new T(2,6,6004,f.message);}})}function $h(a,b){var c,d,e;return O(function(f){if(1==f.g)return F(f,ai(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.kb=new bg,d.push(e.kb);d.push(c.remove());return F(f,Promise.all(d),3)}a.i.delete(c);H(f)})}
261
261
  function Yh(a){var b,c,d,e,f;return O(function(g){if(1==g.g){if(!a.A.size)return g.u(2);a.A.forEach(function(h,k){ai(a,k,h)});return F(g,a.l,3)}if(2!=g.g){b=a.g&&a.g.keyIds||new Set([]);if(0<b.size&&bi(a))return g.return(a.l);a.l=new bg;a.l.catch(function(){})}c=(a.g?a.g.initData:[])||[];d=t(c);for(e=d.next();!e.done;e=d.next())f=e.value,Wh(a,f.initDataType,f.initData);ci(a)&&a.l.resolve();return g.return(a.l)})}
262
262
  function Wh(a,b,c){if(c.length){if(a.h.ignoreDuplicateInitData){var d=a.i.values();d=t(d);for(var e=d.next();!e.done;e=d.next())if(xb(c,e.value.initData))return}0<a.i.size&&ci(a)&&(a.l.resolve(),a.l=new bg,a.l.catch(function(){}));di(a,b,c,a.g.sessionType)}}function ei(a){a=a.i.keys();a=Dg(a,function(b){return b.sessionId});return Array.from(a)}
263
- r.ef=function(){var a=this,b=this.i.keys();b=Dg(b,function(c){var d=a.i.get(c);return{sessionId:c.sessionId,sessionType:d.type,initData:d.initData,initDataType:d.initDataType}});return Array.from(b)};r.$c=function(){var a=Infinity,b=this.i.keys();b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,isNaN(c.expiration)||(a=Math.min(a,c.expiration));return a};r.Id=function(){return Hg(this.ea)};
264
- function Ph(a,b,c){var d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z;return O(function(D){switch(D.g){case 1:d=new Map;if(c.length){e=fi(a,c,d);D.u(2);break}return F(D,gi(a,b),3);case 3:e=D.h;case 2:f=e;if(!f)throw new T(2,6,6001);Cg(a.j);ra(D,4);a.H.clear();g=f.getConfiguration();h=g.audioCapabilities||[];k=g.videoCapabilities||[];l=t(h);for(m=l.next();!m.done;m=l.next())n=m.value,a.H.add(n.contentType.toLowerCase());q=t(k);for(p=q.next();!p.done;p=q.next())w=p.value,a.H.add(w.contentType.toLowerCase());if(c.length){var y=
265
- f.keySystem;var B=d.get(f.keySystem);var C=[],E=[],G=[],L=[],K=[],I=new Set,J=new Set;hi(B,C,E,L,G,K,I,J);var N=a.O?"persistent-license":"temporary";y={keySystem:y,encryptionScheme:C[0],licenseServerUri:E[0],distinctiveIdentifierRequired:B[0].distinctiveIdentifierRequired,persistentStateRequired:B[0].persistentStateRequired,sessionType:B[0].sessionType||N,audioRobustness:B[0].audioRobustness||"",videoRobustness:B[0].videoRobustness||"",serverCertificate:L[0],serverCertificateUri:G[0],initData:K,keyIds:I};
263
+ q.ef=function(){var a=this,b=this.i.keys();b=Dg(b,function(c){var d=a.i.get(c);return{sessionId:c.sessionId,sessionType:d.type,initData:d.initData,initDataType:d.initDataType}});return Array.from(b)};q.ad=function(){var a=Infinity,b=this.i.keys();b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,isNaN(c.expiration)||(a=Math.min(a,c.expiration));return a};q.Id=function(){return Hg(this.ea)};
264
+ function Ph(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z;return O(function(D){switch(D.g){case 1:d=new Map;if(c.length){e=fi(a,c,d);D.u(2);break}return F(D,gi(a,b),3);case 3:e=D.h;case 2:f=e;if(!f)throw new T(2,6,6001);Cg(a.j);ra(D,4);a.H.clear();g=f.getConfiguration();h=g.audioCapabilities||[];k=g.videoCapabilities||[];l=t(h);for(m=l.next();!m.done;m=l.next())n=m.value,a.H.add(n.contentType.toLowerCase());p=t(k);for(r=p.next();!r.done;r=p.next())u=r.value,a.H.add(u.contentType.toLowerCase());if(c.length){var y=
265
+ f.keySystem;var B=d.get(f.keySystem);var C=[],E=[],G=[],L=[],K=[],I=new Set,J=new Set;hi(B,C,E,L,G,K,I,J);var M=a.O?"persistent-license":"temporary";y={keySystem:y,encryptionScheme:C[0],licenseServerUri:E[0],distinctiveIdentifierRequired:B[0].distinctiveIdentifierRequired,persistentStateRequired:B[0].persistentStateRequired,sessionType:B[0].sessionType||M,audioRobustness:B[0].audioRobustness||"",videoRobustness:B[0].videoRobustness||"",serverCertificate:L[0],serverCertificateUri:G[0],initData:K,keyIds:I};
266
266
  0<J.size&&(y.keySystemUris=J);B=t(B);for(J=B.next();!J.done;J=B.next())J=J.value,J.distinctiveIdentifierRequired&&(y.distinctiveIdentifierRequired=J.distinctiveIdentifierRequired),J.persistentStateRequired&&(y.persistentStateRequired=J.persistentStateRequired);B=y}else B=f.keySystem,J=b.get(f.keySystem),y=[],C=[],E=[],G=[],L=[],K=new Set,hi(J.drmInfos,y,C,G,E,L,K),B={keySystem:B,encryptionScheme:y[0],licenseServerUri:C[0],distinctiveIdentifierRequired:"required"==J.distinctiveIdentifier,persistentStateRequired:"required"==
267
- J.persistentState,sessionType:J.sessionTypes[0]||"temporary",audioRobustness:(J.audioCapabilities?J.audioCapabilities[0].robustness:"")||"",videoRobustness:(J.videoCapabilities?J.videoCapabilities[0].robustness:"")||"",serverCertificate:G[0],serverCertificateUri:E[0],initData:L,keyIds:K};a.g=B;if(!a.g.licenseServerUri)throw new T(2,6,6012,a.g.keySystem);return F(D,f.createMediaKeys(),6);case 6:u=D.h;Cg(a.j);a.s=u;if(!(""!=a.h.minHdcpVersion&&"getStatusForPolicy"in a.s)){D.u(7);break}ra(D,8);return F(D,
268
- a.s.getStatusForPolicy({minHdcpVersion:a.h.minHdcpVersion}),10);case 10:v=D.h;if("usable"!=v)throw new T(2,6,6018);Cg(a.j);ta(D,7,4);break;case 8:A=ua(D,4);if(A instanceof T)throw A;throw new T(2,6,6019,A.message);case 7:return a.da=!0,F(D,Zh(a),11);case 11:Cg(a.j);ta(D,0);break;case 4:z=ua(D);Cg(a.j,z);a.g=null;a.H.clear();if(z instanceof T)throw z;throw new T(2,6,6002,z.message);}})}
267
+ J.persistentState,sessionType:J.sessionTypes[0]||"temporary",audioRobustness:(J.audioCapabilities?J.audioCapabilities[0].robustness:"")||"",videoRobustness:(J.videoCapabilities?J.videoCapabilities[0].robustness:"")||"",serverCertificate:G[0],serverCertificateUri:E[0],initData:L,keyIds:K};a.g=B;if(!a.g.licenseServerUri)throw new T(2,6,6012,a.g.keySystem);return F(D,f.createMediaKeys(),6);case 6:v=D.h;Cg(a.j);a.s=v;if(!(""!=a.h.minHdcpVersion&&"getStatusForPolicy"in a.s)){D.u(7);break}ra(D,8);return F(D,
268
+ a.s.getStatusForPolicy({minHdcpVersion:a.h.minHdcpVersion}),10);case 10:w=D.h;if("usable"!=w)throw new T(2,6,6018);Cg(a.j);ta(D,7,4);break;case 8:A=ua(D,4);if(A instanceof T)throw A;throw new T(2,6,6019,A.message);case 7:return a.da=!0,F(D,Zh(a),11);case 11:Cg(a.j);ta(D,0);break;case 4:z=ua(D);Cg(a.j,z);a.g=null;a.H.clear();if(z instanceof T)throw z;throw new T(2,6,6002,z.message);}})}
269
269
  function fi(a,b,c){for(var d=t(b),e=d.next();!e.done;e=d.next()){e=t(Sh(e.value));for(var f=e.next();!f.done;f=e.next())f=f.value,c.has(f.keySystem)||c.set(f.keySystem,[]),c.get(f.keySystem).push(f)}if(1==c.size&&c.has(""))throw new T(2,6,6E3);a=t(a.h.preferredKeySystems);e=a.next();for(d={};!e.done;d={Rg:void 0},e=a.next())for(d.Rg=e.value,e=t(b),f=e.next();!f.done;f=e.next())if(f=f.value.decodingInfos.find(function(l){return function(m){return m.supported&&null!=m.keySystemAccess&&m.keySystemAccess.keySystem==
270
270
  l.Rg}}(d)))return f.keySystemAccess;a=t([!0,!1]);for(d=a.next();!d.done;d=a.next())for(d=d.value,e=t(b),f=e.next();!f.done;f=e.next()){f=t(f.value.decodingInfos);for(var g=f.next();!g.done;g=f.next())if(g=g.value,g.supported&&g.keySystemAccess){var h=c.get(g.keySystemAccess.keySystem);h=t(h);for(var k=h.next();!k.done;k=h.next())if(!!k.value.licenseServerUri==d)return g.keySystemAccess}}return null}
271
- function gi(a,b){var c,d,e,f,g,h,k,l,m,n,q,p,w,u,v,A;return O(function(z){switch(z.g){case 1:if(1==b.size&&b.has(""))throw new T(2,6,6E3);d=t(b.values());for(e=d.next();!e.done;e=d.next())f=e.value,0==f.audioCapabilities.length&&delete f.audioCapabilities,0==f.videoCapabilities.length&&delete f.videoCapabilities;g=t(a.h.preferredKeySystems);h=g.next();case 2:if(h.done){z.u(4);break}k=h.value;if(!b.has(k)){z.u(3);break}l=b.get(k);ra(z,6);return F(z,navigator.requestMediaKeySystemAccess(k,[l]),8);case 8:return c=
272
- z.h,z.return(c);case 6:ua(z);case 7:Cg(a.j);case 3:h=g.next();z.u(2);break;case 4:m=t([!0,!1]),n=m.next();case 9:if(n.done){z.u(11);break}q=n.value;p=t(b.keys());w=p.next();case 12:if(w.done){n=m.next();z.u(9);break}u=w.value;v=b.get(u);A=v.drmInfos.some(function(D){return!!D.licenseServerUri});if(A!=q){z.u(13);break}ra(z,15);return F(z,navigator.requestMediaKeySystemAccess(u,[v]),17);case 17:return c=z.h,z.return(c);case 15:ua(z);case 16:Cg(a.j);case 13:w=p.next();z.u(12);break;case 11:return z.return(c)}})}
271
+ function gi(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A;return O(function(z){switch(z.g){case 1:if(1==b.size&&b.has(""))throw new T(2,6,6E3);d=t(b.values());for(e=d.next();!e.done;e=d.next())f=e.value,0==f.audioCapabilities.length&&delete f.audioCapabilities,0==f.videoCapabilities.length&&delete f.videoCapabilities;g=t(a.h.preferredKeySystems);h=g.next();case 2:if(h.done){z.u(4);break}k=h.value;if(!b.has(k)){z.u(3);break}l=b.get(k);ra(z,6);return F(z,navigator.requestMediaKeySystemAccess(k,[l]),8);case 8:return c=
272
+ z.h,z.return(c);case 6:ua(z);case 7:Cg(a.j);case 3:h=g.next();z.u(2);break;case 4:m=t([!0,!1]),n=m.next();case 9:if(n.done){z.u(11);break}p=n.value;r=t(b.keys());u=r.next();case 12:if(u.done){n=m.next();z.u(9);break}v=u.value;w=b.get(v);A=w.drmInfos.some(function(D){return!!D.licenseServerUri});if(A!=p){z.u(13);break}ra(z,15);return F(z,navigator.requestMediaKeySystemAccess(v,[w]),17);case 17:return c=z.h,z.return(c);case 15:ua(z);case 16:Cg(a.j);case 13:u=r.next();z.u(12);break;case 11:return z.return(c)}})}
273
273
  function Qh(a){a=Fg(a.h.clearKeys);return 0==a.size?null:Qd(a)}function ii(a){ci(a)&&a.l.resolve()}function ji(a,b){(new Sc(function(){b.loaded=!0;ii(a)})).Z(ki)}
274
274
  function ai(a,b,c){var d,e,f,g,h,k,l;return O(function(m){switch(m.g){case 1:try{d=a.s.createSession("persistent-license")}catch(n){return e=new T(2,6,6005,n.message),a.o(e),m.return(Promise.reject(e))}a.B.D(d,"message",function(n){a.m&&a.h.delayLicenseRequestUntilPlayed&&a.m.paused&&!a.T?a.N.push(n):Xh(a,n)});a.B.D(d,"keystatuseschange",function(n){return li(a,n)});f={initData:c.initData,initDataType:c.initDataType,loaded:!1,zf:Infinity,kb:null,type:"persistent-license"};a.i.set(d,f);ra(m,2);return F(m,
275
275
  d.load(b),4);case 4:return g=m.h,Cg(a.j),g||(a.i.delete(d),h=a.h.persistentSessionOnlinePlayback?1:2,a.o(new T(h,6,6013)),f.loaded=!0),ji(a,f),ii(a),m.return(d);case 2:k=ua(m),Cg(a.j,k),a.i.delete(d),l=a.h.persistentSessionOnlinePlayback?1:2,a.o(new T(l,6,6005,k.message)),f.loaded=!0,ii(a);case 3:return m.return(Promise.resolve())}})}
276
276
  function di(a,b,c,d){try{var e=a.s.createSession(d)}catch(f){a.o(new T(2,6,6005,f.message));return}a.B.D(e,"message",function(f){a.m&&a.h.delayLicenseRequestUntilPlayed&&a.m.paused&&!a.T?a.N.push(f):Xh(a,f)});a.B.D(e,"keystatuseschange",function(f){return li(a,f)});a.i.set(e,{initData:c,initDataType:b,loaded:!1,zf:Infinity,kb:null,type:d});try{c=a.h.initDataTransform(c,b,a.g)}catch(f){b=f;f instanceof T||(b=new T(2,6,6016,f));a.o(b);return}a.h.logLicenseExchange&&Fd(c);e.generateRequest(b,c).catch(function(f){if(!a.j.g){a.i.delete(e);
277
277
  var g=f.errorCode;if(g&&g.systemCode){var h=g.systemCode;0>h&&(h+=Math.pow(2,32));h="0x"+h.toString(16)}a.o(new T(2,6,6006,f.message,f,h))}})}
278
- function Xh(a,b){var c,d,e,f,g,h,k,l,m,n,q,p,w,u;O(function(v){switch(v.g){case 1:c=b.target;a.h.logLicenseExchange&&Fd(b.message);d=a.i.get(c);e=a.g.licenseServerUri;f=a.h.advanced[a.g.keySystem];"individualization-request"==b.messageType&&f&&f.individualizationServer&&(e=f.individualizationServer);g=tg([e],a.h.retryParameters);g.body=b.message;g.method="POST";g.licenseRequestType=b.messageType;g.sessionId=c.sessionId;g.drmInfo=a.g;d&&(g.initData=d.initData,g.initDataType=d.initDataType);if(f&&f.headers)for(h in f.headers)g.headers[h]=
279
- f.headers[h];if(Oc(a.g.keySystem)){var A=wd(g.body,!0,!0);if(A.includes("PlayReadyKeyMessage")){A=ah(A,"PlayReadyKeyMessage");var z=kh(A,"HttpHeader");z=t(z);for(var D=z.next();!D.done;D=z.next()){var y=D.value;D=kh(y,"name")[0];y=kh(y,"value")[0];g.headers[ih(D)]=ih(y)}A=kh(A,"Challenge")[0];g.body=Gd(ih(A))}else g.headers["Content-Type"]="text/xml; charset=utf-8"}k=Date.now();ra(v,2);m=a.C.Lb.request(2,g);return F(v,m.promise,4);case 4:l=v.h;ta(v,3);break;case 2:n=ua(v);if(a.j.g)return v.return();
280
- q=new T(2,6,6007,n);1==a.i.size?(a.o(q),d&&d.kb&&d.kb.reject(q)):(d&&d.kb&&d.kb.reject(q),a.i.delete(c),ci(a)&&(a.l.resolve(),a.L.Z(.1)));return v.return();case 3:if(a.j.g)return v.return();a.I+=(Date.now()-k)/1E3;a.h.logLicenseExchange&&Fd(l.data);ra(v,5);return F(v,c.update(l.data),7);case 7:ta(v,6);break;case 5:return p=ua(v),w=new T(2,6,6008,p.message),a.o(w),d&&d.kb&&d.kb.reject(w),v.return();case 6:if(a.j.g)return v.return();u=new U("drmsessionupdate");a.C.onEvent(u);d&&(d.kb&&d.kb.resolve(),
281
- ji(a,d));H(v)}})}
278
+ function Xh(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v;O(function(w){switch(w.g){case 1:c=b.target;a.h.logLicenseExchange&&Fd(b.message);d=a.i.get(c);e=a.g.licenseServerUri;f=a.h.advanced[a.g.keySystem];"individualization-request"==b.messageType&&f&&f.individualizationServer&&(e=f.individualizationServer);g=tg([e],a.h.retryParameters);g.body=b.message;g.method="POST";g.licenseRequestType=b.messageType;g.sessionId=c.sessionId;g.drmInfo=a.g;d&&(g.initData=d.initData,g.initDataType=d.initDataType);if(f&&f.headers)for(h in f.headers)g.headers[h]=
279
+ f.headers[h];if(Oc(a.g.keySystem)){var A=wd(g.body,!0,!0);if(A.includes("PlayReadyKeyMessage")){A=ah(A,"PlayReadyKeyMessage");var z=kh(A,"HttpHeader");z=t(z);for(var D=z.next();!D.done;D=z.next()){var y=D.value;D=kh(y,"name")[0];y=kh(y,"value")[0];g.headers[ih(D)]=ih(y)}A=kh(A,"Challenge")[0];g.body=Gd(ih(A))}else g.headers["Content-Type"]="text/xml; charset=utf-8"}k=Date.now();ra(w,2);m=a.C.Lb.request(2,g);return F(w,m.promise,4);case 4:l=w.h;ta(w,3);break;case 2:n=ua(w);if(a.j.g)return w.return();
280
+ p=new T(2,6,6007,n);1==a.i.size?(a.o(p),d&&d.kb&&d.kb.reject(p)):(d&&d.kb&&d.kb.reject(p),a.i.delete(c),ci(a)&&(a.l.resolve(),a.L.Z(.1)));return w.return();case 3:if(a.j.g)return w.return();a.I+=(Date.now()-k)/1E3;a.h.logLicenseExchange&&Fd(l.data);ra(w,5);return F(w,c.update(l.data),7);case 7:ta(w,6);break;case 5:return r=ua(w),u=new T(2,6,6008,r.message),a.o(u),d&&d.kb&&d.kb.reject(u),w.return();case 6:if(a.j.g)return w.return();v=new U("drmsessionupdate");a.C.onEvent(v);d&&(d.kb&&d.kb.resolve(),
281
+ ji(a,d));H(w)}})}
282
282
  function li(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(Oc(a.g.keySystem)&&16==g.byteLength&&(Wc()||id())){h=Eb(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=Id(g).slice(0,32);a.Y.set(g,f)});var e=b.expiration-Date.now();(0>e||d&&1E3>e)&&c&&!c.kb&&(a.i.delete(b),b.close().catch(function(){}));ci(a)&&
283
283
  (a.l.resolve(),a.L.Z(mi))}function Hh(a){var b=a.Y,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 T(2,6,6014));a.C.de(Hg(c))}
284
- function ni(){var a,b,c,d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L,K,I;return O(function(J){if(1==J.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=
285
- [{contentType:'video/mp4; codecs="avc1.42E01E"'},{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(N,M){var P,R,Q,X,W,ya,xa,Ba;return O(function(Ga){switch(Ga.g){case 1:return ra(Ga,2),F(Ga,M.createMediaKeys(),4);case 4:ta(Ga,3);break;case 2:return ua(Ga),Ga.return();case 3:R=
286
- (P=M.getConfiguration().sessionTypes)?P.includes("persistent-license"):!1,ad()&&(R=!1),Q=M.getConfiguration().videoCapabilities,X=M.getConfiguration().audioCapabilities,W={persistentState:R,encryptionSchemes:[],videoRobustnessLevels:[],audioRobustnessLevels:[]},k.has(N)&&k.get(N)?W=k.get(N):k.set(N,W),(ya=Q[0].encryptionScheme)&&!W.encryptionSchemes.includes(ya)&&W.encryptionSchemes.push(ya),(xa=Q[0].robustness)&&!W.videoRobustnessLevels.includes(xa)&&W.videoRobustnessLevels.push(xa),(Ba=X[0].robustness)&&
287
- !W.audioRobustnessLevels.includes(Ba)&&W.audioRobustnessLevels.push(Ba),H(Ga)}})};m=function(N,M,P,R){var Q,X,W,ya,xa,Ba,Ga,bb,Za,Ta;return O(function(Ca){switch(Ca.g){case 1:ra(Ca,2);Q=Le(g);X=t(Q.videoCapabilities);for(W=X.next();!W.done;W=X.next())ya=W.value,ya.encryptionScheme=M,ya.robustness=P;xa=t(Q.audioCapabilities);for(Ba=xa.next();!Ba.done;Ba=xa.next())Ga=Ba.value,Ga.encryptionScheme=M,Ga.robustness=R;bb=Le(Q);bb.persistentState="required";bb.sessionTypes=["persistent-license"];Za=[bb,Q];
288
- return F(Ca,navigator.requestMediaKeySystemAccess(N,Za),4);case 4:return Ta=Ca.h,F(Ca,l(N,Ta),5);case 5:ta(Ca,0);break;case 2:ua(Ca),H(Ca)}})};n=function(N,M,P,R){var Q,X,W;return O(function(ya){switch(ya.g){case 1:return ra(ya,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:N,video:{encryptionScheme:M,robustness:P},audio:{encryptionScheme:M,
289
- robustness:R}}},F(ya,navigator.mediaCapabilities.decodingInfo(Q),4);case 4:return X=ya.h,W=X.keySystemAccess,F(ya,l(N,W),5);case 5:ta(ya,0);break;case 2:ua(ya),H(ya)}})};q=t(a);for(p=q.next();!p.done;p=q.next())w=p.value,k.set(w,null);u=[];v=t(h);for(A=v.next();!A.done;A=v.next())for(z=A.value,D=t(a),y=D.next();!y.done;y=D.next())B=y.value,"org.w3.clearkey"===B&&ld()||(u.push(m(B,z,"","")),u.push(n(B,z,"","")));C=t(a);for(E=C.next();!E.done;E=C.next())for(G=E.value,L=t(d[G]||[]),K=L.next();!K.done;K=
290
- L.next())I=K.value,u.push(m(G,null,I,"")),u.push(m(G,null,"",I)),u.push(n(G,null,I,"")),u.push(n(G,null,"",I));return F(J,Promise.all(u),2)}return J.return(Hg(k))})}function oi(a){var b;return O(function(c){if(1==c.g)return b=new Promise(function(d,e){(new Sc(e)).Z(pi)}),ra(c,2),F(c,Promise.race([Promise.all([a.close(),a.closed]),b]),4);if(2!=c.g)return ta(c,0);ua(c);H(c)})}
284
+ function ni(){var a,b,c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L,K,I;return O(function(J){if(1==J.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=
285
+ [{contentType:'video/mp4; codecs="avc1.42E01E"'},{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(M,N){var P,R,Q,X,W,ya,xa,Ba;return O(function(Ga){switch(Ga.g){case 1:return ra(Ga,2),F(Ga,N.createMediaKeys(),4);case 4:ta(Ga,3);break;case 2:return ua(Ga),Ga.return();case 3:R=
286
+ (P=N.getConfiguration().sessionTypes)?P.includes("persistent-license"):!1,ad()&&(R=!1),Q=N.getConfiguration().videoCapabilities,X=N.getConfiguration().audioCapabilities,W={persistentState:R,encryptionSchemes:[],videoRobustnessLevels:[],audioRobustnessLevels:[]},k.has(M)&&k.get(M)?W=k.get(M):k.set(M,W),(ya=Q[0].encryptionScheme)&&!W.encryptionSchemes.includes(ya)&&W.encryptionSchemes.push(ya),(xa=Q[0].robustness)&&!W.videoRobustnessLevels.includes(xa)&&W.videoRobustnessLevels.push(xa),(Ba=X[0].robustness)&&
287
+ !W.audioRobustnessLevels.includes(Ba)&&W.audioRobustnessLevels.push(Ba),H(Ga)}})};m=function(M,N,P,R){var Q,X,W,ya,xa,Ba,Ga,bb,Za,Ta;return O(function(Ca){switch(Ca.g){case 1:ra(Ca,2);Q=Le(g);X=t(Q.videoCapabilities);for(W=X.next();!W.done;W=X.next())ya=W.value,ya.encryptionScheme=N,ya.robustness=P;xa=t(Q.audioCapabilities);for(Ba=xa.next();!Ba.done;Ba=xa.next())Ga=Ba.value,Ga.encryptionScheme=N,Ga.robustness=R;bb=Le(Q);bb.persistentState="required";bb.sessionTypes=["persistent-license"];Za=[bb,Q];
288
+ return F(Ca,navigator.requestMediaKeySystemAccess(M,Za),4);case 4:return Ta=Ca.h,F(Ca,l(M,Ta),5);case 5:ta(Ca,0);break;case 2:ua(Ca),H(Ca)}})};n=function(M,N,P,R){var Q,X,W;return O(function(ya){switch(ya.g){case 1:return ra(ya,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:M,video:{encryptionScheme:N,robustness:P},audio:{encryptionScheme:N,
289
+ robustness:R}}},F(ya,navigator.mediaCapabilities.decodingInfo(Q),4);case 4:return X=ya.h,W=X.keySystemAccess,F(ya,l(M,W),5);case 5:ta(ya,0);break;case 2:ua(ya),H(ya)}})};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,D=t(a),y=D.next();!y.done;y=D.next())B=y.value,"org.w3.clearkey"===B&&ld()||(v.push(m(B,z,"","")),v.push(n(B,z,"","")));C=t(a);for(E=C.next();!E.done;E=C.next())for(G=E.value,L=t(d[G]||[]),K=L.next();!K.done;K=
290
+ L.next())I=K.value,v.push(m(G,null,I,"")),v.push(m(G,null,"",I)),v.push(n(G,null,I,"")),v.push(n(G,null,"",I));return F(J,Promise.all(v),2)}return J.return(Hg(k))})}function oi(a){var b;return O(function(c){if(1==c.g)return b=new Promise(function(d,e){(new Sc(e)).Z(pi)}),ra(c,2),F(c,Promise.race([Promise.all([a.close(),a.closed]),b]),4);if(2!=c.g)return ta(c,0);ua(c);H(c)})}
291
291
  function Kh(a){var b;return O(function(c){b=Array.from(a.i.entries());a.i.clear();return F(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 ra(g,2),a.fa||a.A.has(e.sessionId)||"persistent-license"!==f.type||a.h.persistentSessionOnlinePlayback?F(g,oi(e),5):F(g,e.remove(),5);if(2!=g.g)return ta(g,0);ua(g);H(g)})})),0)})}function Sh(a){return(a.video?a.video.drmInfos:[]).concat(a.audio?a.audio.drmInfos:[])}
292
292
  function Ih(a){a.i.forEach(function(b,c){var d=b.zf,e=c.expiration;isNaN(e)&&(e=Infinity);e!=d&&(a.C.onExpirationUpdated(c.sessionId,e),b.zf=e)})}function ci(a){a=a.i.values();return Eg(a,function(b){return b.loaded})}function bi(a){for(var b=t(a.g&&a.g.keyIds||new Set([])),c=b.next();!c.done;c=b.next())if("usable"!==a.Y.get(c.value))return!1;return!0}
293
293
  function Rh(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)}
294
294
  function hi(a,b,c,d,e,f,g,h){var k=[];a=t(a);for(var l=a.next(),m={};!l.done;m={sa:void 0},l=a.next()){m.sa=l.value;b.includes(m.sa.encryptionScheme)||b.push(m.sa.encryptionScheme);"org.w3.clearkey"==m.sa.keySystem&&m.sa.licenseServerUri.startsWith("data:application/json;base64,")?k.includes(m.sa.licenseServerUri)||k.push(m.sa.licenseServerUri):c.includes(m.sa.licenseServerUri)||c.push(m.sa.licenseServerUri);e.includes(m.sa.serverCertificateUri)||e.push(m.sa.serverCertificateUri);m.sa.serverCertificate&&
295
- (d.some(function(p){return function(w){return xb(w,p.sa.serverCertificate)}}(m))||d.push(m.sa.serverCertificate));if(m.sa.initData){l=t(m.sa.initData);for(var n=l.next(),q={};!n.done;q={lf:void 0},n=l.next())q.lf=n.value,f.some(function(p){return function(w){var u=p.lf;return w.keyId&&w.keyId==u.keyId?!0:w.initDataType==u.initDataType&&xb(w.initData,u.initData)}}(q))||f.push(q.lf)}if(m.sa.keyIds)for(l=t(m.sa.keyIds),n=l.next();!n.done;n=l.next())g.add(n.value);if(m.sa.keySystemUris&&h)for(m=t(m.sa.keySystemUris),
295
+ (d.some(function(r){return function(u){return xb(u,r.sa.serverCertificate)}}(m))||d.push(m.sa.serverCertificate));if(m.sa.initData){l=t(m.sa.initData);for(var n=l.next(),p={};!n.done;p={lf:void 0},n=l.next())p.lf=n.value,f.some(function(r){return function(u){var v=r.lf;return u.keyId&&u.keyId==v.keyId?!0:u.initDataType==v.initDataType&&xb(u.initData,v.initData)}}(p))||f.push(p.lf)}if(m.sa.keyIds)for(l=t(m.sa.keyIds),n=l.next();!n.done;n=l.next())g.add(n.value);if(m.sa.keySystemUris&&h)for(m=t(m.sa.keySystemUris),
296
296
  l=m.next();!l.done;l=m.next())h.add(l.value)}if(1==k.length)c.push(k[0]);else if(0<k.length){b=[];k=t(k);for(d=k.next();!d.done;d=k.next())d=window.atob(d.value.split("data:application/json;base64,").pop()),d=JSON.parse(d),b.push.apply(b,x(d.keys));k=JSON.stringify({keys:b});c.push("data:application/json;base64,"+window.btoa(k))}}
297
297
  function Th(a,b,c,d){var e=a.keySystem;if(e&&("org.w3.clearkey"!=e||!a.licenseServerUri)){b.size&&(b=b.get(e)||"",a.licenseServerUri=b);a.keyIds||(a.keyIds=new Set);if(c=c.get(e))a.distinctiveIdentifierRequired||(a.distinctiveIdentifierRequired=c.distinctiveIdentifierRequired),a.persistentStateRequired||(a.persistentStateRequired=c.persistentStateRequired),a.videoRobustness||(a.videoRobustness=c.videoRobustness),a.audioRobustness||(a.audioRobustness=c.audioRobustness),a.serverCertificate||(a.serverCertificate=
298
298
  c.serverCertificate),c.sessionType&&(a.sessionType=c.sessionType),a.serverCertificateUri||(a.serverCertificateUri=c.serverCertificateUri);d[e]&&(a.keySystem=d[e]);window.cast&&window.cast.__platform__&&"com.microsoft.playready"==e&&(a.keySystem="com.chromecast.playready")}}var pi=1,ki=5,mi=.5;/*
@@ -308,12 +308,12 @@ missingKeys:Array.from(f),restrictedKeyStatuses:Array.from(g)},new T(2,4,4012,a)
308
308
  function(m){k.push({box:m,Oa:1701733238})}).S("hev1",function(m){k.push({box:m,Oa:1701733238})}).S("hvc1",function(m){k.push({box:m,Oa:1701733238})}).S("avc1",function(m){k.push({box:m,Oa:1701733238})}).S("avc3",function(m){k.push({box:m,Oa:1701733238})}).S("ac-3",function(m){k.push({box:m,Oa:1701733217})}).S("ec-3",function(m){k.push({box:m,Oa:1701733217})}).S("ac-4",function(m){k.push({box:m,Oa:1701733217})}).S("mp4a",function(m){k.push({box:m,Oa:1701733217})}).parse(a);if(f)return a;if(0==k.length||
309
309
  !g)throw eb(Id(a)),new T(2,3,3019,b);k.reverse();b=t(k);for(var l=b.next();!l.done;l=b.next())l=l.value,e=Ai(e,g,l.box,h,l.Oa);return Wc()&&md()?(b=new Uint8Array(a.byteLength+e.byteLength),b.set(e),b.set(a,e.byteLength),b):e}
310
310
  function Ai(a,b,c,d,e){var f=Bi.value(),g=a.subarray(c.start,c.start+c.size),h=Eb(g),k=new Uint8Array(c.size+f.byteLength);k.set(g,0);g=Eb(k);g.setUint32(4,e);k.set(f,c.size);e=h.getUint32(4);g.setUint32(c.size+16,e);Ci(k,0,k.byteLength);e=new Uint8Array(a.byteLength+k.byteLength);c=Yc()||Wc()?c.start:c.start+c.size;f=a.subarray(c);e.set(a.subarray(0,c));e.set(k,c);e.set(f,c+k.byteLength);a=t(d);for(d=a.next();!d.done;d=a.next())d=d.value,Ci(e,d.start,d.size+k.byteLength);k=Eb(e,b.start);b=Rg(b);
311
- a=k.getUint32(b);k.setUint32(b,a+1);return e}function Ci(a,b,c){a=Eb(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 Bi=new Kc(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 Di(a,b,c,d,e,f,g){this.M=a;this.Ga=b;this.ta=c;this.Hc=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}Di.prototype.Xb=function(){return this.Ga};Di.prototype.Ub=function(){return this.ta};Di.prototype.bd=function(){return this.g};function Ei(a,b){return a===b?!0:a&&b?a.Xb()==b.Xb()&&a.Ub()==b.Ub()&&Pb(a.M().sort(),b.M().sort())&&xb(a.bd(),b.bd()):a==b}S("shaka.media.InitSegmentReference",Di);
311
+ a=k.getUint32(b);k.setUint32(b,a+1);return e}function Ci(a,b,c){a=Eb(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 Bi=new Kc(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 Di(a,b,c,d,e,f,g){this.M=a;this.Ga=b;this.ta=c;this.Ic=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}Di.prototype.Xb=function(){return this.Ga};Di.prototype.Ub=function(){return this.ta};Di.prototype.cd=function(){return this.g};function Ei(a,b){return a===b?!0:a&&b?a.Xb()==b.Xb()&&a.Ub()==b.Ub()&&Pb(a.M().sort(),b.M().sort())&&xb(a.cd(),b.cd()):a==b}S("shaka.media.InitSegmentReference",Di);
312
312
  Di.prototype.getEndByte=Di.prototype.Ub;Di.prototype.getStartByte=Di.prototype.Xb;
313
- function Fi(a,b,c,d,e,f,g,h,k,l,m,n,q,p,w,u){l=void 0===l?[]:l;p=void 0===p?Gi:p;this.startTime=a;this.j=this.endTime=b;this.F=c;this.Ga=d;this.ta=e;this.$=f;this.timestampOffset=g;this.appendWindowStart=h;this.appendWindowEnd=k;this.g=l;this.tilesLayout=void 0===m?"":m;this.B=void 0===n?null:n;this.h=void 0===q?null:q;this.status=p;this.preload=!1;this.l=!0;this.m=!1;this.aesKey=void 0===w?null:w;this.A=null;this.i=0;this.o=void 0===u?!1:u;this.G=this.s=!1;a=t(this.g);for(b=a.next();!b.done;b=a.next())b.value.Kg();
314
- this.o&&this.g.length&&this.g[this.g.length-1].Jg();this.C=this.mimeType=this.codecs=null}r=Fi.prototype;r.M=function(){return this.F()};r.getStartTime=function(){return this.startTime};r.Mh=function(){return this.endTime};r.Xb=function(){return this.Ga};r.Ub=function(){return this.ta};r.di=function(){return this.tilesLayout};r.ci=function(){return this.B};r.Yb=function(){return this.status};r.xi=function(){this.status=Hi};r.wf=function(){this.preload=!0};r.ri=function(){return this.preload};
315
- r.Vd=function(){this.l=!1};r.ni=function(){return this.l};r.Kg=function(){this.s=!0};r.pi=function(){return this.s};r.Jg=function(){this.G=!0};r.oi=function(){return this.G};r.Ig=function(){this.m=!0};r.ji=function(){return this.m};r.fh=function(a){this.A=a};r.bi=function(){return this.A};r.offset=function(a){this.startTime+=a;this.endTime+=a;this.j+=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.j+=a};
316
- r.Vf=function(a){null==this.h?Xa("Sync attempted without sync time!"):(a=this.h-a-this.startTime,.001<=Math.abs(a)&&this.offset(a))};r.Zi=function(a){this.C=a};r.bd=function(){return this.C};function Ii(a,b){a.$=b;a=t(a.g);for(var c=a.next();!c.done;c=a.next())Ii(c.value,b)}S("shaka.media.SegmentReference",Fi);Fi.prototype.getSegmentData=Fi.prototype.bd;Fi.prototype.setSegmentData=Fi.prototype.Zi;Fi.prototype.syncAgainst=Fi.prototype.Vf;Fi.prototype.offset=Fi.prototype.offset;
313
+ function Fi(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?Gi:r;this.startTime=a;this.j=this.endTime=b;this.F=c;this.Ga=d;this.ta=e;this.$=f;this.timestampOffset=g;this.appendWindowStart=h;this.appendWindowEnd=k;this.g=l;this.tilesLayout=void 0===m?"":m;this.B=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.A=null;this.i=0;this.o=void 0===v?!1:v;this.G=this.s=!1;a=t(this.g);for(b=a.next();!b.done;b=a.next())b.value.Kg();
314
+ this.o&&this.g.length&&this.g[this.g.length-1].Jg();this.C=this.mimeType=this.codecs=null}q=Fi.prototype;q.M=function(){return this.F()};q.getStartTime=function(){return this.startTime};q.Mh=function(){return this.endTime};q.Xb=function(){return this.Ga};q.Ub=function(){return this.ta};q.di=function(){return this.tilesLayout};q.ci=function(){return this.B};q.Yb=function(){return this.status};q.xi=function(){this.status=Hi};q.wf=function(){this.preload=!0};q.ri=function(){return this.preload};
315
+ q.Vd=function(){this.l=!1};q.ni=function(){return this.l};q.Kg=function(){this.s=!0};q.pi=function(){return this.s};q.Jg=function(){this.G=!0};q.oi=function(){return this.G};q.Ig=function(){this.m=!0};q.ji=function(){return this.m};q.fh=function(a){this.A=a};q.bi=function(){return this.A};q.offset=function(a){this.startTime+=a;this.endTime+=a;this.j+=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.j+=a};
316
+ q.Vf=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.Zi=function(a){this.C=a};q.cd=function(){return this.C};function Ii(a,b){a.$=b;a=t(a.g);for(var c=a.next();!c.done;c=a.next())Ii(c.value,b)}S("shaka.media.SegmentReference",Fi);Fi.prototype.getSegmentData=Fi.prototype.cd;Fi.prototype.setSegmentData=Fi.prototype.Zi;Fi.prototype.syncAgainst=Fi.prototype.Vf;Fi.prototype.offset=Fi.prototype.offset;
317
317
  Fi.prototype.getThumbnailSprite=Fi.prototype.bi;Fi.prototype.setThumbnailSprite=Fi.prototype.fh;Fi.prototype.hasByterangeOptimization=Fi.prototype.ji;Fi.prototype.markAsByterangeOptimization=Fi.prototype.Ig;Fi.prototype.isLastPartial=Fi.prototype.oi;Fi.prototype.markAsLastPartial=Fi.prototype.Jg;Fi.prototype.isPartial=Fi.prototype.pi;Fi.prototype.markAsPartial=Fi.prototype.Kg;Fi.prototype.isIndependent=Fi.prototype.ni;Fi.prototype.markAsNonIndependent=Fi.prototype.Vd;Fi.prototype.isPreload=Fi.prototype.ri;
318
318
  Fi.prototype.markAsPreload=Fi.prototype.wf;Fi.prototype.markAsUnavailable=Fi.prototype.xi;Fi.prototype.getStatus=Fi.prototype.Yb;Fi.prototype.getTileDuration=Fi.prototype.ci;Fi.prototype.getTilesLayout=Fi.prototype.di;Fi.prototype.getEndByte=Fi.prototype.Ub;Fi.prototype.getStartByte=Fi.prototype.Xb;Fi.prototype.getEndTime=Fi.prototype.Mh;Fi.prototype.getStartTime=Fi.prototype.getStartTime;Fi.prototype.getUris=Fi.prototype.M;var Gi=0,Hi=1;Fi.Status={hj:Gi,Zj:Hi,Bj:2};function Ji(a){return 1==a.length&&1E-4>a.end(0)-a.start(0)}function Ki(a){return!a||Ji(a)?null:a.length?a.end(a.length-1):null}function Oi(a,b){return!a||!a.length||Ji(a)||b>a.end(a.length-1)?!1:b>=a.start(0)}function Pi(a,b){if(!a||!a.length||Ji(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}
319
319
  function Ri(a,b,c){if(!a||!a.length||Ji(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};/*
@@ -327,7 +327,7 @@ function Wi(a){var b={key:a.type,description:"",data:"",mimeType:null,pictureTyp
327
327
  d=a.data.subarray(1).indexOf(0);if(-1===d)return null;c=ud(zb(a.data,1,d));a=ud(zb(a.data,2+d)).replace(/\0*$/,"");b.description=c;b.data=a;return b}if("WXXX"===a.type){if(2>a.size||3!==a.data[0])return null;d=a.data.subarray(1).indexOf(0);if(-1===d)return null;c=ud(zb(a.data,1,d));a=ud(zb(a.data,2+d)).replace(/\0*$/,"");b.description=c;b.data=a;return b}if("PRIV"===a.type){if(2>a.size)return null;c=a.data.indexOf(0);if(-1===c)return null;c=ud(zb(a.data,0,c));b.description=c;"com.apple.streaming.transportStreamTimestamp"==
328
328
  c?(c=a.data.subarray(c.length+1),a=c[3]&1,c=(c[4]<<23)+(c[5]<<15)+(c[6]<<7)+c[7],c/=45,a&&(c+=4.772185884E7),b.data=c):(a=Ab(a.data.subarray(c.length+1)),b.data=a);return b}if("T"===a.type[0]){if(2>a.size||3!==a.data[0])return null;a=ud(a.data.subarray(1)).replace(/\0*$/,"");b.data=a;return b}return"W"===a.type[0]?(a=ud(a.data).replace(/\0*$/,""),b.data=a,b):a.data?(b.data=Ab(a.data),b):null}
329
329
  function Xi(a){for(var b=0,c=[];Ti(a,b);){var d=Vi(a,b+6);a[b+5]>>6&1&&(b+=10);b+=10;for(d=b+d;b+10<d;){var e=a.subarray(b),f=Vi(e,4);e={type:String.fromCharCode(e[0],e[1],e[2],e[3]),size:f,data:e.subarray(10,10+f)};(f=Wi(e))&&c.push(f);b+=e.size+10}Ui(a,b)&&(b+=10)}return c}function Yi(a,b){for(var c=b=void 0===b?0:b,d=0;Ti(a,b);)a[b+5]>>6&1&&(d+=10),d+=10,d+=Vi(a,b+6),Ui(a,b+10)&&(d+=10),b+=d;return 0<d?a.subarray(c,c+d):new Uint8Array([])}S("shaka.util.Id3Utils",Si);Si.getID3Data=Yi;
330
- Si.getID3Frames=Xi;function Zi(a,b){var c=null,d=null,e=null,f=a.R();b&1&&(e=a.Mc());b&2&&a.skip(4);b&8&&(c=a.R());b&16&&(d=a.R());return{trackId:f,Xc:c,Fd:d,ck:e}}function $i(a,b){return 1==b?(b=a.R(),a=a.R(),{baseMediaDecodeTime:b*Math.pow(2,32)+a}):{baseMediaDecodeTime:a.R()}}function aj(a,b){1==b?(a.skip(8),a.skip(8)):(a.skip(4),a.skip(4));b=a.R();a.skip(4);a=a.na();return{timescale:b,language:String.fromCharCode((a>>10)+96)+String.fromCharCode(((a&960)>>5)+96)+String.fromCharCode((a&31)+96)}}
330
+ Si.getID3Frames=Xi;function Zi(a,b){var c=null,d=null,e=null,f=a.R();b&1&&(e=a.Nc());b&2&&a.skip(4);b&8&&(c=a.R());b&16&&(d=a.R());return{trackId:f,Yc:c,Fd:d,ck:e}}function $i(a,b){return 1==b?(b=a.R(),a=a.R(),{baseMediaDecodeTime:b*Math.pow(2,32)+a}):{baseMediaDecodeTime:a.R()}}function aj(a,b){1==b?(a.skip(8),a.skip(8)):(a.skip(4),a.skip(4));b=a.R();a.skip(4);a=a.na();return{timescale:b,language:String.fromCharCode((a>>10)+96)+String.fromCharCode(((a&960)>>5)+96)+String.fromCharCode((a&31)+96)}}
331
331
  function bj(a,b,c){var d=a.R(),e=[],f=null;c&1&&(f=a.R());c&4&&a.skip(4);for(var g=0;g<d;g++){var h={Jf:null,sampleSize:null,me:null};c&256&&(h.Jf=a.R());c&512&&(h.sampleSize=a.R());c&1024&&a.skip(4);c&2048&&(h.me=0==b?a.R():a.Sg());e.push(h)}return{gk:d,Wg:e,Fh:f}}function cj(a){a.skip(6);a.skip(2);a.skip(8);var b=a.na();a.skip(2);a.skip(2);a.skip(2);a=a.na()+a.na()/65536;return{channelCount:b,sampleRate:a}}function dj(a){a=a.R();return{codec:Pg(a)}}
332
332
  function ej(a){var b=null,c=null,d=a.qb(4);var e=String.fromCharCode(d[0]);e+=String.fromCharCode(d[1]);e+=String.fromCharCode(d[2]);e+=String.fromCharCode(d[3]);if("nclx"===e){switch(a.na()){case 1:case 5:case 6:case 7:b="srgb";break;case 9:b="rec2020";break;case 11:case 12:b="p3"}d=a.na();a.na();switch(d){case 1:case 6:case 13:case 14:case 15:c="SDR";break;case 16:c="PQ";break;case 18:c="HLG"}}return{colorGamut:b,vd:c}}
333
333
  function fj(a,b){b=void 0===b?!1:b;a=a.toString(16).toUpperCase();return b?a:("0"+a).slice(-2)}function gj(a){return(10>a?"0":"")+a};/*
@@ -348,150 +348,150 @@ function fj(a,b){b=void 0===b?!1:b;a=a.toString(16).toUpperCase();return b?a:("0
348
348
  */
349
349
  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=zb(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 Ig(c,0)).R(),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}
350
350
  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 pj(a){return kj(a,8)}
351
- function qj(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 rj(a){pj(a);V(a);return V(a)}S("shaka.util.ExpGolomb",hj);function sj(){this.G=null;this.H=!1;this.m=this.I=null;this.j=[];this.g=[];this.A=this.B=null;this.i=[];this.h=[];this.C=null;this.l=[];this.F=this.o=this.s=null}r=sj.prototype;r.clearData=function(){this.j=[];this.g=[];this.i=[];this.h=[];this.l=[]};
352
- r.parse=function(a){if(564>a.length)return this;for(var b=Math.max(0,tj(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.G=(a[h+10]&31)<<8|a[h+11];break;case 17:case 8191:break;case this.G:f&&(h+=a[h]+1);f=a;g={audio:-1,video:-1,Od:-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<
353
- 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,q=m;2<q;){var p=f[n+1]+2;switch(f[n]){case 5:var w=xd(f.subarray(n+2,n+p));-1==g.audio&&"Opus"===w?(g.audio=l,g.audioCodec="opus"):-1==g.video&&"AV01"===w&&(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&&(w=
354
- null,128===f[n+2]&&(w=f[n+3]),null!=w&&(this.F={channelCount:0===(w&15)?2:w&15,Ch:w,sampleRate:48E3}))}n+=p;q-=p}break;case 15:-1==g.audio&&(g.audio=l,g.audioCodec="aac");break;case 17:-1==g.audio&&(g.audio=l,g.audioCodec="aac-loas");break;case 21:-1==g.Od&&(g.Od=l);break;case 27:-1==g.video&&(g.video=l,g.videoCodec="avc");break;case 3:case 4:-1==g.audio&&(g.audio=l,g.audioCodec="mp3");break;case 36:-1==g.video&&(g.video=l,g.videoCodec="hvc");break;case 129:-1==g.audio&&(g.audio=l,g.audioCodec="ac3");
351
+ function qj(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 rj(a){pj(a);V(a);return V(a)}S("shaka.util.ExpGolomb",hj);function sj(){this.G=null;this.H=!1;this.m=this.I=null;this.j=[];this.g=[];this.A=this.B=null;this.i=[];this.h=[];this.C=null;this.l=[];this.F=this.o=this.s=null}q=sj.prototype;q.clearData=function(){this.j=[];this.g=[];this.i=[];this.h=[];this.l=[]};
352
+ q.parse=function(a){if(564>a.length)return this;for(var b=Math.max(0,tj(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.G=(a[h+10]&31)<<8|a[h+11];break;case 17:case 8191:break;case this.G:f&&(h+=a[h]+1);f=a;g={audio:-1,video:-1,Od:-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<
353
+ 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=xd(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=
354
+ null,128===f[n+2]&&(u=f[n+3]),null!=u&&(this.F={channelCount:0===(u&15)?2:u&15,Ch:u,sampleRate:48E3}))}n+=r;p-=r}break;case 15:-1==g.audio&&(g.audio=l,g.audioCodec="aac");break;case 17:-1==g.audio&&(g.audio=l,g.audioCodec="aac-loas");break;case 21:-1==g.Od&&(g.Od=l);break;case 27:-1==g.video&&(g.video=l,g.videoCodec="avc");break;case 3:case 4:-1==g.audio&&(g.audio=l,g.audioCodec="mp3");break;case 36:-1==g.video&&(g.video=l,g.videoCodec="hvc");break;case 129:-1==g.audio&&(g.audio=l,g.audioCodec="ac3");
355
355
  break;case 132:case 135:-1==g.audio&&(g.audio=l,g.audioCodec="ec3")}h+=m+5}f=g;-1!=f.video&&(this.I=f.video,this.m=f.videoCodec);-1!=f.audio&&(this.B=f.audio,this.A=f.audioCodec);-1!=f.Od&&(this.C=f.Od);d&&!this.H&&(d=!1,e=b-188);this.H=!0;break;case this.I:h=a.subarray(h,e+188);f?this.j.push([h]):this.j.length&&this.j[this.j.length-1]&&this.j[this.j.length-1].push(h);break;case this.B:h=a.subarray(h,e+188);f?this.i.push([h]):this.i.length&&this.i[this.i.length-1]&&this.i[this.i.length-1].push(h);
356
356
  break;case this.C:h=a.subarray(h,e+188);f?this.l.push([h]):this.l.length&&this.l[this.l.length-1]&&this.l[this.l.length-1].push(h);break;default:d=!0}}return this};
357
357
  function Bj(a,b){if(1!==(b[0]<<16|b[1]<<8|b[2]))return null;var c={data:new Uint8Array(0),packetLength:b[4]<<8|b[5],pts:null,dts:null,nalus:[]};if(c.packetLength&&c.packetLength>b.byteLength-6)return null;var d=b[7];if(d&192){var e=536870912*(b[9]&14)+4194304*(b[10]&255)+16384*(b[11]&254)+128*(b[12]&255)+(b[13]&254)/2;null==a.s&&(a.s=e);c.pts=Cj(e,a.s);a.s=c.pts;c.dts=c.pts;d&64&&(d=536870912*(b[14]&14)+4194304*(b[15]&255)+16384*(b[16]&254)+128*(b[17]&255)+(b[18]&254)/2,null==a.o&&(a.o=d),c.dts=Cj(d,
358
- a.o));a.o=c.dts}a=b[8]+9;if(b.byteLength<=a)return null;c.data=b.subarray(a);return c}r.Ci=function(a){qb("TsParser.parseAvcNalus","Please use parseNalus function instead.");return this.Cf(a)};
359
- r.Cf=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 q=a[n];if(q){if(2<=g&&1==q){b&&!h.length&&-1==k&&(q=n-(3<g?3:g),c&&0!=q&&(q=a.subarray(0,q),b.data=Ld(b.data,q),b.fullData=Ld(b.fullData,q)));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=Ld(b.data,k),b.fullData=Ld(b.fullData,k)));if(n>=e-f)return h;
360
- 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=Ld(b.data,a),b.fullData=Ld(b.fullData,a));return h};r.getMetadata=function(){for(var a=[],b=t(this.l),c=b.next();!c.done;c=b.next())c=Ld.apply(Dd,x(c.value)),(c=Bj(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};
361
- r.Tb=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=Ld.apply(Dd,x(c.value)),e=Bj(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=Ld(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};
362
- r.Gc=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=Ld.apply(Dd,x(d.value)),f=Bj(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=Ld(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.Cf(e,
363
- 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)};r.getStartTime=function(a){if("audio"==a){a=null;var b=this.Tb();b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4);return a}return"video"==a?(a=null,b=this.Gc(!1),b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4),a):null};r.Zc=function(){return{audio:this.A,video:this.m}};
364
- r.Md=function(){for(var a=[],b=t(this.Gc()),c=b.next();!c.done;c=b.next())a.push.apply(a,x(c.value.nalus));return a};r.gi=function(){qb("TsParser.getVideoResolution","Please use getVideoInfo function instead.");var a=this.jf();return{height:a.height,width:a.width}};r.jf=function(){return"hvc"==this.m?Dj(this):Ej(this)};
365
- function Ej(a){var b={height:null,width:null,codec:null};a=a.Md();if(!a.length)return b;a=a.find(function(q){return 7==q.type});if(!a)return b;a=new hj(a.data);var c=pj(a),d=pj(a),e=pj(a);mj(a);if(Fj.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?qj(a,16):qj(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,
358
+ a.o));a.o=c.dts}a=b[8]+9;if(b.byteLength<=a)return null;c.data=b.subarray(a);return c}q.Ci=function(a){qb("TsParser.parseAvcNalus","Please use parseNalus function instead.");return this.Cf(a)};
359
+ q.Cf=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=Ld(b.data,p),b.fullData=Ld(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=Ld(b.data,k),b.fullData=Ld(b.fullData,k)));if(n>=e-f)return h;
360
+ 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=Ld(b.data,a),b.fullData=Ld(b.fullData,a));return h};q.getMetadata=function(){for(var a=[],b=t(this.l),c=b.next();!c.done;c=b.next())c=Ld.apply(Dd,x(c.value)),(c=Bj(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};
361
+ q.Tb=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=Ld.apply(Dd,x(c.value)),e=Bj(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=Ld(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};
362
+ q.Gc=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=Ld.apply(Dd,x(d.value)),f=Bj(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=Ld(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.Cf(e,
363
+ 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.Tb();b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4);return a}return"video"==a?(a=null,b=this.Gc(!1),b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4),a):null};q.$c=function(){return{audio:this.A,video:this.m}};
364
+ q.Md=function(){for(var a=[],b=t(this.Gc()),c=b.next();!c.done;c=b.next())a.push.apply(a,x(c.value.nalus));return a};q.gi=function(){qb("TsParser.getVideoResolution","Please use getVideoInfo function instead.");var a=this.jf();return{height:a.height,width:a.width}};q.jf=function(){return"hvc"==this.m?Dj(this):Ej(this)};
365
+ function Ej(a){var b={height:null,width:null,codec:null};a=a.Md();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=pj(a),d=pj(a),e=pj(a);mj(a);if(Fj.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?qj(a,16):qj(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,
366
366
  m=0,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.codec="avc1."+("0"+c.toString(16).toUpperCase()).slice(-2)+("0"+d.toString(16).toUpperCase()).slice(-2)+("0"+e.toString(16).toUpperCase()).slice(-2);return b}
367
- function Dj(a){var b={height:null,width:null,codec:null};a=a.Md();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);pj(c);pj(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=pj(c);for(var k=pj(c),l=pj(c),m=pj(c),n=pj(c),q=pj(c),p=pj(c),w=[],u=[],v=0;v<d;v++)w.push(oj(c)),u.push(oj(c));if(0<d)for(v=d;8>v;v++)kj(c,2);for(v=0;v<d;v++)w[v]&&kj(c,88),u[v]&&pj(c);V(c);d=V(c);3==d&&kj(c,1);w=V(c);u=V(c);var A=v=0,z=0,D=
368
- 0;oj(c)&&(v+=V(c),A+=V(c),z+=V(c),D+=V(c));b.width=String(w-(v+A)*(1===d||2===d?2:1));b.height=String(u-(z+D)*(1===d?2:1));c=function(y){for(var B=0,C=0;32>C;C++)B|=(y>>C&1)<<31-C;return B>>>0}(h);f=1==f?"H":"L";e="hvc1"+("."+["","A","B","C"][e]+g);e+="."+c.toString(16).toUpperCase();e+="."+f+p;q&&(e+="."+q.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());
367
+ function Dj(a){var b={height:null,width:null,codec:null};a=a.Md();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);pj(c);pj(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=pj(c);for(var k=pj(c),l=pj(c),m=pj(c),n=pj(c),p=pj(c),r=pj(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]&&pj(c);V(c);d=V(c);3==d&&kj(c,1);u=V(c);v=V(c);var A=w=0,z=0,D=
368
+ 0;oj(c)&&(w+=V(c),A+=V(c),z+=V(c),D+=V(c));b.width=String(u-(w+A)*(1===d||2===d?2:1));b.height=String(v-(z+D)*(1===d?2:1));c=function(y){for(var B=0,C=0;32>C;C++)B|=(y>>C&1)<<31-C;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());
369
369
  a&&(e+="."+a.toString(16).toUpperCase());b.codec=e;return b}function Cj(a,b){var c=1;for(a>b&&(c=-1);4294967296<Math.abs(b-a);)a+=8589934592*c;return a}function Gj(a){return 0>tj(a)?!1:!0}function tj(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}S("shaka.util.TsParser",sj);sj.syncOffset=tj;sj.probe=Gj;sj.prototype.getVideoInfo=sj.prototype.jf;sj.prototype.getVideoResolution=sj.prototype.gi;sj.prototype.getVideoNalus=sj.prototype.Md;
370
- sj.prototype.getCodecs=sj.prototype.Zc;sj.prototype.getStartTime=sj.prototype.getStartTime;sj.prototype.getVideoData=sj.prototype.Gc;sj.prototype.getAudioData=sj.prototype.Tb;sj.prototype.getMetadata=sj.prototype.getMetadata;sj.prototype.parseNalus=sj.prototype.Cf;sj.prototype.parseAvcNalus=sj.prototype.Ci;sj.prototype.parse=sj.prototype.parse;sj.prototype.clearData=sj.prototype.clearData;sj.Timescale=9E4;var Fj=[100,110,122,244,44,83,86,118,128,138,139,134];function Hj(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,qb("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
+ sj.prototype.getCodecs=sj.prototype.$c;sj.prototype.getStartTime=sj.prototype.getStartTime;sj.prototype.getVideoData=sj.prototype.Gc;sj.prototype.getAudioData=sj.prototype.Tb;sj.prototype.getMetadata=sj.prototype.getMetadata;sj.prototype.parseNalus=sj.prototype.Cf;sj.prototype.parseAvcNalus=sj.prototype.Ci;sj.prototype.parse=sj.prototype.parse;sj.prototype.clearData=sj.prototype.clearData;sj.Timescale=9E4;var Fj=[100,110,122,244,44,83,86,118,128,138,139,134];function Hj(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,qb("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"),
371
371
  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 Ij(a){a.g&&a.i.classList.add("shaka-hidden")}
372
372
  Hj.prototype.release=function(){this.g&&(this.g.close(),this.g=null)};function Jj(a,b,c){var d=0,e=-1;switch(b.mimeType){case "video/webm":d=1;break;case "video/mp4":d=2}switch(c){case "DASH":e=1;break;case "HLS":e=0}a.g&&(a.o=b.id,a.g.setLevelSwitching(b.id,!0),a.g.setContainerFormat(d),a.j||a.g.setStreamingFormat(e))}S("shaka.lcevc.Dec",Hj);Hj.prototype.release=Hj.prototype.release;function Kj(a,b,c,d){var e=this;this.i=a;this.da=c;this.A=null;this.F=b;this.h={};this.G={};this.Da={};this.g=null;this.fa=!1;this.Y=d||null;this.l={};this.s=new gb;this.j={};this.H=null;this.L=new bg;this.N="";this.ra=!1;this.m=Lj(this,this.L);this.C=!1;this.I=new Bg(function(){return Mj(e)});this.B=!1;this.ba="UNKNOWN";this.Ea=this.Fa=!1;this.za=new bg;this.o=!1;this.xa=!0;this.qa=this.O=this.ya=this.T=this.K=this.ea=null;this.la=new bg}
373
373
  function Lj(a,b){if(window.ManagedMediaSource){a.i.disableRemotePlayback=!0;var c=new ManagedMediaSource;a.s.D(c,"startstreaming",function(){a.xa=!0});a.s.D(c,"endstreaming",function(){a.xa=!1});a.s.ja(c,"sourceopen",function(){URL.revokeObjectURL(a.N);b.resolve()});a.s.ja(a.i,"playing",function(){a.ra=!0});a.N=Nj(c);a.i.src=a.N;return c}c=new MediaSource;a.s.ja(c,"sourceopen",function(){URL.revokeObjectURL(a.N);b.resolve()});a.s.ja(a.i,"playing",function(){a.ra=!0});a.N=Nj(c);a.i.src=a.N;return c}
374
- function Oj(a,b){var c,d,e,f,g,h,k,l,m,n,q;return O(function(p){if(1==p.g)return a.createSegmentIndex?F(p,a.createSegmentIndex(),2):p.u(2);if(!a.segmentIndex)return p.return(!1);if(0==a.segmentIndex.getNumReferences())return p.return(!0);c=Wd;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.ua){if(m=Zd(h,k),!qe(m))return p.return(!1)}else if(b==c.ha?k=af(k):b==c.X&&(k=bf(k,h)),n=
375
- ce(a,h,k),q=ae(h,k),!mb(n)&&!lc(q))return p.return(!1);return p.return(!0)})}r=Kj.prototype;r.destroy=function(){return this.I.destroy()};
374
+ function Oj(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?F(r,a.createSegmentIndex(),2):r.u(2);if(!a.segmentIndex)return r.return(!1);if(0==a.segmentIndex.getNumReferences())return r.return(!0);c=Wd;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.ua){if(m=Zd(h,k),!qe(m))return r.return(!1)}else if(b==c.ha?k=af(k):b==c.X&&(k=bf(k,h)),n=
375
+ ce(a,h,k),p=ae(h,k),!mb(n)&&!lc(p))return r.return(!1);return r.return(!0)})}q=Kj.prototype;q.destroy=function(){return this.I.destroy()};
376
376
  function Mj(a){var b,c,d,e,f,g,h,k;return O(function(l){if(1==l.g){b=[];for(c in a.l)for(d=a.l[c],e=d[0],a.l[c]=d.slice(0,1),e&&b.push(e.p.catch(ze)),f=t(d.slice(1)),g=f.next();!g.done;g=f.next())h=g.value,h.p.reject(new T(2,7,7003,void 0));a.g&&b.push(a.g.destroy());a.F&&b.push(a.F.destroy());for(k in a.j)b.push(a.j[k].destroy());return F(l,Promise.all(b),2)}a.s&&(a.s.release(),a.s=null);a.i&&(a.i.removeAttribute("src"),a.i.load(),a.i=null);a.A=null;a.m=null;a.g=null;a.F=null;a.h={};a.j={};a.H=null;
377
- a.l={};a.Y=null;a.K=null;a.da=null;H(l)})}r.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=Wd,F(m,e.L,2);case 2:e.B=b,e.ba=c,e.Fa=d,e.Ea=!e.B&&"HLS"==e.ba&&!e.Fa,e.K=null,g=t(a.keys()),h=g.next();case 3:if(h.done){m.u(0);break}k=h.value;l=a.get(k);return F(m,Pj(e,k,l,l.codecs),6);case 6:e.o?(e.l[f.X]=[],e.l[f.ha]=[]):e.l[k]=[],h=g.next(),m.u(3)}})};
378
- function Pj(a,b,c,d){var e,f,g,h,k,l,m,n,q,p,w,u;return O(function(v){switch(v.g){case 1:return e=Wd,f=Pa,g=Qa,F(v,Oj(c,b),2);case 2:g.call(f,v.h,"Type negotiation should happen before MediaSourceEngine.init!");h=Zd(c.mimeType,d);if(b==e.ua){Qj(a,h,a.B,c.external);v.u(0);break}k=a.A.forceTransmux;if(!mb(h)||!a.B&&$d.includes(h))k=!0;l=ae(c.mimeType,d);if(!k){v.u(4);break}m=Sd(e.X,(d||"").split(","));n=Sd(e.ha,(d||"").split(","));if(!m||!n){v.u(5);break}a.o=!0;return F(v,Pj(a,e.X,c,m),6);case 6:return F(v,
379
- Pj(a,e.ha,c,n),7);case 7:return v.return();case 5:if(q=lc(l))p=q(),a.j[b]=p,h=p.convertCodecs(b,l);case 4:w=h+a.A.addExtraFeaturesToSourceBuffer(h);Cg(a.I);try{u=a.m.addSourceBuffer(w)}catch(A){throw new T(2,3,3015,A,"The mediaSource_ status was "+a.m.readyState+" expected 'open'",null);}a.B&&(u.mode=Rj);a.s.D(u,"error",function(){var A=a.l[b][0];A.p.reject(new T(2,3,3014,a.i.error?a.i.error.code:0,A.uri))});a.s.D(u,"updateend",function(){return Sj(a,b)});a.h[b]=u;a.G[b]=h;a.Da[b]=!!c.drmInfos.length;
380
- H(v)}})}r.configure=function(a){this.A=a;this.g&&(this.g.A=a.modifyCueCallback)};
377
+ a.l={};a.Y=null;a.K=null;a.da=null;H(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=Wd,F(m,e.L,2);case 2:e.B=b,e.ba=c,e.Fa=d,e.Ea=!e.B&&"HLS"==e.ba&&!e.Fa,e.K=null,g=t(a.keys()),h=g.next();case 3:if(h.done){m.u(0);break}k=h.value;l=a.get(k);return F(m,Pj(e,k,l,l.codecs),6);case 6:e.o?(e.l[f.X]=[],e.l[f.ha]=[]):e.l[k]=[],h=g.next(),m.u(3)}})};
378
+ function Pj(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=Wd,f=Pa,g=Qa,F(w,Oj(c,b),2);case 2:g.call(f,w.h,"Type negotiation should happen before MediaSourceEngine.init!");h=Zd(c.mimeType,d);if(b==e.ua){Qj(a,h,a.B,c.external);w.u(0);break}k=a.A.forceTransmux;if(!mb(h)||!a.B&&$d.includes(h))k=!0;l=ae(c.mimeType,d);if(!k){w.u(4);break}m=Sd(e.X,(d||"").split(","));n=Sd(e.ha,(d||"").split(","));if(!m||!n){w.u(5);break}a.o=!0;return F(w,Pj(a,e.X,c,m),6);case 6:return F(w,
379
+ Pj(a,e.ha,c,n),7);case 7:return w.return();case 5:if(p=lc(l))r=p(),a.j[b]=r,h=r.convertCodecs(b,l);case 4:u=h+a.A.addExtraFeaturesToSourceBuffer(h);Cg(a.I);try{v=a.m.addSourceBuffer(u)}catch(A){throw new T(2,3,3015,A,"The mediaSource_ status was "+a.m.readyState+" expected 'open'",null);}a.B&&(v.mode=Rj);a.s.D(v,"error",function(){var A=a.l[b][0];A.p.reject(new T(2,3,3014,a.i.error?a.i.error.code:0,A.uri))});a.s.D(v,"updateend",function(){return Sj(a,b)});a.h[b]=v;a.G[b]=h;a.Da[b]=!!c.drmInfos.length;
380
+ H(w)}})}q.configure=function(a){this.A=a;this.g&&(this.g.A=a.modifyCueCallback)};
381
381
  function Qj(a,b,c,d){a.g||(a.g=new pe(a.F),a.g&&(a.g.A=a.A.modifyCueCallback));var e=a.g;d=d||a.fa;a=a.ba;"application/cea-608"==b||"application/cea-708"==b?e.i=null:(e.i=(0,re[b])(),e.i.setSequenceMode?e.i.setSequenceMode(c):qb("Text parsers w/ setSequenceMode",'Text parsers should have a "setSequenceMode" method!'),e.i.setManifestType?e.i.setManifestType(a):qb("Text parsers w/ setManifestType",'Text parsers should have a "setManifestType" method!'),e.B=d)}
382
382
  function Tj(a){return a.C?!1:a.m?"ended"==a.m.readyState:!0}function Uj(a,b){a.C||!Object.keys(a.h).length?a=null:b==Ud?a=a.g.g:(a=Vj(a,b),a=!a||Ji(a)?null:1==a.length&&0>a.start(0)?0:a.length?a.start(0):null);return a}function Wj(a,b){return a.C?null:b==Ud?a.g.h:Ki(Vj(a,b))}function Xj(a,b,c){if(a.C)return 0;if(b==Ud)return a=a.g,null==a.h||a.h<c?0:a.h-Math.max(c,a.g);a=Vj(a,b);return Pi(a,c)}
383
- r.wb=function(){var a={total:this.C?[]:Qi(this.i.buffered),audio:this.C?[]:Qi(Vj(this,"audio")),video:this.C?[]:Qi(Vj(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 Vj(a,b){try{return a.h[b].buffered}catch(c){return null}}
383
+ q.wb=function(){var a={total:this.C?[]:Qi(this.i.buffered),audio:this.C?[]:Qi(Vj(this,"audio")),video:this.C?[]:Qi(Vj(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 Vj(a,b){try{return a.h[b].buffered}catch(c){return null}}
384
384
  function Yj(a,b,c,d,e,f){var g=null,h=zb(c);if($d.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.da.onMetadata([{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.$&&d.$.timescale){var k=d.$.timescale;if(!isNaN(k)){var l=0,m=!1;(new Lg).box("moof",Qg).box("traf",Qg).S("tfdt",function(n){l=$i(n.reader,
385
385
  n.version).baseMediaDecodeTime/k;m=!0;n.parser.stop()}).parse(c,!0);m&&(g=l)}}else if(!e.includes("/mp4")&&!e.includes("/webm")&&Gj(h)&&(a.K?a.K.clearData():a.K=new sj,h=a.K.parse(h),b=h.getStartTime(b),null!=b&&(g=b),h=h.getMetadata(),h.length))a.da.onMetadata(h,f,d?d.endTime:null);return g}
386
- function Zj(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,q,p,w,u,v,A,z,D,y,B,C,E;return O(function(G){switch(G.g){case 1:m=Wd;if(b!=m.ua){G.u(2);break}if(!a.B){G.u(3);break}return F(G,a.za,4);case 4:n=G.h,a.g.s=n;case 3:return F(G,te(a.g,c,d?d.startTime:null,d?d.endTime:null,d?d.M()[0]:null),5);case 5:return G.return();case 2:if(l||!a.o){G.u(6);break}return F(G,Zj(a,m.X,c,d,e,f,g,h,k,!0),7);case 7:return F(G,Zj(a,m.ha,c,d,e,f,g,h,k,!0),8);case 8:return G.return();
387
- case 6:if(!a.h[b])return G.return();q=a.h[b].timestampOffset;p=a.G[b];a.j[b]&&(p=a.j[b].getOriginalMimeType());d&&(w=Yj(a,b,c,d,p,q),null!=w&&(null==a.T&&b==m.ha&&(a.T=w,a.ya=d.startTime,null!=a.O&&(u=0,a.ya==a.qa&&(u=a.T-a.O),a.la.resolve(u))),null==a.O&&b==m.X&&(a.O=w,a.qa=d.startTime,null!=a.T&&(v=0,a.ya==a.qa&&(v=a.T-a.O),a.la.resolve(v))),A=d.startTime-w,z=Math.abs(q-A),(.001<=z||g||h)&&(!k||0<A||!q)&&(q=A,a.Ea&&(ak(a,b,function(){return bk(a,b)},null),ak(a,b,function(){return ck(a,b,q)},null))),
388
- D=b==m.ha||!(m.ha in a.h),a.B&&D&&a.za.resolve(q)));f&&b==m.ha&&(a.g||Qj(a,"application/cea-608",a.B,!1),a.H||(y=p.split(";",1)[0],a.H=new Gb(y)),d?(B=a.H.i(c),B.length&&xe(a.g,B,d.startTime,d.endTime,q)):a.H.init(c,h));if(!a.j[b]){G.u(9);break}return F(G,a.j[b].transmux(c,e,d,a.m.duration,b),10);case 10:c=G.h;case 9:c=dk(a,c,d?d.startTime:null,b,d?d.M()[0]:null);if(!d||!a.B||b==m.ua){G.u(11);break}if(!g&&!h){G.u(11);break}C=d.startTime;if("HLS"!=a.ba||a.o||b!=m.X||!a.h[m.ha]){G.u(13);break}return F(G,
389
- a.la,14);case 14:E=G.h,.1<Math.abs(E)&&(C-=E);case 13:ak(a,b,function(){return bk(a,b)},null),ak(a,b,function(){return ck(a,b,C)},null);case 11:return F(G,ak(a,b,function(){var L=c;if("video"==b&&a.Y){var K=a.Y;K.g&&K.g.appendBuffer(L,"video",K.o,-q)}a.h[b].appendBuffer(L)},d?d.M()[0]:null),15);case 15:H(G)}})}function ek(a,b){var c=Wj(a,"video")||0;ve(a.g,b,c)}function fk(a){a.g&&ve(a.g,"",0)}
390
- r.remove=function(a,b,c){var d=this,e;return O(function(f){return 1==f.g?(e=Wd,a==e.ua?F(f,d.g.remove(b,c),0):F(f,ak(d,a,function(){return gk(d,a,b,c)},null),4)):d.o?F(f,ak(d,e.X,function(){return gk(d,e.X,b,c)},null),0):f.u(0)})};function hk(a,b){var c;return O(function(d){return 1==d.g?(c=Wd,b==c.ua?a.g?F(d,a.g.remove(0,Infinity),0):d.return():F(d,ak(a,b,function(){return gk(a,b,0,a.m.duration)},null),4)):a.o?F(d,ak(a,c.X,function(){return gk(a,c.X,0,a.m.duration)},null),0):d.u(0)})}
391
- r.flush=function(a){var b=this,c;return O(function(d){return 1==d.g?(c=Wd,a==c.ua?d.return():F(d,ak(b,a,function(){b.i.currentTime-=.001;Sj(b,a)},null),2)):b.o?F(d,ak(b,c.X,function(){var e=c.X;b.i.currentTime-=.001;Sj(b,e)},null),0):d.u(0)})};
392
- function ik(a,b,c,d,e,f,g,h,k){var l,m,n;return O(function(q){if(1==q.g){l=Wd;if(b==l.ua)return f||(a.g.s=c),ue(a.g,d,e),q.return();m=[];return F(q,jk(a,b,g,h,k),2)}n=q.h;n||(m.push(ak(a,b,function(){return bk(a,b)},null)),a.o&&m.push(ak(a,l.X,function(){return bk(a,l.X)},null)));f||(m.push(ak(a,b,function(){return ck(a,b,c)},null)),a.o&&m.push(ak(a,l.X,function(){return ck(a,l.X,c)},null)));m.push(ak(a,b,function(){a.h[b].appendWindowStart=0;a.h[b].appendWindowEnd=e;a.h[b].appendWindowStart=d;Sj(a,
393
- b)},null));a.o&&m.push(ak(a,l.X,function(){var p=l.X;a.h[p].appendWindowStart=0;a.h[p].appendWindowEnd=e;a.h[p].appendWindowStart=d;Sj(a,p)},null));return F(q,Promise.all(m),0)})}
394
- function kk(a,b,c){var d;return O(function(e){if(1==e.g){d=Wd;if(b==d.ua)return e.return();b==d.ha&&(a.za=new bg);ak(a,b,function(){return bk(a,b)},null);a.o&&ak(a,d.X,function(){return bk(a,d.X)},null);return F(e,ak(a,b,function(){return ck(a,b,c)},null),2)}return a.o?F(e,ak(a,d.X,function(){return ck(a,d.X,c)},null),0):e.u(0)})}r.endOfStream=function(a){var b=this;return O(function(c){return F(c,lk(b,function(){Tj(b)||"closed"===b.m.readyState||(a?b.m.endOfStream(a):b.m.endOfStream())}),0)})};
395
- r.Za=function(a){var b=this;return O(function(c){return F(c,lk(b,function(){if(a<b.m.duration)for(var d in b.h){var e={start:function(){},p:new bg,uri:null};b.l[d].unshift(e)}b.m.duration=a;b.ea=a}),0)})};r.getDuration=function(){return this.m.duration};function gk(a,b,c,d){d<=c?Sj(a,b):a.h[b].remove(c,d)}function bk(a,b){var c=a.h[b].appendWindowStart,d=a.h[b].appendWindowEnd;a.h[b].abort();a.h[b].appendWindowStart=c;a.h[b].appendWindowEnd=d;Sj(a,b)}
386
+ function Zj(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,D,y,B,C,E;return O(function(G){switch(G.g){case 1:m=Wd;if(b!=m.ua){G.u(2);break}if(!a.B){G.u(3);break}return F(G,a.za,4);case 4:n=G.h,a.g.s=n;case 3:return F(G,te(a.g,c,d?d.startTime:null,d?d.endTime:null,d?d.M()[0]:null),5);case 5:return G.return();case 2:if(l||!a.o){G.u(6);break}return F(G,Zj(a,m.X,c,d,e,f,g,h,k,!0),7);case 7:return F(G,Zj(a,m.ha,c,d,e,f,g,h,k,!0),8);case 8:return G.return();
387
+ case 6:if(!a.h[b])return G.return();p=a.h[b].timestampOffset;r=a.G[b];a.j[b]&&(r=a.j[b].getOriginalMimeType());d&&(u=Yj(a,b,c,d,r,p),null!=u&&(null==a.T&&b==m.ha&&(a.T=u,a.ya=d.startTime,null!=a.O&&(v=0,a.ya==a.qa&&(v=a.T-a.O),a.la.resolve(v))),null==a.O&&b==m.X&&(a.O=u,a.qa=d.startTime,null!=a.T&&(w=0,a.ya==a.qa&&(w=a.T-a.O),a.la.resolve(w))),A=d.startTime-u,z=Math.abs(p-A),(.001<=z||g||h)&&(!k||0<A||!p)&&(p=A,a.Ea&&(ak(a,b,function(){return bk(a,b)},null),ak(a,b,function(){return ck(a,b,p)},null))),
388
+ D=b==m.ha||!(m.ha in a.h),a.B&&D&&a.za.resolve(p)));f&&b==m.ha&&(a.g||Qj(a,"application/cea-608",a.B,!1),a.H||(y=r.split(";",1)[0],a.H=new Gb(y)),d?(B=a.H.i(c),B.length&&xe(a.g,B,d.startTime,d.endTime,p)):a.H.init(c,h));if(!a.j[b]){G.u(9);break}return F(G,a.j[b].transmux(c,e,d,a.m.duration,b),10);case 10:c=G.h;case 9:c=dk(a,c,d?d.startTime:null,b,d?d.M()[0]:null);if(!d||!a.B||b==m.ua){G.u(11);break}if(!g&&!h){G.u(11);break}C=d.startTime;if("HLS"!=a.ba||a.o||b!=m.X||!a.h[m.ha]){G.u(13);break}return F(G,
389
+ a.la,14);case 14:E=G.h,.1<Math.abs(E)&&(C-=E);case 13:ak(a,b,function(){return bk(a,b)},null),ak(a,b,function(){return ck(a,b,C)},null);case 11:return F(G,ak(a,b,function(){var L=c;if("video"==b&&a.Y){var K=a.Y;K.g&&K.g.appendBuffer(L,"video",K.o,-p)}a.h[b].appendBuffer(L)},d?d.M()[0]:null),15);case 15:H(G)}})}function ek(a,b){var c=Wj(a,"video")||0;ve(a.g,b,c)}function fk(a){a.g&&ve(a.g,"",0)}
390
+ q.remove=function(a,b,c){var d=this,e;return O(function(f){return 1==f.g?(e=Wd,a==e.ua?F(f,d.g.remove(b,c),0):F(f,ak(d,a,function(){return gk(d,a,b,c)},null),4)):d.o?F(f,ak(d,e.X,function(){return gk(d,e.X,b,c)},null),0):f.u(0)})};function hk(a,b){var c;return O(function(d){return 1==d.g?(c=Wd,b==c.ua?a.g?F(d,a.g.remove(0,Infinity),0):d.return():F(d,ak(a,b,function(){return gk(a,b,0,a.m.duration)},null),4)):a.o?F(d,ak(a,c.X,function(){return gk(a,c.X,0,a.m.duration)},null),0):d.u(0)})}
391
+ q.flush=function(a){var b=this,c;return O(function(d){return 1==d.g?(c=Wd,a==c.ua?d.return():F(d,ak(b,a,function(){b.i.currentTime-=.001;Sj(b,a)},null),2)):b.o?F(d,ak(b,c.X,function(){var e=c.X;b.i.currentTime-=.001;Sj(b,e)},null),0):d.u(0)})};
392
+ function ik(a,b,c,d,e,f,g,h,k){var l,m,n;return O(function(p){if(1==p.g){l=Wd;if(b==l.ua)return f||(a.g.s=c),ue(a.g,d,e),p.return();m=[];return F(p,jk(a,b,g,h,k),2)}n=p.h;n||(m.push(ak(a,b,function(){return bk(a,b)},null)),a.o&&m.push(ak(a,l.X,function(){return bk(a,l.X)},null)));f||(m.push(ak(a,b,function(){return ck(a,b,c)},null)),a.o&&m.push(ak(a,l.X,function(){return ck(a,l.X,c)},null)));m.push(ak(a,b,function(){a.h[b].appendWindowStart=0;a.h[b].appendWindowEnd=e;a.h[b].appendWindowStart=d;Sj(a,
393
+ b)},null));a.o&&m.push(ak(a,l.X,function(){var r=l.X;a.h[r].appendWindowStart=0;a.h[r].appendWindowEnd=e;a.h[r].appendWindowStart=d;Sj(a,r)},null));return F(p,Promise.all(m),0)})}
394
+ function kk(a,b,c){var d;return O(function(e){if(1==e.g){d=Wd;if(b==d.ua)return e.return();b==d.ha&&(a.za=new bg);ak(a,b,function(){return bk(a,b)},null);a.o&&ak(a,d.X,function(){return bk(a,d.X)},null);return F(e,ak(a,b,function(){return ck(a,b,c)},null),2)}return a.o?F(e,ak(a,d.X,function(){return ck(a,d.X,c)},null),0):e.u(0)})}q.endOfStream=function(a){var b=this;return O(function(c){return F(c,lk(b,function(){Tj(b)||"closed"===b.m.readyState||(a?b.m.endOfStream(a):b.m.endOfStream())}),0)})};
395
+ q.Za=function(a){var b=this;return O(function(c){return F(c,lk(b,function(){if(a<b.m.duration)for(var d in b.h){var e={start:function(){},p:new bg,uri:null};b.l[d].unshift(e)}b.m.duration=a;b.ea=a}),0)})};q.getDuration=function(){return this.m.duration};function gk(a,b,c,d){d<=c?Sj(a,b):a.h[b].remove(c,d)}function bk(a,b){var c=a.h[b].appendWindowStart,d=a.h[b].appendWindowEnd;a.h[b].abort();a.h[b].appendWindowStart=c;a.h[b].appendWindowEnd=d;Sj(a,b)}
396
396
  function ck(a,b,c){0>c&&(c+=.001);a.h[b].timestampOffset=c;Sj(a,b)}function Sj(a,b){if(!a.C){var c=a.l[b][0];c&&(c.p.resolve(),mk(a,b))}}function ak(a,b,c,d){Cg(a.I);c={start:c,p:new bg,uri:d};a.l[b].push(c);1==a.l[b].length&&nk(a,b);return c.p}
397
397
  function lk(a,b){var c,d,e,f,g,h,k;return O(function(l){switch(l.g){case 1:Cg(a.I);c=[];d={};for(e in a.h)d={ready:void 0},d.ready=new bg,f={start:function(m){return function(){return m.ready.resolve()}}(d),p:d.ready,uri:null},a.l[e].push(f),c.push(d.ready),1==a.l[e].length&&f.start();ra(l,2);return F(l,Promise.all(c),4);case 4:ta(l,3);break;case 2:throw g=ua(l),g;case 3:return ra(l,5,6),F(l,b(),6);case 6:va(l);for(h in a.h)mk(a,h);wa(l,0);break;case 5:throw k=ua(l),new T(2,3,3015,k,a.i.error||"No error in the media element",
398
398
  null);}})}function mk(a,b){a.l[b].shift();nk(a,b)}function nk(a,b){var c=a.l[b][0];if(c)try{c.start()}catch(d){"QuotaExceededError"==d.name?c.p.reject(new T(2,3,3017,b)):c.p.reject(new T(2,3,3015,d,a.i.error||"No error in the media element",c.uri)),mk(a,b)}}function dk(a,b,c,d,e){var f=null==c,g=a.Da[d];c=a.da.Qh();if(f=a.A.insertFakeEncryptionInInit&&f&&g)c=Oc(c),f=$c()||Yc()||hd()||Wc()&&md()&&c;f&&"mp4"==ee(a.G[d])&&(b=zi(b,e));return b}
399
399
  function ok(a,b,c,d){return ak(a,b,function(){b!==Ud&&(ob()&&(a.j[b]&&(a.j[b].destroy(),delete a.j[b]),d&&(a.j[b]=d),a.h[b].changeType(c+a.A.addExtraFeaturesToSourceBuffer(c)),a.G[b]=c),Sj(a,b))},null)}
400
- function pk(a,b){var c,d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L;return O(function(K){switch(K.g){case 1:c=Wd;a.C=!0;a.o=!1;d=a.i.currentTime;e=a.i.autoplay;f=a.i.paused;a.ra&&(a.i.autoplay=!1);sa(K,2);a.s.Qa();g=[];for(h in a.j)g.push(a.j[h].destroy());for(k in a.l)for(l=a.l[k],m=l[0],a.l[k]=l.slice(0,1),m&&g.push(m.p.catch(ze)),n=t(l.slice(1)),q=n.next();!q.done;q=n.next())p=q.value,p.p.reject(new T(2,7,7003,void 0));for(w in a.h){u=a.h[w];try{a.m.removeSourceBuffer(u)}catch(I){}}return F(K,
401
- Promise.all(g),4);case 4:return a.j={},a.h={},v=a.m.duration,a.L=new bg,a.m=Lj(a,a.L),F(K,a.L,5);case 5:!isNaN(v)&&v?a.m.duration=v:!isNaN(a.ea)&&a.ea&&(a.m.duration=a.ea),A=new bg,z=a.m.sourceBuffers,D=b.size,y=0,B=function(){y++;y===D&&(A.resolve(),a.s.jb(z,"addsourcebuffer",B))},a.s.D(z,"addsourcebuffer",B),C=t(b.keys()),E=C.next();case 6:if(E.done)return a.i.currentTime=d,F(K,A,2);G=E.value;L=b.get(G);return F(K,Pj(a,G,L,L.codecs),9);case 9:a.o?(a.l[c.X]=[],a.l[c.ha]=[]):a.l[G]=[];E=C.next();
400
+ function pk(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L;return O(function(K){switch(K.g){case 1:c=Wd;a.C=!0;a.o=!1;d=a.i.currentTime;e=a.i.autoplay;f=a.i.paused;a.ra&&(a.i.autoplay=!1);sa(K,2);a.s.Qa();g=[];for(h in a.j)g.push(a.j[h].destroy());for(k in a.l)for(l=a.l[k],m=l[0],a.l[k]=l.slice(0,1),m&&g.push(m.p.catch(ze)),n=t(l.slice(1)),p=n.next();!p.done;p=n.next())r=p.value,r.p.reject(new T(2,7,7003,void 0));for(u in a.h){v=a.h[u];try{a.m.removeSourceBuffer(v)}catch(I){}}return F(K,
401
+ Promise.all(g),4);case 4:return a.j={},a.h={},w=a.m.duration,a.L=new bg,a.m=Lj(a,a.L),F(K,a.L,5);case 5:!isNaN(w)&&w?a.m.duration=w:!isNaN(a.ea)&&a.ea&&(a.m.duration=a.ea),A=new bg,z=a.m.sourceBuffers,D=b.size,y=0,B=function(){y++;y===D&&(A.resolve(),a.s.jb(z,"addsourcebuffer",B))},a.s.D(z,"addsourcebuffer",B),C=t(b.keys()),E=C.next();case 6:if(E.done)return a.i.currentTime=d,F(K,A,2);G=E.value;L=b.get(G);return F(K,Pj(a,G,L,L.codecs),9);case 9:a.o?(a.l[c.X]=[],a.l[c.ha]=[]):a.l[G]=[];E=C.next();
402
402
  K.u(6);break;case 2:va(K),a.C=!1,Cg(a.I),a.s.ja(a.i,"canplaythrough",function(){a.I.g||(a.i.autoplay=e,f||a.i.play())}),wa(K,0)}})}function qk(a,b){return lk(a,function(){return pk(a,b)})}
403
- function jk(a,b,c,d,e){var f,g,h,k,l,m,n,q,p,w,u,v,A,z,D;return O(function(y){if(1==y.g){f=Wd;if(b==f.ua)return y.return(!1);g=fe(je(a.G[b]));h=ie(a.G[b]);l=!1;m=Zd(c,d);n=a.A.forceTransmux;if(!mb(m)||!a.B&&$d.includes(m))n=!0;n&&(q=ae(c,d),p=lc(q))&&(k=p(),w=Sd(f.X,(d||"").split(",")),u=Sd(f.ha,(d||"").split(",")),w&&u?(l=!0,v=u,b==f.X&&(v=w),m=k.convertCodecs(b,ae(c,v))):m=k.convertCodecs(b,q));A=fe(je(m));z=ie(m);if(g===A&&h===z)return a.j[b]&&!k?(a.j[b].destroy(),delete a.j[b]):!a.j[b]&&k?a.j[b]=
403
+ function jk(a,b,c,d,e){var f,g,h,k,l,m,n,p,r,u,v,w,A,z,D;return O(function(y){if(1==y.g){f=Wd;if(b==f.ua)return y.return(!1);g=fe(je(a.G[b]));h=ie(a.G[b]);l=!1;m=Zd(c,d);n=a.A.forceTransmux;if(!mb(m)||!a.B&&$d.includes(m))n=!0;n&&(p=ae(c,d),r=lc(p))&&(k=r(),u=Sd(f.X,(d||"").split(",")),v=Sd(f.ha,(d||"").split(",")),u&&v?(l=!0,w=v,b==f.X&&(w=u),m=k.convertCodecs(b,ae(c,w))):m=k.convertCodecs(b,p));A=fe(je(m));z=ie(m);if(g===A&&h===z)return a.j[b]&&!k?(a.j[b].destroy(),delete a.j[b]):!a.j[b]&&k?a.j[b]=
404
404
  k:k&&(a.j[b]&&a.j[b].transmux!=k.transmux?(a.j[b].destroy(),delete a.j[b],a.j[b]=k):k.destroy()),y.return(!1);D=!0;if(a.o||l&&k&&!a.j[b])D=!1;if(D&&"smooth"===a.A.codecSwitchingStrategy&&ob())return F(y,ok(a,b,m,k),3);k&&k.destroy();return F(y,qk(a,e),3)}return y.return(!0)})}
405
- function rk(a,b,c,d){if(b==Ud)var e=!1;else{e=fe(je(a.G[b]));var f=ie(a.G[b]),g=Zd(c,d),h=a.A.forceTransmux;if(!mb(g)||!a.B&&$d.includes(g))h=!0;c=ae(c,d);h&&(h=lc(c))&&(h=h(),g=h.convertCodecs(b,c),h.destroy());b=fe(je(g));g=ie(g);e=e!==b||f!==g}return e?"smooth"!==a.A.codecSwitchingStrategy||!ob()||a.o:!1}var Nj=window.URL.createObjectURL,Rj="sequence";function sk(a,b,c){this.i=a;this.A=b;this.o=this.j=Infinity;this.g=1;this.h=this.l=null;this.B=0;this.G=!0;this.H=0;this.C=void 0===c?!0:c;this.F=0;this.s=!1;this.m=a}r=sk.prototype;r.getDuration=function(){return this.j};r.Sh=function(){return this.g};r.dh=function(a){this.i=a};r.Za=function(a){this.j=a};r.Xh=function(){return this.i};r.ah=function(a){this.B=a};r.tc=function(a){this.G=a};r.oe=function(a){this.o=a};r.Ld=function(){return this.o};r.Of=function(a){this.A=a};r.Lh=function(){return this.A};
406
- r.Ng=function(a,b){if(0!=a.length){var c=(Date.now()+this.B)/1E3;a=a.filter(function(e){return e.start+b<c});if(0!=a.length){var d=a[a.length-1].end+b;this.ae(a[0].start+b);this.g=a.reduce(function(e,f){return Math.max(e,f.end-f.start)},this.g);this.h=Math.max(this.h,d);null!=this.i&&this.C&&!this.s&&(this.i=c-this.h-this.g)}}};
407
- r.qd=function(a){if(0!=a.length){var b=a[0].startTime,c=a[0].endTime,d=(Date.now()+this.B)/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.ae(b);this.h=Math.max(this.h,c);null!=this.i&&this.C&&!this.s&&(this.i=d-this.h-this.g)}};r.Th=function(){return this.h};r.Ud=function(){this.s=!0};r.si=function(){return this.s};r.bh=function(a){this.m=a};r.Ph=function(){return this.m};
408
- r.ae=function(a){this.l=null==this.l?a:Math.min(this.l,a)};r.xf=function(a){this.g=Math.max(this.g,a)};r.offset=function(a){null!=this.l&&(this.l+=a);null!=this.h&&(this.h+=a)};r.V=function(){return Infinity==this.j&&!this.G};r.mc=function(){return Infinity!=this.j&&!this.G};r.mb=function(){return Math.max(this.H,this.Wb()-this.o)};r.hh=function(a){this.H=a};
409
- r.Wb=function(){return this.V()||this.mc()?Math.min(Math.max(0,(Date.now()+this.B)/1E3-this.g-this.i)+this.F,this.j):this.h?Math.min(this.h,this.j):this.j};r.ad=function(a){var b=Math.max(this.l,this.H);return Infinity==this.o?Math.ceil(1E3*b)/1E3:Math.max(b,Math.min(this.Wb()-this.o+a,this.yb()))};r.Vb=function(){return this.ad(0)};r.yb=function(){return Math.max(0,this.Wb()-(this.V()||this.mc()?this.A:0))};r.nh=function(){return null==this.i||null!=this.h&&this.C?!1:!0};
410
- r.$g=function(a){this.F=a};r.Jh=function(){return this.F};S("shaka.media.PresentationTimeline",sk);sk.prototype.getAvailabilityTimeOffset=sk.prototype.Jh;sk.prototype.setAvailabilityTimeOffset=sk.prototype.$g;sk.prototype.usingPresentationStartTime=sk.prototype.nh;sk.prototype.getSeekRangeEnd=sk.prototype.yb;sk.prototype.getSeekRangeStart=sk.prototype.Vb;sk.prototype.getSafeSeekRangeStart=sk.prototype.ad;sk.prototype.getSegmentAvailabilityEnd=sk.prototype.Wb;sk.prototype.setUserSeekStart=sk.prototype.hh;
405
+ function rk(a,b,c,d){if(b==Ud)var e=!1;else{e=fe(je(a.G[b]));var f=ie(a.G[b]),g=Zd(c,d),h=a.A.forceTransmux;if(!mb(g)||!a.B&&$d.includes(g))h=!0;c=ae(c,d);h&&(h=lc(c))&&(h=h(),g=h.convertCodecs(b,c),h.destroy());b=fe(je(g));g=ie(g);e=e!==b||f!==g}return e?"smooth"!==a.A.codecSwitchingStrategy||!ob()||a.o:!1}var Nj=window.URL.createObjectURL,Rj="sequence";function sk(a,b,c){this.i=a;this.A=b;this.o=this.j=Infinity;this.g=1;this.h=this.l=null;this.B=0;this.G=!0;this.H=0;this.C=void 0===c?!0:c;this.F=0;this.s=!1;this.m=a}q=sk.prototype;q.getDuration=function(){return this.j};q.Sh=function(){return this.g};q.dh=function(a){this.i=a};q.Za=function(a){this.j=a};q.Xh=function(){return this.i};q.ah=function(a){this.B=a};q.tc=function(a){this.G=a};q.oe=function(a){this.o=a};q.Ld=function(){return this.o};q.Of=function(a){this.A=a};q.Lh=function(){return this.A};
406
+ q.Ng=function(a,b){if(0!=a.length){var c=(Date.now()+this.B)/1E3;a=a.filter(function(e){return e.start+b<c});if(0!=a.length){var d=a[a.length-1].end+b;this.ae(a[0].start+b);this.g=a.reduce(function(e,f){return Math.max(e,f.end-f.start)},this.g);this.h=Math.max(this.h,d);null!=this.i&&this.C&&!this.s&&(this.i=c-this.h-this.g)}}};
407
+ q.qd=function(a){if(0!=a.length){var b=a[0].startTime,c=a[0].endTime,d=(Date.now()+this.B)/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.ae(b);this.h=Math.max(this.h,c);null!=this.i&&this.C&&!this.s&&(this.i=d-this.h-this.g)}};q.Th=function(){return this.h};q.Ud=function(){this.s=!0};q.si=function(){return this.s};q.bh=function(a){this.m=a};q.Ph=function(){return this.m};
408
+ q.ae=function(a){this.l=null==this.l?a:Math.min(this.l,a)};q.xf=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.V=function(){return Infinity==this.j&&!this.G};q.mc=function(){return Infinity!=this.j&&!this.G};q.mb=function(){return Math.max(this.H,this.Wb()-this.o)};q.hh=function(a){this.H=a};
409
+ q.Wb=function(){return this.V()||this.mc()?Math.min(Math.max(0,(Date.now()+this.B)/1E3-this.g-this.i)+this.F,this.j):this.h?Math.min(this.h,this.j):this.j};q.bd=function(a){var b=Math.max(this.l,this.H);return Infinity==this.o?Math.ceil(1E3*b)/1E3:Math.max(b,Math.min(this.Wb()-this.o+a,this.yb()))};q.Vb=function(){return this.bd(0)};q.yb=function(){return Math.max(0,this.Wb()-(this.V()||this.mc()?this.A:0))};q.nh=function(){return null==this.i||null!=this.h&&this.C?!1:!0};
410
+ q.$g=function(a){this.F=a};q.Jh=function(){return this.F};S("shaka.media.PresentationTimeline",sk);sk.prototype.getAvailabilityTimeOffset=sk.prototype.Jh;sk.prototype.setAvailabilityTimeOffset=sk.prototype.$g;sk.prototype.usingPresentationStartTime=sk.prototype.nh;sk.prototype.getSeekRangeEnd=sk.prototype.yb;sk.prototype.getSeekRangeStart=sk.prototype.Vb;sk.prototype.getSafeSeekRangeStart=sk.prototype.bd;sk.prototype.getSegmentAvailabilityEnd=sk.prototype.Wb;sk.prototype.setUserSeekStart=sk.prototype.hh;
411
411
  sk.prototype.getSegmentAvailabilityStart=sk.prototype.mb;sk.prototype.isInProgress=sk.prototype.mc;sk.prototype.isLive=sk.prototype.V;sk.prototype.offset=sk.prototype.offset;sk.prototype.notifyMaxSegmentDuration=sk.prototype.xf;sk.prototype.notifyMinSegmentStartTime=sk.prototype.ae;sk.prototype.getInitialProgramDateTime=sk.prototype.Ph;sk.prototype.setInitialProgramDateTime=sk.prototype.bh;sk.prototype.isStartTimeLocked=sk.prototype.si;sk.prototype.lockStartTime=sk.prototype.Ud;
412
412
  sk.prototype.getMaxSegmentEndTime=sk.prototype.Th;sk.prototype.notifySegments=sk.prototype.qd;sk.prototype.notifyTimeRange=sk.prototype.Ng;sk.prototype.getDelay=sk.prototype.Lh;sk.prototype.setDelay=sk.prototype.Of;sk.prototype.getSegmentAvailabilityDuration=sk.prototype.Ld;sk.prototype.setSegmentAvailabilityDuration=sk.prototype.oe;sk.prototype.setStatic=sk.prototype.tc;sk.prototype.setClockOffset=sk.prototype.ah;sk.prototype.getPresentationStartTime=sk.prototype.Xh;sk.prototype.setDuration=sk.prototype.Za;
413
413
  sk.prototype.setPresentationStartTime=sk.prototype.dh;sk.prototype.getMaxSegmentDuration=sk.prototype.Sh;sk.prototype.getDuration=sk.prototype.getDuration;function tk(a,b,c){this.j=c;this.l=a;this.s=uk(a);this.g=a.g.currentTime;this.m=Date.now()/1E3;this.h=!1;this.o=0;this.A=b;this.i=function(){}}tk.prototype.release=function(){this.j=this.l=null;this.i=function(){}};function vk(a,b){a.i=b}function wk(a){this.g=a}function uk(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 xk(a,b,c,d,e){var f=this;this.A=e;this.g=a;this.B=b;this.s=c;this.l=new gb;this.j=!1;this.F=a.readyState;this.C=this.i=0;this.h=d;this.o=!1;this.l.D(a,"waiting",function(){return yk(f)});this.m=(new Sc(function(){yk(f)})).Ra(this.s.gapJumpTimerTime)}xk.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.B=this.A=null};xk.prototype.Af=function(){this.o=!0;yk(this)};
414
414
  function yk(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.F&&(a.F=a.g.readyState);var b;if(!(b=!a.h)){b=a.h;var c=b.l,d=uk(c),e=c.g.currentTime,f=Date.now()/1E3;if(b.g!=e||b.s!=d)b.m=f,b.g=e,b.s=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 U("stalldetected"));b=!d}if(b&&(b=a.g.currentTime,c=a.g.buffered,d=Ri(c,b,a.s.gapDetectionThreshold),
415
415
  null!=d&&(0!=d||a.o))){e=c.start(d);if(navigator.userAgent.match(/Edge\//)||Yc())e=Math.ceil(100*(e+.01))/100;e>=a.B.yb()||.001>e-b||(0!=d&&c.end(d-1),a.g.currentTime=e,b==a.i&&(a.i=e),a.C++,a.A(new U("gapjumped")))}}}};function zk(a,b,c,d){b==HTMLMediaElement.HAVE_NOTHING||a.readyState>=b?d():(b=Ak.value().get(b),c.ja(a,b,d))}var Ak=new Kc(function(){return new Map([[HTMLMediaElement.HAVE_METADATA,"loadedmetadata"],[HTMLMediaElement.HAVE_CURRENT_DATA,"loadeddata"],[HTMLMediaElement.HAVE_FUTURE_DATA,"canplay"],[HTMLMediaElement.HAVE_ENOUGH_DATA,"canplaythrough"]])});function Bk(a,b,c,d){var e=this;this.g=a;this.m=b;this.s=c;this.l=null;this.j=function(){null==e.l&&(e.l=d());return e.l};this.o=!1;this.h=new gb;this.i=new Ck(a);zk(this.g,HTMLMediaElement.HAVE_METADATA,this.h,function(){Dk(e,e.j())})}Bk.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 Ek(a){return a.o?a.g.currentTime:a.j()}
416
416
  function Fk(a,b){0<a.g.readyState?Gk(a.i,b):zk(a.g,HTMLMediaElement.HAVE_METADATA,a.h,function(){Dk(a,a.j())})}function Dk(a,b){.001>Math.abs(a.g.currentTime-b)?Hk(a):(a.h.ja(a.g,"seeking",function(){Hk(a)}),Gk(a.i,a.g.currentTime&&0!=a.g.currentTime?a.g.currentTime:b))}function Hk(a){a.o=!0;a.h.D(a.g,"seeking",function(){return a.m()});a.s(a.g.currentTime)}
417
- function Ck(a){var b=this;this.g=a;this.m=10;this.j=this.l=this.i=0;this.h=new Sc(function(){0>=b.i?b.h.stop():b.g.currentTime!=b.l||b.g.currentTime===b.j?b.h.stop():(b.g.currentTime=b.j,b.i--)})}Ck.prototype.release=function(){this.h&&(this.h.stop(),this.h=null);this.g=null};function Gk(a,b){a.l=a.g.currentTime;a.j=b;a.i=a.m;a.g.currentTime=b;a.h.Ra(.1)};function Ik(a){this.h=a;this.j=!1;this.g=null;this.i=new gb}r=Ik.prototype;r.ready=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.ja(b.h,"seeking",function(){b.j=!0}),b.h.currentTime=d):b.j=!0}}var b=this;zk(this.h,HTMLMediaElement.HAVE_CURRENT_DATA,this.i,function(){a()})};r.release=function(){this.i&&(this.i.release(),this.i=null);this.h=null};r.De=function(a){this.g=this.j?this.g:a};
418
- r.wd=function(){return(this.j?this.h.currentTime:this.g)||0};r.gg=function(){return 0};r.fg=function(){return 0};r.Mg=function(){};
417
+ function Ck(a){var b=this;this.g=a;this.m=10;this.j=this.l=this.i=0;this.h=new Sc(function(){0>=b.i?b.h.stop():b.g.currentTime!=b.l||b.g.currentTime===b.j?b.h.stop():(b.g.currentTime=b.j,b.i--)})}Ck.prototype.release=function(){this.h&&(this.h.stop(),this.h=null);this.g=null};function Gk(a,b){a.l=a.g.currentTime;a.j=b;a.i=a.m;a.g.currentTime=b;a.h.Ra(.1)};function Ik(a){this.h=a;this.j=!1;this.g=null;this.i=new gb}q=Ik.prototype;q.ready=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.ja(b.h,"seeking",function(){b.j=!0}),b.h.currentTime=d):b.j=!0}}var b=this;zk(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.De=function(a){this.g=this.j?this.g:a};
418
+ q.wd=function(){return(this.j?this.h.currentTime:this.g)||0};q.gg=function(){return 0};q.fg=function(){return 0};q.Mg=function(){};
419
419
  function Jk(a,b,c,d,e,f){var g=this;this.i=a;this.g=b.presentationTimeline;this.B=b.minBufferTime||0;this.l=c;this.A=e;this.s=null;this.o=Kk(a,c,f);this.j=new xk(a,b.presentationTimeline,c,this.o,f);this.h=new Bk(a,function(){a:{var h=g.j;h.j=!0;h.o=!1;var k=Ek(g.h);h=Lk(g,k);if(.001<Math.abs(h-k)){k=!1;if(!fd()||fd()&&nd())k=!0;else{var l=Date.now()/1E3;if(!g.s||g.s<l-1)g.s=l,k=!0}if(k){Fk(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)},
420
- function(){var h=d;null==h?h=Infinity>g.g.getDuration()?g.g.Vb():g.g.yb():0>h&&(h=g.g.yb()+h);return Mk(g,Nk(g,h))});this.m=new Sc(function(){if(0!=g.i.readyState&&!g.i.paused){var h=Ek(g.h),k=g.g.Vb(),l=g.g.yb();3>l-k&&(k=l-3);h<k&&(h=Lk(g,h),g.i.currentTime=h)}})}r=Jk.prototype;r.ready=function(){this.m.Ra(.25)};r.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(){}};
421
- r.De=function(a){Fk(this.h,a)};r.wd=function(){var a=Ek(this.h);return 0<this.i.readyState&&!this.i.paused?Nk(this,a):a};r.gg=function(){return this.o?this.o.o:0};r.fg=function(){return this.j.C};r.Mg=function(){this.j.Af()};function Mk(a,b){var c=a.g.getDuration();return b>=c?c-a.l.durationBackoff:b}
422
- function Lk(a,b){var c=Math.max(a.B,a.l.rebufferingGoal),d=a.l.safeSeekOffset,e=a.g.Vb(),f=a.g.yb(),g=a.g.getDuration();3>f-e&&(e=f-3);var h=a.g.ad(c),k=a.g.ad(d);c=a.g.ad(c+d);return b>=g?Mk(a,b):b>f?f:b<e?Oi(a.i.buffered,k)?k:c:b>=h||Oi(a.i.buffered,b)?b:c}function Nk(a,b){var c=a.g.Vb();if(b<c)return c;a=a.g.yb();return b>a?a:b}
423
- function Kk(a,b,c){if(!b.stallEnabled)return null;var d=b.stallSkip;b=new tk(new wk(a),b.stallThreshold,c);vk(b,function(){d?a.currentTime+=d:(a.pause(),a.play())});return b};function Ok(a){this.P=a;this.l=null;this.i=0;this.m=!1}r=Ok.prototype;r.getNumReferences=function(){return this.P.length};r.getNumEvicted=function(){return this.i};r.release=function(){this.m||(this.P=[],this.l&&this.l.stop(),this.l=null)};r.yi=function(){this.m=!0};r.Hb=function(a){for(var b=t(this.P),c=b.next();!c.done;c=b.next())a(c.value)};
424
- r.find=function(a){for(var b=this.P.length-1,c=b;0<=c;--c){var d=this.P[c],e=c<b?this.P[c+1].startTime:d.endTime;if(a>=d.startTime&&a<e)return c+this.i}return this.P.length&&a<this.P[0].startTime?this.i:null};r.get=function(a){if(0==this.P.length)return null;a-=this.i;return 0>a||a>=this.P.length?null:this.P[a]};r.offset=function(a){if(!this.m)for(var b=t(this.P),c=b.next();!c.done;c=b.next())c.value.offset(a)};
425
- r.Xd=function(a){if(!this.m&&a.length){var b=Math.round(1E3*a[0].startTime)/1E3;this.P=this.P.filter(function(c){return Math.round(1E3*c.startTime)/1E3<b});this.P.push.apply(this.P,x(a))}};r.pd=function(a,b){var c=this;a=a.filter(function(d){return d.endTime>b&&(0==c.P.length||d.endTime>c.P[0].startTime)});this.Xd(a);this.La(b)};r.La=function(a){if(!this.m){var b=this.P.length;this.P=this.P.filter(function(c){return c.endTime>a});this.i+=b-this.P.length}};
426
- r.Cc=function(a,b,c){c=void 0===c?!1:c;if(!this.m){for(;this.P.length;)if(this.P[this.P.length-1].startTime>=b)this.P.pop();else break;for(;this.P.length;)if(this.P[0].endTime<=a)this.P.shift(),c||this.i++;else break;0!=this.P.length&&(a=this.P[this.P.length-1],b=new Fi(a.startTime,b,a.F,a.Ga,a.ta,a.$,a.timestampOffset,a.appendWindowStart,a.appendWindowEnd,a.g,a.tilesLayout,a.B,a.h,a.status,a.aesKey),b.mimeType=a.mimeType,b.codecs=a.codecs,b.i=a.i,this.P[this.P.length-1]=b)}};
427
- r.te=function(a,b){var c=this;this.m||(this.l&&this.l.stop(),this.l=new Sc(function(){var d=b();d?c.P.push.apply(c.P,x(d)):(c.l.stop(),c.l=null)}),this.l.Ra(a))};Ok.prototype[Symbol.iterator]=function(){return this.Ib(0)};
420
+ function(){var h=d;null==h?h=Infinity>g.g.getDuration()?g.g.Vb():g.g.yb():0>h&&(h=g.g.yb()+h);return Mk(g,Nk(g,h))});this.m=new Sc(function(){if(0!=g.i.readyState&&!g.i.paused){var h=Ek(g.h),k=g.g.Vb(),l=g.g.yb();3>l-k&&(k=l-3);h<k&&(h=Lk(g,h),g.i.currentTime=h)}})}q=Jk.prototype;q.ready=function(){this.m.Ra(.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(){}};
421
+ q.De=function(a){Fk(this.h,a)};q.wd=function(){var a=Ek(this.h);return 0<this.i.readyState&&!this.i.paused?Nk(this,a):a};q.gg=function(){return this.o?this.o.o:0};q.fg=function(){return this.j.C};q.Mg=function(){this.j.Af()};function Mk(a,b){var c=a.g.getDuration();return b>=c?c-a.l.durationBackoff:b}
422
+ function Lk(a,b){var c=Math.max(a.B,a.l.rebufferingGoal),d=a.l.safeSeekOffset,e=a.g.Vb(),f=a.g.yb(),g=a.g.getDuration();3>f-e&&(e=f-3);var h=a.g.bd(c),k=a.g.bd(d);c=a.g.bd(c+d);return b>=g?Mk(a,b):b>f?f:b<e?Oi(a.i.buffered,k)?k:c:b>=h||Oi(a.i.buffered,b)?b:c}function Nk(a,b){var c=a.g.Vb();if(b<c)return c;a=a.g.yb();return b>a?a:b}
423
+ function Kk(a,b,c){if(!b.stallEnabled)return null;var d=b.stallSkip;b=new tk(new wk(a),b.stallThreshold,c);vk(b,function(){d?a.currentTime+=d:(a.pause(),a.play())});return b};function Ok(a){this.P=a;this.l=null;this.i=0;this.m=!1}q=Ok.prototype;q.getNumReferences=function(){return this.P.length};q.getNumEvicted=function(){return this.i};q.release=function(){this.m||(this.P=[],this.l&&this.l.stop(),this.l=null)};q.yi=function(){this.m=!0};q.Hb=function(a){for(var b=t(this.P),c=b.next();!c.done;c=b.next())a(c.value)};
424
+ q.find=function(a){for(var b=this.P.length-1,c=b;0<=c;--c){var d=this.P[c],e=c<b?this.P[c+1].startTime:d.endTime;if(a>=d.startTime&&a<e)return c+this.i}return this.P.length&&a<this.P[0].startTime?this.i:null};q.get=function(a){if(0==this.P.length)return null;a-=this.i;return 0>a||a>=this.P.length?null:this.P[a]};q.offset=function(a){if(!this.m)for(var b=t(this.P),c=b.next();!c.done;c=b.next())c.value.offset(a)};
425
+ q.Xd=function(a){if(!this.m&&a.length){var b=Math.round(1E3*a[0].startTime)/1E3;this.P=this.P.filter(function(c){return Math.round(1E3*c.startTime)/1E3<b});this.P.push.apply(this.P,x(a))}};q.pd=function(a,b){var c=this;a=a.filter(function(d){return d.endTime>b&&(0==c.P.length||d.endTime>c.P[0].startTime)});this.Xd(a);this.La(b)};q.La=function(a){if(!this.m){var b=this.P.length;this.P=this.P.filter(function(c){return c.endTime>a});this.i+=b-this.P.length}};
426
+ q.Cc=function(a,b,c){c=void 0===c?!1:c;if(!this.m){for(;this.P.length;)if(this.P[this.P.length-1].startTime>=b)this.P.pop();else break;for(;this.P.length;)if(this.P[0].endTime<=a)this.P.shift(),c||this.i++;else break;0!=this.P.length&&(a=this.P[this.P.length-1],b=new Fi(a.startTime,b,a.F,a.Ga,a.ta,a.$,a.timestampOffset,a.appendWindowStart,a.appendWindowEnd,a.g,a.tilesLayout,a.B,a.h,a.status,a.aesKey),b.mimeType=a.mimeType,b.codecs=a.codecs,b.i=a.i,this.P[this.P.length-1]=b)}};
427
+ q.te=function(a,b){var c=this;this.m||(this.l&&this.l.stop(),this.l=new Sc(function(){var d=b();d?c.P.push.apply(c.P,x(d)):(c.l.stop(),c.l=null)}),this.l.Ra(a))};Ok.prototype[Symbol.iterator]=function(){return this.Ib(0)};
428
428
  Ok.prototype.Ib=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 Pk(this,d,f,c)};function Qk(a,b,c){a=new Fi(a,a+b,function(){return c},0,null,null,a,a,a+b);return new Ok([a])}
429
429
  S("shaka.media.SegmentIndex",Ok);Ok.forSingleSegment=Qk;Ok.prototype.getIteratorForTime=Ok.prototype.Ib;Ok.prototype.updateEvery=Ok.prototype.te;Ok.prototype.fit=Ok.prototype.Cc;Ok.prototype.evict=Ok.prototype.La;Ok.prototype.mergeAndEvict=Ok.prototype.pd;Ok.prototype.offset=Ok.prototype.offset;Ok.prototype.get=Ok.prototype.get;Ok.prototype.find=Ok.prototype.find;Ok.prototype.markImmutable=Ok.prototype.yi;Ok.prototype.release=Ok.prototype.release;Ok.prototype.getNumEvicted=Ok.prototype.getNumEvicted;
430
- Ok.prototype.getNumReferences=Ok.prototype.getNumReferences;function Pk(a,b,c,d){this.i=a;this.h=b;this.g=c;this.reverse=d}Pk.prototype.Rc=function(a){this.reverse=a};Pk.prototype.Eh=function(){return this.h};Pk.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};
430
+ Ok.prototype.getNumReferences=Ok.prototype.getNumReferences;function Pk(a,b,c,d){this.i=a;this.h=b;this.g=c;this.reverse=d}Pk.prototype.Sc=function(a){this.reverse=a};Pk.prototype.Eh=function(){return this.h};Pk.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};
431
431
  Pk.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}};S("shaka.media.SegmentIterator",Pk);Pk.prototype.next=Pk.prototype.next;Pk.prototype.current=Pk.prototype.current;Pk.prototype.currentPosition=Pk.prototype.Eh;
432
- Pk.prototype.setReverse=Pk.prototype.Rc;function Rk(){Ok.call(this,[]);this.g=[]}na(Rk,Ok);r=Rk.prototype;r.clone=function(){var a=new Rk;a.g=this.g.slice();return a};r.release=function(){for(var a=t(this.g),b=a.next();!b.done;b=a.next())b.value.release();this.g=[]};r.Hb=function(a){for(var b=t(this.g),c=b.next();!c.done;c=b.next())c.value.Hb(a)};r.find=function(a){for(var b=0,c=t(this.g),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};
433
- r.get=function(a){for(var b=0,c=t(this.g),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};r.offset=function(){};r.Xd=function(){};r.La=function(){};r.pd=function(){};r.Cc=function(){};r.te=function(){};S("shaka.media.MetaSegmentIndex",Rk);Rk.prototype.updateEvery=Rk.prototype.te;Rk.prototype.fit=Rk.prototype.Cc;Rk.prototype.mergeAndEvict=Rk.prototype.pd;Rk.prototype.evict=Rk.prototype.La;Rk.prototype.merge=Rk.prototype.Xd;
432
+ Pk.prototype.setReverse=Pk.prototype.Sc;function Rk(){Ok.call(this,[]);this.g=[]}na(Rk,Ok);q=Rk.prototype;q.clone=function(){var a=new Rk;a.g=this.g.slice();return a};q.release=function(){for(var a=t(this.g),b=a.next();!b.done;b=a.next())b.value.release();this.g=[]};q.Hb=function(a){for(var b=t(this.g),c=b.next();!c.done;c=b.next())c.value.Hb(a)};q.find=function(a){for(var b=0,c=t(this.g),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};
433
+ q.get=function(a){for(var b=0,c=t(this.g),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.Xd=function(){};q.La=function(){};q.pd=function(){};q.Cc=function(){};q.te=function(){};S("shaka.media.MetaSegmentIndex",Rk);Rk.prototype.updateEvery=Rk.prototype.te;Rk.prototype.fit=Rk.prototype.Cc;Rk.prototype.mergeAndEvict=Rk.prototype.pd;Rk.prototype.evict=Rk.prototype.La;Rk.prototype.merge=Rk.prototype.Xd;
434
434
  Rk.prototype.offset=Rk.prototype.offset;Rk.prototype.get=Rk.prototype.get;Rk.prototype.find=Rk.prototype.find;Rk.prototype.forEachTopLevelReference=Rk.prototype.Hb;Rk.prototype.release=Rk.prototype.release;function Sk(a){var b=this;this.g=a;this.j=!1;this.i=this.g.Kd();this.h=new Sc(function(){b.g.Lg(.25*b.i)})}Sk.prototype.release=function(){this.set(this.jc());this.h&&(this.h.stop(),this.h=null);this.g=null};Sk.prototype.set=function(a){this.i=a;Tk(this)};Sk.prototype.jc=function(){return this.g.jc()};function Tk(a){a.h.stop();var b=a.j?0:a.i;if(0<=b)try{a.g.Kd()!=b&&a.g.Rf(b);return}catch(c){}a.h.Ra(.25);0!=a.g.Kd()&&a.g.Rf(0)};function Uk(a){var b=this;this.h=a;this.g=new Set;this.i=(new Sc(function(){Vk(b,!1)})).Ra(.25)}Uk.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 Vk(a,b){for(var c=t(a.g),d=c.next();!d.done;d=c.next())d.value.j(a.h.currentTime,b)};function Wk(){this.g=null;this.h=[]}function Xk(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 Yk(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 Zk(){this.i=this.h=null;this.g=[]}function $k(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 al(){this.ec=this.Hg=this.A=this.B=this.I=this.C=this.s=this.j=this.H=this.m=this.i=this.T=this.Y=this.L=this.N=this.O=this.l=this.o=NaN;this.K=0;this.F=this.G=NaN;this.g=new Wk;this.h=new Zk};function bl(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 cl(a,b){a.l=b;a=t(a.h.values());for(var c=a.next();!c.done;c=a.next())c.value.g=b}function dl(a,b,c){c=void 0===c?!1:c;if(a.i.segmentIndex&&(a.g||(a.g=a.i.segmentIndex.Ib(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.ta&&(c=!1);2==b.Yb()&&(c=!1);c&&b.$&&el(a,b.$);c&&!a.h.has(b)&&(c=new fl(a.l),gl(c,b,a.i),a.h.set(b,c))}hl(a)}}
435
- function el(a,b){if(a.i.segmentIndex&&!Array.from(a.j.keys()).some(function(d){return Ei(d,b)})){var c=new fl(a.l);gl(c,b,a.i);a.j.set(b,c)}}function il(a,b){b=t(b.keys());for(var c=b.next();!c.done;c=b.next())(c=c.value)&&jl(a,c)}function kl(a){il(a,a.h);il(a,a.j);a.g=null}bl.prototype.La=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&&jl(this,d);b&&hl(this)};bl.prototype.Rc=function(a){this.o=a;this.g&&this.g.Rc(a)};
435
+ function el(a,b){if(a.i.segmentIndex&&!Array.from(a.j.keys()).some(function(d){return Ei(d,b)})){var c=new fl(a.l);gl(c,b,a.i);a.j.set(b,c)}}function il(a,b){b=t(b.keys());for(var c=b.next();!c.done;c=b.next())(c=c.value)&&jl(a,c)}function kl(a){il(a,a.h);il(a,a.j);a.g=null}bl.prototype.La=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&&jl(this,d);b&&hl(this)};bl.prototype.Sc=function(a){this.o=a;this.g&&this.g.Sc(a)};
436
436
  function hl(a){for(var b=Array.from(a.h.keys()),c=t(a.j.keys()),d=c.next(),e={};!d.done;e={mf:void 0},d=c.next())e.mf=d.value,b.some(function(f){return function(g){return Ei(g.$,f.mf)}}(e))||jl(a,e.mf)}function ll(a,b){a.m=b;for(var c=Array.from(a.h.keys());c.length>b;){var d=c.pop();d&&jl(a,d)}hl(a)}function ml(a,b){b&&b!==a.i&&(kl(a),a.i=b)}function jl(a,b){var c=a.h;b instanceof Di&&(c=a.j);a=c.get(b);c.delete(b);a&&a.abort()}function fl(a){this.g=a;this.ee=this.Uf=null}
437
- function gl(a,b,c){var d=new Uint8Array(0);a.ee=a.g(b,c,function(e){return O(function(f){if(1==f.g)return 0<d.byteLength?d=Ld(d,e):d=e,a.Uf?F(f,a.Uf(d),3):f.u(0);d=new Uint8Array(0);H(f)})})}fl.prototype.abort=function(){this.ee&&this.ee.abort()};function nl(a){lg.call(this);var b=this;this.g=new Set;this.i=a;this.h=(new Sc(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 U("regionremove",new Map([["region",e]])),b.dispatchEvent(e))})).Ra(2)}na(nl,lg);nl.prototype.release=function(){this.g.clear();this.h.stop();lg.prototype.release.call(this)};function ol(a){lg.call(this);this.g=new Map;this.h=a}na(ol,lg);ol.prototype.release=function(){this.g.clear();lg.prototype.release.call(this)};function pl(a,b){var c=a.g.get(b);c||(c={sd:[],Oe:null,contentType:b},a.g.set(b,c));return c}function ql(a,b,c){var d=pl(a,b.contentType);rl(a,d);a={Hc:b,position:c};d=d.sd;b=d.findIndex(function(e){return e.position>=c});0<=b?d.splice(b,d[b].position==c?1:0,a):d.push(a)}
438
- ol.prototype.j=function(a){for(var b=t(this.g.values()),c=b.next();!c.done;c=b.next()){c=c.value;var d=c.Oe;a:{var e=c.sd;for(var f=e.length-1;0<=f;f--){var g=e[f];if(g.position<=a){e=g.Hc;break a}}e=null}f=e&&!(d===e||d&&e&&d.bandwidth==e.bandwidth&&d.audioSamplingRate==e.audioSamplingRate&&d.codecs==e.codecs&&d.contentType==e.contentType&&d.frameRate==e.frameRate&&d.height==e.height&&d.mimeType==e.mimeType&&d.channelsCount==e.channelsCount&&d.pixelAspectRatio==e.pixelAspectRatio&&d.width==e.width);
437
+ function gl(a,b,c){var d=new Uint8Array(0);a.ee=a.g(b,c,function(e){return O(function(f){if(1==f.g)return 0<d.byteLength?d=Ld(d,e):d=e,a.Uf?F(f,a.Uf(d),3):f.u(0);d=new Uint8Array(0);H(f)})})}fl.prototype.abort=function(){this.ee&&this.ee.abort()};function nl(a){lg.call(this);var b=this;this.g=new Set;this.i=a;this.h=(new Sc(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 U("regionremove",new Map([["region",e]])),b.dispatchEvent(e))})).Ra(2)}na(nl,lg);nl.prototype.release=function(){this.g.clear();this.h.stop();lg.prototype.release.call(this)};function ol(a){lg.call(this);this.g=new Map;this.h=a}na(ol,lg);ol.prototype.release=function(){this.g.clear();lg.prototype.release.call(this)};function pl(a,b){var c=a.g.get(b);c||(c={sd:[],Oe:null,contentType:b},a.g.set(b,c));return c}function ql(a,b,c){var d=pl(a,b.contentType);rl(a,d);a={Ic:b,position:c};d=d.sd;b=d.findIndex(function(e){return e.position>=c});0<=b?d.splice(b,d[b].position==c?1:0,a):d.push(a)}
438
+ ol.prototype.j=function(a){for(var b=t(this.g.values()),c=b.next();!c.done;c=b.next()){c=c.value;var d=c.Oe;a:{var e=c.sd;for(var f=e.length-1;0<=f;f--){var g=e[f];if(g.position<=a){e=g.Ic;break a}}e=null}f=e&&!(d===e||d&&e&&d.bandwidth==e.bandwidth&&d.audioSamplingRate==e.audioSamplingRate&&d.codecs==e.codecs&&d.contentType==e.contentType&&d.frameRate==e.frameRate&&d.height==e.height&&d.mimeType==e.mimeType&&d.channelsCount==e.channelsCount&&d.pixelAspectRatio==e.pixelAspectRatio&&d.width==e.width);
439
439
  g=e&&d&&e.label&&d.label&&d.label!==e.label;var h=e&&d&&e.language&&d.language&&d.language!==e.language;d=e&&d&&e.roles&&d.roles&&!Pb(d.roles,e.roles);(g||h||d)&&sl(this,a,e.contentType)&&(c.Oe=e,d=new U("audiotrackchange",new Map([["quality",e],["position",a]])),this.dispatchEvent(d));f&&sl(this,a,e.contentType)&&(c.Oe=e,JSON.stringify(e),c=new U("qualitychange",new Map([["quality",e],["position",a]])),this.dispatchEvent(c))}};
440
440
  function sl(a,b,c){return(a=a.h()[c])&&0<a.length&&(c=a[a.length-1].end,b>=a[0].start&&b<c)?!0:!1}function rl(a,b){if((a=a.h()[b.contentType])&&0<a.length){var c=a[0].start,d=a[a.length-1].end,e=b.sd;b.sd=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.sd=[]}
441
441
  function tl(a){var b={bandwidth:a.bandwidth||0,audioSamplingRate:null,codecs:a.codecs,contentType:a.type,frameRate:null,height:null,mimeType:a.mimeType,channelsCount:null,pixelAspectRatio:null,width:null,label:null,roles:a.roles,language:null};"video"==a.type&&(b.frameRate=a.frameRate||null,b.height=a.height||null,b.pixelAspectRatio=a.pixelAspectRatio||null,b.width=a.width||null);"audio"==a.type&&(b.audioSamplingRate=a.audioSamplingRate,b.channelsCount=a.channelsCount,b.label=a.label||null,b.language=
442
442
  a.language);return b};function ul(a){var b=ie(a),c=b.split("/")[0];a=je(a);return{type:c,mimeType:b,codecs:a,language:null,height:null,width:null,channelCount:null,sampleRate:null,closedCaptions:new Map,vd:null,colorGamut:null}}
443
- function vl(a,b){function c(y){v=y.name;var B=y.reader;B.skip(24);var C=B.na(),E=B.na();B.skip(50);n=String(C);m=String(E);y.reader.pa()&&Qg(y)}function d(y){var B=cj(y.reader);q=B.channelCount;p=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");
444
- 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,q=null,p=null,w=null,u=null,v;(new Lg).box("moov",Qg).box("trak",Qg).box("mdia",Qg).S("mdhd",function(y){l=aj(y.reader,y.version).language}).box("minf",Qg).box("stbl",Qg).S("stsd",Sg).box("mp4a",function(y){var B=cj(y.reader);q=B.channelCount;p=B.sampleRate;y.reader.pa()?Qg(y):e(y.name)}).box("esds",function(y){y=y.reader;for(var B=
443
+ function vl(a,b){function c(y){w=y.name;var B=y.reader;B.skip(24);var C=B.na(),E=B.na();B.skip(50);n=String(C);m=String(E);y.reader.pa()&&Qg(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");
444
+ 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 Lg).box("moov",Qg).box("trak",Qg).box("mdia",Qg).S("mdhd",function(y){l=aj(y.reader,y.version).language}).box("minf",Qg).box("stbl",Qg).S("stsd",Sg).box("mp4a",function(y){var B=cj(y.reader);p=B.channelCount;r=B.sampleRate;y.reader.pa()?Qg(y):e(y.name)}).box("esds",function(y){y=y.reader;for(var B=
445
445
  "mp4a",C,E;y.pa();){C=y.U();for(var G=y.U();G&128;)G=y.U();if(3==C)y.na(),G=y.U(),G&128&&y.na(),G&64&&y.skip(y.U()),G&32&&y.na();else if(4==C)E=y.U(),y.skip(12);else if(5==C)break}E&&(B+="."+fj(E),5==C&&y.pa()&&(C=y.U(),E=(C&248)>>3,31===E&&y.pa()&&(E=32+((C&7)<<3)+((y.U()&224)>>5)),B+="."+E));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",
446
- c).box("av01",c).box("avcC",function(y){var B=v||"";switch(v){case "dvav":B="avc3";break;case "dva1":B="avc1"}y=y.reader;y.skip(1);y=B+"."+fj(y.U())+fj(y.U())+fj(y.U());g.push(y);k=!0}).box("hvcC",function(y){var B=v||"";switch(v){case "dvh1":B="hvc1";break;case "dvhe":B="hev1"}var C=y.reader;C.skip(1);y=C.U();var E=["","A","B","C"][y>>6],G=y&31,L=C.R(),K=(y&32)>>5?"H":"L";y=[C.U(),C.U(),C.U(),C.U(),C.U(),C.U()];C=C.U();for(var I=0,J=0;32>J;J++){I|=L&1;if(31==J)break;I<<=1;L>>=1}B=B+("."+E+G)+("."+
447
- fj(I,!0));B+="."+K+C;E="";for(G=y.length;G--;)if((K=y[G])||E)E="."+K.toString(16).toUpperCase()+E;B+=E;g.push(B);k=!0}).box("dvcC",function(y){var B=v||"";switch(v){case "hvc1":B="dvh1";break;case "hev1":B="dvhe";break;case "avc1":B="dva1";break;case "avc3":B="dvav";break;case "av01":B="dav1"}var C=y.reader;C.skip(2);y=C.U();C=C.U();g.push(B+"."+gj(y>>1&127)+"."+gj(y<<5&32|C>>3&31));k=!0}).box("dvvC",function(y){var B=v||"";switch(v){case "hvc1":B="dvh1";break;case "hev1":B="dvhe";break;case "avc1":B=
448
- "dva1";break;case "avc3":B="dvav";break;case "av01":B="dav1"}var C=y.reader;C.skip(2);y=C.U();C=C.U();g.push(B+"."+gj(y>>1&127)+"."+gj(y<<5&32|C>>3&31));k=!0}).S("vpcC",function(y){var B=v||"",C=y.reader;y=C.U();var E=C.U();C=C.U()>>4&15;g.push(B+"."+gj(y)+"."+gj(E)+"."+gj(C));k=!0}).box("av1C",function(y){var B=v||"";switch(v){case "dav1":B="av01"}var C=y.reader;C.skip(1);y=C.U();C=C.U();var E=y>>>5,G=(C&64)>>6;g.push(B+"."+E+"."+gj(y&31)+(C>>>7?"H":"M")+"."+gj(2===E&&G?(C&32)>>5?12:10:G?10:8)+"."+
449
- ((C&16)>>4)+"."+((C&8)>>3)+((C&4)>>2)+(C&3)+"."+gj(1)+"."+gj(1)+"."+gj(1)+".0");k=!0}).box("enca",Wg).box("encv",Tg).box("sinf",Qg).box("frma",function(y){y=dj(y.reader).codec;e(y)}).box("colr",function(y){g=g.map(function(E){if(E.startsWith("av01.")){var G=y.reader,L=G.va(),K=G.qb(4);var I=String.fromCharCode(K[0]);I+=String.fromCharCode(K[1]);I+=String.fromCharCode(K[2]);I+=String.fromCharCode(K[3]);if("nclx"===I){K=G.na();I=G.na();var J=G.na(),N=G.U()>>7,M=E.split(".");10==M.length&&(M[6]=gj(K),
450
- M[7]=gj(I),M[8]=gj(J),M[9]=String(N),E=M.join("."))}G.seek(L)}return E});var B=ej(y.reader),C=B.colorGamut;w=B.vd;u=C}).parse(a||b,!0);if(!f.length&&!g.length)return null;var A=h&&!k,z=new Map;if(k){var D=new Gb("video/mp4");a&&D.init(a);D.i(b);a=t(D.j());for(b=a.next();!b.done;b=a.next())b=b.value,z.set(b,b);D.g()}return{type:A?"audio":"video",mimeType:A?"audio/mp4":"video/mp4",codecs:wl(f.concat(g)).join(", "),language:l,height:m,width:n,channelCount:q,sampleRate:p,closedCaptions:z,vd:w,colorGamut:u}}
446
+ 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.U())+fj(y.U())+fj(y.U());g.push(y);k=!0}).box("hvcC",function(y){var B=w||"";switch(w){case "dvh1":B="hvc1";break;case "dvhe":B="hev1"}var C=y.reader;C.skip(1);y=C.U();var E=["","A","B","C"][y>>6],G=y&31,L=C.R(),K=(y&32)>>5?"H":"L";y=[C.U(),C.U(),C.U(),C.U(),C.U(),C.U()];C=C.U();for(var I=0,J=0;32>J;J++){I|=L&1;if(31==J)break;I<<=1;L>>=1}B=B+("."+E+G)+("."+
447
+ fj(I,!0));B+="."+K+C;E="";for(G=y.length;G--;)if((K=y[G])||E)E="."+K.toString(16).toUpperCase()+E;B+=E;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";break;case "av01":B="dav1"}var C=y.reader;C.skip(2);y=C.U();C=C.U();g.push(B+"."+gj(y>>1&127)+"."+gj(y<<5&32|C>>3&31));k=!0}).box("dvvC",function(y){var B=w||"";switch(w){case "hvc1":B="dvh1";break;case "hev1":B="dvhe";break;case "avc1":B=
448
+ "dva1";break;case "avc3":B="dvav";break;case "av01":B="dav1"}var C=y.reader;C.skip(2);y=C.U();C=C.U();g.push(B+"."+gj(y>>1&127)+"."+gj(y<<5&32|C>>3&31));k=!0}).S("vpcC",function(y){var B=w||"",C=y.reader;y=C.U();var E=C.U();C=C.U()>>4&15;g.push(B+"."+gj(y)+"."+gj(E)+"."+gj(C));k=!0}).box("av1C",function(y){var B=w||"";switch(w){case "dav1":B="av01"}var C=y.reader;C.skip(1);y=C.U();C=C.U();var E=y>>>5,G=(C&64)>>6;g.push(B+"."+E+"."+gj(y&31)+(C>>>7?"H":"M")+"."+gj(2===E&&G?(C&32)>>5?12:10:G?10:8)+"."+
449
+ ((C&16)>>4)+"."+((C&8)>>3)+((C&4)>>2)+(C&3)+"."+gj(1)+"."+gj(1)+"."+gj(1)+".0");k=!0}).box("enca",Wg).box("encv",Tg).box("sinf",Qg).box("frma",function(y){y=dj(y.reader).codec;e(y)}).box("colr",function(y){g=g.map(function(E){if(E.startsWith("av01.")){var G=y.reader,L=G.va(),K=G.qb(4);var I=String.fromCharCode(K[0]);I+=String.fromCharCode(K[1]);I+=String.fromCharCode(K[2]);I+=String.fromCharCode(K[3]);if("nclx"===I){K=G.na();I=G.na();var J=G.na(),M=G.U()>>7,N=E.split(".");10==N.length&&(N[6]=gj(K),
450
+ N[7]=gj(I),N[8]=gj(J),N[9]=String(M),E=N.join("."))}G.seek(L)}return E});var B=ej(y.reader),C=B.colorGamut;u=B.vd;v=C}).parse(a||b,!0);if(!f.length&&!g.length)return null;var A=h&&!k,z=new Map;if(k){var D=new Gb("video/mp4");a&&D.init(a);D.i(b);a=t(D.j());for(b=a.next();!b.done;b=a.next())b=b.value,z.set(b,b);D.g()}return{type:A?"audio":"video",mimeType:A?"audio/mp4":"video/mp4",codecs:wl(f.concat(g)).join(", "),language:l,height:m,width:n,channelCount:p,sampleRate:r,closedCaptions:z,vd:u,colorGamut:v}}
451
451
  function wl(a){var b=new Set,c=[];a=t(a);for(var d=a.next();!d.done;d=a.next()){d=d.value;var e=he(d);b.has(e)||(c.push(d),b.add(e))}b=Vd("audio",c);d=Vd("video",c);a=Vd(Ud,c);d=xl(d);b=b.concat(d).concat(a);return c.length&&!b.length?c:b}
452
452
  function xl(a){if(1>=a.length)return a;var b=a.find(function(c){return c.startsWith("dvav.")||c.startsWith("dva1.")||c.startsWith("dvh1.")||c.startsWith("dvhe.")||c.startsWith("dav1.")||c.startsWith("dvc1.")||c.startsWith("dvi1.")});return b?mb('video/mp4; codecs="'+b+'"')?[b]:a.filter(function(c){return c!=b}):a}
453
453
  function yl(a){var b=null;(new Lg).box("moov",Qg).box("trak",Qg).box("mdia",Qg).box("minf",Qg).box("stbl",Qg).S("stsd",Sg).box("encv",Tg).box("enca",Wg).box("sinf",Qg).box("schi",Qg).S("tenc",function(c){c=c.reader;c.U();c.U();c.U();c.U();b=Id(c.qb(16))}).parse(a,!0);return b}
454
- function zl(a,b,c){var d,e,f,g,h;return O(function(k){if(1==k.g)return d=b,d.cryptoKey?k.u(2):F(k,d.fetchKey(),3);e=d.iv;if(!e)for(e=zb(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))})};function Al(a,b,c,d,e){a=tg(a,d,e);if(0!=b||null!=c)a.headers.Range=c?"bytes="+b+"-"+c:"bytes="+b+"-";return a};function Bl(a,b){var c=this;this.g=b;this.l=a;this.h=null;this.F=new Map;this.B=1;this.s=this.j=null;this.I=0;this.G=!1;this.i=new Map;this.C=!1;this.K=null;this.A=!1;this.m=new Bg(function(){return Cl(c)});this.L=Date.now()/1E3;this.o=new Map;this.H={projection:null,hfov:null};this.O=0;this.N=Infinity}r=Bl.prototype;r.destroy=function(){return this.m.destroy()};
454
+ function zl(a,b,c){var d,e,f,g,h;return O(function(k){if(1==k.g)return d=b,d.cryptoKey?k.u(2):F(k,d.fetchKey(),3);e=d.iv;if(!e)for(e=zb(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))})};function Al(a,b,c,d,e){a=tg(a,d,e);if(0!=b||null!=c)a.headers.Range=c?"bytes="+b+"-"+c:"bytes="+b+"-";return a};function Bl(a,b){var c=this;this.g=b;this.l=a;this.h=null;this.F=new Map;this.B=1;this.s=this.j=null;this.I=0;this.G=!1;this.i=new Map;this.C=!1;this.K=null;this.A=!1;this.m=new Bg(function(){return Cl(c)});this.L=Date.now()/1E3;this.o=new Map;this.H={projection:null,hfov:null};this.O=0;this.N=Infinity}q=Bl.prototype;q.destroy=function(){return this.m.destroy()};
455
455
  function Cl(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,Dl(e),b.push(El(e)),e.W&&(kl(e.W),e.W=null);f=t(a.o.values());for(g=f.next();!g.done;g=f.next())h=g.value,kl(h);return F(k,Promise.all(b),2)}a.i.clear();a.o.clear();a.g=null;a.l=null;a.h=null;H(k)})}
456
- r.configure=function(a){this.h=a;this.K=new Zf({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.W&&(kl(b.W),b.W=null);b=t(this.o.keys());for(var c=b.next();!c.done;c=b.next())c=c.value,kl(this.o.get(c)),this.o.delete(c)}a.disableTextPrefetch&&(b=this.i.get(Ud))&&
456
+ q.configure=function(a){this.h=a;this.K=new Zf({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.W&&(kl(b.W),b.W=null);b=t(this.o.keys());for(var c=b.next();!c.done;c=b.next())c=c.value,kl(this.o.get(c)),this.o.delete(c)}a.disableTextPrefetch&&(b=this.i.get(Ud))&&
457
457
  b.W&&(kl(b.W),b.W=null);a.disableVideoPrefetch&&(b=this.i.get("video"))&&b.W&&(kl(b.W),b.W=null);b=t(this.i.keys());for(c=b.next();!c.done;c=b.next())c=this.i.get(c.value),c.W?(ll(c.W,a.segmentPrefetchLimit),0<a.segmentPrefetchLimit||(kl(c.W),c.W=null)):0<a.segmentPrefetchLimit&&(c.W=Fl(this,c.stream));a.disableAudioPrefetch||Gl(this)};function Hl(a,b,c){a.l.presentationTimeline.V()||(a.O=b,a.N=c)}
458
- r.start=function(a){var b=this;return O(function(c){if(1==c.g)return F(c,Il(b,a||new Map),2);Cg(b.m);b.C=!0;H(c)})};function Jl(a,b){var c,d,e,f,g,h,k;O(function(l){switch(l.g){case 1:return c=Wd,a.I++,d=a.I,ra(l,2),F(l,hk(a.g.aa,c.ua),4);case 4:ta(l,3);break;case 2:if(e=ua(l),a.g)a.g.onError(e);case 3:f=Zd(b.mimeType,b.codecs),Qj(a.g.aa,f,a.l.sequenceMode,b.external),g=a.g.aa.F,(h=g.isTextVisible()||a.h.alwaysStreamText)&&a.I==d&&(k=Kl(a,b),a.i.set(c.ua,k),Ll(a,k,0)),H(l)}})}
459
- function Ml(a){var b=a.i.get(Ud);b&&(Dl(b),El(b).catch(function(){}),a.i.delete(Ud));a.s=null}function Nl(a,b){for(var c=0>a.g.eb(),d=t(a.i.values()),e=d.next();!e.done;e=d.next())e=e.value,e.ka&&e.ka.Rc(c),e.W&&e.W.Rc(c);d=t(a.o.values());for(e=d.next();!e.done;e=d.next())e.value.Rc(c);if(c=a.i.get("video"))if(d=c.stream)if(b)(b=d.trickModeVideo)&&!c.$b&&(Ol(a,b,!1,0,!1),c.$b=d);else if(b=c.$b)c.$b=null,Ol(a,b,!0,0,!1)}
458
+ q.start=function(a){var b=this;return O(function(c){if(1==c.g)return F(c,Il(b,a||new Map),2);Cg(b.m);b.C=!0;H(c)})};function Jl(a,b){var c,d,e,f,g,h,k;O(function(l){switch(l.g){case 1:return c=Wd,a.I++,d=a.I,ra(l,2),F(l,hk(a.g.aa,c.ua),4);case 4:ta(l,3);break;case 2:if(e=ua(l),a.g)a.g.onError(e);case 3:f=Zd(b.mimeType,b.codecs),Qj(a.g.aa,f,a.l.sequenceMode,b.external),g=a.g.aa.F,(h=g.isTextVisible()||a.h.alwaysStreamText)&&a.I==d&&(k=Kl(a,b),a.i.set(c.ua,k),Ll(a,k,0)),H(l)}})}
459
+ function Ml(a){var b=a.i.get(Ud);b&&(Dl(b),El(b).catch(function(){}),a.i.delete(Ud));a.s=null}function Nl(a,b){for(var c=0>a.g.eb(),d=t(a.i.values()),e=d.next();!e.done;e=d.next())e=e.value,e.ka&&e.ka.Sc(c),e.W&&e.W.Sc(c);d=t(a.o.values());for(e=d.next();!e.done;e=d.next())e.value.Sc(c);if(c=a.i.get("video"))if(d=c.stream)if(b)(b=d.trickModeVideo)&&!c.$b&&(Ol(a,b,!1,0,!1),c.$b=d);else if(b=c.$b)c.$b=null,Ol(a,b,!0,0,!1)}
460
460
  function Pl(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.C&&(b.video&&Ol(a,b.video,c,d,e,f),b.audio&&Ol(a,b.audio,c,d,e,f))}function Ql(a,b){O(function(c){if(1==c.g)return a.s=b,a.C?b.segmentIndex?c.u(2):F(c,b.createSegmentIndex(),2):c.return();Ol(a,b,!0,0,!1);H(c)})}function Rl(a,b){for(var c=t(a.F.entries()),d=c.next();!d.done;d=c.next()){var e=t(d.value);d=e.next().value;e=e.next().value;d.includes(b.type)&&(e(),a.F.delete(d))}}
461
- function Ol(a,b,c,d,e,f){var g=a.i.get(b.type);g||b.type!=Ud?g&&(g.$b&&(b.trickModeVideo?(g.$b=b,b=b.trickModeVideo):g.$b=null),g.stream!=b||e)&&(a.o.has(b)?g.W=a.o.get(b):g.W&&ml(g.W,b),b.type==Ud&&(e=Zd(b.mimeType,b.codecs),Qj(a.g.aa,e,a.l.sequenceMode,b.external)),!a.o.has(g.stream)&&g.stream.closeSegmentIndex&&(g.Ja?(e="("+g.type+":"+g.stream.id+")",a.F.has(e)||a.F.set(e,g.stream.closeSegmentIndex)):g.stream.closeSegmentIndex()),g.stream=b,g.ka=null,g.hg=!!f,c?g.Uc?g.Ae=!0:g.Ja?(g.dc=!0,g.Ed=
461
+ function Ol(a,b,c,d,e,f){var g=a.i.get(b.type);g||b.type!=Ud?g&&(g.$b&&(b.trickModeVideo?(g.$b=b,b=b.trickModeVideo):g.$b=null),g.stream!=b||e)&&(a.o.has(b)?g.W=a.o.get(b):g.W&&ml(g.W,b),b.type==Ud&&(e=Zd(b.mimeType,b.codecs),Qj(a.g.aa,e,a.l.sequenceMode,b.external)),!a.o.has(g.stream)&&g.stream.closeSegmentIndex&&(g.Ja?(e="("+g.type+":"+g.stream.id+")",a.F.has(e)||a.F.set(e,g.stream.closeSegmentIndex)):g.stream.closeSegmentIndex()),g.stream=b,g.ka=null,g.hg=!!f,c?g.Vc?g.Ae=!0:g.Ja?(g.dc=!0,g.Ed=
462
462
  d,g.Ae=!0):(Dl(g),Sl(a,g,!0,d).catch(function(h){if(a.g)a.g.onError(h)})):g.Ja||g.sb||Ll(a,g,0),Tl(a,g).catch(function(h){if(a.g)a.g.onError(h)})):Jl(a,b)}
463
463
  function Tl(a,b){var c,d;return O(function(e){if(1==e.g){if(!b.ib)return e.return();c=b.stream;d=b.ib;return c.segmentIndex?e.u(2):F(e,c.createSegmentIndex(),2)}if(b.ib!=d||b.stream!=c)return e.return();var f=a.g.Jd();var g=Wj(a.g.aa,b.type),h=b.stream.segmentIndex.find(b.Na?b.Na.endTime:f),k=null==h?null:b.stream.segmentIndex.get(h);h=k?k.ta?k.ta-k.Ga:null:null;k&&!h&&(h=(k.endTime-k.getStartTime())*(b.stream.bandwidth||0)/8);h?((k=k.$)&&(h+=(k.ta?k.ta-k.Ga:null)||0),k=a.g.getBandwidthEstimate(),
464
464
  f=8*h/k<(g||0)-f-Math.max(a.l.minBufferTime||0,a.h.rebufferingGoal)||b.ib.h.g>h?!0:!1):f=!1;f&&b.ib.abort();H(e)})}
465
- r.Pc=function(){if(this.g)for(var a=this.g.Jd(),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.aa;e.C?e=!1:d==Ud?(e=e.g,e=null==e.g||null==e.h?!1:a>=e.g&&a<e.h):(e=Vj(e,d),e=Oi(e,a));if(!e){c.W&&(c.W.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.ka=null;(null!=Wj(this.g.aa,d)||c.Ja)&&Ul(this,c);c.ib&&(c.ib.abort(),c.ib=null);d===Ud&&(d=this.g.aa,d.H&&d.H.g());c.Pc=!0}}};
466
- function Ul(a,b){b.Uc||b.dc||(b.Ja?(b.dc=!0,b.Ed=0):null==Uj(a.g.aa,b.type)?null==b.sb&&Ll(a,b,0):(Dl(b),Sl(a,b,!1,0).catch(function(c){if(a.g)a.g.onError(c)})))}
467
- function Il(a,b){var c,d,e,f,g,h,k,l,m,n;return O(function(q){if(1==q.g){c=Wd;if(!a.j)throw new T(2,5,5006);d=new Map;e=new Set;a.j.audio&&(d.set(c.X,a.j.audio),e.add(a.j.audio));a.j.video&&(d.set(c.ha,a.j.video),e.add(a.j.video));a.s&&(d.set(c.ua,a.s),e.add(a.s));f=a.g.aa;return F(q,f.init(d,a.l.sequenceMode,a.l.type,a.l.ignoreManifestTimestampsInSegmentsMode),2)}Cg(a.m);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=Kl(a,l),b.has(l.id)&&(n=
468
- b.get(l.id),cl(n,function(p,w,u){return Vl(p,w,u||null,a.h.retryParameters,a.g.Lb)}),m.W=n),a.i.set(k,m),Ll(a,m,0));H(q)})}function Kl(a,b){return{stream:b,type:b.type,ka:null,W:Fl(a,b),Na:null,nc:null,Td:null,Sd:null,Rd:null,$b:null,endOfStream:!1,Ja:!1,sb:null,dc:!1,Ed:0,Ae:!1,Uc:!1,Pc:!0,Gf:!1,ed:!1,ib:null}}
465
+ q.Qc=function(){if(this.g)for(var a=this.g.Jd(),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.aa;e.C?e=!1:d==Ud?(e=e.g,e=null==e.g||null==e.h?!1:a>=e.g&&a<e.h):(e=Vj(e,d),e=Oi(e,a));if(!e){c.W&&(c.W.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.ka=null;(null!=Wj(this.g.aa,d)||c.Ja)&&Ul(this,c);c.ib&&(c.ib.abort(),c.ib=null);d===Ud&&(d=this.g.aa,d.H&&d.H.g());c.Qc=!0}}};
466
+ function Ul(a,b){b.Vc||b.dc||(b.Ja?(b.dc=!0,b.Ed=0):null==Uj(a.g.aa,b.type)?null==b.sb&&Ll(a,b,0):(Dl(b),Sl(a,b,!1,0).catch(function(c){if(a.g)a.g.onError(c)})))}
467
+ function Il(a,b){var c,d,e,f,g,h,k,l,m,n;return O(function(p){if(1==p.g){c=Wd;if(!a.j)throw new T(2,5,5006);d=new Map;e=new Set;a.j.audio&&(d.set(c.X,a.j.audio),e.add(a.j.audio));a.j.video&&(d.set(c.ha,a.j.video),e.add(a.j.video));a.s&&(d.set(c.ua,a.s),e.add(a.s));f=a.g.aa;return F(p,f.init(d,a.l.sequenceMode,a.l.type,a.l.ignoreManifestTimestampsInSegmentsMode),2)}Cg(a.m);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=Kl(a,l),b.has(l.id)&&(n=
468
+ b.get(l.id),cl(n,function(r,u,v){return Vl(r,u,v||null,a.h.retryParameters,a.g.Lb)}),m.W=n),a.i.set(k,m),Ll(a,m,0));H(p)})}function Kl(a,b){return{stream:b,type:b.type,ka:null,W:Fl(a,b),Na:null,nc:null,Td:null,Sd:null,Rd:null,$b:null,endOfStream:!1,Ja:!1,sb:null,dc:!1,Ed:0,Ae:!1,Vc:!1,Qc:!0,Gf:!1,fd:!1,ib:null}}
469
469
  function Fl(a,b){if("video"===b.type&&a.h.disableVideoPrefetch||"audio"===b.type&&a.h.disableAudioPrefetch||b.type===Ud&&("application/cea-608"==b.mimeType||"application/cea-708"==b.mimeType)||b.type===Ud&&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.W)&&b===c.i?c:0<a.h.segmentPrefetchLimit?new bl(a.h.segmentPrefetchLimit,b,function(d,e,f){return Vl(d,e,f||null,a.h.retryParameters,a.g.Lb)},0>a.g.eb()):null}
470
470
  function Gl(a){for(var b=a.h.segmentPrefetchLimit,c=a.h.prefetchAudioLanguages,d=t(a.l.variants),e=d.next(),f={};!e.done;f={lb:void 0},e=d.next())if(f.lb=e.value,f.lb.audio)if(a.o.has(f.lb.audio)){if(e=a.o.get(f.lb.audio),ll(e,b),!(0<b&&c.some(function(h){return function(k){return Ce(h.lb.audio.language,k)}}(f)))){var g=a.i.get(f.lb.audio.type);e!==(g&&g.W)&&kl(e);a.o.delete(f.lb.audio)}}else 0>=b||!c.some(function(h){return function(k){return Ce(h.lb.audio.language,k)}}(f))||!(e=Fl(a,f.lb.audio))||
471
- (f.lb.audio.segmentIndex||f.lb.audio.createSegmentIndex(),a.o.set(f.lb.audio,e))}r.updateDuration=function(){var a=this.l.presentationTimeline.getDuration();Infinity>a?this.g.aa.Za(a):this.g.aa.Za(this.h.infiniteLiveStreamDuration?Infinity:Math.pow(2,32))};
472
- function Wl(a,b){var c,d,e,f,g,h;return O(function(k){switch(k.g){case 1:Cg(a.m);if(b.Ja||null==b.sb||b.Uc)return k.return();b.sb=null;if(!b.dc){k.u(2);break}return F(k,Sl(a,b,b.Ae,b.Ed),3);case 3:return k.return();case 2:Rl(a,b);if(b.stream.segmentIndex){k.u(4);break}c=b.stream;ra(k,5);return F(k,b.stream.createSegmentIndex(),7);case 7:ta(k,6);break;case 5:return d=ua(k),F(k,Xl(a,b,d),8);case 8:return k.return();case 6:if(c!=b.stream)return c.closeSegmentIndex&&c.closeSegmentIndex(),b.Ja||b.sb||
473
- Ll(a,b,0),k.return();case 4:ra(k,9);e=Yl(a,b);null!=e&&(Ll(a,b,e),b.ed=!1);ta(k,10);break;case 9:return f=ua(k),F(k,Xl(a,b,f),11);case 11:return k.return();case 10:g=Array.from(a.i.values());if(!a.C||!g.every(function(l){return l.endOfStream})){k.u(0);break}return F(k,a.g.aa.endOfStream(),13);case 13:Cg(a.m),h=a.g.aa.getDuration(),0!=h&&h<a.l.presentationTimeline.getDuration()&&a.l.presentationTimeline.Za(h),H(k)}})}
471
+ (f.lb.audio.segmentIndex||f.lb.audio.createSegmentIndex(),a.o.set(f.lb.audio,e))}q.updateDuration=function(){var a=this.l.presentationTimeline.getDuration();Infinity>a?this.g.aa.Za(a):this.g.aa.Za(this.h.infiniteLiveStreamDuration?Infinity:Math.pow(2,32))};
472
+ function Wl(a,b){var c,d,e,f,g,h;return O(function(k){switch(k.g){case 1:Cg(a.m);if(b.Ja||null==b.sb||b.Vc)return k.return();b.sb=null;if(!b.dc){k.u(2);break}return F(k,Sl(a,b,b.Ae,b.Ed),3);case 3:return k.return();case 2:Rl(a,b);if(b.stream.segmentIndex){k.u(4);break}c=b.stream;ra(k,5);return F(k,b.stream.createSegmentIndex(),7);case 7:ta(k,6);break;case 5:return d=ua(k),F(k,Xl(a,b,d),8);case 8:return k.return();case 6:if(c!=b.stream)return c.closeSegmentIndex&&c.closeSegmentIndex(),b.Ja||b.sb||
473
+ Ll(a,b,0),k.return();case 4:ra(k,9);e=Yl(a,b);null!=e&&(Ll(a,b,e),b.fd=!1);ta(k,10);break;case 9:return f=ua(k),F(k,Xl(a,b,f),11);case 11:return k.return();case 10:g=Array.from(a.i.values());if(!a.C||!g.every(function(l){return l.endOfStream})){k.u(0);break}return F(k,a.g.aa.endOfStream(),13);case 13:Cg(a.m),h=a.g.aa.getDuration(),0!=h&&h<a.l.presentationTimeline.getDuration()&&a.l.presentationTimeline.Za(h),H(k)}})}
474
474
  function Yl(a,b){if(Zl(b))return ek(a.g.aa,b.stream.originalId||""),null;b.type==Ud&&fk(a.g.aa);if(!a.g.aa.xa&&b.type!=Ud)return a.h.updateIntervalSeconds/2;var c=a.g.Jd();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.La(c,!0),dl(e,c);d=b.Na?b.Na.endTime:c;var f=Xj(a.g.aa,b.type,c),g=Math.max(1,Math.max(a.l.minBufferTime||0,a.h.rebufferingGoal,a.h.bufferingGoal)*a.B),h=a.l.presentationTimeline.getDuration()-d;e=Wj(a.g.aa,b.type);if(1E-6>h&&e)return b.endOfStream=
475
475
  !0,"video"==b.type&&(a=a.i.get(Ud))&&Zl(a)&&(a.endOfStream=!0),null;b.endOfStream=!1;if(f>=g)return a.h.updateIntervalSeconds/2;g=!b.ka;e=$l(a,b,c,e);if(!e)return a.h.updateIntervalSeconds;f=!1;g&&b.hg&&(f=!0,b.hg=!1);g=Infinity;h=Array.from(a.i.values());h=t(h);for(var k=h.next();!k.done;k=h.next())k=k.value,Zl(k)||k.ka&&!k.ka.current()||(g=Math.min(g,k.Na?k.Na.endTime:c));if(d>=g+a.l.presentationTimeline.g)return a.h.updateIntervalSeconds;b.W&&b.ka&&!a.o.has(b.stream)&&(b.W.La(e.startTime),dl(b.W,
476
476
  e.startTime));am(a,b,c,e,f).catch(function(){});return null}function $l(a,b,c,d){if(b.ka)return b.ka.current();if(b.Na||d)return b.ka=b.stream.segmentIndex.Ib(b.Na?b.Na.endTime:d,!1,0>a.g.eb()),b.ka&&b.ka.next().value;d=a.l.sequenceMode?0:a.h.inaccurateManifestTolerance;var e=Math.max(c-d,0);a=0>a.g.eb();var f=null;d&&(b.ka=b.stream.segmentIndex.Ib(e,!1,a),f=b.ka&&b.ka.next().value);f||(b.ka=b.stream.segmentIndex.Ib(c,!1,a),f=b.ka&&b.ka.next().value);return f}
477
- function am(a,b,c,d,e){var f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B;return O(function(C){switch(C.g){case 1:f=Wd;g=b.stream;h=b.ka;b.Ja=!0;ra(C,2);if(2==d.Yb())throw new T(1,1,1011);return F(C,bm(a,b,d,e),4);case 4:Cg(a.m);if(a.A)return C.return();k="video/mp4"==g.mimeType||"audio/mp4"==g.mimeType;l=window.ReadableStream;if((m=a.h.lowLatencyMode&&a.l.isLowLatency)&&l&&k&&("HLS"!=a.l.type||d.m))return p=new Uint8Array(0),u=w=!1,A=function(E){var G,L,K,I;return O(function(J){switch(J.g){case 1:if(w)return J.return();
478
- u=!0;Cg(a.m);if(a.A)return J.return();ra(J,2);p=cm(p,E);G=!1;L=0;(new Lg).box("mdat",function(N){L=N.size+N.start;G=!0}).parse(p,!1,!0);if(!G){J.u(4);break}K=p.subarray(0,L);p=p.subarray(L);return F(J,dm(a,b,c,g,d,K,!0,e),5);case 5:b.W&&b.ka&&dl(b.W,d.startTime,!0);case 4:ta(J,0);break;case 2:v=I=ua(J),H(J)}})},F(C,em(a,b,d,A),9);n=em(a,b,d);return F(C,n,7);case 7:q=C.h;Cg(a.m);if(a.A)return C.return();Cg(a.m);return b.dc?(b.Ja=!1,Ll(a,b,0),C.return()):F(C,dm(a,b,c,g,d,q,!1,e),6);case 9:z=C.h;if(v)throw v;
479
- if(u){C.u(10);break}w=!0;Cg(a.m);return a.A?C.return():b.dc?(b.Ja=!1,Ll(a,b,0),C.return()):F(C,dm(a,b,c,g,d,z,!1,e),10);case 10:b.W&&b.ka&&dl(b.W,d.startTime,!0);case 6:Cg(a.m);if(a.A)return C.return();b.Na=d;h.next();b.Ja=!1;b.Gf=!1;D=a.g.aa.wb();y=D[b.type];db(JSON.stringify(y));b.dc||a.g.Af(d,b.stream);Ll(a,b,0);ta(C,0);break;case 2:B=ua(C);Cg(a.m,B);if(a.A)return C.return();b.Ja=!1;if(7001==B.code)b.Ja=!1,Dl(b),Ll(a,b,0),C.u(0);else if(b.type==f.ua&&a.h.ignoreTextStreamFailures)a.i.delete(f.ua),
480
- C.u(0);else if(3017==B.code)fm(a,b,B),C.u(0);else return b.ed=!0,1==B.category&&b.W&&jl(b.W,d),B.severity=2,F(C,Xl(a,b,B),0)}})}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.Gf})){if(a.g.disableStream(b.stream,a.h.maxDisabledTime))return;var d=Math.round(100*a.B);if(20<d)a.B-=.2;else if(4<d)a.B-=.04;else{b.ed=!0;a.A=!0;a.g.onError(c);return}b.Gf=!0}Ll(a,b,4)}
481
- function bm(a,b,c,d){var e,f,g,h,k,l,m,n,q,p,w,u,v,A,z;return O(function(D){switch(D.g){case 1:e=Wd;f=null==b.Na&&null==b.nc;g=[];h=Math.max(0,Math.max(c.appendWindowStart,a.O)-.1);k=Math.min(c.appendWindowEnd,a.N)+.01;l=he(c.codecs||b.stream.codecs);m=ie(c.mimeType||b.stream.mimeType);n=c.timestampOffset;if(n==b.Td&&h==b.Sd&&k==b.Rd&&l==b.tf&&m==b.uf){D.u(2);break}q=b.tf&&b.uf&&rk(a.g.aa,b.type,m,l);if(!q){D.u(3);break}p=null;b.type===e.ha?p=a.i.get(e.X):b.type===e.X&&(p=a.i.get(e.ha));if(!p){D.u(3);
482
- break}return F(D,El(p).catch(function(){}),5);case 5:p.nc=null,Ul(a,p);case 3:return F(D,gm(a,b,n,h,k,c,l,m),2);case 2:return Ei(c.$,b.nc)||(b.nc=c.$,c.l&&c.$&&(w=em(a,b,c.$),u=function(){var y,B,C,E,G,L,K;return O(function(I){switch(I.g){case 1:return ra(I,2),F(I,w,4);case 4:return y=I.h,Cg(a.m),B=null,C=new Map,E={projection:null,hfov:null},G=new Lg,G.box("moov",Qg).box("trak",Qg).box("mdia",Qg).S("mdhd",function(J){B=aj(J.reader,J.version).timescale}).box("hdlr",function(J){J=J.reader;J.skip(8);
483
- switch(J.qc()){case "soun":C.set(e.X,B);break;case "vide":C.set(e.ha,B)}B=null}).box("minf",Qg).box("stbl",Qg).S("stsd",Sg).box("encv",Tg).box("avc1",Tg).box("avc3",Tg).box("hev1",Tg).box("hvc1",Tg).box("dvav",Tg).box("dva1",Tg).box("dvh1",Tg).box("dvhe",Tg).box("dvc1",Tg).box("dvi1",Tg).box("vexu",Qg).box("proj",Qg).S("prji",function(J){J=J.reader.qc();E.projection=J}).box("hfov",function(J){J=J.reader.R()/1E3;E.hfov=J}).parse(y),hm(a,E),C.has(b.type)?c.$.timescale=C.get(b.type):null!=B&&(c.$.timescale=
484
- B),L=b.stream.closedCaptions&&0<b.stream.closedCaptions.size,F(I,a.g.kg(b.type,y),5);case 5:return F(I,Zj(a.g.aa,b.type,y,null,b.stream,L,b.Pc,d),6);case 6:ta(I,0);break;case 2:throw K=ua(I),b.nc=null,K;}})},v=c.startTime,f&&(A=Wj(a.g.aa,b.type),null!=A&&(v=A)),a.g.Ai(v,c.$),g.push(u()))),a.l.sequenceMode&&(z=b.Na?b.Na.i:null,c.i!=z&&g.push(kk(a.g.aa,b.type,c.startTime))),F(D,Promise.all(g),0)}})}
485
- function gm(a,b,c,d,e,f,g,h){var k,l,m,n;return O(function(q){if(1==q.g)return k=Wd,l=new Map,a.j.audio&&l.set(k.X,a.j.audio),a.j.video&&l.set(k.ha,a.j.video),ra(q,2),b.Sd=d,b.Rd=e,g&&(b.tf=g),h&&(b.uf=h),b.Td=c,m=a.l.sequenceMode||"HLS"==a.l.type,F(q,ik(a.g.aa,b.type,c,d,e,m,f.mimeType||b.stream.mimeType,f.codecs||b.stream.codecs,l),4);if(2!=q.g)return ta(q,0);n=ua(q);b.Sd=null;b.Rd=null;b.tf=null;b.uf=null;b.Td=null;throw n;})}
486
- function dm(a,b,c,d,e,f,g,h){g=void 0===g?!1:g;h=void 0===h?!1:h;var k,l,m,n,q,p,w,u;return O(function(v){switch(v.g){case 1:k=d.closedCaptions&&0<d.closedCaptions.size;m=null!=d.emsgSchemeIdUris&&0<d.emsgSchemeIdUris.length||a.h.dispatchAllEmsgBoxes;n=a.h.parsePrftBox&&!a.G;q="video/mp4"==d.mimeType||"audio/mp4"==d.mimeType;p=null;e.$&&(p=e.$.timescale);w=q&&p&&"video"===d.type&&"DASH"==a.l.type&&a.h.shouldFixTimestampOffset;if(m||n||w)l=new Lg;m&&l.S("emsg",function(A){var z=d.emsgSchemeIdUris;
487
- if(0===A.version){var D=A.reader.qc();var y=A.reader.qc();var B=A.reader.R();var C=A.reader.R();var E=A.reader.R();var G=A.reader.R();var L=e.startTime+C/B}else B=A.reader.R(),L=A.reader.Mc()/B+e.timestampOffset,C=L-e.startTime,E=A.reader.R(),G=A.reader.R(),D=A.reader.qc(),y=A.reader.qc();A=A.reader.qb(A.reader.getLength()-A.reader.va());if(z&&z.includes(D)||a.h.dispatchAllEmsgBoxes)if("urn:mpeg:dash:event:2012"==D)a.g.Bi();else if(z=L+E/B,B=(new Map).set("detail",{startTime:L,endTime:z,schemeIdUri:D,
477
+ function am(a,b,c,d,e){var f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B;return O(function(C){switch(C.g){case 1:f=Wd;g=b.stream;h=b.ka;b.Ja=!0;ra(C,2);if(2==d.Yb())throw new T(1,1,1011);return F(C,bm(a,b,d,e),4);case 4:Cg(a.m);if(a.A)return C.return();k="video/mp4"==g.mimeType||"audio/mp4"==g.mimeType;l=window.ReadableStream;if((m=a.h.lowLatencyMode&&a.l.isLowLatency)&&l&&k&&("HLS"!=a.l.type||d.m))return r=new Uint8Array(0),v=u=!1,A=function(E){var G,L,K,I;return O(function(J){switch(J.g){case 1:if(u)return J.return();
478
+ v=!0;Cg(a.m);if(a.A)return J.return();ra(J,2);r=cm(r,E);G=!1;L=0;(new Lg).box("mdat",function(M){L=M.size+M.start;G=!0}).parse(r,!1,!0);if(!G){J.u(4);break}K=r.subarray(0,L);r=r.subarray(L);return F(J,dm(a,b,c,g,d,K,!0,e),5);case 5:b.W&&b.ka&&dl(b.W,d.startTime,!0);case 4:ta(J,0);break;case 2:w=I=ua(J),H(J)}})},F(C,em(a,b,d,A),9);n=em(a,b,d);return F(C,n,7);case 7:p=C.h;Cg(a.m);if(a.A)return C.return();Cg(a.m);return b.dc?(b.Ja=!1,Ll(a,b,0),C.return()):F(C,dm(a,b,c,g,d,p,!1,e),6);case 9:z=C.h;if(w)throw w;
479
+ if(v){C.u(10);break}u=!0;Cg(a.m);return a.A?C.return():b.dc?(b.Ja=!1,Ll(a,b,0),C.return()):F(C,dm(a,b,c,g,d,z,!1,e),10);case 10:b.W&&b.ka&&dl(b.W,d.startTime,!0);case 6:Cg(a.m);if(a.A)return C.return();b.Na=d;h.next();b.Ja=!1;b.Gf=!1;D=a.g.aa.wb();y=D[b.type];db(JSON.stringify(y));b.dc||a.g.Af(d,b.stream);Ll(a,b,0);ta(C,0);break;case 2:B=ua(C);Cg(a.m,B);if(a.A)return C.return();b.Ja=!1;if(7001==B.code)b.Ja=!1,Dl(b),Ll(a,b,0),C.u(0);else if(b.type==f.ua&&a.h.ignoreTextStreamFailures)a.i.delete(f.ua),
480
+ C.u(0);else if(3017==B.code)fm(a,b,B),C.u(0);else return b.fd=!0,1==B.category&&b.W&&jl(b.W,d),B.severity=2,F(C,Xl(a,b,B),0)}})}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.Gf})){if(a.g.disableStream(b.stream,a.h.maxDisabledTime))return;var d=Math.round(100*a.B);if(20<d)a.B-=.2;else if(4<d)a.B-=.04;else{b.fd=!0;a.A=!0;a.g.onError(c);return}b.Gf=!0}Ll(a,b,4)}
481
+ function bm(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D;return O(function(y){switch(y.g){case 1:e=Wd;f=null==b.Na&&null==b.nc;g=[];h=Math.max(0,Math.max(c.appendWindowStart,a.O)-.1);k=Math.min(c.appendWindowEnd,a.N)+.01;l=c.codecs||b.stream.codecs;m=he(l);n=ie(c.mimeType||b.stream.mimeType);p=c.timestampOffset;if(p==b.Td&&h==b.Sd&&k==b.Rd&&m==b.tf&&n==b.uf){y.u(2);break}r=b.tf&&b.uf&&rk(a.g.aa,b.type,n,l);if(!r){y.u(3);break}u=null;b.type===e.ha?u=a.i.get(e.X):b.type===e.X&&(u=a.i.get(e.ha));if(!u){y.u(3);
482
+ break}return F(y,El(u).catch(function(){}),5);case 5:u.nc=null,Ul(a,u);case 3:return F(y,gm(a,b,p,h,k,c,m,n),2);case 2:return Ei(c.$,b.nc)||(b.nc=c.$,c.l&&c.$&&(v=em(a,b,c.$),w=function(){var B,C,E,G,L,K,I;return O(function(J){switch(J.g){case 1:return ra(J,2),F(J,v,4);case 4:return B=J.h,Cg(a.m),C=null,E=new Map,G={projection:null,hfov:null},L=new Lg,L.box("moov",Qg).box("trak",Qg).box("mdia",Qg).S("mdhd",function(M){C=aj(M.reader,M.version).timescale}).box("hdlr",function(M){M=M.reader;M.skip(8);
483
+ switch(M.qc()){case "soun":E.set(e.X,C);break;case "vide":E.set(e.ha,C)}C=null}).box("minf",Qg).box("stbl",Qg).S("stsd",Sg).box("encv",Tg).box("avc1",Tg).box("avc3",Tg).box("hev1",Tg).box("hvc1",Tg).box("dvav",Tg).box("dva1",Tg).box("dvh1",Tg).box("dvhe",Tg).box("dvc1",Tg).box("dvi1",Tg).box("vexu",Qg).box("proj",Qg).S("prji",function(M){M=M.reader.qc();G.projection=M}).box("hfov",function(M){M=M.reader.R()/1E3;G.hfov=M}).parse(B),hm(a,G),E.has(b.type)?c.$.timescale=E.get(b.type):null!=C&&(c.$.timescale=
484
+ C),K=b.stream.closedCaptions&&0<b.stream.closedCaptions.size,F(J,a.g.kg(b.type,B),5);case 5:return F(J,Zj(a.g.aa,b.type,B,null,b.stream,K,b.Qc,d),6);case 6:ta(J,0);break;case 2:throw I=ua(J),b.nc=null,I;}})},A=c.startTime,f&&(z=Wj(a.g.aa,b.type),null!=z&&(A=z)),a.g.Ai(A,c.$),g.push(w()))),a.l.sequenceMode&&(D=b.Na?b.Na.i:null,c.i!=D&&g.push(kk(a.g.aa,b.type,c.startTime))),F(y,Promise.all(g),0)}})}
485
+ function gm(a,b,c,d,e,f,g,h){var k,l,m,n;return O(function(p){if(1==p.g)return k=Wd,l=new Map,a.j.audio&&l.set(k.X,a.j.audio),a.j.video&&l.set(k.ha,a.j.video),ra(p,2),b.Sd=d,b.Rd=e,g&&(b.tf=g),h&&(b.uf=h),b.Td=c,m=a.l.sequenceMode||"HLS"==a.l.type,F(p,ik(a.g.aa,b.type,c,d,e,m,f.mimeType||b.stream.mimeType,f.codecs||b.stream.codecs,l),4);if(2!=p.g)return ta(p,0);n=ua(p);b.Sd=null;b.Rd=null;b.tf=null;b.uf=null;b.Td=null;throw n;})}
486
+ function dm(a,b,c,d,e,f,g,h){g=void 0===g?!1:g;h=void 0===h?!1:h;var k,l,m,n,p,r,u,v;return O(function(w){switch(w.g){case 1:k=d.closedCaptions&&0<d.closedCaptions.size;m=null!=d.emsgSchemeIdUris&&0<d.emsgSchemeIdUris.length||a.h.dispatchAllEmsgBoxes;n=a.h.parsePrftBox&&!a.G;p="video/mp4"==d.mimeType||"audio/mp4"==d.mimeType;r=null;e.$&&(r=e.$.timescale);u=p&&r&&"video"===d.type&&"DASH"==a.l.type&&a.h.shouldFixTimestampOffset;if(m||n||u)l=new Lg;m&&l.S("emsg",function(A){var z=d.emsgSchemeIdUris;
487
+ if(0===A.version){var D=A.reader.qc();var y=A.reader.qc();var B=A.reader.R();var C=A.reader.R();var E=A.reader.R();var G=A.reader.R();var L=e.startTime+C/B}else B=A.reader.R(),L=A.reader.Nc()/B+e.timestampOffset,C=L-e.startTime,E=A.reader.R(),G=A.reader.R(),D=A.reader.qc(),y=A.reader.qc();A=A.reader.qb(A.reader.getLength()-A.reader.va());if(z&&z.includes(D)||a.h.dispatchAllEmsgBoxes)if("urn:mpeg:dash:event:2012"==D)a.g.Bi();else if(z=L+E/B,B=(new Map).set("detail",{startTime:L,endTime:z,schemeIdUri:D,
488
488
  value:y,timescale:B,presentationTimeDelta:C,eventDuration:E,id:G,messageData:A}),B=new U("emsg",B),B.cancelable=!0,a.g.onEvent(B),!B.defaultPrevented&&("https://aomedia.org/emsg/ID3"==D||"https://developer.apple.com/streaming/emsg-id3"==D)&&(D=Xi(A),D.length))a.g.onMetadata([{cueTime:L,data:A,frames:D,dts:L,pts:L}],0,z)});n&&l.S("prft",function(A){if(!a.G&&e.$.timescale){var z=A.reader,D=A.version;z.R();A=z.R();var y=z.R();A=1E3*A+y/Math.pow(2,32)*1E3;0===D?z=z.R():(D=z.R(),z=z.R(),z=D*Math.pow(2,
489
- 32)+z);A=(new Date((new Date(Date.UTC(1900,0,1,0,0,0))).getTime()+A)).getTime();z=(new Map).set("detail",{wallClockTime:A,programStartDate:new Date(A-z/e.$.timescale*1E3)});z=new U("prft",z);a.g.onEvent(z);a.G=!0}});w&&l.box("moof",Qg).box("traf",Qg).S("tfdt",function(A){var z,D,y,B,C,E;return O(function(G){z=$i(A.reader,A.version);D=z.baseMediaDecodeTime;if(!D)return G.return();y=-D/p;B=Number(b.Td)||0;if(!(B<y))return G.u(0);C=b.Sd;E=b.Rd;return F(G,gm(a,b,y,C,E,e),0)})});(m||n||w)&&l.parse(f,!1,
490
- g);return F(v,im(a,b,c),2);case 2:return Cg(a.m),u=b.Pc,b.Pc=!1,F(v,a.g.kg(b.type,f),3);case 3:return F(v,Zj(a.g.aa,b.type,f,e,d,k,u,h,g),4);case 4:Cg(a.m),H(v)}})}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.l.presentationTimeline.g);e=Uj(a.g.aa,b.type);if(null==e)return h.return();f=c-e;g=f-d;return g<=a.h.evictionGoal?h.return():F(h,a.g.aa.remove(b.type,e,e+g),2)}Cg(a.m);H(h)})}
489
+ 32)+z);A=(new Date((new Date(Date.UTC(1900,0,1,0,0,0))).getTime()+A)).getTime();z=(new Map).set("detail",{wallClockTime:A,programStartDate:new Date(A-z/e.$.timescale*1E3)});z=new U("prft",z);a.g.onEvent(z);a.G=!0}});u&&l.box("moof",Qg).box("traf",Qg).S("tfdt",function(A){var z,D,y,B,C,E;return O(function(G){z=$i(A.reader,A.version);D=z.baseMediaDecodeTime;if(!D)return G.return();y=-D/r;B=Number(b.Td)||0;if(!(B<y))return G.u(0);C=b.Sd;E=b.Rd;return F(G,gm(a,b,y,C,E,e),0)})});(m||n||u)&&l.parse(f,!1,
490
+ g);return F(w,im(a,b,c),2);case 2:return Cg(a.m),v=b.Qc,b.Qc=!1,F(w,a.g.kg(b.type,f),3);case 3:return F(w,Zj(a.g.aa,b.type,f,e,d,k,v,h,g),4);case 4:Cg(a.m),H(w)}})}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.l.presentationTimeline.g);e=Uj(a.g.aa,b.type);if(null==e)return h.return();f=c-e;g=f-d;return g<=a.h.evictionGoal?h.return():F(h,a.g.aa.remove(b.type,e,e+g),2)}Cg(a.m);H(h)})}
491
491
  function Zl(a){return a&&a.type==Ud&&("application/cea-608"==a.stream.mimeType||"application/cea-708"==a.stream.mimeType)}
492
- function em(a,b,c,d){var e,f,g,h,k;return O(function(l){switch(l.g){case 1:if(e=c.bd())return l.return(e);f=null;if(b.W){var m=b.W,n=m.h;c instanceof Di&&(n=m.j);n.has(c)?(m=n.get(c),d&&(m.Uf=d),f=m.ee):f=null}f||(f=Vl(c,b.stream,d||null,a.h.retryParameters,a.g.Lb));g=0;b.ka&&(g=b.ka.h);b.ib=f;return F(l,f.promise,2);case 2:h=l.h;b.ib=null;k=h.data;if(!c.aesKey){l.u(3);break}return F(l,zl(k,c.aesKey,g),4);case 4:k=l.h;case 3:return l.return(k)}})}
492
+ function em(a,b,c,d){var e,f,g,h,k;return O(function(l){switch(l.g){case 1:if(e=c.cd())return l.return(e);f=null;if(b.W){var m=b.W,n=m.h;c instanceof Di&&(n=m.j);n.has(c)?(m=n.get(c),d&&(m.Uf=d),f=m.ee):f=null}f||(f=Vl(c,b.stream,d||null,a.h.retryParameters,a.g.Lb));g=0;b.ka&&(g=b.ka.h);b.ib=f;return F(l,f.promise,2);case 2:h=l.h;b.ib=null;k=h.data;if(!c.aesKey){l.u(3);break}return F(l,zl(k,c.aesKey,g),4);case 4:k=l.h;case 3:return l.return(k)}})}
493
493
  function Vl(a,b,c,d,e){var f=a instanceof Fi?a:void 0,g=f?1:0;a=Al(a.M(),a.Ga,a.ta,d,c);a.contentType=b.type;return e.request(zg,a,{type:g,stream:b,segment:f})}
494
- function Sl(a,b,c,d){var e,f;return O(function(g){if(1==g.g)return b.dc=!1,b.Ae=!1,b.Ed=0,b.Uc=!0,b.Na=null,b.ka=null,b.W&&!a.o.has(b.stream)&&kl(b.W),d?(e=a.g.Jd(),f=a.g.aa.getDuration(),F(g,a.g.aa.remove(b.type,e+d,f),3)):F(g,hk(a.g.aa,b.type),4);if(3!=g.g)return Cg(a.m),c?F(g,a.g.aa.flush(b.type),3):g.u(3);Cg(a.m);b.Uc=!1;b.endOfStream=!1;b.Ja||b.sb||Ll(a,b,0);H(g)})}
494
+ function Sl(a,b,c,d){var e,f;return O(function(g){if(1==g.g)return b.dc=!1,b.Ae=!1,b.Ed=0,b.Vc=!0,b.Na=null,b.ka=null,b.W&&!a.o.has(b.stream)&&kl(b.W),d?(e=a.g.Jd(),f=a.g.aa.getDuration(),F(g,a.g.aa.remove(b.type,e+d,f),3)):F(g,hk(a.g.aa,b.type),4);if(3!=g.g)return Cg(a.m),c?F(g,a.g.aa.flush(b.type),3):g.u(3);Cg(a.m);b.Vc=!1;b.endOfStream=!1;b.Ja||b.sb||Ll(a,b,0);H(g)})}
495
495
  function Ll(a,b,c){var d=b.type;if(d!=Ud||a.i.has(d))b.sb=(new Rc(function(){var e;return O(function(f){if(1==f.g)return ra(f,2),F(f,Wl(a,b),4);if(2!=f.g)return ta(f,0);e=ua(f);if(a.g)a.g.onError(e);H(f)})})).Z(c)}function Dl(a){null!=a.sb&&(a.sb.stop(),a.sb=null)}function El(a){return O(function(b){return a.ib?F(b,a.ib.abort(),0):b.u(0)})}
496
496
  function Xl(a,b,c){var d;return O(function(e){if(1==e.g)return F(e,ag(a.K),2);Cg(a.m);if(1===c.category){if(b.$b)return Nl(a,!1),e.return();d=0===a.h.maxDisabledTime&&1011==c.code?1:a.h.maxDisabledTime;c.handled=a.g.disableStream(b.stream,d);c.handled&&(c.severity=1)}if(!c.handled||1011!=c.code)a.g.onError(c);c.handled||a.h.failureCallback(c);H(e)})}
497
497
  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=Wd;if(e=a.i.get(d.X))e.nc=null,Ul(a,e),El(e).catch(function(){});if(f=a.i.get(d.ha))f.nc=null,Ul(a,f),El(f).catch(function(){});g=new Map;a.j.audio&&g.set(d.X,a.j.audio);a.j.video&&g.set(d.ha,a.j.video);return F(h,qk(a.g.aa,g),2)}return h.return(!0)})}
@@ -504,14 +504,14 @@ function tm(a,b){2===a&&(b.headers["Content-Type"]="application/octet-stream")}S
504
504
  pm.conaxFairPlayRequest=function(a,b){tm(a,b)};pm.ezdrmFairPlayRequest=function(a,b){tm(a,b)};pm.verimatrixFairPlayRequest=function(a,b){2===a&&(a=zb(b.body),a=Fd(a),b.headers["Content-Type"]="application/x-www-form-urlencoded",b.body=zd("spc="+a))};pm.expressplayInitDataTransform=function(a,b,c){return sm(a,b,c)};
505
505
  pm.conaxInitDataTransform=function(a,b,c){if("skd"!==b)return a;b=c.serverCertificate;c=yd(a).split("skd://").pop().split("?").shift();c=window.atob(c);var d=new ArrayBuffer(2*c.length);d=Db(d);for(var e=0,f=c.length;e<f;e++)d[e]=c.charCodeAt(e);return rm(a,d,b)};pm.ezdrmInitDataTransform=function(a,b,c){if("skd"!==b)return a;b=c.serverCertificate;c=yd(a).split(";").pop();return rm(a,c,b)};pm.verimatrixInitDataTransform=function(a,b,c){return sm(a,b,c)};pm.initDataTransform=rm;
506
506
  pm.defaultGetContentId=qm;pm.isFairPlaySupported=function(){var a;return O(function(b){if(1==b.g)return a={initDataTypes:["cenc","sinf","skd"],videoCapabilities:[{contentType:'video/mp4; codecs="avc1.42E01E"'}]},ra(b,2),F(b,navigator.requestMediaKeySystemAccess("com.apple.fps",[a]),4);if(2!=b.g)return b.return(!0);ua(b);return b.return(!1)})};function um(){}
507
- function vm(){var a=Infinity;navigator.connection&&navigator.connection.saveData&&(a=360);var b={retryParameters:$f(),servers:{},clearKeys:{},advanced:{},delayLicenseRequestUntilPlayed:!1,persistentSessionOnlinePlayback:!1,persistentSessionsMetadata:[],initDataTransform:function(m,n,q){rd()&&"skd"==n&&(n=q.serverCertificate,q=qm(m),m=rm(m,q,n));return m},logLicenseExchange:!1,updateExpirationTime:1,preferredKeySystems:[],keySystemsMapping:{},parseInbandPsshEnabled:Yc(),minHdcpVersion:"",ignoreDuplicateInitData:!bd()};
507
+ function vm(){var a=Infinity;navigator.connection&&navigator.connection.saveData&&(a=360);var b={retryParameters:$f(),servers:{},clearKeys:{},advanced:{},delayLicenseRequestUntilPlayed:!1,persistentSessionOnlinePlayback:!1,persistentSessionsMetadata:[],initDataTransform:function(m,n,p){rd()&&"skd"==n&&(n=p.serverCertificate,p=qm(m),m=rm(m,p,n));return m},logLicenseExchange:!1,updateExpirationTime:1,preferredKeySystems:[],keySystemsMapping:{},parseInbandPsshEnabled:Yc(),minHdcpVersion:"",ignoreDuplicateInitData:!bd()};
508
508
  (Yc()||id())&&b.preferredKeySystems.push("com.microsoft.playready");var c="reload",d=!1;bd()||ad()||Zc("Tizen 4")||Zc("Tizen 5")||Zc("Tizen 6")||dd()||cd()&&53===ed()||cd()&&68===ed()||!(!fd()||fd()&&nd()||fd()&&Zc("Fuchsia"))||md()&&Wc()||(c="smooth",d=!0);d={retryParameters:$f(),availabilityWindowOverride:NaN,disableAudio:!1,disableVideo:!1,disableText:!1,disableThumbnails:!1,defaultPresentationDelay:0,segmentRelativeVttTiming:!1,raiseFatalErrorOnManifestUpdateRequestFailure:!1,continueLoadingWhenPaused:!0,
509
509
  dash:{clockSyncUri:"",ignoreDrmInfo:!1,disableXlinkProcessing:!1,xlinkFailGracefully:!1,ignoreMinBufferTime:!1,autoCorrectDrift:!0,initialSegmentLimit:1E3,ignoreSuggestedPresentationDelay:!1,ignoreEmptyAdaptationSet:!1,ignoreMaxSegmentDuration:!1,keySystemsByURI:{"urn:uuid:1077efec-c0b2-4d02-ace3-3c1e52e2fb4b":"org.w3.clearkey","urn:uuid:e2719d58-a985-b3c9-781a-b030af78d30e":"org.w3.clearkey","urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":"com.widevine.alpha","urn:uuid:9a04f079-9840-4286-ab92-e65be0885f95":"com.microsoft.playready",
510
510
  "urn:uuid:79f0049a-4098-8642-ab92-e65be0885f95":"com.microsoft.playready"},manifestPreprocessor:wm,manifestPreprocessorTXml:xm,sequenceMode:!1,enableAudioGroups:!1,multiTypeVariantsAllowed:d,useStreamOnceInPeriodFlattening:!1,updatePeriod:-1,enableFastSwitching:!0},hls:{ignoreTextStreamFailures:!1,ignoreImageStreamFailures:!1,defaultAudioCodec:"mp4a.40.2",defaultVideoCodec:"avc1.42E01E",ignoreManifestProgramDateTime:!1,ignoreManifestProgramDateTimeForTypes:[],mediaPlaylistFullMimeType:'video/mp2t; codecs="avc1.42E01E, mp4a.40.2"',
511
511
  useSafariBehaviorForLive:!0,liveSegmentsDelay:3,sequenceMode:ad()||bd()||dd()||id()?!1:!0,ignoreManifestTimestampsInSegmentsMode:!1,disableCodecGuessing:!1,disableClosedCaptionsDetection:!1,allowLowLatencyByteRangeOptimization:!0},mss:{manifestPreprocessor:wm,manifestPreprocessorTXml:xm,sequenceMode:!1,keySystemsBySystemId:{"9a04f079-9840-4286-ab92-e65be0885f95":"com.microsoft.playready","79f0049a-4098-8642-ab92-e65be0885f95":"com.microsoft.playready"}}};var e={retryParameters:$f(),failureCallback:function(m){return nm([m])},
512
512
  rebufferingGoal:2,bufferingGoal:10,bufferBehind:30,evictionGoal:1,ignoreTextStreamFailures:!1,alwaysStreamText:!1,startAtSegmentBoundary:!1,gapDetectionThreshold:.5,gapJumpTimerTime:.25,durationBackoff:1,safeSeekOffset:5,stallEnabled:!0,stallThreshold:1,stallSkip:.1,useNativeHlsForFairPlay:!0,inaccurateManifestTolerance:2,lowLatencyMode:!1,autoLowLatencyMode:!1,forceHTTP:!1,forceHTTPS:!1,preferNativeHls:!1,updateIntervalSeconds:1,dispatchAllEmsgBoxes:!1,observeQualityChanges:!1,maxDisabledTime:30,
513
513
  parsePrftBox:!1,segmentPrefetchLimit:0,prefetchAudioLanguages:[],disableAudioPrefetch:!1,disableTextPrefetch:!1,disableVideoPrefetch:!1,liveSync:{enabled:!1,targetLatency:.5,targetLatencyTolerance:.5,maxPlaybackRate:1.1,minPlaybackRate:.95,panicMode:!1,panicThreshold:60,dynamicTargetLatency:{enabled:!1,stabilityThreshold:60,rebufferIncrement:.5,maxAttempts:10,maxLatency:4,minLatency:1}},allowMediaSourceRecoveries:!0,minTimeBetweenRecoveries:5,vodDynamicPlaybackRate:!1,vodDynamicPlaybackRateLowBufferRate:.95,
514
- vodDynamicPlaybackRateBufferRatio:.5,infiniteLiveStreamDuration:!1,preloadNextUrlWindow:30,loadTimeout:30,clearDecodingCache:id()||jd(),dontChooseCodecs:!1,shouldFixTimestampOffset:cd()||$c()};if(cd()||$c()||fd()||kd())e.stallSkip=0;var f={trackSelectionCallback:function(m){return O(function(n){return n.return(m)})},downloadSizeCallback:function(m){var n;return O(function(q){if(1==q.g)return navigator.storage&&navigator.storage.estimate?F(q,navigator.storage.estimate(),3):q.return(!0);n=q.h;return q.return(n.usage+
514
+ vodDynamicPlaybackRateBufferRatio:.5,infiniteLiveStreamDuration:!1,preloadNextUrlWindow:30,loadTimeout:30,clearDecodingCache:id()||jd(),dontChooseCodecs:!1,shouldFixTimestampOffset:cd()||$c()};if(cd()||$c()||fd()||kd())e.stallSkip=0;var f={trackSelectionCallback:function(m){return O(function(n){return n.return(m)})},downloadSizeCallback:function(m){var n;return O(function(p){if(1==p.g)return navigator.storage&&navigator.storage.estimate?F(p,navigator.storage.estimate(),3):p.return(!0);n=p.h;return p.return(n.usage+
515
515
  m<.95*n.quota)})},progressCallback:function(m,n){return nm([m,n])},usePersistentLicense:!0,numberOfParallelDownloads:5};a={enabled:!0,useNetworkInformation:!0,defaultBandwidthEstimate:1E6,switchInterval:8,bandwidthUpgradeTarget:.85,bandwidthDowngradeTarget:.95,restrictions:{minWidth:0,maxWidth:Infinity,minHeight:0,maxHeight:a,minPixels:0,maxPixels:Infinity,minFrameRate:0,maxFrameRate:Infinity,minBandwidth:0,maxBandwidth:Infinity,minChannelsCount:0,maxChannelsCount:Infinity},advanced:{minTotalBytes:128E3,
516
516
  minBytes:16E3,fastHalfLife:2,slowHalfLife:5},restrictToElementSize:!1,restrictToScreenSize:!1,ignoreDevicePixelRatio:!1,clearBufferSwitch:!1,safeMarginSwitch:0,cacheLoadThreshold:20,minTimeToSwitch:gd()?.5:0};c={codecSwitchingStrategy:c,addExtraFeaturesToSourceBuffer:function(m){return nm([m],"")},forceTransmux:!1,insertFakeEncryptionInInit:!0,modifyCueCallback:function(m,n){return nm([m,n])}};var g=!1,h=!1,k=!0;od()&&(h=g=!0,k=!1);var l={drm:b,manifest:d,streaming:e,mediaSource:c,offline:f,abrFactory:function(){return new xf},
517
517
  abr:a,autoShowText:3,preferredAudioLanguage:"",preferredAudioLabel:"",preferredTextLanguage:"",preferredVariantRole:"",preferredTextRole:"",preferredAudioChannelCount:2,preferredVideoHdrLevel:"AUTO",preferredVideoLayout:"",preferredVideoLabel:"",preferredVideoCodecs:[],preferredAudioCodecs:[],preferForcedSubs:!1,preferSpatialAudio:!1,preferredDecodingAttributes:[],restrictions:{minWidth:0,maxWidth:Infinity,minHeight:0,maxHeight:Infinity,minPixels:0,maxPixels:Infinity,minFrameRate:0,maxFrameRate:Infinity,
@@ -520,46 +520,46 @@ supportsMultipleMediaElements:k}};f.trackSelectionCallback=function(m){return O(
520
520
  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,"")}
521
521
  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=Ke(b,e.map(function(h){return h.language}));f&&(c=e.filter(function(h){return De(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-
522
522
  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!=Ud&&"image"!=c.type||b.push(c);return b}function wm(a){return nm([a],a)}function xm(a){return nm([a],a)}S("shaka.util.PlayerConfiguration",um);um.mergeConfigObjects=zm;um.createDefault=vm;function Am(a,b,c,d){lg.call(this);this.L=a;this.T=b;this.xa=d.networkingEngine;this.A=c;this.o=null;this.ra=0;this.Fa=d.zc;this.C=d.vi;this.ab=d.wi;this.g=d.config;this.j=this.F=this.h=null;this.ea=!1;this.G=d.Fi;this.la=!1;this.l=null;this.da=!1;this.i=this.B=null;this.ba=!1;this.K=new Map;this.qa=!1;this.za=d.Ei;this.Y=new al;this.m=new bg;this.N=null;this.s=!1;this.Da=d.yh;this.fa=null;this.Ea=d.xh;this.O=!1;this.I=[];this.H=[]}na(Am,lg);function Bm(a,b,c){(a=b?a.H:a.I)?a.push(c):c()}
523
- function Cm(a){if(a.H)for(var b=t(a.H),c=b.next();!c.done;c=b.next())c=c.value,c();a.H=null}function Dm(a,b){a.N=b;a.O=!0;if(a.I){b=t(a.I);for(var c=b.next();!c.done;c=b.next())c=c.value,c()}a.I=null}r=Am.prototype;r.getStartTime=function(){return this.A};r.Ec=function(){return this.L};r.ff=function(){return this.h};function Em(a){a.ba=!0;return a.i}function Fm(a){a.ea=!0;return a.j}function Gm(a){a.la=!0;return a.G}r.getStats=function(){return this.Y};function Hm(a){a.da=!0;return a.l}
523
+ function Cm(a){if(a.H)for(var b=t(a.H),c=b.next();!c.done;c=b.next())c=c.value,c();a.H=null}function Dm(a,b){a.N=b;a.O=!0;if(a.I){b=t(a.I);for(var c=b.next();!c.done;c=b.next())c=c.value,c()}a.I=null}q=Am.prototype;q.getStartTime=function(){return this.A};q.Ec=function(){return this.L};q.ff=function(){return this.h};function Em(a){a.ba=!0;return a.i}function Fm(a){a.ea=!0;return a.j}function Gm(a){a.la=!0;return a.G}q.getStats=function(){return this.Y};function Hm(a){a.da=!0;return a.l}
524
524
  function Im(a){a.qa=!0;return a.K}
525
- r.start=function(){var a=this;(function(){var b;return O(function(c){switch(c.g){case 1:return F(c,Promise.resolve(),2);case 2:return ra(c,3),F(c,Jm(a),5);case 5:return Km(a),F(c,Lm(a),6);case 6:Km(a);a.o||(a.o=new Lf(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));if(a.Ea){var d=
526
- a.g.abrFactory;a.B=d;a.i=d();a.i.configure(a.g.abr)}if(a.Da){d=a.h.presentationTimeline.V();var e=uf(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())a.fa=e,e.video&&Mm(a,e.video,d),e.audio&&Mm(a,e.audio,d)}return F(c,void 0,7);case 7:Km(a);a.m.resolve();ta(c,0);break;case 3:b=ua(c),a.m.reject(b),H(c)}})})()};r.dispatchEvent=function(a){return this.N?this.N.dispatchEvent(a):lg.prototype.dispatchEvent.call(this,a)};
527
- r.onError=function(a){2===a.severity&&(this.m.reject(a),this.destroy());var b=(new Map).set("detail",a);b=new U("error",b);this.dispatchEvent(b);b.defaultPrevented&&(a.handled=!0)};function Km(a){if(a.s)throw new T(2,7,7003);}function Nm(a,b){a.dispatchEvent(new U("onstatechange",(new Map).set("state",b)))}
525
+ q.start=function(){var a=this;(function(){var b;return O(function(c){switch(c.g){case 1:return F(c,Promise.resolve(),2);case 2:return ra(c,3),F(c,Jm(a),5);case 5:return Km(a),F(c,Lm(a),6);case 6:Km(a);a.o||(a.o=new Lf(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));if(a.Ea){var d=
526
+ a.g.abrFactory;a.B=d;a.i=d();a.i.configure(a.g.abr)}if(a.Da){d=a.h.presentationTimeline.V();var e=uf(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())a.fa=e,e.video&&Mm(a,e.video,d),e.audio&&Mm(a,e.audio,d)}return F(c,void 0,7);case 7:Km(a);a.m.resolve();ta(c,0);break;case 3:b=ua(c),a.m.reject(b),H(c)}})})()};q.dispatchEvent=function(a){return this.N?this.N.dispatchEvent(a):lg.prototype.dispatchEvent.call(this,a)};
527
+ q.onError=function(a){2===a.severity&&(this.m.reject(a),this.destroy());var b=(new Map).set("detail",a);b=new U("error",b);this.dispatchEvent(b);b.defaultPrevented&&(a.handled=!0)};function Km(a){if(a.s)throw new T(2,7,7003);}function Nm(a,b){a.dispatchEvent(new U("onstatechange",(new Map).set("state",b)))}
528
528
  function Jm(a){var b,c,d,e;return O(function(f){if(1==f.g)return Nm(a,"manifest-parser"),a.j||(a.F=xi(a.L,a.T),a.j=a.F(),a.j.configure(a.g.manifest)),b=Date.now()/1E3,Nm(a,"manifest"),a.h?f.u(2):F(f,a.j.start(a.L,a.ab),3);2!=f.g&&(a.h=f.h);c=new U("manifestparsed",void 0);a.dispatchEvent(c);if(0==a.h.variants.length)throw new T(2,4,4036);Om(a.h);d=Date.now()/1E3;e=d-b;a.Y.H=e;H(f)})}
529
529
  function Lm(a){var b,c,d,e,f;return O(function(g){switch(g.g){case 1:Nm(a,"drm-engine");a.ra=Date.now()/1E3;a.l=a.Fa();a.C.g=a.l;a.l.configure(a.g.drm);var h=a.C;b=Se(a.h.variants,h.h.restrictions,h.i);if(!b){g.u(2);break}c=new U("trackschanged",void 0);return F(g,Promise.resolve(),3);case 3:Km(a),a.dispatchEvent(c);case 2:return d=uf(a.h.variants),F(g,Nh(a.l,d,a.h.offlineSessionIds),4);case 4:return Km(a),F(g,ri(a.C,a.h),5);case 5:e=g.h;if(!e){g.u(0);break}f=new U("trackschanged",void 0);return F(g,
530
- Promise.resolve(),7);case 7:a.dispatchEvent(f),H(g)}})}r.configure=function(a,b){a=mm(a,b);zm(this.g,a)};r.getConfiguration=function(){return Le(this.g)};
531
- 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 bl(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),F(k,b.createSegmentIndex(),2);f=a.A||0;(h=(g=b.segmentIndex.Ib(f))?g.current():null)||(h=b.segmentIndex.get(0));h&&(c?h.$&&el(e,h.$):dl(e,h.startTime));H(k)})}r.fj=function(){return this.m};
532
- r.destroy=function(){var a=this,b,c,d;return O(function(e){switch(e.g){case 1:a.s=!0;if(!a.j||a.ea){e.u(2);break}return F(e,a.j.stop(),2);case 2:if(!a.i||a.ba){e.u(4);break}return F(e,a.i.stop(),4);case 4:a.G&&!a.la&&a.G.release();if(!a.l||a.da){e.u(6);break}return F(e,a.l.destroy(),6);case 6:if(0<a.K.size&&!a.qa)for(b=t(a.K.values()),c=b.next();!c.done;c=b.next())d=c.value,kl(d);H(e)}})};
530
+ Promise.resolve(),7);case 7:a.dispatchEvent(f),H(g)}})}q.configure=function(a,b){a=mm(a,b);zm(this.g,a)};q.getConfiguration=function(){return Le(this.g)};
531
+ 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 bl(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),F(k,b.createSegmentIndex(),2);f=a.A||0;(h=(g=b.segmentIndex.Ib(f))?g.current():null)||(h=b.segmentIndex.get(0));h&&(c?h.$&&el(e,h.$):dl(e,h.startTime));H(k)})}q.fj=function(){return this.m};
532
+ q.destroy=function(){var a=this,b,c,d;return O(function(e){switch(e.g){case 1:a.s=!0;if(!a.j||a.ea){e.u(2);break}return F(e,a.j.stop(),2);case 2:if(!a.i||a.ba){e.u(4);break}return F(e,a.i.stop(),4);case 4:a.G&&!a.la&&a.G.release();if(!a.l||a.da){e.u(6);break}return F(e,a.l.destroy(),6);case 6:if(0<a.K.size&&!a.qa)for(b=t(a.K.values()),c=b.next();!c.done;c=b.next())d=c.value,kl(d);H(e)}})};
533
533
  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))}S("shaka.media.PreloadManager",Am);Am.prototype.destroy=Am.prototype.destroy;Am.prototype.waitForFinish=Am.prototype.fj;function Pm(a,b){lg.call(this);var c=this;this.i=a;this.l=b;this.g=new Map;this.m=[{xc:null,wc:Qm,lc:function(d,e){return Rm(c,"enter",d,e)}},{xc:Sm,wc:Qm,lc:function(d,e){return Rm(c,"enter",d,e)}},{xc:Tm,wc:Qm,lc:function(d,e){return Rm(c,"enter",d,e)}},{xc:Qm,wc:Sm,lc:function(d,e){return Rm(c,"exit",d,e)}},{xc:Qm,wc:Tm,lc:function(d,e){return Rm(c,"exit",d,e)}},{xc:Sm,wc:Tm,lc:function(d,e){return Rm(c,"skip",d,e)}},{xc:Tm,wc:Sm,lc:function(d,e){return Rm(c,"skip",d,e)}}];this.h=new gb;this.h.D(this.i,
534
534
  "regionremove",function(d){c.g.delete(d.region)})}na(Pm,lg);Pm.prototype.release=function(){this.i=null;this.g.clear();this.h.release();this.h=null;lg.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.xc==e&&h.wc==f&&h.lc(d,b)}}};
535
535
  function Rm(a,b,c,d){b=new U(b,new Map([["region",c],["seeking",d]]));a.dispatchEvent(b)}var Sm=1,Qm=2,Tm=3;function hn(a,b,c){var d,e,f,g,h,k,l;return O(function(m){switch(m.g){case 1:var n=(new tc(a)).Pa.split("/").pop().split(".");d=1==n.length?"":n.pop().toLowerCase();if(e=jn[d])return m.return(e);f=0;g=tg([a],c);ra(m,2);g.method="HEAD";return F(m,b.request(f,g).promise,4);case 4:h=m.h;e=h.headers["content-type"];ta(m,3);break;case 2:k=ua(m);if(!k||1002!=k.code&&1001!=k.code){m.u(3);break}g.method="GET";return F(m,b.request(f,g).promise,6);case 6:l=m.h,e=l.headers["content-type"];case 3:return m.return(e?
536
536
  e.toLowerCase().split(";").shift():"")}})}
537
- var jn={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 kn(a,b){if(a.lineBreak)return"\n";if(a.nestedCues.length)return a.nestedCues.map(function(g){return kn(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=ln(e))&&(d+="."+e);e=a.backgroundColor;""==e&&b&&(e=b.backgroundColor);(b=ln(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;
538
- return"<"+h+(void 0===k?"":k)+">"+g+"</"+h+">"},a.payload)}
537
+ var jn={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 kn(a,b){if(a.lineBreak)return"\n";if(a.nestedCues.length)return a.nestedCues.map(function(g){return kn(g,a)}).join("");if(!a.payload)return a.payload;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=ln(e))&&(d+="."+e);e=a.backgroundColor;""==e&&b&&(e=b.backgroundColor);(b=ln(e))&&(d+=".bg_"+b);d&&c.push(["c",d]);return c.reduceRight(function(g,h){var k=t(h);
538
+ h=k.next().value;k=k.next().value;return"<"+h+(void 0===k?"":k)+">"+g+"</"+h+">"},a.payload)}
539
539
  function ln(a){a=a.toLowerCase();var b=a.replace(/\s/g,"").match(/^rgba?\((\d+),(\d+),(\d+),?([^,\s)]+)?/i);b?a="#"+(parseInt(b[1],10)|256).toString(16).slice(1)+(parseInt(b[2],10)|256).toString(16).slice(1)+(parseInt(b[3],10)|256).toString(16).slice(1):a.startsWith("#")&&7<a.length&&(a=a.slice(0,7));switch(a){case "white":case "#fff":case "#ffffff":return"white";case "lime":case "#0f0":case "#00ff00":return"lime";case "cyan":case "#0ff":case "#00ffff":return"cyan";case "red":case "#f00":case "#ff0000":return"red";
540
540
  case "yellow":case "#ff0":case "#ffff00":return"yellow";case "magenta":case "#f0f":case "#ff00ff":return"magenta";case "blue":case "#00f":case "#0000ff":return"blue";case "black":case "#000":case "#000000":return"black"}return null}function mn(a,b){var c=[];a=t(nn(a));for(var d=a.next();!d.done;d=a.next())if(d=d.value,d.isContainer)c.push.apply(c,x(mn(d.nestedCues,d)));else{var e=d.clone();e.nestedCues=[];e.payload=kn(d,b);c.push(e)}return c}
541
541
  function nn(a){var b=[];a=t(a);for(var c=a.next(),d={};!c.done;d={Le:void 0},c=a.next())d.Le=c.value,b.some(function(e){return function(f){return bc(e.Le,f)}}(d))||b.push(d.Le);return b}
542
542
  function on(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&&
543
- (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 pn(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"}r=pn.prototype;r.configure=function(){};r.remove=function(a,b){if(!this.g)return!1;qn(this.g,function(c){return c.startTime<b&&c.endTime>a});return!0};
544
- r.append=function(a){var b=mn(a),c=[];a=this.g.cues?Array.from(this.g.cues):[];b=t(b);for(var d=b.next(),e={};!d.done;e={gd:void 0},d=b.next())e.gd=d.value,a.some(function(f){return function(g){return g.startTime==f.gd.startTime&&g.endTime==f.gd.endTime&&g.text==f.gd.payload?!0:!1}}(e))||(d=on(e.gd))&&c.push(d);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)-
545
- c.indexOf(g)});a=t(a);for(b=a.next();!b.done;b=a.next())this.g.addCue(b.value)};r.destroy=function(){this.g&&(qn(this.g,function(){return!0}),this.g.mode="disabled");this.g=null;return Promise.resolve()};r.isTextVisible=function(){return"showing"==this.g.mode};r.setTextVisibility=function(a){this.g.mode=a?"showing":"hidden"};
546
- function qn(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}S("shaka.text.SimpleTextDisplayer",pn);pn.prototype.setTextVisibility=pn.prototype.setTextVisibility;pn.prototype.isTextVisible=pn.prototype.isTextVisible;pn.prototype.destroy=pn.prototype.destroy;pn.prototype.append=pn.prototype.append;pn.prototype.remove=pn.prototype.remove;pn.prototype.configure=pn.prototype.configure;function rn(){}r=rn.prototype;r.configure=function(){};r.remove=function(){};r.append=function(){};r.destroy=function(){};r.isTextVisible=function(){return!1};r.setTextVisibility=function(){};S("shaka.text.StubTextDisplayer",rn);rn.prototype.setTextVisibility=rn.prototype.setTextVisibility;rn.prototype.isTextVisible=rn.prototype.isTextVisible;rn.prototype.destroy=rn.prototype.destroy;rn.prototype.append=rn.prototype.append;rn.prototype.remove=rn.prototype.remove;rn.prototype.configure=rn.prototype.configure;function sn(){}function tn(a){for(;a.firstChild;)a.removeChild(a.firstChild)}S("shaka.util.Dom",sn);sn.removeAllChildren=tn;function un(a,b,c){var d=this;this.m=!1;this.h=[];this.A=a;this.s=b;this.l=null;this.g=document.createElement("div");this.g.classList.add("shaka-text-container");this.g.style.textAlign="center";this.g.style.display="flex";this.g.style.flexDirection="column";this.g.style.alignItems="center";this.g.style.justifyContent="flex-end";this.s.appendChild(this.g);c&&c.captionsUpdatePeriod||qb("UITextDisplayer w/ config","Please migrate to initializing UITextDisplayer with a config.");this.C=(new Sc(function(){d.A.paused||
547
- vn(d)})).Ra(c&&c.captionsUpdatePeriod?c.captionsUpdatePeriod:.25);this.i=new Map;this.j=new gb;this.j.D(document,"fullscreenchange",function(){vn(d,!0)});this.j.D(this.A,"seeking",function(){vn(d,!0)});this.j.D(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(){vn(d,!0)}),this.o.observe(this.g));this.B=new Map}r=un.prototype;r.configure=function(a){this.C&&this.C.Ra(a.captionsUpdatePeriod)};
548
- r.append=function(a){var b=[].concat(x(this.h));a=t(nn(a));for(var c=a.next(),d={};!c.done;d={Me:void 0},c=a.next())d.Me=c.value,b.some(function(e){return function(f){return bc(f,e.Me)}}(d))||this.h.push(d.Me);vn(this)};r.destroy=function(){if(!this.g)return Promise.resolve();this.s.removeChild(this.g);this.g=null;this.m=!1;this.h=[];this.C&&this.C.stop();this.i.clear();this.j&&(this.j.release(),this.j=null);this.o&&(this.o.disconnect(),this.o=null);return Promise.resolve()};
549
- r.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});vn(this,c>this.h.length);return!0};r.isTextVisible=function(){return this.m};r.setTextVisibility=function(a){this.m=a};function wn(a,b){for(;null!=b;){if(b==a.g)return!0;b=b.parentElement}return!1}
550
- function xn(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.qh:null;l&&(g.push(l.Ne),l.sc&&g.push(l.sc),m||(f=!0,a.i.delete(k),l=null));m&&(h.push(k),l?wn(a,n)||(f=!0):(yn(a,k,e),l=a.i.get(k),n=l.qh,f=!0));0<k.nestedCues.length&&n&&xn(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(q,p){return q.startTime!=
551
- p.startTime?q.startTime-p.startTime:q.endTime-p.endTime});h=t(h);for(d=h.next();!d.done;d=h.next())d=a.i.get(d.value),d.sc?(d.sc.contains(c)&&d.sc.removeChild(c),c.appendChild(d.sc),d.sc.appendChild(d.Ne)):c.appendChild(d.Ne)}}function vn(a,b){if(a.g){var c=a.A.currentTime;if(!a.m||(void 0===b?0:b)){b=t(a.B.values());for(var d=b.next();!d.done;d=b.next())tn(d.value);tn(a.g);a.i.clear();a.B.clear()}a.m&&xn(a,a.h,a.g,c,[])}}
543
+ (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 pn(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=pn.prototype;q.configure=function(){};q.remove=function(a,b){if(!this.g)return!1;qn(this.g,function(c){return c.startTime<b&&c.endTime>a});return!0};
544
+ q.append=function(a){var b=mn(a),c=[];a=this.g.cues?Array.from(this.g.cues):[];b=t(b);for(var d=b.next(),e={};!d.done;e={Hc:void 0},d=b.next())e.Hc=d.value,!a.some(function(f){return function(g){return g.startTime==f.Hc.startTime&&g.endTime==f.Hc.endTime&&g.text==f.Hc.payload?!0:!1}}(e))&&e.Hc.payload&&(d=on(e.Hc))&&c.push(d);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):
545
+ c.indexOf(f)-c.indexOf(g)});a=t(a);for(b=a.next();!b.done;b=a.next())this.g.addCue(b.value)};q.destroy=function(){this.g&&(qn(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"};
546
+ function qn(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}S("shaka.text.SimpleTextDisplayer",pn);pn.prototype.setTextVisibility=pn.prototype.setTextVisibility;pn.prototype.isTextVisible=pn.prototype.isTextVisible;pn.prototype.destroy=pn.prototype.destroy;pn.prototype.append=pn.prototype.append;pn.prototype.remove=pn.prototype.remove;pn.prototype.configure=pn.prototype.configure;function rn(){}q=rn.prototype;q.configure=function(){};q.remove=function(){};q.append=function(){};q.destroy=function(){};q.isTextVisible=function(){return!1};q.setTextVisibility=function(){};S("shaka.text.StubTextDisplayer",rn);rn.prototype.setTextVisibility=rn.prototype.setTextVisibility;rn.prototype.isTextVisible=rn.prototype.isTextVisible;rn.prototype.destroy=rn.prototype.destroy;rn.prototype.append=rn.prototype.append;rn.prototype.remove=rn.prototype.remove;rn.prototype.configure=rn.prototype.configure;function sn(){}function tn(a){for(;a.firstChild;)a.removeChild(a.firstChild)}S("shaka.util.Dom",sn);sn.removeAllChildren=tn;function un(a,b,c){var d=this;this.m=!1;this.h=[];this.A=a;this.s=b;this.l=null;this.g=document.createElement("div");this.g.classList.add("shaka-text-container");this.g.style.textAlign="center";this.g.style.display="flex";this.g.style.flexDirection="column";this.g.style.alignItems="center";this.g.style.justifyContent="flex-end";this.s.appendChild(this.g);c&&c.captionsUpdatePeriod||qb("UITextDisplayer w/ config","Please migrate to initializing UITextDisplayer with a config.");this.C=(new Sc(function(){d.A.paused||
547
+ vn(d)})).Ra(c&&c.captionsUpdatePeriod?c.captionsUpdatePeriod:.25);this.i=new Map;this.j=new gb;this.j.D(document,"fullscreenchange",function(){vn(d,!0)});this.j.D(this.A,"seeking",function(){vn(d,!0)});this.j.D(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(){vn(d,!0)}),this.o.observe(this.g));this.B=new Map}q=un.prototype;q.configure=function(a){this.C&&this.C.Ra(a.captionsUpdatePeriod)};
548
+ q.append=function(a){var b=[].concat(x(this.h));a=t(nn(a));for(var c=a.next(),d={};!c.done;d={Me:void 0},c=a.next())d.Me=c.value,b.some(function(e){return function(f){return bc(f,e.Me)}}(d))||this.h.push(d.Me);vn(this)};q.destroy=function(){if(!this.g)return Promise.resolve();this.s.removeChild(this.g);this.g=null;this.m=!1;this.h=[];this.C&&this.C.stop();this.i.clear();this.j&&(this.j.release(),this.j=null);this.o&&(this.o.disconnect(),this.o=null);return Promise.resolve()};
549
+ 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});vn(this,c>this.h.length);return!0};q.isTextVisible=function(){return this.m};q.setTextVisibility=function(a){this.m=a};function wn(a,b){for(;null!=b;){if(b==a.g)return!0;b=b.parentElement}return!1}
550
+ function xn(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.qh:null;l&&(g.push(l.Ne),l.sc&&g.push(l.sc),m||(f=!0,a.i.delete(k),l=null));m&&(h.push(k),l?wn(a,n)||(f=!0):(yn(a,k,e),l=a.i.get(k),n=l.qh,f=!0));0<k.nestedCues.length&&n&&xn(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!=
551
+ r.startTime?p.startTime-r.startTime:p.endTime-r.endTime});h=t(h);for(d=h.next();!d.done;d=h.next())d=a.i.get(d.value),d.sc?(d.sc.contains(c)&&d.sc.removeChild(c),c.appendChild(d.sc),d.sc.appendChild(d.Ne)):c.appendChild(d.Ne)}}function vn(a,b){if(a.g){var c=a.A.currentTime;if(!a.m||(void 0===b?0:b)){b=t(a.B.values());for(var d=b.next();!d.done;d=b.next())tn(d.value);tn(a.g);a.i.clear();a.B.clear()}a.m&&xn(a,a.h,a.g,c,[])}}
552
552
  function yn(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=document.createElement(e);"br"!=e&&zn(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==Kb?"%":"px")+"-"+g.viewportAnchorX+"x"+g.viewportAnchorY+(g.viewportAnchorUnits==Kb?"%":"px");if(a.B.has(c))c=a.B.get(c);else{e=document.createElement("span");var k=g.heightUnits==Kb?"%":"px",l=g.widthUnits==
553
- Kb?"%":"px",m=g.viewportAnchorUnits==Kb?"%":"px";e.id="shaka-text-region---"+c;e.classList.add("shaka-text-region");e.style.position="absolute";var n=g.height,q=g.width;2===g.heightUnits&&(n=5.33*g.height,k="%");2===g.widthUnits&&(q=g.width*h,l="%");e.style.height=n+k;e.style.width=q+l;2===g.viewportAnchorUnits?(h=g.viewportAnchorY/75*100,k=g.viewportAnchorX/(a.l===4/3?160:210)*100,h-=g.regionAnchorY*n/100,k-=g.regionAnchorX*q/100,e.style.top=h+"%",e.style.left=k+"%"):(e.style.top=g.viewportAnchorY-
554
- g.regionAnchorY*n/100+m,e.style.left=g.viewportAnchorX-g.regionAnchorX*q/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=
553
+ Kb?"%":"px",m=g.viewportAnchorUnits==Kb?"%":"px";e.id="shaka-text-region---"+c;e.classList.add("shaka-text-region");e.style.position="absolute";var n=g.height,p=g.width;2===g.heightUnits&&(n=5.33*g.height,k="%");2===g.widthUnits&&(p=g.width*h,l="%");e.style.height=n+k;e.style.width=p+l;2===g.viewportAnchorUnits?(h=g.viewportAnchorY/75*100,k=g.viewportAnchorX/(a.l===4/3?160:210)*100,h-=g.regionAnchorY*n/100,k-=g.regionAnchorX*p/100,e.style.top=h+"%",e.style.left=k+"%"):(e.style.top=g.viewportAnchorY-
554
+ g.regionAnchorY*n/100+m,e.style.left=g.viewportAnchorX-g.regionAnchorX*p/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=
555
555
  "before"==b.displayAlign?"flex-start":"center"==b.displayAlign?"center":"flex-end";a.B.set(c,e);c=e}}e=f;d&&(e=document.createElement("span"),e.classList.add("shaka-text-wrapper"),e.style.backgroundColor=b.backgroundColor,e.style.lineHeight="normal",f.appendChild(e));a.i.set(b,{Ne:f,qh:e,sc:c})}
556
556
  function An(a){var b=a.direction,c=a.positionAlign;a=a.textAlign;return c!==Sb?c:"left"===a||"start"===a&&b===Ub||"end"===a&&"rtl"===b?"line-left":"right"===a||"start"===a&&"rtl"===b||"end"===a&&b===Ub?"line-right":"center"}
557
557
  function zn(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=Bn(c.linePadding,c,a.s);f.paddingRight=Bn(c.linePadding,c,a.s);f.textCombineUpright=c.textCombineUpright;f.textShadow=c.textShadow;if(c.backgroundImage)f.backgroundImage=
558
- "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=document.createElement("span"),b.appendChild(l);c.border&&(l.style.border=c.border);!e&&((b=Cn(d,function(m){return m.backgroundColor}))?l.style.backgroundColor=b:k&&(l.style.backgroundColor="rgba(0, 0, 0, 0.8)"),b=Cn(d,function(m){return m.fontFamily}))&&
559
- (l.style.fontFamily=b);k&&(l.textContent=k)}if(h&&!d[d.length-1].isContainer)f.display="inline";else{f.display="flex";f.flexDirection="column";f.alignItems="center";if("left"==c.textAlign||"start"==c.textAlign)f.width="100%",f.alignItems="start";else if("right"==c.textAlign||"end"==c.textAlign)f.width="100%",f.alignItems="end";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();
560
- f.fontStyle=c.fontStyle;f.letterSpacing=c.letterSpacing;f.fontSize=Bn(c.fontSize,c,a.s);d=c.line;null!=d&&(g=c.lineInterpretation,g==Wb&&(g=1,h=16,a.l&&1>a.l&&(h=32),d=0>d?100+d/h*100:d/h*100),1==g&&(f.position="absolute",c.writingMode==Vb?(f.width="100%",c.lineAlign==Xb?f.top=d+"%":"end"==c.lineAlign&&(f.bottom=100-d+"%")):"vertical-lr"==c.writingMode?(f.height="100%",c.lineAlign==Xb?f.left=d+"%":"end"==c.lineAlign&&(f.right=100-d+"%")):(f.height="100%",c.lineAlign==Xb?f.right=d+"%":"end"==c.lineAlign&&
561
- (f.left=100-d+"%"))));f.lineHeight=c.lineHeight;a=An(c);"line-left"==a?(f.cssFloat="left",null!==c.position&&(f.position="absolute",c.writingMode==Vb?(f.left=c.position+"%",f.width="auto"):f.top=c.position+"%")):"line-right"==a?(f.cssFloat="right",null!==c.position&&(f.position="absolute",c.writingMode==Vb?(f.right=100-c.position+"%",f.width="auto"):f.bottom=c.position+"%")):null!==c.position&&50!=c.position&&(f.position="absolute",c.writingMode==Vb?(f.left=c.position+"%",f.width="auto"):f.top=c.position+
562
- "%");f.textAlign=c.textAlign;f.textDecoration=c.textDecoration.join(" ");f.writingMode=c.writingMode;"writingMode"in document.documentElement.style&&f.writingMode==c.writingMode||(f.webkitWritingMode=c.writingMode);c.size&&(c.writingMode==Vb?f.width=c.size+"%":f.height=c.size+"%")}
558
+ "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=document.createElement("span"),b.appendChild(l);c.border&&(l.style.border=c.border);e||((b=Cn(d,function(m){return m.backgroundColor}))?l.style.backgroundColor=b:k&&(l.style.backgroundColor="rgba(0, 0, 0, 0.8)"));k&&(l.textContent=k)}if(h&&!d[d.length-
559
+ 1].isContainer)f.display="inline";else{f.display="flex";f.flexDirection="column";f.alignItems="center";if("left"==c.textAlign||"start"==c.textAlign)f.width="100%",f.alignItems="start";else if("right"==c.textAlign||"end"==c.textAlign)f.width="100%",f.alignItems="end";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;
560
+ f.fontSize=Bn(c.fontSize,c,a.s);d=c.line;null!=d&&(g=c.lineInterpretation,g==Wb&&(g=1,h=16,a.l&&1>a.l&&(h=32),d=0>d?100+d/h*100:d/h*100),1==g&&(f.position="absolute",c.writingMode==Vb?(f.width="100%",c.lineAlign==Xb?f.top=d+"%":"end"==c.lineAlign&&(f.bottom=100-d+"%")):"vertical-lr"==c.writingMode?(f.height="100%",c.lineAlign==Xb?f.left=d+"%":"end"==c.lineAlign&&(f.right=100-d+"%")):(f.height="100%",c.lineAlign==Xb?f.right=d+"%":"end"==c.lineAlign&&(f.left=100-d+"%"))));f.lineHeight=c.lineHeight;
561
+ a=An(c);"line-left"==a?(f.cssFloat="left",null!==c.position&&(f.position="absolute",c.writingMode==Vb?(f.left=c.position+"%",f.width="auto"):f.top=c.position+"%")):"line-right"==a?(f.cssFloat="right",null!==c.position&&(f.position="absolute",c.writingMode==Vb?(f.right=100-c.position+"%",f.width="auto"):f.bottom=c.position+"%")):null!==c.position&&50!=c.position&&(f.position="absolute",c.writingMode==Vb?(f.left=c.position+"%",f.width="auto"):f.top=c.position+"%");f.textAlign=c.textAlign;f.textDecoration=
562
+ c.textDecoration.join(" ");f.writingMode=c.writingMode;"writingMode"in document.documentElement.style&&f.writingMode==c.writingMode||(f.webkitWritingMode=c.writingMode);c.size&&(c.writingMode==Vb?f.width=c.size+"%":f.height=c.size+"%")}
563
563
  function Bn(a,b,c){var d=(d=(new RegExp(/(\d*\.?\d+)([a-z]+|%+)/)).exec(a))?{value:Number(d[1]),unit:d[2]}:null;if(!d)return a;var e=d.value;switch(d.unit){case "%":return e/100*c.clientHeight/b.cellResolution.rows+"px";case "c":return c.clientHeight*e/b.cellResolution.rows+"px";default:return a}}function Cn(a,b){for(var c=a.length-1;0<=c;c--){var d=b(a[c]);if(d||0===d)return d}return null}S("shaka.text.UITextDisplayer",un);un.prototype.setTextVisibility=un.prototype.setTextVisibility;
564
564
  un.prototype.isTextVisible=un.prototype.isTextVisible;un.prototype.remove=un.prototype.remove;un.prototype.destroy=un.prototype.destroy;un.prototype.append=un.prototype.append;un.prototype.configure=un.prototype.configure;function Dn(a,b){function c(f){for(var g=f,h=t(b),k=h.next();!k.done;k=h.next())k=k.value,k.end&&k.start<f&&(g+=k.end-k.start);f=Math.floor(g/3600);h=Math.floor(g/60%60);k=Math.floor(g%60);g=Math.floor(1E3*g%1E3);return(10>f?"0":"")+f+":"+(10>h?"0":"")+h+":"+(10>k?"0":"")+k+"."+(100>g?10>g?"00":"0":"")+g}var d=mn(a);a="WEBVTT\n\n";d=t(d);for(var e=d.next();!e.done;e=d.next())e=e.value,a+=c(e.startTime)+" --\x3e "+c(e.endTime)+function(f){var g=[];switch(f.textAlign){case "left":g.push("align:left");
565
565
  break;case "right":g.push("align:right");break;case Tb:g.push("align:middle");break;case "start":g.push("align:start");break;case "end":g.push("align:end")}switch(f.writingMode){case "vertical-lr":g.push("vertical:lr");break;case "vertical-rl":g.push("vertical:rl")}return g.length?" "+g.join(" "):""}(e)+"\n",a+=e.payload+"\n\n";return a}S("shaka.text.WebVttGenerator",function(){});function En(a,b){this.h=a;this.g=b;this.m=void 0;this.i=!1;this.l=!0;this.j=!1}En.prototype.configure=function(a){this.g=a};function Fn(a){a.i=!1;a.l=!0;a.j=!1}
@@ -570,77 +570,77 @@ function Rn(a){if(0===a.type)return Sn;if(a=a.stream){var b=a.type;if("video"==b
570
570
  function Wn(a,b){b=a.h.wb()[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 Xn(a,b){var c=a.h.kc();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 On:return a.videoBandwidth||NaN;case In:return a.audioBandwidth||NaN;default:return a.bandwidth}}
571
571
  function Ln(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"===
572
572
  l?h:"symbol"===l?h+"="+k.description:h+"="+k;e.push(m)}}return e.join(",")}function Qn(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=Ln(e[a]))&&(c["CMCD-"+d[a]]=f);return c}
573
- function Mn(a,b){if(!b||a.includes("offline:"))return a;a=new tc(a);a.g.set("CMCD",b);return a.toString()}var Kn="m",In="a",On="v",Jn="av",Sn="i",Un="c",Tn="tt";S("shaka.util.CmcdManager.StreamingFormat",{DASH:"d",HLS:"h",Kj:"s",OTHER:"o"});function Yn(a){this.h=a;this.g=null}r=Yn.prototype;r.configure=function(a){this.h=a};r.zg=function(){return this.h.enabled&&this.h.applyMaximumSuggestedBitrate&&this.g&&this.g.has(Zn)?1E3*this.g.get(Zn):null};r.xg=function(){return this.h.enabled&&this.g&&this.g.has($n)?1E3*this.g.get($n):null};r.Yh=function(){return this.h.enabled&&this.g&&this.g.has(ao)?this.g.get(ao):null};r.Zh=function(){return this.h.enabled&&this.g&&this.g.has(bo)?this.g.get(bo):null};
574
- r.getBandwidthEstimate=function(a){var b=this.xg();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}S("shaka.util.CmsdManager",Yn);Yn.prototype.getBandwidthEstimate=Yn.prototype.getBandwidthEstimate;Yn.prototype.getRoundTripTime=Yn.prototype.Zh;Yn.prototype.getResponseDelay=Yn.prototype.Yh;Yn.prototype.getEstimatedThroughput=Yn.prototype.xg;
575
- Yn.prototype.getMaxBitrate=Yn.prototype.zg;var $n="etp",Zn="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?F(c,new Promise(function(d){return a.h.push(d)}),2):c.u(2);a.g=b;H(c)})}eo.prototype.release=function(){0<this.h.length?this.h.shift()():this.g=null};function Y(a,b){lg.call(this);var c=this;this.l=go;this.ce=this.h=null;this.la=!1;this.pe=new gb;this.fd=new gb;this.m=new gb;this.Fa=new gb;this.ub=new gb;this.C=this.G=this.B=this.H=null;this.se=0;this.Y=new eo;this.qa=this.ag=this.da=this.i=this.ab=this.F=this.j=this.Yc=this.K=this.eg=this.ea=this.N=this.cd=this.L=this.ge=this.I=this.Fb=null;this.Ea=!1;this.xa=this.o=null;this.cg=1E9;this.od=[];this.T=NaN;this.g=ho(this);this.O=null;this.ye=-1;this.Da=null;this.fa={width:Infinity,height:Infinity};
573
+ function Mn(a,b){if(!b||a.includes("offline:"))return a;a=new tc(a);a.g.set("CMCD",b);return a.toString()}var Kn="m",In="a",On="v",Jn="av",Sn="i",Un="c",Tn="tt";S("shaka.util.CmcdManager.StreamingFormat",{DASH:"d",HLS:"h",Kj:"s",OTHER:"o"});function Yn(a){this.h=a;this.g=null}q=Yn.prototype;q.configure=function(a){this.h=a};q.zg=function(){return this.h.enabled&&this.h.applyMaximumSuggestedBitrate&&this.g&&this.g.has(Zn)?1E3*this.g.get(Zn):null};q.xg=function(){return this.h.enabled&&this.g&&this.g.has($n)?1E3*this.g.get($n):null};q.Yh=function(){return this.h.enabled&&this.g&&this.g.has(ao)?this.g.get(ao):null};q.Zh=function(){return this.h.enabled&&this.g&&this.g.has(bo)?this.g.get(bo):null};
574
+ q.getBandwidthEstimate=function(a){var b=this.xg();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}S("shaka.util.CmsdManager",Yn);Yn.prototype.getBandwidthEstimate=Yn.prototype.getBandwidthEstimate;Yn.prototype.getRoundTripTime=Yn.prototype.Zh;Yn.prototype.getResponseDelay=Yn.prototype.Yh;Yn.prototype.getEstimatedThroughput=Yn.prototype.xg;
575
+ Yn.prototype.getMaxBitrate=Yn.prototype.zg;var $n="etp",Zn="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?F(c,new Promise(function(d){return a.h.push(d)}),2):c.u(2);a.g=b;H(c)})}eo.prototype.release=function(){0<this.h.length?this.h.shift()():this.g=null};function Y(a,b){lg.call(this);var c=this;this.l=go;this.ce=this.h=null;this.la=!1;this.pe=new gb;this.gd=new gb;this.m=new gb;this.Fa=new gb;this.ub=new gb;this.C=this.G=this.B=this.H=null;this.se=0;this.Y=new eo;this.qa=this.ag=this.da=this.i=this.ab=this.F=this.j=this.Zc=this.K=this.eg=this.ea=this.N=this.dd=this.L=this.ge=this.I=this.Fb=null;this.Ea=!1;this.xa=this.o=null;this.cg=1E9;this.od=[];this.T=NaN;this.g=ho(this);this.O=null;this.ye=-1;this.Da=null;this.fa={width:Infinity,height:Infinity};
576
576
  this.$d=new qi(this.g,this.fa,null);this.je=[];this.s=null;this.za=new Lf(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.Db=this.g.preferredTextLanguage;this.nd=this.g.preferredTextRole;this.md=this.g.preferForcedSubs;this.kd=[];b&&
577
577
  b(this);this.N=io(this);this.ea=new Yn(this.g.cmsd);this.H=jo(this);this.H.Pf(this.g.streaming.forceHTTP);this.H.Qf(this.g.streaming.forceHTTPS);this.Gb=this.ba=this.A=null;this.Be=!1;this.dg=new Sc(function(){return O(function(d){if(1==d.g)return c.ba?F(d,c.Rb(c.Gb,!0),3):d.u(0);if(4!=d.g)return F(d,c.load(c.ba),4);c.Be?c.Gb.pause():c.Gb.play();c.ba=null;c.Be=!1;H(d)})});ko&&(this.A=ko(),this.A.configure(this.g.ads),this.ub.D(this.A,"ad-content-pause-requested",function(d){var e;return O(function(f){if(1==
578
578
  f.g){c.dg.stop();if(c.ba)return f.u(0);c.Gb=c.h;c.Be=c.h.ended;e=d.saveLivePosition||!1;return F(f,c.qg(!0,e),3)}c.ba=f.h;H(f)})}),this.ub.D(this.A,"ad-content-resume-requested",function(d){d=d.offset||0;if(c.ba){var e=c.ba;e.A&&d&&(e.A+=d)}c.dg.Z(.1)}),this.ub.D(this.A,"ad-content-attach-requested",function(){return O(function(d){return c.h||!c.Gb?d.u(0):F(d,c.Rb(c.Gb,!0),0)})}));this.pe.D(window,"online",function(){lo(c);c.If()});this.ie=new Sc(function(){for(var d=Date.now()/1E3,e=!1,f=!0,g=t(c.i.variants),
579
579
  h=g.next();!h.done;h=g.next())h=h.value,0<h.disabledUntilTime&&h.disabledUntilTime<=d&&(h.disabledUntilTime=0,e=!0),0<h.disabledUntilTime&&(f=!1);f&&c.ie.stop();e&&mo(c,!1,void 0,!1,!1)});this.ra=null;a&&(qb("Player w/ mediaElement","Please migrate from initializing Player with a mediaElement; use the attach method instead."),this.Rb(a,!0))}na(Y,lg);function no(a){null!=a.K&&(Ij(a.K),a.K.release(),a.K=null)}
580
- function oo(a,b){b.lcevc.enabled?(no(a),null==a.K&&(a.K=new Hj(a.h,a.eg,b.lcevc),a.G&&(a.G.Y=a.K))):no(a)}function po(a,b){return new U(a,b)}r=Y.prototype;
581
- r.destroy=function(){var a=this,b;return O(function(c){switch(c.g){case 1:if(a.l==qo)return c.return();no(a);b=a.detach();a.l=qo;return F(c,b,2);case 2:return F(c,a.Pe(),3);case 3:a.pe&&(a.pe.release(),a.pe=null);a.fd&&(a.fd.release(),a.fd=null);a.m&&(a.m.release(),a.m=null);a.Fa&&(a.Fa.release(),a.Fa=null);a.ub&&(a.ub.release(),a.ub=null);a.xa=null;a.g=null;a.s=null;a.ce=null;a.N=null;a.ea=null;if(!a.H){c.u(4);break}return F(c,a.H.destroy(),5);case 5:a.H=null;case 4:a.o&&(a.o.release(),a.o=null),
580
+ function oo(a,b){b.lcevc.enabled?(no(a),null==a.K&&(a.K=new Hj(a.h,a.eg,b.lcevc),a.G&&(a.G.Y=a.K))):no(a)}function po(a,b){return new U(a,b)}q=Y.prototype;
581
+ q.destroy=function(){var a=this,b;return O(function(c){switch(c.g){case 1:if(a.l==qo)return c.return();no(a);b=a.detach();a.l=qo;return F(c,b,2);case 2:return F(c,a.Pe(),3);case 3:a.pe&&(a.pe.release(),a.pe=null);a.gd&&(a.gd.release(),a.gd=null);a.m&&(a.m.release(),a.m=null);a.Fa&&(a.Fa.release(),a.Fa=null);a.ub&&(a.ub.release(),a.ub=null);a.xa=null;a.g=null;a.s=null;a.ce=null;a.N=null;a.ea=null;if(!a.H){c.u(4);break}return F(c,a.H.destroy(),5);case 5:a.H=null;case 4:a.o&&(a.o.release(),a.o=null),
582
582
  lg.prototype.release.call(a),H(c)}})};function ro(a,b){a.dispatchEvent(po("onstatechange",(new Map).set("state",b)))}
583
- r.Rb=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 T(2,7,7E3);d=c.h&&c.h==a;if(!c.h||c.h==a){g.u(2);break}return F(g,c.detach(),2);case 2:return F(g,so(c,"attach"),4);case 4:if(g.h)return g.return();ra(g,5,6);d||(ro(c,"attach"),e=function(){var h=to(c,!1);h&&uo(c,h)},c.fd.D(a,"error",e),c.h=a);if(!b||!Tc()||c.G){g.u(6);break}return F(g,vo(c),6);case 6:va(g);c.Y.release();wa(g,0);break;case 5:return f=ua(g),F(g,c.detach(),10);case 10:throw f;
584
- }})};r.zh=function(a){this.eg=a};r.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 T(2,7,7E3);return F(c,b.cc(!1,a),2)}if(3!=c.g)return F(c,so(b,"detach"),3);if(c.h)return c.return();try{b.h&&(b.fd.Qa(),b.h=null),ro(b,"detach"),b.A&&!a&&b.A.release()}finally{b.Y.release()}H(c)})};function so(a,b){var c;return O(function(d){return 1==d.g?(c=++a.se,F(d,fo(a.Y,b),2)):c!=a.se?(a.Y.release(),d.return(!0)):d.return(!1)})}
585
- r.cc=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,q;return O(function(p){switch(p.g){case 1:return c.l!=qo&&(c.l=go),F(p,so(c,"unload"),2);case 2:if(p.h)return p.return();sa(p,3);c.Ea=!1;ro(c,"unload");a&&!Tc()&&(a=!1);no(c);d=c.kd.map(function(w){return w()});c.kd=[];return F(p,Promise.all(d),5);case 5:c.dispatchEvent(po("unloading"));c.cd&&(c.cd.release(),c.cd=null);c.h&&(c.m.Qa(),c.Fa.Qa());c.ie.stop();c.Fb&&(c.Fb.release(),c.Fb=null);c.ge&&(c.ge.stop(),c.ge=null);
586
- if(!c.F){p.u(6);break}return F(p,c.F.stop(),7);case 7:c.F=null,c.ab=null;case 6:if(!c.o){p.u(8);break}return F(p,c.o.stop(),8);case 8:if(!c.j){p.u(10);break}return F(p,c.j.destroy(),11);case 11:c.j=null;case 10:c.I&&(c.I.release(),c.I=null);c.C&&(c.C.release(),c.C=null);if(!rd("webkit")||!c.B){p.u(12);break}return F(p,c.B.destroy(),13);case 13:c.B=null;case 12:if(!c.G){p.u(14);break}return F(p,c.G.destroy(),15);case 15:c.G=null;case 14:if(c.A&&!b)c.A.onAssetUnload();c.ba&&!b&&(c.ba.destroy(),c.ba=
587
- null);b||c.dg.stop();c.N&&Fn(c.N);c.ea&&(c.ea.g=null);c.h&&tn(c.h);if(!c.h||!c.h.src){p.u(16);break}return F(p,new Promise(function(w){return(new Sc(w)).Z(.1)}),17);case 17:c.h.removeAttribute("src"),c.h.load();case 16:if(!c.B){p.u(18);break}return F(p,c.B.destroy(),19);case 19:c.B=null;case 18:c.ra&&c.da!=c.ra.Ec()&&(c.ra.s||c.ra.destroy(),c.ra=null);c.da=null;c.ag=null;c.L=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=
588
- h.next())(l=k.value)&&l.segmentIndex&&l.segmentIndex.release();m=t(c.i.textStreams);for(n=m.next();!n.done;n=m.next())q=n.value,q.segmentIndex&&q.segmentIndex.release()}c.g.streaming.clearDecodingCache&&(ef={},Qc.clear());c.i=null;c.s=new al;c.bg=null;c.Da=null;c.O=null;c.ye=-1;c.od=[];c.T=NaN;wo(c);case 3:va(p);c.Y.release();wa(p,4);break;case 4:if(a&&Tc()&&!c.G&&c.h)return F(p,vo(c),0);p.u(0)}})};r.ej=function(a){this.qa=a};
589
- r.load=function(a,b,c){b=void 0===b?null:b;var d=this,e,f,g,h,k,l,m,n,q,p,w,u,v;return O(function(A){switch(A.g){case 1:if(d.l==qo)throw new T(2,7,7E3);e=null;f="";a instanceof Am?(e=a,f=e.Ec()||""):f=a||"";return F(A,fo(d.Y,"load"),2);case 2:d.Y.release();if(!d.h)throw new T(2,7,7002);if(!d.da){A.u(3);break}d.da=f;return F(A,d.cc(!1),3);case 3:g=++d.se;h=function(){return O(function(z){if(1==z.g)return d.se==g?z.u(0):e?F(z,e.destroy(),3):z.u(3);throw new T(2,7,7E3);})};k=function(z,D){return O(function(y){switch(y.g){case 1:return sa(y,
583
+ q.Rb=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 T(2,7,7E3);d=c.h&&c.h==a;if(!c.h||c.h==a){g.u(2);break}return F(g,c.detach(),2);case 2:return F(g,so(c,"attach"),4);case 4:if(g.h)return g.return();ra(g,5,6);d||(ro(c,"attach"),e=function(){var h=to(c,!1);h&&uo(c,h)},c.gd.D(a,"error",e),c.h=a);if(!b||!Tc()||c.G){g.u(6);break}return F(g,vo(c),6);case 6:va(g);c.Y.release();wa(g,0);break;case 5:return f=ua(g),F(g,c.detach(),10);case 10:throw f;
584
+ }})};q.zh=function(a){this.eg=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 T(2,7,7E3);return F(c,b.cc(!1,a),2)}if(3!=c.g)return F(c,so(b,"detach"),3);if(c.h)return c.return();try{b.h&&(b.gd.Qa(),b.h=null),ro(b,"detach"),b.A&&!a&&b.A.release()}finally{b.Y.release()}H(c)})};function so(a,b){var c;return O(function(d){return 1==d.g?(c=++a.se,F(d,fo(a.Y,b),2)):c!=a.se?(a.Y.release(),d.return(!0)):d.return(!1)})}
585
+ q.cc=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,p;return O(function(r){switch(r.g){case 1:return c.l!=qo&&(c.l=go),F(r,so(c,"unload"),2);case 2:if(r.h)return r.return();sa(r,3);c.Ea=!1;ro(c,"unload");a&&!Tc()&&(a=!1);no(c);d=c.kd.map(function(u){return u()});c.kd=[];return F(r,Promise.all(d),5);case 5:c.dispatchEvent(po("unloading"));c.dd&&(c.dd.release(),c.dd=null);c.h&&(c.m.Qa(),c.Fa.Qa());c.ie.stop();c.Fb&&(c.Fb.release(),c.Fb=null);c.ge&&(c.ge.stop(),c.ge=null);
586
+ if(!c.F){r.u(6);break}return F(r,c.F.stop(),7);case 7:c.F=null,c.ab=null;case 6:if(!c.o){r.u(8);break}return F(r,c.o.stop(),8);case 8:if(!c.j){r.u(10);break}return F(r,c.j.destroy(),11);case 11:c.j=null;case 10:c.I&&(c.I.release(),c.I=null);c.C&&(c.C.release(),c.C=null);if(!rd("webkit")||!c.B){r.u(12);break}return F(r,c.B.destroy(),13);case 13:c.B=null;case 12:if(!c.G){r.u(14);break}return F(r,c.G.destroy(),15);case 15:c.G=null;case 14:if(c.A&&!b)c.A.onAssetUnload();c.ba&&!b&&(c.ba.destroy(),c.ba=
587
+ null);b||c.dg.stop();c.N&&Fn(c.N);c.ea&&(c.ea.g=null);c.h&&tn(c.h);if(!c.h||!c.h.src){r.u(16);break}return F(r,new Promise(function(u){return(new Sc(u)).Z(.1)}),17);case 17:c.h.removeAttribute("src"),c.h.load();case 16:if(!c.B){r.u(18);break}return F(r,c.B.destroy(),19);case 19:c.B=null;case 18:c.ra&&c.da!=c.ra.Ec()&&(c.ra.s||c.ra.destroy(),c.ra=null);c.da=null;c.ag=null;c.L=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=
588
+ h.next())(l=k.value)&&l.segmentIndex&&l.segmentIndex.release();m=t(c.i.textStreams);for(n=m.next();!n.done;n=m.next())p=n.value,p.segmentIndex&&p.segmentIndex.release()}c.g.streaming.clearDecodingCache&&(ef={},Qc.clear());c.i=null;c.s=new al;c.bg=null;c.Da=null;c.O=null;c.ye=-1;c.od=[];c.T=NaN;wo(c);case 3:va(r);c.Y.release();wa(r,4);break;case 4:if(a&&Tc()&&!c.G&&c.h)return F(r,vo(c),0);r.u(0)}})};q.ej=function(a){this.qa=a};
589
+ 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 T(2,7,7E3);e=null;f="";a instanceof Am?(e=a,f=e.Ec()||""):f=a||"";return F(A,fo(d.Y,"load"),2);case 2:d.Y.release();if(!d.h)throw new T(2,7,7002);if(!d.da){A.u(3);break}d.da=f;return F(A,d.cc(!1),3);case 3:g=++d.se;h=function(){return O(function(z){if(1==z.g)return d.se==g?z.u(0):e?F(z,e.destroy(),3):z.u(3);throw new T(2,7,7E3);})};k=function(z,D){return O(function(y){switch(y.g){case 1:return sa(y,
590
590
  2),F(y,fo(d.Y,D),4);case 4:return F(y,h(),5);case 5:return F(y,z(),6);case 6:return F(y,h(),7);case 7:e&&d.g&&(e.g=d.g);case 2:va(y),d.Y.release(),wa(y,0)}})};ra(A,5,6);null==b&&e&&(b=e.getStartTime());d.qa=b;d.Ea=!1;d.dispatchEvent(po("loading"));if(e){c=e.T;A.u(8);break}if(c){A.u(8);break}return F(A,k(function(){return O(function(z){if(1==z.g)return F(z,xo(d,f),2);c=z.h;H(z)})},"guessMimeType_"),8);case 8:l=!!e;if(e){Dm(e,d);d.s=e.getStats();A.u(11);break}return F(A,yo(d,f,b,c,!0),12);case 12:(e=
591
591
  A.h)?(Dm(e,d),d.s=e.getStats(),e.start(),e.m.catch(function(){})):d.s=new al;case 11:m=!e;n=Date.now()/1E3;d.s=e?e.getStats():new al;d.da=f;d.ag=c||null;if(m)return F(A,k(function(){return O(function(z){return F(z,zo(d,c),0)})},"initializeSrcEqualsDrmInner_"),20);if(d.G){A.u(15);break}return F(A,k(function(){return O(function(z){return F(z,vo(d),0)})},"initializeMediaSourceEngineInner_"),15);case 15:return F(A,k(function(){return O(function(z){return F(z,e.m,0)})},"waitForFinish"),17);case 17:d.g=
592
- e.getConfiguration();d.$d=e.C;d.ab=e.F;d.F=Fm(e);d.F&&d.F.setMediaElement&&d.h&&d.F.setMediaElement(d.h);d.cd=Gm(e);d.Yc=e.za;d.i=e.ff();if(q=e.o)d.za=q;l&&d.h&&"AUDIO"===d.h.nodeName&&(Ao(d),d.configure("manifest.disableVideo",!0));d.B=Hm(e);return F(A,k(function(){return O(function(z){return F(z,d.B.Rb(d.h),0)})},"drmEngine_.attach"),18);case 18:return!(p=e.B)||d.xa&&d.xa==p||(d.o=Em(e),d.xa=e.B,"function"!=typeof d.o.setMediaElement&&(qb("AbrManager w/o setMediaElement","Please use an AbrManager with setMediaElement function."),
593
- d.o.setMediaElement=function(){}),"function"!=typeof d.o.setCmsdManager&&(qb("AbrManager w/o setCmsdManager","Please use an AbrManager with setCmsdManager function."),d.o.setCmsdManager=function(){}),"function"!=typeof d.o.trySuggestStreams&&(qb("AbrManager w/o trySuggestStreams","Please use an AbrManager with trySuggestStreams function."),d.o.trySuggestStreams=function(){})),w=Im(e),u=e.fa,F(A,k(function(){return O(function(z){return F(z,Bo(d,n,u,w),0)})},"loadInner_"),19);case 19:Cm(e);A.u(14);
594
- break;case 20:return F(A,k(function(){return O(function(z){return F(z,Co(d,n,c),0)})},"srcEqualsInner_"),14);case 14:d.dispatchEvent(po("loaded"));case 6:va(A);if(!e){A.u(22);break}return F(A,e.destroy(),22);case 22:d.ra=null;wa(A,0);break;case 5:v=ua(A);if(!v||7E3==v.code){A.u(24);break}return F(A,d.cc(!1),24);case 24:throw v;}})};
595
- function Ao(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})}r.aj=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?F(e,Do(c),2):3!=e.g?(d=e.h,F(e,c.cc(a,b),3)):e.return(d)})};
596
- r.qg=function(a,b){a=void 0===a?!1:a;b=void 0===b?!1:b;var c=this,d;return O(function(e){return 1==e.g?F(e,Do(c,b),2):3!=e.g?(d=e.h,F(e,c.detach(a),3)):e.return(d)})};
592
+ e.getConfiguration();d.$d=e.C;d.ab=e.F;d.F=Fm(e);d.F&&d.F.setMediaElement&&d.h&&d.F.setMediaElement(d.h);d.dd=Gm(e);d.Zc=e.za;d.i=e.ff();if(p=e.o)d.za=p;l&&d.h&&"AUDIO"===d.h.nodeName&&(Ao(d),d.configure("manifest.disableVideo",!0));d.B=Hm(e);return F(A,k(function(){return O(function(z){return F(z,d.B.Rb(d.h),0)})},"drmEngine_.attach"),18);case 18:return!(r=e.B)||d.xa&&d.xa==r||(d.o=Em(e),d.xa=e.B,"function"!=typeof d.o.setMediaElement&&(qb("AbrManager w/o setMediaElement","Please use an AbrManager with setMediaElement function."),
593
+ d.o.setMediaElement=function(){}),"function"!=typeof d.o.setCmsdManager&&(qb("AbrManager w/o setCmsdManager","Please use an AbrManager with setCmsdManager function."),d.o.setCmsdManager=function(){}),"function"!=typeof d.o.trySuggestStreams&&(qb("AbrManager w/o trySuggestStreams","Please use an AbrManager with trySuggestStreams function."),d.o.trySuggestStreams=function(){})),u=Im(e),v=e.fa,F(A,k(function(){return O(function(z){return F(z,Bo(d,n,v,u),0)})},"loadInner_"),19);case 19:Cm(e);A.u(14);
594
+ break;case 20:return F(A,k(function(){return O(function(z){return F(z,Co(d,n,c),0)})},"srcEqualsInner_"),14);case 14:d.dispatchEvent(po("loaded"));case 6:va(A);if(!e){A.u(22);break}return F(A,e.destroy(),22);case 22:d.ra=null;wa(A,0);break;case 5:w=ua(A);if(!w||7E3==w.code){A.u(24);break}return F(A,d.cc(!1),24);case 24:throw w;}})};
595
+ function Ao(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.aj=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?F(e,Do(c),2):3!=e.g?(d=e.h,F(e,c.cc(a,b),3)):e.return(d)})};
596
+ q.qg=function(a,b){a=void 0===a?!1:a;b=void 0===b?!1:b;var c=this,d;return O(function(e){return 1==e.g?F(e,Do(c,b),2):3!=e.g?(d=e.h,F(e,c.detach(a),3)):e.return(d)})};
597
597
  function Do(a,b){b=void 0===b?!1:b;var c,d;return O(function(e){if(1==e.g){c=null;if(!(a.i&&a.F&&a.ab&&a.da))return e.u(2);d=a.h.currentTime;a.V()&&!b&&(d=null);return F(e,Eo(a,a.da,d,a.ag,!0,!1,!1),3)}if(2!=e.g){c=e.h;a.je.push(c);a.F&&a.F.setMediaElement&&a.F.setMediaElement(null);var f=c,g=a.F,h=a.ab;f.h=a.i;f.j=g;f.F=h;f=c;g=a.xa;f.i=a.o;f.B=g;c.o=a.za;c.start();a.i=null;a.F=null;a.ab=null;a.o=null;a.xa=null}return e.return(c)})}
598
- r.preload=function(a,b,c){b=void 0===b?null:b;var d=this,e;return O(function(f){if(1==f.g)return F(f,yo(d,a,b,c),2);(e=f.h)?e.start():uo(d,new T(2,7,7005));return f.return(e)})};r.Pe=function(){var a=this,b,c,d,e;return O(function(f){b=[];c=t(a.je);for(d=c.next();!d.done;d=c.next())e=d.value,e.s||b.push(e.destroy());a.je=[];return F(f,Promise.all(b),0)})};
598
+ 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 F(f,yo(d,a,b,c),2);(e=f.h)?e.start():uo(d,new T(2,7,7005));return f.return(e)})};q.Pe=function(){var a=this,b,c,d,e;return O(function(f){b=[];c=t(a.je);for(d=c.next();!d.done;d=c.next())e=d.value,e.s||b.push(e.destroy());a.je=[];return F(f,Promise.all(b),0)})};
599
599
  function yo(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 d?l.u(2):F(l,xo(a,b),3);2!=l.g&&(d=l.h);if(f=Fo(a,d))return l.return(null);g=!1;h=!0;e&&(a.o&&a.xa==a.g.abrFactory&&(h=!1),a.h&&"AUDIO"===a.h.nodeName&&(g=!0));k=Eo(a,b,c,d||null,!e,g,h);e||(k=k.then(function(m){a.je.push(m);return m}));return l.return(k)})}
600
- function Eo(a,b,c,d,e,f,g){e=void 0===e?!0:e;f=void 0===f?!1:f;g=void 0===g?!0:g;var h,k,l,m,n,q,p,w,u,v,A,z,D,y,B;return O(function(C){if(1==C.g)return h=null,k=Le(a.g),f&&(k.manifest.disableVideo=!0),l=function(){return h.O&&h.s?null:h},m=function(){return l()?l().getConfiguration():a.g},n=function(E,G){l()?h.configure(E,G):a.configure(E,G)},Infinity!=a.fa.width||Infinity!=a.fa.height?C.u(2):F(C,sd(),3);2!=C.g&&(q=C.h,a.fa.width=q.width,a.fa.height=q.height);p=new qi(k,a.fa,null);w={networkingEngine:a.H,
601
- filter:function(E){var G,L;return O(function(K){if(1==K.g)return F(K,ri(p,E),2);if(4!=K.g){G=K.h;if(!G)return K.u(0);L=po("trackschanged");return F(K,Promise.resolve(),4)}h.dispatchEvent(L);H(K)})},makeTextStreamsForClosedCaptions:function(E){return Go(a,E)},onTimelineRegionAdded:function(E){var G=h.G;a:{var L=t(G.g);for(var K=L.next();!K.done;K=L.next())if(K=K.value,K.schemeIdUri==E.schemeIdUri&&K.id==E.id&&K.startTime==E.startTime&&K.endTime==E.endTime){L=K;break a}L=null}null==L&&(G.g.add(E),E=
602
- new U("regionadd",new Map([["region",E]])),G.dispatchEvent(E))},onEvent:function(E){return h.dispatchEvent(E)},onError:function(E){return h.onError(E)},isLowLatencyMode:function(){return m().streaming.lowLatencyMode},isAutoLowLatencyMode:function(){return m().streaming.autoLowLatencyMode},enableLowLatencyMode:function(){n("streaming.lowLatencyMode",!0)},updateDuration:function(){a.j&&h.O&&a.j.updateDuration()},newDrmInfo:function(E){var G=h.l,L=G?G.g:null;L&&G.s&&ti(p,L.keySystem,E)},onManifestUpdated:function(){var E=
603
- (new Map).set("isLive",a.V());h.dispatchEvent(po("manifestupdated",E));Bm(h,!1,function(){if(a.A)a.A.onManifestUpdated(a.V())})},getBandwidthEstimate:function(){return a.o.getBandwidthEstimate()},onMetadata:function(E,G,L,K){var I=E;if("com.apple.hls.interstitial"==E&&(I="com.apple.quicktime.HLS",E={startTime:G,endTime:L,values:K},a.A))a.A.onInterstitialMetadata(a,a.h,E);K=t(K);E=K.next();for(var J={};!E.done;J={Pg:void 0},E=K.next())J.Pg=E.value,Bm(h,!1,function(N){return function(){Ho(a,G,L,I,N.Pg)}}(J))},
604
- disableStream:function(E){return a.disableStream(E,a.g.streaming.maxDisabledTime)}};u=new nl(function(){return a.Ob()});u.addEventListener("regionadd",function(E){var G=E.region;Io(a,"timelineregionadded",G,h);Bm(h,!1,function(){if(a.A)a.A.onDashTimedMetadata(G)})});v=null;k.streaming.observeQualityChanges&&(v=new ol(function(){return a.wb()}),v.addEventListener("qualitychange",function(E){Jo(a,E.quality,E.position)}),v.addEventListener("audiotrackchange",function(E){Jo(a,E.quality,E.position,!0)}));
605
- A=!0;z={Lb:a.H,onError:function(E){return h.onError(E)},de:function(E){Bm(h,!0,function(){a:{var G=E,L=po("keystatuschanged");a.dispatchEvent(L);var K=Object.keys(G);1==K.length&&""==K[0]&&(K=["00"],G={"00":G[""]});L=1==K.length&&"00"==K[0];var I=!1;if(K.length){K=t(a.i.variants);for(var J=K.next();!J.done;J=K.next()){J=J.value;var N=[];J.audio&&N.push(J.audio);J.video&&N.push(J.video);N=t(N);for(var M=N.next();!M.done;M=N.next()){var P=M.value;M=J.allowedByKeySystem;if(P.keyIds.size){J.allowedByKeySystem=
606
- !0;P=t(P.keyIds);for(var R=P.next();!R.done;R=P.next())if(R=R.value,(R=G[L?"00":R])||a.B.F)J.allowedByKeySystem=J.allowedByKeySystem&&!!R&&!vi.includes(R)}M!=J.allowedByKeySystem&&(I=!0)}}}if(I&&(Ko(a),!Lo(a)))break a;(G=a.j.j)&&!G.allowedByKeySystem&&mo(a)}})},onExpirationUpdated:function(E,G){var L=po("expirationupdated");h.dispatchEvent(L);if((L=h.j)&&L.onExpirationUpdated)L.onExpirationUpdated(E,G)},onEvent:function(E){h.dispatchEvent(E);"drmsessionupdate"==E.type&&A&&(A=!1,E=Date.now()/1E3-h.ra,
607
- (a.s||h.getStats()).j=E,a.K&&Ij(a.K))}};D=jo(a,l);sg(a.H,D);y=function(){return a.zc(z)};B={config:k,wi:w,Fi:u,Ei:v,zc:y,vi:p,networkingEngine:D,yh:e,xh:g};h=new Am(b,d,c,B);return C.return(h)})}function xo(a,b){var c,d;return O(function(e){if(1==e.g)return c=a.g.manifest.retryParameters,F(e,hn(b,a.H,c),2);d=e.h;"application/x-mpegurl"==d&&gd()&&(d="application/vnd.apple.mpegurl");return e.return(d)})}
600
+ function Eo(a,b,c,d,e,f,g){e=void 0===e?!0:e;f=void 0===f?!1:f;g=void 0===g?!0:g;var h,k,l,m,n,p,r,u,v,w,A,z,D,y,B;return O(function(C){if(1==C.g)return h=null,k=Le(a.g),f&&(k.manifest.disableVideo=!0),l=function(){return h.O&&h.s?null:h},m=function(){return l()?l().getConfiguration():a.g},n=function(E,G){l()?h.configure(E,G):a.configure(E,G)},Infinity!=a.fa.width||Infinity!=a.fa.height?C.u(2):F(C,sd(),3);2!=C.g&&(p=C.h,a.fa.width=p.width,a.fa.height=p.height);r=new qi(k,a.fa,null);u={networkingEngine:a.H,
601
+ filter:function(E){var G,L;return O(function(K){if(1==K.g)return F(K,ri(r,E),2);if(4!=K.g){G=K.h;if(!G)return K.u(0);L=po("trackschanged");return F(K,Promise.resolve(),4)}h.dispatchEvent(L);H(K)})},makeTextStreamsForClosedCaptions:function(E){return Go(a,E)},onTimelineRegionAdded:function(E){var G=h.G;a:{var L=t(G.g);for(var K=L.next();!K.done;K=L.next())if(K=K.value,K.schemeIdUri==E.schemeIdUri&&K.id==E.id&&K.startTime==E.startTime&&K.endTime==E.endTime){L=K;break a}L=null}null==L&&(G.g.add(E),E=
602
+ new U("regionadd",new Map([["region",E]])),G.dispatchEvent(E))},onEvent:function(E){return h.dispatchEvent(E)},onError:function(E){return h.onError(E)},isLowLatencyMode:function(){return m().streaming.lowLatencyMode},isAutoLowLatencyMode:function(){return m().streaming.autoLowLatencyMode},enableLowLatencyMode:function(){n("streaming.lowLatencyMode",!0)},updateDuration:function(){a.j&&h.O&&a.j.updateDuration()},newDrmInfo:function(E){var G=h.l,L=G?G.g:null;L&&G.s&&ti(r,L.keySystem,E)},onManifestUpdated:function(){var E=
603
+ (new Map).set("isLive",a.V());h.dispatchEvent(po("manifestupdated",E));Bm(h,!1,function(){if(a.A)a.A.onManifestUpdated(a.V())})},getBandwidthEstimate:function(){return a.o.getBandwidthEstimate()},onMetadata:function(E,G,L,K){var I=E;if("com.apple.hls.interstitial"==E&&(I="com.apple.quicktime.HLS",E={startTime:G,endTime:L,values:K},a.A))a.A.onInterstitialMetadata(a,a.h,E);K=t(K);E=K.next();for(var J={};!E.done;J={Pg:void 0},E=K.next())J.Pg=E.value,Bm(h,!1,function(M){return function(){Ho(a,G,L,I,M.Pg)}}(J))},
604
+ disableStream:function(E){return a.disableStream(E,a.g.streaming.maxDisabledTime)}};v=new nl(function(){return a.Ob()});v.addEventListener("regionadd",function(E){var G=E.region;Io(a,"timelineregionadded",G,h);Bm(h,!1,function(){if(a.A)a.A.onDashTimedMetadata(G)})});w=null;k.streaming.observeQualityChanges&&(w=new ol(function(){return a.wb()}),w.addEventListener("qualitychange",function(E){Jo(a,E.quality,E.position)}),w.addEventListener("audiotrackchange",function(E){Jo(a,E.quality,E.position,!0)}));
605
+ A=!0;z={Lb:a.H,onError:function(E){return h.onError(E)},de:function(E){Bm(h,!0,function(){a:{var G=E,L=po("keystatuschanged");a.dispatchEvent(L);var K=Object.keys(G);1==K.length&&""==K[0]&&(K=["00"],G={"00":G[""]});L=1==K.length&&"00"==K[0];var I=!1;if(K.length){K=t(a.i.variants);for(var J=K.next();!J.done;J=K.next()){J=J.value;var M=[];J.audio&&M.push(J.audio);J.video&&M.push(J.video);M=t(M);for(var N=M.next();!N.done;N=M.next()){var P=N.value;N=J.allowedByKeySystem;if(P.keyIds.size){J.allowedByKeySystem=
606
+ !0;P=t(P.keyIds);for(var R=P.next();!R.done;R=P.next())if(R=R.value,(R=G[L?"00":R])||a.B.F)J.allowedByKeySystem=J.allowedByKeySystem&&!!R&&!vi.includes(R)}N!=J.allowedByKeySystem&&(I=!0)}}}if(I&&(Ko(a),!Lo(a)))break a;(G=a.j.j)&&!G.allowedByKeySystem&&mo(a)}})},onExpirationUpdated:function(E,G){var L=po("expirationupdated");h.dispatchEvent(L);if((L=h.j)&&L.onExpirationUpdated)L.onExpirationUpdated(E,G)},onEvent:function(E){h.dispatchEvent(E);"drmsessionupdate"==E.type&&A&&(A=!1,E=Date.now()/1E3-h.ra,
607
+ (a.s||h.getStats()).j=E,a.K&&Ij(a.K))}};D=jo(a,l);sg(a.H,D);y=function(){return a.zc(z)};B={config:k,wi:u,Fi:v,Ei:w,zc:y,vi:r,networkingEngine:D,yh:e,xh:g};h=new Am(b,d,c,B);return C.return(h)})}function xo(a,b){var c,d;return O(function(e){if(1==e.g)return c=a.g.manifest.retryParameters,F(e,hn(b,a.H,c),2);d=e.h;"application/x-mpegurl"==d&&gd()&&(d="application/vnd.apple.mpegurl");return e.return(d)})}
608
608
  function Fo(a,b){if(!Tc())return!0;if(b){if(""==(a.h||Vc()).canPlayType(b))return!1;if(!(Tc()&&b in yi))return!0;if(ke(b))return gd()&&(a.g.drm.servers["com.apple.fps"]||a.g.drm.servers["com.apple.fps.1_0"])?a.g.streaming.useNativeHlsForFairPlay:a.g.streaming.preferNativeHls}return!1}
609
609
  function vo(a){var b,c,d,e,f;return O(function(g){if(1==g.g)return ro(a,"media-source"),b=a.g.textDisplayFactory,c=b(),c.configure?c.configure(a.g.textDisplayer):qb("Text displayer w/ configure",'Text displayer should have a "configure" method!'),a.bg=b,d=Mo(a.h,c,{Qh:function(){return a.keySystem()},onMetadata:function(h,k,l){No(a,h,k,l)}},a.K),d.configure(a.g.mediaSource),e=a.g.manifest,f=e.segmentRelativeVttTiming,d.fa=f,F(g,d.L,2);a.G=d;H(g)})}
610
- function Bo(a,b,c,d){var e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L;return O(function(K){switch(K.g){case 1:ro(a,"load"),e=a.h,a.I=new Sk({Kd:function(){return e.playbackRate},jc:function(){return e.defaultPlaybackRate},Rf:function(I){e.playbackRate=I},Lg:function(I){e.currentTime+=I}}),f=function(){return Oo(a)},g=function(){return Po(a)},a.m.D(e,"playing",f),a.m.D(e,"pause",f),a.m.D(e,"ended",f),a.m.D(e,"ratechange",g),oo(a,a.g),a.Db=a.g.preferredTextLanguage,a.nd=a.g.preferredTextRole,a.md=a.g.preferForcedSubs,
611
- Qo(a.i.presentationTimeline,a.g.playRangeStart,a.g.playRangeEnd),a.o.init(function(I,J,N){a.i&&a.j&&I!=a.j.j&&Ro(a,I,!0,void 0===J?!1:J,void 0===N?0:N)}),a.o.setMediaElement(e),a.o.setCmsdManager(a.ea),a.j=So(a),a.j.configure(a.g.streaming),a.l=To,e.textTracks&&a.m.D(e.textTracks,"addtrack",function(I){if(I.track)switch(I=I.track,I.kind){case "chapters":Uo(a,I)}}),a.dispatchEvent(po("streaming")),h=c;case 2:(l=a.j.j)||h||(h=Lo(a)?a.o.chooseVariant():null);m=[];k=l||h;n=t([k.video,k.audio]);for(q=
612
- n.next();!q.done;q=n.next())(p=q.value)&&!p.segmentIndex&&m.push(p.createSegmentIndex());if(!(0<m.length)){K.u(4);break}return F(K,Promise.all(m),4);case 4:if(!k||0!=k.disabledUntilTime){K.u(2);break}if(a.F&&a.F.onInitialVariantChosen)a.F.onInitialVariantChosen(k);a.i.isLowLatency&&!a.g.streaming.lowLatencyMode&&Ya("Low-latency live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details.");
613
- Qo(a.i.presentationTimeline,a.g.playRangeStart,a.g.playRangeEnd);Hl(a.j,a.g.playRangeStart,a.g.playRangeEnd);w=function(I){a.C=Vo(a,I);a.Fb=Wo(a,I);Xo(a,e,Math.max(a.i.minBufferTime,a.g.streaming.rebufferingGoal))};a.g.streaming.startAtSegmentBoundary||w(a.qa);if(l){K.u(7);break}if(!a.g.streaming.startAtSegmentBoundary){K.u(8);break}u=a.i.presentationTimeline;v=a.qa||a.h.currentTime;A=u.Vb();z=u.yb();v<A?v=A:v>z&&(v=z);return F(K,Yo(h,v),9);case 9:D=K.h,w(D);case 8:Ro(a,h,!0,!1,0);case 7:return a.C.ready(),
610
+ function Bo(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L;return O(function(K){switch(K.g){case 1:ro(a,"load"),e=a.h,a.I=new Sk({Kd:function(){return e.playbackRate},jc:function(){return e.defaultPlaybackRate},Rf:function(I){e.playbackRate=I},Lg:function(I){e.currentTime+=I}}),f=function(){return Oo(a)},g=function(){return Po(a)},a.m.D(e,"playing",f),a.m.D(e,"pause",f),a.m.D(e,"ended",f),a.m.D(e,"ratechange",g),oo(a,a.g),a.Db=a.g.preferredTextLanguage,a.nd=a.g.preferredTextRole,a.md=a.g.preferForcedSubs,
611
+ Qo(a.i.presentationTimeline,a.g.playRangeStart,a.g.playRangeEnd),a.o.init(function(I,J,M){a.i&&a.j&&I!=a.j.j&&Ro(a,I,!0,void 0===J?!1:J,void 0===M?0:M)}),a.o.setMediaElement(e),a.o.setCmsdManager(a.ea),a.j=So(a),a.j.configure(a.g.streaming),a.l=To,e.textTracks&&a.m.D(e.textTracks,"addtrack",function(I){if(I.track)switch(I=I.track,I.kind){case "chapters":Uo(a,I)}}),a.dispatchEvent(po("streaming")),h=c;case 2:(l=a.j.j)||h||(h=Lo(a)?a.o.chooseVariant():null);m=[];k=l||h;n=t([k.video,k.audio]);for(p=
612
+ n.next();!p.done;p=n.next())(r=p.value)&&!r.segmentIndex&&m.push(r.createSegmentIndex());if(!(0<m.length)){K.u(4);break}return F(K,Promise.all(m),4);case 4:if(!k||0!=k.disabledUntilTime){K.u(2);break}if(a.F&&a.F.onInitialVariantChosen)a.F.onInitialVariantChosen(k);a.i.isLowLatency&&!a.g.streaming.lowLatencyMode&&Ya("Low-latency live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details.");
613
+ Qo(a.i.presentationTimeline,a.g.playRangeStart,a.g.playRangeEnd);Hl(a.j,a.g.playRangeStart,a.g.playRangeEnd);u=function(I){a.C=Vo(a,I);a.Fb=Wo(a,I);Xo(a,e,Math.max(a.i.minBufferTime,a.g.streaming.rebufferingGoal))};a.g.streaming.startAtSegmentBoundary||u(a.qa);if(l){K.u(7);break}if(!a.g.streaming.startAtSegmentBoundary){K.u(8);break}v=a.i.presentationTimeline;w=a.qa||a.h.currentTime;A=v.Vb();z=v.yb();w<A?w=A:w>z&&(w=z);return F(K,Yo(h,w),9);case 9:D=K.h,u(D);case 8:Ro(a,h,!0,!1,0);case 7:return a.C.ready(),
614
614
  y=a.Fc().find(function(I){return I.active}),y||((B=vf(a.i.textStreams,a.Db,a.nd,a.md)[0]||null)&&$k(a.s.h,B,!0),h&&(B?(Zo(a,h.audio,B)&&(a.la=!0),a.la&&a.G.F.setTextVisibility(!0),$o(a)):a.la=!1),B&&(a.g.streaming.alwaysStreamText||a.qf())&&Ql(a.j,B)),F(K,a.j.start(d),10);case 10:a.g.abr.enabled&&(a.o.enable(),ap(a));Ko(a);Lo(a);a.i.variants.some(function(I){return I.primary});if((C=a.V())&&(a.g.streaming.liveSync&&a.g.streaming.liveSync.enabled||a.i.serviceDescription||a.g.streaming.liveSync.panicMode)||
615
615
  a.g.streaming.vodDynamicPlaybackRate)E=function(){return bp(a)},a.m.D(e,"timeupdate",E);C||(G=function(){return cp(a)},a.m.D(e,"timeupdate",G),cp(a),a.i.nextUrl&&(0<a.g.streaming.preloadNextUrlWindow&&(L=function(){var I;return O(function(J){if(1==J.g){I=a.h.duration-a.h.currentTime;if(isNaN(I)||!(I<=a.g.streaming.preloadNextUrlWindow))return J.u(0);a.m.jb(e,"timeupdate",L);return F(J,a.preload(a.i.nextUrl),4)}a.ra=J.h;H(J)})},a.m.D(e,"timeupdate",L)),a.m.D(e,"ended",function(){a.load(a.ra||a.i.nextUrl)})));
616
616
  if(a.A)a.A.onManifestUpdated(C);a.Ea=!0;a.m.ja(e,"loadedmetadata",function(){a.s.m=Date.now()/1E3-b});H(K)}})}
617
617
  function zo(a,b){var c,d,e,f,g;return O(function(h){return 1==h.g?(c=Wd,d=Date.now()/1E3,e=!0,a.B=a.zc({Lb:a.H,onError:function(k){uo(a,k)},de:function(){},onExpirationUpdated:function(){var k=po("expirationupdated");a.dispatchEvent(k)},onEvent:function(k){a.dispatchEvent(k);"drmsessionupdate"==k.type&&e&&(e=!1,a.s.j=Date.now()/1E3-d)}}),a.B.configure(a.g.drm),f={id:0,language:"und",disabledUntilTime:0,primary:!1,audio:null,video:null,bandwidth:100,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},
618
618
  g={id:0,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:b?ie(b):"",codecs:b?je(b):"",encrypted:!0,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:c.ha,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(Zd(g.mimeType,
619
619
  g.codecs)),b.startsWith("audio/")?(g.type=c.X,f.audio=g):f.video=g,a.B.ba=!0,F(h,Nh(a.B,[f],[]),2)):F(h,a.B.Rb(a.h),0)})}
620
- function Co(a,b,c){var d,e,f,g,h,k,l,m,n,q,p,w;return O(function(u){if(1==u.g)return ro(a,"src-equals"),d=a.h,a.C=new Ik(d),e=!1,a.kd.push(function(){e=!0}),null!=a.qa&&a.C.De(a.qa),a.I=new Sk({Kd:function(){return d.playbackRate},jc:function(){return d.defaultPlaybackRate},Rf:function(v){d.playbackRate=v},Lg:function(v){d.currentTime+=v}}),f=a.g.streaming.rebufferingGoal,Xo(a,d,f),g=function(){return Oo(a)},h=function(){return Po(a)},a.m.D(d,"playing",g),a.m.D(d,"pause",g),a.m.D(d,"ended",g),a.m.D(d,
621
- "ratechange",h),"none"!=d.preload&&a.m.ja(d,"loadedmetadata",function(){a.s.m=Date.now()/1E3-b}),d.audioTracks&&(a.m.D(d.audioTracks,"addtrack",function(){return Ko(a)}),a.m.D(d.audioTracks,"removetrack",function(){return Ko(a)}),a.m.D(d.audioTracks,"change",function(){return Ko(a)})),d.textTracks&&(a.m.D(d.textTracks,"addtrack",function(v){if(v.track)switch(v=v.track,v.kind){case "metadata":dp(a,v);break;case "chapters":Uo(a,v);break;default:Ko(a)}}),a.m.D(d.textTracks,"removetrack",function(){return Ko(a)}),
620
+ function Co(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u;return O(function(v){if(1==v.g)return ro(a,"src-equals"),d=a.h,a.C=new Ik(d),e=!1,a.kd.push(function(){e=!0}),null!=a.qa&&a.C.De(a.qa),a.I=new Sk({Kd:function(){return d.playbackRate},jc:function(){return d.defaultPlaybackRate},Rf:function(w){d.playbackRate=w},Lg:function(w){d.currentTime+=w}}),f=a.g.streaming.rebufferingGoal,Xo(a,d,f),g=function(){return Oo(a)},h=function(){return Po(a)},a.m.D(d,"playing",g),a.m.D(d,"pause",g),a.m.D(d,"ended",g),a.m.D(d,
621
+ "ratechange",h),"none"!=d.preload&&a.m.ja(d,"loadedmetadata",function(){a.s.m=Date.now()/1E3-b}),d.audioTracks&&(a.m.D(d.audioTracks,"addtrack",function(){return Ko(a)}),a.m.D(d.audioTracks,"removetrack",function(){return Ko(a)}),a.m.D(d.audioTracks,"change",function(){return Ko(a)})),d.textTracks&&(a.m.D(d.textTracks,"addtrack",function(w){if(w.track)switch(w=w.track,w.kind){case "metadata":dp(a,w);break;case "chapters":Uo(a,w);break;default:Ko(a)}}),a.m.D(d.textTracks,"removetrack",function(){return Ko(a)}),
622
622
  a.m.D(d.textTracks,"change",function(){return Ko(a)})),k=Gn(a.N,a.da,c),!k.includes("#t=")&&(0<a.g.playRangeStart||isFinite(a.g.playRangeEnd))&&(k+="#t=",0<a.g.playRangeStart&&(k+=a.g.playRangeStart),isFinite(a.g.playRangeEnd)&&(k+=","+a.g.playRangeEnd)),d.src=k,($c()||cd())&&d.load(),"none"!=d.preload&&!d.autoplay&&ke(c)&&ld()&&d.load(),a.l=ep,a.dispatchEvent(po("streaming")),l=new bg,zk(d,HTMLMediaElement.HAVE_METADATA,a.m,function(){a.C.ready();l.resolve()}),zk(d,HTMLMediaElement.HAVE_CURRENT_DATA,
623
- a.m,function(){var v;return O(function(A){if(1==A.g)return fp(a),v=gp(a),v.find(function(z){return"disabled"!=z.mode})?(0<v.length&&(a.la=!0),A.u(2)):F(A,new Promise(function(z){a.m.ja(d.textTracks,"change",z);(new Sc(z)).Z(1)}),2);if(e)return A.return();hp(a);H(A)})}),d.error?l.reject(to(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.'),
624
- l.resolve()),a.m.ja(d,"error",function(){l.reject(to(a))}),m=new Promise(function(v,A){(new Sc(A)).Z(a.g.streaming.loadTimeout)}),F(u,Promise.race([l,m]),2);if((n=a.V())&&(a.g.streaming.liveSync&&a.g.streaming.liveSync.enabled||a.g.streaming.liveSync.panicMode)||a.g.streaming.vodDynamicPlaybackRate)q=function(){return bp(a)},a.m.D(d,"timeupdate",q);n||(p=function(){return cp(a)},a.m.D(d,"timeupdate",p),cp(a));a.A&&(a.A.onManifestUpdated(n),n&&(w=a.Ob().end,a.m.D(d,"progress",function(){var v=a.Ob().end;
625
- w!=v&&(a.A.onManifestUpdated(a.V()),w=v)})));a.Ea=!0;H(u)})}function fp(a){var b=a.g.preferredAudioLanguage;""!=b&&a.Xg(b,a.g.preferredVariantRole)}function hp(a){var b=a.g.preferredTextLanguage;""!=b&&a.Lf(b,a.g.preferredTextRole,a.g.preferForcedSubs)}
623
+ a.m,function(){var w;return O(function(A){if(1==A.g)return fp(a),w=gp(a),w.find(function(z){return"disabled"!=z.mode})?(0<w.length&&(a.la=!0),A.u(2)):F(A,new Promise(function(z){a.m.ja(d.textTracks,"change",z);(new Sc(z)).Z(1)}),2);if(e)return A.return();hp(a);H(A)})}),d.error?l.reject(to(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.'),
624
+ l.resolve()),a.m.ja(d,"error",function(){l.reject(to(a))}),m=new Promise(function(w,A){(new Sc(A)).Z(a.g.streaming.loadTimeout)}),F(v,Promise.race([l,m]),2);if((n=a.V())&&(a.g.streaming.liveSync&&a.g.streaming.liveSync.enabled||a.g.streaming.liveSync.panicMode)||a.g.streaming.vodDynamicPlaybackRate)p=function(){return bp(a)},a.m.D(d,"timeupdate",p);n||(r=function(){return cp(a)},a.m.D(d,"timeupdate",r),cp(a));a.A&&(a.A.onManifestUpdated(n),n&&(u=a.Ob().end,a.m.D(d,"progress",function(){var w=a.Ob().end;
625
+ u!=w&&(a.A.onManifestUpdated(a.V()),u=w)})));a.Ea=!0;H(v)})}function fp(a){var b=a.g.preferredAudioLanguage;""!=b&&a.Xg(b,a.g.preferredVariantRole)}function hp(a){var b=a.g.preferredTextLanguage;""!=b&&a.Lf(b,a.g.preferredTextRole,a.g.preferForcedSubs)}
626
626
  function dp(a,b){if("metadata"==b.kind){b.mode="hidden";a.m.D(b,"cuechange",function(){if(b.activeCues){for(var d=[],e=t(b.activeCues),f=e.next(),g={};!f.done;g={Ta:void 0},f=e.next()){g.Ta=f.value;Ho(a,g.Ta.startTime,g.Ta.endTime,g.Ta.type,g.Ta.value);if(a.A)a.A.onCueMetadataChange(g.Ta.value);"com.apple.quicktime.HLS"==g.Ta.type&&null!=g.Ta.startTime&&(f=d.find(function(h){return function(k){return k.startTime==h.Ta.startTime&&k.endTime==h.Ta.endTime}}(g)),f||(f={startTime:g.Ta.startTime,endTime:g.Ta.endTime,
627
627
  values:[]},d.push(f)),f.values.push(g.Ta.value))}d=t(d);for(e=d.next();!e.done;e=d.next())e=e.value,e.values.some(function(h){return"X-ASSET-URI"==h.key||"X-ASSET-LIST"==h.key})&&a.A&&(e.values.push({key:"CUE",description:"",data:"ONCE",mimeType:null,pictureType:null}),a.A.onInterstitialMetadata(a,a.h,e))}});var c=(new Sc(function(){var d=ip(a);d=t(d);for(var e=d.next();!e.done;e=d.next())e.value.mode="hidden"})).uc().Z(.5);a.kd.push(function(){c.stop()})}}
628
628
  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&&"number"==typeof 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())Ho(a,f,g,"org.id3",k.value);if(a.A)a.A.onHlsTimedMetadata(e,f)}}function Ho(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))}
629
- function Uo(a,b){if(b&&"chapters"==b.kind){b.mode="hidden";var c=(new Sc(function(){b.mode="hidden"})).uc().Z(.5);a.kd.push(function(){c.stop()})}}r.Ji=function(){for(var a=this.Y;a.g;)a.release()};r.zc=function(a){return new Gh(a)};
629
+ function Uo(a,b){if(b&&"chapters"==b.kind){b.mode="hidden";var c=(new Sc(function(){b.mode="hidden"})).uc().Z(.5);a.kd.push(function(){c.stop()})}}q.Ji=function(){for(var a=this.Y;a.g;)a.release()};q.zc=function(a){return new Gh(a)};
630
630
  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 og(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.ea){var h=a.ea;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],
631
- co(n[1]))}}catch(v){}if(l=e["cmsd-dynamic"]){try{var q=new Map,p=l.split(";");for(l=1;l<p.length;l++){var w=p[l].split("=");q.set(w[0],co(w[1]))}var u=q}catch(v){u=null}u&&(h.g=u)}}}})},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.N,k=g;k=void 0===k?{}:k;if(h.g.enabled)if("HEAD"===f.method)Nn(h,f);else switch(e){case 0:try{if(h.g.enabled){if(k.type){a:{switch(k.type){case 4:var l=
632
- "d";break a;case 3:case 2:l="h";break a;case 5:l="s";break a}l=void 0}h.m=l}Nn(h,f,{ot:Kn,su:!h.i})}}catch(M){$a("CMCD_MANIFEST_ERROR","Could not generate manifest CMCD data.",M)}break;case zg: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.V()?"l":"v"};n.ot=Rn(k);var q=n.ot===On||n.ot===In||n.ot===Jn||n.ot===Tn,p=k.stream;if(p){var w=h.h.eb();if(q&&(n.bl=Vn(h,p.type),n.ot!==Tn)){var u=Wn(h,p.type);n.dl=w?u/Math.abs(w):u}p.bandwidth&&(n.br=p.bandwidth/1E3);
633
- if(p.segmentIndex&&m){var v=p.segmentIndex.Ib(m.endTime,!0,0>w);if(v){var A=v.next().value;if(A&&A!=m){if(!Pb(m.M(),A.M())){var z=A.M()[0],D=f.uris[0],y=new URL(z),B=new URL(D);if(y.origin!==B.origin)var C=z;else{for(var E=y.pathname.split("/").slice(1),G=B.pathname.split("/").slice(1,-1);E[0]===G[0];)E.shift(),G.shift();for(;G.length;)G.shift(),E.unshift("..");C=E.join("/")}n.nor=C}if((A.Ga||A.ta)&&(m.Ga!=A.Ga||m.ta!=A.ta)){var L=A.Ga+"-";A.ta&&(L+=A.ta);n.nrr=L}}}var K=h.h.eb()||1,I=Wn(h,p.type)||
634
- 500,J=p.bandwidth;var N=J?J*(m.endTime-m.startTime)/1E3/(I/K/1E3)*h.g.rtpSafetyFactor:NaN;isNaN(N)||(n.rtp=N)}}q&&n.ot!==Tn&&(n.tb=Xn(h,n.ot)/1E3);Nn(h,f,n)}}catch(M){$a("CMCD_SEGMENT_ERROR","Could not generate segment CMCD data.",M)}break;case 2:case 5:case 6:Nn(h,f,{ot:"k"});break;case 4:Nn(h,f,{ot:"o"})}})},function(e,f,g,h){(e=b()?b().j:a.F)&&e.banLocation&&e.banLocation(h)},function(e,f){if(f.data){f=f.data.byteLength;var g=b()?b().getStats():a.s;g&&(g.ec=isNaN(g.ec)?f:g.ec+f,0===e&&(g.Hg=f))}})}
635
- function Vo(a,b){return new Jk(a.h,a.i,a.g.streaming,b,function(){a.Fb&&Vk(a.Fb,!0);a.j&&a.j.Pc();a.L&&jp(a)},function(c){return a.dispatchEvent(c)})}
636
- function Wo(a,b){b=new Pm(a.cd,a.V()||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 Uk(a.h);c.g.add(b);a.Yc&&c.g.add(a.Yc);return c}
631
+ 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.N,k=g;k=void 0===k?{}:k;if(h.g.enabled)if("HEAD"===f.method)Nn(h,f);else switch(e){case 0:try{if(h.g.enabled){if(k.type){a:{switch(k.type){case 4:var l=
632
+ "d";break a;case 3:case 2:l="h";break a;case 5:l="s";break a}l=void 0}h.m=l}Nn(h,f,{ot:Kn,su:!h.i})}}catch(N){$a("CMCD_MANIFEST_ERROR","Could not generate manifest CMCD data.",N)}break;case zg: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.V()?"l":"v"};n.ot=Rn(k);var p=n.ot===On||n.ot===In||n.ot===Jn||n.ot===Tn,r=k.stream;if(r){var u=h.h.eb();if(p&&(n.bl=Vn(h,r.type),n.ot!==Tn)){var v=Wn(h,r.type);n.dl=u?v/Math.abs(u):v}r.bandwidth&&(n.br=r.bandwidth/1E3);
633
+ if(r.segmentIndex&&m){var w=r.segmentIndex.Ib(m.endTime,!0,0>u);if(w){var A=w.next().value;if(A&&A!=m){if(!Pb(m.M(),A.M())){var z=A.M()[0],D=f.uris[0],y=new URL(z),B=new URL(D);if(y.origin!==B.origin)var C=z;else{for(var E=y.pathname.split("/").slice(1),G=B.pathname.split("/").slice(1,-1);E[0]===G[0];)E.shift(),G.shift();for(;G.length;)G.shift(),E.unshift("..");C=E.join("/")}n.nor=C}if((A.Ga||A.ta)&&(m.Ga!=A.Ga||m.ta!=A.ta)){var L=A.Ga+"-";A.ta&&(L+=A.ta);n.nrr=L}}}var K=h.h.eb()||1,I=Wn(h,r.type)||
634
+ 500,J=r.bandwidth;var M=J?J*(m.endTime-m.startTime)/1E3/(I/K/1E3)*h.g.rtpSafetyFactor:NaN;isNaN(M)||(n.rtp=M)}}p&&n.ot!==Tn&&(n.tb=Xn(h,n.ot)/1E3);Nn(h,f,n)}}catch(N){$a("CMCD_SEGMENT_ERROR","Could not generate segment CMCD data.",N)}break;case 2:case 5:case 6:Nn(h,f,{ot:"k"});break;case 4:Nn(h,f,{ot:"o"})}})},function(e,f,g,h){(e=b()?b().j:a.F)&&e.banLocation&&e.banLocation(h)},function(e,f){if(f.data){f=f.data.byteLength;var g=b()?b().getStats():a.s;g&&(g.ec=isNaN(g.ec)?f:g.ec+f,0===e&&(g.Hg=f))}})}
635
+ function Vo(a,b){return new Jk(a.h,a.i,a.g.streaming,b,function(){a.Fb&&Vk(a.Fb,!0);a.j&&a.j.Qc();a.L&&jp(a)},function(c){return a.dispatchEvent(c)})}
636
+ function Wo(a,b){b=new Pm(a.dd,a.V()||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 Uk(a.h);c.g.add(b);a.Zc&&c.g.add(a.Zc);return c}
637
637
  function Xo(a,b,c){a.L=new Vf;a.L.g=Xf;Yf(a.L,c,Math.min(.5,c/2));wo(a);a.ge=(new Sc(function(){jp(a)})).Ra(.25);a.m.D(b,"waiting",function(){return jp(a)});a.m.D(b,"stalled",function(){return jp(a)});a.m.D(b,"canplaythrough",function(){return jp(a)});a.m.D(b,"progress",function(){return jp(a)})}
638
638
  function jp(a){switch(a.l){case ep:if(a.h.ended)var b=!0;else{var c=Ki(a.h.buffered);b=null!=c&&c>=a.h.duration-1}break;case To:a:if(a.h.ended||Tj(a.G))b=!0;else{if(a.i.presentationTimeline.V()){c=a.i.presentationTimeline.Wb();var d=Ki(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.L;var e=b,f=c.i.get(c.g);b=c.g;d=e||d>=f?Wf:Xf;c.g=d;(b=b!=d)&&d===Wf&&(c.h=Date.now());b&&wo(a)}function Mo(a,b,c,d){return new Kj(a,b,c,d)}
639
639
  function io(a){return new En({getBandwidthEstimate:function(){return a.o?a.o.getBandwidthEstimate():NaN},wb:function(){return a.wb()},getCurrentTime:function(){return a.h?a.h.currentTime:0},eb:function(){return a.eb()},xb:function(){return a.xb()},kc:function(){return a.kc()},V:function(){return a.V()}},a.g.cmcd)}
640
640
  function So(a){return new Bl(a.i,{Jd:function(){return a.C?a.C.wd():0},getBandwidthEstimate:function(){return a.o.getBandwidthEstimate()},eb:function(){return a.eb()},aa:a.G,Lb:a.H,onError:function(b){return uo(a,b)},onEvent:function(b){return a.dispatchEvent(b)},Bi:function(){a.F&&a.F.update&&a.F.update()},Af:function(b,c){var d=b.startTime;b=b.endTime;var e=c.type;c=c.codecs.includes(",");if(a.C){a.C.Mg();var f=Uj(a.G,e);!a.V()&&a.h.paused&&null!=f&&0<f&&a.C.wd()<f&&a.C.De(f)}jp(a);d=(new Map).set("start",
641
- d).set("end",b).set("contentType",e).set("isMuxed",c);a.dispatchEvent(po("segmentappended",d))},Ai:function(b,c){(c=c.Hc)&&a.Yc&&ql(a.Yc,c,b)},kg:function(b,c){var d=a.B;if(d.h.parseInbandPsshEnabled&&!d.F&&["audio","video"].includes(b)){b=new Yg(zb(c));c=0;for(var e=t(b.data),f=e.next();!f.done;f=e.next())c+=f.value.length;if(0==c)d=Promise.resolve();else{c=new Uint8Array(c);e=0;b=t(b.data);for(f=b.next();!f.done;f=b.next())f=f.value,c.set(f,e),e+=f.length;Wh(d,"cenc",c);d=d.l}}else d=Promise.resolve();
641
+ d).set("end",b).set("contentType",e).set("isMuxed",c);a.dispatchEvent(po("segmentappended",d))},Ai:function(b,c){(c=c.Ic)&&a.Zc&&ql(a.Zc,c,b)},kg:function(b,c){var d=a.B;if(d.h.parseInbandPsshEnabled&&!d.F&&["audio","video"].includes(b)){b=new Yg(zb(c));c=0;for(var e=t(b.data),f=e.next();!f.done;f=e.next())c+=f.value.length;if(0==c)d=Promise.resolve();else{c=new Uint8Array(c);e=0;b=t(b.data);for(f=b.next();!f.done;f=b.next())f=f.value,c.set(f,e),e+=f.length;Wh(d,"cenc",c);d=d.l}}else d=Promise.resolve();
642
642
  return d},onMetadata:function(b,c,d){No(a,b,c,d)},disableStream:function(b,c){return a.disableStream(b,c)}})}
643
- r.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=mm(a,b));a.streaming&&"forceTransmuxTS"in a.streaming&&(qb("streaming.forceTransmuxTS configuration","Please Use mediaSource.forceTransmux instead."),a.mediaSource.mediaSource=a.streaming.forceTransmuxTS,delete a.streaming.forceTransmuxTS);a.streaming&&"forceTransmux"in a.streaming&&(qb("streaming.forceTransmux configuration","Please Use mediaSource.forceTransmux instead."),a.mediaSource.mediaSource=a.streaming.forceTransmux,delete a.streaming.forceTransmux);
643
+ q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=mm(a,b));a.streaming&&"forceTransmuxTS"in a.streaming&&(qb("streaming.forceTransmuxTS configuration","Please Use mediaSource.forceTransmux instead."),a.mediaSource.mediaSource=a.streaming.forceTransmuxTS,delete a.streaming.forceTransmuxTS);a.streaming&&"forceTransmux"in a.streaming&&(qb("streaming.forceTransmux configuration","Please Use mediaSource.forceTransmux instead."),a.mediaSource.mediaSource=a.streaming.forceTransmux,delete a.streaming.forceTransmux);
644
644
  a.streaming&&"useNativeHlsOnSafari"in a.streaming&&(qb("streaming.useNativeHlsOnSafari configuration","Please Use streaming.useNativeHlsForFairPlay or streaming.preferNativeHls instead."),a.streaming.preferNativeHls=a.streaming.useNativeHlsOnSafari&&gd(),delete a.streaming.useNativeHlsOnSafari);if(a.streaming&&"boolean"==typeof a.streaming.liveSync){qb("streaming.liveSync","Please Use streaming.liveSync.enabled instead.");var c=a.streaming.liveSync;a.streaming.liveSync={};a.streaming.liveSync.enabled=
645
645
  c}if(a.streaming&&!(a.streaming.liveSync&&"targetLatency"in a.streaming.liveSync)&&("liveSyncMinLatency"in a.streaming||"liveSyncMaxLatency"in a.streaming)){c=a.streaming.liveSyncMinLatency||0;var d=Math.abs((a.streaming.liveSyncMaxLatency||1)-c)/2;a.streaming.liveSync=a.streaming.liveSync||{};a.streaming.liveSync.targetLatency=c+d;a.streaming.liveSync.targetLatencyTolerance=d}a.streaming&&"liveSyncMaxLatency"in a.streaming&&(qb("streaming.liveSyncMaxLatency","Please Use streaming.liveSync.targetLatency and streaming.liveSync.targetLatencyTolerance instead. Or, set the values in your DASH manifest"),
646
646
  delete a.streaming.liveSyncMaxLatency);a.streaming&&"liveSyncMinLatency"in a.streaming&&(qb("streaming.liveSyncMinLatency","Please Use streaming.liveSync.targetLatency and streaming.liveSync.targetLatencyTolerance instead. Or, set the values in your DASH manifest"),delete a.streaming.liveSyncMinLatency);a.streaming&&"liveSyncTargetLatency"in a.streaming&&(qb("streaming.liveSyncTargetLatency","Please Use streaming.liveSync.targetLatency instead."),a.streaming.liveSync=a.streaming.liveSync||{},a.streaming.liveSync.targetLatency=
@@ -653,67 +653,67 @@ a.streaming.liveSyncPanicThreshold,delete a.streaming.liveSyncPanicThreshold);if
653
653
  ho(this));kp(this);return c};
654
654
  function kp(a){a.$d=new qi(a.g,a.fa,a.B);if(a.F){var b=Le(a.g.manifest);a.h&&"AUDIO"===a.h.nodeName&&(b.disableVideo=!0);a.F.configure(b)}a.B&&a.B.configure(a.g.drm);if(a.j){a.j.configure(a.g.streaming);try{a.l!=qo&&si(a.$d,a.i)&&Ko(a)}catch(f){uo(a,f)}a.o&&Lo(a);b=a.j.j;!b||b.allowedByApplication&&b.allowedByKeySystem||mo(a)}a.H&&(a.H.Pf(a.g.streaming.forceHTTP),a.H.Qf(a.g.streaming.forceHTTPS));if(a.G)if(a.G.configure(a.g.mediaSource),a.G.fa=a.g.manifest.segmentRelativeVttTiming,b=a.g.textDisplayFactory,
655
655
  a.bg!=b){var c=b();c.configure?c.configure(a.g.textDisplayer):qb("Text displayer w/ configure",'Text displayer should have a "configure" method!');var d=a.G,e=d.F;d.F=c;e&&(c.setTextVisibility(e.isTextVisible()),e.destroy());d.g&&(d.g.j=c);a.bg=b;a.j&&(b=a.j,(c=b.i.get(Ud))&&Ol(b,c.stream,!0,0,!0))}else b=a.G.F,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(),ap(a));a.L&&(b=a.g.streaming.rebufferingGoal,a.i&&(b=Math.max(b,a.i.minBufferTime)),
656
- Yf(a.L,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.N&&a.N.configure(a.g.cmcd);a.ea&&a.ea.configure(a.g.cmsd)}r.getConfiguration=function(){var a=ho(this);zm(a,this.g,ho(this));return a};r.Ag=function(){var a=ho(this);zm(a,this.g,ho(this));return om(this.g,ho(this))};
657
- r.vg=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.Ob().end);if(a>=b)return 1;if(!(a<=this.h.currentTime)&&a<b)return(a-this.h.currentTime)/(b-this.h.currentTime)}return 0};r.Ni=function(){for(var a in this.g)delete this.g[a];zm(this.g,ho(this),ho(this));kp(this)};r.yg=function(){return this.l};r.gf=function(){return this.i?this.i.type:null};r.Uh=function(){return this.h};
658
- r.xb=function(){return this.H};r.Ec=function(){return this.da};r.ug=function(){return this.A?this.A:null};r.V=function(){return this.i?this.i.presentationTimeline.V():this.h&&this.h.src?Infinity==this.h.duration:!1};r.mc=function(){return this.i?this.i.presentationTimeline.mc():!1};r.ki=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};
659
- r.Ob=function(){if(this.i){if(!this.Ea&&"HLS"==this.i.type)return{start:0,end:0};var a=this.i.presentationTimeline;return{start:a.Vb(),end:a.yb()}}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}};r.hi=function(){this.V()&&(this.h.currentTime=this.Ob().end)};r.li=function(){return this.Ea};r.keySystem=function(){var a=this.drmInfo();return a?a.keySystem:""};r.drmInfo=function(){return this.B?this.B.g:null};
660
- r.$c=function(){return this.B?this.B.$c():Infinity};r.ef=function(){return this.B?this.B.ef():[]};r.Id=function(){return this.B?this.B.Id():{}};r.nf=function(){return this.L?this.L.g==Xf:!1};r.eb=function(){return this.h?this.I?this.I.i:1:0};
661
- r.ud=function(a,b){var c=this;b=void 0===b?!0:b;0==a?Ya("A trick play rate of 0 is unsupported!"):(this.Fa.Qa(),this.h.paused&&this.h.play(),this.I.set(a),this.l==To&&(this.o.playbackRateChanged(a),Nl(this.j,b&&1<Math.abs(a))),this.V()&&this.Fa.D(this.h,"timeupdate",function(){var d=c.h.currentTime,e=c.Ob(),f=c.g.streaming.safeSeekOffset;0<a?Math.floor(d)>=Math.floor(e.end)&&c.Sc():Math.floor(d)<=Math.floor(e.start+f)&&c.Sc()}))};
662
- r.Sc=function(){var a=this.I.jc();this.l==ep&&this.I.set(a);this.l==To&&(this.I.set(a),this.o.playbackRateChanged(a),Nl(this.j,!1));this.Fa.Qa()};
663
- r.kc=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,tf(e)){var f=lf(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 sf(g)}):[]};
664
- r.Fc=function(){if(this.i){for(var a=this.j?this.j.s:null,b=[],c=t(this.i.textStreams),d=c.next();!d.done;d=c.next()){d=d.value;var e=mf(d);e.active=d==a;b.push(e)}return b}return this.h&&this.h.src&&this.h.textTracks?gp(this).map(function(f){return qf(f)}):[]};r.Oh=function(){var a=this.od;this.i&&(a=this.i.imageStreams);return a.map(function(b){return nf(b)})};
665
- r.Gh=function(a){var b=this,c,d,e,f;return O(function(g){if(1==g.g){if(b.l!=To&&b.l!=ep)return g.return(null);c=b.od;b.i&&(c=b.i.imageStreams);return(d=c.find(function(h){return h.id==a}))?d.segmentIndex?g.u(2):F(g,d.createSegmentIndex(),2):g.return(null)}if(4!=g.g)return e=[],d.segmentIndex.Hb(function(h){var k=lp(h.tilesLayout||d.tilesLayout);if(k){k=k.rows*k.fc;for(var l=h.j-h.startTime,m=0;m<k;m++)e.push(b.Cg(a,h.startTime+l*m/k))}}),F(g,Promise.all(e),4);f=g.h;return g.return(f.filter(function(h){return h}))})};
656
+ Yf(a.L,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.N&&a.N.configure(a.g.cmcd);a.ea&&a.ea.configure(a.g.cmsd)}q.getConfiguration=function(){var a=ho(this);zm(a,this.g,ho(this));return a};q.Ag=function(){var a=ho(this);zm(a,this.g,ho(this));return om(this.g,ho(this))};
657
+ q.vg=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.Ob().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.Ni=function(){for(var a in this.g)delete this.g[a];zm(this.g,ho(this),ho(this));kp(this)};q.yg=function(){return this.l};q.gf=function(){return this.i?this.i.type:null};q.Uh=function(){return this.h};
658
+ q.xb=function(){return this.H};q.Ec=function(){return this.da};q.ug=function(){return this.A?this.A:null};q.V=function(){return this.i?this.i.presentationTimeline.V():this.h&&this.h.src?Infinity==this.h.duration:!1};q.mc=function(){return this.i?this.i.presentationTimeline.mc():!1};q.ki=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};
659
+ q.Ob=function(){if(this.i){if(!this.Ea&&"HLS"==this.i.type)return{start:0,end:0};var a=this.i.presentationTimeline;return{start:a.Vb(),end:a.yb()}}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.hi=function(){this.V()&&(this.h.currentTime=this.Ob().end)};q.li=function(){return this.Ea};q.keySystem=function(){var a=this.drmInfo();return a?a.keySystem:""};q.drmInfo=function(){return this.B?this.B.g:null};
660
+ q.ad=function(){return this.B?this.B.ad():Infinity};q.ef=function(){return this.B?this.B.ef():[]};q.Id=function(){return this.B?this.B.Id():{}};q.nf=function(){return this.L?this.L.g==Xf:!1};q.eb=function(){return this.h?this.I?this.I.i:1:0};
661
+ q.ud=function(a,b){var c=this;b=void 0===b?!0:b;0==a?Ya("A trick play rate of 0 is unsupported!"):(this.Fa.Qa(),this.h.paused&&this.h.play(),this.I.set(a),this.l==To&&(this.o.playbackRateChanged(a),Nl(this.j,b&&1<Math.abs(a))),this.V()&&this.Fa.D(this.h,"timeupdate",function(){var d=c.h.currentTime,e=c.Ob(),f=c.g.streaming.safeSeekOffset;0<a?Math.floor(d)>=Math.floor(e.end)&&c.Tc():Math.floor(d)<=Math.floor(e.start+f)&&c.Tc()}))};
662
+ q.Tc=function(){var a=this.I.jc();this.l==ep&&this.I.set(a);this.l==To&&(this.I.set(a),this.o.playbackRateChanged(a),Nl(this.j,!1));this.Fa.Qa()};
663
+ q.kc=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,tf(e)){var f=lf(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 sf(g)}):[]};
664
+ q.Fc=function(){if(this.i){for(var a=this.j?this.j.s:null,b=[],c=t(this.i.textStreams),d=c.next();!d.done;d=c.next()){d=d.value;var e=mf(d);e.active=d==a;b.push(e)}return b}return this.h&&this.h.src&&this.h.textTracks?gp(this).map(function(f){return qf(f)}):[]};q.Oh=function(){var a=this.od;this.i&&(a=this.i.imageStreams);return a.map(function(b){return nf(b)})};
665
+ q.Gh=function(a){var b=this,c,d,e,f;return O(function(g){if(1==g.g){if(b.l!=To&&b.l!=ep)return g.return(null);c=b.od;b.i&&(c=b.i.imageStreams);return(d=c.find(function(h){return h.id==a}))?d.segmentIndex?g.u(2):F(g,d.createSegmentIndex(),2):g.return(null)}if(4!=g.g)return e=[],d.segmentIndex.Hb(function(h){var k=lp(h.tilesLayout||d.tilesLayout);if(k){k=k.rows*k.fc;for(var l=h.j-h.startTime,m=0;m<k;m++)e.push(b.Cg(a,h.startTime+l*m/k))}}),F(g,Promise.all(e),4);f=g.h;return g.return(f.filter(function(h){return h}))})};
666
666
  function lp(a){return a?(a=/(\d+)x(\d+)/.exec(a))?{fc:parseInt(a[1],10),rows:parseInt(a[2],10)}:null:null}
667
- r.Cg=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y;return O(function(B){if(1==B.g){if(c.l!=To&&c.l!=ep)return B.return(null);d=c.od;c.i&&(d=c.i.imageStreams);return(e=d.find(function(C){return C.id==a}))?e.segmentIndex?B.u(2):F(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=lp(g.tilesLayout||e.tilesLayout);if(!h)return B.return(null);k=e.width||0;l=e.height||0;m=k/h.fc;n=l/h.rows;q=h.fc*h.rows;p=g.j-g.startTime;
668
- w=g.B||p/q;u=g.startTime;A=v=0;1<q&&(z=Math.floor((b-g.startTime)/w),u=g.startTime+z*w,v=z%h.fc*m,A=Math.floor(z/h.fc)*n);D=!1;if(y=g.A)D=!0,n=y.height,v=y.positionX,A=y.positionY,m=y.width;return B.return({segment:g,imageHeight:l,imageWidth:k,height:n,positionX:v,positionY:A,startTime:u,duration:w,uris:g.M(),width:m,sprite:D})})};
669
- r.Yg=function(a){if(this.i&&this.j){var b=this.i.textStreams.find(function(d){return d.id==a.id});b&&b!=this.j.s&&($k(this.s.h,b,!1),Ql(this.j,b),mp(this),this.Db=b.language)}else if(this.h&&this.h.src&&this.h.textTracks){b=gp(this);b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,of(c)==a.id?c.mode=this.la?"showing":"hidden":c.mode="disabled";mp(this)}};
670
- r.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&&tf(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.za=new Kf(d,
671
- this.g.mediaSource.codecSwitchingStrategy,this.g.manifest.dash.enableAudioGroups);Lo(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,of(c)==a.id){np(this,c);break}};r.Ih=function(){return op(this.kc())};r.ai=function(){return op(this.Fc())};r.Hh=function(){return Array.from(pp(this.kc()))};r.$h=function(){return Array.from(pp(this.Fc()))};
672
- r.Xg=function(a,b,c,d,e){c=void 0===c?0:c;d=void 0===d?0:d;e=void 0===e?"":e;if(this.i&&this.C){this.za=new Lf(a,b||"",c,"",!1,"","","",this.g.mediaSource.codecSwitchingStrategy,this.g.manifest.dash.enableAudioGroups,e);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;e=this.za.create(this.i.variants);c=null;e=t(e.values());for(var f=e.next();!f.done;f=e.next())f=f.value,
673
- tf(f)&&(!c||a(c,b)>a(f,b))&&(c=f);c!=b&&(c?(a=lf(c),this.Mf(a,!0,d)):mo(this))}else this.h&&this.h.audioTracks&&(d=vf(this.kc(),a,b||"",!1)[0])&&this.Mf(d)};r.Lf=function(a,b,c){c=void 0===c?!1:c;if(this.i&&this.C){if(this.Db=a,this.nd=b||"",this.md=c,(a=vf(this.i.textStreams,this.Db,this.nd,this.md)[0]||null)&&a!=this.j.s&&($k(this.s.h,a,!1),this.g.streaming.alwaysStreamText||this.qf()))Ql(this.j,a),mp(this)}else(a=vf(this.Fc(),a,b||"",c)[0])&&this.Yg(a)};
674
- r.Ti=function(a,b,c){b=void 0===b?!0:b;c=void 0===c?0:c;if(this.i&&this.C){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.za=new Lf(d.language,"",0,"",!1,"",a,"",this.g.mediaSource.codecSwitchingStrategy,this.g.manifest.dash.enableAudioGroups),mo(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&&np(this,b)}};
675
- r.qf=function(){var a=this.la;return this.G&&this.l==To?this.G.F.isTextVisible():this.h&&this.h.src&&this.h.textTracks?gp(this).some(function(b){return"showing"==b.mode}):a};r.wg=function(){return this.h&&this.h.src&&this.h.textTracks?qp(this).map(function(a){return qf(a)}):[]};
676
- r.Kh=function(a){if(!this.h||!this.h.src||!this.h.textTracks)return[];var b=De(a),c=qp(this).filter(function(h){return De(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};
667
+ q.Cg=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y;return O(function(B){if(1==B.g){if(c.l!=To&&c.l!=ep)return B.return(null);d=c.od;c.i&&(d=c.i.imageStreams);return(e=d.find(function(C){return C.id==a}))?e.segmentIndex?B.u(2):F(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=lp(g.tilesLayout||e.tilesLayout);if(!h)return B.return(null);k=e.width||0;l=e.height||0;m=k/h.fc;n=l/h.rows;p=h.fc*h.rows;r=g.j-g.startTime;
668
+ u=g.B||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.fc*m,A=Math.floor(z/h.fc)*n);D=!1;if(y=g.A)D=!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.M(),width:m,sprite:D})})};
669
+ q.Yg=function(a){if(this.i&&this.j){var b=this.i.textStreams.find(function(d){return d.id==a.id});b&&b!=this.j.s&&($k(this.s.h,b,!1),Ql(this.j,b),mp(this),this.Db=b.language)}else if(this.h&&this.h.src&&this.h.textTracks){b=gp(this);b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,of(c)==a.id?c.mode=this.la?"showing":"hidden":c.mode="disabled";mp(this)}};
670
+ 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&&tf(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.za=new Kf(d,
671
+ this.g.mediaSource.codecSwitchingStrategy,this.g.manifest.dash.enableAudioGroups);Lo(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,of(c)==a.id){np(this,c);break}};q.Ih=function(){return op(this.kc())};q.ai=function(){return op(this.Fc())};q.Hh=function(){return Array.from(pp(this.kc()))};q.$h=function(){return Array.from(pp(this.Fc()))};
672
+ q.Xg=function(a,b,c,d,e){c=void 0===c?0:c;d=void 0===d?0:d;e=void 0===e?"":e;if(this.i&&this.C){this.za=new Lf(a,b||"",c,"",!1,"","","",this.g.mediaSource.codecSwitchingStrategy,this.g.manifest.dash.enableAudioGroups,e);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;e=this.za.create(this.i.variants);c=null;e=t(e.values());for(var f=e.next();!f.done;f=e.next())f=f.value,
673
+ tf(f)&&(!c||a(c,b)>a(f,b))&&(c=f);c!=b&&(c?(a=lf(c),this.Mf(a,!0,d)):mo(this))}else this.h&&this.h.audioTracks&&(d=vf(this.kc(),a,b||"",!1)[0])&&this.Mf(d)};q.Lf=function(a,b,c){c=void 0===c?!1:c;if(this.i&&this.C){if(this.Db=a,this.nd=b||"",this.md=c,(a=vf(this.i.textStreams,this.Db,this.nd,this.md)[0]||null)&&a!=this.j.s&&($k(this.s.h,a,!1),this.g.streaming.alwaysStreamText||this.qf()))Ql(this.j,a),mp(this)}else(a=vf(this.Fc(),a,b||"",c)[0])&&this.Yg(a)};
674
+ q.Ti=function(a,b,c){b=void 0===b?!0:b;c=void 0===c?0:c;if(this.i&&this.C){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.za=new Lf(d.language,"",0,"",!1,"",a,"",this.g.mediaSource.codecSwitchingStrategy,this.g.manifest.dash.enableAudioGroups),mo(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&&np(this,b)}};
675
+ q.qf=function(){var a=this.la;return this.G&&this.l==To?this.G.F.isTextVisible():this.h&&this.h.src&&this.h.textTracks?gp(this).some(function(b){return"showing"==b.mode}):a};q.wg=function(){return this.h&&this.h.src&&this.h.textTracks?qp(this).map(function(a){return qf(a)}):[]};
676
+ q.Kh=function(a){if(!this.h||!this.h.src||!this.h.textTracks)return[];var b=De(a),c=qp(this).filter(function(h){return De(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};
677
677
  function gp(a){return Array.from(a.h.textTracks).filter(function(b){return"metadata"!=b.kind&&"chapters"!=b.kind&&"Shaka Player TextTrack"!=b.label})}function ip(a){return Array.from(a.h.textTracks).filter(function(b){return"metadata"==b.kind})}function qp(a){return Array.from(a.h.textTracks).filter(function(b){return"chapters"==b.kind})}
678
- r.eh=function(a){a=!!a;if(this.la!=a){this.la=a;if(this.l==To)this.G.F.setTextVisibility(a),this.g.streaming.alwaysStreamText||(a?this.j.s||(a=vf(this.i.textStreams,this.Db,this.nd,this.md),0<a.length&&(Ql(this.j,a[0]),mp(this))):Ml(this.j));else if(this.h&&this.h.src&&this.h.textTracks){var b=gp(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")}$o(this)}};
679
- r.Wh=function(){if(this.C)var a=this.C.wd();else{if(null==this.qa)return new Date;a=this.qa}if(this.i){var b=this.i.presentationTimeline;return new Date(1E3*((b.m||b.i)+a))}return this.h&&this.h.getStartDate?(b=this.h.getStartDate(),isNaN(b.getTime())?null:new Date(b.getTime()+1E3*a)):null};r.Bg=function(){if(this.i){var a=this.i.presentationTimeline;return new Date(1E3*(a.m||a.i))}return this.h&&this.h.getStartDate?(a=this.h.getStartDate(),isNaN(a.getTime())?null:a):null};
680
- r.Ld=function(){return this.V()?this.i?this.i.presentationTimeline.Ld():null:null};r.wb=function(){if(this.l==To)return this.G.wb();var a={total:[],audio:[],video:[],text:[]};this.l==ep&&(a.total=Qi(this.h.buffered));return a};
681
- r.getStats=function(){if(this.l!=To&&this.l!=ep)return{width:NaN,height:NaN,streamBandwidth:NaN,decodedFrames:NaN,droppedFrames:NaN,corruptedFrames:NaN,stallsDetected:NaN,gapsJumped:NaN,estimatedBandwidth:NaN,completionPercent:NaN,loadLatency:NaN,manifestTimeSeconds:NaN,drmTimeSeconds:NaN,playTime:NaN,pauseTime:NaN,bufferingTime:NaN,licenseTime:NaN,liveLatency:NaN,maxSegmentDuration:NaN,manifestSizeBytes:NaN,bytesDownloaded:NaN,nonFatalErrorCount:NaN,manifestPeriodCount:NaN,manifestGapCount:NaN,switchHistory:[],
678
+ q.eh=function(a){a=!!a;if(this.la!=a){this.la=a;if(this.l==To)this.G.F.setTextVisibility(a),this.g.streaming.alwaysStreamText||(a?this.j.s||(a=vf(this.i.textStreams,this.Db,this.nd,this.md),0<a.length&&(Ql(this.j,a[0]),mp(this))):Ml(this.j));else if(this.h&&this.h.src&&this.h.textTracks){var b=gp(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")}$o(this)}};
679
+ q.Wh=function(){if(this.C)var a=this.C.wd();else{if(null==this.qa)return new Date;a=this.qa}if(this.i){var b=this.i.presentationTimeline;return new Date(1E3*((b.m||b.i)+a))}return this.h&&this.h.getStartDate?(b=this.h.getStartDate(),isNaN(b.getTime())?null:new Date(b.getTime()+1E3*a)):null};q.Bg=function(){if(this.i){var a=this.i.presentationTimeline;return new Date(1E3*(a.m||a.i))}return this.h&&this.h.getStartDate?(a=this.h.getStartDate(),isNaN(a.getTime())?null:a):null};
680
+ q.Ld=function(){return this.V()?this.i?this.i.presentationTimeline.Ld():null:null};q.wb=function(){if(this.l==To)return this.G.wb();var a={total:[],audio:[],video:[],text:[]};this.l==ep&&(a.total=Qi(this.h.buffered));return a};
681
+ q.getStats=function(){if(this.l!=To&&this.l!=ep)return{width:NaN,height:NaN,streamBandwidth:NaN,decodedFrames:NaN,droppedFrames:NaN,corruptedFrames:NaN,stallsDetected:NaN,gapsJumped:NaN,estimatedBandwidth:NaN,completionPercent:NaN,loadLatency:NaN,manifestTimeSeconds:NaN,drmTimeSeconds:NaN,playTime:NaN,pauseTime:NaN,bufferingTime:NaN,licenseTime:NaN,liveLatency:NaN,maxSegmentDuration:NaN,manifestSizeBytes:NaN,bytesDownloaded:NaN,nonFatalErrorCount:NaN,manifestPeriodCount:NaN,manifestGapCount:NaN,switchHistory:[],
682
682
  stateHistory:[]};Oo(this);var a=this.h,b=a.currentTime/a.duration;if(!isNaN(b)&&!this.V()){var c=this.s;b=Math.round(100*b);c.i=isNaN(c.i)?b:Math.max(c.i,b)}this.C&&(this.s.T=this.C.fg(),this.s.Y=this.C.gg());if(a.getVideoPlaybackQuality){c=a.getVideoPlaybackQuality();b=this.s;var d=Number(c.totalVideoFrames);b.O=Number(c.droppedVideoFrames);b.N=d;this.s.L=Number(c.corruptedVideoFrames)}this.B?(c=this.B,c=c.I?c.I:NaN):c=NaN;this.s.s=c;if(this.l==To){c=this.j.j;b=this.j.s;if(c){d=this.I?this.I.i:1;
683
683
  var e=d*c.bandwidth;b&&b.bandwidth&&(e+=d*b.bandwidth);this.s.B=e}c&&c.video&&(b=this.s,d=c.video.height||NaN,b.o=c.video.width||NaN,b.l=d);this.V()&&(c=this.Bg().valueOf()+1E3*a.currentTime,this.s.C=(Date.now()-c)/1E3);this.i&&(this.s.G=this.i.periodCount,this.s.F=this.i.gapCount,this.i.presentationTimeline&&(this.s.I=this.i.presentationTimeline.g));c=this.o.getBandwidthEstimate();this.s.A=c}this.l==ep&&(c=this.s,c.ec=isNaN(c.ec)?NaN:c.ec+NaN,c=this.s,b=a.videoHeight||NaN,c.o=a.videoWidth||NaN,c.l=
684
- b);var f=this.s;a=f.o;c=f.l;b=f.B;d=f.N;e=f.O;var g=f.L,h=f.Y,k=f.T,l=f.A,m=f.i,n=f.m,q=f.H,p=f.j,w=Xk(f.g,"playing"),u=Xk(f.g,"paused"),v=Xk(f.g,"buffering"),A=f.s,z=f.C,D=f.I,y=f.Hg,B=f.ec,C=f.K,E=f.G,G=f.F,L=Yk(f.g),K=[];f=t(f.h.g);for(var I=f.next();!I.done;I=f.next())I=I.value,K.push({timestamp:I.timestamp,id:I.id,type:I.type,fromAdaptation:I.fromAdaptation,bandwidth:I.bandwidth});return{width:a,height:c,streamBandwidth:b,decodedFrames:d,droppedFrames:e,corruptedFrames:g,stallsDetected:h,gapsJumped:k,
685
- estimatedBandwidth:l,completionPercent:m,loadLatency:n,manifestTimeSeconds:q,drmTimeSeconds:p,playTime:w,pauseTime:u,bufferingTime:v,licenseTime:A,liveLatency:z,maxSegmentDuration:D,manifestSizeBytes:y,bytesDownloaded:B,nonFatalErrorCount:C,manifestPeriodCount:E,manifestGapCount:G,stateHistory:L,switchHistory:K}};
686
- r.uh=function(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h=this,k,l,m,n,q,p,w,u,v,A,z,D;return O(function(y){switch(y.g){case 1:if(h.l!=To&&h.l!=ep)throw new T(1,7,7004);"subtitles"!=c&&"captions"!=c&&Ya("Using a kind value different of `subtitles` or `captions` can cause unwanted issues.");if(d){y.u(2);break}return F(y,rp(h,a),3);case 3:d=y.h;case 2:k=[];h.A&&(k=h.A.getCuePoints());if(h.l!=ep){y.u(4);break}g&&(c="forced");return F(y,sp(h,a,b,c,d,f||"",k),5);case 5:l=De(b);m=h.Fc();if(n=m.find(function(B){return De(B.language)==
687
- l&&B.label==(f||"")&&B.kind==c}))return Ko(h),y.return(n);throw new T(1,2,2012);case 4:q=Wd;p=h.h.duration;h.i&&(p=h.i.presentationTimeline.getDuration());if(Infinity==p)throw new T(1,4,4033);if(!k.length){y.u(6);break}return F(y,tp(h,a,h.H,h.g.streaming.retryParameters),7);case 7:w=y.h,u=up(h,w,d,k),v=new Blob([u],{type:"text/vtt"}),a=Nj(v),d="text/vtt";case 6:A={id:h.cg++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:Qk(0,p,[a]),mimeType:d||"",
688
- codecs:e||"",kind:c,encrypted:!1,drmInfos:[],keyIds:new Set,language:b,originalLanguage:b,label:f||null,type:q.ua,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([Zd(d||"",e||"")])};z=Zd(A.mimeType,A.codecs);D=qe(z);if(!D)throw new T(2,2,2014,d);h.i.textStreams.push(A);Ko(h);return y.return(mf(A))}})};
689
- r.vh=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z;return O(function(D){switch(D.g){case 1:if(c.l!=To&&c.l!=ep)throw new T(1,7,7004);if(b){D.u(2);break}return F(D,rp(c,a),3);case 3:b=D.h;case 2:if("text/vtt"!=b)throw new T(1,2,2017,a);d=Wd;e=c.h.duration;c.i&&(e=c.i.presentationTimeline.getDuration());if(Infinity==e)throw new T(1,4,4045);return F(D,tp(c,a,c.H,c.g.streaming.retryParameters),4);case 4:f=D.h;g=re[b];if(!g)throw new T(2,2,2014,b);h=g();k={periodStart:0,segmentStart:0,segmentEnd:e,
690
- vttOffset:0};l=zb(f);m=h.parseMedia(l,k,a);n=[];q=t(m);p=q.next();for(w={};!p.done;w={xe:void 0,Ac:void 0},p=q.next())w.Ac=p.value,w.xe=null,u=function(y){return function(){null==y.xe&&(y.xe=Md([a],[y.Ac.payload]));return y.xe||[]}}(w),v=new Fi(w.Ac.startTime,w.Ac.endTime,u,0,null,null,0,0,Infinity),w.Ac.payload.includes("#xywh")&&(A=w.Ac.payload.split("#xywh=")[1].split(","),4===A.length&&v.fh({height:parseInt(A[3],10),positionX:parseInt(A[0],10),positionY:parseInt(A[1],10),width:parseInt(A[2],10)})),
691
- n.push(v);z={id:c.cg++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Ok(n),mimeType:b||"",codecs:"",kind:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:d.Ce,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([Zd(b||
684
+ b);var f=this.s;a=f.o;c=f.l;b=f.B;d=f.N;e=f.O;var g=f.L,h=f.Y,k=f.T,l=f.A,m=f.i,n=f.m,p=f.H,r=f.j,u=Xk(f.g,"playing"),v=Xk(f.g,"paused"),w=Xk(f.g,"buffering"),A=f.s,z=f.C,D=f.I,y=f.Hg,B=f.ec,C=f.K,E=f.G,G=f.F,L=Yk(f.g),K=[];f=t(f.h.g);for(var I=f.next();!I.done;I=f.next())I=I.value,K.push({timestamp:I.timestamp,id:I.id,type:I.type,fromAdaptation:I.fromAdaptation,bandwidth:I.bandwidth});return{width:a,height:c,streamBandwidth:b,decodedFrames:d,droppedFrames:e,corruptedFrames:g,stallsDetected:h,gapsJumped:k,
685
+ estimatedBandwidth:l,completionPercent:m,loadLatency:n,manifestTimeSeconds:p,drmTimeSeconds:r,playTime:u,pauseTime:v,bufferingTime:w,licenseTime:A,liveLatency:z,maxSegmentDuration:D,manifestSizeBytes:y,bytesDownloaded:B,nonFatalErrorCount:C,manifestPeriodCount:E,manifestGapCount:G,stateHistory:L,switchHistory:K}};
686
+ q.uh=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,D;return O(function(y){switch(y.g){case 1:if(h.l!=To&&h.l!=ep)throw new T(1,7,7004);"subtitles"!=c&&"captions"!=c&&Ya("Using a kind value different of `subtitles` or `captions` can cause unwanted issues.");if(d){y.u(2);break}return F(y,rp(h,a),3);case 3:d=y.h;case 2:k=[];h.A&&(k=h.A.getCuePoints());if(h.l!=ep){y.u(4);break}g&&(c="forced");return F(y,sp(h,a,b,c,d,f||"",k),5);case 5:l=De(b);m=h.Fc();if(n=m.find(function(B){return De(B.language)==
687
+ l&&B.label==(f||"")&&B.kind==c}))return Ko(h),y.return(n);throw new T(1,2,2012);case 4:p=Wd;r=h.h.duration;h.i&&(r=h.i.presentationTimeline.getDuration());if(Infinity==r)throw new T(1,4,4033);if(!k.length){y.u(6);break}return F(y,tp(h,a,h.H,h.g.streaming.retryParameters),7);case 7:u=y.h,v=up(h,u,d,k),w=new Blob([v],{type:"text/vtt"}),a=Nj(w),d="text/vtt";case 6:A={id:h.cg++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:Qk(0,r,[a]),mimeType:d||"",
688
+ codecs:e||"",kind:c,encrypted:!1,drmInfos:[],keyIds:new Set,language:b,originalLanguage:b,label:f||null,type:p.ua,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([Zd(d||"",e||"")])};z=Zd(A.mimeType,A.codecs);D=qe(z);if(!D)throw new T(2,2,2014,d);h.i.textStreams.push(A);Ko(h);return y.return(mf(A))}})};
689
+ q.vh=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(D){switch(D.g){case 1:if(c.l!=To&&c.l!=ep)throw new T(1,7,7004);if(b){D.u(2);break}return F(D,rp(c,a),3);case 3:b=D.h;case 2:if("text/vtt"!=b)throw new T(1,2,2017,a);d=Wd;e=c.h.duration;c.i&&(e=c.i.presentationTimeline.getDuration());if(Infinity==e)throw new T(1,4,4045);return F(D,tp(c,a,c.H,c.g.streaming.retryParameters),4);case 4:f=D.h;g=re[b];if(!g)throw new T(2,2,2014,b);h=g();k={periodStart:0,segmentStart:0,segmentEnd:e,
690
+ vttOffset:0};l=zb(f);m=h.parseMedia(l,k,a);n=[];p=t(m);r=p.next();for(u={};!r.done;u={xe:void 0,Ac:void 0},r=p.next())u.Ac=r.value,u.xe=null,v=function(y){return function(){null==y.xe&&(y.xe=Md([a],[y.Ac.payload]));return y.xe||[]}}(u),w=new Fi(u.Ac.startTime,u.Ac.endTime,v,0,null,null,0,0,Infinity),u.Ac.payload.includes("#xywh")&&(A=u.Ac.payload.split("#xywh=")[1].split(","),4===A.length&&w.fh({height:parseInt(A[3],10),positionX:parseInt(A[0],10),positionY:parseInt(A[1],10),width:parseInt(A[2],10)})),
691
+ n.push(w);z={id:c.cg++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Ok(n),mimeType:b||"",codecs:"",kind:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:d.Ce,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([Zd(b||
692
692
  "","")])};c.l==ep?c.od.push(z):c.i.imageStreams.push(z);Ko(c);return D.return(nf(z))}})};
693
- r.th=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!=ep)throw new T(1,7,7004);if(c){k.u(2);break}return F(k,rp(d,a),3);case 3:c=k.h;case 2:return e=[],d.A&&(e=d.A.getCuePoints()),F(k,sp(d,a,b,"chapters",c,"",e),4);case 4:f=k.h;g=d.wg();h=g.find(function(l){return l.language==b});if(!h){k.u(5);break}return F(k,new Promise(function(l,m){d.m.ja(f,"load",l);d.m.ja(f,"error",function(){m(new T(1,2,2015))})}),6);case 6:return Ko(d),k.return(h);case 5:throw new T(1,
693
+ q.th=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!=ep)throw new T(1,7,7004);if(c){k.u(2);break}return F(k,rp(d,a),3);case 3:c=k.h;case 2:return e=[],d.A&&(e=d.A.getCuePoints()),F(k,sp(d,a,b,"chapters",c,"",e),4);case 4:f=k.h;g=d.wg();h=g.find(function(l){return l.language==b});if(!h){k.u(5);break}return F(k,new Promise(function(l,m){d.m.ja(f,"load",l);d.m.ja(f,"error",function(){m(new T(1,2,2015))})}),6);case 6:return Ko(d),k.return(h);case 5:throw new T(1,
694
694
  2,2012);}})};function rp(a,b){var c;return O(function(d){switch(d.g){case 1:return ra(d,2),F(d,hn(b,a.H,a.g.streaming.retryParameters),4);case 4:c=d.h;ta(d,3);break;case 2:ua(d);case 3:if(c)return d.return(c);throw new T(1,2,2011,b);}})}
695
- function sp(a,b,c,d,e,f,g){var h,k,l,m;return O(function(n){if(1==n.g)return"text/vtt"!=e||g.length?F(n,tp(a,b,a.H,a.g.streaming.retryParameters),3):n.u(2);2!=n.g&&(h=n.h,k=up(a,h,e,g),l=new Blob([k],{type:"text/vtt"}),b=Nj(l),e="text/vtt");m=document.createElement("track");var q=a.N,p=b;try{if(q.g.enabled){var w=Hn(q);w.ot=Un;w.su=!0;var u=Ln(w);var v=Mn(p,u)}else v=p}catch(A){$a("CMCD_TEXT_TRACK_ERROR","Could not generate text track CMCD data.",A),v=p}m.src=v;m.label=f;m.kind=d;m.srclang=c;a.h.getAttribute("crossorigin")||
695
+ function sp(a,b,c,d,e,f,g){var h,k,l,m;return O(function(n){if(1==n.g)return"text/vtt"!=e||g.length?F(n,tp(a,b,a.H,a.g.streaming.retryParameters),3):n.u(2);2!=n.g&&(h=n.h,k=up(a,h,e,g),l=new Blob([k],{type:"text/vtt"}),b=Nj(l),e="text/vtt");m=document.createElement("track");var p=a.N,r=b;try{if(p.g.enabled){var u=Hn(p);u.ot=Un;u.su=!0;var v=Ln(u);var w=Mn(r,v)}else w=r}catch(A){$a("CMCD_TEXT_TRACK_ERROR","Could not generate text track CMCD data.",A),w=r}m.src=w;m.label=f;m.kind=d;m.srclang=c;a.h.getAttribute("crossorigin")||
696
696
  a.h.setAttribute("crossorigin","anonymous");a.h.appendChild(m);return n.return(m)})}function tp(a,b,c,d){var e,f,g;return O(function(h){if(1==h.g){e=zg;f=tg([b],d);f.method="GET";var k=a.N;try{k.g.enabled&&Nn(k,f,{ot:Un,su:!0})}catch(l){$a("CMCD_TEXT_ERROR","Could not generate text CMCD data.",l)}return F(h,c.request(e,f).promise,2)}g=h.h;return h.return(g.data)})}
697
- function up(a,b,c,d){var e=re[c];if(e)return c=e(),a={periodStart:0,segmentStart:0,segmentEnd:a.h.duration,vttOffset:0},b=zb(b),b=c.parseMedia(b,a,null),Dn(b,d);throw new T(2,2,2014,c);}r.Yi=function(a,b){this.fa.width=a;this.fa.height=b};r.If=function(a){if(this.l==To){var b=this.j;a=void 0===a?.1:a;if(b.m.g)b=!1;else if(b.A)b=!1;else{for(var c=t(b.i.values()),d=c.next();!d.done;d=c.next())d=d.value,!d.ed||d.Ja||d.sb||(d.ed=!1,Ll(b,d,a));b=!0}}else b=!1;return b};
698
- r.ff=function(){Ya("Shaka Player's internal Manifest structure is NOT covered by semantic versioning compatibility guarantees. It may change at any time! Please consider filing a feature request for whatever you use getManifest() for.");return this.i};r.Rh=function(){return this.ab};
699
- function ho(a){var b=vm();b.streaming.failureCallback=function(c){if(a.V()){var d=null;1001==c.code||1002==c.code?(d=1,a.g.streaming.lowLatencyMode&&(d=.1)):1003==c.code&&(d=.1);null!=d&&(c.severity=1,a.If(d))}};b.textDisplayFactory=function(){if(a.ce){var c=a.getConfiguration();return new un(a.h,a.ce,c.textDisplayer)}return HTMLMediaElement.prototype.addTextTrack?new pn(a.h,"Shaka Player TextTrack"):new rn};return b}r.ih=function(a){this.ce=a};
697
+ function up(a,b,c,d){var e=re[c];if(e)return c=e(),a={periodStart:0,segmentStart:0,segmentEnd:a.h.duration,vttOffset:0},b=zb(b),b=c.parseMedia(b,a,null),Dn(b,d);throw new T(2,2,2014,c);}q.Yi=function(a,b){this.fa.width=a;this.fa.height=b};q.If=function(a){if(this.l==To){var b=this.j;a=void 0===a?.1:a;if(b.m.g)b=!1;else if(b.A)b=!1;else{for(var c=t(b.i.values()),d=c.next();!d.done;d=c.next())d=d.value,!d.fd||d.Ja||d.sb||(d.fd=!1,Ll(b,d,a));b=!0}}else b=!1;return b};
698
+ q.ff=function(){Ya("Shaka Player's internal Manifest structure is NOT covered by semantic versioning compatibility guarantees. It may change at any time! Please consider filing a feature request for whatever you use getManifest() for.");return this.i};q.Rh=function(){return this.ab};
699
+ function ho(a){var b=vm();b.streaming.failureCallback=function(c){if(a.V()){var d=null;1001==c.code||1002==c.code?(d=1,a.g.streaming.lowLatencyMode&&(d=.1)):1003==c.code&&(d=.1);null!=d&&(c.severity=1,a.If(d))}};b.textDisplayFactory=function(){if(a.ce){var c=a.getConfiguration();return new un(a.h,a.ce,c.textDisplayer)}return HTMLMediaElement.prototype.addTextTrack?new pn(a.h,"Shaka Player TextTrack"):new rn};return b}q.ih=function(a){this.ce=a};
700
700
  function Go(a,b){for(var c=new Set,d=t(b.textStreams),e=d.next();!e.done;e=d.next())e=e.value,"application/cea-608"!=e.mimeType&&"application/cea-708"!=e.mimeType||c.add(e.originalId);d=t(b.variants);for(e=d.next();!e.done;e=d.next())if((e=e.value.video)&&e.closedCaptions)for(var f=t(e.closedCaptions.keys()),g=f.next();!g.done;g=f.next())if(g=g.value,!c.has(g)){var h=g.startsWith("CC")?"application/cea-608":"application/cea-708",k=new Rk,l=e.closedCaptions.get(g);h={id:a.cg++,originalId:g,groupId:null,
701
701
  createSegmentIndex:function(){return Promise.resolve()},segmentIndex:k,mimeType:h,codecs:"",kind:"caption",encrypted:!1,drmInfos:[],keyIds:new Set,language:l,originalLanguage:l,label:null,type:Ud,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:e.roles,forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set([Zd(h,"")])};b.textStreams.push(h);c.add(g)}}
702
- function Yo(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,q;return O(function(p){if(1==p.g)return k?F(p,k.createSegmentIndex(),2):p.return(null);n=(m=k.segmentIndex.Ib(l))?m.next().value:null;if(!n)return p.return(null);q=n.startTime;return p.return(q)})},F(h,e(c,b),2);if(3!=h.g)return f=h.h,F(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)})}
702
+ function Yo(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?F(r,k.createSegmentIndex(),2):r.return(null);n=(m=k.segmentIndex.Ib(l))?m.next().value:null;if(!n)return r.return(null);p=n.startTime;return r.return(p)})},F(h,e(c,b),2);if(3!=h.g)return f=h.h,F(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)})}
703
703
  function wo(a){var b=a.nf();if(a.s&&a.L&&a.C){var c=a.I;c.j=b;Tk(c);a.N&&(c=a.N,b||c.i||(c.i=!0),c.i&&b&&(c.j=!0),c.l=b);Oo(a);c=a.g.streaming.liveSync.dynamicTargetLatency.maxAttempts;if(a.g.streaming.liveSync.dynamicTargetLatency.enabled&&b&&a.ye<c){c=a.g.streaming.liveSync.dynamicTargetLatency.maxLatency;var d=a.g.streaming.liveSync.targetLatencyTolerance,e=a.g.streaming.liveSync.dynamicTargetLatency.rebufferIncrement;a.O&&(a.O=Math.min(a.O+ ++a.ye*e,c-d))}}b=(new Map).set("buffering",b);a.dispatchEvent(po("buffering",
704
704
  b))}function Po(a){var b=a.h.playbackRate;0!=b&&(a.I&&a.I.set(b),b=po("ratechange"),a.dispatchEvent(b))}
705
705
  function Oo(a){if(a.s&&a.L){var b=a.s.g,c="playing";a.L.g==Xf?c="buffering":a.h.ended?c="ended":a.h.paused&&(c="paused");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)))}}
706
- function bp(a){var b=a.h.playbackRate,c=a.V();if(a.g.streaming.vodDynamicPlaybackRate&&!c){var d=a.g.streaming.vodDynamicPlaybackRateLowBufferRate,e=a.vg();e<=a.g.streaming.vodDynamicPlaybackRateBufferRatio?b!=d&&a.ud(d,!1):1==e&&b!==a.I.jc()&&a.Sc()}if(c&&(c=a.Ob(),Number.isFinite(c.end)&&!(a.h.currentTime<c.start))){d=a.g.streaming.liveSync.targetLatencyTolerance;e=a.g.streaming.liveSync.dynamicTargetLatency.enabled;var f=a.g.streaming.liveSync.dynamicTargetLatency.stabilityThreshold;if(a.g.streaming.liveSync&&
706
+ function bp(a){var b=a.h.playbackRate,c=a.V();if(a.g.streaming.vodDynamicPlaybackRate&&!c){var d=a.g.streaming.vodDynamicPlaybackRateLowBufferRate,e=a.vg();e<=a.g.streaming.vodDynamicPlaybackRateBufferRatio?b!=d&&a.ud(d,!1):1==e&&b!==a.I.jc()&&a.Tc()}if(c&&(c=a.Ob(),Number.isFinite(c.end)&&!(a.h.currentTime<c.start))){d=a.g.streaming.liveSync.targetLatencyTolerance;e=a.g.streaming.liveSync.dynamicTargetLatency.enabled;var f=a.g.streaming.liveSync.dynamicTargetLatency.stabilityThreshold;if(a.g.streaming.liveSync&&
707
707
  a.g.streaming.liveSync.enabled){var g=a.g.streaming.liveSync.targetLatency;var h=g+d;var k=Math.max(0,g-d);var l=a.g.streaming.liveSync.maxPlaybackRate;var m=a.g.streaming.liveSync.minPlaybackRate}else a.i&&a.i.serviceDescription&&(g=a.i.serviceDescription.targetLatency,null!=a.i.serviceDescription.targetLatency?h=a.i.serviceDescription.targetLatency+d:null!=a.i.serviceDescription.maxLatency&&(h=a.i.serviceDescription.maxLatency),null!=a.i.serviceDescription.targetLatency?k=Math.max(0,a.i.serviceDescription.targetLatency-
708
708
  d):null!=a.i.serviceDescription.minLatency&&(k=a.i.serviceDescription.minLatency),l=a.i.serviceDescription.maxPlaybackRate||a.g.streaming.liveSync.maxPlaybackRate,m=a.i.serviceDescription.minPlaybackRate||a.g.streaming.liveSync.minPlaybackRate);a.O||"number"!==typeof g||(a.O=g);var n=a.g.streaming.liveSync.dynamicTargetLatency.maxAttempts;e&&a.Da&&null!==a.O&&"number"===typeof g&&a.ye<n&&Date.now()-a.Da>1E3*f&&(f=a.g.streaming.liveSync.dynamicTargetLatency.minLatency,a.O=Math.max(a.O-(g-f)/2,f+d),
709
- a.Da=Date.now());e&&null!==a.O&&(h=a.O+d,k=a.O-d);g=c.end-a.h.currentTime;d=0;a.l==ep&&(e=a.h.buffered,0<e.length&&(d=e.end(e.length-1),d=Math.max(l,d-c.end)));c=a.g.streaming.liveSync.panicMode;e=1E3*a.g.streaming.liveSync.panicThreshold;f=Date.now()-a.L.h;c&&!m&&(m=a.g.streaming.liveSync.minPlaybackRate);c&&m&&f<=e?b!=m&&a.ud(m,!1):h&&l&&g-d>h?(b!=l&&a.ud(l,!1),a.Da=null):k&&m&&g-d<k?(b!=m&&a.ud(m,!1),a.Da=null):b!==a.I.jc()&&(a.Sc(),a.Da=Date.now())}}
709
+ a.Da=Date.now());e&&null!==a.O&&(h=a.O+d,k=a.O-d);g=c.end-a.h.currentTime;d=0;a.l==ep&&(e=a.h.buffered,0<e.length&&(d=e.end(e.length-1),d=Math.max(l,d-c.end)));c=a.g.streaming.liveSync.panicMode;e=1E3*a.g.streaming.liveSync.panicThreshold;f=Date.now()-a.L.h;c&&!m&&(m=a.g.streaming.liveSync.minPlaybackRate);c&&m&&f<=e?b!=m&&a.ud(m,!1):h&&l&&g-d>h?(b!=l&&a.ud(l,!1),a.Da=null):k&&m&&g-d<k?(b!=m&&a.ud(m,!1),a.Da=null):b!==a.I.jc()&&(a.Tc(),a.Da=Date.now())}}
710
710
  function cp(a){if(a.h){var b=!1,c=a.h.currentTime/a.h.duration;isNaN(c)||(c=Math.round(100*c),isNaN(a.T)?(a.T=c,b=!0):(c=Math.max(a.T,c),a.T!=c&&(a.T=c,b=!0)));if(b){var d;0==a.T?d=po("started"):25==a.T?d=po("firstquartile"):50==a.T?d=po("midpoint"):75==a.T?d=po("thirdquartile"):100==a.T&&(d=po("complete"));d&&a.dispatchEvent(d)}}}function Lo(a){try{ui(a.$d,a.i)}catch(c){return uo(a,c),!1}var b=uf(a.i.variants);b=a.za.create(b);a.o.setVariants(Array.from(b.values()));return!0}
711
711
  function mo(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;(f=Lo(a)?a.o.chooseVariant():null)&&Ro(a,f,e,b,c,d)}
712
712
  function Ro(a,b,c,d,e,f){f=void 0===f?!1:f;var g=a.j.j;if(b==g)d&&Pl(a.j,b,d,e,!0);else{var h=a.s.h;h.h!=b&&(h.h=b,h.g.push({timestamp:Date.now()/1E3,id:b.id,type:"variant",fromAdaptation:c,bandwidth:b.bandwidth}));Pl(a.j,b,d,e,f,c);d=null;g&&(d=lf(g));b=lf(b);c?(c=(new Map).set("oldTrack",d).set("newTrack",b),a.K&&Jj(a.K,b,a.gf()),c=po("adaptation",c),vp(a,c)):wp(a,d,b)}}
713
713
  function np(a,b){var c=Array.from(a.h.audioTracks).find(function(d){return d.enabled});b.enabled=!0;c&&(b.id!==c.id&&(c.enabled=!1),c=sf(c),b=sf(b),wp(a,c,b))}function Zo(a,b,c){if(0==a.g.autoShowText)return!1;if(1==a.g.autoShowText)return!0;var d=De(a.g.preferredTextLanguage);c=De(c.language);if(2==a.g.autoShowText)return Ce(c,d);if(3==a.g.autoShowText){if(!b)return!1;a=De(b.language);return Ce(c,d)&&!Ce(a,c)}Ya("Invalid autoShowText setting!");return!1}
714
714
  function Ko(a){var b=po("trackschanged");vp(a,b)}function wp(a,b,c){b=(new Map).set("oldTrack",b).set("newTrack",c);a.K&&Jj(a.K,c,a.gf());c=po("variantchanged",b);vp(a,c)}function mp(a){var b=po("textchanged");vp(a,b)}function $o(a){var b=po("texttrackvisibility");vp(a,b)}function ap(a){a.g.abr.enabled||lo(a);var b=(new Map).set("newStatus",a.g.abr.enabled);vp(a,po("abrstatuschanged",b))}
715
715
  function lo(a,b){b=void 0===b?!0:b;if(a.l==To){a.ie.stop();for(var c=t(a.i.variants),d=c.next();!d.done;d=c.next())d.value.disabledUntilTime=0;b&&Lo(a)}}
716
- r.disableStream=function(a,b){if(!this.g.abr.enabled||this.l===qo||!navigator.onLine||0==b)return!1;if(this.i.variants.some(function(h){var k=h[a.type];return k&&k.id!==a.id&&!h.disabledUntilTime?"audio"==a.type?a.language===k.language:!0:!1})){for(var c=!1,d=!1,e=t(this.i.variants),f=e.next();!f.done;f=e.next()){f=f.value;var g=f[a.type];g&&(g.id===a.id?(f.disabledUntilTime=Date.now()/1E3+b,c=!0):g.trickModeVideo&&g.trickModeVideo.id==a.id&&(d=!0))}if(!c&&d)return!1;this.ie.Ra(1);b=this.wb().video.reduce(function(h,
716
+ q.disableStream=function(a,b){if(!this.g.abr.enabled||this.l===qo||!navigator.onLine||0==b)return!1;if(this.i.variants.some(function(h){var k=h[a.type];return k&&k.id!==a.id&&!h.disabledUntilTime?"audio"==a.type?a.language===k.language:!0:!1})){for(var c=!1,d=!1,e=t(this.i.variants),f=e.next();!f.done;f=e.next()){f=f.value;var g=f[a.type];g&&(g.id===a.id?(f.disabledUntilTime=Date.now()/1E3+b,c=!0):g.trickModeVideo&&g.trickModeVideo.id==a.id&&(d=!0))}if(!c&&d)return!1;this.ie.Ra(1);b=this.wb().video.reduce(function(h,
717
717
  k){return h+k.end-k.start},0);mo(this,!1,b,!0,!1);return!0}return!1};
718
718
  function uo(a,b){var c,d,e;return O(function(f){switch(f.g){case 1:if(a.l==qo)return f.return();1===b.severity&&a.s.K++;c=!0;if(!(a.Ea&&a.i&&a.j)||3016!=b.code&&3014!=b.code&&3015!=b.code&&3018!=b.code){f.u(2);break}ra(f,3);return F(f,jm(a.j),5);case 5:d=f.h;c=!d;ta(f,2);break;case 3:ua(f),c=!0;case 2:if(!c)return f.return();2===b.severity&&lo(a,!1);e=po("error",(new Map).set("detail",b));a.dispatchEvent(e);e.defaultPrevented&&(b.handled=!0);H(f)}})}
719
719
  function Io(a,b,c,d){d=void 0===d?a:d;a=(new Map).set("detail",{schemeIdUri:c.schemeIdUri,value:c.value,startTime:c.startTime,endTime:c.endTime,id:c.id,eventElement:c.eventElement,eventNode:c.eventNode});d.dispatchEvent(po(b,a))}
@@ -724,24 +724,24 @@ function op(a){var b=new Map,c=new Map;a=t(a);for(var d=a.next();!d.done;d=a.nex
724
724
  h.push({language:l,role:m,label:n})}});return h}S("shaka.Player",Y);Y.prototype.setVideoContainer=Y.prototype.ih;Y.prototype.getManifestParserFactory=Y.prototype.Rh;Y.prototype.getManifest=Y.prototype.ff;Y.prototype.retryStreaming=Y.prototype.If;Y.prototype.setMaxHardwareResolution=Y.prototype.Yi;Y.prototype.addChaptersTrack=Y.prototype.th;Y.prototype.addThumbnailsTrack=Y.prototype.vh;Y.prototype.addTextTrackAsync=Y.prototype.uh;Y.prototype.getStats=Y.prototype.getStats;
725
725
  Y.prototype.getBufferedInfo=Y.prototype.wb;Y.prototype.getSegmentAvailabilityDuration=Y.prototype.Ld;Y.prototype.getPresentationStartTimeAsDate=Y.prototype.Bg;Y.prototype.getPlayheadTimeAsDate=Y.prototype.Wh;Y.prototype.setTextTrackVisibility=Y.prototype.eh;Y.prototype.getChapters=Y.prototype.Kh;Y.prototype.getChaptersTracks=Y.prototype.wg;Y.prototype.isTextTrackVisible=Y.prototype.qf;Y.prototype.selectVariantsByLabel=Y.prototype.Ti;Y.prototype.selectTextLanguage=Y.prototype.Lf;
726
726
  Y.prototype.selectAudioLanguage=Y.prototype.Xg;Y.prototype.getTextLanguages=Y.prototype.$h;Y.prototype.getAudioLanguages=Y.prototype.Hh;Y.prototype.getTextLanguagesAndRoles=Y.prototype.ai;Y.prototype.getAudioLanguagesAndRoles=Y.prototype.Ih;Y.prototype.selectVariantTrack=Y.prototype.Mf;Y.prototype.selectTextTrack=Y.prototype.Yg;Y.prototype.getThumbnails=Y.prototype.Cg;Y.prototype.getAllThumbnails=Y.prototype.Gh;Y.prototype.getImageTracks=Y.prototype.Oh;Y.prototype.getTextTracks=Y.prototype.Fc;
727
- Y.prototype.getVariantTracks=Y.prototype.kc;Y.prototype.cancelTrickPlay=Y.prototype.Sc;Y.prototype.trickPlay=Y.prototype.ud;Y.prototype.getPlaybackRate=Y.prototype.eb;Y.prototype.isBuffering=Y.prototype.nf;Y.prototype.getKeyStatuses=Y.prototype.Id;Y.prototype.getActiveSessionsMetadata=Y.prototype.ef;Y.prototype.getExpiration=Y.prototype.$c;Y.prototype.drmInfo=Y.prototype.drmInfo;Y.prototype.keySystem=Y.prototype.keySystem;Y.prototype.isFullyLoaded=Y.prototype.li;Y.prototype.goToLive=Y.prototype.hi;
727
+ Y.prototype.getVariantTracks=Y.prototype.kc;Y.prototype.cancelTrickPlay=Y.prototype.Tc;Y.prototype.trickPlay=Y.prototype.ud;Y.prototype.getPlaybackRate=Y.prototype.eb;Y.prototype.isBuffering=Y.prototype.nf;Y.prototype.getKeyStatuses=Y.prototype.Id;Y.prototype.getActiveSessionsMetadata=Y.prototype.ef;Y.prototype.getExpiration=Y.prototype.ad;Y.prototype.drmInfo=Y.prototype.drmInfo;Y.prototype.keySystem=Y.prototype.keySystem;Y.prototype.isFullyLoaded=Y.prototype.li;Y.prototype.goToLive=Y.prototype.hi;
728
728
  Y.prototype.seekRange=Y.prototype.Ob;Y.prototype.isAudioOnly=Y.prototype.ki;Y.prototype.isInProgress=Y.prototype.mc;Y.prototype.isLive=Y.prototype.V;Y.prototype.getAdManager=Y.prototype.ug;Y.prototype.getAssetUri=Y.prototype.Ec;Y.prototype.getNetworkingEngine=Y.prototype.xb;Y.prototype.getMediaElement=Y.prototype.Uh;Y.prototype.getManifestType=Y.prototype.gf;Y.prototype.getLoadMode=Y.prototype.yg;Y.prototype.resetConfiguration=Y.prototype.Ni;Y.prototype.getBufferFullness=Y.prototype.vg;
729
729
  Y.prototype.getNonDefaultConfiguration=Y.prototype.Ag;Y.prototype.getConfiguration=Y.prototype.getConfiguration;Y.prototype.configure=Y.prototype.configure;Y.prototype.releaseAllMutexes=Y.prototype.Ji;Y.prototype.destroyAllPreloads=Y.prototype.Pe;Y.prototype.preload=Y.prototype.preload;Y.prototype.detachAndSavePreload=Y.prototype.qg;Y.prototype.unloadAndSavePreload=Y.prototype.aj;Y.prototype.load=Y.prototype.load;Y.prototype.updateStartTime=Y.prototype.ej;Y.prototype.unload=Y.prototype.cc;
730
730
  Y.prototype.detach=Y.prototype.detach;Y.prototype.attachCanvas=Y.prototype.zh;Y.prototype.attach=Y.prototype.Rb;
731
731
  Y.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.u(2);break}return F(k,ni(),3);case 3:b=k.h;case 2:var l={};if(Tc())for(var m in yi)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]=Tc()?!!yi[n]:Uc(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($d));
732
- l={};m=t(m);for(n=m.next();!n.done;n=m.next()){n=n.value;l[n]=qe(n)?!0:Tc()?mb(n)||(lc(n)?!0:!1):Uc(n);var q=n.split(";")[0];l[q]=l[q]||l[n]}d=l;return F(k,sd(),4);case 4:e=k.h;f={manifest:c,media:d,drm:b,hardwareResolution:e};g=xp;for(h in g)f[h]=g[h]();return k.return(f)}})};
732
+ l={};m=t(m);for(n=m.next();!n.done;n=m.next()){n=n.value;l[n]=qe(n)?!0:Tc()?mb(n)||(lc(n)?!0:!1):Uc(n);var p=n.split(";")[0];l[p]=l[p]||l[n]}d=l;return F(k,sd(),4);case 4:e=k.h;f={manifest:c,media:d,drm:b,hardwareResolution:e};g=xp;for(h in g)f[h]=g[h]();return k.return(f)}})};
733
733
  Y.isBrowserSupported=function(){window.Promise||Ya("A Promise implementation or polyfill is required");if(!(window.Promise&&window.Uint8Array&&Array.prototype.forEach)||Zc("Trident/"))return!1;var a=ld();return a&&9>a||!(window.MediaKeys&&window.navigator&&window.navigator.requestMediaKeySystemAccess&&window.MediaKeySystemAccess&&window.MediaKeySystemAccess.prototype.getConfiguration)?!1:Tc()?!0:Uc("application/x-mpegurl")};Y.setAdManagerFactory=function(a){ko=a};
734
- Y.registerSupportPlugin=function(a,b){xp[a]=b};Y.prototype.destroy=Y.prototype.destroy;var qo=0,go=1,To=2,ep=3;Y.LoadMode={DESTROYED:qo,NOT_LOADED:go,MEDIA_SOURCE:To,SRC_EQUALS:ep};Y.version="v4.10.13";var yp=["4","10"];rb=new function(a){this.g=a;this.i=sb;this.h=tb}(new pb(Number(yp[0]),Number(yp[1])));var xp={},ko=null;function zp(){this.g=[];this.i=this.l=this.j=this.h=0}function Ap(a){return a.g.length?a.g.reduce(function(b,c){return b+c},0)/a.g.length:0};function Bp(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 gb;this.m.D(this.h,google.ima.AdEvent.Type.PAUSED,function(){d.i=!0});this.m.D(this.h,google.ima.AdEvent.Type.RESUMED,function(){d.i=!1})}r=Bp.prototype;r.needsSkipUI=function(){return!1};r.getDuration=function(){return this.g.getDuration()};r.getMinSuggestedDuration=function(){return this.g.getMinSuggestedDuration()};r.getRemainingTime=function(){return this.h.getRemainingTime()};r.isPaused=function(){return this.i};
735
- r.isSkippable=function(){return 0<=this.g.getSkipTimeOffset()};r.getTimeUntilSkippable=function(){var a=this.g.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};r.canSkipNow=function(){return this.h.getAdSkippableState()};r.skip=function(){return this.h.skip()};r.pause=function(){return this.h.pause()};r.play=function(){return this.h.resume()};r.getVolume=function(){return this.h.getVolume()};r.setVolume=function(a){this.j.volume=a;return this.h.setVolume(a)};
736
- r.isMuted=function(){return 0==this.h.getVolume()};r.isLinear=function(){return this.g.isLinear()};r.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)};r.setMuted=function(a){(this.j.muted=a)?(this.l=this.getVolume(),this.h.setVolume(0)):this.h.setVolume(this.l)};
737
- r.getSequenceLength=function(){var a=this.g.getAdPodInfo();return null==a?1:a.getTotalAds()};r.getPositionInSequence=function(){var a=this.g.getAdPodInfo();return null==a?1:a.getAdPosition()};r.getTitle=function(){return this.g.getTitle()};r.getDescription=function(){return this.g.getDescription()};r.getVastMediaBitrate=function(){return this.g.getVastMediaBitrate()};r.getVastMediaHeight=function(){return this.g.getVastMediaHeight()};r.getVastMediaWidth=function(){return this.g.getVastMediaWidth()};
738
- r.getAdId=function(){return this.g.getAdId()};r.getCreativeAdId=function(){return this.g.getCreativeAdId()};r.getAdvertiserName=function(){return this.g.getAdvertiserName()};r.getMediaUrl=function(){return this.g.getMediaUrl()};r.getTimeOffset=function(){var a=this.g.getAdPodInfo();return null==a?0:a.getTimeOffset()};r.getPodIndex=function(){var a=this.g.getAdPodInfo();return null==a?0:a.getPodIndex()};r.release=function(){this.h=this.g=null};S("shaka.ads.ClientSideAd",Bp);Bp.prototype.release=Bp.prototype.release;
734
+ Y.registerSupportPlugin=function(a,b){xp[a]=b};Y.prototype.destroy=Y.prototype.destroy;var qo=0,go=1,To=2,ep=3;Y.LoadMode={DESTROYED:qo,NOT_LOADED:go,MEDIA_SOURCE:To,SRC_EQUALS:ep};Y.version="v4.10.15";var yp=["4","10"];rb=new function(a){this.g=a;this.i=sb;this.h=tb}(new pb(Number(yp[0]),Number(yp[1])));var xp={},ko=null;function zp(){this.g=[];this.i=this.l=this.j=this.h=0}function Ap(a){return a.g.length?a.g.reduce(function(b,c){return b+c},0)/a.g.length:0};function Bp(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 gb;this.m.D(this.h,google.ima.AdEvent.Type.PAUSED,function(){d.i=!0});this.m.D(this.h,google.ima.AdEvent.Type.RESUMED,function(){d.i=!1})}q=Bp.prototype;q.needsSkipUI=function(){return!1};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};
735
+ 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)};
736
+ 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)};
737
+ 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()};
738
+ 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};S("shaka.ads.ClientSideAd",Bp);Bp.prototype.release=Bp.prototype.release;
739
739
  Bp.prototype.getPodIndex=Bp.prototype.getPodIndex;Bp.prototype.getTimeOffset=Bp.prototype.getTimeOffset;Bp.prototype.getMediaUrl=Bp.prototype.getMediaUrl;Bp.prototype.getAdvertiserName=Bp.prototype.getAdvertiserName;Bp.prototype.getCreativeAdId=Bp.prototype.getCreativeAdId;Bp.prototype.getAdId=Bp.prototype.getAdId;Bp.prototype.getVastMediaWidth=Bp.prototype.getVastMediaWidth;Bp.prototype.getVastMediaHeight=Bp.prototype.getVastMediaHeight;Bp.prototype.getVastMediaBitrate=Bp.prototype.getVastMediaBitrate;
740
740
  Bp.prototype.getDescription=Bp.prototype.getDescription;Bp.prototype.getTitle=Bp.prototype.getTitle;Bp.prototype.getPositionInSequence=Bp.prototype.getPositionInSequence;Bp.prototype.getSequenceLength=Bp.prototype.getSequenceLength;Bp.prototype.setMuted=Bp.prototype.setMuted;Bp.prototype.resize=Bp.prototype.resize;Bp.prototype.isLinear=Bp.prototype.isLinear;Bp.prototype.isMuted=Bp.prototype.isMuted;Bp.prototype.setVolume=Bp.prototype.setVolume;Bp.prototype.getVolume=Bp.prototype.getVolume;
741
741
  Bp.prototype.play=Bp.prototype.play;Bp.prototype.pause=Bp.prototype.pause;Bp.prototype.skip=Bp.prototype.skip;Bp.prototype.canSkipNow=Bp.prototype.canSkipNow;Bp.prototype.getTimeUntilSkippable=Bp.prototype.getTimeUntilSkippable;Bp.prototype.isSkippable=Bp.prototype.isSkippable;Bp.prototype.isPaused=Bp.prototype.isPaused;Bp.prototype.getRemainingTime=Bp.prototype.getRemainingTime;Bp.prototype.getMinSuggestedDuration=Bp.prototype.getMinSuggestedDuration;Bp.prototype.getDuration=Bp.prototype.getDuration;
742
742
  Bp.prototype.needsSkipUI=Bp.prototype.needsSkipUI;function Cp(){}S("shaka.ads.Utils",Cp);Cp.ADS_LOADED="ads-loaded";Cp.AD_STARTED="ad-started";Cp.AD_FIRST_QUARTILE="ad-first-quartile";Cp.AD_MIDPOINT="ad-midpoint";Cp.AD_THIRD_QUARTILE="ad-third-quartile";Cp.AD_COMPLETE="ad-complete";Cp.AD_STOPPED="ad-stopped";Cp.AD_SKIPPED="ad-skipped";Cp.AD_VOLUME_CHANGED="ad-volume-changed";Cp.AD_MUTED="ad-muted";Cp.AD_PAUSED="ad-paused";Cp.AD_RESUMED="ad-resumed";Cp.AD_SKIP_STATE_CHANGED="ad-skip-state-changed";Cp.CUEPOINTS_CHANGED="ad-cue-points-changed";
743
743
  Cp.IMA_AD_MANAGER_LOADED="ima-ad-manager-loaded";Cp.IMA_STREAM_MANAGER_LOADED="ima-stream-manager-loaded";Cp.AD_CLICKED="ad-clicked";Cp.AD_PROGRESS="ad-progress";Cp.AD_BUFFERING="ad-buffering";Cp.AD_IMPRESSION="ad-impression";Cp.AD_DURATION_CHANGED="ad-duration-changed";Cp.AD_CLOSED="ad-closed";Cp.AD_LOADED="ad-loaded";Cp.ALL_ADS_COMPLETED="all-ads-completed";Cp.AD_LINEAR_CHANGED="ad-linear-changed";Cp.AD_METADATA="ad-metadata";Cp.AD_RECOVERABLE_ERROR="ad-recoverable-error";Cp.AD_ERROR="ad-error";
744
- Cp.AD_BREAK_READY="ad-break-ready";Cp.AD_INTERACTION="ad-interaction";Cp.AD_CONTENT_PAUSE_REQUESTED="ad-content-pause-requested";Cp.AD_CONTENT_RESUME_REQUESTED="ad-content-resume-requested";Cp.AD_CONTENT_ATTACH_REQUESTED="ad-content-attach-requested";function Dp(a,b,c,d,e){var f=this;this.s=a;this.i=b;this.F=!1;this.A=this.o=null;this.G=NaN;this.l=e;this.j=null;this.h=new gb;google.ima.settings.setLocale(c);google.ima.settings.setDisableCustomPlaybackForIOS10Plus(!0);this.C=new google.ima.AdDisplayContainer(this.s,this.i);this.C.initialize();this.m=new google.ima.AdsLoader(this.C);this.m.getSettings().setPlayerType("shaka-player");this.m.getSettings().setPlayerVersion("v4.10.13");this.g=null;this.B=d||new google.ima.AdsRenderingSettings;this.h.D(this.m,
744
+ Cp.AD_BREAK_READY="ad-break-ready";Cp.AD_INTERACTION="ad-interaction";Cp.AD_CONTENT_PAUSE_REQUESTED="ad-content-pause-requested";Cp.AD_CONTENT_RESUME_REQUESTED="ad-content-resume-requested";Cp.AD_CONTENT_ATTACH_REQUESTED="ad-content-attach-requested";function Dp(a,b,c,d,e){var f=this;this.s=a;this.i=b;this.F=!1;this.A=this.o=null;this.G=NaN;this.l=e;this.j=null;this.h=new gb;google.ima.settings.setLocale(c);google.ima.settings.setDisableCustomPlaybackForIOS10Plus(!0);this.C=new google.ima.AdDisplayContainer(this.s,this.i);this.C.initialize();this.m=new google.ima.AdsLoader(this.C);this.m.getSettings().setPlayerType("shaka-player");this.m.getSettings().setPlayerVersion("v4.10.15");this.g=null;this.B=d||new google.ima.AdsRenderingSettings;this.h.D(this.m,
745
745
  google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,function(g){Ep(f,g)});this.h.D(this.m,google.ima.AdErrorEvent.Type.AD_ERROR,function(g){Fp(f,g)});this.h.D(this.i,"ended",function(){f.m.contentComplete()});this.h.ja(this.i,"play",function(){f.F=!0})}Dp.prototype.configure=function(a){this.o=a};Dp.prototype.stop=function(){this.g&&this.g.stop();this.s&&tn(this.s)};
746
746
  Dp.prototype.release=function(){this.stop();this.A&&this.A.disconnect();this.h&&this.h.release();this.g&&this.g.destroy();this.m.destroy();this.C.destroy()};function Fp(a,b){b.getError();b=(new Map).set("originalEvent",b);a.l(new U("ad-error",b));Gp(a,null);a.l(new U("ad-cue-points-changed",(new Map).set("cuepoints",[])))}
747
747
  function Ep(a,b){a.l(new U("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.G)));if(a.o.customPlayheadTracker){var c={currentTime:a.i.currentTime};a.g=b.getAdsManager(c,a.B);a.i.muted?a.g.setVolume(0):a.g.setVolume(a.i.volume);a.h.D(a.i,"timeupdate",function(){a.i.duration&&(c.currentTime=a.i.currentTime)});a.h.D(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.B);a.l(new U("ima-ad-manager-loaded",(new Map).set("imaAdManager",
@@ -754,39 +754,39 @@ a.h.D(a.g,google.ima.AdEvent.Type.PAUSED,function(c){a.j&&(a.j.i=!0,b(c,"ad-paus
754
754
  a.h.D(a.g,google.ima.AdEvent.Type.IMPRESSION,function(c){b(c,"ad-impression")});a.h.D(a.g,google.ima.AdEvent.Type.DURATION_CHANGE,function(c){b(c,"ad-duration-changed")});a.h.D(a.g,google.ima.AdEvent.Type.USER_CLOSE,function(c){b(c,"ad-closed")});a.h.D(a.g,google.ima.AdEvent.Type.LOADED,function(c){b(c,"ad-loaded")});a.h.D(a.g,google.ima.AdEvent.Type.ALL_ADS_COMPLETED,function(c){b(c,"all-ads-completed")});a.h.D(a.g,google.ima.AdEvent.Type.LINEAR_CHANGED,function(c){b(c,"ad-linear-changed")});a.h.D(a.g,
755
755
  google.ima.AdEvent.Type.AD_METADATA,function(c){b(c,"ad-metadata")});a.h.D(a.g,google.ima.AdEvent.Type.LOG,function(c){b(c,"ad-recoverable-error")});a.h.D(a.g,google.ima.AdEvent.Type.AD_BREAK_READY,function(c){b(c,"ad-break-ready")});a.h.D(a.g,google.ima.AdEvent.Type.INTERACTION,function(c){b(c,"ad-interaction")})}
756
756
  function Jp(a,b){var c=b.getAd();c?(a.j=new Bp(c,a.g,a.i),b.type!=google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED||a.o.supportsMultipleMediaElements||a.l(new U("ad-content-pause-requested")),b=(new Map).set("ad",a.j).set("sdkAdObject",c).set("originalEvent",b),a.l(new U("ad-started",b)),a.j.isLinear()&&(a.s.setAttribute("ad-active","true"),a.o.customPlayheadTracker||a.i.pause(),a.i.muted?(b=a.j,b.l=a.i.volume,b.h.setVolume(0)):a.j.setVolume(a.i.volume))):Ya("The IMA SDK fired a "+b.type+" event with no associated ad. Unable to play ad!")}
757
- function Gp(a,b){b&&b.type==google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED&&!a.o.supportsMultipleMediaElements&&a.l(new U("ad-content-resume-requested"));a.l(new U("ad-stopped",(new Map).set("originalEvent",b)));a.j&&a.j.isLinear()&&(a.s.removeAttribute("ad-active"),a.o.customPlayheadTracker||a.i.ended||a.i.play())};function Kp(a,b,c,d,e){this.g=a;this.h=b;this.j=c;this.l=d;this.i=e}r=Kp.prototype;r.needsSkipUI=function(){return!0};r.getDuration=function(){var a=this.g.duration;return isNaN(a)?-1:a};r.getMinSuggestedDuration=function(){return this.getDuration()};r.getRemainingTime=function(){var a=this.g.duration;return isNaN(a)?-1:a-this.g.currentTime};r.isPaused=function(){return this.g.paused};r.isSkippable=function(){return this.h};
758
- r.getTimeUntilSkippable=function(){return this.h?0:Math.max(this.getRemainingTime(),0)};r.canSkipNow=function(){return 0==this.getTimeUntilSkippable()};r.skip=function(){this.j()};r.pause=function(){return this.g.pause()};r.play=function(){return this.g.play()};r.getVolume=function(){return this.g.volume};r.setVolume=function(a){this.g.volume=a};r.isMuted=function(){return this.g.muted};r.isLinear=function(){return!0};r.resize=function(){};r.setMuted=function(a){this.g.muted=a};
759
- r.getSequenceLength=function(){return this.l};r.getPositionInSequence=function(){return this.i};r.getTitle=function(){return""};r.getDescription=function(){return""};r.getVastMediaBitrate=function(){return 0};r.getVastMediaHeight=function(){return 0};r.getVastMediaWidth=function(){return 0};r.getAdId=function(){return""};r.getCreativeAdId=function(){return""};r.getAdvertiserName=function(){return""};r.getMediaUrl=function(){return null};r.getTimeOffset=function(){return 0};r.getPodIndex=function(){return 0};
760
- r.release=function(){this.g=null};S("shaka.ads.InterstitialAd",Kp);Kp.prototype.release=Kp.prototype.release;Kp.prototype.getPodIndex=Kp.prototype.getPodIndex;Kp.prototype.getTimeOffset=Kp.prototype.getTimeOffset;Kp.prototype.getMediaUrl=Kp.prototype.getMediaUrl;Kp.prototype.getAdvertiserName=Kp.prototype.getAdvertiserName;Kp.prototype.getCreativeAdId=Kp.prototype.getCreativeAdId;Kp.prototype.getAdId=Kp.prototype.getAdId;Kp.prototype.getVastMediaWidth=Kp.prototype.getVastMediaWidth;
757
+ function Gp(a,b){b&&b.type==google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED&&!a.o.supportsMultipleMediaElements&&a.l(new U("ad-content-resume-requested"));a.l(new U("ad-stopped",(new Map).set("originalEvent",b)));a.j&&a.j.isLinear()&&(a.s.removeAttribute("ad-active"),a.o.customPlayheadTracker||a.i.ended||a.i.play())};function Kp(a,b,c,d,e){this.g=a;this.h=b;this.j=c;this.l=d;this.i=e}q=Kp.prototype;q.needsSkipUI=function(){return!0};q.getDuration=function(){var a=this.g.duration;return isNaN(a)?-1:a};q.getMinSuggestedDuration=function(){return this.getDuration()};q.getRemainingTime=function(){var a=this.g.duration;return isNaN(a)?-1:a-this.g.currentTime};q.isPaused=function(){return this.g.paused};q.isSkippable=function(){return this.h};
758
+ q.getTimeUntilSkippable=function(){return this.h?0:Math.max(this.getRemainingTime(),0)};q.canSkipNow=function(){return 0==this.getTimeUntilSkippable()};q.skip=function(){this.j()};q.pause=function(){return this.g.pause()};q.play=function(){return this.g.play()};q.getVolume=function(){return this.g.volume};q.setVolume=function(a){this.g.volume=a};q.isMuted=function(){return this.g.muted};q.isLinear=function(){return!0};q.resize=function(){};q.setMuted=function(a){this.g.muted=a};
759
+ q.getSequenceLength=function(){return this.l};q.getPositionInSequence=function(){return this.i};q.getTitle=function(){return""};q.getDescription=function(){return""};q.getVastMediaBitrate=function(){return 0};q.getVastMediaHeight=function(){return 0};q.getVastMediaWidth=function(){return 0};q.getAdId=function(){return""};q.getCreativeAdId=function(){return""};q.getAdvertiserName=function(){return""};q.getMediaUrl=function(){return null};q.getTimeOffset=function(){return 0};q.getPodIndex=function(){return 0};
760
+ q.release=function(){this.g=null};S("shaka.ads.InterstitialAd",Kp);Kp.prototype.release=Kp.prototype.release;Kp.prototype.getPodIndex=Kp.prototype.getPodIndex;Kp.prototype.getTimeOffset=Kp.prototype.getTimeOffset;Kp.prototype.getMediaUrl=Kp.prototype.getMediaUrl;Kp.prototype.getAdvertiserName=Kp.prototype.getAdvertiserName;Kp.prototype.getCreativeAdId=Kp.prototype.getCreativeAdId;Kp.prototype.getAdId=Kp.prototype.getAdId;Kp.prototype.getVastMediaWidth=Kp.prototype.getVastMediaWidth;
761
761
  Kp.prototype.getVastMediaHeight=Kp.prototype.getVastMediaHeight;Kp.prototype.getVastMediaBitrate=Kp.prototype.getVastMediaBitrate;Kp.prototype.getDescription=Kp.prototype.getDescription;Kp.prototype.getTitle=Kp.prototype.getTitle;Kp.prototype.getPositionInSequence=Kp.prototype.getPositionInSequence;Kp.prototype.getSequenceLength=Kp.prototype.getSequenceLength;Kp.prototype.setMuted=Kp.prototype.setMuted;Kp.prototype.resize=Kp.prototype.resize;Kp.prototype.isLinear=Kp.prototype.isLinear;
762
762
  Kp.prototype.isMuted=Kp.prototype.isMuted;Kp.prototype.setVolume=Kp.prototype.setVolume;Kp.prototype.getVolume=Kp.prototype.getVolume;Kp.prototype.play=Kp.prototype.play;Kp.prototype.pause=Kp.prototype.pause;Kp.prototype.skip=Kp.prototype.skip;Kp.prototype.canSkipNow=Kp.prototype.canSkipNow;Kp.prototype.getTimeUntilSkippable=Kp.prototype.getTimeUntilSkippable;Kp.prototype.isSkippable=Kp.prototype.isSkippable;Kp.prototype.isPaused=Kp.prototype.isPaused;Kp.prototype.getRemainingTime=Kp.prototype.getRemainingTime;
763
- Kp.prototype.getMinSuggestedDuration=Kp.prototype.getMinSuggestedDuration;Kp.prototype.getDuration=Kp.prototype.getDuration;Kp.prototype.needsSkipUI=Kp.prototype.needsSkipUI;function Lp(a,b,c,d){var e=this;this.F=a;this.B=b;this.i=c;this.C=null;this.m=!0;this.s=this.i;this.g=d;this.G=new Set;this.A=new Set;this.o=new Map;this.h=new Y;Mp(this);this.I=new gb;this.j=new gb;this.H=!1;this.l=null;this.I.D(this.i,"timeupdate",function(){if(!e.H){var f=null==e.l||0==e.l;e.l=e.i.currentTime;(f=Np(e,f))&&Op(e,f,1,1,Date.now())}});(new Sc(function(){var f,g,h,k,l,m,n,q,p,w;return O(function(u){switch(u.g){case 1:if(!e.A.size||e.H||null==e.l){u.u(0);break}f=!1;g=Array.from(e.A);
764
- h=e.B.Ob();k=t(g);l=k.next();case 3:if(l.done){u.u(5);break}m=l.value;n=m.endTime||m.startTime;if(!(1<=h.start-n)){q=m.startTime-e.l;0<q&&10>=q&&(e.o.has(m)||e.o.set(m,e.h.preload(m.uri)));u.u(4);break}if(!e.o.has(m)){u.u(7);break}return F(u,e.o.get(m),8);case 8:(p=u.h)&&p.destroy(),e.o.delete(m);case 7:w=JSON.stringify(m),e.G.has(w)&&e.G.delete(w),e.A.delete(m),f=!0;case 4:l=k.next();u.u(3);break;case 5:f&&Pp(e),H(u)}})})).Ra(1)}
763
+ Kp.prototype.getMinSuggestedDuration=Kp.prototype.getMinSuggestedDuration;Kp.prototype.getDuration=Kp.prototype.getDuration;Kp.prototype.needsSkipUI=Kp.prototype.needsSkipUI;function Lp(a,b,c,d){var e=this;this.F=a;this.B=b;this.i=c;this.C=null;this.m=!0;this.s=this.i;this.g=d;this.G=new Set;this.A=new Set;this.o=new Map;this.h=new Y;Mp(this);this.I=new gb;this.j=new gb;this.H=!1;this.l=null;this.I.D(this.i,"timeupdate",function(){if(!e.H){var f=null==e.l||0==e.l;e.l=e.i.currentTime;(f=Np(e,f))&&Op(e,f,1,1,Date.now())}});(new Sc(function(){var f,g,h,k,l,m,n,p,r,u;return O(function(v){switch(v.g){case 1:if(!e.A.size||e.H||null==e.l){v.u(0);break}f=!1;g=Array.from(e.A);
764
+ h=e.B.Ob();k=t(g);l=k.next();case 3:if(l.done){v.u(5);break}m=l.value;n=m.endTime||m.startTime;if(!(1<=h.start-n)){p=m.startTime-e.l;0<p&&10>=p&&(e.o.has(m)||e.o.set(m,e.h.preload(m.uri)));v.u(4);break}if(!e.o.has(m)){v.u(7);break}return F(v,e.o.get(m),8);case 8:(r=v.h)&&r.destroy(),e.o.delete(m);case 7:u=JSON.stringify(m),e.G.has(u)&&e.G.delete(u),e.A.delete(m),f=!0;case 4:l=k.next();v.u(3);break;case 5:f&&Pp(e),H(v)}})})).Ra(1)}
765
765
  Lp.prototype.configure=function(a){this.F&&this.m==a.supportsMultipleMediaElements&&((this.m=!a.supportsMultipleMediaElements)?(this.s=this.i,this.C&&(this.C.parentElement&&this.F.removeChild(this.C),this.C=null)):(this.C||(a=document.createElement(this.i.tagName),a.autoplay=!0,a.style.position="absolute",a.style.top="0",a.style.left="0",a.style.width="100%",a.style.height="100%",a.style.backgroundColor="rgb(0, 0, 0)",a.setAttribute("playsinline",""),this.C=a),this.s=this.C))};
766
766
  Lp.prototype.stop=function(){this.j&&this.j.Qa();this.G.clear();this.A.clear();this.h.Pe();this.o.clear();this.h.detach();this.H=!1;this.l=null};Lp.prototype.release=function(){this.stop();this.I&&this.I.release();this.j&&this.j.release();this.F&&tn(this.F);this.h.destroy()};
767
767
  function Qp(a,b){var c,d,e,f,g,h,k,l;O(function(m){if(1==m.g){if(a.B.yg()==ep&&a.m)return Ya("Unsupported interstitial when using single media element",b),m.return();Mp(a);c=!1;return F(m,Rp(a,b),2)}d=m.h;if(d.length)for(e=t(d),f=e.next();!f.done;f=e.next())(g=f.value,h=JSON.stringify(g),a.G.has(h))||(c=!0,a.G.add(h),a.A.add(g),k=!1,b.Ab&&null==a.l?k=!0:0!=g.startTime||g.He?null!=a.l&&(l=b.startTime-a.l,0<l&&10>=l&&(k=!0)):k=!0,k&&(a.o.has(g)||a.o.set(g,a.h.preload(g.uri))));else Ya("Unsupported interstitial",
768
768
  b);c&&Pp(a);H(m)})}function Np(a,b,c){c=void 0===c?0:c;var d=0,e=null;if(a.A.size&&null!=a.l){var f=a.i.ended,g=Array.from(a.A).sort(function(l,m){return m.startTime-l.startTime});g=t(g);for(var h=g.next();!h.done;h=g.next()){h=h.value;var k=!1;b?k=h.Ab:f?k=h.pc:h.Ab||h.pc||(k=a.l-Math.round(1E3*h.startTime)/1E3,k=0<k&&(1>=k||!h.He));if(k){if(d==c){e=h;break}d++}}}return e}
769
- function Op(a,b,c,d,e,f){f=void 0===f?0:f;var g,h,k,l,m,n,q,p,w,u,v,A,z,D;O(function(y){switch(y.g){case 1:g=Date.now();!a.s.parentElement&&a.F&&a.F.appendChild(a.s);1==d&&1==c&&(c=Array.from(a.A).filter(function(B){return b.Ab?B.Ab==b.Ab:b.pc?B.pc==b.pc:.001>Math.abs(B.startTime-b.startTime)}).length);if(b.once||b.Ab)f++,a.A.delete(b),Pp(a);a.H=!0;if(!a.m||1!=d){y.u(2);break}a.g(new U("ad-content-pause-requested",(new Map).set("saveLivePosition",!0)));h=new bg;k=function(B){return O(function(C){if(1==
770
- C.g)return"detach"!=B.state?C.u(0):od()?F(C,new Promise(function(E){return(new Sc(E)).Z(.1)}),3):C.u(3);h.resolve();a.j.jb(a.B,"onstatechange",k);H(C)})};a.j.D(a.B,"onstatechange",k);return F(y,h,2);case 2:return a.m||(a.i.pause(),null!=b.Nc&&0!=b.Nc&&(a.i.currentTime+=b.Nc)),l=!1,m=null,n=function(){if(!a.m&&null==b.Nc)if(b.re&&b.endTime&&Infinity!=b.endTime)a.i.currentTime!=b.endTime&&(a.i.currentTime=b.endTime);else{var B=Date.now();a.i.currentTime+=(B-e)/1E3;e=B}},q=function(){var B,C;return O(function(E){if(1==
771
- E.g)return n(),m&&m.stop(),(B=Np(a,b.Ab,d-f))?(a.g(new U("ad-stopped")),a.j.Qa(),Op(a,B,c,++d,e,f),E.u(0)):a.m?F(E,a.h.detach(),4):F(E,a.h.cc(),4);a.m&&(C=b.Nc,null==C&&(C=b.re&&b.endTime&&Infinity!=b.endTime?b.endTime-(a.l||0):(Date.now()-e)/1E3),a.g(new U("ad-content-resume-requested",(new Map).set("offset",C))));a.g(new U("ad-stopped"));a.j.Qa();a.H=!1;a.m||(n(),a.i.ended||a.i.play());H(E)})},p=function(B){return O(function(C){if(l)return C.return();l=!0;a.g(new U("ad-error",(new Map).set("originalEvent",
772
- B)));return F(C,q(),0)})},w=function(){return O(function(B){if(1==B.g){if(l)return B.return();l=!0;return F(B,q(),2)}a.g(new U("ad-complete"));H(B)})},u=function(){return O(function(B){if(l)return B.return();l=!0;a.g(new U("ad-skipped"));return F(B,q(),0)})},v=new Kp(a.s,b.isSkippable,u,c,d),a.m||(v.setMuted(a.i.muted),v.setVolume(a.i.volume)),a.g(new U("ad-started",(new Map).set("ad",v))),v.canSkipNow()&&a.g(new U("ad-skip-state-changed")),a.j.ja(a.h,"error",p),a.j.ja(a.h,"firstquartile",function(){n();
773
- a.g(new U("ad-first-quartile"))}),a.j.ja(a.h,"midpoint",function(){n();a.g(new U("ad-midpoint"))}),a.j.ja(a.h,"thirdquartile",function(){n();a.g(new U("ad-third-quartile"))}),a.j.ja(a.h,"complete",w),a.j.D(a.s,"play",function(){a.g(new U("ad-resumed"))}),a.j.D(a.s,"pause",function(){a.g(new U("ad-paused"))}),a.j.D(a.s,"volumechange",function(){a.s.muted?a.g(new U("ad-muted")):a.g(new U("ad-volume-changed"))}),ra(y,4),b.Ef&&(m=(new Sc(function(){v.skip()})).Z(b.Ef)),Mp(a),F(y,a.h.Rb(a.s),6);case 6:return a.o.has(b)?
774
- F(y,a.o.get(b),10):F(y,a.h.load(b.uri),8);case 10:return A=y.h,a.o.delete(b),A?F(y,a.h.load(A),8):F(y,a.h.load(b.uri),8);case 8:z=(Date.now()-g)/1E3;a.g(new U("ads-loaded",(new Map).set("loadTime",z)));a.m&&a.i.play();ta(y,0);break;case 4:D=ua(y),p(D),H(y)}})}
775
- function Rp(a,b){var c,d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L,K,I,J,N,M,P,R;return O(function(Q){switch(Q.g){case 1:c=[];if(!b)return Q.return(c);d=b.values.find(function(X){return"X-ASSET-URI"==X.key});e=b.values.find(function(X){return"X-ASSET-LIST"==X.key});if(!d&&!e)return Q.return(c);f=b.values.find(function(X){return"X-RESTRICT"==X.key});h=g=!0;f&&f.data&&(k=f.data,g=!k.includes("SKIP"),h=!k.includes("JUMP"));l=null;if(m=b.values.find(function(X){return"X-RESUME-OFFSET"==X.key}))n=m.data,
776
- l=parseFloat(n),isNaN(l)&&(l=null);q=null;if(p=b.values.find(function(X){return"X-PLAYOUT-LIMIT"==X.key}))w=p.data,q=parseFloat(w),isNaN(q)&&(q=null);A=v=u=!1;if(z=b.values.find(function(X){return"CUE"==X.key}))D=z.data,u=D.includes("ONCE"),v=D.includes("PRE"),A=D.includes("POST");y=!1;(B=b.values.find(function(X){return"X-TIMELINE-OCCUPIES"==X.key}))?(C=B.data,y=C.includes("RANGE")):!m&&a.B.V()&&(y=!v&&!A);if(d){E=d.data;if(!E)return Q.return(c);c.push({startTime:b.startTime,endTime:b.endTime,uri:E,
777
- isSkippable:g,He:h,Nc:l,Ef:q,once:u,Ab:v,pc:A,re:y});Q.u(2);break}if(!e){Q.u(2);break}G=e.data;if(!G)return Q.return(c);L=tg([G],$f());K=a.B.xb().request(7,L);ra(Q,4);return F(Q,K.promise,6);case 6:I=Q.h;J=ud(I.data);N=JSON.parse(J);M=t(N.ASSETS);for(P=M.next();!P.done;P=M.next())R=P.value,R.URI&&c.push({startTime:b.startTime,endTime:b.endTime,uri:R.URI,isSkippable:g,He:h,Nc:l,Ef:q,once:u,Ab:v,pc:A,re:y});ta(Q,2);break;case 4:ua(Q);case 2:return Q.return(c)}})}
778
- function Pp(a){for(var b=[],c=t(a.A),d=c.next(),e={};!d.done;e={Qb:void 0},d=c.next())d=d.value,e.Qb={start:d.startTime,end:null},d.Ab?(e.Qb.start=0,e.Qb.end=null):d.pc?(e.Qb.start=-1,e.Qb.end=null):d.re&&(e.Qb.end=d.endTime),b.find(function(f){return function(g){return f.Qb.start==g.start&&f.Qb.end==g.end}}(e))||b.push(e.Qb);a.g(new U("ad-cue-points-changed",(new Map).set("cuepoints",b)))}function Mp(a){a.h.configure(a.B.Ag());var b=a.h.xb();b.mg();b.ng();sg(a.B.xb(),b)};function Sp(a){this.h=a||"";this.g=0}function Tp(a){Up(a,/[ \t]+/gm)}function Up(a,b){b.lastIndex=a.g;b=b.exec(a.h);b=null==b?null:{position:b.index,length:b[0].length,results:b};if(a.g==a.h.length||null==b||b.position!=a.g)return null;a.g+=b.length;return b.results}function Vp(a){return a.g==a.h.length?null:(a=Up(a,/[^ \t\n]*/gm))?a[0]:null};function Wp(a,b,c,d,e){this.h=a;if(a=this.h.skipOffset)if(a=Up(new Sp(a),Xp),null==a)a=null;else{var f=Number(a[2]),g=Number(a[3]);a=59<f||59<g?null:(Number(a[4])||0)/1E3+g+60*f+3600*(Number(a[1])||0)}else a=null;this.j=a;this.g=e;this.i=b;this.l=c;this.o=d;this.m=!1}r=Wp.prototype;r.needsSkipUI=function(){return!0};r.getDuration=function(){return this.h.durationInSeconds};r.getMinSuggestedDuration=function(){return this.getDuration()};
779
- r.getRemainingTime=function(){return this.h.startTimeInSeconds+this.h.durationInSeconds-this.g.currentTime};r.isPaused=function(){return this.g.paused};r.isSkippable=function(){return"number"==typeof this.j?!0:!1};r.getTimeUntilSkippable=function(){if("number"!=typeof this.j)return this.getRemainingTime();var a=this.getRemainingTime()+this.j-this.getDuration();return Math.max(a,0)};r.canSkipNow=function(){return 0==this.getTimeUntilSkippable()};r.skip=function(){this.m=!0;this.g.currentTime+=this.getRemainingTime()};
780
- r.pause=function(){return this.g.pause()};r.play=function(){return this.g.play()};r.getVolume=function(){return this.g.volume};r.setVolume=function(a){this.g.volume=a};r.isMuted=function(){return this.g.muted};r.isLinear=function(){return this.o};r.resize=function(){};r.setMuted=function(a){this.g.muted=a};r.getSequenceLength=function(){return this.l?this.l:1};r.getPositionInSequence=function(){return this.i?this.i:1};r.getTitle=function(){return this.h.adTitle};r.getDescription=function(){return""};
781
- r.getVastMediaBitrate=function(){return 0};r.getVastMediaHeight=function(){return 0};r.getVastMediaWidth=function(){return 0};r.getAdId=function(){return this.h.adId};r.getCreativeAdId=function(){return this.h.creativeId};r.getAdvertiserName=function(){return""};r.getMediaUrl=function(){return null};r.getTimeOffset=function(){return 0};r.getPodIndex=function(){return 0};r.release=function(){this.l=this.i=this.g=this.h=null};S("shaka.ads.MediaTailorAd",Wp);Wp.prototype.release=Wp.prototype.release;
769
+ function Op(a,b,c,d,e,f){f=void 0===f?0:f;var g,h,k,l,m,n,p,r,u,v,w,A,z,D;O(function(y){switch(y.g){case 1:g=Date.now();!a.s.parentElement&&a.F&&a.F.appendChild(a.s);1==d&&1==c&&(c=Array.from(a.A).filter(function(B){return b.Ab?B.Ab==b.Ab:b.pc?B.pc==b.pc:.001>Math.abs(B.startTime-b.startTime)}).length);if(b.once||b.Ab)f++,a.A.delete(b),Pp(a);a.H=!0;if(!a.m||1!=d){y.u(2);break}a.g(new U("ad-content-pause-requested",(new Map).set("saveLivePosition",!0)));h=new bg;k=function(B){return O(function(C){if(1==
770
+ C.g)return"detach"!=B.state?C.u(0):od()?F(C,new Promise(function(E){return(new Sc(E)).Z(.1)}),3):C.u(3);h.resolve();a.j.jb(a.B,"onstatechange",k);H(C)})};a.j.D(a.B,"onstatechange",k);return F(y,h,2);case 2:return a.m||(a.i.pause(),null!=b.Oc&&0!=b.Oc&&(a.i.currentTime+=b.Oc)),l=!1,m=null,n=function(){if(!a.m&&null==b.Oc)if(b.re&&b.endTime&&Infinity!=b.endTime)a.i.currentTime!=b.endTime&&(a.i.currentTime=b.endTime);else{var B=Date.now();a.i.currentTime+=(B-e)/1E3;e=B}},p=function(){var B,C;return O(function(E){if(1==
771
+ E.g)return n(),m&&m.stop(),(B=Np(a,b.Ab,d-f))?(a.g(new U("ad-stopped")),a.j.Qa(),Op(a,B,c,++d,e,f),E.u(0)):a.m?F(E,a.h.detach(),4):F(E,a.h.cc(),4);a.m&&(C=b.Oc,null==C&&(C=b.re&&b.endTime&&Infinity!=b.endTime?b.endTime-(a.l||0):(Date.now()-e)/1E3),a.g(new U("ad-content-resume-requested",(new Map).set("offset",C))));a.g(new U("ad-stopped"));a.j.Qa();a.H=!1;a.m||(n(),a.i.ended||a.i.play());H(E)})},r=function(B){return O(function(C){if(l)return C.return();l=!0;a.g(new U("ad-error",(new Map).set("originalEvent",
772
+ B)));return F(C,p(),0)})},u=function(){return O(function(B){if(1==B.g){if(l)return B.return();l=!0;return F(B,p(),2)}a.g(new U("ad-complete"));H(B)})},v=function(){return O(function(B){if(l)return B.return();l=!0;a.g(new U("ad-skipped"));return F(B,p(),0)})},w=new Kp(a.s,b.isSkippable,v,c,d),a.m||(w.setMuted(a.i.muted),w.setVolume(a.i.volume)),a.g(new U("ad-started",(new Map).set("ad",w))),w.canSkipNow()&&a.g(new U("ad-skip-state-changed")),a.j.ja(a.h,"error",r),a.j.ja(a.h,"firstquartile",function(){n();
773
+ a.g(new U("ad-first-quartile"))}),a.j.ja(a.h,"midpoint",function(){n();a.g(new U("ad-midpoint"))}),a.j.ja(a.h,"thirdquartile",function(){n();a.g(new U("ad-third-quartile"))}),a.j.ja(a.h,"complete",u),a.j.D(a.s,"play",function(){a.g(new U("ad-resumed"))}),a.j.D(a.s,"pause",function(){a.g(new U("ad-paused"))}),a.j.D(a.s,"volumechange",function(){a.s.muted?a.g(new U("ad-muted")):a.g(new U("ad-volume-changed"))}),ra(y,4),b.Ef&&(m=(new Sc(function(){w.skip()})).Z(b.Ef)),Mp(a),F(y,a.h.Rb(a.s),6);case 6:return a.o.has(b)?
774
+ F(y,a.o.get(b),10):F(y,a.h.load(b.uri),8);case 10:return A=y.h,a.o.delete(b),A?F(y,a.h.load(A),8):F(y,a.h.load(b.uri),8);case 8:z=(Date.now()-g)/1E3;a.g(new U("ads-loaded",(new Map).set("loadTime",z)));a.m&&a.i.play();ta(y,0);break;case 4:D=ua(y),r(D),H(y)}})}
775
+ function Rp(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L,K,I,J,M,N,P,R;return O(function(Q){switch(Q.g){case 1:c=[];if(!b)return Q.return(c);d=b.values.find(function(X){return"X-ASSET-URI"==X.key});e=b.values.find(function(X){return"X-ASSET-LIST"==X.key});if(!d&&!e)return Q.return(c);f=b.values.find(function(X){return"X-RESTRICT"==X.key});h=g=!0;f&&f.data&&(k=f.data,g=!k.includes("SKIP"),h=!k.includes("JUMP"));l=null;if(m=b.values.find(function(X){return"X-RESUME-OFFSET"==X.key}))n=m.data,
776
+ l=parseFloat(n),isNaN(l)&&(l=null);p=null;if(r=b.values.find(function(X){return"X-PLAYOUT-LIMIT"==X.key}))u=r.data,p=parseFloat(u),isNaN(p)&&(p=null);A=w=v=!1;if(z=b.values.find(function(X){return"CUE"==X.key}))D=z.data,v=D.includes("ONCE"),w=D.includes("PRE"),A=D.includes("POST");y=!1;(B=b.values.find(function(X){return"X-TIMELINE-OCCUPIES"==X.key}))?(C=B.data,y=C.includes("RANGE")):!m&&a.B.V()&&(y=!w&&!A);if(d){E=d.data;if(!E)return Q.return(c);c.push({startTime:b.startTime,endTime:b.endTime,uri:E,
777
+ isSkippable:g,He:h,Oc:l,Ef:p,once:v,Ab:w,pc:A,re:y});Q.u(2);break}if(!e){Q.u(2);break}G=e.data;if(!G)return Q.return(c);L=tg([G],$f());K=a.B.xb().request(7,L);ra(Q,4);return F(Q,K.promise,6);case 6:I=Q.h;J=ud(I.data);M=JSON.parse(J);N=t(M.ASSETS);for(P=N.next();!P.done;P=N.next())R=P.value,R.URI&&c.push({startTime:b.startTime,endTime:b.endTime,uri:R.URI,isSkippable:g,He:h,Oc:l,Ef:p,once:v,Ab:w,pc:A,re:y});ta(Q,2);break;case 4:ua(Q);case 2:return Q.return(c)}})}
778
+ function Pp(a){for(var b=[],c=t(a.A),d=c.next(),e={};!d.done;e={Qb:void 0},d=c.next())d=d.value,e.Qb={start:d.startTime,end:null},d.Ab?(e.Qb.start=0,e.Qb.end=null):d.pc?(e.Qb.start=-1,e.Qb.end=null):d.re&&(e.Qb.end=d.endTime),b.find(function(f){return function(g){return f.Qb.start==g.start&&f.Qb.end==g.end}}(e))||b.push(e.Qb);a.g(new U("ad-cue-points-changed",(new Map).set("cuepoints",b)))}function Mp(a){a.h.configure(a.B.Ag());var b=a.h.xb();b.mg();b.ng();sg(a.B.xb(),b)};function Sp(a){this.h=a||"";this.g=0}function Tp(a){Up(a,/[ \t]+/gm)}function Up(a,b){b.lastIndex=a.g;b=b.exec(a.h);b=null==b?null:{position:b.index,length:b[0].length,results:b};if(a.g==a.h.length||null==b||b.position!=a.g)return null;a.g+=b.length;return b.results}function Vp(a){return a.g==a.h.length?null:(a=Up(a,/[^ \t\n]*/gm))?a[0]:null};function Wp(a,b,c,d,e){this.h=a;if(a=this.h.skipOffset)if(a=Up(new Sp(a),Xp),null==a)a=null;else{var f=Number(a[2]),g=Number(a[3]);a=59<f||59<g?null:(Number(a[4])||0)/1E3+g+60*f+3600*(Number(a[1])||0)}else a=null;this.j=a;this.g=e;this.i=b;this.l=c;this.o=d;this.m=!1}q=Wp.prototype;q.needsSkipUI=function(){return!0};q.getDuration=function(){return this.h.durationInSeconds};q.getMinSuggestedDuration=function(){return this.getDuration()};
779
+ q.getRemainingTime=function(){return this.h.startTimeInSeconds+this.h.durationInSeconds-this.g.currentTime};q.isPaused=function(){return this.g.paused};q.isSkippable=function(){return"number"==typeof this.j?!0:!1};q.getTimeUntilSkippable=function(){if("number"!=typeof this.j)return this.getRemainingTime();var a=this.getRemainingTime()+this.j-this.getDuration();return Math.max(a,0)};q.canSkipNow=function(){return 0==this.getTimeUntilSkippable()};q.skip=function(){this.m=!0;this.g.currentTime+=this.getRemainingTime()};
780
+ q.pause=function(){return this.g.pause()};q.play=function(){return this.g.play()};q.getVolume=function(){return this.g.volume};q.setVolume=function(a){this.g.volume=a};q.isMuted=function(){return this.g.muted};q.isLinear=function(){return this.o};q.resize=function(){};q.setMuted=function(a){this.g.muted=a};q.getSequenceLength=function(){return this.l?this.l:1};q.getPositionInSequence=function(){return this.i?this.i:1};q.getTitle=function(){return this.h.adTitle};q.getDescription=function(){return""};
781
+ q.getVastMediaBitrate=function(){return 0};q.getVastMediaHeight=function(){return 0};q.getVastMediaWidth=function(){return 0};q.getAdId=function(){return this.h.adId};q.getCreativeAdId=function(){return this.h.creativeId};q.getAdvertiserName=function(){return""};q.getMediaUrl=function(){return null};q.getTimeOffset=function(){return 0};q.getPodIndex=function(){return 0};q.release=function(){this.l=this.i=this.g=this.h=null};S("shaka.ads.MediaTailorAd",Wp);Wp.prototype.release=Wp.prototype.release;
782
782
  Wp.prototype.getPodIndex=Wp.prototype.getPodIndex;Wp.prototype.getTimeOffset=Wp.prototype.getTimeOffset;Wp.prototype.getMediaUrl=Wp.prototype.getMediaUrl;Wp.prototype.getAdvertiserName=Wp.prototype.getAdvertiserName;Wp.prototype.getCreativeAdId=Wp.prototype.getCreativeAdId;Wp.prototype.getAdId=Wp.prototype.getAdId;Wp.prototype.getVastMediaWidth=Wp.prototype.getVastMediaWidth;Wp.prototype.getVastMediaHeight=Wp.prototype.getVastMediaHeight;Wp.prototype.getVastMediaBitrate=Wp.prototype.getVastMediaBitrate;
783
783
  Wp.prototype.getDescription=Wp.prototype.getDescription;Wp.prototype.getTitle=Wp.prototype.getTitle;Wp.prototype.getPositionInSequence=Wp.prototype.getPositionInSequence;Wp.prototype.getSequenceLength=Wp.prototype.getSequenceLength;Wp.prototype.setMuted=Wp.prototype.setMuted;Wp.prototype.resize=Wp.prototype.resize;Wp.prototype.isLinear=Wp.prototype.isLinear;Wp.prototype.isMuted=Wp.prototype.isMuted;Wp.prototype.setVolume=Wp.prototype.setVolume;Wp.prototype.getVolume=Wp.prototype.getVolume;
784
784
  Wp.prototype.play=Wp.prototype.play;Wp.prototype.pause=Wp.prototype.pause;Wp.prototype.skip=Wp.prototype.skip;Wp.prototype.canSkipNow=Wp.prototype.canSkipNow;Wp.prototype.getTimeUntilSkippable=Wp.prototype.getTimeUntilSkippable;Wp.prototype.isSkippable=Wp.prototype.isSkippable;Wp.prototype.isPaused=Wp.prototype.isPaused;Wp.prototype.getRemainingTime=Wp.prototype.getRemainingTime;Wp.prototype.getMinSuggestedDuration=Wp.prototype.getMinSuggestedDuration;Wp.prototype.getDuration=Wp.prototype.getDuration;
785
785
  Wp.prototype.needsSkipUI=Wp.prototype.needsSkipUI;var Xp=/(?:(\d{1,}):)?(\d{2}):(\d{2})((\.(\d{1,3})))?/g;function Yp(a,b,c,d){this.B=a;this.K=b;this.h=c;this.l=null;this.T=NaN;this.i=d;this.I=!1;this.A=null;this.j=[];this.N=[];this.L=this.C=this.g=null;this.F=new Map;this.m=[];this.s=[];this.G="";this.O=!0;this.H="";this.o=new gb}Yp.prototype.stop=function(){for(var a=t(this.m),b=a.next();!b.done;b=a.next())b=b.value,this.o.jb(b.target,b.type,b.listener);Zp(this);this.m=[];this.s=[];this.G="";this.O=!0;this.H="";this.A=null;this.j=[];this.N=[];this.F.clear()};
786
786
  Yp.prototype.release=function(){this.stop();this.o&&this.o.release()};Yp.prototype.onManifestUpdated=function(a){this.I=a;""!=this.G&&($p(this,this.G,this.O),this.O=!1)};Yp.prototype.getCuePoints=function(){for(var a=[],b=t(this.j),c=b.next();!c.done;c=b.next()){c=t(c.value.ads);for(var d=c.next();!d.done;d=c.next())d=d.value,a.push({start:d.startTimeInSeconds,end:d.startTimeInSeconds+d.durationInSeconds})}return a};
787
- function aq(a,b,c){var d,e,f,g,h,k,l,m,n,q,p;O(function(w){if(1==w.g)return d=tg([b],$f()),d.method="POST",c&&(e=JSON.stringify(c),d.body=zd(e)),f=a.K.request(7,d),ra(w,2),F(w,f.promise,4);if(2!=w.g){g=w.h;h=ud(g.data);k=JSON.parse(h);if(k.manifestUrl&&k.trackingUrl)l=new tc(b),m=new tc(k.trackingUrl),a.G=l.resolve(m).toString(),n=Date.now()/1E3,q=n-a.T,a.i(new U("ads-loaded",(new Map).set("loadTime",q))),p=new tc(k.manifestUrl),a.l.resolve(l.resolve(p).toString()),a.l=null;else throw Error("Insufficient data from MediaTailor.");
788
- return ta(w,0)}ua(w);if(!a.H.length)return a.l.reject("MediaTailor request returned an error and there was no backup asset uri provided."),a.l=null,w.return();a.l.resolve(a.H);a.l=null;H(w)})}
789
- function $p(a,b,c){var d,e,f,g,h,k,l,m,n,q,p,w,u,v,A;O(function(z){if(1==z.g)return d=tg([b],$f()),e=a.K.request(7,d),ra(z,2),F(z,e.promise,4);if(2!=z.g){f=z.h;g=[];h=ud(f.data);k=JSON.parse(h);if(0<k.avails.length){if(JSON.stringify(a.j)!=JSON.stringify(k.avails)){a.j=k.avails;l=t(a.j);for(m=l.next();!m.done;m=l.next())for(n=m.value,q=t(n.nonLinearAdsList),p=q.next();!p.done;p=q.next())for(w=p.value,u=t(w.nonLinearAdList),v=u.next();!v.done;v=u.next())A=v.value,bq(a,A);g=a.getCuePoints();a.i(new U("ad-cue-points-changed",
787
+ function aq(a,b,c){var d,e,f,g,h,k,l,m,n,p,r;O(function(u){if(1==u.g)return d=tg([b],$f()),d.method="POST",c&&(e=JSON.stringify(c),d.body=zd(e)),f=a.K.request(7,d),ra(u,2),F(u,f.promise,4);if(2!=u.g){g=u.h;h=ud(g.data);k=JSON.parse(h);if(k.manifestUrl&&k.trackingUrl)l=new tc(b),m=new tc(k.trackingUrl),a.G=l.resolve(m).toString(),n=Date.now()/1E3,p=n-a.T,a.i(new U("ads-loaded",(new Map).set("loadTime",p))),r=new tc(k.manifestUrl),a.l.resolve(l.resolve(r).toString()),a.l=null;else throw Error("Insufficient data from MediaTailor.");
788
+ return ta(u,0)}ua(u);if(!a.H.length)return a.l.reject("MediaTailor request returned an error and there was no backup asset uri provided."),a.l=null,u.return();a.l.resolve(a.H);a.l=null;H(u)})}
789
+ function $p(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A;O(function(z){if(1==z.g)return d=tg([b],$f()),e=a.K.request(7,d),ra(z,2),F(z,e.promise,4);if(2!=z.g){f=z.h;g=[];h=ud(f.data);k=JSON.parse(h);if(0<k.avails.length){if(JSON.stringify(a.j)!=JSON.stringify(k.avails)){a.j=k.avails;l=t(a.j);for(m=l.next();!m.done;m=l.next())for(n=m.value,p=t(n.nonLinearAdsList),r=p.next();!r.done;r=p.next())for(u=r.value,v=t(u.nonLinearAdList),w=v.next();!w.done;w=v.next())A=w.value,bq(a,A);g=a.getCuePoints();a.i(new U("ad-cue-points-changed",
790
790
  (new Map).set("cuepoints",g)))}}else a.j.length&&a.i(new U("ad-cue-points-changed",(new Map).set("cuepoints",g))),Zp(a),a.j=[];c&&(a.I||0<g.length)&&cq(a);return ta(z,0)}ua(z);H(z)})}
791
791
  function bq(a,b){var c,d,e,f,g,h,k,l;O(function(m){if(1==m.g){if(!b.staticResource)return m.return();c=dq(b);if(d=a.F.get(c))return m.return();e=tg([b.staticResource],$f());f=a.K.request(7,e);ra(m,2);a.F.set(c,[]);return F(m,f.promise,4)}if(2!=m.g)return g=m.h,h=ud(g.data),k=JSON.parse(h),l=k.apps,a.F.set(c,l),ta(m,0);ua(m);a.F.delete(c);H(m)})}
792
792
  function dq(a){return[a.adId,a.adParameters,a.adSystem,a.adTitle,a.creativeAdId,a.creativeId,a.creativeSequence,a.height,a.width,a.staticResource].join("")}function cq(a){eq(a);a.I||(fq(a),a.o.D(a.h,"seeked",function(){fq(a)}),a.o.D(a.h,"ended",function(){Zp(a)}));a.o.D(a.h,"timeupdate",function(){eq(a)})}
@@ -800,10 +800,10 @@ function hq(a){var b=!1;a.h.paused?b=!0:(gq(a,"impression"),gq(a,"start"));a.m.p
800
800
  d.type,d.listener)}
801
801
  function gq(a,b){var c=a.C.trackingEvents.find(function(e){return e.eventType==b});c||(c=a.L.adBreakTrackingEvents.find(function(e){return e.eventType==b}));if(c){c=t(c.beaconUrls);for(var d=c.next();!d.done;d=c.next())(d=d.value)&&""!=d&&(d=tg([d],$f()),d.method="POST",a.K.request(7,d))}switch(b){case "impression":a.i(new U("ad-impression"));break;case "start":a.i(new U("ad-started",(new Map).set("ad",a.g)));break;case "mute":a.i(new U("ad-muted"));break;case "unmute":a.i(new U("ad-volume-changed"));break;
802
802
  case "resume":a.i(new U("ad-resumed"));break;case "pause":a.i(new U("ad-paused"));break;case "firstQuartile":a.i(new U("ad-first-quartile"));break;case "midpoint":a.i(new U("ad-midpoint"));break;case "thirdQuartile":a.i(new U("ad-third-quartile"));break;case "complete":a.i(new U("ad-complete"));a.i(new U("ad-stopped"));break;case "skip":a.i(new U("ad-skipped"));a.i(new U("ad-stopped"));break;case "breakStart":a.B.setAttribute("ad-active","true");break;case "breakEnd":a.B.removeAttribute("ad-active");
803
- break;case "skipStateChanged":a.i(new U("ad-skip-state-changed"))}};function iq(a,b){this.g=a;this.i=null;this.h=b}r=iq.prototype;r.needsSkipUI=function(){return!0};r.getDuration=function(){return this.i?this.i.duration:-1};r.getMinSuggestedDuration=function(){return this.getDuration()};r.getRemainingTime=function(){return this.i?this.i.duration-this.i.currentTime:-1};r.isPaused=function(){return this.h.paused};r.isSkippable=function(){return this.g.isSkippable()};
804
- r.getTimeUntilSkippable=function(){var a=this.g.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};r.canSkipNow=function(){return 0==this.getTimeUntilSkippable()};r.skip=function(){this.h.currentTime+=this.getRemainingTime()};r.pause=function(){return this.h.pause()};r.play=function(){return this.h.play()};r.getVolume=function(){return this.h.volume};r.setVolume=function(a){this.h.volume=a};r.isMuted=function(){return this.h.muted};r.isLinear=function(){return!0};r.resize=function(){};
805
- r.setMuted=function(a){this.h.muted=a};r.getSequenceLength=function(){var a=this.g.getAdPodInfo();return null==a?1:a.getTotalAds()};r.getPositionInSequence=function(){var a=this.g.getAdPodInfo();return null==a?1:a.getAdPosition()};r.getTitle=function(){return this.g.getTitle()};r.getDescription=function(){return this.g.getDescription()};r.getVastMediaBitrate=function(){return 0};r.getVastMediaHeight=function(){return this.g.getVastMediaHeight()};r.getVastMediaWidth=function(){return this.g.getVastMediaWidth()};
806
- r.getAdId=function(){return this.g.getAdId()};r.getCreativeAdId=function(){return this.g.getCreativeAdId()};r.getAdvertiserName=function(){return this.g.getAdvertiserName()};r.getMediaUrl=function(){return null};r.getTimeOffset=function(){var a=this.g.getAdPodInfo();return null==a?0:a.getTimeOffset()};r.getPodIndex=function(){var a=this.g.getAdPodInfo();return null==a?0:a.getPodIndex()};r.release=function(){this.h=this.i=this.g=null};S("shaka.ads.ServerSideAd",iq);iq.prototype.release=iq.prototype.release;
803
+ break;case "skipStateChanged":a.i(new U("ad-skip-state-changed"))}};function iq(a,b){this.g=a;this.i=null;this.h=b}q=iq.prototype;q.needsSkipUI=function(){return!0};q.getDuration=function(){return this.i?this.i.duration:-1};q.getMinSuggestedDuration=function(){return this.getDuration()};q.getRemainingTime=function(){return this.i?this.i.duration-this.i.currentTime:-1};q.isPaused=function(){return this.h.paused};q.isSkippable=function(){return this.g.isSkippable()};
804
+ q.getTimeUntilSkippable=function(){var a=this.g.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};q.canSkipNow=function(){return 0==this.getTimeUntilSkippable()};q.skip=function(){this.h.currentTime+=this.getRemainingTime()};q.pause=function(){return this.h.pause()};q.play=function(){return this.h.play()};q.getVolume=function(){return this.h.volume};q.setVolume=function(a){this.h.volume=a};q.isMuted=function(){return this.h.muted};q.isLinear=function(){return!0};q.resize=function(){};
805
+ q.setMuted=function(a){this.h.muted=a};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 0};q.getVastMediaHeight=function(){return this.g.getVastMediaHeight()};q.getVastMediaWidth=function(){return this.g.getVastMediaWidth()};
806
+ 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 null};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.i=this.g=null};S("shaka.ads.ServerSideAd",iq);iq.prototype.release=iq.prototype.release;
807
807
  iq.prototype.getPodIndex=iq.prototype.getPodIndex;iq.prototype.getTimeOffset=iq.prototype.getTimeOffset;iq.prototype.getMediaUrl=iq.prototype.getMediaUrl;iq.prototype.getAdvertiserName=iq.prototype.getAdvertiserName;iq.prototype.getCreativeAdId=iq.prototype.getCreativeAdId;iq.prototype.getAdId=iq.prototype.getAdId;iq.prototype.getVastMediaWidth=iq.prototype.getVastMediaWidth;iq.prototype.getVastMediaHeight=iq.prototype.getVastMediaHeight;iq.prototype.getVastMediaBitrate=iq.prototype.getVastMediaBitrate;
808
808
  iq.prototype.getDescription=iq.prototype.getDescription;iq.prototype.getTitle=iq.prototype.getTitle;iq.prototype.getPositionInSequence=iq.prototype.getPositionInSequence;iq.prototype.getSequenceLength=iq.prototype.getSequenceLength;iq.prototype.setMuted=iq.prototype.setMuted;iq.prototype.resize=iq.prototype.resize;iq.prototype.isLinear=iq.prototype.isLinear;iq.prototype.isMuted=iq.prototype.isMuted;iq.prototype.setVolume=iq.prototype.setVolume;iq.prototype.getVolume=iq.prototype.getVolume;
809
809
  iq.prototype.play=iq.prototype.play;iq.prototype.pause=iq.prototype.pause;iq.prototype.skip=iq.prototype.skip;iq.prototype.canSkipNow=iq.prototype.canSkipNow;iq.prototype.getTimeUntilSkippable=iq.prototype.getTimeUntilSkippable;iq.prototype.isSkippable=iq.prototype.isSkippable;iq.prototype.isPaused=iq.prototype.isPaused;iq.prototype.getRemainingTime=iq.prototype.getRemainingTime;iq.prototype.getMinSuggestedDuration=iq.prototype.getMinSuggestedDuration;iq.prototype.getDuration=iq.prototype.getDuration;
@@ -811,16 +811,16 @@ iq.prototype.needsSkipUI=iq.prototype.needsSkipUI;function jq(a,b,c,d){var e=thi
811
811
  e.j.resolve(e.B):e.j.reject("IMA Stream request returned an error and there was no backup asset uri provided.");e.j=null});this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.AD_BREAK_STARTED,function(){});this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.STARTED,function(f){f=f.getAd();e.m=new iq(f,e.l);e.A&&(e.m.i=e.A);e.i(new U("ad-started",(new Map).set("ad",e.m)));e.s.setAttribute("ad-active","true")});this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.AD_BREAK_ENDED,function(){e.s.removeAttribute("ad-active");
812
812
  var f=e.l.currentTime;e.o&&e.o>f&&(e.l.currentTime=e.o,e.o=null)});this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.AD_PROGRESS,function(f){e.A=f.getStreamData().adProgressData;e.m&&(e.m.i=e.A)});this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.FIRST_QUARTILE,function(){e.i(new U("ad-first-quartile"))});this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.MIDPOINT,function(){e.i(new U("ad-midpoint"))});this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.THIRD_QUARTILE,function(){e.i(new U("ad-third-quartile"))});
813
813
  this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.COMPLETE,function(){e.i(new U("ad-complete"));e.i(new U("ad-stopped"));e.s.removeAttribute("ad-active");e.m=null});this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.SKIPPED,function(){e.i(new U("ad-skipped"));e.i(new U("ad-stopped"))});this.h.D(this.g,google.ima.dai.api.StreamEvent.Type.CUEPOINTS_CHANGED,function(f){var g=f.getStreamData();f=[];g=t(g.cuepoints);for(var h=g.next();!h.done;h=g.next())h=h.value,f.push({start:h.start,end:h.end});e.C=
814
- f;e.i(new U("ad-cue-points-changed",(new Map).set("cuepoints",f)))})}r=jq.prototype;r.configure=function(){};r.stop=function(){this.B="";this.o=null;this.C=[]};r.release=function(){this.stop();this.h&&this.h.release()};r.onCueMetadataChange=function(a){if(a.key&&a.data){var b={};b[a.key]=a.data;this.g.onTimedMetadata(b)}};r.getCuePoints=function(){return this.C};
815
- function kq(a,b){a.i(new U("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.F)));b=b.getStreamData().url;a.j.resolve(b);a.j=null;a.G||a.h.D(a.l,"seeked",function(){var c=a.l.currentTime;if(0!=c){a.g.streamTimeForContentTime(c);var d=a.g.previousCuePointForStreamTime(c);d&&!d.played&&(a.o=c,a.l.currentTime=d.start)}})};function lq(){lg.call(this);this.g=this.h=this.i=this.j=null;this.m=new zp;this.o=navigator.language;this.l=null}na(lq,lg);r=lq.prototype;r.setLocale=function(a){this.o=a};r.configure=function(a){this.l=a;this.j&&this.j.configure(this.l);this.i&&this.i.configure(this.l);this.g&&this.g.configure(this.l)};r.initInterstitial=function(a,b,c){var d=this;this.j&&this.j.release();this.j=new Lp(a,b,c,function(e){return mq(d,e)});this.j.configure(this.l)};
816
- r.initClientSide=function(a,b,c){var d=this;if(!window.google||!google.ima||!google.ima.AdsLoader)throw new T(2,10,1E4);this.i&&this.i.release();this.i=new Dp(a,b,this.o,c,function(e){return mq(d,e)});this.i.configure(this.l)};r.release=function(){this.j&&(this.j.release(),this.j=null);this.i&&(this.i.release(),this.i=null);this.h&&(this.h.release(),this.h=null);this.g&&(this.g.release(),this.g=null);lg.prototype.release.call(this)};
817
- r.onAssetUnload=function(){this.j&&this.j.stop();this.i&&this.i.stop();this.h&&this.h.stop();this.g&&this.g.stop();this.dispatchEvent(new U("ad-stopped"));this.dispatchEvent(new U("ad-content-attach-requested"));this.m=new zp};r.requestClientSideAds=function(a){if(!this.i)throw new T(1,10,10001);var b=this.i;b.g&&b.g.destroy();b.m&&b.m.contentComplete();b.G=Date.now()/1E3;b.m.requestAds(a)};
818
- r.updateClientSideAdsRenderingSettings=function(a){if(!this.i)throw new T(1,10,10001);var b=this.i;b.B=a;b.g&&b.g.updateAdsRenderingSettings(b.B)};r.initMediaTailor=function(a,b,c){var d=this;this.h&&this.h.release();this.h=new Yp(a,b,c,function(e){return mq(d,e)})};r.requestMediaTailorStream=function(a,b,c){if(!this.h)throw new T(1,10,10005);var d=this.h;c=void 0===c?"":c;d.l?a=Promise.reject(new T(1,10,10004)):(d.l=new bg,aq(d,a,b),d.H=c||"",d.T=Date.now()/1E3,a=d.l);return a};
819
- r.addMediaTailorTrackingUrl=function(a){if(!this.h)throw new T(1,10,10005);var b=this.h;b.G=a;b.i(new U("ads-loaded",(new Map).set("loadTime",0)))};r.initServerSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.dai)throw new T(2,10,10002);this.g&&this.g.release();this.g=new jq(a,b,this.o,function(d){return mq(c,d)});this.g.configure(this.l)};
820
- r.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new T(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.10.13";c=this.g;c.j?a=Promise.reject(new T(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
821
- (c.G=!0),c.j=new bg,c.g.requestStream(a),c.B=b||"",c.F=Date.now()/1E3,a=c.j);return a};r.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new T(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.10.13";this.g.g.replaceAdTagParameters(a)};
822
- r.getServerSideCuePoints=function(){qb("AdManager.getServerSideCuePoints","Please use getCuePoints function.");return this.getCuePoints()};r.getCuePoints=function(){var a=[];this.g&&(a=a.concat(this.g.getCuePoints()));this.h&&(a=a.concat(this.h.getCuePoints()));return a};r.getStats=function(){var a=this.m;return{loadTimes:a.g,averageLoadTime:Ap(a),started:a.h,playedCompletely:a.j,skipped:a.l,errors:a.i}};r.onManifestUpdated=function(a){if(this.h)this.h.onManifestUpdated(a)};
823
- r.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)};r.onHlsTimedMetadata=function(a,b){this.g&&this.g.g.processMetadata("ID3",a.data,b)};r.onCueMetadataChange=function(a){if(this.g)this.g.onCueMetadataChange(a)};r.onInterstitialMetadata=function(a,b,c){this.j||this.initInterstitial(null,a,b);this.j&&Qp(this.j,c)};
814
+ f;e.i(new U("ad-cue-points-changed",(new Map).set("cuepoints",f)))})}q=jq.prototype;q.configure=function(){};q.stop=function(){this.B="";this.o=null;this.C=[]};q.release=function(){this.stop();this.h&&this.h.release()};q.onCueMetadataChange=function(a){if(a.key&&a.data){var b={};b[a.key]=a.data;this.g.onTimedMetadata(b)}};q.getCuePoints=function(){return this.C};
815
+ function kq(a,b){a.i(new U("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.F)));b=b.getStreamData().url;a.j.resolve(b);a.j=null;a.G||a.h.D(a.l,"seeked",function(){var c=a.l.currentTime;if(0!=c){a.g.streamTimeForContentTime(c);var d=a.g.previousCuePointForStreamTime(c);d&&!d.played&&(a.o=c,a.l.currentTime=d.start)}})};function lq(){lg.call(this);this.g=this.h=this.i=this.j=null;this.m=new zp;this.o=navigator.language;this.l=null}na(lq,lg);q=lq.prototype;q.setLocale=function(a){this.o=a};q.configure=function(a){this.l=a;this.j&&this.j.configure(this.l);this.i&&this.i.configure(this.l);this.g&&this.g.configure(this.l)};q.initInterstitial=function(a,b,c){var d=this;this.j&&this.j.release();this.j=new Lp(a,b,c,function(e){return mq(d,e)});this.j.configure(this.l)};
816
+ q.initClientSide=function(a,b,c){var d=this;if(!window.google||!google.ima||!google.ima.AdsLoader)throw new T(2,10,1E4);this.i&&this.i.release();this.i=new Dp(a,b,this.o,c,function(e){return mq(d,e)});this.i.configure(this.l)};q.release=function(){this.j&&(this.j.release(),this.j=null);this.i&&(this.i.release(),this.i=null);this.h&&(this.h.release(),this.h=null);this.g&&(this.g.release(),this.g=null);lg.prototype.release.call(this)};
817
+ q.onAssetUnload=function(){this.j&&this.j.stop();this.i&&this.i.stop();this.h&&this.h.stop();this.g&&this.g.stop();this.dispatchEvent(new U("ad-stopped"));this.dispatchEvent(new U("ad-content-attach-requested"));this.m=new zp};q.requestClientSideAds=function(a){if(!this.i)throw new T(1,10,10001);var b=this.i;b.g&&b.g.destroy();b.m&&b.m.contentComplete();b.G=Date.now()/1E3;b.m.requestAds(a)};
818
+ q.updateClientSideAdsRenderingSettings=function(a){if(!this.i)throw new T(1,10,10001);var b=this.i;b.B=a;b.g&&b.g.updateAdsRenderingSettings(b.B)};q.initMediaTailor=function(a,b,c){var d=this;this.h&&this.h.release();this.h=new Yp(a,b,c,function(e){return mq(d,e)})};q.requestMediaTailorStream=function(a,b,c){if(!this.h)throw new T(1,10,10005);var d=this.h;c=void 0===c?"":c;d.l?a=Promise.reject(new T(1,10,10004)):(d.l=new bg,aq(d,a,b),d.H=c||"",d.T=Date.now()/1E3,a=d.l);return a};
819
+ q.addMediaTailorTrackingUrl=function(a){if(!this.h)throw new T(1,10,10005);var b=this.h;b.G=a;b.i(new U("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 T(2,10,10002);this.g&&this.g.release();this.g=new jq(a,b,this.o,function(d){return mq(c,d)});this.g.configure(this.l)};
820
+ q.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new T(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.10.15";c=this.g;c.j?a=Promise.reject(new T(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
821
+ (c.G=!0),c.j=new bg,c.g.requestStream(a),c.B=b||"",c.F=Date.now()/1E3,a=c.j);return a};q.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new T(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.10.15";this.g.g.replaceAdTagParameters(a)};
822
+ q.getServerSideCuePoints=function(){qb("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.m;return{loadTimes:a.g,averageLoadTime:Ap(a),started:a.h,playedCompletely:a.j,skipped:a.l,errors:a.i}};q.onManifestUpdated=function(a){if(this.h)this.h.onManifestUpdated(a)};
823
+ 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)};q.onInterstitialMetadata=function(a,b,c){this.j||this.initInterstitial(null,a,b);this.j&&Qp(this.j,c)};
824
824
  function mq(a,b){if(b&&b.type)switch(b.type){case "ads-loaded":a.m.g.push(b.loadTime);break;case "ad-started":a.m.h++;break;case "ad-complete":a.m.j++;break;case "ad-skipped":a.m.l++;break;case "ad-error":a.m.i++}a.dispatchEvent(b)}S("shaka.ads.AdManager",lq);lq.prototype.onInterstitialMetadata=lq.prototype.onInterstitialMetadata;lq.prototype.onCueMetadataChange=lq.prototype.onCueMetadataChange;lq.prototype.onHlsTimedMetadata=lq.prototype.onHlsTimedMetadata;lq.prototype.onDashTimedMetadata=lq.prototype.onDashTimedMetadata;
825
825
  lq.prototype.onManifestUpdated=lq.prototype.onManifestUpdated;lq.prototype.getStats=lq.prototype.getStats;lq.prototype.getCuePoints=lq.prototype.getCuePoints;lq.prototype.getServerSideCuePoints=lq.prototype.getServerSideCuePoints;lq.prototype.replaceServerSideAdTagParameters=lq.prototype.replaceServerSideAdTagParameters;lq.prototype.requestServerSideStream=lq.prototype.requestServerSideStream;lq.prototype.initServerSide=lq.prototype.initServerSide;lq.prototype.addMediaTailorTrackingUrl=lq.prototype.addMediaTailorTrackingUrl;
826
826
  lq.prototype.requestMediaTailorStream=lq.prototype.requestMediaTailorStream;lq.prototype.initMediaTailor=lq.prototype.initMediaTailor;lq.prototype.updateClientSideAdsRenderingSettings=lq.prototype.updateClientSideAdsRenderingSettings;lq.prototype.requestClientSideAds=lq.prototype.requestClientSideAds;lq.prototype.onAssetUnload=lq.prototype.onAssetUnload;lq.prototype.release=lq.prototype.release;lq.prototype.initClientSide=lq.prototype.initClientSide;lq.prototype.initInterstitial=lq.prototype.initInterstitial;
@@ -832,19 +832,19 @@ function oq(a){return JSON.parse(a,function(b,c){if("NaN"==c)var d=NaN;else if("
832
832
  function pq(a){return{length:a.length,start:function(b){return a.start[b]},end:function(b){return a.end[b]}}}
833
833
  var qq="ended play playing pause pausing ratechange seeked seeking timeupdate volumechange".split(" "),rq="buffered currentTime duration ended loop muted paused playbackRate seeking videoHeight videoWidth volume".split(" "),sq=["loop","playbackRate"],tq=["pause","play"],uq={getAssetUri:2,getAudioLanguages:4,getAudioLanguagesAndRoles:4,getBufferFullness:1,getBufferedInfo:2,getExpiration:2,getKeyStatuses:2,getPlaybackRate:2,getTextLanguages:4,getTextLanguagesAndRoles:4,getImageTracks:2,getThumbnails:2,
834
834
  isAudioOnly:10,isBuffering:1,isInProgress:1,isLive:10,isTextTrackVisible:1,keySystem:10,seekRange:1,getLoadMode:10,getManifestType:10,isFullyLoaded:1},vq={getConfiguration:4,getStats:5,getTextTracks:2,getVariantTracks:2},wq={getPlayheadTimeAsDate:1,getPresentationStartTimeAsDate:20,getSegmentAvailabilityDuration:20},xq=[["getConfiguration","configure"]],yq=[["isTextTrackVisible","setTextTrackVisibility"]],zq="addChaptersTrack addTextTrackAsync addThumbnailsTrack cancelTrickPlay configure getChapters getChaptersTracks resetConfiguration retryStreaming selectAudioLanguage selectTextLanguage selectTextTrack selectVariantTrack selectVariantsByLabel setTextTrackVisibility trickPlay updateStartTime goToLive".split(" "),
835
- Aq=["attach","attachCanvas","detach","load","unload"];function Bq(a,b,c,d,e,f,g){var h=this;this.G=a;this.K=g;this.l=new Sc(b);this.L=c;this.s=!1;this.A=d;this.F=e;this.N=f;this.h=this.m=!1;this.I="";this.o=null;this.B=function(){return Cq(h)};this.C=function(k,l){k=oq(l);switch(k.type){case "event":var m=k.targetName,n=jg(k.event);h.A(m,n);break;case "update":m=k.update;for(n in m){k=h.g[n]||{};for(var q in m[n])k[q]=m[n][q]}h.s&&(h.L(),h.s=!1);break;case "asyncComplete":if(n=k.id,q=k.error,k=h.i[n],delete h.i[n],k)if(q){n=new T(q.severity,q.category,
836
- q.code);for(m in q)n[m]=q[m];k.reject(n)}else k.resolve()}};this.g={video:{},player:{}};this.H=0;this.i={};this.j=null;Dq.add(this)}r=Bq.prototype;r.destroy=function(){Dq.delete(this);Eq(this);Fq&&Gq(this);this.l&&(this.l.stop(),this.l=null);this.F=this.A=null;this.h=this.m=!1;this.C=this.B=this.j=this.i=this.g=this.o=null;return Promise.resolve()};r.fb=function(){return this.h};r.Ff=function(){return this.I};
837
- r.init=function(){if(this.G.length)if(window.chrome&&chrome.cast&&chrome.cast.isAvailable){this.m=!0;this.l.uc();var a=new chrome.cast.SessionRequest(this.G,[],null,this.K,null);a=new chrome.cast.ApiConfig(a,function(b){for(var c=t(Dq),d=c.next();!d.done;d=c.next()){d=d.value;var e=b;d.j=new bg;d.s=!0;Hq(d,e)}},function(b){for(var c=t(Dq),d=c.next();!d.done;d=c.next())d=d.value,Iq="available"==b,d.l.uc()},"origin_scoped");chrome.cast.initialize(a,function(){},function(){});Iq&&this.l.Z(Jq);(a=Fq)&&
838
- a.status!=chrome.cast.SessionStatus.STOPPED?(this.j=new bg,this.s=!0,Hq(this,a)):Fq=null}else window.__onGCastApiAvailable!==Kq&&(Lq=window.__onGCastApiAvailable||null,window.__onGCastApiAvailable=Kq)};r.Nf=function(a){this.o=a;this.h&&Mq(this,{type:"appData",appData:this.o})};
839
- r.cast=function(){var a=this;return O(function(b){if(!a.m)throw new T(1,8,8E3);if(!Iq)throw new T(1,8,8001);if(a.h)throw new T(1,8,8002);a.j=new bg;chrome.cast.requestSession(function(c){return Hq(a,c)},function(c){return Nq(a,c)});return F(b,a.j,0)})};function Oq(a){a.h&&chrome.cast.requestSession(function(b){return Hq(a,b)},function(b){return Nq(a,b)})}r.Dc=function(){if(this.h){Eq(this);if(Fq){Gq(this);try{Fq.stop(function(){},function(){})}catch(a){}Fq=null}Cq(this)}};
840
- r.get=function(a,b){var c=this;if("video"==a){if(tq.includes(b))return function(){return c.Ug.apply(c,[a,b].concat(x(Ia.apply(0,arguments))))}}else if("player"==a){if(wq[b]&&!this.get("player","isLive")())return function(){};if(zq.includes(b))return function(){return c.Ug.apply(c,[a,b].concat(x(Ia.apply(0,arguments))))};if(Aq.includes(b))return function(){return c.Ki.apply(c,[a,b].concat(x(Ia.apply(0,arguments))))};if(uq[b]||vq[b])return function(){return c.g[a][b]}}return this.g[a][b]};
841
- r.set=function(a,b,c){this.g[a][b]=c;Mq(this,{type:"set",targetName:a,property:b,value:c})};function Hq(a,b){var c=a.N();Fq=b;b.addUpdateListener(a.B);b.addMessageListener("urn:x-cast:com.google.shaka.v2",a.C);Cq(a);Mq(a,{type:"init",initState:c,appData:a.o});a.j.resolve()}function Nq(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 T(2,8,c,b))}
842
- r.Ug=function(a,b){Mq(this,{type:"call",targetName:a,methodName:b,args:Ia.apply(2,arguments)})};r.Ki=function(a,b){var c=Ia.apply(2,arguments),d=new bg,e=this.H.toString();this.H++;this.i[e]=d;try{Mq(this,{type:"asyncCall",targetName:a,methodName:b,args:c,id:e})}catch(f){d.reject(f)}return d};function Gq(a){var b=Fq;b.removeUpdateListener(a.B);b.removeMessageListener("urn:x-cast:com.google.shaka.v2",a.C)}
835
+ Aq=["attach","attachCanvas","detach","load","unload"];function Bq(a,b,c,d,e,f,g){var h=this;this.G=a;this.K=g;this.l=new Sc(b);this.L=c;this.s=!1;this.A=d;this.F=e;this.N=f;this.h=this.m=!1;this.I="";this.o=null;this.B=function(){return Cq(h)};this.C=function(k,l){k=oq(l);switch(k.type){case "event":var m=k.targetName,n=jg(k.event);h.A(m,n);break;case "update":m=k.update;for(n in m){k=h.g[n]||{};for(var p in m[n])k[p]=m[n][p]}h.s&&(h.L(),h.s=!1);break;case "asyncComplete":if(n=k.id,p=k.error,k=h.i[n],delete h.i[n],k)if(p){n=new T(p.severity,p.category,
836
+ p.code);for(m in p)n[m]=p[m];k.reject(n)}else k.resolve()}};this.g={video:{},player:{}};this.H=0;this.i={};this.j=null;Dq.add(this)}q=Bq.prototype;q.destroy=function(){Dq.delete(this);Eq(this);Fq&&Gq(this);this.l&&(this.l.stop(),this.l=null);this.F=this.A=null;this.h=this.m=!1;this.C=this.B=this.j=this.i=this.g=this.o=null;return Promise.resolve()};q.fb=function(){return this.h};q.Ff=function(){return this.I};
837
+ q.init=function(){if(this.G.length)if(window.chrome&&chrome.cast&&chrome.cast.isAvailable){this.m=!0;this.l.uc();var a=new chrome.cast.SessionRequest(this.G,[],null,this.K,null);a=new chrome.cast.ApiConfig(a,function(b){for(var c=t(Dq),d=c.next();!d.done;d=c.next()){d=d.value;var e=b;d.j=new bg;d.s=!0;Hq(d,e)}},function(b){for(var c=t(Dq),d=c.next();!d.done;d=c.next())d=d.value,Iq="available"==b,d.l.uc()},"origin_scoped");chrome.cast.initialize(a,function(){},function(){});Iq&&this.l.Z(Jq);(a=Fq)&&
838
+ a.status!=chrome.cast.SessionStatus.STOPPED?(this.j=new bg,this.s=!0,Hq(this,a)):Fq=null}else window.__onGCastApiAvailable!==Kq&&(Lq=window.__onGCastApiAvailable||null,window.__onGCastApiAvailable=Kq)};q.Nf=function(a){this.o=a;this.h&&Mq(this,{type:"appData",appData:this.o})};
839
+ q.cast=function(){var a=this;return O(function(b){if(!a.m)throw new T(1,8,8E3);if(!Iq)throw new T(1,8,8001);if(a.h)throw new T(1,8,8002);a.j=new bg;chrome.cast.requestSession(function(c){return Hq(a,c)},function(c){return Nq(a,c)});return F(b,a.j,0)})};function Oq(a){a.h&&chrome.cast.requestSession(function(b){return Hq(a,b)},function(b){return Nq(a,b)})}q.Dc=function(){if(this.h){Eq(this);if(Fq){Gq(this);try{Fq.stop(function(){},function(){})}catch(a){}Fq=null}Cq(this)}};
840
+ q.get=function(a,b){var c=this;if("video"==a){if(tq.includes(b))return function(){return c.Ug.apply(c,[a,b].concat(x(Ia.apply(0,arguments))))}}else if("player"==a){if(wq[b]&&!this.get("player","isLive")())return function(){};if(zq.includes(b))return function(){return c.Ug.apply(c,[a,b].concat(x(Ia.apply(0,arguments))))};if(Aq.includes(b))return function(){return c.Ki.apply(c,[a,b].concat(x(Ia.apply(0,arguments))))};if(uq[b]||vq[b])return function(){return c.g[a][b]}}return this.g[a][b]};
841
+ q.set=function(a,b,c){this.g[a][b]=c;Mq(this,{type:"set",targetName:a,property:b,value:c})};function Hq(a,b){var c=a.N();Fq=b;b.addUpdateListener(a.B);b.addMessageListener("urn:x-cast:com.google.shaka.v2",a.C);Cq(a);Mq(a,{type:"init",initState:c,appData:a.o});a.j.resolve()}function Nq(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 T(2,8,c,b))}
842
+ q.Ug=function(a,b){Mq(this,{type:"call",targetName:a,methodName:b,args:Ia.apply(2,arguments)})};q.Ki=function(a,b){var c=Ia.apply(2,arguments),d=new bg,e=this.H.toString();this.H++;this.i[e]=d;try{Mq(this,{type:"asyncCall",targetName:a,methodName:b,args:c,id:e})}catch(f){d.reject(f)}return d};function Gq(a){var b=Fq;b.removeUpdateListener(a.B);b.removeMessageListener("urn:x-cast:com.google.shaka.v2",a.C)}
843
843
  function Cq(a){var b=Fq?"connected"==Fq.status:!1;if(a.h&&!b){a.F();for(var c in a.g)a.g[c]={};Eq(a)}a.h=b;a.I=b?Fq.receiver.friendlyName:"";a.l.uc()}function Eq(a){for(var b in a.i){var c=a.i[b];delete a.i[b];c.reject(new T(1,7,7E3))}}function Mq(a,b){b=nq(b);var c=Fq;try{c.sendMessage("urn:x-cast:com.google.shaka.v2",b,function(){},cb)}catch(d){throw b=new T(2,8,8005,d),c=new U("error",(new Map).set("detail",b)),a.A("player",c),a.Dc(),b;}}var Jq=.02,Iq=!1,Fq=null,Lq=null,Dq=new Set;
844
- function Kq(a){Lq?window.__onGCastApiAvailable=Lq:delete window.__onGCastApiAvailable;Lq=null;if(a)for(var b=t(Dq),c=b.next();!c.done;c=b.next())c.value.init();"function"===typeof window.__onGCastApiAvailable&&window.__onGCastApiAvailable(a)};function Pq(a,b,c,d){d=void 0===d?!1:d;lg.call(this);var e=this;this.i=a;this.h=b;this.m=this.o=this.j=this.s=this.l=null;this.C=c;this.B=d;this.A=new Map;this.g=new Bq(c,function(){return Qq(e)},function(){return Rq(e)},function(f,g){return Sq(e,f,g)},function(){return Tq(e)},function(){return Uq(e)},d);Vq(this)}na(Pq,lg);r=Pq.prototype;
845
- r.destroy=function(a){a&&this.g.Dc();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.s=this.l=this.i=null;lg.prototype.release.call(this);return Promise.all(a)};r.fi=function(){return this.l};r.Vh=function(){return this.s};r.Ah=function(){return this.g.m&&Iq};r.fb=function(){return this.g.fb()};r.Ff=function(){return this.g.Ff()};
846
- r.cast=function(){var a=this;return O(function(b){return 1==b.g?F(b,a.g.cast(),2):a.h?F(b,a.h.cc(),0):b.return()})};r.Nf=function(a){this.g.Nf(a)};r.$i=function(){Oq(this.g)};r.Dc=function(){this.g.Dc()};
847
- r.Bh=function(a,b){b=void 0===b?!1:b;var c=this;return O(function(d){if(1==d.g){if(a==c.C&&b==c.B)return d.return();c.C=a;c.B=b;c.g.Dc();return F(d,c.g.destroy(),2)}c.g=null;c.g=new Bq(a,function(){return Qq(c)},function(){return Rq(c)},function(e,f){return Sq(c,e,f)},function(){return Tq(c)},function(){return Uq(c)},b);c.g.init();H(d)})};
844
+ function Kq(a){Lq?window.__onGCastApiAvailable=Lq:delete window.__onGCastApiAvailable;Lq=null;if(a)for(var b=t(Dq),c=b.next();!c.done;c=b.next())c.value.init();"function"===typeof window.__onGCastApiAvailable&&window.__onGCastApiAvailable(a)};function Pq(a,b,c,d){d=void 0===d?!1:d;lg.call(this);var e=this;this.i=a;this.h=b;this.m=this.o=this.j=this.s=this.l=null;this.C=c;this.B=d;this.A=new Map;this.g=new Bq(c,function(){return Qq(e)},function(){return Rq(e)},function(f,g){return Sq(e,f,g)},function(){return Tq(e)},function(){return Uq(e)},d);Vq(this)}na(Pq,lg);q=Pq.prototype;
845
+ q.destroy=function(a){a&&this.g.Dc();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.s=this.l=this.i=null;lg.prototype.release.call(this);return Promise.all(a)};q.fi=function(){return this.l};q.Vh=function(){return this.s};q.Ah=function(){return this.g.m&&Iq};q.fb=function(){return this.g.fb()};q.Ff=function(){return this.g.Ff()};
846
+ q.cast=function(){var a=this;return O(function(b){return 1==b.g?F(b,a.g.cast(),2):a.h?F(b,a.h.cc(),0):b.return()})};q.Nf=function(a){this.g.Nf(a)};q.$i=function(){Oq(this.g)};q.Dc=function(){this.g.Dc()};
847
+ q.Bh=function(a,b){b=void 0===b?!1:b;var c=this;return O(function(d){if(1==d.g){if(a==c.C&&b==c.B)return d.return();c.C=a;c.B=b;c.g.Dc();return F(d,c.g.destroy(),2)}c.g=null;c.g=new Bq(a,function(){return Qq(c)},function(){return Rq(c)},function(e,f){return Sq(c,e,f)},function(){return Tq(c)},function(){return Uq(c)},b);c.g.init();H(d)})};
848
848
  function Vq(a){a.g.init();a.m=new gb;for(var b=t(qq),c=b.next();!c.done;c=b.next())a.m.D(a.i,c.value,function(f){a.g.fb()||(f=jg(f),a.j.dispatchEvent(f))});for(var d in kg)a.m.D(a.h,kg[d],function(f){a.g.fb()||a.o.dispatchEvent(f)});a.l={};b={};for(var e in a.i)b={ld:b.ld},b.ld=e,Object.defineProperty(a.l,b.ld,{configurable:!1,enumerable:!0,get:function(f){return function(){return Wq(a,f.ld)}}(b),set:function(f){return function(g){var h=f.ld;a.g.fb()?a.g.set("video",h,g):a.i[h]=g}}(b)});a.s={};Xq(a,
849
849
  function(f){Object.defineProperty(a.s,f,{configurable:!1,enumerable:!0,get:function(){return Yq(a,f)}})});Zq(a);a.j=new lg;a.j.le=a.l;a.o=new lg;a.o.le=a.s}function Zq(a){var b=new Map;Xq(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)})}
850
850
  function Xq(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)}}
@@ -856,14 +856,14 @@ function Wq(a,b){if("addEventListener"==b)return function(d,e,f){return a.j.addE
856
856
  function Yq(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.xb()};if("getDrmEngine"==b)return function(){return a.h.B};if("getAdManager"==b)return function(){return a.h.ug()};
857
857
  if("setVideoContainer"==b)return function(c){return a.h.ih(c)};if(a.g.fb()){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.fb()&&0==Object.keys(a.g.g.video).length&&(uq[b]||vq[b])||!a.g.fb()?a.h[b].bind(a.h):a.g.get("player",b)}
858
858
  function Sq(a,b,c){a.g.fb()&&("video"==b?a.j.dispatchEvent(c):"player"==b&&a.o.dispatchEvent(c))}S("shaka.cast.CastProxy",Pq);Pq.prototype.changeReceiverId=Pq.prototype.Bh;Pq.prototype.forceDisconnect=Pq.prototype.Dc;Pq.prototype.suggestDisconnect=Pq.prototype.$i;Pq.prototype.setAppData=Pq.prototype.Nf;Pq.prototype.cast=Pq.prototype.cast;Pq.prototype.receiverName=Pq.prototype.Ff;Pq.prototype.isCasting=Pq.prototype.fb;Pq.prototype.canCast=Pq.prototype.Ah;Pq.prototype.getPlayer=Pq.prototype.Vh;
859
- Pq.prototype.getVideo=Pq.prototype.fi;Pq.prototype.destroy=Pq.prototype.destroy;function $q(a,b,c,d){lg.call(this);var e=this;this.g=a;this.h=b;this.j=new gb;this.H={video:a,player:b};this.F=c||function(){};this.I=d||function(f){return f};this.i=null;this.G=!1;this.o=!0;this.m=0;this.B=!1;this.A=!0;this.s=this.l=null;this.C=new Sc(function(){ar(e)});br(this)}na($q,lg);r=$q.prototype;r.isConnected=function(){return this.G};r.mi=function(){return this.o};r.Wi=function(a){this.i=a};r.Dh=function(){this.i=null};
860
- r.Xi=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.title=a};r.Vi=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.images=[{url:a}]};r.Ui=function(a){this.i||(this.i={});this.i.artist=a;this.i.metadataType=cast.receiver.media.MetadataType.MUSIC_TRACK};
861
- r.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.C&&(a.C.stop(),a.C=null),a.g=null,a.H=null,a.F=null,a.G=!1,a.o=!0,a.l=null,a.s=null,lg.prototype.release.call(a),F(d,Promise.all(b),2);c=cast.receiver.CastReceiverManager.getInstance();c.stop();H(d)})};
859
+ Pq.prototype.getVideo=Pq.prototype.fi;Pq.prototype.destroy=Pq.prototype.destroy;function $q(a,b,c,d){lg.call(this);var e=this;this.g=a;this.h=b;this.j=new gb;this.H={video:a,player:b};this.F=c||function(){};this.I=d||function(f){return f};this.i=null;this.G=!1;this.o=!0;this.m=0;this.B=!1;this.A=!0;this.s=this.l=null;this.C=new Sc(function(){ar(e)});br(this)}na($q,lg);q=$q.prototype;q.isConnected=function(){return this.G};q.mi=function(){return this.o};q.Wi=function(a){this.i=a};q.Dh=function(){this.i=null};
860
+ q.Xi=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.title=a};q.Vi=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.images=[{url:a}]};q.Ui=function(a){this.i||(this.i={});this.i.artist=a;this.i.metadataType=cast.receiver.media.MetadataType.MUSIC_TRACK};
861
+ 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.C&&(a.C.stop(),a.C=null),a.g=null,a.H=null,a.F=null,a.G=!1,a.o=!0,a.l=null,a.s=null,lg.prototype.release.call(a),F(d,Promise.all(b),2);c=cast.receiver.CastReceiverManager.getInstance();c.stop();H(d)})};
862
862
  function br(a){var b=cast.receiver.CastReceiverManager.getInstance();b.onSenderConnected=function(){return cr(a)};b.onSenderDisconnected=function(){return cr(a)};b.onSystemVolumeChanged=function(){var e=cast.receiver.CastReceiverManager.getInstance().getSystemVolume();e&&dr(a,{type:"update",update:{video:{volume:e.level,muted:e.muted}}},a.l);dr(a,{type:"event",targetName:"video",event:{type:"volumechange"}},a.l)};a.s=b.getCastMessageBus("urn:x-cast:com.google.cast.media");a.s.onMessage=function(e){return er(a,
863
863
  e)};a.l=b.getCastMessageBus("urn:x-cast:com.google.shaka.v2");a.l.onMessage=function(e){return fr(a,e)};b.start();b=t(qq);for(var c=b.next();!c.done;c=b.next())a.j.D(a.g,c.value,function(e){return gr(a,"video",e)});for(var d in kg)a.j.D(a.h,kg[d],function(e){return gr(a,"player",e)});a.j.D(a.g,"loadeddata",function(){a.B=!0});a.j.D(a.h,"loading",function(){a.o=!1;hr(a)});a.j.D(a.g,"playing",function(){a.o=!1;hr(a)});a.j.D(a.g,"pause",function(){hr(a)});a.j.D(a.h,"unloading",function(){a.o=!0;hr(a)});
864
864
  a.j.D(a.g,"ended",function(){(new Sc(function(){a.g&&a.g.ended&&(a.o=!0,hr(a))})).Z(ir)})}function cr(a){a.m=0;a.A=!0;a.G=0!=cast.receiver.CastReceiverManager.getInstance().getSenders().length;hr(a)}function hr(a){var b;O(function(c){if(1==c.g)return F(c,Promise.resolve(),2);if(!a.h)return c.return();b=new U("caststatuschanged");a.dispatchEvent(b);jr(a)||kr(a);H(c)})}
865
- function lr(a,b,c){var d,e,f,g,h,k,l,m,n,q;O(function(p){switch(p.g){case 1:for(d in b.player)e=b.player[d],a.h[d](e);a.F(c);f=a.g.autoplay;return b.manifest?(a.g.autoplay=!1,ra(p,5),F(p,a.h.load(b.manifest,b.startTime),7)):F(p,Promise.resolve(),3);case 7:ta(p,3);break;case 5:return g=ua(p),h=(new Map).set("detail",g),k=new U("error",h),a.h&&a.h.dispatchEvent(k),p.return();case 3:if(!a.h)return p.return();for(l in b.video)m=b.video[l],a.g[l]=m;for(n in b.playerAfterLoad)q=b.playerAfterLoad[n],a.h[n](q);
866
- a.g.autoplay=f;b.manifest&&(a.g.play(),kr(a));H(p)}})}function gr(a,b,c){a.h&&(ar(a),dr(a,{type:"event",targetName:b,event:c},a.l))}
865
+ function lr(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.F(c);f=a.g.autoplay;return b.manifest?(a.g.autoplay=!1,ra(r,5),F(r,a.h.load(b.manifest,b.startTime),7)):F(r,Promise.resolve(),3);case 7:ta(r,3);break;case 5:return g=ua(r),h=(new Map).set("detail",g),k=new U("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);
866
+ a.g.autoplay=f;b.manifest&&(a.g.play(),kr(a));H(r)}})}function gr(a,b,c){a.h&&(ar(a),dr(a,{type:"event",targetName:b,event:c},a.l))}
867
867
  function ar(a){a.C.Z(mr);for(var b={video:{},player:{}},c=t(rq),d=c.next();!d.done;d=c.next())d=d.value,b.video[d]=a.g[d];if(a.h.V())for(var e in wq)0==a.m%wq[e]&&(b.player[e]=a.h[e]());for(var f in uq)0==a.m%uq[f]&&(b.player[f]=a.h[f]());if(c=cast.receiver.CastReceiverManager.getInstance().getSystemVolume())b.video.volume=c.level,b.video.muted=c.muted;dr(a,{type:"update",update:b},a.l);for(var g in vq)0==a.m%vq[g]&&(b={player:{}},b.player[g]=a.h[g](),dr(a,{type:"update",update:b},a.l));a.B&&(a.m+=
868
868
  1);jr(a)}function jr(a){return a.A&&(a.g.duration||a.h.V())?(nr(a),a.A=!1,!0):!1}function nr(a,b){var c={contentId:a.h.Ec(),streamType:a.h.V()?"LIVE":"BUFFERED",contentType:""};a.h.V()||(c.duration=a.g.duration);a.i&&(c.metadata=a.i);kr(a,void 0===b?0:b,c)}
869
869
  function fr(a,b){var c=oq(b.data);switch(c.type){case "init":a.m=0;a.B=!1;a.A=!0;lr(a,c.initState,c.appData);ar(a);break;case "appData":a.F(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.H[d][e]=c;break;case "call":d=a.H[c.targetName];d[c.methodName].apply(d,c.args);break;case "asyncCall":d=c.targetName;e=c.methodName;
@@ -871,8 +871,8 @@ function fr(a,b){var c=oq(b.data);switch(c.type){case "init":a.m=0;a.B=!1;a.A=!0
871
871
  function er(a,b){var c=oq(b.data);switch(c.type){case "PLAY":a.g.play();kr(a);break;case "PAUSE":a.g.pause();kr(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(),kr(a)):d&&"PLAYBACK_PAUSE"==d&&(a.g.pause(),kr(a));break;case "STOP":a.h.cc().then(function(){a.h&&kr(a)});break;case "GET_STATUS":nr(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));
872
872
  null!=d&&(a.g.muted=d);e==a.g.volume&&f==a.g.muted||kr(a);break;case "LOAD":a.m=0;a.B=!1;a.A=!1;b=c.media;d=c.currentTime;e=a.I(b.contentId);f=c.autoplay||!0;a.F(b.customData);f&&(a.g.autoplay=!0);a.h.load(e,d).then(function(){a.h&&nr(a)}).catch(function(g){var h="LOAD_FAILED";7==g.category&&7E3==g.code&&(h="LOAD_CANCELLED");dr(a,{requestId:Number(c.requestId),type:h},a.s)});break;default:dr(a,{requestId:Number(c.requestId),type:"INVALID_REQUEST",reason:"INVALID_COMMAND"},a.s)}}
873
873
  function or(a,b,c,d){a.h&&dr(a,{type:"asyncComplete",id:c,error:d},a.l,b)}function dr(a,b,c,d){a.G&&(a=nq(b),d?c.getCastChannel(d).send(a):c.broadcast(a))}function kr(a,b,c){c=void 0===c?null:c;var d={mediaSessionId:0,playbackRate:a.g.playbackRate,playerState:a.o?pr:a.h.nf()?qr:a.g.paused?rr:sr,currentTime:a.g.currentTime,supportedMediaCommands:63,volume:{level:a.g.volume,muted:a.g.muted}};c&&(d.media=c);dr(a,{requestId:void 0===b?0:b,type:"MEDIA_STATUS",status:[d]},a.s)}
874
- S("shaka.cast.CastReceiver",$q);$q.prototype.destroy=$q.prototype.destroy;$q.prototype.setContentArtist=$q.prototype.Ui;$q.prototype.setContentImage=$q.prototype.Vi;$q.prototype.setContentTitle=$q.prototype.Xi;$q.prototype.clearContentMetadata=$q.prototype.Dh;$q.prototype.setContentMetadata=$q.prototype.Wi;$q.prototype.isIdle=$q.prototype.mi;$q.prototype.isConnected=$q.prototype.isConnected;var mr=.5,ir=5,pr="IDLE",sr="PLAYING",qr="BUFFERING",rr="PAUSED";function tr(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=ur(d,e,h,k,l,m);f<=g;f++){for(var q=c[f],p=-1,w=-1,u=0;u<q.length;u++)if(null!=q[u]&&""!==q[u].g.trim()){p=u;break}for(u=q.length-1;0<=u;u--)if(null!=q[u]&&""!==q[u].g.trim()){w=u;break}if(-1===
875
- p||-1===w)q=vr(d,e),a.nestedCues.push(q);else{for(;p<=w;p++)if(u=q[p]){var v=u.l,A=u.i,z=u.j,D=u.h;if(v!=h||A!=k||z!=l||D!=m)n.payload&&a.nestedCues.push(n),n=ur(d,e,v,A,z,D),h=v,k=A,l=z,m=D;n.payload+=u.g}else n.payload+=" ";n.payload&&a.nestedCues.push(n);f!==g&&(n=vr(d,e),a.nestedCues.push(n));n=ur(d,e,h,k,l,m)}}return a.nestedCues.length?{cue:a,stream:b}:null}
874
+ S("shaka.cast.CastReceiver",$q);$q.prototype.destroy=$q.prototype.destroy;$q.prototype.setContentArtist=$q.prototype.Ui;$q.prototype.setContentImage=$q.prototype.Vi;$q.prototype.setContentTitle=$q.prototype.Xi;$q.prototype.clearContentMetadata=$q.prototype.Dh;$q.prototype.setContentMetadata=$q.prototype.Wi;$q.prototype.isIdle=$q.prototype.mi;$q.prototype.isConnected=$q.prototype.isConnected;var mr=.5,ir=5,pr="IDLE",sr="PLAYING",qr="BUFFERING",rr="PAUSED";function tr(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=ur(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===
875
+ r||-1===u)p=vr(d,e),a.nestedCues.push(p);else{for(;r<=u;r++)if(v=p[r]){var w=v.l,A=v.i,z=v.j,D=v.h;if(w!=h||A!=k||z!=l||D!=m)n.payload&&a.nestedCues.push(n),n=ur(d,e,w,A,z,D),h=w,k=A,l=z,m=D;n.payload+=v.g}else n.payload+=" ";n.payload&&a.nestedCues.push(n);f!==g&&(n=vr(d,e),a.nestedCues.push(n));n=ur(d,e,h,k,l,m)}}return a.nestedCues.length?{cue:a,stream:b}:null}
876
876
  function ur(a,b,c,d,e,f){a=new Qb(a,b,"");c&&a.textDecoration.push("underline");d&&(a.fontStyle="italic");a.color=e;a.backgroundColor=f;return a}function vr(a,b){a=new Qb(a,b,"");a.lineBreak=!0;return a}function wr(a,b,c,d,e){this.g=a;this.l=b;this.i=c;this.h=d;this.j=e};function xr(a,b){this.i=[];this.g=1;this.h=0;this.A=a;this.s=b;this.j=this.m=!1;this.l="white";this.o="black";yr(this)}function zr(a,b,c){var d="CC"+((a.A<<1|a.s)+1),e=new Qb(b,c,"");e.lineInterpretation=1;var f=Ar.get(a.g);f&&(e.line=f);(b=tr(e,d,a.i,b,c))&&15<a.g+b.cue.nestedCues.length-3&&(f=Ar.get(a.g+3-b.cue.nestedCues.length))&&(e.line=f);return b}function yr(a){Br(a,0,15);a.g=1}
877
877
  function Cr(a,b,c){if(!(32>c||127<c)){var d="";switch(b){case 0:d=Dr.has(c)?Dr.get(c):String.fromCharCode(c);break;case 1:d=Er.get(c);break;case 2:a.i[a.g].pop();d=Fr.get(c);break;case 3:a.i[a.g].pop(),d=Gr.get(c)}d&&a.i[a.g].push(new wr(d,a.m,a.j,a.o,a.l))}}function Hr(a,b,c,d){if(!(0>c||0>b))if(b>=c)for(--d;0<=d;d--)a.i[b+d]=a.i[c+d].map(function(f){return f});else for(var e=0;e<d;e++)a.i[b+e]=a.i[c+e].map(function(f){return f})}function Br(a,b,c){for(var d=0;d<=c;d++)a.i[b+d]=[]}
878
878
  var Dr=new Map([[39,"\u2019"],[42,"\u00e1"],[92,"\u00e9"],[92,"\u00e9"],[94,"\u00ed"],[95,"\u00f3"],[96,"\u00fa"],[123,"\u00e7"],[124,"\u00f7"],[125,"\u00d1"],[126,"\u00f1"],[127,"\u2588"]]),Er=new Map([[48,"\u00ae"],[49,"\u00b0"],[50,"\u00bd"],[51,"\u00bf"],[52,"\u2122"],[53,"\u00a2"],[54,"\u00a3"],[55,"\u266a"],[56,"\u00e0"],[57," "],[58,"\u00e8"],[59,"\u00e2"],[60,"\u00ea"],[61,"\u00ee"],[62,"\u00f4"],[63,"\u00fb"]]),Fr=new Map([[32,"\u00c1"],[33,"\u00c9"],[34,"\u00d3"],[35,"\u00da"],[36,"\u00dc"],
@@ -892,76 +892,76 @@ function hs(a,b){var c=b.type;if(16===(b.bb&112)){var d=b.bb>>3&1;0===c?a.o=d:a.
892
892
  "white";e=!1;7>f?d=Nr[f]:7===f&&(e=!0);a=1===(a&1);4!==c.h&&(f=c.g,3===c.h&&b!==f.g&&(c=1+b-f.h,Hr(f,c,1+f.g-f.h,f.h),Br(f,0,c-1),Br(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",Cr(c.g,0,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))Cr(c.g,
893
893
  1,a);else if(18===(d&246)&&32===(a&224))Cr(c.g,d&1?3:2,a);else if(20===(d&246)&&32===(a&240)){a=b.pts;d=null;switch(b.Cb){case 32:Kr(c);break;case 33:c=c.g;c.i[c.g].pop();break;case 37:d=Jr(c,2,a);break;case 38:d=Jr(c,3,a);break;case 39:d=Jr(c,4,a);break;case 40:Cr(c.g,0,32);break;case 41:c.h=2;c.g=c.i;c.g.h=0;c.l=a;break;case 42:yr(c.o);Lr(c);break;case 43:Lr(c);break;case 44:b=c.i;d=null;4!==c.h&&(d=zr(b,c.l,a));Br(b,0,15);break;case 45:b=c.g;3!==c.h?d=null:(d=zr(b,c.l,a),e=b.g-b.h+1,Hr(b,e-1,e,
894
894
  b.h),Br(b,0,e-1),Br(b,b.g,15-b.g),c.l=a);break;case 46:Br(c.j,0,15);break;case 47:b=null,4!==c.h&&(b=zr(c.i,c.l,a)),d=c.j,c.j=c.i,c.i=d,Kr(c),c.l=a,d=b}e=d;break a}e=null}else a=b.Cb,Cr(c.g,0,b.bb),Cr(c.g,0,a);return e}
895
- function is(a,b){var c=[];try{for(;b.pa();){var d=Xr(b).value,e=(d&224)>>5,f=d&31;7===e&&0!=f&&(e=Xr(b).value&63);if(0!=e){a.A.add("svc"+e);a.j.has(e)||a.j.set(e,new Yr(e));for(var g=a.j.get(e),h=b.va();b.va()-h<f;){e=g;var k=b,l=Xr(k),m=l.value,n=l.pts;if(16===m){var q=Xr(k);m=m<<16|q.value}if(0<=m&&31>=m){k=e;var p=m,w=n;if(k.g){var u=k.g;e=null;switch(p){case 8:!Sr(u)||0>=u.g&&0>=u.h||(0>=u.g?(u.g=u.m-1,u.h--):u.g--,u.i[u.h][u.g]=null);break;case 13:u.isVisible()&&(e=Tr(u,w,k.i));if(u.h+1>=u.o){k=
896
- u;p=0;for(w=1;16>w;w++,p++)k.i[p]=k.i[w];for(w=0;1>w;w++,p++)k.i[p]=Qr()}else u.h++;u.g=0;break;case 14:u.isVisible()&&(e=Tr(u,w,k.i));u.i[u.h]=Qr();u.g=0;break;case 12:u.isVisible()&&(e=Tr(u,w,k.i)),Pr(u),k=u,k.h=0,k.g=0}var v=e}else v=null}else if(128<=m&&159>=m)v=Zr(e,k,m,n);else{if(4096<=m&&4127>=m)e=k,k=m&255,8<=k&&15>=k?e.skip(1):16<=k&&23>=k?e.skip(2):24<=k&&31>=k&&e.skip(3);else if(4224<=m&&4255>=m)e=k,k=m&255,128<=k&&135>=k?e.skip(4):136<=k&&143>=k&&e.skip(5);else if(32<=m&&127>=m)k=m,e.g&&
897
- (127===k?Rr(e.g,"\u266a"):Rr(e.g,String.fromCharCode(k)));else if(160<=m&&255>=m)e.g&&Rr(e.g,String.fromCharCode(m));else if(4128<=m&&4223>=m){if(k=m&255,e.g)if(es.has(k)){var A=es.get(k);Rr(e.g,A)}else Rr(e.g,"_")}else 4256<=m&&4351>=m&&e.g&&(160!=(m&255)?Rr(e.g,"_"):Rr(e.g,"[CC]"));v=null}(e=v)&&c.push(e)}}}}catch(z){if(z instanceof T&&3E3===z.code)$a("CEA708_INVALID_DATA","Buffer read out of bounds / invalid CEA-708 Data.");else throw z;}return c}
895
+ function is(a,b){var c=[];try{for(;b.pa();){var d=Xr(b).value,e=(d&224)>>5,f=d&31;7===e&&0!=f&&(e=Xr(b).value&63);if(0!=e){a.A.add("svc"+e);a.j.has(e)||a.j.set(e,new Yr(e));for(var g=a.j.get(e),h=b.va();b.va()-h<f;){e=g;var k=b,l=Xr(k),m=l.value,n=l.pts;if(16===m){var p=Xr(k);m=m<<16|p.value}if(0<=m&&31>=m){k=e;var r=m,u=n;if(k.g){var v=k.g;e=null;switch(r){case 8:!Sr(v)||0>=v.g&&0>=v.h||(0>=v.g?(v.g=v.m-1,v.h--):v.g--,v.i[v.h][v.g]=null);break;case 13:v.isVisible()&&(e=Tr(v,u,k.i));if(v.h+1>=v.o){k=
896
+ v;r=0;for(u=1;16>u;u++,r++)k.i[r]=k.i[u];for(u=0;1>u;u++,r++)k.i[r]=Qr()}else v.h++;v.g=0;break;case 14:v.isVisible()&&(e=Tr(v,u,k.i));v.i[v.h]=Qr();v.g=0;break;case 12:v.isVisible()&&(e=Tr(v,u,k.i)),Pr(v),k=v,k.h=0,k.g=0}var w=e}else w=null}else if(128<=m&&159>=m)w=Zr(e,k,m,n);else{if(4096<=m&&4127>=m)e=k,k=m&255,8<=k&&15>=k?e.skip(1):16<=k&&23>=k?e.skip(2):24<=k&&31>=k&&e.skip(3);else if(4224<=m&&4255>=m)e=k,k=m&255,128<=k&&135>=k?e.skip(4):136<=k&&143>=k&&e.skip(5);else if(32<=m&&127>=m)k=m,e.g&&
897
+ (127===k?Rr(e.g,"\u266a"):Rr(e.g,String.fromCharCode(k)));else if(160<=m&&255>=m)e.g&&Rr(e.g,String.fromCharCode(m));else if(4128<=m&&4223>=m){if(k=m&255,e.g)if(es.has(k)){var A=es.get(k);Rr(e.g,A)}else Rr(e.g,"_")}else 4256<=m&&4351>=m&&e.g&&(160!=(m&255)?Rr(e.g,"_"):Rr(e.g,"[CC]"));w=null}(e=w)&&c.push(e)}}}}catch(z){if(z instanceof T&&3E3===z.code)$a("CEA708_INVALID_DATA","Buffer read out of bounds / invalid CEA-708 Data.");else throw z;}return c}
898
898
  function js(a){for(var b=0;a;)b^=a&1,a>>=1;return 1===b}fs.prototype.getStreams=function(){return Array.from(this.A)};S("shaka.cea.CeaDecoder",fs);Ib=function(){return new fs};function ks(a){for(var b=[],c=a,d=a=0;d<c.length;)2==a&&3==c[d]?(a=0,c=[].concat(x(c)),c.splice(d,1),c=new Uint8Array(c)):0==c[d]?a++:a=0,d++;a=c;for(d=0;d<a.length;){for(c=0;255==a[d];)c+=255,d++;c+=a[d++];for(var e=0;255==a[d];)e+=255,d++;e+=a[d++];4==c&&b.push(a.subarray(d,d+e));d+=e}return b};function ls(){this.j=new Map;this.i=this.h=0;this.g=ms}
899
899
  ls.prototype.init=function(a){function b(f){f=f.name;f in ns&&(c.g=ns[f])}var c=this,d=[],e=[];(new Lg).box("moov",Qg).box("mvex",Qg).S("trex",function(f){var g=f.reader;g.skip(4);g.skip(4);f=g.R();g=g.R();c.h=f;c.i=g}).box("trak",Qg).S("tkhd",function(f){var g=f.reader;f=f.version;1==f?(g.skip(8),g.skip(8)):(g.skip(4),g.skip(4));var h=g.R();1==f?g.skip(8):g.skip(4);g.skip(4);g.skip(8);g.skip(2);g.skip(2);g.skip(2);g.skip(2);g.skip(36);g.na();g.na();g.na();g.na();d.push(h)}).box("mdia",Qg).S("mdhd",
900
900
  function(f){f=aj(f.reader,f.version);e.push(f.timescale)}).box("minf",Qg).box("stbl",Qg).S("stsd",Sg).box("avc1",b).box("avc3",b).box("dvav",b).box("dva1",b).box("hev1",b).box("hvc1",b).box("dvh1",b).box("dvhe",b).box("vvc1",b).box("vvi1",b).box("dvc1",b).box("dvi1",b).box("encv",Tg).box("sinf",Qg).box("frma",function(f){f=dj(f.reader).codec;f in ns&&(c.g=ns[f])}).parse(a,!0);if(!d.length||!e.length||d.length!=e.length)throw new T(2,2,2010);this.g==ms&&Ya("Unable to determine bitstream format for CEA parsing!");
901
901
  d.forEach(function(f,g){c.j.set(f,e[g])})};
902
- ls.prototype.parse=function(a){var b=this;if(this.g==ms)return[];var c=[],d=0,e=[];(new Lg).box("moof",function(f){d=f.start;e=[];Qg(f)}).box("traf",function(f){e.push({baseMediaDecodeTime:null,Xc:b.h,Fd:b.i,Og:[],timescale:9E4});Qg(f)}).S("trun",function(f){var g=e[e.length-1];f=bj(f.reader,f.version,f.flags);g.Og.push(f)}).S("tfhd",function(f){var g=e[e.length-1];f=Zi(f.reader,f.flags);g.Xc=f.Xc||b.h;g.Fd=f.Fd||b.i;f=f.trackId;b.j.has(f)&&(g.timescale=b.j.get(f))}).S("tfdt",function(f){var g=e[e.length-
903
- 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.va(),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 T(2,2,2010);f.reader.seek(h);os(b,f.reader,l.baseMediaDecodeTime,l.timescale,l.Xc,l.Fd,g,l.Og,c)}}).parse(a,!1);return c};
904
- function os(a,b,c,d,e,f,g,h,k){var l=0,m=f,n=h.map(function(w){return w.Wg});n=[].concat.apply([],x(n));n.length&&(m=n[0].sampleSize||f);for(b.skip(g+h[0].Fh);b.pa();){g=b.R();var q=b.U(),p=null;p=!1;h=1;switch(a.g){case ps:p=q&31;p=6==p;break;case qs:h=2;b.skip(1);p=q>>1&63;p=39==p||40==p;break;case rs:h=2;b.skip(1);p=q>>1&63;p=23==p||24==p;break;default:return}if(p)for(q=0,l<n.length&&(q=n[l].me||0),q=(c+q)/d,h=t(ks(b.qb(g-h))),p=h.next();!p.done;p=h.next())k.push({packet:p.value,pts:q});else try{b.skip(g-
905
- h)}catch(w){break}m-=g+4;0==m&&(c=l<n.length?c+(n[l].Jf||e):c+e,l++,l<n.length?m=n[l].sampleSize||f:m=f)}}S("shaka.cea.Mp4CeaParser",ls);var ms=0,ps=1,qs=2,rs=3,ns={avc1:ps,avc3:ps,dvav:ps,dva1:ps,hev1:qs,hvc1:qs,dvh1:qs,dvhe:qs,vvc1:rs,vvi1:rs,dvc1:rs,dvi1:rs};Hb["video/mp4"]=function(){return new ls};function ss(){this.g=null}ss.prototype.init=function(){};ss.prototype.parse=function(a){this.g?this.g.clearData():this.g=new sj;var b=[];a=zb(a);if(!Gj(a))return b;a=this.g.parse(a);var c=a.Zc(),d=a.Md();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(ks(d.data)),f=e.next();!f.done;f=e.next())b.push({packet:f.value,pts:d.time});return b};
906
- S("shaka.cea.TsCeaParser",ss);Hb["video/mp2t"]=function(){return new ss};function ts(a,b,c){var d=us(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 T(2,4,4010);if(!b){f=d.filter(function(l){return"urn:mpeg:dash:sea:2012"==l.Oc});if(1<f.length)throw new T(2,4,4050);f.length&&(g=vs(f[0]));(f=d.find(function(l){return"urn:mpeg:dash:mp4protection:2011"==l.Oc}))&&f.encryptionScheme&&(k=f.encryptionScheme);f=d.filter(function(l){return"urn:mpeg:dash:mp4protection:2011"==l.Oc?(e=l.init||e,!1):"urn:mpeg:dash:sea:2012"!=
907
- l.Oc});f.length&&(a=ws(e,k,f,c,h),0==a.length&&(a=[Pd("",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(Pd(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{pg:h,dk:e,drmInfos:a,Ee:g,tg:!0}}
902
+ ls.prototype.parse=function(a){var b=this;if(this.g==ms)return[];var c=[],d=0,e=[];(new Lg).box("moof",function(f){d=f.start;e=[];Qg(f)}).box("traf",function(f){e.push({baseMediaDecodeTime:null,Yc:b.h,Fd:b.i,Og:[],timescale:9E4});Qg(f)}).S("trun",function(f){var g=e[e.length-1];f=bj(f.reader,f.version,f.flags);g.Og.push(f)}).S("tfhd",function(f){var g=e[e.length-1];f=Zi(f.reader,f.flags);g.Yc=f.Yc||b.h;g.Fd=f.Fd||b.i;f=f.trackId;b.j.has(f)&&(g.timescale=b.j.get(f))}).S("tfdt",function(f){var g=e[e.length-
903
+ 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.va(),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 T(2,2,2010);f.reader.seek(h);os(b,f.reader,l.baseMediaDecodeTime,l.timescale,l.Yc,l.Fd,g,l.Og,c)}}).parse(a,!1);return c};
904
+ function os(a,b,c,d,e,f,g,h,k){var l=0,m=f,n=h.map(function(u){return u.Wg});n=[].concat.apply([],x(n));n.length&&(m=n[0].sampleSize||f);for(b.skip(g+h[0].Fh);b.pa();){g=b.R();var p=b.U(),r=null;r=!1;h=1;switch(a.g){case ps:r=p&31;r=6==r;break;case qs:h=2;b.skip(1);r=p>>1&63;r=39==r||40==r;break;case rs:h=2;b.skip(1);r=p>>1&63;r=23==r||24==r;break;default:return}if(r)for(p=0,l<n.length&&(p=n[l].me||0),p=(c+p)/d,h=t(ks(b.qb(g-h))),r=h.next();!r.done;r=h.next())k.push({packet:r.value,pts:p});else try{b.skip(g-
905
+ h)}catch(u){break}m-=g+4;0==m&&(c=l<n.length?c+(n[l].Jf||e):c+e,l++,l<n.length?m=n[l].sampleSize||f:m=f)}}S("shaka.cea.Mp4CeaParser",ls);var ms=0,ps=1,qs=2,rs=3,ns={avc1:ps,avc3:ps,dvav:ps,dva1:ps,hev1:qs,hvc1:qs,dvh1:qs,dvhe:qs,vvc1:rs,vvi1:rs,dvc1:rs,dvi1:rs};Hb["video/mp4"]=function(){return new ls};function ss(){this.g=null}ss.prototype.init=function(){};ss.prototype.parse=function(a){this.g?this.g.clearData():this.g=new sj;var b=[];a=zb(a);if(!Gj(a))return b;a=this.g.parse(a);var c=a.$c(),d=a.Md();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(ks(d.data)),f=e.next();!f.done;f=e.next())b.push({packet:f.value,pts:d.time});return b};
906
+ S("shaka.cea.TsCeaParser",ss);Hb["video/mp2t"]=function(){return new ss};function ts(a,b,c){var d=us(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 T(2,4,4010);if(!b){f=d.filter(function(l){return"urn:mpeg:dash:sea:2012"==l.Pc});if(1<f.length)throw new T(2,4,4050);f.length&&(g=vs(f[0]));(f=d.find(function(l){return"urn:mpeg:dash:mp4protection:2011"==l.Pc}))&&f.encryptionScheme&&(k=f.encryptionScheme);f=d.filter(function(l){return"urn:mpeg:dash:mp4protection:2011"==l.Pc?(e=l.init||e,!1):"urn:mpeg:dash:sea:2012"!=
907
+ l.Pc});f.length&&(a=ws(e,k,f,c,h),0==a.length&&(a=[Pd("",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(Pd(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{pg:h,dk:e,drmInfos:a,Ee:g,tg:!0}}
908
908
  function xs(a,b,c,d){var e=ts(a,c,d);if(b.tg){a=1==b.drmInfos.length&&!b.drmInfos[0].keySystem;c=0==e.drmInfos.length;if(0==b.drmInfos.length||a&&!c)b.drmInfos=e.drmInfos;b.tg=!1}else if(0<e.drmInfos.length&&(b.drmInfos=b.drmInfos.filter(function(f){return e.drmInfos.some(function(g){return g.keySystem==f.keySystem})}),0==b.drmInfos.length))throw new T(2,4,4008);return e.pg||b.pg}
909
909
  function ys(a){var b=0,c=Eb(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=zb(c,a,e);b.push({type:d,value:f});a+=e}c=b}return c}function zs(a){a=t(kh(a,"DATA"));for(var b=a.next();!b.done;b=a.next())if(b=b.value,b.children){b=t(b.children);for(var c=b.next();!c.done;c=b.next())if(c=c.value,"LA_URL"==c.tagName)return ih(c)}return""}
910
910
  function As(a){var b=mh(a.node,"https://dashif.org/CPS","Laurl");if(b&&(b=ih(b)))return b;a=mh(a.node,"urn:microsoft:playready","pro");if(!a||!ih(a))return"";a=ih(a);a=Gd(a);a=ys(a).filter(function(c){return c.type===Bs})[0];if(!a)return"";a=wd(a.value,!0);return(a=ah(a,"WRMHEADER"))?zs(a):""}
911
- function ws(a,b,c,d,e){var f=[];c=t(c);for(var g=c.next();!g.done;g=c.next()){g=g.value;var h=d[g.Oc];if(h){var k;if((k=mh(g.node,"urn:microsoft:playready","pro"))&&ih(k)){k=ih(k);k=Gd(k);var l=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);k=[{initData:Zg(k,l,new Set,0),initDataType:"cenc",keyId:g.keyId}]}else k=null;l=null;if("urn:uuid:e2719d58-a985-b3c9-781a-b030af78d30e"===g.Oc){l=g;var m=e;if(0==m.size)l=null;else{var n=new Uint8Array([16,119,239,236,192,178,77,2,
912
- 172,227,60,30,82,226,251,75]),q=new Uint8Array([]);l=[{initData:Zg(q,n,m,1),initDataType:"cenc",keyId:l.keyId}]}}k=Pd(h,b,g.init||a||k||l);if(h=Cs.get(h))k.licenseServerUri=h(g);f.push(k)}}return f}function us(a){var b=[];a=t(a);for(var c=a.next();!c.done;c=a.next())(c=Ds(c.value))&&b.push(c);return b}
913
- function Ds(a){var b=a.attributes.schemeIdUri,c=ph(a,"urn:mpeg:cenc:2013","default_KID"),d=nh(a,"urn:mpeg:cenc:2013","pssh").map(jh),e=a.attributes.value;if(!b)return null;b=b.toLowerCase();if(c&&(c=c.replace(/-/g,"").toLowerCase(),c.includes(" ")))throw new T(2,4,4009);var f=[];try{f=d.map(function(g){return{initDataType:"cenc",initData:Gd(g),keyId:null}})}catch(g){throw new T(2,4,4007);}return{node:a,Oc:b,keyId:c,init:0<f.length?f:null,encryptionScheme:e}}
911
+ function ws(a,b,c,d,e){var f=[];c=t(c);for(var g=c.next();!g.done;g=c.next()){g=g.value;var h=d[g.Pc];if(h){var k;if((k=mh(g.node,"urn:microsoft:playready","pro"))&&ih(k)){k=ih(k);k=Gd(k);var l=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);k=[{initData:Zg(k,l,new Set,0),initDataType:"cenc",keyId:g.keyId}]}else k=null;l=null;if("urn:uuid:e2719d58-a985-b3c9-781a-b030af78d30e"===g.Pc){l=g;var m=e;if(0==m.size)l=null;else{var n=new Uint8Array([16,119,239,236,192,178,77,2,
912
+ 172,227,60,30,82,226,251,75]),p=new Uint8Array([]);l=[{initData:Zg(p,n,m,1),initDataType:"cenc",keyId:l.keyId}]}}k=Pd(h,b,g.init||a||k||l);if(h=Cs.get(h))k.licenseServerUri=h(g);f.push(k)}}return f}function us(a){var b=[];a=t(a);for(var c=a.next();!c.done;c=a.next())(c=Ds(c.value))&&b.push(c);return b}
913
+ function Ds(a){var b=a.attributes.schemeIdUri,c=ph(a,"urn:mpeg:cenc:2013","default_KID"),d=nh(a,"urn:mpeg:cenc:2013","pssh").map(jh),e=a.attributes.value;if(!b)return null;b=b.toLowerCase();if(c&&(c=c.replace(/-/g,"").toLowerCase(),c.includes(" ")))throw new T(2,4,4009);var f=[];try{f=d.map(function(g){return{initDataType:"cenc",initData:Gd(g),keyId:null}})}catch(g){throw new T(2,4,4007);}return{node:a,Pc:b,keyId:c,init:0<f.length?f:null,encryptionScheme:e}}
914
914
  function vs(a){if(!window.crypto||!window.crypto.subtle)throw Ya("Web Crypto API is not available to decrypt AES-128. (Web Crypto only exists in secure origins like https)"),new T(2,4,4042);var b=mh(a.node,"urn:mpeg:dash:schema:sea:2012","SegmentEncryption");if(!b)throw new T(2,4,4051);if("urn:mpeg:dash:sea:aes128-cbc:2013"!=b.attributes.schemeIdUri)throw new T(2,4,4051);b=mh(a.node,"urn:mpeg:dash:schema:sea:2012","CryptoPeriod");if(!b)throw new T(2,4,4051);a=b.attributes.IV;b=Cd(b.attributes.keyUriTemplate);
915
915
  if(!a||!b)throw new T(2,4,4051);a=Hd(a.substr(2));if(16!=a.byteLength)throw new T(2,4,4048);return{ti:b,iv:a}}
916
916
  var Bs=1,Cs=(new Map).set("com.widevine.alpha",function(a){var b=mh(a.node,"https://dashif.org/CPS","Laurl");return b&&(b=ih(b))?b:(a=mh(a.node,"urn:microsoft","laurl"))?Cd(a.attributes.licenseUrl)||"":""}).set("com.microsoft.playready",As).set("com.microsoft.playready.recommendation",As).set("com.microsoft.playready.software",As).set("com.microsoft.playready.hardware",As).set("org.w3.clearkey",function(a){var b=mh(a.node,"https://dashif.org/CPS","Laurl");return b&&(b=ih(b))?b:(a=mh(a.node,"http://dashif.org/guidelines/clearKey",
917
917
  "Laurl"))&&"EME-1.0"===a.attributes.Lic_type&&a&&(a=ih(a))?a:""});function Es(a,b,c,d,e,f){var g={RepresentationID:b,Number:c,SubNumber:d,Bandwidth:e,Time:f};return a.replace(/\$(RepresentationID|Number|SubNumber|Bandwidth|Time)?(?:%0([0-9]+)([diouxX]))?\$/g,function(h,k,l,m){if("$$"==h)return"$";var n=g[k];if(null==n)return h;"RepresentationID"==k&&l&&(l=void 0);"Time"==k&&"bigint"!=typeof n&&(.2<=Math.abs(n-Math.round(n))&&Ya("Calculated $Time$ values must be close to integers"),n=Math.round(n));switch(m){case void 0:case "d":case "i":case "u":h=n.toString();
918
918
  break;case "o":h=n.toString(8);break;case "x":h=n.toString(16);break;case "X":h=n.toString(16).toUpperCase();break;default:h=n.toString()}l=window.parseInt(l,10)||1;return Array(Math.max(0,l-h.length)+1).join("0")+h})}
919
- function Fs(a,b){var c=Gs(a,b,"timescale"),d=1;c&&(d=vh(c)||1);c=Gs(a,b,"duration");(c=vh(c||""))&&(c/=d);var e=Gs(a,b,"startNumber"),f=Number(Gs(a,b,"presentationTimeOffset"))||0,g=wh(e||"");if(null==e||null==g)g=1;e=null;if(b=Hs(a,b,"SegmentTimeline")){b=hh(b,"S");e=d;a=a.ga.duration||Infinity;for(var h=g,k=[],l=-f,m=0;m<b.length;++m){var n=b[m],q=b[m+1],p=oh(n,"t",wh),w=oh(n,"d",wh),u=oh(n,"r",uh);n=oh(n,"k",uh)||0;null!=p&&(p-=f);if(w){p=null!=p?p:l;u=u||0;if(0>u)if(q){q=oh(q,"t",wh);if(null==
920
- q)break;else if(p>=q)break;u=Math.ceil((q-p)/w)-1}else{if(Infinity==a)break;else if(p/e>=a)break;u=Math.ceil((a*e-p)/w)-1}0<k.length&&p!=l&&(k[k.length-1].end=p/e);for(q=0;q<=u;++q)l=p+w,k.push({start:p/e,end:l/e,$f:p,zb:n,Si:k.length+h}),p=l}}e=k}return{timescale:d,Ka:c,td:g,Nb:f/d||0,Zf:f,timeline:e}}function Is(a,b){return[b(a.J),b(a.ia),b(a.ma)].filter(Ae)}function Gs(a,b,c){b=Is(a,b);a=null;b=t(b);for(var d=b.next();!d.done&&!(a=d.value.attributes[c]);d=b.next());return a}
919
+ function Fs(a,b){var c=Gs(a,b,"timescale"),d=1;c&&(d=vh(c)||1);c=Gs(a,b,"duration");(c=vh(c||""))&&(c/=d);var e=Gs(a,b,"startNumber"),f=Number(Gs(a,b,"presentationTimeOffset"))||0,g=wh(e||"");if(null==e||null==g)g=1;e=null;if(b=Hs(a,b,"SegmentTimeline")){b=hh(b,"S");e=d;a=a.ga.duration||Infinity;for(var h=g,k=[],l=-f,m=0;m<b.length;++m){var n=b[m],p=b[m+1],r=oh(n,"t",wh),u=oh(n,"d",wh),v=oh(n,"r",uh);n=oh(n,"k",uh)||0;null!=r&&(r-=f);if(u){r=null!=r?r:l;v=v||0;if(0>v)if(p){p=oh(p,"t",wh);if(null==
920
+ p)break;else if(r>=p)break;v=Math.ceil((p-r)/u)-1}else{if(Infinity==a)break;else if(r/e>=a)break;v=Math.ceil((a*e-r)/u)-1}0<k.length&&r!=l&&(k[k.length-1].end=r/e);for(p=0;p<=v;++p)l=r+u,k.push({start:r/e,end:l/e,$f:r,zb:n,Si:k.length+h}),r=l}}e=k}return{timescale:d,Ka:c,td:g,Nb:f/d||0,Zf:f,timeline:e}}function Is(a,b){return[b(a.J),b(a.ia),b(a.ma)].filter(Ae)}function Gs(a,b,c){b=Is(a,b);a=null;b=t(b);for(var d=b.next();!d.done&&!(a=d.value.attributes[c]);d=b.next());return a}
921
921
  function Hs(a,b,c){b=Is(a,b);a=null;b=t(b);for(var d=b.next();!d.done&&!(a=lh(d.value,c));d=b.next());return a}
922
- function Js(a,b,c,d,e,f){for(var g=ph(a,"http://www.w3.org/1999/xlink","href"),h=ph(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=ch("http://www.w3.org/1999/xlink");m[0]==n&&delete a.attributes[l]}if(5<=f)return dg(new T(2,4,4028));if("onLoad"!=h)return dg(new T(2,4,4027));var q=Md([d],[g]);return e.request(0,tg(q,b)).Aa(function(p){p=$g(p.data,a.tagName);if(!p)return dg(new T(2,4,4001,g));for(a.children=
923
- [];p.children.length;){var w=p.children.shift();w.tagName&&(w.parent=a);a.children.push(w)}w=t(Object.keys(p.attributes));for(var u=w.next();!u.done;u=w.next())u=u.value,a.attributes[u]=p.attributes[u];return Ks(a,b,c,q[0],e,f+1)})}
924
- function Ks(a,b,c,d,e,f){f=void 0===f?0:f;if(ph(a,"http://www.w3.org/1999/xlink","href")){var g=Js(a,b,c,d,e,f);c&&(g=g.Aa(void 0,function(){return Ks(a,b,c,d,e,f)}));return g}g=[];for(var h=t(gh(a)),k=h.next(),l={};!k.done;l={Tc:void 0},k=h.next())l.Tc=k.value,"urn:mpeg:dash:resolve-to-zero:2013"==ph(l.Tc,"http://www.w3.org/1999/xlink","href")?a.children=a.children.filter(function(m){return function(n){return n!==m.Tc}}(l)):"SegmentTimeline"!=l.Tc.tagName&&g.push(Ks(l.Tc,b,c,d,e,f));return hg(g).Aa(function(){return a})}
922
+ function Js(a,b,c,d,e,f){for(var g=ph(a,"http://www.w3.org/1999/xlink","href"),h=ph(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=ch("http://www.w3.org/1999/xlink");m[0]==n&&delete a.attributes[l]}if(5<=f)return dg(new T(2,4,4028));if("onLoad"!=h)return dg(new T(2,4,4027));var p=Md([d],[g]);return e.request(0,tg(p,b)).Aa(function(r){r=$g(r.data,a.tagName);if(!r)return dg(new T(2,4,4001,g));for(a.children=
923
+ [];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 Ks(a,b,c,p[0],e,f+1)})}
924
+ function Ks(a,b,c,d,e,f){f=void 0===f?0:f;if(ph(a,"http://www.w3.org/1999/xlink","href")){var g=Js(a,b,c,d,e,f);c&&(g=g.Aa(void 0,function(){return Ks(a,b,c,d,e,f)}));return g}g=[];for(var h=t(gh(a)),k=h.next(),l={};!k.done;l={Uc:void 0},k=h.next())l.Uc=k.value,"urn:mpeg:dash:resolve-to-zero:2013"==ph(l.Uc,"http://www.w3.org/1999/xlink","href")?a.children=a.children.filter(function(m){return function(n){return n!==m.Uc}}(l)):"SegmentTimeline"!=l.Uc.tagName&&g.push(Ks(l.Uc,b,c,d,e,f));return hg(g).Aa(function(){return a})}
925
925
  ;function Ls(a,b,c,d,e,f,g){var h,k=(new Lg).S("sidx",function(l){h=Ms(b,d,e,f,g,c,l)});a&&k.parse(a);if(h)return h;throw new T(2,3,3004);}
926
- function Ms(a,b,c,d,e,f,g){var h=[];g.reader.skip(4);var k=g.reader.R();if(0==k)throw new T(2,3,3005);if(0==g.version){var l=g.reader.R();var m=g.reader.R()}else l=g.reader.Mc(),m=g.reader.Mc();g.reader.skip(2);var n=g.reader.na();a=a+g.size+m;for(m=0;m<n;m++){var q=g.reader.R(),p=(q&2147483648)>>>31;q&=2147483647;var w=g.reader.R();g.reader.skip(4);if(1==p)throw new T(2,3,3006);h.push(new Fi(l/k+c,(l+w)/k+c,function(){return f},a,a+q-1,b,c,d,e));l+=w;a+=q}g.parser.stop();return h};function Ns(a){this.h=Eb(a);this.g=new Ig(this.h,0)}Ns.prototype.pa=function(){return this.g.pa()};
926
+ function Ms(a,b,c,d,e,f,g){var h=[];g.reader.skip(4);var k=g.reader.R();if(0==k)throw new T(2,3,3005);if(0==g.version){var l=g.reader.R();var m=g.reader.R()}else l=g.reader.Nc(),m=g.reader.Nc();g.reader.skip(2);var n=g.reader.na();a=a+g.size+m;for(m=0;m<n;m++){var p=g.reader.R(),r=(p&2147483648)>>>31;p&=2147483647;var u=g.reader.R();g.reader.skip(4);if(1==r)throw new T(2,3,3006);h.push(new Fi(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 Ns(a){this.h=Eb(a);this.g=new Ig(this.h,0)}Ns.prototype.pa=function(){return this.g.pa()};
927
927
  function Os(a){var b=Ps(a);if(7<b.length)throw new T(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=Ps(a);a:{d=t(Qs);for(var e=d.next();!e.done;e=d.next())if(xb(b,new Uint8Array(e.value))){d=!0;break a}d=!1}if(d)b=a.h.byteLength-a.g.va();else{if(8==b.length&&b[1]&224)throw new T(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.va()+b<=a.h.byteLength?b:a.h.byteLength-a.g.va();d=Eb(a.h,a.g.va(),b);a.g.skip(b);return new Rs(c,
928
928
  d)}function Ps(a){var b=a.g.va(),c=a.g.U();if(0==c)throw new T(2,3,3002);c=8-Math.floor(Math.log2(c));a.g.skip(c-1);return zb(a.h,b,c)}var Qs=[[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 Rs(a,b){this.id=a;this.g=b}
929
- function Ss(a){if(8<a.g.byteLength)throw new T(2,3,3002);if(8==a.g.byteLength&&a.g.getUint8(0)&224)throw new T(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 Ts(a,b,c,d,e,f,g,h,k){function l(){return e}var m=[];a=new Ns(a.g);for(var n=null,q=null;a.pa();){var p=Os(a);if(187==p.id){var w=Us(p);w&&(p=c*w.dj,w=b+w.Ii,null!=n&&m.push(new Fi(n+g,p+g,l,q,w-1,f,g,h,k)),n=p,q=w)}}null!=n&&m.push(new Fi(n+g,d+g,l,q,null,f,g,h,k));return m}
929
+ function Ss(a){if(8<a.g.byteLength)throw new T(2,3,3002);if(8==a.g.byteLength&&a.g.getUint8(0)&224)throw new T(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 Ts(a,b,c,d,e,f,g,h,k){function l(){return e}var m=[];a=new Ns(a.g);for(var n=null,p=null;a.pa();){var r=Os(a);if(187==r.id){var u=Us(r);u&&(r=c*u.dj,u=b+u.Ii,null!=n&&m.push(new Fi(n+g,r+g,l,p,u-1,f,g,h,k)),n=r,p=u)}}null!=n&&m.push(new Fi(n+g,d+g,l,p,null,f,g,h,k));return m}
930
930
  function Us(a){var b=new Ns(a.g);a=Os(b);if(179!=a.id)throw new T(2,3,3013);a=Ss(a);b=Os(b);if(183!=b.id)throw new T(2,3,3012);b=new Ns(b.g);for(var c=0;b.pa();){var d=Os(b);if(241==d.id){c=Ss(d);break}}return{dj:a,Ii:c}};function Vs(a,b,c){b=Hs(a,b,"Initialization");if(!b)return null;var d=a.J.Ma(),e=b.attributes.sourceURL;e&&(d=Md(d,[Cd(e)]));e=0;var f=null;if(b=oh(b,"range",th))e=b.start,f=b.end;c=new Di(function(){return d},e,f,Ws(a),null,null,c);c.codecs=a.J.codecs;c.mimeType=a.J.mimeType;return c}
931
931
  function Xs(a,b,c){var d=Number(Gs(a,Ys,"presentationTimeOffset"))||0,e=Gs(a,Ys,"timescale"),f=1;e&&(f=vh(e)||1);var g=d/f||0,h=Vs(a,Ys,c);Zs(a,h);var k=Me(a);return{ic:function(){var l=Hs(k,Ys,"RepresentationIndex");var m=k.J.Ma();l&&(l=Cd(l.attributes.sourceURL))&&(m=Md(m,[l]));l=$s(k);return at(k,b,h,m,l.start,l.end,g)}}}
932
- function at(a,b,c,d,e,f,g){var h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G;return O(function(L){if(1==L.g)return h=a.presentationTimeline,k=!a.vb||!a.ga.pf,l=a.ga.start,m=a.ga.duration,n=a.J.mimeType.split("/")[1],q=b,p=null,w=[q(d,e,f,!1),"webm"==n?q(c.M(),c.Ga,c.ta,!0):null],q=null,F(L,Promise.all(w),2);u=L.h;v=u[0];A=u[1]||null;z=null;D=l-g;y=l;B=m?l+m:Infinity;if("mp4"==n)var K=Ls(v,e,d,c,D,y,B);else{K=v;var I=new Ns(A);if(440786851!=Os(I).id)throw new T(2,3,3008);var J=Os(I);if(408125543!=J.id)throw new T(2,
933
- 3,3009);I=J.g.byteOffset;J=new Ns(J.g);for(var N=null;J.pa();){var M=Os(J);if(357149030==M.id){N=M;break}}if(!N)throw new T(2,3,3010);N=new Ns(N.g);M=1E6;for(J=null;N.pa();){var P=Os(N);if(2807729==P.id)M=Ss(P);else if(17545==P.id)if(4==P.g.byteLength)J=P.g.getFloat32(0);else if(8==P.g.byteLength)J=P.g.getFloat64(0);else throw new T(2,3,3003);}if(null==J)throw new T(2,3,3011);N=M/1E9;J*=N;K=Os(new Ns(K));if(475249515!=K.id)throw new T(2,3,3007);K=Ts(K,I,N,J,d,c,D,y,B)}z=K;C=t(z);for(E=C.next();!E.done;E=
934
- C.next())G=E.value,G.codecs=a.J.codecs,G.mimeType=a.J.mimeType;h.qd(z);p=new Ok(z);k&&p.Cc(y,B,!0);return L.return(p)})}function Ys(a){return a.Qc}function $s(a){var b=Hs(a,Ys,"RepresentationIndex");a=Gs(a,Ys,"indexRange");a=th(a||"");b&&(a=oh(b,"range",th,a));return a}function Zs(a,b){bt(a,b);if(!$s(a))throw new T(2,4,4002);}function bt(a,b){var c=a.J.mimeType.split("/")[1];if(a.J.contentType!=Ud&&"mp4"!=c&&"webm"!=c)throw new T(2,4,4006);if("webm"==c&&!b)throw new T(2,4,4005);}
935
- function Ws(a){var b=a.J;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.be,pixelAspectRatio:b.pixelAspectRatio||null,width:b.width||null,label:a.ia.label||null,roles:a.roles||null,language:a.ia.language||null}};function ct(a,b,c){var d=Vs(a,dt,c),e=et(a);if(!e.Ka&&!e.timeline&&1<e.Ic.length)throw new T(2,4,4002);if(!e.Ka&&!a.ga.duration&&!e.timeline&&1==e.Ic.length)throw new T(2,4,4002);if(e.timeline&&0==e.timeline.length)throw new T(2,4,4002);var f=null,g=null;a.ma.id&&a.J.id&&(g=b[a.ma.id+","+a.J.id])&&(f=g.segmentIndex);var h=ft(a.ga.start,a.ga.duration,a.J.Ma,e,d,c,a.J.mimeType,a.J.codecs);b=!f;f?f.pd(h,a.presentationTimeline.mb()):f=new Ok(h);a.presentationTimeline.qd(h);a.vb&&a.ga.pf||f.Cc(a.ga.start,
936
- a.ga.duration?a.ga.start+a.ga.duration:Infinity,b);g&&(g.segmentIndex=f);return{ic:function(){f&&0!=f.getNumReferences()||f.Xd(h);return Promise.resolve(f)}}}function dt(a){return a.Pb}function et(a){var b=gt(a);a=Fs(a,dt);var c=a.td;0==c&&(c=1);var d=0;a.Ka?d=a.Ka*(c-1):a.timeline&&0<a.timeline.length&&(d=a.timeline[0].start);return{Ka:a.Ka,startTime:d,td:c,Nb:a.Nb,timeline:a.timeline,Ic:b}}
937
- function ft(a,b,c,d,e,f,g,h){var k=d.Ic.length;d.timeline&&d.timeline.length!=d.Ic.length&&(k=Math.min(d.timeline.length,d.Ic.length));for(var l=a-d.Nb,m=b?a+b:Infinity,n=[],q=d.startTime,p={},w=0;w<k;p={ue:void 0,ne:void 0},w++){p.ne=d.Ic[w];var u=q;q=void 0;q=null!=d.Ka?u+d.Ka:d.timeline?d.timeline[w].end:u+b;p.ue=null;p=new Fi(a+u,a+q,function(v){return function(){null==v.ue&&(v.ue=Md(c(),[v.ne.zi]));return v.ue}}(p),p.ne.start,p.ne.end,e,l,a,m,[],"",null,null,Gi,f);p.codecs=h;p.mimeType=g;n.push(p)}return n}
938
- function gt(a){return[a.J.Pb,a.ia.Pb,a.ma.Pb].filter(Ae).map(function(b){return hh(b,"SegmentURL")}).reduce(function(b,c){return 0<b.length?b:c}).map(function(b){b.attributes.indexRange&&!a.kf&&(a.kf=!0);var c=Cd(b.attributes.media);b=oh(b,"mediaRange",th,{start:0,end:null});return{zi:c,start:b.start,end:b.end}})};function ht(a,b,c,d,e,f,g,h,k){k||a.J.Pd||(a.J.Pd=Gs(a,it,"initialization"));var l=a.J.Pd?jt(a,g):null,m=kt(a);lt(m);var n=Me(a);if(m.hd)return bt(a,l),{ic:function(){var v=Es(m.hd,n.J.id,null,null,n.bandwidth||null,null);v=Md(n.J.Ma(),[v]);return at(n,b,l,v,0,null,m.Nb)}};if(m.Ka)return d||"image"===a.ia.contentType||(a.presentationTimeline.xf(m.Ka),a.presentationTimeline.ae(a.ga.start)),{ic:function(){return mt(n,m,e,l,f,g,h)}};var q=null;d=d=null;a.ma.id&&a.J.id&&(d=a.ma.id+","+a.J.id,d=c[d])&&
939
- (q=d.segmentIndex);var p=a.ga.start,w=a.ga.duration?p+a.ga.duration:Infinity,u=!(a.vb&&a.ga.pf);q?(c=q,nt(c,m,p,w,u,l),c.La(a.presentationTimeline.mb())):q=new ot(m,a.J.id,a.bandwidth,a.J.Ma,p,w,l,u,g,a.J.Kf);m.timeline&&"image"!==a.ia.contentType&&a.presentationTimeline.Ng(m.timeline,p);d&&a.vb&&(d.segmentIndex=q);return{ic:function(){q instanceof ot&&0==q.getNumReferences()&&nt(q,m,p,w,u,l);return Promise.resolve(q)}}}function it(a){return a.ac}
932
+ function at(a,b,c,d,e,f,g){var h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G;return O(function(L){if(1==L.g)return h=a.presentationTimeline,k=!a.vb||!a.ga.pf,l=a.ga.start,m=a.ga.duration,n=a.J.mimeType.split("/")[1],p=b,r=null,u=[p(d,e,f,!1),"webm"==n?p(c.M(),c.Ga,c.ta,!0):null],p=null,F(L,Promise.all(u),2);v=L.h;w=v[0];A=v[1]||null;z=null;D=l-g;y=l;B=m?l+m:Infinity;if("mp4"==n)var K=Ls(w,e,d,c,D,y,B);else{K=w;var I=new Ns(A);if(440786851!=Os(I).id)throw new T(2,3,3008);var J=Os(I);if(408125543!=J.id)throw new T(2,
933
+ 3,3009);I=J.g.byteOffset;J=new Ns(J.g);for(var M=null;J.pa();){var N=Os(J);if(357149030==N.id){M=N;break}}if(!M)throw new T(2,3,3010);M=new Ns(M.g);N=1E6;for(J=null;M.pa();){var P=Os(M);if(2807729==P.id)N=Ss(P);else if(17545==P.id)if(4==P.g.byteLength)J=P.g.getFloat32(0);else if(8==P.g.byteLength)J=P.g.getFloat64(0);else throw new T(2,3,3003);}if(null==J)throw new T(2,3,3011);M=N/1E9;J*=M;K=Os(new Ns(K));if(475249515!=K.id)throw new T(2,3,3007);K=Ts(K,I,M,J,d,c,D,y,B)}z=K;C=t(z);for(E=C.next();!E.done;E=
934
+ C.next())G=E.value,G.codecs=a.J.codecs,G.mimeType=a.J.mimeType;h.qd(z);r=new Ok(z);k&&r.Cc(y,B,!0);return L.return(r)})}function Ys(a){return a.Rc}function $s(a){var b=Hs(a,Ys,"RepresentationIndex");a=Gs(a,Ys,"indexRange");a=th(a||"");b&&(a=oh(b,"range",th,a));return a}function Zs(a,b){bt(a,b);if(!$s(a))throw new T(2,4,4002);}function bt(a,b){var c=a.J.mimeType.split("/")[1];if(a.J.contentType!=Ud&&"mp4"!=c&&"webm"!=c)throw new T(2,4,4006);if("webm"==c&&!b)throw new T(2,4,4005);}
935
+ function Ws(a){var b=a.J;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.be,pixelAspectRatio:b.pixelAspectRatio||null,width:b.width||null,label:a.ia.label||null,roles:a.roles||null,language:a.ia.language||null}};function ct(a,b,c){var d=Vs(a,dt,c),e=et(a);if(!e.Ka&&!e.timeline&&1<e.Jc.length)throw new T(2,4,4002);if(!e.Ka&&!a.ga.duration&&!e.timeline&&1==e.Jc.length)throw new T(2,4,4002);if(e.timeline&&0==e.timeline.length)throw new T(2,4,4002);var f=null,g=null;a.ma.id&&a.J.id&&(g=b[a.ma.id+","+a.J.id])&&(f=g.segmentIndex);var h=ft(a.ga.start,a.ga.duration,a.J.Ma,e,d,c,a.J.mimeType,a.J.codecs);b=!f;f?f.pd(h,a.presentationTimeline.mb()):f=new Ok(h);a.presentationTimeline.qd(h);a.vb&&a.ga.pf||f.Cc(a.ga.start,
936
+ a.ga.duration?a.ga.start+a.ga.duration:Infinity,b);g&&(g.segmentIndex=f);return{ic:function(){f&&0!=f.getNumReferences()||f.Xd(h);return Promise.resolve(f)}}}function dt(a){return a.Pb}function et(a){var b=gt(a);a=Fs(a,dt);var c=a.td;0==c&&(c=1);var d=0;a.Ka?d=a.Ka*(c-1):a.timeline&&0<a.timeline.length&&(d=a.timeline[0].start);return{Ka:a.Ka,startTime:d,td:c,Nb:a.Nb,timeline:a.timeline,Jc:b}}
937
+ function ft(a,b,c,d,e,f,g,h){var k=d.Jc.length;d.timeline&&d.timeline.length!=d.Jc.length&&(k=Math.min(d.timeline.length,d.Jc.length));for(var l=a-d.Nb,m=b?a+b:Infinity,n=[],p=d.startTime,r={},u=0;u<k;r={ue:void 0,ne:void 0},u++){r.ne=d.Jc[u];var v=p;p=void 0;p=null!=d.Ka?v+d.Ka:d.timeline?d.timeline[u].end:v+b;r.ue=null;r=new Fi(a+v,a+p,function(w){return function(){null==w.ue&&(w.ue=Md(c(),[w.ne.zi]));return w.ue}}(r),r.ne.start,r.ne.end,e,l,a,m,[],"",null,null,Gi,f);r.codecs=h;r.mimeType=g;n.push(r)}return n}
938
+ function gt(a){return[a.J.Pb,a.ia.Pb,a.ma.Pb].filter(Ae).map(function(b){return hh(b,"SegmentURL")}).reduce(function(b,c){return 0<b.length?b:c}).map(function(b){b.attributes.indexRange&&!a.kf&&(a.kf=!0);var c=Cd(b.attributes.media);b=oh(b,"mediaRange",th,{start:0,end:null});return{zi:c,start:b.start,end:b.end}})};function ht(a,b,c,d,e,f,g,h,k){k||a.J.Pd||(a.J.Pd=Gs(a,it,"initialization"));var l=a.J.Pd?jt(a,g):null,m=kt(a);lt(m);var n=Me(a);if(m.hd)return bt(a,l),{ic:function(){var w=Es(m.hd,n.J.id,null,null,n.bandwidth||null,null);w=Md(n.J.Ma(),[w]);return at(n,b,l,w,0,null,m.Nb)}};if(m.Ka)return d||"image"===a.ia.contentType||(a.presentationTimeline.xf(m.Ka),a.presentationTimeline.ae(a.ga.start)),{ic:function(){return mt(n,m,e,l,f,g,h)}};var p=null;d=d=null;a.ma.id&&a.J.id&&(d=a.ma.id+","+a.J.id,d=c[d])&&
939
+ (p=d.segmentIndex);var r=a.ga.start,u=a.ga.duration?r+a.ga.duration:Infinity,v=!(a.vb&&a.ga.pf);p?(c=p,nt(c,m,r,u,v,l),c.La(a.presentationTimeline.mb())):p=new ot(m,a.J.id,a.bandwidth,a.J.Ma,r,u,l,v,g,a.J.Kf);m.timeline&&"image"!==a.ia.contentType&&a.presentationTimeline.Ng(m.timeline,r);d&&a.vb&&(d.segmentIndex=p);return{ic:function(){p instanceof ot&&0==p.getNumReferences()&&nt(p,m,r,u,v,l);return Promise.resolve(p)}}}function it(a){return a.ac}
940
940
  function kt(a){var b=Fs(a,it),c=Gs(a,it,"media"),d=Gs(a,it,"index");return{Ka:b.Ka,timescale:b.timescale,td:b.td,Nb:b.Nb,Zf:b.Zf,timeline:b.timeline,Zb:c&&Cd(c),hd:d,mimeType:a.J.mimeType,codecs:a.J.codecs}}function lt(a){var b=a.hd?1:0;b+=a.timeline?1:0;b+=a.Ka?1:0;if(0==b)throw new T(2,4,4002);1!=b&&(a.hd&&(a.timeline=null),a.Ka=null);if(!a.hd&&!a.Zb)throw new T(2,4,4002);}
941
- function mt(a,b,c,d,e,f,g){function h(I){var J=(I-u)*w,N=J+b.Nb,M=J+n;J=M+w;var P=Math.min(J,l());M=new Fi(M,P,function(){var R=N*v;"BigInt"in window&&R>Number.MAX_SAFE_INTEGER&&(R=BigInt(N)*BigInt(v));R=Es(A,D,I,null,z,R);return Md(y(),[R])},0,null,d,B,n,l(),[],"",null,null,Gi,f);M.codecs=a.J.codecs;M.mimeType=a.J.mimeType;M.j=J;return M}function k(){var I=[Math.max(m.mb(),n),Math.min(m.Wb(),l())].map(function(J){return J-n});I=[Math.ceil(I[0]/w),Math.ceil(I[1]/w)-1];a.J.Sa&&I[1]++;return I.map(function(J){return J+
942
- u})}function l(){var I=null!=q&&e[q]||p;return I?n+I:Infinity}var m=a.presentationTimeline,n=a.ga.start,q=a.ma.id,p=a.ga.duration,w=b.Ka,u=b.td,v=b.timescale,A=b.Zb,z=a.bandwidth||null,D=a.J.id,y=a.J.Ma,B=n-b.Nb,C=k();c=a.vb?Math.max(C[0],C[1]-c+1):C[0];g=g||C[1];C=[];for(var E=c;E<=g;++E){var G=h(E);C.push(G)}var L=new Ok(C);C=m.Wb()<l();E=m.V();if(C||E){var K=Math.max(c,g+1);c=w;a.J.Sa&&(c=.1);L.te(c,function(){var I=m.mb();L.La(I);var J=t(k());J.next();J=J.next().value;for(var N=[];K<=J;){var M=
943
- h(K);N.push(M);K++}return I>l()&&!N.length?null:N})}return Promise.resolve(L)}function jt(a,b){var c=a.J.Pd;c||(c=Gs(a,it,"initialization"));if(!c)return null;c=Cd(c);var d=a.J.id,e=a.bandwidth||null,f=a.J.Ma;b=new Di(function(){var g=Es(c,d,null,null,e,null);return Md(f(),[g])},0,null,Ws(a),null,null,b);b.codecs=a.J.codecs;b.mimeType=a.J.mimeType;return b}
944
- function ot(a,b,c,d,e,f,g,h,k,l){Ok.call(this,[]);this.g=a;this.C=b;this.A=c;this.B=d;this.h=e;this.j=f;this.o=g;this.s=k;this.F=l;h&&pt(this)}na(ot,Ok);r=ot.prototype;r.getNumReferences=function(){return this.g?this.g.timeline.length:0};r.release=function(){Ok.prototype.release.call(this);this.g=null};
945
- r.La=function(a){if(this.g){for(var b=0,c=this.g.timeline,d=0;d<c.length;d+=1)if(c[d].end+this.h<=a)b+=1;else break;0<b&&(this.g.timeline=c.slice(b),this.P.length>=b&&(this.P=this.P.slice(b)),this.i+=b,0===this.getNumReferences()&&this.release())}};
941
+ function mt(a,b,c,d,e,f,g){function h(I){var J=(I-v)*u,M=J+b.Nb,N=J+n;J=N+u;var P=Math.min(J,l());N=new Fi(N,P,function(){var R=M*w;"BigInt"in window&&R>Number.MAX_SAFE_INTEGER&&(R=BigInt(M)*BigInt(w));R=Es(A,D,I,null,z,R);return Md(y(),[R])},0,null,d,B,n,l(),[],"",null,null,Gi,f);N.codecs=a.J.codecs;N.mimeType=a.J.mimeType;N.j=J;return N}function k(){var I=[Math.max(m.mb(),n),Math.min(m.Wb(),l())].map(function(J){return J-n});I=[Math.ceil(I[0]/u),Math.ceil(I[1]/u)-1];a.J.Sa&&I[1]++;return I.map(function(J){return J+
942
+ v})}function l(){var I=null!=p&&e[p]||r;return I?n+I:Infinity}var m=a.presentationTimeline,n=a.ga.start,p=a.ma.id,r=a.ga.duration,u=b.Ka,v=b.td,w=b.timescale,A=b.Zb,z=a.bandwidth||null,D=a.J.id,y=a.J.Ma,B=n-b.Nb,C=k();c=a.vb?Math.max(C[0],C[1]-c+1):C[0];g=g||C[1];C=[];for(var E=c;E<=g;++E){var G=h(E);C.push(G)}var L=new Ok(C);C=m.Wb()<l();E=m.V();if(C||E){var K=Math.max(c,g+1);c=u;a.J.Sa&&(c=.1);L.te(c,function(){var I=m.mb();L.La(I);var J=t(k());J.next();J=J.next().value;for(var M=[];K<=J;){var N=
943
+ h(K);M.push(N);K++}return I>l()&&!M.length?null:M})}return Promise.resolve(L)}function jt(a,b){var c=a.J.Pd;c||(c=Gs(a,it,"initialization"));if(!c)return null;c=Cd(c);var d=a.J.id,e=a.bandwidth||null,f=a.J.Ma;b=new Di(function(){var g=Es(c,d,null,null,e,null);return Md(f(),[g])},0,null,Ws(a),null,null,b);b.codecs=a.J.codecs;b.mimeType=a.J.mimeType;return b}
944
+ function ot(a,b,c,d,e,f,g,h,k,l){Ok.call(this,[]);this.g=a;this.C=b;this.A=c;this.B=d;this.h=e;this.j=f;this.o=g;this.s=k;this.F=l;h&&pt(this)}na(ot,Ok);q=ot.prototype;q.getNumReferences=function(){return this.g?this.g.timeline.length:0};q.release=function(){Ok.prototype.release.call(this);this.g=null};
945
+ q.La=function(a){if(this.g){for(var b=0,c=this.g.timeline,d=0;d<c.length;d+=1)if(c[d].end+this.h<=a)b+=1;else break;0<b&&(this.g.timeline=c.slice(b),this.P.length>=b&&(this.P=this.P.slice(b)),this.i+=b,0===this.getNumReferences()&&this.release())}};
946
946
  function nt(a,b,c,d,e,f){qt(a,f);if(a.g){c=a.g.timeline;a.g.Zb!==b.Zb&&(a.g.Zb=b.Zb);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.g.timeline.push.apply(a.g.timeline,x(b));a.j!==d&&(a.j=d)}else a.g=b,a.h=c,a.j=d;e&&pt(a)}function qt(a,b){if(a.o!==b){a.o=b;a=t(a.P);for(var c=a.next();!c.done;c=a.next())(c=c.value)&&Ii(c,b)}}
947
- function pt(a){if(!a.m){for(var b=a.g.timeline;b.length;)if(b[b.length-1].start>=a.j)b.pop();else break;a.La(a.h)}}r.find=function(a){if(this.g&&this.g.timeline&&this.g.timeline.length&&a<this.g.timeline[0].start+this.h)return this.i;if(!this.g)return null;var b=this.g.timeline;if(a<this.h||a>=this.j)return null;for(var c=b.length-1,d=0;d<b.length;d++){var e=b[d],f=e.start+this.h;e=d<c?b[d+1].start+this.h:Infinity===this.j?e.end+this.h:this.j;if(a>=f&&a<e)return d+this.i}return null};
948
- r.get=function(a){var b=this;a-=this.i;if(0>a||a>=this.getNumReferences()||!this.g)return null;var c=this.P[a];if(!c){var d=this.g.timeline[a],e=d.Si,f=this.g.Zf+d.$f;c=this.h-this.g.Nb;var g=this.h+d.end,h=g;a===this.getNumReferences()-1&&Infinity!==this.j&&(h=this.j);for(var k=this.g.codecs,l=this.g.mimeType,m=[],n=(d.end-d.start)/d.zb,q={},p=0;p<d.zb;q={ve:void 0,kh:void 0},p++){var w=d.start+n*p,u=w+n;q.kh=p+1;q.ve=null;q=new Fi(this.h+w,this.h+u,function(v){return function(){if(!b.g)return[];
949
- null==v.ve&&(v.ve=rt(b.g.Zb,b.C,e,b.A,f,v.kh,b.B));return v.ve}}(q),0,null,this.o,c,this.h,this.j,[],"",null,null,Gi,this.s);q.codecs=k;q.mimeType=l;0==this.F?0<p&&q.Vd():0!=p%this.F&&q.Vd();m.push(q)}c=new Fi(this.h+d.start,h,function(){return 0<d.zb||!b.g?[]:rt(b.g.Zb,b.C,e,b.A,f,null,b.B)},0,null,this.o,c,this.h,this.j,m,"",null,null,Gi,this.s,0<d.zb);c.codecs=k;c.mimeType=l;c.j=g;this.P[a]=c}return c};
947
+ function pt(a){if(!a.m){for(var b=a.g.timeline;b.length;)if(b[b.length-1].start>=a.j)b.pop();else break;a.La(a.h)}}q.find=function(a){if(this.g&&this.g.timeline&&this.g.timeline.length&&a<this.g.timeline[0].start+this.h)return this.i;if(!this.g)return null;var b=this.g.timeline;if(a<this.h||a>=this.j)return null;for(var c=b.length-1,d=0;d<b.length;d++){var e=b[d],f=e.start+this.h;e=d<c?b[d+1].start+this.h:Infinity===this.j?e.end+this.h:this.j;if(a>=f&&a<e)return d+this.i}return null};
948
+ q.get=function(a){var b=this;a-=this.i;if(0>a||a>=this.getNumReferences()||!this.g)return null;var c=this.P[a];if(!c){var d=this.g.timeline[a],e=d.Si,f=this.g.Zf+d.$f;c=this.h-this.g.Nb;var g=this.h+d.end,h=g;a===this.getNumReferences()-1&&Infinity!==this.j&&(h=this.j);for(var k=this.g.codecs,l=this.g.mimeType,m=[],n=(d.end-d.start)/d.zb,p={},r=0;r<d.zb;p={ve:void 0,kh:void 0},r++){var u=d.start+n*r,v=u+n;p.kh=r+1;p.ve=null;p=new Fi(this.h+u,this.h+v,function(w){return function(){if(!b.g)return[];
949
+ null==w.ve&&(w.ve=rt(b.g.Zb,b.C,e,b.A,f,w.kh,b.B));return w.ve}}(p),0,null,this.o,c,this.h,this.j,[],"",null,null,Gi,this.s);p.codecs=k;p.mimeType=l;0==this.F?0<r&&p.Vd():0!=r%this.F&&p.Vd();m.push(p)}c=new Fi(this.h+d.start,h,function(){return 0<d.zb||!b.g?[]:rt(b.g.Zb,b.C,e,b.A,f,null,b.B)},0,null,this.o,c,this.h,this.j,m,"",null,null,Gi,this.s,0<d.zb);c.codecs=k;c.mimeType=l;c.j=g;this.P[a]=c}return c};
950
950
  function rt(a,b,c,d,e,f,g){a=Es(a,b,c,f,d||null,e);return Md(g(),[a]).map(function(h){return h.toString()})};function st(a){this.o=null;this.A=a;this.G=new mg;this.i=[];this.h=null;this.m=[];this.B=null;this.F=[];this.C=300;this.l=new Map;this.j=new Map;this.g=null;this.s="UNKNOWN"}st.prototype.configure=function(a){this.o=a};st.prototype.destroy=function(){this.A=this.o=null;this.i=[];this.h=null;this.m=[];this.F=[];this.l.clear();null!=this.g&&(this.g.stop(),this.g=null);return this.G.destroy()};st.prototype.setManifestType=function(a){this.s=a};
951
951
  function tt(a,b){var c,d,e,f,g,h,k;return O(function(l){if(1==l.g)return c=Md(a.i,[ut(a,b)]),d=tg(c,a.o.retryParameters),e=a.A.networkingEngine.request(8,d),ng(a.G,e),ra(l,2),F(l,e.promise,4);if(2!=l.g)return f=l.h,g=ud(f.data),h=JSON.parse(g),1==h.VERSION&&vt(a,h,f.uri),ta(l,0);if((k=ua(l))&&7001==k.code)return l.return();null!=a.g&&(a.g.stop(),a.g=null);a.g=new Sc(function(){tt(a,b)});a.g.Z(a.C);H(l)})}
952
952
  function ut(a,b){if(!a.m.length)return b;b=new tc(b);var c=a.B||a.m[0],d=Math.round(a.A.getBandwidthEstimate()),e=b.g;"DASH"==a.s?(e.add("_DASH_pathway",c),e.add("_DASH_throughput",String(d))):"HLS"==a.s&&(e.add("_HLS_pathway",c),e.add("_HLS_throughput",String(d)));Ic(e)&&xc(b,e);return b.toString()}function vt(a,b,c){null!=a.g&&(a.g.stop(),a.g=null);var d=b["RELOAD-URI"]||c;a.g=new Sc(function(){tt(a,d)});if(c=b.TTL)a.C=c;a.g.Z(a.C);a.m=b["PATHWAY-PRIORITY"]||[];a.F=b["PATHWAY-CLONES"]||[]}
953
953
  function wt(a,b,c,d){var e=a.l.get(b);e||(e=new Map);e.set(c,d);a.l.set(b,e)}st.prototype.banLocation=function(a){this.j.set(a,Date.now()+6E4)};
954
- function xt(a,b,c){c=void 0===c?!1:c;b=a.l.get(b)||new Map;for(var d=[],e=t(a.m),f=e.next(),g={};!f.done;g={Kc:void 0},f=e.next())if(g.Kc=f.value,f=b.get(g.Kc))d.push({Df:g.Kc,location:f});else if(f=a.F.find(function(k){return function(l){return l.wj==k.Kc}}(g))){var h=b.get(f["BASE-ID"]);h&&(f["URI-REPLACEMENT"].rh?(h=new tc(h),vc(h,f["URI-REPLACEMENT"].rh),d.push({Df:g.Kc,location:h.toString()})):d.push({Df:g.Kc,location:h}))}e=Date.now();g=t(a.j.keys());for(f=g.next();!f.done;f=g.next())f=f.value,
955
- h=a.j.get(f),e>h&&a.j.delete(f);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 tc(k.location)).Eb))return!1;return!0});d.length&&(a.B=d[0].Df);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(g=b.get(g.value))a.B=a.h,d.push(g);if(!d.length)for(b=t(b.values()),e=b.next();!e.done;e=b.next())d.push(e.value);return c?d:Md(a.i,d)};function yt(){this.j=[];this.h=[];this.g=[];this.l=[];this.i=[];this.s=this.o=!1;this.m=new Set}r=yt.prototype;r.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=[]};r.ei=function(){return this.j};r.hf=function(){return this.l.slice()};r.Nh=function(){return this.i};
954
+ function xt(a,b,c){c=void 0===c?!1:c;b=a.l.get(b)||new Map;for(var d=[],e=t(a.m),f=e.next(),g={};!f.done;g={Lc:void 0},f=e.next())if(g.Lc=f.value,f=b.get(g.Lc))d.push({Df:g.Lc,location:f});else if(f=a.F.find(function(k){return function(l){return l.wj==k.Lc}}(g))){var h=b.get(f["BASE-ID"]);h&&(f["URI-REPLACEMENT"].rh?(h=new tc(h),vc(h,f["URI-REPLACEMENT"].rh),d.push({Df:g.Lc,location:h.toString()})):d.push({Df:g.Lc,location:h}))}e=Date.now();g=t(a.j.keys());for(f=g.next();!f.done;f=g.next())f=f.value,
955
+ h=a.j.get(f),e>h&&a.j.delete(f);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 tc(k.location)).Eb))return!1;return!0});d.length&&(a.B=d[0].Df);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(g=b.get(g.value))a.B=a.h,d.push(g);if(!d.length)for(b=t(b.values()),e=b.next();!e.done;e=b.next())d.push(e.value);return c?d:Md(a.i,d)};function yt(){this.j=[];this.h=[];this.g=[];this.l=[];this.i=[];this.s=this.o=!1;this.m=new Set}q=yt.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.ei=function(){return this.j};q.hf=function(){return this.l.slice()};q.Nh=function(){return this.i};
956
956
  function zt(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[At(n),n]}));var k=new Map(h.videoStreams.map(function(n){return[Bt(n),n]})),l=new Map(h.textStreams.map(function(n){return[Ct(n),n]}));h=new Map(h.imageStreams.map(function(n){return[Dt(n),n]}));if(b){var m=Et(Ud);l.set(Ct(m),m);m=Et("image");h.set(Dt(m),m)}c.push(g);d.push(k);e.push(l);f.push(h)}return{jg:c,ph:d,lh:e,Eg:f}}
957
- r.Je=function(a,b,c){c=void 0===c?!1:c;var d=this,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L,K,I,J,N,M,P,R,Q;return O(function(X){if(1==X.g){e=Wd;if(!b&&1==a.length)return f=zt(a,!1),g=f.jg,h=f.ph,k=f.lh,l=f.Eg,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()),X.u(2);m=c?d.m.size:0;n=-1;for(q=0;q<a.length;q++)p=a[q],d.m.has(p.id)||(d.m.add(p.id),-1==n&&(n=q));if(-1==n)return X.return();w=zt(a,!0);u=w.jg;v=w.ph;A=w.lh;z=w.Eg;return F(X,
958
- Promise.all([Ft(d,d.h,u,n,Gt,Ht,m),Ft(d,d.g,v,n,Gt,Ht,m),Ft(d,d.l,A,n,Gt,Ht,m),Ft(d,d.i,z,n,Gt,Ht,m)]),2)}D=0;y=[];if(d.g.length&&d.h.length)for(K=t(d.h),I=K.next();!I.done;I=K.next())for(J=I.value,N=t(d.g),M=N.next();!M.done;M=N.next())P=M.value,R=Mc(J.drmInfos,P.drmInfos),J.drmInfos.length&&P.drmInfos.length&&!R.length||(Q=D++,y.push({id:Q,language:J.language,disabledUntilTime:0,primary:J.primary,audio:J,video:P,bandwidth:(J.bandwidth||0)+(P.bandwidth||0),drmInfos:R,allowedByApplication:!0,allowedByKeySystem:!0,
957
+ q.Je=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,D,y,B,C,E,G,L,K,I,J,M,N,P,R,Q;return O(function(X){if(1==X.g){e=Wd;if(!b&&1==a.length)return f=zt(a,!1),g=f.jg,h=f.ph,k=f.lh,l=f.Eg,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()),X.u(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 X.return();u=zt(a,!0);v=u.jg;w=u.ph;A=u.lh;z=u.Eg;return F(X,
958
+ Promise.all([Ft(d,d.h,v,n,Gt,Ht,m),Ft(d,d.g,w,n,Gt,Ht,m),Ft(d,d.l,A,n,Gt,Ht,m),Ft(d,d.i,z,n,Gt,Ht,m)]),2)}D=0;y=[];if(d.g.length&&d.h.length)for(K=t(d.h),I=K.next();!I.done;I=K.next())for(J=I.value,M=t(d.g),N=M.next();!N.done;N=M.next())P=N.value,R=Mc(J.drmInfos,P.drmInfos),J.drmInfos.length&&P.drmInfos.length&&!R.length||(Q=D++,y.push({id:Q,language:J.language,disabledUntilTime:0,primary:J.primary,audio:J,video:P,bandwidth:(J.bandwidth||0)+(P.bandwidth||0),drmInfos:R,allowedByApplication:!0,allowedByKeySystem:!0,
959
959
  decodingInfos:[]}));else for(B=d.g.length?d.g:d.h,C=t(B),E=C.next();!E.done;E=C.next())G=E.value,L=D++,y.push({id:L,language:G.language,disabledUntilTime:0,primary:G.primary,audio:G.type==e.X?G:null,video:G.type==e.ha?G:null,bandwidth:G.bandwidth||0,drmInfos:G.drmInfos,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});d.j=y;H(X)})};
960
- function It(a){var b,c,d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L,K,I,J,N,M;return O(function(P){switch(P.g){case 1:b=Wd;if(1==a.length)return P.return(a[0]);c=a.map(function(R){return new Map(R.filter(function(Q){return Q.type===b.X}).map(function(Q){return[At(Q),Q]}))});d=a.map(function(R){return new Map(R.filter(function(Q){return Q.type===b.ha}).map(function(Q){return[Bt(Q),Q]}))});e=a.map(function(R){return new Map(R.filter(function(Q){return Q.type===b.ua}).map(function(Q){return[Ct(Q),Q]}))});
961
- f=a.map(function(R){return new Map(R.filter(function(Q){return Q.type===b.Ce}).map(function(Q){return[Dt(Q),Q]}))});g=t(e);for(h=g.next();!h.done;h=g.next())k=h.value,l=Jt(b.ua),k.set(Ct(l),l);m=t(f);for(n=m.next();!n.done;n=m.next())q=n.value,p=Jt(b.Ce),q.set(Dt(p),p);w=new yt;return F(P,Ft(w,[],c,0,Kt,Lt,0),2);case 2:return u=P.h,F(P,Ft(w,[],d,0,Kt,Lt,0),3);case 3:return v=P.h,F(P,Ft(w,[],e,0,Kt,Lt,0),4);case 4:return A=P.h,F(P,Ft(w,[],f,0,Kt,Lt,0),5);case 5:z=P.h;D=0;if(v.length&&u.length)for(G=
962
- t(u),L=G.next();!L.done;L=G.next())for(K=L.value,I=t(v),J=I.next();!J.done;J=I.next())N=J.value,M=D++,N.variantIds.push(M),K.variantIds.push(M);else for(y=v.concat(u),B=t(y),C=B.next();!C.done;C=B.next())E=C.value,E.variantIds=[D++];return P.return(v.concat(u).concat(A).concat(z))}})}
963
- function Ft(a,b,c,d,e,f,g){var h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L,K;return O(function(I){switch(I.g){case 1:h=[];for(k=0;k<c.length;k++)k>=d?h.push(new Set(c[k].values())):h.push(new Set);l=t(b);m=l.next();case 2:if(m.done){I.u(4);break}n=m.value;return F(I,Mt(a,n,c,d,f,h,g),5);case 5:q=I.h;if(!q)throw new T(2,4,4037);m=l.next();I.u(2);break;case 4:p=t(h);for(w=p.next();!w.done;w=p.next())for(u=w.value,v=t(u),A=v.next();!A.done;A=v.next())z=A.value,(D=Nt(a,z,c,e,f,h))&&b.push(D);y=t(h);for(B=y.next();!B.done;B=
964
- y.next())for(C=B.value,E=t(C),G=E.next(),L={};!G.done;L={Tf:void 0},G=E.next())if(L.Tf=G.value,!Ot(L.Tf)&&(K=b.some(function(J){return function(N){return Pt(a,J.Tf,N)}}(L))))throw new T(2,4,4037);return I.return(b)}})}function Mt(a,b,c,d,e,f,g){return O(function(h){if(1==h.g)return Qt(a,c,b,0<g),b.matchedStreams?b.segmentIndex?F(h,Rt(b,d+g),2):h.u(2):h.return(!1);St(b,d,e,f,g);return h.return(!0)})}
960
+ function It(a){var b,c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L,K,I,J,M,N;return O(function(P){switch(P.g){case 1:b=Wd;if(1==a.length)return P.return(a[0]);c=a.map(function(R){return new Map(R.filter(function(Q){return Q.type===b.X}).map(function(Q){return[At(Q),Q]}))});d=a.map(function(R){return new Map(R.filter(function(Q){return Q.type===b.ha}).map(function(Q){return[Bt(Q),Q]}))});e=a.map(function(R){return new Map(R.filter(function(Q){return Q.type===b.ua}).map(function(Q){return[Ct(Q),Q]}))});
961
+ f=a.map(function(R){return new Map(R.filter(function(Q){return Q.type===b.Ce}).map(function(Q){return[Dt(Q),Q]}))});g=t(e);for(h=g.next();!h.done;h=g.next())k=h.value,l=Jt(b.ua),k.set(Ct(l),l);m=t(f);for(n=m.next();!n.done;n=m.next())p=n.value,r=Jt(b.Ce),p.set(Dt(r),r);u=new yt;return F(P,Ft(u,[],c,0,Kt,Lt,0),2);case 2:return v=P.h,F(P,Ft(u,[],d,0,Kt,Lt,0),3);case 3:return w=P.h,F(P,Ft(u,[],e,0,Kt,Lt,0),4);case 4:return A=P.h,F(P,Ft(u,[],f,0,Kt,Lt,0),5);case 5:z=P.h;D=0;if(w.length&&v.length)for(G=
962
+ t(v),L=G.next();!L.done;L=G.next())for(K=L.value,I=t(w),J=I.next();!J.done;J=I.next())M=J.value,N=D++,M.variantIds.push(N),K.variantIds.push(N);else for(y=w.concat(v),B=t(y),C=B.next();!C.done;C=B.next())E=C.value,E.variantIds=[D++];return P.return(w.concat(v).concat(A).concat(z))}})}
963
+ function Ft(a,b,c,d,e,f,g){var h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L,K;return O(function(I){switch(I.g){case 1:h=[];for(k=0;k<c.length;k++)k>=d?h.push(new Set(c[k].values())):h.push(new Set);l=t(b);m=l.next();case 2:if(m.done){I.u(4);break}n=m.value;return F(I,Mt(a,n,c,d,f,h,g),5);case 5:p=I.h;if(!p)throw new T(2,4,4037);m=l.next();I.u(2);break;case 4:r=t(h);for(u=r.next();!u.done;u=r.next())for(v=u.value,w=t(v),A=w.next();!A.done;A=w.next())z=A.value,(D=Nt(a,z,c,e,f,h))&&b.push(D);y=t(h);for(B=y.next();!B.done;B=
964
+ y.next())for(C=B.value,E=t(C),G=E.next(),L={};!G.done;L={Tf:void 0},G=E.next())if(L.Tf=G.value,!Ot(L.Tf)&&(K=b.some(function(J){return function(M){return Pt(a,J.Tf,M)}}(L))))throw new T(2,4,4037);return I.return(b)}})}function Mt(a,b,c,d,e,f,g){return O(function(h){if(1==h.g)return Qt(a,c,b,0<g),b.matchedStreams?b.segmentIndex?F(h,Rt(b,d+g),2):h.u(2):h.return(!1);St(b,d,e,f,g);return h.return(!0)})}
965
965
  function Rt(a,b){var c,d,e,f,g,h,k;return O(function(l){if(1==l.g){c=[];d=a.matchedStreams;e=t(d);for(f=e.next();!f.done;f=e.next())g=f.value,c.push(g.createSegmentIndex()),g.trickModeVideo&&!g.trickModeVideo.segmentIndex&&c.push(g.trickModeVideo.createSegmentIndex());return F(l,Promise.all(c),2)}if(a.segmentIndex instanceof Rk)for(h=b;h<d.length;h++)k=d[h],k.segmentIndex&&a.segmentIndex.g.push(k.segmentIndex);H(l)})}
966
966
  function Nt(a,b,c,d,e,f){if(Ot(b))return null;var g=d(b);Qt(a,c,g);g.createSegmentIndex&&(g.createSegmentIndex=function(){return O(function(h){if(g.segmentIndex)return h.u(0);g.segmentIndex=new Rk;return F(h,Rt(g,0),0)})});if(!g.matchedStreams||!g.matchedStreams.length)return null;St(g,0,e,f,0);return g}
967
967
  function St(a,b,c,d,e){var f=a.matchedStreams;for(b+=e;b<f.length;b++){var g=f[b];c(a,g);var h=!0;"audio"==a.type&&0==He(a.language,g.language)&&(h=!1);if(h&&(d[b-e].delete(g),g.fullMimeTypes))for(g=t(g.fullMimeTypes.values()),h=g.next();!h.done;h=g.next())a.fullMimeTypes.add(h.value)}}
@@ -973,7 +973,7 @@ for(var g=new Rk,h=t(a.trickModeVideo.matchedStreams),k=h.next();!k.done;k=h.nex
973
973
  function Lt(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)}
974
974
  function Qt(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=Tt(a,e.value,c);if(!e)return;d.push(e)}c.matchedStreams=d}
975
975
  function Tt(a,b,c){var d={audio:At,video:Bt,text:Ct,image:Dt}[c.type],e=null,f=d(c);if(b.has(f))e=b.get(f);else{f={audio:function(l,m){return Pt(a,l,m)},video:function(l,m){return Pt(a,l,m)},text:Ut,image:Vt}[c.type];for(var g={audio:Wt,video:Xt,text:Yt,image:Zt}[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.s&&!Ot(e)&&b.delete(d(e));return e}
976
- function $t(a,b){return a.mimeType!=b.mimeType?!1:au(a.codecs)===au(b.codecs)}r.Zg=function(a){this.o=a};r.gh=function(a){this.s=a};function Pt(a,b,c){return!$t(b,c)&&!a.o||b.drmInfos&&!Lc(b.drmInfos,c.drmInfos)?!1:!0}function Ut(a,b){return b.language?a.forced!==b.forced||0==He(a.language,b.language)||b.kind!=a.kind?!1:!0:!0}function Vt(){return!0}
976
+ function $t(a,b){return a.mimeType!=b.mimeType?!1:au(a.codecs)===au(b.codecs)}q.Zg=function(a){this.o=a};q.gh=function(a){this.s=a};function Pt(a,b,c){return!$t(b,c)&&!a.o||b.drmInfos&&!Lc(b.drmInfos,c.drmInfos)?!1:!0}function Ut(a,b){return b.language?a.forced!==b.forced||0==He(a.language,b.language)||b.kind!=a.kind?!1:!0:!0}function Vt(){return!0}
977
977
  function Wt(a,b,c){var d=$t(a,b),e=$t(a,c);if(d&&!e)return!1;if(!d&&e)return!0;d=He(a.language,b.language);e=He(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){d=b.roles.filter(function(f){return a.roles.includes(f)});e=c.roles.filter(function(f){return a.roles.includes(f)});if(e.length>d.length)return!0;if(e.length<d.length)return!1;if(c.roles.length!==b.roles.length)return c.roles.length<
978
978
  b.roles.length}else{if(!c.roles.length&&b.roles.length)return!0;if(c.roles.length&&!b.roles.length)return!1}if(!b.primary&&c.primary)return!0;if(b.primary&&!c.primary)return!1;d=bu(a.channelsCount,b.channelsCount,c.channelsCount);if(d==cu)return!0;if(d==du)return!1;d=bu(a.audioSamplingRate,b.audioSamplingRate,c.audioSamplingRate);return d==cu?!0:d==du?!1:a.bandwidth&&eu(a.bandwidth,b.bandwidth,c.bandwidth)==cu?!0:!1}
979
979
  function Xt(a,b,c){var d=$t(a,b),e=$t(a,c);if(d&&!e)return!1;if(!d&&e)return!0;d=bu(a.width*a.height,b.width*b.height,c.width*c.height);if(d==cu)return!0;if(d==du)return!1;if(a.frameRate){d=bu(a.frameRate,b.frameRate,c.frameRate);if(d==cu)return!0;if(d==du)return!1}return a.bandwidth&&eu(a.bandwidth,b.bandwidth,c.bandwidth)==cu?!0:!1}
@@ -985,59 +985,59 @@ function bu(a,b,c){if(b==a&&a!=c)return du;if(c==a&&a!=b)return cu;if(b>a){if(c<
985
985
  function Bt(a){return JSON.stringify([a.fastSwitching,a.width,a.frameRate,au(a.codecs),a.mimeType,a.label,a.roles,a.closedCaptions?Array.from(a.closedCaptions.entries()):null,a.bandwidth])}function At(a){return JSON.stringify([a.fastSwitching,a.channelsCount,a.language,a.bandwidth,a.label,au(a.codecs),a.mimeType,a.roles,a.audioSamplingRate,a.primary])}function Ct(a){return JSON.stringify([a.language,a.label,a.codecs,a.mimeType,a.bandwidth,a.roles])}
986
986
  function Dt(a){return JSON.stringify([a.width,a.codecs,a.mimeType])}function au(a){if(!gu.has(a)){var b=fe(a);gu.set(a,b)}return gu.get(a)}S("shaka.util.PeriodCombiner",yt);yt.prototype.setUseStreamOnce=yt.prototype.gh;yt.prototype.setAllowMultiTypeVariants=yt.prototype.Zg;yt.prototype.combinePeriods=yt.prototype.Je;yt.prototype.getImageStreams=yt.prototype.Nh;yt.prototype.getTextStreams=yt.prototype.hf;yt.prototype.getVariants=yt.prototype.ei;var cu=1,fu=0,du=-1,gu=new Map;function hu(a,b){var c=new DOMParser,d=iu.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 ju(a,b){try{var c=yd(a);return hu(c,b)}catch(d){return null}}
987
987
  var iu=new Kc(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 ku(){var a=this;this.j=this.g=null;this.A=[];this.i=null;this.la=1;this.F=[];this.l={Zd:"",type:"",profiles:[],Kb:null,Sa:0,Ma:null,rd:0};this.o=new Map;this.s={};this.C={};this.ea={};this.m=new yt;this.K=0;this.fa=new Sa(5);this.L=new Sc(function(){if(a.I&&!a.g.continueLoadingWhenPaused&&(a.G.jb(a.I,"timeupdate"),a.I.paused)){a.G.ja(a.I,"timeupdate",function(){return lu(a)});return}lu(a)});this.T=new mg;this.O=null;this.B=[];this.Y=Infinity;this.H=!1;this.h=null;this.N=0;this.ba=!1;this.G=
988
- new gb;this.I=null;this.da=!1}r=ku.prototype;r.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.V()&&this.L.uc();this.h&&this.h.configure(this.g);this.m&&(this.m.Zg(this.g.dash.multiTypeVariantsAllowed&&ob()),this.m.gh(this.g.dash.useStreamOnceInPeriodFlattening))};
989
- r.start=function(a,b){var c=this,d;return O(function(e){if(1==e.g)return c.H=b.isLowLatencyMode(),c.A=[a],c.j=b,F(e,mu(c),2);d=e.h;c.j&&nu(c,d);if(!c.j)throw new T(2,7,7001);return e.return(c.i)})};
990
- r.stop=function(){for(var a=t(Object.values(this.s)),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.s={};this.C={};this.o.clear();this.l={Zd:"",type:"",profiles:[],Kb:null,Sa:0,Ma:null,rd:0};this.m=null;null!=this.L&&(this.L.stop(),this.L=null);this.h&&this.h.destroy();this.G&&(this.G.release(),this.G=null);return this.T.destroy()};
991
- r.update=function(){var a=this,b;return O(function(c){if(1==c.g)return ra(c,2),F(c,mu(a),4);if(2!=c.g)return ta(c,0);b=ua(c);if(!a.j||!b)return c.return();a.j.onError(b);H(c)})};r.onExpirationUpdated=function(){};r.onInitialVariantChosen=function(a){if(this.i&&this.i.presentationTimeline.V()){var b=a.video||a.audio;if(b&&b.segmentIndex){a=this.i.presentationTimeline.Wb();var c=b.segmentIndex.find(a);null!=c&&(b=b.segmentIndex.get(c))&&(this.K=b.endTime-a,nu(this,0))}}};
992
- r.banLocation=function(a){this.h&&this.h.banLocation(a)};r.setMediaElement=function(a){this.I=a};
988
+ new gb;this.I=null;this.da=!1}q=ku.prototype;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.V()&&this.L.uc();this.h&&this.h.configure(this.g);this.m&&(this.m.Zg(this.g.dash.multiTypeVariantsAllowed&&ob()),this.m.gh(this.g.dash.useStreamOnceInPeriodFlattening))};
989
+ q.start=function(a,b){var c=this,d;return O(function(e){if(1==e.g)return c.H=b.isLowLatencyMode(),c.A=[a],c.j=b,F(e,mu(c),2);d=e.h;c.j&&nu(c,d);if(!c.j)throw new T(2,7,7001);return e.return(c.i)})};
990
+ q.stop=function(){for(var a=t(Object.values(this.s)),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.s={};this.C={};this.o.clear();this.l={Zd:"",type:"",profiles:[],Kb:null,Sa:0,Ma:null,rd:0};this.m=null;null!=this.L&&(this.L.stop(),this.L=null);this.h&&this.h.destroy();this.G&&(this.G.release(),this.G=null);return this.T.destroy()};
991
+ q.update=function(){var a=this,b;return O(function(c){if(1==c.g)return ra(c,2),F(c,mu(a),4);if(2!=c.g)return ta(c,0);b=ua(c);if(!a.j||!b)return c.return();a.j.onError(b);H(c)})};q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(a){if(this.i&&this.i.presentationTimeline.V()){var b=a.video||a.audio;if(b&&b.segmentIndex){a=this.i.presentationTimeline.Wb();var c=b.segmentIndex.find(a);null!=c&&(b=b.segmentIndex.get(c))&&(this.K=b.endTime-a,nu(this,0))}}};
992
+ q.banLocation=function(a){this.h&&this.h.banLocation(a)};q.setMediaElement=function(a){this.I=a};
993
993
  function mu(a){var b,c,d,e,f,g,h,k,l,m;return O(function(n){if(1==n.g)return b=4,c="MPD",d=ou(a),e=a.A,d.length?(e=d,c="Patch",b=6):1<a.A.length&&a.h&&(f=xt(a.h,"Location",!0),f.length&&(e=f)),g=tg(e,a.g.retryParameters),h=Date.now(),F(n,pu(a,g,0,{type:b}),2);if(3!=n.g){k=n.h;if(!a.j)return n.return(0);k.uri&&k.uri!=k.originalUri&&!a.A.includes(k.uri)&&a.A.unshift(k.uri);return F(n,qu(a,k.data,k.uri,c),3)}l=Date.now();m=(l-h)/1E3;a.fa.sample(1,m);return n.return(m)})}
994
- function qu(a,b,c,d){var e,f,g,h,k,l,m,n,q,p,w;return O(function(u){if(1==u.g){e=b;f=a.g.dash.manifestPreprocessor;g=wm;if(f!=g){qb("manifest.dash.manifestPreprocessor configuration","Please Use manifest.dash.manifestPreprocessorTXml instead.");h=ju(e,d);if(!h)throw new T(2,4,4001,c);f(h);e=zd(h.outerHTML)}k=$g(e,d);if(!k)throw new T(2,4,4001,c);l=a.g.dash.manifestPreprocessorTXml;m=xm;l!=m&&l(k);if("Patch"===d)return u.return(ru(a,k));if(n=a.g.dash.disableXlinkProcessing)return u.return(su(a,k,c));
995
- q=a.g.dash.xlinkFailGracefully;p=Ks(k,a.g.retryParameters,q,c,a.j.networkingEngine);ng(a.T,p);return F(u,p.promise,2)}w=u.h;return u.return(su(a,w,c))})}
996
- function su(a,b,c){var d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L,K,I,J,N,M,P,R,Q,X,W,ya,xa,Ba,Ga,bb,Za,Ta,Ca,nc,Ra,lb,Rb,Nc,le,me,ne,Jd,Li,Kd,Mi,Ni,Gg,oe;return O(function(oc){switch(oc.g){case 1:a.h&&a.h.l.clear();d=[c];e=[];f=new Map;g=hh(b,"Location");h=t(g);for(k=h.next();!k.done;k=h.next())if(l=k.value,m=l.attributes.serviceLocation,n=jh(l))q=Md(d,[n])[0],m&&(a.h?wt(a.h,"Location",m,q):f.set(m,q)),e.push(q);a.h?(p=xt(a.h,"Location",!0),0<p.length&&(d=a.A=p)):e.length&&(d=a.A=e);a.l.Zd=b.attributes.id||
997
- "";a.l.rd=oh(b,"publishTime",rh)||0;a.F=hh(b,"PatchLocation");w=Promise.resolve();if((u=lh(b,"ContentSteering"))&&a.j){v=u.attributes.defaultServiceLocation;if(a.h)a.h.i=d,a.h.h=v;else if(a.h=new st(a.j),a.h.configure(a.g),a.h.setManifestType("DASH"),a.h.i=d,a.h.h=v,A=jh(u))(z=oh(u,"queryBeforeStart",yh,!1))?w=tt(a.h,A):tt(a.h,A);D=t(f.keys());for(y=D.next();!y.done;y=D.next())B=y.value,C=f.get(B),wt(a.h,"Location",B,C)}E=hh(b,"BaseURL");L=!1;if(a.h)for(K=t(E),I=K.next();!I.done;I=K.next())J=I.value,
998
- N=J.attributes.serviceLocation,M=jh(J),N&&M&&(wt(a.h,"BaseURL",N,M),L=!0);L&&a.h||(P=E.map(jh),G=Md(d,P));R=function(){return a.h&&L?xt(a.h,"BaseURL"):G?G:[]};a.l.Ma=R;Q=0;E&&E.length&&(Q=oh(E[0],"availabilityTimeOffset",xh)||0);a.l.Sa=Q;X=a.g.dash.ignoreMinBufferTime;W=0;X||(W=oh(b,"minBufferTime",sh)||0);a.K=oh(b,"minimumUpdatePeriod",sh,-1);ya=oh(b,"availabilityStartTime",rh);xa=oh(b,"timeShiftBufferDepth",sh);Ba=a.g.dash.ignoreSuggestedPresentationDelay;Ga=null;Ba||(Ga=oh(b,"suggestedPresentationDelay",
994
+ function qu(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){qb("manifest.dash.manifestPreprocessor configuration","Please Use manifest.dash.manifestPreprocessorTXml instead.");h=ju(e,d);if(!h)throw new T(2,4,4001,c);f(h);e=zd(h.outerHTML)}k=$g(e,d);if(!k)throw new T(2,4,4001,c);l=a.g.dash.manifestPreprocessorTXml;m=xm;l!=m&&l(k);if("Patch"===d)return v.return(ru(a,k));if(n=a.g.dash.disableXlinkProcessing)return v.return(su(a,k,c));
995
+ p=a.g.dash.xlinkFailGracefully;r=Ks(k,a.g.retryParameters,p,c,a.j.networkingEngine);ng(a.T,r);return F(v,r.promise,2)}u=v.h;return v.return(su(a,u,c))})}
996
+ function su(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L,K,I,J,M,N,P,R,Q,X,W,ya,xa,Ba,Ga,bb,Za,Ta,Ca,nc,Ra,lb,Rb,Nc,le,me,ne,Jd,Li,Kd,Mi,Ni,Gg,oe;return O(function(oc){switch(oc.g){case 1:a.h&&a.h.l.clear();d=[c];e=[];f=new Map;g=hh(b,"Location");h=t(g);for(k=h.next();!k.done;k=h.next())if(l=k.value,m=l.attributes.serviceLocation,n=jh(l))p=Md(d,[n])[0],m&&(a.h?wt(a.h,"Location",m,p):f.set(m,p)),e.push(p);a.h?(r=xt(a.h,"Location",!0),0<r.length&&(d=a.A=r)):e.length&&(d=a.A=e);a.l.Zd=b.attributes.id||
997
+ "";a.l.rd=oh(b,"publishTime",rh)||0;a.F=hh(b,"PatchLocation");u=Promise.resolve();if((v=lh(b,"ContentSteering"))&&a.j){w=v.attributes.defaultServiceLocation;if(a.h)a.h.i=d,a.h.h=w;else if(a.h=new st(a.j),a.h.configure(a.g),a.h.setManifestType("DASH"),a.h.i=d,a.h.h=w,A=jh(v))(z=oh(v,"queryBeforeStart",yh,!1))?u=tt(a.h,A):tt(a.h,A);D=t(f.keys());for(y=D.next();!y.done;y=D.next())B=y.value,C=f.get(B),wt(a.h,"Location",B,C)}E=hh(b,"BaseURL");L=!1;if(a.h)for(K=t(E),I=K.next();!I.done;I=K.next())J=I.value,
998
+ M=J.attributes.serviceLocation,N=jh(J),M&&N&&(wt(a.h,"BaseURL",M,N),L=!0);L&&a.h||(P=E.map(jh),G=Md(d,P));R=function(){return a.h&&L?xt(a.h,"BaseURL"):G?G:[]};a.l.Ma=R;Q=0;E&&E.length&&(Q=oh(E[0],"availabilityTimeOffset",xh)||0);a.l.Sa=Q;X=a.g.dash.ignoreMinBufferTime;W=0;X||(W=oh(b,"minBufferTime",sh)||0);a.K=oh(b,"minimumUpdatePeriod",sh,-1);ya=oh(b,"availabilityStartTime",rh);xa=oh(b,"timeShiftBufferDepth",sh);Ba=a.g.dash.ignoreSuggestedPresentationDelay;Ga=null;Ba||(Ga=oh(b,"suggestedPresentationDelay",
999
999
  sh));bb=a.g.dash.ignoreMaxSegmentDuration;Za=null;bb||(Za=oh(b,"maxSegmentDuration",sh));Ta=b.attributes.type||"static";a.i&&a.i.presentationTimeline&&(a.da=a.i.presentationTimeline.V()&&"static"==Ta);a.l.type=Ta;tu(a);if(a.i)for(Ca=a.i.presentationTimeline,nc=t(Object.values(a.s)),Ra=nc.next();!Ra.done;Ra=nc.next())lb=Ra.value,lb.segmentIndex&&lb.segmentIndex.La(Ca.mb());else Rb=a.g.defaultPresentationDelay||1.5*W,Nc=null!=Ga?Ga:Rb,Ca=new sk(ya,Nc,a.g.dash.autoCorrectDrift);Ca.tc("static"==Ta);(le=
1000
1000
  Ca.V())&&!isNaN(a.g.availabilityWindowOverride)&&(xa=a.g.availabilityWindowOverride);null==xa&&(xa=Infinity);Ca.oe(xa);me=b.attributes.profiles||"";a.l.profiles=me.split(",");ne={vb:"static"!=Ta,presentationTimeline:Ca,ma:null,ga:null,ia:null,J:null,bandwidth:0,kf:!1,Sa:Q,Kb:null,profiles:me.split(","),roles:null};a.N=0;Jd=uu(a,ne,R,b,!1);Li=Jd.duration;Kd=Jd.periods;("static"!=Ta||a.da)&&Jd.rg||Ca.Za(Li||Infinity);a.ba&&!a.H&&(Mi=a.j.isAutoLowLatencyMode())&&(a.j.enableLowLatencyMode(),a.H=a.j.isLowLatencyMode());
1001
- a.H&&Ca.$g(a.Y);Ca.xf(Za||1);return F(oc,w,2);case 2:a.H&&(W=0,Ni=null!=Ga?Ga:a.g.defaultPresentationDelay,Ca.Of(Ni));if(!a.i)return F(oc,a.m.Je(Kd,ne.vb),6);a.i.periodCount=Kd.length;a.i.gapCount=a.N;return F(oc,vu(a,Kd,!1),4);case 6:a.i={presentationTimeline:Ca,variants:a.m.j,textStreams:a.m.hf(),imageStreams:a.m.i,offlineSessionIds:[],minBufferTime:W||0,sequenceMode:a.g.dash.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,type:"DASH",serviceDescription:wu(b),nextUrl:xu(b),periodCount:Kd.length,
1001
+ a.H&&Ca.$g(a.Y);Ca.xf(Za||1);return F(oc,u,2);case 2:a.H&&(W=0,Ni=null!=Ga?Ga:a.g.defaultPresentationDelay,Ca.Of(Ni));if(!a.i)return F(oc,a.m.Je(Kd,ne.vb),6);a.i.periodCount=Kd.length;a.i.gapCount=a.N;return F(oc,vu(a,Kd,!1),4);case 6:a.i={presentationTimeline:Ca,variants:a.m.j,textStreams:a.m.hf(),imageStreams:a.m.i,offlineSessionIds:[],minBufferTime:W||0,sequenceMode:a.g.dash.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,type:"DASH",serviceDescription:wu(b),nextUrl:xu(b),periodCount:Kd.length,
1002
1002
  gapCount:a.N,isLowLatency:a.ba};if(!Ca.nh()){oc.u(7);break}Gg=hh(b,"UTCTiming");return F(oc,yu(a,R,Gg),8);case 8:oe=oc.h;if(!a.j)return oc.return();Ca.ah(oe);case 7:Ca.Ud();case 4:a.j.makeTextStreamsForClosedCaptions(a.i),H(oc)}})}function vu(a,b,c){var d;return O(function(e){if(1==e.g)return F(e,a.m.Je(b,!0,c),2);a.i.variants=a.m.j;d=a.m.hf();0<d.length&&(a.i.textStreams=d);a.i.imageStreams=a.m.i;a.j.filter(a.i);H(e)})}
1003
- function ru(a,b){var c,d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L,K,I,J;return O(function(N){if(1==N.g){c=b.attributes.mpdId;d=oh(b,"originalPublishTime",rh);if(!c||c!==a.l.Zd||d!==a.l.rd)throw a.F=[],new T(1,4,4052);e=[];f=[];g=new Set;h=t(gh(b));for(k=h.next();!k.done;k=h.next())if(l=k.value,m=Ah(l.attributes.sel||""),n=m[m.length-1],q=jh(l)||"","MPD"===n.name)if("mediaPresentationDuration"===n.Sb){p=jh(l)||"";var M=sh(p);if(null!=M){a.l.Kb=M;for(var P=t(a.o.values()),R=P.next();!R.done;R=P.next())R.value.Kb=
1004
- M}}else if("type"===n.Sb){a.i.presentationTimeline.tc("static"==q);a.l.type=q;M=t(a.o.values());for(P=M.next();!P.done;P=M.next())P.value.vb="dynamic"==q;"static"==q&&(a.K=-1)}else"publishTime"===n.Sb?a.l.rd=rh(q)||0:null===n.Sb&&"add"===l.tagName&&f.push(l);else if("PatchLocation"===n.name)Bh(a.F,l);else if("Period"===n.name)"add"===l.tagName?f.push(l):"remove"===l.tagName&&n.id&&zu(a,n.id);else if("SegmentTemplate"===n.name){P=Ah(l.attributes.sel||"");M=P[P.length-1];if(M.Sb){P=Au(a,P);R=jh(l)||
1005
- "";for(var Q=t(P),X=Q.next();!X.done;X=Q.next())X=a.o.get(X.value),Dh(X.J.ac,l.tagName,M.Sb,R);M=P}else M=[];w=M;u=t(w);for(v=u.next();!v.done;v=u.next())A=v.value,g.add(A)}else if("SegmentTimeline"===n.name||"S"===n.name){M=Ah(l.attributes.sel||"");M=Au(a,M);P=t(M);for(R=P.next();!R.done;R=P.next())R=a.o.get(R.value),R=Hs(R,it,"SegmentTimeline"),Q=hh(R,"S"),Bh(Q,l),R.children=Q;z=M;D=t(z);for(y=D.next();!y.done;y=D.next())B=y.value,g.add(B)}C=t(g);for(E=C.next();!E.done;E=C.next())G=E.value,Bu(a,
1006
- G);L=t(f);for(K=L.next();!K.done;K=L.next())I=K.value,e.push.apply(e,x(uu(a,{vb:"dynamic"==a.l.type,presentationTimeline:a.i.presentationTimeline,ma:null,ga:null,ia:null,J:null,bandwidth:0,kf:!1,Sa:a.l.Sa,profiles:a.l.profiles,Kb:a.l.Kb,roles:null},a.l.Ma,I,!0).periods));if(!e.length)return N.u(2);a.i.periodCount+=e.length;a.i.gapCount=a.N;return F(N,vu(a,e,!0),2)}"static"==a.l.type&&(J=a.l.Kb,a.i.presentationTimeline.Za(J||Infinity));H(N)})}
1003
+ function ru(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L,K,I,J;return O(function(M){if(1==M.g){c=b.attributes.mpdId;d=oh(b,"originalPublishTime",rh);if(!c||c!==a.l.Zd||d!==a.l.rd)throw a.F=[],new T(1,4,4052);e=[];f=[];g=new Set;h=t(gh(b));for(k=h.next();!k.done;k=h.next())if(l=k.value,m=Ah(l.attributes.sel||""),n=m[m.length-1],p=jh(l)||"","MPD"===n.name)if("mediaPresentationDuration"===n.Sb){r=jh(l)||"";var N=sh(r);if(null!=N){a.l.Kb=N;for(var P=t(a.o.values()),R=P.next();!R.done;R=P.next())R.value.Kb=
1004
+ N}}else if("type"===n.Sb){a.i.presentationTimeline.tc("static"==p);a.l.type=p;N=t(a.o.values());for(P=N.next();!P.done;P=N.next())P.value.vb="dynamic"==p;"static"==p&&(a.K=-1)}else"publishTime"===n.Sb?a.l.rd=rh(p)||0:null===n.Sb&&"add"===l.tagName&&f.push(l);else if("PatchLocation"===n.name)Bh(a.F,l);else if("Period"===n.name)"add"===l.tagName?f.push(l):"remove"===l.tagName&&n.id&&zu(a,n.id);else if("SegmentTemplate"===n.name){P=Ah(l.attributes.sel||"");N=P[P.length-1];if(N.Sb){P=Au(a,P);R=jh(l)||
1005
+ "";for(var Q=t(P),X=Q.next();!X.done;X=Q.next())X=a.o.get(X.value),Dh(X.J.ac,l.tagName,N.Sb,R);N=P}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=Ah(l.attributes.sel||"");N=Au(a,N);P=t(N);for(R=P.next();!R.done;R=P.next())R=a.o.get(R.value),R=Hs(R,it,"SegmentTimeline"),Q=hh(R,"S"),Bh(Q,l),R.children=Q;z=N;D=t(z);for(y=D.next();!y.done;y=D.next())B=y.value,g.add(B)}C=t(g);for(E=C.next();!E.done;E=C.next())G=E.value,Bu(a,
1006
+ G);L=t(f);for(K=L.next();!K.done;K=L.next())I=K.value,e.push.apply(e,x(uu(a,{vb:"dynamic"==a.l.type,presentationTimeline:a.i.presentationTimeline,ma:null,ga:null,ia:null,J:null,bandwidth:0,kf:!1,Sa:a.l.Sa,profiles:a.l.profiles,Kb:a.l.Kb,roles:null},a.l.Ma,I,!0).periods));if(!e.length)return M.u(2);a.i.periodCount+=e.length;a.i.gapCount=a.N;return F(M,vu(a,e,!0),2)}"static"==a.l.type&&(J=a.l.Kb,a.i.presentationTimeline.Za(J||Infinity));H(M)})}
1007
1007
  function zu(a,b){a.i.periodCount--;for(var c=t(a.o.keys()),d=c.next();!d.done;d=c.next())if(d=d.value,d.startsWith(b)){var e=a.o.get(d);Hs(e,it,"SegmentTimeline").children=[];Bu(a,d);a.o.delete(d)}a.B=a.B.filter(function(f){return f!==b})}
1008
1008
  function Au(a,b){var c="",d="",e=-1,f="";b=t(b);for(var g=b.next();!g.done;g=b.next())g=g.value,"Period"===g.name?c=g.id:"AdaptationSet"===g.name?(d=g.id,null!==g.position&&(e=g.position)):"Representation"===g.name&&(f=g.id);b=[];if(f)b.push(c+","+f);else if(d)for(e=t(a.o.values()),a=e.next();!a.done;a=e.next())a=a.value,a.ma.id===c&&a.ia.id===d&&a.J.id&&b.push(c+","+a.J.id);else if(-1<e)for(d=t(a.o.values()),a=d.next();!a.done;a=d.next())a=a.value,a.ma.id===c&&a.ia.position===e&&a.J.id&&b.push(c+
1009
1009
  ","+a.J.id);return b}function Bu(a,b){var c=a.o.get(b),d=a.s[b];d.segmentIndex&&d.segmentIndex.La(a.i.presentationTimeline.mb());try{var e=ht(c,function(f,g,h,k){return Cu(a,f,g,h,k)},a.s,!0,a.g.dash.initialSegmentLimit,a.ea,c.J.aesKey,null,!0);d.createSegmentIndex=function(){return O(function(f){if(1==f.g)return d.segmentIndex?f.u(0):F(f,e.ic(),3);d.segmentIndex=f.h;H(f)})}}catch(f){if(b=c.J.contentType,b!=Ud&&"application"!=b&&"image"!=b||4002!=f.code)throw f;}}
1010
1010
  function wu(a){var b=lh(a,"ServiceDescription");if(!b)return null;a=lh(b,"Latency");b=lh(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)));
1011
1011
  return c}function xu(a){a=hh(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}
1012
- function uu(a,b,c,d,e){var f=b.Kb;f||(f=oh(d,"mediaPresentationDuration",sh),a.l.Kb=f);var g=0;a.i&&a.i.presentationTimeline&&a.da&&(g=a.i.presentationTimeline.Vb());var h=[],k=g;d=hh(d,"Period");for(var l=0;l<d.length;l++){var m=d[l],n=d[l+1],q=oh(m,"start",sh,k),p=m.attributes.id,w=oh(m,"duration",sh),u=null;if(n){var v=oh(n,"start",sh);null!=v&&(u=v-q)}else null!=f&&(u=f-q+g);v=Xd;u&&w&&Math.abs(u-w)>v&&u>w&&a.N++;null==u&&(u=w);if(!(null!==a.O&&null!==p&&null!==q&&q<a.O)||a.B.includes(p)||l+1==
1013
- d.length){null!==q&&(null===a.O||q>a.O)&&(a.O=q);k=Du(a,b,c,{start:q,duration:u,node:m,pf:null==u||!n});h.push(k);b.ma.id&&u&&(a.ea[b.ma.id]=u);if(null==u){k=null;break}k=q+u}}if(e)for(b=t(h),c=b.next();!c.done;c=b.next())c=c.value.id,a.B.includes(c)||a.B.push(c);else a.B=h.map(function(A){return A.id});return null!=f?{periods:h,duration:f+g,rg:!1}:{periods:h,duration:k,rg:!0}}
1012
+ function uu(a,b,c,d,e){var f=b.Kb;f||(f=oh(d,"mediaPresentationDuration",sh),a.l.Kb=f);var g=0;a.i&&a.i.presentationTimeline&&a.da&&(g=a.i.presentationTimeline.Vb());var h=[],k=g;d=hh(d,"Period");for(var l=0;l<d.length;l++){var m=d[l],n=d[l+1],p=oh(m,"start",sh,k),r=m.attributes.id,u=oh(m,"duration",sh),v=null;if(n){var w=oh(n,"start",sh);null!=w&&(v=w-p)}else null!=f&&(v=f-p+g);w=Xd;v&&u&&Math.abs(v-u)>w&&v>u&&a.N++;null==v&&(v=u);if(!(null!==a.O&&null!==r&&null!==p&&p<a.O)||a.B.includes(r)||l+1==
1013
+ d.length){null!==p&&(null===a.O||p>a.O)&&(a.O=p);k=Du(a,b,c,{start:p,duration:v,node:m,pf:null==v||!n});h.push(k);b.ma.id&&v&&(a.ea[b.ma.id]=v);if(null==v){k=null;break}k=p+v}}if(e)for(b=t(h),c=b.next();!c.done;c=b.next())c=c.value.id,a.B.includes(c)||a.B.push(c);else a.B=h.map(function(A){return A.id});return null!=f?{periods:h,duration:f+g,rg:!1}:{periods:h,duration:k,rg:!0}}
1014
1014
  function tu(a){var b=Object.keys(a.C);if(b.length!==a.B.length){b=b.filter(function(f){return!a.B.includes(f)});b=t(b);for(var c=b.next();!c.done;c=b.next()){c=c.value;for(var d=t(a.C[c]),e=d.next();!e.done;e=d.next())delete a.s[e.value];delete a.C[c]}}}
1015
1015
  function Du(a,b,c,d){b.ma=Eu(a,d.node,null,c);b.ga=d;b.ma.Sa=b.Sa;b.ma.id||(b.ma.id="__shaka_period_"+d.start);var e=hh(d.node,"EventStream");c=b.presentationTimeline.mb();e=t(e);for(var f=e.next();!f.done;f=e.next())Fu(a,d.start,d.duration,f.value,c);c=hh(d.node,"AdaptationSet").map(function(m,n){return Gu(a,b,n,m)}).filter(Ae);if(b.vb){d=[];e=t(c);for(f=e.next();!f.done;f=e.next()){f=t(f.value.Mi);for(var g=f.next();!g.done;g=f.next())d.push(g.value)}if(d.length!=(new Set(d)).size)throw new T(2,
1016
1016
  4,4018);}d=c.filter(function(m){return!m.Yf});c=c.filter(function(m){return m.Yf});c=t(c);for(e=c.next();!e.done;e=c.next()){e=e.value;f=e.Yf.split(" ");g=t(d);for(var h=g.next();!h.done;h=g.next())if(h=h.value,f.includes(h.id)){h=t(h.streams);for(var k=h.next(),l={};!k.done;l={Sf:void 0},k=h.next())l.Sf=k.value,l.Sf.trickModeVideo=e.streams.find(function(m){return function(n){return fe(m.Sf.codecs)==fe(n.codecs)}}(l))}}c=Hu(a.g.disableAudio,d,"audio");e=Hu(a.g.disableVideo,d,"video");f=Hu(a.g.disableText,
1017
1017
  d,Ud);d=Hu(a.g.disableThumbnails,d,"image");if(0===e.length&&0===c.length)throw new T(2,4,4004);return{id:b.ma.id,audioStreams:c,videoStreams:e,textStreams:f,imageStreams:d}}function Hu(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},[])}
1018
1018
  function Gu(a,b,c,d){function e(I){switch(I){case 1:case 5:case 6:case 7:return"srgb";case 9:return"rec2020";case 11:case 12:return"p3"}}function f(I){switch(I){case 1:case 6:case 13:case 14:case 15:return"SDR";case 16:return"PQ";case 18:return"HLG"}}b.ia=Eu(a,d,b.ma,null);b.ia.position=c;var g=!1;c=hh(d,"Role");var h=c.map(function(I){return I.attributes.value}).filter(Ae),k=void 0,l=b.ia.contentType==Ud;l&&(k="subtitle");c=t(c);for(var m=c.next();!m.done;m=c.next()){m=m.value;var n=m.attributes.schemeIdUri;
1019
- if(null==n||"urn:mpeg:dash:role:2011"==n)switch(m=m.attributes.value,m){case "main":g=!0;break;case "caption":case "subtitle":k=m}}var q,p;n=hh(d,"EssentialProperty");c=null;var w=!1;m=!1;n=t(n);for(var u=n.next();!u.done;u=n.next()){u=u.value;var v=u.attributes.schemeIdUri;"http://dashif.org/guidelines/trickmode"==v?c=u.attributes.value:"urn:mpeg:mpegB:cicp:TransferCharacteristics"==v?q=f(parseInt(u.attributes.value,10)):"urn:mpeg:mpegB:cicp:ColourPrimaries"==v?p=e(parseInt(u.attributes.value,10)):
1020
- "urn:mpeg:mpegB:cicp:MatrixCoefficients"!=v&&("urn:mpeg:dash:ssr:2023"==v&&a.g.dash.enableFastSwitching?w=!0:m=!0)}var A=null;n=hh(d,"SupplementalProperty");n=t(n);for(u=n.next();!u.done;u=n.next())u=u.value,v=u.attributes.schemeIdUri,"http://dashif.org/guidelines/last-segment-number"==v?A=parseInt(u.attributes.value,10)-1:"urn:mpeg:mpegB:cicp:TransferCharacteristics"==v?q=f(parseInt(u.attributes.value,10)):"urn:mpeg:mpegB:cicp:ColourPrimaries"==v&&(p=e(parseInt(u.attributes.value,10)));n=hh(d,"Accessibility");
1021
- var z=new Map,D;n=t(n);for(u=n.next();!u.done;u=n.next())if(v=u.value,u=v.attributes.schemeIdUri,v=v.attributes.value,"urn:scte:dash:cc:cea-608:2015"!=u||a.g.disableText)if("urn:scte:dash:cc:cea-708:2015"!=u||a.g.disableText)"urn:mpeg:dash:role:2011"==u?null!=v&&(h.push(v),"captions"==v&&(k="caption")):"urn:tva:metadata:cs:AudioPurposeCS:2007"==u&&("1"==v?D="visually impaired":"2"==v&&(D="hard of hearing"));else if(u=1,null!=v){v=t(v.split(";"));for(var y=v.next();!y.done;y=v.next()){var B=y.value,
1022
- C=y=void 0;B.includes("=")?(B=B.split("="),y="svc"+B[0],C=B[1].split(",")[0].split(":").pop()):(y="svc"+u,u++,C=B);z.set(y,De(C))}}else z.set("svc1","und");else if(u=1,null!=v)for(v=v.split(";"),y=t(v),B=y.next();!B.done;B=y.next()){C=B.value;var E=B=void 0;C.includes("=")?(C=C.split("="),B=C[0].startsWith("CC")?C[0]:"CC"+C[0],E=C[1]||"und"):(B="CC"+u,2==v.length?u+=2:u++,E=C);z.set(B,De(E))}else z.set("CC1","und");if(m)return null;m=hh(d,"ContentProtection");var G=ts(m,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI),
1023
- L=De(b.ia.language||"und"),K=b.ia.label;m=hh(d,"Representation");d=m.map(function(I){if(I=Iu(a,b,G,k,L,K,g,h,z,I,D,A))I.hdr=I.hdr||q,I.colorGamut=I.colorGamut||p,I.fastSwitching=w;return I}).filter(function(I){return!!I});if(0==d.length){c="image"==b.ia.contentType;if(a.g.dash.ignoreEmptyAdaptationSet||l||c)return null;throw new T(2,4,4003);}if(!b.ia.contentType||"application"==b.ia.contentType)for(b.ia.contentType=Ju(d[0].mimeType,d[0].codecs),l=t(d),n=l.next();!n.done;n=l.next())n.value.type=b.ia.contentType;
1024
- l=b.ia.id||"__fake__"+a.la++;n=t(d);for(u=n.next();!u.done;u=n.next()){u=u.value;v=t(G.drmInfos);for(y=v.next();!y.done;y=v.next())y=y.value,y.keyIds=y.keyIds&&u.keyIds?new Set([].concat(x(y.keyIds),x(u.keyIds))):y.keyIds||u.keyIds;a.g.dash.enableAudioGroups&&(u.groupId=l)}m=m.map(function(I){return I.attributes.id}).filter(Ae);return{id:l,contentType:b.ia.contentType,language:L,ek:g,streams:d,drmInfos:G.drmInfos,Yf:c,Mi:m}}
1025
- function Iu(a,b,c,d,e,f,g,h,k,l,m,n){b.J=Eu(a,l,b.ia,null);var q=b.J.id;a.Y=Math.min(a.Y,b.J.Sa);a.ba=0<a.Y;if(!Ku(b.J))return null;var p=b.ga.start;b.bandwidth=oh(l,"bandwidth",vh)||0;b.roles=h;var w=b.J.contentType,u=w==Ud||"application"==w;w="image"==w;try{var v=void 0;if(c.Ee){var A=b.J.Ma,z=Md(A(),[c.Ee.ti]),D=tg(z,a.g.retryParameters);v={bitsKey:128,blockCipherMode:"CBC",iv:c.Ee.iv,firstMediaSequenceNumber:0,fetchKey:function(){var J,N,M;return O(function(P){if(1==P.g)return F(P,pu(a,D,6),2);
1026
- if(3!=P.g){J=P.h;if(!J.data||16!=J.data.byteLength)throw new T(2,4,4049);N={name:"AES-CBC"};M=v;return F(P,window.crypto.subtle.importKey("raw",J.data,N,!0,["decrypt"]),3)}M.cryptoKey=P.h;v.fetchKey=void 0;H(P)})}}}b.J.aesKey=v;A=function(J,N,M,P){return Cu(a,J,N,M,P)};if(b.J.Qc)var y=Xs(b,A,v);else if(b.J.Pb)y=ct(b,a.s,v);else if(b.J.ac)y=ht(b,A,a.s,!!a.i,a.g.dash.initialSegmentLimit,a.ea,v,n,!1);else{var B=b.ga.duration||0,C=b.J.Ma,E=b.J.mimeType,G=b.J.codecs;y={ic:function(){var J=Qk(p,B,C());
1027
- J.Hb(function(N){N.mimeType=E;N.codecs=G});return Promise.resolve(J)}}}}catch(J){if((u||w)&&4002==J.code)return null;throw J;}n=hh(l,"ContentProtection");n=xs(n,c,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI);n=new Set(n?[n]:[]);A=!1;hh(l,"SupplementalProperty").some(function(J){return"tag:dolby.com,2018:dash:EC3_ExtensionType:2018"==J.attributes.schemeIdUri&&"JOC"==J.attributes.value})&&(A=!0);z=!1;u&&(z=h.includes("forced_subtitle")||h.includes("forced-subtitle"));var L;if(w&&((l=hh(l,"EssentialProperty").find(function(J){return["http://dashif.org/thumbnail_tile",
1028
- "http://dashif.org/guidelines/thumbnail_tile"].includes(J.attributes.schemeIdUri)}))&&(L=l.attributes.value),!L))return null;var K;u=b.J.codecs;b.profiles.includes("http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10")&&(u.includes("hvc1.2.4.L153.B0")||u.includes("hev1.2.4.L153.B0"))&&(K="PQ");l=b.J.id?b.ma.id+","+b.J.id:"";a.F.length&&q&&a.o.set(b.ma.id+","+q,Lu(b));var I=l&&a.s[l]?a.s[l]:{id:a.la++,originalId:b.J.id,groupId:null,createSegmentIndex:function(){return Promise.resolve()},closeSegmentIndex:function(){I.segmentIndex&&
1029
- (I.segmentIndex.release(),I.segmentIndex=null)},segmentIndex:null,mimeType:b.J.mimeType,codecs:u,frameRate:b.J.frameRate,pixelAspectRatio:b.J.pixelAspectRatio,bandwidth:b.bandwidth,width:b.J.width,height:b.J.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.J.emsgSchemeIdUris,roles:h,forced:z,channelsCount:b.J.be,audioSamplingRate:b.J.audioSamplingRate,spatialAudio:A,
1030
- closedCaptions:k,hdr:K,colorGamut:void 0,videoLayout:void 0,tilesLayout:L,accessibilityPurpose:m,external:!1,fastSwitching:!1,fullMimeTypes:new Set([Zd(b.J.mimeType,b.J.codecs)])};I.createSegmentIndex=function(){var J;return O(function(N){if(1==N.g){if(I.segmentIndex)return N.u(0);J=I;return F(N,y.ic(),3)}J.segmentIndex=N.h;H(N)})};l&&b.vb&&!a.s[l]&&(b=b.ma.id||"",a.C[b]||(a.C[b]=[]),a.s[l]=I,a.C[b].push(l));return I}
1031
- function Lu(a){function b(c){if(!c)return null;c=Me(c);c.Qc=null;c.Pb=null;c.ac=Fh(c.ac);return c}a=Me(a);a.ma=b(a.ma);a.ia=b(a.ia);a.J=b(a.J);a.ga&&(a.ga=Me(a.ga),a.ga.node=null);return a}
1019
+ if(null==n||"urn:mpeg:dash:role:2011"==n)switch(m=m.attributes.value,m){case "main":g=!0;break;case "caption":case "subtitle":k=m}}var p,r;n=hh(d,"EssentialProperty");c=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?c=v.attributes.value:"urn:mpeg:mpegB:cicp:TransferCharacteristics"==w?p=f(parseInt(v.attributes.value,10)):"urn:mpeg:mpegB:cicp:ColourPrimaries"==w?r=e(parseInt(v.attributes.value,10)):
1020
+ "urn:mpeg:mpegB:cicp:MatrixCoefficients"!=w&&("urn:mpeg:dash:ssr:2023"==w&&a.g.dash.enableFastSwitching?u=!0:m=!0)}var A=null;n=hh(d,"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=f(parseInt(v.attributes.value,10)):"urn:mpeg:mpegB:cicp:ColourPrimaries"==w&&(r=e(parseInt(v.attributes.value,10)));n=hh(d,"Accessibility");
1021
+ var z=new Map,D;n=t(n);for(v=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||a.g.disableText)if("urn:scte:dash:cc:cea-708:2015"!=v||a.g.disableText)"urn:mpeg:dash:role:2011"==v?null!=w&&(h.push(w),"captions"==w&&(k="caption")):"urn:tva:metadata:cs:AudioPurposeCS:2007"==v&&("1"==w?D="visually impaired":"2"==w&&(D="hard of hearing"));else if(v=1,null!=w){w=t(w.split(";"));for(var y=w.next();!y.done;y=w.next()){var B=y.value,
1022
+ C=y=void 0;B.includes("=")?(B=B.split("="),y="svc"+B[0],C=B[1].split(",")[0].split(":").pop()):(y="svc"+v,v++,C=B);z.set(y,De(C))}}else z.set("svc1","und");else if(v=1,null!=w)for(w=w.split(";"),y=t(w),B=y.next();!B.done;B=y.next()){C=B.value;var E=B=void 0;C.includes("=")?(C=C.split("="),B=C[0].startsWith("CC")?C[0]:"CC"+C[0],E=C[1]||"und"):(B="CC"+v,2==w.length?v+=2:v++,E=C);z.set(B,De(E))}else z.set("CC1","und");if(m)return null;m=hh(d,"ContentProtection");var G=ts(m,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI),
1023
+ L=De(b.ia.language||"und"),K=b.ia.label;m=hh(d,"Representation");d=m.map(function(I){if(I=Iu(a,b,G,k,L,K,g,h,z,I,D,A))I.hdr=I.hdr||p,I.colorGamut=I.colorGamut||r,I.fastSwitching=u;return I}).filter(function(I){return!!I});if(0==d.length){c="image"==b.ia.contentType;if(a.g.dash.ignoreEmptyAdaptationSet||l||c)return null;throw new T(2,4,4003);}if(!b.ia.contentType||"application"==b.ia.contentType)for(b.ia.contentType=Ju(d[0].mimeType,d[0].codecs),l=t(d),n=l.next();!n.done;n=l.next())n.value.type=b.ia.contentType;
1024
+ l=b.ia.id||"__fake__"+a.la++;n=t(d);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(I){return I.attributes.id}).filter(Ae);return{id:l,contentType:b.ia.contentType,language:L,ek:g,streams:d,drmInfos:G.drmInfos,Yf:c,Mi:m}}
1025
+ function Iu(a,b,c,d,e,f,g,h,k,l,m,n){b.J=Eu(a,l,b.ia,null);var p=b.J.id;a.Y=Math.min(a.Y,b.J.Sa);a.ba=0<a.Y;if(!Ku(b.J))return null;var r=b.ga.start;b.bandwidth=oh(l,"bandwidth",vh)||0;b.roles=h;var u=b.J.contentType,v=u==Ud||"application"==u;u="image"==u;try{var w=void 0;if(c.Ee){var A=b.J.Ma,z=Md(A(),[c.Ee.ti]),D=tg(z,a.g.retryParameters);w={bitsKey:128,blockCipherMode:"CBC",iv:c.Ee.iv,firstMediaSequenceNumber:0,fetchKey:function(){var J,M,N;return O(function(P){if(1==P.g)return F(P,pu(a,D,6),2);
1026
+ if(3!=P.g){J=P.h;if(!J.data||16!=J.data.byteLength)throw new T(2,4,4049);M={name:"AES-CBC"};N=w;return F(P,window.crypto.subtle.importKey("raw",J.data,M,!0,["decrypt"]),3)}N.cryptoKey=P.h;w.fetchKey=void 0;H(P)})}}}b.J.aesKey=w;A=function(J,M,N,P){return Cu(a,J,M,N,P)};if(b.J.Rc)var y=Xs(b,A,w);else if(b.J.Pb)y=ct(b,a.s,w);else if(b.J.ac)y=ht(b,A,a.s,!!a.i,a.g.dash.initialSegmentLimit,a.ea,w,n,!1);else{var B=b.ga.duration||0,C=b.J.Ma,E=b.J.mimeType,G=b.J.codecs;y={ic:function(){var J=Qk(r,B,C());
1027
+ J.Hb(function(M){M.mimeType=E;M.codecs=G});return Promise.resolve(J)}}}}catch(J){if((v||u)&&4002==J.code)return null;throw J;}n=hh(l,"ContentProtection");n=xs(n,c,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI);n=new Set(n?[n]:[]);A=!1;hh(l,"SupplementalProperty").some(function(J){return"tag:dolby.com,2018:dash:EC3_ExtensionType:2018"==J.attributes.schemeIdUri&&"JOC"==J.attributes.value})&&(A=!0);z=!1;v&&(z=h.includes("forced_subtitle")||h.includes("forced-subtitle"));var L;if(u&&((l=hh(l,"EssentialProperty").find(function(J){return["http://dashif.org/thumbnail_tile",
1028
+ "http://dashif.org/guidelines/thumbnail_tile"].includes(J.attributes.schemeIdUri)}))&&(L=l.attributes.value),!L))return null;var K;v=b.J.codecs;b.profiles.includes("http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10")&&(v.includes("hvc1.2.4.L153.B0")||v.includes("hev1.2.4.L153.B0"))&&(K="PQ");l=b.J.id?b.ma.id+","+b.J.id:"";a.F.length&&p&&a.o.set(b.ma.id+","+p,Lu(b));var I=l&&a.s[l]?a.s[l]:{id:a.la++,originalId:b.J.id,groupId:null,createSegmentIndex:function(){return Promise.resolve()},closeSegmentIndex:function(){I.segmentIndex&&
1029
+ (I.segmentIndex.release(),I.segmentIndex=null)},segmentIndex:null,mimeType:b.J.mimeType,codecs:v,frameRate:b.J.frameRate,pixelAspectRatio:b.J.pixelAspectRatio,bandwidth:b.bandwidth,width:b.J.width,height:b.J.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.J.emsgSchemeIdUris,roles:h,forced:z,channelsCount:b.J.be,audioSamplingRate:b.J.audioSamplingRate,spatialAudio:A,
1030
+ closedCaptions:k,hdr:K,colorGamut:void 0,videoLayout:void 0,tilesLayout:L,accessibilityPurpose:m,external:!1,fastSwitching:!1,fullMimeTypes:new Set([Zd(b.J.mimeType,b.J.codecs)])};I.createSegmentIndex=function(){var J;return O(function(M){if(1==M.g){if(I.segmentIndex)return M.u(0);J=I;return F(M,y.ic(),3)}J.segmentIndex=M.h;H(M)})};l&&b.vb&&!a.s[l]&&(b=b.ma.id||"",a.C[b]||(a.C[b]=[]),a.s[l]=I,a.C[b].push(l));return I}
1031
+ function Lu(a){function b(c){if(!c)return null;c=Me(c);c.Rc=null;c.Pb=null;c.ac=Fh(c.ac);return c}a=Me(a);a.ma=b(a.ma);a.ia=b(a.ia);a.J=b(a.J);a.ga&&(a.ga=Me(a.ga),a.ga.node=null);return a}
1032
1032
  function lu(a){var b,c;return O(function(d){switch(d.g){case 1:return b=0,ra(d,2),F(d,mu(a),4);case 4:b=d.h;ta(d,3);break;case 2:if(c=ua(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();nu(a,b);H(d)}})}function nu(a,b){if(!(0>a.K)){var c=a.K;0<=a.g.dash.updatePeriod&&(c=a.g.dash.updatePeriod);a.L.Z(Math.max(c-b,Ua(a.fa)))}}
1033
1033
  function Eu(a,b,c,d){c=c||{contentType:"",mimeType:"",codecs:"",emsgSchemeIdUris:[],frameRate:void 0,pixelAspectRatio:void 0,be:null,audioSamplingRate:null,Sa:0,Kf:0};d=d||c.Ma;var e=b.attributes.id,f=hh(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=jh(m);l&&m&&(wt(a.h,e,l,m),h=!0)}h&&a.h||(g=f.map(jh));k=b.attributes.contentType||c.contentType;l=b.attributes.mimeType||c.mimeType;m=[b.attributes.codecs||c.codecs];var n=ph(b,
1034
- "urn:scte:dash:scte214-extensions","supplementalCodecs");n&&m.push(n);m=wl(m).join(",");n=oh(b,"frameRate",zh)||c.frameRate;var q=b.attributes.sar||c.pixelAspectRatio,p=Mu(hh(b,"InbandEventStream"),c.emsgSchemeIdUris),w=hh(b,"AudioChannelConfiguration");w=Zu(w)||c.be;var u=oh(b,"audioSamplingRate",wh)||c.audioSamplingRate;k||(k=Ju(l,m));var v=lh(b,"SegmentBase"),A=lh(b,"SegmentTemplate"),z=v?oh(v,"availabilityTimeOffset",xh)||0:0,D=A?oh(A,"availabilityTimeOffset",xh)||0:0,y=f&&f.length?oh(f[0],"availabilityTimeOffset",
1035
- xh)||0:0;z=c.Sa+y+z+D;D=null;(y=lh(b,"SegmentSequenceProperties"))&&(y=lh(y,"SAP"))&&(D=oh(y,"cadence",uh));y=b.attributes.label;var B=hh(b,"Label");B&&B.length&&(B=B[0],ih(B)&&(y=ih(B)));return{Ma:function(){return Md(d(),f.length?a.h&&h?xt(a.h,e):g?g:[]:[])},Qc:v||c.Qc,Pb:lh(b,"SegmentList")||c.Pb,ac:A||c.ac,width:oh(b,"width",wh)||c.width,height:oh(b,"height",wh)||c.height,contentType:k,mimeType:l,codecs:m,frameRate:n,pixelAspectRatio:q,emsgSchemeIdUris:p,id:e,language:b.attributes.lang,be:w,audioSamplingRate:u,
1036
- Sa:z,Pd:null,Kf:D||c.Kf,label:y||null}}function Mu(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}
1034
+ "urn:scte:dash:scte214-extensions","supplementalCodecs");n&&m.push(n);m=wl(m).join(",");n=oh(b,"frameRate",zh)||c.frameRate;var p=b.attributes.sar||c.pixelAspectRatio,r=Yu(hh(b,"InbandEventStream"),c.emsgSchemeIdUris),u=hh(b,"AudioChannelConfiguration");u=Zu(u)||c.be;var v=oh(b,"audioSamplingRate",wh)||c.audioSamplingRate;k||(k=Ju(l,m));var w=lh(b,"SegmentBase"),A=lh(b,"SegmentTemplate"),z=w?oh(w,"availabilityTimeOffset",xh)||0:0,D=A?oh(A,"availabilityTimeOffset",xh)||0:0,y=f&&f.length?oh(f[0],"availabilityTimeOffset",
1035
+ xh)||0:0;z=c.Sa+y+z+D;D=null;(y=lh(b,"SegmentSequenceProperties"))&&(y=lh(y,"SAP"))&&(D=oh(y,"cadence",uh));y=b.attributes.label;var B=hh(b,"Label");B&&B.length&&(B=B[0],ih(B)&&(y=ih(B)));return{Ma:function(){return Md(d(),f.length?a.h&&h?xt(a.h,e):g?g:[]:[])},Rc:w||c.Rc,Pb:lh(b,"SegmentList")||c.Pb,ac:A||c.ac,width:oh(b,"width",wh)||c.width,height:oh(b,"height",wh)||c.height,contentType:k,mimeType:l,codecs:m,frameRate:n,pixelAspectRatio:p,emsgSchemeIdUris:r,id:e,language:b.attributes.lang,be:u,audioSamplingRate:v,
1036
+ Sa:z,Pd:null,Kf:D||c.Kf,label:y||null}}function Yu(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}
1037
1037
  function Zu(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=
1038
- 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 Ku(a){var b=a.Qc?1:0;b+=a.Pb?1:0;b+=a.ac?1:0;if(0==b)return a.contentType==Ud||"application"==a.contentType?!0:!1;1!=b&&(a.Qc&&(a.Pb=null),a.ac=null);return!0}
1038
+ 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 Ku(a){var b=a.Rc?1:0;b+=a.Pb?1:0;b+=a.ac?1:0;if(0==b)return a.contentType==Ud||"application"==a.contentType?!0:!1;1!=b&&(a.Rc&&(a.Pb=null),a.ac=null);return!0}
1039
1039
  function $u(a,b,c,d){var e,f,g,h,k,l,m;return O(function(n){if(1==n.g)return e=[Cd(c)],f=Md(b(),e),g=tg(f,a.g.retryParameters),g.method=d,h=a.j.networkingEngine.request(4,g),ng(a.T,h),F(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=ud(k.data);m=Date.parse(l);return isNaN(m)?n.return(0):n.return(m-Date.now())})}
1040
- function yu(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(q){return{scheme:q.attributes.schemeIdUri,value:q.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.u(4);break}h=g.value;ra(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.u(7);case "urn:mpeg:dash:utc:http-xsdate:2014":case "urn:mpeg:dash:utc:http-iso:2014":case "urn:mpeg:dash:utc:http-xsdate:2012":case "urn:mpeg:dash:utc:http-iso:2012":return n.u(8);
1040
+ function yu(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.u(4);break}h=g.value;ra(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.u(7);case "urn:mpeg:dash:utc:http-xsdate:2014":case "urn:mpeg:dash:utc:http-iso:2014":case "urn:mpeg:dash:utc:http-xsdate:2012":case "urn:mpeg:dash:utc:http-iso:2012":return n.u(8);
1041
1041
  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.u(9);break;case 7:return F(n,$u(a,b,l,"HEAD"),10);case 10:return n.return(n.h);case 8:return F(n,$u(a,b,l,"GET"),11);case 11:return n.return(n.h);case 9:ta(n,
1042
1042
  3);break;case 5:ua(n);case 3:g=f.next();n.u(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)}})}
1043
1043
  function Fu(a,b,c,d,e){var f=d.attributes.schemeIdUri||"",g=d.attributes.value||"",h=oh(d,"timescale",wh)||1;d=t(hh(d,"Event"));for(var k=d.next();!k.done;k=d.next()){k=k.value;var l=oh(k,"presentationTime",wh)||0,m=oh(k,"duration",wh)||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:Eh(k),eventNode:k},a.j.onTimelineRegionAdded(k))}}
@@ -1050,28 +1050,28 @@ c.splice(f,c.length-f);c=[];d=[];f=[];h=null;g=t(g);for(var k=g.next();!k.done;k
1050
1050
  g.name&&(g.attributes.push(new kv("URI",h)),d=!0)}}return new ev(b,e)}function uv(a,b){a=a.g++;var c=b.match(/^#(EXT[^:]*)(?::(.*))?$/);if(!c)throw new T(2,4,4016,b);b=c[1];var d=c[2];c=[];var e;if(d){d=new Sp(d);var f;(f=Up(d,/^([^,=]+)(?:,|$)/g))&&(e=f[1]);for(var g=/([^=]+)=(?:"([^"]*)"|([^",]*))(?:,|$)/g;f=Up(d,g);)c.push(new kv(f[1],f[2]||f[3])),Tp(d)}return new fv(a,b,c,e)}
1051
1051
  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 EXT-X-DATERANGE".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 fg({uri:a,originalUri:a,data:b.data,headers:{"content-type":b.contentType}})}catch(c){return dg(c)}}
1052
1052
  function zv(a){var b=a.split(":");if(2>b.length||"data"!=b[0])throw new T(2,1,1004,a);b=b.slice(1).join(":").split(",");if(2>b.length)throw new T(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=Gd(a):e=zd(a);return{data:e,contentType:c}}S("shaka.net.DataUriPlugin",xv);xv.parse=yv;pg("data",yv);function Av(){var a=this;this.g=this.h=null;this.B=1;this.s=new Map;this.G=new Map;this.N=new Map;this.N.set("video",new Map);this.N.set("audio",new Map);this.N.set(Ud,new Map);this.N.set("image",new Map);this.ub=new Set;this.i=new Map;this.l=null;this.L="";this.Fa=new sv;this.H=-1;this.fa=Infinity;this.ea=this.Gb=!1;this.A=new Sc(function(){if(a.ba&&!a.g.continueLoadingWhenPaused&&(a.Y.jb(a.ba,"timeupdate"),a.ba.paused)){a.Y.ja(a.ba,"timeupdate",function(){return Bv(a)});return}Bv(a)});this.xa=Cv;
1053
- this.m=null;this.ab=0;this.o=Infinity;this.Da=this.za=this.T=0;this.da=new mg;this.C=new Map;this.F=new Map;this.ra=new Map;this.la=new Map;this.K=new Map;this.qa=new Map;this.ya=new Map;this.Fb=this.I=!1;this.Db=new Sa(5);this.j=null;this.O=!0;this.Ea=new Set;this.Y=new gb;this.ba=null}r=Av.prototype;r.configure=function(a){this.g=a;this.j&&this.j.configure(this.g)};
1054
- r.start=function(a,b){var c=this,d;return O(function(e){return 1==e.g?(c.h=b,c.I=b.isLowLatencyMode(),F(e,Dv(c,[a]),2)):3!=e.g?(d=e.h,c.L=d.uri,F(e,Ev(c,d.data,a),3)):e.return(c.m)})};
1055
- r.stop=function(){this.A&&(this.A.stop(),this.A=null);var a=[];this.da&&(a.push(this.da.destroy()),this.da=null);this.g=this.h=null;this.ub.clear();this.m=null;this.i.clear();this.G.clear();this.F.clear();this.s.clear();this.ra.clear();this.la.clear();this.K.clear();this.qa.clear();this.ya.clear();this.Ea.clear();this.j&&this.j.destroy();this.Y&&(this.Y.release(),this.Y=null);return Promise.all(a)};
1056
- r.update=function(){var a=this,b,c,d,e,f,g,h,k,l,m,n,q;return O(function(p){if(1==p.g){if(!Fv(a))return p.return();b=[];c=Array.from(a.i.values());a.o=Infinity;a.m.gapCount=0;d=c.filter(function(w){return w.stream.segmentIndex});e=t(d);for(f=e.next();!f.done;f=e.next())g=f.value,b.push(Gv(a,g));return F(p,Promise.all(b),2)}Hv(a,d.map(function(w){return w.stream}));h=d.some(function(w){return 0==w.dd});d.length&&!h&&(k=Iv,Jv(a,k.sh),l=d.map(function(w){return w.Jb}),a.l.Za(Math.min.apply(Math,x(l))),
1057
- a.h.updateDuration());h&&Kv(a);m=t(d);for(n=m.next();!n.done;n=m.next())q=n.value,q.stream.segmentIndex&&!q.stream.segmentIndex.P[0]&&a.h.disableStream(q.stream);H(p)})};function Lv(a,b){return Fv(a)?a.N.get(b.type):b.Wd}
1058
- function Gv(a,b){var c,d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L,K,I,J,N,M,P,R,Q,X,W,ya;return O(function(xa){switch(xa.g){case 1:c=[];d=t(b.M());for(e=d.next();!e.done;e=d.next())f=e.value,g=new tc(f),h=g.g,b.Cd&&(0<=b.ob&&h.add("_HLS_msn",String(b.ob)),0<=b.pb&&h.add("_HLS_part",String(b.pb))),b.Dd&&h.add("_HLS_skip","YES"),Ic(h)&&xc(g,h),c.push(g.toString());ra(xa,2);return F(xa,Dv(a,c,!0),4);case 4:k=xa.h;ta(xa,3);break;case 2:throw l=ua(xa),a.h&&a.h.disableStream(b.stream),l;case 3:if(!b.stream.segmentIndex)return xa.return();
1059
- m=tv(a.Fa,k.data);if(1!=m.type)throw new T(2,4,4017);n=k.uri;n==k.originalUri||b.M().includes(n)||b.Tg.push(n);q=lv(m.g,"EXT-X-DEFINE");p=Mv(a,q,n);w=b.stream;u=Lv(a,b);return F(xa,Nv(a,m,w.mimeType,b.M,p),5);case 5:v=xa.h;A=v.keyIds;z=v.drmInfos;D=function(Ba,Ga){return Ba.size===Ga.size&&[].concat(x(Ba)).every(function(bb){return Ga.has(bb)})};D(w.keyIds,A)||(w.keyIds=A,w.drmInfos=z,a.h.newDrmInfo(w));y=Ov(a,m,u,p,b.M,b.type);B=y.segments;if(C=y.bandwidth)w.bandwidth=C;E=tl(w);G=t(B);for(L=G.next();!L.done;L=
1060
- G.next())K=L.value,K.$&&(K.$.Hc=E);w.segmentIndex.pd(B,a.l.mb());B.length&&(I=ov(m.g,"EXT-X-MEDIA-SEQUENCE",0),N=(J=nv(m.g,"EXT-X-SKIP"))?Number(Z(J,"SKIPPED-SEGMENTS")):0,M=Pv(I,B),P=M.ob,R=M.pb,b.ob=P+N,b.pb=R,Q=u.get(I),w.segmentIndex.La(Q));if(X=w.segmentIndex.P[0]||null)b.oc=X.startTime,W=B[B.length-1],b.Jb=W.endTime;if(ya=nv(m.g,"EXT-X-ENDLIST"))b.dd=!0;Qv(a,m);Rv(a,m.g,w.type,p,b.M);H(xa)}})}r.onExpirationUpdated=function(){};r.onInitialVariantChosen=function(){};
1061
- r.banLocation=function(a){this.j&&this.j.banLocation(a)};r.setMediaElement=function(a){this.ba=a};
1053
+ this.m=null;this.ab=0;this.o=Infinity;this.Da=this.za=this.T=0;this.da=new mg;this.C=new Map;this.F=new Map;this.ra=new Map;this.la=new Map;this.K=new Map;this.qa=new Map;this.ya=new Map;this.Fb=this.I=!1;this.Db=new Sa(5);this.j=null;this.O=!0;this.Ea=new Set;this.Y=new gb;this.ba=null}q=Av.prototype;q.configure=function(a){this.g=a;this.j&&this.j.configure(this.g)};
1054
+ q.start=function(a,b){var c=this,d;return O(function(e){return 1==e.g?(c.h=b,c.I=b.isLowLatencyMode(),F(e,Dv(c,[a]),2)):3!=e.g?(d=e.h,c.L=d.uri,F(e,Ev(c,d.data,a),3)):e.return(c.m)})};
1055
+ q.stop=function(){this.A&&(this.A.stop(),this.A=null);var a=[];this.da&&(a.push(this.da.destroy()),this.da=null);this.g=this.h=null;this.ub.clear();this.m=null;this.i.clear();this.G.clear();this.F.clear();this.s.clear();this.ra.clear();this.la.clear();this.K.clear();this.qa.clear();this.ya.clear();this.Ea.clear();this.j&&this.j.destroy();this.Y&&(this.Y.release(),this.Y=null);return Promise.all(a)};
1056
+ q.update=function(){var a=this,b,c,d,e,f,g,h,k,l,m,n,p;return O(function(r){if(1==r.g){if(!Fv(a))return r.return();b=[];c=Array.from(a.i.values());a.o=Infinity;a.m.gapCount=0;d=c.filter(function(u){return u.stream.segmentIndex});e=t(d);for(f=e.next();!f.done;f=e.next())g=f.value,b.push(Gv(a,g));return F(r,Promise.all(b),2)}Hv(a,d.map(function(u){return u.stream}));h=d.some(function(u){return 0==u.ed});d.length&&!h&&(k=Iv,Jv(a,k.sh),l=d.map(function(u){return u.Jb}),a.l.Za(Math.min.apply(Math,x(l))),
1057
+ a.h.updateDuration());h&&Kv(a);m=t(d);for(n=m.next();!n.done;n=m.next())p=n.value,p.stream.segmentIndex&&!p.stream.segmentIndex.P[0]&&a.h.disableStream(p.stream);H(r)})};function Lv(a,b){return Fv(a)?a.N.get(b.type):b.Wd}
1058
+ function Gv(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L,K,I,J,M,N,P,R,Q,X,W,ya;return O(function(xa){switch(xa.g){case 1:c=[];d=t(b.M());for(e=d.next();!e.done;e=d.next())f=e.value,g=new tc(f),h=g.g,b.Cd&&(0<=b.ob&&h.add("_HLS_msn",String(b.ob)),0<=b.pb&&h.add("_HLS_part",String(b.pb))),b.Dd&&h.add("_HLS_skip","YES"),Ic(h)&&xc(g,h),c.push(g.toString());ra(xa,2);return F(xa,Dv(a,c,!0),4);case 4:k=xa.h;ta(xa,3);break;case 2:throw l=ua(xa),a.h&&a.h.disableStream(b.stream),l;case 3:if(!b.stream.segmentIndex)return xa.return();
1059
+ m=tv(a.Fa,k.data);if(1!=m.type)throw new T(2,4,4017);n=k.uri;n==k.originalUri||b.M().includes(n)||b.Tg.push(n);p=lv(m.g,"EXT-X-DEFINE");r=Mv(a,p,n);u=b.stream;v=Lv(a,b);return F(xa,Nv(a,m,u.mimeType,b.M,r),5);case 5:w=xa.h;A=w.keyIds;z=w.drmInfos;D=function(Ba,Ga){return Ba.size===Ga.size&&[].concat(x(Ba)).every(function(bb){return Ga.has(bb)})};D(u.keyIds,A)||(u.keyIds=A,u.drmInfos=z,a.h.newDrmInfo(u));y=Ov(a,m,v,r,b.M,b.type);B=y.segments;if(C=y.bandwidth)u.bandwidth=C;E=tl(u);G=t(B);for(L=G.next();!L.done;L=
1060
+ G.next())K=L.value,K.$&&(K.$.Ic=E);u.segmentIndex.pd(B,a.l.mb());B.length&&(I=ov(m.g,"EXT-X-MEDIA-SEQUENCE",0),M=(J=nv(m.g,"EXT-X-SKIP"))?Number(Z(J,"SKIPPED-SEGMENTS")):0,N=Pv(I,B),P=N.ob,R=N.pb,b.ob=P+M,b.pb=R,Q=v.get(I),u.segmentIndex.La(Q));if(X=u.segmentIndex.P[0]||null)b.oc=X.startTime,W=B[B.length-1],b.Jb=W.endTime;if(ya=nv(m.g,"EXT-X-ENDLIST"))b.ed=!0;Qv(a,m);Rv(a,m.g,u.type,r,b.M);H(xa)}})}q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(){};
1061
+ q.banLocation=function(a){this.j&&this.j.banLocation(a)};q.setMediaElement=function(a){this.ba=a};
1062
1062
  function Sv(a,b){for(var c=-1==a.H,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.P[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.H=Math.max(a.H,k));e.Qe=k;break}}}}if(!(0>a.H))for(b=t(b),c=b.next();!c.done;c=b.next())if(c=c.value,Tv(a,c.type)&&(d=c.stream.segmentIndex))if(e=a.H-c.Qe,0<e&&(d.P.splice(0,e),d=d.P[0]||null))d=-d.startTime,c.stream.segmentIndex.offset(d),Uv(a,
1063
1063
  c,d)}
1064
1064
  function Vv(a,b){if(Infinity==a.fa){b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value.stream.segmentIndex.P[0]||null,null!=c&&null!=c.h&&(a.fa=Math.min(a.fa,c.h))}b=a.fa;if(Infinity!=b){c=t(a.i.values());for(var d=c.next();!d.done;d=c.next())if(d=d.value,!Tv(a,d.type)){var e=d.stream.segmentIndex;if(null!=e){var f=e.P[0]||null;if(f)if(null==f.h)Xa("Missing EXT-X-PROGRAM-DATE-TIME for stream",d.M(),"Expect AV sync issues!");else for(Uv(a,d,f.h-b-f.startTime),d=t(e),e=d.next();!e.done;e=d.next())e.value.Vf(b)}}}}
1065
1065
  function Uv(a,b,c){b.oc+=c;b.Jb+=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.M()}
1066
- function Ev(a,b,c){var d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L,K,I,J,N,M,P,R,Q,X;return O(function(W){switch(W.g){case 1:d=Wd;e=tv(a.Fa,b);f=lv(e.g,"EXT-X-DEFINE");g=[];h=[];k=[];a.l=new sk(null,0);a.l.tc(!0);l=function(){return[c]};m=null;n=new Map;if(1==e.type)return a.O=!1,D=lv(e.g,"EXT-X-DEFINE"),n=Mv(a,D,a.L),m=d.ha,y="",B=new Map,F(W,Wv(a,a.B++,n,e,l,"",m,y,!0,"Media Playlist",null,B,null,!1,null,!1),7);Xv(a,f);q=lv(e.g,"EXT-X-MEDIA");p=lv(e.g,"EXT-X-STREAM-INF");w=lv(e.g,"EXT-X-IMAGE-STREAM-INF");
1067
- u=lv(e.g,"EXT-X-I-FRAME-STREAM-INF");v=lv(e.g,"EXT-X-SESSION-KEY");A=lv(e.g,"EXT-X-SESSION-DATA");z=lv(e.g,"EXT-X-CONTENT-STEERING");Yv(a,A);return F(W,Zv(a,z),4);case 4:return $v(a,p),aw(a,q),F(W,bw(a,p,v,q,l,a.s),5);case 5:return g=W.h,h=cw(a,q),F(W,dw(a,w,u),6);case 6:k=W.h;W.u(3);break;case 7:C=W.h,a.i.set(c,C),C.stream&&(E=tl(C.stream),C.stream.segmentIndex.Hb(function(ya){ya.$&&(ya.$.Hc=E)})),m=C.stream.type,g.push({id:0,language:De(y||"und"),disabledUntilTime:0,primary:!0,audio:"audio"==m?
1066
+ function Ev(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L,K,I,J,M,N,P,R,Q,X;return O(function(W){switch(W.g){case 1:d=Wd;e=tv(a.Fa,b);f=lv(e.g,"EXT-X-DEFINE");g=[];h=[];k=[];a.l=new sk(null,0);a.l.tc(!0);l=function(){return[c]};m=null;n=new Map;if(1==e.type)return a.O=!1,D=lv(e.g,"EXT-X-DEFINE"),n=Mv(a,D,a.L),m=d.ha,y="",B=new Map,F(W,Wv(a,a.B++,n,e,l,"",m,y,!0,"Media Playlist",null,B,null,!1,null,!1),7);Xv(a,f);p=lv(e.g,"EXT-X-MEDIA");r=lv(e.g,"EXT-X-STREAM-INF");u=lv(e.g,"EXT-X-IMAGE-STREAM-INF");
1067
+ v=lv(e.g,"EXT-X-I-FRAME-STREAM-INF");w=lv(e.g,"EXT-X-SESSION-KEY");A=lv(e.g,"EXT-X-SESSION-DATA");z=lv(e.g,"EXT-X-CONTENT-STEERING");Yv(a,A);return F(W,Zv(a,z),4);case 4:return $v(a,r),aw(a,p),F(W,bw(a,r,w,p,l,a.s),5);case 5:return g=W.h,h=cw(a,p),F(W,dw(a,u,v),6);case 6:k=W.h;W.u(3);break;case 7:C=W.h,a.i.set(c,C),C.stream&&(E=tl(C.stream),C.stream.segmentIndex.Hb(function(ya){ya.$&&(ya.$.Ic=E)})),m=C.stream.type,g.push({id:0,language:De(y||"und"),disabledUntilTime:0,primary:!0,audio:"audio"==m?
1068
1068
  C.stream:null,video:"video"==m?C.stream:null,bandwidth:C.stream.bandwidth||0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});case 3:if(!a.h)throw new T(2,7,7001);1==e.type&&(Fv(a)&&(ew(a,e),G=a.o,a.A.Z(G)),L=Array.from(a.i.values()),fw(a,L),Kv(a),Rv(a,e.g,m,n,l));a.m={presentationTimeline:a.l,variants:g,textStreams:h,imageStreams:k,offlineSessionIds:[],minBufferTime:0,sequenceMode:a.g.hls.sequenceMode,ignoreManifestTimestampsInSegmentsMode:a.g.hls.ignoreManifestTimestampsInSegmentsMode,
1069
- type:"HLS",serviceDescription:null,nextUrl:null,periodCount:1,gapCount:0,isLowLatency:!1};if(a.ea||!a.g.hls.disableCodecGuessing){W.u(8);break}K=[];I=t(a.m.variants);for(J=I.next();!J.done;J=I.next())N=J.value,N.audio&&""===N.audio.codecs&&K.push(N.audio.createSegmentIndex()),N.video&&""===N.video.codecs&&K.push(N.video.createSegmentIndex());return F(W,Promise.all(K),8);case 8:a.h.makeTextStreamsForClosedCaptions(a.m);if(1==g.length){M=[];P=g[0];R=t([P.video,P.audio]);for(Q=R.next();!Q.done;Q=R.next())(X=
1070
- Q.value)&&!X.segmentIndex&&M.push(X.createSegmentIndex());if(0<M.length)return F(W,Promise.all(M),0)}W.u(0)}})}
1071
- function gw(a,b){var c,d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G;return O(function(L){switch(L.g){case 1:c=ul(a.g.hls.mediaPlaylistFullMimeType);if(!b.length)return L.return(c);d=hw(a,b);e=d.segment;f=d.segmentIndex;g=e.M();h=g[0];k=new tc(h);l=k.Pa.split(".").pop();if(m=iw[l])return L.return(ul(m));n=zg;p=q=null;w=e.$;if(!w){L.u(2);break}u=Al(w.M(),w.Xb(),w.Ub(),a.g.retryParameters);return F(L,jw(a,u,n,{type:0}),3);case 3:v=L.h;q=v.data;if(!w.aesKey){L.u(4);break}return F(L,zl(q,w.aesKey,0),5);
1072
- case 5:q=L.h;case 4:(p=v.headers["content-type"])&&(p=p.split(";")[0].toLowerCase());case 2:return A=Al(e.M(),e.Xb(),e.Ub(),a.g.retryParameters),F(L,jw(a,A,n,{type:1}),6);case 6:z=L.h;D=z.data;if(!e.aesKey){L.u(7);break}return F(L,zl(D,e.aesKey,f),8);case 8:D=L.h;case 7:(y=z.headers["content-type"])&&(y=y.split(";")[0].toLowerCase());B="mp4 mp4a m4s m4i m4a m4f cmfa mp4v m4v cmfv fmp4".split(" ");C=["audio/mp4","video/mp4","video/iso.segment"];if(Gj(zb(D))){var K=D;var I=zb(K);I=(new sj).parse(I);
1073
- var J=I.Zc();I=I.jf();var N=[],M=!1,P=!1;switch(J.audio){case "aac":case "aac-loas":N.push("mp4a.40.2");M=!0;break;case "mp3":N.push("mp4a.40.34");M=!0;break;case "ac3":N.push("ac-3");M=!0;break;case "ec3":N.push("ec-3");M=!0;break;case "opus":N.push("opus"),M=!0}switch(J.video){case "avc":I.codec?N.push(I.codec):N.push("avc1.42E01E");P=!0;break;case "hvc":I.codec?N.push(I.codec):N.push("hvc1.1.6.L93.90");P=!0;break;case "av1":N.push("av01.0.01M.08"),P=!0}if(N.length){J=M&&!P;M=new Map;if(P){P=new Gb("video/mp2t");
1074
- P.i(K);K=t(P.j());for(var R=K.next();!R.done;R=K.next())R=R.value,M.set(R,R);P.g()}I={type:J?"audio":"video",mimeType:"video/mp2t",codecs:N.join(", "),language:null,height:I.height,width:I.width,channelCount:null,sampleRate:null,closedCaptions:M,vd:null,colorGamut:null}}else I=null;if(E=I)return L.return(E)}else if(B.includes(l)||C.includes(y)||p&&C.includes(p))if(G=vl(q,D))return L.return(G);return y?L.return(ul(y)):p?L.return(ul(p)):L.return(c)}})}
1069
+ type:"HLS",serviceDescription:null,nextUrl:null,periodCount:1,gapCount:0,isLowLatency:!1};if(a.ea||!a.g.hls.disableCodecGuessing){W.u(8);break}K=[];I=t(a.m.variants);for(J=I.next();!J.done;J=I.next())M=J.value,M.audio&&""===M.audio.codecs&&K.push(M.audio.createSegmentIndex()),M.video&&""===M.video.codecs&&K.push(M.video.createSegmentIndex());return F(W,Promise.all(K),8);case 8:a.h.makeTextStreamsForClosedCaptions(a.m);if(1==g.length){N=[];P=g[0];R=t([P.video,P.audio]);for(Q=R.next();!Q.done;Q=R.next())(X=
1070
+ Q.value)&&!X.segmentIndex&&N.push(X.createSegmentIndex());if(0<N.length)return F(W,Promise.all(N),0)}W.u(0)}})}
1071
+ function gw(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G;return O(function(L){switch(L.g){case 1:c=ul(a.g.hls.mediaPlaylistFullMimeType);if(!b.length)return L.return(c);d=hw(a,b);e=d.segment;f=d.segmentIndex;g=e.M();h=g[0];k=new tc(h);l=k.Pa.split(".").pop();if(m=iw[l])return L.return(ul(m));n=zg;r=p=null;u=e.$;if(!u){L.u(2);break}v=Al(u.M(),u.Xb(),u.Ub(),a.g.retryParameters);return F(L,jw(a,v,n,{type:0}),3);case 3:w=L.h;p=w.data;if(!u.aesKey){L.u(4);break}return F(L,zl(p,u.aesKey,0),5);
1072
+ case 5:p=L.h;case 4:(r=w.headers["content-type"])&&(r=r.split(";")[0].toLowerCase());case 2:return A=Al(e.M(),e.Xb(),e.Ub(),a.g.retryParameters),F(L,jw(a,A,n,{type:1}),6);case 6:z=L.h;D=z.data;if(!e.aesKey){L.u(7);break}return F(L,zl(D,e.aesKey,f),8);case 8:D=L.h;case 7:(y=z.headers["content-type"])&&(y=y.split(";")[0].toLowerCase());B="mp4 mp4a m4s m4i m4a m4f cmfa mp4v m4v cmfv fmp4".split(" ");C=["audio/mp4","video/mp4","video/iso.segment"];if(Gj(zb(D))){var K=D;var I=zb(K);I=(new sj).parse(I);
1073
+ var J=I.$c();I=I.jf();var M=[],N=!1,P=!1;switch(J.audio){case "aac":case "aac-loas":M.push("mp4a.40.2");N=!0;break;case "mp3":M.push("mp4a.40.34");N=!0;break;case "ac3":M.push("ac-3");N=!0;break;case "ec3":M.push("ec-3");N=!0;break;case "opus":M.push("opus"),N=!0}switch(J.video){case "avc":I.codec?M.push(I.codec):M.push("avc1.42E01E");P=!0;break;case "hvc":I.codec?M.push(I.codec):M.push("hvc1.1.6.L93.90");P=!0;break;case "av1":M.push("av01.0.01M.08"),P=!0}if(M.length){J=N&&!P;N=new Map;if(P){P=new Gb("video/mp2t");
1074
+ P.i(K);K=t(P.j());for(var R=K.next();!R.done;R=K.next())R=R.value,N.set(R,R);P.g()}I={type:J?"audio":"video",mimeType:"video/mp2t",codecs:M.join(", "),language:null,height:I.height,width:I.width,channelCount:null,sampleRate:null,closedCaptions:N,vd:null,colorGamut:null}}else I=null;if(E=I)return L.return(E)}else if(B.includes(l)||C.includes(y)||r&&C.includes(r))if(G=vl(p,D))return L.return(G);return y?L.return(ul(y)):r?L.return(ul(r)):L.return(c)}})}
1075
1075
  function Kv(a){if(Fv(a)){if(a.xa==kw){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.Jb),c=Math.min(c,e.oc));b-=c;a.g.hls.useSafariBehaviorForLive&&(b=a.l.A);isNaN(a.g.availabilityWindowOverride)||(b=a.g.availabilityWindowOverride);a.l.oe(b)}}else a.l.Za(lw(a));if(!a.l.s)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))&&
1076
1076
  c.h&&a.l.bh(c.h);a.l.Ud()}function Xv(a,b){var c=(new tc(a.L)).g;b=t(b);for(var d=b.next();!d.done;d=b.next()){var e=d.value;d=Z(e,"NAME");var f=Z(e,"VALUE");e=Z(e,"QUERYPARAM");d&&f&&(a.s.has(d)||a.s.set(d,f));e&&(d=c.get(e)[0])&&!a.s.has(d)&&a.s.set(e,d)}}
1077
1077
  function Mv(a,b,c){c=(new tc(c)).g;var d=new Map;b=t(b);for(var e=b.next();!e.done;e=b.next()){var f=e.value,g=Z(f,"NAME"),h=Z(f,"VALUE");e=Z(f,"QUERYPARAM");f=Z(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.s.get(f))&&d.set(f,e)}return d}
@@ -1081,68 +1081,68 @@ function Zv(a,b){var c,d,e,f,g,h;return O(function(k){if(!a.h||!a.g)return k.ret
1081
1081
  function cw(a,b){var c=mv(b,"SUBTITLES");b=c.map(function(g){if(a.g.disableText)return null;try{return nw(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=iv(d.value,"GROUP-ID");if(d=a.F.get(e))if(e=a.G.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=ow(Ud,d)||pw(Ud),qw(f.stream)}}return b.filter(function(g){return g})}
1082
1082
  function qw(a){var b=new Set([Zd(a.mimeType,a.codecs)]);a.segmentIndex&&a.segmentIndex.Hb(function(c){c.mimeType&&b.add(Zd(c.mimeType,a.codecs))});a.fullMimeTypes=b}
1083
1083
  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);ra(m,2);return F(m,rw(a,g),4)}if(2!=m.g)return k=m.h,m.return(k.stream);l=ua(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=iv(g,"URI"),k=Z(g,"CODECS")||"";if(a.i.has(h))var l=a.i.get(h);else{var m=Z(g,"LANGUAGE"),n=Z(g,"NAME"),
1084
- q=Z(g,"CHARACTERISTICS"),p=sw(a,a.B++,[h],k,"image",m,!1,n,null,null,q,!1,null,!1),w=Z(g,"RESOLUTION"),u=t(w?w.split("x"):[null,null]),v=u.next().value,A=u.next().value;p.stream.width=Number(v)||void 0;p.stream.height=Number(A)||void 0;var z=Z(g,"BANDWIDTH");z&&(p.stream.bandwidth=Number(z));a.i.set(h,p);l=p}g=l;return"mjpg"!==g.stream.codecs?null:g.stream}catch(D){if(a.g.hls.ignoreImageStreamFailures)return null;throw D;}})),F(f,Promise.all(d),2);e=f.h;return f.return(e.filter(function(g){return g}))})}
1084
+ p=Z(g,"CHARACTERISTICS"),r=sw(a,a.B++,[h],k,"image",m,!1,n,null,null,p,!1,null,!1),u=Z(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=Z(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(D){if(a.g.hls.ignoreImageStreamFailures)return null;throw D;}})),F(f,Promise.all(d),2);e=f.h;return f.return(e.filter(function(g){return g}))})}
1085
1085
  function tw(a,b,c){b=b.filter(function(h){var k=Z(h,"URI")||"";return"SUBTITLES"!=Z(h,"TYPE")&&""!=k});var d={};b=t(b);for(var e=b.next();!e.done;e=b.next()){e=e.value;var f=gv(e,!a.j);d[f]?d[f].push(e):d[f]=[e]}for(var g in d)nw(a,d[g],c)}
1086
- function bw(a,b,c,d,e,f){var g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L,K,I,J,N,M,P,R,Q,X,W,ya,xa,Ba,Ga,bb;return O(function(Za){switch(Za.g){case 1:g=[];h=new Set;if(!(0<c.length)){Za.u(2);break}k=t(c);l=k.next();case 3:if(l.done){Za.u(2);break}m=l.value;n=iv(m,"METHOD");q=Z(m,"KEYFORMAT")||"identity";p=null;if("NONE"==n){Za.u(4);break}if(uw(n)){w=pv(e(),iv(m,"URI"),f);u=w.sort().join("");a.K.has(u)||(v=tg(w,a.g.retryParameters),A=jw(a,v,6),a.K.set(u,A));Za.u(4);break}if("identity"!=q){p=(z=vw[q])?
1087
- z(m,""):null;Za.u(6);break}return F(Za,ww(a,m,"",e,null,f),9);case 9:p=Za.h;case 6:if(p){if(p.keyIds)for(D=t(p.keyIds),y=D.next();!y.done;y=D.next())B=y.value,h.add(B);g.push(p)}case 4:l=k.next();Za.u(3);break;case 2:C={};E=t(b);for(G=E.next();!G.done;G=E.next())L=G.value,K=gv(L,!a.j),C[K]?C[K].push(L):C[K]=[L];I=[];for(J in C)N=C[J],M=N[0],P=Z(M,"FRAME-RATE"),R=Number(Z(M,"AVERAGE-BANDWIDTH"))||Number(iv(M,"BANDWIDTH")),Q=Z(M,"RESOLUTION"),X=t(Q?Q.split("x"):[null,null]),W=X.next().value,ya=X.next().value,
1088
- xa=Z(M,"VIDEO-RANGE"),(Ba=Z(M,"REQ-VIDEO-LAYOUT"))&&Ba.includes(",")&&(Ga=Ba.split(",").filter(function(Ta){return"CH-STEREO"==Ta||"CH-MONO"==Ta}),Ba=Ga[0]),Ba=Ba||"CH-MONO",bb=xw(a,N,d),I.push.apply(I,x(yw(a,bb.audio,bb.video,R,W,ya,P,xa,Ba,g,h)));return Za.return(I.filter(function(Ta){return null!=Ta}))}})}
1089
- function xw(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=Z(m,"AUDIO");var n=Z(m,"VIDEO"),q=l||n;q&&(f.includes(q)||f.push(q),(m=Z(m,"PATHWAY-ID"))&&e.set(q,m),l?g=!0:n&&(h=!0))}f.length&&c.length&&(k=c.filter(function(u){return f.includes(iv(u,"GROUP-ID"))}),tw(a,k,e));k=(e=f.sort().join(","))&&a.G.has(e)?a.G.get(e):[];g?d.audio.push.apply(d.audio,x(k)):h&&d.video.push.apply(d.video,x(k));l=!1;var p=b.map(function(u){return iv(u,
1090
- "URI")});h=d.audio.find(function(u){return u&&u.M().find(function(v){return p.includes(v)})});g=mw(a,b[0]);n=Sd("video",g);(q=Sd("audio",g))&&!n?(h="audio",l=0<d.audio.length):!d.audio.length&&!d.video.length&&q&&n?(h="video",g=[[n,q].join()]):d.audio.length&&h?(h="audio",l=!0):h=d.video.length&&!d.audio.length?"audio":"video";if(!l){var w=m=q=n=l=null;!k.length&&(c=c.find(function(u){var v=Z(u,"URI")||"",A=Z(u,"TYPE");u=iv(u,"GROUP-ID");return"SUBTITLES"!=A&&""==v&&f.includes(u)}))&&(l=Z(c,"LANGUAGE"),
1091
- n=Z(c,"NAME"),q=zw(c),Aw(c),m=Z(c,"CHARACTERISTICS"),w=Bw(c));a=Cw(a,b,g,h,l,n,q,m,w);e&&(a.stream.groupId=e);d[a.stream.type]=[a]}return d}
1086
+ function bw(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L,K,I,J,M,N,P,R,Q,X,W,ya,xa,Ba,Ga,bb;return O(function(Za){switch(Za.g){case 1:g=[];h=new Set;if(!(0<c.length)){Za.u(2);break}k=t(c);l=k.next();case 3:if(l.done){Za.u(2);break}m=l.value;n=iv(m,"METHOD");p=Z(m,"KEYFORMAT")||"identity";r=null;if("NONE"==n){Za.u(4);break}if(uw(n)){u=pv(e(),iv(m,"URI"),f);v=u.sort().join("");a.K.has(v)||(w=tg(u,a.g.retryParameters),A=jw(a,w,6),a.K.set(v,A));Za.u(4);break}if("identity"!=p){r=(z=vw[p])?
1087
+ z(m,""):null;Za.u(6);break}return F(Za,ww(a,m,"",e,null,f),9);case 9:r=Za.h;case 6:if(r){if(r.keyIds)for(D=t(r.keyIds),y=D.next();!y.done;y=D.next())B=y.value,h.add(B);g.push(r)}case 4:l=k.next();Za.u(3);break;case 2:C={};E=t(b);for(G=E.next();!G.done;G=E.next())L=G.value,K=gv(L,!a.j),C[K]?C[K].push(L):C[K]=[L];I=[];for(J in C)M=C[J],N=M[0],P=Z(N,"FRAME-RATE"),R=Number(Z(N,"AVERAGE-BANDWIDTH"))||Number(iv(N,"BANDWIDTH")),Q=Z(N,"RESOLUTION"),X=t(Q?Q.split("x"):[null,null]),W=X.next().value,ya=X.next().value,
1088
+ xa=Z(N,"VIDEO-RANGE"),(Ba=Z(N,"REQ-VIDEO-LAYOUT"))&&Ba.includes(",")&&(Ga=Ba.split(",").filter(function(Ta){return"CH-STEREO"==Ta||"CH-MONO"==Ta}),Ba=Ga[0]),Ba=Ba||"CH-MONO",bb=xw(a,M,d),I.push.apply(I,x(yw(a,bb.audio,bb.video,R,W,ya,P,xa,Ba,g,h)));return Za.return(I.filter(function(Ta){return null!=Ta}))}})}
1089
+ function xw(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=Z(m,"AUDIO");var n=Z(m,"VIDEO"),p=l||n;p&&(f.includes(p)||f.push(p),(m=Z(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(iv(v,"GROUP-ID"))}),tw(a,k,e));k=(e=f.sort().join(","))&&a.G.has(e)?a.G.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 iv(v,
1090
+ "URI")});h=d.audio.find(function(v){return v&&v.M().find(function(w){return r.includes(w)})});g=mw(a,b[0]);n=Sd("video",g);(p=Sd("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=Z(v,"URI")||"",A=Z(v,"TYPE");v=iv(v,"GROUP-ID");return"SUBTITLES"!=A&&""==w&&f.includes(v)}))&&(l=Z(c,"LANGUAGE"),
1091
+ n=Z(c,"NAME"),p=zw(c),Aw(c),m=Z(c,"CHARACTERISTICS"),u=Bw(c));a=Cw(a,b,g,h,l,n,p,m,u);e&&(a.stream.groupId=e);d[a.stream.type]=[a]}return d}
1092
1092
  function mw(a,b){var c=Z(b,"CODECS")||"";b=Z(b,"SUPPLEMENTAL-CODECS");a.ea=0<c.length;a.ea||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 wl(a)}function zw(a){return(a=Z(a,"CHANNELS"))?parseInt(a.split("/")[0],10):null}
1093
1093
  function Bw(a){return(a=Z(a,"SAMPLE-RATE"))?parseInt(a,10):null}function Aw(a){return(a=Z(a,"CHANNELS"))?a.includes("/JOC"):!1}
1094
- function yw(a,b,c,d,e,f,g,h,k,l,m){for(var n=t(c),q=n.next();!q.done;q=n.next())Dw(q.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 p=h.value;if(h=f?f.stream:null)h.drmInfos=l,h.keyIds=m;if(k=p?p.stream:null)k.drmInfos=l,k.keyIds=m;k&&!h&&(k.bandwidth=d);!k&&h&&(h.bandwidth=d);n=f?f.stream.drmInfos:null;q=p?p.stream.drmInfos:null;
1095
- p=p?p.M().sort().join(","):"";var w=f?f.M().sort().join(","):"";p=p+" - "+w;h&&k&&!Lc(n,q)||a.ub.has(p)||(h={id:a.B++,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.ub.add(p))}return e}
1094
+ function yw(a,b,c,d,e,f,g,h,k,l,m){for(var n=t(c),p=n.next();!p.done;p=n.next())Dw(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;
1095
+ r=r?r.M().sort().join(","):"";var u=f?f.M().sort().join(","):"";r=r+" - "+u;h&&k&&!Lc(n,p)||a.ub.has(r)||(h={id:a.B++,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.ub.add(r))}return e}
1096
1096
  function aw(a,b){b=mv(b,"CLOSED-CAPTIONS");a.O=0==b.length;b=t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value,e=Z(d,"LANGUAGE");c=De(e||"und");e||(e=Z(d,"NAME"))&&(c=e);e=iv(d,"GROUP-ID");d=iv(d,"INSTREAM-ID").replace("SERVICE","svc");a.C.get(e)||a.C.set(e,new Map);a.C.get(e).set(d,c)}}
1097
1097
  function nw(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=iv(k,"URI");k=iv(k,"GROUP-ID");d.push(h);e.push(k);f.set(k,h)}g=e.sort().join(",");h=b[0];b="";k=iv(h,"TYPE").toLowerCase();"subtitles"==k&&(k=Ud);if(k==Ud)b=Z(h,"CODECS")||"";else{e=t(e);for(var l=e.next();!l.done;l=e.next())if(l=l.value,a.F.has(l)){b=a.F.get(l);break}}e=d.sort().join(",");if(a.i.has(e))return a.i.get(e);l=a.B++;if(a.j){f=t(f);for(var m=f.next();!m.done;m=f.next()){var n=t(m.value);
1098
- m=n.next().value;n=n.next().value;(m=c.get(m))&&wt(a.j,l,m,n)}}c=Z(h,"LANGUAGE");f=Z(h,"NAME");m="YES"==Z(h,"DEFAULT");n="audio"==k?zw(h):null;var q="audio"==k?Aw(h):!1,p=Z(h,"CHARACTERISTICS"),w="YES"==Z(h,"FORCED");h="audio"==k?Bw(h):null;d=sw(a,l,d,b,k,c,m,f,n,null,p,w,h,q);d.stream&&(d.stream.groupId=g);a.G.has(g)?a.G.get(g).push(d):a.G.set(g,[d]);a.i.set(e,d);return d}
1099
- function rw(a,b){var c,d,e,f,g,h,k,l,m,n;return O(function(q){if(1==q.g){c=iv(b,"URI");d=Z(b,"CODECS","jpeg")||"";if(a.i.has(c))return q.return(a.i.get(c));e=Z(b,"LANGUAGE");f=Z(b,"NAME");g=Z(b,"CHARACTERISTICS");h=sw(a,a.B++,[c],d,"image",e,!1,f,null,null,g,!1,null,!1);return(k=Z(b,"RESOLUTION"))?F(q,h.stream.createSegmentIndex(),3):q.u(2)}2!=q.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])*
1100
- Number(m.split("x")[1]));if(n=Z(b,"BANDWIDTH"))h.stream.bandwidth=Number(n);a.i.set(c,h);return q.return(h)})}
1101
- function Cw(a,b,c,d,e,f,g,h,k){for(var l=a.B++,m=[],n=t(b),q=n.next();!q.done;q=n.next()){var p=q.value;q=iv(p,"URI");p=Z(p,"PATHWAY-ID");a.j&&p&&wt(a.j,l,p,q);m.push(q)}n=m.sort().join(",");if(a.i.has(n))return a.i.get(n);a:{b=Z(b[0],"CLOSED-CAPTIONS");if("video"==d){if(a.g.disableText){a.O=!1;b=null;break a}if(b){if("NONE"!=b){b=a.C.get(b);break a}a.O=!1}else if(!b&&a.C.size)for(b=t(a.C.keys()).next();!b.done;){b=a.C.get(b.value);break a}}b=null}c=Rd(d,c);d=sw(a,l,m,c,d,e,!1,f,g,b,h,!1,k,!1);a.i.set(n,
1098
+ m=n.next().value;n=n.next().value;(m=c.get(m))&&wt(a.j,l,m,n)}}c=Z(h,"LANGUAGE");f=Z(h,"NAME");m="YES"==Z(h,"DEFAULT");n="audio"==k?zw(h):null;var p="audio"==k?Aw(h):!1,r=Z(h,"CHARACTERISTICS"),u="YES"==Z(h,"FORCED");h="audio"==k?Bw(h):null;d=sw(a,l,d,b,k,c,m,f,n,null,r,u,h,p);d.stream&&(d.stream.groupId=g);a.G.has(g)?a.G.get(g).push(d):a.G.set(g,[d]);a.i.set(e,d);return d}
1099
+ function rw(a,b){var c,d,e,f,g,h,k,l,m,n;return O(function(p){if(1==p.g){c=iv(b,"URI");d=Z(b,"CODECS","jpeg")||"";if(a.i.has(c))return p.return(a.i.get(c));e=Z(b,"LANGUAGE");f=Z(b,"NAME");g=Z(b,"CHARACTERISTICS");h=sw(a,a.B++,[c],d,"image",e,!1,f,null,null,g,!1,null,!1);return(k=Z(b,"RESOLUTION"))?F(p,h.stream.createSegmentIndex(),3):p.u(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])*
1100
+ Number(m.split("x")[1]));if(n=Z(b,"BANDWIDTH"))h.stream.bandwidth=Number(n);a.i.set(c,h);return p.return(h)})}
1101
+ function Cw(a,b,c,d,e,f,g,h,k){for(var l=a.B++,m=[],n=t(b),p=n.next();!p.done;p=n.next()){var r=p.value;p=iv(r,"URI");r=Z(r,"PATHWAY-ID");a.j&&r&&wt(a.j,l,r,p);m.push(p)}n=m.sort().join(",");if(a.i.has(n))return a.i.get(n);a:{b=Z(b[0],"CLOSED-CAPTIONS");if("video"==d){if(a.g.disableText){a.O=!1;b=null;break a}if(b){if("NONE"!=b){b=a.C.get(b);break a}a.O=!1}else if(!b&&a.C.size)for(b=t(a.C.keys()).next();!b.done;){b=a.C.get(b.value);break a}}b=null}c=Rd(d,c);d=sw(a,l,m,c,d,e,!1,f,g,b,h,!1,k,!1);a.i.set(n,
1102
1102
  d);return d}
1103
- function sw(a,b,c,d,e,f,g,h,k,l,m,n,q,p){function w(B){var C,E,G,L,K,I,J,N,M,P,R,Q,X,W,ya,xa,Ba,Ga,bb,Za,Ta,Ca,nc;return O(function(Ra){switch(Ra.g){case 1:return C=Wd,E=z.M(),ra(Ra,2),F(Ra,Dv(a,z.M(),!0),4);case 4:G=Ra.h;ta(Ra,3);break;case 2:L=ua(Ra);v.closeSegmentIndex();if(K=a.h.disableStream(v))return Ra.return();throw L;case 3:if(B.aborted)return Ra.return();I=G.uri;I==G.originalUri||E.includes(I)||A.push(I);J=tv(a.Fa,G.data);if(1!=J.type)throw new T(2,4,4017);N=lv(J.g,"EXT-X-DEFINE");M=Mv(a,
1104
- N,I);P=!1;(!a.ea&&a.g.hls.disableCodecGuessing||a.O&&e==C.ha&&!a.g.hls.disableClosedCaptionsDetection)&&0<J.segments.length&&(a.O=!1,P=!0);R=!a.ea&&a.g.hls.disableCodecGuessing;Q=Fv(a);return F(Ra,Wv(a,0,M,J,u,d,e,f,g,h,k,l,m,n,q,p,void 0,P,R),5);case 5:X=Ra.h;if(B.aborted)return Ra.return();W=X.stream;Fv(a)&&!Q&&ew(a,J);z.oc=X.oc;z.Jb=X.Jb;z.Dd=X.Dd;z.Cd=X.Cd;z.dd=X.dd;z.Wd=X.Wd;z.ob=X.ob;z.pb=X.pb;z.vf=!0;v.segmentIndex=W.segmentIndex;v.encrypted=W.encrypted;v.drmInfos=W.drmInfos;v.keyIds=W.keyIds;
1105
- v.mimeType=W.mimeType;v.bandwidth=v.bandwidth||W.bandwidth;v.codecs=v.codecs||W.codecs;v.closedCaptions=v.closedCaptions||W.closedCaptions;v.width=v.width||W.width;v.height=v.height||W.height;v.hdr=v.hdr||W.hdr;v.colorGamut=v.colorGamut||W.colorGamut;"und"==v.language&&"und"!=W.language&&(v.language=W.language);v.language=v.language||W.language;v.channelsCount=v.channelsCount||W.channelsCount;v.audioSamplingRate=v.audioSamplingRate||W.audioSamplingRate;qw(v);v.drmInfos.length&&a.h.newDrmInfo(v);ya=
1106
- !1;if(!l&&v.closedCaptions||l&&v.closedCaptions&&l.size!=v.closedCaptions.size)ya=!0;a.m&&ya&&a.h.makeTextStreamsForClosedCaptions(a.m);if(e==C.ha||e==C.X)for(xa=t(a.i.values()),Ba=xa.next();!Ba.done;Ba=xa.next())Ga=Ba.value,Ga.vf||Ga.type!=e||(Ga.stream.mimeType=W.mimeType,qw(Ga.stream));e==C.ua&&(bb=W.segmentIndex.get(0))&&bb.$&&(v.mimeType="application/mp4",qw(v));Za=tl(v);v.segmentIndex.Hb(function(lb){lb.$&&(lb.$.Hc=Za)});Ew(a)&&(a.Gb?fw(a,[z]):(a.Gb=!0,Ta=Array.from(a.i.values()),Ca=Ta.filter(function(lb){return lb.stream.segmentIndex}),
1107
- fw(a,Ca),Kv(a),nc=a.o,0<nc&&a.A.Z(nc)));Rv(a,J.g,v.type,M,u);H(Ra)}})}function u(){return a.j&&1<c.length?xt(a.j,b):A.concat(qv([a.L],c,a.s))}var v=Fw(a,d,e,f,g,h,k,l,m,n,q,p),A=[],z={stream:v,type:e,Tg:A,M:u,oc:0,Jb:0,Wd:new Map,Dd:!1,Cd:!1,dd:!1,Qe:-1,ob:-1,pb:-1,vf:!1},D=null,y=new AbortController;v.createSegmentIndex=function(){if(D)return D;y=new AbortController;return D=new Promise(function(B){B(w(y.signal))})};v.closeSegmentIndex=function(){D&&!v.segmentIndex&&y.abort();v.segmentIndex&&(v.segmentIndex.release(),
1108
- v.segmentIndex=null);D=null};return z}function lw(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.Jb));return b}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.Hb(function(e){c.push(e)});a.l.qd(c)}
1103
+ function sw(a,b,c,d,e,f,g,h,k,l,m,n,p,r){function u(B){var C,E,G,L,K,I,J,M,N,P,R,Q,X,W,ya,xa,Ba,Ga,bb,Za,Ta,Ca,nc;return O(function(Ra){switch(Ra.g){case 1:return C=Wd,E=z.M(),ra(Ra,2),F(Ra,Dv(a,z.M(),!0),4);case 4:G=Ra.h;ta(Ra,3);break;case 2:L=ua(Ra);w.closeSegmentIndex();if(K=a.h.disableStream(w))return Ra.return();throw L;case 3:if(B.aborted)return Ra.return();I=G.uri;I==G.originalUri||E.includes(I)||A.push(I);J=tv(a.Fa,G.data);if(1!=J.type)throw new T(2,4,4017);M=lv(J.g,"EXT-X-DEFINE");N=Mv(a,
1104
+ M,I);P=!1;(!a.ea&&a.g.hls.disableCodecGuessing||a.O&&e==C.ha&&!a.g.hls.disableClosedCaptionsDetection)&&0<J.segments.length&&(a.O=!1,P=!0);R=!a.ea&&a.g.hls.disableCodecGuessing;Q=Fv(a);return F(Ra,Wv(a,0,N,J,v,d,e,f,g,h,k,l,m,n,p,r,void 0,P,R),5);case 5:X=Ra.h;if(B.aborted)return Ra.return();W=X.stream;Fv(a)&&!Q&&ew(a,J);z.oc=X.oc;z.Jb=X.Jb;z.Dd=X.Dd;z.Cd=X.Cd;z.ed=X.ed;z.Wd=X.Wd;z.ob=X.ob;z.pb=X.pb;z.vf=!0;w.segmentIndex=W.segmentIndex;w.encrypted=W.encrypted;w.drmInfos=W.drmInfos;w.keyIds=W.keyIds;
1105
+ w.mimeType=W.mimeType;w.bandwidth=w.bandwidth||W.bandwidth;w.codecs=w.codecs||W.codecs;w.closedCaptions=w.closedCaptions||W.closedCaptions;w.width=w.width||W.width;w.height=w.height||W.height;w.hdr=w.hdr||W.hdr;w.colorGamut=w.colorGamut||W.colorGamut;"und"==w.language&&"und"!=W.language&&(w.language=W.language);w.language=w.language||W.language;w.channelsCount=w.channelsCount||W.channelsCount;w.audioSamplingRate=w.audioSamplingRate||W.audioSamplingRate;qw(w);w.drmInfos.length&&a.h.newDrmInfo(w);ya=
1106
+ !1;if(!l&&w.closedCaptions||l&&w.closedCaptions&&l.size!=w.closedCaptions.size)ya=!0;a.m&&ya&&a.h.makeTextStreamsForClosedCaptions(a.m);if(e==C.ha||e==C.X)for(xa=t(a.i.values()),Ba=xa.next();!Ba.done;Ba=xa.next())Ga=Ba.value,Ga.vf||Ga.type!=e||(Ga.stream.mimeType=W.mimeType,qw(Ga.stream));e==C.ua&&(bb=W.segmentIndex.get(0))&&bb.$&&(w.mimeType="application/mp4",qw(w));Za=tl(w);w.segmentIndex.Hb(function(lb){lb.$&&(lb.$.Ic=Za)});Ew(a)&&(a.Gb?fw(a,[z]):(a.Gb=!0,Ta=Array.from(a.i.values()),Ca=Ta.filter(function(lb){return lb.stream.segmentIndex}),
1107
+ fw(a,Ca),Kv(a),nc=a.o,0<nc&&a.A.Z(nc)));Rv(a,J.g,w.type,N,v);H(Ra)}})}function v(){return a.j&&1<c.length?xt(a.j,b):A.concat(qv([a.L],c,a.s))}var w=Fw(a,d,e,f,g,h,k,l,m,n,p,r),A=[],z={stream:w,type:e,Tg:A,M:v,oc:0,Jb:0,Wd:new Map,Dd:!1,Cd:!1,ed:!1,Qe:-1,ob:-1,pb:-1,vf:!1},D=null,y=new AbortController;w.createSegmentIndex=function(){if(D)return D;y=new AbortController;return D=new Promise(function(B){B(u(y.signal))})};w.closeSegmentIndex=function(){D&&!w.segmentIndex&&y.abort();w.segmentIndex&&(w.segmentIndex.release(),
1108
+ w.segmentIndex=null);D=null};return z}function lw(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.Jb));return b}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.Hb(function(e){c.push(e)});a.l.qd(c)}
1109
1109
  function fw(a,b){if(!Fv(a))for(var c=lw(a),d=t(b),e=d.next();!e.done;e=d.next())e.value.stream.segmentIndex.Cc(0,c);Hv(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))}function Tv(a,b){return a.g.hls.ignoreManifestProgramDateTime?!0:a.g.hls.ignoreManifestProgramDateTimeForTypes.includes(b)}
1110
1110
  function Ew(a){if(!a.m)return!1;var b=[],c=[];a=t(a.m.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}
1111
- function Wv(a,b,c,d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z){A=void 0===A?!0:A;z=void 0===z?!0:z;var D,y,B,C,E,G,L,K,I,J,N,M,P,R,Q,X,W,ya,xa,Ba,Ga,bb,Za,Ta,Ca,nc;return O(function(Ra){switch(Ra.g){case 1:var lb=nv(d.g,"EXT-X-PLAYLIST-TYPE"),Rb=nv(d.g,"EXT-X-ENDLIST");Rb=lb&&"VOD"==lb.value||Rb;lb=lb&&"EVENT"==lb.value&&!Rb;lb=!Rb&&!lb;Rb?Jv(a,Cv):lb?Jv(a,kw):Jv(a,Gw);Fv(a)&&Qv(a,d);D=Fv(a)?a.N.get(g):new Map;y=Ov(a,d,D,c,e,g);B=y.segments;C=y.bandwidth;K=L=G=E=null;if(!(0<B.length&&A)){Ra.u(2);break}return F(Ra,
1112
- gw(a,B),3);case 3:I=Ra.h,g=I.type,h=I.language,m=I.channelCount,w=I.sampleRate,a.g.disableText||(n=I.closedCaptions),G=I.height,E=I.width,L=I.vd,K=I.colorGamut,z&&(v=I.mimeType,f=I.codecs);case 2:if(v){Ra.u(4);break}return F(Ra,Hw(a,g,f,B),5);case 5:v=Ra.h;case 4:return F(Ra,Nv(a,d,v,e,c),6);case 6:J=Ra.h;N=J.drmInfos;M=J.keyIds;P=J.encrypted;R=J.wh;if(P&&!N.length&&!R)throw new T(2,4,4026);Q=Fw(a,f,g,h,k,l,m,n,q,p,w,u);Q.encrypted=P;Q.drmInfos=N;Q.keyIds=M;Q.mimeType=v;C&&(Q.bandwidth=C);qw(Q);"video"==
1113
- g&&(E||G||L||K)&&Dw(Q,E,G,null,L,null,K);Fv(a)&&Qv(a,d);X=B[0].startTime;W=B[B.length-1];ya=W.endTime;xa=new Ok(B);Q.segmentIndex=xa;Ga=(Ba=nv(d.g,"EXT-X-SERVER-CONTROL"))?null!=hv(Ba,"CAN-SKIP-UNTIL"):!1;bb=Ba?null!=hv(Ba,"CAN-BLOCK-RELOAD"):!1;Za=ov(d.g,"EXT-X-MEDIA-SEQUENCE",0);Ta=Pv(Za,B);Ca=Ta.ob;nc=Ta.pb;return Ra.return({stream:Q,type:g,Tg:[],M:e,oc:X,Jb:ya,Dd:Ga,Cd:bb,dd:!1,Qe:-1,ob:Ca,pb:nc,Wd:D,vf:!1})}})}
1111
+ function Wv(a,b,c,d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z){A=void 0===A?!0:A;z=void 0===z?!0:z;var D,y,B,C,E,G,L,K,I,J,M,N,P,R,Q,X,W,ya,xa,Ba,Ga,bb,Za,Ta,Ca,nc;return O(function(Ra){switch(Ra.g){case 1:var lb=nv(d.g,"EXT-X-PLAYLIST-TYPE"),Rb=nv(d.g,"EXT-X-ENDLIST");Rb=lb&&"VOD"==lb.value||Rb;lb=lb&&"EVENT"==lb.value&&!Rb;lb=!Rb&&!lb;Rb?Jv(a,Cv):lb?Jv(a,kw):Jv(a,Gw);Fv(a)&&Qv(a,d);D=Fv(a)?a.N.get(g):new Map;y=Ov(a,d,D,c,e,g);B=y.segments;C=y.bandwidth;K=L=G=E=null;if(!(0<B.length&&A)){Ra.u(2);break}return F(Ra,
1112
+ gw(a,B),3);case 3:I=Ra.h,g=I.type,h=I.language,m=I.channelCount,u=I.sampleRate,a.g.disableText||(n=I.closedCaptions),G=I.height,E=I.width,L=I.vd,K=I.colorGamut,z&&(w=I.mimeType,f=I.codecs);case 2:if(w){Ra.u(4);break}return F(Ra,Hw(a,g,f,B),5);case 5:w=Ra.h;case 4:return F(Ra,Nv(a,d,w,e,c),6);case 6:J=Ra.h;M=J.drmInfos;N=J.keyIds;P=J.encrypted;R=J.wh;if(P&&!M.length&&!R)throw new T(2,4,4026);Q=Fw(a,f,g,h,k,l,m,n,p,r,u,v);Q.encrypted=P;Q.drmInfos=M;Q.keyIds=N;Q.mimeType=w;C&&(Q.bandwidth=C);qw(Q);"video"==
1113
+ g&&(E||G||L||K)&&Dw(Q,E,G,null,L,null,K);Fv(a)&&Qv(a,d);X=B[0].startTime;W=B[B.length-1];ya=W.endTime;xa=new Ok(B);Q.segmentIndex=xa;Ga=(Ba=nv(d.g,"EXT-X-SERVER-CONTROL"))?null!=hv(Ba,"CAN-SKIP-UNTIL"):!1;bb=Ba?null!=hv(Ba,"CAN-BLOCK-RELOAD"):!1;Za=ov(d.g,"EXT-X-MEDIA-SEQUENCE",0);Ta=Pv(Za,B);Ca=Ta.ob;nc=Ta.pb;return Ra.return({stream:Q,type:g,Tg:[],M:e,oc:X,Jb:ya,Dd:Ga,Cd:bb,ed:!1,Qe:-1,ob:Ca,pb:nc,Wd:D,vf:!1})}})}
1114
1114
  function Pv(a,b){a=a+b.length-1;var c=-1;if(!b.length)return a++,{ob:a,pb:c};b=b[b.length-1];var d=b.g;if(!b.g.length)return a++,b.m&&(c=0),{ob:a,pb:c};c=d.length-1;d[d.length-1].preload||(a++,c=0);return{ob:a,pb:c}}
1115
- function Fw(a,b,c,d,e,f,g,h,k,l,m,n){var q=ow(c,b)||pw(c),p=[];if(k){k=t(k.split(","));for(var w=k.next();!w.done;w=k.next())p.push(w.value)}k=void 0;w=null;c==Ud?k=p.includes("public.accessibility.transcribes-spoken-dialog")&&p.includes("public.accessibility.describes-music-and-sound")?"caption":"subtitle":p.includes("public.accessibility.describes-video")&&(w="visually impaired");p.length||"subtitle"!==k||p.push("subtitle");a={id:a.B++,originalId:f,groupId:null,createSegmentIndex:function(){return Promise.resolve()},
1116
- segmentIndex:null,mimeType:q,codecs:b,kind:c==Ud?"subtitle":void 0,encrypted:!1,drmInfos:[],keyIds:new Set,language:De(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:p,forced:l,channelsCount:g,audioSamplingRate:m,spatialAudio:n,closedCaptions:h,hdr:void 0,colorGamut:void 0,videoLayout:void 0,tilesLayout:void 0,accessibilityPurpose:w,external:!1,fastSwitching:!1,
1115
+ function Fw(a,b,c,d,e,f,g,h,k,l,m,n){var p=ow(c,b)||pw(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==Ud?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.B++,originalId:f,groupId:null,createSegmentIndex:function(){return Promise.resolve()},
1116
+ segmentIndex:null,mimeType:p,codecs:b,kind:c==Ud?"subtitle":void 0,encrypted:!1,drmInfos:[],keyIds:new Set,language:De(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,
1117
1117
  fullMimeTypes:new Set};qw(a);return a}
1118
- function Nv(a,b,c,d,e){var f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L,K,I,J,N,M,P,R;return O(function(Q){switch(Q.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=lv(k.g,"EXT-X-KEY"),m=null,l.length)for(m=Iw(a,b,k.g,d,e),n=t(l),q=n.next();!q.done;q=n.next())p=q.value,f.set(p,m);u=w=!1;v=[];A=new Set;z=t(f);D=z.next();case 2:if(D.done){Q.u(4);break}y=D.value;B=t(y);C=B.next().value;E=B.next().value;G=C;L=E;K=iv(G,"METHOD");if("NONE"==K){Q.u(3);break}w=
1119
- !0;I=Z(G,"KEYFORMAT")||"identity";J=null;if(uw(K)){u=!0;Q.u(3);break}if("identity"!=I){J=(N=vw[I])?N(G,c):null;Q.u(6);break}return F(Q,ww(a,G,c,d,L,e),8);case 8:J=Q.h;case 6:if(J){if(J.keyIds)for(M=t(J.keyIds),P=M.next();!P.done;P=M.next())R=P.value,A.add(R);v.push(J)}case 3:D=z.next();Q.u(2);break;case 4:return Q.return({drmInfos:v,keyIds:A,encrypted:w,wh:u})}})}
1118
+ function Nv(a,b,c,d,e){var f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L,K,I,J,M,N,P,R;return O(function(Q){switch(Q.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=lv(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);D=z.next();case 2:if(D.done){Q.u(4);break}y=D.value;B=t(y);C=B.next().value;E=B.next().value;G=C;L=E;K=iv(G,"METHOD");if("NONE"==K){Q.u(3);break}u=
1119
+ !0;I=Z(G,"KEYFORMAT")||"identity";J=null;if(uw(K)){v=!0;Q.u(3);break}if("identity"!=I){J=(M=vw[I])?M(G,c):null;Q.u(6);break}return F(Q,ww(a,G,c,d,L,e),8);case 8:J=Q.h;case 6:if(J){if(J.keyIds)for(N=t(J.keyIds),P=N.next();!P.done;P=N.next())R=P.value,A.add(R);w.push(J)}case 3:D=z.next();Q.u(2);break;case 4:return Q.return({drmInfos:w,keyIds:A,encrypted:u,wh:v})}})}
1120
1120
  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 T(2,4,4042);var f=0,g=Z(b,"IV","");if(g){var h=Hd(g.substr(2));if(16!=h.byteLength)throw new T(2,4,4048);}else f=ov(c.g,"EXT-X-MEDIA-SEQUENCE",0);c=b.toString()+"-"+f;if(!a.la.has(c)){var k={bitsKey:128,blockCipherMode:"CBC",iv:h,firstMediaSequenceNumber:f};switch(iv(b,"METHOD")){case "AES-256":k.bitsKey=256;break;case "AES-256-CTR":k.bitsKey=
1121
- 256,k.blockCipherMode="CTR"}k.fetchKey=function(){var l,m,n,q,p,w;return O(function(u){if(1==u.g)return l=pv(d(),iv(b,"URI"),e),m=l.sort().join(""),a.K.has(m)||(n=tg(l,a.g.retryParameters),q=jw(a,n,6),a.K.set(m,q)),F(u,a.K.get(m),2);if(3!=u.g){p=u.h;if(!p.data||p.data.byteLength!=k.bitsKey/8)throw new T(2,4,4049);w={name:"CTR"==k.blockCipherMode?"AES-CTR":"AES-CBC",length:k.bitsKey};return F(u,window.crypto.subtle.importKey("raw",p.data,w,!0,["decrypt"]),3)}k.cryptoKey=u.h;k.fetchKey=void 0;H(u)})};
1121
+ 256,k.blockCipherMode="CTR"}k.fetchKey=function(){var l,m,n,p,r,u;return O(function(v){if(1==v.g)return l=pv(d(),iv(b,"URI"),e),m=l.sort().join(""),a.K.has(m)||(n=tg(l,a.g.retryParameters),p=jw(a,n,6),a.K.set(m,p)),F(v,a.K.get(m),2);if(3!=v.g){r=v.h;if(!r.data||r.data.byteLength!=k.bitsKey/8)throw new T(2,4,4049);u={name:"CTR"==k.blockCipherMode?"AES-CTR":"AES-CBC",length:k.bitsKey};return F(v,window.crypto.subtle.importKey("raw",r.data,u,!0,["decrypt"]),3)}k.cryptoKey=v.h;k.fetchKey=void 0;H(v)})};
1122
1122
  a.la.set(c,k)}return a.la.get(c)}
1123
1123
  function Qv(a,b){var c=Infinity,d=b.segments;if(d.length)for(var e=d.length-1;0<=e;){var f=nv(d[e].g,"EXTINF");if(f){c=Number(f.value.split(",")[0]);break}e--}d=nv(b.g,"EXT-X-TARGETDURATION");if(!d)throw new T(2,4,4024,"EXT-X-TARGETDURATION");d=Number(d.value);if(e=nv(b.g,"EXT-X-PART-INF"))a.T=Number(iv(e,"PART-TARGET"));b=nv(b.g,"EXT-X-SERVER-CONTROL");a.I&&a.T?(a.o=a.Fb?5*a.T<=c?Math.min(a.T,a.o):Math.min(c,a.o):Math.min(a.T,a.o),a.Da=b?Number(iv(b,"PART-HOLD-BACK")):0):(a.o=Math.min(c,a.o),c=b?
1124
1124
  hv(b,"HOLD-BACK"):null,a.za=c?Number(c.value):0);a.ab=Math.max(d,a.ab)}function ew(a,b){if(a.g.defaultPresentationDelay)b=a.g.defaultPresentationDelay;else if(a.Da)b=a.Da;else if(a.za)b=a.za;else{b=b.segments.length;var c=a.g.hls.liveSegmentsDelay;c>b-2&&(c=Math.max(1,b-2));b=a.ab*c}a.l.dh(0);a.l.Of(b);a.l.tc(!1)}
1125
1125
  function Iw(a,b,c,d,e){var f=nv(c,"EXT-X-MAP");if(!f)return null;var g=iv(f,"URI"),h=pv(d(),g,e);g=[h.toString(),Z(f,"BYTERANGE","")].join("-");if(!a.ra.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?uw(iv(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.ra.set(g,b)}return a.ra.get(g)}
1126
1126
  function Kw(a,b,c,d){var e=0,f=null;b=Z(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 Di(function(){return a},e,f,null,null,null,d)}
1127
- function Lw(a,b,c,d,e,f,g,h,k){function l(X){X=(new tc(X)).Pa.split(".").pop();var W=Mw[g][X];W||(W=iw[X]);return W}var m=d.g,n=nv(m,"EXTINF"),q=0,p=0,w=null;d.zb.length&&(a.m.isLowLatency=!0);var u=null;if(!a.g.hls.ignoreManifestProgramDateTime){var v=nv(m,"EXT-X-PROGRAM-DATE-TIME");v&&v.value&&(u=rh(v.value))}var A=Gi;nv(m,"EXT-X-GAP")&&(a.m.gapCount++,A=2);if(!n){if(0==d.zb.length)throw new T(2,4,4024,"EXTINF");if(!a.I)return null}var z=[];v=!1;var D=null,y=!1,B=!1;if(a.I&&d.zb.length){q=b&&window.ReadableStream&&
1128
- a.g.hls.allowLowLatencyByteRangeOptimization;for(var C=u,E={},G=0;G<d.zb.length;E={we:void 0,fe:void 0},G++){var L=d.zb[G],K=0==G?c:z[z.length-1],I=0==G?e:K.endTime,J=Number(Z(L,"DURATION"))||a.T;if(J){var N=I+J,M=0,P=null;"EXT-X-PRELOAD-HINT"==L.name?(M=(M=Z(L,"BYTERANGE-START"))?Number(M):0,(K=Z(L,"BYTERANGE-LENGTH"))?P=M+Number(K)-1:M&&(P=Number.MAX_SAFE_INTEGER)):(M=Z(L,"BYTERANGE"),P=t(Nw(K,M)),M=P.next().value,P=P.next().value);E.fe=Z(L,"URI");if(E.fe){K=Gi;"YES"==Z(L,"GAP")&&(a.m.gapCount++,
1129
- K=2,y=!0);E.we=null;var R=function(X){return function(){null==X.we&&(X.we=pv(h(),X.fe,f));return X.we}}(E);q&&0<=M&&null!=P&&(D=R,v=!0);I=new Fi(I,N,R,M,P,b,0,0,Infinity,[],"",null,C,K,k);"EXT-X-PRELOAD-HINT"==L.name&&(I.wf(),B=!0);"YES"!=Z(L,"INDEPENDENT")&&0<G&&I.Vd();if(E=l(E.fe))I.mimeType=E,Ow.has(E)&&(I.$=null);z.push(I);C&&(C+=J)}}}}if(n){n=Number(n.value.split(",")[0]);if(0==n)return null;q=e+n}else if(z.length)q=z[z.length-1].endTime;else return null;v&&(y||0!=z[0].Ga?(v=!1,D=null):z=[]);
1130
- (n=nv(m,"EXT-X-BYTERANGE"))?(w=t(Nw(c,n.value)),p=w.next().value,w=w.next().value):z.length&&(p=z[0].Ga,w=z[z.length-1].ta);c="";n=null;"image"==g&&(c="1x1",m=nv(m,"EXT-X-TILES"))&&(c=iv(m,"LAYOUT"),(m=Z(m,"DURATION"))&&(n=Number(m)));var Q=null;b=new Fi(e,q,function(){if(D)return D();null==Q&&(Q=pv(h(),d.h,f));return Q||[]},p,w,b,0,0,Infinity,z,c,n,u,A,k,0<z.length&&!!d.h);if(e=l(d.h))b.mimeType=e,Ow.has(e)&&(b.$=null);v&&(a.Fb=!0,b.Ig(),B&&b.wf());return b}
1127
+ function Lw(a,b,c,d,e,f,g,h,k){function l(X){X=(new tc(X)).Pa.split(".").pop();var W=Mw[g][X];W||(W=iw[X]);return W}var m=d.g,n=nv(m,"EXTINF"),p=0,r=0,u=null;d.zb.length&&(a.m.isLowLatency=!0);var v=null;if(!a.g.hls.ignoreManifestProgramDateTime){var w=nv(m,"EXT-X-PROGRAM-DATE-TIME");w&&w.value&&(v=rh(w.value))}var A=Gi;nv(m,"EXT-X-GAP")&&(a.m.gapCount++,A=2);if(!n){if(0==d.zb.length)throw new T(2,4,4024,"EXTINF");if(!a.I)return null}var z=[];w=!1;var D=null,y=!1,B=!1;if(a.I&&d.zb.length){p=b&&window.ReadableStream&&
1128
+ a.g.hls.allowLowLatencyByteRangeOptimization;for(var C=v,E={},G=0;G<d.zb.length;E={we:void 0,fe:void 0},G++){var L=d.zb[G],K=0==G?c:z[z.length-1],I=0==G?e:K.endTime,J=Number(Z(L,"DURATION"))||a.T;if(J){var M=I+J,N=0,P=null;"EXT-X-PRELOAD-HINT"==L.name?(N=(N=Z(L,"BYTERANGE-START"))?Number(N):0,(K=Z(L,"BYTERANGE-LENGTH"))?P=N+Number(K)-1:N&&(P=Number.MAX_SAFE_INTEGER)):(N=Z(L,"BYTERANGE"),P=t(Nw(K,N)),N=P.next().value,P=P.next().value);E.fe=Z(L,"URI");if(E.fe){K=Gi;"YES"==Z(L,"GAP")&&(a.m.gapCount++,
1129
+ K=2,y=!0);E.we=null;var R=function(X){return function(){null==X.we&&(X.we=pv(h(),X.fe,f));return X.we}}(E);p&&0<=N&&null!=P&&(D=R,w=!0);I=new Fi(I,M,R,N,P,b,0,0,Infinity,[],"",null,C,K,k);"EXT-X-PRELOAD-HINT"==L.name&&(I.wf(),B=!0);"YES"!=Z(L,"INDEPENDENT")&&0<G&&I.Vd();if(E=l(E.fe))I.mimeType=E,Ow.has(E)&&(I.$=null);z.push(I);C&&(C+=J)}}}}if(n){n=Number(n.value.split(",")[0]);if(0==n)return null;p=e+n}else if(z.length)p=z[z.length-1].endTime;else return null;w&&(y||0!=z[0].Ga?(w=!1,D=null):z=[]);
1130
+ (n=nv(m,"EXT-X-BYTERANGE"))?(u=t(Nw(c,n.value)),r=u.next().value,u=u.next().value):z.length&&(r=z[0].Ga,u=z[z.length-1].ta);c="";n=null;"image"==g&&(c="1x1",m=nv(m,"EXT-X-TILES"))&&(c=iv(m,"LAYOUT"),(m=Z(m,"DURATION"))&&(n=Number(m)));var Q=null;b=new Fi(e,p,function(){if(D)return D();null==Q&&(Q=pv(h(),d.h,f));return Q||[]},r,u,b,0,0,Infinity,z,c,n,v,A,k,0<z.length&&!!d.h);if(e=l(d.h))b.mimeType=e,Ow.has(e)&&(b.$=null);w&&(a.Fb=!0,b.Ig(),B&&b.wf());return b}
1131
1131
  function Nw(a,b){var c=0,d=null;b&&(c=b.split("@"),b=Number(c[0]),c=c[1]?Number(c[1]):a.ta+1,d=c+b-1);return[c,d]}
1132
- function Rv(a,b,c,d,e){if("video"==c||"audio"==c){var f=a.l.m;if(f&&!Tv(a,c))for(b=lv(b,"EXT-X-DATERANGE"),b=b.sort(function(u,v){u=iv(u,"START-DATE");v=iv(v,"START-DATE");return u<v?-1:u>v?1:0}),c=0;c<b.length;c++){var g=b[c],h=iv(g,"ID");if(!a.Ea.has(h)){var k=iv(g,"START-DATE"),l=rh(k);if(!isNaN(l)){k=Math.max(0,l-f);var m=null,n=Z(g,"END-DATE");if(n&&(n=rh(n),!isNaN(n)&&(m=n-f,0>m)))continue;if(null==m&&(n=Z(g,"DURATION")||Z(g,"PLANNED-DURATION"))&&(n=parseFloat(n),isNaN(n)||(m=k+n),0>l-f+n))continue;
1133
- n=Z(g,"CLASS")||"com.apple.quicktime.HLS";var q="YES"==Z(g,"END-ON-NEXT");if(null==m&&q){for(q=c+1;q<b.length;q++){var p=Z(b[q],"CLASS")||"com.apple.quicktime.HLS";if(n==p&&(p=iv(b[q],"START-DATE"),p=rh(p),!isNaN(p)&&p&&p>l)){m=Math.max(0,p-f);break}}if(null==m)continue}l="ID CLASS START-DATE END-DATE DURATION END-ON-NEXT".split(" ");q=[];g=t(g.attributes);for(p=g.next();!p.done;p=g.next())if(p=p.value,!l.includes(p.name)){var w=rv(p.value,d);if("X-ASSET-URI"==p.name||"X-ASSET-LIST"==p.name)w=pv(e(),
1134
- p.value,d)[0];q.push({key:p.name,description:"",data:w,mimeType:null,pictureType:null})}if(q.length)a.h.onMetadata(n,k,m,q);a.Ea.add(h)}}}}}
1135
- function Ov(a,b,c,d,e,f){var g=b.segments,h=void 0,k=ov(b.g,"EXT-X-DISCONTINUITY-SEQUENCE",0),l=ov(b.g,"EXT-X-MEDIA-SEQUENCE",0),m=nv(b.g,"EXT-X-SKIP"),n=m?Number(Z(m,"SKIPPED-SEGMENTS")):0,q=l+n,p=0;Fv(a)&&c.has(q)&&(p=c.get(q));0===p&&a.xa==kw&&0<c.size&&!c.has(q)&&(p=a.l.mb());var w=[],u=null;m=[];for(var v=0;v<g.length;v++){var A=g[v],z=0==v?p:u.endTime;q=l+n+v;nv(A.g,"EXT-X-DISCONTINUITY")&&k++;var D=t(A.g);for(var y=D.next();!y.done;y=D.next())y=y.value,"EXT-X-KEY"==y.name&&(uw(iv(y,"METHOD"))?
1136
- h=Jw(a,y,b,e,d):h=void 0);c.set(q,z);D=Iw(a,b,A.g,e,d);!a.I&&a.h.isAutoLowLatencyMode()&&(a.h.enableLowLatencyMode(),a.I=a.h.isLowLatencyMode());if(z=Lw(a,D,u,A,z,d,f,e,h))(u=ov(A.g,"EXT-X-BITRATE"))?m.push({bitrate:u,duration:z.endTime-z.startTime}):m.length&&(u=m.pop(),u.duration+=z.endTime-z.startTime,m.push(u)),u=z,z.i=k,Tv(a,f)&&null!=a.H&&q<a.H||w.push(z)}b=void 0;m.length&&(b=m.reduce(function(B,C){return B+C.duration},0),b=Math.round(m.reduce(function(B,C){return B+C.bitrate*C.duration},0)/
1137
- b*1E3));if(m=w.some(function(B){return null!=B.h}))for(c={},d=0;d<w.length;c={Hd:void 0,Gd:void 0,yd:void 0,rc:void 0,xd:void 0},d++)if(c.rc=w[d],null==c.rc.h)for(c.Gd=0,c.Hd=d,e=function(B){return function(){var C=w[B.Hd];if(C){if(null!=C.h)return C.h+B.Gd;B.Gd-=C.endTime-C.startTime;B.Hd+=1}return null}}(c),c.xd=0,c.yd=d,g=function(B){return function(){var C=w[B.yd];if(C){C!=B.rc&&(B.xd+=C.endTime-C.startTime);if(null!=C.h)return C.h+B.xd;--B.yd}return null}}(c);null==c.rc.h;)c.rc.h=g(),null==c.rc.h&&
1138
- (c.rc.h=e());if(m)for(c=t(w),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.fa;if(m&&Infinity!=c&&!Tv(a,f))for(a=t(w),f=a.next();!f.done;f=a.next())f.value.Vf(c);return{segments:w,bandwidth:b}}
1132
+ function Rv(a,b,c,d,e){if("video"==c||"audio"==c){var f=a.l.m;if(f&&!Tv(a,c))for(b=lv(b,"EXT-X-DATERANGE"),b=b.sort(function(v,w){v=iv(v,"START-DATE");w=iv(w,"START-DATE");return v<w?-1:v>w?1:0}),c=0;c<b.length;c++){var g=b[c],h=iv(g,"ID");if(!a.Ea.has(h)){var k=iv(g,"START-DATE"),l=rh(k);if(!isNaN(l)){k=Math.max(0,l-f);var m=null,n=Z(g,"END-DATE");if(n&&(n=rh(n),!isNaN(n)&&(m=n-f,0>m)))continue;if(null==m&&(n=Z(g,"DURATION")||Z(g,"PLANNED-DURATION"))&&(n=parseFloat(n),isNaN(n)||(m=k+n),0>l-f+n))continue;
1133
+ n=Z(g,"CLASS")||"com.apple.quicktime.HLS";var p="YES"==Z(g,"END-ON-NEXT");if(null==m&&p){for(p=c+1;p<b.length;p++){var r=Z(b[p],"CLASS")||"com.apple.quicktime.HLS";if(n==r&&(r=iv(b[p],"START-DATE"),r=rh(r),!isNaN(r)&&r&&r>l)){m=Math.max(0,r-f);break}}if(null==m)continue}l="ID CLASS START-DATE END-DATE DURATION END-ON-NEXT".split(" ");p=[];g=t(g.attributes);for(r=g.next();!r.done;r=g.next())if(r=r.value,!l.includes(r.name)){var u=rv(r.value,d);if("X-ASSET-URI"==r.name||"X-ASSET-LIST"==r.name)u=pv(e(),
1134
+ r.value,d)[0];p.push({key:r.name,description:"",data:u,mimeType:null,pictureType:null})}if(p.length)a.h.onMetadata(n,k,m,p);a.Ea.add(h)}}}}}
1135
+ function Ov(a,b,c,d,e,f){var g=b.segments,h=void 0,k=ov(b.g,"EXT-X-DISCONTINUITY-SEQUENCE",0),l=ov(b.g,"EXT-X-MEDIA-SEQUENCE",0),m=nv(b.g,"EXT-X-SKIP"),n=m?Number(Z(m,"SKIPPED-SEGMENTS")):0,p=l+n,r=0;Fv(a)&&c.has(p)&&(r=c.get(p));0===r&&a.xa==kw&&0<c.size&&!c.has(p)&&(r=a.l.mb());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;nv(A.g,"EXT-X-DISCONTINUITY")&&k++;var D=t(A.g);for(var y=D.next();!y.done;y=D.next())y=y.value,"EXT-X-KEY"==y.name&&(uw(iv(y,"METHOD"))?
1136
+ h=Jw(a,y,b,e,d):h=void 0);c.set(p,z);D=Iw(a,b,A.g,e,d);!a.I&&a.h.isAutoLowLatencyMode()&&(a.h.enableLowLatencyMode(),a.I=a.h.isLowLatencyMode());if(z=Lw(a,D,v,A,z,d,f,e,h))(v=ov(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.i=k,Tv(a,f)&&null!=a.H&&p<a.H||u.push(z)}b=void 0;m.length&&(b=m.reduce(function(B,C){return B+C.duration},0),b=Math.round(m.reduce(function(B,C){return B+C.bitrate*C.duration},0)/
1137
+ b*1E3));if(m=u.some(function(B){return null!=B.h}))for(c={},d=0;d<u.length;c={Hd:void 0,Gd:void 0,yd:void 0,rc:void 0,xd:void 0},d++)if(c.rc=u[d],null==c.rc.h)for(c.Gd=0,c.Hd=d,e=function(B){return function(){var C=u[B.Hd];if(C){if(null!=C.h)return C.h+B.Gd;B.Gd-=C.endTime-C.startTime;B.Hd+=1}return null}}(c),c.xd=0,c.yd=d,g=function(B){return function(){var C=u[B.yd];if(C){C!=B.rc&&(B.xd+=C.endTime-C.startTime);if(null!=C.h)return C.h+B.xd;--B.yd}return null}}(c);null==c.rc.h;)c.rc.h=g(),null==c.rc.h&&
1138
+ (c.rc.h=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.fa;if(m&&Infinity!=c&&!Tv(a,f))for(a=t(u),f=a.next();!f.done;f=a.next())f.value.Vf(c);return{segments:u,bandwidth:b}}
1139
1139
  function ow(a,b){if(a==Ud){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"}function pw(a){return a==Ud?"text/vtt":Mw[a].mp4}function hw(a,b){a=Fv(a)?Math.trunc((b.length-1)/2):0;for(var c=b[a];2==c.Yb()&&a+1<b.length;)a++,c=b[a];return{segment:c,segmentIndex:a}}
1140
- function Hw(a,b,c,d){var e,f,g,h,k,l,m,n,q,p,w,u,v,A;return O(function(z){switch(z.g){case 1:e=zg;f=hw(a,d);g=f.segment;if(2==g.status)return z.return(pw(b));h=g.M();k=new tc(h[0]);l=k.Pa.split(".").pop();m=Mw[b];if((n=m[l])||(n=iw[l])||(n=ow(b,c)))return z.return(n);p=1;w=tg(h,a.g.retryParameters);ra(z,2);w.method="HEAD";return F(z,jw(a,w,e,{type:p}),4);case 4:u=z.h;q=u.headers["content-type"];ta(z,3);break;case 2:v=ua(z);if(!v||1002!=v.code&&1001!=v.code){z.u(3);break}w.method="GET";return F(z,
1141
- jw(a,w,e,{type:p}),6);case 6:A=z.h,q=A.headers["content-type"];case 3:return q?z.return(q.toLowerCase().split(";")[0]):z.return(pw(b))}})}function Dw(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,tg(b,a.g.retryParameters),0,{type:c?2:3})}
1140
+ 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=zg;f=hw(a,d);g=f.segment;if(2==g.status)return z.return(pw(b));h=g.M();k=new tc(h[0]);l=k.Pa.split(".").pop();m=Mw[b];if((n=m[l])||(n=iw[l])||(n=ow(b,c)))return z.return(n);r=1;u=tg(h,a.g.retryParameters);ra(z,2);u.method="HEAD";return F(z,jw(a,u,e,{type:r}),4);case 4:v=z.h;p=v.headers["content-type"];ta(z,3);break;case 2:w=ua(z);if(!w||1002!=w.code&&1001!=w.code){z.u(3);break}u.method="GET";return F(z,
1141
+ 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(pw(b))}})}function Dw(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,tg(b,a.g.retryParameters),0,{type:c?2:3})}
1142
1142
  function Bv(a){var b,c,d,e,f,g;return O(function(h){switch(h.g){case 1:if(!a.h)return h.return();ra(h,2);b=Date.now();return F(h,a.update(),4);case 4:c=Date.now();Fv(a)&&(d=(c-b)/1E3,a.Db.sample(1,d),e=a.o,f=Math.max(0,e-Ua(a.Db)),a.A.Z(f));ta(h,3);break;case 2:g=ua(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.Z(.1);case 3:if(!a.h)return h.return();a.h.onManifestUpdated();H(h)}})}
1143
1143
  function Fv(a){return a.xa!=Cv}function Jv(a,b){a.xa=b;a.l&&a.l.tc(!Fv(a));Fv(a)||a.A.stop()}function jw(a,b,c,d){if(!a.da)throw new T(2,7,7001);b=a.h.networkingEngine.request(c,b,d);ng(a.da,b);return b.promise}function uw(a){return"AES-128"==a||"AES-256"==a||"AES-256-CTR"==a}
1144
- function ww(a,b,c,d,e,f){var g,h,k,l,m,n,q,p,w,u,v,A,z,D,y;return O(function(B){switch(B.g){case 1:if("video/mp2t"==c)throw new T(2,4,4040);if(rd())throw new T(2,4,4041);g=iv(b,"METHOD");h=["SAMPLE-AES","SAMPLE-AES-CTR"];if(!h.includes(g))return B.return(null);k=pv(d(),iv(b,"URI"),f);if(k[0].startsWith("data:text/plain;base64,")){l=Id(Gd(k[0].split("data:text/plain;base64,").pop()));B.u(2);break}m=k.sort().join("");a.qa.has(m)||(n=tg(k,a.g.retryParameters),q=jw(a,n,6),a.qa.set(m,q));return F(B,a.qa.get(m),
1145
- 3);case 3:p=B.h,l=Id(p.data);case 2:w="00000000000000000000000000000000";if(!e){B.u(4);break}if(a.ya.has(e)){u=a.ya.get(e);B.u(5);break}v=Al(e.M(),e.Xb(),e.Ub(),a.g.retryParameters);A=zg;return F(B,jw(a,v,A,{type:0}),6);case 6:z=B.h,u=yl(z.data),a.ya.set(e,u);case 5:u&&(w=u);case 4:return D=new Map,D.set(w,l),y="cenc","SAMPLE-AES"==g&&(y="cbcs"),B.return(Qd(D,y))}})}S("shaka.hls.HlsParser",Av);
1144
+ function ww(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,u,v,w,A,z,D,y;return O(function(B){switch(B.g){case 1:if("video/mp2t"==c)throw new T(2,4,4040);if(rd())throw new T(2,4,4041);g=iv(b,"METHOD");h=["SAMPLE-AES","SAMPLE-AES-CTR"];if(!h.includes(g))return B.return(null);k=pv(d(),iv(b,"URI"),f);if(k[0].startsWith("data:text/plain;base64,")){l=Id(Gd(k[0].split("data:text/plain;base64,").pop()));B.u(2);break}m=k.sort().join("");a.qa.has(m)||(n=tg(k,a.g.retryParameters),p=jw(a,n,6),a.qa.set(m,p));return F(B,a.qa.get(m),
1145
+ 3);case 3:r=B.h,l=Id(r.data);case 2:u="00000000000000000000000000000000";if(!e){B.u(4);break}if(a.ya.has(e)){v=a.ya.get(e);B.u(5);break}w=Al(e.M(),e.Xb(),e.Ub(),a.g.retryParameters);A=zg;return F(B,jw(a,w,A,{type:0}),6);case 6:z=B.h,v=yl(z.data),a.ya.set(e,v);case 5:v&&(u=v);case 4:return D=new Map,D.set(u,l),y="cenc","SAMPLE-AES"==g&&(y="cbcs"),B.return(Qd(D,y))}})}S("shaka.hls.HlsParser",Av);
1146
1146
  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",
1147
1147
  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"}},Ow=new Set(["video/mp2t"].concat(x($d))),vw={"com.apple.streamingkeydelivery":function(a,b){if("video/mp2t"==b)throw new T(2,4,4040);if(rd())throw new T(2,4,4041);b=iv(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;var c="cenc";"SAMPLE-AES"==b&&(c="cbcs");return Pd("com.apple.fps",c,[{initDataType:"sinf",initData:new Uint8Array(0),
1148
1148
  keyId:null}],iv(a,"URI"))},"urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":function(a){var b=iv(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;var c="cenc";"SAMPLE-AES"==b&&(c="cbcs");b=iv(a,"URI");b=zv(b.split("?")[0]);b=zb(b.data);c=Pd("com.widevine.alpha",c,[{initDataType:"cenc",initData:b}]);if(a=Z(a,"KEYID"))c.keyIds=new Set([a.toLowerCase().substr(2)]);return c},"com.microsoft.playready":function(a){var b=iv(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;
@@ -1153,7 +1153,7 @@ function $w(a){for(var b=[],c=t(a.g),d=c.next();!d.done;d=c.next()){var e=b,f=e.
1153
1153
  case "audio":g=Xw("minf",Xw("smhd",gx),Zw,fx(g));break a}g=new Uint8Array([])}g=k("mdia",l,n,g);d=d("trak",h,g);f.call(e,d)}b=Ld.apply(Dd,x(b));f=a.g[0];c=Xw;d=f.duration*f.timescale;e=Math.floor(d/(ax+1));d=Math.floor(d%(ax+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(bx(f.timescale,4)),x(bx(e,4)),x(bx(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,
1154
1154
  255]));e=Xw("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(bx(k.value.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1])),k=Xw("trex",k),h.call(g,k);a=Ld.apply(Dd,x(d));a=Xw("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=Ld.apply(Dd,x(d))}else f=new Uint8Array([]);a=c("moov",e,b,a,f);b=new Uint8Array(Ww.byteLength+
1155
1155
  a.byteLength);b.set(Ww);b.set(a,Ww.byteLength);return b}
1156
- function fx(a){var b=Xw,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.wa.byteLength)var e=Xw("avcC",a.wa);else{e=Xw;for(var f=7,g=[],h=[],k=0,l=0,m=0,n=0;n<a.$a.length;n++){var q=hx(a.$a[n]);switch(q[0]&31){case 7:g.push(q);f+=q.length+2;break;case 8:h.push(q),f+=q.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=
1156
+ function fx(a){var b=Xw,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.wa.byteLength)var e=Xw("avcC",a.wa);else{e=Xw;for(var f=7,g=[],h=[],k=0,l=0,m=0,n=0;n<a.$a.length;n++){var p=hx(a.$a[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=
1157
1157
  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(bx(c,2)),x(bx(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=ix(a);g=new Uint8Array([]);
1158
1158
  a.encrypted&&(g=jx(a),d="encv");c=Xw(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.wa.byteLength&&(c=Xw("hvcC",a.wa)),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(bx(d,2)),x(bx(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=ix(a),g=new Uint8Array([]),a.encrypted&&(g=jx(a),e="encv"),c=Xw(e,d,
1159
1159
  c,h,g));break;case "audio":if(a.codecs.includes("mp3"))a=Xw(".mp3",kx(a));else if(a.codecs.includes("ac-3"))c=Xw("dac3",a.oa),d="ac-3",e=new Uint8Array([]),a.encrypted&&(e=jx(a),d="enca"),a=Xw(d,kx(a),c,e);else if(a.codecs.includes("ec-3"))c=Xw("dec3",a.oa),d="ec-3",e=new Uint8Array([]),a.encrypted&&(e=jx(a),d="enca"),a=Xw(d,kx(a),c,e);else if(a.codecs.includes("opus"))c=Xw("dOps",a.oa),d="Opus",e=new Uint8Array([]),a.encrypted&&(e=jx(a),d="enca"),a=Xw(d,kx(a),c,e);else{if(0<a.oa.byteLength)c=Xw("esds",
@@ -1162,65 +1162,65 @@ a=Xw(d,kx(a),c,e)}c=a}a=Xw("stsd",lx,c);return b("stbl",a,Xw("stts",mx),Xw("stsc
1162
1162
  function jx(a){var b=Xw;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(bx(d,4))));c=Xw("frma",c);d=new Uint8Array([0,0,0,0,99,101,110,99,0,1,0,0]);d=Xw("schm",d);e=Xw;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=hx(h.value)}a=new Uint8Array([0,
1163
1163
  0,0,0,0,0,1,8]);f=Xw("tenc",a,f);return b("sinf",c,d,e("schi",f))}
1164
1164
  function qx(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=Xw;var g=new Uint8Array([0,0,0,0].concat(x(bx(c.data?c.data.rb:0,4))));g=Xw("mfhd",g);var h;var k=c.data?c.data.Ya:[];var l=new Uint8Array(4+k.length);for(h=0;h<k.length;h++){var m=k[h].flags;l[h+4]=m.Va<<4|m.Xa<<2|m.Wa}k=Xw("sdtp",l);var n=k.length+92;l=Xw;h=new Uint8Array([0,0,0,58].concat(x(bx(c.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0]));h=Xw("tfhd",h);m=c.data?c.data.baseMediaDecodeTime:
1165
- 0;var q=Math.floor(m%(ax+1));m=new Uint8Array([1,0,0,0].concat(x(bx(Math.floor(m/(ax+1)),4)),x(bx(q,4))));m=Xw("tfdt",m);var p=n;n=c.data?c.data.Ya:[];q=n.length;var w=12+16*q,u=new Uint8Array(w);p+=8+w;u.set(["video"===c.type?1:0,0,15,1].concat(x(bx(q,4)),x(bx(p,4))),0);for(p=0;p<q;p++){var v=n[p];w=bx(v.duration,4);var A=bx(v.size,4),z=v.flags;v=bx(v.cb,4);u.set([].concat(x(w),x(A),[z.gb<<2|z.Va,z.Xa<<6|z.Wa<<4|z.hb,z.Ua&61440,z.Ua&15],x(v)),12+16*p)}n=Xw("trun",u);k=l("traf",h,m,n,k);f=f("moof",
1165
+ 0;var p=Math.floor(m%(ax+1));m=new Uint8Array([1,0,0,0].concat(x(bx(Math.floor(m/(ax+1)),4)),x(bx(p,4))));m=Xw("tfdt",m);var r=n;n=c.data?c.data.Ya:[];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(bx(p,4)),x(bx(r,4))),0);for(r=0;r<p;r++){var w=n[r];u=bx(w.duration,4);var A=bx(w.size,4),z=w.flags;w=bx(w.cb,4);v.set([].concat(x(u),x(A),[z.gb<<2|z.Va,z.Xa<<6|z.Wa<<4|z.hb,z.Ua&61440,z.Ua&15],x(w)),12+16*r)}n=Xw("trun",v);k=l("traf",h,m,n,k);f=f("moof",
1166
1166
  g,k);e.call(d,b,[f,rx(c)])}return Ld.apply(Dd,x(b))}function rx(a){a=(a.data?a.data.Ya:[]).map(function(b){return b.data});a=Ld.apply(Dd,x(a));return Xw("mdat",a)}function bx(a,b){var c=[];for(--b;0<=b;b--)c.push(a>>8*b&255);return c}function hx(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}
1167
1167
  function Xw(a){var b=Ia.apply(1,arguments),c=sx[a];c||(c=[a.charCodeAt(0),a.charCodeAt(1),a.charCodeAt(2),a.charCodeAt(3)],sx[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}
1168
1168
  var Vw=!1,ax=Math.pow(2,32)-1,sx={},cx=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]),dx=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]),mx=new Uint8Array([0,0,0,0,0,0,0,0]),nx=new Uint8Array([0,0,0,0,0,0,0,0]),px=new Uint8Array([0,0,0,0,0,0,0,0]),ox=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),ex=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0]),gx=new Uint8Array([0,
1169
- 0,0,0,0,0,0,0]),lx=new Uint8Array([0,0,0,0,0,0,0,1]),Ww=new Uint8Array([]),Yw=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),Zw=new Uint8Array([]);function tx(){var a=this;this.h=this.g=null;this.l=[];this.j=null;this.s=1;this.i=null;this.B=new Sa(5);this.o=new Sc(function(){ux(a)});this.A=new mg;this.m=new Map}r=tx.prototype;r.configure=function(a){this.g=a};r.start=function(a,b){var c=this;return O(function(d){if(1==d.g)return c.l=[a],c.h=b,F(d,vx(c),2);if(!c.h)throw new T(2,7,7001);return d.return(c.j)})};
1170
- function ux(a){var b;O(function(c){switch(c.g){case 1:return ra(c,2),F(c,vx(a),4);case 4:ta(c,3);break;case 2:b=ua(c),a.h&&(b.severity=1,a.h.onError(b));case 3:if(!a.h)return c.return();H(c)}})}r.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()};
1171
- r.update=function(){var a=this,b;return O(function(c){if(1==c.g)return ra(c,2),F(c,vx(a),4);if(2!=c.g)return ta(c,0);b=ua(c);if(!a.h||!b)return c.return();a.h.onError(b);H(c)})};r.onExpirationUpdated=function(){};r.onInitialVariantChosen=function(){};r.banLocation=function(){};r.setMediaElement=function(){};
1169
+ 0,0,0,0,0,0,0]),lx=new Uint8Array([0,0,0,0,0,0,0,1]),Ww=new Uint8Array([]),Yw=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),Zw=new Uint8Array([]);function tx(){var a=this;this.h=this.g=null;this.l=[];this.j=null;this.s=1;this.i=null;this.B=new Sa(5);this.o=new Sc(function(){ux(a)});this.A=new mg;this.m=new Map}q=tx.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,F(d,vx(c),2);if(!c.h)throw new T(2,7,7001);return d.return(c.j)})};
1170
+ function ux(a){var b;O(function(c){switch(c.g){case 1:return ra(c,2),F(c,vx(a),4);case 4:ta(c,3);break;case 2:b=ua(c),a.h&&(b.severity=1,a.h.onError(b));case 3:if(!a.h)return c.return();H(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()};
1171
+ q.update=function(){var a=this,b;return O(function(c){if(1==c.g)return ra(c,2),F(c,vx(a),4);if(2!=c.g)return ta(c,0);b=ua(c);if(!a.h||!b)return c.return();a.h.onError(b);H(c)})};q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(){};q.banLocation=function(){};q.setMediaElement=function(){};
1172
1172
  function vx(a){var b,c,d,e,f,g,h;return O(function(k){if(1==k.g)return b=tg(a.l,a.g.retryParameters),c=a.h.networkingEngine,d=Date.now(),e=c.request(0,b,{type:5}),ng(a.A,e),F(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){qb("manifest.mss.manifestPreprocessor configuration","Please Use manifest.mss.manifestPreprocessorTXml instead.");m=ju(m,"SmoothStreamingMedia");if(!m)throw new T(2,4,4046,
1173
- l);n(m);m=zd(m.outerHTML)}var q=$g(m,"SmoothStreamingMedia");if(!q)throw new T(2,4,4046,l);l=a.g.mss.manifestPreprocessorTXml;l!=xm&&l(q);a.i||(a.i=new sk(null,0));if(l=oh(q,"IsLive",yh,!1))throw new T(2,4,4047);a.i.tc(!l);n=oh(q,"TimeScale",wh,1E7);m=oh(q,"DVRWindowLength",wh);l&&(0===m||isNaN(m))&&(m=Infinity);var p=oh(q,"CanSeek",yh,!1);0===m&&p&&(m=Infinity);p=null;m&&0<m&&(p=m/n);l&&!isNaN(a.g.availabilityWindowOverride)&&(p=a.g.availabilityWindowOverride);null==p&&(p=Infinity);a.i.oe(p);m=oh(q,
1174
- "Duration",wh,Infinity);l||a.i.Za(m/n);l={variants:[],textStreams:[],timescale:n,duration:m/n};var w;p=hh(q,"Protection");n=a.g.mss.keySystemsBySystemId;m=[];p=t(p);for(w=p.next();!w.done;w=p.next())m=m.concat(hh(w.value,"ProtectionHeader"));if(m.length){p=[];for(w=0;w<m.length;w++){var u=m[w],v=u.attributes.SystemID.toLowerCase(),A=n[v];if(A){var z=Rw(u);if(z)a:{z=t(kh(z,"DATA"));for(var D=z.next();!D.done;D=z.next())if(D=lh(D.value,"KID")){z=Gd(ih(D));z=new Uint8Array([z[3],z[2],z[1],z[0],z[5],
1175
- z[4],z[7],z[6]].concat(x(z.slice(8))));z=Id(z);break a}z=null}else z=null;D=Gd(ih(u));v=Hd(v.replace(/-/g,""));v=[{initData:Zg(D,v,new Set,0),initDataType:"cenc",keyId:z}];v=Pd(A,"cenc",v);z&&v.keyIds.add(z);if(A=Tw.get(A))v.licenseServerUri=A(u);p.push(v)}}n=p}else n=[];w=n;p=[];n=[];m=[];q=hh(q,"StreamIndex");q=t(q);for(u=q.next();!u.done;u=q.next()){u=u.value;A=hh(u,"QualityLevel");v=l.timescale;z=l.duration;D=hh(u,"c");for(var y=[],B=0,C=0;C<D.length;++C){var E=D[C],G=D[C+1],L=oh(E,"t",wh),K=
1176
- oh(E,"d",wh);E=oh(E,"r",uh);if(!K)break;L=null!=L?L:B;E=E||0;if(0>E)if(G){G=oh(G,"t",wh);if(null==G)break;else if(L>=G)break;E=Math.ceil((G-L)/K)-1}else{if(Infinity==z)break;else if(L/v>=z)break;E=Math.ceil((z*v-L)/K)-1}for(G=0;G<=E;++G)B=L+K,y.push({start:L/v,end:B/v,$f:L}),L=B}v=y;A=t(A);for(z=A.next();!z.done;z=A.next())(z=wx(a,u,z.value,v,w,l))&&("audio"!=z.type||a.g.disableAudio?"video"!=z.type||a.g.disableVideo?z.type!=Ud||a.g.disableText||m.push(z):n.push(z):p.push(z))}q=[];p=t(0<p.length?
1177
- p:[null]);for(w=p.next();!w.done;w=p.next())for(w=w.value,u=t(0<n.length?n:[null]),y=u.next();!y.done;y=u.next())A=q,v=A.push,z=a,D=w,y=y.value,C=0,D&&D.bandwidth&&0<D.bandwidth&&(C+=D.bandwidth),y&&y.bandwidth&&0<y.bandwidth&&(C+=y.bandwidth),z={id:z.s++,language:D?D.language:"und",disabledUntilTime:0,primary:!!D&&D.primary||!!y&&y.primary,audio:D,video:y,bandwidth:C,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},v.call(A,z);l.variants=q;l.textStreams=m;a.j?(a.j.variants=l.variants,
1173
+ l);n(m);m=zd(m.outerHTML)}var p=$g(m,"SmoothStreamingMedia");if(!p)throw new T(2,4,4046,l);l=a.g.mss.manifestPreprocessorTXml;l!=xm&&l(p);a.i||(a.i=new sk(null,0));if(l=oh(p,"IsLive",yh,!1))throw new T(2,4,4047);a.i.tc(!l);n=oh(p,"TimeScale",wh,1E7);m=oh(p,"DVRWindowLength",wh);l&&(0===m||isNaN(m))&&(m=Infinity);var r=oh(p,"CanSeek",yh,!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.oe(r);m=oh(p,
1174
+ "Duration",wh,Infinity);l||a.i.Za(m/n);l={variants:[],textStreams:[],timescale:n,duration:m/n};var u;r=hh(p,"Protection");n=a.g.mss.keySystemsBySystemId;m=[];r=t(r);for(u=r.next();!u.done;u=r.next())m=m.concat(hh(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=Rw(v);if(z)a:{z=t(kh(z,"DATA"));for(var D=z.next();!D.done;D=z.next())if(D=lh(D.value,"KID")){z=Gd(ih(D));z=new Uint8Array([z[3],z[2],z[1],z[0],z[5],
1175
+ z[4],z[7],z[6]].concat(x(z.slice(8))));z=Id(z);break a}z=null}else z=null;D=Gd(ih(v));w=Hd(w.replace(/-/g,""));w=[{initData:Zg(D,w,new Set,0),initDataType:"cenc",keyId:z}];w=Pd(A,"cenc",w);z&&w.keyIds.add(z);if(A=Tw.get(A))w.licenseServerUri=A(v);r.push(w)}}n=r}else n=[];u=n;r=[];n=[];m=[];p=hh(p,"StreamIndex");p=t(p);for(v=p.next();!v.done;v=p.next()){v=v.value;A=hh(v,"QualityLevel");w=l.timescale;z=l.duration;D=hh(v,"c");for(var y=[],B=0,C=0;C<D.length;++C){var E=D[C],G=D[C+1],L=oh(E,"t",wh),K=
1176
+ oh(E,"d",wh);E=oh(E,"r",uh);if(!K)break;L=null!=L?L:B;E=E||0;if(0>E)if(G){G=oh(G,"t",wh);if(null==G)break;else if(L>=G)break;E=Math.ceil((G-L)/K)-1}else{if(Infinity==z)break;else if(L/w>=z)break;E=Math.ceil((z*w-L)/K)-1}for(G=0;G<=E;++G)B=L+K,y.push({start:L/w,end:B/w,$f:L}),L=B}w=y;A=t(A);for(z=A.next();!z.done;z=A.next())(z=wx(a,v,z.value,w,u,l))&&("audio"!=z.type||a.g.disableAudio?"video"!=z.type||a.g.disableVideo?z.type!=Ud||a.g.disableText||m.push(z):n.push(z):r.push(z))}p=[];r=t(0<r.length?
1177
+ r:[null]);for(u=r.next();!u.done;u=r.next())for(u=u.value,v=t(0<n.length?n:[null]),y=v.next();!y.done;y=v.next())A=p,w=A.push,z=a,D=u,y=y.value,C=0,D&&D.bandwidth&&0<D.bandwidth&&(C+=D.bandwidth),y&&y.bandwidth&&0<y.bandwidth&&(C+=y.bandwidth),z={id:z.s++,language:D?D.language:"und",disabledUntilTime:0,primary:!!D&&D.primary||!!y&&y.primary,audio:D,video:y,bandwidth:C,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},w.call(A,z);l.variants=p;l.textStreams=m;a.j?(a.j.variants=l.variants,
1178
1178
  a.j.textStreams=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,periodCount:1,gapCount:0,isLowLatency:!1},a.i.Ud());Promise.resolve();g=Date.now();h=(g-d)/1E3;a.B.sample(1,h);H(k)})}
1179
- function wx(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.s++,l=oh(c,"Bitrate",vh),m=oh(c,"MaxWidth",vh),n=oh(c,"MaxHeight",vh),q=oh(c,"Channels",vh),p=oh(c,"SamplingRate",vh),w=f.duration;d.length&&(w=d[d.length-1].end-d[0].start);var u=a.i.getDuration();a.i.Za(Math.min(w,u));var v={id:k,originalId:b.attributes.Name||String(k),groupId:null,createSegmentIndex:function(){return Promise.resolve()},
1180
- 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:De(h||"und"),originalLanguage:h,label:"",type:"",primary:!1,trickModeVideo:null,emsgSchemeIdUris:[],roles:[],forced:!1,channelsCount:q,audioSamplingRate:p,spatialAudio:!1,closedCaptions:null,hdr:void 0,colorGamut:void 0,videoLayout:void 0,tilesLayout:void 0,
1181
- matchedStreams:[],mssPrivateData:{duration:w,timescale:f.timescale,codecPrivateData:null},accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set};if(e=b.attributes.Subtype)(e=xx[e])&&v.roles.push(e),"main"===e&&(v.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(!yx.includes(e.toUpperCase()))return Ya("Codec not supported:",
1182
- e),null;c=zx(c,g,e,v);v.mssPrivateData.codecPrivateData=c;switch(g){case "audio":if(!c)return Ya("Quality unsupported without CodecPrivateData",g),null;v.type="audio";v.mimeType="mss/audio/mp4";v.codecs=Ax(e,c);break;case "video":if(!c)return Ya("Quality unsupported without CodecPrivateData",g),null;v.type="video";v.mimeType="mss/video/mp4";v.codecs=Bx(c);break;case "text":if(v.type=Ud,v.mimeType="application/mp4","TTML"===e||"DFXP"===e)v.codecs="stpp"}v.fullMimeTypes.add(Zd(v.mimeType,v.codecs));
1183
- v.createSegmentIndex=function(){if(v.segmentIndex)return Promise.resolve();if(a.m.has(v.id))var A=a.m.get(v.id);else A=[],"video"==v.type&&(A=v.mssPrivateData.codecPrivateData.split("00000001").slice(1)),A={id:v.id,type:v.type,codecs:v.codecs,encrypted:v.encrypted,timescale:v.mssPrivateData.timescale,duration:v.mssPrivateData.duration,$a:A,oa:new Uint8Array([]),wa:new Uint8Array([]),Ba:0,Ca:0,data:null,stream:v},A=$w(new Uw([A])),a.m.set(v.id,A);A=Cx(a,new Di(function(){return[]},0,null,tl(v),v.mssPrivateData.timescale,
1184
- A),v,b,d);v.segmentIndex=new Ok(A);return Promise.resolve()};v.closeSegmentIndex=function(){v.segmentIndex&&(v.segmentIndex.release(),v.segmentIndex=null)};return v}
1179
+ function wx(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.s++,l=oh(c,"Bitrate",vh),m=oh(c,"MaxWidth",vh),n=oh(c,"MaxHeight",vh),p=oh(c,"Channels",vh),r=oh(c,"SamplingRate",vh),u=f.duration;d.length&&(u=d[d.length-1].end-d[0].start);var v=a.i.getDuration();a.i.Za(Math.min(u,v));var w={id:k,originalId:b.attributes.Name||String(k),groupId:null,createSegmentIndex:function(){return Promise.resolve()},
1180
+ 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:De(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,
1181
+ matchedStreams:[],mssPrivateData:{duration:u,timescale:f.timescale,codecPrivateData:null},accessibilityPurpose:null,external:!1,fastSwitching:!1,fullMimeTypes:new Set};if(e=b.attributes.Subtype)(e=xx[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(!yx.includes(e.toUpperCase()))return Ya("Codec not supported:",
1182
+ e),null;c=zx(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=Ax(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=Bx(c);break;case "text":if(w.type=Ud,w.mimeType="application/mp4","TTML"===e||"DFXP"===e)w.codecs="stpp"}w.fullMimeTypes.add(Zd(w.mimeType,w.codecs));
1183
+ 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,$a:A,oa:new Uint8Array([]),wa:new Uint8Array([]),Ba:0,Ca:0,data:null,stream:w},A=$w(new Uw([A])),a.m.set(w.id,A);A=Cx(a,new Di(function(){return[]},0,null,tl(w),w.mssPrivateData.timescale,
1184
+ A),w,b,d);w.segmentIndex=new Ok(A);return Promise.resolve()};w.closeSegmentIndex=function(){w.segmentIndex&&(w.segmentIndex.release(),w.segmentIndex=null)};return w}
1185
1185
  function zx(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;
1186
1186
  b=new Uint16Array(1);b[0]=(c[0]<<8)+c[1];return b[0].toString(16)}function Ax(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 Bx(a){var b=/00000001[0-9]7/.exec(a);return b.length&&a?"avc1."+a.substr(a.indexOf(b[0])+10,6):""}
1187
1187
  function Cx(a,b,c,d,e){var f=d.attributes.Url.replace("{bitrate}",String(c.bandwidth));d=[];e=t(e);for(var g=e.next(),h={};!g.done;h={qe:void 0},g=e.next())h.qe=g.value,d.push(new Fi(h.qe.start,h.qe.end,function(k){return function(){return Md(a.l,[f.replace("{start time}",String(k.qe.$f))])}}(h),0,null,b,0,0,c.mssPrivateData.duration));return d}S("shaka.mss.MssParser",tx);var yx="AAC AACL AACH AACP AVC1 H264 TTML DFXP".split(" "),xx={CAPT:"main",SUBT:"alternate",DESC:"main"};
1188
1188
  yi["application/vnd.ms-sstr+xml"]=function(){return new tx};function Dx(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=yd(b)}catch(h){}throw new T(401==c||403==c?2:1,1,1001,d,c,g,a,f,e||d);};function Ex(){}function Fx(a,b,c,d,e){var f=new Gx;Fg(b.headers).forEach(function(l,m){f.append(m,l)});var g=new Hx,h={lg:!1,mh:!1};a=Ix(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 cg(a,function(){h.lg=!0;g.abort();return Promise.resolve()});if(b=b.retryParameters.timeout){var k=new Sc(function(){h.mh=!0;g.abort()});k.Z(b/1E3);a.finally(function(){k.stop()})}return a}
1189
- function Ix(a,b,c,d,e,f,g){var h,k,l,m,n,q,p,w,u,v,A,z,D;return O(function(y){switch(y.g){case 1:return h=Jx,k=Kx,q=n=0,p=Date.now(),ra(y,2),F(y,h(a,c),4);case 4:l=y.h;f(Lx(l.headers));if("HEAD"==c.method){y.u(5);break}w=l.clone().body.getReader();v=(u=l.headers.get("Content-Length"))?parseInt(u,10):0;A=function(B){function C(){var E,G,L;return O(function(K){switch(K.g){case 1:return ra(K,2),F(K,w.read(),4);case 4:E=K.h;ta(K,3);break;case 2:return ua(K),K.return();case 3:if(E.done){K.u(5);break}n+=
1190
- E.value.byteLength;if(!g){K.u(5);break}return F(K,g(E.value),5);case 5:G=Date.now();if(100<G-p||E.done)L=E.done?0:v-n,e(G-p,n-q,L),q=n,p=G;E.done?B.close():(B.enqueue(E.value),C());H(K)}})}C()};new k({start:A});return F(y,l.arrayBuffer(),6);case 6:m=y.h;case 5:ta(y,3);break;case 2:z=ua(y);if(d.lg)throw new T(1,1,7001,a,b);if(d.mh)throw new T(1,1,1003,a,b);throw new T(1,1,1002,a,z,b);case 3:return D=Lx(l.headers),y.return(Dx(D,m,l.status,a,l.url,b))}})}
1189
+ function Ix(a,b,c,d,e,f,g){var h,k,l,m,n,p,r,u,v,w,A,z,D;return O(function(y){switch(y.g){case 1:return h=Jx,k=Kx,p=n=0,r=Date.now(),ra(y,2),F(y,h(a,c),4);case 4:l=y.h;f(Lx(l.headers));if("HEAD"==c.method){y.u(5);break}u=l.clone().body.getReader();w=(v=l.headers.get("Content-Length"))?parseInt(v,10):0;A=function(B){function C(){var E,G,L;return O(function(K){switch(K.g){case 1:return ra(K,2),F(K,u.read(),4);case 4:E=K.h;ta(K,3);break;case 2:return ua(K),K.return();case 3:if(E.done){K.u(5);break}n+=
1190
+ E.value.byteLength;if(!g){K.u(5);break}return F(K,g(E.value),5);case 5:G=Date.now();if(100<G-r||E.done)L=E.done?0:w-n,e(G-r,n-p,L),p=n,r=G;E.done?B.close():(B.enqueue(E.value),C());H(K)}})}C()};new k({start:A});return F(y,l.arrayBuffer(),6);case 6:m=y.h;case 5:ta(y,3);break;case 2:z=ua(y);if(d.lg)throw new T(1,1,7001,a,b);if(d.mh)throw new T(1,1,1003,a,b);throw new T(1,1,1002,a,z,b);case 3:return D=Lx(l.headers),y.return(Dx(D,m,l.status,a,l.url,b))}})}
1191
1191
  function Lx(a){var b={};a.forEach(function(c,d){b[d.trim()]=c});return b}function Mx(){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)}S("shaka.net.HttpFetchPlugin",Ex);Ex.isSupported=Mx;Ex.parse=Fx;var Jx=window.fetch,Hx=window.AbortController,Kx=window.ReadableStream,Gx=window.Headers;
1192
1192
  Mx()&&(pg("http",Fx,2,!0),pg("https",Fx,2,!0),pg("blob",Fx,2,!0));function Nx(){}
1193
- function Ox(a,b,c,d,e){var f=new Px,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 T(1,1,7001,a,c))};var n=!1;f.onreadystatechange=function(){if(2==f.readyState&&!n){var p=Qx(f);e(p);n=!0}};f.onload=function(p){var w=Qx(f),u=f.response;try{d(Date.now()-g,p.loaded-h,0);var v=Dx(w,u,f.status,a,f.responseURL,c);l(v)}catch(A){m(A)}};f.onerror=function(p){m(new T(1,
1194
- 1,1002,a,p,c))};f.ontimeout=function(){m(new T(1,1,1003,a,c))};f.onprogress=function(p){var w=Date.now();if(100<w-g||p.lengthComputable&&p.loaded==p.total)d(w-g,p.loaded-h,4==f.readyState?0:p.total-p.loaded),h=p.loaded,g=w};for(var q in b.headers)f.setRequestHeader(q.toLowerCase(),b.headers[q]);f.send(b.body)});return new cg(k,function(){f.abort();return Promise.resolve()})}
1193
+ function Ox(a,b,c,d,e){var f=new Px,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 T(1,1,7001,a,c))};var n=!1;f.onreadystatechange=function(){if(2==f.readyState&&!n){var r=Qx(f);e(r);n=!0}};f.onload=function(r){var u=Qx(f),v=f.response;try{d(Date.now()-g,r.loaded-h,0);var w=Dx(u,v,f.status,a,f.responseURL,c);l(w)}catch(A){m(A)}};f.onerror=function(r){m(new T(1,
1194
+ 1,1002,a,r,c))};f.ontimeout=function(){m(new T(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 cg(k,function(){f.abort();return Promise.resolve()})}
1195
1195
  function Qx(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}S("shaka.net.HttpXHRPlugin",Nx);Nx.parse=Ox;var Px=window.XMLHttpRequest;pg("http",Ox,1,!0);pg("https",Ox,1,!0);pg("blob",Ox,1,!0);function Rx(a,b,c,d){this.g=a;this.i=b;this.groupId=c;this.h=d}function Sx(a){return a.M().map(function(b){return"{"+encodeURI(b)+"}"}).join("")+":"+a.Ga+":"+a.ta}function Tx(a,b){return Al(a.g.M(),a.g.Ga,a.g.ta,b.streaming.retryParameters)};function Ux(){this.h=this.j=this.i=0;this.g=new Map;this.l=0}function Vx(a,b){a.i+=b;var c=a.l;a.l++;a.g.set(c,b);return c}Ux.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 Wx(a){var b=this;this.o=a;this.j=new Map;this.i=new Bg(function(){return Xx(b).catch(function(){})});this.h=[];this.m=function(){};this.l=function(){};this.g=new Ux}Wx.prototype.destroy=function(){return this.i.destroy()};function Yx(a,b,c){a.m=b;a.l=c}function Xx(a){var b=a.h.map(function(c){return c()});a.h=[];return Promise.all(b)}
1196
- function Zx(a,b,c,d,e,f){Cg(a.i);var g=(a.j.get(b)||Promise.resolve()).then(function(){var h,k,l,m,n,q,p;return O(function(w){if(1==w.g)return F(w,$x(a,c),2);h=w.h;if(a.i.g)throw new T(2,9,7001);if(e)for(m in k=zb(h),l=new Yg(k),l.data)n=Number(m),q=l.data[n],p=l.g[n],a.l(q,p);a.g.close(d,h.byteLength);var u=a.g;a.m(0==u.i?0:u.j/u.i,a.g.h);return w.return(f(h))})});a.j.set(b,g)}function ay(a){return O(function(b){return 1==b.g?F(b,Promise.all(a.j.values()),2):b.return(a.g.h)})}
1196
+ function Zx(a,b,c,d,e,f){Cg(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 F(u,$x(a,c),2);h=u.h;if(a.i.g)throw new T(2,9,7001);if(e)for(m in k=zb(h),l=new Yg(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 ay(a){return O(function(b){return 1==b.g?F(b,Promise.all(a.j.values()),2):b.return(a.g.h)})}
1197
1197
  function $x(a,b){var c,d,e,f;return O(function(g){if(1==g.g)return c=zg,d=a.o.request(c,b),e=function(){return d.abort()},a.h.push(e),F(g,d.promise,2);f=g.h;Nb(a.h,e);return g.return(f.data)})};function by(a,b){var c=this;this.i=a;this.h=a.objectStore(b);this.g=new bg;a.onabort=function(d){d.preventDefault();c.g.reject()};a.onerror=function(d){d.preventDefault();c.g.reject()};a.oncomplete=function(){c.g.resolve()}}by.prototype.abort=function(){var a=this;return O(function(b){if(1==b.g){try{a.i.abort()}catch(c){}ra(b,2);return F(b,a.g,4)}if(2!=b.g)return ta(b,0);ua(b);H(b)})};
1198
- function cy(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 F(g,b(f.key,f.value,f),2)}f.continue();H(g)})}})}by.prototype.store=function(){return this.h};by.prototype.promise=function(){return this.g};function dy(a){this.h=a;this.g=[]}dy.prototype.destroy=function(){return Promise.all(this.g.map(function(a){return a.abort()}))};function ey(a,b){return fy(a,b,"readwrite")}function fy(a,b,c){c=a.h.transaction([b],c);var d=new by(c,b);a.g.push(d);d.promise().then(function(){Nb(a.g,d)},function(){Nb(a.g,d)});return d};function gy(a,b,c){this.h=new dy(a);this.i=b;this.g=c}r=gy.prototype;r.destroy=function(){return this.h.destroy()};r.hasFixedKeySpace=function(){return!0};r.addSegments=function(){return hy(this.i)};r.removeSegments=function(a,b){return iy(this,this.i,a,b)};r.getSegments=function(a){var b=this,c;return O(function(d){if(1==d.g)return F(d,jy(b,b.i,a),2);c=d.h;return d.return(c.map(function(e){return b.og(e)}))})};r.addManifests=function(){return hy(this.g)};
1199
- r.updateManifest=function(){return Promise.reject(new T(2,9,9016,"Cannot modify values in "+this.g))};function ky(a,b,c){a=ey(a.h,a.g);var d=a.store();d.get(b).onsuccess=function(){d.put(c,b)};return a.promise()}r.updateManifestExpiration=function(a,b){var c=ey(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()};r.removeManifests=function(a,b){return iy(this,this.g,a,b)};
1200
- r.getManifests=function(a){var b=this,c;return O(function(d){if(1==d.g)return F(d,jy(b,b.g,a),2);c=d.h;return d.return(Promise.all(c.map(function(e){return b.Vc(e)})))})};r.getAllManifests=function(){var a=this,b,c;return O(function(d){return 1==d.g?(b=fy(a.h,a.g,"readonly"),c=new Map,F(d,cy(b,function(e,f){var g;return O(function(h){if(1==h.g)return F(h,a.Vc(f),2);g=h.h;c.set(e,g);H(h)})}),2)):3!=d.g?F(d,b.promise(),3):d.return(c)})};r.og=function(a){return a};r.Vc=function(a){return Promise.resolve(a)};
1201
- function hy(a){return Promise.reject(new T(2,9,9011,"Cannot add new value to "+a))}r.add=function(a,b){var c=this,d,e,f,g,h,k,l;return O(function(m){if(1==m.g){d=ey(c.h,a);e=d.store();f=[];g=t(b);h=g.next();for(k={};!h.done;k={Hf:void 0},h=g.next())l=h.value,k.Hf=e.add(l),k.Hf.onsuccess=function(n){return function(){f.push(n.Hf.result)}}(k);return F(m,d.promise(),2)}return m.return(f)})};
1198
+ function cy(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 F(g,b(f.key,f.value,f),2)}f.continue();H(g)})}})}by.prototype.store=function(){return this.h};by.prototype.promise=function(){return this.g};function dy(a){this.h=a;this.g=[]}dy.prototype.destroy=function(){return Promise.all(this.g.map(function(a){return a.abort()}))};function ey(a,b){return fy(a,b,"readwrite")}function fy(a,b,c){c=a.h.transaction([b],c);var d=new by(c,b);a.g.push(d);d.promise().then(function(){Nb(a.g,d)},function(){Nb(a.g,d)});return d};function gy(a,b,c){this.h=new dy(a);this.i=b;this.g=c}q=gy.prototype;q.destroy=function(){return this.h.destroy()};q.hasFixedKeySpace=function(){return!0};q.addSegments=function(){return hy(this.i)};q.removeSegments=function(a,b){return iy(this,this.i,a,b)};q.getSegments=function(a){var b=this,c;return O(function(d){if(1==d.g)return F(d,jy(b,b.i,a),2);c=d.h;return d.return(c.map(function(e){return b.og(e)}))})};q.addManifests=function(){return hy(this.g)};
1199
+ q.updateManifest=function(){return Promise.reject(new T(2,9,9016,"Cannot modify values in "+this.g))};function ky(a,b,c){a=ey(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=ey(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 iy(this,this.g,a,b)};
1200
+ q.getManifests=function(a){var b=this,c;return O(function(d){if(1==d.g)return F(d,jy(b,b.g,a),2);c=d.h;return d.return(Promise.all(c.map(function(e){return b.Wc(e)})))})};q.getAllManifests=function(){var a=this,b,c;return O(function(d){return 1==d.g?(b=fy(a.h,a.g,"readonly"),c=new Map,F(d,cy(b,function(e,f){var g;return O(function(h){if(1==h.g)return F(h,a.Wc(f),2);g=h.h;c.set(e,g);H(h)})}),2)):3!=d.g?F(d,b.promise(),3):d.return(c)})};q.og=function(a){return a};q.Wc=function(a){return Promise.resolve(a)};
1201
+ function hy(a){return Promise.reject(new T(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=ey(c.h,a);e=d.store();f=[];g=t(b);h=g.next();for(k={};!h.done;k={Hf:void 0},h=g.next())l=h.value,k.Hf=e.add(l),k.Hf.onsuccess=function(n){return function(){f.push(n.Hf.result)}}(k);return F(m,d.promise(),2)}return m.return(f)})};
1202
1202
  function iy(a,b,c,d){a=ey(a.h,b);b=a.store();c=t(c);for(var e=c.next(),f={};!e.done;f={rf:void 0},e=c.next())f.rf=e.value,b.delete(f.rf).onsuccess=function(g){return function(){return d(g.rf)}}(f);return a.promise()}
1203
1203
  function jy(a,b,c){var d,e,f,g,h,k,l;return O(function(m){if(1==m.g){d=fy(a.h,b,"readonly");e=d.store();f={};g=[];h=t(c);k=h.next();for(l={};!k.done;l={ke:void 0,Qd:void 0},k=h.next())l.Qd=k.value,l.ke=e.get(l.Qd),l.ke.onsuccess=function(n){return function(){void 0==n.ke.result&&g.push(n.Qd);f[n.Qd]=n.ke.result}}(l);return F(m,d.promise(),2)}if(g.length)throw new T(2,9,9012,"Could not find values for "+g);return m.return(c.map(function(n){return f[n]}))})};function ly(a){this.g=new dy(a)}ly.prototype.destroy=function(){return this.g.destroy()};ly.prototype.getAll=function(){var a=this,b,c;return O(function(d){return 1==d.g?(b=fy(a.g,"session-ids","readonly"),c=[],F(d,cy(b,function(e,f){c.push(f)}),2)):3!=d.g?F(d,b.promise(),3):d.return(c)})};ly.prototype.add=function(a){var b=ey(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()};
1204
1204
  ly.prototype.remove=function(a){var b=this,c;return O(function(d){return 1==d.g?(c=ey(b.g,"session-ids"),F(d,cy(c,function(e,f,g){a.includes(f.sessionId)&&g.delete()}),2)):F(d,c.promise(),0)})};function my(){this.g=new Map}my.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)};my.prototype.init=function(){var a=this;ny.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)};
1205
1205
  function oy(a){var b=null;a.g.forEach(function(c,d){c.getCells().forEach(function(e,f){e.hasFixedKeySpace()||b||(b={path:{nb:d,Ha:f},Ha:e})})});if(b)return b;throw new T(2,9,9013,"Could not find a cell that supports add-operations");}function py(a,b){a.g.forEach(function(c,d){c.getCells().forEach(function(e,f){b({nb:d,Ha:f},e)})})}
1206
1206
  function qy(a,b,c){a=a.g.get(b);if(!a)throw new T(2,9,9013,"Could not find mechanism with name "+b);b=a.getCells().get(c);if(!b)throw new T(2,9,9013,"Could not find cell with name "+c);return b}function ry(a,b){a.g.forEach(function(c){b(c.getEmeSessionCell())})}function sy(a){var b=Array.from(a.g.keys());if(!b.length)throw new T(2,9,9E3,"No supported storage mechanisms found");return a.g.get(b[0]).getEmeSessionCell()}
1207
1207
  function ty(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=ny,d.forEach(function(f){(f=f())&&b.push(f)})),F(e,Promise.all(b.map(function(f){return f.erase()})),2)):c?e.u(0):F(e,Promise.all(b.map(function(f){return f.destroy()})),0)})}function uy(a,b){ny.set(a,b)}S("shaka.offline.StorageMuxer",my);my.unregister=function(a){ny.delete(a)};my.register=uy;my.prototype.destroy=my.prototype.destroy;var ny=new Map;function vy(){gy.apply(this,arguments)}na(vy,gy);vy.prototype.updateManifestExpiration=function(a,b){var c=this,d,e,f;return O(function(g){d=ey(c.h,c.g);e=d.store();f=new bg;e.get(a).onsuccess=function(h){(h=h.target.result)?(h.expiration=b,e.put(h),f.resolve()):f.reject(new T(2,9,9012,"Could not find values for "+a))};return F(g,Promise.all([d.promise(),f]),0)})};
1208
- vy.prototype.Vc=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=wy(a.periods[c],e),b.push(f);return F(h,It(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})})};
1208
+ vy.prototype.Wc=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=wy(a.periods[c],e),b.push(f);return F(h,It(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})})};
1209
1209
  function wy(a,b){xy(a);for(var c=t(a.streams),d=c.next();!d.done;d=c.next());return a.streams.map(function(e){return yy(e,a.startTime,b)})}
1210
1210
  function yy(a,b,c){var d=a.initSegmentUri?zy(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=
1211
1211
  zy(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}}vy.prototype.og=function(a){return{data:a.data}};
1212
1212
  function zy(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 T(2,9,9004,"Could not parse uri "+a);}
1213
1213
  function xy(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){d=c++;for(var e=t(a),f=e.next();!f.done;f=e.next())f.value.variantIds.push(d)}if(!a.length&&b.length)for(d=c++,
1214
1214
  e=t(b),f=e.next();!f.done;f=e.next())f.value.variantIds.push(d);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 Ay(){gy.apply(this,arguments)}na(Ay,gy);
1215
- Ay.prototype.Vc=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(By(n,k.startTime,k.startTime+e));f=l;b.push(f)}return F(h,It(b),2)}g=h.h;return h.return({appMetadata:a.appMetadata,creationTime:0,drmInfo:a.drmInfo,duration:a.duration,expiration:null==a.expiration?
1215
+ Ay.prototype.Wc=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(By(n,k.startTime,k.startTime+e));f=l;b.push(f)}return F(h,It(b),2)}g=h.h;return h.return({appMetadata:a.appMetadata,creationTime:0,drmInfo:a.drmInfo,duration:a.duration,expiration:null==a.expiration?
1216
1216
  Infinity:a.expiration,originalManifestUri:a.originalManifestUri,sessionIds:a.sessionIds,size:a.size,streams:g,sequenceMode:!1})})};
1217
1217
  function By(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,
1218
- 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 Cy(){gy.apply(this,arguments)}na(Cy,gy);r=Cy.prototype;r.hasFixedKeySpace=function(){return!1};r.addSegments=function(a){return this.add(this.i,a)};r.addManifests=function(a){return this.add(this.g,a)};r.updateManifest=function(a,b){return ky(this,a,b)};r.Vc=function(a){null==a.expiration&&(a.expiration=Infinity);return Promise.resolve(a)};function Dy(){this.m=this.j=this.i=this.h=this.g=this.l=null}r=Dy.prototype;
1219
- r.init=function(){var a=this,b=new bg,c=!1,d=new Sc(function(){c=!0;b.reject(new T(2,9,9017))});d.Z(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 vy(f,"segment","manifest"):null;a.g=g;g=f.objectStoreNames;g=g.contains("manifest-v2")&&g.contains("segment-v2")?new Ay(f,"segment-v2","manifest-v2"):null;a.h=g;g=f.objectStoreNames;g=g.contains("manifest-v3")&&g.contains("segment-v3")?
1218
+ 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 Cy(){gy.apply(this,arguments)}na(Cy,gy);q=Cy.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 ky(this,a,b)};q.Wc=function(a){null==a.expiration&&(a.expiration=Infinity);return Promise.resolve(a)};function Dy(){this.m=this.j=this.i=this.h=this.g=this.l=null}q=Dy.prototype;
1219
+ q.init=function(){var a=this,b=new bg,c=!1,d=new Sc(function(){c=!0;b.reject(new T(2,9,9017))});d.Z(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 vy(f,"segment","manifest"):null;a.g=g;g=f.objectStoreNames;g=g.contains("manifest-v2")&&g.contains("segment-v2")?new Ay(f,"segment-v2","manifest-v2"):null;a.h=g;g=f.objectStoreNames;g=g.contains("manifest-v3")&&g.contains("segment-v3")?
1220
1220
  new Ay(f,"segment-v3","manifest-v3"):null;a.i=g;g=f.objectStoreNames;g=g.contains("manifest-v5")&&g.contains("segment-v5")?new Cy(f,"segment-v5","manifest-v5"):null;a.j=g;f=f.objectStoreNames.contains("session-ids")?new ly(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 T(2,
1221
- 9,9001,e.error)),d.stop(),f.preventDefault())};return b};r.destroy=function(){var a=this;return O(function(b){switch(b.g){case 1:if(!a.g){b.u(2);break}return F(b,a.g.destroy(),2);case 2:if(!a.h){b.u(4);break}return F(b,a.h.destroy(),4);case 4:if(!a.i){b.u(6);break}return F(b,a.i.destroy(),6);case 6:if(!a.j){b.u(8);break}return F(b,a.j.destroy(),8);case 8:if(!a.m){b.u(10);break}return F(b,a.m.destroy(),10);case 10:a.l&&a.l.close(),H(b)}})};
1222
- r.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};r.getEmeSessionCell=function(){return this.m};
1223
- r.erase=function(){var a=this;return O(function(b){switch(b.g){case 1:if(!a.g){b.u(2);break}return F(b,a.g.destroy(),2);case 2:if(!a.h){b.u(4);break}return F(b,a.h.destroy(),4);case 4:if(!a.i){b.u(6);break}return F(b,a.i.destroy(),6);case 6:if(!a.j){b.u(8);break}return F(b,a.j.destroy(),8);case 8:return a.l&&a.l.close(),F(b,Ey(),10);case 10:return a.l=null,a.g=null,a.h=null,a.i=null,a.j=null,F(b,a.init(),0)}})};
1221
+ 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.u(2);break}return F(b,a.g.destroy(),2);case 2:if(!a.h){b.u(4);break}return F(b,a.h.destroy(),4);case 4:if(!a.i){b.u(6);break}return F(b,a.i.destroy(),6);case 6:if(!a.j){b.u(8);break}return F(b,a.j.destroy(),8);case 8:if(!a.m){b.u(10);break}return F(b,a.m.destroy(),10);case 10:a.l&&a.l.close(),H(b)}})};
1222
+ 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};
1223
+ q.erase=function(){var a=this;return O(function(b){switch(b.g){case 1:if(!a.g){b.u(2);break}return F(b,a.g.destroy(),2);case 2:if(!a.h){b.u(4);break}return F(b,a.h.destroy(),4);case 4:if(!a.i){b.u(6);break}return F(b,a.i.destroy(),6);case 6:if(!a.j){b.u(8);break}return F(b,a.j.destroy(),8);case 8:return a.l&&a.l.close(),F(b,Ey(),10);case 10:return a.l=null,a.g=null,a.h=null,a.i=null,a.j=null,F(b,a.init(),0)}})};
1224
1224
  function Ey(){var a=new bg,b=window.indexedDB.deleteDatabase("shaka_offline_db");b.onblocked=function(){};b.onsuccess=function(){a.resolve()};b.onerror=function(c){a.reject(new T(2,9,9001,b.error));c.preventDefault()};return a}uy("idb",function(){return fd()||Yc()||!window.indexedDB?null:new Dy});function Fy(a,b,c,d){this.g=a;this.i=b;this.h=c;this.l=d;this.j=["offline:",a,"/",b,"/",c,"/",d].join("")}Fy.prototype.nb=function(){return this.i};Fy.prototype.Ha=function(){return this.h};Fy.prototype.key=function(){return this.l};Fy.prototype.toString=function(){return this.j};
1225
1225
  function Gy(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 Fy(b,c,d,Number(a[4])):null};function Hy(a,b){this.h=a;this.g=b}
1226
1226
  function Iy(a,b){var c=new sk(null,0);c.Za(b.duration);var d=b.streams.filter(function(l){return"audio"==l.type}),e=b.streams.filter(function(l){return"video"==l.type});d=Jy(a,d,e,c);e=b.streams.filter(function(l){return l.type==Ud}).map(function(l){return Ky(a,l,c)});var f=b.streams.filter(function(l){return"image"==l.type}).map(function(l){return Ky(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=
@@ -1229,42 +1229,42 @@ function Jy(a,b,c,d){for(var e=new Set,f=t(b),g=f.next();!g.done;g=f.next()){g=t
1229
1229
  b.next())for(g=e.value,e=Ky(a,g,d),g=t(g.variantIds),h=g.next();!h.done;h=g.next())h=f.get(h.value),h.language=e.language,h.primary=h.primary||e.primary,h.audio=e;c=t(c);for(b=c.next();!b.done;b=c.next())for(e=b.value,b=Ky(a,e,d),e=t(e.variantIds),g=e.next();!g.done;g=e.next())g=f.get(g.value),g.primary=g.primary||b.primary,g.video=b;return f}
1230
1230
  function Ky(a,b,c){var d=b.segments.map(function(e){return Ly(a,e,b)});c.qd(d);return{id:b.id,originalId:b.originalId,groupId:b.groupId,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Ok(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||
1231
1231
  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([Zd(b.mimeType,b.codecs)])}}
1232
- function Ly(a,b,c){var d=new Fy("segment",a.h,a.g,b.dataKey);a=new Fi(b.startTime,b.endTime,function(){return[d.toString()]},0,null,null!=b.initSegmentKey?My(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 My(a,b){var c=new Fy("segment",a.h,a.g,b);return new Di(function(){return[c.toString()]},0,null)};function Ny(){this.g=null}r=Ny.prototype;r.configure=function(){};
1233
- r.start=function(a,b){var c=this,d,e,f,g,h,k,l;return O(function(m){switch(m.g){case 1:d=Gy(a);c.g=d;if(null==d||"manifest"!=d.g)throw new T(2,1,9004,a);e=new my;sa(m,2);return F(m,e.init(),4);case 4:return F(m,qy(e,d.nb(),d.Ha()),5);case 5:return f=m.h,F(m,f.getManifests([d.key()]),6);case 6:return g=m.h,h=g[0],k=new Hy(d.nb(),d.Ha()),l=Iy(k,h),b.makeTextStreamsForClosedCaptions(l),m.return(l);case 2:return va(m),F(m,e.destroy(),7);case 7:wa(m,0)}})};r.stop=function(){return Promise.resolve()};
1234
- r.update=function(){};
1235
- r.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 my,ra(m,2,3),F(m,e.init(),5);case 5:return F(m,qy(e,d.nb(),d.Ha()),6);case 6:return f=m.h,F(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.u(3);break}return F(m,f.updateManifestExpiration(d.key(),b),3);case 3:return va(m),F(m,e.destroy(),10);case 10:wa(m,0);break;case 2:ua(m),m.u(3)}})};
1236
- r.onInitialVariantChosen=function(){};r.banLocation=function(){};r.setMediaElement=function(){};yi["application/x-offline-manifest"]=function(){return new Ny};function Oy(){}function Py(a){var b=Gy(a);b&&"manifest"==b.g?(a={uri:a,originalUri:a,data:new ArrayBuffer(0),headers:{"content-type":"application/x-offline-manifest"}},a=fg(a)):a=b&&"segment"==b.g?Qy(b.key(),b):dg(new T(2,1,9004,a));return a}
1237
- function Qy(a,b){var c=new my;return fg(void 0).Aa(function(){return c.init()}).Aa(function(){return qy(c,b.nb(),b.Ha())}).Aa(function(d){return d.getSegments([b.key()])}).Aa(function(d){return{uri:b,data:d[0].data,headers:{}}}).finally(function(){return c.destroy()})}S("shaka.offline.OfflineScheme",Oy);Oy.plugin=Py;pg("offline",Py);function Ry(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),q=n.next();!q.done;q=n.next()){q=q.value;for(var p=!1,w=t(m),u=w.next();!u.done;u=w.next())if(u=u.value,Sy(u.info,q)){u.sessionIds.push(q.sessionId);p=!0;break}p||m.push({info:q,sessionIds:[q.sessionId]})}e=t(m);f=e.next();case 2:if(f.done){l.u(4);break}g=f.value;h=Ty(a,b,g);return F(l,h,5);case 5:k=l.h;d=d.concat(k);f=e.next();l.u(2);break;case 4:return l.return(d)}})}
1232
+ function Ly(a,b,c){var d=new Fy("segment",a.h,a.g,b.dataKey);a=new Fi(b.startTime,b.endTime,function(){return[d.toString()]},0,null,null!=b.initSegmentKey?My(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 My(a,b){var c=new Fy("segment",a.h,a.g,b);return new Di(function(){return[c.toString()]},0,null)};function Ny(){this.g=null}q=Ny.prototype;q.configure=function(){};
1233
+ 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=Gy(a);c.g=d;if(null==d||"manifest"!=d.g)throw new T(2,1,9004,a);e=new my;sa(m,2);return F(m,e.init(),4);case 4:return F(m,qy(e,d.nb(),d.Ha()),5);case 5:return f=m.h,F(m,f.getManifests([d.key()]),6);case 6:return g=m.h,h=g[0],k=new Hy(d.nb(),d.Ha()),l=Iy(k,h),b.makeTextStreamsForClosedCaptions(l),m.return(l);case 2:return va(m),F(m,e.destroy(),7);case 7:wa(m,0)}})};q.stop=function(){return Promise.resolve()};
1234
+ q.update=function(){};
1235
+ 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 my,ra(m,2,3),F(m,e.init(),5);case 5:return F(m,qy(e,d.nb(),d.Ha()),6);case 6:return f=m.h,F(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.u(3);break}return F(m,f.updateManifestExpiration(d.key(),b),3);case 3:return va(m),F(m,e.destroy(),10);case 10:wa(m,0);break;case 2:ua(m),m.u(3)}})};
1236
+ q.onInitialVariantChosen=function(){};q.banLocation=function(){};q.setMediaElement=function(){};yi["application/x-offline-manifest"]=function(){return new Ny};function Oy(){}function Py(a){var b=Gy(a);b&&"manifest"==b.g?(a={uri:a,originalUri:a,data:new ArrayBuffer(0),headers:{"content-type":"application/x-offline-manifest"}},a=fg(a)):a=b&&"segment"==b.g?Qy(b.key(),b):dg(new T(2,1,9004,a));return a}
1237
+ function Qy(a,b){var c=new my;return fg(void 0).Aa(function(){return c.init()}).Aa(function(){return qy(c,b.nb(),b.Ha())}).Aa(function(d){return d.getSegments([b.key()])}).Aa(function(d){return{uri:b,data:d[0].data,headers:{}}}).finally(function(){return c.destroy()})}S("shaka.offline.OfflineScheme",Oy);Oy.plugin=Py;pg("offline",Py);function Ry(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,Sy(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.u(4);break}g=f.value;h=Ty(a,b,g);return F(l,h,5);case 5:k=l.h;d=d.concat(k);f=e.next();l.u(2);break;case 4:return l.return(d)}})}
1238
1238
  function Ty(a,b,c){var d,e;return O(function(f){switch(f.g){case 1:return d=new Gh({Lb:b,onError:function(){},de:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),ra(f,2),d.configure(a),F(f,Oh(d,c.info.keySystem,c.info.licenseUri,c.info.serverCertificate,c.info.audioCapabilities,c.info.videoCapabilities),4);case 4:ta(f,3);break;case 2:return ua(f),F(f,d.destroy(),5);case 5:return f.return([]);case 3:return e=[],F(f,Promise.all(c.sessionIds.map(function(g){return O(function(h){if(1==
1239
1239
  h.g)return ra(h,2),F(h,$h(d,g),4);if(2!=h.g)return e.push(g),ta(h,0);ua(h);H(h)})})),6);case 6:return F(f,d.destroy(),7);case 7:return f.return(e)}})}function Sy(a,b){function c(d,e){return d.robustness==e.robustness&&d.contentType==e.contentType}return a.keySystem==b.keySystem&&a.licenseUri==b.licenseUri&&Ob(a.audioCapabilities,b.audioCapabilities,c)&&Ob(a.videoCapabilities,b.videoCapabilities,c)};function Uy(a,b,c){var d=b.presentationTimeline.getDuration();b=Vy(b);return{offlineUri:null,originalManifestUri:a,duration:d,size:0,expiration:Infinity,tracks:b,appMetadata:c,isIncomplete:!1}}function Wy(a,b){var c=Iy(new Hy(a.nb(),a.Ha()),b),d=b.appMetadata||{};c=Vy(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}}
1240
1240
  function Vy(a){var b=[],c=uf(a.variants);c=t(c);for(var d=c.next();!d.done;d=c.next())b.push(lf(d.value));a=t(a.textStreams);for(c=a.next();!c.done;c=a.next())b.push(mf(c.value));return b};function Xy(){this.g={}}function Yy(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 Zy(a,b){a.g[b.id]=b.bandwidth||2048}function $y(a,b){a=a.g[b];null==a&&(a=0);return a};function az(a){var b=this;if(a&&a.constructor!=Y)throw new T(2,9,9008);this.g=this.h=null;a?(this.h=a.g,this.g=a.xb()):(this.h=vm(),this.g=new og);this.i=[];this.j=[];var c=!a;this.l=new Bg(function(){var d,e,f,g,h;return O(function(k){switch(k.g){case 1:return F(k,Promise.all(b.j.map(function(l){return Xx(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 F(k,Promise.all(e),3);case 3:if(!c){k.u(4);break}return F(k,b.g.destroy(),4);
1241
- case 4:b.h=null,b.g=null,H(k)}})})}function bz(){if(Tc())a:{var a=t(ny.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}r=az.prototype;r.destroy=function(){return this.l.destroy()};r.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=mm(a,b));return zm(this.h,a)};r.getConfiguration=function(){var a=vm();zm(a,this.h,vm());return a};r.xb=function(){return this.g};
1242
- r.store=function(a,b,c){var d=this,e=this.getConfiguration(),f=new Wx(this.g);this.j.push(f);b=cz(this,a,b||{},function(){var g;return O(function(h){if(1==h.g)return c?h.u(2):F(h,hn(a,d.g,e.manifest.retryParameters),3);2!=h.g&&(c=h.h);g=xi(a,c||null);return h.return(g())})},e,f);b=new cg(b,function(){return Xx(f)});b.finally(function(){Nb(d.j,f)});return dz(this,b)};
1243
- function cz(a,b,c,d,e,f){var g,h,k,l,m,n,q,p,w,u,v,A,z,D;return O(function(y){switch(y.g){case 1:return ez(),h=g=null,k=new my,n=m=l=null,ra(y,2,3),F(y,d(),5);case 5:return g=y.h,F(y,fz(a,b,g,e),6);case 6:q=y.h;gz(a);p=!q.presentationTimeline.V()&&!q.presentationTimeline.mc();if(!p)throw new T(2,9,9005,b);return F(y,a.zc(q,function(B){n=n||B},e),7);case 7:h=y.h;gz(a);if(n)throw n;return F(y,hz(q,h,e),8);case 8:return F(y,k.init(),9);case 9:return gz(a),F(y,oy(k),10);case 10:return l=y.h,gz(a),w=iz(h,
1244
- q,b,c,e,f),u=w.ui,v=w.Xf,F(y,l.Ha.addManifests([u]),11);case 11:A=y.h;gz(a);m=A[0];gz(a);if(n)throw n;return F(y,jz(a,v,m,u,f,e,l.Ha,q,h),12);case 12:return gz(a),kz(q,u,h,e),F(y,l.Ha.updateManifest(m,u),13);case 13:return gz(a),z=new Fy("manifest",l.path.nb,l.path.Ha,m),y.return(Wy(z,u));case 3:return va(y),F(y,k.destroy(),14);case 14:if(!g){y.u(15);break}return F(y,g.stop(),15);case 15:if(!h){y.u(17);break}return F(y,h.destroy(),17);case 17:wa(y,0);break;case 2:D=ua(y);if(null==m){y.u(19);break}return F(y,
1241
+ case 4:b.h=null,b.g=null,H(k)}})})}function bz(){if(Tc())a:{var a=t(ny.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=az.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.xb=function(){return this.g};
1242
+ q.store=function(a,b,c){var d=this,e=this.getConfiguration(),f=new Wx(this.g);this.j.push(f);b=cz(this,a,b||{},function(){var g;return O(function(h){if(1==h.g)return c?h.u(2):F(h,hn(a,d.g,e.manifest.retryParameters),3);2!=h.g&&(c=h.h);g=xi(a,c||null);return h.return(g())})},e,f);b=new cg(b,function(){return Xx(f)});b.finally(function(){Nb(d.j,f)});return dz(this,b)};
1243
+ function cz(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,u,v,w,A,z,D;return O(function(y){switch(y.g){case 1:return ez(),h=g=null,k=new my,n=m=l=null,ra(y,2,3),F(y,d(),5);case 5:return g=y.h,F(y,fz(a,b,g,e),6);case 6:p=y.h;gz(a);r=!p.presentationTimeline.V()&&!p.presentationTimeline.mc();if(!r)throw new T(2,9,9005,b);return F(y,a.zc(p,function(B){n=n||B},e),7);case 7:h=y.h;gz(a);if(n)throw n;return F(y,hz(p,h,e),8);case 8:return F(y,k.init(),9);case 9:return gz(a),F(y,oy(k),10);case 10:return l=y.h,gz(a),u=iz(h,
1244
+ p,b,c,e,f),v=u.ui,w=u.Xf,F(y,l.Ha.addManifests([v]),11);case 11:A=y.h;gz(a);m=A[0];gz(a);if(n)throw n;return F(y,jz(a,w,m,v,f,e,l.Ha,p,h),12);case 12:return gz(a),kz(p,v,h,e),F(y,l.Ha.updateManifest(m,v),13);case 13:return gz(a),z=new Fy("manifest",l.path.nb,l.path.Ha,m),y.return(Wy(z,v));case 3:return va(y),F(y,k.destroy(),14);case 14:if(!g){y.u(15);break}return F(y,g.stop(),15);case 15:if(!h){y.u(17);break}return F(y,h.destroy(),17);case 17:wa(y,0);break;case 2:D=ua(y);if(null==m){y.u(19);break}return F(y,
1245
1245
  lz(m),19);case 19:throw n||D;}})}
1246
- function jz(a,b,c,d,e,f,g,h,k){var l,m,n,q,p,w,u,v,A,z;return O(function(D){switch(D.g){case 1:l={};m=0;n=function(y,B){var C,E,G,L,K,I,J;return O(function(N){if(1==N.g){C=t(y);E=C.next();for(G={};!E.done;G={Bc:void 0},E=C.next())G.Bc=E.value,L=Tx(G.Bc,f),K=G.Bc.i,I=G.Bc.h,J=function(M){return function(P){var R,Q,X;return O(function(W){if(1==W.g)return F(W,g.addSegments([{data:P}]),2);R=W.h;gz(a);Q=M.Bc.g;X=Sx(Q);l[X]=R[0];m+=P.byteLength;H(W)})}}(G),Zx(e,G.Bc.groupId,L,K,I,J);return F(N,ay(e),2)}if(!B)return N.u(0);
1247
- gz(a);kz(h,d,k,f);return F(N,g.updateManifest(c,d),0)})};q=!1;ra(D,2);if(!mz(h)||!q||nz(h)){D.u(4);break}return F(D,n(b.filter(function(y){return y.h}),!0),5);case 5:return gz(a),b=b.filter(function(y){return!y.h}),p=l,w=m,l={},m=0,F(D,oz(g,c,d,p,w,function(){return gz(a)}),6);case 6:gz(a);case 4:if(q){D.u(7);break}return F(D,n(b,!1),8);case 8:return gz(a),u=l,v=m,l={},m=0,F(D,oz(g,c,d,u,v,function(){return gz(a)}),9);case 9:gz(a);case 7:ta(D,0);break;case 2:return A=ua(D),z=Object.values(l),F(D,
1246
+ function jz(a,b,c,d,e,f,g,h,k){var l,m,n,p,r,u,v,w,A,z;return O(function(D){switch(D.g){case 1:l={};m=0;n=function(y,B){var C,E,G,L,K,I,J;return O(function(M){if(1==M.g){C=t(y);E=C.next();for(G={};!E.done;G={Bc:void 0},E=C.next())G.Bc=E.value,L=Tx(G.Bc,f),K=G.Bc.i,I=G.Bc.h,J=function(N){return function(P){var R,Q,X;return O(function(W){if(1==W.g)return F(W,g.addSegments([{data:P}]),2);R=W.h;gz(a);Q=N.Bc.g;X=Sx(Q);l[X]=R[0];m+=P.byteLength;H(W)})}}(G),Zx(e,G.Bc.groupId,L,K,I,J);return F(M,ay(e),2)}if(!B)return M.u(0);
1247
+ gz(a);kz(h,d,k,f);return F(M,g.updateManifest(c,d),0)})};p=!1;ra(D,2);if(!mz(h)||!p||nz(h)){D.u(4);break}return F(D,n(b.filter(function(y){return y.h}),!0),5);case 5:return gz(a),b=b.filter(function(y){return!y.h}),r=l,u=m,l={},m=0,F(D,oz(g,c,d,r,u,function(){return gz(a)}),6);case 6:gz(a);case 4:if(p){D.u(7);break}return F(D,n(b,!1),8);case 8:return gz(a),v=l,w=m,l={},m=0,F(D,oz(g,c,d,v,w,function(){return gz(a)}),9);case 9:gz(a);case 7:ta(D,0);break;case 2:return A=ua(D),z=Object.values(l),F(D,
1248
1248
  g.removeSegments(z,function(){}),10);case 10:throw A;}})}function lz(a){var b,c,d,e;return O(function(f){switch(f.g){case 1:return b=new my,F(f,b.init(),2);case 2:return F(f,oy(b),3);case 3:return c=f.h,d=new Fy("manifest",c.path.nb,c.path.Ha,a),F(f,b.destroy(),4);case 4:return e=new az,F(f,e.remove(d.toString()),0)}})}
1249
- function oz(a,b,c,d,e,f){var g,h,k,l,m,n,q,p,w,u,v;return O(function(A){switch(A.g){case 1:g=!1;ra(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),q=n.next();!q.done;q=n.next())p=q.value,w=p.pendingSegmentRefId?d[p.pendingSegmentRefId]:null,null!=w&&(p.dataKey=w,p.pendingSegmentRefId=void 0),w=p.pendingInitSegmentRefId?d[p.pendingInitSegmentRefId]:null,null!=w&&(p.initSegmentKey=w,p.pendingInitSegmentRefId=void 0),p.pendingSegmentRefId&&(h=!1),p.pendingInitSegmentRefId&&
1250
- (h=!1);c.size+=e;h&&(c.isIncomplete=!1);return F(A,a.updateManifest(b,c),4);case 4:g=!0;f();ta(A,0);break;case 2:return u=ua(A),F(A,lz(b),5);case 5:if(g){A.u(6);break}v=Object.values(d);return F(A,a.removeSegments(v,function(){}),6);case 6:throw u;}})}
1251
- function hz(a,b,c){var d,e,f,g,h,k,l,m,n,q,p,w,u,v,A,z,D,y,B,C,E,G,L,K,I,J,N,M,P;return O(function(R){switch(R.g){case 1:return d={width:Infinity,height:Infinity},Qe(a,c.restrictions,d),F(R,Ue(b,a,c.offline.usePersistentLicense,c.drm.preferredKeySystems),2);case 2:e=[];f=c.preferredDecodingAttributes;g=c.preferredVideoCodecs;h=c.preferredAudioCodecs;Oe(a,g,h,f);k=t(a.variants);for(l=k.next();!l.done;l=k.next())m=l.value,e.push(lf(m));n=t(a.textStreams);for(q=n.next();!q.done;q=n.next())p=q.value,
1252
- e.push(mf(p));w=t(a.imageStreams);for(u=w.next();!u.done;u=w.next())v=u.value,e.push(nf(v));return F(R,c.offline.trackSelectionCallback(e),3);case 3:A=R.h;z=a.presentationTimeline.getDuration();D=0;y=t(A);for(B=y.next();!B.done;B=y.next())C=B.value,E=C.bandwidth*z/8,D+=E;ra(R,4);return F(R,c.offline.downloadSizeCallback(D),6);case 6:G=R.h;if(!G)throw new T(2,9,9014);ta(R,5);break;case 4:L=ua(R);if(L instanceof T)throw L;throw new T(2,9,9015);case 5:K=new Set;I=new Set;J=new Set;N=t(A);for(M=N.next();!M.done;M=
1253
- N.next())P=M.value,"variant"==P.type&&K.add(P.id),"text"==P.type&&I.add(P.id),"image"==P.type&&J.add(P.id);a.variants=a.variants.filter(function(Q){return K.has(Q.id)});a.textStreams=a.textStreams.filter(function(Q){return I.has(Q.id)});a.imageStreams=a.imageStreams.filter(function(Q){return J.has(Q.id)});pz(a);H(R)}})}
1254
- function iz(a,b,c,d,e,f){var g=Uy(c,b,d),h=e.offline.progressCallback;Yx(f,function(p,w){g.size=w;h(g,p)},function(p,w){k&&e.offline.usePersistentLicense&&l==w&&Wh(a,"cenc",p)});var k=mz(b)&&!nz(b),l=null;k&&(l=qz.get(a.g.keySystem));for(var m=new Xy,n=t(b.textStreams),q=n.next();!q.done;q=n.next())m.g[q.value.id]=52;n=t(b.imageStreams);for(q=n.next();!q.done;q=n.next())Zy(m,q.value);n=t(b.variants);for(q=n.next();!q.done;q=n.next())Yy(m,q.value);m=rz(f,m,b,e);f=m.streams;m=m.Xf;n=a.g;q=e.offline.usePersistentLicense;
1255
- n&&q&&(n.initData=[]);return{ui:{creationTime:Date.now(),originalManifestUri:c,duration:b.presentationTimeline.getDuration(),size:0,expiration:a.$c(),streams:f,sessionIds:q?ei(a):[],drmInfo:n,appMetadata:d,isIncomplete:!0,sequenceMode:b.sequenceMode,type:b.type},Xf:m}}function mz(a){return a.variants.some(function(b){var c=b.audio&&b.audio.encrypted;return b.video&&b.video.encrypted||c})}
1256
- function nz(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 kz(a,b,c,d){b.expiration=c.$c();c=ei(c);b.sessionIds=d.offline.usePersistentLicense?c:[];if(mz(a)&&d.offline.usePersistentLicense&&!c.length)throw new T(2,9,9007);}r.remove=function(a){return sz(this,tz(this,a))};
1249
+ function oz(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;ra(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&&
1250
+ (h=!1);c.size+=e;h&&(c.isIncomplete=!1);return F(A,a.updateManifest(b,c),4);case 4:g=!0;f();ta(A,0);break;case 2:return v=ua(A),F(A,lz(b),5);case 5:if(g){A.u(6);break}w=Object.values(d);return F(A,a.removeSegments(w,function(){}),6);case 6:throw v;}})}
1251
+ function hz(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,u,v,w,A,z,D,y,B,C,E,G,L,K,I,J,M,N,P;return O(function(R){switch(R.g){case 1:return d={width:Infinity,height:Infinity},Qe(a,c.restrictions,d),F(R,Ue(b,a,c.offline.usePersistentLicense,c.drm.preferredKeySystems),2);case 2:e=[];f=c.preferredDecodingAttributes;g=c.preferredVideoCodecs;h=c.preferredAudioCodecs;Oe(a,g,h,f);k=t(a.variants);for(l=k.next();!l.done;l=k.next())m=l.value,e.push(lf(m));n=t(a.textStreams);for(p=n.next();!p.done;p=n.next())r=p.value,
1252
+ e.push(mf(r));u=t(a.imageStreams);for(v=u.next();!v.done;v=u.next())w=v.value,e.push(nf(w));return F(R,c.offline.trackSelectionCallback(e),3);case 3:A=R.h;z=a.presentationTimeline.getDuration();D=0;y=t(A);for(B=y.next();!B.done;B=y.next())C=B.value,E=C.bandwidth*z/8,D+=E;ra(R,4);return F(R,c.offline.downloadSizeCallback(D),6);case 6:G=R.h;if(!G)throw new T(2,9,9014);ta(R,5);break;case 4:L=ua(R);if(L instanceof T)throw L;throw new T(2,9,9015);case 5:K=new Set;I=new Set;J=new Set;M=t(A);for(N=M.next();!N.done;N=
1253
+ M.next())P=N.value,"variant"==P.type&&K.add(P.id),"text"==P.type&&I.add(P.id),"image"==P.type&&J.add(P.id);a.variants=a.variants.filter(function(Q){return K.has(Q.id)});a.textStreams=a.textStreams.filter(function(Q){return I.has(Q.id)});a.imageStreams=a.imageStreams.filter(function(Q){return J.has(Q.id)});pz(a);H(R)}})}
1254
+ function iz(a,b,c,d,e,f){var g=Uy(c,b,d),h=e.offline.progressCallback;Yx(f,function(r,u){g.size=u;h(g,r)},function(r,u){k&&e.offline.usePersistentLicense&&l==u&&Wh(a,"cenc",r)});var k=mz(b)&&!nz(b),l=null;k&&(l=qz.get(a.g.keySystem));for(var m=new Xy,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())Zy(m,p.value);n=t(b.variants);for(p=n.next();!p.done;p=n.next())Yy(m,p.value);m=rz(f,m,b,e);f=m.streams;m=m.Xf;n=a.g;p=e.offline.usePersistentLicense;
1255
+ n&&p&&(n.initData=[]);return{ui:{creationTime:Date.now(),originalManifestUri:c,duration:b.presentationTimeline.getDuration(),size:0,expiration:a.ad(),streams:f,sessionIds:p?ei(a):[],drmInfo:n,appMetadata:d,isIncomplete:!0,sequenceMode:b.sequenceMode,type:b.type},Xf:m}}function mz(a){return a.variants.some(function(b){var c=b.audio&&b.audio.encrypted;return b.video&&b.video.encrypted||c})}
1256
+ function nz(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 kz(a,b,c,d){b.expiration=c.ad();c=ei(c);b.sessionIds=d.offline.usePersistentLicense?c:[];if(mz(a)&&d.offline.usePersistentLicense&&!c.length)throw new T(2,9,9007);}q.remove=function(a){return sz(this,tz(this,a))};
1257
1257
  function tz(a,b){var c,d,e,f,g,h;return O(function(k){switch(k.g){case 1:ez();c=Gy(b);if(null==c||"manifest"!=c.g)throw new T(2,9,9004,b);d=c;e=new my;sa(k,2);return F(k,e.init(),4);case 4:return F(k,qy(e,d.nb(),d.Ha()),5);case 5:return f=k.h,F(k,f.getManifests([d.key()]),6);case 6:return g=k.h,h=g[0],F(k,Promise.all([uz(a,h,e),vz(f,d,h)]),2);case 2:return va(k),F(k,e.destroy(),8);case 8:wa(k,0)}})}
1258
1258
  function wz(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:Zd(e.mimeType,e.codecs),robustness:a.drmInfo.videoRobustness}):b||"audio"!=e.type||c.push({contentType:Zd(e.mimeType,e.codecs),robustness:a.drmInfo.audioRobustness});return c}function uz(a,b,c){return O(function(d){return F(d,xz(a.g,a.h.drm,c,b),0)})}
1259
- function vz(a,b,c){function d(){}var e=yz(c);Wy(b,c);return Promise.all([a.removeSegments(e,d),a.removeManifests([b.key()],d)])}r.Li=function(){return sz(this,zz(this))};
1260
- function zz(a){var b,c,d,e,f,g,h,k,l,m;return O(function(n){switch(n.g){case 1:return ez(),b=a.g,c=a.h.drm,d=new my,e=!1,sa(n,2),F(n,d.init(),4);case 4:f=[],ry(d,function(q){return f.push(q)}),g=t(f),h=g.next();case 5:if(h.done){n.u(2);break}k=h.value;return F(n,k.getAll(),8);case 8:return l=n.h,F(n,Ry(c,b,l),9);case 9:return m=n.h,F(n,k.remove(m),10);case 10:m.length!=l.length&&(e=!0);h=g.next();n.u(5);break;case 2:return va(n),F(n,d.destroy(),11);case 11:wa(n,3);break;case 3:return n.return(!e)}})}
1261
- r.list=function(){return sz(this,Az())};function Az(){var a,b,c;return O(function(d){switch(d.g){case 1:return ez(),a=[],b=new my,sa(d,2),F(d,b.init(),4);case 4:return c=Promise.resolve(),py(b,function(e,f){c=c.then(function(){var g;return O(function(h){if(1==h.g)return F(h,f.getAllManifests(),2);g=h.h;g.forEach(function(k,l){k=Wy(new Fy("manifest",e.nb,e.Ha,l),k);a.push(k)});H(h)})})}),F(d,c,2);case 2:return va(d),F(d,b.destroy(),6);case 6:wa(d,3);break;case 3:return d.return(a)}})}
1259
+ function vz(a,b,c){function d(){}var e=yz(c);Wy(b,c);return Promise.all([a.removeSegments(e,d),a.removeManifests([b.key()],d)])}q.Li=function(){return sz(this,zz(this))};
1260
+ function zz(a){var b,c,d,e,f,g,h,k,l,m;return O(function(n){switch(n.g){case 1:return ez(),b=a.g,c=a.h.drm,d=new my,e=!1,sa(n,2),F(n,d.init(),4);case 4:f=[],ry(d,function(p){return f.push(p)}),g=t(f),h=g.next();case 5:if(h.done){n.u(2);break}k=h.value;return F(n,k.getAll(),8);case 8:return l=n.h,F(n,Ry(c,b,l),9);case 9:return m=n.h,F(n,k.remove(m),10);case 10:m.length!=l.length&&(e=!0);h=g.next();n.u(5);break;case 2:return va(n),F(n,d.destroy(),11);case 11:wa(n,3);break;case 3:return n.return(!e)}})}
1261
+ q.list=function(){return sz(this,Az())};function Az(){var a,b,c;return O(function(d){switch(d.g){case 1:return ez(),a=[],b=new my,sa(d,2),F(d,b.init(),4);case 4:return c=Promise.resolve(),py(b,function(e,f){c=c.then(function(){var g;return O(function(h){if(1==h.g)return F(h,f.getAllManifests(),2);g=h.h;g.forEach(function(k,l){k=Wy(new Fy("manifest",e.nb,e.Ha,l),k);a.push(k)});H(h)})})}),F(d,c,2);case 2:return va(d),F(d,b.destroy(),6);case 6:wa(d,3);break;case 3:return d.return(a)}})}
1262
1262
  function fz(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},
1263
1263
  onMetadata:function(){},disableStream:function(){}},c.configure(d.manifest),gz(a),F(l,c.start(b,g),2);if(3!=l.g)return h=l.h,gz(a),k=Bz(h),F(l,Promise.all(Dg(k,function(m){return m.createSegmentIndex()})),3);gz(a);if(e)throw e;return l.return(h)})}
1264
- r.zc=function(a,b,c){var d=this,e;return O(function(f){return 1==f.g?(e=new Gh({Lb:d.g,onError:b,de:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),e.configure(c.drm),F(f,Lh(e,a.variants,c.offline.usePersistentLicense),2)):3!=f.g?F(f,Yh(e),3):f.return(e)})};
1264
+ q.zc=function(a,b,c){var d=this,e;return O(function(f){return 1==f.g?(e=new Gh({Lb:d.g,onError:b,de:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),e.configure(c.drm),F(f,Lh(e,a.variants,c.offline.usePersistentLicense),2)):3!=f.g?F(f,Yh(e),3):f.return(e)})};
1265
1265
  function rz(a,b,c,d){var e=new Map,f=Bz(c),g=new Map;f=t(f);for(var h=f.next();!h.done;h=f.next()){h=h.value;var k=Cz(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()),Xf:Array.from(e.values())}}
1266
1266
  function Cz(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,
1267
- audioSamplingRate:d.audioSamplingRate,spatialAudio:d.spatialAudio,closedCaptions:d.closedCaptions,tilesLayout:d.tilesLayout,external:d.external,fastSwitching:d.fastSwitching},h=e.offline.numberOfParallelDownloads,k=0;Dz(d,c.presentationTimeline.mb(),function(l){var m=Sx(l),n=void 0;if(!f.has(m)){var q=l.endTime-l.startTime;q=$y(b,d.id)*q;q=Vx(a.g,q);f.set(m,new Rx(l,q,k,!1))}l.$&&(n=Sx(l.$),f.has(n)||(q=.5*$y(b,d.id),q=Vx(a.g,q),f.set(n,new Rx(l.$,q,k,!0))));g.segments.push({pendingInitSegmentRefId:n,
1267
+ audioSamplingRate:d.audioSamplingRate,spatialAudio:d.spatialAudio,closedCaptions:d.closedCaptions,tilesLayout:d.tilesLayout,external:d.external,fastSwitching:d.fastSwitching},h=e.offline.numberOfParallelDownloads,k=0;Dz(d,c.presentationTimeline.mb(),function(l){var m=Sx(l),n=void 0;if(!f.has(m)){var p=l.endTime-l.startTime;p=$y(b,d.id)*p;p=Vx(a.g,p);f.set(m,new Rx(l,p,k,!1))}l.$&&(n=Sx(l.$),f.has(n)||(p=.5*$y(b,d.id),p=Vx(a.g,p),f.set(n,new Rx(l.$,p,k,!0))));g.segments.push({pendingInitSegmentRefId:n,
1268
1268
  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 Dz(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 gz(a){if(a.l.g)throw new T(2,9,7001);}function ez(){if(!bz())throw new T(2,9,9E3);}
1269
1269
  function sz(a,b){return O(function(c){if(1==c.g)return a.i.push(b),sa(c,2),F(c,b,4);if(2!=c.g)return c.return(c.h);va(c);Nb(a.i,b);return wa(c,0)})}function dz(a,b){var c=b.promise;a.i.push(c);return b.finally(function(){Nb(a.i,c)})}function yz(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)}
1270
1270
  function xz(a,b,c,d){var e,f,g;return O(function(h){if(1==h.g){if(!d.drmInfo)return h.return();e=sy(c);f=d.sessionIds.map(function(k){return{sessionId:k,keySystem:d.drmInfo.keySystem,licenseUri:d.drmInfo.licenseServerUri,serverCertificate:d.drmInfo.serverCertificate,audioCapabilities:wz(d,!1),videoCapabilities:wz(d,!0)}});return F(h,Ry(b,a,f),2)}return 3!=h.g?(g=h.h,F(h,e.remove(g),3)):F(h,e.add(f.filter(function(k){return!g.includes(k.sessionId)})),0)})}
@@ -1277,11 +1277,11 @@ da.Object.defineProperties(Iz.prototype,{aborted:{configurable:!0,enumerable:!0,
1277
1277
  function Rz(){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}}),
1278
1278
  Object.defineProperty(document,"fullscreenEnabled",{get:function(){return document.mozFullScreenEnabled||document.msFullscreenEnabled||document.webkitFullscreenEnabled}}));document.addEventListener("webkitfullscreenchange",Sz);document.addEventListener("webkitfullscreenerror",Sz);document.addEventListener("mozfullscreenchange",Sz);document.addEventListener("mozfullscreenerror",Sz);document.addEventListener("MSFullscreenChange",Sz);document.addEventListener("MSFullscreenError",Sz)}}
1279
1279
  function Sz(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)}Ez.Fullscreen=Qz;Qz.install=Rz;Fz(Rz);function Tz(){}function Uz(){var a=!0;!fd()||fd()&&nd()||fd()&&Zc("Fuchsia")||(a=!1);if(gd()||jd()||id()||cd()||$c()||Zc("PC=EOS")||kd())a=!1;a&&navigator.mediaCapabilities||(navigator.mediaCapabilities||(navigator.mediaCapabilities={}),Vz=navigator.mediaCapabilities,navigator.mediaCapabilities.decodingInfo=Wz)}
1280
- function Wz(a){var b,c,d,e,f,g,h,k,l,m,n;return O(function(q){switch(q.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=Uc(e),!f)||d&&(g=d.contentType,h=Uc(g),!h))return q.return(b)}else return q.return(b);q.u(2);break}if(!Tc())return q.return(b);if(!c){q.u(3);break}return F(q,Xz(c),4);case 4:if(k=q.h,!k)return q.return(b);case 3:if(d){var p=d.contentType;fd()&&d.spatialRendering&&
1281
- (p+="; spatialRendering=true");l=mb(p);if(!l)return q.return(b)}case 2:if(!a.keySystemConfiguration)return b.supported=!0,q.return(b);m=a.keySystemConfiguration;return F(q,Yz(c,d,m),6);case 6:if(n=q.h)b.supported=!0,b.keySystemAccess=n;case 5:return q.return(b)}})}
1280
+ function Wz(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=Uc(e),!f)||d&&(g=d.contentType,h=Uc(g),!h))return p.return(b)}else return p.return(b);p.u(2);break}if(!Tc())return p.return(b);if(!c){p.u(3);break}return F(p,Xz(c),4);case 4:if(k=p.h,!k)return p.return(b);case 3:if(d){var r=d.contentType;fd()&&d.spatialRendering&&
1281
+ (r+="; spatialRendering=true");l=mb(r);if(!l)return p.return(b)}case 2:if(!a.keySystemConfiguration)return b.supported=!0,p.return(b);m=a.keySystemConfiguration;return F(p,Yz(c,d,m),6);case 6:if(n=p.h)b.supported=!0,b.keySystemAccess=n;case 5:return p.return(b)}})}
1282
1282
  function Xz(a){var b,c;return O(function(d){return 1==d.g?fd()?F(d,Zz(a),3):$c()?(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(mb(b))):d.u(2):2!=d.g?(c=d.h,d.return(c)):d.return(mb(a.contentType))})}
1283
- function Yz(a,b,c){var d,e,f,g,h,k,l,m,n;return O(function(q){switch(q.g){case 1:d=[];e=[];c.audio&&(f={robustness:c.audio.robustness||"",contentType:b.contentType},$c()&&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],
1284
- 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;ra(q,2);if(Qc.has(k+"#"+l+"#"+m)){n=Qc.get(k+"#"+l+"#"+m)||null;q.u(4);break}return F(q,navigator.requestMediaKeySystemAccess(c.keySystem,[h]),5);case 5:n=q.h,Qc.set(k+"#"+l+"#"+m,n);case 4:ta(q,3);break;case 2:ua(q);case 3:return q.return(n)}})}
1283
+ function Yz(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},$c()&&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],
1284
+ 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;ra(p,2);if(Qc.has(k+"#"+l+"#"+m)){n=Qc.get(k+"#"+l+"#"+m)||null;p.u(4);break}return F(p,navigator.requestMediaKeySystemAccess(c.keySystem,[h]),5);case 5:n=p.h,Qc.set(k+"#"+l+"#"+m,n);case 4:ta(p,3);break;case 2:ua(p);case 3:return p.return(n)}})}
1285
1285
  function Zz(a){var b,c;return O(function(d){if(1==d.g){if(!(window.cast&&cast.__platform__&&cast.__platform__.canDisplayType))return d.return(mb(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 $z?(c=$z[b],d.u(2)):F(d,cast.__platform__.canDisplayType(b),3)}2!=d.g&&(c=d.h,$z[b]=c);return d.return(c)})}Ez.MediaCapabilities=Tz;Tz.install=Uz;
1286
1286
  var Vz=null;Tz.originalMcap=Vz;var $z={};Tz.memoizedCanDisplayTypeRequests_=$z;Fz(Uz,-1);function aA(){}function bA(){var a=ld();if(window.MediaSource||window.ManagedMediaSource)a&&window.MediaSource?10>=a?window.MediaSource=null:12>=a?(cA(),dA()):15>=a&&cA():Zc("DT_STB_BCM")?(cA(),dA()):(bd()||ad()||Zc("Tizen 4"))&&eA();(window.MediaSource||window.ManagedMediaSource)&&fA();window.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&gA()}
1287
1287
  function cA(){var a=MediaSource.prototype.addSourceBuffer;MediaSource.prototype.addSourceBuffer=function(){var b=a.apply(this,Ia.apply(0,arguments));b.abort=function(){};return b}}function dA(){var a=SourceBuffer.prototype.remove;SourceBuffer.prototype.remove=function(b,c){return a.call(this,b,c-.001)}}
@@ -1298,11 +1298,11 @@ tA;window.shakaMediaKeysPolyfill=zA}};
1298
1298
  function uA(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,
1299
1299
  g.contentType.split(";")[0])&&(b.audioCapabilities.push(g),e=!0));if(c.videoCapabilities)for(c=t(c.videoCapabilities),f=c.next();!f.done;f=c.next())f=f.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;}
1300
1300
  uA.prototype.createMediaKeys=function(){var a=new yA(this.keySystem);return Promise.resolve(a)};uA.prototype.getConfiguration=function(){return this.g};function yA(a){this.h=new WebKitMediaKeys(a);this.g=new gb}yA.prototype.createSession=function(a){a=a||"temporary";if("temporary"!=a)throw new TypeError("Session type "+a+" is unsupported on this platform.");return new AA(this.h,a)};yA.prototype.setServerCertificate=function(){return Promise.resolve(!1)};
1301
- function wA(a,b){a.g.Qa();if(!b)return Promise.resolve();a.g.D(b,"webkitneedkey",xA);try{return zk(b,HTMLMediaElement.HAVE_METADATA,a.g,function(){b.webkitSetMediaKeys(a.h)}),Promise.resolve()}catch(c){return Promise.reject(c)}}yA.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function AA(a){lg.call(this);this.i=null;this.l=a;this.g=this.h=null;this.j=new gb;this.sessionId="";this.expiration=NaN;this.closed=new bg;this.keyStatuses=new BA}na(AA,lg);r=AA.prototype;
1302
- r.generateRequest=function(a,b){var c=this;this.h=new bg;try{var d=this.l.createSession("video/mp4",zb(b));this.i=d;this.sessionId=d.sessionId||"";this.j.D(this.i,"webkitkeymessage",function(e){c.h&&(c.h.resolve(),c.h=null);e=(new Map).set("messageType",void 0==c.keyStatuses.Yb()?"license-request":"license-renewal").set("message",Ab(e.message));e=new U("message",e);c.dispatchEvent(e)});this.j.D(d,"webkitkeyadded",function(){c.g&&(CA(c,"usable"),c.g.resolve(),c.g=null)});this.j.D(d,"webkitkeyerror",
1303
- 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:CA(c,"output-not-allowed");break;default:CA(c,"internal-error")}});CA(this,"status-pending")}catch(e){this.h.reject(e)}return this.h};r.load=function(){return Promise.reject(Error("MediaKeySession.load not yet supported"))};
1304
- r.update=function(a){this.g=new bg;try{this.i.update(zb(a))}catch(b){this.g.reject(b)}return this.g};r.close=function(){try{this.i.close(),this.closed.resolve(),this.j.Qa()}catch(a){this.closed.reject(a)}return this.closed};r.remove=function(){return Promise.reject(Error("MediaKeySession.remove is only applicable for persistent licenses, which are not supported on this platform"))};function CA(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new U("keystatuseschange");a.dispatchEvent(b)}
1305
- function BA(){this.size=0;this.g=void 0}r=BA.prototype;r.Yb=function(){return this.g};r.forEach=function(a){this.g&&a(this.g,Pc.value())};r.get=function(a){if(this.has(a))return this.g};r.has=function(a){var b=Pc.value();return this.g&&xb(a,b)?!0:!1};r.entries=function(){};r.keys=function(){};r.values=function(){};var zA="apple";function DA(){}function EA(){window.MediaKeys&&(!MediaKeys.prototype.setServerCertificate||ad()||Zc("Tizen 4")||Zc("Tizen 5.0")||dd())&&(MediaKeys.prototype.setServerCertificate=FA)}function FA(){return Promise.resolve(!1)}Ez.PatchedMediaKeysCert=DA;DA.install=EA;Fz(EA);function GA(){}function HA(){!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=IA,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=JA,window.MediaKeys=KA,window.MediaKeySystemAccess=LA,window.shakaMediaKeysPolyfill=MA)}function IA(){return Promise.reject(Error("The key system specified is not supported."))}
1301
+ function wA(a,b){a.g.Qa();if(!b)return Promise.resolve();a.g.D(b,"webkitneedkey",xA);try{return zk(b,HTMLMediaElement.HAVE_METADATA,a.g,function(){b.webkitSetMediaKeys(a.h)}),Promise.resolve()}catch(c){return Promise.reject(c)}}yA.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function AA(a){lg.call(this);this.i=null;this.l=a;this.g=this.h=null;this.j=new gb;this.sessionId="";this.expiration=NaN;this.closed=new bg;this.keyStatuses=new BA}na(AA,lg);q=AA.prototype;
1302
+ q.generateRequest=function(a,b){var c=this;this.h=new bg;try{var d=this.l.createSession("video/mp4",zb(b));this.i=d;this.sessionId=d.sessionId||"";this.j.D(this.i,"webkitkeymessage",function(e){c.h&&(c.h.resolve(),c.h=null);e=(new Map).set("messageType",void 0==c.keyStatuses.Yb()?"license-request":"license-renewal").set("message",Ab(e.message));e=new U("message",e);c.dispatchEvent(e)});this.j.D(d,"webkitkeyadded",function(){c.g&&(CA(c,"usable"),c.g.resolve(),c.g=null)});this.j.D(d,"webkitkeyerror",
1303
+ 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:CA(c,"output-not-allowed");break;default:CA(c,"internal-error")}});CA(this,"status-pending")}catch(e){this.h.reject(e)}return this.h};q.load=function(){return Promise.reject(Error("MediaKeySession.load not yet supported"))};
1304
+ q.update=function(a){this.g=new bg;try{this.i.update(zb(a))}catch(b){this.g.reject(b)}return this.g};q.close=function(){try{this.i.close(),this.closed.resolve(),this.j.Qa()}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 CA(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new U("keystatuseschange");a.dispatchEvent(b)}
1305
+ function BA(){this.size=0;this.g=void 0}q=BA.prototype;q.Yb=function(){return this.g};q.forEach=function(a){this.g&&a(this.g,Pc.value())};q.get=function(a){if(this.has(a))return this.g};q.has=function(a){var b=Pc.value();return this.g&&xb(a,b)?!0:!1};q.entries=function(){};q.keys=function(){};q.values=function(){};var zA="apple";function DA(){}function EA(){window.MediaKeys&&(!MediaKeys.prototype.setServerCertificate||ad()||Zc("Tizen 4")||Zc("Tizen 5.0")||dd())&&(MediaKeys.prototype.setServerCertificate=FA)}function FA(){return Promise.resolve(!1)}Ez.PatchedMediaKeysCert=DA;DA.install=EA;Fz(EA);function GA(){}function HA(){!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=IA,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=JA,window.MediaKeys=KA,window.MediaKeySystemAccess=LA,window.shakaMediaKeysPolyfill=MA)}function IA(){return Promise.reject(Error("The key system specified is not supported."))}
1306
1306
  function JA(a){return null==a?Promise.resolve():Promise.reject(Error("MediaKeys not supported."))}Ez.PatchedMediaKeysNop=GA;GA.install=HA;function KA(){throw new TypeError("Illegal constructor.");}KA.prototype.createSession=function(){};KA.prototype.setServerCertificate=function(){};KA.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function LA(){this.keySystem="";throw new TypeError("Illegal constructor.");}LA.prototype.getConfiguration=function(){};
1307
1307
  LA.prototype.createMediaKeys=function(){};var MA="nop";Fz(HA,-10);function NA(){}
1308
1308
  function OA(){if(!(!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration)){if(HTMLMediaElement.prototype.webkitGenerateKeyRequest)PA="webkit";else if(!HTMLMediaElement.prototype.generateKeyRequest)return;navigator.requestMediaKeySystemAccess=QA;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=RA;window.MediaKeys=SA;window.MediaKeySystemAccess=TA;window.shakaMediaKeysPolyfill=UA}}
@@ -1313,156 +1313,157 @@ d=!1);if(d){this.h=g;return}}c="Unsupported keySystem";if("org.w3.clearkey"==a||
1313
1313
  function WA(a,b){a.h=b;a.g.Qa();var c=PA;b&&(a.g.D(b,c+"needkey",function(d){var e=new CustomEvent("encrypted");e.initDataType="cenc";e.initData=Ab(d.initData);a.h.dispatchEvent(e)}),a.g.D(b,c+"keymessage",function(d){var e=XA(a,d.sessionId);e&&(d=(new Map).set("messageType",void 0==e.keyStatuses.Yb()?"licenserequest":"licenserenewal").set("message",d.message),d=new U("message",d),e.h&&(e.h.resolve(),e.h=null),e.dispatchEvent(d))}),a.g.D(b,c+"keyadded",function(d){(d=XA(a,d.sessionId))&&d.ready()}),
1314
1314
  a.g.D(b,c+"keyerror",function(d){var e=XA(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?YA(e,"output-restricted"):1==f?YA(e,"expired"):YA(e,"internal-error"))}}))}
1315
1315
  SA.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 ZA(b,this.l,a);this.i.push(a);return a};SA.prototype.setServerCertificate=function(){return Promise.resolve(!1)};SA.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};
1316
- function XA(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 ZA(a,b,c){lg.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 bg;this.keyStatuses=new $A}na(ZA,lg);r=ZA.prototype;r.ready=function(){YA(this,"usable");this.g&&this.g.resolve();this.g=null};
1316
+ function XA(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 ZA(a,b,c){lg.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 bg;this.keyStatuses=new $A}na(ZA,lg);q=ZA.prototype;q.ready=function(){YA(this,"usable");this.g&&this.g.resolve();this.g=null};
1317
1317
  function aB(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=zb(zd("LOAD_SESSION|"+c));else{var e=zd("PERSISTENT|");d=Ld(e,b)}else d=zb(b)}catch(g){return Promise.reject(g)}a.h=new bg;var f=VA("generateKeyRequest");try{a.j[f](a.i,d)}catch(g){if("InvalidStateError"!=g.name)return a.h=null,Promise.reject(g);(new Sc(function(){try{a.j[f](a.i,d)}catch(h){a.h.reject(h),a.h=null}})).Z(.01)}return a.h}
1318
1318
  function bB(a,b,c){if(a.g)a.g.then(function(){return bB(a,b,c)}).catch(function(){return bB(a,b,c)});else{a.g=b;if("webkit-org.w3.clearkey"==a.i){var d=ud(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=Gd(e.keys[0].k);e=Gd(e.keys[0].kid)}else d=zb(c),e=null;var f=VA("addKey");try{a.j[f](a.i,d,e,a.sessionId)}catch(g){a.g.reject(g),a.g=null}}}
1319
- function YA(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new U("keystatuseschange");a.dispatchEvent(b)}r.generateRequest=function(a,b){return aB(this,b,null)};r.load=function(a){return"persistent-license"==this.l?aB(this,null,a):Promise.reject(Error("Not a persistent session."))};r.update=function(a){var b=new bg;bB(this,b,a);return b};
1320
- r.close=function(){if("persistent-license"!=this.l){if(!this.sessionId)return this.closed.reject(Error("The session is not callable.")),this.closed;var a=VA("cancelKeyRequest");try{this.j[a](this.i,this.sessionId)}catch(b){}}this.closed.resolve();return this.closed};r.remove=function(){return"persistent-license"!=this.l?Promise.reject(Error("Not a persistent session.")):this.close()};function $A(){this.size=0;this.g=void 0}r=$A.prototype;r.Yb=function(){return this.g};
1321
- r.forEach=function(a){this.g&&a(this.g,Pc.value())};r.get=function(a){if(this.has(a))return this.g};r.has=function(a){var b=Pc.value();return this.g&&xb(a,b)?!0:!1};r.entries=function(){};r.keys=function(){};r.values=function(){};var PA="",UA="webkit";Fz(OA);function cB(){}function dB(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;a.requestPictureInPicture&&document.exitPictureInPicture||!a.webkitSupportsPresentationMode||(document.pictureInPictureEnabled=!0,document.pictureInPictureElement=null,a.requestPictureInPicture=eB,Object.defineProperty(a,"disablePictureInPicture",{get:fB,set:gB,enumerable:!0,configurable:!0}),document.exitPictureInPicture=hB,document.addEventListener("webkitpresentationmodechanged",iB,!0))}}
1319
+ function YA(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new U("keystatuseschange");a.dispatchEvent(b)}q.generateRequest=function(a,b){return aB(this,b,null)};q.load=function(a){return"persistent-license"==this.l?aB(this,null,a):Promise.reject(Error("Not a persistent session."))};q.update=function(a){var b=new bg;bB(this,b,a);return b};
1320
+ 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=VA("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 $A(){this.size=0;this.g=void 0}q=$A.prototype;q.Yb=function(){return this.g};
1321
+ q.forEach=function(a){this.g&&a(this.g,Pc.value())};q.get=function(a){if(this.has(a))return this.g};q.has=function(a){var b=Pc.value();return this.g&&xb(a,b)?!0:!1};q.entries=function(){};q.keys=function(){};q.values=function(){};var PA="",UA="webkit";Fz(OA);function cB(){}function dB(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;a.requestPictureInPicture&&document.exitPictureInPicture||!a.webkitSupportsPresentationMode||(document.pictureInPictureEnabled=!0,document.pictureInPictureElement=null,a.requestPictureInPicture=eB,Object.defineProperty(a,"disablePictureInPicture",{get:fB,set:gB,enumerable:!0,configurable:!0}),document.exitPictureInPicture=hB,document.addEventListener("webkitpresentationmodechanged",iB,!0))}}
1322
1322
  function iB(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)}
1323
1323
  function eB(){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 hB(){var a=document.pictureInPictureElement;return a?(a.webkitSetPresentationMode("inline"),document.pictureInPictureElement=null,Promise.resolve()):Promise.reject(Error("No picture in picture element found"))}
1324
1324
  function fB(){return this.hasAttribute("disablePictureInPicture")?!0:!this.webkitSupportsPresentationMode("picture-in-picture")}function gB(a){a?this.setAttribute("disablePictureInPicture",""):this.removeAttribute("disablePictureInPicture")}Ez.PiPWebkit=cB;cB.install=dB;Fz(dB);function jB(){}function kB(){window.crypto&&("randomUUID"in window.crypto||(window.crypto.randomUUID=lB))}function lB(){var a=URL.createObjectURL(new Blob),b=a.toString();URL.revokeObjectURL(a);return b.substr(b.lastIndexOf("/")+1)}Ez.RandomUUID=jB;jB.install=kB;Fz(kB);function mB(){}function nB(){var a=Symbol.prototype;"description"in a||Object.defineProperty(a,"description",{get:oB})}function oB(){var a=/\((.*)\)/.exec(this.toString());return a?a[1]:void 0}Ez.Symbol=mB;mB.install=nB;Fz(nB);function pB(){}function qB(){if(window.HTMLMediaElement){var a=HTMLMediaElement.prototype.play;HTMLMediaElement.prototype.play=function(){var b=a.apply(this);b&&b.catch(function(){});return b}}}Ez.VideoPlayPromise=pB;pB.install=qB;Fz(qB);function rB(){}function sB(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;!a.getVideoPlaybackQuality&&("webkitDroppedFrameCount"in a||dd())&&(a.getVideoPlaybackQuality=tB)}}function tB(){return{droppedVideoFrames:this.webkitDroppedFrameCount,totalVideoFrames:this.webkitDecodedFrameCount,corruptedVideoFrames:0,creationTime:NaN,totalFrameDelay:0}}Ez.VideoPlaybackQuality=rB;rB.install=sB;Fz(sB);function uB(){}function vB(){if(!window.VTTCue&&window.TextTrackCue){var a=null,b=TextTrackCue.length;if(3==b)a=wB;else if(6==b)a=xB;else{try{var c=!!wB(1,2,"")}catch(d){c=!1}c&&(a=wB)}a&&(window.VTTCue=function(d,e,f){return a(d,e,f)})}}function wB(a,b,c){return new window.TextTrackCue(a,b,c)}function xB(a,b,c){return new window.TextTrackCue(a+"-"+b+"-"+c,a,b,c)}Ez.VTTCue=uB;uB.install=vB;Fz(vB);function yB(){}yB.prototype.parseInit=function(){};yB.prototype.setSequenceMode=function(){};yB.prototype.setManifestType=function(){};yB.prototype.parseMedia=function(a,b){var c=null,d=[];a=ud(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=zB.exec(e))){var f=AB.exec(e[1]);f=60*parseInt(f[1],10)+parseFloat(f[2].replace(",","."));e=new Qb(f,b.segmentEnd?b.segmentEnd:f+2,e[2]);c&&(c.endTime=f,d.push(c));c=e}c&&d.push(c);return d};
1325
1325
  S("shaka.text.LrcTextParser",yB);yB.prototype.parseMedia=yB.prototype.parseMedia;yB.prototype.setManifestType=yB.prototype.setManifestType;yB.prototype.setSequenceMode=yB.prototype.setSequenceMode;yB.prototype.parseInit=yB.prototype.parseInit;var zB=/^\[(\d{1,2}:\d{1,2}(?:[.,]\d{1,3})?)\](.*)/,AB=/^(\d+):(\d{1,2}(?:[.,]\d{1,3})?)$/;re["application/x-subtitle-lrc"]=function(){return new yB};function BB(){}BB.prototype.parseInit=function(){};BB.prototype.setSequenceMode=function(){};BB.prototype.setManifestType=function(){};
1326
- BB.prototype.parseMedia=function(a,b,c){var d=ud(a);a=[];if(""==d)return a;var e=ah(d,"tt");if(!e)throw new T(2,2,2005,"Failed to parse TTML.");d=kh(e,"body")[0];if(!d)return[];var f=qh(e,CB,"frameRate"),g=qh(e,CB,"subFrameRate"),h=qh(e,CB,"frameRateMultiplier"),k=qh(e,CB,"tickRate"),l=qh(e,CB,"cellResolution"),m=e.attributes["xml:space"]||"default",n=qh(e,DB,"extent");if("default"!=m&&"preserve"!=m)throw new T(2,2,2005,"Invalid xml:space value: "+m);m="default"==m;f=new EB(f,g,h,k);l=l?(l=/^(\d+) (\d+)$/.exec(l))?
1327
- {fc:parseInt(l[1],10),rows:parseInt(l[2],10)}:null:null;g=(g=kh(e,"metadata")[0])?g.children:[];h=kh(e,"style");e=kh(e,"region");k=[];for(var q=t(e),p=q.next();!p.done;p=q.next()){var w=p.value;p=new Jb;var u=w.attributes["xml:id"];if(u){p.id=u;var v=null;n&&(v=FB.exec(n)||GB.exec(n));u=v?Number(v[1]):null;v=v?Number(v[2]):null;var A,z=HB(w,h,"extent");if(z){var D=(A=FB.exec(z))||GB.exec(z);null!=D&&(p.width=Number(D[1]),p.height=Number(D[2]),A||(null!=u&&(p.width=100*p.width/u),null!=v&&(p.height=
1328
- 100*p.height/v)),p.widthUnits=A||null!=u?Kb:0,p.heightUnits=A||null!=v?Kb:0)}if(w=HB(w,h,"origin"))if(D=(A=FB.exec(w))||GB.exec(w),null!=D)p.viewportAnchorX=Number(D[1]),p.viewportAnchorY=Number(D[2]),A?z||(p.width=100-p.viewportAnchorX,p.widthUnits=Kb,p.height=100-p.viewportAnchorY,p.heightUnits=Kb):(null!=v&&(p.viewportAnchorY=100*p.viewportAnchorY/v),null!=u&&(p.viewportAnchorX=100*p.viewportAnchorX/u)),p.viewportAnchorUnits=A||null!=u?Kb:0}else p=null;p&&k.push(p)}if(hh(d,"p").length)throw new T(2,
1329
- 2,2001,"<p> can only be inside <div> in TTML");n=t(hh(d,"div"));for(q=n.next();!q.done;q=n.next())if(hh(q.value,"span").length)throw new T(2,2,2001,"<span> can only be inside <p> in TTML");if(b=IB(d,b,f,g,h,e,k,m,l,null,!1,c))b.backgroundColor||(b.backgroundColor="transparent"),a.push(b);return a};
1330
- function IB(a,b,c,d,e,f,g,h,k,l,m,n){var q=l;if(fh(a)){if(!m)return null;var p={tagName:"span",children:[ih(a)],attributes:{},parent:null}}else p=a;for(var w=null,u=t(JB),v=u.next();!v.done&&!(w=KB(p,"backgroundImage",d,"#",v.value)[0]);v=u.next());u=null;var A=qh(p,JB,"backgroundImage");n&&A&&!A.startsWith("#")&&(v=new tc(n),A=new tc(A),(v=v.resolve(A).toString())&&(u=v));if("p"==a.tagName||w||u)m=!0;a=m;v="default"==(p.attributes["xml:space"]||(h?"default":"preserve"));A=p.children.every(fh);h=
1331
- [];if(!A)for(var z=t(p.children),D=z.next();!D.done;D=z.next())(D=IB(D.value,b,c,d,e,f,g,v,k,p,m,n))&&h.push(D);d=null!=l;n=ih(p);n=p.children.length&&n&&/\S/.test(n);D=p.attributes.begin||p.attributes.end||p.attributes.dur;if(!(D||n||"br"==p.tagName||0!=h.length||d&&!v))return null;z=LB(p,c);n=z.start;for(z=z.end;q&&q.tagName&&"tt"!=q.tagName;)z=MB(q,c,n,z),n=z.start,z=z.end,q=q.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);
1332
- if(!D&&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"==p.tagName)return e=new Qb(n,z,""),e.lineBreak=!0,e;b="";A&&(b=Cd(ih(p)||""),v&&(b=b.replace(/\s+/g," ")));b=new Qb(n,z,b);b.nestedCues=h;m||(b.isContainer=!0);k&&(b.cellResolution=k);k=KB(p,"region",f,"")[0];if(p.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&&!p.attributes.region&&
1333
- !p.attributes.style&&(g=KB(l,"region",f,"")[0]);NB(b,p,g,w,u,e,a,0==h.length);return b}
1334
- function NB(a,b,c,d,e,f,g,h){g=g||h;"rtl"==OB(b,c,f,"direction",g)&&(a.direction="rtl");h=OB(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=Ub);(h=OB(b,c,f,"textAlign",!0))?(a.positionAlign=PB[h],a.lineAlign=QB[h],a.textAlign=cc[h.toUpperCase()]):a.textAlign=Tb;if(h=OB(b,c,f,"displayAlign",!0))a.displayAlign=dc[h.toUpperCase()];if(h=OB(b,c,f,"color",g))a.color=h;if(h=OB(b,c,f,"backgroundColor",
1335
- g))a.backgroundColor=h;if(h=OB(b,c,f,"border",g))a.border=h;if(h=OB(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"!=
1336
- k}).join(",")}(h=OB(b,c,f,"fontWeight",g))&&"bold"==h&&(a.fontWeight=700);h=OB(b,c,f,"wrapOption",g);a.wrapLine=h&&"noWrap"==h?!1:!0;(h=OB(b,c,f,"lineHeight",g))&&h.match(RB)&&(a.lineHeight=h);(h=OB(b,c,f,"fontSize",g))&&(h.match(RB)||h.match(SB))&&(a.fontSize=h);if(h=OB(b,c,f,"fontStyle",g))a.fontStyle=hc[h.toUpperCase()];d?(e=d.attributes.imageType||d.attributes.imagetype,h=d.attributes.encoding,d=ih(d).trim(),"PNG"==e&&"Base64"==h&&d&&(a.backgroundImage="data:image/png;base64,"+d)):e&&(a.backgroundImage=
1337
- e);if(d=OB(b,c,f,"textOutline",g))d=d.split(" "),d[0].match(RB)?a.textStrokeColor=a.color:(a.textStrokeColor=d[0],d.shift()),d[0]&&d[0].match(RB)?a.textStrokeWidth=d[0]:a.textStrokeColor="";(d=OB(b,c,f,"letterSpacing",g))&&d.match(RB)&&(a.letterSpacing=d);(d=OB(b,c,f,"linePadding",g))&&d.match(RB)&&(a.linePadding=d);if(d=OB(b,c,f,"opacity",g))a.opacity=parseFloat(d);(d=HB(c,f,"textDecoration"))&&TB(a,d);(d=UB(b,f,"textDecoration"))&&TB(a,d);if(d=OB(b,c,f,"textCombine",g))a.textCombineUpright=d;switch(OB(b,
1326
+ BB.prototype.parseMedia=function(a,b,c){var d=ud(a);a=[];if(""==d)return a;var e=ah(d,"tt");if(!e)throw new T(2,2,2005,"Failed to parse TTML.");d=kh(e,"body")[0];if(!d)return[];var f=qh(e,CB,"frameRate"),g=qh(e,CB,"subFrameRate"),h=qh(e,CB,"frameRateMultiplier"),k=qh(e,CB,"tickRate"),l=qh(e,CB,"cellResolution"),m=e.attributes["xml:space"]||"default",n=qh(e,DB,"extent");if("default"!=m&&"preserve"!=m)throw new T(2,2,2005,"Invalid xml:space value: "+m);m="default"==m;f=new EB(f,g,h,k);l=FB(l);g=kh(e,
1327
+ "metadata")[0];g=(g?g.children:[]).filter(function(u){return"\n"!=u});h=kh(e,"style");e=kh(e,"region");k=[];for(var p=t(e),r=p.next();!r.done;r=p.next())(r=GB(r.value,h,n))&&k.push(r);if(hh(d,"p").length)throw new T(2,2,2001,"<p> can only be inside <div> in TTML");n=t(hh(d,"div"));for(p=n.next();!p.done;p=n.next())if(hh(p.value,"span").length)throw new T(2,2,2001,"<span> can only be inside <p> in TTML");if(b=HB(d,b,f,g,h,e,k,m,l,null,!1,c))b.backgroundColor||(b.backgroundColor="transparent"),a.push(b);
1328
+ return a};
1329
+ function HB(a,b,c,d,e,f,g,h,k,l,m,n){var p=l;if(fh(a)){if(!m)return null;var r={tagName:"span",children:[ih(a)],attributes:{},parent:null}}else r=a;for(var u=null,v=t(IB),w=v.next();!w.done&&!(u=JB(r,"backgroundImage",d,"#",w.value)[0]);w=v.next());v=null;var A=qh(r,IB,"backgroundImage");n&&A&&!A.startsWith("#")&&(w=new tc(n),A=new tc(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(fh);h=
1330
+ [];if(!A)for(var z=t(r.children),D=z.next();!D.done;D=z.next())(D=HB(D.value,b,c,d,e,f,g,w,k,r,m,n))&&h.push(D);d=null!=l;n=ih(r);n=r.children.length&&n&&/\S/.test(n);D=r.attributes.begin||r.attributes.end||r.attributes.dur;if(!(D||n||"br"==r.tagName||0!=h.length||d&&!w))return null;z=KB(r,c);n=z.start;for(z=z.end;p&&p.tagName&&"tt"!=p.tagName;)z=LB(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);
1331
+ if(!D&&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 Qb(n,z,""),e.lineBreak=!0,e;b="";A&&(b=Cd(ih(r)||""),w&&(b=b.replace(/\s+/g," ")));b=new Qb(n,z,b);b.nestedCues=h;m||(b.isContainer=!0);k&&(b.cellResolution=k);k=JB(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&&
1332
+ !r.attributes.style&&(g=JB(l,"region",f,"")[0]);MB(b,r,g,u,v,e,a,0==h.length);return b}
1333
+ function GB(a,b,c){var d=new Jb,e=a.attributes["xml:id"];if(!e)return null;d.id=e;e=null;c&&(e=NB.exec(c)||OB.exec(c));c=e?Number(e[1]):null;e=e?Number(e[2]):null;var f,g=PB(a,b,"extent");if(g){var h=(f=NB.exec(g))||OB.exec(g);null!=h&&(d.width=Number(h[1]),d.height=Number(h[2]),f||(null!=c&&(d.width=100*d.width/c),null!=e&&(d.height=100*d.height/e)),d.widthUnits=f||null!=c?Kb:0,d.heightUnits=f||null!=e?Kb:0)}if(a=PB(a,b,"origin"))if(h=(f=NB.exec(a))||OB.exec(a),null!=h)d.viewportAnchorX=Number(h[1]),
1334
+ d.viewportAnchorY=Number(h[2]),f?g||(d.width=100-d.viewportAnchorX,d.widthUnits=Kb,d.height=100-d.viewportAnchorY,d.heightUnits=Kb):(null!=e&&(d.viewportAnchorY=100*d.viewportAnchorY/e),null!=c&&(d.viewportAnchorX=100*d.viewportAnchorX/c)),d.viewportAnchorUnits=f||null!=c?Kb:0;return d}
1335
+ function MB(a,b,c,d,e,f,g,h){g=g||h;"rtl"==QB(b,c,f,"direction",g)&&(a.direction="rtl");h=QB(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=Ub);(h=QB(b,c,f,"textAlign",!0))?(a.positionAlign=RB[h],a.lineAlign=SB[h],a.textAlign=cc[h.toUpperCase()]):a.textAlign=Tb;if(h=QB(b,c,f,"displayAlign",!0))a.displayAlign=dc[h.toUpperCase()];if(h=QB(b,c,f,"color",g))a.color=h;if(h=QB(b,c,f,"backgroundColor",
1336
+ g))a.backgroundColor=h;if(h=QB(b,c,f,"border",g))a.border=h;if(h=QB(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"!=
1337
+ k}).join(",")}(h=QB(b,c,f,"fontWeight",g))&&"bold"==h&&(a.fontWeight=700);h=QB(b,c,f,"wrapOption",g);a.wrapLine=h&&"noWrap"==h?!1:!0;(h=QB(b,c,f,"lineHeight",g))&&h.match(TB)&&(a.lineHeight=h);(h=QB(b,c,f,"fontSize",g))&&(h.match(TB)||h.match(UB))&&(a.fontSize=h);if(h=QB(b,c,f,"fontStyle",g))a.fontStyle=hc[h.toUpperCase()];d?(e=d.attributes.imageType||d.attributes.imagetype,h=d.attributes.encoding,d=ih(d).trim(),"PNG"==e&&"Base64"==h&&d&&(a.backgroundImage="data:image/png;base64,"+d)):e&&(a.backgroundImage=
1338
+ e);if(d=QB(b,c,f,"textOutline",g))d=d.split(" "),d[0].match(TB)?a.textStrokeColor=a.color:(a.textStrokeColor=d[0],d.shift()),d[0]&&d[0].match(TB)?a.textStrokeWidth=d[0]:a.textStrokeColor="";(d=QB(b,c,f,"letterSpacing",g))&&d.match(TB)&&(a.letterSpacing=d);(d=QB(b,c,f,"linePadding",g))&&d.match(TB)&&(a.linePadding=d);if(d=QB(b,c,f,"opacity",g))a.opacity=parseFloat(d);(d=PB(c,f,"textDecoration"))&&VB(a,d);(d=WB(b,f,"textDecoration"))&&VB(a,d);if(d=QB(b,c,f,"textCombine",g))a.textCombineUpright=d;switch(QB(b,
1338
1339
  c,f,"ruby",g)){case "container":a.rubyTag="ruby";break;case "text":a.rubyTag="rt"}}
1339
- function TB(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")&&Nb(a.textDecoration,"underline");break;case "lineThrough":a.textDecoration.includes("lineThrough")||a.textDecoration.push("lineThrough");break;case "noLineThrough":a.textDecoration.includes("lineThrough")&&Nb(a.textDecoration,"lineThrough");break;case "overline":a.textDecoration.includes("overline")||
1340
- a.textDecoration.push("overline");break;case "noOverline":a.textDecoration.includes("overline")&&Nb(a.textDecoration,"overline")}}function OB(a,b,c,d,e){e=void 0===e?!0:e;return(a=UB(a,c,d))?a:e?HB(b,c,d):null}function HB(a,b,c){if(!a)return null;var d=qh(a,DB,c);return d?d:VB(a,b,c)}function UB(a,b,c){var d=qh(a,DB,c);return d?d:VB(a,b,c)}
1341
- function VB(a,b,c){a=KB(a,"style",b,"");for(var d=null,e=0;e<a.length;e++){var f=ph(a[e],"urn:ebu:tt:style",c);f||(f=qh(a[e],DB,c));f||(f=UB(a[e],b,c));f&&(d=f)}return d}function KB(a,b,c,d,e){var f=[];if(!a||1>c.length)return f;var g=a;for(a=null;!a&&!(a=e?ph(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}
1342
- function MB(a,b,c,d){a=LB(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 LB(a,b){var c=WB(a.attributes.begin,b),d=WB(a.attributes.end,b);a=WB(a.attributes.dur,b);null==d&&null!=a&&(d=c+a);return{start:c,end:d}}
1343
- function WB(a,b){var c=null;if(XB.test(a)){a=XB.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(YB.test(a))c=ZB(YB,a);else if($B.test(a))c=ZB($B,a);else if(aC.test(a))a=aC.exec(a),c=Number(a[1])/b.frameRate;else if(bC.test(a))a=bC.exec(a),c=Number(a[1])/b.g;else if(cC.test(a))c=ZB(cC,a);else if(a)throw new T(2,2,2001,"Could not parse cue time range in TTML");return c}
1344
- function ZB(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)}S("shaka.text.TtmlTextParser",BB);BB.prototype.parseMedia=BB.prototype.parseMedia;BB.prototype.setManifestType=BB.prototype.setManifestType;BB.prototype.setSequenceMode=BB.prototype.setSequenceMode;BB.prototype.parseInit=BB.prototype.parseInit;
1340
+ function VB(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")&&Nb(a.textDecoration,"underline");break;case "lineThrough":a.textDecoration.includes("lineThrough")||a.textDecoration.push("lineThrough");break;case "noLineThrough":a.textDecoration.includes("lineThrough")&&Nb(a.textDecoration,"lineThrough");break;case "overline":a.textDecoration.includes("overline")||
1341
+ a.textDecoration.push("overline");break;case "noOverline":a.textDecoration.includes("overline")&&Nb(a.textDecoration,"overline")}}function QB(a,b,c,d,e){e=void 0===e?!0:e;return(a=WB(a,c,d))?a:e?PB(b,c,d):null}function PB(a,b,c){if(!a)return null;var d=qh(a,DB,c);return d?d:XB(a,b,c)}function WB(a,b,c){var d=qh(a,DB,c);return d?d:XB(a,b,c)}
1342
+ function XB(a,b,c){a=JB(a,"style",b,"");for(var d=null,e=0;e<a.length;e++){var f=ph(a[e],"urn:ebu:tt:style",c);f||(f=qh(a[e],DB,c));f||(f=WB(a[e],b,c));f&&(d=f)}return d}function JB(a,b,c,d,e){var f=[];if(!a||1>c.length)return f;var g=a;for(a=null;!a&&!(a=e?ph(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}
1343
+ function LB(a,b,c,d){a=KB(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 KB(a,b){var c=YB(a.attributes.begin,b),d=YB(a.attributes.end,b);a=YB(a.attributes.dur,b);null==d&&null!=a&&(d=c+a);return{start:c,end:d}}
1344
+ function YB(a,b){var c=null;if(ZB.test(a)){a=ZB.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($B.test(a))c=aC($B,a);else if(bC.test(a))c=aC(bC,a);else if(cC.test(a))a=cC.exec(a),c=Number(a[1])/b.frameRate;else if(dC.test(a))a=dC.exec(a),c=Number(a[1])/b.g;else if(eC.test(a))c=aC(eC,a);else if(a)throw new T(2,2,2001,"Could not parse cue time range in TTML");return c}
1345
+ function aC(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)}function FB(a){return a?(a=/^(\d+) (\d+)$/.exec(a))?{fc:parseInt(a[1],10),rows:parseInt(a[2],10)}:null:null}S("shaka.text.TtmlTextParser",BB);BB.prototype.parseMedia=BB.prototype.parseMedia;BB.prototype.setManifestType=BB.prototype.setManifestType;BB.prototype.setSequenceMode=BB.prototype.setSequenceMode;BB.prototype.parseInit=BB.prototype.parseInit;
1345
1346
  function EB(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]))}
1346
- var FB=/^(\d{1,2}(?:\.\d+)?|100(?:\.0+)?)% (\d{1,2}(?:\.\d+)?|100(?:\.0+)?)%$/,SB=/^(\d{1,4}(?:\.\d+)?|100)%$/,RB=/^(\d+px|\d+em|\d*\.?\d+c)$/,GB=/^(\d+)px (\d+)px$/,XB=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,YB=/^(?:(\d{2,}):)?(\d{2}):(\d{2})$/,$B=/^(?:(\d{2,}):)?(\d{2}):(\d{2}\.\d+)$/,aC=/^(\d*(?:\.\d*)?)f$/,bC=/^(\d*(?:\.\d*)?)t$/,cC=RegExp("^(?:(\\d*(?:\\.\\d*)?)h)?(?:(\\d*(?:\\.\\d*)?)m)?(?:(\\d*(?:\\.\\d*)?)s)?(?:(\\d*(?:\\.\\d*)?)ms)?$"),QB={left:Xb,center:"center",right:"end",start:Xb,
1347
- end:"end"},PB={left:"line-left",center:"center",right:"line-right"},CB=["http://www.w3.org/ns/ttml#parameter","http://www.w3.org/2006/10/ttaf1#parameter"],DB=["http://www.w3.org/ns/ttml#styling","http://www.w3.org/2006/10/ttaf1#styling"],JB=["http://www.smpte-ra.org/schemas/2052-1/2010/smpte-tt","http://www.smpte-ra.org/schemas/2052-1/2013/smpte-tt"];re["application/ttml+xml"]=function(){return new BB};function dC(){this.g=new BB}dC.prototype.parseInit=function(a){var b=!1;(new Lg).box("moov",Qg).box("trak",Qg).box("mdia",Qg).box("minf",Qg).box("stbl",Qg).S("stsd",Sg).box("stpp",function(c){b=!0;c.parser.stop()}).parse(a);if(!b)throw new T(2,2,2007);};dC.prototype.setSequenceMode=function(){};dC.prototype.setManifestType=function(){};
1348
- dC.prototype.parseMedia=function(a,b,c){var d=this,e=!1,f=[];(new Lg).box("mdat",Xg(function(g){e=!0;f=f.concat(d.g.parseMedia(g,b,c))})).parse(a,!1);if(!e)throw new T(2,2,2007);return f};S("shaka.text.Mp4TtmlParser",dC);dC.prototype.parseMedia=dC.prototype.parseMedia;dC.prototype.setManifestType=dC.prototype.setManifestType;dC.prototype.setSequenceMode=dC.prototype.setSequenceMode;dC.prototype.parseInit=dC.prototype.parseInit;re['application/mp4; codecs="stpp"']=function(){return new dC};
1349
- re['application/mp4; codecs="stpp.ttml"']=function(){return new dC};re['application/mp4; codecs="stpp.ttml.im1t"']=function(){return new dC};re['application/mp4; codecs="stpp.ttml.im2t"']=function(){return new dC};re['application/mp4; codecs="stpp.ttml.etd1"']=function(){return new dC};re['application/mp4; codecs="stpp.ttml.etd1|im1t"']=function(){return new dC};re['application/mp4; codecs="stpp.ttml.im1t|etd1"']=function(){return new dC};re['application/mp4; codecs="stpp.TTML.im1t"']=function(){return new dC};function eC(){this.h=!1;this.g="UNKNOWN"}eC.prototype.parseInit=function(){};eC.prototype.setSequenceMode=function(a){this.h=a};eC.prototype.setManifestType=function(a){this.g=a};
1350
- eC.prototype.parseMedia=function(a,b){a=ud(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 T(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 T(2,2,2E3);a=fC(new Sp(a[1]));if(null==a)throw new T(2,2,2E3);d=Number(d[1]);for(var e=b.segmentStart-b.periodStart;95443.7176888889<=e;)e-=
1347
+ var NB=/^(\d{1,2}(?:\.\d+)?|100(?:\.0+)?)% (\d{1,2}(?:\.\d+)?|100(?:\.0+)?)%$/,UB=/^(\d{1,4}(?:\.\d+)?|100)%$/,TB=/^(\d+px|\d+em|\d*\.?\d+c)$/,OB=/^(\d+)px (\d+)px$/,ZB=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,$B=/^(?:(\d{2,}):)?(\d{2}):(\d{2})$/,bC=/^(?:(\d{2,}):)?(\d{2}):(\d{2}\.\d+)$/,cC=/^(\d*(?:\.\d*)?)f$/,dC=/^(\d*(?:\.\d*)?)t$/,eC=RegExp("^(?:(\\d*(?:\\.\\d*)?)h)?(?:(\\d*(?:\\.\\d*)?)m)?(?:(\\d*(?:\\.\\d*)?)s)?(?:(\\d*(?:\\.\\d*)?)ms)?$"),SB={left:Xb,center:"center",right:"end",start:Xb,
1348
+ end:"end"},RB={left:"line-left",center:"center",right:"line-right"},CB=["http://www.w3.org/ns/ttml#parameter","http://www.w3.org/2006/10/ttaf1#parameter"],DB=["http://www.w3.org/ns/ttml#styling","http://www.w3.org/2006/10/ttaf1#styling"],IB=["http://www.smpte-ra.org/schemas/2052-1/2010/smpte-tt","http://www.smpte-ra.org/schemas/2052-1/2013/smpte-tt"];re["application/ttml+xml"]=function(){return new BB};function fC(){this.g=new BB}fC.prototype.parseInit=function(a){var b=!1;(new Lg).box("moov",Qg).box("trak",Qg).box("mdia",Qg).box("minf",Qg).box("stbl",Qg).S("stsd",Sg).box("stpp",function(c){b=!0;c.parser.stop()}).parse(a);if(!b)throw new T(2,2,2007);};fC.prototype.setSequenceMode=function(){};fC.prototype.setManifestType=function(){};
1349
+ fC.prototype.parseMedia=function(a,b,c){var d=this,e=!1,f=[];(new Lg).box("mdat",Xg(function(g){e=!0;f=f.concat(d.g.parseMedia(g,b,c))})).parse(a,!1);if(!e)throw new T(2,2,2007);return f};S("shaka.text.Mp4TtmlParser",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;re['application/mp4; codecs="stpp"']=function(){return new fC};
1350
+ re['application/mp4; codecs="stpp.ttml"']=function(){return new fC};re['application/mp4; codecs="stpp.ttml.im1t"']=function(){return new fC};re['application/mp4; codecs="stpp.ttml.im2t"']=function(){return new fC};re['application/mp4; codecs="stpp.ttml.etd1"']=function(){return new fC};re['application/mp4; codecs="stpp.ttml.etd1|im1t"']=function(){return new fC};re['application/mp4; codecs="stpp.ttml.im1t|etd1"']=function(){return new fC};re['application/mp4; codecs="stpp.TTML.im1t"']=function(){return new fC};function gC(){this.h=!1;this.g="UNKNOWN"}gC.prototype.parseInit=function(){};gC.prototype.setSequenceMode=function(a){this.h=a};gC.prototype.setManifestType=function(a){this.g=a};
1351
+ gC.prototype.parseMedia=function(a,b){a=ud(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 T(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 T(2,2,2E3);a=hC(new Sp(a[1]));if(null==a)throw new T(2,2,2E3);d=Number(d[1]);for(var e=b.segmentStart-b.periodStart;95443.7176888889<=e;)e-=
1351
1352
  95443.7176888889,d+=8589934592;a=b.periodStart+d/9E4-a}else a=b.segmentStart;b=[];d=t(c[0].split("\n"));for(e=d.next();!e.done;e=d.next())if(e=e.value,/^Region:/.test(e)){e=new Sp(e);var f=new Jb;Vp(e);Tp(e);for(var g=Vp(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=
1352
- Number(g[2])):(g=/^viewportanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(k))?(h.viewportAnchorX=Number(g[1]),h.viewportAnchorY=Number(g[2])):/^scroll=up$/.exec(k)&&(h.scroll="up");Tp(e);g=Vp(e)}b.push(f)}d=new Map;gC(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=
1353
- 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=l.slice(1,-1);l[0].includes("}")&&(l=/\{(.*?)\}/.exec(l[0]))&&(k=l[1].split(";"));(l=d.get(g))||(l=new Qb(0,0,""));for(var m=!1,n=0;n<k.length;n++){var q=/^\s*([^:]+):\s*(.*)/.exec(k[n]);if(q){var p=q[2].trim().replace(";","");switch(q[1].trim()){case "background-color":case "background":m=!0;l.backgroundColor=p;break;case "color":m=!0;l.color=p;break;case "font-family":m=!0;l.fontFamily=p;break;
1354
- case "font-size":m=!0;l.fontSize=p;break;case "font-weight":if(700<=parseInt(p,10)||"bold"==p)m=!0,l.fontWeight=700;break;case "font-style":switch(p){case "normal":m=!0;l.fontStyle=$b;break;case "italic":m=!0;l.fontStyle="italic";break;case "oblique":m=!0,l.fontStyle="oblique"}break;case "opacity":m=!0;l.opacity=parseFloat(p);break;case "text-combine-upright":m=!0;l.textCombineUpright=p;break;case "text-shadow":m=!0;l.textShadow=p;break;case "white-space":m=!0,l.wrapLine="noWrap"!=p}}}m&&d.set(g,
1355
- l)}}l=f;m=a;if(1==l.length&&!l[0]||/^NOTE($|[ \t])/.test(l[0])||"STYLE"==l[0]||"REGION"==l[0])f=null;else if(f=null,l[0].includes("--\x3e")||(f=l[0],l.splice(0,1)),h=new Sp(l[0]),g=fC(h),n=Up(h,/[ \t]+--\x3e[ \t]+/g),k=fC(h),null==g||null==n||null==k)Ya("Failed to parse VTT time code. Cue skipped:",f,l),f=null;else{g+=m;k+=m;l=l.slice(1).join("\n").trim();d.has("global")?(m=d.get("global").clone(),m.startTime=g,m.endTime=k,m.payload=""):m=new Qb(g,k,"");Tp(h);for(g=Vp(h);g;)hC(m,g,b),Tp(h),g=Vp(h);
1356
- iC(l,m,d);null!=f&&(m.id=f);f=m}f&&e.push(f)}return e};function gC(a){for(var b=t(Object.entries(fc)),c=b.next();!c.done;c=b.next()){var d=t(c.value);c=d.next().value;d=d.next().value;var e=new Qb(0,0,"");e.color=d;a.set("."+c,e)}b=t(Object.entries(gc));for(c=b.next();!c.done;c=b.next())d=t(c.value),c=d.next().value,d=d.next().value,e=new Qb(0,0,""),e.backgroundColor=d,a.set("."+c,e)}
1357
- function iC(a,b,c){if(a.includes("<")){0===c.size&&gC(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(jC)&&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===
1358
- 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=kC(a);try{var m=ah("<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=
1359
- m.next())lC(a.value,b,c);else b.payload=Cd(a);else b.payload=Cd(a)}else b.payload=Cd(a)}function kC(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 mC(a,b){return a&&0<a.length?a:b}
1360
- function lC(a,b,c){var d=b.clone();d.nestedCues=[];d.payload="";d.rubyTag="";d.line=null;d.region=new Jb;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)&&(h=d,g=c.get(g))&&(h.backgroundColor=mC(g.backgroundColor,h.backgroundColor),h.color=mC(g.color,h.color),h.fontFamily=mC(g.fontFamily,h.fontFamily),h.fontSize=
1361
- mC(g.fontSize,h.fontSize),h.textShadow=mC(g.textShadow,h.textShadow),h.fontWeight=g.fontWeight,h.fontStyle=g.fontStyle,h.opacity=g.opacity,h.rubyTag=g.rubyTag,h.textCombineUpright=g.textCombineUpright,h.wrapLine=g.wrapLine);switch(f){case "br":d=ac(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;
1362
- if(!f)break;if(f=fC(new Sp(f)))d.startTime=f;break;case "ruby":case "rp":case "rt":d.rubyTag=f}}e=a.children;if(fh(a)||1==e.length&&fh(e[0]))for(c=ih(a).split("\n"),a=!0,c=t(c),e=c.next();!e.done;e=c.next())e=e.value,a||(a=ac(d.startTime,d.endTime),b.nestedCues.push(a)),0<e.length&&(a=d.clone(),a.payload=Cd(e),b.nestedCues.push(a)),a=!1;else for(b.nestedCues.push(d),b=t(e),a=b.next();!a.done;a=b.next())lC(a.value,d,c)}
1363
- function hC(a,b,c){var d;if(d=/^align:(start|middle|center|end|left|right)$/.exec(b))b=d[1],"middle"==b?a.textAlign=Tb:a.textAlign=cc[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"==
1364
- b||"end"==b?"line-right":"center"==b||"middle"==b?"center":Sb);else if(d=/^region:(.*)$/.exec(b)){if(b=nC(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=ec[c[2].toUpperCase()]);else if(c=/^line:(-?\d+)(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=Wb,a.line=Number(c[1]),c[2]&&(a.lineAlign=ec[c[2].toUpperCase()])}
1365
- function nC(a,b){a=a.filter(function(c){return c.id==b});return a.length?a[0]:null}function fC(a){a=Up(a,jC);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)}S("shaka.text.VttTextParser",eC);eC.prototype.parseMedia=eC.prototype.parseMedia;eC.prototype.setManifestType=eC.prototype.setManifestType;eC.prototype.setSequenceMode=eC.prototype.setSequenceMode;eC.prototype.parseInit=eC.prototype.parseInit;var jC=/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g;
1366
- re["text/vtt"]=function(){return new eC};re['text/vtt; codecs="vtt"']=function(){return new eC};re['text/vtt; codecs="wvtt"']=function(){return new eC};function oC(){this.g=null}oC.prototype.parseInit=function(a){var b=this,c=!1;(new Lg).box("moov",Qg).box("trak",Qg).box("mdia",Qg).S("mdhd",function(d){d=aj(d.reader,d.version);b.g=d.timescale}).box("minf",Qg).box("stbl",Qg).S("stsd",Sg).box("wvtt",function(){c=!0}).parse(a);if(!this.g)throw new T(2,2,2008);if(!c)throw new T(2,2,2008);};oC.prototype.setSequenceMode=function(){};oC.prototype.setManifestType=function(){};
1367
- oC.prototype.parseMedia=function(a,b){if(!a.length)return[];if(!this.g)throw new T(2,2,2008);var c=0,d=[],e,f=[],g=!1,h=!1,k=!1,l=null;(new Lg).box("moof",Qg).box("traf",Qg).S("tfdt",function(D){g=!0;c=$i(D.reader,D.version).baseMediaDecodeTime}).S("tfhd",function(D){l=Zi(D.reader,D.flags).Xc}).S("trun",function(D){h=!0;d=bj(D.reader,D.version,D.flags).Wg}).box("mdat",Xg(function(D){k=!0;e=D})).parse(a,!1);if(!k&&!g&&!h)throw new T(2,2,2008);a=c;for(var m=new Ig(e,0),n=t(d),q=n.next();!q.done;q=n.next()){q=
1368
- q.value;var p=q.Jf||l,w=q.me?c+q.me:a;a=w+(p||0);var u=0;do{var v=m.R();u+=v;var A=m.R(),z=null;"vttc"==Pg(A)?8<v&&(z=m.qb(v-8)):m.skip(v-8);p&&z&&(v=pC(z,b.periodStart+w/this.g,b.periodStart+a/this.g),f.push(v))}while(q.sampleSize&&u<q.sampleSize)}return f.filter(Ae)};function pC(a,b,c){var d,e,f;(new Lg).box("payl",Xg(function(g){d=ud(g)})).box("iden",Xg(function(g){e=ud(g)})).box("sttg",Xg(function(g){f=ud(g)})).parse(a);return d?qC(d,e,f,b,c):null}
1369
- function qC(a,b,c,d,e){d=new Qb(d,e,"");iC(a,d,new Map);b&&(d.id=b);if(c)for(a=new Sp(c),b=Vp(a);b;)hC(d,b,[]),Tp(a),b=Vp(a);return d}S("shaka.text.Mp4VttParser",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;re['application/mp4; codecs="wvtt"']=function(){return new oC};function rC(){}rC.prototype.parseInit=function(){};rC.prototype.setSequenceMode=function(){};rC.prototype.setManifestType=function(){};rC.prototype.parseMedia=function(a){var b=ud(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 Sp(c[0]),e=sC(d),f=Up(d,/,/g);d=sC(d);if(null==e||null==f||null==d)throw new T(2,2,2001,"Could not parse cue time range in SubViewer");a.push(new Qb(e,d,c.slice(1).join("\n").trim()))}return a};
1370
- function sC(a){a=Up(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)}S("shaka.text.SbvTextParser",rC);rC.prototype.parseMedia=rC.prototype.parseMedia;rC.prototype.setManifestType=rC.prototype.setManifestType;rC.prototype.setSequenceMode=rC.prototype.setSequenceMode;rC.prototype.parseInit=rC.prototype.parseInit;re["text/x-subviewer"]=function(){return new rC};function tC(){this.g=new eC}tC.prototype.parseInit=function(){};tC.prototype.setSequenceMode=function(){};tC.prototype.setManifestType=function(){};tC.prototype.parseMedia=function(a,b,c){a=ud(a);a=uC(a);a=zb(zd(a));return this.g.parseMedia(a,b,c)};
1371
- function uC(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}S("shaka.text.SrtTextParser",tC);tC.srt2webvtt=uC;tC.prototype.parseMedia=tC.prototype.parseMedia;
1372
- tC.prototype.setManifestType=tC.prototype.setManifestType;tC.prototype.setSequenceMode=tC.prototype.setSequenceMode;tC.prototype.parseInit=tC.prototype.parseInit;re["text/srt"]=function(){return new tC};function vC(){}vC.prototype.parseInit=function(){};vC.prototype.setSequenceMode=function(){};vC.prototype.setManifestType=function(){};
1373
- vC.prototype.parseMedia=function(a){var b="",c="",d=null,e=null;e=ud(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=wC.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(a=b.next();!a.done;a=b.next())if(a=a.value,!/^\s*;/.test(a)&&(f=xC.exec(a)))if(a=f[1].trim(),f=f[2].trim(),"Format"==a)e=f.split(yC);else if("Style"==a){a=f.split(yC);f={};for(var g=0;g<e.length&&
1374
- g<a.length;g++)f[e[g]]=a[g];d.push(f)}e=[];b=null;c=t(c.split(/\r?\n/));f=c.next();for(a={};!f.done;a={jh:void 0},f=c.next())if(f=f.value,!/^\s*;/.test(f)&&(g=xC.exec(f)))if(f=g[1].trim(),g=g[2].trim(),"Format"==f)b=g.split(yC);else if("Dialogue"==f){g=g.split(yC);f={};for(var h=0;h<b.length&&h<g.length;h++)f[b[h]]=g[h];h=zC(f.Start);var k=zC(f.End);g=new Qb(h,k,g.slice(b.length-1).join(",").replace(/\\N/g,"\n").replace(/\{[^}]+\}/g,""));a.jh=f.Style;(a=d.find(function(l){return function(m){return m.Name==
1375
- l.jh}}(a)))&&AC(g,a);e.push(g)}return e};
1376
- function AC(a,b){var c=b.Fontname;c&&(a.fontFamily=c);if(c=b.Fontsize)a.fontSize=c+"px";if(c=b.PrimaryColour)if(c=BC(c))a.color=c;if(c=b.BackColour)if(c=BC(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=Yb;a.textAlign="start";break;case 2:a.displayAlign=Yb;a.textAlign=Tb;break;case 3:a.displayAlign=Yb;a.textAlign="end";
1353
+ Number(g[2])):(g=/^viewportanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(k))?(h.viewportAnchorX=Number(g[1]),h.viewportAnchorY=Number(g[2])):/^scroll=up$/.exec(k)&&(h.scroll="up");Tp(e);g=Vp(e)}b.push(f)}d=new Map;iC(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=
1354
+ 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=l.slice(1,-1);l[0].includes("}")&&(l=/\{(.*?)\}/.exec(l[0]))&&(k=l[1].split(";"));(l=d.get(g))||(l=new Qb(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;
1355
+ case "font-size":m=!0;l.fontSize=r;break;case "font-weight":if(700<=parseInt(r,10)||"bold"==r)m=!0,l.fontWeight=700;break;case "font-style":switch(r){case "normal":m=!0;l.fontStyle=$b;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,
1356
+ l)}}l=f;m=a;if(1==l.length&&!l[0]||/^NOTE($|[ \t])/.test(l[0])||"STYLE"==l[0]||"REGION"==l[0])f=null;else if(f=null,l[0].includes("--\x3e")||(f=l[0],l.splice(0,1)),h=new Sp(l[0]),g=hC(h),n=Up(h,/[ \t]+--\x3e[ \t]+/g),k=hC(h),null==g||null==n||null==k)Ya("Failed to parse VTT time code. Cue skipped:",f,l),f=null;else{g+=m;k+=m;l=l.slice(1).join("\n").trim();d.has("global")?(m=d.get("global").clone(),m.startTime=g,m.endTime=k,m.payload=""):m=new Qb(g,k,"");Tp(h);for(g=Vp(h);g;)jC(m,g,b),Tp(h),g=Vp(h);
1357
+ kC(l,m,d);null!=f&&(m.id=f);f=m}f&&e.push(f)}return e};function iC(a){for(var b=t(Object.entries(fc)),c=b.next();!c.done;c=b.next()){var d=t(c.value);c=d.next().value;d=d.next().value;var e=new Qb(0,0,"");e.color=d;a.set("."+c,e)}b=t(Object.entries(gc));for(c=b.next();!c.done;c=b.next())d=t(c.value),c=d.next().value,d=d.next().value,e=new Qb(0,0,""),e.backgroundColor=d,a.set("."+c,e)}
1358
+ function kC(a,b,c){if(a.includes("<")){0===c.size&&iC(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(lC)&&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===
1359
+ 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=mC(a);try{var m=ah("<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=
1360
+ m.next())nC(a.value,b,c);else b.payload=Cd(a);else b.payload=Cd(a)}else b.payload=Cd(a)}function mC(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 oC(a,b){return a&&0<a.length?a:b}
1361
+ function nC(a,b,c){var d=b.clone();d.nestedCues=[];d.payload="";d.rubyTag="";d.line=null;d.region=new Jb;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)&&(h=d,g=c.get(g))&&(h.backgroundColor=oC(g.backgroundColor,h.backgroundColor),h.color=oC(g.color,h.color),h.fontFamily=oC(g.fontFamily,h.fontFamily),h.fontSize=
1362
+ oC(g.fontSize,h.fontSize),h.textShadow=oC(g.textShadow,h.textShadow),h.fontWeight=g.fontWeight,h.fontStyle=g.fontStyle,h.opacity=g.opacity,h.rubyTag=g.rubyTag,h.textCombineUpright=g.textCombineUpright,h.wrapLine=g.wrapLine);switch(f){case "br":d=ac(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;
1363
+ if(!f)break;if(f=hC(new Sp(f)))d.startTime=f;break;case "ruby":case "rp":case "rt":d.rubyTag=f}}e=a.children;if(fh(a)||1==e.length&&fh(e[0]))for(c=ih(a).split("\n"),a=!0,c=t(c),e=c.next();!e.done;e=c.next())e=e.value,a||(a=ac(d.startTime,d.endTime),b.nestedCues.push(a)),0<e.length&&(a=d.clone(),a.payload=Cd(e),b.nestedCues.push(a)),a=!1;else for(b.nestedCues.push(d),b=t(e),a=b.next();!a.done;a=b.next())nC(a.value,d,c)}
1364
+ function jC(a,b,c){var d;if(d=/^align:(start|middle|center|end|left|right)$/.exec(b))b=d[1],"middle"==b?a.textAlign=Tb:a.textAlign=cc[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"==
1365
+ b||"end"==b?"line-right":"center"==b||"middle"==b?"center":Sb);else if(d=/^region:(.*)$/.exec(b)){if(b=pC(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=ec[c[2].toUpperCase()]);else if(c=/^line:(-?\d+)(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=Wb,a.line=Number(c[1]),c[2]&&(a.lineAlign=ec[c[2].toUpperCase()])}
1366
+ function pC(a,b){a=a.filter(function(c){return c.id==b});return a.length?a[0]:null}function hC(a){a=Up(a,lC);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)}S("shaka.text.VttTextParser",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;var lC=/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g;
1367
+ re["text/vtt"]=function(){return new gC};re['text/vtt; codecs="vtt"']=function(){return new gC};re['text/vtt; codecs="wvtt"']=function(){return new gC};function qC(){this.g=null}qC.prototype.parseInit=function(a){var b=this,c=!1;(new Lg).box("moov",Qg).box("trak",Qg).box("mdia",Qg).S("mdhd",function(d){d=aj(d.reader,d.version);b.g=d.timescale}).box("minf",Qg).box("stbl",Qg).S("stsd",Sg).box("wvtt",function(){c=!0}).parse(a);if(!this.g)throw new T(2,2,2008);if(!c)throw new T(2,2,2008);};qC.prototype.setSequenceMode=function(){};qC.prototype.setManifestType=function(){};
1368
+ qC.prototype.parseMedia=function(a,b){if(!a.length)return[];if(!this.g)throw new T(2,2,2008);var c=0,d=[],e,f=[],g=!1,h=!1,k=!1,l=null;(new Lg).box("moof",Qg).box("traf",Qg).S("tfdt",function(D){g=!0;c=$i(D.reader,D.version).baseMediaDecodeTime}).S("tfhd",function(D){l=Zi(D.reader,D.flags).Yc}).S("trun",function(D){h=!0;d=bj(D.reader,D.version,D.flags).Wg}).box("mdat",Xg(function(D){k=!0;e=D})).parse(a,!1);if(!k&&!g&&!h)throw new T(2,2,2008);a=c;for(var m=new Ig(e,0),n=t(d),p=n.next();!p.done;p=n.next()){p=
1369
+ p.value;var r=p.Jf||l,u=p.me?c+p.me:a;a=u+(r||0);var v=0;do{var w=m.R();v+=w;var A=m.R(),z=null;"vttc"==Pg(A)?8<w&&(z=m.qb(w-8)):m.skip(w-8);r&&z&&(w=rC(z,b.periodStart+u/this.g,b.periodStart+a/this.g),f.push(w))}while(p.sampleSize&&v<p.sampleSize)}return f.filter(Ae)};function rC(a,b,c){var d,e,f;(new Lg).box("payl",Xg(function(g){d=ud(g)})).box("iden",Xg(function(g){e=ud(g)})).box("sttg",Xg(function(g){f=ud(g)})).parse(a);return d?sC(d,e,f,b,c):null}
1370
+ function sC(a,b,c,d,e){d=new Qb(d,e,"");kC(a,d,new Map);b&&(d.id=b);if(c)for(a=new Sp(c),b=Vp(a);b;)jC(d,b,[]),Tp(a),b=Vp(a);return d}S("shaka.text.Mp4VttParser",qC);qC.prototype.parseMedia=qC.prototype.parseMedia;qC.prototype.setManifestType=qC.prototype.setManifestType;qC.prototype.setSequenceMode=qC.prototype.setSequenceMode;qC.prototype.parseInit=qC.prototype.parseInit;re['application/mp4; codecs="wvtt"']=function(){return new qC};function tC(){}tC.prototype.parseInit=function(){};tC.prototype.setSequenceMode=function(){};tC.prototype.setManifestType=function(){};tC.prototype.parseMedia=function(a){var b=ud(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 Sp(c[0]),e=uC(d),f=Up(d,/,/g);d=uC(d);if(null==e||null==f||null==d)throw new T(2,2,2001,"Could not parse cue time range in SubViewer");a.push(new Qb(e,d,c.slice(1).join("\n").trim()))}return a};
1371
+ function uC(a){a=Up(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)}S("shaka.text.SbvTextParser",tC);tC.prototype.parseMedia=tC.prototype.parseMedia;tC.prototype.setManifestType=tC.prototype.setManifestType;tC.prototype.setSequenceMode=tC.prototype.setSequenceMode;tC.prototype.parseInit=tC.prototype.parseInit;re["text/x-subviewer"]=function(){return new tC};function vC(){this.g=new gC}vC.prototype.parseInit=function(){};vC.prototype.setSequenceMode=function(){};vC.prototype.setManifestType=function(){};vC.prototype.parseMedia=function(a,b,c){a=ud(a);a=wC(a);a=zb(zd(a));return this.g.parseMedia(a,b,c)};
1372
+ function wC(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}S("shaka.text.SrtTextParser",vC);vC.srt2webvtt=wC;vC.prototype.parseMedia=vC.prototype.parseMedia;
1373
+ vC.prototype.setManifestType=vC.prototype.setManifestType;vC.prototype.setSequenceMode=vC.prototype.setSequenceMode;vC.prototype.parseInit=vC.prototype.parseInit;re["text/srt"]=function(){return new vC};function xC(){}xC.prototype.parseInit=function(){};xC.prototype.setSequenceMode=function(){};xC.prototype.setManifestType=function(){};
1374
+ xC.prototype.parseMedia=function(a){var b="",c="",d=null,e=null;e=ud(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=yC.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(a=b.next();!a.done;a=b.next())if(a=a.value,!/^\s*;/.test(a)&&(f=zC.exec(a)))if(a=f[1].trim(),f=f[2].trim(),"Format"==a)e=f.split(AC);else if("Style"==a){a=f.split(AC);f={};for(var g=0;g<e.length&&
1375
+ g<a.length;g++)f[e[g]]=a[g];d.push(f)}e=[];b=null;c=t(c.split(/\r?\n/));f=c.next();for(a={};!f.done;a={jh:void 0},f=c.next())if(f=f.value,!/^\s*;/.test(f)&&(g=zC.exec(f)))if(f=g[1].trim(),g=g[2].trim(),"Format"==f)b=g.split(AC);else if("Dialogue"==f){g=g.split(AC);f={};for(var h=0;h<b.length&&h<g.length;h++)f[b[h]]=g[h];h=BC(f.Start);var k=BC(f.End);g=new Qb(h,k,g.slice(b.length-1).join(",").replace(/\\N/g,"\n").replace(/\{[^}]+\}/g,""));a.jh=f.Style;(a=d.find(function(l){return function(m){return m.Name==
1376
+ l.jh}}(a)))&&CC(g,a);e.push(g)}return e};
1377
+ function CC(a,b){var c=b.Fontname;c&&(a.fontFamily=c);if(c=b.Fontsize)a.fontSize=c+"px";if(c=b.PrimaryColour)if(c=DC(c))a.color=c;if(c=b.BackColour)if(c=DC(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=Yb;a.textAlign="start";break;case 2:a.displayAlign=Yb;a.textAlign=Tb;break;case 3:a.displayAlign=Yb;a.textAlign="end";
1377
1378
  break;case 5:a.displayAlign="before";a.textAlign="start";break;case 6:a.displayAlign="before";a.textAlign=Tb;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=Tb;break;case 11:a.displayAlign="center",a.textAlign="end"}if(b=b.AlphaLevel)a.opacity=parseFloat(b)}
1378
- function BC(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 zC(a){a=CC.exec(a);return 3600*(a[1]?parseInt(a[1].replace(":",""),10):0)+60*parseInt(a[2],10)+parseFloat(a[3])}S("shaka.text.SsaTextParser",vC);vC.prototype.parseMedia=vC.prototype.parseMedia;vC.prototype.setManifestType=vC.prototype.setManifestType;vC.prototype.setSequenceMode=vC.prototype.setSequenceMode;vC.prototype.parseInit=vC.prototype.parseInit;
1379
- var wC=/^\s*\[([^\]]+)\]\r?\n([\s\S]*)/,xC=/^\s*([^:]+):\s*(.*)/,yC=/\s*,\s*/,CC=/^(\d+:)?(\d{1,2}):(\d{1,2}(?:[.]\d{1,3})?)?$/;re["text/x-ssa"]=function(){return new vC};function DC(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)?{Nd:c,ca:a}:null}function EC(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,codec:"mp4a.40."+e}}
1380
- function FC(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}
1381
- function GC(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,
1382
- 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 HC(a){this.i=a;this.h=0;this.g=new Map}r=HC.prototype;r.destroy=function(){this.g.clear()};r.isSupported=function(a){return"audio/aac"==a.toLowerCase().split(";")[0]?mb(this.convertCodecs("audio",a)):!1};r.convertCodecs=function(a,b){return"audio/aac"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="'+(je(b)||"mp4a.40.2")+'"':b};r.getOriginalMimeType=function(){return this.i};
1383
- r.transmux=function(a,b,c,d){for(var e=zb(a),f=Yi(e),g=f.length;g<e.length&&!FC(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=EC(e,g);if(!f)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));b.audioSamplingRate=f.sampleRate;b.channelsCount=f.channelCount;for(var h=[];g<e.length;){var k=DC(e,g);if(!k)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));var l=k.Nd+k.ca;g+l<=e.length&&h.push({data:e.subarray(g+
1379
+ function DC(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 BC(a){a=EC.exec(a);return 3600*(a[1]?parseInt(a[1].replace(":",""),10):0)+60*parseInt(a[2],10)+parseFloat(a[3])}S("shaka.text.SsaTextParser",xC);xC.prototype.parseMedia=xC.prototype.parseMedia;xC.prototype.setManifestType=xC.prototype.setManifestType;xC.prototype.setSequenceMode=xC.prototype.setSequenceMode;xC.prototype.parseInit=xC.prototype.parseInit;
1380
+ var yC=/^\s*\[([^\]]+)\]\r?\n([\s\S]*)/,zC=/^\s*([^:]+):\s*(.*)/,AC=/\s*,\s*/,EC=/^(\d+:)?(\d{1,2}):(\d{1,2}(?:[.]\d{1,3})?)?$/;re["text/x-ssa"]=function(){return new xC};function FC(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)?{Nd:c,ca:a}:null}function GC(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,codec:"mp4a.40."+e}}
1381
+ function HC(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}
1382
+ function IC(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,
1383
+ 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 JC(a){this.i=a;this.h=0;this.g=new Map}q=JC.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/aac"==a.toLowerCase().split(";")[0]?mb(this.convertCodecs("audio",a)):!1};q.convertCodecs=function(a,b){return"audio/aac"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="'+(je(b)||"mp4a.40.2")+'"':b};q.getOriginalMimeType=function(){return this.i};
1384
+ q.transmux=function(a,b,c,d){for(var e=zb(a),f=Yi(e),g=f.length;g<e.length&&!HC(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=GC(e,g);if(!f)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));b.audioSamplingRate=f.sampleRate;b.channelsCount=f.channelCount;for(var h=[];g<e.length;){var k=FC(e,g);if(!k)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));var l=k.Nd+k.ca;g+l<=e.length&&h.push({data:e.subarray(g+
1384
1385
  k.Nd,g+l),size:k.ca,duration:1024,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}});g+=l}e=f.sampleRate;a=Math.floor(a*e/1E3);d={id:b.id,type:"audio",codecs:f.codec,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:e,duration:d,$a:[],oa:new Uint8Array([]),wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.h,baseMediaDecodeTime:a,Ya:h},stream:b};d=new Uw([d]);c=b.id+"_"+c.i;this.g.has(c)?b=this.g.get(c):(b=$w(d),this.g.set(c,b));c=qx(d);this.h++;b=Ld(b,c);return Promise.resolve(b)};
1385
- S("shaka.transmuxer.AacTransmuxer",HC);HC.prototype.transmux=HC.prototype.transmux;HC.prototype.getOriginalMimeType=HC.prototype.getOriginalMimeType;HC.prototype.convertCodecs=HC.prototype.convertCodecs;HC.prototype.isSupported=HC.prototype.isSupported;HC.prototype.destroy=HC.prototype.destroy;jc("audio/aac",function(){return new HC("audio/aac")},rc);function IC(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,
1386
+ S("shaka.transmuxer.AacTransmuxer",JC);JC.prototype.transmux=JC.prototype.transmux;JC.prototype.getOriginalMimeType=JC.prototype.getOriginalMimeType;JC.prototype.convertCodecs=JC.prototype.convertCodecs;JC.prototype.isSupported=JC.prototype.isSupported;JC.prototype.destroy=JC.prototype.destroy;jc("audio/aac",function(){return new JC("audio/aac")},rc);function KC(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,
1386
1387
  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,oa:a,ca:e}}
1387
- function JC(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 KC(a){this.i=a;this.h=0;this.g=new Map}r=KC.prototype;r.destroy=function(){this.g.clear()};r.isSupported=function(a){return"audio/ac3"==a.toLowerCase().split(";")[0]?mb(this.convertCodecs("audio",a)):!1};r.convertCodecs=function(a,b){return"audio/ac3"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="ac-3"':b};r.getOriginalMimeType=function(){return this.i};
1388
- r.transmux=function(a,b,c,d){a=zb(a);for(var e=Yi(a),f=e.length;f<a.length&&!JC(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=IC(a,f);if(!l)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));b.audioSamplingRate=l.sampleRate;b.channelsCount=l.channelCount;e=l.sampleRate;h=l.oa;k.push({data:a.subarray(f,f+l.ca),size:l.ca,duration:1536,
1389
- cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}});f+=l.ca}a=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,$a:[],oa:h,wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.h,baseMediaDecodeTime:a,Ya:k},stream:b};d=new Uw([d]);c=b.id+"_"+c.i;this.g.has(c)?b=this.g.get(c):(b=$w(d),this.g.set(c,b));c=qx(d);this.h++;b=Ld(b,c);return Promise.resolve(b)};S("shaka.transmuxer.Ac3Transmuxer",KC);KC.prototype.transmux=KC.prototype.transmux;
1390
- KC.prototype.getOriginalMimeType=KC.prototype.getOriginalMimeType;KC.prototype.convertCodecs=KC.prototype.convertCodecs;KC.prototype.isSupported=KC.prototype.isSupported;KC.prototype.destroy=KC.prototype.destroy;jc("audio/ac3",function(){return new KC("audio/ac3")},rc);function LC(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,oa:a,ca:d}};function MC(a){this.i=a;this.h=0;this.g=new Map}r=MC.prototype;r.destroy=function(){this.g.clear()};r.isSupported=function(a){return"audio/ec3"==a.toLowerCase().split(";")[0]?mb(this.convertCodecs("audio",a)):!1};r.convertCodecs=function(a,b){return"audio/ec3"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="ec-3"':b};r.getOriginalMimeType=function(){return this.i};
1391
- r.transmux=function(a,b,c,d){a=zb(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=LC(a,f);if(!l)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));b.audioSamplingRate=l.sampleRate;b.channelsCount=l.channelCount;e=l.sampleRate;h=l.oa;k.push({data:a.subarray(f,f+l.ca),
1392
- size:l.ca,duration:1536,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}});f+=l.ca}a=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,$a:[],oa:h,wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.h,baseMediaDecodeTime:a,Ya:k},stream:b};d=new Uw([d]);c=b.id+"_"+c.i;this.g.has(c)?b=this.g.get(c):(b=$w(d),this.g.set(c,b));c=qx(d);this.h++;b=Ld(b,c);return Promise.resolve(b)};S("shaka.transmuxer.Ec3Transmuxer",MC);MC.prototype.transmux=MC.prototype.transmux;
1393
- MC.prototype.getOriginalMimeType=MC.prototype.getOriginalMimeType;MC.prototype.convertCodecs=MC.prototype.convertCodecs;MC.prototype.isSupported=MC.prototype.isSupported;MC.prototype.destroy=MC.prototype.destroy;jc("audio/ec3",function(){return new MC("audio/ec3")},rc);function NC(a){if(!a.length)return null;var b=a.find(function(u){return 7==u.type});a=a.find(function(u){return 8==u.type});if(!b||!a)return null;var c=new hj(b.data),d=pj(c);pj(c);pj(c);mj(c);if(OC.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?qj(c,16):qj(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;
1394
- oj(c)&&(k=V(c),l=V(c),m=V(c),n=V(c));e=d=1;if(oj(c)&&oj(c)){var q=pj(c),p=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2],w=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1];0<q&&16>=q?(d=p[q-1],e=w[q-1]):255===q&&(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],
1388
+ function LC(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 MC(a){this.i=a;this.h=0;this.g=new Map}q=MC.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/ac3"==a.toLowerCase().split(";")[0]?mb(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};
1389
+ q.transmux=function(a,b,c,d){a=zb(a);for(var e=Yi(a),f=e.length;f<a.length&&!LC(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=KC(a,f);if(!l)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));b.audioSamplingRate=l.sampleRate;b.channelsCount=l.channelCount;e=l.sampleRate;h=l.oa;k.push({data:a.subarray(f,f+l.ca),size:l.ca,duration:1536,
1390
+ cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}});f+=l.ca}a=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,$a:[],oa:h,wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.h,baseMediaDecodeTime:a,Ya:k},stream:b};d=new Uw([d]);c=b.id+"_"+c.i;this.g.has(c)?b=this.g.get(c):(b=$w(d),this.g.set(c,b));c=qx(d);this.h++;b=Ld(b,c);return Promise.resolve(b)};S("shaka.transmuxer.Ac3Transmuxer",MC);MC.prototype.transmux=MC.prototype.transmux;
1391
+ MC.prototype.getOriginalMimeType=MC.prototype.getOriginalMimeType;MC.prototype.convertCodecs=MC.prototype.convertCodecs;MC.prototype.isSupported=MC.prototype.isSupported;MC.prototype.destroy=MC.prototype.destroy;jc("audio/ac3",function(){return new MC("audio/ac3")},rc);function NC(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,oa:a,ca:d}};function OC(a){this.i=a;this.h=0;this.g=new Map}q=OC.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/ec3"==a.toLowerCase().split(";")[0]?mb(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};
1392
+ q.transmux=function(a,b,c,d){a=zb(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=NC(a,f);if(!l)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));b.audioSamplingRate=l.sampleRate;b.channelsCount=l.channelCount;e=l.sampleRate;h=l.oa;k.push({data:a.subarray(f,f+l.ca),
1393
+ size:l.ca,duration:1536,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}});f+=l.ca}a=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,$a:[],oa:h,wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.h,baseMediaDecodeTime:a,Ya:k},stream:b};d=new Uw([d]);c=b.id+"_"+c.i;this.g.has(c)?b=this.g.get(c):(b=$w(d),this.g.set(c,b));c=qx(d);this.h++;b=Ld(b,c);return Promise.resolve(b)};S("shaka.transmuxer.Ec3Transmuxer",OC);OC.prototype.transmux=OC.prototype.transmux;
1394
+ OC.prototype.getOriginalMimeType=OC.prototype.getOriginalMimeType;OC.prototype.convertCodecs=OC.prototype.convertCodecs;OC.prototype.isSupported=OC.prototype.isSupported;OC.prototype.destroy=OC.prototype.destroy;jc("audio/ec3",function(){return new OC("audio/ec3")},rc);function PC(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=pj(c);pj(c);pj(c);mj(c);if(QC.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?qj(c,16):qj(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;
1395
+ oj(c)&&(k=V(c),l=V(c),m=V(c),n=V(c));e=d=1;if(oj(c)&&oj(c)){var p=pj(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],
1395
1396
  k[5],255,225].concat(k,[1],b));return{height:c,width:f,wa:a,Ba:d,Ca:e}}
1396
- function PC(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=rj(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?
1397
- {data:Ld.apply(Dd,x(c)),jd:b}:null}var OC=[100,110,122,244,44,83,86,118,128,138,139,134];function QC(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=RC(b.fullData);a=SC(c.fullData);var f=TC(d.fullData);b=UC(b.fullData,c.fullData,d.fullData,{yf:e.yf,Wf:e.Wf,cf:a.cf,df:a.df,Xe:a.Xe,bf:a.bf,Ye:a.Ye,Ze:a.Ze,$e:a.$e,af:a.af,Re:a.Re,Se:a.Se,Te:a.Te,Ue:a.Ue,Ve:a.Ve,We:a.We,Ke:a.Ke,Yd:a.Yd,Ie:a.Ie,Ge:a.Ge,Fe:a.Fe,Bf:f.Bf});return{height:a.height,width:a.width,
1398
- wa:b,Ba:a.Ri,Ca:a.Qi}}function RC(a){var b=new hj(a,!0);pj(b);pj(b);kj(b,4);kj(b,2);kj(b,6);a=kj(b,3);b=oj(b);return{yf:a+1,Wf:b}}
1399
- function SC(a){a=new hj(a,!0);pj(a);pj(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=pj(a),m=pj(a),n=pj(a),q=pj(a),p=pj(a),w=pj(a),u=pj(a),v=pj(a),A=pj(a),z=pj(a),D=pj(a),y=[],B=[],C=0;C<f;C++)y.push(oj(a)),B.push(oj(a));if(0<f)for(C=f;8>C;C++)kj(a,2);for(C=0;C<f;C++)y[C]&&kj(a,88),B[C]&&pj(a);V(a);y=V(a);3==y&&kj(a,1);B=V(a);C=V(a);oj(a)&&(b+=V(a),c+=V(a),d+=V(a),e+=V(a));var E=V(a),G=V(a),L=V(a);if(oj(a))for(var K=0;K<=f;K++)V(a),V(a),V(a);else V(a),
1400
- V(a),V(a);V(a);V(a);V(a);V(a);V(a);V(a);if(oj(a)&&oj(a))for(K=0;4>K;K++)for(var I=0;I<(3===K?2:6);I++)if(oj(a)){var J=Math.min(64,1<<4+(K<<1));1<K&&nj(a);for(var N=0;N<J;N++)nj(a)}else V(a);oj(a);oj(a);oj(a)&&(pj(a),V(a),V(a),oj(a));K=V(a);for(J=I=0;J<K;J++)if(N=!1,0!==J&&(N=oj(a)),N){J===K&&V(a);oj(a);V(a);for(var M=N=0;M<=I;M++){var P=oj(a),R=!1;P||(R=oj(a));(P||R)&&N++}I=N}else{M=V(a);N=V(a);I=M+N;for(P=0;P<M;P++)V(a),oj(a);for(M=0;M<N;M++)V(a),oj(a)}if(oj(a))for(K=V(a),I=0;I<K;I++){for(J=0;J<
1401
- L+4;J++)kj(a,1);kj(a,1)}K=L=1;I=0;oj(a);oj(a);if(oj(a)){oj(a)&&(J=pj(a),N=[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<J&&16>=J?(L=N[J-1],K=M[J-1]):255===J&&(L=kj(a,16),K=kj(a,16)));oj(a)&&oj(a);oj(a)&&(kj(a,3),oj(a),oj(a)&&(pj(a),pj(a),pj(a)));oj(a)&&(V(a),V(a));oj(a);oj(a);oj(a);if(J=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;J=oj(a);N=oj(a);if(J||N){if(M=oj(a))pj(a),kj(a,5),oj(a),kj(a,5);kj(a,4);kj(a,4);M&&
1402
- kj(a,4);kj(a,5);kj(a,5);kj(a,5)}for(P=0;P<=f;P++){var Q=!0;R=1;oj(a)||(Q=oj(a));var X=!1;Q?V(a):X=oj(a);X||(R=V(a)+1);if(J){for(Q=0;Q<R;Q++)V(a),V(a),M&&(V(a),V(a));oj(a)}if(N){for(Q=0;Q<R;Q++)V(a),V(a),M&&(V(a),V(a));oj(a)}}}oj(a)&&(oj(a),oj(a),oj(a),I=V(a),V(a),V(a),V(a),V(a))}return{Xe:D,cf:g,df:h,bf:k,Ye:l,Ze:m,$e:n,af:q,Re:p,Se:w,Te:u,Ue:v,Ve:A,We:z,Yd:I,Ke:0,Ie:y,Ge:E,Fe:G,width:B-(b+c)*(1===y||2===y?2:1),height:C-(d+e)*(1===y?2:1),Ri:L,Qi:K}}
1403
- function TC(a){var b=new hj(a,!0);pj(b);pj(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{Bf:c}}
1404
- function UC(a,b,c,d){var e=new Uint8Array(23+(5+a.byteLength)+(5+b.byteLength)+(5+c.byteLength));e[0]=1;e[1]=(d.cf&3)<<6|(d.df?1:0)<<5|d.bf&31;e[2]=d.Ye;e[3]=d.Ze;e[4]=d.$e;e[5]=d.af;e[6]=d.Re;e[7]=d.Se;e[8]=d.Te;e[9]=d.Ue;e[10]=d.Ve;e[11]=d.We;e[12]=d.Xe;e[13]=240|(d.Yd&3840)>>8;e[14]=d.Yd&255;e[15]=252|d.Bf&3;e[16]=252|d.Ie&3;e[17]=248|d.Ge&7;e[18]=248|d.Fe&7;e[19]=0;e[20]=0;e[21]=(d.Ke&3)<<6|(d.yf&7)<<3|(d.Wf?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&
1405
- 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 VC(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*WC[14*(3===c?3-d:3===d?3:4)+e-1];f=XC[3*(3===c?0:2===c?1:2)+f];c=YC[c][d];var h=ZC[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,ca:k,Pi:8*c*h}}return null}
1406
- function $C(a,b){return 255===a[b]&&224===(a[b+1]&224)&&0!==(a[b+1]&6)}function aD(a,b){if(b+1<a.length&&$C(a,b)){var c=VC(a,b),d=4;c&&c.ca&&(d=c.ca);b+=d;return b===a.length||b+1<a.length&&$C(a,b)}return!1}
1407
- var WC=[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],XC=[44100,48E3,32E3,22050,24E3,16E3,11025,12E3,8E3],YC=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],ZC=[0,1,1,4];function bD(a){this.i=a;this.h=0;this.g=new Map}r=bD.prototype;r.destroy=function(){this.g.clear()};r.isSupported=function(a){return"audio/mpeg"==a.toLowerCase().split(";")[0]?mb(this.convertCodecs("audio",a)):!1};r.convertCodecs=function(a,b){return"audio/mpeg"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="mp3"':b};r.getOriginalMimeType=function(){return this.i};
1408
- r.transmux=function(a,b,c,d){for(var e=zb(a),f=Yi(e).length;f<e.length&&!aD(e,f);f++);var g;for(a=[];f<e.length;){var h=VC(e,f);if(!h)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));g||(g=h);f+h.ca<=e.length&&a.push({data:e.subarray(f,f+h.ca),size:h.ca,duration:1152,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}});f+=h.ca}if(!g)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));e=9E4*g.Pi/g.sampleRate*this.h;d={id:b.id,type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:g.sampleRate,
1409
- duration:d,$a:[],oa:new Uint8Array([]),wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.h,baseMediaDecodeTime:e,Ya:a},stream:b};d=new Uw([d]);c=b.id+"_"+c.i;this.g.has(c)?b=this.g.get(c):(b=$w(d),this.g.set(c,b));c=qx(d);this.h++;b=Ld(b,c);return Promise.resolve(b)};S("shaka.transmuxer.Mp3Transmuxer",bD);bD.prototype.transmux=bD.prototype.transmux;bD.prototype.getOriginalMimeType=bD.prototype.getOriginalMimeType;bD.prototype.convertCodecs=bD.prototype.convertCodecs;bD.prototype.isSupported=bD.prototype.isSupported;
1410
- bD.prototype.destroy=bD.prototype.destroy;jc("audio/mpeg",function(){return new bD("audio/mpeg")},rc);function cD(a){this.h=a;this.g=null}r=cD.prototype;r.destroy=function(){};r.isSupported=function(a){if("video/mp2t"!=a.toLowerCase().split(";")[0])return!1;var b=je(a).split(","),c=Sd("audio",b);b=Sd("video",b);return!c||b||"mp3"!=fe(c)?!1:mb(this.convertCodecs("audio",a))};r.convertCodecs=function(a,b){return"video/mp2t"==b.toLowerCase().split(";")[0]?"audio/mpeg":b};r.getOriginalMimeType=function(){return this.h};
1411
- r.transmux=function(a,b,c,d,e){this.g?this.g.clearData():this.g=new sj;a=zb(a);a=this.g.parse(a);if("mp3"!=a.Zc().audio||"audio"!=e)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));c=new Uint8Array([]);e=t(a.Tb());for(a=e.next();!a.done;a=e.next())if(a=a.value.data)for(b=0;b<a.length;)(d=VC(a,b))?(b+d.ca<=a.length&&(c=Ld(c,a.subarray(b,b+d.ca))),b+=d.ca):b++;return Promise.resolve(c)};S("shaka.transmuxer.MpegTsTransmuxer",cD);cD.prototype.transmux=cD.prototype.transmux;
1412
- cD.prototype.getOriginalMimeType=cD.prototype.getOriginalMimeType;cD.prototype.convertCodecs=cD.prototype.convertCodecs;cD.prototype.isSupported=cD.prototype.isSupported;cD.prototype.destroy=cD.prototype.destroy;jc("video/mp2t",function(){return new cD("video/mp2t")},qc);/*
1397
+ function RC(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=rj(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?
1398
+ {data:Ld.apply(Dd,x(c)),jd:b}:null}var QC=[100,110,122,244,44,83,86,118,128,138,139,134];function SC(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=TC(b.fullData);a=UC(c.fullData);var f=VC(d.fullData);b=WC(b.fullData,c.fullData,d.fullData,{yf:e.yf,Wf:e.Wf,cf:a.cf,df:a.df,Xe:a.Xe,bf:a.bf,Ye:a.Ye,Ze:a.Ze,$e:a.$e,af:a.af,Re:a.Re,Se:a.Se,Te:a.Te,Ue:a.Ue,Ve:a.Ve,We:a.We,Ke:a.Ke,Yd:a.Yd,Ie:a.Ie,Ge:a.Ge,Fe:a.Fe,Bf:f.Bf});return{height:a.height,width:a.width,
1399
+ wa:b,Ba:a.Ri,Ca:a.Qi}}function TC(a){var b=new hj(a,!0);pj(b);pj(b);kj(b,4);kj(b,2);kj(b,6);a=kj(b,3);b=oj(b);return{yf:a+1,Wf:b}}
1400
+ function UC(a){a=new hj(a,!0);pj(a);pj(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=pj(a),m=pj(a),n=pj(a),p=pj(a),r=pj(a),u=pj(a),v=pj(a),w=pj(a),A=pj(a),z=pj(a),D=pj(a),y=[],B=[],C=0;C<f;C++)y.push(oj(a)),B.push(oj(a));if(0<f)for(C=f;8>C;C++)kj(a,2);for(C=0;C<f;C++)y[C]&&kj(a,88),B[C]&&pj(a);V(a);y=V(a);3==y&&kj(a,1);B=V(a);C=V(a);oj(a)&&(b+=V(a),c+=V(a),d+=V(a),e+=V(a));var E=V(a),G=V(a),L=V(a);if(oj(a))for(var K=0;K<=f;K++)V(a),V(a),V(a);else V(a),
1401
+ V(a),V(a);V(a);V(a);V(a);V(a);V(a);V(a);if(oj(a)&&oj(a))for(K=0;4>K;K++)for(var I=0;I<(3===K?2:6);I++)if(oj(a)){var J=Math.min(64,1<<4+(K<<1));1<K&&nj(a);for(var M=0;M<J;M++)nj(a)}else V(a);oj(a);oj(a);oj(a)&&(pj(a),V(a),V(a),oj(a));K=V(a);for(J=I=0;J<K;J++)if(M=!1,0!==J&&(M=oj(a)),M){J===K&&V(a);oj(a);V(a);for(var N=M=0;N<=I;N++){var P=oj(a),R=!1;P||(R=oj(a));(P||R)&&M++}I=M}else{N=V(a);M=V(a);I=N+M;for(P=0;P<N;P++)V(a),oj(a);for(N=0;N<M;N++)V(a),oj(a)}if(oj(a))for(K=V(a),I=0;I<K;I++){for(J=0;J<
1402
+ L+4;J++)kj(a,1);kj(a,1)}K=L=1;I=0;oj(a);oj(a);if(oj(a)){oj(a)&&(J=pj(a),M=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2],N=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1],0<J&&16>=J?(L=M[J-1],K=N[J-1]):255===J&&(L=kj(a,16),K=kj(a,16)));oj(a)&&oj(a);oj(a)&&(kj(a,3),oj(a),oj(a)&&(pj(a),pj(a),pj(a)));oj(a)&&(V(a),V(a));oj(a);oj(a);oj(a);if(J=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))){N=!1;J=oj(a);M=oj(a);if(J||M){if(N=oj(a))pj(a),kj(a,5),oj(a),kj(a,5);kj(a,4);kj(a,4);N&&
1403
+ kj(a,4);kj(a,5);kj(a,5);kj(a,5)}for(P=0;P<=f;P++){var Q=!0;R=1;oj(a)||(Q=oj(a));var X=!1;Q?V(a):X=oj(a);X||(R=V(a)+1);if(J){for(Q=0;Q<R;Q++)V(a),V(a),N&&(V(a),V(a));oj(a)}if(M){for(Q=0;Q<R;Q++)V(a),V(a),N&&(V(a),V(a));oj(a)}}}oj(a)&&(oj(a),oj(a),oj(a),I=V(a),V(a),V(a),V(a),V(a))}return{Xe:D,cf:g,df:h,bf:k,Ye:l,Ze:m,$e:n,af:p,Re:r,Se:u,Te:v,Ue:w,Ve:A,We:z,Yd:I,Ke:0,Ie:y,Ge:E,Fe:G,width:B-(b+c)*(1===y||2===y?2:1),height:C-(d+e)*(1===y?2:1),Ri:L,Qi:K}}
1404
+ function VC(a){var b=new hj(a,!0);pj(b);pj(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{Bf:c}}
1405
+ function WC(a,b,c,d){var e=new Uint8Array(23+(5+a.byteLength)+(5+b.byteLength)+(5+c.byteLength));e[0]=1;e[1]=(d.cf&3)<<6|(d.df?1:0)<<5|d.bf&31;e[2]=d.Ye;e[3]=d.Ze;e[4]=d.$e;e[5]=d.af;e[6]=d.Re;e[7]=d.Se;e[8]=d.Te;e[9]=d.Ue;e[10]=d.Ve;e[11]=d.We;e[12]=d.Xe;e[13]=240|(d.Yd&3840)>>8;e[14]=d.Yd&255;e[15]=252|d.Bf&3;e[16]=252|d.Ie&3;e[17]=248|d.Ge&7;e[18]=248|d.Fe&7;e[19]=0;e[20]=0;e[21]=(d.Ke&3)<<6|(d.yf&7)<<3|(d.Wf?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&
1406
+ 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 XC(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*YC[14*(3===c?3-d:3===d?3:4)+e-1];f=ZC[3*(3===c?0:2===c?1:2)+f];c=$C[c][d];var h=aD[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,ca:k,Pi:8*c*h}}return null}
1407
+ function bD(a,b){return 255===a[b]&&224===(a[b+1]&224)&&0!==(a[b+1]&6)}function cD(a,b){if(b+1<a.length&&bD(a,b)){var c=XC(a,b),d=4;c&&c.ca&&(d=c.ca);b+=d;return b===a.length||b+1<a.length&&bD(a,b)}return!1}
1408
+ var YC=[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],ZC=[44100,48E3,32E3,22050,24E3,16E3,11025,12E3,8E3],$C=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],aD=[0,1,1,4];function dD(a){this.i=a;this.h=0;this.g=new Map}q=dD.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/mpeg"==a.toLowerCase().split(";")[0]?mb(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};
1409
+ q.transmux=function(a,b,c,d){for(var e=zb(a),f=Yi(e).length;f<e.length&&!cD(e,f);f++);var g;for(a=[];f<e.length;){var h=XC(e,f);if(!h)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));g||(g=h);f+h.ca<=e.length&&a.push({data:e.subarray(f,f+h.ca),size:h.ca,duration:1152,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}});f+=h.ca}if(!g)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));e=9E4*g.Pi/g.sampleRate*this.h;d={id:b.id,type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:g.sampleRate,
1410
+ duration:d,$a:[],oa:new Uint8Array([]),wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.h,baseMediaDecodeTime:e,Ya:a},stream:b};d=new Uw([d]);c=b.id+"_"+c.i;this.g.has(c)?b=this.g.get(c):(b=$w(d),this.g.set(c,b));c=qx(d);this.h++;b=Ld(b,c);return Promise.resolve(b)};S("shaka.transmuxer.Mp3Transmuxer",dD);dD.prototype.transmux=dD.prototype.transmux;dD.prototype.getOriginalMimeType=dD.prototype.getOriginalMimeType;dD.prototype.convertCodecs=dD.prototype.convertCodecs;dD.prototype.isSupported=dD.prototype.isSupported;
1411
+ dD.prototype.destroy=dD.prototype.destroy;jc("audio/mpeg",function(){return new dD("audio/mpeg")},rc);function eD(a){this.h=a;this.g=null}q=eD.prototype;q.destroy=function(){};q.isSupported=function(a){if("video/mp2t"!=a.toLowerCase().split(";")[0])return!1;var b=je(a).split(","),c=Sd("audio",b);b=Sd("video",b);return!c||b||"mp3"!=fe(c)?!1:mb(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};
1412
+ q.transmux=function(a,b,c,d,e){this.g?this.g.clearData():this.g=new sj;a=zb(a);a=this.g.parse(a);if("mp3"!=a.$c().audio||"audio"!=e)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));c=new Uint8Array([]);e=t(a.Tb());for(a=e.next();!a.done;a=e.next())if(a=a.value.data)for(b=0;b<a.length;)(d=XC(a,b))?(b+d.ca<=a.length&&(c=Ld(c,a.subarray(b,b+d.ca))),b+=d.ca):b++;return Promise.resolve(c)};S("shaka.transmuxer.MpegTsTransmuxer",eD);eD.prototype.transmux=eD.prototype.transmux;
1413
+ eD.prototype.getOriginalMimeType=eD.prototype.getOriginalMimeType;eD.prototype.convertCodecs=eD.prototype.convertCodecs;eD.prototype.isSupported=eD.prototype.isSupported;eD.prototype.destroy=eD.prototype.destroy;jc("video/mp2t",function(){return new eD("video/mp2t")},qc);/*
1413
1414
  @license
1414
1415
  MSS Transmuxer
1415
1416
  Copyright 2015 Dash Industry Forum
1416
1417
  SPDX-License-Identifier: BSD-3-Clause
1417
1418
  */
1418
- function dD(a){this.h=a;(this.g=bv.get("ISOBoxer")())&&eD(this)}
1419
- function eD(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",
1419
+ function fD(a){this.h=a;(this.g=bv.get("ISOBoxer")())&&gD(this)}
1420
+ function gD(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",
1420
1421
  "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",
1421
- "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]!==fD[d]&&(c=!1);c&&(this._parsing&&(this.type="sepiff"),b.call(this))})}r=dD.prototype;r.destroy=function(){};
1422
- r.isSupported=function(a,b){var c=a.startsWith("mss/");if(!this.g||!c)return!1;if(b)return mb(this.convertCodecs(b,a));b=this.convertCodecs("audio",a);a=this.convertCodecs("video",a);return mb(b)||mb(a)};r.convertCodecs=function(a,b){return b.replace("mss/","")};r.getOriginalMimeType=function(){return this.h};
1423
- r.transmux=function(a,b,c){if(!c)return Promise.resolve(zb(a));if(!b.mssPrivateData)return Promise.reject(new T(2,3,3020,c?c.M()[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");
1424
- 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 q=e.fetch("saio");if(null===q){q=this.g.createFullBox("saio",h);q.version=0;q.flags=0;q.entry_count=1;q.offset=[0];var p=this.g.createFullBox("saiz",h);p.version=0;p.flags=0;p.sample_count=n.sample_count;p.default_sample_info_size=0;p.sample_info_size=[];if(n.flags&2)for(d=0;d<n.sample_count;d+=1)p.sample_info_size[d]=10+6*n.entry[d].NumberOfEntries;else p.default_sample_info_size=
1425
- 8}}f.flags&=16777214;f.flags|=131072;k.flags|=1;var w=e.fetch("moof");k.data_offset=w.getLength()+8;var u=e.fetch("saio");null!==u&&(u.offset[0]=gD(w,"traf")+gD(h,"senc")+16);var v=zb(e.write());return Promise.resolve(v)}catch(A){return A instanceof T?Promise.reject(A):Promise.reject(new T(2,3,3022,c?c.M()[0]:null))}};function gD(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}S("shaka.transmuxer.MssTransmuxer",dD);dD.prototype.transmux=dD.prototype.transmux;
1426
- dD.prototype.getOriginalMimeType=dD.prototype.getOriginalMimeType;dD.prototype.convertCodecs=dD.prototype.convertCodecs;dD.prototype.isSupported=dD.prototype.isSupported;dD.prototype.destroy=dD.prototype.destroy;var fD=new Uint8Array([162,57,79,82,90,155,79,20,162,68,108,66,124,100,141,244]);jc("mss/audio/mp4",function(){return new dD("mss/audio/mp4")},rc);jc("mss/video/mp4",function(){return new dD("mss/video/mp4")},rc);function hD(a){this.l=a;this.g=0;this.i=new Map;this.h=this.j=null}r=hD.prototype;r.destroy=function(){this.i.clear();this.h&&this.h.destroy()};
1427
- r.isSupported=function(a,b){if("video/mp2t"!=a.toLowerCase().split(";")[0])return!1;var c=a;b&&(c=this.convertCodecs(b,a));var d=je(c).split(",");c=Sd("audio",d);d=Sd("video",d);if(c&&(c=fe(c),!iD.includes(c))||d&&(c=fe(d),!jD.includes(c)))return!1;if(b)return mb(this.convertCodecs(b,a));b=this.convertCodecs("audio",a);a=this.convertCodecs("video",a);return mb(b)||mb(a)};
1428
- r.convertCodecs=function(a,b){return"video/mp2t"==b.toLowerCase().split(";")[0]?(b=je(b).replace("mp4a.40.34","mp3").split(",").map(function(c){return bf(c,"audio/mp4")}).map(af).join(","),"audio"==a?'audio/mp4; codecs="'+b+'"':'video/mp4; codecs="'+b+'"'):b};r.getOriginalMimeType=function(){return this.l};
1429
- r.transmux=function(a,b,c,d,e){var f=zb(a);if("audio"==e&&!Gj(f)){for(var g=Yi(f),h=g.length;h<f.length;h++)if(aD(f,h))return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));for(h=g.length;h<f.length;h++)if(FC(f,h))return this.h||(this.h=new HC("audio/aac")),this.h.transmux(a,b,c,d,e);return Promise.reject(new T(2,3,3018,c?c.M()[0]:null))}this.j?this.j.clearData():this.j=new sj;var k=this.j.parse(f),l=[],m=k.Zc();try{var n=null;if("video"==e){switch(m.video){case "avc":var q=[],p=null,w=[],u=k.Gc();
1430
- if(!u.length)throw new T(2,3,3023,c?c.M()[0]:null);for(var v=0;v<u.length;v++){var A=u[v],z=A.nalus;w.push.apply(w,x(z));var D=PC(z);if(D){null==p&&(p=A.dts);var y=void 0;y=v+1<u.length?(u[v+1].dts||0)-(A.dts||0):1<u.length?(A.dts||0)-(u[v-1].dts||0):9E4*(c.endTime-c.startTime);q.push({data:D.data,size:D.data.byteLength,duration:y,cb:Math.round((A.pts||0)-(A.dts||0)),flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:D.jd?2:1,hb:D.jd?0:1}})}}var B=NC(w);if(!B||null==p)throw new T(2,3,3018,c?c.M()[0]:null);b.height=B.height;
1431
- b.width=B.width;n={id:b.id,type:"video",codecs:"avc1",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:9E4,duration:d,$a:[],oa:new Uint8Array([]),wa:B.wa,Ba:B.Ba,Ca:B.Ca,data:{rb:this.g,baseMediaDecodeTime:p,Ya:q},stream:b};break;case "hvc":var C=[],E=null,G=[],L=k.Gc();if(!L.length)throw new T(2,3,3023,c?c.M()[0]:null);for(var K=0;K<L.length;K++){var I=L[K],J=I.nalus;G.push.apply(G,x(J));for(var N=!1,M=[],P=!1,R=t(J),Q=R.next();!Q.done;Q=R.next()){var X=Q.value;switch(X.type){case 1:case 0:var W=
1432
- P=!0;break;case 19:case 20:case 21:N=W=P=!0;break;case 32:W=!0;break;case 33:W=!0;break;case 34:W=!0;break;case 35:P=W=!0;break;case 39:case 40:W=!0;break;default:W=!1}if(P&&W){var ya=X.fullData.byteLength,xa=new Uint8Array(4);xa[0]=ya>>24&255;xa[1]=ya>>16&255;xa[2]=ya>>8&255;xa[3]=ya&255;M.push(xa);M.push(X.fullData)}}var Ba=M.length?{data:Ld.apply(Dd,x(M)),jd:N}:null;if(Ba){null==E&&null!=I.dts&&(E=I.dts);var Ga=void 0;Ga=K+1<L.length?(L[K+1].dts||0)-(I.dts||0):1<L.length?(I.dts||0)-(L[K-1].dts||
1433
- 0):9E4*(c.endTime-c.startTime);C.push({data:Ba.data,size:Ba.data.byteLength,duration:Ga,cb:Math.round((I.pts||0)-(I.dts||0)),flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:Ba.jd?2:1,hb:Ba.jd?0:1}})}}var bb=QC(G);if(!bb||null==E)throw new T(2,3,3018,c?c.M()[0]:null);b.height=bb.height;b.width=bb.width;n={id:b.id,type:"video",codecs:"hvc1",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:9E4,duration:d,$a:[],oa:new Uint8Array([]),wa:bb.wa,Ba:bb.Ba,Ca:bb.Ca,data:{rb:this.g,baseMediaDecodeTime:E,Ya:C},stream:b}}n&&
1434
- (l.push(n),n=null)}if("audio"==e){switch(m.audio){case "aac":for(var Za=[],Ta,Ca=null,nc=t(k.Tb()),Ra=nc.next();!Ra.done;Ra=nc.next()){var lb=Ra.value,Rb=lb.data;if(Rb){var Nc=0;Ta=EC(Rb,Nc);if(!Ta)throw new T(2,3,3018,c?c.M()[0]:null);b.audioSamplingRate=Ta.sampleRate;b.channelsCount=Ta.channelCount;null==Ca&&null!==lb.pts&&(Ca=lb.pts);for(;Nc<Rb.length;){var le=DC(Rb,Nc);if(le){var me=le.Nd+le.ca;Nc+me<=Rb.length&&Za.push({data:Rb.subarray(Nc+le.Nd,Nc+me),size:le.ca,duration:1024,cb:0,flags:{gb:0,
1435
- Xa:0,Wa:0,Ua:0,Va:2,hb:0}});Nc+=me}else Nc++}}}if(!Ta||null==Ca){if(!k.Gc().length)throw new T(2,3,3018,c?c.M()[0]:null);Ca=9E4*c.startTime;var ne=Sd("audio",b.codecs.split(","));if(!ne||!b.channelsCount||!b.audioSamplingRate)throw new T(2,3,3018,c?c.M()[0]:null);Ta={sampleRate:b.audioSamplingRate,channelCount:b.channelsCount,codec:ne};var Jd=GC(ne,b.channelsCount);if(!Jd)throw new T(2,3,3018,c?c.M()[0]:null);for(var Li=Ca+9E4*(c.endTime-c.startTime),Kd=Ca;Kd<Li;)Za.push({data:Jd,size:Jd.byteLength,
1436
- duration:1024,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}}),Kd+=1024/Ta.sampleRate*9E4}var Mi=Ta.sampleRate,Ni=Ca/9E4*Mi;n={id:b.id,type:"audio",codecs:Ta.codec,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:Mi,duration:d,$a:[],oa:new Uint8Array([]),wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.g,baseMediaDecodeTime:Ni,Ya:Za},stream:b};break;case "ac3":for(var Gg=[],oe=0,oc=new Uint8Array([]),uj=null,Nu=t(k.Tb()),Um=Nu.next();!Um.done;Um=Nu.next()){var Vm=Um.value,Wm=Vm.data;null==uj&&null!==
1437
- Vm.pts&&(uj=Vm.pts);for(var yf=0;yf<Wm.length;){var Nd=IC(Wm,yf);Nd?(b.audioSamplingRate=Nd.sampleRate,b.channelsCount=Nd.channelCount,oe=Nd.sampleRate,oc=Nd.oa,Gg.push({data:Wm.subarray(yf,yf+Nd.ca),size:Nd.ca,duration:1536,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}}),yf+=Nd.ca):yf++}}if(0==oe||0==oc.byteLength||null==uj)throw new T(2,3,3018,c?c.M()[0]:null);var zD=uj/9E4*oe;n={id:b.id,type:"audio",codecs:"ac-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:oe,duration:d,$a:[],oa:oc,wa:new Uint8Array([]),
1438
- Ba:0,Ca:0,data:{rb:this.g,baseMediaDecodeTime:zD,Ya:Gg},stream:b};break;case "ec3":for(var Ou=[],vj=0,Xm=new Uint8Array([]),wj=null,Pu=t(k.Tb()),Ym=Pu.next();!Ym.done;Ym=Pu.next()){var Zm=Ym.value,$m=Zm.data;null==wj&&null!==Zm.pts&&(wj=Zm.pts);for(var zf=0;zf<$m.length;){var Od=LC($m,zf);Od?(b.audioSamplingRate=Od.sampleRate,b.channelsCount=Od.channelCount,vj=Od.sampleRate,Xm=Od.oa,Ou.push({data:$m.subarray(zf,zf+Od.ca),size:Od.ca,duration:1536,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}}),zf+=Od.ca):
1439
- zf++}}if(0==vj||0==Xm.byteLength||null==wj)throw new T(2,3,3018,c?c.M()[0]:null);var AD=wj/9E4*vj;n={id:b.id,type:"audio",codecs:"ec-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:vj,duration:d,$a:[],oa:Xm,wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.g,baseMediaDecodeTime:AD,Ya:Ou},stream:b};break;case "mp3":for(var Qu=[],xj,yj=null,Ru=t(k.Tb()),an=Ru.next();!an.done;an=Ru.next()){var bn=an.value,Ug=bn.data;if(Ug){null==yj&&null!==bn.pts&&(yj=bn.pts);for(var se=0;se<Ug.length;){var Af=VC(Ug,
1440
- se);Af?(xj||(xj=Af),se+Af.ca<=Ug.length&&Qu.push({data:Ug.subarray(se,se+Af.ca),size:Af.ca,duration:1152,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}}),se+=Af.ca):se++}}}if(!xj||null==yj)throw new T(2,3,3018,c?c.M()[0]:null);var Su=xj.sampleRate,BD=yj/9E4*Su;n={id:b.id,type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:Su,duration:d,$a:[],oa:new Uint8Array([]),wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.g,baseMediaDecodeTime:BD,Ya:Qu},stream:b};break;case "opus":var Tu=
1422
+ "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]!==hD[d]&&(c=!1);c&&(this._parsing&&(this.type="sepiff"),b.call(this))})}q=fD.prototype;q.destroy=function(){};
1423
+ q.isSupported=function(a,b){var c=a.startsWith("mss/");if(!this.g||!c)return!1;if(b)return mb(this.convertCodecs(b,a));b=this.convertCodecs("audio",a);a=this.convertCodecs("video",a);return mb(b)||mb(a)};q.convertCodecs=function(a,b){return b.replace("mss/","")};q.getOriginalMimeType=function(){return this.h};
1424
+ q.transmux=function(a,b,c){if(!c)return Promise.resolve(zb(a));if(!b.mssPrivateData)return Promise.reject(new T(2,3,3020,c?c.M()[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");
1425
+ 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=
1426
+ 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]=iD(u,"traf")+iD(h,"senc")+16);var w=zb(e.write());return Promise.resolve(w)}catch(A){return A instanceof T?Promise.reject(A):Promise.reject(new T(2,3,3022,c?c.M()[0]:null))}};function iD(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}S("shaka.transmuxer.MssTransmuxer",fD);fD.prototype.transmux=fD.prototype.transmux;
1427
+ fD.prototype.getOriginalMimeType=fD.prototype.getOriginalMimeType;fD.prototype.convertCodecs=fD.prototype.convertCodecs;fD.prototype.isSupported=fD.prototype.isSupported;fD.prototype.destroy=fD.prototype.destroy;var hD=new Uint8Array([162,57,79,82,90,155,79,20,162,68,108,66,124,100,141,244]);jc("mss/audio/mp4",function(){return new fD("mss/audio/mp4")},rc);jc("mss/video/mp4",function(){return new fD("mss/video/mp4")},rc);function jD(a){this.l=a;this.g=0;this.i=new Map;this.h=this.j=null}q=jD.prototype;q.destroy=function(){this.i.clear();this.h&&this.h.destroy()};
1428
+ 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=je(c).split(",");c=Sd("audio",d);d=Sd("video",d);if(c&&(c=fe(c),!kD.includes(c))||d&&(c=fe(d),!lD.includes(c)))return!1;if(b)return mb(this.convertCodecs(b,a));b=this.convertCodecs("audio",a);a=this.convertCodecs("video",a);return mb(b)||mb(a)};
1429
+ q.convertCodecs=function(a,b){return"video/mp2t"==b.toLowerCase().split(";")[0]?(b=je(b).replace("mp4a.40.34","mp3").split(",").map(function(c){return bf(c,"audio/mp4")}).map(af).join(","),"audio"==a?'audio/mp4; codecs="'+b+'"':'video/mp4; codecs="'+b+'"'):b};q.getOriginalMimeType=function(){return this.l};
1430
+ q.transmux=function(a,b,c,d,e){var f=zb(a);if("audio"==e&&!Gj(f)){for(var g=Yi(f),h=g.length;h<f.length;h++)if(cD(f,h))return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));for(h=g.length;h<f.length;h++)if(HC(f,h))return this.h||(this.h=new JC("audio/aac")),this.h.transmux(a,b,c,d,e);return Promise.reject(new T(2,3,3018,c?c.M()[0]:null))}this.j?this.j.clearData():this.j=new sj;var k=this.j.parse(f),l=[],m=k.$c();try{var n=null;if("video"==e){switch(m.video){case "avc":var p=[],r=null,u=[],v=k.Gc();
1431
+ if(!v.length)throw new T(2,3,3023,c?c.M()[0]:null);for(var w=0;w<v.length;w++){var A=v[w],z=A.nalus;u.push.apply(u,x(z));var D=RC(z);if(D){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:D.data,size:D.data.byteLength,duration:y,cb:Math.round((A.pts||0)-(A.dts||0)),flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:D.jd?2:1,hb:D.jd?0:1}})}}var B=PC(u);if(!B||null==r)throw new T(2,3,3018,c?c.M()[0]:null);b.height=B.height;
1432
+ b.width=B.width;n={id:b.id,type:"video",codecs:"avc1",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:9E4,duration:d,$a:[],oa:new Uint8Array([]),wa:B.wa,Ba:B.Ba,Ca:B.Ca,data:{rb:this.g,baseMediaDecodeTime:r,Ya:p},stream:b};break;case "hvc":var C=[],E=null,G=[],L=k.Gc();if(!L.length)throw new T(2,3,3023,c?c.M()[0]:null);for(var K=0;K<L.length;K++){var I=L[K],J=I.nalus;G.push.apply(G,x(J));for(var M=!1,N=[],P=!1,R=t(J),Q=R.next();!Q.done;Q=R.next()){var X=Q.value;switch(X.type){case 1:case 0:var W=
1433
+ P=!0;break;case 19:case 20:case 21:M=W=P=!0;break;case 32:W=!0;break;case 33:W=!0;break;case 34:W=!0;break;case 35:P=W=!0;break;case 39:case 40:W=!0;break;default:W=!1}if(P&&W){var ya=X.fullData.byteLength,xa=new Uint8Array(4);xa[0]=ya>>24&255;xa[1]=ya>>16&255;xa[2]=ya>>8&255;xa[3]=ya&255;N.push(xa);N.push(X.fullData)}}var Ba=N.length?{data:Ld.apply(Dd,x(N)),jd:M}:null;if(Ba){null==E&&null!=I.dts&&(E=I.dts);var Ga=void 0;Ga=K+1<L.length?(L[K+1].dts||0)-(I.dts||0):1<L.length?(I.dts||0)-(L[K-1].dts||
1434
+ 0):9E4*(c.endTime-c.startTime);C.push({data:Ba.data,size:Ba.data.byteLength,duration:Ga,cb:Math.round((I.pts||0)-(I.dts||0)),flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:Ba.jd?2:1,hb:Ba.jd?0:1}})}}var bb=SC(G);if(!bb||null==E)throw new T(2,3,3018,c?c.M()[0]:null);b.height=bb.height;b.width=bb.width;n={id:b.id,type:"video",codecs:"hvc1",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:9E4,duration:d,$a:[],oa:new Uint8Array([]),wa:bb.wa,Ba:bb.Ba,Ca:bb.Ca,data:{rb:this.g,baseMediaDecodeTime:E,Ya:C},stream:b}}n&&
1435
+ (l.push(n),n=null)}if("audio"==e){switch(m.audio){case "aac":for(var Za=[],Ta,Ca=null,nc=t(k.Tb()),Ra=nc.next();!Ra.done;Ra=nc.next()){var lb=Ra.value,Rb=lb.data;if(Rb){var Nc=0;Ta=GC(Rb,Nc);if(!Ta)throw new T(2,3,3018,c?c.M()[0]:null);b.audioSamplingRate=Ta.sampleRate;b.channelsCount=Ta.channelCount;null==Ca&&null!==lb.pts&&(Ca=lb.pts);for(;Nc<Rb.length;){var le=FC(Rb,Nc);if(le){var me=le.Nd+le.ca;Nc+me<=Rb.length&&Za.push({data:Rb.subarray(Nc+le.Nd,Nc+me),size:le.ca,duration:1024,cb:0,flags:{gb:0,
1436
+ Xa:0,Wa:0,Ua:0,Va:2,hb:0}});Nc+=me}else Nc++}}}if(!Ta||null==Ca){if(!k.Gc().length)throw new T(2,3,3018,c?c.M()[0]:null);Ca=9E4*c.startTime;var ne=Sd("audio",b.codecs.split(","));if(!ne||!b.channelsCount||!b.audioSamplingRate)throw new T(2,3,3018,c?c.M()[0]:null);Ta={sampleRate:b.audioSamplingRate,channelCount:b.channelsCount,codec:ne};var Jd=IC(ne,b.channelsCount);if(!Jd)throw new T(2,3,3018,c?c.M()[0]:null);for(var Li=Ca+9E4*(c.endTime-c.startTime),Kd=Ca;Kd<Li;)Za.push({data:Jd,size:Jd.byteLength,
1437
+ duration:1024,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}}),Kd+=1024/Ta.sampleRate*9E4}var Mi=Ta.sampleRate,Ni=Ca/9E4*Mi;n={id:b.id,type:"audio",codecs:Ta.codec,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:Mi,duration:d,$a:[],oa:new Uint8Array([]),wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.g,baseMediaDecodeTime:Ni,Ya:Za},stream:b};break;case "ac3":for(var Gg=[],oe=0,oc=new Uint8Array([]),uj=null,Mu=t(k.Tb()),Um=Mu.next();!Um.done;Um=Mu.next()){var Vm=Um.value,Wm=Vm.data;null==uj&&null!==
1438
+ Vm.pts&&(uj=Vm.pts);for(var yf=0;yf<Wm.length;){var Nd=KC(Wm,yf);Nd?(b.audioSamplingRate=Nd.sampleRate,b.channelsCount=Nd.channelCount,oe=Nd.sampleRate,oc=Nd.oa,Gg.push({data:Wm.subarray(yf,yf+Nd.ca),size:Nd.ca,duration:1536,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}}),yf+=Nd.ca):yf++}}if(0==oe||0==oc.byteLength||null==uj)throw new T(2,3,3018,c?c.M()[0]:null);var BD=uj/9E4*oe;n={id:b.id,type:"audio",codecs:"ac-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:oe,duration:d,$a:[],oa:oc,wa:new Uint8Array([]),
1439
+ Ba:0,Ca:0,data:{rb:this.g,baseMediaDecodeTime:BD,Ya:Gg},stream:b};break;case "ec3":for(var Nu=[],vj=0,Xm=new Uint8Array([]),wj=null,Ou=t(k.Tb()),Ym=Ou.next();!Ym.done;Ym=Ou.next()){var Zm=Ym.value,$m=Zm.data;null==wj&&null!==Zm.pts&&(wj=Zm.pts);for(var zf=0;zf<$m.length;){var Od=NC($m,zf);Od?(b.audioSamplingRate=Od.sampleRate,b.channelsCount=Od.channelCount,vj=Od.sampleRate,Xm=Od.oa,Nu.push({data:$m.subarray(zf,zf+Od.ca),size:Od.ca,duration:1536,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}}),zf+=Od.ca):
1440
+ zf++}}if(0==vj||0==Xm.byteLength||null==wj)throw new T(2,3,3018,c?c.M()[0]:null);var CD=wj/9E4*vj;n={id:b.id,type:"audio",codecs:"ec-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:vj,duration:d,$a:[],oa:Xm,wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.g,baseMediaDecodeTime:CD,Ya:Nu},stream:b};break;case "mp3":for(var Pu=[],xj,yj=null,Qu=t(k.Tb()),an=Qu.next();!an.done;an=Qu.next()){var bn=an.value,Ug=bn.data;if(Ug){null==yj&&null!==bn.pts&&(yj=bn.pts);for(var se=0;se<Ug.length;){var Af=XC(Ug,
1441
+ se);Af?(xj||(xj=Af),se+Af.ca<=Ug.length&&Pu.push({data:Ug.subarray(se,se+Af.ca),size:Af.ca,duration:1152,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}}),se+=Af.ca):se++}}}if(!xj||null==yj)throw new T(2,3,3018,c?c.M()[0]:null);var Ru=xj.sampleRate,DD=yj/9E4*Ru;n={id:b.id,type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:Ru,duration:d,$a:[],oa:new Uint8Array([]),wa:new Uint8Array([]),Ba:0,Ca:0,data:{rb:this.g,baseMediaDecodeTime:DD,Ya:Pu},stream:b};break;case "opus":var Su=
1441
1442
  [],zj=null,Xc=k.F;if(!Xc)throw new T(2,3,3018,c?c.M()[0]:null);var Bb=[];switch(Xc.Ch){case 1:case 2:Bb=[0];break;case 0:Bb=[255,1,1,0,1];break;case 128:Bb=[255,2,0,0,1];break;case 3:Bb=[1,2,1,0,2,1];break;case 4:Bb=[1,2,2,0,1,2,3];break;case 5:Bb=[1,3,2,0,4,1,2,3];break;case 6:Bb=[1,4,2,0,4,1,2,3,5];break;case 7:Bb=[1,4,2,0,4,1,2,3,5,6];break;case 8:Bb=[1,5,3,0,6,1,2,3,4,5,7];break;case 130:Bb=[1,1,2,0,1];break;case 131:Bb=[1,1,3,0,1,2];break;case 132:Bb=[1,1,4,0,1,2,3];break;case 133:Bb=[1,1,5,
1442
- 0,1,2,3,4];break;case 134:Bb=[1,1,6,0,1,2,3,4,5];break;case 135:Bb=[1,1,7,0,1,2,3,4,5,6];break;case 136:Bb=[1,1,8,0,1,2,3,4,5,6,7]}var Uu=new Uint8Array([0,Xc.channelCount,0,0,Xc.sampleRate>>>24&255,Xc.sampleRate>>>17&255,Xc.sampleRate>>>8&255,Xc.sampleRate>>>0&255,0,0].concat(x(Bb)));for(var Vu=Xc.sampleRate,Wu=t(k.Tb()),cn=Wu.next();!cn.done;cn=Wu.next()){var dn=cn.value,Bf=dn.data;null==zj&&null!==dn.pts&&(zj=dn.pts);for(var Vg=0;Vg<Bf.length;){for(var CD=0!==(Bf[Vg+1]&16),DD=0!==(Bf[Vg+1]&8),
1443
- vd=Vg+2,Aj=0;255===Bf[vd];)Aj+=255,vd+=1;Aj+=Bf[vd];vd+=1;vd+=CD?2:0;vd+=DD?2:0;var Xu=Bf.slice(vd,vd+Aj);Tu.push({data:Xu,size:Xu.byteLength,duration:960,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}});Vg=vd+Aj}}if(0==Uu.byteLength||null==zj)throw new T(2,3,3018,c?c.M()[0]:null);b.audioSamplingRate=Xc.sampleRate;b.channelsCount=Xc.channelCount;var ED=zj/9E4*Vu;n={id:b.id,type:"audio",codecs:"opus",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:Vu,duration:d,$a:[],oa:Uu,wa:new Uint8Array([]),Ba:0,
1444
- Ca:0,data:{rb:this.g,baseMediaDecodeTime:ED,Ya:Tu},stream:b}}n&&(l.push(n),n=null)}}catch(en){return en&&3023==en.code?Promise.resolve(new Uint8Array([])):Promise.reject(en)}if(!l.length)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));var Yu=new Uw(l),fn=b.id+"_"+c.i;if(this.i.has(fn))var gn=this.i.get(fn);else gn=$w(Yu),this.i.set(fn,gn);var FD=qx(Yu);this.g++;var GD=Ld(gn,FD);return Promise.resolve(GD)};S("shaka.transmuxer.TsTransmuxer",hD);hD.prototype.transmux=hD.prototype.transmux;
1445
- hD.prototype.getOriginalMimeType=hD.prototype.getOriginalMimeType;hD.prototype.convertCodecs=hD.prototype.convertCodecs;hD.prototype.isSupported=hD.prototype.isSupported;hD.prototype.destroy=hD.prototype.destroy;var iD=["aac","ac-3","ec-3","mp3","opus"],jD=["avc","hevc"];jc("video/mp2t",function(){return new hD("video/mp2t")},pc);/*
1443
+ 0,1,2,3,4];break;case 134:Bb=[1,1,6,0,1,2,3,4,5];break;case 135:Bb=[1,1,7,0,1,2,3,4,5,6];break;case 136:Bb=[1,1,8,0,1,2,3,4,5,6,7]}var Tu=new Uint8Array([0,Xc.channelCount,0,0,Xc.sampleRate>>>24&255,Xc.sampleRate>>>17&255,Xc.sampleRate>>>8&255,Xc.sampleRate>>>0&255,0,0].concat(x(Bb)));for(var Uu=Xc.sampleRate,Vu=t(k.Tb()),cn=Vu.next();!cn.done;cn=Vu.next()){var dn=cn.value,Bf=dn.data;null==zj&&null!==dn.pts&&(zj=dn.pts);for(var Vg=0;Vg<Bf.length;){for(var ED=0!==(Bf[Vg+1]&16),FD=0!==(Bf[Vg+1]&8),
1444
+ vd=Vg+2,Aj=0;255===Bf[vd];)Aj+=255,vd+=1;Aj+=Bf[vd];vd+=1;vd+=ED?2:0;vd+=FD?2:0;var Wu=Bf.slice(vd,vd+Aj);Su.push({data:Wu,size:Wu.byteLength,duration:960,cb:0,flags:{gb:0,Xa:0,Wa:0,Ua:0,Va:2,hb:0}});Vg=vd+Aj}}if(0==Tu.byteLength||null==zj)throw new T(2,3,3018,c?c.M()[0]:null);b.audioSamplingRate=Xc.sampleRate;b.channelsCount=Xc.channelCount;var GD=zj/9E4*Uu;n={id:b.id,type:"audio",codecs:"opus",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:Uu,duration:d,$a:[],oa:Tu,wa:new Uint8Array([]),Ba:0,
1445
+ Ca:0,data:{rb:this.g,baseMediaDecodeTime:GD,Ya:Su},stream:b}}n&&(l.push(n),n=null)}}catch(en){return en&&3023==en.code?Promise.resolve(new Uint8Array([])):Promise.reject(en)}if(!l.length)return Promise.reject(new T(2,3,3018,c?c.M()[0]:null));var Xu=new Uw(l),fn=b.id+"_"+c.i;if(this.i.has(fn))var gn=this.i.get(fn);else gn=$w(Xu),this.i.set(fn,gn);var HD=qx(Xu);this.g++;var ID=Ld(gn,HD);return Promise.resolve(ID)};S("shaka.transmuxer.TsTransmuxer",jD);jD.prototype.transmux=jD.prototype.transmux;
1446
+ jD.prototype.getOriginalMimeType=jD.prototype.getOriginalMimeType;jD.prototype.convertCodecs=jD.prototype.convertCodecs;jD.prototype.isSupported=jD.prototype.isSupported;jD.prototype.destroy=jD.prototype.destroy;var kD=["aac","ac-3","ec-3","mp3","opus"],lD=["avc","hevc"];jc("video/mp2t",function(){return new jD("video/mp2t")},pc);/*
1446
1447
  @license
1447
1448
  EME Encryption Scheme Polyfill
1448
1449
  Copyright 2019 Google LLC
1449
1450
  SPDX-License-Identifier: Apache-2.0
1450
1451
  */
1451
- function kD(){}var lD;
1452
- function mD(){lD||navigator.emeEncryptionSchemePolyfilled?console.debug("EmeEncryptionSchemePolyfill: Already installed."):navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration?(lD=navigator.requestMediaKeySystemAccess,console.debug("EmeEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.requestMediaKeySystemAccess=nD,navigator.emeEncryptionSchemePolyfilled=!0):console.debug("EmeEncryptionSchemePolyfill: EME not found")}
1453
- function nD(a,b){var c=this,d;return O(function(e){if(1==e.g)return console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess'),F(e,lD.call(c,a,b),2);d=e.h;if(oD(d))return console.debug("EmeEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.requestMediaKeySystemAccess=lD,e.return(d);console.debug("EmeEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");navigator.requestMediaKeySystemAccess=pD;return e.return(pD.call(c,
1452
+ function mD(){}var nD;
1453
+ function oD(){nD||navigator.emeEncryptionSchemePolyfilled?console.debug("EmeEncryptionSchemePolyfill: Already installed."):navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration?(nD=navigator.requestMediaKeySystemAccess,console.debug("EmeEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.requestMediaKeySystemAccess=pD,navigator.emeEncryptionSchemePolyfilled=!0):console.debug("EmeEncryptionSchemePolyfill: EME not found")}
1454
+ function pD(a,b){var c=this,d;return O(function(e){if(1==e.g)return console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess'),F(e,nD.call(c,a,b),2);d=e.h;if(qD(d))return console.debug("EmeEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.requestMediaKeySystemAccess=nD,e.return(d);console.debug("EmeEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");navigator.requestMediaKeySystemAccess=rD;return e.return(rD.call(c,
1454
1455
  a,b))})}
1455
- function pD(a,b){var c=this,d,e,f,g,h,k,l,m,n,q,p,w;return O(function(u){if(1==u.g){console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess');d=qD(a);e=[];f=t(b);for(g=f.next();!g.done;g=f.next())h=g.value,k=rD(h.videoCapabilities,d),l=rD(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."),
1456
- n.name="NotSupportedError",n.code=DOMException.NOT_SUPPORTED_ERR,n;return F(u,lD.call(c,a,e),2)}q=u.h;w=p=null;e[0]&&(e[0].videoCapabilities&&(p=e[0].videoCapabilities[0].encryptionScheme),e[0].audioCapabilities&&(w=e[0].audioCapabilities[0].encryptionScheme));return u.return(new sD(q,p,w))})}function rD(a,b){return a?a.filter(function(c){return tD(c.encryptionScheme,b)}):a}S("EmeEncryptionSchemePolyfill",kD);kD.install=mD;function uD(){}var vD;
1457
- function wD(){vD||navigator.mediaCapabilitiesEncryptionSchemePolyfilled?console.debug("McEncryptionSchemePolyfill: Already installed."):navigator.mediaCapabilities?(vD=navigator.mediaCapabilities.decodingInfo,console.debug("McEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.mediaCapabilities.decodingInfo=xD,navigator.mediaCapabilitiesEncryptionSchemePolyfilled=!0):console.debug("McEncryptionSchemePolyfill: MediaCapabilities not found")}
1458
- function xD(a){var b=this,c,d;return O(function(e){switch(e.g){case 1:return console.assert(b==navigator.mediaCapabilities,'bad "this" for decodingInfo'),F(e,vD.call(b,a),2);case 2:c=e.h;if(!a.keySystemConfiguration)return e.return(c);if((d=c.keySystemAccess)&&oD(d))return console.debug("McEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.mediaCapabilities.decodingInfo=vD,e.return(c);console.debug("McEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");
1459
- navigator.mediaCapabilities.decodingInfo=yD;if(d){e.u(3);break}return F(e,HD(a),4);case 4:return c.keySystemAccess=e.h,e.return(c);case 3:return e.return(yD.call(b,a))}})}
1460
- function yD(a){var b=this,c,d,e,f,g,h,k;return O(function(l){switch(l.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=qD(f),h={powerEfficient:!1,smooth:!1,supported:!1,keySystemAccess:null,configuration:a},tD(d,g)&&tD(c,g))?F(l,vD.call(b,a),2):l.return(h);case 2:k=l.h;if(k.keySystemAccess){k.keySystemAccess=
1461
- new sD(k.keySystemAccess,c,d);l.u(3);break}if(!a.keySystemConfiguration){l.u(3);break}return F(l,HD(a),5);case 5:k.keySystemAccess=l.h;case 3:return l.return(k)}})}
1462
- function HD(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};
1463
- f.length&&(e.audioCapabilities=f);g.length&&(e.videoCapabilities=g);b=e;return F(d,navigator.requestMediaKeySystemAccess(a.keySystemConfiguration.keySystem,[b]),2)}c=d.h;return d.return(c)})}S("McEncryptionSchemePolyfill",uD);uD.install=wD;function sD(a,b,c){this.g=a;this.i=b||null;this.h=c||null;this.keySystem=a.keySystem}
1464
- sD.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};sD.prototype.createMediaKeys=function(){return this.g.createMediaKeys()};
1465
- function qD(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 oD(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}
1466
- function tD(a,b){if(!a||a==b)return!0;if("cbcs"==a||"cbcs-1-9"==a)if(ID||JD)return!0;return!1}function KD(){}function Pz(){mD();wD()}S("EncryptionSchemePolyfills",KD);KD.install=Pz;var JD=navigator.userAgent.includes("CrKey"),ID=100<=parseInt(navigator.userAgent.split("Firefox/").pop(),10);"undefined"!==typeof module&&module.exports&&(module.exports=KD);}).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})();
1456
+ function rD(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=sD(a);e=[];f=t(b);for(g=f.next();!g.done;g=f.next())h=g.value,k=tD(h.videoCapabilities,d),l=tD(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."),
1457
+ n.name="NotSupportedError",n.code=DOMException.NOT_SUPPORTED_ERR,n;return F(v,nD.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 uD(p,r,u))})}function tD(a,b){return a?a.filter(function(c){return vD(c.encryptionScheme,b)}):a}S("EmeEncryptionSchemePolyfill",mD);mD.install=oD;function wD(){}var xD;
1458
+ function yD(){xD||navigator.mediaCapabilitiesEncryptionSchemePolyfilled?console.debug("McEncryptionSchemePolyfill: Already installed."):navigator.mediaCapabilities?(xD=navigator.mediaCapabilities.decodingInfo,console.debug("McEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.mediaCapabilities.decodingInfo=zD,navigator.mediaCapabilitiesEncryptionSchemePolyfilled=!0):console.debug("McEncryptionSchemePolyfill: MediaCapabilities not found")}
1459
+ function zD(a){var b=this,c,d;return O(function(e){switch(e.g){case 1:return console.assert(b==navigator.mediaCapabilities,'bad "this" for decodingInfo'),F(e,xD.call(b,a),2);case 2:c=e.h;if(!a.keySystemConfiguration)return e.return(c);if((d=c.keySystemAccess)&&qD(d))return console.debug("McEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.mediaCapabilities.decodingInfo=xD,e.return(c);console.debug("McEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");
1460
+ navigator.mediaCapabilities.decodingInfo=AD;if(d){e.u(3);break}return F(e,JD(a),4);case 4:return c.keySystemAccess=e.h,e.return(c);case 3:return e.return(AD.call(b,a))}})}
1461
+ function AD(a){var b=this,c,d,e,f,g,h,k;return O(function(l){switch(l.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=sD(f),h={powerEfficient:!1,smooth:!1,supported:!1,keySystemAccess:null,configuration:a},vD(d,g)&&vD(c,g))?F(l,xD.call(b,a),2):l.return(h);case 2:k=l.h;if(k.keySystemAccess){k.keySystemAccess=
1462
+ new uD(k.keySystemAccess,c,d);l.u(3);break}if(!a.keySystemConfiguration){l.u(3);break}return F(l,JD(a),5);case 5:k.keySystemAccess=l.h;case 3:return l.return(k)}})}
1463
+ 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};
1464
+ f.length&&(e.audioCapabilities=f);g.length&&(e.videoCapabilities=g);b=e;return F(d,navigator.requestMediaKeySystemAccess(a.keySystemConfiguration.keySystem,[b]),2)}c=d.h;return d.return(c)})}S("McEncryptionSchemePolyfill",wD);wD.install=yD;function uD(a,b,c){this.g=a;this.i=b||null;this.h=c||null;this.keySystem=a.keySystem}
1465
+ uD.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};uD.prototype.createMediaKeys=function(){return this.g.createMediaKeys()};
1466
+ function sD(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 qD(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}
1467
+ function vD(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 Pz(){oD();yD()}S("EncryptionSchemePolyfills",MD);MD.install=Pz;var LD=navigator.userAgent.includes("CrKey"),KD=100<=parseInt(navigator.userAgent.split("Firefox/").pop(),10);"undefined"!==typeof module&&module.exports&&(module.exports=MD);}).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})();
1467
1468
 
1468
1469
  //# sourceMappingURL=shaka-player.compiled.map