shaka-player 4.6.13 → 4.6.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/.github/workflows/shaka-bot-commands/lib.sh +37 -12
  2. package/.github/workflows/shaka-bot-commands/main.sh +4 -2
  3. package/.github/workflows/talk-to-shaka-bot.yaml +1 -0
  4. package/AUTHORS +1 -0
  5. package/CHANGELOG.md +26 -0
  6. package/CONTRIBUTORS +1 -0
  7. package/dist/controls.css +1 -1
  8. package/dist/controls.css.map +1 -1
  9. package/dist/deps.js +1 -1
  10. package/dist/locales.js +29 -29
  11. package/dist/shaka-player.compiled.debug.js +91 -89
  12. package/dist/shaka-player.compiled.debug.map +3 -3
  13. package/dist/shaka-player.compiled.js +348 -349
  14. package/dist/shaka-player.compiled.map +3 -3
  15. package/dist/shaka-player.ui.debug.js +105 -103
  16. package/dist/shaka-player.ui.debug.map +3 -3
  17. package/dist/shaka-player.ui.js +433 -434
  18. package/dist/shaka-player.ui.map +3 -3
  19. package/lib/ads/ad_manager.js +1 -1
  20. package/lib/dash/segment_template.js +18 -13
  21. package/lib/deprecate/deprecate.js +1 -1
  22. package/lib/hls/hls_parser.js +24 -5
  23. package/lib/media/manifest_parser.js +3 -2
  24. package/lib/media/segment_reference.js +4 -1
  25. package/lib/media/streaming_engine.js +2 -2
  26. package/lib/player.js +3 -3
  27. package/lib/polyfill/mediasource.js +5 -36
  28. package/lib/text/vtt_text_parser.js +2 -1
  29. package/lib/util/error.js +1 -0
  30. package/lib/util/periods.js +23 -1
  31. package/lib/util/stream_utils.js +1 -1
  32. package/lib/util/ts_parser.js +2 -2
  33. package/package.json +3 -3
  34. package/test/dash/dash_parser_segment_template_unit.js +1 -1
  35. package/test/hls/hls_parser_unit.js +28 -0
  36. package/test/media/buffering_observer_unit.js +13 -0
  37. package/test/player_integration.js +9 -1
  38. package/test/player_load_graph_integration.js +13 -10
  39. package/test/player_src_equals_integration.js +2 -2
  40. package/test/player_unit.js +9 -3
  41. package/test/test/assets/hls-ts-h265/index.m3u8 +2 -0
  42. package/test/test/assets/hls-ts-muxed-aac-h265/media.m3u8 +5 -1
  43. package/test/test/util/waiter.js +5 -0
  44. package/test/text/vtt_text_parser_unit.js +31 -0
  45. package/test/transmuxer/transmuxer_integration.js +22 -53
  46. package/test/util/periods_unit.js +64 -0
  47. package/ui/less/containers.less +1 -0
@@ -31,10 +31,10 @@ while(!k.done)})};return b});function Ia(a,b){return Object.prototype.hasOwnProp
31
31
  ha("WeakMap",function(a){function b(k){this.g=(h+=Math.random()+1).toString();if(k){k=t(k);for(var l;!(l=k.next()).done;)l=l.value,this.set(l[0],l[1])}}function c(){}function d(k){var l=typeof k;return"object"===l&&null!==k||"function"===l}function e(k){if(!Ia(k,g)){var l=new c;ba(k,g,{value:l})}}function f(k){var l=Object[k];l&&(Object[k]=function(m){if(m instanceof c)return m;Object.isExtensible(m)&&e(m);return l(m)})}if(function(){if(!a||!Object.seal)return!1;try{var k=Object.seal({}),l=Object.seal({}),
32
32
  m=new a([[k,2],[l,3]]);if(2!=m.get(k)||3!=m.get(l))return!1;m.delete(k);m.set(l,4);return!m.has(k)&&4==m.get(l)}catch(n){return!1}}())return a;var g="$jscomp_hidden_"+Math.random();f("freeze");f("preventExtensions");f("seal");var h=0;b.prototype.set=function(k,l){if(!d(k))throw Error("Invalid WeakMap key");e(k);if(!Ia(k,g))throw Error("WeakMap key fail: "+k);k[g][this.g]=l;return this};b.prototype.get=function(k){return d(k)&&Ia(k,g)?k[g][this.g]:void 0};b.prototype.has=function(k){return d(k)&&Ia(k,
33
33
  g)&&Ia(k[g],this.g)};b.prototype.delete=function(k){return d(k)&&Ia(k,g)&&Ia(k[g],this.g)?delete k[g][this.g]:!1};return b});
34
- ha("Map",function(a){function b(){var h={};return h.Nb=h.next=h.head=h}function c(h,k){var l=h.g;return ia(function(){if(l){for(;l.head!=h.g;)l=l.Nb;for(;l.next!=l.head;)return l=l.next,{done:!1,value:k(l)};l=null}return{done:!0,value:void 0}})}function d(h,k){var l=k&&typeof k;"object"==l||"function"==l?f.has(k)?l=f.get(k):(l=""+ ++g,f.set(k,l)):l="p_"+k;var m=h.h[l];if(m&&Ia(h.h,l))for(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,
34
+ ha("Map",function(a){function b(){var h={};return h.Pb=h.next=h.head=h}function c(h,k){var l=h.g;return ia(function(){if(l){for(;l.head!=h.g;)l=l.Pb;for(;l.next!=l.head;)return l=l.next,{done:!1,value:k(l)};l=null}return{done:!0,value:void 0}})}function d(h,k){var l=k&&typeof k;"object"==l||"function"==l?f.has(k)?l=f.get(k):(l=""+ ++g,f.set(k,l)):l="p_"+k;var m=h.h[l];if(m&&Ia(h.h,l))for(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
35
  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||
36
- "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,Nb:this.g.Nb,head:this.g,key:h,value:k},l.list.push(l.entry),this.g.Nb.next=l.entry,this.g.Nb=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.Nb.next=h.entry.next,
37
- h.entry.next.Nb=h.entry.Nb,h.entry.head=null,this.size--,!0):!1};e.prototype.clear=function(){this.h={};this.g=this.g.Nb=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=
36
+ "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,Pb:this.g.Pb,head:this.g,key:h,value:k},l.list.push(l.entry),this.g.Pb.next=l.entry,this.g.Pb=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.Pb.next=h.entry.next,
37
+ h.entry.next.Pb=h.entry.Pb,h.entry.head=null,this.size--,!0):!1};e.prototype.clear=function(){this.h={};this.g=this.g.Pb=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=
38
38
  function(h,k){for(var l=this.entries(),m;!(m=l.next()).done;)m=m.value,h.call(k,m[1],m[0],this)};e.prototype[Symbol.iterator]=e.prototype.entries;var g=0;return e});function Ja(a,b){a instanceof String&&(a+="");var c=0,d=!1,e={next:function(){if(!d&&c<a.length){var f=c++;return{value:b(f,a[f]),done:!1}}d=!0;return{done:!0,value:void 0}}};e[Symbol.iterator]=function(){return e};return e}ha("Array.prototype.keys",function(a){return a?a:function(){return Ja(this,function(b){return b})}});
39
39
  ha("Set",function(a){function b(c){this.g=new Map;if(c){c=t(c);for(var d;!(d=c.next()).done;)this.add(d.value)}this.size=this.g.size}if(function(){if(!a||"function"!=typeof a||!a.prototype.entries||"function"!=typeof Object.seal)return!1;try{var c=Object.seal({x:4}),d=new a(t([c]));if(!d.has(c)||1!=d.size||d.add(c)!=d||1!=d.size||d.add({x:4})!=d||2!=d.size)return!1;var e=d.entries(),f=e.next();if(f.done||f.value[0]!=c||f.value[1]!=c)return!1;f=e.next();return f.done||f.value[0]==c||4!=f.value[0].x||
40
40
  f.value[1]!=f.value[0]?!1:e.next().done}catch(g){return!1}}())return a;b.prototype.add=function(c){c=0===c?0:c;this.g.set(c,c);this.size=this.g.size;return this};b.prototype.delete=function(c){c=this.g.delete(c);this.size=this.g.size;return c};b.prototype.clear=function(){this.g.clear();this.size=0};b.prototype.has=function(c){return this.g.has(c)};b.prototype.entries=function(){return this.g.entries()};b.prototype.values=function(){return this.g.values()};b.prototype.keys=b.prototype.values;b.prototype[Symbol.iterator]=
@@ -68,10 +68,10 @@ var fb=RegExp("^(?:([^:/?#.]+):)?(?://(?:([^/?#]*)@)?([^/#?]*?)(?::([0-9]+))?(?=
68
68
  Copyright 2006 The Closure Library Authors
69
69
  SPDX-License-Identifier: Apache-2.0
70
70
  */
71
- function gb(a){var b;a instanceof gb?(jb(this,a.vb),this.vc=a.vc,kb(this,a.Ib),nb(this,a.Pc),this.Wa=a.Wa,ob(this,a.g.clone()),this.ic=a.ic):a&&(b=String(a).match(fb))?(jb(this,b[1]||"",!0),this.vc=pb(b[2]||""),kb(this,b[3]||"",!0),nb(this,b[4]),this.Wa=pb(b[5]||"",!0),ob(this,b[6]||"",!0),this.ic=pb(b[7]||"")):this.g=new qb(null)}p=gb.prototype;p.vb="";p.vc="";p.Ib="";p.Pc=null;p.Wa="";p.ic="";
72
- p.toString=function(){var a=[],b=this.vb;b&&a.push(rb(b,tb,!0),":");if(b=this.Ib){a.push("//");var c=this.vc;c&&a.push(rb(c,tb,!0),"@");a.push(encodeURIComponent(b).replace(/%25([0-9a-fA-F]{2})/g,"%$1"));b=this.Pc;null!=b&&a.push(":",String(b))}if(b=this.Wa)this.Ib&&"/"!=b.charAt(0)&&a.push("/"),a.push(rb(b,"/"==b.charAt(0)?ub:vb,!0));(b=this.g.toString())&&a.push("?",b);(b=this.ic)&&a.push("#",rb(b,wb));return a.join("")};
71
+ function gb(a){var b;a instanceof gb?(jb(this,a.vb),this.vc=a.vc,kb(this,a.Ib),nb(this,a.Pc),this.Wa=a.Wa,ob(this,a.g.clone()),this.jc=a.jc):a&&(b=String(a).match(fb))?(jb(this,b[1]||"",!0),this.vc=pb(b[2]||""),kb(this,b[3]||"",!0),nb(this,b[4]),this.Wa=pb(b[5]||"",!0),ob(this,b[6]||"",!0),this.jc=pb(b[7]||"")):this.g=new qb(null)}p=gb.prototype;p.vb="";p.vc="";p.Ib="";p.Pc=null;p.Wa="";p.jc="";
72
+ p.toString=function(){var a=[],b=this.vb;b&&a.push(rb(b,tb,!0),":");if(b=this.Ib){a.push("//");var c=this.vc;c&&a.push(rb(c,tb,!0),"@");a.push(encodeURIComponent(b).replace(/%25([0-9a-fA-F]{2})/g,"%$1"));b=this.Pc;null!=b&&a.push(":",String(b))}if(b=this.Wa)this.Ib&&"/"!=b.charAt(0)&&a.push("/"),a.push(rb(b,"/"==b.charAt(0)?ub:vb,!0));(b=this.g.toString())&&a.push("?",b);(b=this.jc)&&a.push("#",rb(b,wb));return a.join("")};
73
73
  p.resolve=function(a){var b=this.clone();"data"===b.vb&&(b=new gb);var c=!!a.vb;c?jb(b,a.vb):c=!!a.vc;c?b.vc=a.vc:c=!!a.Ib;c?kb(b,a.Ib):c=null!=a.Pc;var d=a.Wa;if(c)nb(b,a.Pc);else if(c=!!a.Wa){if("/"!=d.charAt(0))if(this.Ib&&!this.Wa)d="/"+d;else{var e=b.Wa.lastIndexOf("/");-1!=e&&(d=b.Wa.substr(0,e+1)+d)}if(".."==d||"."==d)d="";else if(-1!=d.indexOf("./")||-1!=d.indexOf("/.")){e=0==d.lastIndexOf("/",0);d=d.split("/");for(var f=[],g=0;g<d.length;){var h=d[g++];"."==h?e&&g==d.length&&f.push(""):".."==
74
- h?((1<f.length||1==f.length&&""!=f[0])&&f.pop(),e&&g==d.length&&f.push("")):(f.push(h),e=!0)}d=f.join("/")}}c?b.Wa=d:c=""!==a.g.toString();c?ob(b,a.g.clone()):c=!!a.ic;c&&(b.ic=a.ic);return b};p.clone=function(){return new gb(this)};function jb(a,b,c){a.vb=c?pb(b,!0):b;a.vb&&(a.vb=a.vb.replace(/:$/,""))}function kb(a,b,c){a.Ib=c?pb(b,!0):b}function nb(a,b){if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.Pc=b}else a.Pc=null}
74
+ h?((1<f.length||1==f.length&&""!=f[0])&&f.pop(),e&&g==d.length&&f.push("")):(f.push(h),e=!0)}d=f.join("/")}}c?b.Wa=d:c=""!==a.g.toString();c?ob(b,a.g.clone()):c=!!a.jc;c&&(b.jc=a.jc);return b};p.clone=function(){return new gb(this)};function jb(a,b,c){a.vb=c?pb(b,!0):b;a.vb&&(a.vb=a.vb.replace(/:$/,""))}function kb(a,b,c){a.Ib=c?pb(b,!0):b}function nb(a,b){if(b){b=Number(b);if(isNaN(b)||0>b)throw Error("Bad port number "+b);a.Pc=b}else a.Pc=null}
75
75
  function ob(a,b,c){b instanceof qb?a.g=b:(c||(b=rb(b,xb)),a.g=new qb(b))}function pb(a,b){return a?b?decodeURI(a):decodeURIComponent(a):""}function rb(a,b,c){return null!=a?(a=encodeURI(a).replace(b,yb),c&&(a=a.replace(/%25([0-9a-fA-F]{2})/g,"%$1")),a):null}function yb(a){a=a.charCodeAt(0);return"%"+(a>>4&15).toString(16)+(a&15).toString(16)}var tb=/[#\/\?@]/g,vb=/[#\?:]/g,ub=/[#\?]/g,xb=/[#\?@]/g,wb=/#/g;function qb(a){this.g=a||null}
76
76
  function zb(a){if(!a.Na&&(a.Na={},a.nd=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," ")))}}p=qb.prototype;p.Na=null;p.nd=null;function Ab(a){zb(a);return a.nd}p.add=function(a,b){zb(this);this.g=null;var c=this.Na.hasOwnProperty(a)?this.Na[a]:null;c||(this.Na[a]=c=[]);c.push(b);this.nd++;return this};
77
77
  p.set=function(a,b){zb(this);this.g=null;this.Na.hasOwnProperty(a)?this.Na[a]=[b]:this.add(a,b);return this};p.get=function(a){zb(this);return this.Na[a]||[]};p.toString=function(){if(this.g)return this.g;if(!this.Na)return"";var a=[],b;for(b in this.Na)for(var c=encodeURIComponent(b),d=this.Na[b],e=0;e<d.length;e++){var f=c;""!==d[e]&&(f+="="+encodeURIComponent(d[e]));a.push(f)}return this.g=a.join("&")};
@@ -107,7 +107,7 @@ function lc(a,b,c){c=void 0===c?Infinity:c;return nc(a,void 0===b?0:b,c,Uint8Arr
107
107
  M("shaka.util.BufferUtils",ic);ic.toDataView=pc;ic.toUint16=oc;ic.toUint8=lc;ic.toArrayBuffer=mc;ic.equal=jc;function qc(){}qc.prototype.init=function(){};qc.prototype.i=function(){};qc.prototype.h=function(){};qc.prototype.j=function(){};M("shaka.media.IClosedCaptionParser",qc);function rc(a){this.l=new hc;if(a=sc[a.toLowerCase()])this.l=a();this.g=new gc;if(a=tc)this.g=a()}rc.prototype.init=function(a){this.l.init(a)};rc.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=lc(b.packet);0<c.length&&this.g.extract(c,b.pts)}return this.g.decode()};
108
108
  rc.prototype.h=function(){this.g.clear()};rc.prototype.j=function(){return this.g.getStreams()};M("shaka.media.ClosedCaptionParser",rc);rc.findDecoder=function(){return tc};rc.unregisterDecoder=function(){tc=null};rc.registerDecoder=function(a){tc=a};rc.findParser=function(a){return sc[a]};rc.unregisterParser=function(a){delete sc[a]};rc.registerParser=function(a,b){sc[a]=b};var sc={},tc=null;function uc(a,b){return"number"===typeof a&&"number"===typeof b&&isNaN(a)&&isNaN(b)?!0:a===b}function vc(a,b){b=a.indexOf(b);-1<b&&a.splice(b,1)}function wc(a,b,c){c||(c=uc);if(a.length!=b.length)return!1;b=b.slice();var d={};a=t(a);for(var e=a.next();!e.done;d={Ne:d.Ne},e=a.next()){d.Ne=e.value;e=b.findIndex(function(f){return function(g){return c(f.Ne,g)}}(d));if(-1==e)return!1;b[e]=b[b.length-1];b.pop()}return 0==b.length}
109
109
  function xc(a,b,c){c||(c=uc);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 yc(a,b,c){this.startTime=a;this.endTime=b;this.payload=c;this.region=new zc;this.position=null;this.positionAlign=Ac;this.size=0;this.textAlign=Bc;this.direction=Cc;this.writingMode=Dc;this.lineInterpretation=Ec;this.line=null;this.lineHeight="";this.lineAlign=Fc;this.displayAlign=Gc;this.fontSize=this.border=this.backgroundImage=this.backgroundColor=this.color="";this.fontWeight=Hc;this.fontStyle=Ic;this.linePadding=this.letterSpacing=this.fontFamily="";this.opacity=1;this.textCombineUpright=
110
- "";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={hc:32,rows:15}}function Jc(a,b){a=new yc(a,b,"");a.lineBreak=!0;return a}yc.prototype.clone=function(){var a=new yc(0,0,""),b;for(b in this)a[b]=this[b],a[b]&&a[b].constructor==Array&&(a[b]=a[b].slice());return a};
110
+ "";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={ic:32,rows:15}}function Jc(a,b){a=new yc(a,b,"");a.lineBreak=!0;return a}yc.prototype.clone=function(){var a=new yc(0,0,""),b;for(b in this)a[b]=this[b],a[b]&&a[b].constructor==Array&&(a[b]=a[b].slice());return a};
111
111
  function Kc(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(!xc(a.nestedCues,b.nestedCues,Kc))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(!xc(a[c],b[c]))return!1}else if(a[c]!=b[c])return!1;return!0}M("shaka.text.Cue",yc);yc.equal=Kc;yc.prototype.clone=yc.prototype.clone;var Ac="auto";
112
112
  yc.positionAlign={LEFT:"line-left",RIGHT:"line-right",CENTER:"center",AUTO:Ac};var Bc="center",Lc={LEFT:"left",RIGHT:"right",CENTER:Bc,START:"start",END:"end"};yc.textAlign=Lc;var Gc="after",Mc={BEFORE:"before",CENTER:"center",AFTER:Gc};yc.displayAlign=Mc;var Cc="ltr";yc.direction={HORIZONTAL_LEFT_TO_RIGHT:Cc,HORIZONTAL_RIGHT_TO_LEFT:"rtl"};var Dc="horizontal-tb";yc.writingMode={HORIZONTAL_TOP_TO_BOTTOM:Dc,VERTICAL_LEFT_TO_RIGHT:"vertical-lr",VERTICAL_RIGHT_TO_LEFT:"vertical-rl"};var Ec=0;
113
113
  yc.lineInterpretation={LINE_NUMBER:Ec,PERCENTAGE:1};var Fc="start",Nc={CENTER:"center",START:Fc,END:"end"};yc.lineAlign=Nc;var Oc={white:"white",lime:"lime",cyan:"cyan",red:"red",yellow:"yellow",magenta:"magenta",blue:"blue",black:"black"};yc.defaultTextColor=Oc;var Pc={bg_white:"white",bg_lime:"lime",bg_cyan:"cyan",bg_red:"red",bg_yellow:"yellow",bg_magenta:"magenta",bg_blue:"blue",bg_black:"black"};yc.defaultTextBackgroundColor=Pc;var Hc=400;yc.fontWeight={NORMAL:Hc,BOLD:700};
@@ -138,10 +138,10 @@ function be(a,b){var c,d,e;return K(function(f){switch(f.g){case 1:c=ae(b);ta(f,
138
138
  function Xd(a,b,c,d){var e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B;return K(function(C){switch(C.g){case 1:if(e=a.some(function(E){return E.decodingInfos.length}))return C.return();f={};g=t(d);h=g.next();case 2:if(h.done){C.F(4);break}f.Pe=h.value;k=!1;l=t(a);m=l.next();case 5:if(m.done){C.F(7);break}n=m.value;q=de(n,b,c).filter(function(E){return function(H){return(H.keySystemConfiguration&&H.keySystemConfiguration.keySystem)===E.Pe}}(f));r=t(q);u=r.next();case 8:if(u.done){C.F(10);break}v=u.value;return D(C,
139
139
  be(n,v),9);case 9:u=r.next();C.F(8);break;case 10:n.decodingInfos.length&&(k=!0);m=l.next();C.F(5);break;case 7:if(k)return C.return();f={Pe:f.Pe};h=g.next();C.F(2);break;case 4:y=t(a),m=y.next();case 12:if(m.done){C.F(0);break}z=m.value;x=de(z,b,c).filter(function(E){E=E.keySystemConfiguration&&E.keySystemConfiguration.keySystem;return!E||!d.includes(E)});A=t(x);u=A.next();case 15:if(u.done){m=y.next();C.F(12);break}B=u.value;return D(C,be(z,B),16);case 16:u=A.next(),C.F(15)}})}
140
140
  function de(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=Eb("video",g);f=Zd(f);g=Eb("audio",g);g=$d(g);g=ed(e.mimeType,g,"audio");c.audio={contentType:g,channels:2,bitrate:a.bandwidth||1,samplerate:1,spatialRendering:!1}}f=Zd(f);f=ed(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=
141
- "srgb";break;case "PQ":c.video.transferFunction="pq";break;case "HLG":c.video.transferFunction="hlg"}}d&&(f=ed(d.mimeType,$d(d.codecs),"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,
141
+ "srgb";break;case "PQ":c.video.transferFunction="pq";break;case "HLG":c.video.transferFunction="hlg"}}d&&(f=$d(d.codecs),f=ed(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,
142
142
  []);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 q=new Set,r=t(h.initData),u=r.next();!u.done;u=r.next())q.add(u.value.initDataType);m.initDataType=h.initData[0].initDataType}h.distinctiveIdentifierRequired&&
143
143
  (m.distinctiveIdentifier="required");h.persistentStateRequired&&(m.persistentState="required");h.sessionType&&(m.sessionTypes=[h.sessionType]);d&&(""!=h.audioRobustness?m.audio?m.audio.robustness=m.audio.robustness||h.audioRobustness:m.audio={robustness:h.audioRobustness}:m.audio||(m.audio={}));e&&(""!=h.videoRobustness?m.video?m.video.robustness=m.video.robustness||h.videoRobustness:m.video={robustness:h.videoRobustness}:m.video||(m.video={}))}l.keySystemConfiguration=m;a.push(l)}return a}
144
- function $d(a){return"fLaC"===a?"flac":"Opus"===a?"opus":a}function Zd(a){if(a.includes("avc1")){var b=a.split(".");if(3==b.length)return a=b.shift()+".",a+=parseInt(b.shift(),10).toString(16),a+=("000"+parseInt(b.shift(),10).toString(16)).slice(-4)}else if("vp9"==a)return"vp09.00.41.08";return a}function Vd(a){a.textStreams=a.textStreams.filter(function(b){b=bd(b.mimeType,b.codecs);return kd(b)})}
144
+ function $d(a){return"fLaC"!==a||Jd()?"Opus"===a?"opus":a:"flac"}function Zd(a){if(a.includes("avc1")){var b=a.split(".");if(3==b.length)return a=b.shift()+".",a+=parseInt(b.shift(),10).toString(16),a+=("000"+parseInt(b.shift(),10).toString(16)).slice(-4)}else if("vp9"==a)return"vp09.00.41.08";return a}function Vd(a){a.textStreams=a.textStreams.filter(function(b){b=bd(b.mimeType,b.codecs);return kd(b)})}
145
145
  function Wd(a){var b,c,d,e,f,g,h,k;return K(function(l){switch(l.g){case 1:b=[],c=t(a.imageStreams),d=c.next();case 2:if(d.done){l.F(4);break}e=d.value;f=e.mimeType;"application/mp4"==f&&"mjpg"==e.codecs&&(f="image/jpg");if(ee.has(f)){l.F(5);break}g=fe.get(f);if(!g){ee.set(f,!1);l.F(5);break}return D(l,ge(g),7);case 7:h=l.h,ee.set(f,h);case 5:(k=ee.get(f))&&b.push(e);d=c.next();l.F(2);break;case 4:a.imageStreams=b,F(l)}})}
146
146
  function ge(a){return new Promise(function(b){var c=new Image;c.src=a;"decode"in c?c.decode().then(function(){b(!0)}).catch(function(){b(!1)}):c.onload=c.onerror=function(){b(2===c.height)}})}
147
147
  function he(a){var b=a.audio,c=a.video,d=b?b.mimeType:null,e=c?c.mimeType:null,f=b?b.codecs:null,g=c?c.codecs:null,h=[];g&&h.push(g);f&&h.push(f);var k=[];c&&k.push(c.mimeType);b&&k.push(b.mimeType);k=k[0]||null;var l=[];b&&l.push(b.kind);c&&l.push(c.kind);l=l[0]||null;var m=new Set;if(b)for(var n=t(b.roles),q=n.next();!q.done;q=n.next())m.add(q.value);if(c)for(n=t(c.roles),q=n.next();!q.done;q=n.next())m.add(q.value);a={id:a.id,active:!1,type:"variant",bandwidth:a.bandwidth,language:a.language,label:null,
@@ -167,19 +167,19 @@ p.segmentDownloaded=function(a,b,c){this.i.sample(a,b);if(c&&null!=this.u&&this.
167
167
  p.setMediaElement=function(a){var b=this;this.j=a;this.h&&(this.h.disconnect(),this.h=null);this.j&&"ResizeObserver"in window&&(this.h=new ResizeObserver(function(){b.G.T(ye)}),this.h.observe(this.j))};p.configure=function(a){this.g=a;this.i&&this.g&&this.i.configure(this.g.advanced)};function xe(a){var b=a.g.defaultBandwidthEstimate;navigator.connection&&navigator.connection.downlink&&a.g.useNetworkInformation&&(b=1E6*navigator.connection.downlink);return b}
168
168
  function ve(a,b,c,d){a&&(b=b.filter(function(e){return Rd(e,a,{width:d,height:c})}));return b.sort(function(e,f){return e.bandwidth-f.bandwidth})}function we(a){var b=[];a=t(a);for(var c=a.next();!c.done;c=a.next())(c=c.value.video)&&c.height&&c.width&&b.push({height:c.height,width:c.width});return b.sort(function(d,e){return d.width-e.width})}M("shaka.abr.SimpleAbrManager",ue);ue.prototype.configure=ue.prototype.configure;ue.prototype.setMediaElement=ue.prototype.setMediaElement;
169
169
  ue.prototype.playbackRateChanged=ue.prototype.playbackRateChanged;ue.prototype.setVariants=ue.prototype.setVariants;ue.prototype.getBandwidthEstimate=ue.prototype.getBandwidthEstimate;ue.prototype.segmentDownloaded=ue.prototype.segmentDownloaded;ue.prototype.disable=ue.prototype.disable;ue.prototype.enable=ue.prototype.enable;ue.prototype.chooseVariant=ue.prototype.chooseVariant;ue.prototype.init=ue.prototype.init;ue.prototype.release=ue.prototype.release;ue.prototype.stop=ue.prototype.stop;
170
- var ye=1;function ze(a,b){this.g=a;this.h=b}ze.prototype.toString=function(){return"v"+this.g+"."+this.h};function Ae(a,b){var c=new ze(5,0),d=Be,e=d.g,f=c.h-e.h;(0<(c.g-e.g||f)?d.i:d.h)(d.g,c,a,b)}function Ce(a,b,c,d){Sa([c,"has been deprecated and will be removed in",b,". We are currently at version",a,". Additional information:",d].join(" "))}function De(a,b,c,d){Ra([c,"has been deprecated and has been removed in",b,". We are now at version",a,". Additional information:",d].join(""))}var Be=null;M("shaka.config.AutoShowText",{NEVER:0,ALWAYS:1,IF_PREFERRED_TEXT_LANGUAGE:2,IF_SUBTITLES_MAY_BE_NEEDED:3});M("shaka.config.CodecSwitchingStrategy",{Nj:"reload",rh:"smooth"});function Ee(a,b,c,d){c=void 0===c?!0:c;d=void 0===d?!1:d;this.h=a;this.g=new Set([a]);b=b||[];a=t(b);for(b=a.next();!b.done;b=a.next())this.add(b.value,c,d)}Ee.prototype.add=function(a,b,c){return Fe(this.h,a,void 0===b?!0:b,void 0===c?!1:c)?(this.g.add(a),!0):!1};
170
+ var ye=1;function ze(a,b){this.g=a;this.h=b}ze.prototype.toString=function(){return"v"+this.g+"."+this.h};function Ae(a,b){var c=new ze(5,0),d=Be,e=d.g,f=c.h-e.h;(0<(c.g-e.g||f)?d.i:d.h)(d.g,c,a,b)}function Ce(a,b,c,d){Sa([c,"has been deprecated and will be removed in",b,". We are currently at version",a,". Additional information:",d].join(" "))}function De(a,b,c,d){Ra([c,"has been deprecated and has been removed in",b,". We are now at version",a,". Additional information:",d].join(" "))}var Be=null;M("shaka.config.AutoShowText",{NEVER:0,ALWAYS:1,IF_PREFERRED_TEXT_LANGUAGE:2,IF_SUBTITLES_MAY_BE_NEEDED:3});M("shaka.config.CodecSwitchingStrategy",{Nj:"reload",rh:"smooth"});function Ee(a,b,c,d){c=void 0===c?!0:c;d=void 0===d?!1:d;this.h=a;this.g=new Set([a]);b=b||[];a=t(b);for(b=a.next();!b.done;b=a.next())this.add(b.value,c,d)}Ee.prototype.add=function(a,b,c){return Fe(this.h,a,void 0===b?!0:b,void 0===c?!1:c)?(this.g.add(a),!0):!1};
171
171
  function Fe(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&&!Ge(e,f)||!He(e.roles,f.roles)||d&&e.groupId!==f.groupId)}!(d=e)&&(d=a.video&&b.video)&&(a=a.video,b=b.video,d=!((!c||Ge(a,b))&&He(a.roles,b.roles)));return d?!1:!0}Ee.prototype.values=function(){return this.g.values()};
172
172
  function Ge(a,b){if(a.mimeType!=b.mimeType)return!1;a=a.codecs.split(",").map(function(d){return gd(d)[0]});b=b.codecs.split(",").map(function(d){return gd(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 He(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 Ie(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 Je(a.language,"",a.audio&&a.audio.channelsCount?a.audio.channelsCount:0,"","","",b,c)}Ie.prototype.create=function(a){var b=this,c="smooth"==this.h&&fc(),d=a.filter(function(e){return Fe(b.i,e,!c,b.g)});return d.length?new Ee(d[0],d,!c,this.g):this.j.create(a)};
173
173
  function Je(a,b,c,d,e,f,g,h){this.s=a;this.u=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}
174
- Je.prototype.create=function(a){var b=[];b=Ke(a,this.s);var c=a.filter(function(d){return d.primary});b=b.length?b:c.length?c:a;a=Le(b,this.u);a.length&&(b=a);this.j&&(a=Oe(b,this.j),a.length&&(b=a));this.h&&(a=Pe(b,this.h),a.length&&(b=a));this.g&&(a=Qe(b,this.g),a.length&&(b=a));this.i&&(a=Re(b,this.i),a.length&&(b=a));return new Ee(b[0],b,!("smooth"==this.l&&fc()),this.m)};function Ke(a,b){b=Nb(b);var c=Vb(b,a.map(function(d){return Ub(d)}));return c?a.filter(function(d){return c==Ub(d)}):[]}
174
+ Je.prototype.create=function(a){var b=[];b=Ke(a,this.s);var c=a.filter(function(d){return d.primary});b=b.length?b:c.length?c:a;a=Le(b,this.u);a.length&&(b=a);this.j&&(a=Me(b,this.j),a.length&&(b=a));this.h&&(a=Ne(b,this.h),a.length&&(b=a));this.g&&(a=Qe(b,this.g),a.length&&(b=a));this.i&&(a=Re(b,this.i),a.length&&(b=a));return new Ee(b[0],b,!("smooth"==this.l&&fc()),this.m)};function Ke(a,b){b=Nb(b);var c=Vb(b,a.map(function(d){return Ub(d)}));return c?a.filter(function(d){return c==Ub(d)}):[]}
175
175
  function Le(a,b){return a.filter(function(c){return c.audio?b?c.audio.roles.includes(b):0==c.audio.roles.length:!1})}function Re(a,b){return a.filter(function(c){return c.audio&&c.audio.label?c.audio.label.toLowerCase()==b.toLowerCase():!1})}function Qe(a,b){return a.filter(function(c){return c.audio&&c.audio.channelsCount&&c.audio.channelsCount!=b?!1:!0})}
176
- function Pe(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 Oe(a,b){return a.filter(function(c){return c.video&&c.video.videoLayout&&c.video.videoLayout!=b?!1:!0})};function Se(){this.g=Te;this.h=(new Map).set(Te,2).set(Ue,1)}function We(a,b,c){a.h.set(Te,c).set(Ue,b)}var Ue=0,Te=1;function Xe(a,b){var c=Ye();this.l=null==a.maxAttempts?c.maxAttempts:a.maxAttempts;this.j=null==a.baseDelay?c.baseDelay:a.baseDelay;this.s=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}
176
+ function Ne(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 Me(a,b){return a.filter(function(c){return c.video&&c.video.videoLayout&&c.video.videoLayout!=b?!1:!0})};function Se(){this.g=Te;this.h=(new Map).set(Te,2).set(Ue,1)}function Ve(a,b,c){a.h.set(Te,c).set(Ue,b)}var Ue=0,Te=1;function We(a,b){var c=Ye();this.l=null==a.maxAttempts?c.maxAttempts:a.maxAttempts;this.j=null==a.baseDelay?c.baseDelay:a.baseDelay;this.s=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}
177
177
  function Ze(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 P(2,7,1010);b=a.g;a.g++;if(0==b)return d.return();c=a.h*(1+(2*Math.random()-1)*a.s);return D(d,new Promise(function(e){(new vd(e)).T(c/1E3)}),2)}a.h*=a.m;F(d)})}function Ye(){return{maxAttempts:2,baseDelay:1E3,backoffFactor:2,fuzzFactor:.5,timeout:3E4,stallTimeout:5E3,connectionTimeout:1E4}};function $e(){var a,b,c=new Promise(function(d,e){a=d;b=e});c.resolve=a;c.reject=b;return c}$e.prototype.resolve=function(){};$e.prototype.reject=function(){};function af(a,b){this.promise=a;this.i=b;this.g=!1}function bf(a){return new af(Promise.reject(a),function(){return Promise.resolve()})}function cf(){var a=Promise.reject(new P(2,7,7001));a.catch(function(){});return new af(a,function(){return Promise.resolve()})}function df(a){return new af(Promise.resolve(a),function(){return Promise.resolve()})}function ef(a){return new af(a,function(){return a.catch(function(){})})}af.prototype.abort=function(){this.g=!0;return this.i()};
178
178
  function ff(a){return new af(Promise.all(a.map(function(b){return b.promise})),function(){return Promise.all(a.map(function(b){return b.abort()}))})}af.prototype.finally=function(a){this.promise.then(function(){return a(!0)},function(){return a(!1)});return this};
179
179
  af.prototype.Da=function(a,b){function c(h){return function(k){if(e.g&&h)f.reject(g);else{var l=h?a:b;l?d=gf(l,k,f):(h?f.resolve:f.reject)(k)}}}function d(){f.reject(g);return e.abort()}var e=this,f=new $e,g=new P(2,7,7001);this.promise.then(c(!0),c(!1));return new af(f,function(){return d()})};
180
180
  function gf(a,b,c){try{var d=a(b);if(d&&d.promise&&d.abort)return c.resolve(d.promise),function(){return d.abort()};c.resolve(d);return function(){return Promise.resolve(d).then(function(){},function(){})}}catch(e){return c.reject(e),function(){return Promise.resolve()}}}M("shaka.util.AbortableOperation",af);af.prototype.chain=af.prototype.Da;af.prototype["finally"]=af.prototype.finally;af.all=ff;af.prototype.abort=af.prototype.abort;af.notAbortable=ef;af.completed=df;af.aborted=cf;af.failed=bf;function hf(a){function b(d){switch(typeof d){case "undefined":case "boolean":case "number":case "string":case "symbol":case "function":return d;default:if(!d||d.buffer&&d.buffer.constructor==ArrayBuffer)return d;if(c.has(d))return null;var e=d.constructor==Array;if(d.constructor!=Object&&!e)return null;c.add(d);var f=e?[]:{},g;for(g in d)f[g]=b(d[g]);e&&(f.length=d.length);return f}}var c=new WeakSet;return b(a)}function jf(a){var b={},c;for(c in a)b[c]=a[c];return b};function kf(){this.g=[]}function lf(a,b){a.g.push(b.finally(function(){vc(a.g,b)}))}kf.prototype.destroy=function(){for(var a=[],b=t(this.g),c=b.next();!c.done;c=b.next())c=c.value,c.promise.catch(function(){}),a.push(c.abort());this.g=[];return Promise.all(a)};function mf(a,b,c,d,e){ab.call(this);this.i=!1;this.m=new kf;this.g=new Set;this.h=new Set;this.l=a||null;this.j=b||null;this.u=c||null;this.C=d||null;this.D=e||null;this.s=!1}pa(mf,ab);p=mf.prototype;p.gg=function(a){this.s=a};function nf(a,b,c,d){c=c||of;var e=pf[a];if(!e||c>=e.priority)pf[a]={priority:c,Ae:b,Oi:void 0===d?!1:d}}p.Pi=function(a){this.g.add(a)};p.ij=function(a){this.g.delete(a)};p.Bh=function(){this.g.clear()};p.Qi=function(a){this.h.add(a)};p.jj=function(a){this.h.delete(a)};
181
181
  p.Ch=function(){this.h.clear()};function qf(a,b,c){return{uris:a,method:"GET",body:null,headers:{},allowCrossSiteCredentials:!1,retryParameters:b,licenseRequestType:null,sessionId:null,drmInfo:null,initData:null,initDataType:null,streamDataCallback:void 0===c?null:c}}p.destroy=function(){this.i=!0;this.g.clear();this.h.clear();ab.prototype.release.call(this);return this.m.destroy()};
182
- p.request=function(a,b,c){var d=this,e=new rf;if(this.i){var f=Promise.reject(new P(2,7,7001));f.catch(function(){});return new sf(f,function(){return Promise.resolve()},e)}b.method=b.method||"GET";b.headers=b.headers||{};b.retryParameters=b.retryParameters?hf(b.retryParameters):Ye();b.uris=hf(b.uris);f=tf(this,a,b,c);var g=f.Da(function(){return uf(d,a,b,c,new Xe(b.retryParameters,!1),0,null,e)}),h=g.Da(function(q){return vf(d,a,q,c)}),k=Date.now(),l=0;f.promise.then(function(){l=Date.now()-k},function(){});
182
+ p.request=function(a,b,c){var d=this,e=new rf;if(this.i){var f=Promise.reject(new P(2,7,7001));f.catch(function(){});return new sf(f,function(){return Promise.resolve()},e)}b.method=b.method||"GET";b.headers=b.headers||{};b.retryParameters=b.retryParameters?hf(b.retryParameters):Ye();b.uris=hf(b.uris);f=tf(this,a,b,c);var g=f.Da(function(){return uf(d,a,b,c,new We(b.retryParameters,!1),0,null,e)}),h=g.Da(function(q){return vf(d,a,q,c)}),k=Date.now(),l=0;f.promise.then(function(){l=Date.now()-k},function(){});
183
183
  var m=0;g.promise.then(function(){m=Date.now()},function(){});var n=h.Da(function(q){var r=Date.now()-m,u=q.response;u.timeMs+=l;u.timeMs+=r;q.ri||!d.l||u.fromCache||"HEAD"==b.method||a!=wf||d.l(u.timeMs,u.data.byteLength,xf(c));return u},function(q){q&&(q.severity=2);throw q;});f=new sf(n.promise,function(){return n.abort()},e);lf(this.m,f);return f};
184
184
  function tf(a,b,c,d){function e(h){f=f.Da(function(){c.body&&(c.body=mc(c.body));return h(b,c,d)})}var f=df(void 0);a.C&&e(a.C);a=t(a.g);for(var g=a.next();!g.done;g=a.next())e(g.value);return f.Da(void 0,function(h){if(h instanceof P&&7001==h.code)throw h;throw new P(2,1,1006,h);})}
185
185
  function uf(a,b,c,d,e,f,g,h){a.s&&(c.uris[f]=c.uris[f].replace("http://","https://"));0<f&&a.D&&a.D(b,d,c.uris[f],c.uris[f-1]);var k=new gb(c.uris[f]),l=k.vb,m=!1;l||(l=location.protocol,l=l.slice(0,-1),jb(k,l),c.uris[f]=k.toString());l=l.toLowerCase();var n=(l=pf[l])?l.Ae:null;if(!n)return bf(new P(2,1,1E3,k));var q=l.Oi,r=null,u=null,v=!1,y=!1,z;return ef(Ze(e)).Da(function(){if(a.i)return cf();z=Date.now();var x=n(c.uris[f],c,b,function(C,E,H){r&&r.stop();u&&u.T(B/1E3);a.l&&b==wf&&(a.l(C,E,xf(d)),
@@ -187,24 +187,24 @@ m=!0,h.g=H)},function(C){a.j&&a.j(C,c,b);y=!0});if(!q)return x;var A=c.retryPara
187
187
  A,B,v)}if(a.i)return cf();v&&(x=new P(1,1,1003,c.uris[f],b));if(x instanceof P){if(7001==x.code)throw x;if(1010==x.code)throw g;if(1==x.severity)return A=(new Map).set("error",x),A=new O("retry",A),a.dispatchEvent(A),f=(f+1)%c.uris.length,uf(a,b,c,d,e,f,x,h)}throw x;})}
188
188
  function vf(a,b,c,d){var e=df(void 0),f={};a=t(a.h);for(var g=a.next();!g.done;f={Re:f.Re},g=a.next())f.Re=g.value,e=e.Da(function(h){return function(){var k=c.response;k.data&&(k.data=mc(k.data));return h.Re(b,k,d)}}(f));return e.Da(function(){return c},function(h){var k=2;if(h instanceof P){if(7001==h.code)throw h;k=h.severity}throw new P(k,1,1007,h);})}function xf(a){if(a){var b=a.segment;a=a.stream;if(b&&a&&a.fastSwitching&&b.D&&!b.C)return!1}return!0}M("shaka.net.NetworkingEngine",mf);
189
189
  mf.prototype.request=mf.prototype.request;mf.prototype.destroy=mf.prototype.destroy;mf.makeRequest=qf;mf.defaultRetryParameters=function(){return Ye()};mf.prototype.clearAllResponseFilters=mf.prototype.Ch;mf.prototype.unregisterResponseFilter=mf.prototype.jj;mf.prototype.registerResponseFilter=mf.prototype.Qi;mf.prototype.clearAllRequestFilters=mf.prototype.Bh;mf.prototype.unregisterRequestFilter=mf.prototype.ij;mf.prototype.registerRequestFilter=mf.prototype.Pi;mf.unregisterScheme=function(a){delete pf[a]};
190
- mf.registerScheme=nf;mf.prototype.setForceHTTPS=mf.prototype.gg;function rf(){this.g=0}mf.NumBytesRemainingClass=rf;function sf(a,b,c){af.call(this,a,b);this.h=c}pa(sf,af);mf.PendingRequest=sf;var wf=1;mf.RequestType={MANIFEST:0,SEGMENT:wf,LICENSE:2,APP:3,TIMING:4,SERVER_CERTIFICATE:5,KEY:6,ADS:7,CONTENT_STEERING:8};mf.AdvancedRequestType={INIT_SEGMENT:0,MEDIA_SEGMENT:1,MEDIA_PLAYLIST:2,MASTER_PLAYLIST:3,MPD:4,MSS:5};var of=3;mf.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:of};var pf={};function yf(a){this.g=!1;this.h=new $e;this.i=a}yf.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 zf(a,b){if(a.g){if(b instanceof P&&7003==b.code)throw b;throw new P(2,7,7003,b);}};function Af(){this.g=new $a}p=Af.prototype;p.release=function(){this.sb();this.g=null};p.o=function(a,b,c,d){this.g&&(a=new Bf(a,b,c,d),this.g.push(b,a))};p.ka=function(a,b,c,d){function e(g){f.cc(a,b,e);c(g)}var f=this;this.o(a,b,e,d)};p.cc=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.cc(),this.g.remove(b,e))}};
191
- p.sb=function(){if(this.g){var a=this.g,b=[],c;for(c in a.g)b.push.apply(b,w(a.g[c]));a=t(b);for(b=a.next();!b.done;b=a.next())b.value.cc();this.g.g={}}};M("shaka.util.EventManager",Af);Af.prototype.removeAll=Af.prototype.sb;Af.prototype.unlisten=Af.prototype.cc;Af.prototype.listenOnce=Af.prototype.ka;Af.prototype.listen=Af.prototype.o;Af.prototype.release=Af.prototype.release;function Bf(a,b,c,d){this.target=a;this.type=b;this.listener=c;this.g=Cf(a,d);this.target.addEventListener(b,c,this.g)}
192
- Bf.prototype.cc=function(){this.target.removeEventListener(this.type,this.listener,this.g);this.listener=this.target=null;this.g=!1};function Cf(a,b){if(void 0==b)return!1;if("boolean"==typeof b)return b;var c=new Set(["passive","capture"]);Object.keys(b).filter(function(d){return!c.has(d)});return Df(a)?b:b.capture||!1}
190
+ mf.registerScheme=nf;mf.prototype.setForceHTTPS=mf.prototype.gg;function rf(){this.g=0}mf.NumBytesRemainingClass=rf;function sf(a,b,c){af.call(this,a,b);this.h=c}pa(sf,af);mf.PendingRequest=sf;var wf=1;mf.RequestType={MANIFEST:0,SEGMENT:wf,LICENSE:2,APP:3,TIMING:4,SERVER_CERTIFICATE:5,KEY:6,ADS:7,CONTENT_STEERING:8};mf.AdvancedRequestType={INIT_SEGMENT:0,MEDIA_SEGMENT:1,MEDIA_PLAYLIST:2,MASTER_PLAYLIST:3,MPD:4,MSS:5};var of=3;mf.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:of};var pf={};function yf(a){this.g=!1;this.h=new $e;this.i=a}yf.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 zf(a,b){if(a.g){if(b instanceof P&&7003==b.code)throw b;throw new P(2,7,7003,b);}};function Af(){this.g=new $a}p=Af.prototype;p.release=function(){this.sb();this.g=null};p.o=function(a,b,c,d){this.g&&(a=new Bf(a,b,c,d),this.g.push(b,a))};p.ka=function(a,b,c,d){function e(g){f.dc(a,b,e);c(g)}var f=this;this.o(a,b,e,d)};p.dc=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.dc(),this.g.remove(b,e))}};
191
+ p.sb=function(){if(this.g){var a=this.g,b=[],c;for(c in a.g)b.push.apply(b,w(a.g[c]));a=t(b);for(b=a.next();!b.done;b=a.next())b.value.dc();this.g.g={}}};M("shaka.util.EventManager",Af);Af.prototype.removeAll=Af.prototype.sb;Af.prototype.unlisten=Af.prototype.dc;Af.prototype.listenOnce=Af.prototype.ka;Af.prototype.listen=Af.prototype.o;Af.prototype.release=Af.prototype.release;function Bf(a,b,c,d){this.target=a;this.type=b;this.listener=c;this.g=Cf(a,d);this.target.addEventListener(b,c,this.g)}
192
+ Bf.prototype.dc=function(){this.target.removeEventListener(this.type,this.listener,this.g);this.listener=this.target=null;this.g=!1};function Cf(a,b){if(void 0==b)return!1;if("boolean"==typeof b)return b;var c=new Set(["passive","capture"]);Object.keys(b).filter(function(d){return!c.has(d)});return Df(a)?b:b.capture||!1}
193
193
  function Df(a){var b=Ef;if(void 0==b){b=!1;try{var c={},d={get:function(){b=!0;return!1}};Object.defineProperty(c,"passive",d);Object.defineProperty(c,"capture",d);d=function(){};a.addEventListener("test",d,c);a.removeEventListener("test",d,c)}catch(e){b=!1}Ef=b}return b||!1}var Ef=void 0;function Ff(a){this.h=a;this.g=void 0}Ff.prototype.value=function(){void 0==this.g&&(this.g=this.h());return this.g};function Gf(a){for(var b=new Map,c=t(Object.keys(a)),d=c.next();!d.done;d=c.next())d=d.value,b.set(d,a[d]);return b}function Hf(a){var b={};a.forEach(function(c,d){b[d]=c});return b}function If(a,b){if(a||b){if(a&&!b||b&&!a)return!1}else return!0;if(a.size!=b.size)return!1;a=t(a);for(var c=a.next();!c.done;c=a.next()){var d=t(c.value);c=d.next().value;d=d.next().value;if(!b.has(c))return!1;c=b.get(c);if(c!=d||void 0==c)return!1}return!0};function Jf(){}
194
194
  function Kf(a){if(!a)return"";a=lc(a);239==a[0]&&187==a[1]&&191==a[2]&&(a=a.subarray(3));if(window.TextDecoder&&!Id())return a=(new TextDecoder).decode(a),a.includes("\ufffd")&&Ra('Decoded string contains an "unknown character" codepoint. That probably means the UTF8 encoding was incorrect!'),a;for(var b="",c=0;c<a.length;++c){var d=65533;0==(a[c]&128)?d=a[c]:a.length>=c+2&&192==(a[c]&224)&&128==(a[c+1]&192)?(d=(a[c]&31)<<6|a[c+1]&63,c+=1):a.length>=c+3&&224==(a[c]&240)&&128==(a[c+1]&192)&&128==
195
195
  (a[c+2]&192)?(d=(a[c]&15)<<12|(a[c+1]&63)<<6|a[c+2]&63,c+=2):a.length>=c+4&&240==(a[c]&241)&&128==(a[c+1]&192)&&128==(a[c+2]&192)&&128==(a[c+3]&192)&&(d=(a[c]&7)<<18|(a[c+1]&63)<<12|(a[c+2]&63)<<6|a[c+3]&63,c+=3);if(65535>=d)b+=String.fromCharCode(d);else{d-=65536;var e=d&1023;b+=String.fromCharCode(55296+(d>>10));b+=String.fromCharCode(56320+e)}}return b}
196
196
  function Lf(a,b,c){if(!a)return"";if(!c&&0!=a.byteLength%2)throw new P(2,2,2004);c=Math.floor(a.byteLength/2);var d=new Uint16Array(c);a=pc(a);for(var e=0;e<c;e++)d[e]=a.getUint16(2*e,b);return Mf.value()(d)}
197
197
  function Nf(a){function b(d){return c.byteLength<=d||32<=c[d]&&126>=c[d]}if(!a)return"";var c=lc(a);if(239==c[0]&&187==c[1]&&191==c[2])return Kf(c);if(254==c[0]&&255==c[1])return Lf(c.subarray(2),!1);if(255==c[0]&&254==c[1])return Lf(c.subarray(2),!0);if(0==c[0]&&0==c[2])return Lf(a,!1);if(0==c[1]&&0==c[3])return Lf(a,!0);if(b(0)&&b(1)&&b(2)&&b(3))return Kf(a);throw new P(2,2,2003);}
198
198
  function Of(a){if(window.TextEncoder&&!Id()){var b=new TextEncoder;return mc(b.encode(a))}a=encodeURIComponent(a);a=unescape(a);b=new Uint8Array(a.length);for(var c=0;c<a.length;c++)b[c]=a[c].charCodeAt(0);return mc(b)}function Pf(a,b){for(var c=new ArrayBuffer(2*a.length),d=new DataView(c),e=0;e<a.length;++e)d.setUint16(2*e,a.charCodeAt(e),b);return c}M("shaka.util.StringUtils",Jf);Jf.resetFromCharCode=function(){Mf.g=void 0};Jf.toUTF16=Pf;Jf.toUTF8=Of;Jf.fromBytesAutoDetect=Nf;Jf.fromUTF16=Lf;
199
- Jf.fromUTF8=Kf;var Mf=new Ff(function(){function a(c){try{var d=new Uint8Array(c);return 0<String.fromCharCode.apply(null,d).length}catch(e){return!1}}for(var b={Sb:65536};0<b.Sb;b={Sb:b.Sb},b.Sb/=2)if(a(b.Sb))return function(c){return function(d){for(var e="",f=0;f<d.length;f+=c.Sb)e+=String.fromCharCode.apply(null,d.subarray(f,f+c.Sb));return e}}(b);return null});function Qf(a,b){this.h=pc(a);this.i=b==Rf;this.g=0}p=Qf.prototype;p.wa=function(){return this.g<this.h.byteLength};p.Ea=function(){return this.g};p.getLength=function(){return this.h.byteLength};p.oa=function(){try{var a=this.h.getUint8(this.g);this.g+=1;return a}catch(b){throw Sf();}};p.Ta=function(){try{var a=this.h.getUint16(this.g,this.i);this.g+=2;return a}catch(b){throw Sf();}};p.N=function(){try{var a=this.h.getUint32(this.g,this.i);this.g+=4;return a}catch(b){throw Sf();}};
200
- p.Zg=function(){try{var a=this.h.getInt32(this.g,this.i);this.g+=4;return a}catch(b){throw Sf();}};p.Qc=function(){try{if(this.i){var a=this.h.getUint32(this.g,!0);var b=this.h.getUint32(this.g+4,!0)}else b=this.h.getUint32(this.g,!1),a=this.h.getUint32(this.g+4,!1)}catch(c){throw Sf();}if(2097151<b)throw new P(2,3,3001);this.g+=8;return b*Math.pow(2,32)+a};p.Ob=function(a){if(this.g+a>this.h.byteLength)throw Sf();var b=lc(this.h,this.g,a);this.g+=a;return b};
199
+ Jf.fromUTF8=Kf;var Mf=new Ff(function(){function a(c){try{var d=new Uint8Array(c);return 0<String.fromCharCode.apply(null,d).length}catch(e){return!1}}for(var b={Ub:65536};0<b.Ub;b={Ub:b.Ub},b.Ub/=2)if(a(b.Ub))return function(c){return function(d){for(var e="",f=0;f<d.length;f+=c.Ub)e+=String.fromCharCode.apply(null,d.subarray(f,f+c.Ub));return e}}(b);return null});function Qf(a,b){this.h=pc(a);this.i=b==Rf;this.g=0}p=Qf.prototype;p.wa=function(){return this.g<this.h.byteLength};p.Ea=function(){return this.g};p.getLength=function(){return this.h.byteLength};p.oa=function(){try{var a=this.h.getUint8(this.g);this.g+=1;return a}catch(b){throw Sf();}};p.Ta=function(){try{var a=this.h.getUint16(this.g,this.i);this.g+=2;return a}catch(b){throw Sf();}};p.N=function(){try{var a=this.h.getUint32(this.g,this.i);this.g+=4;return a}catch(b){throw Sf();}};
200
+ p.Zg=function(){try{var a=this.h.getInt32(this.g,this.i);this.g+=4;return a}catch(b){throw Sf();}};p.Qc=function(){try{if(this.i){var a=this.h.getUint32(this.g,!0);var b=this.h.getUint32(this.g+4,!0)}else b=this.h.getUint32(this.g,!1),a=this.h.getUint32(this.g+4,!1)}catch(c){throw Sf();}if(2097151<b)throw new P(2,3,3001);this.g+=8;return b*Math.pow(2,32)+a};p.Qb=function(a){if(this.g+a>this.h.byteLength)throw Sf();var b=lc(this.h,this.g,a);this.g+=a;return b};
201
201
  p.skip=function(a){if(this.g+a>this.h.byteLength)throw Sf();this.g+=a};p.Yi=function(a){if(this.g<a)throw Sf();this.g-=a};p.seek=function(a){if(0>a||a>this.h.byteLength)throw Sf();this.g=a};p.Cd=function(){for(var a=this.g;this.wa()&&0!=this.h.getUint8(this.g);)this.g+=1;a=lc(this.h,a,this.g-a);this.g+=1;return Kf(a)};function Sf(){return new P(2,3,3E3)}M("shaka.util.DataViewReader",Qf);Qf.prototype.readTerminatedString=Qf.prototype.Cd;Qf.prototype.seek=Qf.prototype.seek;Qf.prototype.rewind=Qf.prototype.Yi;
202
- Qf.prototype.skip=Qf.prototype.skip;Qf.prototype.readBytes=Qf.prototype.Ob;Qf.prototype.readUint64=Qf.prototype.Qc;Qf.prototype.readInt32=Qf.prototype.Zg;Qf.prototype.readUint32=Qf.prototype.N;Qf.prototype.readUint16=Qf.prototype.Ta;Qf.prototype.readUint8=Qf.prototype.oa;Qf.prototype.getLength=Qf.prototype.getLength;Qf.prototype.getPosition=Qf.prototype.Ea;Qf.prototype.hasMoreData=Qf.prototype.wa;var Rf=1;Qf.Endianness={BIG_ENDIAN:0,LITTLE_ENDIAN:Rf};function Tf(){this.i=[];this.h=[];this.g=!1}p=Tf.prototype;p.box=function(a,b){a=Uf(a);this.i[a]=Vf;this.h[a]=b;return this};p.S=function(a,b){a=Uf(a);this.i[a]=Wf;this.h[a]=b;return this};p.stop=function(){this.g=!0};p.parse=function(a,b,c){a=new Qf(a,0);for(this.g=!1;a.wa()&&!this.g;)this.zd(0,a,b,c)};
203
- p.zd=function(a,b,c,d){var e=b.Ea();if(d&&e+8>b.getLength())this.g=!0;else{var f=b.N(),g=b.N(),h=Xf(g),k=!1;switch(f){case 0:f=b.getLength()-e;break;case 1:if(d&&b.Ea()+8>b.getLength()){this.g=!0;return}f=b.Qc();k=!0}var l=this.h[g];if(l){var m=null,n=null;if(this.i[g]==Wf){if(d&&b.Ea()+4>b.getLength()){this.g=!0;return}n=b.N();m=n>>>24;n&=16777215}g=e+f;c&&g>b.getLength()&&(g=b.getLength());d&&g>b.getLength()?this.g=!0:(d=g-b.Ea(),b=0<d?b.Ob(d):new Uint8Array(0),b=new Qf(b,0),l({name:h,parser:this,
202
+ Qf.prototype.skip=Qf.prototype.skip;Qf.prototype.readBytes=Qf.prototype.Qb;Qf.prototype.readUint64=Qf.prototype.Qc;Qf.prototype.readInt32=Qf.prototype.Zg;Qf.prototype.readUint32=Qf.prototype.N;Qf.prototype.readUint16=Qf.prototype.Ta;Qf.prototype.readUint8=Qf.prototype.oa;Qf.prototype.getLength=Qf.prototype.getLength;Qf.prototype.getPosition=Qf.prototype.Ea;Qf.prototype.hasMoreData=Qf.prototype.wa;var Rf=1;Qf.Endianness={BIG_ENDIAN:0,LITTLE_ENDIAN:Rf};function Tf(){this.i=[];this.h=[];this.g=!1}p=Tf.prototype;p.box=function(a,b){a=Uf(a);this.i[a]=Vf;this.h[a]=b;return this};p.S=function(a,b){a=Uf(a);this.i[a]=Wf;this.h[a]=b;return this};p.stop=function(){this.g=!0};p.parse=function(a,b,c){a=new Qf(a,0);for(this.g=!1;a.wa()&&!this.g;)this.zd(0,a,b,c)};
203
+ p.zd=function(a,b,c,d){var e=b.Ea();if(d&&e+8>b.getLength())this.g=!0;else{var f=b.N(),g=b.N(),h=Xf(g),k=!1;switch(f){case 0:f=b.getLength()-e;break;case 1:if(d&&b.Ea()+8>b.getLength()){this.g=!0;return}f=b.Qc();k=!0}var l=this.h[g];if(l){var m=null,n=null;if(this.i[g]==Wf){if(d&&b.Ea()+4>b.getLength()){this.g=!0;return}n=b.N();m=n>>>24;n&=16777215}g=e+f;c&&g>b.getLength()&&(g=b.getLength());d&&g>b.getLength()?this.g=!0:(d=g-b.Ea(),b=0<d?b.Qb(d):new Uint8Array(0),b=new Qf(b,0),l({name:h,parser:this,
204
204
  partialOkay:c||!1,version:m,flags:n,reader:b,size:f,start:e+a,has64BitSize:k}))}else b.skip(Math.min(e+f-b.Ea(),b.getLength()-b.Ea()))}};function Yf(a){for(var b=Zf(a);a.reader.wa()&&!a.parser.g;)a.parser.zd(a.start+b,a.reader,a.partialOkay)}function $f(a){for(var b=Zf(a),c=a.reader.N(),d=0;d<c&&(a.parser.zd(a.start+b,a.reader,a.partialOkay),!a.parser.g);d++);}function ag(a){var b=Zf(a);for(a.reader.skip(78);a.reader.wa()&&!a.parser.g;)a.parser.zd(a.start+b,a.reader,a.partialOkay)}
205
- function bg(a){return function(b){a(b.reader.Ob(b.reader.getLength()-b.reader.Ea()))}}function Uf(a){var b=0;a=t(a);for(var c=a.next();!c.done;c=a.next())b=b<<8|c.value.charCodeAt(0);return b}function Xf(a){return String.fromCharCode(a>>24&255,a>>16&255,a>>8&255,a&255)}function Zf(a){return 8+(a.has64BitSize?8:0)+(null!=a.flags?4:0)}M("shaka.util.Mp4Parser",Tf);Tf.headerSize=Zf;Tf.typeToString=Xf;Tf.allData=bg;Tf.visualSampleEntry=ag;Tf.sampleDescription=$f;Tf.children=Yf;Tf.prototype.parseNext=Tf.prototype.zd;
205
+ function bg(a){return function(b){a(b.reader.Qb(b.reader.getLength()-b.reader.Ea()))}}function Uf(a){var b=0;a=t(a);for(var c=a.next();!c.done;c=a.next())b=b<<8|c.value.charCodeAt(0);return b}function Xf(a){return String.fromCharCode(a>>24&255,a>>16&255,a>>8&255,a&255)}function Zf(a){return 8+(a.has64BitSize?8:0)+(null!=a.flags?4:0)}M("shaka.util.Mp4Parser",Tf);Tf.headerSize=Zf;Tf.typeToString=Xf;Tf.allData=bg;Tf.visualSampleEntry=ag;Tf.sampleDescription=$f;Tf.children=Yf;Tf.prototype.parseNext=Tf.prototype.zd;
206
206
  Tf.prototype.parse=Tf.prototype.parse;Tf.prototype.stop=Tf.prototype.stop;Tf.prototype.fullBox=Tf.prototype.S;Tf.prototype.box=Tf.prototype.box;var Vf=0,Wf=1;function cg(){}function dg(a){a=lc(a);a=Mf.value()(a);return btoa(a)}function eg(a,b){b=void 0==b?!0:b;a=dg(a).replace(/\+/g,"-").replace(/\//g,"_");return b?a:a.replace(/[=]*$/,"")}function fg(a){a=window.atob(a.replace(/-/g,"+").replace(/_/g,"/"));for(var b=new Uint8Array(a.length),c=0;c<a.length;++c)b[c]=a.charCodeAt(c);return b}function gg(a){for(var b=a.length/2,c=new Uint8Array(b),d=0;d<b;d++)c[d]=window.parseInt(a.substr(2*d,2),16);return c}
207
- function ig(a){var b=lc(a);a="";b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,c=c.toString(16),1==c.length&&(c="0"+c),a+=c;return a}function jg(){for(var a=Ga.apply(0,arguments),b=0,c=0;c<a.length;++c)b+=a[c].byteLength;b=new Uint8Array(b);for(var d=c=0;d<a.length;++d){var e=a[d];e instanceof Uint8Array?b.set(e,c):b.set(lc(e),c);c+=e.byteLength}return b}M("shaka.util.Uint8ArrayUtils",cg);cg.concat=jg;cg.toHex=ig;cg.fromHex=gg;cg.fromBase64=fg;cg.toBase64=eg;cg.toStandardBase64=dg;function kg(a){var b=this;this.g=[];this.h=[];this.data=[];(new Tf).box("moov",Yf).box("moof",Yf).S("pssh",function(c){if(!(1<c.version)){var d=lc(c.reader.h,-12,c.size);b.data.push(d);b.g.push(ig(c.reader.Ob(16)));if(0<c.version){d=c.reader.N();for(var e=0;e<d;e++){var f=ig(c.reader.Ob(16));b.h.push(f)}}}}).parse(a)}
207
+ function hg(a){var b=lc(a);a="";b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,c=c.toString(16),1==c.length&&(c="0"+c),a+=c;return a}function ig(){for(var a=Ga.apply(0,arguments),b=0,c=0;c<a.length;++c)b+=a[c].byteLength;b=new Uint8Array(b);for(var d=c=0;d<a.length;++d){var e=a[d];e instanceof Uint8Array?b.set(e,c):b.set(lc(e),c);c+=e.byteLength}return b}M("shaka.util.Uint8ArrayUtils",cg);cg.concat=ig;cg.toHex=hg;cg.fromHex=gg;cg.fromBase64=fg;cg.toBase64=eg;cg.toStandardBase64=dg;function kg(a){var b=this;this.g=[];this.h=[];this.data=[];(new Tf).box("moov",Yf).box("moof",Yf).S("pssh",function(c){if(!(1<c.version)){var d=lc(c.reader.h,-12,c.size);b.data.push(d);b.g.push(hg(c.reader.Qb(16)));if(0<c.version){d=c.reader.N();for(var e=0;e<d;e++){var f=hg(c.reader.Qb(16));b.h.push(f)}}}}).parse(a)}
208
208
  function lg(a,b,c,d){var e=a.length,f=b.length+16+e;0<d&&(f+=4+16*c.size);var g=new Uint8Array(f),h=pc(g),k=0;h.setUint32(k,f);k+=4;h.setUint32(k,1886614376);k+=4;1>d?h.setUint32(k,0):h.setUint32(k,16777216);k+=4;g.set(b,k);k+=b.length;if(0<d)for(h.setUint32(k,c.size),k+=4,b=t(c),c=b.next();!c.done;c=b.next())c=gg(c.value),g.set(c,k),k+=c.length;h.setUint32(k,e);g.set(a,k+4);return g};function mg(a,b){a=ng(a,b);return 1!=a.length?null:a[0]}function og(a,b,c){a=pg(a,b,c);return 1!=a.length?null:a[0]}function ng(a,b){var c=[];a=t(a.childNodes);for(var d=a.next();!d.done;d=a.next())d=d.value,d instanceof Element&&d.tagName==b&&c.push(d);return c}function qg(a){return Array.from(a.childNodes).filter(function(b){return b instanceof Element})}
209
209
  function pg(a,b,c){var d=[];a=t(a.childNodes);for(var e=a.next();!e.done;e=a.next())e=e.value,e instanceof Element&&e.localName==c&&e.namespaceURI==b&&d.push(e);return d}function rg(a,b,c){return a.hasAttributeNS(b,c)?a.getAttributeNS(b,c):null}function sg(a,b,c){b=t(b);for(var d=b.next();!d.done;d=b.next())if(d=d.value,a.hasAttributeNS(d,c))return a.getAttributeNS(d,c);return null}function tg(a){return Array.from(a.childNodes).every(ug)?a.textContent.trim():null}
210
210
  function ug(a){return a.nodeType==Node.TEXT_NODE||a.nodeType==Node.CDATA_SECTION_NODE}function vg(a,b,c,d){d=void 0===d?null:d;var e=null;a=a.getAttribute(b);null!=a&&(e=c(a));return null==e?d:e}function wg(a){if(!a)return null;/^\d+-\d+-\d+T\d+:\d+:\d+(\.\d+)?$/.test(a)&&(a+="Z");a=Date.parse(a);return isNaN(a)?null:a/1E3}
@@ -244,7 +244,7 @@ var g=f.errorCode;if(g&&g.systemCode){var h=g.systemCode;0>h&&(h+=Math.pow(2,32)
244
244
  function Zg(a,b){var c,d,e,f,g,h,k,l,m,n,q,r,u;K(function(v){switch(v.g){case 1:c=b.target;a.h.logLicenseExchange&&eg(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=qf([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(gh(a.g.keySystem)){var y=
245
245
  Lf(g.body,!0,!0);if(y.includes("PlayReadyKeyMessage")){y=Fg(y,"PlayReadyKeyMessage");for(var z=t(y.getElementsByTagName("HttpHeader")),x=z.next();!x.done;x=z.next())x=x.value,g.headers[x.getElementsByTagName("name")[0].textContent]=x.getElementsByTagName("value")[0].textContent;g.body=fg(y.getElementsByTagName("Challenge")[0].textContent)}else g.headers["Content-Type"]="text/xml; charset=utf-8"}h=Date.now();ta(v,2);l=a.G.tc.request(2,g);return D(v,l.promise,4);case 4:k=v.h;va(v,3);break;case 2:return m=
246
246
  wa(v),n=new P(2,6,6007,m),a.s(n),d&&d.Bb&&d.Bb.reject(n),v.return();case 3:if(a.j.g)return v.return();a.K+=(Date.now()-h)/1E3;a.h.logLicenseExchange&&eg(k.data);ta(v,5);return D(v,c.update(k.data),7);case 7:va(v,6);break;case 5:return q=wa(v),r=new P(2,6,6008,q.message),a.s(r),d&&d.Bb&&d.Bb.reject(r),v.return();case 6:if(a.j.g)return v.return();u=new O("drmsessionupdate");a.G.onEvent(u);d&&(d.Bb&&d.Bb.resolve(),mh(a,d));F(v)}})}
247
- function oh(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(gh(a.g.keySystem)&&16==g.byteLength&&(zd()||Id())){h=pc(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=ig(g).slice(0,32);a.U.set(g,f)});var e=b.expiration-Date.now();(0>e||d&&1E3>e)&&c&&!c.Bb&&(a.i.delete(b),b.close().catch(function(){}));
247
+ function oh(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(gh(a.g.keySystem)&&16==g.byteLength&&(zd()||Id())){h=pc(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=hg(g).slice(0,32);a.U.set(g,f)});var e=b.expiration-Date.now();(0>e||d&&1E3>e)&&c&&!c.Bb&&(a.i.delete(b),b.close().catch(function(){}));
248
248
  eh(a)&&(a.l.resolve(),a.V.T(ph))}function Jg(a){var b=a.U,c=a.qa;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.s(new P(2,6,6014));a.G.ze(Hf(c))}
249
249
  function qh(){var a,b,c,d,e,f,g,h;return K(function(k){return 1==k.g?(a="org.w3.clearkey com.widevine.alpha com.microsoft.playready com.microsoft.playready.recommendation com.apple.fps.1_0 com.apple.fps com.adobe.primetime".split(" "),b=[{contentType:'video/mp4; codecs="avc1.42E01E"'},{contentType:'video/webm; codecs="vp8"'}],c={initDataTypes:["cenc"],videoCapabilities:b},d={videoCapabilities:b,persistentState:"required",sessionTypes:["persistent-license"]},e=[d,c],f=new Map,g=function(l){var m,n,
250
250
  q;return K(function(r){switch(r.g){case 1:ta(r,2);if("org.w3.clearkey"===l&&Jd())throw Error("Unsupported keySystem");return D(r,navigator.requestMediaKeySystemAccess(l,e),4);case 4:return m=r.h,q=(n=m.getConfiguration().sessionTypes)?n.includes("persistent-license"):!1,Dd()&&(q=!1),f.set(l,{persistentState:q}),D(r,m.createMediaKeys(),5);case 5:va(r,0);break;case 2:wa(r),f.set(l,null),F(r)}})},h=a.map(function(l){return g(l)}),D(k,Promise.all(h),2)):k.return(Hf(f))})}
@@ -257,17 +257,17 @@ function Tg(a,b){var c=[];b.forEach(function(d,e){c.push({keySystem:e,licenseSer
257
257
  function kh(a,b,c,d,e,f){var g={};a=t(a);for(var h=a.next();!h.done;g={Ua:g.Ua},h=a.next()){g.Ua=h.value;b.includes(g.Ua.licenseServerUri)||b.push(g.Ua.licenseServerUri);d.includes(g.Ua.serverCertificateUri)||d.push(g.Ua.serverCertificateUri);g.Ua.serverCertificate&&(c.some(function(m){return function(n){return jc(n,m.Ua.serverCertificate)}}(g))||c.push(g.Ua.serverCertificate));if(g.Ua.initData){h={};for(var k=t(g.Ua.initData),l=k.next();!l.done;h={Md:h.Md},l=k.next())h.Md=l.value,e.some(function(m){return function(n){var q=
258
258
  m.Md;return n.keyId&&n.keyId==q.keyId?!0:n.initDataType==q.initDataType&&jc(n.initData,q.initData)}}(h))||e.push(h.Md)}if(g.Ua.keyIds)for(h=t(g.Ua.keyIds),k=h.next();!k.done;k=h.next())f.add(k.value)}}
259
259
  function Vg(a,b,c,d){var e=a.keySystem;if(e&&("org.w3.clearkey"!=e||!a.licenseServerUri)){b.size&&(b=b.get(e)||"",a.licenseServerUri=b);a.keyIds||(a.keyIds=new Set);if(c=c.get(e))a.distinctiveIdentifierRequired||(a.distinctiveIdentifierRequired=c.distinctiveIdentifierRequired),a.persistentStateRequired||(a.persistentStateRequired=c.persistentStateRequired),a.videoRobustness||(a.videoRobustness=c.videoRobustness),a.audioRobustness||(a.audioRobustness=c.audioRobustness),a.serverCertificate||(a.serverCertificate=
260
- c.serverCertificate),c.sessionType&&(a.sessionType=c.sessionType),a.serverCertificateUri||(a.serverCertificateUri=c.serverCertificateUri);d[e]&&(a.keySystem=d[e]);window.cast&&window.cast.__platform__&&"com.microsoft.playready"==e&&(a.keySystem="com.chromecast.playready")}}var sh=1,nh=5,ph=.5,vh=new Ff(function(){return mc(new Uint8Array([0]))});function wh(){}function xh(a,b){if(b&&(b=yh[b.toLowerCase()]))return b;throw new P(2,4,4E3,a);}M("shaka.media.ManifestParser",wh);wh.unregisterParserByMime=function(a){delete yh[a]};wh.registerParserByMime=function(a,b){yh[a]=b};wh.registerParserByExtension=function(){Ae("ManifestParser","Please use an ManifestParser with registerParserByMime function.")};wh.AccessibilityPurpose={ek:"visually impaired",Aj:"hard of hearing"};var yh={};function zh(a){function b(){d=!0}function c(l){f.push(l);Yf(l)}a=lc(a);var d=!1,e,f=[],g=[];(new Tf).box("moov",c).box("trak",c).box("mdia",c).box("minf",c).box("stbl",c).S("stsd",function(l){e=l;f.push(l);$f(l)}).S("encv",b).S("enca",b).S("dvav",function(l){g.push({box:l,bb:1701733238})}).S("dva1",function(l){g.push({box:l,bb:1701733238})}).S("dvh1",function(l){g.push({box:l,bb:1701733238})}).S("dvhe",function(l){g.push({box:l,bb:1701733238})}).S("hev1",function(l){g.push({box:l,bb:1701733238})}).S("hvc1",
261
- function(l){g.push({box:l,bb:1701733238})}).S("avc1",function(l){g.push({box:l,bb:1701733238})}).S("avc3",function(l){g.push({box:l,bb:1701733238})}).S("ac-3",function(l){g.push({box:l,bb:1701733217})}).S("ec-3",function(l){g.push({box:l,bb:1701733217})}).S("ac-4",function(l){g.push({box:l,bb:1701733217})}).S("mp4a",function(l){g.push({box:l,bb:1701733217})}).parse(a);if(d)return a;if(0==g.length||!e)throw Za(ig(a)),new P(2,3,3019);g.reverse();for(var h=t(g),k=h.next();!k.done;k=h.next())k=k.value,
260
+ c.serverCertificate),c.sessionType&&(a.sessionType=c.sessionType),a.serverCertificateUri||(a.serverCertificateUri=c.serverCertificateUri);d[e]&&(a.keySystem=d[e]);window.cast&&window.cast.__platform__&&"com.microsoft.playready"==e&&(a.keySystem="com.chromecast.playready")}}var sh=1,nh=5,ph=.5,vh=new Ff(function(){return mc(new Uint8Array([0]))});function wh(){}function xh(a,b){if(b){var c=yh[b.toLowerCase()];if(c)return c}throw new P(2,4,4E3,a,b);}M("shaka.media.ManifestParser",wh);wh.unregisterParserByMime=function(a){delete yh[a]};wh.registerParserByMime=function(a,b){yh[a]=b};wh.registerParserByExtension=function(){Ae("ManifestParser.registerParserByExtension","Please use an ManifestParser with registerParserByMime function.")};wh.AccessibilityPurpose={ek:"visually impaired",Aj:"hard of hearing"};var yh={};function zh(a){function b(){d=!0}function c(l){f.push(l);Yf(l)}a=lc(a);var d=!1,e,f=[],g=[];(new Tf).box("moov",c).box("trak",c).box("mdia",c).box("minf",c).box("stbl",c).S("stsd",function(l){e=l;f.push(l);$f(l)}).S("encv",b).S("enca",b).S("dvav",function(l){g.push({box:l,bb:1701733238})}).S("dva1",function(l){g.push({box:l,bb:1701733238})}).S("dvh1",function(l){g.push({box:l,bb:1701733238})}).S("dvhe",function(l){g.push({box:l,bb:1701733238})}).S("hev1",function(l){g.push({box:l,bb:1701733238})}).S("hvc1",
261
+ function(l){g.push({box:l,bb:1701733238})}).S("avc1",function(l){g.push({box:l,bb:1701733238})}).S("avc3",function(l){g.push({box:l,bb:1701733238})}).S("ac-3",function(l){g.push({box:l,bb:1701733217})}).S("ec-3",function(l){g.push({box:l,bb:1701733217})}).S("ac-4",function(l){g.push({box:l,bb:1701733217})}).S("mp4a",function(l){g.push({box:l,bb:1701733217})}).parse(a);if(d)return a;if(0==g.length||!e)throw Za(hg(a)),new P(2,3,3019);g.reverse();for(var h=t(g),k=h.next();!k.done;k=h.next())k=k.value,
262
262
  a=Ah(a,e,k.box,f,k.bb);return a}
263
263
  function Ah(a,b,c,d,e){var f=Bh.value(),g=a.subarray(c.start,c.start+c.size),h=pc(g),k=new Uint8Array(c.size+f.byteLength);k.set(g,0);g=pc(k);g.setUint32(4,e);k.set(f,c.size);e=h.getUint32(4);g.setUint32(c.size+16,e);Ch(k,0,k.byteLength);e=new Uint8Array(a.byteLength+k.byteLength);c=Ad()?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,Ch(e,d.start,d.size+k.byteLength);k=pc(e,b.start);b=Zf(b);a=k.getUint32(b);
264
- k.setUint32(b,a+1);return e}function Ch(a,b,c){a=pc(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 Bh=new Ff(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 Dh(a,b,c,d,e,f,g){this.aa=a;this.gb=b;this.Ma=c;this.Nf=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}Dh.prototype.Zb=function(){return this.gb};Dh.prototype.Wb=function(){return this.Ma};function Eh(a,b){return a&&b?a.Zb()==b.Zb()&&a.Wb()==b.Wb()&&xc(a.aa().sort(),b.aa().sort())&&jc(a.g,b.g):a==b}M("shaka.media.InitSegmentReference",Dh);Dh.prototype.getEndByte=Dh.prototype.Wb;Dh.prototype.getStartByte=Dh.prototype.Zb;
264
+ k.setUint32(b,a+1);return e}function Ch(a,b,c){a=pc(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 Bh=new Ff(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 Dh(a,b,c,d,e,f,g){this.aa=a;this.gb=b;this.Ma=c;this.Nf=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}Dh.prototype.Nb=function(){return this.gb};Dh.prototype.Kb=function(){return this.Ma};function Eh(a,b){return a===b?!0:a&&b?a.Nb()==b.Nb()&&a.Kb()==b.Kb()&&xc(a.aa().sort(),b.aa().sort())&&jc(a.g,b.g):a==b}M("shaka.media.InitSegmentReference",Dh);Dh.prototype.getEndByte=Dh.prototype.Kb;Dh.prototype.getStartByte=Dh.prototype.Nb;
265
265
  function Fh(a,b,c,d,e,f,g,h,k,l,m,n,q,r,u,v){l=void 0===l?[]:l;r=void 0===r?Gh:r;this.startTime=a;this.i=this.endTime=b;this.I=c;this.gb=d;this.Ma=e;this.g=f;this.timestampOffset=g;this.appendWindowStart=h;this.appendWindowEnd=k;this.h=l;this.tilesLayout=void 0===m?"":m;this.H=void 0===n?null:n;this.ma=void 0===q?null:q;this.status=r;this.m=!1;this.l=!0;this.s=!1;this.aes128Key=void 0===u?null:u;this.G=null;this.j=0;this.u=void 0===v?!1:v;this.C=this.D=!1;a=t(this.h);for(b=a.next();!b.done;b=a.next())b.value.Vg();
266
- this.u&&this.h.length&&this.h[this.h.length-1].Ug()}p=Fh.prototype;p.aa=function(){return this.I()};p.getStartTime=function(){return this.startTime};p.Uh=function(){return this.endTime};p.Zb=function(){return this.gb};p.Wb=function(){return this.Ma};p.li=function(){return this.tilesLayout};p.ki=function(){return this.H};p.mc=function(){return this.status};p.Hi=function(){this.status=Hh};p.Mf=function(){this.m=!0};p.Bi=function(){return this.m};p.qe=function(){this.l=!1};p.xi=function(){return this.l};
266
+ this.u&&this.h.length&&this.h[this.h.length-1].Ug()}p=Fh.prototype;p.aa=function(){return this.I()};p.getStartTime=function(){return this.startTime};p.Uh=function(){return this.endTime};p.Nb=function(){return this.gb};p.Kb=function(){return this.Ma};p.li=function(){return this.tilesLayout};p.ki=function(){return this.H};p.mc=function(){return this.status};p.Hi=function(){this.status=Hh};p.Mf=function(){this.m=!0};p.Bi=function(){return this.m};p.qe=function(){this.l=!1};p.xi=function(){return this.l};
267
267
  p.Vg=function(){this.D=!0};p.Ai=function(){return this.D};p.Ug=function(){this.C=!0};p.zi=function(){return this.C};p.Tg=function(){this.s=!0};p.si=function(){return this.s};p.ih=function(a){this.G=a};p.ji=function(){return this.G};p.offset=function(a){this.startTime+=a;this.endTime+=a;this.i+=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.i+=a};
268
268
  p.mg=function(a){null==this.ma?Ra("Sync attempted without sync time!"):(a=this.ma-a-this.startTime,.001<=Math.abs(a)&&this.offset(a))};M("shaka.media.SegmentReference",Fh);Fh.prototype.syncAgainst=Fh.prototype.mg;Fh.prototype.offset=Fh.prototype.offset;Fh.prototype.getThumbnailSprite=Fh.prototype.ji;Fh.prototype.setThumbnailSprite=Fh.prototype.ih;Fh.prototype.hasByterangeOptimization=Fh.prototype.si;Fh.prototype.markAsByterangeOptimization=Fh.prototype.Tg;Fh.prototype.isLastPartial=Fh.prototype.zi;
269
269
  Fh.prototype.markAsLastPartial=Fh.prototype.Ug;Fh.prototype.isPartial=Fh.prototype.Ai;Fh.prototype.markAsPartial=Fh.prototype.Vg;Fh.prototype.isIndependent=Fh.prototype.xi;Fh.prototype.markAsNonIndependent=Fh.prototype.qe;Fh.prototype.isPreload=Fh.prototype.Bi;Fh.prototype.markAsPreload=Fh.prototype.Mf;Fh.prototype.markAsUnavailable=Fh.prototype.Hi;Fh.prototype.getStatus=Fh.prototype.mc;Fh.prototype.getTileDuration=Fh.prototype.ki;Fh.prototype.getTilesLayout=Fh.prototype.li;
270
- Fh.prototype.getEndByte=Fh.prototype.Wb;Fh.prototype.getStartByte=Fh.prototype.Zb;Fh.prototype.getEndTime=Fh.prototype.Uh;Fh.prototype.getStartTime=Fh.prototype.getStartTime;Fh.prototype.getUris=Fh.prototype.aa;var Gh=0,Hh=1;Fh.Status={nj:Gh,ck:Hh,Gj:2};function Ih(a){return!a||1==a.length&&1E-6>a.end(0)-a.start(0)?null:a.length?a.end(a.length-1):null}function Jh(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 Kh(a,b){if(!a||!a.length||1==a.length&&1E-6>a.end(0)-a.start(0))return 0;var c=0;a=t(Lh(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}
270
+ Fh.prototype.getEndByte=Fh.prototype.Kb;Fh.prototype.getStartByte=Fh.prototype.Nb;Fh.prototype.getEndTime=Fh.prototype.Uh;Fh.prototype.getStartTime=Fh.prototype.getStartTime;Fh.prototype.getUris=Fh.prototype.aa;var Gh=0,Hh=1;Fh.Status={nj:Gh,ck:Hh,Gj:2};function Ih(a){return!a||1==a.length&&1E-6>a.end(0)-a.start(0)?null:a.length?a.end(a.length-1):null}function Jh(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 Kh(a,b){if(!a||!a.length||1==a.length&&1E-6>a.end(0)-a.start(0))return 0;var c=0;a=t(Lh(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}
271
271
  function Mh(a,b,c){if(!a||!a.length||1==a.length&&1E-6>a.end(0)-a.start(0))return null;a=Lh(a).findIndex(function(d,e,f){return d.start>b&&(0==e||f[e-1].end-b<=c)});return 0<=a?a:null}function Lh(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};/*
272
272
  @license
273
273
  Shaka Player
@@ -279,7 +279,7 @@ function Rh(a){var b={key:a.type,description:"",data:"",mimeType:null,pictureTyp
279
279
  d=a.data.subarray(1).indexOf(0);if(-1===d)return null;c=Kf(lc(a.data,1,d));a=Kf(lc(a.data,2+d)).replace(/\0*$/,"");b.description=c;b.data=a;return b}if("WXXX"===a.type){if(2>a.size||3!==a.data[0])return null;d=a.data.subarray(1).indexOf(0);if(-1===d)return null;c=Kf(lc(a.data,1,d));a=Kf(lc(a.data,2+d)).replace(/\0*$/,"");b.description=c;b.data=a;return b}if("PRIV"===a.type){if(2>a.size)return null;c=a.data.indexOf(0);if(-1===c)return null;c=Kf(lc(a.data,0,c));b.description=c;"com.apple.streaming.transportStreamTimestamp"==
280
280
  c?(c=a.data.subarray(c.length+1),a=c[3]&1,c=(c[4]<<23)+(c[5]<<15)+(c[6]<<7)+c[7],c/=45,a&&(c+=4.772185884E7),b.data=c):(a=mc(a.data.subarray(c.length+1)),b.data=a);return b}if("T"===a.type[0]){if(2>a.size||3!==a.data[0])return null;a=Kf(a.data.subarray(1)).replace(/\0*$/,"");b.data=a;return b}return"W"===a.type[0]?(a=Kf(a.data).replace(/\0*$/,""),b.data=a,b):a.data?(b.data=mc(a.data),b):null}
281
281
  function Sh(a){for(var b=0,c=[];Oh(a,b);){var d=Qh(a,b+6);a[b+5]>>6&1&&(b+=10);b+=10;for(d=b+d;b+10<d;){var e=a.subarray(b),f=Qh(e,4);e={type:String.fromCharCode(e[0],e[1],e[2],e[3]),size:f,data:e.subarray(10,10+f)};(f=Rh(e))&&c.push(f);b+=e.size+10}Ph(a,b)&&(b+=10)}return c}function Th(a,b){for(var c=b=void 0===b?0:b,d=0;Oh(a,b);)a[b+5]>>6&1&&(d+=10),d+=10,d+=Qh(a,b+6),Ph(a,b+10)&&(d+=10),b+=d;return 0<d?a.subarray(c,c+d):new Uint8Array([])}M("shaka.util.Id3Utils",Nh);Nh.getID3Data=Th;
282
- Nh.getID3Frames=Sh;function Uh(a,b){var c=null,d=null,e=null,f=a.N();b&1&&(e=a.Qc());b&2&&a.skip(4);b&8&&(c=a.N());b&16&&(d=a.N());return{trackId:f,Hg:c,Gh:d,gk:e}}function Vh(a,b){return 1==b?(b=a.N(),a=a.N(),{baseMediaDecodeTime:b*Math.pow(2,32)+a}):{baseMediaDecodeTime:a.N()}}function Xh(a,b){1==b?(a.skip(8),a.skip(8)):(a.skip(4),a.skip(4));b=a.N();a.skip(4);a=a.Ta();return{timescale:b,language:String.fromCharCode((a>>10)+96)+String.fromCharCode(((a&960)>>5)+96)+String.fromCharCode((a&31)+96)}}
282
+ Nh.getID3Frames=Sh;function Uh(a,b){var c=null,d=null,e=null,f=a.N();b&1&&(e=a.Qc());b&2&&a.skip(4);b&8&&(c=a.N());b&16&&(d=a.N());return{trackId:f,Hg:c,Gh:d,gk:e}}function Vh(a,b){return 1==b?(b=a.N(),a=a.N(),{baseMediaDecodeTime:b*Math.pow(2,32)+a}):{baseMediaDecodeTime:a.N()}}function Wh(a,b){1==b?(a.skip(8),a.skip(8)):(a.skip(4),a.skip(4));b=a.N();a.skip(4);a=a.Ta();return{timescale:b,language:String.fromCharCode((a>>10)+96)+String.fromCharCode(((a&960)>>5)+96)+String.fromCharCode((a&31)+96)}}
283
283
  function Yh(a,b,c){var d=a.N(),e=[],f=null;c&1&&(f=a.N());c&4&&a.skip(4);for(var g=0;g<d;g++){var h={$f:null,sampleSize:null,De:null};c&256&&(h.$f=a.N());c&512&&(h.sampleSize=a.N());c&1024&&a.skip(4);c&2048&&(h.De=0==b?a.N():a.Zg());e.push(h)}return{kk:d,bh:e,Fh:f}}
284
284
  function Zh(a,b){1==b?(a.skip(8),a.skip(8)):(a.skip(4),a.skip(4));var c=a.N();1==b?a.skip(8):a.skip(4);a.skip(4);a.skip(8);a.skip(2);a.skip(2);a.skip(2);a.skip(2);a.skip(36);b=a.Ta()+a.Ta()/16;a=a.Ta()+a.Ta()/16;return{trackId:c,width:b,height:a}}
285
285
  function $h(a){for(var b="mp4a",c,d;a.wa();){c=a.oa();for(var e=a.oa();e&128;)e=a.oa();if(3==c)a.Ta(),e=a.oa(),e&128&&a.Ta(),e&64&&a.skip(a.oa()),e&32&&a.Ta();else if(4==c)d=a.oa(),a.skip(12);else if(5==c)break}d&&(b+="."+this.g(d),5==c&&a.wa()&&(c=a.oa(),d=(c&248)>>3,31===d&&a.wa()&&(d=32+((c&7)<<3)+((a.oa()&224)>>5)),b+="."+d));return{va:b}}function ai(a,b){a.skip(87);return{va:b+"."+this.g(a.oa())+this.g(a.oa())+this.g(a.oa())}}function bi(a){a=a.N();return{va:Xf(a)}};/*
@@ -306,19 +306,19 @@ k;){var l=(f[h+1]&31)<<8|f[h+2],m=(f[h+3]&15)<<8|f[h+4];switch(f[h]){case 6:if(-
306
306
  "hvc");break;case 129:-1==g.audio&&(g.audio=l,g.audioCodec="ac3");break;case 132:case 135:-1==g.audio&&(g.audio=l,g.audioCodec="ec3")}h+=m+5}f=g;-1!=f.video&&(this.H=f.video,this.m=f.videoCodec);-1!=f.audio&&(this.u=f.audio,this.s=f.audioCodec);-1!=f.je&&(this.C=f.je);d&&!this.G&&(d=!1,e=b-188);this.G=!0;break;case this.H:h=a.subarray(h,e+188);f?this.j.push([h]):this.j.length&&this.j[this.j.length-1]&&this.j[this.j.length-1].push(h);break;case this.u:h=a.subarray(h,e+188);f?this.i.push([h]):this.i.length&&
307
307
  this.i[this.i.length-1]&&this.i[this.i.length-1].push(h);break;case this.C:h=a.subarray(h,e+188);f?this.l.push([h]):this.l.length&&this.l[this.l.length-1]&&this.l[this.l.length-1].push(h);break;default:d=!0}}return this};
308
308
  function oi(a){if(1!==(a[0]<<16|a[1]<<8|a[2]))return null;var b={data:new Uint8Array(0),packetLength:a[4]<<8|a[5],pts:null,dts:null,nalus:[]};if(b.packetLength&&b.packetLength>a.byteLength-6)return null;var c=a[7];c&192&&(b.pts=536870912*(a[9]&14)+4194304*(a[10]&255)+16384*(a[11]&254)+128*(a[12]&255)+(a[13]&254)/2,b.dts=b.pts,c&64&&(b.dts=536870912*(a[14]&14)+4194304*(a[15]&255)+16384*(a[16]&254)+128*(a[17]&255)+(a[18]&254)/2));c=a[8]+9;if(a.byteLength<=c)return null;b.data=a.subarray(c);return b}
309
- p.Ni=function(a){Ae("TsParser","Please use parseNalus function instead.");return this.Uf(a)};
310
- p.Uf=function(a,b,c){var d=a.pts?a.pts/9E4:null;a=a.data;var e=a.byteLength,f=1;"hvc"==this.m&&(f=2);for(var g=c||0,h=[],k=-1,l=0,m,n=0;n<e;++n){var q=a[n];if(q){if(2<=g&&1==q){b&&!h.length&&-1==k&&(q=n-(3<g?3:g),c&&0!=q&&(q=a.subarray(0,q),b.data=jg(b.data,q),b.fullData=jg(b.fullData,q)));0<=k?(g=n-((3<g?3:g)+1),h.push({data:a.subarray(k+f,g+1),fullData:a.subarray(k,g+1),type:l,time:d})):b&&!h.length&&(k=n-g,0<k&&(k=a.subarray(0,k),b.data=jg(b.data,k),b.fullData=jg(b.fullData,k)));if(n>=e-f)return h;
311
- n++;k=n;l="hvc"==this.m?a[n]>>1&63:a[n]&31}g=0}else g++;n>=e-1&&0<=k&&0<=g&&(m={data:a.subarray(k+f,e),fullData:a.subarray(k,e),type:l,time:d})}m&&h.push(m);!h.length&&b&&(b.data=jg(b.data,a),b.fullData=jg(b.fullData,a));return h};p.getMetadata=function(){for(var a=[],b=t(this.l),c=b.next();!c.done;c=b.next())c=jg.apply(cg,w(c.value)),(c=oi(c))&&a.push({cueTime:c.pts?c.pts/9E4:null,data:c.data,frames:Sh(c.data),dts:c.dts,pts:c.pts});return a};
312
- p.jc=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=jg.apply(cg,w(c.value)),e=oi(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=jg(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};
313
- p.Ic=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=jg.apply(cg,w(d.value)),f=oi(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=jg(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.nalus=this.Uf(d,g,void 0),
314
- d.nalus.length&&(g=d.nalus[d.nalus.length-1]);this.g=this.g.filter(function(h){return h.nalus.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)};p.getStartTime=function(a){if("audio"==a){a=null;var b=this.jc();b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4);return a}return"video"==a?(a=null,b=this.Ic(!1),b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4),a):null};p.pd=function(){return{audio:this.s,video:this.m}};
315
- p.ee=function(){for(var a=[],b=t(this.Ic()),c=b.next();!c.done;c=b.next())a.push.apply(a,w(c.value.nalus));return a};p.oi=function(){Ae("TsParser","Please use getVideoInfo function instead.");var a=this.Df();return{height:a.height,width:a.width}};p.Df=function(){return"hvc"==this.m?pi(this):qi(this)};
309
+ p.Ni=function(a){Ae("TsParser.parseAvcNalus","Please use parseNalus function instead.");return this.Uf(a)};
310
+ p.Uf=function(a,b,c){var d=a.pts?a.pts/9E4:null;a=a.data;var e=a.byteLength,f=1;"hvc"==this.m&&(f=2);for(var g=c||0,h=[],k=-1,l=0,m,n=0;n<e;++n){var q=a[n];if(q){if(2<=g&&1==q){b&&!h.length&&-1==k&&(q=n-(3<g?3:g),c&&0!=q&&(q=a.subarray(0,q),b.data=ig(b.data,q),b.fullData=ig(b.fullData,q)));0<=k?(g=n-((3<g?3:g)+1),h.push({data:a.subarray(k+f,g+1),fullData:a.subarray(k,g+1),type:l,time:d})):b&&!h.length&&(k=n-g,0<k&&(k=a.subarray(0,k),b.data=ig(b.data,k),b.fullData=ig(b.fullData,k)));if(n>=e-f)return h;
311
+ n++;k=n;l="hvc"==this.m?a[n]>>1&63:a[n]&31}g=0}else g++;n>=e-1&&0<=k&&0<=g&&(m={data:a.subarray(k+f,e),fullData:a.subarray(k,e),type:l,time:d})}m&&h.push(m);!h.length&&b&&(b.data=ig(b.data,a),b.fullData=ig(b.fullData,a));return h};p.getMetadata=function(){for(var a=[],b=t(this.l),c=b.next();!c.done;c=b.next())c=ig.apply(cg,w(c.value)),(c=oi(c))&&a.push({cueTime:c.pts?c.pts/9E4:null,data:c.data,frames:Sh(c.data),dts:c.dts,pts:c.pts});return a};
312
+ p.kc=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=ig.apply(cg,w(c.value)),e=oi(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=ig(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};
313
+ p.Ic=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=ig.apply(cg,w(d.value)),f=oi(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=ig(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.nalus=this.Uf(d,g,void 0),
314
+ d.nalus.length&&(g=d.nalus[d.nalus.length-1]);this.g=this.g.filter(function(h){return h.nalus.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)};p.getStartTime=function(a){if("audio"==a){a=null;var b=this.kc();b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4);return a}return"video"==a?(a=null,b=this.Ic(!1),b.length&&(a=b[0],a=Math.min(a.dts,a.pts)/9E4),a):null};p.pd=function(){return{audio:this.s,video:this.m}};
315
+ p.ee=function(){for(var a=[],b=t(this.Ic()),c=b.next();!c.done;c=b.next())a.push.apply(a,w(c.value.nalus));return a};p.oi=function(){Ae("TsParser.getVideoResolution","Please use getVideoInfo function instead.");var a=this.Df();return{height:a.height,width:a.width}};p.Df=function(){return"hvc"==this.m?pi(this):qi(this)};
316
316
  function qi(a){var b={height:null,width:null,va:null};a=a.ee();if(!a.length)return b;a=a.find(function(q){return 7==q.type});if(!a)return b;a=new ci(a.data);var c=ji(a),d=ji(a),e=ji(a);hi(a);if(ri.includes(c)){var f=Q(a);3===f&&ei(a,1);hi(a);hi(a);ei(a,1);if(S(a)){f=3!==f?8:12;for(var g=0;g<f;g++)S(a)&&(6>g?ki(a,16):ki(a,64))}}hi(a);f=Q(a);if(0===f)Q(a);else if(1===f)for(ei(a,1),hi(a),hi(a),f=Q(a),g=0;g<f;g++)hi(a);hi(a);ei(a,1);f=Q(a);g=Q(a);var h=fi(a,1);0===h&&ei(a,1);ei(a,1);var k=0,l=0,m=0,n=
317
317
  0;S(a)&&(k=Q(a),l=Q(a),m=Q(a),n=Q(a));b.height=String((2-h)*(g+1)*16-2*m-2*n);b.width=String(16*(f+1)-2*k-2*l);b.va="avc1."+("0"+c.toString(16).toUpperCase()).slice(-2)+("0"+d.toString(16).toUpperCase()).slice(-2)+("0"+e.toString(16).toUpperCase()).slice(-2);return b}
318
318
  function pi(a){var b={height:null,width:null,va:null};a=a.ee();if(!a.length)return b;a=a.find(function(B){return 33==B.type});if(!a)return b;var c=new ci(a.fullData,!0);ji(c);ji(c);fi(c,4);var d=fi(c,3);S(c);var e=fi(c,2),f=fi(c,1),g=fi(c,5),h=fi(c,32);a=ji(c);for(var k=ji(c),l=ji(c),m=ji(c),n=ji(c),q=ji(c),r=ji(c),u=[],v=[],y=0;y<d;y++)u.push(S(c)),v.push(S(c));if(0<d)for(y=d;8>y;y++)fi(c,2);for(y=0;y<d;y++)u[y]&&fi(c,88),v[y]&&ji(c);Q(c);d=Q(c);3==d&&fi(c,1);u=Q(c);v=Q(c);var z=y=0,x=0,A=0;S(c)&&
319
319
  (y+=Q(c),z+=Q(c),x+=Q(c),A+=Q(c));b.width=String(u-(y+z)*(1===d||2===d?2:1));b.height=String(v-(x+A)*(1===d?2:1));c=function(B){for(var C=0,E=0;32>E;E++)C|=(B>>E&1)<<31-E;return C>>>0}(h);f=1==f?"H":"L";e="hvc1"+("."+["","A","B","C"][e]+g);e+="."+c.toString(16).toUpperCase();e+="."+f+r;q&&(e+="."+q.toString(16).toUpperCase());n&&(e+="."+n.toString(16).toUpperCase());m&&(e+="."+m.toString(16).toUpperCase());l&&(e+="."+l.toString(16).toUpperCase());k&&(e+="."+k.toString(16).toUpperCase());a&&(e+="."+
320
320
  a.toString(16).toUpperCase());b.va=e;return b}function si(a){return 0>ni(a)?!1:!0}function ni(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}M("shaka.util.TsParser",mi);mi.syncOffset=ni;mi.probe=si;mi.prototype.getVideoInfo=mi.prototype.Df;mi.prototype.getVideoResolution=mi.prototype.oi;mi.prototype.getVideoNalus=mi.prototype.ee;mi.prototype.getCodecs=mi.prototype.pd;mi.prototype.getStartTime=mi.prototype.getStartTime;
321
- mi.prototype.getVideoData=mi.prototype.Ic;mi.prototype.getAudioData=mi.prototype.jc;mi.prototype.getMetadata=mi.prototype.getMetadata;mi.prototype.parseNalus=mi.prototype.Uf;mi.prototype.parseAvcNalus=mi.prototype.Ni;mi.prototype.parse=mi.prototype.parse;mi.prototype.clearData=mi.prototype.clearData;mi.Timescale=9E4;var ri=[100,110,122,244,44,83,86,118,128,138,139,134];function ti(a,b,c){this.g=null;this.s=-1;this.l=a;this.i=b;this.m=c;this.j=!1;a:{"undefined"===typeof libDPIModule&&Sa("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,Ae("LcevcDil","lcevc_dil.js is deprecated, please use lcevc_dec.js instead");else{Sa("Could not find LCEVC Library on this page");a=!1;break a}"undefined"===typeof this.h.SupportObject?(Sa("Could not find LCEVC Library on this page"),
321
+ mi.prototype.getVideoData=mi.prototype.Ic;mi.prototype.getAudioData=mi.prototype.kc;mi.prototype.getMetadata=mi.prototype.getMetadata;mi.prototype.parseNalus=mi.prototype.Uf;mi.prototype.parseAvcNalus=mi.prototype.Ni;mi.prototype.parse=mi.prototype.parse;mi.prototype.clearData=mi.prototype.clearData;mi.Timescale=9E4;var ri=[100,110,122,244,44,83,86,118,128,138,139,134];function ti(a,b,c){this.g=null;this.s=-1;this.l=a;this.i=b;this.m=c;this.j=!1;a:{"undefined"===typeof libDPIModule&&Sa("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,Ae("LcevcDil","lcevc_dil.js is deprecated, please use lcevc_dec.js instead");else{Sa("Could not find LCEVC Library on this page");a=!1;break a}"undefined"===typeof this.h.SupportObject?(Sa("Could not find LCEVC Library on this page"),
322
322
  a=!1):(this.h.SupportObject.SupportStatus||Sa(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 ui(a){a.g&&a.i.classList.add("shaka-hidden")}
323
323
  ti.prototype.release=function(){this.g&&(this.g.close(),this.g=null)};function vi(a,b,c){var d=wi,e=xi;switch(b.mimeType){case "video/webm":d=yi;break;case "video/mp4":d=zi}switch(c){case "DASH":e=Ai;break;case "HLS":e=Bi}a.g&&(a.s=b.id,a.g.setLevelSwitching(b.id,!0),a.g.setContainerFormat(d),a.j||a.g.setStreamingFormat(e))}M("shaka.lcevc.Dec",ti);ti.prototype.release=ti.prototype.release;var wi=0,yi=1,zi=2,Bi=0,Ai=1,xi=-1;function Ci(a,b,c,d){var e=this;this.i=a;this.G=null;this.H=b;this.g={};this.I={};this.ea={};this.h=null;this.V=!1;this.ra=c||function(){};this.P=d||null;this.j={};this.u=new Af;this.m={};this.J=null;this.L=new $e;this.M="";this.Z=!1;this.l=Di(this,this.L);this.D=!1;this.K=new yf(function(){return Ei(e)});this.C=!1;this.U="UNKNOWN";this.qa=this.ha=!1;this.sa=new $e;this.s=!1;this.$=!0}
324
324
  function Di(a,b){if(window.ManagedMediaSource){a.i.disableRemotePlayback=!0;var c=new ManagedMediaSource;a.u.o(c,"startstreaming",function(){a.$=!0});a.u.o(c,"endstreaming",function(){a.$=!1});a.u.ka(c,"sourceopen",function(){URL.revokeObjectURL(a.M);b.resolve()});a.u.ka(a.i,"playing",function(){a.Z=!0});a.M=Gi(c);a.i.src=a.M;return c}c=new MediaSource;a.u.ka(c,"sourceopen",function(){URL.revokeObjectURL(a.M);b.resolve()});a.u.ka(a.i,"playing",function(){a.Z=!0});a.M=Gi(c);a.i.src=a.M;return c}
@@ -351,70 +351,70 @@ function aj(a,b,c,d){var e,f,g,h,k,l,m,n,q,r,u;return K(function(v){if(1==v.g){i
351
351
  hj(a,d),3)}return v.return(!0)})}function ij(a,b,c){if(b==Jb)var d=!1;else{d=gd(id(a.I[b]))[0];var e=hd(a.I[b]),f=bd(c.mimeType,c.codecs),g=a.G.forceTransmux;if(!dc(f)||!a.C&&cd.includes(f))g=!0;c=dd(c.mimeType,c.codecs);g&&(g=Wc(c))&&(g=g(),f=g.convertCodecs(b,c),g.destroy());b=gd(id(f))[0];f=hd(f);d=d!==b||e!==f}return d?"smooth"!==a.G.codecSwitchingStrategy||!fc()||a.s:!1}var Gi=window.URL.createObjectURL,Ji="sequence";function jj(a,b,c){this.i=a;this.s=b;this.C=this.j=Infinity;this.g=1;this.h=this.l=null;this.u=0;this.G=!0;this.H=0;this.D=void 0===c?!0:c;this.I=0;this.m=!1}p=jj.prototype;p.getDuration=function(){return this.j};p.ai=function(){return this.g};p.ig=function(a){this.i=a};p.fb=function(a){this.j=a};p.di=function(){return this.i};p.eh=function(a){this.u=a};p.Rc=function(a){this.G=a};p.Ge=function(a){this.C=a};p.fh=function(a){this.s=a};p.Th=function(){return this.s};
352
352
  p.Yg=function(a,b){if(0!=a.length){var c=a[a.length-1].end+b;this.we(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.D&&!this.m&&(this.i=(Date.now()+this.u)/1E3-this.h-this.g)}};
353
353
  p.yd=function(a){if(0!=a.length){var b=a[0].startTime,c=a[0].endTime,d=(Date.now()+this.u)/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.we(b);this.h=Math.max(this.h,c);null!=this.i&&this.D&&!this.m&&(this.i=d-this.h-this.g)}};p.oe=function(){this.m=!0};p.Di=function(){return this.m};p.we=function(a){this.l=null==this.l?a:Math.min(this.l,a)};
354
- p.Pf=function(a){this.g=Math.max(this.g,a)};p.offset=function(a){null!=this.l&&(this.l+=a);null!=this.h&&(this.h+=a)};p.R=function(){return Infinity==this.j&&!this.G};p.pc=function(){return Infinity!=this.j&&!this.G};p.yb=function(){return Math.max(this.H,this.Yb()-this.C)};p.jh=function(a){this.H=a};p.Yb=function(){return this.R()||this.pc()?Math.min(Math.max(0,(Date.now()+this.u)/1E3-this.g-this.i)+this.I,this.j):this.h?Math.min(this.h,this.j):this.j};
355
- p.rd=function(a){var b=Math.max(this.l,this.H);return Infinity==this.C?Math.ceil(1E3*b)/1E3:Math.max(b,Math.min(this.Yb()-this.C+a,this.Lb()))};p.Hc=function(){return this.rd(0)};p.Lb=function(){return Math.max(0,this.Yb()-(this.R()||this.pc()?this.s:0))};p.nh=function(){return null==this.i||null!=this.h&&this.D?!1:!0};p.dh=function(a){this.I=a};M("shaka.media.PresentationTimeline",jj);jj.prototype.setAvailabilityTimeOffset=jj.prototype.dh;jj.prototype.usingPresentationStartTime=jj.prototype.nh;
356
- jj.prototype.getSeekRangeEnd=jj.prototype.Lb;jj.prototype.getSeekRangeStart=jj.prototype.Hc;jj.prototype.getSafeSeekRangeStart=jj.prototype.rd;jj.prototype.getSegmentAvailabilityEnd=jj.prototype.Yb;jj.prototype.setUserSeekStart=jj.prototype.jh;jj.prototype.getSegmentAvailabilityStart=jj.prototype.yb;jj.prototype.isInProgress=jj.prototype.pc;jj.prototype.isLive=jj.prototype.R;jj.prototype.offset=jj.prototype.offset;jj.prototype.notifyMaxSegmentDuration=jj.prototype.Pf;
354
+ p.Pf=function(a){this.g=Math.max(this.g,a)};p.offset=function(a){null!=this.l&&(this.l+=a);null!=this.h&&(this.h+=a)};p.R=function(){return Infinity==this.j&&!this.G};p.pc=function(){return Infinity!=this.j&&!this.G};p.yb=function(){return Math.max(this.H,this.$b()-this.C)};p.jh=function(a){this.H=a};p.$b=function(){return this.R()||this.pc()?Math.min(Math.max(0,(Date.now()+this.u)/1E3-this.g-this.i)+this.I,this.j):this.h?Math.min(this.h,this.j):this.j};
355
+ p.rd=function(a){var b=Math.max(this.l,this.H);return Infinity==this.C?Math.ceil(1E3*b)/1E3:Math.max(b,Math.min(this.$b()-this.C+a,this.Mb()))};p.Hc=function(){return this.rd(0)};p.Mb=function(){return Math.max(0,this.$b()-(this.R()||this.pc()?this.s:0))};p.nh=function(){return null==this.i||null!=this.h&&this.D?!1:!0};p.dh=function(a){this.I=a};M("shaka.media.PresentationTimeline",jj);jj.prototype.setAvailabilityTimeOffset=jj.prototype.dh;jj.prototype.usingPresentationStartTime=jj.prototype.nh;
356
+ jj.prototype.getSeekRangeEnd=jj.prototype.Mb;jj.prototype.getSeekRangeStart=jj.prototype.Hc;jj.prototype.getSafeSeekRangeStart=jj.prototype.rd;jj.prototype.getSegmentAvailabilityEnd=jj.prototype.$b;jj.prototype.setUserSeekStart=jj.prototype.jh;jj.prototype.getSegmentAvailabilityStart=jj.prototype.yb;jj.prototype.isInProgress=jj.prototype.pc;jj.prototype.isLive=jj.prototype.R;jj.prototype.offset=jj.prototype.offset;jj.prototype.notifyMaxSegmentDuration=jj.prototype.Pf;
357
357
  jj.prototype.notifyMinSegmentStartTime=jj.prototype.we;jj.prototype.isStartTimeLocked=jj.prototype.Di;jj.prototype.lockStartTime=jj.prototype.oe;jj.prototype.notifySegments=jj.prototype.yd;jj.prototype.notifyTimeRange=jj.prototype.Yg;jj.prototype.getDelay=jj.prototype.Th;jj.prototype.setDelay=jj.prototype.fh;jj.prototype.setSegmentAvailabilityDuration=jj.prototype.Ge;jj.prototype.setStatic=jj.prototype.Rc;jj.prototype.setClockOffset=jj.prototype.eh;jj.prototype.getPresentationStartTime=jj.prototype.di;
358
358
  jj.prototype.setDuration=jj.prototype.fb;jj.prototype.setPresentationStartTime=jj.prototype.ig;jj.prototype.getMaxSegmentDuration=jj.prototype.ai;jj.prototype.getDuration=jj.prototype.getDuration;function kj(a,b,c){this.j=c;this.l=a;this.u=lj(a);this.g=a.g.currentTime;this.m=Date.now()/1E3;this.h=!1;this.s=0;this.C=b;this.i=function(){}}kj.prototype.release=function(){this.j=this.l=null;this.i=function(){}};function mj(a,b){a.i=b}function nj(a){this.g=a}function lj(a){if(a.g.paused||0==a.g.buffered.length)var b=!1;else a:{b=a.g.currentTime;a=t(Lh(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 oj(a,b,c,d,e){var f=this;this.C=e;this.g=a;this.D=b;this.u=c;this.l=new Af;this.j=!1;this.H=a.readyState;this.G=this.i=0;this.h=d;this.s=!1;this.l.o(a,"waiting",function(){return pj(f)});this.m=(new vd(function(){pj(f)})).ya(this.u.gapJumpTimerTime)}oj.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.D=this.C=null};oj.prototype.Sf=function(){this.s=!0;pj(this)};
359
359
  function pj(a){if(0!=a.g.readyState){if(a.g.seeking){if(!a.j)return}else a.j=!1;if(!a.g.paused||a.g.currentTime==a.i&&(a.g.autoplay||a.g.currentTime!=a.i)){a.g.readyState!=a.H&&(a.H=a.g.readyState);var b;if(!(b=!a.h)){b=a.h;var c=b.l,d=lj(c),e=c.g.currentTime,f=Date.now()/1E3;if(b.g!=e||b.u!=d)b.m=f,b.g=e,b.u=d,b.h=!1;e=f-b.m;if(d=e>=b.C&&d&&!b.h)b.i(b.g,e),b.h=!0,b.g=c.g.currentTime,b.s++,b.j(new O("stalldetected"));b=!d}b&&(b=a.g.currentTime,c=a.g.buffered,d=Mh(c,b,a.u.gapDetectionThreshold),null==
360
- d||0==d&&!a.s||(e=c.start(d),e>=a.D.Lb()||.001>e-b||(0!=d&&c.end(d-1),a.g.currentTime=e,b==a.i&&(a.i=e),a.G++,a.C(new O("gapjumped")))))}}};function qj(a,b,c,d){b==HTMLMediaElement.HAVE_NOTHING||a.readyState>=b?d():(b=rj.value().get(b),c.ka(a,b,d))}var rj=new Ff(function(){return new Map([[HTMLMediaElement.HAVE_METADATA,"loadedmetadata"],[HTMLMediaElement.HAVE_CURRENT_DATA,"loadeddata"],[HTMLMediaElement.HAVE_FUTURE_DATA,"canplay"],[HTMLMediaElement.HAVE_ENOUGH_DATA,"canplaythrough"]])});function sj(a,b,c,d){var e=this;this.g=a;this.m=b;this.u=c;this.l=null;this.j=function(){null==e.l&&(e.l=d());return e.l};this.s=!1;this.h=new Af;this.i=new tj(a);qj(this.g,HTMLMediaElement.HAVE_METADATA,this.h,function(){uj(e,e.j())})}sj.prototype.release=function(){this.h&&(this.h.release(),this.h=null);null!=this.i&&(this.i.release(),this.i=null);this.m=function(){};this.g=null};function vj(a){return a.s?a.g.currentTime:a.j()}
360
+ d||0==d&&!a.s||(e=c.start(d),e>=a.D.Mb()||.001>e-b||(0!=d&&c.end(d-1),a.g.currentTime=e,b==a.i&&(a.i=e),a.G++,a.C(new O("gapjumped")))))}}};function qj(a,b,c,d){b==HTMLMediaElement.HAVE_NOTHING||a.readyState>=b?d():(b=rj.value().get(b),c.ka(a,b,d))}var rj=new Ff(function(){return new Map([[HTMLMediaElement.HAVE_METADATA,"loadedmetadata"],[HTMLMediaElement.HAVE_CURRENT_DATA,"loadeddata"],[HTMLMediaElement.HAVE_FUTURE_DATA,"canplay"],[HTMLMediaElement.HAVE_ENOUGH_DATA,"canplaythrough"]])});function sj(a,b,c,d){var e=this;this.g=a;this.m=b;this.u=c;this.l=null;this.j=function(){null==e.l&&(e.l=d());return e.l};this.s=!1;this.h=new Af;this.i=new tj(a);qj(this.g,HTMLMediaElement.HAVE_METADATA,this.h,function(){uj(e,e.j())})}sj.prototype.release=function(){this.h&&(this.h.release(),this.h=null);null!=this.i&&(this.i.release(),this.i=null);this.m=function(){};this.g=null};function vj(a){return a.s?a.g.currentTime:a.j()}
361
361
  function wj(a,b){0<a.g.readyState?xj(a.i,b):qj(a.g,HTMLMediaElement.HAVE_METADATA,a.h,function(){uj(a,a.j())})}function uj(a,b){.001>Math.abs(a.g.currentTime-b)?yj(a):(a.h.ka(a.g,"seeking",function(){yj(a)}),xj(a.i,a.g.currentTime&&0!=a.g.currentTime?a.g.currentTime:b))}function yj(a){a.s=!0;a.h.o(a.g,"seeking",function(){return a.m()});a.u(a.g.currentTime)}
362
362
  function tj(a){var b=this;this.h=a;this.m=10;this.l=this.j=this.i=0;this.g=new vd(function(){0>=b.i?b.g.stop():b.h.currentTime!=b.j?b.g.stop():(b.h.currentTime=b.l,b.i--)})}tj.prototype.release=function(){this.g&&(this.g.stop(),this.g=null);this.h=null};function xj(a,b){a.j=a.h.currentTime;a.l=b;a.i=a.m;a.h.currentTime=b;a.g.ya(.1)};function zj(a){this.g=a;this.j=!1;this.h=null;this.i=new Af}p=zj.prototype;p.Ve=function(){function a(){null==b.h||0==b.h?b.j=!0:(b.i.ka(b.g,"seeking",function(){b.j=!0}),b.g.currentTime=Math.max(0,b.g.currentTime+b.h))}var b=this;qj(this.g,HTMLMediaElement.HAVE_CURRENT_DATA,this.i,function(){a()})};p.release=function(){this.i&&(this.i.release(),this.i=null);this.g=null};p.We=function(a){this.h=this.j?this.h:a};p.Sd=function(){return(this.j?this.g.currentTime:this.h)||0};p.wg=function(){return 0};
363
363
  p.vg=function(){return 0};p.Xg=function(){};
364
364
  function Aj(a,b,c,d,e,f){var g=this;this.i=a;this.g=b.presentationTimeline;this.D=b.minBufferTime||0;this.l=c;this.C=e;this.u=null;this.s=Bj(a,c,f);this.j=new oj(a,b.presentationTimeline,c,this.s,f);this.h=new sj(a,function(){a:{var h=g.j;h.j=!0;h.s=!1;var k=vj(g.h);h=Cj(g,k);if(.001<Math.abs(h-k)&&(k=Date.now()/1E3,!g.u||g.u<k-1)){g.u=k;wj(g.h,h);h=void 0;break a}g.C();h=void 0}return h},function(h){var k=g.j;k.g.seeking&&!k.j&&(k.j=!0,k.i=h)},function(){var h=d;null==h?h=Infinity>g.g.getDuration()?
365
- g.g.Hc():g.g.Lb():0>h&&(h=g.g.Lb()+h);return Dj(g,Ej(g,h))});this.m=new vd(function(){if(0!=g.i.readyState&&!g.i.paused){var h=vj(g.h),k=g.g.Hc(),l=g.g.Lb();3>l-k&&(k=l-3);h<k&&(h=Cj(g,h),g.i.currentTime=h)}})}p=Aj.prototype;p.Ve=function(){this.m.ya(.25)};p.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.C=function(){}};p.We=function(a){wj(this.h,a)};
365
+ g.g.Hc():g.g.Mb():0>h&&(h=g.g.Mb()+h);return Dj(g,Ej(g,h))});this.m=new vd(function(){if(0!=g.i.readyState&&!g.i.paused){var h=vj(g.h),k=g.g.Hc(),l=g.g.Mb();3>l-k&&(k=l-3);h<k&&(h=Cj(g,h),g.i.currentTime=h)}})}p=Aj.prototype;p.Ve=function(){this.m.ya(.25)};p.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.C=function(){}};p.We=function(a){wj(this.h,a)};
366
366
  p.Sd=function(){var a=vj(this.h);return 0<this.i.readyState&&!this.i.paused?Ej(this,a):a};p.wg=function(){return this.s?this.s.s:0};p.vg=function(){return this.j.G};p.Xg=function(){this.j.Sf()};function Dj(a,b){var c=a.g.getDuration();return b>=c?c-a.l.durationBackoff:b}
367
- function Cj(a,b){var c=Math.max(a.D,a.l.rebufferingGoal),d=a.l.safeSeekOffset,e=a.g.Hc(),f=a.g.Lb(),g=a.g.getDuration();3>f-e&&(e=f-3);var h=a.g.rd(c),k=a.g.rd(d);c=a.g.rd(c+d);return b>=g?Dj(a,b):b>f?f:b<e?Jh(a.i.buffered,k)?k:c:b>=h||Jh(a.i.buffered,b)?b:c}function Ej(a,b){var c=a.g.Hc();if(b<c)return c;a=a.g.Lb();return b>a?a:b}
368
- function Bj(a,b,c){if(!b.stallEnabled)return null;var d=b.stallSkip;b=new kj(new nj(a),b.stallThreshold,c);mj(b,function(){d?a.currentTime+=d:(a.pause(),a.play())});return b};function Fj(a){this.g=a;this.l=null;this.j=0;this.s=!1}p=Fj.prototype;p.lc=function(){return this.g.length};p.release=function(){this.s||(this.g=[],this.l&&this.l.stop(),this.l=null)};p.Ii=function(){this.s=!0};function Gj(a,b){a=t(a.g);for(var c=a.next();!c.done;c=a.next())b(c.value)}p.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
+ function Cj(a,b){var c=Math.max(a.D,a.l.rebufferingGoal),d=a.l.safeSeekOffset,e=a.g.Hc(),f=a.g.Mb(),g=a.g.getDuration();3>f-e&&(e=f-3);var h=a.g.rd(c),k=a.g.rd(d);c=a.g.rd(c+d);return b>=g?Dj(a,b):b>f?f:b<e?Jh(a.i.buffered,k)?k:c:b>=h||Jh(a.i.buffered,b)?b:c}function Ej(a,b){var c=a.g.Hc();if(b<c)return c;a=a.g.Mb();return b>a?a:b}
368
+ function Bj(a,b,c){if(!b.stallEnabled)return null;var d=b.stallSkip;b=new kj(new nj(a),b.stallThreshold,c);mj(b,function(){d?a.currentTime+=d:(a.pause(),a.play())});return b};function Fj(a){this.g=a;this.m=null;this.j=0;this.s=!1}p=Fj.prototype;p.Zb=function(){return this.g.length};p.release=function(){this.s||(this.g=[],this.m&&this.m.stop(),this.m=null)};p.Ii=function(){this.s=!0};function Gj(a,b){a=t(a.g);for(var c=a.next();!c.done;c=a.next())b(c.value)}p.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};
369
369
  p.get=function(a){if(0==this.g.length)return null;a-=this.j;return 0>a||a>=this.g.length?null:this.g[a]};p.offset=function(a){if(!this.s)for(var b=t(this.g),c=b.next();!c.done;c=b.next())c.value.offset(a)};p.se=function(a){if(!this.s&&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))}};
370
370
  p.xd=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.se(a);this.wb(b)};p.wb=function(a){if(!this.s){var b=this.g.length;this.g=this.g.filter(function(c){return c.endTime>a});this.j+=b-this.g.length}};
371
371
  p.Cc=function(a,b,c){c=void 0===c?!1:c;if(!this.s){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 Fh(a.startTime,b,a.I,a.gb,a.Ma,a.g,a.timestampOffset,a.appendWindowStart,a.appendWindowEnd,a.h,a.tilesLayout,a.H,a.ma,a.status,a.aes128Key),this.g[this.g.length-1].j=a.j)}};
372
- p.Je=function(a,b){var c=this;this.s||(this.l&&this.l.stop(),this.l=new vd(function(){var d=b();d?c.g.push.apply(c.g,w(d)):(c.l.stop(),c.l=null)}),this.l.ya(a))};Fj.prototype[Symbol.iterator]=function(){return this.kc(0)};
373
- Fj.prototype.kc=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.l;)e--,f=c.h[e];if(!f.l)return Ra("No independent partial segment found!"),null;b++;d=e-1;break}}return new Hj(this,b,d)};function Ij(a,b,c){a=new Fh(a,a+b,function(){return c},0,null,null,a,a,a+b);return new Fj([a])}M("shaka.media.SegmentIndex",Fj);Fj.forSingleSegment=Ij;
374
- Fj.prototype.getIteratorForTime=Fj.prototype.kc;Fj.prototype.updateEvery=Fj.prototype.Je;Fj.prototype.fit=Fj.prototype.Cc;Fj.prototype.evict=Fj.prototype.wb;Fj.prototype.mergeAndEvict=Fj.prototype.xd;Fj.prototype.offset=Fj.prototype.offset;Fj.prototype.get=Fj.prototype.get;Fj.prototype.find=Fj.prototype.find;Fj.prototype.markImmutable=Fj.prototype.Ii;Fj.prototype.release=Fj.prototype.release;function Hj(a,b,c){this.i=a;this.g=b;this.h=c}Hj.prototype.Eh=function(){return this.g};
372
+ p.Je=function(a,b){var c=this;this.s||(this.m&&this.m.stop(),this.m=new vd(function(){var d=b();d?c.g.push.apply(c.g,w(d)):(c.m.stop(),c.m=null)}),this.m.ya(a))};Fj.prototype[Symbol.iterator]=function(){return this.lc(0)};
373
+ Fj.prototype.lc=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.l;)e--,f=c.h[e];if(!f.l)return Ra("No independent partial segment found!"),null;b++;d=e-1;break}}return new Hj(this,b,d)};function Ij(a,b,c){a=new Fh(a,a+b,function(){return c},0,null,null,a,a,a+b);return new Fj([a])}M("shaka.media.SegmentIndex",Fj);Fj.forSingleSegment=Ij;
374
+ Fj.prototype.getIteratorForTime=Fj.prototype.lc;Fj.prototype.updateEvery=Fj.prototype.Je;Fj.prototype.fit=Fj.prototype.Cc;Fj.prototype.evict=Fj.prototype.wb;Fj.prototype.mergeAndEvict=Fj.prototype.xd;Fj.prototype.offset=Fj.prototype.offset;Fj.prototype.get=Fj.prototype.get;Fj.prototype.find=Fj.prototype.find;Fj.prototype.markImmutable=Fj.prototype.Ii;Fj.prototype.release=Fj.prototype.release;function Hj(a,b,c){this.i=a;this.g=b;this.h=c}Hj.prototype.Eh=function(){return this.g};
375
375
  Hj.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};Hj.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}};M("shaka.media.SegmentIterator",Hj);Hj.prototype.next=Hj.prototype.next;Hj.prototype.current=Hj.prototype.current;
376
- Hj.prototype.currentPosition=Hj.prototype.Eh;function Jj(){Fj.call(this,[]);this.h=[]}pa(Jj,Fj);p=Jj.prototype;p.clone=function(){var a=new Jj;a.h=this.h.slice();return a};p.release=function(){for(var a=t(this.h),b=a.next();!b.done;b=a.next())b.value.release();this.h=[]};p.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.lc()}return null};
377
- p.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.lc()}return null};p.offset=function(){};p.se=function(){};p.wb=function(){};p.xd=function(){};p.Cc=function(){};p.Je=function(){};M("shaka.media.MetaSegmentIndex",Jj);Jj.prototype.updateEvery=Jj.prototype.Je;Jj.prototype.fit=Jj.prototype.Cc;Jj.prototype.mergeAndEvict=Jj.prototype.xd;Jj.prototype.evict=Jj.prototype.wb;Jj.prototype.merge=Jj.prototype.se;Jj.prototype.offset=Jj.prototype.offset;
376
+ Hj.prototype.currentPosition=Hj.prototype.Eh;function Jj(){Fj.call(this,[]);this.h=[]}pa(Jj,Fj);p=Jj.prototype;p.clone=function(){var a=new Jj;a.h=this.h.slice();return a};p.release=function(){for(var a=t(this.h),b=a.next();!b.done;b=a.next())b.value.release();this.h=[]};p.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.Zb()}return null};
377
+ p.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.Zb()}return null};p.offset=function(){};p.se=function(){};p.wb=function(){};p.xd=function(){};p.Cc=function(){};p.Je=function(){};M("shaka.media.MetaSegmentIndex",Jj);Jj.prototype.updateEvery=Jj.prototype.Je;Jj.prototype.fit=Jj.prototype.Cc;Jj.prototype.mergeAndEvict=Jj.prototype.xd;Jj.prototype.evict=Jj.prototype.wb;Jj.prototype.merge=Jj.prototype.se;Jj.prototype.offset=Jj.prototype.offset;
378
378
  Jj.prototype.get=Jj.prototype.get;Jj.prototype.find=Jj.prototype.find;Jj.prototype.release=Jj.prototype.release;function Kj(a){var b=this;this.g=a;this.h=this.g.ce();this.i=new vd(function(){b.g.Wg(.25*b.h)})}Kj.prototype.release=function(){this.set(this.Fc());this.i&&(this.i.stop(),this.i=null);this.g=null};Kj.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.ce()!=b&&this.g.jg(b);break a}catch(c){}this.i.ya(.25);0!=this.g.ce()&&this.g.jg(0)}};Kj.prototype.Fc=function(){return this.g.Fc()};function Lj(a){var b=this;this.h=a;this.g=new Set;this.i=(new vd(function(){Mj(b,!1)})).ya(.25)}Lj.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 Mj(a,b){for(var c=t(a.g),d=c.next();!d.done;d=c.next())d.value.j(a.h.currentTime,b)};function Nj(a){ab.call(this);this.g=new Map;this.h=a}pa(Nj,ab);Nj.prototype.release=function(){this.g.clear();ab.prototype.release.call(this)};function Oj(a,b){var c=a.g.get(b);c||(c={Bd:[],Fg:null,contentType:b},a.g.set(b,c));return c}function Pj(a,b,c){var d=Oj(a,b.contentType);Qj(a,d);a={Nf:b,position:c};d=d.Bd;b=d.findIndex(function(e){return e.position>=c});0<=b?d.splice(b,d[b].position==c?1:0,a):d.push(a)}
379
379
  Nj.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.Bd;for(var e=d.length-1;0<=e;e--){var f=d[e];if(f.position<=a){d=f.Nf;break a}}d=null}if(e=d)e=c.Fg,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);
380
380
  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.Fg=d,JSON.stringify(d),c=new O("qualitychange",new Map([["quality",d],["position",a]])),this.dispatchEvent(c))}};function Qj(a,b){if((a=a.h()[b.contentType])&&0<a.length){var c=a[0].start,d=a[a.length-1].end,e=b.Bd;b.Bd=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.Bd=[]};function Rj(a){ab.call(this);var b=this;this.g=new Set;this.i=a;this.h=(new vd(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 O("regionremove",new Map([["region",e]])),b.dispatchEvent(e))})).ya(2)}pa(Rj,ab);Rj.prototype.release=function(){this.g.clear();this.h.stop();ab.prototype.release.call(this)};function Sj(a,b){ab.call(this);var c=this;this.i=a;this.l=b;this.g=new Map;this.m=[{xc:null,wc:Tj,nc:function(d,e){return Uj(c,"enter",d,e)}},{xc:Vj,wc:Tj,nc:function(d,e){return Uj(c,"enter",d,e)}},{xc:Wj,wc:Tj,nc:function(d,e){return Uj(c,"enter",d,e)}},{xc:Tj,wc:Vj,nc:function(d,e){return Uj(c,"exit",d,e)}},{xc:Tj,wc:Wj,nc:function(d,e){return Uj(c,"exit",d,e)}},{xc:Vj,wc:Wj,nc:function(d,e){return Uj(c,"skip",d,e)}},{xc:Wj,wc:Vj,nc:function(d,e){return Uj(c,"skip",d,e)}}];this.h=new Af;this.h.o(this.i,
381
381
  "regionremove",function(d){c.g.delete(d.region)})}pa(Sj,ab);Sj.prototype.release=function(){this.i=null;this.g.clear();this.h.release();this.h=null;ab.prototype.release.call(this)};Sj.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?Vj:a>d.endTime?Wj:Tj;this.g.set(d,f);for(var g=t(this.m),h=g.next();!h.done;h=g.next())h=h.value,h.xc==e&&h.wc==f&&h.nc(d,b)}}};
382
- function Uj(a,b,c,d){b=new O(b,new Map([["region",c],["seeking",d]]));a.dispatchEvent(b)}var Vj=1,Tj=2,Wj=3;function Xj(a,b,c){this.i=a;this.h=b;this.j=0;this.l=c;this.g=new Map}function Yj(a,b,c){c=void 0===c?!1:c;if(a.h.segmentIndex){var d=a.h.segmentIndex.kc(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.m&&null!=e.Ma&&(b=!1),2==e.mc()&&(b=!1),b&&!a.g.has(e)&&(b=new Zj(a.l),ak(b,e,a.h),a.g.set(e,b)),a.j=e.startTime,e=d.next().value}}}
382
+ function Uj(a,b,c,d){b=new O(b,new Map([["region",c],["seeking",d]]));a.dispatchEvent(b)}var Vj=1,Tj=2,Wj=3;function Xj(a,b,c){this.i=a;this.h=b;this.j=0;this.l=c;this.g=new Map}function Yj(a,b,c){c=void 0===c?!1:c;if(a.h.segmentIndex){var d=a.h.segmentIndex.lc(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.m&&null!=e.Ma&&(b=!1),2==e.mc()&&(b=!1),b&&!a.g.has(e)&&(b=new Zj(a.l),ak(b,e,a.h),a.g.set(e,b)),a.j=e.startTime,e=d.next().value}}}
383
383
  function bk(a,b){if(a.h.segmentIndex&&a.g.size<a.i&&!a.g.has(b)){var c=new Zj(a.l);ak(c,b,a.h);a.g.set(b,c)}}function ck(a){if(0!==a.g.size){for(var b=t(a.g.keys()),c=b.next();!c.done;c=b.next())(c=c.value)&&dk(a,c);a.j=0}}function ek(a,b){b&&b!==a.h&&(ck(a),a.h=b)}function dk(a,b){var c=a.g.get(b);a.g.delete(b);c&&c.abort()}function Zj(a){this.i=a;this.g=this.h=null}
384
- function ak(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=jg(d,e):d=e,a.h?D(f,a.h(d),3):f.F(0);d=new Uint8Array(0);F(f)})})}Zj.prototype.abort=function(){this.g&&this.g.abort()};function fk(a,b,c,d,e){a=qf(a,d,e);if(0!=b||null!=c)a.headers.Range=c?"bytes="+b+"-"+c:"bytes="+b+"-";return a};function gk(a,b){var c=this;this.g=b;this.m=a;this.i=null;this.C=1;this.s=this.j=null;this.H=0;this.G=!1;this.h=new Map;this.D=!1;this.I=null;this.u=!1;this.l=new yf(function(){return hk(c)})}p=gk.prototype;p.destroy=function(){return this.l.destroy()};function hk(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,ik(e),b.push(jk(e));return D(f,Promise.all(b),2)}a.h.clear();a.g=null;a.m=null;a.i=null;F(f)})}
385
- p.configure=function(a){this.i=a;this.I=new Xe({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.Ga){var d=c.Ga,e=a.segmentPrefetchLimit;d.i=e;for(var f=Array.from(d.g.keys());f.length>e;){var g=f.pop();g&&dk(d,g)}0<a.segmentPrefetchLimit||
384
+ function ak(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=ig(d,e):d=e,a.h?D(f,a.h(d),3):f.F(0);d=new Uint8Array(0);F(f)})})}Zj.prototype.abort=function(){this.g&&this.g.abort()};function fk(a,b,c,d,e){a=qf(a,d,e);if(0!=b||null!=c)a.headers.Range=c?"bytes="+b+"-"+c:"bytes="+b+"-";return a};function gk(a,b){var c=this;this.g=b;this.m=a;this.i=null;this.C=1;this.s=this.j=null;this.H=0;this.G=!1;this.h=new Map;this.D=!1;this.I=null;this.u=!1;this.l=new yf(function(){return hk(c)})}p=gk.prototype;p.destroy=function(){return this.l.destroy()};function hk(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,ik(e),b.push(jk(e));return D(f,Promise.all(b),2)}a.h.clear();a.g=null;a.m=null;a.i=null;F(f)})}
385
+ p.configure=function(a){this.i=a;this.I=new We({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.Ga){var d=c.Ga,e=a.segmentPrefetchLimit;d.i=e;for(var f=Array.from(d.g.keys());f.length>e;){var g=f.pop();g&&dk(d,g)}0<a.segmentPrefetchLimit||
386
386
  (c.Ga=null)}else 0<a.segmentPrefetchLimit&&(c.Ga=kk(this,c.stream))};p.start=function(){var a=this;return K(function(b){if(1==b.g)return D(b,lk(a),2);zf(a.l);a.D=!0;F(b)})};
387
387
  function mk(a,b){var c,d,e,f,g,h,k;K(function(l){switch(l.g){case 1:return c=Kb,a.H++,d=a.H,ta(l,2),D(l,Zi(a.g.Y,c.za),4);case 4:va(l,3);break;case 2:if(e=wa(l),a.g)a.g.onError(e);case 3:f=bd(b.mimeType,b.codecs),Ii(a.g.Y,f,a.m.sequenceMode,b.external),g=a.g.Y.H,(h=g.isTextVisible()||a.i.alwaysStreamText)&&a.H==d&&(k=nk(a,b),a.h.set(c.za,k),ok(a,k,0)),F(l)}})}function pk(a){var b=a.h.get(Jb);b&&(ik(b),jk(b).catch(function(){}),a.h.delete(Jb));a.s=null}
388
388
  function qk(a,b){var c=a.h.get("video");if(c){var d=c.stream;if(d)if(b)(b=d.trickModeVideo)&&!c.uc&&(rk(a,b,!1,0,!1),c.uc=d);else if(d=c.uc)c.uc=null,rk(a,d,!0,0,!1)}}function sk(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.D&&(b.video&&rk(a,b.video,c,d,e,f),b.audio&&rk(a,b.audio,c,d,e,f))}function tk(a,b){K(function(c){if(1==c.g)return a.s=b,a.D?b.segmentIndex?c.F(2):D(c,b.createSegmentIndex(),2):c.return();rk(a,b,!0,0,!1);F(c)})}
389
- function rk(a,b,c,d,e,f){var g=a.h.get(b.type);g||b.type!=Jb?g&&(g.uc&&(b.trickModeVideo?(g.uc=b,b=b.trickModeVideo):g.uc=null),g.stream!=b||e)&&(g.Ga&&ek(g.Ga,b),b.type==Jb&&(e=bd(b.mimeType,b.codecs),Ii(a.g.Y,e,a.m.sequenceMode,b.external)),g.stream.closeSegmentIndex&&g.stream.closeSegmentIndex(),g.stream=b,g.ba=null,g.xg=!!f,c&&(g.ld?g.Ke=!0:g.Sa?(g.Qb=!0,g.Xd=d,g.Ke=!0):(ik(g),uk(a,g,!0,d).catch(function(h){if(a.g)a.g.onError(h)}))),vk(a,g).catch(function(h){if(a.g)a.g.onError(h)})):mk(a,b)}
389
+ function rk(a,b,c,d,e,f){var g=a.h.get(b.type);g||b.type!=Jb?g&&(g.uc&&(b.trickModeVideo?(g.uc=b,b=b.trickModeVideo):g.uc=null),g.stream!=b||e)&&(g.Ga&&ek(g.Ga,b),b.type==Jb&&(e=bd(b.mimeType,b.codecs),Ii(a.g.Y,e,a.m.sequenceMode,b.external)),g.stream.closeSegmentIndex&&g.stream.closeSegmentIndex(),g.stream=b,g.ba=null,g.xg=!!f,c&&(g.ld?g.Ke=!0:g.Sa?(g.Sb=!0,g.Xd=d,g.Ke=!0):(ik(g),uk(a,g,!0,d).catch(function(h){if(a.g)a.g.onError(h)}))),vk(a,g).catch(function(h){if(a.g)a.g.onError(h)})):mk(a,b)}
390
390
  function vk(a,b){var c,d;return K(function(e){if(1==e.g){if(!b.cb)return e.return();c=b.stream;d=b.cb;return c.segmentIndex?e.F(2):D(e,c.createSegmentIndex(),2)}if(b.cb!=d||b.stream!=c)return e.return();var f=a.g.be();var g=Oi(a.g.Y,b.type),h=b.stream.segmentIndex.find(b.Ra?b.Ra.endTime:f),k=null==h?null:b.stream.segmentIndex.get(h);h=k?k.Ma?k.Ma-k.gb:null:null;k&&!h&&(h=(k.endTime-k.getStartTime())*(b.stream.bandwidth||0)/8);h?((k=k.g)&&(h+=(k.Ma?k.Ma-k.gb:null)||0),k=a.g.getBandwidthEstimate(),
391
391
  f=8*h/k<(g||0)-f-Math.max(a.m.minBufferTime||0,a.i.rebufferingGoal)||b.cb.h.g>h?!0:!1):f=!1;f&&b.cb.abort();F(e)})}
392
392
  p.Fd=function(){if(this.g)for(var a=this.g.be(),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.ba&&(e=c.ba.current());if(!e||e.startTime>a||e.endTime<a)c.ba=null;e=this.g.Y;e.D?e=!1:d==Jb?(e=e.h,e=null==e.g||null==e.h?!1:a>=e.g&&a<e.h):(e=Ni(e,d),e=Jh(e,a));e||((null!=Oi(this.g.Y,d)||c.Sa)&&wk(this,c),c.cb&&(c.cb.abort(),c.cb=null),d===Jb&&(d=this.g.Y,d.J&&d.J.h()),c.Fd=!0)}};
393
- function wk(a,b){b.ld||b.Qb||(b.Sa?(b.Qb=!0,b.Xd=0):null==Mi(a.g.Y,b.type)?null==b.Cb&&ok(a,b,0):(ik(b),uk(a,b,!1,0).catch(function(c){if(a.g)a.g.onError(c)})))}
393
+ function wk(a,b){b.ld||b.Sb||(b.Sa?(b.Sb=!0,b.Xd=0):null==Mi(a.g.Y,b.type)?null==b.Cb&&ok(a,b,0):(ik(b),uk(a,b,!1,0).catch(function(c){if(a.g)a.g.onError(c)})))}
394
394
  function lk(a){var b,c,d,e,f,g,h,k,l;return K(function(m){if(1==m.g){b=Kb;if(!a.j)throw new P(2,5,5006);c=new Map;d=new Set;a.j.audio&&(c.set(b.W,a.j.audio),d.add(a.j.audio));a.j.video&&(c.set(b.ua,a.j.video),d.add(a.j.video));a.s&&(c.set(b.za,a.s),d.add(a.s));e=a.g.Y;return D(m,e.init(c,a.m.sequenceMode,a.m.type,a.m.ignoreManifestTimestampsInSegmentsMode),2)}zf(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=nk(a,k),a.h.set(h,l),ok(a,l,
395
- 0));F(m)})}function nk(a,b){return{stream:b,type:b.type,ba:null,Ga:kk(a,b),Ra:null,Mc:null,Kf:null,If:null,Hf:null,uc:null,endOfStream:!1,Sa:!1,Cb:null,Qb:!1,Xd:0,Ke:!1,ld:!1,Fd:!0,Of:!1,Xf:!1,td:!1,cb:null}}function kk(a,b){return"video"!==b.type&&"audio"!==b.type?null:0<a.i.segmentPrefetchLimit?new Xj(a.i.segmentPrefetchLimit,b,function(c,d,e){return xk(a,c,d,e)}):null}p.updateDuration=function(){var a=this.m.presentationTimeline.getDuration();Infinity>a?this.g.Y.fb(a):this.g.Y.fb(Math.pow(2,32))};
396
- function yk(a,b){var c,d,e,f,g;return K(function(h){switch(h.g){case 1:zf(a.l);if(b.Sa||null==b.Cb||b.ld)return h.return();b.Cb=null;if(!b.Qb){h.F(2);break}return D(h,uk(a,b,b.Ke,b.Xd),3);case 3:return h.return();case 2:if(b.stream.segmentIndex){h.F(4);break}c=b.stream;return D(h,b.stream.createSegmentIndex(),5);case 5:if(c!=b.stream)return c.closeSegmentIndex&&c.closeSegmentIndex(),b.Sa||b.Cb||ok(a,b,0),h.return();case 4:ta(h,6);d=zk(a,b);null!=d&&(ok(a,b,d),b.td=!1);va(h,7);break;case 6:return e=
395
+ 0));F(m)})}function nk(a,b){return{stream:b,type:b.type,ba:null,Ga:kk(a,b),Ra:null,Mc:null,Kf:null,If:null,Hf:null,uc:null,endOfStream:!1,Sa:!1,Cb:null,Sb:!1,Xd:0,Ke:!1,ld:!1,Fd:!0,Of:!1,Xf:!1,td:!1,cb:null}}function kk(a,b){return"video"!==b.type&&"audio"!==b.type?null:0<a.i.segmentPrefetchLimit?new Xj(a.i.segmentPrefetchLimit,b,function(c,d,e){return xk(a,c,d,e)}):null}p.updateDuration=function(){var a=this.m.presentationTimeline.getDuration();Infinity>a?this.g.Y.fb(a):this.g.Y.fb(Math.pow(2,32))};
396
+ function yk(a,b){var c,d,e,f,g;return K(function(h){switch(h.g){case 1:zf(a.l);if(b.Sa||null==b.Cb||b.ld)return h.return();b.Cb=null;if(!b.Sb){h.F(2);break}return D(h,uk(a,b,b.Ke,b.Xd),3);case 3:return h.return();case 2:if(b.stream.segmentIndex){h.F(4);break}c=b.stream;return D(h,b.stream.createSegmentIndex(),5);case 5:if(c!=b.stream)return c.closeSegmentIndex&&c.closeSegmentIndex(),b.Sa||b.Cb||ok(a,b,0),h.return();case 4:ta(h,6);d=zk(a,b);null!=d&&(ok(a,b,d),b.td=!1);va(h,7);break;case 6:return e=
397
397
  wa(h),D(h,Ak(a,b,e),8);case 8:return h.return();case 7:f=Array.from(a.h.values());if(!a.D||!f.every(function(k){return k.endOfStream})){h.F(0);break}return D(h,a.g.Y.endOfStream(),10);case 10:zf(a.l),g=a.g.Y.getDuration(),0!=g&&g<a.m.presentationTimeline.getDuration()&&a.m.presentationTimeline.fb(g),F(h)}})}
398
398
  function zk(a,b){if(Bk(b))return Wi(a.g.Y,b.stream.originalId||""),null;b.type==Jb&&Xi(a.g.Y);if(!a.g.Y.$&&b.type!=Jb)return a.i.updateIntervalSeconds/2;var c=a.g.be(),d=b.Ra?b.Ra.endTime:c,e=Pi(a.g.Y,b.type,c),f=Math.max(a.m.minBufferTime||0,a.i.rebufferingGoal,a.i.bufferingGoal)*a.C,g=a.m.presentationTimeline.getDuration()-d,h=Oi(a.g.Y,b.type);if(1E-6>g&&h)return b.endOfStream=!0,"video"==b.type&&(a=a.h.get(Jb))&&Bk(a)&&(a.endOfStream=!0),null;b.endOfStream=!1;if(e>=f)return a.i.updateIntervalSeconds/
399
399
  2;e=Ck(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,Bk(h)||h.ba&&!h.ba.current()||(f=Math.min(f,h.Ra?h.Ra.endTime:c));if(d>=f+a.m.presentationTimeline.g)return a.i.updateIntervalSeconds;b.Ga&&b.ba&&(d=e.g,!d||b.Ra&&Eh(d,b.Mc)||bk(b.Ga,d),Yj(b.Ga,e));Dk(a,b,c,e).catch(function(){});return null}
400
- function Ck(a,b,c,d){if(b.ba)return b.ba.current();if(b.Ra||d)return c=b.Ra?b.Ra.endTime:d,b.Of=!0,b.ba=b.stream.segmentIndex.kc(c),b.ba&&b.ba.next().value;a=a.i.inaccurateManifestTolerance;d=Math.max(c-a,0);var e=null;a&&(b.ba=b.stream.segmentIndex.kc(d),e=b.ba&&b.ba.next().value);e||(b.ba=b.stream.segmentIndex.kc(c),e=b.ba&&b.ba.next().value);return e}
400
+ function Ck(a,b,c,d){if(b.ba)return b.ba.current();if(b.Ra||d)return c=b.Ra?b.Ra.endTime:d,b.Of=!0,b.ba=b.stream.segmentIndex.lc(c),b.ba&&b.ba.next().value;a=a.i.inaccurateManifestTolerance;d=Math.max(c-a,0);var e=null;a&&(b.ba=b.stream.segmentIndex.lc(d),e=b.ba&&b.ba.next().value);e||(b.ba=b.stream.segmentIndex.lc(c),e=b.ba&&b.ba.next().value);return e}
401
401
  function Dk(a,b,c,d){var e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A;return K(function(B){switch(B.g){case 1:e=Kb;f=b.stream;g=b.ba;b.Sa=!0;ta(B,2);if(2==d.mc())throw new P(1,1,1011);return D(B,Ek(a,b,d),4);case 4:zf(a.l);if(a.u)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),r=q=!1,v=function(C){var E,H,G,I;return K(function(J){switch(J.g){case 1:if(q)return J.return();r=!0;zf(a.l);if(a.u)return J.return();
402
- ta(J,2);n=Fk(n,C);E=!1;H=0;(new Tf).box("mdat",function(L){H=L.size+L.start;E=!0}).parse(n,!1,!0);if(!E){J.F(4);break}G=n.subarray(0,H);n=n.subarray(H);return D(J,Gk(a,b,c,f,d,G,!0),5);case 5:b.Ga&&b.ba&&Yj(b.Ga,d,!0);case 4:va(J,0);break;case 2:u=I=wa(J),F(J)}})},D(B,Hk(a,b,d,v),9);l=Hk(a,b,d);return D(B,l,7);case 7:m=B.h;zf(a.l);if(a.u)return B.return();zf(a.l);return b.Qb?(b.Sa=!1,ok(a,b,0),B.return()):D(B,Gk(a,b,c,f,d,m),6);case 9:y=B.h;if(u)throw u;if(r){B.F(10);break}q=!0;zf(a.l);return a.u?
403
- B.return():b.Qb?(b.Sa=!1,ok(a,b,0),B.return()):D(B,Gk(a,b,c,f,d,y),10);case 10:b.Ga&&b.ba&&Yj(b.Ga,d,!0);case 6:zf(a.l);if(a.u)return B.return();b.Ra=d;g.next();b.Sa=!1;b.Xf=!1;z=a.g.Y.Jb();x=z[b.type];Ya(JSON.stringify(x));b.Qb||a.g.Sf(d.startTime,d.endTime,b.type);ok(a,b,0);va(B,0);break;case 2:A=wa(B);zf(a.l,A);if(a.u)return B.return();b.Sa=!1;if(7001==A.code)b.Sa=!1,ik(b),ok(a,b,0),B.F(0);else if(b.type==e.za&&a.i.ignoreTextStreamFailures)a.h.delete(e.za),B.F(0);else if(3017==A.code)Ik(a,b,A),
402
+ ta(J,2);n=Fk(n,C);E=!1;H=0;(new Tf).box("mdat",function(L){H=L.size+L.start;E=!0}).parse(n,!1,!0);if(!E){J.F(4);break}G=n.subarray(0,H);n=n.subarray(H);return D(J,Gk(a,b,c,f,d,G,!0),5);case 5:b.Ga&&b.ba&&Yj(b.Ga,d,!0);case 4:va(J,0);break;case 2:u=I=wa(J),F(J)}})},D(B,Hk(a,b,d,v),9);l=Hk(a,b,d);return D(B,l,7);case 7:m=B.h;zf(a.l);if(a.u)return B.return();zf(a.l);return b.Sb?(b.Sa=!1,ok(a,b,0),B.return()):D(B,Gk(a,b,c,f,d,m),6);case 9:y=B.h;if(u)throw u;if(r){B.F(10);break}q=!0;zf(a.l);return a.u?
403
+ B.return():b.Sb?(b.Sa=!1,ok(a,b,0),B.return()):D(B,Gk(a,b,c,f,d,y),10);case 10:b.Ga&&b.ba&&Yj(b.Ga,d,!0);case 6:zf(a.l);if(a.u)return B.return();b.Ra=d;g.next();b.Sa=!1;b.Xf=!1;z=a.g.Y.Jb();x=z[b.type];Ya(JSON.stringify(x));b.Sb||a.g.Sf(d.startTime,d.endTime,b.type);ok(a,b,0);va(B,0);break;case 2:A=wa(B);zf(a.l,A);if(a.u)return B.return();b.Sa=!1;if(7001==A.code)b.Sa=!1,ik(b),ok(a,b,0),B.F(0);else if(b.type==e.za&&a.i.ignoreTextStreamFailures)a.h.delete(e.za),B.F(0);else if(3017==A.code)Ik(a,b,A),
404
404
  B.F(0);else return b.td=!0,A.severity=2,D(B,Ak(a,b,A),0)}})}function Jk(a,b,c){var d,e,f,g;return K(function(h){if(1==h.g)return d=b,d.cryptoKey?h.F(2):D(h,d.fetchKey(),3);e=d.iv;if(!e)for(e=lc(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 Fk(a,b){var c=new Uint8Array(a.length+b.length);c.set(a);c.set(b,a.length);return c}
405
405
  function Ik(a,b,c){if(!Array.from(a.h.values()).some(function(e){return e!=b&&e.Xf})){var d=Math.round(100*a.C);if(20<d)a.C-=.2;else if(4<d)a.C-=.04;else{b.td=!0;a.u=!0;a.g.onError(c);return}b.Xf=!0}ok(a,b,4)}
406
406
  function Ek(a,b,c){var d,e,f,g,h,k,l,m,n,q,r,u,v;return K(function(y){if(1==y.g){d=Kb;e=[];f=Math.max(0,c.appendWindowStart-.1);g=c.appendWindowEnd+.01;h=gd(b.stream.codecs)[0];k=hd(b.stream.mimeType);l=c.timestampOffset;if(l==b.Kf&&f==b.If&&g==b.Hf&&h==b.Jf&&k==b.Sg)return y.F(2);if(m=b.Jf&&b.Sg&&ij(a.g.Y,b.type,b.stream))n=null,b.type===d.ua?n=a.h.get(d.W):b.type===d.W&&(n=a.h.get(d.ua)),n&&(n.Mc=null,wk(a,n),jk(n).catch(function(){}));q=function(){var z,x,A,B;return K(function(C){if(1==C.g)return z=
407
- new Map,a.j.audio&&z.set(d.W,a.j.audio),a.j.video&&z.set(d.ua,a.j.video),ta(C,2),b.If=f,b.Hf=g,b.Jf=h,b.Sg=k,b.Kf=l,x=a.m.sequenceMode||"HLS"==a.m.type,D(C,$i(a.g.Y,b.type,l,f,g,x,b.stream,z),4);if(2!=C.g)return m&&(A=null,b.type===d.ua?A=a.h.get(d.W):b.type===d.W&&(A=a.h.get(d.ua)),A&&(A.Qb=!1,A.Sa=!1,wk(a,A))),va(C,0);B=wa(C);b.If=null;b.Hf=null;b.Jf=null;b.Kf=null;throw B;})};return D(y,q(),2)}Eh(c.g,b.Mc)||(b.Mc=c.g,c.l&&c.g&&(r=Hk(a,b,c.g),u=function(){var z,x,A,B,C,E;return K(function(H){switch(H.g){case 1:return ta(H,
408
- 2),D(H,r,4);case 4:return z=H.h,zf(a.l),x=null,A=new Map,B=new Tf,B.box("moov",Yf).box("trak",Yf).box("mdia",Yf).S("mdhd",function(G){x=Xh(G.reader,G.version).timescale}).box("hdlr",function(G){G=G.reader;G.skip(8);G=G.Ob(4);var I=String.fromCharCode(G[0]);I+=String.fromCharCode(G[1]);I+=String.fromCharCode(G[2]);I+=String.fromCharCode(G[3]);switch(I){case "soun":A.set(d.W,x);break;case "vide":A.set(d.ua,x)}x=null}).parse(z),A.has(b.type)?c.g.timescale=A.get(b.type):null!=x&&(c.g.timescale=x),C=b.stream.closedCaptions&&
407
+ new Map,a.j.audio&&z.set(d.W,a.j.audio),a.j.video&&z.set(d.ua,a.j.video),ta(C,2),b.If=f,b.Hf=g,b.Jf=h,b.Sg=k,b.Kf=l,x=a.m.sequenceMode||"HLS"==a.m.type,D(C,$i(a.g.Y,b.type,l,f,g,x,b.stream,z),4);if(2!=C.g)return m&&(A=null,b.type===d.ua?A=a.h.get(d.W):b.type===d.W&&(A=a.h.get(d.ua)),A&&(A.Sb=!1,A.Sa=!1,wk(a,A))),va(C,0);B=wa(C);b.If=null;b.Hf=null;b.Jf=null;b.Kf=null;throw B;})};return D(y,q(),2)}Eh(c.g,b.Mc)||(b.Mc=c.g,c.l&&c.g&&(r=Hk(a,b,c.g),u=function(){var z,x,A,B,C,E;return K(function(H){switch(H.g){case 1:return ta(H,
408
+ 2),D(H,r,4);case 4:return z=H.h,zf(a.l),x=null,A=new Map,B=new Tf,B.box("moov",Yf).box("trak",Yf).box("mdia",Yf).S("mdhd",function(G){x=Wh(G.reader,G.version).timescale}).box("hdlr",function(G){G=G.reader;G.skip(8);G=G.Qb(4);var I=String.fromCharCode(G[0]);I+=String.fromCharCode(G[1]);I+=String.fromCharCode(G[2]);I+=String.fromCharCode(G[3]);switch(I){case "soun":A.set(d.W,x);break;case "vide":A.set(d.ua,x)}x=null}).parse(z),A.has(b.type)?c.g.timescale=A.get(b.type):null!=x&&(c.g.timescale=x),C=b.stream.closedCaptions&&
409
409
  0<b.stream.closedCaptions.size,D(H,a.g.zg(b.type,z),5);case 5:return D(H,Ri(a.g.Y,b.type,z,null,b.stream,C),6);case 6:va(H,0);break;case 2:throw E=wa(H),b.Mc=null,E;}})},a.g.Ki(c.startTime,c.g),e.push(u())));a.m.sequenceMode&&(v=b.Ra?b.Ra.j:null,c.j!=v||b.Of)&&(b.Of=!1,e.push(bj(a.g.Y,b.type,c.startTime)));return D(y,Promise.all(e),0)})}
410
410
  function Gk(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h,k,l,m,n,q;return K(function(r){switch(r.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.G;if(l||m)k=new Tf;l&&k.S("emsg",function(u){var v=d.emsgSchemeIdUris;if(0===u.version){var y=u.reader.Cd();var z=u.reader.Cd();var x=u.reader.N();var A=u.reader.N();var B=u.reader.N();var C=u.reader.N();var E=e.startTime+A/x}else x=u.reader.N(),E=u.reader.Qc()/
411
- x+e.timestampOffset,A=E-e.startTime,B=u.reader.N(),C=u.reader.N(),y=u.reader.Cd(),z=u.reader.Cd();u=u.reader.Ob(u.reader.getLength()-u.reader.Ea());if(v&&v.includes(y)||a.i.dispatchAllEmsgBoxes)"urn:mpeg:dash:event:2012"==y?a.g.Li():(v=(new Map).set("detail",{startTime:E,endTime:E+B/x,schemeIdUri:y,value:z,timescale:x,presentationTimeDelta:A,eventDuration:B,id:C,messageData:u}),v=new O("emsg",v),v.cancelable=!0,a.g.onEvent(v),v.defaultPrevented||"https://aomedia.org/emsg/ID3"!=y&&"https://developer.apple.com/streaming/emsg-id3"!=
411
+ x+e.timestampOffset,A=E-e.startTime,B=u.reader.N(),C=u.reader.N(),y=u.reader.Cd(),z=u.reader.Cd();u=u.reader.Qb(u.reader.getLength()-u.reader.Ea());if(v&&v.includes(y)||a.i.dispatchAllEmsgBoxes)"urn:mpeg:dash:event:2012"==y?a.g.Li():(v=(new Map).set("detail",{startTime:E,endTime:E+B/x,schemeIdUri:y,value:z,timescale:x,presentationTimeDelta:A,eventDuration:B,id:C,messageData:u}),v=new O("emsg",v),v.cancelable=!0,a.g.onEvent(v),v.defaultPrevented||"https://aomedia.org/emsg/ID3"!=y&&"https://developer.apple.com/streaming/emsg-id3"!=
412
412
  y||(y=Sh(u),y.length&&e&&a.g.Mi([{cueTime:e.startTime,data:u,frames:y,dts:e.startTime,pts:e.startTime}],0,e.endTime)))});m&&k.S("prft",function(u){if(!a.G&&e.g.timescale){var v=u.reader,y=u.version;v.N();u=v.N();var z=v.N();u=1E3*u+z/Math.pow(2,32)*1E3;0===y?v=v.N():(y=v.N(),v=v.N(),v=y*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 O("prft",v);a.g.onEvent(v);
413
- a.G=!0}});(l||m)&&k.parse(f);return D(r,Kk(a,b,c),2);case 2:return zf(a.l),n=b.Fd,b.Fd=!1,q=b.xg,b.xg=!1,D(r,a.g.zg(b.type,f),3);case 3:return D(r,Ri(a.g.Y,b.type,f,e,d,h,n,q,g),4);case 4:zf(a.l),F(r)}})}function Kk(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=Mi(a.g.Y,b.type);if(null==e)return h.return();f=c-e;g=f-d;return.01>=g?h.return():D(h,a.g.Y.remove(b.type,e,e+g),2)}zf(a.l);F(h)})}
413
+ a.G=!0}});(l||m)&&k.parse(f);return D(r,Kk(a,b,c),2);case 2:return zf(a.l),n=b.Fd,b.Fd=!1,q=b.xg,b.xg=!1,D(r,a.g.zg(b.type,f),3);case 3:return D(r,Ri(a.g.Y,b.type,f,e,d,h,n,q,g),4);case 4:zf(a.l),F(r)}})}function Kk(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=Mi(a.g.Y,b.type);if(null==e)return h.return();f=c-e;g=f-d;return 1>=g?h.return():D(h,a.g.Y.remove(b.type,e,e+g),2)}zf(a.l);F(h)})}
414
414
  function Bk(a){return a&&a.type==Jb&&("application/cea-608"==a.stream.mimeType||"application/cea-708"==a.stream.mimeType)}
415
415
  function Hk(a,b,c,d){var e,f,g,h,k;return K(function(l){switch(l.g){case 1:if(c instanceof Dh&&(e=c.g))return l.return(e);f=null;if(b.Ga){var m=b.Ga;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=xk(a,c,b.stream,d));g=0;b.ba&&(g=b.ba.g);b.cb=f;return D(l,f.promise,2);case 2:h=l.h;b.cb=null;k=h.data;if(!c.aes128Key){l.F(3);break}return D(l,Jk(k,c.aes128Key,g),4);case 4:k=l.h;case 3:return l.return(k)}})}
416
416
  function xk(a,b,c,d){var e=b instanceof Fh?b:void 0,f=e?1:0;b=fk(b.aa(),b.gb,b.Ma,a.i.retryParameters,d);return a.g.tc.request(wf,b,{type:f,stream:c,segment:e})}
417
- function uk(a,b,c,d){var e,f;return K(function(g){if(1==g.g)return b.Qb=!1,b.Ke=!1,b.Xd=0,b.ld=!0,b.Ra=null,b.Mc=null,b.ba=null,b.Ga&&ck(b.Ga),d?(e=a.g.be(),f=a.g.Y.getDuration(),D(g,a.g.Y.remove(b.type,e+d,f),3)):D(g,Zi(a.g.Y,b.type),4);if(3!=g.g)return zf(a.l),c?D(g,a.g.Y.flush(b.type),3):g.F(3);zf(a.l);b.ld=!1;b.endOfStream=!1;b.Sa||b.Cb||ok(a,b,0);F(g)})}
417
+ function uk(a,b,c,d){var e,f;return K(function(g){if(1==g.g)return b.Sb=!1,b.Ke=!1,b.Xd=0,b.ld=!0,b.Ra=null,b.Mc=null,b.ba=null,b.Ga&&ck(b.Ga),d?(e=a.g.be(),f=a.g.Y.getDuration(),D(g,a.g.Y.remove(b.type,e+d,f),3)):D(g,Zi(a.g.Y,b.type),4);if(3!=g.g)return zf(a.l),c?D(g,a.g.Y.flush(b.type),3):g.F(3);zf(a.l);b.ld=!1;b.endOfStream=!1;b.Sa||b.Cb||ok(a,b,0);F(g)})}
418
418
  function ok(a,b,c){var d=b.type;if(d!=Jb||a.h.has(d))b.Cb=(new ud(function(){var e;return K(function(f){if(1==f.g)return ta(f,2),D(f,yk(a,b),4);if(2!=f.g)return va(f,0);e=wa(f);if(a.g)a.g.onError(e);F(f)})})).T(c)}function ik(a){null!=a.Cb&&(a.Cb.stop(),a.Cb=null)}function jk(a){return K(function(b){return a.cb?D(b,a.cb.abort(),0):b.F(0)})}
419
419
  function Ak(a,b,c){var d;return K(function(e){if(1==e.g)return D(e,Ze(a.I),2);zf(a.l);d=0===a.i.maxDisabledTime&&1011==c.code?1:a.i.maxDisabledTime;1===c.category&&0<d&&(c.handled=a.g.ef(b.stream,d),c.handled&&(c.severity=1));a.g.onError(c);c.handled||a.i.failureCallback(c);F(e)})};function Lk(a,b,c){var d,e,f,g,h,k,l;return K(function(m){switch(m.g){case 1:var n=(new gb(a)).Wa.split("/").pop().split(".");d=1==n.length?"":n.pop().toLowerCase();if(e=Mk[d])return m.return(e);f=0;g=qf([a],c);ta(m,2);g.method="HEAD";return D(m,b.request(f,g).promise,4);case 4:h=m.h;e=h.headers["content-type"];va(m,3);break;case 2:k=wa(m);if(!k||1002!=k.code&&1001!=k.code){m.F(3);break}g.method="GET";return D(m,b.request(f,g).promise,6);case 6:l=m.h,e=l.headers["content-type"];case 3:return m.return(e?
420
420
  e.toLowerCase().split(";").shift():"")}})}
@@ -451,7 +451,7 @@ Xk.prototype.isTextVisible=Xk.prototype.isTextVisible;Xk.prototype.remove=Xk.pro
451
451
  break;case "right":g.push("align:right");break;case Bc: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}M("shaka.text.WebVttGenerator",function(){});function gl(a,b){this.h=a;this.g=b;this.i="";this.s=void 0;this.j=!1;this.m=!0;this.l=!1}gl.prototype.configure=function(a){this.g=a;this.g.sessionId&&this.g.sessionId!=this.i&&(this.i="")};
452
452
  function hl(a,b,c){try{if(!a.g.enabled)return b;var d=il(a);a:{switch(c.toLowerCase()){case "audio/mp4":case "audio/webm":case "audio/ogg":case "audio/mpeg":case "audio/aac":case "audio/flac":case "audio/wav":var e=jl;break a;case "video/webm":case "video/mp4":case "video/mpeg":case "video/mp2t":e=kl;break a;case "application/x-mpegurl":case "application/vnd.apple.mpegurl":case "application/dash+xml":case "video/vnd.mpeg.dash.mpd":case "application/vnd.ms-sstr+xml":e=ll;break a}e=void 0}d.ot=e;d.su=
453
453
  !0;var f=ml(d);return nl(b,f)}catch(g){return Ta("CMCD_SRC_ERROR","Could not generate src CMCD data.",g),b}}function il(a){a.i||(a.i=a.g.sessionId||window.crypto.randomUUID());return{v:1,sf:a.s,sid:a.i,cid:a.g.contentId,mtp:a.h.getBandwidthEstimate()/1E3}}
454
- function ol(a,b,c){c=void 0===c?{}:c;var d=void 0===d?a.g.useHeaders:d;if(a.g.enabled){Object.assign(c,il(a));c.pr=a.h.Kb();var e=c.ot===pl||c.ot===kl;a.l&&e&&(c.bs=!0,c.su=!0,a.l=!1);null==c.su&&(c.su=a.m);if(d)a=ql(c),Object.keys(a).length&&Object.assign(b.headers,a);else{var f=ml(c);f&&(b.uris=b.uris.map(function(g){return nl(g,f)}))}}}
454
+ function ol(a,b,c){c=void 0===c?{}:c;var d=void 0===d?a.g.useHeaders:d;if(a.g.enabled){Object.assign(c,il(a));c.pr=a.h.Lb();var e=c.ot===pl||c.ot===kl;a.l&&e&&(c.bs=!0,c.su=!0,a.l=!1);null==c.su&&(c.su=a.m);if(d)a=ql(c),Object.keys(a).length&&Object.assign(b.headers,a);else{var f=ml(c);f&&(b.uris=b.uris.map(function(g){return nl(g,f)}))}}}
455
455
  function rl(a){if(0===a.type)return sl;if(a=a.stream){var b=a.type;if("video"==b)return a.codecs&&a.codecs.includes(",")?kl:pl;if("audio"==b)return jl;if("text"==b)return"application/mp4"===a.mimeType?tl:ul}}function vl(a,b){b=a.h.Jb()[b];if(!b.length)return NaN;var c=a.h.getCurrentTime();return(a=b.find(function(d){return d.start<=c&&d.end>=c}))?1E3*(a.end-c):NaN}
456
456
  function wl(a,b){var c=a.h.kb();if(!c.length)return NaN;a=c[0];c=t(c);for(var d=c.next();!d.done;d=c.next())d=d.value,"variant"===d.type&&d.bandwidth>a.bandwidth&&(a=d);switch(b){case pl:return a.videoBandwidth||NaN;case jl:return a.audioBandwidth||NaN;default:return a.bandwidth}}
457
457
  function ml(a){function b(n){return 100*c(n/100)}function c(n){return Math.round(n)}function d(n){return!Number.isNaN(n)&&null!=n&&""!==n&&!1!==n}var e=[],f={br:c,d:c,bl:b,dl:b,mtp:b,nor:function(n){return encodeURIComponent(n)},rtp:b,tb:c},g=Object.keys(a||{}).sort();g=t(g);for(var h=g.next();!h.done;h=g.next()){h=h.value;var k=a[h];if(d(k)&&("v"!==h||1!==k)&&("pr"!=h||1!==k)){var l=f[h];l&&(k=l(k));l=typeof k;var m=void 0;m="string"===l&&"ot"!==h&&"sf"!==h&&"st"!==h?h+"="+JSON.stringify(k):"boolean"===
@@ -475,9 +475,9 @@ forceTransmux:!1,insertFakeEncryptionInInit:!0},offline:e,abrFactory:function(){
475
475
  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(Kl(h,g.preferredAudioLanguage,g.preferredVideoHdrLevel))})};return g}
476
476
  function Ll(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 yl(a,b,c||Jl(),d,"")}
477
477
  function Kl(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=Vb(b,e.map(function(h){return h.language}));f&&(c=e.filter(function(h){return Nb(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-
478
- 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!=Jb&&"image"!=c.type||b.push(c);return b}M("shaka.util.PlayerConfiguration",Il);Il.mergeConfigObjects=Ll;Il.createDefault=Jl;function Ml(){this.g=null;this.h=[]}function Nl(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 Ol(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 Pl(){this.i=this.h=null;this.g=[]}function Ql(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 Rl(){this.C=this.D=this.I=this.G=this.u=this.j=this.H=this.m=this.i=this.M=this.P=this.J=this.K=this.L=this.l=this.s=NaN;this.g=new Ml;this.h=new Pl};function V(a,b){ab.call(this);var c=this;this.l=Sl;this.fe=this.g=null;this.Z=!1;this.pe=new Af;this.Xa=new Af;this.s=new Af;this.sa=new Af;this.G=this.I=this.m=this.J=null;this.ye=0;this.V=new Bl;this.ea=this.$=this.i=this.Be=this.H=this.j=this.ha=this.L=this.oh=this.U=this.ra=this.M=this.K=this.Va=null;this.od=!1;this.Wf=this.u=null;this.rg=1E9;this.Ub=[];this.P=NaN;this.h=Tl(this);this.ve={width:Infinity,height:Infinity};this.C=null;this.Ka=new Je(this.h.preferredAudioLanguage,this.h.preferredVariantRole,
478
+ 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!=Jb&&"image"!=c.type||b.push(c);return b}M("shaka.util.PlayerConfiguration",Il);Il.mergeConfigObjects=Ll;Il.createDefault=Jl;function Ml(){this.g=null;this.h=[]}function Nl(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 Ol(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 Pl(){this.i=this.h=null;this.g=[]}function Ql(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 Rl(){this.C=this.D=this.I=this.G=this.u=this.j=this.H=this.m=this.i=this.M=this.P=this.J=this.K=this.L=this.l=this.s=NaN;this.g=new Ml;this.h=new Pl};function V(a,b){ab.call(this);var c=this;this.l=Sl;this.fe=this.g=null;this.Z=!1;this.pe=new Af;this.Xa=new Af;this.s=new Af;this.sa=new Af;this.G=this.I=this.m=this.J=null;this.ye=0;this.V=new Bl;this.ea=this.$=this.i=this.Be=this.H=this.j=this.ha=this.L=this.oh=this.U=this.ra=this.M=this.K=this.Va=null;this.od=!1;this.Wf=this.u=null;this.rg=1E9;this.Wb=[];this.P=NaN;this.h=Tl(this);this.ve={width:Infinity,height:Infinity};this.C=null;this.Ka=new Je(this.h.preferredAudioLanguage,this.h.preferredVariantRole,
479
479
  this.h.preferredAudioChannelCount,this.h.preferredVideoHdrLevel,this.h.preferredVideoLayout,this.h.preferredAudioLabel,this.h.mediaSource.codecSwitchingStrategy,this.h.manifest.dash.enableAudioGroups);this.Qa=this.h.preferredTextLanguage;this.Gb=this.h.preferredTextRole;this.Db=this.h.preferForcedSubs;this.Fb=[];b&&b(this);this.U=Ul(this);this.J=Vl(this);this.J.gg(this.h.streaming.forceHTTPS);this.D=null;Wl&&(this.D=Wl(),this.D.configure(this.h.ads));this.pe.o(window,"online",function(){Xl(c);c.Yf()});
480
- this.ie=new vd(function(){return Yl(c)});a&&(Ae("Player","Please migrate from initializing Player with a mediaElement; use the attach method instead."),this.Ac(a,!0))}pa(V,ab);function Zl(a){null!=a.L&&(ui(a.L),a.L.release(),a.L=null)}
480
+ this.ie=new vd(function(){return Yl(c)});a&&(Ae("Player w/ mediaElement","Please migrate from initializing Player with a mediaElement; use the attach method instead."),this.Ac(a,!0))}pa(V,ab);function Zl(a){null!=a.L&&(ui(a.L),a.L.release(),a.L=null)}
481
481
  function $l(a,b){if(b.lcevc.enabled){var c=a.kb();c&&c[0]&&"video/mp2t"==c[0].videoMimeType&&(zd()||navigator.userAgent.match(/Edge\//))&&(b.mediaSource.forceTransmux||Sa("LCEVC Warning: For MPEG-2 TS decoding the config.mediaSource.forceTransmux must be enabled."));Zl(a);null==a.L&&(a.L=new ti(a.g,a.oh,b.lcevc),a.I&&(a.I.P=a.L))}else Zl(a)}function am(a,b){return new O(a,b)}p=V.prototype;
482
482
  p.destroy=function(){var a=this,b;return K(function(c){switch(c.g){case 1:if(a.l==bm)return c.return();Zl(a);b=a.detach();a.l=bm;return D(c,b,2);case 2:a.pe&&(a.pe.release(),a.pe=null);a.Xa&&(a.Xa.release(),a.Xa=null);a.s&&(a.s.release(),a.s=null);a.sa&&(a.sa.release(),a.sa=null);a.Wf=null;a.h=null;a.C=null;a.fe=null;a.U=null;if(!a.J){c.F(3);break}return D(c,a.J.destroy(),4);case 4:a.J=null;case 3:a.u&&(a.u.release(),a.u=null),ab.prototype.release.call(a),F(c)}})};
483
483
  function cm(){window.Promise||Sa("A Promise implementation or polyfill is required");if(!(window.Promise&&window.Uint8Array&&Array.prototype.forEach)||Bd("Trident/"))return!1;var a=Jd();return a&&9>a||!(window.MediaKeys&&window.navigator&&window.navigator.requestMediaKeySystemAccess&&window.MediaKeySystemAccess&&window.MediaKeySystemAccess.prototype.getConfiguration)?!1:wd()?!0:xd("application/x-mpegurl")}function dm(a,b){a.dispatchEvent(am("onstatechange",(new Map).set("state",b)))}
@@ -485,7 +485,7 @@ p.Ac=function(a,b){b=void 0===b?!0:b;var c=this,d,e;return K(function(f){switch(
485
485
  p.yg=function(a){this.oh=a};p.detach=function(a){a=void 0===a?!1:a;var b=this;return K(function(c){if(1==c.g){if(b.l==bm)throw new P(2,7,7E3);return D(c,b.Sc(!1,a),2)}if(3!=c.g)return D(c,em(b,"detach"),3);if(c.h)return c.return();try{b.g&&(b.Xa.sb(),b.g=null),dm(b,"detach"),b.D&&!a&&b.D.release()}finally{b.V.release()}F(c)})};function em(a,b){var c;return K(function(d){return 1==d.g?(c=++a.ye,D(d,Cl(a.V,b),2)):c!=a.ye?(a.V.release(),d.return(!0)):d.return(!1)})}
486
486
  p.Sc=function(a,b){a=void 0===a?!0:a;b=void 0===b?!1:b;var c=this,d,e,f,g,h,k,l,m,n;return K(function(q){switch(q.g){case 1:return c.l!=bm&&(c.l=Sl),D(q,em(c,"unload"),2);case 2:if(q.h)return q.return();ua(q,3);c.od=!1;dm(c,"unload");a&&!wd()&&(a=!1);Zl(c);d=c.Fb.map(function(r){return r()});c.Fb=[];return D(q,Promise.all(d),5);case 5:c.dispatchEvent(am("unloading"));c.ra&&(c.ra.release(),c.ra=null);c.g&&(c.s.sb(),c.sa.sb());c.ie.stop();c.Va&&(c.Va.release(),c.Va=null);if(!c.H){q.F(6);break}return D(q,
487
487
  c.H.stop(),7);case 7:c.H=null,c.Be=null;case 6:if(!c.u){q.F(8);break}return D(q,c.u.stop(),8);case 8:if(!c.j){q.F(10);break}return D(q,c.j.destroy(),11);case 11:c.j=null;case 10:c.K&&(c.K.release(),c.K=null);c.G&&(c.G.release(),c.G=null);if(!c.I){q.F(12);break}return D(q,c.I.destroy(),13);case 13:c.I=null;case 12:if(c.D&&!b)c.D.onAssetUnload();c.g&&Wk(c.g);if(!c.g||!c.g.src){q.F(14);break}return D(q,new Promise(function(r){return(new vd(r)).T(.1)}),15);case 15:c.g.removeAttribute("src"),c.g.load();
488
- case 14:if(!c.m){q.F(16);break}return D(q,c.m.destroy(),17);case 17:c.m=null;case 16:c.$=null;c.M=null;if(c.i){e=t(c.i.variants);for(f=e.next();!f.done;f=e.next())for(g=f.value,h=t([g.audio,g.video]),k=h.next();!k.done;k=h.next())(l=k.value)&&l.segmentIndex&&l.segmentIndex.release();m=t(c.i.textStreams);for(k=m.next();!k.done;k=m.next())n=k.value,n.segmentIndex&&n.segmentIndex.release()}c.i=null;c.C=new Rl;c.Zf=null;c.Ub=[];c.P=NaN;lm(c);case 3:xa(q);c.V.release();ya(q,4);break;case 4:if(a&&wd()&&
488
+ case 14:if(!c.m){q.F(16);break}return D(q,c.m.destroy(),17);case 17:c.m=null;case 16:c.$=null;c.M=null;if(c.i){e=t(c.i.variants);for(f=e.next();!f.done;f=e.next())for(g=f.value,h=t([g.audio,g.video]),k=h.next();!k.done;k=h.next())(l=k.value)&&l.segmentIndex&&l.segmentIndex.release();m=t(c.i.textStreams);for(k=m.next();!k.done;k=m.next())n=k.value,n.segmentIndex&&n.segmentIndex.release()}c.i=null;c.C=new Rl;c.Zf=null;c.Wb=[];c.P=NaN;lm(c);case 3:xa(q);c.V.release();ya(q,4);break;case 4:if(a&&wd()&&
489
489
  !c.I)return D(q,km(c),0);q.F(0)}})};p.lj=function(a){this.ea=a};
490
490
  p.load=function(a,b,c){b=void 0===b?null:b;var d=this,e,f,g,h,k,l;return K(function(m){switch(m.g){case 1:if(d.l==bm)throw new P(2,7,7E3);return D(m,Cl(d.V,"load"),2);case 2:d.V.release();if(!d.g)throw new P(2,7,7002);if(!d.$){m.F(3);break}return D(m,d.Sc(!1),3);case 3:e=++d.ye;f=function(){if(d.ye!=e)throw new P(2,7,7E3);};g=function(n,q){return K(function(r){switch(r.g){case 1:return ua(r,2),D(r,Cl(d.V,q),4);case 4:return f(),D(r,n(),5);case 5:f();case 2:xa(r),d.V.release(),ya(r,0)}})};ta(m,5);
491
491
  d.ea=b;d.od=!1;d.dispatchEvent(am("loading"));h=Date.now()/1E3;d.C=new Rl;d.$=a;if(c){m.F(7);break}return D(m,g(function(){return K(function(n){if(1==n.g)return D(n,mm(d),2);c=n.h;F(n)})},"guessMimeType_"),7);case 7:if(k=nm(d,c))return D(m,g(function(){return K(function(n){return D(n,om(d,c),0)})},"initializeSrcEqualsDrmInner_"),16);if(d.I){m.F(11);break}return D(m,g(function(){return K(function(n){return D(n,km(d),0)})},"initializeMediaSourceEngineInner_"),11);case 11:return D(m,g(function(){return K(function(n){return D(n,
@@ -499,11 +499,11 @@ a.ra;a:{var r=t(q.g);for(var u=r.next();!u.done;u=r.next())if(u=u.value,u.scheme
499
499
  zm(a.i);k=Date.now()/1E3;l=k-f;a.C.H=l;F(m)})}
500
500
  function qm(a){var b,c,d,e;return K(function(f){return 1==f.g?(dm(a,"drm-engine"),b=Date.now()/1E3,c=!0,a.m=Am(a,{tc:a.J,onError:function(g){jm(a,g)},ze:function(g){Bm(a,g)},onExpirationUpdated:function(g,h){Cm(a,g,h)},onEvent:function(g){a.dispatchEvent(g);"drmsessionupdate"==g.type&&c&&(c=!1,a.C.j=Date.now()/1E3-b,a.L&&ui(a.L))}}),a.m.configure(a.h.drm),(d=Sd(a.i.variants,a.h.restrictions,a.ve))&&a.j&&Dm(a),e=qe(a.i.variants),D(f,Pg(a.m,e,a.i.offlineSessionIds),2)):3!=f.g?D(f,a.m.Ac(a.g),3):D(f,
501
501
  wm(a,a.i),0)})}
502
- function rm(a,b){var c,d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B;return K(function(C){switch(C.g){case 1:dm(a,"load");c=a.g;a.K=new Kj({ce:function(){return c.playbackRate},Fc:function(){return c.defaultPlaybackRate},jg:function(E){c.playbackRate=E},Wg:function(E){c.currentTime+=E}});d=function(){return Em(a)};e=function(){return Fm(a)};a.s.o(c,"playing",d);a.s.o(c,"pause",d);a.s.o(c,"ended",d);a.s.o(c,"ratechange",e);$l(a,a.h);f=a.h.abrFactory;a.u&&a.Wf==f||(a.Wf=f,a.u=f(),"function"!=typeof a.u.setMediaElement&&(Ae("AbrManager",
502
+ function rm(a,b){var c,d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B;return K(function(C){switch(C.g){case 1:dm(a,"load");c=a.g;a.K=new Kj({ce:function(){return c.playbackRate},Fc:function(){return c.defaultPlaybackRate},jg:function(E){c.playbackRate=E},Wg:function(E){c.currentTime+=E}});d=function(){return Em(a)};e=function(){return Fm(a)};a.s.o(c,"playing",d);a.s.o(c,"pause",d);a.s.o(c,"ended",d);a.s.o(c,"ratechange",e);$l(a,a.h);f=a.h.abrFactory;a.u&&a.Wf==f||(a.Wf=f,a.u=f(),"function"!=typeof a.u.setMediaElement&&(Ae("AbrManager w/o setMediaElement",
503
503
  "Please use an AbrManager with setMediaElement function."),a.u.setMediaElement=function(){}),a.u.configure(a.h.abr));a.Ka=new Je(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.Qa=a.h.preferredTextLanguage;a.Gb=a.h.preferredTextRole;a.Db=a.h.preferForcedSubs;Gm(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd);
504
504
  a.u.init(function(E,H,G){a.j&&E!=a.j.j&&Hm(a,E,!0,void 0===H?!1:H,void 0===G?0:G)});a.u.setMediaElement(c);Od(a.i,a.h.preferredVideoCodecs,a.h.preferredAudioCodecs,a.h.preferredDecodingAttributes);a.j=Im(a);a.j.configure(a.h.streaming);a.l=Jm;c.textTracks&&a.s.o(c.textTracks,"addtrack",function(E){if(E.track)switch(E=E.track,E.kind){case "chapters":Km(a,E)}});a.dispatchEvent(am("streaming"));g=null;(h=a.j.j)||(g=Lm(a,!0));k=[];l=h||g;m=t([l.video,l.audio]);for(n=m.next();!n.done;n=m.next())(q=n.value)&&
505
505
  !q.segmentIndex&&k.push(q.createSegmentIndex());if(!(0<k.length)){C.F(2);break}return D(C,Promise.all(k),2);case 2:if(a.H&&a.H.onInitialVariantChosen)a.H.onInitialVariantChosen(l);Gm(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd);a.G=Mm(a,a.ea);a.Va=Nm(a,b);r=Math.max(a.i.minBufferTime,a.h.streaming.rebufferingGoal);Om(a,c,r);if(h){C.F(4);break}Hm(a,g,!0,!1,0);if(!a.h.streaming.startAtSegmentBoundary){C.F(4);break}u=a.G;v=u.We;return D(C,Pm(g,a.G.Sd()),6);case 6:v.call(u,C.h);case 4:return a.G.Ve(),
506
- y=a.$b().find(function(E){return E.active}),y||((z=re(a.i.textStreams,a.Qa,a.Gb,a.Db)[0]||null)&&Ql(a.C.h,z,!0),g&&(z?(g.audio&&Qm(a,g.audio,z)&&(a.Z=!0),a.Z&&a.I.H.setTextVisibility(!0),Rm(a)):a.Z=!1),z&&(a.h.streaming.alwaysStreamText||a.rc())&&tk(a.j,z)),D(C,a.j.start(),7);case 7:a.h.abr.enabled&&(a.u.enable(),Sm(a));Dm(a);Tm(a);a.i.variants.some(function(E){return E.primary});(x=a.R())&&(a.h.streaming.liveSync||a.i.serviceDescription)?(A=function(){return Um(a)},a.s.o(c,"timeupdate",A)):x||(B=
506
+ y=a.ac().find(function(E){return E.active}),y||((z=re(a.i.textStreams,a.Qa,a.Gb,a.Db)[0]||null)&&Ql(a.C.h,z,!0),g&&(z?(g.audio&&Qm(a,g.audio,z)&&(a.Z=!0),a.Z&&a.I.H.setTextVisibility(!0),Rm(a)):a.Z=!1),z&&(a.h.streaming.alwaysStreamText||a.rc())&&tk(a.j,z)),D(C,a.j.start(),7);case 7:a.h.abr.enabled&&(a.u.enable(),Sm(a));Dm(a);Tm(a);a.i.variants.some(function(E){return E.primary});(x=a.R())&&(a.h.streaming.liveSync||a.i.serviceDescription)?(A=function(){return Um(a)},a.s.o(c,"timeupdate",A)):x||(B=
507
507
  function(){return Vm(a)},a.s.o(c,"timeupdate",B),Vm(a));if(a.D)a.D.onManifestUpdated(x);a.od=!0;a.s.ka(c,"loadedmetadata",function(){a.C.m=Date.now()/1E3-b});F(C)}})}
508
508
  function om(a,b){var c,d,e,f;return K(function(g){return 1==g.g?(c=Kb,d=Date.now()/1E3,e=!0,a.m=Am(a,{tc:a.J,onError:function(h){jm(a,h)},ze:function(h){Bm(a,h)},onExpirationUpdated:function(h,k){Cm(a,h,k)},onEvent:function(h){a.dispatchEvent(h);"drmsessionupdate"==h.type&&e&&(e=!1,a.C.j=Date.now()/1E3-d)}}),a.m.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,
509
509
  mimeType:b?hd(b):"",codecs:b?id(b):"",encrypted:!0,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:c.ua,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.m.Z=!0,D(g,Pg(a.m,[f],[]),2)):D(g,a.m.Ac(a.g),0)})}
@@ -519,31 +519,31 @@ function Vl(a){return new mf(function(b,c,d){a.u&&a.u.segmentDownloaded(b,c,d)},
519
519
  "d";break a;case 3:case 2:f="h";break a;case 5:f="s";break a}f=void 0}e.s=f}ol(e,c,{ot:ll,su:!e.j})}}catch(m){Ta("CMCD_MANIFEST_ERROR","Could not generate manifest CMCD data.",m)}break;case wf:b=d;try{if(e.g.enabled){var g=b.segment;f=0;g&&(f=g.endTime-g.startTime);var h={d:1E3*f,st:e.h.R()?"l":"v"};h.ot=rl(b);var k=h.ot===pl||h.ot===jl||h.ot===kl||h.ot===tl,l=b.stream;l&&(k&&(h.bl=vl(e,l.type)),l.bandwidth&&(h.br=l.bandwidth/1E3));k&&h.ot!==tl&&(h.tb=wl(e,h.ot)/1E3);ol(e,c,h)}}catch(m){Ta("CMCD_SEGMENT_ERROR",
520
520
  "Could not generate segment CMCD data.",m)}break;case 2:case 5:case 6:ol(e,c,{ot:"k"});break;case 4:ol(e,c,{ot:"o"})}},function(b,c,d,e){a.H&&a.H.banLocation&&a.H.banLocation(e)})}function Mm(a,b){return new Aj(a.g,a.i,a.h.streaming,b,function(){a.Va&&Mj(a.Va,!0);a.j&&a.j.Fd();a.M&&cn(a)},function(c){return a.dispatchEvent(c)})}
521
521
  function Nm(a,b){b=new Sj(a.ra,a.R()||0<b);b.addEventListener("enter",function(d){vm(a,"timelineregionenter",d.region)});b.addEventListener("exit",function(d){vm(a,"timelineregionexit",d.region)});b.addEventListener("skip",function(d){var e=d.region;d.seeking||(vm(a,"timelineregionenter",e),vm(a,"timelineregionexit",e))});var c=new Lj(a.g);c.g.add(b);a.ha&&c.g.add(a.ha);return c}
522
- function Om(a,b,c){a.M=new Se;a.M.g=Ue;We(a.M,c,Math.min(.5,c/2));lm(a);a.s.o(b,"waiting",function(){return cn(a)});a.s.o(b,"stalled",function(){return cn(a)});a.s.o(b,"canplaythrough",function(){return cn(a)});a.s.o(b,"progress",function(){return cn(a)})}
523
- function cn(a){switch(a.l){case Xm:if(a.g.ended)var b=!0;else{var c=Ih(a.g.buffered);b=null!=c&&c>=a.g.duration-1}break;case Jm:a:if(a.g.ended||Li(a.I))b=!0;else{if(a.i.presentationTimeline.R()){c=a.i.presentationTimeline.Yb();var d=Ih(a.g.buffered);if(null!=d&&d>=c){b=!0;break a}}b=!1}break;default:b=!1}d=Kh(a.g.buffered,a.g.currentTime);c=a.M;var e=b,f=c.h.get(c.g);b=c.g;d=e||d>=f?Te:Ue;c.g=d;b!=d&&lm(a)}function tm(a,b,c,d){return new Ci(a,b,c,d)}
524
- function Ul(a){return new gl({getBandwidthEstimate:function(){return a.u?a.u.getBandwidthEstimate():NaN},Jb:function(){return a.Jb()},getCurrentTime:function(){return a.g?a.g.currentTime:0},Kb:function(){return a.Kb()},Xb:function(){return a.Xb()},kb:function(){return a.kb()},R:function(){return a.R()}},a.h.cmcd)}
522
+ function Om(a,b,c){a.M=new Se;a.M.g=Ue;Ve(a.M,c,Math.min(.5,c/2));lm(a);a.s.o(b,"waiting",function(){return cn(a)});a.s.o(b,"stalled",function(){return cn(a)});a.s.o(b,"canplaythrough",function(){return cn(a)});a.s.o(b,"progress",function(){return cn(a)})}
523
+ function cn(a){switch(a.l){case Xm:if(a.g.ended)var b=!0;else{var c=Ih(a.g.buffered);b=null!=c&&c>=a.g.duration-1}break;case Jm:a:if(a.g.ended||Li(a.I))b=!0;else{if(a.i.presentationTimeline.R()){c=a.i.presentationTimeline.$b();var d=Ih(a.g.buffered);if(null!=d&&d>=c){b=!0;break a}}b=!1}break;default:b=!1}d=Kh(a.g.buffered,a.g.currentTime);c=a.M;var e=b,f=c.h.get(c.g);b=c.g;d=e||d>=f?Te:Ue;c.g=d;b!=d&&lm(a)}function tm(a,b,c,d){return new Ci(a,b,c,d)}
524
+ function Ul(a){return new gl({getBandwidthEstimate:function(){return a.u?a.u.getBandwidthEstimate():NaN},Jb:function(){return a.Jb()},getCurrentTime:function(){return a.g?a.g.currentTime:0},Lb:function(){return a.Lb()},Yb:function(){return a.Yb()},kb:function(){return a.kb()},R:function(){return a.R()}},a.h.cmcd)}
525
525
  function Im(a){return new gk(a.i,{be:function(){return a.G?a.G.Sd():0},getBandwidthEstimate:function(){return a.u.getBandwidthEstimate()},Y:a.I,tc:a.J,onError:function(b){return jm(a,b)},onEvent:function(b){return a.dispatchEvent(b)},Li:function(){a.H&&a.H.update&&a.H.update()},Sf:function(b,c,d){a.G&&a.G.Xg();cn(a);b=(new Map).set("start",b).set("end",c).set("contentType",d);a.dispatchEvent(am("segmentappended",b))},Ki:function(b,c){(c=c.Nf)&&a.ha&&Pj(a.ha,c,b)},zg:function(b,c){var d=a.m;if(d.h.parseInbandPsshEnabled&&
526
526
  !d.H&&["audio","video"].includes(b)){c=new kg(lc(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;Yg(d,"cenc",e);d=d.l}}else d=Promise.resolve();return d},Mi:function(b,c,d){um(a,b,c,d)},ef:function(b,c){return a.ef(b,c)}})}
527
527
  p.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=zl(a,b));a.streaming&&"forceTransmuxTS"in a.streaming&&(Ae("streaming.forceTransmuxTS configuration","Please Use mediaSource.forceTransmux instead."),a.mediaSource.mediaSource=a.streaming.forceTransmuxTS,delete a.streaming.forceTransmuxTS);a.streaming&&"forceTransmux"in a.streaming&&(Ae("streaming.forceTransmux configuration","Please Use mediaSource.forceTransmux instead."),a.mediaSource.mediaSource=a.streaming.forceTransmux,delete a.streaming.forceTransmux);
528
528
  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=Ll(this.h,a,Tl(this));dn(this);return c};
529
529
  function dn(a){if(a.H){var b=hf(a.h.manifest);a.g&&"AUDIO"===a.g.nodeName&&(b.disableVideo=!0);a.H.configure(b)}a.m&&a.m.configure(a.h.drm);if(a.j){a.j.configure(a.h.streaming);try{en(a,a.i)}catch(f){jm(a,f)}a.u&&Tm(a);b=a.j.j;!b||b.allowedByApplication&&b.allowedByKeySystem||fn(a)}a.J&&a.J.gg(a.h.streaming.forceHTTPS);if(a.I&&(a.I.configure(a.h.mediaSource),a.I.V=a.h.manifest.segmentRelativeVttTiming,b=a.h.textDisplayFactory,a.Zf!=b)){var c=b(),d=a.I,e=d.H;d.H=c;e&&(c.setTextVisibility(e.isTextVisible()),
530
- e.destroy());d.h&&(d.h.j=c);a.Zf=b;a.j&&(b=a.j,(c=b.h.get(Jb))&&rk(b,c.stream,!0,0,!0))}a.u&&(a.u.configure(a.h.abr),a.h.abr.enabled?a.u.enable():a.u.disable(),Sm(a));a.M&&(b=a.h.streaming.rebufferingGoal,a.i&&(b=Math.max(b,a.i.minBufferTime)),We(a.M,b,Math.min(.5,b/2)));a.i&&Gm(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd);a.D&&a.D.configure(a.h.ads);a.U&&a.U.configure(a.h.cmcd)}p.getConfiguration=function(){var a=Tl(this);Ll(a,this.h,Tl(this));return a};
530
+ e.destroy());d.h&&(d.h.j=c);a.Zf=b;a.j&&(b=a.j,(c=b.h.get(Jb))&&rk(b,c.stream,!0,0,!0))}a.u&&(a.u.configure(a.h.abr),a.h.abr.enabled?a.u.enable():a.u.disable(),Sm(a));a.M&&(b=a.h.streaming.rebufferingGoal,a.i&&(b=Math.max(b,a.i.minBufferTime)),Ve(a.M,b,Math.min(.5,b/2)));a.i&&Gm(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd);a.D&&a.D.configure(a.h.ads);a.U&&a.U.configure(a.h.cmcd)}p.getConfiguration=function(){var a=Tl(this);Ll(a,this.h,Tl(this));return a};
531
531
  p.Kh=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.Fa().end);if(a>=b)return 1;if(!(a<=this.g.currentTime)&&a<b)return(a-this.g.currentTime)/(b-this.g.currentTime)}return 0};p.Wi=function(){for(var a in this.h)delete this.h[a];Ll(this.h,Tl(this),Tl(this));dn(this)};p.ae=function(){return this.l};p.Af=function(){return this.i?this.i.type:null};p.bi=function(){return this.g};
532
- p.Xb=function(){return this.J};p.zf=function(){return this.$};p.Yd=function(){return this.D?this.D:null};p.R=function(){return this.i?this.i.presentationTimeline.R():this.g&&this.g.src?Infinity==this.g.duration:!1};p.pc=function(){return this.i?this.i.presentationTimeline.pc():!1};p.Kc=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};
533
- p.Fa=function(){if(this.i){if(!this.od&&"HLS"==this.i.type)return{start:0,end:0};var a=this.i.presentationTimeline;return{start:a.Hc(),end:a.Lb()}}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}};p.pi=function(){this.R()&&(this.g.currentTime=this.Fa().end)};p.keySystem=function(){var a=this.drmInfo();return a?a.keySystem:""};p.drmInfo=function(){return this.m?this.m.g:null};p.qd=function(){return this.m?this.m.qd():Infinity};
534
- p.yf=function(){return this.m?this.m.yf():[]};p.$d=function(){return this.m?this.m.$d():{}};p.vd=function(){return this.M?this.M.g==Ue:!1};p.Kb=function(){return this.g?this.K?this.K.h:1:0};
532
+ p.Yb=function(){return this.J};p.zf=function(){return this.$};p.Yd=function(){return this.D?this.D:null};p.R=function(){return this.i?this.i.presentationTimeline.R():this.g&&this.g.src?Infinity==this.g.duration:!1};p.pc=function(){return this.i?this.i.presentationTimeline.pc():!1};p.Kc=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};
533
+ p.Fa=function(){if(this.i){if(!this.od&&"HLS"==this.i.type)return{start:0,end:0};var a=this.i.presentationTimeline;return{start:a.Hc(),end:a.Mb()}}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}};p.pi=function(){this.R()&&(this.g.currentTime=this.Fa().end)};p.keySystem=function(){var a=this.drmInfo();return a?a.keySystem:""};p.drmInfo=function(){return this.m?this.m.g:null};p.qd=function(){return this.m?this.m.qd():Infinity};
534
+ p.yf=function(){return this.m?this.m.yf():[]};p.$d=function(){return this.m?this.m.$d():{}};p.vd=function(){return this.M?this.M.g==Ue:!1};p.Lb=function(){return this.g?this.K?this.K.h:1:0};
535
535
  p.Jd=function(a){var b=this;0==a?Sa("A trick play rate of 0 is unsupported!"):(this.sa.sb(),this.g.paused&&this.g.play(),this.K.set(a),this.l==Jm&&(this.u.playbackRateChanged(a),qk(this.j,1<Math.abs(a))),this.R()&&this.sa.o(this.g,"timeupdate",function(){var c=b.g.currentTime,d=b.Fa(),e=b.h.streaming.safeSeekOffset;0<a?c>=d.end&&b.kd():c<=d.start+e&&b.kd()}))};p.kd=function(){var a=this.K.Fc();this.l==Xm&&this.K.set(a);this.l==Jm&&(this.K.set(a),this.u.playbackRateChanged(a),qk(this.j,!1));this.sa.sb()};
536
536
  p.kb=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,pe(e)){var f=he(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 oe(g)}):[]};
537
- p.$b=function(){if(this.i){for(var a=this.j?this.j.s:null,b=[],c=t(this.i.textStreams),d=c.next();!d.done;d=c.next()){d=d.value;var e=ie(d);e.active=d==a;b.push(e)}return b}return this.g&&this.g.src&&this.g.textTracks?Zm(this).map(function(f){return me(f)}):[]};p.Zd=function(){var a=this.Ub;this.i&&(a=this.i.imageStreams);return a.map(function(b){return je(b)})};
538
- p.Hh=function(a){var b=this,c,d,e,f;return K(function(g){if(1==g.g){if(b.l!=Jm&&b.l!=Xm)return g.return(null);c=b.Ub;b.i&&(c=b.i.imageStreams);return(d=c.find(function(h){return h.id==a}))?d.segmentIndex?g.F(2):D(g,d.createSegmentIndex(),2):g.return(null)}if(4!=g.g)return e=[],Gj(d.segmentIndex,function(h){var k=gn(h.tilesLayout||d.tilesLayout);if(k){k=k.rows*k.hc;for(var l=h.i-h.startTime,m=0;m<k;m++)e.push(b.Cf(a,h.startTime+l*m/k))}}),D(g,Promise.all(e),4);f=g.h;return g.return(f.filter(function(h){return h}))})};
539
- function gn(a){return a?(a=/(\d+)x(\d+)/.exec(a))?{hc:parseInt(a[1],10),rows:parseInt(a[2],10)}:null:null}
540
- p.Cf=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B;return K(function(C){if(1==C.g){if(c.l!=Jm&&c.l!=Xm)return C.return(null);d=c.Ub;c.i&&(d=c.i.imageStreams);return(e=d.find(function(E){return E.id==a}))?e.segmentIndex?C.F(2):D(C,e.createSegmentIndex(),2):C.return(null)}f=e.segmentIndex.find(b);if(null==f)return C.return(null);g=e.segmentIndex.get(f);h=gn(g.tilesLayout||e.tilesLayout);if(!h)return C.return(null);k=e.width||0;l=e.height||0;m=k/h.hc;n=l/h.rows;q=h.hc*h.rows;r=g.i-g.startTime;
541
- u=g.H||r/q;v=g.startTime;z=y=0;1<q&&(x=Math.floor((b-g.startTime)/u),v=g.startTime+x*u,y=x%h.hc*m,z=Math.floor(x/h.hc)*n);A=!1;if(B=g.G)A=!0,n=B.height,y=B.positionX,z=B.positionY,m=B.width;return C.return({segment:g,imageHeight:l,imageWidth:k,height:n,positionX:y,positionY:z,startTime:v,duration:u,uris:g.aa(),width:m,sprite:A})})};
537
+ p.ac=function(){if(this.i){for(var a=this.j?this.j.s:null,b=[],c=t(this.i.textStreams),d=c.next();!d.done;d=c.next()){d=d.value;var e=ie(d);e.active=d==a;b.push(e)}return b}return this.g&&this.g.src&&this.g.textTracks?Zm(this).map(function(f){return me(f)}):[]};p.Zd=function(){var a=this.Wb;this.i&&(a=this.i.imageStreams);return a.map(function(b){return je(b)})};
538
+ p.Hh=function(a){var b=this,c,d,e,f;return K(function(g){if(1==g.g){if(b.l!=Jm&&b.l!=Xm)return g.return(null);c=b.Wb;b.i&&(c=b.i.imageStreams);return(d=c.find(function(h){return h.id==a}))?d.segmentIndex?g.F(2):D(g,d.createSegmentIndex(),2):g.return(null)}if(4!=g.g)return e=[],Gj(d.segmentIndex,function(h){var k=gn(h.tilesLayout||d.tilesLayout);if(k){k=k.rows*k.ic;for(var l=h.i-h.startTime,m=0;m<k;m++)e.push(b.Cf(a,h.startTime+l*m/k))}}),D(g,Promise.all(e),4);f=g.h;return g.return(f.filter(function(h){return h}))})};
539
+ function gn(a){return a?(a=/(\d+)x(\d+)/.exec(a))?{ic:parseInt(a[1],10),rows:parseInt(a[2],10)}:null:null}
540
+ p.Cf=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B;return K(function(C){if(1==C.g){if(c.l!=Jm&&c.l!=Xm)return C.return(null);d=c.Wb;c.i&&(d=c.i.imageStreams);return(e=d.find(function(E){return E.id==a}))?e.segmentIndex?C.F(2):D(C,e.createSegmentIndex(),2):C.return(null)}f=e.segmentIndex.find(b);if(null==f)return C.return(null);g=e.segmentIndex.get(f);h=gn(g.tilesLayout||e.tilesLayout);if(!h)return C.return(null);k=e.width||0;l=e.height||0;m=k/h.ic;n=l/h.rows;q=h.ic*h.rows;r=g.i-g.startTime;
541
+ u=g.H||r/q;v=g.startTime;z=y=0;1<q&&(x=Math.floor((b-g.startTime)/u),v=g.startTime+x*u,y=x%h.ic*m,z=Math.floor(x/h.ic)*n);A=!1;if(B=g.G)A=!0,n=B.height,y=B.positionX,z=B.positionY,m=B.width;return C.return({segment:g,imageHeight:l,imageWidth:k,height:n,positionX:y,positionY:z,startTime:v,duration:u,uris:g.aa(),width:m,sprite:A})})};
542
542
  p.dg=function(a){if(this.i&&this.j){var b=this.i.textStreams.find(function(d){return d.id==a.id});b&&b!=this.j.s&&(Ql(this.C.h,b,!1),tk(this.j,b),hn(this),this.Qa=b.language)}else if(this.g&&this.g.src&&this.g.textTracks){b=Zm(this);b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,ke(c)==a.id?c.mode=this.Z?"showing":"hidden":c.mode="disabled";hn(this)}};
543
543
  p.Fe=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&&Sa("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&&pe(d)&&(Hm(this,d,!1,b,c),this.Ka=new Ie(d,this.h.mediaSource.codecSwitchingStrategy,this.h.manifest.dash.enableAudioGroups),Tm(this))}else if(this.g&&this.g.audioTracks)for(b=
544
- Array.from(this.g.audioTracks),b=t(b),c=b.next();!c.done;c=b.next())if(c=c.value,ke(c)==a.id){jn(this,c);break}};p.Jh=function(){return kn(this.kb())};p.ii=function(){return kn(this.$b())};p.Ih=function(){return Array.from(ln(this.kb()))};p.gi=function(){return Array.from(ln(this.$b()))};
544
+ Array.from(this.g.audioTracks),b=t(b),c=b.next();!c.done;c=b.next())if(c=c.value,ke(c)==a.id){jn(this,c);break}};p.Jh=function(){return kn(this.kb())};p.ii=function(){return kn(this.ac())};p.Ih=function(){return Array.from(ln(this.kb()))};p.gi=function(){return Array.from(ln(this.ac()))};
545
545
  p.Ee=function(a,b,c,d){c=void 0===c?0:c;d=void 0===d?0:d;if(this.i&&this.G){this.Ka=new Je(a,b||"",c,"","","",this.h.mediaSource.codecSwitchingStrategy,this.h.manifest.dash.enableAudioGroups);a=function(g,h){return g.video||h.video?g.video&&h.video?Math.abs((g.video.height||0)-(h.video.height||0))+Math.abs((g.video.width||0)-(h.video.width||0)):Infinity:0};b=this.j.j;var e=this.Ka.create(this.i.variants);c=null;e=t(e.values());for(var f=e.next();!f.done;f=e.next())if(f=f.value,!c||a(c,b)>a(f,b))c=
546
- f;c?(a=he(c),this.Fe(a,!0,d)):fn(this)}else this.g&&this.g.audioTracks&&(d=re(this.kb(),a,b||"",!1)[0])&&this.Fe(d)};p.cg=function(a,b,c){c=void 0===c?!1:c;if(this.i&&this.G){if(this.Qa=a,this.Gb=b||"",this.Db=c,(a=re(this.i.textStreams,this.Qa,this.Gb,this.Db)[0]||null)&&a!=this.j.s&&(Ql(this.C.h,a,!1),this.h.streaming.alwaysStreamText||this.rc()))tk(this.j,a),hn(this)}else(a=re(this.$b(),a,b||"",c)[0])&&this.dg(a)};
546
+ f;c?(a=he(c),this.Fe(a,!0,d)):fn(this)}else this.g&&this.g.audioTracks&&(d=re(this.kb(),a,b||"",!1)[0])&&this.Fe(d)};p.cg=function(a,b,c){c=void 0===c?!1:c;if(this.i&&this.G){if(this.Qa=a,this.Gb=b||"",this.Db=c,(a=re(this.i.textStreams,this.Qa,this.Gb,this.Db)[0]||null)&&a!=this.j.s&&(Ql(this.C.h,a,!1),this.h.streaming.alwaysStreamText||this.rc()))tk(this.j,a),hn(this)}else(a=re(this.ac(),a,b||"",c)[0])&&this.dg(a)};
547
547
  p.cj=function(a,b,c){b=void 0===b?!0:b;c=void 0===c?0:c;if(this.i&&this.G){for(var d=null,e=t(this.i.variants),f=e.next();!f.done;f=e.next())if(f=f.value,f.audio.label==a){d=f;break}null!=d&&(this.Ka=new Je(d.language,"",0,"","",a,this.h.mediaSource.codecSwitchingStrategy,this.h.manifest.dash.enableAudioGroups),fn(this,b,c))}else if(this.g&&this.g.audioTracks){c=Array.from(this.g.audioTracks);b=null;c=t(c);for(d=c.next();!d.done;d=c.next())d=d.value,d.label==a&&(b=d);b&&jn(this,b)}};
548
548
  p.rc=function(){var a=this.Z;return this.I&&this.l==Jm?this.I.H.isTextVisible():this.g&&this.g.src&&this.g.textTracks?Zm(this).some(function(b){return"showing"==b.mode}):a};p.Lg=function(){return this.g&&this.g.src&&this.g.textTracks?mn(this).map(function(a){return me(a)}):[]};
549
549
  p.Mh=function(a){if(!this.g||!this.g.src||!this.g.textTracks)return[];var b=Nb(a),c=mn(this).filter(function(h){return Nb(h.language)==b});if(!c||!c.length)return[];a=[];var d=new Set;c=t(c);for(var e=c.next();!e.done;e=c.next())if((e=e.value)&&e.cues){e=t(e.cues);for(var f=e.next();!f.done;f=e.next()){var g=f.value;(f=g.id)&&""!=f||(f=g.startTime+"-"+g.endTime+"-"+g.text);g={id:f,title:g.text,startTime:g.startTime,endTime:g.endTime};d.has(f)||(a.push(g),d.add(f))}}return a};
@@ -555,12 +555,12 @@ p.getStats=function(){if(this.l!=Jm&&this.l!=Xm)return{width:NaN,height:NaN,stre
555
555
  Math.round(100*b);c.i=isNaN(c.i)?b:Math.max(c.i,b)}this.G&&(this.C.M=this.G.vg(),this.C.P=this.G.wg());if(a.getVideoPlaybackQuality){c=a.getVideoPlaybackQuality();b=this.C;var d=Number(c.totalVideoFrames);b.L=Number(c.droppedVideoFrames);b.K=d;this.C.J=Number(c.corruptedVideoFrames)}this.m?(c=this.m,c=c.K?c.K:NaN):c=NaN;this.C.u=c;if(this.l==Jm){c=this.j.j;b=this.j.s;if(c){d=this.K?this.K.h:1;var e=d*c.bandwidth;b&&b.bandwidth&&(e+=d*b.bandwidth);this.C.D=e}c&&c.video&&(b=this.C,d=c.video.height||
556
556
  NaN,b.s=c.video.width||NaN,b.l=d);this.R()&&(c=this.Ng().valueOf()+1E3*a.currentTime,this.C.G=(Date.now()-c)/1E3);this.i&&this.i.presentationTimeline&&(this.C.I=this.i.presentationTimeline.g);c=this.u.getBandwidthEstimate();this.C.C=c}this.l==Xm&&(c=this.C,b=a.videoHeight||NaN,c.s=a.videoWidth||NaN,c.l=b);var f=this.C;a=f.s;c=f.l;b=f.D;d=f.K;e=f.L;var g=f.J,h=f.P,k=f.M,l=f.C,m=f.i,n=f.m,q=f.H,r=f.j,u=Nl(f.g,"playing"),v=Nl(f.g,"paused"),y=Nl(f.g,"buffering"),z=f.u,x=f.G,A=f.I,B=Ol(f.g),C=[];f=t(f.h.g);
557
557
  for(var E=f.next();!E.done;E=f.next())E=E.value,C.push({timestamp:E.timestamp,id:E.id,type:E.type,fromAdaptation:E.fromAdaptation,bandwidth:E.bandwidth});return{width:a,height:c,streamBandwidth:b,decodedFrames:d,droppedFrames:e,corruptedFrames:g,stallsDetected:h,gapsJumped:k,estimatedBandwidth:l,completionPercent:m,loadLatency:n,manifestTimeSeconds:q,drmTimeSeconds:r,playTime:u,pauseTime:v,bufferingTime:y,licenseTime:z,liveLatency:x,maxSegmentDuration:A,stateHistory:B,switchHistory:C}};
558
- p.vh=function(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h=this,k,l,m,n,q,r,u,v,y,z,x,A;return K(function(B){switch(B.g){case 1:if(h.l!=Jm&&h.l!=Xm)throw new P(1,7,7004);"subtitles"!=c&&"captions"!=c&&Sa("Using a kind value different of `subtitles` or `captions` can cause unwanted issues.");if(d){B.F(2);break}return D(B,nn(h,a),3);case 3:d=B.h;case 2:k=[];h.D&&(k=h.D.getCuePoints());if(h.l!=Xm){B.F(4);break}g&&(c="forced");return D(B,on(h,a,b,c,d,f||"",k),5);case 5:l=Nb(b);m=h.$b();if(n=m.find(function(C){return Nb(C.language)==
558
+ p.vh=function(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h=this,k,l,m,n,q,r,u,v,y,z,x,A;return K(function(B){switch(B.g){case 1:if(h.l!=Jm&&h.l!=Xm)throw new P(1,7,7004);"subtitles"!=c&&"captions"!=c&&Sa("Using a kind value different of `subtitles` or `captions` can cause unwanted issues.");if(d){B.F(2);break}return D(B,nn(h,a),3);case 3:d=B.h;case 2:k=[];h.D&&(k=h.D.getCuePoints());if(h.l!=Xm){B.F(4);break}g&&(c="forced");return D(B,on(h,a,b,c,d,f||"",k),5);case 5:l=Nb(b);m=h.ac();if(n=m.find(function(C){return Nb(C.language)==
559
559
  l&&C.label==(f||"")&&C.kind==c}))return Dm(h),B.return(n);throw new P(1,2,2012);case 4:q=Kb;r=h.g.duration;h.i&&(r=h.i.presentationTimeline.getDuration());if(Infinity==r)throw new P(1,4,4033);if(!k.length){B.F(6);break}return D(B,pn(h,a,h.J,h.h.streaming.retryParameters),7);case 7:u=B.h,v=qn(h,u,d,k),y=new Blob([v],{type:"text/vtt"}),a=Gi(y),d="text/vtt";case 6:z={id:h.rg++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:Ij(0,r,[a]),mimeType:d||"",
560
560
  codecs:e||"",kind:c,encrypted:!1,drmInfos:[],keyIds:new Set,language:b,originalLanguage:b,label:f||null,type:q.za,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!!g,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!0,fastSwitching:!1};x=bd(z.mimeType,z.codecs);A=kd(x);if(!A)throw new P(2,2,2014,d);h.i.textStreams.push(z);Dm(h);return B.return(ie(z))}})};
561
561
  p.wh=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x;return K(function(A){switch(A.g){case 1:if(c.l!=Jm&&c.l!=Xm)throw new P(1,7,7004);if(b){A.F(2);break}return D(A,nn(c,a),3);case 3:b=A.h;case 2:if("text/vtt"!=b)throw new P(1,2,2017,a);d=Kb;e=c.g.duration;c.i&&(e=c.i.presentationTimeline.getDuration());if(Infinity==e)throw new P(1,4,4045);return D(A,pn(c,a,c.J,c.h.streaming.retryParameters),4);case 4:f=A.h;g=ld[b];if(!g)throw new P(2,2,2014,b);h=g();k={periodStart:0,segmentStart:0,segmentEnd:e,
562
- vttOffset:0};l=lc(f);m=h.parseMedia(l,k,a);n=[];q={};r=t(m);for(u=r.next();!u.done;q={ed:q.ed,dc:q.dc},u=r.next())q.dc=u.value,q.ed=null,v=function(B){return function(){null==B.ed&&(B.ed=Cb([a],[B.dc.payload]));return B.ed||[]}}(q),y=new Fh(q.dc.startTime,q.dc.endTime,v,0,null,null,0,0,Infinity),q.dc.payload.includes("#xywh")&&(z=q.dc.payload.split("#xywh=")[1].split(","),4===z.length&&y.ih({height:parseInt(z[3],10),positionX:parseInt(z[0],10),positionY:parseInt(z[1],10),width:parseInt(z[2],10)})),
563
- n.push(y);x={id:c.rg++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Fj(n),mimeType:b||"",codecs:"",kind:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:d.jd,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==Xm?c.Ub.push(x):
562
+ vttOffset:0};l=lc(f);m=h.parseMedia(l,k,a);n=[];q={};r=t(m);for(u=r.next();!u.done;q={ed:q.ed,ec:q.ec},u=r.next())q.ec=u.value,q.ed=null,v=function(B){return function(){null==B.ed&&(B.ed=Cb([a],[B.ec.payload]));return B.ed||[]}}(q),y=new Fh(q.ec.startTime,q.ec.endTime,v,0,null,null,0,0,Infinity),q.ec.payload.includes("#xywh")&&(z=q.ec.payload.split("#xywh=")[1].split(","),4===z.length&&y.ih({height:parseInt(z[3],10),positionX:parseInt(z[0],10),positionY:parseInt(z[1],10),width:parseInt(z[2],10)})),
563
+ n.push(y);x={id:c.rg++,originalId:null,groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Fj(n),mimeType:b||"",codecs:"",kind:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"und",originalLanguage:null,label:null,type:d.jd,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==Xm?c.Wb.push(x):
564
564
  c.i.imageStreams.push(x);Dm(c);return A.return(je(x))}})};
565
565
  p.uh=function(a,b,c){var d=this,e,f,g,h;return K(function(k){switch(k.g){case 1:if(d.l!=Jm&&d.l!=Xm)throw new P(1,7,7004);if(c){k.F(2);break}return D(k,nn(d,a),3);case 3:c=k.h;case 2:return e=[],d.D&&(e=d.D.getCuePoints()),D(k,on(d,a,b,"chapters",c,"",e),4);case 4:f=k.h;g=d.Lg();h=g.find(function(l){return l.language==b});if(!h){k.F(5);break}return D(k,new Promise(function(l,m){d.s.ka(f,"load",l);d.s.ka(f,"error",function(){m(new P(1,2,2015))})}),6);case 6:return Dm(d),k.return(h);case 5:throw new P(1,
566
566
  2,2012);}})};function nn(a,b){var c;return K(function(d){switch(d.g){case 1:return ta(d,2),D(d,Lk(b,a.J,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 P(1,2,2011,b);}})}
@@ -573,7 +573,7 @@ function xm(a,b){for(var c=new Set,d=t(b.textStreams),e=d.next();!e.done;e=d.nex
573
573
  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:Jb,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)}}
574
574
  function wm(a,b){return K(function(c){if(1==c.g)return D(c,rn(a,b),2);en(a,b);F(c)})}function rn(a,b){return K(function(c){if(1==c.g)return D(c,Td(a.m,b),2);if(!b.variants.some(pe))throw new P(2,4,4032);F(c)})}function en(a,b){if(a.l!=bm){Sd(b.variants,a.h.restrictions,a.ve)&&a.j&&Dm(a);var c=a.m?a.m.g:null;if(c&&a.m.u)for(var d=t(b.variants),e=d.next();!e.done;e=d.next())e=e.value,ym(a,c.keySystem,e.video),ym(a,c.keySystem,e.audio);sn(a,b)}}
575
575
  function ym(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,Yg(a.m,e.initDataType,e.initData)}}}
576
- function Pm(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,q;return K(function(r){if(1==r.g)return k?D(r,k.createSegmentIndex(),2):r.return(null);n=(m=k.segmentIndex.kc(l))?m.next().value:null;if(!n)return r.return(null);q=n.startTime;return r.return(q)})},D(h,e(c,b),2);if(3!=h.g)return f=h.h,D(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)})}
576
+ function Pm(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,q;return K(function(r){if(1==r.g)return k?D(r,k.createSegmentIndex(),2):r.return(null);n=(m=k.segmentIndex.lc(l))?m.next().value:null;if(!n)return r.return(null);q=n.startTime;return r.return(q)})},D(h,e(c,b),2);if(3!=h.g)return f=h.h,D(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)})}
577
577
  function lm(a){var b=a.vd();if(a.C&&a.M&&a.G){if(a.U){var c=a.U;b||c.j||(c.j=!0);c.j&&b&&(c.l=!0);c.m=b}Em(a)}b=(new Map).set("buffering",b);a.dispatchEvent(am("buffering",b))}function Fm(a){var b=a.g.playbackRate;0!=b&&(a.K&&a.K.set(b),b=am("ratechange"),a.dispatchEvent(b))}
578
578
  function Em(a){if(a.C&&a.M){var b=a.C.g,c="playing";a.M.g==Ue?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(am("statechanged",c)))}}
579
579
  function Um(a){if(a.R()){var b=a.Fa();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&&
@@ -594,12 +594,12 @@ missingKeys:Array.from(f),restrictedKeyStatuses:Array.from(g)},new P(2,4,4012,a)
594
594
  function kn(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=Nb(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));
595
595
  h.push({language:l,role:m,label:n})}});return h}M("shaka.Player",V);V.prototype.setVideoContainer=V.prototype.lg;V.prototype.getManifestParserFactory=V.prototype.$h;V.prototype.getManifest=V.prototype.Zh;V.prototype.retryStreaming=V.prototype.Yf;V.prototype.setMaxHardwareResolution=V.prototype.hg;V.prototype.addChaptersTrack=V.prototype.uh;V.prototype.addThumbnailsTrack=V.prototype.wh;V.prototype.addTextTrackAsync=V.prototype.vh;V.prototype.getStats=V.prototype.getStats;
596
596
  V.prototype.getBufferedInfo=V.prototype.Jb;V.prototype.getPresentationStartTimeAsDate=V.prototype.Ng;V.prototype.getPlayheadTimeAsDate=V.prototype.ci;V.prototype.setTextTrackVisibility=V.prototype.He;V.prototype.getChapters=V.prototype.Mh;V.prototype.getChaptersTracks=V.prototype.Lg;V.prototype.isTextTrackVisible=V.prototype.rc;V.prototype.selectVariantsByLabel=V.prototype.cj;V.prototype.selectTextLanguage=V.prototype.cg;V.prototype.selectAudioLanguage=V.prototype.Ee;
597
- V.prototype.getTextLanguages=V.prototype.gi;V.prototype.getAudioLanguages=V.prototype.Ih;V.prototype.getTextLanguagesAndRoles=V.prototype.ii;V.prototype.getAudioLanguagesAndRoles=V.prototype.Jh;V.prototype.selectVariantTrack=V.prototype.Fe;V.prototype.selectTextTrack=V.prototype.dg;V.prototype.getThumbnails=V.prototype.Cf;V.prototype.getAllThumbnails=V.prototype.Hh;V.prototype.getImageTracks=V.prototype.Zd;V.prototype.getTextTracks=V.prototype.$b;V.prototype.getVariantTracks=V.prototype.kb;
598
- V.prototype.cancelTrickPlay=V.prototype.kd;V.prototype.trickPlay=V.prototype.Jd;V.prototype.getPlaybackRate=V.prototype.Kb;V.prototype.isBuffering=V.prototype.vd;V.prototype.getKeyStatuses=V.prototype.$d;V.prototype.getActiveSessionsMetadata=V.prototype.yf;V.prototype.getExpiration=V.prototype.qd;V.prototype.drmInfo=V.prototype.drmInfo;V.prototype.keySystem=V.prototype.keySystem;V.prototype.goToLive=V.prototype.pi;V.prototype.seekRange=V.prototype.Fa;V.prototype.isAudioOnly=V.prototype.Kc;
599
- V.prototype.isInProgress=V.prototype.pc;V.prototype.isLive=V.prototype.R;V.prototype.getAdManager=V.prototype.Yd;V.prototype.getAssetUri=V.prototype.zf;V.prototype.getNetworkingEngine=V.prototype.Xb;V.prototype.getMediaElement=V.prototype.bi;V.prototype.getManifestType=V.prototype.Af;V.prototype.getLoadMode=V.prototype.ae;V.prototype.resetConfiguration=V.prototype.Wi;V.prototype.getBufferFullness=V.prototype.Kh;V.prototype.getConfiguration=V.prototype.getConfiguration;V.prototype.configure=V.prototype.configure;
597
+ V.prototype.getTextLanguages=V.prototype.gi;V.prototype.getAudioLanguages=V.prototype.Ih;V.prototype.getTextLanguagesAndRoles=V.prototype.ii;V.prototype.getAudioLanguagesAndRoles=V.prototype.Jh;V.prototype.selectVariantTrack=V.prototype.Fe;V.prototype.selectTextTrack=V.prototype.dg;V.prototype.getThumbnails=V.prototype.Cf;V.prototype.getAllThumbnails=V.prototype.Hh;V.prototype.getImageTracks=V.prototype.Zd;V.prototype.getTextTracks=V.prototype.ac;V.prototype.getVariantTracks=V.prototype.kb;
598
+ V.prototype.cancelTrickPlay=V.prototype.kd;V.prototype.trickPlay=V.prototype.Jd;V.prototype.getPlaybackRate=V.prototype.Lb;V.prototype.isBuffering=V.prototype.vd;V.prototype.getKeyStatuses=V.prototype.$d;V.prototype.getActiveSessionsMetadata=V.prototype.yf;V.prototype.getExpiration=V.prototype.qd;V.prototype.drmInfo=V.prototype.drmInfo;V.prototype.keySystem=V.prototype.keySystem;V.prototype.goToLive=V.prototype.pi;V.prototype.seekRange=V.prototype.Fa;V.prototype.isAudioOnly=V.prototype.Kc;
599
+ V.prototype.isInProgress=V.prototype.pc;V.prototype.isLive=V.prototype.R;V.prototype.getAdManager=V.prototype.Yd;V.prototype.getAssetUri=V.prototype.zf;V.prototype.getNetworkingEngine=V.prototype.Yb;V.prototype.getMediaElement=V.prototype.bi;V.prototype.getManifestType=V.prototype.Af;V.prototype.getLoadMode=V.prototype.ae;V.prototype.resetConfiguration=V.prototype.Wi;V.prototype.getBufferFullness=V.prototype.Kh;V.prototype.getConfiguration=V.prototype.getConfiguration;V.prototype.configure=V.prototype.configure;
600
600
  V.prototype.releaseAllMutexes=V.prototype.Si;V.prototype.load=V.prototype.load;V.prototype.updateStartTime=V.prototype.lj;V.prototype.unload=V.prototype.Sc;V.prototype.detach=V.prototype.detach;V.prototype.attachCanvas=V.prototype.yg;V.prototype.attach=V.prototype.Ac;
601
601
  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?D(h,qh(),3):h.F(2);2!=h.g&&(b=h.h);var k={};if(wd())for(var l in yh)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]=wd()?!!yh[m]:xd(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(cd));
602
- k={};l=t(l);for(m=l.next();!m.done;m=l.next()){m=m.value;k[m]=wd()?kd(m)?!0:dc(m)||(Wc(m)?!0:!1):xd(m);var n=m.split(";")[0];k[n]=k[n]||k[m]}d=k;e={manifest:c,media:d,drm:b};f=wn;for(g in f)e[g]=f[g]();return h.return(e)})};V.isBrowserSupported=cm;V.setAdManagerFactory=function(a){Wl=a};V.registerSupportPlugin=function(a,b){wn[a]=b};V.prototype.destroy=V.prototype.destroy;var bm=0,Sl=1,Jm=2,Xm=3;V.LoadMode={DESTROYED:bm,NOT_LOADED:Sl,MEDIA_SOURCE:Jm,SRC_EQUALS:Xm};V.version="v4.6.13";
602
+ k={};l=t(l);for(m=l.next();!m.done;m=l.next()){m=m.value;k[m]=wd()?kd(m)?!0:dc(m)||(Wc(m)?!0:!1):xd(m);var n=m.split(";")[0];k[n]=k[n]||k[m]}d=k;e={manifest:c,media:d,drm:b};f=wn;for(g in f)e[g]=f[g]();return h.return(e)})};V.isBrowserSupported=cm;V.setAdManagerFactory=function(a){Wl=a};V.registerSupportPlugin=function(a,b){wn[a]=b};V.prototype.destroy=V.prototype.destroy;var bm=0,Sl=1,Jm=2,Xm=3;V.LoadMode={DESTROYED:bm,NOT_LOADED:Sl,MEDIA_SOURCE:Jm,SRC_EQUALS:Xm};V.version="v4.6.15";
603
603
  var xn=["4","6"];Be=new function(a){this.g=a;this.i=Ce;this.h=De}(new ze(Number(xn[0]),Number(xn[1])));var vn=["output-restricted","internal-error"],wn={},Wl=null;function yn(){this.h=[];this.j=this.i=this.g=0};function zn(a,b,c){var d=this;this.g=a;this.h=b;this.j=c;this.i=!1;this.l=this.h.getVolume();this.m=new Af;this.m.o(this.h,google.ima.AdEvent.Type.PAUSED,function(){d.i=!0});this.m.o(this.h,google.ima.AdEvent.Type.RESUMED,function(){d.i=!1})}p=zn.prototype;p.getDuration=function(){return this.g.getDuration()};p.getMinSuggestedDuration=function(){return this.g.getMinSuggestedDuration()};p.getRemainingTime=function(){return this.h.getRemainingTime()};p.isPaused=function(){return this.i};
604
604
  p.isSkippable=function(){return 0<=this.g.getSkipTimeOffset()};p.getTimeUntilSkippable=function(){var a=this.g.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};p.canSkipNow=function(){return this.h.getAdSkippableState()};p.skip=function(){return this.h.skip()};p.pause=function(){return this.h.pause()};p.play=function(){return this.h.resume()};p.getVolume=function(){return this.h.getVolume()};p.setVolume=function(a){this.j.volume=a;return this.h.setVolume(a)};
605
605
  p.isMuted=function(){return 0==this.h.getVolume()};p.isLinear=function(){return this.g.isLinear()};p.resize=function(a,b){var c=!1,d=this.j;document.fullscreenEnabled?c=!!document.fullscreenElement:d.webkitSupportsFullscreen&&(c=d.webkitDisplayingFullscreen);this.h.resize(a,b,c?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)};p.setMuted=function(a){(this.j.muted=a)?(this.l=this.getVolume(),this.h.setVolume(0)):this.h.setVolume(this.l)};
@@ -607,7 +607,7 @@ p.getSequenceLength=function(){var a=this.g.getAdPodInfo();return null==a?1:a.ge
607
607
  p.getAdId=function(){return this.g.getAdId()};p.getCreativeAdId=function(){return this.g.getCreativeAdId()};p.getAdvertiserName=function(){return this.g.getAdvertiserName()};p.getMediaUrl=function(){return this.g.getMediaUrl()};p.getTimeOffset=function(){var a=this.g.getAdPodInfo();return null==a?0:a.getTimeOffset()};p.getPodIndex=function(){var a=this.g.getAdPodInfo();return null==a?0:a.getPodIndex()};p.release=function(){this.h=this.g=null};M("shaka.ads.ClientSideAd",zn);zn.prototype.release=zn.prototype.release;
608
608
  zn.prototype.getPodIndex=zn.prototype.getPodIndex;zn.prototype.getTimeOffset=zn.prototype.getTimeOffset;zn.prototype.getMediaUrl=zn.prototype.getMediaUrl;zn.prototype.getAdvertiserName=zn.prototype.getAdvertiserName;zn.prototype.getCreativeAdId=zn.prototype.getCreativeAdId;zn.prototype.getAdId=zn.prototype.getAdId;zn.prototype.getVastMediaWidth=zn.prototype.getVastMediaWidth;zn.prototype.getVastMediaHeight=zn.prototype.getVastMediaHeight;zn.prototype.getVastMediaBitrate=zn.prototype.getVastMediaBitrate;
609
609
  zn.prototype.getDescription=zn.prototype.getDescription;zn.prototype.getTitle=zn.prototype.getTitle;zn.prototype.getPositionInSequence=zn.prototype.getPositionInSequence;zn.prototype.getSequenceLength=zn.prototype.getSequenceLength;zn.prototype.setMuted=zn.prototype.setMuted;zn.prototype.resize=zn.prototype.resize;zn.prototype.isLinear=zn.prototype.isLinear;zn.prototype.isMuted=zn.prototype.isMuted;zn.prototype.setVolume=zn.prototype.setVolume;zn.prototype.getVolume=zn.prototype.getVolume;
610
- zn.prototype.play=zn.prototype.play;zn.prototype.pause=zn.prototype.pause;zn.prototype.skip=zn.prototype.skip;zn.prototype.canSkipNow=zn.prototype.canSkipNow;zn.prototype.getTimeUntilSkippable=zn.prototype.getTimeUntilSkippable;zn.prototype.isSkippable=zn.prototype.isSkippable;zn.prototype.isPaused=zn.prototype.isPaused;zn.prototype.getRemainingTime=zn.prototype.getRemainingTime;zn.prototype.getMinSuggestedDuration=zn.prototype.getMinSuggestedDuration;zn.prototype.getDuration=zn.prototype.getDuration;function An(a,b,c,d,e){var f=this;this.s=a;this.i=b;this.D=!1;this.u=this.G=null;this.H=NaN;this.m=e;this.j=null;this.h=new Af;google.ima.settings.setLocale(c);google.ima.settings.setDisableCustomPlaybackForIOS10Plus(!0);a=new google.ima.AdDisplayContainer(this.s,this.i);a.initialize();this.l=new google.ima.AdsLoader(a);this.l.getSettings().setPlayerType("shaka-player");this.l.getSettings().setPlayerVersion("v4.6.13");this.g=null;this.C=d||new google.ima.AdsRenderingSettings;this.h.o(this.l,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,
610
+ zn.prototype.play=zn.prototype.play;zn.prototype.pause=zn.prototype.pause;zn.prototype.skip=zn.prototype.skip;zn.prototype.canSkipNow=zn.prototype.canSkipNow;zn.prototype.getTimeUntilSkippable=zn.prototype.getTimeUntilSkippable;zn.prototype.isSkippable=zn.prototype.isSkippable;zn.prototype.isPaused=zn.prototype.isPaused;zn.prototype.getRemainingTime=zn.prototype.getRemainingTime;zn.prototype.getMinSuggestedDuration=zn.prototype.getMinSuggestedDuration;zn.prototype.getDuration=zn.prototype.getDuration;function An(a,b,c,d,e){var f=this;this.s=a;this.i=b;this.D=!1;this.u=this.G=null;this.H=NaN;this.m=e;this.j=null;this.h=new Af;google.ima.settings.setLocale(c);google.ima.settings.setDisableCustomPlaybackForIOS10Plus(!0);a=new google.ima.AdDisplayContainer(this.s,this.i);a.initialize();this.l=new google.ima.AdsLoader(a);this.l.getSettings().setPlayerType("shaka-player");this.l.getSettings().setPlayerVersion("v4.6.15");this.g=null;this.C=d||new google.ima.AdsRenderingSettings;this.h.o(this.l,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,
611
611
  function(g){Bn(f,g)});this.h.o(this.l,google.ima.AdErrorEvent.Type.AD_ERROR,function(g){Cn(f,g)});this.h.o(this.i,"ended",function(){f.l.contentComplete()});this.h.ka(this.i,"play",function(){f.D=!0})}An.prototype.configure=function(a){this.G=a};An.prototype.stop=function(){this.g&&this.g.stop();this.s&&Wk(this.s)};An.prototype.release=function(){this.stop();this.u&&this.u.disconnect();this.h&&this.h.release();this.g&&this.g.destroy();this.l.destroy()};
612
612
  function Cn(a,b){b.getError();b=(new Map).set("originalEvent",b);a.m(new O("ad-error",b));Dn(a,null);a.m(new O("ad-cue-points-changed",(new Map).set("cuepoints",[])))}
613
613
  function Bn(a,b){a.m(new O("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.H)));if(a.G.customPlayheadTracker){var c={currentTime:a.i.currentTime};a.g=b.getAdsManager(c,a.C);a.i.muted?a.g.setVolume(0):a.g.setVolume(a.i.volume);a.h.o(a.i,"timeupdate",function(){a.i.duration&&(c.currentTime=a.i.currentTime)});a.h.o(a.i,"volumechange",function(){a.j&&(a.j.setVolume(a.i.volume),a.i.muted&&a.j.setMuted(!0))})}else a.g=b.getAdsManager(a.i,a.C);a.m(new O("ima-ad-manager-loaded",(new Map).set("imaAdManager",
@@ -625,7 +625,7 @@ p.isLinear=function(){return this.l};p.resize=function(){};p.setMuted=function(a
625
625
  p.getAdvertiserName=function(){return""};p.getMediaUrl=function(){return null};p.getTimeOffset=function(){return 0};p.getPodIndex=function(){return 0};p.release=function(){this.j=this.i=this.g=this.h=null};M("shaka.ads.MediaTailorAd",Hn);Hn.prototype.release=Hn.prototype.release;Hn.prototype.getPodIndex=Hn.prototype.getPodIndex;Hn.prototype.getTimeOffset=Hn.prototype.getTimeOffset;Hn.prototype.getMediaUrl=Hn.prototype.getMediaUrl;Hn.prototype.getAdvertiserName=Hn.prototype.getAdvertiserName;
626
626
  Hn.prototype.getCreativeAdId=Hn.prototype.getCreativeAdId;Hn.prototype.getAdId=Hn.prototype.getAdId;Hn.prototype.getVastMediaWidth=Hn.prototype.getVastMediaWidth;Hn.prototype.getVastMediaHeight=Hn.prototype.getVastMediaHeight;Hn.prototype.getVastMediaBitrate=Hn.prototype.getVastMediaBitrate;Hn.prototype.getDescription=Hn.prototype.getDescription;Hn.prototype.getTitle=Hn.prototype.getTitle;Hn.prototype.getPositionInSequence=Hn.prototype.getPositionInSequence;Hn.prototype.getSequenceLength=Hn.prototype.getSequenceLength;
627
627
  Hn.prototype.setMuted=Hn.prototype.setMuted;Hn.prototype.resize=Hn.prototype.resize;Hn.prototype.isLinear=Hn.prototype.isLinear;Hn.prototype.isMuted=Hn.prototype.isMuted;Hn.prototype.setVolume=Hn.prototype.setVolume;Hn.prototype.getVolume=Hn.prototype.getVolume;Hn.prototype.play=Hn.prototype.play;Hn.prototype.pause=Hn.prototype.pause;Hn.prototype.skip=Hn.prototype.skip;Hn.prototype.canSkipNow=Hn.prototype.canSkipNow;Hn.prototype.getTimeUntilSkippable=Hn.prototype.getTimeUntilSkippable;
628
- Hn.prototype.isSkippable=Hn.prototype.isSkippable;Hn.prototype.isPaused=Hn.prototype.isPaused;Hn.prototype.getRemainingTime=Hn.prototype.getRemainingTime;Hn.prototype.getMinSuggestedDuration=Hn.prototype.getMinSuggestedDuration;Hn.prototype.getDuration=Hn.prototype.getDuration;function In(a,b,c,d){this.D=a;this.K=b;this.g=c;this.l=null;this.V=NaN;this.i=d;this.J=!1;this.C=null;this.j=[];this.M=[];this.L=this.G=this.h=null;this.H=new Map;this.m=[];this.u=[];this.P="";this.U=!0;this.I="";this.s=new Af}In.prototype.stop=function(){for(var a=t(this.m),b=a.next();!b.done;b=a.next())b=b.value,this.s.cc(b.target,b.type,b.listener);Jn(this);this.m=[];this.u=[];this.P="";this.U=!0;this.I="";this.C=null;this.j=[];this.M=[];this.H.clear()};
628
+ Hn.prototype.isSkippable=Hn.prototype.isSkippable;Hn.prototype.isPaused=Hn.prototype.isPaused;Hn.prototype.getRemainingTime=Hn.prototype.getRemainingTime;Hn.prototype.getMinSuggestedDuration=Hn.prototype.getMinSuggestedDuration;Hn.prototype.getDuration=Hn.prototype.getDuration;function In(a,b,c,d){this.D=a;this.K=b;this.g=c;this.l=null;this.V=NaN;this.i=d;this.J=!1;this.C=null;this.j=[];this.M=[];this.L=this.G=this.h=null;this.H=new Map;this.m=[];this.u=[];this.P="";this.U=!0;this.I="";this.s=new Af}In.prototype.stop=function(){for(var a=t(this.m),b=a.next();!b.done;b=a.next())b=b.value,this.s.dc(b.target,b.type,b.listener);Jn(this);this.m=[];this.u=[];this.P="";this.U=!0;this.I="";this.C=null;this.j=[];this.M=[];this.H.clear()};
629
629
  In.prototype.release=function(){this.stop();this.s&&this.s.release()};In.prototype.onManifestUpdated=function(a){this.J=a;""!=this.P&&(Kn(this,this.P,this.U),this.U=!1)};In.prototype.getCuePoints=function(){for(var a=[],b=t(this.j),c=b.next();!c.done;c=b.next()){c=t(c.value.ads);for(var d=c.next();!d.done;d=c.next())d=d.value,a.push({start:d.startTimeInSeconds,end:d.startTimeInSeconds+d.durationInSeconds})}return a};
630
630
  function Ln(a,b,c){var d,e,f,g,h,k,l,m,n,q,r;K(function(u){if(1==u.g)return d=qf([b],Ye()),d.method="POST",c&&(e=JSON.stringify(c),d.body=Of(e)),f=a.K.request(7,d),ta(u,2),D(u,f.promise,4);if(2!=u.g){g=u.h;h=Kf(g.data);k=JSON.parse(h);if(k.manifestUrl&&k.trackingUrl)l=new gb(b),m=new gb(k.trackingUrl),a.P=l.resolve(m).toString(),n=Date.now()/1E3,q=n-a.V,a.i(new O("ads-loaded",(new Map).set("loadTime",q))),r=new gb(k.manifestUrl),a.l.resolve(l.resolve(r).toString()),a.l=null;else throw Error("Insufficient data from MediaTailor.");
631
631
  return va(u,0)}wa(u);if(!a.I.length)return a.l.reject("MediaTailor request returned an error and there was no backup asset uri provided."),a.l=null,u.return();a.l.resolve(a.I);a.l=null;F(u)})}
@@ -638,7 +638,7 @@ function Pn(a){if(a.g.duration&&(a.h||a.j.length)){var b=a.g.currentTime,c=!1;if
638
638
  e=a.h.getDuration();0<e&&(0>=d||d>e)&&Jn(a)}if(!a.h||!a.h.isLinear()){a:for(d=t(a.j),e=d.next();!e.done;e=d.next()){e=e.value;if(a.h&&a.h.isLinear())break;for(f=0;f<e.ads.length;f++){var g=e.ads[f],h=g.startTimeInSeconds+g.durationInSeconds;if(g.startTimeInSeconds<=b&&h>b){if(a.M.includes(g.adId)){if(a.g.ended)continue;a.g.currentTime=h;break a}Jn(a);a.L=e;a.h=new Hn(g,f+1,e.ads.length,!0,a.g);a.G=g;0===f&&Rn(a,"breakStart");Sn(a);break}}}if(!a.h)for(d=t(a.j),e=d.next();!e.done;e=d.next()){e=e.value;
639
639
  if(a.h)break;for(f=0;f<e.nonLinearAdsList.length;f++)if(g=e.nonLinearAdsList[f],g.nonLinearAdList.length){h=e.startTimeInSeconds;var k=a.H.get(On(g.nonLinearAdList[0]));if(h<=b&&k&&k.length){Jn(a);h=a;k=t(k);for(var l=k.next();!l.done;l=k.next())if(l=l.value,l.data.source.length){var m=document.createElement("img");m.src=l.data.source[0].url;m.style.top=(l.placeholder.top||0)+"%";m.style.height=100-(l.placeholder.top||0)+"%";m.style.left=(l.placeholder.left||0)+"%";m.style.maxWidth=100-(l.placeholder.left||
640
640
  0)+"%";m.style.objectFit="contain";m.style.position="absolute";h.D.appendChild(m)}a.L=e;a.h=new Hn(g,f+1,e.ads.length,!1,a.g);a.G=g;0===f&&Rn(a,"breakStart");Sn(a);break}}}c&&!a.h&&(b=a.g.currentTime,a.C&&a.C>b&&(a.g.currentTime=a.C),a.C=null)}}}
641
- function Jn(a){if(a.h){for(;a.D.lastChild;)a.D.removeChild(a.D.firstChild);a.J||a.M.push(a.G.adId);Rn(a,"complete");for(var b=t(a.m),c=b.next();!c.done;c=b.next())c=c.value,a.s.cc(c.target,c.type,c.listener);a.m=[];a.u=[];b=a.h.getPositionInSequence();c=a.h.getSequenceLength();b===c&&Rn(a,"breakEnd");a.h=null;a.G=null;a.L=null}}
641
+ function Jn(a){if(a.h){for(;a.D.lastChild;)a.D.removeChild(a.D.firstChild);a.J||a.M.push(a.G.adId);Rn(a,"complete");for(var b=t(a.m),c=b.next();!c.done;c=b.next())c=c.value,a.s.dc(c.target,c.type,c.listener);a.m=[];a.u=[];b=a.h.getPositionInSequence();c=a.h.getSequenceLength();b===c&&Rn(a,"breakEnd");a.h=null;a.G=null;a.L=null}}
642
642
  function Sn(a){var b=!1;a.g.paused?b=!0:(Rn(a,"impression"),Rn(a,"start"));a.m.push({target:a.g,type:"volumechange",listener:function(){a.g.muted&&Rn(a,"mute")}});a.m.push({target:a.g,type:"volumechange",listener:function(){a.g.muted||Rn(a,"unmute")}});a.m.push({target:a.g,type:"play",listener:function(){b?(Rn(a,"impression"),Rn(a,"start"),b=!1):Rn(a,"resume")}});a.m.push({target:a.g,type:"pause",listener:function(){Rn(a,"pause")}});for(var c=t(a.m),d=c.next();!d.done;d=c.next())d=d.value,a.s.o(d.target,
643
643
  d.type,d.listener)}
644
644
  function Rn(a,b){var c=a.G.trackingEvents.find(function(e){return e.eventType==b});c||(c=a.L.adBreakTrackingEvents.find(function(e){return e.eventType==b}));if(c){c=t(c.beaconUrls);for(var d=c.next();!d.done;d=c.next())(d=d.value)&&""!=d&&(d=qf([d],Ye()),d.method="POST",a.K.request(7,d))}switch(b){case "impression":a.i(new O("ad-impression"));break;case "start":a.i(new O("ad-started",(new Map).set("ad",a.h)));break;case "mute":a.i(new O("ad-muted"));break;case "unmute":a.i(new O("ad-volume-changed"));break;
@@ -657,9 +657,9 @@ function Vn(a,b){a.i(new O("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-
657
657
  p.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);ab.prototype.release.call(this)};p.onAssetUnload=function(){this.h&&this.h.stop();this.i&&this.i.stop();this.g&&this.g.stop();this.dispatchEvent(new O("ad-stopped"));this.j=new yn};p.requestClientSideAds=function(a){if(!this.h)throw new P(1,10,10001);var b=this.h;b.g&&b.g.destroy();b.l&&b.l.contentComplete();b.H=Date.now()/1E3;b.l.requestAds(a)};
658
658
  p.updateClientSideAdsRenderingSettings=function(a){if(!this.h)throw new P(1,10,10001);var b=this.h;b.C=a;b.g&&b.g.updateAdsRenderingSettings(b.C)};p.initMediaTailor=function(a,b,c){var d=this;this.i&&this.i.release();this.i=new In(a,b,c,function(e){return Wn(d,e)})};p.requestMediaTailorStream=function(a,b,c){if(!this.i)throw new P(1,10,10005);var d=this.i;c=void 0===c?"":c;d.l?a=Promise.reject(new P(1,10,10004)):(d.l=new $e,Ln(d,a,b),d.I=c||"",d.V=Date.now()/1E3,a=d.l);return a};
659
659
  p.initServerSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.dai)throw new P(2,10,10002);this.g&&this.g.release();this.g=new Un(a,b,this.m,function(d){return Wn(c,d)});this.g.configure(this.l)};
660
- p.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new P(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Sa('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.13";c=this.g;c.j?a=Promise.reject(new P(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
661
- (c.I=!0),c.j=new $e,c.g.requestStream(a),c.D=b||"",c.H=Date.now()/1E3,a=c.j);return a};p.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new P(1,10,10003);(a.mpt||a.mpv)&&Sa('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.13";this.g.g.replaceAdTagParameters(a)};
662
- p.getServerSideCuePoints=function(){Ae("AdManager","Please use getCuePoints function.");return this.getCuePoints()};p.getCuePoints=function(){var a=[];this.g&&(a=a.concat(this.g.getCuePoints()));this.i&&(a=a.concat(this.i.getCuePoints()));return a};p.getStats=function(){var a=this.j;return{loadTimes:a.h,started:a.g,playedCompletely:a.i,skipped:a.j}};p.onManifestUpdated=function(a){if(this.i)this.i.onManifestUpdated(a)};
660
+ p.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new P(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Sa('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.15";c=this.g;c.j?a=Promise.reject(new P(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
661
+ (c.I=!0),c.j=new $e,c.g.requestStream(a),c.D=b||"",c.H=Date.now()/1E3,a=c.j);return a};p.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new P(1,10,10003);(a.mpt||a.mpv)&&Sa('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.15";this.g.g.replaceAdTagParameters(a)};
662
+ p.getServerSideCuePoints=function(){Ae("AdManager.getServerSideCuePoints","Please use getCuePoints function.");return this.getCuePoints()};p.getCuePoints=function(){var a=[];this.g&&(a=a.concat(this.g.getCuePoints()));this.i&&(a=a.concat(this.i.getCuePoints()));return a};p.getStats=function(){var a=this.j;return{loadTimes:a.h,started:a.g,playedCompletely:a.i,skipped:a.j}};p.onManifestUpdated=function(a){if(this.i)this.i.onManifestUpdated(a)};
663
663
  p.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)}};p.onHlsTimedMetadata=function(a,b){this.g&&this.g.g.processMetadata("ID3",a.data,b)};p.onCueMetadataChange=function(a){if(this.g)this.g.onCueMetadataChange(a)};
664
664
  function Wn(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)}M("shaka.ads.AdManager",W);W.prototype.onCueMetadataChange=W.prototype.onCueMetadataChange;W.prototype.onHlsTimedMetadata=W.prototype.onHlsTimedMetadata;W.prototype.onDashTimedMetadata=W.prototype.onDashTimedMetadata;W.prototype.onManifestUpdated=W.prototype.onManifestUpdated;W.prototype.getStats=W.prototype.getStats;
665
665
  W.prototype.getCuePoints=W.prototype.getCuePoints;W.prototype.getServerSideCuePoints=W.prototype.getServerSideCuePoints;W.prototype.replaceServerSideAdTagParameters=W.prototype.replaceServerSideAdTagParameters;W.prototype.requestServerSideStream=W.prototype.requestServerSideStream;W.prototype.initServerSide=W.prototype.initServerSide;W.prototype.requestMediaTailorStream=W.prototype.requestMediaTailorStream;W.prototype.initMediaTailor=W.prototype.initMediaTailor;
@@ -681,7 +681,7 @@ p.set=function(a,b,c){this.g[a][b]=c;wo(this,{type:"set",targetName:a,property:b
681
681
  p.ah=function(a,b){wo(this,{type:"call",targetName:a,methodName:b,args:Ga.apply(2,arguments)})};p.Ti=function(a,b){var c=Ga.apply(2,arguments),d=new $e,e=this.J.toString();this.J++;this.i[e]=d;try{wo(this,{type:"asyncCall",targetName:a,methodName:b,args:c,id:e})}catch(f){d.reject(f)}return d};function ro(a,b){var c=a.K();a.l=new $e;a.C=!0;xo(a,c,b)}function qo(a){var b=po;b.removeUpdateListener(a.D);b.removeMessageListener("urn:x-cast:com.google.shaka.v2",a.G)}
682
682
  function mo(a){var b=po?"connected"==po.status:!1;if(a.h&&!b){a.H();for(var c in a.g)a.g[c]={};oo(a)}a.h=b;a.L=b?po.receiver.friendlyName:"";a.j.Pa()}function oo(a){for(var b in a.i){var c=a.i[b];delete a.i[b];c.reject(new P(1,7,7E3))}}function wo(a,b){b=Xn(b);var c=po;try{c.sendMessage("urn:x-cast:com.google.shaka.v2",b,function(){},Va)}catch(d){throw b=new P(2,8,8005,d),c=new O("error",(new Map).set("detail",b)),a.u("player",c),a.Dc(),b;}}var to=.02,so=!1,po=null,vo=null,no=new Set;
683
683
  function uo(a){vo?window.__onGCastApiAvailable=vo:delete window.__onGCastApiAvailable;vo=null;if(a)for(var b=t(no),c=b.next();!c.done;c=b.next())c.value.init();"function"===typeof window.__onGCastApiAvailable&&window.__onGCastApiAvailable(a)};function Ao(a,b,c,d){d=void 0===d?!1:d;ab.call(this);var e=this;this.i=a;this.h=b;this.m=this.s=this.j=this.u=this.l=null;this.G=c;this.D=d;this.C=new Map;this.g=new lo(c,function(){return Bo(e)},function(){return Co(e)},function(f,g){return Do(e,f,g)},function(){return Eo(e)},function(){return Fo(e)},d);Go(this)}pa(Ao,ab);p=Ao.prototype;
684
- p.destroy=function(a){a&&this.g.Dc();this.m&&(this.m.release(),this.m=null);a=[];this.h&&(a.push(this.h.destroy()),this.h=null);this.g&&(a.push(this.g.destroy()),this.g=null);this.u=this.l=this.i=null;ab.prototype.release.call(this);return Promise.all(a)};p.ac=function(){return this.l};p.Gc=function(){return this.u};p.$e=function(){return this.g.m&&so};p.Aa=function(){return this.g.Aa()};p.Ce=function(){return this.g.Ce()};
684
+ p.destroy=function(a){a&&this.g.Dc();this.m&&(this.m.release(),this.m=null);a=[];this.h&&(a.push(this.h.destroy()),this.h=null);this.g&&(a.push(this.g.destroy()),this.g=null);this.u=this.l=this.i=null;ab.prototype.release.call(this);return Promise.all(a)};p.bc=function(){return this.l};p.Gc=function(){return this.u};p.$e=function(){return this.g.m&&so};p.Aa=function(){return this.g.Aa()};p.Ce=function(){return this.g.Ce()};
685
685
  p.cast=function(){var a=this,b;return K(function(c){return 1==c.g?(b=Fo(a),D(c,a.g.cast(b),2)):a.h?D(c,a.h.Sc(),0):c.return()})};p.eg=function(a){this.g.eg(a)};p.lh=function(){zo(this.g)};p.Dc=function(){this.g.Dc()};
686
686
  p.Cg=function(a,b){b=void 0===b?!1:b;var c=this;return K(function(d){if(1==d.g){if(a==c.G&&b==c.D)return d.return();c.G=a;c.D=b;c.g.Dc();return D(d,c.g.destroy(),2)}c.g=null;c.g=new lo(a,function(){return Bo(c)},function(){return Co(c)},function(e,f){return Do(c,e,f)},function(){return Eo(c)},function(){return Fo(c)},b);c.g.init();F(d)})};
687
687
  function Go(a){a.g.init();a.m=new Af;for(var b=t($n),c=b.next();!c.done;c=b.next())a.m.o(a.i,c.value,function(f){a.g.Aa()||(f=Oa(f),a.j.dispatchEvent(f))});for(var d in Pa)a.m.o(a.h,Pa[d],function(f){a.g.Aa()||a.s.dispatchEvent(f)});a.l={};b={};for(var e in a.i)b.Wc=e,Object.defineProperty(a.l,b.Wc,{configurable:!1,enumerable:!0,get:function(f){return function(){return Ho(a,f.Wc)}}(b),set:function(f){return function(g){var h=f.Wc;a.g.Aa()?a.g.set("video",h,g):a.i[h]=g}}(b)}),b={Wc:b.Wc};a.u={};Io(a,
@@ -692,10 +692,10 @@ function Co(a){var b=new O(a.l.paused?"pause":"play");a.j.dispatchEvent(b)}
692
692
  function Eo(a){for(var b=t(ho),c=b.next();!c.done;c=b.next()){var d=c.value;c=d[1];d=a.g.get("player",d[0])();a.h[c](d)}var e=a.g.get("player","getAssetUri")();d=a.g.get("video","ended");b=Promise.resolve();var f=a.i.autoplay;c=null;d||(c=a.g.get("video","currentTime"));var g;(d=a.g.get("player","getTextTracks")())&&d.length&&(g=d.find(function(l){return l.active}));var h=a.g.get("player","isTextTrackVisible")();e&&(a.i.autoplay=!1,b=a.h.load(e,c));var k={};c=t(bo);for(d=c.next();!d.done;d=c.next())d=
693
693
  d.value,k[d]=a.g.get("video",d);b.then(function(){if(a.i){for(var l=t(bo),m=l.next();!m.done;m=l.next())m=m.value,a.i[m]=k[m];l=t(io);for(m=l.next();!m.done;m=l.next()){var n=m.value;m=n[1];n=a.g.get("player",n[0])();a.h[m](n)}a.h.He(h);g&&a.h.cg(g.language,g.roles,g.forced);a.i.autoplay=f;e&&a.i.play()}},function(l){l=(new Map).set("detail",l);l=new O("error",l);a.h.dispatchEvent(l)})}
694
694
  function Ho(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.Aa()&&0==Object.keys(a.g.g.video).length){var c=a.i[b];if("function"!=typeof c)return c}return a.g.Aa()?a.g.get("video",b):(b=a.i[b],"function"==typeof b&&(b=b.bind(a.i)),b)}
695
- function Jo(a,b){a.C.has(b)&&(b=a.C.get(b));if("addEventListener"==b)return function(c,d,e){return a.s.addEventListener(c,d,e)};if("removeEventListener"==b)return function(c,d,e){return a.s.removeEventListener(c,d,e)};if("getMediaElement"==b)return function(){return a.l};if("getSharedConfiguration"==b)return a.g.get("player","getConfiguration");if("getNetworkingEngine"==b)return function(){return a.h.Xb()};if("getDrmEngine"==b)return function(){return a.h.m};if("getAdManager"==b)return function(){return a.h.Yd()};
695
+ function Jo(a,b){a.C.has(b)&&(b=a.C.get(b));if("addEventListener"==b)return function(c,d,e){return a.s.addEventListener(c,d,e)};if("removeEventListener"==b)return function(c,d,e){return a.s.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.Yb()};if("getDrmEngine"==b)return function(){return a.h.m};if("getAdManager"==b)return function(){return a.h.Yd()};
696
696
  if("setVideoContainer"==b)return function(c){return a.h.lg(c)};if(a.g.Aa()){if("getManifest"==b||"drmInfo"==b)return function(){Sa(b+"() does not work while casting!");return null};if("attach"==b||"detach"==b)return function(){Sa(b+"() does not work while casting!");return Promise.resolve()}}return a.g.Aa()&&0==Object.keys(a.g.g.video).length&&(eo[b]||fo[b])||!a.g.Aa()?a.h[b].bind(a.h):a.g.get("player",b)}
697
697
  function Do(a,b,c){a.g.Aa()&&("video"==b?a.j.dispatchEvent(c):"player"==b&&a.s.dispatchEvent(c))}M("shaka.cast.CastProxy",Ao);Ao.prototype.changeReceiverId=Ao.prototype.Cg;Ao.prototype.forceDisconnect=Ao.prototype.Dc;Ao.prototype.suggestDisconnect=Ao.prototype.lh;Ao.prototype.setAppData=Ao.prototype.eg;Ao.prototype.cast=Ao.prototype.cast;Ao.prototype.receiverName=Ao.prototype.Ce;Ao.prototype.isCasting=Ao.prototype.Aa;Ao.prototype.canCast=Ao.prototype.$e;Ao.prototype.getPlayer=Ao.prototype.Gc;
698
- Ao.prototype.getVideo=Ao.prototype.ac;Ao.prototype.destroy=Ao.prototype.destroy;function Lo(a,b,c,d){ab.call(this);var e=this;this.g=a;this.h=b;this.j=new Af;this.J={video:a,player:b};this.G=c||function(){};this.K=d||function(f){return f};this.i=null;this.H=!1;this.s=!0;this.m=0;this.D=!1;this.C=!0;this.u=this.l=null;this.I=new vd(function(){Mo(e)});No(this)}pa(Lo,ab);p=Lo.prototype;p.isConnected=function(){return this.H};p.wi=function(){return this.s};p.fj=function(a){this.i=a};p.Dh=function(){this.i=null};
698
+ Ao.prototype.getVideo=Ao.prototype.bc;Ao.prototype.destroy=Ao.prototype.destroy;function Lo(a,b,c,d){ab.call(this);var e=this;this.g=a;this.h=b;this.j=new Af;this.J={video:a,player:b};this.G=c||function(){};this.K=d||function(f){return f};this.i=null;this.H=!1;this.s=!0;this.m=0;this.D=!1;this.C=!0;this.u=this.l=null;this.I=new vd(function(){Mo(e)});No(this)}pa(Lo,ab);p=Lo.prototype;p.isConnected=function(){return this.H};p.wi=function(){return this.s};p.fj=function(a){this.i=a};p.Dh=function(){this.i=null};
699
699
  p.gj=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.title=a};p.ej=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.images=[{url:a}]};p.dj=function(a){this.i||(this.i={});this.i.artist=a;this.i.metadataType=cast.receiver.media.MetadataType.MUSIC_TRACK};
700
700
  p.destroy=function(){var a=this,b,c;return K(function(d){if(1==d.g)return a.j&&(a.j.release(),a.j=null),b=[],a.h&&(b.push(a.h.destroy()),a.h=null),a.I&&(a.I.stop(),a.I=null),a.g=null,a.J=null,a.G=null,a.H=!1,a.s=!0,a.l=null,a.u=null,ab.prototype.release.call(a),D(d,Promise.all(b),2);c=cast.receiver.CastReceiverManager.getInstance();c.stop();F(d)})};
701
701
  function No(a){var b=cast.receiver.CastReceiverManager.getInstance();b.onSenderConnected=function(){return Oo(a)};b.onSenderDisconnected=function(){return Oo(a)};b.onSystemVolumeChanged=function(){var e=cast.receiver.CastReceiverManager.getInstance().getSystemVolume();e&&Po(a,{type:"update",update:{video:{volume:e.level,muted:e.muted}}},a.l);Po(a,{type:"event",targetName:"video",event:{type:"volumechange"}},a.l)};a.u=b.getCastMessageBus("urn:x-cast:com.google.cast.media");a.u.onMessage=function(e){return Qo(a,
@@ -736,11 +736,11 @@ function eq(a,b){var c=[];try{for(;b.wa();){var d=Tp(b).value,e=(d&224)>>5,f=d&3
736
736
  0,v=1;16>v;v++,u++)q.i[u]=q.i[v];for(v=0;1>v;v++,u++)q.i[u]=Kp()}else r.h++;r.g=0;break;case 14:r.isVisible()&&(e=Np(r,q,g.i));r.i[r.h]=Kp();r.g=0;break;case 12:r.isVisible()&&(e=Np(r,q,g.i)),Jp(r),q=r,q.h=0,q.g=0}var y=e}else y=null}else if(128<=l&&159>=l)y=Vp(g,e,l,m);else{if(4096<=l&&4127>=l)q=l&255,8<=q&&15>=q?e.skip(1):16<=q&&23>=q?e.skip(2):24<=q&&31>=q&&e.skip(3);else if(4224<=l&&4255>=l)q=l&255,128<=q&&135>=q?e.skip(4):136<=q&&143>=q&&e.skip(5);else if(32<=l&&127>=l)e=l,g.g&&(127===e?Lp(g.g,
737
737
  "\u266a"):Lp(g.g,String.fromCharCode(e)));else if(160<=l&&255>=l)g.g&&Lp(g.g,String.fromCharCode(l));else if(4128<=l&&4223>=l){if(e=l&255,g.g)if(aq.has(e)){var z=aq.get(e);Lp(g.g,z)}else Lp(g.g,"_")}else 4256<=l&&4351>=l&&g.g&&(160!=(l&255)?Lp(g.g,"_"):Lp(g.g,"[CC]"));y=null}(e=y)&&c.push(e)}}}}catch(x){if(x instanceof P&&3E3===x.code)Ta("CEA708_INVALID_DATA","Buffer read out of bounds / invalid CEA-708 Data.");else throw x;}return c}function fq(a){for(var b=0;a;)b^=a&1,a>>=1;return 1===b}
738
738
  bq.prototype.getStreams=function(){return Array.from(this.C)};M("shaka.cea.CeaDecoder",bq);tc=function(){return new bq};function gq(a){for(var b=[],c=a,d=a=0;d<c.length;)2==a&&3==c[d]?(a=0,c=[].concat(w(c)),c.splice(d,1),c=new Uint8Array(c)):0==c[d]?a++:a=0,d++;a=c;for(d=0;d<a.length;){for(c=0;255==a[d];)c+=255,d++;c+=a[d++];for(var e=0;255==a[d];)e+=255,d++;e+=a[d++];4==c&&b.push(a.subarray(d,d+e));d+=e}return b};function hq(){this.j=new Map;this.i=this.h=0;this.g=iq}
739
- hq.prototype.init=function(a){function b(f){f=f.name;f in jq&&(c.g=jq[f])}var c=this,d=[],e=[];(new Tf).box("moov",Yf).box("mvex",Yf).S("trex",function(f){var g=f.reader;g.skip(4);g.skip(4);f=g.N();g=g.N();c.h=f;c.i=g}).box("trak",Yf).S("tkhd",function(f){f=Zh(f.reader,f.version);d.push(f.trackId)}).box("mdia",Yf).S("mdhd",function(f){f=Xh(f.reader,f.version);e.push(f.timescale)}).box("minf",Yf).box("stbl",Yf).S("stsd",$f).box("avc1",b).box("avc3",b).box("hev1",b).box("hvc1",b).box("dvh1",b).box("dvhe",
739
+ hq.prototype.init=function(a){function b(f){f=f.name;f in jq&&(c.g=jq[f])}var c=this,d=[],e=[];(new Tf).box("moov",Yf).box("mvex",Yf).S("trex",function(f){var g=f.reader;g.skip(4);g.skip(4);f=g.N();g=g.N();c.h=f;c.i=g}).box("trak",Yf).S("tkhd",function(f){f=Zh(f.reader,f.version);d.push(f.trackId)}).box("mdia",Yf).S("mdhd",function(f){f=Wh(f.reader,f.version);e.push(f.timescale)}).box("minf",Yf).box("stbl",Yf).S("stsd",$f).box("avc1",b).box("avc3",b).box("hev1",b).box("hvc1",b).box("dvh1",b).box("dvhe",
740
740
  b).box("encv",ag).box("sinf",Yf).box("frma",function(f){f=bi(f.reader).va;f in jq&&(c.g=jq[f])}).parse(a,!0);if(!d.length||!e.length||d.length!=e.length)throw new P(2,2,2010);this.g==iq&&Sa("Unable to determine bitstream format for CEA parsing!");d.forEach(function(f,g){c.j.set(f,e[g])})};
741
741
  hq.prototype.parse=function(a){var b=this;if(this.g==iq)return[];var c=[],d=this.h,e=this.i,f=0,g=[],h=null,k=9E4;(new Tf).box("moof",function(l){f=l.start;g=[];Yf(l)}).box("traf",Yf).S("trun",function(l){l=Yh(l.reader,l.version,l.flags);g.push(l)}).S("tfhd",function(l){l=Uh(l.reader,l.flags);d=l.Hg||b.h;e=l.Gh||b.i;l=l.trackId;b.j.has(l)&&(k=b.j.get(l))}).S("tfdt",function(l){h=Vh(l.reader,l.version).baseMediaDecodeTime}).box("mdat",function(l){if(null===h)throw Sa("Unable to find base media decode time for CEA captions!"),
742
742
  new P(2,2,2010);kq(b,l.reader,h,k,d,e,f-l.start-8,g,c)}).parse(a,!1);return c};
743
- function kq(a,b,c,d,e,f,g,h,k){var l=0,m=f,n=h.map(function(u){return u.bh});n=[].concat.apply([],w(n));n.length&&(m=n[0].sampleSize||f);for(b.skip(g+h[0].Fh);b.wa();){g=b.N();var q=b.oa(),r=null;r=!1;h=1;switch(a.g){case lq:r=q&31;r=6==r;break;case mq:h=2;b.skip(1);r=q>>1&63;r=39==r||40==r;break;default:return}if(r)for(q=0,l<n.length&&(q=n[l].De||0),q=(c+q)/d,h=t(gq(b.Ob(g-h))),r=h.next();!r.done;r=h.next())k.push({packet:r.value,pts:q});else try{b.skip(g-h)}catch(u){break}m-=g+4;0==m&&(c=l<n.length?
743
+ function kq(a,b,c,d,e,f,g,h,k){var l=0,m=f,n=h.map(function(u){return u.bh});n=[].concat.apply([],w(n));n.length&&(m=n[0].sampleSize||f);for(b.skip(g+h[0].Fh);b.wa();){g=b.N();var q=b.oa(),r=null;r=!1;h=1;switch(a.g){case lq:r=q&31;r=6==r;break;case mq:h=2;b.skip(1);r=q>>1&63;r=39==r||40==r;break;default:return}if(r)for(q=0,l<n.length&&(q=n[l].De||0),q=(c+q)/d,h=t(gq(b.Qb(g-h))),r=h.next();!r.done;r=h.next())k.push({packet:r.value,pts:q});else try{b.skip(g-h)}catch(u){break}m-=g+4;0==m&&(c=l<n.length?
744
744
  c+(n[l].$f||e):c+e,l++,l<n.length?m=n[l].sampleSize||f:m=f)}}M("shaka.cea.Mp4CeaParser",hq);var iq=0,lq=1,mq=2,jq={avc1:lq,avc3:lq,hev1:mq,hvc1:mq,dvh1:mq,dvhe:mq};sc["video/mp4"]=function(){return new hq};function nq(){}nq.prototype.init=function(){};nq.prototype.parse=function(a){var b=[];a=lc(a);if(!si(a))return b;a=(new mi).parse(a);var c=a.pd(),d=a.ee();a=[];switch(c.video){case "avc":a.push(6);break;case "hvc":a.push(39),a.push(40)}if(!a.length)return b;c=t(d);for(d=c.next();!d.done;d=c.next())if(d=d.value,a.includes(d.type)&&null!=d.time)for(var e=t(gq(d.data)),f=e.next();!f.done;f=e.next())b.push({packet:f.value,pts:d.time});return b};M("shaka.cea.TsCeaParser",nq);sc["video/mp2t"]=function(){return new nq};function oq(a,b,c){var d=pq(a),e=null;a=[];var f=[],g=null,h=new Set(d.map(function(k){return k.keyId}));h.delete(null);if(1<h.size)throw new P(2,4,4010);if(!b){f=d.filter(function(k){return"urn:mpeg:dash:sea:2012"==k.Ed});if(1<f.length)throw new P(2,4,4050);f.length&&(g=qq(f[0]));f=d.filter(function(k){return"urn:mpeg:dash:mp4protection:2011"==k.Ed?(e=k.init||e,!1):"urn:mpeg:dash:sea:2012"!=k.Ed});f.length&&(a=rq(e,f,c,h),0==a.length&&(a=[Db("",e)]))}if(d.length&&!g&&(b||!f.length))for(a=[],b=t(Object.values(c)),
745
745
  c=b.next();!c.done;c=b.next())c=c.value,"org.w3.clearkey"!=c&&a.push(Db(c,e));if(h=Array.from(h)[0]||null)for(b=t(a),c=b.next();!c.done;c=b.next())for(c=t(c.value.initData),d=c.next();!d.done;d=c.next())d.value.keyId=h;return{Gg:h,hk:e,drmInfos:a,Xe:g,Kg:!0}}
746
746
  function sq(a,b,c,d){var e=oq(a,c,d);if(b.Kg){a=1==b.drmInfos.length&&!b.drmInfos[0].keySystem;c=0==e.drmInfos.length;if(0==b.drmInfos.length||a&&!c)b.drmInfos=e.drmInfos;b.Kg=!1}else if(0<e.drmInfos.length&&(b.drmInfos=b.drmInfos.filter(function(f){return e.drmInfos.some(function(g){return g.keySystem==f.keySystem})}),0==b.drmInfos.length))throw new P(2,4,4008);return e.Gg||b.Gg}
@@ -756,7 +756,7 @@ var wq=1,xq=(new Map).set("com.widevine.alpha",function(a){var b=og(a.node,"http
756
756
  b.textContent:(a=og(a.node,"http://dashif.org/guidelines/clearKey","Laurl"))&&"EME-1.0"===a.getAttribute("Lic_type")&&a.textContent?a.textContent:""});function zq(a,b,c,d,e,f){var g={RepresentationID:b,Number:c,SubNumber:d,Bandwidth:e,Time:f};return a.replace(/\$(RepresentationID|Number|SubNumber|Bandwidth|Time)?(?:%0([0-9]+)([diouxX]))?\$/g,function(h,k,l,m){if("$$"==h)return"$";var n=g[k];if(null==n)return h;"RepresentationID"==k&&l&&(l=void 0);"Time"==k&&"bigint"!=typeof n&&(.2<=Math.abs(n-Math.round(n))&&Sa("Calculated $Time$ values must be close to integers"),n=Math.round(n));switch(m){case void 0:case "d":case "i":case "u":h=n.toString();
757
757
  break;case "o":h=n.toString(8);break;case "x":h=n.toString(16);break;case "X":h=n.toString(16).toUpperCase();break;default:h=n.toString()}l=window.parseInt(l,10)||1;return Array(Math.max(0,l-h.length)+1).join("0")+h})}
758
758
  function Aq(a,b){var c=Bq(a,b,"timescale"),d=1;c&&(d=Ag(c)||1);var e=Bq(a,b,"duration");c=Ag(e||"");"image"==a.O.contentType&&(c=Cg(e||""));c&&(c/=d);var f=Bq(a,b,"startNumber");e=Number(Bq(a,b,"presentationTimeOffset"))||0;var g=Bg(f||"");if(null==f||null==g)g=1;var h=Cq(a,b,"SegmentTimeline");b=null;if(h){b=d;a=a.ia.duration||Infinity;f=g;h=ng(h,"S");for(var k=[],l=-e,m=0;m<h.length;++m){var n=h[m],q=h[m+1],r=vg(n,"t",Bg),u=vg(n,"d",Bg),v=vg(n,"r",zg);n=vg(n,"k",zg)||0;null!=r&&(r-=e);if(!u)break;
759
- r=null!=r?r:l;v=v||0;if(0>v)if(q){q=vg(q,"t",Bg);if(null==q)break;else if(r>=q)break;v=Math.ceil((q-r)/u)-1}else{if(Infinity==a)break;else if(r/b>=a)break;v=Math.ceil((a*b-r)/u)-1}0<k.length&&r!=l&&(k[k.length-1].end=r/b);for(q=0;q<=v;++q)l=r+u,k.push({start:r/b,end:l/b,ug:r,zb:n,bj:k.length+f}),r=l}b=k}return{timescale:d,Oa:c,Id:g,Pb:e/d||0,sg:e,timeline:b}}function Dq(a,b){return[b(a.O),b(a.Ca),b(a.Ia)].filter(td)}
759
+ r=null!=r?r:l;v=v||0;if(0>v)if(q){q=vg(q,"t",Bg);if(null==q)break;else if(r>=q)break;v=Math.ceil((q-r)/u)-1}else{if(Infinity==a)break;else if(r/b>=a)break;v=Math.ceil((a*b-r)/u)-1}0<k.length&&r!=l&&(k[k.length-1].end=r/b);for(q=0;q<=v;++q)l=r+u,k.push({start:r/b,end:l/b,ug:r,zb:n,bj:k.length+f}),r=l}b=k}return{timescale:d,Oa:c,Id:g,Rb:e/d||0,sg:e,timeline:b}}function Dq(a,b){return[b(a.O),b(a.Ca),b(a.Ia)].filter(td)}
760
760
  function Bq(a,b,c){b=Dq(a,b);a=null;b=t(b);for(var d=b.next();!d.done&&!(a=d.value.getAttribute(c));d=b.next());return a}function Cq(a,b,c){b=Dq(a,b);a=null;b=t(b);for(var d=b.next();!d.done&&!(a=mg(d.value,c));d=b.next());return a}
761
761
  function Eq(a,b,c,d,e,f){for(var g=rg(a,"http://www.w3.org/1999/xlink","href"),h=rg(a,"http://www.w3.org/1999/xlink","actuate")||"onRequest",k=t(Array.from(a.attributes)),l=k.next();!l.done;l=k.next())l=l.value,"http://www.w3.org/1999/xlink"==l.namespaceURI&&a.removeAttributeNS(l.namespaceURI,l.localName);if(5<=f)return bf(new P(2,4,4028));if("onLoad"!=h)return bf(new P(2,4,4027));var m=Cb([d],[g]);return e.request(0,qf(m,b)).Da(function(n){n=Hg(n.data,a.tagName);if(!n)return bf(new P(2,4,4001,g));
762
762
  for(;a.childNodes.length;)a.removeChild(a.childNodes[0]);for(;n.childNodes.length;){var q=n.childNodes[0];n.removeChild(q);a.appendChild(q)}n=t(Array.from(n.attributes));for(q=n.next();!q.done;q=n.next())a.setAttributeNode(q.value.cloneNode(!1));return Fq(a,b,c,m[0],e,f+1)})}
@@ -767,27 +767,26 @@ d)}function Kq(a){var b=a.g.Ea(),c=a.g.oa();if(0==c)throw new P(2,3,3002);c=8-Ma
767
767
  function Nq(a){if(8<a.g.byteLength)throw new P(2,3,3002);if(8==a.g.byteLength&&a.g.getUint8(0)&224)throw new P(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 Oq(a,b,c,d,e,f,g,h,k){function l(){return e}var m=[];a=new Iq(a.g);for(var n=null,q=null;a.wa();){var r=Jq(a);if(187==r.id){var u=Pq(r);u&&(r=c*u.kj,u=b+u.Ri,null!=n&&m.push(new Fh(n+g,r+g,l,q,u-1,f,g,h,k)),n=r,q=u)}}null!=n&&m.push(new Fh(n+g,d+g,l,q,null,f,g,h,k));return m}
768
768
  function Pq(a){var b=new Iq(a.g);a=Jq(b);if(179!=a.id)throw new P(2,3,3013);a=Nq(a);b=Jq(b);if(183!=b.id)throw new P(2,3,3012);b=new Iq(b.g);for(var c=0;b.wa();){var d=Jq(b);if(241==d.id){c=Nq(d);break}}return{kj:a,Ri:c}};function Qq(a,b,c){b=Cq(a,b,"Initialization");if(!b)return null;var d=a.O.xb(),e=b.getAttribute("sourceURL");e&&(d=Cb(d,[e]));e=0;var f=null;if(b=vg(b,"range",yg))e=b.start,f=b.end;return new Dh(function(){return d},e,f,Rq(a),null,null,c)}
769
769
  function Sq(a,b,c){var d=Number(Bq(a,Tq,"presentationTimeOffset"))||0,e=Bq(a,Tq,"timescale"),f=1;e&&(f=Ag(e)||1);var g=d/f||0,h=Qq(a,Tq,c);Uq(a,h);var k=jf(a);return{Ec:function(){var l=Cq(k,Tq,"RepresentationIndex");var m=k.O.xb();l&&(l=l.getAttribute("sourceURL"))&&(m=Cb(m,[l]));l=Vq(k);return Wq(k,b,h,m,l.start,l.end,g)}}}
770
- function Wq(a,b,c,d,e,f,g){var h,k,l,m,n,q,r,u,v,y,z,x,A,B,C;return K(function(E){if(1==E.g)return h=a.presentationTimeline,k=!a.Vb||!a.ia.Ef,l=a.ia.start,m=a.ia.duration,n=a.O.mimeType.split("/")[1],q=b,r=null,u=[q(d,e,f,!1),"webm"==n?q(c.aa(),c.gb,c.Ma,!0):null],q=null,D(E,Promise.all(u),2);v=E.h;y=v[0];z=v[1]||null;x=null;A=l-g;B=l;C=m?l+m:Infinity;if("mp4"==n)var H=Gq(y,e,d,c,A,B,C);else{H=new Iq(z);if(440786851!=Jq(H).id)throw new P(2,3,3008);var G=Jq(H);if(408125543!=G.id)throw new P(2,3,3009);
770
+ function Wq(a,b,c,d,e,f,g){var h,k,l,m,n,q,r,u,v,y,z,x,A,B,C;return K(function(E){if(1==E.g)return h=a.presentationTimeline,k=!a.Xb||!a.ia.Ef,l=a.ia.start,m=a.ia.duration,n=a.O.mimeType.split("/")[1],q=b,r=null,u=[q(d,e,f,!1),"webm"==n?q(c.aa(),c.gb,c.Ma,!0):null],q=null,D(E,Promise.all(u),2);v=E.h;y=v[0];z=v[1]||null;x=null;A=l-g;B=l;C=m?l+m:Infinity;if("mp4"==n)var H=Gq(y,e,d,c,A,B,C);else{H=new Iq(z);if(440786851!=Jq(H).id)throw new P(2,3,3008);var G=Jq(H);if(408125543!=G.id)throw new P(2,3,3009);
771
771
  H=G.g.byteOffset;G=new Iq(G.g);for(var I=null;G.wa();){var J=Jq(G);if(357149030==J.id){I=J;break}}if(!I)throw new P(2,3,3010);I=new Iq(I.g);J=1E6;for(G=null;I.wa();){var L=Jq(I);if(2807729==L.id)J=Nq(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 P(2,3,3003);}if(null==G)throw new P(2,3,3011);I=J/1E9;G*=I;J=Jq(new Iq(y));if(475249515!=J.id)throw new P(2,3,3007);H=Oq(J,H,I,G,d,c,A,B,C)}x=H;h.yd(x);r=new Fj(x);k&&r.Cc(B,C,
772
772
  !0);return E.return(r)})}function Tq(a){return a.Gd}function Vq(a){var b=Cq(a,Tq,"RepresentationIndex");a=Bq(a,Tq,"indexRange");a=yg(a||"");b&&(a=vg(b,"range",yg,a));return a}function Uq(a,b){Xq(a,b);if(!Vq(a))throw new P(2,4,4002);}function Xq(a,b){var c=a.O.mimeType.split("/")[1];if(a.O.contentType!=Jb&&"mp4"!=c&&"webm"!=c)throw new P(2,4,4006);if("webm"==c&&!b)throw new P(2,4,4005);}
773
- function Rq(a){var b=a.O;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.xe,pixelAspectRatio:b.pixelAspectRatio||null,width:b.width||null}};function Yq(a,b,c){var d=Qq(a,Zq,c),e=$q(a);if(!e.Oa&&!e.timeline&&1<e.Nc.length)throw new P(2,4,4002);if(!e.Oa&&!a.ia.duration&&!e.timeline&&1==e.Nc.length)throw new P(2,4,4002);if(e.timeline&&0==e.timeline.length)throw new P(2,4,4002);var f=null,g=null;a.Ia.id&&a.O.id&&(g=b[a.Ia.id+","+a.O.id])&&(f=g.segmentIndex);var h=ar(a.ia.start,a.ia.duration,a.O.xb,e,d,c);b=!f;f?f.xd(h,a.presentationTimeline.yb()):f=new Fj(h);a.presentationTimeline.yd(h);a.Vb&&a.ia.Ef||f.Cc(a.ia.start,a.ia.duration?a.ia.start+
774
- a.ia.duration:Infinity,b);g&&(g.segmentIndex=f);return{Ec:function(){f&&0!=f.lc()||f.se(h);return Promise.resolve(f)}}}function Zq(a){return a.bc}function $q(a){var b=br(a);a=Aq(a,Zq);var c=a.Id;0==c&&(c=1);var d=0;a.Oa?d=a.Oa*(c-1):a.timeline&&0<a.timeline.length&&(d=a.timeline[0].start);return{Oa:a.Oa,startTime:d,Id:c,Pb:a.Pb,timeline:a.timeline,Nc:b}}
775
- function ar(a,b,c,d,e,f){var g=d.Nc.length;d.timeline&&d.timeline.length!=d.Nc.length&&(g=Math.min(d.timeline.length,d.Nc.length));for(var h=a-d.Pb,k=b?a+b:Infinity,l=[],m=d.startTime,n={},q=0;q<g;n={fd:n.fd,bd:n.bd},q++){n.bd=d.Nc[q];var r=void 0;r=null!=d.Oa?m+d.Oa:d.timeline?d.timeline[q].end:m+b;n.fd=null;l.push(new Fh(a+m,a+r,function(u){return function(){null==u.fd&&(u.fd=Cb(c(),[u.bd.Ji]));return u.fd}}(n),n.bd.start,n.bd.end,e,h,a,k,[],"",null,null,Gh,f));m=r}return l}
776
- function br(a){return[a.O.bc,a.Ca.bc,a.Ia.bc].filter(td).map(function(b){return ng(b,"SegmentURL")}).reduce(function(b,c){return 0<b.length?b:c}).map(function(b){b.getAttribute("indexRange")&&!a.Qg&&(a.Qg=!0);var c=b.getAttribute("media");b=vg(b,"mediaRange",yg,{start:0,end:null});return{Ji:c,start:b.start,end:b.end}})};function cr(a,b,c,d,e,f,g){var h=dr(a,g),k=er(a);fr(k);var l=jf(a);if(k.ud)return Xq(a,h),{Ec:function(){var u=zq(k.ud,l.O.id,null,null,l.bandwidth||null,null);u=Cb(l.O.xb(),[u]);return Wq(l,b,h,u,0,null,k.Pb)}};if(k.Oa)return d||"image"===a.Ca.contentType||(a.presentationTimeline.Pf(k.Oa),a.presentationTimeline.we(a.ia.start)),{Ec:function(){return gr(l,k,e,h,f,g)}};var m=null;d=d=null;a.Ia.id&&a.O.id&&(d=a.Ia.id+","+a.O.id,d=c[d])&&(m=d.segmentIndex);var n=a.ia.start,q=a.ia.duration?n+a.ia.duration:
777
- Infinity,r=!(a.Vb&&a.ia.Ef);m?(c=m,hr(c,k,n,q,r,h),c.wb(a.presentationTimeline.yb())):m=new ir(k,a.O.id,a.bandwidth,a.O.xb,n,q,h,r,g,a.O.ag);k.timeline&&"image"!==a.Ca.contentType&&a.presentationTimeline.Yg(k.timeline,n);d&&a.Vb&&(d.segmentIndex=m);return{Ec:function(){m instanceof ir&&0==m.lc()&&hr(m,k,n,q,r,h);return Promise.resolve(m)}}}function jr(a){return a.Hd}
778
- function er(a){var b=Aq(a,jr),c=Bq(a,jr,"media");a=Bq(a,jr,"index");return{Oa:b.Oa,timescale:b.timescale,Id:b.Id,Pb:b.Pb,sg:b.sg,timeline:b.timeline,Oc:c,ud:a}}function fr(a){var b=a.ud?1:0;b+=a.timeline?1:0;b+=a.Oa?1:0;if(0==b)throw new P(2,4,4002);1!=b&&(a.ud&&(a.timeline=null),a.Oa=null);if(!a.ud&&!a.Oc)throw new P(2,4,4002);}
779
- function gr(a,b,c,d,e,f){function g(J){var L=(J-u)*r,N=L+b.Pb,R=L+m;L=R+r;var T=Math.min(L,k());R=new Fh(R,T,function(){var ea=N*v;"BigInt"in window&&ea>Number.MAX_SAFE_INTEGER&&(ea=BigInt(N)*BigInt(v));ea=zq(y,x,J,null,z,ea);return Cb(A(),[ea])},0,null,d,B,m,k(),[],"",null,null,Gh,f);R.i=L;return R}function h(){var J=[Math.max(l.yb(),m),Math.min(l.Yb(),k())].map(function(L){return L-m});return[Math.ceil(J[0]/r),Math.ceil(J[1]/r)-1].map(function(L){return L+u})}function k(){var J=null!=n&&e[n]||q;
780
- return J?m+J:Infinity}var l=a.presentationTimeline,m=a.ia.start,n=a.Ia.id,q=a.ia.duration,r=b.Oa,u=b.Id,v=b.timescale,y=b.Oc,z=a.bandwidth||null,x=a.O.id,A=a.O.xb,B=m-b.Pb,C=h();a=a.Vb?Math.max(C[0],C[1]-c+1):C[0];C=C[1];c=[];for(var E=a;E<=C;++E){var H=g(E);c.push(H)}var G=new Fj(c);c=l.Yb()<k();E=l.R();if(c||E){var I=Math.max(a,C+1);G.Je(r,function(){var J=l.yb();G.wb(J);var L=t(h());L.next();L=L.next().value;for(var N=[];I<=L;){var R=g(I);N.push(R);I++}return J>k()&&!N.length?null:N})}return Promise.resolve(G)}
781
- function dr(a,b){var c=Bq(a,jr,"initialization");if(!c)return null;var d=a.O.id,e=a.bandwidth||null,f=a.O.xb;return new Dh(function(){var g=zq(c,d,null,null,e,null);return Cb(f(),[g])},0,null,Rq(a),null,null,b)}function ir(a,b,c,d,e,f,g,h,k,l){Fj.call(this,[]);this.h=a;this.H=b;this.D=c;this.G=d;this.i=e;this.m=f;this.u=g;this.C=k;this.I=l;h&&kr(this)}pa(ir,Fj);p=ir.prototype;p.lc=function(){return this.h?this.h.timeline.length:0};p.release=function(){Fj.prototype.release.call(this);this.h=null};
782
- p.wb=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.lc()&&this.release())}};function hr(a,b,c,d,e,f){a.u=f;if(a.h){c=a.h.timeline;a.h.Oc=b.Oc;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&&kr(a)}
783
- function kr(a){if(!a.s){for(var b=a.h.timeline;b.length;)if(b[b.length-1].start>=a.m)b.pop();else break;a.wb(a.i);0!==b.length&&Infinity!==a.m&&(b[b.length-1].end=a.m-a.i)}}
784
- p.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};
785
- p.get=function(a){var b=this;a-=this.j;if(0>a||a>=this.lc()||!this.h)return null;var c=this.g[a];if(!c){var d=this.h.Oc,e=this.h.timeline[a],f=e.bj,g=this.h.sg+e.ug;c=this.i-this.h.Pb;for(var h=[],k=(e.end-e.start)/e.zb,l={},m=0;m<e.zb;l={gd:l.gd,Te:l.Te},m++){var n=e.start+k*m,q=n+k;l.Te=m+1;l.gd=null;n=new Fh(this.i+n,this.i+q,function(r){return function(){if(!b.h)return[];null==r.gd&&(r.gd=lr(b.h.Oc,b.H,f,b.D,g,r.Te,b.G));return r.gd}}(l),0,null,this.u,c,this.i,this.m,[],"",null,null,Gh,this.C);
786
- 0==this.I?0<m&&n.qe():0!=m%this.I&&n.qe();h.push(n)}c=new Fh(this.i+e.start,this.i+e.end,function(){return 0<e.zb?[]:lr(d,b.H,f,b.D,g,null,b.G)},0,null,this.u,c,this.i,this.m,h,"",null,null,Gh,this.C,0<e.zb);this.g[a]=c}return c};function lr(a,b,c,d,e,f,g){a=zq(a,b,c,f,d||null,e);return Cb(g(),[a]).map(function(h){return h.toString()})};function mr(a){this.s=null;this.C=a;this.I=new kf;this.j=[];this.h=null;this.m=[];this.D=null;this.H=[];this.G=300;this.l=new Map;this.i=new Map;this.g=null;this.u="UNKNOWN"}mr.prototype.configure=function(a){this.s=a};mr.prototype.destroy=function(){this.C=this.s=null;this.j=[];this.h=null;this.m=[];this.H=[];this.l.clear();null!=this.g&&(this.g.stop(),this.g=null);return this.I.destroy()};mr.prototype.setManifestType=function(a){this.u=a};
773
+ function Rq(a){var b=a.O;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.xe,pixelAspectRatio:b.pixelAspectRatio||null,width:b.width||null}};function Yq(a,b,c){var d=Qq(a,Zq,c),e=$q(a);if(!e.Oa&&!e.timeline&&1<e.Nc.length)throw new P(2,4,4002);if(!e.Oa&&!a.ia.duration&&!e.timeline&&1==e.Nc.length)throw new P(2,4,4002);if(e.timeline&&0==e.timeline.length)throw new P(2,4,4002);var f=null,g=null;a.Ia.id&&a.O.id&&(g=b[a.Ia.id+","+a.O.id])&&(f=g.segmentIndex);var h=ar(a.ia.start,a.ia.duration,a.O.xb,e,d,c);b=!f;f?f.xd(h,a.presentationTimeline.yb()):f=new Fj(h);a.presentationTimeline.yd(h);a.Xb&&a.ia.Ef||f.Cc(a.ia.start,a.ia.duration?a.ia.start+
774
+ a.ia.duration:Infinity,b);g&&(g.segmentIndex=f);return{Ec:function(){f&&0!=f.Zb()||f.se(h);return Promise.resolve(f)}}}function Zq(a){return a.cc}function $q(a){var b=br(a);a=Aq(a,Zq);var c=a.Id;0==c&&(c=1);var d=0;a.Oa?d=a.Oa*(c-1):a.timeline&&0<a.timeline.length&&(d=a.timeline[0].start);return{Oa:a.Oa,startTime:d,Id:c,Rb:a.Rb,timeline:a.timeline,Nc:b}}
775
+ function ar(a,b,c,d,e,f){var g=d.Nc.length;d.timeline&&d.timeline.length!=d.Nc.length&&(g=Math.min(d.timeline.length,d.Nc.length));for(var h=a-d.Rb,k=b?a+b:Infinity,l=[],m=d.startTime,n={},q=0;q<g;n={fd:n.fd,bd:n.bd},q++){n.bd=d.Nc[q];var r=void 0;r=null!=d.Oa?m+d.Oa:d.timeline?d.timeline[q].end:m+b;n.fd=null;l.push(new Fh(a+m,a+r,function(u){return function(){null==u.fd&&(u.fd=Cb(c(),[u.bd.Ji]));return u.fd}}(n),n.bd.start,n.bd.end,e,h,a,k,[],"",null,null,Gh,f));m=r}return l}
776
+ function br(a){return[a.O.cc,a.Ca.cc,a.Ia.cc].filter(td).map(function(b){return ng(b,"SegmentURL")}).reduce(function(b,c){return 0<b.length?b:c}).map(function(b){b.getAttribute("indexRange")&&!a.Qg&&(a.Qg=!0);var c=b.getAttribute("media");b=vg(b,"mediaRange",yg,{start:0,end:null});return{Ji:c,start:b.start,end:b.end}})};function cr(a,b,c,d,e,f,g){var h=dr(a,g),k=er(a);fr(k);var l=jf(a);if(k.ud)return Xq(a,h),{Ec:function(){var u=zq(k.ud,l.O.id,null,null,l.bandwidth||null,null);u=Cb(l.O.xb(),[u]);return Wq(l,b,h,u,0,null,k.Rb)}};if(k.Oa)return d||"image"===a.Ca.contentType||(a.presentationTimeline.Pf(k.Oa),a.presentationTimeline.we(a.ia.start)),{Ec:function(){return gr(l,k,e,h,f,g)}};var m=null;d=d=null;a.Ia.id&&a.O.id&&(d=a.Ia.id+","+a.O.id,d=c[d])&&(m=d.segmentIndex);var n=a.ia.start,q=a.ia.duration?n+a.ia.duration:
777
+ Infinity,r=!(a.Xb&&a.ia.Ef);m?(c=m,hr(c,k,n,q,r,h),c.wb(a.presentationTimeline.yb())):m=new ir(k,a.O.id,a.bandwidth,a.O.xb,n,q,h,r,g,a.O.ag);k.timeline&&"image"!==a.Ca.contentType&&a.presentationTimeline.Yg(k.timeline,n);d&&a.Xb&&(d.segmentIndex=m);return{Ec:function(){m instanceof ir&&0==m.Zb()&&hr(m,k,n,q,r,h);return Promise.resolve(m)}}}function jr(a){return a.Hd}
778
+ function er(a){var b=Aq(a,jr),c=Bq(a,jr,"media");a=Bq(a,jr,"index");return{Oa:b.Oa,timescale:b.timescale,Id:b.Id,Rb:b.Rb,sg:b.sg,timeline:b.timeline,Oc:c,ud:a}}function fr(a){var b=a.ud?1:0;b+=a.timeline?1:0;b+=a.Oa?1:0;if(0==b)throw new P(2,4,4002);1!=b&&(a.ud&&(a.timeline=null),a.Oa=null);if(!a.ud&&!a.Oc)throw new P(2,4,4002);}
779
+ function gr(a,b,c,d,e,f){function g(J){var L=(J-u)*r,N=L+b.Rb,R=L+m;L=R+r;var T=Math.min(L,k());R=new Fh(R,T,function(){var ea=N*v;"BigInt"in window&&ea>Number.MAX_SAFE_INTEGER&&(ea=BigInt(N)*BigInt(v));ea=zq(y,x,J,null,z,ea);return Cb(A(),[ea])},0,null,d,B,m,k(),[],"",null,null,Gh,f);R.i=L;return R}function h(){var J=[Math.max(l.yb(),m),Math.min(l.$b(),k())].map(function(L){return L-m});return[Math.ceil(J[0]/r),Math.ceil(J[1]/r)-1].map(function(L){return L+u})}function k(){var J=null!=n&&e[n]||q;
780
+ return J?m+J:Infinity}var l=a.presentationTimeline,m=a.ia.start,n=a.Ia.id,q=a.ia.duration,r=b.Oa,u=b.Id,v=b.timescale,y=b.Oc,z=a.bandwidth||null,x=a.O.id,A=a.O.xb,B=m-b.Rb,C=h();a=a.Xb?Math.max(C[0],C[1]-c+1):C[0];C=C[1];c=[];for(var E=a;E<=C;++E){var H=g(E);c.push(H)}var G=new Fj(c);c=l.$b()<k();E=l.R();if(c||E){var I=Math.max(a,C+1);G.Je(r,function(){var J=l.yb();G.wb(J);var L=t(h());L.next();L=L.next().value;for(var N=[];I<=L;){var R=g(I);N.push(R);I++}return J>k()&&!N.length?null:N})}return Promise.resolve(G)}
781
+ function dr(a,b){var c=Bq(a,jr,"initialization");if(!c)return null;var d=a.O.id,e=a.bandwidth||null,f=a.O.xb;return new Dh(function(){var g=zq(c,d,null,null,e,null);return Cb(f(),[g])},0,null,Rq(a),null,null,b)}function ir(a,b,c,d,e,f,g,h,k,l){Fj.call(this,[]);this.h=a;this.H=b;this.D=c;this.G=d;this.i=e;this.l=f;this.u=g;this.C=k;this.I=l;h&&kr(this)}pa(ir,Fj);p=ir.prototype;p.Zb=function(){return this.h?this.h.timeline.length:0};p.release=function(){Fj.prototype.release.call(this);this.h=null};
782
+ p.wb=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.Zb()&&this.release())}};function hr(a,b,c,d,e,f){a.u=f;if(a.h){c=a.h.timeline;a.h.Oc=b.Oc;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.l!==d&&(a.l=d)}else a.h=b,a.i=c,a.l=d;e&&kr(a)}
783
+ function kr(a){if(!a.s){for(var b=a.h.timeline;b.length;)if(b[b.length-1].start>=a.l)b.pop();else break;a.wb(a.i)}}p.find=function(a){if(this.h&&this.h.timeline&&this.h.timeline.length&&a<this.h.timeline[0].start+this.i)return this.j;if(!this.h)return null;var b=this.h.timeline;if(a<this.i||a>=this.l)return null;for(var c=b.length-1,d=0;d<b.length;d++){var e=b[d],f=e.start+this.i;e=d<c?b[d+1].start+this.i:Infinity===this.l?e.end+this.i:this.l;if(a>=f&&a<e)return d+this.j}return null};
784
+ p.get=function(a){var b=this;a-=this.j;if(0>a||a>=this.Zb()||!this.h)return null;var c=this.g[a];if(!c){var d=this.h.Oc,e=this.h.timeline[a],f=e.bj,g=this.h.sg+e.ug;c=this.i-this.h.Rb;var h=this.i+e.end,k=h;a===this.Zb()-1&&Infinity!==this.l&&(k=this.l);for(var l=[],m=(e.end-e.start)/e.zb,n={},q=0;q<e.zb;n={gd:n.gd,Te:n.Te},q++){var r=e.start+m*q,u=r+m;n.Te=q+1;n.gd=null;r=new Fh(this.i+r,this.i+u,function(v){return function(){if(!b.h)return[];null==v.gd&&(v.gd=lr(b.h.Oc,b.H,f,b.D,g,v.Te,b.G));return v.gd}}(n),
785
+ 0,null,this.u,c,this.i,this.l,[],"",null,null,Gh,this.C);0==this.I?0<q&&r.qe():0!=q%this.I&&r.qe();l.push(r)}c=new Fh(this.i+e.start,k,function(){return 0<e.zb?[]:lr(d,b.H,f,b.D,g,null,b.G)},0,null,this.u,c,this.i,this.l,l,"",null,null,Gh,this.C,0<e.zb);c.i=h;this.g[a]=c}return c};function lr(a,b,c,d,e,f,g){a=zq(a,b,c,f,d||null,e);return Cb(g(),[a]).map(function(h){return h.toString()})};function mr(a){this.s=null;this.C=a;this.I=new kf;this.j=[];this.h=null;this.m=[];this.D=null;this.H=[];this.G=300;this.l=new Map;this.i=new Map;this.g=null;this.u="UNKNOWN"}mr.prototype.configure=function(a){this.s=a};mr.prototype.destroy=function(){this.C=this.s=null;this.j=[];this.h=null;this.m=[];this.H=[];this.l.clear();null!=this.g&&(this.g.stop(),this.g=null);return this.I.destroy()};mr.prototype.setManifestType=function(a){this.u=a};
787
786
  function nr(a,b){var c,d,e,f,g,h,k;return K(function(l){if(1==l.g)return c=Cb(a.j,[or(a,b)]),d=qf(c,a.s.retryParameters),e=a.C.networkingEngine.request(8,d),lf(a.I,e),ta(l,2),D(l,e.promise,4);if(2!=l.g)return f=l.h,g=Kf(f.data),h=JSON.parse(g),1==h.VERSION&&pr(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 vd(function(){nr(a,b)});a.g.T(a.G);F(l)})}
788
787
  function or(a,b){if(!a.m.length)return b;b=new gb(b);var c=a.D||a.m[0],d=Math.round(a.C.getBandwidthEstimate()),e=b.g;"DASH"==a.u?(e.add("_DASH_pathway",c),e.add("_DASH_throughput",String(d))):"HLS"==a.u&&(e.add("_HLS_pathway",c),e.add("_HLS_throughput",String(d)));Ab(e)&&ob(b,e);return b.toString()}function pr(a,b,c){null!=a.g&&(a.g.stop(),a.g=null);var d=b["RELOAD-URI"]||c;a.g=new vd(function(){nr(a,d)});if(c=b.TTL)a.G=c;a.g.T(a.G);a.m=b["PATHWAY-PRIORITY"]||[];a.H=b["PATHWAY-CLONES"]||[]}
789
788
  function qr(a,b,c,d){var e=a.l.get(b);e||(e=new Map);e.set(c,d);a.l.set(b,e)}
790
- function rr(a,b){b=a.l.get(b)||new Map;for(var c=[],d={},e=t(a.m),f=e.next();!f.done;d={fc:d.fc},f=e.next())if(d.fc=f.value,f=b.get(d.fc))c.push({Vf:d.fc,location:f});else if(f=a.H.find(function(h){return function(k){return k.Bj==h.fc}}(d))){var g=b.get(f["BASE-ID"]);g&&(f["URI-REPLACEMENT"].qh?(g=new gb(g),kb(g,f["URI-REPLACEMENT"].qh),c.push({Vf:d.fc,location:g.toString()})):c.push({Vf:d.fc,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&&
789
+ function rr(a,b){b=a.l.get(b)||new Map;for(var c=[],d={},e=t(a.m),f=e.next();!f.done;d={hc:d.hc},f=e.next())if(d.hc=f.value,f=b.get(d.hc))c.push({Vf:d.hc,location:f});else if(f=a.H.find(function(h){return function(k){return k.Bj==h.hc}}(d))){var g=b.get(f["BASE-ID"]);g&&(f["URI-REPLACEMENT"].qh?(g=new gb(g),kb(g,f["URI-REPLACEMENT"].qh),c.push({Vf:d.hc,location:g.toString()})):c.push({Vf:d.hc,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&&
791
790
  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 gb(h.location)).Ib))return!1;return!0});c.length&&(a.D=c[0].Vf);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.D=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 Cb(a.j,c)};function sr(){this.j=[];this.h=[];this.g=[];this.l=[];this.i=[];this.m=new Set}p=sr.prototype;p.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=[]};p.mi=function(){return this.j};p.Bf=function(){return this.l.slice()};p.Vh=function(){return this.i};
792
791
  p.Dg=function(a,b){var c,d,e,f,g=this,h,k,l,m,n,q,r,u,v,y,z,x,A,B,C,E,H,G,I,J,L,N,R,T,ea,Z,fa,Ha,Xa,Gb;return K(function(lb){if(1==lb.g){h=Kb;tr(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,lb.F(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 lb.return();for(var bc=[],za=[],mb=[],hb=[],Hb=t(a),ib=Hb.next();!ib.done;ib=Hb.next())ib=ib.value,bc.push(ib.audioStreams),za.push(ib.videoStreams),
793
792
  mb.push(ib.textStreams),hb.push(ib.imageStreams);c=bc;d=za;e=mb;f=hb;q=c;r=d;u=e;v=f;y=t(u);for(z=y.next();!z.done;z=y.next())x=z.value,x.push(ur(h.za));A=t(v);for(B=A.next();!B.done;B=A.next())C=B.value,C.push(ur(h.jd));return D(lb,Promise.all([vr(g.h,q,l,wr,xr),vr(g.g,r,l,wr,xr),vr(g.l,u,l,wr,xr),vr(g.i,v,l,wr,xr)]),2)}E=0;H=[];if(g.g.length&&g.h.length)for(R=t(g.h),T=R.next();!T.done;T=R.next())for(ea=T.value,Z=t(g.g),fa=Z.next();!fa.done;fa=Z.next())Ha=fa.value,Xa=uh(ea.drmInfos,Ha.drmInfos),
@@ -800,7 +799,7 @@ function zr(a){var b,c,d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B,C,E,H,G,I,J,L;return
800
799
  l=t(f);for(m=l.next();!m.done;m=l.next())n=m.value,n.push(Ar(b.jd));return D(N,vr([],c,0,Br,Cr),2);case 2:return q=N.h,D(N,vr([],d,0,Br,Cr),3);case 3:return r=N.h,D(N,vr([],e,0,Br,Cr),4);case 4:return u=N.h,D(N,vr([],f,0,Br,Cr),5);case 5:v=N.h;y=0;if(r.length&&q.length)for(C=t(q),E=C.next();!E.done;E=C.next())for(H=E.value,G=t(r),I=G.next();!I.done;I=G.next())J=I.value,L=y++,J.variantIds.push(L),H.variantIds.push(L);else for(z=r.concat(q),x=t(z),A=x.next();!A.done;A=x.next())B=A.value,B.variantIds=
801
800
  [y++];return N.return(r.concat(q).concat(u).concat(v))}})}
802
801
  function vr(a,b,c,d,e){var f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B,C,E,H,G,I;return K(function(J){switch(J.g){case 1:f=Kb;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){J.F(4);break}m=l.value;return D(J,Dr(m,b,c,e,g),5);case 5:n=J.h;if(!n)throw new P(2,4,4037);l=k.next();J.F(2);break;case 4:q=t(g);for(r=q.next();!r.done;r=q.next())for(u=r.value,v=t(u),y=v.next();!y.done;y=v.next())z=y.value,(x=Er(z,b,d,e,g))&&a.push(x);A=t(g);for(r=A.next();!r.done;r=
803
- A.next())for(B=r.value,C={},E=t(B),y=E.next();!y.done;C={Tb:C.Tb},y=E.next())if(C.Tb=y.value,H=C.Tb.type==f.za&&!C.Tb.language,G=C.Tb.type==f.jd&&!C.Tb.tilesLayout,!H&&!G&&(I=a.some(function(L){return function(N){return N.mimeType==L.Tb.mimeType&&fd(N.codecs)==fd(L.Tb.codecs)}}(C))))throw new P(2,4,4037);return J.return(a)}})}function Dr(a,b,c,d,e){return K(function(f){if(1==f.g)return Fr(b,a),a.matchedStreams?a.segmentIndex?D(f,Gr(a,c),2):f.F(2):f.return(!1);Hr(a,c,d,e);return f.return(!0)})}
802
+ A.next())for(B=r.value,C={},E=t(B),y=E.next();!y.done;C={Vb:C.Vb},y=E.next())if(C.Vb=y.value,H=C.Vb.type==f.za&&!C.Vb.language,G=C.Vb.type==f.jd&&!C.Vb.tilesLayout,!H&&!G&&(I=a.some(function(L){return function(N){return N.mimeType==L.Vb.mimeType&&fd(N.codecs)==fd(L.Vb.codecs)}}(C))))throw new P(2,4,4037);return J.return(a)}})}function Dr(a,b,c,d,e){return K(function(f){if(1==f.g)return Fr(b,a),a.matchedStreams?a.segmentIndex?D(f,Gr(a,c),2):f.F(2):f.return(!1);Hr(a,c,d,e);return f.return(!0)})}
804
803
  function Gr(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 D(l,Promise.all(c),2)}if(a.segmentIndex instanceof Jj)for(h=b;h<d.length;h++)k=d[h],k.segmentIndex&&a.segmentIndex.h.push(k.segmentIndex);F(l)})}
805
804
  function Er(a,b,c,d,e){var f=c(a);Fr(b,f);f.createSegmentIndex&&(f.createSegmentIndex=function(){return K(function(g){if(f.segmentIndex)return g.F(0);f.segmentIndex=new Jj;return D(g,Gr(f,0),0)})});if(!f.matchedStreams||!f.matchedStreams.length)return null;Hr(f,0,d,e);return f}function Hr(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==Tb(a.language,f.language)&&(g=!1);g&&d[b].delete(f)}}
806
805
  function wr(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,29 +809,29 @@ function xr(a,b){a.roles=Array.from(new Set(a.roles.concat(b.roles)));b.emsgSche
810
809
  function Cr(a,b){a.roles=Array.from(new Set(a.roles.concat(b.roles)));var c=b.keyIds;c=new Set([].concat(w(a.keyIds),w(c)));a.keyIds=c;a.encrypted=a.encrypted&&b.encrypted;a.segments.push.apply(a.segments,w(b.segments));if(b.closedCaptions)for(a.closedCaptions||(a.closedCaptions=new Map),b=t(b.closedCaptions),c=b.next();!c.done;c=b.next()){var d=t(c.value);c=d.next().value;d=d.next().value;a.closedCaptions.set(c,d)}}
811
810
  function Fr(a,b){var c=[];a=t(a);for(var d=a.next();!d.done;d=a.next()){var e=b,f={audio:Ir,video:Ir,text:Jr,image:Kr}[e.type],g={audio:Lr,video:Mr,text:Nr,image:Or}[e.type],h=null;d=t(d.value);for(var k=d.next();!k.done;k=d.next())k=k.value,!f(e,k)||h&&!g(e,h,k)||(h=k);e=h;if(!e)return;c.push(e)}b.matchedStreams=c}
812
811
  function Ir(a,b){function c(d){if(!Pr.has(d)){var e=fd(d);Pr.set(d,e)}return Pr.get(d)}return b.mimeType!=a.mimeType||c(b.codecs)!=c(a.codecs)||a.drmInfos&&!th(a.drmInfos,b.drmInfos)?!1:!0}function Jr(a,b){return a.language?b.language?a.forced!==b.forced||0==Tb(a.language,b.language)||b.kind!=a.kind?!1:!0:!0:!1}function Kr(a){return a.tilesLayout?!0:!1}
813
- function Lr(a,b,c){if(a.id==c.id)return!0;var d=Tb(a.language,b.language),e=Tb(a.language,c.language);if(e>d)return!0;if(e<d)return!1;if(a.roles.length)return d=b.roles.filter(function(f){return a.roles.includes(f)}),e=c.roles.filter(function(f){return a.roles.includes(f)}),e.length>d.length?!0:e.length<d.length?!1:c.roles.length<b.roles.length;if(!c.roles.length&&b.roles.length)return!0;if(c.roles.length&&!b.roles.length)return!1;if(!b.primary&&c.primary)return!0;if(b.primary&&!c.primary)return!1;
814
- d=Qr(a.channelsCount,b.channelsCount,c.channelsCount);if(d==Rr)return!0;if(d==Sr)return!1;d=Qr(a.audioSamplingRate,b.audioSamplingRate,c.audioSamplingRate);return d==Rr?!0:d==Sr?!1:a.bandwidth&&Tr(a.bandwidth,b.bandwidth,c.bandwidth)==Rr?!0:!1}
812
+ function Lr(a,b,c){if(a.id==c.id)return!0;var d=Tb(a.language,b.language),e=Tb(a.language,c.language);if(e>d)return!0;if(e<d)return!1;if(b.label!==c.label){if(a.label===b.label)return!1;if(a.label===c.label)return!0}if(a.roles.length)return d=b.roles.filter(function(f){return a.roles.includes(f)}),e=c.roles.filter(function(f){return a.roles.includes(f)}),e.length>d.length?!0:e.length<d.length?!1:c.roles.length<b.roles.length;if(!c.roles.length&&b.roles.length)return!0;if(c.roles.length&&!b.roles.length)return!1;
813
+ if(!b.primary&&c.primary)return!0;if(b.primary&&!c.primary)return!1;d=Qr(a.channelsCount,b.channelsCount,c.channelsCount);if(d==Rr)return!0;if(d==Sr)return!1;d=Qr(a.audioSamplingRate,b.audioSamplingRate,c.audioSamplingRate);return d==Rr?!0:d==Sr?!1:a.bandwidth&&Tr(a.bandwidth,b.bandwidth,c.bandwidth)==Rr?!0:!1}
815
814
  function Mr(a,b,c){if(a.id==c.id)return!0;var d=Qr(a.width*a.height,b.width*b.height,c.width*c.height);if(d==Rr)return!0;if(d==Sr)return!1;if(a.frameRate){d=Qr(a.frameRate,b.frameRate,c.frameRate);if(d==Rr)return!0;if(d==Sr)return!1}return a.bandwidth&&Tr(a.bandwidth,b.bandwidth,c.bandwidth)==Rr?!0:!1}
816
- function Nr(a,b,c){if(a.id==c.id)return!0;var d=Tb(a.language,b.language),e=Tb(a.language,c.language);if(e>d)return!0;if(e<d)return!1;if(!b.primary&&c.primary)return!0;if(b.primary&&!c.primary)return!1;if(a.roles.length){d=b.roles.filter(function(f){return a.roles.includes(f)});e=c.roles.filter(function(f){return a.roles.includes(f)});if(e.length>d.length)return!0;if(e.length<d.length)return!1}else{if(!c.roles.length&&b.roles.length)return!0;if(c.roles.length&&!b.roles.length)return!1}return c.mimeType!=
817
- a.mimeType||c.codecs!=a.codecs||b.mimeType==a.mimeType&&b.codecs==a.codecs?!1:!0}function Or(a,b,c){return a.id==c.id?!0:Qr(a.width*a.height,b.width*b.height,c.width*c.height)==Rr?!0:!1}
815
+ function Nr(a,b,c){if(a.id==c.id)return!0;var d=Tb(a.language,b.language),e=Tb(a.language,c.language);if(e>d)return!0;if(e<d)return!1;if(!b.primary&&c.primary)return!0;if(b.primary&&!c.primary)return!1;if(b.label!==c.label){if(a.label===b.label)return!1;if(a.label===c.label)return!0}if(a.roles.length){d=b.roles.filter(function(f){return a.roles.includes(f)});e=c.roles.filter(function(f){return a.roles.includes(f)});if(e.length>d.length)return!0;if(e.length<d.length)return!1}else{if(!c.roles.length&&
816
+ b.roles.length)return!0;if(c.roles.length&&!b.roles.length)return!1}return c.mimeType!=a.mimeType||c.codecs!=a.codecs||b.mimeType==a.mimeType&&b.codecs==a.codecs?!1:!0}function Or(a,b,c){return a.id==c.id?!0:Qr(a.width*a.height,b.width*b.height,c.width*c.height)==Rr?!0:!1}
818
817
  function Ar(a){return{id:0,originalId:"",groupId:null,primary:!1,type:a,mimeType:"",codecs:"",language:"",originalLanguage:null,label:null,width:null,height:null,encrypted:!1,keyIds:new Set,segments:[],variantIds:[],roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,external:!1,fastSwitching:!1}}
819
818
  function ur(a){return{id:0,originalId:"",groupId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Fj([]),mimeType:"",codecs:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"",originalLanguage:null,label:null,type:a,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null,accessibilityPurpose:null,external:!1,fastSwitching:!1}}
820
819
  function Qr(a,b,c){if(b==a&&a!=c)return Sr;if(c==a&&a!=b)return Rr;if(b>a){if(c<=a||c-a<b-a)return Rr;if(c-a>b-a)return Sr}else{if(c>a)return Sr;if(a-c<a-b)return Rr;if(a-c>a-b)return Sr}return Ur}function Tr(a,b,c){b=Math.abs(a-b);a=Math.abs(a-c);return a<b?Rr:b<a?Sr:Ur}M("shaka.util.PeriodCombiner",sr);sr.prototype.combinePeriods=sr.prototype.Dg;sr.prototype.getImageStreams=sr.prototype.Vh;sr.prototype.getTextStreams=sr.prototype.Bf;sr.prototype.getVariants=sr.prototype.mi;
821
820
  var Rr=1,Ur=0,Sr=-1,Pr=new Map;function Vr(){var a=this;this.i=this.g=null;this.s=[];this.j=null;this.K=1;this.m={};this.M={};this.l=new sr;this.H=0;this.J=new $b(5);this.I=new vd(function(){Wr(a)});this.G=new kf;this.C=null;this.L=[];this.D=Infinity;this.u=!1;this.h=null}p=Vr.prototype;p.configure=function(a){this.g=a;this.h&&this.h.configure(this.g)};p.start=function(a,b){var c=this,d;return K(function(e){if(1==e.g)return c.u=b.isLowLatencyMode(),c.s=[a],c.i=b,D(e,Xr(c),2);d=e.h;c.i&&Yr(c,d);if(!c.i)throw new P(2,7,7001);return e.return(c.j)})};
822
821
  p.stop=function(){for(var a=t(Object.values(this.m)),b=a.next();!b.done;b=a.next())b=b.value,b.segmentIndex&&b.segmentIndex.release();this.l&&this.l.release();this.g=this.i=null;this.s=[];this.j=null;this.m={};this.l=null;null!=this.I&&(this.I.stop(),this.I=null);this.h&&this.h.destroy();return this.G.destroy()};p.update=function(){var a=this,b;return K(function(c){if(1==c.g)return ta(c,2),D(c,Xr(a),4);if(2!=c.g)return va(c,0);b=wa(c);if(!a.i||!b)return c.return();a.i.onError(b);F(c)})};
823
- p.onExpirationUpdated=function(){};p.onInitialVariantChosen=function(a){if(this.j&&this.j.presentationTimeline.R()){var b=a.video||a.audio;if(b&&b.segmentIndex){a=this.j.presentationTimeline.Yb();var c=b.segmentIndex.find(a);null!=c&&(b=b.segmentIndex.get(c))&&(this.H=b.endTime-a,Yr(this,0))}}};p.banLocation=function(a){this.h&&this.h.i.set(a,Date.now()+6E4)};
822
+ p.onExpirationUpdated=function(){};p.onInitialVariantChosen=function(a){if(this.j&&this.j.presentationTimeline.R()){var b=a.video||a.audio;if(b&&b.segmentIndex){a=this.j.presentationTimeline.$b();var c=b.segmentIndex.find(a);null!=c&&(b=b.segmentIndex.get(c))&&(this.H=b.endTime-a,Yr(this,0))}}};p.banLocation=function(a){this.h&&this.h.i.set(a,Date.now()+6E4)};
824
823
  function Xr(a){var b,c,d,e,f;return K(function(g){if(1==g.g)return b=qf(a.s,a.g.retryParameters),c=Date.now(),D(g,Zr(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.s.includes(d.uri)&&a.s.unshift(d.uri);return D(g,$r(a,d.data,d.uri),3)}e=Date.now();f=(e-c)/1E3;a.J.sample(1,f);return g.return(f)})}
825
824
  function $r(a,b,c){var d,e,f,g,h;return K(function(k){if(1==k.g){d=Hg(b,"MPD");if(!d)throw new P(2,4,4001,c);if(e=a.g.dash.disableXlinkProcessing)return k.return(as(a,d,c));f=a.g.dash.xlinkFailGracefully;g=Fq(d,a.g.retryParameters,f,c,a.i.networkingEngine);lf(a.G,g);return D(k,g.promise,2)}h=k.h;return k.return(as(a,h,c))})}
826
- function as(a,b,c){var d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B,C,E,H,G,I,J,L,N,R,T,ea,Z,fa,Ha,Xa,Gb,lb,bc,za,mb,hb,Hb,ib,Wh,Md,Me,Ne;return K(function(sb){switch(sb.g){case 1:(d=a.g.dash.manifestPreprocessor)&&d(b);e=[c];f=ng(b,"Location").map(tg).filter(td);0<f.length&&(g=Cb(e,f),e=a.s=g);h=Promise.resolve();if((k=mg(b,"ContentSteering"))&&a.i)if(l=k.getAttribute("defaultServiceLocation"),a.h)a.h.j=e,a.h.h=l;else if(a.h=new mr(a.i),a.h.configure(a.g),a.h.setManifestType("DASH"),a.h.j=e,a.h.h=l,m=tg(k))(n=
825
+ function as(a,b,c){var d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B,C,E,H,G,I,J,L,N,R,T,ea,Z,fa,Ha,Xa,Gb,lb,bc,za,mb,hb,Hb,ib,Xh,Md,Oe,Pe;return K(function(sb){switch(sb.g){case 1:(d=a.g.dash.manifestPreprocessor)&&d(b);e=[c];f=ng(b,"Location").map(tg).filter(td);0<f.length&&(g=Cb(e,f),e=a.s=g);h=Promise.resolve();if((k=mg(b,"ContentSteering"))&&a.i)if(l=k.getAttribute("defaultServiceLocation"),a.h)a.h.j=e,a.h.h=l;else if(a.h=new mr(a.i),a.h.configure(a.g),a.h.setManifestType("DASH"),a.h.j=e,a.h.h=l,m=tg(k))(n=
827
826
  vg(k,"queryBeforeStart",Dg,!1))?h=nr(a.h,m):nr(a.h,m);q=ng(b,"BaseURL");u=!1;if(a.h)for(a.h.l.clear(),v=t(q),y=v.next();!y.done;y=v.next())z=y.value,x=z.getAttribute("serviceLocation"),A=tg(z),x&&A&&(qr(a.h,"BaseURL",x,A),u=!0);u&&a.h||(B=q.map(tg),r=Cb(e,B));C=function(){return a.h&&u?rr(a.h,"BaseURL"):r?r:[]};E=0;q&&q.length&&(E=vg(q[0],"availabilityTimeOffset",Cg)||0);H=a.g.dash.ignoreMinBufferTime;G=0;H||(G=vg(b,"minBufferTime",xg)||0);a.H=vg(b,"minimumUpdatePeriod",xg,-1);I=vg(b,"availabilityStartTime",
828
827
  wg);J=vg(b,"timeShiftBufferDepth",xg);L=a.g.dash.ignoreSuggestedPresentationDelay;N=null;L||(N=vg(b,"suggestedPresentationDelay",xg));R=a.g.dash.ignoreMaxSegmentDuration;T=null;R||(T=vg(b,"maxSegmentDuration",xg));ea=b.getAttribute("type")||"static";if(a.j)for(Z=a.j.presentationTimeline,fa=t(Object.values(a.m)),Ha=fa.next();!Ha.done;Ha=fa.next())Xa=Ha.value,Xa.segmentIndex&&Xa.segmentIndex.wb(Z.yb());else Gb=a.g.defaultPresentationDelay||1.5*G,lb=null!=N?N:Gb,Z=new jj(I,lb,a.g.dash.autoCorrectDrift);
829
- Z.Rc("static"==ea);(bc=Z.R())&&!isNaN(a.g.availabilityWindowOverride)&&(J=a.g.availabilityWindowOverride);null==J&&(J=Infinity);Z.Ge(J);za=b.getAttribute("profiles")||"";mb={Vb:"static"!=ea,presentationTimeline:Z,Ia:null,ia:null,Ca:null,O:null,bandwidth:0,Qg:!1,Bc:E,profiles:za.split(",")};hb=bs(a,mb,C,b);Hb=hb.duration;ib=hb.periods;"static"!=ea&&hb.Ig||Z.fb(Hb||Infinity);a.D&&!a.u&&(Wh=a.i.isAutoLowLatencyMode())&&(a.i.enableLowLatencyMode(),a.u=a.i.isLowLatencyMode());a.u?Z.dh(a.D):a.D&&Sa("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.");
830
- Z.Pf(T||1);return D(sb,a.l.Dg(ib,mb.Vb),2);case 2:return D(sb,h,3);case 3:a.u&&(G=0);if(a.j){a.j.variants=a.l.j;Md=a.l.Bf();0<Md.length&&(a.j.textStreams=Md);a.j.imageStreams=a.l.i;a.i.filter(a.j);sb.F(4);break}a.j={presentationTimeline:Z,variants:a.l.j,textStreams:a.l.Bf(),imageStreams:a.l.i,offlineSessionIds:[],minBufferTime:G||0,sequenceMode:a.g.dash.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,type:"DASH",serviceDescription:cs(b)};if(!Z.nh()){sb.F(5);break}Me=ng(b,"UTCTiming");return D(sb,
831
- ds(a,C,Me),6);case 6:Ne=sb.h;if(!a.i)return sb.return();Z.eh(Ne);case 5:Z.oe();case 4:a.i.makeTextStreamsForClosedCaptions(a.j),F(sb)}})}
828
+ Z.Rc("static"==ea);(bc=Z.R())&&!isNaN(a.g.availabilityWindowOverride)&&(J=a.g.availabilityWindowOverride);null==J&&(J=Infinity);Z.Ge(J);za=b.getAttribute("profiles")||"";mb={Xb:"static"!=ea,presentationTimeline:Z,Ia:null,ia:null,Ca:null,O:null,bandwidth:0,Qg:!1,Bc:E,profiles:za.split(",")};hb=bs(a,mb,C,b);Hb=hb.duration;ib=hb.periods;"static"!=ea&&hb.Ig||Z.fb(Hb||Infinity);a.D&&!a.u&&(Xh=a.i.isAutoLowLatencyMode())&&(a.i.enableLowLatencyMode(),a.u=a.i.isLowLatencyMode());a.u?Z.dh(a.D):a.D&&Sa("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.");
829
+ Z.Pf(T||1);return D(sb,a.l.Dg(ib,mb.Xb),2);case 2:return D(sb,h,3);case 3:a.u&&(G=0);if(a.j){a.j.variants=a.l.j;Md=a.l.Bf();0<Md.length&&(a.j.textStreams=Md);a.j.imageStreams=a.l.i;a.i.filter(a.j);sb.F(4);break}a.j={presentationTimeline:Z,variants:a.l.j,textStreams:a.l.Bf(),imageStreams:a.l.i,offlineSessionIds:[],minBufferTime:G||0,sequenceMode:a.g.dash.sequenceMode,ignoreManifestTimestampsInSegmentsMode:!1,type:"DASH",serviceDescription:cs(b)};if(!Z.nh()){sb.F(5);break}Oe=ng(b,"UTCTiming");return D(sb,
830
+ ds(a,C,Oe),6);case 6:Pe=sb.h;if(!a.i)return sb.return();Z.eh(Pe);case 5:Z.oe();case 4:a.i.makeTextStreamsForClosedCaptions(a.j),F(sb)}})}
832
831
  function cs(a){a=mg(a,"ServiceDescription");if(!a)return null;var b=mg(a,"Latency"),c=mg(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}
833
832
  function bs(a,b,c,d){var e=vg(d,"mediaPresentationDuration",xg),f=[],g=0;d=ng(d,"Period");for(var h=0;h<d.length;h++){var k=d[h],l=d[h+1],m=vg(k,"start",xg,g),n=k.id,q=vg(k,"duration",xg),r=null;if(l){var u=vg(l,"start",xg);null!=u&&(r=u-m)}else null!=e&&(r=e-m);null==r&&(r=q);if(!(null!==a.C&&null!==n&&null!==m&&m<a.C)||a.L.includes(n)||h+1==d.length){null!==m&&(null===a.C||m>a.C)&&(a.C=m);g=es(a,b,c,{start:m,duration:r,node:k,Ef:null==r||!l});f.push(g);b.Ia.id&&r&&(a.M[b.Ia.id]=r);if(null==r){g=
834
833
  null;break}g=m+r}}a.L=f.map(function(v){return v.id});return null!=e?{periods:f,duration:e,Ig:!1}:{periods:f,duration:g,Ig:!0}}
835
- function es(a,b,c,d){b.Ia=fs(a,d.node,null,c);b.ia=d;b.Ia.Bc=b.Bc;b.Ia.id||(b.Ia.id="__shaka_period_"+d.start);var e=ng(d.node,"EventStream");c=b.presentationTimeline.yb();e=t(e);for(var f=e.next();!f.done;f=e.next())gs(a,d.start,d.duration,f.value,c);c=ng(d.node,"AdaptationSet").map(function(m){return hs(a,b,m)}).filter(td);if(b.Vb){d=[];e=t(c);for(f=e.next();!f.done;f=e.next()){f=t(f.value.Vi);for(var g=f.next();!g.done;g=f.next())d.push(g.value)}if(d.length!=(new Set(d)).size)throw new P(2,4,4018);
834
+ function es(a,b,c,d){b.Ia=fs(a,d.node,null,c);b.ia=d;b.Ia.Bc=b.Bc;b.Ia.id||(b.Ia.id="__shaka_period_"+d.start);var e=ng(d.node,"EventStream");c=b.presentationTimeline.yb();e=t(e);for(var f=e.next();!f.done;f=e.next())gs(a,d.start,d.duration,f.value,c);c=ng(d.node,"AdaptationSet").map(function(m){return hs(a,b,m)}).filter(td);if(b.Xb){d=[];e=t(c);for(f=e.next();!f.done;f=e.next()){f=t(f.value.Vi);for(var g=f.next();!g.done;g=f.next())d.push(g.value)}if(d.length!=(new Set(d)).size)throw new P(2,4,4018);
836
835
  }d=c.filter(function(m){return!m.qg});c=c.filter(function(m){return m.qg});c=t(c);for(e=c.next();!e.done;e=c.next()){e=e.value;f=e.qg.split(" ");g=t(d);for(var h=g.next();!h.done;h=g.next()){var k=h.value;if(f.includes(k.id)){h={};k=t(k.streams);for(var l=k.next();!l.done;h={Rd:h.Rd},l=k.next())h.Rd=l.value,h.Rd.trickModeVideo=e.streams.find(function(m){return function(n){return fd(m.Rd.codecs)==fd(n.codecs)}}(h))}}}c=is(a.g.disableAudio,d,"audio");e=is(a.g.disableVideo,d,"video");f=is(a.g.disableText,
837
836
  d,Jb);d=is(a.g.disableThumbnails,d,"image");if(0===e.length&&0===c.length)throw new P(2,4,4004);return{id:b.Ia.id,audioStreams:c,videoStreams:e,textStreams:f,imageStreams:d}}function is(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},[])}
838
837
  function hs(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.Ca=fs(a,c,b.Ia,null);var e=!1,f=ng(c,"Role"),g=f.map(function(G){return G.getAttribute("value")}).filter(td),h=void 0,k=b.Ca.contentType==Jb;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=
@@ -843,18 +842,18 @@ u?y="visually impaired":"2"==u&&(y="hard of hearing"));if(l)return null;l=ng(c,"
843
842
  k||f)return null;throw new P(2,4,4003);}if(!b.Ca.contentType||"application"==b.Ca.contentType)for(b.Ca.contentType=ks(c[0].mimeType,c[0].codecs),k=t(c),r=k.next();!r.done;r=k.next())r.value.type=b.Ca.contentType;k=b.Ca.id||"__fake__"+a.K++;m=t(c);for(r=m.next();!r.done;r=m.next()){r=r.value;u=t(C.drmInfos);for(z=u.next();!z.done;z=u.next())z=z.value,z.keyIds=z.keyIds&&r.keyIds?new Set([].concat(w(z.keyIds),w(r.keyIds))):z.keyIds||r.keyIds;a.g.dash.enableAudioGroups&&(r.groupId=k)}l=l.map(function(G){return G.getAttribute("id")}).filter(td);
844
843
  return{id:k,contentType:b.Ca.contentType,language:E,ik:e,streams:c,drmInfos:C.drmInfos,qg:f,Vi:l}}
845
844
  function js(a,b,c,d,e,f,g,h,k,l,m){b.O=fs(a,l,b.Ca,null);a.D=Math.min(a.D,b.O.Bc);if(!ls(b.O))return null;var n=b.ia.start;b.bandwidth=vg(l,"bandwidth",Ag)||0;var q=b.O.contentType,r=q==Jb||"application"==q;q="image"==q;try{var u=void 0;if(c.Xe){var v=b.O.xb,y=Cb(v(),[c.Xe.Ei]),z=qf(y,a.g.retryParameters);u={method:"AES-128",iv:c.Xe.iv,firstMediaSequenceNumber:0,fetchKey:function(){var I,J,L;return K(function(N){if(1==N.g)return D(N,Zr(a,z,6),2);if(3!=N.g){I=N.h;if(!I.data||16!=I.data.byteLength)throw new P(2,
846
- 4,4049);J={name:"AES-CBC"};L=u;return D(N,window.crypto.subtle.importKey("raw",I.data,J,!0,["decrypt"]),3)}L.cryptoKey=N.h;u.fetchKey=void 0;F(N)})}}}v=function(I,J,L,N){return ms(a,I,J,L,N)};if(b.O.Gd)var x=Sq(b,v,u);else if(b.O.bc)x=Yq(b,a.m,u);else if(b.O.Hd)x=cr(b,v,a.m,!!a.j,a.g.dash.initialSegmentLimit,a.M,u);else{var A=b.ia.duration||0,B=b.O.xb;x={Ec:function(){return Promise.resolve(Ij(n,A,B()))}}}}catch(I){if((r||q)&&4002==I.code)return null;throw I;}v=ng(l,"ContentProtection");v=sq(v,c,
845
+ 4,4049);J={name:"AES-CBC"};L=u;return D(N,window.crypto.subtle.importKey("raw",I.data,J,!0,["decrypt"]),3)}L.cryptoKey=N.h;u.fetchKey=void 0;F(N)})}}}v=function(I,J,L,N){return ms(a,I,J,L,N)};if(b.O.Gd)var x=Sq(b,v,u);else if(b.O.cc)x=Yq(b,a.m,u);else if(b.O.Hd)x=cr(b,v,a.m,!!a.j,a.g.dash.initialSegmentLimit,a.M,u);else{var A=b.ia.duration||0,B=b.O.xb;x={Ec:function(){return Promise.resolve(Ij(n,A,B()))}}}}catch(I){if((r||q)&&4002==I.code)return null;throw I;}v=ng(l,"ContentProtection");v=sq(v,c,
847
846
  a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI);v=new Set(v?[v]:[]);y=!1;ng(l,"SupplementalProperty").some(function(I){return"tag:dolby.com,2018:dash:EC3_ExtensionType:2018"==I.getAttribute("schemeIdUri")&&"JOC"==I.getAttribute("value")})&&(y=!0);var C=!1;r&&(C=h.includes("forced_subtitle")||h.includes("forced-subtitle"));var E;if(q&&((l=ng(l,"EssentialProperty").find(function(I){return["http://dashif.org/thumbnail_tile","http://dashif.org/guidelines/thumbnail_tile"].includes(I.getAttribute("schemeIdUri"))}))&&
848
847
  (E=l.getAttribute("value")),!E))return null;var H;l=b.O.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"))&&(H="PQ");l=b.O.id?b.Ia.id+","+b.O.id:"";var G=l&&a.m[l]?a.m[l]:{id:a.K++,originalId:b.O.id,groupId:null,createSegmentIndex:function(){return Promise.resolve()},closeSegmentIndex:function(){G.segmentIndex&&(G.segmentIndex.release(),G.segmentIndex=null)},segmentIndex:null,mimeType:b.O.mimeType,
849
848
  codecs:b.O.codecs,frameRate:b.O.frameRate,pixelAspectRatio:b.O.pixelAspectRatio,bandwidth:b.bandwidth,width:b.O.width,height:b.O.height,kind:d,encrypted:0<c.drmInfos.length,drmInfos:c.drmInfos,keyIds:v,language:e,originalLanguage:b.Ca.language,label:f,type:b.Ca.contentType,primary:g,trickModeVideo:null,emsgSchemeIdUris:b.O.emsgSchemeIdUris,roles:h,forced:C,channelsCount:b.O.xe,audioSamplingRate:b.O.audioSamplingRate,spatialAudio:y,closedCaptions:k,hdr:H,videoLayout:void 0,tilesLayout:E,matchedStreams:[],
850
- accessibilityPurpose:m,external:!1,fastSwitching:!1};G.createSegmentIndex=function(){var I;return K(function(J){if(1==J.g){if(G.segmentIndex)return J.F(0);I=G;return D(J,x.Ec(),3)}I.segmentIndex=J.h;F(J)})};l&&b.Vb&&!a.m[l]&&(a.m[l]=G);return G}
849
+ accessibilityPurpose:m,external:!1,fastSwitching:!1};G.createSegmentIndex=function(){var I;return K(function(J){if(1==J.g){if(G.segmentIndex)return J.F(0);I=G;return D(J,x.Ec(),3)}I.segmentIndex=J.h;F(J)})};l&&b.Xb&&!a.m[l]&&(a.m[l]=G);return G}
851
850
  function Wr(a){var b,c;K(function(d){switch(d.g){case 1:return b=0,ta(d,2),D(d,Xr(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();Yr(a,b);F(d)}})}function Yr(a,b){0>a.H||a.I.T(Math.max(a.H-b,ac(a.J)))}
852
851
  function fs(a,b,c,d){c=c||{contentType:"",mimeType:"",codecs:"",emsgSchemeIdUris:[],frameRate:void 0,pixelAspectRatio:void 0,xe:null,audioSamplingRate:null,Bc:0,ag:0};d=d||c.xb;var e=b.getAttribute("id"),f=ng(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=tg(m);l&&m&&(qr(a.h,e,l,m),h=!0)}h&&a.h||(g=f.map(tg));k=b.getAttribute("contentType")||c.contentType;l=b.getAttribute("mimeType")||c.mimeType;m=b.getAttribute("codecs")||
853
852
  c.codecs;var n=vg(b,"frameRate",Eg)||c.frameRate,q=b.getAttribute("sar")||c.pixelAspectRatio,r=ns(ng(b,"InbandEventStream"),c.emsgSchemeIdUris),u=ng(b,"AudioChannelConfiguration");u=os(u)||c.xe;var v=vg(b,"audioSamplingRate",Bg)||c.audioSamplingRate;k||(k=ks(l,m));var y=mg(b,"SegmentBase"),z=mg(b,"SegmentTemplate"),x=y?vg(y,"availabilityTimeOffset",Cg)||0:0,A=z?vg(z,"availabilityTimeOffset",Cg)||0:0,B=f&&f.length?vg(f[0],"availabilityTimeOffset",Cg)||0:0;x=c.Bc+B+x+A;A=null;(B=mg(b,"SegmentSequenceProperties"))&&
854
- (B=mg(B,"SAP"))&&(A=vg(B,"cadence",zg));return{xb:function(){return Cb(d(),f.length?a.h&&h?rr(a.h,e):g?g:[]:[])},Gd:y||c.Gd,bc:mg(b,"SegmentList")||c.bc,Hd:z||c.Hd,width:vg(b,"width",Bg)||c.width,height:vg(b,"height",Bg)||c.height,contentType:k,mimeType:l,codecs:m,frameRate:n,pixelAspectRatio:q,emsgSchemeIdUris:r,id:e,language:b.getAttribute("lang"),xe:u,audioSamplingRate:v,Bc:x,ag:A||c.ag}}
853
+ (B=mg(B,"SAP"))&&(A=vg(B,"cadence",zg));return{xb:function(){return Cb(d(),f.length?a.h&&h?rr(a.h,e):g?g:[]:[])},Gd:y||c.Gd,cc:mg(b,"SegmentList")||c.cc,Hd:z||c.Hd,width:vg(b,"width",Bg)||c.width,height:vg(b,"height",Bg)||c.height,contentType:k,mimeType:l,codecs:m,frameRate:n,pixelAspectRatio:q,emsgSchemeIdUris:r,id:e,language:b.getAttribute("lang"),xe:u,audioSamplingRate:v,Bc:x,ag:A||c.ag}}
855
854
  function ns(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}
856
855
  function os(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=
857
- 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 ls(a){var b=a.Gd?1:0;b+=a.bc?1:0;b+=a.Hd?1:0;if(0==b)return a.contentType==Jb||"application"==a.contentType?!0:!1;1!=b&&(a.Gd&&(a.bc=null),a.Hd=null);return!0}
856
+ 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 ls(a){var b=a.Gd?1:0;b+=a.cc?1:0;b+=a.Hd?1:0;if(0==b)return a.contentType==Jb||"application"==a.contentType?!0:!1;1!=b&&(a.Gd&&(a.cc=null),a.Hd=null);return!0}
858
857
  function ps(a,b,c,d){var e,f,g,h,k,l;return K(function(m){if(1==m.g)return e=Cb(b(),[c]),f=qf(e,a.g.retryParameters),f.method=d,g=a.i.networkingEngine.request(4,f),lf(a.G,g),D(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=Kf(h.data);l=Date.parse(k);return isNaN(l)?m.return(0):m.return(l-Date.now())})}
859
858
  function ds(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(q){return{scheme:q.getAttribute("schemeIdUri"),value:q.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.F(4);break}h=g.value;ta(n,5);k=h.scheme;l=h.value;switch(k){case "urn:mpeg:dash:utc:http-head:2014":case "urn:mpeg:dash:utc:http-head:2012":return n.F(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.F(8);
860
859
  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":Sa("NTP UTCTiming scheme is not supported");break;default:Sa("Unrecognized scheme in UTCTiming element",k)}n.F(9);break;case 7:return D(n,ps(a,b,l,"HEAD"),10);case 10:return n.return(n.h);case 8:return D(n,ps(a,b,l,"GET"),11);case 11:return n.return(n.h);case 9:va(n,
@@ -870,24 +869,24 @@ g.name&&(g.g.push(new zs("URI",h)),d=!0)}}return new us(b,e)}function Ms(a,b){a=
870
869
  var Ns="EXT-X-TARGETDURATION EXT-X-MEDIA-SEQUENCE EXT-X-DISCONTINUITY-SEQUENCE EXT-X-PLAYLIST-TYPE EXT-X-I-FRAMES-ONLY EXT-X-ENDLIST EXT-X-SERVER-CONTROL EXT-X-SKIP EXT-X-PART-INF".split(" "),Os="EXTINF EXT-X-BYTERANGE EXT-X-DISCONTINUITY EXT-X-PROGRAM-DATE-TIME EXT-X-KEY EXT-X-DATERANGE EXT-X-MAP".split(" ");function Ps(){}function Qs(a){try{var b=Rs(a);return df({uri:a,originalUri:a,data:b.data,headers:{"content-type":b.contentType}})}catch(c){return bf(c)}}
871
870
  function Rs(a){var b=a.split(":");if(2>b.length||"data"!=b[0])throw new P(2,1,1004,a);b=b.slice(1).join(":").split(",");if(2>b.length)throw new P(2,1,1004,a);var c=b[0];a=window.decodeURIComponent(b.slice(1).join(","));b=c.split(";");c=b[0];var d=!1;1<b.length&&"base64"==b[b.length-1]&&(d=!0,b.pop());var e;d?e=fg(a):e=Of(a);return{data:e,contentType:c}}M("shaka.net.DataUriPlugin",Ps);Ps.parse=Qs;nf("data",Qs);function Ss(a){var b=hd(a),c=b.split("/")[0];a=id(a);return{type:c,mimeType:b,codecs:a,language:null,height:null,width:null,channelCount:null,sampleRate:null,closedCaptions:new Map}}
872
871
  function Ts(a,b){function c(v){return d(v.name)}function d(v){v=v.toLowerCase();switch(v){case "avc1":case "avc3":e.push(v+".42E01E");g=!0;break;case "hev1":case "hvc1":e.push(v+".1.6.L93.90");g=!0;break;case "dvh1":case "dvhe":e.push(v+".05.04");g=!0;break;case "vp09":e.push(v+".00.10.08");g=!0;break;case "av01":e.push(v+".0.01M.08");g=!0;break;case "mp4a":e.push("mp4a.40.2");f=!0;break;case "ac-3":case "ec-3":case "opus":case "flac":e.push(v),f=!0}}var e=[],f=!1,g=!1,h=null,k=null,l=null,m=null,
873
- n=null;(new Tf).box("moov",Yf).box("trak",Yf).S("tkhd",function(v){v=Zh(v.reader,v.version);k=String(v.height);l=String(v.width)}).box("mdia",Yf).S("mdhd",function(v){h=Xh(v.reader,v.version).language}).box("minf",Yf).box("stbl",Yf).S("stsd",$f).box("mp4a",function(v){var y=v.reader;y.skip(6);y.skip(2);y.skip(8);var z=y.Ta();y.skip(2);y.skip(2);y.skip(2);y=y.Ta()+y.Ta()/65536;m=z;n=y;v.reader.wa()?Yf(v):c(v)}).box("esds",function(v){v=$h(v.reader);e.push(v.va);f=!0}).box("ac-3",c).box("ec-3",c).box("opus",
872
+ n=null;(new Tf).box("moov",Yf).box("trak",Yf).S("tkhd",function(v){v=Zh(v.reader,v.version);k=String(v.height);l=String(v.width)}).box("mdia",Yf).S("mdhd",function(v){h=Wh(v.reader,v.version).language}).box("minf",Yf).box("stbl",Yf).S("stsd",$f).box("mp4a",function(v){var y=v.reader;y.skip(6);y.skip(2);y.skip(8);var z=y.Ta();y.skip(2);y.skip(2);y.skip(2);y=y.Ta()+y.Ta()/65536;m=z;n=y;v.reader.wa()?Yf(v):c(v)}).box("esds",function(v){v=$h(v.reader);e.push(v.va);f=!0}).box("ac-3",c).box("ec-3",c).box("opus",
874
873
  c).box("Opus",c).box("fLaC",c).box("avc1",function(v){v=ai(v.reader,v.name);e.push(v.va);g=!0}).box("avc3",function(v){v=ai(v.reader,v.name);e.push(v.va);g=!0}).box("hev1",c).box("hvc1",c).box("dvh1",c).box("dvhe",c).box("vp09",c).box("av01",c).box("enca",ag).box("encv",ag).box("sinf",Yf).box("frma",function(v){v=bi(v.reader).va;d(v)}).parse(a||b,!0);if(!e.length)return null;var q=f&&!g,r=new Map;if(g){var u=new rc("video/mp4");a&&u.init(a);u.i(b);a=t(u.j());for(b=a.next();!b.done;b=a.next())b=b.value,
875
874
  r.set(b,b);u.h()}return{type:q?"audio":"video",mimeType:q?"audio/mp4":"video/mp4",codecs:Us(e).join(", "),language:h,height:k,width:l,channelCount:m,sampleRate:n,closedCaptions:r}}function Us(a){var b=new Set,c=[];a=t(a);for(var d=a.next();!d.done;d=a.next()){d=d.value;var e=gd(d)[0];b.has(e)||(c.push(d),b.add(e))}return c};function Vs(){var a=this;this.g=this.i=null;this.C=1;this.s=new Map;this.J=new Map;this.L=new Map;this.L.set("video",new Map);this.L.set("audio",new Map);this.L.set(Jb,new Map);this.L.set("image",new Map);this.Ka=new Set;this.h=new Map;this.l=null;this.Z="";this.ra=new Ks;this.K=-1;this.U=Infinity;this.$=this.Xa=!1;this.u=new vd(function(){Ws(a)});this.qa=Xs;this.G=null;this.sa=0;this.m=Infinity;this.ha=this.ea=this.M=0;this.P=new kf;this.H=new Map;this.I=new Map;this.V=new Map;this.Va=this.D=!1;
876
875
  this.Qa=new $b(5);this.j=null}p=Vs.prototype;p.configure=function(a){this.g=a;this.j&&this.j.configure(this.g)};p.start=function(a,b){var c=this,d;return K(function(e){return 1==e.g?(c.i=b,c.D=b.isLowLatencyMode(),D(e,Ys(c,[a]),2)):3!=e.g?(d=e.h,c.Z=d.uri,D(e,Zs(c,d.data,a),3)):e.return(c.G)})};
877
876
  p.stop=function(){this.u&&(this.u.stop(),this.u=null);var a=[];this.P&&(a.push(this.P.destroy()),this.P=null);this.g=this.i=null;this.Ka.clear();this.G=null;this.h.clear();this.J.clear();this.I.clear();this.s.clear();this.V.clear();this.j&&this.j.destroy();return Promise.all(a)};
878
- p.update=function(){var a=this,b,c,d,e,f,g,h,k,l;return K(function(m){if(1==m.g){if(!$s(a))return m.return();b=[];c=Array.from(a.h.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(at(a,g));return D(m,Promise.all(b),2)}bt(a,d.map(function(n){return n.stream}));h=d.some(function(n){return 0==n.sd});d.length&&!h&&(k=ct,dt(a,k.sh),l=d.map(function(n){return n.Mb}),a.l.fb(Math.min.apply(Math,w(l))),a.i.updateDuration());
877
+ p.update=function(){var a=this,b,c,d,e,f,g,h,k,l;return K(function(m){if(1==m.g){if(!$s(a))return m.return();b=[];c=Array.from(a.h.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(at(a,g));return D(m,Promise.all(b),2)}bt(a,d.map(function(n){return n.stream}));h=d.some(function(n){return 0==n.sd});d.length&&!h&&(k=ct,dt(a,k.sh),l=d.map(function(n){return n.Ob}),a.l.fb(Math.min.apply(Math,w(l))),a.i.updateDuration());
879
878
  h&&et(a);F(m)})};function ft(a,b){return $s(a)?a.L.get(b.type):b.re}
880
879
  function at(a,b){var c,d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B,C,E,H,G,I,J,L,N,R,T,ea;return K(function(Z){if(1==Z.g){c=[];d=t(b.aa());for(e=d.next();!e.done;e=d.next())f=e.value,g=new gb(f),h=g.g,b.Vd&&(0<=b.qb&&h.add("_HLS_msn",String(b.qb)),0<=b.rb&&h.add("_HLS_part",String(b.rb))),b.Wd&&h.add("_HLS_skip","YES"),Ab(h)&&ob(g,h),c.push(g.toString());return D(Z,Ys(a,c,!0),2)}k=Z.h;if(!b.stream.segmentIndex)return Z.return();l=Ls(a.ra,k.data);if(1!=l.type)throw new P(2,4,4017);m=k.uri;m==k.originalUri||
881
880
  b.aa().includes(m)||b.$g.push(m);n=As(l.g,"EXT-X-DEFINE");q=gt(a,n,m);r=b.stream;u=ft(a,b);v=ht(l,r.mimeType);y=v.keyIds;z=v.drmInfos;x=function(fa,Ha){return fa.size===Ha.size&&[].concat(w(fa)).every(function(Xa){return Ha.has(Xa)})};x(r.keyIds,y)||(r.keyIds=y,r.drmInfos=z,a.i.newDrmInfo(r));A=it(a,l,r,u,q,b.aa);B=A.segments;C=A.bandwidth;r.bandwidth=C;r.segmentIndex.xd(B,a.l.yb());B.length&&(E=Ds(l.g,"EXT-X-MEDIA-SEQUENCE",0),G=(H=Cs(l.g,"EXT-X-SKIP"))?Number(X(H,"SKIPPED-SEGMENTS")):0,I=jt(E,B),
882
- J=I.qb,L=I.rb,b.qb=J+G,b.rb=L,N=u.get(E),r.segmentIndex.wb(N));R=B[0];b.sc=R.startTime;T=B[B.length-1];b.Mb=T.endTime;if(ea=Cs(l.g,"EXT-X-ENDLIST"))b.sd=!0;kt(a,l);F(Z)})}p.onExpirationUpdated=function(){};p.onInitialVariantChosen=function(){};p.banLocation=function(a){this.j&&this.j.i.set(a,Date.now()+6E4)};
881
+ J=I.qb,L=I.rb,b.qb=J+G,b.rb=L,N=u.get(E),r.segmentIndex.wb(N));R=B[0];b.sc=R.startTime;T=B[B.length-1];b.Ob=T.endTime;if(ea=Cs(l.g,"EXT-X-ENDLIST"))b.sd=!0;kt(a,l);F(Z)})}p.onExpirationUpdated=function(){};p.onInitialVariantChosen=function(){};p.banLocation=function(a){this.j&&this.j.i.set(a,Date.now()+6E4)};
883
882
  function lt(a,b){for(var c=-1==a.K,d=t(b),e=d.next();!e.done;e=d.next()){e=e.value;var f=e.stream.segmentIndex,g=ft(a,e);if(f=f.g[0]||null){g=t(g);for(var h=g.next();!h.done;h=g.next()){h=t(h.value);var k=h.next().value;if(h.next().value==f.startTime){c&&(a.K=Math.max(a.K,k));e.gf=k;break}}}}if(!(0>a.K))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.K-c.gf),d=d.g[0]||null)d=-d.startTime,c.stream.segmentIndex.offset(d),mt(a,c,d)}
884
883
  function nt(a,b){if(Infinity==a.U){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.ma&&(a.U=Math.min(a.U,d.ma))}}b=a.U;if(Infinity!=b)for(d=t(a.h.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.ma)Ra("Missing EXT-X-PROGRAM-DATE-TIME for stream",c.aa(),"Expect AV sync issues!");else for(mt(a,c,f.ma-b-f.startTime),c=t(e),e=c.next();!e.done;e=c.next())e.value.mg(b)}}}
885
- function mt(a,b,c){b.sc+=c;b.Mb+=c;a=ft(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.aa()}
884
+ function mt(a,b,c){b.sc+=c;b.Ob+=c;a=ft(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.aa()}
886
885
  function Zs(a,b,c){var d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B,C,E,H,G,I,J,L,N,R,T,ea,Z;return K(function(fa){switch(fa.g){case 1:d=Ls(a.ra,b);e=As(d.g,"EXT-X-DEFINE");f=[];g=[];h=[];if(1==d.type)return v=function(){return[c]},D(fa,ot(a,d,v),6);pt(a,e);k=As(d.g,"EXT-X-MEDIA");l=As(d.g,"EXT-X-STREAM-INF");m=As(d.g,"EXT-X-IMAGE-STREAM-INF");n=As(d.g,"EXT-X-I-FRAME-STREAM-INF");q=As(d.g,"EXT-X-SESSION-KEY");r=As(d.g,"EXT-X-SESSION-DATA");u=As(d.g,"EXT-X-CONTENT-STEERING");qt(a,r);return D(fa,rt(a,u),4);
887
886
  case 4:return st(a,l),tt(a,k),f=ut(a,l,q,k),g=vt(a,k),D(fa,wt(a,m,n),5);case 5:h=fa.h;fa.F(3);break;case 6:return y=fa.h,z=y.type,x=y.mimeType,A=y.codecs,B=y.language,C=y.height,E=y.width,H=y.channelCount,G=y.sampleRate,I=y.closedCaptions,D(fa,xt(a,a.C++,d,v,c,A,z,B,!0,"Media Playlist",H,I,null,!1,G,!1,x),7);case 7:J=fa.h,a.h.set(c,J),"video"==z&&yt(J.stream,E,C,null,null,null),f.push({id:0,language:Nb(B||"und"),disabledUntilTime:0,primary:!0,audio:"audio"==z?J.stream:null,video:"video"==z?J.stream:
888
887
  null,bandwidth:J.stream.bandwidth||0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});case 3:if(!a.i)throw new P(2,7,7001);a.l=new jj(null,0);a.l.Rc(!0);1==d.type&&($s(a)&&(zt(a,d),L=a.m,a.u.T(L)),N=Array.from(a.h.values()),At(a,N),et(a));a.G={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};
889
888
  if(a.$||!a.g.hls.disableCodecGuessing){fa.F(8);break}R=[];T=t(a.G.variants);for(ea=T.next();!ea.done;ea=T.next())Z=ea.value,Z.audio&&""===Z.audio.codecs&&R.push(Z.audio.createSegmentIndex()),Z.video&&""===Z.video.codecs&&R.push(Z.video.createSegmentIndex());return D(fa,Promise.all(R),8);case 8:a.i.makeTextStreamsForClosedCaptions(a.G),F(fa)}})}
890
- function ot(a,b,c){var d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B;return K(function(C){switch(C.g){case 1:d=Ss(a.g.hls.mediaPlaylistFullMimeType);if(!b.segments.length)return C.return(d);e=Math.trunc((b.segments.length-1)/2);f=b.segments[e];g=Es(c(),b.segments[0].h);h=g[0];k=new gb(h);l=k.Wa.split(".").pop();if(m=Bt[l])return C.return(Ss(m));n=wf;q=null;r=Ct(a,b,f.g,c);a.V.clear();if(!r){C.F(2);break}u=qf(r.aa(),a.g.retryParameters);return D(C,Dt(a,u,n,{type:0}),3);case 3:v=C.h,q=v.data;case 2:return y=
889
+ function ot(a,b,c){var d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B;return K(function(C){switch(C.g){case 1:d=Ss(a.g.hls.mediaPlaylistFullMimeType);if(!b.segments.length)return C.return(d);e=Math.trunc((b.segments.length-1)/2);f=b.segments[e];g=Es(c(),b.segments[0].h);h=g[0];k=new gb(h);l=k.Wa.split(".").pop();if(m=Bt[l])return C.return(Ss(m));n=wf;q=null;r=Ct(a,b,f.g,c);a.V.clear();if(!r){C.F(2);break}u=fk(r.aa(),r.Nb(),r.Kb(),a.g.retryParameters);return D(C,Dt(a,u,n,{type:0}),3);case 3:v=C.h,q=v.data;case 2:return y=
891
890
  qf(g,a.g.retryParameters),D(C,Dt(a,y,n,{type:1}),4);case 4:z=C.h;(x=z.headers["content-type"])&&(x=x.split(";")[0].toLowerCase());if("ts"==l||"video/mp2t"==x){var E=z.data;var H=lc(E);H=(new mi).parse(H);var G=H.pd();H=H.Df();var I=[],J=!1,L=!1;switch(G.audio){case "aac":I.push("mp4a.40.2");J=!0;break;case "mp3":I.push("mp4a.40.34");J=!0;break;case "ac3":I.push("ac-3");J=!0;break;case "ec3":I.push("ec-3"),J=!0}switch(G.video){case "avc":H.va?I.push(H.va):I.push("avc1.42E01E");L=!0;break;case "hvc":H.va?
892
891
  I.push(H.va):I.push("hvc1.1.6.L93.90"),L=!0}if(I.length){G=J&&!L;J=new Map;if(L){L=new rc("video/mp2t");L.i(E);E=t(L.j());for(var N=E.next();!N.done;N=E.next())N=N.value,J.set(N,N);L.h()}H={type:G?"audio":"video",mimeType:"video/mp2t",codecs:I.join(", "),language:null,height:H.height,width:H.width,channelCount:null,sampleRate:null,closedCaptions:J}}else H=null;if(A=H)return C.return(A)}else if("mp4"==l||"cmfv"==l||"m4s"==l||"video/mp4"==x||"audio/mp4"==x||"video/iso.segment"==x)if(B=Ts(q,z.data))return C.return(B);
893
892
  return C.return(d)}})}function et(a){if($s(a)){if(a.qa==Et){var b=Ft(a);a.g.hls.useSafariBehaviorForLive&&(b=a.l.s);isNaN(a.g.availabilityWindowOverride)||(b=a.g.availabilityWindowOverride);a.l.Ge(b)}if(!a.l.m){b=Array.from(a.h.values()).filter(function(d){return d.stream.segmentIndex});b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,("audio"==c.type||"video"==c.type)&&(c=c.stream.segmentIndex.get(0))&&c.ma&&a.l.ig(c.ma)}}else a.l.fb(Gt(a));a.l.oe()}
@@ -915,18 +914,18 @@ function Lt(a,b){var c,d,e,f,g,h,k,l,m,n;return K(function(q){if(1==q.g){c=xs(b,
915
914
  Number(m.split("x")[1]));if(n=X(b,"BANDWIDTH"))h.stream.bandwidth=Number(n);a.h.set(c,h);return q.return(h)})}
916
915
  function Ut(a,b,c,d,e,f,g,h,k){for(var l=a.C++,m=[],n=t(b),q=n.next();!q.done;q=n.next()){var r=q.value;q=xs(r,"URI");r=X(r,"PATHWAY-ID");a.j&&r&&qr(a.j,l,r,q);m.push(q)}n=m.sort().join(",");if(a.h.has(n))return a.h.get(n);a:{b=X(b[0],"CLOSED-CAPTIONS");if("video"==d){if(b&&"NONE"!=b){b=a.H.get(b);break a}if(!b&&a.H.size)for(b=t(a.H.keys()).next();!b.done;){b=a.H.get(b.value);break a}}b=null}c=Eb(d,c);d=Mt(a,l,m,c,d,e,!1,f,g,b,h,!1,k,!1);a.h.set(n,d);return d}
917
916
  function Mt(a,b,c,d,e,f,g,h,k,l,m,n,q,r){function u(C){var E,H,G,I,J,L,N,R,T,ea,Z,fa,Ha,Xa,Gb,lb,bc;return K(function(za){switch(za.g){case 1:return E=x.aa(),D(za,Ys(a,x.aa(),!0),2);case 2:H=za.h;if(C.aborted)return za.return();G=H.uri;G==H.originalUri||E.includes(G)||z.push(G);I=Ls(a.ra,H.data);J=void 0;if(a.$||!a.g.hls.disableCodecGuessing){za.F(3);break}return D(za,ot(a,I,v),4);case 4:L=za.h,J=L.mimeType,d=L.codecs;case 3:return N=$s(a),D(za,xt(a,0,I,v,G,d,e,f,g,h,k,l,m,n,q,r,J),5);case 5:R=za.h;
918
- if(C.aborted)return za.return();T=R.stream;$s(a)&&!N&&zt(a,I);x.sc=R.sc;x.Mb=R.Mb;x.Wd=R.Wd;x.Vd=R.Vd;x.sd=R.sd;x.re=R.re;x.qb=R.qb;x.rb=R.rb;x.Lf=!0;y.segmentIndex=T.segmentIndex;y.encrypted=T.encrypted;y.drmInfos=T.drmInfos;y.keyIds=T.keyIds;y.mimeType=T.mimeType;y.bandwidth=T.bandwidth;y.codecs=T.codecs||y.codecs;y.drmInfos.length&&a.i.newDrmInfo(y);ea=Kb;if(e==ea.ua||e==ea.W)for(Z=t(a.h.values()),fa=Z.next();!fa.done;fa=Z.next())Ha=fa.value,Ha.Lf||Ha.type!=e||(Ha.stream.mimeType=T.mimeType);e==
919
- ea.za&&(Xa=T.segmentIndex.get(0))&&Xa.g&&(y.mimeType="application/mp4");Vt(a)&&(a.Xa?At(a,[x]):(a.Xa=!0,Gb=Array.from(a.h.values()),lb=Gb.filter(function(mb){return mb.stream.segmentIndex}),At(a,lb),et(a),bc=a.m,0<bc&&a.u.T(bc)));F(za)}})}function v(){return a.j&&1<c.length?rr(a.j,b):z.concat(Fs([a.Z],c,a.s))}var y=Wt(a,d,e,f,g,h,k,l,m,n,q,r),z=[],x={stream:y,type:e,$g:z,aa:v,sc:0,Mb:0,re:new Map,Wd:!1,Vd:!1,sd:!1,gf:-1,qb:-1,rb:-1,Lf:!1},A=null,B=new AbortController;y.createSegmentIndex=function(){if(A)return A;
920
- B=new AbortController;return A=new Promise(function(C){C(u(B.signal))})};y.closeSegmentIndex=function(){A&&!y.segmentIndex&&B.abort();y.segmentIndex&&(y.segmentIndex.release(),y.segmentIndex=null);A=null};return x}function Gt(a){var b=Infinity;a=t(a.h.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.Mb));return b}
921
- function Ft(a){var b=Infinity,c=Infinity;a=t(a.h.values());for(var d=a.next();!d.done;d=a.next())d=d.value,d.stream.segmentIndex&&"text"!=d.stream.type&&(b=Math.min(b,d.Mb),c=Math.min(c,d.sc));return b-c}function bt(a,b){var c=[];b=t(b);for(var d=b.next();!d.done;d=b.next())d=d.value,d.segmentIndex&&Gj(d.segmentIndex,function(e){c.push(e)});a.l.yd(c)}
917
+ if(C.aborted)return za.return();T=R.stream;$s(a)&&!N&&zt(a,I);x.sc=R.sc;x.Ob=R.Ob;x.Wd=R.Wd;x.Vd=R.Vd;x.sd=R.sd;x.re=R.re;x.qb=R.qb;x.rb=R.rb;x.Lf=!0;y.segmentIndex=T.segmentIndex;y.encrypted=T.encrypted;y.drmInfos=T.drmInfos;y.keyIds=T.keyIds;y.mimeType=T.mimeType;y.bandwidth=T.bandwidth;y.codecs=T.codecs||y.codecs;y.drmInfos.length&&a.i.newDrmInfo(y);ea=Kb;if(e==ea.ua||e==ea.W)for(Z=t(a.h.values()),fa=Z.next();!fa.done;fa=Z.next())Ha=fa.value,Ha.Lf||Ha.type!=e||(Ha.stream.mimeType=T.mimeType);e==
918
+ ea.za&&(Xa=T.segmentIndex.get(0))&&Xa.g&&(y.mimeType="application/mp4");Vt(a)&&(a.Xa?At(a,[x]):(a.Xa=!0,Gb=Array.from(a.h.values()),lb=Gb.filter(function(mb){return mb.stream.segmentIndex}),At(a,lb),et(a),bc=a.m,0<bc&&a.u.T(bc)));F(za)}})}function v(){return a.j&&1<c.length?rr(a.j,b):z.concat(Fs([a.Z],c,a.s))}var y=Wt(a,d,e,f,g,h,k,l,m,n,q,r),z=[],x={stream:y,type:e,$g:z,aa:v,sc:0,Ob:0,re:new Map,Wd:!1,Vd:!1,sd:!1,gf:-1,qb:-1,rb:-1,Lf:!1},A=null,B=new AbortController;y.createSegmentIndex=function(){if(A)return A;
919
+ B=new AbortController;return A=new Promise(function(C){C(u(B.signal))})};y.closeSegmentIndex=function(){A&&!y.segmentIndex&&B.abort();y.segmentIndex&&(y.segmentIndex.release(),y.segmentIndex=null);A=null};return x}function Gt(a){var b=Infinity;a=t(a.h.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.Ob));return b}
920
+ function Ft(a){var b=Infinity,c=Infinity;a=t(a.h.values());for(var d=a.next();!d.done;d=a.next())d=d.value,d.stream.segmentIndex&&"text"!=d.stream.type&&(b=Math.min(b,d.Ob),c=Math.min(c,d.sc));return b-c}function bt(a,b){var c=[];b=t(b);for(var d=b.next();!d.done;d=b.next())d=d.value,d.segmentIndex&&Gj(d.segmentIndex,function(e){c.push(e)});a.l.yd(c)}
922
921
  function At(a,b){if(!$s(a))for(var c=Gt(a),d=t(b),e=d.next();!e.done;e=d.next())e.value.stream.segmentIndex.Cc(0,c);bt(a,b.map(function(f){return f.stream}));a.g.hls.ignoreManifestProgramDateTime?lt(a,b):nt(a,b)}function Vt(a){if(!a.G)return!1;var b=[],c=[];a=t(a.G.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}
923
922
  function xt(a,b,c,d,e,f,g,h,k,l,m,n,q,r,u,v,y){var z,x,A,B,C,E,H,G,I,J,L,N,R,T,ea,Z,fa,Ha,Xa,Gb,lb,bc,za;return K(function(mb){if(1==mb.g){if(1!=c.type)throw new P(2,4,4017);z=As(c.g,"EXT-X-DEFINE");x=gt(a,z,e);var hb=Cs(c.g,"EXT-X-PLAYLIST-TYPE"),Hb=Cs(c.g,"EXT-X-ENDLIST");Hb=hb&&"VOD"==hb.value||Hb;hb=hb&&"EVENT"==hb.value&&!Hb;hb=!Hb&&!hb;Hb?dt(a,Xs):hb?dt(a,Et):dt(a,Xt);$s(a)&&kt(a,c);return y?mb.F(2):D(mb,Yt(a,g,f,c,x,d),3)}2!=mb.g&&(y=mb.h);A=ht(c,y);B=A.drmInfos;C=A.keyIds;E=A.encrypted;H=
924
923
  A.xh;if(E&&!B.length&&!H)throw new P(2,4,4026);G=Wt(a,f,g,h,k,l,m,n,q,r,u,v);G.encrypted=E;G.drmInfos=B;G.keyIds=C;G.mimeType=y;I=$s(a)?a.L.get(g):new Map;J=it(a,c,G,I,x,d);L=J.segments;N=J.bandwidth;G.bandwidth=N;$s(a)&&kt(a,c);R=L[0].startTime;T=L[L.length-1];ea=T.endTime;Z=new Fj(L);G.segmentIndex=Z;Ha=(fa=Cs(c.g,"EXT-X-SERVER-CONTROL"))?null!=fa.getAttribute("CAN-SKIP-UNTIL"):!1;Xa=fa?null!=fa.getAttribute("CAN-BLOCK-RELOAD"):!1;Gb=Ds(c.g,"EXT-X-MEDIA-SEQUENCE",0);lb=jt(Gb,L);bc=lb.qb;za=lb.rb;
925
- return mb.return({stream:G,type:g,$g:[],aa:d,sc:R,Mb:ea,Wd:Ha,Vd:Xa,sd:!1,gf:-1,qb:bc,rb:za,re:I,Lf:!1})})}function jt(a,b){a=a+b.length-1;var c=-1;if(!b.length)return a++,{qb:a,rb:c};b=b[b.length-1];var d=b.h;if(!b.h.length)return a++,b.s&&(c=0),{qb:a,rb:c};c=d.length-1;d[d.length-1].m||(a++,c=0);return{qb:a,rb:c}}
924
+ return mb.return({stream:G,type:g,$g:[],aa:d,sc:R,Ob:ea,Wd:Ha,Vd:Xa,sd:!1,gf:-1,qb:bc,rb:za,re:I,Lf:!1})})}function jt(a,b){a=a+b.length-1;var c=-1;if(!b.length)return a++,{qb:a,rb:c};b=b[b.length-1];var d=b.h;if(!b.h.length)return a++,b.s&&(c=0),{qb:a,rb:c};c=d.length-1;d[d.length-1].m||(a++,c=0);return{qb:a,rb:c}}
926
925
  function Wt(a,b,c,d,e,f,g,h,k,l,m,n){var q=Jt(c,b)||Kt(c),r=[];if(k){k=t(k.split(","));for(var u=k.next();!u.done;u=k.next())r.push(u.value)}k=void 0;u=null;c==Jb?k=r.includes("public.accessibility.transcribes-spoken-dialog")&&r.includes("public.accessibility.describes-music-and-sound")?"caption":"subtitle":r.includes("public.accessibility.describes-video")&&(u="visually impaired");r.length||"subtitle"!==k||r.push("subtitle");return{id:a.C++,originalId:f,groupId:null,createSegmentIndex:function(){return Promise.resolve()},
927
926
  segmentIndex:null,mimeType:q,codecs:b,kind:c==Jb?"subtitle":void 0,encrypted:!1,drmInfos:[],keyIds:new Set,language:Nb(d||"und"),originalLanguage:d,label:f,type:c,primary:e,trickModeVideo:null,emsgSchemeIdUris:null,frameRate:void 0,pixelAspectRatio:void 0,width:void 0,height:void 0,bandwidth:void 0,roles:r,forced:l,channelsCount:g,audioSamplingRate:m,spatialAudio:n,closedCaptions:h,hdr:void 0,videoLayout:void 0,tilesLayout:void 0,accessibilityPurpose:u,external:!1,fastSwitching:!1}}
928
927
  function ht(a,b){var c=[];if(a.segments){a=t(a.segments);for(var d=a.next();!d.done;d=a.next())d=As(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=xs(g,"METHOD");if("NONE"!=h)if(a=!0,"AES-128"==h)d=!0;else if(h=X(g,"KEYFORMAT")||"identity",g=(h=Ot[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,xh:d}}
929
- function Zt(a,b,c,d,e){if(!window.crypto||!window.crypto.subtle)throw Sa("Web Crypto API is not available to decrypt AES-128. (Web Crypto only exists in secure origins like https)"),new P(2,4,4042);var f=0,g=X(b,"IV","");if(g){var h=gg(g.substr(2));if(16!=h.byteLength)throw new P(2,4,4048);}else f=Ds(c.g,"EXT-X-MEDIA-SEQUENCE",0);var k={method:"AES-128",iv:h,firstMediaSequenceNumber:f,fetchKey:function(){var l,m,n,q,r;return K(function(u){if(1==u.g)return l=Es(d(),xs(b,"URI"),e),m=qf([l],a.g.retryParameters),
928
+ function Zt(a,b,c,d,e){if(!window.crypto||!window.crypto.subtle)throw Sa("Web Crypto API is not available to decrypt AES-128. (Web Crypto only exists in secure origins like https)"),new P(2,4,4042);var f=0,g=X(b,"IV","");if(g){var h=gg(g.substr(2));if(16!=h.byteLength)throw new P(2,4,4048);}else f=Ds(c.g,"EXT-X-MEDIA-SEQUENCE",0);var k={method:"AES-128",iv:h,firstMediaSequenceNumber:f,fetchKey:function(){var l,m,n,q,r;return K(function(u){if(1==u.g)return l=Es(d(),xs(b,"URI"),e),m=qf(l,a.g.retryParameters),
930
929
  D(u,Dt(a,m,6),2);if(3!=u.g){n=u.h;if(!n.data||16!=n.data.byteLength)throw new P(2,4,4049);q={name:"AES-CBC"};r=k;return D(u,window.crypto.subtle.importKey("raw",n.data,q,!0,["decrypt"]),3)}r.cryptoKey=u.h;k.fetchKey=void 0;F(u)})}};return k}
931
930
  function kt(a,b){var c=Infinity,d=b.segments;if(d.length)for(var e=d.length-1;0<=e;){var f=Cs(d[e].g,"EXTINF");if(f){c=Number(f.value.split(",")[0]);break}e--}d=Cs(b.g,"EXT-X-TARGETDURATION");if(!d)throw new P(2,4,4024,"EXT-X-TARGETDURATION");d=Number(d.value);if(e=Cs(b.g,"EXT-X-PART-INF"))a.M=Number(xs(e,"PART-TARGET"));b=Cs(b.g,"EXT-X-SERVER-CONTROL");a.D&&a.M?(a.m=a.Va?5*a.M<=c?Math.min(a.M,a.m):Math.min(c,a.m):Math.min(a.M,a.m),a.ha=b?Number(xs(b,"PART-HOLD-BACK")):0):(a.m=Math.min(c,a.m),c=b?
932
931
  b.getAttribute("HOLD-BACK"):null,a.ea=c?Number(c.value):0);a.sa=Math.max(d,a.sa)}function zt(a,b){if(a.g.defaultPresentationDelay)b=a.g.defaultPresentationDelay;else if(a.ha)b=a.ha;else if(a.ea)b=a.ea;else{b=b.segments.length;var c=a.g.hls.liveSegmentsDelay;c>b-2&&(c=Math.max(1,b-2));b=a.sa*c}a.l.ig(0);a.l.fh(b);a.l.Rc(!1)}
@@ -939,8 +938,8 @@ z[z.length-1].endTime;else return null;v&&(A||0!=z[0].gb?(v=!1,x=null):z=[]);(m=
939
938
  function bu(a,b){var c=0,d=null;b&&(c=b.split("@"),b=Number(c[0]),c=c[1]?Number(c[1]):a.Ma+1,d=c+b-1);return[c,d]}
940
939
  function it(a,b,c,d,e,f){var g=b.segments,h=void 0,k=Ds(b.g,"EXT-X-DISCONTINUITY-SEQUENCE",0),l=Ds(b.g,"EXT-X-MEDIA-SEQUENCE",0),m=Cs(b.g,"EXT-X-SKIP"),n=m?Number(X(m,"SKIPPED-SEGMENTS")):0,q=l+n,r=0;$s(a)&&d.has(q)&&(r=d.get(q));0===r&&a.qa==Et&&0<d.size&&!d.has(q)&&(r=a.l.yb());var u=[],v=null;m=[];for(var y=0;y<g.length;y++){var z=g[y],x=0==y?r:v.endTime;q=l+n+y;Cs(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"==xs(B,
941
940
  "METHOD")?h=Zt(a,B,b,f,e):h=void 0);d.set(q,x);A=Ct(a,b,z.g,f,e);!a.D&&a.i.isAutoLowLatencyMode()&&(a.i.enableLowLatencyMode(),a.D=a.i.isLowLatencyMode());if(x=au(a,A,v,z,x,e,c,f,h))(v=Ds(z.g,"EXT-X-BITRATE"))?m.push({bitrate:v,duration:x.endTime-x.startTime}):m.length&&(v=m.pop(),v.duration+=x.endTime-x.startTime,m.push(v)),v=x,x.j=k,a.g.hls.ignoreManifestProgramDateTime&&null!=a.K&&q<a.K||u.push(x)}b=void 0;m.length&&(b=m.reduce(function(C,E){return C+E.duration},0),b=Math.round(m.reduce(function(C,
942
- E){return C+E.bitrate*E.duration},0)/b*1E3));if(m=u.some(function(C){return null!=C.ma}))for(c={},d=0;d<u.length;c={Vc:c.Vc,Uc:c.Uc,Kd:c.Kd,Rb:c.Rb,Tc:c.Tc},d++)if(c.Rb=u[d],null==c.Rb.ma)for(c.Uc=0,c.Vc=d,e=function(C){return function(){var E=u[C.Vc];if(E){if(null!=E.ma)return E.ma+C.Uc;C.Uc-=E.endTime-E.startTime;C.Vc+=1}return null}}(c),c.Tc=0,c.Kd=d,f=function(C){return function(){var E=u[C.Kd];if(E){E!=C.Rb&&(C.Tc+=E.endTime-E.startTime);if(null!=E.ma)return E.ma+C.Tc;--C.Kd}return null}}(c);null==
943
- c.Rb.ma;)c.Rb.ma=f(),null==c.Rb.ma&&(c.Rb.ma=e());if(m)for(c=t(u),d=c.next();!d.done;d=c.next())for(e=d.value,d=e.ma,e=t(e.h),f=e.next();!f.done;f=e.next())f=f.value,f.ma=d,d+=f.endTime-f.startTime;a=a.U;if(m&&Infinity!=a)for(m=t(u),d=m.next();!d.done;d=m.next())d.value.mg(a);return{segments:u,bandwidth:b}}
941
+ E){return C+E.bitrate*E.duration},0)/b*1E3));if(m=u.some(function(C){return null!=C.ma}))for(c={},d=0;d<u.length;c={Vc:c.Vc,Uc:c.Uc,Kd:c.Kd,Tb:c.Tb,Tc:c.Tc},d++)if(c.Tb=u[d],null==c.Tb.ma)for(c.Uc=0,c.Vc=d,e=function(C){return function(){var E=u[C.Vc];if(E){if(null!=E.ma)return E.ma+C.Uc;C.Uc-=E.endTime-E.startTime;C.Vc+=1}return null}}(c),c.Tc=0,c.Kd=d,f=function(C){return function(){var E=u[C.Kd];if(E){E!=C.Tb&&(C.Tc+=E.endTime-E.startTime);if(null!=E.ma)return E.ma+C.Tc;--C.Kd}return null}}(c);null==
942
+ c.Tb.ma;)c.Tb.ma=f(),null==c.Tb.ma&&(c.Tb.ma=e());if(m)for(c=t(u),d=c.next();!d.done;d=c.next())for(e=d.value,d=e.ma,e=t(e.h),f=e.next();!f.done;f=e.next())f=f.value,f.ma=d,d+=f.endTime-f.startTime;a=a.U;if(m&&Infinity!=a)for(m=t(u),d=m.next();!d.done;d=m.next())d.value.mg(a);return{segments:u,bandwidth:b}}
944
943
  function Jt(a,b){if(a==Jb){if("vtt"==b||"wvtt"==b)return"text/vtt";if(b&&""!==b)return"application/mp4"}return"image"!=a||b&&"jpeg"!=b?"audio"==a&&"mp4a.40.34"==b?"audio/mpeg":"mjpg"==b?"application/mp4":null:"image/jpeg"}function Kt(a){return a==Jb?"text/vtt":cu[a].mp4}
945
944
  function Yt(a,b,c,d,e,f){var g,h,k,l,m,n,q,r,u,v,y,z,x;return K(function(A){switch(A.g){case 1:g=wf;h=Math.trunc((d.segments.length-1)/2);k=Es(f(),d.segments[h].h,e);l=new gb(k[0]);m=l.Wa.split(".").pop();n=cu[b];if((q=n[m])||(q=Bt[m])||(q=Jt(b,c)))return A.return(q);u=1;v=qf(k,a.g.retryParameters);ta(A,2);v.method="HEAD";return D(A,Dt(a,v,g,{type:u}),4);case 4:y=A.h;r=y.headers["content-type"];va(A,3);break;case 2:z=wa(A);if(!z||1002!=z.code&&1001!=z.code){A.F(3);break}v.method="GET";return D(A,
946
945
  Dt(a,v,g,{type:u}),6);case 6:x=A.h,r=x.headers["content-type"];case 3:return r?A.return(r.split(";")[0]):A.return(Kt(b))}})}function yt(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 Ys(a,b,c){return Dt(a,qf(b,a.g.retryParameters),0,{type:c?2:3})}
@@ -948,13 +947,13 @@ function Ws(a){var b,c,d,e,f,g;K(function(h){switch(h.g){case 1:if(!a.i)return h
948
947
  function $s(a){return a.qa!=Xs}function dt(a,b){a.qa=b;a.l&&a.l.Rc(!$s(a));$s(a)||a.u.stop()}function Dt(a,b,c,d){if(!a.P)throw new P(2,7,7001);b=a.i.networkingEngine.request(c,b,d);lf(a.P,b);return b.promise}M("shaka.hls.HlsParser",Vs);
949
948
  var Bt={aac:"audio/aac",ac3:"audio/ac3",ec3:"audio/ec3",mp3:"audio/mpeg"},cu={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",
950
949
  vtt:"text/vtt",webvtt:"text/vtt",ttml:"application/ttml+xml"},image:{jpg:"image/jpeg",png:"image/png",svg:"image/svg+xml",webp:"image/webp",avif:"image/avif"}},Ot={"com.apple.streamingkeydelivery":function(a,b){if("video/mp2t"==b)throw new P(2,4,4040);if(window.shakaMediaKeysPolyfill)throw new P(2,4,4041);return Db("com.apple.fps",[{initDataType:"sinf",initData:new Uint8Array(0),keyId:null}])},"urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":function(a){var b=xs(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;
951
- b=xs(a,"URI");b=Rs(b);b=lc(b.data);b=Db("com.widevine.alpha",[{initDataType:"cenc",initData:b}]);if(a=X(a,"KEYID"))b.keyIds=new Set([a.toLowerCase().substr(2)]);return b},"com.microsoft.playready":function(a){var b=xs(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;a=xs(a,"URI");a=Rs(a);a=lc(a.data);b=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);a=lg(a,b,new Set,0);return Db("com.microsoft.playready",[{initDataType:"cenc",initData:a}])},identity:function(a){a=
952
- xs(a,"METHOD");return["SAMPLE-AES","SAMPLE-AES-CTR"].includes(a)?Db("org.w3.clearkey",null):null}},Xs="VOD",Xt="EVENT",Et="LIVE",ct={sh:Xs,vj:Xt,Dj:Et};yh["application/x-mpegurl"]=function(){return new Vs};yh["application/vnd.apple.mpegurl"]=function(){return new Vs};function du(a){var b=0,c=pc(a),d=c.getUint32(b,!0);if(d!=a.byteLength)return[];a:{a=b+6;for(b=[];a<c.byteLength-1;){d=c.getUint16(a,!0);a+=2;var e=c.getUint16(a,!0);a+=2;if(0!=(e&1)||e+a>c.byteLength){c=[];break a}var f=lc(c,a,e);b.push({type:d,value:f});a+=e}c=b}return c}function eu(a){if(a=fu(a))a:{a=t(a.getElementsByTagName("DATA"));for(var b=a.next();!b.done;b=a.next())if(b=mg(b.value,"LA_URL")){a=b.textContent;break a}a=""}else a="";return a}
953
- function fu(a){a=fg(a.textContent);a=du(a).filter(function(b){return b.type===gu})[0];if(!a)return null;a=Lf(a.value,!0);return(a=Fg(a,"WRMHEADER"))?a:null}var gu=1,hu=(new Map).set("com.microsoft.playready",eu).set("com.microsoft.playready.recommendation",eu).set("com.microsoft.playready.software",eu).set("com.microsoft.playready.hardware",eu);function iu(a){if(!lu){lu=!0;var b=new Uint8Array([105,115,111,109]),c=new Uint8Array([97,118,99,49]),d=new Uint8Array([0,0,0,1]);mu=nu("ftyp",b,d,b,c);b=nu("dref",ou);pu=nu("dinf",b)}this.g=a}
950
+ b=xs(a,"URI");b=Rs(b);b=lc(b.data);b=Db("com.widevine.alpha",[{initDataType:"cenc",initData:b}]);if(a=X(a,"KEYID"))b.keyIds=new Set([a.toLowerCase().substr(2)]);return b},"com.microsoft.playready":function(a){var b=xs(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;a=xs(a,"URI");a=Rs(a);a=lc(a.data);b=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);a=lg(a,b,new Set,0);return Db("com.microsoft.playready",[{initDataType:"cenc",initData:a}])},identity:function(a,
951
+ b){if("video/mp2t"==b)throw new P(2,4,4040);if(window.shakaMediaKeysPolyfill)throw new P(2,4,4041);a=xs(a,"METHOD");return["SAMPLE-AES","SAMPLE-AES-CTR"].includes(a)?Db("org.w3.clearkey",null):null}},Xs="VOD",Xt="EVENT",Et="LIVE",ct={sh:Xs,vj:Xt,Dj:Et};yh["application/x-mpegurl"]=function(){return new Vs};yh["application/vnd.apple.mpegurl"]=function(){return new Vs};function du(a){var b=0,c=pc(a),d=c.getUint32(b,!0);if(d!=a.byteLength)return[];a:{a=b+6;for(b=[];a<c.byteLength-1;){d=c.getUint16(a,!0);a+=2;var e=c.getUint16(a,!0);a+=2;if(0!=(e&1)||e+a>c.byteLength){c=[];break a}var f=lc(c,a,e);b.push({type:d,value:f});a+=e}c=b}return c}function eu(a){if(a=fu(a))a:{a=t(a.getElementsByTagName("DATA"));for(var b=a.next();!b.done;b=a.next())if(b=mg(b.value,"LA_URL")){a=b.textContent;break a}a=""}else a="";return a}
952
+ function fu(a){a=fg(a.textContent);a=du(a).filter(function(b){return b.type===gu})[0];if(!a)return null;a=Lf(a.value,!0);return(a=Fg(a,"WRMHEADER"))?a:null}var gu=1,hu=(new Map).set("com.microsoft.playready",eu).set("com.microsoft.playready.recommendation",eu).set("com.microsoft.playready.software",eu).set("com.microsoft.playready.hardware",eu);function iu(a){if(!ju){ju=!0;var b=new Uint8Array([105,115,111,109]),c=new Uint8Array([97,118,99,49]),d=new Uint8Array([0,0,0,1]);mu=nu("ftyp",b,d,b,c);b=nu("dref",ou);pu=nu("dinf",b)}this.g=a}
954
953
  function qu(a){for(var b=[],c=t(a.g),d=c.next();!d.done;d=c.next()){var e=b,f=e.push;var g=d.value;d=nu;var h=g.id+1;var k=g.stream.width||0,l=g.stream.height||0;"audio"==g.type&&(l=k=0);var m=g.duration*g.timescale,n=Math.floor(m/(ru+1));m=Math.floor(m%(ru+1));h=new Uint8Array([1,0,0,7,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(w(su(h,4)),[0,0,0,0],w(su(n,4)),w(su(m,4)),[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0],w(su(k,2)),[0,0],w(su(l,
955
954
  2)),[0,0]));h=nu("tkhd",h);k=nu;n=g.duration*g.timescale;l=Math.floor(n/(ru+1));n=Math.floor(n%(ru+1));m=g.stream.language;m=m.charCodeAt(0)-96<<10|m.charCodeAt(1)-96<<5|m.charCodeAt(2)-96;l=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(w(su(g.timescale,4)),w(su(l,4)),w(su(n,4)),w(su(m,2)),[0,0]));l=nu("mdhd",l);n=g;m=new Uint8Array([]);switch(n.type){case "video":m=tu;break;case "audio":m=uu}n=nu("hdlr",m);a:{switch(g.type){case "video":g=nu("minf",nu("vmhd",vu),pu,wu(g));break a;
956
- case "audio":g=nu("minf",nu("smhd",xu),pu,wu(g));break a}g=new Uint8Array([])}g=k("mdia",l,n,g);d=d("trak",h,g);f.call(e,d)}b=jg.apply(cg,w(b));f=a.g[0];c=nu;d=f.duration*f.timescale;e=Math.floor(d/(ru+1));d=Math.floor(d%(ru+1));e=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(w(su(f.timescale,4)),w(su(e,4)),w(su(d,4)),[0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,
957
- 255]));e=nu("mvhd",e);d=[];a=t(a.g);for(k=a.next();!k.done;k=a.next())g=d,h=g.push,k=new Uint8Array([0,0,0,0].concat(w(su(k.value.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1])),k=nu("trex",k),h.call(g,k);a=jg.apply(cg,w(d));a=nu("mvex",a);d=[];if(f.encrypted){f=t(f.stream.drmInfos);for(g=f.next();!g.done;g=f.next())if(g=g.value,g.initData)for(g=t(g.initData),h=g.next();!h.done;h=g.next())d.push(h.value.initData);f=jg.apply(cg,w(d))}else f=new Uint8Array([]);a=c("moov",e,b,a,f);b=new Uint8Array(mu.byteLength+
955
+ case "audio":g=nu("minf",nu("smhd",xu),pu,wu(g));break a}g=new Uint8Array([])}g=k("mdia",l,n,g);d=d("trak",h,g);f.call(e,d)}b=ig.apply(cg,w(b));f=a.g[0];c=nu;d=f.duration*f.timescale;e=Math.floor(d/(ru+1));d=Math.floor(d%(ru+1));e=new Uint8Array([1,0,0,0,0,0,0,0,0,0,0,2,0,0,0,0,0,0,0,3].concat(w(su(f.timescale,4)),w(su(e,4)),w(su(d,4)),[0,1,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,64,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,255,255,255,
956
+ 255]));e=nu("mvhd",e);d=[];a=t(a.g);for(k=a.next();!k.done;k=a.next())g=d,h=g.push,k=new Uint8Array([0,0,0,0].concat(w(su(k.value.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,1,0,1])),k=nu("trex",k),h.call(g,k);a=ig.apply(cg,w(d));a=nu("mvex",a);d=[];if(f.encrypted){f=t(f.stream.drmInfos);for(g=f.next();!g.done;g=f.next())if(g=g.value,g.initData)for(g=t(g.initData),h=g.next();!h.done;h=g.next())d.push(h.value.initData);f=ig.apply(cg,w(d))}else f=new Uint8Array([]);a=c("moov",e,b,a,f);b=new Uint8Array(mu.byteLength+
958
957
  a.byteLength);b.set(mu);b.set(a,mu.byteLength);return b}
959
958
  function wu(a){var b=nu,c=new Uint8Array([]);switch(a.type){case "video":if(a.codecs.includes("avc1")){c=a.stream.width||0;var d=a.stream.height||0;if(0<a.Ba.byteLength)var e=nu("avcC",a.Ba);else{e=nu;for(var f=7,g=[],h=[],k=0,l=0,m=0,n=0;n<a.hb.length;n++){var q=yu(a.hb[n]);switch(q[0]&31){case 7:g.push(q);f+=q.length+2;break;case 8:h.push(q),f+=q.length+2}}0<g.length&&(k=g[0][1],m=g[0][2],l=g[0][3]);f=new Uint8Array(f);n=0;f[n++]=1;f[n++]=k;f[n++]=m;f[n++]=l;f[n++]=255;f[n++]=224|g.length;for(k=
960
959
  0;k<g.length;k++)f[n++]=(g[k].length&65280)>>8,f[n++]=g[k].length&255,f.set(g[k],n),n+=g[k].length;f[n++]=h.length;for(g=0;g<h.length;g++)f[n++]=(h[g].length&65280)>>8,f[n++]=h[g].length&255,f.set(h[g],n),n+=h[g].length;e=e("avcC",f)}c=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0].concat(w(su(c,2)),w(su(d,2)),[0,72,0,0,0,72,0,0,0,0,0,0,0,1,19,118,105,100,101,111,106,115,45,99,111,110,116,114,105,98,45,104,108,115,0,0,0,0,0,0,0,0,0,0,0,0,0,24,17,17]));d="avc1";h=zu(a);g=new Uint8Array([]);
@@ -966,15 +965,15 @@ function Au(a){var b=nu;var c=a.codecs.substring(0,a.codecs.indexOf("."));for(va
966
965
  0,0,0,0,0,1,8]);f=nu("tenc",a,f);return b("sinf",c,d,e("schi",f))}
967
966
  function Hu(a){var b=[];a=t(a.g);for(var c=a.next();!c.done;c=a.next()){c=c.value;var d=b.push,e=d.apply;var f=nu;var g=new Uint8Array([0,0,0,0].concat(w(su(c.data?c.data.Ab:0,4))));g=nu("mfhd",g);var h;var k=c.data?c.data.eb:[];var l=new Uint8Array(4+k.length);for(h=0;h<k.length;h++){var m=k[h].flags;l[h+4]=m.Za<<4|m.ab<<2|m.$a}k=nu("sdtp",l);var n=k.length+92;l=nu;h=new Uint8Array([0,0,0,58].concat(w(su(c.id+1,4)),[0,0,0,1,0,0,0,0,0,0,0,0,0,0,0,0]));h=nu("tfhd",h);m=c.data?c.data.baseMediaDecodeTime:
968
967
  0;var q=Math.floor(m%(ru+1));m=new Uint8Array([1,0,0,0].concat(w(su(Math.floor(m/(ru+1)),4)),w(su(q,4))));m=nu("tfdt",m);var r=n;n=c.data?c.data.eb:[];q=n.length;var u=12+16*q,v=new Uint8Array(u);r+=8+u;v.set(["video"===c.type?1:0,0,15,1].concat(w(su(q,4)),w(su(r,4))),0);for(r=0;r<q;r++){var y=n[r];u=su(y.duration,4);var z=su(y.size,4),x=y.flags;y=su(y.jb,4);v.set([].concat(w(u),w(z),[x.mb<<2|x.Za,x.ab<<6|x.$a<<4|x.ob,x.Ya&61440,x.Ya&15],w(y)),12+16*r)}n=nu("trun",v);k=l("traf",h,m,n,k);f=f("moof",
969
- g,k);e.call(d,b,[f,Iu(c)])}return jg.apply(cg,w(b))}function Iu(a){a=(a.data?a.data.eb:[]).map(function(b){return b.data});a=jg.apply(cg,w(a));return nu("mdat",a)}function su(a,b){var c=[];for(--b;0<=b;b--)c.push(a>>8*b&255);return c}function yu(a){for(var b=new Uint8Array(a.length/2),c=0;c<a.length/2;c+=1)b[c]=parseInt(String(a[2*c]+a[2*c+1]),16);return b}
968
+ g,k);e.call(d,b,[f,Iu(c)])}return ig.apply(cg,w(b))}function Iu(a){a=(a.data?a.data.eb:[]).map(function(b){return b.data});a=ig.apply(cg,w(a));return nu("mdat",a)}function su(a,b){var c=[];for(--b;0<=b;b--)c.push(a>>8*b&255);return c}function yu(a){for(var b=new Uint8Array(a.length/2),c=0;c<a.length/2;c+=1)b[c]=parseInt(String(a[2*c]+a[2*c+1]),16);return b}
970
969
  function nu(a){var b=Ga.apply(1,arguments),c=Ju[a];c||(c=[a.charCodeAt(0),a.charCodeAt(1),a.charCodeAt(2),a.charCodeAt(3)],Ju[a]=c);for(var d=8,e=b.length-1;0<=e;e--)d+=b[e].byteLength;e=new Uint8Array(d);e[0]=d>>24&255;e[1]=d>>16&255;e[2]=d>>8&255;e[3]=d&255;e.set(c,4);c=0;for(d=8;c<b.length;c++)e.set(b[c],d),d+=b[c].byteLength;return e}
971
- var lu=!1,ru=Math.pow(2,32)-1,Ju={},tu=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),uu=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]),Du=new Uint8Array([0,0,0,0,0,0,0,0]),Eu=new Uint8Array([0,0,0,0,0,0,0,0]),Gu=new Uint8Array([0,0,0,0,0,0,0,0]),Fu=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),vu=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0]),xu=new Uint8Array([0,
970
+ var ju=!1,ru=Math.pow(2,32)-1,Ju={},tu=new Uint8Array([0,0,0,0,0,0,0,0,118,105,100,101,0,0,0,0,0,0,0,0,0,0,0,0,86,105,100,101,111,72,97,110,100,108,101,114,0]),uu=new Uint8Array([0,0,0,0,0,0,0,0,115,111,117,110,0,0,0,0,0,0,0,0,0,0,0,0,83,111,117,110,100,72,97,110,100,108,101,114,0]),Du=new Uint8Array([0,0,0,0,0,0,0,0]),Eu=new Uint8Array([0,0,0,0,0,0,0,0]),Gu=new Uint8Array([0,0,0,0,0,0,0,0]),Fu=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0]),vu=new Uint8Array([0,0,0,1,0,0,0,0,0,0,0,0]),xu=new Uint8Array([0,
972
971
  0,0,0,0,0,0,0]),Cu=new Uint8Array([0,0,0,0,0,0,0,1]),mu=new Uint8Array([]),ou=new Uint8Array([0,0,0,0,0,0,0,1,0,0,0,12,117,114,108,32,0,0,0,1]),pu=new Uint8Array([]);function Ku(){var a=this;this.h=this.g=null;this.l=[];this.j=null;this.u=1;this.i=null;this.D=new $b(5);this.s=new vd(function(){Lu(a)});this.C=new kf;this.m=new Map}p=Ku.prototype;p.configure=function(a){this.g=a};p.start=function(a,b){var c=this;return K(function(d){if(1==d.g)return c.l=[a],c.h=b,D(d,Mu(c),2);if(!c.h)throw new P(2,7,7001);return d.return(c.j)})};
973
972
  function Lu(a){var b;K(function(c){switch(c.g){case 1:return ta(c,2),D(c,Mu(a),4);case 4:va(c,3);break;case 2:b=wa(c),a.h&&(b.severity=1,a.h.onError(b));case 3:if(!a.h)return c.return();F(c)}})}p.stop=function(){this.g=this.h=null;this.l=[];this.j=null;null!=this.s&&(this.s.stop(),this.s=null);this.m.clear();return this.C.destroy()};
974
973
  p.update=function(){var a=this,b;return K(function(c){if(1==c.g)return ta(c,2),D(c,Mu(a),4);if(2!=c.g)return va(c,0);b=wa(c);if(!a.h||!b)return c.return();a.h.onError(b);F(c)})};p.onExpirationUpdated=function(){};p.onInitialVariantChosen=function(){};p.banLocation=function(){};
975
974
  function Mu(a){var b,c,d,e,f,g,h;return K(function(k){if(1==k.g)return b=qf(a.l,a.g.retryParameters),c=a.h.networkingEngine,d=Date.now(),e=c.request(0,b,{type:5}),lf(a.C,e),D(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=Hg(f.data,"SmoothStreamingMedia");if(!m)throw new P(2,4,4046,l);(l=a.g.mss.manifestPreprocessor)&&l(m);a.i||(a.i=new jj(null,0));if(l=vg(m,"IsLive",Dg,!1))throw new P(2,4,4047);a.i.Rc(!l);var n=vg(m,"TimeScale",Bg,1E7),
976
975
  q=vg(m,"DVRWindowLength",Bg);l&&(0===q||isNaN(q))&&(q=Infinity);var r=vg(m,"CanSeek",Dg,!1);0===q&&r&&(q=Infinity);r=null;q&&0<q&&(r=q/n);l&&!isNaN(a.g.availabilityWindowOverride)&&(r=a.g.availabilityWindowOverride);null==r&&(r=Infinity);a.i.Ge(r);q=vg(m,"Duration",Bg,Infinity);l||a.i.fb(q/n);l={variants:[],textStreams:[],timescale:n,duration:q/n};r=ng(m,"Protection");var u;n=a.g.mss.keySystemsBySystemId;q=[];r=t(r);for(u=r.next();!u.done;u=r.next())q=q.concat(ng(u.value,"ProtectionHeader"));if(q.length){r=
977
- [];for(u=0;u<q.length;u++){var v=q[u],y=v.getAttribute("SystemID").toLowerCase(),z=n[y];if(z){var x=fu(v);if(x)a:{x=t(x.getElementsByTagName("DATA"));for(var A=x.next();!A.done;A=x.next())if(A=mg(A.value,"KID")){x=fg(A.textContent);x=new Uint8Array([x[3],x[2],x[1],x[0],x[5],x[4],x[7],x[6]].concat(w(x.slice(8))));x=ig(x);break a}x=null}else x=null;A=fg(v.textContent);y=gg(y.replace(/-/g,""));y=[{initData:lg(A,y,new Set,0),initDataType:"cenc",keyId:x}];y=Db(z,y);x&&y.keyIds.add(x);if(z=hu.get(z))y.licenseServerUri=
976
+ [];for(u=0;u<q.length;u++){var v=q[u],y=v.getAttribute("SystemID").toLowerCase(),z=n[y];if(z){var x=fu(v);if(x)a:{x=t(x.getElementsByTagName("DATA"));for(var A=x.next();!A.done;A=x.next())if(A=mg(A.value,"KID")){x=fg(A.textContent);x=new Uint8Array([x[3],x[2],x[1],x[0],x[5],x[4],x[7],x[6]].concat(w(x.slice(8))));x=hg(x);break a}x=null}else x=null;A=fg(v.textContent);y=gg(y.replace(/-/g,""));y=[{initData:lg(A,y,new Set,0),initDataType:"cenc",keyId:x}];y=Db(z,y);x&&y.keyIds.add(x);if(z=hu.get(z))y.licenseServerUri=
978
977
  z(v);r.push(y)}}n=r}else n=[];u=n;r=[];n=[];q=[];m=ng(m,"StreamIndex");m=t(m);for(v=m.next();!v.done;v=m.next()){v=v.value;z=ng(v,"QualityLevel");y=l.timescale;x=l.duration;A=ng(v,"c");for(var B=[],C=0,E=0;E<A.length;++E){var H=A[E],G=A[E+1],I=vg(H,"t",Bg),J=vg(H,"d",Bg);H=vg(H,"r",zg);if(!J)break;I=null!=I?I:C;H=H||0;if(0>H)if(G){G=vg(G,"t",Bg);if(null==G)break;else if(I>=G)break;H=Math.ceil((G-I)/J)-1}else{if(Infinity==x)break;else if(I/y>=x)break;H=Math.ceil((x*y-I)/J)-1}for(G=0;G<=H;++G)C=I+J,
979
978
  B.push({start:I/y,end:C/y,ug:I}),I=C}y=B;z=t(z);for(x=z.next();!x.done;x=z.next())(x=Nu(a,v,x.value,y,u,l))&&("audio"!=x.type||a.g.disableAudio?"video"!=x.type||a.g.disableVideo?x.type!=Jb||a.g.disableText||q.push(x):n.push(x):r.push(x))}m=[];r=t(0<r.length?r:[null]);for(u=r.next();!u.done;u=r.next())for(u=u.value,v=t(0<n.length?n:[null]),x=v.next();!x.done;x=v.next())z=m,y=z.push,x=x.value,A=0,u&&u.bandwidth&&0<u.bandwidth&&(A+=u.bandwidth),x&&x.bandwidth&&0<x.bandwidth&&(A+=x.bandwidth),x={id:a.u++,
980
979
  language:u?u.language:"und",disabledUntilTime:0,primary:!!u&&u.primary||!!x&&x.primary,audio:u,video:x,bandwidth:A,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},y.call(z,x);l.variants=m;l.textStreams=q;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,
@@ -1040,13 +1039,13 @@ p.onInitialVariantChosen=function(){};p.banLocation=function(){};yh["application
1040
1039
  function gw(a,b){var c=new Dv;return df(void 0).Da(function(){return c.init()}).Da(function(){return Hv(c,b.pb(),b.La())}).Da(function(d){return d.getSegments([b.key()])}).Da(function(d){return{uri:b,data:d[0].data,headers:{}}}).finally(function(){return c.destroy()})}M("shaka.offline.OfflineScheme",ew);ew.plugin=fw;nf("offline",fw);function hw(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),q=n.next();!q.done;q=n.next()){q=q.value;for(var r=!1,u=t(m),v=u.next();!v.done;v=u.next())if(v=v.value,iw(v.info,q)){v.sessionIds.push(q.sessionId);r=!0;break}r||m.push({info:q,sessionIds:[q.sessionId]})}e=t(m);f=e.next();case 2:if(f.done){l.F(4);break}g=f.value;h=jw(a,b,g);return D(l,h,5);case 5:k=l.h;d=d.concat(k);f=e.next();l.F(2);break;case 4:return l.return(d)}})}
1041
1040
  function jw(a,b,c){var d,e;return K(function(f){switch(f.g){case 1:return d=new Ig({tc:b,onError:function(){},ze:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),ta(f,2),d.configure(a),D(f,Qg(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),D(f,d.destroy(),5);case 5:return f.return([]);case 3:return e=[],D(f,Promise.all(c.sessionIds.map(function(g){return K(function(h){if(1==
1042
1041
  h.g)return ta(h,2),D(h,bh(d,g),4);if(2!=h.g)return e.push(g),va(h,0);wa(h);F(h)})})),6);case 6:return D(f,d.destroy(),7);case 7:return f.return(e)}})}function iw(a,b){function c(d,e){return d.robustness==e.robustness&&d.contentType==e.contentType}return a.keySystem==b.keySystem&&a.licenseUri==b.licenseUri&&wc(a.audioCapabilities,b.audioCapabilities,c)&&wc(a.videoCapabilities,b.videoCapabilities,c)};function kw(a,b,c){var d=b.presentationTimeline.getDuration();b=lw(b);return{offlineUri:null,originalManifestUri:a,duration:d,size:0,expiration:Infinity,tracks:b,appMetadata:c,isIncomplete:!1}}function mw(a,b){var c=Zv(new Yv(a.pb(),a.La()),b),d=b.appMetadata||{};c=lw(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}}
1043
- function lw(a){var b=[],c=qe(a.variants);c=t(c);for(var d=c.next();!d.done;d=c.next())b.push(he(d.value));a=t(a.textStreams);for(c=a.next();!c.done;c=a.next())b.push(ie(c.value));return b};function nw(){this.g={}}function ow(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 pw(a,b){a.g[b.id]=b.bandwidth||2048}function qw(a,b){a=a.g[b];null==a&&(a=0);return a};function rw(a){var b=this;if(a&&a.constructor!=V)throw new P(2,9,9008);this.g=this.h=null;a?(this.h=a.h,this.g=a.Xb()):(this.h=Jl(),this.g=new mf);this.i=[];this.j=[];var c=!a;this.l=new yf(function(){var d,e,f,g,h;return K(function(k){switch(k.g){case 1:return D(k,Promise.all(b.j.map(function(l){return nv(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 D(k,Promise.all(e),3);case 3:if(!c){k.F(4);break}return D(k,b.g.destroy(),4);
1044
- case 4:b.h=null,b.g=null,F(k)}})})}function sw(){if(wd())a:{var a=t(Ev.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}p=rw.prototype;p.destroy=function(){return this.l.destroy()};p.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=zl(a,b));return Ll(this.h,a)};p.getConfiguration=function(){var a=Jl();Ll(a,this.h,Jl());return a};p.Xb=function(){return this.g};
1042
+ function lw(a){var b=[],c=qe(a.variants);c=t(c);for(var d=c.next();!d.done;d=c.next())b.push(he(d.value));a=t(a.textStreams);for(c=a.next();!c.done;c=a.next())b.push(ie(c.value));return b};function nw(){this.g={}}function ow(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 pw(a,b){a.g[b.id]=b.bandwidth||2048}function qw(a,b){a=a.g[b];null==a&&(a=0);return a};function rw(a){var b=this;if(a&&a.constructor!=V)throw new P(2,9,9008);this.g=this.h=null;a?(this.h=a.h,this.g=a.Yb()):(this.h=Jl(),this.g=new mf);this.i=[];this.j=[];var c=!a;this.l=new yf(function(){var d,e,f,g,h;return K(function(k){switch(k.g){case 1:return D(k,Promise.all(b.j.map(function(l){return nv(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 D(k,Promise.all(e),3);case 3:if(!c){k.F(4);break}return D(k,b.g.destroy(),4);
1043
+ case 4:b.h=null,b.g=null,F(k)}})})}function sw(){if(wd())a:{var a=t(Ev.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}p=rw.prototype;p.destroy=function(){return this.l.destroy()};p.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=zl(a,b));return Ll(this.h,a)};p.getConfiguration=function(){var a=Jl();Ll(a,this.h,Jl());return a};p.Yb=function(){return this.g};
1045
1044
  p.store=function(a,b,c){var d=this,e=this.getConfiguration(),f=new mv(this.g);this.j.push(f);b=tw(this,a,b||{},function(){var g;return K(function(h){if(1==h.g)return c?h.F(2):D(h,Lk(a,d.g,e.manifest.retryParameters),3);2!=h.g&&(c=h.h);g=xh(a,c||null);return h.return(g())})},e,f);b=new af(b,function(){return nv(f)});b.finally(function(){vc(d.j,f)});return uw(this,b)};
1046
1045
  function tw(a,b,c,d,e,f){var g,h,k,l,m,n,q,r,u,v,y,z,x,A;return K(function(B){switch(B.g){case 1:return vw(),h=g=null,k=new Dv,n=m=l=null,ta(B,2,3),D(B,d(),5);case 5:return g=B.h,D(B,ww(a,b,g,e),6);case 6:q=B.h;xw(a);r=!q.presentationTimeline.R()&&!q.presentationTimeline.pc();if(!r)throw new P(2,9,9005,b);return D(B,yw(a,q,function(C){n=n||C},e),7);case 7:h=B.h;xw(a);if(n)throw n;return D(B,zw(q,h,e),8);case 8:return D(B,k.init(),9);case 9:return xw(a),D(B,Fv(k),10);case 10:return l=B.h,xw(a),u=Aw(h,
1047
1046
  q,b,c,e,f),v=u.Gi,y=u.og,D(B,l.La.addManifests([v]),11);case 11:z=B.h;xw(a);m=z[0];xw(a);if(n)throw n;return D(B,Bw(a,y,m,v,f,e,l.La,q,h),12);case 12:return xw(a),Cw(q,v,h,e),D(B,l.La.updateManifest(m,v),13);case 13:return xw(a),x=new Wv("manifest",l.path.pb,l.path.La,m),B.return(mw(x,v));case 3:return xa(B),D(B,k.destroy(),14);case 14:if(!g){B.F(15);break}return D(B,g.stop(),15);case 15:if(!h){B.F(17);break}return D(B,h.destroy(),17);case 17:ya(B,0);break;case 2:A=wa(B);if(null==m){B.F(19);break}return D(B,
1048
1047
  Dw(m),19);case 19:throw n||A;}})}
1049
- function Bw(a,b,c,d,e,f,g,h,k){var l,m,n,q,r,u,v,y,z,x;return K(function(A){switch(A.g){case 1:l={};m=0;n=function(B,C){var E,H,G,I,J,L,N;return K(function(R){if(1==R.g){E={};H=t(B);for(G=H.next();!G.done;E={ec:E.ec},G=H.next())E.ec=G.value,I=jv(E.ec,f),J=E.ec.i,L=E.ec.h,N=function(T){return function(ea){var Z,fa,Ha;return K(function(Xa){if(1==Xa.g)return D(Xa,g.addSegments([{data:ea}]),2);Z=Xa.h;xw(a);fa=T.ec.g;Ha=iv(fa);l[Ha]=Z[0];m+=ea.byteLength;F(Xa)})}}(E),pv(e,E.ec.groupId,I,J,L,N);return D(R,
1048
+ function Bw(a,b,c,d,e,f,g,h,k){var l,m,n,q,r,u,v,y,z,x;return K(function(A){switch(A.g){case 1:l={};m=0;n=function(B,C){var E,H,G,I,J,L,N;return K(function(R){if(1==R.g){E={};H=t(B);for(G=H.next();!G.done;E={fc:E.fc},G=H.next())E.fc=G.value,I=jv(E.fc,f),J=E.fc.i,L=E.fc.h,N=function(T){return function(ea){var Z,fa,Ha;return K(function(Xa){if(1==Xa.g)return D(Xa,g.addSegments([{data:ea}]),2);Z=Xa.h;xw(a);fa=T.fc.g;Ha=iv(fa);l[Ha]=Z[0];m+=ea.byteLength;F(Xa)})}}(E),pv(e,E.fc.groupId,I,J,L,N);return D(R,
1050
1049
  rv(e),2)}if(!C)return R.F(0);xw(a);Cw(h,d,k,f);return D(R,g.updateManifest(c,d),0)})};q=!1;ta(A,2);if(!Ew(h)||!q||Fw(h)){A.F(4);break}return D(A,n(b.filter(function(B){return B.h}),!0),5);case 5:return xw(a),b=b.filter(function(B){return!B.h}),r=l,u=m,l={},m=0,D(A,Gw(g,c,d,r,u,function(){return xw(a)}),6);case 6:xw(a);case 4:if(q){A.F(7);break}return D(A,n(b,!1),8);case 8:return xw(a),v=l,y=m,l={},m=0,D(A,Gw(g,c,d,v,y,function(){return xw(a)}),9);case 9:xw(a);case 7:va(A,0);break;case 2:return z=
1051
1050
  wa(A),x=Object.values(l),D(A,g.removeSegments(x,function(){}),10);case 10:throw z;}})}function Dw(a){var b,c,d,e;return K(function(f){switch(f.g){case 1:return b=new Dv,D(f,b.init(),2);case 2:return D(f,Fv(b),3);case 3:return c=f.h,d=new Wv("manifest",c.path.pb,c.path.La,a),D(f,b.destroy(),4);case 4:return e=new rw,D(f,e.remove(d.toString()),0)}})}
1052
1051
  function Gw(a,b,c,d,e,f){var g,h,k,l,m,n,q,r,u,v,y;return K(function(z){switch(z.g){case 1:g=!1;ta(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),q=n.next();!q.done;q=n.next())r=q.value,u=r.pendingSegmentRefId?d[r.pendingSegmentRefId]:null,null!=u&&(r.dataKey=u,r.pendingSegmentRefId=void 0),u=r.pendingInitSegmentRefId?d[r.pendingInitSegmentRefId]:null,null!=u&&(r.initSegmentKey=u,r.pendingInitSegmentRefId=void 0),r.pendingSegmentRefId&&(h=!1),r.pendingInitSegmentRefId&&
@@ -1072,7 +1071,7 @@ function Kw(a,b){return K(function(c){if(1==c.g)return a.i.push(b),ua(c,2),D(c,b
1072
1071
  function Pw(a,b,c,d){var e,f,g;return K(function(h){if(1==h.g){if(!d.drmInfo)return h.return();e=Jv(c);f=d.sessionIds.map(function(k){return{sessionId:k,keySystem:d.drmInfo.keySystem,licenseUri:d.drmInfo.licenseServerUri,serverCertificate:d.drmInfo.serverCertificate,audioCapabilities:Ow(d,!1),videoCapabilities:Ow(d,!0)}});return D(h,hw(b,a,f),2)}return 3!=h.g?(g=h.h,D(h,e.remove(g),3)):D(h,e.add(f.filter(function(k){return!g.includes(k.sessionId)})),0)})}
1073
1072
  function Tw(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}
1074
1073
  function Hw(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());}M("shaka.offline.Storage",rw);rw.deleteAll=function(){var a;return K(function(b){return 1==b.g?(a=new Dv,ua(b,2),D(b,Kv(a),2)):5!=b.g?(xa(b),D(b,a.destroy(),5)):ya(b,0)})};
1075
- rw.prototype.list=rw.prototype.list;rw.prototype.removeEmeSessions=rw.prototype.Ui;rw.prototype.remove=rw.prototype.remove;rw.prototype.store=rw.prototype.store;rw.prototype.getNetworkingEngine=rw.prototype.Xb;rw.prototype.getConfiguration=rw.prototype.getConfiguration;rw.prototype.configure=rw.prototype.configure;rw.prototype.destroy=rw.prototype.destroy;rw.support=sw;
1074
+ rw.prototype.list=rw.prototype.list;rw.prototype.removeEmeSessions=rw.prototype.Ui;rw.prototype.remove=rw.prototype.remove;rw.prototype.store=rw.prototype.store;rw.prototype.getNetworkingEngine=rw.prototype.Yb;rw.prototype.getConfiguration=rw.prototype.getConfiguration;rw.prototype.configure=rw.prototype.configure;rw.prototype.destroy=rw.prototype.destroy;rw.support=sw;
1076
1075
  var Iw=(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");
1077
1076
  wn.offline=sw;function Ww(){}function Xw(){for(var a=t(Yw),b=a.next();!b.done;b=a.next()){b=b.value;try{b.Ah()}catch(c){Sa("Error installing polyfill!",c)}}}function Zw(a,b){a={priority:b||0,Ah:a};for(b=0;b<Yw.length;b++)if(Yw[b].priority<a.priority){Yw.splice(b,0,a);return}Yw.push(a)}M("shaka.polyfill",Ww);Ww.register=Zw;Ww.installAll=Xw;var Yw=[];function $w(){this.g=new ax}function bx(){window.AbortController||(window.AbortController=$w,window.AbortSignal=ax)}$w.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 O("abort");if(b.onabort)b.onabort(a);b.dispatchEvent(a)}};da.Object.defineProperties($w.prototype,{signal:{configurable:!0,enumerable:!0,get:function(){return this.g}}});Ww.AbortController=$w;$w.install=bx;
1078
1077
  function ax(){ab.call(this);this.h=!1;this.g=void 0;this.onabort=null}pa(ax,ab);da.Object.defineProperties(ax.prototype,{aborted:{configurable:!0,enumerable:!0,get:function(){return this.h}},reason:{configurable:!0,enumerable:!0,get:function(){return this.g}}});Zw(bx);function cx(){}function dx(){if(!Object.getOwnPropertyDescriptor(Element.prototype,"ariaHidden"))for(var a=t(["ariaHidden","ariaLabel","ariaPressed","ariaSelected"]),b=a.next();!b.done;b=a.next())ex(b.value)}function ex(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)}})}Ww.Aria=cx;cx.install=dx;Zw(dx);function fx(){}function gx(){hx()}Ww.EncryptionScheme=fx;fx.install=gx;Zw(gx,-2);function ix(){}
@@ -1083,180 +1082,180 @@ function ox(a){var b,c,d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A;return K(function(B){sw
1083
1082
  (C+="; eotf=smpte2084");e=cast.__platform__.canDisplayType(C)}else e=dc(c.contentType);else Cd()?(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=dc(f)):e=dc(c.contentType);if(!e)return B.return(b)}if(d&&(Gd()&&d.spatialRendering?(h=d.contentType+"; spatialRendering=true",g=dc(h)):g=dc(d.contentType),!g))return B.return(b)}else if("file"==a.type){if(c&&(k=c.contentType,l=xd(k),
1084
1083
  !l)||d&&(m=d.contentType,n=xd(m),!n))return B.return(b)}else return B.return(b);if(!a.keySystemConfiguration)return b.supported=!0,B.return(Promise.resolve(b));q=a.keySystemConfiguration;r=[];u=[];q.audio&&(v={robustness:q.audio.robustness||"",contentType:a.audio.contentType},Cd()&&a.audio.contentType.includes('codecs="ac-3"')&&(v={robustness:v.robustness,contentType:'audio/mp4; codecs="ec-3"'}),r.push(v));q.video&&(y={robustness:q.video.robustness||"",contentType:a.video.contentType},u.push(y));
1085
1084
  z={initDataTypes:[q.initDataType],distinctiveIdentifier:q.distinctiveIdentifier,persistentState:q.persistentState,sessionTypes:q.sessionTypes};r.length&&(z.audioCapabilities=r);u.length&&(z.videoCapabilities=u);x=(a.video?a.video.contentType:"")+"#"+(a.audio?a.audio.contentType:"")+"#"+a.keySystemConfiguration.keySystem;ta(B,3);if(x in px){A=px[x];B.F(5);break}return D(B,navigator.requestMediaKeySystemAccess(q.keySystem,[z]),6);case 6:A=B.h,px[x]=A;case 5:va(B,4);break;case 3:wa(B);case 4:A&&(b.supported=
1086
- !0,b.keySystemAccess=A);case 2:return B.return(b)}})}Ww.MediaCapabilities=lx;lx.install=mx;var nx=null;lx.originalMcap=nx;var px={};lx.memoizedMediaKeySystemAccessRequests_=px;Zw(mx,-1);function qx(){}function rx(){var a=Jd();window.MediaSource&&(window.cast&&cast.__platform__&&cast.__platform__.canDisplayType?sx():a?10>=a?window.MediaSource=null:12>=a?(tx(),ux()):15>=a&&tx():zd()?vx():(Ed()||Dd()||Bd("Tizen 4"))&&wx());window.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&xx()}
1087
- function tx(){var a=MediaSource.prototype.addSourceBuffer;MediaSource.prototype.addSourceBuffer=function(){var b=a.apply(this,Ga.apply(0,arguments));b.abort=function(){};return b}}function ux(){var a=SourceBuffer.prototype.remove;SourceBuffer.prototype.remove=function(b,c){return a.call(this,b,c-.001)}}function vx(){var a=MediaSource.isTypeSupported;MediaSource.isTypeSupported=function(b){return"mp2t"!=b.split(";")[0].split("/")[1]&&a(b)}}
1088
- function wx(){var a=MediaSource.isTypeSupported;MediaSource.isTypeSupported=function(b){return"opus"!=gd(b)[0]&&a(b)}}function sx(){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)}}
1089
- function xx(){var a=MediaSource.isTypeSupported;Bd("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)})}Ww.MediaSource=qx;qx.install=rx;Zw(rx);function yx(){}function zx(){screen.orientation&&screen.orientation.unlock||(void 0!=screen.orientation?Ax():void 0!=window.orientation&&Bx())}function Ax(){void 0===screen.orientation.lock&&(screen.orientation.lock=function(){return Promise.resolve()});void 0===screen.orientation.unlock&&(screen.orientation.unlock=function(){})}
1090
- function Bx(){function a(){switch(window.orientation){case -90:b.type="landscape-secondary";b.angle=270;break;case 0:b.type="portrait-primary";b.angle=0;break;case 90:b.type="landscape-primary";b.angle=90;break;case 180:b.type="portrait-secondary",b.angle=180}}var b=new Cx;screen.orientation=b;a();window.addEventListener("orientationchange",function(){a();var c=new O("change");b.dispatchEvent(c)})}Ww.Orientation=yx;yx.install=zx;function Cx(){ab.call(this);this.type="";this.angle=0}pa(Cx,ab);
1091
- Cx.prototype.lock=function(a){function b(d){return screen.lockOrientation?screen.lockOrientation(d):screen.mozLockOrientation?screen.mozLockOrientation(d):screen.msLockOrientation?screen.msLockOrientation(d):!1}var c=!1;switch(a){case "natural":c=b("default");break;case "any":c=!0;this.unlock();break;default:c=b(a)}if(c)return Promise.resolve();a=Error("screen.orientation.lock() is not available on this device");a.name="NotSupportedError";a.code=DOMException.NOT_SUPPORTED_ERR;return Promise.reject(a)};
1092
- Cx.prototype.unlock=function(){screen.unlockOrientation?screen.unlockOrientation():screen.mozUnlockOrientation?screen.mozUnlockOrientation():screen.msUnlockOrientation&&screen.msUnlockOrientation()};Zw(zx);function Dx(){}var Ex,Fx,Gx,Hx,Ix,Jx;function Kx(a,b){try{var c=new Lx(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}}function Mx(a){var b=this.mediaKeys;b&&b!=a&&Nx(b,null);delete this.mediaKeys;return(this.mediaKeys=a)?Nx(a,this):Promise.resolve()}
1093
- function Ox(a){a=lc(a.initData);if(pc(a).getUint32(0,!0)+4!=a.byteLength)throw new RangeError("Malformed FairPlay init data");a=Lf(a.subarray(4),!0);a=Of(a);var b=new Event("encrypted");b.initDataType="skd";b.initData=mc(a);this.dispatchEvent(b)}Ww.PatchedMediaKeysApple=Dx;
1094
- Dx.uninstall=function(){Ex&&(Ex=!1,Object.defineProperty(HTMLMediaElement.prototype,"mediaKeys",Fx),HTMLMediaElement.prototype.setMediaKeys=Gx,window.MediaKeys=Hx,window.MediaKeySystemAccess=Ix,navigator.requestMediaKeySystemAccess=Jx,Fx=Jx=Gx=Ix=Hx=null,window.shakaMediaKeysPolyfill=!1)};
1095
- Dx.install=function(a){if(window.HTMLVideoElement&&window.WebKitMediaKeys){if(void 0===a?0:a)Ex=!0,Fx=Object.getOwnPropertyDescriptor(HTMLMediaElement.prototype,"mediaKeys"),Gx=HTMLMediaElement.prototype.setMediaKeys,Hx=window.MediaKeys,Ix=window.MediaKeySystemAccess,Jx=navigator.requestMediaKeySystemAccess;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=Mx;window.MediaKeys=Px;window.MediaKeySystemAccess=Lx;navigator.requestMediaKeySystemAccess=
1096
- Kx;window.shakaMediaKeysPolyfill=!0}};
1097
- function Lx(a,b){this.keySystem=a;if(a.startsWith("com.apple.fps"))for(a=t(b),b=a.next();!b.done;b=a.next()){var c=b.value;if("required"==c.persistentState)b=null;else{b={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:c.initDataTypes,sessionTypes:["temporary"],label:c.label};var d=!1,e=!1;if(c.audioCapabilities)for(var f=t(c.audioCapabilities),g=f.next();!g.done;g=f.next())g=g.value,g.contentType&&(d=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,
1085
+ !0,b.keySystemAccess=A);case 2:return B.return(b)}})}Ww.MediaCapabilities=lx;lx.install=mx;var nx=null;lx.originalMcap=nx;var px={};lx.memoizedMediaKeySystemAccessRequests_=px;Zw(mx,-1);function qx(){}function rx(){var a=Jd();window.MediaSource&&(Gd()?sx():a?10>=a?window.MediaSource=null:12>=a?(tx(),ux()):15>=a&&tx():zd()?sx():(Ed()||Dd()||Bd("Tizen 4"))&&vx());window.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&wx()}
1086
+ function tx(){var a=MediaSource.prototype.addSourceBuffer;MediaSource.prototype.addSourceBuffer=function(){var b=a.apply(this,Ga.apply(0,arguments));b.abort=function(){};return b}}function ux(){var a=SourceBuffer.prototype.remove;SourceBuffer.prototype.remove=function(b,c){return a.call(this,b,c-.001)}}function sx(){var a=MediaSource.isTypeSupported;MediaSource.isTypeSupported=function(b){return"mp2t"!=b.split(";")[0].split("/")[1]&&a(b)}}
1087
+ function vx(){var a=MediaSource.isTypeSupported;MediaSource.isTypeSupported=function(b){return"opus"!=gd(b)[0]&&a(b)}}
1088
+ function wx(){var a=MediaSource.isTypeSupported;Bd("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)})}Ww.MediaSource=qx;qx.install=rx;Zw(rx);function xx(){}function yx(){screen.orientation&&screen.orientation.unlock||(void 0!=screen.orientation?zx():void 0!=window.orientation&&Ax())}function zx(){void 0===screen.orientation.lock&&(screen.orientation.lock=function(){return Promise.resolve()});void 0===screen.orientation.unlock&&(screen.orientation.unlock=function(){})}
1089
+ function Ax(){function a(){switch(window.orientation){case -90:b.type="landscape-secondary";b.angle=270;break;case 0:b.type="portrait-primary";b.angle=0;break;case 90:b.type="landscape-primary";b.angle=90;break;case 180:b.type="portrait-secondary",b.angle=180}}var b=new Bx;screen.orientation=b;a();window.addEventListener("orientationchange",function(){a();var c=new O("change");b.dispatchEvent(c)})}Ww.Orientation=xx;xx.install=yx;function Bx(){ab.call(this);this.type="";this.angle=0}pa(Bx,ab);
1090
+ Bx.prototype.lock=function(a){function b(d){return screen.lockOrientation?screen.lockOrientation(d):screen.mozLockOrientation?screen.mozLockOrientation(d):screen.msLockOrientation?screen.msLockOrientation(d):!1}var c=!1;switch(a){case "natural":c=b("default");break;case "any":c=!0;this.unlock();break;default:c=b(a)}if(c)return Promise.resolve();a=Error("screen.orientation.lock() is not available on this device");a.name="NotSupportedError";a.code=DOMException.NOT_SUPPORTED_ERR;return Promise.reject(a)};
1091
+ Bx.prototype.unlock=function(){screen.unlockOrientation?screen.unlockOrientation():screen.mozUnlockOrientation?screen.mozUnlockOrientation():screen.msUnlockOrientation&&screen.msUnlockOrientation()};Zw(yx);function Cx(){}var Dx,Ex,Fx,Gx,Hx,Ix;function Jx(a,b){try{var c=new Kx(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}}function Lx(a){var b=this.mediaKeys;b&&b!=a&&Mx(b,null);delete this.mediaKeys;return(this.mediaKeys=a)?Mx(a,this):Promise.resolve()}
1092
+ function Nx(a){a=lc(a.initData);if(pc(a).getUint32(0,!0)+4!=a.byteLength)throw new RangeError("Malformed FairPlay init data");a=Lf(a.subarray(4),!0);a=Of(a);var b=new Event("encrypted");b.initDataType="skd";b.initData=mc(a);this.dispatchEvent(b)}Ww.PatchedMediaKeysApple=Cx;
1093
+ Cx.uninstall=function(){Dx&&(Dx=!1,Object.defineProperty(HTMLMediaElement.prototype,"mediaKeys",Ex),HTMLMediaElement.prototype.setMediaKeys=Fx,window.MediaKeys=Gx,window.MediaKeySystemAccess=Hx,navigator.requestMediaKeySystemAccess=Ix,Ex=Ix=Fx=Hx=Gx=null,window.shakaMediaKeysPolyfill=!1)};
1094
+ Cx.install=function(a){if(window.HTMLVideoElement&&window.WebKitMediaKeys){if(void 0===a?0:a)Dx=!0,Ex=Object.getOwnPropertyDescriptor(HTMLMediaElement.prototype,"mediaKeys"),Fx=HTMLMediaElement.prototype.setMediaKeys,Gx=window.MediaKeys,Hx=window.MediaKeySystemAccess,Ix=navigator.requestMediaKeySystemAccess;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=Lx;window.MediaKeys=Ox;window.MediaKeySystemAccess=Kx;navigator.requestMediaKeySystemAccess=
1095
+ Jx;window.shakaMediaKeysPolyfill=!0}};
1096
+ function Kx(a,b){this.keySystem=a;if(a.startsWith("com.apple.fps"))for(a=t(b),b=a.next();!b.done;b=a.next()){var c=b.value;if("required"==c.persistentState)b=null;else{b={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:c.initDataTypes,sessionTypes:["temporary"],label:c.label};var d=!1,e=!1;if(c.audioCapabilities)for(var f=t(c.audioCapabilities),g=f.next();!g.done;g=f.next())g=g.value,g.contentType&&(d=!0,WebKitMediaKeys.isTypeSupported(this.keySystem,
1098
1097
  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;}
1099
- Lx.prototype.createMediaKeys=function(){var a=new Px(this.keySystem);return Promise.resolve(a)};Lx.prototype.getConfiguration=function(){return this.g};function Px(a){this.h=new WebKitMediaKeys(a);this.g=new Af}Px.prototype.createSession=function(a){a=a||"temporary";if("temporary"!=a)throw new TypeError("Session type "+a+" is unsupported on this platform.");return new Qx(this.h,a)};Px.prototype.setServerCertificate=function(){return Promise.resolve(!1)};
1100
- function Nx(a,b){a.g.sb();if(!b)return Promise.resolve();a.g.o(b,"webkitneedkey",Ox);try{return qj(b,HTMLMediaElement.HAVE_METADATA,a.g,function(){b.webkitSetMediaKeys(a.h)}),Promise.resolve()}catch(c){return Promise.reject(c)}}Px.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function Qx(a){ab.call(this);this.i=null;this.l=a;this.g=this.h=null;this.j=new Af;this.sessionId="";this.expiration=NaN;this.closed=new $e;this.keyStatuses=new Rx}pa(Qx,ab);p=Qx.prototype;
1101
- p.generateRequest=function(a,b){var c=this;this.h=new $e;try{var d=this.l.createSession("video/mp4",lc(b));this.i=d;this.sessionId=d.sessionId||"";this.j.o(this.i,"webkitkeymessage",function(e){c.h&&(c.h.resolve(),c.h=null);e=(new Map).set("messageType",void 0==c.keyStatuses.mc()?"license-request":"license-renewal").set("message",mc(e.message));e=new O("message",e);c.dispatchEvent(e)});this.j.o(d,"webkitkeyadded",function(){c.g&&(Sx(c,"usable"),c.g.resolve(),c.g=null)});this.j.o(d,"webkitkeyerror",
1102
- 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:Sx(c,"output-not-allowed");break;default:Sx(c,"internal-error")}});Sx(this,"status-pending")}catch(e){this.h.reject(e)}return this.h};p.load=function(){return Promise.reject(Error("MediaKeySession.load not yet supported"))};
1103
- p.update=function(a){this.g=new $e;try{this.i.update(lc(a))}catch(b){this.g.reject(b)}return this.g};p.close=function(){try{this.i.close(),this.closed.resolve(),this.j.sb()}catch(a){this.closed.reject(a)}return this.closed};p.remove=function(){return Promise.reject(Error("MediaKeySession.remove is only applicable for persistent licenses, which are not supported on this platform"))};function Sx(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new O("keystatuseschange");a.dispatchEvent(b)}
1104
- function Rx(){this.size=0;this.g=void 0}p=Rx.prototype;p.mc=function(){return this.g};p.forEach=function(a){this.g&&a(this.g,vh.value())};p.get=function(a){if(this.has(a))return this.g};p.has=function(a){var b=vh.value();return this.g&&jc(a,b)?!0:!1};p.entries=function(){};p.keys=function(){};p.values=function(){};function Tx(){}function Ux(){!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=Vx,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=Wx,window.MediaKeys=Xx,window.MediaKeySystemAccess=Yx,window.shakaMediaKeysPolyfill=!0)}function Vx(){return Promise.reject(Error("The key system specified is not supported."))}
1105
- function Wx(a){return null==a?Promise.resolve():Promise.reject(Error("MediaKeys not supported."))}Ww.PatchedMediaKeysNop=Tx;Tx.install=Ux;function Xx(){throw new TypeError("Illegal constructor.");}Xx.prototype.createSession=function(){};Xx.prototype.setServerCertificate=function(){};Xx.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function Yx(){this.keySystem="";throw new TypeError("Illegal constructor.");}Yx.prototype.getConfiguration=function(){};
1106
- Yx.prototype.createMediaKeys=function(){};Zw(Ux,-10);function Zx(){}
1107
- function $x(){if(!(!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration)){if(HTMLMediaElement.prototype.webkitGenerateKeyRequest)ay="webkit";else if(!HTMLMediaElement.prototype.generateKeyRequest)return;navigator.requestMediaKeySystemAccess=by;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=cy;window.MediaKeys=dy;window.MediaKeySystemAccess=ey;window.shakaMediaKeysPolyfill=!0}}
1108
- function fy(a){var b=ay;return b?b+a.charAt(0).toUpperCase()+a.slice(1):a}function by(a,b){try{var c=new ey(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}}function cy(a){var b=this.mediaKeys;b&&b!=a&&gy(b,null);delete this.mediaKeys;(this.mediaKeys=a)&&gy(a,this);return Promise.resolve()}Ww.PatchedMediaKeysWebkit=Zx;Zx.install=$x;
1109
- function ey(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),
1098
+ Kx.prototype.createMediaKeys=function(){var a=new Ox(this.keySystem);return Promise.resolve(a)};Kx.prototype.getConfiguration=function(){return this.g};function Ox(a){this.h=new WebKitMediaKeys(a);this.g=new Af}Ox.prototype.createSession=function(a){a=a||"temporary";if("temporary"!=a)throw new TypeError("Session type "+a+" is unsupported on this platform.");return new Px(this.h,a)};Ox.prototype.setServerCertificate=function(){return Promise.resolve(!1)};
1099
+ function Mx(a,b){a.g.sb();if(!b)return Promise.resolve();a.g.o(b,"webkitneedkey",Nx);try{return qj(b,HTMLMediaElement.HAVE_METADATA,a.g,function(){b.webkitSetMediaKeys(a.h)}),Promise.resolve()}catch(c){return Promise.reject(c)}}Ox.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function Px(a){ab.call(this);this.i=null;this.l=a;this.g=this.h=null;this.j=new Af;this.sessionId="";this.expiration=NaN;this.closed=new $e;this.keyStatuses=new Qx}pa(Px,ab);p=Px.prototype;
1100
+ p.generateRequest=function(a,b){var c=this;this.h=new $e;try{var d=this.l.createSession("video/mp4",lc(b));this.i=d;this.sessionId=d.sessionId||"";this.j.o(this.i,"webkitkeymessage",function(e){c.h&&(c.h.resolve(),c.h=null);e=(new Map).set("messageType",void 0==c.keyStatuses.mc()?"license-request":"license-renewal").set("message",mc(e.message));e=new O("message",e);c.dispatchEvent(e)});this.j.o(d,"webkitkeyadded",function(){c.g&&(Rx(c,"usable"),c.g.resolve(),c.g=null)});this.j.o(d,"webkitkeyerror",
1101
+ 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:Rx(c,"output-not-allowed");break;default:Rx(c,"internal-error")}});Rx(this,"status-pending")}catch(e){this.h.reject(e)}return this.h};p.load=function(){return Promise.reject(Error("MediaKeySession.load not yet supported"))};
1102
+ p.update=function(a){this.g=new $e;try{this.i.update(lc(a))}catch(b){this.g.reject(b)}return this.g};p.close=function(){try{this.i.close(),this.closed.resolve(),this.j.sb()}catch(a){this.closed.reject(a)}return this.closed};p.remove=function(){return Promise.reject(Error("MediaKeySession.remove is only applicable for persistent licenses, which are not supported on this platform"))};function Rx(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new O("keystatuseschange");a.dispatchEvent(b)}
1103
+ function Qx(){this.size=0;this.g=void 0}p=Qx.prototype;p.mc=function(){return this.g};p.forEach=function(a){this.g&&a(this.g,vh.value())};p.get=function(a){if(this.has(a))return this.g};p.has=function(a){var b=vh.value();return this.g&&jc(a,b)?!0:!1};p.entries=function(){};p.keys=function(){};p.values=function(){};function Sx(){}function Tx(){!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=Ux,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=Vx,window.MediaKeys=Wx,window.MediaKeySystemAccess=Xx,window.shakaMediaKeysPolyfill=!0)}function Ux(){return Promise.reject(Error("The key system specified is not supported."))}
1104
+ function Vx(a){return null==a?Promise.resolve():Promise.reject(Error("MediaKeys not supported."))}Ww.PatchedMediaKeysNop=Sx;Sx.install=Tx;function Wx(){throw new TypeError("Illegal constructor.");}Wx.prototype.createSession=function(){};Wx.prototype.setServerCertificate=function(){};Wx.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};function Xx(){this.keySystem="";throw new TypeError("Illegal constructor.");}Xx.prototype.getConfiguration=function(){};
1105
+ Xx.prototype.createMediaKeys=function(){};Zw(Tx,-10);function Yx(){}
1106
+ function Zx(){if(!(!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration)){if(HTMLMediaElement.prototype.webkitGenerateKeyRequest)$x="webkit";else if(!HTMLMediaElement.prototype.generateKeyRequest)return;navigator.requestMediaKeySystemAccess=ay;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=by;window.MediaKeys=cy;window.MediaKeySystemAccess=dy;window.shakaMediaKeysPolyfill=!0}}
1107
+ function ey(a){var b=$x;return b?b+a.charAt(0).toUpperCase()+a.slice(1):a}function ay(a,b){try{var c=new dy(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}}function by(a){var b=this.mediaKeys;b&&b!=a&&fy(b,null);delete this.mediaKeys;(this.mediaKeys=a)&&fy(a,this);return Promise.resolve()}Ww.PatchedMediaKeysWebkit=Yx;Yx.install=Zx;
1108
+ function dy(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),
1110
1109
  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"]):
1111
- 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;}ey.prototype.createMediaKeys=function(){var a=new dy(this.g);return Promise.resolve(a)};ey.prototype.getConfiguration=function(){return this.h};function dy(a){this.l=a;this.h=null;this.g=new Af;this.i=[];this.j=new Map}
1112
- function gy(a,b){a.h=b;a.g.sb();var c=ay;b&&(a.g.o(b,c+"needkey",function(d){var e=new CustomEvent("encrypted");e.initDataType="cenc";e.initData=mc(d.initData);a.h.dispatchEvent(e)}),a.g.o(b,c+"keymessage",function(d){var e=hy(a,d.sessionId);e&&(d=(new Map).set("messageType",void 0==e.keyStatuses.mc()?"licenserequest":"licenserenewal").set("message",d.message),d=new O("message",d),e.h&&(e.h.resolve(),e.h=null),e.dispatchEvent(d))}),a.g.o(b,c+"keyadded",function(d){if(d=hy(a,d.sessionId))iy(d,"usable"),
1113
- d.g&&d.g.resolve(),d.g=null}),a.g.o(b,c+"keyerror",function(d){var e=hy(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?iy(e,"output-restricted"):1==f?iy(e,"expired"):iy(e,"internal-error"))}}))}
1114
- dy.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 jy(b,this.l,a);this.i.push(a);return a};dy.prototype.setServerCertificate=function(){return Promise.resolve(!1)};dy.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};
1115
- function hy(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 jy(a,b,c){ab.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 $e;this.keyStatuses=new ky}pa(jy,ab);
1116
- function ly(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=lc(Of("LOAD_SESSION|"+c));else{var e=Of("PERSISTENT|");d=jg(e,b)}else d=lc(b)}catch(g){return Promise.reject(g)}a.h=new $e;var f=fy("generateKeyRequest");try{a.j[f](a.i,d)}catch(g){if("InvalidStateError"!=g.name)return a.h=null,Promise.reject(g);(new vd(function(){try{a.j[f](a.i,d)}catch(h){a.h.reject(h),a.h=null}})).T(.01)}return a.h}
1117
- function my(a,b,c){if(a.g)a.g.then(function(){return my(a,b,c)}).catch(function(){return my(a,b,c)});else{a.g=b;if("webkit-org.w3.clearkey"==a.i){var d=Kf(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=fg(e.keys[0].k);e=fg(e.keys[0].kid)}else d=lc(c),e=null;var f=fy("addKey");try{a.j[f](a.i,d,e,a.sessionId)}catch(g){a.g.reject(g),a.g=null}}}
1118
- function iy(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new O("keystatuseschange");a.dispatchEvent(b)}p=jy.prototype;p.generateRequest=function(a,b){return ly(this,b,null)};p.load=function(a){return"persistent-license"==this.l?ly(this,null,a):Promise.reject(Error("Not a persistent session."))};p.update=function(a){var b=new $e;my(this,b,a);return b};
1119
- p.close=function(){if("persistent-license"!=this.l){if(!this.sessionId)return this.closed.reject(Error("The session is not callable.")),this.closed;var a=fy("cancelKeyRequest");try{this.j[a](this.i,this.sessionId)}catch(b){}}this.closed.resolve();return this.closed};p.remove=function(){return"persistent-license"!=this.l?Promise.reject(Error("Not a persistent session.")):this.close()};function ky(){this.size=0;this.g=void 0}p=ky.prototype;p.mc=function(){return this.g};
1120
- p.forEach=function(a){this.g&&a(this.g,vh.value())};p.get=function(a){if(this.has(a))return this.g};p.has=function(a){var b=vh.value();return this.g&&jc(a,b)?!0:!1};p.entries=function(){};p.keys=function(){};p.values=function(){};var ay="";Zw($x);function ny(){}function oy(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;a.requestPictureInPicture&&document.exitPictureInPicture||!a.webkitSupportsPresentationMode||(document.pictureInPictureEnabled=!0,document.pictureInPictureElement=null,a.requestPictureInPicture=py,Object.defineProperty(a,"disablePictureInPicture",{get:qy,set:ry,enumerable:!0,configurable:!0}),document.exitPictureInPicture=sy,document.addEventListener("webkitpresentationmodechanged",ty,!0))}}
1121
- function ty(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)}
1122
- function py(){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 sy(){var a=document.pictureInPictureElement;return a?(a.webkitSetPresentationMode("inline"),document.pictureInPictureElement=null,Promise.resolve()):Promise.reject(Error("No picture in picture element found"))}
1123
- function qy(){return this.hasAttribute("disablePictureInPicture")?!0:!this.webkitSupportsPresentationMode("picture-in-picture")}function ry(a){a?this.setAttribute("disablePictureInPicture",""):this.removeAttribute("disablePictureInPicture")}Ww.PiPWebkit=ny;ny.install=oy;Zw(oy);function uy(){}function vy(){window.crypto&&("randomUUID"in window.crypto||(window.crypto.randomUUID=wy))}function wy(){var a=URL.createObjectURL(new Blob),b=a.toString();URL.revokeObjectURL(a);return b.substr(b.lastIndexOf("/")+1)}Ww.RandomUUID=uy;uy.install=vy;Zw(vy);function xy(){}function yy(){navigator.storage&&navigator.storage.estimate||!navigator.webkitTemporaryStorage||!navigator.webkitTemporaryStorage.queryUsageAndQuota||("storage"in navigator||(navigator.storage={}),navigator.storage.estimate=zy)}function zy(){return new Promise(function(a,b){navigator.webkitTemporaryStorage.queryUsageAndQuota(function(c,d){a({usage:c,quota:d})},b)})}Ww.StorageEstimate=xy;xy.install=yy;Zw(yy);function Ay(){}function By(){var a=Symbol.prototype;"description"in a||Object.defineProperty(a,"description",{get:Cy})}function Cy(){var a=/\((.*)\)/.exec(this.toString());return a?a[1]:void 0}Ww.Symbol=Ay;Ay.install=By;Zw(By);function Dy(){}function Ey(){if(window.HTMLMediaElement){var a=HTMLMediaElement.prototype.play;HTMLMediaElement.prototype.play=function(){var b=a.apply(this);b&&b.catch(function(){});return b}}}Ww.VideoPlayPromise=Dy;Dy.install=Ey;Zw(Ey);function Fy(){}function Gy(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;!a.getVideoPlaybackQuality&&("webkitDroppedFrameCount"in a||Fd())&&(a.getVideoPlaybackQuality=Hy)}}function Hy(){return{droppedVideoFrames:this.webkitDroppedFrameCount,totalVideoFrames:this.webkitDecodedFrameCount,corruptedVideoFrames:0,creationTime:NaN,totalFrameDelay:0}}Ww.VideoPlaybackQuality=Fy;Fy.install=Gy;Zw(Gy);function Iy(){}function Jy(){if(!window.VTTCue&&window.TextTrackCue){var a=null,b=TextTrackCue.length;if(3==b)a=Ky;else if(6==b)a=Ly;else{try{var c=!!Ky(1,2,"")}catch(d){c=!1}c&&(a=Ky)}a&&(window.VTTCue=function(d,e,f){return a(d,e,f)})}}function Ky(a,b,c){return new window.TextTrackCue(a,b,c)}function Ly(a,b,c){return new window.TextTrackCue(a+"-"+b+"-"+c,a,b,c)}Ww.VTTCue=Iy;Iy.install=Jy;Zw(Jy);function My(){}My.prototype.parseInit=function(){};My.prototype.setSequenceMode=function(){};My.prototype.setManifestType=function(){};My.prototype.parseMedia=function(a,b){var c=null,d=[];a=Kf(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=Ny.exec(e))){var f=Oy.exec(e[1]);f=60*parseInt(f[1],10)+parseFloat(f[2].replace(",","."));e=new yc(f,b.segmentEnd?b.segmentEnd:f+2,e[2]);c&&(c.endTime=f,d.push(c));c=e}c&&d.push(c);return d};
1124
- M("shaka.text.LrcTextParser",My);My.prototype.parseMedia=My.prototype.parseMedia;My.prototype.setManifestType=My.prototype.setManifestType;My.prototype.setSequenceMode=My.prototype.setSequenceMode;My.prototype.parseInit=My.prototype.parseInit;var Ny=/^\[(\d{1,2}:\d{1,2}(?:[.,]\d{1,3})?)\](.*)/,Oy=/^(\d+):(\d{1,2}(?:[.,]\d{1,3})?)$/;ld["application/x-subtitle-lrc"]=function(){return new My};function Py(){}Py.prototype.parseInit=function(){};Py.prototype.setSequenceMode=function(){};Py.prototype.setManifestType=function(){};
1125
- Py.prototype.parseMedia=function(a,b,c){var d=Kf(a);a=[];if(""==d)return a;var e=Fg(d,"tt");if(!e)throw new P(2,2,2005,"Failed to parse TTML.");d=e.getElementsByTagName("body")[0];if(!d)return[];var f=sg(e,Qy,"frameRate"),g=sg(e,Qy,"subFrameRate"),h=sg(e,Qy,"frameRateMultiplier"),k=sg(e,Qy,"tickRate"),l=sg(e,Qy,"cellResolution"),m=e.getAttribute("xml:space")||"default",n=sg(e,Ry,"extent");if("default"!=m&&"preserve"!=m)throw new P(2,2,2005,"Invalid xml:space value: "+m);m="default"==m;f=new Sy(f,
1126
- g,h,k);l=l?(l=/^(\d+) (\d+)$/.exec(l))?{hc:parseInt(l[1],10),rows:parseInt(l[2],10)}:null:null;g=(g=e.getElementsByTagName("metadata")[0])?qg(g):[];h=Array.from(e.getElementsByTagName("style"));e=Array.from(e.getElementsByTagName("region"));k=[];for(var q=t(e),r=q.next();!r.done;r=q.next()){var u=r.value;r=new zc;var v=u.getAttribute("xml:id");if(v){r.id=v;var y=null;n&&(y=Ty.exec(n)||Uy.exec(n));v=y?Number(y[1]):null;y=y?Number(y[2]):null;var z,x=Vy(u,h,"extent");if(x){var A=(z=Ty.exec(x))||Uy.exec(x);
1127
- null!=A&&(r.width=Number(A[1]),r.height=Number(A[2]),z||(null!=v&&(r.width=100*r.width/v),null!=y&&(r.height=100*r.height/y)),r.widthUnits=z||null!=v?Rc:0,r.heightUnits=z||null!=y?Rc:0)}if(u=Vy(u,h,"origin"))if(A=(z=Ty.exec(u))||Uy.exec(u),null!=A)r.viewportAnchorX=Number(A[1]),r.viewportAnchorY=Number(A[2]),z?x||(r.width=100-r.viewportAnchorX,r.widthUnits=Rc,r.height=100-r.viewportAnchorY,r.heightUnits=Rc):(null!=y&&(r.viewportAnchorY=100*r.viewportAnchorY/y),null!=v&&(r.viewportAnchorX=100*r.viewportAnchorX/
1128
- v)),r.viewportAnchorUnits=z||null!=v?Rc:0}else r=null;r&&k.push(r)}if(ng(d,"p").length)throw new P(2,2,2001,"<p> can only be inside <div> in TTML");n=t(ng(d,"div"));for(q=n.next();!q.done;q=n.next())if(ng(q.value,"span").length)throw new P(2,2,2001,"<span> can only be inside <p> in TTML");if(b=Wy(d,b,f,g,h,e,k,m,l,null,!1,c))b.backgroundColor||(b.backgroundColor="transparent"),a.push(b);return a};
1129
- function Wy(a,b,c,d,e,f,g,h,k,l,m,n){var q=a.parentNode;if(a.nodeType==Node.COMMENT_NODE)return null;if(a.nodeType==Node.TEXT_NODE){if(!m)return null;var r=document.createElement("span");r.textContent=a.textContent}else r=a;for(var u=null,v=t(Xy),y=v.next();!y.done&&!(u=Yy(r,"backgroundImage",d,"#",y.value)[0]);y=v.next());v=null;var z=sg(r,Xy,"backgroundImage");n&&z&&!z.startsWith("#")&&(y=new gb(n),z=new gb(z),(y=y.resolve(z).toString())&&(v=y));if("p"==a.nodeName||u||v)m=!0;a=m;y="default"==(r.getAttribute("xml:space")||
1130
- (h?"default":"preserve"));z=Array.from(r.childNodes).every(function(C){return C.nodeType==Node.TEXT_NODE});h=[];if(!z)for(var x=t(r.childNodes),A=x.next();!A.done;A=x.next())(A=Wy(A.value,b,c,d,e,f,g,y,k,r,m,n))&&h.push(A);d=null!=l;n=/\S/.test(r.textContent);A=r.hasAttribute("begin")||r.hasAttribute("end")||r.hasAttribute("dur");if(!(A||n||"br"==r.tagName||0!=h.length||d&&!y))return null;x=Zy(r,c);n=x.start;for(x=x.end;q&&q.nodeType==Node.ELEMENT_NODE&&"tt"!=q.tagName;)x=$y(q,c,n,x),n=x.start,x=
1131
- x.end,q=q.parentNode;null==n&&(n=0);n+=b.periodStart;x=null==x?Infinity:x+b.periodStart;n=Math.max(n,b.segmentStart);x=Math.min(x,b.segmentEnd);if(!A&&0<h.length)for(n=Infinity,x=0,b=t(h),c=b.next();!c.done;c=b.next())c=c.value,n=Math.min(n,c.startTime),x=Math.max(x,c.endTime);if("br"==r.tagName)return e=new yc(n,x,""),e.lineBreak=!0,e;b="";z&&(b=r.textContent,y&&(b=b.trim(),b=b.replace(/\s+/g," ")));b=new yc(n,x,b);b.nestedCues=h;m||(b.isContainer=!0);k&&(b.cellResolution=k);k=Yy(r,"region",f,"")[0];
1132
- if(r.hasAttribute("region")&&k&&k.getAttribute("xml:id")){var B=k.getAttribute("xml:id");b.region=g.filter(function(C){return C.id==B})[0]}g=k;l&&d&&!r.getAttribute("region")&&!r.getAttribute("style")&&(g=Yy(l,"region",f,"")[0]);az(b,r,g,u,v,e,a,0==h.length);return b}
1133
- function az(a,b,c,d,e,f,g,h){g=g||h;"rtl"==bz(b,c,f,"direction",g)&&(a.direction="rtl");h=bz(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=Cc);(h=bz(b,c,f,"textAlign",!0))?(a.positionAlign=cz[h],a.lineAlign=dz[h],a.textAlign=Lc[h.toUpperCase()]):a.textAlign=Bc;if(h=bz(b,c,f,"displayAlign",!0))a.displayAlign=Mc[h.toUpperCase()];if(h=bz(b,c,f,"color",g))a.color=h;if(h=bz(b,c,f,"backgroundColor",
1134
- g))a.backgroundColor=h;if(h=bz(b,c,f,"border",g))a.border=h;if(h=bz(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=bz(b,c,f,"fontWeight",g))&&
1135
- "bold"==h&&(a.fontWeight=700);h=bz(b,c,f,"wrapOption",g);a.wrapLine=h&&"noWrap"==h?!1:!0;(h=bz(b,c,f,"lineHeight",g))&&h.match(ez)&&(a.lineHeight=h);(h=bz(b,c,f,"fontSize",g))&&(h.match(ez)||h.match(fz))&&(a.fontSize=h);if(h=bz(b,c,f,"fontStyle",g))a.fontStyle=Qc[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=bz(b,
1136
- c,f,"textOutline",g))d=d.split(" "),d[0].match(ez)?a.textStrokeColor=a.color:(a.textStrokeColor=d[0],d.shift()),d[0]&&d[0].match(ez)?a.textStrokeWidth=d[0]:a.textStrokeColor="";(d=bz(b,c,f,"letterSpacing",g))&&d.match(ez)&&(a.letterSpacing=d);(d=bz(b,c,f,"linePadding",g))&&d.match(ez)&&(a.linePadding=d);if(d=bz(b,c,f,"opacity",g))a.opacity=parseFloat(d);(d=Vy(c,f,"textDecoration"))&&gz(a,d);(d=hz(b,f,"textDecoration"))&&gz(a,d);if(d=bz(b,c,f,"textCombine",g))a.textCombineUpright=d;switch(bz(b,c,f,
1110
+ 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;}dy.prototype.createMediaKeys=function(){var a=new cy(this.g);return Promise.resolve(a)};dy.prototype.getConfiguration=function(){return this.h};function cy(a){this.l=a;this.h=null;this.g=new Af;this.i=[];this.j=new Map}
1111
+ function fy(a,b){a.h=b;a.g.sb();var c=$x;b&&(a.g.o(b,c+"needkey",function(d){var e=new CustomEvent("encrypted");e.initDataType="cenc";e.initData=mc(d.initData);a.h.dispatchEvent(e)}),a.g.o(b,c+"keymessage",function(d){var e=gy(a,d.sessionId);e&&(d=(new Map).set("messageType",void 0==e.keyStatuses.mc()?"licenserequest":"licenserenewal").set("message",d.message),d=new O("message",d),e.h&&(e.h.resolve(),e.h=null),e.dispatchEvent(d))}),a.g.o(b,c+"keyadded",function(d){if(d=gy(a,d.sessionId))hy(d,"usable"),
1112
+ d.g&&d.g.resolve(),d.g=null}),a.g.o(b,c+"keyerror",function(d){var e=gy(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?hy(e,"output-restricted"):1==f?hy(e,"expired"):hy(e,"internal-error"))}}))}
1113
+ cy.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 iy(b,this.l,a);this.i.push(a);return a};cy.prototype.setServerCertificate=function(){return Promise.resolve(!1)};cy.prototype.getStatusForPolicy=function(){return Promise.resolve("usable")};
1114
+ function gy(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 iy(a,b,c){ab.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 $e;this.keyStatuses=new jy}pa(iy,ab);
1115
+ function ky(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=lc(Of("LOAD_SESSION|"+c));else{var e=Of("PERSISTENT|");d=ig(e,b)}else d=lc(b)}catch(g){return Promise.reject(g)}a.h=new $e;var f=ey("generateKeyRequest");try{a.j[f](a.i,d)}catch(g){if("InvalidStateError"!=g.name)return a.h=null,Promise.reject(g);(new vd(function(){try{a.j[f](a.i,d)}catch(h){a.h.reject(h),a.h=null}})).T(.01)}return a.h}
1116
+ function ly(a,b,c){if(a.g)a.g.then(function(){return ly(a,b,c)}).catch(function(){return ly(a,b,c)});else{a.g=b;if("webkit-org.w3.clearkey"==a.i){var d=Kf(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=fg(e.keys[0].k);e=fg(e.keys[0].kid)}else d=lc(c),e=null;var f=ey("addKey");try{a.j[f](a.i,d,e,a.sessionId)}catch(g){a.g.reject(g),a.g=null}}}
1117
+ function hy(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;b=new O("keystatuseschange");a.dispatchEvent(b)}p=iy.prototype;p.generateRequest=function(a,b){return ky(this,b,null)};p.load=function(a){return"persistent-license"==this.l?ky(this,null,a):Promise.reject(Error("Not a persistent session."))};p.update=function(a){var b=new $e;ly(this,b,a);return b};
1118
+ p.close=function(){if("persistent-license"!=this.l){if(!this.sessionId)return this.closed.reject(Error("The session is not callable.")),this.closed;var a=ey("cancelKeyRequest");try{this.j[a](this.i,this.sessionId)}catch(b){}}this.closed.resolve();return this.closed};p.remove=function(){return"persistent-license"!=this.l?Promise.reject(Error("Not a persistent session.")):this.close()};function jy(){this.size=0;this.g=void 0}p=jy.prototype;p.mc=function(){return this.g};
1119
+ p.forEach=function(a){this.g&&a(this.g,vh.value())};p.get=function(a){if(this.has(a))return this.g};p.has=function(a){var b=vh.value();return this.g&&jc(a,b)?!0:!1};p.entries=function(){};p.keys=function(){};p.values=function(){};var $x="";Zw(Zx);function my(){}function ny(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;a.requestPictureInPicture&&document.exitPictureInPicture||!a.webkitSupportsPresentationMode||(document.pictureInPictureEnabled=!0,document.pictureInPictureElement=null,a.requestPictureInPicture=oy,Object.defineProperty(a,"disablePictureInPicture",{get:py,set:qy,enumerable:!0,configurable:!0}),document.exitPictureInPicture=ry,document.addEventListener("webkitpresentationmodechanged",sy,!0))}}
1120
+ function sy(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)}
1121
+ function oy(){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 ry(){var a=document.pictureInPictureElement;return a?(a.webkitSetPresentationMode("inline"),document.pictureInPictureElement=null,Promise.resolve()):Promise.reject(Error("No picture in picture element found"))}
1122
+ function py(){return this.hasAttribute("disablePictureInPicture")?!0:!this.webkitSupportsPresentationMode("picture-in-picture")}function qy(a){a?this.setAttribute("disablePictureInPicture",""):this.removeAttribute("disablePictureInPicture")}Ww.PiPWebkit=my;my.install=ny;Zw(ny);function ty(){}function uy(){window.crypto&&("randomUUID"in window.crypto||(window.crypto.randomUUID=vy))}function vy(){var a=URL.createObjectURL(new Blob),b=a.toString();URL.revokeObjectURL(a);return b.substr(b.lastIndexOf("/")+1)}Ww.RandomUUID=ty;ty.install=uy;Zw(uy);function wy(){}function xy(){navigator.storage&&navigator.storage.estimate||!navigator.webkitTemporaryStorage||!navigator.webkitTemporaryStorage.queryUsageAndQuota||("storage"in navigator||(navigator.storage={}),navigator.storage.estimate=yy)}function yy(){return new Promise(function(a,b){navigator.webkitTemporaryStorage.queryUsageAndQuota(function(c,d){a({usage:c,quota:d})},b)})}Ww.StorageEstimate=wy;wy.install=xy;Zw(xy);function zy(){}function Ay(){var a=Symbol.prototype;"description"in a||Object.defineProperty(a,"description",{get:By})}function By(){var a=/\((.*)\)/.exec(this.toString());return a?a[1]:void 0}Ww.Symbol=zy;zy.install=Ay;Zw(Ay);function Cy(){}function Dy(){if(window.HTMLMediaElement){var a=HTMLMediaElement.prototype.play;HTMLMediaElement.prototype.play=function(){var b=a.apply(this);b&&b.catch(function(){});return b}}}Ww.VideoPlayPromise=Cy;Cy.install=Dy;Zw(Dy);function Ey(){}function Fy(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;!a.getVideoPlaybackQuality&&("webkitDroppedFrameCount"in a||Fd())&&(a.getVideoPlaybackQuality=Gy)}}function Gy(){return{droppedVideoFrames:this.webkitDroppedFrameCount,totalVideoFrames:this.webkitDecodedFrameCount,corruptedVideoFrames:0,creationTime:NaN,totalFrameDelay:0}}Ww.VideoPlaybackQuality=Ey;Ey.install=Fy;Zw(Fy);function Hy(){}function Iy(){if(!window.VTTCue&&window.TextTrackCue){var a=null,b=TextTrackCue.length;if(3==b)a=Jy;else if(6==b)a=Ky;else{try{var c=!!Jy(1,2,"")}catch(d){c=!1}c&&(a=Jy)}a&&(window.VTTCue=function(d,e,f){return a(d,e,f)})}}function Jy(a,b,c){return new window.TextTrackCue(a,b,c)}function Ky(a,b,c){return new window.TextTrackCue(a+"-"+b+"-"+c,a,b,c)}Ww.VTTCue=Hy;Hy.install=Iy;Zw(Iy);function Ly(){}Ly.prototype.parseInit=function(){};Ly.prototype.setSequenceMode=function(){};Ly.prototype.setManifestType=function(){};Ly.prototype.parseMedia=function(a,b){var c=null,d=[];a=Kf(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=My.exec(e))){var f=Ny.exec(e[1]);f=60*parseInt(f[1],10)+parseFloat(f[2].replace(",","."));e=new yc(f,b.segmentEnd?b.segmentEnd:f+2,e[2]);c&&(c.endTime=f,d.push(c));c=e}c&&d.push(c);return d};
1123
+ M("shaka.text.LrcTextParser",Ly);Ly.prototype.parseMedia=Ly.prototype.parseMedia;Ly.prototype.setManifestType=Ly.prototype.setManifestType;Ly.prototype.setSequenceMode=Ly.prototype.setSequenceMode;Ly.prototype.parseInit=Ly.prototype.parseInit;var My=/^\[(\d{1,2}:\d{1,2}(?:[.,]\d{1,3})?)\](.*)/,Ny=/^(\d+):(\d{1,2}(?:[.,]\d{1,3})?)$/;ld["application/x-subtitle-lrc"]=function(){return new Ly};function Oy(){}Oy.prototype.parseInit=function(){};Oy.prototype.setSequenceMode=function(){};Oy.prototype.setManifestType=function(){};
1124
+ Oy.prototype.parseMedia=function(a,b,c){var d=Kf(a);a=[];if(""==d)return a;var e=Fg(d,"tt");if(!e)throw new P(2,2,2005,"Failed to parse TTML.");d=e.getElementsByTagName("body")[0];if(!d)return[];var f=sg(e,Py,"frameRate"),g=sg(e,Py,"subFrameRate"),h=sg(e,Py,"frameRateMultiplier"),k=sg(e,Py,"tickRate"),l=sg(e,Py,"cellResolution"),m=e.getAttribute("xml:space")||"default",n=sg(e,Qy,"extent");if("default"!=m&&"preserve"!=m)throw new P(2,2,2005,"Invalid xml:space value: "+m);m="default"==m;f=new Ry(f,
1125
+ g,h,k);l=l?(l=/^(\d+) (\d+)$/.exec(l))?{ic:parseInt(l[1],10),rows:parseInt(l[2],10)}:null:null;g=(g=e.getElementsByTagName("metadata")[0])?qg(g):[];h=Array.from(e.getElementsByTagName("style"));e=Array.from(e.getElementsByTagName("region"));k=[];for(var q=t(e),r=q.next();!r.done;r=q.next()){var u=r.value;r=new zc;var v=u.getAttribute("xml:id");if(v){r.id=v;var y=null;n&&(y=Sy.exec(n)||Ty.exec(n));v=y?Number(y[1]):null;y=y?Number(y[2]):null;var z,x=Uy(u,h,"extent");if(x){var A=(z=Sy.exec(x))||Ty.exec(x);
1126
+ null!=A&&(r.width=Number(A[1]),r.height=Number(A[2]),z||(null!=v&&(r.width=100*r.width/v),null!=y&&(r.height=100*r.height/y)),r.widthUnits=z||null!=v?Rc:0,r.heightUnits=z||null!=y?Rc:0)}if(u=Uy(u,h,"origin"))if(A=(z=Sy.exec(u))||Ty.exec(u),null!=A)r.viewportAnchorX=Number(A[1]),r.viewportAnchorY=Number(A[2]),z?x||(r.width=100-r.viewportAnchorX,r.widthUnits=Rc,r.height=100-r.viewportAnchorY,r.heightUnits=Rc):(null!=y&&(r.viewportAnchorY=100*r.viewportAnchorY/y),null!=v&&(r.viewportAnchorX=100*r.viewportAnchorX/
1127
+ v)),r.viewportAnchorUnits=z||null!=v?Rc:0}else r=null;r&&k.push(r)}if(ng(d,"p").length)throw new P(2,2,2001,"<p> can only be inside <div> in TTML");n=t(ng(d,"div"));for(q=n.next();!q.done;q=n.next())if(ng(q.value,"span").length)throw new P(2,2,2001,"<span> can only be inside <p> in TTML");if(b=Vy(d,b,f,g,h,e,k,m,l,null,!1,c))b.backgroundColor||(b.backgroundColor="transparent"),a.push(b);return a};
1128
+ function Vy(a,b,c,d,e,f,g,h,k,l,m,n){var q=a.parentNode;if(a.nodeType==Node.COMMENT_NODE)return null;if(a.nodeType==Node.TEXT_NODE){if(!m)return null;var r=document.createElement("span");r.textContent=a.textContent}else r=a;for(var u=null,v=t(Wy),y=v.next();!y.done&&!(u=Xy(r,"backgroundImage",d,"#",y.value)[0]);y=v.next());v=null;var z=sg(r,Wy,"backgroundImage");n&&z&&!z.startsWith("#")&&(y=new gb(n),z=new gb(z),(y=y.resolve(z).toString())&&(v=y));if("p"==a.nodeName||u||v)m=!0;a=m;y="default"==(r.getAttribute("xml:space")||
1129
+ (h?"default":"preserve"));z=Array.from(r.childNodes).every(function(C){return C.nodeType==Node.TEXT_NODE});h=[];if(!z)for(var x=t(r.childNodes),A=x.next();!A.done;A=x.next())(A=Vy(A.value,b,c,d,e,f,g,y,k,r,m,n))&&h.push(A);d=null!=l;n=/\S/.test(r.textContent);A=r.hasAttribute("begin")||r.hasAttribute("end")||r.hasAttribute("dur");if(!(A||n||"br"==r.tagName||0!=h.length||d&&!y))return null;x=Yy(r,c);n=x.start;for(x=x.end;q&&q.nodeType==Node.ELEMENT_NODE&&"tt"!=q.tagName;)x=Zy(q,c,n,x),n=x.start,x=
1130
+ x.end,q=q.parentNode;null==n&&(n=0);n+=b.periodStart;x=null==x?Infinity:x+b.periodStart;n=Math.max(n,b.segmentStart);x=Math.min(x,b.segmentEnd);if(!A&&0<h.length)for(n=Infinity,x=0,b=t(h),c=b.next();!c.done;c=b.next())c=c.value,n=Math.min(n,c.startTime),x=Math.max(x,c.endTime);if("br"==r.tagName)return e=new yc(n,x,""),e.lineBreak=!0,e;b="";z&&(b=r.textContent,y&&(b=b.trim(),b=b.replace(/\s+/g," ")));b=new yc(n,x,b);b.nestedCues=h;m||(b.isContainer=!0);k&&(b.cellResolution=k);k=Xy(r,"region",f,"")[0];
1131
+ if(r.hasAttribute("region")&&k&&k.getAttribute("xml:id")){var B=k.getAttribute("xml:id");b.region=g.filter(function(C){return C.id==B})[0]}g=k;l&&d&&!r.getAttribute("region")&&!r.getAttribute("style")&&(g=Xy(l,"region",f,"")[0]);$y(b,r,g,u,v,e,a,0==h.length);return b}
1132
+ function $y(a,b,c,d,e,f,g,h){g=g||h;"rtl"==az(b,c,f,"direction",g)&&(a.direction="rtl");h=az(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=Cc);(h=az(b,c,f,"textAlign",!0))?(a.positionAlign=bz[h],a.lineAlign=cz[h],a.textAlign=Lc[h.toUpperCase()]):a.textAlign=Bc;if(h=az(b,c,f,"displayAlign",!0))a.displayAlign=Mc[h.toUpperCase()];if(h=az(b,c,f,"color",g))a.color=h;if(h=az(b,c,f,"backgroundColor",
1133
+ g))a.backgroundColor=h;if(h=az(b,c,f,"border",g))a.border=h;if(h=az(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=az(b,c,f,"fontWeight",g))&&
1134
+ "bold"==h&&(a.fontWeight=700);h=az(b,c,f,"wrapOption",g);a.wrapLine=h&&"noWrap"==h?!1:!0;(h=az(b,c,f,"lineHeight",g))&&h.match(dz)&&(a.lineHeight=h);(h=az(b,c,f,"fontSize",g))&&(h.match(dz)||h.match(ez))&&(a.fontSize=h);if(h=az(b,c,f,"fontStyle",g))a.fontStyle=Qc[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=az(b,
1135
+ c,f,"textOutline",g))d=d.split(" "),d[0].match(dz)?a.textStrokeColor=a.color:(a.textStrokeColor=d[0],d.shift()),d[0]&&d[0].match(dz)?a.textStrokeWidth=d[0]:a.textStrokeColor="";(d=az(b,c,f,"letterSpacing",g))&&d.match(dz)&&(a.letterSpacing=d);(d=az(b,c,f,"linePadding",g))&&d.match(dz)&&(a.linePadding=d);if(d=az(b,c,f,"opacity",g))a.opacity=parseFloat(d);(d=Uy(c,f,"textDecoration"))&&fz(a,d);(d=gz(b,f,"textDecoration"))&&fz(a,d);if(d=az(b,c,f,"textCombine",g))a.textCombineUpright=d;switch(az(b,c,f,
1137
1136
  "ruby",g)){case "container":a.rubyTag="ruby";break;case "text":a.rubyTag="rt"}}
1138
- function gz(a,b){b=t(b.split(" "));for(var c=b.next();!c.done;c=b.next())switch(c.value){case "underline":a.textDecoration.includes("underline")||a.textDecoration.push("underline");break;case "noUnderline":a.textDecoration.includes("underline")&&vc(a.textDecoration,"underline");break;case "lineThrough":a.textDecoration.includes("lineThrough")||a.textDecoration.push("lineThrough");break;case "noLineThrough":a.textDecoration.includes("lineThrough")&&vc(a.textDecoration,"lineThrough");break;case "overline":a.textDecoration.includes("overline")||
1139
- a.textDecoration.push("overline");break;case "noOverline":a.textDecoration.includes("overline")&&vc(a.textDecoration,"overline")}}function bz(a,b,c,d,e){e=void 0===e?!0:e;return(a=hz(a,c,d))?a:e?Vy(b,c,d):null}function Vy(a,b,c){if(!a)return null;var d=sg(a,Ry,c);return d?d:iz(a,b,c)}function hz(a,b,c){var d=sg(a,Ry,c);return d?d:iz(a,b,c)}
1140
- function iz(a,b,c){a=Yy(a,"style",b,"");for(var d=null,e=0;e<a.length;e++){var f=rg(a[e],"urn:ebu:tt:style",c);f||(f=sg(a[e],Ry,c));f||(f=hz(a[e],b,c));f&&(d=f)}return d}
1141
- function Yy(a,b,c,d,e){var f=[];if(!a||1>c.length)return f;var g=a;for(a=null;g&&!(a=e?rg(g,e,b):g.getAttribute(b))&&(g=g.parentNode,g instanceof Element););if(b=a)for(b=t(b.split(" ")),e=b.next();!e.done;e=b.next())for(e=e.value,a=t(c),g=a.next();!g.done;g=a.next())if(g=g.value,d+g.getAttribute("xml:id")==e){f.push(g);break}return f}function $y(a,b,c,d){a=Zy(a,b);null==c?c=a.start:null!=a.start&&(c+=a.start);null==d?d=a.end:null!=a.start&&(d+=a.start);return{start:c,end:d}}
1142
- function Zy(a,b){var c=jz(a.getAttribute("begin"),b),d=jz(a.getAttribute("end"),b);a=jz(a.getAttribute("dur"),b);null==d&&null!=a&&(d=c+a);return{start:c,end:d}}
1143
- function jz(a,b){var c=null;if(kz.test(a)){a=kz.exec(a);c=Number(a[1]);var d=Number(a[2]),e=Number(a[3]),f=Number(a[4]);f+=(Number(a[5])||0)/b.h;e+=f/b.frameRate;c=e+60*d+3600*c}else if(lz.test(a))c=mz(lz,a);else if(nz.test(a))c=mz(nz,a);else if(oz.test(a))a=oz.exec(a),c=Number(a[1])/b.frameRate;else if(pz.test(a))a=pz.exec(a),c=Number(a[1])/b.g;else if(qz.test(a))c=mz(qz,a);else if(a)throw new P(2,2,2001,"Could not parse cue time range in TTML");return c}
1144
- function mz(a,b){a=a.exec(b);return null==a||""==a[0]?null:(Number(a[4])||0)/1E3+(Number(a[3])||0)+60*(Number(a[2])||0)+3600*(Number(a[1])||0)}M("shaka.text.TtmlTextParser",Py);Py.prototype.parseMedia=Py.prototype.parseMedia;Py.prototype.setManifestType=Py.prototype.setManifestType;Py.prototype.setSequenceMode=Py.prototype.setSequenceMode;Py.prototype.parseInit=Py.prototype.parseInit;
1145
- function Sy(a,b,c,d){this.frameRate=Number(a)||30;this.h=Number(b)||1;this.g=Number(d);0==this.g&&(this.g=a?this.frameRate*this.h:1);c&&(a=/^(\d+) (\d+)$/g.exec(c))&&(this.frameRate*=Number(a[1])/Number(a[2]))}
1146
- var Ty=/^(\d{1,2}(?:\.\d+)?|100(?:\.0+)?)% (\d{1,2}(?:\.\d+)?|100(?:\.0+)?)%$/,fz=/^(\d{1,2}(?:\.\d+)?|100)%$/,ez=/^(\d+px|\d+em|\d*\.?\d+c)$/,Uy=/^(\d+)px (\d+)px$/,kz=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,lz=/^(?:(\d{2,}):)?(\d{2}):(\d{2})$/,nz=/^(?:(\d{2,}):)?(\d{2}):(\d{2}\.\d{2,})$/,oz=/^(\d*(?:\.\d*)?)f$/,pz=/^(\d*(?:\.\d*)?)t$/,qz=RegExp("^(?:(\\d*(?:\\.\\d*)?)h)?(?:(\\d*(?:\\.\\d*)?)m)?(?:(\\d*(?:\\.\\d*)?)s)?(?:(\\d*(?:\\.\\d*)?)ms)?$"),dz={left:Fc,center:"center",right:"end",start:Fc,
1147
- end:"end"},cz={left:"line-left",center:"center",right:"line-right"},Qy=["http://www.w3.org/ns/ttml#parameter","http://www.w3.org/2006/10/ttaf1#parameter"],Ry=["http://www.w3.org/ns/ttml#styling","http://www.w3.org/2006/10/ttaf1#styling"],Xy=["http://www.smpte-ra.org/schemas/2052-1/2010/smpte-tt","http://www.smpte-ra.org/schemas/2052-1/2013/smpte-tt"];ld["application/ttml+xml"]=function(){return new Py};function rz(){this.g=new Py}rz.prototype.parseInit=function(a){var b=!1;(new Tf).box("moov",Yf).box("trak",Yf).box("mdia",Yf).box("minf",Yf).box("stbl",Yf).S("stsd",$f).box("stpp",function(c){b=!0;c.parser.stop()}).parse(a);if(!b)throw new P(2,2,2007);};rz.prototype.setSequenceMode=function(){};rz.prototype.setManifestType=function(){};
1148
- rz.prototype.parseMedia=function(a,b,c){var d=this,e=!1,f=[];(new Tf).box("mdat",bg(function(g){e=!0;f=f.concat(d.g.parseMedia(g,b,c))})).parse(a,!1);if(!e)throw new P(2,2,2007);return f};M("shaka.text.Mp4TtmlParser",rz);rz.prototype.parseMedia=rz.prototype.parseMedia;rz.prototype.setManifestType=rz.prototype.setManifestType;rz.prototype.setSequenceMode=rz.prototype.setSequenceMode;rz.prototype.parseInit=rz.prototype.parseInit;ld['application/mp4; codecs="stpp"']=function(){return new rz};
1149
- ld['application/mp4; codecs="stpp.ttml"']=function(){return new rz};ld['application/mp4; codecs="stpp.ttml.im1t"']=function(){return new rz};ld['application/mp4; codecs="stpp.TTML.im1t"']=function(){return new rz};function sz(){this.h=!1;this.g="UNKNOWN"}sz.prototype.parseInit=function(){};sz.prototype.setSequenceMode=function(a){this.h=a};sz.prototype.setManifestType=function(a){this.g=a};
1150
- sz.prototype.parseMedia=function(a,b){a=Kf(a);a=a.replace(/\r\n|\r(?=[^\n]|$)/gm,"\n");var c=a.split(/\n{2,}/m);if(!/^WEBVTT($|[ \t\n])/m.test(c[0]))throw new P(2,2,2E3);a=b.vttOffset;if(c[0].includes("X-TIMESTAMP-MAP")&&this.h){var d=c[0].match(/LOCAL:((?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{3}))/m),e=c[0].match(/MPEGTS:(\d+)/m);if(d&&e){a=tz(new Gs(d[1]));if(null==a)throw new P(2,2,2E3);e=Number(e[1]);for(d=b.segmentStart-b.periodStart;95443.7176888889<=d;)d-=95443.7176888889,e+=8589934592;a=b.periodStart+
1137
+ function fz(a,b){b=t(b.split(" "));for(var c=b.next();!c.done;c=b.next())switch(c.value){case "underline":a.textDecoration.includes("underline")||a.textDecoration.push("underline");break;case "noUnderline":a.textDecoration.includes("underline")&&vc(a.textDecoration,"underline");break;case "lineThrough":a.textDecoration.includes("lineThrough")||a.textDecoration.push("lineThrough");break;case "noLineThrough":a.textDecoration.includes("lineThrough")&&vc(a.textDecoration,"lineThrough");break;case "overline":a.textDecoration.includes("overline")||
1138
+ a.textDecoration.push("overline");break;case "noOverline":a.textDecoration.includes("overline")&&vc(a.textDecoration,"overline")}}function az(a,b,c,d,e){e=void 0===e?!0:e;return(a=gz(a,c,d))?a:e?Uy(b,c,d):null}function Uy(a,b,c){if(!a)return null;var d=sg(a,Qy,c);return d?d:hz(a,b,c)}function gz(a,b,c){var d=sg(a,Qy,c);return d?d:hz(a,b,c)}
1139
+ function hz(a,b,c){a=Xy(a,"style",b,"");for(var d=null,e=0;e<a.length;e++){var f=rg(a[e],"urn:ebu:tt:style",c);f||(f=sg(a[e],Qy,c));f||(f=gz(a[e],b,c));f&&(d=f)}return d}
1140
+ function Xy(a,b,c,d,e){var f=[];if(!a||1>c.length)return f;var g=a;for(a=null;g&&!(a=e?rg(g,e,b):g.getAttribute(b))&&(g=g.parentNode,g instanceof Element););if(b=a)for(b=t(b.split(" ")),e=b.next();!e.done;e=b.next())for(e=e.value,a=t(c),g=a.next();!g.done;g=a.next())if(g=g.value,d+g.getAttribute("xml:id")==e){f.push(g);break}return f}function Zy(a,b,c,d){a=Yy(a,b);null==c?c=a.start:null!=a.start&&(c+=a.start);null==d?d=a.end:null!=a.start&&(d+=a.start);return{start:c,end:d}}
1141
+ function Yy(a,b){var c=iz(a.getAttribute("begin"),b),d=iz(a.getAttribute("end"),b);a=iz(a.getAttribute("dur"),b);null==d&&null!=a&&(d=c+a);return{start:c,end:d}}
1142
+ function iz(a,b){var c=null;if(jz.test(a)){a=jz.exec(a);c=Number(a[1]);var d=Number(a[2]),e=Number(a[3]),f=Number(a[4]);f+=(Number(a[5])||0)/b.h;e+=f/b.frameRate;c=e+60*d+3600*c}else if(kz.test(a))c=lz(kz,a);else if(mz.test(a))c=lz(mz,a);else if(nz.test(a))a=nz.exec(a),c=Number(a[1])/b.frameRate;else if(oz.test(a))a=oz.exec(a),c=Number(a[1])/b.g;else if(pz.test(a))c=lz(pz,a);else if(a)throw new P(2,2,2001,"Could not parse cue time range in TTML");return c}
1143
+ function lz(a,b){a=a.exec(b);return null==a||""==a[0]?null:(Number(a[4])||0)/1E3+(Number(a[3])||0)+60*(Number(a[2])||0)+3600*(Number(a[1])||0)}M("shaka.text.TtmlTextParser",Oy);Oy.prototype.parseMedia=Oy.prototype.parseMedia;Oy.prototype.setManifestType=Oy.prototype.setManifestType;Oy.prototype.setSequenceMode=Oy.prototype.setSequenceMode;Oy.prototype.parseInit=Oy.prototype.parseInit;
1144
+ function Ry(a,b,c,d){this.frameRate=Number(a)||30;this.h=Number(b)||1;this.g=Number(d);0==this.g&&(this.g=a?this.frameRate*this.h:1);c&&(a=/^(\d+) (\d+)$/g.exec(c))&&(this.frameRate*=Number(a[1])/Number(a[2]))}
1145
+ var Sy=/^(\d{1,2}(?:\.\d+)?|100(?:\.0+)?)% (\d{1,2}(?:\.\d+)?|100(?:\.0+)?)%$/,ez=/^(\d{1,2}(?:\.\d+)?|100)%$/,dz=/^(\d+px|\d+em|\d*\.?\d+c)$/,Ty=/^(\d+)px (\d+)px$/,jz=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,kz=/^(?:(\d{2,}):)?(\d{2}):(\d{2})$/,mz=/^(?:(\d{2,}):)?(\d{2}):(\d{2}\.\d{2,})$/,nz=/^(\d*(?:\.\d*)?)f$/,oz=/^(\d*(?:\.\d*)?)t$/,pz=RegExp("^(?:(\\d*(?:\\.\\d*)?)h)?(?:(\\d*(?:\\.\\d*)?)m)?(?:(\\d*(?:\\.\\d*)?)s)?(?:(\\d*(?:\\.\\d*)?)ms)?$"),cz={left:Fc,center:"center",right:"end",start:Fc,
1146
+ end:"end"},bz={left:"line-left",center:"center",right:"line-right"},Py=["http://www.w3.org/ns/ttml#parameter","http://www.w3.org/2006/10/ttaf1#parameter"],Qy=["http://www.w3.org/ns/ttml#styling","http://www.w3.org/2006/10/ttaf1#styling"],Wy=["http://www.smpte-ra.org/schemas/2052-1/2010/smpte-tt","http://www.smpte-ra.org/schemas/2052-1/2013/smpte-tt"];ld["application/ttml+xml"]=function(){return new Oy};function qz(){this.g=new Oy}qz.prototype.parseInit=function(a){var b=!1;(new Tf).box("moov",Yf).box("trak",Yf).box("mdia",Yf).box("minf",Yf).box("stbl",Yf).S("stsd",$f).box("stpp",function(c){b=!0;c.parser.stop()}).parse(a);if(!b)throw new P(2,2,2007);};qz.prototype.setSequenceMode=function(){};qz.prototype.setManifestType=function(){};
1147
+ qz.prototype.parseMedia=function(a,b,c){var d=this,e=!1,f=[];(new Tf).box("mdat",bg(function(g){e=!0;f=f.concat(d.g.parseMedia(g,b,c))})).parse(a,!1);if(!e)throw new P(2,2,2007);return f};M("shaka.text.Mp4TtmlParser",qz);qz.prototype.parseMedia=qz.prototype.parseMedia;qz.prototype.setManifestType=qz.prototype.setManifestType;qz.prototype.setSequenceMode=qz.prototype.setSequenceMode;qz.prototype.parseInit=qz.prototype.parseInit;ld['application/mp4; codecs="stpp"']=function(){return new qz};
1148
+ ld['application/mp4; codecs="stpp.ttml"']=function(){return new qz};ld['application/mp4; codecs="stpp.ttml.im1t"']=function(){return new qz};ld['application/mp4; codecs="stpp.TTML.im1t"']=function(){return new qz};function rz(){this.h=!1;this.g="UNKNOWN"}rz.prototype.parseInit=function(){};rz.prototype.setSequenceMode=function(a){this.h=a};rz.prototype.setManifestType=function(a){this.g=a};
1149
+ rz.prototype.parseMedia=function(a,b){a=Kf(a);a=a.replace(/\r\n|\r(?=[^\n]|$)/gm,"\n");var c=a.split(/\n{2,}/m);if(!/^WEBVTT($|[ \t\n])/m.test(c[0]))throw new P(2,2,2E3);a=b.vttOffset;if(c[0].includes("X-TIMESTAMP-MAP")&&this.h){var d=c[0].match(/LOCAL:((?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{3}))/m),e=c[0].match(/MPEGTS:(\d+)/m);if(d&&e){a=sz(new Gs(d[1]));if(null==a)throw new P(2,2,2E3);e=Number(e[1]);for(d=b.segmentStart-b.periodStart;95443.7176888889<=d;)d-=95443.7176888889,e+=8589934592;a=b.periodStart+
1151
1150
  e/9E4-a}}else c[0].includes("X-TIMESTAMP-MAP")&&"HLS"==this.g&&(a=b.segmentStart);b=[];e=t(c[0].split("\n"));for(d=e.next();!d.done;d=e.next())if(d=d.value,/^Region:/.test(d)){d=new Gs(d);var f=new zc;Js(d);Hs(d);for(var g=Js(d);g;){var h=f,k=g;(g=/^id=(.*)$/.exec(k))?h.id=g[1]:(g=/^width=(\d{1,2}|100)%$/.exec(k))?h.width=Number(g[1]):(g=/^lines=(\d+)$/.exec(k))?(h.height=Number(g[1]),h.heightUnits=2):(g=/^regionanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(k))?(h.regionAnchorX=Number(g[1]),h.regionAnchorY=
1152
- Number(g[2])):(g=/^viewportanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(k))?(h.viewportAnchorX=Number(g[1]),h.viewportAnchorY=Number(g[2])):/^scroll=up$/.exec(k)&&(h.scroll="up");Hs(d);g=Js(d)}b.push(f)}e=new Map;uz(e);d=[];c=t(c.slice(1));for(f=c.next();!f.done;f=c.next()){f=f.value.split("\n");if((1!=f.length||f[0])&&!/^NOTE($|[ \t])/.test(f[0])&&"STYLE"==f[0]){h=[];g=-1;for(k=1;k<f.length;k++)f[k].includes("::cue")&&(h.push([]),g=h.length-1),-1!=g&&(h[g].push(f[k]),f[k].includes("}")&&(g=-1));h=
1151
+ Number(g[2])):(g=/^viewportanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(k))?(h.viewportAnchorX=Number(g[1]),h.viewportAnchorY=Number(g[2])):/^scroll=up$/.exec(k)&&(h.scroll="up");Hs(d);g=Js(d)}b.push(f)}e=new Map;tz(e);d=[];c=t(c.slice(1));for(f=c.next();!f.done;f=c.next()){f=f.value.split("\n");if((1!=f.length||f[0])&&!/^NOTE($|[ \t])/.test(f[0])&&"STYLE"==f[0]){h=[];g=-1;for(k=1;k<f.length;k++)f[k].includes("::cue")&&(h.push([]),g=h.length-1),-1!=g&&(h[g].push(f[k]),f[k].includes("}")&&(g=-1));h=
1153
1152
  t(h);for(g=h.next();!g.done;g=h.next()){var l=g.value;g="global";(k=l[0].match(/\((.*)\)/))&&(g=k.pop());k=l.slice(1,-1);l[0].includes("}")&&(l=/\{(.*?)\}/.exec(l[0]))&&(k=l[1].split(";"));(l=e.get(g))||(l=new yc(0,0,""));for(var m=!1,n=0;n<k.length;n++){var q=/^\s*([^:]+):\s*(.*)/.exec(k[n]);if(q){var r=q[2].trim().replace(";","");switch(q[1].trim()){case "background-color":case "background":m=!0;l.backgroundColor=r;break;case "color":m=!0;l.color=r;break;case "font-family":m=!0;l.fontFamily=r;break;
1154
1153
  case "font-size":m=!0;l.fontSize=r;break;case "font-weight":if(700<=parseInt(r,10)||"bold"==r)m=!0,l.fontWeight=700;break;case "font-style":switch(r){case "normal":m=!0;l.fontStyle=Ic;break;case "italic":m=!0;l.fontStyle="italic";break;case "oblique":m=!0,l.fontStyle="oblique"}break;case "opacity":m=!0;l.opacity=parseFloat(r);break;case "text-combine-upright":m=!0;l.textCombineUpright=r;break;case "text-shadow":m=!0;l.textShadow=r;break;case "white-space":m=!0,l.wrapLine="noWrap"!=r}}}m&&e.set(g,
1155
- l)}}m=a;if(1==f.length&&!f[0]||/^NOTE($|[ \t])/.test(f[0])||"STYLE"==f[0]||"REGION"==f[0])f=null;else if(h=null,f[0].includes("--\x3e")||(h=f[0],f.splice(0,1)),g=new Gs(f[0]),k=tz(g),n=Is(g,/[ \t]+--\x3e[ \t]+/g),l=tz(g),null==k||null==n||null==l)Sa("Failed to parse VTT time code. Cue skipped:",h,f),f=null;else{k+=m;l+=m;f=f.slice(1).join("\n").trim();e.has("global")?(m=e.get("global").clone(),m.startTime=k,m.endTime=l,m.payload=""):m=new yc(k,l,"");Hs(g);for(k=Js(g);k;)vz(m,k,b),Hs(g),k=Js(g);wz(f,
1156
- m,e);null!=h&&(m.id=h);f=m}f&&d.push(f)}return d};function uz(a){for(var b=t(Object.entries(Oc)),c=b.next();!c.done;c=b.next()){var d=t(c.value);c=d.next().value;d=d.next().value;var e=new yc(0,0,"");e.color=d;a.set("."+c,e)}b=t(Object.entries(Pc));for(c=b.next();!c.done;c=b.next())d=t(c.value),c=d.next().value,d=d.next().value,e=new yc(0,0,""),e.backgroundColor=d,a.set("."+c,e)}
1157
- function wz(a,b,c){if(a.includes("<")){0===c.size&&uz(c);a:{for(var d=[],e=-1,f="",g=0;g<a.length;g++)if("/"===a[g]&&0<g&&"<"===a[g-1]){var h=a.indexOf(">",g);if(h<=g)break a;if((h=a.substring(g+1,h))&&"c"===h){var k=d.pop();k?k===h?(f+="/"+h+">",g+=h.length+1):k.startsWith("c.")?(g+=h.length+1,f+="/"+k+">"):f+=a[g]:f+=a[g]}else f+=a[g]}else"<"===a[g]?(e=g+1,"c"!=a[e]&&(e=-1)):">"===a[g]&&0<e&&(d.push(a.substr(e,g-e)),e=-1),f+=a[g];a=f}d=a;a=[];f=-1;for(e=0;e<d.length;e++)"<"===d[e]?f=e+1:">"===d[e]&&
1158
- 0<f&&(f=d.substr(f,e-f),f.match(xz)&&a.push(f),f=-1);a=t(a);for(e=a.next();!e.done;e=a.next())e=e.value,d=d.replace("<"+e+">",'<div time="'+e+'">'),d+="</div>";a=d;a:{e=a;f=[];g=-1;a="";d=!1;for(h=0;h<e.length;h++)if("/"===e[h]){k=e.indexOf(">",h);if(-1===k){a=e;break a}if((k=e.substring(h+1,k))&&"v"==k){d=!0;var l=null;f.length&&(l=f[f.length-1]);if(l){if(l===k)a+="/"+k+">";else{if(!l.startsWith("v")){a+=e[h];continue}a+="/"+l+">"}h+=k.length+1}else a+=e[h]}else a+=e[h]}else"<"===e[h]?(g=h+1,"v"!=
1159
- e[g]&&(g=-1)):">"===e[h]&&0<g&&(f.push(e.substr(g,h-g)),g=-1),a+=e[h];e=t(f);for(f=e.next();!f.done;f=e.next())f=f.value,g=f.replace(" ",".voice-"),a=a.replace("<"+f+">","<"+g+">"),a=a.replace("</"+f+">","</"+g+">"),d||(a+="</"+g+">")}if(d=Fg("<span>"+a+"</span>","span")){d=d.childNodes;if(1==d.length&&(e=d[0],e.nodeType==Node.TEXT_NODE||e.nodeType==Node.CDATA_SECTION_NODE)){b.payload=yz(a);return}a=t(d);for(d=a.next();!d.done;d=a.next())zz(d.value,b,c)}else b.payload=yz(a)}else b.payload=yz(a)}
1160
- function Az(a,b){return a&&0<a.length?a:b}
1161
- function zz(a,b,c){var d=b.clone();d.nestedCues=[];d.payload="";d.rubyTag="";d.line=null;d.region=new zc;d.position=null;d.size=0;if(a.nodeType===Node.ELEMENT_NODE&&a.nodeName)for(var e=t(a.nodeName.split(/(?=[ .])+/g)),f=e.next();!f.done;f=e.next()){var g=f=f.value;if(g.startsWith(".voice-")){var h=g.split("-").pop();g='v[voice="'+h+'"]';c.has(g)||(g="v[voice="+h+"]")}c.has(g)&&(g=c.get(g))&&(d.backgroundColor=Az(g.backgroundColor,d.backgroundColor),d.color=Az(g.color,d.color),d.fontFamily=Az(g.fontFamily,
1162
- d.fontFamily),d.fontSize=Az(g.fontSize,d.fontSize),d.fontWeight=g.fontWeight,d.fontStyle=g.fontStyle,d.opacity=g.opacity,d.rubyTag=g.rubyTag,d.textCombineUpright=g.textCombineUpright,d.textShadow=g.textShadow,d.wrapLine=g.wrapLine);switch(f){case "br":d=Jc(d.startTime,d.endTime);b.nestedCues.push(d);return;case "b":d.fontWeight=700;break;case "i":d.fontStyle="italic";break;case "u":d.textDecoration.push("underline");break;case "font":if(f=a.getAttribute("color"))d.color=f;break;case "div":f=a.getAttribute("time");
1163
- if(!f)break;if(f=tz(new Gs(f)))d.startTime=f;break;case "ruby":case "rp":case "rt":d.rubyTag=f}}e=a.childNodes;if(ug(a)||1==e.length&&ug(e[0]))for(e=!0,c=t(a.textContent.split("\n")),a=c.next();!a.done;a=c.next())a=a.value,e||(e=Jc(d.startTime,d.endTime),b.nestedCues.push(e)),0<a.length&&(e=d.clone(),e.payload=yz(a),b.nestedCues.push(e)),e=!1;else for(b.nestedCues.push(d),b=t(e),a=b.next();!a.done;a=b.next())zz(a.value,d,c)}
1164
- function vz(a,b,c){var d;if(d=/^align:(start|middle|center|end|left|right)$/.exec(b))b=d[1],"middle"==b?a.textAlign=Bc:a.textAlign=Lc[b.toUpperCase()];else if(d=/^vertical:(lr|rl)$/.exec(b))a.writingMode="lr"==d[1]?"vertical-lr":"vertical-rl";else if(d=/^size:([\d.]+)%$/.exec(b))a.size=Number(d[1]);else if(d=/^position:([\d.]+)%(?:,(line-left|line-right|middle|center|start|end|auto))?$/.exec(b))a.position=Number(d[1]),d[2]&&(b=d[2],a.positionAlign="line-left"==b||"start"==b?"line-left":"line-right"==
1165
- b||"end"==b?"line-right":"center"==b||"middle"==b?"center":Ac);else if(d=/^region:(.*)$/.exec(b)){if(b=Bz(c,d[1]))a.region=b}else if(c=/^line:([\d.]+)%(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=1,a.line=Number(c[1]),c[2]&&(a.lineAlign=Nc[c[2].toUpperCase()]);else if(c=/^line:(-?\d+)(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=Ec,a.line=Number(c[1]),c[2]&&(a.lineAlign=Nc[c[2].toUpperCase()])}
1166
- function Bz(a,b){a=a.filter(function(c){return c.id==b});return a.length?a[0]:null}function tz(a){a=Is(a,xz);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)}
1167
- function yz(a){var b={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'","&nbsp;":"\u00a0","&lrm;":"\u200e","&rlm;":"\u200f"},c=/&(?:amp|lt|gt|quot|#(0+)?39|nbsp|lrm|rlm);/g,d=RegExp(c.source);return a&&d.test(a)?a.replace(c,function(e){return b[e]||"'"}):a||""}M("shaka.text.VttTextParser",sz);sz.prototype.parseMedia=sz.prototype.parseMedia;sz.prototype.setManifestType=sz.prototype.setManifestType;sz.prototype.setSequenceMode=sz.prototype.setSequenceMode;sz.prototype.parseInit=sz.prototype.parseInit;
1168
- var xz=/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g;ld["text/vtt"]=function(){return new sz};ld['text/vtt; codecs="vtt"']=function(){return new sz};ld['text/vtt; codecs="wvtt"']=function(){return new sz};function Cz(){this.g=null}Cz.prototype.parseInit=function(a){var b=this,c=!1;(new Tf).box("moov",Yf).box("trak",Yf).box("mdia",Yf).S("mdhd",function(d){d=Xh(d.reader,d.version);b.g=d.timescale}).box("minf",Yf).box("stbl",Yf).S("stsd",$f).box("wvtt",function(){c=!0}).parse(a);if(!this.g)throw new P(2,2,2008);if(!c)throw new P(2,2,2008);};Cz.prototype.setSequenceMode=function(){};Cz.prototype.setManifestType=function(){};
1169
- Cz.prototype.parseMedia=function(a,b){if(!a.length)return[];if(!this.g)throw new P(2,2,2008);var c=0,d=[],e,f=[],g=!1,h=!1,k=!1,l=null;(new Tf).box("moof",Yf).box("traf",Yf).S("tfdt",function(A){g=!0;c=Vh(A.reader,A.version).baseMediaDecodeTime}).S("tfhd",function(A){l=Uh(A.reader,A.flags).Hg}).S("trun",function(A){h=!0;d=Yh(A.reader,A.version,A.flags).bh}).box("mdat",bg(function(A){k=!0;e=A})).parse(a,!1);if(!k&&!g&&!h)throw new P(2,2,2008);a=c;for(var m=new Qf(e,0),n=t(d),q=n.next();!q.done;q=n.next()){q=
1170
- q.value;var r=q.$f||l,u=q.De?c+q.De:a;a=u+(r||0);var v=0;do{var y=m.N();v+=y;var z=m.N(),x=null;"vttc"==Xf(z)?8<y&&(x=m.Ob(y-8)):m.skip(y-8);r&&x&&(y=Dz(x,b.periodStart+u/this.g,b.periodStart+a/this.g),f.push(y))}while(q.sampleSize&&v<q.sampleSize)}return f.filter(td)};function Dz(a,b,c){var d,e,f;(new Tf).box("payl",bg(function(g){d=Kf(g)})).box("iden",bg(function(g){e=Kf(g)})).box("sttg",bg(function(g){f=Kf(g)})).parse(a);return d?Ez(d,e,f,b,c):null}
1171
- function Ez(a,b,c,d,e){d=new yc(d,e,"");wz(a,d,new Map);b&&(d.id=b);if(c)for(a=new Gs(c),b=Js(a);b;)vz(d,b,[]),Hs(a),b=Js(a);return d}M("shaka.text.Mp4VttParser",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;ld['application/mp4; codecs="wvtt"']=function(){return new Cz};function Fz(){}Fz.prototype.parseInit=function(){};Fz.prototype.setSequenceMode=function(){};Fz.prototype.setManifestType=function(){};Fz.prototype.parseMedia=function(a){var b=Kf(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 Gs(c[0]),e=Gz(d),f=Is(d,/,/g);d=Gz(d);if(null==e||null==f||null==d)throw new P(2,2,2001,"Could not parse cue time range in SubViewer");a.push(new yc(e,d,c.slice(1).join("\n").trim()))}return a};
1172
- function Gz(a){a=Is(a,/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g);if(null==a)return null;var b=Number(a[2]),c=Number(a[3]);return 59<b||59<c?null:Number(a[4])/1E3+c+60*b+3600*(Number(a[1])||0)}M("shaka.text.SbvTextParser",Fz);Fz.prototype.parseMedia=Fz.prototype.parseMedia;Fz.prototype.setManifestType=Fz.prototype.setManifestType;Fz.prototype.setSequenceMode=Fz.prototype.setSequenceMode;Fz.prototype.parseInit=Fz.prototype.parseInit;ld["text/x-subviewer"]=function(){return new Fz};function Hz(){this.g=new sz}Hz.prototype.parseInit=function(){};Hz.prototype.setSequenceMode=function(){};Hz.prototype.setManifestType=function(){};Hz.prototype.parseMedia=function(a,b,c){a=Kf(a);a=Iz(a);a=lc(Of(a));return this.g.parseMedia(a,b,c)};
1173
- function Iz(a){var b="WEBVTT\n\n";if(""==a)return b;a=a.replace(/\r+/g,"");a=a.trim();a=t(a.split("\n\n"));for(var c=a.next();!c.done;c=a.next())c=c.value.split(/\n/),c[0].match(/\d+/)&&c.shift(),c[0]=c[0].replace(/,/g,"."),b+=c.join("\n").replace(/{b}/g,"<b>").replace(/{\/b}/g,"</b>").replace(/{i}/g,"<i>").replace(/{\/i}/g,"</i>").replace(/{u}/g,"<u>").replace(/{\/u}/g,"</u>")+"\n\n";return b}M("shaka.text.SrtTextParser",Hz);Hz.srt2webvtt=Iz;Hz.prototype.parseMedia=Hz.prototype.parseMedia;
1174
- Hz.prototype.setManifestType=Hz.prototype.setManifestType;Hz.prototype.setSequenceMode=Hz.prototype.setSequenceMode;Hz.prototype.parseInit=Hz.prototype.parseInit;ld["text/srt"]=function(){return new Hz};function Jz(){}Jz.prototype.parseInit=function(){};Jz.prototype.setSequenceMode=function(){};Jz.prototype.setManifestType=function(){};
1175
- Jz.prototype.parseMedia=function(a){var b="",c="";a=Kf(a).split(/\r?\n\s*\r?\n/);a=t(a);for(var d=a.next();!d.done;d=a.next()){var e=Kz.exec(d.value);e&&(d=e[1],e=e[2],"V4 Styles"==d||"V4+ Styles"==d?b=e:"Events"==d&&(c=e))}a=[];d=null;b=t(b.split(/\r?\n/));for(var f=b.next();!f.done;f=b.next())if(e=f.value,!/^\s*;/.test(e)&&(f=Lz.exec(e)))if(e=f[1].trim(),f=f[2].trim(),"Format"==e)d=f.split(Mz);else if("Style"==e){e=f.split(Mz);f={};for(var g=0;g<d.length&&g<e.length;g++)f[d[g]]=e[g];a.push(f)}d=
1176
- [];b=null;e={};c=t(c.split(/\r?\n/));for(f=c.next();!f.done;e={Se:e.Se},f=c.next())if(f=f.value,!/^\s*;/.test(f)&&(g=Lz.exec(f)))if(f=g[1].trim(),g=g[2].trim(),"Format"==f)b=g.split(Mz);else if("Dialogue"==f){g=g.split(Mz);f={};for(var h=0;h<b.length&&h<g.length;h++)f[b[h]]=g[h];h=Nz(f.Start);var k=Nz(f.End);g=new yc(h,k,g.slice(b.length-1).join(",").replace(/\\N/g,"\n").replace(/\{[^}]+\}/g,""));e.Se=f.Style;(f=a.find(function(l){return function(m){return m.Name==l.Se}}(e)))&&Oz(g,f);d.push(g)}return d};
1177
- function Oz(a,b){var c=b.Fontname;c&&(a.fontFamily=c);if(c=b.Fontsize)a.fontSize=c+"px";if(c=b.PrimaryColour)if(c=Pz(c))a.color=c;if(c=b.BackColour)if(c=Pz(c))a.backgroundColor=c;b.Bold&&(a.fontWeight=700);b.Italic&&(a.fontStyle="italic");b.Underline&&a.textDecoration.push("underline");if(c=b.Spacing)a.letterSpacing=c+"px";if(c=b.Alignment)switch(parseInt(c,10)){case 1:a.displayAlign=Gc;a.textAlign="start";break;case 2:a.displayAlign=Gc;a.textAlign=Bc;break;case 3:a.displayAlign=Gc;a.textAlign="end";
1154
+ l)}}m=a;if(1==f.length&&!f[0]||/^NOTE($|[ \t])/.test(f[0])||"STYLE"==f[0]||"REGION"==f[0])f=null;else if(h=null,f[0].includes("--\x3e")||(h=f[0],f.splice(0,1)),g=new Gs(f[0]),k=sz(g),n=Is(g,/[ \t]+--\x3e[ \t]+/g),l=sz(g),null==k||null==n||null==l)Sa("Failed to parse VTT time code. Cue skipped:",h,f),f=null;else{k+=m;l+=m;f=f.slice(1).join("\n").trim();e.has("global")?(m=e.get("global").clone(),m.startTime=k,m.endTime=l,m.payload=""):m=new yc(k,l,"");Hs(g);for(k=Js(g);k;)uz(m,k,b),Hs(g),k=Js(g);vz(f,
1155
+ m,e);null!=h&&(m.id=h);f=m}f&&d.push(f)}return d};function tz(a){for(var b=t(Object.entries(Oc)),c=b.next();!c.done;c=b.next()){var d=t(c.value);c=d.next().value;d=d.next().value;var e=new yc(0,0,"");e.color=d;a.set("."+c,e)}b=t(Object.entries(Pc));for(c=b.next();!c.done;c=b.next())d=t(c.value),c=d.next().value,d=d.next().value,e=new yc(0,0,""),e.backgroundColor=d,a.set("."+c,e)}
1156
+ function vz(a,b,c){if(a.includes("<")){0===c.size&&tz(c);a:{for(var d=[],e=-1,f="",g=0;g<a.length;g++)if("/"===a[g]&&0<g&&"<"===a[g-1]){var h=a.indexOf(">",g);if(h<=g)break a;if((h=a.substring(g+1,h))&&"c"===h){var k=d.pop();k?k===h?(f+="/"+h+">",g+=h.length+1):k.startsWith("c.")?(g+=h.length+1,f+="/"+k+">"):f+=a[g]:f+=a[g]}else f+=a[g]}else"<"===a[g]?(e=g+1,"c"!=a[e]&&(e=-1)):">"===a[g]&&0<e&&(d.push(a.substr(e,g-e)),e=-1),f+=a[g];a=f}d=a;a=[];f=-1;for(e=0;e<d.length;e++)"<"===d[e]?f=e+1:">"===d[e]&&
1157
+ 0<f&&(f=d.substr(f,e-f),f.match(wz)&&a.push(f),f=-1);a=t(a);for(e=a.next();!e.done;e=a.next())e=e.value,d=d.replace("<"+e+">",'<div time="'+e+'">'),d+="</div>";a=d;a:{e=a;f=[];g=-1;a="";d=!1;for(h=0;h<e.length;h++)if("/"===e[h]){k=e.indexOf(">",h);if(-1===k){a=e;break a}if((k=e.substring(h+1,k))&&"v"==k){d=!0;var l=null;f.length&&(l=f[f.length-1]);if(l){if(l===k)a+="/"+k+">";else{if(!l.startsWith("v")){a+=e[h];continue}a+="/"+l+">"}h+=k.length+1}else a+=e[h]}else a+=e[h]}else"<"===e[h]?(g=h+1,"v"!=
1158
+ e[g]&&(g=-1)):">"===e[h]&&0<g&&(f.push(e.substr(g,h-g)),g=-1),a+=e[h];e=t(f);for(f=e.next();!f.done;f=e.next())f=f.value,g=f.replace(" ",".voice-"),a=a.replace("<"+f+">","<"+g+">"),a=a.replace("</"+f+">","</"+g+">"),d||(a+="</"+g+">")}if(d=Fg("<span>"+a+"</span>","span")){d=d.childNodes;if(1==d.length&&(e=d[0],e.nodeType==Node.TEXT_NODE||e.nodeType==Node.CDATA_SECTION_NODE)){b.payload=xz(a);return}a=t(d);for(d=a.next();!d.done;d=a.next())yz(d.value,b,c)}else b.payload=xz(a)}else b.payload=xz(a)}
1159
+ function zz(a,b){return a&&0<a.length?a:b}
1160
+ function yz(a,b,c){var d=b.clone();d.nestedCues=[];d.payload="";d.rubyTag="";d.line=null;d.region=new zc;d.position=null;d.size=0;if(a.nodeType===Node.ELEMENT_NODE&&a.nodeName)for(var e=t(a.nodeName.split(/(?=[ .])+/g)),f=e.next();!f.done;f=e.next()){var g=f=f.value;if(g.startsWith(".voice-")){var h=g.split("-").pop();g='v[voice="'+h+'"]';c.has(g)||(g="v[voice="+h+"]")}c.has(g)&&(g=c.get(g))&&(d.backgroundColor=zz(g.backgroundColor,d.backgroundColor),d.color=zz(g.color,d.color),d.fontFamily=zz(g.fontFamily,
1161
+ d.fontFamily),d.fontSize=zz(g.fontSize,d.fontSize),d.textShadow=zz(g.textShadow,d.textShadow),d.fontWeight=g.fontWeight,d.fontStyle=g.fontStyle,d.opacity=g.opacity,d.rubyTag=g.rubyTag,d.textCombineUpright=g.textCombineUpright,d.wrapLine=g.wrapLine);switch(f){case "br":d=Jc(d.startTime,d.endTime);b.nestedCues.push(d);return;case "b":d.fontWeight=700;break;case "i":d.fontStyle="italic";break;case "u":d.textDecoration.push("underline");break;case "font":if(f=a.getAttribute("color"))d.color=f;break;case "div":f=
1162
+ a.getAttribute("time");if(!f)break;if(f=sz(new Gs(f)))d.startTime=f;break;case "ruby":case "rp":case "rt":d.rubyTag=f}}e=a.childNodes;if(ug(a)||1==e.length&&ug(e[0]))for(e=!0,c=t(a.textContent.split("\n")),a=c.next();!a.done;a=c.next())a=a.value,e||(e=Jc(d.startTime,d.endTime),b.nestedCues.push(e)),0<a.length&&(e=d.clone(),e.payload=xz(a),b.nestedCues.push(e)),e=!1;else for(b.nestedCues.push(d),b=t(e),a=b.next();!a.done;a=b.next())yz(a.value,d,c)}
1163
+ function uz(a,b,c){var d;if(d=/^align:(start|middle|center|end|left|right)$/.exec(b))b=d[1],"middle"==b?a.textAlign=Bc:a.textAlign=Lc[b.toUpperCase()];else if(d=/^vertical:(lr|rl)$/.exec(b))a.writingMode="lr"==d[1]?"vertical-lr":"vertical-rl";else if(d=/^size:([\d.]+)%$/.exec(b))a.size=Number(d[1]);else if(d=/^position:([\d.]+)%(?:,(line-left|line-right|middle|center|start|end|auto))?$/.exec(b))a.position=Number(d[1]),d[2]&&(b=d[2],a.positionAlign="line-left"==b||"start"==b?"line-left":"line-right"==
1164
+ b||"end"==b?"line-right":"center"==b||"middle"==b?"center":Ac);else if(d=/^region:(.*)$/.exec(b)){if(b=Az(c,d[1]))a.region=b}else if(c=/^line:([\d.]+)%(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=1,a.line=Number(c[1]),c[2]&&(a.lineAlign=Nc[c[2].toUpperCase()]);else if(c=/^line:(-?\d+)(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=Ec,a.line=Number(c[1]),c[2]&&(a.lineAlign=Nc[c[2].toUpperCase()])}
1165
+ function Az(a,b){a=a.filter(function(c){return c.id==b});return a.length?a[0]:null}function sz(a){a=Is(a,wz);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)}
1166
+ function xz(a){var b={"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'","&nbsp;":"\u00a0","&lrm;":"\u200e","&rlm;":"\u200f"},c=/&(?:amp|lt|gt|quot|#(0+)?39|nbsp|lrm|rlm);/g,d=RegExp(c.source);return a&&d.test(a)?a.replace(c,function(e){return b[e]||"'"}):a||""}M("shaka.text.VttTextParser",rz);rz.prototype.parseMedia=rz.prototype.parseMedia;rz.prototype.setManifestType=rz.prototype.setManifestType;rz.prototype.setSequenceMode=rz.prototype.setSequenceMode;rz.prototype.parseInit=rz.prototype.parseInit;
1167
+ var wz=/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g;ld["text/vtt"]=function(){return new rz};ld['text/vtt; codecs="vtt"']=function(){return new rz};ld['text/vtt; codecs="wvtt"']=function(){return new rz};function Bz(){this.g=null}Bz.prototype.parseInit=function(a){var b=this,c=!1;(new Tf).box("moov",Yf).box("trak",Yf).box("mdia",Yf).S("mdhd",function(d){d=Wh(d.reader,d.version);b.g=d.timescale}).box("minf",Yf).box("stbl",Yf).S("stsd",$f).box("wvtt",function(){c=!0}).parse(a);if(!this.g)throw new P(2,2,2008);if(!c)throw new P(2,2,2008);};Bz.prototype.setSequenceMode=function(){};Bz.prototype.setManifestType=function(){};
1168
+ Bz.prototype.parseMedia=function(a,b){if(!a.length)return[];if(!this.g)throw new P(2,2,2008);var c=0,d=[],e,f=[],g=!1,h=!1,k=!1,l=null;(new Tf).box("moof",Yf).box("traf",Yf).S("tfdt",function(A){g=!0;c=Vh(A.reader,A.version).baseMediaDecodeTime}).S("tfhd",function(A){l=Uh(A.reader,A.flags).Hg}).S("trun",function(A){h=!0;d=Yh(A.reader,A.version,A.flags).bh}).box("mdat",bg(function(A){k=!0;e=A})).parse(a,!1);if(!k&&!g&&!h)throw new P(2,2,2008);a=c;for(var m=new Qf(e,0),n=t(d),q=n.next();!q.done;q=n.next()){q=
1169
+ q.value;var r=q.$f||l,u=q.De?c+q.De:a;a=u+(r||0);var v=0;do{var y=m.N();v+=y;var z=m.N(),x=null;"vttc"==Xf(z)?8<y&&(x=m.Qb(y-8)):m.skip(y-8);r&&x&&(y=Cz(x,b.periodStart+u/this.g,b.periodStart+a/this.g),f.push(y))}while(q.sampleSize&&v<q.sampleSize)}return f.filter(td)};function Cz(a,b,c){var d,e,f;(new Tf).box("payl",bg(function(g){d=Kf(g)})).box("iden",bg(function(g){e=Kf(g)})).box("sttg",bg(function(g){f=Kf(g)})).parse(a);return d?Dz(d,e,f,b,c):null}
1170
+ function Dz(a,b,c,d,e){d=new yc(d,e,"");vz(a,d,new Map);b&&(d.id=b);if(c)for(a=new Gs(c),b=Js(a);b;)uz(d,b,[]),Hs(a),b=Js(a);return d}M("shaka.text.Mp4VttParser",Bz);Bz.prototype.parseMedia=Bz.prototype.parseMedia;Bz.prototype.setManifestType=Bz.prototype.setManifestType;Bz.prototype.setSequenceMode=Bz.prototype.setSequenceMode;Bz.prototype.parseInit=Bz.prototype.parseInit;ld['application/mp4; codecs="wvtt"']=function(){return new Bz};function Ez(){}Ez.prototype.parseInit=function(){};Ez.prototype.setSequenceMode=function(){};Ez.prototype.setManifestType=function(){};Ez.prototype.parseMedia=function(a){var b=Kf(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 Gs(c[0]),e=Fz(d),f=Is(d,/,/g);d=Fz(d);if(null==e||null==f||null==d)throw new P(2,2,2001,"Could not parse cue time range in SubViewer");a.push(new yc(e,d,c.slice(1).join("\n").trim()))}return a};
1171
+ function Fz(a){a=Is(a,/(?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{2,3})/g);if(null==a)return null;var b=Number(a[2]),c=Number(a[3]);return 59<b||59<c?null:Number(a[4])/1E3+c+60*b+3600*(Number(a[1])||0)}M("shaka.text.SbvTextParser",Ez);Ez.prototype.parseMedia=Ez.prototype.parseMedia;Ez.prototype.setManifestType=Ez.prototype.setManifestType;Ez.prototype.setSequenceMode=Ez.prototype.setSequenceMode;Ez.prototype.parseInit=Ez.prototype.parseInit;ld["text/x-subviewer"]=function(){return new Ez};function Gz(){this.g=new rz}Gz.prototype.parseInit=function(){};Gz.prototype.setSequenceMode=function(){};Gz.prototype.setManifestType=function(){};Gz.prototype.parseMedia=function(a,b,c){a=Kf(a);a=Hz(a);a=lc(Of(a));return this.g.parseMedia(a,b,c)};
1172
+ function Hz(a){var b="WEBVTT\n\n";if(""==a)return b;a=a.replace(/\r+/g,"");a=a.trim();a=t(a.split("\n\n"));for(var c=a.next();!c.done;c=a.next())c=c.value.split(/\n/),c[0].match(/\d+/)&&c.shift(),c[0]=c[0].replace(/,/g,"."),b+=c.join("\n").replace(/{b}/g,"<b>").replace(/{\/b}/g,"</b>").replace(/{i}/g,"<i>").replace(/{\/i}/g,"</i>").replace(/{u}/g,"<u>").replace(/{\/u}/g,"</u>")+"\n\n";return b}M("shaka.text.SrtTextParser",Gz);Gz.srt2webvtt=Hz;Gz.prototype.parseMedia=Gz.prototype.parseMedia;
1173
+ Gz.prototype.setManifestType=Gz.prototype.setManifestType;Gz.prototype.setSequenceMode=Gz.prototype.setSequenceMode;Gz.prototype.parseInit=Gz.prototype.parseInit;ld["text/srt"]=function(){return new Gz};function Iz(){}Iz.prototype.parseInit=function(){};Iz.prototype.setSequenceMode=function(){};Iz.prototype.setManifestType=function(){};
1174
+ Iz.prototype.parseMedia=function(a){var b="",c="";a=Kf(a).split(/\r?\n\s*\r?\n/);a=t(a);for(var d=a.next();!d.done;d=a.next()){var e=Jz.exec(d.value);e&&(d=e[1],e=e[2],"V4 Styles"==d||"V4+ Styles"==d?b=e:"Events"==d&&(c=e))}a=[];d=null;b=t(b.split(/\r?\n/));for(var f=b.next();!f.done;f=b.next())if(e=f.value,!/^\s*;/.test(e)&&(f=Kz.exec(e)))if(e=f[1].trim(),f=f[2].trim(),"Format"==e)d=f.split(Lz);else if("Style"==e){e=f.split(Lz);f={};for(var g=0;g<d.length&&g<e.length;g++)f[d[g]]=e[g];a.push(f)}d=
1175
+ [];b=null;e={};c=t(c.split(/\r?\n/));for(f=c.next();!f.done;e={Se:e.Se},f=c.next())if(f=f.value,!/^\s*;/.test(f)&&(g=Kz.exec(f)))if(f=g[1].trim(),g=g[2].trim(),"Format"==f)b=g.split(Lz);else if("Dialogue"==f){g=g.split(Lz);f={};for(var h=0;h<b.length&&h<g.length;h++)f[b[h]]=g[h];h=Mz(f.Start);var k=Mz(f.End);g=new yc(h,k,g.slice(b.length-1).join(",").replace(/\\N/g,"\n").replace(/\{[^}]+\}/g,""));e.Se=f.Style;(f=a.find(function(l){return function(m){return m.Name==l.Se}}(e)))&&Nz(g,f);d.push(g)}return d};
1176
+ function Nz(a,b){var c=b.Fontname;c&&(a.fontFamily=c);if(c=b.Fontsize)a.fontSize=c+"px";if(c=b.PrimaryColour)if(c=Oz(c))a.color=c;if(c=b.BackColour)if(c=Oz(c))a.backgroundColor=c;b.Bold&&(a.fontWeight=700);b.Italic&&(a.fontStyle="italic");b.Underline&&a.textDecoration.push("underline");if(c=b.Spacing)a.letterSpacing=c+"px";if(c=b.Alignment)switch(parseInt(c,10)){case 1:a.displayAlign=Gc;a.textAlign="start";break;case 2:a.displayAlign=Gc;a.textAlign=Bc;break;case 3:a.displayAlign=Gc;a.textAlign="end";
1178
1177
  break;case 5:a.displayAlign="before";a.textAlign="start";break;case 6:a.displayAlign="before";a.textAlign=Bc;break;case 7:a.displayAlign="before";a.textAlign="end";break;case 9:a.displayAlign="center";a.textAlign="start";break;case 10:a.displayAlign="center";a.textAlign=Bc;break;case 11:a.displayAlign="center",a.textAlign="end"}if(b=b.AlphaLevel)a.opacity=parseFloat(b)}
1179
- function Pz(a){a=parseInt(a.replace("&H",""),16);return 0<=a?"rgba("+(a&255)+","+(a>>8&255)+","+(a>>16&255)+","+(a>>24&255^255)/255+")":null}function Nz(a){a=Qz.exec(a);return 3600*(a[1]?parseInt(a[1].replace(":",""),10):0)+60*parseInt(a[2],10)+parseFloat(a[3])}M("shaka.text.SsaTextParser",Jz);Jz.prototype.parseMedia=Jz.prototype.parseMedia;Jz.prototype.setManifestType=Jz.prototype.setManifestType;Jz.prototype.setSequenceMode=Jz.prototype.setSequenceMode;Jz.prototype.parseInit=Jz.prototype.parseInit;
1180
- var Kz=/^\s*\[([^\]]+)\]\r?\n([\s\S]*)/,Lz=/^\s*([^:]+):\s*(.*)/,Mz=/\s*,\s*/,Qz=/^(\d+:)?(\d{1,2}):(\d{1,2}(?:[.]\d{1,3})?)?$/;ld["text/x-ssa"]=function(){return new Jz};function Rz(a,b){var c=a[b+1]&1?7:9;return b+c<=a.length&&(a=((a[b+3]&3)<<11|a[b+4]<<3|(a[b+5]&224)>>>5)-c,0<a)?{ge:c,X:a}:null}function Sz(a,b){var c=[96E3,88200,64E3,48E3,44100,32E3,24E3,22050,16E3,12E3,11025,8E3,7350],d=(a[b+2]&60)>>>2;if(d>c.length-1)return null;var e=((a[b+2]&192)>>>6)+1,f=(a[b+2]&1)<<2;f|=(a[b+3]&192)>>>6;return{sampleRate:c[d],channelCount:f,va:"mp4a.40."+e}}
1181
- function Tz(a,b){if(b+1<a.length&&255===a[b]&&240===(a[b+1]&246)){var c=a[b+1]&1?7:9;if(b+c>=a.length)return!1;var d=(a[b+3]&3)<<11|a[b+4]<<3|(a[b+5]&224)>>>5;if(d<=c)return!1;b+=d;return b===a.length||b+1<a.length&&255===a[b]&&240===(a[b+1]&246)}return!1}
1182
- function Uz(a,b){switch(a){case "mp4a.40.2":if(1===b)return new Uint8Array([0,200,0,128,35,128]);if(2===b)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(3===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);if(4===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);if(5===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,56]);if(6===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,
1183
- 2,0,178,0,32,8,224]);break;default:if(1===b)return new Uint8Array([1,64,34,128,163,78,230,128,186,8,0,0,0,28,6,241,193,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(2===b||3===b)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94])}return null};function Vz(a){this.i=a;this.h=0;this.g=new Map}p=Vz.prototype;p.destroy=function(){this.g.clear()};p.isSupported=function(a){return"audio/aac"==a.toLowerCase().split(";")[0]?dc(this.convertCodecs("audio",a)):!1};p.convertCodecs=function(a,b){return"audio/aac"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="'+(id(b)||"mp4a.40.2")+'"':b};p.getOriginalMimeType=function(){return this.i};
1184
- p.transmux=function(a,b,c,d){for(var e=lc(a),f=Th(e),g=f.length;g<e.length&&!Tz(e,g);g++);a=1E3*c.endTime;f=Sh(f);f.length&&c&&(c=f.find(function(l){return"com.apple.streaming.transportStreamTimestamp"===l.description}))&&(a=c.data);c=Sz(e,g);if(!c)return Promise.reject(new P(2,3,3018));b.audioSamplingRate=c.sampleRate;b.channelsCount=c.channelCount;for(f=[];g<e.length;){var h=Rz(e,g);if(!h)return Promise.reject(new P(2,3,3018));var k=h.ge+h.X;g+k<=e.length&&f.push({data:e.subarray(g+h.ge,g+k),size:h.X,
1185
- duration:1024,jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}});g+=k}e=c.sampleRate;a=Math.floor(a*e/1E3);d={id:b.id,type:"audio",codecs:c.va,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:e,duration:d,hb:[],na:new Uint8Array([]),Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.h,baseMediaDecodeTime:a,eb:f},stream:b};a=new iu([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=qu(a),this.g.set(b.id,d));b=Hu(a);this.h++;b=jg(d,b);return Promise.resolve(b)};M("shaka.transmuxer.AacTransmuxer",Vz);
1186
- Vz.prototype.transmux=Vz.prototype.transmux;Vz.prototype.getOriginalMimeType=Vz.prototype.getOriginalMimeType;Vz.prototype.convertCodecs=Vz.prototype.convertCodecs;Vz.prototype.isSupported=Vz.prototype.isSupported;Vz.prototype.destroy=Vz.prototype.destroy;Uc("audio/aac",function(){return new Vz("audio/aac")},$c);function Wz(a,b){if(b+8>a.length||11!==a[b]||119!==a[b+1])return null;var c=a[b+4]>>6;if(3<=c)return null;var d=a[b+4]&63,e=2*[64,69,96,64,70,96,80,87,120,80,88,120,96,104,144,96,105,144,112,121,168,112,122,168,128,139,192,128,140,192,160,174,240,160,175,240,192,208,288,192,209,288,224,243,336,224,244,336,256,278,384,256,279,384,320,348,480,320,349,480,384,417,576,384,418,576,448,487,672,448,488,672,512,557,768,512,558,768,640,696,960,640,697,960,768,835,1152,768,836,1152,896,975,1344,896,976,1344,
1178
+ function Oz(a){a=parseInt(a.replace("&H",""),16);return 0<=a?"rgba("+(a&255)+","+(a>>8&255)+","+(a>>16&255)+","+(a>>24&255^255)/255+")":null}function Mz(a){a=Pz.exec(a);return 3600*(a[1]?parseInt(a[1].replace(":",""),10):0)+60*parseInt(a[2],10)+parseFloat(a[3])}M("shaka.text.SsaTextParser",Iz);Iz.prototype.parseMedia=Iz.prototype.parseMedia;Iz.prototype.setManifestType=Iz.prototype.setManifestType;Iz.prototype.setSequenceMode=Iz.prototype.setSequenceMode;Iz.prototype.parseInit=Iz.prototype.parseInit;
1179
+ var Jz=/^\s*\[([^\]]+)\]\r?\n([\s\S]*)/,Kz=/^\s*([^:]+):\s*(.*)/,Lz=/\s*,\s*/,Pz=/^(\d+:)?(\d{1,2}):(\d{1,2}(?:[.]\d{1,3})?)?$/;ld["text/x-ssa"]=function(){return new Iz};function Qz(a,b){var c=a[b+1]&1?7:9;return b+c<=a.length&&(a=((a[b+3]&3)<<11|a[b+4]<<3|(a[b+5]&224)>>>5)-c,0<a)?{ge:c,X:a}:null}function Rz(a,b){var c=[96E3,88200,64E3,48E3,44100,32E3,24E3,22050,16E3,12E3,11025,8E3,7350],d=(a[b+2]&60)>>>2;if(d>c.length-1)return null;var e=((a[b+2]&192)>>>6)+1,f=(a[b+2]&1)<<2;f|=(a[b+3]&192)>>>6;return{sampleRate:c[d],channelCount:f,va:"mp4a.40."+e}}
1180
+ function Sz(a,b){if(b+1<a.length&&255===a[b]&&240===(a[b+1]&246)){var c=a[b+1]&1?7:9;if(b+c>=a.length)return!1;var d=(a[b+3]&3)<<11|a[b+4]<<3|(a[b+5]&224)>>>5;if(d<=c)return!1;b+=d;return b===a.length||b+1<a.length&&255===a[b]&&240===(a[b+1]&246)}return!1}
1181
+ function Tz(a,b){switch(a){case "mp4a.40.2":if(1===b)return new Uint8Array([0,200,0,128,35,128]);if(2===b)return new Uint8Array([33,0,73,144,2,25,0,35,128]);if(3===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,142]);if(4===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,128,44,128,8,2,56]);if(5===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,2,56]);if(6===b)return new Uint8Array([0,200,0,128,32,132,1,38,64,8,100,0,130,48,4,153,0,33,144,
1182
+ 2,0,178,0,32,8,224]);break;default:if(1===b)return new Uint8Array([1,64,34,128,163,78,230,128,186,8,0,0,0,28,6,241,193,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94]);if(2===b||3===b)return new Uint8Array([1,64,34,128,163,94,230,128,186,8,0,0,0,0,149,0,6,241,161,10,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,90,94])}return null};function Uz(a){this.i=a;this.h=0;this.g=new Map}p=Uz.prototype;p.destroy=function(){this.g.clear()};p.isSupported=function(a){return"audio/aac"==a.toLowerCase().split(";")[0]?dc(this.convertCodecs("audio",a)):!1};p.convertCodecs=function(a,b){return"audio/aac"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="'+(id(b)||"mp4a.40.2")+'"':b};p.getOriginalMimeType=function(){return this.i};
1183
+ p.transmux=function(a,b,c,d){for(var e=lc(a),f=Th(e),g=f.length;g<e.length&&!Sz(e,g);g++);a=1E3*c.endTime;f=Sh(f);f.length&&c&&(c=f.find(function(l){return"com.apple.streaming.transportStreamTimestamp"===l.description}))&&(a=c.data);c=Rz(e,g);if(!c)return Promise.reject(new P(2,3,3018));b.audioSamplingRate=c.sampleRate;b.channelsCount=c.channelCount;for(f=[];g<e.length;){var h=Qz(e,g);if(!h)return Promise.reject(new P(2,3,3018));var k=h.ge+h.X;g+k<=e.length&&f.push({data:e.subarray(g+h.ge,g+k),size:h.X,
1184
+ duration:1024,jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}});g+=k}e=c.sampleRate;a=Math.floor(a*e/1E3);d={id:b.id,type:"audio",codecs:c.va,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:e,duration:d,hb:[],na:new Uint8Array([]),Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.h,baseMediaDecodeTime:a,eb:f},stream:b};a=new iu([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=qu(a),this.g.set(b.id,d));b=Hu(a);this.h++;b=ig(d,b);return Promise.resolve(b)};M("shaka.transmuxer.AacTransmuxer",Uz);
1185
+ Uz.prototype.transmux=Uz.prototype.transmux;Uz.prototype.getOriginalMimeType=Uz.prototype.getOriginalMimeType;Uz.prototype.convertCodecs=Uz.prototype.convertCodecs;Uz.prototype.isSupported=Uz.prototype.isSupported;Uz.prototype.destroy=Uz.prototype.destroy;Uc("audio/aac",function(){return new Uz("audio/aac")},$c);function Vz(a,b){if(b+8>a.length||11!==a[b]||119!==a[b+1])return null;var c=a[b+4]>>6;if(3<=c)return null;var d=a[b+4]&63,e=2*[64,69,96,64,70,96,80,87,120,80,88,120,96,104,144,96,105,144,112,121,168,112,122,168,128,139,192,128,140,192,160,174,240,160,175,240,192,208,288,192,209,288,224,243,336,224,244,336,256,278,384,256,279,384,320,348,480,320,349,480,384,417,576,384,418,576,448,487,672,448,488,672,512,557,768,512,558,768,640,696,960,640,697,960,768,835,1152,768,836,1152,896,975,1344,896,976,1344,
1187
1186
  1024,1114,1536,1024,1115,1536,1152,1253,1728,1152,1254,1728,1280,1393,1920,1280,1394,1920][3*d+c];if(b+e>a.length)return null;var f=a[b+6]>>5,g=0;2===f?g+=2:(f&1&&1!==f&&(g+=2),f&4&&(g+=2));g=(a[b+6]<<8|a[b+7])>>12-g&1;var h=a[b+5]&7;a=new Uint8Array([c<<6|a[b+5]>>3<<1|h>>2,(h&3)<<6|f<<3|g<<2|d>>4,d<<4&224]);return{sampleRate:[48E3,44100,32E3][c],channelCount:[2,1,2,3,3,4,4,5][f]+g,na:a,X:e}}
1188
- function Xz(a,b){if(11===a[b]&&119===a[b+1]){var c=0,d=5;b+=d;for(var e,f;0<d;){f=a[b];var g=Math.min(d,8),h=8-g;e=4278190080>>>24+h<<h;e=(f&e)>>h;c=c?c<<g|e:e;b+=1;d-=g}if(16>c)return!0}return!1};function Yz(a){this.i=a;this.h=0;this.g=new Map}p=Yz.prototype;p.destroy=function(){this.g.clear()};p.isSupported=function(a){return"audio/ac3"==a.toLowerCase().split(";")[0]?dc(this.convertCodecs("audio",a)):!1};p.convertCodecs=function(a,b){return"audio/ac3"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="ac-3"':b};p.getOriginalMimeType=function(){return this.i};
1189
- p.transmux=function(a,b,c,d){a=lc(a);for(var e=Th(a),f=e.length;f<a.length&&!Xz(a,f);f++);var g=1E3*c.endTime;e=Sh(e);e.length&&c&&(c=e.find(function(l){return"com.apple.streaming.transportStreamTimestamp"===l.description}))&&(g=c.data);c=0;e=new Uint8Array([]);for(var h=[];f<a.length;){var k=Wz(a,f);if(!k)return Promise.reject(new P(2,3,3018));b.audioSamplingRate=k.sampleRate;b.channelsCount=k.channelCount;c=k.sampleRate;e=k.na;h.push({data:a.subarray(f,f+k.X),size:k.X,duration:1536,jb:0,flags:{mb:0,
1190
- ab:0,$a:0,Ya:0,Za:2,ob:0}});f+=k.X}a=Math.floor(g*c/1E3);d={id:b.id,type:"audio",codecs:"ac-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:c,duration:d,hb:[],na:e,Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.h,baseMediaDecodeTime:a,eb:h},stream:b};a=new iu([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=qu(a),this.g.set(b.id,d));b=Hu(a);this.h++;b=jg(d,b);return Promise.resolve(b)};M("shaka.transmuxer.Ac3Transmuxer",Yz);Yz.prototype.transmux=Yz.prototype.transmux;
1191
- Yz.prototype.getOriginalMimeType=Yz.prototype.getOriginalMimeType;Yz.prototype.convertCodecs=Yz.prototype.convertCodecs;Yz.prototype.isSupported=Yz.prototype.isSupported;Yz.prototype.destroy=Yz.prototype.destroy;Uc("audio/ac3",function(){return new Yz("audio/ac3")},$c);function Zz(a,b){if(b+8>a.length||2935!==(a[b]<<8|a[b+1]<<0))return null;var c=new ci(a.subarray(b+2));ei(c,2);ei(c,3);var d=fi(c,11)+1<<1,e=fi(c,2);if(3==e){e=fi(c,2);e=[24E3,22060,16E3][e];var f=3}else e=[48E3,44100,32E3][e],f=fi(c,2);var g=fi(c,3),h=fi(c,1);c=fi(c,5);if(b+d>a.byteLength)return null;a=Math.floor(d*e/(16*[1,2,3,6][f]));a=new Uint8Array([(a&8160)>>5,(a&31)<<3,e<<6|c<<1|0,0|g<<1|h<<0,0]);return{sampleRate:e,channelCount:[2,1,2,3,3,4,4,5][g]+h,na:a,X:d}};function $z(a){this.i=a;this.h=0;this.g=new Map}p=$z.prototype;p.destroy=function(){this.g.clear()};p.isSupported=function(a){return"audio/ec3"==a.toLowerCase().split(";")[0]?dc(this.convertCodecs("audio",a)):!1};p.convertCodecs=function(a,b){return"audio/ec3"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="ec-3"':b};p.getOriginalMimeType=function(){return this.i};
1192
- p.transmux=function(a,b,c,d){a=lc(a);for(var e=Th(a),f=e.length;f<a.length&&2935!==(a[f]<<8|a[f+1]<<0);f++);var g=1E3*c.endTime;e=Sh(e);e.length&&c&&(c=e.find(function(l){return"com.apple.streaming.transportStreamTimestamp"===l.description}))&&(g=c.data);c=0;e=new Uint8Array([]);for(var h=[];f<a.length;){var k=Zz(a,f);if(!k)return Promise.reject(new P(2,3,3018));b.audioSamplingRate=k.sampleRate;b.channelsCount=k.channelCount;c=k.sampleRate;e=k.na;h.push({data:a.subarray(f,f+k.X),size:k.X,duration:1536,
1193
- jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}});f+=k.X}a=Math.floor(g*c/1E3);d={id:b.id,type:"audio",codecs:"ec-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:c,duration:d,hb:[],na:e,Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.h,baseMediaDecodeTime:a,eb:h},stream:b};a=new iu([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=qu(a),this.g.set(b.id,d));b=Hu(a);this.h++;b=jg(d,b);return Promise.resolve(b)};M("shaka.transmuxer.Ec3Transmuxer",$z);$z.prototype.transmux=$z.prototype.transmux;
1194
- $z.prototype.getOriginalMimeType=$z.prototype.getOriginalMimeType;$z.prototype.convertCodecs=$z.prototype.convertCodecs;$z.prototype.isSupported=$z.prototype.isSupported;$z.prototype.destroy=$z.prototype.destroy;Uc("audio/ec3",function(){return new $z("audio/ec3")},$c);function aA(a){if(!a.length)return null;var b=a.find(function(v){return 7==v.type});a=a.find(function(v){return 8==v.type});if(!b||!a)return null;var c=new ci(b.data),d=ji(c);ji(c);ji(c);hi(c);if(bA.includes(d)&&(d=Q(c),3===d&&ei(c,1),hi(c),hi(c),ei(c,1),S(c))){d=3!==d?8:12;for(var e=0;e<d;e++)S(c)&&(6>e?ki(c,16):ki(c,64))}hi(c);d=Q(c);if(0===d)Q(c);else if(1===d)for(ei(c,1),hi(c),hi(c),d=Q(c),e=0;e<d;e++)hi(c);hi(c);ei(c,1);var f=Q(c),g=Q(c),h=fi(c,1);0===h&&ei(c,1);ei(c,1);var k=0,l=0,m=0,n=0;S(c)&&
1187
+ function Wz(a,b){if(11===a[b]&&119===a[b+1]){var c=0,d=5;b+=d;for(var e,f;0<d;){f=a[b];var g=Math.min(d,8),h=8-g;e=4278190080>>>24+h<<h;e=(f&e)>>h;c=c?c<<g|e:e;b+=1;d-=g}if(16>c)return!0}return!1};function Xz(a){this.i=a;this.h=0;this.g=new Map}p=Xz.prototype;p.destroy=function(){this.g.clear()};p.isSupported=function(a){return"audio/ac3"==a.toLowerCase().split(";")[0]?dc(this.convertCodecs("audio",a)):!1};p.convertCodecs=function(a,b){return"audio/ac3"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="ac-3"':b};p.getOriginalMimeType=function(){return this.i};
1188
+ p.transmux=function(a,b,c,d){a=lc(a);for(var e=Th(a),f=e.length;f<a.length&&!Wz(a,f);f++);var g=1E3*c.endTime;e=Sh(e);e.length&&c&&(c=e.find(function(l){return"com.apple.streaming.transportStreamTimestamp"===l.description}))&&(g=c.data);c=0;e=new Uint8Array([]);for(var h=[];f<a.length;){var k=Vz(a,f);if(!k)return Promise.reject(new P(2,3,3018));b.audioSamplingRate=k.sampleRate;b.channelsCount=k.channelCount;c=k.sampleRate;e=k.na;h.push({data:a.subarray(f,f+k.X),size:k.X,duration:1536,jb:0,flags:{mb:0,
1189
+ ab:0,$a:0,Ya:0,Za:2,ob:0}});f+=k.X}a=Math.floor(g*c/1E3);d={id:b.id,type:"audio",codecs:"ac-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:c,duration:d,hb:[],na:e,Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.h,baseMediaDecodeTime:a,eb:h},stream:b};a=new iu([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=qu(a),this.g.set(b.id,d));b=Hu(a);this.h++;b=ig(d,b);return Promise.resolve(b)};M("shaka.transmuxer.Ac3Transmuxer",Xz);Xz.prototype.transmux=Xz.prototype.transmux;
1190
+ Xz.prototype.getOriginalMimeType=Xz.prototype.getOriginalMimeType;Xz.prototype.convertCodecs=Xz.prototype.convertCodecs;Xz.prototype.isSupported=Xz.prototype.isSupported;Xz.prototype.destroy=Xz.prototype.destroy;Uc("audio/ac3",function(){return new Xz("audio/ac3")},$c);function Yz(a,b){if(b+8>a.length||2935!==(a[b]<<8|a[b+1]<<0))return null;var c=new ci(a.subarray(b+2));ei(c,2);ei(c,3);var d=fi(c,11)+1<<1,e=fi(c,2);if(3==e){e=fi(c,2);e=[24E3,22060,16E3][e];var f=3}else e=[48E3,44100,32E3][e],f=fi(c,2);var g=fi(c,3),h=fi(c,1);c=fi(c,5);if(b+d>a.byteLength)return null;a=Math.floor(d*e/(16*[1,2,3,6][f]));a=new Uint8Array([(a&8160)>>5,(a&31)<<3,e<<6|c<<1|0,0|g<<1|h<<0,0]);return{sampleRate:e,channelCount:[2,1,2,3,3,4,4,5][g]+h,na:a,X:d}};function Zz(a){this.i=a;this.h=0;this.g=new Map}p=Zz.prototype;p.destroy=function(){this.g.clear()};p.isSupported=function(a){return"audio/ec3"==a.toLowerCase().split(";")[0]?dc(this.convertCodecs("audio",a)):!1};p.convertCodecs=function(a,b){return"audio/ec3"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="ec-3"':b};p.getOriginalMimeType=function(){return this.i};
1191
+ p.transmux=function(a,b,c,d){a=lc(a);for(var e=Th(a),f=e.length;f<a.length&&2935!==(a[f]<<8|a[f+1]<<0);f++);var g=1E3*c.endTime;e=Sh(e);e.length&&c&&(c=e.find(function(l){return"com.apple.streaming.transportStreamTimestamp"===l.description}))&&(g=c.data);c=0;e=new Uint8Array([]);for(var h=[];f<a.length;){var k=Yz(a,f);if(!k)return Promise.reject(new P(2,3,3018));b.audioSamplingRate=k.sampleRate;b.channelsCount=k.channelCount;c=k.sampleRate;e=k.na;h.push({data:a.subarray(f,f+k.X),size:k.X,duration:1536,
1192
+ jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}});f+=k.X}a=Math.floor(g*c/1E3);d={id:b.id,type:"audio",codecs:"ec-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:c,duration:d,hb:[],na:e,Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.h,baseMediaDecodeTime:a,eb:h},stream:b};a=new iu([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=qu(a),this.g.set(b.id,d));b=Hu(a);this.h++;b=ig(d,b);return Promise.resolve(b)};M("shaka.transmuxer.Ec3Transmuxer",Zz);Zz.prototype.transmux=Zz.prototype.transmux;
1193
+ Zz.prototype.getOriginalMimeType=Zz.prototype.getOriginalMimeType;Zz.prototype.convertCodecs=Zz.prototype.convertCodecs;Zz.prototype.isSupported=Zz.prototype.isSupported;Zz.prototype.destroy=Zz.prototype.destroy;Uc("audio/ec3",function(){return new Zz("audio/ec3")},$c);function $z(a){if(!a.length)return null;var b=a.find(function(v){return 7==v.type});a=a.find(function(v){return 8==v.type});if(!b||!a)return null;var c=new ci(b.data),d=ji(c);ji(c);ji(c);hi(c);if(aA.includes(d)&&(d=Q(c),3===d&&ei(c,1),hi(c),hi(c),ei(c,1),S(c))){d=3!==d?8:12;for(var e=0;e<d;e++)S(c)&&(6>e?ki(c,16):ki(c,64))}hi(c);d=Q(c);if(0===d)Q(c);else if(1===d)for(ei(c,1),hi(c),hi(c),d=Q(c),e=0;e<d;e++)hi(c);hi(c);ei(c,1);var f=Q(c),g=Q(c),h=fi(c,1);0===h&&ei(c,1);ei(c,1);var k=0,l=0,m=0,n=0;S(c)&&
1195
1194
  (k=Q(c),l=Q(c),m=Q(c),n=Q(c));e=d=1;if(S(c)&&S(c)){var q=ji(c),r=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2],u=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1];0<q&&16>q?(d=r[q-1],e=u[q-1]):255===q&&(d=fi(c,16),e=fi(c,16))}c=(2-h)*(g+1)*16-2*m-2*n;f=16*(f+1)-2*k-2*l;k=[];b=b.fullData;k.push(b.byteLength>>>8&255);k.push(b.byteLength&255);k=k.concat.apply(k,w(b));b=[];a=a.fullData;b.push(a.byteLength>>>8&255);b.push(a.byteLength&255);b=b.concat.apply(b,w(a));a=new Uint8Array([1,k[3],k[4],k[5],255,225].concat(k,
1196
1195
  [1],b));return{height:c,width:f,Ba:a,Ha:d,Ja:e}}
1197
- function cA(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=li(new ci(h)),2===h||4===h||7===h||9===h)&&(b=!0);break;case 5:b=g=e=!0;break;case 6:g=!0;break;case 7:g=!0;break;case 8:g=!0;break;case 9:e=g=!0;break;case 12:g=!0;break;default:g=!1}e&&g&&(g=f.fullData.byteLength,h=new Uint8Array(4),h[0]=g>>24&255,h[1]=g>>16&255,h[2]=g>>8&255,h[3]=g&255,c.push(jg(h,
1198
- f.fullData)))}return c.length?{data:jg.apply(cg,w(c)),wd:b}:null}var bA=[100,110,122,244,44,83,86,118,128,138,139,134];function dA(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=eA(b.fullData);a=fA(c.fullData);var f=gA(d.fullData);b=hA(b.fullData,c.fullData,d.fullData,{Qf:e.Qf,ng:e.ng,wf:a.wf,xf:a.xf,pf:a.pf,vf:a.vf,qf:a.qf,rf:a.rf,tf:a.tf,uf:a.uf,hf:a.hf,jf:a.jf,kf:a.kf,lf:a.lf,mf:a.mf,nf:a.nf,cf:a.cf,ue:a.ue,bf:a.bf,Ze:a.Ze,Ye:a.Ye,Tf:f.Tf});return{height:a.height,width:a.width,
1199
- Ba:b,Ha:a.aj,Ja:a.$i}}function eA(a){var b=new ci(a,!0);ji(b);ji(b);fi(b,4);fi(b,2);fi(b,6);a=fi(b,3);b=S(b);return{Qf:a+1,ng:b}}
1200
- function fA(a){a=new ci(a,!0);ji(a);ji(a);var b=0,c=0,d=0,e=0;fi(a,4);var f=fi(a,3);S(a);for(var g=fi(a,2),h=fi(a,1),k=fi(a,5),l=ji(a),m=ji(a),n=ji(a),q=ji(a),r=ji(a),u=ji(a),v=ji(a),y=ji(a),z=ji(a),x=ji(a),A=ji(a),B=[],C=[],E=0;E<f;E++)B.push(S(a)),C.push(S(a));if(0<f)for(E=f;8>E;E++)fi(a,2);for(E=0;E<f;E++)B[E]&&fi(a,88),C[E]&&ji(a);Q(a);B=Q(a);3==B&&fi(a,1);C=Q(a);E=Q(a);S(a)&&(b+=Q(a),c+=Q(a),d+=Q(a),e+=Q(a));var H=Q(a),G=Q(a),I=Q(a);if(S(a))for(var J=0;J<=f;J++)Q(a),Q(a),Q(a);else Q(a),Q(a),
1196
+ function bA(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=li(new ci(h)),2===h||4===h||7===h||9===h)&&(b=!0);break;case 5:b=g=e=!0;break;case 6:g=!0;break;case 7:g=!0;break;case 8:g=!0;break;case 9:e=g=!0;break;case 12:g=!0;break;default:g=!1}e&&g&&(g=f.fullData.byteLength,h=new Uint8Array(4),h[0]=g>>24&255,h[1]=g>>16&255,h[2]=g>>8&255,h[3]=g&255,c.push(ig(h,
1197
+ f.fullData)))}return c.length?{data:ig.apply(cg,w(c)),wd:b}:null}var aA=[100,110,122,244,44,83,86,118,128,138,139,134];function cA(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=dA(b.fullData);a=eA(c.fullData);var f=fA(d.fullData);b=gA(b.fullData,c.fullData,d.fullData,{Qf:e.Qf,ng:e.ng,wf:a.wf,xf:a.xf,pf:a.pf,vf:a.vf,qf:a.qf,rf:a.rf,tf:a.tf,uf:a.uf,hf:a.hf,jf:a.jf,kf:a.kf,lf:a.lf,mf:a.mf,nf:a.nf,cf:a.cf,ue:a.ue,bf:a.bf,Ze:a.Ze,Ye:a.Ye,Tf:f.Tf});return{height:a.height,width:a.width,
1198
+ Ba:b,Ha:a.aj,Ja:a.$i}}function dA(a){var b=new ci(a,!0);ji(b);ji(b);fi(b,4);fi(b,2);fi(b,6);a=fi(b,3);b=S(b);return{Qf:a+1,ng:b}}
1199
+ function eA(a){a=new ci(a,!0);ji(a);ji(a);var b=0,c=0,d=0,e=0;fi(a,4);var f=fi(a,3);S(a);for(var g=fi(a,2),h=fi(a,1),k=fi(a,5),l=ji(a),m=ji(a),n=ji(a),q=ji(a),r=ji(a),u=ji(a),v=ji(a),y=ji(a),z=ji(a),x=ji(a),A=ji(a),B=[],C=[],E=0;E<f;E++)B.push(S(a)),C.push(S(a));if(0<f)for(E=f;8>E;E++)fi(a,2);for(E=0;E<f;E++)B[E]&&fi(a,88),C[E]&&ji(a);Q(a);B=Q(a);3==B&&fi(a,1);C=Q(a);E=Q(a);S(a)&&(b+=Q(a),c+=Q(a),d+=Q(a),e+=Q(a));var H=Q(a),G=Q(a),I=Q(a);if(S(a))for(var J=0;J<=f;J++)Q(a),Q(a),Q(a);else Q(a),Q(a),
1201
1200
  Q(a);Q(a);Q(a);Q(a);Q(a);Q(a);Q(a);if(S(a)&&S(a))for(J=0;4>J;J++)for(var L=0;L<(3===J?2:6);L++)if(S(a)){var N=Math.min(64,1<<4+(J<<1));1<J&&ii(a);for(var R=0;R<N;R++)ii(a)}else Q(a);S(a);S(a);S(a)&&(ji(a),Q(a),Q(a),S(a));J=Q(a);for(N=L=0;N<J;N++)if(R=!1,0!==N&&(R=S(a)),R){N===J&&Q(a);S(a);Q(a);for(var T=R=0;T<=L;T++){var ea=S(a),Z=!1;ea||(Z=S(a));(ea||Z)&&R++}L=R}else{T=Q(a);R=Q(a);L=T+R;for(ea=0;ea<T;ea++)Q(a),S(a);for(T=0;T<R;T++)Q(a),S(a)}if(S(a))for(J=Q(a),L=0;L<J;L++){for(N=0;N<I+4;N++)fi(a,
1202
1201
  1);fi(a,1)}J=I=1;L=0;S(a);S(a);if(S(a)){S(a)&&(N=ji(a),R=[1,12,10,16,40,24,20,32,80,18,15,64,160,4,3,2],T=[1,11,11,11,33,11,11,11,33,11,11,33,99,3,2,1],0<N&&16>N?(I=R[N-1],J=T[N-1]):255===N&&(I=fi(a,16),J=fi(a,16)));S(a)&&S(a);S(a)&&(fi(a,3),S(a),S(a)&&(ji(a),ji(a),ji(a)));S(a)&&(Q(a),Q(a));S(a);S(a);S(a);if(N=S(a))Q(a),Q(a),Q(a),Q(a);if(S(a)&&(fi(a,32),fi(a,32),S(a)&&Q(a),S(a))){T=!1;N=S(a);R=S(a);if(N||R){if(T=S(a))ji(a),fi(a,5),S(a),fi(a,5);fi(a,4);fi(a,4);T&&fi(a,4);fi(a,5);fi(a,5);fi(a,5)}for(ea=
1203
1202
  0;ea<=f;ea++){var fa=!0;Z=1;S(a)||(fa=S(a));var Ha=!1;fa?Q(a):Ha=S(a);Ha||(Z=Q(a)+1);if(N){for(fa=0;fa<Z;fa++)Q(a),Q(a),T&&(Q(a),Q(a));S(a)}if(R){for(fa=0;fa<Z;fa++)Q(a),Q(a),T&&(Q(a),Q(a));S(a)}}}S(a)&&(S(a),S(a),S(a),L=Q(a),Q(a),Q(a),Q(a),Q(a))}return{pf:A,wf:g,xf:h,vf:k,qf:l,rf:m,tf:n,uf:q,hf:r,jf:u,kf:v,lf:y,mf:z,nf:x,ue:L,cf:0,bf:B,Ze:H,Ye:G,width:C-(b+c)*(1===B||2===B?2:1),height:E-(d+e)*(1===B?2:1),aj:I,$i:J}}
1204
- function gA(a){var b=new ci(a,!0);ji(b);ji(b);Q(b);Q(b);S(b);S(b);fi(b,3);S(b);S(b);Q(b);Q(b);ii(b);S(b);S(b);S(b)&&Q(b);ii(b);ii(b);S(b);S(b);S(b);S(b);a=S(b);b=S(b);var c=1;b&&a?c=0:b?c=3:a&&(c=2);return{Tf:c}}
1205
- function hA(a,b,c,d){var e=new Uint8Array(23+(5+a.byteLength)+(5+b.byteLength)+(5+c.byteLength));e[0]=1;e[1]=(d.wf&3)<<6|(d.xf?1:0)<<5|d.vf&31;e[2]=d.qf;e[3]=d.rf;e[4]=d.tf;e[5]=d.uf;e[6]=d.hf;e[7]=d.jf;e[8]=d.kf;e[9]=d.lf;e[10]=d.mf;e[11]=d.nf;e[12]=d.pf;e[13]=240|(d.ue&3840)>>8;e[14]=d.ue&255;e[15]=252|d.Tf&3;e[16]=252|d.bf&3;e[17]=248|d.Ze&7;e[18]=248|d.Ye&7;e[19]=0;e[20]=0;e[21]=(d.cf&3)<<6|(d.Qf&7)<<3|(d.ng?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&
1206
- 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 iA(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*jA[14*(3===c?3-d:3===d?3:4)+e-1];f=kA[3*(3===c?0:2===c?1:2)+f];c=lA[c][d];var h=mA[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,X:k,Zi:8*c*h}}return null}
1207
- function nA(a,b){return 255===a[b]&&224===(a[b+1]&224)&&0!==(a[b+1]&6)}var jA=[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],kA=[44100,48E3,32E3,22050,24E3,16E3,11025,12E3,8E3],lA=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],mA=[0,1,1,4];function oA(a){this.i=a;this.h=0;this.g=new Map}p=oA.prototype;p.destroy=function(){this.g.clear()};p.isSupported=function(a){return"audio/mpeg"==a.toLowerCase().split(";")[0]?dc(this.convertCodecs("audio",a)):!1};p.convertCodecs=function(a,b){return"audio/mpeg"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="mp3"':b};p.getOriginalMimeType=function(){return this.i};
1208
- p.transmux=function(a,b,c,d){a=lc(a);for(c=Th(a).length;c<a.length;c++){var e=c;if(e+1<a.length&&nA(a,e)){var f=iA(a,e),g=4;f&&f.X&&(g=f.X);e+=g;e=e===a.length||e+1<a.length&&nA(a,e)}else e=!1;if(e)break}var h;for(e=[];c<a.length;){f=iA(a,c);if(!f)return Promise.reject(new P(2,3,3018));h||(h=f);c+f.X<=a.length&&e.push({data:a.subarray(c,c+f.X),size:f.X,duration:1152,jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}});c+=f.X}if(!h)return Promise.reject(new P(2,3,3018));a=9E4*h.Zi/h.sampleRate*this.h;d={id:b.id,
1209
- type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:h.sampleRate,duration:d,hb:[],na:new Uint8Array([]),Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.h,baseMediaDecodeTime:a,eb:e},stream:b};h=new iu([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=qu(h),this.g.set(b.id,d));b=Hu(h);this.h++;b=jg(d,b);return Promise.resolve(b)};M("shaka.transmuxer.Mp3Transmuxer",oA);oA.prototype.transmux=oA.prototype.transmux;oA.prototype.getOriginalMimeType=oA.prototype.getOriginalMimeType;
1210
- oA.prototype.convertCodecs=oA.prototype.convertCodecs;oA.prototype.isSupported=oA.prototype.isSupported;oA.prototype.destroy=oA.prototype.destroy;Uc("audio/mpeg",function(){return new oA("audio/mpeg")},$c);function pA(a){this.h=a;this.g=null}p=pA.prototype;p.destroy=function(){};p.isSupported=function(a){if("video/mp2t"!=a.toLowerCase().split(";")[0])return!1;var b=id(a).split(","),c=Fb("audio",b);b=Fb("video",b);return!c||b||"mp3"!=fd(c)?!1:dc(this.convertCodecs("audio",a))};p.convertCodecs=function(a,b){return"video/mp2t"==b.toLowerCase().split(";")[0]?"audio/mpeg":b};p.getOriginalMimeType=function(){return this.h};
1211
- p.transmux=function(a,b,c,d,e){this.g?this.g.clearData():this.g=new mi;a=lc(a);a=this.g.parse(a);if("mp3"!=a.pd().audio||"audio"!=e)return Promise.reject(new P(2,3,3018));e=new Uint8Array([]);a=t(a.jc());for(b=a.next();!b.done;b=a.next())if(b=b.value.data)for(c=0;c<b.length;)(d=iA(b,c))?(c+d.X<=b.length&&(e=jg(e,b.subarray(c,c+d.X))),c+=d.X):c++;return Promise.resolve(e)};M("shaka.transmuxer.MpegTsTransmuxer",pA);pA.prototype.transmux=pA.prototype.transmux;pA.prototype.getOriginalMimeType=pA.prototype.getOriginalMimeType;
1212
- pA.prototype.convertCodecs=pA.prototype.convertCodecs;pA.prototype.isSupported=pA.prototype.isSupported;pA.prototype.destroy=pA.prototype.destroy;Uc("video/mp2t",function(){return new pA("video/mp2t")},Zc);/*
1203
+ function fA(a){var b=new ci(a,!0);ji(b);ji(b);Q(b);Q(b);S(b);S(b);fi(b,3);S(b);S(b);Q(b);Q(b);ii(b);S(b);S(b);S(b)&&Q(b);ii(b);ii(b);S(b);S(b);S(b);S(b);a=S(b);b=S(b);var c=1;b&&a?c=0:b?c=3:a&&(c=2);return{Tf:c}}
1204
+ function gA(a,b,c,d){var e=new Uint8Array(23+(5+a.byteLength)+(5+b.byteLength)+(5+c.byteLength));e[0]=1;e[1]=(d.wf&3)<<6|(d.xf?1:0)<<5|d.vf&31;e[2]=d.qf;e[3]=d.rf;e[4]=d.tf;e[5]=d.uf;e[6]=d.hf;e[7]=d.jf;e[8]=d.kf;e[9]=d.lf;e[10]=d.mf;e[11]=d.nf;e[12]=d.pf;e[13]=240|(d.ue&3840)>>8;e[14]=d.ue&255;e[15]=252|d.Tf&3;e[16]=252|d.bf&3;e[17]=248|d.Ze&7;e[18]=248|d.Ye&7;e[19]=0;e[20]=0;e[21]=(d.cf&3)<<6|(d.Qf&7)<<3|(d.ng?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&
1205
+ 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 hA(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*iA[14*(3===c?3-d:3===d?3:4)+e-1];f=jA[3*(3===c?0:2===c?1:2)+f];c=kA[c][d];var h=lA[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,X:k,Zi:8*c*h}}return null}
1206
+ function mA(a,b){return 255===a[b]&&224===(a[b+1]&224)&&0!==(a[b+1]&6)}var iA=[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],jA=[44100,48E3,32E3,22050,24E3,16E3,11025,12E3,8E3],kA=[[0,72,144,12],[0,0,0,0],[0,72,144,12],[0,144,144,12]],lA=[0,1,1,4];function nA(a){this.i=a;this.h=0;this.g=new Map}p=nA.prototype;p.destroy=function(){this.g.clear()};p.isSupported=function(a){return"audio/mpeg"==a.toLowerCase().split(";")[0]?dc(this.convertCodecs("audio",a)):!1};p.convertCodecs=function(a,b){return"audio/mpeg"==b.toLowerCase().split(";")[0]?'audio/mp4; codecs="mp3"':b};p.getOriginalMimeType=function(){return this.i};
1207
+ p.transmux=function(a,b,c,d){a=lc(a);for(c=Th(a).length;c<a.length;c++){var e=c;if(e+1<a.length&&mA(a,e)){var f=hA(a,e),g=4;f&&f.X&&(g=f.X);e+=g;e=e===a.length||e+1<a.length&&mA(a,e)}else e=!1;if(e)break}var h;for(e=[];c<a.length;){f=hA(a,c);if(!f)return Promise.reject(new P(2,3,3018));h||(h=f);c+f.X<=a.length&&e.push({data:a.subarray(c,c+f.X),size:f.X,duration:1152,jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}});c+=f.X}if(!h)return Promise.reject(new P(2,3,3018));a=9E4*h.Zi/h.sampleRate*this.h;d={id:b.id,
1208
+ type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:h.sampleRate,duration:d,hb:[],na:new Uint8Array([]),Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.h,baseMediaDecodeTime:a,eb:e},stream:b};h=new iu([d]);this.g.has(b.id)?d=this.g.get(b.id):(d=qu(h),this.g.set(b.id,d));b=Hu(h);this.h++;b=ig(d,b);return Promise.resolve(b)};M("shaka.transmuxer.Mp3Transmuxer",nA);nA.prototype.transmux=nA.prototype.transmux;nA.prototype.getOriginalMimeType=nA.prototype.getOriginalMimeType;
1209
+ nA.prototype.convertCodecs=nA.prototype.convertCodecs;nA.prototype.isSupported=nA.prototype.isSupported;nA.prototype.destroy=nA.prototype.destroy;Uc("audio/mpeg",function(){return new nA("audio/mpeg")},$c);function oA(a){this.h=a;this.g=null}p=oA.prototype;p.destroy=function(){};p.isSupported=function(a){if("video/mp2t"!=a.toLowerCase().split(";")[0])return!1;var b=id(a).split(","),c=Fb("audio",b);b=Fb("video",b);return!c||b||"mp3"!=fd(c)?!1:dc(this.convertCodecs("audio",a))};p.convertCodecs=function(a,b){return"video/mp2t"==b.toLowerCase().split(";")[0]?"audio/mpeg":b};p.getOriginalMimeType=function(){return this.h};
1210
+ p.transmux=function(a,b,c,d,e){this.g?this.g.clearData():this.g=new mi;a=lc(a);a=this.g.parse(a);if("mp3"!=a.pd().audio||"audio"!=e)return Promise.reject(new P(2,3,3018));e=new Uint8Array([]);a=t(a.kc());for(b=a.next();!b.done;b=a.next())if(b=b.value.data)for(c=0;c<b.length;)(d=hA(b,c))?(c+d.X<=b.length&&(e=ig(e,b.subarray(c,c+d.X))),c+=d.X):c++;return Promise.resolve(e)};M("shaka.transmuxer.MpegTsTransmuxer",oA);oA.prototype.transmux=oA.prototype.transmux;oA.prototype.getOriginalMimeType=oA.prototype.getOriginalMimeType;
1211
+ oA.prototype.convertCodecs=oA.prototype.convertCodecs;oA.prototype.isSupported=oA.prototype.isSupported;oA.prototype.destroy=oA.prototype.destroy;Uc("video/mp2t",function(){return new oA("video/mp2t")},Zc);/*
1213
1212
  @license
1214
1213
  MSS Transmuxer
1215
1214
  Copyright 2015 Dash Industry Forum
1216
1215
  SPDX-License-Identifier: BSD-3-Clause
1217
1216
  */
1218
- function qA(a){this.h=a;(this.g=rs.get("ISOBoxer")())&&rA(this)}
1219
- function rA(a){function b(){this._procFullBox();this.flags&1&&(this._procField("AlgorithmID","uint",24),this._procField("IV_size","uint",8),this._procFieldArray("KID",16,"uint",8));this._procField("sample_count","uint",32);this._procEntries("entry",this.sample_count,function(c){this._procEntryField(c,"InitializationVector","data",8);this.flags&2&&(this._procEntryField(c,"NumberOfEntries","uint",16),this._procSubEntries(c,"clearAndCryptedData",c.NumberOfEntries,function(d){this._procEntryField(d,"BytesOfClearData",
1217
+ function pA(a){this.h=a;(this.g=rs.get("ISOBoxer")())&&qA(this)}
1218
+ function qA(a){function b(){this._procFullBox();this.flags&1&&(this._procField("AlgorithmID","uint",24),this._procField("IV_size","uint",8),this._procFieldArray("KID",16,"uint",8));this._procField("sample_count","uint",32);this._procEntries("entry",this.sample_count,function(c){this._procEntryField(c,"InitializationVector","data",8);this.flags&2&&(this._procEntryField(c,"NumberOfEntries","uint",16),this._procSubEntries(c,"clearAndCryptedData",c.NumberOfEntries,function(d){this._procEntryField(d,"BytesOfClearData",
1220
1219
  "uint",16);this._procEntryField(d,"BytesOfEncryptedData","uint",32)}))})}a.g.addBoxProcessor("saio",function(){this._procFullBox();this.flags&1&&(this._procField("aux_info_type","uint",32),this._procField("aux_info_type_parameter","uint",32));this._procField("entry_count","uint",32);this._procFieldArray("offset",this.entry_count,"uint",1===this.version?64:32)});a.g.addBoxProcessor("saiz",function(){this._procFullBox();this.flags&1&&(this._procField("aux_info_type","uint",32),this._procField("aux_info_type_parameter",
1221
- "uint",32));this._procField("default_sample_info_size","uint",8);this._procField("sample_count","uint",32);0===this.default_sample_info_size&&this._procFieldArray("sample_info_size",this.sample_count,"uint",8)});a.g.addBoxProcessor("senc",b);a.g.addBoxProcessor("uuid",function(){for(var c=!0,d=0;16>d;d++)this.usertype[d]!==sA[d]&&(c=!1);c&&(this._parsing&&(this.type="sepiff"),b.call(this))})}p=qA.prototype;p.destroy=function(){};
1220
+ "uint",32));this._procField("default_sample_info_size","uint",8);this._procField("sample_count","uint",32);0===this.default_sample_info_size&&this._procFieldArray("sample_info_size",this.sample_count,"uint",8)});a.g.addBoxProcessor("senc",b);a.g.addBoxProcessor("uuid",function(){for(var c=!0,d=0;16>d;d++)this.usertype[d]!==rA[d]&&(c=!1);c&&(this._parsing&&(this.type="sepiff"),b.call(this))})}p=pA.prototype;p.destroy=function(){};
1222
1221
  p.isSupported=function(a,b){var c=a.startsWith("mss/");if(!this.g||!c)return!1;if(b)return dc(this.convertCodecs(b,a));b=this.convertCodecs("audio",a);a=this.convertCodecs("video",a);return dc(b)||dc(a)};p.convertCodecs=function(a,b){return b.replace("mss/","")};p.getOriginalMimeType=function(){return this.h};
1223
1222
  p.transmux=function(a,b,c){if(!c)return Promise.resolve(lc(a));if(!b.mssPrivateData)return Promise.reject(new P(2,3,3020));try{var d,e=this.g.parseBuffer(a),f=e.fetch("tfhd");f.track_ID=b.id+1;var g=e.fetch("tfdt"),h=e.fetch("traf");null===g&&(g=this.g.createFullBox("tfdt",h,f),g.version=1,g.flags=0,g.baseMediaDecodeTime=Math.floor(c.startTime*b.mssPrivateData.timescale));var k=e.fetch("trun"),l=e.fetch("tfxd");l&&l._parent.boxes.splice(l._parent.boxes.indexOf(l),1);var m=e.fetch("tfrf");m&&m._parent.boxes.splice(m._parent.boxes.indexOf(m),
1224
1223
  1);var n=e.fetch("sepiff");if(null!==n){n.type="senc";n.usertype=void 0;var q=e.fetch("saio");if(null===q){q=this.g.createFullBox("saio",h);q.version=0;q.flags=0;q.entry_count=1;q.offset=[0];var r=this.g.createFullBox("saiz",h);r.version=0;r.flags=0;r.sample_count=n.sample_count;r.default_sample_info_size=0;r.sample_info_size=[];if(n.flags&2)for(d=0;d<n.sample_count;d+=1)r.sample_info_size[d]=10+6*n.entry[d].NumberOfEntries;else r.default_sample_info_size=8}}f.flags&=16777214;f.flags|=131072;k.flags|=
1225
- 1;var u=e.fetch("moof");k.data_offset=u.getLength()+8;var v=e.fetch("saio");null!==v&&(v.offset[0]=tA(u,"traf")+tA(h,"senc")+16);var y=lc(e.write());return Promise.resolve(y)}catch(z){return z instanceof P?Promise.reject(z):Promise.reject(new P(2,3,3022))}};function tA(a,b){for(var c=8,d=0;d<a.boxes.length&&a.boxes[d].type!==b;d++)c+=a.boxes[d].size;return c}M("shaka.transmuxer.MssTransmuxer",qA);qA.prototype.transmux=qA.prototype.transmux;qA.prototype.getOriginalMimeType=qA.prototype.getOriginalMimeType;
1226
- qA.prototype.convertCodecs=qA.prototype.convertCodecs;qA.prototype.isSupported=qA.prototype.isSupported;qA.prototype.destroy=qA.prototype.destroy;var sA=new Uint8Array([162,57,79,82,90,155,79,20,162,68,108,66,124,100,141,244]);Uc("mss/audio/mp4",function(){return new qA("mss/audio/mp4")},$c);Uc("mss/video/mp4",function(){return new qA("mss/video/mp4")},$c);function uA(a){this.j=a;this.g=0;this.h=new Map;this.i=null}p=uA.prototype;p.destroy=function(){this.h.clear()};p.isSupported=function(a,b){if("video/mp2t"!=a.toLowerCase().split(";")[0])return!1;var c=a;b&&(c=this.convertCodecs(b,a));var d=id(c).split(",");c=Fb("audio",d);d=Fb("video",d);if(c&&(c=fd(c),!vA.includes(c))||d&&(c=fd(d),!wA.includes(c)))return!1;if(b)return dc(this.convertCodecs(b,a));b=this.convertCodecs("audio",a);a=this.convertCodecs("video",a);return dc(b)||dc(a)};
1224
+ 1;var u=e.fetch("moof");k.data_offset=u.getLength()+8;var v=e.fetch("saio");null!==v&&(v.offset[0]=sA(u,"traf")+sA(h,"senc")+16);var y=lc(e.write());return Promise.resolve(y)}catch(z){return z instanceof P?Promise.reject(z):Promise.reject(new P(2,3,3022))}};function sA(a,b){for(var c=8,d=0;d<a.boxes.length&&a.boxes[d].type!==b;d++)c+=a.boxes[d].size;return c}M("shaka.transmuxer.MssTransmuxer",pA);pA.prototype.transmux=pA.prototype.transmux;pA.prototype.getOriginalMimeType=pA.prototype.getOriginalMimeType;
1225
+ pA.prototype.convertCodecs=pA.prototype.convertCodecs;pA.prototype.isSupported=pA.prototype.isSupported;pA.prototype.destroy=pA.prototype.destroy;var rA=new Uint8Array([162,57,79,82,90,155,79,20,162,68,108,66,124,100,141,244]);Uc("mss/audio/mp4",function(){return new pA("mss/audio/mp4")},$c);Uc("mss/video/mp4",function(){return new pA("mss/video/mp4")},$c);function tA(a){this.j=a;this.g=0;this.h=new Map;this.i=null}p=tA.prototype;p.destroy=function(){this.h.clear()};p.isSupported=function(a,b){if("video/mp2t"!=a.toLowerCase().split(";")[0])return!1;var c=a;b&&(c=this.convertCodecs(b,a));var d=id(c).split(",");c=Fb("audio",d);d=Fb("video",d);if(c&&(c=fd(c),!uA.includes(c))||d&&(c=fd(d),!vA.includes(c)))return!1;if(b)return dc(this.convertCodecs(b,a));b=this.convertCodecs("audio",a);a=this.convertCodecs("video",a);return dc(b)||dc(a)};
1227
1226
  p.convertCodecs=function(a,b){return"video/mp2t"==b.toLowerCase().split(";")[0]?(b=id(b).replace("mp4a.40.34","mp3").split(",").map(this.Rh).join(","),"audio"==a?'audio/mp4; codecs="'+b+'"':'video/mp4; codecs="'+b+'"'):b};p.Rh=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};p.getOriginalMimeType=function(){return this.j};
1228
- p.transmux=function(a,b,c,d,e){this.i?this.i.clearData():this.i=new mi;a=lc(a);var f=this.i.parse(a);a=[];var g=f.pd();try{var h=null;if("video"==e){switch(g.video){case "avc":var k=[],l=null,m=[],n=f.Ic();if(!n.length)throw new P(2,3,3023);for(var q=0;q<n.length;q++){var r=n[q],u=r.nalus;m.push.apply(m,w(u));var v=cA(u);if(v){null==l&&(l=r.dts);var y=void 0;y=q+1<n.length?(n[q+1].dts||0)-(r.dts||0):1<n.length?(r.dts||0)-(n[q-1].dts||0):9E4*(c.endTime-c.startTime);k.push({data:v.data,size:v.data.byteLength,
1229
- duration:y,jb:Math.round((r.pts||0)-(r.dts||0)),flags:{mb:0,ab:0,$a:0,Ya:0,Za:v.wd?2:1,ob:v.wd?0:1}})}}var z=aA(m);if(!z||null==l)throw new P(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,hb:[],na:new Uint8Array([]),Ba:z.Ba,Ha:z.Ha,Ja:z.Ja,data:{Ab:this.g,baseMediaDecodeTime:l,eb:k},stream:b};break;case "hvc":n=[];r=null;u=[];k=f.Ic();if(!k.length)throw new P(2,3,3023);for(v=0;v<k.length;v++){l=
1230
- k[v];m=l.nalus;u.push.apply(u,w(m));z=!1;var x=[],A=!1;q=t(m);for(y=q.next();!y.done;y=q.next()){var B=y.value;switch(B.type){case 1:case 0:var C=A=!0;break;case 19:case 20:case 21:z=C=A=!0;break;case 32:C=!0;break;case 33:C=!0;break;case 34:C=!0;break;case 35:A=C=!0;break;case 39:case 40:C=!0;break;default:C=!1}if(A&&C){var E=B.fullData.byteLength,H=new Uint8Array(4);H[0]=E>>24&255;H[1]=E>>16&255;H[2]=E>>8&255;H[3]=E&255;x.push(jg(H,B.fullData))}}var G=x.length?{data:jg.apply(cg,w(x)),wd:z}:null;
1231
- G&&(null==r&&null!=l.dts&&(r=l.dts),z=void 0,z=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,jb:Math.round((l.pts||0)-(l.dts||0)),flags:{mb:0,ab:0,$a:0,Ya:0,Za:G.wd?2:1,ob:G.wd?0:1}}))}var I=dA(u);if(!I||null==r)throw new P(2,3,3018);b.height=I.height;b.width=I.width;h={id:b.id,type:"video",codecs:"hvc1",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:9E4,duration:d,hb:[],na:new Uint8Array([]),
1232
- Ba:I.Ba,Ha:I.Ha,Ja:I.Ja,data:{Ab:this.g,baseMediaDecodeTime:r,eb:n},stream:b}}h&&(a.push(h),h=null)}if("audio"==e){switch(g.audio){case "aac":for(var J=[],L,N=null,R=t(f.jc()),T=R.next();!T.done;T=R.next()){var ea=T.value,Z=ea.data;if(Z){var fa=0;L=Sz(Z,fa);if(!L)throw new P(2,3,3018);b.audioSamplingRate=L.sampleRate;b.channelsCount=L.channelCount;null==N&&null!==ea.pts&&(N=ea.pts);for(;fa<Z.length;){var Ha=Rz(Z,fa);if(Ha){var Xa=Ha.ge+Ha.X;fa+Xa<=Z.length&&J.push({data:Z.subarray(fa+Ha.ge,fa+Xa),
1233
- size:Ha.X,duration:1024,jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}});fa+=Xa}else fa++}}}if(!L||null==N){if(!f.Ic().length)throw new P(2,3,3018);N=9E4*c.startTime;var Gb=Fb("audio",b.codecs.split(","));if(!Gb||!b.channelsCount||!b.audioSamplingRate)throw new P(2,3,3018);L={sampleRate:b.audioSamplingRate,channelCount:b.channelsCount,va:Gb};var lb=Uz(Gb,b.channelsCount);if(!lb)throw new P(2,3,3018);var bc=N+9E4*(c.endTime-c.startTime);for(f=N;f<bc;)J.push({data:lb,size:lb.byteLength,duration:1024,jb:0,
1234
- flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}}),f+=1024/L.sampleRate*9E4}var za=L.sampleRate;f=N/9E4*za;h={id:b.id,type:"audio",codecs:L.va,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:za,duration:d,hb:[],na:new Uint8Array([]),Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.g,baseMediaDecodeTime:f,eb:J},stream:b};break;case "ac3":L=[];za=0;J=new Uint8Array([]);N=null;fa=t(f.jc());for(var mb=fa.next();!mb.done;mb=fa.next()){var hb=mb.value,Hb=hb.data;null==N&&null!==hb.pts&&(N=hb.pts);for(f=0;f<Hb.length;){var ib=
1235
- Wz(Hb,f);ib?(b.audioSamplingRate=ib.sampleRate,b.channelsCount=ib.channelCount,za=ib.sampleRate,J=ib.na,L.push({data:Hb.subarray(f,f+ib.X),size:ib.X,duration:1536,jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}}),f+=ib.X):f++}}if(0==za||0==J.byteLength||null==N)throw new P(2,3,3018);f=N/9E4*za;h={id:b.id,type:"audio",codecs:"ac-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:za,duration:d,hb:[],na:J,Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.g,baseMediaDecodeTime:f,eb:L},stream:b};break;case "ec3":L=
1236
- [];za=0;N=new Uint8Array([]);J=null;for(var Wh=t(f.jc()),Md=Wh.next();!Md.done;Md=Wh.next()){var Me=Md.value,Ne=Me.data;null==J&&null!==Me.pts&&(J=Me.pts);for(f=0;f<Ne.length;){var sb=Zz(Ne,f);sb?(b.audioSamplingRate=sb.sampleRate,b.channelsCount=sb.channelCount,za=sb.sampleRate,N=sb.na,L.push({data:Ne.subarray(f,f+sb.X),size:sb.X,duration:1536,jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}}),f+=sb.X):f++}}if(0==za||0==N.byteLength||null==J)throw new P(2,3,3018);f=J/9E4*za;h={id:b.id,type:"audio",codecs:"ec-3",
1237
- encrypted:b.encrypted&&0<b.drmInfos.length,timescale:za,duration:d,hb:[],na:N,Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.g,baseMediaDecodeTime:f,eb:L},stream:b};break;case "mp3":L=[];var Fi;za=null;for(var ju=t(f.jc()),gm=ju.next();!gm.done;gm=ju.next()){var hm=gm.value,hg=hm.data;if(hg)for(null==za&&null!==hm.pts&&(za=hm.pts),f=0;f<hg.length;){var Ve=iA(hg,f);Ve?(Fi||(Fi=Ve),f+Ve.X<=hg.length&&L.push({data:hg.subarray(f,f+Ve.X),size:Ve.X,duration:1152,jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}}),
1238
- f+=Ve.X):f++}}if(!Fi||null==za)throw new P(2,3,3018);var ku=Fi.sampleRate;f=za/9E4*ku;h={id:b.id,type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:ku,duration:d,hb:[],na:new Uint8Array([]),Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.g,baseMediaDecodeTime:f,eb:L},stream:b}}h&&a.push(h)}}catch(im){return im&&3023==im.code?Promise.resolve(new Uint8Array([])):Promise.reject(im)}if(!a.length)return Promise.reject(new P(2,3,3018));a=new iu(a);this.h.has(b.id)?d=this.h.get(b.id):
1239
- (d=qu(a),this.h.set(b.id,d));b=Hu(a);this.g++;b=jg(d,b);return Promise.resolve(b)};M("shaka.transmuxer.TsTransmuxer",uA);uA.prototype.transmux=uA.prototype.transmux;uA.prototype.getOriginalMimeType=uA.prototype.getOriginalMimeType;uA.prototype.convertCodecs=uA.prototype.convertCodecs;uA.prototype.isSupported=uA.prototype.isSupported;uA.prototype.destroy=uA.prototype.destroy;var vA=["aac","ac-3","ec-3","mp3"],wA=["avc","hevc"];Uc("video/mp2t",function(){return new uA("video/mp2t")},Yc);/*
1227
+ p.transmux=function(a,b,c,d,e){this.i?this.i.clearData():this.i=new mi;a=lc(a);var f=this.i.parse(a);a=[];var g=f.pd();try{var h=null;if("video"==e){switch(g.video){case "avc":var k=[],l=null,m=[],n=f.Ic();if(!n.length)throw new P(2,3,3023);for(var q=0;q<n.length;q++){var r=n[q],u=r.nalus;m.push.apply(m,w(u));var v=bA(u);if(v){null==l&&(l=r.dts);var y=void 0;y=q+1<n.length?(n[q+1].dts||0)-(r.dts||0):1<n.length?(r.dts||0)-(n[q-1].dts||0):9E4*(c.endTime-c.startTime);k.push({data:v.data,size:v.data.byteLength,
1228
+ duration:y,jb:Math.round((r.pts||0)-(r.dts||0)),flags:{mb:0,ab:0,$a:0,Ya:0,Za:v.wd?2:1,ob:v.wd?0:1}})}}var z=$z(m);if(!z||null==l)throw new P(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,hb:[],na:new Uint8Array([]),Ba:z.Ba,Ha:z.Ha,Ja:z.Ja,data:{Ab:this.g,baseMediaDecodeTime:l,eb:k},stream:b};break;case "hvc":n=[];r=null;u=[];k=f.Ic();if(!k.length)throw new P(2,3,3023);for(v=0;v<k.length;v++){l=
1229
+ k[v];m=l.nalus;u.push.apply(u,w(m));z=!1;var x=[],A=!1;q=t(m);for(y=q.next();!y.done;y=q.next()){var B=y.value;switch(B.type){case 1:case 0:var C=A=!0;break;case 19:case 20:case 21:z=C=A=!0;break;case 32:C=!0;break;case 33:C=!0;break;case 34:C=!0;break;case 35:A=C=!0;break;case 39:case 40:C=!0;break;default:C=!1}if(A&&C){var E=B.fullData.byteLength,H=new Uint8Array(4);H[0]=E>>24&255;H[1]=E>>16&255;H[2]=E>>8&255;H[3]=E&255;x.push(ig(H,B.fullData))}}var G=x.length?{data:ig.apply(cg,w(x)),wd:z}:null;
1230
+ G&&(null==r&&null!=l.dts&&(r=l.dts),z=void 0,z=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,jb:Math.round((l.pts||0)-(l.dts||0)),flags:{mb:0,ab:0,$a:0,Ya:0,Za:G.wd?2:1,ob:G.wd?0:1}}))}var I=cA(u);if(!I||null==r)throw new P(2,3,3018);b.height=I.height;b.width=I.width;h={id:b.id,type:"video",codecs:"hvc1",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:9E4,duration:d,hb:[],na:new Uint8Array([]),
1231
+ Ba:I.Ba,Ha:I.Ha,Ja:I.Ja,data:{Ab:this.g,baseMediaDecodeTime:r,eb:n},stream:b}}h&&(a.push(h),h=null)}if("audio"==e){switch(g.audio){case "aac":for(var J=[],L,N=null,R=t(f.kc()),T=R.next();!T.done;T=R.next()){var ea=T.value,Z=ea.data;if(Z){var fa=0;L=Rz(Z,fa);if(!L)throw new P(2,3,3018);b.audioSamplingRate=L.sampleRate;b.channelsCount=L.channelCount;null==N&&null!==ea.pts&&(N=ea.pts);for(;fa<Z.length;){var Ha=Qz(Z,fa);if(Ha){var Xa=Ha.ge+Ha.X;fa+Xa<=Z.length&&J.push({data:Z.subarray(fa+Ha.ge,fa+Xa),
1232
+ size:Ha.X,duration:1024,jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}});fa+=Xa}else fa++}}}if(!L||null==N){if(!f.Ic().length)throw new P(2,3,3018);N=9E4*c.startTime;var Gb=Fb("audio",b.codecs.split(","));if(!Gb||!b.channelsCount||!b.audioSamplingRate)throw new P(2,3,3018);L={sampleRate:b.audioSamplingRate,channelCount:b.channelsCount,va:Gb};var lb=Tz(Gb,b.channelsCount);if(!lb)throw new P(2,3,3018);var bc=N+9E4*(c.endTime-c.startTime);for(f=N;f<bc;)J.push({data:lb,size:lb.byteLength,duration:1024,jb:0,
1233
+ flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}}),f+=1024/L.sampleRate*9E4}var za=L.sampleRate;f=N/9E4*za;h={id:b.id,type:"audio",codecs:L.va,encrypted:b.encrypted&&0<b.drmInfos.length,timescale:za,duration:d,hb:[],na:new Uint8Array([]),Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.g,baseMediaDecodeTime:f,eb:J},stream:b};break;case "ac3":L=[];za=0;J=new Uint8Array([]);N=null;fa=t(f.kc());for(var mb=fa.next();!mb.done;mb=fa.next()){var hb=mb.value,Hb=hb.data;null==N&&null!==hb.pts&&(N=hb.pts);for(f=0;f<Hb.length;){var ib=
1234
+ Vz(Hb,f);ib?(b.audioSamplingRate=ib.sampleRate,b.channelsCount=ib.channelCount,za=ib.sampleRate,J=ib.na,L.push({data:Hb.subarray(f,f+ib.X),size:ib.X,duration:1536,jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}}),f+=ib.X):f++}}if(0==za||0==J.byteLength||null==N)throw new P(2,3,3018);f=N/9E4*za;h={id:b.id,type:"audio",codecs:"ac-3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:za,duration:d,hb:[],na:J,Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.g,baseMediaDecodeTime:f,eb:L},stream:b};break;case "ec3":L=
1235
+ [];za=0;N=new Uint8Array([]);J=null;for(var Xh=t(f.kc()),Md=Xh.next();!Md.done;Md=Xh.next()){var Oe=Md.value,Pe=Oe.data;null==J&&null!==Oe.pts&&(J=Oe.pts);for(f=0;f<Pe.length;){var sb=Yz(Pe,f);sb?(b.audioSamplingRate=sb.sampleRate,b.channelsCount=sb.channelCount,za=sb.sampleRate,N=sb.na,L.push({data:Pe.subarray(f,f+sb.X),size:sb.X,duration:1536,jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}}),f+=sb.X):f++}}if(0==za||0==N.byteLength||null==J)throw new P(2,3,3018);f=J/9E4*za;h={id:b.id,type:"audio",codecs:"ec-3",
1236
+ encrypted:b.encrypted&&0<b.drmInfos.length,timescale:za,duration:d,hb:[],na:N,Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.g,baseMediaDecodeTime:f,eb:L},stream:b};break;case "mp3":L=[];var Fi;za=null;for(var ku=t(f.kc()),gm=ku.next();!gm.done;gm=ku.next()){var hm=gm.value,jg=hm.data;if(jg)for(null==za&&null!==hm.pts&&(za=hm.pts),f=0;f<jg.length;){var Xe=hA(jg,f);Xe?(Fi||(Fi=Xe),f+Xe.X<=jg.length&&L.push({data:jg.subarray(f,f+Xe.X),size:Xe.X,duration:1152,jb:0,flags:{mb:0,ab:0,$a:0,Ya:0,Za:2,ob:0}}),
1237
+ f+=Xe.X):f++}}if(!Fi||null==za)throw new P(2,3,3018);var lu=Fi.sampleRate;f=za/9E4*lu;h={id:b.id,type:"audio",codecs:"mp3",encrypted:b.encrypted&&0<b.drmInfos.length,timescale:lu,duration:d,hb:[],na:new Uint8Array([]),Ba:new Uint8Array([]),Ha:0,Ja:0,data:{Ab:this.g,baseMediaDecodeTime:f,eb:L},stream:b}}h&&a.push(h)}}catch(im){return im&&3023==im.code?Promise.resolve(new Uint8Array([])):Promise.reject(im)}if(!a.length)return Promise.reject(new P(2,3,3018));a=new iu(a);this.h.has(b.id)?d=this.h.get(b.id):
1238
+ (d=qu(a),this.h.set(b.id,d));b=Hu(a);this.g++;b=ig(d,b);return Promise.resolve(b)};M("shaka.transmuxer.TsTransmuxer",tA);tA.prototype.transmux=tA.prototype.transmux;tA.prototype.getOriginalMimeType=tA.prototype.getOriginalMimeType;tA.prototype.convertCodecs=tA.prototype.convertCodecs;tA.prototype.isSupported=tA.prototype.isSupported;tA.prototype.destroy=tA.prototype.destroy;var uA=["aac","ac-3","ec-3","mp3"],vA=["avc","hevc"];Uc("video/mp2t",function(){return new tA("video/mp2t")},Yc);/*
1240
1239
  @license
1241
1240
  EME Encryption Scheme Polyfill
1242
1241
  Copyright 2019 Google LLC
1243
1242
  SPDX-License-Identifier: Apache-2.0
1244
1243
  */
1245
- function xA(){}var yA;function zA(){yA?console.debug("EmeEncryptionSchemePolyfill: Already installed."):navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration?(yA=navigator.requestMediaKeySystemAccess,console.debug("EmeEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.requestMediaKeySystemAccess=AA):console.debug("EmeEncryptionSchemePolyfill: EME not found")}
1246
- function AA(a,b){var c=this,d;return K(function(e){if(1==e.g)return console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess'),D(e,yA.call(c,a,b),2);d=e.h;if(BA(d))return console.debug("EmeEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.requestMediaKeySystemAccess=yA,e.return(d);console.debug("EmeEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");navigator.requestMediaKeySystemAccess=CA;return e.return(CA.call(c,
1244
+ function wA(){}var xA;function yA(){xA?console.debug("EmeEncryptionSchemePolyfill: Already installed."):navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration?(xA=navigator.requestMediaKeySystemAccess,console.debug("EmeEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.requestMediaKeySystemAccess=zA):console.debug("EmeEncryptionSchemePolyfill: EME not found")}
1245
+ function zA(a,b){var c=this,d;return K(function(e){if(1==e.g)return console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess'),D(e,xA.call(c,a,b),2);d=e.h;if(AA(d))return console.debug("EmeEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.requestMediaKeySystemAccess=xA,e.return(d);console.debug("EmeEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");navigator.requestMediaKeySystemAccess=BA;return e.return(BA.call(c,
1247
1246
  a,b))})}
1248
- function CA(a,b){var c=this,d,e,f,g,h,k,l,m,n,q;return K(function(r){if(1==r.g){console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess');d=DA(a);e=[];f=t(b);for(g=f.next();!g.done;g=f.next())h=g.value,k=EA(h.videoCapabilities,d),l=EA(h.audioCapabilities,d),h.videoCapabilities&&h.videoCapabilities.length&&!k.length||h.audioCapabilities&&h.audioCapabilities.length&&!l.length||(m=Object.assign({},h),m.videoCapabilities=k,m.audioCapabilities=l,e.push(m));if(!e.length)throw n=Error("Unsupported keySystem or supportedConfigurations."),
1249
- n.name="NotSupportedError",n.code=DOMException.NOT_SUPPORTED_ERR,n;return D(r,yA.call(c,a,e),2)}q=r.h;return r.return(new FA(q,d))})}function EA(a,b){return a?a.filter(function(c){return!c.encryptionScheme||c.encryptionScheme==b}):a}M("EmeEncryptionSchemePolyfill",xA);xA.install=zA;function GA(){}var HA;
1250
- function IA(){HA?console.debug("McEncryptionSchemePolyfill: Already installed."):navigator.mediaCapabilities?(HA=navigator.mediaCapabilities.decodingInfo,console.debug("McEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.mediaCapabilities.decodingInfo=JA):console.debug("McEncryptionSchemePolyfill: MediaCapabilities not found")}
1251
- function JA(a){var b=this,c,d,e;return K(function(f){switch(f.g){case 1:return console.assert(b==navigator.mediaCapabilities,'bad "this" for decodingInfo'),D(f,HA.call(b,a),2);case 2:c=f.h;if(!a.keySystemConfiguration)return f.return(c);if((d=c.keySystemAccess)&&BA(d))return console.debug("McEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.mediaCapabilities.decodingInfo=HA,f.return(c);console.debug("McEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");
1252
- navigator.mediaCapabilities.decodingInfo=KA;if(d){f.F(3);break}e=c;return D(f,LA(a),4);case 4:return e.keySystemAccess=f.h,f.return(c);case 3:return f.return(KA.call(b,a))}})}
1253
- function KA(a){var b=this,c,d,e,f,g,h,k,l;return K(function(m){switch(m.g){case 1:return console.assert(b==navigator.mediaCapabilities,'bad "this" for decodingInfo'),c=null,a.keySystemConfiguration&&(d=a.keySystemConfiguration,e=d.keySystem,f=d.audio&&d.audio.encryptionScheme,g=d.video&&d.video.encryptionScheme,c=DA(e),h={powerEfficient:!1,smooth:!1,supported:!1,keySystemAccess:null,configuration:a},f&&f!=c||g&&g!=c)?m.return(h):D(m,HA.call(b,a),2);case 2:k=m.h;if(k.keySystemAccess){k.keySystemAccess=
1254
- new FA(k.keySystemAccess,c);m.F(3);break}if(!a.keySystemConfiguration){m.F(3);break}l=k;return D(m,LA(a),5);case 5:l.keySystemAccess=m.h;case 3:return m.return(k)}})}
1255
- function LA(a){var b,c;return K(function(d){if(1==d.g){var e=a.keySystemConfiguration,f=[],g=[];e.audio&&f.push({robustness:e.audio.robustness||"",contentType:a.audio.contentType});e.video&&g.push({robustness:e.video.robustness||"",contentType:a.video.contentType});e={initDataTypes:e.initDataType?[e.initDataType]:[],distinctiveIdentifier:e.distinctiveIdentifier,persistentState:e.persistentState,sessionTypes:e.sessionTypes};f.length&&(e.audioCapabilities=f);g.length&&(e.videoCapabilities=g);b=e;return D(d,
1256
- navigator.requestMediaKeySystemAccess(a.keySystemConfiguration.keySystem,[b]),2)}c=d.h;return d.return(c)})}M("McEncryptionSchemePolyfill",GA);GA.install=IA;function FA(a,b){this.h=a;this.g=b;this.keySystem=a.keySystem}
1257
- FA.prototype.getConfiguration=function(){var a=this.h.getConfiguration();if(a.videoCapabilities)for(var b=t(a.videoCapabilities),c=b.next();!c.done;c=b.next())c.value.encryptionScheme=this.g;if(a.audioCapabilities)for(b=t(a.audioCapabilities),c=b.next();!c.done;c=b.next())c.value.encryptionScheme=this.g;return a};FA.prototype.createMediaKeys=function(){return this.h.createMediaKeys()};
1258
- function DA(a){if(a.startsWith("com.widevine")||a.startsWith("com.microsoft")||a.startsWith("com.chromecast")||a.startsWith("com.adobe")||a.startsWith("org.w3"))return"cenc";if(a.startsWith("com.apple"))return"cbcs-1-9";console.warn("EmeEncryptionSchemePolyfill: Unknown key system:",a,"Please contribute!");return null}function BA(a){a=a.getConfiguration();var b=a.audioCapabilities&&a.audioCapabilities[0];return(a=a.videoCapabilities&&a.videoCapabilities[0]||b)&&void 0!==a.encryptionScheme?!0:!1}
1259
- function MA(){}function hx(){zA();IA()}M("EncryptionSchemePolyfills",MA);MA.install=hx;"undefined"!==typeof module&&module.exports&&(module.exports=MA);/*
1247
+ function BA(a,b){var c=this,d,e,f,g,h,k,l,m,n,q;return K(function(r){if(1==r.g){console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess');d=CA(a);e=[];f=t(b);for(g=f.next();!g.done;g=f.next())h=g.value,k=DA(h.videoCapabilities,d),l=DA(h.audioCapabilities,d),h.videoCapabilities&&h.videoCapabilities.length&&!k.length||h.audioCapabilities&&h.audioCapabilities.length&&!l.length||(m=Object.assign({},h),m.videoCapabilities=k,m.audioCapabilities=l,e.push(m));if(!e.length)throw n=Error("Unsupported keySystem or supportedConfigurations."),
1248
+ n.name="NotSupportedError",n.code=DOMException.NOT_SUPPORTED_ERR,n;return D(r,xA.call(c,a,e),2)}q=r.h;return r.return(new EA(q,d))})}function DA(a,b){return a?a.filter(function(c){return!c.encryptionScheme||c.encryptionScheme==b}):a}M("EmeEncryptionSchemePolyfill",wA);wA.install=yA;function FA(){}var GA;
1249
+ function HA(){GA?console.debug("McEncryptionSchemePolyfill: Already installed."):navigator.mediaCapabilities?(GA=navigator.mediaCapabilities.decodingInfo,console.debug("McEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.mediaCapabilities.decodingInfo=IA):console.debug("McEncryptionSchemePolyfill: MediaCapabilities not found")}
1250
+ function IA(a){var b=this,c,d,e;return K(function(f){switch(f.g){case 1:return console.assert(b==navigator.mediaCapabilities,'bad "this" for decodingInfo'),D(f,GA.call(b,a),2);case 2:c=f.h;if(!a.keySystemConfiguration)return f.return(c);if((d=c.keySystemAccess)&&AA(d))return console.debug("McEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.mediaCapabilities.decodingInfo=GA,f.return(c);console.debug("McEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");
1251
+ navigator.mediaCapabilities.decodingInfo=JA;if(d){f.F(3);break}e=c;return D(f,KA(a),4);case 4:return e.keySystemAccess=f.h,f.return(c);case 3:return f.return(JA.call(b,a))}})}
1252
+ function JA(a){var b=this,c,d,e,f,g,h,k,l;return K(function(m){switch(m.g){case 1:return console.assert(b==navigator.mediaCapabilities,'bad "this" for decodingInfo'),c=null,a.keySystemConfiguration&&(d=a.keySystemConfiguration,e=d.keySystem,f=d.audio&&d.audio.encryptionScheme,g=d.video&&d.video.encryptionScheme,c=CA(e),h={powerEfficient:!1,smooth:!1,supported:!1,keySystemAccess:null,configuration:a},f&&f!=c||g&&g!=c)?m.return(h):D(m,GA.call(b,a),2);case 2:k=m.h;if(k.keySystemAccess){k.keySystemAccess=
1253
+ new EA(k.keySystemAccess,c);m.F(3);break}if(!a.keySystemConfiguration){m.F(3);break}l=k;return D(m,KA(a),5);case 5:l.keySystemAccess=m.h;case 3:return m.return(k)}})}
1254
+ function KA(a){var b,c;return K(function(d){if(1==d.g){var e=a.keySystemConfiguration,f=[],g=[];e.audio&&f.push({robustness:e.audio.robustness||"",contentType:a.audio.contentType});e.video&&g.push({robustness:e.video.robustness||"",contentType:a.video.contentType});e={initDataTypes:e.initDataType?[e.initDataType]:[],distinctiveIdentifier:e.distinctiveIdentifier,persistentState:e.persistentState,sessionTypes:e.sessionTypes};f.length&&(e.audioCapabilities=f);g.length&&(e.videoCapabilities=g);b=e;return D(d,
1255
+ navigator.requestMediaKeySystemAccess(a.keySystemConfiguration.keySystem,[b]),2)}c=d.h;return d.return(c)})}M("McEncryptionSchemePolyfill",FA);FA.install=HA;function EA(a,b){this.h=a;this.g=b;this.keySystem=a.keySystem}
1256
+ EA.prototype.getConfiguration=function(){var a=this.h.getConfiguration();if(a.videoCapabilities)for(var b=t(a.videoCapabilities),c=b.next();!c.done;c=b.next())c.value.encryptionScheme=this.g;if(a.audioCapabilities)for(b=t(a.audioCapabilities),c=b.next();!c.done;c=b.next())c.value.encryptionScheme=this.g;return a};EA.prototype.createMediaKeys=function(){return this.h.createMediaKeys()};
1257
+ function CA(a){if(a.startsWith("com.widevine")||a.startsWith("com.microsoft")||a.startsWith("com.chromecast")||a.startsWith("com.adobe")||a.startsWith("org.w3"))return"cenc";if(a.startsWith("com.apple"))return"cbcs-1-9";console.warn("EmeEncryptionSchemePolyfill: Unknown key system:",a,"Please contribute!");return null}function AA(a){a=a.getConfiguration();var b=a.audioCapabilities&&a.audioCapabilities[0];return(a=a.videoCapabilities&&a.videoCapabilities[0]||b)&&void 0!==a.encryptionScheme?!0:!1}
1258
+ function LA(){}function hx(){yA();HA()}M("EncryptionSchemePolyfills",LA);LA.install=hx;"undefined"!==typeof module&&module.exports&&(module.exports=LA);/*
1260
1259
  @license
1261
1260
  Copyright 2013 Ali Al Dallal
1262
1261
 
@@ -1280,7 +1279,7 @@ function MA(){}function hx(){zA();IA()}M("EncryptionSchemePolyfills",MA);MA.inst
1280
1279
  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
1281
1280
  SOFTWARE.
1282
1281
  */
1283
- for(var NA={ach:{A:"Lwo",B:"Acholi"},ady:{A:"\u0410\u0434\u044b\u0433\u044d\u0431\u0437\u044d",B:"Adyghe"},af:{A:"Afrikaans",B:"Afrikaans"},"af-NA":{A:"Afrikaans (Namibia)",B:"Afrikaans (Namibia)"},"af-ZA":{A:"Afrikaans (South Africa)",B:"Afrikaans (South Africa)"},ak:{A:"T\u0255\u0265i",B:"Akan"},ar:{A:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",B:"Arabic"},"ar-AR":{A:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",B:"Arabic"},"ar-MA":{A:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",B:"Arabic (Morocco)"},
1282
+ for(var MA={ach:{A:"Lwo",B:"Acholi"},ady:{A:"\u0410\u0434\u044b\u0433\u044d\u0431\u0437\u044d",B:"Adyghe"},af:{A:"Afrikaans",B:"Afrikaans"},"af-NA":{A:"Afrikaans (Namibia)",B:"Afrikaans (Namibia)"},"af-ZA":{A:"Afrikaans (South Africa)",B:"Afrikaans (South Africa)"},ak:{A:"T\u0255\u0265i",B:"Akan"},ar:{A:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",B:"Arabic"},"ar-AR":{A:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",B:"Arabic"},"ar-MA":{A:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",B:"Arabic (Morocco)"},
1284
1283
  "ar-SA":{A:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629 (\u0627\u0644\u0633\u0639\u0648\u062f\u064a\u0629)",B:"Arabic (Saudi Arabia)"},"ay-BO":{A:"Aymar aru",B:"Aymara"},az:{A:"Az\u0259rbaycan dili",B:"Azerbaijani"},"az-AZ":{A:"Az\u0259rbaycan dili",B:"Azerbaijani"},"be-BY":{A:"\u0411\u0435\u043b\u0430\u0440\u0443\u0441\u043a\u0430\u044f",B:"Belarusian"},bg:{A:"\u0411\u044a\u043b\u0433\u0430\u0440\u0441\u043a\u0438",B:"Bulgarian"},"bg-BG":{A:"\u0411\u044a\u043b\u0433\u0430\u0440\u0441\u043a\u0438",
1285
1284
  B:"Bulgarian"},bn:{A:"\u09ac\u09be\u0982\u09b2\u09be",B:"Bengali"},"bn-IN":{A:"\u09ac\u09be\u0982\u09b2\u09be (\u09ad\u09be\u09b0\u09a4)",B:"Bengali (India)"},"bn-BD":{A:"\u09ac\u09be\u0982\u09b2\u09be(\u09ac\u09be\u0982\u09b2\u09be\u09a6\u09c7\u09b6)",B:"Bengali (Bangladesh)"},"bs-BA":{A:"Bosanski",B:"Bosnian"},ca:{A:"Catal\u00e0",B:"Catalan"},"ca-ES":{A:"Catal\u00e0",B:"Catalan"},cak:{A:"Maya Kaqchikel",B:"Kaqchikel"},"ck-US":{A:"\u13e3\u13b3\u13a9 (tsalagi)",B:"Cherokee"},cs:{A:"\u010ce\u0161tina",
1286
1285
  B:"Czech"},"cs-CZ":{A:"\u010ce\u0161tina",B:"Czech"},cy:{A:"Cymraeg",B:"Welsh"},"cy-GB":{A:"Cymraeg",B:"Welsh"},da:{A:"Dansk",B:"Danish"},"da-DK":{A:"Dansk",B:"Danish"},de:{A:"Deutsch",B:"German"},"de-AT":{A:"Deutsch (\u00d6sterreich)",B:"German (Austria)"},"de-DE":{A:"Deutsch (Deutschland)",B:"German (Germany)"},"de-CH":{A:"Deutsch (Schweiz)",B:"German (Switzerland)"},dsb:{A:"Dolnoserb\u0161\u0107ina",B:"Lower Sorbian"},el:{A:"\u0395\u03bb\u03bb\u03b7\u03bd\u03b9\u03ba\u03ac",B:"Greek"},"el-GR":{A:"\u0395\u03bb\u03bb\u03b7\u03bd\u03b9\u03ba\u03ac",
@@ -1301,69 +1300,69 @@ B:"Slovak"},"sk-SK":{A:"Sloven\u010dina (Slovakia)",B:"Slovak (Slovakia)"},sl:{A
1301
1300
  sw:{A:"Kiswahili",B:"Swahili"},"sw-KE":{A:"Kiswahili",B:"Swahili (Kenya)"},ta:{A:"\u0ba4\u0bae\u0bbf\u0bb4\u0bcd",B:"Tamil"},"ta-IN":{A:"\u0ba4\u0bae\u0bbf\u0bb4\u0bcd",B:"Tamil"},te:{A:"\u0c24\u0c46\u0c32\u0c41\u0c17\u0c41",B:"Telugu"},"te-IN":{A:"\u0c24\u0c46\u0c32\u0c41\u0c17\u0c41",B:"Telugu"},tg:{A:"\u0437\u0430\u0431\u043e\u0301\u043d\u0438 \u0442\u043e\u04b7\u0438\u043a\u04e3\u0301",B:"Tajik"},"tg-TJ":{A:"\u0442\u043e\u04b7\u0438\u043a\u04e3",B:"Tajik"},th:{A:"\u0e20\u0e32\u0e29\u0e32\u0e44\u0e17\u0e22",
1302
1301
  B:"Thai"},"th-TH":{A:"\u0e20\u0e32\u0e29\u0e32\u0e44\u0e17\u0e22 (\u0e1b\u0e23\u0e30\u0e40\u0e17\u0e28\u0e44\u0e17\u0e22)",B:"Thai (Thailand)"},tl:{A:"Filipino",B:"Filipino"},"tl-PH":{A:"Filipino",B:"Filipino"},tlh:{A:"tlhIngan-Hol",B:"Klingon"},tr:{A:"T\u00fcrk\u00e7e",B:"Turkish"},"tr-TR":{A:"T\u00fcrk\u00e7e",B:"Turkish"},"tt-RU":{A:"\u0442\u0430\u0442\u0430\u0440\u0447\u0430",B:"Tatar"},uk:{A:"\u0423\u043a\u0440\u0430\u0457\u043d\u0441\u044c\u043a\u0430",B:"Ukrainian"},"uk-UA":{A:"\u0423\u043a\u0440\u0430\u0457\u043d\u0441\u044c\u043a\u0430",
1303
1302
  B:"Ukrainian"},ur:{A:"\u0627\u0631\u062f\u0648",B:"Urdu"},"ur-PK":{A:"\u0627\u0631\u062f\u0648",B:"Urdu"},uz:{A:"O'zbek",B:"Uzbek"},"uz-UZ":{A:"O'zbek",B:"Uzbek"},vi:{A:"Ti\u1ebfng Vi\u1ec7t",B:"Vietnamese"},"vi-VN":{A:"Ti\u1ebfng Vi\u1ec7t",B:"Vietnamese"},"xh-ZA":{A:"isiXhosa",B:"Xhosa"},yi:{A:"\u05d9\u05d9\u05b4\u05d3\u05d9\u05e9",B:"Yiddish"},"yi-DE":{A:"\u05d9\u05d9\u05b4\u05d3\u05d9\u05e9 (German)",B:"Yiddish (German)"},zh:{A:"\u4e2d\u6587",B:"Chinese"},"zh-HANS":{A:"\u4e2d\u6587\u7b80\u4f53",
1304
- B:"Chinese Simplified"},"zh-HANT":{A:"\u4e2d\u6587\u7e41\u9ad4",B:"Chinese Traditional"},"zh-CN":{A:"\u4e2d\u6587\uff08\u4e2d\u56fd\uff09",B:"Chinese Simplified (China)"},"zh-HK":{A:"\u4e2d\u6587\uff08\u9999\u6e2f\uff09",B:"Chinese Traditional (Hong Kong)"},"zh-SG":{A:"\u4e2d\u6587\uff08\u65b0\u52a0\u5761\uff09",B:"Chinese Simplified (Singapore)"},"zh-TW":{A:"\u4e2d\u6587\uff08\u53f0\u7063\uff09",B:"Chinese Traditional (Taiwan)"},"zu-ZA":{A:"isiZulu",B:"Zulu"}},OA=t(Object.keys(NA)),PA=OA.next();!PA.done;PA=
1305
- OA.next()){var QA=PA.value;NA[QA.toLowerCase()]=NA[QA]};function RA(a,b){var c=this;this.parent=a;this.controls=b;this.eventManager=new Af;this.localization=this.controls.Ka;this.player=this.controls.Gc();this.video=this.controls.ac();this.adManager=this.player.Yd();this.ad=b.getAd();this.eventManager.o(this.adManager,"ad-started",function(d){c.ad=d.ad});this.eventManager.o(this.adManager,"ad-stopped",function(){c.ad=null})}
1306
- RA.prototype.release=function(){this.eventManager.release();this.ad=this.adManager=this.video=this.player=this.localization=this.eventManager=this.controls=this.parent=null};M("shaka.ui.Element",RA);RA.prototype.release=RA.prototype.release;function SA(a){return TA(a,"shaka-back-to-overflow-button")}function TA(a,b){a=a.getElementsByClassName(b);return a.length?a[0]:null}function UA(a){a&&(a=TA(a,"shaka-chosen-item"))&&a.parentElement.focus()}function VA(){var a=U("i");a.classList.add("material-icons-round");a.classList.add("shaka-chosen-item");a.textContent="done";a.ariaHidden="true";return a}function WA(a,b){a&&(b?a.classList.remove("shaka-hidden"):a.classList.add("shaka-hidden"))}
1307
- function XA(a,b){var c=Math.floor(a/3600),d=Math.floor(a/60%60);a=Math.floor(a%60);10>a&&(a="0"+a);a=d+":"+a;b&&(10>d&&(a="0"+a),a=c+":"+a);return a};function YA(a,b){RA.call(this,a,b);var c=this;this.i=U("div");this.i.classList.add("shaka-ad-counter");this.parent.appendChild(this.i);this.h=U("span");this.h.classList.add("shaka-ad-counter-span");this.i.appendChild(this.h);this.g=new vd(function(){var d=Math.round(c.ad.getRemainingTime()),e=c.ad.getDuration();-1!=d&&-1!=e&&(0<d?(d=XA(e-d,!1)+" / "+XA(e,!1),1<c.ad.getSequenceLength()?c.h.textContent=d:(e=c.localization.resolve("AD_TIME"),c.h.textContent=e.replace("[AD_TIME]",d))):(c.g.stop(),c.h.textContent=
1308
- ""))});this.eventManager.o(this.localization,"locale-updated",function(){});this.eventManager.o(this.localization,"locale-changed",function(){});this.eventManager.o(this.adManager,"ad-started",function(){c.g.Pa();c.g.ya(.5)});this.eventManager.o(this.adManager,"ad-stopped",function(){c.g.stop();c.h.textContent=""});this.ad&&(this.g.Pa(),this.g.ya(.5))}pa(YA,RA);YA.prototype.release=function(){this.g.stop();this.g=null;RA.prototype.release.call(this)};M("shaka.ui.AdCounter",YA);function ZA(a,b){RA.call(this,a,b);var c=this;this.g=U("div");this.g.classList.add("shaka-ad-position");WA(this.g,!1);this.parent.appendChild(this.g);this.h=U("span");this.h.classList.add("shaka-ad-position-span");this.g.appendChild(this.h);this.eventManager.o(this.localization,"locale-updated",function(){c.ad&&$A(c)});this.eventManager.o(this.localization,"locale-changed",function(){c.ad&&$A(c)});this.eventManager.o(this.adManager,"ad-started",function(){$A(c)});this.eventManager.o(this.adManager,
1309
- "ad-stopped",function(){c.h.textContent="";WA(c.g,!1)});this.ad&&$A(this)}pa(ZA,RA);function $A(a){var b=a.ad.getSequenceLength();if(1<b){var c=a.ad.getPositionInSequence();a.h.textContent=a.localization.resolve("AD_PROGRESS").replace("[AD_ON]",String(c)).replace("[NUM_ADS]",String(b));WA(a.g,!0)}}M("shaka.ui.AdPosition",ZA);function aB(a,b){RA.call(this,a,b);var c=this;this.button=Vk();this.parent.appendChild(this.button);this.eventManager.o(this.localization,"locale-updated",function(){c.g()});this.eventManager.o(this.localization,"locale-changed",function(){c.g()});this.eventManager.o(this.video,"play",function(){c.g();c.h()});this.eventManager.o(this.video,"pause",function(){c.g();c.h()});this.eventManager.o(this.video,"seeking",function(){c.g();c.h()});this.eventManager.o(this.adManager,"ad-paused",function(){c.g();
1310
- c.h()});this.eventManager.o(this.adManager,"ad-resumed",function(){c.g();c.h()});this.eventManager.o(this.adManager,"ad-started",function(){c.g();c.h()});this.eventManager.o(this.adManager,"ad-stopped",function(){c.g();c.h()});this.eventManager.o(this.button,"click",function(){c.ad&&c.ad.isLinear()?bB(c.controls):cB(c.controls)});this.ad&&(this.g(),this.h())}pa(aB,RA);aB.prototype.isPaused=function(){if(this.ad&&this.ad.isLinear())var a=this.ad.isPaused();else a=this.controls,a=a.u.paused&&!a.V;return a};
1311
- aB.prototype.isEnded=function(){return this.ad&&this.ad.isLinear()?!1:this.video.ended};aB.prototype.g=function(){};aB.prototype.h=function(){};M("shaka.ui.PlayButton",aB);function dB(a,b){aB.call(this,a,b);this.button.classList.add("shaka-play-button");this.button.classList.add("shaka-no-propagation");this.h();this.g()}pa(dB,aB);dB.prototype.h=function(){this.isPaused()?this.button.setAttribute("icon","play"):this.button.setAttribute("icon","pause")};dB.prototype.g=function(){var a=this.isPaused()?"PLAY":"PAUSE";this.button.ariaLabel=this.localization.resolve(a)};M("shaka.ui.BigPlayButton",dB);function eB(a,b){RA.call(this,a,b);var c=this;this.j=this.controls.g;this.h=this.controls.h;this.i=[];this.g=U("div");this.g.classList.add("shaka-no-propagation");this.g.classList.add("shaka-context-menu");this.g.classList.add("shaka-hidden");this.h.appendChild(this.g);this.eventManager.o(this.h,"contextmenu",function(d){if(c.g.classList.contains("shaka-hidden")){d.preventDefault();var e=c.h.getBoundingClientRect();c.g.style.left=d.clientX-e.left+"px";c.g.style.top=d.clientY-e.top+"px";WA(c.g,!0)}else WA(c.g,
1312
- !1)});this.eventManager.o(window,"click",function(){WA(c.g,!1)});fB(this)}pa(eB,RA);eB.prototype.release=function(){this.h=null;for(var a=t(this.i),b=a.next();!b.done;b=a.next())b.value.release();this.i=[];RA.prototype.release.call(this)};function gB(a,b){hB.set(a,b)}function fB(a){for(var b=t(a.j.contextMenuElements),c=b.next();!c.done;c=b.next()){c=c.value;var d=hB.get(c);d?a.i.push(d.create(a.g,a.controls)):Sa("Unrecognized context menu element:",c)}}M("shaka.ui.ContextMenu",eB);
1313
- eB.registerElement=gB;var hB=new Map;function iB(a,b,c,d){RA.call(this,a,b);var e=this;this.container=U("div");this.container.classList.add("shaka-range-container");this.container.classList.add.apply(this.container.classList,w(c));this.h=!1;this.bar=document.createElement("input");this.G=new vd(function(){e.onChangeEnd();e.h=!1});this.bar.classList.add("shaka-range-element");this.bar.classList.add.apply(this.bar.classList,w(d));this.bar.type="range";this.bar.step="any";this.bar.min="0";this.bar.max="1";this.bar.value="0";this.container.appendChild(this.bar);
1314
- this.parent.appendChild(this.container);this.eventManager.o(this.bar,"mousedown",function(){e.controls.qc()&&(e.h=!0,e.onChangeStart())});this.eventManager.o(this.bar,"touchstart",function(f){e.controls.qc()&&(e.h=!0,jB(e,f),e.onChangeStart())});this.eventManager.o(this.bar,"input",function(){e.onChange()});this.eventManager.o(this.bar,"touchmove",function(f){e.h&&(jB(e,f),e.onChange())});this.eventManager.o(this.bar,"touchend",function(f){e.h&&(e.h=!1,jB(e,f),e.onChangeEnd())});this.eventManager.o(this.bar,
1315
- "touchcancel",function(f){e.h&&(e.h=!1,jB(e,f),e.onChangeEnd())});this.eventManager.o(this.bar,"mouseup",function(){e.h&&(e.h=!1,e.onChangeEnd())});this.eventManager.o(this.bar,"blur",function(){e.h&&(e.h=!1,e.onChangeEnd())});this.eventManager.o(this.bar,"contextmenu",function(f){f.preventDefault();f.stopPropagation()})}pa(iB,RA);p=iB.prototype;p.release=function(){this.G&&(this.G.stop(),this.G=null);RA.prototype.release.call(this)};p.setRange=function(a,b){this.bar.min=a;this.bar.max=b};
1303
+ B:"Chinese Simplified"},"zh-HANT":{A:"\u4e2d\u6587\u7e41\u9ad4",B:"Chinese Traditional"},"zh-CN":{A:"\u4e2d\u6587\uff08\u4e2d\u56fd\uff09",B:"Chinese Simplified (China)"},"zh-HK":{A:"\u4e2d\u6587\uff08\u9999\u6e2f\uff09",B:"Chinese Traditional (Hong Kong)"},"zh-SG":{A:"\u4e2d\u6587\uff08\u65b0\u52a0\u5761\uff09",B:"Chinese Simplified (Singapore)"},"zh-TW":{A:"\u4e2d\u6587\uff08\u53f0\u7063\uff09",B:"Chinese Traditional (Taiwan)"},"zu-ZA":{A:"isiZulu",B:"Zulu"}},NA=t(Object.keys(MA)),OA=NA.next();!OA.done;OA=
1304
+ NA.next()){var PA=OA.value;MA[PA.toLowerCase()]=MA[PA]};function QA(a,b){var c=this;this.parent=a;this.controls=b;this.eventManager=new Af;this.localization=this.controls.Ka;this.player=this.controls.Gc();this.video=this.controls.bc();this.adManager=this.player.Yd();this.ad=b.getAd();this.eventManager.o(this.adManager,"ad-started",function(d){c.ad=d.ad});this.eventManager.o(this.adManager,"ad-stopped",function(){c.ad=null})}
1305
+ QA.prototype.release=function(){this.eventManager.release();this.ad=this.adManager=this.video=this.player=this.localization=this.eventManager=this.controls=this.parent=null};M("shaka.ui.Element",QA);QA.prototype.release=QA.prototype.release;function RA(a){return SA(a,"shaka-back-to-overflow-button")}function SA(a,b){a=a.getElementsByClassName(b);return a.length?a[0]:null}function TA(a){a&&(a=SA(a,"shaka-chosen-item"))&&a.parentElement.focus()}function UA(){var a=U("i");a.classList.add("material-icons-round");a.classList.add("shaka-chosen-item");a.textContent="done";a.ariaHidden="true";return a}function VA(a,b){a&&(b?a.classList.remove("shaka-hidden"):a.classList.add("shaka-hidden"))}
1306
+ function WA(a,b){var c=Math.floor(a/3600),d=Math.floor(a/60%60);a=Math.floor(a%60);10>a&&(a="0"+a);a=d+":"+a;b&&(10>d&&(a="0"+a),a=c+":"+a);return a};function XA(a,b){QA.call(this,a,b);var c=this;this.i=U("div");this.i.classList.add("shaka-ad-counter");this.parent.appendChild(this.i);this.h=U("span");this.h.classList.add("shaka-ad-counter-span");this.i.appendChild(this.h);this.g=new vd(function(){var d=Math.round(c.ad.getRemainingTime()),e=c.ad.getDuration();-1!=d&&-1!=e&&(0<d?(d=WA(e-d,!1)+" / "+WA(e,!1),1<c.ad.getSequenceLength()?c.h.textContent=d:(e=c.localization.resolve("AD_TIME"),c.h.textContent=e.replace("[AD_TIME]",d))):(c.g.stop(),c.h.textContent=
1307
+ ""))});this.eventManager.o(this.localization,"locale-updated",function(){});this.eventManager.o(this.localization,"locale-changed",function(){});this.eventManager.o(this.adManager,"ad-started",function(){c.g.Pa();c.g.ya(.5)});this.eventManager.o(this.adManager,"ad-stopped",function(){c.g.stop();c.h.textContent=""});this.ad&&(this.g.Pa(),this.g.ya(.5))}pa(XA,QA);XA.prototype.release=function(){this.g.stop();this.g=null;QA.prototype.release.call(this)};M("shaka.ui.AdCounter",XA);function YA(a,b){QA.call(this,a,b);var c=this;this.g=U("div");this.g.classList.add("shaka-ad-position");VA(this.g,!1);this.parent.appendChild(this.g);this.h=U("span");this.h.classList.add("shaka-ad-position-span");this.g.appendChild(this.h);this.eventManager.o(this.localization,"locale-updated",function(){c.ad&&ZA(c)});this.eventManager.o(this.localization,"locale-changed",function(){c.ad&&ZA(c)});this.eventManager.o(this.adManager,"ad-started",function(){ZA(c)});this.eventManager.o(this.adManager,
1308
+ "ad-stopped",function(){c.h.textContent="";VA(c.g,!1)});this.ad&&ZA(this)}pa(YA,QA);function ZA(a){var b=a.ad.getSequenceLength();if(1<b){var c=a.ad.getPositionInSequence();a.h.textContent=a.localization.resolve("AD_PROGRESS").replace("[AD_ON]",String(c)).replace("[NUM_ADS]",String(b));VA(a.g,!0)}}M("shaka.ui.AdPosition",YA);function $A(a,b){QA.call(this,a,b);var c=this;this.button=Vk();this.parent.appendChild(this.button);this.eventManager.o(this.localization,"locale-updated",function(){c.g()});this.eventManager.o(this.localization,"locale-changed",function(){c.g()});this.eventManager.o(this.video,"play",function(){c.g();c.h()});this.eventManager.o(this.video,"pause",function(){c.g();c.h()});this.eventManager.o(this.video,"seeking",function(){c.g();c.h()});this.eventManager.o(this.adManager,"ad-paused",function(){c.g();
1309
+ c.h()});this.eventManager.o(this.adManager,"ad-resumed",function(){c.g();c.h()});this.eventManager.o(this.adManager,"ad-started",function(){c.g();c.h()});this.eventManager.o(this.adManager,"ad-stopped",function(){c.g();c.h()});this.eventManager.o(this.button,"click",function(){c.ad&&c.ad.isLinear()?aB(c.controls):bB(c.controls)});this.ad&&(this.g(),this.h())}pa($A,QA);$A.prototype.isPaused=function(){if(this.ad&&this.ad.isLinear())var a=this.ad.isPaused();else a=this.controls,a=a.u.paused&&!a.V;return a};
1310
+ $A.prototype.isEnded=function(){return this.ad&&this.ad.isLinear()?!1:this.video.ended};$A.prototype.g=function(){};$A.prototype.h=function(){};M("shaka.ui.PlayButton",$A);function cB(a,b){$A.call(this,a,b);this.button.classList.add("shaka-play-button");this.button.classList.add("shaka-no-propagation");this.h();this.g()}pa(cB,$A);cB.prototype.h=function(){this.isPaused()?this.button.setAttribute("icon","play"):this.button.setAttribute("icon","pause")};cB.prototype.g=function(){var a=this.isPaused()?"PLAY":"PAUSE";this.button.ariaLabel=this.localization.resolve(a)};M("shaka.ui.BigPlayButton",cB);function dB(a,b){QA.call(this,a,b);var c=this;this.j=this.controls.g;this.h=this.controls.h;this.i=[];this.g=U("div");this.g.classList.add("shaka-no-propagation");this.g.classList.add("shaka-context-menu");this.g.classList.add("shaka-hidden");this.h.appendChild(this.g);this.eventManager.o(this.h,"contextmenu",function(d){if(c.g.classList.contains("shaka-hidden")){d.preventDefault();var e=c.h.getBoundingClientRect();c.g.style.left=d.clientX-e.left+"px";c.g.style.top=d.clientY-e.top+"px";VA(c.g,!0)}else VA(c.g,
1311
+ !1)});this.eventManager.o(window,"click",function(){VA(c.g,!1)});eB(this)}pa(dB,QA);dB.prototype.release=function(){this.h=null;for(var a=t(this.i),b=a.next();!b.done;b=a.next())b.value.release();this.i=[];QA.prototype.release.call(this)};function fB(a,b){gB.set(a,b)}function eB(a){for(var b=t(a.j.contextMenuElements),c=b.next();!c.done;c=b.next()){c=c.value;var d=gB.get(c);d?a.i.push(d.create(a.g,a.controls)):Sa("Unrecognized context menu element:",c)}}M("shaka.ui.ContextMenu",dB);
1312
+ dB.registerElement=fB;var gB=new Map;function hB(a,b,c,d){QA.call(this,a,b);var e=this;this.container=U("div");this.container.classList.add("shaka-range-container");this.container.classList.add.apply(this.container.classList,w(c));this.h=!1;this.bar=document.createElement("input");this.G=new vd(function(){e.onChangeEnd();e.h=!1});this.bar.classList.add("shaka-range-element");this.bar.classList.add.apply(this.bar.classList,w(d));this.bar.type="range";this.bar.step="any";this.bar.min="0";this.bar.max="1";this.bar.value="0";this.container.appendChild(this.bar);
1313
+ this.parent.appendChild(this.container);this.eventManager.o(this.bar,"mousedown",function(){e.controls.qc()&&(e.h=!0,e.onChangeStart())});this.eventManager.o(this.bar,"touchstart",function(f){e.controls.qc()&&(e.h=!0,iB(e,f),e.onChangeStart())});this.eventManager.o(this.bar,"input",function(){e.onChange()});this.eventManager.o(this.bar,"touchmove",function(f){e.h&&(iB(e,f),e.onChange())});this.eventManager.o(this.bar,"touchend",function(f){e.h&&(e.h=!1,iB(e,f),e.onChangeEnd())});this.eventManager.o(this.bar,
1314
+ "touchcancel",function(f){e.h&&(e.h=!1,iB(e,f),e.onChangeEnd())});this.eventManager.o(this.bar,"mouseup",function(){e.h&&(e.h=!1,e.onChangeEnd())});this.eventManager.o(this.bar,"blur",function(){e.h&&(e.h=!1,e.onChangeEnd())});this.eventManager.o(this.bar,"contextmenu",function(f){f.preventDefault();f.stopPropagation()})}pa(hB,QA);p=hB.prototype;p.release=function(){this.G&&(this.G.stop(),this.G=null);QA.prototype.release.call(this)};p.setRange=function(a,b){this.bar.min=a;this.bar.max=b};
1316
1315
  p.onChangeStart=function(){};p.onChange=function(){};p.onChangeEnd=function(){};p.changeTo=function(a){this.h||(this.h=!0,this.onChangeStart());var b=parseFloat(this.bar.min),c=parseFloat(this.bar.max);this.bar.value=a>c?c:a<b?b:a;this.onChange();this.G.T(.5)};p.getValue=function(){return parseFloat(this.bar.value)};p.setValue=function(a){this.h||(this.bar.value=a)};
1317
- function jB(a,b){b.preventDefault();var c=b.changedTouches[0],d=a.bar.getBoundingClientRect();b=parseFloat(a.bar.min);var e=parseFloat(a.bar.max);c=b+(e-b)/d.width*(c.clientX-d.left);c<b?c=b:c>e&&(c=e);a.bar.value=c}M("shaka.ui.RangeElement",iB);iB.prototype.setValue=iB.prototype.setValue;iB.prototype.getValue=iB.prototype.getValue;iB.prototype.changeTo=iB.prototype.changeTo;iB.prototype.onChangeEnd=iB.prototype.onChangeEnd;iB.prototype.onChange=iB.prototype.onChange;iB.prototype.onChangeStart=iB.prototype.onChangeStart;
1318
- iB.prototype.setRange=iB.prototype.setRange;function kB(a,b){iB.call(this,a,b,["shaka-seek-bar-container"],["shaka-seek-bar","shaka-no-propagation","shaka-show-controls-on-mouse-over"]);var c=this;this.D=U("div");this.D.classList.add("shaka-ad-markers");this.container.insertBefore(this.D,this.container.childNodes[0]);this.H=this.controls.g;this.s=new vd(function(){var d=c.getValue();c.player.R()||d==c.video.duration&&(d-=.001);c.video.currentTime=d});this.I=new vd(function(){lB(c)});this.K=!1;this.i=U("div");this.i.id="shaka-player-ui-thumbnail-container";
1319
- this.g=U("img");this.g.id="shaka-player-ui-thumbnail-image";this.g.draggable=!1;this.u=U("div");this.u.id="shaka-player-ui-thumbnail-time";this.i.appendChild(this.g);this.i.appendChild(this.u);this.container.appendChild(this.i);this.j=this.l=null;this.J=!1;this.m=new vd(function(){mB(c)});this.C=[];this.eventManager.o(this.localization,"locale-updated",function(){return nB(c)});this.eventManager.o(this.localization,"locale-changed",function(){return nB(c)});this.eventManager.o(this.adManager,"ad-started",
1320
- function(){oB(c)||WA(c.container,!1)});this.eventManager.o(this.adManager,"ad-stopped",function(){oB(c)&&WA(c.container,!0)});this.eventManager.o(this.adManager,"ad-cue-points-changed",function(d){c.C=d.cuepoints;pB(c)});this.eventManager.o(this.player,"unloading",function(){c.C=[];pB(c);c.j&&(c.j.abort(),c.j=null);c.l=null;mB(c)});this.eventManager.o(this.bar,"mousemove",function(d){if(c.player.Zd().length){var e=c.bar.getBoundingClientRect(),f=parseFloat(c.bar.min);d=d.clientX-e.left;qB(c,d,Math.round(f+
1321
- (parseFloat(c.bar.max)-f)/e.width*d))}else mB(c)});this.eventManager.o(this.container,"mouseleave",function(){c.m.stop();c.m.T(.25)});this.setValue(this.video.currentTime);this.update();nB(this);this.ad&&WA(this.container,!1)}pa(kB,iB);p=kB.prototype;p.release=function(){this.s&&(this.s.stop(),this.s=null,this.I.stop(),this.I=null);iB.prototype.release.call(this)};p.onChangeStart=function(){this.K=!this.video.paused;this.controls.kg(!0);this.video.pause();this.m.stop();this.J=!0};
1322
- p.onChange=function(){if(this.video.duration)if(this.update(),this.s.T(.125),this.player.Zd().length){var a=parseFloat(this.bar.min),b=parseFloat(this.bar.max),c=this.bar.getBoundingClientRect(),d=Math.round(this.getValue());qB(this,(d-a)/((b-a)/c.width),d)}else mB(this)};p.onChangeEnd=function(){this.s.Pa();this.controls.kg(!1);this.K&&this.video.play();this.J&&(this.J=!1,this.m.stop(),this.m.T(.25))};p.isShowing=function(){return!this.container.classList.contains("shaka-hidden")};
1323
- p.update=function(){var a=this.H.seekBarColors,b=this.getValue(),c=this.video.buffered.length,d=c?this.video.buffered.start(0):0,e=c?this.video.buffered.end(c-1):0,f=this.player.Fa(),g=f.end-f.start;this.setRange(f.start,f.end);oB(this)?(WA(this.container,!0),0==c?this.container.style.background=a.base:(c=(Math.max(d,f.start)-f.start)/g||0,e=(Math.min(e,f.end)-f.start)/g||0,b=(Math.min(Math.max(b,f.start),f.end)-f.start)/g||0,this.container.style.background="linear-gradient("+["to right",(this.H.showUnbufferedStart?
1324
- a.base:a.played)+" "+100*c+"%",a.played+" "+100*c+"%",a.played+" "+100*b+"%",a.buffered+" "+100*b+"%",a.buffered+" "+100*e+"%",a.base+" "+100*e+"%"].join()+")")):WA(this.container,!1)};
1325
- function lB(a){if(a.C.length){for(var b=a.player.Fa(),c=b.end-b.start,d=["to right"],e=[],f=a.H.seekBarColors.adBreaks,g=!1,h=t(a.C),k=h.next();!k.done;k=h.next())if(k=k.value,-1!=k.start||k.end||(g=!0),k.start>=b.start&&k.start<b.end&&!(k.end&&k.end>b.end)){var l=(k.start-b.start)/c||0,m=l+.01;k.end&&(m=(k.end-b.start)/c||0);e.push({start:l,end:m})}b=t(e);for(k=b.next();!k.done;k=b.next())c=k.value,d.push("transparent "+100*c.start+"%"),d.push(f+" "+100*c.start+"%"),d.push(f+" "+100*c.end+"%"),d.push("transparent "+
1326
- 100*c.end+"%");g&&(d.push("transparent 99%"),d.push(f+" 99%"));a.D.style.background="linear-gradient("+d.join(",")+")"}else a.D.style.background="transparent"}function pB(a){lB(a);var b=a.player.Fa();b=b.end-b.start;a.player.R()&&5<b&&a.I.ya(1)}function oB(a){var b=a.player.Fa();b=b.end-b.start;return a.player.R()&&5>b?!1:null==a.ad||!a.ad.isLinear()}function nB(a){a.bar.ariaLabel=a.localization.resolve("SEEK")}
1327
- function qB(a,b,c){var d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B;K(function(C){switch(C.g){case 1:d=rB(a);if(!d)return mB(a),C.return();0>c&&(c=0);e=a.player.Fa();f=Math.max(Math.ceil(e.start),Math.min(Math.floor(e.end),c));return D(C,a.player.Cf(d.id,f),2);case 2:g=C.h;if(!g||!g.uris.length)return mB(a),C.return();a.player.R()?(h=e.end-c,a.u.textContent=1>h?a.localization.resolve("LIVE"):"-"+sB(h)):a.u.textContent=sB(c);k=-10;l=a.i.clientWidth;m=Math.floor(9*l/16);a.i.style.height=m+"px";a.i.style.top=
1328
- -(m-k)+"px";n=Math.min(a.bar.offsetWidth-l,Math.max(0,b-l/2));a.i.style.left=n+"px";a.i.style.visibility="visible";q=g.uris[0].split("#xywh=")[0];if(a.l&&q===a.l.uris[0].split("#xywh=")[0]&&g.segment.Zb()==a.l.segment.Zb()&&g.segment.Wb()==a.l.segment.Wb()){C.F(3);break}a.l=g;a.j&&(a.j.abort(),a.j=null);if("mjpg"!=d.codecs&&!q.startsWith("offline:")){C.F(4);break}a.g.src='data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg"/>';ta(C,5);r=wf;u=fk(g.segment.aa(),g.segment.Zb(),g.segment.Wb(),a.player.getConfiguration().streaming.retryParameters);
1329
- a.j=a.player.Xb().request(r,u,{type:1});return D(C,a.j.promise,7);case 7:v=C.h;a.j=null;"mjpg"==d.codecs?(y=(new Tf).box("mdat",bg(function(E){q=URL.createObjectURL(new Blob([E],{type:"image/jpeg"}))})),y.parse(v.data,!1)):(z=d.mimeType||"image/jpeg",x=new Blob([v.data],{type:z}),q=URL.createObjectURL(x));va(C,4);break;case 5:A=wa(C);if(7001==A.code)return C.return();throw A;case 4:try{a.i.removeChild(a.g)}catch(E){}a.g=U("img");a.g.id="shaka-player-ui-thumbnail-image";a.g.draggable=!1;a.g.src=q;
1316
+ function iB(a,b){b.preventDefault();var c=b.changedTouches[0],d=a.bar.getBoundingClientRect();b=parseFloat(a.bar.min);var e=parseFloat(a.bar.max);c=b+(e-b)/d.width*(c.clientX-d.left);c<b?c=b:c>e&&(c=e);a.bar.value=c}M("shaka.ui.RangeElement",hB);hB.prototype.setValue=hB.prototype.setValue;hB.prototype.getValue=hB.prototype.getValue;hB.prototype.changeTo=hB.prototype.changeTo;hB.prototype.onChangeEnd=hB.prototype.onChangeEnd;hB.prototype.onChange=hB.prototype.onChange;hB.prototype.onChangeStart=hB.prototype.onChangeStart;
1317
+ hB.prototype.setRange=hB.prototype.setRange;function jB(a,b){hB.call(this,a,b,["shaka-seek-bar-container"],["shaka-seek-bar","shaka-no-propagation","shaka-show-controls-on-mouse-over"]);var c=this;this.D=U("div");this.D.classList.add("shaka-ad-markers");this.container.insertBefore(this.D,this.container.childNodes[0]);this.H=this.controls.g;this.s=new vd(function(){var d=c.getValue();c.player.R()||d==c.video.duration&&(d-=.001);c.video.currentTime=d});this.I=new vd(function(){kB(c)});this.K=!1;this.i=U("div");this.i.id="shaka-player-ui-thumbnail-container";
1318
+ this.g=U("img");this.g.id="shaka-player-ui-thumbnail-image";this.g.draggable=!1;this.u=U("div");this.u.id="shaka-player-ui-thumbnail-time";this.i.appendChild(this.g);this.i.appendChild(this.u);this.container.appendChild(this.i);this.j=this.l=null;this.J=!1;this.m=new vd(function(){lB(c)});this.C=[];this.eventManager.o(this.localization,"locale-updated",function(){return mB(c)});this.eventManager.o(this.localization,"locale-changed",function(){return mB(c)});this.eventManager.o(this.adManager,"ad-started",
1319
+ function(){nB(c)||VA(c.container,!1)});this.eventManager.o(this.adManager,"ad-stopped",function(){nB(c)&&VA(c.container,!0)});this.eventManager.o(this.adManager,"ad-cue-points-changed",function(d){c.C=d.cuepoints;oB(c)});this.eventManager.o(this.player,"unloading",function(){c.C=[];oB(c);c.j&&(c.j.abort(),c.j=null);c.l=null;lB(c)});this.eventManager.o(this.bar,"mousemove",function(d){if(c.player.Zd().length){var e=c.bar.getBoundingClientRect(),f=parseFloat(c.bar.min);d=d.clientX-e.left;pB(c,d,Math.round(f+
1320
+ (parseFloat(c.bar.max)-f)/e.width*d))}else lB(c)});this.eventManager.o(this.container,"mouseleave",function(){c.m.stop();c.m.T(.25)});this.setValue(this.video.currentTime);this.update();mB(this);this.ad&&VA(this.container,!1)}pa(jB,hB);p=jB.prototype;p.release=function(){this.s&&(this.s.stop(),this.s=null,this.I.stop(),this.I=null);hB.prototype.release.call(this)};p.onChangeStart=function(){this.K=!this.video.paused;this.controls.kg(!0);this.video.pause();this.m.stop();this.J=!0};
1321
+ p.onChange=function(){if(this.video.duration)if(this.update(),this.s.T(.125),this.player.Zd().length){var a=parseFloat(this.bar.min),b=parseFloat(this.bar.max),c=this.bar.getBoundingClientRect(),d=Math.round(this.getValue());pB(this,(d-a)/((b-a)/c.width),d)}else lB(this)};p.onChangeEnd=function(){this.s.Pa();this.controls.kg(!1);this.K&&this.video.play();this.J&&(this.J=!1,this.m.stop(),this.m.T(.25))};p.isShowing=function(){return!this.container.classList.contains("shaka-hidden")};
1322
+ p.update=function(){var a=this.H.seekBarColors,b=this.getValue(),c=this.video.buffered.length,d=c?this.video.buffered.start(0):0,e=c?this.video.buffered.end(c-1):0,f=this.player.Fa(),g=f.end-f.start;this.setRange(f.start,f.end);nB(this)?(VA(this.container,!0),0==c?this.container.style.background=a.base:(c=(Math.max(d,f.start)-f.start)/g||0,e=(Math.min(e,f.end)-f.start)/g||0,b=(Math.min(Math.max(b,f.start),f.end)-f.start)/g||0,this.container.style.background="linear-gradient("+["to right",(this.H.showUnbufferedStart?
1323
+ a.base:a.played)+" "+100*c+"%",a.played+" "+100*c+"%",a.played+" "+100*b+"%",a.buffered+" "+100*b+"%",a.buffered+" "+100*e+"%",a.base+" "+100*e+"%"].join()+")")):VA(this.container,!1)};
1324
+ function kB(a){if(a.C.length){for(var b=a.player.Fa(),c=b.end-b.start,d=["to right"],e=[],f=a.H.seekBarColors.adBreaks,g=!1,h=t(a.C),k=h.next();!k.done;k=h.next())if(k=k.value,-1!=k.start||k.end||(g=!0),k.start>=b.start&&k.start<b.end&&!(k.end&&k.end>b.end)){var l=(k.start-b.start)/c||0,m=l+.01;k.end&&(m=(k.end-b.start)/c||0);e.push({start:l,end:m})}b=t(e);for(k=b.next();!k.done;k=b.next())c=k.value,d.push("transparent "+100*c.start+"%"),d.push(f+" "+100*c.start+"%"),d.push(f+" "+100*c.end+"%"),d.push("transparent "+
1325
+ 100*c.end+"%");g&&(d.push("transparent 99%"),d.push(f+" 99%"));a.D.style.background="linear-gradient("+d.join(",")+")"}else a.D.style.background="transparent"}function oB(a){kB(a);var b=a.player.Fa();b=b.end-b.start;a.player.R()&&5<b&&a.I.ya(1)}function nB(a){var b=a.player.Fa();b=b.end-b.start;return a.player.R()&&5>b?!1:null==a.ad||!a.ad.isLinear()}function mB(a){a.bar.ariaLabel=a.localization.resolve("SEEK")}
1326
+ function pB(a,b,c){var d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B;K(function(C){switch(C.g){case 1:d=qB(a);if(!d)return lB(a),C.return();0>c&&(c=0);e=a.player.Fa();f=Math.max(Math.ceil(e.start),Math.min(Math.floor(e.end),c));return D(C,a.player.Cf(d.id,f),2);case 2:g=C.h;if(!g||!g.uris.length)return lB(a),C.return();a.player.R()?(h=e.end-c,a.u.textContent=1>h?a.localization.resolve("LIVE"):"-"+rB(h)):a.u.textContent=rB(c);k=-10;l=a.i.clientWidth;m=Math.floor(9*l/16);a.i.style.height=m+"px";a.i.style.top=
1327
+ -(m-k)+"px";n=Math.min(a.bar.offsetWidth-l,Math.max(0,b-l/2));a.i.style.left=n+"px";a.i.style.visibility="visible";q=g.uris[0].split("#xywh=")[0];if(a.l&&q===a.l.uris[0].split("#xywh=")[0]&&g.segment.Nb()==a.l.segment.Nb()&&g.segment.Kb()==a.l.segment.Kb()){C.F(3);break}a.l=g;a.j&&(a.j.abort(),a.j=null);if("mjpg"!=d.codecs&&!q.startsWith("offline:")){C.F(4);break}a.g.src='data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg"/>';ta(C,5);r=wf;u=fk(g.segment.aa(),g.segment.Nb(),g.segment.Kb(),a.player.getConfiguration().streaming.retryParameters);
1328
+ a.j=a.player.Yb().request(r,u,{type:1});return D(C,a.j.promise,7);case 7:v=C.h;a.j=null;"mjpg"==d.codecs?(y=(new Tf).box("mdat",bg(function(E){q=URL.createObjectURL(new Blob([E],{type:"image/jpeg"}))})),y.parse(v.data,!1)):(z=d.mimeType||"image/jpeg",x=new Blob([v.data],{type:z}),q=URL.createObjectURL(x));va(C,4);break;case 5:A=wa(C);if(7001==A.code)return C.return();throw A;case 4:try{a.i.removeChild(a.g)}catch(E){}a.g=U("img");a.g.id="shaka-player-ui-thumbnail-image";a.g.draggable=!1;a.g.src=q;
1330
1329
  a.g.onload=function(){q.startsWith("blob:")&&URL.revokeObjectURL(q)};a.i.insertBefore(a.g,a.i.firstChild);case 3:B=l/g.width,g.imageHeight?a.g.height=g.imageHeight:g.sprite||(a.g.style.height="100%",a.g.style.objectFit="contain"),g.imageWidth?a.g.width=g.imageWidth:g.sprite||(a.g.style.width="100%",a.g.style.objectFit="contain"),a.g.style.left="-"+B*g.positionX+"px",a.g.style.top="-"+B*g.positionY+"px",a.g.style.transform="scale("+B+")",a.g.style.transformOrigin="left top",m=Math.floor(l*g.height/
1331
1330
  g.width),a.i.style.height=m+"px",a.i.style.top=-(m-k)+"px",F(C)}})}
1332
- function rB(a){var b=a.player.Zd();if(!b.length)return null;for(var c={},d=t(["image/avif","image/webp","image/jpeg","image/png","image/svg+xml"]),e=d.next();!e.done;c={Oe:c.Oe,Me:c.Me},e=d.next())if(c.Oe=e.value,c.Me=a.player.getStats().estimatedBandwidth,(e=b.filter(function(f){return function(g){return g.mimeType.toLowerCase()===f.Oe&&g.bandwidth<.01*f.Me}}(c)).sort(function(f,g){return g.bandwidth-f.bandwidth}))&&e.length)return e[0];return b.find(function(f){return"application/mp4"==f.mimeType&&
1333
- "mjpg"==f.codecs})||b[0]}function mB(a){a.i.style.visibility="hidden";a.u.textContent=""}function sB(a){var b=Math.round(a);a=Math.floor(b/3600);var c=Math.floor((b-3600*a)/60);b=b-3600*a-60*c;10>b&&(b="0"+b);return 0<a?(10>c&&(c="0"+c),a+":"+c+":"+b):c+":"+b}M("shaka.ui.SeekBar",kB);function tB(){}tB.prototype.create=function(a,b){return new kB(a,b)};kB.Factory=tB;function Y(a,b,c,d){ab.call(this);var e=this;this.P=!0;this.g=d;this.C=new Ao(c,a,this.g.castReceiverAppId,this.g.castAndroidReceiverCompatible);this.sa=!0;this.u=this.C.ac();this.s=c;this.D=this.C.Gc();this.ra=a;this.j=b;this.Va=this.D.Yd();this.l=this.m=null;this.V=!1;this.G=[];this.Ub=[];this.Gb=!1;this.Z=new vd(function(){e.j.style.cursor="none";e.Gb=!1;uB(e)});this.ea=new vd(function(){e.h.removeAttribute("shown");e.I.T(2)});this.I=new vd(function(){for(var f=t(e.G),g=f.next();!g.done;g=f.next())WA(g.value,
1334
- !1)});this.Qa=new vd(function(){e.qc()&&vB(e)});this.J=null;this.H=[];this.Ka=wB();this.i=new Af;this.configure(this.g);xB(this);this.ha=new Set;yB(this);this.Qa.ya(.125);this.i.o(this.Ka,"locale-changed",function(f){e.Va.setLocale(f.locales[0])})}pa(Y,ab);p=Y.prototype;
1335
- p.destroy=function(){var a=this;return K(function(b){switch(b.g){case 1:if(document.pictureInPictureElement!=a.s){b.F(2);break}return D(b,document.exitPictureInPicture(),2);case 2:a.i&&(a.i.release(),a.i=null);a.Z&&(a.Z.stop(),a.Z=null);a.ea&&(a.ea.stop(),a.ea=null);a.I&&(a.I.stop(),a.I=null);a.Qa&&(a.Qa.stop(),a.Qa=null);zB(a);a.h&&(a.j.removeChild(a.h),a.h=null);if(!a.C){b.F(4);break}return D(b,a.C.destroy(),5);case 5:a.C=null;case 4:if(!a.ra){b.F(6);break}return D(b,a.ra.destroy(),7);case 7:a.ra=
1336
- null;case 6:a.D=null,a.s=null,a.u=null,a.Ka=null,a.ha.clear(),ab.prototype.release.call(a),F(b)}})};function zB(a){for(var b=t(a.H),c=b.next();!c.done;c=b.next())c.value.release();a.H=[]}function AB(a,b){BB.set(a,b)}p.yh=function(a){this.sa=a;yB(this)};p.Fi=function(){uB(this)};
1337
- p.configure=function(a){this.g=a;this.C.Cg(a.castReceiverAppId,a.castAndroidReceiverCompatible);this.l&&(this.l=null);this.Db&&(this.Db=null);this.Xa&&(this.Xa=null);this.h?(Wk(this.h),zB(this)):(CB(this),DB(this));this.j.classList.add("shaka-video-container");this.s.classList.add("shaka-video");EB(this);this.g.addBigPlayButton&&FB(this);this.g.customContextMenu&&(this.Xa=new eB(this.U,this),this.H.push(this.Xa));this.$||GB(this);this.Fb=U("div");this.Fb.classList.add("shaka-server-side-ad-container");
1338
- this.h.appendChild(this.Fb);HB(this);this.G=Array.from(this.j.getElementsByClassName("shaka-settings-menu"));this.G.push.apply(this.G,w(Array.from(this.j.getElementsByClassName("shaka-overflow-menu"))));IB(this);this.Ub=Array.from(this.j.getElementsByClassName("shaka-show-controls-on-mouse-over"));uB(this);a=t(this.j.getElementsByClassName("shaka-no-propagation"));for(var b=a.next();!b.done;b=a.next()){b=b.value;var c=function(d){return d.stopPropagation()};this.i.o(b,"click",c);this.i.o(b,"dblclick",
1339
- c)}};p.fg=function(a){(this.P=a)?(this.j.setAttribute("shaka-controls","true"),this.s.tabIndex=-1,this.s.controls=!1):this.j.removeAttribute("shaka-controls");uB(this)};p.gh=function(a){this.s.controls=a;this.s.tabIndex=a?0:-1;a&&this.fg(!1)};p.getAd=function(){return this.m};p.Lh=function(){return this.C};p.Yh=function(){return this.Ka};p.ni=function(){return this.j};p.ac=function(){return this.u};p.Xh=function(){return this.s};p.Gc=function(){return this.D};p.Wh=function(){return this.ra};
1331
+ function qB(a){var b=a.player.Zd();if(!b.length)return null;for(var c={},d=t(["image/avif","image/webp","image/jpeg","image/png","image/svg+xml"]),e=d.next();!e.done;c={Oe:c.Oe,Me:c.Me},e=d.next())if(c.Oe=e.value,c.Me=a.player.getStats().estimatedBandwidth,(e=b.filter(function(f){return function(g){return g.mimeType.toLowerCase()===f.Oe&&g.bandwidth<.01*f.Me}}(c)).sort(function(f,g){return g.bandwidth-f.bandwidth}))&&e.length)return e[0];return b.find(function(f){return"application/mp4"==f.mimeType&&
1332
+ "mjpg"==f.codecs})||b[0]}function lB(a){a.i.style.visibility="hidden";a.u.textContent=""}function rB(a){var b=Math.round(a);a=Math.floor(b/3600);var c=Math.floor((b-3600*a)/60);b=b-3600*a-60*c;10>b&&(b="0"+b);return 0<a?(10>c&&(c="0"+c),a+":"+c+":"+b):c+":"+b}M("shaka.ui.SeekBar",jB);function sB(){}sB.prototype.create=function(a,b){return new jB(a,b)};jB.Factory=sB;function Y(a,b,c,d){ab.call(this);var e=this;this.P=!0;this.g=d;this.C=new Ao(c,a,this.g.castReceiverAppId,this.g.castAndroidReceiverCompatible);this.sa=!0;this.u=this.C.bc();this.s=c;this.D=this.C.Gc();this.ra=a;this.j=b;this.Va=this.D.Yd();this.l=this.m=null;this.V=!1;this.G=[];this.Wb=[];this.Gb=!1;this.Z=new vd(function(){e.j.style.cursor="none";e.Gb=!1;tB(e)});this.ea=new vd(function(){e.h.removeAttribute("shown");e.I.T(2)});this.I=new vd(function(){for(var f=t(e.G),g=f.next();!g.done;g=f.next())VA(g.value,
1333
+ !1)});this.Qa=new vd(function(){e.qc()&&uB(e)});this.J=null;this.H=[];this.Ka=vB();this.i=new Af;this.configure(this.g);wB(this);this.ha=new Set;xB(this);this.Qa.ya(.125);this.i.o(this.Ka,"locale-changed",function(f){e.Va.setLocale(f.locales[0])})}pa(Y,ab);p=Y.prototype;
1334
+ p.destroy=function(){var a=this;return K(function(b){switch(b.g){case 1:if(document.pictureInPictureElement!=a.s){b.F(2);break}return D(b,document.exitPictureInPicture(),2);case 2:a.i&&(a.i.release(),a.i=null);a.Z&&(a.Z.stop(),a.Z=null);a.ea&&(a.ea.stop(),a.ea=null);a.I&&(a.I.stop(),a.I=null);a.Qa&&(a.Qa.stop(),a.Qa=null);yB(a);a.h&&(a.j.removeChild(a.h),a.h=null);if(!a.C){b.F(4);break}return D(b,a.C.destroy(),5);case 5:a.C=null;case 4:if(!a.ra){b.F(6);break}return D(b,a.ra.destroy(),7);case 7:a.ra=
1335
+ null;case 6:a.D=null,a.s=null,a.u=null,a.Ka=null,a.ha.clear(),ab.prototype.release.call(a),F(b)}})};function yB(a){for(var b=t(a.H),c=b.next();!c.done;c=b.next())c.value.release();a.H=[]}function zB(a,b){AB.set(a,b)}p.yh=function(a){this.sa=a;xB(this)};p.Fi=function(){tB(this)};
1336
+ p.configure=function(a){this.g=a;this.C.Cg(a.castReceiverAppId,a.castAndroidReceiverCompatible);this.l&&(this.l=null);this.Db&&(this.Db=null);this.Xa&&(this.Xa=null);this.h?(Wk(this.h),yB(this)):(BB(this),CB(this));this.j.classList.add("shaka-video-container");this.s.classList.add("shaka-video");DB(this);this.g.addBigPlayButton&&EB(this);this.g.customContextMenu&&(this.Xa=new dB(this.U,this),this.H.push(this.Xa));this.$||FB(this);this.Fb=U("div");this.Fb.classList.add("shaka-server-side-ad-container");
1337
+ this.h.appendChild(this.Fb);GB(this);this.G=Array.from(this.j.getElementsByClassName("shaka-settings-menu"));this.G.push.apply(this.G,w(Array.from(this.j.getElementsByClassName("shaka-overflow-menu"))));HB(this);this.Wb=Array.from(this.j.getElementsByClassName("shaka-show-controls-on-mouse-over"));tB(this);a=t(this.j.getElementsByClassName("shaka-no-propagation"));for(var b=a.next();!b.done;b=a.next()){b=b.value;var c=function(d){return d.stopPropagation()};this.i.o(b,"click",c);this.i.o(b,"dblclick",
1338
+ c)}};p.fg=function(a){(this.P=a)?(this.j.setAttribute("shaka-controls","true"),this.s.tabIndex=-1,this.s.controls=!1):this.j.removeAttribute("shaka-controls");tB(this)};p.gh=function(a){this.s.controls=a;this.s.tabIndex=a?0:-1;a&&this.fg(!1)};p.getAd=function(){return this.m};p.Lh=function(){return this.C};p.Yh=function(){return this.Ka};p.ni=function(){return this.j};p.bc=function(){return this.u};p.Xh=function(){return this.s};p.Gc=function(){return this.D};p.Wh=function(){return this.ra};
1340
1339
  p.Qh=function(){return this.h};p.ei=function(){return this.Fb};p.Nh=function(){return this.M};p.Oh=function(){return this.g};p.Ci=function(){return this.V};p.kg=function(a){this.V=a};p.ti=function(){return this.sa};p.Mg=function(){return this.l?this.l.getValue():this.u.currentTime};p.hh=function(a){this.J=a};p.Td=function(){return this.G.some(function(a){return!a.classList.contains("shaka-hidden")})};p.Jc=function(){this.I.Pa()};
1341
1340
  p.ke=function(){return document.fullscreenEnabled||this.s.webkitSupportsFullscreen?!0:!1};p.Lc=function(){if(document.fullscreenEnabled)return!!document.fullscreenElement;var a=this.s;return a.webkitSupportsFullscreen?a.webkitDisplayingFullscreen:!1};
1342
- function JB(a){var b,c,d;return K(function(e){switch(e.g){case 1:ta(e,2);if(!document.fullscreenEnabled){b=a.s;b.webkitSupportsFullscreen&&b.webkitEnterFullscreen();e.F(4);break}if(!document.pictureInPictureElement){e.F(5);break}return D(e,document.exitPictureInPicture(),5);case 5:return c=a.g.fullScreenElement,D(e,c.requestFullscreen({navigationUI:"hide"}),7);case 7:if(!a.g.forceLandscapeOnFullscreen||!screen.orientation){e.F(4);break}ta(e,9);return D(e,screen.orientation.lock("landscape"),11);case 11:va(e,
1343
- 4,2);break;case 9:wa(e,2);case 4:va(e,0);break;case 2:d=wa(e),a.dispatchEvent(new O("error",(new Map).set("detail",d))),F(e)}})}function KB(a){var b;return K(function(c){if(!document.fullscreenEnabled)return b=a.s,b.webkitSupportsFullscreen&&b.webkitExitFullscreen(),c.F(0);screen.orientation&&screen.orientation.unlock();return D(c,document.exitFullscreen(),0)})}p.pg=function(){var a=this;return K(function(b){return a.Lc()?D(b,KB(a),0):D(b,JB(a),0)})};
1341
+ function IB(a){var b,c,d;return K(function(e){switch(e.g){case 1:ta(e,2);if(!document.fullscreenEnabled){b=a.s;b.webkitSupportsFullscreen&&b.webkitEnterFullscreen();e.F(4);break}if(!document.pictureInPictureElement){e.F(5);break}return D(e,document.exitPictureInPicture(),5);case 5:return c=a.g.fullScreenElement,D(e,c.requestFullscreen({navigationUI:"hide"}),7);case 7:if(!a.g.forceLandscapeOnFullscreen||!screen.orientation){e.F(4);break}ta(e,9);return D(e,screen.orientation.lock("landscape"),11);case 11:va(e,
1342
+ 4,2);break;case 9:wa(e,2);case 4:va(e,0);break;case 2:d=wa(e),a.dispatchEvent(new O("error",(new Map).set("detail",d))),F(e)}})}function JB(a){var b;return K(function(c){if(!document.fullscreenEnabled)return b=a.s,b.webkitSupportsFullscreen&&b.webkitExitFullscreen(),c.F(0);screen.orientation&&screen.orientation.unlock();return D(c,document.exitFullscreen(),0)})}p.pg=function(){var a=this;return K(function(b){return a.Lc()?D(b,JB(a),0):D(b,IB(a),0)})};
1344
1343
  p.Gf=function(){return this.C.Aa()?!1:"documentPictureInPicture"in window&&this.g.preferDocumentPictureInPicture||document.pictureInPictureEnabled?!this.s.disablePictureInPicture:!1};p.le=function(){return"documentPictureInPicture"in window&&this.g.preferDocumentPictureInPicture?!!window.documentPictureInPicture.window:!!document.pictureInPictureElement};
1345
- p.Ie=function(){var a=this,b,c;return K(function(d){if(1==d.g)return ta(d,2),"documentPictureInPicture"in window&&a.g.preferDocumentPictureInPicture?D(d,LB(a),5):document.pictureInPictureElement?D(d,document.exitPictureInPicture(),5):(document.fullscreenElement&&document.exitFullscreen(),b=a.s,D(d,b.requestPictureInPicture(),5));if(2!=d.g)return va(d,0);c=wa(d);a.dispatchEvent(new O("error",(new Map).set("detail",c)));F(d)})};
1346
- function LB(a){var b,c,d,e,f,g;return K(function(h){if(1==h.g){if(window.documentPictureInPicture.window)return window.documentPictureInPicture.window.close(),h.return();b=a.j;c=b.getBoundingClientRect();return D(h,window.documentPictureInPicture.requestWindow({width:c.width,height:c.height}),2)}d=h.h;MB(d);e=b.parentNode||document.body;f=a.j.cloneNode(!0);f.style.visibility="hidden";f.style.height=getComputedStyle(b).height;e.appendChild(f);g=document.createElement("style");g.append("[data-shaka-player-container] {\n width: 100% !important; max-height: 100%}");
1344
+ p.Ie=function(){var a=this,b,c;return K(function(d){if(1==d.g)return ta(d,2),"documentPictureInPicture"in window&&a.g.preferDocumentPictureInPicture?D(d,KB(a),5):document.pictureInPictureElement?D(d,document.exitPictureInPicture(),5):(document.fullscreenElement&&document.exitFullscreen(),b=a.s,D(d,b.requestPictureInPicture(),5));if(2!=d.g)return va(d,0);c=wa(d);a.dispatchEvent(new O("error",(new Map).set("detail",c)));F(d)})};
1345
+ function KB(a){var b,c,d,e,f,g;return K(function(h){if(1==h.g){if(window.documentPictureInPicture.window)return window.documentPictureInPicture.window.close(),h.return();b=a.j;c=b.getBoundingClientRect();return D(h,window.documentPictureInPicture.requestWindow({width:c.width,height:c.height}),2)}d=h.h;LB(d);e=b.parentNode||document.body;f=a.j.cloneNode(!0);f.style.visibility="hidden";f.style.height=getComputedStyle(b).height;e.appendChild(f);g=document.createElement("style");g.append("[data-shaka-player-container] {\n width: 100% !important; max-height: 100%}");
1347
1346
  d.document.head.append(g);d.document.body.append(b);a.i.ka(d,"pagehide",function(){f.replaceWith(b)});F(h)})}
1348
- function MB(a){var b=[].concat(w(document.styleSheets)).map(function(d){try{return[].concat(w(d.cssRules)).map(function(f){return f.cssText}).join("")}catch(f){var e=document.createElement("link");e.rel="stylesheet";e.type=d.type;e.media=d.media;e.href=d.href;a.document.head.appendChild(e)}return""}).filter(Boolean).join("\n"),c=document.createElement("style");c.textContent=b;a.document.head.appendChild(c)}p.kh=function(){WA(this.K,!0);WA(this.M,!0);this.h.setAttribute("ad-active","true")};
1349
- p.Og=function(){WA(this.K,!1);WA(this.M,!1);this.h.removeAttribute("ad-active")};function cB(a){a.P&&a.u.duration&&(a.D.kd(),a.u.paused&&!a.V?a.u.play():a.u.pause())}function bB(a){a.m&&a.m.isPaused()?a.m.play():a.m&&a.m.pause()}
1350
- function CB(a){a.h=U("div");a.h.classList.add("shaka-controls-container");a.j.appendChild(a.h);a.j.setAttribute("shaka-controls","true");a.i.o(a.h,"touchstart",function(b){a.u.duration&&(a.qc()?a.J=Date.now():(NB(a,b),b.cancelable&&b.preventDefault()))},{passive:!1});a.i.o(a.h,"click",function(){OB(a)});a.i.o(a.h,"dblclick",function(){a.g.doubleClickForFullscreen&&a.ke()&&a.pg()})}
1351
- function FB(a){var b=U("div");b.classList.add("shaka-play-button-container");a.h.appendChild(b);a.Db=new dB(b,a);a.H.push(a.Db)}function EB(a){var b=U("div");b.classList.add("shaka-scrim-container");a.h.appendChild(b)}function PB(a){a.K=U("div");a.K.classList.add("shaka-ad-controls");var b=null!=a.m&&a.m.isLinear();WA(a.K,b);a.L.appendChild(a.K);b=new ZA(a.K,a);a.H.push(b);b=new YA(a.K,a);a.H.push(b)}
1352
- function GB(a){a.$=U("div");a.$.classList.add("shaka-spinner-container");a.j.appendChild(a.$);var b=U("div");b.classList.add("shaka-spinner");a.$.appendChild(b);a=document.createElementNS("http://www.w3.org/2000/svg","svg");a.classList.add("shaka-spinner-svg");a.setAttribute("viewBox","0 0 30 30");b.appendChild(a);b=document.createElementNS("http://www.w3.org/2000/svg","circle");b.classList.add("shaka-spinner-path");b.setAttribute("cx","15");b.setAttribute("cy","15");b.setAttribute("r","14.5");b.setAttribute("fill",
1347
+ function LB(a){var b=[].concat(w(document.styleSheets)).map(function(d){try{return[].concat(w(d.cssRules)).map(function(f){return f.cssText}).join("")}catch(f){var e=document.createElement("link");e.rel="stylesheet";e.type=d.type;e.media=d.media;e.href=d.href;a.document.head.appendChild(e)}return""}).filter(Boolean).join("\n"),c=document.createElement("style");c.textContent=b;a.document.head.appendChild(c)}p.kh=function(){VA(this.K,!0);VA(this.M,!0);this.h.setAttribute("ad-active","true")};
1348
+ p.Og=function(){VA(this.K,!1);VA(this.M,!1);this.h.removeAttribute("ad-active")};function bB(a){a.P&&a.u.duration&&(a.D.kd(),a.u.paused&&!a.V?a.u.play():a.u.pause())}function aB(a){a.m&&a.m.isPaused()?a.m.play():a.m&&a.m.pause()}
1349
+ function BB(a){a.h=U("div");a.h.classList.add("shaka-controls-container");a.j.appendChild(a.h);a.j.setAttribute("shaka-controls","true");a.i.o(a.h,"touchstart",function(b){a.u.duration&&(a.qc()?a.J=Date.now():(MB(a,b),b.cancelable&&b.preventDefault()))},{passive:!1});a.i.o(a.h,"click",function(){NB(a)});a.i.o(a.h,"dblclick",function(){a.g.doubleClickForFullscreen&&a.ke()&&a.pg()})}
1350
+ function EB(a){var b=U("div");b.classList.add("shaka-play-button-container");a.h.appendChild(b);a.Db=new cB(b,a);a.H.push(a.Db)}function DB(a){var b=U("div");b.classList.add("shaka-scrim-container");a.h.appendChild(b)}function OB(a){a.K=U("div");a.K.classList.add("shaka-ad-controls");var b=null!=a.m&&a.m.isLinear();VA(a.K,b);a.L.appendChild(a.K);b=new YA(a.K,a);a.H.push(b);b=new XA(a.K,a);a.H.push(b)}
1351
+ function FB(a){a.$=U("div");a.$.classList.add("shaka-spinner-container");a.j.appendChild(a.$);var b=U("div");b.classList.add("shaka-spinner");a.$.appendChild(b);a=document.createElementNS("http://www.w3.org/2000/svg","svg");a.classList.add("shaka-spinner-svg");a.setAttribute("viewBox","0 0 30 30");b.appendChild(a);b=document.createElementNS("http://www.w3.org/2000/svg","circle");b.classList.add("shaka-spinner-path");b.setAttribute("cx","15");b.setAttribute("cy","15");b.setAttribute("r","14.5");b.setAttribute("fill",
1353
1352
  "none");b.setAttribute("stroke-width","1");b.setAttribute("stroke-miterlimit","10");a.appendChild(b)}
1354
- function HB(a){a.L=U("div");a.L.classList.add("shaka-bottom-controls");a.L.classList.add("shaka-no-propagation");a.h.appendChild(a.L);a.i.o(a.L,"click",function(d){d.target.closest(".shaka-overflow-button")||a.Jc()});PB(a);a.U=U("div");a.U.classList.add("shaka-controls-button-panel");a.U.classList.add("shaka-show-controls-on-mouse-over");a.g.enableTooltips&&a.U.classList.add("shaka-tooltips-on");a.L.appendChild(a.U);for(var b=t(a.g.controlPanelElements),c=b.next();!c.done;c=b.next())c=c.value,BB.get(c)?
1355
- (c=BB.get(c).create(a.U,a),a.H.push(c)):Sa("Unrecognized control panel element requested:",c)}function IB(a){if(a.g.addSeekBar)a.l=QB.create(a.L,a),a.H.push(a.l);else{a=t(a.G);for(var b=a.next();!b.done;b=a.next())b.value.classList.add("shaka-low-position")}}function DB(a){a.M=U("div");a.M.classList.add("shaka-client-side-ad-container");WA(a.M,!1);a.i.o(a.M,"click",function(){OB(a)});a.j.appendChild(a.M)}
1356
- function xB(a){a.i.o(a.D,"buffering",function(){a.P&&WA(a.$,a.D.vd())});a.P&&WA(a.$,a.D.vd());a.i.o(window,"keydown",function(b){RB(a,b)});a.i.o(window,"click",function(){return a.Jc()});a.i.o(a,"submenuopen",function(){a.Jc()});a.i.o(a.u,"play",function(){uB(a)});a.i.o(a.u,"pause",function(){uB(a)});a.i.o(a.j,"mousemove",function(b){NB(a,b)});a.i.o(a.j,"touchmove",function(b){NB(a,b)},{passive:!0});a.i.o(a.j,"touchend",function(b){NB(a,b)},{passive:!0});a.i.o(a.j,"mouseleave",function(){a.J||a.Z.Pa()});
1357
- a.i.o(a.C,"caststatuschanged",function(){yB(a)});a.i.o(a.j,"keydown",function(b){var c=document.activeElement,d=c&&c.classList?c.classList.contains("shaka-volume-bar"):!1,e=c&&c.classList&&c.classList.contains("shaka-seek-bar");a.h.contains(c)&&NB(a,b);if(a.g.enableKeyboardPlaybackControls){c=a.g.keyboardSeekDistance;var f=a.g.keyboardLargeSeekDistance;switch(b.key){case "ArrowLeft":a.l&&!d&&0<c&&(b.preventDefault(),SB(a,a.l.getValue()-c));break;case "ArrowRight":a.l&&!d&&0<c&&(b.preventDefault(),
1358
- SB(a,a.l.getValue()+c));break;case "PageDown":a.l&&e&&0<c&&(b.preventDefault(),SB(a,a.l.getValue()-f));break;case "PageUp":a.l&&e&&0<c&&(b.preventDefault(),SB(a,a.l.getValue()+f));break;case "Home":a.l&&SB(a,a.D.Fa().start);break;case "End":a.l&&SB(a,a.D.Fa().end);break;case " ":e&&TB(a)}}});a.i.o(a.j,"keyup",function(b){a.ha.delete(b.key)});a.i.o(a.Va,"ad-started",function(b){a.m=b.ad;a.kh()});a.i.o(a.Va,"ad-stopped",function(){a.m=null;a.Og()});screen.orientation&&a.i.o(screen.orientation,"change",
1359
- function(){return K(function(b){return D(b,UB(a),0)})})}function UB(a){return K(function(b){return a.u&&0!=a.u.readyState&&!a.C.Aa()&&a.g.enableFullscreenOnRotation&&a.ke()?screen.orientation.type.includes("landscape")&&!a.Lc()?D(b,JB(a),0):screen.orientation.type.includes("portrait")&&a.Lc()?D(b,KB(a),0):b.F(0):b.return()})}
1360
- function NB(a,b){"mousemove"==b.type&&(a.h.classList.remove("shaka-keyboard-navigation"),uB(a));"touchstart"==b.type||"touchmove"==b.type||"touchend"==b.type||"keyup"==b.type?a.J=Date.now():a.J+1E3<Date.now()&&(a.J=null);a.J&&"mousemove"==b.type||(a.j.style.cursor="",a.Gb=!0,a.I.stop(),a.qc()||(vB(a),uB(a)),a.Z.stop(),"touchend"!=b.type&&"keyup"!=b.type&&a.J||a.Z.T(3))}function VB(a){return window.matchMedia("hover: hover").matches?a.Ub.some(function(b){return b.matches(":hover")}):!1}
1361
- function uB(a){var b=a.m?a.m.isPaused():!1,c=a.u.paused&&!a.V,d=a.h.classList.contains("shaka-keyboard-navigation");b||(!a.m||!a.m.isLinear())&&c||a.Gb||d||VB(a)?(vB(a),a.h.setAttribute("shown","true"),a.ea.stop()):a.ea.T(a.g.fadeDelay)}function OB(a){a.P&&(a.Td()?a.I.Pa():a.g.singleClickForPlayAndPause&&TB(a))}function TB(a){a.m&&a.m.isLinear()?bB(a):cB(a)}
1362
- function yB(a){var b=a.C.Aa();a.dispatchEvent(new O("caststatuschanged",(new Map).set("newStatus",b)));b?a.h.setAttribute("casting","true"):a.h.removeAttribute("casting")}p.qc=function(){return this.P?null!=this.h.getAttribute("shown")||null!=this.h.getAttribute("casting"):!1};function SB(a,b){a.l.changeTo(b);a.qc()&&vB(a)}
1363
- function vB(a){if(a.l)if(a.l.setValue(a.u.currentTime),a.l.update(),a.l.isShowing())for(var b=t(a.G),c=b.next();!c.done;c=b.next())c.value.classList.remove("shaka-low-position");else for(b=t(a.G),c=b.next();!c.done;c=b.next())c.value.classList.add("shaka-low-position");a.dispatchEvent(new O("timeandseekrangeupdated"))}
1364
- function RB(a,b){a.ha.add(b.key);var c=a.Td();"Tab"==b.key&&(a.h.classList.add("shaka-keyboard-navigation"),uB(a),a.i.o(window,"mousedown",function(){a.i.cc(window,"mousedown")}));"Escape"==b.key&&a.I.Pa();c&&a.ha.has("Tab")&&WB(a,b)}
1365
- function WB(a,b){var c=a.G.filter(function(f){return!f.classList.contains("shaka-hidden")});if(c.length){var d=c[0];if(d.childNodes.length){for(c=d.firstElementChild;c&&c.classList.contains("shaka-hidden");)c=c.nextElementSibling;for(d=d.lastElementChild;d&&d.classList.contains("shaka-hidden");)d=d.previousElementSibling;var e=document.activeElement;a.ha.has("Shift")?e==c&&(b.preventDefault(),d.focus()):e==d&&(b.preventDefault(),c.focus())}}}
1366
- function wB(){var a=new Wb("en");a.xa("ar",new Map([["AD_DURATION","\u0645\u062f\u0629 \u0627\u0644\u0625\u0639\u0644\u0627\u0646"],["AD_PROGRESS","\u0627\u0644\u0625\u0639\u0644\u0627\u0646 [AD_ON] \u0645\u0646 [NUM_ADS]"],["AD_TIME","\u0627\u0644\u0625\u0639\u0644\u0627\u0646: [AD_TIME]"],["AUTO_QUALITY","\u062a\u0644\u0642\u0627\u0626\u064a"],["BACK","\u0631\u062c\u0648\u0639"],["CAPTIONS","\u0627\u0644\u062a\u0631\u062c\u0645\u0629 \u0648\u0627\u0644\u0634\u0631\u062d"],["CAST","\u0625\u0631\u0633\u0627\u0644..."],
1353
+ function GB(a){a.L=U("div");a.L.classList.add("shaka-bottom-controls");a.L.classList.add("shaka-no-propagation");a.h.appendChild(a.L);a.i.o(a.L,"click",function(d){d.target.closest(".shaka-overflow-button")||a.Jc()});OB(a);a.U=U("div");a.U.classList.add("shaka-controls-button-panel");a.U.classList.add("shaka-show-controls-on-mouse-over");a.g.enableTooltips&&a.U.classList.add("shaka-tooltips-on");a.L.appendChild(a.U);for(var b=t(a.g.controlPanelElements),c=b.next();!c.done;c=b.next())c=c.value,AB.get(c)?
1354
+ (c=AB.get(c).create(a.U,a),a.H.push(c)):Sa("Unrecognized control panel element requested:",c)}function HB(a){if(a.g.addSeekBar)a.l=PB.create(a.L,a),a.H.push(a.l);else{a=t(a.G);for(var b=a.next();!b.done;b=a.next())b.value.classList.add("shaka-low-position")}}function CB(a){a.M=U("div");a.M.classList.add("shaka-client-side-ad-container");VA(a.M,!1);a.i.o(a.M,"click",function(){NB(a)});a.j.appendChild(a.M)}
1355
+ function wB(a){a.i.o(a.D,"buffering",function(){a.P&&VA(a.$,a.D.vd())});a.P&&VA(a.$,a.D.vd());a.i.o(window,"keydown",function(b){QB(a,b)});a.i.o(window,"click",function(){return a.Jc()});a.i.o(a,"submenuopen",function(){a.Jc()});a.i.o(a.u,"play",function(){tB(a)});a.i.o(a.u,"pause",function(){tB(a)});a.i.o(a.j,"mousemove",function(b){MB(a,b)});a.i.o(a.j,"touchmove",function(b){MB(a,b)},{passive:!0});a.i.o(a.j,"touchend",function(b){MB(a,b)},{passive:!0});a.i.o(a.j,"mouseleave",function(){a.J||a.Z.Pa()});
1356
+ a.i.o(a.C,"caststatuschanged",function(){xB(a)});a.i.o(a.j,"keydown",function(b){var c=document.activeElement,d=c&&c.classList?c.classList.contains("shaka-volume-bar"):!1,e=c&&c.classList&&c.classList.contains("shaka-seek-bar");a.h.contains(c)&&MB(a,b);if(a.g.enableKeyboardPlaybackControls){c=a.g.keyboardSeekDistance;var f=a.g.keyboardLargeSeekDistance;switch(b.key){case "ArrowLeft":a.l&&!d&&0<c&&(b.preventDefault(),RB(a,a.l.getValue()-c));break;case "ArrowRight":a.l&&!d&&0<c&&(b.preventDefault(),
1357
+ RB(a,a.l.getValue()+c));break;case "PageDown":a.l&&e&&0<c&&(b.preventDefault(),RB(a,a.l.getValue()-f));break;case "PageUp":a.l&&e&&0<c&&(b.preventDefault(),RB(a,a.l.getValue()+f));break;case "Home":a.l&&RB(a,a.D.Fa().start);break;case "End":a.l&&RB(a,a.D.Fa().end);break;case " ":e&&SB(a)}}});a.i.o(a.j,"keyup",function(b){a.ha.delete(b.key)});a.i.o(a.Va,"ad-started",function(b){a.m=b.ad;a.kh()});a.i.o(a.Va,"ad-stopped",function(){a.m=null;a.Og()});screen.orientation&&a.i.o(screen.orientation,"change",
1358
+ function(){return K(function(b){return D(b,TB(a),0)})})}function TB(a){return K(function(b){return a.u&&0!=a.u.readyState&&!a.C.Aa()&&a.g.enableFullscreenOnRotation&&a.ke()?screen.orientation.type.includes("landscape")&&!a.Lc()?D(b,IB(a),0):screen.orientation.type.includes("portrait")&&a.Lc()?D(b,JB(a),0):b.F(0):b.return()})}
1359
+ function MB(a,b){"mousemove"==b.type&&(a.h.classList.remove("shaka-keyboard-navigation"),tB(a));"touchstart"==b.type||"touchmove"==b.type||"touchend"==b.type||"keyup"==b.type?a.J=Date.now():a.J+1E3<Date.now()&&(a.J=null);a.J&&"mousemove"==b.type||(a.j.style.cursor="",a.Gb=!0,a.I.stop(),a.qc()||(uB(a),tB(a)),a.Z.stop(),"touchend"!=b.type&&"keyup"!=b.type&&a.J||a.Z.T(3))}function UB(a){return window.matchMedia("hover: hover").matches?a.Wb.some(function(b){return b.matches(":hover")}):!1}
1360
+ function tB(a){var b=a.m?a.m.isPaused():!1,c=a.u.paused&&!a.V,d=a.h.classList.contains("shaka-keyboard-navigation");b||(!a.m||!a.m.isLinear())&&c||a.Gb||d||UB(a)?(uB(a),a.h.setAttribute("shown","true"),a.ea.stop()):a.ea.T(a.g.fadeDelay)}function NB(a){a.P&&(a.Td()?a.I.Pa():a.g.singleClickForPlayAndPause&&SB(a))}function SB(a){a.m&&a.m.isLinear()?aB(a):bB(a)}
1361
+ function xB(a){var b=a.C.Aa();a.dispatchEvent(new O("caststatuschanged",(new Map).set("newStatus",b)));b?a.h.setAttribute("casting","true"):a.h.removeAttribute("casting")}p.qc=function(){return this.P?null!=this.h.getAttribute("shown")||null!=this.h.getAttribute("casting"):!1};function RB(a,b){a.l.changeTo(b);a.qc()&&uB(a)}
1362
+ function uB(a){if(a.l)if(a.l.setValue(a.u.currentTime),a.l.update(),a.l.isShowing())for(var b=t(a.G),c=b.next();!c.done;c=b.next())c.value.classList.remove("shaka-low-position");else for(b=t(a.G),c=b.next();!c.done;c=b.next())c.value.classList.add("shaka-low-position");a.dispatchEvent(new O("timeandseekrangeupdated"))}
1363
+ function QB(a,b){a.ha.add(b.key);var c=a.Td();"Tab"==b.key&&(a.h.classList.add("shaka-keyboard-navigation"),tB(a),a.i.o(window,"mousedown",function(){a.i.dc(window,"mousedown")}));"Escape"==b.key&&a.I.Pa();c&&a.ha.has("Tab")&&VB(a,b)}
1364
+ function VB(a,b){var c=a.G.filter(function(f){return!f.classList.contains("shaka-hidden")});if(c.length){var d=c[0];if(d.childNodes.length){for(c=d.firstElementChild;c&&c.classList.contains("shaka-hidden");)c=c.nextElementSibling;for(d=d.lastElementChild;d&&d.classList.contains("shaka-hidden");)d=d.previousElementSibling;var e=document.activeElement;a.ha.has("Shift")?e==c&&(b.preventDefault(),d.focus()):e==d&&(b.preventDefault(),c.focus())}}}
1365
+ function vB(){var a=new Wb("en");a.xa("ar",new Map([["AD_DURATION","\u0645\u062f\u0629 \u0627\u0644\u0625\u0639\u0644\u0627\u0646"],["AD_PROGRESS","\u0627\u0644\u0625\u0639\u0644\u0627\u0646 [AD_ON] \u0645\u0646 [NUM_ADS]"],["AD_TIME","\u0627\u0644\u0625\u0639\u0644\u0627\u0646: [AD_TIME]"],["AUTO_QUALITY","\u062a\u0644\u0642\u0627\u0626\u064a"],["BACK","\u0631\u062c\u0648\u0639"],["CAPTIONS","\u0627\u0644\u062a\u0631\u062c\u0645\u0629 \u0648\u0627\u0644\u0634\u0631\u062d"],["CAST","\u0625\u0631\u0633\u0627\u0644..."],
1367
1366
  ["ENTER_LOOP_MODE","\u062a\u0643\u0631\u0627\u0631 \u0627\u0644\u0641\u064a\u062f\u064a\u0648 \u0627\u0644\u062d\u0627\u0644\u064a"],["ENTER_PICTURE_IN_PICTURE",'\u0627\u0644\u062f\u062e\u0648\u0644 \u0641\u064a \u0648\u0636\u0639 "\u0646\u0627\u0641\u0630\u0629 \u0636\u0645\u0646 \u0646\u0627\u0641\u0630\u0629"'],["EXIT_FULL_SCREEN","\u0625\u0646\u0647\u0627\u0621 \u0648\u0636\u0639 \u0645\u0644\u0621 \u0627\u0644\u0634\u0627\u0634\u0629"],["EXIT_LOOP_MODE","\u0625\u064a\u0642\u0627\u0641 \u062a\u0643\u0631\u0627\u0631 \u0627\u0644\u0641\u064a\u062f\u064a\u0648 \u0627\u0644\u062d\u0627\u0644\u064a"],
1368
1367
  ["EXIT_PICTURE_IN_PICTURE",'\u0627\u0644\u062e\u0631\u0648\u062c \u0645\u0646 \u0648\u0636\u0639 "\u0646\u0627\u0641\u0630\u0629 \u0636\u0645\u0646 \u0646\u0627\u0641\u0630\u0629"'],["FAST_FORWARD","\u062a\u0642\u062f\u064a\u0645 \u0633\u0631\u064a\u0639"],["FULL_SCREEN","\u0645\u0644\u0621 \u0627\u0644\u0634\u0627\u0634\u0629"],["LANGUAGE","\u0627\u0644\u0644\u063a\u0629"],["LIVE","\u0645\u0628\u0627\u0634\u0631"],["LOOP","\u062a\u0643\u0631\u0627\u0631"],["MORE_SETTINGS","\u0645\u0632\u064a\u062f \u0645\u0646 \u0627\u0644\u0625\u0639\u062f\u0627\u062f\u0627\u062a"],
1369
1368
  ["MULTIPLE_LANGUAGES","\u0644\u063a\u0627\u062a \u0645\u062a\u0639\u062f\u062f\u0629"],["MUTE","\u0643\u062a\u0645 \u0627\u0644\u0635\u0648\u062a"],["NOT_APPLICABLE","\u063a\u064a\u0631 \u0633\u0627\u0631\u064d"],["OFF","\u0625\u064a\u0642\u0627\u0641"],["ON","\u062a\u0634\u063a\u064a\u0644"],["PAUSE","\u0625\u064a\u0642\u0627\u0641 \u0645\u0624\u0642\u062a"],["PICTURE_IN_PICTURE","\u0646\u0627\u0641\u0630\u0629 \u0636\u0645\u0646 \u0627\u0644\u0646\u0627\u0641\u0630\u0629"],["PLAY","\u0627\u0644\u062a\u0634\u063a\u064a\u0644"],
@@ -1423,83 +1422,83 @@ a.xa("en",new Map([["AD_DURATION","Ad duration"],["AD_PROGRESS","Ad [AD_ON] of [
1423
1422
  ["FAST_FORWARD","\u5feb\u8f49"],["FULL_SCREEN","\u5168\u87a2\u5e55"],["LANGUAGE","\u8a9e\u8a00"],["LIVE","\u76f4\u64ad"],["LOOP","\u5faa\u74b0\u64ad\u653e"],["MORE_SETTINGS","\u986f\u793a\u66f4\u591a\u8a2d\u5b9a"],["MULTIPLE_LANGUAGES","\u591a\u7a2e\u8a9e\u8a00"],["MUTE","\u975c\u97f3"],["NOT_APPLICABLE","\u4e0d\u9069\u7528"],["OFF","\u95dc\u9589"],["ON","\u958b\u555f"],["PAUSE","\u66ab\u505c"],["PICTURE_IN_PICTURE","\u5b50\u6bcd\u756b\u9762"],["PLAY","\u64ad\u653e"],["PLAYBACK_RATE","\u64ad\u653e\u901f\u5ea6"],
1424
1423
  ["RESOLUTION","\u89e3\u6790\u5ea6"],["REWIND","\u5012\u8f49"],["SEEK","\u641c\u5c0b"],["SKIP_AD","\u7565\u904e\u5ee3\u544a"],["SKIP_TO_LIVE","\u8df3\u81f3\u5f53\u524d\u76f4\u64ad"],["UNDETERMINED_LANGUAGE","\u4e0d\u660e"],["UNMUTE","\u53d6\u6d88\u975c\u97f3"],["UNRECOGNIZED_LANGUAGE","\u7121\u6cd5\u8fa8\u8b58"],["VOLUME","\u97f3\u91cf"]]));a.Bg(navigator.languages||[]);return a}M("shaka.ui.Controls",Y);Y.prototype.isOpaque=Y.prototype.qc;Y.prototype.hideAdUI=Y.prototype.Og;Y.prototype.showAdUI=Y.prototype.kh;
1425
1424
  Y.prototype.togglePiP=Y.prototype.Ie;Y.prototype.isPiPEnabled=Y.prototype.le;Y.prototype.isPiPAllowed=Y.prototype.Gf;Y.prototype.toggleFullScreen=Y.prototype.pg;Y.prototype.isFullScreenEnabled=Y.prototype.Lc;Y.prototype.isFullScreenSupported=Y.prototype.ke;Y.prototype.hideSettingsMenus=Y.prototype.Jc;Y.prototype.anySettingsMenusAreOpen=Y.prototype.Td;Y.prototype.setLastTouchEventTime=Y.prototype.hh;Y.prototype.getDisplayTime=Y.prototype.Mg;Y.prototype.isCastAllowed=Y.prototype.ti;
1426
- Y.prototype.setSeeking=Y.prototype.kg;Y.prototype.isSeeking=Y.prototype.Ci;Y.prototype.getConfig=Y.prototype.Oh;Y.prototype.getClientSideAdContainer=Y.prototype.Nh;Y.prototype.getServerSideAdContainer=Y.prototype.ei;Y.prototype.getControlsContainer=Y.prototype.Qh;Y.prototype.getLocalPlayer=Y.prototype.Wh;Y.prototype.getPlayer=Y.prototype.Gc;Y.prototype.getLocalVideo=Y.prototype.Xh;Y.prototype.getVideo=Y.prototype.ac;Y.prototype.getVideoContainer=Y.prototype.ni;Y.prototype.getLocalization=Y.prototype.Yh;
1427
- Y.prototype.getCastProxy=Y.prototype.Lh;Y.prototype.getAd=Y.prototype.getAd;Y.prototype.setEnabledNativeControls=Y.prototype.gh;Y.prototype.setEnabledShakaControls=Y.prototype.fg;Y.prototype.configure=Y.prototype.configure;Y.prototype.loadComplete=Y.prototype.Fi;Y.prototype.allowCast=Y.prototype.yh;Y.registerSeekBar=function(a){QB=a};Y.registerElement=AB;Y.prototype.destroy=Y.prototype.destroy;var BB=new Map,QB=new tB;function XB(a,b){RA.call(this,a,b);var c=this;this.l=this.controls.g;this.j=this.controls.h;this.i=[];this.g=Vk();this.g.classList.add("shaka-overflow-menu-button");this.g.classList.add("shaka-no-propagation");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");this.g.textContent="more_vert";this.parent.appendChild(this.g);this.h=U("div");this.h.classList.add("shaka-overflow-menu");this.h.classList.add("shaka-no-propagation");this.h.classList.add("shaka-show-controls-on-mouse-over");
1428
- this.h.classList.add("shaka-hidden");this.j.appendChild(this.h);YB(this);this.eventManager.o(this.localization,"locale-updated",function(){ZB(c)});this.eventManager.o(this.localization,"locale-changed",function(){ZB(c)});this.eventManager.o(this.adManager,"ad-started",function(){c.ad&&c.ad.isLinear()&&WA(c.g,!1)});this.eventManager.o(this.adManager,"ad-stopped",function(){WA(c.g,!0)});this.eventManager.o(this.controls,"submenuopen",function(){WA(c.h,!1)});this.eventManager.o(this.h,"touchstart",function(d){c.controls.hh(Date.now());
1429
- d.stopPropagation()});this.eventManager.o(this.g,"click",function(){$B(c)});ZB(this);this.ad&&this.ad.isLinear()&&WA(this.g,!1)}pa(XB,RA);XB.prototype.release=function(){this.j=null;for(var a=t(this.i),b=a.next();!b.done;b=a.next())b.value.release();this.i=[];RA.prototype.release.call(this)};function aC(a,b){bC.set(a,b)}
1430
- function YB(a){for(var b=t(a.l.overflowMenuButtons),c=b.next();!c.done;c=b.next())c=c.value,bC.get(c)?(c=bC.get(c),a.i.push(c.create(a.h,a.controls))):Sa("Unrecognized overflow menu element requested:",c)}function $B(a){if(a.controls.Td())a.controls.Jc();else{WA(a.h,!0);uB(a.controls);var b=function(c){return 0==c.classList.contains("shaka-hidden")};db(a.h.childNodes,b)&&eb(a.h.childNodes,b)[0].focus()}}function ZB(a){a.g.ariaLabel=a.localization.resolve("MORE_SETTINGS")}
1431
- M("shaka.ui.OverflowMenu",XB);XB.registerElement=aC;function cC(){}cC.prototype.create=function(a,b){return new XB(a,b)};AB("overflow_menu",new cC);var bC=new Map;function dC(a,b){RA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("shaka-airplay-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.h=U("i");this.h.classList.add("material-icons-round");this.h.textContent="airplay";this.g.appendChild(this.h);window.WebKitPlaybackTargetAvailabilityEvent||this.g.classList.add("shaka-hidden");a=U("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=U("span");a.appendChild(this.j);
1432
- this.i=U("span");this.i.classList.add("shaka-current-selection-span");a.appendChild(this.i);this.g.appendChild(a);this.parent.appendChild(this.g);eC(this);fC(this);this.eventManager.o(this.localization,"locale-updated",function(){eC(c)});this.eventManager.o(this.localization,"locale-changed",function(){eC(c)});this.eventManager.o(this.g,"click",function(){c.controls.ac().webkitShowPlaybackTargetPicker()});a=this.controls.ac();this.eventManager.o(a,"webkitplaybacktargetavailabilitychanged",function(d){var e=
1433
- c.player.ae()==Xm;WA(c.g,"available"==d.availability&&e)});this.eventManager.o(a,"webkitcurrentplaybacktargetiswirelesschanged",function(){fC(c)})}pa(dC,RA);function fC(a){var b=a.controls.ac();a.g.ariaPressed=b&&b.webkitCurrentPlaybackTargetIsWireless?"true":"false"}function eC(a){a.g.ariaLabel=a.localization.resolve("AIRPLAY");a.j.textContent=a.localization.resolve("AIRPLAY")}M("shaka.ui.AirPlayButton",dC);function gC(){}gC.prototype.create=function(a,b){return new dC(a,b)};aC("airplay",new gC);
1434
- AB("airplay",new gC);function hC(a,b,c){this.i=a;this.j=b;this.h=iC(this);b.dataset.shakaPlayerContainer="";b.ui=this;this.Ff()&&b.classList.add("shaka-mobile");this.g=new Y(a,b,c,this.h);this.configure({});c.controls||a.lg(b);b.ui=this;c.ui=this}p=hC.prototype;p.destroy=function(){var a=this;return K(function(b){if(1==b.g)return a.g?D(b,a.g.destroy(),2):b.F(2);if(4!=b.g)return a.g=null,a.i?D(b,a.i.destroy(),4):b.F(4);a.i=null;F(b)})};
1435
- p.Ff=function(){return/(?:iPhone|iPad|iPod|Android)/.test(navigator.userAgent)?!0:Hd()&&1<navigator.maxTouchPoints};p.getConfiguration=function(){var a=iC(this);yl(a,this.h,iC(this),{},"");return a};p.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=zl(a,b));yl(this.h,a,iC(this),{},"");this.h.castReceiverAppId&&!this.h.overflowMenuButtons.includes("cast")&&this.h.overflowMenuButtons.push("cast");this.g.configure(this.h);this.g.dispatchEvent(new O("uiupdated"))};p.Ph=function(){return this.g};
1425
+ Y.prototype.setSeeking=Y.prototype.kg;Y.prototype.isSeeking=Y.prototype.Ci;Y.prototype.getConfig=Y.prototype.Oh;Y.prototype.getClientSideAdContainer=Y.prototype.Nh;Y.prototype.getServerSideAdContainer=Y.prototype.ei;Y.prototype.getControlsContainer=Y.prototype.Qh;Y.prototype.getLocalPlayer=Y.prototype.Wh;Y.prototype.getPlayer=Y.prototype.Gc;Y.prototype.getLocalVideo=Y.prototype.Xh;Y.prototype.getVideo=Y.prototype.bc;Y.prototype.getVideoContainer=Y.prototype.ni;Y.prototype.getLocalization=Y.prototype.Yh;
1426
+ Y.prototype.getCastProxy=Y.prototype.Lh;Y.prototype.getAd=Y.prototype.getAd;Y.prototype.setEnabledNativeControls=Y.prototype.gh;Y.prototype.setEnabledShakaControls=Y.prototype.fg;Y.prototype.configure=Y.prototype.configure;Y.prototype.loadComplete=Y.prototype.Fi;Y.prototype.allowCast=Y.prototype.yh;Y.registerSeekBar=function(a){PB=a};Y.registerElement=zB;Y.prototype.destroy=Y.prototype.destroy;var AB=new Map,PB=new sB;function WB(a,b){QA.call(this,a,b);var c=this;this.l=this.controls.g;this.j=this.controls.h;this.i=[];this.g=Vk();this.g.classList.add("shaka-overflow-menu-button");this.g.classList.add("shaka-no-propagation");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");this.g.textContent="more_vert";this.parent.appendChild(this.g);this.h=U("div");this.h.classList.add("shaka-overflow-menu");this.h.classList.add("shaka-no-propagation");this.h.classList.add("shaka-show-controls-on-mouse-over");
1427
+ this.h.classList.add("shaka-hidden");this.j.appendChild(this.h);XB(this);this.eventManager.o(this.localization,"locale-updated",function(){YB(c)});this.eventManager.o(this.localization,"locale-changed",function(){YB(c)});this.eventManager.o(this.adManager,"ad-started",function(){c.ad&&c.ad.isLinear()&&VA(c.g,!1)});this.eventManager.o(this.adManager,"ad-stopped",function(){VA(c.g,!0)});this.eventManager.o(this.controls,"submenuopen",function(){VA(c.h,!1)});this.eventManager.o(this.h,"touchstart",function(d){c.controls.hh(Date.now());
1428
+ d.stopPropagation()});this.eventManager.o(this.g,"click",function(){ZB(c)});YB(this);this.ad&&this.ad.isLinear()&&VA(this.g,!1)}pa(WB,QA);WB.prototype.release=function(){this.j=null;for(var a=t(this.i),b=a.next();!b.done;b=a.next())b.value.release();this.i=[];QA.prototype.release.call(this)};function $B(a,b){aC.set(a,b)}
1429
+ function XB(a){for(var b=t(a.l.overflowMenuButtons),c=b.next();!c.done;c=b.next())c=c.value,aC.get(c)?(c=aC.get(c),a.i.push(c.create(a.h,a.controls))):Sa("Unrecognized overflow menu element requested:",c)}function ZB(a){if(a.controls.Td())a.controls.Jc();else{VA(a.h,!0);tB(a.controls);var b=function(c){return 0==c.classList.contains("shaka-hidden")};db(a.h.childNodes,b)&&eb(a.h.childNodes,b)[0].focus()}}function YB(a){a.g.ariaLabel=a.localization.resolve("MORE_SETTINGS")}
1430
+ M("shaka.ui.OverflowMenu",WB);WB.registerElement=$B;function bC(){}bC.prototype.create=function(a,b){return new WB(a,b)};zB("overflow_menu",new bC);var aC=new Map;function cC(a,b){QA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("shaka-airplay-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.h=U("i");this.h.classList.add("material-icons-round");this.h.textContent="airplay";this.g.appendChild(this.h);window.WebKitPlaybackTargetAvailabilityEvent||this.g.classList.add("shaka-hidden");a=U("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=U("span");a.appendChild(this.j);
1431
+ this.i=U("span");this.i.classList.add("shaka-current-selection-span");a.appendChild(this.i);this.g.appendChild(a);this.parent.appendChild(this.g);dC(this);eC(this);this.eventManager.o(this.localization,"locale-updated",function(){dC(c)});this.eventManager.o(this.localization,"locale-changed",function(){dC(c)});this.eventManager.o(this.g,"click",function(){c.controls.bc().webkitShowPlaybackTargetPicker()});a=this.controls.bc();this.eventManager.o(a,"webkitplaybacktargetavailabilitychanged",function(d){var e=
1432
+ c.player.ae()==Xm;VA(c.g,"available"==d.availability&&e)});this.eventManager.o(a,"webkitcurrentplaybacktargetiswirelesschanged",function(){eC(c)})}pa(cC,QA);function eC(a){var b=a.controls.bc();a.g.ariaPressed=b&&b.webkitCurrentPlaybackTargetIsWireless?"true":"false"}function dC(a){a.g.ariaLabel=a.localization.resolve("AIRPLAY");a.j.textContent=a.localization.resolve("AIRPLAY")}M("shaka.ui.AirPlayButton",cC);function fC(){}fC.prototype.create=function(a,b){return new cC(a,b)};$B("airplay",new fC);
1433
+ zB("airplay",new fC);function gC(a,b,c){this.i=a;this.j=b;this.h=hC(this);b.dataset.shakaPlayerContainer="";b.ui=this;this.Ff()&&b.classList.add("shaka-mobile");this.g=new Y(a,b,c,this.h);this.configure({});c.controls||a.lg(b);b.ui=this;c.ui=this}p=gC.prototype;p.destroy=function(){var a=this;return K(function(b){if(1==b.g)return a.g?D(b,a.g.destroy(),2):b.F(2);if(4!=b.g)return a.g=null,a.i?D(b,a.i.destroy(),4):b.F(4);a.i=null;F(b)})};
1434
+ p.Ff=function(){return/(?:iPhone|iPad|iPod|Android)/.test(navigator.userAgent)?!0:Hd()&&1<navigator.maxTouchPoints};p.getConfiguration=function(){var a=hC(this);yl(a,this.h,hC(this),{},"");return a};p.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=zl(a,b));yl(this.h,a,hC(this),{},"");this.h.castReceiverAppId&&!this.h.overflowMenuButtons.includes("cast")&&this.h.overflowMenuButtons.push("cast");this.g.configure(this.h);this.g.dispatchEvent(new O("uiupdated"))};p.Ph=function(){return this.g};
1436
1435
  p.hj=function(a){this.g.fg(a)};
1437
- function iC(a){var b={controlPanelElements:"play_pause time_and_duration spacer mute volume fullscreen overflow_menu".split(" "),overflowMenuButtons:"captions quality language picture_in_picture cast playback_rate".split(" "),statisticsList:"width height corruptedFrames decodedFrames droppedFrames drmTimeSeconds licenseTime liveLatency loadLatency bufferingTime manifestTimeSeconds estimatedBandwidth streamBandwidth maxSegmentDuration pauseTime playTime completionPercent".split(" "),contextMenuElements:["loop",
1436
+ function hC(a){var b={controlPanelElements:"play_pause time_and_duration spacer mute volume fullscreen overflow_menu".split(" "),overflowMenuButtons:"captions quality language picture_in_picture cast playback_rate".split(" "),statisticsList:"width height corruptedFrames decodedFrames droppedFrames drmTimeSeconds licenseTime liveLatency loadLatency bufferingTime manifestTimeSeconds estimatedBandwidth streamBandwidth maxSegmentDuration pauseTime playTime completionPercent".split(" "),contextMenuElements:["loop",
1438
1437
  "picture_in_picture","statistics"],playbackRates:[.5,.75,1,1.25,1.5,1.75,2],fastForwardRates:[2,4,8,1],rewindRates:[-1,-2,-4,-8],addSeekBar:!0,addBigPlayButton:!1,customContextMenu:!1,castReceiverAppId:"",castAndroidReceiverCompatible:!1,clearBufferOnQualityChange:!0,showUnbufferedStart:!1,seekBarColors:{base:"rgba(255, 255, 255, 0.3)",buffered:"rgba(255, 255, 255, 0.54)",played:"rgb(255, 255, 255)",adBreaks:"rgb(255, 204, 0)"},volumeBarColors:{base:"rgba(255, 255, 255, 0.54)",level:"rgb(255, 255, 255)"},
1439
- trackLabelFormat:jC,fadeDelay:0,doubleClickForFullscreen:!0,singleClickForPlayAndPause:!0,enableKeyboardPlaybackControls:!0,enableFullscreenOnRotation:!0,forceLandscapeOnFullscreen:!0,enableTooltips:!1,keyboardSeekDistance:5,keyboardLargeSeekDistance:60,fullScreenElement:a.j,preferDocumentPictureInPicture:!0,showAudioChannelCountVariants:!0};"remote"in HTMLMediaElement.prototype?b.overflowMenuButtons.push("remote"):window.WebKitPlaybackTargetAvailabilityEvent&&b.overflowMenuButtons.push("airplay");
1438
+ trackLabelFormat:iC,fadeDelay:0,doubleClickForFullscreen:!0,singleClickForPlayAndPause:!0,enableKeyboardPlaybackControls:!0,enableFullscreenOnRotation:!0,forceLandscapeOnFullscreen:!0,enableTooltips:!1,keyboardSeekDistance:5,keyboardLargeSeekDistance:60,fullScreenElement:a.j,preferDocumentPictureInPicture:!0,showAudioChannelCountVariants:!0};"remote"in HTMLMediaElement.prototype?b.overflowMenuButtons.push("remote"):window.WebKitPlaybackTargetAvailabilityEvent&&b.overflowMenuButtons.push("airplay");
1440
1439
  a.Ff()&&(b.addBigPlayButton=!0,b.controlPanelElements=b.controlPanelElements.filter(function(c){return"play_pause"!=c&&"volume"!=c}));return b}
1441
- function kC(){var a,b,c,d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B;return K(function(C){switch(C.g){case 1:Xw();if(!cm())return lC("shaka-ui-load-failed",mC),C.return();a=document.querySelectorAll("[data-shaka-player-container]");b=document.querySelectorAll("[data-shaka-player]");c=document.querySelectorAll("[data-shaka-player-canvas]");if(!b.length&&!a.length){C.F(2);break}if(b.length&&!a.length){d=t(b);for(e=d.next();!e.done;e=d.next())if(f=e.value,!f.ui){g=document.createElement("div");h=f.parentElement;
1442
- h.replaceChild(g,f);g.appendChild(f);k=null;l=t(c);for(m=l.next();!m.done;m=l.next())if(n=m.value,n.parentElement==g){k=n;break}k||(k=document.createElement("canvas"),k.classList.add("shaka-canvas-container"),g.appendChild(k));nC(g,f,k)}C.F(2);break}q=t(a);r=q.next();case 4:if(r.done){C.F(2);break}u=r.value;if(u.ui){C.F(5);break}v=null;y=t(b);for(e=y.next();!e.done;e=y.next())if(z=e.value,z.parentElement==u){v=z;break}v||(v=document.createElement("video"),v.setAttribute("playsinline",""),u.appendChild(v));
1443
- x=null;A=t(c);for(m=A.next();!m.done;m=A.next())if(B=m.value,B.parentElement==u){x=B;break}x||(x=document.createElement("canvas"),x.classList.add("shaka-canvas-container"),u.appendChild(x));ta(C,7);return D(C,nC(u,v,x),9);case 9:va(C,5);break;case 7:return wa(C),lC("shaka-ui-load-failed",oC),C.return();case 5:r=q.next();C.F(4);break;case 2:lC("shaka-ui-loaded"),F(C)}})}function lC(a,b){var c=null;void 0!=b&&(c={reasonCode:b});a=new CustomEvent(a,{detail:c});document.dispatchEvent(a)}
1444
- function nC(a,b,c){var d,e,f,g,h,k,l,m,n;return K(function(q){switch(q.g){case 1:d=new V;e=new hC(d,a,b);d.yg(c);f="";g=!1;a.dataset&&a.dataset.shakaPlayerCastReceiverId?(f=a.dataset.shakaPlayerCastReceiverId,g="true"===a.dataset.shakaPlayerCastAndroidReceiverCompatible):b.dataset&&b.dataset.shakaPlayerCastReceiverId&&(f=b.dataset.shakaPlayerCastReceiverId,g="true"===b.dataset.shakaPlayerCastAndroidReceiverCompatible);f.length&&e.configure({castReceiverAppId:f,castAndroidReceiverCompatible:g});b.controls&&
1445
- e.g.gh(!0);if(h=b.getAttribute("src"))k=document.createElement("source"),k.setAttribute("src",h),b.appendChild(k),b.removeAttribute("src");l=t(b.querySelectorAll("source"));m=l.next();case 2:if(m.done){q.F(4);break}n=m.value;ta(q,5);return D(q,e.g.Gc().load(n.getAttribute("src")),7);case 7:q.F(4);break;case 5:wa(q);case 3:m=l.next();q.F(2);break;case 4:return D(q,d.Ac(b),0)}})}M("shaka.ui.Overlay",hC);hC.prototype.setEnabled=hC.prototype.hj;hC.prototype.getControls=hC.prototype.Ph;
1446
- hC.prototype.configure=hC.prototype.configure;hC.prototype.getConfiguration=hC.prototype.getConfiguration;hC.prototype.isMobile=hC.prototype.Ff;hC.prototype.destroy=hC.prototype.destroy;var jC=0;hC.TrackLabelFormat={LANGUAGE:jC,ROLE:1,LANGUAGE_ROLE:2,LABEL:3};var mC=0,oC=1;hC.FailReasonCode={NO_BROWSER_SUPPORT:mC,PLAYER_FAILED_TO_LOAD:oC};"complete"==document.readyState?K(function(a){if(1==a.g)return D(a,Promise.resolve(),2);kC();F(a)}):window.addEventListener("load",kC);function pC(a,b,c,d,e,f,g,h){function k(H){var G="";5<=H&&(G=" "+f.resolve("SURROUND"));return G}function l(H,G,I,J){H=[H,G];h&&null!=J&&H.push(J);I&&3==g&&H.push(I);return H.join(": ")}function m(H){return"variant"==H.type?H.audioRoles?H.audioRoles.join(", "):void 0:H.roles.join(", ")}var n=a.find(function(H){return 1==H.active}),q=SA(b);Wk(b);b.appendChild(q);q=new Map;for(var r=t(a),u=r.next();!u.done;u=r.next())u=u.value,q.has(u.language)||q.set(u.language,new Set),q.get(u.language).add(m(u));
1447
- q=new Set;n=n?l(n.language,m(n),n.label,n.channelsCount):"";r={};a=t(a);for(u=a.next();!u.done;r={ub:r.ub},u=a.next()){r.ub=u.value;u=r.ub.language;var v=r.ub.forced,y=f.resolve("SUBTITLE_FORCED"),z=m(r.ub),x=r.ub.label,A=r.ub.channelsCount,B=l(u,z,x,A);if(!q.has(B)){q.add(B);var C=Vk();C.addEventListener("click",function(H){return function(){c(H.ub)}}(r));var E=U("span");C.appendChild(E);E.textContent=qC(u,f);switch(g){case jC:h&&(E.textContent+=k(A));v&&(E.textContent+=" ("+y+")");break;case 1:h&&
1448
- (E.textContent+=k(A));z?E.textContent=z:(Sa("Track #"+r.ub.id+" does not have a role, but the UI is configured to only show role."),E.textContent="?");v&&(E.textContent+=" ("+y+")");break;case 2:h&&(E.textContent+=k(A));z&&(E.textContent+=": "+z);v&&(E.textContent+=" ("+y+")");break;case 3:x?E.textContent=x:(Sa("Track #"+r.ub.id+" does not have a label, but the UI is configured to only show labels."),E.textContent="?")}d&&B==n&&(C.appendChild(VA()),E.classList.add("shaka-chosen-item"),C.ariaSelected=
1449
- "true",e.textContent=E.textContent);b.appendChild(C)}}}function qC(a,b){if(!a&&!b)return"";switch(a){case "mul":return b.resolve("MULTIPLE_LANGUAGES");case "und":return b.resolve("UNDETERMINED_LANGUAGE");case "zxx":return b.resolve("NOT_APPLICABLE")}var c=Sb(a);return a in NA?NA[a].A:c in NA?NA[c].A+" ("+a+")":b.resolve("UNRECOGNIZED_LANGUAGE")+" ("+a+")"};function rC(a,b,c){RA.call(this,a,b);var d=this;sC(this,c);tC(this);uC(this);this.eventManager.o(this.button,"click",function(){d.menu.classList.contains("shaka-hidden")?(d.controls.dispatchEvent(new O("submenuopen")),WA(d.menu,!0),UA(d.menu)):WA(d.menu,!1)})}pa(rC,RA);
1450
- function sC(a,b){a.button=Vk();a.button.classList.add("shaka-overflow-button");a.icon=U("i");a.icon.classList.add("material-icons-round");a.icon.textContent=b;a.button.appendChild(a.icon);b=U("label");b.classList.add("shaka-overflow-button-label");b.classList.add("shaka-overflow-menu-only");a.nameSpan=U("span");b.appendChild(a.nameSpan);a.currentSelection=U("span");a.currentSelection.classList.add("shaka-current-selection-span");b.appendChild(a.currentSelection);a.button.appendChild(b);a.parent.appendChild(a.button)}
1451
- function tC(a){a.menu=U("div");a.menu.classList.add("shaka-no-propagation");a.menu.classList.add("shaka-show-controls-on-mouse-over");a.menu.classList.add("shaka-settings-menu");a.menu.classList.add("shaka-hidden");a.backButton=Vk();a.backButton.classList.add("shaka-back-to-overflow-button");a.menu.appendChild(a.backButton);a.eventManager.o(a.backButton,"click",function(){a.controls.Jc()});var b=U("i");b.classList.add("material-icons-round");b.textContent="close";a.backButton.appendChild(b);a.backSpan=
1452
- U("span");a.backButton.appendChild(a.backSpan);a.controls.h.appendChild(a.menu)}function uC(a){a.parent.classList.contains("shaka-overflow-menu")&&(a.backButton.firstChild.textContent="arrow_back",a.eventManager.o(a.backButton,"click",function(){function b(c){return 0==c.classList.contains("shaka-hidden")}WA(a.parent,!0);db(a.parent.childNodes,b)&&eb(a.parent.childNodes,b)[0].focus();uB(a.controls)}))}M("shaka.ui.SettingsMenu",rC);function vC(a,b){rC.call(this,a,b,"language");var c=this;this.button.classList.add("shaka-language-button");this.button.classList.add("shaka-tooltip-status");this.menu.classList.add("shaka-audio-languages");this.eventManager.o(this.localization,"locale-updated",function(){wC(c)});this.eventManager.o(this.localization,"locale-changed",function(){wC(c)});this.eventManager.o(this.player,"trackschanged",function(){var d=0<c.player.kb().length;WA(c.button,d);xC(c)});this.eventManager.o(this.player,"variantchanged",
1453
- function(){xC(c)});wC(this);xC(this)}pa(vC,rC);
1454
- function xC(a){var b=a.player.kb();pC(b,a.menu,function(c){c.channelsCount&&a.controls.g.showAudioChannelCountVariants?a.player.Ee(c.language,c.roles[0],c.channelsCount):a.player.Ee(c.language,c.roles[0])},!0,a.currentSelection,a.localization,a.controls.g.trackLabelFormat,a.controls.g.showAudioChannelCountVariants);UA(a.menu);a.controls.dispatchEvent(new O("languageselectionupdated"));a.button.setAttribute("shaka-status",a.currentSelection.innerText)}
1455
- function wC(a){a.backButton.ariaLabel=a.localization.resolve("BACK");a.button.ariaLabel=a.localization.resolve("LANGUAGE");a.nameSpan.textContent=a.localization.resolve("LANGUAGE");a.backSpan.textContent=a.localization.resolve("LANGUAGE")}M("shaka.ui.AudioLanguageSelection",vC);function yC(){}yC.prototype.create=function(a,b){return new vC(a,b)};aC("language",new yC);AB("language",new yC);function zC(a,b){RA.call(this,a,b);var c=this;this.h=this.controls.C;this.g=Vk();this.g.classList.add("shaka-cast-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.i=U("i");this.i.classList.add("material-icons-round");this.i.textContent="cast";this.g.appendChild(this.i);a=U("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.l=U("span");a.appendChild(this.l);this.j=U("span");this.j.classList.add("shaka-current-selection-span");
1456
- a.appendChild(this.j);this.g.appendChild(a);this.parent.appendChild(this.g);AC(this);BC(this);this.eventManager.o(this.localization,"locale-updated",function(){AC(c)});this.eventManager.o(this.localization,"locale-changed",function(){AC(c)});this.eventManager.o(this.g,"click",function(){CC(c)});this.eventManager.o(this.controls,"caststatuschanged",function(){BC(c)})}pa(zC,RA);
1457
- function CC(a){var b;K(function(c){if(1==c.g){if(a.h.Aa())return a.h.lh(),c.F(0);ta(c,3);a.g.disabled=!0;return D(c,a.h.cast(),5)}if(3!=c.g)return a.g.disabled=!1,va(c,0);b=wa(c);a.g.disabled=!1;8004!=b.code&&a.controls.dispatchEvent(new O("error",(new Map).set("detail",b)));F(c)})}function BC(a){var b=a.h.$e()&&a.controls.sa,c=a.h.Aa();WA(a.g,b);a.i.textContent=c?"cast_connected":"cast";b&&(a.g.ariaPressed=c?"true":"false");DC(a)}
1458
- function DC(a){a.j.textContent=a.h.Aa()?a.h.Ce():a.localization.resolve("OFF")}function AC(a){a.g.ariaLabel=a.localization.resolve("CAST");a.l.textContent=a.localization.resolve("CAST");DC(a)}M("shaka.ui.CastButton",zC);function EC(){}EC.prototype.create=function(a,b){return new zC(a,b)};aC("cast",new EC);AB("cast",new EC);function FC(a,b){RA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("material-icons-round");this.g.classList.add("shaka-fast-forward-button");this.g.classList.add("shaka-tooltip-status");this.g.setAttribute("shaka-status","1x");this.g.textContent="fast_forward";this.parent.appendChild(this.g);GC(this);this.h=this.controls.g.fastForwardRates;this.eventManager.o(this.localization,"locale-updated",function(){GC(c)});this.eventManager.o(this.localization,"locale-changed",function(){GC(c)});
1459
- this.eventManager.o(this.g,"click",function(){if(c.video.duration){var d=c.h.indexOf(c.player.Kb())+1;d=d!=c.h.length?c.h[d]:c.h[0];c.player.Jd(d);c.g.setAttribute("shaka-status",d+"x")}})}pa(FC,RA);function GC(a){a.g.ariaLabel=a.localization.resolve("FAST_FORWARD")}M("shaka.ui.FastForwardButton",FC);function HC(){}HC.prototype.create=function(a,b){return new FC(a,b)};AB("fast_forward",new HC);function IC(a,b){RA.call(this,a,b);var c=this;this.h=this.controls.s;this.g=Vk();this.g.classList.add("shaka-fullscreen-button");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");JC(this);this.g.textContent="fullscreen";this.parent.appendChild(this.g);KC(this);this.eventManager.o(this.localization,"locale-updated",function(){KC(c)});this.eventManager.o(this.localization,"locale-changed",function(){KC(c)});this.eventManager.o(this.g,"click",function(){return K(function(d){return D(d,
1460
- c.controls.pg(),0)})});this.eventManager.o(document,"fullscreenchange",function(){c.g.textContent=c.controls.Lc()?"fullscreen_exit":"fullscreen";KC(c)});this.eventManager.o(this.h,"loadedmetadata",function(){JC(c)});this.eventManager.o(this.h,"loadeddata",function(){JC(c)})}pa(IC,RA);function JC(a){a.controls.ke()?a.g.classList.remove("shaka-hidden"):a.g.classList.add("shaka-hidden")}function KC(a){a.g.ariaLabel=a.localization.resolve(a.controls.Lc()?"EXIT_FULL_SCREEN":"FULL_SCREEN")}
1461
- M("shaka.ui.FullscreenButton",IC);function LC(){}LC.prototype.create=function(a,b){return new IC(a,b)};AB("fullscreen",new LC);function MC(a,b){RA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("shaka-loop-button");this.g.classList.add("shaka-tooltip");this.i=U("i");this.i.classList.add("material-icons-round");this.i.textContent="repeat";this.g.appendChild(this.i);a=U("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=U("span");this.j.textContent=this.localization.resolve("LOOP");a.appendChild(this.j);this.l=U("span");this.l.classList.add("shaka-current-selection-span");
1462
- a.appendChild(this.l);this.g.appendChild(a);NC(this);this.parent.appendChild(this.g);this.eventManager.o(this.localization,"locale-updated",function(){NC(c)});this.eventManager.o(this.localization,"locale-changed",function(){NC(c)});this.eventManager.o(this.g,"click",function(){c.video.loop=!c.video.loop;c.h.Pa();c.h.ya(1)});this.m=this.video.loop;this.h=new vd(function(){c.m!=c.video.loop&&(NC(c),c.m=c.video.loop)});this.h.ya(1)}pa(MC,RA);
1463
- MC.prototype.release=function(){this.h.stop();this.h=null;RA.prototype.release.call(this)};function NC(a){a.j.textContent=a.localization.resolve("LOOP");a.l.textContent=a.localization.resolve(a.video.loop?"ON":"OFF");a.i.textContent=a.video.loop?"repeat_on":"repeat";a.g.ariaLabel=a.localization.resolve(a.video.loop?"EXIT_LOOP_MODE":"ENTER_LOOP_MODE")}M("shaka.ui.LoopButton",MC);function OC(){}OC.prototype.create=function(a,b){return new MC(a,b)};aC("loop",new OC);AB("loop",new OC);gB("loop",new OC);function PC(a,b){RA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("shaka-mute-button");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");this.parent.appendChild(this.g);QC(this);RC(this);this.eventManager.o(this.localization,"locale-updated",function(){QC(c)});this.eventManager.o(this.localization,"locale-changed",function(){QC(c)});this.eventManager.o(this.g,"click",function(){c.ad&&c.ad.isLinear()?c.ad.setMuted(!c.ad.isMuted()):c.video.muted=!c.video.muted});
1464
- this.eventManager.o(this.video,"volumechange",function(){QC(c);RC(c)});this.eventManager.o(this.adManager,"ad-volume-changed",function(){QC(c);RC(c)});this.eventManager.o(this.adManager,"ad-muted",function(){QC(c);RC(c)});this.eventManager.o(this.adManager,"ad-stopped",function(){c.ad=null;QC(c);RC(c)})}pa(PC,RA);function QC(a){var b=a.ad?a.ad.isMuted()?"UNMUTE":"MUTE":a.video.muted?"UNMUTE":"MUTE";a.g.ariaLabel=a.localization.resolve(b)}
1465
- function RC(a){var b=a.ad?a.ad.isMuted()?"volume_off":"volume_up":a.video.muted?"volume_off":"volume_up";a.g.textContent=b}M("shaka.ui.MuteButton",PC);function SC(){}SC.prototype.create=function(a,b){return new PC(a,b)};AB("mute",new SC);function TC(a,b){RA.call(this,a,b);var c=this;this.l=this.controls.s;this.g=Vk();this.g.classList.add("shaka-pip-button");this.g.classList.add("shaka-tooltip");this.i=U("i");this.i.classList.add("material-icons-round");this.i.textContent="picture_in_picture_alt";this.g.appendChild(this.i);a=U("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=U("span");this.j.textContent=this.localization.resolve("PICTURE_IN_PICTURE");a.appendChild(this.j);this.h=
1466
- U("span");this.h.classList.add("shaka-current-selection-span");a.appendChild(this.h);this.g.appendChild(a);UC(this);this.parent.appendChild(this.g);this.controls.Gf()||WA(this.g,!1);this.eventManager.o(this.localization,"locale-updated",function(){UC(c)});this.eventManager.o(this.localization,"locale-changed",function(){UC(c)});this.eventManager.o(this.g,"click",function(){c.controls.Ie()});this.eventManager.o(this.l,"enterpictureinpicture",function(){VC(c)});this.eventManager.o(this.l,"leavepictureinpicture",
1467
- function(){WC(c)});this.eventManager.o(this.controls,"caststatuschanged",function(){XC(c)});this.eventManager.o(this.player,"trackschanged",function(){XC(c)});"documentPictureInPicture"in window&&this.eventManager.o(window.documentPictureInPicture,"enter",function(d){VC(c);c.eventManager.ka(d.window,"pagehide",function(){WC(c)})})}pa(TC,RA);
1468
- function VC(a){a.i.textContent="branding_watermark";a.g.ariaLabel=a.localization.resolve("EXIT_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve("ON")}function WC(a){a.i.textContent="picture_in_picture_alt";a.g.ariaLabel=a.localization.resolve("ENTER_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve("OFF")}
1469
- function UC(a){a.j.textContent=a.localization.resolve("PICTURE_IN_PICTURE");var b=a.controls.le();a.g.ariaLabel=a.localization.resolve(b?"EXIT_PICTURE_IN_PICTURE":"ENTER_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve(b?"ON":"OFF")}function XC(a){K(function(b){if(!a.controls.Gf())return WA(a.g,!1),a.controls.le()?D(b,a.controls.Ie(),0):b.F(0);if(!a.player||!a.player.Kc())return WA(a.g,!0),b.F(0);WA(a.g,!1);return a.controls.le()?D(b,a.controls.Ie(),0):b.F(0)})}M("shaka.ui.PipButton",TC);
1470
- function YC(){}YC.prototype.create=function(a,b){return new TC(a,b)};aC("picture_in_picture",new YC);AB("picture_in_picture",new YC);gB("picture_in_picture",new YC);function ZC(a,b){rC.call(this,a,b,"slow_motion_video");var c=this;this.button.classList.add("shaka-playbackrate-button");this.menu.classList.add("shaka-playback-rates");this.button.classList.add("shaka-tooltip-status");this.eventManager.o(this.localization,"locale-updated",function(){$C(c)});this.eventManager.o(this.localization,"locale-changed",function(){$C(c)});this.eventManager.o(this.player,"loaded",function(){aD(c,c.player.Kb())});this.eventManager.o(this.player,"ratechange",function(){aD(c,
1471
- c.player.Kb())});this.g=new Map(this.controls.g.playbackRates.map(function(d){return[d+"x",d]}));$C(this);bD(this);aD(this,this.player.Kb())}pa(ZC,rC);function $C(a){a.backButton.ariaLabel=a.localization.resolve("BACK");a.button.ariaLabel=a.localization.resolve("PLAYBACK_RATE");a.nameSpan.textContent=a.localization.resolve("PLAYBACK_RATE");a.backSpan.textContent=a.localization.resolve("PLAYBACK_RATE")}
1472
- function aD(a,b){var c=TA(a.menu,"material-icons-round shaka-chosen-item");if(c){var d=c.parentElement;d.removeAttribute("aria-selected");d.getElementsByTagName("span")[0].classList.remove("shaka-chosen-item");d.removeChild(c)}if(c=Array.from(a.menu.querySelectorAll("span")).find(function(e){return a.g.get(e.textContent)==b}))d=c.parentElement,d.appendChild(VA()),d.ariaSelected="true",c.classList.add("shaka-chosen-item");a.currentSelection.textContent=b+"x";a.button.setAttribute("shaka-status",b+
1473
- "x")}function bD(a){for(var b={},c=t(a.g.keys()),d=c.next();!d.done;b={Yc:b.Yc},d=c.next()){b.Yc=d.value;d=Vk();var e=U("span");e.textContent=b.Yc;d.appendChild(e);a.eventManager.o(d,"click",function(f){return function(){a.video.playbackRate=a.g.get(f.Yc);a.video.defaultPlaybackRate=a.g.get(f.Yc)}}(b));a.menu.appendChild(d)}UA(a.menu)}M("shaka.ui.PlaybackRateSelection",ZC);function cD(){}cD.prototype.create=function(a,b){return new ZC(a,b)};aC("playback_rate",new cD);AB("playback_rate",new cD);function dD(a,b){RA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("shaka-current-time");eD(this,"0:00");this.parent.appendChild(this.g);this.eventManager.o(this.g,"click",function(){c.player.R()&&(c.video.currentTime=c.player.Fa().end)});this.eventManager.o(this.controls,"timeandseekrangeupdated",function(){var d=c.controls.V,e=c.controls.Mg(),f=c.player.Fa(),g=f.end-f.start;c.player.R()?(e=Math.max(0,Math.floor(f.end-e)),g=3600<=g,1<=e||d?(eD(c,"- "+XA(e,g)),c.g.disabled=!1):(eD(c,c.localization.resolve("LIVE")),
1474
- c.g.disabled=!0)):(d=3600<=g,e=XA(Math.max(0,e-f.start),d),g&&(e+=" / "+XA(g,d)),eD(c,e),c.g.disabled=!0)});this.eventManager.o(this.player,"trackschanged",function(){c.player.R()&&(c.g.ariaLabel=c.localization.resolve("SKIP_TO_LIVE"))})}pa(dD,RA);function eD(a,b){b!=a.g.textContent&&(a.g.textContent=b)}M("shaka.ui.PresentationTimeTracker",dD);function fD(){}fD.prototype.create=function(a,b){return new dD(a,b)};AB("time_and_duration",new fD);function gD(a,b){RA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("shaka-remote-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.i=U("i");this.i.classList.add("material-icons-round");a="cast";(b=Jd())&&13<=b&&(a="airplay");this.i.textContent=a;this.g.appendChild(this.i);a=U("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.l=U("span");a.appendChild(this.l);this.j=U("span");this.j.classList.add("shaka-current-selection-span");
1475
- a.appendChild(this.j);this.g.appendChild(a);this.parent.appendChild(this.g);this.h=-1;hD(this);WA(this.g,!1);!this.video.remote||this.video.disableRemotePlayback?this.g.classList.add("shaka-hidden"):(this.eventManager.o(this.localization,"locale-updated",function(){hD(c)}),this.eventManager.o(this.localization,"locale-changed",function(){hD(c)}),this.eventManager.o(this.controls,"caststatuschanged",function(){iD(c)}),this.eventManager.o(this.g,"click",function(){c.video.remote.prompt()}),this.eventManager.o(this.video.remote,
1476
- "connect",function(){iD(c)}),this.eventManager.o(this.video.remote,"connecting",function(){iD(c)}),this.eventManager.o(this.video.remote,"disconnect",function(){iD(c)}),this.eventManager.o(this.player,"loaded",function(){iD(c)}),iD(this))}pa(gD,RA);gD.prototype.release=function(){this.video.remote&&-1!=this.h&&this.video.remote.cancelWatchAvailability(this.h).catch(function(){});RA.prototype.release.call(this)};
1477
- function iD(a){var b,c;K(function(d){switch(d.g){case 1:if(a.controls.C.$e()&&a.controls.sa){WA(a.g,!1);-1!=a.h&&(a.video.remote.cancelWatchAvailability(a.h),a.h=-1);d.F(0);break}if("disconnected"==a.video.remote.state){b=function(e){a.player?WA(a.g,a.player.ae()==Xm&&e):WA(a.g,!1)};ta(d,7);if(-1==a.h){d.F(9);break}return D(d,a.video.remote.cancelWatchAvailability(a.h),10)}if(-1==a.h){d.F(0);break}return D(d,a.video.remote.cancelWatchAvailability(a.h),6);case 6:a.h=-1;d.F(0);break;case 10:a.h=-1;
1478
- case 9:va(d,8);break;case 7:wa(d);case 8:return ta(d,11),D(d,a.video.remote.watchAvailability(b),13);case 13:c=d.h;a.h=c;va(d,0);break;case 11:wa(d),b(!0),F(d)}})}function hD(a){var b=a.localization.resolve("CAST"),c=Jd();c&&13<=c&&(b=a.localization.resolve("AIRPLAY"));a.g.ariaLabel=b;a.l.textContent=b}M("shaka.ui.RemoteButton",gD);function jD(){}jD.prototype.create=function(a,b){return new gD(a,b)};aC("remote",new jD);AB("remote",new jD);function kD(a,b){rC.call(this,a,b,"settings");var c=this;this.button.classList.add("shaka-resolution-button");this.button.classList.add("shaka-tooltip-status");this.menu.classList.add("shaka-resolutions");this.eventManager.o(this.localization,"locale-updated",function(){lD(c)});this.eventManager.o(this.localization,"locale-changed",function(){lD(c)});this.eventManager.o(this.player,"variantchanged",function(){mD(c)});this.eventManager.o(this.player,"trackschanged",function(){mD(c)});this.eventManager.o(this.player,
1479
- "abrstatuschanged",function(){mD(c)});mD(this)}pa(kD,rC);
1480
- function mD(a){var b=[];a.player.ae()!=Xm&&(b=a.player.kb());var c=b.find(function(k){return k.active});c&&(b=b.filter(function(k){return k.language==c.language&&k.channelsCount==c.channelsCount}));b=b.filter(function(k,l){var m=-1;m=a.player.Kc()?b.findIndex(function(n){return n.bandwidth==k.bandwidth}):b.findIndex(function(n){return n.height==k.height&&n.frameRate==k.frameRate&&n.hdr==k.hdr&&n.videoLayout==k.videoLayout});return m==l});a.player.Kc()?b.sort(function(k,l){return l.bandwidth-k.bandwidth}):
1481
- b.sort(function(k,l){return l.height-k.height});var d=SA(a.menu);Wk(a.menu);a.menu.appendChild(d);d=a.player.getConfiguration().abr.enabled;for(var e={},f=t(b),g=f.next();!g.done;e={Eb:e.Eb},g=f.next()){e.Eb=g.value;g=Vk();g.classList.add("explicit-resolution");a.eventManager.o(g,"click",function(k){return function(){var l=k.Eb;a.player.configure({abr:{enabled:!1}});a.player.Fe(l,a.controls.g.clearBufferOnQualityChange)}}(e));var h=U("span");h.textContent=a.player.Kc()&&e.Eb.bandwidth?Math.round(e.Eb.bandwidth/
1482
- 1E3)+" kbits/s":e.Eb.height&&e.Eb.width?nD(e.Eb):"Unknown";g.appendChild(h);d||e.Eb!=c||(g.ariaSelected="true",g.appendChild(VA()),h.classList.add("shaka-chosen-item"),a.currentSelection.textContent=h.textContent);a.menu.appendChild(g)}e=Vk();e.classList.add("shaka-enable-abr-button");a.eventManager.o(e,"click",function(){a.player.configure({abr:{enabled:!0}});mD(a)});a.g=U("span");a.g.classList.add("shaka-auto-span");a.g.textContent=a.localization.resolve("AUTO_QUALITY");e.appendChild(a.g);d&&(e.ariaSelected=
1483
- "true",e.appendChild(VA()),a.g.classList.add("shaka-chosen-item"),a.currentSelection.textContent=a.localization.resolve("AUTO_QUALITY"));a.button.setAttribute("shaka-status",a.currentSelection.textContent);a.menu.appendChild(e);UA(a.menu);a.controls.dispatchEvent(new O("resolutionselectionupdated"));lD(a)}
1484
- function nD(a){var b=a.height||0,c=a.width||0,d=b;c/b>16/9&&(d=Math.round(9*c/16));b=d+"p";2160==d&&(b="4K");(d=a.frameRate)&&(50<=d||20>=d)&&(b+=Math.round(a.frameRate));if("PQ"==a.hdr||"HLG"==a.hdr)b+=" (HDR)";"CH-STEREO"==a.videoLayout&&(b+=" (3D)");return b}
1485
- function lD(a){var b=a.player.Kc()?"QUALITY":"RESOLUTION";a.button.ariaLabel=a.localization.resolve(b);a.backButton.ariaLabel=a.localization.resolve(b);a.backSpan.textContent=a.localization.resolve(b);a.nameSpan.textContent=a.localization.resolve(b);a.g.textContent=a.localization.resolve("AUTO_QUALITY");a.player.getConfiguration().abr.enabled&&(a.currentSelection.textContent=a.localization.resolve("AUTO_QUALITY"))}M("shaka.ui.ResolutionSelection",kD);function oD(){}
1486
- oD.prototype.create=function(a,b){return new kD(a,b)};aC("quality",new oD);AB("quality",new oD);function pD(a,b){RA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("material-icons-round");this.g.classList.add("shaka-rewind-button");this.g.classList.add("shaka-tooltip-status");this.g.setAttribute("shaka-status",this.localization.resolve("OFF"));this.g.textContent="fast_rewind";this.parent.appendChild(this.g);qD(this);this.h=this.controls.g.rewindRates;this.eventManager.o(this.localization,"locale-updated",function(){qD(c)});this.eventManager.o(this.localization,"locale-changed",function(){qD(c)});
1487
- this.eventManager.o(this.g,"click",function(){if(c.video.duration){var d=c.h.indexOf(c.player.Kb())+1;d=d!=c.h.length?c.h[d]:c.h[0];c.player.Jd(d);c.g.setAttribute("shaka-status",d+"x")}})}pa(pD,RA);function qD(a){a.g.ariaLabel=a.localization.resolve("REWIND")}M("shaka.ui.RewindButton",pD);function rD(){}rD.prototype.create=function(a,b){return new pD(a,b)};AB("rewind",new rD);function sD(a,b){RA.call(this,a,b);var c=this;this.j=U("div");this.j.classList.add("shaka-skip-ad-container");this.parent.appendChild(this.j);this.h=U("div");this.h.classList.add("shaka-skip-ad-counter");WA(this.h,!1);this.j.appendChild(this.h);this.g=Vk();this.g.classList.add("shaka-skip-ad-button");this.g.disabled=!0;WA(this.g,!1);this.g.classList.add("shaka-no-propagation");this.j.appendChild(this.g);tD(this);this.i=new vd(function(){var d=Math.round(c.ad.getTimeUntilSkippable());0<d?c.h.textContent=
1488
- d:(c.i.stop(),WA(c.h,!1))});this.eventManager.o(this.localization,"locale-updated",function(){tD(c)});this.eventManager.o(this.localization,"locale-changed",function(){tD(c)});this.eventManager.o(this.adManager,"ad-started",function(){uD(c)});this.eventManager.o(this.adManager,"ad-skip-state-changed",function(){c.ad.canSkipNow()&&(c.g.disabled=!1,c.i.stop(),WA(c.h,!1))});this.eventManager.o(this.adManager,"ad-stopped",function(){c.i.stop();c.g.disabled=!0;WA(c.g,!1);WA(c.h,!1)});this.eventManager.o(this.g,
1489
- "click",function(){c.ad.skip()});this.ad&&uD(this)}pa(sD,RA);sD.prototype.release=function(){this.i.stop();this.i=null;RA.prototype.release.call(this)};function tD(a){a.g.textContent=a.localization.resolve("SKIP_AD")}function uD(a){a.ad.isSkippable()&&(WA(a.g,!0),WA(a.h,!0),a.h.textContent="",a.i.Pa(),a.i.ya(.5))}M("shaka.ui.SkipAdButton",sD);function vD(a,b){aB.call(this,a,b);this.button.classList.add("shaka-small-play-button");this.button.classList.add("material-icons-round");this.button.classList.add("shaka-tooltip");this.h();this.g()}pa(vD,aB);vD.prototype.h=function(){this.isEnded()?this.button.textContent="replay":this.button.textContent=this.isPaused()?"play_arrow":"pause"};
1490
- vD.prototype.g=function(){if(this.isEnded())this.button.ariaLabel=this.localization.resolve("REPLAY");else{var a=this.isPaused()?"PLAY":"PAUSE";this.button.ariaLabel=this.localization.resolve(a)}};M("shaka.ui.SmallPlayButton",vD);function wD(){}wD.prototype.create=function(a,b){return new vD(a,b)};AB("play_pause",new wD);function xD(a,b){RA.call(this,a,b);a=U("div");a.classList.add("shaka-spacer");a.ariaHidden="true";this.parent.appendChild(a)}pa(xD,RA);M("shaka.ui.Spacer",xD);function yD(){}yD.prototype.create=function(a,b){return new xD(a,b)};AB("spacer",new yD);function zD(a,b){function c(k){return XA(h.h[k],!1)+" (m)"}function d(k){return Math.round(h.h[k]/1E3)+" (kbits/s)"}function e(k){return h.h[k].toFixed(2)+" (s)"}function f(k){return h.h[k]+" (frames)"}function g(k){return h.h[k]+" (px)"}RA.call(this,a,b);var h=this;this.i=Vk();this.i.classList.add("shaka-statistics-button");this.j=U("i");this.j.classList.add("material-icons-round");this.j.textContent="insert_chart_outlined";this.i.appendChild(this.j);a=U("label");a.classList.add("shaka-overflow-button-label");
1440
+ function jC(){var a,b,c,d,e,f,g,h,k,l,m,n,q,r,u,v,y,z,x,A,B;return K(function(C){switch(C.g){case 1:Xw();if(!cm())return kC("shaka-ui-load-failed",lC),C.return();a=document.querySelectorAll("[data-shaka-player-container]");b=document.querySelectorAll("[data-shaka-player]");c=document.querySelectorAll("[data-shaka-player-canvas]");if(!b.length&&!a.length){C.F(2);break}if(b.length&&!a.length){d=t(b);for(e=d.next();!e.done;e=d.next())if(f=e.value,!f.ui){g=document.createElement("div");h=f.parentElement;
1441
+ h.replaceChild(g,f);g.appendChild(f);k=null;l=t(c);for(m=l.next();!m.done;m=l.next())if(n=m.value,n.parentElement==g){k=n;break}k||(k=document.createElement("canvas"),k.classList.add("shaka-canvas-container"),g.appendChild(k));mC(g,f,k)}C.F(2);break}q=t(a);r=q.next();case 4:if(r.done){C.F(2);break}u=r.value;if(u.ui){C.F(5);break}v=null;y=t(b);for(e=y.next();!e.done;e=y.next())if(z=e.value,z.parentElement==u){v=z;break}v||(v=document.createElement("video"),v.setAttribute("playsinline",""),u.appendChild(v));
1442
+ x=null;A=t(c);for(m=A.next();!m.done;m=A.next())if(B=m.value,B.parentElement==u){x=B;break}x||(x=document.createElement("canvas"),x.classList.add("shaka-canvas-container"),u.appendChild(x));ta(C,7);return D(C,mC(u,v,x),9);case 9:va(C,5);break;case 7:return wa(C),kC("shaka-ui-load-failed",nC),C.return();case 5:r=q.next();C.F(4);break;case 2:kC("shaka-ui-loaded"),F(C)}})}function kC(a,b){var c=null;void 0!=b&&(c={reasonCode:b});a=new CustomEvent(a,{detail:c});document.dispatchEvent(a)}
1443
+ function mC(a,b,c){var d,e,f,g,h,k,l,m,n;return K(function(q){switch(q.g){case 1:d=new V;e=new gC(d,a,b);d.yg(c);f="";g=!1;a.dataset&&a.dataset.shakaPlayerCastReceiverId?(f=a.dataset.shakaPlayerCastReceiverId,g="true"===a.dataset.shakaPlayerCastAndroidReceiverCompatible):b.dataset&&b.dataset.shakaPlayerCastReceiverId&&(f=b.dataset.shakaPlayerCastReceiverId,g="true"===b.dataset.shakaPlayerCastAndroidReceiverCompatible);f.length&&e.configure({castReceiverAppId:f,castAndroidReceiverCompatible:g});b.controls&&
1444
+ e.g.gh(!0);if(h=b.getAttribute("src"))k=document.createElement("source"),k.setAttribute("src",h),b.appendChild(k),b.removeAttribute("src");l=t(b.querySelectorAll("source"));m=l.next();case 2:if(m.done){q.F(4);break}n=m.value;ta(q,5);return D(q,e.g.Gc().load(n.getAttribute("src")),7);case 7:q.F(4);break;case 5:wa(q);case 3:m=l.next();q.F(2);break;case 4:return D(q,d.Ac(b),0)}})}M("shaka.ui.Overlay",gC);gC.prototype.setEnabled=gC.prototype.hj;gC.prototype.getControls=gC.prototype.Ph;
1445
+ gC.prototype.configure=gC.prototype.configure;gC.prototype.getConfiguration=gC.prototype.getConfiguration;gC.prototype.isMobile=gC.prototype.Ff;gC.prototype.destroy=gC.prototype.destroy;var iC=0;gC.TrackLabelFormat={LANGUAGE:iC,ROLE:1,LANGUAGE_ROLE:2,LABEL:3};var lC=0,nC=1;gC.FailReasonCode={NO_BROWSER_SUPPORT:lC,PLAYER_FAILED_TO_LOAD:nC};"complete"==document.readyState?K(function(a){if(1==a.g)return D(a,Promise.resolve(),2);jC();F(a)}):window.addEventListener("load",jC);function oC(a,b,c,d,e,f,g,h){function k(H){var G="";5<=H&&(G=" "+f.resolve("SURROUND"));return G}function l(H,G,I,J){H=[H,G];h&&null!=J&&H.push(J);I&&3==g&&H.push(I);return H.join(": ")}function m(H){return"variant"==H.type?H.audioRoles?H.audioRoles.join(", "):void 0:H.roles.join(", ")}var n=a.find(function(H){return 1==H.active}),q=RA(b);Wk(b);b.appendChild(q);q=new Map;for(var r=t(a),u=r.next();!u.done;u=r.next())u=u.value,q.has(u.language)||q.set(u.language,new Set),q.get(u.language).add(m(u));
1446
+ q=new Set;n=n?l(n.language,m(n),n.label,n.channelsCount):"";r={};a=t(a);for(u=a.next();!u.done;r={ub:r.ub},u=a.next()){r.ub=u.value;u=r.ub.language;var v=r.ub.forced,y=f.resolve("SUBTITLE_FORCED"),z=m(r.ub),x=r.ub.label,A=r.ub.channelsCount,B=l(u,z,x,A);if(!q.has(B)){q.add(B);var C=Vk();C.addEventListener("click",function(H){return function(){c(H.ub)}}(r));var E=U("span");C.appendChild(E);E.textContent=pC(u,f);switch(g){case iC:h&&(E.textContent+=k(A));v&&(E.textContent+=" ("+y+")");break;case 1:h&&
1447
+ (E.textContent+=k(A));z?E.textContent=z:(Sa("Track #"+r.ub.id+" does not have a role, but the UI is configured to only show role."),E.textContent="?");v&&(E.textContent+=" ("+y+")");break;case 2:h&&(E.textContent+=k(A));z&&(E.textContent+=": "+z);v&&(E.textContent+=" ("+y+")");break;case 3:x?E.textContent=x:(Sa("Track #"+r.ub.id+" does not have a label, but the UI is configured to only show labels."),E.textContent="?")}d&&B==n&&(C.appendChild(UA()),E.classList.add("shaka-chosen-item"),C.ariaSelected=
1448
+ "true",e.textContent=E.textContent);b.appendChild(C)}}}function pC(a,b){if(!a&&!b)return"";switch(a){case "mul":return b.resolve("MULTIPLE_LANGUAGES");case "und":return b.resolve("UNDETERMINED_LANGUAGE");case "zxx":return b.resolve("NOT_APPLICABLE")}var c=Sb(a);return a in MA?MA[a].A:c in MA?MA[c].A+" ("+a+")":b.resolve("UNRECOGNIZED_LANGUAGE")+" ("+a+")"};function qC(a,b,c){QA.call(this,a,b);var d=this;rC(this,c);sC(this);tC(this);this.eventManager.o(this.button,"click",function(){d.menu.classList.contains("shaka-hidden")?(d.controls.dispatchEvent(new O("submenuopen")),VA(d.menu,!0),TA(d.menu)):VA(d.menu,!1)})}pa(qC,QA);
1449
+ function rC(a,b){a.button=Vk();a.button.classList.add("shaka-overflow-button");a.icon=U("i");a.icon.classList.add("material-icons-round");a.icon.textContent=b;a.button.appendChild(a.icon);b=U("label");b.classList.add("shaka-overflow-button-label");b.classList.add("shaka-overflow-menu-only");a.nameSpan=U("span");b.appendChild(a.nameSpan);a.currentSelection=U("span");a.currentSelection.classList.add("shaka-current-selection-span");b.appendChild(a.currentSelection);a.button.appendChild(b);a.parent.appendChild(a.button)}
1450
+ function sC(a){a.menu=U("div");a.menu.classList.add("shaka-no-propagation");a.menu.classList.add("shaka-show-controls-on-mouse-over");a.menu.classList.add("shaka-settings-menu");a.menu.classList.add("shaka-hidden");a.backButton=Vk();a.backButton.classList.add("shaka-back-to-overflow-button");a.menu.appendChild(a.backButton);a.eventManager.o(a.backButton,"click",function(){a.controls.Jc()});var b=U("i");b.classList.add("material-icons-round");b.textContent="close";a.backButton.appendChild(b);a.backSpan=
1451
+ U("span");a.backButton.appendChild(a.backSpan);a.controls.h.appendChild(a.menu)}function tC(a){a.parent.classList.contains("shaka-overflow-menu")&&(a.backButton.firstChild.textContent="arrow_back",a.eventManager.o(a.backButton,"click",function(){function b(c){return 0==c.classList.contains("shaka-hidden")}VA(a.parent,!0);db(a.parent.childNodes,b)&&eb(a.parent.childNodes,b)[0].focus();tB(a.controls)}))}M("shaka.ui.SettingsMenu",qC);function uC(a,b){qC.call(this,a,b,"language");var c=this;this.button.classList.add("shaka-language-button");this.button.classList.add("shaka-tooltip-status");this.menu.classList.add("shaka-audio-languages");this.eventManager.o(this.localization,"locale-updated",function(){vC(c)});this.eventManager.o(this.localization,"locale-changed",function(){vC(c)});this.eventManager.o(this.player,"trackschanged",function(){var d=0<c.player.kb().length;VA(c.button,d);wC(c)});this.eventManager.o(this.player,"variantchanged",
1452
+ function(){wC(c)});vC(this);wC(this)}pa(uC,qC);
1453
+ function wC(a){var b=a.player.kb();oC(b,a.menu,function(c){c.channelsCount&&a.controls.g.showAudioChannelCountVariants?a.player.Ee(c.language,c.roles[0],c.channelsCount):a.player.Ee(c.language,c.roles[0])},!0,a.currentSelection,a.localization,a.controls.g.trackLabelFormat,a.controls.g.showAudioChannelCountVariants);TA(a.menu);a.controls.dispatchEvent(new O("languageselectionupdated"));a.button.setAttribute("shaka-status",a.currentSelection.innerText)}
1454
+ function vC(a){a.backButton.ariaLabel=a.localization.resolve("BACK");a.button.ariaLabel=a.localization.resolve("LANGUAGE");a.nameSpan.textContent=a.localization.resolve("LANGUAGE");a.backSpan.textContent=a.localization.resolve("LANGUAGE")}M("shaka.ui.AudioLanguageSelection",uC);function xC(){}xC.prototype.create=function(a,b){return new uC(a,b)};$B("language",new xC);zB("language",new xC);function yC(a,b){QA.call(this,a,b);var c=this;this.h=this.controls.C;this.g=Vk();this.g.classList.add("shaka-cast-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.i=U("i");this.i.classList.add("material-icons-round");this.i.textContent="cast";this.g.appendChild(this.i);a=U("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.l=U("span");a.appendChild(this.l);this.j=U("span");this.j.classList.add("shaka-current-selection-span");
1455
+ a.appendChild(this.j);this.g.appendChild(a);this.parent.appendChild(this.g);zC(this);AC(this);this.eventManager.o(this.localization,"locale-updated",function(){zC(c)});this.eventManager.o(this.localization,"locale-changed",function(){zC(c)});this.eventManager.o(this.g,"click",function(){BC(c)});this.eventManager.o(this.controls,"caststatuschanged",function(){AC(c)})}pa(yC,QA);
1456
+ function BC(a){var b;K(function(c){if(1==c.g){if(a.h.Aa())return a.h.lh(),c.F(0);ta(c,3);a.g.disabled=!0;return D(c,a.h.cast(),5)}if(3!=c.g)return a.g.disabled=!1,va(c,0);b=wa(c);a.g.disabled=!1;8004!=b.code&&a.controls.dispatchEvent(new O("error",(new Map).set("detail",b)));F(c)})}function AC(a){var b=a.h.$e()&&a.controls.sa,c=a.h.Aa();VA(a.g,b);a.i.textContent=c?"cast_connected":"cast";b&&(a.g.ariaPressed=c?"true":"false");CC(a)}
1457
+ function CC(a){a.j.textContent=a.h.Aa()?a.h.Ce():a.localization.resolve("OFF")}function zC(a){a.g.ariaLabel=a.localization.resolve("CAST");a.l.textContent=a.localization.resolve("CAST");CC(a)}M("shaka.ui.CastButton",yC);function DC(){}DC.prototype.create=function(a,b){return new yC(a,b)};$B("cast",new DC);zB("cast",new DC);function EC(a,b){QA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("material-icons-round");this.g.classList.add("shaka-fast-forward-button");this.g.classList.add("shaka-tooltip-status");this.g.setAttribute("shaka-status","1x");this.g.textContent="fast_forward";this.parent.appendChild(this.g);FC(this);this.h=this.controls.g.fastForwardRates;this.eventManager.o(this.localization,"locale-updated",function(){FC(c)});this.eventManager.o(this.localization,"locale-changed",function(){FC(c)});
1458
+ this.eventManager.o(this.g,"click",function(){if(c.video.duration){var d=c.h.indexOf(c.player.Lb())+1;d=d!=c.h.length?c.h[d]:c.h[0];c.player.Jd(d);c.g.setAttribute("shaka-status",d+"x")}})}pa(EC,QA);function FC(a){a.g.ariaLabel=a.localization.resolve("FAST_FORWARD")}M("shaka.ui.FastForwardButton",EC);function GC(){}GC.prototype.create=function(a,b){return new EC(a,b)};zB("fast_forward",new GC);function HC(a,b){QA.call(this,a,b);var c=this;this.h=this.controls.s;this.g=Vk();this.g.classList.add("shaka-fullscreen-button");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");IC(this);this.g.textContent="fullscreen";this.parent.appendChild(this.g);JC(this);this.eventManager.o(this.localization,"locale-updated",function(){JC(c)});this.eventManager.o(this.localization,"locale-changed",function(){JC(c)});this.eventManager.o(this.g,"click",function(){return K(function(d){return D(d,
1459
+ c.controls.pg(),0)})});this.eventManager.o(document,"fullscreenchange",function(){c.g.textContent=c.controls.Lc()?"fullscreen_exit":"fullscreen";JC(c)});this.eventManager.o(this.h,"loadedmetadata",function(){IC(c)});this.eventManager.o(this.h,"loadeddata",function(){IC(c)})}pa(HC,QA);function IC(a){a.controls.ke()?a.g.classList.remove("shaka-hidden"):a.g.classList.add("shaka-hidden")}function JC(a){a.g.ariaLabel=a.localization.resolve(a.controls.Lc()?"EXIT_FULL_SCREEN":"FULL_SCREEN")}
1460
+ M("shaka.ui.FullscreenButton",HC);function KC(){}KC.prototype.create=function(a,b){return new HC(a,b)};zB("fullscreen",new KC);function LC(a,b){QA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("shaka-loop-button");this.g.classList.add("shaka-tooltip");this.i=U("i");this.i.classList.add("material-icons-round");this.i.textContent="repeat";this.g.appendChild(this.i);a=U("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=U("span");this.j.textContent=this.localization.resolve("LOOP");a.appendChild(this.j);this.l=U("span");this.l.classList.add("shaka-current-selection-span");
1461
+ a.appendChild(this.l);this.g.appendChild(a);MC(this);this.parent.appendChild(this.g);this.eventManager.o(this.localization,"locale-updated",function(){MC(c)});this.eventManager.o(this.localization,"locale-changed",function(){MC(c)});this.eventManager.o(this.g,"click",function(){c.video.loop=!c.video.loop;c.h.Pa();c.h.ya(1)});this.m=this.video.loop;this.h=new vd(function(){c.m!=c.video.loop&&(MC(c),c.m=c.video.loop)});this.h.ya(1)}pa(LC,QA);
1462
+ LC.prototype.release=function(){this.h.stop();this.h=null;QA.prototype.release.call(this)};function MC(a){a.j.textContent=a.localization.resolve("LOOP");a.l.textContent=a.localization.resolve(a.video.loop?"ON":"OFF");a.i.textContent=a.video.loop?"repeat_on":"repeat";a.g.ariaLabel=a.localization.resolve(a.video.loop?"EXIT_LOOP_MODE":"ENTER_LOOP_MODE")}M("shaka.ui.LoopButton",LC);function NC(){}NC.prototype.create=function(a,b){return new LC(a,b)};$B("loop",new NC);zB("loop",new NC);fB("loop",new NC);function OC(a,b){QA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("shaka-mute-button");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");this.parent.appendChild(this.g);PC(this);QC(this);this.eventManager.o(this.localization,"locale-updated",function(){PC(c)});this.eventManager.o(this.localization,"locale-changed",function(){PC(c)});this.eventManager.o(this.g,"click",function(){c.ad&&c.ad.isLinear()?c.ad.setMuted(!c.ad.isMuted()):c.video.muted=!c.video.muted});
1463
+ this.eventManager.o(this.video,"volumechange",function(){PC(c);QC(c)});this.eventManager.o(this.adManager,"ad-volume-changed",function(){PC(c);QC(c)});this.eventManager.o(this.adManager,"ad-muted",function(){PC(c);QC(c)});this.eventManager.o(this.adManager,"ad-stopped",function(){c.ad=null;PC(c);QC(c)})}pa(OC,QA);function PC(a){var b=a.ad?a.ad.isMuted()?"UNMUTE":"MUTE":a.video.muted?"UNMUTE":"MUTE";a.g.ariaLabel=a.localization.resolve(b)}
1464
+ function QC(a){var b=a.ad?a.ad.isMuted()?"volume_off":"volume_up":a.video.muted?"volume_off":"volume_up";a.g.textContent=b}M("shaka.ui.MuteButton",OC);function RC(){}RC.prototype.create=function(a,b){return new OC(a,b)};zB("mute",new RC);function SC(a,b){QA.call(this,a,b);var c=this;this.l=this.controls.s;this.g=Vk();this.g.classList.add("shaka-pip-button");this.g.classList.add("shaka-tooltip");this.i=U("i");this.i.classList.add("material-icons-round");this.i.textContent="picture_in_picture_alt";this.g.appendChild(this.i);a=U("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.j=U("span");this.j.textContent=this.localization.resolve("PICTURE_IN_PICTURE");a.appendChild(this.j);this.h=
1465
+ U("span");this.h.classList.add("shaka-current-selection-span");a.appendChild(this.h);this.g.appendChild(a);TC(this);this.parent.appendChild(this.g);this.controls.Gf()||VA(this.g,!1);this.eventManager.o(this.localization,"locale-updated",function(){TC(c)});this.eventManager.o(this.localization,"locale-changed",function(){TC(c)});this.eventManager.o(this.g,"click",function(){c.controls.Ie()});this.eventManager.o(this.l,"enterpictureinpicture",function(){UC(c)});this.eventManager.o(this.l,"leavepictureinpicture",
1466
+ function(){VC(c)});this.eventManager.o(this.controls,"caststatuschanged",function(){WC(c)});this.eventManager.o(this.player,"trackschanged",function(){WC(c)});"documentPictureInPicture"in window&&this.eventManager.o(window.documentPictureInPicture,"enter",function(d){UC(c);c.eventManager.ka(d.window,"pagehide",function(){VC(c)})})}pa(SC,QA);
1467
+ function UC(a){a.i.textContent="branding_watermark";a.g.ariaLabel=a.localization.resolve("EXIT_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve("ON")}function VC(a){a.i.textContent="picture_in_picture_alt";a.g.ariaLabel=a.localization.resolve("ENTER_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve("OFF")}
1468
+ function TC(a){a.j.textContent=a.localization.resolve("PICTURE_IN_PICTURE");var b=a.controls.le();a.g.ariaLabel=a.localization.resolve(b?"EXIT_PICTURE_IN_PICTURE":"ENTER_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve(b?"ON":"OFF")}function WC(a){K(function(b){if(!a.controls.Gf())return VA(a.g,!1),a.controls.le()?D(b,a.controls.Ie(),0):b.F(0);if(!a.player||!a.player.Kc())return VA(a.g,!0),b.F(0);VA(a.g,!1);return a.controls.le()?D(b,a.controls.Ie(),0):b.F(0)})}M("shaka.ui.PipButton",SC);
1469
+ function XC(){}XC.prototype.create=function(a,b){return new SC(a,b)};$B("picture_in_picture",new XC);zB("picture_in_picture",new XC);fB("picture_in_picture",new XC);function YC(a,b){qC.call(this,a,b,"slow_motion_video");var c=this;this.button.classList.add("shaka-playbackrate-button");this.menu.classList.add("shaka-playback-rates");this.button.classList.add("shaka-tooltip-status");this.eventManager.o(this.localization,"locale-updated",function(){ZC(c)});this.eventManager.o(this.localization,"locale-changed",function(){ZC(c)});this.eventManager.o(this.player,"loaded",function(){$C(c,c.player.Lb())});this.eventManager.o(this.player,"ratechange",function(){$C(c,
1470
+ c.player.Lb())});this.g=new Map(this.controls.g.playbackRates.map(function(d){return[d+"x",d]}));ZC(this);aD(this);$C(this,this.player.Lb())}pa(YC,qC);function ZC(a){a.backButton.ariaLabel=a.localization.resolve("BACK");a.button.ariaLabel=a.localization.resolve("PLAYBACK_RATE");a.nameSpan.textContent=a.localization.resolve("PLAYBACK_RATE");a.backSpan.textContent=a.localization.resolve("PLAYBACK_RATE")}
1471
+ function $C(a,b){var c=SA(a.menu,"material-icons-round shaka-chosen-item");if(c){var d=c.parentElement;d.removeAttribute("aria-selected");d.getElementsByTagName("span")[0].classList.remove("shaka-chosen-item");d.removeChild(c)}if(c=Array.from(a.menu.querySelectorAll("span")).find(function(e){return a.g.get(e.textContent)==b}))d=c.parentElement,d.appendChild(UA()),d.ariaSelected="true",c.classList.add("shaka-chosen-item");a.currentSelection.textContent=b+"x";a.button.setAttribute("shaka-status",b+
1472
+ "x")}function aD(a){for(var b={},c=t(a.g.keys()),d=c.next();!d.done;b={Yc:b.Yc},d=c.next()){b.Yc=d.value;d=Vk();var e=U("span");e.textContent=b.Yc;d.appendChild(e);a.eventManager.o(d,"click",function(f){return function(){a.video.playbackRate=a.g.get(f.Yc);a.video.defaultPlaybackRate=a.g.get(f.Yc)}}(b));a.menu.appendChild(d)}TA(a.menu)}M("shaka.ui.PlaybackRateSelection",YC);function bD(){}bD.prototype.create=function(a,b){return new YC(a,b)};$B("playback_rate",new bD);zB("playback_rate",new bD);function cD(a,b){QA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("shaka-current-time");dD(this,"0:00");this.parent.appendChild(this.g);this.eventManager.o(this.g,"click",function(){c.player.R()&&(c.video.currentTime=c.player.Fa().end)});this.eventManager.o(this.controls,"timeandseekrangeupdated",function(){var d=c.controls.V,e=c.controls.Mg(),f=c.player.Fa(),g=f.end-f.start;c.player.R()?(e=Math.max(0,Math.floor(f.end-e)),g=3600<=g,1<=e||d?(dD(c,"- "+WA(e,g)),c.g.disabled=!1):(dD(c,c.localization.resolve("LIVE")),
1473
+ c.g.disabled=!0)):(d=3600<=g,e=WA(Math.max(0,e-f.start),d),g&&(e+=" / "+WA(g,d)),dD(c,e),c.g.disabled=!0)});this.eventManager.o(this.player,"trackschanged",function(){c.player.R()&&(c.g.ariaLabel=c.localization.resolve("SKIP_TO_LIVE"))})}pa(cD,QA);function dD(a,b){b!=a.g.textContent&&(a.g.textContent=b)}M("shaka.ui.PresentationTimeTracker",cD);function eD(){}eD.prototype.create=function(a,b){return new cD(a,b)};zB("time_and_duration",new eD);function fD(a,b){QA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("shaka-remote-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.i=U("i");this.i.classList.add("material-icons-round");a="cast";(b=Jd())&&13<=b&&(a="airplay");this.i.textContent=a;this.g.appendChild(this.i);a=U("label");a.classList.add("shaka-overflow-button-label");a.classList.add("shaka-overflow-menu-only");this.l=U("span");a.appendChild(this.l);this.j=U("span");this.j.classList.add("shaka-current-selection-span");
1474
+ a.appendChild(this.j);this.g.appendChild(a);this.parent.appendChild(this.g);this.h=-1;gD(this);VA(this.g,!1);!this.video.remote||this.video.disableRemotePlayback?this.g.classList.add("shaka-hidden"):(this.eventManager.o(this.localization,"locale-updated",function(){gD(c)}),this.eventManager.o(this.localization,"locale-changed",function(){gD(c)}),this.eventManager.o(this.controls,"caststatuschanged",function(){hD(c)}),this.eventManager.o(this.g,"click",function(){c.video.remote.prompt()}),this.eventManager.o(this.video.remote,
1475
+ "connect",function(){hD(c)}),this.eventManager.o(this.video.remote,"connecting",function(){hD(c)}),this.eventManager.o(this.video.remote,"disconnect",function(){hD(c)}),this.eventManager.o(this.player,"loaded",function(){hD(c)}),hD(this))}pa(fD,QA);fD.prototype.release=function(){this.video.remote&&-1!=this.h&&this.video.remote.cancelWatchAvailability(this.h).catch(function(){});QA.prototype.release.call(this)};
1476
+ function hD(a){var b,c;K(function(d){switch(d.g){case 1:if(a.controls.C.$e()&&a.controls.sa){VA(a.g,!1);-1!=a.h&&(a.video.remote.cancelWatchAvailability(a.h),a.h=-1);d.F(0);break}if("disconnected"==a.video.remote.state){b=function(e){a.player?VA(a.g,a.player.ae()==Xm&&e):VA(a.g,!1)};ta(d,7);if(-1==a.h){d.F(9);break}return D(d,a.video.remote.cancelWatchAvailability(a.h),10)}if(-1==a.h){d.F(0);break}return D(d,a.video.remote.cancelWatchAvailability(a.h),6);case 6:a.h=-1;d.F(0);break;case 10:a.h=-1;
1477
+ case 9:va(d,8);break;case 7:wa(d);case 8:return ta(d,11),D(d,a.video.remote.watchAvailability(b),13);case 13:c=d.h;a.h=c;va(d,0);break;case 11:wa(d),b(!0),F(d)}})}function gD(a){var b=a.localization.resolve("CAST"),c=Jd();c&&13<=c&&(b=a.localization.resolve("AIRPLAY"));a.g.ariaLabel=b;a.l.textContent=b}M("shaka.ui.RemoteButton",fD);function iD(){}iD.prototype.create=function(a,b){return new fD(a,b)};$B("remote",new iD);zB("remote",new iD);function jD(a,b){qC.call(this,a,b,"settings");var c=this;this.button.classList.add("shaka-resolution-button");this.button.classList.add("shaka-tooltip-status");this.menu.classList.add("shaka-resolutions");this.eventManager.o(this.localization,"locale-updated",function(){kD(c)});this.eventManager.o(this.localization,"locale-changed",function(){kD(c)});this.eventManager.o(this.player,"variantchanged",function(){lD(c)});this.eventManager.o(this.player,"trackschanged",function(){lD(c)});this.eventManager.o(this.player,
1478
+ "abrstatuschanged",function(){lD(c)});lD(this)}pa(jD,qC);
1479
+ function lD(a){var b=[];a.player.ae()!=Xm&&(b=a.player.kb());var c=b.find(function(k){return k.active});c&&(b=b.filter(function(k){return k.language==c.language&&k.channelsCount==c.channelsCount}));b=b.filter(function(k,l){var m=-1;m=a.player.Kc()?b.findIndex(function(n){return n.bandwidth==k.bandwidth}):b.findIndex(function(n){return n.height==k.height&&n.frameRate==k.frameRate&&n.hdr==k.hdr&&n.videoLayout==k.videoLayout});return m==l});a.player.Kc()?b.sort(function(k,l){return l.bandwidth-k.bandwidth}):
1480
+ b.sort(function(k,l){return l.height-k.height});var d=RA(a.menu);Wk(a.menu);a.menu.appendChild(d);d=a.player.getConfiguration().abr.enabled;for(var e={},f=t(b),g=f.next();!g.done;e={Eb:e.Eb},g=f.next()){e.Eb=g.value;g=Vk();g.classList.add("explicit-resolution");a.eventManager.o(g,"click",function(k){return function(){var l=k.Eb;a.player.configure({abr:{enabled:!1}});a.player.Fe(l,a.controls.g.clearBufferOnQualityChange)}}(e));var h=U("span");h.textContent=a.player.Kc()&&e.Eb.bandwidth?Math.round(e.Eb.bandwidth/
1481
+ 1E3)+" kbits/s":e.Eb.height&&e.Eb.width?mD(e.Eb):"Unknown";g.appendChild(h);d||e.Eb!=c||(g.ariaSelected="true",g.appendChild(UA()),h.classList.add("shaka-chosen-item"),a.currentSelection.textContent=h.textContent);a.menu.appendChild(g)}e=Vk();e.classList.add("shaka-enable-abr-button");a.eventManager.o(e,"click",function(){a.player.configure({abr:{enabled:!0}});lD(a)});a.g=U("span");a.g.classList.add("shaka-auto-span");a.g.textContent=a.localization.resolve("AUTO_QUALITY");e.appendChild(a.g);d&&(e.ariaSelected=
1482
+ "true",e.appendChild(UA()),a.g.classList.add("shaka-chosen-item"),a.currentSelection.textContent=a.localization.resolve("AUTO_QUALITY"));a.button.setAttribute("shaka-status",a.currentSelection.textContent);a.menu.appendChild(e);TA(a.menu);a.controls.dispatchEvent(new O("resolutionselectionupdated"));kD(a)}
1483
+ function mD(a){var b=a.height||0,c=a.width||0,d=b;c/b>16/9&&(d=Math.round(9*c/16));b=d+"p";2160==d&&(b="4K");(d=a.frameRate)&&(50<=d||20>=d)&&(b+=Math.round(a.frameRate));if("PQ"==a.hdr||"HLG"==a.hdr)b+=" (HDR)";"CH-STEREO"==a.videoLayout&&(b+=" (3D)");return b}
1484
+ function kD(a){var b=a.player.Kc()?"QUALITY":"RESOLUTION";a.button.ariaLabel=a.localization.resolve(b);a.backButton.ariaLabel=a.localization.resolve(b);a.backSpan.textContent=a.localization.resolve(b);a.nameSpan.textContent=a.localization.resolve(b);a.g.textContent=a.localization.resolve("AUTO_QUALITY");a.player.getConfiguration().abr.enabled&&(a.currentSelection.textContent=a.localization.resolve("AUTO_QUALITY"))}M("shaka.ui.ResolutionSelection",jD);function nD(){}
1485
+ nD.prototype.create=function(a,b){return new jD(a,b)};$B("quality",new nD);zB("quality",new nD);function oD(a,b){QA.call(this,a,b);var c=this;this.g=Vk();this.g.classList.add("material-icons-round");this.g.classList.add("shaka-rewind-button");this.g.classList.add("shaka-tooltip-status");this.g.setAttribute("shaka-status",this.localization.resolve("OFF"));this.g.textContent="fast_rewind";this.parent.appendChild(this.g);pD(this);this.h=this.controls.g.rewindRates;this.eventManager.o(this.localization,"locale-updated",function(){pD(c)});this.eventManager.o(this.localization,"locale-changed",function(){pD(c)});
1486
+ this.eventManager.o(this.g,"click",function(){if(c.video.duration){var d=c.h.indexOf(c.player.Lb())+1;d=d!=c.h.length?c.h[d]:c.h[0];c.player.Jd(d);c.g.setAttribute("shaka-status",d+"x")}})}pa(oD,QA);function pD(a){a.g.ariaLabel=a.localization.resolve("REWIND")}M("shaka.ui.RewindButton",oD);function qD(){}qD.prototype.create=function(a,b){return new oD(a,b)};zB("rewind",new qD);function rD(a,b){QA.call(this,a,b);var c=this;this.j=U("div");this.j.classList.add("shaka-skip-ad-container");this.parent.appendChild(this.j);this.h=U("div");this.h.classList.add("shaka-skip-ad-counter");VA(this.h,!1);this.j.appendChild(this.h);this.g=Vk();this.g.classList.add("shaka-skip-ad-button");this.g.disabled=!0;VA(this.g,!1);this.g.classList.add("shaka-no-propagation");this.j.appendChild(this.g);sD(this);this.i=new vd(function(){var d=Math.round(c.ad.getTimeUntilSkippable());0<d?c.h.textContent=
1487
+ d:(c.i.stop(),VA(c.h,!1))});this.eventManager.o(this.localization,"locale-updated",function(){sD(c)});this.eventManager.o(this.localization,"locale-changed",function(){sD(c)});this.eventManager.o(this.adManager,"ad-started",function(){tD(c)});this.eventManager.o(this.adManager,"ad-skip-state-changed",function(){c.ad.canSkipNow()&&(c.g.disabled=!1,c.i.stop(),VA(c.h,!1))});this.eventManager.o(this.adManager,"ad-stopped",function(){c.i.stop();c.g.disabled=!0;VA(c.g,!1);VA(c.h,!1)});this.eventManager.o(this.g,
1488
+ "click",function(){c.ad.skip()});this.ad&&tD(this)}pa(rD,QA);rD.prototype.release=function(){this.i.stop();this.i=null;QA.prototype.release.call(this)};function sD(a){a.g.textContent=a.localization.resolve("SKIP_AD")}function tD(a){a.ad.isSkippable()&&(VA(a.g,!0),VA(a.h,!0),a.h.textContent="",a.i.Pa(),a.i.ya(.5))}M("shaka.ui.SkipAdButton",rD);function uD(a,b){$A.call(this,a,b);this.button.classList.add("shaka-small-play-button");this.button.classList.add("material-icons-round");this.button.classList.add("shaka-tooltip");this.h();this.g()}pa(uD,$A);uD.prototype.h=function(){this.isEnded()?this.button.textContent="replay":this.button.textContent=this.isPaused()?"play_arrow":"pause"};
1489
+ uD.prototype.g=function(){if(this.isEnded())this.button.ariaLabel=this.localization.resolve("REPLAY");else{var a=this.isPaused()?"PLAY":"PAUSE";this.button.ariaLabel=this.localization.resolve(a)}};M("shaka.ui.SmallPlayButton",uD);function vD(){}vD.prototype.create=function(a,b){return new uD(a,b)};zB("play_pause",new vD);function wD(a,b){QA.call(this,a,b);a=U("div");a.classList.add("shaka-spacer");a.ariaHidden="true";this.parent.appendChild(a)}pa(wD,QA);M("shaka.ui.Spacer",wD);function xD(){}xD.prototype.create=function(a,b){return new wD(a,b)};zB("spacer",new xD);function yD(a,b){function c(k){return WA(h.h[k],!1)+" (m)"}function d(k){return Math.round(h.h[k]/1E3)+" (kbits/s)"}function e(k){return h.h[k].toFixed(2)+" (s)"}function f(k){return h.h[k]+" (frames)"}function g(k){return h.h[k]+" (px)"}QA.call(this,a,b);var h=this;this.i=Vk();this.i.classList.add("shaka-statistics-button");this.j=U("i");this.j.classList.add("material-icons-round");this.j.textContent="insert_chart_outlined";this.i.appendChild(this.j);a=U("label");a.classList.add("shaka-overflow-button-label");
1491
1490
  this.s=U("span");a.appendChild(this.s);this.m=U("span");this.m.classList.add("shaka-current-selection-span");a.appendChild(this.m);this.i.appendChild(a);this.parent.appendChild(this.i);this.g=U("div");this.g.classList.add("shaka-no-propagation");this.g.classList.add("shaka-show-controls-on-mouse-over");this.g.classList.add("shaka-statistics-container");this.g.classList.add("shaka-hidden");this.controls.h.appendChild(this.g);this.D=[];this.G=["stateHistory","switchHistory"];this.h=this.player.getStats();
1492
1491
  this.u={};this.C={width:g,height:g,completionPercent:function(k){return h.h[k]+" (%)"},bufferingTime:e,drmTimeSeconds:e,licenseTime:e,liveLatency:e,loadLatency:e,manifestTimeSeconds:e,estimatedBandwidth:d,streamBandwidth:d,maxSegmentDuration:c,pauseTime:c,playTime:c,corruptedFrames:f,decodedFrames:f,droppedFrames:f,stallsDetected:function(k){return h.h[k]+" (stalls)"},gapsJumped:function(k){return h.h[k]+" (gaps)"}};this.l=new vd(function(){h.h=h.player.getStats();for(var k=t(h.D),l=k.next();!l.done;l=
1493
- k.next())l=l.value,h.u[l].textContent=h.C[l](l)});AD(this);BD(this);this.eventManager.o(this.localization,"locale-updated",function(){AD(h)});this.eventManager.o(this.localization,"locale-changed",function(){AD(h)});this.eventManager.o(this.i,"click",function(){WA(h.parent,!1);h.g.classList.contains("shaka-hidden")?(h.j.textContent="insert_chart",h.l.ya(.1),WA(h.g,!0)):(h.j.textContent="insert_chart_outlined",h.l.stop(),WA(h.g,!1));AD(h)})}pa(zD,RA);
1494
- function AD(a){a.s.textContent=a.localization.resolve("STATISTICS");a.i.ariaLabel=a.localization.resolve("STATISTICS");a.m.textContent=a.localization.resolve(a.g.classList.contains("shaka-hidden")?"OFF":"ON")}
1495
- function BD(a){for(var b=t(a.controls.g.statisticsList),c=b.next();!c.done;c=b.next())if(c=c.value,c in a.h&&!a.G.includes(c)){var d=a.g,e=d.appendChild,f=a,g=U("div"),h=U("label");h.textContent=c+":";g.appendChild(h);h=U("span");h.textContent=f.C[c](c);g.appendChild(h);f.u[c]=h;e.call(d,g);a.D.push(c)}else Sa("Unrecognized statistic element:",c)}zD.prototype.release=function(){this.l.stop();this.l=null;RA.prototype.release.call(this)};M("shaka.ui.StatisticsButton",zD);function CD(){}
1496
- CD.prototype.create=function(a,b){return new zD(a,b)};aC("statistics",new CD);gB("statistics",new CD);function DD(a,b){rC.call(this,a,b,"closed_caption");var c=this;this.button.classList.add("shaka-caption-button");this.button.classList.add("shaka-tooltip-status");this.menu.classList.add("shaka-text-languages");this.player&&this.player.rc()?this.button.ariaPressed="true":this.button.ariaPressed="false";ED(this);this.eventManager.o(this.localization,"locale-updated",function(){FD(c);GD(c)});this.eventManager.o(this.localization,"locale-changed",function(){FD(c);GD(c)});this.eventManager.o(this.player,
1497
- "texttrackvisibility",function(){HD(c);GD(c)});this.eventManager.o(this.player,"textchanged",function(){GD(c)});this.eventManager.o(this.player,"trackschanged",function(){ID(c)});HD(this);FD(this);GD(this);ID(this)}pa(DD,rC);function ED(a){var b=Vk();b.ariaSelected="true";a.menu.appendChild(b);b.appendChild(VA());a.g=U("span");a.g.classList.add("shaka-auto-span");b.appendChild(a.g)}
1498
- function HD(a){a.player.rc()?(a.icon.textContent="closed_caption",a.button.ariaPressed="true"):(a.icon.textContent="closed_caption_disabled",a.button.ariaPressed="false");a.controls.dispatchEvent(new O("captionselectionupdated"))}
1499
- function GD(a){var b=a.player.$b();pC(b,a.menu,function(c){return JD(a,c)},a.player.rc(),a.currentSelection,a.localization,a.controls.g.trackLabelFormat,a.controls.g.showAudioChannelCountVariants);b=Vk();b.classList.add("shaka-turn-captions-off-button");a.eventManager.o(b,"click",function(){a.player.He(!1);GD(a)});b.appendChild(a.g);a.menu.appendChild(b);a.player.rc()||(b.ariaSelected="true",b.appendChild(VA()),a.g.classList.add("shaka-chosen-item"),a.currentSelection.textContent=a.localization.resolve("OFF"));
1500
- a.button.setAttribute("shaka-status",a.currentSelection.textContent);UA(a.menu);a.controls.dispatchEvent(new O("captionselectionupdated"))}function JD(a,b){return K(function(c){a.player.dg(b);return D(c,a.player.He(!0),0)})}
1501
- function FD(a){a.button.ariaLabel=a.localization.resolve("CAPTIONS");a.backButton.ariaLabel=a.localization.resolve("BACK");a.nameSpan.textContent=a.localization.resolve("CAPTIONS");a.backSpan.textContent=a.localization.resolve("CAPTIONS");a.g.textContent=a.localization.resolve("OFF")}function ID(a){var b=0<a.player.$b().length;WA(a.button,b);GD(a)}M("shaka.ui.TextSelection",DD);function KD(){}KD.prototype.create=function(a,b){return new DD(a,b)};aC("captions",new KD);AB("captions",new KD);function LD(a,b){iB.call(this,a,b,["shaka-volume-bar-container"],["shaka-volume-bar"]);var c=this;this.g=this.controls.g;this.setRange(0,100);this.eventManager.o(this.video,"volumechange",function(){return MD(c)});this.eventManager.o(this.adManager,"ad-volume-changed",function(){return ND(c)});this.eventManager.o(this.adManager,"ad-muted",function(){return ND(c)});this.eventManager.o(this.adManager,"ad-stopped",function(){return MD(c)});this.eventManager.o(this.localization,"locale-updated",function(){return OD(c)});
1502
- this.eventManager.o(this.localization,"locale-changed",function(){return OD(c)});MD(this);OD(this);if(this.ad)this.onChange()}pa(LD,iB);LD.prototype.onChange=function(){this.ad&&this.ad.isLinear()?this.ad.setVolume(this.getValue()/100):(this.video.volume=this.getValue()/100,this.video.muted=0==this.video.volume?!0:!1)};function MD(a){a.video.muted?a.setValue(0):a.setValue(100*a.video.volume);PD(a)}function ND(a){var b=a.ad.getVolume();a.setValue(100*b);PD(a)}
1503
- function PD(a){var b=a.g.volumeBarColors,c=["to right"];c.push(b.level+a.getValue()+"%");c.push(b.base+a.getValue()+"%");c.push(b.base+"100%");a.container.style.background="linear-gradient("+c.join(",")+")"}function OD(a){a.bar.ariaLabel=a.localization.resolve("VOLUME")}M("shaka.ui.VolumeBar",LD);function QD(){}QD.prototype.create=function(a,b){return new LD(a,b)};AB("volume",new QD);}).call(exportTo,innerGlobal,innerGlobal,undefined);if(typeof exports!="undefined")for(var k in exportTo.shaka)exports[k]=exportTo.shaka[k];else if(typeof define=="function"&&define.amd)define(function(){return exportTo.shaka});else innerGlobal.shaka=exportTo.shaka})();
1492
+ k.next())l=l.value,h.u[l].textContent=h.C[l](l)});zD(this);AD(this);this.eventManager.o(this.localization,"locale-updated",function(){zD(h)});this.eventManager.o(this.localization,"locale-changed",function(){zD(h)});this.eventManager.o(this.i,"click",function(){VA(h.parent,!1);h.g.classList.contains("shaka-hidden")?(h.j.textContent="insert_chart",h.l.ya(.1),VA(h.g,!0)):(h.j.textContent="insert_chart_outlined",h.l.stop(),VA(h.g,!1));zD(h)})}pa(yD,QA);
1493
+ function zD(a){a.s.textContent=a.localization.resolve("STATISTICS");a.i.ariaLabel=a.localization.resolve("STATISTICS");a.m.textContent=a.localization.resolve(a.g.classList.contains("shaka-hidden")?"OFF":"ON")}
1494
+ function AD(a){for(var b=t(a.controls.g.statisticsList),c=b.next();!c.done;c=b.next())if(c=c.value,c in a.h&&!a.G.includes(c)){var d=a.g,e=d.appendChild,f=a,g=U("div"),h=U("label");h.textContent=c+":";g.appendChild(h);h=U("span");h.textContent=f.C[c](c);g.appendChild(h);f.u[c]=h;e.call(d,g);a.D.push(c)}else Sa("Unrecognized statistic element:",c)}yD.prototype.release=function(){this.l.stop();this.l=null;QA.prototype.release.call(this)};M("shaka.ui.StatisticsButton",yD);function BD(){}
1495
+ BD.prototype.create=function(a,b){return new yD(a,b)};$B("statistics",new BD);fB("statistics",new BD);function CD(a,b){qC.call(this,a,b,"closed_caption");var c=this;this.button.classList.add("shaka-caption-button");this.button.classList.add("shaka-tooltip-status");this.menu.classList.add("shaka-text-languages");this.player&&this.player.rc()?this.button.ariaPressed="true":this.button.ariaPressed="false";DD(this);this.eventManager.o(this.localization,"locale-updated",function(){ED(c);FD(c)});this.eventManager.o(this.localization,"locale-changed",function(){ED(c);FD(c)});this.eventManager.o(this.player,
1496
+ "texttrackvisibility",function(){GD(c);FD(c)});this.eventManager.o(this.player,"textchanged",function(){FD(c)});this.eventManager.o(this.player,"trackschanged",function(){HD(c)});GD(this);ED(this);FD(this);HD(this)}pa(CD,qC);function DD(a){var b=Vk();b.ariaSelected="true";a.menu.appendChild(b);b.appendChild(UA());a.g=U("span");a.g.classList.add("shaka-auto-span");b.appendChild(a.g)}
1497
+ function GD(a){a.player.rc()?(a.icon.textContent="closed_caption",a.button.ariaPressed="true"):(a.icon.textContent="closed_caption_disabled",a.button.ariaPressed="false");a.controls.dispatchEvent(new O("captionselectionupdated"))}
1498
+ function FD(a){var b=a.player.ac();oC(b,a.menu,function(c){return ID(a,c)},a.player.rc(),a.currentSelection,a.localization,a.controls.g.trackLabelFormat,a.controls.g.showAudioChannelCountVariants);b=Vk();b.classList.add("shaka-turn-captions-off-button");a.eventManager.o(b,"click",function(){a.player.He(!1);FD(a)});b.appendChild(a.g);a.menu.appendChild(b);a.player.rc()||(b.ariaSelected="true",b.appendChild(UA()),a.g.classList.add("shaka-chosen-item"),a.currentSelection.textContent=a.localization.resolve("OFF"));
1499
+ a.button.setAttribute("shaka-status",a.currentSelection.textContent);TA(a.menu);a.controls.dispatchEvent(new O("captionselectionupdated"))}function ID(a,b){return K(function(c){a.player.dg(b);return D(c,a.player.He(!0),0)})}
1500
+ function ED(a){a.button.ariaLabel=a.localization.resolve("CAPTIONS");a.backButton.ariaLabel=a.localization.resolve("BACK");a.nameSpan.textContent=a.localization.resolve("CAPTIONS");a.backSpan.textContent=a.localization.resolve("CAPTIONS");a.g.textContent=a.localization.resolve("OFF")}function HD(a){var b=0<a.player.ac().length;VA(a.button,b);FD(a)}M("shaka.ui.TextSelection",CD);function JD(){}JD.prototype.create=function(a,b){return new CD(a,b)};$B("captions",new JD);zB("captions",new JD);function KD(a,b){hB.call(this,a,b,["shaka-volume-bar-container"],["shaka-volume-bar"]);var c=this;this.g=this.controls.g;this.setRange(0,100);this.eventManager.o(this.video,"volumechange",function(){return LD(c)});this.eventManager.o(this.adManager,"ad-volume-changed",function(){return MD(c)});this.eventManager.o(this.adManager,"ad-muted",function(){return MD(c)});this.eventManager.o(this.adManager,"ad-stopped",function(){return LD(c)});this.eventManager.o(this.localization,"locale-updated",function(){return ND(c)});
1501
+ this.eventManager.o(this.localization,"locale-changed",function(){return ND(c)});LD(this);ND(this);if(this.ad)this.onChange()}pa(KD,hB);KD.prototype.onChange=function(){this.ad&&this.ad.isLinear()?this.ad.setVolume(this.getValue()/100):(this.video.volume=this.getValue()/100,this.video.muted=0==this.video.volume?!0:!1)};function LD(a){a.video.muted?a.setValue(0):a.setValue(100*a.video.volume);OD(a)}function MD(a){var b=a.ad.getVolume();a.setValue(100*b);OD(a)}
1502
+ function OD(a){var b=a.g.volumeBarColors,c=["to right"];c.push(b.level+a.getValue()+"%");c.push(b.base+a.getValue()+"%");c.push(b.base+"100%");a.container.style.background="linear-gradient("+c.join(",")+")"}function ND(a){a.bar.ariaLabel=a.localization.resolve("VOLUME")}M("shaka.ui.VolumeBar",KD);function PD(){}PD.prototype.create=function(a,b){return new KD(a,b)};zB("volume",new PD);}).call(exportTo,innerGlobal,innerGlobal,undefined);if(typeof exports!="undefined")for(var k in exportTo.shaka)exports[k]=exportTo.shaka[k];else if(typeof define=="function"&&define.amd)define(function(){return exportTo.shaka});else innerGlobal.shaka=exportTo.shaka})();
1504
1503
 
1505
1504
  //# sourceMappingURL=shaka-player.ui.map