shaka-player 3.3.16 → 3.3.17

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 (37) hide show
  1. package/.github/workflows/selenium-lab-tests.yaml +22 -0
  2. package/CHANGELOG.md +16 -0
  3. package/dist/locales.js +30 -30
  4. package/dist/shaka-player.compiled.d.ts +5 -0
  5. package/dist/shaka-player.compiled.debug.d.ts +5 -0
  6. package/dist/shaka-player.compiled.debug.externs.js +4 -0
  7. package/dist/shaka-player.compiled.debug.js +80 -75
  8. package/dist/shaka-player.compiled.debug.map +3 -3
  9. package/dist/shaka-player.compiled.externs.js +4 -0
  10. package/dist/shaka-player.compiled.js +255 -252
  11. package/dist/shaka-player.compiled.map +3 -3
  12. package/dist/shaka-player.ui.d.ts +5 -0
  13. package/dist/shaka-player.ui.debug.d.ts +5 -0
  14. package/dist/shaka-player.ui.debug.externs.js +4 -0
  15. package/dist/shaka-player.ui.debug.js +94 -89
  16. package/dist/shaka-player.ui.debug.map +3 -3
  17. package/dist/shaka-player.ui.externs.js +4 -0
  18. package/dist/shaka-player.ui.js +288 -285
  19. package/dist/shaka-player.ui.map +3 -3
  20. package/externs/shaka/text.js +7 -0
  21. package/lib/dash/segment_template.js +17 -5
  22. package/lib/hls/hls_parser.js +1 -1
  23. package/lib/player.js +1 -1
  24. package/lib/polyfill/media_capabilities.js +1 -0
  25. package/lib/text/cue.js +6 -0
  26. package/lib/text/ui_text_displayer.js +1 -5
  27. package/lib/text/vtt_text_parser.js +256 -91
  28. package/lib/util/platform.js +8 -0
  29. package/package.json +1 -1
  30. package/support.html +1 -0
  31. package/test/dash/dash_parser_manifest_unit.js +0 -36
  32. package/test/test/util/layout_tests.js +433 -0
  33. package/test/test/util/util.js +0 -120
  34. package/test/{ui → text}/text_displayer_layout_unit.js +59 -235
  35. package/test/text/ui_text_displayer_unit.js +2 -4
  36. package/test/text/vtt_text_parser_unit.js +127 -6
  37. package/test/text/web_vtt_layout_integration.js +528 -0
@@ -16,45 +16,45 @@ ha("Symbol.iterator",function(a){if(a)return a;a=Symbol("Symbol.iterator");for(v
16
16
  function t(a){var b="undefined"!=typeof Symbol&&Symbol.iterator&&a[Symbol.iterator];return b?b.call(a):{next:ca(a)}}function ja(a){if(!(a instanceof Array)){a=t(a);for(var b,c=[];!(b=a.next()).done;)c.push(b.value);a=c}return a}var ka="function"==typeof Object.create?Object.create:function(a){function b(){}b.prototype=a;return new b},la;
17
17
  if("function"==typeof Object.setPrototypeOf)la=Object.setPrototypeOf;else{var ma;a:{var na={a:!0},oa={};try{oa.__proto__=na;ma=oa.a;break a}catch(a){}ma=!1}la=ma?function(a,b){a.__proto__=b;if(a.__proto__!==b)throw new TypeError(a+" is not extensible");return a}:null}var pa=la;
18
18
  function qa(a,b){a.prototype=ka(b.prototype);a.prototype.constructor=a;if(pa)pa(a,b);else for(var c in b)if("prototype"!=c)if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);d&&Object.defineProperty(a,c,d)}else a[c]=b[c];a.Sg=b.prototype}function ra(){this.o=!1;this.l=null;this.h=void 0;this.g=1;this.j=this.m=0;this.u=this.i=null}function sa(a){if(a.o)throw new TypeError("Generator is already running");a.o=!0}ra.prototype.s=function(a){this.h=a};
19
- function ta(a,b){a.i={je:b,qe:!0};a.g=a.m||a.j}ra.prototype["return"]=function(a){this.i={"return":a};this.g=this.j};function u(a,b,c){a.g=c;return{value:b}}ra.prototype.B=function(a){this.g=a};function A(a){a.g=0}function C(a,b,c){a.m=b;void 0!=c&&(a.j=c)}function ua(a){a.m=0;a.j=2}function va(a,b){a.g=b;a.m=0}function E(a){a.m=0;var b=a.i.je;a.i=null;return b}function wa(a){a.u=[a.i];a.m=0;a.j=0}
20
- function ya(a,b){var c=a.u.splice(0)[0];(c=a.i=a.i||c)?c.qe?a.g=a.m||a.j:void 0!=c.B&&a.j<c.B?(a.g=c.B,a.i=null):a.g=a.j:a.g=b}function za(a){this.g=new ra;this.h=a}function Aa(a,b){sa(a.g);var c=a.g.l;if(c)return Ba(a,"return"in c?c["return"]:function(d){return{value:d,done:!0}},b,a.g["return"]);a.g["return"](b);return Ca(a)}
19
+ function ta(a,b){a.i={ke:b,re:!0};a.g=a.m||a.j}ra.prototype["return"]=function(a){this.i={"return":a};this.g=this.j};function u(a,b,c){a.g=c;return{value:b}}ra.prototype.B=function(a){this.g=a};function A(a){a.g=0}function C(a,b,c){a.m=b;void 0!=c&&(a.j=c)}function ua(a){a.m=0;a.j=2}function va(a,b){a.g=b;a.m=0}function E(a){a.m=0;var b=a.i.ke;a.i=null;return b}function wa(a){a.u=[a.i];a.m=0;a.j=0}
20
+ function ya(a,b){var c=a.u.splice(0)[0];(c=a.i=a.i||c)?c.re?a.g=a.m||a.j:void 0!=c.B&&a.j<c.B?(a.g=c.B,a.i=null):a.g=a.j:a.g=b}function za(a){this.g=new ra;this.h=a}function Aa(a,b){sa(a.g);var c=a.g.l;if(c)return Ba(a,"return"in c?c["return"]:function(d){return{value:d,done:!0}},b,a.g["return"]);a.g["return"](b);return Ca(a)}
21
21
  function Ba(a,b,c,d){try{var e=b.call(a.g.l,c);if(!(e instanceof Object))throw new TypeError("Iterator result "+e+" is not an object");if(!e.done)return a.g.o=!1,e;var f=e.value}catch(g){return a.g.l=null,ta(a.g,g),Ca(a)}a.g.l=null;d.call(a.g,f);return Ca(a)}
22
- function Ca(a){for(;a.g.g;)try{var b=a.h(a.g);if(b)return a.g.o=!1,{value:b.value,done:!1}}catch(c){a.g.h=void 0,ta(a.g,c)}a.g.o=!1;if(a.g.i){b=a.g.i;a.g.i=null;if(b.qe)throw b.je;return{value:b["return"],done:!0}}return{value:void 0,done:!0}}
22
+ function Ca(a){for(;a.g.g;)try{var b=a.h(a.g);if(b)return a.g.o=!1,{value:b.value,done:!1}}catch(c){a.g.h=void 0,ta(a.g,c)}a.g.o=!1;if(a.g.i){b=a.g.i;a.g.i=null;if(b.re)throw b.ke;return{value:b["return"],done:!0}}return{value:void 0,done:!0}}
23
23
  function Ea(a){this.next=function(b){sa(a.g);a.g.l?b=Ba(a,a.g.l.next,b,a.g.s):(a.g.s(b),b=Ca(a));return b};this["throw"]=function(b){sa(a.g);a.g.l?b=Ba(a,a.g.l["throw"],b,a.g.s):(ta(a.g,b),b=Ca(a));return b};this["return"]=function(b){return Aa(a,b)};this[Symbol.iterator]=function(){return this}}
24
24
  function Ga(a){function b(d){return a.next(d)}function c(d){return a["throw"](d)}return new Promise(function(d,e){function f(g){g.done?d(g.value):Promise.resolve(g.value).then(b,c).then(f,e)}f(a.next())})}function L(a){return Ga(new Ea(new za(a)))}function Ha(){for(var a=Number(this),b=[],c=a;c<arguments.length;c++)b[c-a]=arguments[c];return b}
25
25
  ha("Promise",function(a){function b(g){this.h=0;this.i=void 0;this.g=[];this.o=!1;var h=this.j();try{g(h.resolve,h.reject)}catch(k){h.reject(k)}}function c(){this.g=null}function d(g){return g instanceof b?g:new b(function(h){h(g)})}if(a)return a;c.prototype.h=function(g){if(null==this.g){this.g=[];var h=this;this.i(function(){h.l()})}this.g.push(g)};var e=fa.setTimeout;c.prototype.i=function(g){e(g,0)};c.prototype.l=function(){for(;this.g&&this.g.length;){var g=this.g;this.g=[];for(var h=0;h<g.length;++h){var k=
26
26
  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.I(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.D(g):this.m(g)}};
27
27
  b.prototype.D=function(g){var h=void 0;try{h=g.then}catch(k){this.l(k);return}"function"==typeof h?this.L(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.u()};b.prototype.G=function(){var g=this;e(function(){if(g.C()){var h=fa.console;"undefined"!==typeof h&&h.error(g.i)}},1)};b.prototype.C=
28
28
  function(){if(this.o)return!1;var g=fa.CustomEvent,h=fa.Event,k=fa.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=fa.document.createEvent("CustomEvent"),g.initCustomEvent("unhandledrejection",!1,!0,g));g.promise=this;g.reason=this.i;return k(g)};b.prototype.u=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;
29
- b.prototype.I=function(g){var h=this.j();g.zc(h.resolve,h.reject)};b.prototype.L=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,q){return"function"==typeof p?function(v){try{l(p(v))}catch(y){m(y)}}:q}var l,m,n=new b(function(p,q){l=p;m=q});this.zc(k(g,l),k(h,m));return n};b.prototype["catch"]=function(g){return this.then(void 0,g)};b.prototype.zc=function(g,h){function k(){switch(l.h){case 1:g(l.i);break;case 2:h(l.i);
30
- 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).zc(h,k)})};b.all=function(g){var h=t(g),k=h.next();return k.done?d([]):new b(function(l,m){function n(v){return function(y){p[v]=y;q--;0==q&&l(p)}}var p=[],q=0;do p.push(void 0),q++,d(k.value).zc(n(p.length-1),m),k=h.next();
31
- while(!k.done)})};return b});function Ja(a,b){return Object.prototype.hasOwnProperty.call(a,b)}
32
- ha("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;da(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({}),
33
- 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)&&
34
- Ja(k,g)&&Ja(k[g],this.g)};b.prototype["delete"]=function(k){return d(k)&&Ja(k,g)&&Ja(k[g],this.g)?delete k[g][this.g]:!1};return b});
35
- ha("Map",function(a){function b(){var h={};return h.Ra=h.next=h.head=h}function c(h,k){var l=h.g;return ia(function(){if(l){for(;l.head!=h.g;)l=l.Ra;for(;l.next!=l.head;)return l=l.next,{done:!1,value:k(l)};l=null}return{done:!0,value:void 0}})}function d(h,k){var l=k&&typeof k;"object"==l||"function"==l?f.has(k)?l=f.get(k):(l=""+ ++g,f.set(k,l)):l="p_"+k;var m=h.h[l];if(m&&Ja(h.h,l))for(var n=0;n<m.length;n++){var p=m[n];if(k!==k&&p.key!==p.key||k===p.key)return{id:l,list:m,index:n,ia:p}}return{id:l,
29
+ b.prototype.I=function(g){var h=this.j();g.zc(h.resolve,h.reject)};b.prototype.L=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,q){return"function"==typeof p?function(v){try{l(p(v))}catch(w){m(w)}}:q}var l,m,n=new b(function(p,q){l=p;m=q});this.zc(k(g,l),k(h,m));return n};b.prototype["catch"]=function(g){return this.then(void 0,g)};b.prototype.zc=function(g,h){function k(){switch(l.h){case 1:g(l.i);break;case 2:h(l.i);
30
+ 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).zc(h,k)})};b.all=function(g){var h=t(g),k=h.next();return k.done?d([]):new b(function(l,m){function n(v){return function(w){p[v]=w;q--;0==q&&l(p)}}var p=[],q=0;do p.push(void 0),q++,d(k.value).zc(n(p.length-1),m),k=h.next();
31
+ while(!k.done)})};return b});function Ia(a,b){return Object.prototype.hasOwnProperty.call(a,b)}
32
+ ha("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(!Ia(k,g)){var l=new c;da(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({}),
33
+ 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(!Ia(k,g))throw Error("WeakMap key fail: "+k);k[g][this.g]=l;return this};b.prototype.get=function(k){return d(k)&&Ia(k,g)?k[g][this.g]:void 0};b.prototype.has=function(k){return d(k)&&
34
+ Ia(k,g)&&Ia(k[g],this.g)};b.prototype["delete"]=function(k){return d(k)&&Ia(k,g)&&Ia(k[g],this.g)?delete k[g][this.g]:!1};return b});
35
+ ha("Map",function(a){function b(){var h={};return h.Sa=h.next=h.head=h}function c(h,k){var l=h.g;return ia(function(){if(l){for(;l.head!=h.g;)l=l.Sa;for(;l.next!=l.head;)return l=l.next,{done:!1,value:k(l)};l=null}return{done:!0,value:void 0}})}function d(h,k){var l=k&&typeof k;"object"==l||"function"==l?f.has(k)?l=f.get(k):(l=""+ ++g,f.set(k,l)):l="p_"+k;var m=h.h[l];if(m&&Ia(h.h,l))for(var n=0;n<m.length;n++){var p=m[n];if(k!==k&&p.key!==p.key||k===p.key)return{id:l,list:m,index:n,ia:p}}return{id:l,
36
36
  list:m,index:-1,ia:void 0}}function e(h){this.h={};this.g=b();this.size=0;if(h){h=t(h);for(var k;!(k=h.next()).done;)k=k.value,this.set(k[0],k[1])}}if(function(){if(!a||"function"!=typeof a||!a.prototype.entries||"function"!=typeof Object.seal)return!1;try{var h=Object.seal({x:4}),k=new a(t([[h,"s"]]));if("s"!=k.get(h)||1!=k.size||k.get({x:4})||k.set({x:4},"t")!=k||2!=k.size)return!1;var l=k.entries(),m=l.next();if(m.done||m.value[0]!=h||"s"!=m.value[1])return!1;m=l.next();return m.done||4!=m.value[0].x||
37
- "t"!=m.value[1]||!l.next().done?!1:!0}catch(n){return!1}}())return a;var f=new WeakMap;e.prototype.set=function(h,k){h=0===h?0:h;var l=d(this,h);l.list||(l.list=this.h[l.id]=[]);l.ia?l.ia.value=k:(l.ia={next:this.g,Ra:this.g.Ra,head:this.g,key:h,value:k},l.list.push(l.ia),this.g.Ra.next=l.ia,this.g.Ra=l.ia,this.size++);return this};e.prototype["delete"]=function(h){h=d(this,h);return h.ia&&h.list?(h.list.splice(h.index,1),h.list.length||delete this.h[h.id],h.ia.Ra.next=h.ia.next,h.ia.next.Ra=h.ia.Ra,
38
- h.ia.head=null,this.size--,!0):!1};e.prototype.clear=function(){this.h={};this.g=this.g.Ra=b();this.size=0};e.prototype.has=function(h){return!!d(this,h).ia};e.prototype.get=function(h){return(h=d(this,h).ia)&&h.value};e.prototype.entries=function(){return c(this,function(h){return[h.key,h.value]})};e.prototype.keys=function(){return c(this,function(h){return h.key})};e.prototype.values=function(){return c(this,function(h){return h.value})};e.prototype.forEach=function(h,k){for(var l=this.entries(),
37
+ "t"!=m.value[1]||!l.next().done?!1:!0}catch(n){return!1}}())return a;var f=new WeakMap;e.prototype.set=function(h,k){h=0===h?0:h;var l=d(this,h);l.list||(l.list=this.h[l.id]=[]);l.ia?l.ia.value=k:(l.ia={next:this.g,Sa:this.g.Sa,head:this.g,key:h,value:k},l.list.push(l.ia),this.g.Sa.next=l.ia,this.g.Sa=l.ia,this.size++);return this};e.prototype["delete"]=function(h){h=d(this,h);return h.ia&&h.list?(h.list.splice(h.index,1),h.list.length||delete this.h[h.id],h.ia.Sa.next=h.ia.next,h.ia.next.Sa=h.ia.Sa,
38
+ h.ia.head=null,this.size--,!0):!1};e.prototype.clear=function(){this.h={};this.g=this.g.Sa=b();this.size=0};e.prototype.has=function(h){return!!d(this,h).ia};e.prototype.get=function(h){return(h=d(this,h).ia)&&h.value};e.prototype.entries=function(){return c(this,function(h){return[h.key,h.value]})};e.prototype.keys=function(){return c(this,function(h){return h.key})};e.prototype.values=function(){return c(this,function(h){return h.value})};e.prototype.forEach=function(h,k){for(var l=this.entries(),
39
39
  m;!(m=l.next()).done;)m=m.value,h.call(k,m[1],m[0],this)};e.prototype[Symbol.iterator]=e.prototype.entries;var g=0;return e});
40
40
  ha("Set",function(a){function b(c){this.g=new Map;if(c){c=t(c);for(var d;!(d=c.next()).done;)this.add(d.value)}this.size=this.g.size}if(function(){if(!a||"function"!=typeof a||!a.prototype.entries||"function"!=typeof Object.seal)return!1;try{var c=Object.seal({x:4}),d=new a(t([c]));if(!d.has(c)||1!=d.size||d.add(c)!=d||1!=d.size||d.add({x:4})!=d||2!=d.size)return!1;var e=d.entries(),f=e.next();if(f.done||f.value[0]!=c||f.value[1]!=c)return!1;f=e.next();return f.done||f.value[0]==c||4!=f.value[0].x||
41
41
  f.value[1]!=f.value[0]?!1:e.next().done}catch(g){return!1}}())return a;b.prototype.add=function(c){c=0===c?0:c;this.g.set(c,c);this.size=this.g.size;return this};b.prototype["delete"]=function(c){c=this.g["delete"](c);this.size=this.g.size;return c};b.prototype.clear=function(){this.g.clear();this.size=0};b.prototype.has=function(c){return this.g.has(c)};b.prototype.entries=function(){return this.g.entries()};b.prototype.values=function(){return this.g.values()};b.prototype.keys=b.prototype.values;
42
- b.prototype[Symbol.iterator]=b.prototype.values;b.prototype.forEach=function(c,d){var e=this;this.g.forEach(function(f){return c.call(d,f,f,e)})};return b});function Ka(a,b,c){a instanceof String&&(a=String(a));for(var d=a.length,e=0;e<d;e++){var f=a[e];if(b.call(c,f,e,a))return{oe:e,v:f}}return{oe:-1,v:void 0}}ha("Array.prototype.findIndex",function(a){return a?a:function(b,c){return Ka(this,b,c).oe}});ha("Object.is",function(a){return a?a:function(b,c){return b===c?0!==b||1/b===1/c:b!==b&&c!==c}});
42
+ b.prototype[Symbol.iterator]=b.prototype.values;b.prototype.forEach=function(c,d){var e=this;this.g.forEach(function(f){return c.call(d,f,f,e)})};return b});function Ka(a,b,c){a instanceof String&&(a=String(a));for(var d=a.length,e=0;e<d;e++){var f=a[e];if(b.call(c,f,e,a))return{pe:e,v:f}}return{pe:-1,v:void 0}}ha("Array.prototype.findIndex",function(a){return a?a:function(b,c){return Ka(this,b,c).pe}});ha("Object.is",function(a){return a?a:function(b,c){return b===c?0!==b||1/b===1/c:b!==b&&c!==c}});
43
43
  ha("Array.prototype.includes",function(a){return a?a:function(b,c){var d=this;d instanceof String&&(d=String(d));var e=d.length,f=c||0;for(0>f&&(f=Math.max(f+e,0));f<e;f++){var g=d[f];if(g===b||Object.is(g,b))return!0}return!1}});function La(a,b,c){if(null==a)throw new TypeError("The 'this' value for String.prototype."+c+" must not be null or undefined");if(b instanceof RegExp)throw new TypeError("First argument to String.prototype."+c+" must not be a regular expression");return a+""}
44
44
  ha("String.prototype.includes",function(a){return a?a:function(b,c){return-1!==La(this,b,"includes").indexOf(b,c||0)}});ha("Array.prototype.find",function(a){return a?a:function(b,c){return Ka(this,b,c).v}});ha("String.prototype.startsWith",function(a){return a?a:function(b,c){for(var d=La(this,b,"startsWith"),e=d.length,f=b.length,g=Math.max(0,Math.min(c|0,d.length)),h=0;h<f&&g<e;)if(d[g++]!=b[h++])return!1;return h>=f}});
45
- function Ma(a,b){a instanceof String&&(a+="");var c=0,d=!1,e={next:function(){if(!d&&c<a.length){var f=c++;return{value:b(f,a[f]),done:!1}}d=!0;return{done:!0,value:void 0}}};e[Symbol.iterator]=function(){return e};return e}ha("Array.prototype.keys",function(a){return a?a:function(){return Ma(this,function(b){return b})}});var Na="function"==typeof Object.assign?Object.assign:function(a,b){for(var c=1;c<arguments.length;c++){var d=arguments[c];if(d)for(var e in d)Ja(d,e)&&(a[e]=d[e])}return a};
45
+ function Ma(a,b){a instanceof String&&(a+="");var c=0,d=!1,e={next:function(){if(!d&&c<a.length){var f=c++;return{value:b(f,a[f]),done:!1}}d=!0;return{done:!0,value:void 0}}};e[Symbol.iterator]=function(){return e};return e}ha("Array.prototype.keys",function(a){return a?a:function(){return Ma(this,function(b){return b})}});var Na="function"==typeof Object.assign?Object.assign:function(a,b){for(var c=1;c<arguments.length;c++){var d=arguments[c];if(d)for(var e in d)Ia(d,e)&&(a[e]=d[e])}return a};
46
46
  ha("Object.assign",function(a){return a||Na});ha("Array.from",function(a){return a?a:function(b,c,d){c=null!=c?c:function(h){return h};var e=[],f="undefined"!=typeof Symbol&&Symbol.iterator&&b[Symbol.iterator];if("function"==typeof f){b=f.call(b);for(var g=0;!(f=b.next()).done;)e.push(c.call(d,f.value,g++))}else for(f=b.length,g=0;g<f;g++)e.push(c.call(d,b[g],g));return e}});ha("Array.prototype.values",function(a){return a?a:function(){return Ma(this,function(b,c){return c})}});
47
47
  ha("Promise.prototype.finally",function(a){return a?a:function(b){return this.then(function(c){return Promise.resolve(b()).then(function(){return c})},function(c){return Promise.resolve(b()).then(function(){throw c;})})}});ha("Array.prototype.entries",function(a){return a?a:function(){return Ma(this,function(b,c){return[b,c]})}});
48
- ha("String.prototype.repeat",function(a){return a?a:function(b){var c=La(this,null,"repeat");if(0>b||1342177279<b)throw new RangeError("Invalid count value");b|=0;for(var d="";b;)if(b&1&&(d+=c),b>>>=1)c+=c;return d}});ha("Number.isNaN",function(a){return a?a:function(b){return"number"===typeof b&&isNaN(b)}});ha("Object.values",function(a){return a?a:function(b){var c=[],d;for(d in b)Ja(b,d)&&c.push(b[d]);return c}});ha("Math.log2",function(a){return a?a:function(b){return Math.log(b)/Math.LN2}});
49
- ha("Object.entries",function(a){return a?a:function(b){var c=[],d;for(d in b)Ja(b,d)&&c.push([d,b[d]]);return c}});var Oa=this||self;function M(a,b){var c=a.split("."),d=Oa;c[0]in d||"undefined"==typeof d.execScript||d.execScript("var "+c[0]);for(var e;c.length&&(e=c.shift());)c.length||void 0===b?d[e]&&d[e]!==Object.prototype[e]?d=d[e]:d=d[e]={}:d[e]=b};/*
48
+ ha("String.prototype.repeat",function(a){return a?a:function(b){var c=La(this,null,"repeat");if(0>b||1342177279<b)throw new RangeError("Invalid count value");b|=0;for(var d="";b;)if(b&1&&(d+=c),b>>>=1)c+=c;return d}});ha("Number.isNaN",function(a){return a?a:function(b){return"number"===typeof b&&isNaN(b)}});ha("Object.values",function(a){return a?a:function(b){var c=[],d;for(d in b)Ia(b,d)&&c.push(b[d]);return c}});ha("Math.log2",function(a){return a?a:function(b){return Math.log(b)/Math.LN2}});
49
+ ha("Object.entries",function(a){return a?a:function(b){var c=[],d;for(d in b)Ia(b,d)&&c.push([d,b[d]]);return c}});var Oa=this||self;function M(a,b){var c=a.split("."),d=Oa;c[0]in d||"undefined"==typeof d.execScript||d.execScript("var "+c[0]);for(var e;c.length&&(e=c.shift());)c.length||void 0===b?d[e]&&d[e]!==Object.prototype[e]?d=d[e]:d=d[e]={}:d[e]=b};/*
50
50
  @license
51
51
  Shaka Player
52
52
  Copyright 2016 Google LLC
53
53
  SPDX-License-Identifier: Apache-2.0
54
54
  */
55
55
  function Pa(a){this.g=Math.exp(Math.log(.5)/a);this.i=this.h=0}Pa.prototype.sample=function(a,b){var c=Math.pow(this.g,a);c=b*(1-c)+c*this.h;isNaN(c)||(this.h=c,this.i+=a)};function Qa(a){return a.h/(1-Math.pow(a.g,a.i))};function Ra(){this.h=new Pa(2);this.j=new Pa(5);this.g=0;this.i=128E3;this.l=16E3}Ra.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)};Ra.prototype.sample=function(a,b){if(!(b<this.l)){var c=8E3*b/a,d=a/1E3;this.g+=b;this.h.sample(d,c);this.j.sample(d,c)}};Ra.prototype.getBandwidthEstimate=function(a){return this.g<this.i?a:Math.min(Qa(this.h),Qa(this.j))};function Sa(){}function Ta(){}function Ua(){}function Va(a){var b=Ha.apply(1,arguments);Wa.has(a)||(Wa.add(a),Ua.apply(Sa,ja(b)))}function Xa(){}function Za(){}function $a(){}function ab(){}var Wa=new Set;if(window.console&&window.console.log.bind){var bb={},db=(bb[1]=console.error.bind(console),bb[2]=console.warn.bind(console),bb[3]=console.info.bind(console),bb[4]=console.log.bind(console),bb[5]=console.debug.bind(console),bb[6]=console.debug.bind(console),bb);Ua=db[2];Ta=db[1]};function eb(a,b){return"number"===typeof a&&"number"===typeof b&&isNaN(a)&&isNaN(b)?!0:a===b}function fb(a,b){var c=a.indexOf(b);-1<c&&a.splice(c,1)}function gb(a,b,c){c||(c=eb);if(a.length!=b.length)return!1;b=b.slice();var d={};a=t(a);for(var e=a.next();!e.done;d={ad:d.ad},e=a.next()){d.ad=e.value;e=b.findIndex(function(f){return function(g){return c(f.ad,g)}}(d));if(-1==e)return!1;b[e]=b[b.length-1];b.pop()}return 0==b.length}
56
- function hb(a,b,c){c||(c=eb);if(a.length!=b.length)return!1;for(var d=0;d<a.length;d++)if(!c(a[d],b[d]))return!1;return!0};function ib(a,b,c){this.startTime=a;this.direction=jb;this.endTime=b;this.payload=c;this.region=new kb;this.position=null;this.positionAlign=lb;this.size=0;this.textAlign=mb;this.writingMode=nb;this.lineInterpretation=ob;this.line=null;this.lineHeight="";this.lineAlign=pb;this.displayAlign=qb;this.fontSize=this.textStrokeWidth=this.textStrokeColor=this.border=this.backgroundImage=this.backgroundColor=this.color="";this.fontWeight=rb;this.fontStyle=sb;this.linePadding=this.letterSpacing=this.fontFamily=
57
- "";this.opacity=1;this.textDecoration=[];this.wrapLine=!0;this.id="";this.nestedCues=[];this.spacer=this.lineBreak=this.isContainer=!1;this.cellResolution={columns:32,rows:15}}ib.prototype.clone=function(){var a=new ib(0,0,""),b;for(b in this)a[b]=this[b],a[b]&&a[b].constructor==Array&&(a[b]=a[b].slice());return a};
56
+ function hb(a,b,c){c||(c=eb);if(a.length!=b.length)return!1;for(var d=0;d<a.length;d++)if(!c(a[d],b[d]))return!1;return!0};function ib(a,b,c){this.startTime=a;this.direction=jb;this.endTime=b;this.payload=c;this.region=new kb;this.position=null;this.positionAlign=lb;this.size=0;this.textAlign=mb;this.writingMode=nb;this.lineInterpretation=ob;this.line=null;this.lineHeight="";this.lineAlign=pb;this.displayAlign=qb;this.fontSize=this.textStrokeWidth=this.textStrokeColor=this.textShadow=this.border=this.backgroundImage=this.backgroundColor=this.color="";this.fontWeight=rb;this.fontStyle=sb;this.linePadding=this.letterSpacing=
57
+ this.fontFamily="";this.opacity=1;this.textDecoration=[];this.wrapLine=!0;this.id="";this.nestedCues=[];this.spacer=this.lineBreak=this.isContainer=!1;this.cellResolution={columns:32,rows:15}}ib.prototype.clone=function(){var a=new ib(0,0,""),b;for(b in this)a[b]=this[b],a[b]&&a[b].constructor==Array&&(a[b]=a[b].slice());return a};
58
58
  function tb(a,b){if(a.startTime!=b.startTime||a.endTime!=b.endTime||a.payload!=b.payload)return!1;for(var c in a)if("startTime"!=c&&"endTime"!=c&&"payload"!=c)if("nestedCues"==c){if(!hb(a.nestedCues,b.nestedCues,tb))return!1}else if("region"==c||"cellResolution"==c)for(var d in a[c]){if(a[c][d]!=b[c][d])return!1}else if(Array.isArray(a[c])){if(!hb(a[c],b[c]))return!1}else if(a[c]!=b[c])return!1;return!0}M("shaka.text.Cue",ib);var lb="auto";
59
59
  ib.positionAlign={LEFT:"line-left",RIGHT:"line-right",CENTER:"center",AUTO:lb};var mb="center",ub={LEFT:"left",RIGHT:"right",CENTER:mb,START:"start",END:"end"};ib.textAlign=ub;var qb="after",vb={BEFORE:"before",CENTER:"center",AFTER:qb};ib.displayAlign=vb;var jb="ltr";ib.direction={HORIZONTAL_LEFT_TO_RIGHT:jb,HORIZONTAL_RIGHT_TO_LEFT:"rtl"};var nb="horizontal-tb";ib.writingMode={HORIZONTAL_TOP_TO_BOTTOM:nb,VERTICAL_LEFT_TO_RIGHT:"vertical-lr",VERTICAL_RIGHT_TO_LEFT:"vertical-rl"};var ob=0;
60
60
  ib.lineInterpretation={LINE_NUMBER:ob,PERCENTAGE:1};var pb="start",wb={CENTER:"center",START:pb,END:"end"};ib.lineAlign=wb;var xb={white:"#FFF",lime:"#0F0",cyan:"#0FF",red:"#F00",yellow:"#FF0",magenta:"#F0F",blue:"#00F",black:"#000"};ib.defaultTextColor=xb;var yb={bg_white:"#FFF",bg_lime:"#0F0",bg_cyan:"#0FF",bg_red:"#F00",bg_yellow:"#FF0",bg_magenta:"#F0F",bg_blue:"#00F",bg_black:"#000"};ib.defaultTextBackgroundColor=yb;var rb=400;ib.fontWeight={NORMAL:rb,BOLD:700};
@@ -93,7 +93,7 @@ function Jc(a){if(!a)return"";a=Fb(a);239==a[0]&&187==a[1]&&191==a[2]&&(a=a.suba
93
93
  function Kc(a,b,c){if(!a)return"";if(!c&&0!=a.byteLength%2)throw new N(2,2,2004);c=Math.floor(a.byteLength/2);var d=new Uint16Array(c);a=Ib(a);for(var e=0;e<c;e++)d[e]=a.getUint16(2*e,b);return Lc.value()(d)}
94
94
  function Mc(a){function b(d){return c.byteLength<=d||32<=c[d]&&126>=c[d]}if(!a)return"";var c=Fb(a);if(239==c[0]&&187==c[1]&&191==c[2])return Jc(c);if(254==c[0]&&255==c[1])return Kc(c.subarray(2),!1);if(255==c[0]&&254==c[1])return Kc(c.subarray(2),!0);if(0==c[0]&&0==c[2])return Kc(a,!1);if(0==c[1]&&0==c[3])return Kc(a,!0);if(b(0)&&b(1)&&b(2)&&b(3))return Jc(a);throw new N(2,2,2003);}
95
95
  function Nc(a){if(window.TextEncoder&&!Dc()){var b=new TextEncoder;return Gb(b.encode(a))}a=encodeURIComponent(a);a=unescape(a);b=new Uint8Array(a.length);for(var c=0;c<a.length;c++)b[c]=a[c].charCodeAt(0);return Gb(b)}function Oc(a,b){for(var c=new ArrayBuffer(2*a.length),d=new DataView(c),e=0;e<a.length;++e)d.setUint16(2*e,a.charCodeAt(e),b);return c}M("shaka.util.StringUtils",Ic);Ic.resetFromCharCode=function(){Lc.g=void 0};Ic.toUTF16=Oc;Ic.toUTF8=Nc;Ic.fromBytesAutoDetect=Mc;Ic.fromUTF16=Kc;
96
- Ic.fromUTF8=Jc;var Lc=new sc(function(){function a(c){try{var d=new Uint8Array(c);return 0<String.fromCharCode.apply(null,d).length}catch(e){return!1}}for(var b={Ua:65536};0<b.Ua;b={Ua:b.Ua},b.Ua/=2)if(a(b.Ua))return function(c){return function(d){for(var e="",f=0;f<d.length;f+=c.Ua)e+=String.fromCharCode.apply(null,d.subarray(f,f+c.Ua));return e}}(b);return null});function Pc(){}function Qc(a){a=Fb(a);a=Lc.value()(a);return btoa(a)}function Rc(a,b){b=void 0==b?!0:b;var c=Qc(a).replace(/\+/g,"-").replace(/\//g,"_");return b?c:c.replace(/[=]*$/,"")}function Sc(a){a=window.atob(a.replace(/-/g,"+").replace(/_/g,"/"));for(var b=new Uint8Array(a.length),c=0;c<a.length;++c)b[c]=a.charCodeAt(c);return b}function Tc(a){for(var b=a.length/2,c=new Uint8Array(b),d=0;d<b;d++)c[d]=window.parseInt(a.substr(2*d,2),16);return c}
96
+ Ic.fromUTF8=Jc;var Lc=new sc(function(){function a(c){try{var d=new Uint8Array(c);return 0<String.fromCharCode.apply(null,d).length}catch(e){return!1}}for(var b={Va:65536};0<b.Va;b={Va:b.Va},b.Va/=2)if(a(b.Va))return function(c){return function(d){for(var e="",f=0;f<d.length;f+=c.Va)e+=String.fromCharCode.apply(null,d.subarray(f,f+c.Va));return e}}(b);return null});function Pc(){}function Qc(a){a=Fb(a);a=Lc.value()(a);return btoa(a)}function Rc(a,b){b=void 0==b?!0:b;var c=Qc(a).replace(/\+/g,"-").replace(/\//g,"_");return b?c:c.replace(/[=]*$/,"")}function Sc(a){a=window.atob(a.replace(/-/g,"+").replace(/_/g,"/"));for(var b=new Uint8Array(a.length),c=0;c<a.length;++c)b[c]=a.charCodeAt(c);return b}function Tc(a){for(var b=a.length/2,c=new Uint8Array(b),d=0;d<b;d++)c[d]=window.parseInt(a.substr(2*d,2),16);return c}
97
97
  function Uc(a){var b=Fb(a);a="";b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,c=c.toString(16),1==c.length&&(c="0"+c),a+=c;return a}function Vc(){for(var a=Ha.apply(0,arguments),b=0,c=t(a),d=c.next();!d.done;d=c.next())b+=d.value.byteLength;b=new Uint8Array(b);c=0;a=t(a);for(d=a.next();!d.done;d=a.next())d=d.value,b.set(Fb(d),c),c+=d.byteLength;return b}M("shaka.util.Uint8ArrayUtils",Pc);Pc.concat=Vc;Pc.toHex=Uc;Pc.fromHex=Tc;Pc.fromBase64=Sc;Pc.toBase64=Rc;Pc.toStandardBase64=Qc;
98
98
  Pc.equal=function(a,b){Kb("shaka.util.Uint8ArrayUtils.equal","Please use shaka.util.BufferUtils.equal instead.");return Db(a,b)};function Wc(){var a=this;this.o=Ub.get("muxjs")();this.g=new this.o.mp4.Transmuxer({keepOriginalTimestamps:!0});this.h=null;this.m=[];this.j=[];this.i=[];this.l=!1;this.g.on("data",function(b){a.j=b.captions;a.i=b.metadata;a.m.push(Vc(b.initSegment,b.data))});this.g.on("done",function(){var b={data:Vc.apply(Pc,ja(a.m)),captions:a.j,metadata:a.i};a.h.resolve(b);a.l=!1})}Wc.prototype.destroy=function(){this.g.dispose();this.g=null;return Promise.resolve()};
99
99
  function Xc(a,b){if(!Ub.get("muxjs")()||!Yc(a))return!1;if(b)return MediaSource.isTypeSupported(Zc(b,a));var c=Zc("audio",a),d=Zc("video",a);return MediaSource.isTypeSupported(c)||MediaSource.isTypeSupported(d)}function Yc(a){return"mp2t"==a.toLowerCase().split(";")[0].split("/")[1]}
@@ -123,7 +123,7 @@ function Od(a,b,c){function d(f,g,h){return f>=g&&f<=h}var e=a.video;return e&&e
123
123
  function Pd(a,b){return L(function(c){if(1==c.g)return u(c,Qd(b,0<b.offlineSessionIds.length),2);Rd(a,b);Sd(b);Td(b);A(c)})}
124
124
  function Qd(a,b){return L(function(c){if(1==c.g)return u(c,Ud(a.variants,b,!1),2);a.variants=a.variants.filter(function(d){var e=d.video;if(e){var f=Vd(e.codecs);if(e.codecs.includes(",")){var g=e.codecs.split(",");f=mc("video",g);f=Vd(f);g=mc("audio",g);g=Wd(g);var h=bd(e.mimeType,g,"audio");if(!MediaSource.isTypeSupported(h))return!1;f=[f,g].join()}g=bd(e.mimeType,f,"video");if(!MediaSource.isTypeSupported(g))return!1;e.codecs=f}if(f=d.audio){g=Wd(f.codecs);h=bd(f.mimeType,g,"audio");if(!MediaSource.isTypeSupported(h))return!1;
125
125
  f.codecs=g}if(xc()&&e&&(e.width&&1920<e.width||e.height&&1080<e.height)&&(e.codecs.includes("avc1.")||e.codecs.includes("avc3.")))return Za(Xd(d)),!1;(e=d.decodingInfos.some(function(k){return k.supported}))||Za(Xd(d));return e});A(c)})}
126
- function Ud(a,b,c){var d,e,f,g,h,k,l,m,n,p,q;return L(function(v){if(d=a.some(function(y){return y.decodingInfos.length}))return v["return"]();e=navigator.mediaCapabilities;f=[];g=function(y,w){var x;return L(function(D){if(1==D.g)return C(D,2),u(D,e.decodingInfo(w),4);if(2!=D.g)return x=D.h,y.decodingInfos.push(x),va(D,0);E(D);JSON.stringify(w);A(D)})};h=t(a);for(k=h.next();!k.done;k=h.next())for(l=k.value,m=Yd(l,b,c),n=t(m),p=n.next();!p.done;p=n.next())q=p.value,f.push(g(l,q));return u(v,Promise.all(f),
126
+ function Ud(a,b,c){var d,e,f,g,h,k,l,m,n,p,q;return L(function(v){if(d=a.some(function(w){return w.decodingInfos.length}))return v["return"]();e=navigator.mediaCapabilities;f=[];g=function(w,x){var y;return L(function(D){if(1==D.g)return C(D,2),u(D,e.decodingInfo(x),4);if(2!=D.g)return y=D.h,w.decodingInfos.push(y),va(D,0);E(D);JSON.stringify(x);A(D)})};h=t(a);for(k=h.next();!k.done;k=h.next())for(l=k.value,m=Yd(l,b,c),n=t(m),p=n.next();!p.done;p=n.next())q=p.value,f.push(g(l,q));return u(v,Promise.all(f),
127
127
  0)})}
128
128
  function Yd(a,b,c){var d=a.audio,e=a.video;c={type:c?"file":"media-source"};if(e){var f=e.codecs;if(e.codecs.includes(",")){var g=e.codecs.split(",");f=mc("video",g);f=Vd(f);g=mc("audio",g);g=bd(e.mimeType,g,"audio");c.audio={contentType:g,channels:2,bitrate:a.bandwidth||1,samplerate:1,spatialRendering:!1}}f=Vd(f);f=bd(e.mimeType,f,"video");c.video={contentType:f,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":c.video.transferFunction="srgb";
129
129
  break;case "PQ":c.video.transferFunction="pq";break;case "HLG":c.video.transferFunction="hlg"}}d&&(f=Wd(d.codecs),f=bd(d.mimeType,f,"audio"),c.audio={contentType:f,channels:d.channelsCount||2,bitrate:d.bandwidth||a.bandwidth||1,samplerate:d.audioSamplingRate||1,spatialRendering:d.spatialAudio});g=(a.video?a.video.drmInfos:[]).concat(a.audio?a.audio.drmInfos:[]);if(!g.length)return[c];a=[];f=new Map;g=t(g);for(var h=g.next();!h.done;h=g.next()){var k=h.value;f.get(k.keySystem)||f.set(k.keySystem,[]);
@@ -158,18 +158,18 @@ function Ke(a){return new Fe(Promise.all(a.map(function(b){return b.promise})),f
158
158
  Fe.prototype.$=function(a,b){function c(h){return function(k){if(e.g&&h)f.reject(g);else{var l=h?a:b;l?d=Le(l,k,f):(h?f.resolve:f.reject)(k)}}}function d(){f.reject(g);return e.abort()}var e=this,f=new rc,g=new N(2,7,7001);this.promise.then(c(!0),c(!1));return new Fe(f,function(){return d()})};
159
159
  function Le(a,b,c){try{var d=a(b);if(d&&d.promise&&d.abort)return c.resolve(d.promise),function(){return d.abort()};c.resolve(d);return function(){return Promise.resolve(d).then(function(){},function(){})}}catch(e){return c.reject(e),function(){return Promise.resolve()}}}M("shaka.util.AbortableOperation",Fe);Fe.prototype.chain=Fe.prototype.$;Fe.prototype["finally"]=Fe.prototype["finally"];Fe.all=Ke;Fe.prototype.abort=Fe.prototype.abort;Fe.notAbortable=Je;Fe.completed=Ie;Fe.aborted=He;Fe.failed=Ge;function Q(a,b){if(b)if(b instanceof Map)for(var c=t(b.keys()),d=c.next();!d.done;d=c.next())d=d.value,Object.defineProperty(this,d,{value:b.get(d),writable:!0,enumerable:!0});else for(c in b)Object.defineProperty(this,c,{value:b[c],writable:!0,enumerable:!0});this.defaultPrevented=this.cancelable=this.bubbles=!1;this.timeStamp=window.performance&&window.performance.now?window.performance.now():Date.now();this.type=a;this.isTrusted=!1;this.target=this.currentTarget=null;this.g=!1}
160
160
  function Me(a){var b=new Q(a.type),c;for(c in a)Object.defineProperty(b,c,{value:a[c],writable:!0,enumerable:!0});return b}Q.prototype.preventDefault=function(){this.cancelable&&(this.defaultPrevented=!0)};Q.prototype.stopImmediatePropagation=function(){this.g=!0};Q.prototype.stopPropagation=function(){};M("shaka.util.FakeEvent",Q);function Ne(){this.ea=new zd;this.Ec=this}Ne.prototype.addEventListener=function(a,b){this.ea&&this.ea.push(a,b)};Ne.prototype.removeEventListener=function(a,b){this.ea&&this.ea.remove(a,b)};Ne.prototype.dispatchEvent=function(a){if(!this.ea)return!0;var b=this.ea.get(a.type)||[],c=this.ea.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.Ec;a.currentTarget=this.Ec;try{c.handleEvent?c.handleEvent(a):c.call(this,a)}catch(d){}if(a.g)break}return a.defaultPrevented};
161
- Ne.prototype.release=function(){this.ea=null};function Oe(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&&d.buffer.constructor==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 Set;return b(a)}function Pe(a){var b={},c;for(c in a)b[c]=a[c];return b};function Qe(){this.g=[]}function Re(a,b){a.g.push(b["finally"](function(){fb(a.g,b)}))}Qe.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 Se(a,b,c){Ne.call(this);this.i=!1;this.m=new Qe;this.g=new Set;this.h=new Set;this.l=a||null;this.j=b||null;this.s=c||null;this.o=!1}qa(Se,Ne);r=Se.prototype;r.Vd=function(a){this.o=a};function Te(a,b,c,d){c=c||Ue;var e=Ve[a];if(!e||c>=e.priority)Ve[a]={priority:c,Mf:b,Nf:void 0===d?!1:d}}r.Of=function(a){this.g.add(a)};r.dg=function(a){this.g["delete"](a)};r.Ue=function(){this.g.clear()};r.Pf=function(a){this.h.add(a)};r.eg=function(a){this.h["delete"](a)};r.Ve=function(){this.h.clear()};
161
+ Ne.prototype.release=function(){this.ea=null};function Oe(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&&d.buffer.constructor==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 Set;return b(a)}function Pe(a){var b={},c;for(c in a)b[c]=a[c];return b};function Qe(){this.g=[]}function Re(a,b){a.g.push(b["finally"](function(){fb(a.g,b)}))}Qe.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 Se(a,b,c){Ne.call(this);this.i=!1;this.m=new Qe;this.g=new Set;this.h=new Set;this.l=a||null;this.j=b||null;this.s=c||null;this.o=!1}qa(Se,Ne);r=Se.prototype;r.Wd=function(a){this.o=a};function Te(a,b,c,d){c=c||Ue;var e=Ve[a];if(!e||c>=e.priority)Ve[a]={priority:c,Mf:b,Nf:void 0===d?!1:d}}r.Of=function(a){this.g.add(a)};r.dg=function(a){this.g["delete"](a)};r.Ue=function(){this.g.clear()};r.Pf=function(a){this.h.add(a)};r.eg=function(a){this.h["delete"](a)};r.Ve=function(){this.h.clear()};
162
162
  function We(a,b,c){return{uris:a,method:"GET",body:null,headers:{},allowCrossSiteCredentials:!1,retryParameters:b,licenseRequestType:null,sessionId:null,streamDataCallback:void 0===c?null:c}}r.destroy=function(){this.i=!0;this.g.clear();this.h.clear();Ne.prototype.release.call(this);return this.m.destroy()};
163
163
  r.request=function(a,b){var c=this,d=new Xe;if(this.i){var e=Promise.reject(new N(2,7,7001));e["catch"](function(){});return new Ye(e,function(){return Promise.resolve()},d)}b.method=b.method||"GET";b.headers=b.headers||{};b.retryParameters=b.retryParameters?Oe(b.retryParameters):De();b.uris=Oe(b.uris);e=Ze(this,a,b);var f=e.$(function(){return $e(c,a,b,new Ce(b.retryParameters,!1),0,null,d)}),g=f.$(function(n){return af(c,a,n)}),h=Date.now(),k=0;e.promise.then(function(){k=Date.now()-h},function(){});
164
164
  var l=0;f.promise.then(function(){l=Date.now()},function(){});var m=g.$(function(n){var p=Date.now()-l,q=n.response;q.timeMs+=k;q.timeMs+=p;n.Bf||!c.l||q.fromCache||a!=bf||c.l(q.timeMs,q.data.byteLength);return q},function(n){n&&(n.severity=2);throw n;});e=new Ye(m.promise,function(){return m.abort()},d);Re(this.m,e);return e};
165
165
  function Ze(a,b,c){var d=Ie(void 0),e={};a=t(a.g);for(var f=a.next();!f.done;e={gd:e.gd},f=a.next())e.gd=f.value,d=d.$(function(g){return function(){c.body&&(c.body=Gb(c.body));return g.gd(b,c)}}(e));return d.$(void 0,function(g){if(g instanceof N&&7001==g.code)throw g;throw new N(2,1,1006,g);})}
166
- function $e(a,b,c,d,e,f,g){a.o&&(c.uris[e]=c.uris[e].replace("http://","https://"));var h=new Xb(c.uris[e]),k=h.Fa,l=!1;k||(k=location.protocol,k=k.slice(0,-1),Yb(h,k),c.uris[e]=h.toString());k=k.toLowerCase();var m=(k=Ve[k])?k.Mf:null;if(!m)return Ge(new N(2,1,1E3,h));var n=k.Nf,p=null,q=null,v=!1,y=!1,w;return Je(Ee(d)).$(function(){if(a.i)return He();w=Date.now();var x=m(c.uris[e],c,b,function(B,F,G){p&&p.stop();q&&q.S(z/1E3);a.l&&b==bf&&(a.l(B,F),l=!0,g.g=G)},function(B){a.j&&a.j(B,c,b);y=!0});
167
- if(!n)return x;var D=c.retryParameters.connectionTimeout;D&&(p=new O(function(){v=!0;x.abort()}),p.S(D/1E3));var z=c.retryParameters.stallTimeout;z&&(q=new O(function(){v=!0;x.abort()}));return x}).$(function(x){p&&p.stop();q&&q.stop();void 0==x.timeMs&&(x.timeMs=Date.now()-w);var D={response:x,Bf:l};!y&&a.j&&a.j(x.headers,c,b);return D},function(x){p&&p.stop();q&&q.stop();if(a.s){var D=null,z=0;x instanceof N&&(D=x,1001==x.code&&(z=x.data[1]));a.s(c,D,z,v)}if(a.i)return He();v&&(x=new N(1,1,1003,
168
- c.uris[e],b));if(x instanceof N){if(7001==x.code)throw x;if(1010==x.code)throw f;if(1==x.severity)return D=(new Map).set("error",x),D=new Q("retry",D),a.dispatchEvent(D),e=(e+1)%c.uris.length,$e(a,b,c,d,e,x,g)}throw x;})}
166
+ function $e(a,b,c,d,e,f,g){a.o&&(c.uris[e]=c.uris[e].replace("http://","https://"));var h=new Xb(c.uris[e]),k=h.Fa,l=!1;k||(k=location.protocol,k=k.slice(0,-1),Yb(h,k),c.uris[e]=h.toString());k=k.toLowerCase();var m=(k=Ve[k])?k.Mf:null;if(!m)return Ge(new N(2,1,1E3,h));var n=k.Nf,p=null,q=null,v=!1,w=!1,x;return Je(Ee(d)).$(function(){if(a.i)return He();x=Date.now();var y=m(c.uris[e],c,b,function(B,F,G){p&&p.stop();q&&q.S(z/1E3);a.l&&b==bf&&(a.l(B,F),l=!0,g.g=G)},function(B){a.j&&a.j(B,c,b);w=!0});
167
+ if(!n)return y;var D=c.retryParameters.connectionTimeout;D&&(p=new O(function(){v=!0;y.abort()}),p.S(D/1E3));var z=c.retryParameters.stallTimeout;z&&(q=new O(function(){v=!0;y.abort()}));return y}).$(function(y){p&&p.stop();q&&q.stop();void 0==y.timeMs&&(y.timeMs=Date.now()-x);var D={response:y,Bf:l};!w&&a.j&&a.j(y.headers,c,b);return D},function(y){p&&p.stop();q&&q.stop();if(a.s){var D=null,z=0;y instanceof N&&(D=y,1001==y.code&&(z=y.data[1]));a.s(c,D,z,v)}if(a.i)return He();v&&(y=new N(1,1,1003,
168
+ c.uris[e],b));if(y instanceof N){if(7001==y.code)throw y;if(1010==y.code)throw f;if(1==y.severity)return D=(new Map).set("error",y),D=new Q("retry",D),a.dispatchEvent(D),e=(e+1)%c.uris.length,$e(a,b,c,d,e,y,g)}throw y;})}
169
169
  function af(a,b,c){var d=Ie(void 0),e={};a=t(a.h);for(var f=a.next();!f.done;e={hd:e.hd},f=a.next())e.hd=f.value,d=d.$(function(g){return function(){var h=c.response;h.data&&(h.data=Gb(h.data));return g.hd(b,h)}}(e));return d.$(function(){return c},function(g){var h=2;if(g instanceof N){if(7001==g.code)throw g;h=g.severity}throw new N(h,1,1007,g);})}M("shaka.net.NetworkingEngine",Se);Se.prototype.request=Se.prototype.request;Se.prototype.destroy=Se.prototype.destroy;Se.makeRequest=We;
170
- Se.defaultRetryParameters=function(){return De()};Se.prototype.clearAllResponseFilters=Se.prototype.Ve;Se.prototype.unregisterResponseFilter=Se.prototype.eg;Se.prototype.registerResponseFilter=Se.prototype.Pf;Se.prototype.clearAllRequestFilters=Se.prototype.Ue;Se.prototype.unregisterRequestFilter=Se.prototype.dg;Se.prototype.registerRequestFilter=Se.prototype.Of;Se.unregisterScheme=function(a){delete Ve[a]};Se.registerScheme=Te;Se.prototype.setForceHTTPS=Se.prototype.Vd;function Xe(){this.g=0}
171
- Se.NumBytesRemainingClass=Xe;function Ye(a,b,c){Fe.call(this,a,b);this.h=c}qa(Ye,Fe);Se.PendingRequest=Ye;var bf=1;Se.RequestType={MANIFEST:0,SEGMENT:bf,LICENSE:2,APP:3,TIMING:4,SERVER_CERTIFICATE:5};var Ue=3;Se.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:Ue};var Ve={};function cf(a){this.g=!1;this.h=new rc;this.i=a}cf.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 df(a,b){if(a.g){if(b instanceof N&&7003==b.code)throw b;throw new N(2,7,7003,b);}};function ef(){this.g=new zd}r=ef.prototype;r.release=function(){this.Sa();this.g=null};r.A=function(a,b,c,d){this.g&&(a=new ff(a,b,c,d),this.g.push(b,a))};r.oa=function(a,b,c,d){function e(g){f.qc(a,b,e);c(g)}var f=this;this.A(a,b,e,d)};r.qc=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.qc(),this.g.remove(b,e))}};
172
- r.Sa=function(){if(this.g){var a=this.g,b=[],c;for(c in a.g)b.push.apply(b,ja(a.g[c]));a=t(b);for(b=a.next();!b.done;b=a.next())b.value.qc();this.g.g={}}};M("shaka.util.EventManager",ef);ef.prototype.removeAll=ef.prototype.Sa;ef.prototype.unlisten=ef.prototype.qc;ef.prototype.listenOnce=ef.prototype.oa;ef.prototype.listen=ef.prototype.A;ef.prototype.release=ef.prototype.release;function ff(a,b,c,d){this.target=a;this.type=b;this.listener=c;this.g=gf(a,d);this.target.addEventListener(b,c,this.g)}
170
+ Se.defaultRetryParameters=function(){return De()};Se.prototype.clearAllResponseFilters=Se.prototype.Ve;Se.prototype.unregisterResponseFilter=Se.prototype.eg;Se.prototype.registerResponseFilter=Se.prototype.Pf;Se.prototype.clearAllRequestFilters=Se.prototype.Ue;Se.prototype.unregisterRequestFilter=Se.prototype.dg;Se.prototype.registerRequestFilter=Se.prototype.Of;Se.unregisterScheme=function(a){delete Ve[a]};Se.registerScheme=Te;Se.prototype.setForceHTTPS=Se.prototype.Wd;function Xe(){this.g=0}
171
+ Se.NumBytesRemainingClass=Xe;function Ye(a,b,c){Fe.call(this,a,b);this.h=c}qa(Ye,Fe);Se.PendingRequest=Ye;var bf=1;Se.RequestType={MANIFEST:0,SEGMENT:bf,LICENSE:2,APP:3,TIMING:4,SERVER_CERTIFICATE:5};var Ue=3;Se.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:Ue};var Ve={};function cf(a){this.g=!1;this.h=new rc;this.i=a}cf.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 df(a,b){if(a.g){if(b instanceof N&&7003==b.code)throw b;throw new N(2,7,7003,b);}};function ef(){this.g=new zd}r=ef.prototype;r.release=function(){this.Ta();this.g=null};r.A=function(a,b,c,d){this.g&&(a=new ff(a,b,c,d),this.g.push(b,a))};r.oa=function(a,b,c,d){function e(g){f.qc(a,b,e);c(g)}var f=this;this.A(a,b,e,d)};r.qc=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.qc(),this.g.remove(b,e))}};
172
+ r.Ta=function(){if(this.g){var a=this.g,b=[],c;for(c in a.g)b.push.apply(b,ja(a.g[c]));a=t(b);for(b=a.next();!b.done;b=a.next())b.value.qc();this.g.g={}}};M("shaka.util.EventManager",ef);ef.prototype.removeAll=ef.prototype.Ta;ef.prototype.unlisten=ef.prototype.qc;ef.prototype.listenOnce=ef.prototype.oa;ef.prototype.listen=ef.prototype.A;ef.prototype.release=ef.prototype.release;function ff(a,b,c,d){this.target=a;this.type=b;this.listener=c;this.g=gf(a,d);this.target.addEventListener(b,c,this.g)}
173
173
  ff.prototype.qc=function(){this.target.removeEventListener(this.type,this.listener,this.g);this.listener=this.target=null;this.g=!1};function gf(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 hf(a)?b:b.capture||!1}
174
174
  function hf(a){var b=jf;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}jf=b}return b||!1}var jf=void 0;function kf(){}function lf(a){a=Mc(a);return(new Xb(a)).Ha}function mf(a,b,c){function d(h){Ib(f).setUint32(g,h.byteLength,!0);g+=4;f.set(Fb(h),g);g+=h.byteLength}if(!c||!c.byteLength)throw new N(2,6,6015);var e;"string"==typeof b?e=Oc(b,!0):e=b;a=Mc(a);a=Oc(a,!0);var f=new Uint8Array(12+a.byteLength+e.byteLength+c.byteLength),g=0;d(a);d(e);d(c);return f}M("shaka.util.FairPlayUtils",kf);kf.initDataTransform=mf;kf.defaultGetContentId=lf;function nf(a,b){for(var c=[],d=t(a),e=d.next();!e.done;e=d.next())c.push(b(e.value));return c}function of(a,b){for(var c=t(a),d=c.next();!d.done;d=c.next())if(!b(d.value))return!1;return!0};function pf(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 qf(a){var b={};a.forEach(function(c,d){b[d]=c});return b}function rf(a,b){if(a||b){if(a&&!b||b&&!a)return!1}else return!0;if(a.size!=b.size)return!1;for(var c=t(a),d=c.next();!d.done;d=c.next()){var e=t(d.value);d=e.next().value;e=e.next().value;if(!b.has(d))return!1;d=b.get(d);if(d!=e||void 0==d)return!1}return!0};function sf(a,b){var c=tf(a,b);return 1!=c.length?null:c[0]}function uf(a,b,c){a=vf(a,b,c);return 1!=a.length?null:a[0]}function tf(a,b){for(var c=[],d=t(a.childNodes),e=d.next();!e.done;e=d.next())e=e.value,e instanceof Element&&e.tagName==b&&c.push(e);return c}function wf(a){return Array.from(a.childNodes).filter(function(b){return b instanceof Element})}
175
175
  function vf(a,b,c){var d=[];a=t(a.childNodes);for(var e=a.next();!e.done;e=a.next())e=e.value,e instanceof Element&&e.localName==c&&e.namespaceURI==b&&d.push(e);return d}function xf(a,b,c){return a.hasAttributeNS(b,c)?a.getAttributeNS(b,c):null}function yf(a,b,c){b=t(b);for(var d=b.next();!d.done;d=b.next())if(d=d.value,a.hasAttributeNS(d,c))return a.getAttributeNS(d,c);return null}function zf(a){return Array.from(a.childNodes).every(Af)?a.textContent.trim():null}
@@ -180,31 +180,31 @@ function Mf(a,b){var c=new DOMParser,d=Nf.value()(a),e=null;try{e=c.parseFromStr
180
180
  var Nf=new sc(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 Pf(a,b){var c=this;b=void 0===b?1:b;this.D=a;this.F=new Set;this.l=this.s=null;this.fa=this.ca=!1;this.G=0;this.g=null;this.o=new ef;this.i=new Map;this.C=[];this.u=new rc;this.h=null;this.m=function(d){c.u.reject(d);a.onError(d)};this.ka=new Map;this.da=new Map;this.V=new O(function(){return Qf(c)});this.L=!1;this.I=[];this.N=!1;this.ea=(new O(function(){Rf(c)})).Da(b);this.u["catch"](function(){});this.j=new cf(function(){return Sf(c)});this.W=!1}r=Pf.prototype;r.destroy=function(){return this.j.destroy()};
181
181
  function Sf(a){return L(function(b){switch(b.g){case 1:return a.o.release(),a.o=null,a.u.reject(),a.ea.stop(),a.ea=null,a.V.stop(),a.V=null,u(b,Tf(a),2);case 2:if(!a.l){b.B(3);break}C(b,4);return u(b,a.l.setMediaKeys(null),6);case 6:va(b,5);break;case 4:E(b);case 5:a.l=null;case 3:a.g=null,a.F.clear(),a.s=null,a.C=[],a.h=null,a.m=function(){},a.D=null,a.W=!1,A(b)}})}r.configure=function(a){this.h=a};function Uf(a,b,c){a.fa=!0;a.C=[];a.L=c;return Vf(a,b)}
182
182
  function Wf(a,b,c){a.C=c;a.L=0<c.length;return Vf(a,b)}function Xf(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 Yf(a,g,[])}
183
- function Vf(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v,y;return L(function(w){if(1==w.g){if(c=Zf(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(x){return x.video&&x.video.drmInfos.length||x.audio&&x.audio.drmInfos.length?!0:!1});g||(h=pf(a.h.servers),$f(b,h));k=t(b);for(e=k.next();!e.done;e=k.next())for(l=e.value,m=ag(l),n=t(m),p=n.next();!p.done;p=n.next())q=p.value,bg(q,pf(a.h.servers),pf(a.h.advanced||{}));return u(w,
184
- Ud(b,a.L,a.W),2)}v=g||Object.keys(a.h.servers).length;if(!v)return a.ca=!0,w["return"](Promise.resolve());y=Yf(a,void 0,b);return w["return"](g?y:y["catch"](function(){}))})}
183
+ function Vf(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v,w;return L(function(x){if(1==x.g){if(c=Zf(a))for(d=t(b),e=d.next();!e.done;e=d.next())f=e.value,f.video&&(f.video.drmInfos=[c]),f.audio&&(f.audio.drmInfos=[c]);g=b.some(function(y){return y.video&&y.video.drmInfos.length||y.audio&&y.audio.drmInfos.length?!0:!1});g||(h=pf(a.h.servers),$f(b,h));k=t(b);for(e=k.next();!e.done;e=k.next())for(l=e.value,m=ag(l),n=t(m),p=n.next();!p.done;p=n.next())q=p.value,bg(q,pf(a.h.servers),pf(a.h.advanced||{}));return u(x,
184
+ Ud(b,a.L,a.W),2)}v=g||Object.keys(a.h.servers).length;if(!v)return a.ca=!0,x["return"](Promise.resolve());w=Yf(a,void 0,b);return x["return"](g?w:w["catch"](function(){}))})}
185
185
  r.Wb=function(a){var b=this,c,d;return L(function(e){if(1==e.g){if(!b.s)return b.o.oa(a,"encrypted",function(){b.m(new N(2,6,6010))}),e["return"]();b.l=a;b.o.oa(b.l,"play",function(){for(var f=t(b.I),g=f.next();!g.done;g=f.next())cg(b,g.value);b.N=!0;b.I=[]});"webkitCurrentPlaybackTargetIsWireless"in b.l&&b.o.A(b.l,"webkitcurrentplaybacktargetiswirelesschanged",function(){return Tf(b)});c=b.l.setMediaKeys(b.s);c=c["catch"](function(f){return Promise.reject(new N(2,6,6003,f.message))});return u(e,
186
186
  c,2)}df(b.j);dg(b);b.g.initData.length||b.C.length||(d=function(f){return eg(b,f.initDataType,Fb(f.initData))},b.o.A(b.l,"encrypted",d));A(e)})};
187
187
  function fg(a){var b,c,d,e,f;return L(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.B(2);break}b=We([a.g.serverCertificateUri],a.h.retryParameters);C(g,3);c=a.D.nb.request(5,b);return u(g,c.promise,5);case 5:d=g.h;a.g.serverCertificate=Fb(d.data);va(g,4);break;case 3:throw e=E(g),new N(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"]();
188
188
  C(g,6);return u(g,a.s.setServerCertificate(a.g.serverCertificate),8);case 8:va(g,0);break;case 6:throw f=E(g),new N(2,6,6004,f.message);}})}function gg(a,b){var c,d,e;return L(function(f){if(1==f.g)return u(f,hg(a,b),2);if(3!=f.g){c=f.h;if(!c)return f["return"]();d=[];if(e=a.i.get(c))e.Ka=new rc,d.push(e.Ka);d.push(c.remove());return u(f,Promise.all(d),3)}a.i["delete"](c);A(f)})}
189
189
  function dg(a){for(var b=(a.g?a.g.initData:[])||[],c=t(b),d=c.next();!d.done;d=c.next())d=d.value,eg(a,d.initDataType,d.initData);c=t(a.C);for(d=c.next();!d.done;d=c.next())hg(a,d.value);b.length||a.C.length||a.u.resolve();return a.u}function eg(a,b,c){var d=a.i.values();d=t(d);for(var e=d.next();!e.done;e=d.next())if(Db(c,e.value.initData)&&!yc("Tizen 2"))return;ig(a,b,c,a.g.sessionType)}function jg(a){return a?!!a.match(/^com\.(microsoft|chromecast)\.playready/):!1}
190
190
  function kg(a){a=a.i.keys();a=nf(a,function(b){return b.sessionId});return Array.from(a)}r.cc=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.Gc=function(){return qf(this.da)};
191
- function Yf(a,b,c){var d,e,f,g,h,k,l,m,n,p,q,v,y;return L(function(w){switch(w.g){case 1:d=new Map;if(c.length){e=lg(a,c,d);w.B(2);break}return u(w,mg(a,b),3);case 3:e=w.h;case 2:f=e;if(!f)throw new N(2,6,6001);df(a.j);C(w,4);a.F.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.F.add(n.contentType.toLowerCase());p=t(k);for(m=p.next();!m.done;m=p.next())q=m.value,a.F.add(q.contentType.toLowerCase());if(c.length){var x=
192
- f.keySystem;var D=d.get(f.keySystem);var z=[],B=[],F=[],G=[],H=new Set;ng(D,z,F,B,G,H);var I=a.L?"persistent-license":"temporary";x={keySystem:x,licenseServerUri:z[0],distinctiveIdentifierRequired:D[0].distinctiveIdentifierRequired,persistentStateRequired:D[0].persistentStateRequired,sessionType:D[0].sessionType||I,audioRobustness:D[0].audioRobustness||"",videoRobustness:D[0].videoRobustness||"",serverCertificate:F[0],serverCertificateUri:B[0],initData:G,keyIds:H};D=t(D);for(z=D.next();!z.done;z=
193
- D.next())z=z.value,z.distinctiveIdentifierRequired&&(x.distinctiveIdentifierRequired=z.distinctiveIdentifierRequired),z.persistentStateRequired&&(x.persistentStateRequired=z.persistentStateRequired);D=x}else D=f.keySystem,x=b.get(f.keySystem),z=[],B=[],F=[],G=[],H=new Set,ng(x.drmInfos,z,F,B,G,H),D={keySystem:D,licenseServerUri:z[0],distinctiveIdentifierRequired:"required"==x.distinctiveIdentifier,persistentStateRequired:"required"==x.persistentState,sessionType:x.sessionTypes[0]||"temporary",audioRobustness:(x.audioCapabilities?
194
- x.audioCapabilities[0].robustness:"")||"",videoRobustness:(x.videoCapabilities?x.videoCapabilities[0].robustness:"")||"",serverCertificate:F[0],serverCertificateUri:B[0],initData:G,keyIds:H};a.g=D;if(!a.g.licenseServerUri)throw new N(2,6,6012,a.g.keySystem);return u(w,f.createMediaKeys(),6);case 6:return v=w.h,df(a.j),a.s=v,a.ca=!0,u(w,fg(a),7);case 7:df(a.j);va(w,0);break;case 4:y=E(w);df(a.j,y);a.g=null;a.F.clear();if(y instanceof N)throw y;throw new N(2,6,6002,y.message);}})}
191
+ function Yf(a,b,c){var d,e,f,g,h,k,l,m,n,p,q,v,w;return L(function(x){switch(x.g){case 1:d=new Map;if(c.length){e=lg(a,c,d);x.B(2);break}return u(x,mg(a,b),3);case 3:e=x.h;case 2:f=e;if(!f)throw new N(2,6,6001);df(a.j);C(x,4);a.F.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.F.add(n.contentType.toLowerCase());p=t(k);for(m=p.next();!m.done;m=p.next())q=m.value,a.F.add(q.contentType.toLowerCase());if(c.length){var y=
192
+ f.keySystem;var D=d.get(f.keySystem);var z=[],B=[],F=[],G=[],H=new Set;ng(D,z,F,B,G,H);var I=a.L?"persistent-license":"temporary";y={keySystem:y,licenseServerUri:z[0],distinctiveIdentifierRequired:D[0].distinctiveIdentifierRequired,persistentStateRequired:D[0].persistentStateRequired,sessionType:D[0].sessionType||I,audioRobustness:D[0].audioRobustness||"",videoRobustness:D[0].videoRobustness||"",serverCertificate:F[0],serverCertificateUri:B[0],initData:G,keyIds:H};D=t(D);for(z=D.next();!z.done;z=
193
+ D.next())z=z.value,z.distinctiveIdentifierRequired&&(y.distinctiveIdentifierRequired=z.distinctiveIdentifierRequired),z.persistentStateRequired&&(y.persistentStateRequired=z.persistentStateRequired);D=y}else D=f.keySystem,y=b.get(f.keySystem),z=[],B=[],F=[],G=[],H=new Set,ng(y.drmInfos,z,F,B,G,H),D={keySystem:D,licenseServerUri:z[0],distinctiveIdentifierRequired:"required"==y.distinctiveIdentifier,persistentStateRequired:"required"==y.persistentState,sessionType:y.sessionTypes[0]||"temporary",audioRobustness:(y.audioCapabilities?
194
+ y.audioCapabilities[0].robustness:"")||"",videoRobustness:(y.videoCapabilities?y.videoCapabilities[0].robustness:"")||"",serverCertificate:F[0],serverCertificateUri:B[0],initData:G,keyIds:H};a.g=D;if(!a.g.licenseServerUri)throw new N(2,6,6012,a.g.keySystem);return u(x,f.createMediaKeys(),6);case 6:return v=x.h,df(a.j),a.s=v,a.ca=!0,u(x,fg(a),7);case 7:df(a.j);va(x,0);break;case 4:w=E(x);df(a.j,w);a.g=null;a.F.clear();if(w instanceof N)throw w;throw new N(2,6,6002,w.message);}})}
195
195
  function lg(a,b,c){for(var d=t(b),e=d.next();!e.done;e=d.next()){var f=t(ag(e.value));for(e=f.next();!e.done;e=f.next())e=e.value,c.has(e.keySystem)||c.set(e.keySystem,[]),c.get(e.keySystem).push(e)}if(1==c.size&&c.has(""))throw new N(2,6,6E3);d={};a=t(a.h.preferredKeySystems);for(e=a.next();!e.done;d={ed:d.ed},e=a.next())for(d.ed=e.value,f=t(b),e=f.next();!e.done;e=f.next())if(e=e.value.decodingInfos.find(function(l){return function(m){return m.supported&&null!=m.keySystemAccess&&m.keySystemAccess.keySystem==
196
196
  l.ed}}(d)))return e.keySystemAccess;a=t([!0,!1]);for(e=a.next();!e.done;e=a.next())for(d=e.value,f=t(b),e=f.next();!e.done;e=f.next()){var g=t(e.value.decodingInfos);for(e=g.next();!e.done;e=g.next()){var h=e.value;if(h.supported&&h.keySystemAccess){e=c.get(h.keySystemAccess.keySystem);var k=t(e);for(e=k.next();!e.done;e=k.next())if(!!e.value.licenseServerUri==d)return h.keySystemAccess}}}return null}
197
- function mg(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v,y,w;return L(function(x){switch(x.g){case 1:if(1==b.size&&b.has(""))throw new N(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){x.B(4);break}k=h.value;if(!b.has(k)){x.B(3);break}l=b.get(k);C(x,6);return u(x,navigator.requestMediaKeySystemAccess(k,[l]),8);case 8:return c=
198
- x.h,x["return"](c);case 6:E(x);case 7:df(a.j);case 3:h=g.next();x.B(2);break;case 4:m=t([!0,!1]),n=m.next();case 9:if(n.done){x.B(11);break}p=n.value;q=t(b.keys());h=q.next();case 12:if(h.done){n=m.next();x.B(9);break}v=h.value;y=b.get(v);w=y.drmInfos.some(function(D){return!!D.licenseServerUri});if(w!=p){x.B(13);break}C(x,15);return u(x,navigator.requestMediaKeySystemAccess(v,[y]),17);case 17:return c=x.h,x["return"](c);case 15:E(x);case 16:df(a.j);case 13:h=q.next();x.B(12);break;case 11:return x["return"](c)}})}
197
+ function mg(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v,w,x;return L(function(y){switch(y.g){case 1:if(1==b.size&&b.has(""))throw new N(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){y.B(4);break}k=h.value;if(!b.has(k)){y.B(3);break}l=b.get(k);C(y,6);return u(y,navigator.requestMediaKeySystemAccess(k,[l]),8);case 8:return c=
198
+ y.h,y["return"](c);case 6:E(y);case 7:df(a.j);case 3:h=g.next();y.B(2);break;case 4:m=t([!0,!1]),n=m.next();case 9:if(n.done){y.B(11);break}p=n.value;q=t(b.keys());h=q.next();case 12:if(h.done){n=m.next();y.B(9);break}v=h.value;w=b.get(v);x=w.drmInfos.some(function(D){return!!D.licenseServerUri});if(x!=p){y.B(13);break}C(y,15);return u(y,navigator.requestMediaKeySystemAccess(v,[w]),17);case 17:return c=y.h,y["return"](c);case 15:E(y);case 16:df(a.j);case 13:h=q.next();y.B(12);break;case 11:return y["return"](c)}})}
199
199
  function Zf(a){a=pf(a.h.clearKeys);if(0==a.size)return null;var b=[],c=[];a.forEach(function(e,f){var g=Tc(f),h=Tc(e);g={kty:"oct",kid:Rc(g,!1),k:Rc(h,!1)};b.push(g);c.push(g.kid)});a=JSON.stringify({keys:b});var d=JSON.stringify({kids:c});d=[{initData:Fb(Nc(d)),initDataType:"keyids"}];return{keySystem:"org.w3.clearkey",licenseServerUri:"data:application/json;base64,"+window.btoa(a),distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,
200
200
  serverCertificateUri:"",sessionType:"",initData:d,keyIds:new Set(c)}}
201
- function hg(a,b){var c,d,e,f,g;return L(function(h){switch(h.g){case 1:try{c=a.s.createSession("persistent-license")}catch(k){return d=new N(2,6,6005,k.message),a.m(d),h["return"](Promise.reject(d))}a.o.A(c,"message",function(k){a.l&&a.h.delayLicenseRequestUntilPlayed&&a.l.paused&&!a.N?a.I.push(k):cg(a,k)});a.o.A(c,"keystatuseschange",function(k){return og(a,k)});e={initData:null,loaded:!1,Kd:Infinity,Ka:null,type:"persistent-license"};a.i.set(c,e);C(h,2);return u(h,c.load(b),4);case 4:f=h.h;df(a.j);
201
+ function hg(a,b){var c,d,e,f,g;return L(function(h){switch(h.g){case 1:try{c=a.s.createSession("persistent-license")}catch(k){return d=new N(2,6,6005,k.message),a.m(d),h["return"](Promise.reject(d))}a.o.A(c,"message",function(k){a.l&&a.h.delayLicenseRequestUntilPlayed&&a.l.paused&&!a.N?a.I.push(k):cg(a,k)});a.o.A(c,"keystatuseschange",function(k){return og(a,k)});e={initData:null,loaded:!1,Ld:Infinity,Ka:null,type:"persistent-license"};a.i.set(c,e);C(h,2);return u(h,c.load(b),4);case 4:f=h.h;df(a.j);
202
202
  if(!f)return a.i["delete"](c),a.m(new N(2,6,6013)),h["return"](Promise.resolve());e.loaded=!0;pg(a)&&a.u.resolve();return h["return"](c);case 2:g=E(h),df(a.j,g),a.i["delete"](c),a.m(new N(2,6,6005,g.message));case 3:return h["return"](Promise.resolve())}})}
203
- function ig(a,b,c,d){try{var e=a.s.createSession(d)}catch(f){a.m(new N(2,6,6005,f.message));return}a.o.A(e,"message",function(f){a.l&&a.h.delayLicenseRequestUntilPlayed&&a.l.paused&&!a.N?a.I.push(f):cg(a,f)});a.o.A(e,"keystatuseschange",function(f){return og(a,f)});a.i.set(e,{initData:c,loaded:!1,Kd:Infinity,Ka:null,type:d});try{c=a.h.initDataTransform(c,b,a.g)}catch(f){b=f;f instanceof N||(b=new N(2,6,6016,f));a.m(b);return}a.h.logLicenseExchange&&Rc(c);e.generateRequest(b,c)["catch"](function(f){if(!a.j.g){a.i["delete"](e);
203
+ function ig(a,b,c,d){try{var e=a.s.createSession(d)}catch(f){a.m(new N(2,6,6005,f.message));return}a.o.A(e,"message",function(f){a.l&&a.h.delayLicenseRequestUntilPlayed&&a.l.paused&&!a.N?a.I.push(f):cg(a,f)});a.o.A(e,"keystatuseschange",function(f){return og(a,f)});a.i.set(e,{initData:c,loaded:!1,Ld:Infinity,Ka:null,type:d});try{c=a.h.initDataTransform(c,b,a.g)}catch(f){b=f;f instanceof N||(b=new N(2,6,6016,f));a.m(b);return}a.h.logLicenseExchange&&Rc(c);e.generateRequest(b,c)["catch"](function(f){if(!a.j.g){a.i["delete"](e);
204
204
  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.m(new N(2,6,6006,f.message,f,h))}})}function qg(a,b,c){"skd"==b&&(b=c.serverCertificate,c=lf(a),a=mf(a,c,b));return a}
205
- function cg(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v,y;L(function(w){switch(w.g){case 1:return c=b.target,a.h.logLicenseExchange&&Rc(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=We([e],a.h.retryParameters),g.body=b.message,g.method="POST",g.licenseRequestType=b.messageType,g.sessionId=c.sessionId,jg(a.g.keySystem)&&rg(g),h=Date.now(),C(w,2),l=a.D.nb.request(2,g),u(w,
206
- l.promise,4);case 4:k=w.h;va(w,3);break;case 2:return m=E(w),n=new N(2,6,6007,m),a.m(n),d&&d.Ka&&d.Ka.reject(n),w["return"]();case 3:if(a.j.g)return w["return"]();a.G+=(Date.now()-h)/1E3;a.h.logLicenseExchange&&Rc(k.data);C(w,5);return u(w,c.update(k.data),7);case 7:va(w,6);break;case 5:return p=E(w),q=new N(2,6,6008,p.message),a.m(q),d&&d.Ka&&d.Ka.reject(q),w["return"]();case 6:if(a.j.g)return w["return"]();v=new Q("drmsessionupdate");a.D.onEvent(v);d&&(d.Ka&&d.Ka.resolve(),y=new O(function(){d.loaded=
207
- !0;pg(a)&&a.u.resolve()}),y.S(sg));A(w)}})}function rg(a){var b=Kc(a.body,!0,!0);if(b.includes("PlayReadyKeyMessage")){b=Mf(b,"PlayReadyKeyMessage");for(var c=t(b.getElementsByTagName("HttpHeader")),d=c.next();!d.done;d=c.next())d=d.value,a.headers[d.getElementsByTagName("name")[0].textContent]=d.getElementsByTagName("value")[0].textContent;a.body=Sc(b.getElementsByTagName("Challenge")[0].textContent)}else a.headers["Content-Type"]="text/xml; charset=utf-8"}
205
+ function cg(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v,w;L(function(x){switch(x.g){case 1:return c=b.target,a.h.logLicenseExchange&&Rc(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=We([e],a.h.retryParameters),g.body=b.message,g.method="POST",g.licenseRequestType=b.messageType,g.sessionId=c.sessionId,jg(a.g.keySystem)&&rg(g),h=Date.now(),C(x,2),l=a.D.nb.request(2,g),u(x,
206
+ l.promise,4);case 4:k=x.h;va(x,3);break;case 2:return m=E(x),n=new N(2,6,6007,m),a.m(n),d&&d.Ka&&d.Ka.reject(n),x["return"]();case 3:if(a.j.g)return x["return"]();a.G+=(Date.now()-h)/1E3;a.h.logLicenseExchange&&Rc(k.data);C(x,5);return u(x,c.update(k.data),7);case 7:va(x,6);break;case 5:return p=E(x),q=new N(2,6,6008,p.message),a.m(q),d&&d.Ka&&d.Ka.reject(q),x["return"]();case 6:if(a.j.g)return x["return"]();v=new Q("drmsessionupdate");a.D.onEvent(v);d&&(d.Ka&&d.Ka.resolve(),w=new O(function(){d.loaded=
207
+ !0;pg(a)&&a.u.resolve()}),w.S(sg));A(x)}})}function rg(a){var b=Kc(a.body,!0,!0);if(b.includes("PlayReadyKeyMessage")){b=Mf(b,"PlayReadyKeyMessage");for(var c=t(b.getElementsByTagName("HttpHeader")),d=c.next();!d.done;d=c.next())d=d.value,a.headers[d.getElementsByTagName("name")[0].textContent]=d.getElementsByTagName("value")[0].textContent;a.body=Sc(b.getElementsByTagName("Challenge")[0].textContent)}else a.headers["Content-Type"]="text/xml; charset=utf-8"}
208
208
  function og(a,b){var c=b.target,d=a.i.get(c),e=!1;c.keyStatuses.forEach(function(g,h){if("string"==typeof h){var k=h;h=g;g=k}if(jg(a.g.keySystem)&&16==h.byteLength&&(navigator.userAgent.match(/Edge?\//)||Dc())){k=Ib(h);var l=k.getUint32(0,!0),m=k.getUint16(4,!0),n=k.getUint16(6,!0);k.setUint32(0,l,!1);k.setUint16(4,m,!1);k.setUint16(6,n,!1)}"status-pending"!=g&&(d.loaded=!0);"expired"==g&&(e=!0);k=Uc(h).slice(0,32);a.ka.set(k,g)});var f=c.expiration-Date.now();(0>f||e&&1E3>f)&&d&&!d.Ka&&(a.i["delete"](c),
209
209
  c.close()["catch"](function(){}));pg(a)&&(a.u.resolve(),a.V.S(tg))}function Qf(a){var b=a.ka,c=a.da;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.m(new N(2,6,6014));a.D.Pc(qf(c))}
210
210
  function ug(){var a,b,c,d,e,f,g,h;return L(function(k){return 1==k.g?(a="org.w3.clearkey com.widevine.alpha com.microsoft.playready com.microsoft.playready.recommendation com.apple.fps.3_0 com.apple.fps.2_0 com.apple.fps.1_0 com.apple.fps com.adobe.primetime".split(" "),b=[{contentType:'video/mp4; codecs="avc1.42E01E"'},{contentType:'video/webm; codecs="vp8"'}],c={initDataTypes:["cenc"],videoCapabilities:b},d={videoCapabilities:b,persistentState:"required",sessionTypes:["persistent-license"]},e=[d,
@@ -213,7 +213,7 @@ function vg(a){var b;return L(function(c){if(1==c.g)return b=new Promise(functio
213
213
  function Tf(a){var b;return L(function(c){b=Array.from(a.i.entries());a.i.clear();return u(c,Promise.all(b.map(function(d){d=t(d);var e=d.next().value,f=d.next().value;return L(function(g){if(1==g.g)return C(g,2),a.fa||a.C.includes(e.sessionId)||"persistent-license"!==f.type?u(g,vg(e),5):u(g,e.remove(),5);if(2!=g.g)return va(g,0);E(g);A(g)})})),0)})}
214
214
  function xg(a,b){if(!a.length)return b;if(!b.length)return a;for(var c=[],d=t(a),e=d.next();!e.done;e=d.next()){e=e.value;for(var f={},g=t(b),h=g.next();!h.done;f={Ea:f.Ea},h=g.next())if(h=h.value,e.keySystem==h.keySystem){f.Ea=[];f.Ea=f.Ea.concat(e.initData||[]);f.Ea=f.Ea.concat(h.initData||[]);f.Ea=f.Ea.filter(function(k){return function(l,m){return void 0===l.keyId||m===k.Ea.findIndex(function(n){return n.keyId===l.keyId})}}(f));g=e.keyIds&&h.keyIds?new Set([].concat(ja(e.keyIds),ja(h.keyIds))):
215
215
  e.keyIds||h.keyIds;c.push({keySystem:e.keySystem,licenseServerUri:e.licenseServerUri||h.licenseServerUri,distinctiveIdentifierRequired:e.distinctiveIdentifierRequired||h.distinctiveIdentifierRequired,persistentStateRequired:e.persistentStateRequired||h.persistentStateRequired,videoRobustness:e.videoRobustness||h.videoRobustness,audioRobustness:e.audioRobustness||h.audioRobustness,serverCertificate:e.serverCertificate||h.serverCertificate,serverCertificateUri:e.serverCertificateUri||h.serverCertificateUri,
216
- initData:f.Ea,keyIds:g});break}}return c}function ag(a){return(a.video?a.video.drmInfos:[]).concat(a.audio?a.audio.drmInfos:[])}function Rf(a){a.i.forEach(function(b,c){var d=b.Kd,e=c.expiration;isNaN(e)&&(e=Infinity);e!=d&&(a.D.onExpirationUpdated(c.sessionId,e),b.Kd=e)})}function pg(a){a=a.i.values();return of(a,function(b){return b.loaded})}
216
+ initData:f.Ea,keyIds:g});break}}return c}function ag(a){return(a.video?a.video.drmInfos:[]).concat(a.audio?a.audio.drmInfos:[])}function Rf(a){a.i.forEach(function(b,c){var d=b.Ld,e=c.expiration;isNaN(e)&&(e=Infinity);e!=d&&(a.D.onExpirationUpdated(c.sessionId,e),b.Ld=e)})}function pg(a){a=a.i.values();return of(a,function(b){return b.loaded})}
217
217
  function $f(a,b){var c=[];b.forEach(function(f,g){c.push({keySystem:g,licenseServerUri:f,distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,serverCertificateUri:"",initData:[],keyIds:new Set})});for(var d=t(a),e=d.next();!e.done;e=d.next())e=e.value,e.video&&(e.video.drmInfos=c),e.audio&&(e.audio.drmInfos=c)}
218
218
  function ng(a,b,c,d,e,f){var g={};a=t(a);for(var h=a.next();!h.done;g={ra:g.ra},h=a.next()){g.ra=h.value;b.includes(g.ra.licenseServerUri)||b.push(g.ra.licenseServerUri);d.includes(g.ra.serverCertificateUri)||d.push(g.ra.serverCertificateUri);g.ra.serverCertificate&&(c.some(function(m){return function(n){return Db(n,m.ra.serverCertificate)}}(g))||c.push(g.ra.serverCertificate));if(g.ra.initData){h={};for(var k=t(g.ra.initData),l=k.next();!l.done;h={tc:h.tc},l=k.next())h.tc=l.value,e.some(function(m){return function(n){var p=
219
219
  m.tc;return n.keyId&&n.keyId==p.keyId?!0:n.initDataType==p.initDataType&&Db(n.initData,p.initData)}}(h))||e.push(h.tc)}if(g.ra.keyIds)for(h=t(g.ra.keyIds),k=h.next();!k.done;k=h.next())f.add(k.value)}}
@@ -230,8 +230,8 @@ function Jg(a){var b=0;a=t(a);for(var c=a.next();!c.done;c=a.next())b=b<<8|c.val
230
230
  Ig.prototype.fullBox=Ig.prototype.P;Ig.prototype.box=Ig.prototype.box;var Kg=0,Lg=1;function Rg(a){function b(){d=!0}function c(l){f.push(l);Mg(l)}a=Fb(a);var d=!1,e,f=[],g=[];(new Ig).box("moov",c).box("trak",c).box("mdia",c).box("minf",c).box("stbl",c).P("stsd",function(l){e=l;f.push(l);Og(l)}).P("encv",b).P("enca",b).P("hev1",function(l){g.push({box:l,ob:1701733238})}).P("hvc1",function(l){g.push({box:l,ob:1701733238})}).P("avc1",function(l){g.push({box:l,ob:1701733238})}).P("avc3",function(l){g.push({box:l,ob:1701733238})}).P("ac-3",function(l){g.push({box:l,ob:1701733217})}).P("ec-3",
231
231
  function(l){g.push({box:l,ob:1701733217})}).P("mp4a",function(l){g.push({box:l,ob:1701733217})}).parse(a);if(d)return a;if(0==g.length||!e)throw ab(Uc(a)),new N(2,3,3019);g.reverse();for(var h=t(g),k=h.next();!k.done;k=h.next())k=k.value,a=Sg(a,e,k.box,f,k.ob);return a}
232
232
  function Sg(a,b,c,d,e){var f=Tg.value(),g=a.subarray(c.start,c.start+c.size),h=Ib(g),k=new Uint8Array(c.size+f.byteLength);k.set(g,0);g=Ib(k);g.setUint32(4,e);k.set(f,c.size);e=h.getUint32(4);g.setUint32(c.size+16,e);Ug(k,0,k.byteLength);e=new Uint8Array(a.byteLength+k.byteLength);c=xc()?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,Ug(e,d.start,d.size+k.byteLength);k=Ib(e,b.start);b=Ng(b);a=k.getUint32(b);
233
- k.setUint32(b,a+1);return e}function Ug(a,b,c){a=Ib(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 Tg=new sc(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 Vg(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(B){return null!=B&&""!=B.g.trim()})){f=h;break}for(h=c.length-1;0<=h;h--)if(c[h].some(function(B){return null!=B&&""!=B.g.trim()})){g=h;break}if(-1===f||-1===g)return null;for(var k=h=!1,l="white",m="black",n=Wg(d,e,h,k,l,m);f<=g;f++){for(var p=c[f],q=-1,v=-1,y=0;y<p.length;y++)if(null!=p[y]&&""!==p[y].g.trim()){q=y;break}for(y=p.length-1;0<=y;y--)if(null!=p[y]&&""!==p[y].g.trim()){v=y;break}if(-1===
234
- q||-1===v)p=Xg(d,e),a.nestedCues.push(p);else{for(;q<=v;q++)if(y=p[q]){var w=y.l,x=y.i,D=y.j,z=y.h;if(w!=h||x!=k||D!=l||z!=m)n.payload&&a.nestedCues.push(n),n=Wg(d,e,w,x,D,z),h=w,k=x,l=D,m=z;n.payload+=y.g}else n.payload+=" ";n.payload&&a.nestedCues.push(n);f!==g&&(n=Xg(d,e),a.nestedCues.push(n));n=Wg(d,e,h,k,l,m)}}return a.nestedCues.length?{cue:a,stream:b}:null}
233
+ k.setUint32(b,a+1);return e}function Ug(a,b,c){a=Ib(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 Tg=new sc(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 Vg(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(B){return null!=B&&""!=B.g.trim()})){f=h;break}for(h=c.length-1;0<=h;h--)if(c[h].some(function(B){return null!=B&&""!=B.g.trim()})){g=h;break}if(-1===f||-1===g)return null;for(var k=h=!1,l="white",m="black",n=Wg(d,e,h,k,l,m);f<=g;f++){for(var p=c[f],q=-1,v=-1,w=0;w<p.length;w++)if(null!=p[w]&&""!==p[w].g.trim()){q=w;break}for(w=p.length-1;0<=w;w--)if(null!=p[w]&&""!==p[w].g.trim()){v=w;break}if(-1===
234
+ q||-1===v)p=Xg(d,e),a.nestedCues.push(p);else{for(;q<=v;q++)if(w=p[q]){var x=w.l,y=w.i,D=w.j,z=w.h;if(x!=h||y!=k||D!=l||z!=m)n.payload&&a.nestedCues.push(n),n=Wg(d,e,x,y,D,z),h=x,k=y,l=D,m=z;n.payload+=w.g}else n.payload+=" ";n.payload&&a.nestedCues.push(n);f!==g&&(n=Xg(d,e),a.nestedCues.push(n));n=Wg(d,e,h,k,l,m)}}return a.nestedCues.length?{cue:a,stream:b}:null}
235
235
  function Wg(a,b,c,d,e,f){a=new ib(a,b,"");c&&a.textDecoration.push("underline");d&&(a.fontStyle="italic");a.color=e;a.backgroundColor=f;return a}function Xg(a,b){var c=new ib(a,b,"");c.lineBreak=!0;return c}function Yg(a,b,c,d,e){this.g=a;this.l=b;this.i=c;this.h=d;this.j=e};function Zg(a,b){this.i=[];this.g=1;this.h=0;this.u=a;this.s=b;this.j=this.m=!1;this.l="white";this.o="black";$g(this)}function ah(a,b,c){return Vg(new ib(b,c,""),"CC"+(a.u<<1|a.s+1),a.i,b,c)}function $g(a){bh(a,0,15);a.g=1}function ch(a,b,c){if(!(32>c||127<c)){var d="";switch(b){case dh:d=eh.has(c)?eh.get(c):String.fromCharCode(c);break;case fh:d=gh.get(c);break;case hh:a.i[a.g].pop();d=ih.get(c);break;case jh:a.i[a.g].pop(),d=kh.get(c)}d&&a.i[a.g].push(new Yg(d,a.m,a.j,a.o,a.l))}}
236
236
  function lh(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 bh(a,b,c){for(var d=0;d<=c;d++)a.i[b+d]=[]}
237
237
  var dh=0,fh=1,hh=2,jh=3,eh=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"]]),gh=new Map([[48,"\u00ae"],[49,"\u00b0"],[50,"\u00bd"],[51,"\u00bf"],[52,"\u2122"],[53,"\u00a2"],[54,"\u00a3"],[55,"\u266a"],[56,"\u00e0"],[57,"\u2800"],[58,"\u00e8"],[59,"\u00e2"],[60,"\u00ea"],[61,"\u00ee"],[62,"\u00f4"],[63,"\u00fb"]]),ih=new Map([[32,"\u00c1"],[33,"\u00c9"],[34,"\u00d3"],
@@ -249,13 +249,13 @@ function Uh(a,b){var c=b.type;if(16===(b.Aa&112)){var d=b.Aa>>3&1;0===c?a.m=d:a.
249
249
  d=1===(d&1);if(c.h!==qh){f=c.g;if(c.h===ph&&e!==f.g){var k=1+e-f.h;lh(f,k,1+f.g-f.h,f.h);bh(f,0,k-1);bh(f,e+1,15-e)}f.g=e;c.g.m=d;c.g.j=h;c.g.l=g;c.g.o="black"}}else if(17===(e&247)&&32===(d&240))c.g.m=!1,c.g.j=!1,c.g.l="white",ch(c.g,dh,32),g=!1,e=vh[(d&14)>>1],"white_italics"===e&&(e="white",g=!0),c.g.m=1===(d&1),c.g.j=g,c.g.l=e;else if(16===(e&247)&&32===(d&240)||23===(e&247)&&45===(d&255))g="black",0===(e&7)&&(g=uh[(d&14)>>1]),c.g.o=g;else if(17===(e&247)&&48===(d&240))ch(c.g,fh,d);else if(18===
250
250
  (e&246)&&32===(d&224))ch(c.g,e&1?jh:hh,d);else if(20===(e&246)&&32===(d&240)){d=b.pts;e=null;switch(b.Oa){case 32:rh(c);break;case 33:c=c.g;c.i[c.g].pop();break;case 37:e=oh(c,2,d);break;case 38:e=oh(c,3,d);break;case 39:e=oh(c,4,d);break;case 40:ch(c.g,dh,32);break;case 41:c.h=2;c.g=c.i;c.g.h=0;c.j=d;break;case 42:$g(c.o);th(c);break;case 43:th(c);break;case 44:e=c.i;g=null;c.h!==qh&&(g=ah(e,c.j,d));bh(e,0,15);e=g;break;case 45:e=c.g;c.h!==ph?e=null:(g=ah(e,c.j,d),h=e.g-e.h+1,lh(e,h-1,h,e.h),bh(e,
251
251
  0,h-1),bh(e,e.g,15-e.g),c.j=d,e=g);break;case 46:bh(c.l,0,15);break;case 47:e=null,c.h!==qh&&(e=ah(c.i,c.j,d)),g=c.l,c.l=c.i,c.i=g,rh(c),c.j=d}d=e;break a}d=null}else e=b.Oa,ch(c.g,dh,b.Aa),ch(c.g,dh,e);return d}
252
- function Vh(a,b){var c=[];try{for(;b.ma();){var d=Ih(b).value,e=(d&224)>>5,f=d&31;7===e&&0!=f&&(e=Ih(b).value&63);if(0!=e){a.j.has(e)||a.j.set(e,new Jh(e));for(var g=a.j.get(e),h=b.X();b.X()-h<f;){e=b;var k=Ih(e),l=k.value,m=k.pts;if(16===l){var n=Ih(e);l=l<<16|n.value}if(0<=l&&31>=l){var p=m;if(g.g){var q=g.g;e=null;switch(l){case 8:!Bh(q)||0>=q.g&&0>=q.h||(0>=q.g?(q.g=q.C-1,q.h--):q.g--,q.i[q.h][q.g]=null);break;case 13:q.isVisible()&&(e=Ch(q,p,g.i));if(q.h+1>=q.F){p=q;for(var v=0,y=1;16>y;y++,
253
- v++)p.i[v]=p.i[y];for(y=0;1>y;y++,v++)p.i[v]=zh()}else q.h++;q.g=0;break;case 14:q.isVisible()&&(e=Ch(q,p,g.i));q.i[q.h]=zh();q.g=0;break;case 12:q.isVisible()&&(e=Ch(q,p,g.i)),yh(q),p=q,p.h=0,p.g=0}var w=e}else w=null}else if(128<=l&&159>=l)w=Kh(g,e,l,m);else{if(4096<=l&&4127>=l)p=l&255,8<=p&&15>=p?e.skip(1):16<=p&&23>=p?e.skip(2):24<=p&&31>=p&&e.skip(3);else if(4224<=l&&4255>=l)p=l&255,128<=p&&135>=p?e.skip(4):136<=p&&143>=p&&e.skip(5);else if(32<=l&&127>=l)e=l,g.g&&(127===e?Ah(g.g,"\u266a"):Ah(g.g,
254
- String.fromCharCode(e)));else if(160<=l&&255>=l)g.g&&Ah(g.g,String.fromCharCode(l));else if(4128<=l&&4223>=l){if(e=l&255,g.g)if(Qh.has(e)){var x=Qh.get(e);Ah(g.g,x)}else Ah(g.g,"_")}else 4256<=l&&4351>=l&&g.g&&(160!=(l&255)?Ah(g.g,"_"):Ah(g.g,"[CC]"));w=null}(e=w)&&c.push(e)}}}}catch(D){if(D instanceof N&&3E3===D.code)Va("CEA708_INVALID_DATA","Buffer read out of bounds / invalid CEA-708 Data.");else throw D;}return c}function Wh(a){for(var b=0;a;)b^=a&1,a>>=1;return 1===b};function Xh(a,b){var c=null,d=null,e=a.M();b&1&&a.skip(8);b&2&&a.skip(4);b&8&&(c=a.M());b&16&&(d=a.M());return{trackId:e,he:c,Xe:d}}function Yh(a,b){return{pd:1==b?a.Lb():a.M()}}function Zh(a,b){1==b?(a.skip(8),a.skip(8)):(a.skip(4),a.skip(4));return{timescale:a.M()}}
255
- function $h(a,b,c){var d=a.M(),e=[];c&1&&a.skip(4);c&4&&a.skip(4);for(var f=0;f<d;f++){var g={Rd:null,sampleSize:null,Tc:null};c&256&&(g.Rd=a.M());c&512&&(g.sampleSize=a.M());c&1024&&a.skip(4);c&2048&&(g.Tc=0==b?a.M():a.we());e.push(g)}return{Rg:d,ze:e}};function ai(){this.i=new Map;this.h=this.g=0}
252
+ function Vh(a,b){var c=[];try{for(;b.ma();){var d=Ih(b).value,e=(d&224)>>5,f=d&31;7===e&&0!=f&&(e=Ih(b).value&63);if(0!=e){a.j.has(e)||a.j.set(e,new Jh(e));for(var g=a.j.get(e),h=b.X();b.X()-h<f;){e=b;var k=Ih(e),l=k.value,m=k.pts;if(16===l){var n=Ih(e);l=l<<16|n.value}if(0<=l&&31>=l){var p=m;if(g.g){var q=g.g;e=null;switch(l){case 8:!Bh(q)||0>=q.g&&0>=q.h||(0>=q.g?(q.g=q.C-1,q.h--):q.g--,q.i[q.h][q.g]=null);break;case 13:q.isVisible()&&(e=Ch(q,p,g.i));if(q.h+1>=q.F){p=q;for(var v=0,w=1;16>w;w++,
253
+ v++)p.i[v]=p.i[w];for(w=0;1>w;w++,v++)p.i[v]=zh()}else q.h++;q.g=0;break;case 14:q.isVisible()&&(e=Ch(q,p,g.i));q.i[q.h]=zh();q.g=0;break;case 12:q.isVisible()&&(e=Ch(q,p,g.i)),yh(q),p=q,p.h=0,p.g=0}var x=e}else x=null}else if(128<=l&&159>=l)x=Kh(g,e,l,m);else{if(4096<=l&&4127>=l)p=l&255,8<=p&&15>=p?e.skip(1):16<=p&&23>=p?e.skip(2):24<=p&&31>=p&&e.skip(3);else if(4224<=l&&4255>=l)p=l&255,128<=p&&135>=p?e.skip(4):136<=p&&143>=p&&e.skip(5);else if(32<=l&&127>=l)e=l,g.g&&(127===e?Ah(g.g,"\u266a"):Ah(g.g,
254
+ String.fromCharCode(e)));else if(160<=l&&255>=l)g.g&&Ah(g.g,String.fromCharCode(l));else if(4128<=l&&4223>=l){if(e=l&255,g.g)if(Qh.has(e)){var y=Qh.get(e);Ah(g.g,y)}else Ah(g.g,"_")}else 4256<=l&&4351>=l&&g.g&&(160!=(l&255)?Ah(g.g,"_"):Ah(g.g,"[CC]"));x=null}(e=x)&&c.push(e)}}}}catch(D){if(D instanceof N&&3E3===D.code)Va("CEA708_INVALID_DATA","Buffer read out of bounds / invalid CEA-708 Data.");else throw D;}return c}function Wh(a){for(var b=0;a;)b^=a&1,a>>=1;return 1===b};function Xh(a,b){var c=null,d=null,e=a.M();b&1&&a.skip(8);b&2&&a.skip(4);b&8&&(c=a.M());b&16&&(d=a.M());return{trackId:e,ie:c,Xe:d}}function Yh(a,b){return{pd:1==b?a.Lb():a.M()}}function Zh(a,b){1==b?(a.skip(8),a.skip(8)):(a.skip(4),a.skip(4));return{timescale:a.M()}}
255
+ function $h(a,b,c){var d=a.M(),e=[];c&1&&a.skip(4);c&4&&a.skip(4);for(var f=0;f<d;f++){var g={Sd:null,sampleSize:null,Tc:null};c&256&&(g.Sd=a.M());c&512&&(g.sampleSize=a.M());c&1024&&a.skip(4);c&2048&&(g.Tc=0==b?a.M():a.we());e.push(g)}return{Rg:d,ze:e}};function ai(){this.i=new Map;this.h=this.g=0}
256
256
  ai.prototype.init=function(a){var b=this,c=[],d=[];(new Ig).box("moov",Mg).box("mvex",Mg).P("trex",function(e){var f=e.reader;f.skip(4);f.skip(4);e=f.M();f=f.M();b.g=e;b.h=f}).box("trak",Mg).P("tkhd",function(e){var f=e.reader;1==e.version?(f.skip(8),f.skip(8)):(f.skip(4),f.skip(4));e=f.M();c.push(e)}).box("mdia",Mg).P("mdhd",function(e){e=Zh(e.reader,e.version);d.push(e.timescale)}).parse(a,!0);if(!c.length||!d.length||c.length!=d.length)throw new N(2,2,2010);c.forEach(function(e,f){b.i.set(e,d[f])})};
257
- ai.prototype.parse=function(a){var b=this,c=[],d=this.g,e=this.h,f=[],g=null,h=9E4;(new Ig).box("moof",Mg).box("traf",Mg).P("trun",function(k){f=$h(k.reader,k.version,k.flags).ze}).P("tfhd",function(k){k=Xh(k.reader,k.flags);d=k.he||b.g;e=k.Xe||b.h;k=k.trackId;b.i.has(k)&&(h=b.i.get(k))}).P("tfdt",function(k){g=Yh(k.reader,k.version).pd}).box("mdat",function(k){if(null===g)throw new N(2,2,2010);k=k.reader;var l=g,m=h,n=d,p=e,q=f,v=0,y=p;for(q.length&&(y=q[0].sampleSize||p);k.ma();){var w=k.M();if(6==
258
- (k.Y()&31)){var x=0;q.length>v&&(x=q[v].Tc||0);x=(l+x)/m;for(var D=[],z,B=k.Za(w-1),F=z=0;F<B.length;)2==z&&3==B[F]?(z=0,B=[].concat(ja(B)),B.splice(F,1),B=new Uint8Array(B)):0==B[F]?z++:z=0,F++;z=B;for(F=0;F<z.length;){for(B=0;255==z[F];)B+=255,F++;B+=z[F++];for(var G=0;255==z[F];)G+=255,F++;G+=z[F++];4==B&&D.push(z.subarray(F,F+G));F+=G}D=t(D);for(z=D.next();!z.done;z=D.next())c.push({Lf:z.value,pts:x})}else try{k.skip(w-1)}catch(H){break}y-=w+4;0==y&&(l=q.length>v?l+(q[v].Rd||n):l+n,v++,y=q.length>
257
+ ai.prototype.parse=function(a){var b=this,c=[],d=this.g,e=this.h,f=[],g=null,h=9E4;(new Ig).box("moof",Mg).box("traf",Mg).P("trun",function(k){f=$h(k.reader,k.version,k.flags).ze}).P("tfhd",function(k){k=Xh(k.reader,k.flags);d=k.ie||b.g;e=k.Xe||b.h;k=k.trackId;b.i.has(k)&&(h=b.i.get(k))}).P("tfdt",function(k){g=Yh(k.reader,k.version).pd}).box("mdat",function(k){if(null===g)throw new N(2,2,2010);k=k.reader;var l=g,m=h,n=d,p=e,q=f,v=0,w=p;for(q.length&&(w=q[0].sampleSize||p);k.ma();){var x=k.M();if(6==
258
+ (k.Y()&31)){var y=0;q.length>v&&(y=q[v].Tc||0);y=(l+y)/m;for(var D=[],z,B=k.Za(x-1),F=z=0;F<B.length;)2==z&&3==B[F]?(z=0,B=[].concat(ja(B)),B.splice(F,1),B=new Uint8Array(B)):0==B[F]?z++:z=0,F++;z=B;for(F=0;F<z.length;){for(B=0;255==z[F];)B+=255,F++;B+=z[F++];for(var G=0;255==z[F];)G+=255,F++;G+=z[F++];4==B&&D.push(z.subarray(F,F+G));F+=G}D=t(D);for(z=D.next();!z.done;z=D.next())c.push({Lf:z.value,pts:y})}else try{k.skip(x-1)}catch(H){break}w-=x+4;0==w&&(l=q.length>v?l+(q[v].Sd||n):l+n,v++,w=q.length>
259
259
  v?q[v].sampleSize||p:p)}}).parse(a,!1);return c};function bi(){this.h=new ai;this.g=new Rh}bi.prototype.init=function(a){this.h.init(a)};
260
260
  function ci(a,b){var c=a.h.parse(b);c=t(c);for(var d=c.next();!d.done;d=c.next()){var e=d.value,f=Fb(e.Lf);if(0<f.length&&(d=a.g,e=e.pts,f=new Fg(f,0),181===f.Y()&&49===f.Kb()&&1195456820===f.M()&&3===f.Y())){var g=f.Y();if(0!==(g&64)){g&=31;f.skip(1);for(var h=0;h<g;h++){var k=f.Y(),l=(k&4)>>2,m=f.Y(),n=f.Y();l&&(k&=3,0===k||1===k?d.h.push({pts:e,type:k,Aa:m,Oa:n,order:d.h.length}):(d.g.push({pts:e,type:k,value:m,order:d.g.length}),d.g.push({pts:e,type:2,value:n,order:d.g.length})))}}}}return Th(a.g)}
261
261
  ;function di(a){return!a||1==a.length&&1E-6>a.end(0)-a.start(0)?null:a.length?a.end(a.length-1):null}function ei(a,b,c){c=void 0===c?0:c;return!a||!a.length||1==a.length&&1E-6>a.end(0)-a.start(0)||b>a.end(a.length-1)?!1:b+c>=a.start(0)}function fi(a,b){if(!a||!a.length||1==a.length&&1E-6>a.end(0)-a.start(0))return 0;for(var c=0,d=t(gi(a)),e=d.next();!e.done;e=d.next()){var f=e.value;e=f.start;f=f.end;f>b&&(c+=f-Math.max(e,b))}return c}
@@ -271,22 +271,22 @@ function Bi(a,b){var c;return L(function(d){c=qc;return b==c.Z?a.g?u(d,a.g.remov
271
271
  function Ci(a,b,c,d,e){var f;return L(function(g){f=qc;return b==f.Z?(a.g.u=c,jd(a.g,d,e),g["return"]()):u(g,Promise.all([yi(a,b,function(){var h=a.h[b].appendWindowStart,k=a.h[b].appendWindowEnd;a.h[b].abort();a.h[b].appendWindowStart=h;a.h[b].appendWindowEnd=k;qi(a,b)}),yi(a,b,function(){var h=c;0>h&&(h+=.001);a.h[b].timestampOffset=h;qi(a,b)}),yi(a,b,function(){a.h[b].appendWindowStart=0;a.h[b].appendWindowEnd=e;a.h[b].appendWindowStart=d;qi(a,b)})]),0)})}
272
272
  r.endOfStream=function(a){var b=this;return L(function(c){return u(c,Di(b,function(){ri(b)||(a?b.m.endOfStream(a):b.m.endOfStream())}),0)})};r.Ja=function(a){var b=this;return L(function(c){return u(c,Di(b,function(){b.m.duration=a}),0)})};r.getDuration=function(){return this.m.duration};function qi(a,b){var c=a.i[b][0];c&&(c.p.resolve(),Ei(a,b))}function yi(a,b,c){df(a.C);c={start:c,p:new rc};a.i[b].push(c);1==a.i[b].length&&Fi(a,b);return c.p}
273
273
  function Di(a,b){var c,d,e,f,g,h;return L(function(k){switch(k.g){case 1:df(a.C);c=[];d={};for(e in a.h)d.Rb=new rc,f={start:function(l){return function(){return l.Rb.resolve()}}(d),p:d.Rb},a.i[e].push(f),c.push(d.Rb),1==a.i[e].length&&f.start(),d={Rb:d.Rb};C(k,2);return u(k,Promise.all(c),4);case 4:va(k,3);break;case 2:throw g=E(k),g;case 3:try{b()}catch(l){throw new N(2,3,3015,l);}finally{for(h in a.h)Ei(a,h)}A(k)}})}function Ei(a,b){a.i[b].shift();Fi(a,b)}
274
- function Fi(a,b){var c=a.i[b][0];if(c)try{c.start()}catch(d){"QuotaExceededError"==d.name?c.p.reject(new N(2,3,3017,b)):c.p.reject(new N(2,3,3015,d)),Ei(a,b)}}function xi(a,b,c,d){var e=a.G[d];null==c&&e&&(zc()||xc())&&"mp4"==a.I[d].split(";")[0].split("/")[1]&&(b=Rg(b));return b}var oi=window.URL.createObjectURL;function Gi(a,b,c,d){this.sa=a;this.pa=b;this.ha=c;this.Dd=void 0===d?null:d}Gi.prototype.fc=function(){return this.pa};Gi.prototype.bc=function(){return this.ha};function Hi(a,b){return a&&b?a.fc()==b.fc()&&a.bc()==b.bc()&&hb(a.sa(),b.sa()):a==b}M("shaka.media.InitSegmentReference",Gi);Gi.prototype.getEndByte=Gi.prototype.bc;Gi.prototype.getStartByte=Gi.prototype.fc;
274
+ function Fi(a,b){var c=a.i[b][0];if(c)try{c.start()}catch(d){"QuotaExceededError"==d.name?c.p.reject(new N(2,3,3017,b)):c.p.reject(new N(2,3,3015,d)),Ei(a,b)}}function xi(a,b,c,d){var e=a.G[d];null==c&&e&&(zc()||xc())&&"mp4"==a.I[d].split(";")[0].split("/")[1]&&(b=Rg(b));return b}var oi=window.URL.createObjectURL;function Gi(a,b,c,d){this.sa=a;this.pa=b;this.ha=c;this.Ed=void 0===d?null:d}Gi.prototype.fc=function(){return this.pa};Gi.prototype.bc=function(){return this.ha};function Hi(a,b){return a&&b?a.fc()==b.fc()&&a.bc()==b.bc()&&hb(a.sa(),b.sa()):a==b}M("shaka.media.InitSegmentReference",Gi);Gi.prototype.getEndByte=Gi.prototype.bc;Gi.prototype.getStartByte=Gi.prototype.fc;
275
275
  function Ii(a,b,c,d,e,f,g,h,k,l,m,n){l=void 0===l?[]:l;this.startTime=a;this.l=this.endTime=b;this.j=c;this.pa=d;this.ha=e;this.g=f;this.timestampOffset=g;this.appendWindowStart=h;this.appendWindowEnd=k;this.h=l;this.tilesLayout=void 0===m?"":m;this.i=void 0===n?null:n}r=Ii.prototype;r.sa=function(){return this.j()};r.getStartTime=function(){return this.startTime};r.ef=function(){return this.endTime};r.fc=function(){return this.pa};r.bc=function(){return this.ha};r.yf=function(){return this.tilesLayout};
276
- r.xf=function(){return this.i};M("shaka.media.SegmentReference",Ii);Ii.prototype.getTileDuration=Ii.prototype.xf;Ii.prototype.getTilesLayout=Ii.prototype.yf;Ii.prototype.getEndByte=Ii.prototype.bc;Ii.prototype.getStartByte=Ii.prototype.fc;Ii.prototype.getEndTime=Ii.prototype.ef;Ii.prototype.getStartTime=Ii.prototype.getStartTime;Ii.prototype.getUris=Ii.prototype.sa;function S(a,b,c){this.l=a;this.Sc=b;this.m=this.i=Infinity;this.g=1;this.h=this.j=null;this.o=0;this.s=!0;this.u=0;this.C=void 0===c?!0:c;this.D=0;this.F=!1}r=S.prototype;r.getDuration=function(){return this.i};r.lf=function(){return this.g};r.Ja=function(a){this.i=a};r.rf=function(){return this.l};r.Ee=function(a){this.o=a};r.pc=function(a){this.s=a};r.Yd=function(a){this.m=a};r.$f=function(a){this.Sc=a};r.df=function(){return this.Sc};
277
- r.Hb=function(a){if(0!=a.length){var b=a[a.length-1].endTime;this.Id(a[0].startTime);this.g=a.reduce(function(c,d){return Math.max(c,d.endTime-d.startTime)},this.g);this.h=Math.max(this.h,b);null!=this.l&&this.C&&!this.F&&(this.l=(Date.now()+this.o)/1E3-this.h-this.g)}};r.Bd=function(){this.F=!0};r.Id=function(a){this.j=null==this.j?a:Math.min(this.j,a)};r.Hd=function(a){this.g=Math.max(this.g,a)};r.offset=function(a){null!=this.j&&(this.j+=a);null!=this.h&&(this.h+=a)};
278
- r.T=function(){return Infinity==this.i&&!this.s};r.mb=function(){return Infinity!=this.i&&!this.s};r.Qa=function(){return Math.max(this.u,this.hb()-this.m)};r.Fe=function(a){this.u=a};r.hb=function(){return this.T()||this.mb()?Math.min(Math.max(0,(Date.now()+this.o)/1E3-this.g-this.l)+this.D,this.i):this.h?Math.min(this.h,this.i):this.i};r.ec=function(a){var b=Math.max(this.j,this.u);return Infinity==this.m?Math.ceil(1E3*b)/1E3:Math.max(b,Math.min(this.hb()-this.m+a,this.Pa()))};r.Db=function(){return this.ec(0)};
279
- r.Pa=function(){return Math.max(0,this.hb()-(this.T()||this.mb()?this.Sc:0))};r.Ie=function(){return null==this.l||null!=this.h&&this.C?!1:!0};r.De=function(a){this.D=a};M("shaka.media.PresentationTimeline",S);S.prototype.setAvailabilityTimeOffset=S.prototype.De;S.prototype.usingPresentationStartTime=S.prototype.Ie;S.prototype.getSeekRangeEnd=S.prototype.Pa;S.prototype.getSeekRangeStart=S.prototype.Db;S.prototype.getSafeSeekRangeStart=S.prototype.ec;S.prototype.getSegmentAvailabilityEnd=S.prototype.hb;
280
- S.prototype.setUserSeekStart=S.prototype.Fe;S.prototype.getSegmentAvailabilityStart=S.prototype.Qa;S.prototype.isInProgress=S.prototype.mb;S.prototype.isLive=S.prototype.T;S.prototype.offset=S.prototype.offset;S.prototype.notifyMaxSegmentDuration=S.prototype.Hd;S.prototype.notifyMinSegmentStartTime=S.prototype.Id;S.prototype.lockStartTime=S.prototype.Bd;S.prototype.notifySegments=S.prototype.Hb;S.prototype.getDelay=S.prototype.df;S.prototype.setDelay=S.prototype.$f;
281
- S.prototype.setSegmentAvailabilityDuration=S.prototype.Yd;S.prototype.setStatic=S.prototype.pc;S.prototype.setClockOffset=S.prototype.Ee;S.prototype.getPresentationStartTime=S.prototype.rf;S.prototype.setDuration=S.prototype.Ja;S.prototype.getMaxSegmentDuration=S.prototype.lf;S.prototype.getDuration=S.prototype.getDuration;function Ji(a,b){this.j=a;this.m=Ki(a);this.g=a.g.currentTime;this.l=Date.now()/1E3;this.h=!1;this.o=b;this.i=function(){}}Ji.prototype.release=function(){this.j=null;this.i=function(){}};function Li(a,b){a.i=b}function Mi(a){this.g=a}function Ki(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(gi(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 Ni(a,b,c,d,e){var f=this;this.g=a;this.C=b;this.l=c;this.u=e;this.i=new ef;this.s=!1;this.D=a.readyState;this.j=!1;this.h=d;this.o=!1;this.i.A(a,"waiting",function(){return Oi(f)});this.m=(new O(function(){Oi(f)})).Da(.25)}Ni.prototype.release=function(){this.i&&(this.i.release(),this.i=null);null!=this.m&&(this.m.stop(),this.m=null);this.h&&(this.h.release(),this.h=null);this.g=this.C=this.u=null};Ni.prototype.Ld=function(){this.o=!0;Oi(this)};
276
+ r.xf=function(){return this.i};M("shaka.media.SegmentReference",Ii);Ii.prototype.getTileDuration=Ii.prototype.xf;Ii.prototype.getTilesLayout=Ii.prototype.yf;Ii.prototype.getEndByte=Ii.prototype.bc;Ii.prototype.getStartByte=Ii.prototype.fc;Ii.prototype.getEndTime=Ii.prototype.ef;Ii.prototype.getStartTime=Ii.prototype.getStartTime;Ii.prototype.getUris=Ii.prototype.sa;function S(a,b,c){this.l=a;this.Sc=b;this.m=this.i=Infinity;this.g=1;this.h=this.j=null;this.o=0;this.s=!0;this.u=0;this.C=void 0===c?!0:c;this.D=0;this.F=!1}r=S.prototype;r.getDuration=function(){return this.i};r.lf=function(){return this.g};r.Ja=function(a){this.i=a};r.rf=function(){return this.l};r.Ee=function(a){this.o=a};r.pc=function(a){this.s=a};r.Zd=function(a){this.m=a};r.$f=function(a){this.Sc=a};r.df=function(){return this.Sc};
277
+ r.Hb=function(a){if(0!=a.length){var b=a[a.length-1].endTime;this.Jd(a[0].startTime);this.g=a.reduce(function(c,d){return Math.max(c,d.endTime-d.startTime)},this.g);this.h=Math.max(this.h,b);null!=this.l&&this.C&&!this.F&&(this.l=(Date.now()+this.o)/1E3-this.h-this.g)}};r.Cd=function(){this.F=!0};r.Jd=function(a){this.j=null==this.j?a:Math.min(this.j,a)};r.Id=function(a){this.g=Math.max(this.g,a)};r.offset=function(a){null!=this.j&&(this.j+=a);null!=this.h&&(this.h+=a)};
278
+ r.U=function(){return Infinity==this.i&&!this.s};r.mb=function(){return Infinity!=this.i&&!this.s};r.Ra=function(){return Math.max(this.u,this.hb()-this.m)};r.Fe=function(a){this.u=a};r.hb=function(){return this.U()||this.mb()?Math.min(Math.max(0,(Date.now()+this.o)/1E3-this.g-this.l)+this.D,this.i):this.h?Math.min(this.h,this.i):this.i};r.ec=function(a){var b=Math.max(this.j,this.u);return Infinity==this.m?Math.ceil(1E3*b)/1E3:Math.max(b,Math.min(this.hb()-this.m+a,this.Qa()))};r.Db=function(){return this.ec(0)};
279
+ r.Qa=function(){return Math.max(0,this.hb()-(this.U()||this.mb()?this.Sc:0))};r.Ie=function(){return null==this.l||null!=this.h&&this.C?!1:!0};r.De=function(a){this.D=a};M("shaka.media.PresentationTimeline",S);S.prototype.setAvailabilityTimeOffset=S.prototype.De;S.prototype.usingPresentationStartTime=S.prototype.Ie;S.prototype.getSeekRangeEnd=S.prototype.Qa;S.prototype.getSeekRangeStart=S.prototype.Db;S.prototype.getSafeSeekRangeStart=S.prototype.ec;S.prototype.getSegmentAvailabilityEnd=S.prototype.hb;
280
+ S.prototype.setUserSeekStart=S.prototype.Fe;S.prototype.getSegmentAvailabilityStart=S.prototype.Ra;S.prototype.isInProgress=S.prototype.mb;S.prototype.isLive=S.prototype.U;S.prototype.offset=S.prototype.offset;S.prototype.notifyMaxSegmentDuration=S.prototype.Id;S.prototype.notifyMinSegmentStartTime=S.prototype.Jd;S.prototype.lockStartTime=S.prototype.Cd;S.prototype.notifySegments=S.prototype.Hb;S.prototype.getDelay=S.prototype.df;S.prototype.setDelay=S.prototype.$f;
281
+ S.prototype.setSegmentAvailabilityDuration=S.prototype.Zd;S.prototype.setStatic=S.prototype.pc;S.prototype.setClockOffset=S.prototype.Ee;S.prototype.getPresentationStartTime=S.prototype.rf;S.prototype.setDuration=S.prototype.Ja;S.prototype.getMaxSegmentDuration=S.prototype.lf;S.prototype.getDuration=S.prototype.getDuration;function Ji(a,b){this.j=a;this.m=Ki(a);this.g=a.g.currentTime;this.l=Date.now()/1E3;this.h=!1;this.o=b;this.i=function(){}}Ji.prototype.release=function(){this.j=null;this.i=function(){}};function Li(a,b){a.i=b}function Mi(a){this.g=a}function Ki(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(gi(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 Ni(a,b,c,d,e){var f=this;this.g=a;this.C=b;this.l=c;this.u=e;this.i=new ef;this.s=!1;this.D=a.readyState;this.j=!1;this.h=d;this.o=!1;this.i.A(a,"waiting",function(){return Oi(f)});this.m=(new O(function(){Oi(f)})).Da(.25)}Ni.prototype.release=function(){this.i&&(this.i.release(),this.i=null);null!=this.m&&(this.m.stop(),this.m=null);this.h&&(this.h.release(),this.h=null);this.g=this.C=this.u=null};Ni.prototype.Md=function(){this.o=!0;Oi(this)};
282
282
  function Oi(a){if(0!=a.g.readyState){if(a.g.seeking){if(!a.s)return}else a.s=!1;if(!a.g.paused||0==a.g.currentTime&&(a.g.autoplay||0!=a.g.currentTime)){a.g.readyState!=a.D&&(a.j=!1,a.D=a.g.readyState);var b;if(!(b=!a.h)){b=a.h;var c=b.j,d=Ki(c),e=c.g.currentTime,f=Date.now()/1E3;if(b.g!=e||b.m!=d)b.l=f,b.g=e,b.m=d,b.h=!1;e=f-b.l;if(d=e>=b.o&&d&&!b.h)b.i(b.g,e),b.h=!0,b.g=c.g.currentTime;b=!d}if(b){e=a.l.smallGapLimit;var g=a.g.currentTime;b=a.g.buffered;c=hi(b,g,a.l.gapDetectionThreshold);if(!(null==
283
- c||0==c&&!a.o||(d=b.start(c),d>=a.C.Pa()))){var h=d-g;e=h<=e;f=!1;.001>h||(e||a.j||(a.j=!0,g=(new Map).set("currentTime",g).set("gapSize",h),g=new Q("largegap",g),g.cancelable=!0,a.u(g),a.l.jumpLargeGaps&&!g.defaultPrevented&&(f=!0)),!e&&!f)||(0!=c&&b.end(c-1),a.g.currentTime=d)}}}}};function Pi(a,b,c,d){b==HTMLMediaElement.HAVE_NOTHING||a.readyState>=b?d():(b=Qi.value().get(b),c.oa(a,b,d))}var Qi=new sc(function(){return new Map([[HTMLMediaElement.HAVE_METADATA,"loadedmetadata"],[HTMLMediaElement.HAVE_CURRENT_DATA,"loadeddata"],[HTMLMediaElement.HAVE_FUTURE_DATA,"canplay"],[HTMLMediaElement.HAVE_ENOUGH_DATA,"canplaythrough"]])});function Ri(a,b,c){var d=this;this.g=a;this.l=b;this.j=c;this.m=!1;this.h=new ef;this.i=new Si(a);Pi(this.g,HTMLMediaElement.HAVE_METADATA,this.h,function(){Ti(d,d.j)})}Ri.prototype.release=function(){this.h&&(this.h.release(),this.h=null);null!=this.i&&(this.i.release(),this.i=null);this.l=function(){};this.g=null};function Ui(a){return a.m?a.g.currentTime:a.j}function Vi(a,b){0<a.g.readyState?Wi(a.i,b):Pi(a.g,HTMLMediaElement.HAVE_METADATA,a.h,function(){Ti(a,a.j)})}
283
+ c||0==c&&!a.o||(d=b.start(c),d>=a.C.Qa()))){var h=d-g;e=h<=e;f=!1;.001>h||(e||a.j||(a.j=!0,g=(new Map).set("currentTime",g).set("gapSize",h),g=new Q("largegap",g),g.cancelable=!0,a.u(g),a.l.jumpLargeGaps&&!g.defaultPrevented&&(f=!0)),!e&&!f)||(0!=c&&b.end(c-1),a.g.currentTime=d)}}}}};function Pi(a,b,c,d){b==HTMLMediaElement.HAVE_NOTHING||a.readyState>=b?d():(b=Qi.value().get(b),c.oa(a,b,d))}var Qi=new sc(function(){return new Map([[HTMLMediaElement.HAVE_METADATA,"loadedmetadata"],[HTMLMediaElement.HAVE_CURRENT_DATA,"loadeddata"],[HTMLMediaElement.HAVE_FUTURE_DATA,"canplay"],[HTMLMediaElement.HAVE_ENOUGH_DATA,"canplaythrough"]])});function Ri(a,b,c){var d=this;this.g=a;this.l=b;this.j=c;this.m=!1;this.h=new ef;this.i=new Si(a);Pi(this.g,HTMLMediaElement.HAVE_METADATA,this.h,function(){Ti(d,d.j)})}Ri.prototype.release=function(){this.h&&(this.h.release(),this.h=null);null!=this.i&&(this.i.release(),this.i=null);this.l=function(){};this.g=null};function Ui(a){return a.m?a.g.currentTime:a.j}function Vi(a,b){0<a.g.readyState?Wi(a.i,b):Pi(a.g,HTMLMediaElement.HAVE_METADATA,a.h,function(){Ti(a,a.j)})}
284
284
  function Ti(a,b){.001>Math.abs(a.g.currentTime-b)?Xi(a):(a.h.oa(a.g,"seeking",function(){Xi(a)}),Wi(a.i,0==a.g.currentTime?b:a.g.currentTime))}function Xi(a){a.m=!0;a.h.A(a.g,"seeking",function(){return a.l()})}function Si(a){var b=this;this.h=a;this.m=10;this.l=this.j=this.i=0;this.g=new O(function(){0>=b.i?b.g.stop():b.h.currentTime!=b.j?b.g.stop():(b.h.currentTime=b.l,b.i--)})}Si.prototype.release=function(){this.g&&(this.g.stop(),this.g=null);this.h=null};
285
285
  function Wi(a,b){a.j=a.h.currentTime;a.l=b;a.i=a.m;a.h.currentTime=b;a.g.Da(.1)};function Yi(a){this.g=a;this.j=!1;this.h=null;this.i=new ef}r=Yi.prototype;r.nd=function(){function a(){null==b.h||0==b.h?b.j=!0:(b.i.oa(b.g,"seeking",function(){b.j=!0}),b.g.currentTime=Math.max(0,b.g.currentTime+b.h))}var b=this;Pi(this.g,HTMLMediaElement.HAVE_CURRENT_DATA,this.i,function(){a()})};r.release=function(){this.i&&(this.i.release(),this.i=null);this.g=null};r.od=function(a){this.h=this.j?this.h:a};r.xc=function(){return(this.j?this.g.currentTime:this.h)||0};r.ue=function(){};
286
- function Zi(a,b,c,d,e,f){var g=this;this.i=a;this.g=b.presentationTimeline;this.u=b.minBufferTime||0;this.l=c;this.s=e;this.o=null;this.j=new Ni(a,b.presentationTimeline,c,$i(a,c),f);this.h=new Ri(a,function(){a:{var h=g.j;h.s=!0;h.o=!1;h.j=!1;var k=Ui(g.h);h=aj(g,k);if(.001<Math.abs(h-k)&&(k=Date.now()/1E3,!g.o||g.o<k-1)){g.o=k;Vi(g.h,h);h=void 0;break a}g.s();h=void 0}return h},bj(this,d));this.m=new O(function(){if(0!=g.i.readyState&&!g.i.paused){var h=Ui(g.h),k=g.g.Db(),l=g.g.Pa();3>l-k&&(k=l-
286
+ function Zi(a,b,c,d,e,f){var g=this;this.i=a;this.g=b.presentationTimeline;this.u=b.minBufferTime||0;this.l=c;this.s=e;this.o=null;this.j=new Ni(a,b.presentationTimeline,c,$i(a,c),f);this.h=new Ri(a,function(){a:{var h=g.j;h.s=!0;h.o=!1;h.j=!1;var k=Ui(g.h);h=aj(g,k);if(.001<Math.abs(h-k)&&(k=Date.now()/1E3,!g.o||g.o<k-1)){g.o=k;Vi(g.h,h);h=void 0;break a}g.s();h=void 0}return h},bj(this,d));this.m=new O(function(){if(0!=g.i.readyState&&!g.i.paused){var h=Ui(g.h),k=g.g.Db(),l=g.g.Qa();3>l-k&&(k=l-
287
287
  3);h<k&&(h=aj(g,h),g.i.currentTime=h)}})}r=Zi.prototype;r.nd=function(){this.m.Da(.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.s=function(){}};r.od=function(a){Vi(this.h,a)};r.xc=function(){var a=Ui(this.h);return 0<this.i.readyState&&!this.i.paused?cj(this,a):a};
288
- function bj(a,b){null==b?b=Infinity>a.g.getDuration()?a.g.Db():a.g.Pa():0>b&&(b=a.g.Pa()+b);return dj(a,cj(a,b))}r.ue=function(){this.j.Ld()};function dj(a,b){var c=a.g.getDuration();return b>=c?c-a.l.durationBackoff:b}function aj(a,b){var c=Math.max(a.u,a.l.rebufferingGoal),d=a.l.safeSeekOffset,e=a.g.Db(),f=a.g.Pa(),g=a.g.getDuration();3>f-e&&(e=f-3);var h=a.g.ec(c),k=a.g.ec(d);c=a.g.ec(c+d);return b>=g?dj(a,b):b>f?f:b<e?ei(a.i.buffered,k)?k:c:b>=h||ei(a.i.buffered,b)?b:c}
289
- function cj(a,b){var c=a.g.Db();if(b<c)return c;c=a.g.Pa();return b>c?c:b}function $i(a,b){if(!b.stallEnabled)return null;var c=b.stallSkip,d=new Ji(new Mi(a),b.stallThreshold);Li(d,function(){c?a.currentTime+=c:(a.pause(),a.play())});return d};function T(a){this.K=a;this.g=null;this.h=0;this.i=!1}r=T.prototype;r.destroy=function(){Kb("shaka.media.SegmentIndex","Please use release() instead of destroy().");this.release();return Promise.resolve()};r.release=function(){this.i||(this.K=[],this.g&&this.g.stop(),this.g=null)};r.Ff=function(){this.i=!0};
288
+ function bj(a,b){null==b?b=Infinity>a.g.getDuration()?a.g.Db():a.g.Qa():0>b&&(b=a.g.Qa()+b);return dj(a,cj(a,b))}r.ue=function(){this.j.Md()};function dj(a,b){var c=a.g.getDuration();return b>=c?c-a.l.durationBackoff:b}function aj(a,b){var c=Math.max(a.u,a.l.rebufferingGoal),d=a.l.safeSeekOffset,e=a.g.Db(),f=a.g.Qa(),g=a.g.getDuration();3>f-e&&(e=f-3);var h=a.g.ec(c),k=a.g.ec(d);c=a.g.ec(c+d);return b>=g?dj(a,b):b>f?f:b<e?ei(a.i.buffered,k)?k:c:b>=h||ei(a.i.buffered,b)?b:c}
289
+ function cj(a,b){var c=a.g.Db();if(b<c)return c;c=a.g.Qa();return b>c?c:b}function $i(a,b){if(!b.stallEnabled)return null;var c=b.stallSkip,d=new Ji(new Mi(a),b.stallThreshold);Li(d,function(){c?a.currentTime+=c:(a.pause(),a.play())});return d};function T(a){this.K=a;this.g=null;this.h=0;this.i=!1}r=T.prototype;r.destroy=function(){Kb("shaka.media.SegmentIndex","Please use release() instead of destroy().");this.release();return Promise.resolve()};r.release=function(){this.i||(this.K=[],this.g&&this.g.stop(),this.g=null)};r.Ff=function(){this.i=!0};
290
290
  r.find=function(a){for(var b=this.K.length-1,c=b;0<=c;--c){var d=this.K[c],e=c<b?this.K[c+1].startTime:d.endTime;if(a>=d.startTime&&a<e)return c+this.h}return this.K.length&&a<this.K[0].startTime?this.h:null};r.get=function(a){if(0==this.K.length)return null;a-=this.h;return 0>a||a>=this.K.length?null:this.K[a]};r.offset=function(a){if(!this.i)for(var b=t(this.K),c=b.next();!c.done;c=b.next())c=c.value,c.startTime+=a,c.endTime+=a,c.timestampOffset+=a};
291
291
  r.Fb=function(a){!this.i&&a.length&&(this.K=this.K.filter(function(b){return b.startTime<a[0].startTime}),this.K.push.apply(this.K,ja(a)))};r.Gb=function(a,b){var c=this;a=a.filter(function(d){return d.endTime>b&&(0==c.K.length||d.endTime>c.K[0].startTime)});this.Fb(a);this.eb(b)};r.eb=function(a){if(!this.i){var b=this.K.length;this.K=this.K.filter(function(c){return c.endTime>a});this.h+=b-this.K.length}};
292
292
  r.Xa=function(a,b,c){c=void 0===c?!1:c;if(!this.i){for(;this.K.length;)if(this.K[this.K.length-1].startTime>=b)this.K.pop();else break;for(;this.K.length;)if(this.K[0].endTime<=a)this.K.shift(),c||this.h++;else break;0!=this.K.length&&(a=this.K[this.K.length-1],this.K[this.K.length-1]=new Ii(a.startTime,b,a.j,a.pa,a.ha,a.g,a.timestampOffset,a.appendWindowStart,a.appendWindowEnd,a.h,a.tilesLayout,a.i))}};
@@ -296,9 +296,9 @@ T.prototype.release=T.prototype.release;T.prototype.destroy=T.prototype.destroy;
296
296
  ej.prototype.current=function(){var a=this.i.get(this.h);a&&0<a.h.length&&a.sa().length&&this.g>=a.h.length&&(this.h++,this.g=0,a=this.i.get(this.h));return a&&0<a.h.length?a.h[this.g]:a};ej.prototype.next=function(){var a=this.i.get(this.h);a&&0<a.h.length?(this.g++,a.sa().length&&this.g==a.h.length&&(this.h++,this.g=0)):(this.h++,this.g=0);a=this.current();return{value:a,done:!a}};M("shaka.media.SegmentIterator",ej);ej.prototype.next=ej.prototype.next;ej.prototype.current=ej.prototype.current;
297
297
  ej.prototype.seek=ej.prototype.seek;function gj(){T.call(this,[]);this.j=[]}qa(gj,T);r=gj.prototype;r.clone=function(){var a=new gj;a.j=this.j.slice();return a};r.release=function(){for(var a=t(this.j),b=a.next();!b.done;b=a.next())b.value.release();this.j=[]};r.find=function(a){for(var b=0,c=t(this.j),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.find(a);if(null!=e)return e+b;b+=d.h+d.K.length}return null};
298
298
  r.get=function(a){for(var b=0,c=t(this.j),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.get(a-b);if(e)return e;b+=d.h+d.K.length}return null};r.offset=function(){};r.Fb=function(){};r.eb=function(){};r.Gb=function(){};r.Xa=function(){};r.Uc=function(){};M("shaka.media.MetaSegmentIndex",gj);gj.prototype.updateEvery=gj.prototype.Uc;gj.prototype.fit=gj.prototype.Xa;gj.prototype.mergeAndEvict=gj.prototype.Gb;gj.prototype.evict=gj.prototype.eb;gj.prototype.merge=gj.prototype.Fb;
299
- gj.prototype.offset=gj.prototype.offset;gj.prototype.get=gj.prototype.get;gj.prototype.find=gj.prototype.find;gj.prototype.release=gj.prototype.release;function hj(a){var b=this;this.g=a;this.j=!1;this.i=this.g.Jc();this.h=new O(function(){b.g.te(.25*b.i)})}hj.prototype.release=function(){this.h&&(this.h.stop(),this.h=null);this.g=null};hj.prototype.set=function(a){this.i=a;ij(this)};hj.prototype.Fc=function(){return this.g.Fc()};function ij(a){a.h.stop();var b=a.j?0:a.i;if(0<=b)try{a.g.Jc()!=b&&a.g.Xd(b);return}catch(c){}a.h.Da(.25);0!=a.g.Jc()&&a.g.Xd(0)};function jj(a){var b=this;this.h=a;this.g=new Set;this.i=(new O(function(){kj(b,!1)})).Da(.25)}jj.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 kj(a,b){for(var c=t(a.g),d=c.next();!d.done;d=c.next())d.value.j(a.h.currentTime,b)};function lj(a){Ne.call(this);this.g=new Map;this.h=a}qa(lj,Ne);lj.prototype.release=function(){this.g.clear();Ne.prototype.release.call(this)};function mj(a,b){var c=a.g.get(b);c||(c={jc:[],fe:null,contentType:b},a.g.set(b,c));return c}function nj(a,b,c){var d=mj(a,b.contentType);oj(a,d);a={Dd:b,position:c};d=d.jc;b=d.findIndex(function(e){return e.position>=c});0<=b?d.splice(b,d[b].position==c?1:0,a):d.push(a)}
300
- lj.prototype.j=function(a){for(var b=t(this.g.values()),c=b.next();!c.done;c=b.next()){c=c.value;a:{var d=c.jc;for(var e=d.length-1;0<=e;e--){var f=d[e];if(f.position<=a){d=f.Dd;break a}}d=null}if(e=d)e=c.fe,e=!(e===d||e&&d&&e.bandwidth==d.bandwidth&&e.audioSamplingRate==d.audioSamplingRate&&e.codecs==d.codecs&&e.contentType==d.contentType&&e.frameRate==d.frameRate&&e.height==d.height&&e.mimeType==d.mimeType&&e.channelsCount==d.channelsCount&&e.pixelAspectRatio==d.pixelAspectRatio&&e.width==d.width);
301
- if(e)a:{e=a;f=d.contentType;if((f=this.h()[f])&&0<f.length){var g=f[f.length-1].end;if(e>=f[0].start&&e<g){e=!0;break a}}e=!1}e&&(c.fe=d,JSON.stringify(d),c=new Q("qualitychange",new Map([["quality",d],["position",a]])),this.dispatchEvent(c))}};function oj(a,b){var c=a.h()[b.contentType];if(c&&0<c.length){var d=c[0].start,e=c[c.length-1].end,f=b.jc;b.jc=f.filter(function(g,h){return g.position<=d&&h+1<f.length&&f[h+1].position<=d||g.position>=e?!1:!0})}else b.jc=[]};function pj(a){Ne.call(this);var b=this;this.g=new Set;this.i=a;this.h=(new O(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 Q("regionremove",new Map([["region",e]])),b.dispatchEvent(e))})).Da(2)}qa(pj,Ne);pj.prototype.release=function(){this.g.clear();this.h.stop();Ne.prototype.release.call(this)};function qj(a){Ne.call(this);var b=this;this.i=a;this.g=new Map;this.l=[{ub:null,sb:rj,lb:function(c,d){return sj(b,"enter",c,d)}},{ub:tj,sb:rj,lb:function(c,d){return sj(b,"enter",c,d)}},{ub:uj,sb:rj,lb:function(c,d){return sj(b,"enter",c,d)}},{ub:rj,sb:tj,lb:function(c,d){return sj(b,"exit",c,d)}},{ub:rj,sb:uj,lb:function(c,d){return sj(b,"exit",c,d)}},{ub:tj,sb:uj,lb:function(c,d){return sj(b,"skip",c,d)}},{ub:uj,sb:tj,lb:function(c,d){return sj(b,"skip",c,d)}}];this.h=new ef;this.h.A(this.i,"regionremove",
299
+ gj.prototype.offset=gj.prototype.offset;gj.prototype.get=gj.prototype.get;gj.prototype.find=gj.prototype.find;gj.prototype.release=gj.prototype.release;function hj(a){var b=this;this.g=a;this.j=!1;this.i=this.g.Jc();this.h=new O(function(){b.g.te(.25*b.i)})}hj.prototype.release=function(){this.h&&(this.h.stop(),this.h=null);this.g=null};hj.prototype.set=function(a){this.i=a;ij(this)};hj.prototype.Fc=function(){return this.g.Fc()};function ij(a){a.h.stop();var b=a.j?0:a.i;if(0<=b)try{a.g.Jc()!=b&&a.g.Yd(b);return}catch(c){}a.h.Da(.25);0!=a.g.Jc()&&a.g.Yd(0)};function jj(a){var b=this;this.h=a;this.g=new Set;this.i=(new O(function(){kj(b,!1)})).Da(.25)}jj.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 kj(a,b){for(var c=t(a.g),d=c.next();!d.done;d=c.next())d.value.j(a.h.currentTime,b)};function lj(a){Ne.call(this);this.g=new Map;this.h=a}qa(lj,Ne);lj.prototype.release=function(){this.g.clear();Ne.prototype.release.call(this)};function mj(a,b){var c=a.g.get(b);c||(c={jc:[],ge:null,contentType:b},a.g.set(b,c));return c}function nj(a,b,c){var d=mj(a,b.contentType);oj(a,d);a={Ed:b,position:c};d=d.jc;b=d.findIndex(function(e){return e.position>=c});0<=b?d.splice(b,d[b].position==c?1:0,a):d.push(a)}
300
+ lj.prototype.j=function(a){for(var b=t(this.g.values()),c=b.next();!c.done;c=b.next()){c=c.value;a:{var d=c.jc;for(var e=d.length-1;0<=e;e--){var f=d[e];if(f.position<=a){d=f.Ed;break a}}d=null}if(e=d)e=c.ge,e=!(e===d||e&&d&&e.bandwidth==d.bandwidth&&e.audioSamplingRate==d.audioSamplingRate&&e.codecs==d.codecs&&e.contentType==d.contentType&&e.frameRate==d.frameRate&&e.height==d.height&&e.mimeType==d.mimeType&&e.channelsCount==d.channelsCount&&e.pixelAspectRatio==d.pixelAspectRatio&&e.width==d.width);
301
+ if(e)a:{e=a;f=d.contentType;if((f=this.h()[f])&&0<f.length){var g=f[f.length-1].end;if(e>=f[0].start&&e<g){e=!0;break a}}e=!1}e&&(c.ge=d,JSON.stringify(d),c=new Q("qualitychange",new Map([["quality",d],["position",a]])),this.dispatchEvent(c))}};function oj(a,b){var c=a.h()[b.contentType];if(c&&0<c.length){var d=c[0].start,e=c[c.length-1].end,f=b.jc;b.jc=f.filter(function(g,h){return g.position<=d&&h+1<f.length&&f[h+1].position<=d||g.position>=e?!1:!0})}else b.jc=[]};function pj(a){Ne.call(this);var b=this;this.g=new Set;this.i=a;this.h=(new O(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 Q("regionremove",new Map([["region",e]])),b.dispatchEvent(e))})).Da(2)}qa(pj,Ne);pj.prototype.release=function(){this.g.clear();this.h.stop();Ne.prototype.release.call(this)};function qj(a){Ne.call(this);var b=this;this.i=a;this.g=new Map;this.l=[{ub:null,sb:rj,lb:function(c,d){return sj(b,"enter",c,d)}},{ub:tj,sb:rj,lb:function(c,d){return sj(b,"enter",c,d)}},{ub:uj,sb:rj,lb:function(c,d){return sj(b,"enter",c,d)}},{ub:rj,sb:tj,lb:function(c,d){return sj(b,"exit",c,d)}},{ub:rj,sb:uj,lb:function(c,d){return sj(b,"exit",c,d)}},{ub:tj,sb:uj,lb:function(c,d){return sj(b,"skip",c,d)}},{ub:uj,sb:tj,lb:function(c,d){return sj(b,"skip",c,d)}}];this.h=new ef;this.h.A(this.i,"regionremove",
302
302
  function(c){b.g["delete"](c.region)})}qa(qj,Ne);qj.prototype.release=function(){this.i=null;this.g.clear();this.h.release();this.h=null;Ne.prototype.release.call(this)};qj.prototype.j=function(a,b){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?tj:a>d.endTime?uj:rj;this.g.set(d,f);for(var g=t(this.l),h=g.next();!h.done;h=g.next())h=h.value,h.ub==e&&h.sb==f&&h.lb(d,b)}};
303
303
  function sj(a,b,c,d){b=new Q(b,new Map([["region",c],["seeking",d]]));a.dispatchEvent(b)}var tj=1,rj=2,uj=3;function vj(a,b,c,d,e){a=We(a,d,e);if(0!=b||null!=c)a.headers.Range=c?"bytes="+b+"-"+c:"bytes="+b+"-";return a};function wj(a,b){var c=this;this.g=b;this.m=a;this.h=null;this.u=1;this.o=this.l=null;this.j=new Map;this.C=!1;this.D=null;this.s=!1;this.i=new cf(function(){return xj(c)})}wj.prototype.destroy=function(){return this.i.destroy()};function xj(a){var b,c,d,e;return L(function(f){if(1==f.g){b=[];c=t(a.j.values());for(d=c.next();!d.done;d=c.next())e=d.value,yj(e),b.push(zj(e));return u(f,Promise.all(b),2)}a.j.clear();a.g=null;a.m=null;a.h=null;A(f)})}
304
304
  wj.prototype.configure=function(a){this.h=a;this.D=new Ce({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)};wj.prototype.start=function(){var a=this;return L(function(b){if(1==b.g)return u(b,Aj(a),2);df(a.i);a.C=!0;A(b)})};
@@ -308,20 +308,20 @@ function Gj(a,b,c,d,e){var f=a.j.get(b.type);f||b.type!=pc?f&&(f.qb&&(b.trickMod
308
308
  function Kj(a,b){var c,d;return L(function(e){if(1==e.g){if(!b.va)return e["return"]();c=b.stream;d=b.va;return c.segmentIndex?e.B(2):u(e,c.createSegmentIndex(),2)}if(b.va!=d||b.stream!=c)return e["return"]();var f=a.g.Ic();var g=ui(a.g.R,b.type),h=b.stream.segmentIndex.find(b.Ba?b.Ba.endTime:f),k=null==h?null:b.stream.segmentIndex.get(h);h=k?k.ha?k.ha-k.pa:null:null;k&&!h&&(h=(k.endTime-k.getStartTime())*(b.stream.bandwidth||0)/8);h?((k=k.g)&&(h+=(k.ha?k.ha-k.pa:null)||0),k=a.g.getBandwidthEstimate(),
309
309
  f=8*h/k<(g||0)-f-Math.max(a.m.minBufferTime||0,a.h.rebufferingGoal)||b.va.h.g>h?!0:!1):f=!1;f&&b.va.abort();A(e)})}function Lj(a,b){b.Zb||b.ab||(b.ta?(b.ab=!0,b.Ac=0):null==si(a.g.R,b.type)?null==b.La&&Dj(a,b,0):(yj(b),Jj(a,b,!1,0)["catch"](function(c){if(a.g)a.g.onError(c)})))}
310
310
  function Aj(a){var b,c,d,e,f,g,h,k,l,m;return L(function(n){if(1==n.g){b=qc;if(!a.l)throw new N(2,5,5006);c=new Map;d=new Set;a.l.audio&&(c.set(b.cb,a.l.audio),d.add(a.l.audio));a.l.video&&(c.set(b.Na,a.l.video),d.add(a.l.video));a.o&&(c.set(b.Z,a.o),d.add(a.o));e=a.g.R;f=a.h.forceTransmuxTS;return u(n,e.init(c,f),2)}df(a.i);var p=a.m.presentationTimeline.getDuration();Infinity>p?a.g.R.Ja(p):a.g.R.Ja(Math.pow(2,32));g=t(c.keys());for(h=g.next();!h.done;h=g.next())k=h.value,l=c.get(k),a.j.has(k)||
311
- (m=Cj(l),a.j.set(k,m),Dj(a,m,0));A(n)})}function Cj(a){return{stream:a,type:a.type,ba:null,Ba:null,Mc:null,zd:null,yd:null,xd:null,qb:null,endOfStream:!1,ta:!1,La:null,ab:!1,Ac:0,Xc:!1,Zb:!1,Pd:!1,hc:!1,va:null}}
311
+ (m=Cj(l),a.j.set(k,m),Dj(a,m,0));A(n)})}function Cj(a){return{stream:a,type:a.type,ba:null,Ba:null,Mc:null,Bd:null,zd:null,yd:null,qb:null,endOfStream:!1,ta:!1,La:null,ab:!1,Ac:0,Xc:!1,Zb:!1,Qd:!1,hc:!1,va:null}}
312
312
  function Mj(a,b){var c,d,e,f,g;return L(function(h){switch(h.g){case 1:df(a.i);if(b.ta||null==b.La||b.Zb)return h["return"]();b.La=null;if(!b.ab){h.B(2);break}return u(h,Jj(a,b,b.Xc,b.Ac),3);case 3:return h["return"]();case 2:if(b.stream.segmentIndex){h.B(4);break}c=b.stream;return u(h,b.stream.createSegmentIndex(),5);case 5:if(c!=b.stream)return c.closeSegmentIndex&&c.closeSegmentIndex(),b.ta||b.La||Dj(a,b,0),h["return"]();case 4:C(h,6);d=Nj(a,b);null!=d&&(Dj(a,b,d),b.hc=!1);va(h,7);break;case 6:return e=
313
313
  E(h),u(h,Oj(a,e),8);case 8:return h["return"]();case 7:f=Array.from(a.j.values());if(!a.C||!f.every(function(k){return k.endOfStream})){h.B(0);break}return u(h,a.g.R.endOfStream(),10);case 10:df(a.i),g=a.g.R.getDuration(),0!=g&&g<a.m.presentationTimeline.getDuration()&&a.m.presentationTimeline.Ja(g),A(h)}})}
314
314
  function Nj(a,b){if(Pj(b))return zi(a.g.R,b.stream.originalId||""),null;b.type==pc&&Ai(a.g.R);var c=a.g.Ic(),d=b.Ba?b.Ba.endTime:c,e=vi(a.g.R,b.type,c),f=Math.max(a.m.minBufferTime||0,a.h.rebufferingGoal,a.h.bufferingGoal)*a.u,g=a.m.presentationTimeline.getDuration()-d,h=ui(a.g.R,b.type);if(1E-6>g&&h)return b.endOfStream=!0,"video"==b.type&&(c=a.j.get(pc))&&Pj(c)&&(c.endOfStream=!0),null;b.endOfStream=!1;if(e>=f)return a.h.updateIntervalSeconds/2;e=Qj(a,b,c,h);if(!e)return a.h.updateIntervalSeconds;
315
315
  f=Infinity;g=Array.from(a.j.values());g=t(g);for(h=g.next();!h.done;h=g.next())h=h.value,Pj(h)||h.ba&&!h.ba.current()||(f=Math.min(f,h.Ba?h.Ba.endTime:c));if(d>=f+a.m.presentationTimeline.g)return a.h.updateIntervalSeconds;Rj(a,b,c,e)["catch"](function(){});return null}
316
316
  function Qj(a,b,c,d){if(b.ba)return b.ba.current();if(b.Ba||d)return b.ba=b.stream.segmentIndex.gb(b.Ba?b.Ba.endTime:d),b.ba&&b.ba.next().value;a=a.h.inaccurateManifestTolerance;d=Math.max(c-a,0);var e=null;a&&(b.ba=b.stream.segmentIndex.gb(d),e=b.ba&&b.ba.next().value);e||(b.ba=b.stream.segmentIndex.gb(c),e=b.ba&&b.ba.next().value);return e}
317
- function Rj(a,b,c,d){var e,f,g,h,k,l,m,n,p,q,v,y,w,x,D;return L(function(z){switch(z.g){case 1:return e=qc,f=b.stream,g=b.ba,b.ta=!0,C(z,2),u(z,Sj(a,b,d),4);case 4:df(a.i);if(a.s)return z["return"]();h="video/mp4"==f.mimeType||"audio/mp4"==f.mimeType;k=window.ReadableStream;if(a.h.lowLatencyMode&&k&&h)return n=new Uint8Array(0),q=p=!1,v=function(B){var F,G,H;return L(function(I){if(p)return I["return"]();q=!0;df(a.i);if(a.s)return I["return"]();n=Tj(n,B);F=!1;G=0;(new Ig).box("mdat",function(J){G=
318
- J.size+J.start;F=!0}).parse(n,!1,!0);if(!F)return I.B(0);H=n.subarray(0,G);n=n.subarray(G);return u(I,Uj(a,b,c,f,d,H),0)})},u(z,Vj(a,b,d,v),9);l=Vj(a,b,d);return u(z,l,7);case 7:return m=z.h,df(a.i),a.s?z["return"]():b.ab?(b.ta=!1,Dj(a,b,0),z["return"]()):u(z,Uj(a,b,c,f,d,m),6);case 9:y=z.h;if(q){z.B(6);break}p=!0;df(a.i);return a.s?z["return"]():b.ab?(b.ta=!1,Dj(a,b,0),z["return"]()):u(z,Uj(a,b,c,f,d,y),6);case 6:df(a.i);if(a.s)return z["return"]();b.Ba=d;g.next();b.ta=!1;b.Pd=!1;w=a.g.R.Ya();x=
319
- w[b.type];$a(JSON.stringify(x));b.ab||a.g.Ld();Dj(a,b,0);va(z,0);break;case 2:D=E(z);df(a.i,D);if(a.s)return z["return"]();b.ta=!1;if(7001==D.code)b.ta=!1,yj(b),Dj(a,b,0),z.B(0);else if(b.type==e.Z&&a.h.ignoreTextStreamFailures)a.j["delete"](e.Z),z.B(0);else if(3017==D.code)Wj(a,b,D),z.B(0);else return b.hc=!0,D.severity=2,u(z,Oj(a,D),0)}})}function Tj(a,b){var c=new Uint8Array(a.length+b.length);c.set(a);c.set(b,a.length);return c}
320
- function Wj(a,b,c){if(!Array.from(a.j.values()).some(function(e){return e!=b&&e.Pd})){var d=Math.round(100*a.u);if(20<d)a.u-=.2;else if(4<d)a.u-=.04;else{b.hc=!0;a.s=!0;a.g.onError(c);return}b.Pd=!0}Dj(a,b,4)}
321
- function Sj(a,b,c){var d,e,f,g,h,k,l;return L(function(m){d=[];e=Math.max(0,c.appendWindowStart-.1);f=c.appendWindowEnd+.01;g=c.timestampOffset;if(g!=b.zd||e!=b.yd||f!=b.xd)h=function(){var n;return L(function(p){if(1==p.g)return C(p,2),b.yd=e,b.xd=f,b.zd=g,u(p,Ci(a.g.R,b.type,g,e,f),4);if(2!=p.g)return va(p,0);n=E(p);b.yd=null;b.xd=null;b.zd=null;throw n;})},d.push(h());!Hi(c.g,b.Mc)&&(b.Mc=c.g)&&(k=Vj(a,b,c.g),l=function(){var n,p,q;return L(function(v){switch(v.g){case 1:return C(v,2),u(v,k,4);
317
+ function Rj(a,b,c,d){var e,f,g,h,k,l,m,n,p,q,v,w,x,y,D;return L(function(z){switch(z.g){case 1:return e=qc,f=b.stream,g=b.ba,b.ta=!0,C(z,2),u(z,Sj(a,b,d),4);case 4:df(a.i);if(a.s)return z["return"]();h="video/mp4"==f.mimeType||"audio/mp4"==f.mimeType;k=window.ReadableStream;if(a.h.lowLatencyMode&&k&&h)return n=new Uint8Array(0),q=p=!1,v=function(B){var F,G,H;return L(function(I){if(p)return I["return"]();q=!0;df(a.i);if(a.s)return I["return"]();n=Tj(n,B);F=!1;G=0;(new Ig).box("mdat",function(J){G=
318
+ J.size+J.start;F=!0}).parse(n,!1,!0);if(!F)return I.B(0);H=n.subarray(0,G);n=n.subarray(G);return u(I,Uj(a,b,c,f,d,H),0)})},u(z,Vj(a,b,d,v),9);l=Vj(a,b,d);return u(z,l,7);case 7:return m=z.h,df(a.i),a.s?z["return"]():b.ab?(b.ta=!1,Dj(a,b,0),z["return"]()):u(z,Uj(a,b,c,f,d,m),6);case 9:w=z.h;if(q){z.B(6);break}p=!0;df(a.i);return a.s?z["return"]():b.ab?(b.ta=!1,Dj(a,b,0),z["return"]()):u(z,Uj(a,b,c,f,d,w),6);case 6:df(a.i);if(a.s)return z["return"]();b.Ba=d;g.next();b.ta=!1;b.Qd=!1;x=a.g.R.Ya();y=
319
+ x[b.type];$a(JSON.stringify(y));b.ab||a.g.Md();Dj(a,b,0);va(z,0);break;case 2:D=E(z);df(a.i,D);if(a.s)return z["return"]();b.ta=!1;if(7001==D.code)b.ta=!1,yj(b),Dj(a,b,0),z.B(0);else if(b.type==e.Z&&a.h.ignoreTextStreamFailures)a.j["delete"](e.Z),z.B(0);else if(3017==D.code)Wj(a,b,D),z.B(0);else return b.hc=!0,D.severity=2,u(z,Oj(a,D),0)}})}function Tj(a,b){var c=new Uint8Array(a.length+b.length);c.set(a);c.set(b,a.length);return c}
320
+ function Wj(a,b,c){if(!Array.from(a.j.values()).some(function(e){return e!=b&&e.Qd})){var d=Math.round(100*a.u);if(20<d)a.u-=.2;else if(4<d)a.u-=.04;else{b.hc=!0;a.s=!0;a.g.onError(c);return}b.Qd=!0}Dj(a,b,4)}
321
+ function Sj(a,b,c){var d,e,f,g,h,k,l;return L(function(m){d=[];e=Math.max(0,c.appendWindowStart-.1);f=c.appendWindowEnd+.01;g=c.timestampOffset;if(g!=b.Bd||e!=b.zd||f!=b.yd)h=function(){var n;return L(function(p){if(1==p.g)return C(p,2),b.zd=e,b.yd=f,b.Bd=g,u(p,Ci(a.g.R,b.type,g,e,f),4);if(2!=p.g)return va(p,0);n=E(p);b.zd=null;b.yd=null;b.Bd=null;throw n;})},d.push(h());!Hi(c.g,b.Mc)&&(b.Mc=c.g)&&(k=Vj(a,b,c.g),l=function(){var n,p,q;return L(function(v){switch(v.g){case 1:return C(v,2),u(v,k,4);
322
322
  case 4:return n=v.h,df(a.i),p=b.stream.closedCaptions&&0<b.stream.closedCaptions.size,u(v,wi(a.g.R,b.type,n,null,null,p),5);case 5:va(v,0);break;case 2:throw q=E(v),b.Mc=null,q;}})},a.g.Jf(c.startTime,c.g),d.push(l()));return u(m,Promise.all(d),0)})}
323
- function Uj(a,b,c,d,e,f){var g;return L(function(h){if(1==h.g)return g=d.closedCaptions&&0<d.closedCaptions.size,(null!=d.emsgSchemeIdUris&&0<d.emsgSchemeIdUris.length||a.h.dispatchAllEmsgBoxes)&&(new Ig).P("emsg",function(k){var l=d.emsgSchemeIdUris;if(0===k.version){var m=k.reader.kc();var n=k.reader.kc();var p=k.reader.M();var q=k.reader.M();var v=k.reader.M();var y=k.reader.M();var w=e.startTime+q/p}else p=k.reader.M(),w=k.reader.Lb()/p+e.timestampOffset,q=w-e.startTime,v=k.reader.M(),y=k.reader.M(),
324
- m=k.reader.kc(),n=k.reader.kc();k=k.reader.Za(k.reader.O.byteLength-k.reader.X());if(l&&l.includes(m)||a.h.dispatchAllEmsgBoxes)"urn:mpeg:dash:event:2012"==m?a.g.Kf():(l=(new Map).set("detail",{startTime:w,endTime:w+v/p,schemeIdUri:m,value:n,timescale:p,presentationTimeDelta:q,eventDuration:v,id:y,messageData:k}),l=new Q(Xj,l),a.g.onEvent(l))}).parse(f),u(h,Yj(a,b,c),2);if(3!=h.g)return df(a.i),u(h,wi(a.g.R,b.type,f,e.startTime,e.endTime,g),3);df(a.i);A(h)})}
323
+ function Uj(a,b,c,d,e,f){var g;return L(function(h){if(1==h.g)return g=d.closedCaptions&&0<d.closedCaptions.size,(null!=d.emsgSchemeIdUris&&0<d.emsgSchemeIdUris.length||a.h.dispatchAllEmsgBoxes)&&(new Ig).P("emsg",function(k){var l=d.emsgSchemeIdUris;if(0===k.version){var m=k.reader.kc();var n=k.reader.kc();var p=k.reader.M();var q=k.reader.M();var v=k.reader.M();var w=k.reader.M();var x=e.startTime+q/p}else p=k.reader.M(),x=k.reader.Lb()/p+e.timestampOffset,q=x-e.startTime,v=k.reader.M(),w=k.reader.M(),
324
+ m=k.reader.kc(),n=k.reader.kc();k=k.reader.Za(k.reader.O.byteLength-k.reader.X());if(l&&l.includes(m)||a.h.dispatchAllEmsgBoxes)"urn:mpeg:dash:event:2012"==m?a.g.Kf():(l=(new Map).set("detail",{startTime:x,endTime:x+v/p,schemeIdUri:m,value:n,timescale:p,presentationTimeDelta:q,eventDuration:v,id:w,messageData:k}),l=new Q(Xj,l),a.g.onEvent(l))}).parse(f),u(h,Yj(a,b,c),2);if(3!=h.g)return df(a.i),u(h,wi(a.g.R,b.type,f,e.startTime,e.endTime,g),3);df(a.i);A(h)})}
325
325
  function Yj(a,b,c){var d,e,f,g;return L(function(h){if(1==h.g){d=Math.max(a.h.bufferBehind,a.m.presentationTimeline.g);e=si(a.g.R,b.type);if(null==e)return h["return"]();f=c-e;g=f-d;return.01>=g?h["return"]():u(h,a.g.R.remove(b.type,e,e+g),2)}df(a.i);A(h)})}function Pj(a){return a&&a.type==pc&&("application/cea-608"==a.stream.mimeType||"application/cea-708"==a.stream.mimeType)}
326
326
  function Vj(a,b,c,d){var e,f,g,h,k;return L(function(l){if(1==l.g)return e=bf,f=vj(c.sa(),c.pa,c.ha,a.h.retryParameters,d),g=b.stream,a.g.modifySegmentRequest(f,{type:g.type,init:c instanceof Gi,duration:c.endTime-c.startTime,mimeType:g.mimeType,codecs:g.codecs,bandwidth:g.bandwidth}),h=a.g.nb.request(e,f),b.va=h,u(l,h.promise,2);k=l.h;b.va=null;return l["return"](k.data)})}
327
327
  function Jj(a,b,c,d){var e,f;return L(function(g){if(1==g.g)return b.ab=!1,b.Xc=!1,b.Ac=0,b.Zb=!0,b.Ba=null,b.Mc=null,b.ba=null,d?(e=a.g.Ic(),f=a.g.R.getDuration(),u(g,a.g.R.remove(b.type,e+d,f),3)):u(g,Bi(a.g.R,b.type),4);if(3!=g.g)return df(a.i),c?u(g,a.g.R.flush(b.type),3):g.B(3);df(a.i);b.Zb=!1;b.endOfStream=!1;b.ta||b.La||Dj(a,b,0);A(g)})}
@@ -342,14 +342,14 @@ q.startTime?p.startTime-q.startTime:p.endTime-q.endTime});h=t(h);for(k=h.next();
342
342
  function pk(a,b,c){var d=1<c.length,e=d?"span":"div";if(b.lineBreak||b.spacer)b.spacer&&Kb("shaka.extern.Cue","Please use lineBreak instead of spacer."),e="br";d=!d&&0<b.nestedCues.length;var f=document.createElement(e);"br"!=e&&qk(a,f,b,c,d);c=null;if(b.region&&b.region.id)if(c=b.region,e=c.id+"_"+c.width+"x"+c.height+(c.heightUnits==Ab?"%":"px")+"-"+c.viewportAnchorX+"x"+c.viewportAnchorY+(c.viewportAnchorUnits==Ab?"%":"px"),a.o.has(e))c=a.o.get(e);else{var g=document.createElement("span"),h=c.heightUnits==
343
343
  Ab?"%":"px",k=c.widthUnits==Ab?"%":"px",l=c.viewportAnchorUnits==Ab?"%":"px";g.id="shaka-text-region---"+e;g.classList.add("shaka-text-region");g.style.height=c.height+h;g.style.width=c.width+k;g.style.position="absolute";g.style.top=c.viewportAnchorY+l;g.style.left=c.viewportAnchorX+l;g.style.display="flex";g.style.flexDirection="column";g.style.alignItems="center";g.style.justifyContent="before"==b.displayAlign?"flex-start":"center"==b.displayAlign?"center":"flex-end";a.o.set(e,g);c=g}e=f;d&&(e=
344
344
  document.createElement("span"),e.classList.add("shaka-text-wrapper"),e.style.backgroundColor=b.backgroundColor,f.appendChild(e));a.h.set(b,{qd:f,Je:e,lc:c})}
345
- function qk(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=rk(c.linePadding,c,a.m);f.paddingRight=rk(c.linePadding,c,a.m);if(c.backgroundImage)f.backgroundImage="url('"+c.backgroundImage+"')",f.backgroundRepeat="no-repeat",f.backgroundSize=
346
- "contain",f.backgroundPosition="center",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=sk(d,function(m){return m.backgroundColor}))?l.style.backgroundColor=b:k&&(l.style.backgroundColor="rgba(0, 0, 0, 0.8)"));k&&(l.textContent=k)}h&&!d[d.length-1].isContainer?f.display="inline":(f.display="flex",f.flexDirection="column",f.alignItems="center",f.justifyContent="before"==c.displayAlign?
347
- "flex-start":"center"==c.displayAlign?"center":"flex-end");g||(f.margin="0");f.fontFamily=c.fontFamily;f.fontWeight=c.fontWeight.toString();f.fontStyle=c.fontStyle;f.letterSpacing=c.letterSpacing;f.fontSize=rk(c.fontSize,c,a.m);null!=c.line&&1==c.lineInterpretation&&(f.position="absolute",f.left="0",f.top="0",c.writingMode==nb?(f.width="100%",c.lineAlign==pb?f.top=c.line+"%":"end"==c.lineAlign&&(f.bottom=100-c.line+"%")):"vertical-lr"==c.writingMode?(f.height="100%",c.lineAlign==pb?f.left=c.line+
345
+ function qk(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=rk(c.linePadding,c,a.m);f.paddingRight=rk(c.linePadding,c,a.m);f.textShadow=c.textShadow;if(c.backgroundImage)f.backgroundImage="url('"+c.backgroundImage+"')",f.backgroundRepeat=
346
+ "no-repeat",f.backgroundSize="contain",f.backgroundPosition="center",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=sk(d,function(m){return m.backgroundColor}))?l.style.backgroundColor=b:k&&(l.style.backgroundColor="rgba(0, 0, 0, 0.8)"));k&&(l.textContent=k)}h&&!d[d.length-1].isContainer?f.display="inline":(f.display="flex",f.flexDirection="column",f.alignItems="center",f.justifyContent=
347
+ "before"==c.displayAlign?"flex-start":"center"==c.displayAlign?"center":"flex-end");g||(f.margin="0");f.fontFamily=c.fontFamily;f.fontWeight=c.fontWeight.toString();f.fontStyle=c.fontStyle;f.letterSpacing=c.letterSpacing;f.fontSize=rk(c.fontSize,c,a.m);null!=c.line&&1==c.lineInterpretation&&(f.position="absolute",c.writingMode==nb?(f.width="100%",c.lineAlign==pb?f.top=c.line+"%":"end"==c.lineAlign&&(f.bottom=100-c.line+"%")):"vertical-lr"==c.writingMode?(f.height="100%",c.lineAlign==pb?f.left=c.line+
348
348
  "%":"end"==c.lineAlign&&(f.right=100-c.line+"%")):(f.height="100%",c.lineAlign==pb?f.right=c.line+"%":"end"==c.lineAlign&&(f.left=100-c.line+"%")));f.lineHeight=c.lineHeight;null!=c.position&&(c.writingMode==nb?f.paddingLeft=c.position:f.paddingTop=c.position);"line-left"==c.positionAlign?f.cssFloat="left":"line-right"==c.positionAlign&&(f.cssFloat="right");f.textAlign=c.textAlign;f.textDecoration=c.textDecoration.join(" ");f.writingMode=c.writingMode;"writingMode"in document.documentElement.style&&
349
349
  f.writingMode==c.writingMode||(f.webkitWritingMode=c.writingMode);c.size&&(c.writingMode==nb?f.width=c.size+"%":f.height=c.size+"%")}function rk(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}}
350
350
  function sk(a,b){for(var c=a.length-1;0<=c;c--){var d=b(a[c]);if(d||0===d)return d}return null}M("shaka.text.UITextDisplayer",lk);lk.prototype.setTextVisibility=lk.prototype.setTextVisibility;lk.prototype.isTextVisible=lk.prototype.isTextVisible;lk.prototype.remove=lk.prototype.remove;lk.prototype.destroy=lk.prototype.destroy;lk.prototype.append=lk.prototype.append;function tk(a,b){function c(k,l){for(var m=t(k),n=m.next();!n.done;n=m.next())if(n=n.value,n.isContainer)c(n.nestedCues,l);else{var p=n.clone();p.nestedCues=[];p.payload=e(n);l.push(p)}return l}function d(k){for(var l=k,m=t(b),n=m.next();!n.done;n=m.next())n=n.value,n.end&&n.start<k&&(l+=n.end-n.start);k=Math.floor(l/3600);m=Math.floor(l/60%60);n=Math.floor(l%60);l=Math.floor(1E3*l%1E3);return(10>k?"0":"")+k+":"+(10>m?"0":"")+m+":"+(10>n?"0":"")+n+"."+(100>l?10>l?"00":"0":"")+l}function e(k){var l=
351
351
  [],m=700<=k.fontWeight,n="italic"==k.fontStyle,p=k.textDecoration.includes("underline");m&&l.push("b");n&&l.push("i");p&&l.push("u");m=l.reduce(function(q,v){return q+"<"+v+">"},"");l=l.reduceRight(function(q,v){return q+"</"+v+">"},"");return k.lineBreak||k.spacer?(k.spacer&&Kb("shaka.text.Cue","Please use lineBreak instead of spacer."),"\n"):k.nestedCues.length?k.nestedCues.map(e).join(""):m+k.payload+l}var f=c(a,[]),g="WEBVTT\n\n";f=t(f);for(var h=f.next();!h.done;h=f.next())h=h.value,g+=d(h.startTime)+
352
- " --\x3e "+d(h.endTime)+function(k){var l=[];switch(k.textAlign){case "left":l.push("align:left");break;case "right":l.push("align:right");break;case mb:l.push("align:middle");break;case "start":l.push("align:start");break;case "end":l.push("align:end")}switch(k.writingMode){case "vertical-lr":l.push("vertical:lr");break;case "vertical-rl":l.push("vertical:rl")}return l.length?" "+l.join(" "):""}(h)+"\n",g+=h.payload+"\n\n";return g}M("shaka.text.WebVttGenerator",function(){});function uk(a,b){this.h=a;this.g=b;this.j="";this.o=void 0;this.i=!1;this.m=!0;this.l=!1}function vk(a,b,c){try{if(a.g.enabled){var d={d:1E3*c.duration,st:a.h.T()?wk:xk};d.ot=yk(c);var e=d.ot===zk||d.ot===Ak||d.ot===Bk||d.ot===Ck;e&&(d.bl=Dk(a,c.type));c.bandwidth&&(d.br=c.bandwidth/1E3);e&&d.ot!==Ck&&(d.tb=Ek(a,d.ot)/1E3);Fk(a,b,d)}}catch(f){Va("CMCD_SEGMENT_ERROR","Could not generate segment CMCD data.",f)}}
352
+ " --\x3e "+d(h.endTime)+function(k){var l=[];switch(k.textAlign){case "left":l.push("align:left");break;case "right":l.push("align:right");break;case mb:l.push("align:middle");break;case "start":l.push("align:start");break;case "end":l.push("align:end")}switch(k.writingMode){case "vertical-lr":l.push("vertical:lr");break;case "vertical-rl":l.push("vertical:rl")}return l.length?" "+l.join(" "):""}(h)+"\n",g+=h.payload+"\n\n";return g}M("shaka.text.WebVttGenerator",function(){});function uk(a,b){this.h=a;this.g=b;this.j="";this.o=void 0;this.i=!1;this.m=!0;this.l=!1}function vk(a,b,c){try{if(a.g.enabled){var d={d:1E3*c.duration,st:a.h.U()?wk:xk};d.ot=yk(c);var e=d.ot===zk||d.ot===Ak||d.ot===Bk||d.ot===Ck;e&&(d.bl=Dk(a,c.type));c.bandwidth&&(d.br=c.bandwidth/1E3);e&&d.ot!==Ck&&(d.tb=Ek(a,d.ot)/1E3);Fk(a,b,d)}}catch(f){Va("CMCD_SEGMENT_ERROR","Could not generate segment CMCD data.",f)}}
353
353
  function Gk(a,b,c){try{if(!a.g.enabled)return b;var d=Hk(a);a:{switch(c){case "video/webm":case "video/mp4":var e=Bk;break a;case "application/x-mpegurl":e=Ik;break a}e=void 0}d.ot=e;d.su=!0;var f=Jk(d);return Kk(b,f)}catch(g){return Va("CMCD_SRC_ERROR","Could not generate src CMCD data.",g),b}}function Lk(a,b){try{if(!a.g.enabled)return b;var c=Hk(a);c.ot=Mk;c.su=!0;var d=Jk(c);return Kk(b,d)}catch(e){return Va("CMCD_TEXT_TRACK_ERROR","Could not generate text track CMCD data.",e),b}}
354
354
  function Hk(a){a.j||(a.j=a.g.sessionId||window.crypto.randomUUID());return{v:1,sf:a.o,sid:a.j,cid:a.g.contentId,mtp:a.h.getBandwidthEstimate()/1E3}}function Fk(a,b,c){c=void 0===c?{}:c;var d=void 0===d?a.g.useHeaders:d;if(a.g.enabled){Object.assign(c,Hk(a));c.pr=a.h.Hc();var e=c.ot===zk||c.ot===Bk;a.l&&e&&(c.bs=!0,c.su=!0,a.l=!1);null==c.su&&(c.su=a.m);if(d)a=Nk(c),Object.keys(a).length&&Object.assign(b.headers,a);else{var f=Jk(c);f&&(b.uris=b.uris.map(function(g){return Kk(g,f)}))}}}
355
355
  function yk(a){var b=a.type;if(a.init)return Ok;if("video"==b)return a.codecs.includes(",")?Bk:zk;if("audio"==b)return Ak;if("text"==b)return"application/mp4"===a.mimeType?Ck:Mk}function Dk(a,b){var c=a.h.Ya()[b];if(!c.length)return NaN;var d=a.h.getCurrentTime();return(c=c.find(function(e){return e.start<=d&&e.end>=d}))?1E3*(c.end-d):NaN}
@@ -369,92 +369,92 @@ maxHeight:Infinity,minPixels:0,maxPixels:Infinity,minFrameRate:0,maxFrameRate:In
369
369
  function Wk(a,b,c){var d={".drm.servers":"",".drm.clearKeys":"",".drm.advanced":{distinctiveIdentifierRequired:!1,persistentStateRequired:!1,videoRobustness:"",audioRobustness:"",sessionType:"",serverCertificate:new Uint8Array(0),serverCertificateUri:"",individualizationServer:""}};return Qk(a,b,c||Uk(),d,"")}
370
370
  function Vk(a,b){var c=a.filter(function(h){return"variant"==h.type}),d=[],e=yd(b,c.map(function(h){return h.language}));e&&(d=c.filter(function(h){return rd(h.language)==e}));0==d.length&&(d=c.filter(function(h){return h.primary}));0==d.length&&(c.map(function(h){return h.language}),d=c);var f=d.filter(function(h){return h.height&&480>=h.height});f.length&&(f.sort(function(h,k){return k.height-h.height}),d=f.filter(function(h){return h.height==f[0].height}));c=[];if(d.length){var g=Math.floor(d.length/
371
371
  2);d.sort(function(h,k){return h.bandwidth-k.bandwidth});c.push(d[g])}d=t(a);for(g=d.next();!g.done;g=d.next())g=g.value,g.type!=pc&&"image"!=g.type||c.push(g);return c}M("shaka.util.PlayerConfiguration",Tk);Tk.mergeConfigObjects=Wk;function Xk(){this.g=null;this.h=[]}function Yk(a,b){if(null==a.g)a.g={timestamp:Date.now()/1E3,state:b,duration:0};else{var c=Date.now()/1E3;a.g.duration=c-a.g.timestamp;a.g.state!=b&&(a.h.push(a.g),a.g={timestamp:c,state:b,duration:0})}}function Zk(a,b){var c=0;a.g&&a.g.state==b&&(c+=a.g.duration);for(var d=t(a.h),e=d.next();!e.done;e=d.next())e=e.value,c+=e.state==b?e.duration:0;return c}
372
- function $k(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 al(){this.i=this.h=null;this.g=[]}function bl(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 cl(){this.u=this.C=this.G=this.D=this.s=this.j=this.F=this.m=this.i=this.I=this.L=this.N=this.l=this.o=NaN;this.g=new Xk;this.h=new al};function U(a,b){Ne.call(this);var c=this;this.l=dl;this.Cc=this.g=null;this.ka=!1;this.Kc=new ef;this.Ob=new ef;this.o=new ef;this.ud=this.u=this.Ub=this.i=this.Lc=this.I=this.j=this.xa=this.W=this.ya=this.L=this.Dc=this.G=this.yb=this.C=this.N=this.m=this.F=null;this.Jd=1E9;this.h=el(this);this.Gd={width:Infinity,height:Infinity};this.s=null;this.Ma=new ue(this.h.preferredAudioLanguage,this.h.preferredVariantRole,this.h.preferredAudioChannelCount);this.wb=this.h.preferredTextLanguage;this.Yb=this.h.preferredTextRole;
373
- this.Xb=this.h.preferForcedSubs;this.Vb=[];this.ac=null;b&&b(this);this.F=fl(this);this.F.Vd(this.h.streaming.forceHTTPS);this.D=null;gl&&(this.D=Sb(gl));this.Kc.A(window,"online",function(){c.Qd()});this.V={name:"detach"};this.ca={name:"attach"};this.fa={name:"unload"};this.Md={name:"manifest-parser"};this.Cd={name:"manifest"};this.xb={name:"media-source"};this.vd={name:"drm-engine"};this.da={name:"load"};this.Nd={name:"src-equals-drm-engine"};this.zb={name:"src-equals"};var d=new Map;d.set(this.ca,
374
- function(e,f){return Je(hl(c,e,f))});d.set(this.V,function(e){e.J&&(c.Ob.Sa(),e.J=null);c.D&&c.D.release();c.g=null;e=Promise.resolve();return Je(e)});d.set(this.fa,function(e){return Je(il(c,e))});d.set(this.xb,function(e){e=jl(c,e);return Je(e)});d.set(this.Md,function(e,f){var g=kl(c,e,f);return Je(g)});d.set(this.Cd,function(e){return ll(c,e)});d.set(this.vd,function(e){e=ml(c,e);return Je(e)});d.set(this.da,function(e,f){return Je(nl(c,e,f))});d.set(this.Nd,function(e,f){var g=ol(c,e,f);return Je(g)});
375
- d.set(this.zb,function(e,f){return pl(c,e,f)});this.Ga=new Zj(this.V,{nf:function(e,f,g,h){var k=null;e==c.V&&(k=g==c.V?c.V:c.ca);e==c.ca&&(k=g==c.V||f.J!=h.J?c.V:g==c.ca?c.ca:g==c.xb||g==c.da?c.xb:g==c.zb?c.Nd:null);e==c.xb&&(k=g==c.da&&f.J==h.J?c.Md:c.fa);e==c.Md&&(k=ql(c.da,c.Cd,c.fa,g,f,h));e==c.Cd&&(k=ql(c.da,c.vd,c.fa,g,f,h));e==c.vd&&(k=ql(c.da,c.da,c.fa,g,f,h));e==c.Nd&&(k=g==c.zb&&f.J==h.J?c.zb:c.fa);if(e==c.da||e==c.zb)k=c.fa;e==c.fa&&(k=h.J&&f.J==h.J?c.ca:c.V);return k},Ze:function(e,f,
372
+ function $k(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 al(){this.i=this.h=null;this.g=[]}function bl(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 cl(){this.u=this.C=this.G=this.D=this.s=this.j=this.F=this.m=this.i=this.I=this.L=this.N=this.l=this.o=NaN;this.g=new Xk;this.h=new al};function U(a,b){Ne.call(this);var c=this;this.l=dl;this.Cc=this.g=null;this.ka=!1;this.Kc=new ef;this.Ob=new ef;this.o=new ef;this.vd=this.u=this.Ub=this.i=this.Lc=this.I=this.j=this.xa=this.W=this.ya=this.L=this.Dc=this.G=this.yb=this.C=this.N=this.m=this.F=null;this.Kd=1E9;this.h=el(this);this.Hd={width:Infinity,height:Infinity};this.s=null;this.Ma=new ue(this.h.preferredAudioLanguage,this.h.preferredVariantRole,this.h.preferredAudioChannelCount);this.wb=this.h.preferredTextLanguage;this.Yb=this.h.preferredTextRole;
373
+ this.Xb=this.h.preferForcedSubs;this.Vb=[];this.ac=null;b&&b(this);this.F=fl(this);this.F.Wd(this.h.streaming.forceHTTPS);this.D=null;gl&&(this.D=Sb(gl));this.Kc.A(window,"online",function(){c.Rd()});this.V={name:"detach"};this.ca={name:"attach"};this.fa={name:"unload"};this.Nd={name:"manifest-parser"};this.Dd={name:"manifest"};this.xb={name:"media-source"};this.wd={name:"drm-engine"};this.da={name:"load"};this.Od={name:"src-equals-drm-engine"};this.zb={name:"src-equals"};var d=new Map;d.set(this.ca,
374
+ function(e,f){return Je(hl(c,e,f))});d.set(this.V,function(e){e.J&&(c.Ob.Ta(),e.J=null);c.D&&c.D.release();c.g=null;e=Promise.resolve();return Je(e)});d.set(this.fa,function(e){return Je(il(c,e))});d.set(this.xb,function(e){e=jl(c,e);return Je(e)});d.set(this.Nd,function(e,f){var g=kl(c,e,f);return Je(g)});d.set(this.Dd,function(e){return ll(c,e)});d.set(this.wd,function(e){e=ml(c,e);return Je(e)});d.set(this.da,function(e,f){return Je(nl(c,e,f))});d.set(this.Od,function(e,f){var g=ol(c,e,f);return Je(g)});
375
+ d.set(this.zb,function(e,f){return pl(c,e,f)});this.Ga=new Zj(this.V,{nf:function(e,f,g,h){var k=null;e==c.V&&(k=g==c.V?c.V:c.ca);e==c.ca&&(k=g==c.V||f.J!=h.J?c.V:g==c.ca?c.ca:g==c.xb||g==c.da?c.xb:g==c.zb?c.Od:null);e==c.xb&&(k=g==c.da&&f.J==h.J?c.Nd:c.fa);e==c.Nd&&(k=ql(c.da,c.Dd,c.fa,g,f,h));e==c.Dd&&(k=ql(c.da,c.wd,c.fa,g,f,h));e==c.wd&&(k=ql(c.da,c.da,c.fa,g,f,h));e==c.Od&&(k=g==c.zb&&f.J==h.J?c.zb:c.fa);if(e==c.da||e==c.zb)k=c.fa;e==c.fa&&(k=h.J&&f.J==h.J?c.ca:c.V);return k},Ze:function(e,f,
376
376
  g){c.dispatchEvent(rl(sl,(new Map).set("state",e.name)));return d.get(e)(f,g)},handleError:function(e){return L(function(f){return 1==f.g?u(f,il(c,e),2):f["return"](e.J?c.ca:c.V)})},If:function(e){c.dispatchEvent(rl(tl,(new Map).set("state",e.name)))}});a&&this.Wb(a,!0)}qa(U,Ne);function rl(a,b){return new Q(a,b)}r=U.prototype;
377
- r.destroy=function(){var a=this,b;return L(function(c){switch(c.g){case 1:if(a.l==ul)return c["return"]();a.l=ul;b=ek(a.Ga,function(){return{node:a.V,payload:ak(),kb:!1}});return u(c,new Promise(function(d){b.Ib=function(){};b.Oc=function(){d()};b.pb=function(){d()};b.onError=function(){d()};b.Qc=function(){d()}}),2);case 2:return u(c,a.Ga.destroy(),3);case 3:a.Kc&&(a.Kc.release(),a.Kc=null);a.Ob&&(a.Ob.release(),a.Ob=null);a.o&&(a.o.release(),a.o=null);a.ud=null;a.u=null;a.h=null;a.s=null;a.Cc=null;
377
+ r.destroy=function(){var a=this,b;return L(function(c){switch(c.g){case 1:if(a.l==ul)return c["return"]();a.l=ul;b=ek(a.Ga,function(){return{node:a.V,payload:ak(),kb:!1}});return u(c,new Promise(function(d){b.Ib=function(){};b.Oc=function(){d()};b.pb=function(){d()};b.onError=function(){d()};b.Qc=function(){d()}}),2);case 2:return u(c,a.Ga.destroy(),3);case 3:a.Kc&&(a.Kc.release(),a.Kc=null);a.Ob&&(a.Ob.release(),a.Ob=null);a.o&&(a.o.release(),a.o=null);a.vd=null;a.u=null;a.h=null;a.s=null;a.Cc=null;
378
378
  a.W=null;if(!a.F){c.B(4);break}return u(c,a.F.destroy(),5);case 5:a.F=null;case 4:Ne.prototype.release.call(a),A(c)}})};r.Wb=function(a,b){b=void 0===b?!0:b;if(this.l==ul)return Promise.reject(vl());var c=ak();c.J=a;uc()||(b=!1);var d=b?this.xb:this.ca,e=ek(this.Ga,function(){return{node:d,payload:c,kb:!1}});e.Ib=function(){};return wl(e)};r.detach=function(){var a=this;if(this.l==ul)return Promise.reject(vl());var b=ek(this.Ga,function(){return{node:a.V,payload:ak(),kb:!1}});b.Ib=function(){};return wl(b)};
379
- r.be=function(a){var b=this;a=void 0===a?!0:a;if(this.l==ul)return Promise.reject(vl());uc()||(a=!1);var c=ak(),d=ek(this.Ga,function(e){var f=e.J&&a?b.xb:e.J?b.ca:b.V;c.J=e.J;return{node:f,payload:c,kb:!1}});d.Ib=function(){};return wl(d)};r.hg=function(a){this.ac=a};
380
- r.load=function(a,b,c){var d=this;this.ac=null;if(this.l==ul)return Promise.reject(vl());this.dispatchEvent(rl(xl));var e=ak();e.uri=a;e.Zd=Date.now()/1E3;c&&(e.mimeType=c);void 0!==b&&(e.startTime=b);var f=yl(this,e)?this.zb:this.da,g=ek(this.Ga,function(h){if(null==h.J)return null;e.J=h.J;return{node:f,payload:e,kb:!0}});this.s=new cl;this.W=zl(this);g.Ib=function(){};return new Promise(function(h,k){g.Qc=function(){return k(new N(2,7,7002))};g.Oc=function(){h();d.dispatchEvent(rl(Al))};g.pb=function(){return k(vl())};
379
+ r.ce=function(a){var b=this;a=void 0===a?!0:a;if(this.l==ul)return Promise.reject(vl());uc()||(a=!1);var c=ak(),d=ek(this.Ga,function(e){var f=e.J&&a?b.xb:e.J?b.ca:b.V;c.J=e.J;return{node:f,payload:c,kb:!1}});d.Ib=function(){};return wl(d)};r.hg=function(a){this.ac=a};
380
+ r.load=function(a,b,c){var d=this;this.ac=null;if(this.l==ul)return Promise.reject(vl());this.dispatchEvent(rl(xl));var e=ak();e.uri=a;e.$d=Date.now()/1E3;c&&(e.mimeType=c);void 0!==b&&(e.startTime=b);var f=yl(this,e)?this.zb:this.da,g=ek(this.Ga,function(h){if(null==h.J)return null;e.J=h.J;return{node:f,payload:e,kb:!0}});this.s=new cl;this.W=zl(this);g.Ib=function(){};return new Promise(function(h,k){g.Qc=function(){return k(new N(2,7,7002))};g.Oc=function(){h();d.dispatchEvent(rl(Al))};g.pb=function(){return k(vl())};
381
381
  g.onError=function(l){return k(l)}})};function yl(a,b){if(!uc())return!0;var c=b.mimeType,d=b.uri||"";c||(c=Cg(d),c=Bl[c]);if(c){if(""==(b.J||wc()).canPlayType(c))return!1;if(!uc()||!(c in Bg||Cg(d)in Dg)||a.h.streaming.preferNativeHls)return!0;if(Cc())return a.h.streaming.useNativeHlsOnSafari}return!1}function hl(a,b,c){null==b.J&&(b.J=c.J,a.Ob.A(b.J,"error",function(){var d=Cl(a);d&&Dl(a,d)}));a.g=b.J;return Promise.resolve()}
382
- function il(a,b){var c,d,e,f,g,h,k,l,m;return L(function(n){switch(n.g){case 1:return a.l!=ul&&(a.l=dl),c=a.Vb.map(function(p){return p()}),a.Vb=[],u(n,Promise.all(c),2);case 2:a.dispatchEvent(rl(El));b.mimeType=null;b.startTime=null;b.uri=null;a.ya&&(a.ya.release(),a.ya=null);b.J&&a.o.Sa();a.yb&&(a.yb.release(),a.yb=null);a.Dc&&(a.Dc.stop(),a.Dc=null);if(!a.I){n.B(3);break}return u(n,a.I.stop(),4);case 4:a.I=null,a.Lc=null;case 3:if(!a.u){n.B(5);break}return u(n,a.u.stop(),5);case 5:if(!a.j){n.B(7);
382
+ function il(a,b){var c,d,e,f,g,h,k,l,m;return L(function(n){switch(n.g){case 1:return a.l!=ul&&(a.l=dl),c=a.Vb.map(function(p){return p()}),a.Vb=[],u(n,Promise.all(c),2);case 2:a.dispatchEvent(rl(El));b.mimeType=null;b.startTime=null;b.uri=null;a.ya&&(a.ya.release(),a.ya=null);b.J&&a.o.Ta();a.yb&&(a.yb.release(),a.yb=null);a.Dc&&(a.Dc.stop(),a.Dc=null);if(!a.I){n.B(3);break}return u(n,a.I.stop(),4);case 4:a.I=null,a.Lc=null;case 3:if(!a.u){n.B(5);break}return u(n,a.u.stop(),5);case 5:if(!a.j){n.B(7);
383
383
  break}return u(n,a.j.destroy(),8);case 8:a.j=null;case 7:a.G&&(a.G.release(),a.G=null);a.C&&(a.C.release(),a.C=null);if(!a.N){n.B(9);break}return u(n,a.N.destroy(),10);case 10:a.N=null;case 9:if(a.D)a.D.onAssetUnload();if(!b.J||!b.J.src){n.B(11);break}return u(n,new Promise(function(p){return(new O(p)).S(.1)}),12);case 12:for(b.J.removeAttribute("src"),b.J.load();b.J.lastChild;)b.J.removeChild(b.J.firstChild);case 11:if(!a.m){n.B(13);break}return u(n,a.m.destroy(),14);case 14:a.m=null;case 13:a.Ub=
384
- null;a.L=null;if(a.i){d=t(a.i.variants);for(e=d.next();!e.done;e=d.next())for(f=e.value,g=t([f.audio,f.video]),h=g.next();!h.done;h=g.next())(k=h.value)&&k.segmentIndex&&k.segmentIndex.release();l=t(a.i.textStreams);for(h=l.next();!h.done;h=l.next())m=h.value,m.segmentIndex&&m.segmentIndex.release()}a.i=null;a.s=new cl;a.wd=null;Fl(a);A(n)}})}
385
- function jl(a,b){var c,d,e,f;return L(function(g){if(1==g.g)return c=new bi,d=a.h.textDisplayFactory,e=Sb(d),a.wd=d,f=Gl(b.J,c,e,function(h,k,l){h=t(h);for(var m=h.next();!m.done;m=h.next())if(m=m.value,m.data&&m.cueTime&&m.frames){for(var n=m.cueTime+k,p=l,q=t(m.frames),v=q.next();!v.done;v=q.next())Hl(a,n,p,"ID3",v.value);if(a.D)a.D.onHlsTimedMetadata(m,n)}}),u(g,f.D,2);a.N=f;A(g)})}
384
+ null;a.L=null;if(a.i){d=t(a.i.variants);for(e=d.next();!e.done;e=d.next())for(f=e.value,g=t([f.audio,f.video]),h=g.next();!h.done;h=g.next())(k=h.value)&&k.segmentIndex&&k.segmentIndex.release();l=t(a.i.textStreams);for(h=l.next();!h.done;h=l.next())m=h.value,m.segmentIndex&&m.segmentIndex.release()}a.i=null;a.s=new cl;a.xd=null;Fl(a);A(n)}})}
385
+ function jl(a,b){var c,d,e,f;return L(function(g){if(1==g.g)return c=new bi,d=a.h.textDisplayFactory,e=Sb(d),a.xd=d,f=Gl(b.J,c,e,function(h,k,l){h=t(h);for(var m=h.next();!m.done;m=h.next())if(m=m.value,m.data&&m.cueTime&&m.frames){for(var n=m.cueTime+k,p=l,q=t(m.frames),v=q.next();!v.done;v=q.next())Hl(a,n,p,"ID3",v.value);if(a.D)a.D.onHlsTimedMetadata(m,n)}}),u(g,f.D,2);a.N=f;A(g)})}
386
386
  function kl(a,b,c){var d,e,f,g;return L(function(h){if(1==h.g)return b.mimeType=c.mimeType,b.uri=c.uri,d=b.uri,e=a.F,a.Ub=d,f=a,u(h,Ag(d,e,a.h.manifest.retryParameters,b.mimeType),2);f.Lc=h.h;a.I=Sb(a.Lc);g=Oe(a.h.manifest);c.J&&"AUDIO"===c.J.nodeName&&(g.disableVideo=!0);a.I.configure(g);A(h)})}
387
387
  function ll(a,b){var c=b.uri,d=a.F;a.ya=new pj(function(){return a.mc()});a.ya.addEventListener("regionadd",function(g){g=g.region;Il(a,Jl,g);if(a.D)a.D.onDashTimedMetadata(g)});a.xa=null;a.h.streaming.observeQualityChanges&&(a.xa=new lj(function(){return a.Ya()}),a.xa.addEventListener("qualitychange",function(g){var h=g.quality;g=g.position;h=(new Map).set("mediaQuality",{bandwidth:h.bandwidth,audioSamplingRate:h.audioSamplingRate,codecs:h.codecs,contentType:h.contentType,frameRate:h.frameRate,height:h.height,
388
388
  mimeType:h.mimeType,channelsCount:h.channelsCount,pixelAspectRatio:h.pixelAspectRatio,width:h.width}).set("position",g);a.dispatchEvent(rl(Kl,h))}));var e={networkingEngine:d,modifyManifestRequest:function(g,h){var k=a.W;try{k.g.enabled&&(k.o=h.format,Fk(k,g,{ot:Ik,su:!k.i}))}catch(l){Va("CMCD_MANIFEST_ERROR","Could not generate manifest CMCD data.",l)}},modifySegmentRequest:function(g,h){vk(a.W,g,h)},filter:function(g){return Ll(a,g)},makeTextStreamsForClosedCaptions:function(g){return Ml(a,g)},
389
389
  onTimelineRegionAdded:function(g){var h=a.ya;a:{var k=t(h.g);for(var l=k.next();!l.done;l=k.next())if(l=l.value,l.schemeIdUri==g.schemeIdUri&&l.id==g.id&&l.startTime==g.startTime&&l.endTime==g.endTime){k=l;break a}k=null}null==k&&(h.g.add(g),g=new Q("regionadd",new Map([["region",g]])),h.dispatchEvent(g))},onEvent:function(g){return a.dispatchEvent(g)},onError:function(g){return Dl(a,g)},isLowLatencyMode:function(){return a.h.streaming.lowLatencyMode},isAutoLowLatencyMode:function(){return a.h.streaming.autoLowLatencyMode},
390
390
  enableLowLatencyMode:function(){a.configure("streaming.lowLatencyMode",!0)}},f=Date.now()/1E3;return new Fe(function(){var g,h,k,l;return L(function(m){if(1==m.g)return g=a,u(m,a.I.start(c,e),2);g.i=m.h;h=rl(Nl);a.dispatchEvent(h);if(0==a.i.variants.length)throw new N(2,4,4036);Ol(a.i);k=Date.now()/1E3;l=k-f;a.s.F=l;A(m)})}(),function(){return a.I.stop()})}
391
391
  function ml(a,b){var c,d;return L(function(e){return 1==e.g?(c=Date.now()/1E3,d=!0,a.m=Pl(a,{nb:a.F,onError:function(f){Dl(a,f)},Pc:function(f){Ql(a,f)},onExpirationUpdated:function(f,g){Rl(a,f,g)},onEvent:function(f){a.dispatchEvent(f);f.type==Sl&&d&&(d=!1,a.s.j=Date.now()/1E3-c)}}),a.m.configure(a.h.drm),u(e,Wf(a.m,a.i.variants,a.i.offlineSessionIds),2)):3!=e.g?u(e,a.m.Wb(b.J),3):u(e,Ll(a,a.i),0)})}
392
- function nl(a,b,c){var d,e,f,g,h,k,l,m,n,p,q,v;return L(function(y){switch(y.g){case 1:b.startTime=c.startTime;null!=a.ac&&(b.startTime=a.ac,a.ac=null);d=b.J;e=b.uri;a.Ub=e;a.G=new hj({Jc:function(){return d.playbackRate},Fc:function(){return d.defaultPlaybackRate},Xd:function(w){d.playbackRate=w},te:function(w){d.currentTime+=w}});f=function(){return Tl(a)};g=function(){return Ul(a)};a.o.A(d,"playing",f);a.o.A(d,"pause",f);a.o.A(d,"ended",f);a.o.A(d,"ratechange",g);h=a.h.abrFactory;a.u&&a.ud==h||
393
- (a.ud=h,a.u=Sb(h),"function"!=typeof a.u.playbackRateChanged&&(Kb("AbrManager","Please use an AbrManager with playbackRateChanged function."),a.u.playbackRateChanged=function(){}),a.u.configure(a.h.abr));a.Ma=new ue(a.h.preferredAudioLanguage,a.h.preferredVariantRole,a.h.preferredAudioChannelCount);a.wb=a.h.preferredTextLanguage;a.Yb=a.h.preferredTextRole;a.Xb=a.h.preferForcedSubs;Vl(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd);a.u.init(function(w,x,D){a.j&&w!=a.j.l&&Wl(a,w,!0,void 0===
394
- x?!1:x,void 0===D?0:D)});a.C=Xl(a,b.startTime);a.yb=Yl(a);k=Math.max(a.i.minBufferTime,a.h.streaming.rebufferingGoal);Zl(a,k);Bd(a.i,a.h.preferredVideoCodecs,a.h.preferredAudioCodecs,a.h.preferredAudioChannelCount,a.h.preferredDecodingAttributes);a.j=$l(a);a.j.configure(a.h.streaming);a.l=am;d.textTracks&&a.o.A(d.textTracks,"addtrack",function(w){if(w.track)switch(w=w.track,w.kind){case "chapters":bm(a,w)}});a.dispatchEvent(rl(cm));l=null;if(m=a.jb().find(function(w){return w.active})){y.B(2);break}l=
395
- dm(a)?a.u.chooseVariant():null;Wl(a,l,!0,!1,0);if(!a.h.streaming.startAtSegmentBoundary){y.B(3);break}n=a.C.xc();return u(y,em(l,n),4);case 4:p=y.h,a.C.od(p);case 3:fm(a,null,$d(l));case 2:return a.C.nd(),q=a.ib().find(function(w){return w.active}),q||((v=je(a.i.textStreams,a.wb,a.Yb,a.Xb)[0]||null)&&bl(a.s.h,v,!0),l&&(v?(l.audio&&gm(a,l.audio,v)&&(a.ka=!0),a.ka&&a.N.l.setTextVisibility(!0),hm(a)):a.ka=!1),v&&(a.h.streaming.alwaysStreamText||a.td())&&Ij(a.j,v)),u(y,a.j.start(),5);case 5:a.h.abr.enabled&&
396
- (a.u.enable(),im(a)),Rd(a.j?a.j.l:null,a.i),jm(a.i),km(a),dm(a),a.i.variants.some(function(w){return w.primary}),a.o.oa(d,"loadedmetadata",function(){a.s.m=Date.now()/1E3-c.Zd}),A(y)}})}
392
+ function nl(a,b,c){var d,e,f,g,h,k,l,m,n,p,q,v;return L(function(w){switch(w.g){case 1:b.startTime=c.startTime;null!=a.ac&&(b.startTime=a.ac,a.ac=null);d=b.J;e=b.uri;a.Ub=e;a.G=new hj({Jc:function(){return d.playbackRate},Fc:function(){return d.defaultPlaybackRate},Yd:function(x){d.playbackRate=x},te:function(x){d.currentTime+=x}});f=function(){return Tl(a)};g=function(){return Ul(a)};a.o.A(d,"playing",f);a.o.A(d,"pause",f);a.o.A(d,"ended",f);a.o.A(d,"ratechange",g);h=a.h.abrFactory;a.u&&a.vd==h||
393
+ (a.vd=h,a.u=Sb(h),"function"!=typeof a.u.playbackRateChanged&&(Kb("AbrManager","Please use an AbrManager with playbackRateChanged function."),a.u.playbackRateChanged=function(){}),a.u.configure(a.h.abr));a.Ma=new ue(a.h.preferredAudioLanguage,a.h.preferredVariantRole,a.h.preferredAudioChannelCount);a.wb=a.h.preferredTextLanguage;a.Yb=a.h.preferredTextRole;a.Xb=a.h.preferForcedSubs;Vl(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd);a.u.init(function(x,y,D){a.j&&x!=a.j.l&&Wl(a,x,!0,void 0===
394
+ y?!1:y,void 0===D?0:D)});a.C=Xl(a,b.startTime);a.yb=Yl(a);k=Math.max(a.i.minBufferTime,a.h.streaming.rebufferingGoal);Zl(a,k);Bd(a.i,a.h.preferredVideoCodecs,a.h.preferredAudioCodecs,a.h.preferredAudioChannelCount,a.h.preferredDecodingAttributes);a.j=$l(a);a.j.configure(a.h.streaming);a.l=am;d.textTracks&&a.o.A(d.textTracks,"addtrack",function(x){if(x.track)switch(x=x.track,x.kind){case "chapters":bm(a,x)}});a.dispatchEvent(rl(cm));l=null;if(m=a.jb().find(function(x){return x.active})){w.B(2);break}l=
395
+ dm(a)?a.u.chooseVariant():null;Wl(a,l,!0,!1,0);if(!a.h.streaming.startAtSegmentBoundary){w.B(3);break}n=a.C.xc();return u(w,em(l,n),4);case 4:p=w.h,a.C.od(p);case 3:fm(a,null,$d(l));case 2:return a.C.nd(),q=a.ib().find(function(x){return x.active}),q||((v=je(a.i.textStreams,a.wb,a.Yb,a.Xb)[0]||null)&&bl(a.s.h,v,!0),l&&(v?(l.audio&&gm(a,l.audio,v)&&(a.ka=!0),a.ka&&a.N.l.setTextVisibility(!0),hm(a)):a.ka=!1),v&&(a.h.streaming.alwaysStreamText||a.ud())&&Ij(a.j,v)),u(w,a.j.start(),5);case 5:a.h.abr.enabled&&
396
+ (a.u.enable(),im(a)),Rd(a.j?a.j.l:null,a.i),jm(a.i),km(a),dm(a),a.i.variants.some(function(x){return x.primary}),a.o.oa(d,"loadedmetadata",function(){a.s.m=Date.now()/1E3-c.$d}),A(w)}})}
397
397
  function ol(a,b,c){var d,e,f,g,h,k,l;return L(function(m){return 1==m.g?(d=qc,e=Date.now()/1E3,f=!0,a.m=Pl(a,{nb:a.F,onError:function(n){Dl(a,n)},Pc:function(n){Ql(a,n)},onExpirationUpdated:function(n,p){Rl(a,n,p)},onEvent:function(n){a.dispatchEvent(n);n.type==Sl&&f&&(f=!1,a.s.j=Date.now()/1E3-e)}}),a.m.configure(a.h.drm),g=c.uri||"",h=Cg(g),k=Bl[h],"application/x-mpegurl"==k&&Cc()&&(k="application/vnd.apple.mpegurl"),k||(k="video/mp4"),l={id:0,language:"und",primary:!1,audio:null,video:{id:0,originalId:null,
398
398
  createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:c.mimeType?c.mimeType.split(";")[0]:k,codecs:c.mimeType?ed(c.mimeType):"",encrypted:!0,drmInfos:[],keyIds:new Set,language:"und",label:null,type:d.Na,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null},bandwidth:100,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},a.m.W=!0,u(m,Wf(a.m,[l],[]),2)):u(m,a.m.Wb(b.J),
399
399
  0)})}
400
- function pl(a,b,c){function d(){return Tl(a)}b.uri=c.uri;b.startTime=c.startTime;a.Ub=b.uri;var e=b.J;a.C=new Yi(e);var f=!1;a.Vb.push(function(){f=!0});null!=b.startTime&&a.C.od(b.startTime);a.G=new hj({Jc:function(){return e.playbackRate},Fc:function(){return e.defaultPlaybackRate},Xd:function(k){e.playbackRate=k},te:function(k){e.currentTime+=k}});Zl(a,a.h.streaming.rebufferingGoal);a.o.A(e,"playing",d);a.o.A(e,"pause",d);a.o.A(e,"ended",d);a.o.A(e,"ratechange",function(){return Ul(a)});"none"!=e.preload&&
401
- a.o.oa(e,"loadedmetadata",function(){a.s.m=Date.now()/1E3-c.Zd});e.audioTracks&&(a.o.A(e.audioTracks,"addtrack",function(){return km(a)}),a.o.A(e.audioTracks,"removetrack",function(){return km(a)}),a.o.A(e.audioTracks,"change",function(){return km(a)}));e.textTracks&&(a.o.A(e.textTracks,"addtrack",function(k){if(k.track)switch(k=k.track,k.kind){case "metadata":lm(a,k);break;case "chapters":bm(a,k);break;default:km(a)}}),a.o.A(e.textTracks,"removetrack",function(){return km(a)}),a.o.A(e.textTracks,
400
+ function pl(a,b,c){function d(){return Tl(a)}b.uri=c.uri;b.startTime=c.startTime;a.Ub=b.uri;var e=b.J;a.C=new Yi(e);var f=!1;a.Vb.push(function(){f=!0});null!=b.startTime&&a.C.od(b.startTime);a.G=new hj({Jc:function(){return e.playbackRate},Fc:function(){return e.defaultPlaybackRate},Yd:function(k){e.playbackRate=k},te:function(k){e.currentTime+=k}});Zl(a,a.h.streaming.rebufferingGoal);a.o.A(e,"playing",d);a.o.A(e,"pause",d);a.o.A(e,"ended",d);a.o.A(e,"ratechange",function(){return Ul(a)});"none"!=e.preload&&
401
+ a.o.oa(e,"loadedmetadata",function(){a.s.m=Date.now()/1E3-c.$d});e.audioTracks&&(a.o.A(e.audioTracks,"addtrack",function(){return km(a)}),a.o.A(e.audioTracks,"removetrack",function(){return km(a)}),a.o.A(e.audioTracks,"change",function(){return km(a)}));e.textTracks&&(a.o.A(e.textTracks,"addtrack",function(k){if(k.track)switch(k=k.track,k.kind){case "metadata":lm(a,k);break;case "chapters":bm(a,k);break;default:km(a)}}),a.o.A(e.textTracks,"removetrack",function(){return km(a)}),a.o.A(e.textTracks,
402
402
  "change",function(){return km(a)}));var g=Cg(b.uri);e.src=Gk(a.W,b.uri,Bl[g]);(zc()||Ac())&&e.load();a.l=mm;a.dispatchEvent(rl(cm));var h=new rc;Pi(e,HTMLMediaElement.HAVE_METADATA,a.o,function(){a.C.nd();h.resolve()});Pi(e,HTMLMediaElement.HAVE_CURRENT_DATA,a.o,function(){var k;return L(function(l){if(1==l.g)return nm(a),k=om(a),k.find(function(m){return"disabled"!=m.mode})?l.B(2):u(l,new Promise(function(m){a.o.oa(e.textTracks,"change",m);(new O(m)).S(1)}),2);if(f)return l["return"]();pm(a);A(l)})});
403
403
  e.error?h.reject(Cl(a)):"none"==e.preload&&(Ua('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.'),h.resolve());a.o.oa(e,"error",function(){h.reject(Cl(a))});return new Fe(h,function(){h.reject(new N(2,7,7001));return Promise.resolve()})}
404
- function nm(a){var b=a.h.preferredAudioLanguage;if(""!=b){a.Sd(b);var c=a.h.preferredVariantRole;""!=c&&a.Sd(b,c)}}function pm(a){var b=a.h.preferredTextLanguage,c=a.h.preferForcedSubs;if(""!=b){a.Td(b,"",c);var d=a.h.preferredTextRole;""!=d&&a.Td(b,d,c)}}
404
+ function nm(a){var b=a.h.preferredAudioLanguage;if(""!=b){a.Td(b);var c=a.h.preferredVariantRole;""!=c&&a.Td(b,c)}}function pm(a){var b=a.h.preferredTextLanguage,c=a.h.preferForcedSubs;if(""!=b){a.Ud(b,"",c);var d=a.h.preferredTextRole;""!=d&&a.Ud(b,d,c)}}
405
405
  function lm(a,b){if("metadata"==b.kind){b.mode="hidden";a.o.A(b,"cuechange",function(){if(b.activeCues)for(var d=t(b.activeCues),e=d.next();!e.done;e=d.next())if(e=e.value,Hl(a,e.startTime,e.endTime,e.type,e.value),a.D)a.D.onCueMetadataChange(e.value)});var c=(new O(function(){var d=qm(a);d=t(d);for(var e=d.next();!e.done;e=d.next())e.value.mode="hidden"})).Nb().S(.5);a.Vb.push(function(){c.stop()})}}
406
406
  function Hl(a,b,c,d,e){b=(new Map).set("startTime",b).set("endTime",c).set("metadataType",d).set("payload",e);a.dispatchEvent(rl(rm,b))}function bm(a,b){if(b&&"chapters"==b.kind){b.mode="hidden";var c=(new O(function(){b.mode="hidden"})).Nb().S(.5);a.Vb.push(function(){c.stop()})}}function Ol(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))}function Pl(a,b){return new Pf(b,a.h.drm.updateExpirationTime)}
407
407
  function fl(a){return new Se(function(b,c){a.u&&a.u.segmentDownloaded(b,c)},function(b,c,d){b=(new Map).set("headers",b).set("request",c).set("requestType",d);a.dispatchEvent(rl(sm,b))},function(b,c,d,e){b=(new Map).set("request",b).set("error",c).set("httpResponseCode",d).set("aborted",e);a.dispatchEvent(rl(tm,b))})}
408
408
  function Xl(a,b){return new Zi(a.g,a.i,a.h.streaming,b,function(){a.yb&&kj(a.yb,!0);if(a.j){var c=a.j;if(c.g)for(var d=c.g.Ic(),e=c.h.smallGapLimit,f=t(c.j.keys()),g=f.next();!g.done;g=f.next()){g=g.value;var h=c.j.get(g);h.ba=null;var k=c.g.R;g==pc?(k=k.g,k=null==k.g||null==k.h?!1:d>=k.g&&d<k.h):(k=ti(k,g),k=ei(k,d,e));if(!k&&((null!=ui(c.g.R,g)||h.ta)&&Lj(c,h),h.va&&(h.va.abort(),h.va=null),g===pc))for(g=c.g.R.u.g,g.l=0,g.h=[],g.g=[],h=g.i,h.i=[],h.h=[],h.g=0,Sh(g),g=t(g.j.values()),h=g.next();!h.done;h=
409
409
  g.next())Nh(h.value)}}a.L&&um(a)},function(c){return a.dispatchEvent(c)})}function Yl(a){var b=new qj(a.ya);b.addEventListener("enter",function(d){Il(a,vm,d.region)});b.addEventListener("exit",function(d){Il(a,wm,d.region)});b.addEventListener("skip",function(d){var e=d.region;d.seeking||(Il(a,vm,e),Il(a,wm,e))});var c=new jj(a.g);c.g.add(b);a.xa&&c.g.add(a.xa);return c}function Zl(a,b){a.L=new ye;a.L.g=Ae;Be(a.L,b,Math.min(.5,b/2));Fl(a);a.Dc=(new O(function(){um(a)})).Da(.25)}
410
- function um(a){switch(a.l){case mm:if(a.g.ended)var b=!0;else{var c=di(a.g.buffered);b=null!=c&&c>=a.g.duration-1}break;case am:a:if(a.g.ended||ri(a.N))b=!0;else{if(a.i.presentationTimeline.T()){c=a.i.presentationTimeline.hb();var d=di(a.g.buffered);if(null!=d&&d>=c){b=!0;break a}}b=!1}break;default:b=!1}d=fi(a.g.buffered,a.g.currentTime);c=a.L;var e=b,f=c.h.get(c.g);b=c.g;d=e||d>=f?ze:Ae;c.g=d;b!=d&&Fl(a)}function Gl(a,b,c,d){return new ii(a,b,c,d)}
411
- function zl(a){return new uk({getBandwidthEstimate:function(){return a.u?a.u.getBandwidthEstimate():NaN},Ya:function(){return a.Ya()},getCurrentTime:function(){return a.g?a.g.currentTime:0},jb:function(){return a.jb()},Hc:function(){return a.Hc()},T:function(){return a.T()}},a.h.cmcd)}
412
- function $l(a){return new wj(a.i,{Ic:function(){return a.C.xc()},getBandwidthEstimate:function(){return a.u.getBandwidthEstimate()},modifySegmentRequest:function(b,c){vk(a.W,b,c)},R:a.N,nb:a.F,onError:function(b){return Dl(a,b)},onEvent:function(b){return a.dispatchEvent(b)},Kf:function(){a.I&&a.I.update&&a.I.update()},Ld:function(){a.C&&a.C.ue();um(a)},Jf:function(b,c){var d=c.Dd;d&&a.xa&&nj(a.xa,d,b)}})}
410
+ function um(a){switch(a.l){case mm:if(a.g.ended)var b=!0;else{var c=di(a.g.buffered);b=null!=c&&c>=a.g.duration-1}break;case am:a:if(a.g.ended||ri(a.N))b=!0;else{if(a.i.presentationTimeline.U()){c=a.i.presentationTimeline.hb();var d=di(a.g.buffered);if(null!=d&&d>=c){b=!0;break a}}b=!1}break;default:b=!1}d=fi(a.g.buffered,a.g.currentTime);c=a.L;var e=b,f=c.h.get(c.g);b=c.g;d=e||d>=f?ze:Ae;c.g=d;b!=d&&Fl(a)}function Gl(a,b,c,d){return new ii(a,b,c,d)}
411
+ function zl(a){return new uk({getBandwidthEstimate:function(){return a.u?a.u.getBandwidthEstimate():NaN},Ya:function(){return a.Ya()},getCurrentTime:function(){return a.g?a.g.currentTime:0},jb:function(){return a.jb()},Hc:function(){return a.Hc()},U:function(){return a.U()}},a.h.cmcd)}
412
+ function $l(a){return new wj(a.i,{Ic:function(){return a.C.xc()},getBandwidthEstimate:function(){return a.u.getBandwidthEstimate()},modifySegmentRequest:function(b,c){vk(a.W,b,c)},R:a.N,nb:a.F,onError:function(b){return Dl(a,b)},onEvent:function(b){return a.dispatchEvent(b)},Kf:function(){a.I&&a.I.update&&a.I.update()},Md:function(){a.C&&a.C.ue();um(a)},Jf:function(b,c){var d=c.Ed;d&&a.xa&&nj(a.xa,d,b)}})}
413
413
  r.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=Rk(a,b));a.manifest&&a.manifest.dash&&"defaultPresentationDelay"in a.manifest.dash&&(Kb("manifest.dash.defaultPresentationDelay configuration","Please Use manifest.defaultPresentationDelay instead."),a.manifest.defaultPresentationDelay=a.manifest.dash.defaultPresentationDelay,delete a.manifest.dash.defaultPresentationDelay);a.streaming&&a.streaming.lowLatencyMode&&(void 0==a.streaming.inaccurateManifestTolerance&&(a.streaming.inaccurateManifestTolerance=
414
414
  0),void 0==a.streaming.rebufferingGoal&&(a.streaming.rebufferingGoal=.01));var c=Wk(this.h,a,el(this));xm(this);return c};
415
- function xm(a){if(a.I){var b=Oe(a.h.manifest);a.g&&"AUDIO"===a.g.nodeName&&(b.disableVideo=!0);a.I.configure(b)}a.m&&a.m.configure(a.h.drm);if(a.j){a.j.configure(a.h.streaming);try{ym(a,a.i)}catch(f){Dl(a,f)}a.u&&dm(a);b=a.j.l;!b||b.allowedByApplication&&b.allowedByKeySystem||zm(a)}a.F&&a.F.Vd(a.h.streaming.forceHTTPS);if(a.N&&(b=a.h.textDisplayFactory,a.wd!=b)){var c=Sb(b),d=a.N,e=d.l;d.l=c;e&&(c.setTextVisibility(e.isTextVisible()),e.destroy());d.g&&(d.g.i=c);a.wd=b;a.j&&(b=a.j,(c=b.j.get(pc))&&
415
+ function xm(a){if(a.I){var b=Oe(a.h.manifest);a.g&&"AUDIO"===a.g.nodeName&&(b.disableVideo=!0);a.I.configure(b)}a.m&&a.m.configure(a.h.drm);if(a.j){a.j.configure(a.h.streaming);try{ym(a,a.i)}catch(f){Dl(a,f)}a.u&&dm(a);b=a.j.l;!b||b.allowedByApplication&&b.allowedByKeySystem||zm(a)}a.F&&a.F.Wd(a.h.streaming.forceHTTPS);if(a.N&&(b=a.h.textDisplayFactory,a.xd!=b)){var c=Sb(b),d=a.N,e=d.l;d.l=c;e&&(c.setTextVisibility(e.isTextVisible()),e.destroy());d.g&&(d.g.i=c);a.xd=b;a.j&&(b=a.j,(c=b.j.get(pc))&&
416
416
  Gj(b,c.stream,!0,0,!0))}a.u&&(a.u.configure(a.h.abr),a.h.abr.enabled?a.u.enable():a.u.disable(),im(a));a.L&&(b=a.h.streaming.rebufferingGoal,a.i&&(b=Math.max(b,a.i.minBufferTime)),Be(a.L,b,Math.min(.5,b/2)));a.i&&Vl(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd)}r.getConfiguration=function(){var a=el(this);Wk(a,this.h,el(this));return a};
417
417
  r.bf=function(){if(this.g){var a=this.g.buffered.length;a=a?this.g.buffered.end(a-1):0;var b=this.getConfiguration().streaming.bufferingGoal;b=Math.min(this.g.currentTime+b,this.mc().end);if(a>=b)return 1;if(!(a<=this.g.currentTime)&&a<b)return(a-this.g.currentTime)/(b-this.g.currentTime)}return 0};r.Uf=function(){for(var a in this.h)delete this.h[a];Wk(this.h,el(this),el(this));xm(this)};r.hf=function(){return this.l};r.mf=function(){return this.g};r.dc=function(){return this.F};r.rd=function(){return this.Ub};
418
- r.le=function(){return this.D?this.D:null};r.T=function(){return this.i?this.i.presentationTimeline.T():this.g&&this.g.src?Infinity==this.g.duration:!1};r.mb=function(){return this.i?this.i.presentationTimeline.mb():!1};r.Cf=function(){if(this.i){var a=this.i.variants;return a.length?!a[0].video:!1}return this.g&&this.g.src?this.g.videoTracks?0==this.g.videoTracks.length:0==this.g.videoHeight:!1};
419
- r.mc=function(){if(this.i){var a=this.i.presentationTimeline;return{start:a.Db(),end:a.Pa()}}return this.g&&this.g.src&&(a=this.g.seekable,a.length)?{start:a.start(0),end:a.end(a.length-1)}:{start:0,end:0}};r.Af=function(){this.T()&&(this.g.currentTime=this.mc().end)};r.keySystem=function(){var a=this.drmInfo();return a?a.keySystem:""};r.drmInfo=function(){return this.m?this.m.g:null};r.cc=function(){return this.m?this.m.cc():Infinity};r.Gc=function(){return this.m?this.m.Gc():{}};
418
+ r.me=function(){return this.D?this.D:null};r.U=function(){return this.i?this.i.presentationTimeline.U():this.g&&this.g.src?Infinity==this.g.duration:!1};r.mb=function(){return this.i?this.i.presentationTimeline.mb():!1};r.Cf=function(){if(this.i){var a=this.i.variants;return a.length?!a[0].video:!1}return this.g&&this.g.src?this.g.videoTracks?0==this.g.videoTracks.length:0==this.g.videoHeight:!1};
419
+ r.mc=function(){if(this.i){var a=this.i.presentationTimeline;return{start:a.Db(),end:a.Qa()}}return this.g&&this.g.src&&(a=this.g.seekable,a.length)?{start:a.start(0),end:a.end(a.length-1)}:{start:0,end:0}};r.Af=function(){this.U()&&(this.g.currentTime=this.mc().end)};r.keySystem=function(){var a=this.drmInfo();return a?a.keySystem:""};r.drmInfo=function(){return this.m?this.m.g:null};r.cc=function(){return this.m?this.m.cc():Infinity};r.Gc=function(){return this.m?this.m.Gc():{}};
420
420
  r.sd=function(){return this.L?this.L.g==Ae:!1};r.Hc=function(){return this.g?this.G?this.G.i:1:0};r.cg=function(a){0==a?Ua("A trick play rate of 0 is unsupported!"):(this.g.paused&&this.g.play(),this.G.set(a),this.l==am&&(this.u.playbackRateChanged(a),Fj(this.j,1<Math.abs(a))))};r.Se=function(){var a=this.G.Fc();this.l==mm&&this.G.set(a);this.l==am&&(this.G.set(a),this.u.playbackRateChanged(a),Fj(this.j,!1))};
421
421
  r.jb=function(){if(this.i){for(var a=this.j?this.j.l:null,b=[],c=0,d=t(this.i.variants),e=d.next();!e.done;e=d.next())if(e=e.value,he(e)){var f=$d(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.g&&this.g.audioTracks?Array.from(this.g.audioTracks).map(function(g){return ge(g)}):[]};
422
422
  r.ib=function(){if(this.i){for(var a=this.j?this.j.o:null,b=[],c=t(this.i.textStreams),d=c.next();!d.done;d=c.next()){d=d.value;var e=ae(d);e.active=d==a;b.push(e)}return b}return this.g&&this.g.src&&this.g.textTracks?om(this).map(function(f){return ee(f)}):[]};r.ff=function(){return this.i?this.i.imageStreams.map(function(a){return be(a)}):[]};
423
- r.wf=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,p,q,v,y,w,x,D,z,B;return L(function(F){if(1==F.g)return c.i?(d=c.i.imageStreams.find(function(G){return G.id==a}))?d.segmentIndex?F.B(3):u(F,d.createSegmentIndex(),3):F["return"](null):F.B(2);if(2!=F.g){e=d.segmentIndex.find(b);if(null==e)return F["return"](null);f=d.segmentIndex.get(e);g=f.tilesLayout||d.tilesLayout;h=/(\d+)x(\d+)/.exec(g);if(!h)return F["return"](null);k=d.width||0;l=d.height||0;m=parseInt(h[1],10);n=parseInt(h[2],10);p=k/m;q=l/n;
424
- v=m*n;y=f.l-f.startTime;w=f.i||y/v;x=f.startTime;z=D=0;1<v&&(B=Math.floor((b-f.startTime)/w),x=f.startTime+B*w,D=B%m*p,z=Math.floor(B/m)*q);return F["return"]({imageHeight:l,imageWidth:k,height:q,positionX:D,positionY:z,startTime:x,duration:w,uris:f.sa(),width:p})}return F["return"](null)})};
423
+ r.wf=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,p,q,v,w,x,y,D,z,B;return L(function(F){if(1==F.g)return c.i?(d=c.i.imageStreams.find(function(G){return G.id==a}))?d.segmentIndex?F.B(3):u(F,d.createSegmentIndex(),3):F["return"](null):F.B(2);if(2!=F.g){e=d.segmentIndex.find(b);if(null==e)return F["return"](null);f=d.segmentIndex.get(e);g=f.tilesLayout||d.tilesLayout;h=/(\d+)x(\d+)/.exec(g);if(!h)return F["return"](null);k=d.width||0;l=d.height||0;m=parseInt(h[1],10);n=parseInt(h[2],10);p=k/m;q=l/n;
424
+ v=m*n;w=f.l-f.startTime;x=f.i||w/v;y=f.startTime;z=D=0;1<v&&(B=Math.floor((b-f.startTime)/x),y=f.startTime+B*x,D=B%m*p,z=Math.floor(B/m)*q);return F["return"]({imageHeight:l,imageWidth:k,height:q,positionX:D,positionY:z,startTime:y,duration:x,uris:f.sa(),width:p})}return F["return"](null)})};
425
425
  r.Be=function(a){if(this.i&&this.j){var b=this.i.textStreams.find(function(d){return d.id==a.id});b&&b!=this.j.o&&(bl(this.s.h,b,!1),Ij(this.j,b),Am(this),this.wb=b.language)}else if(this.g&&this.g.src&&this.g.textTracks){b=om(this);b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,ce(c)==a.id?c.mode=this.ka?"showing":"hidden":c.mode="disabled";Am(this)}};
426
426
  r.Ce=function(a,b,c){b=void 0===b?!1:b;c=void 0===c?0:c;if(this.i&&this.j){this.h.abr.enabled&&Ua("Changing tracks while abr manager is enabled will likely result in the selected track being overriden. Consider disabling abr before calling selectVariantTrack().");var d=this.i.variants.find(function(e){return e.id==a.id});d&&he(d)&&(Wl(this,d,!1,b,c),this.Ma=new te(d),dm(this))}else if(this.g&&this.g.audioTracks)for(b=Array.from(this.g.audioTracks),b=t(b),c=b.next();!c.done;c=b.next())if(c=c.value,
427
427
  ce(c)==a.id){Bm(this,c);break}};r.af=function(){return Cm(this.jb())};r.vf=function(){return Cm(this.ib())};r.$e=function(){return Array.from(Dm(this.jb()))};r.uf=function(){return Array.from(Dm(this.ib()))};
428
- r.Sd=function(a,b){if(this.i&&this.C){this.Ma=new ue(a,b||"",0,"");var c=function(k,l){return k.video||l.video?k.video&&l.video?Math.abs((k.video.height||0)-(l.video.height||0))+Math.abs((k.video.width||0)-(l.video.width||0)):Infinity:0},d=this.j.l,e=this.Ma.create(this.i.variants),f=null;e=t(e.values());for(var g=e.next();!g.done;g=e.next())if(g=g.value,!f||c(f,d)>c(g,d))f=g;f?(c=$d(f),this.Ce(c,!0)):zm(this)}else if(this.g&&this.g.audioTracks){e=Array.from(this.g.audioTracks);c=rd(a);f=d=null;e=
428
+ r.Td=function(a,b){if(this.i&&this.C){this.Ma=new ue(a,b||"",0,"");var c=function(k,l){return k.video||l.video?k.video&&l.video?Math.abs((k.video.height||0)-(l.video.height||0))+Math.abs((k.video.width||0)-(l.video.width||0)):Infinity:0},d=this.j.l,e=this.Ma.create(this.i.variants),f=null;e=t(e.values());for(var g=e.next();!g.done;g=e.next())if(g=g.value,!f||c(f,d)>c(g,d))f=g;f?(c=$d(f),this.Ce(c,!0)):zm(this)}else if(this.g&&this.g.audioTracks){e=Array.from(this.g.audioTracks);c=rd(a);f=d=null;e=
429
429
  t(e);for(g=e.next();!g.done;g=e.next()){g=g.value;var h=ge(g);rd(h.language)==c&&(d=g,b?h.roles.includes(b)&&(f=g):0==h.roles.length&&(f=g))}f?Bm(this,f):d&&Bm(this,d)}};
430
- r.Td=function(a,b,c){c=void 0===c?!1:c;if(this.i&&this.C){if(this.wb=a,this.Yb=b||"",this.Xb=c,(a=je(this.i.textStreams,this.wb,this.Yb,this.Xb)[0]||null)&&a!=this.j.o&&(bl(this.s.h,a,!1),this.h.streaming.alwaysStreamText||this.td()))Ij(this.j,a),Am(this)}else{var d=rd(a);(a=this.ib().find(function(e){return rd(e.language)==d&&(!b||e.roles.includes(b))&&e.forced==c}))&&this.Be(a)}};
431
- r.Vf=function(a){if(this.i&&this.C){for(var b=null,c=t(this.i.variants),d=c.next();!d.done;d=c.next())if(d=d.value,d.audio.label==a){b=d;break}null!=b&&(this.Ma=new ue(b.language,"",0,a),zm(this))}};r.td=function(){var a=this.ka;return this.N?this.N.l.isTextVisible():this.g&&this.g.src&&this.g.textTracks?om(this).some(function(b){return"showing"==b.mode}):a};r.me=function(){return this.g&&this.g.src&&this.g.textTracks?Em(this).map(function(a){return ee(a)}):[]};
430
+ r.Ud=function(a,b,c){c=void 0===c?!1:c;if(this.i&&this.C){if(this.wb=a,this.Yb=b||"",this.Xb=c,(a=je(this.i.textStreams,this.wb,this.Yb,this.Xb)[0]||null)&&a!=this.j.o&&(bl(this.s.h,a,!1),this.h.streaming.alwaysStreamText||this.ud()))Ij(this.j,a),Am(this)}else{var d=rd(a);(a=this.ib().find(function(e){return rd(e.language)==d&&(!b||e.roles.includes(b))&&e.forced==c}))&&this.Be(a)}};
431
+ r.Vf=function(a){if(this.i&&this.C){for(var b=null,c=t(this.i.variants),d=c.next();!d.done;d=c.next())if(d=d.value,d.audio.label==a){b=d;break}null!=b&&(this.Ma=new ue(b.language,"",0,a),zm(this))}};r.ud=function(){var a=this.ka;return this.N?this.N.l.isTextVisible():this.g&&this.g.src&&this.g.textTracks?om(this).some(function(b){return"showing"==b.mode}):a};r.ne=function(){return this.g&&this.g.src&&this.g.textTracks?Em(this).map(function(a){return ee(a)}):[]};
432
432
  r.cf=function(a){var b=rd(a),c=Em(this).filter(function(h){return rd(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};
433
433
  function om(a){return Array.from(a.g.textTracks).filter(function(b){return"metadata"!=b.kind&&"chapters"!=b.kind&&"Shaka Player TextTrack"!=b.label})}function qm(a){return Array.from(a.g.textTracks).filter(function(b){return"metadata"==b.kind})}function Em(a){return Array.from(a.g.textTracks).filter(function(b){return"chapters"==b.kind})}
434
434
  r.ag=function(a){a=!!a;if(this.ka!=a){this.ka=a;if(this.l==am)this.N.l.setTextVisibility(a),this.h.streaming.alwaysStreamText||(a?this.j.o||(a=je(this.i.textStreams,this.wb,this.Yb,this.Xb),0<a.length&&(Ij(this.j,a[0]),Am(this))):Ej(this.j));else if(this.g&&this.g.src&&this.g.textTracks){var b=om(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")}hm(this)}};
435
- r.qf=function(){if(!this.T())return null;var a=this.Ga.l,b=0;if(this.C)b=this.C.xc();else if(a){if(null==a.startTime)return new Date;b=a.startTime}return this.i?new Date(1E3*(this.i.presentationTimeline.l+b)):this.g&&this.g.getStartDate?(a=this.g.getStartDate(),isNaN(a.getTime())?null:new Date(a.getTime()+1E3*b)):null};
436
- r.ne=function(){if(!this.T())return null;if(this.i)return new Date(1E3*this.i.presentationTimeline.l);if(this.g&&this.g.getStartDate){var a=this.g.getStartDate();return isNaN(a.getTime())?null:a}return null};r.Ya=function(){if(this.l==am)return this.N.Ya();var a={total:[],audio:[],video:[],text:[]};this.l==mm&&(a.total=gi(this.g.buffered));return a};
435
+ r.qf=function(){if(!this.U())return null;var a=this.Ga.l,b=0;if(this.C)b=this.C.xc();else if(a){if(null==a.startTime)return new Date;b=a.startTime}return this.i?new Date(1E3*(this.i.presentationTimeline.l+b)):this.g&&this.g.getStartDate?(a=this.g.getStartDate(),isNaN(a.getTime())?null:new Date(a.getTime()+1E3*b)):null};
436
+ r.oe=function(){if(!this.U())return null;if(this.i)return new Date(1E3*this.i.presentationTimeline.l);if(this.g&&this.g.getStartDate){var a=this.g.getStartDate();return isNaN(a.getTime())?null:a}return null};r.Ya=function(){if(this.l==am)return this.N.Ya();var a={total:[],audio:[],video:[],text:[]};this.l==mm&&(a.total=gi(this.g.buffered));return a};
437
437
  r.getStats=function(){if(this.l!=am&&this.l!=mm)return{width:NaN,height:NaN,streamBandwidth:NaN,decodedFrames:NaN,droppedFrames:NaN,corruptedFrames:NaN,estimatedBandwidth:NaN,completionPercent:NaN,loadLatency:NaN,manifestTimeSeconds:NaN,drmTimeSeconds:NaN,playTime:NaN,pauseTime:NaN,bufferingTime:NaN,licenseTime:NaN,liveLatency:NaN,maxSegmentDuration:NaN,switchHistory:[],stateHistory:[]};Tl(this);var a=this.g,b=a.currentTime/a.duration;if(!isNaN(b)){var c=this.s;b=Math.round(100*b);c.i=isNaN(c.i)?
438
- b:Math.max(c.i,b)}if(a.getVideoPlaybackQuality){c=a.getVideoPlaybackQuality();b=this.s;var d=Number(c.totalVideoFrames);b.N=Number(c.droppedVideoFrames);b.L=d;this.s.I=Number(c.corruptedVideoFrames)}this.m?(c=this.m,c=c.G?c.G:NaN):c=NaN;this.s.s=c;if(this.l==am){if(c=this.j.l)this.s.C=(this.G?this.G.i:1)*c.bandwidth;c&&c.video&&(b=this.s,d=c.video.height||NaN,b.o=c.video.width||NaN,b.l=d);this.T()&&(c=this.ne().valueOf()+1E3*this.mc().end,this.s.D=(Date.now()-c)/1E3);this.i&&this.i.presentationTimeline&&
439
- (this.s.G=this.i.presentationTimeline.g);c=this.u.getBandwidthEstimate();this.s.u=c}this.l==mm&&(c=this.s,b=a.videoHeight||NaN,c.o=a.videoWidth||NaN,c.l=b);var e=this.s;a=e.o;c=e.l;b=e.C;d=e.L;var f=e.N,g=e.I,h=e.u,k=e.i,l=e.m,m=e.F,n=e.j,p=Zk(e.g,"playing"),q=Zk(e.g,"paused"),v=Zk(e.g,"buffering"),y=e.s,w=e.D,x=e.G,D=$k(e.g),z=[];e=t(e.h.g);for(var B=e.next();!B.done;B=e.next())B=B.value,z.push({timestamp:B.timestamp,id:B.id,type:B.type,fromAdaptation:B.fromAdaptation,bandwidth:B.bandwidth});return{width:a,
440
- height:c,streamBandwidth:b,decodedFrames:d,droppedFrames:f,corruptedFrames:g,estimatedBandwidth:h,completionPercent:k,loadLatency:l,manifestTimeSeconds:m,drmTimeSeconds:n,playTime:p,pauseTime:q,bufferingTime:v,licenseTime:y,liveLatency:w,maxSegmentDuration:x,stateHistory:D,switchHistory:z}};
438
+ b:Math.max(c.i,b)}if(a.getVideoPlaybackQuality){c=a.getVideoPlaybackQuality();b=this.s;var d=Number(c.totalVideoFrames);b.N=Number(c.droppedVideoFrames);b.L=d;this.s.I=Number(c.corruptedVideoFrames)}this.m?(c=this.m,c=c.G?c.G:NaN):c=NaN;this.s.s=c;if(this.l==am){if(c=this.j.l)this.s.C=(this.G?this.G.i:1)*c.bandwidth;c&&c.video&&(b=this.s,d=c.video.height||NaN,b.o=c.video.width||NaN,b.l=d);this.U()&&(c=this.oe().valueOf()+1E3*this.mc().end,this.s.D=(Date.now()-c)/1E3);this.i&&this.i.presentationTimeline&&
439
+ (this.s.G=this.i.presentationTimeline.g);c=this.u.getBandwidthEstimate();this.s.u=c}this.l==mm&&(c=this.s,b=a.videoHeight||NaN,c.o=a.videoWidth||NaN,c.l=b);var e=this.s;a=e.o;c=e.l;b=e.C;d=e.L;var f=e.N,g=e.I,h=e.u,k=e.i,l=e.m,m=e.F,n=e.j,p=Zk(e.g,"playing"),q=Zk(e.g,"paused"),v=Zk(e.g,"buffering"),w=e.s,x=e.D,y=e.G,D=$k(e.g),z=[];e=t(e.h.g);for(var B=e.next();!B.done;B=e.next())B=B.value,z.push({timestamp:B.timestamp,id:B.id,type:B.type,fromAdaptation:B.fromAdaptation,bandwidth:B.bandwidth});return{width:a,
440
+ height:c,streamBandwidth:b,decodedFrames:d,droppedFrames:f,corruptedFrames:g,estimatedBandwidth:h,completionPercent:k,loadLatency:l,manifestTimeSeconds:m,drmTimeSeconds:n,playTime:p,pauseTime:q,bufferingTime:v,licenseTime:w,liveLatency:x,maxSegmentDuration:y,stateHistory:D,switchHistory:z}};
441
441
  r.addTextTrack=function(a,b,c,d,e,f,g){g=void 0===g?!1:g;Kb("addTextTrack","Please use an addTextTrackAsync.");if(this.l!=am&&this.l!=mm)throw new N(1,7,7004);if(!d){var h=Cg(a);d=Fm[h];if(!d)throw new N(1,2,2011,h);}if(this.l==mm){if("text/vtt"!=d)throw new N(1,2,2013,d);g&&(c="forced");d=document.createElement("track");d.src=Lk(this.W,a);d.label=f||"";d.kind=c;d.srclang=b;this.g.getAttribute("crossorigin")||this.g.setAttribute("crossorigin","anonymous");this.g.appendChild(d);if(a=this.ib().find(function(k){return k.language==
442
- b&&k.label==(f||"")&&k.kind==c}))return km(this),a;throw new N(1,2,2012);}h=this.i.presentationTimeline.getDuration();if(Infinity==h)throw new N(1,4,4033);a={id:this.Jd++,originalId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:fj(0,h,[a]),mimeType:d||"",codecs:e||"",kind:c,encrypted:!1,drmInfos:[],keyIds:new Set,language:b,label:f||null,type:pc,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!!g,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,
442
+ b&&k.label==(f||"")&&k.kind==c}))return km(this),a;throw new N(1,2,2012);}h=this.i.presentationTimeline.getDuration();if(Infinity==h)throw new N(1,4,4033);a={id:this.Kd++,originalId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:fj(0,h,[a]),mimeType:d||"",codecs:e||"",kind:c,encrypted:!1,drmInfos:[],keyIds:new Set,language:b,label:f||null,type:pc,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!!g,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,
443
443
  closedCaptions:null};if(!gd(ad(a.mimeType,a.codecs)))throw new N(2,2,2014,d);this.i.textStreams.push(a);km(this);return ae(a)};
444
- r.Oe=function(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h=this,k,l,m,n,p,q,v,y,w,x,D;return L(function(z){switch(z.g){case 1:if(h.l!=am&&h.l!=mm)throw new N(1,7,7004);if(d){z.B(2);break}return u(z,Gm(h,a),3);case 3:d=z.h;case 2:k=[];if(h.D)try{k=h.D.getServerSideCuePoints()}catch(B){}if(h.l!=mm){z.B(4);break}g&&(c="forced");return u(z,Hm(h,a,b,c,d,f||"",k),5);case 5:l=h.ib();if(m=l.find(function(B){return B.language==b&&B.label==(f||"")&&B.kind==c}))return km(h),z["return"](m);throw new N(1,2,2012);case 4:n=
445
- qc;p=h.i.presentationTimeline.getDuration();if(Infinity==p)throw new N(1,4,4033);if(!k.length){z.B(6);break}return u(z,Im(h,a,h.F,h.h.streaming.retryParameters),7);case 7:q=z.h,v=Jm(h,q,d,k),y=new Blob([v],{type:"text/vtt"}),a=oi(y),d="text/vtt";case 6:w={id:h.Jd++,originalId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:fj(0,p,[a]),mimeType:d||"",codecs:e||"",kind:c,encrypted:!1,drmInfos:[],keyIds:new Set,language:b,label:f||null,type:n.Z,primary:!1,trickModeVideo:null,
446
- emsgSchemeIdUris:null,roles:[],forced:!!g,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null};x=ad(w.mimeType,w.codecs);D=gd(x);if(!D)throw new N(2,2,2014,d);h.i.textStreams.push(w);km(h);return z["return"](ae(w))}})};
447
- r.Ne=function(a,b,c){var d=this,e,f,g,h;return L(function(k){switch(k.g){case 1:if(d.l!=am&&d.l!=mm)throw new N(1,7,7004);if(c){k.B(2);break}return u(k,Gm(d,a),3);case 3:c=k.h;case 2:e=[];if(d.D)try{e=d.D.getServerSideCuePoints()}catch(l){}return u(k,Hm(d,a,b,"chapters",c,"",e),4);case 4:f=k.h;g=d.me();h=g.find(function(l){return l.language==b});if(!h){k.B(5);break}return u(k,new Promise(function(l,m){d.o.oa(f,"load",l);d.o.oa(f,"error",function(){m(new N(1,2,2015))})}),6);case 6:return k["return"](h);
444
+ r.Oe=function(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h=this,k,l,m,n,p,q,v,w,x,y,D;return L(function(z){switch(z.g){case 1:if(h.l!=am&&h.l!=mm)throw new N(1,7,7004);if(d){z.B(2);break}return u(z,Gm(h,a),3);case 3:d=z.h;case 2:k=[];if(h.D)try{k=h.D.getServerSideCuePoints()}catch(B){}if(h.l!=mm){z.B(4);break}g&&(c="forced");return u(z,Hm(h,a,b,c,d,f||"",k),5);case 5:l=h.ib();if(m=l.find(function(B){return B.language==b&&B.label==(f||"")&&B.kind==c}))return km(h),z["return"](m);throw new N(1,2,2012);case 4:n=
445
+ qc;p=h.i.presentationTimeline.getDuration();if(Infinity==p)throw new N(1,4,4033);if(!k.length){z.B(6);break}return u(z,Im(h,a,h.F,h.h.streaming.retryParameters),7);case 7:q=z.h,v=Jm(h,q,d,k),w=new Blob([v],{type:"text/vtt"}),a=oi(w),d="text/vtt";case 6:x={id:h.Kd++,originalId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:fj(0,p,[a]),mimeType:d||"",codecs:e||"",kind:c,encrypted:!1,drmInfos:[],keyIds:new Set,language:b,label:f||null,type:n.Z,primary:!1,trickModeVideo:null,
446
+ emsgSchemeIdUris:null,roles:[],forced:!!g,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null};y=ad(x.mimeType,x.codecs);D=gd(y);if(!D)throw new N(2,2,2014,d);h.i.textStreams.push(x);km(h);return z["return"](ae(x))}})};
447
+ r.Ne=function(a,b,c){var d=this,e,f,g,h;return L(function(k){switch(k.g){case 1:if(d.l!=am&&d.l!=mm)throw new N(1,7,7004);if(c){k.B(2);break}return u(k,Gm(d,a),3);case 3:c=k.h;case 2:e=[];if(d.D)try{e=d.D.getServerSideCuePoints()}catch(l){}return u(k,Hm(d,a,b,"chapters",c,"",e),4);case 4:f=k.h;g=d.ne();h=g.find(function(l){return l.language==b});if(!h){k.B(5);break}return u(k,new Promise(function(l,m){d.o.oa(f,"load",l);d.o.oa(f,"error",function(){m(new N(1,2,2015))})}),6);case 6:return k["return"](h);
448
448
  case 5:throw new N(1,2,2012);}})};function Gm(a,b){var c,d;return L(function(e){switch(e.g){case 1:c=Cg(b);if(d=Fm[c])return e["return"](d);C(e,2);return u(e,Eg(b,a.F,a.h.streaming.retryParameters),4);case 4:d=e.h;va(e,3);break;case 2:E(e);case 3:if(d)return e["return"](d);throw new N(1,2,2011,c);}})}
449
449
  function Hm(a,b,c,d,e,f,g){var h,k,l,m;return L(function(n){if(1==n.g)return"text/vtt"!=e||g.length?u(n,Im(a,b,a.F,a.h.streaming.retryParameters),3):n.B(2);2!=n.g&&(h=n.h,k=Jm(a,h,e,g),l=new Blob([k],{type:"text/vtt"}),b=oi(l),e="text/vtt");m=document.createElement("track");m.src=Lk(a.W,b);m.label=f;m.kind=d;m.srclang=c;a.g.getAttribute("crossorigin")||a.g.setAttribute("crossorigin","anonymous");a.g.appendChild(m);return n["return"](m)})}
450
450
  function Im(a,b,c,d){var e,f,g;return L(function(h){if(1==h.g){e=bf;f=We([b],d);f.method="GET";var k=a.W;try{k.g.enabled&&Fk(k,f,{ot:Mk,su:!0})}catch(l){Va("CMCD_TEXT_ERROR","Could not generate text CMCD data.",l)}return u(h,c.request(e,f).promise,2)}g=h.h;return h["return"](g.data)})}function Jm(a,b,c,d){var e=hd[c];if(e)return c=e(),a={periodStart:0,segmentStart:0,segmentEnd:a.g.duration},b=Fb(b),b=c.parseMedia(b,a),tk(b,d);throw new N(2,2,2014,c);}
451
- r.Wd=function(a,b){this.Gd.width=a;this.Gd.height=b};r.Qd=function(a){if(this.l==am){var b=this.j;a=void 0===a?.1:a;if(b.i.g)b=!1;else if(b.s)b=!1;else{for(var c=t(b.j.values()),d=c.next();!d.done;d=c.next())d=d.value,!d.hc||d.ta||d.La||(d.hc=!1,Dj(b,d,a));b=!0}}else b=!1;return b};
451
+ r.Xd=function(a,b){this.Hd.width=a;this.Hd.height=b};r.Rd=function(a){if(this.l==am){var b=this.j;a=void 0===a?.1:a;if(b.i.g)b=!1;else if(b.s)b=!1;else{for(var c=t(b.j.values()),d=c.next();!d.done;d=c.next())d=d.value,!d.hc||d.ta||d.La||(d.hc=!1,Dj(b,d,a));b=!0}}else b=!1;return b};
452
452
  r.jf=function(){Ua("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.kf=function(){return this.Lc};
453
- function el(a){var b=Uk();b.streaming.failureCallback=function(c){if(a.T()){var d=null;1001==c.code||1002==c.code?d=1:1003==c.code&&(d=.1);null!=d&&(c.severity=1,a.Qd(d))}};b.textDisplayFactory=function(){return a.Cc?new lk(a.g,a.Cc):new gk(a.g)};return b}r.Ge=function(a){this.Cc=a};
454
- function Ml(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 gj;h={id:a.Jd++,originalId:g,createSegmentIndex:function(){return Promise.resolve()},
453
+ function el(a){var b=Uk();b.streaming.failureCallback=function(c){if(a.U()){var d=null;1001==c.code||1002==c.code?d=1:1003==c.code&&(d=.1);null!=d&&(c.severity=1,a.Rd(d))}};b.textDisplayFactory=function(){return a.Cc?new lk(a.g,a.Cc):new gk(a.g)};return b}r.Ge=function(a){this.Cc=a};
454
+ function Ml(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 gj;h={id:a.Kd++,originalId:g,createSegmentIndex:function(){return Promise.resolve()},
455
455
  segmentIndex:k,mimeType:h,codecs:"",kind:"caption",encrypted:!1,drmInfos:[],keyIds:new Set,language:e.closedCaptions.get(g),label:null,type:pc,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:e.roles,forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null};b.textStreams.push(h);c.add(g)}}function Ll(a,b){return L(function(c){if(1==c.g)return u(c,Km(a,b),2);ym(a,b);A(c)})}
456
456
  function Km(a,b){var c;return L(function(d){if(1==d.g)return c=a.j?a.j.l:null,u(d,Pd(c,b),2);jm(b);A(d)})}
457
- function ym(a,b){if(a.l!=ul){for(var c=a.h.restrictions,d=a.Gd,e=!1,f=t(b.variants),g=f.next();!g.done;g=f.next()){g=g.value;var h=g.allowedByApplication;g.allowedByApplication=Od(g,c,d);h!=g.allowedByApplication&&(e=!0)}e&&a.j&&km(a);if((c=a.m?a.m.g:null)&&a.m.s)for(d=t(b.variants),e=d.next();!e.done;e=d.next())for(e=e.value,e=t((e.video?e.video.drmInfos:[]).concat(e.audio?e.audio.drmInfos:[])),f=e.next();!f.done;f=e.next())if(f=f.value,f.keySystem==c.keySystem)for(f=t(f.initData||[]),g=f.next();!g.done;g=
457
+ function ym(a,b){if(a.l!=ul){for(var c=a.h.restrictions,d=a.Hd,e=!1,f=t(b.variants),g=f.next();!g.done;g=f.next()){g=g.value;var h=g.allowedByApplication;g.allowedByApplication=Od(g,c,d);h!=g.allowedByApplication&&(e=!0)}e&&a.j&&km(a);if((c=a.m?a.m.g:null)&&a.m.s)for(d=t(b.variants),e=d.next();!e.done;e=d.next())for(e=e.value,e=t((e.video?e.video.drmInfos:[]).concat(e.audio?e.audio.drmInfos:[])),f=e.next();!f.done;f=e.next())if(f=f.value,f.keySystem==c.keySystem)for(f=t(f.initData||[]),g=f.next();!g.done;g=
458
458
  f.next())g=g.value,eg(a.m,g.initDataType,g.initData);Lm(a,b)}}
459
459
  function em(a,b){var c,d,e,f,g;return L(function(h){if(1==h.g)return c=a.audio,d=a.video,e=function(k,l){var m,n,p;return L(function(q){if(1==q.g)return k?u(q,k.createSegmentIndex(),2):q["return"](null);n=(m=k.segmentIndex.gb(l))?m.next().value:null;if(!n)return q["return"](null);p=n.startTime;return q["return"](p)})},u(h,e(c,b),2);if(3!=h.g)return f=h.h,u(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)})}
460
460
  function Fl(a){var b=a.sd();if(a.s&&a.L&&a.C){var c=a.G;c.j=b;ij(c);a.W&&(c=a.W,b||c.i||(c.i=!0),c.i&&b&&(c.l=!0),c.m=b);Tl(a)}b=(new Map).set("buffering",b);a.dispatchEvent(rl(Mm,b))}function Ul(a){var b=a.g.playbackRate;0!=b&&(a.G&&a.G.set(b),b=rl(Nm),a.dispatchEvent(b))}function Tl(a){if(a.s&&a.L){var b=a.s.g;a.L.g==Ae?Yk(b,"buffering"):a.g.paused?Yk(b,"paused"):a.g.ended?Yk(b,"ended"):Yk(b,"playing")}}
@@ -464,29 +464,29 @@ function gm(a,b,c){a=rd(a.h.preferredTextLanguage);b=rd(b.language);c=rd(c.langu
464
464
  function Dl(a,b){if(a.l!=ul){var c=rl(Wm,(new Map).set("detail",b));a.dispatchEvent(c);c.defaultPrevented&&(b.handled=!0)}}function Il(a,b,c){c=(new Map).set("detail",{schemeIdUri:c.schemeIdUri,value:c.value,startTime:c.startTime,endTime:c.endTime,id:c.id,eventElement:c.eventElement});a.dispatchEvent(rl(b,c))}
465
465
  function Cl(a){if(!a.g.error)return null;var b=a.g.error.code;if(1==b)return null;var c=a.g.error.msExtendedCode;c&&(0>c&&(c+=Math.pow(2,32)),c=c.toString(16));return new N(2,3,3016,b,c,a.g.error.message)}
466
466
  function Ql(a,b){if(a.j){var c=Object.keys(b),d=1==c.length&&"00"==c[0],e=!1;if(c.length){c=t(a.i.variants);for(var f=c.next();!f.done;f=c.next()){f=f.value;var g=[];f.audio&&g.push(f.audio);f.video&&g.push(f.video);g=t(g);for(var h=g.next();!h.done;h=g.next()){var k=h.value;h=f.allowedByKeySystem;if(k.keyIds.size){f.allowedByKeySystem=!0;k=t(k.keyIds);for(var l=k.next();!l.done;l=k.next())l=l.value,l=b[d?"00":l],f.allowedByKeySystem=f.allowedByKeySystem&&!!l&&!Xm.includes(l)}h!=f.allowedByKeySystem&&
467
- (e=!0)}}}if(!e||dm(a))(d=a.j.l)&&!d.allowedByKeySystem&&zm(a),e&&km(a)}}function Rl(a,b,c){if(a.I&&a.I.onExpirationUpdated)a.I.onExpirationUpdated(b,c);b=rl(Ym);a.dispatchEvent(b)}function Vl(a,b,c){0<b&&(a.T()||a.Fe(b));b=a.getDuration();c<b&&(a.T()||a.Ja(c))}
467
+ (e=!0)}}}if(!e||dm(a))(d=a.j.l)&&!d.allowedByKeySystem&&zm(a),e&&km(a)}}function Rl(a,b,c){if(a.I&&a.I.onExpirationUpdated)a.I.onExpirationUpdated(b,c);b=rl(Ym);a.dispatchEvent(b)}function Vl(a,b,c){0<b&&(a.U()||a.Fe(b));b=a.getDuration();c<b&&(a.U()||a.Ja(c))}
468
468
  function Lm(a,b){var c=a.m?a.m.Gc():{},d=Object.keys(c);d=d.length&&"00"==d[0];for(var e=!1,f=!1,g=new Set,h=new Set,k=t(b.variants),l=k.next();!l.done;l=k.next()){l=l.value;var m=[];l.audio&&m.push(l.audio);l.video&&m.push(l.video);m=t(m);for(var n=m.next();!n.done;n=m.next())if(n=n.value,n.keyIds.size){n=t(n.keyIds);for(var p=n.next();!p.done;p=n.next()){p=p.value;var q=c[d?"00":p];q?Xm.includes(q)&&h.add(q):g.add(p)}}l.allowedByApplication?l.allowedByKeySystem&&(e=!0):f=!0}if(!e)throw c={hasAppRestrictions:f,
469
469
  missingKeys:Array.from(g),restrictedKeyStatuses:Array.from(h)},new N(2,4,4012,c);}function jm(a){if(!a.variants.some(he))throw new N(2,4,4032);}function Qm(a,b){L(function(c){if(1==c.g)return u(c,Promise.resolve(),2);a.l!=ul&&a.dispatchEvent(b);A(c)})}function Dm(a){var b=new Set;a=t(a);for(var c=a.next();!c.done;c=a.next())c=c.value,c.language?b.add(rd(c.language)):b.add("und");return b}
470
470
  function Cm(a){var b=new Map,c=new Map;a=t(a);for(var d=a.next();!d.done;d=a.next()){d=d.value;var e="und",f=[];d.language&&(e=rd(d.language));"variant"==d.type?f=d.audioRoles:f=d.roles;f&&f.length||(f=[""]);b.has(e)||b.set(e,new Set);f=t(f);for(var g=f.next();!g.done;g=f.next())g=g.value,b.get(e).add(g),d.label&&(c.has(e)||c.set(e,new Map),c.get(e).set(g,d.label))}var h=[];b.forEach(function(k,l){for(var m=t(k),n=m.next();!n.done;n=m.next()){n=n.value;var p=null;c.has(l)&&c.get(l).has(n)&&(p=c.get(l).get(n));
471
- h.push({language:l,role:n,label:p})}});return h}function vl(){return new N(2,7,7E3)}function ql(a,b,c,d,e,f){return d==a&&e.J==f.J&&e.uri==f.uri&&e.mimeType==f.mimeType?b:c}function ak(){return{J:null,mimeType:null,startTime:null,Zd:NaN,uri:null}}function wl(a){return new Promise(function(b,c){a.pb=function(){return c(vl())};a.Oc=function(){return b()};a.onError=function(d){return c(d)};a.Qc=function(){return c(vl())}})}M("shaka.Player",U);U.prototype.setVideoContainer=U.prototype.Ge;
472
- U.prototype.getManifestParserFactory=U.prototype.kf;U.prototype.getManifest=U.prototype.jf;U.prototype.retryStreaming=U.prototype.Qd;U.prototype.setMaxHardwareResolution=U.prototype.Wd;U.prototype.addChaptersTrack=U.prototype.Ne;U.prototype.addTextTrackAsync=U.prototype.Oe;U.prototype.addTextTrack=U.prototype.addTextTrack;U.prototype.getStats=U.prototype.getStats;U.prototype.getBufferedInfo=U.prototype.Ya;U.prototype.getPresentationStartTimeAsDate=U.prototype.ne;
473
- U.prototype.getPlayheadTimeAsDate=U.prototype.qf;U.prototype.setTextTrackVisibility=U.prototype.ag;U.prototype.getChapters=U.prototype.cf;U.prototype.getChaptersTracks=U.prototype.me;U.prototype.isTextTrackVisible=U.prototype.td;U.prototype.selectVariantsByLabel=U.prototype.Vf;U.prototype.selectTextLanguage=U.prototype.Td;U.prototype.selectAudioLanguage=U.prototype.Sd;U.prototype.getTextLanguages=U.prototype.uf;U.prototype.getAudioLanguages=U.prototype.$e;U.prototype.getTextLanguagesAndRoles=U.prototype.vf;
471
+ h.push({language:l,role:n,label:p})}});return h}function vl(){return new N(2,7,7E3)}function ql(a,b,c,d,e,f){return d==a&&e.J==f.J&&e.uri==f.uri&&e.mimeType==f.mimeType?b:c}function ak(){return{J:null,mimeType:null,startTime:null,$d:NaN,uri:null}}function wl(a){return new Promise(function(b,c){a.pb=function(){return c(vl())};a.Oc=function(){return b()};a.onError=function(d){return c(d)};a.Qc=function(){return c(vl())}})}M("shaka.Player",U);U.prototype.setVideoContainer=U.prototype.Ge;
472
+ U.prototype.getManifestParserFactory=U.prototype.kf;U.prototype.getManifest=U.prototype.jf;U.prototype.retryStreaming=U.prototype.Rd;U.prototype.setMaxHardwareResolution=U.prototype.Xd;U.prototype.addChaptersTrack=U.prototype.Ne;U.prototype.addTextTrackAsync=U.prototype.Oe;U.prototype.addTextTrack=U.prototype.addTextTrack;U.prototype.getStats=U.prototype.getStats;U.prototype.getBufferedInfo=U.prototype.Ya;U.prototype.getPresentationStartTimeAsDate=U.prototype.oe;
473
+ U.prototype.getPlayheadTimeAsDate=U.prototype.qf;U.prototype.setTextTrackVisibility=U.prototype.ag;U.prototype.getChapters=U.prototype.cf;U.prototype.getChaptersTracks=U.prototype.ne;U.prototype.isTextTrackVisible=U.prototype.ud;U.prototype.selectVariantsByLabel=U.prototype.Vf;U.prototype.selectTextLanguage=U.prototype.Ud;U.prototype.selectAudioLanguage=U.prototype.Td;U.prototype.getTextLanguages=U.prototype.uf;U.prototype.getAudioLanguages=U.prototype.$e;U.prototype.getTextLanguagesAndRoles=U.prototype.vf;
474
474
  U.prototype.getAudioLanguagesAndRoles=U.prototype.af;U.prototype.selectVariantTrack=U.prototype.Ce;U.prototype.selectTextTrack=U.prototype.Be;U.prototype.getThumbnails=U.prototype.wf;U.prototype.getImageTracks=U.prototype.ff;U.prototype.getTextTracks=U.prototype.ib;U.prototype.getVariantTracks=U.prototype.jb;U.prototype.cancelTrickPlay=U.prototype.Se;U.prototype.trickPlay=U.prototype.cg;U.prototype.getPlaybackRate=U.prototype.Hc;U.prototype.isBuffering=U.prototype.sd;U.prototype.getKeyStatuses=U.prototype.Gc;
475
- U.prototype.getExpiration=U.prototype.cc;U.prototype.drmInfo=U.prototype.drmInfo;U.prototype.keySystem=U.prototype.keySystem;U.prototype.goToLive=U.prototype.Af;U.prototype.seekRange=U.prototype.mc;U.prototype.isAudioOnly=U.prototype.Cf;U.prototype.isInProgress=U.prototype.mb;U.prototype.isLive=U.prototype.T;U.prototype.getAdManager=U.prototype.le;U.prototype.getAssetUri=U.prototype.rd;U.prototype.getNetworkingEngine=U.prototype.dc;U.prototype.getMediaElement=U.prototype.mf;
476
- U.prototype.getLoadMode=U.prototype.hf;U.prototype.resetConfiguration=U.prototype.Uf;U.prototype.getBufferFullness=U.prototype.bf;U.prototype.getConfiguration=U.prototype.getConfiguration;U.prototype.configure=U.prototype.configure;U.prototype.load=U.prototype.load;U.prototype.updateStartTime=U.prototype.hg;U.prototype.unload=U.prototype.be;U.prototype.detach=U.prototype.detach;U.prototype.attach=U.prototype.Wb;
475
+ U.prototype.getExpiration=U.prototype.cc;U.prototype.drmInfo=U.prototype.drmInfo;U.prototype.keySystem=U.prototype.keySystem;U.prototype.goToLive=U.prototype.Af;U.prototype.seekRange=U.prototype.mc;U.prototype.isAudioOnly=U.prototype.Cf;U.prototype.isInProgress=U.prototype.mb;U.prototype.isLive=U.prototype.U;U.prototype.getAdManager=U.prototype.me;U.prototype.getAssetUri=U.prototype.rd;U.prototype.getNetworkingEngine=U.prototype.dc;U.prototype.getMediaElement=U.prototype.mf;
476
+ U.prototype.getLoadMode=U.prototype.hf;U.prototype.resetConfiguration=U.prototype.Uf;U.prototype.getBufferFullness=U.prototype.bf;U.prototype.getConfiguration=U.prototype.getConfiguration;U.prototype.configure=U.prototype.configure;U.prototype.load=U.prototype.load;U.prototype.updateStartTime=U.prototype.hg;U.prototype.unload=U.prototype.ce;U.prototype.detach=U.prototype.detach;U.prototype.attach=U.prototype.Wb;
477
477
  U.probeSupport=function(a){a=void 0===a?!0:a;var b,c,d,e,f,g;return L(function(h){if(1==h.g)return b={},a?u(h,ug(),3):h.B(2);2!=h.g&&(b=h.h);var k={};if(uc()){for(var l in Bg)k[l]=!0;for(var m in Dg)k[m]=!0}l={mpd:"application/dash+xml",m3u8:"application/x-mpegurl",ism:"application/vnd.ms-sstr+xml"};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,k[n]=uc()?!!Bg[n]:vc(n);for(var p in l)k[p]=
478
478
  uc()?!!Dg[p]:vc(l[p]);c=k;k={};p=t('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",audio/mp4; codecs="mp4a.40.2",audio/mp4; codecs="ac-3",audio/mp4; codecs="ec-3",audio/mp4; codecs="opus",audio/mp4; codecs="flac",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(","));
479
479
  for(l=p.next();!l.done;l=p.next())l=l.value,k[l]=uc()?gd(l)?!0:MediaSource.isTypeSupported(l)||Xc(l):vc(l),m=l.split(";")[0],k[m]=k[m]||k[l];d=k;e={manifest:c,media:d,drm:b};f=Zm;for(g in f)e[g]=f[g]();return h["return"](e)})};
480
480
  U.isBrowserSupported=function(){window.Promise||Ua("A Promise implementation or polyfill is required");if(!(window.Promise&&window.Uint8Array&&Array.prototype.forEach)||yc("Trident/"))return!1;var a=Fc();return a&&12>a||!(window.MediaKeys&&window.navigator&&window.navigator.requestMediaKeySystemAccess&&window.MediaKeySystemAccess&&window.MediaKeySystemAccess.prototype.getConfiguration)?!1:uc()?!0:vc("application/x-mpegurl")};U.setAdManagerFactory=function(a){gl=a};
481
481
  U.registerSupportPlugin=function(a,b){Zm[a]=b};U.prototype.destroy=U.prototype.destroy;
482
482
  var Vm="abrstatuschanged",Pm="adaptation",Mm="buffering",tm="downloadfailed",sm="downloadheadersreceived",Sl="drmsessionupdate",Xj="emsg",Wm="error",Ym="expirationupdated",Al="loaded",xl="loading",Nl="manifestparsed",Kl="mediaqualitychanged",rm="metadata",sl="onstatechange",tl="onstateidle",Nm="ratechange",cm="streaming",Tm="textchanged",Um="texttrackvisibility",Jl="timelineregionadded",vm="timelineregionenter",wm="timelineregionexit",Rm="trackschanged",El="unloading",Sm="variantchanged",$m={jg:Vm,
483
- kg:Pm,lg:Mm,ng:tm,og:sm,pg:Sl,rg:Xj,Error:Wm,sg:Ym,ug:"largegap",vg:Al,wg:xl,xg:Nl,yg:Kl,Metadata:rm,Ag:sl,Bg:tl,Cg:Nm,Eg:"sessiondata",Fg:cm,Gg:Tm,Hg:Um,Ig:Jl,Jg:vm,Kg:wm,Lg:Rm,Mg:El,Ng:Sm},ul=0,dl=1,am=2,mm=3;U.LoadMode={DESTROYED:ul,NOT_LOADED:dl,MEDIA_SOURCE:am,SRC_EQUALS:mm};U.version="v3.3.16";var an=["3","3"];Lb=new function(a){this.g=a;this.i=Mb;this.h=Nb}(new Jb(Number(an[0]),Number(an[1])));
483
+ kg:Pm,lg:Mm,ng:tm,og:sm,pg:Sl,rg:Xj,Error:Wm,sg:Ym,ug:"largegap",vg:Al,wg:xl,xg:Nl,yg:Kl,Metadata:rm,Ag:sl,Bg:tl,Cg:Nm,Eg:"sessiondata",Fg:cm,Gg:Tm,Hg:Um,Ig:Jl,Jg:vm,Kg:wm,Lg:Rm,Mg:El,Ng:Sm},ul=0,dl=1,am=2,mm=3;U.LoadMode={DESTROYED:ul,NOT_LOADED:dl,MEDIA_SOURCE:am,SRC_EQUALS:mm};U.version="v3.3.17";var an=["3","3"];Lb=new function(a){this.g=a;this.i=Mb;this.h=Nb}(new Jb(Number(an[0]),Number(an[1])));
484
484
  var Xm=["output-restricted","internal-error"],Zm={},gl=null,Bl={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",mp3:"audio/mpeg",aac:"audio/aac",flac:"audio/flac",wav:"audio/wav"},Fm={sbv:"text/x-subviewer",srt:"text/srt",vtt:"text/vtt",webvtt:"text/vtt",ttml:"application/ttml+xml",lrc:"application/x-subtitle-lrc",
485
485
  ssa:"text/x-ssa",ass:"text/x-ssa"};function bn(){this.h=[];this.j=this.i=this.g=0};function V(a,b){var c=this;this.h=a;this.g=b;this.i=!1;this.l=this.g.getVolume();this.j=new ef;this.j.A(this.g,google.ima.AdEvent.Type.PAUSED,function(){c.i=!0});this.j.A(this.g,google.ima.AdEvent.Type.RESUMED,function(){c.i=!1})}r=V.prototype;r.getDuration=function(){return this.h.getDuration()};r.getMinSuggestedDuration=function(){return this.h.getMinSuggestedDuration()};r.getRemainingTime=function(){return this.g.getRemainingTime()};r.isPaused=function(){return this.i};
486
486
  r.isSkippable=function(){return 0<=this.h.getSkipTimeOffset()};r.getTimeUntilSkippable=function(){var a=this.h.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};r.canSkipNow=function(){return this.g.getAdSkippableState()};r.skip=function(){return this.g.skip()};r.pause=function(){return this.g.pause()};r.play=function(){return this.g.resume()};r.getVolume=function(){return this.g.getVolume()};r.setVolume=function(a){return this.g.setVolume(a)};r.isMuted=function(){return 0==this.g.getVolume()};
487
487
  r.isLinear=function(){return this.h.isLinear()};r.resize=function(a,b){this.g.resize(a,b,document.fullscreenElement?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)};r.setMuted=function(a){a?(this.l=this.getVolume(),this.setVolume(0)):this.setVolume(this.l)};r.getSequenceLength=function(){var a=this.h.getAdPodInfo();return null==a?1:a.getTotalAds()};r.getPositionInSequence=function(){var a=this.h.getAdPodInfo();return null==a?1:a.getAdPosition()};r.release=function(){this.g=this.h=null};
488
488
  M("shaka.ads.ClientSideAd",V);V.prototype.release=V.prototype.release;V.prototype.getPositionInSequence=V.prototype.getPositionInSequence;V.prototype.getSequenceLength=V.prototype.getSequenceLength;V.prototype.setMuted=V.prototype.setMuted;V.prototype.resize=V.prototype.resize;V.prototype.isLinear=V.prototype.isLinear;V.prototype.isMuted=V.prototype.isMuted;V.prototype.setVolume=V.prototype.setVolume;V.prototype.getVolume=V.prototype.getVolume;V.prototype.play=V.prototype.play;V.prototype.pause=V.prototype.pause;
489
- V.prototype.skip=V.prototype.skip;V.prototype.canSkipNow=V.prototype.canSkipNow;V.prototype.getTimeUntilSkippable=V.prototype.getTimeUntilSkippable;V.prototype.isSkippable=V.prototype.isSkippable;V.prototype.isPaused=V.prototype.isPaused;V.prototype.getRemainingTime=V.prototype.getRemainingTime;V.prototype.getMinSuggestedDuration=V.prototype.getMinSuggestedDuration;V.prototype.getDuration=V.prototype.getDuration;function cn(a,b,c,d){var e=this;this.o=a;this.i=b;this.s=null;this.u=NaN;this.l=d;this.j=null;this.h=new ef;google.ima.settings.setLocale(c);a=new google.ima.AdDisplayContainer(this.o,this.i);a.initialize();this.m=new google.ima.AdsLoader(a);this.m.getSettings().setPlayerType("shaka-player");this.m.getSettings().setPlayerVersion("v3.3.16");this.g=null;this.h.oa(this.m,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,function(f){dn(e,f)});this.h.A(this.m,google.ima.AdErrorEvent.Type.AD_ERROR,
489
+ V.prototype.skip=V.prototype.skip;V.prototype.canSkipNow=V.prototype.canSkipNow;V.prototype.getTimeUntilSkippable=V.prototype.getTimeUntilSkippable;V.prototype.isSkippable=V.prototype.isSkippable;V.prototype.isPaused=V.prototype.isPaused;V.prototype.getRemainingTime=V.prototype.getRemainingTime;V.prototype.getMinSuggestedDuration=V.prototype.getMinSuggestedDuration;V.prototype.getDuration=V.prototype.getDuration;function cn(a,b,c,d){var e=this;this.o=a;this.i=b;this.s=null;this.u=NaN;this.l=d;this.j=null;this.h=new ef;google.ima.settings.setLocale(c);a=new google.ima.AdDisplayContainer(this.o,this.i);a.initialize();this.m=new google.ima.AdsLoader(a);this.m.getSettings().setPlayerType("shaka-player");this.m.getSettings().setPlayerVersion("v3.3.17");this.g=null;this.h.oa(this.m,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,function(f){dn(e,f)});this.h.A(this.m,google.ima.AdErrorEvent.Type.AD_ERROR,
490
490
  function(f){en(e,f)});this.i.onended=function(){e.m.contentComplete()}}cn.prototype.stop=function(){this.g&&this.g.stop();this.o&&kk(this.o)};cn.prototype.release=function(){this.stop();this.s&&this.s.disconnect();this.h&&this.h.release();this.g&&this.g.destroy();this.m.destroy()};function en(a,b){b.getError();fn(a,null);a.l(new Q("ad-cue-points-changed",(new Map).set("cuepoints",[])))}
491
491
  function dn(a,b){a.l(new Q("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.u)));a.g=b.getAdsManager(a.i);a.l(new Q("ima-ad-manager-loaded",(new Map).set("imaAdManager",a.g)));var c=a.g.getCuePoints();if(c.length){var d=[];c=t(c);for(var e=c.next();!e.done;e=c.next())d.push({start:e.value,end:null});a.l(new Q("ad-cue-points-changed",(new Map).set("cuepoints",d)))}gn(a);try{a.g.init(a.i.offsetWidth,a.i.offsetHeight,document.fullscreenElement?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL),
492
492
  a.h.A(a.i,"loadeddata",function(){a.g.resize(a.i.offsetWidth,a.i.offsetHeight,document.fullscreenElement?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),"ResizeObserver"in window&&(a.s=new ResizeObserver(function(){a.g.resize(a.i.offsetWidth,a.i.offsetHeight,document.fullscreenElement?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),a.s.observe(a.i)),a.i.addEventListener("play",function(){a.g.start()},{once:!0})}catch(f){fn(a,null)}}
@@ -507,8 +507,8 @@ f;e.i(new Q("ad-cue-points-changed",(new Map).set("cuepoints",f)))})}jn.prototyp
507
507
  function kn(a,b){a.i(new Q("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.G)));var c=b.getStreamData().url;a.j.resolve(c);a.j=null;a.F||a.h.A(a.l,"seeked",function(){var d=a.l.currentTime;if(0!=d){a.g.streamTimeForContentTime(d);var e=a.g.previousCuePointForStreamTime(d);e&&!e.played&&(a.o=d,a.l.currentTime=e.start)}})};function X(){Ne.call(this);this.g=this.i=null;this.h=new bn;this.j=navigator.language}qa(X,Ne);r=X.prototype;r.setLocale=function(a){this.j=a};r.initClientSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.AdsLoader)throw new N(2,10,1E4);this.i&&this.i.release();this.i=new cn(a,b,this.j,function(d){if(d&&d.type)switch(d.type){case "ads-loaded":c.h.h.push(d.loadTime);break;case "ad-started":c.h.g++;break;case "ad-complete":c.h.i++;break;case "ad-skipped":c.h.j++}c.dispatchEvent(d)})};
508
508
  r.release=function(){this.i&&(this.i.release(),this.i=null);this.g&&(this.g.release(),this.g=null);Ne.prototype.release.call(this)};r.onAssetUnload=function(){this.i&&this.i.stop();this.g&&this.g.stop();this.dispatchEvent(new Q("ad-stopped"));this.h=new bn};r.requestClientSideAds=function(a){if(!this.i)throw new N(1,10,10001);var b=this.i;b.u=Date.now()/1E3;b.m.requestAds(a)};
509
509
  r.initServerSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.dai)throw new N(2,10,10002);this.g&&this.g.release();this.g=new jn(a,b,this.j,function(d){if(d&&d.type)switch(d.type){case "ads-loaded":c.h.h.push(d.loadTime);break;case "ad-started":c.h.g++;break;case "ad-complete":c.h.i++;break;case "ad-skipped":c.h.j++}c.dispatchEvent(d)})};
510
- r.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new N(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Ua('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="v3.3.16";c=this.g;var d=b;c.j?c=Promise.reject(new N(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
511
- (c.F=!0),c.j=new rc,c.g.requestStream(a),c.C=d||"",c.G=Date.now()/1E3,c=c.j);return c};r.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new N(1,10,10003);(a.mpt||a.mpv)&&Ua('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="v3.3.16";this.g.g.replaceAdTagParameters(a)};r.getServerSideCuePoints=function(){if(!this.g)throw new N(1,10,10003);return this.g.D};
510
+ r.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new N(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Ua('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="v3.3.17";c=this.g;var d=b;c.j?c=Promise.reject(new N(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
511
+ (c.F=!0),c.j=new rc,c.g.requestStream(a),c.C=d||"",c.G=Date.now()/1E3,c=c.j);return c};r.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new N(1,10,10003);(a.mpt||a.mpv)&&Ua('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="v3.3.17";this.g.g.replaceAdTagParameters(a)};r.getServerSideCuePoints=function(){if(!this.g)throw new N(1,10,10003);return this.g.D};
512
512
  r.getStats=function(){var a=this.h;return{loadTimes:a.h,started:a.g,playedCompletely:a.i,skipped:a.j}};r.onDashTimedMetadata=function(a){if(this.g&&"urn:google:dai:2018"==a.schemeIdUri){var b=a.schemeIdUri,c=a.eventElement?a.eventElement.getAttribute("messageData"):null;this.g.g.processMetadata(b,c,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)};M("shaka.ads.AdManager",X);
513
513
  X.prototype.onCueMetadataChange=X.prototype.onCueMetadataChange;X.prototype.onHlsTimedMetadata=X.prototype.onHlsTimedMetadata;X.prototype.onDashTimedMetadata=X.prototype.onDashTimedMetadata;X.prototype.getStats=X.prototype.getStats;X.prototype.getServerSideCuePoints=X.prototype.getServerSideCuePoints;X.prototype.replaceServerSideAdTagParameters=X.prototype.replaceServerSideAdTagParameters;X.prototype.requestServerSideStream=X.prototype.requestServerSideStream;X.prototype.initServerSide=X.prototype.initServerSide;
514
514
  X.prototype.requestClientSideAds=X.prototype.requestClientSideAds;X.prototype.onAssetUnload=X.prototype.onAssetUnload;X.prototype.release=X.prototype.release;X.prototype.initClientSide=X.prototype.initClientSide;X.prototype.setLocale=X.prototype.setLocale;X.ADS_LOADED="ads-loaded";X.AD_STARTED="ad-started";X.AD_FIRST_QUARTILE="ad-first-quartile";X.AD_MIDPOINT="ad-midpoint";X.AD_THIRD_QUARTILE="ad-third-quartile";X.AD_COMPLETE="ad-complete";X.AD_STOPPED="ad-stopped";X.AD_SKIPPED="ad-skipped";
@@ -520,17 +520,17 @@ function nn(a){return{length:a.length,start:function(b){return a.start[b]},end:f
520
520
  var on="ended play playing pause pausing ratechange seeked seeking timeupdate volumechange".split(" "),pn="buffered currentTime duration ended loop muted paused playbackRate seeking videoHeight videoWidth volume".split(" "),qn=["loop","playbackRate"],rn=["pause","play"],sn={getAssetUri:2,getAudioLanguages:4,getAudioLanguagesAndRoles:4,getBufferFullness:1,getBufferedInfo:2,getExpiration:2,getKeyStatuses:2,getPlaybackRate:2,getTextLanguages:4,getTextLanguagesAndRoles:4,getImageTracks:2,getThumbnails:2,
521
521
  isAudioOnly:10,isBuffering:1,isInProgress:1,isLive:10,isTextTrackVisible:1,keySystem:10,seekRange:1,getLoadMode:10},tn={getConfiguration:4,getStats:5,getTextTracks:2,getVariantTracks:2},un={getPlayheadTimeAsDate:1,getPresentationStartTimeAsDate:20},vn=[["getConfiguration","configure"]],wn=[["isTextTrackVisible","setTextTrackVisibility"]],xn="addChaptersTrack addTextTrack addTextTrackAsync cancelTrickPlay configure getChapters getChaptersTracks resetConfiguration retryStreaming selectAudioLanguage selectTextLanguage selectTextTrack selectVariantTrack selectVariantsByLabel setTextTrackVisibility trickPlay updateStartTime goToLive".split(" "),
522
522
  yn=["attach","detach","load","unload"];function zn(a,b,c,d,e,f){var g=this;this.G=a;this.j=new O(b);this.V=c;this.u=!1;this.s=d;this.F=e;this.L=f;this.h=this.m=!1;this.N="";this.o=null;this.C=function(){return An(g)};this.D=function(h,k){var l=mn(k);switch(l.type){case "event":var m=l.targetName;l=Me(l.event);g.s(m,l);break;case "update":m=l.update;for(var n in m){l=g.g[n]||{};for(var p in m[n])l[p]=m[n][p]}g.u&&(g.V(),g.u=!1);break;case "asyncComplete":if(n=l.id,l=l.error,p=g.i[n],delete g.i[n],p)if(l){n=new N(l.severity,l.category,l.code);
523
- for(m in l)n[m]=l[m];p.reject(n)}else p.resolve()}};this.g={video:{},player:{}};this.I=0;this.i={};this.l=null;Bn.add(this)}r=zn.prototype;r.destroy=function(){Bn["delete"](this);Cn(this);Ln&&Mn(this);this.j&&(this.j.stop(),this.j=null);this.F=this.s=null;this.h=this.m=!1;this.D=this.C=this.l=this.i=this.g=this.o=null;return Promise.resolve()};r.ua=function(){return this.h};r.Od=function(){return this.N};
523
+ for(m in l)n[m]=l[m];p.reject(n)}else p.resolve()}};this.g={video:{},player:{}};this.I=0;this.i={};this.l=null;Bn.add(this)}r=zn.prototype;r.destroy=function(){Bn["delete"](this);Cn(this);Ln&&Mn(this);this.j&&(this.j.stop(),this.j=null);this.F=this.s=null;this.h=this.m=!1;this.D=this.C=this.l=this.i=this.g=this.o=null;return Promise.resolve()};r.ua=function(){return this.h};r.Pd=function(){return this.N};
524
524
  r.init=function(){if(this.G.length)if(window.chrome&&chrome.cast&&chrome.cast.isAvailable){this.m=!0;this.j.Nb();var a=new chrome.cast.SessionRequest(this.G);a=new chrome.cast.ApiConfig(a,function(b){for(var c=t(Bn),d=c.next();!d.done;d=c.next())Nn(d.value,b)},function(b){for(var c=t(Bn),d=c.next();!d.done;d=c.next())d=d.value,On="available"==b,d.j.Nb()},"origin_scoped");chrome.cast.initialize(a,function(){},function(){});On&&this.j.S(Pn);(a=Ln)&&a.status!=chrome.cast.SessionStatus.STOPPED?Nn(this,
525
- a):Ln=null}else window.__onGCastApiAvailable!==Qn&&(Rn=window.__onGCastApiAvailable||null,window.__onGCastApiAvailable=Qn)};r.Ud=function(a){this.o=a;this.h&&Sn(this,{type:"appData",appData:this.o})};r.cast=function(a){var b=this;return L(function(c){if(!b.m)throw new N(1,8,8E3);if(!On)throw new N(1,8,8001);if(b.h)throw new N(1,8,8002);b.l=new rc;chrome.cast.requestSession(function(d){return Tn(b,a,d)},function(d){return Un(b,d)});return u(c,b.l,0)})};
525
+ a):Ln=null}else window.__onGCastApiAvailable!==Qn&&(Rn=window.__onGCastApiAvailable||null,window.__onGCastApiAvailable=Qn)};r.Vd=function(a){this.o=a;this.h&&Sn(this,{type:"appData",appData:this.o})};r.cast=function(a){var b=this;return L(function(c){if(!b.m)throw new N(1,8,8E3);if(!On)throw new N(1,8,8001);if(b.h)throw new N(1,8,8002);b.l=new rc;chrome.cast.requestSession(function(d){return Tn(b,a,d)},function(d){return Un(b,d)});return u(c,b.l,0)})};
526
526
  function Vn(a){if(a.h){var b=a.L();chrome.cast.requestSession(function(c){return Tn(a,b,c)},function(c){return Un(a,c)})}}r.Bb=function(){if(this.h){Cn(this);if(Ln){Mn(this);try{Ln.stop(function(){},function(){})}catch(a){}Ln=null}An(this)}};
527
527
  r.get=function(a,b){var c=this;if("video"==a){if(rn.includes(b))return function(){return c.xe.apply(c,[a,b].concat(ja(Ha.apply(0,arguments))))}}else if("player"==a){if(un[b]&&!this.get("player","isLive")())return function(){};if(xn.includes(b))return function(){return c.xe.apply(c,[a,b].concat(ja(Ha.apply(0,arguments))))};if(yn.includes(b))return function(){return c.Rf.apply(c,[a,b].concat(ja(Ha.apply(0,arguments))))};if(sn[b]||tn[b])return function(){return c.g[a][b]}}return this.g[a][b]};
528
528
  r.set=function(a,b,c){this.g[a][b]=c;Sn(this,{type:"set",targetName:a,property:b,value:c})};function Tn(a,b,c){Ln=c;c.addUpdateListener(a.C);c.addMessageListener("urn:x-cast:com.google.shaka.v2",a.D);An(a);Sn(a,{type:"init",initState:b,appData:a.o});a.l.resolve()}function Un(a,b){var c=8003;switch(b.code){case "cancel":c=8004;break;case "timeout":c=8005;break;case "receiver_unavailable":c=8006}a.l.reject(new N(2,8,c,b))}
529
529
  r.xe=function(a,b){Sn(this,{type:"call",targetName:a,methodName:b,args:Ha.apply(2,arguments)})};r.Rf=function(a,b){var c=Ha.apply(2,arguments),d=new rc,e=this.I.toString();this.I++;this.i[e]=d;try{Sn(this,{type:"asyncCall",targetName:a,methodName:b,args:c,id:e})}catch(f){d.reject(f)}return d};function Nn(a,b){var c=a.L();a.l=new rc;a.u=!0;Tn(a,c,b)}function Mn(a){var b=Ln;b.removeUpdateListener(a.C);b.removeMessageListener("urn:x-cast:com.google.shaka.v2",a.D)}
530
530
  function An(a){var b=Ln?"connected"==Ln.status:!1;if(a.h&&!b){a.F();for(var c in a.g)a.g[c]={};Cn(a)}a.h=b;a.N=b?Ln.receiver.friendlyName:"";a.j.Nb()}function Cn(a){for(var b in a.i){var c=a.i[b];delete a.i[b];c.reject(new N(1,7,7E3))}}function Sn(a,b){var c=ln(b),d=Ln;try{d.sendMessage("urn:x-cast:com.google.shaka.v2",c,function(){},Xa)}catch(e){throw c=new N(2,8,8005,e),d=new Q("error",(new Map).set("detail",c)),a.s("player",d),a.Bb(),c;}}var Pn=.02,On=!1,Ln=null,Rn=null,Bn=new Set;
531
531
  function Qn(a){Rn?window.__onGCastApiAvailable=Rn:delete window.__onGCastApiAvailable;Rn=null;if(a)for(var b=t(Bn),c=b.next();!c.done;c=b.next())c.value.init();"function"===typeof window.__onGCastApiAvailable&&window.__onGCastApiAvailable(a)};function Wn(a,b,c){Ne.call(this);var d=this;this.i=a;this.h=b;this.m=this.o=this.j=this.s=this.l=null;this.C=c;this.u=new Map;this.g=new zn(c,function(){return Xn(d)},function(){return Yn(d)},function(e,f){return Zn(d,e,f)},function(){return $n(d)},function(){return ao(d)});bo(this)}qa(Wn,Ne);r=Wn.prototype;
532
- r.destroy=function(a){a&&this.g.Bb();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;Ne.prototype.release.call(this);return Promise.all(a)};r.zf=function(){return this.l};r.pf=function(){return this.s};r.Qe=function(){return this.g.m&&On};r.ua=function(){return this.g.ua()};r.Od=function(){return this.g.Od()};
533
- r.cast=function(){var a=this,b;return L(function(c){return 1==c.g?(b=ao(a),u(c,a.g.cast(b),2)):a.h?u(c,a.h.be(),0):c["return"]()})};r.Ud=function(a){this.g.Ud(a)};r.bg=function(){Vn(this.g)};r.Bb=function(){this.g.Bb()};
532
+ r.destroy=function(a){a&&this.g.Bb();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;Ne.prototype.release.call(this);return Promise.all(a)};r.zf=function(){return this.l};r.pf=function(){return this.s};r.Qe=function(){return this.g.m&&On};r.ua=function(){return this.g.ua()};r.Pd=function(){return this.g.Pd()};
533
+ r.cast=function(){var a=this,b;return L(function(c){return 1==c.g?(b=ao(a),u(c,a.g.cast(b),2)):a.h?u(c,a.h.ce(),0):c["return"]()})};r.Vd=function(a){this.g.Vd(a)};r.bg=function(){Vn(this.g)};r.Bb=function(){this.g.Bb()};
534
534
  r.Te=function(a){var b=this;return L(function(c){if(1==c.g){if(a==b.C)return c["return"]();b.C=a;b.g.Bb();return u(c,b.g.destroy(),2)}b.g=null;b.g=new zn(a,function(){return Xn(b)},function(){return Yn(b)},function(d,e){return Zn(b,d,e)},function(){return $n(b)},function(){return ao(b)});b.g.init();A(c)})};
535
535
  function bo(a){a.g.init();a.m=new ef;for(var b=t(on),c=b.next();!c.done;c=b.next())a.m.A(a.i,c.value,function(f){a.g.ua()||(f=Me(f),a.j.dispatchEvent(f))});for(var d in $m)a.m.A(a.h,$m[d],function(f){a.g.ua()||a.o.dispatchEvent(f)});a.l={};b={};for(var e in a.i)b.Pb=e,Object.defineProperty(a.l,b.Pb,{configurable:!1,enumerable:!0,get:function(f){return function(){return co(a,f.Pb)}}(b),set:function(f){return function(g){var h=f.Pb;a.g.ua()?a.g.set("video",h,g):a.i[h]=g}}(b)}),b={Pb:b.Pb};a.s={};eo(a,
536
536
  function(f){Object.defineProperty(a.s,f,{configurable:!1,enumerable:!0,get:function(){return fo(a,f)}})});go(a);a.j=new Ne;a.j.Ec=a.l;a.o=new Ne;a.o.Ec=a.s}function go(a){var b=new Map;eo(a,function(c,d){if(b.has(d)){var e=b.get(d);c.length<e.length?a.u.set(c,e):a.u.set(e,c)}else b.set(d,c)})}
@@ -540,28 +540,28 @@ function Yn(a){var b=new Q(a.l.paused?"pause":"play");a.j.dispatchEvent(b)}
540
540
  function $n(a){for(var b=t(vn),c=b.next();!c.done;c=b.next()){var d=c.value;c=d[1];d=a.g.get("player",d[0])();a.h[c](d)}var e=a.g.get("player","getAssetUri")();c=a.g.get("video","ended");b=Promise.resolve();var f=a.i.autoplay;d=null;c||(d=a.g.get("video","currentTime"));e&&(a.i.autoplay=!1,b=a.h.load(e,d));var g={};c=t(qn);for(d=c.next();!d.done;d=c.next())d=d.value,g[d]=a.g.get("video",d);b.then(function(){if(a.i){for(var h=t(qn),k=h.next();!k.done;k=h.next())k=k.value,a.i[k]=g[k];h=t(wn);for(k=
541
541
  h.next();!k.done;k=h.next()){var l=k.value;k=l[1];l=a.g.get("player",l[0])();a.h[k](l)}a.i.autoplay=f;e&&a.i.play()}},function(h){h=(new Map).set("detail",h);h=new Q(Wm,h);a.h.dispatchEvent(h)})}
542
542
  function co(a,b){if("addEventListener"==b)return function(d,e,f){return a.j.addEventListener(d,e,f)};if("removeEventListener"==b)return function(d,e,f){return a.j.removeEventListener(d,e,f)};if(a.g.ua()&&0==Object.keys(a.g.g.video).length){var c=a.i[b];if("function"!=typeof c)return c}return a.g.ua()?a.g.get("video",b):(c=a.i[b],"function"==typeof c&&(c=c.bind(a.i)),c)}
543
- function fo(a,b){a.u.has(b)&&(b=a.u.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.dc()};if("getDrmEngine"==b)return function(){return a.h.m};if("getAdManager"==b)return function(){return a.h.le()};
543
+ function fo(a,b){a.u.has(b)&&(b=a.u.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.dc()};if("getDrmEngine"==b)return function(){return a.h.m};if("getAdManager"==b)return function(){return a.h.me()};
544
544
  if("setVideoContainer"==b)return function(c){return a.h.Ge(c)};if(a.g.ua()){if("getManifest"==b||"drmInfo"==b)return function(){Ua(b+"() does not work while casting!");return null};if("attach"==b||"detach"==b)return function(){Ua(b+"() does not work while casting!");return Promise.resolve()}}return a.g.ua()&&0==Object.keys(a.g.g.video).length&&(sn[b]||tn[b])||!a.g.ua()?a.h[b].bind(a.h):a.g.get("player",b)}
545
- function Zn(a,b,c){a.g.ua()&&("video"==b?a.j.dispatchEvent(c):"player"==b&&a.o.dispatchEvent(c))}M("shaka.cast.CastProxy",Wn);Wn.prototype.changeReceiverId=Wn.prototype.Te;Wn.prototype.forceDisconnect=Wn.prototype.Bb;Wn.prototype.suggestDisconnect=Wn.prototype.bg;Wn.prototype.setAppData=Wn.prototype.Ud;Wn.prototype.cast=Wn.prototype.cast;Wn.prototype.receiverName=Wn.prototype.Od;Wn.prototype.isCasting=Wn.prototype.ua;Wn.prototype.canCast=Wn.prototype.Qe;Wn.prototype.getPlayer=Wn.prototype.pf;
545
+ function Zn(a,b,c){a.g.ua()&&("video"==b?a.j.dispatchEvent(c):"player"==b&&a.o.dispatchEvent(c))}M("shaka.cast.CastProxy",Wn);Wn.prototype.changeReceiverId=Wn.prototype.Te;Wn.prototype.forceDisconnect=Wn.prototype.Bb;Wn.prototype.suggestDisconnect=Wn.prototype.bg;Wn.prototype.setAppData=Wn.prototype.Vd;Wn.prototype.cast=Wn.prototype.cast;Wn.prototype.receiverName=Wn.prototype.Pd;Wn.prototype.isCasting=Wn.prototype.ua;Wn.prototype.canCast=Wn.prototype.Qe;Wn.prototype.getPlayer=Wn.prototype.pf;
546
546
  Wn.prototype.getVideo=Wn.prototype.zf;Wn.prototype.destroy=Wn.prototype.destroy;function ho(a,b,c,d){Ne.call(this);var e=this;this.g=a;this.h=b;this.j=new ef;this.I={video:a,player:b};this.D=c||function(){};this.L=d||function(f){return f};this.i=null;this.F=!1;this.o=!0;this.m=0;this.C=!1;this.u=!0;this.s=this.l=null;this.G=new O(function(){io(e)});jo(this)}qa(ho,Ne);r=ho.prototype;r.isConnected=function(){return this.F};r.Df=function(){return this.o};r.Yf=function(a){this.i=a};r.We=function(){this.i=null};
547
547
  r.Zf=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.title=a};r.Xf=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.images=[{url:a}]};r.Wf=function(a){this.i||(this.i={});this.i.artist=a;this.i.metadataType=cast.receiver.media.MetadataType.MUSIC_TRACK};
548
548
  r.destroy=function(){var a=this,b,c;return L(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.G&&(a.G.stop(),a.G=null),a.g=null,a.I=null,a.D=null,a.F=!1,a.o=!0,a.l=null,a.s=null,Ne.prototype.release.call(a),u(d,Promise.all(b),2);c=cast.receiver.CastReceiverManager.getInstance();c.stop();A(d)})};
549
549
  function jo(a){var b=cast.receiver.CastReceiverManager.getInstance();b.onSenderConnected=function(){return ko(a)};b.onSenderDisconnected=function(){return ko(a)};b.onSystemVolumeChanged=function(){var e=cast.receiver.CastReceiverManager.getInstance().getSystemVolume();e&&lo(a,{type:"update",update:{video:{volume:e.level,muted:e.muted}}},a.l);lo(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 mo(a,
550
- e)};a.l=b.getCastMessageBus("urn:x-cast:com.google.shaka.v2");a.l.onMessage=function(e){return no(a,e)};b.start();b=t(on);for(var c=b.next();!c.done;c=b.next())a.j.A(a.g,c.value,function(e){return oo(a,"video",e)});for(var d in $m)a.j.A(a.h,$m[d],function(e){return oo(a,"player",e)});cast.__platform__&&cast.__platform__.canDisplayType('video/mp4; codecs="avc1.640028"; width=3840; height=2160')?a.h.Wd(3840,2160):a.h.Wd(1920,1080);a.j.A(a.g,"loadeddata",function(){a.C=!0});a.j.A(a.h,"loading",function(){a.o=
550
+ e)};a.l=b.getCastMessageBus("urn:x-cast:com.google.shaka.v2");a.l.onMessage=function(e){return no(a,e)};b.start();b=t(on);for(var c=b.next();!c.done;c=b.next())a.j.A(a.g,c.value,function(e){return oo(a,"video",e)});for(var d in $m)a.j.A(a.h,$m[d],function(e){return oo(a,"player",e)});cast.__platform__&&cast.__platform__.canDisplayType('video/mp4; codecs="avc1.640028"; width=3840; height=2160')?a.h.Xd(3840,2160):a.h.Xd(1920,1080);a.j.A(a.g,"loadeddata",function(){a.C=!0});a.j.A(a.h,"loading",function(){a.o=
551
551
  !1;po(a)});a.j.A(a.g,"playing",function(){a.o=!1;po(a)});a.j.A(a.g,"pause",function(){po(a)});a.j.A(a.h,"unloading",function(){a.o=!0;po(a)});a.j.A(a.g,"ended",function(){(new O(function(){a.g&&a.g.ended&&(a.o=!0,po(a))})).S(qo)})}function ko(a){a.m=0;a.u=!0;a.F=0!=cast.receiver.CastReceiverManager.getInstance().getSenders().length;po(a)}
552
552
  function po(a){var b;L(function(c){if(1==c.g)return u(c,Promise.resolve(),2);if(!a.h)return c["return"]();b=new Q("caststatuschanged");a.dispatchEvent(b);ro(a)||so(a);A(c)})}
553
553
  function to(a,b,c){var d,e,f,g,h,k,l,m,n,p,q;L(function(v){switch(v.g){case 1:for(d in b.player)e=b.player[d],a.h[d](e);a.D(c);f=a.g.autoplay;return b.manifest?(a.g.autoplay=!1,C(v,5),u(v,a.h.load(b.manifest,b.startTime),7)):u(v,Promise.resolve(),3);case 7:va(v,3);break;case 5:return g=E(v),h=Wm,k=(new Map).set("detail",g),l=new Q(h,k),a.h&&a.h.dispatchEvent(l),v["return"]();case 3:if(!a.h)return v["return"]();for(m in b.video)n=b.video[m],a.g[m]=n;for(p in b.playerAfterLoad)q=b.playerAfterLoad[p],
554
554
  a.h[p](q);a.g.autoplay=f;b.manifest&&(a.g.play(),so(a));A(v)}})}function oo(a,b,c){a.h&&(io(a),lo(a,{type:"event",targetName:b,event:c},a.l))}
555
- function io(a){a.G.S(uo);for(var b={video:{},player:{}},c=t(pn),d=c.next();!d.done;d=c.next())d=d.value,b.video[d]=a.g[d];if(a.h.T())for(var e in un)0==a.m%un[e]&&(b.player[e]=a.h[e]());for(var f in sn)0==a.m%sn[f]&&(b.player[f]=a.h[f]());if(c=cast.receiver.CastReceiverManager.getInstance().getSystemVolume())b.video.volume=c.level,b.video.muted=c.muted;lo(a,{type:"update",update:b},a.l);for(var g in tn)0==a.m%tn[g]&&(b={player:{}},b.player[g]=a.h[g](),lo(a,{type:"update",update:b},a.l));a.C&&(a.m+=
556
- 1);ro(a)}function ro(a){return a.u&&(a.g.duration||a.h.T())?(vo(a),a.u=!1,!0):!1}function vo(a,b){var c={contentId:a.h.rd(),streamType:a.h.T()?"LIVE":"BUFFERED",contentType:""};a.h.T()||(c.duration=a.g.duration);a.i&&(c.metadata=a.i);so(a,void 0===b?0:b,c)}
555
+ function io(a){a.G.S(uo);for(var b={video:{},player:{}},c=t(pn),d=c.next();!d.done;d=c.next())d=d.value,b.video[d]=a.g[d];if(a.h.U())for(var e in un)0==a.m%un[e]&&(b.player[e]=a.h[e]());for(var f in sn)0==a.m%sn[f]&&(b.player[f]=a.h[f]());if(c=cast.receiver.CastReceiverManager.getInstance().getSystemVolume())b.video.volume=c.level,b.video.muted=c.muted;lo(a,{type:"update",update:b},a.l);for(var g in tn)0==a.m%tn[g]&&(b={player:{}},b.player[g]=a.h[g](),lo(a,{type:"update",update:b},a.l));a.C&&(a.m+=
556
+ 1);ro(a)}function ro(a){return a.u&&(a.g.duration||a.h.U())?(vo(a),a.u=!1,!0):!1}function vo(a,b){var c={contentId:a.h.rd(),streamType:a.h.U()?"LIVE":"BUFFERED",contentType:""};a.h.U()||(c.duration=a.g.duration);a.i&&(c.metadata=a.i);so(a,void 0===b?0:b,c)}
557
557
  function no(a,b){var c=mn(b.data);switch(c.type){case "init":a.m=0;a.C=!1;a.u=!0;to(a,c.initState,c.appData);io(a);break;case "appData":a.D(c.appData);break;case "set":var d=c.targetName,e=c.property;c=c.value;if("video"==d){var f=cast.receiver.CastReceiverManager.getInstance();if("volume"==e){f.setSystemVolumeLevel(c);break}else if("muted"==e){f.setSystemVolumeMuted(c);break}}a.I[d][e]=c;break;case "call":d=a.I[c.targetName];d[c.methodName].apply(d,c.args);break;case "asyncCall":d=c.targetName;e=
558
558
  c.methodName;"player"==d&&"load"==e&&(a.m=0,a.C=!1);var g=c.id,h=b.senderId;f=a.I[d];c=f[e].apply(f,c.args);"player"==d&&"load"==e&&(c=c.then(function(){a.u=!0}));c.then(function(){return wo(a,h,g,null)},function(k){return wo(a,h,g,k)})}}
559
- function mo(a,b){var c=mn(b.data);switch(c.type){case "PLAY":a.g.play();so(a);break;case "PAUSE":a.g.pause();so(a);break;case "SEEK":var d=c.currentTime,e=c.resumeState;null!=d&&(a.g.currentTime=Number(d));e&&"PLAYBACK_START"==e?(a.g.play(),so(a)):e&&"PLAYBACK_PAUSE"==e&&(a.g.pause(),so(a));break;case "STOP":a.h.be().then(function(){a.h&&so(a)});break;case "GET_STATUS":vo(a,Number(c.requestId));break;case "VOLUME":e=c.volume;d=e.level;e=e.muted;var f=a.g.volume,g=a.g.muted;null!=d&&(a.g.volume=Number(d));
559
+ function mo(a,b){var c=mn(b.data);switch(c.type){case "PLAY":a.g.play();so(a);break;case "PAUSE":a.g.pause();so(a);break;case "SEEK":var d=c.currentTime,e=c.resumeState;null!=d&&(a.g.currentTime=Number(d));e&&"PLAYBACK_START"==e?(a.g.play(),so(a)):e&&"PLAYBACK_PAUSE"==e&&(a.g.pause(),so(a));break;case "STOP":a.h.ce().then(function(){a.h&&so(a)});break;case "GET_STATUS":vo(a,Number(c.requestId));break;case "VOLUME":e=c.volume;d=e.level;e=e.muted;var f=a.g.volume,g=a.g.muted;null!=d&&(a.g.volume=Number(d));
560
560
  null!=e&&(a.g.muted=e);f==a.g.volume&&g==a.g.muted||so(a);break;case "LOAD":a.m=0;a.C=!1;a.u=!1;d=c.media;e=c.currentTime;f=a.L(d.contentId);g=c.autoplay||!0;a.D(d.customData);g&&(a.g.autoplay=!0);a.h.load(f,e).then(function(){a.h&&vo(a)})["catch"](function(h){var k="LOAD_FAILED";7==h.category&&7E3==h.code&&(k="LOAD_CANCELLED");lo(a,{requestId:Number(c.requestId),type:k},a.s)});break;default:lo(a,{requestId:Number(c.requestId),type:"INVALID_REQUEST",reason:"INVALID_COMMAND"},a.s)}}
561
561
  function wo(a,b,c,d){a.h&&lo(a,{type:"asyncComplete",id:c,error:d},a.l,b)}function lo(a,b,c,d){a.F&&(a=ln(b),d?c.getCastChannel(d).send(a):c.broadcast(a))}function so(a,b,c){c=void 0===c?null:c;var d={mediaSessionId:0,playbackRate:a.g.playbackRate,playerState:a.o?xo:a.h.sd()?yo:a.g.paused?zo:Ao,currentTime:a.g.currentTime,supportedMediaCommands:63,volume:{level:a.g.volume,muted:a.g.muted}};c&&(d.media=c);lo(a,{requestId:void 0===b?0:b,type:"MEDIA_STATUS",status:[d]},a.s)}
562
562
  M("shaka.cast.CastReceiver",ho);ho.prototype.destroy=ho.prototype.destroy;ho.prototype.setContentArtist=ho.prototype.Wf;ho.prototype.setContentImage=ho.prototype.Xf;ho.prototype.setContentTitle=ho.prototype.Zf;ho.prototype.clearContentMetadata=ho.prototype.We;ho.prototype.setContentMetadata=ho.prototype.Yf;ho.prototype.isIdle=ho.prototype.Df;ho.prototype.isConnected=ho.prototype.isConnected;var uo=.5,qo=5,xo="IDLE",Ao="PLAYING",yo="BUFFERING",zo="PAUSED";function Bo(a){var b=this;this.g=[];this.h=[];this.data=[];(new Ig).box("moov",Mg).P("pssh",function(c){if(!(1<c.version)){var d=Fb(c.reader.O,-12,c.size);b.data.push(d);b.g.push(Uc(c.reader.Za(16)));if(0<c.version){d=c.reader.M();for(var e=0;e<d;e++){var f=Uc(c.reader.Za(16));b.h.push(f)}}}}).parse(a)}
563
563
  function Co(a,b){var c=a.length,d=b.length+16+c,e=new Uint8Array(d),f=Ib(e),g=0;f.setUint32(g,d);g+=4;f.setUint32(g,1886614376);g+=4;f.setUint32(g,0);g+=4;e.set(b,g);g+=b.length;f.setUint32(g,c);e.set(a,g+4);return e}function Do(a){if(!a)return a;var b=new Bo(a);if(1>=b.data.length)return a;a=[];var c={};b=t(b.data);for(var d=b.next();!d.done;c={sc:c.sc},d=b.next())c.sc=d.value,a.some(function(e){return function(f){return Db(f,e.sc)}}(c))||a.push(c.sc);return Vc.apply(Pc,ja(a))};function Eo(a,b,c){var d=Fo(a),e=null;a=[];var f=[],g=new Set(d.map(function(h){return h.keyId}));g["delete"](null);if(1<g.size)throw new N(2,4,4010);b||(f=d.filter(function(h){return"urn:mpeg:dash:mp4protection:2011"==h.Ae?(e=h.init||e,!1):!0}),f.length&&(a=Go(e,f,c),0==a.length&&(a=[lc("",e)])));if(d.length&&(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(lc(c,e));if(g=Array.from(g)[0]||null)for(b=t(a),c=b.next();!c.done;c=b.next())for(c=
564
- t(c.value.initData),d=c.next();!d.done;d=c.next())d.value.keyId=g;return{ge:g,Og:e,drmInfos:a,ke:!0}}function Ho(a,b,c,d){var e=Eo(a,c,d);if(b.ke){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.ke=!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 N(2,4,4008);return e.ge||b.ge}
564
+ t(c.value.initData),d=c.next();!d.done;d=c.next())d.value.keyId=g;return{he:g,Og:e,drmInfos:a,le:!0}}function Ho(a,b,c,d){var e=Eo(a,c,d);if(b.le){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.le=!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 N(2,4,4008);return e.he||b.he}
565
565
  function Io(a){var b=0,c=Ib(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=Fb(c,a,e);b.push({type:d,value:f});a+=e}c=b}return c}
566
566
  function Jo(a){a=t(a.getElementsByTagName("DATA"));for(var b=a.next();!b.done;b=a.next()){b=t(b.value.childNodes);for(var c=b.next();!c.done;c=b.next())if(c=c.value,c instanceof Element&&"LA_URL"==c.tagName)return c.textContent}return""}function Ko(a){a=uf(a.node,"urn:microsoft:playready","pro");if(!a)return"";a=Sc(a.textContent);a=Io(a).filter(function(b){return b.type===Lo})[0];if(!a)return"";a=Kc(a.value,!0);return(a=Mf(a,"WRMHEADER"))?Jo(a):""}
567
567
  function Go(a,b,c){var d=[];b=t(b);for(var e=b.next();!e.done;e=b.next()){e=e.value;var f=c[e.Ae];if(f){var g;if(g=uf(e.node,"urn:microsoft:playready","pro")){g=Sc(g.textContent);var h=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);g=[{initData:Co(g,h),initDataType:"cenc",keyId:e.keyId}]}else g=null;g=lc(f,e.init||a||g);if(f=Mo.get(f))g.licenseServerUri=f(e);d.push(g)}}return d}
@@ -569,8 +569,8 @@ function Fo(a){var b=[];a=t(a);for(var c=a.next();!c.done;c=a.next())(c=No(c.val
569
569
  function No(a){var b=a.getAttribute("schemeIdUri"),c=xf(a,"urn:mpeg:cenc:2013","default_KID"),d=vf(a,"urn:mpeg:cenc:2013","pssh").map(zf);if(!b)return null;b=b.toLowerCase();if(c&&(c=c.replace(/-/g,"").toLowerCase(),c.includes(" ")))throw new N(2,4,4009);var e=[];try{e=d.map(function(f){return{initDataType:"cenc",initData:Sc(f),keyId:null}})}catch(f){throw new N(2,4,4007);}return{node:a,Ae:b,keyId:c,init:0<e.length?e:null}}
570
570
  var Lo=1,Mo=(new Map).set("com.widevine.alpha",function(a){return(a=uf(a.node,"urn:microsoft","laurl"))?a.getAttribute("licenseUrl")||"":""}).set("com.microsoft.playready",Ko).set("com.microsoft.playready.recommendation",Ko).set("com.microsoft.playready.software",Ko).set("com.microsoft.playready.hardware",Ko);function Oo(a,b,c,d,e){var f={RepresentationID:b,Number:c,Bandwidth:d,Time:e};return a.replace(/\$(RepresentationID|Number|Bandwidth|Time)?(?:%0([0-9]+)([diouxX]))?\$/g,function(g,h,k,l){if("$$"==g)return"$";var m=f[h];if(null==m)return g;"RepresentationID"==h&&k&&(k=void 0);"Time"==h&&(m=Math.round(m));switch(l){case void 0:case "d":case "i":case "u":g=m.toString();break;case "o":g=m.toString(8);break;case "x":g=m.toString(16);break;case "X":g=m.toString(16).toUpperCase();break;default:g=m.toString()}k=
571
571
  window.parseInt(k,10)||1;return Array(Math.max(0,k-g.length)+1).join("0")+g})}
572
- function Po(a,b){var c=Qo(a,b,"timescale"),d=1;c&&(d=If(c)||1);var e=Qo(a,b,"duration");c=If(e||"");"image"==a.H.contentType&&(c=Kf(e||""));c&&(c/=d);var f=Qo(a,b,"startNumber");e=Number(Qo(a,b,"presentationTimeOffset"))||0;var g=Jf(f||"");if(null==f||null==g)g=1;var h=Ro(a,b,"SegmentTimeline");f=null;if(h){f=d;var k=a.U.duration||Infinity;h=tf(h,"S");for(var l=[],m=-e,n=0;n<h.length;++n){var p=h[n],q=h[n+1],v=Bf(p,"t",Jf),y=Bf(p,"d",Jf);p=Bf(p,"r",Ff);null!=v&&(v-=e);if(!y)break;v=null!=v?v:m;p=
573
- p||0;if(0>p)if(q){q=Bf(q,"t",Jf);if(null==q)break;else if(v>=q)break;p=Math.ceil((q-v)/y)-1}else{if(Infinity==k)break;else if(v/f>=k)break;p=Math.ceil((k*f-v)/y)-1}0<l.length&&v!=m&&(l[l.length-1].end=v/f);for(q=0;q<=p;++q)m=v+y,l.push({start:v/f,end:m/f,fg:v}),v=m}f=l}return{timescale:d,ja:c,Mb:g,Ta:e/d||0,ce:e,timeline:f}}function Qo(a,b,c){return[b(a.H),b(a.ga),b(a.aa)].filter(Qb).map(function(d){return d.getAttribute(c)}).reduce(function(d,e){return d||e})}
572
+ function Po(a,b){var c=Qo(a,b,"timescale"),d=1;c&&(d=If(c)||1);var e=Qo(a,b,"duration");c=If(e||"");"image"==a.H.contentType&&(c=Kf(e||""));c&&(c/=d);var f=Qo(a,b,"startNumber");e=Number(Qo(a,b,"presentationTimeOffset"))||0;var g=Jf(f||"");if(null==f||null==g)g=1;var h=Ro(a,b,"SegmentTimeline");f=null;if(h){f=d;var k=a.T.duration||Infinity;h=tf(h,"S");for(var l=[],m=-e,n=0;n<h.length;++n){var p=h[n],q=h[n+1],v=Bf(p,"t",Jf),w=Bf(p,"d",Jf);p=Bf(p,"r",Ff);null!=v&&(v-=e);if(!w)break;v=null!=v?v:m;p=
573
+ p||0;if(0>p)if(q){q=Bf(q,"t",Jf);if(null==q)break;else if(v>=q)break;p=Math.ceil((q-v)/w)-1}else{if(Infinity==k)break;else if(v/f>=k)break;p=Math.ceil((k*f-v)/w)-1}0<l.length&&v!=m&&(l[l.length-1].end=v/f);for(q=0;q<=p;++q)m=v+w,l.push({start:v/f,end:m/f,fg:v}),v=m}f=l}return{timescale:d,ja:c,Mb:g,Ua:e/d||0,de:e,timeline:f}}function Qo(a,b,c){return[b(a.H),b(a.ga),b(a.aa)].filter(Qb).map(function(d){return d.getAttribute(c)}).reduce(function(d,e){return d||e})}
574
574
  function Ro(a,b,c){return[b(a.H),b(a.ga),b(a.aa)].filter(Qb).map(function(d){return sf(d,c)}).reduce(function(d,e){return d||e})}
575
575
  function So(a,b,c,d,e,f){for(var g=xf(a,"http://www.w3.org/1999/xlink","href"),h=xf(a,"http://www.w3.org/1999/xlink","actuate")||"onRequest",k=t(Array.from(a.attributes)),l=k.next();!l.done;l=k.next())l=l.value,"http://www.w3.org/1999/xlink"==l.namespaceURI&&a.removeAttributeNS(l.namespaceURI,l.localName);if(5<=f)return Ge(new N(2,4,4028));if("onLoad"!=h)return Ge(new N(2,4,4027));var m=kc([d],[g]);return e.request(0,We(m,b)).$(function(n){n=Of(n.data,a.tagName);if(!n)return Ge(new N(2,4,4001,g));
576
576
  for(;a.childNodes.length;)a.removeChild(a.childNodes[0]);for(;n.childNodes.length;){var p=n.childNodes[0];n.removeChild(p);a.appendChild(p)}n=t(Array.from(n.attributes));for(p=n.next();!p.done;p=n.next())a.setAttributeNode(p.value.cloneNode(!1));return To(a,b,c,m[0],e,f+1)})}
@@ -581,31 +581,31 @@ function Yo(a){var b=a.g.X(),c=a.g.Y();if(0==c)throw new N(2,3,3002);c=8-Math.fl
581
581
  function ap(a){if(8<a.g.byteLength)throw new N(2,3,3002);if(8==a.g.byteLength&&a.g.getUint8(0)&224)throw new N(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 bp(a,b,c,d,e,f,g,h,k){function l(){return e}var m=[];a=new Wo(a.g);for(var n=null,p=null;a.ma();){var q=Xo(a);if(187==q.id){var v=cp(q);v&&(q=c*v.gg,v=b+v.Qf,null!=n&&m.push(new Ii(n+g,q+g,l,p,v-1,f,g,h,k)),n=q,p=v)}}null!=n&&m.push(new Ii(n+g,d+g,l,p,null,f,g,h,k));return m}
582
582
  function cp(a){var b=new Wo(a.g);a=Xo(b);if(179!=a.id)throw new N(2,3,3013);a=ap(a);b=Xo(b);if(183!=b.id)throw new N(2,3,3012);b=new Wo(b.g);for(var c=0;b.ma();){var d=Xo(b);if(241==d.id){c=ap(d);break}}return{gg:a,Qf:c}};function dp(a,b){var c=Ro(a,b,"Initialization");if(!c)return null;var d=a.H.za,e=c.getAttribute("sourceURL");e&&(d=kc(a.H.za,[e]));e=0;var f=null;if(c=Bf(c,"range",Ef))e=c.start,f=c.end;return new Gi(function(){return d},e,f,ep(a))}
583
583
  function fp(a,b){var c=Number(Qo(a,gp,"presentationTimeOffset"))||0,d=Qo(a,gp,"timescale"),e=1;d&&(e=If(d)||1);var f=c/e||0,g=dp(a,gp);hp(a,g);var h=Pe(a);return{Cb:function(){var k=Ro(h,gp,"RepresentationIndex"),l=h.H.za;k&&(k=k.getAttribute("sourceURL"))&&(l=kc(h.H.za,[k]));k=ip(h);return jp(h,b,g,l,k.start,k.end,f)}}}
584
- function jp(a,b,c,d,e,f,g){var h,k,l,m,n,p,q,v,y,w,x,D,z,B,F;return L(function(G){if(1==G.g)return h=a.presentationTimeline,k=!a.Wa||!a.U.re,l=a.U.start,m=a.U.duration,n=a.H.mimeType.split("/")[1],p=b,q=null,v=[p(d,e,f),"webm"==n?p(c.sa(),c.pa,c.ha):null],p=null,u(G,Promise.all(v),2);y=G.h;w=y[0];x=y[1]||null;D=null;z=l-g;B=l;F=m?l+m:Infinity;if("mp4"==n)var H=Uo(w,e,d,c,z,B,F);else{H=new Wo(x);if(440786851!=Xo(H).id)throw new N(2,3,3008);var I=Xo(H);if(408125543!=I.id)throw new N(2,3,3009);H=I.g.byteOffset;
585
- I=new Wo(I.g);for(var J=null;I.ma();){var K=Xo(I);if(357149030==K.id){J=K;break}}if(!J)throw new N(2,3,3010);J=new Wo(J.g);K=1E6;for(I=null;J.ma();){var P=Xo(J);if(2807729==P.id)K=ap(P);else if(17545==P.id)if(4==P.g.byteLength)I=P.g.getFloat32(0);else if(8==P.g.byteLength)I=P.g.getFloat64(0);else throw new N(2,3,3003);}if(null==I)throw new N(2,3,3011);J=K/1E9;I*=J;K=Xo(new Wo(w));if(475249515!=K.id)throw new N(2,3,3007);H=bp(K,H,J,I,d,c,z,B,F)}D=H;h.Hb(D);q=new T(D);k&&q.Xa(B,F,!0);return G["return"](q)})}
584
+ function jp(a,b,c,d,e,f,g){var h,k,l,m,n,p,q,v,w,x,y,D,z,B,F;return L(function(G){if(1==G.g)return h=a.presentationTimeline,k=!a.Pa||!a.T.td,l=a.T.start,m=a.T.duration,n=a.H.mimeType.split("/")[1],p=b,q=null,v=[p(d,e,f),"webm"==n?p(c.sa(),c.pa,c.ha):null],p=null,u(G,Promise.all(v),2);w=G.h;x=w[0];y=w[1]||null;D=null;z=l-g;B=l;F=m?l+m:Infinity;if("mp4"==n)var H=Uo(x,e,d,c,z,B,F);else{H=new Wo(y);if(440786851!=Xo(H).id)throw new N(2,3,3008);var I=Xo(H);if(408125543!=I.id)throw new N(2,3,3009);H=I.g.byteOffset;
585
+ I=new Wo(I.g);for(var J=null;I.ma();){var K=Xo(I);if(357149030==K.id){J=K;break}}if(!J)throw new N(2,3,3010);J=new Wo(J.g);K=1E6;for(I=null;J.ma();){var P=Xo(J);if(2807729==P.id)K=ap(P);else if(17545==P.id)if(4==P.g.byteLength)I=P.g.getFloat32(0);else if(8==P.g.byteLength)I=P.g.getFloat64(0);else throw new N(2,3,3003);}if(null==I)throw new N(2,3,3011);J=K/1E9;I*=J;K=Xo(new Wo(x));if(475249515!=K.id)throw new N(2,3,3007);H=bp(K,H,J,I,d,c,z,B,F)}D=H;h.Hb(D);q=new T(D);k&&q.Xa(B,F,!0);return G["return"](q)})}
586
586
  function gp(a){return a.nc}function ip(a){var b=Ro(a,gp,"RepresentationIndex");a=Qo(a,gp,"indexRange");a=Ef(a||"");b&&(a=Bf(b,"range",Ef,a));return a}function hp(a,b){kp(a,b);if(!ip(a))throw new N(2,4,4002);}function kp(a,b){var c=a.H.mimeType.split("/")[1];if(a.H.contentType!=pc&&"mp4"!=c&&"webm"!=c)throw new N(2,4,4006);if("webm"==c&&!b)throw new N(2,4,4005);}
587
- function ep(a){var b=a.H;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.Nc,pixelAspectRatio:b.pixelAspectRatio||null,width:b.width||null}};function lp(a,b){var c=dp(a,mp),d=np(a);if(!d.ja&&!d.timeline&&1<d.Eb.length)throw new N(2,4,4002);if(!d.ja&&!a.U.duration&&!d.timeline&&1==d.Eb.length)throw new N(2,4,4002);if(d.timeline&&0==d.timeline.length)throw new N(2,4,4002);var e=null,f=null;a.aa.id&&a.H.id&&(f=b[a.aa.id+","+a.H.id])&&(e=f.segmentIndex);var g=op(a.U.start,a.U.duration,a.H.za,d,c);c=!e;e?e.Gb(g,a.presentationTimeline.Qa()):e=new T(g);a.presentationTimeline.Hb(g);a.Wa&&a.U.re||e.Xa(a.U.start,a.U.duration?a.U.start+a.U.duration:
588
- Infinity,c);f&&(f.segmentIndex=e);return{Cb:function(){e&&0!=e.K.length||e.Fb(g);return Promise.resolve(e)}}}function mp(a){return a.$a}function np(a){var b=pp(a);a=Po(a,mp);var c=a.Mb;0==c&&(c=1);var d=0;a.ja?d=a.ja*(c-1):a.timeline&&0<a.timeline.length&&(d=a.timeline[0].start);return{ja:a.ja,startTime:d,Mb:c,Ta:a.Ta,timeline:a.timeline,Eb:b}}
589
- function op(a,b,c,d,e){var f=d.Eb.length;d.timeline&&d.timeline.length!=d.Eb.length&&(f=Math.min(d.timeline.length,d.Eb.length));for(var g=a-d.Ta,h=b?a+b:Infinity,k=[],l=d.startTime,m={},n=0;n<f;m={cd:m.cd},n++){var p=d.Eb[n];m.cd=kc(c,[p.Hf]);var q=void 0;q=null!=d.ja?l+d.ja:d.timeline?d.timeline[n].end:l+b;k.push(new Ii(a+l,a+q,function(v){return function(){return v.cd}}(m),p.start,p.end,e,g,a,h));l=q}return k}
590
- function pp(a){return[a.H.$a,a.ga.$a,a.aa.$a].filter(Qb).map(function(b){return tf(b,"SegmentURL")}).reduce(function(b,c){return 0<b.length?b:c}).map(function(b){b.getAttribute("indexRange")&&!a.pe&&(a.pe=!0);var c=b.getAttribute("media");b=Bf(b,"mediaRange",Ef,{start:0,end:null});return{Hf:c,start:b.start,end:b.end}})};function qp(a,b,c,d,e,f){var g=rp(a),h=sp(a);tp(h);var k=Pe(a);if(h.ic)return kp(a,g),{Cb:function(){var q=Oo(h.ic,k.H.id,null,k.bandwidth||null,null);q=kc(k.H.za,[q]);return jp(k,b,g,q,0,null,h.Ta)}};if(h.ja)return d||"image"===a.ga.contentType||(a.presentationTimeline.Hd(h.ja),a.presentationTimeline.Id(a.U.start)),{Cb:function(){return up(k,h,e,g,f)}};var l=null;d=d=null;a.aa.id&&a.H.id&&(d=a.aa.id+","+a.H.id,d=c[d])&&(l=d.segmentIndex);var m=vp(k,h,g);c=a.U.start;var n=a.U.duration?a.U.start+a.U.duration:
591
- Infinity,p=Infinity!=n;l?(p&&(new T(m)).Xa(c,n,!0),l.Gb(m,a.presentationTimeline.Qa())):l=new T(m);a.presentationTimeline.Hb(m);p&&l.Xa(c,n);d&&a.Wa&&(d.segmentIndex=l);return{Cb:function(){l&&0!=l.K.length||l.Fb(m);return Promise.resolve(l)}}}function wp(a){return a.oc}function sp(a){var b=Po(a,wp),c=Qo(a,wp,"media");a=Qo(a,wp,"index");return{ja:b.ja,timescale:b.timescale,Mb:b.Mb,Ta:b.Ta,ce:b.ce,timeline:b.timeline,Fd:c,ic:a}}
592
- function tp(a){var b=a.ic?1:0;b+=a.timeline?1:0;b+=a.ja?1:0;if(0==b)throw new N(2,4,4002);1!=b&&(a.ic&&(a.timeline=null),a.ja=null);if(!a.ic&&!a.Fd)throw new N(2,4,4002);}
593
- function up(a,b,c,d,e){function f(J){var K=(J-q)*p,P=K+b.Ta,R=K+l;K=R+p;var ba=Math.min(K,h());R=new Ii(R,ba,function(){var aa=Oo(y,x,J,w,P*v);return kc(D,[aa])},0,null,d,z,l,h());R.l=K;return R}function g(){var J=[Math.max(k.Qa(),l),Math.min(k.hb(),h())].map(function(K){return K-l});return[Math.ceil(J[0]/p),Math.ceil(J[1]/p)-1].map(function(K){return K+q})}function h(){var J=null!=m&&e[m]||n;return J?l+J:Infinity}var k=a.presentationTimeline,l=a.U.start,m=a.aa.id,n=a.U.duration,p=b.ja,q=b.Mb,v=b.timescale,
594
- y=b.Fd,w=a.bandwidth||null,x=a.H.id,D=a.H.za,z=l-b.Ta,B=g();a=a.Wa?Math.max(B[0],B[1]-c+1):B[0];B=B[1];c=[];for(var F=a;F<=B;++F){var G=f(F);c.push(G)}var H=new T(c);c=k.hb()<h();F=k.T();if(c||F){var I=Math.max(a,B+1);H.Uc(p,function(){var J=k.Qa();H.eb(J);var K=t(g());K.next();K=K.next().value;for(var P=[];I<=K;){var R=f(I);P.push(R);I++}return J>h()&&!P.length?null:P})}return Promise.resolve(H)}
595
- function vp(a,b,c){var d=a.U.start,e=a.U.duration,f=d-b.Ta;e=e?d+e:Infinity;for(var g=[],h={},k=0;k<b.timeline.length;h={bd:h.bd,fd:h.fd,jd:h.jd,Zc:h.Zc,ld:h.ld,$c:h.$c},k++){var l=b.timeline[k],m=l.start,n=l.fg;l=l.end;h.jd=k+b.Mb;h.ld=n+b.ce;h.fd=a.H.id;h.Zc=a.bandwidth||null;h.bd=b.Fd;h.$c=a.H.za;g.push(new Ii(d+m,d+l,function(p){return function(){var q=Oo(p.bd,p.fd,p.jd,p.Zc||null,p.ld);return kc(p.$c,[q]).map(function(v){return v.toString()})}}(h),0,null,c,f,d,e))}return g}
587
+ function ep(a){var b=a.H;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.Nc,pixelAspectRatio:b.pixelAspectRatio||null,width:b.width||null}};function lp(a,b){var c=dp(a,mp),d=np(a);if(!d.ja&&!d.timeline&&1<d.Eb.length)throw new N(2,4,4002);if(!d.ja&&!a.T.duration&&!d.timeline&&1==d.Eb.length)throw new N(2,4,4002);if(d.timeline&&0==d.timeline.length)throw new N(2,4,4002);var e=null,f=null;a.aa.id&&a.H.id&&(f=b[a.aa.id+","+a.H.id])&&(e=f.segmentIndex);var g=op(a.T.start,a.T.duration,a.H.za,d,c);c=!e;e?e.Gb(g,a.presentationTimeline.Ra()):e=new T(g);a.presentationTimeline.Hb(g);a.Pa&&a.T.td||e.Xa(a.T.start,a.T.duration?a.T.start+a.T.duration:
588
+ Infinity,c);f&&(f.segmentIndex=e);return{Cb:function(){e&&0!=e.K.length||e.Fb(g);return Promise.resolve(e)}}}function mp(a){return a.$a}function np(a){var b=pp(a);a=Po(a,mp);var c=a.Mb;0==c&&(c=1);var d=0;a.ja?d=a.ja*(c-1):a.timeline&&0<a.timeline.length&&(d=a.timeline[0].start);return{ja:a.ja,startTime:d,Mb:c,Ua:a.Ua,timeline:a.timeline,Eb:b}}
589
+ function op(a,b,c,d,e){var f=d.Eb.length;d.timeline&&d.timeline.length!=d.Eb.length&&(f=Math.min(d.timeline.length,d.Eb.length));for(var g=a-d.Ua,h=b?a+b:Infinity,k=[],l=d.startTime,m={},n=0;n<f;m={cd:m.cd},n++){var p=d.Eb[n];m.cd=kc(c,[p.Hf]);var q=void 0;q=null!=d.ja?l+d.ja:d.timeline?d.timeline[n].end:l+b;k.push(new Ii(a+l,a+q,function(v){return function(){return v.cd}}(m),p.start,p.end,e,g,a,h));l=q}return k}
590
+ function pp(a){return[a.H.$a,a.ga.$a,a.aa.$a].filter(Qb).map(function(b){return tf(b,"SegmentURL")}).reduce(function(b,c){return 0<b.length?b:c}).map(function(b){b.getAttribute("indexRange")&&!a.qe&&(a.qe=!0);var c=b.getAttribute("media");b=Bf(b,"mediaRange",Ef,{start:0,end:null});return{Hf:c,start:b.start,end:b.end}})};function qp(a,b,c,d,e,f){var g=rp(a),h=sp(a);tp(h);var k=Pe(a);if(h.ic)return kp(a,g),{Cb:function(){var q=Oo(h.ic,k.H.id,null,k.bandwidth||null,null);q=kc(k.H.za,[q]);return jp(k,b,g,q,0,null,h.Ua)}};if(h.ja)return d||"image"===a.ga.contentType||(a.presentationTimeline.Id(h.ja),a.presentationTimeline.Jd(a.T.start)),{Cb:function(){return up(k,h,e,g,f)}};var l=null;d=d=null;a.aa.id&&a.H.id&&(d=a.aa.id+","+a.H.id,d=c[d])&&(l=d.segmentIndex);var m=vp(k,h,g);c=a.T.start;var n=a.T.duration?a.T.start+a.T.duration:
591
+ Infinity,p=!(a.Pa&&a.T.td);l?(p&&(new T(m)).Xa(c,n,!0),l.Gb(m,a.presentationTimeline.Ra())):l=new T(m);a.presentationTimeline.Hb(m);p&&l.Xa(c,n);d&&a.Pa&&(d.segmentIndex=l);return{Cb:function(){l&&0!=l.K.length||l.Fb(m);return Promise.resolve(l)}}}function wp(a){return a.oc}function sp(a){var b=Po(a,wp),c=Qo(a,wp,"media");a=Qo(a,wp,"index");return{ja:b.ja,timescale:b.timescale,Mb:b.Mb,Ua:b.Ua,de:b.de,timeline:b.timeline,Gd:c,ic:a}}
592
+ function tp(a){var b=a.ic?1:0;b+=a.timeline?1:0;b+=a.ja?1:0;if(0==b)throw new N(2,4,4002);1!=b&&(a.ic&&(a.timeline=null),a.ja=null);if(!a.ic&&!a.Gd)throw new N(2,4,4002);}
593
+ function up(a,b,c,d,e){function f(J){var K=(J-q)*p,P=K+b.Ua,R=K+l;K=R+p;var ba=Math.min(K,h());R=new Ii(R,ba,function(){var aa=Oo(w,y,J,x,P*v);return kc(D,[aa])},0,null,d,z,l,h());R.l=K;return R}function g(){var J=[Math.max(k.Ra(),l),Math.min(k.hb(),h())].map(function(K){return K-l});return[Math.ceil(J[0]/p),Math.ceil(J[1]/p)-1].map(function(K){return K+q})}function h(){var J=null!=m&&e[m]||n;return J?l+J:Infinity}var k=a.presentationTimeline,l=a.T.start,m=a.aa.id,n=a.T.duration,p=b.ja,q=b.Mb,v=b.timescale,
594
+ w=b.Gd,x=a.bandwidth||null,y=a.H.id,D=a.H.za,z=l-b.Ua,B=g();a=a.Pa?Math.max(B[0],B[1]-c+1):B[0];B=B[1];c=[];for(var F=a;F<=B;++F){var G=f(F);c.push(G)}var H=new T(c);c=k.hb()<h();F=k.U();if(c||F){var I=Math.max(a,B+1);H.Uc(p,function(){var J=k.Ra();H.eb(J);var K=t(g());K.next();K=K.next().value;for(var P=[];I<=K;){var R=f(I);P.push(R);I++}return J>h()&&!P.length?null:P})}return Promise.resolve(H)}
595
+ function vp(a,b,c){var d=a.T.start,e=a.T.duration,f=d-b.Ua;e=e?d+e:Infinity;for(var g=[],h={},k=0;k<b.timeline.length;h={bd:h.bd,fd:h.fd,jd:h.jd,Zc:h.Zc,ld:h.ld,$c:h.$c},k++){var l=b.timeline[k],m=l.start,n=l.fg;l=l.end;h.jd=k+b.Mb;h.ld=n+b.de;h.fd=a.H.id;h.Zc=a.bandwidth||null;h.bd=b.Gd;h.$c=a.H.za;g.push(new Ii(d+m,d+l,function(p){return function(){var q=Oo(p.bd,p.fd,p.jd,p.Zc||null,p.ld);return kc(p.$c,[q]).map(function(v){return v.toString()})}}(h),0,null,c,f,d,e))}return g}
596
596
  function rp(a){var b=Qo(a,wp,"initialization");if(!b)return null;var c=a.H.id,d=a.bandwidth||null,e=a.H.za;return new Gi(function(){var f=Oo(b,c,null,d,null);return kc(e,[f])},0,null,ep(a))};function xp(){this.l=[];this.g=[];this.h=[];this.j=[];this.i=[];this.m=new Set}xp.prototype.release=function(){for(var a=t(this.g.concat(this.h,this.j,this.i)),b=a.next();!b.done;b=a.next())b=b.value,b.segmentIndex&&b.segmentIndex.release();this.g=[];this.h=[];this.j=[];this.i=[];this.l=[]};
597
- function yp(a,b,c){var d,e,f,g,h,k,l,m,n,p,q,v,y,w,x,D,z,B,F,G,H,I,J,K,P,R,ba,aa,Y,Da;return L(function(Fa){switch(Fa.g){case 1:d=qc;zp(b);Ap(b);Bp(b);Cp(b);if(!c&&1==b.length){e=b[0];a.g=e.yc;a.h=e.Wc;a.j=e.textStreams;a.i=e.imageStreams;Fa.B(2);break}f=-1;for(g=0;g<b.length;g++)h=b[g],a.m.has(h.id)||(a.m.add(h.id),-1==f&&(f=g));if(-1==f)return Fa["return"]();k=b.map(function(xa){return xa.yc});l=b.map(function(xa){return xa.Wc});m=b.map(function(xa){return xa.textStreams});n=b.map(function(xa){return xa.imageStreams});
598
- p=t(m);for(q=p.next();!q.done;q=p.next())v=q.value,v.push(Dp(d.Z));y=t(n);for(w=y.next();!w.done;w=y.next())x=w.value,x.push(Dp(d.Tb));return u(Fa,Ep(a.g,k,f,Fp,Gp),3);case 3:return u(Fa,Ep(a.h,l,f,Fp,Gp),4);case 4:return u(Fa,Ep(a.j,m,f,Fp,Gp),5);case 5:return u(Fa,Ep(a.i,n,f,Fp,Gp),2);case 2:D=0;z=[];if(a.h.length&&a.g.length)for(J=t(a.g),K=J.next();!K.done;K=J.next())for(P=K.value,R=t(a.h),ba=R.next();!ba.done;ba=R.next())aa=ba.value,Y=xg(P.drmInfos,aa.drmInfos),P.drmInfos.length&&aa.drmInfos.length&&
597
+ function yp(a,b,c){var d,e,f,g,h,k,l,m,n,p,q,v,w,x,y,D,z,B,F,G,H,I,J,K,P,R,ba,aa,Y,Da;return L(function(Fa){switch(Fa.g){case 1:d=qc;zp(b);Ap(b);Bp(b);Cp(b);if(!c&&1==b.length){e=b[0];a.g=e.yc;a.h=e.Wc;a.j=e.textStreams;a.i=e.imageStreams;Fa.B(2);break}f=-1;for(g=0;g<b.length;g++)h=b[g],a.m.has(h.id)||(a.m.add(h.id),-1==f&&(f=g));if(-1==f)return Fa["return"]();k=b.map(function(xa){return xa.yc});l=b.map(function(xa){return xa.Wc});m=b.map(function(xa){return xa.textStreams});n=b.map(function(xa){return xa.imageStreams});
598
+ p=t(m);for(q=p.next();!q.done;q=p.next())v=q.value,v.push(Dp(d.Z));w=t(n);for(x=w.next();!x.done;x=w.next())y=x.value,y.push(Dp(d.Tb));return u(Fa,Ep(a.g,k,f,Fp,Gp),3);case 3:return u(Fa,Ep(a.h,l,f,Fp,Gp),4);case 4:return u(Fa,Ep(a.j,m,f,Fp,Gp),5);case 5:return u(Fa,Ep(a.i,n,f,Fp,Gp),2);case 2:D=0;z=[];if(a.h.length&&a.g.length)for(J=t(a.g),K=J.next();!K.done;K=J.next())for(P=K.value,R=t(a.h),ba=R.next();!ba.done;ba=R.next())aa=ba.value,Y=xg(P.drmInfos,aa.drmInfos),P.drmInfos.length&&aa.drmInfos.length&&
599
599
  !Y.length||(Da=D++,z.push({id:Da,language:P.language,primary:P.primary,audio:P,video:aa,bandwidth:(P.bandwidth||0)+(aa.bandwidth||0),drmInfos:Y,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]}));else for(B=a.h.concat(a.g),F=t(B),G=F.next();!G.done;G=F.next())H=G.value,I=D++,z.push({id:I,language:H.language,primary:H.primary,audio:H.type==d.cb?H:null,video:H.type==d.Na?H:null,bandwidth:H.bandwidth||0,drmInfos:H.drmInfos,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});
600
600
  a.l=z;A(Fa)}})}function zp(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;for(var c=[],d=t(b.yc),e=d.next();!e.done;e=d.next()){e=e.value;for(var f=!1,g=t(c),h=g.next();!h.done;h=g.next())h=h.value,e.id!=h.id&&e.channelsCount==h.channelsCount&&e.language==h.language&&e.bandwidth==h.bandwidth&&e.label==h.label&&e.codecs==h.codecs&&e.mimeType==h.mimeType&&gb(e.roles,h.roles)&&e.audioSamplingRate==h.audioSamplingRate&&e.primary==h.primary&&(f=!0);f||c.push(e)}b.yc=c}}
601
601
  function Bp(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;for(var c=[],d=t(b.textStreams),e=d.next();!e.done;e=d.next()){e=e.value;for(var f=!1,g=t(c),h=g.next();!h.done;h=g.next())h=h.value,e.id!=h.id&&e.language==h.language&&e.label==h.label&&e.codecs==h.codecs&&e.mimeType==h.mimeType&&e.bandwidth==h.bandwidth&&gb(e.roles,h.roles)&&(f=!0);f||c.push(e)}b.textStreams=c}}
602
602
  function Ap(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;for(var c=[],d=t(b.Wc),e=d.next();!e.done;e=d.next()){e=e.value;for(var f=!1,g=t(c),h=g.next();!h.done;h=g.next())h=h.value,e.id!=h.id&&e.width==h.width&&e.frameRate==h.frameRate&&e.codecs==h.codecs&&e.mimeType==h.mimeType&&e.label==h.label&&gb(e.roles,h.roles)&&rf(e.closedCaptions,h.closedCaptions)&&e.bandwidth==h.bandwidth&&(f=!0);f||c.push(e)}b.Wc=c}}
603
603
  function Cp(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;for(var c=[],d=t(b.imageStreams),e=d.next();!e.done;e=d.next()){e=e.value;for(var f=!1,g=t(c),h=g.next();!h.done;h=g.next())h=h.value,e.id!=h.id&&e.width==h.width&&e.codecs==h.codecs&&e.mimeType==h.mimeType&&(f=!0);f||c.push(e)}b.imageStreams=c}}
604
- function Hp(a){var b,c,d,e,f,g,h,k,l,m,n,p,q,v,y,w,x,D,z,B,F,G,H,I,J,K,P;return L(function(R){switch(R.g){case 1:b=qc;if(1==a.length)return R["return"](a[0]);c=a.map(function(ba){return ba.filter(function(aa){return aa.type==b.cb})});d=a.map(function(ba){return ba.filter(function(aa){return aa.type==b.Na})});e=a.map(function(ba){return ba.filter(function(aa){return aa.type==b.Z})});f=a.map(function(ba){return ba.filter(function(aa){return aa.type==b.Tb})});g=t(e);for(h=g.next();!h.done;h=g.next())k=
605
- h.value,k.push(Ip(b.Z));l=t(f);for(m=l.next();!m.done;m=l.next())n=m.value,n.push(Ip(b.Tb));return u(R,Ep([],c,0,Jp,Kp),2);case 2:return p=R.h,u(R,Ep([],d,0,Jp,Kp),3);case 3:return q=R.h,u(R,Ep([],e,0,Jp,Kp),4);case 4:return v=R.h,u(R,Ep([],f,0,Jp,Kp),5);case 5:y=R.h;w=0;if(q.length&&p.length)for(F=t(p),G=F.next();!G.done;G=F.next())for(H=G.value,I=t(q),J=I.next();!J.done;J=I.next())K=J.value,P=w++,K.variantIds.push(P),H.variantIds.push(P);else for(x=q.concat(p),D=t(x),z=D.next();!z.done;z=D.next())B=
606
- z.value,B.variantIds=[w++];return R["return"](q.concat(p).concat(v).concat(y))}})}
607
- function Ep(a,b,c,d,e){var f,g,h,k,l,m,n,p,q,v,y,w,x,D,z,B,F,G,H,I,J;return L(function(K){switch(K.g){case 1:f=qc;g=[];for(h=0;h<b.length;h++)h>=c?g.push(new Set(b[h])):g.push(new Set);k=t(a);l=k.next();case 2:if(l.done){K.B(4);break}m=l.value;return u(K,Lp(m,b,c,e,g),5);case 5:n=K.h;if(!n)throw new N(2,4,4037);l=k.next();K.B(2);break;case 4:p=t(g);for(q=p.next();!q.done;q=p.next())for(v=q.value,y=t(v),w=y.next();!w.done;w=y.next())x=w.value,(D=Mp(x,b,d,e,g))&&a.push(D);z=t(g);for(q=z.next();!q.done;q=
608
- z.next())for(B=q.value,F={},G=t(B),w=G.next();!w.done;F={Va:F.Va},w=G.next())if(F.Va=w.value,H=F.Va.type==f.Z&&!F.Va.language,I=F.Va.type==f.Tb&&!F.Va.tilesLayout,!H&&!I&&(J=a.some(function(P){return function(R){return R.mimeType==P.Va.mimeType&&cd(R.codecs)==cd(P.Va.codecs)}}(F))))throw new N(2,4,4037);return K["return"](a)}})}
604
+ function Hp(a){var b,c,d,e,f,g,h,k,l,m,n,p,q,v,w,x,y,D,z,B,F,G,H,I,J,K,P;return L(function(R){switch(R.g){case 1:b=qc;if(1==a.length)return R["return"](a[0]);c=a.map(function(ba){return ba.filter(function(aa){return aa.type==b.cb})});d=a.map(function(ba){return ba.filter(function(aa){return aa.type==b.Na})});e=a.map(function(ba){return ba.filter(function(aa){return aa.type==b.Z})});f=a.map(function(ba){return ba.filter(function(aa){return aa.type==b.Tb})});g=t(e);for(h=g.next();!h.done;h=g.next())k=
605
+ h.value,k.push(Ip(b.Z));l=t(f);for(m=l.next();!m.done;m=l.next())n=m.value,n.push(Ip(b.Tb));return u(R,Ep([],c,0,Jp,Kp),2);case 2:return p=R.h,u(R,Ep([],d,0,Jp,Kp),3);case 3:return q=R.h,u(R,Ep([],e,0,Jp,Kp),4);case 4:return v=R.h,u(R,Ep([],f,0,Jp,Kp),5);case 5:w=R.h;x=0;if(q.length&&p.length)for(F=t(p),G=F.next();!G.done;G=F.next())for(H=G.value,I=t(q),J=I.next();!J.done;J=I.next())K=J.value,P=x++,K.variantIds.push(P),H.variantIds.push(P);else for(y=q.concat(p),D=t(y),z=D.next();!z.done;z=D.next())B=
606
+ z.value,B.variantIds=[x++];return R["return"](q.concat(p).concat(v).concat(w))}})}
607
+ function Ep(a,b,c,d,e){var f,g,h,k,l,m,n,p,q,v,w,x,y,D,z,B,F,G,H,I,J;return L(function(K){switch(K.g){case 1:f=qc;g=[];for(h=0;h<b.length;h++)h>=c?g.push(new Set(b[h])):g.push(new Set);k=t(a);l=k.next();case 2:if(l.done){K.B(4);break}m=l.value;return u(K,Lp(m,b,c,e,g),5);case 5:n=K.h;if(!n)throw new N(2,4,4037);l=k.next();K.B(2);break;case 4:p=t(g);for(q=p.next();!q.done;q=p.next())for(v=q.value,w=t(v),x=w.next();!x.done;x=w.next())y=x.value,(D=Mp(y,b,d,e,g))&&a.push(D);z=t(g);for(q=z.next();!q.done;q=
608
+ z.next())for(B=q.value,F={},G=t(B),x=G.next();!x.done;F={Wa:F.Wa},x=G.next())if(F.Wa=x.value,H=F.Wa.type==f.Z&&!F.Wa.language,I=F.Wa.type==f.Tb&&!F.Wa.tilesLayout,!H&&!I&&(J=a.some(function(P){return function(R){return R.mimeType==P.Wa.mimeType&&cd(R.codecs)==cd(P.Wa.codecs)}}(F))))throw new N(2,4,4037);return K["return"](a)}})}
609
609
  function Lp(a,b,c,d,e){return L(function(f){if(1==f.g)return Np(b,a),a.matchedStreams?a.segmentIndex?u(f,Op(a,c),2):f.B(2):f["return"](!1);Pp(a,c,d,e);return f["return"](!0)})}
610
610
  function Op(a,b){var c,d,e,f,g,h,k;return L(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 u(l,Promise.all(c),2)}if(a.segmentIndex instanceof gj)for(h=0;h<d.length;h++)k=d[h],k.segmentIndex&&h>=b&&a.segmentIndex.j.push(k.segmentIndex);A(l)})}
611
611
  function Mp(a,b,c,d,e){var f=c(a);Np(b,f);f.createSegmentIndex&&(f.createSegmentIndex=function(){return L(function(g){if(f.segmentIndex)return g.B(0);f.segmentIndex=new gj;return u(g,Op(f,0),0)})});if(!f.matchedStreams)return null;Pp(f,0,d,e);return f}function Pp(a,b,c,d){for(var e=a.matchedStreams,f=0;f<e.length;f++)if(f>=b){var g=e[f];c(a,g);var h=!0;"audio"==a.type&&0==vd(a.language,g.language)&&(h=!1);h&&d[f]["delete"](g)}}
@@ -626,29 +626,29 @@ function Xp(a,b,c){if(b==a&&a!=c)return Zp;if(c==a&&a!=b)return Yp;if(b>a){if(c<
626
626
  r.stop=function(){for(var a=t(Object.values(this.l)),b=a.next();!b.done;b=a.next())b=b.value,b.segmentIndex&&b.segmentIndex.release();this.j&&this.j.release();this.g=this.h=null;this.m=[];this.i=null;this.l={};this.j=null;null!=this.D&&(this.D.stop(),this.D=null);return this.o.destroy()};r.update=function(){var a=this,b;return L(function(c){if(1==c.g)return C(c,2),u(c,dq(a),4);if(2!=c.g)return va(c,0);b=E(c);if(!a.h||!b)return c["return"]();a.h.onError(b);A(c)})};r.onExpirationUpdated=function(){};
627
627
  function dq(a){var b,c,d,e,f,g,h;return L(function(k){if(1==k.g)return b=We(a.m,a.g.retryParameters),c=a.h.networkingEngine,a.h.modifyManifestRequest(b,{format:"d"}),d=Date.now(),e=c.request(0,b),Re(a.o,e),u(k,e.promise,2);if(3!=k.g){f=k.h;if(!a.h)return k["return"](0);f.uri&&!a.m.includes(f.uri)&&a.m.unshift(f.uri);return u(k,fq(a,f.data,f.uri),3)}g=Date.now();h=(g-d)/1E3;a.I.sample(1,h);return k["return"](h)})}
628
628
  function fq(a,b,c){var d,e,f,g,h;return L(function(k){if(1==k.g){d=Of(b,"MPD");if(!d)throw new N(2,4,4001,c);if(e=a.g.dash.disableXlinkProcessing)return k["return"](gq(a,d,c));f=a.g.dash.xlinkFailGracefully;g=To(d,a.g.retryParameters,f,c,a.h.networkingEngine);Re(a.o,g);return u(k,g.promise,2)}h=k.h;return k["return"](gq(a,h,c))})}
629
- function gq(a,b,c){var d,e,f,g,h,k,l,m,n,p,q,v,y,w,x,D,z,B,F,G,H,I,J,K,P,R,ba,aa,Y,Da,Fa,xa;return L(function(Ia){switch(Ia.g){case 1:(d=a.g.dash.manifestPreprocessor)&&d(b);e=[c];f=tf(b,"Location").map(zf).filter(Qb);0<f.length&&(g=kc(e,f),e=a.m=g);h=tf(b,"BaseURL");k=h.map(zf);l=kc(e,k);m=0;h&&h.length&&(m=Bf(h[0],"availabilityTimeOffset",Kf)||0);n=a.g.dash.ignoreMinBufferTime;p=0;n||(p=Bf(b,"minBufferTime",Df)||0);a.F=Bf(b,"minimumUpdatePeriod",Df,-1);q=Bf(b,"availabilityStartTime",Cf);v=Bf(b,
630
- "timeShiftBufferDepth",Df);y=a.g.dash.ignoreSuggestedPresentationDelay;w=null;y||(w=Bf(b,"suggestedPresentationDelay",Df));x=a.g.dash.ignoreMaxSegmentDuration;D=null;x||(D=Bf(b,"maxSegmentDuration",Df));z=b.getAttribute("type")||"static";if(a.i)for(B=a.i.presentationTimeline,F=t(Object.values(a.l)),G=F.next();!G.done;G=F.next())H=G.value,H.segmentIndex&&H.segmentIndex.eb(B.Qa());else I=a.g.defaultPresentationDelay||1.5*p,J=null!=w?w:I,B=new S(q,J,a.g.dash.autoCorrectDrift);B.pc("static"==z);(K=B.T())&&
631
- !isNaN(a.g.availabilityWindowOverride)&&(v=a.g.availabilityWindowOverride);null==v&&(v=Infinity);B.Yd(v);P=b.getAttribute("profiles")||"";R={Wa:"static"!=z,presentationTimeline:B,aa:null,U:null,ga:null,H:null,bandwidth:0,pe:!1,Ab:m,profiles:P.split(",")};ba=hq(a,R,l,b);aa=ba.duration;Y=ba.periods;"static"!=z&&ba.ie||B.Ja(aa||Infinity);a.u&&!a.C&&(Da=a.h.isAutoLowLatencyMode())&&(a.h.enableLowLatencyMode(),a.C=a.h.isLowLatencyMode());a.C?B.De(a.u):a.u&&Ua("Low-latency DASH live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details.");
632
- B.Hd(D||1);return u(Ia,yp(a.j,Y,R.Wa),2);case 2:if(a.i){a.i.variants=a.j.l;a.i.textStreams=a.j.j.slice();a.i.imageStreams=a.j.i;a.h.filter(a.i);Ia.B(3);break}a.i={presentationTimeline:B,variants:a.j.l,textStreams:a.j.j.slice(),imageStreams:a.j.i,offlineSessionIds:[],minBufferTime:p||0};if(!B.Ie()){Ia.B(4);break}Fa=tf(b,"UTCTiming");return u(Ia,iq(a,l,Fa),5);case 5:xa=Ia.h;if(!a.h)return Ia["return"]();B.Ee(xa);case 4:B.Bd();case 3:a.h.makeTextStreamsForClosedCaptions(a.i),A(Ia)}})}
633
- function hq(a,b,c,d){var e=Bf(d,"mediaPresentationDuration",Df),f=[],g=0;d=tf(d,"Period");for(var h=0;h<d.length;h++){var k=d[h],l=d[h+1],m=Bf(k,"start",Df,g),n=k.id,p=Bf(k,"duration",Df),q=null;if(l){var v=Bf(l,"start",Df);null!=v&&(q=v-m)}else null!=e&&(q=e-m);null==q&&(q=p);if(!(null!==a.s&&null!==n&&null!==m&&m<a.s)||a.L.includes(n)||h+1==d.length){null!==m&&(null===a.s||m>a.s)&&(a.s=m);g=jq(a,b,c,{start:m,duration:q,node:k,re:null==q||!l});f.push(g);b.aa.id&&q&&(a.N[b.aa.id]=q);if(null==q){g=
634
- null;break}g=m+q}}a.L=f.map(function(y){return y.id});return null!=e?{periods:f,duration:e,ie:!1}:{periods:f,duration:g,ie:!0}}
635
- function jq(a,b,c,d){b.aa=kq(d.node,null,c);b.U=d;b.aa.Ab=b.Ab;b.aa.id||(b.aa.id="__shaka_period_"+d.start);var e=tf(d.node,"EventStream");c=b.presentationTimeline.Qa();e=t(e);for(var f=e.next();!f.done;f=e.next())lq(a,d.start,d.duration,f.value,c);c=tf(d.node,"AdaptationSet").map(function(m){return mq(a,b,m)}).filter(Qb);if(b.Wa){d=[];e=t(c);for(f=e.next();!f.done;f=e.next()){f=t(f.value.Tf);for(var g=f.next();!g.done;g=f.next())d.push(g.value)}if(d.length!=(new Set(d)).size)throw new N(2,4,4018);
636
- }d=c.filter(function(m){return!m.ae});c=c.filter(function(m){return m.ae});c=t(c);for(e=c.next();!e.done;e=c.next()){e=e.value;f=e.ae.split(" ");g=t(d);for(var h=g.next();!h.done;h=g.next()){var k=h.value;if(f.includes(k.id)){h={};k=t(k.streams);for(var l=k.next();!l.done;h={wc:h.wc},l=k.next())h.wc=l.value,h.wc.trickModeVideo=e.streams.find(function(m){return function(n){return cd(m.wc.codecs)==cd(n.codecs)}}(h))}}}e=a.g.disableAudio?[]:nq(d,"audio");g=a.g.disableVideo?[]:nq(d,"video");f=a.g.disableText?
629
+ function gq(a,b,c){var d,e,f,g,h,k,l,m,n,p,q,v,w,x,y,D,z,B,F,G,H,I,J,K,P,R,ba,aa,Y,Da,Fa,xa;return L(function(Ja){switch(Ja.g){case 1:(d=a.g.dash.manifestPreprocessor)&&d(b);e=[c];f=tf(b,"Location").map(zf).filter(Qb);0<f.length&&(g=kc(e,f),e=a.m=g);h=tf(b,"BaseURL");k=h.map(zf);l=kc(e,k);m=0;h&&h.length&&(m=Bf(h[0],"availabilityTimeOffset",Kf)||0);n=a.g.dash.ignoreMinBufferTime;p=0;n||(p=Bf(b,"minBufferTime",Df)||0);a.F=Bf(b,"minimumUpdatePeriod",Df,-1);q=Bf(b,"availabilityStartTime",Cf);v=Bf(b,
630
+ "timeShiftBufferDepth",Df);w=a.g.dash.ignoreSuggestedPresentationDelay;x=null;w||(x=Bf(b,"suggestedPresentationDelay",Df));y=a.g.dash.ignoreMaxSegmentDuration;D=null;y||(D=Bf(b,"maxSegmentDuration",Df));z=b.getAttribute("type")||"static";if(a.i)for(B=a.i.presentationTimeline,F=t(Object.values(a.l)),G=F.next();!G.done;G=F.next())H=G.value,H.segmentIndex&&H.segmentIndex.eb(B.Ra());else I=a.g.defaultPresentationDelay||1.5*p,J=null!=x?x:I,B=new S(q,J,a.g.dash.autoCorrectDrift);B.pc("static"==z);(K=B.U())&&
631
+ !isNaN(a.g.availabilityWindowOverride)&&(v=a.g.availabilityWindowOverride);null==v&&(v=Infinity);B.Zd(v);P=b.getAttribute("profiles")||"";R={Pa:"static"!=z,presentationTimeline:B,aa:null,T:null,ga:null,H:null,bandwidth:0,qe:!1,Ab:m,profiles:P.split(",")};ba=hq(a,R,l,b);aa=ba.duration;Y=ba.periods;"static"!=z&&ba.je||B.Ja(aa||Infinity);a.u&&!a.C&&(Da=a.h.isAutoLowLatencyMode())&&(a.h.enableLowLatencyMode(),a.C=a.h.isLowLatencyMode());a.C?B.De(a.u):a.u&&Ua("Low-latency DASH live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details.");
632
+ B.Id(D||1);return u(Ja,yp(a.j,Y,R.Pa),2);case 2:if(a.i){a.i.variants=a.j.l;a.i.textStreams=a.j.j.slice();a.i.imageStreams=a.j.i;a.h.filter(a.i);Ja.B(3);break}a.i={presentationTimeline:B,variants:a.j.l,textStreams:a.j.j.slice(),imageStreams:a.j.i,offlineSessionIds:[],minBufferTime:p||0};if(!B.Ie()){Ja.B(4);break}Fa=tf(b,"UTCTiming");return u(Ja,iq(a,l,Fa),5);case 5:xa=Ja.h;if(!a.h)return Ja["return"]();B.Ee(xa);case 4:B.Cd();case 3:a.h.makeTextStreamsForClosedCaptions(a.i),A(Ja)}})}
633
+ function hq(a,b,c,d){var e=Bf(d,"mediaPresentationDuration",Df),f=[],g=0;d=tf(d,"Period");for(var h=0;h<d.length;h++){var k=d[h],l=d[h+1],m=Bf(k,"start",Df,g),n=k.id,p=Bf(k,"duration",Df),q=null;if(l){var v=Bf(l,"start",Df);null!=v&&(q=v-m)}else null!=e&&(q=e-m);null==q&&(q=p);if(!(null!==a.s&&null!==n&&null!==m&&m<a.s)||a.L.includes(n)||h+1==d.length){null!==m&&(null===a.s||m>a.s)&&(a.s=m);g=jq(a,b,c,{start:m,duration:q,node:k,td:null==q||!l});f.push(g);b.aa.id&&q&&(a.N[b.aa.id]=q);if(null==q){g=
634
+ null;break}g=m+q}}a.L=f.map(function(w){return w.id});return null!=e?{periods:f,duration:e,je:!1}:{periods:f,duration:g,je:!0}}
635
+ function jq(a,b,c,d){b.aa=kq(d.node,null,c);b.T=d;b.aa.Ab=b.Ab;b.aa.id||(b.aa.id="__shaka_period_"+d.start);var e=tf(d.node,"EventStream");c=b.presentationTimeline.Ra();e=t(e);for(var f=e.next();!f.done;f=e.next())lq(a,d.start,d.duration,f.value,c);c=tf(d.node,"AdaptationSet").map(function(m){return mq(a,b,m)}).filter(Qb);if(b.Pa){d=[];e=t(c);for(f=e.next();!f.done;f=e.next()){f=t(f.value.Tf);for(var g=f.next();!g.done;g=f.next())d.push(g.value)}if(d.length!=(new Set(d)).size)throw new N(2,4,4018);
636
+ }d=c.filter(function(m){return!m.be});c=c.filter(function(m){return m.be});c=t(c);for(e=c.next();!e.done;e=c.next()){e=e.value;f=e.be.split(" ");g=t(d);for(var h=g.next();!h.done;h=g.next()){var k=h.value;if(f.includes(k.id)){h={};k=t(k.streams);for(var l=k.next();!l.done;h={wc:h.wc},l=k.next())h.wc=l.value,h.wc.trickModeVideo=e.streams.find(function(m){return function(n){return cd(m.wc.codecs)==cd(n.codecs)}}(h))}}}e=a.g.disableAudio?[]:nq(d,"audio");g=a.g.disableVideo?[]:nq(d,"video");f=a.g.disableText?
637
637
  []:nq(d,pc);c=a.g.disableThumbnails?[]:nq(d,"image");if(!g.length&&!e.length)throw new N(2,4,4004);d=[];e=t(e);for(h=e.next();!h.done;h=e.next())d.push.apply(d,ja(h.value.streams));e=[];g=t(g);for(h=g.next();!h.done;h=g.next())e.push.apply(e,ja(h.value.streams));g=[];f=t(f);for(h=f.next();!h.done;h=f.next())g.push.apply(g,ja(h.value.streams));f=[];c=t(c);for(h=c.next();!h.done;h=c.next())f.push.apply(f,ja(h.value.streams));return{id:b.aa.id,yc:d,Wc:e,textStreams:g,imageStreams:f}}
638
638
  function nq(a,b){return a.filter(function(c){return c.contentType==b})}
639
639
  function mq(a,b,c){function d(G){switch(G){case 1:case 6:case 13:case 14:case 15:return"SDR";case 16:return"PQ";case 18:return"HLG"}}b.ga=kq(c,b.aa,null);var e=!1,f=tf(c,"Role"),g=f.map(function(G){return G.getAttribute("value")}).filter(Qb),h=void 0,k=b.ga.contentType==pc;k&&(h="subtitle");f=t(f);for(var l=f.next();!l.done;l=f.next()){l=l.value;var m=l.getAttribute("schemeIdUri");if(null==m||"urn:mpeg:dash:role:2011"==m)switch(l=l.getAttribute("value"),l){case "main":e=!0;break;case "caption":case "subtitle":h=
640
640
  l}}var n;m=tf(c,"EssentialProperty");f=null;l=!1;m=t(m);for(var p=m.next();!p.done;p=m.next()){p=p.value;var q=p.getAttribute("schemeIdUri");"http://dashif.org/guidelines/trickmode"==q?f=p.getAttribute("value"):"urn:mpeg:mpegB:cicp:TransferCharacteristics"==q?n=d(parseInt(p.getAttribute("value"),10)):l=!0}m=tf(c,"SupplementalProperty");m=t(m);for(p=m.next();!p.done;p=m.next())p=p.value,"urn:mpeg:mpegB:cicp:TransferCharacteristics"==p.getAttribute("schemeIdUri")&&(n=d(parseInt(p.getAttribute("value"),
641
- 10)));m=tf(c,"Accessibility");var v=new Map;m=t(m);for(p=m.next();!p.done;p=m.next())if(q=p.value,p=q.getAttribute("schemeIdUri"),q=q.getAttribute("value"),"urn:scte:dash:cc:cea-608:2015"==p)if(p=1,null!=q){q=q.split(";");for(var y=t(q),w=y.next();!w.done;w=y.next()){var x=w.value,D=w=void 0;x.includes("=")?(x=x.split("="),w=x[0].startsWith("CC")?x[0]:"CC"+x[0],D=x[1]||"und"):(w="CC"+p,2==q.length?p+=2:p++,D=x);v.set(w,rd(D))}}else v.set("CC1","und");else if("urn:scte:dash:cc:cea-708:2015"==p)if(p=
642
- 1,null!=q)for(q=t(q.split(";")),w=q.next();!w.done;w=q.next())w=w.value,x=y=void 0,w.includes("=")?(w=w.split("="),y="svc"+w[0],x=w[1].split(",")[0].split(":").pop()):(y="svc"+p,p++,x=w),v.set(y,rd(x));else v.set("svc1","und");else"urn:mpeg:dash:role:2011"==p&&null!=q&&(g.push(q),"captions"==q&&(h="caption"));if(l)return null;l=tf(c,"ContentProtection");var z=Eo(l,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI),B=rd(c.getAttribute("lang")||"und"),F=c.getAttribute("label");(l=tf(c,"Label"))&&l.length&&
641
+ 10)));m=tf(c,"Accessibility");var v=new Map;m=t(m);for(p=m.next();!p.done;p=m.next())if(q=p.value,p=q.getAttribute("schemeIdUri"),q=q.getAttribute("value"),"urn:scte:dash:cc:cea-608:2015"==p)if(p=1,null!=q){q=q.split(";");for(var w=t(q),x=w.next();!x.done;x=w.next()){var y=x.value,D=x=void 0;y.includes("=")?(y=y.split("="),x=y[0].startsWith("CC")?y[0]:"CC"+y[0],D=y[1]||"und"):(x="CC"+p,2==q.length?p+=2:p++,D=y);v.set(x,rd(D))}}else v.set("CC1","und");else if("urn:scte:dash:cc:cea-708:2015"==p)if(p=
642
+ 1,null!=q)for(q=t(q.split(";")),x=q.next();!x.done;x=q.next())x=x.value,y=w=void 0,x.includes("=")?(x=x.split("="),w="svc"+x[0],y=x[1].split(",")[0].split(":").pop()):(w="svc"+p,p++,y=x),v.set(w,rd(y));else v.set("svc1","und");else"urn:mpeg:dash:role:2011"==p&&null!=q&&(g.push(q),"captions"==q&&(h="caption"));if(l)return null;l=tf(c,"ContentProtection");var z=Eo(l,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI),B=rd(c.getAttribute("lang")||"und"),F=c.getAttribute("label");(l=tf(c,"Label"))&&l.length&&
643
643
  (l=l[0],l.textContent&&(F=l.textContent));l=tf(c,"Representation");c=l.map(function(G){if(G=oq(a,b,z,h,B,F,e,g,v,G))G.hdr=G.hdr||n;return G}).filter(function(G){return!!G});if(0==c.length){f="image"==b.ga.contentType;if(a.g.dash.ignoreEmptyAdaptationSet||k||f)return null;throw new N(2,4,4003);}if(!b.ga.contentType||"application"==b.ga.contentType)for(b.ga.contentType=pq(c[0].mimeType,c[0].codecs),k=t(c),m=k.next();!m.done;m=k.next())m.value.type=b.ga.contentType;k=t(c);for(m=k.next();!m.done;m=k.next())for(m=
644
- m.value,p=t(z.drmInfos),q=p.next();!q.done;q=p.next())q=q.value,q.keyIds=q.keyIds&&m.keyIds?new Set([].concat(ja(q.keyIds),ja(m.keyIds))):q.keyIds||m.keyIds;k=l.map(function(G){return G.getAttribute("id")}).filter(Qb);return{id:b.ga.id||"__fake__"+a.G++,contentType:b.ga.contentType,language:B,Pg:e,streams:c,drmInfos:z.drmInfos,ae:f,Tf:k}}
645
- function oq(a,b,c,d,e,f,g,h,k,l){b.H=kq(l,b.ga,null);a.u=Math.min(a.u,b.H.Ab);if(!qq(b.H))return null;var m=b.U.start;b.bandwidth=Bf(l,"bandwidth",If)||0;var n=b.H.contentType,p=n==pc||"application"==n;n="image"==n;try{var q=function(H,I,J){return rq(a,H,I,J)};if(b.H.nc)var v=fp(b,q);else if(b.H.$a)v=lp(b,a.l);else if(b.H.oc)v=qp(b,q,a.l,!!a.i,a.g.dash.initialSegmentLimit,a.N);else{var y=b.H.za,w=b.U.duration||0;v={Cb:function(){return Promise.resolve(fj(m,w,y))}}}}catch(H){if((p||n)&&4002==H.code)return null;
646
- throw H;}q=tf(l,"ContentProtection");q=Ho(q,c,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI);q=new Set(q?[q]:[]);var x=!1;tf(l,"SupplementalProperty").some(function(H){return"tag:dolby.com,2018:dash:EC3_ExtensionType:2018"==H.getAttribute("schemeIdUri")&&"JOC"==H.getAttribute("value")})&&(x=!0);var D=!1;p&&(D=h.includes("forced_subtitle")||h.includes("forced-subtitle"));var z;if(n&&((l=tf(l,"EssentialProperty").find(function(H){return["http://dashif.org/thumbnail_tile","http://dashif.org/guidelines/thumbnail_tile"].includes(H.getAttribute("schemeIdUri"))}))&&
647
- (z=l.getAttribute("value")),!z))return null;var B;l=b.H.codecs;b.profiles.includes("http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10")&&(l.includes("hvc1.2.4.L153.B0")||l.includes("hev1.2.4.L153.B0"))&&(B="PQ");var F=b.H.id?b.aa.id+","+b.H.id:"",G={id:a.G++,originalId:b.H.id,createSegmentIndex:function(){var H,I,J;return L(function(K){if(1==K.g){I=(H=F&&b.Wa&&a.l[F])?a.l[F]:G;if(I.segmentIndex)return K.B(0);J=I;return u(K,v.Cb(),3)}J.segmentIndex=K.h;A(K)})},closeSegmentIndex:function(){G.segmentIndex&&
648
- (G.segmentIndex.release(),G.segmentIndex=null)},segmentIndex:null,mimeType:b.H.mimeType,codecs:b.H.codecs,frameRate:b.H.frameRate,pixelAspectRatio:b.H.pixelAspectRatio,bandwidth:b.bandwidth,width:b.H.width,height:b.H.height,kind:d,encrypted:0<c.drmInfos.length,drmInfos:c.drmInfos,keyIds:q,language:e,label:f,type:b.ga.contentType,primary:g,trickModeVideo:null,emsgSchemeIdUris:b.H.emsgSchemeIdUris,roles:h,forced:D,channelsCount:b.H.Nc,audioSamplingRate:b.H.audioSamplingRate,spatialAudio:x,closedCaptions:k,
649
- hdr:B,tilesLayout:z,matchedStreams:[]};F&&b.Wa&&!a.l[F]&&(a.l[F]=G);return G}function cq(a){var b,c;L(function(d){switch(d.g){case 1:return b=0,C(d,2),u(d,dq(a),4);case 4:b=d.h;va(d,3);break;case 2:c=E(d),a.h&&(c.severity=1,a.h.onError(c));case 3:if(!a.h)return d["return"]();eq(a,b);A(d)}})}function eq(a,b){0>a.F||a.D.S(Math.max(3,a.F-b,Qa(a.I)))}
644
+ m.value,p=t(z.drmInfos),q=p.next();!q.done;q=p.next())q=q.value,q.keyIds=q.keyIds&&m.keyIds?new Set([].concat(ja(q.keyIds),ja(m.keyIds))):q.keyIds||m.keyIds;k=l.map(function(G){return G.getAttribute("id")}).filter(Qb);return{id:b.ga.id||"__fake__"+a.G++,contentType:b.ga.contentType,language:B,Pg:e,streams:c,drmInfos:z.drmInfos,be:f,Tf:k}}
645
+ function oq(a,b,c,d,e,f,g,h,k,l){b.H=kq(l,b.ga,null);a.u=Math.min(a.u,b.H.Ab);if(!qq(b.H))return null;var m=b.T.start;b.bandwidth=Bf(l,"bandwidth",If)||0;var n=b.H.contentType,p=n==pc||"application"==n;n="image"==n;try{var q=function(H,I,J){return rq(a,H,I,J)};if(b.H.nc)var v=fp(b,q);else if(b.H.$a)v=lp(b,a.l);else if(b.H.oc)v=qp(b,q,a.l,!!a.i,a.g.dash.initialSegmentLimit,a.N);else{var w=b.H.za,x=b.T.duration||0;v={Cb:function(){return Promise.resolve(fj(m,x,w))}}}}catch(H){if((p||n)&&4002==H.code)return null;
646
+ throw H;}q=tf(l,"ContentProtection");q=Ho(q,c,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI);q=new Set(q?[q]:[]);var y=!1;tf(l,"SupplementalProperty").some(function(H){return"tag:dolby.com,2018:dash:EC3_ExtensionType:2018"==H.getAttribute("schemeIdUri")&&"JOC"==H.getAttribute("value")})&&(y=!0);var D=!1;p&&(D=h.includes("forced_subtitle")||h.includes("forced-subtitle"));var z;if(n&&((l=tf(l,"EssentialProperty").find(function(H){return["http://dashif.org/thumbnail_tile","http://dashif.org/guidelines/thumbnail_tile"].includes(H.getAttribute("schemeIdUri"))}))&&
647
+ (z=l.getAttribute("value")),!z))return null;var B;l=b.H.codecs;b.profiles.includes("http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10")&&(l.includes("hvc1.2.4.L153.B0")||l.includes("hev1.2.4.L153.B0"))&&(B="PQ");var F=b.H.id?b.aa.id+","+b.H.id:"",G={id:a.G++,originalId:b.H.id,createSegmentIndex:function(){var H,I,J;return L(function(K){if(1==K.g){I=(H=F&&b.Pa&&a.l[F])?a.l[F]:G;if(I.segmentIndex)return K.B(0);J=I;return u(K,v.Cb(),3)}J.segmentIndex=K.h;A(K)})},closeSegmentIndex:function(){G.segmentIndex&&
648
+ (G.segmentIndex.release(),G.segmentIndex=null)},segmentIndex:null,mimeType:b.H.mimeType,codecs:b.H.codecs,frameRate:b.H.frameRate,pixelAspectRatio:b.H.pixelAspectRatio,bandwidth:b.bandwidth,width:b.H.width,height:b.H.height,kind:d,encrypted:0<c.drmInfos.length,drmInfos:c.drmInfos,keyIds:q,language:e,label:f,type:b.ga.contentType,primary:g,trickModeVideo:null,emsgSchemeIdUris:b.H.emsgSchemeIdUris,roles:h,forced:D,channelsCount:b.H.Nc,audioSamplingRate:b.H.audioSamplingRate,spatialAudio:y,closedCaptions:k,
649
+ hdr:B,tilesLayout:z,matchedStreams:[]};F&&b.Pa&&!a.l[F]&&(a.l[F]=G);return G}function cq(a){var b,c;L(function(d){switch(d.g){case 1:return b=0,C(d,2),u(d,dq(a),4);case 4:b=d.h;va(d,3);break;case 2:c=E(d),a.h&&(c.severity=1,a.h.onError(c));case 3:if(!a.h)return d["return"]();eq(a,b);A(d)}})}function eq(a,b){0>a.F||a.D.S(Math.max(3,a.F-b,Qa(a.I)))}
650
650
  function kq(a,b,c){b=b||{contentType:"",mimeType:"",codecs:"",emsgSchemeIdUris:[],frameRate:void 0,pixelAspectRatio:void 0,Nc:null,audioSamplingRate:null,Ab:0};c=c||b.za;var d=tf(a,"BaseURL"),e=d.map(zf),f=a.getAttribute("contentType")||b.contentType,g=a.getAttribute("mimeType")||b.mimeType,h=a.getAttribute("codecs")||b.codecs,k=Bf(a,"frameRate",Lf)||b.frameRate,l=a.getAttribute("sar")||b.pixelAspectRatio,m=tf(a,"InbandEventStream"),n=b.emsgSchemeIdUris.slice();m=t(m);for(var p=m.next();!p.done;p=
651
- m.next())p=p.value.getAttribute("schemeIdUri"),n.includes(p)||n.push(p);m=tf(a,"AudioChannelConfiguration");m=sq(m)||b.Nc;p=Bf(a,"audioSamplingRate",Jf)||b.audioSamplingRate;f||(f=pq(g,h));var q=sf(a,"SegmentBase"),v=sf(a,"SegmentTemplate"),y=q?Bf(q,"availabilityTimeOffset",Kf)||0:0,w=v?Bf(v,"availabilityTimeOffset",Kf)||0:0;d=d&&d.length?Bf(d[0],"availabilityTimeOffset",Kf)||0:0;d=b.Ab+d+y+w;return{za:kc(c,e),nc:q||b.nc,$a:sf(a,"SegmentList")||b.$a,oc:v||b.oc,width:Bf(a,"width",Jf)||b.width,height:Bf(a,
651
+ m.next())p=p.value.getAttribute("schemeIdUri"),n.includes(p)||n.push(p);m=tf(a,"AudioChannelConfiguration");m=sq(m)||b.Nc;p=Bf(a,"audioSamplingRate",Jf)||b.audioSamplingRate;f||(f=pq(g,h));var q=sf(a,"SegmentBase"),v=sf(a,"SegmentTemplate"),w=q?Bf(q,"availabilityTimeOffset",Kf)||0:0,x=v?Bf(v,"availabilityTimeOffset",Kf)||0:0;d=d&&d.length?Bf(d[0],"availabilityTimeOffset",Kf)||0:0;d=b.Ab+d+w+x;return{za:kc(c,e),nc:q||b.nc,$a:sf(a,"SegmentList")||b.$a,oc:v||b.oc,width:Bf(a,"width",Jf)||b.width,height:Bf(a,
652
652
  "height",Jf)||b.height,contentType:f,mimeType:g,codecs:h,frameRate:k,pixelAspectRatio:l,emsgSchemeIdUris:n,id:a.getAttribute("id"),Nc:m,audioSamplingRate:p,Ab:d}}
653
653
  function sq(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){var c=b.value;if(b=c.getAttribute("schemeIdUri"))if(c=c.getAttribute("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=
654
654
  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 qq(a){var b=a.nc?1:0;b+=a.$a?1:0;b+=a.oc?1:0;if(0==b)return a.contentType==pc||"application"==a.contentType?!0:!1;1!=b&&(a.nc&&(a.$a=null),a.oc=null);return!0}
@@ -666,65 +666,65 @@ var Kq="EXT-X-TARGETDURATION EXT-X-MEDIA-SEQUENCE EXT-X-DISCONTINUITY-SEQUENCE E
666
666
  M("shaka.net.DataUriPlugin",Mq);Mq.parse=Nq;Te("data",Nq);function Pq(){var a=this;this.g=this.i=null;this.Ga=1;this.o=new Map;this.u=new Map;this.ya=new Set;this.h=new Map;this.j=null;this.N="";this.da=new Hq;this.xa=0;this.C=new O(function(){Qq(a)});this.m=Rq;this.D=null;this.fa=0;this.G=Infinity;this.ca=this.ka=0;this.F=new Qe;this.W=[];this.L=new Map;this.Ma=!1;this.s=new Map;this.V=null;this.ea=new Map;this.I=new Map;this.l=!1}r=Pq.prototype;r.configure=function(a){this.g=a};
667
667
  r.start=function(a,b){var c=this,d,e;return L(function(f){if(1==f.g)return c.i=b,c.l=b.isLowLatencyMode(),u(f,Sq(c,a),2);if(3!=f.g)return d=f.h,c.N=d.uri,u(f,Tq(c,d.data),3);e=c.xa;0<e&&c.C.S(e);return f["return"](c.D)})};r.stop=function(){this.C&&(this.C.stop(),this.C=null);var a=[];this.F&&(a.push(this.F.destroy()),this.F=null);this.g=this.i=null;this.ya.clear();this.D=null;this.h.clear();this.u.clear();this.s.clear();this.o.clear();return Promise.all(a)};
668
668
  r.update=function(){var a=this,b,c,d;return L(function(e){if(1==e.g){if(a.m==Rq)return e["return"]();b=[];a.V=null;c=Array.from(a.h.values());return c.length?u(e,Uq(a,c[0]),2):e.B(2)}for(d=1;d<c.length;d++)b.push(Uq(a,c[d]));return u(e,Promise.all(b),0)})};
669
- function Uq(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v;return L(function(y){if(1==y.g)return c=Vq,d=b.Me,e=new Xb(d),a.l&&b.Re&&$b(e,new bc("_HLS_skip=YES")),u(y,Sq(a,e.toString()),2);if(3!=y.g){f=y.h;g=Iq(a.da,f.data,f.uri);if(1!=g.type)throw new N(2,4,4017);h=zq(g.g,"EXT-X-DEFINE");k=Wq(a,h);l=b.stream;return u(y,Xq(a,b.Vc,g,l.type,l.mimeType,b.Ed,k,b.Ye,l.codecs,l.bandwidth),3)}m=y.h;l.segmentIndex.Gb(m,a.j.Qa());m.length&&(n=Cq(g.g,"EXT-X-MEDIA-SEQUENCE",0),p=b.Ed.get(n),l.segmentIndex.eb(p));q=m[m.length-
670
- 1];if(v=Bq(g.g,"EXT-X-ENDLIST"))Yq(a,c.Le),a.j.Ja(q.endTime);A(y)})}r.onExpirationUpdated=function(){};
671
- function Tq(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v,y,w,x,D,z,B,F,G,H,I,J,K,P,R,ba,aa,Y,Da,Fa,xa,Ia,Rb,nd;return L(function(Ya){switch(Ya.g){case 1:c=Iq(a.da,b,a.N);if(0!=c.type)throw new N(2,4,4022);d=zq(c.g,"EXT-X-DEFINE");Zq(a,d);e=zq(c.g,"EXT-X-MEDIA");f=zq(c.g,"EXT-X-STREAM-INF");g=zq(c.g,"EXT-X-IMAGE-STREAM-INF");$q(a,f);h=zq(c.g,"EXT-X-SESSION-DATA");k=t(h);for(l=k.next();!l.done;l=k.next())if(m=l.value,n=Z(m,"DATA-ID"),p=Z(m,"URI"),q=Z(m,"LANGUAGE"),v=Z(m,"VALUE"),y=(new Map).set("id",n),p&&y.set("uri",
672
- kc([a.N],[p])[0]),q&&y.set("language",q),v&&y.set("value",v),w=new Q("sessiondata",y),a.i)a.i.onEvent(w);return u(Ya,ar(a,e),2);case 2:return br(a,e),u(Ya,cr(a,f),3);case 3:return x=Ya.h,u(Ya,dr(a,e),4);case 4:return D=Ya.h,u(Ya,er(a,g),5);case 5:z=Ya.h;if(!a.i)throw new N(2,7,7001);if(a.Ma&&0==x.length)throw new N(2,4,4034);F=B=Infinity;G=t(a.h.values());for(H=G.next();!H.done;H=G.next())I=H.value,B=Math.min(B,I.se),"text"!=I.stream.type&&(F=Math.min(F,I.Gf-I.se));a.m!=Rq?(a.j=new S(0,a.g.defaultPresentationDelay?
673
- a.g.defaultPresentationDelay:a.ca?a.ca:3*a.fa),a.j.pc(!1)):(a.j=new S(null,0),a.j.pc(!0));if(a.m!=Rq)a.xa=a.G,J=Vq,a.m==J.Ke&&(K=a.j.Sc,isNaN(a.g.availabilityWindowOverride)||(K=a.g.availabilityWindowOverride),a.j.Yd(K));else for(a.j.Ja(F),a.j.offset(-B),P=t(a.h.values()),H=P.next();!H.done;H=P.next())R=H.value,R.stream.segmentIndex.offset(-B),R.stream.segmentIndex.Xa(0,F);a.W=[];ba=[];aa=t(x);for(Y=aa.next();!Y.done;Y=aa.next())for(Da=Y.value,Fa=t([Da.video,Da.audio]),xa=Fa.next();!xa.done;xa=Fa.next())(Ia=
674
- xa.value)&&ba.push(Ia);return u(Ya,Promise.all(ba.map(function(Gf){return L(function(Ec){return u(Ec,Gf.createSegmentIndex(),0)})})),6);case 6:Rb=t(ba);for(xa=Rb.next();!xa.done;xa=Rb.next())nd=xa.value,a.W.push(nd.segmentIndex.K);fr(a);a.j.Bd();a.D={presentationTimeline:a.j,variants:x,textStreams:D,imageStreams:z,offlineSessionIds:[],minBufferTime:0};a.i.makeTextStreamsForClosedCaptions(a.D);A(Ya)}})}
669
+ function Uq(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v;return L(function(w){if(1==w.g)return c=Vq,d=b.Me,e=new Xb(d),a.l&&b.Re&&$b(e,new bc("_HLS_skip=YES")),u(w,Sq(a,e.toString()),2);if(3!=w.g){f=w.h;g=Iq(a.da,f.data,f.uri);if(1!=g.type)throw new N(2,4,4017);h=zq(g.g,"EXT-X-DEFINE");k=Wq(a,h);l=b.stream;return u(w,Xq(a,b.Vc,g,l.type,l.mimeType,b.Fd,k,b.Ye,l.codecs,l.bandwidth),3)}m=w.h;l.segmentIndex.Gb(m,a.j.Ra());m.length&&(n=Cq(g.g,"EXT-X-MEDIA-SEQUENCE",0),p=b.Fd.get(n),l.segmentIndex.eb(p));q=m[m.length-
670
+ 1];if(v=Bq(g.g,"EXT-X-ENDLIST"))Yq(a,c.Le),a.j.Ja(q.endTime);A(w)})}r.onExpirationUpdated=function(){};
671
+ function Tq(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v,w,x,y,D,z,B,F,G,H,I,J,K,P,R,ba,aa,Y,Da,Fa,xa,Ja,Rb,nd;return L(function(Ya){switch(Ya.g){case 1:c=Iq(a.da,b,a.N);if(0!=c.type)throw new N(2,4,4022);d=zq(c.g,"EXT-X-DEFINE");Zq(a,d);e=zq(c.g,"EXT-X-MEDIA");f=zq(c.g,"EXT-X-STREAM-INF");g=zq(c.g,"EXT-X-IMAGE-STREAM-INF");$q(a,f);h=zq(c.g,"EXT-X-SESSION-DATA");k=t(h);for(l=k.next();!l.done;l=k.next())if(m=l.value,n=Z(m,"DATA-ID"),p=Z(m,"URI"),q=Z(m,"LANGUAGE"),v=Z(m,"VALUE"),w=(new Map).set("id",n),p&&w.set("uri",
672
+ kc([a.N],[p])[0]),q&&w.set("language",q),v&&w.set("value",v),x=new Q("sessiondata",w),a.i)a.i.onEvent(x);return u(Ya,ar(a,e),2);case 2:return br(a,e),u(Ya,cr(a,f),3);case 3:return y=Ya.h,u(Ya,dr(a,e),4);case 4:return D=Ya.h,u(Ya,er(a,g),5);case 5:z=Ya.h;if(!a.i)throw new N(2,7,7001);if(a.Ma&&0==y.length)throw new N(2,4,4034);F=B=Infinity;G=t(a.h.values());for(H=G.next();!H.done;H=G.next())I=H.value,B=Math.min(B,I.se),"text"!=I.stream.type&&(F=Math.min(F,I.Gf-I.se));a.m!=Rq?(a.j=new S(0,a.g.defaultPresentationDelay?
673
+ a.g.defaultPresentationDelay:a.ca?a.ca:3*a.fa),a.j.pc(!1)):(a.j=new S(null,0),a.j.pc(!0));if(a.m!=Rq)a.xa=a.G,J=Vq,a.m==J.Ke&&(K=a.j.Sc,isNaN(a.g.availabilityWindowOverride)||(K=a.g.availabilityWindowOverride),a.j.Zd(K));else for(a.j.Ja(F),a.j.offset(-B),P=t(a.h.values()),H=P.next();!H.done;H=P.next())R=H.value,R.stream.segmentIndex.offset(-B),R.stream.segmentIndex.Xa(0,F);a.W=[];ba=[];aa=t(y);for(Y=aa.next();!Y.done;Y=aa.next())for(Da=Y.value,Fa=t([Da.video,Da.audio]),xa=Fa.next();!xa.done;xa=Fa.next())(Ja=
674
+ xa.value)&&ba.push(Ja);return u(Ya,Promise.all(ba.map(function(Gf){return L(function(Ec){return u(Ec,Gf.createSegmentIndex(),0)})})),6);case 6:Rb=t(ba);for(xa=Rb.next();!xa.done;xa=Rb.next())nd=xa.value,a.W.push(nd.segmentIndex.K);fr(a);a.j.Cd();a.D={presentationTimeline:a.j,variants:y,textStreams:D,imageStreams:z,offlineSessionIds:[],minBufferTime:0};a.i.makeTextStreamsForClosedCaptions(a.D);A(Ya)}})}
675
675
  function Zq(a,b){for(var c=t(b),d=c.next();!d.done;d=c.next()){var e=d.value;d=Z(e,"NAME");e=Z(e,"VALUE");d&&e&&(a.o.has(d)||a.o.set(d,e))}}function Wq(a,b){for(var c=new Map,d=t(b),e=d.next();!e.done;e=d.next()){var f=e.value;e=Z(f,"NAME");var g=Z(f,"VALUE");f=Z(f,"IMPORT");e&&g&&c.set(e,g);f&&(e=a.o.get(f))&&c.set(f,e)}return c}
676
676
  function $q(a,b){for(var c=t(b),d=c.next();!d.done;d=c.next()){var e=d.value,f=Z(e,"AUDIO");d=Z(e,"VIDEO");var g=Z(e,"SUBTITLES");e=gr(a,e);if(g){var h=nc(pc,e);a.s.set(g,h);fb(e,h)}f&&(g=nc("audio",e),g||(g=a.g.hls.defaultAudioCodec),a.s.set(f,g));d&&(f=nc("video",e),f||(f=a.g.hls.defaultVideoCodec),a.s.set(d,f))}}
677
- function dr(a,b){var c,d,e,f,g,h,k,l,m,n,p,q;return L(function(v){if(1==v.g)return c=Aq(b,"SUBTITLES"),d=c.map(function(y){var w,x,D;return L(function(z){if(1==z.g){if(w=a.g.disableText)return z["return"](null);C(z,2);return u(z,hr(a,y),4)}if(2!=z.g)return x=z.h,z["return"](x.stream);D=E(z);if(a.g.hls.ignoreTextStreamFailures)return z["return"](null);throw D;})}),u(v,Promise.all(d),2);e=v.h;f=t(c);for(g=f.next();!g.done;g=f.next())if(h=g.value,k=wq(h,"GROUP-ID"),l=a.s.get(k))if(m=a.u.get(k))for(n=
678
- t(m),p=n.next();!p.done;p=n.next())q=p.value,q.stream.codecs=l;return v["return"](e.filter(function(y){return y}))})}
677
+ function dr(a,b){var c,d,e,f,g,h,k,l,m,n,p,q;return L(function(v){if(1==v.g)return c=Aq(b,"SUBTITLES"),d=c.map(function(w){var x,y,D;return L(function(z){if(1==z.g){if(x=a.g.disableText)return z["return"](null);C(z,2);return u(z,hr(a,w),4)}if(2!=z.g)return y=z.h,z["return"](y.stream);D=E(z);if(a.g.hls.ignoreTextStreamFailures)return z["return"](null);throw D;})}),u(v,Promise.all(d),2);e=v.h;f=t(c);for(g=f.next();!g.done;g=f.next())if(h=g.value,k=wq(h,"GROUP-ID"),l=a.s.get(k))if(m=a.u.get(k))for(n=
678
+ t(m),p=n.next();!p.done;p=n.next())q=p.value,q.stream.codecs=l;return v["return"](e.filter(function(w){return w}))})}
679
679
  function er(a,b){var c,d;return L(function(e){if(1==e.g)return c=b.map(function(f){var g,h,k;return L(function(l){if(1==l.g){if(g=a.g.disableThumbnails)return l["return"](null);C(l,2);return u(l,ir(a,f),4)}if(2!=l.g)return h=l.h,l["return"](h.stream);k=E(l);if(a.g.hls.ignoreImageStreamFailures)return l["return"](null);throw k;})}),u(e,Promise.all(c),2);d=e.h;return e["return"](d.filter(function(f){return f}))})}
680
680
  function ar(a,b){var c;return L(function(d){if(1==d.g)return b=b.filter(function(e){var f=Z(e,"URI")||"";return"SUBTITLES"!=Z(e,"TYPE")&&""!=f}),b.length?u(d,hr(a,b[0]),2):d.B(2);c=b.slice(1).map(function(e){return hr(a,e)});return u(d,Promise.all(c),0)})}
681
- function cr(a,b){var c,d,e;return L(function(f){if(1==f.g)return c=b.map(function(g){var h,k,l,m,n,p,q,v;return L(function(y){if(1==y.g)return h=Z(g,"FRAME-RATE"),k=Number(Z(g,"AVERAGE-BANDWIDTH"))||Number(wq(g,"BANDWIDTH")),l=Z(g,"RESOLUTION"),m=t(l?l.split("x"):[null,null]),n=m.next().value,p=m.next().value,q=Z(g,"VIDEO-RANGE"),u(y,jr(a,g,k),2);if(v=y.h){for(var w=y["return"],x=v.audio,D=v.video,z=t(D),B=z.next();!B.done;B=z.next())if(B=B.value.stream)B.width=Number(n)||void 0,B.height=Number(p)||
682
- void 0,B.frameRate=Number(h)||void 0,B.hdr=q||void 0;z=a.g.disableAudio;if(!x.length||z)x=[null];z=a.g.disableVideo;if(!D.length||z)D=[null];z=[];x=t(x);for(B=x.next();!B.done;B=x.next()){B=B.value;for(var F=t(D),G=F.next();!G.done;G=F.next()){var H=G.value;G=B?B.stream:null;var I=H?H.stream:null,J=B?B.stream.drmInfos:null,K=H?H.stream.drmInfos:null;H=(H?H.Vc:"")+" - "+(B?B.Vc:"");G&&I&&J.length&&K.length&&!(0<xg(J,K).length)||a.ya.has(H)||(G={id:a.Ga++,language:G?G.language:"und",primary:!!G&&G.primary||
683
- !!I&&I.primary,audio:G,video:I,bandwidth:k,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},z.push(G),a.ya.add(H))}}y=w.call(y,z)}else y=y["return"]([]);return y})}),u(f,Promise.all(c),2);d=f.h;e=d.reduce(Ob,[]);e=e.filter(function(g){return null!=g});return f["return"](e)})}
684
- function jr(a,b,c){var d,e,f,g,h,k,l,m,n,p,q,v,y,w;return L(function(x){if(1==x.g)return d=qc,e=gr(a,b),f=Z(b,"AUDIO"),g=Z(b,"VIDEO"),k=(h=f||g)&&a.u.has(h)?a.u.get(h):[],l={audio:f?k:[],video:g?k:[]},n=!1,p=wq(b,"URI"),q=l.audio.find(function(D){return D&&D.Vc==p}),v=nc(d.Na,e),(y=nc(d.cb,e))&&!v?m=d.cb:!k.length&&y&&v?(m=d.Na,e=[[v,y].join()]):l.audio.length&&q?(m=d.cb,n=!0):m=l.video.length&&!l.audio.length?d.cb:d.Na,n?x.B(2):u(x,kr(a,b,e,m,c),3);2!=x.g&&(w=x.h);if(w)l[w.stream.type]=[w];else if(null===
685
- w)return x["return"](null);lr(l);return x["return"](l)})}function gr(a,b){var c=[];a.g.disableVideo||c.push(a.g.hls.defaultVideoCodec);a.g.disableAudio||c.push(a.g.hls.defaultAudioCodec);var d=Z(b,"CODECS",c.join(",")).split(/\s*,\s*/);c=new Set;var e=[];d=t(d);for(var f=d.next();!f.done;f=d.next()){f=f.value;var g=dd(f)[0];c.has(g)||(e.push(f),c.add(g))}return e}function mr(a){a=Z(a,"LANGUAGE")||"und";return rd(a)}
681
+ function cr(a,b){var c,d,e;return L(function(f){if(1==f.g)return c=b.map(function(g){var h,k,l,m,n,p,q,v;return L(function(w){if(1==w.g)return h=Z(g,"FRAME-RATE"),k=Number(Z(g,"AVERAGE-BANDWIDTH"))||Number(wq(g,"BANDWIDTH")),l=Z(g,"RESOLUTION"),m=t(l?l.split("x"):[null,null]),n=m.next().value,p=m.next().value,q=Z(g,"VIDEO-RANGE"),u(w,jr(a,g,k),2);if(v=w.h){for(var x=w["return"],y=v.audio,D=v.video,z=t(D),B=z.next();!B.done;B=z.next())if(B=B.value.stream)B.width=Number(n)||void 0,B.height=Number(p)||
682
+ void 0,B.frameRate=Number(h)||void 0,B.hdr=q||void 0;z=a.g.disableAudio;if(!y.length||z)y=[null];z=a.g.disableVideo;if(!D.length||z)D=[null];z=[];y=t(y);for(B=y.next();!B.done;B=y.next()){B=B.value;for(var F=t(D),G=F.next();!G.done;G=F.next()){var H=G.value;G=B?B.stream:null;var I=H?H.stream:null,J=B?B.stream.drmInfos:null,K=H?H.stream.drmInfos:null;H=(H?H.Vc:"")+" - "+(B?B.Vc:"");G&&I&&J.length&&K.length&&!(0<xg(J,K).length)||a.ya.has(H)||(G={id:a.Ga++,language:G?G.language:"und",primary:!!G&&G.primary||
683
+ !!I&&I.primary,audio:G,video:I,bandwidth:k,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},z.push(G),a.ya.add(H))}}w=x.call(w,z)}else w=w["return"]([]);return w})}),u(f,Promise.all(c),2);d=f.h;e=d.reduce(Ob,[]);e=e.filter(function(g){return null!=g});return f["return"](e)})}
684
+ function jr(a,b,c){var d,e,f,g,h,k,l,m,n,p,q,v,w,x;return L(function(y){if(1==y.g)return d=qc,e=gr(a,b),f=Z(b,"AUDIO"),g=Z(b,"VIDEO"),k=(h=f||g)&&a.u.has(h)?a.u.get(h):[],l={audio:f?k:[],video:g?k:[]},n=!1,p=wq(b,"URI"),q=l.audio.find(function(D){return D&&D.Vc==p}),v=nc(d.Na,e),(w=nc(d.cb,e))&&!v?m=d.cb:!k.length&&w&&v?(m=d.Na,e=[[v,w].join()]):l.audio.length&&q?(m=d.cb,n=!0):m=l.video.length&&!l.audio.length?d.cb:d.Na,n?y.B(2):u(y,kr(a,b,e,m,c),3);2!=y.g&&(x=y.h);if(x)l[x.stream.type]=[x];else if(null===
685
+ x)return y["return"](null);lr(l);return y["return"](l)})}function gr(a,b){var c=[];a.g.disableVideo||c.push(a.g.hls.defaultVideoCodec);a.g.disableAudio||c.push(a.g.hls.defaultAudioCodec);var d=Z(b,"CODECS",c.join(",")).split(/\s*,\s*/);c=new Set;var e=[];d=t(d);for(var f=d.next();!f.done;f=d.next()){f=f.value;var g=dd(f)[0];c.has(g)||(e.push(f),c.add(g))}return e}function mr(a){a=Z(a,"LANGUAGE")||"und";return rd(a)}
686
686
  function lr(a){a=t(a.audio.concat(a.video));for(var b=a.next();!b.done;b=a.next())if(b=b.value){var c=b.stream.codecs.split(",");c=c.filter(function(d){return"mp4a.40.34"!=d});b.stream.codecs=c.join(",")}}function br(a,b){var c=Aq(b,"CLOSED-CAPTIONS");c=t(c);for(var d=c.next();!d.done;d=c.next()){var e=d.value;d=mr(e);var f=wq(e,"GROUP-ID");e=wq(e,"INSTREAM-ID");a.L.get(f)||a.L.set(f,new Map);a.L.get(f).set(e,d)}}
687
- function hr(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v,y;return L(function(w){if(1==w.g){c=wq(b,"GROUP-ID");d="";var x=wq(b,"TYPE").toLowerCase();"subtitles"==x&&(x=pc);e=x;e!=pc&&c&&a.s.has(c)&&(d=a.s.get(c));f=nr(wq(b,"URI"),a.o);if(a.h.has(f))return w["return"](a.h.get(f));g=mr(b);h=Z(b,"NAME");k=Z(b,"DEFAULT");l="YES"==k;"audio"==e?x=(x=Z(b,"CHANNELS"))?parseInt(x.split("/")[0],10):null:x=null;m=x;"audio"==e?x=(x=Z(b,"CHANNELS"))?x.includes("/JOC"):!1:x=!1;n=x;p=Z(b,"CHARACTERISTICS");q=Z(b,"FORCED");
688
- v="YES"==q;return u(w,or(a,f,d,e,g,l,h,m,null,p,v,n),2)}y=w.h;a.u.has(c)?a.u.get(c).push(y):a.u.set(c,[y]);if(null==y)return w["return"](null);if(a.h.has(f))return w["return"](a.h.get(f));a.h.set(f,y);return w["return"](y)})}
687
+ function hr(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v,w;return L(function(x){if(1==x.g){c=wq(b,"GROUP-ID");d="";var y=wq(b,"TYPE").toLowerCase();"subtitles"==y&&(y=pc);e=y;e!=pc&&c&&a.s.has(c)&&(d=a.s.get(c));f=nr(wq(b,"URI"),a.o);if(a.h.has(f))return x["return"](a.h.get(f));g=mr(b);h=Z(b,"NAME");k=Z(b,"DEFAULT");l="YES"==k;"audio"==e?y=(y=Z(b,"CHANNELS"))?parseInt(y.split("/")[0],10):null:y=null;m=y;"audio"==e?y=(y=Z(b,"CHANNELS"))?y.includes("/JOC"):!1:y=!1;n=y;p=Z(b,"CHARACTERISTICS");q=Z(b,"FORCED");
688
+ v="YES"==q;return u(x,or(a,f,d,e,g,l,h,m,null,p,v,n),2)}w=x.h;a.u.has(c)?a.u.get(c).push(w):a.u.set(c,[w]);if(null==w)return x["return"](null);if(a.h.has(f))return x["return"](a.h.get(f));a.h.set(f,w);return x["return"](w)})}
689
689
  function ir(a,b){var c,d,e,f,g,h,k,l,m,n;return L(function(p){if(1==p.g){c=nr(wq(b,"URI"),a.o);d=Z(b,"CODECS","jpeg")||"";if(a.h.has(c))return p["return"](a.h.get(c));e=mr(b);f=Z(b,"NAME");g=Z(b,"CHARACTERISTICS");return u(p,or(a,c,d,"image",e,!1,f,null,null,g,!1,!1),2)}h=p.h;if(null==h)return p["return"](null);if(a.h.has(c))return p["return"](a.h.get(c));if(k=Z(b,"RESOLUTION"))if(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=
690
690
  Number(k.split("x")[1])*Number(m.split("x")[1]);if(n=Z(b,"BANDWIDTH"))h.stream.bandwidth=Number(n);a.h.set(c,h);return p["return"](h)})}
691
691
  function kr(a,b,c,d,e){var f,g,h,k;return L(function(l){if(1==l.g){f=nr(wq(b,"URI"),a.o);if(a.h.has(f))return l["return"](a.h.get(f));var m=Z(b,"CLOSED-CAPTIONS");g="video"==d&&m&&"NONE"!=m?a.L.get(m):null;h=mc(d,c);return u(l,or(a,f,h,d,"und",!1,null,null,g,null,!1,!1,e),2)}k=l.h;if(null==k)return l["return"](null);if(a.h.has(f))return l["return"](a.h.get(f));a.h.set(f,k);return l["return"](k)})}
692
- function or(a,b,c,d,e,f,g,h,k,l,m,n,p){var q,v,y,w,x,D,z,B,F,G,H,I,J,K,P,R,ba,aa,Y,Da,Fa,xa,Ia,Rb,nd,Ya,Gf,Ec,ji,Dn,En,Fn,Gn,ki,li,Hf,Hn,In,Jn,Kn;return L(function(cb){switch(cb.g){case 1:return q=kc([a.N],[b])[0],u(cb,Sq(a,q),2);case 2:v=cb.h;q=v.uri;y=Iq(a.da,v.data,q);if(1!=y.type)throw new N(2,4,4017);w=[];if(y.segments)for(x=t(y.segments),D=x.next();!D.done;D=x.next())z=D.value,B=zq(z.g,"EXT-X-KEY"),w.push.apply(w,ja(B));F=!1;G=[];H=new Set;I=t(w);for(J=I.next();!J.done;J=I.next())if(K=J.value,
693
- P=wq(K,"METHOD"),"NONE"!=P){F=!0;if("AES-128"==P)return a.Ma=!0,cb["return"](null);R=wq(K,"KEYFORMAT");if(aa=(ba=pr[R])?ba(K):null){if(aa.keyIds)for(Y=t(aa.keyIds),Da=Y.next();!Da.done;Da=Y.next())Fa=Da.value,H.add(Fa);G.push(aa)}}if(F&&!G.length)throw new N(2,4,4026);xa=zq(y.g,"EXT-X-DEFINE");Ia=Wq(a,xa);qr(a,y);return u(cb,rr(a,d,c,y,Ia),3);case 3:return Rb=cb.h,sr.includes(Rb)&&(c=""),nd=new Map,Ya=new Map,Gf=a.l,C(cb,4),u(cb,Xq(a,b,y,d,Rb,nd,Ia,Ya,c,p),6);case 6:Ec=cb.h;va(cb,5);break;case 4:ji=
694
- E(cb);if(4035==ji.code)return Ua("Skipping unsupported HLS stream",Rb,b),cb["return"](null);throw ji;case 5:Gf!=a.l&&qr(a,y);Dn=Ec[0].startTime;En=Ec[Ec.length-1].endTime;Fn=new T(Ec);Gn=d==pc?"subtitle":void 0;ki=[];if(l)for(li=t(l.split(",")),Hf=li.next();!Hf.done;Hf=li.next())Hn=Hf.value,ki.push(Hn);Jn=(In=Bq(y.g,"EXT-X-SERVER-CONTROL"))?null!=In.getAttribute("CAN-SKIP-UNTIL"):!1;Kn={id:a.Ga++,originalId:g,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:Fn,mimeType:Rb,codecs:c,
695
- kind:Gn,encrypted:F,drmInfos:G,keyIds:H,language:e,label:g,type:d,primary:f,trickModeVideo:null,emsgSchemeIdUris:null,frameRate:void 0,pixelAspectRatio:void 0,width:void 0,height:void 0,bandwidth:void 0,roles:ki,forced:m,channelsCount:h,audioSamplingRate:null,spatialAudio:n,closedCaptions:k,hdr:void 0,tilesLayout:void 0};return cb["return"]({stream:Kn,Vc:b,Me:q,se:Dn,Gf:En,Ed:nd,Ye:Ya,Re:Jn})}})}
692
+ function or(a,b,c,d,e,f,g,h,k,l,m,n,p){var q,v,w,x,y,D,z,B,F,G,H,I,J,K,P,R,ba,aa,Y,Da,Fa,xa,Ja,Rb,nd,Ya,Gf,Ec,ji,Dn,En,Fn,Gn,ki,li,Hf,Hn,In,Jn,Kn;return L(function(cb){switch(cb.g){case 1:return q=kc([a.N],[b])[0],u(cb,Sq(a,q),2);case 2:v=cb.h;q=v.uri;w=Iq(a.da,v.data,q);if(1!=w.type)throw new N(2,4,4017);x=[];if(w.segments)for(y=t(w.segments),D=y.next();!D.done;D=y.next())z=D.value,B=zq(z.g,"EXT-X-KEY"),x.push.apply(x,ja(B));F=!1;G=[];H=new Set;I=t(x);for(J=I.next();!J.done;J=I.next())if(K=J.value,
693
+ P=wq(K,"METHOD"),"NONE"!=P){F=!0;if("AES-128"==P)return a.Ma=!0,cb["return"](null);R=wq(K,"KEYFORMAT");if(aa=(ba=pr[R])?ba(K):null){if(aa.keyIds)for(Y=t(aa.keyIds),Da=Y.next();!Da.done;Da=Y.next())Fa=Da.value,H.add(Fa);G.push(aa)}}if(F&&!G.length)throw new N(2,4,4026);xa=zq(w.g,"EXT-X-DEFINE");Ja=Wq(a,xa);qr(a,w);return u(cb,rr(a,d,c,w,Ja),3);case 3:return Rb=cb.h,sr.includes(Rb)&&(c=""),nd=new Map,Ya=new Map,Gf=a.l,C(cb,4),u(cb,Xq(a,b,w,d,Rb,nd,Ja,Ya,c,p),6);case 6:Ec=cb.h;va(cb,5);break;case 4:ji=
694
+ E(cb);if(4035==ji.code)return Ua("Skipping unsupported HLS stream",Rb,b),cb["return"](null);throw ji;case 5:Gf!=a.l&&qr(a,w);Dn=Ec[0].startTime;En=Ec[Ec.length-1].endTime;Fn=new T(Ec);Gn=d==pc?"subtitle":void 0;ki=[];if(l)for(li=t(l.split(",")),Hf=li.next();!Hf.done;Hf=li.next())Hn=Hf.value,ki.push(Hn);Jn=(In=Bq(w.g,"EXT-X-SERVER-CONTROL"))?null!=In.getAttribute("CAN-SKIP-UNTIL"):!1;Kn={id:a.Ga++,originalId:g,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:Fn,mimeType:Rb,codecs:c,
695
+ kind:Gn,encrypted:F,drmInfos:G,keyIds:H,language:e,label:g,type:d,primary:f,trickModeVideo:null,emsgSchemeIdUris:null,frameRate:void 0,pixelAspectRatio:void 0,width:void 0,height:void 0,bandwidth:void 0,roles:ki,forced:m,channelsCount:h,audioSamplingRate:null,spatialAudio:n,closedCaptions:k,hdr:void 0,tilesLayout:void 0};return cb["return"]({stream:Kn,Vc:b,Me:q,se:Dn,Gf:En,Fd:nd,Ye:Ya,Re:Jn})}})}
696
696
  function qr(a,b){var c=Bq(b.g,"EXT-X-PLAYLIST-TYPE"),d=Bq(b.g,"EXT-X-ENDLIST");d=c&&"VOD"==c.value||d;c=c&&"EVENT"==c.value&&!d;c=!d&&!c;if(d)Yq(a,Rq);else{c?Yq(a,tr):Yq(a,ur);d=Bq(b.g,"EXT-X-TARGETDURATION");if(!d)throw new N(2,4,4024,"EXT-X-TARGETDURATION");d=Number(d.value);c=Bq(b.g,"EXT-X-PART-INF");a.l&&c?(a.ka=Number(wq(c,"PART-TARGET")),a.G=Math.min(a.ka,a.G),c=Bq(b.g,"EXT-X-SERVER-CONTROL"),a.ca=c?Number(wq(c,"PART-HOLD-BACK")):0):a.G=Math.min(d,a.G);a.fa=Math.max(d,a.fa)}}
697
697
  function vr(a,b,c,d){c=Bq(c,"EXT-X-MAP");if(!c)return null;var e=wq(c,"URI");d=nr(kc([b],[e])[0],d);b=[d,Z(c,"BYTERANGE","")].join("-");a.ea.has(b)||(c=wr(d,c),a.ea.set(b,c));return a.ea.get(b)}function wr(a,b){var c=0,d=null,e=Z(b,"BYTERANGE");e&&(c=e.split("@"),d=Number(c[0]),c=Number(c[1]),d=c+d-1);return new Gi(function(){return[a]},c,d)}
698
- function xr(a,b,c,d,e,f,g,h,k){var l=d.g,m=nr(d.h,g),n=Bq(l,"EXTINF"),p=g=0,q=null;if(!n){if(0==d.i.length)throw new N(2,4,4024,"EXTINF");if(!a.l)return null}var v=[];if(a.l)for(var y={},w=0;w<d.i.length;y={dd:y.dd},w++){var x=d.i[w],D=0==w?c:v[v.length-1],z=0==w?e:D.endTime,B=Number(Z(x,"DURATION"))||a.ka;if(B){B=z+B;var F=0,G=null;"EXT-X-PRELOAD-HINT"==x.name?F=(D=Z(x,"BYTERANGE-START"))?Number(D):0:(F=Z(x,"BYTERANGE"),D=t(yr(D,F)),F=D.next().value,G=D.next().value);if(x=Z(x,"URI"))y.dd=kc([h],
699
- [x])[0],v.push(new Ii(z,B,function(H){return function(){return[H.dd]}}(y),F,G,b,f,0,Infinity))}}n?g=e+Number(n.value.split(",")[0]):g=v[v.length-1].endTime;(a=Bq(l,"EXT-X-BYTERANGE"))?(q=t(yr(c,a.value)),p=q.next().value,q=q.next().value):v.length&&(p=v[0].pa,q=v[v.length-1].ha);c="";a=null;"image"==k&&(c="1x1",k=Bq(l,"EXT-X-TILES"))&&(c=wq(k,"LAYOUT"),(k=Z(k,"DURATION"))&&(a=Number(k)));return new Ii(e,g,function(){return m.length?[m]:[]},p,q,b,f,0,Infinity,v,c,a)}
698
+ function xr(a,b,c,d,e,f,g,h,k){var l=d.g,m=nr(d.h,g),n=Bq(l,"EXTINF"),p=g=0,q=null;if(!n){if(0==d.i.length)throw new N(2,4,4024,"EXTINF");if(!a.l)return null}var v=[];if(a.l)for(var w={},x=0;x<d.i.length;w={dd:w.dd},x++){var y=d.i[x],D=0==x?c:v[v.length-1],z=0==x?e:D.endTime,B=Number(Z(y,"DURATION"))||a.ka;if(B){B=z+B;var F=0,G=null;"EXT-X-PRELOAD-HINT"==y.name?F=(D=Z(y,"BYTERANGE-START"))?Number(D):0:(F=Z(y,"BYTERANGE"),D=t(yr(D,F)),F=D.next().value,G=D.next().value);if(y=Z(y,"URI"))w.dd=kc([h],
699
+ [y])[0],v.push(new Ii(z,B,function(H){return function(){return[H.dd]}}(w),F,G,b,f,0,Infinity))}}n?g=e+Number(n.value.split(",")[0]):g=v[v.length-1].endTime;(a=Bq(l,"EXT-X-BYTERANGE"))?(q=t(yr(c,a.value)),p=q.next().value,q=q.next().value):v.length&&(p=v[0].pa,q=v[v.length-1].ha);c="";a=null;"image"==k&&(c="1x1",k=Bq(l,"EXT-X-TILES"))&&(c=wq(k,"LAYOUT"),(k=Z(k,"DURATION"))&&(a=Number(k)));return new Ii(e,g,function(){return m.length?[m]:[]},p,q,b,f,0,Infinity,v,c,a)}
700
700
  function yr(a,b){var c=0,d=null;b&&(c=b.split("@"),d=Number(c[0]),c=c[1]?Number(c[1]):a.ha+1,d=c+d-1);return[c,d]}function fr(a){if(a.j){for(var b=t(a.W),c=b.next();!c.done;c=b.next())a.j.Hb(c.value);a.W=[]}}
701
- function Xq(a,b,c,d,e,f,g,h,k,l){var m,n,p,q,v,y,w,x,D,z,B,F,G,H,I,J,K,P,R,ba,aa;return L(function(Y){switch(Y.g){case 1:m=c.segments;p=Cq(c.g,"EXT-X-MEDIA-SEQUENCE",0);v=(q=Bq(c.g,"EXT-X-SKIP"))?Number(Z(q,"SKIPPED-SEGMENTS")):0;y=p+v;if(a.m!=Rq&&f.has(y)){w=f.get(y);Y.B(2);break}if(null!=a.V){Y.B(3);break}n=vr(a,c.h,m[0].g,g);x=a;return u(Y,zr(a,b,n,e,y,!1,m[0],g,d,k,l),4);case 4:x.V=Y.h;case 3:w=a.V;case 2:D=m[0].h;D.split("/").pop();z=Cq(c.g,"EXT-X-DISCONTINUITY-SEQUENCE");if(a.l&&(h.has(z)||
702
- h.set(z,y),v))for(B=h;B.has(z+1)&&B.get(z+1)<y;)z++;F=a.I.get(z)||0;G=[];H=0;case 5:if(!(H<m.length)){Y.B(7);break}I=m[H];J=G[G.length-1];K=0==H?w:J.endTime;y=p+v+H;f.set(y,K);n=vr(a,c.h,I.g,g);P=Bq(I.g,"EXT-X-DISCONTINUITY");if(!P){Y.B(8);break}z++;h.set(z,y);return u(Y,Ar(a,z,b,n,e,y,I,g,K,d,k,l),9);case 9:F=Y.h;case 8:!a.l&&(R=a.i.isAutoLowLatencyMode())&&(a.i.enableLowLatencyMode(),a.l=a.i.isLowLatencyMode());ba=Bq(I.g,"EXTINF");a.l||ba?(aa=xr(a,n,J,I,K,F,g,c.h,d))&&G.push(aa):a.l||Ua("Low-latency HLS live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details.");
701
+ function Xq(a,b,c,d,e,f,g,h,k,l){var m,n,p,q,v,w,x,y,D,z,B,F,G,H,I,J,K,P,R,ba,aa;return L(function(Y){switch(Y.g){case 1:m=c.segments;p=Cq(c.g,"EXT-X-MEDIA-SEQUENCE",0);v=(q=Bq(c.g,"EXT-X-SKIP"))?Number(Z(q,"SKIPPED-SEGMENTS")):0;w=p+v;if(a.m!=Rq&&f.has(w)){x=f.get(w);Y.B(2);break}if(null!=a.V){Y.B(3);break}n=vr(a,c.h,m[0].g,g);y=a;return u(Y,zr(a,b,n,e,w,!1,m[0],g,d,k,l),4);case 4:y.V=Y.h;case 3:x=a.V;case 2:D=m[0].h;D.split("/").pop();z=Cq(c.g,"EXT-X-DISCONTINUITY-SEQUENCE");if(a.l&&(h.has(z)||
702
+ h.set(z,w),v))for(B=h;B.has(z+1)&&B.get(z+1)<w;)z++;F=a.I.get(z)||0;G=[];H=0;case 5:if(!(H<m.length)){Y.B(7);break}I=m[H];J=G[G.length-1];K=0==H?x:J.endTime;w=p+v+H;f.set(w,K);n=vr(a,c.h,I.g,g);P=Bq(I.g,"EXT-X-DISCONTINUITY");if(!P){Y.B(8);break}z++;h.set(z,w);return u(Y,Ar(a,z,b,n,e,w,I,g,K,d,k,l),9);case 9:F=Y.h;case 8:!a.l&&(R=a.i.isAutoLowLatencyMode())&&(a.i.enableLowLatencyMode(),a.l=a.i.isLowLatencyMode());ba=Bq(I.g,"EXTINF");a.l||ba?(aa=xr(a,n,J,I,K,F,g,c.h,d))&&G.push(aa):a.l||Ua("Low-latency HLS live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details.");
703
703
  H++;Y.B(5);break;case 7:return Y["return"](G)}})}function Ar(a,b,c,d,e,f,g,h,k,l,m,n){var p,q;return L(function(v){if(1==v.g)return p=0,a.I.has(b)?(p=a.I.get(b),v.B(2)):u(v,zr(a,c,d,e,f,!0,g,h,l,m,n),3);2!=v.g&&(q=v.h,p=k-q,a.I.set(b,p));return v["return"](p)})}
704
704
  function Br(a,b,c,d,e,f){var g,h,k,l,m,n;return L(function(p){switch(p.g){case 1:g=bf;h=vj(b.sa(),b.pa,b.ha,a.g.retryParameters);a.i.modifySegmentRequest(h,{type:c,init:b instanceof Gi,duration:b.endTime-b.startTime,mimeType:d,codecs:e,bandwidth:f});if(a.g.hls.useFullSegmentsForStartTime)return p["return"](Cr(a,h,g));k=vj(b.sa(),b.pa,b.pa+2048-1,a.g.retryParameters);a.i.modifySegmentRequest(k,{type:c,init:b instanceof Gi,duration:b.endTime-b.startTime,mimeType:d,codecs:e,bandwidth:f});C(p,2);return u(p,
705
705
  Cr(a,k,g),4);case 4:return l=p.h,p["return"](l);case 2:m=E(p);if(7001==m.code)throw m;Ua("Unable to fetch the starting part of HLS segment! Falling back to a full segment request, which is expensive! Your server should support Range requests and CORS preflights.",k.uris[0]);return u(p,Cr(a,h,g),5);case 5:return n=p.h,p["return"](n)}})}
706
- function zr(a,b,c,d,e,f,g,h,k,l,m){var n,p,q,v,y,w,x,D;return L(function(z){switch(z.g){case 1:n=xr(a,c,null,g,0,0,h,"",k);if(a.D&&!f&&(p=a.h.get(b),q=p.Ed.get(e),void 0!=q))return z["return"](q);d=d.toLowerCase();if(sr.includes(d))throw Ua("Raw formats are not yet supported. Skipping "+d),new N(1,4,4035);if("video/webm"==d)throw Ua("WebM in HLS is not yet supported. Skipping."),new N(1,4,4035);if("video/mp4"!=d&&"audio/mp4"!=d){z.B(2);break}v=[Br(a,n,k,d,l,m)];c&&v.push(Br(a,c,k,d,l,m));return u(z,
707
- Promise.all(v),3);case 3:return y=z.h,w=y[0],x=y[1]||y[0],z["return"](Dr(b,w.uri,w.data,x.data));case 2:if("video/mp2t"!=d){z.B(4);break}return u(z,Br(a,n,k,d,l,m),5);case 5:return D=z.h,z["return"](Er(b,D.uri,D.data));case 4:throw new N(2,4,4030,b);}})}
706
+ function zr(a,b,c,d,e,f,g,h,k,l,m){var n,p,q,v,w,x,y,D;return L(function(z){switch(z.g){case 1:n=xr(a,c,null,g,0,0,h,"",k);if(a.D&&!f&&(p=a.h.get(b),q=p.Fd.get(e),void 0!=q))return z["return"](q);d=d.toLowerCase();if(sr.includes(d))throw Ua("Raw formats are not yet supported. Skipping "+d),new N(1,4,4035);if("video/webm"==d)throw Ua("WebM in HLS is not yet supported. Skipping."),new N(1,4,4035);if("video/mp4"!=d&&"audio/mp4"!=d){z.B(2);break}v=[Br(a,n,k,d,l,m)];c&&v.push(Br(a,c,k,d,l,m));return u(z,
707
+ Promise.all(v),3);case 3:return w=z.h,x=w[0],y=w[1]||w[0],z["return"](Dr(b,x.uri,x.data,y.data));case 2:if("video/mp2t"!=d){z.B(4);break}return u(z,Br(a,n,k,d,l,m),5);case 5:return D=z.h,z["return"](Er(b,D.uri,D.data));case 4:throw new N(2,4,4030,b);}})}
708
708
  function Dr(a,b,c,d){var e=0;(new Ig).box("moov",Mg).box("trak",Mg).box("mdia",Mg).P("mdhd",function(h){e=Zh(h.reader,h.version).timescale;h.parser.stop()}).parse(d,!0);if(!e)throw new N(2,4,4030,a,b);var f=0,g=!1;(new Ig).box("moof",Mg).box("traf",Mg).P("tfdt",function(h){f=Yh(h.reader,h.version).pd/e;g=!0;h.parser.stop()}).parse(c,!0);if(!g)throw new N(2,4,4030,a,b);return f}
709
709
  function Er(a,b,c){function d(){f.seek(g+188);h=f.Y();71!=h&&(f.seek(g+192),h=f.Y());71!=h&&(f.seek(g+204),h=f.Y());71!=h&&e();f.ye(1)}function e(){throw new N(2,4,4030,a,b);}var f=new Fg(c,0),g=0,h=0;for(c=Math.min(f.O.byteLength-188,940);;){g=f.X();h=f.Y();if(71!=h){if(0<c){--c;continue}e()}c=0;var k=f.Kb();if(8191==(k&8191))d();else if(k&16384)if(k=(f.Y()&48)>>4,0!=k&&2!=k||e(),3==k&&(k=f.Y(),f.skip(k)),1!=f.M()>>8)d();else{f.skip(3);c=f.Y()>>6;0!=c&&1!=c||e();0==f.Y()&&e();c=f.Y();k=f.Kb();var l=
710
710
  f.Kb();return(1073741824*((c&14)>>1)+((k&65534)<<14|(l&65534)>>1))/9E4}else d()}}function nr(a,b){var c=String(a).replace(/%7B/g,"{").replace(/%7D/g,"}"),d=c.match(/{\$\w*}/g);if(d){d=t(d);for(var e=d.next();!e.done;e=d.next()){e=e.value;var f=e.slice(2,e.length-1),g=b.get(f);if(g)c=c.replace(e,g);else throw new N(2,4,4039,f);}}return c}
711
- function rr(a,b,c,d,e){var f,g,h,k,l,m,n,p,q,v,y;return L(function(w){if(1==w.g){f=qc;g=bf;h=nr(d.segments[0].h,e);k=new Xb(h);l=k.wa.split(".").pop();m=Fr[b];if(n=m[l])return w["return"](n);if(b==f.Z)return c&&"vtt"!=c&&"wvtt"!=c?w["return"]("application/mp4"):w["return"]("text/vtt");if(b==f.Tb&&(!c||"jpeg"==c))return w["return"]("image/jpeg");p=We([h],a.g.retryParameters);p.method="HEAD";return u(w,Cr(a,p,g),2)}q=w.h;v=q.headers["content-type"];return v?w["return"](v.split(";")[0]):(y=m.mp4,w["return"](y))})}
711
+ function rr(a,b,c,d,e){var f,g,h,k,l,m,n,p,q,v,w;return L(function(x){if(1==x.g){f=qc;g=bf;h=nr(d.segments[0].h,e);k=new Xb(h);l=k.wa.split(".").pop();m=Fr[b];if(n=m[l])return x["return"](n);if(b==f.Z)return c&&"vtt"!=c&&"wvtt"!=c?x["return"]("application/mp4"):x["return"]("text/vtt");if(b==f.Tb&&(!c||"jpeg"==c))return x["return"]("image/jpeg");p=We([h],a.g.retryParameters);p.method="HEAD";return u(x,Cr(a,p,g),2)}q=x.h;v=q.headers["content-type"];return v?x["return"](v.split(";")[0]):(w=m.mp4,x["return"](w))})}
712
712
  function Sq(a,b){var c=We([b],a.g.retryParameters);a.i.modifyManifestRequest(c,{format:"h"});return Cr(a,c,0)}function Qq(a){var b,c;L(function(d){if(1==d.g){if(!a.i)return d["return"]();C(d,2);return u(d,a.update(),4)}if(2!=d.g)return b=a.xa,a.C.S(b),va(d,0);c=E(d);if(!a.i)return d["return"]();c.severity=1;a.i.onError(c);a.C.S(.1);A(d)})}function Yq(a,b){a.m=b;a.j&&a.j.pc(a.m==Rq);a.m!=Rq||a.C.stop()}
713
713
  function Cr(a,b,c){if(!a.F)throw new N(2,7,7001);b=a.i.networkingEngine.request(c,b);Re(a.F,b);return b.promise}M("shaka.hls.HlsParser",Pq);
714
714
  var sr=["audio/aac","audio/ac3","audio/ec3","audio/mpeg"],Fr={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",aac:"audio/aac",ac3:"audio/ac3",ec3:"audio/ec3",mp3:"audio/mpeg"},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"},text:{mp4:"application/mp4",m4s:"application/mp4",m4i:"application/mp4",m4f:"application/mp4",cmft:"application/mp4",
715
- vtt:"text/vtt",webvtt:"txt/vtt",ttml:"application/ttml+xml"},image:{jpg:"image/jpeg",png:"image/png",svg:"image/svg+xml",webp:"image/webp",avif:"image/avif"}},pr={"urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":function(a){var b=wq(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;b=wq(a,"URI");b=Oq(b);b=Fb(b.data);b=lc("com.widevine.alpha",[{initDataType:"cenc",initData:b}]);if(a=Z(a,"KEYID"))b.keyIds=new Set([a.toLowerCase().substr(2)]);return b},"com.microsoft.playready":function(a){var b=
716
- wq(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;a=wq(a,"URI");a=Oq(a);a=Fb(a.data);b=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);a=Co(a,b);return lc("com.microsoft.playready",[{initDataType:"cenc",initData:a}])}},Rq="VOD",ur="EVENT",tr="LIVE",Vq={Le:Rq,qg:ur,Ke:tr};Dg.m3u8=function(){return new Pq};Bg["application/x-mpegurl"]=function(){return new Pq};Bg["application/vnd.apple.mpegurl"]=function(){return new Pq};function Gr(a,b,c,d,e,f){if(200<=c&&299>=c&&202!=c)return{uri:e||d,ve:d,data:b,status:c,headers:a,fromCache:!!a["x-shaka-from-cache"]};e=null;try{e=Mc(b)}catch(g){}throw new N(401==c||403==c?2:1,1,1001,d,c,e,a,f);};function Hr(){}function Ir(a,b,c,d,e){var f=new Jr;pf(b.headers).forEach(function(l,m){f.append(m,l)});var g=new Kr,h={de:!1,He:!1};a=Lr(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 Fe(a,function(){h.de=!0;g.abort();return Promise.resolve()});if(b=b.retryParameters.timeout){var k=new O(function(){h.He=!0;g.abort()});k.S(b/1E3);a["finally"](function(){k.stop()})}return a}
717
- function Lr(a,b,c,d,e,f,g){var h,k,l,m,n,p,q,v,y,w,x,D,z;return L(function(B){switch(B.g){case 1:return h=Mr,k=Nr,p=n=0,q=Date.now(),C(B,2),u(B,h(a,c),4);case 4:return l=B.h,f(Or(l.headers)),v=l.clone().body.getReader(),w=(y=l.headers.get("Content-Length"))?parseInt(y,10):0,x=function(F){function G(){var H,I;return L(function(J){switch(J.g){case 1:return C(J,2),u(J,v.read(),4);case 4:H=J.h;va(J,3);break;case 2:return E(J),J["return"]();case 3:if(H.done){J.B(5);break}n+=H.value.byteLength;if(!g){J.B(5);
718
- break}return u(J,g(H.value),5);case 5:I=Date.now();if(100<I-q||H.done)e(I-q,n-p,w-n),p=n,q=I;H.done?F.close():(F.enqueue(H.value),G());A(J)}})}G()},new k({start:x}),u(B,l.arrayBuffer(),5);case 5:m=B.h;va(B,3);break;case 2:D=E(B);if(d.de)throw new N(1,1,7001,a,b);if(d.He)throw new N(1,1,1003,a,b);throw new N(1,1,1002,a,D,b);case 3:return z=Or(l.headers),B["return"](Gr(z,m,l.status,a,l.url,b))}})}function Or(a){var b={};a.forEach(function(c,d){b[d.trim()]=c});return b}
715
+ 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"}},pr={"urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":function(a){var b=wq(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;b=wq(a,"URI");b=Oq(b);b=Fb(b.data);b=lc("com.widevine.alpha",[{initDataType:"cenc",initData:b}]);if(a=Z(a,"KEYID"))b.keyIds=new Set([a.toLowerCase().substr(2)]);return b},"com.microsoft.playready":function(a){var b=
716
+ wq(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;a=wq(a,"URI");a=Oq(a);a=Fb(a.data);b=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);a=Co(a,b);return lc("com.microsoft.playready",[{initDataType:"cenc",initData:a}])}},Rq="VOD",ur="EVENT",tr="LIVE",Vq={Le:Rq,qg:ur,Ke:tr};Dg.m3u8=function(){return new Pq};Bg["application/x-mpegurl"]=function(){return new Pq};Bg["application/vnd.apple.mpegurl"]=function(){return new Pq};function Gr(a,b,c,d,e,f){if(200<=c&&299>=c&&202!=c)return{uri:e||d,ve:d,data:b,status:c,headers:a,fromCache:!!a["x-shaka-from-cache"]};e=null;try{e=Mc(b)}catch(g){}throw new N(401==c||403==c?2:1,1,1001,d,c,e,a,f);};function Hr(){}function Ir(a,b,c,d,e){var f=new Jr;pf(b.headers).forEach(function(l,m){f.append(m,l)});var g=new Kr,h={ee:!1,He:!1};a=Lr(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 Fe(a,function(){h.ee=!0;g.abort();return Promise.resolve()});if(b=b.retryParameters.timeout){var k=new O(function(){h.He=!0;g.abort()});k.S(b/1E3);a["finally"](function(){k.stop()})}return a}
717
+ function Lr(a,b,c,d,e,f,g){var h,k,l,m,n,p,q,v,w,x,y,D,z;return L(function(B){switch(B.g){case 1:return h=Mr,k=Nr,p=n=0,q=Date.now(),C(B,2),u(B,h(a,c),4);case 4:return l=B.h,f(Or(l.headers)),v=l.clone().body.getReader(),x=(w=l.headers.get("Content-Length"))?parseInt(w,10):0,y=function(F){function G(){var H,I;return L(function(J){switch(J.g){case 1:return C(J,2),u(J,v.read(),4);case 4:H=J.h;va(J,3);break;case 2:return E(J),J["return"]();case 3:if(H.done){J.B(5);break}n+=H.value.byteLength;if(!g){J.B(5);
718
+ break}return u(J,g(H.value),5);case 5:I=Date.now();if(100<I-q||H.done)e(I-q,n-p,x-n),p=n,q=I;H.done?F.close():(F.enqueue(H.value),G());A(J)}})}G()},new k({start:y}),u(B,l.arrayBuffer(),5);case 5:m=B.h;va(B,3);break;case 2:D=E(B);if(d.ee)throw new N(1,1,7001,a,b);if(d.He)throw new N(1,1,1003,a,b);throw new N(1,1,1002,a,D,b);case 3:return z=Or(l.headers),B["return"](Gr(z,m,l.status,a,l.url,b))}})}function Or(a){var b={};a.forEach(function(c,d){b[d.trim()]=c});return b}
719
719
  function Pr(){if(window.ReadableStream)try{new ReadableStream({})}catch(a){return!1}else return!1;return!(!window.fetch||!window.AbortController)}M("shaka.net.HttpFetchPlugin",Hr);Hr.isSupported=Pr;Hr.parse=Ir;var Mr=window.fetch,Kr=window.AbortController,Nr=window.ReadableStream,Jr=window.Headers;Pr()&&(Te("http",Ir,2,!0),Te("https",Ir,2,!0),Te("blob",Ir,2,!0));function Qr(){}
720
- function Rr(a,b,c,d,e){var f=new Sr,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 N(1,1,7001,a,c))};var n=!1;f.onreadystatechange=function(){if(2==f.readyState&&!n){var q=Tr(f);e(q);n=!0}};f.onload=function(){var q=Tr(f),v=f.response;try{var y=Gr(q,v,f.status,a,f.responseURL,c);l(y)}catch(w){m(w)}};f.onerror=function(q){m(new N(1,1,1002,a,q,
720
+ function Rr(a,b,c,d,e){var f=new Sr,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 N(1,1,7001,a,c))};var n=!1;f.onreadystatechange=function(){if(2==f.readyState&&!n){var q=Tr(f);e(q);n=!0}};f.onload=function(){var q=Tr(f),v=f.response;try{var w=Gr(q,v,f.status,a,f.responseURL,c);l(w)}catch(x){m(x)}};f.onerror=function(q){m(new N(1,1,1002,a,q,
721
721
  c))};f.ontimeout=function(){m(new N(1,1,1003,a,c))};f.onprogress=function(q){var v=Date.now();if(100<v-g||q.lengthComputable&&q.loaded==q.total)d(v-g,q.loaded-h,q.total-q.loaded),h=q.loaded,g=v};for(var p in b.headers)f.setRequestHeader(p.toLowerCase(),b.headers[p]);f.send(b.body)});return new Fe(k,function(){f.abort();return Promise.resolve()})}
722
722
  function Tr(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}M("shaka.net.HttpXHRPlugin",Qr);Qr.parse=Rr;var Sr=window.XMLHttpRequest;Te("http",Rr,1,!0);Te("https",Rr,1,!0);Te("blob",Rr,1,!0);function Ur(a,b,c,d){this.g=a;this.i=b;this.groupId=c;this.h=d}function Vr(a){return a.sa().map(function(b){return"{"+encodeURI(b)+"}"}).join("")+":"+a.pa+":"+a.ha}function Wr(a,b){return vj(a.g.sa(),a.g.pa,a.g.ha,b.streaming.retryParameters)};function Xr(){this.h=this.j=this.i=0;this.g=new Map;this.l=0}function Yr(a,b){a.i+=b;var c=a.l;a.l++;a.g.set(c,b);return c}Xr.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 Zr(a){var b=this;this.o=a;this.j=new Map;this.i=new cf(function(){return $r(b)["catch"](function(){})});this.h=[];this.m=function(){};this.l=function(){};this.g=new Xr}Zr.prototype.destroy=function(){return this.i.destroy()};function as(a,b,c){a.m=b;a.l=c}function $r(a){var b=a.h.map(function(c){return c()});a.h=[];return Promise.all(b)}
723
- function bs(a,b,c,d,e,f){df(a.i);var g=(a.j.get(b)||Promise.resolve()).then(function(){var h,k,l,m,n,p,q;return L(function(v){if(1==v.g)return u(v,cs(a,c),2);h=v.h;if(a.i.g)throw new N(2,9,7001);if(e)for(m in k=Fb(h),l=new Bo(k),l.data)n=Number(m),p=l.data[n],q=l.g[n],a.l(p,q);a.g.close(d,h.byteLength);var y=a.g;a.m(0==y.i?0:y.j/y.i,a.g.h);return v["return"](f(h))})});a.j.set(b,g)}function ds(a){return L(function(b){return 1==b.g?u(b,Promise.all(a.j.values()),2):b["return"](a.g.h)})}
723
+ function bs(a,b,c,d,e,f){df(a.i);var g=(a.j.get(b)||Promise.resolve()).then(function(){var h,k,l,m,n,p,q;return L(function(v){if(1==v.g)return u(v,cs(a,c),2);h=v.h;if(a.i.g)throw new N(2,9,7001);if(e)for(m in k=Fb(h),l=new Bo(k),l.data)n=Number(m),p=l.data[n],q=l.g[n],a.l(p,q);a.g.close(d,h.byteLength);var w=a.g;a.m(0==w.i?0:w.j/w.i,a.g.h);return v["return"](f(h))})});a.j.set(b,g)}function ds(a){return L(function(b){return 1==b.g?u(b,Promise.all(a.j.values()),2):b["return"](a.g.h)})}
724
724
  function cs(a,b){var c,d,e,f;return L(function(g){if(1==g.g)return c=bf,d=a.o.request(c,b),e=function(){return d.abort()},a.h.push(e),u(g,d.promise,2);f=g.h;fb(a.h,e);return g["return"](f.data)})};function es(a,b){var c=this;this.i=a;this.h=a.objectStore(b);this.g=new rc;a.onabort=function(d){d.preventDefault();c.g.reject()};a.onerror=function(d){d.preventDefault();c.g.reject()};a.oncomplete=function(){c.g.resolve()}}es.prototype.abort=function(){var a=this;return L(function(b){if(1==b.g){try{a.i.abort()}catch(c){}C(b,2);return u(b,a.g,4)}if(2!=b.g)return va(b,0);E(b);A(b)})};
725
- function fs(a,b){return new Promise(function(c,d){var e=a.h.openCursor();e.onerror=d;e.onsuccess=function(){var f;return L(function(g){if(1==g.g){if(null==e.result)return c(),g["return"]();f=e.result;return u(g,b(f.key,f.value,f),2)}f["continue"]();A(g)})}})}es.prototype.store=function(){return this.h};es.prototype.promise=function(){return this.g};function gs(a){this.h=a;this.g=[]}gs.prototype.destroy=function(){return Promise.all(this.g.map(function(a){return a.abort()}))};function hs(a,b){return is(a,b,"readwrite")}function is(a,b,c){c=a.h.transaction([b],c);var d=new es(c,b);a.g.push(d);d.promise().then(function(){fb(a.g,d)},function(){fb(a.g,d)});return d};function js(a,b,c){this.h=new gs(a);this.i=b;this.g=c}r=js.prototype;r.destroy=function(){return this.h.destroy()};r.hasFixedKeySpace=function(){return!0};r.addSegments=function(){return ks(this.i)};r.removeSegments=function(a,b){return ls(this,this.i,a,b)};r.getSegments=function(a){var b=this,c;return L(function(d){if(1==d.g)return u(d,ms(b,b.i,a),2);c=d.h;return d["return"](c.map(function(e){return b.ee(e)}))})};r.addManifests=function(){return ks(this.g)};
725
+ function fs(a,b){return new Promise(function(c,d){var e=a.h.openCursor();e.onerror=d;e.onsuccess=function(){var f;return L(function(g){if(1==g.g){if(null==e.result)return c(),g["return"]();f=e.result;return u(g,b(f.key,f.value,f),2)}f["continue"]();A(g)})}})}es.prototype.store=function(){return this.h};es.prototype.promise=function(){return this.g};function gs(a){this.h=a;this.g=[]}gs.prototype.destroy=function(){return Promise.all(this.g.map(function(a){return a.abort()}))};function hs(a,b){return is(a,b,"readwrite")}function is(a,b,c){c=a.h.transaction([b],c);var d=new es(c,b);a.g.push(d);d.promise().then(function(){fb(a.g,d)},function(){fb(a.g,d)});return d};function js(a,b,c){this.h=new gs(a);this.i=b;this.g=c}r=js.prototype;r.destroy=function(){return this.h.destroy()};r.hasFixedKeySpace=function(){return!0};r.addSegments=function(){return ks(this.i)};r.removeSegments=function(a,b){return ls(this,this.i,a,b)};r.getSegments=function(a){var b=this,c;return L(function(d){if(1==d.g)return u(d,ms(b,b.i,a),2);c=d.h;return d["return"](c.map(function(e){return b.fe(e)}))})};r.addManifests=function(){return ks(this.g)};
726
726
  r.updateManifest=function(){return Promise.reject(new N(2,9,9016,"Cannot modify values in "+this.g))};function ns(a,b,c){a=hs(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=hs(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 ls(this,this.g,a,b)};
727
- r.getManifests=function(a){var b=this,c;return L(function(d){if(1==d.g)return u(d,ms(b,b.g,a),2);c=d.h;return d["return"](Promise.all(c.map(function(e){return b.$b(e)})))})};r.getAllManifests=function(){var a=this,b,c;return L(function(d){return 1==d.g?(b=is(a.h,a.g,"readonly"),c=new Map,u(d,fs(b,function(e,f){var g;return L(function(h){if(1==h.g)return u(h,a.$b(f),2);g=h.h;c.set(e,g);A(h)})}),2)):3!=d.g?u(d,b.promise(),3):d["return"](c)})};r.ee=function(a){return a};r.$b=function(a){return Promise.resolve(a)};
727
+ r.getManifests=function(a){var b=this,c;return L(function(d){if(1==d.g)return u(d,ms(b,b.g,a),2);c=d.h;return d["return"](Promise.all(c.map(function(e){return b.$b(e)})))})};r.getAllManifests=function(){var a=this,b,c;return L(function(d){return 1==d.g?(b=is(a.h,a.g,"readonly"),c=new Map,u(d,fs(b,function(e,f){var g;return L(function(h){if(1==h.g)return u(h,a.$b(f),2);g=h.h;c.set(e,g);A(h)})}),2)):3!=d.g?u(d,b.promise(),3):d["return"](c)})};r.fe=function(a){return a};r.$b=function(a){return Promise.resolve(a)};
728
728
  function ks(a){return Promise.reject(new N(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 L(function(m){if(1==m.g){d=hs(c.h,a);e=d.store();f=[];g={};h=t(b);for(k=h.next();!k.done;g={vc:g.vc},k=h.next())l=k.value,g.vc=e.add(l),g.vc.onsuccess=function(n){return function(){f.push(n.vc.result)}}(g);return u(m,d.promise(),2)}return m["return"](f)})};
729
729
  function ls(a,b,c,d){a=hs(a.h,b);b=a.store();var e={};c=t(c);for(var f=c.next();!f.done;e={uc:e.uc},f=c.next())e.uc=f.value,b["delete"](e.uc).onsuccess=function(g){return function(){return d(g.uc)}}(e);return a.promise()}
730
730
  function ms(a,b,c){var d,e,f,g,h,k,l;return L(function(m){if(1==m.g){d=is(a.h,b,"readonly");e=d.store();f={};g=[];h={};k=t(c);for(l=k.next();!l.done;h={Sb:h.Sb,Qb:h.Qb},l=k.next())h.Qb=l.value,h.Sb=e.get(h.Qb),h.Sb.onsuccess=function(n){return function(){void 0==n.Sb.result&&g.push(n.Qb);f[n.Qb]=n.Sb.result}}(h);return u(m,d.promise(),2)}if(g.length)throw new N(2,9,9012,"Could not find values for "+g);return m["return"](c.map(function(n){return f[n]}))})};function os(a){this.g=new gs(a)}os.prototype.destroy=function(){return this.g.destroy()};os.prototype.getAll=function(){var a=this,b,c;return L(function(d){return 1==d.g?(b=is(a.g,"session-ids","readonly"),c=[],u(d,fs(b,function(e,f){c.push(f)}),2)):3!=d.g?u(d,b.promise(),3):d["return"](c)})};os.prototype.add=function(a){var b=hs(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()};
@@ -735,7 +735,7 @@ function ws(a){var b,c,d;return L(function(e){return 1==e.g?(b=Array.from(a.g.va
735
735
  ys.prototype.$b=function(a){var b,c,d,e,f,g;return L(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=zs(a.periods[c],e),b.push(f);return u(h,Hp(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})})};
736
736
  function zs(a,b){As(a);for(var c=t(a.streams),d=c.next();!d.done;d=c.next());return a.streams.map(function(e){return Bs(e,a.startTime,b)})}
737
737
  function Bs(a,b,c){var d=a.initSegmentUri?Cs(a.initSegmentUri):null,e=b+a.presentationTimeOffset,f=b+c;return{id:a.id,originalId:null,primary:a.primary,type:a.contentType,mimeType:a.mimeType,codecs:a.codecs,frameRate:a.frameRate,pixelAspectRatio:void 0,hdr:void 0,kind:a.kind,language:a.language,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=Cs(g.uri);return{startTime:b+g.startTime,endTime:b+g.endTime,
738
- dataKey:h,initSegmentKey:d,appendWindowStart:b,appendWindowEnd:f,timestampOffset:e,tilesLayout:""}}),variantIds:a.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0}}ys.prototype.ee=function(a){return{data:a.data}};function Cs(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 N(2,9,9004,"Could not parse uri "+a);}
738
+ dataKey:h,initSegmentKey:d,appendWindowStart:b,appendWindowEnd:f,timestampOffset:e,tilesLayout:""}}),variantIds:a.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0}}ys.prototype.fe=function(a){return{data:a.data}};function Cs(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 N(2,9,9004,"Could not parse uri "+a);}
739
739
  function As(a){var b=a.streams.filter(function(h){return"audio"==h.contentType});a=a.streams.filter(function(h){return"video"==h.contentType});if(!b.every(function(h){return h.variantIds})||!a.every(function(h){return h.variantIds})){for(var c=t(b),d=c.next();!d.done;d=c.next())d.value.variantIds=[];c=t(a);for(d=c.next();!d.done;d=c.next())d.value.variantIds=[];c=0;if(a.length&&!b.length){var e=c++,f=t(a);for(d=f.next();!d.done;d=f.next())d.value.variantIds.push(e)}if(!a.length&&b.length)for(e=c++,
740
740
  f=t(b),d=f.next();!d.done;d=f.next())d.value.variantIds.push(e);if(a.length&&b.length)for(b=t(b),d=b.next();!d.done;d=b.next())for(d=d.value,e=t(a),f=e.next();!f.done;f=e.next()){f=f.value;var g=c++;d.variantIds.push(g);f.variantIds.push(g)}}};function Ds(){js.apply(this,arguments)}qa(Ds,js);
741
741
  Ds.prototype.$b=function(a){var b,c,d,e,f,g;return L(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(Es(n,k.startTime,k.startTime+e));f=l;b.push(f)}return u(h,Hp(b),2)}g=h.h;return h["return"]({appMetadata:a.appMetadata,creationTime:0,drmInfo:a.drmInfo,duration:a.duration,expiration:null==
@@ -759,7 +759,7 @@ function Ps(a,b){var c=new Is("segment",a.h,a.g,b);return new Gi(function(){retu
759
759
  r.start=function(a,b){var c=this,d,e,f,g,h,k,l;return L(function(m){switch(m.g){case 1:d=Js(a);c.g=d;if(null==d||"manifest"!=d.g)throw new N(2,1,9004,a);e=new ps;ua(m);return u(m,e.init(),4);case 4:return u(m,ts(e,d.Ca(),d.la()),5);case 5:return f=m.h,u(m,f.getManifests([d.key()]),6);case 6:return g=m.h,h=g[0],k=new Ks(d.Ca(),d.la()),l=Ls(k,h),b.makeTextStreamsForClosedCaptions(l),m["return"](l);case 2:return wa(m),u(m,e.destroy(),7);case 7:ya(m,0)}})};r.stop=function(){return Promise.resolve()};
760
760
  r.update=function(){};r.onExpirationUpdated=function(a,b){var c=this,d,e,f,g,h,k,l;return L(function(m){switch(m.g){case 1:return d=c.g,e=new ps,C(m,2,3),u(m,e.init(),5);case 5:return u(m,ts(e,d.Ca(),d.la()),6);case 6:return f=m.h,u(m,f.getManifests([d.key()]),7);case 7:g=m.h;h=g[0];k=h.sessionIds.includes(a);l=void 0==h.expiration||h.expiration>b;if(!k||!l){m.B(3);break}return u(m,f.updateManifestExpiration(d.key(),b),3);case 3:return wa(m),u(m,e.destroy(),10);case 10:ya(m,0);break;case 2:E(m),m.B(3)}})};
761
761
  Bg["application/x-offline-manifest"]=function(){return new Qs};function Rs(){}function Ss(a){var b=Js(a);b&&"manifest"==b.g?(a={uri:a,ve:a,data:new ArrayBuffer(0),headers:{"content-type":"application/x-offline-manifest"}},a=Ie(a)):a=b&&"segment"==b.g?Ts(b.key(),b):Ge(new N(2,1,9004,a));return a}
762
- function Ts(a,b){var c=new ps;return Ie(void 0).$(function(){return c.init()}).$(function(){return ts(c,b.Ca(),b.la())}).$(function(d){return d.getSegments([b.key()])}).$(function(d){return{uri:b,data:d[0].data,headers:{}}})["finally"](function(){return c.destroy()})}M("shaka.offline.OfflineScheme",Rs);Rs.plugin=Ss;Te("offline",Ss);function Us(a,b,c){var d,e,f,g,h,k;return L(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 q=!1,v=t(m),y=v.next();!y.done;y=v.next())if(y=y.value,Vs(y.info,p)){y.sessionIds.push(p.sessionId);q=!0;break}q||m.push({info:p,sessionIds:[p.sessionId]})}e=t(m);f=e.next();case 2:if(f.done){l.B(4);break}g=f.value;h=Ws(a,b,g);return u(l,h,5);case 5:k=l.h;d=d.concat(k);f=e.next();l.B(2);break;case 4:return l["return"](d)}})}
762
+ function Ts(a,b){var c=new ps;return Ie(void 0).$(function(){return c.init()}).$(function(){return ts(c,b.Ca(),b.la())}).$(function(d){return d.getSegments([b.key()])}).$(function(d){return{uri:b,data:d[0].data,headers:{}}})["finally"](function(){return c.destroy()})}M("shaka.offline.OfflineScheme",Rs);Rs.plugin=Ss;Te("offline",Ss);function Us(a,b,c){var d,e,f,g,h,k;return L(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 q=!1,v=t(m),w=v.next();!w.done;w=v.next())if(w=w.value,Vs(w.info,p)){w.sessionIds.push(p.sessionId);q=!0;break}q||m.push({info:p,sessionIds:[p.sessionId]})}e=t(m);f=e.next();case 2:if(f.done){l.B(4);break}g=f.value;h=Ws(a,b,g);return u(l,h,5);case 5:k=l.h;d=d.concat(k);f=e.next();l.B(2);break;case 4:return l["return"](d)}})}
763
763
  function Ws(a,b,c){var d,e;return L(function(f){switch(f.g){case 1:return d=new Pf({nb:b,onError:function(){},Pc:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),C(f,2),d.configure(a),u(f,Xf(d,c.info.keySystem,c.info.licenseUri,c.info.serverCertificate,c.info.audioCapabilities,c.info.videoCapabilities),4);case 4:va(f,3);break;case 2:return E(f),u(f,d.destroy(),5);case 5:return f["return"]([]);case 3:return C(f,6),u(f,fg(d),8);case 8:va(f,7);break;case 6:return E(f),u(f,d.destroy(),
764
764
  9);case 9:return f["return"]([]);case 7:return e=[],u(f,Promise.all(c.sessionIds.map(function(g){return L(function(h){if(1==h.g)return C(h,2),u(h,gg(d,g),4);if(2!=h.g)return e.push(g),va(h,0);E(h);A(h)})})),10);case 10:return u(f,d.destroy(),11);case 11:return f["return"](e)}})}
765
765
  function Vs(a,b){function c(d,e){return d.robustness==e.robustness&&d.contentType==e.contentType}return a.keySystem==b.keySystem&&a.licenseUri==b.licenseUri&&gb(a.audioCapabilities,b.audioCapabilities,c)&&gb(a.videoCapabilities,b.videoCapabilities,c)};function Xs(a,b,c){var d=b.presentationTimeline.getDuration();b=Ys(b);return{offlineUri:null,originalManifestUri:a,duration:d,size:0,expiration:Infinity,tracks:b,appMetadata:c,isIncomplete:!1}}function Zs(a,b){var c=Ls(new Ks(a.Ca(),a.la()),b),d=b.appMetadata||{};c=Ys(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}}
@@ -768,18 +768,18 @@ case 4:b.h=null,b.g=null,A(k)}})})}function et(){if(uc())a:{var a=t(qs.values())
768
768
  r.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=Rk(a,b));a.manifest&&a.manifest.dash&&"defaultPresentationDelay"in a.manifest.dash&&(Kb("manifest.dash.defaultPresentationDelay configuration","Please Use manifest.defaultPresentationDelay instead."),a.manifest.defaultPresentationDelay=a.manifest.dash.defaultPresentationDelay,delete a.manifest.dash.defaultPresentationDelay);return Wk(this.h,a)};r.getConfiguration=function(){var a=Uk();Wk(a,this.h,Uk());return a};r.dc=function(){return this.g};
769
769
  r.store=function(a,b,c){var d=this,e=this.getConfiguration(),f=new Zr(this.g);this.j.push(f);b=ft(this,a,b||{},function(){var h;return L(function(k){if(1==k.g)return u(k,Ag(a,d.g,e.manifest.retryParameters,c||null),2);h=k.h;return k["return"](Sb(h))})},e,f);var g=new Fe(b,function(){return $r(f)});g["finally"](function(){fb(d.j,f)});g.then=function(h){Kb("shaka.offline.Storage.store.then","Storage operations now return a shaka.util.AbortableOperation, rather than a promise. Please update to conform to this new API; you can use the |chain| method instead.");
770
770
  return g.promise.then(h)};return gt(this,g)};r.tf=function(){Kb("shaka.offline.Storage.getStoreInProgress","Multiple concurrent downloads are now supported.");return!1};
771
- function ft(a,b,c,d,e,f){var g,h,k,l,m,n,p,q,v,y,w,x,D,z;return L(function(B){switch(B.g){case 1:return ht(),h=g=null,k=new ps,n=m=l=null,C(B,2,3),u(B,d(),5);case 5:return g=B.h,u(B,it(a,b,g,e),6);case 6:p=B.h;jt(a);q=!p.presentationTimeline.T()&&!p.presentationTimeline.mb();if(!q)throw new N(2,9,9005,b);return u(B,kt(a,p,function(F){n=n||F},e),7);case 7:h=B.h;jt(a);if(n)throw n;return u(B,lt(p,e),8);case 8:return u(B,k.init(),9);case 9:return jt(a),u(B,rs(k),10);case 10:return l=B.h,jt(a),v=mt(h,
772
- p,b,c,e,f),y=v.Ef,w=v.$d,u(B,l.la.addManifests([y]),11);case 11:x=B.h;jt(a);m=x[0];jt(a);if(n)throw n;return u(B,nt(a,w,m,y,f,e,l.la,p,h),12);case 12:return jt(a),D=new Is("manifest",l.path.Ca,l.path.la,m),B["return"](Zs(D,y));case 3:return wa(B),u(B,k.destroy(),13);case 13:if(!g){B.B(14);break}return u(B,g.stop(),14);case 14:if(!h){B.B(16);break}return u(B,h.destroy(),16);case 16:ya(B,0);break;case 2:z=E(B);if(null==m){B.B(18);break}return u(B,ot(m),18);case 18:throw n||z;}})}
773
- function nt(a,b,c,d,e,f,g,h,k){var l,m,n,p,q,v,y,w,x,D;return L(function(z){switch(z.g){case 1:l={};m=0;n=function(B,F){var G,H,I,J,K,P,R;return L(function(ba){if(1==ba.g){G={};H=t(B);for(I=H.next();!I.done;G={bb:G.bb},I=H.next())G.bb=I.value,J=Wr(G.bb,f),K=G.bb.i,P=G.bb.h,R=function(aa){return function(Y){var Da,Fa,xa;return L(function(Ia){if(1==Ia.g)return u(Ia,g.addSegments([{data:Y}]),2);Da=Ia.h;jt(a);Fa=aa.bb.g;xa=Vr(Fa);l[xa]=Da[0];m+=Y.byteLength;A(Ia)})}}(G),bs(e,G.bb.groupId,J,K,P,R);return u(ba,
774
- ds(e),2)}if(!F)return ba.B(0);jt(a);pt(h,d,k,f);return u(ba,g.updateManifest(c,d),0)})};p=!1;C(z,2);if(!qt(h)||!p||rt(h)){z.B(4);break}return u(z,n(b.filter(function(B){return B.h}),!0),5);case 5:return jt(a),b=b.filter(function(B){return!B.h}),q=l,v=m,l={},m=0,u(z,st(g,c,d,q,v,function(){return jt(a)}),6);case 6:jt(a);case 4:if(p){z.B(7);break}return u(z,n(b,!1),8);case 8:return jt(a),y=l,w=m,l={},m=0,u(z,st(g,c,d,y,w,function(){return jt(a)}),9);case 9:jt(a);case 7:va(z,0);break;case 2:return x=
775
- E(z),D=Object.values(l),u(z,g.removeSegments(D,function(){}),10);case 10:throw x;}})}function ot(a){var b,c,d,e;return L(function(f){switch(f.g){case 1:return b=new ps,u(f,b.init(),2);case 2:return u(f,rs(b),3);case 3:return c=f.h,d=new Is("manifest",c.path.Ca,c.path.la,a),u(f,b.destroy(),4);case 4:return e=new dt,u(f,e.remove(d.toString()),0)}})}
776
- function st(a,b,c,d,e,f){var g,h,k,l,m,n,p,q,v,y,w;return L(function(x){switch(x.g){case 1:g=!1;C(x,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())q=p.value,v=q.pendingSegmentRefId?d[q.pendingSegmentRefId]:null,null!=v&&(q.dataKey=v,q.pendingSegmentRefId=void 0),v=q.pendingInitSegmentRefId?d[q.pendingInitSegmentRefId]:null,null!=v&&(q.initSegmentKey=v,q.pendingInitSegmentRefId=void 0),q.pendingSegmentRefId&&(h=!1),q.pendingInitSegmentRefId&&
777
- (h=!1);c.size+=e;h&&(c.isIncomplete=!1);return u(x,a.updateManifest(b,c),4);case 4:g=!0;f();va(x,0);break;case 2:return y=E(x),u(x,ot(b),5);case 5:if(g){x.B(6);break}w=Object.values(d);return u(x,a.removeSegments(w,function(){}),6);case 6:throw y;}})}
778
- function lt(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v,y,w,x,D,z,B,F,G,H,I,J,K,P,R,ba,aa;return L(function(Y){switch(Y.g){case 1:return c={width:Infinity,height:Infinity},Nd(a,b.restrictions,c),u(Y,Qd(a,b.offline.usePersistentLicense),2);case 2:d=[];e=b.preferredAudioChannelCount;f=b.preferredDecodingAttributes;g=b.preferredVideoCodecs;h=b.preferredAudioCodecs;Bd(a,g,h,e,f);k=t(a.variants);for(l=k.next();!l.done;l=k.next())m=l.value,d.push($d(m));n=t(a.textStreams);for(p=n.next();!p.done;p=n.next())q=p.value,
779
- d.push(ae(q));v=t(a.imageStreams);for(y=v.next();!y.done;y=v.next())w=y.value,d.push(be(w));return u(Y,b.offline.trackSelectionCallback(d),3);case 3:x=Y.h;D=a.presentationTimeline.getDuration();z=0;B=t(x);for(F=B.next();!F.done;F=B.next())G=F.value,H=G.bandwidth*D/8,z+=H;C(Y,4);return u(Y,b.offline.downloadSizeCallback(z),6);case 6:I=Y.h;if(!I)throw new N(2,9,9014);va(Y,5);break;case 4:J=E(Y);if(J instanceof N)throw J;throw new N(2,9,9015);case 5:K=new Set;P=new Set;R=new Set;ba=t(x);for(F=ba.next();!F.done;F=
771
+ function ft(a,b,c,d,e,f){var g,h,k,l,m,n,p,q,v,w,x,y,D,z;return L(function(B){switch(B.g){case 1:return ht(),h=g=null,k=new ps,n=m=l=null,C(B,2,3),u(B,d(),5);case 5:return g=B.h,u(B,it(a,b,g,e),6);case 6:p=B.h;jt(a);q=!p.presentationTimeline.U()&&!p.presentationTimeline.mb();if(!q)throw new N(2,9,9005,b);return u(B,kt(a,p,function(F){n=n||F},e),7);case 7:h=B.h;jt(a);if(n)throw n;return u(B,lt(p,e),8);case 8:return u(B,k.init(),9);case 9:return jt(a),u(B,rs(k),10);case 10:return l=B.h,jt(a),v=mt(h,
772
+ p,b,c,e,f),w=v.Ef,x=v.ae,u(B,l.la.addManifests([w]),11);case 11:y=B.h;jt(a);m=y[0];jt(a);if(n)throw n;return u(B,nt(a,x,m,w,f,e,l.la,p,h),12);case 12:return jt(a),D=new Is("manifest",l.path.Ca,l.path.la,m),B["return"](Zs(D,w));case 3:return wa(B),u(B,k.destroy(),13);case 13:if(!g){B.B(14);break}return u(B,g.stop(),14);case 14:if(!h){B.B(16);break}return u(B,h.destroy(),16);case 16:ya(B,0);break;case 2:z=E(B);if(null==m){B.B(18);break}return u(B,ot(m),18);case 18:throw n||z;}})}
773
+ function nt(a,b,c,d,e,f,g,h,k){var l,m,n,p,q,v,w,x,y,D;return L(function(z){switch(z.g){case 1:l={};m=0;n=function(B,F){var G,H,I,J,K,P,R;return L(function(ba){if(1==ba.g){G={};H=t(B);for(I=H.next();!I.done;G={bb:G.bb},I=H.next())G.bb=I.value,J=Wr(G.bb,f),K=G.bb.i,P=G.bb.h,R=function(aa){return function(Y){var Da,Fa,xa;return L(function(Ja){if(1==Ja.g)return u(Ja,g.addSegments([{data:Y}]),2);Da=Ja.h;jt(a);Fa=aa.bb.g;xa=Vr(Fa);l[xa]=Da[0];m+=Y.byteLength;A(Ja)})}}(G),bs(e,G.bb.groupId,J,K,P,R);return u(ba,
774
+ ds(e),2)}if(!F)return ba.B(0);jt(a);pt(h,d,k,f);return u(ba,g.updateManifest(c,d),0)})};p=!1;C(z,2);if(!qt(h)||!p||rt(h)){z.B(4);break}return u(z,n(b.filter(function(B){return B.h}),!0),5);case 5:return jt(a),b=b.filter(function(B){return!B.h}),q=l,v=m,l={},m=0,u(z,st(g,c,d,q,v,function(){return jt(a)}),6);case 6:jt(a);case 4:if(p){z.B(7);break}return u(z,n(b,!1),8);case 8:return jt(a),w=l,x=m,l={},m=0,u(z,st(g,c,d,w,x,function(){return jt(a)}),9);case 9:jt(a);case 7:va(z,0);break;case 2:return y=
775
+ E(z),D=Object.values(l),u(z,g.removeSegments(D,function(){}),10);case 10:throw y;}})}function ot(a){var b,c,d,e;return L(function(f){switch(f.g){case 1:return b=new ps,u(f,b.init(),2);case 2:return u(f,rs(b),3);case 3:return c=f.h,d=new Is("manifest",c.path.Ca,c.path.la,a),u(f,b.destroy(),4);case 4:return e=new dt,u(f,e.remove(d.toString()),0)}})}
776
+ function st(a,b,c,d,e,f){var g,h,k,l,m,n,p,q,v,w,x;return L(function(y){switch(y.g){case 1:g=!1;C(y,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())q=p.value,v=q.pendingSegmentRefId?d[q.pendingSegmentRefId]:null,null!=v&&(q.dataKey=v,q.pendingSegmentRefId=void 0),v=q.pendingInitSegmentRefId?d[q.pendingInitSegmentRefId]:null,null!=v&&(q.initSegmentKey=v,q.pendingInitSegmentRefId=void 0),q.pendingSegmentRefId&&(h=!1),q.pendingInitSegmentRefId&&
777
+ (h=!1);c.size+=e;h&&(c.isIncomplete=!1);return u(y,a.updateManifest(b,c),4);case 4:g=!0;f();va(y,0);break;case 2:return w=E(y),u(y,ot(b),5);case 5:if(g){y.B(6);break}x=Object.values(d);return u(y,a.removeSegments(x,function(){}),6);case 6:throw w;}})}
778
+ function lt(a,b){var c,d,e,f,g,h,k,l,m,n,p,q,v,w,x,y,D,z,B,F,G,H,I,J,K,P,R,ba,aa;return L(function(Y){switch(Y.g){case 1:return c={width:Infinity,height:Infinity},Nd(a,b.restrictions,c),u(Y,Qd(a,b.offline.usePersistentLicense),2);case 2:d=[];e=b.preferredAudioChannelCount;f=b.preferredDecodingAttributes;g=b.preferredVideoCodecs;h=b.preferredAudioCodecs;Bd(a,g,h,e,f);k=t(a.variants);for(l=k.next();!l.done;l=k.next())m=l.value,d.push($d(m));n=t(a.textStreams);for(p=n.next();!p.done;p=n.next())q=p.value,
779
+ d.push(ae(q));v=t(a.imageStreams);for(w=v.next();!w.done;w=v.next())x=w.value,d.push(be(x));return u(Y,b.offline.trackSelectionCallback(d),3);case 3:y=Y.h;D=a.presentationTimeline.getDuration();z=0;B=t(y);for(F=B.next();!F.done;F=B.next())G=F.value,H=G.bandwidth*D/8,z+=H;C(Y,4);return u(Y,b.offline.downloadSizeCallback(z),6);case 6:I=Y.h;if(!I)throw new N(2,9,9014);va(Y,5);break;case 4:J=E(Y);if(J instanceof N)throw J;throw new N(2,9,9015);case 5:K=new Set;P=new Set;R=new Set;ba=t(y);for(F=ba.next();!F.done;F=
780
780
  ba.next())aa=F.value,"variant"==aa.type&&K.add(aa.id),"text"==aa.type&&P.add(aa.id),"image"==aa.type&&R.add(aa.id);a.variants=a.variants.filter(function(Da){return K.has(Da.id)});a.textStreams=a.textStreams.filter(function(Da){return P.has(Da.id)});a.imageStreams=a.imageStreams.filter(function(Da){return R.has(Da.id)});tt(a);A(Y)}})}
781
- function mt(a,b,c,d,e,f){var g=Xs(c,b,d),h=e.offline.progressCallback;as(f,function(q,v){g.size=v;h(g,q)},function(q,v){k&&e.offline.usePersistentLicense&&l==v&&eg(a,"cenc",q)});var k=qt(b)&&!rt(b),l=null;k&&(l=ut.get(a.g.keySystem));for(var m=new $s,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())bt(m,p.value);p=t(b.variants);for(n=p.next();!n.done;n=p.next())at(m,n.value);m=vt(f,m,b);f=m.streams;m=m.$d;p=a.g;n=e.offline.usePersistentLicense;
782
- p&&n&&(p.initData=[]);return{Ef:{creationTime:Date.now(),originalManifestUri:c,duration:b.presentationTimeline.getDuration(),size:0,expiration:a.cc(),streams:f,sessionIds:n?kg(a):[],drmInfo:p,appMetadata:d,isIncomplete:!0},$d:m}}function qt(a){return a.variants.some(function(b){var c=b.audio&&b.audio.encrypted;return b.video&&b.video.encrypted||c})}
781
+ function mt(a,b,c,d,e,f){var g=Xs(c,b,d),h=e.offline.progressCallback;as(f,function(q,v){g.size=v;h(g,q)},function(q,v){k&&e.offline.usePersistentLicense&&l==v&&eg(a,"cenc",q)});var k=qt(b)&&!rt(b),l=null;k&&(l=ut.get(a.g.keySystem));for(var m=new $s,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())bt(m,p.value);p=t(b.variants);for(n=p.next();!n.done;n=p.next())at(m,n.value);m=vt(f,m,b);f=m.streams;m=m.ae;p=a.g;n=e.offline.usePersistentLicense;
782
+ p&&n&&(p.initData=[]);return{Ef:{creationTime:Date.now(),originalManifestUri:c,duration:b.presentationTimeline.getDuration(),size:0,expiration:a.cc(),streams:f,sessionIds:n?kg(a):[],drmInfo:p,appMetadata:d,isIncomplete:!0},ae:m}}function qt(a){return a.variants.some(function(b){var c=b.audio&&b.audio.encrypted;return b.video&&b.video.encrypted||c})}
783
783
  function rt(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 pt(a,b,c,d){b.expiration=c.cc();c=kg(c);b.sessionIds=d.offline.usePersistentLicense?c:[];if(qt(a)&&d.offline.usePersistentLicense&&!c.length)throw new N(2,9,9007);}r.remove=function(a){return wt(this,xt(this,a))};
784
784
  function xt(a,b){var c,d,e,f,g,h;return L(function(k){switch(k.g){case 1:ht();c=Js(b);if(null==c||"manifest"!=c.g)throw new N(2,9,9004,b);d=c;e=new ps;ua(k);return u(k,e.init(),4);case 4:return u(k,ts(e,d.Ca(),d.la()),5);case 5:return f=k.h,u(k,f.getManifests([d.key()]),6);case 6:return g=k.h,h=g[0],u(k,Promise.all([yt(a,h,e),zt(f,d,h)]),2);case 2:return wa(k),u(k,e.destroy(),8);case 8:ya(k,0)}})}
785
785
  function At(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:ad(e.mimeType,e.codecs),robustness:a.drmInfo.videoRobustness}):b||"audio"!=e.type||c.push({contentType:ad(e.mimeType,e.codecs),robustness:a.drmInfo.audioRobustness});return c}function yt(a,b,c){return L(function(d){return u(d,Bt(a.g,a.h.drm,c,b),0)})}
@@ -788,9 +788,9 @@ function Dt(a){var b,c,d,e,f,g,h,k,l,m;return L(function(n){switch(n.g){case 1:r
788
788
  r.list=function(){return wt(this,Et())};function Et(){var a,b,c;return L(function(d){switch(d.g){case 1:return ht(),a=[],b=new ps,ua(d),u(d,b.init(),4);case 4:return c=Promise.resolve(),ss(b,function(e,f){c=c.then(function(){var g;return L(function(h){if(1==h.g)return u(h,f.getAllManifests(),2);g=h.h;g.forEach(function(k,l){var m=Zs(new Is("manifest",e.Ca,e.la,l),k);a.push(m)});A(h)})})}),u(d,c,2);case 2:return wa(d),u(d,b.destroy(),6);case 6:ya(d,3);break;case 3:return d["return"](a)}})}
789
789
  function it(a,b,c,d){var e,f,g,h,k;return L(function(l){if(1==l.g)return e=null,f=a.g,g={networkingEngine:f,modifyManifestRequest:function(){},modifySegmentRequest:function(){},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(){}},c.configure(d.manifest),jt(a),u(l,c.start(b,
790
790
  g),2);if(3!=l.g)return h=l.h,jt(a),k=Ft(h),u(l,Promise.all(nf(k,function(m){return m.createSegmentIndex()})),3);jt(a);if(e)throw e;return l["return"](h)})}function kt(a,b,c,d){var e;return L(function(f){switch(f.g){case 1:return e=new Pf({nb:a.g,onError:c,Pc:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),e.configure(d.drm),u(f,Uf(e,b.variants,d.offline.usePersistentLicense),2);case 2:return u(f,fg(e),3);case 3:return u(f,dg(e),4);case 4:return f["return"](e)}})}
791
- function vt(a,b,c){var d=new Map,e=Ft(c),f=new Map;e=t(e);for(var g=e.next();!g.done;g=e.next()){g=g.value;var h=Gt(a,b,c,g,d);f.set(g.id,h)}a=t(c.variants);for(b=a.next();!b.done;b=a.next())b=b.value,b.audio&&f.get(b.audio.id).variantIds.push(b.id),b.video&&f.get(b.video.id).variantIds.push(b.id);return{streams:Array.from(f.values()),$d:Array.from(d.values())}}
791
+ function vt(a,b,c){var d=new Map,e=Ft(c),f=new Map;e=t(e);for(var g=e.next();!g.done;g=e.next()){g=g.value;var h=Gt(a,b,c,g,d);f.set(g.id,h)}a=t(c.variants);for(b=a.next();!b.done;b=a.next())b=b.value,b.audio&&f.get(b.audio.id).variantIds.push(b.id),b.video&&f.get(b.video.id).variantIds.push(b.id);return{streams:Array.from(f.values()),ae:Array.from(d.values())}}
792
792
  function Gt(a,b,c,d,e){var f={id:d.id,originalId:d.originalId,primary:d.primary,type:d.type,mimeType:d.mimeType,codecs:d.codecs,frameRate:d.frameRate,pixelAspectRatio:d.pixelAspectRatio,hdr:d.hdr,kind:d.kind,language:d.language,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,audioSamplingRate:d.audioSamplingRate,spatialAudio:d.spatialAudio,closedCaptions:d.closedCaptions,
793
- tilesLayout:d.tilesLayout};Ht(d,c.presentationTimeline.Qa(),function(g){var h=Vr(g),k=void 0;if(!e.has(h)){var l=g.endTime-g.startTime;l=ct(b,d.id)*l;l=Yr(a.g,l);e.set(h,new Ur(g,l,d.id,!1))}g.g&&(k=Vr(g.g),e.has(k)||(l=.5*ct(b,d.id),l=Yr(a.g,l),e.set(k,new Ur(g.g,l,d.id,!0))));f.segments.push({pendingInitSegmentRefId:k,initSegmentKey:k?0:null,startTime:g.startTime,endTime:g.endTime,appendWindowStart:g.appendWindowStart,appendWindowEnd:g.appendWindowEnd,timestampOffset:g.timestampOffset,tilesLayout:g.tilesLayout,
793
+ tilesLayout:d.tilesLayout};Ht(d,c.presentationTimeline.Ra(),function(g){var h=Vr(g),k=void 0;if(!e.has(h)){var l=g.endTime-g.startTime;l=ct(b,d.id)*l;l=Yr(a.g,l);e.set(h,new Ur(g,l,d.id,!1))}g.g&&(k=Vr(g.g),e.has(k)||(l=.5*ct(b,d.id),l=Yr(a.g,l),e.set(k,new Ur(g.g,l,d.id,!0))));f.segments.push({pendingInitSegmentRefId:k,initSegmentKey:k?0:null,startTime:g.startTime,endTime:g.endTime,appendWindowStart:g.appendWindowStart,appendWindowEnd:g.appendWindowEnd,timestampOffset:g.timestampOffset,tilesLayout:g.tilesLayout,
794
794
  pendingSegmentRefId:h,dataKey:0})});return f}function Ht(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 jt(a){if(a.l.g)throw new N(2,9,7001);}function ht(){if(!et())throw new N(2,9,9E3);}function wt(a,b){return L(function(c){if(1==c.g)return a.i.push(b),ua(c),u(c,b,4);if(2!=c.g)return c["return"](c.h);wa(c);fb(a.i,b);return ya(c,0)})}function gt(a,b){var c=b.promise;a.i.push(c);return b["finally"](function(){fb(a.i,c)})}
795
795
  function Ct(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)}
796
796
  function Bt(a,b,c,d){var e,f,g;return L(function(h){if(1==h.g){if(!d.drmInfo)return h["return"]();e=vs(c);f=d.sessionIds.map(function(k){return{sessionId:k,keySystem:d.drmInfo.keySystem,licenseUri:d.drmInfo.licenseServerUri,serverCertificate:d.drmInfo.serverCertificate,audioCapabilities:At(d,!1),videoCapabilities:At(d,!0)}});return u(h,Us(b,a,f),2)}return 3!=h.g?(g=h.h,u(h,e.remove(g),3)):u(h,e.add(f.filter(function(k){return!g.includes(k.sessionId)})),0)})}
@@ -801,11 +801,11 @@ var ut=(new Map).set("org.w3.clearkey","1077efecc0b24d02ace33c1e52e2fb4b").set("
801
801
  Zm.offline=et;function It(){}function Jt(a,b){for(var c={priority:b||0,Pe:a},d=0;d<Kt.length;d++)if(Kt[d].priority<c.priority){Kt.splice(d,0,c);return}Kt.push(c)}M("shaka.polyfill",It);It.register=Jt;It.installAll=function(){for(var a=t(Kt),b=a.next();!b.done;b=a.next()){b=b.value;try{b.Pe()}catch(c){Ua("Error installing polyfill!",c)}}};var Kt=[];function Lt(){}function Mt(){if(!Object.getOwnPropertyDescriptor(Element.prototype,"ariaHidden"))for(var a=t(["ariaHidden","ariaLabel","ariaPressed","ariaSelected"]),b=a.next();!b.done;b=a.next())Nt(b.value)}function Nt(a){var b="aria-"+a.toLowerCase().replace(/^aria/,"");Object.defineProperty(Element.prototype,a,{get:function(){return this.getAttribute(b)},set:function(c){null==c||void 0==c?this.removeAttribute(b):this.setAttribute(b,c)}})}It.Aria=Lt;Lt.install=Mt;Jt(Mt);function Ot(){}function Pt(){Qt()}It.EncryptionScheme=Ot;Ot.install=Pt;Jt(Pt,-2);function Rt(){}
802
802
  function St(){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}}),
803
803
  Object.defineProperty(document,"fullscreenEnabled",{get:function(){return document.mozFullScreenEnabled||document.msFullscreenEnabled||document.webkitFullscreenEnabled}}));document.addEventListener("webkitfullscreenchange",Tt);document.addEventListener("webkitfullscreenerror",Tt);document.addEventListener("mozfullscreenchange",Tt);document.addEventListener("mozfullscreenerror",Tt);document.addEventListener("MSFullscreenChange",Tt);document.addEventListener("MSFullscreenError",Tt)}}
804
- function Tt(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)}It.Fullscreen=Rt;Rt.install=St;Jt(St);function Ut(){}function Vt(){}It.MathRound=Ut;Ut.install=Vt;Jt(Vt);function Wt(){}function Xt(){if(Bc()||Cc()||Dc()||yc("PlayStation 5")||Ac()||zc()||yc("PC=EOS")||!navigator.mediaCapabilities)navigator.mediaCapabilities||(navigator.mediaCapabilities={}),Yt=navigator.mediaCapabilities,navigator.mediaCapabilities.decodingInfo=Zt}
805
- function Zt(a){var b,c,d,e,f,g,h,k,l,m,n,p,q,v,y,w,x;return L(function(D){switch(D.g){case 1:b={supported:!1,powerEfficient:!0,smooth:!0,keySystemAccess:null,configuration:a};if(!a)return D["return"](b);c=a.video;d=a.audio;if("media-source"==a.type){if(!uc())return D["return"](b);if(c){if(Bc()){if(!window.cast)throw new N(2,8,8E3);if(cast.__platform__&&cast.__platform__.canDisplayType){var z=c.contentType;c.width&&c.height&&(z+="; width="+c.width+"; height="+c.height);c.framerate&&(z+="; framerate="+
804
+ function Tt(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)}It.Fullscreen=Rt;Rt.install=St;Jt(St);function Ut(){}function Vt(){}It.MathRound=Ut;Ut.install=Vt;Jt(Vt);function Wt(){}function Xt(){if(Bc()||Cc()||Dc()||yc("PlayStation 5")||Ac()||zc()||yc("PC=EOS")||yc("Hisense")||yc("VIDAA")||!navigator.mediaCapabilities)navigator.mediaCapabilities||(navigator.mediaCapabilities={}),Yt=navigator.mediaCapabilities,navigator.mediaCapabilities.decodingInfo=Zt}
805
+ function Zt(a){var b,c,d,e,f,g,h,k,l,m,n,p,q,v,w,x,y;return L(function(D){switch(D.g){case 1:b={supported:!1,powerEfficient:!0,smooth:!0,keySystemAccess:null,configuration:a};if(!a)return D["return"](b);c=a.video;d=a.audio;if("media-source"==a.type){if(!uc())return D["return"](b);if(c){if(Bc()){if(!window.cast)throw new N(2,8,8E3);if(cast.__platform__&&cast.__platform__.canDisplayType){var z=c.contentType;c.width&&c.height&&(z+="; width="+c.width+"; height="+c.height);c.framerate&&(z+="; framerate="+
806
806
  c.framerate);"pq"===c.transferFunction&&(z+="; eotf=smpte2084");z=cast.__platform__.canDisplayType(z)}else z=MediaSource.isTypeSupported(c.contentType)}else z=MediaSource.isTypeSupported(c.contentType);e=z;if(!e)return D["return"](b)}if(d&&(f=d.contentType,g=MediaSource.isTypeSupported(f),!g))return D["return"](b)}else if("file"==a.type){if(c&&(h=c.contentType,k=vc(h),!k)||d&&(l=d.contentType,m=vc(l),!m))return D["return"](b)}else return D["return"](b);if(!a.keySystemConfiguration)return b.supported=
807
- !0,D["return"](Promise.resolve(b));n=a.keySystemConfiguration;p=[];q=[];n.audio&&(v={robustness:n.audio.robustness||"",contentType:a.audio.contentType},p.push(v));n.video&&(y={robustness:n.video.robustness||"",contentType:a.video.contentType},q.push(y));w={initDataTypes:[n.initDataType],distinctiveIdentifier:n.distinctiveIdentifier,persistentState:n.persistentState,sessionTypes:n.sessionTypes};p.length&&(w.audioCapabilities=p);q.length&&(w.videoCapabilities=q);C(D,3);return u(D,navigator.requestMediaKeySystemAccess(n.keySystem,
808
- [w]),5);case 5:x=D.h;va(D,4);break;case 3:E(D);case 4:x&&(b.supported=!0,b.keySystemAccess=x);case 2:return D["return"](b)}})}It.MediaCapabilities=Wt;Wt.install=Xt;var Yt=null;Wt.originalMcap=Yt;Jt(Xt,-1);function $t(){}function au(){var a=Fc();window.MediaSource&&(window.cast&&cast.__platform__&&cast.__platform__.canDisplayType?bu():a?(cu(),12>=a?(du(),eu()):du()):(yc("Tizen 2")||yc("Tizen 3")||yc("Tizen 4"))&&fu());window.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&gu()}
807
+ !0,D["return"](Promise.resolve(b));n=a.keySystemConfiguration;p=[];q=[];n.audio&&(v={robustness:n.audio.robustness||"",contentType:a.audio.contentType},p.push(v));n.video&&(w={robustness:n.video.robustness||"",contentType:a.video.contentType},q.push(w));x={initDataTypes:[n.initDataType],distinctiveIdentifier:n.distinctiveIdentifier,persistentState:n.persistentState,sessionTypes:n.sessionTypes};p.length&&(x.audioCapabilities=p);q.length&&(x.videoCapabilities=q);C(D,3);return u(D,navigator.requestMediaKeySystemAccess(n.keySystem,
808
+ [x]),5);case 5:y=D.h;va(D,4);break;case 3:E(D);case 4:y&&(b.supported=!0,b.keySystemAccess=y);case 2:return D["return"](b)}})}It.MediaCapabilities=Wt;Wt.install=Xt;var Yt=null;Wt.originalMcap=Yt;Jt(Xt,-1);function $t(){}function au(){var a=Fc();window.MediaSource&&(window.cast&&cast.__platform__&&cast.__platform__.canDisplayType?bu():a?(cu(),12>=a?(du(),eu()):du()):(yc("Tizen 2")||yc("Tizen 3")||yc("Tizen 4"))&&fu());window.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&gu()}
809
809
  function du(){var a=MediaSource.prototype.addSourceBuffer;MediaSource.prototype.addSourceBuffer=function(){var b=a.apply(this,Ha.apply(0,arguments));b.abort=function(){};return b}}function eu(){var a=SourceBuffer.prototype.remove;SourceBuffer.prototype.remove=function(b,c){return a.call(this,b,c-.001)}}function cu(){var a=MediaSource.isTypeSupported;MediaSource.isTypeSupported=function(b){return"mp2t"==b.split(/ *; */)[0].split("/")[1].toLowerCase()?!1:a(b)}}
810
810
  function fu(){var a=MediaSource.isTypeSupported;MediaSource.isTypeSupported=function(b){return"opus"!=dd(b)[0]&&a(b)}}function bu(){var a=MediaSource.isTypeSupported;MediaSource.isTypeSupported=function(b){var c=b.split(/ *; */);c.shift();return c.some(function(d){return d.startsWith("codecs=")})?cast.__platform__.canDisplayType(b):a(b)}}
811
811
  function gu(){var a=MediaSource.isTypeSupported;Ac()||(MediaSource.isTypeSupported=function(b){var c=b.split(/ *; */),d=c.findIndex(function(g){return g.startsWith("codecs=")});if(0>d)return a(b);var e=c[d].replace("codecs=","").replace(/"/g,"").split(/\s*,\s*/),f=e.findIndex(function(g){return g.startsWith("vp09")});0<=f&&(e[f]="vp9",c[d]='codecs="'+e.join(",")+'"',b=c.join("; "));return a(b)})}It.MediaSource=$t;$t.install=au;Jt(au);function hu(){}function iu(){screen.orientation||void 0!=window.orientation&&ju()}function ju(){function a(){switch(window.orientation){case -90:b.type="landscape-secondary";b.angle=270;break;case 0:b.type="portrait-primary";b.angle=0;break;case 90:b.type="landscape-primary";b.angle=90;break;case 180:b.type="portrait-secondary",b.angle=180}}var b=new ku;screen.orientation=b;a();window.addEventListener("orientationchange",function(){a();var c=new Q("change");b.dispatchEvent(c)})}It.Orientation=hu;
@@ -816,27 +816,27 @@ function nu(a){var b=this.mediaKeys;b&&b!=a&&ru(b,null);delete this.mediaKeys;re
816
816
  function pu(a,b){this.keySystem=a;if(a.startsWith("com.apple.fps"))for(var c=t(b),d=c.next();!d.done;d=c.next()){var e=d.value;if("required"==e.persistentState)d=null;else{d={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:e.initDataTypes,sessionTypes:["temporary"],label:e.label};var f=!1,g=!1;if(e.audioCapabilities)for(var h=t(e.audioCapabilities),k=h.next();!k.done;k=h.next())k=k.value,k.contentType&&(f=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,
817
817
  k.contentType.split(";")[0])&&(d.audioCapabilities.push(k),g=!0));if(e.videoCapabilities)for(e=t(e.videoCapabilities),k=e.next();!k.done;k=e.next())h=k.value,h.contentType&&(f=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,h.contentType.split(";")[0])&&(d.videoCapabilities.push(h),g=!0));f||(g=WebKitMediaKeys.isTypeSupported(this.keySystem,"video/mp4"));d=g?d:null}if(d){this.g=d;return}}c=Error("Unsupported keySystem");c.name="NotSupportedError";c.code=DOMException.NOT_SUPPORTED_ERR;throw c;}
818
818
  pu.prototype.createMediaKeys=function(){var a=new ou(this.keySystem);return Promise.resolve(a)};pu.prototype.getConfiguration=function(){return this.g};function ou(a){this.h=new WebKitMediaKeys(a);this.g=new ef}ou.prototype.createSession=function(a){a=a||"temporary";if("temporary"!=a)throw new TypeError("Session type "+a+" is unsupported on this platform.");return new tu(this.h,a)};ou.prototype.setServerCertificate=function(){return Promise.resolve(!1)};
819
- function ru(a,b){a.g.Sa();if(!b)return Promise.resolve();a.g.A(b,"webkitneedkey",su);try{return Pi(b,HTMLMediaElement.HAVE_METADATA,a.g,function(){b.webkitSetMediaKeys(a.h)}),Promise.resolve()}catch(c){return Promise.reject(c)}}function tu(a){Ne.call(this);this.i=null;this.l=a;this.h=this.g=null;this.j=new ef;this.sessionId="";this.expiration=NaN;this.closed=new rc;this.keyStatuses=new uu}qa(tu,Ne);r=tu.prototype;
819
+ function ru(a,b){a.g.Ta();if(!b)return Promise.resolve();a.g.A(b,"webkitneedkey",su);try{return Pi(b,HTMLMediaElement.HAVE_METADATA,a.g,function(){b.webkitSetMediaKeys(a.h)}),Promise.resolve()}catch(c){return Promise.reject(c)}}function tu(a){Ne.call(this);this.i=null;this.l=a;this.h=this.g=null;this.j=new ef;this.sessionId="";this.expiration=NaN;this.closed=new rc;this.keyStatuses=new uu}qa(tu,Ne);r=tu.prototype;
820
820
  r.generateRequest=function(a,b){var c=this;this.g=new rc;try{var d=this.l.createSession("video/mp4",Fb(b));this.i=d;this.sessionId=d.sessionId||"";this.j.A(this.i,"webkitkeymessage",function(e){c.g&&(c.g.resolve(),c.g=null);e=(new Map).set("messageType",void 0==c.keyStatuses.g?"license-request":"license-renewal").set("message",Gb(e.message));e=new Q("message",e);c.dispatchEvent(e)});this.j.A(d,"webkitkeyadded",function(){c.h&&(vu(c,"usable"),c.h.resolve(),c.h=null)});this.j.A(d,"webkitkeyerror",function(){var e=
821
821
  Error("EME PatchedMediaKeysApple key error");e.errorCode=c.i.error;if(null!=c.g)c.g.reject(e),c.g=null;else if(null!=c.h)c.h.reject(e),c.h=null;else switch(c.i.error.code){case WebKitMediaKeyError.MEDIA_KEYERR_OUTPUT:case WebKitMediaKeyError.MEDIA_KEYERR_HARDWARECHANGE:vu(c,"output-not-allowed");break;default:vu(c,"internal-error")}});vu(this,"status-pending")}catch(e){this.g.reject(e)}return this.g};r.load=function(){return Promise.reject(Error("MediaKeySession.load not yet supported"))};
822
- r.update=function(a){this.h=new rc;try{this.i.update(Fb(a))}catch(b){this.h.reject(b)}return this.h};r.close=function(){try{this.i.close(),this.closed.resolve(),this.j.Sa()}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 vu(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;c=new Q("keystatuseschange");a.dispatchEvent(c)}
822
+ r.update=function(a){this.h=new rc;try{this.i.update(Fb(a))}catch(b){this.h.reject(b)}return this.h};r.close=function(){try{this.i.close(),this.closed.resolve(),this.j.Ta()}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 vu(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;c=new Q("keystatuseschange");a.dispatchEvent(c)}
823
823
  function uu(){this.size=0;this.g=void 0}r=uu.prototype;r.forEach=function(a){this.g&&a(this.g,yg.value())};r.get=function(a){if(this.has(a))return this.g};r.has=function(a){var b=yg.value();return this.g&&Db(a,b)?!0:!1};r.entries=function(){};r.keys=function(){};r.values=function(){};Jt(mu);function wu(){}function xu(){!window.HTMLVideoElement||!window.MSMediaKeys||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,window.MediaKeys=yu,window.MediaKeySystemAccess=zu,navigator.requestMediaKeySystemAccess=Au,HTMLMediaElement.prototype.setMediaKeys=Bu)}function Au(a,b){try{var c=new zu(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}}
824
824
  function Cu(a){if(a.initData){var b=new CustomEvent("encrypted");b.initDataType="cenc";b.initData=Gb(Do(a.initData));this.dispatchEvent(b)}}It.PatchedMediaKeysMs=wu;wu.install=xu;
825
825
  function zu(a,b){this.keySystem=a;for(var c=!1,d=t(b),e=d.next();!e.done;e=d.next()){e=e.value;var f={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:e.initDataTypes,sessionTypes:["temporary"],label:e.label},g=!1;if(e.audioCapabilities)for(var h=t(e.audioCapabilities),k=h.next();!k.done;k=h.next())k=k.value,k.contentType&&(g=!0,MSMediaKeys.isTypeSupported(this.keySystem,k.contentType.split(";")[0])&&(f.audioCapabilities.push(k),c=
826
826
  !0));if(e.videoCapabilities)for(h=t(e.videoCapabilities),k=h.next();!k.done;k=h.next())k=k.value,k.contentType&&(g=!0,MSMediaKeys.isTypeSupported(this.keySystem,k.contentType.split(";")[0])&&(f.videoCapabilities.push(k),c=!0));g||(c=MSMediaKeys.isTypeSupported(this.keySystem,"video/mp4"));"required"==e.persistentState&&(c=!1);if(c){this.g=f;return}}c=Error("Unsupported keySystem");c.name="NotSupportedError";c.code=DOMException.NOT_SUPPORTED_ERR;throw c;}
827
827
  zu.prototype.createMediaKeys=function(){var a=new yu(this.keySystem);return Promise.resolve(a)};zu.prototype.getConfiguration=function(){return this.g};function Bu(a){var b=this.mediaKeys;b&&b!=a&&Du(b,null);delete this.mediaKeys;return(this.mediaKeys=a)?Du(a,this):Promise.resolve()}function yu(a){this.h=new MSMediaKeys(a);this.g=new ef}
828
- yu.prototype.createSession=function(a){a=a||"temporary";if("temporary"!=a)throw new TypeError("Session type "+a+" is unsupported on this platform.");return new Eu(this.h,a)};yu.prototype.setServerCertificate=function(){return Promise.resolve(!1)};function Du(a,b){a.g.Sa();if(!b)return Promise.resolve();a.g.A(b,"msneedkey",Cu);try{return Pi(b,HTMLMediaElement.HAVE_METADATA,a.g,function(){b.msSetMediaKeys(a.h)}),Promise.resolve()}catch(c){return Promise.reject(c)}}
828
+ yu.prototype.createSession=function(a){a=a||"temporary";if("temporary"!=a)throw new TypeError("Session type "+a+" is unsupported on this platform.");return new Eu(this.h,a)};yu.prototype.setServerCertificate=function(){return Promise.resolve(!1)};function Du(a,b){a.g.Ta();if(!b)return Promise.resolve();a.g.A(b,"msneedkey",Cu);try{return Pi(b,HTMLMediaElement.HAVE_METADATA,a.g,function(){b.msSetMediaKeys(a.h)}),Promise.resolve()}catch(c){return Promise.reject(c)}}
829
829
  function Eu(a){Ne.call(this);this.i=null;this.l=a;this.h=this.g=null;this.j=new ef;this.sessionId="";this.expiration=NaN;this.closed=new rc;this.keyStatuses=new Fu}qa(Eu,Ne);r=Eu.prototype;
830
830
  r.generateRequest=function(a,b){var c=this;this.g=new rc;try{this.i=this.l.createSession("video/mp4",Fb(b),null),this.j.A(this.i,"mskeymessage",function(d){c.g&&(c.g.resolve(),c.g=null);d=(new Map).set("messageType",void 0==c.keyStatuses.g?"license-request":"license-renewal").set("message",Gb(d.message));d=new Q("message",d);c.dispatchEvent(d)}),this.j.A(this.i,"mskeyadded",function(){c.g?(Gu(c,"usable"),c.g.resolve(),c.g=null):c.h&&(Gu(c,"usable"),c.h.resolve(),c.h=null)}),this.j.A(this.i,"mskeyerror",
831
831
  function(){var d=Error("EME PatchedMediaKeysMs key error");d.errorCode=c.i.error;if(null!=c.g)c.g.reject(d),c.g=null;else if(null!=c.h)c.h.reject(d),c.h=null;else switch(c.i.error.code){case MSMediaKeyError.MS_MEDIA_KEYERR_OUTPUT:case MSMediaKeyError.MS_MEDIA_KEYERR_HARDWARECHANGE:Gu(c,"output-not-allowed");break;default:Gu(c,"internal-error")}}),Gu(this,"status-pending")}catch(d){this.g.reject(d)}return this.g};r.load=function(){return Promise.reject(Error("MediaKeySession.load not yet supported"))};
832
- r.update=function(a){this.h=new rc;try{this.i.update(Fb(a))}catch(b){this.h.reject(b)}return this.h};r.close=function(){try{this.i.close(),this.closed.resolve(),this.j.Sa()}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 Gu(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;c=new Q("keystatuseschange");a.dispatchEvent(c)}
832
+ r.update=function(a){this.h=new rc;try{this.i.update(Fb(a))}catch(b){this.h.reject(b)}return this.h};r.close=function(){try{this.i.close(),this.closed.resolve(),this.j.Ta()}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 Gu(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;c=new Q("keystatuseschange");a.dispatchEvent(c)}
833
833
  function Fu(){this.size=0;this.g=void 0}r=Fu.prototype;r.forEach=function(a){this.g&&a(this.g,yg.value())};r.get=function(a){if(this.has(a))return this.g};r.has=function(a){var b=yg.value();return this.g&&Db(a,b)?!0:!1};r.entries=function(){};r.keys=function(){};r.values=function(){};Jt(xu);function Hu(){}function Iu(){!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=Ju,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=Ku,window.MediaKeys=Lu,window.MediaKeySystemAccess=Mu)}function Ju(){return Promise.reject(Error("The key system specified is not supported."))}
834
834
  function Ku(a){return null==a?Promise.resolve():Promise.reject(Error("MediaKeys not supported."))}It.PatchedMediaKeysNop=Hu;Hu.install=Iu;function Lu(){throw new TypeError("Illegal constructor.");}Lu.prototype.createSession=function(){};Lu.prototype.setServerCertificate=function(){};function Mu(){this.keySystem="";throw new TypeError("Illegal constructor.");}Mu.prototype.getConfiguration=function(){};Mu.prototype.createMediaKeys=function(){};Jt(Iu,-10);function Nu(){}function Ou(){if(!(!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration)){if(HTMLMediaElement.prototype.webkitGenerateKeyRequest)Pu="webkit";else if(!HTMLMediaElement.prototype.generateKeyRequest)return;navigator.requestMediaKeySystemAccess=Qu;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=Ru;window.MediaKeys=Su;window.MediaKeySystemAccess=Tu}}
835
835
  function Uu(a){var b=Pu;return b?b+a.charAt(0).toUpperCase()+a.slice(1):a}function Qu(a,b){try{var c=new Tu(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}}function Ru(a){var b=this.mediaKeys;b&&b!=a&&Vu(b,null);delete this.mediaKeys;(this.mediaKeys=a)&&Vu(a,this);return Promise.resolve()}It.PatchedMediaKeysWebkit=Nu;Nu.install=Ou;
836
836
  function Tu(a,b){this.g=this.keySystem=a;var c=!1;"org.w3.clearkey"==a&&(this.g="webkit-org.w3.clearkey",c=!1);var d=!1;var e=document.getElementsByTagName("video");e=e.length?e[0]:document.createElement("video");for(var f=t(b),g=f.next();!g.done;g=f.next()){g=g.value;var h={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:g.initDataTypes,sessionTypes:["temporary"],label:g.label},k=!1;if(g.audioCapabilities)for(var l=t(g.audioCapabilities),
837
837
  m=l.next();!m.done;m=l.next())m=m.value,m.contentType&&(k=!0,e.canPlayType(m.contentType.split(";")[0],this.g)&&(h.audioCapabilities.push(m),d=!0));if(g.videoCapabilities)for(l=t(g.videoCapabilities),m=l.next();!m.done;m=l.next())m=m.value,m.contentType&&(k=!0,e.canPlayType(m.contentType,this.g)&&(h.videoCapabilities.push(m),d=!0));k||(d=e.canPlayType("video/mp4",this.g)||e.canPlayType("video/webm",this.g));"required"==g.persistentState&&(c?(h.persistentState="required",h.sessionTypes=["persistent-license"]):
838
838
  d=!1);if(d){this.h=h;return}}c="Unsupported keySystem";if("org.w3.clearkey"==a||"com.widevine.alpha"==a)c="None of the requested configurations were supported.";c=Error(c);c.name="NotSupportedError";c.code=DOMException.NOT_SUPPORTED_ERR;throw c;}Tu.prototype.createMediaKeys=function(){var a=new Su(this.g);return Promise.resolve(a)};Tu.prototype.getConfiguration=function(){return this.h};function Su(a){this.l=a;this.h=null;this.g=new ef;this.i=[];this.j=new Map}
839
- function Vu(a,b){a.h=b;a.g.Sa();var c=Pu;b&&(a.g.A(b,c+"needkey",function(d){var e=new CustomEvent("encrypted");e.initDataType="cenc";e.initData=Gb(d.initData);a.h.dispatchEvent(e)}),a.g.A(b,c+"keymessage",function(d){var e=Wu(a,d.sessionId);e&&(d=(new Map).set("messageType",void 0==e.keyStatuses.g?"licenserequest":"licenserenewal").set("message",d.message),d=new Q("message",d),e.h&&(e.h.resolve(),e.h=null),e.dispatchEvent(d))}),a.g.A(b,c+"keyadded",function(d){if(d=Wu(a,d.sessionId))Xu(d,"usable"),
839
+ function Vu(a,b){a.h=b;a.g.Ta();var c=Pu;b&&(a.g.A(b,c+"needkey",function(d){var e=new CustomEvent("encrypted");e.initDataType="cenc";e.initData=Gb(d.initData);a.h.dispatchEvent(e)}),a.g.A(b,c+"keymessage",function(d){var e=Wu(a,d.sessionId);e&&(d=(new Map).set("messageType",void 0==e.keyStatuses.g?"licenserequest":"licenserenewal").set("message",d.message),d=new Q("message",d),e.h&&(e.h.resolve(),e.h=null),e.dispatchEvent(d))}),a.g.A(b,c+"keyadded",function(d){if(d=Wu(a,d.sessionId))Xu(d,"usable"),
840
840
  d.g&&d.g.resolve(),d.g=null}),a.g.A(b,c+"keyerror",function(d){var e=Wu(a,d.sessionId);e&&e.handleError(d)}))}Su.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 Yu(b,this.l,a);this.i.push(a);return a};Su.prototype.setServerCertificate=function(){return Promise.resolve(!1)};
841
841
  function Wu(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 Yu(a,b,c){Ne.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 rc;this.keyStatuses=new Zu}qa(Yu,Ne);r=Yu.prototype;
842
842
  r.handleError=function(a){var b=Error("EME v0.1b key error"),c=a.errorCode;c.systemCode=a.systemCode;b.errorCode=c;!a.sessionId&&this.h?(45==a.systemCode&&(b.message="Unsupported session type."),this.h.reject(b),this.h=null):a.sessionId&&this.g?(this.g.reject(b),this.g=null):(b=a.systemCode,a.errorCode.code==MediaKeyError.MEDIA_KEYERR_OUTPUT?Xu(this,"output-restricted"):1==b?Xu(this,"expired"):Xu(this,"internal-error"))};
@@ -850,12 +850,12 @@ function dv(){return this.webkitSupportsPresentationMode("picture-in-picture")?(
850
850
  function ev(){return this.hasAttribute("disablePictureInPicture")?!0:!this.webkitSupportsPresentationMode("picture-in-picture")}function fv(a){a?this.setAttribute("disablePictureInPicture",""):this.removeAttribute("disablePictureInPicture")}It.PiPWebkit=bv;bv.install=cv;Jt(cv);function iv(){}function jv(){window.crypto&&("randomUUID"in window.crypto||(window.crypto.randomUUID=kv))}function kv(){var a=URL.createObjectURL(new Blob),b=a.toString();URL.revokeObjectURL(a);return b.substr(b.lastIndexOf("/")+1)}It.RandomUUID=iv;iv.install=jv;Jt(jv);function lv(){}function mv(){navigator.storage&&navigator.storage.estimate||!navigator.webkitTemporaryStorage||!navigator.webkitTemporaryStorage.queryUsageAndQuota||("storage"in navigator||(navigator.storage={}),navigator.storage.estimate=nv)}function nv(){return new Promise(function(a,b){navigator.webkitTemporaryStorage.queryUsageAndQuota(function(c,d){a({usage:c,quota:d})},b)})}It.StorageEstimate=lv;lv.install=mv;Jt(mv);function ov(){}function pv(){var a=Symbol.prototype;"description"in a||Object.defineProperty(a,"description",{get:qv})}function qv(){var a=/\((.*)\)/.exec(this.toString());return a?a[1]:void 0}It.Symbol=ov;ov.install=pv;Jt(pv);function rv(){}function sv(){if(window.HTMLMediaElement){var a=HTMLMediaElement.prototype.play;HTMLMediaElement.prototype.play=function(){var b=a.apply(this);b&&b["catch"](function(){});return b}}}It.VideoPlayPromise=rv;rv.install=sv;Jt(sv);function tv(){}function uv(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;!a.getVideoPlaybackQuality&&("webkitDroppedFrameCount"in a||yc("Web0S")&&yc("Chrome/38.0.2125.122 Safari/537.36"))&&(a.getVideoPlaybackQuality=vv)}}function vv(){return{droppedVideoFrames:this.webkitDroppedFrameCount,totalVideoFrames:this.webkitDecodedFrameCount,corruptedVideoFrames:0,creationTime:NaN,totalFrameDelay:0}}It.VideoPlaybackQuality=tv;tv.install=uv;Jt(uv);function wv(){}function xv(){if(!window.VTTCue&&window.TextTrackCue){var a=null,b=TextTrackCue.length;if(3==b)a=yv;else if(6==b)a=zv;else{try{var c=!!yv(1,2,"")}catch(d){c=!1}c&&(a=yv)}a&&(window.VTTCue=function(d,e,f){return a(d,e,f)})}}function yv(a,b,c){return new window.TextTrackCue(a,b,c)}function zv(a,b,c){return new window.TextTrackCue(a+"-"+b+"-"+c,a,b,c)}It.VTTCue=wv;wv.install=xv;Jt(xv);function Av(){}Av.prototype.parseInit=function(){};Av.prototype.parseMedia=function(a,b){var c=null,d=[],e=Jc(a).split(/\r?\n/);e=t(e);for(var f=e.next();!f.done;f=e.next())if((f=f.value)&&!/^\s+$/.test(f)&&(f=Bv.exec(f))){var g=Cv.exec(f[1]);g=60*parseInt(g[1],10)+parseFloat(g[2].replace(",","."));f=new ib(g,b.segmentEnd?b.segmentEnd:g+2,f[2]);c&&(c.endTime=g,d.push(c));c=f}c&&d.push(c);return d};M("shaka.text.LrcTextParser",Av);Av.prototype.parseMedia=Av.prototype.parseMedia;
851
851
  Av.prototype.parseInit=Av.prototype.parseInit;var Bv=/^\[(\d{1,2}:\d{1,2}(?:[.,]\d{1,3})?)\](.*)/,Cv=/^(\d+):(\d{1,2}(?:[.,]\d{1,3})?)$/;hd["application/x-subtitle-lrc"]=function(){return new Av};function Dv(){}Dv.prototype.parseInit=function(){};
852
852
  Dv.prototype.parseMedia=function(a,b){var c=Jc(a),d=[];if(""==c)return d;var e=Mf(c,"tt");if(!e)throw new N(2,2,2005,"Failed to parse TTML.");c=e.getElementsByTagName("body")[0];if(!c)return[];var f=yf(e,Ev,"frameRate"),g=yf(e,Ev,"subFrameRate"),h=yf(e,Ev,"frameRateMultiplier"),k=yf(e,Ev,"tickRate"),l=yf(e,Ev,"cellResolution"),m=e.getAttribute("xml:space")||"default",n=yf(e,Fv,"extent");if("default"!=m&&"preserve"!=m)throw new N(2,2,2005,"Invalid xml:space value: "+m);m="default"==m;f=new Gv(f,g,
853
- h,k);l=l?(l=/^(\d+) (\d+)$/.exec(l))?{columns:parseInt(l[1],10),rows:parseInt(l[2],10)}:null:null;g=(g=e.getElementsByTagName("metadata")[0])?wf(g):[];h=Array.from(e.getElementsByTagName("style"));e=Array.from(e.getElementsByTagName("region"));k=[];for(var p=t(e),q=p.next();!q.done;q=p.next()){var v=q.value;q=new kb;var y=v.getAttribute("xml:id");if(y){q.id=y;var w=null;n&&(w=Hv.exec(n)||Iv.exec(n));y=w?Number(w[1]):null;w=w?Number(w[2]):null;var x,D;if(x=Jv(v,h,"extent"))x=(D=Hv.exec(x))||Iv.exec(x),
854
- null!=x&&(q.width=Number(x[1]),q.height=Number(x[2]),D||(null!=y&&(q.width=100*q.width/y),null!=w&&(q.height=100*q.height/w)),q.widthUnits=D||null!=y?Ab:0,q.heightUnits=D||null!=w?Ab:0);if(v=Jv(v,h,"origin"))x=(D=Hv.exec(v))||Iv.exec(v),null!=x&&(q.viewportAnchorX=Number(x[1]),q.viewportAnchorY=Number(x[2]),D||(null!=w&&(q.viewportAnchorY=100*q.viewportAnchorY/w),null!=y&&(q.viewportAnchorX=100*q.viewportAnchorX/y)),q.viewportAnchorUnits=D||null!=y?Ab:0)}else q=null;q&&k.push(q)}if(tf(c,"p").length)throw new N(2,
853
+ h,k);l=l?(l=/^(\d+) (\d+)$/.exec(l))?{columns:parseInt(l[1],10),rows:parseInt(l[2],10)}:null:null;g=(g=e.getElementsByTagName("metadata")[0])?wf(g):[];h=Array.from(e.getElementsByTagName("style"));e=Array.from(e.getElementsByTagName("region"));k=[];for(var p=t(e),q=p.next();!q.done;q=p.next()){var v=q.value;q=new kb;var w=v.getAttribute("xml:id");if(w){q.id=w;var x=null;n&&(x=Hv.exec(n)||Iv.exec(n));w=x?Number(x[1]):null;x=x?Number(x[2]):null;var y,D;if(y=Jv(v,h,"extent"))y=(D=Hv.exec(y))||Iv.exec(y),
854
+ null!=y&&(q.width=Number(y[1]),q.height=Number(y[2]),D||(null!=w&&(q.width=100*q.width/w),null!=x&&(q.height=100*q.height/x)),q.widthUnits=D||null!=w?Ab:0,q.heightUnits=D||null!=x?Ab:0);if(v=Jv(v,h,"origin"))y=(D=Hv.exec(v))||Iv.exec(v),null!=y&&(q.viewportAnchorX=Number(y[1]),q.viewportAnchorY=Number(y[2]),D||(null!=x&&(q.viewportAnchorY=100*q.viewportAnchorY/x),null!=w&&(q.viewportAnchorX=100*q.viewportAnchorX/w)),q.viewportAnchorUnits=D||null!=w?Ab:0)}else q=null;q&&k.push(q)}if(tf(c,"p").length)throw new N(2,
855
855
  2,2001,"<p> can only be inside <div> in TTML");n=t(tf(c,"div"));for(p=n.next();!p.done;p=n.next())if(tf(p.value,"span").length)throw new N(2,2,2001,"<span> can only be inside <p> in TTML");if(c=Kv(c,b,f,g,h,e,k,m,l,null,!1))c.backgroundColor||(c.backgroundColor="transparent"),d.push(c);return d};
856
- function Kv(a,b,c,d,e,f,g,h,k,l,m){var n=a.parentNode;if(a.nodeType==Node.COMMENT_NODE)return null;if(a.nodeType==Node.TEXT_NODE){if(!m)return null;var p=document.createElement("span");p.textContent=a.textContent}else p=a;for(var q=null,v=t(Lv),y=v.next();!y.done&&!(q=Mv(p,"backgroundImage",d,"#",y.value)[0]);y=v.next());v=m;if("p"==a.nodeName||q)m=!0;h="default"==(p.getAttribute("xml:space")||(h?"default":"preserve"));y=Array.from(p.childNodes).every(function(B){return B.nodeType==Node.TEXT_NODE});
857
- a=[];if(!y)for(var w=t(p.childNodes),x=w.next();!x.done;x=w.next())(x=Kv(x.value,b,c,d,e,f,g,h,k,p,m))&&a.push(x);d=null!=l;w=/\S/.test(p.textContent);var D=p.hasAttribute("begin")||p.hasAttribute("end")||p.hasAttribute("dur");if(!(D||w||"br"==p.tagName||0!=a.length||d&&!h))return null;x=Nv(p,c);w=x.start;for(x=x.end;n&&n.nodeType==Node.ELEMENT_NODE&&"tt"!=n.tagName;)x=Ov(n,c,w,x),w=x.start,x=x.end,n=n.parentNode;null==w&&(w=0);w+=b.periodStart;x=null==x?Infinity:x+b.periodStart;w=Math.max(w,b.segmentStart);
858
- x=Math.min(x,b.segmentEnd);if(!D&&0<a.length)for(w=Infinity,x=0,b=t(a),c=b.next();!c.done;c=b.next())c=c.value,w=Math.min(w,c.startTime),x=Math.max(x,c.endTime);if("br"==p.tagName)return e=new ib(w,x,""),e.lineBreak=!0,e;b="";y&&(b=p.textContent,h&&(b=b.trim(),b=b.replace(/\s+/g," ")));b=new ib(w,x,b);b.nestedCues=a;m||(b.isContainer=!0);k&&(b.cellResolution=k);k=Mv(p,"region",f,"")[0];if(p.hasAttribute("region")&&k&&k.getAttribute("xml:id")){var z=k.getAttribute("xml:id");b.region=g.filter(function(B){return B.id==
856
+ function Kv(a,b,c,d,e,f,g,h,k,l,m){var n=a.parentNode;if(a.nodeType==Node.COMMENT_NODE)return null;if(a.nodeType==Node.TEXT_NODE){if(!m)return null;var p=document.createElement("span");p.textContent=a.textContent}else p=a;for(var q=null,v=t(Lv),w=v.next();!w.done&&!(q=Mv(p,"backgroundImage",d,"#",w.value)[0]);w=v.next());v=m;if("p"==a.nodeName||q)m=!0;h="default"==(p.getAttribute("xml:space")||(h?"default":"preserve"));w=Array.from(p.childNodes).every(function(B){return B.nodeType==Node.TEXT_NODE});
857
+ a=[];if(!w)for(var x=t(p.childNodes),y=x.next();!y.done;y=x.next())(y=Kv(y.value,b,c,d,e,f,g,h,k,p,m))&&a.push(y);d=null!=l;x=/\S/.test(p.textContent);var D=p.hasAttribute("begin")||p.hasAttribute("end")||p.hasAttribute("dur");if(!(D||x||"br"==p.tagName||0!=a.length||d&&!h))return null;y=Nv(p,c);x=y.start;for(y=y.end;n&&n.nodeType==Node.ELEMENT_NODE&&"tt"!=n.tagName;)y=Ov(n,c,x,y),x=y.start,y=y.end,n=n.parentNode;null==x&&(x=0);x+=b.periodStart;y=null==y?Infinity:y+b.periodStart;x=Math.max(x,b.segmentStart);
858
+ y=Math.min(y,b.segmentEnd);if(!D&&0<a.length)for(x=Infinity,y=0,b=t(a),c=b.next();!c.done;c=b.next())c=c.value,x=Math.min(x,c.startTime),y=Math.max(y,c.endTime);if("br"==p.tagName)return e=new ib(x,y,""),e.lineBreak=!0,e;b="";w&&(b=p.textContent,h&&(b=b.trim(),b=b.replace(/\s+/g," ")));b=new ib(x,y,b);b.nestedCues=a;m||(b.isContainer=!0);k&&(b.cellResolution=k);k=Mv(p,"region",f,"")[0];if(p.hasAttribute("region")&&k&&k.getAttribute("xml:id")){var z=k.getAttribute("xml:id");b.region=g.filter(function(B){return B.id==
859
859
  z})[0]}g=k;l&&d&&!p.getAttribute("region")&&!p.getAttribute("style")&&(g=Mv(l,"region",f,"")[0]);Pv(b,p,g,q,e,v,0==a.length);return b}
860
860
  function Pv(a,b,c,d,e,f,g){f=f||g;"rtl"==Qv(b,c,e,"direction",f)&&(a.direction="rtl");g=Qv(b,c,e,"writingMode",f);"tb"==g||"tblr"==g?a.writingMode="vertical-lr":"tbrl"==g?a.writingMode="vertical-rl":"rltb"==g||"rl"==g?a.direction="rtl":g&&(a.direction=jb);(g=Qv(b,c,e,"textAlign",!0))?(a.positionAlign=Rv[g],a.lineAlign=Sv[g],a.textAlign=ub[g.toUpperCase()]):a.textAlign=mb;if(g=Qv(b,c,e,"displayAlign",!0))a.displayAlign=vb[g.toUpperCase()];if(g=Qv(b,c,e,"color",f))a.color=g;if(g=Qv(b,c,e,"backgroundColor",
861
861
  f))a.backgroundColor=g;if(g=Qv(b,c,e,"border",f))a.border=g;if(g=Qv(b,c,e,"fontFamily",f))switch(g){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=g}(g=Qv(b,c,e,"fontWeight",f))&&
@@ -873,20 +873,23 @@ end:"end"},Rv={left:"line-left",center:"center",right:"line-right"},Ev=["http://
873
873
  fw.prototype.parseInit=fw.prototype.parseInit;hd['application/mp4; codecs="stpp"']=function(){return new fw};hd['application/mp4; codecs="stpp.ttml"']=function(){return new fw};hd['application/mp4; codecs="stpp.ttml.im1t"']=function(){return new fw};hd['application/mp4; codecs="stpp.TTML.im1t"']=function(){return new fw};function gw(){}gw.prototype.parseInit=function(){};
874
874
  gw.prototype.parseMedia=function(a,b){var c=Jc(a);c=c.replace(/\r\n|\r(?=[^\n]|$)/gm,"\n");var d=c.split(/\n{2,}/m);if(!/^WEBVTT($|[ \t\n])/m.test(d[0]))throw new N(2,2,2E3);c=b.periodStart;if(d[0].includes("X-TIMESTAMP-MAP")){var e=d[0].match(/LOCAL:((?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{3}))/m),f=d[0].match(/MPEGTS:(\d+)/m);if(e&&f){c=hw(new Dq(e[1]));if(null==c)throw new N(2,2,2E3);f=Number(f[1]);for(e=b.segmentStart;95443.7176888889<=e;)e-=95443.7176888889,f+=8589934592;c=b.periodStart+f/9E4-c}}f=
875
875
  [];e=t(d[0].split("\n"));for(var g=e.next();!g.done;g=e.next())if(g=g.value,/^Region:/.test(g)){g=new Dq(g);var h=new kb;Gq(g);Eq(g);for(var k=Gq(g);k;){var l=h,m=k;(k=/^id=(.*)$/.exec(m))?l.id=k[1]:(k=/^width=(\d{1,2}|100)%$/.exec(m))?l.width=Number(k[1]):(k=/^lines=(\d+)$/.exec(m))?(l.height=Number(k[1]),l.heightUnits=2):(k=/^regionanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(m))?(l.regionAnchorX=Number(k[1]),l.regionAnchorY=Number(k[2])):(k=/^viewportanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(m))?
876
- (l.viewportAnchorX=Number(k[1]),l.viewportAnchorY=Number(k[2])):/^scroll=up$/.exec(m)&&(l.scroll="up");Eq(g);k=Gq(g)}f.push(h)}e=new Map;iw(e);g=[];d=t(d.slice(1));for(h=d.next();!h.done;h=d.next()){h=h.value.split("\n");if((1!=h.length||h[0])&&!/^NOTE($|[ \t])/.test(h[0])&&"STYLE"==h[0]&&h[1].includes("::cue")){l="global";(k=h[1].match(/\((.*)\)/))&&(l=k.pop());k=h.slice(2,-1);h[1].includes("}")&&(m=/\{(.*?)\}/.exec(h[1]))&&(k=m[1].split(";"));m=new ib(0,0,"");for(var n=!1,p=0;p<k.length;p++){var q=
877
- /^\s*([^:]+):\s*(.*)/.exec(k[p]);if(q){var v=q[2].trim().replace(";","");switch(q[1].trim()){case "background-color":n=!0;m.backgroundColor=v;break;case "color":n=!0;m.color=v;break;case "font-family":n=!0;m.fontFamily=v;break;case "font-size":n=!0;m.fontSize=v;break;case "font-weight":700<=parseInt(v,10)&&(n=!0,m.fontWeight=700);break;case "font-style":switch(v){case "normal":n=!0;m.fontStyle=sb;break;case "italic":n=!0;m.fontStyle="italic";break;case "oblique":n=!0,m.fontStyle="oblique"}break;case "opacity":n=
878
- !0;m.opacity=parseFloat(v);break;case "white-space":n=!0,m.wrapLine="noWrap"!=v}}}n&&e.set(l,m)}p=c;if(1==h.length&&!h[0]||/^NOTE($|[ \t])/.test(h[0])||"STYLE"==h[0])h=null;else{l=null;h[0].includes("--\x3e")||(l=h[0],h.splice(0,1));k=new Dq(h[0]);m=hw(k);q=Fq(k,/[ \t]+--\x3e[ \t]+/g);n=hw(k);if(null==m||null==q||null==n)throw new N(2,2,2001,"Could not parse cue time range in WebVTT");m+=p;n+=p;p=h.slice(1).join("\n").trim();e.has("global")?(h=e.get("global").clone(),h.startTime=m,h.endTime=n,h.payload=
879
- ""):h=new ib(m,n,"");jw(p,h,e);Eq(k);for(m=Gq(k);m;)kw(h,m,f),Eq(k),m=Gq(k);null!=l&&(h.id=l)}h&&g.push(h)}return g};function iw(a){for(var b=t(Object.entries(xb)),c=b.next();!c.done;c=b.next()){var d=t(c.value);c=d.next().value;d=d.next().value;var e=new ib(0,0,"");e.color=d;a.set(c,e)}b=t(Object.entries(yb));for(c=b.next();!c.done;c=b.next())d=t(c.value),c=d.next().value,d=d.next().value,e=new ib(0,0,""),e.backgroundColor=d,a.set(c,e)}
880
- function jw(a,b,c){0===c.size&&iw(c);a=lw(a);var d=Mf("<span>"+a+"</span>","span");if(d){var e=[];d=d.childNodes;if(1==d.length){var f=d[0];if(f.nodeType==Node.TEXT_NODE||f.nodeType==Node.CDATA_SECTION_NODE){b.payload=a;return}}a=t(d);for(d=a.next();!d.done;d=a.next())mw(d.value,b,e,c);b.nestedCues=e}else b.payload=a}
881
- function lw(a){for(var b=[],c=-1,d="",e=0;e<a.length;e++)if("/"===a[e]){var f=a.indexOf(">",e);if(f<=e)return a;f=a.substring(e+1,f);var g=b.pop();if(f&&g){if(g===f)d+="/"+f+">";else{if(!g.startsWith("c.")||"c"!==f)return a;d+="/"+g+">"}e+=f.length+1}else return a}else"<"===a[e]?c=e+1:">"===a[e]&&0<c&&(b.push(a.substr(c,e-c)),c=-1),d+=a[e];return d}function nw(a,b){return a&&0<a.length?a:b}
882
- function mw(a,b,c,d){var e=b.clone();if(a.nodeType===Node.ELEMENT_NODE&&a.nodeName)for(var f=t(a.nodeName.split(/[ .]+/)),g=f.next();!g.done;g=f.next()){g=g.value;if(d.has(g)){var h=d.get(g);h&&(e.backgroundColor=nw(h.backgroundColor,e.backgroundColor),e.color=nw(h.color,e.color),e.fontFamily=nw(h.fontFamily,e.fontFamily),e.fontSize=nw(h.fontSize,e.fontSize),e.fontWeight=h.fontWeight,e.fontStyle=h.fontStyle,e.opacity=h.opacity,e.wrapLine=h.wrapLine)}switch(g){case "b":e.fontWeight=700;break;case "i":e.fontStyle=
883
- "italic";break;case "u":e.textDecoration.push("underline")}}if(Af(a))for(f=!0,d=t(a.textContent.split("\n")),a=d.next();!a.done;a=d.next())a=a.value,f||(f=b.clone(),f.lineBreak=!0,c.push(f)),0<a.length&&(f=e.clone(),f.payload=a,c.push(f)),f=!1;else for(b=t(a.childNodes),a=b.next();!a.done;a=b.next())mw(a.value,e,c,d)}
884
- function kw(a,b,c){var d;if(d=/^align:(start|middle|center|end|left|right)$/.exec(b))b=d[1],"middle"==b?a.textAlign=mb:a.textAlign=ub[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|center|start|end))?$/.exec(b))a.position=Number(d[1]),d[2]&&(b=d[2],a.positionAlign="line-left"==b||"start"==b?"line-left":"line-right"==b||"end"==
876
+ (l.viewportAnchorX=Number(k[1]),l.viewportAnchorY=Number(k[2])):/^scroll=up$/.exec(m)&&(l.scroll="up");Eq(g);k=Gq(g)}f.push(h)}e=new Map;iw(e);g=[];d=t(d.slice(1));for(h=d.next();!h.done;h=d.next()){h=h.value.split("\n");if((1!=h.length||h[0])&&!/^NOTE($|[ \t])/.test(h[0])&&"STYLE"==h[0]){l=[];k=-1;for(m=1;m<h.length;m++)h[m].includes("::cue")&&(l.push([]),k=l.length-1),-1!=k&&(l[k].push(h[m]),h[m].includes("}")&&(k=-1));l=t(l);for(k=l.next();!k.done;k=l.next()){var n=k.value;k="global";(m=n[0].match(/\((.*)\)/))&&
877
+ (k=m.pop());m=n.slice(1,-1);n[0].includes("}")&&(n=/\{(.*?)\}/.exec(n[0]))&&(m=n[1].split(";"));(n=e.get(k))||(n=new ib(0,0,""));for(var p=!1,q=0;q<m.length;q++){var v=/^\s*([^:]+):\s*(.*)/.exec(m[q]);if(v){var w=v[2].trim().replace(";","");switch(v[1].trim()){case "background-color":case "background":p=!0;n.backgroundColor=w;break;case "color":p=!0;n.color=w;break;case "font-family":p=!0;n.fontFamily=w;break;case "font-size":p=!0;n.fontSize=w;break;case "font-weight":if(700<=parseInt(w,10)||"bold"==
878
+ w)p=!0,n.fontWeight=700;break;case "font-style":switch(w){case "normal":p=!0;n.fontStyle=sb;break;case "italic":p=!0;n.fontStyle="italic";break;case "oblique":p=!0,n.fontStyle="oblique"}break;case "opacity":p=!0;n.opacity=parseFloat(w);break;case "text-shadow":p=!0;n.textShadow=w;break;case "white-space":p=!0,n.wrapLine="noWrap"!=w}}}p&&e.set(k,n)}}p=c;if(1==h.length&&!h[0]||/^NOTE($|[ \t])/.test(h[0])||"STYLE"==h[0]||"REGION"==h[0])h=null;else{l=null;h[0].includes("--\x3e")||(l=h[0],h.splice(0,1));
879
+ k=new Dq(h[0]);m=hw(k);q=Fq(k,/[ \t]+--\x3e[ \t]+/g);n=hw(k);if(null==m||null==q||null==n)throw new N(2,2,2001,"Could not parse cue time range in WebVTT");m+=p;n+=p;p=jw(h.slice(1).join("\n").trim());e.has("global")?(h=e.get("global").clone(),h.startTime=m,h.endTime=n,h.payload=""):h=new ib(m,n,"");kw(p,h,e);Eq(k);for(m=Gq(k);m;)lw(h,m,f),Eq(k),m=Gq(k);null!=l&&(h.id=l)}h&&g.push(h)}return g};
880
+ function iw(a){for(var b=t(Object.entries(xb)),c=b.next();!c.done;c=b.next()){var d=t(c.value);c=d.next().value;d=d.next().value;var e=new ib(0,0,"");e.color=d;a.set("."+c,e)}b=t(Object.entries(yb));for(c=b.next();!c.done;c=b.next())d=t(c.value),c=d.next().value,d=d.next().value,e=new ib(0,0,""),e.backgroundColor=d,a.set("."+c,e)}
881
+ function kw(a,b,c){0===c.size&&iw(c);a:{var d=a;a=[];for(var e=-1,f="",g=0;g<d.length;g++)if("/"===d[g]&&0<g&&"<"===d[g-1]){var h=d.indexOf(">",g);if(h<=g){a=d;break a}if((h=d.substring(g+1,h))&&"c"===h){var k=a.pop();k?k===h?(f+="/"+h+">",g+=h.length+1):k.startsWith("c.")?(g+=h.length+1,f+="/"+k+">"):f+=d[g]:f+=d[g]}else f+=d[g]}else"<"===d[g]?(e=g+1,"c"!=d[e]&&(e=-1)):">"===d[g]&&0<e&&(a.push(d.substr(e,g-e)),e=-1),f+=d[g];a=f}a:{e=a;f=[];g=-1;d="";a=!1;for(h=0;h<e.length;h++)if("/"===e[h]){k=e.indexOf(">",
882
+ h);if(-1===k){a=e;break a}if((k=e.substring(h+1,k))&&"v"==k){a=!0;var l=null;f.length&&(l=f[f.length-1]);if(l){if(l===k)d+="/"+k+">";else{if(!l.startsWith("v")){d+=e[h];continue}d+="/"+l+">"}h+=k.length+1}else d+=e[h]}else d+=e[h]}else"<"===e[h]?(g=h+1,"v"!=e[g]&&(g=-1)):">"===e[h]&&0<g&&(f.push(e.substr(g,h-g)),g=-1),d+=e[h];e=t(f);for(f=e.next();!f.done;f=e.next())f=f.value,g=f.replace(" ",".voice-"),d=d.replace("<"+f+">","<"+g+">"),d=d.replace("</"+f+">","</"+g+">"),a||(d+="</"+g+">");a=d}if(e=
883
+ Mf("<span>"+a+"</span>","span")){d=[];e=e.childNodes;if(1==e.length&&(f=e[0],f.nodeType==Node.TEXT_NODE||f.nodeType==Node.CDATA_SECTION_NODE)){b.payload=a;return}a=t(e);for(e=a.next();!e.done;e=a.next())mw(e.value,b,d,c);b.nestedCues=d}else b.payload=a}function nw(a,b){return a&&0<a.length?a:b}
884
+ function mw(a,b,c,d){var e=b.clone();if(a.nodeType===Node.ELEMENT_NODE&&a.nodeName)for(var f=t(a.nodeName.split(/(?=[ .])+/g)),g=f.next();!g.done;g=f.next()){var h=g=g.value;if(h.startsWith(".voice-")){var k=h.split("-").pop();h='v[voice="'+k+'"]';d.has(h)||(h="v[voice="+k+"]")}d.has(h)&&(h=d.get(h))&&(e.backgroundColor=nw(h.backgroundColor,e.backgroundColor),e.color=nw(h.color,e.color),e.fontFamily=nw(h.fontFamily,e.fontFamily),e.fontSize=nw(h.fontSize,e.fontSize),e.fontWeight=h.fontWeight,e.fontStyle=
885
+ h.fontStyle,e.opacity=h.opacity,e.wrapLine=h.wrapLine);switch(g){case "br":g=b.clone();g.lineBreak=!0;c.push(g);break;case "b":e.fontWeight=700;break;case "i":e.fontStyle="italic";break;case "u":e.textDecoration.push("underline")}}if(Af(a))for(f=!0,d=t(a.textContent.split("\n")),a=d.next();!a.done;a=d.next())a=a.value,f||(f=b.clone(),f.lineBreak=!0,c.push(f)),0<a.length&&(f=e.clone(),f.payload=a,c.push(f)),f=!1;else for(b=t(a.childNodes),a=b.next();!a.done;a=b.next())mw(a.value,e,c,d)}
886
+ function lw(a,b,c){var d;if(d=/^align:(start|middle|center|end|left|right)$/.exec(b))b=d[1],"middle"==b?a.textAlign=mb:a.textAlign=ub[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|center|start|end))?$/.exec(b))a.position=Number(d[1]),d[2]&&(b=d[2],a.positionAlign="line-left"==b||"start"==b?"line-left":"line-right"==b||"end"==
885
887
  b?"line-right":"center");else if(d=/^region:(.*)$/.exec(b)){if(b=ow(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=wb[c[2].toUpperCase()]);else if(c=/^line:(-?\d+)(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=ob,a.line=Number(c[1]),c[2]&&(a.lineAlign=wb[c[2].toUpperCase()])}function ow(a,b){var c=a.filter(function(d){return d.id==b});return c.length?c[0]:null}
886
- function hw(a){a=Fq(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)}M("shaka.text.VttTextParser",gw);gw.prototype.parseMedia=gw.prototype.parseMedia;gw.prototype.parseInit=gw.prototype.parseInit;hd["text/vtt"]=function(){return new gw};hd['text/vtt; codecs="vtt"']=function(){return new gw};hd['text/vtt; codecs="wvtt"']=function(){return new gw};function pw(){this.g=null}pw.prototype.parseInit=function(a){var b=this,c=!1;(new Ig).box("moov",Mg).box("trak",Mg).box("mdia",Mg).P("mdhd",function(d){d=Zh(d.reader,d.version);b.g=d.timescale}).box("minf",Mg).box("stbl",Mg).P("stsd",Og).box("wvtt",function(){c=!0}).parse(a);if(!this.g)throw new N(2,2,2008);if(!c)throw new N(2,2,2008);};
887
- pw.prototype.parseMedia=function(a,b){if(!this.g)throw new N(2,2,2008);var c=0,d=[],e,f=[],g=!1,h=!1,k=!1,l=null;(new Ig).box("moof",Mg).box("traf",Mg).P("tfdt",function(B){g=!0;c=Yh(B.reader,B.version).pd}).P("tfhd",function(B){l=Xh(B.reader,B.flags).he}).P("trun",function(B){h=!0;d=$h(B.reader,B.version,B.flags).ze}).box("mdat",Pg(function(B){k=!0;e=B})).parse(a,!1);if(!k&&!g&&!h)throw new N(2,2,2008);for(var m=c,n=new Fg(e,0),p=t(d),q=p.next();!q.done;q=p.next()){q=q.value;var v=q.Rd||l,y=q.Tc?
888
- c+q.Tc:m;m=y+(v||0);var w=0;do{var x=n.M();w+=x;var D=n.M(),z=null;"vttc"==Qg(D)?8<x&&(z=n.Za(x-8)):n.skip(x-8);v&&z&&(x=qw(z,b.periodStart+y/this.g,b.periodStart+m/this.g),f.push(x))}while(q.sampleSize&&w<q.sampleSize)}return f.filter(Qb)};function qw(a,b,c){var d,e,f;(new Ig).box("payl",Pg(function(g){d=Jc(g)})).box("iden",Pg(function(g){e=Jc(g)})).box("sttg",Pg(function(g){f=Jc(g)})).parse(a);return d?rw(d,e,f,b,c):null}
889
- function rw(a,b,c,d,e){d=new ib(d,e,"");jw(a,d,new Map);b&&(d.id=b);if(c)for(a=new Dq(c),b=Gq(a);b;)kw(d,b,[]),Eq(a),b=Gq(a);return d}M("shaka.text.Mp4VttParser",pw);pw.prototype.parseMedia=pw.prototype.parseMedia;pw.prototype.parseInit=pw.prototype.parseInit;hd['application/mp4; codecs="wvtt"']=function(){return new pw};function sw(){}sw.prototype.parseInit=function(){};sw.prototype.parseMedia=function(a){var b=Jc(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 Dq(c[0]),e=tw(d),f=Fq(d,/,/g);d=tw(d);if(null==e||null==f||null==d)throw new N(2,2,2001,"Could not parse cue time range in SubViewer");a.push(new ib(e,d,c.slice(1).join("\n").trim()))}return a};
888
+ function hw(a){a=Fq(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)}function jw(a){var b={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'","&nbsp;":"\u00a0","&lrm;":"\u200e","&rlm;":"\u200f"},c=/&(?:amp|lt|gt|quot|#(0+)?39|nbsp|lrm|rlm);/g,d=RegExp(c.source);return a&&d.test(a)?a.replace(c,function(e){return b[e]||"'"}):a||""}M("shaka.text.VttTextParser",gw);
889
+ gw.prototype.parseMedia=gw.prototype.parseMedia;gw.prototype.parseInit=gw.prototype.parseInit;hd["text/vtt"]=function(){return new gw};hd['text/vtt; codecs="vtt"']=function(){return new gw};hd['text/vtt; codecs="wvtt"']=function(){return new gw};function pw(){this.g=null}pw.prototype.parseInit=function(a){var b=this,c=!1;(new Ig).box("moov",Mg).box("trak",Mg).box("mdia",Mg).P("mdhd",function(d){d=Zh(d.reader,d.version);b.g=d.timescale}).box("minf",Mg).box("stbl",Mg).P("stsd",Og).box("wvtt",function(){c=!0}).parse(a);if(!this.g)throw new N(2,2,2008);if(!c)throw new N(2,2,2008);};
890
+ pw.prototype.parseMedia=function(a,b){if(!this.g)throw new N(2,2,2008);var c=0,d=[],e,f=[],g=!1,h=!1,k=!1,l=null;(new Ig).box("moof",Mg).box("traf",Mg).P("tfdt",function(B){g=!0;c=Yh(B.reader,B.version).pd}).P("tfhd",function(B){l=Xh(B.reader,B.flags).ie}).P("trun",function(B){h=!0;d=$h(B.reader,B.version,B.flags).ze}).box("mdat",Pg(function(B){k=!0;e=B})).parse(a,!1);if(!k&&!g&&!h)throw new N(2,2,2008);for(var m=c,n=new Fg(e,0),p=t(d),q=p.next();!q.done;q=p.next()){q=q.value;var v=q.Sd||l,w=q.Tc?
891
+ c+q.Tc:m;m=w+(v||0);var x=0;do{var y=n.M();x+=y;var D=n.M(),z=null;"vttc"==Qg(D)?8<y&&(z=n.Za(y-8)):n.skip(y-8);v&&z&&(y=qw(z,b.periodStart+w/this.g,b.periodStart+m/this.g),f.push(y))}while(q.sampleSize&&x<q.sampleSize)}return f.filter(Qb)};function qw(a,b,c){var d,e,f;(new Ig).box("payl",Pg(function(g){d=Jc(g)})).box("iden",Pg(function(g){e=Jc(g)})).box("sttg",Pg(function(g){f=Jc(g)})).parse(a);return d?rw(d,e,f,b,c):null}
892
+ function rw(a,b,c,d,e){d=new ib(d,e,"");kw(a,d,new Map);b&&(d.id=b);if(c)for(a=new Dq(c),b=Gq(a);b;)lw(d,b,[]),Eq(a),b=Gq(a);return d}M("shaka.text.Mp4VttParser",pw);pw.prototype.parseMedia=pw.prototype.parseMedia;pw.prototype.parseInit=pw.prototype.parseInit;hd['application/mp4; codecs="wvtt"']=function(){return new pw};function sw(){}sw.prototype.parseInit=function(){};sw.prototype.parseMedia=function(a){var b=Jc(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 Dq(c[0]),e=tw(d),f=Fq(d,/,/g);d=tw(d);if(null==e||null==f||null==d)throw new N(2,2,2001,"Could not parse cue time range in SubViewer");a.push(new ib(e,d,c.slice(1).join("\n").trim()))}return a};
890
893
  function tw(a){a=Fq(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)}M("shaka.text.SbvTextParser",sw);sw.prototype.parseMedia=sw.prototype.parseMedia;sw.prototype.parseInit=sw.prototype.parseInit;hd["text/x-subviewer"]=function(){return new sw};function uw(){this.g=new gw}uw.prototype.parseInit=function(){};uw.prototype.parseMedia=function(a,b){var c=Jc(a);c=vw(c);c=Fb(Nc(c));return this.g.parseMedia(c,b)};function vw(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")+"\n\n";return b}M("shaka.text.SrtTextParser",uw);uw.srt2webvtt=vw;uw.prototype.parseMedia=uw.prototype.parseMedia;
891
894
  uw.prototype.parseInit=uw.prototype.parseInit;hd["text/srt"]=function(){return new uw};function ww(){}ww.prototype.parseInit=function(){};
892
895
  ww.prototype.parseMedia=function(a){var b="",c="";a=Jc(a).split(/\r?\n\s*\r?\n/);a=t(a);for(var d=a.next();!d.done;d=a.next()){var e=xw.exec(d.value);e&&(d=e[1],e=e[2],"V4 Styles"==d||"V4+ Styles"==d?b=e:"Events"==d&&(c=e))}a=[];d=null;b=t(b.split(/\r?\n/));for(var f=b.next();!f.done;f=b.next())if(e=f.value,!/^\s*;/.test(e)&&(f=yw.exec(e)))if(e=f[1].trim(),f=f[2].trim(),"Format"==e)d=f.split(zw);else if("Style"==e){e=f.split(zw);f={};for(var g=0;g<d.length&&g<e.length;g++)f[d[g]]=e[g];a.push(f)}d=