shaka-player 4.6.3 → 4.6.5

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 (49) hide show
  1. package/CHANGELOG.md +21 -0
  2. package/demo/common/asset.js +0 -1
  3. package/demo/common/assets.js +0 -1
  4. package/dist/demo.compiled.debug.map +1 -1
  5. package/dist/demo.compiled.map +1 -1
  6. package/dist/deps.js +5 -5
  7. package/dist/locales.js +33 -33
  8. package/dist/receiver.compiled.debug.map +1 -1
  9. package/dist/receiver.compiled.map +1 -1
  10. package/dist/shaka-player.compiled.d.ts +1 -1
  11. package/dist/shaka-player.compiled.debug.d.ts +1 -1
  12. package/dist/shaka-player.compiled.debug.externs.js +5 -2
  13. package/dist/shaka-player.compiled.debug.js +172 -171
  14. package/dist/shaka-player.compiled.debug.map +3 -3
  15. package/dist/shaka-player.compiled.externs.js +5 -2
  16. package/dist/shaka-player.compiled.js +227 -224
  17. package/dist/shaka-player.compiled.map +3 -3
  18. package/dist/shaka-player.ui.d.ts +1 -1
  19. package/dist/shaka-player.ui.debug.d.ts +1 -1
  20. package/dist/shaka-player.ui.debug.externs.js +5 -2
  21. package/dist/shaka-player.ui.debug.js +196 -195
  22. package/dist/shaka-player.ui.debug.map +3 -3
  23. package/dist/shaka-player.ui.externs.js +5 -2
  24. package/dist/shaka-player.ui.js +223 -220
  25. package/dist/shaka-player.ui.map +3 -3
  26. package/docs/tutorials/ui.md +3 -1
  27. package/lib/ads/client_side_ad_manager.js +4 -0
  28. package/lib/ads/media_tailor_ad_manager.js +5 -0
  29. package/lib/ads/server_side_ad_manager.js +4 -0
  30. package/lib/hls/hls_parser.js +17 -5
  31. package/lib/media/drm_engine.js +0 -3
  32. package/lib/media/media_source_engine.js +1 -1
  33. package/lib/media/streaming_engine.js +3 -2
  34. package/lib/media/video_wrapper.js +4 -3
  35. package/lib/net/networking_utils.js +12 -3
  36. package/lib/player.js +5 -7
  37. package/lib/text/simple_text_displayer.js +8 -7
  38. package/lib/text/text_utils.js +39 -13
  39. package/lib/text/ui_text_displayer.js +20 -11
  40. package/lib/text/web_vtt_generator.js +1 -1
  41. package/lib/util/ts_parser.js +12 -8
  42. package/package.json +1 -1
  43. package/test/media/drm_engine_unit.js +27 -0
  44. package/test/player_unit.js +31 -0
  45. package/test/test/util/layout_tests.js +2 -1
  46. package/test/text/simple_text_displayer_unit.js +1 -1
  47. package/test/text/web_vtt_generator_unit.js +3 -3
  48. package/test/transmuxer/transmuxer_integration.js +3 -3
  49. package/ui/volume_bar.js +10 -6
@@ -13,10 +13,10 @@
13
13
  var q;function aa(a){var b=0;return function(){return b<a.length?{done:!1,value:a[b++]}:{done:!0}}}var ba="function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(a==Array.prototype||a==Object.prototype)return a;a[b]=c.value;return a};
14
14
  function ca(a){a=["object"==typeof globalThis&&globalThis,a,"object"==typeof window&&window,"object"==typeof self&&self,"object"==typeof global&&global];for(var b=0;b<a.length;++b){var c=a[b];if(c&&c.Math==Math)return c}throw Error("Cannot find global object");}var da=ca(this);function ea(a,b){if(b)a:{var c=da;a=a.split(".");for(var d=0;d<a.length-1;d++){var e=a[d];if(!(e in c))break a;c=c[e]}a=a[a.length-1];d=c[a];b=b(d);b!=d&&null!=b&&ba(c,a,{configurable:!0,writable:!0,value:b})}}
15
15
  ea("Symbol",function(a){function b(f){if(this instanceof b)throw new TypeError("Symbol is not a constructor");return new c(d+(f||"")+"_"+e++,f)}function c(f,g){this.g=f;ba(this,"description",{configurable:!0,writable:!0,value:g})}if(a)return a;c.prototype.toString=function(){return this.g};var d="jscomp_symbol_"+(1E9*Math.random()>>>0)+"_",e=0;return b});
16
- ea("Symbol.iterator",function(a){if(a)return a;a=Symbol("Symbol.iterator");for(var b="Array Int8Array Uint8Array Uint8ClampedArray Int16Array Uint16Array Int32Array Uint32Array Float32Array Float64Array".split(" "),c=0;c<b.length;c++){var d=da[b[c]];"function"===typeof d&&"function"!=typeof d.prototype[a]&&ba(d.prototype,a,{configurable:!0,writable:!0,value:function(){return ha(aa(this))}})}return a});function ha(a){a={next:a};a[Symbol.iterator]=function(){return this};return a}
17
- function t(a){var b="undefined"!=typeof Symbol&&Symbol.iterator&&a[Symbol.iterator];return b?b.call(a):{next:aa(a)}}function w(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 ia="function"==typeof Object.create?Object.create:function(a){function b(){}b.prototype=a;return new b},ja;
16
+ ea("Symbol.iterator",function(a){if(a)return a;a=Symbol("Symbol.iterator");for(var b="Array Int8Array Uint8Array Uint8ClampedArray Int16Array Uint16Array Int32Array Uint32Array Float32Array Float64Array".split(" "),c=0;c<b.length;c++){var d=da[b[c]];"function"===typeof d&&"function"!=typeof d.prototype[a]&&ba(d.prototype,a,{configurable:!0,writable:!0,value:function(){return fa(aa(this))}})}return a});function fa(a){a={next:a};a[Symbol.iterator]=function(){return this};return a}
17
+ function t(a){var b="undefined"!=typeof Symbol&&Symbol.iterator&&a[Symbol.iterator];return b?b.call(a):{next:aa(a)}}function w(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 ha="function"==typeof Object.create?Object.create:function(a){function b(){}b.prototype=a;return new b},ja;
18
18
  if("function"==typeof Object.setPrototypeOf)ja=Object.setPrototypeOf;else{var ka;a:{var la={a:!0},ma={};try{ma.__proto__=la;ka=ma.a;break a}catch(a){}ka=!1}ja=ka?function(a,b){a.__proto__=b;if(a.__proto__!==b)throw new TypeError(a+" is not extensible");return a}:null}var na=ja;
19
- function oa(a,b){a.prototype=ia(b.prototype);a.prototype.constructor=a;if(na)na(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.Oi=b.prototype}function pa(){this.o=!1;this.l=null;this.h=void 0;this.g=1;this.j=this.m=0;this.u=this.i=null}function qa(a){if(a.o)throw new TypeError("Generator is already running");a.o=!0}pa.prototype.s=function(a){this.h=a};
19
+ function oa(a,b){a.prototype=ha(b.prototype);a.prototype.constructor=a;if(na)na(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.Oi=b.prototype}function pa(){this.o=!1;this.l=null;this.h=void 0;this.g=1;this.j=this.m=0;this.u=this.i=null}function qa(a){if(a.o)throw new TypeError("Generator is already running");a.o=!0}pa.prototype.s=function(a){this.h=a};
20
20
  function ra(a,b){a.i={Bf:b,Jf:!0};a.g=a.m||a.j}pa.prototype.return=function(a){this.i={return:a};this.g=this.j};function C(a,b,c){a.g=c;return{value:b}}pa.prototype.B=function(a){this.g=a};function E(a){a.g=0}function sa(a,b,c){a.m=b;void 0!=c&&(a.j=c)}function ta(a,b){a.m=0;a.j=b||0}function va(a,b,c){a.g=b;a.m=c||0}function wa(a,b){a.m=b||0;b=a.i.Bf;a.i=null;return b}function xa(a){a.u=[a.i];a.m=0;a.j=0}
21
21
  function ya(a,b){var c=a.u.splice(0)[0];(c=a.i=a.i||c)?c.Jf?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 pa;this.h=a}function Aa(a,b){qa(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)}
22
22
  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,ra(a.g,g),Ca(a)}a.g.l=null;d.call(a.g,f);return Ca(a)}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,ra(a.g,c)}a.g.o=!1;if(a.g.i){b=a.g.i;a.g.i=null;if(b.Jf)throw b.Bf;return{value:b.return,done:!0}}return{value:void 0,done:!0}}
@@ -32,7 +32,7 @@ while(!k.done)})};return b});function Ga(a,b){return Object.prototype.hasOwnProp
32
32
  ea("WeakMap",function(a){function b(k){this.g=(h+=Math.random()+1).toString();if(k){k=t(k);for(var l;!(l=k.next()).done;)l=l.value,this.set(l[0],l[1])}}function c(){}function d(k){var l=typeof k;return"object"===l&&null!==k||"function"===l}function e(k){if(!Ga(k,g)){var l=new c;ba(k,g,{value:l})}}function f(k){var l=Object[k];l&&(Object[k]=function(m){if(m instanceof c)return m;Object.isExtensible(m)&&e(m);return l(m)})}if(function(){if(!a||!Object.seal)return!1;try{var k=Object.seal({}),l=Object.seal({}),
33
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(!Ga(k,g))throw Error("WeakMap key fail: "+k);k[g][this.g]=l;return this};b.prototype.get=function(k){return d(k)&&Ga(k,g)?k[g][this.g]:void 0};b.prototype.has=function(k){return d(k)&&Ga(k,
34
34
  g)&&Ga(k[g],this.g)};b.prototype.delete=function(k){return d(k)&&Ga(k,g)&&Ga(k[g],this.g)?delete k[g][this.g]:!1};return b});
35
- ea("Map",function(a){function b(){var h={};return h.kb=h.next=h.head=h}function c(h,k){var l=h.g;return ha(function(){if(l){for(;l.head!=h.g;)l=l.kb;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&&Ga(h.h,l))for(h=0;h<m.length;h++){var n=m[h];if(k!==k&&n.key!==n.key||k===n.key)return{id:l,list:m,index:h,entry:n}}return{id:l,
35
+ ea("Map",function(a){function b(){var h={};return h.kb=h.next=h.head=h}function c(h,k){var l=h.g;return fa(function(){if(l){for(;l.head!=h.g;)l=l.kb;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&&Ga(h.h,l))for(h=0;h<m.length;h++){var n=m[h];if(k!==k&&n.key!==n.key||k===n.key)return{id:l,list:m,index:h,entry:n}}return{id:l,
36
36
  list:m,index:-1,entry: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
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.entry?l.entry.value=k:(l.entry={next:this.g,kb:this.g.kb,head:this.g,key:h,value:k},l.list.push(l.entry),this.g.kb.next=l.entry,this.g.kb=l.entry,this.size++);return this};e.prototype.delete=function(h){h=d(this,h);return h.entry&&h.list?(h.list.splice(h.index,1),h.list.length||delete this.h[h.id],h.entry.kb.next=h.entry.next,
38
38
  h.entry.next.kb=h.entry.kb,h.entry.head=null,this.size--,!0):!1};e.prototype.clear=function(){this.h={};this.g=this.g.kb=b();this.size=0};e.prototype.has=function(h){return!!d(this,h).entry};e.prototype.get=function(h){return(h=d(this,h).entry)&&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=
@@ -64,7 +64,7 @@ function mb(a,b,c){c=void 0===c?Infinity:c;return ob(a,void 0===b?0:b,c,Uint8Arr
64
64
  N("shaka.util.BufferUtils",jb);jb.toDataView=qb;jb.toUint16=pb;jb.toUint8=mb;jb.toArrayBuffer=nb;jb.equal=kb;function rb(){}rb.prototype.init=function(){};rb.prototype.i=function(){};rb.prototype.h=function(){};rb.prototype.j=function(){};N("shaka.media.IClosedCaptionParser",rb);function sb(a){this.l=new hb;if(a=tb[a.toLowerCase()])this.l=a();this.g=new gb;if(a=ub)this.g=a()}sb.prototype.init=function(a){this.l.init(a)};sb.prototype.i=function(a){a=this.l.parse(a);a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;var c=mb(b.packet);0<c.length&&this.g.extract(c,b.pts)}return this.g.decode()};
65
65
  sb.prototype.h=function(){this.g.clear()};sb.prototype.j=function(){return this.g.getStreams()};N("shaka.media.ClosedCaptionParser",sb);sb.findDecoder=function(){return ub};sb.unregisterDecoder=function(){ub=null};sb.registerDecoder=function(a){ub=a};sb.findParser=function(a){return tb[a]};sb.unregisterParser=function(a){delete tb[a]};sb.registerParser=function(a,b){tb[a]=b};var tb={},ub=null;function vb(a,b){return"number"===typeof a&&"number"===typeof b&&isNaN(a)&&isNaN(b)?!0:a===b}function yb(a,b){b=a.indexOf(b);-1<b&&a.splice(b,1)}function zb(a,b,c){c||(c=vb);if(a.length!=b.length)return!1;b=b.slice();var d={};a=t(a);for(var e=a.next();!e.done;d={Rd:d.Rd},e=a.next()){d.Rd=e.value;e=b.findIndex(function(f){return function(g){return c(f.Rd,g)}}(d));if(-1==e)return!1;b[e]=b[b.length-1];b.pop()}return 0==b.length}
66
66
  function Ab(a,b,c){c||(c=vb);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 Bb(a,b,c){this.startTime=a;this.endTime=b;this.payload=c;this.region=new Cb;this.position=null;this.positionAlign=Db;this.size=0;this.textAlign=Eb;this.direction=Fb;this.writingMode=Gb;this.lineInterpretation=Hb;this.line=null;this.lineHeight="";this.lineAlign=Ib;this.displayAlign=Jb;this.fontSize=this.border=this.backgroundImage=this.backgroundColor=this.color="";this.fontWeight=Kb;this.fontStyle=Lb;this.linePadding=this.letterSpacing=this.fontFamily="";this.opacity=1;this.textCombineUpright=
67
- "";this.textDecoration=[];this.textStrokeWidth=this.textStrokeColor=this.textShadow="";this.wrapLine=!0;this.id="";this.nestedCues=[];this.lineBreak=this.isContainer=!1;this.rubyTag=null;this.cellResolution={Eb:32,rows:15}}function Mb(a,b){a=new Bb(a,b,"");a.lineBreak=!0;return a}Bb.prototype.clone=function(){var a=new Bb(0,0,""),b;for(b in this)a[b]=this[b],a[b]&&a[b].constructor==Array&&(a[b]=a[b].slice());return a};
67
+ "";this.textDecoration=[];this.textStrokeWidth=this.textStrokeColor=this.textShadow="";this.wrapLine=!0;this.id="";this.nestedCues=[];this.lineBreak=this.isContainer=!1;this.rubyTag=null;this.cellResolution={Db:32,rows:15}}function Mb(a,b){a=new Bb(a,b,"");a.lineBreak=!0;return a}Bb.prototype.clone=function(){var a=new Bb(0,0,""),b;for(b in this)a[b]=this[b],a[b]&&a[b].constructor==Array&&(a[b]=a[b].slice());return a};
68
68
  function Nb(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(!Ab(a.nestedCues,b.nestedCues,Nb))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(!Ab(a[c],b[c]))return!1}else if(a[c]!=b[c])return!1;return!0}N("shaka.text.Cue",Bb);Bb.equal=Nb;Bb.prototype.clone=Bb.prototype.clone;var Db="auto";
69
69
  Bb.positionAlign={LEFT:"line-left",RIGHT:"line-right",CENTER:"center",AUTO:Db};var Eb="center",Ob={LEFT:"left",RIGHT:"right",CENTER:Eb,START:"start",END:"end"};Bb.textAlign=Ob;var Jb="after",Pb={BEFORE:"before",CENTER:"center",AFTER:Jb};Bb.displayAlign=Pb;var Fb="ltr";Bb.direction={HORIZONTAL_LEFT_TO_RIGHT:Fb,HORIZONTAL_RIGHT_TO_LEFT:"rtl"};var Gb="horizontal-tb";Bb.writingMode={HORIZONTAL_TOP_TO_BOTTOM:Gb,VERTICAL_LEFT_TO_RIGHT:"vertical-lr",VERTICAL_RIGHT_TO_LEFT:"vertical-rl"};var Hb=0;
70
70
  Bb.lineInterpretation={LINE_NUMBER:Hb,PERCENTAGE:1};var Ib="start",Qb={CENTER:"center",START:Ib,END:"end"};Bb.lineAlign=Qb;var Rb={white:"white",lime:"lime",cyan:"cyan",red:"red",yellow:"yellow",magenta:"magenta",blue:"blue",black:"black"};Bb.defaultTextColor=Rb;var Tb={bg_white:"white",bg_lime:"lime",bg_cyan:"cyan",bg_red:"red",bg_yellow:"yellow",bg_magenta:"magenta",bg_blue:"blue",bg_black:"black"};Bb.defaultTextBackgroundColor=Tb;var Kb=400;Bb.fontWeight={NORMAL:Kb,BOLD:700};
@@ -79,10 +79,10 @@ var ec=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^/?#]*)@)?([^/#?]*?)(?::([0-9]+))?(?=
79
79
  Copyright 2006 The Closure Library Authors
80
80
  SPDX-License-Identifier: Apache-2.0
81
81
  */
82
- function fc(a){var b;a instanceof fc?(gc(this,a.Va),this.Rb=a.Rb,hc(this,a.fb),ic(this,a.ec),this.Ca=a.Ca,jc(this,a.g.clone()),this.Fb=a.Fb):a&&(b=String(a).match(ec))?(gc(this,b[1]||"",!0),this.Rb=kc(b[2]||""),hc(this,b[3]||"",!0),ic(this,b[4]),this.Ca=kc(b[5]||"",!0),jc(this,b[6]||"",!0),this.Fb=kc(b[7]||"")):this.g=new lc(null)}q=fc.prototype;q.Va="";q.Rb="";q.fb="";q.ec=null;q.Ca="";q.Fb="";
83
- q.toString=function(){var a=[],b=this.Va;b&&a.push(mc(b,nc,!0),":");if(b=this.fb){a.push("//");var c=this.Rb;c&&a.push(mc(c,nc,!0),"@");a.push(encodeURIComponent(b).replace(/%25([0-9a-fA-F]{2})/g,"%$1"));b=this.ec;null!=b&&a.push(":",String(b))}if(b=this.Ca)this.fb&&"/"!=b.charAt(0)&&a.push("/"),a.push(mc(b,"/"==b.charAt(0)?oc:pc,!0));(b=this.g.toString())&&a.push("?",b);(b=this.Fb)&&a.push("#",mc(b,qc));return a.join("")};
82
+ function fc(a){var b;a instanceof fc?(gc(this,a.Va),this.Rb=a.Rb,hc(this,a.fb),ic(this,a.ec),this.Ca=a.Ca,jc(this,a.g.clone()),this.Eb=a.Eb):a&&(b=String(a).match(ec))?(gc(this,b[1]||"",!0),this.Rb=kc(b[2]||""),hc(this,b[3]||"",!0),ic(this,b[4]),this.Ca=kc(b[5]||"",!0),jc(this,b[6]||"",!0),this.Eb=kc(b[7]||"")):this.g=new lc(null)}q=fc.prototype;q.Va="";q.Rb="";q.fb="";q.ec=null;q.Ca="";q.Eb="";
83
+ q.toString=function(){var a=[],b=this.Va;b&&a.push(mc(b,nc,!0),":");if(b=this.fb){a.push("//");var c=this.Rb;c&&a.push(mc(c,nc,!0),"@");a.push(encodeURIComponent(b).replace(/%25([0-9a-fA-F]{2})/g,"%$1"));b=this.ec;null!=b&&a.push(":",String(b))}if(b=this.Ca)this.fb&&"/"!=b.charAt(0)&&a.push("/"),a.push(mc(b,"/"==b.charAt(0)?oc:pc,!0));(b=this.g.toString())&&a.push("?",b);(b=this.Eb)&&a.push("#",mc(b,qc));return a.join("")};
84
84
  q.resolve=function(a){var b=this.clone();"data"===b.Va&&(b=new fc);var c=!!a.Va;c?gc(b,a.Va):c=!!a.Rb;c?b.Rb=a.Rb:c=!!a.fb;c?hc(b,a.fb):c=null!=a.ec;var d=a.Ca;if(c)ic(b,a.ec);else if(c=!!a.Ca){if("/"!=d.charAt(0))if(this.fb&&!this.Ca)d="/"+d;else{var e=b.Ca.lastIndexOf("/");-1!=e&&(d=b.Ca.substr(0,e+1)+d)}if(".."==d||"."==d)d="";else if(-1!=d.indexOf("./")||-1!=d.indexOf("/.")){e=0==d.lastIndexOf("/",0);d=d.split("/");for(var f=[],g=0;g<d.length;){var h=d[g++];"."==h?e&&g==d.length&&f.push(""):".."==
85
- h?((1<f.length||1==f.length&&""!=f[0])&&f.pop(),e&&g==d.length&&f.push("")):(f.push(h),e=!0)}d=f.join("/")}}c?b.Ca=d:c=""!==a.g.toString();c?jc(b,a.g.clone()):c=!!a.Fb;c&&(b.Fb=a.Fb);return b};q.clone=function(){return new fc(this)};function gc(a,b,c){a.Va=c?kc(b,!0):b;a.Va&&(a.Va=a.Va.replace(/:$/,""))}function hc(a,b,c){a.fb=c?kc(b,!0):b}function ic(a,b){if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.ec=b}else a.ec=null}
85
+ h?((1<f.length||1==f.length&&""!=f[0])&&f.pop(),e&&g==d.length&&f.push("")):(f.push(h),e=!0)}d=f.join("/")}}c?b.Ca=d:c=""!==a.g.toString();c?jc(b,a.g.clone()):c=!!a.Eb;c&&(b.Eb=a.Eb);return b};q.clone=function(){return new fc(this)};function gc(a,b,c){a.Va=c?kc(b,!0):b;a.Va&&(a.Va=a.Va.replace(/:$/,""))}function hc(a,b,c){a.fb=c?kc(b,!0):b}function ic(a,b){if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.ec=b}else a.ec=null}
86
86
  function jc(a,b,c){b instanceof lc?a.g=b:(c||(b=mc(b,rc)),a.g=new lc(b))}function kc(a,b){return a?b?decodeURI(a):decodeURIComponent(a):""}function mc(a,b,c){return null!=a?(a=encodeURI(a).replace(b,sc),c&&(a=a.replace(/%25([0-9a-fA-F]{2})/g,"%$1")),a):null}function sc(a){a=a.charCodeAt(0);return"%"+(a>>4&15).toString(16)+(a&15).toString(16)}var nc=/[#\/\?@]/g,pc=/[#\?:]/g,oc=/[#\?]/g,rc=/[#\?@]/g,qc=/#/g;function lc(a){this.g=a||null}
87
87
  function tc(a){if(!a.ta&&(a.ta={},a.Gc=0,a.g))for(var b=a.g.split("&"),c=0;c<b.length;c++){var d=b[c].indexOf("="),e=null;if(0<=d){var f=b[c].substring(0,d);e=b[c].substring(d+1)}else f=b[c];f=decodeURIComponent(f.replace(/\+/g," "));e=e||"";a.add(f,decodeURIComponent(e.replace(/\+/g," ")))}}q=lc.prototype;q.ta=null;q.Gc=null;function uc(a){tc(a);return a.Gc}q.add=function(a,b){tc(this);this.g=null;var c=this.ta.hasOwnProperty(a)?this.ta[a]:null;c||(this.ta[a]=c=[]);c.push(b);this.Gc++;return this};
88
88
  q.set=function(a,b){tc(this);this.g=null;this.ta.hasOwnProperty(a)?this.ta[a]=[b]:this.add(a,b);return this};q.get=function(a){tc(this);return this.ta[a]||[]};q.toString=function(){if(this.g)return this.g;if(!this.ta)return"";var a=[],b;for(b in this.ta)for(var c=encodeURIComponent(b),d=this.ta[b],e=0;e<d.length;e++){var f=c;""!==d[e]&&(f+="="+encodeURIComponent(d[e]));a.push(f)}return this.g=a.join("&")};
@@ -118,7 +118,7 @@ var bd=new Map([["aar","aa"],["abk","ab"],["afr","af"],["aka","ak"],["alb","sq"]
118
118
  id.prototype.tickAfter=id.prototype.U;id.prototype.tickNow=id.prototype.ic;function jd(){var a=window.ManagedMediaSource||window.MediaSource;return a&&a.isTypeSupported?!0:!1}function kd(a){return""!=ld().canPlayType(a)}function md(){return navigator.userAgent.match(/Edge?\//)?!0:!1}function nd(){return od("Xbox One")}function pd(){return od("Tizen")}function qd(){return od("Tizen 3")}function rd(){return od("Tizen 2")}function sd(){return od("Web0S")&&od("Chrome/38.0.2125.122 Safari/537.36")}
119
119
  function td(){return!!navigator.vendor&&navigator.vendor.includes("Apple")&&!pd()&&!od("PC=EOS")&&!od("VirginMedia")&&!od("SOPOpenBrowser")&&!ud()&&!od("AFT")}function ud(){return od("PlayStation 4")}function vd(){if(!td())return null;var a=navigator.userAgent.match(/Version\/(\d+)/);return a?parseInt(a[1],10):(a=navigator.userAgent.match(/OS (\d+)(?:_\d+)?/))?parseInt(a[1],10):null}function od(a){return(navigator.userAgent||"").includes(a)}
120
120
  function ld(){if(wd)return wd;yd||(yd=new id(function(){wd=null}));(wd=document.getElementsByTagName("video")[0]||document.getElementsByTagName("audio")[0])||(wd=document.createElement("video"));yd.U(1);return wd}var yd=null,wd=null;function zd(){}
121
- function Ad(a,b,c,d){var e=a.variants;if(b.length||c.length)e=Bd(e,b,c);if(d.length){b=new gd;c=t(e);for(e=c.next();!e.done;e=c.next())e=e.value,b.push(String(e.video.width||0),e);var f=[];b.forEach(function(u,v){u=0;var x=[],z={};v=t(v);for(var y=v.next();!y.done;z={yc:z.yc},y=v.next())z.yc=y.value,y=d.filter(function(B){return function(A){return B.yc.decodingInfos[0][A]}}(z)).length,y>u?(u=y,x=[z.yc]):y==u&&x.push(z.yc);f.push.apply(f,w(x))});e=f}c=new Set;b=new Set;var g=t(e);for(e=g.next();!e.done;e=
121
+ function Ad(a,b,c,d){var e=a.variants;if(b.length||c.length)e=Bd(e,b,c);if(d.length){b=new gd;c=t(e);for(e=c.next();!e.done;e=c.next())e=e.value,b.push(String(e.video.width||0),e);var f=[];b.forEach(function(u,v){u=0;var x=[],z={};v=t(v);for(var y=v.next();!y.done;z={yc:z.yc},y=v.next())z.yc=y.value,y=d.filter(function(A){return function(B){return A.yc.decodingInfos[0][B]}}(z)).length,y>u?(u=y,x=[z.yc]):y==u&&x.push(z.yc);f.push.apply(f,w(x))});e=f}c=new Set;b=new Set;var g=t(e);for(e=g.next();!e.done;e=
122
122
  g.next())e=e.value,e.audio&&c.add(e.audio),e.video&&b.add(e.video);c=Array.from(c).sort(function(u,v){return u.bandwidth-v.bandwidth});var h=[];e=new Map;c=t(c);for(g=c.next();!g.done;g=c.next()){g=g.value;var k=g.language+(g.channelsCount||0)+(g.audioSamplingRate||0)+g.roles.join(",")+g.label+g.groupId+g.fastSwitching,l=e.get(k)||[];if(l.length){var m=l[l.length-1],n=Ic(m.codecs),r=Ic(g.codecs);n==r&&g.bandwidth>m.bandwidth&&(l.push(g),h.push(g.id))}else l.push(g),h.push(g.id);e.set(k,l)}c=Array.from(b).sort(function(u,
123
123
  v){return u.bandwidth&&v.bandwidth?u.bandwidth-v.bandwidth:u.width-v.width});b=fb();var p=[];e=new Map;c=t(c);for(g=c.next();!g.done;g=c.next()){g=g.value;k=Math.round(g.frameRate||0)+(g.hdr||"")+g.fastSwitching;l=e.get(k)||[];if(l.length){m=l[l.length-1];if(!b&&(n=Ic(m.codecs),r=Ic(g.codecs),n!==r))continue;g.width>m.width||g.height>m.height?(l.push(g),p.push(g.id)):g.width==m.width&&g.height==m.height&&(n=Ic(m.codecs),r=Ic(g.codecs),n==r&&g.bandwidth<m.bandwidth&&(l.push(g),p.push(g.id)))}else l.push(g),
124
124
  p.push(g.id);e.set(k,l)}a.variants=a.variants.filter(function(u){var v=u.audio;u=u.video;return v&&!h.includes(v.id)||u&&!p.includes(u.id)?!1:!0})}
@@ -129,8 +129,8 @@ function Fd(a,b,c){var d,e,f,g;return K(function(h){if(1==h.g)return C(h,Id(b.va
129
129
  Hc(l.mimeType,m,f.ea);if(!bb(n))return!1;l.codecs=m}if(l=k.audio){m=Ld(l.codecs);n=Hc(l.mimeType,m,f.P);if(!bb(n))return!1;l.codecs=m}(l=k.decodingInfos.some(function(p){return!p.supported||d&&(p=p.keySystemAccess)&&p.keySystem!=d?!1:!0}))||Xa(Jd(k));return l});E(h)})}
130
130
  function Md(a){var b=[];for(c in a)b.push(c);b.sort();var c=[];b=t(b);for(var d=b.next();!d.done;d=b.next()){var e=d.value;d=JSON.stringify(e);e=a[e];e instanceof Object?(e=Md(e),c.push(d+":"+e)):(e=JSON.stringify(e),c.push(d+":"+e))}return"{"+c.join(",")+"}"}
131
131
  function Nd(a,b){var c,d,e;return K(function(f){switch(f.g){case 1:c=Md(b);sa(f,2);d=Od;if(d[c]){a.decodingInfos.push(d[c]);f.B(4);break}return C(f,navigator.mediaCapabilities.decodingInfo(b),5);case 5:e=f.h,d[c]=e,a.decodingInfos.push(e);case 4:va(f,0);break;case 2:wa(f),JSON.stringify(b),E(f)}})}
132
- function Id(a,b,c,d){var e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,B,A;return K(function(D){switch(D.g){case 1:if(e=a.some(function(F){return F.decodingInfos.length}))return D.return();f={};g=t(d);h=g.next();case 2:if(h.done){D.B(4);break}f.Sd=h.value;k=!1;l=t(a);m=l.next();case 5:if(m.done){D.B(7);break}n=m.value;r=Pd(n,b,c).filter(function(F){return function(J){return(J.keySystemConfiguration&&J.keySystemConfiguration.keySystem)===F.Sd}}(f));p=t(r);u=p.next();case 8:if(u.done){D.B(10);break}v=u.value;return C(D,
133
- Nd(n,v),9);case 9:u=p.next();D.B(8);break;case 10:n.decodingInfos.length&&(k=!0);m=l.next();D.B(5);break;case 7:if(k)return D.return();f={Sd:f.Sd};h=g.next();D.B(2);break;case 4:x=t(a),m=x.next();case 12:if(m.done){D.B(0);break}z=m.value;y=Pd(z,b,c).filter(function(F){F=F.keySystemConfiguration&&F.keySystemConfiguration.keySystem;return!F||!d.includes(F)});B=t(y);u=B.next();case 15:if(u.done){m=x.next();D.B(12);break}A=u.value;return C(D,Nd(z,A),16);case 16:u=B.next(),D.B(15)}})}
132
+ function Id(a,b,c,d){var e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,A,B;return K(function(D){switch(D.g){case 1:if(e=a.some(function(F){return F.decodingInfos.length}))return D.return();f={};g=t(d);h=g.next();case 2:if(h.done){D.B(4);break}f.Sd=h.value;k=!1;l=t(a);m=l.next();case 5:if(m.done){D.B(7);break}n=m.value;r=Pd(n,b,c).filter(function(F){return function(J){return(J.keySystemConfiguration&&J.keySystemConfiguration.keySystem)===F.Sd}}(f));p=t(r);u=p.next();case 8:if(u.done){D.B(10);break}v=u.value;return C(D,
133
+ Nd(n,v),9);case 9:u=p.next();D.B(8);break;case 10:n.decodingInfos.length&&(k=!0);m=l.next();D.B(5);break;case 7:if(k)return D.return();f={Sd:f.Sd};h=g.next();D.B(2);break;case 4:x=t(a),m=x.next();case 12:if(m.done){D.B(0);break}z=m.value;y=Pd(z,b,c).filter(function(F){F=F.keySystemConfiguration&&F.keySystemConfiguration.keySystem;return!F||!d.includes(F)});A=t(y);u=A.next();case 15:if(u.done){m=x.next();D.B(12);break}B=u.value;return C(D,Nd(z,B),16);case 16:u=A.next(),D.B(15)}})}
134
134
  function Pd(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=yc("video",g);f=Kd(f);g=yc("audio",g);g=Ld(g);g=Hc(e.mimeType,g,"audio");c.audio={contentType:g,channels:2,bitrate:a.bandwidth||1,samplerate:1,spatialRendering:!1}}f=Kd(f);f=Hc(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=
135
135
  "srgb";break;case "PQ":c.video.transferFunction="pq";break;case "HLG":c.video.transferFunction="hlg"}}d&&(f=Ld(d.codecs),f=Hc(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,
136
136
  []);f.get(k.keySystem).push(k)}g=b?"required":"optional";b=b?["persistent-license"]:["temporary"];k=t(f.keys());for(var l=k.next();!l.done;l=k.next()){var m=l.value;l=Object.assign({},c);var n=f.get(m);m={keySystem:m,initDataType:"cenc",persistentState:g,distinctiveIdentifier:"optional",sessionTypes:b};n=t(n);for(h=n.next();!h.done;h=n.next()){h=h.value;if(h.initData&&h.initData.length){for(var r=new Set,p=t(h.initData),u=p.next();!u.done;u=p.next())r.add(u.value.initDataType);m.initDataType=h.initData[0].initDataType}h.distinctiveIdentifierRequired&&
@@ -165,8 +165,8 @@ var je=1;function ke(a,b){this.g=a;this.h=b}ke.prototype.toString=function(){ret
165
165
  function qe(a,b,c,d){var e;if(!(e=!!a.audio!=!!b.audio||!!a.video!=!!b.video||a.language!=b.language)&&(e=a.audio&&b.audio)){e=a.audio;var f=b.audio;e=!!((!e.channelsCount||!f.channelsCount||2<e.channelsCount||2<f.channelsCount)&&e.channelsCount!=f.channelsCount||c&&!re(e,f)||!se(e.roles,f.roles)||d&&e.groupId!==f.groupId)}!(d=e)&&(d=a.video&&b.video)&&(a=a.video,b=b.video,d=!((!c||re(a,b))&&se(a.roles,b.roles)));return d?!1:!0}pe.prototype.values=function(){return this.g.values()};
166
166
  function re(a,b){if(a.mimeType!=b.mimeType)return!1;a=a.codecs.split(",").map(function(d){return Jc(d)[0]});b=b.codecs.split(",").map(function(d){return Jc(d)[0]});if(a.length!=b.length)return!1;a.sort();b.sort();for(var c=0;c<a.length;c++)if(a[c]!=b[c])return!1;return!0}function se(a,b){a=new Set(a);b=new Set(b);a.delete("main");b.delete("main");if(a.size!=b.size)return!1;a=t(a);for(var c=a.next();!c.done;c=a.next())if(!b.has(c.value))return!1;return!0};function ve(a,b,c){b=void 0===b?"reload":b;c=void 0===c?!1:c;this.i=a;this.h=b;this.g=c;this.j=new we(a.language,"",a.audio&&a.audio.channelsCount?a.audio.channelsCount:0,"","","",b,c)}ve.prototype.create=function(a){var b=this,c="smooth"==this.h&&fb(),d=a.filter(function(e){return qe(b.i,e,!c,b.g)});return d.length?new pe(d[0],d,!c,this.g):this.j.create(a)};
167
167
  function we(a,b,c,d,e,f,g,h){this.o=a;this.s=b;this.g=c;this.h=d;this.j=e;this.i=void 0===f?"":f;this.l=void 0===g?"reload":g;this.m=void 0===h?!1:h}
168
- we.prototype.create=function(a){var b=[];b=xe(a,this.o);var c=a.filter(function(d){return d.primary});b=b.length?b:c.length?c:a;a=ye(b,this.s);a.length&&(b=a);this.j&&(a=ze(b,this.j),a.length&&(b=a));this.h&&(a=Ae(b,this.h),a.length&&(b=a));this.g&&(a=Ce(b,this.g),a.length&&(b=a));this.i&&(a=De(b,this.i),a.length&&(b=a));return new pe(b[0],b,!("smooth"==this.l&&fb()),this.m)};function xe(a,b){b=Zc(b);var c=fd(b,a.map(function(d){return ed(d)}));return c?a.filter(function(d){return c==ed(d)}):[]}
169
- function ye(a,b){return a.filter(function(c){return c.audio?b?c.audio.roles.includes(b):0==c.audio.roles.length:!1})}function De(a,b){return a.filter(function(c){return c.audio&&c.audio.label?c.audio.label.toLowerCase()==b.toLowerCase():!1})}function Ce(a,b){return a.filter(function(c){return c.audio&&c.audio.channelsCount&&c.audio.channelsCount!=b?!1:!0})}
168
+ we.prototype.create=function(a){var b=[];b=xe(a,this.o);var c=a.filter(function(d){return d.primary});b=b.length?b:c.length?c:a;a=ye(b,this.s);a.length&&(b=a);this.j&&(a=ze(b,this.j),a.length&&(b=a));this.h&&(a=Ae(b,this.h),a.length&&(b=a));this.g&&(a=Be(b,this.g),a.length&&(b=a));this.i&&(a=De(b,this.i),a.length&&(b=a));return new pe(b[0],b,!("smooth"==this.l&&fb()),this.m)};function xe(a,b){b=Zc(b);var c=fd(b,a.map(function(d){return ed(d)}));return c?a.filter(function(d){return c==ed(d)}):[]}
169
+ function ye(a,b){return a.filter(function(c){return c.audio?b?c.audio.roles.includes(b):0==c.audio.roles.length:!1})}function De(a,b){return a.filter(function(c){return c.audio&&c.audio.label?c.audio.label.toLowerCase()==b.toLowerCase():!1})}function Be(a,b){return a.filter(function(c){return c.audio&&c.audio.channelsCount&&c.audio.channelsCount!=b?!1:!0})}
170
170
  function Ae(a,b){"AUTO"==b&&(b=window.matchMedia("(color-gamut: p3)").matches?"PQ":"SDR");return a.filter(function(c){return c.video&&c.video.hdr&&c.video.hdr!=b?!1:!0})}function ze(a,b){return a.filter(function(c){return c.video&&c.video.videoLayout&&c.video.videoLayout!=b?!1:!0})};function Ee(){this.g=Fe;this.h=(new Map).set(Fe,2).set(Ge,1)}function He(a,b,c){a.h.set(Fe,c).set(Ge,b)}var Ge=0,Fe=1;function Ie(a,b){var c=Je();this.l=null==a.maxAttempts?c.maxAttempts:a.maxAttempts;this.j=null==a.baseDelay?c.baseDelay:a.baseDelay;this.o=null==a.fuzzFactor?c.fuzzFactor:a.fuzzFactor;this.m=null==a.backoffFactor?c.backoffFactor:a.backoffFactor;this.g=0;this.h=this.j;if(this.i=void 0===b?!1:b)this.g=1}
171
171
  function Ke(a){var b,c;return K(function(d){if(1==d.g){if(a.g>=a.l)if(a.i)a.g=1,a.h=a.j;else throw new O(2,7,1010);b=a.g;a.g++;if(0==b)return d.return();c=a.h*(1+(2*Math.random()-1)*a.o);return C(d,new Promise(function(e){(new id(e)).U(c/1E3)}),2)}a.h*=a.m;E(d)})}function Je(){return{maxAttempts:2,baseDelay:1E3,backoffFactor:2,fuzzFactor:.5,timeout:3E4,stallTimeout:5E3,connectionTimeout:1E4}};function Le(){var a,b,c=new Promise(function(d,e){a=d;b=e});c.resolve=a;c.reject=b;return c}Le.prototype.resolve=function(){};Le.prototype.reject=function(){};function Me(a,b){this.promise=a;this.i=b;this.g=!1}function Ne(a){return new Me(Promise.reject(a),function(){return Promise.resolve()})}function Oe(){var a=Promise.reject(new O(2,7,7001));a.catch(function(){});return new Me(a,function(){return Promise.resolve()})}function Pe(a){return new Me(Promise.resolve(a),function(){return Promise.resolve()})}function Qe(a){return new Me(a,function(){return a.catch(function(){})})}Me.prototype.abort=function(){this.g=!0;return this.i()};
172
172
  function Re(a){return new Me(Promise.all(a.map(function(b){return b.promise})),function(){return Promise.all(a.map(function(b){return b.abort()}))})}Me.prototype.finally=function(a){this.promise.then(function(){return a(!0)},function(){return a(!1)});return this};
@@ -180,9 +180,9 @@ q.vg=function(){this.h.clear()};function df(a,b,c){return{uris:a,method:"GET",bo
180
180
  q.request=function(a,b,c){var d=this,e=new ef;if(this.i){var f=Promise.reject(new O(2,7,7001));f.catch(function(){});return new ff(f,function(){return Promise.resolve()},e)}b.method=b.method||"GET";b.headers=b.headers||{};b.retryParameters=b.retryParameters?We(b.retryParameters):Je();b.uris=We(b.uris);f=gf(this,a,b,c);var g=f.oa(function(){return hf(d,a,b,c,new Ie(b.retryParameters,!1),0,null,e)}),h=g.oa(function(r){return jf(d,a,r,c)}),k=Date.now(),l=0;f.promise.then(function(){l=Date.now()-k},function(){});
181
181
  var m=0;g.promise.then(function(){m=Date.now()},function(){});var n=h.oa(function(r){var p=Date.now()-m,u=r.response;u.timeMs+=l;u.timeMs+=p;r.ah||!d.l||u.fromCache||"HEAD"==b.method||a!=kf||d.l(u.timeMs,u.data.byteLength,lf(c));return u},function(r){r&&(r.severity=2);throw r;});f=new ff(n.promise,function(){return n.abort()},e);Ze(this.m,f);return f};
182
182
  function gf(a,b,c,d){function e(h){f=f.oa(function(){c.body&&(c.body=nb(c.body));return h(b,c,d)})}var f=Pe(void 0);a.u&&e(a.u);a=t(a.g);for(var g=a.next();!g.done;g=a.next())e(g.value);return f.oa(void 0,function(h){if(h instanceof O&&7001==h.code)throw h;throw new O(2,1,1006,h);})}
183
- function hf(a,b,c,d,e,f,g,h){a.o&&(c.uris[f]=c.uris[f].replace("http://","https://"));0<f&&a.A&&a.A(b,d,c.uris[f],c.uris[f-1]);var k=new fc(c.uris[f]),l=k.Va,m=!1;l||(l=location.protocol,l=l.slice(0,-1),gc(k,l),c.uris[f]=k.toString());l=l.toLowerCase();var n=(l=cf[l])?l.Ld:null;if(!n)return Ne(new O(2,1,1E3,k));var r=l.sh,p=null,u=null,v=!1,x=!1,z;return Qe(Ke(e)).oa(function(){if(a.i)return Oe();z=Date.now();var y=n(c.uris[f],c,b,function(D,F,J){p&&p.stop();u&&u.U(A/1E3);a.l&&b==kf&&(a.l(D,F,lf(d)),
184
- m=!0,h.g=J)},function(D){a.j&&a.j(D,c,b);x=!0});if(!r)return y;var B=c.retryParameters.connectionTimeout;B&&(p=new id(function(){v=!0;y.abort()}),p.U(B/1E3));var A=c.retryParameters.stallTimeout;A&&(u=new id(function(){v=!0;y.abort()}));return y}).oa(function(y){p&&p.stop();u&&u.stop();void 0==y.timeMs&&(y.timeMs=Date.now()-z);var B={response:y,ah:m};!x&&a.j&&a.j(y.headers,c,b);return B},function(y){p&&p.stop();u&&u.stop();if(a.s){var B=null,A=0;y instanceof O&&(B=y,1001==y.code&&(A=y.data[1]));a.s(c,
185
- B,A,v)}if(a.i)return Oe();v&&(y=new O(1,1,1003,c.uris[f],b));if(y instanceof O){if(7001==y.code)throw y;if(1010==y.code)throw g;if(1==y.severity)return B=(new Map).set("error",y),B=new Q("retry",B),a.dispatchEvent(B),f=(f+1)%c.uris.length,hf(a,b,c,d,e,f,y,h)}throw y;})}
183
+ function hf(a,b,c,d,e,f,g,h){a.o&&(c.uris[f]=c.uris[f].replace("http://","https://"));0<f&&a.A&&a.A(b,d,c.uris[f],c.uris[f-1]);var k=new fc(c.uris[f]),l=k.Va,m=!1;l||(l=location.protocol,l=l.slice(0,-1),gc(k,l),c.uris[f]=k.toString());l=l.toLowerCase();var n=(l=cf[l])?l.Ld:null;if(!n)return Ne(new O(2,1,1E3,k));var r=l.sh,p=null,u=null,v=!1,x=!1,z;return Qe(Ke(e)).oa(function(){if(a.i)return Oe();z=Date.now();var y=n(c.uris[f],c,b,function(D,F,J){p&&p.stop();u&&u.U(B/1E3);a.l&&b==kf&&(a.l(D,F,lf(d)),
184
+ m=!0,h.g=J)},function(D){a.j&&a.j(D,c,b);x=!0});if(!r)return y;var A=c.retryParameters.connectionTimeout;A&&(p=new id(function(){v=!0;y.abort()}),p.U(A/1E3));var B=c.retryParameters.stallTimeout;B&&(u=new id(function(){v=!0;y.abort()}));return y}).oa(function(y){p&&p.stop();u&&u.stop();void 0==y.timeMs&&(y.timeMs=Date.now()-z);var A={response:y,ah:m};!x&&a.j&&a.j(y.headers,c,b);return A},function(y){p&&p.stop();u&&u.stop();if(a.s){var A=null,B=0;y instanceof O&&(A=y,1001==y.code&&(B=y.data[1]));a.s(c,
185
+ A,B,v)}if(a.i)return Oe();v&&(y=new O(1,1,1003,c.uris[f],b));if(y instanceof O){if(7001==y.code)throw y;if(1010==y.code)throw g;if(1==y.severity)return A=(new Map).set("error",y),A=new Q("retry",A),a.dispatchEvent(A),f=(f+1)%c.uris.length,hf(a,b,c,d,e,f,y,h)}throw y;})}
186
186
  function jf(a,b,c,d){var e=Pe(void 0),f={};a=t(a.h);for(var g=a.next();!g.done;f={Ud:f.Ud},g=a.next())f.Ud=g.value,e=e.oa(function(h){return function(){var k=c.response;k.data&&(k.data=nb(k.data));return h.Ud(b,k,d)}}(f));return e.oa(function(){return c},function(h){var k=2;if(h instanceof O){if(7001==h.code)throw h;k=h.severity}throw new O(k,1,1007,h);})}function lf(a){if(a){var b=a.segment;a=a.stream;if(b&&a&&a.fastSwitching&&b.C&&!b.A)return!1}return!0}N("shaka.net.NetworkingEngine",$e);
187
187
  $e.prototype.request=$e.prototype.request;$e.prototype.destroy=$e.prototype.destroy;$e.makeRequest=df;$e.defaultRetryParameters=function(){return Je()};$e.prototype.clearAllResponseFilters=$e.prototype.vg;$e.prototype.unregisterResponseFilter=$e.prototype.Mh;$e.prototype.registerResponseFilter=$e.prototype.uh;$e.prototype.clearAllRequestFilters=$e.prototype.ug;$e.prototype.unregisterRequestFilter=$e.prototype.Lh;$e.prototype.registerRequestFilter=$e.prototype.th;$e.unregisterScheme=function(a){delete cf[a]};
188
188
  $e.registerScheme=af;$e.prototype.setForceHTTPS=$e.prototype.cf;function ef(){this.g=0}$e.NumBytesRemainingClass=ef;function ff(a,b,c){Me.call(this,a,b);this.h=c}oa(ff,Me);$e.PendingRequest=ff;var kf=1;$e.RequestType={MANIFEST:0,SEGMENT:kf,LICENSE:2,APP:3,TIMING:4,SERVER_CERTIFICATE:5,KEY:6,ADS:7,CONTENT_STEERING:8};$e.AdvancedRequestType={INIT_SEGMENT:0,MEDIA_SEGMENT:1,MEDIA_PLAYLIST:2,MASTER_PLAYLIST:3,MPD:4,MSS:5};var bf=3;$e.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:bf};var cf={};function mf(a){this.g=!1;this.h=new Le;this.i=a}mf.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 nf(a,b){if(a.g){if(b instanceof O&&7003==b.code)throw b;throw new O(2,7,7003,b);}};function of(){this.g=new gd}q=of.prototype;q.release=function(){this.zb();this.g=null};q.D=function(a,b,c,d){this.g&&(a=new pf(a,b,c,d),this.g.push(b,a))};q.ha=function(a,b,c,d){function e(g){f.Qb(a,b,e);c(g)}var f=this;this.D(a,b,e,d)};q.Qb=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.Qb(),this.g.remove(b,e))}};
@@ -215,20 +215,20 @@ var wg=new vf(function(){if("undefined"!==typeof trustedTypes){var a=trustedType
215
215
  q=yg.prototype;q.destroy=function(){return this.j.destroy()};function Bg(a){return K(function(b){switch(b.g){case 1:return a.A.release(),a.A=null,a.l.reject(),a.la.stop(),a.la=null,a.W.stop(),a.W=null,C(b,Cg(a),2);case 2:if(!a.m){b.B(3);break}sa(b,4);return C(b,a.m.setMediaKeys(null),6);case 6:va(b,5);break;case 4:wa(b);case 5:a.m=null;case 3:a.g=null,a.G.clear(),a.s=null,a.u=new Map,a.h=null,a.o=function(){},a.C=null,a.$=!1,a.F=null,E(b)}})}q.configure=function(a){this.h=a};
216
216
  function Dg(a,b,c){a.ma=!0;a.u=new Map;a.K=c;return Eg(a,b)}function Fg(a,b,c){a.u=new Map;c=t(c);for(var d=c.next();!d.done;d=c.next())a.u.set(d.value,{initData:null,initDataType:null});c=t(a.h.persistentSessionsMetadata);for(d=c.next();!d.done;d=c.next())d=d.value,a.u.set(d.sessionId,{initData:d.initData,initDataType:d.initDataType});a.K=0<a.u.size;return Eg(a,b)}
217
217
  function Gg(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 Hg(a,g,[])}
218
- function Eg(a,b){var c,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y;return K(function(B){if(1==B.g){if(c=Ig(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(A){return A.video&&A.video.drmInfos.length||A.audio&&A.audio.drmInfos.length?!0:!1});g||(h=wf(a.h.servers),Jg(b,h));k=new Set;l=t(b);for(e=l.next();!e.done;e=l.next())for(m=e.value,n=Kg(m),r=t(n),p=r.next();!p.done;p=r.next())u=p.value,k.add(u);v=t(k);for(p=v.next();!p.done;p=
219
- v.next())x=p.value,Lg(x,wf(a.h.servers),wf(a.h.advanced||{}),a.h.keySystemsMapping);return C(B,Id(b,a.K,a.$,a.h.preferredKeySystems),2)}z=g||Object.keys(a.h.servers).length;if(!z)return a.da=!0,B.return(Promise.resolve());y=Hg(a,void 0,b);return B.return(g?y:y.catch(function(){}))})}
218
+ function Eg(a,b){var c,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y;return K(function(A){if(1==A.g){if(c=Ig(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(B){return B.video&&B.video.drmInfos.length||B.audio&&B.audio.drmInfos.length?!0:!1});g||(h=wf(a.h.servers),Jg(b,h));k=new Set;l=t(b);for(e=l.next();!e.done;e=l.next())for(m=e.value,n=Kg(m),r=t(n),p=r.next();!p.done;p=r.next())u=p.value,k.add(u);v=t(k);for(p=v.next();!p.done;p=
219
+ v.next())x=p.value,Lg(x,wf(a.h.servers),wf(a.h.advanced||{}),a.h.keySystemsMapping);return C(A,Id(b,a.K,a.$,a.h.preferredKeySystems),2)}z=g||Object.keys(a.h.servers).length;if(!z)return a.da=!0,A.return(Promise.resolve());y=Hg(a,void 0,b);return A.return(g?y:y.catch(function(){}))})}
220
220
  function Mg(a){var b;return K(function(c){switch(c.g){case 1:if(a.m.mediaKeys)return c.return();if(!a.F){c.B(2);break}return C(c,a.F,3);case 3:return nf(a.j),c.return();case 2:return sa(c,4),a.F=a.m.setMediaKeys(a.s),C(c,a.F,6);case 6:va(c,5);break;case 4:b=wa(c),a.o(new O(2,6,6003,b.message));case 5:nf(a.j),E(c)}})}function Ng(a,b){return K(function(c){if(1==c.g)return C(c,Mg(a),2);Og(a,b.initDataType,mb(b.initData));E(c)})}
221
221
  q.Cc=function(a){var b=this;return K(function(c){if(1==c.g){if(!b.s)return b.A.ha(a,"encrypted",function(){b.o(new O(2,6,6010))}),c.return();b.m=a;b.A.ha(b.m,"play",function(){for(var d=t(b.J),e=d.next();!e.done;e=d.next())Pg(b,e.value);b.N=!0;b.J=[]});"webkitCurrentPlaybackTargetIsWireless"in b.m&&b.A.D(b.m,"webkitcurrentplaybacktargetiswirelesschanged",function(){return Cg(b)});b.I=b.g?b.g.initData.find(function(d){return 0<d.initData.length})||null:null;return b.I||"com.apple.fps"!==b.g.keySystem||
222
222
  b.u.size?C(c,Mg(b),2):c.B(2)}Qg(b).catch(function(){});b.I||b.u.size||b.h.parseInbandPsshEnabled||b.A.D(b.m,"encrypted",function(d){return Ng(b,d)});E(c)})};
223
- function Rg(a){var b,c,d,e,f;return K(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=df([a.g.serverCertificateUri],a.h.retryParameters);sa(g,3);c=a.C.Ob.request(5,b);return C(g,c.promise,5);case 5:d=g.h;a.g.serverCertificate=mb(d.data);va(g,4);break;case 3:throw e=wa(g),new O(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();
223
+ function Rg(a){var b,c,d,e,f;return K(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=df([a.g.serverCertificateUri],a.h.retryParameters);sa(g,3);c=a.C.Nb.request(5,b);return C(g,c.promise,5);case 5:d=g.h;a.g.serverCertificate=mb(d.data);va(g,4);break;case 3:throw e=wa(g),new O(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();
224
224
  sa(g,6);return C(g,a.s.setServerCertificate(a.g.serverCertificate),8);case 8:va(g,0);break;case 6:throw f=wa(g),new O(2,6,6004,f.message);}})}function Sg(a,b){var c,d,e;return K(function(f){if(1==f.g)return C(f,Tg(a,b,{initData:null,initDataType:null}),2);if(3!=f.g){c=f.h;if(!c)return f.return();d=[];if(e=a.i.get(c))e.ab=new Le,d.push(e.ab);d.push(c.remove());return C(f,Promise.all(d),3)}a.i.delete(c);E(f)})}
225
225
  function Qg(a){var b,c,d,e,f;return K(function(g){if(1==g.g){if(!a.u.size)return g.B(2);a.u.forEach(function(h,k){Tg(a,k,h)});return C(g,a.l,3)}if(2!=g.g){b=a.g&&a.g.keyIds||new Set([]);if(0<b.size&&Ug(a))return g.return(a.l);a.l=new Le;a.l.catch(function(){})}c=(a.g?a.g.initData:[])||[];d=t(c);for(e=d.next();!e.done;e=d.next())f=e.value,Og(a,f.initDataType,f.initData);c.length||a.l.resolve();return g.return(a.l)})}
226
226
  function Og(a,b,c){if(c.length){var d=a.i.values();d=t(d);for(var e=d.next();!e.done;e=d.next())if(kb(c,e.value.initData)&&a.h.ignoreDuplicateInitData)return;0<a.i.size&&Vg(a)&&(a.l.resolve(),a.l=new Le,a.l.catch(function(){}));Wg(a,b,c,a.g.sessionType)}}function Xg(a){return a?!!a.match(/^com\.(microsoft|chromecast)\.playready/):!1}function Yg(a){a=a.i.keys();a=tf(a,function(b){return b.sessionId});return Array.from(a)}
227
227
  q.ve=function(){var a=this,b=this.i.keys();b=tf(b,function(c){var d=a.i.get(c);return{sessionId:c.sessionId,sessionType:d.type,initData:d.initData,initDataType:d.initDataType}});return Array.from(b)};q.Kc=function(){var a=Infinity,b=this.i.keys();b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,isNaN(c.expiration)||(a=Math.min(a,c.expiration));return a};q.ud=function(){return xf(this.ia)};
228
- function Hg(a,b,c){var d,e,f,g,h,k,l,m,n,r,p,u,v,x,z;return K(function(y){switch(y.g){case 1:d=new Map;if(c.length){e=Zg(a,c,d);y.B(2);break}return C(y,$g(a,b),3);case 3:e=y.h;case 2:f=e;if(!f)throw new O(2,6,6001);nf(a.j);sa(y,4);a.G.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.G.add(n.contentType.toLowerCase());r=t(k);for(m=r.next();!m.done;m=r.next())p=m.value,a.G.add(p.contentType.toLowerCase());if(c.length){var B=
229
- f.keySystem;var A=d.get(f.keySystem);var D=[],F=[],J=[],G=[],H=new Set;ah(A,D,J,F,G,H);var I=a.K?"persistent-license":"temporary";B={keySystem:B,licenseServerUri:D[0],distinctiveIdentifierRequired:A[0].distinctiveIdentifierRequired,persistentStateRequired:A[0].persistentStateRequired,sessionType:A[0].sessionType||I,audioRobustness:A[0].audioRobustness||"",videoRobustness:A[0].videoRobustness||"",serverCertificate:J[0],serverCertificateUri:F[0],initData:G,keyIds:H};A=t(A);for(D=A.next();!D.done;D=
230
- A.next())D=D.value,D.distinctiveIdentifierRequired&&(B.distinctiveIdentifierRequired=D.distinctiveIdentifierRequired),D.persistentStateRequired&&(B.persistentStateRequired=D.persistentStateRequired);A=B}else A=f.keySystem,B=b.get(f.keySystem),D=[],F=[],J=[],G=[],H=new Set,ah(B.drmInfos,D,J,F,G,H),A={keySystem:A,licenseServerUri:D[0],distinctiveIdentifierRequired:"required"==B.distinctiveIdentifier,persistentStateRequired:"required"==B.persistentState,sessionType:B.sessionTypes[0]||"temporary",audioRobustness:(B.audioCapabilities?
231
- B.audioCapabilities[0].robustness:"")||"",videoRobustness:(B.videoCapabilities?B.videoCapabilities[0].robustness:"")||"",serverCertificate:J[0],serverCertificateUri:F[0],initData:G,keyIds:H};a.g=A;if(!a.g.licenseServerUri)throw new O(2,6,6012,a.g.keySystem);return C(y,f.createMediaKeys(),6);case 6:u=y.h;nf(a.j);a.s=u;if(!(""!=a.h.minHdcpVersion&&"getStatusForPolicy"in a.s)){y.B(7);break}sa(y,8);return C(y,a.s.getStatusForPolicy({minHdcpVersion:a.h.minHdcpVersion}),10);case 10:v=y.h;if("usable"!=v)throw new O(2,
228
+ function Hg(a,b,c){var d,e,f,g,h,k,l,m,n,r,p,u,v,x,z;return K(function(y){switch(y.g){case 1:d=new Map;if(c.length){e=Zg(a,c,d);y.B(2);break}return C(y,$g(a,b),3);case 3:e=y.h;case 2:f=e;if(!f)throw new O(2,6,6001);nf(a.j);sa(y,4);a.G.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.G.add(n.contentType.toLowerCase());r=t(k);for(m=r.next();!m.done;m=r.next())p=m.value,a.G.add(p.contentType.toLowerCase());if(c.length){var A=
229
+ f.keySystem;var B=d.get(f.keySystem);var D=[],F=[],J=[],G=[],H=new Set;ah(B,D,J,F,G,H);var I=a.K?"persistent-license":"temporary";A={keySystem:A,licenseServerUri:D[0],distinctiveIdentifierRequired:B[0].distinctiveIdentifierRequired,persistentStateRequired:B[0].persistentStateRequired,sessionType:B[0].sessionType||I,audioRobustness:B[0].audioRobustness||"",videoRobustness:B[0].videoRobustness||"",serverCertificate:J[0],serverCertificateUri:F[0],initData:G,keyIds:H};B=t(B);for(D=B.next();!D.done;D=
230
+ B.next())D=D.value,D.distinctiveIdentifierRequired&&(A.distinctiveIdentifierRequired=D.distinctiveIdentifierRequired),D.persistentStateRequired&&(A.persistentStateRequired=D.persistentStateRequired);B=A}else B=f.keySystem,A=b.get(f.keySystem),D=[],F=[],J=[],G=[],H=new Set,ah(A.drmInfos,D,J,F,G,H),B={keySystem:B,licenseServerUri:D[0],distinctiveIdentifierRequired:"required"==A.distinctiveIdentifier,persistentStateRequired:"required"==A.persistentState,sessionType:A.sessionTypes[0]||"temporary",audioRobustness:(A.audioCapabilities?
231
+ A.audioCapabilities[0].robustness:"")||"",videoRobustness:(A.videoCapabilities?A.videoCapabilities[0].robustness:"")||"",serverCertificate:J[0],serverCertificateUri:F[0],initData:G,keyIds:H};a.g=B;if(!a.g.licenseServerUri)throw new O(2,6,6012,a.g.keySystem);return C(y,f.createMediaKeys(),6);case 6:u=y.h;nf(a.j);a.s=u;if(!(""!=a.h.minHdcpVersion&&"getStatusForPolicy"in a.s)){y.B(7);break}sa(y,8);return C(y,a.s.getStatusForPolicy({minHdcpVersion:a.h.minHdcpVersion}),10);case 10:v=y.h;if("usable"!=v)throw new O(2,
232
232
  6,6018);nf(a.j);va(y,7,4);break;case 8:x=wa(y,4);if(x instanceof O)throw x;throw new O(2,6,6019,x.message);case 7:return a.da=!0,C(y,Rg(a),11);case 11:nf(a.j);va(y,0);break;case 4:z=wa(y);nf(a.j,z);a.g=null;a.G.clear();if(z instanceof O)throw z;throw new O(2,6,6002,z.message);}})}
233
233
  function Zg(a,b,c){for(var d=t(b),e=d.next();!e.done;e=d.next()){var f=t(Kg(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 O(2,6,6E3);d={};a=t(a.h.preferredKeySystems);for(e=a.next();!e.done;d={Td:d.Td},e=a.next())for(d.Td=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==
234
234
  l.Td}}(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}
@@ -241,7 +241,7 @@ d.load(b),4);case 4:return g=m.h,nf(a.j),g||(a.i.delete(d),h=a.h.persistentSessi
241
241
  function Wg(a,b,c,d){try{var e=a.s.createSession(d)}catch(f){a.o(new O(2,6,6005,f.message));return}a.A.D(e,"message",function(f){a.m&&a.h.delayLicenseRequestUntilPlayed&&a.m.paused&&!a.N?a.J.push(f):Pg(a,f)});a.A.D(e,"keystatuseschange",function(f){return eh(a,f)});a.i.set(e,{initData:c,initDataType:b,loaded:!1,Re:Infinity,ab:null,type:d});try{c=a.h.initDataTransform(c,b,a.g)}catch(f){b=f;f instanceof O||(b=new O(2,6,6016,f));a.o(b);return}a.h.logLicenseExchange&&Wf(c);e.generateRequest(b,c).catch(function(f){if(!a.j.g){a.i.delete(e);
242
242
  var g=f.errorCode;if(g&&g.systemCode){var h=g.systemCode;0>h&&(h+=Math.pow(2,32));h="0x"+h.toString(16)}a.o(new O(2,6,6006,f.message,f,h))}})}
243
243
  function Pg(a,b){var c,d,e,f,g,h,k,l,m,n,r,p,u;K(function(v){switch(v.g){case 1:c=b.target;a.h.logLicenseExchange&&Wf(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=df([e],a.h.retryParameters);g.body=b.message;g.method="POST";g.licenseRequestType=b.messageType;g.sessionId=c.sessionId;g.drmInfo=a.g;d&&(g.initData=d.initData,g.initDataType=d.initDataType);if(Xg(a.g.keySystem)){var x=
244
- Bf(g.body,!0,!0);if(x.includes("PlayReadyKeyMessage")){x=vg(x,"PlayReadyKeyMessage");for(var z=t(x.getElementsByTagName("HttpHeader")),y=z.next();!y.done;y=z.next())y=y.value,g.headers[y.getElementsByTagName("name")[0].textContent]=y.getElementsByTagName("value")[0].textContent;g.body=Xf(x.getElementsByTagName("Challenge")[0].textContent)}else g.headers["Content-Type"]="text/xml; charset=utf-8"}h=Date.now();sa(v,2);l=a.C.Ob.request(2,g);return C(v,l.promise,4);case 4:k=v.h;va(v,3);break;case 2:return m=
244
+ Bf(g.body,!0,!0);if(x.includes("PlayReadyKeyMessage")){x=vg(x,"PlayReadyKeyMessage");for(var z=t(x.getElementsByTagName("HttpHeader")),y=z.next();!y.done;y=z.next())y=y.value,g.headers[y.getElementsByTagName("name")[0].textContent]=y.getElementsByTagName("value")[0].textContent;g.body=Xf(x.getElementsByTagName("Challenge")[0].textContent)}else g.headers["Content-Type"]="text/xml; charset=utf-8"}h=Date.now();sa(v,2);l=a.C.Nb.request(2,g);return C(v,l.promise,4);case 4:k=v.h;va(v,3);break;case 2:return m=
245
245
  wa(v),n=new O(2,6,6007,m),a.o(n),d&&d.ab&&d.ab.reject(n),v.return();case 3:if(a.j.g)return v.return();a.H+=(Date.now()-h)/1E3;a.h.logLicenseExchange&&Wf(k.data);sa(v,5);return C(v,c.update(k.data),7);case 7:va(v,6);break;case 5:return r=wa(v),p=new O(2,6,6008,r.message),a.o(p),d&&d.ab&&d.ab.reject(p),v.return();case 6:if(a.j.g)return v.return();u=new Q("drmsessionupdate");a.C.onEvent(u);d&&(d.ab&&d.ab.resolve(),ch(a,d));E(v)}})}
246
246
  function eh(a,b){b=b.target;var c=a.i.get(b),d=!1;b.keyStatuses.forEach(function(f,g){if("string"==typeof g){var h=g;g=f;f=h}if(Xg(a.g.keySystem)&&16==g.byteLength&&(md()||ud())){h=qb(g);var k=h.getUint32(0,!0),l=h.getUint16(4,!0),m=h.getUint16(6,!0);h.setUint32(0,k,!1);h.setUint16(4,l,!1);h.setUint16(6,m,!1)}"status-pending"!=f&&(c.loaded=!0);"expired"==f&&(d=!0);g=Zf(g).slice(0,32);a.V.set(g,f)});var e=b.expiration-Date.now();(0>e||d&&1E3>e)&&c&&!c.ab&&(a.i.delete(b),b.close().catch(function(){}));
247
247
  Vg(a)&&(a.l.resolve(),a.W.U(fh))}function zg(a){var b=a.V,c=a.ia;c.clear();b.forEach(function(d,e){return c.set(e,d)});b=Array.from(c.values());b.length&&b.every(function(d){return"expired"==d})&&a.o(new O(2,6,6014));a.C.Kd(xf(c))}
@@ -261,10 +261,10 @@ function(l){g.push({box:l,yb:1701733217})}).O("ac-4",function(l){g.push({box:l,y
261
261
  function rh(a,b,c,d,e){var f=sh.value(),g=a.subarray(c.start,c.start+c.size),h=qb(g),k=new Uint8Array(c.size+f.byteLength);k.set(g,0);g=qb(k);g.setUint32(4,e);k.set(f,c.size);e=h.getUint32(4);g.setUint32(c.size+16,e);th(k,0,k.byteLength);e=new Uint8Array(a.byteLength+k.byteLength);c=nd()?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,th(e,d.start,d.size+k.byteLength);k=qb(e,b.start);b=Qf(b);a=k.getUint32(b);
262
262
  k.setUint32(b,a+1);return e}function th(a,b,c){a=qb(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 sh=new vf(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 uh(a,b,c,d,e,f,g){this.Y=a;this.La=b;this.sa=c;this.Ne=void 0===d?null:d;this.timescale=void 0===e?null:e;this.g=void 0===f?null:f;this.aes128Key=void 0===g?null:g}uh.prototype.Mc=function(){return this.La};uh.prototype.Jc=function(){return this.sa};function vh(a,b){return a&&b?a.Mc()==b.Mc()&&a.Jc()==b.Jc()&&Ab(a.Y().sort(),b.Y().sort())&&kb(a.g,b.g):a==b}N("shaka.media.InitSegmentReference",uh);uh.prototype.getEndByte=uh.prototype.Jc;uh.prototype.getStartByte=uh.prototype.Mc;
263
263
  function S(a,b,c,d,e,f,g,h,k,l,m,n,r,p,u,v){l=void 0===l?[]:l;p=void 0===p?wh:p;this.startTime=a;this.j=this.endTime=b;this.H=c;this.La=d;this.sa=e;this.g=f;this.timestampOffset=g;this.appendWindowStart=h;this.appendWindowEnd=k;this.h=l;this.tilesLayout=void 0===m?"":m;this.G=void 0===n?null:n;this.i=void 0===r?null:r;this.status=p;this.o=!1;this.m=!0;this.s=!1;this.aes128Key=void 0===u?null:u;this.F=null;this.l=0;this.u=void 0===v?!1:v;this.A=this.C=!1;a=t(this.h);for(b=a.next();!b.done;b=a.next())b.value.Of();
264
- this.u&&this.h.length&&this.h[this.h.length-1].Nf()}q=S.prototype;q.Y=function(){return this.H()};q.getStartTime=function(){return this.startTime};q.Hg=function(){return this.endTime};q.Mc=function(){return this.La};q.Jc=function(){return this.sa};q.Wg=function(){return this.tilesLayout};q.Vg=function(){return this.G};q.Kb=function(){return this.status};q.lh=function(){this.status=xh};q.Me=function(){this.o=!0};q.ih=function(){return this.o};q.Ed=function(){this.m=!1};q.fh=function(){return this.m};
264
+ this.u&&this.h.length&&this.h[this.h.length-1].Nf()}q=S.prototype;q.Y=function(){return this.H()};q.getStartTime=function(){return this.startTime};q.Hg=function(){return this.endTime};q.Mc=function(){return this.La};q.Jc=function(){return this.sa};q.Wg=function(){return this.tilesLayout};q.Vg=function(){return this.G};q.Jb=function(){return this.status};q.lh=function(){this.status=xh};q.Me=function(){this.o=!0};q.ih=function(){return this.o};q.Ed=function(){this.m=!1};q.fh=function(){return this.m};
265
265
  q.Of=function(){this.C=!0};q.hh=function(){return this.C};q.Nf=function(){this.A=!0};q.gh=function(){return this.A};q.Mf=function(){this.s=!0};q.bh=function(){return this.s};q.dg=function(a){this.F=a};q.Ug=function(){return this.F};q.offset=function(a){this.startTime+=a;this.endTime+=a;this.j+=a;for(var b=t(this.h),c=b.next();!c.done;c=b.next())c=c.value,c.startTime+=a,c.endTime+=a,c.j+=a};
266
266
  q.ff=function(a){null==this.i?Ra("Sync attempted without sync time!"):(a=this.i-a-this.startTime,.001<=Math.abs(a)&&this.offset(a))};N("shaka.media.SegmentReference",S);S.prototype.syncAgainst=S.prototype.ff;S.prototype.offset=S.prototype.offset;S.prototype.getThumbnailSprite=S.prototype.Ug;S.prototype.setThumbnailSprite=S.prototype.dg;S.prototype.hasByterangeOptimization=S.prototype.bh;S.prototype.markAsByterangeOptimization=S.prototype.Mf;S.prototype.isLastPartial=S.prototype.gh;
267
- S.prototype.markAsLastPartial=S.prototype.Nf;S.prototype.isPartial=S.prototype.hh;S.prototype.markAsPartial=S.prototype.Of;S.prototype.isIndependent=S.prototype.fh;S.prototype.markAsNonIndependent=S.prototype.Ed;S.prototype.isPreload=S.prototype.ih;S.prototype.markAsPreload=S.prototype.Me;S.prototype.markAsUnavailable=S.prototype.lh;S.prototype.getStatus=S.prototype.Kb;S.prototype.getTileDuration=S.prototype.Vg;S.prototype.getTilesLayout=S.prototype.Wg;S.prototype.getEndByte=S.prototype.Jc;
267
+ S.prototype.markAsLastPartial=S.prototype.Nf;S.prototype.isPartial=S.prototype.hh;S.prototype.markAsPartial=S.prototype.Of;S.prototype.isIndependent=S.prototype.fh;S.prototype.markAsNonIndependent=S.prototype.Ed;S.prototype.isPreload=S.prototype.ih;S.prototype.markAsPreload=S.prototype.Me;S.prototype.markAsUnavailable=S.prototype.lh;S.prototype.getStatus=S.prototype.Jb;S.prototype.getTileDuration=S.prototype.Vg;S.prototype.getTilesLayout=S.prototype.Wg;S.prototype.getEndByte=S.prototype.Jc;
268
268
  S.prototype.getStartByte=S.prototype.Mc;S.prototype.getEndTime=S.prototype.Hg;S.prototype.getStartTime=S.prototype.getStartTime;S.prototype.getUris=S.prototype.Y;var wh=0,xh=1;S.Status={Qh:wh,Fi:xh,ii:2};function yh(a){return!a||1==a.length&&1E-6>a.end(0)-a.start(0)?null:a.length?a.end(a.length-1):null}function zh(a,b){return!a||!a.length||1==a.length&&1E-6>a.end(0)-a.start(0)||b>a.end(a.length-1)?!1:b>=a.start(0)}function Ah(a,b){if(!a||!a.length||1==a.length&&1E-6>a.end(0)-a.start(0))return 0;var c=0;a=t(Bh(a));for(var d=a.next();!d.done;d=a.next()){var e=d.value;d=e.start;e=e.end;e>b&&(c+=e-Math.max(d,b))}return c}
269
269
  function Ch(a,b,c){if(!a||!a.length||1==a.length&&1E-6>a.end(0)-a.start(0))return null;a=Bh(a).findIndex(function(d,e,f){return d.start>b&&(0==e||f[e-1].end-b<=c)});return 0<=a?a:null}function Bh(a){if(!a)return[];for(var b=[],c=0;c<a.length;c++)b.push({start:a.start(c),end:a.end(c)});return b};/*
270
270
  @license
@@ -307,16 +307,16 @@ function ei(a){if(1!==(a[0]<<16|a[1]<<8|a[2]))return null;var b={data:new Uint8A
307
307
  q.rh=function(a){le("TsParser","Please use parseNalus function instead.");return this.Ue(a)};
308
308
  q.Ue=function(a,b){var c=a.pts?a.pts/9E4:null;a=a.data;var d=a.byteLength,e=1;"hvc"==this.m&&(e=2);for(var f=0,g=[],h=-1,k=0,l,m=0;m<d;++m){var n=a[m];if(n){if(2<=f&&1==n){b&&!g.length&&-1==h&&(n=m-(3<f?3:f),0!=n&&(n=a.subarray(0,n),b.data=$f(b.data,n),b.ba=$f(b.ba,n)));0<=h?(f=m-((3<f?3:f)+1),g.push({data:a.subarray(h+e,f+1),ba:a.subarray(h,f+1),type:k,time:c})):b&&!g.length&&(h=m-f,0<h&&(h=a.subarray(0,h),b.data=$f(b.data,h),b.ba=$f(b.ba,h)));if(m>=d-e)return g;m++;h=m;k="hvc"==this.m?a[m]>>1&63:
309
309
  a[m]&31}f=0}else f++;m>=d-1&&0<=h&&0<=f&&(l={data:a.subarray(h+e,d),ba:a.subarray(h,d),type:k,time:c})}l&&g.push(l);!g.length&&b&&(b.data=$f(b.data,a),b.ba=$f(b.ba,a));return g};q.getMetadata=function(){for(var a=[],b=t(this.l),c=b.next();!c.done;c=b.next())(c=ei(c.value))&&a.push({cueTime:c.pts?c.pts/9E4:null,data:c.data,frames:Ih(c.data),dts:c.dts,pts:c.pts});return a};
310
- q.Gb=function(){if(this.i.length&&!this.h.length){for(var a=!1,b=t(this.i),c=b.next();!c.done;c=b.next()){c=c.value;var d=ei(c);d&&null!=d.pts&&null!=d.dts?(this.h.length&&d.dts<(this.h[this.h.length-1].dts||0)&&(a=!0),this.h.push(d)):this.h.length&&(c=d?d.data:c)&&(d=this.h.pop(),d.data=$f(d.data,c),this.h.push(d))}a&&(this.h=this.h.sort(function(e,f){var g=(e.pts||0)-(f.pts||0);return(e.dts||0)-(f.dts||0)||g}))}return this.h};
311
- q.ac=function(a){a=void 0===a?!0:a;if(this.j.length&&!this.g.length){for(var b=!1,c=t(this.j),d=c.next();!d.done;d=c.next()){d=d.value;var e=ei(d);e&&null!=e.pts&&null!=e.dts?(this.g.length&&e.dts<(this.g[this.g.length-1].dts||0)&&(b=!0),this.g.push(e)):this.g.length&&(d=e?e.data:d)&&(e=this.g.pop(),e.data=$f(e.data,d),this.g.push(e))}if(a){var f;c=t(this.g);for(d=c.next();!d.done;d=c.next())d=d.value,d.xb=this.Ue(d,f),d.xb.length&&(f=d.xb[d.xb.length-1]);this.g=this.g.filter(function(g){return g.xb.length})}b&&
312
- (this.g=this.g.sort(function(g,h){var k=(g.pts||0)-(h.pts||0);return(g.dts||0)-(h.dts||0)||k}))}return a?this.g:(a=this.g,this.g=[],a)};q.getStartTime=function(a){if("audio"==a){a=null;var b=this.Gb();b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4);return a}return"video"==a?(a=null,b=this.ac(!1),b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4),a):null};q.Hc=function(){return{audio:this.o,video:this.m}};
310
+ q.Fb=function(){if(this.i.length&&!this.h.length){for(var a=!1,b=t(this.i),c=b.next();!c.done;c=b.next()){var d=c.value,e=ei(d);c=this.h.length?this.h[this.h.length-1]:null;e&&null!=e.pts&&null!=e.dts&&(!c||c.pts!=e.pts&&c.dts!=e.dts)?(this.h.length&&e.dts<(c.dts||0)&&(a=!0),this.h.push(e)):this.h.length&&(d=e?e.data:d)&&(c=this.h.pop(),c.data=$f(c.data,d),this.h.push(c))}a&&(this.h=this.h.sort(function(f,g){var h=(f.pts||0)-(g.pts||0);return(f.dts||0)-(g.dts||0)||h}))}return this.h};
311
+ q.ac=function(a){a=void 0===a?!0:a;if(this.j.length&&!this.g.length){for(var b=!1,c=t(this.j),d=c.next();!d.done;d=c.next()){var e=d.value,f=ei(e);d=this.g.length?this.g[this.g.length-1]:null;f&&null!=f.pts&&null!=f.dts&&(!d||d.pts!=f.pts&&d.dts!=f.dts)?(this.g.length&&f.dts<(d.dts||0)&&(b=!0),this.g.push(f)):this.g.length&&(e=f?f.data:e)&&(d=this.g.pop(),d.data=$f(d.data,e),this.g.push(d))}if(a){var g;c=t(this.g);for(d=c.next();!d.done;d=c.next())d=d.value,d.xb=this.Ue(d,g),d.xb.length&&(g=d.xb[d.xb.length-
312
+ 1]);this.g=this.g.filter(function(h){return h.xb.length})}b&&(this.g=this.g.sort(function(h,k){var l=(h.pts||0)-(k.pts||0);return(h.dts||0)-(k.dts||0)||l}))}return a?this.g:(a=this.g,this.g=[],a)};q.getStartTime=function(a){if("audio"==a){a=null;var b=this.Fb();b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4);return a}return"video"==a?(a=null,b=this.ac(!1),b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4),a):null};q.Hc=function(){return{audio:this.o,video:this.m}};
313
313
  q.yd=function(){for(var a=[],b=t(this.ac()),c=b.next();!c.done;c=b.next())a.push.apply(a,w(c.value.xb));return a};q.Zg=function(){le("TsParser","Please use getVideoInfo function instead.");var a=this.ze();return{height:a.height,width:a.width}};q.ze=function(){return"hvc"==this.m?fi(this):gi(this)};
314
314
  function gi(a){var b={height:null,width:null,fa:null};a=a.yd();if(!a.length)return b;a=a.find(function(r){return 7==r.type});if(!a)return b;a=new Th(a.data);var c=$h(a),d=$h(a),e=$h(a);Yh(a);if(hi.includes(c)){var f=T(a);3===f&&Vh(a,1);Yh(a);Yh(a);Vh(a,1);if(U(a)){f=3!==f?8:12;for(var g=0;g<f;g++)U(a)&&(6>g?ai(a,16):ai(a,64))}}Yh(a);f=T(a);if(0===f)T(a);else if(1===f)for(Vh(a,1),Yh(a),Yh(a),f=T(a),g=0;g<f;g++)Yh(a);Yh(a);Vh(a,1);f=T(a);g=T(a);var h=Wh(a,1);0===h&&Vh(a,1);Vh(a,1);var k=0,l=0,m=0,n=
315
315
  0;U(a)&&(k=T(a),l=T(a),m=T(a),n=T(a));b.height=String((2-h)*(g+1)*16-2*m-2*n);b.width=String(16*(f+1)-2*k-2*l);b.fa="avc1."+("0"+c.toString(16).toUpperCase()).slice(-2)+("0"+d.toString(16).toUpperCase()).slice(-2)+("0"+e.toString(16).toUpperCase()).slice(-2);return b}
316
- function fi(a){var b={height:null,width:null,fa:null};a=a.yd();if(!a.length)return b;a=a.find(function(A){return 33==A.type});if(!a)return b;var c=new Th(a.ba,!0);$h(c);$h(c);Wh(c,4);var d=Wh(c,3);U(c);var e=Wh(c,2),f=Wh(c,1),g=Wh(c,5),h=Wh(c,32);a=$h(c);for(var k=$h(c),l=$h(c),m=$h(c),n=$h(c),r=$h(c),p=$h(c),u=[],v=[],x=0;x<d;x++)u.push(U(c)),v.push(U(c));if(0<d)for(x=d;8>x;x++)Wh(c,2);for(x=0;x<d;x++)u[x]&&Wh(c,88),v[x]&&$h(c);T(c);d=T(c);3==d&&Wh(c,1);u=T(c);v=T(c);var z=x=0,y=0,B=0;U(c)&&(x+=
317
- T(c),z+=T(c),y+=T(c),B+=T(c));b.width=String(u-(x+z)*(1===d||2===d?2:1));b.height=String(v-(y+B)*(1===d?2:1));c=function(A){for(var D=0,F=0;32>F;F++)D|=(A>>F&1)<<31-F;return D>>>0}(h);f=1==f?"H":"L";e="hvc1"+("."+["","A","B","C"][e]+g);e+="."+c.toString(16).toUpperCase();e+="."+f+p;r&&(e+="."+r.toString(16).toUpperCase());n&&(e+="."+n.toString(16).toUpperCase());m&&(e+="."+m.toString(16).toUpperCase());l&&(e+="."+l.toString(16).toUpperCase());k&&(e+="."+k.toString(16).toUpperCase());a&&(e+="."+a.toString(16).toUpperCase());
316
+ function fi(a){var b={height:null,width:null,fa:null};a=a.yd();if(!a.length)return b;a=a.find(function(B){return 33==B.type});if(!a)return b;var c=new Th(a.ba,!0);$h(c);$h(c);Wh(c,4);var d=Wh(c,3);U(c);var e=Wh(c,2),f=Wh(c,1),g=Wh(c,5),h=Wh(c,32);a=$h(c);for(var k=$h(c),l=$h(c),m=$h(c),n=$h(c),r=$h(c),p=$h(c),u=[],v=[],x=0;x<d;x++)u.push(U(c)),v.push(U(c));if(0<d)for(x=d;8>x;x++)Wh(c,2);for(x=0;x<d;x++)u[x]&&Wh(c,88),v[x]&&$h(c);T(c);d=T(c);3==d&&Wh(c,1);u=T(c);v=T(c);var z=x=0,y=0,A=0;U(c)&&(x+=
317
+ T(c),z+=T(c),y+=T(c),A+=T(c));b.width=String(u-(x+z)*(1===d||2===d?2:1));b.height=String(v-(y+A)*(1===d?2:1));c=function(B){for(var D=0,F=0;32>F;F++)D|=(B>>F&1)<<31-F;return D>>>0}(h);f=1==f?"H":"L";e="hvc1"+("."+["","A","B","C"][e]+g);e+="."+c.toString(16).toUpperCase();e+="."+f+p;r&&(e+="."+r.toString(16).toUpperCase());n&&(e+="."+n.toString(16).toUpperCase());m&&(e+="."+m.toString(16).toUpperCase());l&&(e+="."+l.toString(16).toUpperCase());k&&(e+="."+k.toString(16).toUpperCase());a&&(e+="."+a.toString(16).toUpperCase());
318
318
  b.fa=e;return b}function ii(a){return 0>di(a)?!1:!0}function di(a){for(var b=Math.min(1E3,a.length-564),c=0;c<b;){if(71==a[c]&&71==a[c+188]&&71==a[c+376])return c;c++}return-1}N("shaka.util.TsParser",ci);ci.syncOffset=di;ci.probe=ii;ci.prototype.getVideoInfo=ci.prototype.ze;ci.prototype.getVideoResolution=ci.prototype.Zg;ci.prototype.getVideoNalus=ci.prototype.yd;ci.prototype.getCodecs=ci.prototype.Hc;ci.prototype.getStartTime=ci.prototype.getStartTime;ci.prototype.getVideoData=ci.prototype.ac;
319
- ci.prototype.getAudioData=ci.prototype.Gb;ci.prototype.getMetadata=ci.prototype.getMetadata;ci.prototype.parseNalus=ci.prototype.Ue;ci.prototype.parseAvcNalus=ci.prototype.rh;ci.prototype.parse=ci.prototype.parse;ci.prototype.clearData=ci.prototype.clearData;ci.Timescale=9E4;var hi=[100,110,122,244,44,83,86,118,128,138,139,134];function ji(a,b,c){this.g=null;this.o=-1;this.l=a;this.i=b;this.m=c;this.j=!1;a:{"undefined"===typeof libDPIModule&&Ta("Could not find LCEVC Library dependencies on this page");if("undefined"!==typeof LCEVCdec)this.h=LCEVCdec;else if("undefined"!==typeof LcevcDil)this.h=LcevcDil,this.j=!0,le("LcevcDil","lcevc_dil.js is deprecated, please use lcevc_dec.js instead");else{Ta("Could not find LCEVC Library on this page");a=!1;break a}"undefined"===typeof this.h.SupportObject?(Ta("Could not find LCEVC Library on this page"),
319
+ ci.prototype.getAudioData=ci.prototype.Fb;ci.prototype.getMetadata=ci.prototype.getMetadata;ci.prototype.parseNalus=ci.prototype.Ue;ci.prototype.parseAvcNalus=ci.prototype.rh;ci.prototype.parse=ci.prototype.parse;ci.prototype.clearData=ci.prototype.clearData;ci.Timescale=9E4;var hi=[100,110,122,244,44,83,86,118,128,138,139,134];function ji(a,b,c){this.g=null;this.o=-1;this.l=a;this.i=b;this.m=c;this.j=!1;a:{"undefined"===typeof libDPIModule&&Ta("Could not find LCEVC Library dependencies on this page");if("undefined"!==typeof LCEVCdec)this.h=LCEVCdec;else if("undefined"!==typeof LcevcDil)this.h=LcevcDil,this.j=!0,le("LcevcDil","lcevc_dil.js is deprecated, please use lcevc_dec.js instead");else{Ta("Could not find LCEVC Library on this page");a=!1;break a}"undefined"===typeof this.h.SupportObject?(Ta("Could not find LCEVC Library on this page"),
320
320
  a=!1):(this.h.SupportObject.SupportStatus||Ta(this.h.SupportObject.SupportError),a="undefined"!==typeof this.h&&"undefined"!==typeof libDPIModule&&this.i instanceof HTMLCanvasElement&&this.h.SupportObject.SupportStatus)}a&&!this.g&&this.h.SupportObject.webGLSupport(this.i)&&(this.i.classList.remove("shaka-hidden"),this.g=this.j?new this.h.LcevcDil(this.l,this.i,this.m):new this.h.LCEVCdec(this.l,this.i,this.m))}function ki(a){a.g&&a.i.classList.add("shaka-hidden")}
321
321
  ji.prototype.release=function(){this.g&&(this.g.close(),this.g=null)};function li(a,b,c){var d=mi,e=ni;switch(b.mimeType){case "video/webm":d=oi;break;case "video/mp4":d=pi}switch(c){case "DASH":e=qi;break;case "HLS":e=ri}a.g&&(a.o=b.id,a.g.setLevelSwitching(b.id,!0),a.g.setContainerFormat(d),a.j||a.g.setStreamingFormat(e))}N("shaka.lcevc.Dec",ji);ji.prototype.release=ji.prototype.release;var mi=0,oi=1,pi=2,ri=0,qi=1,ni=-1;function si(a,b,c,d){var e=this;this.i=a;this.C=null;this.F=b;this.g={};this.G={};this.la={};this.h=null;this.W=!1;this.va=c||function(){};this.N=d||null;this.j={};this.s=new of;this.m={};this.H=null;this.J=new Le;this.K="";this.$=!1;this.l=ti(this,this.J);this.A=!1;this.I=new mf(function(){return ui(e)});this.u=!1;this.V="UNKNOWN";this.ia=this.ma=!1;this.Ba=new Le;this.o=!1;this.da=!0}
322
322
  function ti(a,b){if(window.ManagedMediaSource){a.i.disableRemotePlayback=!0;var c=new ManagedMediaSource;a.s.ha(c,"sourceopen",function(){URL.revokeObjectURL(a.K);b.resolve()});a.s.D(c,"startstreaming",function(){a.da=!0});a.s.D(c,"endstreaming",function(){a.da=!1});a.s.ha(a.i,"playing",function(){a.$=!0});a.K=vi(c);a.i.src=a.K;return c}c=new MediaSource;a.s.ha(c,"sourceopen",function(){URL.revokeObjectURL(a.K);b.resolve()});a.s.ha(a.i,"playing",function(){a.$=!0});a.K=vi(c);a.i.src=a.K;return c}
@@ -330,9 +330,9 @@ function Bi(a,b){a.A||!Object.keys(a.g).length?a=null:b==Bc?a=a.h.g:(a=Ci(a,b),a
330
330
  q.gb=function(){var a={total:this.A?[]:Bh(this.i.buffered),audio:this.A?[]:Bh(Ci(this,"audio")),video:this.A?[]:Bh(Ci(this,"video")),text:[]};if(this.h){var b=this.h.g,c=this.h.h;null!=b&&null!=c&&a.text.push({start:b,end:c})}return a};function Ci(a,b){try{return a.g[b].buffered}catch(c){return null}}
331
331
  function Fi(a,b,c,d,e,f){var g=null,h=mb(c);if(Fc.includes(e))f=Ih(h),f.length&&d&&((b=f.find(function(n){return"com.apple.streaming.transportStreamTimestamp"===n.description}))&&b.data&&(g=Math.round(b.data)/1E3),a.va([{cueTime:d.startTime,data:h,frames:f,dts:d.startTime,pts:d.startTime}],0,d.endTime));else if(e.includes("/mp4")&&d&&0==d.timestampOffset&&d.g&&d.g.timescale){var k=d.g.timescale;if(!isNaN(k)){var l=0,m=!1;(new Kf).box("moof",Pf).box("traf",Pf).O("tfdt",function(n){l=Lh(n.reader,n.version).baseMediaDecodeTime/
332
332
  k;m=!0;n.parser.stop()}).parse(c,!0);m&&(g=l)}}else e.includes("/mp4")||e.includes("/webm")||!ii(h)||(h=(new ci).parse(h),b=h.getStartTime(b),null!=b&&(g=b),h=h.getMetadata(),h.length&&a.va(h,f,d?d.endTime:null));return g}
333
- function Gi(a,b,c,d,e,f,g,h,k,l){g=void 0===g?!1:g;h=void 0===h?!1:h;k=void 0===k?!1:k;l=void 0===l?!1:l;var m,n,r,p,u,v,x,z,y,B,A;return K(function(D){switch(D.g){case 1:m=Cc;if(b!=m.ja){D.B(2);break}if(!a.u){D.B(3);break}return C(D,a.Ba,4);case 4:n=D.h,a.h.s=n;case 3:return C(D,Pc(a.h,c,d?d.startTime:null,d?d.endTime:null,d?d.Y()[0]:null),5);case 5:return D.return();case 2:if(l||!a.o){D.B(6);break}return C(D,Gi(a,m.P,c,d,e,f,g,h,k,!0),7);case 7:return C(D,Gi(a,m.ea,c,d,e,f,g,h,k,!0),8);case 8:return D.return();
334
- case 6:if(!a.g[b])return D.return();r=a.g[b].timestampOffset;p=a.G[b];a.m[b]&&(p=a.m[b].getOriginalMimeType());d&&(u=Fi(a,b,c,d,p,r),null!=u&&(v=d.startTime-u,x=Math.abs(r-v),(.1<=x||g||h)&&(!k||0<v||!r)&&(r=v,a.ia&&(Hi(a,b,function(){return Ii(a,b)}),Hi(a,b,function(){return Ji(a,b,r)}))),z=b==m.ea||!(m.ea in a.g),a.u&&z&&a.Ba.resolve(r)));f&&b==m.ea&&(a.h||xi(a,"application/cea-608",a.u,!1),a.H||(y=p.split(";",1)[0],a.H=new sb(y)),d?(B=a.H.i(c),B.length&&Tc(a.h,B,d.startTime,d.endTime,r)):a.H.init(c));
335
- if(!a.m[b]){D.B(9);break}return C(D,a.m[b].transmux(c,e,d,a.l.duration,b),10);case 10:c=D.h;case 9:return c=Ki(a,c,d?d.startTime:null,b),d&&a.u&&b!=m.ja&&(g||h)&&(A=d.startTime,Hi(a,b,function(){return Ii(a,b)}),Hi(a,b,function(){return Ji(a,b,A)})),C(D,Hi(a,b,function(){var F=c;if("video"==b&&a.N){var J=a.N;J.g&&J.g.appendBuffer(F,"video",J.o,-r)}a.g[b].appendBuffer(F)}),11);case 11:E(D)}})}function Li(a,b){var c=Di(a,"video")||0;Rc(a.h,b,c)}function Mi(a){a.h&&Rc(a.h,"",0)}
333
+ function Gi(a,b,c,d,e,f,g,h,k,l){g=void 0===g?!1:g;h=void 0===h?!1:h;k=void 0===k?!1:k;l=void 0===l?!1:l;var m,n,r,p,u,v,x,z,y,A,B;return K(function(D){switch(D.g){case 1:m=Cc;if(b!=m.ja){D.B(2);break}if(!a.u){D.B(3);break}return C(D,a.Ba,4);case 4:n=D.h,a.h.s=n;case 3:return C(D,Pc(a.h,c,d?d.startTime:null,d?d.endTime:null,d?d.Y()[0]:null),5);case 5:return D.return();case 2:if(l||!a.o){D.B(6);break}return C(D,Gi(a,m.P,c,d,e,f,g,h,k,!0),7);case 7:return C(D,Gi(a,m.ea,c,d,e,f,g,h,k,!0),8);case 8:return D.return();
334
+ case 6:if(!a.g[b])return D.return();r=a.g[b].timestampOffset;p=a.G[b];a.m[b]&&(p=a.m[b].getOriginalMimeType());d&&(u=Fi(a,b,c,d,p,r),null!=u&&(v=d.startTime-u,x=Math.abs(r-v),(.001<=x||g||h)&&(!k||0<v||!r)&&(r=v,a.ia&&(Hi(a,b,function(){return Ii(a,b)}),Hi(a,b,function(){return Ji(a,b,r)}))),z=b==m.ea||!(m.ea in a.g),a.u&&z&&a.Ba.resolve(r)));f&&b==m.ea&&(a.h||xi(a,"application/cea-608",a.u,!1),a.H||(y=p.split(";",1)[0],a.H=new sb(y)),d?(A=a.H.i(c),A.length&&Tc(a.h,A,d.startTime,d.endTime,r)):a.H.init(c));
335
+ if(!a.m[b]){D.B(9);break}return C(D,a.m[b].transmux(c,e,d,a.l.duration,b),10);case 10:c=D.h;case 9:return c=Ki(a,c,d?d.startTime:null,b),d&&a.u&&b!=m.ja&&(g||h)&&(B=d.startTime,Hi(a,b,function(){return Ii(a,b)}),Hi(a,b,function(){return Ji(a,b,B)})),C(D,Hi(a,b,function(){var F=c;if("video"==b&&a.N){var J=a.N;J.g&&J.g.appendBuffer(F,"video",J.o,-r)}a.g[b].appendBuffer(F)}),11);case 11:E(D)}})}function Li(a,b){var c=Di(a,"video")||0;Rc(a.h,b,c)}function Mi(a){a.h&&Rc(a.h,"",0)}
336
336
  q.remove=function(a,b,c){var d=this,e;return K(function(f){return 1==f.g?(e=Cc,a==e.ja?C(f,d.h.remove(b,c),0):C(f,Hi(d,a,function(){return Ni(d,a,b,c)}),4)):d.o?C(f,Hi(d,e.P,function(){return Ni(d,e.P,b,c)}),0):f.B(0)})};function Oi(a,b){var c;return K(function(d){return 1==d.g?(c=Cc,b==c.ja?a.h?C(d,a.h.remove(0,Infinity),0):d.return():C(d,Hi(a,b,function(){return Ni(a,b,0,a.l.duration)}),4)):a.o?C(d,Hi(a,c.P,function(){return Ni(a,c.P,0,a.l.duration)}),0):d.B(0)})}
337
337
  q.flush=function(a){var b=this,c;return K(function(d){return 1==d.g?(c=Cc,a==c.ja?d.return():C(d,Hi(b,a,function(){b.i.currentTime-=.001;zi(b,a)}),2)):b.o?C(d,Hi(b,c.P,function(){var e=c.P;b.i.currentTime-=.001;zi(b,e)}),0):d.B(0)})};
338
338
  function Pi(a,b,c,d,e,f,g,h){var k,l,m;return K(function(n){if(1==n.g){k=Cc;if(b==k.ja)return f||(a.h.s=c),Qc(a.h,d,e),n.return();l=[];return C(n,Qi(a,b,g,h),2)}m=n.h;m||(l.push(Hi(a,b,function(){return Ii(a,b)})),a.o&&l.push(Hi(a,k.P,function(){return Ii(a,k.P)})));f||(l.push(Hi(a,b,function(){return Ji(a,b,c)})),a.o&&l.push(Hi(a,k.P,function(){return Ji(a,k.P,c)})));l.push(Hi(a,b,function(){a.g[b].appendWindowStart=0;a.g[b].appendWindowEnd=e;a.g[b].appendWindowStart=d;zi(a,b)}));a.o&&l.push(Hi(a,
@@ -342,16 +342,16 @@ function Ii(a,b){var c=a.g[b].appendWindowStart,d=a.g[b].appendWindowEnd;a.g[b].
342
342
  function Si(a,b){var c,d,e,f,g,h,k;return K(function(l){switch(l.g){case 1:nf(a.I);c=[];d={};for(e in a.g)d.rc=new Le,f={start:function(m){return function(){return m.rc.resolve()}}(d),p:d.rc},a.j[e].push(f),c.push(d.rc),1==a.j[e].length&&f.start(),d={rc:d.rc};sa(l,2);return C(l,Promise.all(c),4);case 4:va(l,3);break;case 2:throw g=wa(l),g;case 3:return sa(l,5,6),C(l,b(),6);case 6:xa(l);for(h in a.g)Ti(a,h);ya(l,0);break;case 5:throw k=wa(l),new O(2,3,3015,k,a.i.error||"No error in the media element");
343
343
  }})}function Ti(a,b){a.j[b].shift();Ui(a,b)}function Ui(a,b){var c=a.j[b][0];if(c)try{c.start()}catch(d){"QuotaExceededError"==d.name?c.p.reject(new O(2,3,3017,b)):c.p.reject(new O(2,3,3015,d,a.i.error||"No error in the media element")),Ti(a,b)}}function Ki(a,b,c,d){var e=a.la[d];a.C.insertFakeEncryptionInInit&&null==c&&e&&(pd()||nd()||od("SOPOpenBrowser"))&&"mp4"==a.G[d].split(";")[0].split("/")[1]&&(b=qh(b));return b}
344
344
  function Vi(a,b,c,d){return Hi(a,b,function(){b!==Bc&&(fb()&&(a.m[b]&&(a.m[b].destroy(),delete a.m[b]),d&&(a.m[b]=d),a.g[b].changeType(c+a.C.sourceBufferExtraFeatures),a.G[b]=c),zi(a,b))})}
345
- function Wi(a,b){var c,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,B,A,D,F,J,G;return K(function(H){switch(H.g){case 1:c=Cc;a.A=!0;a.o=!1;d=a.i.currentTime;e=a.i.autoplay;f=a.i.paused;a.$&&(a.i.autoplay=!1);ta(H,2);a.s.zb();g=[];for(h in a.m)g.push(a.m[h].destroy());for(k in a.j)for(l=a.j[k],m=l[0],a.j[k]=l.slice(0,1),m&&g.push(m.p.catch(Vc)),n=t(l.slice(1)),r=n.next();!r.done;r=n.next())p=r.value,p.p.reject(new O(2,7,7003,void 0));for(u in a.g){v=a.g[u];try{a.l.removeSourceBuffer(v)}catch(I){}}return C(H,Promise.all(g),
346
- 4);case 4:return a.m={},a.g={},x=a.l.duration,a.J=new Le,a.l=ti(a,a.J),C(H,a.J,5);case 5:a.l.duration=x;z=new Le;y=a.l.sourceBuffers;B=b.size;A=0;a.s.D(y,"addsourcebuffer",function(){A++;A===B&&z.resolve()});D=t(b.keys());for(F=D.next();!F.done;F=D.next())J=F.value,G=b.get(J),wi(a,J,G,G.codecs),a.o?(a.j[c.P]=[],a.j[c.ea]=[]):a.j[J]=[];a.i.currentTime=d;return C(H,z,2);case 2:xa(H),a.A=!1,nf(a.I),a.s.ha(a.i,"canplay",function(){nf(a.I);a.i.autoplay=e;f||a.i.play()}),ya(H,0)}})}
345
+ function Wi(a,b){var c,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,A,B,D,F,J,G;return K(function(H){switch(H.g){case 1:c=Cc;a.A=!0;a.o=!1;d=a.i.currentTime;e=a.i.autoplay;f=a.i.paused;a.$&&(a.i.autoplay=!1);ta(H,2);a.s.zb();g=[];for(h in a.m)g.push(a.m[h].destroy());for(k in a.j)for(l=a.j[k],m=l[0],a.j[k]=l.slice(0,1),m&&g.push(m.p.catch(Vc)),n=t(l.slice(1)),r=n.next();!r.done;r=n.next())p=r.value,p.p.reject(new O(2,7,7003,void 0));for(u in a.g){v=a.g[u];try{a.l.removeSourceBuffer(v)}catch(I){}}return C(H,Promise.all(g),
346
+ 4);case 4:return a.m={},a.g={},x=a.l.duration,a.J=new Le,a.l=ti(a,a.J),C(H,a.J,5);case 5:a.l.duration=x;z=new Le;y=a.l.sourceBuffers;A=b.size;B=0;a.s.D(y,"addsourcebuffer",function(){B++;B===A&&z.resolve()});D=t(b.keys());for(F=D.next();!F.done;F=D.next())J=F.value,G=b.get(J),wi(a,J,G,G.codecs),a.o?(a.j[c.P]=[],a.j[c.ea]=[]):a.j[J]=[];a.i.currentTime=d;return C(H,z,2);case 2:xa(H),a.A=!1,nf(a.I),a.s.ha(a.i,"canplay",function(){nf(a.I);a.i.autoplay=e;f||a.i.play()}),ya(H,0)}})}
347
347
  function Xi(a,b){return Si(a,function(){return Wi(a,b)})}
348
348
  function Qi(a,b,c,d){var e,f,g,h,k,l,m,n,r,p,u;return K(function(v){if(1==v.g){if(b==Bc)return v.return(!1);e=Jc(Lc(a.G[b]))[0];f=Kc(a.G[b]);h=Ec(c.mimeType,c.codecs);k=a.C.forceTransmux;if(!bb(h)||!a.u&&Fc.includes(h))k=!0;l=Gc(c.mimeType,c.codecs);k&&(m=$b(l))&&(g=m(),h=g.convertCodecs(b,l));n=Lc(h);r=Jc(n)[0];p=Kc(h);if(e===r&&f===p)return v.return(!1);u=!0;if(a.o||n.split(",").length&&g&&!a.m[b])u=!1;if(u&&"smooth"===a.C.codecSwitchingStrategy&&fb())return C(v,Vi(a,b,h,g),3);g&&g.destroy();return C(v,
349
349
  Xi(a,d),3)}return v.return(!0)})}function Yi(a,b,c){if(b==Bc)var d=!1;else{d=Jc(Lc(a.G[b]))[0];var e=Kc(a.G[b]),f=Ec(c.mimeType,c.codecs),g=a.C.forceTransmux;if(!bb(f)||!a.u&&Fc.includes(f))g=!0;c=Gc(c.mimeType,c.codecs);g&&(g=$b(c))&&(g=g(),f=g.convertCodecs(b,c),g.destroy());b=Jc(Lc(f))[0];f=Kc(f);d=d!==b||e!==f}return d?"smooth"!==a.C.codecSwitchingStrategy||!fb()||a.o:!1}var vi=window.URL.createObjectURL,yi="sequence";function Zi(a,b,c){this.i=a;this.m=b;this.s=this.j=Infinity;this.g=1;this.h=this.l=null;this.o=0;this.C=!0;this.F=0;this.u=void 0===c?!0:c;this.G=0;this.A=!1}q=Zi.prototype;q.getDuration=function(){return this.j};q.Ng=function(){return this.g};q.cg=function(a){this.i=a};q.Ka=function(a){this.j=a};q.Rg=function(){return this.i};q.ag=function(a){this.o=a};q.hc=function(a){this.C=a};q.Nd=function(a){this.s=a};q.bg=function(a){this.m=a};q.Gg=function(){return this.m};
350
350
  q.Rf=function(a,b){if(0!=a.length){var c=a[a.length-1].end+b;this.Id(a[0].start+b);this.g=a.reduce(function(d,e){return Math.max(d,e.end-e.start)},this.g);this.h=Math.max(this.h,c);null!=this.i&&this.u&&!this.A&&(this.i=(Date.now()+this.o)/1E3-this.h-this.g)}};
351
351
  q.Sc=function(a){if(0!=a.length){var b=a[0].startTime,c=a[0].endTime,d=(Date.now()+this.o)/1E3;a=t(a);for(var e=a.next();!e.done;e=a.next())e=e.value,d<e.startTime||(b=Math.min(b,e.startTime),c=Math.max(c,e.endTime),this.g=Math.max(this.g,e.endTime-e.startTime));this.Id(b);this.h=Math.max(this.h,c);null!=this.i&&this.u&&!this.A&&(this.i=d-this.h-this.g)}};q.Dd=function(){this.A=!0};q.Id=function(a){this.l=null==this.l?a:Math.min(this.l,a)};q.Pe=function(a){this.g=Math.max(this.g,a)};
352
- q.offset=function(a){null!=this.l&&(this.l+=a);null!=this.h&&(this.h+=a)};q.S=function(){return Infinity==this.j&&!this.C};q.Mb=function(){return Infinity!=this.j&&!this.C};q.ib=function(){return Math.max(this.F,this.vb()-this.s)};q.eg=function(a){this.F=a};q.vb=function(){return this.S()||this.Mb()?Math.min(Math.max(0,(Date.now()+this.o)/1E3-this.g-this.i)+this.G,this.j):this.h?Math.min(this.h,this.j):this.j};
353
- q.Lc=function(a){var b=Math.max(this.l,this.F);return Infinity==this.s?Math.ceil(1E3*b)/1E3:Math.max(b,Math.min(this.vb()-this.s+a,this.hb()))};q.Zb=function(){return this.Lc(0)};q.hb=function(){return Math.max(0,this.vb()-(this.S()||this.Mb()?this.m:0))};q.hg=function(){return null==this.i||null!=this.h&&this.u?!1:!0};q.$f=function(a){this.G=a};N("shaka.media.PresentationTimeline",Zi);Zi.prototype.setAvailabilityTimeOffset=Zi.prototype.$f;Zi.prototype.usingPresentationStartTime=Zi.prototype.hg;
354
- Zi.prototype.getSeekRangeEnd=Zi.prototype.hb;Zi.prototype.getSeekRangeStart=Zi.prototype.Zb;Zi.prototype.getSafeSeekRangeStart=Zi.prototype.Lc;Zi.prototype.getSegmentAvailabilityEnd=Zi.prototype.vb;Zi.prototype.setUserSeekStart=Zi.prototype.eg;Zi.prototype.getSegmentAvailabilityStart=Zi.prototype.ib;Zi.prototype.isInProgress=Zi.prototype.Mb;Zi.prototype.isLive=Zi.prototype.S;Zi.prototype.offset=Zi.prototype.offset;Zi.prototype.notifyMaxSegmentDuration=Zi.prototype.Pe;
352
+ q.offset=function(a){null!=this.l&&(this.l+=a);null!=this.h&&(this.h+=a)};q.S=function(){return Infinity==this.j&&!this.C};q.Lb=function(){return Infinity!=this.j&&!this.C};q.ib=function(){return Math.max(this.F,this.vb()-this.s)};q.eg=function(a){this.F=a};q.vb=function(){return this.S()||this.Lb()?Math.min(Math.max(0,(Date.now()+this.o)/1E3-this.g-this.i)+this.G,this.j):this.h?Math.min(this.h,this.j):this.j};
353
+ q.Lc=function(a){var b=Math.max(this.l,this.F);return Infinity==this.s?Math.ceil(1E3*b)/1E3:Math.max(b,Math.min(this.vb()-this.s+a,this.hb()))};q.Zb=function(){return this.Lc(0)};q.hb=function(){return Math.max(0,this.vb()-(this.S()||this.Lb()?this.m:0))};q.hg=function(){return null==this.i||null!=this.h&&this.u?!1:!0};q.$f=function(a){this.G=a};N("shaka.media.PresentationTimeline",Zi);Zi.prototype.setAvailabilityTimeOffset=Zi.prototype.$f;Zi.prototype.usingPresentationStartTime=Zi.prototype.hg;
354
+ Zi.prototype.getSeekRangeEnd=Zi.prototype.hb;Zi.prototype.getSeekRangeStart=Zi.prototype.Zb;Zi.prototype.getSafeSeekRangeStart=Zi.prototype.Lc;Zi.prototype.getSegmentAvailabilityEnd=Zi.prototype.vb;Zi.prototype.setUserSeekStart=Zi.prototype.eg;Zi.prototype.getSegmentAvailabilityStart=Zi.prototype.ib;Zi.prototype.isInProgress=Zi.prototype.Lb;Zi.prototype.isLive=Zi.prototype.S;Zi.prototype.offset=Zi.prototype.offset;Zi.prototype.notifyMaxSegmentDuration=Zi.prototype.Pe;
355
355
  Zi.prototype.notifyMinSegmentStartTime=Zi.prototype.Id;Zi.prototype.lockStartTime=Zi.prototype.Dd;Zi.prototype.notifySegments=Zi.prototype.Sc;Zi.prototype.notifyTimeRange=Zi.prototype.Rf;Zi.prototype.getDelay=Zi.prototype.Gg;Zi.prototype.setDelay=Zi.prototype.bg;Zi.prototype.setSegmentAvailabilityDuration=Zi.prototype.Nd;Zi.prototype.setStatic=Zi.prototype.hc;Zi.prototype.setClockOffset=Zi.prototype.ag;Zi.prototype.getPresentationStartTime=Zi.prototype.Rg;Zi.prototype.setDuration=Zi.prototype.Ka;
356
356
  Zi.prototype.setPresentationStartTime=Zi.prototype.cg;Zi.prototype.getMaxSegmentDuration=Zi.prototype.Ng;Zi.prototype.getDuration=Zi.prototype.getDuration;function $i(a,b,c){this.j=c;this.l=a;this.s=aj(a);this.g=a.g.currentTime;this.m=Date.now()/1E3;this.h=!1;this.o=0;this.u=b;this.i=function(){}}$i.prototype.release=function(){this.j=this.l=null;this.i=function(){}};function bj(a,b){a.i=b}function cj(a){this.g=a}function aj(a){if(a.g.paused||0==a.g.buffered.length)var b=!1;else a:{b=a.g.currentTime;a=t(Bh(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 dj(a,b,c,d,e){var f=this;this.u=e;this.g=a;this.A=b;this.s=c;this.l=new of;this.j=!1;this.F=a.readyState;this.C=this.i=0;this.h=d;this.o=!1;this.l.D(a,"waiting",function(){return ej(f)});this.m=(new id(function(){ej(f)})).Ua(this.s.gapJumpTimerTime)}dj.prototype.release=function(){this.l&&(this.l.release(),this.l=null);null!=this.m&&(this.m.stop(),this.m=null);this.h&&(this.h.release(),this.h=null);this.g=this.A=this.u=null};dj.prototype.Se=function(){this.o=!0;ej(this)};
357
357
  function ej(a){if(0!=a.g.readyState){if(a.g.seeking){if(!a.j)return}else a.j=!1;if(!a.g.paused||a.g.currentTime==a.i&&(a.g.autoplay||a.g.currentTime!=a.i)){a.g.readyState!=a.F&&(a.F=a.g.readyState);var b;if(!(b=!a.h)){b=a.h;var c=b.l,d=aj(c),e=c.g.currentTime,f=Date.now()/1E3;if(b.g!=e||b.s!=d)b.m=f,b.g=e,b.s=d,b.h=!1;e=f-b.m;if(d=e>=b.u&&d&&!b.h)b.i(b.g,e),b.h=!0,b.g=c.g.currentTime,b.o++,b.j(new Q("stalldetected"));b=!d}b&&(b=a.g.currentTime,c=a.g.buffered,d=Ch(c,b,a.s.gapDetectionThreshold),null==
@@ -363,81 +363,83 @@ function pj(a,b,c,d,e,f){var g=this;this.i=a;this.g=b.presentationTimeline;this.
363
363
  g.g.Zb():g.g.hb():0>h&&(h=g.g.hb()+h);return sj(g,tj(g,h))});this.m=new id(function(){if(0!=g.i.readyState&&!g.i.paused){var h=kj(g.h),k=g.g.Zb(),l=g.g.hb();3>l-k&&(k=l-3);h<k&&(h=rj(g,h),g.i.currentTime=h)}})}q=pj.prototype;q.Yd=function(){this.m.Ua(.25)};q.release=function(){this.h&&(this.h.release(),this.h=null);this.j&&(this.j.release(),this.j=null);this.m&&(this.m.stop(),this.m=null);this.i=this.h=this.g=this.l=null;this.u=function(){}};q.Zd=function(a){lj(this.h,a)};
364
364
  q.kd=function(){var a=kj(this.h);return 0<this.i.readyState&&!this.i.paused?tj(this,a):a};q.pf=function(){return this.o?this.o.o:0};q.nf=function(){return this.j.C};q.Qf=function(){this.j.Se()};function sj(a,b){var c=a.g.getDuration();return b>=c?c-a.l.durationBackoff:b}
365
365
  function rj(a,b){var c=Math.max(a.A,a.l.rebufferingGoal),d=a.l.safeSeekOffset,e=a.g.Zb(),f=a.g.hb(),g=a.g.getDuration();3>f-e&&(e=f-3);var h=a.g.Lc(c),k=a.g.Lc(d);c=a.g.Lc(c+d);return b>=g?sj(a,b):b>f?f:b<e?zh(a.i.buffered,k)?k:c:b>=h||zh(a.i.buffered,b)?b:c}function tj(a,b){var c=a.g.Zb();if(b<c)return c;a=a.g.hb();return b>a?a:b}
366
- function qj(a,b,c){if(!b.stallEnabled)return null;var d=b.stallSkip;b=new $i(new cj(a),b.stallThreshold,c);bj(b,function(){d?a.currentTime+=d:(a.pause(),a.play())});return b};function uj(a){this.g=a;this.l=null;this.j=0;this.o=!1}q=uj.prototype;q.Jb=function(){return this.g.length};q.release=function(){this.o||(this.g=[],this.l&&this.l.stop(),this.l=null)};q.mh=function(){this.o=!0};function vj(a,b){a=t(a.g);for(var c=a.next();!c.done;c=a.next())b(c.value)}q.find=function(a){for(var b=this.g.length-1,c=b;0<=c;--c){var d=this.g[c],e=c<b?this.g[c+1].startTime:d.endTime;if(a>=d.startTime&&a<e)return c+this.j}return this.g.length&&a<this.g[0].startTime?this.j:null};
366
+ function qj(a,b,c){if(!b.stallEnabled)return null;var d=b.stallSkip;b=new $i(new cj(a),b.stallThreshold,c);bj(b,function(){d?a.currentTime+=d:(a.pause(),a.play())});return b};function uj(a){this.g=a;this.l=null;this.j=0;this.o=!1}q=uj.prototype;q.Ib=function(){return this.g.length};q.release=function(){this.o||(this.g=[],this.l&&this.l.stop(),this.l=null)};q.mh=function(){this.o=!0};function vj(a,b){a=t(a.g);for(var c=a.next();!c.done;c=a.next())b(c.value)}q.find=function(a){for(var b=this.g.length-1,c=b;0<=c;--c){var d=this.g[c],e=c<b?this.g[c+1].startTime:d.endTime;if(a>=d.startTime&&a<e)return c+this.j}return this.g.length&&a<this.g[0].startTime?this.j:null};
367
367
  q.get=function(a){if(0==this.g.length)return null;a-=this.j;return 0>a||a>=this.g.length?null:this.g[a]};q.offset=function(a){if(!this.o)for(var b=t(this.g),c=b.next();!c.done;c=b.next())c.value.offset(a)};q.Gd=function(a){if(!this.o&&a.length){var b=Math.round(1E3*a[0].startTime)/1E3;this.g=this.g.filter(function(c){return Math.round(1E3*c.startTime)/1E3<b});this.g.push.apply(this.g,w(a))}};
368
368
  q.Rc=function(a,b){var c=this;a=a.filter(function(d){return d.endTime>b&&(0==c.g.length||d.endTime>c.g[0].startTime)});this.Gd(a);this.Xa(b)};q.Xa=function(a){if(!this.o){var b=this.g.length;this.g=this.g.filter(function(c){return c.endTime>a});this.j+=b-this.g.length}};
369
369
  q.Wb=function(a,b,c){c=void 0===c?!1:c;if(!this.o){for(;this.g.length;)if(this.g[this.g.length-1].startTime>=b)this.g.pop();else break;for(;this.g.length;)if(this.g[0].endTime<=a)this.g.shift(),c||this.j++;else break;0!=this.g.length&&(a=this.g[this.g.length-1],this.g[this.g.length-1]=new S(a.startTime,b,a.H,a.La,a.sa,a.g,a.timestampOffset,a.appendWindowStart,a.appendWindowEnd,a.h,a.tilesLayout,a.G,a.i,a.status,a.aes128Key),this.g[this.g.length-1].l=a.l)}};
370
- q.Od=function(a,b){var c=this;this.o||(this.l&&this.l.stop(),this.l=new id(function(){var d=b();d?c.g.push.apply(c.g,w(d)):(c.l.stop(),c.l=null)}),this.l.Ua(a))};uj.prototype[Symbol.iterator]=function(){return this.Hb(0)};
371
- uj.prototype.Hb=function(a){var b=this.find(a);if(null==b)return null;b--;var c=this.get(b+1),d=-1;if(c&&0<c.h.length)for(var e=c.h.length-1;0<=e;--e){var f=c.h[e];if(a>=f.startTime&&a<f.endTime){for(;e&&!f.m;)e--,f=c.h[e];if(!f.m)return Ra("No independent partial segment found!"),null;b++;d=e-1;break}}return new wj(this,b,d)};function xj(a,b,c){a=new S(a,a+b,function(){return c},0,null,null,a,a,a+b);return new uj([a])}N("shaka.media.SegmentIndex",uj);uj.forSingleSegment=xj;
372
- uj.prototype.getIteratorForTime=uj.prototype.Hb;uj.prototype.updateEvery=uj.prototype.Od;uj.prototype.fit=uj.prototype.Wb;uj.prototype.evict=uj.prototype.Xa;uj.prototype.mergeAndEvict=uj.prototype.Rc;uj.prototype.offset=uj.prototype.offset;uj.prototype.get=uj.prototype.get;uj.prototype.find=uj.prototype.find;uj.prototype.markImmutable=uj.prototype.mh;uj.prototype.release=uj.prototype.release;function wj(a,b,c){this.i=a;this.g=b;this.h=c}wj.prototype.xg=function(){return this.g};
370
+ q.Od=function(a,b){var c=this;this.o||(this.l&&this.l.stop(),this.l=new id(function(){var d=b();d?c.g.push.apply(c.g,w(d)):(c.l.stop(),c.l=null)}),this.l.Ua(a))};uj.prototype[Symbol.iterator]=function(){return this.Gb(0)};
371
+ uj.prototype.Gb=function(a){var b=this.find(a);if(null==b)return null;b--;var c=this.get(b+1),d=-1;if(c&&0<c.h.length)for(var e=c.h.length-1;0<=e;--e){var f=c.h[e];if(a>=f.startTime&&a<f.endTime){for(;e&&!f.m;)e--,f=c.h[e];if(!f.m)return Ra("No independent partial segment found!"),null;b++;d=e-1;break}}return new wj(this,b,d)};function xj(a,b,c){a=new S(a,a+b,function(){return c},0,null,null,a,a,a+b);return new uj([a])}N("shaka.media.SegmentIndex",uj);uj.forSingleSegment=xj;
372
+ uj.prototype.getIteratorForTime=uj.prototype.Gb;uj.prototype.updateEvery=uj.prototype.Od;uj.prototype.fit=uj.prototype.Wb;uj.prototype.evict=uj.prototype.Xa;uj.prototype.mergeAndEvict=uj.prototype.Rc;uj.prototype.offset=uj.prototype.offset;uj.prototype.get=uj.prototype.get;uj.prototype.find=uj.prototype.find;uj.prototype.markImmutable=uj.prototype.mh;uj.prototype.release=uj.prototype.release;function wj(a,b,c){this.i=a;this.g=b;this.h=c}wj.prototype.xg=function(){return this.g};
373
373
  wj.prototype.current=function(){var a=this.i.get(this.g);a&&0<a.h.length&&a.u&&this.h>=a.h.length&&(this.g++,this.h=0,a=this.i.get(this.g));return a&&0<a.h.length?a.h[this.h]:a};wj.prototype.next=function(){var a=this.i.get(this.g);a&&0<a.h.length?(this.h++,a.u&&this.h==a.h.length&&(this.g++,this.h=0)):(this.g++,this.h=0);a=this.current();return{value:a,done:!a}};N("shaka.media.SegmentIterator",wj);wj.prototype.next=wj.prototype.next;wj.prototype.current=wj.prototype.current;
374
- wj.prototype.currentPosition=wj.prototype.xg;function yj(){uj.call(this,[]);this.h=[]}oa(yj,uj);q=yj.prototype;q.clone=function(){var a=new yj;a.h=this.h.slice();return a};q.release=function(){for(var a=t(this.h),b=a.next();!b.done;b=a.next())b.value.release();this.h=[]};q.find=function(a){for(var b=0,c=t(this.h),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.find(a);if(null!=e)return e+b;b+=d.j+d.Jb()}return null};
375
- q.get=function(a){for(var b=0,c=t(this.h),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.get(a-b);if(e)return e;b+=d.j+d.Jb()}return null};q.offset=function(){};q.Gd=function(){};q.Xa=function(){};q.Rc=function(){};q.Wb=function(){};q.Od=function(){};N("shaka.media.MetaSegmentIndex",yj);yj.prototype.updateEvery=yj.prototype.Od;yj.prototype.fit=yj.prototype.Wb;yj.prototype.mergeAndEvict=yj.prototype.Rc;yj.prototype.evict=yj.prototype.Xa;yj.prototype.merge=yj.prototype.Gd;yj.prototype.offset=yj.prototype.offset;
374
+ wj.prototype.currentPosition=wj.prototype.xg;function yj(){uj.call(this,[]);this.h=[]}oa(yj,uj);q=yj.prototype;q.clone=function(){var a=new yj;a.h=this.h.slice();return a};q.release=function(){for(var a=t(this.h),b=a.next();!b.done;b=a.next())b.value.release();this.h=[]};q.find=function(a){for(var b=0,c=t(this.h),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.find(a);if(null!=e)return e+b;b+=d.j+d.Ib()}return null};
375
+ q.get=function(a){for(var b=0,c=t(this.h),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.get(a-b);if(e)return e;b+=d.j+d.Ib()}return null};q.offset=function(){};q.Gd=function(){};q.Xa=function(){};q.Rc=function(){};q.Wb=function(){};q.Od=function(){};N("shaka.media.MetaSegmentIndex",yj);yj.prototype.updateEvery=yj.prototype.Od;yj.prototype.fit=yj.prototype.Wb;yj.prototype.mergeAndEvict=yj.prototype.Rc;yj.prototype.evict=yj.prototype.Xa;yj.prototype.merge=yj.prototype.Gd;yj.prototype.offset=yj.prototype.offset;
376
376
  yj.prototype.get=yj.prototype.get;yj.prototype.find=yj.prototype.find;yj.prototype.release=yj.prototype.release;function zj(a){var b=this;this.g=a;this.h=this.g.xd();this.i=new id(function(){b.g.Pf(.25*b.h)})}zj.prototype.release=function(){this.i&&(this.i.stop(),this.i=null);this.g=null};zj.prototype.set=function(a){if(this.h!=a)a:{this.h=a,this.i.stop();if(0<=this.h)try{var b=this.h;this.g.xd()!=b&&this.g.ef(b);break a}catch(c){}this.i.Ua(.25);0!=this.g.xd()&&this.g.ef(0)}};zj.prototype.Ic=function(){return this.g.Ic()};function Aj(a){var b=this;this.h=a;this.g=new Set;this.i=(new id(function(){Bj(b,!1)})).Ua(.25)}Aj.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 Bj(a,b){for(var c=t(a.g),d=c.next();!d.done;d=c.next())d.value.j(a.h.currentTime,b)};function Cj(a){Ve.call(this);this.g=new Map;this.h=a}oa(Cj,Ve);Cj.prototype.release=function(){this.g.clear();Ve.prototype.release.call(this)};function Dj(a,b){var c=a.g.get(b);c||(c={Uc:[],xf:null,contentType:b},a.g.set(b,c));return c}function Ej(a,b,c){var d=Dj(a,b.contentType);Fj(a,d);a={Ne:b,position:c};d=d.Uc;b=d.findIndex(function(e){return e.position>=c});0<=b?d.splice(b,d[b].position==c?1:0,a):d.push(a)}
377
377
  Cj.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.Uc;for(var e=d.length-1;0<=e;e--){var f=d[e];if(f.position<=a){d=f.Ne;break a}}d=null}if(e=d)e=c.xf,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);
378
- 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.xf=d,JSON.stringify(d),c=new Q("qualitychange",new Map([["quality",d],["position",a]])),this.dispatchEvent(c))}};function Fj(a,b){if((a=a.h()[b.contentType])&&0<a.length){var c=a[0].start,d=a[a.length-1].end,e=b.Uc;b.Uc=e.filter(function(f,g){return f.position<=c&&g+1<e.length&&e[g+1].position<=c||f.position>=d?!1:!0})}else b.Uc=[]};function Gj(a){Ve.call(this);var b=this;this.g=new Set;this.i=a;this.h=(new id(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))})).Ua(2)}oa(Gj,Ve);Gj.prototype.release=function(){this.g.clear();this.h.stop();Ve.prototype.release.call(this)};function Hj(a,b){Ve.call(this);var c=this;this.i=a;this.l=b;this.g=new Map;this.m=[{Tb:null,Sb:Ij,Lb:function(d,e){return Jj(c,"enter",d,e)}},{Tb:Kj,Sb:Ij,Lb:function(d,e){return Jj(c,"enter",d,e)}},{Tb:Lj,Sb:Ij,Lb:function(d,e){return Jj(c,"enter",d,e)}},{Tb:Ij,Sb:Kj,Lb:function(d,e){return Jj(c,"exit",d,e)}},{Tb:Ij,Sb:Lj,Lb:function(d,e){return Jj(c,"exit",d,e)}},{Tb:Kj,Sb:Lj,Lb:function(d,e){return Jj(c,"skip",d,e)}},{Tb:Lj,Sb:Kj,Lb:function(d,e){return Jj(c,"skip",d,e)}}];this.h=new of;this.h.D(this.i,
379
- "regionremove",function(d){c.g.delete(d.region)})}oa(Hj,Ve);Hj.prototype.release=function(){this.i=null;this.g.clear();this.h.release();this.h=null;Ve.prototype.release.call(this)};Hj.prototype.j=function(a,b){if(!this.l||0!=a){this.l=!1;for(var c=t(this.i.g),d=c.next();!d.done;d=c.next()){d=d.value;var e=this.g.get(d),f=a<d.startTime?Kj:a>d.endTime?Lj:Ij;this.g.set(d,f);for(var g=t(this.m),h=g.next();!h.done;h=g.next())h=h.value,h.Tb==e&&h.Sb==f&&h.Lb(d,b)}}};
380
- function Jj(a,b,c,d){b=new Q(b,new Map([["region",c],["seeking",d]]));a.dispatchEvent(b)}var Kj=1,Ij=2,Lj=3;function Mj(a,b,c){this.i=a;this.h=b;this.j=0;this.l=c;this.g=new Map}function Nj(a,b,c){c=void 0===c?!1:c;if(a.h.segmentIndex){var d=a.h.segmentIndex.Hb(Math.max(b.startTime,a.j));if(d){var e=b;c&&(e=d.next().value)&&e.startTime==b.startTime&&e.endTime==b.endTime&&(e=null);for(;a.g.size<a.i&&null!=e;)b=!0,e.o&&null!=e.sa&&(b=!1),2==e.Kb()&&(b=!1),b&&!a.g.has(e)&&(b=new Oj(a.l),Pj(b,e,a.h),a.g.set(e,b)),a.j=e.startTime,e=d.next().value}}}
378
+ 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.xf=d,JSON.stringify(d),c=new Q("qualitychange",new Map([["quality",d],["position",a]])),this.dispatchEvent(c))}};function Fj(a,b){if((a=a.h()[b.contentType])&&0<a.length){var c=a[0].start,d=a[a.length-1].end,e=b.Uc;b.Uc=e.filter(function(f,g){return f.position<=c&&g+1<e.length&&e[g+1].position<=c||f.position>=d?!1:!0})}else b.Uc=[]};function Gj(a){Ve.call(this);var b=this;this.g=new Set;this.i=a;this.h=(new id(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))})).Ua(2)}oa(Gj,Ve);Gj.prototype.release=function(){this.g.clear();this.h.stop();Ve.prototype.release.call(this)};function Hj(a,b){Ve.call(this);var c=this;this.i=a;this.l=b;this.g=new Map;this.m=[{Tb:null,Sb:Ij,Kb:function(d,e){return Jj(c,"enter",d,e)}},{Tb:Kj,Sb:Ij,Kb:function(d,e){return Jj(c,"enter",d,e)}},{Tb:Lj,Sb:Ij,Kb:function(d,e){return Jj(c,"enter",d,e)}},{Tb:Ij,Sb:Kj,Kb:function(d,e){return Jj(c,"exit",d,e)}},{Tb:Ij,Sb:Lj,Kb:function(d,e){return Jj(c,"exit",d,e)}},{Tb:Kj,Sb:Lj,Kb:function(d,e){return Jj(c,"skip",d,e)}},{Tb:Lj,Sb:Kj,Kb:function(d,e){return Jj(c,"skip",d,e)}}];this.h=new of;this.h.D(this.i,
379
+ "regionremove",function(d){c.g.delete(d.region)})}oa(Hj,Ve);Hj.prototype.release=function(){this.i=null;this.g.clear();this.h.release();this.h=null;Ve.prototype.release.call(this)};Hj.prototype.j=function(a,b){if(!this.l||0!=a){this.l=!1;for(var c=t(this.i.g),d=c.next();!d.done;d=c.next()){d=d.value;var e=this.g.get(d),f=a<d.startTime?Kj:a>d.endTime?Lj:Ij;this.g.set(d,f);for(var g=t(this.m),h=g.next();!h.done;h=g.next())h=h.value,h.Tb==e&&h.Sb==f&&h.Kb(d,b)}}};
380
+ function Jj(a,b,c,d){b=new Q(b,new Map([["region",c],["seeking",d]]));a.dispatchEvent(b)}var Kj=1,Ij=2,Lj=3;function Mj(a,b,c){this.i=a;this.h=b;this.j=0;this.l=c;this.g=new Map}function Nj(a,b,c){c=void 0===c?!1:c;if(a.h.segmentIndex){var d=a.h.segmentIndex.Gb(Math.max(b.startTime,a.j));if(d){var e=b;c&&(e=d.next().value)&&e.startTime==b.startTime&&e.endTime==b.endTime&&(e=null);for(;a.g.size<a.i&&null!=e;)b=!0,e.o&&null!=e.sa&&(b=!1),2==e.Jb()&&(b=!1),b&&!a.g.has(e)&&(b=new Oj(a.l),Pj(b,e,a.h),a.g.set(e,b)),a.j=e.startTime,e=d.next().value}}}
381
381
  function Qj(a,b){if(a.h.segmentIndex&&a.g.size<a.i&&!a.g.has(b)){var c=new Oj(a.l);Pj(c,b,a.h);a.g.set(b,c)}}function Rj(a){if(0!==a.g.size){for(var b=t(a.g.keys()),c=b.next();!c.done;c=b.next())(c=c.value)&&Sj(a,c);a.j=0}}function Tj(a,b){b&&b!==a.h&&(Rj(a),a.h=b)}function Sj(a,b){var c=a.g.get(b);a.g.delete(b);c&&c.abort()}function Oj(a){this.i=a;this.g=this.h=null}
382
382
  function Pj(a,b,c){var d=new Uint8Array(0);a.g=a.i(b,c,function(e){return K(function(f){if(1==f.g)return 0<d.byteLength?d=$f(d,e):d=e,a.h?C(f,a.h(d),3):f.B(0);d=new Uint8Array(0);E(f)})})}Oj.prototype.abort=function(){this.g&&this.g.abort()};function Uj(a,b,c,d,e){a=df(a,d,e);if(0!=b||null!=c)a.headers.Range=c?"bytes="+b+"-"+c:"bytes="+b+"-";return a};function Vj(a,b){var c=this;this.g=b;this.m=a;this.i=null;this.u=1;this.o=this.j=null;this.F=0;this.C=!1;this.h=new Map;this.A=!1;this.G=null;this.s=!1;this.l=new mf(function(){return Wj(c)})}q=Vj.prototype;q.destroy=function(){return this.l.destroy()};function Wj(a){var b,c,d,e;return K(function(f){if(1==f.g){b=[];c=t(a.h.values());for(d=c.next();!d.done;d=c.next())e=d.value,Xj(e),b.push(Yj(e));return C(f,Promise.all(b),2)}a.h.clear();a.g=null;a.m=null;a.i=null;E(f)})}
383
383
  q.configure=function(a){this.i=a;this.G=new Ie({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);for(var b=t(this.h.keys()),c=b.next();!c.done;c=b.next())if(c=this.h.get(c.value),c.qa){var d=c.qa,e=a.segmentPrefetchLimit;d.i=e;for(var f=Array.from(d.g.keys());f.length>e;){var g=f.pop();g&&Sj(d,g)}0<a.segmentPrefetchLimit||
384
384
  (c.qa=null)}else 0<a.segmentPrefetchLimit&&(c.qa=Zj(this,c.stream))};q.start=function(){var a=this;return K(function(b){if(1==b.g)return C(b,ak(a),2);nf(a.l);a.A=!0;E(b)})};
385
385
  function bk(a,b){var c,d,e,f,g,h,k;K(function(l){switch(l.g){case 1:return c=Cc,a.F++,d=a.F,sa(l,2),C(l,Oi(a.g.T,c.ja),4);case 4:va(l,3);break;case 2:if(e=wa(l),a.g)a.g.onError(e);case 3:f=Ec(b.mimeType,b.codecs),xi(a.g.T,f,a.m.sequenceMode,b.external),g=a.g.T.F,(h=g.isTextVisible()||a.i.alwaysStreamText)&&a.F==d&&(k=ck(a,b),a.h.set(c.ja,k),dk(a,k,0)),E(l)}})}function ek(a){var b=a.h.get(Bc);b&&(Xj(b),Yj(b).catch(function(){}),a.h.delete(Bc));a.o=null}
386
- function fk(a,b){var c=a.h.get("video");if(c){var d=c.stream;if(d)if(b)(b=d.trickModeVideo)&&!c.Pb&&(gk(a,b,!1,0,!1),c.Pb=d);else if(d=c.Pb)c.Pb=null,gk(a,d,!0,0,!1)}}function hk(a,b,c,d,e,f){c=void 0===c?!1:c;d=void 0===d?0:d;e=void 0===e?!1:e;f=void 0===f?!1:f;a.j=b;a.A&&(b.video&&gk(a,b.video,c,d,e,f),b.audio&&gk(a,b.audio,c,d,e,f))}function ik(a,b){K(function(c){if(1==c.g)return a.o=b,a.A?b.segmentIndex?c.B(2):C(c,b.createSegmentIndex(),2):c.return();gk(a,b,!0,0,!1);E(c)})}
387
- function gk(a,b,c,d,e,f){var g=a.h.get(b.type);g||b.type!=Bc?g&&(g.Pb&&(b.trickModeVideo?(g.Pb=b,b=b.trickModeVideo):g.Pb=null),g.stream!=b||e)&&(g.qa&&Tj(g.qa,b),b.type==Bc&&(e=Ec(b.mimeType,b.codecs),xi(a.g.T,e,a.m.sequenceMode,b.external)),g.stream.closeSegmentIndex&&g.stream.closeSegmentIndex(),g.stream=b,g.X=null,g.qf=!!f,c&&(g.Ec?g.Pd=!0:g.ya?(g.nb=!0,g.pd=d,g.Pd=!0):(Xj(g),jk(a,g,!0,d).catch(function(h){if(a.g)a.g.onError(h)}))),kk(a,g).catch(function(h){if(a.g)a.g.onError(h)})):bk(a,b)}
386
+ function fk(a,b){var c=a.h.get("video");if(c){var d=c.stream;if(d)if(b)(b=d.trickModeVideo)&&!c.Ob&&(gk(a,b,!1,0,!1),c.Ob=d);else if(d=c.Ob)c.Ob=null,gk(a,d,!0,0,!1)}}function hk(a,b,c,d,e,f){c=void 0===c?!1:c;d=void 0===d?0:d;e=void 0===e?!1:e;f=void 0===f?!1:f;a.j=b;a.A&&(b.video&&gk(a,b.video,c,d,e,f),b.audio&&gk(a,b.audio,c,d,e,f))}function ik(a,b){K(function(c){if(1==c.g)return a.o=b,a.A?b.segmentIndex?c.B(2):C(c,b.createSegmentIndex(),2):c.return();gk(a,b,!0,0,!1);E(c)})}
387
+ function gk(a,b,c,d,e,f){var g=a.h.get(b.type);g||b.type!=Bc?g&&(g.Ob&&(b.trickModeVideo?(g.Ob=b,b=b.trickModeVideo):g.Ob=null),g.stream!=b||e)&&(g.qa&&Tj(g.qa,b),b.type==Bc&&(e=Ec(b.mimeType,b.codecs),xi(a.g.T,e,a.m.sequenceMode,b.external)),g.stream.closeSegmentIndex&&g.stream.closeSegmentIndex(),g.stream=b,g.X=null,g.qf=!!f,c&&(g.Ec?g.Pd=!0:g.ya?(g.nb=!0,g.pd=d,g.Pd=!0):(Xj(g),jk(a,g,!0,d).catch(function(h){if(a.g)a.g.onError(h)}))),kk(a,g).catch(function(h){if(a.g)a.g.onError(h)})):bk(a,b)}
388
388
  function kk(a,b){var c,d;return K(function(e){if(1==e.g){if(!b.Ia)return e.return();c=b.stream;d=b.Ia;return c.segmentIndex?e.B(2):C(e,c.createSegmentIndex(),2)}if(b.Ia!=d||b.stream!=c)return e.return();var f=a.g.wd();var g=Di(a.g.T,b.type),h=b.stream.segmentIndex.find(b.xa?b.xa.endTime:f),k=null==h?null:b.stream.segmentIndex.get(h);h=k?k.sa?k.sa-k.La:null:null;k&&!h&&(h=(k.endTime-k.getStartTime())*(b.stream.bandwidth||0)/8);h?((k=k.g)&&(h+=(k.sa?k.sa-k.La:null)||0),k=a.g.getBandwidthEstimate(),
389
389
  f=8*h/k<(g||0)-f-Math.max(a.m.minBufferTime||0,a.i.rebufferingGoal)||b.Ia.h.g>h?!0:!1):f=!1;f&&b.Ia.abort();E(e)})}
390
390
  q.Yc=function(){if(this.g)for(var a=this.g.wd(),b=t(this.h.keys()),c=b.next();!c.done;c=b.next()){var d=c.value;c=this.h.get(d);var e=null;c.X&&(e=c.X.current());if(!e||e.startTime>a||e.endTime<a)c.X=null;e=this.g.T;e.A?e=!1:d==Bc?(e=e.h,e=null==e.g||null==e.h?!1:a>=e.g&&a<e.h):(e=Ci(e,d),e=zh(e,a));e||((null!=Di(this.g.T,d)||c.ya)&&lk(this,c),c.Ia&&(c.Ia.abort(),c.Ia=null),d===Bc&&(d=this.g.T,d.H&&d.H.h()),c.Yc=!0)}};
391
391
  function lk(a,b){b.Ec||b.nb||(b.ya?(b.nb=!0,b.pd=0):null==Bi(a.g.T,b.type)?null==b.bb&&dk(a,b,0):(Xj(b),jk(a,b,!1,0).catch(function(c){if(a.g)a.g.onError(c)})))}
392
392
  function ak(a){var b,c,d,e,f,g,h,k,l;return K(function(m){if(1==m.g){b=Cc;if(!a.j)throw new O(2,5,5006);c=new Map;d=new Set;a.j.audio&&(c.set(b.P,a.j.audio),d.add(a.j.audio));a.j.video&&(c.set(b.ea,a.j.video),d.add(a.j.video));a.o&&(c.set(b.ja,a.o),d.add(a.o));e=a.g.T;return C(m,e.init(c,a.m.sequenceMode,a.m.type,a.m.ignoreManifestTimestampsInSegmentsMode),2)}nf(a.l);a.updateDuration();f=t(c.keys());for(g=f.next();!g.done;g=f.next())h=g.value,k=c.get(h),a.h.has(h)||(l=ck(a,k),a.h.set(h,l),dk(a,l,
393
- 0));E(m)})}function ck(a,b){return{stream:b,type:b.type,X:null,qa:Zj(a,b),xa:null,bc:null,Ke:null,Ie:null,He:null,Pb:null,endOfStream:!1,ya:!1,bb:null,nb:!1,pd:0,Pd:!1,Ec:!1,Yc:!0,Oe:!1,Xe:!1,Oc:!1,Ia:null}}function Zj(a,b){return"video"!==b.type&&"audio"!==b.type?null:0<a.i.segmentPrefetchLimit?new Mj(a.i.segmentPrefetchLimit,b,function(c,d,e){return mk(a,c,d,e)}):null}q.updateDuration=function(){var a=this.m.presentationTimeline.getDuration();Infinity>a?this.g.T.Ka(a):this.g.T.Ka(Math.pow(2,32))};
393
+ 0));E(m)})}function ck(a,b){return{stream:b,type:b.type,X:null,qa:Zj(a,b),xa:null,bc:null,Ke:null,Ie:null,He:null,Ob:null,endOfStream:!1,ya:!1,bb:null,nb:!1,pd:0,Pd:!1,Ec:!1,Yc:!0,Oe:!1,Xe:!1,Oc:!1,Ia:null}}function Zj(a,b){return"video"!==b.type&&"audio"!==b.type?null:0<a.i.segmentPrefetchLimit?new Mj(a.i.segmentPrefetchLimit,b,function(c,d,e){return mk(a,c,d,e)}):null}q.updateDuration=function(){var a=this.m.presentationTimeline.getDuration();Infinity>a?this.g.T.Ka(a):this.g.T.Ka(Math.pow(2,32))};
394
394
  function nk(a,b){var c,d,e,f,g;return K(function(h){switch(h.g){case 1:nf(a.l);if(b.ya||null==b.bb||b.Ec)return h.return();b.bb=null;if(!b.nb){h.B(2);break}return C(h,jk(a,b,b.Pd,b.pd),3);case 3:return h.return();case 2:if(b.stream.segmentIndex){h.B(4);break}c=b.stream;return C(h,b.stream.createSegmentIndex(),5);case 5:if(c!=b.stream)return c.closeSegmentIndex&&c.closeSegmentIndex(),b.ya||b.bb||dk(a,b,0),h.return();case 4:sa(h,6);d=ok(a,b);null!=d&&(dk(a,b,d),b.Oc=!1);va(h,7);break;case 6:return e=
395
395
  wa(h),C(h,pk(a,b,e),8);case 8:return h.return();case 7:f=Array.from(a.h.values());if(!a.A||!f.every(function(k){return k.endOfStream})){h.B(0);break}return C(h,a.g.T.endOfStream(),10);case 10:nf(a.l),g=a.g.T.getDuration(),0!=g&&g<a.m.presentationTimeline.getDuration()&&a.m.presentationTimeline.Ka(g),E(h)}})}
396
396
  function ok(a,b){if(qk(b))return Li(a.g.T,b.stream.originalId||""),null;b.type==Bc&&Mi(a.g.T);if(!a.g.T.da&&b.type!=Bc)return a.i.updateIntervalSeconds/2;var c=a.g.wd(),d=b.xa?b.xa.endTime:c,e=Ei(a.g.T,b.type,c),f=Math.max(a.m.minBufferTime||0,a.i.rebufferingGoal,a.i.bufferingGoal)*a.u,g=a.m.presentationTimeline.getDuration()-d,h=Di(a.g.T,b.type);if(1E-6>g&&h)return b.endOfStream=!0,"video"==b.type&&(a=a.h.get(Bc))&&qk(a)&&(a.endOfStream=!0),null;b.endOfStream=!1;if(e>=f)return a.i.updateIntervalSeconds/
397
397
  2;e=rk(a,b,c,h);if(!e)return a.i.updateIntervalSeconds;f=Infinity;g=Array.from(a.h.values());g=t(g);for(h=g.next();!h.done;h=g.next())h=h.value,qk(h)||h.X&&!h.X.current()||(f=Math.min(f,h.xa?h.xa.endTime:c));if(d>=f+a.m.presentationTimeline.g)return a.i.updateIntervalSeconds;b.qa&&b.X&&(d=e.g,!d||b.xa&&vh(d,b.bc)||Qj(b.qa,d),Nj(b.qa,e));sk(a,b,c,e).catch(function(){});return null}
398
- function rk(a,b,c,d){if(b.X)return b.X.current();if(b.xa||d)return c=b.xa?b.xa.endTime:d,b.Oe=!0,b.X=b.stream.segmentIndex.Hb(c),b.X&&b.X.next().value;a=a.i.inaccurateManifestTolerance;d=Math.max(c-a,0);var e=null;a&&(b.X=b.stream.segmentIndex.Hb(d),e=b.X&&b.X.next().value);e||(b.X=b.stream.segmentIndex.Hb(c),e=b.X&&b.X.next().value);return e}
399
- function sk(a,b,c,d){var e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,B;return K(function(A){switch(A.g){case 1:e=Cc;f=b.stream;g=b.X;b.ya=!0;sa(A,2);if(2==d.Kb())throw new O(1,1,1011);return C(A,tk(a,b,d),4);case 4:nf(a.l);if(a.s)return A.return();h="video/mp4"==f.mimeType||"audio/mp4"==f.mimeType;k=window.ReadableStream;if(a.i.lowLatencyMode&&k&&h&&("HLS"!=a.m.type||d.s))return n=new Uint8Array(0),p=r=!1,v=function(D){var F,J,G,H;return K(function(I){switch(I.g){case 1:if(r)return I.return();p=!0;nf(a.l);if(a.s)return I.return();
400
- sa(I,2);n=uk(n,D);F=!1;J=0;(new Kf).box("mdat",function(L){J=L.size+L.start;F=!0}).parse(n,!1,!0);if(!F){I.B(4);break}G=n.subarray(0,J);n=n.subarray(J);return C(I,vk(a,b,c,f,d,G,!0),5);case 5:b.qa&&b.X&&Nj(b.qa,d,!0);case 4:va(I,0);break;case 2:u=H=wa(I),E(I)}})},C(A,wk(a,b,d,v),9);l=wk(a,b,d);return C(A,l,7);case 7:m=A.h;nf(a.l);if(a.s)return A.return();nf(a.l);return b.nb?(b.ya=!1,dk(a,b,0),A.return()):C(A,vk(a,b,c,f,d,m),6);case 9:x=A.h;if(u)throw u;if(p){A.B(10);break}r=!0;nf(a.l);return a.s?
401
- A.return():b.nb?(b.ya=!1,dk(a,b,0),A.return()):C(A,vk(a,b,c,f,d,x),10);case 10:b.qa&&b.X&&Nj(b.qa,d,!0);case 6:nf(a.l);if(a.s)return A.return();b.xa=d;g.next();b.ya=!1;b.Xe=!1;z=a.g.T.gb();y=z[b.type];Ya(JSON.stringify(y));b.nb||a.g.Se(d.startTime,d.endTime,b.type);dk(a,b,0);va(A,0);break;case 2:B=wa(A);nf(a.l,B);if(a.s)return A.return();b.ya=!1;if(7001==B.code)b.ya=!1,Xj(b),dk(a,b,0),A.B(0);else if(b.type==e.ja&&a.i.ignoreTextStreamFailures)a.h.delete(e.ja),A.B(0);else if(3017==B.code)xk(a,b,B),
402
- A.B(0);else return b.Oc=!0,B.severity=2,C(A,pk(a,b,B),0)}})}function yk(a,b,c){var d,e,f,g;return K(function(h){if(1==h.g)return d=b,d.cryptoKey?h.B(2):C(h,d.fetchKey(),3);e=d.iv;if(!e)for(e=mb(new ArrayBuffer(16)),f=d.firstMediaSequenceNumber+c,g=e.byteLength-1;0<=g;g--)e[g]=f&255,f>>=8;return h.return(window.crypto.subtle.decrypt({name:"AES-CBC",iv:e},d.cryptoKey,a))})}function uk(a,b){var c=new Uint8Array(a.length+b.length);c.set(a);c.set(b,a.length);return c}
398
+ function rk(a,b,c,d){if(b.X)return b.X.current();if(b.xa||d)return c=b.xa?b.xa.endTime:d,b.Oe=!0,b.X=b.stream.segmentIndex.Gb(c),b.X&&b.X.next().value;a=a.i.inaccurateManifestTolerance;d=Math.max(c-a,0);var e=null;a&&(b.X=b.stream.segmentIndex.Gb(d),e=b.X&&b.X.next().value);e||(b.X=b.stream.segmentIndex.Gb(c),e=b.X&&b.X.next().value);return e}
399
+ function sk(a,b,c,d){var e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,A;return K(function(B){switch(B.g){case 1:e=Cc;f=b.stream;g=b.X;b.ya=!0;sa(B,2);if(2==d.Jb())throw new O(1,1,1011);return C(B,tk(a,b,d),4);case 4:nf(a.l);if(a.s)return B.return();h="video/mp4"==f.mimeType||"audio/mp4"==f.mimeType;k=window.ReadableStream;if(a.i.lowLatencyMode&&k&&h&&("HLS"!=a.m.type||d.s))return n=new Uint8Array(0),p=r=!1,v=function(D){var F,J,G,H;return K(function(I){switch(I.g){case 1:if(r)return I.return();p=!0;nf(a.l);if(a.s)return I.return();
400
+ sa(I,2);n=uk(n,D);F=!1;J=0;(new Kf).box("mdat",function(L){J=L.size+L.start;F=!0}).parse(n,!1,!0);if(!F){I.B(4);break}G=n.subarray(0,J);n=n.subarray(J);return C(I,vk(a,b,c,f,d,G,!0),5);case 5:b.qa&&b.X&&Nj(b.qa,d,!0);case 4:va(I,0);break;case 2:u=H=wa(I),E(I)}})},C(B,wk(a,b,d,v),9);l=wk(a,b,d);return C(B,l,7);case 7:m=B.h;nf(a.l);if(a.s)return B.return();nf(a.l);return b.nb?(b.ya=!1,dk(a,b,0),B.return()):C(B,vk(a,b,c,f,d,m),6);case 9:x=B.h;if(u)throw u;if(p){B.B(10);break}r=!0;nf(a.l);return a.s?
401
+ B.return():b.nb?(b.ya=!1,dk(a,b,0),B.return()):C(B,vk(a,b,c,f,d,x),10);case 10:b.qa&&b.X&&Nj(b.qa,d,!0);case 6:nf(a.l);if(a.s)return B.return();b.xa=d;g.next();b.ya=!1;b.Xe=!1;z=a.g.T.gb();y=z[b.type];Ya(JSON.stringify(y));b.nb||a.g.Se(d.startTime,d.endTime,b.type);dk(a,b,0);va(B,0);break;case 2:A=wa(B);nf(a.l,A);if(a.s)return B.return();b.ya=!1;if(7001==A.code)b.ya=!1,Xj(b),dk(a,b,0),B.B(0);else if(b.type==e.ja&&a.i.ignoreTextStreamFailures)a.h.delete(e.ja),B.B(0);else if(3017==A.code)xk(a,b,A),
402
+ B.B(0);else return b.Oc=!0,A.severity=2,C(B,pk(a,b,A),0)}})}function yk(a,b,c){var d,e,f,g;return K(function(h){if(1==h.g)return d=b,d.cryptoKey?h.B(2):C(h,d.fetchKey(),3);e=d.iv;if(!e)for(e=mb(new ArrayBuffer(16)),f=d.firstMediaSequenceNumber+c,g=e.byteLength-1;0<=g;g--)e[g]=f&255,f>>=8;return h.return(window.crypto.subtle.decrypt({name:"AES-CBC",iv:e},d.cryptoKey,a))})}function uk(a,b){var c=new Uint8Array(a.length+b.length);c.set(a);c.set(b,a.length);return c}
403
403
  function xk(a,b,c){if(!Array.from(a.h.values()).some(function(e){return e!=b&&e.Xe})){var d=Math.round(100*a.u);if(20<d)a.u-=.2;else if(4<d)a.u-=.04;else{b.Oc=!0;a.s=!0;a.g.onError(c);return}b.Xe=!0}dk(a,b,4)}
404
- function tk(a,b,c){var d,e,f,g,h,k,l,m,n,r,p,u,v;return K(function(x){if(1==x.g){d=Cc;e=[];f=Math.max(0,c.appendWindowStart-.1);g=c.appendWindowEnd+.01;h=Jc(b.stream.codecs)[0];k=Kc(b.stream.mimeType);l=c.timestampOffset;if(l==b.Ke&&f==b.Ie&&g==b.He&&h==b.Je&&k==b.Kf)return x.B(2);if(m=b.Je&&b.Kf&&Yi(a.g.T,b.type,b.stream))n=null,b.type===d.ea?n=a.h.get(d.P):b.type===d.P&&(n=a.h.get(d.ea)),n&&(n.bc=null,lk(a,n),Yj(n).catch(function(){}));r=function(){var z,y,B,A;return K(function(D){if(1==D.g)return z=
405
- new Map,a.j.audio&&z.set(d.P,a.j.audio),a.j.video&&z.set(d.ea,a.j.video),sa(D,2),b.Ie=f,b.He=g,b.Je=h,b.Kf=k,b.Ke=l,y=a.m.sequenceMode||"HLS"==a.m.type,C(D,Pi(a.g.T,b.type,l,f,g,y,b.stream,z),4);if(2!=D.g)return m&&(B=null,b.type===d.ea?B=a.h.get(d.P):b.type===d.P&&(B=a.h.get(d.ea)),B&&(B.nb=!1,B.ya=!1,lk(a,B))),va(D,0);A=wa(D);b.Ie=null;b.He=null;b.Je=null;b.Ke=null;throw A;})};return C(x,r(),2)}vh(c.g,b.bc)||(b.bc=c.g,c.m&&c.g&&(p=wk(a,b,c.g),u=function(){var z,y,B,A,D,F;return K(function(J){switch(J.g){case 1:return sa(J,
406
- 2),C(J,p,4);case 4:return z=J.h,nf(a.l),y=null,B=new Map,A=new Kf,A.box("moov",Pf).box("trak",Pf).box("mdia",Pf).O("mdhd",function(G){y=Mh(G.reader,G.version).timescale}).box("hdlr",function(G){G=G.reader;G.skip(8);G=G.lb(4);var H=String.fromCharCode(G[0]);H+=String.fromCharCode(G[1]);H+=String.fromCharCode(G[2]);H+=String.fromCharCode(G[3]);switch(H){case "soun":B.set(d.P,y);break;case "vide":B.set(d.ea,y)}y=null}).parse(z),B.has(b.type)?c.g.timescale=B.get(b.type):null!=y&&(c.g.timescale=y),D=b.stream.closedCaptions&&
404
+ function tk(a,b,c){var d,e,f,g,h,k,l,m,n,r,p,u,v;return K(function(x){if(1==x.g){d=Cc;e=[];f=Math.max(0,c.appendWindowStart-.1);g=c.appendWindowEnd+.01;h=Jc(b.stream.codecs)[0];k=Kc(b.stream.mimeType);l=c.timestampOffset;if(l==b.Ke&&f==b.Ie&&g==b.He&&h==b.Je&&k==b.Kf)return x.B(2);if(m=b.Je&&b.Kf&&Yi(a.g.T,b.type,b.stream))n=null,b.type===d.ea?n=a.h.get(d.P):b.type===d.P&&(n=a.h.get(d.ea)),n&&(n.bc=null,lk(a,n),Yj(n).catch(function(){}));r=function(){var z,y,A,B;return K(function(D){if(1==D.g)return z=
405
+ new Map,a.j.audio&&z.set(d.P,a.j.audio),a.j.video&&z.set(d.ea,a.j.video),sa(D,2),b.Ie=f,b.He=g,b.Je=h,b.Kf=k,b.Ke=l,y=a.m.sequenceMode||"HLS"==a.m.type,C(D,Pi(a.g.T,b.type,l,f,g,y,b.stream,z),4);if(2!=D.g)return m&&(A=null,b.type===d.ea?A=a.h.get(d.P):b.type===d.P&&(A=a.h.get(d.ea)),A&&(A.nb=!1,A.ya=!1,lk(a,A))),va(D,0);B=wa(D);b.Ie=null;b.He=null;b.Je=null;b.Ke=null;throw B;})};return C(x,r(),2)}vh(c.g,b.bc)||(b.bc=c.g,c.m&&c.g&&(p=wk(a,b,c.g),u=function(){var z,y,A,B,D,F;return K(function(J){switch(J.g){case 1:return sa(J,
406
+ 2),C(J,p,4);case 4:return z=J.h,nf(a.l),y=null,A=new Map,B=new Kf,B.box("moov",Pf).box("trak",Pf).box("mdia",Pf).O("mdhd",function(G){y=Mh(G.reader,G.version).timescale}).box("hdlr",function(G){G=G.reader;G.skip(8);G=G.lb(4);var H=String.fromCharCode(G[0]);H+=String.fromCharCode(G[1]);H+=String.fromCharCode(G[2]);H+=String.fromCharCode(G[3]);switch(H){case "soun":A.set(d.P,y);break;case "vide":A.set(d.ea,y)}y=null}).parse(z),A.has(b.type)?c.g.timescale=A.get(b.type):null!=y&&(c.g.timescale=y),D=b.stream.closedCaptions&&
407
407
  0<b.stream.closedCaptions.size,C(J,a.g.rf(b.type,z),5);case 5:return C(J,Gi(a.g.T,b.type,z,null,b.stream,D),6);case 6:va(J,0);break;case 2:throw F=wa(J),b.bc=null,F;}})},a.g.oh(c.startTime,c.g),e.push(u())));a.m.sequenceMode&&(v=b.xa?b.xa.l:null,c.l!=v||b.Oe)&&(b.Oe=!1,e.push(Ri(a.g.T,b.type,c.startTime)));return C(x,Promise.all(e),0)})}
408
- function vk(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h,k,l,m,n,r;return K(function(p){switch(p.g){case 1:h=d.closedCaptions&&0<d.closedCaptions.size;l=null!=d.emsgSchemeIdUris&&0<d.emsgSchemeIdUris.length||a.i.dispatchAllEmsgBoxes;m=a.i.parsePrftBox&&!a.C;if(l||m)k=new Kf;l&&k.O("emsg",function(u){var v=d.emsgSchemeIdUris;if(0===u.version){var x=u.reader.Vc();var z=u.reader.Vc();var y=u.reader.L();var B=u.reader.L();var A=u.reader.L();var D=u.reader.L();var F=e.startTime+B/y}else y=u.reader.L(),F=u.reader.fc()/
409
- y+e.timestampOffset,B=F-e.startTime,A=u.reader.L(),D=u.reader.L(),x=u.reader.Vc(),z=u.reader.Vc();u=u.reader.lb(u.reader.getLength()-u.reader.pa());if(v&&v.includes(x)||a.i.dispatchAllEmsgBoxes)"urn:mpeg:dash:event:2012"==x?a.g.ph():(v=(new Map).set("detail",{startTime:F,endTime:F+A/y,schemeIdUri:x,value:z,timescale:y,presentationTimeDelta:B,eventDuration:A,id:D,messageData:u}),v=new Q("emsg",v),v.cancelable=!0,a.g.onEvent(v),v.defaultPrevented||"https://aomedia.org/emsg/ID3"!=x&&"https://developer.apple.com/streaming/emsg-id3"!=
408
+ function vk(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h,k,l,m,n,r;return K(function(p){switch(p.g){case 1:h=d.closedCaptions&&0<d.closedCaptions.size;l=null!=d.emsgSchemeIdUris&&0<d.emsgSchemeIdUris.length||a.i.dispatchAllEmsgBoxes;m=a.i.parsePrftBox&&!a.C;if(l||m)k=new Kf;l&&k.O("emsg",function(u){var v=d.emsgSchemeIdUris;if(0===u.version){var x=u.reader.Vc();var z=u.reader.Vc();var y=u.reader.L();var A=u.reader.L();var B=u.reader.L();var D=u.reader.L();var F=e.startTime+A/y}else y=u.reader.L(),F=u.reader.fc()/
409
+ y+e.timestampOffset,A=F-e.startTime,B=u.reader.L(),D=u.reader.L(),x=u.reader.Vc(),z=u.reader.Vc();u=u.reader.lb(u.reader.getLength()-u.reader.pa());if(v&&v.includes(x)||a.i.dispatchAllEmsgBoxes)"urn:mpeg:dash:event:2012"==x?a.g.ph():(v=(new Map).set("detail",{startTime:F,endTime:F+B/y,schemeIdUri:x,value:z,timescale:y,presentationTimeDelta:A,eventDuration:B,id:D,messageData:u}),v=new Q("emsg",v),v.cancelable=!0,a.g.onEvent(v),v.defaultPrevented||"https://aomedia.org/emsg/ID3"!=x&&"https://developer.apple.com/streaming/emsg-id3"!=
410
410
  x||(x=Ih(u),x.length&&e&&a.g.qh([{cueTime:e.startTime,data:u,frames:x,dts:e.startTime,pts:e.startTime}],0,e.endTime)))});m&&k.O("prft",function(u){if(!a.C&&e.g.timescale){var v=u.reader,x=u.version;v.L();u=v.L();var z=v.L();u=1E3*u+z/Math.pow(2,32)*1E3;0===x?v=v.L():(x=v.L(),v=v.L(),v=x*Math.pow(2,32)+v);u=(new Date((new Date(Date.UTC(1900,0,1,0,0,0))).getTime()+u)).getTime();v=(new Map).set("detail",{wallClockTime:u,programStartDate:new Date(u-v/e.g.timescale*1E3)});v=new Q("prft",v);a.g.onEvent(v);
411
411
  a.C=!0}});(l||m)&&k.parse(f);return C(p,zk(a,b,c),2);case 2:return nf(a.l),n=b.Yc,b.Yc=!1,r=b.qf,b.qf=!1,C(p,a.g.rf(b.type,f),3);case 3:return C(p,Gi(a.g.T,b.type,f,e,d,h,n,r,g),4);case 4:nf(a.l),E(p)}})}function zk(a,b,c){var d,e,f,g;return K(function(h){if(1==h.g){d=Math.max(a.i.bufferBehind,a.m.presentationTimeline.g);e=Bi(a.g.T,b.type);if(null==e)return h.return();f=c-e;g=f-d;return.01>=g?h.return():C(h,a.g.T.remove(b.type,e,e+g),2)}nf(a.l);E(h)})}
412
412
  function qk(a){return a&&a.type==Bc&&("application/cea-608"==a.stream.mimeType||"application/cea-708"==a.stream.mimeType)}
413
413
  function wk(a,b,c,d){var e,f,g,h,k;return K(function(l){switch(l.g){case 1:if(c instanceof uh&&(e=c.g))return l.return(e);f=null;if(b.qa){var m=b.qa;if(m.g.has(c)){var n=m.g.get(c);d&&(n.h=d);m.g.delete(c);f=n.g}else f=null}f||(f=mk(a,c,b.stream,d));g=0;b.X&&(g=b.X.g);b.Ia=f;return C(l,f.promise,2);case 2:h=l.h;b.Ia=null;k=h.data;if(!c.aes128Key){l.B(3);break}return C(l,yk(k,c.aes128Key,g),4);case 4:k=l.h;case 3:return l.return(k)}})}
414
- function mk(a,b,c,d){var e=b instanceof S?b:void 0,f=e?1:0;b=Uj(b.Y(),b.La,b.sa,a.i.retryParameters,d);return a.g.Ob.request(kf,b,{type:f,stream:c,segment:e})}
414
+ function mk(a,b,c,d){var e=b instanceof S?b:void 0,f=e?1:0;b=Uj(b.Y(),b.La,b.sa,a.i.retryParameters,d);return a.g.Nb.request(kf,b,{type:f,stream:c,segment:e})}
415
415
  function jk(a,b,c,d){var e,f;return K(function(g){if(1==g.g)return b.nb=!1,b.Pd=!1,b.pd=0,b.Ec=!0,b.xa=null,b.bc=null,b.X=null,b.qa&&Rj(b.qa),d?(e=a.g.wd(),f=a.g.T.getDuration(),C(g,a.g.T.remove(b.type,e+d,f),3)):C(g,Oi(a.g.T,b.type),4);if(3!=g.g)return nf(a.l),c?C(g,a.g.T.flush(b.type),3):g.B(3);nf(a.l);b.Ec=!1;b.endOfStream=!1;b.ya||b.bb||dk(a,b,0);E(g)})}
416
416
  function dk(a,b,c){var d=b.type;if(d!=Bc||a.h.has(d))b.bb=(new hd(function(){var e;return K(function(f){if(1==f.g)return sa(f,2),C(f,nk(a,b),4);if(2!=f.g)return va(f,0);e=wa(f);if(a.g)a.g.onError(e);E(f)})})).U(c)}function Xj(a){null!=a.bb&&(a.bb.stop(),a.bb=null)}function Yj(a){return K(function(b){return a.Ia?C(b,a.Ia.abort(),0):b.B(0)})}
417
- function pk(a,b,c){var d;return K(function(e){if(1==e.g)return C(e,Ke(a.G),2);nf(a.l);d=0===a.i.maxDisabledTime&&1011==c.code?1:a.i.maxDisabledTime;1===c.category&&0<d&&(c.handled=a.g.fe(b.stream,d),c.handled&&(c.severity=1));a.g.onError(c);c.handled||a.i.failureCallback(c);E(e)})};function Ak(a,b,c){var d,e,f,g;return K(function(h){if(1==h.g){var k=(new fc(a)).Ca.split("/").pop().split(".");d=1==k.length?"":k.pop().toLowerCase();if(e=Bk[d])return h.return(e);f=df([a],c);f.method="HEAD";return C(h,b.request(0,f).promise,2)}g=h.h;e=g.headers["content-type"];return h.return(e?e.toLowerCase().split(";").shift():"")})}
418
- var Bk={mp4:"video/mp4",m4v:"video/mp4",m4a:"audio/mp4",webm:"video/webm",weba:"audio/webm",mkv:"video/webm",ts:"video/mp2t",ogv:"video/ogg",ogg:"audio/ogg",mpg:"video/mpeg",mpeg:"video/mpeg",m3u8:"application/x-mpegurl",mpd:"application/dash+xml",ism:"application/vnd.ms-sstr+xml",mp3:"audio/mpeg",aac:"audio/aac",flac:"audio/flac",wav:"audio/wav",sbv:"text/x-subviewer",srt:"text/srt",vtt:"text/vtt",webvtt:"text/vtt",ttml:"application/ttml+xml",lrc:"application/x-subtitle-lrc",ssa:"text/x-ssa",ass:"text/x-ssa"};function Ck(a){if(a.lineBreak)return"\n";if(a.nestedCues.length)return a.nestedCues.map(Ck).join("");var b=[],c=700<=a.fontWeight,d="italic"==a.fontStyle,e=a.textDecoration.includes("underline");c&&b.push(["b"]);d&&b.push(["i"]);e&&b.push(["u"]);c="";(d=Dk(a.color))&&(c+="."+d);(d=Dk(a.backgroundColor))&&(c+=".bg_"+d);c&&b.push(["c",c]);return b.reduceRight(function(f,g){var h=t(g);g=h.next().value;h=h.next().value;return"<"+g+(void 0===h?"":h)+">"+f+"</"+g+">"},a.payload)}
419
- function Dk(a){switch(a.toLowerCase()){case "white":case "#fff":case "#ffffff":return"white";case "lime":case "#0f0":case "#00ff00":return"lime";case "cyan":case "#0ff":case "#00ffff":return"cyan";case "red":case "#f00":case "#ff0000":return"red";case "yellow":case "#ff0":case "#ffff00":return"yellow";case "magenta":case "#f0f":return"magenta";case "blue":case "#00f":case "#0000ff":return"blue";case "black":case "#000":case "#000000":return"black"}return null}
420
- function Ek(a,b){a=t(a);for(var c=a.next();!c.done;c=a.next())if(c=c.value,c.isContainer)Ek(c.nestedCues,b);else{var d=c.clone();d.nestedCues=[];d.payload=Ck(c);b.push(d)}return b};function Fk(a){this.g=null;for(var b=t(Array.from(a.textTracks)),c=b.next();!c.done;c=b.next())c=c.value,c.mode="disabled","Shaka Player TextTrack"==c.label&&(this.g=c);this.g||(this.g=a.addTextTrack("subtitles","Shaka Player TextTrack"));this.g.mode="hidden"}q=Fk.prototype;q.remove=function(a,b){if(!this.g)return!1;Gk(this.g,function(c){return c.startTime<b&&c.endTime>a});return!0};
421
- q.append=function(a){var b=Ek(a,[]),c=[];a=this.g.cues?Array.from(this.g.cues):[];var d={};b=t(b);for(var e=b.next();!e.done;d={Ub:d.Ub},e=b.next())d.Ub=e.value,a.some(function(f){return function(g){return g.startTime==f.Ub.startTime&&g.endTime==f.Ub.endTime&&g.text==f.Ub.payload?!0:!1}}(d))||(e=Hk(d.Ub))&&c.push(e);a=c.slice().sort(function(f,g){return f.startTime!=g.startTime?f.startTime-g.startTime:f.endTime!=g.endTime?f.endTime-g.startTime:"line"in VTTCue.prototype?c.indexOf(g)-c.indexOf(f):c.indexOf(f)-
417
+ function pk(a,b,c){var d;return K(function(e){if(1==e.g)return C(e,Ke(a.G),2);nf(a.l);d=0===a.i.maxDisabledTime&&1011==c.code?1:a.i.maxDisabledTime;1===c.category&&0<d&&(c.handled=a.g.fe(b.stream,d),c.handled&&(c.severity=1));a.g.onError(c);c.handled||a.i.failureCallback(c);E(e)})};function Ak(a,b,c){var d,e,f,g,h,k,l;return K(function(m){switch(m.g){case 1:var n=(new fc(a)).Ca.split("/").pop().split(".");d=1==n.length?"":n.pop().toLowerCase();if(e=Bk[d])return m.return(e);f=0;g=df([a],c);sa(m,2);g.method="HEAD";return C(m,b.request(f,g).promise,4);case 4:h=m.h;e=h.headers["content-type"];va(m,3);break;case 2:k=wa(m);if(!k||1002!=k.code){m.B(3);break}g.method="GET";return C(m,b.request(f,g).promise,6);case 6:l=m.h,e=l.headers["content-type"];case 3:return m.return(e?e.toLowerCase().split(";").shift():
418
+ "")}})}
419
+ var Bk={mp4:"video/mp4",m4v:"video/mp4",m4a:"audio/mp4",webm:"video/webm",weba:"audio/webm",mkv:"video/webm",ts:"video/mp2t",ogv:"video/ogg",ogg:"audio/ogg",mpg:"video/mpeg",mpeg:"video/mpeg",m3u8:"application/x-mpegurl",mpd:"application/dash+xml",ism:"application/vnd.ms-sstr+xml",mp3:"audio/mpeg",aac:"audio/aac",flac:"audio/flac",wav:"audio/wav",sbv:"text/x-subviewer",srt:"text/srt",vtt:"text/vtt",webvtt:"text/vtt",ttml:"application/ttml+xml",lrc:"application/x-subtitle-lrc",ssa:"text/x-ssa",ass:"text/x-ssa"};function Ck(a,b){if(a.lineBreak)return"\n";if(a.nestedCues.length)return a.nestedCues.map(function(g){return Ck(g,a)}).join("");var c=[],d=700<=a.fontWeight,e="italic"==a.fontStyle,f=a.textDecoration.includes("underline");d&&c.push(["b"]);e&&c.push(["i"]);f&&c.push(["u"]);e=a.color;""==e&&b&&(e=b.color);d="";(e=Dk(e))&&(d+="."+e);e=a.backgroundColor;""==e&&b&&(e=b.backgroundColor);(b=Dk(e))&&(d+=".bg_"+b);d&&c.push(["c",d]);return c.reduceRight(function(g,h){var k=t(h);h=k.next().value;k=k.next().value;
420
+ return"<"+h+(void 0===k?"":k)+">"+g+"</"+h+">"},a.payload)}
421
+ function Dk(a){a=a.toLowerCase();var b=a.replace(/\s/g,"").match(/^rgba?\((\d+),(\d+),(\d+),?([^,\s)]+)?/i);b?a="#"+(parseInt(b[1],10)|256).toString(16).slice(1)+(parseInt(b[2],10)|256).toString(16).slice(1)+(parseInt(b[3],10)|256).toString(16).slice(1):a.startsWith("#")&&7<a.length&&(a=a.slice(0,7));switch(a){case "white":case "#fff":case "#ffffff":return"white";case "lime":case "#0f0":case "#00ff00":return"lime";case "cyan":case "#0ff":case "#00ffff":return"cyan";case "red":case "#f00":case "#ff0000":return"red";
422
+ case "yellow":case "#ff0":case "#ffff00":return"yellow";case "magenta":case "#f0f":case "#ff00ff":return"magenta";case "blue":case "#00f":case "#0000ff":return"blue";case "black":case "#000":case "#000000":return"black"}return null}function Ek(a,b){var c=[];a=t(a);for(var d=a.next();!d.done;d=a.next())if(d=d.value,d.isContainer)c.push.apply(c,w(Ek(d.nestedCues,d)));else{var e=d.clone();e.nestedCues=[];e.payload=Ck(d,b);c.push(e)}return c};function Fk(a,b){this.g=null;for(var c=t(Array.from(a.textTracks)),d=c.next();!d.done;d=c.next())d=d.value,d.mode="disabled",d.label==b&&(this.g=d);this.g||(this.g=a.addTextTrack("subtitles",b));this.g.mode="hidden"}q=Fk.prototype;q.remove=function(a,b){if(!this.g)return!1;Gk(this.g,function(c){return c.startTime<b&&c.endTime>a});return!0};
423
+ q.append=function(a){var b=Ek(a),c=[];a=this.g.cues?Array.from(this.g.cues):[];var d={};b=t(b);for(var e=b.next();!e.done;d={Ub:d.Ub},e=b.next())d.Ub=e.value,a.some(function(f){return function(g){return g.startTime==f.Ub.startTime&&g.endTime==f.Ub.endTime&&g.text==f.Ub.payload?!0:!1}}(d))||(e=Hk(d.Ub))&&c.push(e);a=c.slice().sort(function(f,g){return f.startTime!=g.startTime?f.startTime-g.startTime:f.endTime!=g.endTime?f.endTime-g.startTime:"line"in VTTCue.prototype?c.indexOf(g)-c.indexOf(f):c.indexOf(f)-
422
424
  c.indexOf(g)});a=t(a);for(d=a.next();!d.done;d=a.next())this.g.addCue(d.value)};q.destroy=function(){this.g&&(Gk(this.g,function(){return!0}),this.g.mode="disabled");this.g=null;return Promise.resolve()};q.isTextVisible=function(){return"showing"==this.g.mode};q.setTextVisibility=function(a){this.g.mode=a?"showing":"hidden"};
423
425
  function Hk(a){if(a.startTime>=a.endTime)return null;var b=new VTTCue(a.startTime,a.endTime,a.payload);b.lineAlign=a.lineAlign;b.positionAlign=a.positionAlign;a.size&&(b.size=a.size);try{b.align=a.textAlign}catch(c){}"center"==a.textAlign&&"center"!=b.align&&(b.align="middle");"vertical-lr"==a.writingMode?b.vertical="lr":"vertical-rl"==a.writingMode&&(b.vertical="rl");1==a.lineInterpretation&&(b.snapToLines=!1);null!=a.line&&(b.line=a.line);null!=a.position&&(b.position=a.position);return b}
424
- function Gk(a,b){var c=a.mode;a.mode="showing"==c?"showing":"hidden";for(var d=t(Array.from(a.cues)),e=d.next();!e.done;e=d.next())(e=e.value)&&b(e)&&a.removeCue(e);a.mode=c}N("shaka.text.SimpleTextDisplayer",Fk);Fk.prototype.setTextVisibility=Fk.prototype.setTextVisibility;Fk.prototype.isTextVisible=Fk.prototype.isTextVisible;Fk.prototype.destroy=Fk.prototype.destroy;Fk.prototype.append=Fk.prototype.append;Fk.prototype.remove=Fk.prototype.remove;function Ik(){}q=Ik.prototype;q.remove=function(){};q.append=function(){};q.destroy=function(){};q.isTextVisible=function(){return!1};q.setTextVisibility=function(){};N("shaka.text.StubTextDisplayer",Ik);Ik.prototype.setTextVisibility=Ik.prototype.setTextVisibility;Ik.prototype.isTextVisible=Ik.prototype.isTextVisible;Ik.prototype.destroy=Ik.prototype.destroy;Ik.prototype.append=Ik.prototype.append;Ik.prototype.remove=Ik.prototype.remove;function Jk(){}function Kk(a){for(;a.firstChild;)a.removeChild(a.firstChild)}N("shaka.util.Dom",Jk);Jk.removeAllChildren=Kk;function Lk(a,b){var c=this;this.l=!1;this.i=[];this.A=a;this.o=b;this.u=null;this.g=document.createElement("div");this.g.classList.add("shaka-text-container");this.g.style.textAlign="center";this.g.style.display="flex";this.g.style.flexDirection="column";this.g.style.alignItems="center";this.g.style.justifyContent="flex-end";this.o.appendChild(this.g);this.C=(new id(function(){Mk(c)})).Ua(.25);this.h=new Map;this.j=new of;this.j.D(document,"fullscreenchange",function(){Mk(c,!0)});this.j.D(this.A,
425
- "resize",function(){var d=c.A,e=d.videoWidth;d=d.videoHeight;e&&d?c.u=e/d:c.u=null});this.m=null;"ResizeObserver"in window&&(this.m=new ResizeObserver(function(){Mk(c,!0)}),this.m.observe(this.g));this.s=new Map}q=Lk.prototype;q.append=function(a){var b=[].concat(w(this.i)),c={};a=t(a);for(var d=a.next();!d.done;c={cd:c.cd},d=a.next())c.cd=d.value,b.some(function(e){return function(f){return Nb(f,e.cd)}}(c))||this.i.push(c.cd);Mk(this)};
426
- q.destroy=function(){this.o.removeChild(this.g);this.g=null;this.l=!1;this.i=[];this.C&&this.C.stop();this.h.clear();this.j&&(this.j.release(),this.j=null);this.m&&(this.m.disconnect(),this.m=null)};q.remove=function(a,b){if(!this.g)return!1;var c=this.i.length;this.i=this.i.filter(function(d){return d.startTime<a||d.endTime>=b});Mk(this,c>this.i.length);return!0};q.isTextVisible=function(){return this.l};q.setTextVisibility=function(a){this.l=a};
426
+ function Gk(a,b){var c=a.mode;a.mode="showing"==c?"showing":"hidden";for(var d=t(Array.from(a.cues)),e=d.next();!e.done;e=d.next())(e=e.value)&&b(e)&&a.removeCue(e);a.mode=c}N("shaka.text.SimpleTextDisplayer",Fk);Fk.prototype.setTextVisibility=Fk.prototype.setTextVisibility;Fk.prototype.isTextVisible=Fk.prototype.isTextVisible;Fk.prototype.destroy=Fk.prototype.destroy;Fk.prototype.append=Fk.prototype.append;Fk.prototype.remove=Fk.prototype.remove;function Ik(){}q=Ik.prototype;q.remove=function(){};q.append=function(){};q.destroy=function(){};q.isTextVisible=function(){return!1};q.setTextVisibility=function(){};N("shaka.text.StubTextDisplayer",Ik);Ik.prototype.setTextVisibility=Ik.prototype.setTextVisibility;Ik.prototype.isTextVisible=Ik.prototype.isTextVisible;Ik.prototype.destroy=Ik.prototype.destroy;Ik.prototype.append=Ik.prototype.append;Ik.prototype.remove=Ik.prototype.remove;function Jk(){}function Kk(a){for(;a.firstChild;)a.removeChild(a.firstChild)}N("shaka.util.Dom",Jk);Jk.removeAllChildren=Kk;function Lk(a,b){var c=this;this.m=!1;this.i=[];this.A=a;this.s=b;this.j=null;this.g=document.createElement("div");this.g.classList.add("shaka-text-container");this.g.style.textAlign="center";this.g.style.display="flex";this.g.style.flexDirection="column";this.g.style.alignItems="center";this.g.style.justifyContent="flex-end";this.s.appendChild(this.g);this.C=(new id(function(){Mk(c)})).Ua(.25);this.h=new Map;this.l=new of;this.l.D(document,"fullscreenchange",function(){Mk(c,!0)});this.l.D(this.A,
427
+ "resize",function(){var d=c.A,e=d.videoWidth;d=d.videoHeight;e&&d?c.j=e/d:c.j=null});this.o=null;"ResizeObserver"in window&&(this.o=new ResizeObserver(function(){Mk(c,!0)}),this.o.observe(this.g));this.u=new Map}q=Lk.prototype;q.append=function(a){var b=[].concat(w(this.i)),c={};a=t(a);for(var d=a.next();!d.done;c={cd:c.cd},d=a.next())c.cd=d.value,b.some(function(e){return function(f){return Nb(f,e.cd)}}(c))||this.i.push(c.cd);Mk(this)};
428
+ q.destroy=function(){this.s.removeChild(this.g);this.g=null;this.m=!1;this.i=[];this.C&&this.C.stop();this.h.clear();this.l&&(this.l.release(),this.l=null);this.o&&(this.o.disconnect(),this.o=null)};q.remove=function(a,b){if(!this.g)return!1;var c=this.i.length;this.i=this.i.filter(function(d){return d.startTime<a||d.endTime>=b});Mk(this,c>this.i.length);return!0};q.isTextVisible=function(){return this.m};q.setTextVisibility=function(a){this.m=a};
427
429
  function Nk(a,b){for(;null!=b;){if(b==a.g)return!0;b=b.parentElement}return!1}
428
430
  function Ok(a,b,c,d,e){var f=!1,g=[],h=[];b=t(b);for(var k=b.next();!k.done;k=b.next()){k=k.value;e.push(k);var l=a.h.get(k),m=k.startTime<=d&&k.endTime>d,n=l?l.ig:null;l&&(g.push(l.ee),l.Wc&&g.push(l.Wc),m||(f=!0,a.h.delete(k),l=null));m&&(h.push(k),l?Nk(a,n)||(f=!0):(Pk(a,k,e),l=a.h.get(k),n=l.ig,f=!0));0<k.nestedCues.length&&n&&Ok(a,k.nestedCues,n,d,e);e.pop()}if(f){d=t(g);for(e=d.next();!e.done;e=d.next())e=e.value,e.parentElement&&e.parentElement.removeChild(e);h.sort(function(r,p){return r.startTime!=
429
- p.startTime?r.startTime-p.startTime:r.endTime-p.endTime});h=t(h);for(k=h.next();!k.done;k=h.next())d=a.h.get(k.value),d.Wc?(c.appendChild(d.Wc),d.Wc.appendChild(d.ee)):c.appendChild(d.ee)}}function Mk(a,b){if(a.g){var c=a.A.currentTime;if(!a.l||(void 0===b?0:b)){b=t(a.s.values());for(var d=b.next();!d.done;d=b.next())Kk(d.value);Kk(a.g);a.h.clear();a.s.clear()}if(a.l){b=new Map;d=t(a.h.keys());for(var e=d.next();!e.done;e=d.next())e=e.value,b.set(e,a.h.get(e));Ok(a,a.i,a.g,c,[])}}}
430
- function Pk(a,b,c){var d=1<c.length,e=d?"span":"div";b.lineBreak&&(e="br");b.rubyTag&&(e=b.rubyTag);d=!d&&0<b.nestedCues.length;var f=document.createElement(e);"br"!=e&&Qk(a,f,b,c,d);c=null;if(b.region&&b.region.id){c=b.region;e=a.u===4/3?2.5:1.9;var g=c.id+"_"+c.width+"x"+c.height+(c.heightUnits==Vb?"%":"px")+"-"+c.viewportAnchorX+"x"+c.viewportAnchorY+(c.viewportAnchorUnits==Vb?"%":"px");if(a.s.has(g))c=a.s.get(g);else{var h=document.createElement("span"),k=c.heightUnits==Vb?"%":"px",l=c.widthUnits==
431
- Vb?"%":"px",m=c.viewportAnchorUnits==Vb?"%":"px";h.id="shaka-text-region---"+g;h.classList.add("shaka-text-region");h.style.position="absolute";2===c.heightUnits&&2===c.widthUnits?(h.style.height=5.33*c.height+"%",h.style.width=c.width*e+"%"):(h.style.height=c.height+k,h.style.width=c.width+l);2===c.viewportAnchorUnits?(k=c.viewportAnchorY/75*100,l=c.viewportAnchorX/(a.u===4/3?160:210)*100,k-=c.regionAnchorY*c.height*5.33/100,l-=c.regionAnchorX*c.width*e/100,h.style.top=k+"%",h.style.left=l+"%"):
432
- (h.style.top=c.viewportAnchorY-c.regionAnchorY*c.height/100+m,h.style.left=c.viewportAnchorX-c.regionAnchorX*c.width/100+m);h.style.display="flex";h.style.flexDirection="column";h.style.alignItems="center";h.style.justifyContent="before"==b.displayAlign?"flex-start":"center"==b.displayAlign?"center":"flex-end";a.s.set(g,h);c=h}}e=f;d&&(e=document.createElement("span"),e.classList.add("shaka-text-wrapper"),e.style.backgroundColor=b.backgroundColor,e.style.lineHeight="normal",f.appendChild(e));a.h.set(b,
431
+ p.startTime?r.startTime-p.startTime:r.endTime-p.endTime});h=t(h);for(k=h.next();!k.done;k=h.next())d=a.h.get(k.value),d.Wc?(c.appendChild(d.Wc),d.Wc.appendChild(d.ee)):c.appendChild(d.ee)}}function Mk(a,b){if(a.g){var c=a.A.currentTime;if(!a.m||(void 0===b?0:b)){b=t(a.u.values());for(var d=b.next();!d.done;d=b.next())Kk(d.value);Kk(a.g);a.h.clear();a.u.clear()}if(a.m){b=new Map;d=t(a.h.keys());for(var e=d.next();!e.done;e=d.next())e=e.value,b.set(e,a.h.get(e));Ok(a,a.i,a.g,c,[])}}}
432
+ function Pk(a,b,c){var d=1<c.length,e=d?"span":"div";b.lineBreak&&(e="br");b.rubyTag&&(e=b.rubyTag);d=!d&&0<b.nestedCues.length;var f=document.createElement(e);"br"!=e&&Qk(a,f,b,c,d);c=null;if(b.region&&b.region.id){c=b.region;e=a.j===4/3?2.5:1.9;var g=c.id+"_"+c.width+"x"+c.height+(c.heightUnits==Vb?"%":"px")+"-"+c.viewportAnchorX+"x"+c.viewportAnchorY+(c.viewportAnchorUnits==Vb?"%":"px");if(a.u.has(g))c=a.u.get(g);else{var h=document.createElement("span"),k=c.heightUnits==Vb?"%":"px",l=c.widthUnits==
433
+ Vb?"%":"px",m=c.viewportAnchorUnits==Vb?"%":"px";h.id="shaka-text-region---"+g;h.classList.add("shaka-text-region");h.style.position="absolute";2===c.heightUnits&&2===c.widthUnits?(h.style.height=5.33*c.height+"%",h.style.width=c.width*e+"%"):(h.style.height=c.height+k,h.style.width=c.width+l);2===c.viewportAnchorUnits?(k=c.viewportAnchorY/75*100,l=c.viewportAnchorX/(a.j===4/3?160:210)*100,k-=c.regionAnchorY*c.height*5.33/100,l-=c.regionAnchorX*c.width*e/100,h.style.top=k+"%",h.style.left=l+"%"):
434
+ (h.style.top=c.viewportAnchorY-c.regionAnchorY*c.height/100+m,h.style.left=c.viewportAnchorX-c.regionAnchorX*c.width/100+m);h.style.display="flex";h.style.flexDirection="column";h.style.alignItems="center";h.style.justifyContent="before"==b.displayAlign?"flex-start":"center"==b.displayAlign?"center":"flex-end";a.u.set(g,h);c=h}}e=f;d&&(e=document.createElement("span"),e.classList.add("shaka-text-wrapper"),e.style.backgroundColor=b.backgroundColor,e.style.lineHeight="normal",f.appendChild(e));a.h.set(b,
433
435
  {ee:f,ig:e,Wc:c})}function Rk(a){var b=a.direction,c=a.positionAlign;a=a.textAlign;return c!==Db?c:"left"===a||"start"===a&&b===Fb||"end"===a&&"rtl"===b?"line-left":"right"===a||"start"===a&&"rtl"===b||"end"===a&&b===Fb?"line-right":"center"}
434
- 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=Sk(c.linePadding,c,a.o);f.paddingRight=Sk(c.linePadding,c,a.o);f.textCombineUpright=c.textCombineUpright;f.textShadow=c.textShadow;if(c.backgroundImage)f.backgroundImage=
436
+ 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=Sk(c.linePadding,c,a.s);f.paddingRight=Sk(c.linePadding,c,a.s);f.textCombineUpright=c.textCombineUpright;f.textShadow=c.textShadow;if(c.backgroundImage)f.backgroundImage=
435
437
  "url('"+c.backgroundImage+"')",f.backgroundRepeat="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=Tk(d,function(m){return m.backgroundColor}))?l.style.backgroundColor=b:k&&(l.style.backgroundColor="rgba(0, 0, 0, 0.8)"),b=Tk(d,function(m){return m.fontFamily}))&&(l.style.fontFamily=b);k&&(l.textContent=k)}h&&!d[d.length-
436
- 1].isContainer?f.display="inline":(f.display="flex",f.flexDirection="column",f.alignItems="center",f.justifyContent="before"==c.displayAlign?"flex-start":"center"==c.displayAlign?"center":"flex-end");g||(f.margin="0");f.fontFamily=c.fontFamily;f.fontWeight=c.fontWeight.toString();f.fontStyle=c.fontStyle;f.letterSpacing=c.letterSpacing;f.fontSize=Sk(c.fontSize,c,a.o);null!=c.line&&(a=c.lineInterpretation,0==c.line&&a==Hb&&(a=1),1==a&&(f.position="absolute",c.writingMode==Gb?(f.width="100%",c.lineAlign==
437
- Ib?f.top=c.line+"%":"end"==c.lineAlign&&(f.bottom=100-c.line+"%")):"vertical-lr"==c.writingMode?(f.height="100%",c.lineAlign==Ib?f.left=c.line+"%":"end"==c.lineAlign&&(f.right=100-c.line+"%")):(f.height="100%",c.lineAlign==Ib?f.right=c.line+"%":"end"==c.lineAlign&&(f.left=100-c.line+"%"))));f.lineHeight=c.lineHeight;null!=c.position&&(c.writingMode==Gb?f.paddingLeft=c.position:f.paddingTop=c.position);a=Rk(c);"line-left"==a?f.cssFloat="left":"line-right"==a&&(f.cssFloat="right");f.textAlign=c.textAlign;
438
- f.textDecoration=c.textDecoration.join(" ");f.writingMode=c.writingMode;"writingMode"in document.documentElement.style&&f.writingMode==c.writingMode||(f.webkitWritingMode=c.writingMode);c.size&&(c.writingMode==Gb?f.width=c.size+"%":f.height=c.size+"%")}
438
+ 1].isContainer?f.display="inline":(f.display="flex",f.flexDirection="column",f.alignItems="center",f.justifyContent="before"==c.displayAlign?"flex-start":"center"==c.displayAlign?"center":"flex-end");g||(f.margin="0");f.fontFamily=c.fontFamily;f.fontWeight=c.fontWeight.toString();f.fontStyle=c.fontStyle;f.letterSpacing=c.letterSpacing;f.fontSize=Sk(c.fontSize,c,a.s);d=c.line;null!=d&&(g=c.lineInterpretation,g==Hb&&(g=1,h=16,a.j&&1>a.j&&(h=32),d=0>d?100+d/h*100:d/h*100),1==g&&(f.position="absolute",
439
+ c.writingMode==Gb?(f.width="100%",c.lineAlign==Ib?f.top=d+"%":"end"==c.lineAlign&&(f.bottom=100-d+"%")):"vertical-lr"==c.writingMode?(f.height="100%",c.lineAlign==Ib?f.left=d+"%":"end"==c.lineAlign&&(f.right=100-d+"%")):(f.height="100%",c.lineAlign==Ib?f.right=d+"%":"end"==c.lineAlign&&(f.left=100-d+"%"))));f.lineHeight=c.lineHeight;null!=c.position&&(c.writingMode==Gb?f.paddingLeft=c.position:f.paddingTop=c.position);a=Rk(c);"line-left"==a?f.cssFloat="left":"line-right"==a&&(f.cssFloat="right");
440
+ f.textAlign=c.textAlign;f.textDecoration=c.textDecoration.join(" ");f.writingMode=c.writingMode;"writingMode"in document.documentElement.style&&f.writingMode==c.writingMode||(f.webkitWritingMode=c.writingMode);c.size&&(c.writingMode==Gb?f.width=c.size+"%":f.height=c.size+"%")}
439
441
  function Sk(a,b,c){var d=(d=(new RegExp(/(\d*\.?\d+)([a-z]+|%+)/)).exec(a))?{value:Number(d[1]),unit:d[2]}:null;if(!d)return a;var e=d.value;switch(d.unit){case "%":return e/100*c.clientHeight/b.cellResolution.rows+"px";case "c":return c.clientHeight*e/b.cellResolution.rows+"px";default:return a}}function Tk(a,b){for(var c=a.length-1;0<=c;c--){var d=b(a[c]);if(d||0===d)return d}return null}N("shaka.text.UITextDisplayer",Lk);Lk.prototype.setTextVisibility=Lk.prototype.setTextVisibility;
440
- 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 Uk(a,b){function c(f){for(var g=f,h=t(b),k=h.next();!k.done;k=h.next())k=k.value,k.end&&k.start<f&&(g+=k.end-k.start);f=Math.floor(g/3600);h=Math.floor(g/60%60);k=Math.floor(g%60);g=Math.floor(1E3*g%1E3);return(10>f?"0":"")+f+":"+(10>h?"0":"")+h+":"+(10>k?"0":"")+k+"."+(100>g?10>g?"00":"0":"")+g}var d=Ek(a,[]);a="WEBVTT\n\n";d=t(d);for(var e=d.next();!e.done;e=d.next())e=e.value,a+=c(e.startTime)+" --\x3e "+c(e.endTime)+function(f){var g=[];switch(f.textAlign){case "left":g.push("align:left");
442
+ 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 Uk(a,b){function c(f){for(var g=f,h=t(b),k=h.next();!k.done;k=h.next())k=k.value,k.end&&k.start<f&&(g+=k.end-k.start);f=Math.floor(g/3600);h=Math.floor(g/60%60);k=Math.floor(g%60);g=Math.floor(1E3*g%1E3);return(10>f?"0":"")+f+":"+(10>h?"0":"")+h+":"+(10>k?"0":"")+k+"."+(100>g?10>g?"00":"0":"")+g}var d=Ek(a);a="WEBVTT\n\n";d=t(d);for(var e=d.next();!e.done;e=d.next())e=e.value,a+=c(e.startTime)+" --\x3e "+c(e.endTime)+function(f){var g=[];switch(f.textAlign){case "left":g.push("align:left");
441
443
  break;case "right":g.push("align:right");break;case Eb:g.push("align:middle");break;case "start":g.push("align:start");break;case "end":g.push("align:end")}switch(f.writingMode){case "vertical-lr":g.push("vertical:lr");break;case "vertical-rl":g.push("vertical:rl")}return g.length?" "+g.join(" "):""}(e)+"\n",a+=e.payload+"\n\n";return a}N("shaka.text.WebVttGenerator",function(){});function Vk(a,b){this.h=a;this.g=b;this.j="";this.o=void 0;this.i=!1;this.m=!0;this.l=!1}Vk.prototype.configure=function(a){this.g=a};
442
444
  function Wk(a,b,c){try{if(!a.g.enabled)return b;var d=Xk(a);a:{switch(c.toLowerCase()){case "video/webm":case "video/mp4":case "video/mpeg":case "video/mp2t":var e=Yk;break a;case "application/x-mpegurl":case "application/vnd.apple.mpegurl":case "application/dash+xml":case "video/vnd.mpeg.dash.mpd":e=Zk;break a}e=void 0}d.ot=e;d.su=!0;var f=$k(d);return al(b,f)}catch(g){return Ua("CMCD_SRC_ERROR","Could not generate src CMCD data.",g),b}}
443
445
  function Xk(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 bl(a,b,c){c=void 0===c?{}:c;var d=void 0===d?a.g.useHeaders:d;if(a.g.enabled){Object.assign(c,Xk(a));c.pr=a.h.vd();var e=c.ot===cl||c.ot===Yk;a.l&&e&&(c.bs=!0,c.su=!0,a.l=!1);null==c.su&&(c.su=a.m);if(d)a=dl(c),Object.keys(a).length&&Object.assign(b.headers,a);else{var f=$k(c);f&&(b.uris=b.uris.map(function(g){return al(g,f)}))}}}
@@ -464,10 +466,10 @@ sourceBufferExtraFeatures:"",forceTransmux:!1,insertFakeEncryptionInInit:!0},off
464
466
  maxHeight:Infinity,minPixels:0,maxPixels:Infinity,minFrameRate:0,maxFrameRate:Infinity,minBandwidth:0,maxBandwidth:Infinity},playRangeStart:0,playRangeEnd:Infinity,textDisplayFactory:function(){return null},cmcd:{enabled:!1,sessionId:"",contentId:"",useHeaders:!1},lcevc:{enabled:!1,dynamicPerformanceScaling:!0,logLevel:0,drawLogo:!1},ads:{customPlayheadTracker:!1}};e.trackSelectionCallback=function(h){return K(function(k){return k.return(Bl(h,g.preferredAudioLanguage,g.preferredVideoHdrLevel))})};
465
467
  return g}function Cl(a,b,c){var d={".drm.keySystemsMapping":"",".drm.servers":"",".drm.clearKeys":"",".drm.advanced":{distinctiveIdentifierRequired:!1,persistentStateRequired:!1,videoRobustness:"",audioRobustness:"",sessionType:"",serverCertificate:new Uint8Array(0),serverCertificateUri:"",individualizationServer:""}};return pl(a,b,c||Al(),d,"")}
466
468
  function Bl(a,b,c){var d=c;"AUTO"==d&&(d=window.matchMedia("(color-gamut: p3)").matches?"PQ":"SDR");var e=a.filter(function(h){return"variant"!=h.type||h.hdr&&h.hdr!=d?!1:!0});c=[];var f=fd(b,e.map(function(h){return h.language}));f&&(c=e.filter(function(h){return Zc(h.language)==f}));0==c.length&&(c=e.filter(function(h){return h.primary}));0==c.length&&(e.map(function(h){return h.language}),c=e);var g=c.filter(function(h){return h.height&&480>=h.height});g.length&&(g.sort(function(h,k){return k.height-
467
- h.height}),c=g.filter(function(h){return h.height==g[0].height}));b=[];c.length&&(e=Math.floor(c.length/2),c.sort(function(h,k){return h.bandwidth-k.bandwidth}),b.push(c[e]));a=t(a);for(c=a.next();!c.done;c=a.next())c=c.value,c.type!=Bc&&"image"!=c.type||b.push(c);return b}N("shaka.util.PlayerConfiguration",zl);zl.mergeConfigObjects=Cl;zl.createDefault=Al;function Dl(){this.g=null;this.h=[]}function El(a,b){var c=0;a.g&&a.g.state==b&&(c+=a.g.duration);a=t(a.h);for(var d=a.next();!d.done;d=a.next())d=d.value,c+=d.state==b?d.duration:0;return c}function Fl(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 Gl(){this.i=this.h=null;this.g=[]}function Hl(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 Il(){this.u=this.A=this.G=this.C=this.s=this.j=this.F=this.m=this.i=this.K=this.N=this.H=this.I=this.J=this.l=this.o=NaN;this.g=new Dl;this.h=new Gl};function W(a,b){Ve.call(this);var c=this;this.l=Jl;this.ld=this.g=null;this.$=!1;this.sd=new of;this.rb=new of;this.m=new of;this.C=this.G=this.o=this.H=null;this.td=0;this.W=new sl;this.la=this.da=this.i=this.zd=this.F=this.j=this.ma=this.J=this.Lf=this.V=this.va=this.K=this.I=this.cb=null;this.Dc=!1;this.Ae=this.s=null;this.Ge=1E9;this.Bc=[];this.N=NaN;this.h=Kl(this);this.Fe={width:Infinity,height:Infinity};this.u=null;this.Ba=new we(this.h.preferredAudioLanguage,this.h.preferredVariantRole,this.h.preferredAudioChannelCount,
469
+ h.height}),c=g.filter(function(h){return h.height==g[0].height}));b=[];c.length&&(e=Math.floor(c.length/2),c.sort(function(h,k){return h.bandwidth-k.bandwidth}),b.push(c[e]));a=t(a);for(c=a.next();!c.done;c=a.next())c=c.value,c.type!=Bc&&"image"!=c.type||b.push(c);return b}N("shaka.util.PlayerConfiguration",zl);zl.mergeConfigObjects=Cl;zl.createDefault=Al;function Dl(){this.g=null;this.h=[]}function El(a,b){var c=0;a.g&&a.g.state==b&&(c+=a.g.duration);a=t(a.h);for(var d=a.next();!d.done;d=a.next())d=d.value,c+=d.state==b?d.duration:0;return c}function Fl(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 Gl(){this.i=this.h=null;this.g=[]}function Hl(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 Il(){this.u=this.A=this.G=this.C=this.s=this.j=this.F=this.m=this.i=this.K=this.N=this.H=this.I=this.J=this.l=this.o=NaN;this.g=new Dl;this.h=new Gl};function V(a,b){Ve.call(this);var c=this;this.l=Jl;this.ld=this.g=null;this.$=!1;this.sd=new of;this.rb=new of;this.m=new of;this.C=this.G=this.o=this.H=null;this.td=0;this.W=new sl;this.la=this.da=this.i=this.zd=this.F=this.j=this.ma=this.J=this.Lf=this.V=this.va=this.K=this.I=this.cb=null;this.Dc=!1;this.Ae=this.s=null;this.Ge=1E9;this.Bc=[];this.N=NaN;this.h=Kl(this);this.Fe={width:Infinity,height:Infinity};this.u=null;this.Ba=new we(this.h.preferredAudioLanguage,this.h.preferredVariantRole,this.h.preferredAudioChannelCount,
468
470
  this.h.preferredVideoHdrLevel,this.h.preferredVideoLayout,this.h.preferredAudioLabel,this.h.mediaSource.codecSwitchingStrategy,this.h.manifest.dash.enableAudioGroups);this.Wa=this.h.preferredTextLanguage;this.kc=this.h.preferredTextRole;this.Ac=this.h.preferForcedSubs;this.sb=[];b&&b(this);this.V=Ll(this);this.H=Ml(this);this.H.cf(this.h.streaming.forceHTTPS);this.A=null;Nl&&(this.A=Nl());this.sd.D(window,"online",function(){Ol(c);c.Ye()});this.qd=new id(function(){return Pl(c)});a&&(le("Player",
469
- "Please migrate from initializing Player with a mediaElement; use the attach method instead."),this.Cc(a,!0))}oa(W,Ve);function Ql(a){null!=a.J&&(ki(a.J),a.J.release(),a.J=null)}
470
- function Rl(a,b){if(b.lcevc.enabled){var c=a.wb();c&&c[0]&&"video/mp2t"==c[0].videoMimeType&&(md()||navigator.userAgent.match(/Edge\//))&&(b.mediaSource.forceTransmux||Ta("LCEVC Warning: For MPEG-2 TS decoding the config.mediaSource.forceTransmux must be enabled."));Ql(a);null==a.J&&(a.J=new ji(a.g,a.Lf,b.lcevc),a.G&&(a.G.N=a.J))}else Ql(a)}function Sl(a,b){return new Q(a,b)}q=W.prototype;
471
+ "Please migrate from initializing Player with a mediaElement; use the attach method instead."),this.Cc(a,!0))}oa(V,Ve);function Ql(a){null!=a.J&&(ki(a.J),a.J.release(),a.J=null)}
472
+ function Rl(a,b){if(b.lcevc.enabled){var c=a.wb();c&&c[0]&&"video/mp2t"==c[0].videoMimeType&&(md()||navigator.userAgent.match(/Edge\//))&&(b.mediaSource.forceTransmux||Ta("LCEVC Warning: For MPEG-2 TS decoding the config.mediaSource.forceTransmux must be enabled."));Ql(a);null==a.J&&(a.J=new ji(a.g,a.Lf,b.lcevc),a.G&&(a.G.N=a.J))}else Ql(a)}function Sl(a,b){return new Q(a,b)}q=V.prototype;
471
473
  q.destroy=function(){var a=this,b;return K(function(c){switch(c.g){case 1:if(a.l==Tl)return c.return();Ql(a);b=a.detach();a.l=Tl;return C(c,b,2);case 2:a.sd&&(a.sd.release(),a.sd=null);a.rb&&(a.rb.release(),a.rb=null);a.m&&(a.m.release(),a.m=null);a.Ae=null;a.h=null;a.u=null;a.ld=null;a.V=null;if(!a.H){c.B(3);break}return C(c,a.H.destroy(),4);case 4:a.H=null;case 3:a.s&&(a.s.release(),a.s=null),Ve.prototype.release.call(a),E(c)}})};
472
474
  function Ul(a,b){a.dispatchEvent(Sl("onstatechange",(new Map).set("state",b)))}
473
475
  q.Cc=function(a,b){b=void 0===b?!0:b;var c=this,d,e;return K(function(f){switch(f.g){case 1:if(c.l==Tl)throw new O(2,7,7E3);if(!c.g||c.g==a){f.B(2);break}return C(f,c.detach(),2);case 2:return C(f,Vl(c,"attach"),4);case 4:if(f.h)return f.return();sa(f,5,6);Ul(c,"attach");d=function(){var g=Wl(c);g&&Xl(c,g)};c.rb.D(a,"error",d);c.g=a;if(!b||!jd()||c.G){f.B(6);break}return C(f,Yl(c),6);case 6:xa(f);c.W.release();ya(f,0);break;case 5:return e=wa(f),C(f,c.detach(),10);case 10:throw e;}})};
@@ -481,24 +483,24 @@ d.la=b;d.Dc=!1;d.dispatchEvent(Sl("loading"));h=Date.now()/1E3;d.u=new Il;d.da=a
481
483
  cm(d,c),0)})},"parseManifestInner_"),13);case 13:return C(m,g(function(){return K(function(n){return C(n,dm(d),0)})},"initializeDrmInner_"),14);case 14:return C(m,g(function(){return K(function(n){return C(n,em(d,h),0)})},"loadInner_"),10);case 16:return C(m,g(function(){return K(function(n){return C(n,fm(d,h,c),0)})},"srcEqualsInner_"),10);case 10:d.dispatchEvent(Sl("loaded"));va(m,0);break;case 5:l=wa(m);if(7E3==l.code){m.B(18);break}return C(m,d.jc(!1),18);case 18:throw l;}})};
482
484
  function $l(a){var b,c;return K(function(d){if(1==d.g)return b=a.h.manifest.retryParameters,C(d,Ak(a.da,a.H,b),2);c=d.h;"application/x-mpegurl"==c&&td()&&(c="application/vnd.apple.mpegurl");return d.return(c)})}function am(a,b){if(!jd())return!0;if(b){if(""==(a.g||ld()).canPlayType(b))return!1;if(!(jd()&&b in ph))return!0;if("application/x-mpegurl"===b||"application/vnd.apple.mpegurl"===b){if(a.h.streaming.preferNativeHls)return!0;if(td())return a.h.streaming.useNativeHlsOnSafari}}return!1}
483
485
  function Yl(a){var b,c,d,e,f;return K(function(g){if(1==g.g)return Ul(a,"media-source"),b=a.h.textDisplayFactory,c=b(),a.Ee=b,d=gm(a.g,c,function(h,k,l){hm(a,h,k,l)},a.J),d.configure(a.h.mediaSource),e=a.h.manifest,f=e.segmentRelativeVttTiming,d.W=f,C(g,d.J,2);a.G=d;E(g)})}
484
- function cm(a,b){var c,d,e,f,g,h,k,l;return K(function(m){if(1==m.g)return c=a.H,Ul(a,"manifest-parser"),a.zd=oh(a.da,b||null),a.F=a.zd(),d=We(a.h.manifest),a.g&&"AUDIO"===a.g.nodeName&&(d.disableVideo=!0),a.F.configure(d),a.va=new Gj(function(){return a.Ab()}),a.va.addEventListener("regionadd",function(n){n=n.region;im(a,"timelineregionadded",n);if(a.A)a.A.onDashTimedMetadata(n)}),a.ma=null,a.h.streaming.observeQualityChanges&&(a.ma=new Cj(function(){return a.gb()}),a.ma.addEventListener("qualitychange",
486
+ function cm(a,b){var c,d,e,f,g,h,k,l;return K(function(m){if(1==m.g)return c=a.H,Ul(a,"manifest-parser"),a.zd=oh(a.da,b||null),a.F=a.zd(),d=We(a.h.manifest),a.g&&"AUDIO"===a.g.nodeName&&(d.disableVideo=!0),a.F.configure(d),a.va=new Gj(function(){return a.Pb()}),a.va.addEventListener("regionadd",function(n){n=n.region;im(a,"timelineregionadded",n);if(a.A)a.A.onDashTimedMetadata(n)}),a.ma=null,a.h.streaming.observeQualityChanges&&(a.ma=new Cj(function(){return a.gb()}),a.ma.addEventListener("qualitychange",
485
487
  function(n){var r=n.quality;n=n.position;r=(new Map).set("mediaQuality",{bandwidth:r.bandwidth,audioSamplingRate:r.audioSamplingRate,codecs:r.codecs,contentType:r.contentType,frameRate:r.frameRate,height:r.height,mimeType:r.mimeType,channelsCount:r.channelsCount,pixelAspectRatio:r.pixelAspectRatio,width:r.width}).set("position",n);a.dispatchEvent(Sl("mediaqualitychanged",r))})),e={networkingEngine:c,filter:function(n){return jm(a,n)},makeTextStreamsForClosedCaptions:function(n){return km(a,n)},onTimelineRegionAdded:function(n){var r=
486
488
  a.va;a:{var p=t(r.g);for(var u=p.next();!u.done;u=p.next())if(u=u.value,u.schemeIdUri==n.schemeIdUri&&u.id==n.id&&u.startTime==n.startTime&&u.endTime==n.endTime){p=u;break a}p=null}null==p&&(r.g.add(n),n=new Q("regionadd",new Map([["region",n]])),r.dispatchEvent(n))},onEvent:function(n){return a.dispatchEvent(n)},onError:function(n){return Xl(a,n)},isLowLatencyMode:function(){return a.h.streaming.lowLatencyMode},isAutoLowLatencyMode:function(){return a.h.streaming.autoLowLatencyMode},enableLowLatencyMode:function(){a.configure("streaming.lowLatencyMode",
487
489
  !0)},updateDuration:function(){a.j&&a.j.updateDuration()},newDrmInfo:function(n){var r=a.o?a.o.g:null;r&&a.o.s&&lm(a,r.keySystem,n)},onManifestUpdated:function(){var n=(new Map).set("isLive",a.S());a.dispatchEvent(Sl("manifestupdated",n));if(a.A)a.A.onManifestUpdated(a.S())},getBandwidthEstimate:function(){return a.s.getBandwidthEstimate()}},f=Date.now()/1E3,Ul(a,"manifest"),g=a,C(m,a.F.start(a.da,e),2);g.i=m.h;h=Sl("manifestparsed");a.dispatchEvent(h);if(0==a.i.variants.length)throw new O(2,4,4036);
488
- mm(a.i);k=Date.now()/1E3;l=k-f;a.u.F=l;E(m)})}function dm(a){var b,c;return K(function(d){return 1==d.g?(Ul(a,"drm-engine"),b=Date.now()/1E3,c=!0,a.o=nm(a,{Ob:a.H,onError:function(e){Xl(a,e)},Kd:function(e){om(a,e)},onExpirationUpdated:function(e,f){pm(a,e,f)},onEvent:function(e){a.dispatchEvent(e);"drmsessionupdate"==e.type&&c&&(c=!1,a.u.j=Date.now()/1E3-b,a.J&&ki(a.J))}}),a.o.configure(a.h.drm),C(d,Fg(a.o,a.i.variants,a.i.offlineSessionIds),2)):3!=d.g?C(d,a.o.Cc(a.g),3):C(d,jm(a,a.i),0)})}
489
- function em(a,b){var c,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,B,A;return K(function(D){switch(D.g){case 1:Ul(a,"load");c=a.g;a.I=new zj({xd:function(){return c.playbackRate},Ic:function(){return c.defaultPlaybackRate},ef:function(F){c.playbackRate=F},Pf:function(F){c.currentTime+=F}});d=function(){return qm(a)};e=function(){return rm(a)};a.m.D(c,"playing",d);a.m.D(c,"pause",d);a.m.D(c,"ended",d);a.m.D(c,"ratechange",e);Rl(a,a.h);f=a.h.abrFactory;a.s&&a.Ae==f||(a.Ae=f,a.s=f(),"function"!=typeof a.s.setMediaElement&&
490
+ mm(a.i);k=Date.now()/1E3;l=k-f;a.u.F=l;E(m)})}function dm(a){var b,c;return K(function(d){return 1==d.g?(Ul(a,"drm-engine"),b=Date.now()/1E3,c=!0,a.o=nm(a,{Nb:a.H,onError:function(e){Xl(a,e)},Kd:function(e){om(a,e)},onExpirationUpdated:function(e,f){pm(a,e,f)},onEvent:function(e){a.dispatchEvent(e);"drmsessionupdate"==e.type&&c&&(c=!1,a.u.j=Date.now()/1E3-b,a.J&&ki(a.J))}}),a.o.configure(a.h.drm),C(d,Fg(a.o,a.i.variants,a.i.offlineSessionIds),2)):3!=d.g?C(d,a.o.Cc(a.g),3):C(d,jm(a,a.i),0)})}
491
+ function em(a,b){var c,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,A,B;return K(function(D){switch(D.g){case 1:Ul(a,"load");c=a.g;a.I=new zj({xd:function(){return c.playbackRate},Ic:function(){return c.defaultPlaybackRate},ef:function(F){c.playbackRate=F},Pf:function(F){c.currentTime+=F}});d=function(){return qm(a)};e=function(){return rm(a)};a.m.D(c,"playing",d);a.m.D(c,"pause",d);a.m.D(c,"ended",d);a.m.D(c,"ratechange",e);Rl(a,a.h);f=a.h.abrFactory;a.s&&a.Ae==f||(a.Ae=f,a.s=f(),"function"!=typeof a.s.setMediaElement&&
490
492
  (le("AbrManager","Please use an AbrManager with setMediaElement function."),a.s.setMediaElement=function(){}),a.s.configure(a.h.abr));a.Ba=new we(a.h.preferredAudioLanguage,a.h.preferredVariantRole,a.h.preferredAudioChannelCount,a.h.preferredVideoHdrLevel,a.h.preferredVideoLayout,a.h.preferredAudioLabel,a.h.mediaSource.codecSwitchingStrategy,a.h.manifest.dash.enableAudioGroups);a.Wa=a.h.preferredTextLanguage;a.kc=a.h.preferredTextRole;a.Ac=a.h.preferForcedSubs;sm(a.i.presentationTimeline,a.h.playRangeStart,
491
493
  a.h.playRangeEnd);a.s.init(function(F,J,G){a.j&&F!=a.j.j&&tm(a,F,!0,void 0===J?!1:J,void 0===G?0:G)});a.s.setMediaElement(c);Ad(a.i,a.h.preferredVideoCodecs,a.h.preferredAudioCodecs,a.h.preferredDecodingAttributes);a.j=um(a);a.j.configure(a.h.streaming);a.l=vm;c.textTracks&&a.m.D(c.textTracks,"addtrack",function(F){if(F.track)switch(F=F.track,F.kind){case "chapters":wm(a,F)}});a.dispatchEvent(Sl("streaming"));g=null;(h=a.j.j)||(g=xm(a,!0));k=[];l=h||g;m=t([l.video,l.audio]);for(n=m.next();!n.done;n=
492
494
  m.next())(r=n.value)&&!r.segmentIndex&&k.push(r.createSegmentIndex());if(!(0<k.length)){D.B(2);break}return C(D,Promise.all(k),2);case 2:if(a.F&&a.F.onInitialVariantChosen)a.F.onInitialVariantChosen(l);sm(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd);a.C=ym(a,a.la);a.cb=zm(a,b);p=Math.max(a.i.minBufferTime,a.h.streaming.rebufferingGoal);Am(a,c,p);if(h){D.B(4);break}tm(a,g,!0,!1,0);if(!a.h.streaming.startAtSegmentBoundary){D.B(4);break}u=a.C;v=u.Zd;return C(D,Bm(g,a.C.kd()),6);case 6:v.call(u,
493
- D.h);case 4:return a.C.Yd(),x=a.$b().find(function(F){return F.active}),x||((z=ce(a.i.textStreams,a.Wa,a.kc,a.Ac)[0]||null)&&Hl(a.u.h,z,!0),g&&(z?(g.audio&&Cm(a,g.audio,z)&&(a.$=!0),a.$&&a.G.F.setTextVisibility(!0),Dm(a)):a.$=!1),z&&(a.h.streaming.alwaysStreamText||a.De())&&ik(a.j,z)),C(D,a.j.start(),7);case 7:a.h.abr.enabled&&(a.s.enable(),Em(a));Fm(a);Gm(a);a.i.variants.some(function(F){return F.primary});(y=a.S())&&(a.h.streaming.liveSync||a.i.serviceDescription)?(B=function(){return Hm(a)},a.m.D(c,
494
- "timeupdate",B)):y||(A=function(){return Im(a)},a.m.D(c,"timeupdate",A),Im(a));if(a.A)a.A.onManifestUpdated(y);a.Dc=!0;a.m.ha(c,"loadedmetadata",function(){a.u.m=Date.now()/1E3-b});E(D)}})}
495
- function bm(a,b){var c,d,e,f;return K(function(g){return 1==g.g?(c=Cc,d=Date.now()/1E3,e=!0,a.o=nm(a,{Ob:a.H,onError:function(h){Xl(a,h)},Kd:function(h){om(a,h)},onExpirationUpdated:function(h,k){pm(a,h,k)},onEvent:function(h){a.dispatchEvent(h);"drmsessionupdate"==h.type&&e&&(e=!1,a.u.j=Date.now()/1E3-d)}}),a.o.configure(a.h.drm),f={id:0,language:"und",disabledUntilTime:0,primary:!1,audio:null,video:{id:0,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,
495
+ D.h);case 4:return a.C.Yd(),x=a.$b().find(function(F){return F.active}),x||((z=ce(a.i.textStreams,a.Wa,a.kc,a.Ac)[0]||null)&&Hl(a.u.h,z,!0),g&&(z?(g.audio&&Cm(a,g.audio,z)&&(a.$=!0),a.$&&a.G.F.setTextVisibility(!0),Dm(a)):a.$=!1),z&&(a.h.streaming.alwaysStreamText||a.De())&&ik(a.j,z)),C(D,a.j.start(),7);case 7:a.h.abr.enabled&&(a.s.enable(),Em(a));Fm(a);Gm(a);a.i.variants.some(function(F){return F.primary});(y=a.S())&&(a.h.streaming.liveSync||a.i.serviceDescription)?(A=function(){return Hm(a)},a.m.D(c,
496
+ "timeupdate",A)):y||(B=function(){return Im(a)},a.m.D(c,"timeupdate",B),Im(a));if(a.A)a.A.onManifestUpdated(y);a.Dc=!0;a.m.ha(c,"loadedmetadata",function(){a.u.m=Date.now()/1E3-b});E(D)}})}
497
+ function bm(a,b){var c,d,e,f;return K(function(g){return 1==g.g?(c=Cc,d=Date.now()/1E3,e=!0,a.o=nm(a,{Nb:a.H,onError:function(h){Xl(a,h)},Kd:function(h){om(a,h)},onExpirationUpdated:function(h,k){pm(a,h,k)},onEvent:function(h){a.dispatchEvent(h);"drmsessionupdate"==h.type&&e&&(e=!1,a.u.j=Date.now()/1E3-d)}}),a.o.configure(a.h.drm),f={id:0,language:"und",disabledUntilTime:0,primary:!1,audio:null,video:{id:0,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,
496
498
  mimeType:b?Kc(b):"",codecs:b?Lc(b):"",encrypted:!0,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:c.ea,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!1,fastSwitching:!1},bandwidth:100,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},a.o.$=!0,C(g,Fg(a.o,[f],[]),2)):C(g,a.o.Cc(a.g),0)})}
497
499
  function fm(a,b,c){var d,e,f,g,h,k,l,m,n,r;return K(function(p){if(1==p.g)return Ul(a,"src-equals"),d=a.g,a.C=new oj(d),e=!1,a.sb.push(function(){e=!0}),null!=a.la&&a.C.Zd(a.la),a.I=new zj({xd:function(){return d.playbackRate},Ic:function(){return d.defaultPlaybackRate},ef:function(u){d.playbackRate=u},Pf:function(u){d.currentTime+=u}}),f=a.h.streaming.rebufferingGoal,Am(a,d,f),g=function(){return qm(a)},h=function(){return rm(a)},a.m.D(d,"playing",g),a.m.D(d,"pause",g),a.m.D(d,"ended",g),a.m.D(d,
498
500
  "ratechange",h),"none"!=d.preload&&a.m.ha(d,"loadedmetadata",function(){a.u.m=Date.now()/1E3-b}),d.audioTracks&&(a.m.D(d.audioTracks,"addtrack",function(){return Fm(a)}),a.m.D(d.audioTracks,"removetrack",function(){return Fm(a)}),a.m.D(d.audioTracks,"change",function(){return Fm(a)})),d.textTracks&&(a.m.D(d.textTracks,"addtrack",function(u){if(u.track)switch(u=u.track,u.kind){case "metadata":Jm(a,u);break;case "chapters":wm(a,u);break;default:Fm(a)}}),a.m.D(d.textTracks,"removetrack",function(){return Fm(a)}),
499
501
  a.m.D(d.textTracks,"change",function(){return Fm(a)})),d.src=Wk(a.V,a.da,c),(pd()||od("Web0S"))&&d.load(),a.l=Km,a.dispatchEvent(Sl("streaming")),k=new Le,fj(d,HTMLMediaElement.HAVE_METADATA,a.m,function(){a.C.Yd();k.resolve()}),fj(d,HTMLMediaElement.HAVE_CURRENT_DATA,a.m,function(){var u;return K(function(v){if(1==v.g)return Lm(a),u=Mm(a),u.find(function(x){return"disabled"!=x.mode})?(0<u.length&&(a.$=!0),v.B(2)):C(v,new Promise(function(x){a.m.ha(d.textTracks,"change",x);(new id(x)).U(1)}),2);if(e)return v.return();
500
502
  Nm(a);E(v)})}),d.error?k.reject(Wl(a)):"none"==d.preload&&(Ta('With <video preload="none">, the browser will not load anything until play() is called. We are unable to measure load latency in a meaningful way, and we cannot provide track info yet. Please do not use preload="none" with Shaka Player.'),k.resolve()),a.m.ha(d,"error",function(){k.reject(Wl(a))}),C(p,k,2);(l=a.S())&&a.h.streaming.liveSync?(m=function(){return Hm(a)},a.m.D(d,"timeupdate",m)):l||(n=function(){return Im(a)},a.m.D(d,"timeupdate",
501
- n),Im(a));a.A&&(a.A.onManifestUpdated(l),l&&(r=a.Ab().end,a.m.D(d,"progress",function(){var u=a.Ab().end;r!=u&&(a.A.onManifestUpdated(a.S()),r=u)})));a.Dc=!0;E(p)})}function Lm(a){var b=a.h.preferredAudioLanguage;""!=b&&a.Xf(b,a.h.preferredVariantRole)}function Nm(a){var b=a.h.preferredTextLanguage;""!=b&&a.Yf(b,a.h.preferredTextRole,a.h.preferForcedSubs)}
503
+ n),Im(a));a.A&&(a.A.onManifestUpdated(l),l&&(r=a.Pb().end,a.m.D(d,"progress",function(){var u=a.Pb().end;r!=u&&(a.A.onManifestUpdated(a.S()),r=u)})));a.Dc=!0;E(p)})}function Lm(a){var b=a.h.preferredAudioLanguage;""!=b&&a.Xf(b,a.h.preferredVariantRole)}function Nm(a){var b=a.h.preferredTextLanguage;""!=b&&a.Yf(b,a.h.preferredTextRole,a.h.preferForcedSubs)}
502
504
  function Jm(a,b){if("metadata"==b.kind){b.mode="hidden";a.m.D(b,"cuechange",function(){if(b.activeCues)for(var d=t(b.activeCues),e=d.next();!e.done;e=d.next())if(e=e.value,Om(a,e.startTime,e.endTime,e.type,e.value),a.A)a.A.onCueMetadataChange(e.value)});var c=(new id(function(){var d=Pm(a);d=t(d);for(var e=d.next();!e.done;e=d.next())e.value.mode="hidden"})).ic().U(.5);a.sb.push(function(){c.stop()})}}
503
505
  function hm(a,b,c,d){b=t(b);for(var e=b.next();!e.done;e=b.next())if(e=e.value,e.data&&e.cueTime&&e.frames){var f=e.cueTime+c,g=d;g&&f>g&&(g=f);for(var h=t(e.frames),k=h.next();!k.done;k=h.next())Om(a,f,g,"org.id3",k.value);if(a.A)a.A.onHlsTimedMetadata(e,f)}}function Om(a,b,c,d,e){b=(new Map).set("startTime",b).set("endTime",c).set("metadataType",d).set("payload",e);a.dispatchEvent(Sl("metadata",b))}
504
506
  function wm(a,b){if(b&&"chapters"==b.kind){b.mode="hidden";var c=(new id(function(){b.mode="hidden"})).ic().U(.5);a.sb.push(function(){c.stop()})}}function mm(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))}q.wh=function(){for(var a=this.W;a.g;)a.release()};function nm(a,b){return new yg(b,a.h.drm.updateExpirationTime)}
@@ -508,23 +510,23 @@ function Ml(a){return new $e(function(b,c,d){a.s&&a.s.segmentDownloaded(b,c,d)},
508
510
  function zm(a,b){b=new Hj(a.va,a.S()||0<b);b.addEventListener("enter",function(d){im(a,"timelineregionenter",d.region)});b.addEventListener("exit",function(d){im(a,"timelineregionexit",d.region)});b.addEventListener("skip",function(d){var e=d.region;d.seeking||(im(a,"timelineregionenter",e),im(a,"timelineregionexit",e))});var c=new Aj(a.g);c.g.add(b);a.ma&&c.g.add(a.ma);return c}
509
511
  function Am(a,b,c){a.K=new Ee;a.K.g=Ge;He(a.K,c,Math.min(.5,c/2));Zl(a);a.m.D(b,"waiting",function(){return Qm(a)});a.m.D(b,"stalled",function(){return Qm(a)});a.m.D(b,"canplaythrough",function(){return Qm(a)});a.m.D(b,"progress",function(){return Qm(a)})}
510
512
  function Qm(a){switch(a.l){case Km:if(a.g.ended)var b=!0;else{var c=yh(a.g.buffered);b=null!=c&&c>=a.g.duration-1}break;case vm:a:if(a.g.ended||Ai(a.G))b=!0;else{if(a.i.presentationTimeline.S()){c=a.i.presentationTimeline.vb();var d=yh(a.g.buffered);if(null!=d&&d>=c){b=!0;break a}}b=!1}break;default:b=!1}d=Ah(a.g.buffered,a.g.currentTime);c=a.K;var e=b,f=c.h.get(c.g);b=c.g;d=e||d>=f?Fe:Ge;c.g=d;b!=d&&Zl(a)}function gm(a,b,c,d){return new si(a,b,c,d)}
511
- function Ll(a){return new Vk({getBandwidthEstimate:function(){return a.s?a.s.getBandwidthEstimate():NaN},gb:function(){return a.gb()},getCurrentTime:function(){return a.g?a.g.currentTime:0},vd:function(){return a.vd()},Ib:function(){return a.Ib()},wb:function(){return a.wb()},S:function(){return a.S()}},a.h.cmcd)}
512
- function um(a){return new Vj(a.i,{wd:function(){return a.C?a.C.kd():0},getBandwidthEstimate:function(){return a.s.getBandwidthEstimate()},T:a.G,Ob:a.H,onError:function(b){return Xl(a,b)},onEvent:function(b){return a.dispatchEvent(b)},ph:function(){a.F&&a.F.update&&a.F.update()},Se:function(b,c,d){a.C&&a.C.Qf();Qm(a);b=(new Map).set("start",b).set("end",c).set("contentType",d);a.dispatchEvent(Sl("segmentappended",b))},oh:function(b,c){(c=c.Ne)&&a.ma&&Ej(a.ma,c,b)},rf:function(b,c){var d=a.o;if(d.h.parseInbandPsshEnabled&&
513
+ function Ll(a){return new Vk({getBandwidthEstimate:function(){return a.s?a.s.getBandwidthEstimate():NaN},gb:function(){return a.gb()},getCurrentTime:function(){return a.g?a.g.currentTime:0},vd:function(){return a.vd()},Hb:function(){return a.Hb()},wb:function(){return a.wb()},S:function(){return a.S()}},a.h.cmcd)}
514
+ function um(a){return new Vj(a.i,{wd:function(){return a.C?a.C.kd():0},getBandwidthEstimate:function(){return a.s.getBandwidthEstimate()},T:a.G,Nb:a.H,onError:function(b){return Xl(a,b)},onEvent:function(b){return a.dispatchEvent(b)},ph:function(){a.F&&a.F.update&&a.F.update()},Se:function(b,c,d){a.C&&a.C.Qf();Qm(a);b=(new Map).set("start",b).set("end",c).set("contentType",d);a.dispatchEvent(Sl("segmentappended",b))},oh:function(b,c){(c=c.Ne)&&a.ma&&Ej(a.ma,c,b)},rf:function(b,c){var d=a.o;if(d.h.parseInbandPsshEnabled&&
513
515
  !d.I&&["audio","video"].includes(b)){c=new ag(mb(c));var e=0,f=t(c.data);for(b=f.next();!b.done;b=f.next())e+=b.value.length;if(0==e)d=Promise.resolve();else{e=new Uint8Array(e);f=0;c=t(c.data);for(b=c.next();!b.done;b=c.next())b=b.value,e.set(b,f),f+=b.length;Og(d,"cenc",e);d=d.l}}else d=Promise.resolve();return d},qh:function(b,c,d){hm(a,b,c,d)},fe:function(b,c){return a.fe(b,c)}})}
514
516
  q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=ql(a,b));a.streaming&&"forceTransmuxTS"in a.streaming&&(le("streaming.forceTransmuxTS configuration","Please Use mediaSource.forceTransmux instead."),a.mediaSource.mediaSource=a.streaming.forceTransmuxTS,delete a.streaming.forceTransmuxTS);a.streaming&&"forceTransmux"in a.streaming&&(le("streaming.forceTransmux configuration","Please Use mediaSource.forceTransmux instead."),a.mediaSource.mediaSource=a.streaming.forceTransmux,delete a.streaming.forceTransmux);
515
517
  a.streaming&&a.streaming.lowLatencyMode&&(void 0==a.streaming.inaccurateManifestTolerance&&(a.streaming.inaccurateManifestTolerance=0),void 0==a.streaming.rebufferingGoal&&(a.streaming.rebufferingGoal=.01),void 0==a.streaming.segmentPrefetchLimit&&(a.streaming.segmentPrefetchLimit=2));var c=Cl(this.h,a,Kl(this));Rm(this);return c};
516
518
  function Rm(a){if(a.F){var b=We(a.h.manifest);a.g&&"AUDIO"===a.g.nodeName&&(b.disableVideo=!0);a.F.configure(b)}a.o&&a.o.configure(a.h.drm);if(a.j){a.j.configure(a.h.streaming);try{Sm(a,a.i)}catch(f){Xl(a,f)}a.s&&Gm(a);b=a.j.j;!b||b.allowedByApplication&&b.allowedByKeySystem||Tm(a)}a.H&&a.H.cf(a.h.streaming.forceHTTPS);if(a.G&&(a.G.configure(a.h.mediaSource),a.G.W=a.h.manifest.segmentRelativeVttTiming,b=a.h.textDisplayFactory,a.Ee!=b)){var c=b(),d=a.G,e=d.F;d.F=c;e&&(c.setTextVisibility(e.isTextVisible()),
517
519
  e.destroy());d.h&&(d.h.j=c);a.Ee=b;a.j&&(b=a.j,(c=b.h.get(Bc))&&gk(b,c.stream,!0,0,!0))}a.s&&(a.s.configure(a.h.abr),a.h.abr.enabled?a.s.enable():a.s.disable(),Em(a));a.K&&(b=a.h.streaming.rebufferingGoal,a.i&&(b=Math.max(b,a.i.minBufferTime)),He(a.K,b,Math.min(.5,b/2)));a.i&&sm(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd);a.A&&a.A.configure(a.h.ads);a.V&&a.V.configure(a.h.cmcd)}q.getConfiguration=function(){var a=Kl(this);Cl(a,this.h,Kl(this));return a};
518
- q.Dg=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.Ab().end);if(a>=b)return 1;if(!(a<=this.g.currentTime)&&a<b)return(a-this.g.currentTime)/(b-this.g.currentTime)}return 0};q.Ah=function(){for(var a in this.h)delete this.h[a];Cl(this.h,Kl(this),Kl(this));Rm(this)};q.Kg=function(){return this.l};q.xe=function(){return this.i?this.i.type:null};q.Og=function(){return this.g};
519
- q.Ib=function(){return this.H};q.we=function(){return this.da};q.Df=function(){return this.A?this.A:null};q.S=function(){return this.i?this.i.presentationTimeline.S():this.g&&this.g.src?Infinity==this.g.duration:!1};q.Mb=function(){return this.i?this.i.presentationTimeline.Mb():!1};q.dh=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};
520
- q.Ab=function(){if(this.i){if(!this.Dc&&"HLS"==this.i.type)return{start:0,end:0};var a=this.i.presentationTimeline;return{start:a.Zb(),end:a.hb()}}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}};q.$g=function(){this.S()&&(this.g.currentTime=this.Ab().end)};q.keySystem=function(){var a=this.drmInfo();return a?a.keySystem:""};q.drmInfo=function(){return this.o?this.o.g:null};q.Kc=function(){return this.o?this.o.Kc():Infinity};
520
+ q.Dg=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.Pb().end);if(a>=b)return 1;if(!(a<=this.g.currentTime)&&a<b)return(a-this.g.currentTime)/(b-this.g.currentTime)}return 0};q.Ah=function(){for(var a in this.h)delete this.h[a];Cl(this.h,Kl(this),Kl(this));Rm(this)};q.Kg=function(){return this.l};q.xe=function(){return this.i?this.i.type:null};q.Og=function(){return this.g};
521
+ q.Hb=function(){return this.H};q.we=function(){return this.da};q.Df=function(){return this.A?this.A:null};q.S=function(){return this.i?this.i.presentationTimeline.S():this.g&&this.g.src?Infinity==this.g.duration:!1};q.Lb=function(){return this.i?this.i.presentationTimeline.Lb():!1};q.dh=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};
522
+ q.Pb=function(){if(this.i){if(!this.Dc&&"HLS"==this.i.type)return{start:0,end:0};var a=this.i.presentationTimeline;return{start:a.Zb(),end:a.hb()}}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}};q.$g=function(){this.S()&&(this.g.currentTime=this.Pb().end)};q.keySystem=function(){var a=this.drmInfo();return a?a.keySystem:""};q.drmInfo=function(){return this.o?this.o.g:null};q.Kc=function(){return this.o?this.o.Kc():Infinity};
521
523
  q.ve=function(){return this.o?this.o.ve():[]};q.ud=function(){return this.o?this.o.ud():{}};q.Be=function(){return this.K?this.K.g==Ge:!1};q.vd=function(){return this.g?this.I?this.I.h:1:0};q.kf=function(a){0==a?Ta("A trick play rate of 0 is unsupported!"):(this.g.paused&&this.g.play(),this.I.set(a),this.l==vm&&(this.s.playbackRateChanged(a),fk(this.j,1<Math.abs(a))))};q.tf=function(){var a=this.I.Ic();this.l==Km&&this.I.set(a);this.l==vm&&(this.I.set(a),this.s.playbackRateChanged(a),fk(this.j,!1))};
522
524
  q.wb=function(){if(this.i){for(var a=this.j?this.j.j:null,b=[],c=0,d=t(this.i.variants),e=d.next();!e.done;e=d.next())if(e=e.value,ae(e)){var f=Td(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 $d(g)}):[]};
523
525
  q.$b=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=Ud(d);e.active=d==a;b.push(e)}return b}return this.g&&this.g.src&&this.g.textTracks?Mm(this).map(function(f){return Yd(f)}):[]};q.Jg=function(){var a=this.Bc;this.i&&(a=this.i.imageStreams);return a.map(function(b){return Vd(b)})};
524
- q.Ag=function(a){var b=this,c,d,e,f;return K(function(g){if(1==g.g){if(b.l!=vm&&b.l!=Km)return g.return(null);c=b.Bc;b.i&&(c=b.i.imageStreams);return(d=c.find(function(h){return h.id==a}))?d.segmentIndex?g.B(2):C(g,d.createSegmentIndex(),2):g.return(null)}if(4!=g.g)return e=[],vj(d.segmentIndex,function(h){var k=Um(h.tilesLayout||d.tilesLayout);if(k){k=k.rows*k.Eb;for(var l=h.j-h.startTime,m=0;m<k;m++)e.push(b.Gf(a,h.startTime+l*m/k))}}),C(g,Promise.all(e),4);f=g.h;return g.return(f.filter(function(h){return h}))})};
525
- function Um(a){return a?(a=/(\d+)x(\d+)/.exec(a))?{Eb:parseInt(a[1],10),rows:parseInt(a[2],10)}:null:null}
526
- q.Gf=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,B,A;return K(function(D){if(1==D.g){if(c.l!=vm&&c.l!=Km)return D.return(null);d=c.Bc;c.i&&(d=c.i.imageStreams);return(e=d.find(function(F){return F.id==a}))?e.segmentIndex?D.B(2):C(D,e.createSegmentIndex(),2):D.return(null)}f=e.segmentIndex.find(b);if(null==f)return D.return(null);g=e.segmentIndex.get(f);h=Um(g.tilesLayout||e.tilesLayout);if(!h)return D.return(null);k=e.width||0;l=e.height||0;m=k/h.Eb;n=l/h.rows;r=h.Eb*h.rows;p=g.j-g.startTime;
527
- u=g.G||p/r;v=g.startTime;z=x=0;1<r&&(y=Math.floor((b-g.startTime)/u),v=g.startTime+y*u,x=y%h.Eb*m,z=Math.floor(y/h.Eb)*n);B=!1;if(A=g.F)B=!0,n=A.height,x=A.positionX,z=A.positionY,m=A.width;return D.return({segment:g,imageHeight:l,imageWidth:k,height:n,positionX:x,positionY:z,startTime:v,duration:u,uris:g.Y(),width:m,sprite:B})})};
526
+ q.Ag=function(a){var b=this,c,d,e,f;return K(function(g){if(1==g.g){if(b.l!=vm&&b.l!=Km)return g.return(null);c=b.Bc;b.i&&(c=b.i.imageStreams);return(d=c.find(function(h){return h.id==a}))?d.segmentIndex?g.B(2):C(g,d.createSegmentIndex(),2):g.return(null)}if(4!=g.g)return e=[],vj(d.segmentIndex,function(h){var k=Um(h.tilesLayout||d.tilesLayout);if(k){k=k.rows*k.Db;for(var l=h.j-h.startTime,m=0;m<k;m++)e.push(b.Gf(a,h.startTime+l*m/k))}}),C(g,Promise.all(e),4);f=g.h;return g.return(f.filter(function(h){return h}))})};
527
+ function Um(a){return a?(a=/(\d+)x(\d+)/.exec(a))?{Db:parseInt(a[1],10),rows:parseInt(a[2],10)}:null:null}
528
+ q.Gf=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,A,B;return K(function(D){if(1==D.g){if(c.l!=vm&&c.l!=Km)return D.return(null);d=c.Bc;c.i&&(d=c.i.imageStreams);return(e=d.find(function(F){return F.id==a}))?e.segmentIndex?D.B(2):C(D,e.createSegmentIndex(),2):D.return(null)}f=e.segmentIndex.find(b);if(null==f)return D.return(null);g=e.segmentIndex.get(f);h=Um(g.tilesLayout||e.tilesLayout);if(!h)return D.return(null);k=e.width||0;l=e.height||0;m=k/h.Db;n=l/h.rows;r=h.Db*h.rows;p=g.j-g.startTime;
529
+ u=g.G||p/r;v=g.startTime;z=x=0;1<r&&(y=Math.floor((b-g.startTime)/u),v=g.startTime+y*u,x=y%h.Db*m,z=Math.floor(y/h.Db)*n);A=!1;if(B=g.F)A=!0,n=B.height,x=B.positionX,z=B.positionY,m=B.width;return D.return({segment:g,imageHeight:l,imageWidth:k,height:n,positionX:x,positionY:z,startTime:v,duration:u,uris:g.Y(),width:m,sprite:A})})};
528
530
  q.Zf=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&&(Hl(this.u.h,b,!1),ik(this.j,b),Vm(this),this.Wa=b.language)}else if(this.g&&this.g.src&&this.g.textTracks){b=Mm(this);b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,Wd(c)==a.id?c.mode=this.$?"showing":"hidden":c.mode="disabled";Vm(this)}};
529
531
  q.af=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&&Ta("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&&ae(d)&&(tm(this,d,!1,b,c),this.Ba=new ve(d,this.h.mediaSource.codecSwitchingStrategy,this.h.manifest.dash.enableAudioGroups),Gm(this))}else if(this.g&&this.g.audioTracks)for(b=
530
532
  Array.from(this.g.audioTracks),b=t(b),c=b.next();!c.done;c=b.next())if(c=c.value,Wd(c)==a.id){Wm(this,c);break}};q.Cg=function(){return Xm(this.wb())};q.Tg=function(){return Xm(this.$b())};q.Bg=function(){return Array.from(Ym(this.wb()))};q.Sg=function(){return Array.from(Ym(this.$b()))};
@@ -539,30 +541,30 @@ q.Qg=function(){if(!this.S())return null;if(this.C)var a=this.C.kd();else{if(nul
539
541
  q.Ff=function(){if(!this.S())return null;if(this.i)return new Date(1E3*this.i.presentationTimeline.i);if(this.g&&this.g.getStartDate){var a=this.g.getStartDate();return isNaN(a.getTime())?null:a}return null};q.gb=function(){if(this.l==vm)return this.G.gb();var a={total:[],audio:[],video:[],text:[]};this.l==Km&&(a.total=Bh(this.g.buffered));return a};
540
542
  q.getStats=function(){if(this.l!=vm&&this.l!=Km)return{width:NaN,height:NaN,streamBandwidth:NaN,decodedFrames:NaN,droppedFrames:NaN,corruptedFrames:NaN,stallsDetected:NaN,gapsJumped:NaN,estimatedBandwidth:NaN,completionPercent:NaN,loadLatency:NaN,manifestTimeSeconds:NaN,drmTimeSeconds:NaN,playTime:NaN,pauseTime:NaN,bufferingTime:NaN,licenseTime:NaN,liveLatency:NaN,maxSegmentDuration:NaN,switchHistory:[],stateHistory:[]};qm(this);var a=this.g,b=a.currentTime/a.duration;if(!isNaN(b)){var c=this.u;b=
541
543
  Math.round(100*b);c.i=isNaN(c.i)?b:Math.max(c.i,b)}this.C&&(this.u.K=this.C.nf(),this.u.N=this.C.pf());if(a.getVideoPlaybackQuality){c=a.getVideoPlaybackQuality();b=this.u;var d=Number(c.totalVideoFrames);b.J=Number(c.droppedVideoFrames);b.I=d;this.u.H=Number(c.corruptedVideoFrames)}this.o?(c=this.o,c=c.H?c.H:NaN):c=NaN;this.u.s=c;if(this.l==vm){if(c=this.j.j)this.u.A=(this.I?this.I.h:1)*c.bandwidth;c&&c.video&&(b=this.u,d=c.video.height||NaN,b.o=c.video.width||NaN,b.l=d);this.S()&&(c=this.Ff().valueOf()+
542
- 1E3*this.Ab().end,this.u.C=(Date.now()-c)/1E3);this.i&&this.i.presentationTimeline&&(this.u.G=this.i.presentationTimeline.g);c=this.s.getBandwidthEstimate();this.u.u=c}this.l==Km&&(c=this.u,b=a.videoHeight||NaN,c.o=a.videoWidth||NaN,c.l=b);var e=this.u;a=e.o;c=e.l;b=e.A;d=e.I;var f=e.J,g=e.H,h=e.N,k=e.K,l=e.u,m=e.i,n=e.m,r=e.F,p=e.j,u=El(e.g,"playing"),v=El(e.g,"paused"),x=El(e.g,"buffering"),z=e.s,y=e.C,B=e.G,A=Fl(e.g),D=[];e=t(e.h.g);for(var F=e.next();!F.done;F=e.next())F=F.value,D.push({timestamp:F.timestamp,
543
- id:F.id,type:F.type,fromAdaptation:F.fromAdaptation,bandwidth:F.bandwidth});return{width:a,height:c,streamBandwidth:b,decodedFrames:d,droppedFrames:f,corruptedFrames:g,stallsDetected:h,gapsJumped:k,estimatedBandwidth:l,completionPercent:m,loadLatency:n,manifestTimeSeconds:r,drmTimeSeconds:p,playTime:u,pauseTime:v,bufferingTime:x,licenseTime:z,liveLatency:y,maxSegmentDuration:B,stateHistory:A,switchHistory:D}};
544
- q.ng=function(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h=this,k,l,m,n,r,p,u,v,x,z,y,B;return K(function(A){switch(A.g){case 1:if(h.l!=vm&&h.l!=Km)throw new O(1,7,7004);if(d){A.B(2);break}return C(A,$m(h,a),3);case 3:d=A.h;case 2:k=[];h.A&&(k=h.A.getCuePoints());if(h.l!=Km){A.B(4);break}g&&(c="forced");return C(A,an(h,a,b,c,d,f||"",k),5);case 5:l=Zc(b);m=h.$b();if(n=m.find(function(D){return Zc(D.language)==l&&D.label==(f||"")&&D.kind==c}))return Fm(h),A.return(n);throw new O(1,2,2012);case 4:r=Cc;p=h.g.duration;
545
- h.i&&(p=h.i.presentationTimeline.getDuration());if(Infinity==p)throw new O(1,4,4033);if(!k.length){A.B(6);break}return C(A,bn(h,a,h.H,h.h.streaming.retryParameters),7);case 7:u=A.h,v=cn(h,u,d,k),x=new Blob([v],{type:"text/vtt"}),a=vi(x),d="text/vtt";case 6:z={id:h.Ge++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:xj(0,p,[a]),mimeType:d||"",codecs:e||"",kind:c,encrypted:!1,drmInfos:[],keyIds:new Set,language:b,originalLanguage:b,label:f||null,type:r.ja,
546
- primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!!g,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!0,fastSwitching:!1};y=Ec(z.mimeType,z.codecs);B=Nc(y);if(!B)throw new O(2,2,2014,d);h.i.textStreams.push(z);Fm(h);return A.return(Ud(z))}})};
547
- q.og=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y;return K(function(B){switch(B.g){case 1:if(c.l!=vm&&c.l!=Km)throw new O(1,7,7004);if(b){B.B(2);break}return C(B,$m(c,a),3);case 3:b=B.h;case 2:if("text/vtt"!=b)throw new O(1,2,2017,a);d=Cc;e=c.g.duration;c.i&&(e=c.i.presentationTimeline.getDuration());if(Infinity==e)throw new O(1,4,4045);return C(B,bn(c,a,c.H,c.h.streaming.retryParameters),4);case 4:f=B.h;g=Oc[b];if(!g)throw new O(2,2,2014,b);h=g();k={periodStart:0,segmentStart:0,segmentEnd:e,
548
- vttOffset:0};l=mb(f);m=h.parseMedia(l,k,a);n=[];r={};p=t(m);for(u=p.next();!u.done;r={oc:r.oc},u=p.next())v=u.value,r.oc=wc([a],[v.payload])[0],x=new S(v.startTime,v.endTime,function(A){return function(){return[A.oc]}}(r),0,null,null,0,0,Infinity),r.oc.includes("#xywh")&&(z=r.oc.split("#xywh=")[1].split(","),4===z.length&&x.dg({height:parseInt(z[3],10),positionX:parseInt(z[0],10),positionY:parseInt(z[1],10),width:parseInt(z[2],10)})),n.push(x);y={id:c.Ge++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},
549
- segmentIndex:new uj(n),mimeType:b||"",codecs:"",kind:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:d.zc,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,tilesLayout:"1x1",accessibilityPurpose:null,external:!0,fastSwitching:!1};c.l==Km?c.Bc.push(y):c.i.imageStreams.push(y);Fm(c);return B.return(Vd(y))}})};
544
+ 1E3*a.currentTime,this.u.C=(Date.now()-c)/1E3);this.i&&this.i.presentationTimeline&&(this.u.G=this.i.presentationTimeline.g);c=this.s.getBandwidthEstimate();this.u.u=c}this.l==Km&&(c=this.u,b=a.videoHeight||NaN,c.o=a.videoWidth||NaN,c.l=b);var e=this.u;a=e.o;c=e.l;b=e.A;d=e.I;var f=e.J,g=e.H,h=e.N,k=e.K,l=e.u,m=e.i,n=e.m,r=e.F,p=e.j,u=El(e.g,"playing"),v=El(e.g,"paused"),x=El(e.g,"buffering"),z=e.s,y=e.C,A=e.G,B=Fl(e.g),D=[];e=t(e.h.g);for(var F=e.next();!F.done;F=e.next())F=F.value,D.push({timestamp:F.timestamp,
545
+ id:F.id,type:F.type,fromAdaptation:F.fromAdaptation,bandwidth:F.bandwidth});return{width:a,height:c,streamBandwidth:b,decodedFrames:d,droppedFrames:f,corruptedFrames:g,stallsDetected:h,gapsJumped:k,estimatedBandwidth:l,completionPercent:m,loadLatency:n,manifestTimeSeconds:r,drmTimeSeconds:p,playTime:u,pauseTime:v,bufferingTime:x,licenseTime:z,liveLatency:y,maxSegmentDuration:A,stateHistory:B,switchHistory:D}};
546
+ q.ng=function(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h=this,k,l,m,n,r,p,u,v,x,z,y,A;return K(function(B){switch(B.g){case 1:if(h.l!=vm&&h.l!=Km)throw new O(1,7,7004);if(d){B.B(2);break}return C(B,$m(h,a),3);case 3:d=B.h;case 2:k=[];h.A&&(k=h.A.getCuePoints());if(h.l!=Km){B.B(4);break}g&&(c="forced");return C(B,an(h,a,b,c,d,f||"",k),5);case 5:l=Zc(b);m=h.$b();if(n=m.find(function(D){return Zc(D.language)==l&&D.label==(f||"")&&D.kind==c}))return Fm(h),B.return(n);throw new O(1,2,2012);case 4:r=Cc;p=h.g.duration;
547
+ h.i&&(p=h.i.presentationTimeline.getDuration());if(Infinity==p)throw new O(1,4,4033);if(!k.length){B.B(6);break}return C(B,bn(h,a,h.H,h.h.streaming.retryParameters),7);case 7:u=B.h,v=cn(h,u,d,k),x=new Blob([v],{type:"text/vtt"}),a=vi(x),d="text/vtt";case 6:z={id:h.Ge++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:xj(0,p,[a]),mimeType:d||"",codecs:e||"",kind:c,encrypted:!1,drmInfos:[],keyIds:new Set,language:b,originalLanguage:b,label:f||null,type:r.ja,
548
+ primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!!g,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!0,fastSwitching:!1};y=Ec(z.mimeType,z.codecs);A=Nc(y);if(!A)throw new O(2,2,2014,d);h.i.textStreams.push(z);Fm(h);return B.return(Ud(z))}})};
549
+ q.og=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y;return K(function(A){switch(A.g){case 1:if(c.l!=vm&&c.l!=Km)throw new O(1,7,7004);if(b){A.B(2);break}return C(A,$m(c,a),3);case 3:b=A.h;case 2:if("text/vtt"!=b)throw new O(1,2,2017,a);d=Cc;e=c.g.duration;c.i&&(e=c.i.presentationTimeline.getDuration());if(Infinity==e)throw new O(1,4,4045);return C(A,bn(c,a,c.H,c.h.streaming.retryParameters),4);case 4:f=A.h;g=Oc[b];if(!g)throw new O(2,2,2014,b);h=g();k={periodStart:0,segmentStart:0,segmentEnd:e,
550
+ vttOffset:0};l=mb(f);m=h.parseMedia(l,k,a);n=[];r={};p=t(m);for(u=p.next();!u.done;r={oc:r.oc},u=p.next())v=u.value,r.oc=wc([a],[v.payload])[0],x=new S(v.startTime,v.endTime,function(B){return function(){return[B.oc]}}(r),0,null,null,0,0,Infinity),r.oc.includes("#xywh")&&(z=r.oc.split("#xywh=")[1].split(","),4===z.length&&x.dg({height:parseInt(z[3],10),positionX:parseInt(z[0],10),positionY:parseInt(z[1],10),width:parseInt(z[2],10)})),n.push(x);y={id:c.Ge++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},
551
+ segmentIndex:new uj(n),mimeType:b||"",codecs:"",kind:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:d.zc,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,tilesLayout:"1x1",accessibilityPurpose:null,external:!0,fastSwitching:!1};c.l==Km?c.Bc.push(y):c.i.imageStreams.push(y);Fm(c);return A.return(Vd(y))}})};
550
552
  q.mg=function(a,b,c){var d=this,e,f,g,h;return K(function(k){switch(k.g){case 1:if(d.l!=vm&&d.l!=Km)throw new O(1,7,7004);if(c){k.B(2);break}return C(k,$m(d,a),3);case 3:c=k.h;case 2:return e=[],d.A&&(e=d.A.getCuePoints()),C(k,an(d,a,b,"chapters",c,"",e),4);case 4:f=k.h;g=d.Ef();h=g.find(function(l){return l.language==b});if(!h){k.B(5);break}return C(k,new Promise(function(l,m){d.m.ha(f,"load",l);d.m.ha(f,"error",function(){m(new O(1,2,2015))})}),6);case 6:return Fm(d),k.return(h);case 5:throw new O(1,
551
553
  2,2012);}})};function $m(a,b){var c;return K(function(d){switch(d.g){case 1:return sa(d,2),C(d,Ak(b,a.H,a.h.streaming.retryParameters),4);case 4:c=d.h;va(d,3);break;case 2:wa(d);case 3:if(c)return d.return(c);throw new O(1,2,2011,b);}})}
552
554
  function an(a,b,c,d,e,f,g){var h,k,l,m;return K(function(n){if(1==n.g)return"text/vtt"!=e||g.length?C(n,bn(a,b,a.H,a.h.streaming.retryParameters),3):n.B(2);2!=n.g&&(h=n.h,k=cn(a,h,e,g),l=new Blob([k],{type:"text/vtt"}),b=vi(l),e="text/vtt");m=document.createElement("track");var r=a.V,p=b;try{if(r.g.enabled){var u=Xk(r);u.ot=ll;u.su=!0;var v=$k(u);var x=al(p,v)}else x=p}catch(z){Ua("CMCD_TEXT_TRACK_ERROR","Could not generate text track CMCD data.",z),x=p}m.src=x;m.label=f;m.kind=d;m.srclang=c;a.g.getAttribute("crossorigin")||
553
555
  a.g.setAttribute("crossorigin","anonymous");a.g.appendChild(m);return n.return(m)})}function bn(a,b,c,d){var e,f,g;return K(function(h){if(1==h.g){e=kf;f=df([b],d);f.method="GET";var k=a.V;try{k.g.enabled&&bl(k,f,{ot:ll,su:!0})}catch(l){Ua("CMCD_TEXT_ERROR","Could not generate text CMCD data.",l)}return C(h,c.request(e,f).promise,2)}g=h.h;return h.return(g.data)})}
554
556
  function cn(a,b,c,d){var e=Oc[c];if(e)return c=e(),a={periodStart:0,segmentStart:0,segmentEnd:a.g.duration,vttOffset:0},b=mb(b),b=c.parseMedia(b,a,null),Uk(b,d);throw new O(2,2,2014,c);}q.df=function(a,b){this.Fe.width=a;this.Fe.height=b};q.Ye=function(a){if(this.l==vm){var b=this.j;a=void 0===a?.1:a;if(b.l.g)b=!1;else if(b.s)b=!1;else{for(var c=t(b.h.values()),d=c.next();!d.done;d=c.next())d=d.value,!d.Oc||d.ya||d.bb||(d.Oc=!1,dk(b,d,a));b=!0}}else b=!1;return b};
555
557
  q.Lg=function(){Ta("Shaka Player's internal Manifest structure is NOT covered by semantic versioning compatibility guarantees. It may change at any time! Please consider filing a feature request for whatever you use getManifest() for.");return this.i};q.Mg=function(){return this.zd};
556
- function Kl(a){var b=Al();b.streaming.failureCallback=function(c){if(a.S()){var d=null;1001==c.code||1002==c.code?d=1:1003==c.code&&(d=.1);null!=d&&(c.severity=1,a.Ye(d))}};b.textDisplayFactory=function(){return a.ld?new Lk(a.g,a.ld):HTMLMediaElement.prototype.addTextTrack?new Fk(a.g):new Ik};return b}q.fg=function(a){this.ld=a};
558
+ function Kl(a){var b=Al();b.streaming.failureCallback=function(c){if(a.S()){var d=null;1001==c.code||1002==c.code?d=1:1003==c.code&&(d=.1);null!=d&&(c.severity=1,a.Ye(d))}};b.textDisplayFactory=function(){return a.ld?new Lk(a.g,a.ld):HTMLMediaElement.prototype.addTextTrack?new Fk(a.g,"Shaka Player TextTrack"):new Ik};return b}q.fg=function(a){this.ld=a};
557
559
  function km(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 yj,l=e.closedCaptions.get(g);h={id:a.Ge++,originalId:g,groupId:null,
558
560
  createSegmentIndex:function(){return Promise.resolve()},segmentIndex:k,mimeType:h,codecs:"",kind:"caption",encrypted:!1,drmInfos:[],keyIds:new Set,language:l,originalLanguage:l,label:null,type:Bc,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:e.roles,forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!1,fastSwitching:!1};b.textStreams.push(h);c.add(g)}}
559
561
  function jm(a,b){return K(function(c){if(1==c.g)return C(c,dn(a,b),2);Sm(a,b);E(c)})}function dn(a,b){return K(function(c){if(1==c.g)return C(c,Ed(a.o,b),2);if(!b.variants.some(ae))throw new O(2,4,4032);E(c)})}
560
562
  function Sm(a,b){if(a.l!=Tl){for(var c=a.h.restrictions,d=a.Fe,e=!1,f=t(b.variants),g=f.next();!g.done;g=f.next()){g=g.value;var h=g.allowedByApplication;g.allowedByApplication=Dd(g,c,d);h!=g.allowedByApplication&&(e=!0)}e&&a.j&&Fm(a);if((c=a.o?a.o.g:null)&&a.o.s)for(d=t(b.variants),e=d.next();!e.done;e=d.next())e=e.value,lm(a,c.keySystem,e.video),lm(a,c.keySystem,e.audio);en(a,b)}}
561
563
  function lm(a,b,c){if(c){c=t(c.drmInfos);for(var d=c.next();!d.done;d=c.next())if(d=d.value,d.keySystem==b){d=t(d.initData||[]);for(var e=d.next();!e.done;e=d.next())e=e.value,Og(a.o,e.initDataType,e.initData)}}}
562
- function Bm(a,b){var c,d,e,f,g;return K(function(h){if(1==h.g)return c=a.audio,d=a.video,e=function(k,l){var m,n,r;return K(function(p){if(1==p.g)return k?C(p,k.createSegmentIndex(),2):p.return(null);n=(m=k.segmentIndex.Hb(l))?m.next().value:null;if(!n)return p.return(null);r=n.startTime;return p.return(r)})},C(h,e(c,b),2);if(3!=h.g)return f=h.h,C(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)})}
564
+ function Bm(a,b){var c,d,e,f,g;return K(function(h){if(1==h.g)return c=a.audio,d=a.video,e=function(k,l){var m,n,r;return K(function(p){if(1==p.g)return k?C(p,k.createSegmentIndex(),2):p.return(null);n=(m=k.segmentIndex.Gb(l))?m.next().value:null;if(!n)return p.return(null);r=n.startTime;return p.return(r)})},C(h,e(c,b),2);if(3!=h.g)return f=h.h,C(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)})}
563
565
  function Zl(a){var b=a.Be();if(a.u&&a.K&&a.C){if(a.V){var c=a.V;b||c.i||(c.i=!0);c.i&&b&&(c.l=!0);c.m=b}qm(a)}b=(new Map).set("buffering",b);a.dispatchEvent(Sl("buffering",b))}function rm(a){var b=a.g.playbackRate;0!=b&&(a.I&&a.I.set(b),b=Sl("ratechange"),a.dispatchEvent(b))}
564
566
  function qm(a){if(a.u&&a.K){var b=a.u.g,c="playing";a.K.g==Ge?c="buffering":a.g.paused?c="paused":a.g.ended&&(c="ended");var d=c;if(null==b.g)b.g={timestamp:Date.now()/1E3,state:d,duration:0},b=!0;else{var e=Date.now()/1E3;b.g.duration=e-b.g.timestamp;b.g.state==d?b=!1:(b.h.push(b.g),b.g={timestamp:e,state:d,duration:0},b=!0)}b&&(c=(new Map).set("newstate",c),a.dispatchEvent(Sl("statechanged",c)))}}
565
- function Hm(a){if(a.S()){var b=a.Ab();if(Number.isFinite(b.end)&&!(a.g.currentTime<b.start)){if(a.h.streaming.liveSync){var c=a.h.streaming.liveSyncMaxLatency;var d=a.h.streaming.liveSyncPlaybackRate}else a.i&&a.i.serviceDescription&&(c=a.i.serviceDescription.maxLatency||a.h.streaming.liveSyncMaxLatency,d=a.i.serviceDescription.maxPlaybackRate||a.h.streaming.liveSyncPlaybackRate);if(a.h.streaming.liveSync){var e=a.h.streaming.liveSyncMinLatency;var f=a.h.streaming.liveSyncMinPlaybackRate}else a.i&&
567
+ function Hm(a){if(a.S()){var b=a.Pb();if(Number.isFinite(b.end)&&!(a.g.currentTime<b.start)){if(a.h.streaming.liveSync){var c=a.h.streaming.liveSyncMaxLatency;var d=a.h.streaming.liveSyncPlaybackRate}else a.i&&a.i.serviceDescription&&(c=a.i.serviceDescription.maxLatency||a.h.streaming.liveSyncMaxLatency,d=a.i.serviceDescription.maxPlaybackRate||a.h.streaming.liveSyncPlaybackRate);if(a.h.streaming.liveSync){var e=a.h.streaming.liveSyncMinLatency;var f=a.h.streaming.liveSyncMinPlaybackRate}else a.i&&
566
568
  a.i.serviceDescription&&(e=a.i.serviceDescription.minLatency||a.h.streaming.liveSyncMinLatency,f=a.i.serviceDescription.minPlaybackRate||a.h.streaming.liveSyncMinPlaybackRate);var g=a.g.playbackRate,h=b.end-a.g.currentTime,k=0;if(a.l==Km){var l=a.g.buffered;0<l.length&&(k=l.end(l.length-1),k=Math.max(d,k-b.end))}c&&d&&h-k>c?g!=d&&a.kf(d):e&&f&&h-k<e?g!=f&&a.kf(f):g!==a.I.Ic()&&a.tf()}}}
567
569
  function Im(a){if(a.g){var b=!1,c=a.g.currentTime/a.g.duration;isNaN(c)||(c=Math.round(100*c),isNaN(a.N)?(a.N=c,b=!0):(c=Math.max(a.N,c),a.N!=c&&(a.N=c,b=!0)));if(b){var d;0==a.N?d=Sl("started"):25==a.N?d=Sl("firstquartile"):50==a.N?d=Sl("midpoint"):75==a.N?d=Sl("thirdquartile"):100==a.N&&(d=Sl("complete"));d&&a.dispatchEvent(d)}}}function Gm(a){try{en(a,a.i)}catch(c){return Xl(a,c),!1}var b=be(a.i.variants);b=a.Ba.create(b);a.s.setVariants(Array.from(b.values()));return!0}
568
570
  function xm(a,b){b=void 0===b?!1:b;return Gm(a)?a.s.chooseVariant(b):null}
@@ -573,28 +575,28 @@ function gn(a,b,c){b=(new Map).set("oldTrack",b).set("newTrack",c);a.J&&li(a.J,c
573
575
  q.fe=function(a,b){if(!this.h.abr.enabled||this.l===Tl||!navigator.onLine)return!1;if(this.i.variants.some(function(f){return(f=f[a.type])&&f.id!==a.id?"audio"==a.type?a.language===f.language:!0:!1})){for(var c=t(this.i.variants),d=c.next();!d.done;d=c.next()){d=d.value;var e=d[a.type];e&&e.id===a.id&&(d.disabledUntilTime=Date.now()/1E3+b)}this.qd.Ua(1);b=this.gb().video.reduce(function(f,g){return f+g.end-g.start},0);Tm(this,!0,b,!0,!1);return!0}return!1};
574
576
  function Xl(a,b){if(a.l!=Tl){2===b.severity&&Ol(a,!1);var c=Sl("error",(new Map).set("detail",b));a.dispatchEvent(c);c.defaultPrevented&&(b.handled=!0)}}function im(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(Sl(b,c))}
575
577
  function Wl(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 O(2,3,3016,b,c,a.g.error.message)}
576
- function om(a,b){if(a.j){var c=Sl("keystatuschanged");a.dispatchEvent(c);var d=Object.keys(b),e=1==d.length&&"00"==d[0];c=!1;if(d.length){d=t(a.i.variants);for(var f=d.next();!f.done;f=d.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[e?"00":l],f.allowedByKeySystem=f.allowedByKeySystem&&
577
- !!l&&!hn.includes(l)}h!=f.allowedByKeySystem&&(c=!0)}}}if(!c||Gm(a))(b=a.j.j)&&!b.allowedByKeySystem&&Tm(a),c&&Fm(a)}}function pm(a,b,c){if(a.F&&a.F.onExpirationUpdated)a.F.onExpirationUpdated(b,c);b=Sl("expirationupdated");a.dispatchEvent(b)}function sm(a,b,c){0<b&&(a.S()||a.eg(b));b=a.getDuration();c<b&&(a.S()||a.Ka(c))}
578
+ function om(a,b){if(a.j){var c=Sl("keystatuschanged");a.dispatchEvent(c);var d=Object.keys(b);c=1==d.length&&"00"==d[0];var e=!1;if(d.length){d=t(a.i.variants);for(var f=d.next();!f.done;f=d.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[c?"00":l],f.allowedByKeySystem=f.allowedByKeySystem&&
579
+ !!l&&!hn.includes(l)}h!=f.allowedByKeySystem&&(e=!0)}}}if(e&&(Fm(a),!Gm(a)))return;(b=a.j.j)&&!b.allowedByKeySystem&&Tm(a)}}function pm(a,b,c){if(a.F&&a.F.onExpirationUpdated)a.F.onExpirationUpdated(b,c);b=Sl("expirationupdated");a.dispatchEvent(b)}function sm(a,b,c){0<b&&(a.S()||a.eg(b));b=a.getDuration();c<b&&(a.S()||a.Ka(c))}
578
580
  function en(a,b){a=a.o?a.o.ud():{};var c=Object.keys(a);c=c.length&&"00"==c[0];var d=!1,e=!1,f=new Set,g=new Set;b=t(b.variants);for(var h=b.next();!h.done;h=b.next()){h=h.value;var k=[];h.audio&&k.push(h.audio);h.video&&k.push(h.video);k=t(k);for(var l=k.next();!l.done;l=k.next())if(l=l.value,l.keyIds.size){l=t(l.keyIds);for(var m=l.next();!m.done;m=l.next()){m=m.value;var n=a[c?"00":m];n?hn.includes(n)&&g.add(n):f.add(m)}}h.allowedByApplication?h.allowedByKeySystem&&(d=!0):e=!0}if(!d)throw a={hasAppRestrictions:e,
579
581
  missingKeys:Array.from(f),restrictedKeyStatuses:Array.from(g)},new O(2,4,4012,a);}function fn(a,b){K(function(c){if(1==c.g)return C(c,Promise.resolve(),2);a.l!=Tl&&a.dispatchEvent(b);E(c)})}function Ym(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(Zc(c.language)):b.add("und");return b}
580
582
  function Xm(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=Zc(d.language));"variant"==d.type?f=d.audioRoles:f=d.roles;f&&f.length||(f=[""]);b.has(e)||b.set(e,new Set);f=t(f);for(var g=f.next();!g.done;g=f.next())g=g.value,b.get(e).add(g),d.label&&(c.has(e)||c.set(e,new Map),c.get(e).set(g,d.label))}var h=[];b.forEach(function(k,l){k=t(k);for(var m=k.next();!m.done;m=k.next()){m=m.value;var n=null;c.has(l)&&c.get(l).has(m)&&(n=c.get(l).get(m));
581
- h.push({language:l,role:m,label:n})}});return h}N("shaka.Player",W);W.prototype.setVideoContainer=W.prototype.fg;W.prototype.getManifestParserFactory=W.prototype.Mg;W.prototype.getManifest=W.prototype.Lg;W.prototype.retryStreaming=W.prototype.Ye;W.prototype.setMaxHardwareResolution=W.prototype.df;W.prototype.addChaptersTrack=W.prototype.mg;W.prototype.addThumbnailsTrack=W.prototype.og;W.prototype.addTextTrackAsync=W.prototype.ng;W.prototype.getStats=W.prototype.getStats;
582
- W.prototype.getBufferedInfo=W.prototype.gb;W.prototype.getPresentationStartTimeAsDate=W.prototype.Ff;W.prototype.getPlayheadTimeAsDate=W.prototype.Qg;W.prototype.setTextTrackVisibility=W.prototype.Jh;W.prototype.getChapters=W.prototype.Eg;W.prototype.getChaptersTracks=W.prototype.Ef;W.prototype.isTextTrackVisible=W.prototype.De;W.prototype.selectVariantsByLabel=W.prototype.Eh;W.prototype.selectTextLanguage=W.prototype.Yf;W.prototype.selectAudioLanguage=W.prototype.Xf;
583
- W.prototype.getTextLanguages=W.prototype.Sg;W.prototype.getAudioLanguages=W.prototype.Bg;W.prototype.getTextLanguagesAndRoles=W.prototype.Tg;W.prototype.getAudioLanguagesAndRoles=W.prototype.Cg;W.prototype.selectVariantTrack=W.prototype.af;W.prototype.selectTextTrack=W.prototype.Zf;W.prototype.getThumbnails=W.prototype.Gf;W.prototype.getAllThumbnails=W.prototype.Ag;W.prototype.getImageTracks=W.prototype.Jg;W.prototype.getTextTracks=W.prototype.$b;W.prototype.getVariantTracks=W.prototype.wb;
584
- W.prototype.cancelTrickPlay=W.prototype.tf;W.prototype.trickPlay=W.prototype.kf;W.prototype.getPlaybackRate=W.prototype.vd;W.prototype.isBuffering=W.prototype.Be;W.prototype.getKeyStatuses=W.prototype.ud;W.prototype.getActiveSessionsMetadata=W.prototype.ve;W.prototype.getExpiration=W.prototype.Kc;W.prototype.drmInfo=W.prototype.drmInfo;W.prototype.keySystem=W.prototype.keySystem;W.prototype.goToLive=W.prototype.$g;W.prototype.seekRange=W.prototype.Ab;W.prototype.isAudioOnly=W.prototype.dh;
585
- W.prototype.isInProgress=W.prototype.Mb;W.prototype.isLive=W.prototype.S;W.prototype.getAdManager=W.prototype.Df;W.prototype.getAssetUri=W.prototype.we;W.prototype.getNetworkingEngine=W.prototype.Ib;W.prototype.getMediaElement=W.prototype.Og;W.prototype.getManifestType=W.prototype.xe;W.prototype.getLoadMode=W.prototype.Kg;W.prototype.resetConfiguration=W.prototype.Ah;W.prototype.getBufferFullness=W.prototype.Dg;W.prototype.getConfiguration=W.prototype.getConfiguration;W.prototype.configure=W.prototype.configure;
586
- W.prototype.releaseAllMutexes=W.prototype.wh;W.prototype.load=W.prototype.load;W.prototype.updateStartTime=W.prototype.Oh;W.prototype.unload=W.prototype.jc;W.prototype.detach=W.prototype.detach;W.prototype.attachCanvas=W.prototype.qg;W.prototype.attach=W.prototype.Cc;
587
- W.probeSupport=function(a){a=void 0===a?!0:a;var b,c,d,e,f,g;return K(function(h){if(1==h.g)return b={},a?C(h,gh(),3):h.B(2);2!=h.g&&(b=h.h);var k={};if(jd())for(var l in ph)k[l]=!0;l=t(["application/dash+xml","application/x-mpegurl","application/vnd.apple.mpegurl","application/vnd.ms-sstr+xml"]);for(var m=l.next();!m.done;m=l.next())m=m.value,k[m]=jd()?!!ph[m]:kd(m);c=k;l='video/mp4; codecs="avc1.42E01E",video/mp4; codecs="avc3.42E01E",video/mp4; codecs="hev1.1.6.L93.90",video/mp4; codecs="hvc1.1.6.L93.90",video/mp4; codecs="hev1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="hvc1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="vp9",video/mp4; codecs="vp09.00.10.08",video/mp4; codecs="av01.0.01M.08",video/mp4; codecs="dvh1.20.01",audio/mp4; codecs="mp4a.40.2",audio/mp4; codecs="ac-3",audio/mp4; codecs="ec-3",audio/mp4; codecs="ac-4",audio/mp4; codecs="opus",audio/mp4; codecs="flac",audio/mp4; codecs="dtsc",audio/mp4; codecs="dtse",audio/mp4; codecs="dtsx",video/webm; codecs="vp8",video/webm; codecs="vp9",video/webm; codecs="vp09.00.10.08",audio/webm; codecs="vorbis",audio/webm; codecs="opus",video/mp2t; codecs="avc1.42E01E",video/mp2t; codecs="avc3.42E01E",video/mp2t; codecs="hvc1.1.6.L93.90",video/mp2t; codecs="mp4a.40.2",video/mp2t; codecs="ac-3",video/mp2t; codecs="ec-3",text/vtt,application/mp4; codecs="wvtt",application/ttml+xml,application/mp4; codecs="stpp"'.split(",").concat(w(Fc));
583
+ h.push({language:l,role:m,label:n})}});return h}N("shaka.Player",V);V.prototype.setVideoContainer=V.prototype.fg;V.prototype.getManifestParserFactory=V.prototype.Mg;V.prototype.getManifest=V.prototype.Lg;V.prototype.retryStreaming=V.prototype.Ye;V.prototype.setMaxHardwareResolution=V.prototype.df;V.prototype.addChaptersTrack=V.prototype.mg;V.prototype.addThumbnailsTrack=V.prototype.og;V.prototype.addTextTrackAsync=V.prototype.ng;V.prototype.getStats=V.prototype.getStats;
584
+ V.prototype.getBufferedInfo=V.prototype.gb;V.prototype.getPresentationStartTimeAsDate=V.prototype.Ff;V.prototype.getPlayheadTimeAsDate=V.prototype.Qg;V.prototype.setTextTrackVisibility=V.prototype.Jh;V.prototype.getChapters=V.prototype.Eg;V.prototype.getChaptersTracks=V.prototype.Ef;V.prototype.isTextTrackVisible=V.prototype.De;V.prototype.selectVariantsByLabel=V.prototype.Eh;V.prototype.selectTextLanguage=V.prototype.Yf;V.prototype.selectAudioLanguage=V.prototype.Xf;
585
+ V.prototype.getTextLanguages=V.prototype.Sg;V.prototype.getAudioLanguages=V.prototype.Bg;V.prototype.getTextLanguagesAndRoles=V.prototype.Tg;V.prototype.getAudioLanguagesAndRoles=V.prototype.Cg;V.prototype.selectVariantTrack=V.prototype.af;V.prototype.selectTextTrack=V.prototype.Zf;V.prototype.getThumbnails=V.prototype.Gf;V.prototype.getAllThumbnails=V.prototype.Ag;V.prototype.getImageTracks=V.prototype.Jg;V.prototype.getTextTracks=V.prototype.$b;V.prototype.getVariantTracks=V.prototype.wb;
586
+ V.prototype.cancelTrickPlay=V.prototype.tf;V.prototype.trickPlay=V.prototype.kf;V.prototype.getPlaybackRate=V.prototype.vd;V.prototype.isBuffering=V.prototype.Be;V.prototype.getKeyStatuses=V.prototype.ud;V.prototype.getActiveSessionsMetadata=V.prototype.ve;V.prototype.getExpiration=V.prototype.Kc;V.prototype.drmInfo=V.prototype.drmInfo;V.prototype.keySystem=V.prototype.keySystem;V.prototype.goToLive=V.prototype.$g;V.prototype.seekRange=V.prototype.Pb;V.prototype.isAudioOnly=V.prototype.dh;
587
+ V.prototype.isInProgress=V.prototype.Lb;V.prototype.isLive=V.prototype.S;V.prototype.getAdManager=V.prototype.Df;V.prototype.getAssetUri=V.prototype.we;V.prototype.getNetworkingEngine=V.prototype.Hb;V.prototype.getMediaElement=V.prototype.Og;V.prototype.getManifestType=V.prototype.xe;V.prototype.getLoadMode=V.prototype.Kg;V.prototype.resetConfiguration=V.prototype.Ah;V.prototype.getBufferFullness=V.prototype.Dg;V.prototype.getConfiguration=V.prototype.getConfiguration;V.prototype.configure=V.prototype.configure;
588
+ V.prototype.releaseAllMutexes=V.prototype.wh;V.prototype.load=V.prototype.load;V.prototype.updateStartTime=V.prototype.Oh;V.prototype.unload=V.prototype.jc;V.prototype.detach=V.prototype.detach;V.prototype.attachCanvas=V.prototype.qg;V.prototype.attach=V.prototype.Cc;
589
+ V.probeSupport=function(a){a=void 0===a?!0:a;var b,c,d,e,f,g;return K(function(h){if(1==h.g)return b={},a?C(h,gh(),3):h.B(2);2!=h.g&&(b=h.h);var k={};if(jd())for(var l in ph)k[l]=!0;l=t(["application/dash+xml","application/x-mpegurl","application/vnd.apple.mpegurl","application/vnd.ms-sstr+xml"]);for(var m=l.next();!m.done;m=l.next())m=m.value,k[m]=jd()?!!ph[m]:kd(m);c=k;l='video/mp4; codecs="avc1.42E01E",video/mp4; codecs="avc3.42E01E",video/mp4; codecs="hev1.1.6.L93.90",video/mp4; codecs="hvc1.1.6.L93.90",video/mp4; codecs="hev1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="hvc1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="vp9",video/mp4; codecs="vp09.00.10.08",video/mp4; codecs="av01.0.01M.08",video/mp4; codecs="dvh1.20.01",audio/mp4; codecs="mp4a.40.2",audio/mp4; codecs="ac-3",audio/mp4; codecs="ec-3",audio/mp4; codecs="ac-4",audio/mp4; codecs="opus",audio/mp4; codecs="flac",audio/mp4; codecs="dtsc",audio/mp4; codecs="dtse",audio/mp4; codecs="dtsx",video/webm; codecs="vp8",video/webm; codecs="vp9",video/webm; codecs="vp09.00.10.08",audio/webm; codecs="vorbis",audio/webm; codecs="opus",video/mp2t; codecs="avc1.42E01E",video/mp2t; codecs="avc3.42E01E",video/mp2t; codecs="hvc1.1.6.L93.90",video/mp2t; codecs="mp4a.40.2",video/mp2t; codecs="ac-3",video/mp2t; codecs="ec-3",text/vtt,application/mp4; codecs="wvtt",application/ttml+xml,application/mp4; codecs="stpp"'.split(",").concat(w(Fc));
588
590
  k={};l=t(l);for(m=l.next();!m.done;m=l.next()){m=m.value;k[m]=jd()?Nc(m)?!0:bb(m)||($b(m)?!0:!1):kd(m);var n=m.split(";")[0];k[n]=k[n]||k[m]}d=k;e={manifest:c,media:d,drm:b};f=jn;for(g in f)e[g]=f[g]();return h.return(e)})};
589
- W.isBrowserSupported=function(){window.Promise||Ta("A Promise implementation or polyfill is required");if(!(window.Promise&&window.Uint8Array&&Array.prototype.forEach)||od("Trident/"))return!1;var a=vd();return a&&9>a||!(window.MediaKeys&&window.navigator&&window.navigator.requestMediaKeySystemAccess&&window.MediaKeySystemAccess&&window.MediaKeySystemAccess.prototype.getConfiguration)?!1:jd()?!0:kd("application/x-mpegurl")};W.setAdManagerFactory=function(a){Nl=a};
590
- W.registerSupportPlugin=function(a,b){jn[a]=b};W.prototype.destroy=W.prototype.destroy;var Tl=0,Jl=1,vm=2,Km=3;W.LoadMode={DESTROYED:Tl,NOT_LOADED:Jl,MEDIA_SOURCE:vm,SRC_EQUALS:Km};W.version="v4.6.3";var kn=["4","6"];me=new function(a){this.g=a;this.i=ne;this.h=oe}(new ke(Number(kn[0]),Number(kn[1])));var hn=["output-restricted","internal-error"],jn={},Nl=null;function ln(){this.h=[];this.j=this.i=this.g=0};function mn(a,b,c){var d=this;this.g=a;this.h=b;this.m=c;this.i=!1;this.l=this.h.getVolume();this.j=new of;this.j.D(this.h,google.ima.AdEvent.Type.PAUSED,function(){d.i=!0});this.j.D(this.h,google.ima.AdEvent.Type.RESUMED,function(){d.i=!1})}q=mn.prototype;q.getDuration=function(){return this.g.getDuration()};q.getMinSuggestedDuration=function(){return this.g.getMinSuggestedDuration()};q.getRemainingTime=function(){return this.h.getRemainingTime()};q.isPaused=function(){return this.i};
591
+ V.isBrowserSupported=function(){window.Promise||Ta("A Promise implementation or polyfill is required");if(!(window.Promise&&window.Uint8Array&&Array.prototype.forEach)||od("Trident/"))return!1;var a=vd();return a&&9>a||!(window.MediaKeys&&window.navigator&&window.navigator.requestMediaKeySystemAccess&&window.MediaKeySystemAccess&&window.MediaKeySystemAccess.prototype.getConfiguration)?!1:jd()?!0:kd("application/x-mpegurl")};V.setAdManagerFactory=function(a){Nl=a};
592
+ V.registerSupportPlugin=function(a,b){jn[a]=b};V.prototype.destroy=V.prototype.destroy;var Tl=0,Jl=1,vm=2,Km=3;V.LoadMode={DESTROYED:Tl,NOT_LOADED:Jl,MEDIA_SOURCE:vm,SRC_EQUALS:Km};V.version="v4.6.5";var kn=["4","6"];me=new function(a){this.g=a;this.i=ne;this.h=oe}(new ke(Number(kn[0]),Number(kn[1])));var hn=["output-restricted","internal-error"],jn={},Nl=null;function ln(){this.h=[];this.j=this.i=this.g=0};function mn(a,b,c){var d=this;this.g=a;this.h=b;this.m=c;this.i=!1;this.l=this.h.getVolume();this.j=new of;this.j.D(this.h,google.ima.AdEvent.Type.PAUSED,function(){d.i=!0});this.j.D(this.h,google.ima.AdEvent.Type.RESUMED,function(){d.i=!1})}q=mn.prototype;q.getDuration=function(){return this.g.getDuration()};q.getMinSuggestedDuration=function(){return this.g.getMinSuggestedDuration()};q.getRemainingTime=function(){return this.h.getRemainingTime()};q.isPaused=function(){return this.i};
591
593
  q.isSkippable=function(){return 0<=this.g.getSkipTimeOffset()};q.getTimeUntilSkippable=function(){var a=this.g.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};q.canSkipNow=function(){return this.h.getAdSkippableState()};q.skip=function(){return this.h.skip()};q.pause=function(){return this.h.pause()};q.play=function(){return this.h.resume()};q.getVolume=function(){return this.h.getVolume()};q.setVolume=function(a){return this.h.setVolume(a)};q.isMuted=function(){return 0==this.h.getVolume()};
592
594
  q.isLinear=function(){return this.g.isLinear()};q.resize=function(a,b){var c=!1,d=this.m;document.fullscreenEnabled?c=!!document.fullscreenElement:d.webkitSupportsFullscreen&&(c=d.webkitDisplayingFullscreen);this.h.resize(a,b,c?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)};q.setMuted=function(a){a?(this.l=this.getVolume(),this.setVolume(0)):this.setVolume(this.l)};q.getSequenceLength=function(){var a=this.g.getAdPodInfo();return null==a?1:a.getTotalAds()};
593
595
  q.getPositionInSequence=function(){var a=this.g.getAdPodInfo();return null==a?1:a.getAdPosition()};q.getTitle=function(){return this.g.getTitle()};q.getDescription=function(){return this.g.getDescription()};q.getVastMediaBitrate=function(){return this.g.getVastMediaBitrate()};q.getVastMediaHeight=function(){return this.g.getVastMediaHeight()};q.getVastMediaWidth=function(){return this.g.getVastMediaWidth()};q.getAdId=function(){return this.g.getAdId()};q.getCreativeAdId=function(){return this.g.getCreativeAdId()};
594
596
  q.getAdvertiserName=function(){return this.g.getAdvertiserName()};q.getMediaUrl=function(){return this.g.getMediaUrl()};q.getTimeOffset=function(){var a=this.g.getAdPodInfo();return null==a?0:a.getTimeOffset()};q.getPodIndex=function(){var a=this.g.getAdPodInfo();return null==a?0:a.getPodIndex()};q.release=function(){this.h=this.g=null};N("shaka.ads.ClientSideAd",mn);mn.prototype.release=mn.prototype.release;mn.prototype.getPodIndex=mn.prototype.getPodIndex;mn.prototype.getTimeOffset=mn.prototype.getTimeOffset;
595
597
  mn.prototype.getMediaUrl=mn.prototype.getMediaUrl;mn.prototype.getAdvertiserName=mn.prototype.getAdvertiserName;mn.prototype.getCreativeAdId=mn.prototype.getCreativeAdId;mn.prototype.getAdId=mn.prototype.getAdId;mn.prototype.getVastMediaWidth=mn.prototype.getVastMediaWidth;mn.prototype.getVastMediaHeight=mn.prototype.getVastMediaHeight;mn.prototype.getVastMediaBitrate=mn.prototype.getVastMediaBitrate;mn.prototype.getDescription=mn.prototype.getDescription;mn.prototype.getTitle=mn.prototype.getTitle;
596
598
  mn.prototype.getPositionInSequence=mn.prototype.getPositionInSequence;mn.prototype.getSequenceLength=mn.prototype.getSequenceLength;mn.prototype.setMuted=mn.prototype.setMuted;mn.prototype.resize=mn.prototype.resize;mn.prototype.isLinear=mn.prototype.isLinear;mn.prototype.isMuted=mn.prototype.isMuted;mn.prototype.setVolume=mn.prototype.setVolume;mn.prototype.getVolume=mn.prototype.getVolume;mn.prototype.play=mn.prototype.play;mn.prototype.pause=mn.prototype.pause;mn.prototype.skip=mn.prototype.skip;
597
- mn.prototype.canSkipNow=mn.prototype.canSkipNow;mn.prototype.getTimeUntilSkippable=mn.prototype.getTimeUntilSkippable;mn.prototype.isSkippable=mn.prototype.isSkippable;mn.prototype.isPaused=mn.prototype.isPaused;mn.prototype.getRemainingTime=mn.prototype.getRemainingTime;mn.prototype.getMinSuggestedDuration=mn.prototype.getMinSuggestedDuration;mn.prototype.getDuration=mn.prototype.getDuration;function nn(a,b,c,d,e){var f=this;this.o=a;this.i=b;this.A=!1;this.s=this.C=null;this.F=NaN;this.m=e;this.j=null;this.h=new of;google.ima.settings.setLocale(c);google.ima.settings.setDisableCustomPlaybackForIOS10Plus(!0);a=new google.ima.AdDisplayContainer(this.o,this.i);a.initialize();this.l=new google.ima.AdsLoader(a);this.l.getSettings().setPlayerType("shaka-player");this.l.getSettings().setPlayerVersion("v4.6.3");this.g=null;this.u=d||new google.ima.AdsRenderingSettings;this.h.D(this.l,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,
599
+ mn.prototype.canSkipNow=mn.prototype.canSkipNow;mn.prototype.getTimeUntilSkippable=mn.prototype.getTimeUntilSkippable;mn.prototype.isSkippable=mn.prototype.isSkippable;mn.prototype.isPaused=mn.prototype.isPaused;mn.prototype.getRemainingTime=mn.prototype.getRemainingTime;mn.prototype.getMinSuggestedDuration=mn.prototype.getMinSuggestedDuration;mn.prototype.getDuration=mn.prototype.getDuration;function nn(a,b,c,d,e){var f=this;this.o=a;this.i=b;this.A=!1;this.s=this.C=null;this.F=NaN;this.m=e;this.j=null;this.h=new of;google.ima.settings.setLocale(c);google.ima.settings.setDisableCustomPlaybackForIOS10Plus(!0);a=new google.ima.AdDisplayContainer(this.o,this.i);a.initialize();this.l=new google.ima.AdsLoader(a);this.l.getSettings().setPlayerType("shaka-player");this.l.getSettings().setPlayerVersion("v4.6.5");this.g=null;this.u=d||new google.ima.AdsRenderingSettings;this.h.D(this.l,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,
598
600
  function(g){on(f,g)});this.h.D(this.l,google.ima.AdErrorEvent.Type.AD_ERROR,function(g){pn(f,g)});this.h.D(this.i,"ended",function(){f.l.contentComplete()});this.h.ha(this.i,"play",function(){f.A=!0})}nn.prototype.configure=function(a){this.C=a};nn.prototype.stop=function(){this.g&&this.g.stop();this.o&&Kk(this.o)};nn.prototype.release=function(){this.stop();this.s&&this.s.disconnect();this.h&&this.h.release();this.g&&this.g.destroy();this.l.destroy()};
599
601
  function pn(a,b){b.getError();b=(new Map).set("originalEvent",b);a.m(new Q("ad-error",b));qn(a,null);a.m(new Q("ad-cue-points-changed",(new Map).set("cuepoints",[])))}
600
602
  function on(a,b){a.m(new Q("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.F)));if(a.C.customPlayheadTracker){var c={currentTime:a.i.currentTime};a.g=b.getAdsManager(c,a.u);a.i.muted?a.g.setVolume(0):a.g.setVolume(a.i.volume);a.h.D(a.i,"timeupdate",function(){a.i.duration&&(c.currentTime=a.i.currentTime)});a.h.D(a.i,"volumechange",function(){a.i.muted?a.g.setVolume(0):a.g.setVolume(a.i.volume)})}else a.g=b.getAdsManager(a.i,a.u);a.m(new Q("ima-ad-manager-loaded",(new Map).set("imaAdManager",
@@ -644,8 +646,8 @@ function In(a,b){a.i(new Q("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-
644
646
  q.release=function(){this.h&&(this.h.release(),this.h=null);this.i&&(this.i.release(),this.i=null);this.g&&(this.g.release(),this.g=null);Ve.prototype.release.call(this)};q.onAssetUnload=function(){this.h&&this.h.stop();this.i&&this.i.stop();this.g&&this.g.stop();this.dispatchEvent(new Q("ad-stopped"));this.j=new ln};q.requestClientSideAds=function(a){if(!this.h)throw new O(1,10,10001);var b=this.h;b.g&&b.g.destroy();b.l&&b.l.contentComplete();b.F=Date.now()/1E3;b.l.requestAds(a)};
645
647
  q.updateClientSideAdsRenderingSettings=function(a){if(!this.h)throw new O(1,10,10001);var b=this.h;b.u=a;b.g&&b.g.updateAdsRenderingSettings(b.u)};q.initMediaTailor=function(a,b,c){var d=this;this.i&&this.i.release();this.i=new vn(a,b,c,function(e){return Jn(d,e)})};q.requestMediaTailorStream=function(a,b,c){if(!this.i)throw new O(1,10,10005);var d=this.i;c=void 0===c?"":c;d.l?a=Promise.reject(new O(1,10,10004)):(d.l=new Le,yn(d,a,b),d.G=c||"",d.W=Date.now()/1E3,a=d.l);return a};
646
648
  q.initServerSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.dai)throw new O(2,10,10002);this.g&&this.g.release();this.g=new Hn(a,b,this.m,function(d){return Jn(c,d)});this.g.configure(this.l)};
647
- q.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new O(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Ta('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.adTagParameters.mpt="shaka-player";a.adTagParameters.mpv="v4.6.3";c=this.g;c.j?a=Promise.reject(new O(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
648
- (c.G=!0),c.j=new Le,c.g.requestStream(a),c.A=b||"",c.F=Date.now()/1E3,a=c.j);return a};q.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new O(1,10,10003);(a.mpt||a.mpv)&&Ta('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.mpt="Shaka Player";a.mpv="v4.6.3";this.g.g.replaceAdTagParameters(a)};
649
+ q.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new O(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Ta('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.adTagParameters.mpt="shaka-player";a.adTagParameters.mpv="v4.6.5";c=this.g;c.j?a=Promise.reject(new O(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
650
+ (c.G=!0),c.j=new Le,c.g.requestStream(a),c.A=b||"",c.F=Date.now()/1E3,a=c.j);return a};q.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new O(1,10,10003);(a.mpt||a.mpv)&&Ta('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.mpt="Shaka Player";a.mpv="v4.6.5";this.g.g.replaceAdTagParameters(a)};
649
651
  q.getServerSideCuePoints=function(){le("AdManager","Please use getCuePoints function.");return this.getCuePoints()};q.getCuePoints=function(){var a=[];this.g&&(a=a.concat(this.g.getCuePoints()));this.i&&(a=a.concat(this.i.getCuePoints()));return a};q.getStats=function(){var a=this.j;return{loadTimes:a.h,started:a.g,playedCompletely:a.i,skipped:a.j}};q.onManifestUpdated=function(a){if(this.i)this.i.onManifestUpdated(a)};
650
652
  q.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)}};q.onHlsTimedMetadata=function(a,b){this.g&&this.g.g.processMetadata("ID3",a.data,b)};q.onCueMetadataChange=function(a){if(this.g)this.g.onCueMetadataChange(a)};
651
653
  function Jn(a,b){if(b&&b.type)switch(b.type){case "ads-loaded":a.j.h.push(b.loadTime);break;case "ad-started":a.j.g++;break;case "ad-complete":a.j.i++;break;case "ad-skipped":a.j.j++}a.dispatchEvent(b)}N("shaka.ads.AdManager",Y);Y.prototype.onCueMetadataChange=Y.prototype.onCueMetadataChange;Y.prototype.onHlsTimedMetadata=Y.prototype.onHlsTimedMetadata;Y.prototype.onDashTimedMetadata=Y.prototype.onDashTimedMetadata;Y.prototype.onManifestUpdated=Y.prototype.onManifestUpdated;Y.prototype.getStats=Y.prototype.getStats;
@@ -679,7 +681,7 @@ function po(a){var b=new Q(a.l.paused?"pause":"play");a.j.dispatchEvent(b)}
679
681
  function ro(a){for(var b=t(Un),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(Pn);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(Pn),k=h.next();!k.done;k=h.next())k=k.value,a.i[k]=g[k];h=t(Vn);for(k=
680
682
  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("error",h);a.h.dispatchEvent(h)})}
681
683
  function uo(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.Ga()&&0==Object.keys(a.g.g.video).length){var c=a.i[b];if("function"!=typeof c)return c}return a.g.Ga()?a.g.get("video",b):(b=a.i[b],"function"==typeof b&&(b=b.bind(a.i)),b)}
682
- function wo(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.Ib()};if("getDrmEngine"==b)return function(){return a.h.o};if("getAdManager"==b)return function(){return a.h.Df()};
684
+ function wo(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.Hb()};if("getDrmEngine"==b)return function(){return a.h.o};if("getAdManager"==b)return function(){return a.h.Df()};
683
685
  if("setVideoContainer"==b)return function(c){return a.h.fg(c)};if(a.g.Ga()){if("getManifest"==b||"drmInfo"==b)return function(){Ta(b+"() does not work while casting!");return null};if("attach"==b||"detach"==b)return function(){Ta(b+"() does not work while casting!");return Promise.resolve()}}return a.g.Ga()&&0==Object.keys(a.g.g.video).length&&(Rn[b]||Sn[b])||!a.g.Ga()?a.h[b].bind(a.h):a.g.get("player",b)}
684
686
  function qo(a,b,c){a.g.Ga()&&("video"==b?a.j.dispatchEvent(c):"player"==b&&a.o.dispatchEvent(c))}N("shaka.cast.CastProxy",no);no.prototype.changeReceiverId=no.prototype.tg;no.prototype.forceDisconnect=no.prototype.Xb;no.prototype.suggestDisconnect=no.prototype.Kh;no.prototype.setAppData=no.prototype.bf;no.prototype.cast=no.prototype.cast;no.prototype.receiverName=no.prototype.We;no.prototype.isCasting=no.prototype.Ga;no.prototype.canCast=no.prototype.sg;no.prototype.getPlayer=no.prototype.Pg;
685
687
  no.prototype.getVideo=no.prototype.Yg;no.prototype.destroy=no.prototype.destroy;function yo(a,b,c,d){Ve.call(this);var e=this;this.g=a;this.h=b;this.j=new of;this.H={video:a,player:b};this.C=c||function(){};this.I=d||function(f){return f};this.i=null;this.F=!1;this.o=!0;this.m=0;this.A=!1;this.u=!0;this.s=this.l=null;this.G=new id(function(){zo(e)});Ao(this)}oa(yo,Ve);q=yo.prototype;q.isConnected=function(){return this.F};q.eh=function(){return this.o};q.Hh=function(a){this.i=a};q.wg=function(){this.i=null};
@@ -698,8 +700,8 @@ function Eo(a,b){var c=Ln(b.data);switch(c.type){case "init":a.m=0;a.A=!1;a.u=!0
698
700
  function Do(a,b){var c=Ln(b.data);switch(c.type){case "PLAY":a.g.play();Jo(a);break;case "PAUSE":a.g.pause();Jo(a);break;case "SEEK":b=c.currentTime;var d=c.resumeState;null!=b&&(a.g.currentTime=Number(b));d&&"PLAYBACK_START"==d?(a.g.play(),Jo(a)):d&&"PLAYBACK_PAUSE"==d&&(a.g.pause(),Jo(a));break;case "STOP":a.h.jc().then(function(){a.h&&Jo(a)});break;case "GET_STATUS":Mo(a,Number(c.requestId));break;case "VOLUME":d=c.volume;b=d.level;d=d.muted;var e=a.g.volume,f=a.g.muted;null!=b&&(a.g.volume=Number(b));
699
701
  null!=d&&(a.g.muted=d);e==a.g.volume&&f==a.g.muted||Jo(a);break;case "LOAD":a.m=0;a.A=!1;a.u=!1;b=c.media;d=c.currentTime;e=a.I(b.contentId);f=c.autoplay||!0;a.C(b.customData);f&&(a.g.autoplay=!0);a.h.load(e,d).then(function(){a.h&&Mo(a)}).catch(function(g){var h="LOAD_FAILED";7==g.category&&7E3==g.code&&(h="LOAD_CANCELLED");Co(a,{requestId:Number(c.requestId),type:h},a.s)});break;default:Co(a,{requestId:Number(c.requestId),type:"INVALID_REQUEST",reason:"INVALID_COMMAND"},a.s)}}
700
702
  function No(a,b,c,d){a.h&&Co(a,{type:"asyncComplete",id:c,error:d},a.l,b)}function Co(a,b,c,d){a.F&&(a=Kn(b),d?c.getCastChannel(d).send(a):c.broadcast(a))}function Jo(a,b,c){c=void 0===c?null:c;var d={mediaSessionId:0,playbackRate:a.g.playbackRate,playerState:a.o?Oo:a.h.Be()?Po:a.g.paused?Qo:Ro,currentTime:a.g.currentTime,supportedMediaCommands:63,volume:{level:a.g.volume,muted:a.g.muted}};c&&(d.media=c);Co(a,{requestId:void 0===b?0:b,type:"MEDIA_STATUS",status:[d]},a.s)}
701
- N("shaka.cast.CastReceiver",yo);yo.prototype.destroy=yo.prototype.destroy;yo.prototype.setContentArtist=yo.prototype.Fh;yo.prototype.setContentImage=yo.prototype.Gh;yo.prototype.setContentTitle=yo.prototype.Ih;yo.prototype.clearContentMetadata=yo.prototype.wg;yo.prototype.setContentMetadata=yo.prototype.Hh;yo.prototype.isIdle=yo.prototype.eh;yo.prototype.isConnected=yo.prototype.isConnected;var Lo=.5,Ho=5,Oo="IDLE",Ro="PLAYING",Po="BUFFERING",Qo="PAUSED";function So(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(A){return null!=A&&""!=A.g.trim()})){f=h;break}for(h=c.length-1;0<=h;h--)if(c[h].some(function(A){return null!=A&&""!=A.g.trim()})){g=h;break}if(-1===f||-1===g)return null;for(var k=h=!1,l="white",m="black",n=To(d,e,h,k,l,m);f<=g;f++){for(var r=c[f],p=-1,u=-1,v=0;v<r.length;v++)if(null!=r[v]&&""!==r[v].g.trim()){p=v;break}for(v=r.length-1;0<=v;v--)if(null!=r[v]&&""!==r[v].g.trim()){u=v;break}if(-1===
702
- p||-1===u)r=Uo(d,e),a.nestedCues.push(r);else{for(;p<=u;p++)if(v=r[p]){var x=v.l,z=v.i,y=v.j,B=v.h;if(x!=h||z!=k||y!=l||B!=m)n.payload&&a.nestedCues.push(n),n=To(d,e,x,z,y,B),h=x,k=z,l=y,m=B;n.payload+=v.g}else n.payload+=" ";n.payload&&a.nestedCues.push(n);f!==g&&(n=Uo(d,e),a.nestedCues.push(n));n=To(d,e,h,k,l,m)}}return a.nestedCues.length?{cue:a,stream:b}:null}
703
+ N("shaka.cast.CastReceiver",yo);yo.prototype.destroy=yo.prototype.destroy;yo.prototype.setContentArtist=yo.prototype.Fh;yo.prototype.setContentImage=yo.prototype.Gh;yo.prototype.setContentTitle=yo.prototype.Ih;yo.prototype.clearContentMetadata=yo.prototype.wg;yo.prototype.setContentMetadata=yo.prototype.Hh;yo.prototype.isIdle=yo.prototype.eh;yo.prototype.isConnected=yo.prototype.isConnected;var Lo=.5,Ho=5,Oo="IDLE",Ro="PLAYING",Po="BUFFERING",Qo="PAUSED";function So(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=To(d,e,h,k,l,m);f<=g;f++){for(var r=c[f],p=-1,u=-1,v=0;v<r.length;v++)if(null!=r[v]&&""!==r[v].g.trim()){p=v;break}for(v=r.length-1;0<=v;v--)if(null!=r[v]&&""!==r[v].g.trim()){u=v;break}if(-1===
704
+ p||-1===u)r=Uo(d,e),a.nestedCues.push(r);else{for(;p<=u;p++)if(v=r[p]){var x=v.l,z=v.i,y=v.j,A=v.h;if(x!=h||z!=k||y!=l||A!=m)n.payload&&a.nestedCues.push(n),n=To(d,e,x,z,y,A),h=x,k=z,l=y,m=A;n.payload+=v.g}else n.payload+=" ";n.payload&&a.nestedCues.push(n);f!==g&&(n=Uo(d,e),a.nestedCues.push(n));n=To(d,e,h,k,l,m)}}return a.nestedCues.length?{cue:a,stream:b}:null}
703
705
  function To(a,b,c,d,e,f){a=new Bb(a,b,"");c&&a.textDecoration.push("underline");d&&(a.fontStyle="italic");a.color=e;a.backgroundColor=f;return a}function Uo(a,b){a=new Bb(a,b,"");a.lineBreak=!0;return a}function Vo(a,b,c,d,e){this.g=a;this.l=b;this.i=c;this.h=d;this.j=e};function Wo(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";Xo(this)}function Yo(a,b,c){var d="CC"+(a.u<<1|a.s+1),e=new Bb(b,c,"");e.lineInterpretation=1;var f=Zo.get(a.g);f&&(e.line=f);return So(e,d,a.i,b,c)}function Xo(a){$o(a,0,15);a.g=1}
704
706
  function ap(a,b,c){if(!(32>c||127<c)){var d="";switch(b){case bp:d=cp.has(c)?cp.get(c):String.fromCharCode(c);break;case dp:d=ep.get(c);break;case fp:a.i[a.g].pop();d=gp.get(c);break;case hp:a.i[a.g].pop(),d=ip.get(c)}d&&a.i[a.g].push(new Vo(d,a.m,a.j,a.o,a.l))}}function jp(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 $o(a,b,c){for(var d=0;d<=c;d++)a.i[b+d]=[]}
705
707
  var bp=0,dp=1,fp=2,hp=3,cp=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"]]),ep=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"]]),gp=new Map([[32,"\u00c1"],[33,"\u00c9"],[34,"\u00d3"],
@@ -754,40 +756,40 @@ d)}function xq(a){var b=a.g.pa(),c=a.g.ca();if(0==c)throw new O(2,3,3002);c=8-Ma
754
756
  function Aq(a){if(8<a.g.byteLength)throw new O(2,3,3002);if(8==a.g.byteLength&&a.g.getUint8(0)&224)throw new O(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 Bq(a,b,c,d,e,f,g,h,k){function l(){return e}var m=[];a=new vq(a.g);for(var n=null,r=null;a.ga();){var p=wq(a);if(187==p.id){var u=Cq(p);u&&(p=c*u.Nh,u=b+u.vh,null!=n&&m.push(new S(n+g,p+g,l,r,u-1,f,g,h,k)),n=p,r=u)}}null!=n&&m.push(new S(n+g,d+g,l,r,null,f,g,h,k));return m}
755
757
  function Cq(a){var b=new vq(a.g);a=wq(b);if(179!=a.id)throw new O(2,3,3013);a=Aq(a);b=wq(b);if(183!=b.id)throw new O(2,3,3012);b=new vq(b.g);for(var c=0;b.ga();){var d=wq(b);if(241==d.id){c=Aq(d);break}}return{Nh:a,vh:c}};function Dq(a,b,c){b=pq(a,b,"Initialization");if(!b)return null;var d=a.M.Ya(),e=b.getAttribute("sourceURL");e&&(d=wc(d,[e]));e=0;var f=null;if(b=lg(b,"range",og))e=b.start,f=b.end;return new uh(function(){return d},e,f,Eq(a),null,null,c)}
756
758
  function Fq(a,b,c){var d=Number(oq(a,Gq,"presentationTimeOffset"))||0,e=oq(a,Gq,"timescale"),f=1;e&&(f=qg(e)||1);var g=d/f||0,h=Dq(a,Gq,c);Hq(a,h);var k=Xe(a);return{Yb:function(){var l=pq(k,Gq,"RepresentationIndex");var m=k.M.Ya();l&&(l=l.getAttribute("sourceURL"))&&(m=wc(m,[l]));l=Iq(k);return Jq(k,b,h,m,l.start,l.end,g)}}}
757
- function Jq(a,b,c,d,e,f,g){var h,k,l,m,n,r,p,u,v,x,z,y,B,A,D;return K(function(F){if(1==F.g)return h=a.presentationTimeline,k=!a.ub||!a.Z.Ce,l=a.Z.start,m=a.Z.duration,n=a.M.mimeType.split("/")[1],r=b,p=null,u=[r(d,e,f,!1),"webm"==n?r(c.Y(),c.La,c.sa,!0):null],r=null,C(F,Promise.all(u),2);v=F.h;x=v[0];z=v[1]||null;y=null;B=l-g;A=l;D=m?l+m:Infinity;if("mp4"==n)var J=tq(x,e,d,c,B,A,D);else{J=new vq(z);if(440786851!=wq(J).id)throw new O(2,3,3008);var G=wq(J);if(408125543!=G.id)throw new O(2,3,3009);
758
- J=G.g.byteOffset;G=new vq(G.g);for(var H=null;G.ga();){var I=wq(G);if(357149030==I.id){H=I;break}}if(!H)throw new O(2,3,3010);H=new vq(H.g);I=1E6;for(G=null;H.ga();){var L=wq(H);if(2807729==L.id)I=Aq(L);else if(17545==L.id)if(4==L.g.byteLength)G=L.g.getFloat32(0);else if(8==L.g.byteLength)G=L.g.getFloat64(0);else throw new O(2,3,3003);}if(null==G)throw new O(2,3,3011);H=I/1E9;G*=H;I=wq(new vq(x));if(475249515!=I.id)throw new O(2,3,3007);J=Bq(I,J,H,G,d,c,B,A,D)}y=J;h.Sc(y);p=new uj(y);k&&p.Wb(A,D,
759
+ function Jq(a,b,c,d,e,f,g){var h,k,l,m,n,r,p,u,v,x,z,y,A,B,D;return K(function(F){if(1==F.g)return h=a.presentationTimeline,k=!a.ub||!a.Z.Ce,l=a.Z.start,m=a.Z.duration,n=a.M.mimeType.split("/")[1],r=b,p=null,u=[r(d,e,f,!1),"webm"==n?r(c.Y(),c.La,c.sa,!0):null],r=null,C(F,Promise.all(u),2);v=F.h;x=v[0];z=v[1]||null;y=null;A=l-g;B=l;D=m?l+m:Infinity;if("mp4"==n)var J=tq(x,e,d,c,A,B,D);else{J=new vq(z);if(440786851!=wq(J).id)throw new O(2,3,3008);var G=wq(J);if(408125543!=G.id)throw new O(2,3,3009);
760
+ J=G.g.byteOffset;G=new vq(G.g);for(var H=null;G.ga();){var I=wq(G);if(357149030==I.id){H=I;break}}if(!H)throw new O(2,3,3010);H=new vq(H.g);I=1E6;for(G=null;H.ga();){var L=wq(H);if(2807729==L.id)I=Aq(L);else if(17545==L.id)if(4==L.g.byteLength)G=L.g.getFloat32(0);else if(8==L.g.byteLength)G=L.g.getFloat64(0);else throw new O(2,3,3003);}if(null==G)throw new O(2,3,3011);H=I/1E9;G*=H;I=wq(new vq(x));if(475249515!=I.id)throw new O(2,3,3007);J=Bq(I,J,H,G,d,c,A,B,D)}y=J;h.Sc(y);p=new uj(y);k&&p.Wb(B,D,
759
761
  !0);return F.return(p)})}function Gq(a){return a.Zc}function Iq(a){var b=pq(a,Gq,"RepresentationIndex");a=oq(a,Gq,"indexRange");a=og(a||"");b&&(a=lg(b,"range",og,a));return a}function Hq(a,b){Kq(a,b);if(!Iq(a))throw new O(2,4,4002);}function Kq(a,b){var c=a.M.mimeType.split("/")[1];if(a.M.contentType!=Bc&&"mp4"!=c&&"webm"!=c)throw new O(2,4,4006);if("webm"==c&&!b)throw new O(2,4,4005);}
760
762
  function Eq(a){var b=a.M;return{bandwidth:a.bandwidth,audioSamplingRate:b.audioSamplingRate,codecs:b.codecs,contentType:b.contentType,frameRate:b.frameRate||null,height:b.height||null,mimeType:b.mimeType,channelsCount:b.Jd,pixelAspectRatio:b.pixelAspectRatio||null,width:b.width||null}};function Lq(a,b,c){var d=Dq(a,Mq,c),e=Nq(a);if(!e.ua&&!e.timeline&&1<e.cc.length)throw new O(2,4,4002);if(!e.ua&&!a.Z.duration&&!e.timeline&&1==e.cc.length)throw new O(2,4,4002);if(e.timeline&&0==e.timeline.length)throw new O(2,4,4002);var f=null,g=null;a.ra.id&&a.M.id&&(g=b[a.ra.id+","+a.M.id])&&(f=g.segmentIndex);var h=Oq(a.Z.start,a.Z.duration,a.M.Ya,e,d,c);b=!f;f?f.Rc(h,a.presentationTimeline.ib()):f=new uj(h);a.presentationTimeline.Sc(h);a.ub&&a.Z.Ce||f.Wb(a.Z.start,a.Z.duration?a.Z.start+a.Z.duration:
761
- Infinity,b);g&&(g.segmentIndex=f);return{Yb:function(){f&&0!=f.Jb()||f.Gd(h);return Promise.resolve(f)}}}function Mq(a){return a.Bb}function Nq(a){var b=Pq(a);a=nq(a,Mq);var c=a.ad;0==c&&(c=1);var d=0;a.ua?d=a.ua*(c-1):a.timeline&&0<a.timeline.length&&(d=a.timeline[0].start);return{ua:a.ua,startTime:d,ad:c,mb:a.mb,timeline:a.timeline,cc:b}}
763
+ Infinity,b);g&&(g.segmentIndex=f);return{Yb:function(){f&&0!=f.Ib()||f.Gd(h);return Promise.resolve(f)}}}function Mq(a){return a.Ab}function Nq(a){var b=Pq(a);a=nq(a,Mq);var c=a.ad;0==c&&(c=1);var d=0;a.ua?d=a.ua*(c-1):a.timeline&&0<a.timeline.length&&(d=a.timeline[0].start);return{ua:a.ua,startTime:d,ad:c,mb:a.mb,timeline:a.timeline,cc:b}}
762
764
  function Oq(a,b,c,d,e,f){var g=d.cc.length;d.timeline&&d.timeline.length!=d.cc.length&&(g=Math.min(d.timeline.length,d.cc.length));for(var h=a-d.mb,k=b?a+b:Infinity,l=[],m=d.startTime,n={},r=0;r<g;n={wc:n.wc,tc:n.tc},r++){n.tc=d.cc[r];var p=void 0;p=null!=d.ua?m+d.ua:d.timeline?d.timeline[r].end:m+b;n.wc=null;l.push(new S(a+m,a+p,function(u){return function(){null==u.wc&&(u.wc=wc(c(),[u.tc.nh]));return u.wc}}(n),n.tc.start,n.tc.end,e,h,a,k,[],"",null,null,wh,f));m=p}return l}
763
- function Pq(a){return[a.M.Bb,a.na.Bb,a.ra.Bb].filter(Wc).map(function(b){return dg(b,"SegmentURL")}).reduce(function(b,c){return 0<b.length?b:c}).map(function(b){b.getAttribute("indexRange")&&!a.If&&(a.If=!0);var c=b.getAttribute("media");b=lg(b,"mediaRange",og,{start:0,end:null});return{nh:c,start:b.start,end:b.end}})};function Qq(a,b,c,d,e,f,g){var h=Rq(a,g),k=Sq(a);Tq(k);var l=Xe(a);if(k.Pc)return Kq(a,h),{Yb:function(){var u=mq(k.Pc,l.M.id,null,null,l.bandwidth||null,null);u=wc(l.M.Ya(),[u]);return Jq(l,b,h,u,0,null,k.mb)}};if(k.ua)return d||"image"===a.na.contentType||(a.presentationTimeline.Pe(k.ua),a.presentationTimeline.Id(a.Z.start)),{Yb:function(){return Uq(l,k,e,h,f,g)}};var m=null;d=d=null;a.ra.id&&a.M.id&&(d=a.ra.id+","+a.M.id,d=c[d])&&(m=d.segmentIndex);var n=a.Z.start,r=a.Z.duration?n+a.Z.duration:
764
- Infinity,p=!(a.ub&&a.Z.Ce);m?(c=m,Vq(c,k,n,r,p,h),c.Xa(a.presentationTimeline.ib())):m=new Wq(k,a.M.id,a.bandwidth,a.M.Ya,n,r,h,p,g,a.M.$e);k.timeline&&"image"!==a.na.contentType&&a.presentationTimeline.Rf(k.timeline,n);d&&a.ub&&(d.segmentIndex=m);return{Yb:function(){m instanceof Wq&&0==m.Jb()&&Vq(m,k,n,r,p,h);return Promise.resolve(m)}}}function Xq(a){return a.$c}
765
+ function Pq(a){return[a.M.Ab,a.na.Ab,a.ra.Ab].filter(Wc).map(function(b){return dg(b,"SegmentURL")}).reduce(function(b,c){return 0<b.length?b:c}).map(function(b){b.getAttribute("indexRange")&&!a.If&&(a.If=!0);var c=b.getAttribute("media");b=lg(b,"mediaRange",og,{start:0,end:null});return{nh:c,start:b.start,end:b.end}})};function Qq(a,b,c,d,e,f,g){var h=Rq(a,g),k=Sq(a);Tq(k);var l=Xe(a);if(k.Pc)return Kq(a,h),{Yb:function(){var u=mq(k.Pc,l.M.id,null,null,l.bandwidth||null,null);u=wc(l.M.Ya(),[u]);return Jq(l,b,h,u,0,null,k.mb)}};if(k.ua)return d||"image"===a.na.contentType||(a.presentationTimeline.Pe(k.ua),a.presentationTimeline.Id(a.Z.start)),{Yb:function(){return Uq(l,k,e,h,f,g)}};var m=null;d=d=null;a.ra.id&&a.M.id&&(d=a.ra.id+","+a.M.id,d=c[d])&&(m=d.segmentIndex);var n=a.Z.start,r=a.Z.duration?n+a.Z.duration:
766
+ Infinity,p=!(a.ub&&a.Z.Ce);m?(c=m,Vq(c,k,n,r,p,h),c.Xa(a.presentationTimeline.ib())):m=new Wq(k,a.M.id,a.bandwidth,a.M.Ya,n,r,h,p,g,a.M.$e);k.timeline&&"image"!==a.na.contentType&&a.presentationTimeline.Rf(k.timeline,n);d&&a.ub&&(d.segmentIndex=m);return{Yb:function(){m instanceof Wq&&0==m.Ib()&&Vq(m,k,n,r,p,h);return Promise.resolve(m)}}}function Xq(a){return a.$c}
765
767
  function Sq(a){var b=nq(a,Xq),c=oq(a,Xq,"media");a=oq(a,Xq,"index");return{ua:b.ua,timescale:b.timescale,ad:b.ad,mb:b.mb,lf:b.lf,timeline:b.timeline,dc:c,Pc:a}}function Tq(a){var b=a.Pc?1:0;b+=a.timeline?1:0;b+=a.ua?1:0;if(0==b)throw new O(2,4,4002);1!=b&&(a.Pc&&(a.timeline=null),a.ua=null);if(!a.Pc&&!a.dc)throw new O(2,4,4002);}
766
- function Uq(a,b,c,d,e,f){function g(I){var L=(I-u)*p,M=L+b.mb,P=L+m;L=P+p;var R=Math.min(L,k());P=new S(P,R,function(){var V=M*v;"BigInt"in window&&V>Number.MAX_SAFE_INTEGER&&(V=BigInt(M)*BigInt(v));V=mq(x,y,I,null,z,V);return wc(B(),[V])},0,null,d,A,m,k(),[],"",null,null,wh,f);P.j=L;return P}function h(){var I=[Math.max(l.ib(),m),Math.min(l.vb(),k())].map(function(L){return L-m});return[Math.ceil(I[0]/p),Math.ceil(I[1]/p)-1].map(function(L){return L+u})}function k(){var I=null!=n&&e[n]||r;return I?
767
- m+I:Infinity}var l=a.presentationTimeline,m=a.Z.start,n=a.ra.id,r=a.Z.duration,p=b.ua,u=b.ad,v=b.timescale,x=b.dc,z=a.bandwidth||null,y=a.M.id,B=a.M.Ya,A=m-b.mb,D=h();a=a.ub?Math.max(D[0],D[1]-c+1):D[0];D=D[1];c=[];for(var F=a;F<=D;++F){var J=g(F);c.push(J)}var G=new uj(c);c=l.vb()<k();F=l.S();if(c||F){var H=Math.max(a,D+1);G.Od(p,function(){var I=l.ib();G.Xa(I);var L=t(h());L.next();L=L.next().value;for(var M=[];H<=L;){var P=g(H);M.push(P);H++}return I>k()&&!M.length?null:M})}return Promise.resolve(G)}
768
- function Rq(a,b){var c=oq(a,Xq,"initialization");if(!c)return null;var d=a.M.id,e=a.bandwidth||null,f=a.M.Ya;return new uh(function(){var g=mq(c,d,null,null,e,null);return wc(f(),[g])},0,null,Eq(a),null,null,b)}function Wq(a,b,c,d,e,f,g,h,k,l){uj.call(this,[]);this.h=a;this.F=b;this.A=c;this.C=d;this.i=e;this.m=f;this.s=g;this.u=k;this.G=l;h&&Yq(this)}oa(Wq,uj);q=Wq.prototype;q.Jb=function(){return this.h?this.h.timeline.length:0};q.release=function(){uj.prototype.release.call(this);this.h=null};
769
- q.Xa=function(a){if(this.h){for(var b=0,c=this.h.timeline,d=0;d<c.length;d+=1)if(c[d].end+this.i<=a)b+=1;else break;0<b&&(this.h.timeline=c.slice(b),this.g.length>=b&&(this.g=this.g.slice(b)),this.j+=b,0===this.Jb()&&this.release())}};function Vq(a,b,c,d,e,f){a.s=f;if(a.h){c=a.h.timeline;a.h.dc=b.dc;var g=c[c.length-1];b=b.timeline.filter(function(h){return h.start>=g.end});0<b.length&&a.h.timeline.push.apply(a.h.timeline,w(b));a.m!==d&&(a.m=d)}else a.h=b,a.i=c,a.m=d;e&&Yq(a)}
768
+ function Uq(a,b,c,d,e,f){function g(I){var L=(I-u)*p,M=L+b.mb,P=L+m;L=P+p;var R=Math.min(L,k());P=new S(P,R,function(){var W=M*v;"BigInt"in window&&W>Number.MAX_SAFE_INTEGER&&(W=BigInt(M)*BigInt(v));W=mq(x,y,I,null,z,W);return wc(A(),[W])},0,null,d,B,m,k(),[],"",null,null,wh,f);P.j=L;return P}function h(){var I=[Math.max(l.ib(),m),Math.min(l.vb(),k())].map(function(L){return L-m});return[Math.ceil(I[0]/p),Math.ceil(I[1]/p)-1].map(function(L){return L+u})}function k(){var I=null!=n&&e[n]||r;return I?
769
+ m+I:Infinity}var l=a.presentationTimeline,m=a.Z.start,n=a.ra.id,r=a.Z.duration,p=b.ua,u=b.ad,v=b.timescale,x=b.dc,z=a.bandwidth||null,y=a.M.id,A=a.M.Ya,B=m-b.mb,D=h();a=a.ub?Math.max(D[0],D[1]-c+1):D[0];D=D[1];c=[];for(var F=a;F<=D;++F){var J=g(F);c.push(J)}var G=new uj(c);c=l.vb()<k();F=l.S();if(c||F){var H=Math.max(a,D+1);G.Od(p,function(){var I=l.ib();G.Xa(I);var L=t(h());L.next();L=L.next().value;for(var M=[];H<=L;){var P=g(H);M.push(P);H++}return I>k()&&!M.length?null:M})}return Promise.resolve(G)}
770
+ function Rq(a,b){var c=oq(a,Xq,"initialization");if(!c)return null;var d=a.M.id,e=a.bandwidth||null,f=a.M.Ya;return new uh(function(){var g=mq(c,d,null,null,e,null);return wc(f(),[g])},0,null,Eq(a),null,null,b)}function Wq(a,b,c,d,e,f,g,h,k,l){uj.call(this,[]);this.h=a;this.F=b;this.A=c;this.C=d;this.i=e;this.m=f;this.s=g;this.u=k;this.G=l;h&&Yq(this)}oa(Wq,uj);q=Wq.prototype;q.Ib=function(){return this.h?this.h.timeline.length:0};q.release=function(){uj.prototype.release.call(this);this.h=null};
771
+ q.Xa=function(a){if(this.h){for(var b=0,c=this.h.timeline,d=0;d<c.length;d+=1)if(c[d].end+this.i<=a)b+=1;else break;0<b&&(this.h.timeline=c.slice(b),this.g.length>=b&&(this.g=this.g.slice(b)),this.j+=b,0===this.Ib()&&this.release())}};function Vq(a,b,c,d,e,f){a.s=f;if(a.h){c=a.h.timeline;a.h.dc=b.dc;var g=c[c.length-1];b=b.timeline.filter(function(h){return h.start>=g.end});0<b.length&&a.h.timeline.push.apply(a.h.timeline,w(b));a.m!==d&&(a.m=d)}else a.h=b,a.i=c,a.m=d;e&&Yq(a)}
770
772
  function Yq(a){if(!a.o){for(var b=a.h.timeline;b.length;)if(b[b.length-1].start>=a.m)b.pop();else break;a.Xa(a.i);0!==b.length&&Infinity!==a.m&&(b[b.length-1].end=a.m-a.i)}}
771
773
  q.find=function(a){if(this.h&&this.h.timeline&&this.h.timeline.length&&a<this.h.timeline[0].start+this.i)return this.j;if(!this.h)return null;var b=this.h.timeline;if(a<this.i||a>this.m)return null;for(var c=b.length-1,d=0;d<b.length;d++){var e=b[d],f=e.start+this.i;e=e.end+this.i;d<c&&(e=b[d+1].start+this.i);if(a>=f&&a<e)return d+this.j}return null};
772
- q.get=function(a){var b=this;a-=this.j;if(0>a||a>=this.Jb()||!this.h)return null;var c=this.g[a];if(!c){var d=this.h.dc,e=this.h.timeline[a],f=e.Dh,g=this.h.lf+e.mf;c=this.i-this.h.mb;for(var h=[],k=(e.end-e.start)/e.Za,l={},m=0;m<e.Za;l={xc:l.xc,Wd:l.Wd},m++){var n=e.start+k*m,r=n+k;l.Wd=m+1;l.xc=null;n=new S(this.i+n,this.i+r,function(p){return function(){if(!b.h)return[];null==p.xc&&(p.xc=Zq(b.h.dc,b.F,f,b.A,g,p.Wd,b.C));return p.xc}}(l),0,null,this.s,c,this.i,this.m,[],"",null,null,wh,this.u);
774
+ q.get=function(a){var b=this;a-=this.j;if(0>a||a>=this.Ib()||!this.h)return null;var c=this.g[a];if(!c){var d=this.h.dc,e=this.h.timeline[a],f=e.Dh,g=this.h.lf+e.mf;c=this.i-this.h.mb;for(var h=[],k=(e.end-e.start)/e.Za,l={},m=0;m<e.Za;l={xc:l.xc,Wd:l.Wd},m++){var n=e.start+k*m,r=n+k;l.Wd=m+1;l.xc=null;n=new S(this.i+n,this.i+r,function(p){return function(){if(!b.h)return[];null==p.xc&&(p.xc=Zq(b.h.dc,b.F,f,b.A,g,p.Wd,b.C));return p.xc}}(l),0,null,this.s,c,this.i,this.m,[],"",null,null,wh,this.u);
773
775
  0==this.G?0<m&&n.Ed():0!=m%this.G&&n.Ed();h.push(n)}c=new S(this.i+e.start,this.i+e.end,function(){return 0<e.Za?[]:Zq(d,b.F,f,b.A,g,null,b.C)},0,null,this.s,c,this.i,this.m,h,"",null,null,wh,this.u,0<e.Za);this.g[a]=c}return c};function Zq(a,b,c,d,e,f,g){a=mq(a,b,c,f,d||null,e);return wc(g(),[a]).map(function(h){return h.toString()})};function $q(a){this.o=null;this.u=a;this.G=new Ye;this.j=[];this.h=null;this.m=[];this.A=null;this.F=[];this.C=300;this.l=new Map;this.i=new Map;this.g=null;this.s="UNKNOWN"}$q.prototype.configure=function(a){this.o=a};$q.prototype.destroy=function(){this.u=this.o=null;this.j=[];this.h=null;this.m=[];this.F=[];this.l.clear();null!=this.g&&(this.g.stop(),this.g=null);return this.G.destroy()};$q.prototype.setManifestType=function(a){this.s=a};
774
776
  function ar(a,b){var c,d,e,f,g,h,k;return K(function(l){if(1==l.g)return c=wc(a.j,[br(a,b)]),d=df(c,a.o.retryParameters),e=a.u.networkingEngine.request(8,d),Ze(a.G,e),sa(l,2),C(l,e.promise,4);if(2!=l.g)return f=l.h,g=Af(f.data),h=JSON.parse(g),1==h.VERSION&&cr(a,h,f.uri),va(l,0);if((k=wa(l))&&7001==k.code)return l.return();null!=a.g&&(a.g.stop(),a.g=null);a.g=new id(function(){ar(a,b)});a.g.U(a.C);E(l)})}
775
777
  function br(a,b){if(!a.m.length)return b;b=new fc(b);var c=a.A||a.m[0],d=Math.round(a.u.getBandwidthEstimate()),e=b.g;"DASH"==a.s?(e.add("_DASH_pathway",c),e.add("_DASH_throughput",String(d))):"HLS"==a.s&&(e.add("_HLS_pathway",c),e.add("_HLS_throughput",String(d)));uc(e)&&jc(b,e);return b.toString()}function cr(a,b,c){null!=a.g&&(a.g.stop(),a.g=null);var d=b["RELOAD-URI"]||c;a.g=new id(function(){ar(a,d)});if(c=b.TTL)a.C=c;a.g.U(a.C);a.m=b["PATHWAY-PRIORITY"]||[];a.F=b["PATHWAY-CLONES"]||[]}
776
778
  function dr(a,b,c,d){var e=a.l.get(b);e||(e=new Map);e.set(c,d);a.l.set(b,e)}
777
- function er(a,b){b=a.l.get(b)||new Map;for(var c=[],d={},e=t(a.m),f=e.next();!f.done;d={Db:d.Db},f=e.next())if(d.Db=f.value,f=b.get(d.Db))c.push({Ve:d.Db,location:f});else if(f=a.F.find(function(h){return function(k){return k.di==h.Db}}(d))){var g=b.get(f["BASE-ID"]);g&&(f["URI-REPLACEMENT"].jg?(g=new fc(g),hc(g,f["URI-REPLACEMENT"].jg),c.push({Ve:d.Db,location:g.toString()})):c.push({Ve:d.Db,location:g}))}d=Date.now();e=t(a.i.keys());for(f=e.next();!f.done;f=e.next())f=f.value,g=a.i.get(f),d>g&&
779
+ function er(a,b){b=a.l.get(b)||new Map;for(var c=[],d={},e=t(a.m),f=e.next();!f.done;d={Cb:d.Cb},f=e.next())if(d.Cb=f.value,f=b.get(d.Cb))c.push({Ve:d.Cb,location:f});else if(f=a.F.find(function(h){return function(k){return k.di==h.Cb}}(d))){var g=b.get(f["BASE-ID"]);g&&(f["URI-REPLACEMENT"].jg?(g=new fc(g),hc(g,f["URI-REPLACEMENT"].jg),c.push({Ve:d.Cb,location:g.toString()})):c.push({Ve:d.Cb,location:g}))}d=Date.now();e=t(a.i.keys());for(f=e.next();!f.done;f=e.next())f=f.value,g=a.i.get(f),d>g&&
778
780
  a.i.delete(f);c=c.filter(function(h){for(var k=t(a.i.keys()),l=k.next();!l.done;l=k.next())if(l.value.includes((new fc(h.location)).fb))return!1;return!0});c.length&&(a.A=c[0].Ve);c=c.map(function(h){return h.location});if(!c.length&&a.h)for(d=t(a.h.split(",")),f=d.next();!f.done;f=d.next())if(e=b.get(f.value))a.A=a.h,c.push(e);if(!c.length)for(b=t(b.values()),d=b.next();!d.done;d=b.next())c.push(d.value);return wc(a.j,c)};function fr(){this.j=[];this.h=[];this.g=[];this.l=[];this.i=[];this.m=new Set}q=fr.prototype;q.release=function(){for(var a=t(this.h.concat(this.g,this.l,this.i)),b=a.next();!b.done;b=a.next())b=b.value,b.segmentIndex&&b.segmentIndex.release();this.h=[];this.g=[];this.l=[];this.i=[];this.j=[]};q.Xg=function(){return this.j};q.ye=function(){return this.l.slice()};q.Ig=function(){return this.i};
779
- q.vf=function(a,b){var c,d,e,f,g=this,h,k,l,m,n,r,p,u,v,x,z,y,B,A,D,F,J,G,H,I,L,M,P,R,V,X,fa,Ha,Sa,wb;return K(function(db){if(1==db.g){h=Cc;gr(a);if(!b&&1==a.length)return k=a[0],g.h=k.audioStreams,g.g=k.videoStreams,g.l=k.textStreams,g.i=k.imageStreams,db.B(2);l=-1;for(m=0;m<a.length;m++)n=a[m],g.m.has(n.id)||(g.m.add(n.id),-1==l&&(l=m));if(-1==l)return db.return();for(var Sb=[],ua=[],eb=[],$a=[],xb=t(a),ab=xb.next();!ab.done;ab=xb.next())ab=ab.value,Sb.push(ab.audioStreams),ua.push(ab.videoStreams),
780
- eb.push(ab.textStreams),$a.push(ab.imageStreams);c=Sb;d=ua;e=eb;f=$a;r=c;p=d;u=e;v=f;x=t(u);for(z=x.next();!z.done;z=x.next())y=z.value,y.push(hr(h.ja));B=t(v);for(A=B.next();!A.done;A=B.next())D=A.value,D.push(hr(h.zc));return C(db,Promise.all([ir(g.h,r,l,jr,kr),ir(g.g,p,l,jr,kr),ir(g.l,u,l,jr,kr),ir(g.i,v,l,jr,kr)]),2)}F=0;J=[];if(g.g.length&&g.h.length)for(P=t(g.h),R=P.next();!R.done;R=P.next())for(V=R.value,X=t(g.g),fa=X.next();!fa.done;fa=X.next())Ha=fa.value,Sa=lh(V.drmInfos,Ha.drmInfos),V.drmInfos.length&&
781
- Ha.drmInfos.length&&!Sa.length||(wb=F++,J.push({id:wb,language:V.language,disabledUntilTime:0,primary:V.primary,audio:V,video:Ha,bandwidth:(V.bandwidth||0)+(Ha.bandwidth||0),drmInfos:Sa,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]}));else for(G=g.g.length?g.g:g.h,H=t(G),I=H.next();!I.done;I=H.next())L=I.value,M=F++,J.push({id:M,language:L.language,disabledUntilTime:0,primary:L.primary,audio:L.type==h.P?L:null,video:L.type==h.ea?L:null,bandwidth:L.bandwidth||0,drmInfos:L.drmInfos,
781
+ q.vf=function(a,b){var c,d,e,f,g=this,h,k,l,m,n,r,p,u,v,x,z,y,A,B,D,F,J,G,H,I,L,M,P,R,W,X,ia,Ha,Sa,wb;return K(function(db){if(1==db.g){h=Cc;gr(a);if(!b&&1==a.length)return k=a[0],g.h=k.audioStreams,g.g=k.videoStreams,g.l=k.textStreams,g.i=k.imageStreams,db.B(2);l=-1;for(m=0;m<a.length;m++)n=a[m],g.m.has(n.id)||(g.m.add(n.id),-1==l&&(l=m));if(-1==l)return db.return();for(var Sb=[],ua=[],eb=[],$a=[],xb=t(a),ab=xb.next();!ab.done;ab=xb.next())ab=ab.value,Sb.push(ab.audioStreams),ua.push(ab.videoStreams),
782
+ eb.push(ab.textStreams),$a.push(ab.imageStreams);c=Sb;d=ua;e=eb;f=$a;r=c;p=d;u=e;v=f;x=t(u);for(z=x.next();!z.done;z=x.next())y=z.value,y.push(hr(h.ja));A=t(v);for(B=A.next();!B.done;B=A.next())D=B.value,D.push(hr(h.zc));return C(db,Promise.all([ir(g.h,r,l,jr,kr),ir(g.g,p,l,jr,kr),ir(g.l,u,l,jr,kr),ir(g.i,v,l,jr,kr)]),2)}F=0;J=[];if(g.g.length&&g.h.length)for(P=t(g.h),R=P.next();!R.done;R=P.next())for(W=R.value,X=t(g.g),ia=X.next();!ia.done;ia=X.next())Ha=ia.value,Sa=lh(W.drmInfos,Ha.drmInfos),W.drmInfos.length&&
783
+ Ha.drmInfos.length&&!Sa.length||(wb=F++,J.push({id:wb,language:W.language,disabledUntilTime:0,primary:W.primary,audio:W,video:Ha,bandwidth:(W.bandwidth||0)+(Ha.bandwidth||0),drmInfos:Sa,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]}));else for(G=g.g.length?g.g:g.h,H=t(G),I=H.next();!I.done;I=H.next())L=I.value,M=F++,J.push({id:M,language:L.language,disabledUntilTime:0,primary:L.primary,audio:L.type==h.P?L:null,video:L.type==h.ea?L:null,bandwidth:L.bandwidth||0,drmInfos:L.drmInfos,
782
784
  allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});g.j=J;E(db)})};
783
785
  function gr(a){a=t(a);for(var b=a.next();!b.done;b=a.next())b=b.value,b.videoStreams=lr(b.videoStreams,function(c,d){return c.id!==d.id&&c.fastSwitching==d.fastSwitching&&c.width===d.width&&c.frameRate===d.frameRate&&c.codecs===d.codecs&&c.mimeType===d.mimeType&&c.label===d.label&&zb(c.roles,d.roles)&&yf(c.closedCaptions,d.closedCaptions)&&c.bandwidth===d.bandwidth}),b.audioStreams=lr(b.audioStreams,function(c,d){return c.id!==d.id&&c.fastSwitching==d.fastSwitching&&c.channelsCount===d.channelsCount&&
784
786
  c.language===d.language&&c.bandwidth===d.bandwidth&&c.label===d.label&&c.codecs===d.codecs&&c.mimeType===d.mimeType&&zb(c.roles,d.roles)&&c.audioSamplingRate===d.audioSamplingRate&&c.primary===d.primary}),b.textStreams=lr(b.textStreams,function(c,d){return c.id!==d.id&&c.language===d.language&&c.label===d.label&&c.codecs===d.codecs&&c.mimeType===d.mimeType&&c.bandwidth===d.bandwidth&&zb(c.roles,d.roles)}),b.imageStreams=lr(b.imageStreams,function(c,d){return c.id!==d.id&&c.width===d.width&&c.codecs===
785
787
  d.codecs&&c.mimeType===d.mimeType})}function lr(a,b){var c=[],d={};a=t(a);for(var e=a.next();!e.done;d={hd:d.hd},e=a.next())d.hd=e.value,c.some(function(f){return function(g){return b(f.hd,g)}}(d))||c.push(d.hd);return c}
786
- function mr(a){var b,c,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,B,A,D,F,J,G,H,I,L;return K(function(M){switch(M.g){case 1:b=Cc;if(1==a.length)return M.return(a[0]);c=a.map(function(P){return P.filter(function(R){return R.type==b.P})});d=a.map(function(P){return P.filter(function(R){return R.type==b.ea})});e=a.map(function(P){return P.filter(function(R){return R.type==b.ja})});f=a.map(function(P){return P.filter(function(R){return R.type==b.zc})});g=t(e);for(h=g.next();!h.done;h=g.next())k=h.value,k.push(nr(b.ja));
787
- l=t(f);for(m=l.next();!m.done;m=l.next())n=m.value,n.push(nr(b.zc));return C(M,ir([],c,0,or,pr),2);case 2:return r=M.h,C(M,ir([],d,0,or,pr),3);case 3:return p=M.h,C(M,ir([],e,0,or,pr),4);case 4:return u=M.h,C(M,ir([],f,0,or,pr),5);case 5:v=M.h;x=0;if(p.length&&r.length)for(D=t(r),F=D.next();!F.done;F=D.next())for(J=F.value,G=t(p),H=G.next();!H.done;H=G.next())I=H.value,L=x++,I.variantIds.push(L),J.variantIds.push(L);else for(z=p.concat(r),y=t(z),B=y.next();!B.done;B=y.next())A=B.value,A.variantIds=
788
+ function mr(a){var b,c,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,A,B,D,F,J,G,H,I,L;return K(function(M){switch(M.g){case 1:b=Cc;if(1==a.length)return M.return(a[0]);c=a.map(function(P){return P.filter(function(R){return R.type==b.P})});d=a.map(function(P){return P.filter(function(R){return R.type==b.ea})});e=a.map(function(P){return P.filter(function(R){return R.type==b.ja})});f=a.map(function(P){return P.filter(function(R){return R.type==b.zc})});g=t(e);for(h=g.next();!h.done;h=g.next())k=h.value,k.push(nr(b.ja));
789
+ l=t(f);for(m=l.next();!m.done;m=l.next())n=m.value,n.push(nr(b.zc));return C(M,ir([],c,0,or,pr),2);case 2:return r=M.h,C(M,ir([],d,0,or,pr),3);case 3:return p=M.h,C(M,ir([],e,0,or,pr),4);case 4:return u=M.h,C(M,ir([],f,0,or,pr),5);case 5:v=M.h;x=0;if(p.length&&r.length)for(D=t(r),F=D.next();!F.done;F=D.next())for(J=F.value,G=t(p),H=G.next();!H.done;H=G.next())I=H.value,L=x++,I.variantIds.push(L),J.variantIds.push(L);else for(z=p.concat(r),y=t(z),A=y.next();!A.done;A=y.next())B=A.value,B.variantIds=
788
790
  [x++];return M.return(p.concat(r).concat(u).concat(v))}})}
789
- function ir(a,b,c,d,e){var f,g,h,k,l,m,n,r,p,u,v,x,z,y,B,A,D,F,J,G,H;return K(function(I){switch(I.g){case 1:f=Cc;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){I.B(4);break}m=l.value;return C(I,qr(m,b,c,e,g),5);case 5:n=I.h;if(!n)throw new O(2,4,4037);l=k.next();I.B(2);break;case 4:r=t(g);for(p=r.next();!p.done;p=r.next())for(u=p.value,v=t(u),x=v.next();!x.done;x=v.next())z=x.value,(y=rr(z,b,d,e,g))&&a.push(y);B=t(g);for(p=B.next();!p.done;p=
790
- B.next())for(A=p.value,D={},F=t(A),x=F.next();!x.done;D={qb:D.qb},x=F.next())if(D.qb=x.value,J=D.qb.type==f.ja&&!D.qb.language,G=D.qb.type==f.zc&&!D.qb.tilesLayout,!J&&!G&&(H=a.some(function(L){return function(M){return M.mimeType==L.qb.mimeType&&Ic(M.codecs)==Ic(L.qb.codecs)}}(D))))throw new O(2,4,4037);return I.return(a)}})}function qr(a,b,c,d,e){return K(function(f){if(1==f.g)return sr(b,a),a.matchedStreams?a.segmentIndex?C(f,tr(a,c),2):f.B(2):f.return(!1);ur(a,c,d,e);return f.return(!0)})}
791
+ function ir(a,b,c,d,e){var f,g,h,k,l,m,n,r,p,u,v,x,z,y,A,B,D,F,J,G,H;return K(function(I){switch(I.g){case 1:f=Cc;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){I.B(4);break}m=l.value;return C(I,qr(m,b,c,e,g),5);case 5:n=I.h;if(!n)throw new O(2,4,4037);l=k.next();I.B(2);break;case 4:r=t(g);for(p=r.next();!p.done;p=r.next())for(u=p.value,v=t(u),x=v.next();!x.done;x=v.next())z=x.value,(y=rr(z,b,d,e,g))&&a.push(y);A=t(g);for(p=A.next();!p.done;p=
792
+ A.next())for(B=p.value,D={},F=t(B),x=F.next();!x.done;D={qb:D.qb},x=F.next())if(D.qb=x.value,J=D.qb.type==f.ja&&!D.qb.language,G=D.qb.type==f.zc&&!D.qb.tilesLayout,!J&&!G&&(H=a.some(function(L){return function(M){return M.mimeType==L.qb.mimeType&&Ic(M.codecs)==Ic(L.qb.codecs)}}(D))))throw new O(2,4,4037);return I.return(a)}})}function qr(a,b,c,d,e){return K(function(f){if(1==f.g)return sr(b,a),a.matchedStreams?a.segmentIndex?C(f,tr(a,c),2):f.B(2):f.return(!1);ur(a,c,d,e);return f.return(!0)})}
791
793
  function tr(a,b){var c,d,e,f,g,h,k;return K(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 C(l,Promise.all(c),2)}if(a.segmentIndex instanceof yj)for(h=b;h<d.length;h++)k=d[h],k.segmentIndex&&a.segmentIndex.h.push(k.segmentIndex);E(l)})}
792
794
  function rr(a,b,c,d,e){var f=c(a);sr(b,f);f.createSegmentIndex&&(f.createSegmentIndex=function(){return K(function(g){if(f.segmentIndex)return g.B(0);f.segmentIndex=new yj;return C(g,tr(f,0),0)})});if(!f.matchedStreams||!f.matchedStreams.length)return null;ur(f,0,d,e);return f}function ur(a,b,c,d){for(var e=a.matchedStreams;b<e.length;b++){var f=e[b];c(a,f);var g=!0;"audio"==a.type&&0==cd(a.language,f.language)&&(g=!1);g&&d[b].delete(f)}}
793
795
  function jr(a){var b=Object.assign({},a);b.originalId=null;b.createSegmentIndex=function(){return Promise.resolve()};b.closeSegmentIndex=function(){b.segmentIndex&&(b.segmentIndex.release(),b.segmentIndex=null);if(b.matchedStreams)for(var c=t(b.matchedStreams),d=c.next();!d.done;d=c.next())d=d.value,d.segmentIndex&&(d.segmentIndex.release(),d.segmentIndex=null)};b.segmentIndex=null;b.emsgSchemeIdUris=[];b.keyIds=new Set;b.closedCaptions=null;b.trickModeVideo=null;return b}
@@ -810,10 +812,10 @@ q.stop=function(){for(var a=t(Object.values(this.m)),b=a.next();!b.done;b=a.next
810
812
  q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(a){if(this.j&&this.j.presentationTimeline.S()){var b=a.video||a.audio;if(b&&b.segmentIndex){a=this.j.presentationTimeline.vb();var c=b.segmentIndex.find(a);null!=c&&(b=b.segmentIndex.get(c))&&(this.F=b.endTime-a,Lr(this,0))}}};q.banLocation=function(a){this.h&&this.h.i.set(a,Date.now()+6E4)};
811
813
  function Kr(a){var b,c,d,e,f;return K(function(g){if(1==g.g)return b=df(a.o,a.g.retryParameters),c=Date.now(),C(g,Mr(a,b,0,{type:4}),2);if(3!=g.g){d=g.h;if(!a.i)return g.return(0);d.uri&&d.uri!=d.originalUri&&!a.o.includes(d.uri)&&a.o.unshift(d.uri);return C(g,Nr(a,d.data,d.uri),3)}e=Date.now();f=(e-c)/1E3;a.H.sample(1,f);return g.return(f)})}
812
814
  function Nr(a,b,c){var d,e,f,g,h;return K(function(k){if(1==k.g){d=xg(b,"MPD");if(!d)throw new O(2,4,4001,c);if(e=a.g.dash.disableXlinkProcessing)return k.return(Or(a,d,c));f=a.g.dash.xlinkFailGracefully;g=sq(d,a.g.retryParameters,f,c,a.i.networkingEngine);Ze(a.C,g);return C(k,g.promise,2)}h=k.h;return k.return(Or(a,h,c))})}
813
- function Or(a,b,c){var d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,B,A,D,F,J,G,H,I,L,M,P,R,V,X,fa,Ha,Sa,wb,db,Sb,ua,eb,$a,xb,ab,kh,xd,te,ue;return K(function(ib){switch(ib.g){case 1:(d=a.g.dash.manifestPreprocessor)&&d(b);e=[c];f=dg(b,"Location").map(jg).filter(Wc);0<f.length&&(g=wc(e,f),e=a.o=g);h=Promise.resolve();if((k=cg(b,"ContentSteering"))&&a.i)if(l=k.getAttribute("defaultServiceLocation"),a.h)a.h.j=e,a.h.h=l;else if(a.h=new $q(a.i),a.h.configure(a.g),a.h.setManifestType("DASH"),a.h.j=e,a.h.h=l,m=jg(k))(n=
814
- lg(k,"queryBeforeStart",tg,!1))?h=ar(a.h,m):ar(a.h,m);r=dg(b,"BaseURL");u=!1;if(a.h)for(a.h.l.clear(),v=t(r),x=v.next();!x.done;x=v.next())z=x.value,y=z.getAttribute("serviceLocation"),B=jg(z),y&&B&&(dr(a.h,"BaseURL",y,B),u=!0);u&&a.h||(A=r.map(jg),p=wc(e,A));D=function(){return a.h&&u?er(a.h,"BaseURL"):p?p:[]};F=0;r&&r.length&&(F=lg(r[0],"availabilityTimeOffset",sg)||0);J=a.g.dash.ignoreMinBufferTime;G=0;J||(G=lg(b,"minBufferTime",ng)||0);a.F=lg(b,"minimumUpdatePeriod",ng,-1);H=lg(b,"availabilityStartTime",
815
- mg);I=lg(b,"timeShiftBufferDepth",ng);L=a.g.dash.ignoreSuggestedPresentationDelay;M=null;L||(M=lg(b,"suggestedPresentationDelay",ng));P=a.g.dash.ignoreMaxSegmentDuration;R=null;P||(R=lg(b,"maxSegmentDuration",ng));V=b.getAttribute("type")||"static";if(a.j)for(X=a.j.presentationTimeline,fa=t(Object.values(a.m)),Ha=fa.next();!Ha.done;Ha=fa.next())Sa=Ha.value,Sa.segmentIndex&&Sa.segmentIndex.Xa(X.ib());else wb=a.g.defaultPresentationDelay||1.5*G,db=null!=M?M:wb,X=new Zi(H,db,a.g.dash.autoCorrectDrift);
816
- X.hc("static"==V);(Sb=X.S())&&!isNaN(a.g.availabilityWindowOverride)&&(I=a.g.availabilityWindowOverride);null==I&&(I=Infinity);X.Nd(I);ua=b.getAttribute("profiles")||"";eb={ub:"static"!=V,presentationTimeline:X,ra:null,Z:null,na:null,M:null,bandwidth:0,If:!1,Vb:F,profiles:ua.split(",")};$a=Pr(a,eb,D,b);xb=$a.duration;ab=$a.periods;"static"!=V&&$a.Af||X.Ka(xb||Infinity);a.A&&!a.s&&(kh=a.i.isAutoLowLatencyMode())&&(a.i.enableLowLatencyMode(),a.s=a.i.isLowLatencyMode());a.s?X.$f(a.A):a.A&&Ta("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.");
815
+ function Or(a,b,c){var d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,A,B,D,F,J,G,H,I,L,M,P,R,W,X,ia,Ha,Sa,wb,db,Sb,ua,eb,$a,xb,ab,kh,xd,te,ue;return K(function(ib){switch(ib.g){case 1:(d=a.g.dash.manifestPreprocessor)&&d(b);e=[c];f=dg(b,"Location").map(jg).filter(Wc);0<f.length&&(g=wc(e,f),e=a.o=g);h=Promise.resolve();if((k=cg(b,"ContentSteering"))&&a.i)if(l=k.getAttribute("defaultServiceLocation"),a.h)a.h.j=e,a.h.h=l;else if(a.h=new $q(a.i),a.h.configure(a.g),a.h.setManifestType("DASH"),a.h.j=e,a.h.h=l,m=jg(k))(n=
816
+ lg(k,"queryBeforeStart",tg,!1))?h=ar(a.h,m):ar(a.h,m);r=dg(b,"BaseURL");u=!1;if(a.h)for(a.h.l.clear(),v=t(r),x=v.next();!x.done;x=v.next())z=x.value,y=z.getAttribute("serviceLocation"),A=jg(z),y&&A&&(dr(a.h,"BaseURL",y,A),u=!0);u&&a.h||(B=r.map(jg),p=wc(e,B));D=function(){return a.h&&u?er(a.h,"BaseURL"):p?p:[]};F=0;r&&r.length&&(F=lg(r[0],"availabilityTimeOffset",sg)||0);J=a.g.dash.ignoreMinBufferTime;G=0;J||(G=lg(b,"minBufferTime",ng)||0);a.F=lg(b,"minimumUpdatePeriod",ng,-1);H=lg(b,"availabilityStartTime",
817
+ mg);I=lg(b,"timeShiftBufferDepth",ng);L=a.g.dash.ignoreSuggestedPresentationDelay;M=null;L||(M=lg(b,"suggestedPresentationDelay",ng));P=a.g.dash.ignoreMaxSegmentDuration;R=null;P||(R=lg(b,"maxSegmentDuration",ng));W=b.getAttribute("type")||"static";if(a.j)for(X=a.j.presentationTimeline,ia=t(Object.values(a.m)),Ha=ia.next();!Ha.done;Ha=ia.next())Sa=Ha.value,Sa.segmentIndex&&Sa.segmentIndex.Xa(X.ib());else wb=a.g.defaultPresentationDelay||1.5*G,db=null!=M?M:wb,X=new Zi(H,db,a.g.dash.autoCorrectDrift);
818
+ X.hc("static"==W);(Sb=X.S())&&!isNaN(a.g.availabilityWindowOverride)&&(I=a.g.availabilityWindowOverride);null==I&&(I=Infinity);X.Nd(I);ua=b.getAttribute("profiles")||"";eb={ub:"static"!=W,presentationTimeline:X,ra:null,Z:null,na:null,M:null,bandwidth:0,If:!1,Vb:F,profiles:ua.split(",")};$a=Pr(a,eb,D,b);xb=$a.duration;ab=$a.periods;"static"!=W&&$a.Af||X.Ka(xb||Infinity);a.A&&!a.s&&(kh=a.i.isAutoLowLatencyMode())&&(a.i.enableLowLatencyMode(),a.s=a.i.isLowLatencyMode());a.s?X.$f(a.A):a.A&&Ta("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.");
817
819
  X.Pe(R||1);return C(ib,a.l.vf(ab,eb.ub),2);case 2:return C(ib,h,3);case 3:a.s&&(G=0);if(a.j){a.j.variants=a.l.j;xd=a.l.ye();0<xd.length&&(a.j.textStreams=xd);a.j.imageStreams=a.l.i;a.i.filter(a.j);ib.B(4);break}a.j={presentationTimeline:X,variants:a.l.j,textStreams:a.l.ye(),imageStreams:a.l.i,offlineSessionIds:[],minBufferTime:G||0,sequenceMode:a.g.dash.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,type:"DASH",serviceDescription:Qr(b)};if(!X.hg()){ib.B(5);break}te=dg(b,"UTCTiming");return C(ib,
818
820
  Rr(a,D,te),6);case 6:ue=ib.h;if(!a.i)return ib.return();X.ag(ue);case 5:X.Dd();case 4:a.i.makeTextStreamsForClosedCaptions(a.j),E(ib)}})}
819
821
  function Qr(a){a=cg(a,"ServiceDescription");if(!a)return null;var b=cg(a,"Latency"),c=cg(a,"PlaybackRate");if(b&&b.getAttribute("max")||c){a=b&&b.getAttribute("max")?parseInt(b.getAttribute("max"),10)/1E3:null;var d=c?parseFloat(c.getAttribute("max")):null;b=b&&b.getAttribute("min")?parseInt(b.getAttribute("min"),10)/1E3:null;c=c?parseFloat(c.getAttribute("min")):null;return{maxLatency:a,maxPlaybackRate:d,minLatency:b,minPlaybackRate:c}}return null}
@@ -824,24 +826,24 @@ function Sr(a,b,c,d){b.ra=Tr(a,d.node,null,c);b.Z=d;b.ra.Vb=b.Vb;b.ra.id||(b.ra.
824
826
  d,Bc);d=Wr(a.g.disableThumbnails,d,"image");if(0===e.length&&0===c.length)throw new O(2,4,4004);return{id:b.ra.id,audioStreams:c,videoStreams:e,textStreams:f,imageStreams:d}}function Wr(a,b,c){return a||!b.length?[]:b.reduce(function(d,e){if(e.contentType!=c)return d;d.push.apply(d,w(e.streams));return d},[])}
825
827
  function Vr(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.na=Tr(a,c,b.ra,null);var e=!1,f=dg(c,"Role"),g=f.map(function(G){return G.getAttribute("value")}).filter(Wc),h=void 0,k=b.na.contentType==Bc;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=
826
828
  l}}var n;m=dg(c,"EssentialProperty");f=null;var r=!1;l=!1;m=t(m);for(var p=m.next();!p.done;p=m.next()){p=p.value;var u=p.getAttribute("schemeIdUri");"http://dashif.org/guidelines/trickmode"==u?f=p.getAttribute("value"):"urn:mpeg:mpegB:cicp:TransferCharacteristics"==u?n=d(parseInt(p.getAttribute("value"),10)):"urn:mpeg:mpegB:cicp:ColourPrimaries"!=u&&"urn:mpeg:mpegB:cicp:MatrixCoefficients"!=u&&("urn:mpeg:dash:ssr:2023"==u?r=!0:l=!0)}m=dg(c,"SupplementalProperty");m=t(m);for(p=m.next();!p.done;p=
827
- m.next())p=p.value,"urn:mpeg:mpegB:cicp:TransferCharacteristics"==p.getAttribute("schemeIdUri")&&(n=d(parseInt(p.getAttribute("value"),10)));m=dg(c,"Accessibility");var v=new Map,x;m=t(m);for(p=m.next();!p.done;p=m.next())if(u=p.value,p=u.getAttribute("schemeIdUri"),u=u.getAttribute("value"),"urn:scte:dash:cc:cea-608:2015"==p)if(p=1,null!=u){u=u.split(";");for(var z=t(u),y=z.next();!y.done;y=z.next()){var B=y.value,A=y=void 0;B.includes("=")?(B=B.split("="),y=B[0].startsWith("CC")?B[0]:"CC"+B[0],
828
- A=B[1]||"und"):(y="CC"+p,2==u.length?p+=2:p++,A=B);v.set(y,Zc(A))}}else v.set("CC1","und");else if("urn:scte:dash:cc:cea-708:2015"==p)if(p=1,null!=u)for(u=t(u.split(";")),y=u.next();!y.done;y=u.next())y=y.value,B=z=void 0,y.includes("=")?(y=y.split("="),z="svc"+y[0],B=y[1].split(",")[0].split(":").pop()):(z="svc"+p,p++,B=y),v.set(z,Zc(B));else v.set("svc1","und");else"urn:mpeg:dash:role:2011"==p?null!=u&&(g.push(u),"captions"==u&&(h="caption")):"urn:tva:metadata:cs:AudioPurposeCS:2007"==p&&("1"==
829
+ m.next())p=p.value,"urn:mpeg:mpegB:cicp:TransferCharacteristics"==p.getAttribute("schemeIdUri")&&(n=d(parseInt(p.getAttribute("value"),10)));m=dg(c,"Accessibility");var v=new Map,x;m=t(m);for(p=m.next();!p.done;p=m.next())if(u=p.value,p=u.getAttribute("schemeIdUri"),u=u.getAttribute("value"),"urn:scte:dash:cc:cea-608:2015"==p)if(p=1,null!=u){u=u.split(";");for(var z=t(u),y=z.next();!y.done;y=z.next()){var A=y.value,B=y=void 0;A.includes("=")?(A=A.split("="),y=A[0].startsWith("CC")?A[0]:"CC"+A[0],
830
+ B=A[1]||"und"):(y="CC"+p,2==u.length?p+=2:p++,B=A);v.set(y,Zc(B))}}else v.set("CC1","und");else if("urn:scte:dash:cc:cea-708:2015"==p)if(p=1,null!=u)for(u=t(u.split(";")),y=u.next();!y.done;y=u.next())y=y.value,A=z=void 0,y.includes("=")?(y=y.split("="),z="svc"+y[0],A=y[1].split(",")[0].split(":").pop()):(z="svc"+p,p++,A=y),v.set(z,Zc(A));else v.set("svc1","und");else"urn:mpeg:dash:role:2011"==p?null!=u&&(g.push(u),"captions"==u&&(h="caption")):"urn:tva:metadata:cs:AudioPurposeCS:2007"==p&&("1"==
829
831
  u?x="visually impaired":"2"==u&&(x="hard of hearing"));if(l)return null;l=dg(c,"ContentProtection");var D=bq(l,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI),F=Zc(b.na.language||"und"),J=c.getAttribute("label");(l=dg(c,"Label"))&&l.length&&(l=l[0],l.textContent&&(J=l.textContent));l=dg(c,"Representation");c=l.map(function(G){if(G=Xr(a,b,D,h,F,J,e,g,v,G,x))G.hdr=G.hdr||n,G.fastSwitching=r;return G}).filter(function(G){return!!G});if(0==c.length){f="image"==b.na.contentType;if(a.g.dash.ignoreEmptyAdaptationSet||
830
832
  k||f)return null;throw new O(2,4,4003);}if(!b.na.contentType||"application"==b.na.contentType)for(b.na.contentType=Yr(c[0].mimeType,c[0].codecs),k=t(c),p=k.next();!p.done;p=k.next())p.value.type=b.na.contentType;k=b.na.id||"__fake__"+a.I++;m=t(c);for(p=m.next();!p.done;p=m.next()){p=p.value;u=t(D.drmInfos);for(z=u.next();!z.done;z=u.next())z=z.value,z.keyIds=z.keyIds&&p.keyIds?new Set([].concat(w(z.keyIds),w(p.keyIds))):z.keyIds||p.keyIds;a.g.dash.enableAudioGroups&&(p.groupId=k)}l=l.map(function(G){return G.getAttribute("id")}).filter(Wc);
831
833
  return{id:k,contentType:b.na.contentType,language:F,Li:e,streams:c,drmInfos:D.drmInfos,jf:f,zh:l}}
832
834
  function Xr(a,b,c,d,e,f,g,h,k,l,m){b.M=Tr(a,l,b.na,null);a.A=Math.min(a.A,b.M.Vb);if(!Zr(b.M))return null;var n=b.Z.start;b.bandwidth=lg(l,"bandwidth",qg)||0;var r=b.M.contentType,p=r==Bc||"application"==r;r="image"==r;try{var u=void 0;if(c.$d){var v=b.M.Ya,x=wc(v(),[c.$d.jh]),z=df(x,a.g.retryParameters);u={method:"AES-128",iv:c.$d.iv,firstMediaSequenceNumber:0,fetchKey:function(){var H,I,L;return K(function(M){if(1==M.g)return C(M,Mr(a,z,6),2);if(3!=M.g){H=M.h;if(!H.data||16!=H.data.byteLength)throw new O(2,
833
- 4,4049);I={name:"AES-CBC"};L=u;return C(M,window.crypto.subtle.importKey("raw",H.data,I,!0,["decrypt"]),3)}L.cryptoKey=M.h;u.fetchKey=void 0;E(M)})}}}v=function(H,I,L,M){return $r(a,H,I,L,M)};if(b.M.Zc)var y=Fq(b,v,u);else if(b.M.Bb)y=Lq(b,a.m,u);else if(b.M.$c)y=Qq(b,v,a.m,!!a.j,a.g.dash.initialSegmentLimit,a.K,u);else{var B=b.Z.duration||0,A=b.M.Ya;y={Yb:function(){return Promise.resolve(xj(n,B,A()))}}}}catch(H){if((p||r)&&4002==H.code)return null;throw H;}v=dg(l,"ContentProtection");v=fq(v,c,a.g.dash.ignoreDrmInfo,
835
+ 4,4049);I={name:"AES-CBC"};L=u;return C(M,window.crypto.subtle.importKey("raw",H.data,I,!0,["decrypt"]),3)}L.cryptoKey=M.h;u.fetchKey=void 0;E(M)})}}}v=function(H,I,L,M){return $r(a,H,I,L,M)};if(b.M.Zc)var y=Fq(b,v,u);else if(b.M.Ab)y=Lq(b,a.m,u);else if(b.M.$c)y=Qq(b,v,a.m,!!a.j,a.g.dash.initialSegmentLimit,a.K,u);else{var A=b.Z.duration||0,B=b.M.Ya;y={Yb:function(){return Promise.resolve(xj(n,A,B()))}}}}catch(H){if((p||r)&&4002==H.code)return null;throw H;}v=dg(l,"ContentProtection");v=fq(v,c,a.g.dash.ignoreDrmInfo,
834
836
  a.g.dash.keySystemsByURI);v=new Set(v?[v]:[]);x=!1;dg(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 F;if(r&&((l=dg(l,"EssentialProperty").find(function(H){return["http://dashif.org/thumbnail_tile","http://dashif.org/guidelines/thumbnail_tile"].includes(H.getAttribute("schemeIdUri"))}))&&(F=l.getAttribute("value")),
835
837
  !F))return null;var J;l=b.M.codecs;b.profiles.includes("http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10")&&(l.includes("hvc1.2.4.L153.B0")||l.includes("hev1.2.4.L153.B0"))&&(J="PQ");l=b.M.id?b.ra.id+","+b.M.id:"";var G=l&&a.m[l]?a.m[l]:{id:a.I++,originalId:b.M.id,groupId:null,createSegmentIndex:function(){return Promise.resolve()},closeSegmentIndex:function(){G.segmentIndex&&(G.segmentIndex.release(),G.segmentIndex=null)},segmentIndex:null,mimeType:b.M.mimeType,codecs:b.M.codecs,frameRate:b.M.frameRate,
836
838
  pixelAspectRatio:b.M.pixelAspectRatio,bandwidth:b.bandwidth,width:b.M.width,height:b.M.height,kind:d,encrypted:0<c.drmInfos.length,drmInfos:c.drmInfos,keyIds:v,language:e,originalLanguage:b.na.language,label:f,type:b.na.contentType,primary:g,trickModeVideo:null,emsgSchemeIdUris:b.M.emsgSchemeIdUris,roles:h,forced:D,channelsCount:b.M.Jd,audioSamplingRate:b.M.audioSamplingRate,spatialAudio:x,closedCaptions:k,hdr:J,videoLayout:void 0,tilesLayout:F,matchedStreams:[],accessibilityPurpose:m,external:!1,
837
839
  fastSwitching:!1};G.createSegmentIndex=function(){var H;return K(function(I){if(1==I.g){if(G.segmentIndex)return I.B(0);H=G;return C(I,y.Yb(),3)}H.segmentIndex=I.h;E(I)})};l&&b.ub&&!a.m[l]&&(a.m[l]=G);return G}
838
840
  function Jr(a){var b,c;K(function(d){switch(d.g){case 1:return b=0,sa(d,2),C(d,Kr(a),4);case 4:b=d.h;va(d,3);break;case 2:if(c=wa(d),a.i){if(a.g.raiseFatalErrorOnManifestUpdateRequestFailure)return a.i.onError(c),d.return();c.severity=1;a.i.onError(c)}case 3:if(!a.i)return d.return();a.i.onManifestUpdated();Lr(a,b);E(d)}})}function Lr(a,b){0>=a.F||a.G.U(Math.max(a.F-b,Oa(a.H)))}
839
841
  function Tr(a,b,c,d){c=c||{contentType:"",mimeType:"",codecs:"",emsgSchemeIdUris:[],frameRate:void 0,pixelAspectRatio:void 0,Jd:null,audioSamplingRate:null,Vb:0,$e:0};d=d||c.Ya;var e=b.getAttribute("id"),f=dg(b,"BaseURL"),g,h=!1;if(a.h)for(var k=t(f),l=k.next();!l.done;l=k.next()){var m=l.value;l=m.getAttribute("serviceLocation");m=jg(m);l&&m&&(dr(a.h,e,l,m),h=!0)}h&&a.h||(g=f.map(jg));k=b.getAttribute("contentType")||c.contentType;l=b.getAttribute("mimeType")||c.mimeType;m=b.getAttribute("codecs")||
840
- c.codecs;var n=lg(b,"frameRate",ug)||c.frameRate,r=b.getAttribute("sar")||c.pixelAspectRatio,p=as(dg(b,"InbandEventStream"),c.emsgSchemeIdUris),u=dg(b,"AudioChannelConfiguration");u=bs(u)||c.Jd;var v=lg(b,"audioSamplingRate",rg)||c.audioSamplingRate;k||(k=Yr(l,m));var x=cg(b,"SegmentBase"),z=cg(b,"SegmentTemplate"),y=x?lg(x,"availabilityTimeOffset",sg)||0:0,B=z?lg(z,"availabilityTimeOffset",sg)||0:0,A=f&&f.length?lg(f[0],"availabilityTimeOffset",sg)||0:0;y=c.Vb+A+y+B;B=null;(A=cg(b,"SegmentSequenceProperties"))&&
841
- (A=cg(A,"SAP"))&&(B=lg(A,"cadence",pg));return{Ya:function(){return wc(d(),f.length?a.h&&h?er(a.h,e):g?g:[]:[])},Zc:x||c.Zc,Bb:cg(b,"SegmentList")||c.Bb,$c:z||c.$c,width:lg(b,"width",rg)||c.width,height:lg(b,"height",rg)||c.height,contentType:k,mimeType:l,codecs:m,frameRate:n,pixelAspectRatio:r,emsgSchemeIdUris:p,id:e,language:b.getAttribute("lang"),Jd:u,audioSamplingRate:v,Vb:y,$e:B||c.$e}}
842
+ c.codecs;var n=lg(b,"frameRate",ug)||c.frameRate,r=b.getAttribute("sar")||c.pixelAspectRatio,p=as(dg(b,"InbandEventStream"),c.emsgSchemeIdUris),u=dg(b,"AudioChannelConfiguration");u=bs(u)||c.Jd;var v=lg(b,"audioSamplingRate",rg)||c.audioSamplingRate;k||(k=Yr(l,m));var x=cg(b,"SegmentBase"),z=cg(b,"SegmentTemplate"),y=x?lg(x,"availabilityTimeOffset",sg)||0:0,A=z?lg(z,"availabilityTimeOffset",sg)||0:0,B=f&&f.length?lg(f[0],"availabilityTimeOffset",sg)||0:0;y=c.Vb+B+y+A;A=null;(B=cg(b,"SegmentSequenceProperties"))&&
843
+ (B=cg(B,"SAP"))&&(A=lg(B,"cadence",pg));return{Ya:function(){return wc(d(),f.length?a.h&&h?er(a.h,e):g?g:[]:[])},Zc:x||c.Zc,Ab:cg(b,"SegmentList")||c.Ab,$c:z||c.$c,width:lg(b,"width",rg)||c.width,height:lg(b,"height",rg)||c.height,contentType:k,mimeType:l,codecs:m,frameRate:n,pixelAspectRatio:r,emsgSchemeIdUris:p,id:e,language:b.getAttribute("lang"),Jd:u,audioSamplingRate:v,Vb:y,$e:A||c.$e}}
842
844
  function as(a,b){b=b.slice();a=t(a);for(var c=a.next();!c.done;c=a.next())c=c.value.getAttribute("schemeIdUri"),b.includes(c)||b.push(c);return b}
843
845
  function bs(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=
844
- 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 Zr(a){var b=a.Zc?1:0;b+=a.Bb?1:0;b+=a.$c?1:0;if(0==b)return a.contentType==Bc||"application"==a.contentType?!0:!1;1!=b&&(a.Zc&&(a.Bb=null),a.$c=null);return!0}
846
+ 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 Zr(a){var b=a.Zc?1:0;b+=a.Ab?1:0;b+=a.$c?1:0;if(0==b)return a.contentType==Bc||"application"==a.contentType?!0:!1;1!=b&&(a.Zc&&(a.Ab=null),a.$c=null);return!0}
845
847
  function cs(a,b,c,d){var e,f,g,h,k,l;return K(function(m){if(1==m.g)return e=wc(b(),[c]),f=df(e,a.g.retryParameters),f.method=d,g=a.i.networkingEngine.request(4,f),Ze(a.C,g),C(m,g.promise,2);h=m.h;if("HEAD"==d){if(!h.headers||!h.headers.date)return m.return(0);k=h.headers.date}else k=Af(h.data);l=Date.parse(k);return isNaN(l)?m.return(0):m.return(l-Date.now())})}
846
848
  function Rr(a,b,c){var d,e,f,g,h,k,l,m;return K(function(n){switch(n.g){case 1:d=c.map(function(r){return{scheme:r.getAttribute("schemeIdUri"),value:r.getAttribute("value")}}),e=a.g.dash.clockSyncUri,!d.length&&e&&d.push({scheme:"urn:mpeg:dash:utc:http-head:2014",value:e}),f=t(d),g=f.next();case 2:if(g.done){n.B(4);break}h=g.value;sa(n,5);k=h.scheme;l=h.value;switch(k){case "urn:mpeg:dash:utc:http-head:2014":case "urn:mpeg:dash:utc:http-head:2012":return n.B(7);case "urn:mpeg:dash:utc:http-xsdate:2014":case "urn:mpeg:dash:utc:http-iso:2014":case "urn:mpeg:dash:utc:http-xsdate:2012":case "urn:mpeg:dash:utc:http-iso:2012":return n.B(8);
847
849
  case "urn:mpeg:dash:utc:direct:2014":case "urn:mpeg:dash:utc:direct:2012":return m=Date.parse(l),n.return(isNaN(m)?0:m-Date.now());case "urn:mpeg:dash:utc:http-ntp:2014":case "urn:mpeg:dash:utc:ntp:2014":case "urn:mpeg:dash:utc:sntp:2014":Ta("NTP UTCTiming scheme is not supported");break;default:Ta("Unrecognized scheme in UTCTiming element",k)}n.B(9);break;case 7:return C(n,cs(a,b,l,"HEAD"),10);case 10:return n.return(n.h);case 8:return C(n,cs(a,b,l,"GET"),11);case 11:return n.return(n.h);case 9:va(n,
@@ -864,20 +866,20 @@ this.cb=new Na(5);this.j=null}q=Ks.prototype;q.configure=function(a){this.g=a;th
864
866
  q.stop=function(){this.s&&(this.s.stop(),this.s=null);var a=[];this.N&&(a.push(this.N.destroy()),this.N=null);this.g=this.h=null;this.Wa.clear();this.C=null;this.i.clear();this.H.clear();this.G.clear();this.o.clear();this.j&&this.j.destroy();return Promise.all(a)};
865
867
  q.update=function(){var a=this,b,c,d,e,f,g,h,k,l;return K(function(m){if(1==m.g){if(!Ps(a))return m.return();b=[];c=Array.from(a.i.values());a.m=Infinity;d=c.filter(function(n){return n.stream.segmentIndex});e=t(d);for(f=e.next();!f.done;f=e.next())g=f.value,b.push(Qs(a,g));return C(m,Promise.all(b),2)}Rs(a,d.map(function(n){return n.stream}));h=d.some(function(n){return 0==n.Nc});d.length&&!h&&(k=Ss,Ts(a,k.lg),l=d.map(function(n){return n.jb}),a.l.Ka(Math.min.apply(Math,w(l))),a.h.updateDuration());
866
868
  h&&Us(a);E(m)})};function Vs(a,b){return Ps(a)?a.J.get(b.type):b.Fd}
867
- function Qs(a,b){var c,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,B,A,D,F,J,G,H,I,L,M,P,R,V;return K(function(X){if(1==X.g){c=[];d=t(b.Y());for(e=d.next();!e.done;e=d.next())f=e.value,g=new fc(f),h=g.g,b.nd&&(0<=b.Sa&&h.add("_HLS_msn",String(b.Sa)),0<=b.Ta&&h.add("_HLS_part",String(b.Ta))),b.od&&h.add("_HLS_skip","YES"),uc(h)&&jc(g,h),c.push(g.toString());return C(X,Ns(a,c,!0),2)}k=X.h;if(!b.stream.segmentIndex)return X.return();l=As(a.la,k.data);if(1!=l.type)throw new O(2,4,4017);m=k.uri;m==k.originalUri||
868
- b.Y().includes(m)||b.Uf.push(m);n=ps(l.g,"EXT-X-DEFINE");r=Ws(a,n,m);p=b.stream;u=Vs(a,b);v=Xs(l,p.mimeType);x=v.keyIds;z=v.drmInfos;y=function(fa,Ha){return fa.size===Ha.size&&[].concat(w(fa)).every(function(Sa){return Ha.has(Sa)})};y(p.keyIds,x)||(p.keyIds=x,p.drmInfos=z,a.h.newDrmInfo(p));B=Ys(a,l,p,u,r,b.Y);A=B.segments;D=B.bandwidth;p.bandwidth=D;p.segmentIndex.Rc(A,a.l.ib());A.length&&(F=ss(l.g,"EXT-X-MEDIA-SEQUENCE",0),G=(J=rs(l.g,"EXT-X-SKIP"))?Number(Z(J,"SKIPPED-SEGMENTS")):0,H=Zs(F,A),
869
- I=H.Sa,L=H.Ta,b.Sa=I+G,b.Ta=L,M=u.get(F),p.segmentIndex.Xa(M));P=A[0];b.Nb=P.startTime;R=A[A.length-1];b.jb=R.endTime;if(V=rs(l.g,"EXT-X-ENDLIST"))b.Nc=!0;$s(a,l);E(X)})}q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(){};q.banLocation=function(a){this.j&&this.j.i.set(a,Date.now()+6E4)};
869
+ function Qs(a,b){var c,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,A,B,D,F,J,G,H,I,L,M,P,R,W;return K(function(X){if(1==X.g){c=[];d=t(b.Y());for(e=d.next();!e.done;e=d.next())f=e.value,g=new fc(f),h=g.g,b.nd&&(0<=b.Sa&&h.add("_HLS_msn",String(b.Sa)),0<=b.Ta&&h.add("_HLS_part",String(b.Ta))),b.od&&h.add("_HLS_skip","YES"),uc(h)&&jc(g,h),c.push(g.toString());return C(X,Ns(a,c,!0),2)}k=X.h;if(!b.stream.segmentIndex)return X.return();l=As(a.la,k.data);if(1!=l.type)throw new O(2,4,4017);m=k.uri;m==k.originalUri||
870
+ b.Y().includes(m)||b.Uf.push(m);n=ps(l.g,"EXT-X-DEFINE");r=Ws(a,n,m);p=b.stream;u=Vs(a,b);v=Xs(l,p.mimeType);x=v.keyIds;z=v.drmInfos;y=function(ia,Ha){return ia.size===Ha.size&&[].concat(w(ia)).every(function(Sa){return Ha.has(Sa)})};y(p.keyIds,x)||(p.keyIds=x,p.drmInfos=z,a.h.newDrmInfo(p));A=Ys(a,l,p,u,r,b.Y);B=A.segments;D=A.bandwidth;p.bandwidth=D;p.segmentIndex.Rc(B,a.l.ib());B.length&&(F=ss(l.g,"EXT-X-MEDIA-SEQUENCE",0),G=(J=rs(l.g,"EXT-X-SKIP"))?Number(Z(J,"SKIPPED-SEGMENTS")):0,H=Zs(F,B),
871
+ I=H.Sa,L=H.Ta,b.Sa=I+G,b.Ta=L,M=u.get(F),p.segmentIndex.Xa(M));P=B[0];b.Mb=P.startTime;R=B[B.length-1];b.jb=R.endTime;if(W=rs(l.g,"EXT-X-ENDLIST"))b.Nc=!0;$s(a,l);E(X)})}q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(){};q.banLocation=function(a){this.j&&this.j.i.set(a,Date.now()+6E4)};
870
872
  function at(a,b){for(var c=-1==a.I,d=t(b),e=d.next();!e.done;e=d.next()){e=e.value;var f=e.stream.segmentIndex,g=Vs(a,e);if(f=f.g[0]||null){g=t(g);for(var h=g.next();!h.done;h=g.next()){h=t(h.value);var k=h.next().value;if(h.next().value==f.startTime){c&&(a.I=Math.max(a.I,k));e.ge=k;break}}}}if(!(0>a.I))for(b=t(b),e=b.next();!e.done;e=b.next())if(c=e.value,d=c.stream.segmentIndex)if(d.g.splice(0,a.I-c.ge),d=d.g[0]||null)d=-d.startTime,c.stream.segmentIndex.offset(d),bt(a,c,d)}
871
873
  function ct(a,b){if(Infinity==a.V){b=t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value.stream.segmentIndex.g[0]||null;null!=d&&null!=d.i&&(a.V=Math.min(a.V,d.i))}}b=a.V;if(Infinity!=b)for(d=t(a.i.values()),c=d.next();!c.done;c=d.next()){c=c.value;var e=c.stream.segmentIndex;if(null!=e){var f=e.g[0]||null;if(null==f.i)Ra("Missing EXT-X-PROGRAM-DATE-TIME for stream",c.Y(),"Expect AV sync issues!");else for(bt(a,c,f.i-b-f.startTime),c=t(e),e=c.next();!e.done;e=c.next())e.value.ff(b)}}}
872
- function bt(a,b,c){b.Nb+=c;b.jb+=c;a=Vs(a,b);for(var d=t(a),e=d.next();!e.done;e=d.next()){var f=t(e.value);e=f.next().value;f=f.next().value;a.set(e,f+c)}b.Y()}
873
- function Os(a,b,c){var d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,B,A,D,F,J,G,H,I,L,M,P,R,V,X;return K(function(fa){switch(fa.g){case 1:d=As(a.la,b);e=ps(d.g,"EXT-X-DEFINE");f=[];g=[];h=[];if(1==d.type)return v=function(){return[c]},C(fa,dt(a,d,v),6);et(a,e);k=ps(d.g,"EXT-X-MEDIA");l=ps(d.g,"EXT-X-STREAM-INF");m=ps(d.g,"EXT-X-IMAGE-STREAM-INF");n=ps(d.g,"EXT-X-I-FRAME-STREAM-INF");r=ps(d.g,"EXT-X-SESSION-KEY");p=ps(d.g,"EXT-X-SESSION-DATA");u=ps(d.g,"EXT-X-CONTENT-STEERING");ft(a,p);return C(fa,gt(a,u),4);case 4:return ht(a,
874
- l),it(a,k),f=jt(a,l,r,k),g=kt(a,k),C(fa,lt(a,m,n),5);case 5:h=fa.h;fa.B(3);break;case 6:return x=fa.h,z=x.type,y=x.mimeType,B=x.codecs,A=x.language,D=x.height,F=x.width,J=x.channelCount,G=x.sampleRate,H=x.closedCaptions,C(fa,mt(a,a.u++,d,v,c,B,z,A,!0,"Media Playlist",J,H,null,!1,G,!1,y),7);case 7:I=fa.h,a.i.set(c,I),"video"==z&&nt(I.stream,F,D,null,null,null),f.push({id:0,language:Zc(A||"und"),disabledUntilTime:0,primary:!0,audio:"audio"==z?I.stream:null,video:"video"==z?I.stream:null,bandwidth:I.stream.bandwidth||
875
- 0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});case 3:if(!a.h)throw new O(2,7,7001);a.l=new Zi(null,0);a.l.hc(!0);1==d.type&&(Ps(a)&&(ot(a,d),L=a.m,a.s.U(L)),M=Array.from(a.i.values()),pt(a,M),Us(a));a.C={presentationTimeline:a.l,variants:f,textStreams:g,imageStreams:h,offlineSessionIds:[],minBufferTime:0,sequenceMode:a.g.hls.sequenceMode,ignoreManifestTimestampsInSegmentsMode:a.g.hls.ignoreManifestTimestampsInSegmentsMode,type:"HLS",serviceDescription:null};if(a.$||!a.g.hls.disableCodecGuessing){fa.B(8);
876
- break}P=[];R=t(a.C.variants);for(V=R.next();!V.done;V=R.next())X=V.value,X.audio&&""===X.audio.codecs&&P.push(X.audio.createSegmentIndex()),X.video&&""===X.video.codecs&&P.push(X.video.createSegmentIndex());return C(fa,Promise.all(P),8);case 8:a.h.makeTextStreamsForClosedCaptions(a.C),E(fa)}})}
877
- function dt(a,b,c){var d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,B,A;return K(function(D){switch(D.g){case 1:d=Hs(a.g.hls.mediaPlaylistFullMimeType);if(!b.segments.length)return D.return(d);e=Math.trunc((b.segments.length-1)/2);f=b.segments[e];g=ts(c(),b.segments[0].h);h=g[0];k=new fc(h);l=k.Ca.split(".").pop();if(m=qt[l])return D.return(Hs(m));n=kf;r=null;p=rt(a,b,f.g,c);if(!p){D.B(2);break}u=df(p.Y(),a.g.retryParameters);return C(D,st(a,u,n,{type:0}),3);case 3:v=D.h,r=v.data;case 2:return x=df(g,a.g.retryParameters),
874
+ function bt(a,b,c){b.Mb+=c;b.jb+=c;a=Vs(a,b);for(var d=t(a),e=d.next();!e.done;e=d.next()){var f=t(e.value);e=f.next().value;f=f.next().value;a.set(e,f+c)}b.Y()}
875
+ function Os(a,b,c){var d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,A,B,D,F,J,G,H,I,L,M,P,R,W,X;return K(function(ia){switch(ia.g){case 1:d=As(a.la,b);e=ps(d.g,"EXT-X-DEFINE");f=[];g=[];h=[];if(1==d.type)return v=function(){return[c]},C(ia,dt(a,d,v),6);et(a,e);k=ps(d.g,"EXT-X-MEDIA");l=ps(d.g,"EXT-X-STREAM-INF");m=ps(d.g,"EXT-X-IMAGE-STREAM-INF");n=ps(d.g,"EXT-X-I-FRAME-STREAM-INF");r=ps(d.g,"EXT-X-SESSION-KEY");p=ps(d.g,"EXT-X-SESSION-DATA");u=ps(d.g,"EXT-X-CONTENT-STEERING");ft(a,p);return C(ia,gt(a,u),4);case 4:return ht(a,
876
+ l),it(a,k),f=jt(a,l,r,k),g=kt(a,k),C(ia,lt(a,m,n),5);case 5:h=ia.h;ia.B(3);break;case 6:return x=ia.h,z=x.type,y=x.mimeType,A=x.codecs,B=x.language,D=x.height,F=x.width,J=x.channelCount,G=x.sampleRate,H=x.closedCaptions,C(ia,mt(a,a.u++,d,v,c,A,z,B,!0,"Media Playlist",J,H,null,!1,G,!1,y),7);case 7:I=ia.h,a.i.set(c,I),"video"==z&&nt(I.stream,F,D,null,null,null),f.push({id:0,language:Zc(B||"und"),disabledUntilTime:0,primary:!0,audio:"audio"==z?I.stream:null,video:"video"==z?I.stream:null,bandwidth:I.stream.bandwidth||
877
+ 0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});case 3:if(!a.h)throw new O(2,7,7001);a.l=new Zi(null,0);a.l.hc(!0);1==d.type&&(Ps(a)&&(ot(a,d),L=a.m,a.s.U(L)),M=Array.from(a.i.values()),pt(a,M),Us(a));a.C={presentationTimeline:a.l,variants:f,textStreams:g,imageStreams:h,offlineSessionIds:[],minBufferTime:0,sequenceMode:a.g.hls.sequenceMode,ignoreManifestTimestampsInSegmentsMode:a.g.hls.ignoreManifestTimestampsInSegmentsMode,type:"HLS",serviceDescription:null};if(a.$||!a.g.hls.disableCodecGuessing){ia.B(8);
878
+ break}P=[];R=t(a.C.variants);for(W=R.next();!W.done;W=R.next())X=W.value,X.audio&&""===X.audio.codecs&&P.push(X.audio.createSegmentIndex()),X.video&&""===X.video.codecs&&P.push(X.video.createSegmentIndex());return C(ia,Promise.all(P),8);case 8:a.h.makeTextStreamsForClosedCaptions(a.C),E(ia)}})}
879
+ function dt(a,b,c){var d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,A,B;return K(function(D){switch(D.g){case 1:d=Hs(a.g.hls.mediaPlaylistFullMimeType);if(!b.segments.length)return D.return(d);e=Math.trunc((b.segments.length-1)/2);f=b.segments[e];g=ts(c(),b.segments[0].h);h=g[0];k=new fc(h);l=k.Ca.split(".").pop();if(m=qt[l])return D.return(Hs(m));n=kf;r=null;p=rt(a,b,f.g,c);if(!p){D.B(2);break}u=df(p.Y(),a.g.retryParameters);return C(D,st(a,u,n,{type:0}),3);case 3:v=D.h,r=v.data;case 2:return x=df(g,a.g.retryParameters),
878
880
  C(D,st(a,x,n,{type:1}),4);case 4:z=D.h;(y=z.headers["content-type"])&&(y=y.split(";")[0].toLowerCase());if("ts"==l||"video/mp2t"==y){var F=z.data;var J=mb(F);J=(new ci).parse(J);var G=J.Hc();J=J.ze();var H=[],I=!1,L=!1;switch(G.audio){case "aac":H.push("mp4a.40.2");I=!0;break;case "mp3":H.push("mp4a.40.34");I=!0;break;case "ac3":H.push("ac-3");I=!0;break;case "ec3":H.push("ec-3"),I=!0}switch(G.video){case "avc":J.fa?H.push(J.fa):H.push("avc1.42E01E");L=!0;break;case "hvc":J.fa?H.push(J.fa):H.push("hvc1.1.6.L93.90"),
879
- L=!0}if(H.length){G=I&&!L;I=new Map;if(L){L=new sb("video/mp2t");L.i(F);F=t(L.j());for(var M=F.next();!M.done;M=F.next())M=M.value,I.set(M,M);L.h()}J={type:G?"audio":"video",mimeType:"video/mp2t",codecs:H.join(", "),language:null,height:J.height,width:J.width,channelCount:null,sampleRate:null,closedCaptions:I}}else J=null;if(B=J)return D.return(B)}else if("mp4"==l||"cmfv"==l||"m4s"==l||"video/mp4"==y||"audio/mp4"==y||"video/iso.segment"==y)if(A=Is(r,z.data))return D.return(A);return D.return(d)}})}
880
- function Us(a){if(Ps(a)){if(a.Ba==tt){for(var b,c=b=Infinity,d=t(a.i.values()),e=d.next();!e.done;e=d.next())e=e.value,e.stream.segmentIndex&&"text"!=e.stream.type&&(b=Math.min(b,e.jb),c=Math.min(c,e.Nb));b-=c;a.g.hls.useSafariBehaviorForLive&&(b=a.l.m);isNaN(a.g.availabilityWindowOverride)||(b=a.g.availabilityWindowOverride);a.l.Nd(b)}}else a.l.Ka(ut(a));a.l.Dd()}
881
+ L=!0}if(H.length){G=I&&!L;I=new Map;if(L){L=new sb("video/mp2t");L.i(F);F=t(L.j());for(var M=F.next();!M.done;M=F.next())M=M.value,I.set(M,M);L.h()}J={type:G?"audio":"video",mimeType:"video/mp2t",codecs:H.join(", "),language:null,height:J.height,width:J.width,channelCount:null,sampleRate:null,closedCaptions:I}}else J=null;if(A=J)return D.return(A)}else if("mp4"==l||"cmfv"==l||"m4s"==l||"video/mp4"==y||"audio/mp4"==y||"video/iso.segment"==y)if(B=Is(r,z.data))return D.return(B);return D.return(d)}})}
882
+ function Us(a){if(Ps(a)){if(a.Ba==tt){for(var b,c=b=Infinity,d=t(a.i.values()),e=d.next();!e.done;e=d.next())e=e.value,e.stream.segmentIndex&&"text"!=e.stream.type&&(b=Math.min(b,e.jb),c=Math.min(c,e.Mb));b-=c;a.g.hls.useSafariBehaviorForLive&&(b=a.l.m);isNaN(a.g.availabilityWindowOverride)||(b=a.g.availabilityWindowOverride);a.l.Nd(b)}}else a.l.Ka(ut(a));a.l.Dd()}
881
883
  function et(a,b){var c=(new fc(a.W)).g;b=t(b);for(var d=b.next();!d.done;d=b.next()){var e=d.value;d=Z(e,"NAME");var f=Z(e,"VALUE");e=Z(e,"QUERYPARAM");d&&f&&(a.o.has(d)||a.o.set(d,f));e&&(d=c.get(e)[0])&&!a.o.has(d)&&a.o.set(e,d)}}
882
884
  function Ws(a,b,c){c=(new fc(c)).g;var d=new Map;b=t(b);for(var e=b.next();!e.done;e=b.next()){var f=e.value,g=Z(f,"NAME"),h=Z(f,"VALUE");e=Z(f,"QUERYPARAM");f=Z(f,"IMPORT");g&&h&&(d.has(g)||d.set(g,h));e&&(g=c.get(e)[0])&&!d.has(g)&&d.set(e,g);f&&(e=a.o.get(f))&&d.set(f,e)}return d}
883
885
  function ht(a,b){b=t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value,e=Z(d,"AUDIO");c=Z(d,"VIDEO");var f=Z(d,"SUBTITLES");d=vt(a,d);if(f){var g=zc(Bc,d);a.G.set(f,g);yb(d,g)}e&&(f=zc("audio",d),f||(f=a.g.hls.defaultAudioCodec),a.G.set(e,f));c&&(e=zc("video",d),e||(e=a.g.hls.defaultVideoCodec),a.G.set(c,e))}}
@@ -885,7 +887,7 @@ function ft(a,b){b=t(b);for(var c=b.next();!c.done;c=b.next()){var d=c.value,e=Z
885
887
  function gt(a,b){var c,d,e,f,g,h;return K(function(k){if(!a.h||!a.g)return k.return();d=t(b);for(e=d.next();!e.done;e=d.next())if(f=e.value,g=Z(f,"PATHWAY-ID"),h=Z(f,"SERVER-URI"),g&&h){a.j=new $q(a.h);a.j.configure(a.g);a.j.j=[a.W];a.j.setManifestType("HLS");a.j.h=g;c=ar(a.j,h);break}return C(k,c,0)})}
886
888
  function kt(a,b){var c=qs(b,"SUBTITLES");b=c.map(function(g){if(a.g.disableText)return null;try{return wt(a,[g],new Map).stream}catch(h){if(a.g.hls.ignoreTextStreamFailures)return null;throw h;}});c=t(c);for(var d=c.next();!d.done;d=c.next()){var e=ms(d.value,"GROUP-ID");if(d=a.G.get(e))if(e=a.H.get(e)){e=t(e);for(var f=e.next();!f.done;f=e.next())f=f.value,f.stream.codecs=d,f.stream.mimeType=xt(Bc,d)||yt(Bc)}}return b.filter(function(g){return g})}
887
889
  function lt(a,b,c){var d,e;return K(function(f){if(1==f.g)return d=b.map(function(g){var h,k,l;return K(function(m){if(1==m.g){if(h=a.g.disableThumbnails)return m.return(null);sa(m,2);return C(m,zt(a,g),4)}if(2!=m.g)return k=m.h,m.return(k.stream);l=wa(m);if(a.g.hls.ignoreImageStreamFailures)return m.return(null);throw l;})}).concat(c.map(function(g){if(a.g.disableThumbnails)return null;try{var h=ms(g,"URI"),k=Z(g,"CODECS")||"";if(a.i.has(h))var l=a.i.get(h);else{var m=Z(g,"LANGUAGE"),n=Z(g,"NAME"),
888
- r=Z(g,"CHARACTERISTICS"),p=At(a,a.u++,[h],k,"image",m,!1,n,null,null,r,!1,null,!1),u=Z(g,"RESOLUTION"),v=t(u?u.split("x"):[null,null]),x=v.next().value,z=v.next().value;p.stream.width=Number(x)||void 0;p.stream.height=Number(z)||void 0;var y=Z(g,"BANDWIDTH");y&&(p.stream.bandwidth=Number(y));a.i.set(h,p);l=p}g=l;return"mjpg"!==g.stream.codecs?null:g.stream}catch(B){if(a.g.hls.ignoreImageStreamFailures)return null;throw B;}})),C(f,Promise.all(d),2);e=f.h;return f.return(e.filter(function(g){return g}))})}
890
+ r=Z(g,"CHARACTERISTICS"),p=At(a,a.u++,[h],k,"image",m,!1,n,null,null,r,!1,null,!1),u=Z(g,"RESOLUTION"),v=t(u?u.split("x"):[null,null]),x=v.next().value,z=v.next().value;p.stream.width=Number(x)||void 0;p.stream.height=Number(z)||void 0;var y=Z(g,"BANDWIDTH");y&&(p.stream.bandwidth=Number(y));a.i.set(h,p);l=p}g=l;return"mjpg"!==g.stream.codecs?null:g.stream}catch(A){if(a.g.hls.ignoreImageStreamFailures)return null;throw A;}})),C(f,Promise.all(d),2);e=f.h;return f.return(e.filter(function(g){return g}))})}
889
891
  function Bt(a,b,c){b=b.filter(function(h){var k=Z(h,"URI")||"";return"SUBTITLES"!=Z(h,"TYPE")&&""!=k});var d={};b=t(b);for(var e=b.next();!e.done;e=b.next()){e=e.value;var f=ls(e);d[f]?d[f].push(e):d[f]=[e]}for(var g in d)wt(a,d[g],c)}
890
892
  function jt(a,b,c,d){var e=[],f=new Set;if(0<c.length){c=t(c);for(var g=c.next();!g.done;g=c.next()){g=g.value;var h=ms(g,"METHOD");if("NONE"!=h&&"AES-128"!=h&&(h=Z(g,"KEYFORMAT")||"identity",g=(h=Ct[h])?h(g,""):null)){if(g.keyIds){h=t(g.keyIds);for(var k=h.next();!k.done;k=h.next())f.add(k.value)}e.push(g)}}}c={};b=t(b);for(g=b.next();!g.done;g=b.next())g=g.value,h=ls(g),c[h]?c[h].push(g):c[h]=[g];b=[];for(var l in c){k=c[l];var m=k[0];g=Z(m,"FRAME-RATE");h=Number(Z(m,"AVERAGE-BANDWIDTH"))||Number(ms(m,
891
893
  "BANDWIDTH"));var n=Z(m,"RESOLUTION"),r=t(n?n.split("x"):[null,null]);n=r.next().value;r=r.next().value;var p=Z(m,"VIDEO-RANGE");(m=Z(m,"REQ-VIDEO-LAYOUT"))&&m.includes(",")&&(m=m.split(",").filter(function(u){return"CH-STEREO"==u||"CH-MONO"==u})[0]);m=m||"CH-MONO";k=Dt(a,k,d);b.push.apply(b,w(Et(a,k.audio,k.video,h,n,r,g,p,m,e,f)))}return b.filter(function(u){return null!=u})}
@@ -901,15 +903,15 @@ m=n.next().value;n=n.next().value;(m=c.get(m))&&dr(a.j,l,m,n)}}c=Z(h,"LANGUAGE")
901
903
  function zt(a,b){var c,d,e,f,g,h,k,l,m,n;return K(function(r){if(1==r.g){c=ms(b,"URI");d=Z(b,"CODECS","jpeg")||"";if(a.i.has(c))return r.return(a.i.get(c));e=Z(b,"LANGUAGE");f=Z(b,"NAME");g=Z(b,"CHARACTERISTICS");h=At(a,a.u++,[c],d,"image",e,!1,f,null,null,g,!1,null,!1);return(k=Z(b,"RESOLUTION"))?C(r,h.stream.createSegmentIndex(),3):r.B(2)}2!=r.g&&(l=h.stream.segmentIndex.get(0),m=l.tilesLayout)&&(h.stream.width=Number(k.split("x")[0])*Number(m.split("x")[0]),h.stream.height=Number(k.split("x")[1])*
902
904
  Number(m.split("x")[1]));if(n=Z(b,"BANDWIDTH"))h.stream.bandwidth=Number(n);a.i.set(c,h);return r.return(h)})}
903
905
  function It(a,b,c,d,e,f,g,h,k){for(var l=a.u++,m=[],n=t(b),r=n.next();!r.done;r=n.next()){var p=r.value;r=ms(p,"URI");p=Z(p,"PATHWAY-ID");a.j&&p&&dr(a.j,l,p,r);m.push(r)}n=m.sort().join(",");if(a.i.has(n))return a.i.get(n);a:{b=Z(b[0],"CLOSED-CAPTIONS");if("video"==d){if(b&&"NONE"!=b){b=a.F.get(b);break a}if(!b&&a.F.size)for(b=t(a.F.keys()).next();!b.done;){b=a.F.get(b.value);break a}}b=null}c=yc(d,c);d=At(a,l,m,c,d,e,!1,f,g,b,h,!1,k,!1);a.i.set(n,d);return d}
904
- function At(a,b,c,d,e,f,g,h,k,l,m,n,r,p){function u(D){var F,J,G,H,I,L,M,P,R,V,X,fa,Ha,Sa,wb,db,Sb;return K(function(ua){switch(ua.g){case 1:return F=y.Y(),C(ua,Ns(a,y.Y(),!0),2);case 2:J=ua.h;if(D.aborted)return ua.return();G=J.uri;G==J.originalUri||F.includes(G)||z.push(G);H=As(a.la,J.data);I=void 0;if(a.$||!a.g.hls.disableCodecGuessing){ua.B(3);break}return C(ua,dt(a,H,v),4);case 4:L=ua.h,I=L.mimeType,d=L.codecs;case 3:return M=Ps(a),C(ua,mt(a,0,H,v,G,d,e,f,g,h,k,l,m,n,r,p,I),5);case 5:P=ua.h;
905
- if(D.aborted)return ua.return();R=P.stream;Ps(a)&&!M&&ot(a,H);y.Nb=P.Nb;y.jb=P.jb;y.od=P.od;y.nd=P.nd;y.Nc=P.Nc;y.Fd=P.Fd;y.Sa=P.Sa;y.Ta=P.Ta;y.Le=!0;x.segmentIndex=R.segmentIndex;x.encrypted=R.encrypted;x.drmInfos=R.drmInfos;x.keyIds=R.keyIds;x.mimeType=R.mimeType;x.bandwidth=R.bandwidth;x.codecs=R.codecs||x.codecs;x.drmInfos.length&&a.h.newDrmInfo(x);V=Cc;if(e==V.ea||e==V.P)for(X=t(a.i.values()),fa=X.next();!fa.done;fa=X.next())Ha=fa.value,Ha.Le||Ha.type!=e||(Ha.stream.mimeType=R.mimeType);e==V.ja&&
906
- (Sa=R.segmentIndex.get(0))&&Sa.g&&(x.mimeType="application/mp4");Jt(a)&&(a.sb?pt(a,[y]):(a.sb=!0,wb=Array.from(a.i.values()),db=wb.filter(function(eb){return eb.stream.segmentIndex}),pt(a,db),Us(a),Sb=a.m,0<Sb&&a.s.U(Sb)));E(ua)}})}function v(){return a.j&&1<c.length?er(a.j,b):z.concat(us([a.W],c,a.o))}var x=Kt(a,d,e,f,g,h,k,l,m,n,r,p),z=[],y={stream:x,type:e,Uf:z,Y:v,Nb:0,jb:0,Fd:new Map,od:!1,nd:!1,Nc:!1,ge:-1,Sa:-1,Ta:-1,Le:!1},B=null,A=new AbortController;x.createSegmentIndex=function(){if(B)return B;
907
- A=new AbortController;return B=new Promise(function(D){D(u(A.signal))})};x.closeSegmentIndex=function(){B&&!x.segmentIndex&&A.abort();x.segmentIndex&&(x.segmentIndex.release(),x.segmentIndex=null);B=null};return y}function ut(a){var b=Infinity;a=t(a.i.values());for(var c=a.next();!c.done;c=a.next())c=c.value,c.stream.segmentIndex&&"text"!=c.stream.type&&(b=Math.min(b,c.jb));return b}
906
+ function At(a,b,c,d,e,f,g,h,k,l,m,n,r,p){function u(D){var F,J,G,H,I,L,M,P,R,W,X,ia,Ha,Sa,wb,db,Sb;return K(function(ua){switch(ua.g){case 1:return F=y.Y(),C(ua,Ns(a,y.Y(),!0),2);case 2:J=ua.h;if(D.aborted)return ua.return();G=J.uri;G==J.originalUri||F.includes(G)||z.push(G);H=As(a.la,J.data);I=void 0;if(a.$||!a.g.hls.disableCodecGuessing){ua.B(3);break}return C(ua,dt(a,H,v),4);case 4:L=ua.h,I=L.mimeType,d=L.codecs;case 3:return M=Ps(a),C(ua,mt(a,0,H,v,G,d,e,f,g,h,k,l,m,n,r,p,I),5);case 5:P=ua.h;
907
+ if(D.aborted)return ua.return();R=P.stream;Ps(a)&&!M&&ot(a,H);y.Mb=P.Mb;y.jb=P.jb;y.od=P.od;y.nd=P.nd;y.Nc=P.Nc;y.Fd=P.Fd;y.Sa=P.Sa;y.Ta=P.Ta;y.Le=!0;x.segmentIndex=R.segmentIndex;x.encrypted=R.encrypted;x.drmInfos=R.drmInfos;x.keyIds=R.keyIds;x.mimeType=R.mimeType;x.bandwidth=R.bandwidth;x.codecs=R.codecs||x.codecs;x.drmInfos.length&&a.h.newDrmInfo(x);W=Cc;if(e==W.ea||e==W.P)for(X=t(a.i.values()),ia=X.next();!ia.done;ia=X.next())Ha=ia.value,Ha.Le||Ha.type!=e||(Ha.stream.mimeType=R.mimeType);e==W.ja&&
908
+ (Sa=R.segmentIndex.get(0))&&Sa.g&&(x.mimeType="application/mp4");Jt(a)&&(a.sb?pt(a,[y]):(a.sb=!0,wb=Array.from(a.i.values()),db=wb.filter(function(eb){return eb.stream.segmentIndex}),pt(a,db),Us(a),Sb=a.m,0<Sb&&a.s.U(Sb)));E(ua)}})}function v(){return a.j&&1<c.length?er(a.j,b):z.concat(us([a.W],c,a.o))}var x=Kt(a,d,e,f,g,h,k,l,m,n,r,p),z=[],y={stream:x,type:e,Uf:z,Y:v,Mb:0,jb:0,Fd:new Map,od:!1,nd:!1,Nc:!1,ge:-1,Sa:-1,Ta:-1,Le:!1},A=null,B=new AbortController;x.createSegmentIndex=function(){if(A)return A;
909
+ B=new AbortController;return A=new Promise(function(D){D(u(B.signal))})};x.closeSegmentIndex=function(){A&&!x.segmentIndex&&B.abort();x.segmentIndex&&(x.segmentIndex.release(),x.segmentIndex=null);A=null};return y}function ut(a){var b=Infinity;a=t(a.i.values());for(var c=a.next();!c.done;c=a.next())c=c.value,c.stream.segmentIndex&&"text"!=c.stream.type&&(b=Math.min(b,c.jb));return b}
908
910
  function Rs(a,b){var c=[];b=t(b);for(var d=b.next();!d.done;d=b.next())d=d.value,d.segmentIndex&&vj(d.segmentIndex,function(e){c.push(e)});a.l.Sc(c)}function pt(a,b){if(!Ps(a))for(var c=ut(a),d=t(b),e=d.next();!e.done;e=d.next())e.value.stream.segmentIndex.Wb(0,c);Rs(a,b.map(function(f){return f.stream}));a.g.hls.ignoreManifestProgramDateTime?at(a,b):ct(a,b)}
909
911
  function Jt(a){if(!a.C)return!1;var b=[],c=[];a=t(a.C.variants);for(var d=a.next();!d.done;d=a.next())d=d.value,d.video&&b.push(d.video),d.audio&&c.push(d.audio);return 0<b.length&&!b.some(function(e){return e.segmentIndex})||0<c.length&&!c.some(function(e){return e.segmentIndex})?!1:!0}
910
- function mt(a,b,c,d,e,f,g,h,k,l,m,n,r,p,u,v,x){var z,y,B,A,D,F,J,G,H,I,L,M,P,R,V,X,fa,Ha,Sa,wb,db,Sb,ua;return K(function(eb){if(1==eb.g){if(1!=c.type)throw new O(2,4,4017);z=ps(c.g,"EXT-X-DEFINE");y=Ws(a,z,e);var $a=rs(c.g,"EXT-X-PLAYLIST-TYPE"),xb=rs(c.g,"EXT-X-ENDLIST");xb=$a&&"VOD"==$a.value||xb;$a=$a&&"EVENT"==$a.value&&!xb;$a=!xb&&!$a;xb?Ts(a,Ms):$a?Ts(a,tt):Ts(a,Lt);Ps(a)&&$s(a,c);return x?eb.B(2):C(eb,Mt(a,g,f,c,y,d),3)}2!=eb.g&&(x=eb.h);B=Xs(c,x);A=B.drmInfos;D=B.keyIds;F=B.encrypted;J=B.pg;
911
- if(F&&!A.length&&!J)throw new O(2,4,4026);G=Kt(a,f,g,h,k,l,m,n,r,p,u,v);G.encrypted=F;G.drmInfos=A;G.keyIds=D;G.mimeType=x;H=Ps(a)?a.J.get(g):new Map;I=Ys(a,c,G,H,y,d);L=I.segments;M=I.bandwidth;G.bandwidth=M;Ps(a)&&$s(a,c);P=L[0].startTime;R=L[L.length-1];V=R.endTime;X=new uj(L);G.segmentIndex=X;Ha=(fa=rs(c.g,"EXT-X-SERVER-CONTROL"))?null!=fa.getAttribute("CAN-SKIP-UNTIL"):!1;Sa=fa?null!=fa.getAttribute("CAN-BLOCK-RELOAD"):!1;wb=ss(c.g,"EXT-X-MEDIA-SEQUENCE",0);db=Zs(wb,L);Sb=db.Sa;ua=db.Ta;return eb.return({stream:G,
912
- type:g,Uf:[],Y:d,Nb:P,jb:V,od:Ha,nd:Sa,Nc:!1,ge:-1,Sa:Sb,Ta:ua,Fd:H,Le:!1})})}function Zs(a,b){a=a+b.length-1;var c=-1;if(!b.length)return a++,{Sa:a,Ta:c};b=b[b.length-1];var d=b.h;if(!b.h.length)return a++,b.s&&(c=0),{Sa:a,Ta:c};c=d.length-1;d[d.length-1].o||(a++,c=0);return{Sa:a,Ta:c}}
912
+ function mt(a,b,c,d,e,f,g,h,k,l,m,n,r,p,u,v,x){var z,y,A,B,D,F,J,G,H,I,L,M,P,R,W,X,ia,Ha,Sa,wb,db,Sb,ua;return K(function(eb){if(1==eb.g){if(1!=c.type)throw new O(2,4,4017);z=ps(c.g,"EXT-X-DEFINE");y=Ws(a,z,e);var $a=rs(c.g,"EXT-X-PLAYLIST-TYPE"),xb=rs(c.g,"EXT-X-ENDLIST");xb=$a&&"VOD"==$a.value||xb;$a=$a&&"EVENT"==$a.value&&!xb;$a=!xb&&!$a;xb?Ts(a,Ms):$a?Ts(a,tt):Ts(a,Lt);Ps(a)&&$s(a,c);return x?eb.B(2):C(eb,Mt(a,g,f,c,y,d),3)}2!=eb.g&&(x=eb.h);A=Xs(c,x);B=A.drmInfos;D=A.keyIds;F=A.encrypted;J=A.pg;
913
+ if(F&&!B.length&&!J)throw new O(2,4,4026);G=Kt(a,f,g,h,k,l,m,n,r,p,u,v);G.encrypted=F;G.drmInfos=B;G.keyIds=D;G.mimeType=x;H=Ps(a)?a.J.get(g):new Map;I=Ys(a,c,G,H,y,d);L=I.segments;M=I.bandwidth;G.bandwidth=M;Ps(a)&&$s(a,c);P=L[0].startTime;R=L[L.length-1];W=R.endTime;X=new uj(L);G.segmentIndex=X;Ha=(ia=rs(c.g,"EXT-X-SERVER-CONTROL"))?null!=ia.getAttribute("CAN-SKIP-UNTIL"):!1;Sa=ia?null!=ia.getAttribute("CAN-BLOCK-RELOAD"):!1;wb=ss(c.g,"EXT-X-MEDIA-SEQUENCE",0);db=Zs(wb,L);Sb=db.Sa;ua=db.Ta;return eb.return({stream:G,
914
+ type:g,Uf:[],Y:d,Mb:P,jb:W,od:Ha,nd:Sa,Nc:!1,ge:-1,Sa:Sb,Ta:ua,Fd:H,Le:!1})})}function Zs(a,b){a=a+b.length-1;var c=-1;if(!b.length)return a++,{Sa:a,Ta:c};b=b[b.length-1];var d=b.h;if(!b.h.length)return a++,b.s&&(c=0),{Sa:a,Ta:c};c=d.length-1;d[d.length-1].o||(a++,c=0);return{Sa:a,Ta:c}}
913
915
  function Kt(a,b,c,d,e,f,g,h,k,l,m,n){var r=xt(c,b)||yt(c),p=[];if(k){k=t(k.split(","));for(var u=k.next();!u.done;u=k.next())p.push(u.value)}k=void 0;u=null;c==Bc?k=p.includes("public.accessibility.transcribes-spoken-dialog")&&p.includes("public.accessibility.describes-music-and-sound")?"caption":"subtitle":p.includes("public.accessibility.describes-video")&&(u="visually impaired");p.length||"subtitle"!==k||p.push("subtitle");return{id:a.u++,originalId:f,groupId:null,createSegmentIndex:function(){return Promise.resolve()},
914
916
  segmentIndex:null,mimeType:r,codecs:b,kind:c==Bc?"subtitle":void 0,encrypted:!1,drmInfos:[],keyIds:new Set,language:Zc(d||"und"),originalLanguage:d,label:f,type:c,primary:e,trickModeVideo:null,emsgSchemeIdUris:null,frameRate:void 0,pixelAspectRatio:void 0,width:void 0,height:void 0,bandwidth:void 0,roles:p,forced:l,channelsCount:g,audioSamplingRate:m,spatialAudio:n,closedCaptions:h,hdr:void 0,videoLayout:void 0,tilesLayout:void 0,accessibilityPurpose:u,external:!1,fastSwitching:!1}}
915
917
  function Xs(a,b){var c=[];if(a.segments){a=t(a.segments);for(var d=a.next();!d.done;d=a.next())d=ps(d.value.g,"EXT-X-KEY"),c.push.apply(c,w(d))}d=a=!1;var e=[],f=new Set;c=t(c);for(var g=c.next();!g.done;g=c.next()){g=g.value;var h=ms(g,"METHOD");if("NONE"!=h)if(a=!0,"AES-128"==h)d=!0;else if(h=Z(g,"KEYFORMAT")||"identity",g=(h=Ct[h])?h(g,b):null){if(g.keyIds){h=t(g.keyIds);for(var k=h.next();!k.done;k=h.next())f.add(k.value)}e.push(g)}}return{drmInfos:e,keyIds:f,encrypted:a,pg:d}}
@@ -920,16 +922,17 @@ b.getAttribute("HOLD-BACK"):null,a.da=c?Number(c.value):0);a.va=Math.max(d,a.va)
920
922
  function rt(a,b,c,d,e){var f=rs(c,"EXT-X-MAP");if(!f)return null;var g=ms(f,"URI"),h=ts(d(),g,e);g=[h.toString(),Z(f,"BYTERANGE","")].join("-");if(!a.ma.has(g)){var k=void 0,l=null;c=t(c);for(var m=c.next();!m.done;m=c.next())m=m.value,"EXT-X-KEY"==m.name?"AES-128"==ms(m,"METHOD")&&m.id<f.id&&(k=Nt(a,m,b,d,e)):"EXT-X-BYTERANGE"==m.name&&m.id<f.id&&(l=m);b=Ot(h,f,l,k);a.ma.set(g,b)}return a.ma.get(g)}
921
923
  function Ot(a,b,c,d){var e=0,f=null;b=Z(b,"BYTERANGE");!b&&c&&(b=c.value);b&&(e=b.split("@"),f=Number(e[0]),e=Number(e[1]),f=e+f-1,d&&(c=f+1-e,c%16&&(f+=16-c%16)));return new uh(function(){return a},e,f,null,null,null,d)}
922
924
  function Pt(a,b,c,d,e,f,g,h,k){var l=d.g,m=rs(l,"EXTINF"),n=0,r=0,p=null;d.Za.length&&!a.A&&Ta("Low-latency HLS live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details.");var u=null;if(!a.g.hls.ignoreManifestProgramDateTime){var v=rs(l,"EXT-X-PROGRAM-DATE-TIME");v&&v.value&&(u=mg(v.value))}var x=wh;rs(l,"EXT-X-GAP")&&(x=2);if(!m){if(0==d.Za.length)throw new O(2,4,4024,"EXTINF");
923
- if(!a.A)return null}var z=[];v=!1;var y=null,B=!1,A=!1;if(a.A&&d.Za.length){n=("video/mp4"==g.mimeType||"audio/mp4"==g.mimeType)&&window.ReadableStream&&a.g.hls.allowLowLatencyByteRangeOptimization;for(var D=u,F={},J=0;J<d.Za.length;F={vc:F.vc,fd:F.fd},J++){var G=d.Za[J],H=0==J?c:z[z.length-1],I=0==J?e:H.endTime,L=Number(Z(G,"DURATION"))||a.K;if(L){var M=I+L,P=0,R=null;"EXT-X-PRELOAD-HINT"==G.name?(P=(P=Z(G,"BYTERANGE-START"))?Number(P):0,(H=Z(G,"BYTERANGE-LENGTH"))?R=P+Number(H)-1:P&&(R=Number.MAX_SAFE_INTEGER)):
924
- (P=Z(G,"BYTERANGE"),R=t(Qt(H,P)),P=R.next().value,R=R.next().value);F.fd=Z(G,"URI");if(F.fd){H=wh;"YES"==Z(G,"GAP")&&(H=2,B=!0);F.vc=null;var V=function(fa){return function(){null==fa.vc&&(fa.vc=ts(h(),fa.fd,f));return fa.vc}}(F);n&&0<=P&&null!=R&&(y=V,v=!0);I=new S(I,M,V,P,R,b,0,0,Infinity,[],"",null,D,H,k);"EXT-X-PRELOAD-HINT"==G.name&&(I.Me(),A=!0);"YES"!=Z(G,"INDEPENDENT")&&0<J&&I.Ed();z.push(I);D&&(D+=L)}}}}if(m){m=Number(m.value.split(",")[0]);if(0==m)return null;n=e+m}else if(z.length)n=z[z.length-
925
- 1].endTime;else return null;v&&(B||0!=z[0].La?(v=!1,y=null):z=[]);(m=rs(l,"EXT-X-BYTERANGE"))?(p=t(Qt(c,m.value)),r=p.next().value,p=p.next().value):z.length&&(r=z[0].La,p=z[z.length-1].sa);c="";m=null;"image"==g.type&&(c="1x1",g=rs(l,"EXT-X-TILES"))&&(c=ms(g,"LAYOUT"),(g=Z(g,"DURATION"))&&(m=Number(g)));var X=null;b=new S(e,n,function(){if(y)return y();null==X&&(X=ts(h(),d.h,f));return X||[]},r,p,b,0,0,Infinity,z,c,m,u,x,k,0<z.length&&!!d.h);v&&(a.rb=!0,b.Mf(),A&&b.Me());return b}
925
+ if(!a.A)return null}var z=[];v=!1;var y=null,A=!1,B=!1;if(a.A&&d.Za.length){n=("video/mp4"==g.mimeType||"audio/mp4"==g.mimeType)&&window.ReadableStream&&a.g.hls.allowLowLatencyByteRangeOptimization;for(var D=u,F={},J=0;J<d.Za.length;F={vc:F.vc,fd:F.fd},J++){var G=d.Za[J],H=0==J?c:z[z.length-1],I=0==J?e:H.endTime,L=Number(Z(G,"DURATION"))||a.K;if(L){var M=I+L,P=0,R=null;"EXT-X-PRELOAD-HINT"==G.name?(P=(P=Z(G,"BYTERANGE-START"))?Number(P):0,(H=Z(G,"BYTERANGE-LENGTH"))?R=P+Number(H)-1:P&&(R=Number.MAX_SAFE_INTEGER)):
926
+ (P=Z(G,"BYTERANGE"),R=t(Qt(H,P)),P=R.next().value,R=R.next().value);F.fd=Z(G,"URI");if(F.fd){H=wh;"YES"==Z(G,"GAP")&&(H=2,A=!0);F.vc=null;var W=function(ia){return function(){null==ia.vc&&(ia.vc=ts(h(),ia.fd,f));return ia.vc}}(F);n&&0<=P&&null!=R&&(y=W,v=!0);I=new S(I,M,W,P,R,b,0,0,Infinity,[],"",null,D,H,k);"EXT-X-PRELOAD-HINT"==G.name&&(I.Me(),B=!0);"YES"!=Z(G,"INDEPENDENT")&&0<J&&I.Ed();z.push(I);D&&(D+=L)}}}}if(m){m=Number(m.value.split(",")[0]);if(0==m)return null;n=e+m}else if(z.length)n=z[z.length-
927
+ 1].endTime;else return null;v&&(A||0!=z[0].La?(v=!1,y=null):z=[]);(m=rs(l,"EXT-X-BYTERANGE"))?(p=t(Qt(c,m.value)),r=p.next().value,p=p.next().value):z.length&&(r=z[0].La,p=z[z.length-1].sa);c="";m=null;"image"==g.type&&(c="1x1",g=rs(l,"EXT-X-TILES"))&&(c=ms(g,"LAYOUT"),(g=Z(g,"DURATION"))&&(m=Number(g)));var X=null;b=new S(e,n,function(){if(y)return y();null==X&&(X=ts(h(),d.h,f));return X||[]},r,p,b,0,0,Infinity,z,c,m,u,x,k,0<z.length&&!!d.h);v&&(a.rb=!0,b.Mf(),B&&b.Me());return b}
926
928
  function Qt(a,b){var c=0,d=null;b&&(c=b.split("@"),b=Number(c[0]),c=c[1]?Number(c[1]):a.sa+1,d=c+b-1);return[c,d]}
927
- function Ys(a,b,c,d,e,f){var g=b.segments,h=void 0,k=ss(b.g,"EXT-X-DISCONTINUITY-SEQUENCE",0),l=ss(b.g,"EXT-X-MEDIA-SEQUENCE",0),m=rs(b.g,"EXT-X-SKIP"),n=m?Number(Z(m,"SKIPPED-SEGMENTS")):0,r=l+n,p=0;Ps(a)&&d.has(r)&&(p=d.get(r));var u=[],v=null;m=[];for(var x=0;x<g.length;x++){var z=g[x],y=0==x?p:v.endTime;r=l+n+x;rs(z.g,"EXT-X-DISCONTINUITY")&&k++;var B=t(z.g);for(var A=B.next();!A.done;A=B.next())A=A.value,"EXT-X-KEY"==A.name&&("AES-128"==ms(A,"METHOD")?h=Nt(a,A,b,f,e):h=void 0);d.set(r,y);B=rt(a,
928
- b,z.g,f,e);!a.A&&a.h.isAutoLowLatencyMode()&&(a.h.enableLowLatencyMode(),a.A=a.h.isLowLatencyMode());if(y=Pt(a,B,v,z,y,e,c,f,h))(v=ss(z.g,"EXT-X-BITRATE"))?m.push({bitrate:v,duration:y.endTime-y.startTime}):m.length&&(v=m.pop(),v.duration+=y.endTime-y.startTime,m.push(v)),v=y,y.l=k,a.g.hls.ignoreManifestProgramDateTime&&null!=a.I&&r<a.I||u.push(y)}b=void 0;m.length&&(b=m.reduce(function(D,F){return D+F.duration},0),b=Math.round(m.reduce(function(D,F){return D+F.bitrate*F.duration},0)/b*1E3));if(m=
929
+ function Ys(a,b,c,d,e,f){var g=b.segments,h=void 0,k=ss(b.g,"EXT-X-DISCONTINUITY-SEQUENCE",0),l=ss(b.g,"EXT-X-MEDIA-SEQUENCE",0),m=rs(b.g,"EXT-X-SKIP"),n=m?Number(Z(m,"SKIPPED-SEGMENTS")):0,r=l+n,p=0;Ps(a)&&d.has(r)&&(p=d.get(r));var u=[],v=null;m=[];for(var x=0;x<g.length;x++){var z=g[x],y=0==x?p:v.endTime;r=l+n+x;rs(z.g,"EXT-X-DISCONTINUITY")&&k++;var A=t(z.g);for(var B=A.next();!B.done;B=A.next())B=B.value,"EXT-X-KEY"==B.name&&("AES-128"==ms(B,"METHOD")?h=Nt(a,B,b,f,e):h=void 0);d.set(r,y);A=rt(a,
930
+ b,z.g,f,e);!a.A&&a.h.isAutoLowLatencyMode()&&(a.h.enableLowLatencyMode(),a.A=a.h.isLowLatencyMode());if(y=Pt(a,A,v,z,y,e,c,f,h))(v=ss(z.g,"EXT-X-BITRATE"))?m.push({bitrate:v,duration:y.endTime-y.startTime}):m.length&&(v=m.pop(),v.duration+=y.endTime-y.startTime,m.push(v)),v=y,y.l=k,a.g.hls.ignoreManifestProgramDateTime&&null!=a.I&&r<a.I||u.push(y)}b=void 0;m.length&&(b=m.reduce(function(D,F){return D+F.duration},0),b=Math.round(m.reduce(function(D,F){return D+F.bitrate*F.duration},0)/b*1E3));if(m=
929
931
  u.some(function(D){return null!=D.i}))for(c={},d=0;d<u.length;c={nc:c.nc,mc:c.mc,bd:c.bd,ob:c.ob,lc:c.lc},d++)if(c.ob=u[d],null==c.ob.i)for(c.mc=0,c.nc=d,e=function(D){return function(){var F=u[D.nc];if(F){if(null!=F.i)return F.i+D.mc;D.mc-=F.endTime-F.startTime;D.nc+=1}return null}}(c),c.lc=0,c.bd=d,f=function(D){return function(){var F=u[D.bd];if(F){F!=D.ob&&(D.lc+=F.endTime-F.startTime);if(null!=F.i)return F.i+D.lc;--D.bd}return null}}(c);null==c.ob.i;)c.ob.i=f(),null==c.ob.i&&(c.ob.i=e());if(m)for(c=
930
932
  t(u),d=c.next();!d.done;d=c.next())for(e=d.value,d=e.i,e=t(e.h),f=e.next();!f.done;f=e.next())f=f.value,f.i=d,d+=f.endTime-f.startTime;a=a.V;if(m&&Infinity!=a)for(m=t(u),d=m.next();!d.done;d=m.next())d.value.ff(a);return{segments:u,bandwidth:b}}function xt(a,b){if(a==Bc){if("vtt"==b||"wvtt"==b)return"text/vtt";if(b&&""!==b)return"application/mp4"}return"image"!=a||b&&"jpeg"!=b?"audio"==a&&"mp4a.40.34"==b?"audio/mpeg":"mjpg"==b?"application/mp4":null:"image/jpeg"}
931
- function yt(a){return a==Bc?"text/vtt":Rt[a].mp4}function Mt(a,b,c,d,e,f){var g,h,k,l,m,n,r,p,u,v;return K(function(x){if(1==x.g){g=kf;h=Math.trunc((d.segments.length-1)/2);k=ts(f(),d.segments[h].h,e);l=new fc(k[0]);m=l.Ca.split(".").pop();n=Rt[b];if((r=n[m])||(r=qt[m])||(r=xt(b,c)))return x.return(r);p=df(k,a.g.retryParameters);p.method="HEAD";return C(x,st(a,p,g,{type:1}),2)}u=x.h;return(v=u.headers["content-type"])?x.return(v.split(";")[0]):x.return(yt(b))})}
932
- function nt(a,b,c,d,e,f){a&&(a.width=Number(b)||void 0,a.height=Number(c)||void 0,a.frameRate=Number(d)||void 0,a.hdr=e||void 0,a.videoLayout=f||void 0)}function Ns(a,b,c){return st(a,df(b,a.g.retryParameters),0,{type:c?2:3})}
933
+ function yt(a){return a==Bc?"text/vtt":Rt[a].mp4}
934
+ function Mt(a,b,c,d,e,f){var g,h,k,l,m,n,r,p,u,v,x,z,y;return K(function(A){switch(A.g){case 1:g=kf;h=Math.trunc((d.segments.length-1)/2);k=ts(f(),d.segments[h].h,e);l=new fc(k[0]);m=l.Ca.split(".").pop();n=Rt[b];if((r=n[m])||(r=qt[m])||(r=xt(b,c)))return A.return(r);u=1;v=df(k,a.g.retryParameters);sa(A,2);v.method="HEAD";return C(A,st(a,v,g,{type:u}),4);case 4:x=A.h;p=x.headers["content-type"];va(A,3);break;case 2:z=wa(A);if(!z||1002!=z.code){A.B(3);break}v.method="GET";return C(A,st(a,v,g,{type:u}),
935
+ 6);case 6:y=A.h,p=y.headers["content-type"];case 3:return p?A.return(p.split(";")[0]):A.return(yt(b))}})}function nt(a,b,c,d,e,f){a&&(a.width=Number(b)||void 0,a.height=Number(c)||void 0,a.frameRate=Number(d)||void 0,a.hdr=e||void 0,a.videoLayout=f||void 0)}function Ns(a,b,c){return st(a,df(b,a.g.retryParameters),0,{type:c?2:3})}
933
936
  function Ls(a){var b,c,d,e,f,g;K(function(h){switch(h.g){case 1:if(!a.h)return h.return();sa(h,2);b=Date.now();return C(h,a.update(),4);case 4:c=Date.now();Ps(a)&&(d=(c-b)/1E3,a.cb.sample(1,d),e=a.m,f=Math.max(0,e-Oa(a.cb)),a.s.U(f));va(h,3);break;case 2:g=wa(h);if(!a.h)return h.return();if(a.g.raiseFatalErrorOnManifestUpdateRequestFailure)return a.h.onError(g),h.return();g.severity=1;a.h.onError(g);a.s.U(.1);case 3:if(!a.h)return h.return();a.h.onManifestUpdated();E(h)}})}
934
937
  function Ps(a){return a.Ba!=Ms}function Ts(a,b){a.Ba=b;a.l&&a.l.hc(!Ps(a));Ps(a)||a.s.stop()}function st(a,b,c,d){if(!a.N)throw new O(2,7,7001);b=a.h.networkingEngine.request(c,b,d);Ze(a.N,b);return b.promise}N("shaka.hls.HlsParser",Ks);
935
938
  var qt={aac:"audio/aac",ac3:"audio/ac3",ec3:"audio/ec3",mp3:"audio/mpeg"},Rt={audio:{mp4:"audio/mp4",mp4a:"audio/mp4",m4s:"audio/mp4",m4i:"audio/mp4",m4a:"audio/mp4",m4f:"audio/mp4",cmfa:"audio/mp4",ts:"video/mp2t",tsa:"video/mp2t"},video:{mp4:"video/mp4",mp4v:"video/mp4",m4s:"video/mp4",m4i:"video/mp4",m4v:"video/mp4",m4f:"video/mp4",cmfv:"video/mp4",ts:"video/mp2t",tsv:"video/mp2t"},text:{mp4:"application/mp4",m4s:"application/mp4",m4i:"application/mp4",m4f:"application/mp4",cmft:"application/mp4",
@@ -959,10 +962,10 @@ function wu(a){var b;K(function(c){switch(c.g){case 1:return sa(c,2),C(c,xu(a),4
959
962
  q.update=function(){var a=this,b;return K(function(c){if(1==c.g)return sa(c,2),C(c,xu(a),4);if(2!=c.g)return va(c,0);b=wa(c);if(!a.h||!b)return c.return();a.h.onError(b);E(c)})};q.onExpirationUpdated=function(){};q.onInitialVariantChosen=function(){};q.banLocation=function(){};
960
963
  function xu(a){var b,c,d,e,f,g,h;return K(function(k){if(1==k.g)return b=df(a.l,a.g.retryParameters),c=a.h.networkingEngine,d=Date.now(),e=c.request(0,b,{type:5}),Ze(a.u,e),C(k,e.promise,2);f=k.h;if(!a.h)return k.return();f.uri&&!a.l.includes(f.uri)&&a.l.unshift(f.uri);var l=f.uri,m=xg(f.data,"SmoothStreamingMedia");if(!m)throw new O(2,4,4046,l);(l=a.g.mss.manifestPreprocessor)&&l(m);a.i||(a.i=new Zi(null,0));if(l=lg(m,"IsLive",tg,!1))throw new O(2,4,4047);a.i.hc(!l);var n=lg(m,"TimeScale",rg,1E7),
961
964
  r=lg(m,"DVRWindowLength",rg);l&&(0===r||isNaN(r))&&(r=Infinity);var p=lg(m,"CanSeek",tg,!1);0===r&&p&&(r=Infinity);p=null;r&&0<r&&(p=r/n);l&&!isNaN(a.g.availabilityWindowOverride)&&(p=a.g.availabilityWindowOverride);null==p&&(p=Infinity);a.i.Nd(p);r=lg(m,"Duration",rg,Infinity);l||a.i.Ka(r/n);l={variants:[],textStreams:[],timescale:n,duration:r/n};p=dg(m,"Protection");var u;n=a.g.mss.keySystemsBySystemId;r=[];p=t(p);for(u=p.next();!u.done;u=p.next())r=r.concat(dg(u.value,"ProtectionHeader"));if(r.length){p=
962
- [];for(u=0;u<r.length;u++){var v=r[u],x=v.getAttribute("SystemID").toLowerCase(),z=n[x];if(z){var y=Ut(v);if(y)a:{y=t(y.getElementsByTagName("DATA"));for(var B=y.next();!B.done;B=y.next())if(B=cg(B.value,"KID")){y=Xf(B.textContent);y=new Uint8Array([y[3],y[2],y[1],y[0],y[5],y[4],y[7],y[6]].concat(w(y.slice(8))));y=Zf(y);break a}y=null}else y=null;B=Xf(v.textContent);x=Yf(x.replace(/-/g,""));x=[{initData:bg(B,x,new Set,0),initDataType:"cenc",keyId:y}];x=xc(z,x);y&&x.keyIds.add(y);if(z=Wt.get(z))x.licenseServerUri=
963
- z(v);p.push(x)}}n=p}else n=[];u=n;p=[];n=[];r=[];m=dg(m,"StreamIndex");m=t(m);for(v=m.next();!v.done;v=m.next()){v=v.value;z=dg(v,"QualityLevel");x=l.timescale;y=l.duration;B=dg(v,"c");for(var A=[],D=0,F=0;F<B.length;++F){var J=B[F],G=B[F+1],H=lg(J,"t",rg),I=lg(J,"d",rg);J=lg(J,"r",pg);if(!I)break;H=null!=H?H:D;J=J||0;if(0>J)if(G){G=lg(G,"t",rg);if(null==G)break;else if(H>=G)break;J=Math.ceil((G-H)/I)-1}else{if(Infinity==y)break;else if(H/x>=y)break;J=Math.ceil((y*x-H)/I)-1}for(G=0;G<=J;++G)D=H+I,
964
- A.push({start:H/x,end:D/x,mf:H}),H=D}x=A;z=t(z);for(y=z.next();!y.done;y=z.next())(y=yu(a,v,y.value,x,u,l))&&("audio"!=y.type||a.g.disableAudio?"video"!=y.type||a.g.disableVideo?y.type!=Bc||a.g.disableText||r.push(y):n.push(y):p.push(y))}m=[];p=t(0<p.length?p:[null]);for(u=p.next();!u.done;u=p.next())for(u=u.value,v=t(0<n.length?n:[null]),y=v.next();!y.done;y=v.next())z=m,x=z.push,y=y.value,B=0,u&&u.bandwidth&&0<u.bandwidth&&(B+=u.bandwidth),y&&y.bandwidth&&0<y.bandwidth&&(B+=y.bandwidth),y={id:a.s++,
965
- language:u?u.language:"und",disabledUntilTime:0,primary:!!u&&u.primary||!!y&&y.primary,audio:u,video:y,bandwidth:B,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},x.call(z,y);l.variants=m;l.textStreams=r;a.j?(a.j.variants=l.variants,a.j.textStreams=l.textStreams,a.h.filter(a.j)):(a.j={presentationTimeline:a.i,variants:l.variants,textStreams:l.textStreams,imageStreams:[],offlineSessionIds:[],minBufferTime:0,sequenceMode:a.g.mss.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,
965
+ [];for(u=0;u<r.length;u++){var v=r[u],x=v.getAttribute("SystemID").toLowerCase(),z=n[x];if(z){var y=Ut(v);if(y)a:{y=t(y.getElementsByTagName("DATA"));for(var A=y.next();!A.done;A=y.next())if(A=cg(A.value,"KID")){y=Xf(A.textContent);y=new Uint8Array([y[3],y[2],y[1],y[0],y[5],y[4],y[7],y[6]].concat(w(y.slice(8))));y=Zf(y);break a}y=null}else y=null;A=Xf(v.textContent);x=Yf(x.replace(/-/g,""));x=[{initData:bg(A,x,new Set,0),initDataType:"cenc",keyId:y}];x=xc(z,x);y&&x.keyIds.add(y);if(z=Wt.get(z))x.licenseServerUri=
966
+ z(v);p.push(x)}}n=p}else n=[];u=n;p=[];n=[];r=[];m=dg(m,"StreamIndex");m=t(m);for(v=m.next();!v.done;v=m.next()){v=v.value;z=dg(v,"QualityLevel");x=l.timescale;y=l.duration;A=dg(v,"c");for(var B=[],D=0,F=0;F<A.length;++F){var J=A[F],G=A[F+1],H=lg(J,"t",rg),I=lg(J,"d",rg);J=lg(J,"r",pg);if(!I)break;H=null!=H?H:D;J=J||0;if(0>J)if(G){G=lg(G,"t",rg);if(null==G)break;else if(H>=G)break;J=Math.ceil((G-H)/I)-1}else{if(Infinity==y)break;else if(H/x>=y)break;J=Math.ceil((y*x-H)/I)-1}for(G=0;G<=J;++G)D=H+I,
967
+ B.push({start:H/x,end:D/x,mf:H}),H=D}x=B;z=t(z);for(y=z.next();!y.done;y=z.next())(y=yu(a,v,y.value,x,u,l))&&("audio"!=y.type||a.g.disableAudio?"video"!=y.type||a.g.disableVideo?y.type!=Bc||a.g.disableText||r.push(y):n.push(y):p.push(y))}m=[];p=t(0<p.length?p:[null]);for(u=p.next();!u.done;u=p.next())for(u=u.value,v=t(0<n.length?n:[null]),y=v.next();!y.done;y=v.next())z=m,x=z.push,y=y.value,A=0,u&&u.bandwidth&&0<u.bandwidth&&(A+=u.bandwidth),y&&y.bandwidth&&0<y.bandwidth&&(A+=y.bandwidth),y={id:a.s++,
968
+ language:u?u.language:"und",disabledUntilTime:0,primary:!!u&&u.primary||!!y&&y.primary,audio:u,video:y,bandwidth:A,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},x.call(z,y);l.variants=m;l.textStreams=r;a.j?(a.j.variants=l.variants,a.j.textStreams=l.textStreams,a.h.filter(a.j)):(a.j={presentationTimeline:a.i,variants:l.variants,textStreams:l.textStreams,imageStreams:[],offlineSessionIds:[],minBufferTime:0,sequenceMode:a.g.mss.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,
966
969
  type:"MSS",serviceDescription:null},a.i.Dd());Promise.resolve();g=Date.now();h=(g-d)/1E3;a.A.sample(1,h);E(k)})}
967
970
  function yu(a,b,c,d,e,f){var g=b.getAttribute("Type");if("audio"!==g&&"video"!==g&&"text"!==g)return Ta("Ignoring unrecognized type:",g),null;var h=b.getAttribute("Language"),k=a.s++,l=lg(c,"Bitrate",qg),m=lg(c,"MaxWidth",qg),n=lg(c,"MaxHeight",qg),r=lg(c,"Channels",qg),p=lg(c,"SamplingRate",qg),u=f.duration;d.length&&(u=d[d.length-1].end-d[0].start);var v=a.i.getDuration();a.i.Ka(Math.min(u,v));var x={id:k,originalId:b.getAttribute("Name")||String(k),groupId:null,createSegmentIndex:function(){return Promise.resolve()},
968
971
  closeSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:"",codecs:"",frameRate:void 0,pixelAspectRatio:void 0,bandwidth:l||0,width:m||void 0,height:n||void 0,kind:"",encrypted:0<e.length,drmInfos:e,keyIds:new Set,language:Zc(h||"und"),originalLanguage:h,label:"",type:"",primary:!1,trickModeVideo:null,emsgSchemeIdUris:[],roles:[],forced:!1,channelsCount:r,audioSamplingRate:p,spatialAudio:!1,closedCaptions:null,hdr:void 0,videoLayout:void 0,tilesLayout:void 0,matchedStreams:[],
@@ -974,8 +977,8 @@ function Bu(a,b,c,d){if(a=a.getAttribute("CodecPrivateData"))return a;if("audio"
974
977
  b<<3;b=new Uint16Array(1);b[0]=(c[0]<<8)+c[1];return b[0].toString(16)}function Cu(a,b){var c=0;"AACH"===a&&(c=5);b?0===c&&(c=(parseInt(b.substr(0,2),16)&248)>>3):(c=2,"AACH"===a&&(c=5));return"mp4a.40."+c}function Du(a){var b=/00000001[0-9]7/.exec(a);return b.length&&a?"avc1."+a.substr(a.indexOf(b[0])+10,6):""}
975
978
  function Eu(a,b,c,d,e){var f=d.getAttribute("Url").replace("{bitrate}",String(c.bandwidth));d=[];var g={};e=t(e);for(var h=e.next();!h.done;g={uc:g.uc},h=e.next())g.uc=h.value,d.push(new S(g.uc.start,g.uc.end,function(k){return function(){return wc(a.l,[f.replace("{start time}",String(k.uc.mf))])}}(g),0,null,b,0,0,c.mssPrivateData.duration));return d}N("shaka.mss.MssParser",vu);var Au="AAC AACL AACH AACP AVC1 H264 TTML DFXP".split(" "),zu={CAPT:"main",SUBT:"alternate",DESC:"main"};
976
979
  ph["application/vnd.ms-sstr+xml"]=function(){return new vu};function Fu(a,b,c,d,e,f){if(200<=c&&299>=c&&202!=c)return{uri:e||d,originalUri:d,data:b,status:c,headers:a,fromCache:!!a["x-shaka-from-cache"]};e=null;try{e=Df(b)}catch(g){}throw new O(401==c||403==c?2:1,1,1001,d,c,e,a,f);};function Gu(){}function Hu(a,b,c,d,e){var f=new Iu;wf(b.headers).forEach(function(l,m){f.append(m,l)});var g=new Ju,h={uf:!1,gg:!1};a=Ku(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 Me(a,function(){h.uf=!0;g.abort();return Promise.resolve()});if(b=b.retryParameters.timeout){var k=new id(function(){h.gg=!0;g.abort()});k.U(b/1E3);a.finally(function(){k.stop()})}return a}
977
- function Ku(a,b,c,d,e,f,g){var h,k,l,m,n,r,p,u,v,x,z,y,B;return K(function(A){switch(A.g){case 1:return h=Lu,k=Mu,r=n=0,p=Date.now(),sa(A,2),C(A,h(a,c),4);case 4:l=A.h;f(Nu(l.headers));if("HEAD"==c.method){A.B(5);break}u=l.clone().body.getReader();x=(v=l.headers.get("Content-Length"))?parseInt(v,10):0;z=function(D){function F(){var J,G;return K(function(H){switch(H.g){case 1:return sa(H,2),C(H,u.read(),4);case 4:J=H.h;va(H,3);break;case 2:return wa(H),H.return();case 3:if(J.done){H.B(5);break}n+=
978
- J.value.byteLength;if(!g){H.B(5);break}return C(H,g(J.value),5);case 5:G=Date.now();if(100<G-p||J.done)e(G-p,n-r,x-n),r=n,p=G;J.done?D.close():(D.enqueue(J.value),F());E(H)}})}F()};new k({start:z});return C(A,l.arrayBuffer(),6);case 6:m=A.h;case 5:va(A,3);break;case 2:y=wa(A);if(d.uf)throw new O(1,1,7001,a,b);if(d.gg)throw new O(1,1,1003,a,b);throw new O(1,1,1002,a,y,b);case 3:return B=Nu(l.headers),A.return(Fu(B,m,l.status,a,l.url,b))}})}
980
+ function Ku(a,b,c,d,e,f,g){var h,k,l,m,n,r,p,u,v,x,z,y,A;return K(function(B){switch(B.g){case 1:return h=Lu,k=Mu,r=n=0,p=Date.now(),sa(B,2),C(B,h(a,c),4);case 4:l=B.h;f(Nu(l.headers));if("HEAD"==c.method){B.B(5);break}u=l.clone().body.getReader();x=(v=l.headers.get("Content-Length"))?parseInt(v,10):0;z=function(D){function F(){var J,G;return K(function(H){switch(H.g){case 1:return sa(H,2),C(H,u.read(),4);case 4:J=H.h;va(H,3);break;case 2:return wa(H),H.return();case 3:if(J.done){H.B(5);break}n+=
981
+ J.value.byteLength;if(!g){H.B(5);break}return C(H,g(J.value),5);case 5:G=Date.now();if(100<G-p||J.done)e(G-p,n-r,x-n),r=n,p=G;J.done?D.close():(D.enqueue(J.value),F());E(H)}})}F()};new k({start:z});return C(B,l.arrayBuffer(),6);case 6:m=B.h;case 5:va(B,3);break;case 2:y=wa(B);if(d.uf)throw new O(1,1,7001,a,b);if(d.gg)throw new O(1,1,1003,a,b);throw new O(1,1,1002,a,y,b);case 3:return A=Nu(l.headers),B.return(Fu(A,m,l.status,a,l.url,b))}})}
979
982
  function Nu(a){var b={};a.forEach(function(c,d){b[d.trim()]=c});return b}function Ou(){if(window.ReadableStream)try{new ReadableStream({})}catch(a){return!1}else return!1;if(window.Response){if(!(new Response("")).body)return!1}else return!1;return!(!window.fetch||!window.AbortController)}N("shaka.net.HttpFetchPlugin",Gu);Gu.isSupported=Ou;Gu.parse=Hu;var Lu=window.fetch,Ju=window.AbortController,Mu=window.ReadableStream,Iu=window.Headers;
980
983
  Ou()&&(af("http",Hu,2,!0),af("https",Hu,2,!0),af("blob",Hu,2,!0));function Pu(){}
981
984
  function Qu(a,b,c,d,e){var f=new Ru,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 O(1,1,7001,a,c))};var n=!1;f.onreadystatechange=function(){if(2==f.readyState&&!n){var p=Su(f);e(p);n=!0}};f.onload=function(){var p=Su(f),u=f.response;try{var v=Fu(p,u,f.status,a,f.responseURL,c);l(v)}catch(x){m(x)}};f.onerror=function(p){m(new O(1,1,1002,a,p,
@@ -1023,22 +1026,22 @@ q.update=function(){};
1023
1026
  q.onExpirationUpdated=function(a,b){var c=this,d,e,f,g,h,k,l;return K(function(m){switch(m.g){case 1:return d=c.g,e=new ov,sa(m,2,3),C(m,e.init(),5);case 5:return C(m,sv(e,d.Ra(),d.wa()),6);case 6:return f=m.h,C(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 C(m,f.updateManifestExpiration(d.key(),b),3);case 3:return xa(m),C(m,e.destroy(),10);case 10:ya(m,0);break;case 2:wa(m),m.B(3)}})};
1024
1027
  q.onInitialVariantChosen=function(){};q.banLocation=function(){};ph["application/x-offline-manifest"]=function(){return new Pv};function Qv(){}function Rv(a){var b=Iv(a);b&&"manifest"==b.g?(a={uri:a,originalUri:a,data:new ArrayBuffer(0),headers:{"content-type":"application/x-offline-manifest"}},a=Pe(a)):a=b&&"segment"==b.g?Sv(b.key(),b):Ne(new O(2,1,9004,a));return a}
1025
1028
  function Sv(a,b){var c=new ov;return Pe(void 0).oa(function(){return c.init()}).oa(function(){return sv(c,b.Ra(),b.wa())}).oa(function(d){return d.getSegments([b.key()])}).oa(function(d){return{uri:b,data:d[0].data,headers:{}}}).finally(function(){return c.destroy()})}N("shaka.offline.OfflineScheme",Qv);Qv.plugin=Rv;af("offline",Rv);function Tv(a,b,c){var d,e,f,g,h,k;return K(function(l){switch(l.g){case 1:d=[];for(var m=[],n=t(c),r=n.next();!r.done;r=n.next()){r=r.value;for(var p=!1,u=t(m),v=u.next();!v.done;v=u.next())if(v=v.value,Uv(v.info,r)){v.sessionIds.push(r.sessionId);p=!0;break}p||m.push({info:r,sessionIds:[r.sessionId]})}e=t(m);f=e.next();case 2:if(f.done){l.B(4);break}g=f.value;h=Vv(a,b,g);return C(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)}})}
1026
- function Vv(a,b,c){var d,e;return K(function(f){switch(f.g){case 1:return d=new yg({Ob:b,onError:function(){},Kd:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),sa(f,2),d.configure(a),C(f,Gg(d,c.info.keySystem,c.info.licenseUri,c.info.serverCertificate,c.info.audioCapabilities,c.info.videoCapabilities),4);case 4:va(f,3);break;case 2:return wa(f),C(f,d.destroy(),5);case 5:return f.return([]);case 3:return sa(f,6),C(f,Rg(d),8);case 8:va(f,7);break;case 6:return wa(f),C(f,d.destroy(),
1029
+ function Vv(a,b,c){var d,e;return K(function(f){switch(f.g){case 1:return d=new yg({Nb:b,onError:function(){},Kd:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),sa(f,2),d.configure(a),C(f,Gg(d,c.info.keySystem,c.info.licenseUri,c.info.serverCertificate,c.info.audioCapabilities,c.info.videoCapabilities),4);case 4:va(f,3);break;case 2:return wa(f),C(f,d.destroy(),5);case 5:return f.return([]);case 3:return sa(f,6),C(f,Rg(d),8);case 8:va(f,7);break;case 6:return wa(f),C(f,d.destroy(),
1027
1030
  9);case 9:return f.return([]);case 7:return e=[],C(f,Promise.all(c.sessionIds.map(function(g){return K(function(h){if(1==h.g)return sa(h,2),C(h,Sg(d,g),4);if(2!=h.g)return e.push(g),va(h,0);wa(h);E(h)})})),10);case 10:return C(f,d.destroy(),11);case 11:return f.return(e)}})}
1028
1031
  function Uv(a,b){function c(d,e){return d.robustness==e.robustness&&d.contentType==e.contentType}return a.keySystem==b.keySystem&&a.licenseUri==b.licenseUri&&zb(a.audioCapabilities,b.audioCapabilities,c)&&zb(a.videoCapabilities,b.videoCapabilities,c)};function Wv(a,b,c){var d=b.presentationTimeline.getDuration();b=Xv(b);return{offlineUri:null,originalManifestUri:a,duration:d,size:0,expiration:Infinity,tracks:b,appMetadata:c,isIncomplete:!1}}function Yv(a,b){var c=Kv(new Jv(a.Ra(),a.wa()),b),d=b.appMetadata||{};c=Xv(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}}
1029
- function Xv(a){var b=[],c=be(a.variants);c=t(c);for(var d=c.next();!d.done;d=c.next())b.push(Td(d.value));a=t(a.textStreams);for(c=a.next();!c.done;c=a.next())b.push(Ud(c.value));return b};function Zv(){this.g={}}function $v(a,b){var c=b.audio,d=b.video;c&&!d&&(a.g[c.id]=c.bandwidth||b.bandwidth);!c&&d&&(a.g[d.id]=d.bandwidth||b.bandwidth);if(c&&d){var e=c.bandwidth||393216,f=d.bandwidth||b.bandwidth-e;0>=f&&(f=b.bandwidth);a.g[c.id]=e;a.g[d.id]=f}}function aw(a,b){a.g[b.id]=b.bandwidth||2048}function bw(a,b){a=a.g[b];null==a&&(a=0);return a};function cw(a){var b=this;if(a&&a.constructor!=W)throw new O(2,9,9008);this.g=this.h=null;a?(this.h=a.h,this.g=a.Ib()):(this.h=Al(),this.g=new $e);this.i=[];this.j=[];var c=!a;this.l=new mf(function(){var d,e,f,g,h;return K(function(k){switch(k.g){case 1:return C(k,Promise.all(b.j.map(function(l){return Zu(l)})),2);case 2:d=function(){};e=[];f=t(b.i);for(g=f.next();!g.done;g=f.next())h=g.value,e.push(h.then(d,d));return C(k,Promise.all(e),3);case 3:if(!c){k.B(4);break}return C(k,b.g.destroy(),4);
1030
- case 4:b.h=null,b.g=null,E(k)}})})}function dw(){if(jd())a:{var a=t(pv.values());for(var b=a.next();!b.done;b=a.next())if(b=b.value,b=b()){b.destroy();a=!0;break a}a=!1}else a=!1;return a}q=cw.prototype;q.destroy=function(){return this.l.destroy()};q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=ql(a,b));return Cl(this.h,a)};q.getConfiguration=function(){var a=Al();Cl(a,this.h,Al());return a};q.Ib=function(){return this.g};
1032
+ function Xv(a){var b=[],c=be(a.variants);c=t(c);for(var d=c.next();!d.done;d=c.next())b.push(Td(d.value));a=t(a.textStreams);for(c=a.next();!c.done;c=a.next())b.push(Ud(c.value));return b};function Zv(){this.g={}}function $v(a,b){var c=b.audio,d=b.video;c&&!d&&(a.g[c.id]=c.bandwidth||b.bandwidth);!c&&d&&(a.g[d.id]=d.bandwidth||b.bandwidth);if(c&&d){var e=c.bandwidth||393216,f=d.bandwidth||b.bandwidth-e;0>=f&&(f=b.bandwidth);a.g[c.id]=e;a.g[d.id]=f}}function aw(a,b){a.g[b.id]=b.bandwidth||2048}function bw(a,b){a=a.g[b];null==a&&(a=0);return a};function cw(a){var b=this;if(a&&a.constructor!=V)throw new O(2,9,9008);this.g=this.h=null;a?(this.h=a.h,this.g=a.Hb()):(this.h=Al(),this.g=new $e);this.i=[];this.j=[];var c=!a;this.l=new mf(function(){var d,e,f,g,h;return K(function(k){switch(k.g){case 1:return C(k,Promise.all(b.j.map(function(l){return Zu(l)})),2);case 2:d=function(){};e=[];f=t(b.i);for(g=f.next();!g.done;g=f.next())h=g.value,e.push(h.then(d,d));return C(k,Promise.all(e),3);case 3:if(!c){k.B(4);break}return C(k,b.g.destroy(),4);
1033
+ case 4:b.h=null,b.g=null,E(k)}})})}function dw(){if(jd())a:{var a=t(pv.values());for(var b=a.next();!b.done;b=a.next())if(b=b.value,b=b()){b.destroy();a=!0;break a}a=!1}else a=!1;return a}q=cw.prototype;q.destroy=function(){return this.l.destroy()};q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=ql(a,b));return Cl(this.h,a)};q.getConfiguration=function(){var a=Al();Cl(a,this.h,Al());return a};q.Hb=function(){return this.g};
1031
1034
  q.store=function(a,b,c){var d=this,e=this.getConfiguration(),f=new Yu(this.g);this.j.push(f);b=ew(this,a,b||{},function(){var g;return K(function(h){if(1==h.g)return c?h.B(2):C(h,Ak(a,d.g,e.manifest.retryParameters),3);2!=h.g&&(c=h.h);g=oh(a,c||null);return h.return(g())})},e,f);b=new Me(b,function(){return Zu(f)});b.finally(function(){yb(d.j,f)});return fw(this,b)};
1032
- function ew(a,b,c,d,e,f){var g,h,k,l,m,n,r,p,u,v,x,z,y,B;return K(function(A){switch(A.g){case 1:return gw(),h=g=null,k=new ov,n=m=l=null,sa(A,2,3),C(A,d(),5);case 5:return g=A.h,C(A,hw(a,b,g,e),6);case 6:r=A.h;iw(a);p=!r.presentationTimeline.S()&&!r.presentationTimeline.Mb();if(!p)throw new O(2,9,9005,b);return C(A,jw(a,r,function(D){n=n||D},e),7);case 7:h=A.h;iw(a);if(n)throw n;return C(A,kw(r,h,e),8);case 8:return C(A,k.init(),9);case 9:return iw(a),C(A,qv(k),10);case 10:return l=A.h,iw(a),u=lw(h,
1033
- r,b,c,e,f),v=u.kh,x=u.hf,C(A,l.wa.addManifests([v]),11);case 11:z=A.h;iw(a);m=z[0];iw(a);if(n)throw n;return C(A,mw(a,x,m,v,f,e,l.wa,r,h),12);case 12:return iw(a),y=new Hv("manifest",l.path.Ra,l.path.wa,m),A.return(Yv(y,v));case 3:return xa(A),C(A,k.destroy(),13);case 13:if(!g){A.B(14);break}return C(A,g.stop(),14);case 14:if(!h){A.B(16);break}return C(A,h.destroy(),16);case 16:ya(A,0);break;case 2:B=wa(A);if(null==m){A.B(18);break}return C(A,nw(m),18);case 18:throw n||B;}})}
1034
- function mw(a,b,c,d,e,f,g,h,k){var l,m,n,r,p,u,v,x,z,y;return K(function(B){switch(B.g){case 1:l={};m=0;n=function(A,D){var F,J,G,H,I,L,M;return K(function(P){if(1==P.g){F={};J=t(A);for(G=J.next();!G.done;F={Cb:F.Cb},G=J.next())F.Cb=G.value,H=Vu(F.Cb,f),I=F.Cb.i,L=F.Cb.h,M=function(R){return function(V){var X,fa,Ha;return K(function(Sa){if(1==Sa.g)return C(Sa,g.addSegments([{data:V}]),2);X=Sa.h;iw(a);fa=R.Cb.g;Ha=Uu(fa);l[Ha]=X[0];m+=V.byteLength;E(Sa)})}}(F),av(e,F.Cb.groupId,H,I,L,M);return C(P,
1035
- cv(e),2)}if(!D)return P.B(0);iw(a);ow(h,d,k,f);return C(P,g.updateManifest(c,d),0)})};r=!1;sa(B,2);if(!pw(h)||!r||qw(h)){B.B(4);break}return C(B,n(b.filter(function(A){return A.h}),!0),5);case 5:return iw(a),b=b.filter(function(A){return!A.h}),p=l,u=m,l={},m=0,C(B,rw(g,c,d,p,u,function(){return iw(a)}),6);case 6:iw(a);case 4:if(r){B.B(7);break}return C(B,n(b,!1),8);case 8:return iw(a),v=l,x=m,l={},m=0,C(B,rw(g,c,d,v,x,function(){return iw(a)}),9);case 9:iw(a);case 7:va(B,0);break;case 2:return z=
1036
- wa(B),y=Object.values(l),C(B,g.removeSegments(y,function(){}),10);case 10:throw z;}})}function nw(a){var b,c,d,e;return K(function(f){switch(f.g){case 1:return b=new ov,C(f,b.init(),2);case 2:return C(f,qv(b),3);case 3:return c=f.h,d=new Hv("manifest",c.path.Ra,c.path.wa,a),C(f,b.destroy(),4);case 4:return e=new cw,C(f,e.remove(d.toString()),0)}})}
1035
+ function ew(a,b,c,d,e,f){var g,h,k,l,m,n,r,p,u,v,x,z,y,A;return K(function(B){switch(B.g){case 1:return gw(),h=g=null,k=new ov,n=m=l=null,sa(B,2,3),C(B,d(),5);case 5:return g=B.h,C(B,hw(a,b,g,e),6);case 6:r=B.h;iw(a);p=!r.presentationTimeline.S()&&!r.presentationTimeline.Lb();if(!p)throw new O(2,9,9005,b);return C(B,jw(a,r,function(D){n=n||D},e),7);case 7:h=B.h;iw(a);if(n)throw n;return C(B,kw(r,h,e),8);case 8:return C(B,k.init(),9);case 9:return iw(a),C(B,qv(k),10);case 10:return l=B.h,iw(a),u=lw(h,
1036
+ r,b,c,e,f),v=u.kh,x=u.hf,C(B,l.wa.addManifests([v]),11);case 11:z=B.h;iw(a);m=z[0];iw(a);if(n)throw n;return C(B,mw(a,x,m,v,f,e,l.wa,r,h),12);case 12:return iw(a),y=new Hv("manifest",l.path.Ra,l.path.wa,m),B.return(Yv(y,v));case 3:return xa(B),C(B,k.destroy(),13);case 13:if(!g){B.B(14);break}return C(B,g.stop(),14);case 14:if(!h){B.B(16);break}return C(B,h.destroy(),16);case 16:ya(B,0);break;case 2:A=wa(B);if(null==m){B.B(18);break}return C(B,nw(m),18);case 18:throw n||A;}})}
1037
+ function mw(a,b,c,d,e,f,g,h,k){var l,m,n,r,p,u,v,x,z,y;return K(function(A){switch(A.g){case 1:l={};m=0;n=function(B,D){var F,J,G,H,I,L,M;return K(function(P){if(1==P.g){F={};J=t(B);for(G=J.next();!G.done;F={Bb:F.Bb},G=J.next())F.Bb=G.value,H=Vu(F.Bb,f),I=F.Bb.i,L=F.Bb.h,M=function(R){return function(W){var X,ia,Ha;return K(function(Sa){if(1==Sa.g)return C(Sa,g.addSegments([{data:W}]),2);X=Sa.h;iw(a);ia=R.Bb.g;Ha=Uu(ia);l[Ha]=X[0];m+=W.byteLength;E(Sa)})}}(F),av(e,F.Bb.groupId,H,I,L,M);return C(P,
1038
+ cv(e),2)}if(!D)return P.B(0);iw(a);ow(h,d,k,f);return C(P,g.updateManifest(c,d),0)})};r=!1;sa(A,2);if(!pw(h)||!r||qw(h)){A.B(4);break}return C(A,n(b.filter(function(B){return B.h}),!0),5);case 5:return iw(a),b=b.filter(function(B){return!B.h}),p=l,u=m,l={},m=0,C(A,rw(g,c,d,p,u,function(){return iw(a)}),6);case 6:iw(a);case 4:if(r){A.B(7);break}return C(A,n(b,!1),8);case 8:return iw(a),v=l,x=m,l={},m=0,C(A,rw(g,c,d,v,x,function(){return iw(a)}),9);case 9:iw(a);case 7:va(A,0);break;case 2:return z=
1039
+ wa(A),y=Object.values(l),C(A,g.removeSegments(y,function(){}),10);case 10:throw z;}})}function nw(a){var b,c,d,e;return K(function(f){switch(f.g){case 1:return b=new ov,C(f,b.init(),2);case 2:return C(f,qv(b),3);case 3:return c=f.h,d=new Hv("manifest",c.path.Ra,c.path.wa,a),C(f,b.destroy(),4);case 4:return e=new cw,C(f,e.remove(d.toString()),0)}})}
1037
1040
  function rw(a,b,c,d,e,f){var g,h,k,l,m,n,r,p,u,v,x;return K(function(z){switch(z.g){case 1:g=!1;sa(z,2);h=!0;k=t(c.streams);for(l=k.next();!l.done;l=k.next())for(m=l.value,n=t(m.segments),r=n.next();!r.done;r=n.next())p=r.value,u=p.pendingSegmentRefId?d[p.pendingSegmentRefId]:null,null!=u&&(p.dataKey=u,p.pendingSegmentRefId=void 0),u=p.pendingInitSegmentRefId?d[p.pendingInitSegmentRefId]:null,null!=u&&(p.initSegmentKey=u,p.pendingInitSegmentRefId=void 0),p.pendingSegmentRefId&&(h=!1),p.pendingInitSegmentRefId&&
1038
1041
  (h=!1);c.size+=e;h&&(c.isIncomplete=!1);return C(z,a.updateManifest(b,c),4);case 4:g=!0;f();va(z,0);break;case 2:return v=wa(z),C(z,nw(b),5);case 5:if(g){z.B(6);break}x=Object.values(d);return C(z,a.removeSegments(x,function(){}),6);case 6:throw v;}})}
1039
- function kw(a,b,c){var d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,B,A,D,F,J,G,H,I,L,M,P,R;return K(function(V){switch(V.g){case 1:return d={width:Infinity,height:Infinity},Cd(a,c.restrictions,d),C(V,Fd(b,a,c.offline.usePersistentLicense),2);case 2:e=[];f=c.preferredDecodingAttributes;g=c.preferredVideoCodecs;h=c.preferredAudioCodecs;Ad(a,g,h,f);k=t(a.variants);for(l=k.next();!l.done;l=k.next())m=l.value,e.push(Td(m));n=t(a.textStreams);for(r=n.next();!r.done;r=n.next())p=r.value,e.push(Ud(p));u=t(a.imageStreams);
1040
- for(v=u.next();!v.done;v=u.next())x=v.value,e.push(Vd(x));return C(V,c.offline.trackSelectionCallback(e),3);case 3:z=V.h;y=a.presentationTimeline.getDuration();B=0;A=t(z);for(D=A.next();!D.done;D=A.next())F=D.value,J=F.bandwidth*y/8,B+=J;sa(V,4);return C(V,c.offline.downloadSizeCallback(B),6);case 6:G=V.h;if(!G)throw new O(2,9,9014);va(V,5);break;case 4:H=wa(V);if(H instanceof O)throw H;throw new O(2,9,9015);case 5:I=new Set;L=new Set;M=new Set;P=t(z);for(D=P.next();!D.done;D=P.next())R=D.value,"variant"==
1041
- R.type&&I.add(R.id),"text"==R.type&&L.add(R.id),"image"==R.type&&M.add(R.id);a.variants=a.variants.filter(function(X){return I.has(X.id)});a.textStreams=a.textStreams.filter(function(X){return L.has(X.id)});a.imageStreams=a.imageStreams.filter(function(X){return M.has(X.id)});sw(a);E(V)}})}
1042
+ function kw(a,b,c){var d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,A,B,D,F,J,G,H,I,L,M,P,R;return K(function(W){switch(W.g){case 1:return d={width:Infinity,height:Infinity},Cd(a,c.restrictions,d),C(W,Fd(b,a,c.offline.usePersistentLicense),2);case 2:e=[];f=c.preferredDecodingAttributes;g=c.preferredVideoCodecs;h=c.preferredAudioCodecs;Ad(a,g,h,f);k=t(a.variants);for(l=k.next();!l.done;l=k.next())m=l.value,e.push(Td(m));n=t(a.textStreams);for(r=n.next();!r.done;r=n.next())p=r.value,e.push(Ud(p));u=t(a.imageStreams);
1043
+ for(v=u.next();!v.done;v=u.next())x=v.value,e.push(Vd(x));return C(W,c.offline.trackSelectionCallback(e),3);case 3:z=W.h;y=a.presentationTimeline.getDuration();A=0;B=t(z);for(D=B.next();!D.done;D=B.next())F=D.value,J=F.bandwidth*y/8,A+=J;sa(W,4);return C(W,c.offline.downloadSizeCallback(A),6);case 6:G=W.h;if(!G)throw new O(2,9,9014);va(W,5);break;case 4:H=wa(W);if(H instanceof O)throw H;throw new O(2,9,9015);case 5:I=new Set;L=new Set;M=new Set;P=t(z);for(D=P.next();!D.done;D=P.next())R=D.value,"variant"==
1044
+ R.type&&I.add(R.id),"text"==R.type&&L.add(R.id),"image"==R.type&&M.add(R.id);a.variants=a.variants.filter(function(X){return I.has(X.id)});a.textStreams=a.textStreams.filter(function(X){return L.has(X.id)});a.imageStreams=a.imageStreams.filter(function(X){return M.has(X.id)});sw(a);E(W)}})}
1042
1045
  function lw(a,b,c,d,e,f){var g=Wv(c,b,d),h=e.offline.progressCallback;$u(f,function(p,u){g.size=u;h(g,p)},function(p,u){k&&e.offline.usePersistentLicense&&l==u&&Og(a,"cenc",p)});var k=pw(b)&&!qw(b),l=null;k&&(l=tw.get(a.g.keySystem));for(var m=new Zv,n=t(b.textStreams),r=n.next();!r.done;r=n.next())m.g[r.value.id]=52;n=t(b.imageStreams);for(r=n.next();!r.done;r=n.next())aw(m,r.value);r=t(b.variants);for(n=r.next();!n.done;n=r.next())$v(m,n.value);m=uw(f,m,b,e);f=m.streams;m=m.hf;r=a.g;n=e.offline.usePersistentLicense;
1043
1046
  r&&n&&(r.initData=[]);return{kh:{creationTime:Date.now(),originalManifestUri:c,duration:b.presentationTimeline.getDuration(),size:0,expiration:a.Kc(),streams:f,sessionIds:n?Yg(a):[],drmInfo:r,appMetadata:d,isIncomplete:!0,sequenceMode:b.sequenceMode,type:b.type},hf:m}}function pw(a){return a.variants.some(function(b){var c=b.audio&&b.audio.encrypted;return b.video&&b.video.encrypted||c})}
1044
1047
  function qw(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 ow(a,b,c,d){b.expiration=c.Kc();c=Yg(c);b.sessionIds=d.offline.usePersistentLicense?c:[];if(pw(a)&&d.offline.usePersistentLicense&&!c.length)throw new O(2,9,9007);}q.remove=function(a){return vw(this,ww(this,a))};
@@ -1048,7 +1051,7 @@ function yw(a,b,c){function d(){}var e=Bw(c);Yv(b,c);return Promise.all([a.remov
1048
1051
  function Cw(a){var b,c,d,e,f,g,h,k,l,m;return K(function(n){switch(n.g){case 1:return gw(),b=a.g,c=a.h.drm,d=new ov,e=!1,ta(n,2),C(n,d.init(),4);case 4:f=[],tv(d,function(r){return f.push(r)}),g=t(f),h=g.next();case 5:if(h.done){n.B(2);break}k=h.value;return C(n,k.getAll(),8);case 8:return l=n.h,C(n,Tv(c,b,l),9);case 9:return m=n.h,C(n,k.remove(m),10);case 10:m.length!=l.length&&(e=!0);h=g.next();n.B(5);break;case 2:return xa(n),C(n,d.destroy(),11);case 11:ya(n,3);break;case 3:return n.return(!e)}})}
1049
1052
  q.list=function(){return vw(this,Dw())};function Dw(){var a,b,c;return K(function(d){switch(d.g){case 1:return gw(),a=[],b=new ov,ta(d,2),C(d,b.init(),4);case 4:return c=Promise.resolve(),rv(b,function(e,f){c=c.then(function(){var g;return K(function(h){if(1==h.g)return C(h,f.getAllManifests(),2);g=h.h;g.forEach(function(k,l){k=Yv(new Hv("manifest",e.Ra,e.wa,l),k);a.push(k)});E(h)})})}),C(d,c,2);case 2:return xa(d),C(d,b.destroy(),6);case 6:ya(d,3);break;case 3:return d.return(a)}})}
1050
1053
  function hw(a,b,c,d){var e,f,g,h,k;return K(function(l){if(1==l.g)return e=null,f=a.g,g={networkingEngine:f,filter:function(){return Promise.resolve()},makeTextStreamsForClosedCaptions:function(){},onTimelineRegionAdded:function(){},onEvent:function(){},onError:function(m){e=m},isLowLatencyMode:function(){return!1},isAutoLowLatencyMode:function(){return!1},enableLowLatencyMode:function(){},updateDuration:function(){},newDrmInfo:function(){},onManifestUpdated:function(){},getBandwidthEstimate:function(){return d.abr.defaultBandwidthEstimate}},
1051
- c.configure(d.manifest),iw(a),C(l,c.start(b,g),2);if(3!=l.g)return h=l.h,iw(a),k=Ew(h),C(l,Promise.all(tf(k,function(m){return m.createSegmentIndex()})),3);iw(a);if(e)throw e;return l.return(h)})}function jw(a,b,c,d){var e;return K(function(f){return 1==f.g?(e=new yg({Ob:a.g,onError:c,Kd:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),e.configure(d.drm),C(f,Dg(e,b.variants,d.offline.usePersistentLicense),2)):3!=f.g?C(f,Qg(e),3):f.return(e)})}
1054
+ c.configure(d.manifest),iw(a),C(l,c.start(b,g),2);if(3!=l.g)return h=l.h,iw(a),k=Ew(h),C(l,Promise.all(tf(k,function(m){return m.createSegmentIndex()})),3);iw(a);if(e)throw e;return l.return(h)})}function jw(a,b,c,d){var e;return K(function(f){return 1==f.g?(e=new yg({Nb:a.g,onError:c,Kd:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),e.configure(d.drm),C(f,Dg(e,b.variants,d.offline.usePersistentLicense),2)):3!=f.g?C(f,Qg(e),3):f.return(e)})}
1052
1055
  function uw(a,b,c,d){var e=new Map,f=Ew(c),g=new Map;f=t(f);for(var h=f.next();!h.done;h=f.next()){h=h.value;var k=Fw(a,b,c,h,d,e);g.set(h.id,k)}a=t(c.variants);for(b=a.next();!b.done;b=a.next())b=b.value,b.audio&&g.get(b.audio.id).variantIds.push(b.id),b.video&&g.get(b.video.id).variantIds.push(b.id);return{streams:Array.from(g.values()),hf:Array.from(e.values())}}
1053
1056
  function Fw(a,b,c,d,e,f){var g={id:d.id,originalId:d.originalId,groupId:d.groupId,primary:d.primary,type:d.type,mimeType:d.mimeType,codecs:d.codecs,frameRate:d.frameRate,pixelAspectRatio:d.pixelAspectRatio,hdr:d.hdr,videoLayout:d.videoLayout,kind:d.kind,language:d.language,originalLanguage:d.originalLanguage,label:d.label,width:d.width||null,height:d.height||null,encrypted:d.encrypted,keyIds:d.keyIds,segments:[],variantIds:[],roles:d.roles,forced:d.forced,channelsCount:d.channelsCount,audioSamplingRate:d.audioSamplingRate,
1054
1057
  spatialAudio:d.spatialAudio,closedCaptions:d.closedCaptions,tilesLayout:d.tilesLayout,external:d.external,fastSwitching:d.fastSwitching},h=e.offline.numberOfParallelDownloads,k=0;Gw(d,c.presentationTimeline.ib(),function(l){var m=Uu(l),n=void 0;if(!f.has(m)){var r=l.endTime-l.startTime;r=bw(b,d.id)*r;r=Xu(a.g,r);f.set(m,new Tu(l,r,k,!1))}l.g&&(n=Uu(l.g),f.has(n)||(r=.5*bw(b,d.id),r=Xu(a.g,r),f.set(n,new Tu(l.g,r,k,!0))));g.segments.push({pendingInitSegmentRefId:n,initSegmentKey:n?0:null,startTime:l.startTime,
@@ -1057,17 +1060,17 @@ function vw(a,b){return K(function(c){if(1==c.g)return a.i.push(b),ta(c,2),C(c,b
1057
1060
  function Aw(a,b,c,d){var e,f,g;return K(function(h){if(1==h.g){if(!d.drmInfo)return h.return();e=uv(c);f=d.sessionIds.map(function(k){return{sessionId:k,keySystem:d.drmInfo.keySystem,licenseUri:d.drmInfo.licenseServerUri,serverCertificate:d.drmInfo.serverCertificate,audioCapabilities:zw(d,!1),videoCapabilities:zw(d,!0)}});return C(h,Tv(b,a,f),2)}return 3!=h.g?(g=h.h,C(h,e.remove(g),3)):C(h,e.add(f.filter(function(k){return!g.includes(k.sessionId)})),0)})}
1058
1061
  function Ew(a){for(var b=new Set,c=t(a.textStreams),d=c.next();!d.done;d=c.next())b.add(d.value);c=t(a.imageStreams);for(d=c.next();!d.done;d=c.next())b.add(d.value);a=t(a.variants);for(c=a.next();!c.done;c=a.next())c=c.value,c.audio&&b.add(c.audio),c.video&&b.add(c.video);return b}
1059
1062
  function sw(a){a.variants.map(function(f){return f.video});var b=new Set(a.variants.map(function(f){return f.audio}));a=a.textStreams;for(var c=t(b),d=c.next();!d.done;d=c.next()){d=t(b);for(var e=d.next();!e.done;e=d.next());}b=t(a);for(c=b.next();!c.done;c=b.next())for(c=t(a),d=c.next();!d.done;d=c.next());}N("shaka.offline.Storage",cw);cw.deleteAll=function(){var a;return K(function(b){return 1==b.g?(a=new ov,ta(b,2),C(b,vv(a),2)):5!=b.g?(xa(b),C(b,a.destroy(),5)):ya(b,0)})};
1060
- cw.prototype.list=cw.prototype.list;cw.prototype.removeEmeSessions=cw.prototype.yh;cw.prototype.remove=cw.prototype.remove;cw.prototype.store=cw.prototype.store;cw.prototype.getNetworkingEngine=cw.prototype.Ib;cw.prototype.getConfiguration=cw.prototype.getConfiguration;cw.prototype.configure=cw.prototype.configure;cw.prototype.destroy=cw.prototype.destroy;cw.support=dw;
1063
+ cw.prototype.list=cw.prototype.list;cw.prototype.removeEmeSessions=cw.prototype.yh;cw.prototype.remove=cw.prototype.remove;cw.prototype.store=cw.prototype.store;cw.prototype.getNetworkingEngine=cw.prototype.Hb;cw.prototype.getConfiguration=cw.prototype.getConfiguration;cw.prototype.configure=cw.prototype.configure;cw.prototype.destroy=cw.prototype.destroy;cw.support=dw;
1061
1064
  var tw=(new Map).set("org.w3.clearkey","1077efecc0b24d02ace33c1e52e2fb4b").set("com.widevine.alpha","edef8ba979d64acea3c827dcd51d21ed").set("com.microsoft.playready","9a04f07998404286ab92e65be0885f95").set("com.microsoft.playready.recommendation","9a04f07998404286ab92e65be0885f95").set("com.microsoft.playready.software","9a04f07998404286ab92e65be0885f95").set("com.microsoft.playready.hardware","9a04f07998404286ab92e65be0885f95").set("com.adobe.primetime","f239e769efa348509c16a903c6932efb");
1062
1065
  jn.offline=dw;function Hw(){}function Iw(a,b){a={priority:b||0,rg:a};for(b=0;b<Jw.length;b++)if(Jw[b].priority<a.priority){Jw.splice(b,0,a);return}Jw.push(a)}N("shaka.polyfill",Hw);Hw.register=Iw;Hw.installAll=function(){for(var a=t(Jw),b=a.next();!b.done;b=a.next()){b=b.value;try{b.rg()}catch(c){Ta("Error installing polyfill!",c)}}};var Jw=[];function Kw(){this.g=new Lw}function Mw(){window.AbortController||(window.AbortController=Kw,window.AbortSignal=Lw)}Kw.prototype.abort=function(a){var b=this.g;if(!b.h){b.h=!0;b.g=a;void 0===b.g&&(b.g=new DOMException("signal is aborted without reason","AbortError"));a=new Q("abort");if(b.onabort)b.onabort(a);b.dispatchEvent(a)}};da.Object.defineProperties(Kw.prototype,{signal:{configurable:!0,enumerable:!0,get:function(){return this.g}}});Hw.AbortController=Kw;Kw.install=Mw;
1063
1066
  function Lw(){Ve.call(this);this.h=!1;this.g=void 0;this.onabort=null}oa(Lw,Ve);da.Object.defineProperties(Lw.prototype,{aborted:{configurable:!0,enumerable:!0,get:function(){return this.h}},reason:{configurable:!0,enumerable:!0,get:function(){return this.g}}});Iw(Mw);function Nw(){}function Ow(){if(!Object.getOwnPropertyDescriptor(Element.prototype,"ariaHidden"))for(var a=t(["ariaHidden","ariaLabel","ariaPressed","ariaSelected"]),b=a.next();!b.done;b=a.next())Pw(b.value)}function Pw(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)}})}Hw.Aria=Nw;Nw.install=Ow;Iw(Ow);function Qw(){}function Rw(){Sw()}Hw.EncryptionScheme=Qw;Qw.install=Rw;Iw(Rw,-2);function Tw(){}
1064
1067
  function Uw(){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}}),
1065
1068
  Object.defineProperty(document,"fullscreenEnabled",{get:function(){return document.mozFullScreenEnabled||document.msFullscreenEnabled||document.webkitFullscreenEnabled}}));document.addEventListener("webkitfullscreenchange",Vw);document.addEventListener("webkitfullscreenerror",Vw);document.addEventListener("mozfullscreenchange",Vw);document.addEventListener("mozfullscreenerror",Vw);document.addEventListener("MSFullscreenChange",Vw);document.addEventListener("MSFullscreenError",Vw)}}
1066
1069
  function Vw(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)}Hw.Fullscreen=Tw;Tw.install=Uw;Iw(Uw);function Ww(){}function Xw(){var a=!0;if(td()||od("PlayStation 5")||ud()||od("Web0S")||pd()||od("CrKey")||od("PC=EOS")||od("Hisense")||od("VIDAA"))a=!1;a&&navigator.mediaCapabilities||(navigator.mediaCapabilities||(navigator.mediaCapabilities={}),Yw=navigator.mediaCapabilities,navigator.mediaCapabilities.decodingInfo=Zw)}
1067
- function Zw(a){var b,c,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,B;return K(function(A){switch(A.g){case 1:b={supported:!1,powerEfficient:!0,smooth:!0,keySystemAccess:null,configuration:a};if(!a)return A.return(b);c=a.video;d=a.audio;if("media-source"==a.type){if(!jd())return A.return(b);if(c){if(od("CrKey"))if(window.cast&&cast.__platform__&&cast.__platform__.canDisplayType){var D=c.contentType;c.width&&c.height&&(D+="; width="+c.width+"; height="+c.height);c.framerate&&(D+="; framerate="+c.framerate);"pq"===
1068
- c.transferFunction&&(D+="; eotf=smpte2084");e=cast.__platform__.canDisplayType(D)}else e=bb(c.contentType);else pd()?(f=c.contentType,c.width&&c.height&&(f+="; width="+c.width,f+="; height="+c.height),c.framerate&&(f+="; framerate="+c.framerate),c.bitrate&&(f+="; bitrate="+c.bitrate),e=bb(f)):e=bb(c.contentType);if(!e)return A.return(b)}if(d&&(g=d.contentType,h=bb(g),!h))return A.return(b)}else if("file"==a.type){if(c&&(k=c.contentType,l=kd(k),!l)||d&&(m=d.contentType,n=kd(m),!n))return A.return(b)}else return A.return(b);
1069
- if(!a.keySystemConfiguration)return b.supported=!0,A.return(Promise.resolve(b));r=a.keySystemConfiguration;p=[];u=[];r.audio&&(v={robustness:r.audio.robustness||"",contentType:a.audio.contentType},p.push(v));r.video&&(x={robustness:r.video.robustness||"",contentType:a.video.contentType},u.push(x));z={initDataTypes:[r.initDataType],distinctiveIdentifier:r.distinctiveIdentifier,persistentState:r.persistentState,sessionTypes:r.sessionTypes};p.length&&(z.audioCapabilities=p);u.length&&(z.videoCapabilities=
1070
- u);y=(a.video?a.video.contentType:"")+"#"+(a.audio?a.audio.contentType:"")+"#"+a.keySystemConfiguration.keySystem;sa(A,3);if(y in $w){B=$w[y];A.B(5);break}return C(A,navigator.requestMediaKeySystemAccess(r.keySystem,[z]),6);case 6:B=A.h,$w[y]=B;case 5:va(A,4);break;case 3:wa(A);case 4:B&&(b.supported=!0,b.keySystemAccess=B);case 2:return A.return(b)}})}Hw.MediaCapabilities=Ww;Ww.install=Xw;var Yw=null;Ww.originalMcap=Yw;var $w={};Ww.memoizedMediaKeySystemAccessRequests_=$w;Iw(Xw,-1);function ax(){}function bx(){var a=vd();window.MediaSource&&(window.cast&&cast.__platform__&&cast.__platform__.canDisplayType?cx():a?10>=a?window.MediaSource=null:12>=a?(dx(),ex()):15>=a&&dx():md()?fx():(rd()||qd()||od("Tizen 4"))&&gx());window.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&hx()}
1070
+ function Zw(a){var b,c,d,e,f,g,h,k,l,m,n,r,p,u,v,x,z,y,A;return K(function(B){switch(B.g){case 1:b={supported:!1,powerEfficient:!0,smooth:!0,keySystemAccess:null,configuration:a};if(!a)return B.return(b);c=a.video;d=a.audio;if("media-source"==a.type){if(!jd())return B.return(b);if(c){if(od("CrKey"))if(window.cast&&cast.__platform__&&cast.__platform__.canDisplayType){var D=c.contentType;c.width&&c.height&&(D+="; width="+c.width+"; height="+c.height);c.framerate&&(D+="; framerate="+c.framerate);"pq"===
1071
+ c.transferFunction&&(D+="; eotf=smpte2084");e=cast.__platform__.canDisplayType(D)}else e=bb(c.contentType);else pd()?(f=c.contentType,c.width&&c.height&&(f+="; width="+c.width,f+="; height="+c.height),c.framerate&&(f+="; framerate="+c.framerate),c.bitrate&&(f+="; bitrate="+c.bitrate),e=bb(f)):e=bb(c.contentType);if(!e)return B.return(b)}if(d&&(g=d.contentType,h=bb(g),!h))return B.return(b)}else if("file"==a.type){if(c&&(k=c.contentType,l=kd(k),!l)||d&&(m=d.contentType,n=kd(m),!n))return B.return(b)}else return B.return(b);
1072
+ if(!a.keySystemConfiguration)return b.supported=!0,B.return(Promise.resolve(b));r=a.keySystemConfiguration;p=[];u=[];r.audio&&(v={robustness:r.audio.robustness||"",contentType:a.audio.contentType},p.push(v));r.video&&(x={robustness:r.video.robustness||"",contentType:a.video.contentType},u.push(x));z={initDataTypes:[r.initDataType],distinctiveIdentifier:r.distinctiveIdentifier,persistentState:r.persistentState,sessionTypes:r.sessionTypes};p.length&&(z.audioCapabilities=p);u.length&&(z.videoCapabilities=
1073
+ u);y=(a.video?a.video.contentType:"")+"#"+(a.audio?a.audio.contentType:"")+"#"+a.keySystemConfiguration.keySystem;sa(B,3);if(y in $w){A=$w[y];B.B(5);break}return C(B,navigator.requestMediaKeySystemAccess(r.keySystem,[z]),6);case 6:A=B.h,$w[y]=A;case 5:va(B,4);break;case 3:wa(B);case 4:A&&(b.supported=!0,b.keySystemAccess=A);case 2:return B.return(b)}})}Hw.MediaCapabilities=Ww;Ww.install=Xw;var Yw=null;Ww.originalMcap=Yw;var $w={};Ww.memoizedMediaKeySystemAccessRequests_=$w;Iw(Xw,-1);function ax(){}function bx(){var a=vd();window.MediaSource&&(window.cast&&cast.__platform__&&cast.__platform__.canDisplayType?cx():a?10>=a?window.MediaSource=null:12>=a?(dx(),ex()):15>=a&&dx():md()?fx():(rd()||qd()||od("Tizen 4"))&&gx());window.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&hx()}
1071
1074
  function dx(){var a=MediaSource.prototype.addSourceBuffer;MediaSource.prototype.addSourceBuffer=function(){var b=a.apply(this,Fa.apply(0,arguments));b.abort=function(){};return b}}function ex(){var a=SourceBuffer.prototype.remove;SourceBuffer.prototype.remove=function(b,c){return a.call(this,b,c-.001)}}function fx(){var a=MediaSource.isTypeSupported;MediaSource.isTypeSupported=function(b){return"mp2t"!=b.split(";")[0].split("/")[1]&&a(b)}}
1072
1075
  function gx(){var a=MediaSource.isTypeSupported;MediaSource.isTypeSupported=function(b){return"opus"!=Jc(b)[0]&&a(b)}}function cx(){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)}}
1073
1076
  function hx(){var a=MediaSource.isTypeSupported;od("Web0S")||(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)})}Hw.MediaSource=ax;ax.install=bx;Iw(bx);function ix(){}function jx(){screen.orientation&&screen.orientation.unlock||(void 0!=screen.orientation?kx():void 0!=window.orientation&&lx())}function kx(){void 0===screen.orientation.lock&&(screen.orientation.lock=function(){return Promise.resolve()});void 0===screen.orientation.unlock&&(screen.orientation.unlock=function(){})}
@@ -1082,10 +1085,10 @@ function vx(a,b){this.keySystem=a;if(a.startsWith("com.apple.fps"))for(a=t(b),b=
1082
1085
  g.contentType.split(";")[0])&&(b.audioCapabilities.push(g),e=!0));if(c.videoCapabilities)for(c=t(c.videoCapabilities),g=c.next();!g.done;g=c.next())f=g.value,f.contentType&&(d=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,f.contentType.split(";")[0])&&(b.videoCapabilities.push(f),e=!0));d||(e=WebKitMediaKeys.isTypeSupported(this.keySystem,"video/mp4"));b=e?b:null}if(b){this.g=b;return}}a=Error("Unsupported keySystem");a.name="NotSupportedError";a.code=DOMException.NOT_SUPPORTED_ERR;throw a;}
1083
1086
  vx.prototype.createMediaKeys=function(){var a=new zx(this.keySystem);return Promise.resolve(a)};vx.prototype.getConfiguration=function(){return this.g};function zx(a){this.h=new WebKitMediaKeys(a);this.g=new of}zx.prototype.createSession=function(a){a=a||"temporary";if("temporary"!=a)throw new TypeError("Session type "+a+" is unsupported on this platform.");return new Ax(this.h,a)};zx.prototype.setServerCertificate=function(){return Promise.resolve(!1)};
1084
1087
  function xx(a,b){a.g.zb();if(!b)return Promise.resolve();a.g.D(b,"webkitneedkey",yx);try{return fj(b,HTMLMediaElement.HAVE_METADATA,a.g,function(){b.webkitSetMediaKeys(a.h)}),Promise.resolve()}catch(c){return Promise.reject(c)}}zx.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function Ax(a){Ve.call(this);this.i=null;this.l=a;this.g=this.h=null;this.j=new of;this.sessionId="";this.expiration=NaN;this.closed=new Le;this.keyStatuses=new Bx}oa(Ax,Ve);q=Ax.prototype;
1085
- q.generateRequest=function(a,b){var c=this;this.h=new Le;try{var d=this.l.createSession("video/mp4",mb(b));this.i=d;this.sessionId=d.sessionId||"";this.j.D(this.i,"webkitkeymessage",function(e){c.h&&(c.h.resolve(),c.h=null);e=(new Map).set("messageType",void 0==c.keyStatuses.Kb()?"license-request":"license-renewal").set("message",nb(e.message));e=new Q("message",e);c.dispatchEvent(e)});this.j.D(d,"webkitkeyadded",function(){c.g&&(Cx(c,"usable"),c.g.resolve(),c.g=null)});this.j.D(d,"webkitkeyerror",
1088
+ q.generateRequest=function(a,b){var c=this;this.h=new Le;try{var d=this.l.createSession("video/mp4",mb(b));this.i=d;this.sessionId=d.sessionId||"";this.j.D(this.i,"webkitkeymessage",function(e){c.h&&(c.h.resolve(),c.h=null);e=(new Map).set("messageType",void 0==c.keyStatuses.Jb()?"license-request":"license-renewal").set("message",nb(e.message));e=new Q("message",e);c.dispatchEvent(e)});this.j.D(d,"webkitkeyadded",function(){c.g&&(Cx(c,"usable"),c.g.resolve(),c.g=null)});this.j.D(d,"webkitkeyerror",
1086
1089
  function(){var e=Error("EME PatchedMediaKeysApple key error");e.errorCode=c.i.error;if(null!=c.h)c.h.reject(e),c.h=null;else if(null!=c.g)c.g.reject(e),c.g=null;else switch(c.i.error.code){case WebKitMediaKeyError.MEDIA_KEYERR_OUTPUT:case WebKitMediaKeyError.MEDIA_KEYERR_HARDWARECHANGE:Cx(c,"output-not-allowed");break;default:Cx(c,"internal-error")}});Cx(this,"status-pending")}catch(e){this.h.reject(e)}return this.h};q.load=function(){return Promise.reject(Error("MediaKeySession.load not yet supported"))};
1087
1090
  q.update=function(a){this.g=new Le;try{this.i.update(mb(a))}catch(b){this.g.reject(b)}return this.g};q.close=function(){try{this.i.close(),this.closed.resolve(),this.j.zb()}catch(a){this.closed.reject(a)}return this.closed};q.remove=function(){return Promise.reject(Error("MediaKeySession.remove is only applicable for persistent licenses, which are not supported on this platform"))};function Cx(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new Q("keystatuseschange");a.dispatchEvent(b)}
1088
- function Bx(){this.size=0;this.g=void 0}q=Bx.prototype;q.Kb=function(){return this.g};q.forEach=function(a){this.g&&a(this.g,mh.value())};q.get=function(a){if(this.has(a))return this.g};q.has=function(a){var b=mh.value();return this.g&&kb(a,b)?!0:!1};q.entries=function(){};q.keys=function(){};q.values=function(){};function Dx(){}function Ex(){!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=Fx,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=Gx,window.MediaKeys=Hx,window.MediaKeySystemAccess=Ix,window.shakaMediaKeysPolyfill=!0)}function Fx(){return Promise.reject(Error("The key system specified is not supported."))}
1091
+ function Bx(){this.size=0;this.g=void 0}q=Bx.prototype;q.Jb=function(){return this.g};q.forEach=function(a){this.g&&a(this.g,mh.value())};q.get=function(a){if(this.has(a))return this.g};q.has=function(a){var b=mh.value();return this.g&&kb(a,b)?!0:!1};q.entries=function(){};q.keys=function(){};q.values=function(){};function Dx(){}function Ex(){!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=Fx,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=Gx,window.MediaKeys=Hx,window.MediaKeySystemAccess=Ix,window.shakaMediaKeysPolyfill=!0)}function Fx(){return Promise.reject(Error("The key system specified is not supported."))}
1089
1092
  function Gx(a){return null==a?Promise.resolve():Promise.reject(Error("MediaKeys not supported."))}Hw.PatchedMediaKeysNop=Dx;Dx.install=Ex;function Hx(){throw new TypeError("Illegal constructor.");}Hx.prototype.createSession=function(){};Hx.prototype.setServerCertificate=function(){};Hx.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function Ix(){this.keySystem="";throw new TypeError("Illegal constructor.");}Ix.prototype.getConfiguration=function(){};
1090
1093
  Ix.prototype.createMediaKeys=function(){};Iw(Ex,-10);function Jx(){}
1091
1094
  function Kx(){if(!(!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration)){if(HTMLMediaElement.prototype.webkitGenerateKeyRequest)Lx="webkit";else if(!HTMLMediaElement.prototype.generateKeyRequest)return;navigator.requestMediaKeySystemAccess=Mx;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=Nx;window.MediaKeys=Ox;window.MediaKeySystemAccess=Px;window.shakaMediaKeysPolyfill=!0}}
@@ -1093,27 +1096,27 @@ function Qx(a){var b=Lx;return b?b+a.charAt(0).toUpperCase()+a.slice(1):a}functi
1093
1096
  function Px(a,b){this.g=this.keySystem=a;var c=!1;"org.w3.clearkey"==a&&(this.g="webkit-org.w3.clearkey",c=!1);var d=!1;var e=document.getElementsByTagName("video");e=e.length?e[0]:document.createElement("video");b=t(b);for(var f=b.next();!f.done;f=b.next()){f=f.value;var g={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:f.initDataTypes,sessionTypes:["temporary"],label:f.label},h=!1;if(f.audioCapabilities)for(var k=t(f.audioCapabilities),
1094
1097
  l=k.next();!l.done;l=k.next())l=l.value,l.contentType&&(h=!0,e.canPlayType(l.contentType.split(";")[0],this.g)&&(g.audioCapabilities.push(l),d=!0));if(f.videoCapabilities)for(k=t(f.videoCapabilities),l=k.next();!l.done;l=k.next())l=l.value,l.contentType&&(h=!0,e.canPlayType(l.contentType,this.g)&&(g.videoCapabilities.push(l),d=!0));h||(d=e.canPlayType("video/mp4",this.g)||e.canPlayType("video/webm",this.g));"required"==f.persistentState&&(c?(g.persistentState="required",g.sessionTypes=["persistent-license"]):
1095
1098
  d=!1);if(d){this.h=g;return}}c="Unsupported keySystem";if("org.w3.clearkey"==a||"com.widevine.alpha"==a)c="None of the requested configurations were supported.";a=Error(c);a.name="NotSupportedError";a.code=DOMException.NOT_SUPPORTED_ERR;throw a;}Px.prototype.createMediaKeys=function(){var a=new Ox(this.g);return Promise.resolve(a)};Px.prototype.getConfiguration=function(){return this.h};function Ox(a){this.l=a;this.h=null;this.g=new of;this.i=[];this.j=new Map}
1096
- function Rx(a,b){a.h=b;a.g.zb();var c=Lx;b&&(a.g.D(b,c+"needkey",function(d){var e=new CustomEvent("encrypted");e.initDataType="cenc";e.initData=nb(d.initData);a.h.dispatchEvent(e)}),a.g.D(b,c+"keymessage",function(d){var e=Sx(a,d.sessionId);e&&(d=(new Map).set("messageType",void 0==e.keyStatuses.Kb()?"licenserequest":"licenserenewal").set("message",d.message),d=new Q("message",d),e.h&&(e.h.resolve(),e.h=null),e.dispatchEvent(d))}),a.g.D(b,c+"keyadded",function(d){if(d=Sx(a,d.sessionId))Tx(d,"usable"),
1099
+ function Rx(a,b){a.h=b;a.g.zb();var c=Lx;b&&(a.g.D(b,c+"needkey",function(d){var e=new CustomEvent("encrypted");e.initDataType="cenc";e.initData=nb(d.initData);a.h.dispatchEvent(e)}),a.g.D(b,c+"keymessage",function(d){var e=Sx(a,d.sessionId);e&&(d=(new Map).set("messageType",void 0==e.keyStatuses.Jb()?"licenserequest":"licenserenewal").set("message",d.message),d=new Q("message",d),e.h&&(e.h.resolve(),e.h=null),e.dispatchEvent(d))}),a.g.D(b,c+"keyadded",function(d){if(d=Sx(a,d.sessionId))Tx(d,"usable"),
1097
1100
  d.g&&d.g.resolve(),d.g=null}),a.g.D(b,c+"keyerror",function(d){var e=Sx(a,d.sessionId);if(e){var f=Error("EME v0.1b key error"),g=d.errorCode;g.systemCode=d.systemCode;f.errorCode=g;!d.sessionId&&e.h?(45==d.systemCode&&(f.message="Unsupported session type."),e.h.reject(f),e.h=null):d.sessionId&&e.g?(e.g.reject(f),e.g=null):(f=d.systemCode,d.errorCode.code==MediaKeyError.MEDIA_KEYERR_OUTPUT?Tx(e,"output-restricted"):1==f?Tx(e,"expired"):Tx(e,"internal-error"))}}))}
1098
1101
  Ox.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 Ux(b,this.l,a);this.i.push(a);return a};Ox.prototype.setServerCertificate=function(){return Promise.resolve(!1)};Ox.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};
1099
1102
  function Sx(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 Ux(a,b,c){Ve.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 Le;this.keyStatuses=new Vx}oa(Ux,Ve);
1100
1103
  function Wx(a,b,c){if(a.m)return Promise.reject(Error("The session is already initialized."));a.m=!0;try{if("persistent-license"==a.l)if(c)var d=mb(Ef("LOAD_SESSION|"+c));else{var e=Ef("PERSISTENT|");d=$f(e,b)}else d=mb(b)}catch(g){return Promise.reject(g)}a.h=new Le;var f=Qx("generateKeyRequest");try{a.j[f](a.i,d)}catch(g){if("InvalidStateError"!=g.name)return a.h=null,Promise.reject(g);(new id(function(){try{a.j[f](a.i,d)}catch(h){a.h.reject(h),a.h=null}})).U(.01)}return a.h}
1101
1104
  function Xx(a,b,c){if(a.g)a.g.then(function(){return Xx(a,b,c)}).catch(function(){return Xx(a,b,c)});else{a.g=b;if("webkit-org.w3.clearkey"==a.i){var d=Af(c);var e=JSON.parse(d);"oct"!=e.keys[0].kty&&(a.g.reject(Error("Response is not a valid JSON Web Key Set.")),a.g=null);d=Xf(e.keys[0].k);e=Xf(e.keys[0].kid)}else d=mb(c),e=null;var f=Qx("addKey");try{a.j[f](a.i,d,e,a.sessionId)}catch(g){a.g.reject(g),a.g=null}}}
1102
1105
  function Tx(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new Q("keystatuseschange");a.dispatchEvent(b)}q=Ux.prototype;q.generateRequest=function(a,b){return Wx(this,b,null)};q.load=function(a){return"persistent-license"==this.l?Wx(this,null,a):Promise.reject(Error("Not a persistent session."))};q.update=function(a){var b=new Le;Xx(this,b,a);return b};
1103
- q.close=function(){if("persistent-license"!=this.l){if(!this.sessionId)return this.closed.reject(Error("The session is not callable.")),this.closed;var a=Qx("cancelKeyRequest");try{this.j[a](this.i,this.sessionId)}catch(b){}}this.closed.resolve();return this.closed};q.remove=function(){return"persistent-license"!=this.l?Promise.reject(Error("Not a persistent session.")):this.close()};function Vx(){this.size=0;this.g=void 0}q=Vx.prototype;q.Kb=function(){return this.g};
1106
+ q.close=function(){if("persistent-license"!=this.l){if(!this.sessionId)return this.closed.reject(Error("The session is not callable.")),this.closed;var a=Qx("cancelKeyRequest");try{this.j[a](this.i,this.sessionId)}catch(b){}}this.closed.resolve();return this.closed};q.remove=function(){return"persistent-license"!=this.l?Promise.reject(Error("Not a persistent session.")):this.close()};function Vx(){this.size=0;this.g=void 0}q=Vx.prototype;q.Jb=function(){return this.g};
1104
1107
  q.forEach=function(a){this.g&&a(this.g,mh.value())};q.get=function(a){if(this.has(a))return this.g};q.has=function(a){var b=mh.value();return this.g&&kb(a,b)?!0:!1};q.entries=function(){};q.keys=function(){};q.values=function(){};var Lx="";Iw(Kx);function Yx(){}function Zx(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;a.requestPictureInPicture&&document.exitPictureInPicture||!a.webkitSupportsPresentationMode||(document.pictureInPictureEnabled=!0,document.pictureInPictureElement=null,a.requestPictureInPicture=$x,Object.defineProperty(a,"disablePictureInPicture",{get:ay,set:by,enumerable:!0,configurable:!0}),document.exitPictureInPicture=cy,document.addEventListener("webkitpresentationmodechanged",dy,!0))}}
1105
1108
  function dy(a){a=a.target;if("picture-in-picture"==a.webkitPresentationMode){document.pictureInPictureElement=a;var b=new Event("enterpictureinpicture");a.dispatchEvent(b)}else document.pictureInPictureElement==a&&(document.pictureInPictureElement=null),b=new Event("leavepictureinpicture"),a.dispatchEvent(b)}
1106
1109
  function $x(){return this.webkitSupportsPresentationMode("picture-in-picture")?(this.webkitSetPresentationMode("picture-in-picture"),document.pictureInPictureElement=this,Promise.resolve()):Promise.reject(Error("PiP not allowed by video element"))}function cy(){var a=document.pictureInPictureElement;return a?(a.webkitSetPresentationMode("inline"),document.pictureInPictureElement=null,Promise.resolve()):Promise.reject(Error("No picture in picture element found"))}
1107
1110
  function ay(){return this.hasAttribute("disablePictureInPicture")?!0:!this.webkitSupportsPresentationMode("picture-in-picture")}function by(a){a?this.setAttribute("disablePictureInPicture",""):this.removeAttribute("disablePictureInPicture")}Hw.PiPWebkit=Yx;Yx.install=Zx;Iw(Zx);function ey(){}function fy(){window.crypto&&("randomUUID"in window.crypto||(window.crypto.randomUUID=gy))}function gy(){var a=URL.createObjectURL(new Blob),b=a.toString();URL.revokeObjectURL(a);return b.substr(b.lastIndexOf("/")+1)}Hw.RandomUUID=ey;ey.install=fy;Iw(fy);function hy(){}function iy(){navigator.storage&&navigator.storage.estimate||!navigator.webkitTemporaryStorage||!navigator.webkitTemporaryStorage.queryUsageAndQuota||("storage"in navigator||(navigator.storage={}),navigator.storage.estimate=jy)}function jy(){return new Promise(function(a,b){navigator.webkitTemporaryStorage.queryUsageAndQuota(function(c,d){a({usage:c,quota:d})},b)})}Hw.StorageEstimate=hy;hy.install=iy;Iw(iy);function ky(){}function ly(){var a=Symbol.prototype;"description"in a||Object.defineProperty(a,"description",{get:my})}function my(){var a=/\((.*)\)/.exec(this.toString());return a?a[1]:void 0}Hw.Symbol=ky;ky.install=ly;Iw(ly);function ny(){}function oy(){if(window.HTMLMediaElement){var a=HTMLMediaElement.prototype.play;HTMLMediaElement.prototype.play=function(){var b=a.apply(this);b&&b.catch(function(){});return b}}}Hw.VideoPlayPromise=ny;ny.install=oy;Iw(oy);function py(){}function qy(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;!a.getVideoPlaybackQuality&&("webkitDroppedFrameCount"in a||sd())&&(a.getVideoPlaybackQuality=ry)}}function ry(){return{droppedVideoFrames:this.webkitDroppedFrameCount,totalVideoFrames:this.webkitDecodedFrameCount,corruptedVideoFrames:0,creationTime:NaN,totalFrameDelay:0}}Hw.VideoPlaybackQuality=py;py.install=qy;Iw(qy);function sy(){}function ty(){if(!window.VTTCue&&window.TextTrackCue){var a=null,b=TextTrackCue.length;if(3==b)a=uy;else if(6==b)a=vy;else{try{var c=!!uy(1,2,"")}catch(d){c=!1}c&&(a=uy)}a&&(window.VTTCue=function(d,e,f){return a(d,e,f)})}}function uy(a,b,c){return new window.TextTrackCue(a,b,c)}function vy(a,b,c){return new window.TextTrackCue(a+"-"+b+"-"+c,a,b,c)}Hw.VTTCue=sy;sy.install=ty;Iw(ty);function wy(){}wy.prototype.parseInit=function(){};wy.prototype.setSequenceMode=function(){};wy.prototype.setManifestType=function(){};wy.prototype.parseMedia=function(a,b){var c=null,d=[];a=Af(a).split(/\r?\n/);a=t(a);for(var e=a.next();!e.done;e=a.next())if((e=e.value)&&!/^\s+$/.test(e)&&(e=xy.exec(e))){var f=yy.exec(e[1]);f=60*parseInt(f[1],10)+parseFloat(f[2].replace(",","."));e=new Bb(f,b.segmentEnd?b.segmentEnd:f+2,e[2]);c&&(c.endTime=f,d.push(c));c=e}c&&d.push(c);return d};
1108
1111
  N("shaka.text.LrcTextParser",wy);wy.prototype.parseMedia=wy.prototype.parseMedia;wy.prototype.setManifestType=wy.prototype.setManifestType;wy.prototype.setSequenceMode=wy.prototype.setSequenceMode;wy.prototype.parseInit=wy.prototype.parseInit;var xy=/^\[(\d{1,2}:\d{1,2}(?:[.,]\d{1,3})?)\](.*)/,yy=/^(\d+):(\d{1,2}(?:[.,]\d{1,3})?)$/;Oc["application/x-subtitle-lrc"]=function(){return new wy};function zy(){}zy.prototype.parseInit=function(){};zy.prototype.setSequenceMode=function(){};zy.prototype.setManifestType=function(){};
1109
1112
  zy.prototype.parseMedia=function(a,b,c){var d=Af(a);a=[];if(""==d)return a;var e=vg(d,"tt");if(!e)throw new O(2,2,2005,"Failed to parse TTML.");d=e.getElementsByTagName("body")[0];if(!d)return[];var f=ig(e,Ay,"frameRate"),g=ig(e,Ay,"subFrameRate"),h=ig(e,Ay,"frameRateMultiplier"),k=ig(e,Ay,"tickRate"),l=ig(e,Ay,"cellResolution"),m=e.getAttribute("xml:space")||"default",n=ig(e,By,"extent");if("default"!=m&&"preserve"!=m)throw new O(2,2,2005,"Invalid xml:space value: "+m);m="default"==m;f=new Cy(f,
1110
- g,h,k);l=l?(l=/^(\d+) (\d+)$/.exec(l))?{Eb:parseInt(l[1],10),rows:parseInt(l[2],10)}:null:null;g=(g=e.getElementsByTagName("metadata")[0])?gg(g):[];h=Array.from(e.getElementsByTagName("style"));e=Array.from(e.getElementsByTagName("region"));k=[];for(var r=t(e),p=r.next();!p.done;p=r.next()){var u=p.value;p=new Cb;var v=u.getAttribute("xml:id");if(v){p.id=v;var x=null;n&&(x=Dy.exec(n)||Ey.exec(n));v=x?Number(x[1]):null;x=x?Number(x[2]):null;var z,y;if(z=Fy(u,h,"extent"))z=(y=Dy.exec(z))||Ey.exec(z),
1113
+ g,h,k);l=l?(l=/^(\d+) (\d+)$/.exec(l))?{Db:parseInt(l[1],10),rows:parseInt(l[2],10)}:null:null;g=(g=e.getElementsByTagName("metadata")[0])?gg(g):[];h=Array.from(e.getElementsByTagName("style"));e=Array.from(e.getElementsByTagName("region"));k=[];for(var r=t(e),p=r.next();!p.done;p=r.next()){var u=p.value;p=new Cb;var v=u.getAttribute("xml:id");if(v){p.id=v;var x=null;n&&(x=Dy.exec(n)||Ey.exec(n));v=x?Number(x[1]):null;x=x?Number(x[2]):null;var z,y;if(z=Fy(u,h,"extent"))z=(y=Dy.exec(z))||Ey.exec(z),
1111
1114
  null!=z&&(p.width=Number(z[1]),p.height=Number(z[2]),y||(null!=v&&(p.width=100*p.width/v),null!=x&&(p.height=100*p.height/x)),p.widthUnits=y||null!=v?Vb:0,p.heightUnits=y||null!=x?Vb:0);if(u=Fy(u,h,"origin"))z=(y=Dy.exec(u))||Ey.exec(u),null!=z&&(p.viewportAnchorX=Number(z[1]),p.viewportAnchorY=Number(z[2]),y||(null!=x&&(p.viewportAnchorY=100*p.viewportAnchorY/x),null!=v&&(p.viewportAnchorX=100*p.viewportAnchorX/v)),p.viewportAnchorUnits=y||null!=v?Vb:0)}else p=null;p&&k.push(p)}if(dg(d,"p").length)throw new O(2,
1112
1115
  2,2001,"<p> can only be inside <div> in TTML");n=t(dg(d,"div"));for(r=n.next();!r.done;r=n.next())if(dg(r.value,"span").length)throw new O(2,2,2001,"<span> can only be inside <p> in TTML");if(b=Gy(d,b,f,g,h,e,k,m,l,null,!1,c))b.backgroundColor||(b.backgroundColor="transparent"),a.push(b);return a};
1113
1116
  function Gy(a,b,c,d,e,f,g,h,k,l,m,n){var r=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 u=null,v=t(Hy),x=v.next();!x.done&&!(u=Iy(p,"backgroundImage",d,"#",x.value)[0]);x=v.next());v=null;var z=ig(p,Hy,"backgroundImage");n&&z&&!z.startsWith("#")&&(x=new fc(n),z=new fc(z),(x=x.resolve(z).toString())&&(v=x));if("p"==a.nodeName||u||v)m=!0;a=m;x="default"==(p.getAttribute("xml:space")||
1114
- (h?"default":"preserve"));z=Array.from(p.childNodes).every(function(D){return D.nodeType==Node.TEXT_NODE});h=[];if(!z)for(var y=t(p.childNodes),B=y.next();!B.done;B=y.next())(B=Gy(B.value,b,c,d,e,f,g,x,k,p,m,n))&&h.push(B);d=null!=l;n=/\S/.test(p.textContent);B=p.hasAttribute("begin")||p.hasAttribute("end")||p.hasAttribute("dur");if(!(B||n||"br"==p.tagName||0!=h.length||d&&!x))return null;y=Jy(p,c);n=y.start;for(y=y.end;r&&r.nodeType==Node.ELEMENT_NODE&&"tt"!=r.tagName;)y=Ky(r,c,n,y),n=y.start,y=
1115
- y.end,r=r.parentNode;null==n&&(n=0);n+=b.periodStart;y=null==y?Infinity:y+b.periodStart;n=Math.max(n,b.segmentStart);y=Math.min(y,b.segmentEnd);if(!B&&0<h.length)for(n=Infinity,y=0,b=t(h),c=b.next();!c.done;c=b.next())c=c.value,n=Math.min(n,c.startTime),y=Math.max(y,c.endTime);if("br"==p.tagName)return e=new Bb(n,y,""),e.lineBreak=!0,e;b="";z&&(b=p.textContent,x&&(b=b.trim(),b=b.replace(/\s+/g," ")));b=new Bb(n,y,b);b.nestedCues=h;m||(b.isContainer=!0);k&&(b.cellResolution=k);k=Iy(p,"region",f,"")[0];
1116
- if(p.hasAttribute("region")&&k&&k.getAttribute("xml:id")){var A=k.getAttribute("xml:id");b.region=g.filter(function(D){return D.id==A})[0]}g=k;l&&d&&!p.getAttribute("region")&&!p.getAttribute("style")&&(g=Iy(l,"region",f,"")[0]);Ly(b,p,g,u,v,e,a,0==h.length);return b}
1117
+ (h?"default":"preserve"));z=Array.from(p.childNodes).every(function(D){return D.nodeType==Node.TEXT_NODE});h=[];if(!z)for(var y=t(p.childNodes),A=y.next();!A.done;A=y.next())(A=Gy(A.value,b,c,d,e,f,g,x,k,p,m,n))&&h.push(A);d=null!=l;n=/\S/.test(p.textContent);A=p.hasAttribute("begin")||p.hasAttribute("end")||p.hasAttribute("dur");if(!(A||n||"br"==p.tagName||0!=h.length||d&&!x))return null;y=Jy(p,c);n=y.start;for(y=y.end;r&&r.nodeType==Node.ELEMENT_NODE&&"tt"!=r.tagName;)y=Ky(r,c,n,y),n=y.start,y=
1118
+ y.end,r=r.parentNode;null==n&&(n=0);n+=b.periodStart;y=null==y?Infinity:y+b.periodStart;n=Math.max(n,b.segmentStart);y=Math.min(y,b.segmentEnd);if(!A&&0<h.length)for(n=Infinity,y=0,b=t(h),c=b.next();!c.done;c=b.next())c=c.value,n=Math.min(n,c.startTime),y=Math.max(y,c.endTime);if("br"==p.tagName)return e=new Bb(n,y,""),e.lineBreak=!0,e;b="";z&&(b=p.textContent,x&&(b=b.trim(),b=b.replace(/\s+/g," ")));b=new Bb(n,y,b);b.nestedCues=h;m||(b.isContainer=!0);k&&(b.cellResolution=k);k=Iy(p,"region",f,"")[0];
1119
+ if(p.hasAttribute("region")&&k&&k.getAttribute("xml:id")){var B=k.getAttribute("xml:id");b.region=g.filter(function(D){return D.id==B})[0]}g=k;l&&d&&!p.getAttribute("region")&&!p.getAttribute("style")&&(g=Iy(l,"region",f,"")[0]);Ly(b,p,g,u,v,e,a,0==h.length);return b}
1117
1120
  function Ly(a,b,c,d,e,f,g,h){g=g||h;"rtl"==My(b,c,f,"direction",g)&&(a.direction="rtl");h=My(b,c,f,"writingMode",g);"tb"==h||"tblr"==h?a.writingMode="vertical-lr":"tbrl"==h?a.writingMode="vertical-rl":"rltb"==h||"rl"==h?a.direction="rtl":h&&(a.direction=Fb);(h=My(b,c,f,"textAlign",!0))?(a.positionAlign=Ny[h],a.lineAlign=Oy[h],a.textAlign=Ob[h.toUpperCase()]):a.textAlign=Eb;if(h=My(b,c,f,"displayAlign",!0))a.displayAlign=Pb[h.toUpperCase()];if(h=My(b,c,f,"color",g))a.color=h;if(h=My(b,c,f,"backgroundColor",
1118
1121
  g))a.backgroundColor=h;if(h=My(b,c,f,"border",g))a.border=h;if(h=My(b,c,f,"fontFamily",g))switch(h){case "monospaceSerif":a.fontFamily="Courier New,Liberation Mono,Courier,monospace";break;case "proportionalSansSerif":a.fontFamily="Arial,Helvetica,Liberation Sans,sans-serif";break;case "sansSerif":a.fontFamily="sans-serif";break;case "monospaceSansSerif":a.fontFamily="Consolas,monospace";break;case "proportionalSerif":a.fontFamily="serif";break;default:a.fontFamily=h}(h=My(b,c,f,"fontWeight",g))&&
1119
1122
  "bold"==h&&(a.fontWeight=700);h=My(b,c,f,"wrapOption",g);a.wrapLine=h&&"noWrap"==h?!1:!0;(h=My(b,c,f,"lineHeight",g))&&h.match(Py)&&(a.lineHeight=h);(h=My(b,c,f,"fontSize",g))&&(h.match(Py)||h.match(Qy))&&(a.fontSize=h);if(h=My(b,c,f,"fontStyle",g))a.fontStyle=Ub[h.toUpperCase()];d?(e=d.getAttribute("imageType")||d.getAttribute("imagetype"),h=d.getAttribute("encoding"),d=d.textContent.trim(),"PNG"==e&&"Base64"==h&&d&&(a.backgroundImage="data:image/png;base64,"+d)):e&&(a.backgroundImage=e);if(d=My(b,
@@ -1150,7 +1153,7 @@ b||"end"==b?"line-right":"center"==b||"middle"==b?"center":Db);else if(d=/^regio
1150
1153
  function lz(a,b){a=a.filter(function(c){return c.id==b});return a.length?a[0]:null}function dz(a){a=xs(a,hz);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)}
1151
1154
  function iz(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||""}N("shaka.text.VttTextParser",cz);cz.prototype.parseMedia=cz.prototype.parseMedia;cz.prototype.setManifestType=cz.prototype.setManifestType;cz.prototype.setSequenceMode=cz.prototype.setSequenceMode;cz.prototype.parseInit=cz.prototype.parseInit;
1152
1155
  var hz=/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g;Oc["text/vtt"]=function(){return new cz};Oc['text/vtt; codecs="vtt"']=function(){return new cz};Oc['text/vtt; codecs="wvtt"']=function(){return new cz};function mz(){this.g=null}mz.prototype.parseInit=function(a){var b=this,c=!1;(new Kf).box("moov",Pf).box("trak",Pf).box("mdia",Pf).O("mdhd",function(d){d=Mh(d.reader,d.version);b.g=d.timescale}).box("minf",Pf).box("stbl",Pf).O("stsd",Rf).box("wvtt",function(){c=!0}).parse(a);if(!this.g)throw new O(2,2,2008);if(!c)throw new O(2,2,2008);};mz.prototype.setSequenceMode=function(){};mz.prototype.setManifestType=function(){};
1153
- mz.prototype.parseMedia=function(a,b){if(!a.length)return[];if(!this.g)throw new O(2,2,2008);var c=0,d=[],e,f=[],g=!1,h=!1,k=!1,l=null;(new Kf).box("moof",Pf).box("traf",Pf).O("tfdt",function(B){g=!0;c=Lh(B.reader,B.version).baseMediaDecodeTime}).O("tfhd",function(B){l=Kh(B.reader,B.flags).zf}).O("trun",function(B){h=!0;d=Nh(B.reader,B.version,B.flags).Wf}).box("mdat",Tf(function(B){k=!0;e=B})).parse(a,!1);if(!k&&!g&&!h)throw new O(2,2,2008);a=c;for(var m=new Gf(e,0),n=t(d),r=n.next();!r.done;r=n.next()){r=
1156
+ mz.prototype.parseMedia=function(a,b){if(!a.length)return[];if(!this.g)throw new O(2,2,2008);var c=0,d=[],e,f=[],g=!1,h=!1,k=!1,l=null;(new Kf).box("moof",Pf).box("traf",Pf).O("tfdt",function(A){g=!0;c=Lh(A.reader,A.version).baseMediaDecodeTime}).O("tfhd",function(A){l=Kh(A.reader,A.flags).zf}).O("trun",function(A){h=!0;d=Nh(A.reader,A.version,A.flags).Wf}).box("mdat",Tf(function(A){k=!0;e=A})).parse(a,!1);if(!k&&!g&&!h)throw new O(2,2,2008);a=c;for(var m=new Gf(e,0),n=t(d),r=n.next();!r.done;r=n.next()){r=
1154
1157
  r.value;var p=r.Ze||l,u=r.Md?c+r.Md:a;a=u+(p||0);var v=0;do{var x=m.L();v+=x;var z=m.L(),y=null;"vttc"==Of(z)?8<x&&(y=m.lb(x-8)):m.skip(x-8);p&&y&&(x=nz(y,b.periodStart+u/this.g,b.periodStart+a/this.g),f.push(x))}while(r.sampleSize&&v<r.sampleSize)}return f.filter(Wc)};function nz(a,b,c){var d,e,f;(new Kf).box("payl",Tf(function(g){d=Af(g)})).box("iden",Tf(function(g){e=Af(g)})).box("sttg",Tf(function(g){f=Af(g)})).parse(a);return d?oz(d,e,f,b,c):null}
1155
1158
  function oz(a,b,c,d,e){d=new Bb(d,e,"");gz(a,d,new Map);b&&(d.id=b);if(c)for(a=new vs(c),b=ys(a);b;)fz(d,b,[]),ws(a),b=ys(a);return d}N("shaka.text.Mp4VttParser",mz);mz.prototype.parseMedia=mz.prototype.parseMedia;mz.prototype.setManifestType=mz.prototype.setManifestType;mz.prototype.setSequenceMode=mz.prototype.setSequenceMode;mz.prototype.parseInit=mz.prototype.parseInit;Oc['application/mp4; codecs="wvtt"']=function(){return new mz};function pz(){}pz.prototype.parseInit=function(){};pz.prototype.setSequenceMode=function(){};pz.prototype.setManifestType=function(){};pz.prototype.parseMedia=function(a){var b=Af(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 vs(c[0]),e=qz(d),f=xs(d,/,/g);d=qz(d);if(null==e||null==f||null==d)throw new O(2,2,2001,"Could not parse cue time range in SubViewer");a.push(new Bb(e,d,c.slice(1).join("\n").trim()))}return a};
1156
1159
  function qz(a){a=xs(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)}N("shaka.text.SbvTextParser",pz);pz.prototype.parseMedia=pz.prototype.parseMedia;pz.prototype.setManifestType=pz.prototype.setManifestType;pz.prototype.setSequenceMode=pz.prototype.setSequenceMode;pz.prototype.parseInit=pz.prototype.parseInit;Oc["text/x-subviewer"]=function(){return new pz};function rz(){this.g=new cz}rz.prototype.parseInit=function(){};rz.prototype.setSequenceMode=function(){};rz.prototype.setManifestType=function(){};rz.prototype.parseMedia=function(a,b,c){a=Af(a);a=sz(a);a=mb(Ef(a));return this.g.parseMedia(a,b,c)};
@@ -1180,17 +1183,17 @@ Kz.prototype.getOriginalMimeType=Kz.prototype.getOriginalMimeType;Kz.prototype.c
1180
1183
  function Nz(a){var b=!1,c=[],d=a.find(function(k){return 7==k.type}),e=!1;a=t(a);for(var f=a.next();!f.done;f=a.next()){f=f.value;var g=!1;switch(f.type){case 1:g=e=!0;var h=f.data;d&&4<h.length&&(h=bi(new Th(h)),2===h||4===h||7===h||9===h)&&(b=!0);break;case 5:b=g=e=!0;break;case 6:g=!0;break;case 7:g=!0;break;case 8:g=!0;break;case 9:e=g=!0;break;case 12:g=!0;break;default:g=!1}e&&g&&(g=f.ba.byteLength,h=new Uint8Array(4),h[0]=g>>24&255,h[1]=g>>16&255,h[2]=g>>8&255,h[3]=g&255,c.push($f(h,f.ba)))}return c.length?
1181
1184
  {data:$f.apply(Uf,w(c)),Qc:b}:null}var Mz=[100,110,122,244,44,83,86,118,128,138,139,134];function Oz(a){if(!a.length)return null;var b=a.find(function(g){return 32==g.type}),c=a.find(function(g){return 33==g.type}),d=a.find(function(g){return 34==g.type});if(!b||!c||!d)return null;var e=Pz(b.ba);a=Qz(c.ba);var f=Rz(d.ba);b=Sz(b.ba,c.ba,d.ba,{Qe:e.Qe,gf:e.gf,te:a.te,ue:a.ue,ne:a.ne,se:a.se,oe:a.oe,pe:a.pe,qe:a.qe,re:a.re,he:a.he,ie:a.ie,je:a.je,ke:a.ke,le:a.le,me:a.me,de:a.de,Hd:a.Hd,ce:a.ce,be:a.be,ae:a.ae,Te:f.Te});return{height:a.height,width:a.width,ka:b}}
1182
1185
  function Pz(a){var b=new Th(a,!0);$h(b);$h(b);Wh(b,4);Wh(b,2);Wh(b,6);a=Wh(b,3);b=U(b);return{Qe:a+1,gf:b}}
1183
- function Qz(a){a=new Th(a,!0);$h(a);$h(a);var b=0,c=0,d=0,e=0;Wh(a,4);var f=Wh(a,3);U(a);for(var g=Wh(a,2),h=Wh(a,1),k=Wh(a,5),l=$h(a),m=$h(a),n=$h(a),r=$h(a),p=$h(a),u=$h(a),v=$h(a),x=$h(a),z=$h(a),y=$h(a),B=$h(a),A=[],D=[],F=0;F<f;F++)A.push(U(a)),D.push(U(a));if(0<f)for(F=f;8>F;F++)Wh(a,2);for(F=0;F<f;F++)A[F]&&Wh(a,88),D[F]&&$h(a);T(a);A=T(a);3==A&&Wh(a,1);D=T(a);F=T(a);U(a)&&(b+=T(a),c+=T(a),d+=T(a),e+=T(a));var J=T(a),G=T(a),H=T(a);if(U(a))for(var I=0;I<=f;I++)T(a),T(a),T(a);else T(a),T(a),
1184
- T(a);T(a);T(a);T(a);T(a);T(a);T(a);if(U(a)&&U(a))for(I=0;4>I;I++)for(var L=0;L<(3===I?2:6);L++)if(U(a)){var M=Math.min(64,1<<4+(I<<1));1<I&&Zh(a);for(var P=0;P<M;P++)Zh(a)}else T(a);U(a);U(a);U(a)&&($h(a),T(a),T(a),U(a));I=T(a);for(M=L=0;M<I;M++)if(P=!1,0!==M&&(P=U(a)),P){M===I&&T(a);U(a);T(a);for(var R=P=0;R<=L;R++){var V=U(a),X=!1;V||(X=U(a));(V||X)&&P++}L=P}else{R=T(a);P=T(a);L=R+P;for(V=0;V<R;V++)T(a),U(a);for(R=0;R<P;R++)T(a),U(a)}if(U(a))for(I=T(a),L=0;L<I;L++){for(M=0;M<H+4;M++)Wh(a,1);Wh(a,
1185
- 1)}H=0;U(a);U(a);if(U(a)){U(a)&&255===$h(a)&&(Wh(a,16),Wh(a,16));U(a)&&U(a);U(a)&&(Wh(a,3),U(a),U(a)&&($h(a),$h(a),$h(a)));U(a)&&(T(a),T(a));U(a);U(a);U(a);if(I=U(a))T(a),T(a),T(a),T(a);if(U(a)&&(Wh(a,32),Wh(a,32),U(a)&&T(a),U(a))){M=!1;I=U(a);L=U(a);if(I||L){if(M=U(a))$h(a),Wh(a,5),U(a),Wh(a,5);Wh(a,4);Wh(a,4);M&&Wh(a,4);Wh(a,5);Wh(a,5);Wh(a,5)}for(P=0;P<=f;P++){V=!0;R=1;U(a)||(V=U(a));X=!1;V?T(a):X=U(a);X||(R=T(a)+1);if(I){for(V=0;V<R;V++)T(a),T(a),M&&(T(a),T(a));U(a)}if(L){for(V=0;V<R;V++)T(a),
1186
- T(a),M&&(T(a),T(a));U(a)}}}U(a)&&(U(a),U(a),U(a),H=T(a),T(a),T(a),T(a),T(a))}return{ne:B,te:g,ue:h,se:k,oe:l,pe:m,qe:n,re:r,he:p,ie:u,je:v,ke:x,le:z,me:y,Hd:H,de:0,ce:A,be:J,ae:G,width:D-(b+c)*(1===A||2===A?2:1),height:F-(d+e)*(1===A?2:1)}}function Rz(a){var b=new Th(a,!0);$h(b);$h(b);T(b);T(b);U(b);U(b);Wh(b,3);U(b);U(b);T(b);T(b);Zh(b);U(b);U(b);U(b)&&T(b);Zh(b);Zh(b);U(b);U(b);U(b);U(b);a=U(b);b=U(b);var c=1;b&&a?c=0:b?c=3:a&&(c=2);return{Te:c}}
1186
+ function Qz(a){a=new Th(a,!0);$h(a);$h(a);var b=0,c=0,d=0,e=0;Wh(a,4);var f=Wh(a,3);U(a);for(var g=Wh(a,2),h=Wh(a,1),k=Wh(a,5),l=$h(a),m=$h(a),n=$h(a),r=$h(a),p=$h(a),u=$h(a),v=$h(a),x=$h(a),z=$h(a),y=$h(a),A=$h(a),B=[],D=[],F=0;F<f;F++)B.push(U(a)),D.push(U(a));if(0<f)for(F=f;8>F;F++)Wh(a,2);for(F=0;F<f;F++)B[F]&&Wh(a,88),D[F]&&$h(a);T(a);B=T(a);3==B&&Wh(a,1);D=T(a);F=T(a);U(a)&&(b+=T(a),c+=T(a),d+=T(a),e+=T(a));var J=T(a),G=T(a),H=T(a);if(U(a))for(var I=0;I<=f;I++)T(a),T(a),T(a);else T(a),T(a),
1187
+ T(a);T(a);T(a);T(a);T(a);T(a);T(a);if(U(a)&&U(a))for(I=0;4>I;I++)for(var L=0;L<(3===I?2:6);L++)if(U(a)){var M=Math.min(64,1<<4+(I<<1));1<I&&Zh(a);for(var P=0;P<M;P++)Zh(a)}else T(a);U(a);U(a);U(a)&&($h(a),T(a),T(a),U(a));I=T(a);for(M=L=0;M<I;M++)if(P=!1,0!==M&&(P=U(a)),P){M===I&&T(a);U(a);T(a);for(var R=P=0;R<=L;R++){var W=U(a),X=!1;W||(X=U(a));(W||X)&&P++}L=P}else{R=T(a);P=T(a);L=R+P;for(W=0;W<R;W++)T(a),U(a);for(R=0;R<P;R++)T(a),U(a)}if(U(a))for(I=T(a),L=0;L<I;L++){for(M=0;M<H+4;M++)Wh(a,1);Wh(a,
1188
+ 1)}H=0;U(a);U(a);if(U(a)){U(a)&&255===$h(a)&&(Wh(a,16),Wh(a,16));U(a)&&U(a);U(a)&&(Wh(a,3),U(a),U(a)&&($h(a),$h(a),$h(a)));U(a)&&(T(a),T(a));U(a);U(a);U(a);if(I=U(a))T(a),T(a),T(a),T(a);if(U(a)&&(Wh(a,32),Wh(a,32),U(a)&&T(a),U(a))){M=!1;I=U(a);L=U(a);if(I||L){if(M=U(a))$h(a),Wh(a,5),U(a),Wh(a,5);Wh(a,4);Wh(a,4);M&&Wh(a,4);Wh(a,5);Wh(a,5);Wh(a,5)}for(P=0;P<=f;P++){W=!0;R=1;U(a)||(W=U(a));X=!1;W?T(a):X=U(a);X||(R=T(a)+1);if(I){for(W=0;W<R;W++)T(a),T(a),M&&(T(a),T(a));U(a)}if(L){for(W=0;W<R;W++)T(a),
1189
+ T(a),M&&(T(a),T(a));U(a)}}}U(a)&&(U(a),U(a),U(a),H=T(a),T(a),T(a),T(a),T(a))}return{ne:A,te:g,ue:h,se:k,oe:l,pe:m,qe:n,re:r,he:p,ie:u,je:v,ke:x,le:z,me:y,Hd:H,de:0,ce:B,be:J,ae:G,width:D-(b+c)*(1===B||2===B?2:1),height:F-(d+e)*(1===B?2:1)}}function Rz(a){var b=new Th(a,!0);$h(b);$h(b);T(b);T(b);U(b);U(b);Wh(b,3);U(b);U(b);T(b);T(b);Zh(b);U(b);U(b);U(b)&&T(b);Zh(b);Zh(b);U(b);U(b);U(b);U(b);a=U(b);b=U(b);var c=1;b&&a?c=0:b?c=3:a&&(c=2);return{Te:c}}
1187
1190
  function Sz(a,b,c,d){var e=new Uint8Array(23+(5+a.byteLength)+(5+b.byteLength)+(5+c.byteLength));e[0]=1;e[1]=(d.te&3)<<6|(d.ue?1:0)<<5|d.se&31;e[2]=d.oe;e[3]=d.pe;e[4]=d.qe;e[5]=d.re;e[6]=d.he;e[7]=d.ie;e[8]=d.je;e[9]=d.ke;e[10]=d.le;e[11]=d.me;e[12]=d.ne;e[13]=240|(d.Hd&3840)>>8;e[14]=d.Hd&255;e[15]=252|d.Te&3;e[16]=252|d.ce&3;e[17]=248|d.be&7;e[18]=248|d.ae&7;e[19]=0;e[20]=0;e[21]=(d.de&3)<<6|(d.Qe&7)<<3|(d.gf?1:0)<<2|3;e[22]=3;e[23]=160;e[24]=0;e[25]=1;e[26]=(a.byteLength&65280)>>8;e[27]=(a.byteLength&
1188
1191
  255)>>0;e.set(a,28);e[23+(5+a.byteLength)]=161;e[a.byteLength+29]=0;e[a.byteLength+30]=1;e[a.byteLength+31]=(b.byteLength&65280)>>8;e[a.byteLength+32]=(b.byteLength&255)>>0;e.set(b,a.byteLength+33);e[23+(a.byteLength+10+b.byteLength)]=162;e[a.byteLength+10+b.byteLength+24]=0;e[a.byteLength+10+b.byteLength+25]=1;e[a.byteLength+10+b.byteLength+26]=(c.byteLength&65280)>>8;e[a.byteLength+10+b.byteLength+27]=(c.byteLength&255)>>0;e.set(c,a.byteLength+10+b.byteLength+28);return e};function Tz(a,b){var c=a[b+1]>>3&3,d=a[b+1]>>1&3,e=a[b+2]>>4&15,f=a[b+2]>>2&3;if(1!==c&&0!==e&&15!==e&&3!==f){var g=a[b+3]>>6;e=1E3*Uz[14*(3===c?3-d:3===d?3:4)+e-1];f=Vz[3*(3===c?0:2===c?1:2)+f];c=Wz[c][d];var h=Xz[d],k=Math.floor(c*e/f+(a[b+2]>>1&1))*h,l=(navigator.userAgent||"").match(/Chrome\/(\d+)/i);(l=l?parseInt(l[1],10):0)&&87>=l&&2===d&&224E3<=e&&0===g&&(a[b+3]|=128);return{sampleRate:f,channelCount:3===g?1:2,R:k,Ch:8*c*h}}return null}
1189
1192
  function Yz(a,b){return 255===a[b]&&224===(a[b+1]&224)&&0!==(a[b+1]&6)}var Uz=[32,64,96,128,160,192,224,256,288,320,352,384,416,448,32,48,56,64,80,96,112,128,160,192,224,256,320,384,32,40,48,56,64,80,96,112,128,160,192,224,256,320,32,48,56,64,80,96,112,128,144,160,176,192,224,256,8,16,24,32,40,48,56,64,80,96,112,128,144,160],Vz=[44100,48E3,32E3,22050,24E3,16E3,11025,12E3,8E3],Wz=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],Xz=[0,1,1,4];function Zz(a){this.i=a;this.h=0;this.g=new Map}q=Zz.prototype;q.destroy=function(){this.g.clear()};q.isSupported=function(a){return"audio/mpeg"==a.toLowerCase().split(";")[0]?bb(this.convertCodecs("audio",a)):!1};q.convertCodecs=function(a,b){return"audio/mpeg"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="mp3"':b};q.getOriginalMimeType=function(){return this.i};
1190
1193
  q.transmux=function(a,b,c,d){a=mb(a);for(c=Jh(a).length;c<a.length;c++){var e=c;if(e+1<a.length&&Yz(a,e)){var f=Tz(a,e),g=4;f&&f.R&&(g=f.R);e+=g;e=e===a.length||e+1<a.length&&Yz(a,e)}else e=!1;if(e)break}var h;for(e=[];c<a.length;){f=Tz(a,c);if(!f)return Promise.reject(new O(2,3,3018));h||(h=f);c+f.R<=a.length&&e.push({data:a.subarray(c,c+f.R),size:f.R,duration:1152,Oa:0,flags:{Pa:0,Ha:0,Fa:0,Da:0,Ea:2,Qa:0}});c+=f.R}if(!h)return Promise.reject(new O(2,3,3018));a=9E4*h.Ch/h.sampleRate*this.h;d={id:b.id,
1191
1194
  type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:h.sampleRate,duration:d,Ma:[],aa:new Uint8Array([]),ka:new Uint8Array([]),data:{$a:this.h,baseMediaDecodeTime:a,Ja:e},stream:b};h=new Xt([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=cu(h),this.g.set(b.id,d));b=su(h);this.h++;b=$f(d,b);return Promise.resolve(b)};N("shaka.transmuxer.Mp3Transmuxer",Zz);Zz.prototype.transmux=Zz.prototype.transmux;Zz.prototype.getOriginalMimeType=Zz.prototype.getOriginalMimeType;
1192
1195
  Zz.prototype.convertCodecs=Zz.prototype.convertCodecs;Zz.prototype.isSupported=Zz.prototype.isSupported;Zz.prototype.destroy=Zz.prototype.destroy;Yb("audio/mpeg",function(){return new Zz("audio/mpeg")},dc);function $z(a){this.h=a;this.g=null}q=$z.prototype;q.destroy=function(){};q.isSupported=function(a){if("video/mp2t"!=a.toLowerCase().split(";")[0])return!1;var b=Lc(a).split(","),c=zc("audio",b);b=zc("video",b);return!c||b||"mp3"!=Ic(c)?!1:bb(this.convertCodecs("audio",a))};q.convertCodecs=function(a,b){return"video/mp2t"==b.toLowerCase().split(";")[0]?"audio/mpeg":b};q.getOriginalMimeType=function(){return this.h};
1193
- q.transmux=function(a,b,c,d,e){this.g?this.g.clearData():this.g=new ci;a=mb(a);a=this.g.parse(a);if("mp3"!=a.Hc().audio||"audio"!=e)return Promise.reject(new O(2,3,3018));e=new Uint8Array([]);a=t(a.Gb());for(b=a.next();!b.done;b=a.next())if(b=b.value.data)for(c=0;c<b.length;)(d=Tz(b,c))?(c+d.R<=b.length&&(e=$f(e,b.subarray(c,c+d.R))),c+=d.R):c++;return Promise.resolve(e)};N("shaka.transmuxer.MpegTsTransmuxer",$z);$z.prototype.transmux=$z.prototype.transmux;$z.prototype.getOriginalMimeType=$z.prototype.getOriginalMimeType;
1196
+ q.transmux=function(a,b,c,d,e){this.g?this.g.clearData():this.g=new ci;a=mb(a);a=this.g.parse(a);if("mp3"!=a.Hc().audio||"audio"!=e)return Promise.reject(new O(2,3,3018));e=new Uint8Array([]);a=t(a.Fb());for(b=a.next();!b.done;b=a.next())if(b=b.value.data)for(c=0;c<b.length;)(d=Tz(b,c))?(c+d.R<=b.length&&(e=$f(e,b.subarray(c,c+d.R))),c+=d.R):c++;return Promise.resolve(e)};N("shaka.transmuxer.MpegTsTransmuxer",$z);$z.prototype.transmux=$z.prototype.transmux;$z.prototype.getOriginalMimeType=$z.prototype.getOriginalMimeType;
1194
1197
  $z.prototype.convertCodecs=$z.prototype.convertCodecs;$z.prototype.isSupported=$z.prototype.isSupported;$z.prototype.destroy=$z.prototype.destroy;Yb("video/mp2t",function(){return new $z("video/mp2t")},cc);/*
1195
1198
  @license
1196
1199
  MSS Transmuxer
@@ -1209,14 +1212,14 @@ aA.prototype.convertCodecs=aA.prototype.convertCodecs;aA.prototype.isSupported=a
1209
1212
  q.convertCodecs=function(a,b){return"video/mp2t"==b.toLowerCase().split(";")[0]?(b=Lc(b).replace("mp4a.40.34","mp3").split(",").map(this.Fg).join(","),"audio"==a?'audio/mp4; codecs="'+b+'"':'video/mp4; codecs="'+b+'"'):b};q.Fg=function(a){if(a.includes("avc1")){var b=a.split(".");if(3==b.length)return a=b.shift()+".",a+=parseInt(b.shift(),10).toString(16),a+=("000"+parseInt(b.shift(),10).toString(16)).slice(-4)}return a};q.getOriginalMimeType=function(){return this.j};
1210
1213
  q.transmux=function(a,b,c,d,e){this.i?this.i.clearData():this.i=new ci;a=mb(a);var f=this.i.parse(a);a=[];var g=f.Hc();try{var h=null;if("video"==e){switch(g.video){case "avc":var k=[],l=null,m=[],n=f.ac();if(!n.length)throw new O(2,3,3023);for(var r=0;r<n.length;r++){var p=n[r],u=p.xb;m=m.concat(u);var v=Nz(u);if(v){null==l&&(l=p.dts);var x=void 0;x=r+1<n.length?(n[r+1].dts||0)-(p.dts||0):1<n.length?(p.dts||0)-(n[r-1].dts||0):9E4*(c.endTime-c.startTime);k.push({data:v.data,size:v.data.byteLength,
1211
1214
  duration:x,Oa:Math.round((p.pts||0)-(p.dts||0)),flags:{Pa:0,Ha:0,Fa:0,Da:0,Ea:v.Qc?2:1,Qa:v.Qc?0:1}})}}var z=Lz(m);if(!z||null==l)throw new O(2,3,3018);b.height=z.height;b.width=z.width;h={id:b.id,type:"video",codecs:"avc1",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:9E4,duration:d,Ma:[],aa:new Uint8Array([]),ka:z.ka,data:{$a:this.g,baseMediaDecodeTime:l,Ja:k},stream:b};break;case "hvc":n=[];p=null;u=[];k=f.ac();if(!k.length)throw new O(2,3,3023);for(v=0;v<k.length;v++){l=k[v];m=l.xb;u=u.concat(m);
1212
- z=!1;var y=[],B=!1;r=t(m);for(x=r.next();!x.done;x=r.next()){var A=x.value;switch(A.type){case 1:case 0:var D=B=!0;break;case 19:case 20:case 21:z=D=B=!0;break;case 32:D=!0;break;case 33:D=!0;break;case 34:D=!0;break;case 35:B=D=!0;break;case 39:case 40:D=!0;break;default:D=!1}if(B&&D){var F=A.ba.byteLength,J=new Uint8Array(4);J[0]=F>>24&255;J[1]=F>>16&255;J[2]=F>>8&255;J[3]=F&255;y.push($f(J,A.ba))}}var G=y.length?{data:$f.apply(Uf,w(y)),Qc:z}:null;G&&(null==p&&null!=l.dts&&(p=l.dts),z=void 0,z=
1215
+ z=!1;var y=[],A=!1;r=t(m);for(x=r.next();!x.done;x=r.next()){var B=x.value;switch(B.type){case 1:case 0:var D=A=!0;break;case 19:case 20:case 21:z=D=A=!0;break;case 32:D=!0;break;case 33:D=!0;break;case 34:D=!0;break;case 35:A=D=!0;break;case 39:case 40:D=!0;break;default:D=!1}if(A&&D){var F=B.ba.byteLength,J=new Uint8Array(4);J[0]=F>>24&255;J[1]=F>>16&255;J[2]=F>>8&255;J[3]=F&255;y.push($f(J,B.ba))}}var G=y.length?{data:$f.apply(Uf,w(y)),Qc:z}:null;G&&(null==p&&null!=l.dts&&(p=l.dts),z=void 0,z=
1213
1216
  v+1<k.length?(k[v+1].dts||0)-(l.dts||0):1<k.length?(l.dts||0)-(k[v-1].dts||0):9E4*(c.endTime-c.startTime),n.push({data:G.data,size:G.data.byteLength,duration:z,Oa:Math.round((l.pts||0)-(l.dts||0)),flags:{Pa:0,Ha:0,Fa:0,Da:0,Ea:G.Qc?2:1,Qa:G.Qc?0:1}}))}var H=Oz(u);if(!H||null==p)throw new O(2,3,3018);b.height=H.height;b.width=H.width;h={id:b.id,type:"video",codecs:"hvc1",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:9E4,duration:d,Ma:[],aa:new Uint8Array([]),ka:H.ka,data:{$a:this.g,baseMediaDecodeTime:p,
1214
- Ja:n},stream:b}}h&&(a.push(h),h=null)}if("audio"==e){switch(g.audio){case "aac":for(var I=[],L,M=null,P=t(f.Gb()),R=P.next();!R.done;R=P.next()){var V=R.value,X=V.data;if(X){var fa=0;L=Cz(X,fa);if(!L)throw new O(2,3,3018);b.audioSamplingRate=L.sampleRate;b.channelsCount=L.channelCount;null==M&&null!==V.pts&&(M=V.pts);for(;fa<X.length;){var Ha=Bz(X,fa);if(Ha){var Sa=Ha.Bd+Ha.R;fa+Sa<=X.length&&I.push({data:X.subarray(fa+Ha.Bd,fa+Sa),size:Ha.R,duration:1024,Oa:0,flags:{Pa:0,Ha:0,Fa:0,Da:0,Ea:2,Qa:0}});
1215
- fa+=Sa}else fa++}}}if(!L||null==M){if(!f.ac().length)throw new O(2,3,3018);M=9E4*c.startTime;var wb=zc("audio",b.codecs.split(","));if(!wb||!b.channelsCount||!b.audioSamplingRate)throw new O(2,3,3018);L={sampleRate:b.audioSamplingRate,channelCount:b.channelsCount,fa:wb};var db=Ez(wb,b.channelsCount);if(!db)throw new O(2,3,3018);var Sb=M+9E4*(c.endTime-c.startTime);for(f=M;f<Sb;)I.push({data:db,size:db.byteLength,duration:1024,Oa:0,flags:{Pa:0,Ha:0,Fa:0,Da:0,Ea:2,Qa:0}}),f+=1024/L.sampleRate*9E4}var ua=
1216
- L.sampleRate;f=M/9E4*ua;h={id:b.id,type:"audio",codecs:L.fa,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:ua,duration:d,Ma:[],aa:new Uint8Array([]),ka:new Uint8Array([]),data:{$a:this.g,baseMediaDecodeTime:f,Ja:I},stream:b};break;case "ac3":L=[];ua=0;I=new Uint8Array([]);M=null;fa=t(f.Gb());for(var eb=fa.next();!eb.done;eb=fa.next()){var $a=eb.value,xb=$a.data;null==M&&null!==$a.pts&&(M=$a.pts);for(f=0;f<xb.length;){var ab=Gz(xb,f);ab?(b.audioSamplingRate=ab.sampleRate,b.channelsCount=ab.channelCount,
1217
- ua=ab.sampleRate,I=ab.aa,L.push({data:xb.subarray(f,f+ab.R),size:ab.R,duration:1536,Oa:0,flags:{Pa:0,Ha:0,Fa:0,Da:0,Ea:2,Qa:0}}),f+=ab.R):f++}}if(0==ua||0==I.byteLength||null==M)throw new O(2,3,3018);f=M/9E4*ua;h={id:b.id,type:"audio",codecs:"ac-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:ua,duration:d,Ma:[],aa:I,ka:new Uint8Array([]),data:{$a:this.g,baseMediaDecodeTime:f,Ja:L},stream:b};break;case "ec3":L=[];ua=0;M=new Uint8Array([]);I=null;for(var kh=t(f.Gb()),xd=kh.next();!xd.done;xd=
1217
+ Ja:n},stream:b}}h&&(a.push(h),h=null)}if("audio"==e){switch(g.audio){case "aac":for(var I=[],L,M=null,P=t(f.Fb()),R=P.next();!R.done;R=P.next()){var W=R.value,X=W.data;if(X){var ia=0;L=Cz(X,ia);if(!L)throw new O(2,3,3018);b.audioSamplingRate=L.sampleRate;b.channelsCount=L.channelCount;null==M&&null!==W.pts&&(M=W.pts);for(;ia<X.length;){var Ha=Bz(X,ia);if(Ha){var Sa=Ha.Bd+Ha.R;ia+Sa<=X.length&&I.push({data:X.subarray(ia+Ha.Bd,ia+Sa),size:Ha.R,duration:1024,Oa:0,flags:{Pa:0,Ha:0,Fa:0,Da:0,Ea:2,Qa:0}});
1218
+ ia+=Sa}else ia++}}}if(!L||null==M){if(!f.ac().length)throw new O(2,3,3018);M=9E4*c.startTime;var wb=zc("audio",b.codecs.split(","));if(!wb||!b.channelsCount||!b.audioSamplingRate)throw new O(2,3,3018);L={sampleRate:b.audioSamplingRate,channelCount:b.channelsCount,fa:wb};var db=Ez(wb,b.channelsCount);if(!db)throw new O(2,3,3018);var Sb=M+9E4*(c.endTime-c.startTime);for(f=M;f<Sb;)I.push({data:db,size:db.byteLength,duration:1024,Oa:0,flags:{Pa:0,Ha:0,Fa:0,Da:0,Ea:2,Qa:0}}),f+=1024/L.sampleRate*9E4}var ua=
1219
+ L.sampleRate;f=M/9E4*ua;h={id:b.id,type:"audio",codecs:L.fa,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:ua,duration:d,Ma:[],aa:new Uint8Array([]),ka:new Uint8Array([]),data:{$a:this.g,baseMediaDecodeTime:f,Ja:I},stream:b};break;case "ac3":L=[];ua=0;I=new Uint8Array([]);M=null;ia=t(f.Fb());for(var eb=ia.next();!eb.done;eb=ia.next()){var $a=eb.value,xb=$a.data;null==M&&null!==$a.pts&&(M=$a.pts);for(f=0;f<xb.length;){var ab=Gz(xb,f);ab?(b.audioSamplingRate=ab.sampleRate,b.channelsCount=ab.channelCount,
1220
+ ua=ab.sampleRate,I=ab.aa,L.push({data:xb.subarray(f,f+ab.R),size:ab.R,duration:1536,Oa:0,flags:{Pa:0,Ha:0,Fa:0,Da:0,Ea:2,Qa:0}}),f+=ab.R):f++}}if(0==ua||0==I.byteLength||null==M)throw new O(2,3,3018);f=M/9E4*ua;h={id:b.id,type:"audio",codecs:"ac-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:ua,duration:d,Ma:[],aa:I,ka:new Uint8Array([]),data:{$a:this.g,baseMediaDecodeTime:f,Ja:L},stream:b};break;case "ec3":L=[];ua=0;M=new Uint8Array([]);I=null;for(var kh=t(f.Fb()),xd=kh.next();!xd.done;xd=
1218
1221
  kh.next()){var te=xd.value,ue=te.data;null==I&&null!==te.pts&&(I=te.pts);for(f=0;f<ue.length;){var ib=Jz(ue,f);ib?(b.audioSamplingRate=ib.sampleRate,b.channelsCount=ib.channelCount,ua=ib.sampleRate,M=ib.aa,L.push({data:ue.subarray(f,f+ib.R),size:ib.R,duration:1536,Oa:0,flags:{Pa:0,Ha:0,Fa:0,Da:0,Ea:2,Qa:0}}),f+=ib.R):f++}}if(0==ua||0==M.byteLength||null==I)throw new O(2,3,3018);f=I/9E4*ua;h={id:b.id,type:"audio",codecs:"ec-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:ua,duration:d,Ma:[],
1219
- aa:M,ka:new Uint8Array([]),data:{$a:this.g,baseMediaDecodeTime:f,Ja:L},stream:b};break;case "mp3":L=[];var Sh;ua=null;for(var js=t(f.Gb()),hl=js.next();!hl.done;hl=js.next()){var il=hl.value,Hf=il.data;if(Hf)for(null==ua&&null!==il.pts&&(ua=il.pts),f=0;f<Hf.length;){var Be=Tz(Hf,f);Be?(Sh||(Sh=Be),f+Be.R<=Hf.length&&L.push({data:Hf.subarray(f,f+Be.R),size:Be.R,duration:1152,Oa:0,flags:{Pa:0,Ha:0,Fa:0,Da:0,Ea:2,Qa:0}}),f+=Be.R):f++}}if(!Sh||null==ua)throw new O(2,3,3018);var ks=Sh.sampleRate;f=ua/
1222
+ aa:M,ka:new Uint8Array([]),data:{$a:this.g,baseMediaDecodeTime:f,Ja:L},stream:b};break;case "mp3":L=[];var Sh;ua=null;for(var js=t(f.Fb()),hl=js.next();!hl.done;hl=js.next()){var il=hl.value,Hf=il.data;if(Hf)for(null==ua&&null!==il.pts&&(ua=il.pts),f=0;f<Hf.length;){var Ce=Tz(Hf,f);Ce?(Sh||(Sh=Ce),f+Ce.R<=Hf.length&&L.push({data:Hf.subarray(f,f+Ce.R),size:Ce.R,duration:1152,Oa:0,flags:{Pa:0,Ha:0,Fa:0,Da:0,Ea:2,Qa:0}}),f+=Ce.R):f++}}if(!Sh||null==ua)throw new O(2,3,3018);var ks=Sh.sampleRate;f=ua/
1220
1223
  9E4*ks;h={id:b.id,type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:ks,duration:d,Ma:[],aa:new Uint8Array([]),ka:new Uint8Array([]),data:{$a:this.g,baseMediaDecodeTime:f,Ja:L},stream:b}}h&&a.push(h)}}catch(jl){return jl&&3023==jl.code?Promise.resolve(new Uint8Array([])):Promise.reject(jl)}if(!a.length)return Promise.reject(new O(2,3,3018));a=new Xt(a);this.h.has(b.id)?d=this.h.get(b.id):(d=cu(a),this.h.set(b.id,d));b=su(a);this.g++;b=$f(d,b);return Promise.resolve(b)};
1221
1224
  N("shaka.transmuxer.TsTransmuxer",eA);eA.prototype.transmux=eA.prototype.transmux;eA.prototype.getOriginalMimeType=eA.prototype.getOriginalMimeType;eA.prototype.convertCodecs=eA.prototype.convertCodecs;eA.prototype.isSupported=eA.prototype.isSupported;eA.prototype.destroy=eA.prototype.destroy;var fA=["aac","ac-3","ec-3","mp3"],gA=["avc","hevc"];Yb("video/mp2t",function(){return new eA("video/mp2t")},bc);/*
1222
1225
  @license