shaka-player 4.1.1 → 4.1.2

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 (129) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/CONTRIBUTORS +2 -0
  3. package/README.md +20 -6
  4. package/demo/index.html +0 -2
  5. package/dist/controls.css +1 -1
  6. package/dist/deps.js +3 -3
  7. package/dist/locales.js +31 -31
  8. package/dist/shaka-player.compiled.d.ts +11 -0
  9. package/dist/shaka-player.compiled.debug.d.ts +11 -0
  10. package/dist/shaka-player.compiled.debug.externs.js +48 -37
  11. package/dist/shaka-player.compiled.debug.js +140 -136
  12. package/dist/shaka-player.compiled.debug.map +4 -4
  13. package/dist/shaka-player.compiled.externs.js +48 -37
  14. package/dist/shaka-player.compiled.js +774 -772
  15. package/dist/shaka-player.compiled.map +4 -4
  16. package/dist/shaka-player.ui.d.ts +11 -0
  17. package/dist/shaka-player.ui.debug.d.ts +11 -0
  18. package/dist/shaka-player.ui.debug.externs.js +48 -37
  19. package/dist/shaka-player.ui.debug.js +152 -148
  20. package/dist/shaka-player.ui.debug.map +4 -4
  21. package/dist/shaka-player.ui.externs.js +48 -37
  22. package/dist/shaka-player.ui.js +884 -882
  23. package/dist/shaka-player.ui.map +4 -4
  24. package/docs/tutorials/upgrade.md +1 -0
  25. package/docs/tutorials/welcome.md +6 -3
  26. package/lib/dash/dash_parser.js +5 -0
  27. package/lib/hls/hls_parser.js +6 -2
  28. package/lib/media/media_source_engine.js +57 -24
  29. package/lib/media/presentation_timeline.js +24 -1
  30. package/lib/media/streaming_engine.js +3 -4
  31. package/lib/media/time_ranges_utils.js +46 -0
  32. package/lib/player.js +1 -1
  33. package/lib/polyfill/media_capabilities.js +3 -0
  34. package/lib/polyfill/videoplaybackquality.js +3 -1
  35. package/lib/util/platform.js +19 -1
  36. package/lib/util/string_utils.js +56 -14
  37. package/maintained-branches.md +15 -0
  38. package/package.json +2 -4
  39. package/test/media/drm_engine_integration.js +24 -8
  40. package/test/media/media_source_engine_integration.js +24 -10
  41. package/test/media/media_source_engine_unit.js +53 -38
  42. package/test/media/streaming_engine_unit.js +28 -27
  43. package/test/test/util/fake_media_source_engine.js +10 -9
  44. package/app-engine/README.md +0 -9
  45. package/app-engine/demo-version-index/README.md +0 -14
  46. package/app-engine/demo-version-index/app.yaml +0 -28
  47. package/app-engine/demo-version-index/generate.py +0 -164
  48. package/app-engine/demo-version-index/main.py +0 -11
  49. package/app-engine/demo-version-index/requirements.txt +0 -5
  50. package/app-engine/demo-version-index/templates/index.html +0 -114
  51. package/app-engine/shaka-player-demo/README.md +0 -18
  52. package/app-engine/shaka-player-demo/app.yaml +0 -61
  53. package/app-engine/shaka-player-demo/main.py +0 -95
  54. package/app-engine/shaka-player-demo/posters/10yo.png +0 -0
  55. package/app-engine/shaka-player-demo/posters/10yo.xcf +0 -0
  56. package/app-engine/shaka-player-demo/posters/1yo.jpg +0 -0
  57. package/app-engine/shaka-player-demo/posters/2yo.png +0 -0
  58. package/app-engine/shaka-player-demo/posters/2yo.xcf +0 -0
  59. package/app-engine/shaka-player-demo/posters/3yo.png +0 -0
  60. package/app-engine/shaka-player-demo/posters/3yo.xcf +0 -0
  61. package/app-engine/shaka-player-demo/posters/4yo.png +0 -0
  62. package/app-engine/shaka-player-demo/posters/4yo.xcf +0 -0
  63. package/app-engine/shaka-player-demo/posters/5yo.png +0 -0
  64. package/app-engine/shaka-player-demo/posters/5yo.xcf +0 -0
  65. package/app-engine/shaka-player-demo/posters/6yo.png +0 -0
  66. package/app-engine/shaka-player-demo/posters/6yo.xcf +0 -0
  67. package/app-engine/shaka-player-demo/posters/7yo.png +0 -0
  68. package/app-engine/shaka-player-demo/posters/7yo.xcf +0 -0
  69. package/app-engine/shaka-player-demo/posters/8yo.png +0 -0
  70. package/app-engine/shaka-player-demo/posters/8yo.xcf +0 -0
  71. package/app-engine/shaka-player-demo/posters/9yo.png +0 -0
  72. package/app-engine/shaka-player-demo/posters/9yo.xcf +0 -0
  73. package/app-engine/shaka-player-demo/posters/audioOnly.gif +0 -0
  74. package/app-engine/shaka-player-demo/posters/audioRickRoll.gif +0 -0
  75. package/app-engine/shaka-player-demo/posters/colorbars.gif +0 -0
  76. package/app-engine/shaka-player-demo/posters/fireworks.jpg +0 -0
  77. package/app-engine/shaka-player-demo/posters/party-hat.png +0 -0
  78. package/app-engine/shaka-player-demo/posters/sources.txt +0 -46
  79. package/app-engine/shaka-player-demo/posters/standard.png +0 -0
  80. package/app-engine/shaka-player-demo/posters/trek.jpg +0 -0
  81. package/app-engine/shaka-player-demo/posters/valentines.png +0 -0
  82. package/app-engine/shaka-player-demo/posters/zombie.jpg +0 -0
  83. package/app-engine/shaka-player-demo/posters.py +0 -110
  84. package/app-engine/shaka-player-demo/requirements.txt +0 -5
  85. package/app-engine/shaka-player-demo/time.txt +0 -1
  86. package/build/README.md +0 -127
  87. package/build/__init__.py +0 -0
  88. package/build/all.py +0 -150
  89. package/build/apps.py +0 -186
  90. package/build/build.py +0 -392
  91. package/build/check.py +0 -354
  92. package/build/checkversion.py +0 -84
  93. package/build/compiler.py +0 -513
  94. package/build/conformance.textproto +0 -335
  95. package/build/docker/Dockerfile +0 -20
  96. package/build/docker/docker-compose.yml +0 -10
  97. package/build/docs.py +0 -54
  98. package/build/eslint-plugin-shaka-rules/arg-comment-spacing.js +0 -72
  99. package/build/eslint-plugin-shaka-rules/index.js +0 -24
  100. package/build/eslint-plugin-shaka-rules/package.json +0 -7
  101. package/build/eslint-plugin-shaka-rules/private.js +0 -109
  102. package/build/gendeps.py +0 -71
  103. package/build/generateExterns.js +0 -867
  104. package/build/generateLocalizations.py +0 -262
  105. package/build/generateTsDefs.py +0 -137
  106. package/build/install-linux-prereqs.sh +0 -136
  107. package/build/license-header +0 -5
  108. package/build/misspellings.txt +0 -39
  109. package/build/pixelsChanged.js +0 -35
  110. package/build/shaka-lab.yaml +0 -161
  111. package/build/shakaBuildHelpers.py +0 -356
  112. package/build/stats.py +0 -816
  113. package/build/subprocessWindowsPatch.py +0 -103
  114. package/build/test.py +0 -541
  115. package/build/types/ads +0 -8
  116. package/build/types/cast +0 -6
  117. package/build/types/cea +0 -13
  118. package/build/types/complete +0 -9
  119. package/build/types/core +0 -108
  120. package/build/types/dash +0 -8
  121. package/build/types/hls +0 -9
  122. package/build/types/manifests +0 -5
  123. package/build/types/networking +0 -6
  124. package/build/types/offline +0 -22
  125. package/build/types/polyfill +0 -18
  126. package/build/types/text +0 -11
  127. package/build/types/ui +0 -39
  128. package/build/updateScreenshots.py +0 -85
  129. package/build/wrapper.template.js +0 -52
@@ -15,19 +15,19 @@ ea("Symbol",function(a){function b(f){if(this instanceof b)throw new TypeError("
15
15
  ea("Symbol.iterator",function(a){if(a)return a;a=Symbol("Symbol.iterator");for(var b="Array Int8Array Uint8Array Uint8ClampedArray Int16Array Uint16Array Int32Array Uint32Array Float32Array Float64Array".split(" "),c=0;c<b.length;c++){var d=da[b[c]];"function"===typeof d&&"function"!=typeof d.prototype[a]&&ba(d.prototype,a,{configurable:!0,writable:!0,value:function(){return fa(aa(this))}})}return a});function fa(a){a={next:a};a[Symbol.iterator]=function(){return this};return a}
16
16
  function t(a){var b="undefined"!=typeof Symbol&&Symbol.iterator&&a[Symbol.iterator];return b?b.call(a):{next:aa(a)}}function ia(a){if(!(a instanceof Array)){a=t(a);for(var b,c=[];!(b=a.next()).done;)c.push(b.value);a=c}return a}var ka="function"==typeof Object.create?Object.create:function(a){function b(){}b.prototype=a;return new b},la;
17
17
  if("function"==typeof Object.setPrototypeOf)la=Object.setPrototypeOf;else{var ma;a:{var na={a:!0},oa={};try{oa.__proto__=na;ma=oa.a;break a}catch(a){}ma=!1}la=ma?function(a,b){a.__proto__=b;if(a.__proto__!==b)throw new TypeError(a+" is not extensible");return a}:null}var pa=la;
18
- function qa(a,b){a.prototype=ka(b.prototype);a.prototype.constructor=a;if(pa)pa(a,b);else for(var c in b)if("prototype"!=c)if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);d&&Object.defineProperty(a,c,d)}else a[c]=b[c];a.Zi=b.prototype}function ra(){this.A=!1;this.l=null;this.h=void 0;this.g=1;this.j=this.m=0;this.C=this.i=null}function sa(a){if(a.A)throw new TypeError("Generator is already running");a.A=!0}ra.prototype.B=function(a){this.h=a};
19
- function ta(a,b){a.i={lf:b,wf:!0};a.g=a.m||a.j}ra.prototype["return"]=function(a){this.i={"return":a};this.g=this.j};function u(a,b,c){a.g=c;return{value:b}}ra.prototype.D=function(a){this.g=a};function z(a){a.g=0}function A(a,b,c){a.m=b;void 0!=c&&(a.j=c)}function ua(a){a.m=0;a.j=2}function va(a,b,c){a.g=b;a.m=c||0}function F(a,b){a.m=b||0;var c=a.i.lf;a.i=null;return c}function wa(a){a.C=[a.i];a.m=0;a.j=0}
20
- function ya(a,b){var c=a.C.splice(0)[0];(c=a.i=a.i||c)?c.wf?a.g=a.m||a.j:void 0!=c.D&&a.j<c.D?(a.g=c.D,a.i=null):a.g=a.j:a.g=b}function za(a){this.g=new ra;this.h=a}function Aa(a,b){sa(a.g);var c=a.g.l;if(c)return Ba(a,"return"in c?c["return"]:function(d){return{value:d,done:!0}},b,a.g["return"]);a.g["return"](b);return Ca(a)}
18
+ function qa(a,b){a.prototype=ka(b.prototype);a.prototype.constructor=a;if(pa)pa(a,b);else for(var c in b)if("prototype"!=c)if(Object.defineProperties){var d=Object.getOwnPropertyDescriptor(b,c);d&&Object.defineProperty(a,c,d)}else a[c]=b[c];a.$i=b.prototype}function ra(){this.A=!1;this.l=null;this.h=void 0;this.g=1;this.j=this.m=0;this.C=this.i=null}function sa(a){if(a.A)throw new TypeError("Generator is already running");a.A=!0}ra.prototype.B=function(a){this.h=a};
19
+ function ta(a,b){a.i={mf:b,xf:!0};a.g=a.m||a.j}ra.prototype["return"]=function(a){this.i={"return":a};this.g=this.j};function u(a,b,c){a.g=c;return{value:b}}ra.prototype.D=function(a){this.g=a};function z(a){a.g=0}function A(a,b,c){a.m=b;void 0!=c&&(a.j=c)}function ua(a){a.m=0;a.j=2}function va(a,b,c){a.g=b;a.m=c||0}function F(a,b){a.m=b||0;var c=a.i.mf;a.i=null;return c}function wa(a){a.C=[a.i];a.m=0;a.j=0}
20
+ function ya(a,b){var c=a.C.splice(0)[0];(c=a.i=a.i||c)?c.xf?a.g=a.m||a.j:void 0!=c.D&&a.j<c.D?(a.g=c.D,a.i=null):a.g=a.j:a.g=b}function za(a){this.g=new ra;this.h=a}function Aa(a,b){sa(a.g);var c=a.g.l;if(c)return Ba(a,"return"in c?c["return"]:function(d){return{value:d,done:!0}},b,a.g["return"]);a.g["return"](b);return Ca(a)}
21
21
  function Ba(a,b,c,d){try{var e=b.call(a.g.l,c);if(!(e instanceof Object))throw new TypeError("Iterator result "+e+" is not an object");if(!e.done)return a.g.A=!1,e;var f=e.value}catch(g){return a.g.l=null,ta(a.g,g),Ca(a)}a.g.l=null;d.call(a.g,f);return Ca(a)}
22
- function Ca(a){for(;a.g.g;)try{var b=a.h(a.g);if(b)return a.g.A=!1,{value:b.value,done:!1}}catch(c){a.g.h=void 0,ta(a.g,c)}a.g.A=!1;if(a.g.i){b=a.g.i;a.g.i=null;if(b.wf)throw b.lf;return{value:b["return"],done:!0}}return{value:void 0,done:!0}}
22
+ function Ca(a){for(;a.g.g;)try{var b=a.h(a.g);if(b)return a.g.A=!1,{value:b.value,done:!1}}catch(c){a.g.h=void 0,ta(a.g,c)}a.g.A=!1;if(a.g.i){b=a.g.i;a.g.i=null;if(b.xf)throw b.mf;return{value:b["return"],done:!0}}return{value:void 0,done:!0}}
23
23
  function Da(a){this.next=function(b){sa(a.g);a.g.l?b=Ba(a,a.g.l.next,b,a.g.B):(a.g.B(b),b=Ca(a));return b};this["throw"]=function(b){sa(a.g);a.g.l?b=Ba(a,a.g.l["throw"],b,a.g.B):(ta(a.g,b),b=Ca(a));return b};this["return"]=function(b){return Aa(a,b)};this[Symbol.iterator]=function(){return this}}
24
24
  function Ea(a){function b(d){return a.next(d)}function c(d){return a["throw"](d)}return new Promise(function(d,e){function f(g){g.done?d(g.value):Promise.resolve(g.value).then(b,c).then(f,e)}f(a.next())})}function I(a){return Ea(new Da(new za(a)))}function Ha(){for(var a=Number(this),b=[],c=a;c<arguments.length;c++)b[c-a]=arguments[c];return b}
25
25
  ea("Promise",function(a){function b(g){this.h=0;this.i=void 0;this.g=[];this.A=!1;var h=this.j();try{g(h.resolve,h.reject)}catch(k){h.reject(k)}}function c(){this.g=null}function d(g){return g instanceof b?g:new b(function(h){h(g)})}if(a)return a;c.prototype.h=function(g){if(null==this.g){this.g=[];var h=this;this.i(function(){h.l()})}this.g.push(g)};var e=da.setTimeout;c.prototype.i=function(g){e(g,0)};c.prototype.l=function(){for(;this.g&&this.g.length;){var g=this.g;this.g=[];for(var h=0;h<g.length;++h){var k=
26
26
  g[h];g[h]=null;try{k()}catch(l){this.j(l)}}}this.g=null};c.prototype.j=function(g){this.i(function(){throw g;})};b.prototype.j=function(){function g(l){return function(m){k||(k=!0,l.call(h,m))}}var h=this,k=!1;return{resolve:g(this.H),reject:g(this.l)}};b.prototype.H=function(g){if(g===this)this.l(new TypeError("A Promise cannot resolve to itself"));else if(g instanceof b)this.J(g);else{a:switch(typeof g){case "object":var h=null!=g;break a;case "function":h=!0;break a;default:h=!1}h?this.G(g):this.m(g)}};
27
27
  b.prototype.G=function(g){var h=void 0;try{h=g.then}catch(k){this.l(k);return}"function"==typeof h?this.K(h,g):this.m(g)};b.prototype.l=function(g){this.B(2,g)};b.prototype.m=function(g){this.B(1,g)};b.prototype.B=function(g,h){if(0!=this.h)throw Error("Cannot settle("+g+", "+h+"): Promise already settled in state"+this.h);this.h=g;this.i=h;2===this.h&&this.I();this.C()};b.prototype.I=function(){var g=this;e(function(){if(g.F()){var h=da.console;"undefined"!==typeof h&&h.error(g.i)}},1)};b.prototype.F=
28
28
  function(){if(this.A)return!1;var g=da.CustomEvent,h=da.Event,k=da.dispatchEvent;if("undefined"===typeof k)return!0;"function"===typeof g?g=new g("unhandledrejection",{cancelable:!0}):"function"===typeof h?g=new h("unhandledrejection",{cancelable:!0}):(g=da.document.createEvent("CustomEvent"),g.initCustomEvent("unhandledrejection",!1,!0,g));g.promise=this;g.reason=this.i;return k(g)};b.prototype.C=function(){if(null!=this.g){for(var g=0;g<this.g.length;++g)f.h(this.g[g]);this.g=null}};var f=new c;
29
- b.prototype.J=function(g){var h=this.j();g.ed(h.resolve,h.reject)};b.prototype.K=function(g,h){var k=this.j();try{g.call(h,k.resolve,k.reject)}catch(l){k.reject(l)}};b.prototype.then=function(g,h){function k(p,r){return"function"==typeof p?function(x){try{l(p(x))}catch(y){m(y)}}:r}var l,m,n=new b(function(p,r){l=p;m=r});this.ed(k(g,l),k(h,m));return n};b.prototype["catch"]=function(g){return this.then(void 0,g)};b.prototype.ed=function(g,h){function k(){switch(l.h){case 1:g(l.i);break;case 2:h(l.i);
30
- break;default:throw Error("Unexpected state: "+l.h);}}var l=this;null==this.g?f.h(k):this.g.push(k);this.A=!0};b.resolve=d;b.reject=function(g){return new b(function(h,k){k(g)})};b.race=function(g){return new b(function(h,k){for(var l=t(g),m=l.next();!m.done;m=l.next())d(m.value).ed(h,k)})};b.all=function(g){var h=t(g),k=h.next();return k.done?d([]):new b(function(l,m){function n(x){return function(y){p[x]=y;r--;0==r&&l(p)}}var p=[],r=0;do p.push(void 0),r++,d(k.value).ed(n(p.length-1),m),k=h.next();
29
+ b.prototype.J=function(g){var h=this.j();g.ed(h.resolve,h.reject)};b.prototype.K=function(g,h){var k=this.j();try{g.call(h,k.resolve,k.reject)}catch(l){k.reject(l)}};b.prototype.then=function(g,h){function k(p,r){return"function"==typeof p?function(w){try{l(p(w))}catch(y){m(y)}}:r}var l,m,n=new b(function(p,r){l=p;m=r});this.ed(k(g,l),k(h,m));return n};b.prototype["catch"]=function(g){return this.then(void 0,g)};b.prototype.ed=function(g,h){function k(){switch(l.h){case 1:g(l.i);break;case 2:h(l.i);
30
+ break;default:throw Error("Unexpected state: "+l.h);}}var l=this;null==this.g?f.h(k):this.g.push(k);this.A=!0};b.resolve=d;b.reject=function(g){return new b(function(h,k){k(g)})};b.race=function(g){return new b(function(h,k){for(var l=t(g),m=l.next();!m.done;m=l.next())d(m.value).ed(h,k)})};b.all=function(g){var h=t(g),k=h.next();return k.done?d([]):new b(function(l,m){function n(w){return function(y){p[w]=y;r--;0==r&&l(p)}}var p=[],r=0;do p.push(void 0),r++,d(k.value).ed(n(p.length-1),m),k=h.next();
31
31
  while(!k.done)})};return b});function Ia(a,b){return Object.prototype.hasOwnProperty.call(a,b)}
32
32
  ea("WeakMap",function(a){function b(k){this.g=(h+=Math.random()+1).toString();if(k){k=t(k);for(var l;!(l=k.next()).done;)l=l.value,this.set(l[0],l[1])}}function c(){}function d(k){var l=typeof k;return"object"===l&&null!==k||"function"===l}function e(k){if(!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({}),
33
33
  m=new a([[k,2],[l,3]]);if(2!=m.get(k)||3!=m.get(l))return!1;m["delete"](k);m.set(l,4);return!m.has(k)&&4==m.get(l)}catch(n){return!1}}())return a;var g="$jscomp_hidden_"+Math.random();f("freeze");f("preventExtensions");f("seal");var h=0;b.prototype.set=function(k,l){if(!d(k))throw Error("Invalid WeakMap key");e(k);if(!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)&&
@@ -40,7 +40,7 @@ m;!(m=l.next()).done;)m=m.value,h.call(k,m[1],m[0],this)};e.prototype[Symbol.ite
40
40
  ea("Set",function(a){function b(c){this.g=new Map;if(c){c=t(c);for(var d;!(d=c.next()).done;)this.add(d.value)}this.size=this.g.size}if(function(){if(!a||"function"!=typeof a||!a.prototype.entries||"function"!=typeof Object.seal)return!1;try{var c=Object.seal({x:4}),d=new a(t([c]));if(!d.has(c)||1!=d.size||d.add(c)!=d||1!=d.size||d.add({x:4})!=d||2!=d.size)return!1;var e=d.entries(),f=e.next();if(f.done||f.value[0]!=c||f.value[1]!=c)return!1;f=e.next();return f.done||f.value[0]==c||4!=f.value[0].x||
41
41
  f.value[1]!=f.value[0]?!1:e.next().done}catch(g){return!1}}())return a;b.prototype.add=function(c){c=0===c?0:c;this.g.set(c,c);this.size=this.g.size;return this};b.prototype["delete"]=function(c){c=this.g["delete"](c);this.size=this.g.size;return c};b.prototype.clear=function(){this.g.clear();this.size=0};b.prototype.has=function(c){return this.g.has(c)};b.prototype.entries=function(){return this.g.entries()};b.prototype.values=function(){return this.g.values()};b.prototype.keys=b.prototype.values;
42
42
  b.prototype[Symbol.iterator]=b.prototype.values;b.prototype.forEach=function(c,d){var e=this;this.g.forEach(function(f){return c.call(d,f,f,e)})};return b});ea("Array.from",function(a){return a?a:function(b,c,d){c=null!=c?c:function(h){return h};var e=[],f="undefined"!=typeof Symbol&&Symbol.iterator&&b[Symbol.iterator];if("function"==typeof f){b=f.call(b);for(var g=0;!(f=b.next()).done;)e.push(c.call(d,f.value,g++))}else for(f=b.length,g=0;g<f;g++)e.push(c.call(d,b[g],g));return e}});
43
- function Ka(a,b,c){a instanceof String&&(a=String(a));for(var d=a.length,e=0;e<d;e++){var f=a[e];if(b.call(c,f,e,a))return{uf:e,v:f}}return{uf:-1,v:void 0}}ea("Array.prototype.findIndex",function(a){return a?a:function(b,c){return Ka(this,b,c).uf}});ea("Object.is",function(a){return a?a:function(b,c){return b===c?0!==b||1/b===1/c:b!==b&&c!==c}});
43
+ function Ka(a,b,c){a instanceof String&&(a=String(a));for(var d=a.length,e=0;e<d;e++){var f=a[e];if(b.call(c,f,e,a))return{vf:e,v:f}}return{vf:-1,v:void 0}}ea("Array.prototype.findIndex",function(a){return a?a:function(b,c){return Ka(this,b,c).vf}});ea("Object.is",function(a){return a?a:function(b,c){return b===c?0!==b||1/b===1/c:b!==b&&c!==c}});
44
44
  ea("Array.prototype.includes",function(a){return a?a:function(b,c){var d=this;d instanceof String&&(d=String(d));var e=d.length,f=c||0;for(0>f&&(f=Math.max(f+e,0));f<e;f++){var g=d[f];if(g===b||Object.is(g,b))return!0}return!1}});function Ma(a,b,c){if(null==a)throw new TypeError("The 'this' value for String.prototype."+c+" must not be null or undefined");if(b instanceof RegExp)throw new TypeError("First argument to String.prototype."+c+" must not be a regular expression");return a+""}
45
45
  ea("String.prototype.includes",function(a){return a?a:function(b,c){return-1!==Ma(this,b,"includes").indexOf(b,c||0)}});ea("Array.prototype.find",function(a){return a?a:function(b,c){return Ka(this,b,c).v}});ea("String.prototype.startsWith",function(a){return a?a:function(b,c){for(var d=Ma(this,b,"startsWith"),e=d.length,f=b.length,g=Math.max(0,Math.min(c|0,d.length)),h=0;h<f&&g<e;)if(d[g++]!=b[h++])return!1;return h>=f}});
46
46
  var Na="function"==typeof Object.assign?Object.assign:function(a,b){for(var c=1;c<arguments.length;c++){var d=arguments[c];if(d)for(var e in d)Ia(d,e)&&(a[e]=d[e])}return a};ea("Object.assign",function(a){return a||Na});ea("Array.prototype.values",function(a){return a?a:function(){return Ja(this,function(b,c){return c})}});
@@ -53,10 +53,10 @@ function J(a,b){var c=a.split("."),d=Oa;c[0]in d||"undefined"==typeof d.execScri
53
53
  Copyright 2016 Google LLC
54
54
  SPDX-License-Identifier: Apache-2.0
55
55
  */
56
- function M(a,b){if(b)if(b instanceof Map)for(var c=t(b.keys()),d=c.next();!d.done;d=c.next())d=d.value,Object.defineProperty(this,d,{value:b.get(d),writable:!0,enumerable:!0});else for(c in b)Object.defineProperty(this,c,{value:b[c],writable:!0,enumerable:!0});this.defaultPrevented=this.cancelable=this.bubbles=!1;this.timeStamp=window.performance&&window.performance.now?window.performance.now():Date.now();this.type=a;this.isTrusted=!1;this.target=this.currentTarget=null;this.g=!1}
57
- function Pa(a){var b=new M(a.type),c;for(c in a)Object.defineProperty(b,c,{value:a[c],writable:!0,enumerable:!0});return b}M.prototype.preventDefault=function(){this.cancelable&&(this.defaultPrevented=!0)};M.prototype.stopImmediatePropagation=function(){this.g=!0};M.prototype.stopPropagation=function(){};J("shaka.util.FakeEvent",M);
58
- var Qa={Bh:"abrstatuschanged",Ch:"adaptation",Dh:"buffering",Hh:"downloadfailed",Ih:"downloadheadersreceived",Jh:"drmsessionupdate",Qh:"emsg",Error:"error",Rh:"expirationupdated",Uh:"gapjumped",Yh:"loaded",Zh:"loading",di:"manifestparsed",ei:"mediaqualitychanged",Metadata:"metadata",li:"onstatechange",mi:"onstateidle",zi:"ratechange",Fi:"sessiondata",Gi:"stalldetected",Hi:"streaming",Ii:"textchanged",Ji:"texttrackvisibility",Ki:"timelineregionadded",Li:"timelineregionenter",Mi:"timelineregionexit",
59
- Ni:"trackschanged",Si:"unloading",Ui:"variantchanged"};function Sa(){}function Ta(){}function Ua(){}function Va(a){var b=Ha.apply(1,arguments);Wa.has(a)||(Wa.add(a),Ua.apply(Sa,ia(b)))}function Xa(){}function Ya(){}function Za(){}function $a(){}var Wa=new Set;if(window.console&&window.console.log.bind){var bb={},cb=(bb[1]=console.error.bind(console),bb[2]=console.warn.bind(console),bb[3]=console.info.bind(console),bb[4]=console.log.bind(console),bb[5]=console.debug.bind(console),bb[6]=console.debug.bind(console),bb);Ua=cb[2];Ta=cb[1]};function db(){this.g={}}q=db.prototype;q.push=function(a,b){this.g.hasOwnProperty(a)?this.g[a].push(b):this.g[a]=[b]};q.get=function(a){return(a=this.g[a])?a.slice():null};q.remove=function(a,b){a in this.g&&(this.g[a]=this.g[a].filter(function(c){return c!=b}),0==this.g[a].length&&delete this.g[a])};function eb(a,b){for(var c in a.g)b(c,a.g[c])}q.size=function(){return Object.keys(this.g).length};q.keys=function(){return Object.keys(this.g)};function fb(){this.ua=new db;this.rd=this}fb.prototype.addEventListener=function(a,b){this.ua&&this.ua.push(a,b)};fb.prototype.removeEventListener=function(a,b){this.ua&&this.ua.remove(a,b)};fb.prototype.dispatchEvent=function(a){if(!this.ua)return!0;var b=this.ua.get(a.type)||[],c=this.ua.get("All");c&&(b=b.concat(c));b=t(b);for(c=b.next();!c.done;c=b.next()){c=c.value;a.target=this.rd;a.currentTarget=this.rd;try{c.handleEvent?c.handleEvent(a):c.call(this,a)}catch(d){}if(a.g)break}return a.defaultPrevented};
56
+ function L(a,b){if(b)if(b instanceof Map)for(var c=t(b.keys()),d=c.next();!d.done;d=c.next())d=d.value,Object.defineProperty(this,d,{value:b.get(d),writable:!0,enumerable:!0});else for(c in b)Object.defineProperty(this,c,{value:b[c],writable:!0,enumerable:!0});this.defaultPrevented=this.cancelable=this.bubbles=!1;this.timeStamp=window.performance&&window.performance.now?window.performance.now():Date.now();this.type=a;this.isTrusted=!1;this.target=this.currentTarget=null;this.g=!1}
57
+ function Pa(a){var b=new L(a.type),c;for(c in a)Object.defineProperty(b,c,{value:a[c],writable:!0,enumerable:!0});return b}L.prototype.preventDefault=function(){this.cancelable&&(this.defaultPrevented=!0)};L.prototype.stopImmediatePropagation=function(){this.g=!0};L.prototype.stopPropagation=function(){};J("shaka.util.FakeEvent",L);
58
+ var Qa={Ch:"abrstatuschanged",Dh:"adaptation",Eh:"buffering",Ih:"downloadfailed",Jh:"downloadheadersreceived",Kh:"drmsessionupdate",Rh:"emsg",Error:"error",Sh:"expirationupdated",Vh:"gapjumped",Zh:"loaded",$h:"loading",ei:"manifestparsed",gi:"mediaqualitychanged",Metadata:"metadata",mi:"onstatechange",ni:"onstateidle",Ai:"ratechange",Gi:"sessiondata",Hi:"stalldetected",Ii:"streaming",Ji:"textchanged",Ki:"texttrackvisibility",Li:"timelineregionadded",Mi:"timelineregionenter",Ni:"timelineregionexit",
59
+ Oi:"trackschanged",Ti:"unloading",Vi:"variantchanged"};function Ra(){}function Ta(){}function Ua(){}function Va(a){var b=Ha.apply(1,arguments);Wa.has(a)||(Wa.add(a),Ua.apply(Ra,ia(b)))}function Xa(){}function Ya(){}function Za(){}function $a(){}var Wa=new Set;if(window.console&&window.console.log.bind){var bb={},cb=(bb[1]=console.error.bind(console),bb[2]=console.warn.bind(console),bb[3]=console.info.bind(console),bb[4]=console.log.bind(console),bb[5]=console.debug.bind(console),bb[6]=console.debug.bind(console),bb);Ua=cb[2];Ta=cb[1]};function db(){this.g={}}q=db.prototype;q.push=function(a,b){this.g.hasOwnProperty(a)?this.g[a].push(b):this.g[a]=[b]};q.get=function(a){return(a=this.g[a])?a.slice():null};q.remove=function(a,b){a in this.g&&(this.g[a]=this.g[a].filter(function(c){return c!=b}),0==this.g[a].length&&delete this.g[a])};function eb(a,b){for(var c in a.g)b(c,a.g[c])}q.size=function(){return Object.keys(this.g).length};q.keys=function(){return Object.keys(this.g)};function fb(){this.ua=new db;this.rd=this}fb.prototype.addEventListener=function(a,b){this.ua&&this.ua.push(a,b)};fb.prototype.removeEventListener=function(a,b){this.ua&&this.ua.remove(a,b)};fb.prototype.dispatchEvent=function(a){if(!this.ua)return!0;var b=this.ua.get(a.type)||[],c=this.ua.get("All");c&&(b=b.concat(c));b=t(b);for(c=b.next();!c.done;c=b.next()){c=c.value;a.target=this.rd;a.currentTarget=this.rd;try{c.handleEvent?c.handleEvent(a):c.call(this,a)}catch(d){}if(a.g)break}return a.defaultPrevented};
60
60
  fb.prototype.release=function(){this.ua=null};function gb(a,b){for(var c=[],d=t(a),e=d.next();!e.done;e=d.next())c.push(b(e.value));return c}function hb(a,b){for(var c=t(a),d=c.next();!d.done;d=c.next())if(!b(d.value))return!1;return!0}function ib(a,b){for(var c=t(a),d=c.next();!d.done;d=c.next())if(b(d.value))return!0;return!1}function jb(a,b){for(var c=[],d=t(a),e=d.next();!e.done;e=d.next())e=e.value,b(e)&&c.push(e);return c};/*
61
61
  @license
62
62
  Copyright 2008 The Closure Library Authors
@@ -82,7 +82,7 @@ HLS_AES_128_ENCRYPTION_NOT_SUPPORTED:4034,HLS_INTERNAL_SKIP_STREAM:4035,NO_VARIA
82
82
  LICENSE_REQUEST_FAILED:6007,LICENSE_RESPONSE_REJECTED:6008,ENCRYPTED_CONTENT_WITHOUT_DRM_INFO:6010,NO_LICENSE_SERVER_GIVEN:6012,OFFLINE_SESSION_REMOVED:6013,EXPIRED:6014,SERVER_CERTIFICATE_REQUIRED:6015,INIT_DATA_TRANSFORM_ERROR:6016,SERVER_CERTIFICATE_REQUEST_FAILED:6017,LOAD_INTERRUPTED:7E3,OPERATION_ABORTED:7001,NO_VIDEO_ELEMENT:7002,OBJECT_DESTROYED:7003,CONTENT_NOT_LOADED:7004,CAST_API_UNAVAILABLE:8E3,NO_CAST_RECEIVERS:8001,ALREADY_CASTING:8002,UNEXPECTED_CAST_ERROR:8003,CAST_CANCELED_BY_USER:8004,
83
83
  CAST_CONNECTION_TIMED_OUT:8005,CAST_RECEIVER_APP_UNAVAILABLE:8006,STORAGE_NOT_SUPPORTED:9E3,INDEXED_DB_ERROR:9001,DEPRECATED_OPERATION_ABORTED:9002,REQUESTED_ITEM_NOT_FOUND:9003,MALFORMED_OFFLINE_URI:9004,CANNOT_STORE_LIVE_OFFLINE:9005,NO_INIT_DATA_FOR_OFFLINE:9007,LOCAL_PLAYER_INSTANCE_REQUIRED:9008,NEW_KEY_OPERATION_NOT_SUPPORTED:9011,KEY_NOT_FOUND:9012,MISSING_STORAGE_CELL:9013,STORAGE_LIMIT_REACHED:9014,DOWNLOAD_SIZE_CALLBACK_ERROR:9015,MODIFY_OPERATION_NOT_SUPPORTED:9016,CS_IMA_SDK_MISSING:1E4,
84
84
  CS_AD_MANAGER_NOT_INITIALIZED:10001,SS_IMA_SDK_MISSING:10002,SS_AD_MANAGER_NOT_INITIALIZED:10003,CURRENT_DAI_REQUEST_NOT_FINISHED:10004};function Ab(a,b){return a.concat(b)}function Bb(){}function Cb(a){return null!=a};function Db(a,b){if(0==b.length)return a;var c=b.map(function(d){return new lb(d)});return a.map(function(d){return new lb(d)}).map(function(d){return c.map(function(e){return d.resolve(e)})}).reduce(Ab,[]).map(function(d){return d.toString()})}function Eb(a,b){return{keySystem:a,licenseServerUri:"",distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,serverCertificateUri:"",sessionType:"",initData:b||[],keyIds:new Set}}
85
- function Fb(a,b){if(1==b.length)return b[0];var c=Gb(a,b);if(null!=c)return c;throw new O(2,4,4025,b);}function Gb(a,b){for(var c=t(Hb[a]),d=c.next();!d.done;d=c.next()){d=d.value;for(var e=t(b),f=e.next();!f.done;f=e.next())if(f=f.value,d.test(f.trim()))return f.trim()}return a==Ib?"":null}var Ib="text",Jb={Ma:"video",Fb:"audio",ha:Ib,xc:"image",xh:"application"},Hb={audio:[/^vorbis$/,/^opus$/,/^flac$/,/^mp4a/,/^[ae]c-3$/],video:[/^avc/,/^hev/,/^hvc/,/^vp0?[89]/,/^av01/],text:[/^vtt$/,/^wvtt/,/^stpp/]};function Kb(){}function Lb(a,b){a=Mb(a);b=Mb(b);return a.split("-")[0]==b.split("-")[0]}function Nb(a,b){a=Mb(a);b=Mb(b);var c=a.split("-"),d=b.split("-");return c[0]==d[0]&&1==c.length&&2==d.length}function Ob(a,b){a=Mb(a);b=Mb(b);var c=a.split("-"),d=b.split("-");return 2==c.length&&2==d.length&&c[0]==d[0]}function Mb(a){var b=a.split("-");a=b[0]||"";b=b[1]||"";a=a.toLowerCase();a=Pb.get(a)||a;return(b=b.toUpperCase())?a+"-"+b:a}function Qb(a,b){var c=Rb(a),d=Rb(b);return a!=c&&b!=d&&c==d}
85
+ function Fb(a,b){if(1==b.length)return b[0];var c=Gb(a,b);if(null!=c)return c;throw new O(2,4,4025,b);}function Gb(a,b){for(var c=t(Hb[a]),d=c.next();!d.done;d=c.next()){d=d.value;for(var e=t(b),f=e.next();!f.done;f=e.next())if(f=f.value,d.test(f.trim()))return f.trim()}return a==Ib?"":null}var Ib="text",Jb={Ma:"video",Fb:"audio",ha:Ib,xc:"image",yh:"application"},Hb={audio:[/^vorbis$/,/^opus$/,/^flac$/,/^mp4a/,/^[ae]c-3$/],video:[/^avc/,/^hev/,/^hvc/,/^vp0?[89]/,/^av01/],text:[/^vtt$/,/^wvtt/,/^stpp/]};function Kb(){}function Lb(a,b){a=Mb(a);b=Mb(b);return a.split("-")[0]==b.split("-")[0]}function Nb(a,b){a=Mb(a);b=Mb(b);var c=a.split("-"),d=b.split("-");return c[0]==d[0]&&1==c.length&&2==d.length}function Ob(a,b){a=Mb(a);b=Mb(b);var c=a.split("-"),d=b.split("-");return 2==c.length&&2==d.length&&c[0]==d[0]}function Mb(a){var b=a.split("-");a=b[0]||"";b=b[1]||"";a=a.toLowerCase();a=Pb.get(a)||a;return(b=b.toUpperCase())?a+"-"+b:a}function Qb(a,b){var c=Rb(a),d=Rb(b);return a!=c&&b!=d&&c==d}
86
86
  function Sb(a,b){a=Mb(a);b=Mb(b);return b==a?4:Nb(b,a)?3:Ob(b,a)?2:Nb(a,b)?1:0}function Rb(a){var b=a.indexOf("-");a=0<=b?a.substring(0,b):a;a=a.toLowerCase();return a=Pb.get(a)||a}function Tb(a){return a.language?Mb(a.language):a.audio&&a.audio.language?Mb(a.audio.language):a.video&&a.video.language?Mb(a.video.language):"und"}
87
87
  function Ub(a,b){for(var c=Mb(a),d=new Set,e=t(b),f=e.next();!f.done;f=e.next())d.add(Mb(f.value));e=t(d);for(f=e.next();!f.done;f=e.next())if(f=f.value,f==c)return f;e=t(d);for(f=e.next();!f.done;f=e.next())if(f=f.value,Nb(f,c))return f;e=t(d);for(f=e.next();!f.done;f=e.next())if(f=f.value,Ob(f,c))return f;d=t(d);for(f=d.next();!f.done;f=d.next())if(f=f.value,Nb(c,f))return f;return null}J("shaka.util.LanguageUtils",Kb);Kb.findClosestLocale=Ub;Kb.getLocaleForVariant=Tb;
88
88
  Kb.getLocaleForText=function(a){return Mb(a.language||"und")};Kb.getBase=Rb;Kb.relatedness=Sb;Kb.areSiblings=Qb;Kb.normalize=Mb;Kb.isSiblingOf=Ob;Kb.isParentOf=Nb;Kb.areLanguageCompatible=Lb;Kb.areLocaleCompatible=function(a,b){a=Mb(a);b=Mb(b);return a==b};
@@ -92,815 +92,817 @@ var Pb=new Map([["aar","aa"],["abk","ab"],["afr","af"],["aka","ak"],["alb","sq"]
92
92
  "mi"],["mar","mr"],["may","ms"],["mkd","mk"],["mlg","mg"],["mlt","mt"],["mon","mn"],["mri","mi"],["msa","ms"],["mya","my"],["nau","na"],["nav","nv"],["nbl","nr"],["nde","nd"],["ndo","ng"],["nep","ne"],["nld","nl"],["nno","nn"],["nob","nb"],["nor","no"],["nya","ny"],["oci","oc"],["oji","oj"],["ori","or"],["orm","om"],["oss","os"],["pan","pa"],["per","fa"],["pli","pi"],["pol","pl"],["por","pt"],["pus","ps"],["que","qu"],["roh","rm"],["ron","ro"],["rum","ro"],["run","rn"],["rus","ru"],["sag","sg"],["san",
93
93
  "sa"],["sin","si"],["slk","sk"],["slo","sk"],["slv","sl"],["sme","se"],["smo","sm"],["sna","sn"],["snd","sd"],["som","so"],["sot","st"],["spa","es"],["sqi","sq"],["srd","sc"],["srp","sr"],["ssw","ss"],["sun","su"],["swa","sw"],["swe","sv"],["tah","ty"],["tam","ta"],["tat","tt"],["tel","te"],["tgk","tg"],["tgl","tl"],["tha","th"],["tib","bo"],["tir","ti"],["ton","to"],["tsn","tn"],["tso","ts"],["tuk","tk"],["tur","tr"],["twi","tw"],["uig","ug"],["ukr","uk"],["urd","ur"],["uzb","uz"],["ven","ve"],["vie",
94
94
  "vi"],["vol","vo"],["wel","cy"],["wln","wa"],["wol","wo"],["xho","xh"],["yid","yi"],["yor","yo"],["zha","za"],["zho","zh"],["zul","zu"]]);function Vb(a){fb.call(this);this.j=Mb(a);this.i=new Map;this.g=new Set;this.h=new Map}qa(Vb,fb);q=Vb.prototype;q.release=function(){fb.prototype.release.call(this)};
95
- q.bf=function(a){var b=this;this.g.clear();a=t(a);for(var c=a.next();!c.done;c=a.next())this.g.add(Mb(c.value));Wb(this);a=jb(this.g,function(d){return!b.h.has(d)});a.length&&this.dispatchEvent(new M("unknown-locales",(new Map).set("locales",a)));a=jb(this.g,function(d){return b.h.has(d)});a=(new Map).set("locales",a.length?a:[this.j]);this.dispatchEvent(new M("locale-changed",a))};
96
- q.ia=function(a,b,c){a=Mb(a);void 0===c&&(c=Xb);var d=this.h.get(a)||new Map;b.forEach(function(e,f){d.has(f)&&c!=Xb||d.set(f,e)});this.h.set(a,d);Wb(this);this.dispatchEvent(new M("locale-updated"));return this};q.fh=function(a){for(var b=t(a.keys()),c=b.next();!c.done;c=b.next())c=c.value,a.set(c,this.resolve(c))};q.resolve=function(a){var b=this.i.get(a);if(b)return b;a=(new Map).set("locales",Array.from(this.g)).set("missing",a);this.dispatchEvent(new M("unknown-localization",a));return""};
95
+ q.cf=function(a){var b=this;this.g.clear();a=t(a);for(var c=a.next();!c.done;c=a.next())this.g.add(Mb(c.value));Wb(this);a=jb(this.g,function(d){return!b.h.has(d)});a.length&&this.dispatchEvent(new L("unknown-locales",(new Map).set("locales",a)));a=jb(this.g,function(d){return b.h.has(d)});a=(new Map).set("locales",a.length?a:[this.j]);this.dispatchEvent(new L("locale-changed",a))};
96
+ q.ia=function(a,b,c){a=Mb(a);void 0===c&&(c=Xb);var d=this.h.get(a)||new Map;b.forEach(function(e,f){d.has(f)&&c!=Xb||d.set(f,e)});this.h.set(a,d);Wb(this);this.dispatchEvent(new L("locale-updated"));return this};q.gh=function(a){for(var b=t(a.keys()),c=b.next();!c.done;c=b.next())c=c.value,a.set(c,this.resolve(c))};q.resolve=function(a){var b=this.i.get(a);if(b)return b;a=(new Map).set("locales",Array.from(this.g)).set("missing",a);this.dispatchEvent(new L("unknown-localization",a));return""};
97
97
  function Wb(a){for(var b=a.h,c=a.j,d=a.g,e=new Set,f={},g=t(d),h=g.next();!h.done;f={Wb:f.Wb},h=g.next()){f.Wb=h.value;e.add(f.Wb);e.add(Rb(f.Wb));h=jb(b.keys(),function(l){return function(m){return Qb(m,l.Wb)}}(f));h.sort();var k=t(h);for(h=k.next();!h.done;h=k.next())e.add(h.value);h=jb(b.keys(),function(l){return function(m){return Rb(m)==l.Wb}}(f));h.sort();k=t(h);for(h=k.next();!h.done;h=k.next())e.add(h.value)}e.add(c);c=[];e=t(e);for(h=e.next();!h.done;h=e.next())(h=b.get(h.value))&&c.push(h);
98
- c.reverse();a.i.clear();b=t(c);for(h=b.next();!h.done;h=b.next())h.value.forEach(function(l,m){a.i.set(m,l)});b=a.i.keys();e=new Set;c=t(a.g);for(h=c.next();!h.done;h=c.next())h=a.h.get(h.value)||new Map,Yb(h,b,e);0<e.size&&(d=(new Map).set("locales",Array.from(d)).set("missing",Array.from(e)),a.dispatchEvent(new M("missing-localizations",d)))}function Yb(a,b,c){b=t(b);for(var d=b.next();!d.done;d=b.next())d=d.value,a.get(d)||c.add(d)}J("shaka.ui.Localization",Vb);Vb.prototype.resolve=Vb.prototype.resolve;
99
- Vb.prototype.resolveDictionary=Vb.prototype.fh;Vb.prototype.insert=Vb.prototype.ia;Vb.prototype.changeLocale=Vb.prototype.bf;Vb.prototype.release=Vb.prototype.release;var Xb=1;Vb.ConflictResolution={USE_OLD:0,USE_NEW:Xb};Vb.UNKNOWN_LOCALES="unknown-locales";Vb.UNKNOWN_LOCALIZATION="unknown-localization";Vb.MISSING_LOCALIZATIONS="missing-localizations";Vb.LOCALE_CHANGED="locale-changed";Vb.LOCALE_UPDATED="locale-updated";var Zb={ai:"MORE_SETTINGS",Fh:"CAST",We:"LIVE",Sh:"FAST_FORWARD",Ai:"SEEK",Eh:"CAPTIONS",ti:"REPLAY",Nh:"EXIT_FULL_SCREEN",Th:"FULL_SCREEN",Pi:"UNDETERMINED_LANGUAGE",yh:"AUTO_QUALITY",ni:"PAUSE",Ei:"STATISTICS",ri:"PLAYBACK_RATE",gi:"NOT_APPLICABLE",AD_PROGRESS:"AD_PROGRESS",wi:"RESOLUTION",Oh:"EXIT_LOOP_MODE",Wh:"LANGUAGE",BACK:"BACK",Ci:"SKIP_TO_LIVE",Qf:"SUBTITLE_FORCED",vh:"AD_TIME",ii:"OFF",pi:"PLAY",Xh:"LOOP",Lh:"ENTER_PICTURE_IN_PICTURE",xi:"REWIND",uh:"AD_DURATION",Qi:"UNMUTE",Ri:"UNRECOGNIZED_LANGUAGE",
100
- wh:"AIRPLAY",Bi:"SKIP_AD",ci:"MUTE",Ti:"VOLUME",bi:"MULTIPLE_LANGUAGES",ji:"ON",oi:"PICTURE_IN_PICTURE",Kh:"ENTER_LOOP_MODE",Ph:"EXIT_PICTURE_IN_PICTURE",si:"QUALITY"};function $b(a){this.g=Math.exp(Math.log(.5)/a);this.i=this.h=0}$b.prototype.sample=function(a,b){var c=Math.pow(this.g,a);c=b*(1-c)+c*this.h;isNaN(c)||(this.h=c,this.i+=a)};function ac(a){return a.h/(1-Math.pow(a.g,a.i))};function bc(){this.h=new $b(2);this.j=new $b(5);this.g=0;this.i=128E3;this.l=16E3}bc.prototype.configure=function(a){this.i=a.minTotalBytes;this.l=a.minBytes;this.h.g=Math.exp(Math.log(.5)/a.fastHalfLife);this.j.g=Math.exp(Math.log(.5)/a.slowHalfLife)};bc.prototype.sample=function(a,b){if(!(b<this.l)){var c=8E3*b/a,d=a/1E3;this.g+=b;this.h.sample(d,c);this.j.sample(d,c)}};bc.prototype.getBandwidthEstimate=function(a){return this.g<this.i?a:Math.min(ac(this.h),ac(this.j))};function cc(a,b){return"number"===typeof a&&"number"===typeof b&&isNaN(a)&&isNaN(b)?!0:a===b}function dc(a,b){var c=a.indexOf(b);-1<c&&a.splice(c,1)}function ec(a,b,c){c||(c=cc);if(a.length!=b.length)return!1;b=b.slice();var d={};a=t(a);for(var e=a.next();!e.done;d={Md:d.Md},e=a.next()){d.Md=e.value;e=b.findIndex(function(f){return function(g){return c(f.Md,g)}}(d));if(-1==e)return!1;b[e]=b[b.length-1];b.pop()}return 0==b.length}
101
- function fc(a,b,c){c||(c=cc);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 gc(a,b,c){this.startTime=a;this.direction=hc;this.endTime=b;this.payload=c;this.region=new ic;this.position=null;this.positionAlign=jc;this.size=0;this.textAlign=kc;this.writingMode=lc;this.lineInterpretation=mc;this.line=null;this.lineHeight="";this.lineAlign=nc;this.displayAlign=oc;this.fontSize=this.textStrokeWidth=this.textStrokeColor=this.textShadow=this.border=this.backgroundImage=this.backgroundColor=this.color="";this.fontWeight=pc;this.fontStyle=tc;this.linePadding=this.letterSpacing=
98
+ c.reverse();a.i.clear();b=t(c);for(h=b.next();!h.done;h=b.next())h.value.forEach(function(l,m){a.i.set(m,l)});b=a.i.keys();e=new Set;c=t(a.g);for(h=c.next();!h.done;h=c.next())h=a.h.get(h.value)||new Map,Yb(h,b,e);0<e.size&&(d=(new Map).set("locales",Array.from(d)).set("missing",Array.from(e)),a.dispatchEvent(new L("missing-localizations",d)))}function Yb(a,b,c){b=t(b);for(var d=b.next();!d.done;d=b.next())d=d.value,a.get(d)||c.add(d)}J("shaka.ui.Localization",Vb);Vb.prototype.resolve=Vb.prototype.resolve;
99
+ Vb.prototype.resolveDictionary=Vb.prototype.gh;Vb.prototype.insert=Vb.prototype.ia;Vb.prototype.changeLocale=Vb.prototype.cf;Vb.prototype.release=Vb.prototype.release;var Xb=1;Vb.ConflictResolution={USE_OLD:0,USE_NEW:Xb};Vb.UNKNOWN_LOCALES="unknown-locales";Vb.UNKNOWN_LOCALIZATION="unknown-localization";Vb.MISSING_LOCALIZATIONS="missing-localizations";Vb.LOCALE_CHANGED="locale-changed";Vb.LOCALE_UPDATED="locale-updated";var Zb={xi:"RESOLUTION",oi:"PAUSE",Ri:"UNMUTE",ii:"NOT_APPLICABLE",Si:"UNRECOGNIZED_LANGUAGE",ki:"ON",vh:"AD_DURATION",Xh:"LANGUAGE",Mh:"ENTER_PICTURE_IN_PICTURE",Lh:"ENTER_LOOP_MODE",Ci:"SKIP_AD",wi:"REPLAY",ci:"MULTIPLE_LANGUAGES",bi:"MORE_SETTINGS",Gh:"CAST",ri:"PLAY",Fi:"STATISTICS",pi:"PICTURE_IN_PICTURE",xh:"AIRPLAY",Xe:"LIVE",wh:"AD_TIME",Rf:"SUBTITLE_FORCED",Ah:"AUTO_QUALITY",Qi:"UNDETERMINED_LANGUAGE",Oh:"EXIT_FULL_SCREEN",Ph:"EXIT_LOOP_MODE",Bi:"SEEK",zi:"REWIND",di:"MUTE",Uh:"FULL_SCREEN",
100
+ ji:"OFF",Ui:"VOLUME",Th:"FAST_FORWARD",Di:"SKIP_TO_LIVE",AD_PROGRESS:"AD_PROGRESS",BACK:"BACK",Qh:"EXIT_PICTURE_IN_PICTURE",Yh:"LOOP",si:"PLAYBACK_RATE",Fh:"CAPTIONS",ti:"QUALITY"};function $b(a){this.g=Math.exp(Math.log(.5)/a);this.i=this.h=0}$b.prototype.sample=function(a,b){var c=Math.pow(this.g,a);c=b*(1-c)+c*this.h;isNaN(c)||(this.h=c,this.i+=a)};function ac(a){return a.h/(1-Math.pow(a.g,a.i))};function bc(){this.h=new $b(2);this.j=new $b(5);this.g=0;this.i=128E3;this.l=16E3}bc.prototype.configure=function(a){this.i=a.minTotalBytes;this.l=a.minBytes;this.h.g=Math.exp(Math.log(.5)/a.fastHalfLife);this.j.g=Math.exp(Math.log(.5)/a.slowHalfLife)};bc.prototype.sample=function(a,b){if(!(b<this.l)){var c=8E3*b/a,d=a/1E3;this.g+=b;this.h.sample(d,c);this.j.sample(d,c)}};bc.prototype.getBandwidthEstimate=function(a){return this.g<this.i?a:Math.min(ac(this.h),ac(this.j))};function cc(a,b){return"number"===typeof a&&"number"===typeof b&&isNaN(a)&&isNaN(b)?!0:a===b}function dc(a,b){var c=a.indexOf(b);-1<c&&a.splice(c,1)}function ec(a,b,c){c||(c=cc);if(a.length!=b.length)return!1;b=b.slice();var d={};a=t(a);for(var e=a.next();!e.done;d={Md:d.Md},e=a.next()){d.Md=e.value;e=b.findIndex(function(f){return function(g){return c(f.Md,g)}}(d));if(-1==e)return!1;b[e]=b[b.length-1];b.pop()}return 0==b.length}
101
+ function fc(a,b,c){c||(c=cc);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 gc(a,b,c){this.startTime=a;this.direction=hc;this.endTime=b;this.payload=c;this.region=new ic;this.position=null;this.positionAlign=jc;this.size=0;this.textAlign=kc;this.writingMode=lc;this.lineInterpretation=mc;this.line=null;this.lineHeight="";this.lineAlign=nc;this.displayAlign=oc;this.fontSize=this.textStrokeWidth=this.textStrokeColor=this.textShadow=this.border=this.backgroundImage=this.backgroundColor=this.color="";this.fontWeight=pc;this.fontStyle=qc;this.linePadding=this.letterSpacing=
102
102
  this.fontFamily="";this.opacity=1;this.textDecoration=[];this.wrapLine=!0;this.id="";this.nestedCues=[];this.lineBreak=this.isContainer=!1;this.cellResolution={columns:32,rows:15}}gc.prototype.clone=function(){var a=new gc(0,0,""),b;for(b in this)a[b]=this[b],a[b]&&a[b].constructor==Array&&(a[b]=a[b].slice());return a};
103
103
  function uc(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(!fc(a.nestedCues,b.nestedCues,uc))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(!fc(a[c],b[c]))return!1}else if(a[c]!=b[c])return!1;return!0}J("shaka.text.Cue",gc);var jc="auto";
104
104
  gc.positionAlign={LEFT:"line-left",RIGHT:"line-right",CENTER:"center",AUTO:jc};var kc="center",vc={LEFT:"left",RIGHT:"right",CENTER:kc,START:"start",END:"end"};gc.textAlign=vc;var oc="after",wc={BEFORE:"before",CENTER:"center",AFTER:oc};gc.displayAlign=wc;var hc="ltr";gc.direction={HORIZONTAL_LEFT_TO_RIGHT:hc,HORIZONTAL_RIGHT_TO_LEFT:"rtl"};var lc="horizontal-tb";gc.writingMode={HORIZONTAL_TOP_TO_BOTTOM:lc,VERTICAL_LEFT_TO_RIGHT:"vertical-lr",VERTICAL_RIGHT_TO_LEFT:"vertical-rl"};var mc=0;
105
105
  gc.lineInterpretation={LINE_NUMBER:mc,PERCENTAGE:1};var nc="start",xc={CENTER:"center",START:nc,END:"end"};gc.lineAlign=xc;var yc={white:"#FFF",lime:"#0F0",cyan:"#0FF",red:"#F00",yellow:"#FF0",magenta:"#F0F",blue:"#00F",black:"#000"};gc.defaultTextColor=yc;var zc={bg_white:"#FFF",bg_lime:"#0F0",bg_cyan:"#0FF",bg_red:"#F00",bg_yellow:"#FF0",bg_magenta:"#F0F",bg_blue:"#00F",bg_black:"#000"};gc.defaultTextBackgroundColor=zc;var pc=400;gc.fontWeight={NORMAL:pc,BOLD:700};
106
- var tc="normal",Ac={NORMAL:tc,ITALIC:"italic",OBLIQUE:"oblique"};gc.fontStyle=Ac;gc.textDecoration={UNDERLINE:"underline",LINE_THROUGH:"lineThrough",OVERLINE:"overline"};function ic(){this.id="";this.regionAnchorY=this.regionAnchorX=this.viewportAnchorY=this.viewportAnchorX=0;this.height=this.width=100;this.viewportAnchorUnits=this.widthUnits=this.heightUnits=Bc;this.scroll=Cc}J("shaka.text.CueRegion",ic);var Bc=1;ic.units={PX:0,PERCENTAGE:Bc,LINES:2};var Cc="";ic.scrollMode={NONE:Cc,UP:"up"};function Dc(){}function Ec(a,b){if(!a&&!b)return!0;if(!a||!b||a.byteLength!=b.byteLength)return!1;if(Fc(a)==Fc(b)&&(a.byteOffset||0)==(b.byteOffset||0))return!0;for(var c=Gc(a),d=Gc(b),e=0;e<a.byteLength;e++)if(c[e]!=d[e])return!1;return!0}function Fc(a){return a instanceof ArrayBuffer?a:a.buffer}function Hc(a){return a instanceof ArrayBuffer?a:0==a.byteOffset&&a.byteLength==a.buffer.byteLength?a.buffer:(new Uint8Array(a)).buffer}
107
- function Gc(a,b,c){c=void 0===c?Infinity:c;return Ic(a,void 0===b?0:b,c,Uint8Array)}function Jc(a,b,c){c=void 0===c?Infinity:c;return Ic(a,void 0===b?0:b,c,DataView)}function Ic(a,b,c,d){var e=(a.byteOffset||0)+a.byteLength;b=Math.max(0,Math.min((a.byteOffset||0)+b,e));return new d(Fc(a),b,Math.min(b+Math.max(c,0),e)-b)}J("shaka.util.BufferUtils",Dc);Dc.toDataView=Jc;Dc.toUint8=Gc;Dc.toArrayBuffer=Hc;Dc.equal=Ec;function Kc(){}J("shaka.dependencies",Kc);Kc.has=function(a){return Lc.has(a)};Kc.add=function(a,b){if(!Mc[a])throw Error(a+" is not supported");Lc.set(a,function(){return b})};var Mc={muxjs:"muxjs"};Kc.Allowed=Mc;var Lc=new Map([["muxjs",function(){return window.muxjs}]]);function Nc(){var a,b,c=new Promise(function(d,e){a=d;b=e});c.resolve=a;c.reject=b;return c}Nc.prototype.resolve=function(){};Nc.prototype.reject=function(){};function Oc(a){this.h=a;this.g=void 0}Oc.prototype.value=function(){void 0==this.g&&(this.g=this.h());return this.g};function Pc(){}function Rc(a){if(!a)return"";a=Gc(a);239==a[0]&&187==a[1]&&191==a[2]&&(a=a.subarray(3));a=(new TextDecoder).decode(a);a.includes("\ufffd")&&Ta('Decoded string contains an "unknown character" codepoint. That probably means the UTF8 encoding was incorrect!');return a}function Sc(a,b,c){if(!a)return"";if(!c&&0!=a.byteLength%2)throw new O(2,2,2004);c=Math.floor(a.byteLength/2);var d=new Uint16Array(c);a=Jc(a);for(var e=0;e<c;e++)d[e]=a.getUint16(2*e,b);return Tc.value()(d)}
108
- function Uc(a){function b(d){return c.byteLength<=d||32<=c[d]&&126>=c[d]}if(!a)return"";var c=Gc(a);if(239==c[0]&&187==c[1]&&191==c[2])return Rc(c);if(254==c[0]&&255==c[1])return Sc(c.subarray(2),!1);if(255==c[0]&&254==c[1])return Sc(c.subarray(2),!0);if(0==c[0]&&0==c[2])return Sc(a,!1);if(0==c[1]&&0==c[3])return Sc(a,!0);if(b(0)&&b(1)&&b(2)&&b(3))return Rc(a);throw new O(2,2,2003);}function Vc(a){var b=new TextEncoder;return Hc(b.encode(a))}
109
- function Wc(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}J("shaka.util.StringUtils",Pc);Pc.resetFromCharCode=function(){Tc.g=void 0};Pc.toUTF16=Wc;Pc.toUTF8=Vc;Pc.fromBytesAutoDetect=Uc;Pc.fromUTF16=Sc;Pc.fromUTF8=Rc;
110
- var Tc=new Oc(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 Xc(){}function Yc(a){a=Gc(a);a=Tc.value()(a);return btoa(a)}function Zc(a,b){b=void 0==b?!0:b;var c=Yc(a).replace(/\+/g,"-").replace(/\//g,"_");return b?c:c.replace(/[=]*$/,"")}function $c(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 ad(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}
111
- function bd(a){var b=Gc(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 cd(){for(var a=Ha.apply(0,arguments),b=0,c=t(a),d=c.next();!d.done;d=c.next())b+=d.value.byteLength;b=new Uint8Array(b);c=0;a=t(a);for(d=a.next();!d.done;d=a.next())d=d.value,b.set(Gc(d),c),c+=d.byteLength;return b}J("shaka.util.Uint8ArrayUtils",Xc);Xc.concat=cd;Xc.toHex=bd;Xc.fromHex=ad;Xc.fromBase64=$c;Xc.toBase64=Zc;Xc.toStandardBase64=Yc;function dd(){var a=this;this.A=Lc.get("muxjs")();this.g=new this.A.mp4.Transmuxer({keepOriginalTimestamps:!0});this.h=null;this.m=[];this.j=[];this.i=[];this.l=!1;this.g.on("data",function(b){a.j=b.captions;a.i=b.metadata;a.m.push(cd(b.initSegment,b.data))});this.g.on("done",function(){var b={data:cd.apply(Xc,ia(a.m)),captions:a.j,metadata:a.i};a.h.resolve(b);a.l=!1})}dd.prototype.destroy=function(){this.g.dispose();this.g=null;return Promise.resolve()};
112
- function ed(a,b){if(!Lc.get("muxjs")()||!fd(a))return!1;if(b)return MediaSource.isTypeSupported(gd(b,a));var c=gd("audio",a),d=gd("video",a);return MediaSource.isTypeSupported(c)||MediaSource.isTypeSupported(d)}function fd(a){return"mp2t"==a.toLowerCase().split(";")[0].split("/")[1]}
113
- function gd(a,b){var c=b.replace(/mp2t/i,"mp4");"audio"==a&&(c=c.replace("video","audio"));var d=/avc1\.(66|77|100)\.(\d+)/.exec(c);if(d){var e="avc1.",f=d[1],g=Number(d[2]);e=("66"==f?e+"4200":"77"==f?e+"4d00":e+"6400")+(g>>4).toString(16);e+=(g&15).toString(16);c=c.replace(d[0],e)}return c}function hd(a,b){a.l=!0;a.h=new Nc;a.m=[];a.j=[];a.i=[];var c=Gc(b);a.g.push(c);a.g.flush();a.l&&a.h.reject(new O(2,3,3018));return a.h};function id(){}function jd(a,b){var c=a;b&&(c+='; codecs="'+b+'"');return c}function kd(a,b,c){a=jd(a,b);if(fd(a)){if(Lc.get("muxjs")())return gd(c,a)}else if("audio"==c)return a.replace("video","audio");return a}
114
- function ld(a){var b=md(a);a=b[0];b=b[1].toLowerCase();switch(!0){case "mp4a"===a&&"69"===b:case "mp4a"===a&&"6b"===b:return"mp3";case "mp4a"===a&&"66"===b:case "mp4a"===a&&"67"===b:case "mp4a"===a&&"68"===b:case "mp4a"===a&&"40.2"===b:case "mp4a"===a&&"40.02"===b:case "mp4a"===a&&"40.5"===b:case "mp4a"===a&&"40.05"===b:case "mp4a"===a&&"40.29"===b:case "mp4a"===a&&"40.42"===b:return"aac";case "mp4a"===a&&"a5"===b:return"ac-3";case "mp4a"===a&&"a6"===b:return"ec-3";case "mp4a"===a&&"b2"===b:return"dtsx";
115
- case "mp4a"===a&&"a9"===b:return"dtsc";case "avc1"===a:case "avc3"===a:return"avc";case "hvc1"===a:case "hev1"===a:return"hevc";case "dvh1"===a:case "dvhe"===a:return"dovi"}return a}function nd(a){a=a.split(/ *; */);a.shift();return(a=a.find(function(b){return b.startsWith("codecs=")}))?a.split("=")[1].replace(/^"|"$/g,""):""}function md(a){a=a.split(".");var b=a[0];a.shift();return[b,a.join(".")]}J("shaka.util.MimeUtils",id);id.getFullType=jd;
116
- (new Map).set("codecs","codecs").set("frameRate","framerate").set("bandwidth","bitrate").set("width","width").set("height","height").set("channelsCount","channels");function od(a){this.j=null;this.i=a;this.C=!1;this.l=this.B=0;this.m=Infinity;this.h=this.g=null;this.F="";this.A=new Map}function pd(a){return qd[a]||"application/cea-608"==a||"application/cea-708"==a?!0:!1}od.prototype.destroy=function(){this.i=this.j=null;this.A.clear();return Promise.resolve()};
117
- function rd(a,b,c,d){var e,f,g,h;return I(function(k){if(1==k.g)return u(k,Promise.resolve(),2);if(!a.j||!a.i)return k["return"]();if(null==c||null==d)return a.j.parseInit(Gc(b)),k["return"]();e=a.C?c:a.B;f={periodStart:a.B,segmentStart:c,segmentEnd:d,vttOffset:e};g=a.j.parseMedia(Gc(b),f);h=g.filter(function(l){return l.startTime>=a.l&&l.startTime<a.m});a.i.append(h);null==a.g&&(a.g=Math.max(c,a.l));a.h=Math.min(d,a.m);z(k)})}
118
- od.prototype.remove=function(a,b){var c=this;return I(function(d){if(1==d.g)return u(d,Promise.resolve(),2);!c.i||!c.i.remove(a,b)||null==c.g||b<=c.g||a>=c.h||(a<=c.g&&b>=c.h?c.g=c.h=null:a<=c.g&&b<c.h?c.g=b:a>c.g&&b>=c.h&&(c.h=a));z(d)})};function sd(a,b,c){a.l=b;a.m=c}function td(a,b,c){a.F=b;if(b=a.A.get(b))for(var d=t(b.keys()),e=d.next();!e.done;e=d.next())(e=b.get(e.value).filter(function(f){return f.endTime<=c}))&&a.i.append(e)}
119
- function ud(a){var b=[];a=t(a);for(var c=a.next();!c.done;c=a.next())c=c.value,b.push({stream:c.stream,cue:new gc(c.startTime,c.endTime,c.text)});return b}function vd(a,b,c){b.startTime+=c;b.endTime+=c;b=t(b.nestedCues);for(var d=b.next();!d.done;d=b.next())vd(a,d.value,c)}
120
- function wd(a,b,c,d,e){var f=c+" "+d,g=new Map;b=t(b);for(var h=b.next();!h.done;h=b.next()){var k=h.value;h=k.stream;k=k.cue;g.has(h)||g.set(h,new Map);g.get(h).has(f)||g.get(h).set(f,[]);vd(a,k,e);k.startTime>=a.l&&k.startTime<a.m&&(g.get(h).get(f).push(k),h==a.F&&a.i.append([k]))}e=t(g.keys());for(f=e.next();!f.done;f=e.next())for(f=f.value,a.A.has(f)||a.A.set(f,new Map),b=t(g.get(f).keys()),h=b.next();!h.done;h=b.next())h=h.value,k=g.get(f).get(h),a.A.get(f).set(h,k);a.g=null==a.g?Math.max(c,
121
- a.l):Math.min(a.g,Math.max(c,a.l));a.h=Math.max(a.h,Math.min(d,a.m))}J("shaka.text.TextEngine",od);od.prototype.destroy=od.prototype.destroy;od.findParser=function(a){return qd[a]};od.unregisterParser=function(a){delete qd[a]};od.registerParser=function(a,b){qd[a]=b};var qd={};function xd(a){this.h=a;this.g=null}xd.prototype.T=function(a){var b=this;this.stop();var c=!0,d=null;this.g=function(){window.clearTimeout(d);c=!1};d=window.setTimeout(function(){c&&b.h()},1E3*a);return this};xd.prototype.stop=function(){this.g&&(this.g(),this.g=null)};function P(a){this.h=a;this.g=null}P.prototype.xa=function(){this.stop();this.h();return this};P.prototype.T=function(a){var b=this;this.stop();this.g=(new xd(function(){b.h()})).T(a);return this};P.prototype.ka=function(a){var b=this;this.stop();this.g=(new xd(function(){b.g.T(a);b.h()})).T(a);return this};P.prototype.stop=function(){this.g&&(this.g.stop(),this.g=null)};J("shaka.util.Timer",P);P.prototype.stop=P.prototype.stop;P.prototype.tickEvery=P.prototype.ka;P.prototype.tickAfter=P.prototype.T;
122
- P.prototype.tickNow=P.prototype.xa;function yd(){return window.MediaSource&&MediaSource.isTypeSupported?!0:!1}function zd(a){return""!=Ad().canPlayType(a)}function Bd(){return Fd("Xbox One")}function Gd(){return Fd("Tizen")}function Hd(){return Fd("CrKey")}function Id(){return!!navigator.vendor&&navigator.vendor.includes("Apple")&&!Gd()}function Jd(){if(!Id())return null;var a=navigator.userAgent.match(/Version\/(\d+)/);return a?parseInt(a[1],10):(a=navigator.userAgent.match(/OS (\d+)(?:_\d+)?/))?parseInt(a[1],10):null}
123
- function Fd(a){return(navigator.userAgent||"").includes(a)}function Ad(){if(Kd)return Kd;Ld||(Ld=new P(function(){Kd=null}));(Kd=document.getElementsByTagName("video")[0]||document.getElementsByTagName("audio")[0])||(Kd=document.createElement("video"));Ld.T(1);return Kd}var Ld=null,Kd=null;function Md(a,b,c,d,e){var f=a.variants;if(b.length||c.length)f=Nd(f,b,c);f=Od(f,d);b=Pd(f);b=Qd(b);var g=Rd(b,e);a.variants=a.variants.filter(function(h){return Sd(h)==g?!0:!1})}function Pd(a){var b=new db;a=t(a);for(var c=a.next();!c.done;c=a.next()){c=c.value;var d=Sd(c);b.push(d,c)}return b}
124
- function Qd(a){var b=0,c=new Map,d=a.size();eb(a,function(e,f){for(var g=t(f),h=g.next();!h.done;h=g.next()){h=h.value;var k=h.video;if(k&&k.width&&k.height){k=k.width*k.height*(k.frameRate||1);c.has(k)||c.set(k,new db);var l=c.get(k);l.push(e,h);l.size()===d&&(b=Math.max(b,k))}}});return b?c.get(b):a}
125
- function Nd(a,b,c){var d={};b=t(b);for(var e=b.next();!e.done;d={Xd:d.Xd},e=b.next())if(d.Xd=e.value,e=a.filter(function(f){return function(g){return g.video&&g.video.codecs.startsWith(f.Xd)}}(d)),e.length){a=e;break}d={};c=t(c);for(b=c.next();!b.done;d={Jd:d.Jd},b=c.next())if(d.Jd=b.value,b=a.filter(function(f){return function(g){return g.audio&&g.audio.codecs.startsWith(f.Jd)}}(d)),b.length){a=b;break}return a}
126
- function Rd(a,b){for(var c=t(b),d=c.next();!d.done;d=c.next())if(d=d.value,d==Td||d==Ud){if(a=Vd(a,d),1==a.size())return a.keys()[0]}else if(d==Wd)break;return Xd(a)}function Vd(a,b){var c=0,d=new db;eb(a,function(e,f){for(var g=0,h=0,k=t(f),l=k.next();!l.done;l=k.next())l=l.value,l.decodingInfos.length&&(g+=l.decodingInfos[0][b]?1:0,h++);g/=h;g>c?(d.g={},d.push(e,f),c=g):g==c&&d.push(e,f)});return d}
127
- function Xd(a){var b="",c=Infinity;eb(a,function(d,e){for(var f=0,g=0,h=t(e),k=h.next();!k.done;k=h.next())f+=k.value.bandwidth||0,++g;f/=g;f<c&&(b=d,c=f)});return b}function Sd(a){var b="";a.video&&(b=ld(a.video.codecs));var c="";a.audio&&(c=ld(a.audio.codecs));return b+"-"+c}function Yd(a,b,c){a.variants=a.variants.filter(function(d){return Zd(d,b,c)})}
128
- function Zd(a,b,c){function d(f,g,h){return f>=g&&f<=h}var e=a.video;if(0!=a.disabledUntilTime){if(a.disabledUntilTime>Date.now()/1E3)return!1;a.disabledUntilTime=0}return e&&e.width&&e.height&&(!d(e.width,b.minWidth,Math.min(b.maxWidth,c.width))||!d(e.height,b.minHeight,Math.min(b.maxHeight,c.height))||!d(e.width*e.height,b.minPixels,b.maxPixels))||a&&a.video&&a.video.frameRate&&!d(a.video.frameRate,b.minFrameRate,b.maxFrameRate)||!d(a.bandwidth,b.minBandwidth,b.maxBandwidth)?!1:!0}
129
- function $d(a,b,c){var d=!1;a=t(a);for(var e=a.next();!e.done;e=a.next()){e=e.value;var f=e.allowedByApplication;e.allowedByApplication=Zd(e,b,c);f!=e.allowedByApplication&&(d=!0)}return d}function ae(a,b){return I(function(c){if(1==c.g)return u(c,be(b,0<b.offlineSessionIds.length),2);ce(a,b);de(b);return u(c,ee(b),0)})}
130
- function be(a,b){return I(function(c){if(1==c.g)return u(c,fe(a.variants,b,!1),2);a.variants=a.variants.filter(function(d){var e=d.video;if(e){var f=ge(e.codecs);if(e.codecs.includes(",")){var g=e.codecs.split(",");f=Fb("video",g);g=Fb("audio",g);g=kd(e.mimeType,g,"audio");if(!MediaSource.isTypeSupported(g))return!1}f=kd(e.mimeType,f,"video");if(!MediaSource.isTypeSupported(f))return!1}if(f=d.audio)if(g=he(f.codecs),f=kd(f.mimeType,g,"audio"),!MediaSource.isTypeSupported(f))return!1;if(Bd()&&e&&(e.width&&
131
- 1920<e.width||e.height&&1080<e.height)&&e.codecs.includes("avc1."))return Ya(ie(d)),!1;(e=d.decodingInfos.some(function(h){return h.supported}))||Ya(ie(d));return e});z(c)})}
132
- function fe(a,b,c){var d,e,f,g,h,k,l,m,n,p,r;return I(function(x){if(d=a.some(function(y){return y.decodingInfos.length}))return x["return"]();e=navigator.mediaCapabilities;f=[];g=function(y,w){var v;return I(function(D){if(1==D.g)return A(D,2),u(D,e.decodingInfo(w),4);if(2!=D.g)return v=D.h,y.decodingInfos.push(v),va(D,0);F(D);JSON.stringify(w);z(D)})};h=t(a);for(k=h.next();!k.done;k=h.next())for(l=k.value,m=je(l,b,c),n=t(m),p=n.next();!p.done;p=n.next())r=p.value,f.push(g(l,r));return u(x,Promise.all(f),
106
+ var qc="normal",Ac={NORMAL:qc,ITALIC:"italic",OBLIQUE:"oblique"};gc.fontStyle=Ac;gc.textDecoration={UNDERLINE:"underline",LINE_THROUGH:"lineThrough",OVERLINE:"overline"};function ic(){this.id="";this.regionAnchorY=this.regionAnchorX=this.viewportAnchorY=this.viewportAnchorX=0;this.height=this.width=100;this.viewportAnchorUnits=this.widthUnits=this.heightUnits=Bc;this.scroll=Cc}J("shaka.text.CueRegion",ic);var Bc=1;ic.units={PX:0,PERCENTAGE:Bc,LINES:2};var Cc="";ic.scrollMode={NONE:Cc,UP:"up"};function Dc(){}function Ec(a,b){if(!a&&!b)return!0;if(!a||!b||a.byteLength!=b.byteLength)return!1;if(Fc(a)==Fc(b)&&(a.byteOffset||0)==(b.byteOffset||0))return!0;for(var c=Gc(a),d=Gc(b),e=0;e<a.byteLength;e++)if(c[e]!=d[e])return!1;return!0}function Fc(a){return a instanceof ArrayBuffer?a:a.buffer}function Hc(a){return a instanceof ArrayBuffer?a:0==a.byteOffset&&a.byteLength==a.buffer.byteLength?a.buffer:(new Uint8Array(a)).buffer}
107
+ function Gc(a,b,c){c=void 0===c?Infinity:c;return Ic(a,void 0===b?0:b,c,Uint8Array)}function Jc(a,b,c){c=void 0===c?Infinity:c;return Ic(a,void 0===b?0:b,c,DataView)}function Ic(a,b,c,d){var e=(a.byteOffset||0)+a.byteLength;b=Math.max(0,Math.min((a.byteOffset||0)+b,e));return new d(Fc(a),b,Math.min(b+Math.max(c,0),e)-b)}J("shaka.util.BufferUtils",Dc);Dc.toDataView=Jc;Dc.toUint8=Gc;Dc.toArrayBuffer=Hc;Dc.equal=Ec;function Kc(){}J("shaka.dependencies",Kc);Kc.has=function(a){return Lc.has(a)};Kc.add=function(a,b){if(!Mc[a])throw Error(a+" is not supported");Lc.set(a,function(){return b})};var Mc={muxjs:"muxjs"};Kc.Allowed=Mc;var Lc=new Map([["muxjs",function(){return window.muxjs}]]);function Nc(){var a,b,c=new Promise(function(d,e){a=d;b=e});c.resolve=a;c.reject=b;return c}Nc.prototype.resolve=function(){};Nc.prototype.reject=function(){};function Oc(a){this.h=a;this.g=void 0}Oc.prototype.value=function(){void 0==this.g&&(this.g=this.h());return this.g};function Pc(a){this.h=a;this.g=null}Pc.prototype.T=function(a){var b=this;this.stop();var c=!0,d=null;this.g=function(){window.clearTimeout(d);c=!1};d=window.setTimeout(function(){c&&b.h()},1E3*a);return this};Pc.prototype.stop=function(){this.g&&(this.g(),this.g=null)};function P(a){this.h=a;this.g=null}P.prototype.xa=function(){this.stop();this.h();return this};P.prototype.T=function(a){var b=this;this.stop();this.g=(new Pc(function(){b.h()})).T(a);return this};P.prototype.ka=function(a){var b=this;this.stop();this.g=(new Pc(function(){b.g.T(a);b.h()})).T(a);return this};P.prototype.stop=function(){this.g&&(this.g.stop(),this.g=null)};J("shaka.util.Timer",P);P.prototype.stop=P.prototype.stop;P.prototype.tickEvery=P.prototype.ka;P.prototype.tickAfter=P.prototype.T;
108
+ P.prototype.tickNow=P.prototype.xa;function Rc(){return window.MediaSource&&MediaSource.isTypeSupported?!0:!1}function Sc(a){return""!=Tc().canPlayType(a)}function Uc(){return Vc("Xbox One")}function Wc(){return Vc("Tizen")}function Xc(){return Vc("Web0S")&&Vc("Chrome/38.0.2125.122 Safari/537.36")}function Yc(){return Vc("CrKey")}function Zc(){return!!navigator.vendor&&navigator.vendor.includes("Apple")&&!Wc()&&!Vc("PC=EOS")&&!$c()}function $c(){return Vc("PlayStation 4")}
109
+ function ad(){if(!Zc())return null;var a=navigator.userAgent.match(/Version\/(\d+)/);return a?parseInt(a[1],10):(a=navigator.userAgent.match(/OS (\d+)(?:_\d+)?/))?parseInt(a[1],10):null}function Vc(a){return(navigator.userAgent||"").includes(a)}function Tc(){if(bd)return bd;cd||(cd=new P(function(){bd=null}));(bd=document.getElementsByTagName("video")[0]||document.getElementsByTagName("audio")[0])||(bd=document.createElement("video"));cd.T(1);return bd}var cd=null,bd=null;function dd(){}function ed(a){if(!a)return"";a=Gc(a);239==a[0]&&187==a[1]&&191==a[2]&&(a=a.subarray(3));if(window.TextDecoder&&!$c())return a=(new TextDecoder).decode(a),a.includes("\ufffd")&&Ta('Decoded string contains an "unknown character" codepoint. That probably means the UTF8 encoding was incorrect!'),a;a=fd(a);a=escape(a);try{return decodeURIComponent(a)}catch(b){throw new O(2,2,2004);}}
110
+ function gd(a,b,c){if(!a)return"";if(!c&&0!=a.byteLength%2)throw new O(2,2,2004);c=Math.floor(a.byteLength/2);var d=new Uint16Array(c);a=Jc(a);for(var e=0;e<c;e++)d[e]=a.getUint16(2*e,b);return fd(d)}
111
+ function hd(a){function b(d){return c.byteLength<=d||32<=c[d]&&126>=c[d]}if(!a)return"";var c=Gc(a);if(239==c[0]&&187==c[1]&&191==c[2])return ed(c);if(254==c[0]&&255==c[1])return gd(c.subarray(2),!1);if(255==c[0]&&254==c[1])return gd(c.subarray(2),!0);if(0==c[0]&&0==c[2])return gd(a,!1);if(0==c[1]&&0==c[3])return gd(a,!0);if(b(0)&&b(1)&&b(2)&&b(3))return ed(a);throw new O(2,2,2003);}
112
+ function id(a){if(window.TextEncoder&&!$c()){var b=new TextEncoder;return Hc(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 Hc(b)}function jd(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}function fd(a){return kd.value()(a)}J("shaka.util.StringUtils",dd);dd.resetFromCharCode=function(){kd.g=void 0};dd.toUTF16=jd;dd.toUTF8=id;
113
+ dd.fromBytesAutoDetect=hd;dd.fromUTF16=gd;dd.fromUTF8=ed;var kd=new Oc(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 ld(){}function md(a){a=fd(Gc(a));return btoa(a)}function nd(a,b){b=void 0==b?!0:b;var c=md(a).replace(/\+/g,"-").replace(/\//g,"_");return b?c:c.replace(/[=]*$/,"")}function od(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 pd(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}
114
+ function qd(a){var b=Gc(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 rd(){for(var a=Ha.apply(0,arguments),b=0,c=t(a),d=c.next();!d.done;d=c.next())b+=d.value.byteLength;b=new Uint8Array(b);c=0;a=t(a);for(d=a.next();!d.done;d=a.next())d=d.value,b.set(Gc(d),c),c+=d.byteLength;return b}J("shaka.util.Uint8ArrayUtils",ld);ld.concat=rd;ld.toHex=qd;ld.fromHex=pd;ld.fromBase64=od;ld.toBase64=nd;ld.toStandardBase64=md;function sd(){var a=this;this.A=Lc.get("muxjs")();this.g=new this.A.mp4.Transmuxer({keepOriginalTimestamps:!0});this.h=null;this.m=[];this.j=[];this.i=[];this.l=!1;this.g.on("data",function(b){a.j=b.captions;a.i=b.metadata;a.m.push(rd(b.initSegment,b.data))});this.g.on("done",function(){var b={data:rd.apply(ld,ia(a.m)),captions:a.j,metadata:a.i};a.h.resolve(b);a.l=!1})}sd.prototype.destroy=function(){this.g.dispose();this.g=null;return Promise.resolve()};
115
+ function td(a,b){if(!Lc.get("muxjs")()||!ud(a))return!1;if(b)return MediaSource.isTypeSupported(vd(b,a));var c=vd("audio",a),d=vd("video",a);return MediaSource.isTypeSupported(c)||MediaSource.isTypeSupported(d)}function ud(a){return"mp2t"==a.toLowerCase().split(";")[0].split("/")[1]}
116
+ function vd(a,b){var c=b.replace(/mp2t/i,"mp4");"audio"==a&&(c=c.replace("video","audio"));var d=/avc1\.(66|77|100)\.(\d+)/.exec(c);if(d){var e="avc1.",f=d[1],g=Number(d[2]);e=("66"==f?e+"4200":"77"==f?e+"4d00":e+"6400")+(g>>4).toString(16);e+=(g&15).toString(16);c=c.replace(d[0],e)}return c}function wd(a,b){a.l=!0;a.h=new Nc;a.m=[];a.j=[];a.i=[];var c=Gc(b);a.g.push(c);a.g.flush();a.l&&a.h.reject(new O(2,3,3018));return a.h};function xd(){}function yd(a,b){var c=a;b&&(c+='; codecs="'+b+'"');return c}function zd(a,b,c){a=yd(a,b);if(ud(a)){if(Lc.get("muxjs")())return vd(c,a)}else if("audio"==c)return a.replace("video","audio");return a}
117
+ function Ad(a){var b=Bd(a);a=b[0];b=b[1].toLowerCase();switch(!0){case "mp4a"===a&&"69"===b:case "mp4a"===a&&"6b"===b:return"mp3";case "mp4a"===a&&"66"===b:case "mp4a"===a&&"67"===b:case "mp4a"===a&&"68"===b:case "mp4a"===a&&"40.2"===b:case "mp4a"===a&&"40.02"===b:case "mp4a"===a&&"40.5"===b:case "mp4a"===a&&"40.05"===b:case "mp4a"===a&&"40.29"===b:case "mp4a"===a&&"40.42"===b:return"aac";case "mp4a"===a&&"a5"===b:return"ac-3";case "mp4a"===a&&"a6"===b:return"ec-3";case "mp4a"===a&&"b2"===b:return"dtsx";
118
+ case "mp4a"===a&&"a9"===b:return"dtsc";case "avc1"===a:case "avc3"===a:return"avc";case "hvc1"===a:case "hev1"===a:return"hevc";case "dvh1"===a:case "dvhe"===a:return"dovi"}return a}function Fd(a){a=a.split(/ *; */);a.shift();return(a=a.find(function(b){return b.startsWith("codecs=")}))?a.split("=")[1].replace(/^"|"$/g,""):""}function Bd(a){a=a.split(".");var b=a[0];a.shift();return[b,a.join(".")]}J("shaka.util.MimeUtils",xd);xd.getFullType=yd;
119
+ (new Map).set("codecs","codecs").set("frameRate","framerate").set("bandwidth","bitrate").set("width","width").set("height","height").set("channelsCount","channels");function Gd(a){this.j=null;this.i=a;this.C=!1;this.l=this.B=0;this.m=Infinity;this.h=this.g=null;this.F="";this.A=new Map}function Hd(a){return Id[a]||"application/cea-608"==a||"application/cea-708"==a?!0:!1}Gd.prototype.destroy=function(){this.i=this.j=null;this.A.clear();return Promise.resolve()};
120
+ function Jd(a,b,c,d){var e,f,g,h;return I(function(k){if(1==k.g)return u(k,Promise.resolve(),2);if(!a.j||!a.i)return k["return"]();if(null==c||null==d)return a.j.parseInit(Gc(b)),k["return"]();e=a.C?c:a.B;f={periodStart:a.B,segmentStart:c,segmentEnd:d,vttOffset:e};g=a.j.parseMedia(Gc(b),f);h=g.filter(function(l){return l.startTime>=a.l&&l.startTime<a.m});a.i.append(h);null==a.g&&(a.g=Math.max(c,a.l));a.h=Math.min(d,a.m);z(k)})}
121
+ Gd.prototype.remove=function(a,b){var c=this;return I(function(d){if(1==d.g)return u(d,Promise.resolve(),2);!c.i||!c.i.remove(a,b)||null==c.g||b<=c.g||a>=c.h||(a<=c.g&&b>=c.h?c.g=c.h=null:a<=c.g&&b<c.h?c.g=b:a>c.g&&b>=c.h&&(c.h=a));z(d)})};function Kd(a,b,c){a.l=b;a.m=c}function Ld(a,b,c){a.F=b;if(b=a.A.get(b))for(var d=t(b.keys()),e=d.next();!e.done;e=d.next())(e=b.get(e.value).filter(function(f){return f.endTime<=c}))&&a.i.append(e)}
122
+ function Md(a){var b=[];a=t(a);for(var c=a.next();!c.done;c=a.next())c=c.value,b.push({stream:c.stream,cue:new gc(c.startTime,c.endTime,c.text)});return b}function Nd(a,b,c){b.startTime+=c;b.endTime+=c;b=t(b.nestedCues);for(var d=b.next();!d.done;d=b.next())Nd(a,d.value,c)}
123
+ function Od(a,b,c,d,e){var f=c+" "+d,g=new Map;b=t(b);for(var h=b.next();!h.done;h=b.next()){var k=h.value;h=k.stream;k=k.cue;g.has(h)||g.set(h,new Map);g.get(h).has(f)||g.get(h).set(f,[]);Nd(a,k,e);k.startTime>=a.l&&k.startTime<a.m&&(g.get(h).get(f).push(k),h==a.F&&a.i.append([k]))}e=t(g.keys());for(f=e.next();!f.done;f=e.next())for(f=f.value,a.A.has(f)||a.A.set(f,new Map),b=t(g.get(f).keys()),h=b.next();!h.done;h=b.next())h=h.value,k=g.get(f).get(h),a.A.get(f).set(h,k);a.g=null==a.g?Math.max(c,
124
+ a.l):Math.min(a.g,Math.max(c,a.l));a.h=Math.max(a.h,Math.min(d,a.m))}J("shaka.text.TextEngine",Gd);Gd.prototype.destroy=Gd.prototype.destroy;Gd.findParser=function(a){return Id[a]};Gd.unregisterParser=function(a){delete Id[a]};Gd.registerParser=function(a,b){Id[a]=b};var Id={};function Pd(a,b,c,d,e){var f=a.variants;if(b.length||c.length)f=Qd(f,b,c);f=Rd(f,d);b=Sd(f);b=Td(b);var g=Ud(b,e);a.variants=a.variants.filter(function(h){return Vd(h)==g?!0:!1})}function Sd(a){var b=new db;a=t(a);for(var c=a.next();!c.done;c=a.next()){c=c.value;var d=Vd(c);b.push(d,c)}return b}
125
+ function Td(a){var b=0,c=new Map,d=a.size();eb(a,function(e,f){for(var g=t(f),h=g.next();!h.done;h=g.next()){h=h.value;var k=h.video;if(k&&k.width&&k.height){k=k.width*k.height*(k.frameRate||1);c.has(k)||c.set(k,new db);var l=c.get(k);l.push(e,h);l.size()===d&&(b=Math.max(b,k))}}});return b?c.get(b):a}
126
+ function Qd(a,b,c){var d={};b=t(b);for(var e=b.next();!e.done;d={Xd:d.Xd},e=b.next())if(d.Xd=e.value,e=a.filter(function(f){return function(g){return g.video&&g.video.codecs.startsWith(f.Xd)}}(d)),e.length){a=e;break}d={};c=t(c);for(b=c.next();!b.done;d={Jd:d.Jd},b=c.next())if(d.Jd=b.value,b=a.filter(function(f){return function(g){return g.audio&&g.audio.codecs.startsWith(f.Jd)}}(d)),b.length){a=b;break}return a}
127
+ function Ud(a,b){for(var c=t(b),d=c.next();!d.done;d=c.next())if(d=d.value,d==Wd||d==Xd){if(a=Yd(a,d),1==a.size())return a.keys()[0]}else if(d==Zd)break;return $d(a)}function Yd(a,b){var c=0,d=new db;eb(a,function(e,f){for(var g=0,h=0,k=t(f),l=k.next();!l.done;l=k.next())l=l.value,l.decodingInfos.length&&(g+=l.decodingInfos[0][b]?1:0,h++);g/=h;g>c?(d.g={},d.push(e,f),c=g):g==c&&d.push(e,f)});return d}
128
+ function $d(a){var b="",c=Infinity;eb(a,function(d,e){for(var f=0,g=0,h=t(e),k=h.next();!k.done;k=h.next())f+=k.value.bandwidth||0,++g;f/=g;f<c&&(b=d,c=f)});return b}function Vd(a){var b="";a.video&&(b=Ad(a.video.codecs));var c="";a.audio&&(c=Ad(a.audio.codecs));return b+"-"+c}function ae(a,b,c){a.variants=a.variants.filter(function(d){return be(d,b,c)})}
129
+ function be(a,b,c){function d(f,g,h){return f>=g&&f<=h}var e=a.video;if(0!=a.disabledUntilTime){if(a.disabledUntilTime>Date.now()/1E3)return!1;a.disabledUntilTime=0}return e&&e.width&&e.height&&(!d(e.width,b.minWidth,Math.min(b.maxWidth,c.width))||!d(e.height,b.minHeight,Math.min(b.maxHeight,c.height))||!d(e.width*e.height,b.minPixels,b.maxPixels))||a&&a.video&&a.video.frameRate&&!d(a.video.frameRate,b.minFrameRate,b.maxFrameRate)||!d(a.bandwidth,b.minBandwidth,b.maxBandwidth)?!1:!0}
130
+ function ce(a,b,c){var d=!1;a=t(a);for(var e=a.next();!e.done;e=a.next()){e=e.value;var f=e.allowedByApplication;e.allowedByApplication=be(e,b,c);f!=e.allowedByApplication&&(d=!0)}return d}function de(a,b){return I(function(c){if(1==c.g)return u(c,ee(b,0<b.offlineSessionIds.length),2);fe(a,b);ge(b);return u(c,he(b),0)})}
131
+ function ee(a,b){return I(function(c){if(1==c.g)return u(c,ie(a.variants,b,!1),2);a.variants=a.variants.filter(function(d){var e=d.video;if(e){var f=je(e.codecs);if(e.codecs.includes(",")){var g=e.codecs.split(",");f=Fb("video",g);g=Fb("audio",g);g=zd(e.mimeType,g,"audio");if(!MediaSource.isTypeSupported(g))return!1}f=zd(e.mimeType,f,"video");if(!MediaSource.isTypeSupported(f))return!1}if(f=d.audio)if(g=ke(f.codecs),f=zd(f.mimeType,g,"audio"),!MediaSource.isTypeSupported(f))return!1;if(Uc()&&e&&(e.width&&
132
+ 1920<e.width||e.height&&1080<e.height)&&e.codecs.includes("avc1."))return Ya(le(d)),!1;(e=d.decodingInfos.some(function(h){return h.supported}))||Ya(le(d));return e});z(c)})}
133
+ function ie(a,b,c){var d,e,f,g,h,k,l,m,n,p,r;return I(function(w){if(d=a.some(function(y){return y.decodingInfos.length}))return w["return"]();e=navigator.mediaCapabilities;f=[];g=function(y,x){var v;return I(function(D){if(1==D.g)return A(D,2),u(D,e.decodingInfo(x),4);if(2!=D.g)return v=D.h,y.decodingInfos.push(v),va(D,0);F(D);JSON.stringify(x);z(D)})};h=t(a);for(k=h.next();!k.done;k=h.next())for(l=k.value,m=me(l,b,c),n=t(m),p=n.next();!p.done;p=n.next())r=p.value,f.push(g(l,r));return u(w,Promise.all(f),
133
134
  0)})}
134
- function je(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=Fb("video",g);f=ge(f);g=Fb("audio",g);g=kd(e.mimeType,g,"audio");c.audio={contentType:g,channels:2,bitrate:a.bandwidth||1,samplerate:1,spatialRendering:!1}}f=ge(f);f=kd(e.mimeType,f,"video");c.video={contentType:f,width:e.width||1,height:e.height||1,bitrate:e.bandwidth||a.bandwidth||1,framerate:e.frameRate||1};if(e.hdr)switch(e.hdr){case "SDR":c.video.transferFunction="srgb";
135
- break;case "PQ":c.video.transferFunction="pq";break;case "HLG":c.video.transferFunction="hlg"}}d&&(f=he(d.codecs),f=kd(d.mimeType,f,"audio"),c.audio={contentType:f,channels:d.channelsCount||2,bitrate:d.bandwidth||a.bandwidth||1,samplerate:d.audioSamplingRate||1,spatialRendering:d.spatialAudio});g=(a.video?a.video.drmInfos:[]).concat(a.audio?a.audio.drmInfos:[]);if(!g.length)return[c];a=[];f=new Map;g=t(g);for(var h=g.next();!h.done;h=g.next()){var k=h.value;f.get(k.keySystem)||f.set(k.keySystem,[]);
136
- 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 p=new Set,r=t(h.initData),x=r.next();!x.done;x=r.next())p.add(x.value.initDataType);m.initDataType=h.initData[0].initDataType}h.distinctiveIdentifierRequired&&
137
- (m.distinctiveIdentifier="required");h.persistentStateRequired&&(m.persistentState="required");h.sessionType&&(m.sessionTypes=[h.sessionType]);d&&(m.audio?m.audio.robustness=m.audio.robustness||h.audioRobustness:m.audio={robustness:h.audioRobustness});e&&(m.video?m.video.robustness=m.video.robustness||h.videoRobustness:m.video={robustness:h.videoRobustness})}l.keySystemConfiguration=m;a.push(l)}return a}function he(a){return Gd()?"ac-3"==a.toLowerCase()?"ec-3":a:a}
138
- function ge(a){return"vp9"==a?"vp09.00.10.08":a}function ce(a,b){b.variants=b.variants.filter(function(c){var d=c.audio;c=c.video;return d&&a&&a.audio&&!ke(d,a.audio)||c&&a&&a.video&&!ke(c,a.video)?!1:!0})}function de(a){a.textStreams=a.textStreams.filter(function(b){return pd(jd(b.mimeType,b.codecs))})}
139
- function ee(a){var b,c,d,e,f,g,h,k;return I(function(l){switch(l.g){case 1:b=[],c=t(a.imageStreams),d=c.next();case 2:if(d.done){l.D(4);break}e=d.value;f=e.mimeType;if(le.has(f)){l.D(5);break}g=me.get(f);if(!g){le.set(f,!1);l.D(5);break}return u(l,ne(g),7);case 7:h=l.h,le.set(f,h);case 5:(k=le.get(f))&&b.push(e);d=c.next();l.D(2);break;case 4:a.imageStreams=b,z(l)}})}
140
- function ne(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)}})}function ke(a,b){return a.mimeType!=b.mimeType||a.codecs.split(".")[0]!=b.codecs.split(".")[0]?!1:!0}
141
- function oe(a){var b=a.audio,c=a.video,d=b?b.mimeType:null,e=c?c.mimeType:null,f=b?b.codecs:null,g=c?c.codecs:null,h=[];g&&h.push(g);f&&h.push(f);var k=[];c&&k.push(c.mimeType);b&&k.push(b.mimeType);k=k[0]||null;var l=[];b&&l.push(b.kind);c&&l.push(c.kind);l=l[0]||null;var m=new Set;if(b)for(var n=t(b.roles),p=n.next();!p.done;p=n.next())m.add(p.value);if(c)for(n=t(c.roles),p=n.next();!p.done;p=n.next())m.add(p.value);a={id:a.id,active:!1,type:"variant",bandwidth:a.bandwidth,language:a.language,label:null,
135
+ function me(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=Fb("video",g);f=je(f);g=Fb("audio",g);g=zd(e.mimeType,g,"audio");c.audio={contentType:g,channels:2,bitrate:a.bandwidth||1,samplerate:1,spatialRendering:!1}}f=je(f);f=zd(e.mimeType,f,"video");c.video={contentType:f,width:e.width||1,height:e.height||1,bitrate:e.bandwidth||a.bandwidth||1,framerate:e.frameRate||1};if(e.hdr)switch(e.hdr){case "SDR":c.video.transferFunction="srgb";
136
+ break;case "PQ":c.video.transferFunction="pq";break;case "HLG":c.video.transferFunction="hlg"}}d&&(f=ke(d.codecs),f=zd(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,[]);
137
+ 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 p=new Set,r=t(h.initData),w=r.next();!w.done;w=r.next())p.add(w.value.initDataType);m.initDataType=h.initData[0].initDataType}h.distinctiveIdentifierRequired&&
138
+ (m.distinctiveIdentifier="required");h.persistentStateRequired&&(m.persistentState="required");h.sessionType&&(m.sessionTypes=[h.sessionType]);d&&(m.audio?m.audio.robustness=m.audio.robustness||h.audioRobustness:m.audio={robustness:h.audioRobustness});e&&(m.video?m.video.robustness=m.video.robustness||h.videoRobustness:m.video={robustness:h.videoRobustness})}l.keySystemConfiguration=m;a.push(l)}return a}function ke(a){return Wc()?"ac-3"==a.toLowerCase()?"ec-3":a:a}
139
+ function je(a){return"vp9"==a?"vp09.00.10.08":a}function fe(a,b){b.variants=b.variants.filter(function(c){var d=c.audio;c=c.video;return d&&a&&a.audio&&!ne(d,a.audio)||c&&a&&a.video&&!ne(c,a.video)?!1:!0})}function ge(a){a.textStreams=a.textStreams.filter(function(b){return Hd(yd(b.mimeType,b.codecs))})}
140
+ function he(a){var b,c,d,e,f,g,h,k;return I(function(l){switch(l.g){case 1:b=[],c=t(a.imageStreams),d=c.next();case 2:if(d.done){l.D(4);break}e=d.value;f=e.mimeType;if(oe.has(f)){l.D(5);break}g=pe.get(f);if(!g){oe.set(f,!1);l.D(5);break}return u(l,qe(g),7);case 7:h=l.h,oe.set(f,h);case 5:(k=oe.get(f))&&b.push(e);d=c.next();l.D(2);break;case 4:a.imageStreams=b,z(l)}})}
141
+ function qe(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)}})}function ne(a,b){return a.mimeType!=b.mimeType||a.codecs.split(".")[0]!=b.codecs.split(".")[0]?!1:!0}
142
+ function re(a){var b=a.audio,c=a.video,d=b?b.mimeType:null,e=c?c.mimeType:null,f=b?b.codecs:null,g=c?c.codecs:null,h=[];g&&h.push(g);f&&h.push(f);var k=[];c&&k.push(c.mimeType);b&&k.push(b.mimeType);k=k[0]||null;var l=[];b&&l.push(b.kind);c&&l.push(c.kind);l=l[0]||null;var m=new Set;if(b)for(var n=t(b.roles),p=n.next();!p.done;p=n.next())m.add(p.value);if(c)for(n=t(c.roles),p=n.next();!p.done;p=n.next())m.add(p.value);a={id:a.id,active:!1,type:"variant",bandwidth:a.bandwidth,language:a.language,label:null,
142
143
  kind:l,width:null,height:null,frameRate:null,pixelAspectRatio:null,hdr:null,mimeType:k,audioMimeType:d,videoMimeType:e,codecs:h.join(", "),audioCodec:f,videoCodec:g,primary:a.primary,roles:Array.from(m),audioRoles:null,forced:!1,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,originalTextId:null,originalImageId:null};c&&(a.videoId=c.id,a.originalVideoId=c.originalId,
143
144
  a.width=c.width||null,a.height=c.height||null,a.frameRate=c.frameRate||null,a.pixelAspectRatio=c.pixelAspectRatio||null,a.videoBandwidth=c.bandwidth||null);b&&(a.audioId=b.id,a.originalAudioId=b.originalId,a.channelsCount=b.channelsCount,a.audioSamplingRate=b.audioSamplingRate,a.audioBandwidth=b.bandwidth||null,a.spatialAudio=b.spatialAudio,a.label=b.label,a.audioRoles=b.roles);return a}
144
- function pe(a){return{id:a.id,active:!1,type:Ib,bandwidth:0,language:a.language,label:a.label,kind:a.kind||null,width:null,height:null,frameRate:null,pixelAspectRatio:null,hdr:null,mimeType:a.mimeType,audioMimeType:null,videoMimeType:null,codecs:a.codecs||null,audioCodec:null,videoCodec:null,primary:a.primary,roles:a.roles,audioRoles:null,forced:a.forced,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,
145
+ function se(a){return{id:a.id,active:!1,type:Ib,bandwidth:0,language:a.language,label:a.label,kind:a.kind||null,width:null,height:null,frameRate:null,pixelAspectRatio:null,hdr:null,mimeType:a.mimeType,audioMimeType:null,videoMimeType:null,codecs:a.codecs||null,audioCodec:null,videoCodec:null,primary:a.primary,roles:a.roles,audioRoles:null,forced:a.forced,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,
145
146
  originalAudioId:null,originalTextId:a.originalId,originalImageId:null}}
146
- function qe(a){var b=a.width||null,c=a.height||null,d=null;a.segmentIndex&&(d=a.segmentIndex.get(0));var e=a.tilesLayout;d&&(e=d.tilesLayout||e);e&&null!=b&&(b/=Number(e.split("x")[0]));e&&null!=c&&(c/=Number(e.split("x")[1]));return{id:a.id,active:!1,type:"image",bandwidth:a.bandwidth||0,language:"",label:null,kind:null,width:b,height:c,frameRate:null,pixelAspectRatio:null,hdr:null,mimeType:a.mimeType,audioMimeType:null,videoMimeType:null,codecs:null,audioCodec:null,videoCodec:null,primary:!1,roles:[],
147
- audioRoles:null,forced:!1,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:e||null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,originalTextId:null,originalImageId:a.originalId}}function re(a){a.__shaka_id||(a.__shaka_id=se++);return a.__shaka_id}
148
- function te(a){var b=ue(a);b.active="disabled"!=a.mode;b.type="text";b.originalTextId=a.id;"captions"==a.kind&&(b.mimeType="application/cea-608");a.kind&&(b.roles=[a.kind]);"forced"==a.kind&&(b.forced=!0);return b}function ve(a){var b=ue(a);b.active=a.enabled;b.type="variant";b.originalAudioId=a.id;"main"==a.kind&&(b.primary=!0);a.kind&&(b.roles=[a.kind],b.audioRoles=[a.kind],b.label=a.label);return b}
149
- function ue(a){return{id:re(a),active:!1,type:"",bandwidth:0,language:Mb(a.language),label:a.label,kind:a.kind,width:null,height:null,frameRate:null,pixelAspectRatio:null,hdr:null,mimeType:null,audioMimeType:null,videoMimeType:null,codecs:null,audioCodec:null,videoCodec:null,primary:!1,roles:[],forced:!1,audioRoles:null,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,
150
- originalTextId:null,originalImageId:null}}function we(a){return a.allowedByApplication&&a.allowedByKeySystem}function xe(a){return a.filter(function(b){return we(b)})}
151
- function Od(a,b){var c=a.filter(function(g){return g.audio&&g.audio.channelsCount}),d=new Map;c=t(c);for(var e=c.next();!e.done;e=c.next()){e=e.value;var f=e.audio.channelsCount;d.has(f)||d.set(f,[]);d.get(f).push(e)}c=Array.from(d.keys());if(0==c.length)return a;e=c.filter(function(g){return g<=b});return e.length?d.get(Math.max.apply(Math,ia(e))):d.get(Math.min.apply(Math,ia(c)))}
152
- function ye(a,b,c,d){var e=a,f=a.filter(function(k){return k.primary});f.length&&(e=f);var g=e.length?e[0].language:"";e=e.filter(function(k){return k.language==g});if(b){var h=Ub(Mb(b),a.map(function(k){return k.language}));h&&(e=a.filter(function(k){return Mb(k.language)==h}))}e=e.filter(function(k){return k.forced==d});if(c){if(a=ze(e,c),a.length)return a}else if(a=e.filter(function(k){return 0==k.roles.length}),a.length)return a;a=e.map(function(k){return k.roles}).reduce(Ab,[]);return a.length?
153
- ze(e,a[0]):e}function ze(a,b){return a.filter(function(c){return c.roles.includes(b)})}function ie(a){var b=[];a.audio&&b.push(Ae(a.audio));a.video&&b.push(Ae(a.video));return b.join(", ")}
154
- function Ae(a){return"audio"==a.type?"type=audio codecs="+a.codecs+" bandwidth="+a.bandwidth+" channelsCount="+a.channelsCount+" audioSamplingRate="+a.audioSamplingRate:"video"==a.type?"type=video codecs="+a.codecs+" bandwidth="+a.bandwidth+" frameRate="+a.frameRate+" width="+a.width+" height="+a.height:"unexpected stream type"}
155
- var se=0,Td="smooth",Ud="powerEfficient",Wd="bandwidth",le=(new Map).set("image/svg+xml",!0).set("image/png",!0).set("image/jpeg",!0).set("image/jpg",!0),me=(new Map).set("image/webp","data:image/webp;base64,UklGRjoAAABXRUJQVlA4IC4AAACyAgCdASoCAAIALmk0mk0iIiIiIgBoSygABc6WWgAA/veff/0PP8bA//LwYAAA").set("image/avif","data:image/avif;base64,AAAAIGZ0eXBhdmlmAAAAAGF2aWZtaWYxbWlhZk1BMUIAAADybWV0YQAAAAAAAAAoaGRscgAAAAAAAAAAcGljdAAAAAAAAAAAAAAAAGxpYmF2aWYAAAAADnBpdG0AAAAAAAEAAAAeaWxvYwAAAABEAAABAAEAAAABAAABGgAAAB0AAAAoaWluZgAAAAAAAQAAABppbmZlAgAAAAABAABhdjAxQ29sb3IAAAAAamlwcnAAAABLaXBjbwAAABRpc3BlAAAAAAAAAAIAAAACAAAAEHBpeGkAAAAAAwgICAAAAAxhdjFDgQ0MAAAAABNjb2xybmNseAACAAIAAYAAAAAXaXBtYQAAAAAAAAABAAEEAQKDBAAAACVtZGF0EgAKCBgANogQEAwgMg8f8D///8WfhwB8+ErK42A=");function Be(){var a=this;this.l=null;this.i=!1;this.h=new bc;navigator.connection&&navigator.connection.addEventListener("change",function(){if(a.g.useNetworkInformation&&a.i){a.h=new bc;a.g&&a.h.configure(a.g.advanced);var b=a.chooseVariant();b&&a.l(b)}});this.j=[];this.A=1;this.B=!1;this.g=this.m=null}q=Be.prototype;q.stop=function(){this.l=null;this.i=!1;this.j=[];this.A=1;this.m=null};q.init=function(a){this.l=a};
156
- q.chooseVariant=function(){var a=Ce(this.g.restrictions,this.j),b=this.h.getBandwidthEstimate(Ee(this));this.j.length&&!a.length&&(a=Ce(null,this.j),a=[a[0]]);for(var c=a[0]||null,d=0;d<a.length;d++){for(var e=a[d],f=isNaN(this.A)?1:Math.abs(this.A),g=f*e.bandwidth/this.g.bandwidthDowngradeTarget,h={bandwidth:Infinity},k=d+1;k<a.length;k++)if(e.bandwidth!=a[k].bandwidth){h=a[k];break}f=f*h.bandwidth/this.g.bandwidthUpgradeTarget;b>=g&&b<=f&&c.bandwidth!=e.bandwidth&&(c=e)}this.m=Date.now();return c};
157
- q.enable=function(){this.i=!0};q.disable=function(){this.i=!1};q.segmentDownloaded=function(a,b){this.h.sample(a,b);if(null!=this.m&&this.i)a:{if(!this.B){var c=this.h;if(!(c.g>=c.i))break a;this.B=!0}else if(Date.now()-this.m<1E3*this.g.switchInterval)break a;c=this.chooseVariant();this.h.getBandwidthEstimate(Ee(this));c&&this.l(c)}};q.getBandwidthEstimate=function(){return this.h.getBandwidthEstimate(Ee(this))};q.setVariants=function(a){this.j=a};q.playbackRateChanged=function(a){this.A=a};
158
- q.configure=function(a){this.g=a;this.h&&this.g&&this.h.configure(this.g.advanced)};function Ee(a){var b=a.g.defaultBandwidthEstimate;navigator.connection&&navigator.connection.downlink&&a.g.useNetworkInformation&&(b=1E6*navigator.connection.downlink);return b}function Ce(a,b){a&&(b=b.filter(function(c){return Zd(c,a,{width:Infinity,height:Infinity})}));return b.sort(function(c,d){return c.bandwidth-d.bandwidth})}J("shaka.abr.SimpleAbrManager",Be);Be.prototype.configure=Be.prototype.configure;
159
- Be.prototype.playbackRateChanged=Be.prototype.playbackRateChanged;Be.prototype.setVariants=Be.prototype.setVariants;Be.prototype.getBandwidthEstimate=Be.prototype.getBandwidthEstimate;Be.prototype.segmentDownloaded=Be.prototype.segmentDownloaded;Be.prototype.disable=Be.prototype.disable;Be.prototype.enable=Be.prototype.enable;Be.prototype.chooseVariant=Be.prototype.chooseVariant;Be.prototype.init=Be.prototype.init;Be.prototype.stop=Be.prototype.stop;function Fe(a,b){this.h=a;this.g=new Set([a]);b=b||[];for(var c=t(b),d=c.next();!d.done;d=c.next())this.add(d.value)}Fe.prototype.add=function(a){return Ge(this.h,a)?(this.g.add(a),!0):!1};
160
- function Ge(a,b){var c;if(!(c=!!a.audio!=!!b.audio||!!a.video!=!!b.video||a.language!=b.language)&&(c=a.audio&&b.audio)){c=a.audio;var d=b.audio;c=!((!(!c.channelsCount||!d.channelsCount||2<c.channelsCount||2<d.channelsCount)||c.channelsCount==d.channelsCount)&&He(c,d)&&Ie(c.roles,d.roles))}!c&&(c=a.video&&b.video)&&(c=a.video,d=b.video,c=!(He(c,d)&&Ie(c.roles,d.roles)));return c?!1:!0}Fe.prototype.values=function(){return this.g.values()};
161
- function He(a,b){if(a.mimeType!=b.mimeType)return!1;var c=a.codecs.split(",").map(function(f){return md(f)[0]}),d=b.codecs.split(",").map(function(f){return md(f)[0]});if(c.length!=d.length)return!1;c.sort();d.sort();for(var e=0;e<c.length;e++)if(c[e]!=d[e])return!1;return!0}function Ie(a,b){var c=new Set(a),d=new Set(b);c["delete"]("main");d["delete"]("main");if(c.size!=d.size)return!1;c=t(c);for(var e=c.next();!e.done;e=c.next())if(!d.has(e.value))return!1;return!0};function Je(a){this.g=a;this.h=new Ke(a.language,"",a.audio&&a.audio.channelsCount?a.audio.channelsCount:0,"")}Je.prototype.create=function(a){var b=this,c=a.filter(function(d){return Ge(b.g,d)});return c.length?new Fe(c[0],c):this.h.create(a)};function Ke(a,b,c,d){this.i=a;this.j=b;this.g=c;this.h=void 0===d?"":d}
162
- Ke.prototype.create=function(a){var b=[];b=Le(a,this.i);var c=a.filter(function(d){return d.primary});b=b.length?b:c.length?c:a;a=Me(b,this.j);a.length&&(b=a);this.g&&(a=Od(b,this.g),a.length&&(b=a));this.h&&(a=Ne(b,this.h),a.length&&(b=a));a=new Fe(b[0]);b=t(b);for(c=b.next();!c.done;c=b.next())c=c.value,Ge(a.h,c)&&a.add(c);return a};function Le(a,b){var c=Mb(b),d=Ub(c,a.map(function(e){return Tb(e)}));return d?a.filter(function(e){return d==Tb(e)}):[]}
163
- function Me(a,b){return a.filter(function(c){return c.audio?b?c.audio.roles.includes(b):0==c.audio.roles.length:!1})}function Ne(a,b){return a.filter(function(c){return c.audio?c.audio.label.toLowerCase()==b.toLowerCase():!1})};function Oe(){this.g=Pe;this.h=(new Map).set(Pe,2).set(Qe,1)}function Re(a,b,c){a.h.set(Pe,c).set(Qe,b)}var Qe=0,Pe=1;function Se(a,b){var c=Te();this.l=null==a.maxAttempts?c.maxAttempts:a.maxAttempts;this.j=null==a.baseDelay?c.baseDelay:a.baseDelay;this.A=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}
164
- function Ue(a){var b,c;return I(function(d){if(1==d.g){if(a.g>=a.l)if(a.i)a.g=1,a.h=a.j;else throw new O(2,7,1010);b=a.g;a.g++;if(0==b)return d["return"]();c=a.h*(1+(2*Math.random()-1)*a.A);return u(d,new Promise(function(e){(new P(e)).T(c/1E3)}),2)}a.h*=a.m;z(d)})}function Te(){return{maxAttempts:2,baseDelay:1E3,backoffFactor:2,fuzzFactor:.5,timeout:3E4,stallTimeout:5E3,connectionTimeout:1E4}};function Ve(a,b){this.promise=a;this.i=b;this.g=!1}function We(a){return new Ve(Promise.reject(a),function(){return Promise.resolve()})}function Xe(){var a=Promise.reject(new O(2,7,7001));a["catch"](function(){});return new Ve(a,function(){return Promise.resolve()})}function Ye(a){return new Ve(Promise.resolve(a),function(){return Promise.resolve()})}function Ze(a){return new Ve(a,function(){return a["catch"](function(){})})}Ve.prototype.abort=function(){this.g=!0;return this.i()};
165
- function $e(a){return new Ve(Promise.all(a.map(function(b){return b.promise})),function(){return Promise.all(a.map(function(b){return b.abort()}))})}Ve.prototype["finally"]=function(a){this.promise.then(function(){return a(!0)},function(){return a(!1)});return this};
166
- Ve.prototype.na=function(a,b){function c(h){return function(k){if(e.g&&h)f.reject(g);else{var l=h?a:b;l?d=af(l,k,f):(h?f.resolve:f.reject)(k)}}}function d(){f.reject(g);return e.abort()}var e=this,f=new Nc,g=new O(2,7,7001);this.promise.then(c(!0),c(!1));return new Ve(f,function(){return d()})};
167
- function af(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()}}}J("shaka.util.AbortableOperation",Ve);Ve.prototype.chain=Ve.prototype.na;Ve.prototype["finally"]=Ve.prototype["finally"];Ve.all=$e;Ve.prototype.abort=Ve.prototype.abort;Ve.notAbortable=Ze;Ve.completed=Ye;Ve.aborted=Xe;Ve.failed=We;function bf(a){function b(d){switch(typeof d){case "undefined":case "boolean":case "number":case "string":case "symbol":case "function":return d;default:if(!d||d.buffer&&d.buffer.constructor==ArrayBuffer)return d;if(c.has(d))return null;var e=d.constructor==Array;if(d.constructor!=Object&&!e)return null;c.add(d);var f=e?[]:{},g;for(g in d)f[g]=b(d[g]);e&&(f.length=d.length);return f}}var c=new Set;return b(a)}function cf(a){var b={},c;for(c in a)b[c]=a[c];return b};function df(){this.g=[]}function ef(a,b){a.g.push(b["finally"](function(){dc(a.g,b)}))}df.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 ff(a,b,c){fb.call(this);this.i=!1;this.m=new df;this.g=new Set;this.h=new Set;this.l=a||null;this.j=b||null;this.B=c||null;this.A=!1}qa(ff,fb);q=ff.prototype;q.Ce=function(a){this.A=a};function gf(a,b,c,d){c=c||hf;var e=jf[a];if(!e||c>=e.priority)jf[a]={priority:c,Wg:b,Xg:void 0===d?!1:d}}q.Yg=function(a){this.g.add(a)};q.oh=function(a){this.g["delete"](a)};q.Yf=function(){this.g.clear()};q.Zg=function(a){this.h.add(a)};q.ph=function(a){this.h["delete"](a)};q.Zf=function(){this.h.clear()};
168
- function kf(a,b,c){return{uris:a,method:"GET",body:null,headers:{},allowCrossSiteCredentials:!1,retryParameters:b,licenseRequestType:null,sessionId:null,drmInfo:null,initData:null,initDataType:null,streamDataCallback:void 0===c?null:c}}q.destroy=function(){this.i=!0;this.g.clear();this.h.clear();fb.prototype.release.call(this);return this.m.destroy()};
169
- q.request=function(a,b){var c=this,d=new lf;if(this.i){var e=Promise.reject(new O(2,7,7001));e["catch"](function(){});return new mf(e,function(){return Promise.resolve()},d)}b.method=b.method||"GET";b.headers=b.headers||{};b.retryParameters=b.retryParameters?bf(b.retryParameters):Te();b.uris=bf(b.uris);e=nf(this,a,b);var f=e.na(function(){return of(c,a,b,new Se(b.retryParameters,!1),0,null,d)}),g=f.na(function(n){return pf(c,a,n)}),h=Date.now(),k=0;e.promise.then(function(){k=Date.now()-h},function(){});
170
- var l=0;f.promise.then(function(){l=Date.now()},function(){});var m=g.na(function(n){var p=Date.now()-l,r=n.response;r.timeMs+=k;r.timeMs+=p;n.Jg||!c.l||r.fromCache||a!=qf||c.l(r.timeMs,r.data.byteLength);return r},function(n){n&&(n.severity=2);throw n;});e=new mf(m.promise,function(){return m.abort()},d);ef(this.m,e);return e};
171
- function nf(a,b,c){var d=Ye(void 0),e={};a=t(a.g);for(var f=a.next();!f.done;e={Sd:e.Sd},f=a.next())e.Sd=f.value,d=d.na(function(g){return function(){c.body&&(c.body=Hc(c.body));return g.Sd(b,c)}}(e));return d.na(void 0,function(g){if(g instanceof O&&7001==g.code)throw g;throw new O(2,1,1006,g);})}
172
- function of(a,b,c,d,e,f,g){a.A&&(c.uris[e]=c.uris[e].replace("http://","https://"));var h=new lb(c.uris[e]),k=h.Wa,l=!1;k||(k=location.protocol,k=k.slice(0,-1),mb(h,k),c.uris[e]=h.toString());k=k.toLowerCase();var m=(k=jf[k])?k.Wg:null;if(!m)return We(new O(2,1,1E3,h));var n=k.Xg,p=null,r=null,x=!1,y=!1,w;return Ze(Ue(d)).na(function(){if(a.i)return Xe();w=Date.now();var v=m(c.uris[e],c,b,function(B,G,E){p&&p.stop();r&&r.T(C/1E3);a.l&&b==qf&&(a.l(B,G),l=!0,g.g=E)},function(B){a.j&&a.j(B,c,b);y=!0});
173
- if(!n)return v;var D=c.retryParameters.connectionTimeout;D&&(p=new P(function(){x=!0;v.abort()}),p.T(D/1E3));var C=c.retryParameters.stallTimeout;C&&(r=new P(function(){x=!0;v.abort()}));return v}).na(function(v){p&&p.stop();r&&r.stop();void 0==v.timeMs&&(v.timeMs=Date.now()-w);var D={response:v,Jg:l};!y&&a.j&&a.j(v.headers,c,b);return D},function(v){p&&p.stop();r&&r.stop();if(a.B){var D=null,C=0;v instanceof O&&(D=v,1001==v.code&&(C=v.data[1]));a.B(c,D,C,x)}if(a.i)return Xe();x&&(v=new O(1,1,1003,
174
- c.uris[e],b));if(v instanceof O){if(7001==v.code)throw v;if(1010==v.code)throw f;if(1==v.severity)return D=(new Map).set("error",v),D=new M("retry",D),a.dispatchEvent(D),e=(e+1)%c.uris.length,of(a,b,c,d,e,v,g)}throw v;})}
175
- function pf(a,b,c){var d=Ye(void 0),e={};a=t(a.h);for(var f=a.next();!f.done;e={Td:e.Td},f=a.next())e.Td=f.value,d=d.na(function(g){return function(){var h=c.response;h.data&&(h.data=Hc(h.data));return g.Td(b,h)}}(e));return d.na(function(){return c},function(g){var h=2;if(g instanceof O){if(7001==g.code)throw g;h=g.severity}throw new O(h,1,1007,g);})}J("shaka.net.NetworkingEngine",ff);ff.prototype.request=ff.prototype.request;ff.prototype.destroy=ff.prototype.destroy;ff.makeRequest=kf;
176
- ff.defaultRetryParameters=function(){return Te()};ff.prototype.clearAllResponseFilters=ff.prototype.Zf;ff.prototype.unregisterResponseFilter=ff.prototype.ph;ff.prototype.registerResponseFilter=ff.prototype.Zg;ff.prototype.clearAllRequestFilters=ff.prototype.Yf;ff.prototype.unregisterRequestFilter=ff.prototype.oh;ff.prototype.registerRequestFilter=ff.prototype.Yg;ff.unregisterScheme=function(a){delete jf[a]};ff.registerScheme=gf;ff.prototype.setForceHTTPS=ff.prototype.Ce;function lf(){this.g=0}
177
- ff.NumBytesRemainingClass=lf;function mf(a,b,c){Ve.call(this,a,b);this.h=c}qa(mf,Ve);ff.PendingRequest=mf;var qf=1;ff.RequestType={MANIFEST:0,SEGMENT:qf,LICENSE:2,APP:3,TIMING:4,SERVER_CERTIFICATE:5};var hf=3;ff.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:hf};var jf={};function rf(a){this.g=!1;this.h=new Nc;this.i=a}rf.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 sf(a,b){if(a.g){if(b instanceof O&&7003==b.code)throw b;throw new O(2,7,7003,b);}};function tf(){this.g=new db}q=tf.prototype;q.release=function(){this.Qc();this.g=null};q.o=function(a,b,c,d){this.g&&(a=new uf(a,b,c,d),this.g.push(b,a))};q.Fa=function(a,b,c,d){function e(g){f.nc(a,b,e);c(g)}var f=this;this.o(a,b,e,d)};q.nc=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.nc(),this.g.remove(b,e))}};
178
- q.Qc=function(){if(this.g){var a=this.g,b=[],c;for(c in a.g)b.push.apply(b,ia(a.g[c]));a=t(b);for(b=a.next();!b.done;b=a.next())b.value.nc();this.g.g={}}};J("shaka.util.EventManager",tf);tf.prototype.removeAll=tf.prototype.Qc;tf.prototype.unlisten=tf.prototype.nc;tf.prototype.listenOnce=tf.prototype.Fa;tf.prototype.listen=tf.prototype.o;tf.prototype.release=tf.prototype.release;function uf(a,b,c,d){this.target=a;this.type=b;this.listener=c;this.g=vf(a,d);this.target.addEventListener(b,c,this.g)}
179
- uf.prototype.nc=function(){this.target.removeEventListener(this.type,this.listener,this.g);this.listener=this.target=null;this.g=!1};function vf(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 wf(a)?b:b.capture||!1}
180
- function wf(a){var b=xf;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}xf=b}return b||!1}var xf=void 0;function yf(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 zf(a){var b={};a.forEach(function(c,d){b[d]=c});return b}function Af(a,b){if(a||b){if(a&&!b||b&&!a)return!1}else return!0;if(a.size!=b.size)return!1;for(var c=t(a),d=c.next();!d.done;d=c.next()){var e=t(d.value);d=e.next().value;e=e.next().value;if(!b.has(d))return!1;d=b.get(d);if(d!=e||void 0==d)return!1}return!0};function Bf(a,b){var c=this;b=void 0===b?1:b;this.G=a;this.I=new Set;this.l=this.B=null;this.ba=this.$=!1;this.J=0;this.g=null;this.A=new tf;this.i=new Map;this.F=[];this.C=new Nc;this.h=null;this.m=function(d){c.C.reject(d);a.onError(d)};this.ea=new Map;this.ua=new Map;this.S=new P(function(){return Cf(c)});this.N=!1;this.K=[];this.P=!1;this.aa=(new P(function(){Df(c)})).ka(b);this.C["catch"](function(){});this.j=new rf(function(){return Ef(c)});this.X=!1;this.H=null}q=Bf.prototype;q.destroy=function(){return this.j.destroy()};
181
- function Ef(a){return I(function(b){switch(b.g){case 1:return a.A.release(),a.A=null,a.C.reject(),a.aa.stop(),a.aa=null,a.S.stop(),a.S=null,u(b,Ff(a),2);case 2:if(!a.l){b.D(3);break}A(b,4);return u(b,a.l.setMediaKeys(null),6);case 6:va(b,5);break;case 4:F(b);case 5:a.l=null;case 3:a.g=null,a.I.clear(),a.B=null,a.F=[],a.h=null,a.m=function(){},a.G=null,a.X=!1,a.H=null,z(b)}})}q.configure=function(a){this.h=a};function Gf(a,b,c){a.ba=!0;a.F=[];a.N=c;return Hf(a,b)}
182
- function If(a,b,c){a.F=c;a.N=0<c.length;return Hf(a,b)}function Jf(a,b,c,d,e,f){var g=new Map;e={audioCapabilities:e,videoCapabilities:f,distinctiveIdentifier:"optional",persistentState:"required",sessionTypes:["persistent-license"],label:b};e.drmInfos=[{keySystem:b,licenseServerUri:c,distinctiveIdentifierRequired:!1,persistentStateRequired:!0,audioRobustness:"",videoRobustness:"",serverCertificate:d,serverCertificateUri:"",initData:null,keyIds:null}];g.set(b,e);return Kf(a,g,[])}
183
- function Hf(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,x,y;return I(function(w){if(1==w.g){if(c=Lf(a))for(d=t(b),e=d.next();!e.done;e=d.next())f=e.value,f.video&&(f.video.drmInfos=[c]),f.audio&&(f.audio.drmInfos=[c]);g=b.some(function(v){return v.video&&v.video.drmInfos.length||v.audio&&v.audio.drmInfos.length?!0:!1});g||(h=yf(a.h.servers),Mf(b,h));k=t(b);for(e=k.next();!e.done;e=k.next())for(l=e.value,m=Nf(l),n=t(m),p=n.next();!p.done;p=n.next())r=p.value,Of(r,yf(a.h.servers),yf(a.h.advanced||{}),a.h.keySystemsMapping);
184
- return u(w,fe(b,a.N,a.X),2)}x=g||Object.keys(a.h.servers).length;if(!x)return a.$=!0,w["return"](Promise.resolve());y=Kf(a,void 0,b);return w["return"](g?y:y["catch"](function(){}))})}function Pf(a){var b;return I(function(c){switch(c.g){case 1:if(a.l.mediaKeys)return c["return"]();if(!a.H){c.D(2);break}return u(c,a.H,3);case 3:return c["return"]();case 2:return A(c,4),a.H=a.l.setMediaKeys(a.B),u(c,a.H,6);case 6:va(c,5);break;case 4:b=F(c),a.m(new O(2,6,6003,b.message));case 5:sf(a.j),z(c)}})}
185
- function Qf(a,b){return I(function(c){if(1==c.g)return u(c,Pf(a),2);Rf(a,b.initDataType,Gc(b.initData));z(c)})}
186
- q.yc=function(a){var b=this,c;return I(function(d){if(1==d.g){if(!b.B)return b.A.Fa(a,"encrypted",function(){b.m(new O(2,6,6010))}),d["return"]();b.l=a;b.A.Fa(b.l,"play",function(){for(var e=t(b.K),f=e.next();!f.done;f=e.next())Sf(b,f.value);b.P=!0;b.K=[]});"webkitCurrentPlaybackTargetIsWireless"in b.l&&b.A.o(b.l,"webkitcurrentplaybacktargetiswirelesschanged",function(){return Ff(b)});return(c=b.g.initData.find(function(e){return 0<e.initData.length}))||window.shakaMediaKeysPolyfill||b.F.length?u(d,
187
- Pf(b),2):d.D(2)}Tf(b);c||b.F.length||b.A.o(b.l,"encrypted",function(e){return Qf(b,e)});z(d)})};
188
- function Uf(a){var b,c,d,e,f;return I(function(g){switch(g.g){case 1:if(!a.B||!a.g)return g["return"]();if(!a.g.serverCertificateUri||a.g.serverCertificate&&a.g.serverCertificate.length){g.D(2);break}b=kf([a.g.serverCertificateUri],a.h.retryParameters);A(g,3);c=a.G.Ob.request(5,b);return u(g,c.promise,5);case 5:d=g.h;a.g.serverCertificate=Gc(d.data);va(g,4);break;case 3:throw e=F(g),new O(2,6,6017,e);case 4:if(a.j.g)return g["return"]();case 2:if(!a.g.serverCertificate||!a.g.serverCertificate.length)return g["return"]();
189
- A(g,6);return u(g,a.B.setServerCertificate(a.g.serverCertificate),8);case 8:va(g,0);break;case 6:throw f=F(g),new O(2,6,6004,f.message);}})}function Vf(a,b){var c,d,e;return I(function(f){if(1==f.g)return u(f,Wf(a,b),2);if(3!=f.g){c=f.h;if(!c)return f["return"]();d=[];if(e=a.i.get(c))e.cb=new Nc,d.push(e.cb);d.push(c.remove());return u(f,Promise.all(d),3)}a.i["delete"](c);z(f)})}
190
- function Tf(a){for(var b=(a.g?a.g.initData:[])||[],c=t(b),d=c.next();!d.done;d=c.next())d=d.value,Rf(a,d.initDataType,d.initData);c=t(a.F);for(d=c.next();!d.done;d=c.next())Wf(a,d.value);b.length||a.F.length||a.C.resolve();return a.C}function Rf(a,b,c){if(c.length){var d=a.i.values();d=t(d);for(var e=d.next();!e.done;e=d.next())if(Ec(c,e.value.initData)&&!Fd("Tizen 2"))return;Xf(a,b,c,a.g.sessionType)}}function Yf(a){return a?!!a.match(/^com\.(microsoft|chromecast)\.playready/):!1}
191
- function Zf(a){a=a.i.keys();a=gb(a,function(b){return b.sessionId});return Array.from(a)}q.Dc=function(){var a=Infinity,b=this.i.keys();b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,isNaN(c.expiration)||(a=Math.min(a,c.expiration));return a};q.kd=function(){return zf(this.ua)};
192
- function Kf(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,x,y;return I(function(w){switch(w.g){case 1:d=new Map;if(c.length){e=$f(a,c,d);w.D(2);break}return u(w,ag(a,b),3);case 3:e=w.h;case 2:f=e;if(!f)throw new O(2,6,6001);sf(a.j);A(w,4);a.I.clear();g=f.getConfiguration();h=g.audioCapabilities||[];k=g.videoCapabilities||[];l=t(h);for(m=l.next();!m.done;m=l.next())n=m.value,a.I.add(n.contentType.toLowerCase());p=t(k);for(m=p.next();!m.done;m=p.next())r=m.value,a.I.add(r.contentType.toLowerCase());if(c.length){var v=
193
- f.keySystem;var D=d.get(f.keySystem);var C=[],B=[],G=[],E=[],H=new Set;bg(D,C,G,B,E,H);var L=a.N?"persistent-license":"temporary";v={keySystem:v,licenseServerUri:C[0],distinctiveIdentifierRequired:D[0].distinctiveIdentifierRequired,persistentStateRequired:D[0].persistentStateRequired,sessionType:D[0].sessionType||L,audioRobustness:D[0].audioRobustness||"",videoRobustness:D[0].videoRobustness||"",serverCertificate:G[0],serverCertificateUri:B[0],initData:E,keyIds:H};D=t(D);for(C=D.next();!C.done;C=
194
- D.next())C=C.value,C.distinctiveIdentifierRequired&&(v.distinctiveIdentifierRequired=C.distinctiveIdentifierRequired),C.persistentStateRequired&&(v.persistentStateRequired=C.persistentStateRequired);D=v}else D=f.keySystem,v=b.get(f.keySystem),C=[],B=[],G=[],E=[],H=new Set,bg(v.drmInfos,C,G,B,E,H),D={keySystem:D,licenseServerUri:C[0],distinctiveIdentifierRequired:"required"==v.distinctiveIdentifier,persistentStateRequired:"required"==v.persistentState,sessionType:v.sessionTypes[0]||"temporary",audioRobustness:(v.audioCapabilities?
195
- v.audioCapabilities[0].robustness:"")||"",videoRobustness:(v.videoCapabilities?v.videoCapabilities[0].robustness:"")||"",serverCertificate:G[0],serverCertificateUri:B[0],initData:E,keyIds:H};a.g=D;if(!a.g.licenseServerUri)throw new O(2,6,6012,a.g.keySystem);return u(w,f.createMediaKeys(),6);case 6:return x=w.h,sf(a.j),a.B=x,a.$=!0,u(w,Uf(a),7);case 7:sf(a.j);va(w,0);break;case 4:y=F(w);sf(a.j,y);a.g=null;a.I.clear();if(y instanceof O)throw y;throw new O(2,6,6002,y.message);}})}
196
- function $f(a,b,c){for(var d=t(b),e=d.next();!e.done;e=d.next()){var f=t(Nf(e.value));for(e=f.next();!e.done;e=f.next())e=e.value,c.has(e.keySystem)||c.set(e.keySystem,[]),c.get(e.keySystem).push(e)}if(1==c.size&&c.has(""))throw new O(2,6,6E3);d={};a=t(a.h.preferredKeySystems);for(e=a.next();!e.done;d={Qd:d.Qd},e=a.next())for(d.Qd=e.value,f=t(b),e=f.next();!e.done;e=f.next())if(e=e.value.decodingInfos.find(function(l){return function(m){return m.supported&&null!=m.keySystemAccess&&m.keySystemAccess.keySystem==
147
+ function te(a){var b=a.width||null,c=a.height||null,d=null;a.segmentIndex&&(d=a.segmentIndex.get(0));var e=a.tilesLayout;d&&(e=d.tilesLayout||e);e&&null!=b&&(b/=Number(e.split("x")[0]));e&&null!=c&&(c/=Number(e.split("x")[1]));return{id:a.id,active:!1,type:"image",bandwidth:a.bandwidth||0,language:"",label:null,kind:null,width:b,height:c,frameRate:null,pixelAspectRatio:null,hdr:null,mimeType:a.mimeType,audioMimeType:null,videoMimeType:null,codecs:null,audioCodec:null,videoCodec:null,primary:!1,roles:[],
148
+ audioRoles:null,forced:!1,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:e||null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,originalTextId:null,originalImageId:a.originalId}}function ue(a){a.__shaka_id||(a.__shaka_id=ve++);return a.__shaka_id}
149
+ function we(a){var b=xe(a);b.active="disabled"!=a.mode;b.type="text";b.originalTextId=a.id;"captions"==a.kind&&(b.mimeType="application/cea-608");a.kind&&(b.roles=[a.kind]);"forced"==a.kind&&(b.forced=!0);return b}function ye(a){var b=xe(a);b.active=a.enabled;b.type="variant";b.originalAudioId=a.id;"main"==a.kind&&(b.primary=!0);a.kind&&(b.roles=[a.kind],b.audioRoles=[a.kind],b.label=a.label);return b}
150
+ function xe(a){return{id:ue(a),active:!1,type:"",bandwidth:0,language:Mb(a.language),label:a.label,kind:a.kind,width:null,height:null,frameRate:null,pixelAspectRatio:null,hdr:null,mimeType:null,audioMimeType:null,videoMimeType:null,codecs:null,audioCodec:null,videoCodec:null,primary:!1,roles:[],forced:!1,audioRoles:null,videoId:null,audioId:null,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,tilesLayout:null,audioBandwidth:null,videoBandwidth:null,originalVideoId:null,originalAudioId:null,
151
+ originalTextId:null,originalImageId:null}}function ze(a){return a.allowedByApplication&&a.allowedByKeySystem}function Ae(a){return a.filter(function(b){return ze(b)})}
152
+ function Rd(a,b){var c=a.filter(function(g){return g.audio&&g.audio.channelsCount}),d=new Map;c=t(c);for(var e=c.next();!e.done;e=c.next()){e=e.value;var f=e.audio.channelsCount;d.has(f)||d.set(f,[]);d.get(f).push(e)}c=Array.from(d.keys());if(0==c.length)return a;e=c.filter(function(g){return g<=b});return e.length?d.get(Math.max.apply(Math,ia(e))):d.get(Math.min.apply(Math,ia(c)))}
153
+ function Be(a,b,c,d){var e=a,f=a.filter(function(k){return k.primary});f.length&&(e=f);var g=e.length?e[0].language:"";e=e.filter(function(k){return k.language==g});if(b){var h=Ub(Mb(b),a.map(function(k){return k.language}));h&&(e=a.filter(function(k){return Mb(k.language)==h}))}e=e.filter(function(k){return k.forced==d});if(c){if(a=Ce(e,c),a.length)return a}else if(a=e.filter(function(k){return 0==k.roles.length}),a.length)return a;a=e.map(function(k){return k.roles}).reduce(Ab,[]);return a.length?
154
+ Ce(e,a[0]):e}function Ce(a,b){return a.filter(function(c){return c.roles.includes(b)})}function le(a){var b=[];a.audio&&b.push(Ee(a.audio));a.video&&b.push(Ee(a.video));return b.join(", ")}
155
+ function Ee(a){return"audio"==a.type?"type=audio codecs="+a.codecs+" bandwidth="+a.bandwidth+" channelsCount="+a.channelsCount+" audioSamplingRate="+a.audioSamplingRate:"video"==a.type?"type=video codecs="+a.codecs+" bandwidth="+a.bandwidth+" frameRate="+a.frameRate+" width="+a.width+" height="+a.height:"unexpected stream type"}
156
+ var ve=0,Wd="smooth",Xd="powerEfficient",Zd="bandwidth",oe=(new Map).set("image/svg+xml",!0).set("image/png",!0).set("image/jpeg",!0).set("image/jpg",!0),pe=(new Map).set("image/webp","data:image/webp;base64,UklGRjoAAABXRUJQVlA4IC4AAACyAgCdASoCAAIALmk0mk0iIiIiIgBoSygABc6WWgAA/veff/0PP8bA//LwYAAA").set("image/avif","data:image/avif;base64,AAAAIGZ0eXBhdmlmAAAAAGF2aWZtaWYxbWlhZk1BMUIAAADybWV0YQAAAAAAAAAoaGRscgAAAAAAAAAAcGljdAAAAAAAAAAAAAAAAGxpYmF2aWYAAAAADnBpdG0AAAAAAAEAAAAeaWxvYwAAAABEAAABAAEAAAABAAABGgAAAB0AAAAoaWluZgAAAAAAAQAAABppbmZlAgAAAAABAABhdjAxQ29sb3IAAAAAamlwcnAAAABLaXBjbwAAABRpc3BlAAAAAAAAAAIAAAACAAAAEHBpeGkAAAAAAwgICAAAAAxhdjFDgQ0MAAAAABNjb2xybmNseAACAAIAAYAAAAAXaXBtYQAAAAAAAAABAAEEAQKDBAAAACVtZGF0EgAKCBgANogQEAwgMg8f8D///8WfhwB8+ErK42A=");function Fe(){var a=this;this.l=null;this.i=!1;this.h=new bc;navigator.connection&&navigator.connection.addEventListener("change",function(){if(a.g.useNetworkInformation&&a.i){a.h=new bc;a.g&&a.h.configure(a.g.advanced);var b=a.chooseVariant();b&&a.l(b)}});this.j=[];this.A=1;this.B=!1;this.g=this.m=null}q=Fe.prototype;q.stop=function(){this.l=null;this.i=!1;this.j=[];this.A=1;this.m=null};q.init=function(a){this.l=a};
157
+ q.chooseVariant=function(){var a=Ge(this.g.restrictions,this.j),b=this.h.getBandwidthEstimate(He(this));this.j.length&&!a.length&&(a=Ge(null,this.j),a=[a[0]]);for(var c=a[0]||null,d=0;d<a.length;d++){for(var e=a[d],f=isNaN(this.A)?1:Math.abs(this.A),g=f*e.bandwidth/this.g.bandwidthDowngradeTarget,h={bandwidth:Infinity},k=d+1;k<a.length;k++)if(e.bandwidth!=a[k].bandwidth){h=a[k];break}f=f*h.bandwidth/this.g.bandwidthUpgradeTarget;b>=g&&b<=f&&c.bandwidth!=e.bandwidth&&(c=e)}this.m=Date.now();return c};
158
+ q.enable=function(){this.i=!0};q.disable=function(){this.i=!1};q.segmentDownloaded=function(a,b){this.h.sample(a,b);if(null!=this.m&&this.i)a:{if(!this.B){var c=this.h;if(!(c.g>=c.i))break a;this.B=!0}else if(Date.now()-this.m<1E3*this.g.switchInterval)break a;c=this.chooseVariant();this.h.getBandwidthEstimate(He(this));c&&this.l(c)}};q.getBandwidthEstimate=function(){return this.h.getBandwidthEstimate(He(this))};q.setVariants=function(a){this.j=a};q.playbackRateChanged=function(a){this.A=a};
159
+ q.configure=function(a){this.g=a;this.h&&this.g&&this.h.configure(this.g.advanced)};function He(a){var b=a.g.defaultBandwidthEstimate;navigator.connection&&navigator.connection.downlink&&a.g.useNetworkInformation&&(b=1E6*navigator.connection.downlink);return b}function Ge(a,b){a&&(b=b.filter(function(c){return be(c,a,{width:Infinity,height:Infinity})}));return b.sort(function(c,d){return c.bandwidth-d.bandwidth})}J("shaka.abr.SimpleAbrManager",Fe);Fe.prototype.configure=Fe.prototype.configure;
160
+ Fe.prototype.playbackRateChanged=Fe.prototype.playbackRateChanged;Fe.prototype.setVariants=Fe.prototype.setVariants;Fe.prototype.getBandwidthEstimate=Fe.prototype.getBandwidthEstimate;Fe.prototype.segmentDownloaded=Fe.prototype.segmentDownloaded;Fe.prototype.disable=Fe.prototype.disable;Fe.prototype.enable=Fe.prototype.enable;Fe.prototype.chooseVariant=Fe.prototype.chooseVariant;Fe.prototype.init=Fe.prototype.init;Fe.prototype.stop=Fe.prototype.stop;function Ie(a,b){this.h=a;this.g=new Set([a]);b=b||[];for(var c=t(b),d=c.next();!d.done;d=c.next())this.add(d.value)}Ie.prototype.add=function(a){return Je(this.h,a)?(this.g.add(a),!0):!1};
161
+ function Je(a,b){var c;if(!(c=!!a.audio!=!!b.audio||!!a.video!=!!b.video||a.language!=b.language)&&(c=a.audio&&b.audio)){c=a.audio;var d=b.audio;c=!((!(!c.channelsCount||!d.channelsCount||2<c.channelsCount||2<d.channelsCount)||c.channelsCount==d.channelsCount)&&Ke(c,d)&&Le(c.roles,d.roles))}!c&&(c=a.video&&b.video)&&(c=a.video,d=b.video,c=!(Ke(c,d)&&Le(c.roles,d.roles)));return c?!1:!0}Ie.prototype.values=function(){return this.g.values()};
162
+ function Ke(a,b){if(a.mimeType!=b.mimeType)return!1;var c=a.codecs.split(",").map(function(f){return Bd(f)[0]}),d=b.codecs.split(",").map(function(f){return Bd(f)[0]});if(c.length!=d.length)return!1;c.sort();d.sort();for(var e=0;e<c.length;e++)if(c[e]!=d[e])return!1;return!0}function Le(a,b){var c=new Set(a),d=new Set(b);c["delete"]("main");d["delete"]("main");if(c.size!=d.size)return!1;c=t(c);for(var e=c.next();!e.done;e=c.next())if(!d.has(e.value))return!1;return!0};function Me(a){this.g=a;this.h=new Ne(a.language,"",a.audio&&a.audio.channelsCount?a.audio.channelsCount:0,"")}Me.prototype.create=function(a){var b=this,c=a.filter(function(d){return Je(b.g,d)});return c.length?new Ie(c[0],c):this.h.create(a)};function Ne(a,b,c,d){this.i=a;this.j=b;this.g=c;this.h=void 0===d?"":d}
163
+ Ne.prototype.create=function(a){var b=[];b=Oe(a,this.i);var c=a.filter(function(d){return d.primary});b=b.length?b:c.length?c:a;a=Pe(b,this.j);a.length&&(b=a);this.g&&(a=Rd(b,this.g),a.length&&(b=a));this.h&&(a=Qe(b,this.h),a.length&&(b=a));a=new Ie(b[0]);b=t(b);for(c=b.next();!c.done;c=b.next())c=c.value,Je(a.h,c)&&a.add(c);return a};function Oe(a,b){var c=Mb(b),d=Ub(c,a.map(function(e){return Tb(e)}));return d?a.filter(function(e){return d==Tb(e)}):[]}
164
+ function Pe(a,b){return a.filter(function(c){return c.audio?b?c.audio.roles.includes(b):0==c.audio.roles.length:!1})}function Qe(a,b){return a.filter(function(c){return c.audio?c.audio.label.toLowerCase()==b.toLowerCase():!1})};function Re(){this.g=Se;this.h=(new Map).set(Se,2).set(Te,1)}function Ue(a,b,c){a.h.set(Se,c).set(Te,b)}var Te=0,Se=1;function Ve(a,b){var c=We();this.l=null==a.maxAttempts?c.maxAttempts:a.maxAttempts;this.j=null==a.baseDelay?c.baseDelay:a.baseDelay;this.A=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}
165
+ function Xe(a){var b,c;return I(function(d){if(1==d.g){if(a.g>=a.l)if(a.i)a.g=1,a.h=a.j;else throw new O(2,7,1010);b=a.g;a.g++;if(0==b)return d["return"]();c=a.h*(1+(2*Math.random()-1)*a.A);return u(d,new Promise(function(e){(new P(e)).T(c/1E3)}),2)}a.h*=a.m;z(d)})}function We(){return{maxAttempts:2,baseDelay:1E3,backoffFactor:2,fuzzFactor:.5,timeout:3E4,stallTimeout:5E3,connectionTimeout:1E4}};function Ye(a,b){this.promise=a;this.i=b;this.g=!1}function Ze(a){return new Ye(Promise.reject(a),function(){return Promise.resolve()})}function $e(){var a=Promise.reject(new O(2,7,7001));a["catch"](function(){});return new Ye(a,function(){return Promise.resolve()})}function af(a){return new Ye(Promise.resolve(a),function(){return Promise.resolve()})}function bf(a){return new Ye(a,function(){return a["catch"](function(){})})}Ye.prototype.abort=function(){this.g=!0;return this.i()};
166
+ function cf(a){return new Ye(Promise.all(a.map(function(b){return b.promise})),function(){return Promise.all(a.map(function(b){return b.abort()}))})}Ye.prototype["finally"]=function(a){this.promise.then(function(){return a(!0)},function(){return a(!1)});return this};
167
+ Ye.prototype.na=function(a,b){function c(h){return function(k){if(e.g&&h)f.reject(g);else{var l=h?a:b;l?d=df(l,k,f):(h?f.resolve:f.reject)(k)}}}function d(){f.reject(g);return e.abort()}var e=this,f=new Nc,g=new O(2,7,7001);this.promise.then(c(!0),c(!1));return new Ye(f,function(){return d()})};
168
+ function df(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()}}}J("shaka.util.AbortableOperation",Ye);Ye.prototype.chain=Ye.prototype.na;Ye.prototype["finally"]=Ye.prototype["finally"];Ye.all=cf;Ye.prototype.abort=Ye.prototype.abort;Ye.notAbortable=bf;Ye.completed=af;Ye.aborted=$e;Ye.failed=Ze;function ef(a){function b(d){switch(typeof d){case "undefined":case "boolean":case "number":case "string":case "symbol":case "function":return d;default:if(!d||d.buffer&&d.buffer.constructor==ArrayBuffer)return d;if(c.has(d))return null;var e=d.constructor==Array;if(d.constructor!=Object&&!e)return null;c.add(d);var f=e?[]:{},g;for(g in d)f[g]=b(d[g]);e&&(f.length=d.length);return f}}var c=new Set;return b(a)}function ff(a){var b={},c;for(c in a)b[c]=a[c];return b};function gf(){this.g=[]}function hf(a,b){a.g.push(b["finally"](function(){dc(a.g,b)}))}gf.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 jf(a,b,c){fb.call(this);this.i=!1;this.m=new gf;this.g=new Set;this.h=new Set;this.l=a||null;this.j=b||null;this.B=c||null;this.A=!1}qa(jf,fb);q=jf.prototype;q.De=function(a){this.A=a};function kf(a,b,c,d){c=c||lf;var e=mf[a];if(!e||c>=e.priority)mf[a]={priority:c,Xg:b,Yg:void 0===d?!1:d}}q.Zg=function(a){this.g.add(a)};q.ph=function(a){this.g["delete"](a)};q.Zf=function(){this.g.clear()};q.$g=function(a){this.h.add(a)};q.qh=function(a){this.h["delete"](a)};q.$f=function(){this.h.clear()};
169
+ function nf(a,b,c){return{uris:a,method:"GET",body:null,headers:{},allowCrossSiteCredentials:!1,retryParameters:b,licenseRequestType:null,sessionId:null,drmInfo:null,initData:null,initDataType:null,streamDataCallback:void 0===c?null:c}}q.destroy=function(){this.i=!0;this.g.clear();this.h.clear();fb.prototype.release.call(this);return this.m.destroy()};
170
+ q.request=function(a,b){var c=this,d=new of;if(this.i){var e=Promise.reject(new O(2,7,7001));e["catch"](function(){});return new pf(e,function(){return Promise.resolve()},d)}b.method=b.method||"GET";b.headers=b.headers||{};b.retryParameters=b.retryParameters?ef(b.retryParameters):We();b.uris=ef(b.uris);e=qf(this,a,b);var f=e.na(function(){return rf(c,a,b,new Ve(b.retryParameters,!1),0,null,d)}),g=f.na(function(n){return sf(c,a,n)}),h=Date.now(),k=0;e.promise.then(function(){k=Date.now()-h},function(){});
171
+ var l=0;f.promise.then(function(){l=Date.now()},function(){});var m=g.na(function(n){var p=Date.now()-l,r=n.response;r.timeMs+=k;r.timeMs+=p;n.Kg||!c.l||r.fromCache||a!=tf||c.l(r.timeMs,r.data.byteLength);return r},function(n){n&&(n.severity=2);throw n;});e=new pf(m.promise,function(){return m.abort()},d);hf(this.m,e);return e};
172
+ function qf(a,b,c){var d=af(void 0),e={};a=t(a.g);for(var f=a.next();!f.done;e={Sd:e.Sd},f=a.next())e.Sd=f.value,d=d.na(function(g){return function(){c.body&&(c.body=Hc(c.body));return g.Sd(b,c)}}(e));return d.na(void 0,function(g){if(g instanceof O&&7001==g.code)throw g;throw new O(2,1,1006,g);})}
173
+ function rf(a,b,c,d,e,f,g){a.A&&(c.uris[e]=c.uris[e].replace("http://","https://"));var h=new lb(c.uris[e]),k=h.Wa,l=!1;k||(k=location.protocol,k=k.slice(0,-1),mb(h,k),c.uris[e]=h.toString());k=k.toLowerCase();var m=(k=mf[k])?k.Xg:null;if(!m)return Ze(new O(2,1,1E3,h));var n=k.Yg,p=null,r=null,w=!1,y=!1,x;return bf(Xe(d)).na(function(){if(a.i)return $e();x=Date.now();var v=m(c.uris[e],c,b,function(B,G,E){p&&p.stop();r&&r.T(C/1E3);a.l&&b==tf&&(a.l(B,G),l=!0,g.g=E)},function(B){a.j&&a.j(B,c,b);y=!0});
174
+ if(!n)return v;var D=c.retryParameters.connectionTimeout;D&&(p=new P(function(){w=!0;v.abort()}),p.T(D/1E3));var C=c.retryParameters.stallTimeout;C&&(r=new P(function(){w=!0;v.abort()}));return v}).na(function(v){p&&p.stop();r&&r.stop();void 0==v.timeMs&&(v.timeMs=Date.now()-x);var D={response:v,Kg:l};!y&&a.j&&a.j(v.headers,c,b);return D},function(v){p&&p.stop();r&&r.stop();if(a.B){var D=null,C=0;v instanceof O&&(D=v,1001==v.code&&(C=v.data[1]));a.B(c,D,C,w)}if(a.i)return $e();w&&(v=new O(1,1,1003,
175
+ c.uris[e],b));if(v instanceof O){if(7001==v.code)throw v;if(1010==v.code)throw f;if(1==v.severity)return D=(new Map).set("error",v),D=new L("retry",D),a.dispatchEvent(D),e=(e+1)%c.uris.length,rf(a,b,c,d,e,v,g)}throw v;})}
176
+ function sf(a,b,c){var d=af(void 0),e={};a=t(a.h);for(var f=a.next();!f.done;e={Td:e.Td},f=a.next())e.Td=f.value,d=d.na(function(g){return function(){var h=c.response;h.data&&(h.data=Hc(h.data));return g.Td(b,h)}}(e));return d.na(function(){return c},function(g){var h=2;if(g instanceof O){if(7001==g.code)throw g;h=g.severity}throw new O(h,1,1007,g);})}J("shaka.net.NetworkingEngine",jf);jf.prototype.request=jf.prototype.request;jf.prototype.destroy=jf.prototype.destroy;jf.makeRequest=nf;
177
+ jf.defaultRetryParameters=function(){return We()};jf.prototype.clearAllResponseFilters=jf.prototype.$f;jf.prototype.unregisterResponseFilter=jf.prototype.qh;jf.prototype.registerResponseFilter=jf.prototype.$g;jf.prototype.clearAllRequestFilters=jf.prototype.Zf;jf.prototype.unregisterRequestFilter=jf.prototype.ph;jf.prototype.registerRequestFilter=jf.prototype.Zg;jf.unregisterScheme=function(a){delete mf[a]};jf.registerScheme=kf;jf.prototype.setForceHTTPS=jf.prototype.De;function of(){this.g=0}
178
+ jf.NumBytesRemainingClass=of;function pf(a,b,c){Ye.call(this,a,b);this.h=c}qa(pf,Ye);jf.PendingRequest=pf;var tf=1;jf.RequestType={MANIFEST:0,SEGMENT:tf,LICENSE:2,APP:3,TIMING:4,SERVER_CERTIFICATE:5};var lf=3;jf.PluginPriority={FALLBACK:1,PREFERRED:2,APPLICATION:lf};var mf={};function uf(a){this.g=!1;this.h=new Nc;this.i=a}uf.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 vf(a,b){if(a.g){if(b instanceof O&&7003==b.code)throw b;throw new O(2,7,7003,b);}};function wf(){this.g=new db}q=wf.prototype;q.release=function(){this.Qc();this.g=null};q.o=function(a,b,c,d){this.g&&(a=new xf(a,b,c,d),this.g.push(b,a))};q.Fa=function(a,b,c,d){function e(g){f.nc(a,b,e);c(g)}var f=this;this.o(a,b,e,d)};q.nc=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.nc(),this.g.remove(b,e))}};
179
+ q.Qc=function(){if(this.g){var a=this.g,b=[],c;for(c in a.g)b.push.apply(b,ia(a.g[c]));a=t(b);for(b=a.next();!b.done;b=a.next())b.value.nc();this.g.g={}}};J("shaka.util.EventManager",wf);wf.prototype.removeAll=wf.prototype.Qc;wf.prototype.unlisten=wf.prototype.nc;wf.prototype.listenOnce=wf.prototype.Fa;wf.prototype.listen=wf.prototype.o;wf.prototype.release=wf.prototype.release;function xf(a,b,c,d){this.target=a;this.type=b;this.listener=c;this.g=yf(a,d);this.target.addEventListener(b,c,this.g)}
180
+ xf.prototype.nc=function(){this.target.removeEventListener(this.type,this.listener,this.g);this.listener=this.target=null;this.g=!1};function yf(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 zf(a)?b:b.capture||!1}
181
+ function zf(a){var b=Af;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}Af=b}return b||!1}var Af=void 0;function Bf(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 Cf(a){var b={};a.forEach(function(c,d){b[d]=c});return b}function Df(a,b){if(a||b){if(a&&!b||b&&!a)return!1}else return!0;if(a.size!=b.size)return!1;for(var c=t(a),d=c.next();!d.done;d=c.next()){var e=t(d.value);d=e.next().value;e=e.next().value;if(!b.has(d))return!1;d=b.get(d);if(d!=e||void 0==d)return!1}return!0};function Ef(a,b){var c=this;b=void 0===b?1:b;this.G=a;this.I=new Set;this.l=this.B=null;this.ba=this.$=!1;this.J=0;this.g=null;this.A=new wf;this.i=new Map;this.F=[];this.C=new Nc;this.h=null;this.m=function(d){c.C.reject(d);a.onError(d)};this.ea=new Map;this.ua=new Map;this.S=new P(function(){return Ff(c)});this.N=!1;this.K=[];this.P=!1;this.aa=(new P(function(){Gf(c)})).ka(b);this.C["catch"](function(){});this.j=new uf(function(){return Hf(c)});this.X=!1;this.H=null}q=Ef.prototype;q.destroy=function(){return this.j.destroy()};
182
+ function Hf(a){return I(function(b){switch(b.g){case 1:return a.A.release(),a.A=null,a.C.reject(),a.aa.stop(),a.aa=null,a.S.stop(),a.S=null,u(b,If(a),2);case 2:if(!a.l){b.D(3);break}A(b,4);return u(b,a.l.setMediaKeys(null),6);case 6:va(b,5);break;case 4:F(b);case 5:a.l=null;case 3:a.g=null,a.I.clear(),a.B=null,a.F=[],a.h=null,a.m=function(){},a.G=null,a.X=!1,a.H=null,z(b)}})}q.configure=function(a){this.h=a};function Jf(a,b,c){a.ba=!0;a.F=[];a.N=c;return Kf(a,b)}
183
+ function Lf(a,b,c){a.F=c;a.N=0<c.length;return Kf(a,b)}function Mf(a,b,c,d,e,f){var g=new Map;e={audioCapabilities:e,videoCapabilities:f,distinctiveIdentifier:"optional",persistentState:"required",sessionTypes:["persistent-license"],label:b};e.drmInfos=[{keySystem:b,licenseServerUri:c,distinctiveIdentifierRequired:!1,persistentStateRequired:!0,audioRobustness:"",videoRobustness:"",serverCertificate:d,serverCertificateUri:"",initData:null,keyIds:null}];g.set(b,e);return Nf(a,g,[])}
184
+ function Kf(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,w,y;return I(function(x){if(1==x.g){if(c=Of(a))for(d=t(b),e=d.next();!e.done;e=d.next())f=e.value,f.video&&(f.video.drmInfos=[c]),f.audio&&(f.audio.drmInfos=[c]);g=b.some(function(v){return v.video&&v.video.drmInfos.length||v.audio&&v.audio.drmInfos.length?!0:!1});g||(h=Bf(a.h.servers),Pf(b,h));k=t(b);for(e=k.next();!e.done;e=k.next())for(l=e.value,m=Qf(l),n=t(m),p=n.next();!p.done;p=n.next())r=p.value,Rf(r,Bf(a.h.servers),Bf(a.h.advanced||{}),a.h.keySystemsMapping);
185
+ return u(x,ie(b,a.N,a.X),2)}w=g||Object.keys(a.h.servers).length;if(!w)return a.$=!0,x["return"](Promise.resolve());y=Nf(a,void 0,b);return x["return"](g?y:y["catch"](function(){}))})}function Sf(a){var b;return I(function(c){switch(c.g){case 1:if(a.l.mediaKeys)return c["return"]();if(!a.H){c.D(2);break}return u(c,a.H,3);case 3:return c["return"]();case 2:return A(c,4),a.H=a.l.setMediaKeys(a.B),u(c,a.H,6);case 6:va(c,5);break;case 4:b=F(c),a.m(new O(2,6,6003,b.message));case 5:vf(a.j),z(c)}})}
186
+ function Tf(a,b){return I(function(c){if(1==c.g)return u(c,Sf(a),2);Uf(a,b.initDataType,Gc(b.initData));z(c)})}
187
+ q.yc=function(a){var b=this,c;return I(function(d){if(1==d.g){if(!b.B)return b.A.Fa(a,"encrypted",function(){b.m(new O(2,6,6010))}),d["return"]();b.l=a;b.A.Fa(b.l,"play",function(){for(var e=t(b.K),f=e.next();!f.done;f=e.next())Vf(b,f.value);b.P=!0;b.K=[]});"webkitCurrentPlaybackTargetIsWireless"in b.l&&b.A.o(b.l,"webkitcurrentplaybacktargetiswirelesschanged",function(){return If(b)});return(c=b.g.initData.find(function(e){return 0<e.initData.length}))||window.shakaMediaKeysPolyfill||b.F.length?u(d,
188
+ Sf(b),2):d.D(2)}Wf(b);c||b.F.length||b.A.o(b.l,"encrypted",function(e){return Tf(b,e)});z(d)})};
189
+ function Xf(a){var b,c,d,e,f;return I(function(g){switch(g.g){case 1:if(!a.B||!a.g)return g["return"]();if(!a.g.serverCertificateUri||a.g.serverCertificate&&a.g.serverCertificate.length){g.D(2);break}b=nf([a.g.serverCertificateUri],a.h.retryParameters);A(g,3);c=a.G.Ob.request(5,b);return u(g,c.promise,5);case 5:d=g.h;a.g.serverCertificate=Gc(d.data);va(g,4);break;case 3:throw e=F(g),new O(2,6,6017,e);case 4:if(a.j.g)return g["return"]();case 2:if(!a.g.serverCertificate||!a.g.serverCertificate.length)return g["return"]();
190
+ A(g,6);return u(g,a.B.setServerCertificate(a.g.serverCertificate),8);case 8:va(g,0);break;case 6:throw f=F(g),new O(2,6,6004,f.message);}})}function Yf(a,b){var c,d,e;return I(function(f){if(1==f.g)return u(f,Zf(a,b),2);if(3!=f.g){c=f.h;if(!c)return f["return"]();d=[];if(e=a.i.get(c))e.cb=new Nc,d.push(e.cb);d.push(c.remove());return u(f,Promise.all(d),3)}a.i["delete"](c);z(f)})}
191
+ function Wf(a){for(var b=(a.g?a.g.initData:[])||[],c=t(b),d=c.next();!d.done;d=c.next())d=d.value,Uf(a,d.initDataType,d.initData);c=t(a.F);for(d=c.next();!d.done;d=c.next())Zf(a,d.value);b.length||a.F.length||a.C.resolve();return a.C}function Uf(a,b,c){if(c.length){var d=a.i.values();d=t(d);for(var e=d.next();!e.done;e=d.next())if(Ec(c,e.value.initData)&&!Vc("Tizen 2"))return;$f(a,b,c,a.g.sessionType)}}function ag(a){return a?!!a.match(/^com\.(microsoft|chromecast)\.playready/):!1}
192
+ function bg(a){a=a.i.keys();a=gb(a,function(b){return b.sessionId});return Array.from(a)}q.Dc=function(){var a=Infinity,b=this.i.keys();b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,isNaN(c.expiration)||(a=Math.min(a,c.expiration));return a};q.kd=function(){return Cf(this.ua)};
193
+ function Nf(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,w,y;return I(function(x){switch(x.g){case 1:d=new Map;if(c.length){e=cg(a,c,d);x.D(2);break}return u(x,dg(a,b),3);case 3:e=x.h;case 2:f=e;if(!f)throw new O(2,6,6001);vf(a.j);A(x,4);a.I.clear();g=f.getConfiguration();h=g.audioCapabilities||[];k=g.videoCapabilities||[];l=t(h);for(m=l.next();!m.done;m=l.next())n=m.value,a.I.add(n.contentType.toLowerCase());p=t(k);for(m=p.next();!m.done;m=p.next())r=m.value,a.I.add(r.contentType.toLowerCase());if(c.length){var v=
194
+ f.keySystem;var D=d.get(f.keySystem);var C=[],B=[],G=[],E=[],H=new Set;eg(D,C,G,B,E,H);var N=a.N?"persistent-license":"temporary";v={keySystem:v,licenseServerUri:C[0],distinctiveIdentifierRequired:D[0].distinctiveIdentifierRequired,persistentStateRequired:D[0].persistentStateRequired,sessionType:D[0].sessionType||N,audioRobustness:D[0].audioRobustness||"",videoRobustness:D[0].videoRobustness||"",serverCertificate:G[0],serverCertificateUri:B[0],initData:E,keyIds:H};D=t(D);for(C=D.next();!C.done;C=
195
+ D.next())C=C.value,C.distinctiveIdentifierRequired&&(v.distinctiveIdentifierRequired=C.distinctiveIdentifierRequired),C.persistentStateRequired&&(v.persistentStateRequired=C.persistentStateRequired);D=v}else D=f.keySystem,v=b.get(f.keySystem),C=[],B=[],G=[],E=[],H=new Set,eg(v.drmInfos,C,G,B,E,H),D={keySystem:D,licenseServerUri:C[0],distinctiveIdentifierRequired:"required"==v.distinctiveIdentifier,persistentStateRequired:"required"==v.persistentState,sessionType:v.sessionTypes[0]||"temporary",audioRobustness:(v.audioCapabilities?
196
+ v.audioCapabilities[0].robustness:"")||"",videoRobustness:(v.videoCapabilities?v.videoCapabilities[0].robustness:"")||"",serverCertificate:G[0],serverCertificateUri:B[0],initData:E,keyIds:H};a.g=D;if(!a.g.licenseServerUri)throw new O(2,6,6012,a.g.keySystem);return u(x,f.createMediaKeys(),6);case 6:return w=x.h,vf(a.j),a.B=w,a.$=!0,u(x,Xf(a),7);case 7:vf(a.j);va(x,0);break;case 4:y=F(x);vf(a.j,y);a.g=null;a.I.clear();if(y instanceof O)throw y;throw new O(2,6,6002,y.message);}})}
197
+ function cg(a,b,c){for(var d=t(b),e=d.next();!e.done;e=d.next()){var f=t(Qf(e.value));for(e=f.next();!e.done;e=f.next())e=e.value,c.has(e.keySystem)||c.set(e.keySystem,[]),c.get(e.keySystem).push(e)}if(1==c.size&&c.has(""))throw new O(2,6,6E3);d={};a=t(a.h.preferredKeySystems);for(e=a.next();!e.done;d={Qd:d.Qd},e=a.next())for(d.Qd=e.value,f=t(b),e=f.next();!e.done;e=f.next())if(e=e.value.decodingInfos.find(function(l){return function(m){return m.supported&&null!=m.keySystemAccess&&m.keySystemAccess.keySystem==
197
198
  l.Qd}}(d)))return e.keySystemAccess;a=t([!0,!1]);for(e=a.next();!e.done;e=a.next())for(d=e.value,f=t(b),e=f.next();!e.done;e=f.next()){var g=t(e.value.decodingInfos);for(e=g.next();!e.done;e=g.next()){var h=e.value;if(h.supported&&h.keySystemAccess){e=c.get(h.keySystemAccess.keySystem);var k=t(e);for(e=k.next();!e.done;e=k.next())if(!!e.value.licenseServerUri==d)return h.keySystemAccess}}}return null}
198
- function ag(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,x,y,w;return I(function(v){switch(v.g){case 1:if(1==b.size&&b.has(""))throw new O(2,6,6E3);d=t(b.values());for(e=d.next();!e.done;e=d.next())f=e.value,0==f.audioCapabilities.length&&delete f.audioCapabilities,0==f.videoCapabilities.length&&delete f.videoCapabilities;g=t(a.h.preferredKeySystems);h=g.next();case 2:if(h.done){v.D(4);break}k=h.value;if(!b.has(k)){v.D(3);break}l=b.get(k);A(v,6);return u(v,navigator.requestMediaKeySystemAccess(k,[l]),8);case 8:return c=
199
- v.h,v["return"](c);case 6:F(v);case 7:sf(a.j);case 3:h=g.next();v.D(2);break;case 4:m=t([!0,!1]),n=m.next();case 9:if(n.done){v.D(11);break}p=n.value;r=t(b.keys());h=r.next();case 12:if(h.done){n=m.next();v.D(9);break}x=h.value;y=b.get(x);w=y.drmInfos.some(function(D){return!!D.licenseServerUri});if(w!=p){v.D(13);break}A(v,15);return u(v,navigator.requestMediaKeySystemAccess(x,[y]),17);case 17:return c=v.h,v["return"](c);case 15:F(v);case 16:sf(a.j);case 13:h=r.next();v.D(12);break;case 11:return v["return"](c)}})}
200
- function Lf(a){a=yf(a.h.clearKeys);if(0==a.size)return null;var b=[],c=[];a.forEach(function(e,f){var g=ad(f),h=ad(e);g={kty:"oct",kid:Zc(g,!1),k:Zc(h,!1)};b.push(g);c.push(g.kid)});a=JSON.stringify({keys:b});var d=JSON.stringify({kids:c});d=[{initData:Gc(Vc(d)),initDataType:"keyids"}];return{keySystem:"org.w3.clearkey",licenseServerUri:"data:application/json;base64,"+window.btoa(a),distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,
199
+ function dg(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,w,y,x;return I(function(v){switch(v.g){case 1:if(1==b.size&&b.has(""))throw new O(2,6,6E3);d=t(b.values());for(e=d.next();!e.done;e=d.next())f=e.value,0==f.audioCapabilities.length&&delete f.audioCapabilities,0==f.videoCapabilities.length&&delete f.videoCapabilities;g=t(a.h.preferredKeySystems);h=g.next();case 2:if(h.done){v.D(4);break}k=h.value;if(!b.has(k)){v.D(3);break}l=b.get(k);A(v,6);return u(v,navigator.requestMediaKeySystemAccess(k,[l]),8);case 8:return c=
200
+ v.h,v["return"](c);case 6:F(v);case 7:vf(a.j);case 3:h=g.next();v.D(2);break;case 4:m=t([!0,!1]),n=m.next();case 9:if(n.done){v.D(11);break}p=n.value;r=t(b.keys());h=r.next();case 12:if(h.done){n=m.next();v.D(9);break}w=h.value;y=b.get(w);x=y.drmInfos.some(function(D){return!!D.licenseServerUri});if(x!=p){v.D(13);break}A(v,15);return u(v,navigator.requestMediaKeySystemAccess(w,[y]),17);case 17:return c=v.h,v["return"](c);case 15:F(v);case 16:vf(a.j);case 13:h=r.next();v.D(12);break;case 11:return v["return"](c)}})}
201
+ function Of(a){a=Bf(a.h.clearKeys);if(0==a.size)return null;var b=[],c=[];a.forEach(function(e,f){var g=pd(f),h=pd(e);g={kty:"oct",kid:nd(g,!1),k:nd(h,!1)};b.push(g);c.push(g.kid)});a=JSON.stringify({keys:b});var d=JSON.stringify({kids:c});d=[{initData:Gc(id(d)),initDataType:"keyids"}];return{keySystem:"org.w3.clearkey",licenseServerUri:"data:application/json;base64,"+window.btoa(a),distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,
201
202
  serverCertificateUri:"",sessionType:"",initData:d,keyIds:new Set(c)}}
202
- function Wf(a,b){var c,d,e,f,g;return I(function(h){switch(h.g){case 1:try{c=a.B.createSession("persistent-license")}catch(k){return d=new O(2,6,6005,k.message),a.m(d),h["return"](Promise.reject(d))}a.A.o(c,"message",function(k){a.l&&a.h.delayLicenseRequestUntilPlayed&&a.l.paused&&!a.P?a.K.push(k):Sf(a,k)});a.A.o(c,"keystatuseschange",function(k){return cg(a,k)});e={initData:null,initDataType:null,loaded:!1,me:Infinity,cb:null,type:"persistent-license"};a.i.set(c,e);A(h,2);return u(h,c.load(b),4);
203
- case 4:f=h.h;sf(a.j);if(!f)return a.i["delete"](c),a.m(new O(2,6,6013)),h["return"](Promise.resolve());e.loaded=!0;dg(a)&&a.C.resolve();return h["return"](c);case 2:g=F(h),sf(a.j,g),a.i["delete"](c),a.m(new O(2,6,6005,g.message));case 3:return h["return"](Promise.resolve())}})}
204
- function Xf(a,b,c,d){try{var e=a.B.createSession(d)}catch(f){a.m(new O(2,6,6005,f.message));return}a.A.o(e,"message",function(f){a.l&&a.h.delayLicenseRequestUntilPlayed&&a.l.paused&&!a.P?a.K.push(f):Sf(a,f)});a.A.o(e,"keystatuseschange",function(f){return cg(a,f)});a.i.set(e,{initData:c,initDataType:b,loaded:!1,me:Infinity,cb:null,type:d});try{c=a.h.initDataTransform(c,b,a.g)}catch(f){b=f;f instanceof O||(b=new O(2,6,6016,f));a.m(b);return}a.h.logLicenseExchange&&Zc(c);e.generateRequest(b,c)["catch"](function(f){if(!a.j.g){a.i["delete"](e);
203
+ function Zf(a,b){var c,d,e,f,g;return I(function(h){switch(h.g){case 1:try{c=a.B.createSession("persistent-license")}catch(k){return d=new O(2,6,6005,k.message),a.m(d),h["return"](Promise.reject(d))}a.A.o(c,"message",function(k){a.l&&a.h.delayLicenseRequestUntilPlayed&&a.l.paused&&!a.P?a.K.push(k):Vf(a,k)});a.A.o(c,"keystatuseschange",function(k){return fg(a,k)});e={initData:null,initDataType:null,loaded:!1,oe:Infinity,cb:null,type:"persistent-license"};a.i.set(c,e);A(h,2);return u(h,c.load(b),4);
204
+ case 4:f=h.h;vf(a.j);if(!f)return a.i["delete"](c),a.m(new O(2,6,6013)),h["return"](Promise.resolve());e.loaded=!0;gg(a)&&a.C.resolve();return h["return"](c);case 2:g=F(h),vf(a.j,g),a.i["delete"](c),a.m(new O(2,6,6005,g.message));case 3:return h["return"](Promise.resolve())}})}
205
+ function $f(a,b,c,d){try{var e=a.B.createSession(d)}catch(f){a.m(new O(2,6,6005,f.message));return}a.A.o(e,"message",function(f){a.l&&a.h.delayLicenseRequestUntilPlayed&&a.l.paused&&!a.P?a.K.push(f):Vf(a,f)});a.A.o(e,"keystatuseschange",function(f){return fg(a,f)});a.i.set(e,{initData:c,initDataType:b,loaded:!1,oe:Infinity,cb:null,type:d});try{c=a.h.initDataTransform(c,b,a.g)}catch(f){b=f;f instanceof O||(b=new O(2,6,6016,f));a.m(b);return}a.h.logLicenseExchange&&nd(c);e.generateRequest(b,c)["catch"](function(f){if(!a.j.g){a.i["delete"](e);
205
206
  var g=f.errorCode;if(g&&g.systemCode){var h=g.systemCode;0>h&&(h+=Math.pow(2,32));h="0x"+h.toString(16)}a.m(new O(2,6,6006,f.message,f,h))}})}
206
- function Sf(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,x,y;I(function(w){switch(w.g){case 1:return c=b.target,a.h.logLicenseExchange&&Zc(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=kf([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),
207
- Yf(a.g.keySystem)&&eg(g),h=Date.now(),A(w,2),l=a.G.Ob.request(2,g),u(w,l.promise,4);case 4:k=w.h;va(w,3);break;case 2:return m=F(w),n=new O(2,6,6007,m),a.m(n),d&&d.cb&&d.cb.reject(n),w["return"]();case 3:if(a.j.g)return w["return"]();a.J+=(Date.now()-h)/1E3;a.h.logLicenseExchange&&Zc(k.data);A(w,5);return u(w,c.update(k.data),7);case 7:va(w,6);break;case 5:return p=F(w),r=new O(2,6,6008,p.message),a.m(r),d&&d.cb&&d.cb.reject(r),w["return"]();case 6:if(a.j.g)return w["return"]();x=new M("drmsessionupdate");
208
- a.G.onEvent(x);d&&(d.cb&&d.cb.resolve(),y=new P(function(){d.loaded=!0;dg(a)&&a.C.resolve()}),y.T(fg));z(w)}})}
209
- function eg(a){var b=Sc(a.body,!0,!0);if(b.includes("PlayReadyKeyMessage")){b=(new DOMParser).parseFromString(b,"application/xml");for(var c=t(b.getElementsByTagName("HttpHeader")),d=c.next();!d.done;d=c.next())d=d.value,a.headers[d.getElementsByTagName("name")[0].textContent]=d.getElementsByTagName("value")[0].textContent;a.body=$c(b.getElementsByTagName("Challenge")[0].textContent)}else a.headers["Content-Type"]="text/xml; charset=utf-8"}
210
- function cg(a,b){var c=b.target,d=a.i.get(c),e=!1;c.keyStatuses.forEach(function(g,h){if("string"==typeof h){var k=h;h=g;g=k}if(Yf(a.g.keySystem)&&16==h.byteLength&&navigator.userAgent.match(/Edge?\//)){k=Jc(h);var l=k.getUint32(0,!0),m=k.getUint16(4,!0),n=k.getUint16(6,!0);k.setUint32(0,l,!1);k.setUint16(4,m,!1);k.setUint16(6,n,!1)}"status-pending"!=g&&(d.loaded=!0);"expired"==g&&(e=!0);k=bd(h);a.ea.set(k,g)});var f=c.expiration-Date.now();(0>f||e&&1E3>f)&&d&&!d.cb&&(a.i["delete"](c),c.close()["catch"](function(){}));
211
- dg(a)&&(a.C.resolve(),a.S.T(gg))}function Cf(a){var b=a.ea,c=a.ua;c.clear();b.forEach(function(d,e){return c.set(e,d)});b=Array.from(c.values());b.length&&b.every(function(d){return"expired"==d})&&a.m(new O(2,6,6014));a.G.wd(zf(c))}
212
- function hg(){var a,b,c,d,e,f,g,h;return I(function(k){return 1==k.g?(a="org.w3.clearkey com.widevine.alpha com.microsoft.playready com.microsoft.playready.recommendation com.apple.fps.3_0 com.apple.fps.2_0 com.apple.fps.1_0 com.apple.fps com.adobe.primetime".split(" "),b=[{contentType:'video/mp4; codecs="avc1.42E01E"'},{contentType:'video/webm; codecs="vp8"'}],c={initDataTypes:["cenc"],videoCapabilities:b},d={videoCapabilities:b,persistentState:"required",sessionTypes:["persistent-license"]},e=[d,
213
- c],f=new Map,g=function(l){var m,n,p;return I(function(r){switch(r.g){case 1:A(r,2);if("org.w3.clearkey"===l&&Jd())throw Error("Unsupported keySystem");return u(r,navigator.requestMediaKeySystemAccess(l,e),4);case 4:return m=r.h,p=(n=m.getConfiguration().sessionTypes)?n.includes("persistent-license"):!1,Fd("Tizen 3")&&(p=!1),f.set(l,{persistentState:p}),u(r,m.createMediaKeys(),5);case 5:va(r,0);break;case 2:F(r),f.set(l,null),z(r)}})},h=a.map(function(l){return g(l)}),u(k,Promise.all(h),2)):k["return"](zf(f))})}
214
- function kg(a){var b;return I(function(c){if(1==c.g)return b=new Promise(function(d,e){(new P(e)).T(lg)}),A(c,2),u(c,Promise.race([Promise.all([a.close(),a.closed]),b]),4);if(2!=c.g)return va(c,0);F(c);z(c)})}
215
- function Ff(a){var b;return I(function(c){b=Array.from(a.i.entries());a.i.clear();return u(c,Promise.all(b.map(function(d){d=t(d);var e=d.next().value,f=d.next().value;return I(function(g){if(1==g.g)return A(g,2),a.ba||a.F.includes(e.sessionId)||"persistent-license"!==f.type?u(g,kg(e),5):u(g,e.remove(),5);if(2!=g.g)return va(g,0);F(g);z(g)})})),0)})}
216
- function mg(a,b){if(!a.length)return b;if(!b.length)return a;for(var c=[],d=t(a),e=d.next();!e.done;e=d.next()){e=e.value;for(var f={},g=t(b),h=g.next();!h.done;f={Ua:f.Ua},h=g.next())if(h=h.value,e.keySystem==h.keySystem){f.Ua=[];f.Ua=f.Ua.concat(e.initData||[]);f.Ua=f.Ua.concat(h.initData||[]);f.Ua=f.Ua.filter(function(k){return function(l,m){return void 0===l.keyId||m===k.Ua.findIndex(function(n){return n.keyId===l.keyId})}}(f));g=e.keyIds&&h.keyIds?new Set([].concat(ia(e.keyIds),ia(h.keyIds))):
207
+ function Vf(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,w,y;I(function(x){switch(x.g){case 1:return c=b.target,a.h.logLicenseExchange&&nd(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=nf([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),
208
+ ag(a.g.keySystem)&&hg(g),h=Date.now(),A(x,2),l=a.G.Ob.request(2,g),u(x,l.promise,4);case 4:k=x.h;va(x,3);break;case 2:return m=F(x),n=new O(2,6,6007,m),a.m(n),d&&d.cb&&d.cb.reject(n),x["return"]();case 3:if(a.j.g)return x["return"]();a.J+=(Date.now()-h)/1E3;a.h.logLicenseExchange&&nd(k.data);A(x,5);return u(x,c.update(k.data),7);case 7:va(x,6);break;case 5:return p=F(x),r=new O(2,6,6008,p.message),a.m(r),d&&d.cb&&d.cb.reject(r),x["return"]();case 6:if(a.j.g)return x["return"]();w=new L("drmsessionupdate");
209
+ a.G.onEvent(w);d&&(d.cb&&d.cb.resolve(),y=new P(function(){d.loaded=!0;gg(a)&&a.C.resolve()}),y.T(ig));z(x)}})}
210
+ function hg(a){var b=gd(a.body,!0,!0);if(b.includes("PlayReadyKeyMessage")){b=(new DOMParser).parseFromString(b,"application/xml");for(var c=t(b.getElementsByTagName("HttpHeader")),d=c.next();!d.done;d=c.next())d=d.value,a.headers[d.getElementsByTagName("name")[0].textContent]=d.getElementsByTagName("value")[0].textContent;a.body=od(b.getElementsByTagName("Challenge")[0].textContent)}else a.headers["Content-Type"]="text/xml; charset=utf-8"}
211
+ function fg(a,b){var c=b.target,d=a.i.get(c),e=!1;c.keyStatuses.forEach(function(g,h){if("string"==typeof h){var k=h;h=g;g=k}if(ag(a.g.keySystem)&&16==h.byteLength&&navigator.userAgent.match(/Edge?\//)){k=Jc(h);var l=k.getUint32(0,!0),m=k.getUint16(4,!0),n=k.getUint16(6,!0);k.setUint32(0,l,!1);k.setUint16(4,m,!1);k.setUint16(6,n,!1)}"status-pending"!=g&&(d.loaded=!0);"expired"==g&&(e=!0);k=qd(h);a.ea.set(k,g)});var f=c.expiration-Date.now();(0>f||e&&1E3>f)&&d&&!d.cb&&(a.i["delete"](c),c.close()["catch"](function(){}));
212
+ gg(a)&&(a.C.resolve(),a.S.T(lg))}function Ff(a){var b=a.ea,c=a.ua;c.clear();b.forEach(function(d,e){return c.set(e,d)});b=Array.from(c.values());b.length&&b.every(function(d){return"expired"==d})&&a.m(new O(2,6,6014));a.G.wd(Cf(c))}
213
+ function mg(){var a,b,c,d,e,f,g,h;return I(function(k){return 1==k.g?(a="org.w3.clearkey com.widevine.alpha com.microsoft.playready com.microsoft.playready.recommendation com.apple.fps.3_0 com.apple.fps.2_0 com.apple.fps.1_0 com.apple.fps com.adobe.primetime".split(" "),b=[{contentType:'video/mp4; codecs="avc1.42E01E"'},{contentType:'video/webm; codecs="vp8"'}],c={initDataTypes:["cenc"],videoCapabilities:b},d={videoCapabilities:b,persistentState:"required",sessionTypes:["persistent-license"]},e=[d,
214
+ c],f=new Map,g=function(l){var m,n,p;return I(function(r){switch(r.g){case 1:A(r,2);if("org.w3.clearkey"===l&&ad())throw Error("Unsupported keySystem");return u(r,navigator.requestMediaKeySystemAccess(l,e),4);case 4:return m=r.h,p=(n=m.getConfiguration().sessionTypes)?n.includes("persistent-license"):!1,Vc("Tizen 3")&&(p=!1),f.set(l,{persistentState:p}),u(r,m.createMediaKeys(),5);case 5:va(r,0);break;case 2:F(r),f.set(l,null),z(r)}})},h=a.map(function(l){return g(l)}),u(k,Promise.all(h),2)):k["return"](Cf(f))})}
215
+ function ng(a){var b;return I(function(c){if(1==c.g)return b=new Promise(function(d,e){(new P(e)).T(og)}),A(c,2),u(c,Promise.race([Promise.all([a.close(),a.closed]),b]),4);if(2!=c.g)return va(c,0);F(c);z(c)})}
216
+ function If(a){var b;return I(function(c){b=Array.from(a.i.entries());a.i.clear();return u(c,Promise.all(b.map(function(d){d=t(d);var e=d.next().value,f=d.next().value;return I(function(g){if(1==g.g)return A(g,2),a.ba||a.F.includes(e.sessionId)||"persistent-license"!==f.type?u(g,ng(e),5):u(g,e.remove(),5);if(2!=g.g)return va(g,0);F(g);z(g)})})),0)})}
217
+ function pg(a,b){if(!a.length)return b;if(!b.length)return a;for(var c=[],d=t(a),e=d.next();!e.done;e=d.next()){e=e.value;for(var f={},g=t(b),h=g.next();!h.done;f={Ua:f.Ua},h=g.next())if(h=h.value,e.keySystem==h.keySystem){f.Ua=[];f.Ua=f.Ua.concat(e.initData||[]);f.Ua=f.Ua.concat(h.initData||[]);f.Ua=f.Ua.filter(function(k){return function(l,m){return void 0===l.keyId||m===k.Ua.findIndex(function(n){return n.keyId===l.keyId})}}(f));g=e.keyIds&&h.keyIds?new Set([].concat(ia(e.keyIds),ia(h.keyIds))):
217
218
  e.keyIds||h.keyIds;c.push({keySystem:e.keySystem,licenseServerUri:e.licenseServerUri||h.licenseServerUri,distinctiveIdentifierRequired:e.distinctiveIdentifierRequired||h.distinctiveIdentifierRequired,persistentStateRequired:e.persistentStateRequired||h.persistentStateRequired,videoRobustness:e.videoRobustness||h.videoRobustness,audioRobustness:e.audioRobustness||h.audioRobustness,serverCertificate:e.serverCertificate||h.serverCertificate,serverCertificateUri:e.serverCertificateUri||h.serverCertificateUri,
218
- initData:f.Ua,keyIds:g});break}}return c}function Nf(a){return(a.video?a.video.drmInfos:[]).concat(a.audio?a.audio.drmInfos:[])}function Df(a){a.i.forEach(function(b,c){var d=b.me,e=c.expiration;isNaN(e)&&(e=Infinity);e!=d&&(a.G.onExpirationUpdated(c.sessionId,e),b.me=e)})}function dg(a){a=a.i.values();return hb(a,function(b){return b.loaded})}
219
- function Mf(a,b){var c=[];b.forEach(function(f,g){c.push({keySystem:g,licenseServerUri:f,distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,serverCertificateUri:"",initData:[],keyIds:new Set})});for(var d=t(a),e=d.next();!e.done;e=d.next())e=e.value,e.video&&(e.video.drmInfos=c),e.audio&&(e.audio.drmInfos=c)}
220
- function bg(a,b,c,d,e,f){var g={};a=t(a);for(var h=a.next();!h.done;g={Ha:g.Ha},h=a.next()){g.Ha=h.value;b.includes(g.Ha.licenseServerUri)||b.push(g.Ha.licenseServerUri);d.includes(g.Ha.serverCertificateUri)||d.push(g.Ha.serverCertificateUri);g.Ha.serverCertificate&&(c.some(function(m){return function(n){return Ec(n,m.Ha.serverCertificate)}}(g))||c.push(g.Ha.serverCertificate));if(g.Ha.initData){h={};for(var k=t(g.Ha.initData),l=k.next();!l.done;h={Xc:h.Xc},l=k.next())h.Xc=l.value,e.some(function(m){return function(n){var p=
219
+ initData:f.Ua,keyIds:g});break}}return c}function Qf(a){return(a.video?a.video.drmInfos:[]).concat(a.audio?a.audio.drmInfos:[])}function Gf(a){a.i.forEach(function(b,c){var d=b.oe,e=c.expiration;isNaN(e)&&(e=Infinity);e!=d&&(a.G.onExpirationUpdated(c.sessionId,e),b.oe=e)})}function gg(a){a=a.i.values();return hb(a,function(b){return b.loaded})}
220
+ function Pf(a,b){var c=[];b.forEach(function(f,g){c.push({keySystem:g,licenseServerUri:f,distinctiveIdentifierRequired:!1,persistentStateRequired:!1,audioRobustness:"",videoRobustness:"",serverCertificate:null,serverCertificateUri:"",initData:[],keyIds:new Set})});for(var d=t(a),e=d.next();!e.done;e=d.next())e=e.value,e.video&&(e.video.drmInfos=c),e.audio&&(e.audio.drmInfos=c)}
221
+ function eg(a,b,c,d,e,f){var g={};a=t(a);for(var h=a.next();!h.done;g={Ha:g.Ha},h=a.next()){g.Ha=h.value;b.includes(g.Ha.licenseServerUri)||b.push(g.Ha.licenseServerUri);d.includes(g.Ha.serverCertificateUri)||d.push(g.Ha.serverCertificateUri);g.Ha.serverCertificate&&(c.some(function(m){return function(n){return Ec(n,m.Ha.serverCertificate)}}(g))||c.push(g.Ha.serverCertificate));if(g.Ha.initData){h={};for(var k=t(g.Ha.initData),l=k.next();!l.done;h={Xc:h.Xc},l=k.next())h.Xc=l.value,e.some(function(m){return function(n){var p=
221
222
  m.Xc;return n.keyId&&n.keyId==p.keyId?!0:n.initDataType==p.initDataType&&Ec(n.initData,p.initData)}}(h))||e.push(h.Xc)}if(g.Ha.keyIds)for(h=t(g.Ha.keyIds),k=h.next();!k.done;k=h.next())f.add(k.value)}}
222
- function Of(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=
223
- 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 lg=1,fg=5,gg=.5,ng=new Oc(function(){return Hc(new Uint8Array([0]))});function og(){}function pg(a,b,c,d){var e,f,g,h;return I(function(k){if(1==k.g){if(d&&(e=qg[d.toLowerCase()]))return k["return"](e);if(f=rg(a))if(g=sg[f])return k["return"](g);return d?k.D(2):u(k,tg(a,b,c),3)}if(2!=k.g&&(d=k.h)&&(h=qg[d]))return k["return"](h);throw new O(2,4,4E3,a);})}
224
- function tg(a,b,c){var d,e,f;return I(function(g){if(1==g.g)return d=kf([a],c),d.method="HEAD",u(g,b.request(0,d).promise,2);e=g.h;f=e.headers["content-type"];return g["return"](f?f.toLowerCase().split(";").shift():"")})}function rg(a){a=(new lb(a)).Ka.split("/").pop().split(".");return 1==a.length?"":a.pop().toLowerCase()}J("shaka.media.ManifestParser",og);og.unregisterParserByMime=function(a){delete qg[a]};og.registerParserByMime=function(a,b){qg[a]=b};
225
- og.registerParserByExtension=function(a,b){sg[a]=b};var qg={},sg={};function ug(a,b){this.W=Jc(a);this.h=b==vg;this.g=0}q=ug.prototype;q.Da=function(){return this.g<this.W.byteLength};q.oa=function(){return this.g};q.pg=function(){return this.W.byteLength};q.qb=function(){try{var a=this.W.getUint8(this.g);this.g+=1;return a}catch(b){throw wg();}};q.qe=function(){try{var a=this.W.getUint16(this.g,this.h);this.g+=2;return a}catch(b){throw wg();}};q.R=function(){try{var a=this.W.getUint32(this.g,this.h);this.g+=4;return a}catch(b){throw wg();}};
226
- q.Bf=function(){try{var a=this.W.getInt32(this.g,this.h);this.g+=4;return a}catch(b){throw wg();}};q.lc=function(){try{if(this.h){var a=this.W.getUint32(this.g,!0);var b=this.W.getUint32(this.g+4,!0)}else b=this.W.getUint32(this.g,!1),a=this.W.getUint32(this.g+4,!1)}catch(c){throw wg();}if(2097151<b)throw new O(2,3,3001);this.g+=8;return b*Math.pow(2,32)+a};q.Cb=function(a){if(this.g+a>this.W.byteLength)throw wg();var b=Gc(this.W,this.g,a);this.g+=a;return b};
227
- q.skip=function(a){if(this.g+a>this.W.byteLength)throw wg();this.g+=a};q.gh=function(a){if(this.g<a)throw wg();this.g-=a};q.seek=function(a){if(0>a||a>this.W.byteLength)throw wg();this.g=a};q.Pc=function(){for(var a=this.g;this.Da()&&0!=this.W.getUint8(this.g);)this.g+=1;a=Gc(this.W,a,this.g-a);this.g+=1;return Rc(a)};function wg(){return new O(2,3,3E3)}J("shaka.util.DataViewReader",ug);ug.prototype.readTerminatedString=ug.prototype.Pc;ug.prototype.seek=ug.prototype.seek;ug.prototype.rewind=ug.prototype.gh;
228
- ug.prototype.skip=ug.prototype.skip;ug.prototype.readBytes=ug.prototype.Cb;ug.prototype.readUint64=ug.prototype.lc;ug.prototype.readInt32=ug.prototype.Bf;ug.prototype.readUint32=ug.prototype.R;ug.prototype.readUint16=ug.prototype.qe;ug.prototype.readUint8=ug.prototype.qb;ug.prototype.getLength=ug.prototype.pg;ug.prototype.getPosition=ug.prototype.oa;ug.prototype.hasMoreData=ug.prototype.Da;var vg=1;ug.Endianness={BIG_ENDIAN:0,LITTLE_ENDIAN:vg};function xg(){this.i=[];this.h=[];this.g=!1}q=xg.prototype;q.box=function(a,b){var c=yg(a);this.i[c]=zg;this.h[c]=b;return this};q.Y=function(a,b){var c=yg(a);this.i[c]=Ag;this.h[c]=b;return this};q.stop=function(){this.g=!0};q.parse=function(a,b,c){a=new ug(a,0);for(this.g=!1;a.Da()&&!this.g;)this.yd(0,a,b,c)};
229
- q.yd=function(a,b,c,d){var e=b.oa();if(d&&e+8>b.W.byteLength)this.g=!0;else{var f=b.R(),g=b.R(),h=!1;switch(f){case 0:f=b.W.byteLength-e;break;case 1:if(d&&b.oa()+8>b.W.byteLength){this.g=!0;return}f=b.lc();h=!0}var k=this.h[g];if(k){var l=null,m=null;if(this.i[g]==Ag){if(d&&b.oa()+4>b.W.byteLength){this.g=!0;return}m=b.R();l=m>>>24;m&=16777215}g=e+f;c&&g>b.W.byteLength&&(g=b.W.byteLength);d&&g>b.W.byteLength?this.g=!0:(d=g-b.oa(),b=0<d?b.Cb(d):new Uint8Array(0),b=new ug(b,0),k({parser:this,partialOkay:c||
230
- !1,version:l,flags:m,reader:b,size:f,start:e+a,has64BitSize:h}))}else b.skip(Math.min(e+f-b.oa(),b.W.byteLength-b.oa()))}};function Bg(a){for(var b=Cg(a);a.reader.Da()&&!a.parser.g;)a.parser.yd(a.start+b,a.reader,a.partialOkay)}function Dg(a){for(var b=Cg(a),c=a.reader.R(),d=0;d<c&&(a.parser.yd(a.start+b,a.reader,a.partialOkay),!a.parser.g);d++);}function Eg(a){return function(b){a(b.reader.Cb(b.reader.W.byteLength-b.reader.oa()))}}
231
- function yg(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 Fg(a){return String.fromCharCode(a>>24&255,a>>16&255,a>>8&255,a&255)}function Cg(a){return 8+(a.has64BitSize?8:0)+(null!=a.flags?4:0)}J("shaka.util.Mp4Parser",xg);xg.headerSize=Cg;xg.typeToString=Fg;xg.allData=Eg;xg.sampleDescription=Dg;xg.children=Bg;xg.prototype.parseNext=xg.prototype.yd;xg.prototype.parse=xg.prototype.parse;xg.prototype.stop=xg.prototype.stop;
232
- xg.prototype.fullBox=xg.prototype.Y;xg.prototype.box=xg.prototype.box;var zg=0,Ag=1;function Gg(a){function b(){d=!0}function c(l){f.push(l);Bg(l)}a=Gc(a);var d=!1,e,f=[],g=[];(new xg).box("moov",c).box("trak",c).box("mdia",c).box("minf",c).box("stbl",c).Y("stsd",function(l){e=l;f.push(l);Dg(l)}).Y("encv",b).Y("enca",b).Y("avc1",function(l){g.push({box:l,Nc:1701733238})}).Y("avc3",function(l){g.push({box:l,Nc:1701733238})}).Y("ac-3",function(l){g.push({box:l,Nc:1701733217})}).Y("ec-3",function(l){g.push({box:l,Nc:1701733217})}).Y("mp4a",function(l){g.push({box:l,Nc:1701733217})}).parse(a);
233
- if(d)return a;if(0==g.length||!e)throw $a(bd(a)),new O(2,3,3019);g.reverse();for(var h=t(g),k=h.next();!k.done;k=h.next())k=k.value,a=Hg(a,e,k.box,f,k.Nc);return a}
234
- function Hg(a,b,c,d,e){var f=Ig.value(),g=a.subarray(c.start,c.start+c.size),h=Jc(g),k=new Uint8Array(c.size+f.byteLength);k.set(g,0);g=Jc(k);g.setUint32(4,e);k.set(f,c.size);e=h.getUint32(4);g.setUint32(c.size+16,e);Jg(k,0,k.byteLength);e=new Uint8Array(a.byteLength+k.byteLength);c=Bd()?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,Jg(e,d.start,d.size+k.byteLength);k=Jc(e,b.start);b=Cg(b);a=k.getUint32(b);
235
- k.setUint32(b,a+1);return e}function Jg(a,b,c){a=Jc(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 Ig=new Oc(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 Kg(a,b,c,d,e){if(d>=e)return null;for(var f=-1,g=-1,h=0;h<c.length;h++)if(c[h].some(function(B){return null!=B&&""!=B.g.trim()})){f=h;break}for(h=c.length-1;0<=h;h--)if(c[h].some(function(B){return null!=B&&""!=B.g.trim()})){g=h;break}if(-1===f||-1===g)return null;for(var k=h=!1,l="white",m="black",n=Lg(d,e,h,k,l,m);f<=g;f++){for(var p=c[f],r=-1,x=-1,y=0;y<p.length;y++)if(null!=p[y]&&""!==p[y].g.trim()){r=y;break}for(y=p.length-1;0<=y;y--)if(null!=p[y]&&""!==p[y].g.trim()){x=y;break}if(-1===
236
- r||-1===x)p=Mg(d,e),a.nestedCues.push(p);else{for(;r<=x;r++)if(y=p[r]){var w=y.l,v=y.i,D=y.j,C=y.h;if(w!=h||v!=k||D!=l||C!=m)n.payload&&a.nestedCues.push(n),n=Lg(d,e,w,v,D,C),h=w,k=v,l=D,m=C;n.payload+=y.g}else n.payload+=" ";n.payload&&a.nestedCues.push(n);f!==g&&(n=Mg(d,e),a.nestedCues.push(n));n=Lg(d,e,h,k,l,m)}}return a.nestedCues.length?{cue:a,stream:b}:null}
237
- function Lg(a,b,c,d,e,f){a=new gc(a,b,"");c&&a.textDecoration.push("underline");d&&(a.fontStyle="italic");a.color=e;a.backgroundColor=f;return a}function Mg(a,b){var c=new gc(a,b,"");c.lineBreak=!0;return c}function Ng(a,b,c,d,e){this.g=a;this.l=b;this.i=c;this.h=d;this.j=e};function Og(a,b){this.i=[];this.g=1;this.h=0;this.C=a;this.B=b;this.j=this.m=!1;this.l="white";this.A="black";Pg(this)}function Qg(a,b,c){return Kg(new gc(b,c,""),"CC"+(a.C<<1|a.B+1),a.i,b,c)}function Pg(a){Rg(a,0,15);a.g=1}function Sg(a,b,c){if(!(32>c||127<c)){var d="";switch(b){case Tg:d=Ug.has(c)?Ug.get(c):String.fromCharCode(c);break;case Vg:d=Wg.get(c);break;case Xg:a.i[a.g].pop();d=Yg.get(c);break;case Zg:a.i[a.g].pop(),d=$g.get(c)}d&&a.i[a.g].push(new Ng(d,a.m,a.j,a.A,a.l))}}
238
- function ah(a,b,c,d){if(b>=c)for(--d;0<=d;d--)a.i[b+d]=a.i[c+d].map(function(f){return f});else for(var e=0;e<d;e++)a.i[b+e]=a.i[c+e].map(function(f){return f})}function Rg(a,b,c){for(var d=0;d<=c;d++)a.i[b+d]=[]}
239
- var Tg=0,Vg=1,Xg=2,Zg=3,Ug=new Map([[39,"\u2019"],[42,"\u00e1"],[92,"\u00e9"],[92,"\u00e9"],[94,"\u00ed"],[95,"\u00f3"],[96,"\u00fa"],[123,"\u00e7"],[124,"\u00f7"],[125,"\u00d1"],[126,"\u00f1"],[127,"\u2588"]]),Wg=new Map([[48,"\u00ae"],[49,"\u00b0"],[50,"\u00bd"],[51,"\u00bf"],[52,"\u2122"],[53,"\u00a2"],[54,"\u00a3"],[55,"\u266a"],[56,"\u00e0"],[57,"\u2800"],[58,"\u00e8"],[59,"\u00e2"],[60,"\u00ea"],[61,"\u00ee"],[62,"\u00f4"],[63,"\u00fb"]]),Yg=new Map([[32,"\u00c1"],[33,"\u00c9"],[34,"\u00d3"],
240
- [35,"\u00da"],[36,"\u00dc"],[37,"\u00fc"],[38,"\u2018"],[39,"\u00a1"],[40,"*"],[41,"'"],[42,"\u2500"],[43,"\u00a9"],[44,"\u2120"],[45,"\u00b7"],[46,"\u201c"],[47,"\u201d"],[48,"\u00c0"],[49,"\u00c2"],[50,"\u00c7"],[51,"\u00c8"],[52,"\u00ca"],[53,"\u00cb"],[54,"\u00eb"],[55,"\u00ce"],[56,"\u00cf"],[57,"\u00ef"],[58,"\u00d4"],[59,"\u00d9"],[60,"\u00f9"],[61,"\u00db"],[62,"\u00ab"],[63,"\u00bb"]]),$g=new Map([[32,"\u00c3"],[33,"\u00e3"],[34,"\u00cd"],[35,"\u00cc"],[36,"\u00ec"],[37,"\u00d2"],[38,"\u00f2"],
241
- [39,"\u00d5"],[40,"\u00f5"],[41,"{"],[42,"}"],[43,"\\"],[44,"^"],[45,"_"],[46,"|"],[47,"~"],[48,"\u00c4"],[49,"\u00e4"],[50,"\u00d6"],[51,"\u00f6"],[52,"\u00df"],[53,"\u00a5"],[54,"\u00a4"],[55,"\u2502"],[56,"\u00c5"],[57,"\u00e5"],[58,"\u00d8"],[59,"\u00f8"],[60,"\u250c"],[61,"\u2510"],[62,"\u2514"],[63,"\u2518"]]);function bh(a,b){this.h=ch;this.A=new Og(a,b);this.i=new Og(a,b);this.l=new Og(a,b);this.g=this.i;this.j=0;this.m=null}function dh(a,b,c){a.g=a.i;var d=a.g,e=null;a.h!==eh&&a.h!==fh&&(e=Qg(d,a.j,c),c=a.i,c.g=0<c.h?c.h:0,Rg(c,0,15),c=a.l,c.g=0<c.h?c.h:0,Rg(c,0,15),d.g=15);a.h=eh;d.h=b;return e}function gh(a){a.h=hh;a.g=a.l;a.g.h=0}function ih(a){Va("Cea608DataChannel","CEA-608 text mode entered, but is unsupported");a.g=a.A;a.h=fh}
242
- var ch=0,hh=1,eh=3,fh=4,jh="black green blue cyan red yellow magenta black".split(" "),kh="white green blue cyan red yellow magenta white_italics".split(" ");function lh(){this.l=!1;this.F=this.H=0;this.G=mh;this.i=[];this.g=this.h=this.j=0;this.C=this.A=!1;this.B="white";this.m="black";nh(this)}function nh(a){a.i=[];for(var b=0;15>b;b++)a.i.push(oh())}function oh(){for(var a=[],b=0;42>b;b++)a.push(null);return a}function ph(a,b){qh(a)&&(a.i[a.h][a.g]=new Ng(b,a.C,a.A,a.m,a.B),a.g++)}function qh(a){var b=a.g<a.F&&0<=a.g;return a.h<a.H&&0<=a.h&&b}lh.prototype.isVisible=function(){return this.l};
243
- function rh(a,b,c){var d=new gc(a.j,b,"");d.textAlign=a.G===sh?"left":a.G===th?"right":kc;if(c=Kg(d,"svc"+c,a.i,a.j,b))a.j=b;return c}var sh=0,th=1,mh=2;function uh(){this.i=[];this.h=null;this.g=0}function vh(a,b){3===b.type?(a.g=2*(b.value&63)-1,a.h=[]):a.h&&(0<a.g&&(a.h.push(b),a.g--),0===a.g&&(a.i.push(new wh(a.h)),a.h=null,a.g=0))}function wh(a){this.g=0;this.h=a}wh.prototype.Da=function(){return this.g<this.h.length};wh.prototype.oa=function(){return this.g};function xh(a){if(!a.Da())throw new O(2,2,3E3);return a.h[a.g++]}wh.prototype.skip=function(a){if(this.g+a>this.h.length)throw new O(2,2,3E3);this.g+=a};function yh(a){this.i=a;this.h=[null,null,null,null,null,null,null,null];this.g=null}
244
- function zh(a,b,c,d){if(128<=c&&135>=c)d=c&7,a.h[d]&&(a.g=a.h[d]);else{if(136===c){c=xh(b).value;b=null;c=t(Ah(a,c));for(var e=c.next();!e.done;e=c.next())e=a.h[e.value],e.isVisible()&&(b=rh(e,d,a.i)),nh(e);return b}if(137===c)for(b=xh(b).value,b=t(Ah(a,b)),c=b.next();!c.done;c=b.next())c=a.h[c.value],c.isVisible()||(c.j=d),c.l=!0;else{if(138===c){c=xh(b).value;b=null;c=t(Ah(a,c));for(e=c.next();!e.done;e=c.next())e=a.h[e.value],e.isVisible()&&(b=rh(e,d,a.i)),e.l=!1;return b}if(139===c){c=xh(b).value;
245
- b=null;c=t(Ah(a,c));for(e=c.next();!e.done;e=c.next())e=a.h[e.value],e.isVisible()?b=rh(e,d,a.i):e.j=d,e.l=!e.l;return b}if(140===c)return b=xh(b).value,Bh(a,b,d);if(143===c)return d=Bh(a,255,d),Ch(a),d;if(144===c)b.skip(1),d=xh(b).value,a.g&&(a.g.A=0<(d&128),a.g.C=0<(d&64));else if(145===c)d=xh(b).value,c=xh(b).value,b.skip(1),a.g&&(b=Dh((c&48)>>4,(c&12)>>2,c&3),a.g.B=Dh((d&48)>>4,(d&12)>>2,d&3),a.g.m=b);else if(146===c)d=xh(b).value,b=xh(b).value,a.g&&(a=a.g,a.h=d&15,a.g=b&63);else if(151===c)b.skip(1),
246
- b.skip(1),d=xh(b).value,b.skip(1),a.g&&(a.g.G=d&3);else if(152<=c&&159>=c){c=(c&15)-8;e=null!==a.h[c];if(!e){var f=new lh;f.j=d;a.h[c]=f}d=xh(b).value;xh(b);xh(b);f=xh(b).value;var g=xh(b).value;b=xh(b).value;e&&0===(b&7)||(b=a.h[c],b.h=0,b.g=0,b.C=!1,b.A=!1,b.B="white",b.m="black");b=a.h[c];b.l=0<(d&32);b.H=(f&15)+1;b.F=(g&63)+1;a.g=a.h[c]}}}return null}function Ah(a,b){for(var c=[],d=0;8>d;d++)1===(b&1)&&a.h[d]&&c.push(d),b>>=1;return c}
247
- function Bh(a,b,c){var d=null;b=t(Ah(a,b));for(var e=b.next();!e.done;e=b.next()){e=e.value;var f=a.h[e];f.isVisible()&&(d=rh(f,c,a.i));a.h[e]=null}return d}function Ch(a){a.g=null;a.h=[null,null,null,null,null,null,null,null]}function Dh(a,b,c){var d={0:0,1:0,2:1,3:1};a=d[a];b=d[b];c=d[c];return Eh[a<<2|b<<1|c]}
248
- var Fh=new Map([[32," "],[33,"\u00a0"],[37,"\u2026"],[42,"\u0160"],[44,"\u0152"],[48,"\u2588"],[49,"\u2018"],[50,"\u2019"],[51,"\u201c"],[52,"\u201d"],[53,"\u2022"],[57,"\u2122"],[58,"\u0161"],[60,"\u0153"],[61,"\u2120"],[63,"\u0178"],[118,"\u215b"],[119,"\u215c"],[120,"\u215d"],[121,"\u215e"],[122,"\u2502"],[123,"\u2510"],[124,"\u2514"],[125,"\u2500"],[126,"\u2518"],[127,"\u250c"]]),Eh="black blue green cyan red magenta yellow white".split(" ");function Gh(){this.h=[];this.g=[];this.i=new uh;this.l=0;this.B=new Map([["CC1",new bh(0,0)],["CC2",new bh(0,1)],["CC3",new bh(1,0)],["CC4",new bh(1,1)]]);this.A=this.m=0;this.j=new Map;Hh(this)}function Hh(a){a.m=0;a.A=0;a=t(a.B.values());for(var b=a.next();!b.done;b=a.next())b=b.value,b.h=2,b.g=b.i,b.m=null,Pg(b.i),Pg(b.l),Pg(b.A)}
249
- function Ih(a){function b(f,g){return f.pts-g.pts||f.order-g.order}var c=[];a.h.sort(b);a.g.sort(b);for(var d=t(a.h),e=d.next();!e.done;e=d.next())(e=Jh(a,e.value))&&c.push(e);d=t(a.g);for(e=d.next();!e.done;e=d.next())vh(a.i,e.value);d=t(a.i.i);for(e=d.next();!e.done;e=d.next())e=Kh(a,e.value),c.push.apply(c,ia(e));a.i.i=[];a.h=[];a.g=[];return c}
250
- function Jh(a,b){var c=b.type;if(16===(b.Oa&112)){var d=b.Oa>>3&1;0===c?a.m=d:a.A=d}c=a.B.get("CC"+(c<<1|(c?a.A:a.m)+1));if(255===b.Oa&&255===b.jb||!b.Oa&&!b.jb||!Lh(b.Oa)||!Lh(b.jb))return 45<=++a.l&&Hh(a),null;a.l=0;b.Oa&=127;b.jb&=127;if(!b.Oa&&!b.jb)return null;d=null;if(16===(b.Oa&112))a:{var e=b.Oa;d=b.jb;if(c.m===(e<<8|d))c.m=null;else if(c.m=e<<8|d,16===(e&240)&&64===(d&192)){e=[11,11,1,2,3,4,12,13,14,15,5,6,7,8,9,10][(e&7)<<1|d>>5&1];var f=(d&30)>>1,g="white",h=!1;7>f?g=kh[f]:7===f&&(h=!0);
251
- d=1===(d&1);if(c.h!==fh){f=c.g;if(c.h===eh&&e!==f.g){var k=1+e-f.h;ah(f,k,1+f.g-f.h,f.h);Rg(f,0,k-1);Rg(f,e+1,15-e)}f.g=e;c.g.m=d;c.g.j=h;c.g.l=g;c.g.A="black"}}else if(17===(e&247)&&32===(d&240))c.g.m=!1,c.g.j=!1,c.g.l="white",Sg(c.g,Tg,32),g=!1,e=kh[(d&14)>>1],"white_italics"===e&&(e="white",g=!0),c.g.m=1===(d&1),c.g.j=g,c.g.l=e;else if(16===(e&247)&&32===(d&240)||23===(e&247)&&45===(d&255))g="black",0===(e&7)&&(g=jh[(d&14)>>1]),c.g.A=g;else if(17===(e&247)&&48===(d&240))Sg(c.g,Vg,d);else if(18===
252
- (e&246)&&32===(d&224))Sg(c.g,e&1?Zg:Xg,d);else if(20===(e&246)&&32===(d&240)){d=b.pts;e=null;switch(b.jb){case 32:gh(c);break;case 33:c=c.g;c.i[c.g].pop();break;case 37:e=dh(c,2,d);break;case 38:e=dh(c,3,d);break;case 39:e=dh(c,4,d);break;case 40:Sg(c.g,Tg,32);break;case 41:c.h=2;c.g=c.i;c.g.h=0;c.j=d;break;case 42:Pg(c.A);ih(c);break;case 43:ih(c);break;case 44:e=c.i;g=null;c.h!==fh&&(g=Qg(e,c.j,d));Rg(e,0,15);e=g;break;case 45:e=c.g;c.h!==eh?e=null:(g=Qg(e,c.j,d),h=e.g-e.h+1,ah(e,h-1,h,e.h),Rg(e,
253
- 0,h-1),Rg(e,e.g,15-e.g),c.j=d,e=g);break;case 46:Rg(c.l,0,15);break;case 47:e=null,c.h!==fh&&(e=Qg(c.i,c.j,d)),g=c.l,c.l=c.i,c.i=g,gh(c),c.j=d}d=e;break a}d=null}else e=b.jb,Sg(c.g,Tg,b.Oa),Sg(c.g,Tg,e);return d}
254
- function Kh(a,b){var c=[];try{for(;b.Da();){var d=xh(b).value,e=(d&224)>>5,f=d&31;7===e&&0!=f&&(e=xh(b).value&63);if(0!=e){a.j.has(e)||a.j.set(e,new yh(e));for(var g=a.j.get(e),h=b.oa();b.oa()-h<f;){e=b;var k=xh(e),l=k.value,m=k.pts;if(16===l){var n=xh(e);l=l<<16|n.value}if(0<=l&&31>=l){var p=m;if(g.g){var r=g.g;e=null;switch(l){case 8:!qh(r)||0>=r.g&&0>=r.h||(0>=r.g?(r.g=r.F-1,r.h--):r.g--,r.i[r.h][r.g]=null);break;case 13:r.isVisible()&&(e=rh(r,p,g.i));if(r.h+1>=r.H){p=r;for(var x=0,y=1;15>y;y++,
255
- x++)p.i[x]=p.i[y];for(y=0;1>y;y++,x++)p.i[x]=oh()}else r.h++;r.g=0;break;case 14:r.isVisible()&&(e=rh(r,p,g.i));r.i[r.h]=oh();r.g=0;break;case 12:r.isVisible()&&(e=rh(r,p,g.i)),nh(r),p=r,p.h=0,p.g=0}var w=e}else w=null}else if(128<=l&&159>=l)w=zh(g,e,l,m);else{if(4096<=l&&4127>=l)p=l&255,8<=p&&15>=p?e.skip(1):16<=p&&23>=p?e.skip(2):24<=p&&31>=p&&e.skip(3);else if(4224<=l&&4255>=l)p=l&255,128<=p&&135>=p?e.skip(4):136<=p&&143>=p&&e.skip(5);else if(32<=l&&127>=l)e=l,g.g&&(127===e?ph(g.g,"\u266a"):ph(g.g,
256
- String.fromCharCode(e)));else if(160<=l&&255>=l)g.g&&ph(g.g,String.fromCharCode(l));else if(4128<=l&&4223>=l){if(e=l&255,g.g)if(Fh.has(e)){var v=Fh.get(e);ph(g.g,v)}else ph(g.g,"_")}else 4256<=l&&4351>=l&&g.g&&(160!=(l&255)?ph(g.g,"_"):ph(g.g,"[CC]"));w=null}(e=w)&&c.push(e)}}}}catch(D){if(D instanceof O&&3E3===D.code)Va("CEA708_INVALID_DATA","Buffer read out of bounds / invalid CEA-708 Data.");else throw D;}return c}function Lh(a){for(var b=0;a;)b^=a&1,a>>=1;return 1===b};function Mh(a,b){var c=null,d=null,e=a.R();b&1&&a.skip(8);b&2&&a.skip(4);b&8&&(c=a.R());b&16&&(d=a.R());return{trackId:e,jf:c,ag:d}}function Nh(a,b){return{Xe:1==b?a.lc():a.R()}}function Oh(a,b){1==b?(a.skip(8),a.skip(8)):(a.skip(4),a.skip(4));return{timescale:a.R()}}
257
- function Ph(a,b,c){var d=a.R(),e=[];c&1&&a.skip(4);c&4&&a.skip(4);for(var f=0;f<d;f++){var g={ve:null,sampleSize:null,Dd:null};c&256&&(g.ve=a.R());c&512&&(g.sampleSize=a.R());c&1024&&a.skip(4);c&2048&&(g.Dd=0==b?a.R():a.Bf());e.push(g)}return{Yi:d,Df:e}};function Qh(){this.i=new Map;this.h=this.g=0}
258
- Qh.prototype.init=function(a){var b=this,c=[],d=[];(new xg).box("moov",Bg).box("mvex",Bg).Y("trex",function(e){var f=e.reader;f.skip(4);f.skip(4);e=f.R();f=f.R();b.g=e;b.h=f}).box("trak",Bg).Y("tkhd",function(e){var f=e.reader;1==e.version?(f.skip(8),f.skip(8)):(f.skip(4),f.skip(4));e=f.R();c.push(e)}).box("mdia",Bg).Y("mdhd",function(e){e=Oh(e.reader,e.version);d.push(e.timescale)}).parse(a,!0);if(!c.length||!d.length||c.length!=d.length)throw new O(2,2,2010);c.forEach(function(e,f){b.i.set(e,d[f])})};
259
- Qh.prototype.parse=function(a){var b=this,c=[],d=this.g,e=this.h,f=[],g=null,h=9E4;(new xg).box("moof",Bg).box("traf",Bg).Y("trun",function(k){f=Ph(k.reader,k.version,k.flags).Df}).Y("tfhd",function(k){k=Mh(k.reader,k.flags);d=k.jf||b.g;e=k.ag||b.h;k=k.trackId;b.i.has(k)&&(h=b.i.get(k))}).Y("tfdt",function(k){g=Nh(k.reader,k.version).Xe}).box("mdat",function(k){if(null===g)throw new O(2,2,2010);k=k.reader;var l=g,m=h,n=d,p=e,r=f,x=0,y=p;for(r.length&&(y=r[0].sampleSize||p);k.Da();){var w=k.R();if(6==
260
- (k.qb()&31)){var v=0;r.length>x&&(v=r[x].Dd||0);v=(l+v)/m;for(var D=[],C,B=k.Cb(w-1),G=C=0;G<B.length;)2==C&&3==B[G]?(C=0,B=[].concat(ia(B)),B.splice(G,1),B=new Uint8Array(B)):0==B[G]?C++:C=0,G++;C=B;for(G=0;G<C.length;){for(B=0;255==C[G];)B+=255,G++;B+=C[G++];for(var E=0;255==C[G];)E+=255,G++;E+=C[G++];4==B&&D.push(C.subarray(G,G+E));G+=E}D=t(D);for(C=D.next();!C.done;C=D.next())c.push({Vg:C.value,pts:v})}else try{k.skip(w-1)}catch(H){break}y-=w+4;0==y&&(l=r.length>x?l+(r[x].ve||n):l+n,x++,y=r.length>
261
- x?r[x].sampleSize||p:p)}}).parse(a,!1);return c};function Rh(){this.h=new Qh;this.g=new Gh}Rh.prototype.init=function(a){this.h.init(a)};
262
- function Sh(a,b){var c=a.h.parse(b);c=t(c);for(var d=c.next();!d.done;d=c.next()){var e=d.value,f=Gc(e.Vg);if(0<f.length&&(d=a.g,e=e.pts,f=new ug(f,0),181===f.qb()&&49===f.qe()&&1195456820===f.R()&&3===f.qb())){var g=f.qb();if(0!==(g&64)){g&=31;f.skip(1);for(var h=0;h<g;h++){var k=f.qb(),l=(k&4)>>2,m=f.qb(),n=f.qb();l&&(k&=3,0===k||1===k?d.h.push({pts:e,type:k,Oa:m,jb:n,order:d.h.length}):(d.g.push({pts:e,type:k,value:m,order:d.g.length}),d.g.push({pts:e,type:2,value:n,order:d.g.length})))}}}}return Ih(a.g)}
263
- ;function Th(a){return!a||1==a.length&&1E-6>a.end(0)-a.start(0)?null:1==a.length&&0>a.start(0)?0:a.length?a.start(0):null}function Uh(a){return!a||1==a.length&&1E-6>a.end(0)-a.start(0)?null:a.length?a.end(a.length-1):null}function Vh(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)}
264
- function Wh(a,b){if(!a||!a.length||1==a.length&&1E-6>a.end(0)-a.start(0))return 0;for(var c=0,d=t(Xh(a)),e=d.next();!e.done;e=d.next()){var f=e.value;e=f.start;f=f.end;f>b&&(c+=f-Math.max(e,b))}return c}function Yh(a,b,c){if(!a||!a.length||1==a.length&&1E-6>a.end(0)-a.start(0))return null;a=Xh(a).findIndex(function(d,e,f){return d.start>b&&(0==e||f[e-1].end-b<=c)});return 0<=a?a:null}function Xh(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};function Zh(a,b,c,d){var e=this;this.j=a;this.m=c;this.h={};this.N={};this.K={};this.g=null;this.H=!1;this.S=d||function(){};this.i={};this.A=new tf;this.C={};this.F=b;this.I=new Nc;this.l=$h(this,this.I);this.G=new rf(function(){return ai(e)});this.J="";this.B=!1;this.P=new Nc}function $h(a,b){var c=new MediaSource;a.A.Fa(c,"sourceopen",function(){URL.revokeObjectURL(a.J);b.resolve()});a.J=bi(c);a.j.src=a.J;return c}q=Zh.prototype;q.destroy=function(){return this.G.destroy()};
265
- function ai(a){var b,c,d,e,f,g,h,k;return I(function(l){if(1==l.g){b=[];for(c in a.i)for(d=a.i[c],e=d[0],a.i[c]=d.slice(0,1),e&&b.push(e.p["catch"](Bb)),f=t(d.slice(1)),g=f.next();!g.done;g=f.next())h=g.value,h.p.reject(new O(2,7,7003,void 0));a.g&&b.push(a.g.destroy());a.m&&b.push(a.m.destroy());for(k in a.C)b.push(a.C[k].destroy());return u(l,Promise.all(b),2)}a.A&&(a.A.release(),a.A=null);a.j&&(a.j.removeAttribute("src"),a.j.load(),a.j=null);a.l=null;a.g=null;a.m=null;a.h={};a.C={};a.F=null;a.i=
223
+ function Rf(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=
224
+ 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 og=1,ig=5,lg=.5,qg=new Oc(function(){return Hc(new Uint8Array([0]))});function rg(){}function sg(a,b,c,d){var e,f,g,h;return I(function(k){if(1==k.g){if(d&&(e=tg[d.toLowerCase()]))return k["return"](e);if(f=ug(a))if(g=vg[f])return k["return"](g);return d?k.D(2):u(k,wg(a,b,c),3)}if(2!=k.g&&(d=k.h)&&(h=tg[d]))return k["return"](h);throw new O(2,4,4E3,a);})}
225
+ function wg(a,b,c){var d,e,f;return I(function(g){if(1==g.g)return d=nf([a],c),d.method="HEAD",u(g,b.request(0,d).promise,2);e=g.h;f=e.headers["content-type"];return g["return"](f?f.toLowerCase().split(";").shift():"")})}function ug(a){a=(new lb(a)).Ka.split("/").pop().split(".");return 1==a.length?"":a.pop().toLowerCase()}J("shaka.media.ManifestParser",rg);rg.unregisterParserByMime=function(a){delete tg[a]};rg.registerParserByMime=function(a,b){tg[a]=b};
226
+ rg.registerParserByExtension=function(a,b){vg[a]=b};var tg={},vg={};function xg(a,b){this.W=Jc(a);this.h=b==yg;this.g=0}q=xg.prototype;q.Da=function(){return this.g<this.W.byteLength};q.oa=function(){return this.g};q.qg=function(){return this.W.byteLength};q.qb=function(){try{var a=this.W.getUint8(this.g);this.g+=1;return a}catch(b){throw zg();}};q.re=function(){try{var a=this.W.getUint16(this.g,this.h);this.g+=2;return a}catch(b){throw zg();}};q.R=function(){try{var a=this.W.getUint32(this.g,this.h);this.g+=4;return a}catch(b){throw zg();}};
227
+ q.Cf=function(){try{var a=this.W.getInt32(this.g,this.h);this.g+=4;return a}catch(b){throw zg();}};q.lc=function(){try{if(this.h){var a=this.W.getUint32(this.g,!0);var b=this.W.getUint32(this.g+4,!0)}else b=this.W.getUint32(this.g,!1),a=this.W.getUint32(this.g+4,!1)}catch(c){throw zg();}if(2097151<b)throw new O(2,3,3001);this.g+=8;return b*Math.pow(2,32)+a};q.Cb=function(a){if(this.g+a>this.W.byteLength)throw zg();var b=Gc(this.W,this.g,a);this.g+=a;return b};
228
+ q.skip=function(a){if(this.g+a>this.W.byteLength)throw zg();this.g+=a};q.hh=function(a){if(this.g<a)throw zg();this.g-=a};q.seek=function(a){if(0>a||a>this.W.byteLength)throw zg();this.g=a};q.Pc=function(){for(var a=this.g;this.Da()&&0!=this.W.getUint8(this.g);)this.g+=1;a=Gc(this.W,a,this.g-a);this.g+=1;return ed(a)};function zg(){return new O(2,3,3E3)}J("shaka.util.DataViewReader",xg);xg.prototype.readTerminatedString=xg.prototype.Pc;xg.prototype.seek=xg.prototype.seek;xg.prototype.rewind=xg.prototype.hh;
229
+ xg.prototype.skip=xg.prototype.skip;xg.prototype.readBytes=xg.prototype.Cb;xg.prototype.readUint64=xg.prototype.lc;xg.prototype.readInt32=xg.prototype.Cf;xg.prototype.readUint32=xg.prototype.R;xg.prototype.readUint16=xg.prototype.re;xg.prototype.readUint8=xg.prototype.qb;xg.prototype.getLength=xg.prototype.qg;xg.prototype.getPosition=xg.prototype.oa;xg.prototype.hasMoreData=xg.prototype.Da;var yg=1;xg.Endianness={BIG_ENDIAN:0,LITTLE_ENDIAN:yg};function Ag(){this.i=[];this.h=[];this.g=!1}q=Ag.prototype;q.box=function(a,b){var c=Bg(a);this.i[c]=Cg;this.h[c]=b;return this};q.Y=function(a,b){var c=Bg(a);this.i[c]=Dg;this.h[c]=b;return this};q.stop=function(){this.g=!0};q.parse=function(a,b,c){a=new xg(a,0);for(this.g=!1;a.Da()&&!this.g;)this.yd(0,a,b,c)};
230
+ q.yd=function(a,b,c,d){var e=b.oa();if(d&&e+8>b.W.byteLength)this.g=!0;else{var f=b.R(),g=b.R(),h=!1;switch(f){case 0:f=b.W.byteLength-e;break;case 1:if(d&&b.oa()+8>b.W.byteLength){this.g=!0;return}f=b.lc();h=!0}var k=this.h[g];if(k){var l=null,m=null;if(this.i[g]==Dg){if(d&&b.oa()+4>b.W.byteLength){this.g=!0;return}m=b.R();l=m>>>24;m&=16777215}g=e+f;c&&g>b.W.byteLength&&(g=b.W.byteLength);d&&g>b.W.byteLength?this.g=!0:(d=g-b.oa(),b=0<d?b.Cb(d):new Uint8Array(0),b=new xg(b,0),k({parser:this,partialOkay:c||
231
+ !1,version:l,flags:m,reader:b,size:f,start:e+a,has64BitSize:h}))}else b.skip(Math.min(e+f-b.oa(),b.W.byteLength-b.oa()))}};function Eg(a){for(var b=Fg(a);a.reader.Da()&&!a.parser.g;)a.parser.yd(a.start+b,a.reader,a.partialOkay)}function Gg(a){for(var b=Fg(a),c=a.reader.R(),d=0;d<c&&(a.parser.yd(a.start+b,a.reader,a.partialOkay),!a.parser.g);d++);}function Hg(a){return function(b){a(b.reader.Cb(b.reader.W.byteLength-b.reader.oa()))}}
232
+ function Bg(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 Ig(a){return String.fromCharCode(a>>24&255,a>>16&255,a>>8&255,a&255)}function Fg(a){return 8+(a.has64BitSize?8:0)+(null!=a.flags?4:0)}J("shaka.util.Mp4Parser",Ag);Ag.headerSize=Fg;Ag.typeToString=Ig;Ag.allData=Hg;Ag.sampleDescription=Gg;Ag.children=Eg;Ag.prototype.parseNext=Ag.prototype.yd;Ag.prototype.parse=Ag.prototype.parse;Ag.prototype.stop=Ag.prototype.stop;
233
+ Ag.prototype.fullBox=Ag.prototype.Y;Ag.prototype.box=Ag.prototype.box;var Cg=0,Dg=1;function Jg(a){function b(){d=!0}function c(l){f.push(l);Eg(l)}a=Gc(a);var d=!1,e,f=[],g=[];(new Ag).box("moov",c).box("trak",c).box("mdia",c).box("minf",c).box("stbl",c).Y("stsd",function(l){e=l;f.push(l);Gg(l)}).Y("encv",b).Y("enca",b).Y("avc1",function(l){g.push({box:l,Nc:1701733238})}).Y("avc3",function(l){g.push({box:l,Nc:1701733238})}).Y("ac-3",function(l){g.push({box:l,Nc:1701733217})}).Y("ec-3",function(l){g.push({box:l,Nc:1701733217})}).Y("mp4a",function(l){g.push({box:l,Nc:1701733217})}).parse(a);
234
+ if(d)return a;if(0==g.length||!e)throw $a(qd(a)),new O(2,3,3019);g.reverse();for(var h=t(g),k=h.next();!k.done;k=h.next())k=k.value,a=Kg(a,e,k.box,f,k.Nc);return a}
235
+ function Kg(a,b,c,d,e){var f=Lg.value(),g=a.subarray(c.start,c.start+c.size),h=Jc(g),k=new Uint8Array(c.size+f.byteLength);k.set(g,0);g=Jc(k);g.setUint32(4,e);k.set(f,c.size);e=h.getUint32(4);g.setUint32(c.size+16,e);Mg(k,0,k.byteLength);e=new Uint8Array(a.byteLength+k.byteLength);c=Uc()?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,Mg(e,d.start,d.size+k.byteLength);k=Jc(e,b.start);b=Fg(b);a=k.getUint32(b);
236
+ k.setUint32(b,a+1);return e}function Mg(a,b,c){a=Jc(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 Lg=new Oc(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 Ng(a,b,c,d,e){if(d>=e)return null;for(var f=-1,g=-1,h=0;h<c.length;h++)if(c[h].some(function(B){return null!=B&&""!=B.g.trim()})){f=h;break}for(h=c.length-1;0<=h;h--)if(c[h].some(function(B){return null!=B&&""!=B.g.trim()})){g=h;break}if(-1===f||-1===g)return null;for(var k=h=!1,l="white",m="black",n=Og(d,e,h,k,l,m);f<=g;f++){for(var p=c[f],r=-1,w=-1,y=0;y<p.length;y++)if(null!=p[y]&&""!==p[y].g.trim()){r=y;break}for(y=p.length-1;0<=y;y--)if(null!=p[y]&&""!==p[y].g.trim()){w=y;break}if(-1===
237
+ r||-1===w)p=Pg(d,e),a.nestedCues.push(p);else{for(;r<=w;r++)if(y=p[r]){var x=y.l,v=y.i,D=y.j,C=y.h;if(x!=h||v!=k||D!=l||C!=m)n.payload&&a.nestedCues.push(n),n=Og(d,e,x,v,D,C),h=x,k=v,l=D,m=C;n.payload+=y.g}else n.payload+=" ";n.payload&&a.nestedCues.push(n);f!==g&&(n=Pg(d,e),a.nestedCues.push(n));n=Og(d,e,h,k,l,m)}}return a.nestedCues.length?{cue:a,stream:b}:null}
238
+ function Og(a,b,c,d,e,f){a=new gc(a,b,"");c&&a.textDecoration.push("underline");d&&(a.fontStyle="italic");a.color=e;a.backgroundColor=f;return a}function Pg(a,b){var c=new gc(a,b,"");c.lineBreak=!0;return c}function Qg(a,b,c,d,e){this.g=a;this.l=b;this.i=c;this.h=d;this.j=e};function Rg(a,b){this.i=[];this.g=1;this.h=0;this.C=a;this.B=b;this.j=this.m=!1;this.l="white";this.A="black";Sg(this)}function Tg(a,b,c){return Ng(new gc(b,c,""),"CC"+(a.C<<1|a.B+1),a.i,b,c)}function Sg(a){Ug(a,0,15);a.g=1}function Vg(a,b,c){if(!(32>c||127<c)){var d="";switch(b){case Wg:d=Xg.has(c)?Xg.get(c):String.fromCharCode(c);break;case Yg:d=Zg.get(c);break;case $g:a.i[a.g].pop();d=ah.get(c);break;case bh:a.i[a.g].pop(),d=ch.get(c)}d&&a.i[a.g].push(new Qg(d,a.m,a.j,a.A,a.l))}}
239
+ function dh(a,b,c,d){if(b>=c)for(--d;0<=d;d--)a.i[b+d]=a.i[c+d].map(function(f){return f});else for(var e=0;e<d;e++)a.i[b+e]=a.i[c+e].map(function(f){return f})}function Ug(a,b,c){for(var d=0;d<=c;d++)a.i[b+d]=[]}
240
+ var Wg=0,Yg=1,$g=2,bh=3,Xg=new Map([[39,"\u2019"],[42,"\u00e1"],[92,"\u00e9"],[92,"\u00e9"],[94,"\u00ed"],[95,"\u00f3"],[96,"\u00fa"],[123,"\u00e7"],[124,"\u00f7"],[125,"\u00d1"],[126,"\u00f1"],[127,"\u2588"]]),Zg=new Map([[48,"\u00ae"],[49,"\u00b0"],[50,"\u00bd"],[51,"\u00bf"],[52,"\u2122"],[53,"\u00a2"],[54,"\u00a3"],[55,"\u266a"],[56,"\u00e0"],[57,"\u2800"],[58,"\u00e8"],[59,"\u00e2"],[60,"\u00ea"],[61,"\u00ee"],[62,"\u00f4"],[63,"\u00fb"]]),ah=new Map([[32,"\u00c1"],[33,"\u00c9"],[34,"\u00d3"],
241
+ [35,"\u00da"],[36,"\u00dc"],[37,"\u00fc"],[38,"\u2018"],[39,"\u00a1"],[40,"*"],[41,"'"],[42,"\u2500"],[43,"\u00a9"],[44,"\u2120"],[45,"\u00b7"],[46,"\u201c"],[47,"\u201d"],[48,"\u00c0"],[49,"\u00c2"],[50,"\u00c7"],[51,"\u00c8"],[52,"\u00ca"],[53,"\u00cb"],[54,"\u00eb"],[55,"\u00ce"],[56,"\u00cf"],[57,"\u00ef"],[58,"\u00d4"],[59,"\u00d9"],[60,"\u00f9"],[61,"\u00db"],[62,"\u00ab"],[63,"\u00bb"]]),ch=new Map([[32,"\u00c3"],[33,"\u00e3"],[34,"\u00cd"],[35,"\u00cc"],[36,"\u00ec"],[37,"\u00d2"],[38,"\u00f2"],
242
+ [39,"\u00d5"],[40,"\u00f5"],[41,"{"],[42,"}"],[43,"\\"],[44,"^"],[45,"_"],[46,"|"],[47,"~"],[48,"\u00c4"],[49,"\u00e4"],[50,"\u00d6"],[51,"\u00f6"],[52,"\u00df"],[53,"\u00a5"],[54,"\u00a4"],[55,"\u2502"],[56,"\u00c5"],[57,"\u00e5"],[58,"\u00d8"],[59,"\u00f8"],[60,"\u250c"],[61,"\u2510"],[62,"\u2514"],[63,"\u2518"]]);function eh(a,b){this.h=fh;this.A=new Rg(a,b);this.i=new Rg(a,b);this.l=new Rg(a,b);this.g=this.i;this.j=0;this.m=null}function gh(a,b,c){a.g=a.i;var d=a.g,e=null;a.h!==hh&&a.h!==ih&&(e=Tg(d,a.j,c),c=a.i,c.g=0<c.h?c.h:0,Ug(c,0,15),c=a.l,c.g=0<c.h?c.h:0,Ug(c,0,15),d.g=15);a.h=hh;d.h=b;return e}function jh(a){a.h=kh;a.g=a.l;a.g.h=0}function lh(a){Va("Cea608DataChannel","CEA-608 text mode entered, but is unsupported");a.g=a.A;a.h=ih}
243
+ var fh=0,kh=1,hh=3,ih=4,mh="black green blue cyan red yellow magenta black".split(" "),nh="white green blue cyan red yellow magenta white_italics".split(" ");function oh(){this.l=!1;this.F=this.H=0;this.G=ph;this.i=[];this.g=this.h=this.j=0;this.C=this.A=!1;this.B="white";this.m="black";qh(this)}function qh(a){a.i=[];for(var b=0;15>b;b++)a.i.push(rh())}function rh(){for(var a=[],b=0;42>b;b++)a.push(null);return a}function sh(a,b){th(a)&&(a.i[a.h][a.g]=new Qg(b,a.C,a.A,a.m,a.B),a.g++)}function th(a){var b=a.g<a.F&&0<=a.g;return a.h<a.H&&0<=a.h&&b}oh.prototype.isVisible=function(){return this.l};
244
+ function uh(a,b,c){var d=new gc(a.j,b,"");d.textAlign=a.G===vh?"left":a.G===wh?"right":kc;if(c=Ng(d,"svc"+c,a.i,a.j,b))a.j=b;return c}var vh=0,wh=1,ph=2;function xh(){this.i=[];this.h=null;this.g=0}function yh(a,b){3===b.type?(a.g=2*(b.value&63)-1,a.h=[]):a.h&&(0<a.g&&(a.h.push(b),a.g--),0===a.g&&(a.i.push(new zh(a.h)),a.h=null,a.g=0))}function zh(a){this.g=0;this.h=a}zh.prototype.Da=function(){return this.g<this.h.length};zh.prototype.oa=function(){return this.g};function Ah(a){if(!a.Da())throw new O(2,2,3E3);return a.h[a.g++]}zh.prototype.skip=function(a){if(this.g+a>this.h.length)throw new O(2,2,3E3);this.g+=a};function Bh(a){this.i=a;this.h=[null,null,null,null,null,null,null,null];this.g=null}
245
+ function Ch(a,b,c,d){if(128<=c&&135>=c)d=c&7,a.h[d]&&(a.g=a.h[d]);else{if(136===c){c=Ah(b).value;b=null;c=t(Dh(a,c));for(var e=c.next();!e.done;e=c.next())e=a.h[e.value],e.isVisible()&&(b=uh(e,d,a.i)),qh(e);return b}if(137===c)for(b=Ah(b).value,b=t(Dh(a,b)),c=b.next();!c.done;c=b.next())c=a.h[c.value],c.isVisible()||(c.j=d),c.l=!0;else{if(138===c){c=Ah(b).value;b=null;c=t(Dh(a,c));for(e=c.next();!e.done;e=c.next())e=a.h[e.value],e.isVisible()&&(b=uh(e,d,a.i)),e.l=!1;return b}if(139===c){c=Ah(b).value;
246
+ b=null;c=t(Dh(a,c));for(e=c.next();!e.done;e=c.next())e=a.h[e.value],e.isVisible()?b=uh(e,d,a.i):e.j=d,e.l=!e.l;return b}if(140===c)return b=Ah(b).value,Eh(a,b,d);if(143===c)return d=Eh(a,255,d),Fh(a),d;if(144===c)b.skip(1),d=Ah(b).value,a.g&&(a.g.A=0<(d&128),a.g.C=0<(d&64));else if(145===c)d=Ah(b).value,c=Ah(b).value,b.skip(1),a.g&&(b=Gh((c&48)>>4,(c&12)>>2,c&3),a.g.B=Gh((d&48)>>4,(d&12)>>2,d&3),a.g.m=b);else if(146===c)d=Ah(b).value,b=Ah(b).value,a.g&&(a=a.g,a.h=d&15,a.g=b&63);else if(151===c)b.skip(1),
247
+ b.skip(1),d=Ah(b).value,b.skip(1),a.g&&(a.g.G=d&3);else if(152<=c&&159>=c){c=(c&15)-8;e=null!==a.h[c];if(!e){var f=new oh;f.j=d;a.h[c]=f}d=Ah(b).value;Ah(b);Ah(b);f=Ah(b).value;var g=Ah(b).value;b=Ah(b).value;e&&0===(b&7)||(b=a.h[c],b.h=0,b.g=0,b.C=!1,b.A=!1,b.B="white",b.m="black");b=a.h[c];b.l=0<(d&32);b.H=(f&15)+1;b.F=(g&63)+1;a.g=a.h[c]}}}return null}function Dh(a,b){for(var c=[],d=0;8>d;d++)1===(b&1)&&a.h[d]&&c.push(d),b>>=1;return c}
248
+ function Eh(a,b,c){var d=null;b=t(Dh(a,b));for(var e=b.next();!e.done;e=b.next()){e=e.value;var f=a.h[e];f.isVisible()&&(d=uh(f,c,a.i));a.h[e]=null}return d}function Fh(a){a.g=null;a.h=[null,null,null,null,null,null,null,null]}function Gh(a,b,c){var d={0:0,1:0,2:1,3:1};a=d[a];b=d[b];c=d[c];return Hh[a<<2|b<<1|c]}
249
+ var Ih=new Map([[32," "],[33,"\u00a0"],[37,"\u2026"],[42,"\u0160"],[44,"\u0152"],[48,"\u2588"],[49,"\u2018"],[50,"\u2019"],[51,"\u201c"],[52,"\u201d"],[53,"\u2022"],[57,"\u2122"],[58,"\u0161"],[60,"\u0153"],[61,"\u2120"],[63,"\u0178"],[118,"\u215b"],[119,"\u215c"],[120,"\u215d"],[121,"\u215e"],[122,"\u2502"],[123,"\u2510"],[124,"\u2514"],[125,"\u2500"],[126,"\u2518"],[127,"\u250c"]]),Hh="black blue green cyan red magenta yellow white".split(" ");function Jh(){this.h=[];this.g=[];this.i=new xh;this.l=0;this.B=new Map([["CC1",new eh(0,0)],["CC2",new eh(0,1)],["CC3",new eh(1,0)],["CC4",new eh(1,1)]]);this.A=this.m=0;this.j=new Map;Kh(this)}function Kh(a){a.m=0;a.A=0;a=t(a.B.values());for(var b=a.next();!b.done;b=a.next())b=b.value,b.h=2,b.g=b.i,b.m=null,Sg(b.i),Sg(b.l),Sg(b.A)}
250
+ function Lh(a){function b(f,g){return f.pts-g.pts||f.order-g.order}var c=[];a.h.sort(b);a.g.sort(b);for(var d=t(a.h),e=d.next();!e.done;e=d.next())(e=Mh(a,e.value))&&c.push(e);d=t(a.g);for(e=d.next();!e.done;e=d.next())yh(a.i,e.value);d=t(a.i.i);for(e=d.next();!e.done;e=d.next())e=Nh(a,e.value),c.push.apply(c,ia(e));a.i.i=[];a.h=[];a.g=[];return c}
251
+ function Mh(a,b){var c=b.type;if(16===(b.Oa&112)){var d=b.Oa>>3&1;0===c?a.m=d:a.A=d}c=a.B.get("CC"+(c<<1|(c?a.A:a.m)+1));if(255===b.Oa&&255===b.jb||!b.Oa&&!b.jb||!Oh(b.Oa)||!Oh(b.jb))return 45<=++a.l&&Kh(a),null;a.l=0;b.Oa&=127;b.jb&=127;if(!b.Oa&&!b.jb)return null;d=null;if(16===(b.Oa&112))a:{var e=b.Oa;d=b.jb;if(c.m===(e<<8|d))c.m=null;else if(c.m=e<<8|d,16===(e&240)&&64===(d&192)){e=[11,11,1,2,3,4,12,13,14,15,5,6,7,8,9,10][(e&7)<<1|d>>5&1];var f=(d&30)>>1,g="white",h=!1;7>f?g=nh[f]:7===f&&(h=!0);
252
+ d=1===(d&1);if(c.h!==ih){f=c.g;if(c.h===hh&&e!==f.g){var k=1+e-f.h;dh(f,k,1+f.g-f.h,f.h);Ug(f,0,k-1);Ug(f,e+1,15-e)}f.g=e;c.g.m=d;c.g.j=h;c.g.l=g;c.g.A="black"}}else if(17===(e&247)&&32===(d&240))c.g.m=!1,c.g.j=!1,c.g.l="white",Vg(c.g,Wg,32),g=!1,e=nh[(d&14)>>1],"white_italics"===e&&(e="white",g=!0),c.g.m=1===(d&1),c.g.j=g,c.g.l=e;else if(16===(e&247)&&32===(d&240)||23===(e&247)&&45===(d&255))g="black",0===(e&7)&&(g=mh[(d&14)>>1]),c.g.A=g;else if(17===(e&247)&&48===(d&240))Vg(c.g,Yg,d);else if(18===
253
+ (e&246)&&32===(d&224))Vg(c.g,e&1?bh:$g,d);else if(20===(e&246)&&32===(d&240)){d=b.pts;e=null;switch(b.jb){case 32:jh(c);break;case 33:c=c.g;c.i[c.g].pop();break;case 37:e=gh(c,2,d);break;case 38:e=gh(c,3,d);break;case 39:e=gh(c,4,d);break;case 40:Vg(c.g,Wg,32);break;case 41:c.h=2;c.g=c.i;c.g.h=0;c.j=d;break;case 42:Sg(c.A);lh(c);break;case 43:lh(c);break;case 44:e=c.i;g=null;c.h!==ih&&(g=Tg(e,c.j,d));Ug(e,0,15);e=g;break;case 45:e=c.g;c.h!==hh?e=null:(g=Tg(e,c.j,d),h=e.g-e.h+1,dh(e,h-1,h,e.h),Ug(e,
254
+ 0,h-1),Ug(e,e.g,15-e.g),c.j=d,e=g);break;case 46:Ug(c.l,0,15);break;case 47:e=null,c.h!==ih&&(e=Tg(c.i,c.j,d)),g=c.l,c.l=c.i,c.i=g,jh(c),c.j=d}d=e;break a}d=null}else e=b.jb,Vg(c.g,Wg,b.Oa),Vg(c.g,Wg,e);return d}
255
+ function Nh(a,b){var c=[];try{for(;b.Da();){var d=Ah(b).value,e=(d&224)>>5,f=d&31;7===e&&0!=f&&(e=Ah(b).value&63);if(0!=e){a.j.has(e)||a.j.set(e,new Bh(e));for(var g=a.j.get(e),h=b.oa();b.oa()-h<f;){e=b;var k=Ah(e),l=k.value,m=k.pts;if(16===l){var n=Ah(e);l=l<<16|n.value}if(0<=l&&31>=l){var p=m;if(g.g){var r=g.g;e=null;switch(l){case 8:!th(r)||0>=r.g&&0>=r.h||(0>=r.g?(r.g=r.F-1,r.h--):r.g--,r.i[r.h][r.g]=null);break;case 13:r.isVisible()&&(e=uh(r,p,g.i));if(r.h+1>=r.H){p=r;for(var w=0,y=1;15>y;y++,
256
+ w++)p.i[w]=p.i[y];for(y=0;1>y;y++,w++)p.i[w]=rh()}else r.h++;r.g=0;break;case 14:r.isVisible()&&(e=uh(r,p,g.i));r.i[r.h]=rh();r.g=0;break;case 12:r.isVisible()&&(e=uh(r,p,g.i)),qh(r),p=r,p.h=0,p.g=0}var x=e}else x=null}else if(128<=l&&159>=l)x=Ch(g,e,l,m);else{if(4096<=l&&4127>=l)p=l&255,8<=p&&15>=p?e.skip(1):16<=p&&23>=p?e.skip(2):24<=p&&31>=p&&e.skip(3);else if(4224<=l&&4255>=l)p=l&255,128<=p&&135>=p?e.skip(4):136<=p&&143>=p&&e.skip(5);else if(32<=l&&127>=l)e=l,g.g&&(127===e?sh(g.g,"\u266a"):sh(g.g,
257
+ String.fromCharCode(e)));else if(160<=l&&255>=l)g.g&&sh(g.g,String.fromCharCode(l));else if(4128<=l&&4223>=l){if(e=l&255,g.g)if(Ih.has(e)){var v=Ih.get(e);sh(g.g,v)}else sh(g.g,"_")}else 4256<=l&&4351>=l&&g.g&&(160!=(l&255)?sh(g.g,"_"):sh(g.g,"[CC]"));x=null}(e=x)&&c.push(e)}}}}catch(D){if(D instanceof O&&3E3===D.code)Va("CEA708_INVALID_DATA","Buffer read out of bounds / invalid CEA-708 Data.");else throw D;}return c}function Oh(a){for(var b=0;a;)b^=a&1,a>>=1;return 1===b};function Ph(a,b){var c=null,d=null,e=a.R();b&1&&a.skip(8);b&2&&a.skip(4);b&8&&(c=a.R());b&16&&(d=a.R());return{trackId:e,kf:c,cg:d}}function Qh(a,b){return{Ye:1==b?a.lc():a.R()}}function Rh(a,b){1==b?(a.skip(8),a.skip(8)):(a.skip(4),a.skip(4));return{timescale:a.R()}}
258
+ function Sh(a,b,c){var d=a.R(),e=[];c&1&&a.skip(4);c&4&&a.skip(4);for(var f=0;f<d;f++){var g={we:null,sampleSize:null,Dd:null};c&256&&(g.we=a.R());c&512&&(g.sampleSize=a.R());c&1024&&a.skip(4);c&2048&&(g.Dd=0==b?a.R():a.Cf());e.push(g)}return{Zi:d,Ef:e}};function Th(){this.i=new Map;this.h=this.g=0}
259
+ Th.prototype.init=function(a){var b=this,c=[],d=[];(new Ag).box("moov",Eg).box("mvex",Eg).Y("trex",function(e){var f=e.reader;f.skip(4);f.skip(4);e=f.R();f=f.R();b.g=e;b.h=f}).box("trak",Eg).Y("tkhd",function(e){var f=e.reader;1==e.version?(f.skip(8),f.skip(8)):(f.skip(4),f.skip(4));e=f.R();c.push(e)}).box("mdia",Eg).Y("mdhd",function(e){e=Rh(e.reader,e.version);d.push(e.timescale)}).parse(a,!0);if(!c.length||!d.length||c.length!=d.length)throw new O(2,2,2010);c.forEach(function(e,f){b.i.set(e,d[f])})};
260
+ Th.prototype.parse=function(a){var b=this,c=[],d=this.g,e=this.h,f=[],g=null,h=9E4;(new Ag).box("moof",Eg).box("traf",Eg).Y("trun",function(k){f=Sh(k.reader,k.version,k.flags).Ef}).Y("tfhd",function(k){k=Ph(k.reader,k.flags);d=k.kf||b.g;e=k.cg||b.h;k=k.trackId;b.i.has(k)&&(h=b.i.get(k))}).Y("tfdt",function(k){g=Qh(k.reader,k.version).Ye}).box("mdat",function(k){if(null===g)throw new O(2,2,2010);k=k.reader;var l=g,m=h,n=d,p=e,r=f,w=0,y=p;for(r.length&&(y=r[0].sampleSize||p);k.Da();){var x=k.R();if(6==
261
+ (k.qb()&31)){var v=0;r.length>w&&(v=r[w].Dd||0);v=(l+v)/m;for(var D=[],C,B=k.Cb(x-1),G=C=0;G<B.length;)2==C&&3==B[G]?(C=0,B=[].concat(ia(B)),B.splice(G,1),B=new Uint8Array(B)):0==B[G]?C++:C=0,G++;C=B;for(G=0;G<C.length;){for(B=0;255==C[G];)B+=255,G++;B+=C[G++];for(var E=0;255==C[G];)E+=255,G++;E+=C[G++];4==B&&D.push(C.subarray(G,G+E));G+=E}D=t(D);for(C=D.next();!C.done;C=D.next())c.push({Wg:C.value,pts:v})}else try{k.skip(x-1)}catch(H){break}y-=x+4;0==y&&(l=r.length>w?l+(r[w].we||n):l+n,w++,y=r.length>
262
+ w?r[w].sampleSize||p:p)}}).parse(a,!1);return c};function Uh(){this.h=new Th;this.g=new Jh}Uh.prototype.init=function(a){this.h.init(a)};
263
+ function Vh(a,b){var c=a.h.parse(b);c=t(c);for(var d=c.next();!d.done;d=c.next()){var e=d.value,f=Gc(e.Wg);if(0<f.length&&(d=a.g,e=e.pts,f=new xg(f,0),181===f.qb()&&49===f.re()&&1195456820===f.R()&&3===f.qb())){var g=f.qb();if(0!==(g&64)){g&=31;f.skip(1);for(var h=0;h<g;h++){var k=f.qb(),l=(k&4)>>2,m=f.qb(),n=f.qb();l&&(k&=3,0===k||1===k?d.h.push({pts:e,type:k,Oa:m,jb:n,order:d.h.length}):(d.g.push({pts:e,type:k,value:m,order:d.g.length}),d.g.push({pts:e,type:2,value:n,order:d.g.length})))}}}}return Lh(a.g)}
264
+ ;function Wh(a,b,c,d){this.Pa=a;this.Ta=b;this.Ca=c;this.je=void 0===d?null:d}Wh.prototype.Gc=function(){return this.Ta};Wh.prototype.Cc=function(){return this.Ca};function Xh(a,b){return a&&b?a.Gc()==b.Gc()&&a.Cc()==b.Cc()&&fc(a.Pa(),b.Pa()):a==b}J("shaka.media.InitSegmentReference",Wh);Wh.prototype.getEndByte=Wh.prototype.Cc;Wh.prototype.getStartByte=Wh.prototype.Gc;
265
+ function Yh(a,b,c,d,e,f,g,h,k,l,m,n,p,r){l=void 0===l?[]:l;r=void 0===r?Zh:r;this.startTime=a;this.j=this.endTime=b;this.m=c;this.Ta=d;this.Ca=e;this.i=f;this.timestampOffset=g;this.appendWindowStart=h;this.appendWindowEnd=k;this.h=l;this.tilesLayout=void 0===m?"":m;this.l=void 0===n?null:n;this.g=void 0===p?null:p;this.status=r}q=Yh.prototype;q.Pa=function(){return this.m()};q.getStartTime=function(){return this.startTime};q.og=function(){return this.endTime};q.Gc=function(){return this.Ta};
266
+ q.Cc=function(){return this.Ca};q.Hg=function(){return this.tilesLayout};q.Gg=function(){return this.l};q.nd=function(){return this.status};q.Qg=function(){this.status=$h};J("shaka.media.SegmentReference",Yh);Yh.prototype.markAsUnavailable=Yh.prototype.Qg;Yh.prototype.getStatus=Yh.prototype.nd;Yh.prototype.getTileDuration=Yh.prototype.Gg;Yh.prototype.getTilesLayout=Yh.prototype.Hg;Yh.prototype.getEndByte=Yh.prototype.Cc;Yh.prototype.getStartByte=Yh.prototype.Gc;Yh.prototype.getEndTime=Yh.prototype.og;
267
+ Yh.prototype.getStartTime=Yh.prototype.getStartTime;Yh.prototype.getUris=Yh.prototype.Pa;var Zh=0,$h=1;Yh.Status={Bh:Zh,Pi:$h,ai:2};function ai(a){return!a||1==a.length&&1E-6>a.end(0)-a.start(0)?null:1==a.length&&0>a.start(0)?0:a.length?a.start(0):null}function bi(a){return!a||1==a.length&&1E-6>a.end(0)-a.start(0)?null:a.length?a.end(a.length-1):null}function ci(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)}
268
+ function di(a,b){if(!a||!a.length||1==a.length&&1E-6>a.end(0)-a.start(0))return 0;for(var c=0,d=t(ei(a)),e=d.next();!e.done;e=d.next()){var f=e.value;e=f.start;f=f.end;f>b&&(c+=f-Math.max(e,b))}return c}function fi(a,b,c){if(!a||!a.length||1==a.length&&1E-6>a.end(0)-a.start(0))return null;a=ei(a).findIndex(function(d,e,f){return d.start>b&&(0==e||f[e-1].end-b<=c)});return 0<=a?a:null}function ei(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};function gi(a,b,c,d){var e=this;this.j=a;this.m=c;this.h={};this.N={};this.K={};this.g=null;this.H=!1;this.S=d||function(){};this.i={};this.A=new wf;this.C={};this.F=b;this.I=new Nc;this.l=hi(this,this.I);this.G=new uf(function(){return ii(e)});this.J="";this.B=!1;this.P=new Nc}function hi(a,b){var c=new MediaSource;a.A.Fa(c,"sourceopen",function(){URL.revokeObjectURL(a.J);b.resolve()});a.J=ji(c);a.j.src=a.J;return c}q=gi.prototype;q.destroy=function(){return this.G.destroy()};
269
+ function ii(a){var b,c,d,e,f,g,h,k;return I(function(l){if(1==l.g){b=[];for(c in a.i)for(d=a.i[c],e=d[0],a.i[c]=d.slice(0,1),e&&b.push(e.p["catch"](Bb)),f=t(d.slice(1)),g=f.next();!g.done;g=f.next())h=g.value,h.p.reject(new O(2,7,7003,void 0));a.g&&b.push(a.g.destroy());a.m&&b.push(a.m.destroy());for(k in a.C)b.push(a.C[k].destroy());return u(l,Promise.all(b),2)}a.A&&(a.A.release(),a.A=null);a.j&&(a.j.removeAttribute("src"),a.j.load(),a.j=null);a.l=null;a.g=null;a.m=null;a.h={};a.C={};a.F=null;a.i=
266
270
  {};z(l)})}
267
- q.init=function(a,b,c){c=void 0===c?!1:c;var d=this,e,f,g,h,k,l,m;return I(function(n){if(1==n.g)return e=Jb,u(n,d.I,2);d.B=c;f={};g=t(a.keys());for(h=g.next();!h.done;f={Ga:f.Ga},h=g.next())f.Ga=h.value,k=a.get(f.Ga),l=jd(k.mimeType,k.codecs),f.Ga==e.ha?ci(d,l,c):(!b&&MediaSource.isTypeSupported(l)||!ed(l,f.Ga)||(d.C[f.Ga]=new dd,l=gd(f.Ga,l)),m=d.l.addSourceBuffer(l),d.A.o(m,"error",function(p){return function(){d.i[p.Ga][0].p.reject(new O(2,3,3014,d.j.error?d.j.error.code:0))}}(f)),d.A.o(m,"updateend",
268
- function(p){return function(){return di(d,p.Ga)}}(f)),d.h[f.Ga]=m,d.N[f.Ga]=l,d.i[f.Ga]=[],d.K[f.Ga]=!!k.drmInfos.length);z(n)})};function ci(a,b,c){a.g||(a.g=new od(a.m));var d=a.g;a=a.H;"application/cea-608"!=b&&"application/cea-708"!=b&&(d.j=(0,qd[b])(),d.j.setSequenceMode?d.j.setSequenceMode(c):Ua('Text parsers should have a "setSequenceMode" method!'),d.C=a)}function ei(a){return a.l?"ended"==a.l.readyState:!0}function fi(a,b){return b==Ib?a.g.g:Th(gi(a,b))}
269
- function hi(a,b){return b==Ib?a.g.h:Uh(gi(a,b))}function ii(a,b,c){if(b==Ib)return a=a.g,null==a.h||a.h<c?0:a.h-Math.max(c,a.g);a=gi(a,b);return Wh(a,c)}q.kb=function(){var a={total:Xh(this.j.buffered),audio:Xh(gi(this,"audio")),video:Xh(gi(this,"video")),text:[]};if(this.g){var b=this.g.g,c=this.g.h;null!=b&&null!=c&&a.text.push({start:b,end:c})}return a};function gi(a,b){try{return a.h[b].buffered}catch(c){return null}}
270
- function ji(a,b,c,d,e,f,g){var h,k,l,m,n,p,r,x,y,w,v,D,C,B,G,E;return I(function(H){switch(H.g){case 1:h=Jb;if(b!=h.ha){H.D(2);break}if(!a.B){H.D(3);break}return u(H,a.P,4);case 4:k=H.h,a.g.B=k;case 3:return u(H,rd(a.g,c,d,e),5);case 5:return H["return"]();case 2:if(!a.C[b]){f&&(a.g||ci(a,"text/vtt",a.B),null==d&&null==e?a.F.init(c):(l=Sh(a.F,c),l.length&&(m=a.h[h.Ma].timestampOffset,wd(a.g,l,d,e,m))));H.D(6);break}return u(H,hd(a.C[b],c),7);case 7:n=H.h,a.g||ci(a,"text/vtt",a.B),n.metadata&&(p=a.h[b].timestampOffset,
271
- a.S(n.metadata,p,e)),n.captions&&n.captions.length&&(r=a.h[h.Ma].timestampOffset,x=ud(n.captions),wd(a.g,x,d,e,r)),c=n.data;case 6:c=ki(a,c,d,b);y=a.h[b];w=li;if(!a.B||y.mode==w||null==d){H.D(8);break}v=b==h.Ma||!(h.Ma in a.h);if(!v){H.D(9);break}D=[y.appendWindowStart,y.appendWindowEnd];y.appendWindowStart=0;y.appendWindowEnd=Infinity;C=y.timestampOffset;y.timestampOffset=0;return u(H,mi(a,b,function(){a.h[b].appendBuffer(c)}),10);case 10:return y.timestampOffset=C,y.appendWindowStart=D[0],y.appendWindowEnd=
272
- D[1],B=Th(gi(a,b)),G=(d||0)-(B||0),a.P.resolve(G),u(H,mi(a,b,function(){return ni(a,b,0,a.l.duration)}),9);case 9:y.mode=w;case 8:return null!=d&&a.B&&b!=h.ha&&g&&(E=d,mi(a,b,function(){var L=E;0>L&&(L+=.001);a.h[b].timestampOffset=L;di(a,b)})),u(H,mi(a,b,function(){a.h[b].appendBuffer(c)}),0)}})}function oi(a,b){var c=hi(a,"video")||0;td(a.g,b,c)}function pi(a){a.g&&td(a.g,"",0)}
273
- q.remove=function(a,b,c){var d=this,e;return I(function(f){e=Jb;return a==e.ha?u(f,d.g.remove(b,c),0):u(f,mi(d,a,function(){return ni(d,a,b,c)}),0)})};function qi(a,b){var c;return I(function(d){c=Jb;return b==c.ha?a.g?u(d,a.g.remove(0,Infinity),0):d["return"]():u(d,mi(a,b,function(){return ni(a,b,0,a.l.duration)}),0)})}q.flush=function(a){var b=this,c;return I(function(d){c=Jb;return a==c.ha?d["return"]():u(d,mi(b,a,function(){b.j.currentTime-=.001;di(b,a)}),0)})};
274
- function ri(a,b,c,d,e,f){var g;return I(function(h){g=Jb;return b==g.ha?(f||(a.g.B=c),sd(a.g,d,e),h["return"]()):u(h,Promise.all([mi(a,b,function(){var k=a.h[b].appendWindowStart,l=a.h[b].appendWindowEnd;a.h[b].abort();a.h[b].appendWindowStart=k;a.h[b].appendWindowEnd=l;di(a,b)}),f?Promise.resolve():mi(a,b,function(){var k=c;0>k&&(k+=.001);a.h[b].timestampOffset=k;di(a,b)}),mi(a,b,function(){a.h[b].appendWindowStart=0;a.h[b].appendWindowEnd=e;a.h[b].appendWindowStart=d;di(a,b)})]),0)})}
275
- q.endOfStream=function(a){var b=this;return I(function(c){return u(c,si(b,function(){ei(b)||(a?b.l.endOfStream(a):b.l.endOfStream())}),0)})};q.bb=function(a){var b=this;return I(function(c){return u(c,si(b,function(){b.l.duration=a}),0)})};q.getDuration=function(){return this.l.duration};function ni(a,b,c,d){d<=c?di(a,b):a.h[b].remove(c,d)}function di(a,b){var c=a.i[b][0];c&&(c.p.resolve(),ti(a,b))}
276
- function mi(a,b,c){sf(a.G);c={start:c,p:new Nc};a.i[b].push(c);1==a.i[b].length&&ui(a,b);return c.p}
277
- function si(a,b){var c,d,e,f,g,h;return I(function(k){switch(k.g){case 1:sf(a.G);c=[];d={};for(e in a.h)d.vc=new Nc,f={start:function(l){return function(){return l.vc.resolve()}}(d),p:d.vc},a.i[e].push(f),c.push(d.vc),1==a.i[e].length&&f.start(),d={vc:d.vc};A(k,2);return u(k,Promise.all(c),4);case 4:va(k,3);break;case 2:throw g=F(k),g;case 3:try{b()}catch(l){throw new O(2,3,3015,l);}finally{for(h in a.h)ti(a,h)}z(k)}})}function ti(a,b){a.i[b].shift();ui(a,b)}
278
- function ui(a,b){var c=a.i[b][0];if(c)try{c.start()}catch(d){"QuotaExceededError"==d.name?c.p.reject(new O(2,3,3017,b)):c.p.reject(new O(2,3,3015,d)),ti(a,b)}}function ki(a,b,c,d){var e=a.K[d];null==c&&e&&(Gd()||Bd())&&"mp4"==a.N[d].split(";")[0].split("/")[1]&&(b=Gg(b));return b}var bi=window.URL.createObjectURL,li="sequence",vi=["audio/aac","audio/ac3","audio/ec3","audio/mpeg"];function wi(a,b,c,d){this.Pa=a;this.Ta=b;this.Ca=c;this.ie=void 0===d?null:d}wi.prototype.Gc=function(){return this.Ta};wi.prototype.Cc=function(){return this.Ca};function xi(a,b){return a&&b?a.Gc()==b.Gc()&&a.Cc()==b.Cc()&&fc(a.Pa(),b.Pa()):a==b}J("shaka.media.InitSegmentReference",wi);wi.prototype.getEndByte=wi.prototype.Cc;wi.prototype.getStartByte=wi.prototype.Gc;
279
- function yi(a,b,c,d,e,f,g,h,k,l,m,n,p,r){l=void 0===l?[]:l;r=void 0===r?zi:r;this.startTime=a;this.j=this.endTime=b;this.m=c;this.Ta=d;this.Ca=e;this.i=f;this.timestampOffset=g;this.appendWindowStart=h;this.appendWindowEnd=k;this.h=l;this.tilesLayout=void 0===m?"":m;this.l=void 0===n?null:n;this.g=void 0===p?null:p;this.status=r}q=yi.prototype;q.Pa=function(){return this.m()};q.getStartTime=function(){return this.startTime};q.ng=function(){return this.endTime};q.Gc=function(){return this.Ta};
280
- q.Cc=function(){return this.Ca};q.Gg=function(){return this.tilesLayout};q.Fg=function(){return this.l};q.nd=function(){return this.status};q.Pg=function(){this.status=Ai};J("shaka.media.SegmentReference",yi);yi.prototype.markAsUnavailable=yi.prototype.Pg;yi.prototype.getStatus=yi.prototype.nd;yi.prototype.getTileDuration=yi.prototype.Fg;yi.prototype.getTilesLayout=yi.prototype.Gg;yi.prototype.getEndByte=yi.prototype.Cc;yi.prototype.getStartByte=yi.prototype.Gc;yi.prototype.getEndTime=yi.prototype.ng;
281
- yi.prototype.getStartTime=yi.prototype.getStartTime;yi.prototype.getUris=yi.prototype.Pa;var zi=0,Ai=1;yi.Status={Ah:zi,Oi:Ai,$h:2};function Q(a,b,c){this.l=a;this.zd=b;this.m=this.i=Infinity;this.g=1;this.h=this.j=null;this.A=0;this.B=!0;this.C=0;this.F=void 0===c?!0:c;this.G=0}q=Q.prototype;q.getDuration=function(){return this.i};q.wg=function(){return this.g};q.bb=function(a){this.i=a};q.Ag=function(){return this.l};q.Ff=function(a){this.A=a};q.Uc=function(a){this.B=a};q.Ge=function(a){this.m=a};q.mh=function(a){this.zd=a};q.mg=function(){return this.zd};
282
- q.ic=function(a){if(0!=a.length){var b=a[a.length-1].endTime;this.le(a[0].startTime);this.g=a.reduce(function(c,d){return Math.max(c,d.endTime-d.startTime)},this.g);this.h=Math.max(this.h,b);null!=this.l&&this.F&&(this.l=(Date.now()+this.A)/1E3-this.h-this.g)}};q.le=function(a){this.j=null==this.j?a:Math.min(this.j,a)};q.ke=function(a){this.g=Math.max(this.g,a)};q.offset=function(a){null!=this.j&&(this.j+=a);null!=this.h&&(this.h+=a)};q.U=function(){return Infinity==this.i&&!this.B};
283
- q.Lb=function(){return Infinity!=this.i&&!this.B};q.ob=function(){return Math.max(this.C,this.Ib()-this.m)};q.If=function(a){this.C=a};q.Ib=function(){return this.U()||this.Lb()?Math.min(Math.max(0,(Date.now()+this.A)/1E3-this.g-this.l)+this.G,this.i):this.h?Math.min(this.h,this.i):this.i};q.Fc=function(a){var b=Math.max(this.j,this.C);return Infinity==this.m?Math.ceil(1E3*b)/1E3:Math.max(b,Math.min(this.Ib()-this.m+a,this.mb()))};q.cc=function(){return this.Fc(0)};
284
- q.mb=function(){return Math.max(0,this.Ib()-(this.U()||this.Lb()?this.zd:0))};q.Mf=function(){return null==this.l||null!=this.h&&this.F?!1:!0};q.Ef=function(a){this.G=a};J("shaka.media.PresentationTimeline",Q);Q.prototype.setAvailabilityTimeOffset=Q.prototype.Ef;Q.prototype.usingPresentationStartTime=Q.prototype.Mf;Q.prototype.getSeekRangeEnd=Q.prototype.mb;Q.prototype.getSeekRangeStart=Q.prototype.cc;Q.prototype.getSafeSeekRangeStart=Q.prototype.Fc;Q.prototype.getSegmentAvailabilityEnd=Q.prototype.Ib;
285
- Q.prototype.setUserSeekStart=Q.prototype.If;Q.prototype.getSegmentAvailabilityStart=Q.prototype.ob;Q.prototype.isInProgress=Q.prototype.Lb;Q.prototype.isLive=Q.prototype.U;Q.prototype.offset=Q.prototype.offset;Q.prototype.notifyMaxSegmentDuration=Q.prototype.ke;Q.prototype.notifyMinSegmentStartTime=Q.prototype.le;Q.prototype.notifySegments=Q.prototype.ic;Q.prototype.getDelay=Q.prototype.mg;Q.prototype.setDelay=Q.prototype.mh;Q.prototype.setSegmentAvailabilityDuration=Q.prototype.Ge;
286
- Q.prototype.setStatic=Q.prototype.Uc;Q.prototype.setClockOffset=Q.prototype.Ff;Q.prototype.getPresentationStartTime=Q.prototype.Ag;Q.prototype.setDuration=Q.prototype.bb;Q.prototype.getMaxSegmentDuration=Q.prototype.wg;Q.prototype.getDuration=Q.prototype.getDuration;function Bi(a,b,c){this.l=c;this.j=a;this.B=Ci(a);this.g=a.g.currentTime;this.m=Date.now()/1E3;this.h=!1;this.A=0;this.C=b;this.i=function(){}}Bi.prototype.release=function(){this.l=this.j=null;this.i=function(){}};function Di(a,b){a.i=b}function Ei(a){this.g=a}function Ci(a){if(a.g.paused||0==a.g.playbackRate||0==a.g.buffered.length)var b=!1;else a:{b=a.g.currentTime;a=t(Xh(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 Fi(a,b,c,d,e){var f=this;this.A=e;this.g=a;this.B=b;this.G=c;this.i=new tf;this.m=!1;this.F=a.readyState;this.C=0;this.h=d;this.l=!1;this.i.o(a,"waiting",function(){return Gi(f)});this.j=(new P(function(){Gi(f)})).ka(.25)}Fi.prototype.release=function(){this.i&&(this.i.release(),this.i=null);null!=this.j&&(this.j.stop(),this.j=null);this.h&&(this.h.release(),this.h=null);this.g=this.B=this.A=null};Fi.prototype.oe=function(){this.l=!0;Gi(this)};
287
- function Gi(a){if(0!=a.g.readyState){if(a.g.seeking){if(!a.m)return}else a.m=!1;if(!a.g.paused||0==a.g.currentTime&&(a.g.autoplay||0!=a.g.currentTime)){a.g.readyState!=a.F&&(a.F=a.g.readyState);var b;if(!(b=!a.h)){b=a.h;var c=b.j,d=Ci(c),e=c.g.currentTime,f=Date.now()/1E3;if(b.g!=e||b.B!=d)b.m=f,b.g=e,b.B=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.A++,b.l(new M("stalldetected"));b=!d}b&&(b=a.g.currentTime,c=a.g.buffered,d=Yh(c,b,a.G.gapDetectionThreshold),null==
288
- d||0==d&&!a.l||(e=c.start(d),e>=a.B.mb()||.001>e-b||(0!=d&&c.end(d-1),a.g.currentTime=e,a.C++,a.A(new M("gapjumped")))))}}};function Hi(a,b,c,d){b==HTMLMediaElement.HAVE_NOTHING||a.readyState>=b?d():(b=Ii.value().get(b),c.Fa(a,b,d))}var Ii=new Oc(function(){return new Map([[HTMLMediaElement.HAVE_METADATA,"loadedmetadata"],[HTMLMediaElement.HAVE_CURRENT_DATA,"loadeddata"],[HTMLMediaElement.HAVE_FUTURE_DATA,"canplay"],[HTMLMediaElement.HAVE_ENOUGH_DATA,"canplaythrough"]])});function Ji(a,b,c){var d=this;this.g=a;this.l=b;this.j=c;this.m=!1;this.h=new tf;this.i=new Ki(a);Hi(this.g,HTMLMediaElement.HAVE_METADATA,this.h,function(){Li(d,d.j)})}Ji.prototype.release=function(){this.h&&(this.h.release(),this.h=null);null!=this.i&&(this.i.release(),this.i=null);this.l=function(){};this.g=null};function Mi(a){return a.m?a.g.currentTime:a.j}function Ni(a,b){0<a.g.readyState?Oi(a.i,b):Hi(a.g,HTMLMediaElement.HAVE_METADATA,a.h,function(){Li(a,a.j)})}
289
- function Li(a,b){.001>Math.abs(a.g.currentTime-b)?Pi(a):(a.h.Fa(a.g,"seeking",function(){Pi(a)}),Oi(a.i,0==a.g.currentTime?b:a.g.currentTime))}function Pi(a){a.m=!0;a.h.o(a.g,"seeking",function(){return a.l()})}function Ki(a){var b=this;this.h=a;this.m=10;this.l=this.j=this.i=0;this.g=new P(function(){0>=b.i?b.g.stop():b.h.currentTime!=b.j?b.g.stop():(b.h.currentTime=b.l,b.i--)})}Ki.prototype.release=function(){this.g&&(this.g.stop(),this.g=null);this.h=null};
290
- function Oi(a,b){a.j=a.h.currentTime;a.l=b;a.i=a.m;a.h.currentTime=b;a.g.ka(.1)};function Qi(a){function b(){null==c.h||0==c.h?c.j=!0:(c.i.Fa(c.g,"seeking",function(){c.j=!0}),c.g.currentTime=Math.max(0,c.g.currentTime+c.h))}var c=this;this.g=a;this.j=!1;this.h=null;this.i=new tf;Hi(this.g,HTMLMediaElement.HAVE_CURRENT_DATA,this.i,function(){b()})}q=Qi.prototype;q.release=function(){this.i&&(this.i.release(),this.i=null);this.g=null};q.Yd=function(a){this.h=this.j?this.h:a};q.bd=function(){return(this.j?this.g.currentTime:this.h)||0};q.Ve=function(){return 0};q.Ue=function(){return 0};
291
- q.zf=function(){};
292
- function Ri(a,b,c,d,e,f){var g=this;this.i=a;this.g=b.presentationTimeline;this.F=b.minBufferTime||0;this.l=c;this.B=e;this.A=null;this.C=Si(a,c,f);this.j=new Fi(a,b.presentationTimeline,c,this.C,f);this.h=new Ji(a,function(){a:{var h=g.j;h.m=!0;h.l=!1;var k=Mi(g.h);h=Ti(g,k);if(.001<Math.abs(h-k)&&(k=Date.now()/1E3,!g.A||g.A<k-1)){g.A=k;Ni(g.h,h);h=void 0;break a}g.B();h=void 0}return h},Ui(this,d));this.m=(new P(function(){if(0!=g.i.readyState&&!g.i.paused){var h=Mi(g.h),k=g.g.cc(),l=g.g.mb();3>
293
- l-k&&(k=l-3);h<k&&(h=Ti(g,h),g.i.currentTime=h)}})).ka(.25)}q=Ri.prototype;q.release=function(){this.h&&(this.h.release(),this.h=null);this.j&&(this.j.release(),this.j=null);this.m&&(this.m.stop(),this.m=null);this.i=this.h=this.g=this.l=null;this.B=function(){}};q.Yd=function(a){Ni(this.h,a)};q.bd=function(){var a=Mi(this.h);return 0<this.i.readyState&&!this.i.paused?Vi(this,a):a};q.Ve=function(){return this.C.A};q.Ue=function(){return this.j.C};
294
- function Ui(a,b){null==b?b=Infinity>a.g.getDuration()?a.g.cc():a.g.mb():0>b&&(b=a.g.mb()+b);return Wi(a,Vi(a,b))}q.zf=function(){this.j.oe()};function Wi(a,b){var c=a.g.getDuration();return b>=c?c-a.l.durationBackoff:b}function Ti(a,b){var c=Math.max(a.F,a.l.rebufferingGoal),d=a.l.safeSeekOffset,e=a.g.cc(),f=a.g.mb(),g=a.g.getDuration();3>f-e&&(e=f-3);var h=a.g.Fc(c),k=a.g.Fc(d);c=a.g.Fc(c+d);return b>=g?Wi(a,b):b>f?f:b<e?Vh(a.i.buffered,k)?k:c:b>=h||Vh(a.i.buffered,b)?b:c}
295
- function Vi(a,b){var c=a.g.cc();if(b<c)return c;c=a.g.mb();return b>c?c:b}function Si(a,b,c){if(!b.stallEnabled)return null;var d=b.stallSkip;b=new Bi(new Ei(a),b.stallThreshold,c);Di(b,function(){d?a.currentTime+=d:(a.pause(),a.play())});return b};function Xi(a){this.M=a;this.g=null;this.h=0;this.i=!1}q=Xi.prototype;q.release=function(){this.i||(this.M=[],this.g&&this.g.stop(),this.g=null)};q.Qg=function(){this.i=!0};q.find=function(a){for(var b=this.M.length-1,c=b;0<=c;--c){var d=this.M[c],e=c<b?this.M[c+1].startTime:d.endTime;if(a>=d.startTime&&a<e)return c+this.h}return this.M.length&&a<this.M[0].startTime?this.h:null};q.get=function(a){if(0==this.M.length)return null;a-=this.h;return 0>a||a>=this.M.length?null:this.M[a]};
271
+ q.init=function(a,b,c){c=void 0===c?!1:c;var d=this,e,f,g,h,k,l,m;return I(function(n){if(1==n.g)return e=Jb,u(n,d.I,2);d.B=c;f={};g=t(a.keys());for(h=g.next();!h.done;f={Ga:f.Ga},h=g.next())f.Ga=h.value,k=a.get(f.Ga),l=yd(k.mimeType,k.codecs),f.Ga==e.ha?ki(d,l,c):(!b&&MediaSource.isTypeSupported(l)||!td(l,f.Ga)||(d.C[f.Ga]=new sd,l=vd(f.Ga,l)),m=d.l.addSourceBuffer(l),d.A.o(m,"error",function(p){return function(){d.i[p.Ga][0].p.reject(new O(2,3,3014,d.j.error?d.j.error.code:0))}}(f)),d.A.o(m,"updateend",
272
+ function(p){return function(){return li(d,p.Ga)}}(f)),d.h[f.Ga]=m,d.N[f.Ga]=l,d.i[f.Ga]=[],d.K[f.Ga]=!!k.drmInfos.length);z(n)})};function ki(a,b,c){a.g||(a.g=new Gd(a.m));var d=a.g;a=a.H;"application/cea-608"!=b&&"application/cea-708"!=b&&(d.j=(0,Id[b])(),d.j.setSequenceMode?d.j.setSequenceMode(c):Ua('Text parsers should have a "setSequenceMode" method!'),d.C=a)}function mi(a){return a.l?"ended"==a.l.readyState:!0}function ni(a,b){return b==Ib?a.g.g:ai(oi(a,b))}
273
+ function pi(a,b){return b==Ib?a.g.h:bi(oi(a,b))}function qi(a,b,c){if(b==Ib)return a=a.g,null==a.h||a.h<c?0:a.h-Math.max(c,a.g);a=oi(a,b);return di(a,c)}q.kb=function(){var a={total:ei(this.j.buffered),audio:ei(oi(this,"audio")),video:ei(oi(this,"video")),text:[]};if(this.g){var b=this.g.g,c=this.g.h;null!=b&&null!=c&&a.text.push({start:b,end:c})}return a};function oi(a,b){try{return a.h[b].buffered}catch(c){return null}}
274
+ function ri(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,w,y,x,v,D,C,B,G;return I(function(E){switch(E.g){case 1:g=Jb;if(b!=g.ha){E.D(2);break}if(!a.B){E.D(3);break}return u(E,a.P,4);case 4:h=E.h,a.g.B=h;case 3:return u(E,Jd(a.g,c,d?d.startTime:null,d?d.endTime:null),5);case 5:return E["return"]();case 2:if(!a.C[b]){e&&(a.g||ki(a,"text/vtt",a.B),d?(k=Vh(a.F,c),k.length&&(l=a.h[g.Ma].timestampOffset,Od(a.g,k,d.startTime,d.endTime,l))):a.F.init(c));E.D(6);break}return u(E,wd(a.C[b],c),7);case 7:m=E.h,a.g||ki(a,
275
+ "text/vtt",a.B),m.metadata&&(n=a.h[b].timestampOffset,a.S(m.metadata,n,d?d.endTime:null)),m.captions&&m.captions.length&&(p=a.h[g.Ma].timestampOffset,r=Md(m.captions),Od(a.g,r,d?d.startTime:null,d?d.endTime:null,p)),c=m.data;case 6:c=si(a,c,d?d.startTime:null,b);w=a.h[b];y=ti;if(!a.B||w.mode==y||!d){E.D(8);break}x=b==g.Ma||!(g.Ma in a.h);if(!x){E.D(9);break}v=[w.appendWindowStart,w.appendWindowEnd];w.appendWindowStart=0;w.appendWindowEnd=Infinity;D=w.timestampOffset;w.timestampOffset=0;return u(E,
276
+ ui(a,b,function(){a.h[b].appendBuffer(c)}),10);case 10:return w.timestampOffset=D,w.appendWindowStart=v[0],w.appendWindowEnd=v[1],C=ai(oi(a,b)),B=(d.startTime||0)-(C||0),a.P.resolve(B),u(E,ui(a,b,function(){return vi(a,b,0,a.l.duration)}),9);case 9:w.mode=y;case 8:return d&&a.B&&b!=g.ha&&f&&(G=d.startTime,ui(a,b,function(){var H=G;0>H&&(H+=.001);a.h[b].timestampOffset=H;li(a,b)})),u(E,ui(a,b,function(){a.h[b].appendBuffer(c)}),12);case 12:z(E)}})}
277
+ function wi(a,b){var c=pi(a,"video")||0;Ld(a.g,b,c)}function xi(a){a.g&&Ld(a.g,"",0)}q.remove=function(a,b,c){var d=this,e;return I(function(f){e=Jb;return a==e.ha?u(f,d.g.remove(b,c),0):u(f,ui(d,a,function(){return vi(d,a,b,c)}),0)})};function yi(a,b){var c;return I(function(d){c=Jb;return b==c.ha?a.g?u(d,a.g.remove(0,Infinity),0):d["return"]():u(d,ui(a,b,function(){return vi(a,b,0,a.l.duration)}),0)})}
278
+ q.flush=function(a){var b=this,c;return I(function(d){c=Jb;return a==c.ha?d["return"]():u(d,ui(b,a,function(){b.j.currentTime-=.001;li(b,a)}),0)})};
279
+ function zi(a,b,c,d,e,f){var g;return I(function(h){g=Jb;return b==g.ha?(f||(a.g.B=c),Kd(a.g,d,e),h["return"]()):u(h,Promise.all([ui(a,b,function(){var k=a.h[b].appendWindowStart,l=a.h[b].appendWindowEnd;a.h[b].abort();a.h[b].appendWindowStart=k;a.h[b].appendWindowEnd=l;li(a,b)}),f?Promise.resolve():ui(a,b,function(){var k=c;0>k&&(k+=.001);a.h[b].timestampOffset=k;li(a,b)}),ui(a,b,function(){a.h[b].appendWindowStart=0;a.h[b].appendWindowEnd=e;a.h[b].appendWindowStart=d;li(a,b)})]),0)})}
280
+ q.endOfStream=function(a){var b=this;return I(function(c){return u(c,Ai(b,function(){mi(b)||(a?b.l.endOfStream(a):b.l.endOfStream())}),0)})};q.bb=function(a){var b=this;return I(function(c){return u(c,Ai(b,function(){b.l.duration=a}),0)})};q.getDuration=function(){return this.l.duration};function vi(a,b,c,d){d<=c?li(a,b):a.h[b].remove(c,d)}function li(a,b){var c=a.i[b][0];c&&(c.p.resolve(),Bi(a,b))}
281
+ function ui(a,b,c){vf(a.G);c={start:c,p:new Nc};a.i[b].push(c);1==a.i[b].length&&Ci(a,b);return c.p}
282
+ function Ai(a,b){var c,d,e,f,g,h;return I(function(k){switch(k.g){case 1:vf(a.G);c=[];d={};for(e in a.h)d.vc=new Nc,f={start:function(l){return function(){return l.vc.resolve()}}(d),p:d.vc},a.i[e].push(f),c.push(d.vc),1==a.i[e].length&&f.start(),d={vc:d.vc};A(k,2);return u(k,Promise.all(c),4);case 4:va(k,3);break;case 2:throw g=F(k),g;case 3:try{b()}catch(l){throw new O(2,3,3015,l);}finally{for(h in a.h)Bi(a,h)}z(k)}})}function Bi(a,b){a.i[b].shift();Ci(a,b)}
283
+ function Ci(a,b){var c=a.i[b][0];if(c)try{c.start()}catch(d){"QuotaExceededError"==d.name?c.p.reject(new O(2,3,3017,b)):c.p.reject(new O(2,3,3015,d)),Bi(a,b)}}function si(a,b,c,d){var e=a.K[d];null==c&&e&&(Wc()||Uc())&&"mp4"==a.N[d].split(";")[0].split("/")[1]&&(b=Jg(b));return b}var ji=window.URL.createObjectURL,ti="sequence",Di=["audio/aac","audio/ac3","audio/ec3","audio/mpeg"];function Q(a,b,c){this.l=a;this.zd=b;this.m=this.i=Infinity;this.g=1;this.h=this.j=null;this.A=0;this.B=!0;this.C=0;this.F=void 0===c?!0:c;this.G=0;this.H=!1}q=Q.prototype;q.getDuration=function(){return this.i};q.xg=function(){return this.g};q.bb=function(a){this.i=a};q.Bg=function(){return this.l};q.Gf=function(a){this.A=a};q.Uc=function(a){this.B=a};q.He=function(a){this.m=a};q.nh=function(a){this.zd=a};q.ng=function(){return this.zd};
284
+ q.ic=function(a){if(0!=a.length){var b=a[a.length-1].endTime;this.me(a[0].startTime);this.g=a.reduce(function(c,d){return Math.max(c,d.endTime-d.startTime)},this.g);this.h=Math.max(this.h,b);null!=this.l&&this.F&&!this.H&&(this.l=(Date.now()+this.A)/1E3-this.h-this.g)}};q.ge=function(){this.H=!0};q.me=function(a){this.j=null==this.j?a:Math.min(this.j,a)};q.le=function(a){this.g=Math.max(this.g,a)};q.offset=function(a){null!=this.j&&(this.j+=a);null!=this.h&&(this.h+=a)};
285
+ q.U=function(){return Infinity==this.i&&!this.B};q.Lb=function(){return Infinity!=this.i&&!this.B};q.ob=function(){return Math.max(this.C,this.Ib()-this.m)};q.Jf=function(a){this.C=a};q.Ib=function(){return this.U()||this.Lb()?Math.min(Math.max(0,(Date.now()+this.A)/1E3-this.g-this.l)+this.G,this.i):this.h?Math.min(this.h,this.i):this.i};q.Fc=function(a){var b=Math.max(this.j,this.C);return Infinity==this.m?Math.ceil(1E3*b)/1E3:Math.max(b,Math.min(this.Ib()-this.m+a,this.mb()))};q.cc=function(){return this.Fc(0)};
286
+ q.mb=function(){return Math.max(0,this.Ib()-(this.U()||this.Lb()?this.zd:0))};q.Nf=function(){return null==this.l||null!=this.h&&this.F?!1:!0};q.Ff=function(a){this.G=a};J("shaka.media.PresentationTimeline",Q);Q.prototype.setAvailabilityTimeOffset=Q.prototype.Ff;Q.prototype.usingPresentationStartTime=Q.prototype.Nf;Q.prototype.getSeekRangeEnd=Q.prototype.mb;Q.prototype.getSeekRangeStart=Q.prototype.cc;Q.prototype.getSafeSeekRangeStart=Q.prototype.Fc;Q.prototype.getSegmentAvailabilityEnd=Q.prototype.Ib;
287
+ Q.prototype.setUserSeekStart=Q.prototype.Jf;Q.prototype.getSegmentAvailabilityStart=Q.prototype.ob;Q.prototype.isInProgress=Q.prototype.Lb;Q.prototype.isLive=Q.prototype.U;Q.prototype.offset=Q.prototype.offset;Q.prototype.notifyMaxSegmentDuration=Q.prototype.le;Q.prototype.notifyMinSegmentStartTime=Q.prototype.me;Q.prototype.lockStartTime=Q.prototype.ge;Q.prototype.notifySegments=Q.prototype.ic;Q.prototype.getDelay=Q.prototype.ng;Q.prototype.setDelay=Q.prototype.nh;
288
+ Q.prototype.setSegmentAvailabilityDuration=Q.prototype.He;Q.prototype.setStatic=Q.prototype.Uc;Q.prototype.setClockOffset=Q.prototype.Gf;Q.prototype.getPresentationStartTime=Q.prototype.Bg;Q.prototype.setDuration=Q.prototype.bb;Q.prototype.getMaxSegmentDuration=Q.prototype.xg;Q.prototype.getDuration=Q.prototype.getDuration;function Ei(a,b,c){this.l=c;this.j=a;this.B=Fi(a);this.g=a.g.currentTime;this.m=Date.now()/1E3;this.h=!1;this.A=0;this.C=b;this.i=function(){}}Ei.prototype.release=function(){this.l=this.j=null;this.i=function(){}};function Gi(a,b){a.i=b}function Hi(a){this.g=a}function Fi(a){if(a.g.paused||0==a.g.playbackRate||0==a.g.buffered.length)var b=!1;else a:{b=a.g.currentTime;a=t(ei(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 Ii(a,b,c,d,e){var f=this;this.A=e;this.g=a;this.B=b;this.G=c;this.i=new wf;this.m=!1;this.F=a.readyState;this.C=0;this.h=d;this.l=!1;this.i.o(a,"waiting",function(){return Ji(f)});this.j=(new P(function(){Ji(f)})).ka(.25)}Ii.prototype.release=function(){this.i&&(this.i.release(),this.i=null);null!=this.j&&(this.j.stop(),this.j=null);this.h&&(this.h.release(),this.h=null);this.g=this.B=this.A=null};Ii.prototype.pe=function(){this.l=!0;Ji(this)};
289
+ function Ji(a){if(0!=a.g.readyState){if(a.g.seeking){if(!a.m)return}else a.m=!1;if(!a.g.paused||0==a.g.currentTime&&(a.g.autoplay||0!=a.g.currentTime)){a.g.readyState!=a.F&&(a.F=a.g.readyState);var b;if(!(b=!a.h)){b=a.h;var c=b.j,d=Fi(c),e=c.g.currentTime,f=Date.now()/1E3;if(b.g!=e||b.B!=d)b.m=f,b.g=e,b.B=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.A++,b.l(new L("stalldetected"));b=!d}b&&(b=a.g.currentTime,c=a.g.buffered,d=fi(c,b,a.G.gapDetectionThreshold),null==
290
+ d||0==d&&!a.l||(e=c.start(d),e>=a.B.mb()||.001>e-b||(0!=d&&c.end(d-1),a.g.currentTime=e,a.C++,a.A(new L("gapjumped")))))}}};function Ki(a,b,c,d){b==HTMLMediaElement.HAVE_NOTHING||a.readyState>=b?d():(b=Li.value().get(b),c.Fa(a,b,d))}var Li=new Oc(function(){return new Map([[HTMLMediaElement.HAVE_METADATA,"loadedmetadata"],[HTMLMediaElement.HAVE_CURRENT_DATA,"loadeddata"],[HTMLMediaElement.HAVE_FUTURE_DATA,"canplay"],[HTMLMediaElement.HAVE_ENOUGH_DATA,"canplaythrough"]])});function Mi(a,b,c){var d=this;this.g=a;this.l=b;this.j=c;this.m=!1;this.h=new wf;this.i=new Ni(a);Ki(this.g,HTMLMediaElement.HAVE_METADATA,this.h,function(){Oi(d,d.j)})}Mi.prototype.release=function(){this.h&&(this.h.release(),this.h=null);null!=this.i&&(this.i.release(),this.i=null);this.l=function(){};this.g=null};function Pi(a){return a.m?a.g.currentTime:a.j}function Qi(a,b){0<a.g.readyState?Ri(a.i,b):Ki(a.g,HTMLMediaElement.HAVE_METADATA,a.h,function(){Oi(a,a.j)})}
291
+ function Oi(a,b){.001>Math.abs(a.g.currentTime-b)?Si(a):(a.h.Fa(a.g,"seeking",function(){Si(a)}),Ri(a.i,0==a.g.currentTime?b:a.g.currentTime))}function Si(a){a.m=!0;a.h.o(a.g,"seeking",function(){return a.l()})}function Ni(a){var b=this;this.h=a;this.m=10;this.l=this.j=this.i=0;this.g=new P(function(){0>=b.i?b.g.stop():b.h.currentTime!=b.j?b.g.stop():(b.h.currentTime=b.l,b.i--)})}Ni.prototype.release=function(){this.g&&(this.g.stop(),this.g=null);this.h=null};
292
+ function Ri(a,b){a.j=a.h.currentTime;a.l=b;a.i=a.m;a.h.currentTime=b;a.g.ka(.1)};function Ti(a){function b(){null==c.h||0==c.h?c.j=!0:(c.i.Fa(c.g,"seeking",function(){c.j=!0}),c.g.currentTime=Math.max(0,c.g.currentTime+c.h))}var c=this;this.g=a;this.j=!1;this.h=null;this.i=new wf;Ki(this.g,HTMLMediaElement.HAVE_CURRENT_DATA,this.i,function(){b()})}q=Ti.prototype;q.release=function(){this.i&&(this.i.release(),this.i=null);this.g=null};q.Yd=function(a){this.h=this.j?this.h:a};q.bd=function(){return(this.j?this.g.currentTime:this.h)||0};q.We=function(){return 0};q.Ve=function(){return 0};
293
+ q.Af=function(){};
294
+ function Ui(a,b,c,d,e,f){var g=this;this.i=a;this.g=b.presentationTimeline;this.F=b.minBufferTime||0;this.l=c;this.B=e;this.A=null;this.C=Vi(a,c,f);this.j=new Ii(a,b.presentationTimeline,c,this.C,f);this.h=new Mi(a,function(){a:{var h=g.j;h.m=!0;h.l=!1;var k=Pi(g.h);h=Wi(g,k);if(.001<Math.abs(h-k)&&(k=Date.now()/1E3,!g.A||g.A<k-1)){g.A=k;Qi(g.h,h);h=void 0;break a}g.B();h=void 0}return h},Xi(this,d));this.m=(new P(function(){if(0!=g.i.readyState&&!g.i.paused){var h=Pi(g.h),k=g.g.cc(),l=g.g.mb();3>
295
+ l-k&&(k=l-3);h<k&&(h=Wi(g,h),g.i.currentTime=h)}})).ka(.25)}q=Ui.prototype;q.release=function(){this.h&&(this.h.release(),this.h=null);this.j&&(this.j.release(),this.j=null);this.m&&(this.m.stop(),this.m=null);this.i=this.h=this.g=this.l=null;this.B=function(){}};q.Yd=function(a){Qi(this.h,a)};q.bd=function(){var a=Pi(this.h);return 0<this.i.readyState&&!this.i.paused?Yi(this,a):a};q.We=function(){return this.C.A};q.Ve=function(){return this.j.C};
296
+ function Xi(a,b){null==b?b=Infinity>a.g.getDuration()?a.g.cc():a.g.mb():0>b&&(b=a.g.mb()+b);return Zi(a,Yi(a,b))}q.Af=function(){this.j.pe()};function Zi(a,b){var c=a.g.getDuration();return b>=c?c-a.l.durationBackoff:b}function Wi(a,b){var c=Math.max(a.F,a.l.rebufferingGoal),d=a.l.safeSeekOffset,e=a.g.cc(),f=a.g.mb(),g=a.g.getDuration();3>f-e&&(e=f-3);var h=a.g.Fc(c),k=a.g.Fc(d);c=a.g.Fc(c+d);return b>=g?Zi(a,b):b>f?f:b<e?ci(a.i.buffered,k)?k:c:b>=h||ci(a.i.buffered,b)?b:c}
297
+ function Yi(a,b){var c=a.g.cc();if(b<c)return c;c=a.g.mb();return b>c?c:b}function Vi(a,b,c){if(!b.stallEnabled)return null;var d=b.stallSkip;b=new Ei(new Hi(a),b.stallThreshold,c);Gi(b,function(){d?a.currentTime+=d:(a.pause(),a.play())});return b};function $i(a){this.M=a;this.g=null;this.h=0;this.i=!1}q=$i.prototype;q.release=function(){this.i||(this.M=[],this.g&&this.g.stop(),this.g=null)};q.Rg=function(){this.i=!0};q.find=function(a){for(var b=this.M.length-1,c=b;0<=c;--c){var d=this.M[c],e=c<b?this.M[c+1].startTime:d.endTime;if(a>=d.startTime&&a<e)return c+this.h}return this.M.length&&a<this.M[0].startTime?this.h:null};q.get=function(a){if(0==this.M.length)return null;a-=this.h;return 0>a||a>=this.M.length?null:this.M[a]};
296
298
  q.offset=function(a){if(!this.i)for(var b=t(this.M),c=b.next();!c.done;c=b.next()){c=c.value;c.startTime+=a;c.endTime+=a;c.j+=a;c=t(c.h);for(var d=c.next();!d.done;d=c.next())d=d.value,d.startTime+=a,d.endTime+=a,d.j+=a}};q.Mc=function(a){!this.i&&a.length&&(this.M=this.M.filter(function(b){return b.startTime<a[0].startTime}),this.M.push.apply(this.M,ia(a)))};q.hc=function(a,b){var c=this;a=a.filter(function(d){return d.endTime>b&&(0==c.M.length||d.endTime>c.M[0].startTime)});this.Mc(a);this.Gb(b)};
297
299
  q.Gb=function(a){if(!this.i){var b=this.M.length;this.M=this.M.filter(function(c){return c.endTime>a});this.h+=b-this.M.length}};
298
- q.yb=function(a,b,c){c=void 0===c?!1:c;if(!this.i){for(;this.M.length;)if(this.M[this.M.length-1].startTime>=b)this.M.pop();else break;for(;this.M.length;)if(this.M[0].endTime<=a)this.M.shift(),c||this.h++;else break;0!=this.M.length&&(a=this.M[this.M.length-1],this.M[this.M.length-1]=new yi(a.startTime,b,a.m,a.Ta,a.Ca,a.i,a.timestampOffset,a.appendWindowStart,a.appendWindowEnd,a.h,a.tilesLayout,a.l,a.g))}};
299
- q.Fd=function(a,b){var c=this;this.i||(this.g&&this.g.stop(),this.g=new P(function(){var d=b();d?c.M.push.apply(c.M,ia(d)):(c.g.stop(),c.g=null)}),this.g.ka(a))};Xi.prototype[Symbol.iterator]=function(){return this.ac(0)};Xi.prototype.ac=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){b++;d=e-1;break}}return new Yi(this,b,d)};
300
- function Zi(a,b,c){return new Xi([new yi(a,a+b,function(){return c},0,null,null,a,a,a+b)])}J("shaka.media.SegmentIndex",Xi);Xi.forSingleSegment=Zi;Xi.prototype.getIteratorForTime=Xi.prototype.ac;Xi.prototype.updateEvery=Xi.prototype.Fd;Xi.prototype.fit=Xi.prototype.yb;Xi.prototype.evict=Xi.prototype.Gb;Xi.prototype.mergeAndEvict=Xi.prototype.hc;Xi.prototype.offset=Xi.prototype.offset;Xi.prototype.get=Xi.prototype.get;Xi.prototype.find=Xi.prototype.find;Xi.prototype.markImmutable=Xi.prototype.Qg;
301
- Xi.prototype.release=Xi.prototype.release;function Yi(a,b,c){this.i=a;this.h=b;this.g=c}Yi.prototype.current=function(){var a=this.i.get(this.h);a&&0<a.h.length&&a.Pa().length&&this.g>=a.h.length&&(this.h++,this.g=0,a=this.i.get(this.h));return a&&0<a.h.length?a.h[this.g]:a};Yi.prototype.next=function(){var a=this.i.get(this.h);a&&0<a.h.length?(this.g++,a.Pa().length&&this.g==a.h.length&&(this.h++,this.g=0)):(this.h++,this.g=0);a=this.current();return{value:a,done:!a}};
302
- J("shaka.media.SegmentIterator",Yi);Yi.prototype.next=Yi.prototype.next;Yi.prototype.current=Yi.prototype.current;function $i(){Xi.call(this,[]);this.j=[]}qa($i,Xi);q=$i.prototype;q.clone=function(){var a=new $i;a.j=this.j.slice();return a};q.release=function(){for(var a=t(this.j),b=a.next();!b.done;b=a.next())b.value.release();this.j=[]};q.find=function(a){for(var b=0,c=t(this.j),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.find(a);if(null!=e)return e+b;b+=d.h+d.M.length}return null};
303
- q.get=function(a){for(var b=0,c=t(this.j),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.get(a-b);if(e)return e;b+=d.h+d.M.length}return null};q.offset=function(){};q.Mc=function(){};q.Gb=function(){};q.hc=function(){};q.yb=function(){};q.Fd=function(){};J("shaka.media.MetaSegmentIndex",$i);$i.prototype.updateEvery=$i.prototype.Fd;$i.prototype.fit=$i.prototype.yb;$i.prototype.mergeAndEvict=$i.prototype.hc;$i.prototype.evict=$i.prototype.Gb;$i.prototype.merge=$i.prototype.Mc;
304
- $i.prototype.offset=$i.prototype.offset;$i.prototype.get=$i.prototype.get;$i.prototype.find=$i.prototype.find;$i.prototype.release=$i.prototype.release;function aj(a){var b=this;this.g=a;this.j=!1;this.i=this.g.md();this.h=new P(function(){b.g.yf(.25*b.i)})}aj.prototype.release=function(){this.h&&(this.h.stop(),this.h=null);this.g=null};aj.prototype.set=function(a){this.i=a;bj(this)};aj.prototype.jd=function(){return this.g.jd()};function bj(a){a.h.stop();var b=a.j?0:a.i;if(0<=b)try{a.g.md()!=b&&a.g.Ee(b);return}catch(c){}a.h.ka(.25);0!=a.g.md()&&a.g.Ee(0)};function cj(a){var b=this;this.h=a;this.g=new Set;this.i=(new P(function(){dj(b,!1)})).ka(.25)}cj.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 dj(a,b){for(var c=t(a.g),d=c.next();!d.done;d=c.next())d.value.j(a.h.currentTime,b)};function ej(a){fb.call(this);this.g=new Map;this.h=a}qa(ej,fb);ej.prototype.release=function(){this.g.clear();fb.prototype.release.call(this)};function fj(a,b){var c=a.g.get(b);c||(c={Oc:[],gf:null,contentType:b},a.g.set(b,c));return c}function gj(a,b,c){var d=fj(a,b.contentType);hj(a,d);a={ie:b,position:c};d=d.Oc;b=d.findIndex(function(e){return e.position>=c});0<=b?d.splice(b,d[b].position==c?1:0,a):d.push(a)}
305
- ej.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.Oc;for(var e=d.length-1;0<=e;e--){var f=d[e];if(f.position<=a){d=f.ie;break a}}d=null}if(e=d)e=c.gf,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);
306
- 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.gf=d,JSON.stringify(d),c=new M("qualitychange",new Map([["quality",d],["position",a]])),this.dispatchEvent(c))}};function hj(a,b){var c=a.h()[b.contentType];if(c&&0<c.length){var d=c[0].start,e=c[c.length-1].end,f=b.Oc;b.Oc=f.filter(function(g,h){return g.position<=d&&h+1<f.length&&f[h+1].position<=d||g.position>=e?!1:!0})}else b.Oc=[]};function ij(a){fb.call(this);var b=this;this.g=new Set;this.i=a;this.h=(new P(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 M("regionremove",new Map([["region",e]])),b.dispatchEvent(e))})).ka(2)}qa(ij,fb);ij.prototype.release=function(){this.g.clear();this.h.stop();fb.prototype.release.call(this)};function jj(a){fb.call(this);var b=this;this.i=a;this.g=new Map;this.l=[{Ub:null,Tb:kj,Kb:function(c,d){return lj(b,"enter",c,d)}},{Ub:mj,Tb:kj,Kb:function(c,d){return lj(b,"enter",c,d)}},{Ub:nj,Tb:kj,Kb:function(c,d){return lj(b,"enter",c,d)}},{Ub:kj,Tb:mj,Kb:function(c,d){return lj(b,"exit",c,d)}},{Ub:kj,Tb:nj,Kb:function(c,d){return lj(b,"exit",c,d)}},{Ub:mj,Tb:nj,Kb:function(c,d){return lj(b,"skip",c,d)}},{Ub:nj,Tb:mj,Kb:function(c,d){return lj(b,"skip",c,d)}}];this.h=new tf;this.h.o(this.i,"regionremove",
307
- function(c){b.g["delete"](c.region)})}qa(jj,fb);jj.prototype.release=function(){this.i=null;this.g.clear();this.h.release();this.h=null;fb.prototype.release.call(this)};jj.prototype.j=function(a,b){for(var c=t(this.i.g),d=c.next();!d.done;d=c.next()){d=d.value;var e=this.g.get(d),f=a<d.startTime?mj:a>d.endTime?nj:kj;this.g.set(d,f);for(var g=t(this.l),h=g.next();!h.done;h=g.next())h=h.value,h.Ub==e&&h.Tb==f&&h.Kb(d,b)}};
308
- function lj(a,b,c,d){b=new M(b,new Map([["region",c],["seeking",d]]));a.dispatchEvent(b)}var mj=1,kj=2,nj=3;function oj(a,b,c,d,e){a=kf(a,d,e);if(0!=b||null!=c)a.headers.Range=c?"bytes="+b+"-"+c:"bytes="+b+"-";return a};function pj(a,b){var c=this;this.g=b;this.m=a;this.i=null;this.C=1;this.A=this.l=null;this.h=new Map;this.F=!1;this.G=null;this.B=!1;this.j=new rf(function(){return qj(c)})}pj.prototype.destroy=function(){return this.j.destroy()};function qj(a){var b,c,d,e;return I(function(f){if(1==f.g){b=[];c=t(a.h.values());for(d=c.next();!d.done;d=c.next())e=d.value,rj(e),b.push(sj(e));return u(f,Promise.all(b),2)}a.h.clear();a.g=null;a.m=null;a.i=null;z(f)})}
309
- pj.prototype.configure=function(a){this.i=a;this.G=new Se({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)};pj.prototype.start=function(){var a=this;return I(function(b){if(1==b.g)return u(b,tj(a),2);sf(a.j);a.F=!0;z(b)})};
310
- function uj(a,b){var c,d,e,f,g,h;I(function(k){switch(k.g){case 1:return c=Jb,A(k,2),u(k,qi(a.g.V,c.ha),4);case 4:va(k,3);break;case 2:if(d=F(k),a.g)a.g.onError(d);case 3:e=jd(b.mimeType,b.codecs);ci(a.g.V,e,a.m.sequenceMode);f=a.g.V.m;if(g=f.isTextVisible()||a.i.alwaysStreamText)h=vj(b),a.h.set(c.ha,h),wj(a,h,0);z(k)}})}function xj(a){var b=a.h.get(Ib);b&&(rj(b),sj(b)["catch"](function(){}),a.h["delete"](Ib));a.A=null}
311
- function yj(a,b){var c=a.h.get("video");if(c){var d=c.stream;if(d)if(b){var e=d.trickModeVideo;e&&!c.Qb&&(zj(a,e,!1,0,!1),c.Qb=d)}else if(d=c.Qb)c.Qb=null,zj(a,d,!0,0,!1)}}function Aj(a,b,c,d,e){c=void 0===c?!1:c;d=void 0===d?0:d;e=void 0===e?!1:e;a.l=b;a.F&&(b.video&&zj(a,b.video,c,d,e),b.audio&&zj(a,b.audio,c,d,e))}function Bj(a,b){a.A=b;a.F&&zj(a,b,!0,0,!1)}
312
- function zj(a,b,c,d,e){var f=a.h.get(b.type);f||b.type!=Ib?f&&(f.Qb&&(b.trickModeVideo?(f.Qb=b,b=b.trickModeVideo):f.Qb=null),f.stream!=b||e)&&(b.type==Ib&&ci(a.g.V,jd(b.mimeType,b.codecs),a.m.sequenceMode),f.stream.closeSegmentIndex&&f.stream.closeSegmentIndex(),f.stream=b,f.sa=null,c&&(f.zc?f.Id=!0:f.ab?(f.Sb=!0,f.fd=d,f.Id=!0):(rj(f),Cj(a,f,!0,d)["catch"](function(g){if(a.g)a.g.onError(g)}))),Dj(a,f)["catch"](function(g){if(a.g)a.g.onError(g)})):uj(a,b)}
313
- function Dj(a,b){var c,d;return I(function(e){if(1==e.g){if(!b.Ja)return e["return"]();c=b.stream;d=b.Ja;return c.segmentIndex?e.D(2):u(e,c.createSegmentIndex(),2)}if(b.Ja!=d||b.stream!=c)return e["return"]();var f=a.g.ld();var g=hi(a.g.V,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.Ca?k.Ca-k.Ta:null:null;k&&!h&&(h=(k.endTime-k.getStartTime())*(b.stream.bandwidth||0)/8);h?((k=k.i)&&(h+=(k.Ca?k.Ca-k.Ta:null)||0),k=a.g.getBandwidthEstimate(),
300
+ q.yb=function(a,b,c){c=void 0===c?!1:c;if(!this.i){for(;this.M.length;)if(this.M[this.M.length-1].startTime>=b)this.M.pop();else break;for(;this.M.length;)if(this.M[0].endTime<=a)this.M.shift(),c||this.h++;else break;0!=this.M.length&&(a=this.M[this.M.length-1],this.M[this.M.length-1]=new Yh(a.startTime,b,a.m,a.Ta,a.Ca,a.i,a.timestampOffset,a.appendWindowStart,a.appendWindowEnd,a.h,a.tilesLayout,a.l,a.g))}};
301
+ q.Fd=function(a,b){var c=this;this.i||(this.g&&this.g.stop(),this.g=new P(function(){var d=b();d?c.M.push.apply(c.M,ia(d)):(c.g.stop(),c.g=null)}),this.g.ka(a))};$i.prototype[Symbol.iterator]=function(){return this.ac(0)};$i.prototype.ac=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){b++;d=e-1;break}}return new aj(this,b,d)};
302
+ function bj(a,b,c){return new $i([new Yh(a,a+b,function(){return c},0,null,null,a,a,a+b)])}J("shaka.media.SegmentIndex",$i);$i.forSingleSegment=bj;$i.prototype.getIteratorForTime=$i.prototype.ac;$i.prototype.updateEvery=$i.prototype.Fd;$i.prototype.fit=$i.prototype.yb;$i.prototype.evict=$i.prototype.Gb;$i.prototype.mergeAndEvict=$i.prototype.hc;$i.prototype.offset=$i.prototype.offset;$i.prototype.get=$i.prototype.get;$i.prototype.find=$i.prototype.find;$i.prototype.markImmutable=$i.prototype.Rg;
303
+ $i.prototype.release=$i.prototype.release;function aj(a,b,c){this.i=a;this.h=b;this.g=c}aj.prototype.current=function(){var a=this.i.get(this.h);a&&0<a.h.length&&a.Pa().length&&this.g>=a.h.length&&(this.h++,this.g=0,a=this.i.get(this.h));return a&&0<a.h.length?a.h[this.g]:a};aj.prototype.next=function(){var a=this.i.get(this.h);a&&0<a.h.length?(this.g++,a.Pa().length&&this.g==a.h.length&&(this.h++,this.g=0)):(this.h++,this.g=0);a=this.current();return{value:a,done:!a}};
304
+ J("shaka.media.SegmentIterator",aj);aj.prototype.next=aj.prototype.next;aj.prototype.current=aj.prototype.current;function cj(){$i.call(this,[]);this.j=[]}qa(cj,$i);q=cj.prototype;q.clone=function(){var a=new cj;a.j=this.j.slice();return a};q.release=function(){for(var a=t(this.j),b=a.next();!b.done;b=a.next())b.value.release();this.j=[]};q.find=function(a){for(var b=0,c=t(this.j),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.find(a);if(null!=e)return e+b;b+=d.h+d.M.length}return null};
305
+ q.get=function(a){for(var b=0,c=t(this.j),d=c.next();!d.done;d=c.next()){d=d.value;var e=d.get(a-b);if(e)return e;b+=d.h+d.M.length}return null};q.offset=function(){};q.Mc=function(){};q.Gb=function(){};q.hc=function(){};q.yb=function(){};q.Fd=function(){};J("shaka.media.MetaSegmentIndex",cj);cj.prototype.updateEvery=cj.prototype.Fd;cj.prototype.fit=cj.prototype.yb;cj.prototype.mergeAndEvict=cj.prototype.hc;cj.prototype.evict=cj.prototype.Gb;cj.prototype.merge=cj.prototype.Mc;
306
+ cj.prototype.offset=cj.prototype.offset;cj.prototype.get=cj.prototype.get;cj.prototype.find=cj.prototype.find;cj.prototype.release=cj.prototype.release;function dj(a){var b=this;this.g=a;this.j=!1;this.i=this.g.md();this.h=new P(function(){b.g.zf(.25*b.i)})}dj.prototype.release=function(){this.h&&(this.h.stop(),this.h=null);this.g=null};dj.prototype.set=function(a){this.i=a;ej(this)};dj.prototype.jd=function(){return this.g.jd()};function ej(a){a.h.stop();var b=a.j?0:a.i;if(0<=b)try{a.g.md()!=b&&a.g.Fe(b);return}catch(c){}a.h.ka(.25);0!=a.g.md()&&a.g.Fe(0)};function fj(a){var b=this;this.h=a;this.g=new Set;this.i=(new P(function(){gj(b,!1)})).ka(.25)}fj.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 gj(a,b){for(var c=t(a.g),d=c.next();!d.done;d=c.next())d.value.j(a.h.currentTime,b)};function hj(a){fb.call(this);this.g=new Map;this.h=a}qa(hj,fb);hj.prototype.release=function(){this.g.clear();fb.prototype.release.call(this)};function ij(a,b){var c=a.g.get(b);c||(c={Oc:[],hf:null,contentType:b},a.g.set(b,c));return c}function jj(a,b,c){var d=ij(a,b.contentType);kj(a,d);a={je:b,position:c};d=d.Oc;b=d.findIndex(function(e){return e.position>=c});0<=b?d.splice(b,d[b].position==c?1:0,a):d.push(a)}
307
+ hj.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.Oc;for(var e=d.length-1;0<=e;e--){var f=d[e];if(f.position<=a){d=f.je;break a}}d=null}if(e=d)e=c.hf,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);
308
+ 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.hf=d,JSON.stringify(d),c=new L("qualitychange",new Map([["quality",d],["position",a]])),this.dispatchEvent(c))}};function kj(a,b){var c=a.h()[b.contentType];if(c&&0<c.length){var d=c[0].start,e=c[c.length-1].end,f=b.Oc;b.Oc=f.filter(function(g,h){return g.position<=d&&h+1<f.length&&f[h+1].position<=d||g.position>=e?!1:!0})}else b.Oc=[]};function lj(a){fb.call(this);var b=this;this.g=new Set;this.i=a;this.h=(new P(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 L("regionremove",new Map([["region",e]])),b.dispatchEvent(e))})).ka(2)}qa(lj,fb);lj.prototype.release=function(){this.g.clear();this.h.stop();fb.prototype.release.call(this)};function mj(a){fb.call(this);var b=this;this.i=a;this.g=new Map;this.l=[{Ub:null,Tb:nj,Kb:function(c,d){return oj(b,"enter",c,d)}},{Ub:pj,Tb:nj,Kb:function(c,d){return oj(b,"enter",c,d)}},{Ub:qj,Tb:nj,Kb:function(c,d){return oj(b,"enter",c,d)}},{Ub:nj,Tb:pj,Kb:function(c,d){return oj(b,"exit",c,d)}},{Ub:nj,Tb:qj,Kb:function(c,d){return oj(b,"exit",c,d)}},{Ub:pj,Tb:qj,Kb:function(c,d){return oj(b,"skip",c,d)}},{Ub:qj,Tb:pj,Kb:function(c,d){return oj(b,"skip",c,d)}}];this.h=new wf;this.h.o(this.i,"regionremove",
309
+ function(c){b.g["delete"](c.region)})}qa(mj,fb);mj.prototype.release=function(){this.i=null;this.g.clear();this.h.release();this.h=null;fb.prototype.release.call(this)};mj.prototype.j=function(a,b){for(var c=t(this.i.g),d=c.next();!d.done;d=c.next()){d=d.value;var e=this.g.get(d),f=a<d.startTime?pj:a>d.endTime?qj:nj;this.g.set(d,f);for(var g=t(this.l),h=g.next();!h.done;h=g.next())h=h.value,h.Ub==e&&h.Tb==f&&h.Kb(d,b)}};
310
+ function oj(a,b,c,d){b=new L(b,new Map([["region",c],["seeking",d]]));a.dispatchEvent(b)}var pj=1,nj=2,qj=3;function rj(a,b,c,d,e){a=nf(a,d,e);if(0!=b||null!=c)a.headers.Range=c?"bytes="+b+"-"+c:"bytes="+b+"-";return a};function sj(a,b){var c=this;this.g=b;this.m=a;this.i=null;this.C=1;this.A=this.l=null;this.h=new Map;this.F=!1;this.G=null;this.B=!1;this.j=new uf(function(){return tj(c)})}sj.prototype.destroy=function(){return this.j.destroy()};function tj(a){var b,c,d,e;return I(function(f){if(1==f.g){b=[];c=t(a.h.values());for(d=c.next();!d.done;d=c.next())e=d.value,uj(e),b.push(vj(e));return u(f,Promise.all(b),2)}a.h.clear();a.g=null;a.m=null;a.i=null;z(f)})}
311
+ sj.prototype.configure=function(a){this.i=a;this.G=new Ve({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)};sj.prototype.start=function(){var a=this;return I(function(b){if(1==b.g)return u(b,wj(a),2);vf(a.j);a.F=!0;z(b)})};
312
+ function xj(a,b){var c,d,e,f,g,h;I(function(k){switch(k.g){case 1:return c=Jb,A(k,2),u(k,yi(a.g.V,c.ha),4);case 4:va(k,3);break;case 2:if(d=F(k),a.g)a.g.onError(d);case 3:e=yd(b.mimeType,b.codecs);ki(a.g.V,e,a.m.sequenceMode);f=a.g.V.m;if(g=f.isTextVisible()||a.i.alwaysStreamText)h=yj(b),a.h.set(c.ha,h),zj(a,h,0);z(k)}})}function Aj(a){var b=a.h.get(Ib);b&&(uj(b),vj(b)["catch"](function(){}),a.h["delete"](Ib));a.A=null}
313
+ function Bj(a,b){var c=a.h.get("video");if(c){var d=c.stream;if(d)if(b){var e=d.trickModeVideo;e&&!c.Qb&&(Cj(a,e,!1,0,!1),c.Qb=d)}else if(d=c.Qb)c.Qb=null,Cj(a,d,!0,0,!1)}}function Dj(a,b,c,d,e){c=void 0===c?!1:c;d=void 0===d?0:d;e=void 0===e?!1:e;a.l=b;a.F&&(b.video&&Cj(a,b.video,c,d,e),b.audio&&Cj(a,b.audio,c,d,e))}function Ej(a,b){a.A=b;a.F&&Cj(a,b,!0,0,!1)}
314
+ function Cj(a,b,c,d,e){var f=a.h.get(b.type);f||b.type!=Ib?f&&(f.Qb&&(b.trickModeVideo?(f.Qb=b,b=b.trickModeVideo):f.Qb=null),f.stream!=b||e)&&(b.type==Ib&&ki(a.g.V,yd(b.mimeType,b.codecs),a.m.sequenceMode),f.stream.closeSegmentIndex&&f.stream.closeSegmentIndex(),f.stream=b,f.sa=null,c&&(f.zc?f.Id=!0:f.ab?(f.Sb=!0,f.fd=d,f.Id=!0):(uj(f),Fj(a,f,!0,d)["catch"](function(g){if(a.g)a.g.onError(g)}))),Gj(a,f)["catch"](function(g){if(a.g)a.g.onError(g)})):xj(a,b)}
315
+ function Gj(a,b){var c,d;return I(function(e){if(1==e.g){if(!b.Ja)return e["return"]();c=b.stream;d=b.Ja;return c.segmentIndex?e.D(2):u(e,c.createSegmentIndex(),2)}if(b.Ja!=d||b.stream!=c)return e["return"]();var f=a.g.ld();var g=pi(a.g.V,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.Ca?k.Ca-k.Ta:null:null;k&&!h&&(h=(k.endTime-k.getStartTime())*(b.stream.bandwidth||0)/8);h?((k=k.i)&&(h+=(k.Ca?k.Ca-k.Ta:null)||0),k=a.g.getBandwidthEstimate(),
314
316
  f=8*h/k<(g||0)-f-Math.max(a.m.minBufferTime||0,a.i.rebufferingGoal)||b.Ja.h.g>h?!0:!1):f=!1;f&&b.Ja.abort();z(e)})}
315
- pj.prototype.Rc=function(){for(var a=this.g.ld(),b=t(this.h.keys()),c=b.next();!c.done;c=b.next()){var d=c.value;c=this.h.get(d);c.sa=null;var e=this.g.V;d==Ib?(e=e.g,e=null==e.g||null==e.h?!1:a>=e.g&&a<e.h):(e=gi(e,d),e=Vh(e,a));if(!e){(null!=hi(this.g.V,d)||c.ab)&&Ej(this,c);c.Ja&&(c.Ja.abort(),c.Ja=null);if(d===Ib)for(d=this.g.V.F.g,d.l=0,d.h=[],d.g=[],e=d.i,e.i=[],e.h=[],e.g=0,Hh(d),d=t(d.j.values()),e=d.next();!e.done;e=d.next())Ch(e.value);c.Rc=!0}}};
316
- function Ej(a,b){b.zc||b.Sb||(b.ab?(b.Sb=!0,b.fd=0):null==fi(a.g.V,b.type)?null==b.eb&&wj(a,b,0):(rj(b),Cj(a,b,!1,0)["catch"](function(c){if(a.g)a.g.onError(c)})))}
317
- function tj(a){var b,c,d,e,f,g,h,k,l,m;return I(function(n){if(1==n.g){b=Jb;if(!a.l)throw new O(2,5,5006);c=new Map;d=new Set;a.l.audio&&(c.set(b.Fb,a.l.audio),d.add(a.l.audio));a.l.video&&(c.set(b.Ma,a.l.video),d.add(a.l.video));a.A&&(c.set(b.ha,a.A),d.add(a.A));e=a.g.V;f=a.i.forceTransmuxTS;return u(n,e.init(c,f,a.m.sequenceMode),2)}sf(a.j);var p=a.m.presentationTimeline.getDuration();Infinity>p?a.g.V.bb(p):a.g.V.bb(Math.pow(2,32));g=t(c.keys());for(h=g.next();!h.done;h=g.next())k=h.value,l=c.get(k),
318
- a.h.has(k)||(m=vj(l),a.h.set(k,m),wj(a,m,0));z(n)})}function vj(a){return{stream:a,type:a.type,sa:null,Ra:null,qd:null,fe:null,ee:null,ce:null,Qb:null,endOfStream:!1,ab:!1,eb:null,Sb:!1,fd:0,Id:!1,zc:!1,Rc:!0,re:!1,Ic:!1,Ja:null}}
319
- function Fj(a,b){var c,d,e,f,g;return I(function(h){switch(h.g){case 1:sf(a.j);if(b.ab||null==b.eb||b.zc)return h["return"]();b.eb=null;if(!b.Sb){h.D(2);break}return u(h,Cj(a,b,b.Id,b.fd),3);case 3:return h["return"]();case 2:if(b.stream.segmentIndex){h.D(4);break}c=b.stream;return u(h,b.stream.createSegmentIndex(),5);case 5:if(c!=b.stream)return c.closeSegmentIndex&&c.closeSegmentIndex(),null==b.eb&&wj(a,b,0),h["return"]();case 4:A(h,6);d=Gj(a,b);null!=d&&(wj(a,b,d),b.Ic=!1);va(h,7);break;case 6:return e=
320
- F(h),u(h,Hj(a,e),8);case 8:return h["return"]();case 7:f=Array.from(a.h.values());if(!a.F||!f.every(function(k){return k.endOfStream})){h.D(0);break}return u(h,a.g.V.endOfStream(),10);case 10:sf(a.j),g=a.g.V.getDuration(),0!=g&&g<a.m.presentationTimeline.getDuration()&&a.m.presentationTimeline.bb(g),z(h)}})}
321
- function Gj(a,b){if(Ij(b))return oi(a.g.V,b.stream.originalId||""),null;b.type==Ib&&pi(a.g.V);var c=a.g.ld(),d=b.Ra?b.Ra.endTime:c,e=ii(a.g.V,b.type,c),f=Math.max(a.m.minBufferTime||0,a.i.rebufferingGoal,a.i.bufferingGoal)*a.C;if(1E-6>a.m.presentationTimeline.getDuration()-d)return b.endOfStream=!0,"video"==b.type&&(c=a.h.get(Ib))&&Ij(c)&&(c.endOfStream=!0),null;b.endOfStream=!1;if(e>=f)return a.i.updateIntervalSeconds/2;e=hi(a.g.V,b.type);e=Jj(a,b,c,e);if(!e)return a.i.updateIntervalSeconds;f=Infinity;
322
- var g=Array.from(a.h.values());g=t(g);for(var h=g.next();!h.done;h=g.next())h=h.value,Ij(h)||h.sa&&!h.sa.current()||(f=Math.min(f,h.Ra?h.Ra.endTime:c));if(d>=f+a.m.presentationTimeline.g)return a.i.updateIntervalSeconds;Kj(a,b,c,e)["catch"](function(){});return null}
323
- function Jj(a,b,c,d){if(b.sa)return b.sa.current();if(b.Ra||d)return b.sa=b.stream.segmentIndex.ac(b.Ra?b.Ra.endTime:d),b.sa&&b.sa.next().value;a=a.i.inaccurateManifestTolerance;d=Math.max(c-a,0);var e=null;a&&(b.sa=b.stream.segmentIndex.ac(d),e=b.sa&&b.sa.next().value);e||(b.sa=b.stream.segmentIndex.ac(c),e=b.sa&&b.sa.next().value);return e}
324
- function Kj(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,x,y;return I(function(w){switch(w.g){case 1:e=Jb;f=b.stream;g=b.sa;b.ab=!0;A(w,2);if(2==d.nd())throw new O(1,1,1011);return u(w,Lj(a,b,d),4);case 4:sf(a.j);if(a.B)return w["return"]();h="video/mp4"==f.mimeType||"audio/mp4"==f.mimeType;k=window.ReadableStream;if(a.i.lowLatencyMode&&k&&h)return n=new Uint8Array(0),p=function(v){var D,C,B;return I(function(G){sf(a.j);if(a.B)return G["return"]();n=Mj(n,v);D=!1;C=0;(new xg).box("mdat",function(E){C=E.size+E.start;
325
- D=!0}).parse(n,!1,!0);if(!D)return G.D(0);B=n.subarray(0,C);n=n.subarray(C);return u(G,Nj(a,b,c,f,d,B),0)})},u(w,Oj(a,b,d,p),6);l=Oj(a,b,d);return u(w,l,7);case 7:return m=w.h,sf(a.j),a.B?w["return"]():b.Sb?(b.ab=!1,wj(a,b,0),w["return"]()):u(w,Nj(a,b,c,f,d,m),6);case 6:sf(a.j);if(a.B)return w["return"]();b.Ra=d;g.next();b.ab=!1;b.re=!1;r=a.g.V.kb();x=r[b.type];Za(JSON.stringify(x));b.Sb||a.g.oe();wj(a,b,0);va(w,0);break;case 2:y=F(w);sf(a.j,y);if(a.B)return w["return"]();b.ab=!1;if(7001==y.code)b.ab=
326
- !1,b.eb=null,wj(a,b,0),w.D(0);else if(b.type==e.ha&&a.i.ignoreTextStreamFailures)a.h["delete"](e.ha),w.D(0);else if(3017==y.code)Pj(a,b,y),w.D(0);else if(1001==y.code&&y.data&&404==y.data[1])b.ab=!1,b.eb=null,wj(a,b,1),w.D(0);else return b.Ic=!0,y.severity=2,u(w,Hj(a,y),0)}})}function Mj(a,b){var c=new Uint8Array(a.length+b.length);c.set(a);c.set(b,a.length);return c}
327
- function Pj(a,b,c){if(!Array.from(a.h.values()).some(function(e){return e!=b&&e.re})){var d=Math.round(100*a.C);if(20<d)a.C-=.2;else if(4<d)a.C-=.04;else{b.Ic=!0;a.B=!0;a.g.onError(c);return}b.re=!0}wj(a,b,4)}
328
- function Lj(a,b,c){var d,e,f,g,h,k,l;return I(function(m){d=[];e=Math.max(0,c.appendWindowStart-.1);f=c.appendWindowEnd+.01;g=c.timestampOffset;if(g!=b.fe||e!=b.ee||f!=b.ce)h=function(){var n;return I(function(p){if(1==p.g)return A(p,2),b.ee=e,b.ce=f,b.fe=g,u(p,ri(a.g.V,b.type,g,e,f,a.m.sequenceMode),4);if(2!=p.g)return va(p,0);n=F(p);b.ee=null;b.ce=null;b.fe=null;throw n;})},d.push(h());!xi(c.i,b.qd)&&(b.qd=c.i)&&(k=Oj(a,b,c.i),l=function(){var n,p,r;return I(function(x){switch(x.g){case 1:return A(x,
329
- 2),u(x,k,4);case 4:return n=x.h,sf(a.j),p=b.stream.closedCaptions&&0<b.stream.closedCaptions.size,u(x,ji(a.g.V,b.type,n,null,null,p),5);case 5:va(x,0);break;case 2:throw r=F(x),b.qd=null,r;}})},a.g.Tg(c.startTime,c.i),d.push(l()));return u(m,Promise.all(d),0)})}
330
- function Nj(a,b,c,d,e,f){var g,h;return I(function(k){if(1==k.g)return g=d.closedCaptions&&0<d.closedCaptions.size,(null!=d.emsgSchemeIdUris&&0<d.emsgSchemeIdUris.length||a.i.dispatchAllEmsgBoxes)&&(new xg).Y("emsg",function(l){var m=d.emsgSchemeIdUris;if(0===l.version){var n=l.reader.Pc();var p=l.reader.Pc();var r=l.reader.R();var x=l.reader.R();var y=l.reader.R();var w=l.reader.R();var v=e.startTime+x/r}else r=l.reader.R(),v=l.reader.lc()/r+e.timestampOffset,x=v-e.startTime,y=l.reader.R(),w=l.reader.R(),
331
- n=l.reader.Pc(),p=l.reader.Pc();l=l.reader.Cb(l.reader.W.byteLength-l.reader.oa());if(m&&m.includes(n)||a.i.dispatchAllEmsgBoxes)"urn:mpeg:dash:event:2012"==n?a.g.Ug():(m=(new Map).set("detail",{startTime:v,endTime:v+y/r,schemeIdUri:n,value:p,timescale:r,presentationTimeDelta:x,eventDuration:y,id:w,messageData:l}),m=new M("emsg",m),a.g.onEvent(m))}).parse(f),u(k,Qj(a,b,c),2);if(3!=k.g)return sf(a.j),h=b.Rc,b.Rc=!1,u(k,ji(a.g.V,b.type,f,e.startTime,e.endTime,g,h),3);sf(a.j);z(k)})}
332
- function Qj(a,b,c){var d,e,f,g;return I(function(h){if(1==h.g){d=Math.max(a.i.bufferBehind,a.m.presentationTimeline.g);e=fi(a.g.V,b.type);if(null==e)return h["return"]();f=c-e;g=f-d;return.01>=g?h["return"]():u(h,a.g.V.remove(b.type,e,e+g),2)}sf(a.j);z(h)})}function Ij(a){return a&&a.type==Ib&&("application/cea-608"==a.stream.mimeType||"application/cea-708"==a.stream.mimeType)}
333
- function Oj(a,b,c,d){var e,f,g,h,k;return I(function(l){if(1==l.g)return e=qf,f=oj(c.Pa(),c.Ta,c.Ca,a.i.retryParameters,d),g=b.stream,a.g.modifySegmentRequest(f,{type:g.type,init:c instanceof wi,duration:c.endTime-c.startTime,mimeType:g.mimeType,codecs:g.codecs,bandwidth:g.bandwidth}),h=a.g.Ob.request(e,f),b.Ja=h,u(l,h.promise,2);k=l.h;b.Ja=null;return l["return"](k.data)})}
334
- function Cj(a,b,c,d){var e,f;return I(function(g){if(1==g.g)return b.Sb=!1,b.Id=!1,b.fd=0,b.zc=!0,b.Ra=null,b.qd=null,b.sa=null,d?(e=a.g.ld(),f=a.g.V.getDuration(),u(g,a.g.V.remove(b.type,e+d,f),3)):u(g,qi(a.g.V,b.type),4);if(3!=g.g)return sf(a.j),c?u(g,a.g.V.flush(b.type),3):g.D(3);sf(a.j);b.zc=!1;b.endOfStream=!1;wj(a,b,0);z(g)})}
335
- function wj(a,b,c){var d=b.type;if(d!=Ib||a.h.has(d))b.eb=(new xd(function(){var e;return I(function(f){if(1==f.g)return A(f,2),u(f,Fj(a,b),4);if(2!=f.g)return va(f,0);e=F(f);if(a.g)a.g.onError(e);z(f)})})).T(c)}function rj(a){null!=a.eb&&(a.eb.stop(),a.eb=null)}function sj(a){return I(function(b){return a.Ja?u(b,a.Ja.abort(),0):b.D(0)})}function Hj(a,b){return I(function(c){if(1==c.g)return u(c,Ue(a.G),2);sf(a.j);a.g.onError(b);b.handled||a.i.failureCallback(b);z(c)})};function Rj(a,b){var c=Sj(),d=this;this.j=b;this.i=a;this.l=c;this.A=null;this.m=[];this.h=this.g=null;this.C=Promise.resolve().then(function(){return Tj(d)});this.B=new rf(function(){return Uj(d)})}Rj.prototype.destroy=function(){return this.B.destroy()};function Uj(a){var b,c,d;return I(function(e){if(1==e.g)return a.h&&a.h.abort(),Vj(a),u(e,a.C,2);a.g&&a.g.$a.Pb();b=t(a.m);for(c=b.next();!c.done;c=b.next())d=c.value,d.$a.Pb();a.g=null;a.m=[];a.j=null;z(e)})}
336
- function Wj(a,b){var c={jc:function(){},vd:function(){},Pb:function(){},onError:function(){},xd:function(){},Xi:function(){}};a.m.push({create:b,$a:c});a.h&&a.h.abort();Vj(a);return c}
337
- function Tj(a){return I(function(b){if(a.B.g)b=b.D(0);else{if(0==a.m.length||a.g&&!a.g.Jb)var c=!1;else{a.g&&(a.g.$a.Pb(),a.g=null);c=a.m.shift();var d=c.create(a.l);d?(c.$a.jc(),a.g={node:d.node,payload:d.payload,Jb:d.Jb,$a:c.$a}):c.$a.xd();c=!0}c?c=Promise.resolve():a.g?c=Xj(a):(a.j.Sg(a.i),a.A=new Nc,c=a.A);b=u(b,c,1)}return b})}
338
- function Xj(a){var b,c;return I(function(d){switch(d.g){case 1:return a.i=a.j.yg(a.i,a.l,a.g.node,a.g.payload),A(d,2),a.h=a.j.cg(a.i,a.l,a.g.payload),u(d,a.h.promise,4);case 4:a.h=null;a.i==a.g.node&&(a.g.$a.vd(),a.g=null);va(d,0);break;case 2:b=F(d);if(7001==b.code)a.g.$a.Pb();else a.g.$a.onError(b);a.g=null;a.h=null;c=a;return u(d,a.j.handleError(a.l,b),5);case 5:c.i=d.h,z(d)}})}function Vj(a){a.A&&(a.A.resolve(),a.A=null)};function Yj(a){this.g=null;for(var b=t(Array.from(a.textTracks)),c=b.next();!c.done;c=b.next())c=c.value,c.mode="disabled","Shaka Player TextTrack"==c.label&&(this.g=c);this.g||(this.g=a.addTextTrack("subtitles","Shaka Player TextTrack"));this.g.mode="hidden"}q=Yj.prototype;q.remove=function(a,b){if(!this.g)return!1;Zj(this.g,function(c){return c.startTime<b&&c.endTime>a});return!0};
317
+ sj.prototype.Rc=function(){for(var a=this.g.ld(),b=t(this.h.keys()),c=b.next();!c.done;c=b.next()){var d=c.value;c=this.h.get(d);c.sa=null;var e=this.g.V;d==Ib?(e=e.g,e=null==e.g||null==e.h?!1:a>=e.g&&a<e.h):(e=oi(e,d),e=ci(e,a));if(!e){(null!=pi(this.g.V,d)||c.ab)&&Hj(this,c);c.Ja&&(c.Ja.abort(),c.Ja=null);if(d===Ib)for(d=this.g.V.F.g,d.l=0,d.h=[],d.g=[],e=d.i,e.i=[],e.h=[],e.g=0,Kh(d),d=t(d.j.values()),e=d.next();!e.done;e=d.next())Fh(e.value);c.Rc=!0}}};
318
+ function Hj(a,b){b.zc||b.Sb||(b.ab?(b.Sb=!0,b.fd=0):null==ni(a.g.V,b.type)?null==b.eb&&zj(a,b,0):(uj(b),Fj(a,b,!1,0)["catch"](function(c){if(a.g)a.g.onError(c)})))}
319
+ function wj(a){var b,c,d,e,f,g,h,k,l,m;return I(function(n){if(1==n.g){b=Jb;if(!a.l)throw new O(2,5,5006);c=new Map;d=new Set;a.l.audio&&(c.set(b.Fb,a.l.audio),d.add(a.l.audio));a.l.video&&(c.set(b.Ma,a.l.video),d.add(a.l.video));a.A&&(c.set(b.ha,a.A),d.add(a.A));e=a.g.V;f=a.i.forceTransmuxTS;return u(n,e.init(c,f,a.m.sequenceMode),2)}vf(a.j);var p=a.m.presentationTimeline.getDuration();Infinity>p?a.g.V.bb(p):a.g.V.bb(Math.pow(2,32));g=t(c.keys());for(h=g.next();!h.done;h=g.next())k=h.value,l=c.get(k),
320
+ a.h.has(k)||(m=yj(l),a.h.set(k,m),zj(a,m,0));z(n)})}function yj(a){return{stream:a,type:a.type,sa:null,Ra:null,qd:null,fe:null,ee:null,ce:null,Qb:null,endOfStream:!1,ab:!1,eb:null,Sb:!1,fd:0,Id:!1,zc:!1,Rc:!0,se:!1,Ic:!1,Ja:null}}
321
+ function Ij(a,b){var c,d,e,f,g;return I(function(h){switch(h.g){case 1:vf(a.j);if(b.ab||null==b.eb||b.zc)return h["return"]();b.eb=null;if(!b.Sb){h.D(2);break}return u(h,Fj(a,b,b.Id,b.fd),3);case 3:return h["return"]();case 2:if(b.stream.segmentIndex){h.D(4);break}c=b.stream;return u(h,b.stream.createSegmentIndex(),5);case 5:if(c!=b.stream)return c.closeSegmentIndex&&c.closeSegmentIndex(),null==b.eb&&zj(a,b,0),h["return"]();case 4:A(h,6);d=Jj(a,b);null!=d&&(zj(a,b,d),b.Ic=!1);va(h,7);break;case 6:return e=
322
+ F(h),u(h,Kj(a,e),8);case 8:return h["return"]();case 7:f=Array.from(a.h.values());if(!a.F||!f.every(function(k){return k.endOfStream})){h.D(0);break}return u(h,a.g.V.endOfStream(),10);case 10:vf(a.j),g=a.g.V.getDuration(),0!=g&&g<a.m.presentationTimeline.getDuration()&&a.m.presentationTimeline.bb(g),z(h)}})}
323
+ function Jj(a,b){if(Lj(b))return wi(a.g.V,b.stream.originalId||""),null;b.type==Ib&&xi(a.g.V);var c=a.g.ld(),d=b.Ra?b.Ra.endTime:c,e=qi(a.g.V,b.type,c),f=Math.max(a.m.minBufferTime||0,a.i.rebufferingGoal,a.i.bufferingGoal)*a.C;if(1E-6>a.m.presentationTimeline.getDuration()-d)return b.endOfStream=!0,"video"==b.type&&(c=a.h.get(Ib))&&Lj(c)&&(c.endOfStream=!0),null;b.endOfStream=!1;if(e>=f)return a.i.updateIntervalSeconds/2;e=pi(a.g.V,b.type);e=Mj(a,b,c,e);if(!e)return a.i.updateIntervalSeconds;f=Infinity;
324
+ var g=Array.from(a.h.values());g=t(g);for(var h=g.next();!h.done;h=g.next())h=h.value,Lj(h)||h.sa&&!h.sa.current()||(f=Math.min(f,h.Ra?h.Ra.endTime:c));if(d>=f+a.m.presentationTimeline.g)return a.i.updateIntervalSeconds;Nj(a,b,c,e)["catch"](function(){});return null}
325
+ function Mj(a,b,c,d){if(b.sa)return b.sa.current();if(b.Ra||d)return b.sa=b.stream.segmentIndex.ac(b.Ra?b.Ra.endTime:d),b.sa&&b.sa.next().value;a=a.i.inaccurateManifestTolerance;d=Math.max(c-a,0);var e=null;a&&(b.sa=b.stream.segmentIndex.ac(d),e=b.sa&&b.sa.next().value);e||(b.sa=b.stream.segmentIndex.ac(c),e=b.sa&&b.sa.next().value);return e}
326
+ function Nj(a,b,c,d){var e,f,g,h,k,l,m,n,p,r,w,y;return I(function(x){switch(x.g){case 1:e=Jb;f=b.stream;g=b.sa;b.ab=!0;A(x,2);if(2==d.nd())throw new O(1,1,1011);return u(x,Oj(a,b,d),4);case 4:vf(a.j);if(a.B)return x["return"]();h="video/mp4"==f.mimeType||"audio/mp4"==f.mimeType;k=window.ReadableStream;if(a.i.lowLatencyMode&&k&&h)return n=new Uint8Array(0),p=function(v){var D,C,B;return I(function(G){vf(a.j);if(a.B)return G["return"]();n=Pj(n,v);D=!1;C=0;(new Ag).box("mdat",function(E){C=E.size+E.start;
327
+ D=!0}).parse(n,!1,!0);if(!D)return G.D(0);B=n.subarray(0,C);n=n.subarray(C);return u(G,Qj(a,b,c,f,d,B),0)})},u(x,Rj(a,b,d,p),6);l=Rj(a,b,d);return u(x,l,7);case 7:return m=x.h,vf(a.j),a.B?x["return"]():b.Sb?(b.ab=!1,zj(a,b,0),x["return"]()):u(x,Qj(a,b,c,f,d,m),6);case 6:vf(a.j);if(a.B)return x["return"]();b.Ra=d;g.next();b.ab=!1;b.se=!1;r=a.g.V.kb();w=r[b.type];Za(JSON.stringify(w));b.Sb||a.g.pe();zj(a,b,0);va(x,0);break;case 2:y=F(x);vf(a.j,y);if(a.B)return x["return"]();b.ab=!1;if(7001==y.code)b.ab=
328
+ !1,b.eb=null,zj(a,b,0),x.D(0);else if(b.type==e.ha&&a.i.ignoreTextStreamFailures)a.h["delete"](e.ha),x.D(0);else if(3017==y.code)Sj(a,b,y),x.D(0);else if(1001==y.code&&y.data&&404==y.data[1])b.ab=!1,b.eb=null,zj(a,b,1),x.D(0);else return b.Ic=!0,y.severity=2,u(x,Kj(a,y),0)}})}function Pj(a,b){var c=new Uint8Array(a.length+b.length);c.set(a);c.set(b,a.length);return c}
329
+ function Sj(a,b,c){if(!Array.from(a.h.values()).some(function(e){return e!=b&&e.se})){var d=Math.round(100*a.C);if(20<d)a.C-=.2;else if(4<d)a.C-=.04;else{b.Ic=!0;a.B=!0;a.g.onError(c);return}b.se=!0}zj(a,b,4)}
330
+ function Oj(a,b,c){var d,e,f,g,h,k,l;return I(function(m){d=[];e=Math.max(0,c.appendWindowStart-.1);f=c.appendWindowEnd+.01;g=c.timestampOffset;if(g!=b.fe||e!=b.ee||f!=b.ce)h=function(){var n;return I(function(p){if(1==p.g)return A(p,2),b.ee=e,b.ce=f,b.fe=g,u(p,zi(a.g.V,b.type,g,e,f,a.m.sequenceMode),4);if(2!=p.g)return va(p,0);n=F(p);b.ee=null;b.ce=null;b.fe=null;throw n;})},d.push(h());!Xh(c.i,b.qd)&&(b.qd=c.i)&&(k=Rj(a,b,c.i),l=function(){var n,p,r;return I(function(w){switch(w.g){case 1:return A(w,
331
+ 2),u(w,k,4);case 4:return n=w.h,vf(a.j),p=b.stream.closedCaptions&&0<b.stream.closedCaptions.size,u(w,ri(a.g.V,b.type,n,null,p),5);case 5:va(w,0);break;case 2:throw r=F(w),b.qd=null,r;}})},a.g.Ug(c.startTime,c.i),d.push(l()));return u(m,Promise.all(d),0)})}
332
+ function Qj(a,b,c,d,e,f){var g,h;return I(function(k){if(1==k.g)return g=d.closedCaptions&&0<d.closedCaptions.size,(null!=d.emsgSchemeIdUris&&0<d.emsgSchemeIdUris.length||a.i.dispatchAllEmsgBoxes)&&(new Ag).Y("emsg",function(l){var m=d.emsgSchemeIdUris;if(0===l.version){var n=l.reader.Pc();var p=l.reader.Pc();var r=l.reader.R();var w=l.reader.R();var y=l.reader.R();var x=l.reader.R();var v=e.startTime+w/r}else r=l.reader.R(),v=l.reader.lc()/r+e.timestampOffset,w=v-e.startTime,y=l.reader.R(),x=l.reader.R(),
333
+ n=l.reader.Pc(),p=l.reader.Pc();l=l.reader.Cb(l.reader.W.byteLength-l.reader.oa());if(m&&m.includes(n)||a.i.dispatchAllEmsgBoxes)"urn:mpeg:dash:event:2012"==n?a.g.Vg():(m=(new Map).set("detail",{startTime:v,endTime:v+y/r,schemeIdUri:n,value:p,timescale:r,presentationTimeDelta:w,eventDuration:y,id:x,messageData:l}),m=new L("emsg",m),a.g.onEvent(m))}).parse(f),u(k,Tj(a,b,c),2);if(3!=k.g)return vf(a.j),h=b.Rc,b.Rc=!1,u(k,ri(a.g.V,b.type,f,e,g,h),3);vf(a.j);z(k)})}
334
+ function Tj(a,b,c){var d,e,f,g;return I(function(h){if(1==h.g){d=Math.max(a.i.bufferBehind,a.m.presentationTimeline.g);e=ni(a.g.V,b.type);if(null==e)return h["return"]();f=c-e;g=f-d;return.01>=g?h["return"]():u(h,a.g.V.remove(b.type,e,e+g),2)}vf(a.j);z(h)})}function Lj(a){return a&&a.type==Ib&&("application/cea-608"==a.stream.mimeType||"application/cea-708"==a.stream.mimeType)}
335
+ function Rj(a,b,c,d){var e,f,g,h,k;return I(function(l){if(1==l.g)return e=tf,f=rj(c.Pa(),c.Ta,c.Ca,a.i.retryParameters,d),g=b.stream,a.g.modifySegmentRequest(f,{type:g.type,init:c instanceof Wh,duration:c.endTime-c.startTime,mimeType:g.mimeType,codecs:g.codecs,bandwidth:g.bandwidth}),h=a.g.Ob.request(e,f),b.Ja=h,u(l,h.promise,2);k=l.h;b.Ja=null;return l["return"](k.data)})}
336
+ function Fj(a,b,c,d){var e,f;return I(function(g){if(1==g.g)return b.Sb=!1,b.Id=!1,b.fd=0,b.zc=!0,b.Ra=null,b.qd=null,b.sa=null,d?(e=a.g.ld(),f=a.g.V.getDuration(),u(g,a.g.V.remove(b.type,e+d,f),3)):u(g,yi(a.g.V,b.type),4);if(3!=g.g)return vf(a.j),c?u(g,a.g.V.flush(b.type),3):g.D(3);vf(a.j);b.zc=!1;b.endOfStream=!1;zj(a,b,0);z(g)})}
337
+ function zj(a,b,c){var d=b.type;if(d!=Ib||a.h.has(d))b.eb=(new Pc(function(){var e;return I(function(f){if(1==f.g)return A(f,2),u(f,Ij(a,b),4);if(2!=f.g)return va(f,0);e=F(f);if(a.g)a.g.onError(e);z(f)})})).T(c)}function uj(a){null!=a.eb&&(a.eb.stop(),a.eb=null)}function vj(a){return I(function(b){return a.Ja?u(b,a.Ja.abort(),0):b.D(0)})}function Kj(a,b){return I(function(c){if(1==c.g)return u(c,Xe(a.G),2);vf(a.j);a.g.onError(b);b.handled||a.i.failureCallback(b);z(c)})};function Uj(a,b){var c=Vj(),d=this;this.j=b;this.i=a;this.l=c;this.A=null;this.m=[];this.h=this.g=null;this.C=Promise.resolve().then(function(){return Wj(d)});this.B=new uf(function(){return Xj(d)})}Uj.prototype.destroy=function(){return this.B.destroy()};function Xj(a){var b,c,d;return I(function(e){if(1==e.g)return a.h&&a.h.abort(),Yj(a),u(e,a.C,2);a.g&&a.g.$a.Pb();b=t(a.m);for(c=b.next();!c.done;c=b.next())d=c.value,d.$a.Pb();a.g=null;a.m=[];a.j=null;z(e)})}
338
+ function Zj(a,b){var c={jc:function(){},vd:function(){},Pb:function(){},onError:function(){},xd:function(){},Yi:function(){}};a.m.push({create:b,$a:c});a.h&&a.h.abort();Yj(a);return c}
339
+ function Wj(a){return I(function(b){if(a.B.g)b=b.D(0);else{if(0==a.m.length||a.g&&!a.g.Jb)var c=!1;else{a.g&&(a.g.$a.Pb(),a.g=null);c=a.m.shift();var d=c.create(a.l);d?(c.$a.jc(),a.g={node:d.node,payload:d.payload,Jb:d.Jb,$a:c.$a}):c.$a.xd();c=!0}c?c=Promise.resolve():a.g?c=ak(a):(a.j.Tg(a.i),a.A=new Nc,c=a.A);b=u(b,c,1)}return b})}
340
+ function ak(a){var b,c;return I(function(d){switch(d.g){case 1:return a.i=a.j.zg(a.i,a.l,a.g.node,a.g.payload),A(d,2),a.h=a.j.dg(a.i,a.l,a.g.payload),u(d,a.h.promise,4);case 4:a.h=null;a.i==a.g.node&&(a.g.$a.vd(),a.g=null);va(d,0);break;case 2:b=F(d);if(7001==b.code)a.g.$a.Pb();else a.g.$a.onError(b);a.g=null;a.h=null;c=a;return u(d,a.j.handleError(a.l,b),5);case 5:c.i=d.h,z(d)}})}function Yj(a){a.A&&(a.A.resolve(),a.A=null)};function bk(a){this.g=null;for(var b=t(Array.from(a.textTracks)),c=b.next();!c.done;c=b.next())c=c.value,c.mode="disabled","Shaka Player TextTrack"==c.label&&(this.g=c);this.g||(this.g=a.addTextTrack("subtitles","Shaka Player TextTrack"));this.g.mode="hidden"}q=bk.prototype;q.remove=function(a,b){if(!this.g)return!1;ck(this.g,function(c){return c.startTime<b&&c.endTime>a});return!0};
339
341
  q.append=function(a){function b(g){var h=[],k=700<=g.fontWeight,l="italic"==g.fontStyle,m=g.textDecoration.includes("underline");k&&h.push("b");l&&h.push("i");m&&h.push("u");k=h.reduce(function(n,p){return n+"<"+p+">"},"");h=h.reduceRight(function(n,p){return n+"</"+p+">"},"");return g.lineBreak?"\n":g.nestedCues.length?g.nestedCues.map(b).join(""):k+g.payload+h}var c=a.map(function(g){if(g.nestedCues.length){var h=g.clone();h.nestedCues=[];h.payload=b(g);return h}return g}),d=[];a=this.g.cues?Array.from(this.g.cues):
340
- [];var e={};c=t(c);for(var f=c.next();!f.done;e={Vb:e.Vb},f=c.next())e.Vb=f.value,a.some(function(g){return function(h){return h.startTime==g.Vb.startTime&&h.endTime==g.Vb.endTime&&h.text==g.Vb.payload?!0:!1}}(e))||(f=ak(e.Vb))&&d.push(f);a=d.slice().sort(function(g,h){return g.startTime!=h.startTime?g.startTime-h.startTime:g.endTime!=h.endTime?g.endTime-h.startTime:"line"in VTTCue.prototype?d.indexOf(h)-d.indexOf(g):d.indexOf(g)-d.indexOf(h)});a=t(a);for(e=a.next();!e.done;e=a.next())this.g.addCue(e.value)};
341
- q.destroy=function(){this.g&&(Zj(this.g,function(){return!0}),this.g.mode="disabled");this.g=null;return Promise.resolve()};q.isTextVisible=function(){return"showing"==this.g.mode};q.setTextVisibility=function(a){this.g.mode=a?"showing":"hidden"};
342
- function ak(a){if(a.startTime>=a.endTime)return null;var b=new VTTCue(a.startTime,a.endTime,a.payload);b.lineAlign=a.lineAlign;b.positionAlign=a.positionAlign;a.size&&(b.size=a.size);try{b.align=a.textAlign}catch(c){}"center"==a.textAlign&&"center"!=b.align&&(b.align="middle");"vertical-lr"==a.writingMode?b.vertical="lr":"vertical-rl"==a.writingMode&&(b.vertical="rl");1==a.lineInterpretation&&(b.snapToLines=!1);null!=a.line&&(b.line=a.line);null!=a.position&&(b.position=a.position);return b}
343
- function Zj(a,b){var c=a.mode;a.mode="showing"==c?"showing":"hidden";for(var d=t(Array.from(a.cues)),e=d.next();!e.done;e=d.next())(e=e.value)&&b(e)&&a.removeCue(e);a.mode=c}J("shaka.text.SimpleTextDisplayer",Yj);Yj.prototype.setTextVisibility=Yj.prototype.setTextVisibility;Yj.prototype.isTextVisible=Yj.prototype.isTextVisible;Yj.prototype.destroy=Yj.prototype.destroy;Yj.prototype.append=Yj.prototype.append;Yj.prototype.remove=Yj.prototype.remove;function bk(){}function R(a){return document.createElement(a)}function ck(){return document.createElement("button")}function dk(a){for(;a.firstChild;)a.removeChild(a.firstChild)}J("shaka.util.Dom",bk);bk.removeAllChildren=dk;function ek(a,b){var c=this;this.j=!1;this.i=[];this.C=a;this.m=b;this.g=R("div");this.g.classList.add("shaka-text-container");this.g.style.textAlign="center";this.g.style.display="flex";this.g.style.flexDirection="column";this.g.style.alignItems="center";this.g.style.justifyContent="flex-end";this.m.appendChild(this.g);this.B=(new P(function(){fk(c)})).ka(.25);this.h=new Map;this.A=new tf;this.A.o(document,"fullscreenchange",function(){fk(c,!0)});this.l=null;"ResizeObserver"in window&&(this.l=new ResizeObserver(function(){fk(c,
344
- !0)}),this.l.observe(this.g))}q=ek.prototype;q.append=function(a){var b=[].concat(ia(this.i)),c={};a=t(a);for(var d=a.next();!d.done;c={Wc:c.Wc},d=a.next())c.Wc=d.value,b.some(function(e){return function(f){return uc(f,e.Wc)}}(c))||this.i.push(c.Wc);fk(this)};q.destroy=function(){this.m.removeChild(this.g);this.g=null;this.j=!1;this.i=[];this.B&&this.B.stop();this.h.clear();this.A&&(this.A.release(),this.A=null);this.l&&(this.l.disconnect(),this.l=null)};
345
- q.remove=function(a,b){if(!this.g)return!1;var c=this.i.length;this.i=this.i.filter(function(d){return d.startTime<a||d.endTime>=b});fk(this,c>this.i.length);return!0};q.isTextVisible=function(){return this.j};q.setTextVisibility=function(a){this.j=a};
346
- function gk(a,b,c,d,e){var f=!1,g=[],h=[];b=t(b);for(var k=b.next();!k.done;k=b.next()){k=k.value;e.push(k);var l=a.h.get(k),m=k.startTime<=d&&k.endTime>d,n=l?l.Nf:null;l&&(g.push(l.ef),m||(f=!0,a.h["delete"](k),l=null));m&&(h.push(k),l||(hk(a,k,e),l=a.h.get(k),n=l.Nf,f=!0));0<k.nestedCues.length&&n&&gk(a,k.nestedCues,n,d,e);e.pop()}if(f){d=t(g);for(e=d.next();!e.done;e=d.next())c.removeChild(e.value);h.sort(function(p,r){return p.startTime!=r.startTime?p.startTime-r.startTime:p.endTime-r.endTime});
347
- h=t(h);for(k=h.next();!k.done;k=h.next())d=a.h.get(k.value),c.appendChild(d.ef)}}function fk(a,b){if(a.g){var c=a.C.currentTime;(!a.j||(void 0===b?0:b))&&0<a.h.size&&(dk(a.g),a.h.clear());if(a.j){for(var d=new Map,e=t(a.h.keys()),f=e.next();!f.done;f=e.next())f=f.value,d.set(f,a.h.get(f));gk(a,a.i,a.g,c,[])}}}
348
- function hk(a,b,c){var d=1<c.length,e=d?"span":"div";b.lineBreak&&(e="br");d=!d&&0<b.nestedCues.length;var f=R(e);"br"!=e&&ik(a,f,b,c,d);c=f;d&&(c=R("span"),c.classList.add("shaka-text-wrapper"),c.style.backgroundColor=b.backgroundColor,f.appendChild(c));a.h.set(b,{ef:f,Nf:c})}
349
- function ik(a,b,c,d,e){var f=b.style,g=0==c.nestedCues.length,h=1<d.length;f.whiteSpace="pre-wrap";var k=c.payload.replace(/\s+$/g,function(m){return"\u00a0".repeat(m.length)});f.webkitTextStrokeColor=c.textStrokeColor;f.webkitTextStrokeWidth=c.textStrokeWidth;f.color=c.color;f.direction=c.direction;f.opacity=c.opacity;f.paddingLeft=jk(c.linePadding,c,a.m);f.paddingRight=jk(c.linePadding,c,a.m);f.textShadow=c.textShadow;if(c.backgroundImage)f.backgroundImage="url('"+c.backgroundImage+"')",f.backgroundRepeat=
350
- "no-repeat",f.backgroundSize="contain",f.backgroundPosition="center";else{if(c.nestedCues.length)var l=b;else l=R("span"),b.appendChild(l);c.border&&(l.style.border=c.border);e||((b=kk(d,function(m){return m.backgroundColor}))?l.style.backgroundColor=b:k&&(l.style.backgroundColor="rgba(0, 0, 0, 0.8)"));k&&(l.textContent=k)}h&&!d[d.length-1].isContainer?f.display="inline":(f.display="flex",f.flexDirection="column",f.alignItems="center",f.justifyContent="before"==c.displayAlign?"flex-start":"center"==
351
- c.displayAlign?"center":"flex-end");g||(f.margin="0");f.fontFamily=c.fontFamily;f.fontWeight=c.fontWeight.toString();f.fontStyle=c.fontStyle;f.letterSpacing=c.letterSpacing;f.fontSize=jk(c.fontSize,c,a.m);c.line?1==c.lineInterpretation&&(f.position="absolute",f.left="0",f.top="0",c.writingMode==lc?(f.width="100%",c.lineAlign==nc?f.top=c.line+"%":"end"==c.lineAlign&&(f.bottom=c.line+"%")):"vertical-lr"==c.writingMode?(f.height="100%",c.lineAlign==nc?f.left=c.line+"%":"end"==c.lineAlign&&(f.right=c.line+
342
+ [];var e={};c=t(c);for(var f=c.next();!f.done;e={Vb:e.Vb},f=c.next())e.Vb=f.value,a.some(function(g){return function(h){return h.startTime==g.Vb.startTime&&h.endTime==g.Vb.endTime&&h.text==g.Vb.payload?!0:!1}}(e))||(f=dk(e.Vb))&&d.push(f);a=d.slice().sort(function(g,h){return g.startTime!=h.startTime?g.startTime-h.startTime:g.endTime!=h.endTime?g.endTime-h.startTime:"line"in VTTCue.prototype?d.indexOf(h)-d.indexOf(g):d.indexOf(g)-d.indexOf(h)});a=t(a);for(e=a.next();!e.done;e=a.next())this.g.addCue(e.value)};
343
+ q.destroy=function(){this.g&&(ck(this.g,function(){return!0}),this.g.mode="disabled");this.g=null;return Promise.resolve()};q.isTextVisible=function(){return"showing"==this.g.mode};q.setTextVisibility=function(a){this.g.mode=a?"showing":"hidden"};
344
+ function dk(a){if(a.startTime>=a.endTime)return null;var b=new VTTCue(a.startTime,a.endTime,a.payload);b.lineAlign=a.lineAlign;b.positionAlign=a.positionAlign;a.size&&(b.size=a.size);try{b.align=a.textAlign}catch(c){}"center"==a.textAlign&&"center"!=b.align&&(b.align="middle");"vertical-lr"==a.writingMode?b.vertical="lr":"vertical-rl"==a.writingMode&&(b.vertical="rl");1==a.lineInterpretation&&(b.snapToLines=!1);null!=a.line&&(b.line=a.line);null!=a.position&&(b.position=a.position);return b}
345
+ function ck(a,b){var c=a.mode;a.mode="showing"==c?"showing":"hidden";for(var d=t(Array.from(a.cues)),e=d.next();!e.done;e=d.next())(e=e.value)&&b(e)&&a.removeCue(e);a.mode=c}J("shaka.text.SimpleTextDisplayer",bk);bk.prototype.setTextVisibility=bk.prototype.setTextVisibility;bk.prototype.isTextVisible=bk.prototype.isTextVisible;bk.prototype.destroy=bk.prototype.destroy;bk.prototype.append=bk.prototype.append;bk.prototype.remove=bk.prototype.remove;function ek(){}function R(a){return document.createElement(a)}function fk(){return document.createElement("button")}function gk(a){for(;a.firstChild;)a.removeChild(a.firstChild)}J("shaka.util.Dom",ek);ek.removeAllChildren=gk;function hk(a,b){var c=this;this.j=!1;this.i=[];this.C=a;this.m=b;this.g=R("div");this.g.classList.add("shaka-text-container");this.g.style.textAlign="center";this.g.style.display="flex";this.g.style.flexDirection="column";this.g.style.alignItems="center";this.g.style.justifyContent="flex-end";this.m.appendChild(this.g);this.B=(new P(function(){ik(c)})).ka(.25);this.h=new Map;this.A=new wf;this.A.o(document,"fullscreenchange",function(){ik(c,!0)});this.l=null;"ResizeObserver"in window&&(this.l=new ResizeObserver(function(){ik(c,
346
+ !0)}),this.l.observe(this.g))}q=hk.prototype;q.append=function(a){var b=[].concat(ia(this.i)),c={};a=t(a);for(var d=a.next();!d.done;c={Wc:c.Wc},d=a.next())c.Wc=d.value,b.some(function(e){return function(f){return uc(f,e.Wc)}}(c))||this.i.push(c.Wc);ik(this)};q.destroy=function(){this.m.removeChild(this.g);this.g=null;this.j=!1;this.i=[];this.B&&this.B.stop();this.h.clear();this.A&&(this.A.release(),this.A=null);this.l&&(this.l.disconnect(),this.l=null)};
347
+ q.remove=function(a,b){if(!this.g)return!1;var c=this.i.length;this.i=this.i.filter(function(d){return d.startTime<a||d.endTime>=b});ik(this,c>this.i.length);return!0};q.isTextVisible=function(){return this.j};q.setTextVisibility=function(a){this.j=a};
348
+ function jk(a,b,c,d,e){var f=!1,g=[],h=[];b=t(b);for(var k=b.next();!k.done;k=b.next()){k=k.value;e.push(k);var l=a.h.get(k),m=k.startTime<=d&&k.endTime>d,n=l?l.Of:null;l&&(g.push(l.gf),m||(f=!0,a.h["delete"](k),l=null));m&&(h.push(k),l||(kk(a,k,e),l=a.h.get(k),n=l.Of,f=!0));0<k.nestedCues.length&&n&&jk(a,k.nestedCues,n,d,e);e.pop()}if(f){d=t(g);for(e=d.next();!e.done;e=d.next())c.removeChild(e.value);h.sort(function(p,r){return p.startTime!=r.startTime?p.startTime-r.startTime:p.endTime-r.endTime});
349
+ h=t(h);for(k=h.next();!k.done;k=h.next())d=a.h.get(k.value),c.appendChild(d.gf)}}function ik(a,b){if(a.g){var c=a.C.currentTime;(!a.j||(void 0===b?0:b))&&0<a.h.size&&(gk(a.g),a.h.clear());if(a.j){for(var d=new Map,e=t(a.h.keys()),f=e.next();!f.done;f=e.next())f=f.value,d.set(f,a.h.get(f));jk(a,a.i,a.g,c,[])}}}
350
+ function kk(a,b,c){var d=1<c.length,e=d?"span":"div";b.lineBreak&&(e="br");d=!d&&0<b.nestedCues.length;var f=R(e);"br"!=e&&lk(a,f,b,c,d);c=f;d&&(c=R("span"),c.classList.add("shaka-text-wrapper"),c.style.backgroundColor=b.backgroundColor,f.appendChild(c));a.h.set(b,{gf:f,Of:c})}
351
+ function lk(a,b,c,d,e){var f=b.style,g=0==c.nestedCues.length,h=1<d.length;f.whiteSpace="pre-wrap";var k=c.payload.replace(/\s+$/g,function(m){return"\u00a0".repeat(m.length)});f.webkitTextStrokeColor=c.textStrokeColor;f.webkitTextStrokeWidth=c.textStrokeWidth;f.color=c.color;f.direction=c.direction;f.opacity=c.opacity;f.paddingLeft=mk(c.linePadding,c,a.m);f.paddingRight=mk(c.linePadding,c,a.m);f.textShadow=c.textShadow;if(c.backgroundImage)f.backgroundImage="url('"+c.backgroundImage+"')",f.backgroundRepeat=
352
+ "no-repeat",f.backgroundSize="contain",f.backgroundPosition="center";else{if(c.nestedCues.length)var l=b;else l=R("span"),b.appendChild(l);c.border&&(l.style.border=c.border);e||((b=nk(d,function(m){return m.backgroundColor}))?l.style.backgroundColor=b:k&&(l.style.backgroundColor="rgba(0, 0, 0, 0.8)"));k&&(l.textContent=k)}h&&!d[d.length-1].isContainer?f.display="inline":(f.display="flex",f.flexDirection="column",f.alignItems="center",f.justifyContent="before"==c.displayAlign?"flex-start":"center"==
353
+ c.displayAlign?"center":"flex-end");g||(f.margin="0");f.fontFamily=c.fontFamily;f.fontWeight=c.fontWeight.toString();f.fontStyle=c.fontStyle;f.letterSpacing=c.letterSpacing;f.fontSize=mk(c.fontSize,c,a.m);c.line?1==c.lineInterpretation&&(f.position="absolute",f.left="0",f.top="0",c.writingMode==lc?(f.width="100%",c.lineAlign==nc?f.top=c.line+"%":"end"==c.lineAlign&&(f.bottom=c.line+"%")):"vertical-lr"==c.writingMode?(f.height="100%",c.lineAlign==nc?f.left=c.line+"%":"end"==c.lineAlign&&(f.right=c.line+
352
354
  "%")):(f.height="100%",c.lineAlign==nc?f.right=c.line+"%":"end"==c.lineAlign&&(f.left=c.line+"%"))):c.region&&c.region.id&&(a=c.region.widthUnits==Bc?"%":"px",d=c.region.viewportAnchorUnits==Bc?"%":"px",f.height=c.region.height+(c.region.heightUnits==Bc?"%":"px"),f.width=c.region.width+a,f.position="absolute",f.top=c.region.viewportAnchorY+d,f.left=c.region.viewportAnchorX+d);f.lineHeight=c.lineHeight;c.position&&(c.writingMode==lc?f.paddingLeft=c.position:f.paddingTop=c.position);"line-left"==c.positionAlign?
353
355
  f.cssFloat="left":"line-right"==c.positionAlign&&(f.cssFloat="right");f.textAlign=c.textAlign;f.textDecoration=c.textDecoration.join(" ");f.writingMode=c.writingMode;"writingMode"in document.documentElement.style&&f.writingMode==c.writingMode||(f.webkitWritingMode=c.writingMode);c.size&&(c.writingMode==lc?f.width=c.size+"%":f.height=c.size+"%")}
354
- function jk(a,b,c){var d=(d=(new RegExp(/(\d*\.?\d+)([a-z]+|%+)/)).exec(a))?{value:Number(d[1]),unit:d[2]}:null;if(!d)return a;var e=d.value;switch(d.unit){case "%":return e/100*c.clientHeight/b.cellResolution.rows+"px";case "c":return c.clientHeight*e/b.cellResolution.rows+"px";default:return a}}function kk(a,b){for(var c=a.length-1;0<=c;c--){var d=b(a[c]);if(d||0===d)return d}return null}J("shaka.text.UITextDisplayer",ek);ek.prototype.setTextVisibility=ek.prototype.setTextVisibility;
355
- ek.prototype.isTextVisible=ek.prototype.isTextVisible;ek.prototype.remove=ek.prototype.remove;ek.prototype.destroy=ek.prototype.destroy;ek.prototype.append=ek.prototype.append;function lk(a,b){function c(h){for(var k=h,l=t(b),m=l.next();!m.done;m=l.next())m=m.value,m.end&&m.start<h&&(k+=m.end-m.start);h=Math.floor(k/3600);l=Math.floor(k/60%60);m=Math.floor(k%60);k=Math.floor(1E3*k%1E3);return(10>h?"0":"")+h+":"+(10>l?"0":"")+l+":"+(10>m?"0":"")+m+"."+(100>k?10>k?"00":"0":"")+k}function d(h){var k=[],l=700<=h.fontWeight,m="italic"==h.fontStyle,n=h.textDecoration.includes("underline");l&&k.push("b");m&&k.push("i");n&&k.push("u");l=k.reduce(function(p,r){return p+"<"+r+">"},
356
+ function mk(a,b,c){var d=(d=(new RegExp(/(\d*\.?\d+)([a-z]+|%+)/)).exec(a))?{value:Number(d[1]),unit:d[2]}:null;if(!d)return a;var e=d.value;switch(d.unit){case "%":return e/100*c.clientHeight/b.cellResolution.rows+"px";case "c":return c.clientHeight*e/b.cellResolution.rows+"px";default:return a}}function nk(a,b){for(var c=a.length-1;0<=c;c--){var d=b(a[c]);if(d||0===d)return d}return null}J("shaka.text.UITextDisplayer",hk);hk.prototype.setTextVisibility=hk.prototype.setTextVisibility;
357
+ hk.prototype.isTextVisible=hk.prototype.isTextVisible;hk.prototype.remove=hk.prototype.remove;hk.prototype.destroy=hk.prototype.destroy;hk.prototype.append=hk.prototype.append;function ok(a,b){function c(h){for(var k=h,l=t(b),m=l.next();!m.done;m=l.next())m=m.value,m.end&&m.start<h&&(k+=m.end-m.start);h=Math.floor(k/3600);l=Math.floor(k/60%60);m=Math.floor(k%60);k=Math.floor(1E3*k%1E3);return(10>h?"0":"")+h+":"+(10>l?"0":"")+l+":"+(10>m?"0":"")+m+"."+(100>k?10>k?"00":"0":"")+k}function d(h){var k=[],l=700<=h.fontWeight,m="italic"==h.fontStyle,n=h.textDecoration.includes("underline");l&&k.push("b");m&&k.push("i");n&&k.push("u");l=k.reduce(function(p,r){return p+"<"+r+">"},
356
358
  "");k=k.reduceRight(function(p,r){return p+"</"+r+">"},"");return h.lineBreak?"\n":h.nestedCues.length?h.nestedCues.map(d).join(""):l+h.payload+k}var e=a.map(function(h){if(h.nestedCues.length){var k=h.clone();k.nestedCues=[];k.payload=d(h);return k}return h}),f="WEBVTT\n\n";e=t(e);for(var g=e.next();!g.done;g=e.next())g=g.value,f+=c(g.startTime)+" --\x3e "+c(g.endTime)+function(h){var k=[];switch(h.textAlign){case "left":k.push("align:left");break;case "right":k.push("align:right");break;case kc:k.push("align:middle");
357
- break;case "start":k.push("align:start");break;case "end":k.push("align:end")}switch(h.writingMode){case "vertical-lr":k.push("vertical:lr");break;case "vertical-rl":k.push("vertical:rl")}return k.length?" "+k.join(" "):""}(g)+"\n",f+=g.payload+"\n\n";return f}J("shaka.text.WebVttGenerator",function(){});function mk(a,b){this.h=a;this.g=b;this.j="";this.A=void 0;this.i=!1;this.m=!0;this.l=!1}function nk(a,b,c){try{if(a.g.enabled){var d={d:1E3*c.duration,st:a.h.U()?ok:pk};d.ot=qk(c);var e=d.ot===rk||d.ot===sk||d.ot===tk||d.ot===uk;e&&(d.bl=vk(a,c.type));c.bandwidth&&(d.br=c.bandwidth/1E3);e&&d.ot!==uk&&(d.tb=wk(a,d.ot)/1E3);xk(a,b,d)}}catch(f){Va("CMCD_SEGMENT_ERROR","Could not generate segment CMCD data.",f)}}
358
- function yk(a,b,c){try{if(!a.g.enabled)return b;var d=zk(a);a:{switch(c){case "video/webm":case "video/mp4":var e=tk;break a;case "application/x-mpegurl":e=Ak;break a}e=void 0}d.ot=e;d.su=!0;var f=Bk(d);return Ck(b,f)}catch(g){return Va("CMCD_SRC_ERROR","Could not generate src CMCD data.",g),b}}function zk(a){a.j||(a.j=a.g.sessionId||window.crypto.randomUUID());return{v:1,sf:a.A,sid:a.j,cid:a.g.contentId,mtp:a.h.getBandwidthEstimate()/1E3}}
359
- function xk(a,b,c){c=void 0===c?{}:c;var d=void 0===d?a.g.useHeaders:d;if(a.g.enabled){Object.assign(c,zk(a));c.pr=a.h.zb();var e=c.ot===rk||c.ot===tk;a.l&&e&&(c.bs=!0,c.su=!0,a.l=!1);null==c.su&&(c.su=a.m);if(d)a=Dk(c),Object.keys(a).length&&Object.assign(b.headers,a);else{var f=Bk(c);f&&(b.uris=b.uris.map(function(g){return Ck(g,f)}))}}}
360
- function qk(a){var b=a.type;if(a.init)return Ek;if("video"==b)return a.codecs.includes(",")?tk:rk;if("audio"==b)return sk;if("text"==b)return"application/mp4"===a.mimeType?uk:Fk}function vk(a,b){var c=a.h.kb()[b];if(!c.length)return NaN;var d=a.h.getCurrentTime();return(c=c.find(function(e){return e.start<=d&&e.end>=d}))?1E3*(c.end-d):NaN}
361
- function wk(a,b){var c=a.h.Qa();if(!c.length)return NaN;var d=c[0];c=t(c);for(var e=c.next();!e.done;e=c.next())e=e.value,"variant"===e.type&&e.bandwidth>d.bandwidth&&(d=e);switch(b){case rk:return d.videoBandwidth||NaN;case sk:return d.audioBandwidth||NaN;default:return d.bandwidth}}
362
- function Bk(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"===
363
- l?h:"symbol"===l?h+"="+k.description:h+"="+k;e.push(m)}}return e.join(",")}function Dk(a){var b=Object.keys(a),c={},d=["Object","Request","Session","Status"],e=[{},{},{},{}],f={br:0,d:0,ot:0,tb:0,bl:1,dl:1,mtp:1,nor:1,nrr:1,su:1,cid:2,pr:2,sf:2,sid:2,st:2,v:2,bs:3,rtp:3};b=t(b);for(var g=b.next();!g.done;g=b.next())g=g.value,e[null!=f[g]?f[g]:1][g]=a[g];for(a=0;a<e.length;a++)(f=Bk(e[a]))&&(c["CMCD-"+d[a]]=f);return c}
364
- function Ck(a,b){if(!b||a.includes("offline:"))return a;var c=new lb(a);c.g.set("CMCD",b);return c.toString()}var Ak="m",sk="a",rk="v",tk="av",Ek="i",Fk="c",uk="tt",pk="v",ok="l";J("shaka.util.CmcdManager.StreamingFormat",{Gh:"d",Vh:"h",Di:"s",ki:"o"});function Gk(){}
365
- function Hk(a,b,c,d,e){var f=e in d,g=!0,h;for(h in b){var k=e+"."+h,l=f?d[e]:c[h];f||h in c?void 0===b[h]?void 0===l||f?delete a[h]:a[h]=bf(l):l.constructor==Object&&b[h]&&b[h].constructor==Object?(a[h]||(a[h]=bf(l)),k=Hk(a[h],b[h],l,d,k),g=g&&k):typeof b[h]!=typeof l||null==b[h]||"function"!=typeof b[h]&&b[h].constructor!=l.constructor?(Ta("Invalid config, wrong type for "+k),g=!1):("function"==typeof c[h]&&c[h].length!=b[h].length&&Ua("Unexpected number of arguments for "+k),a[h]=b[h]):(Ta("Invalid config, unrecognized key "+
366
- k),g=!1)}return g}function Ik(a,b){for(var c={},d=c,e=0,f=0;;){e=a.indexOf(".",e);if(0>e)break;if(0==e||"\\"!=a[e-1])f=a.substring(f,e).replace(/\\\./g,"."),d[f]={},d=d[f],f=e+1;e+=1}d[a.substring(f).replace(/\\\./g,".")]=b;return c}function Jk(a,b){return a&&b}J("shaka.util.ConfigUtils",Gk);Gk.convertToConfigObject=Ik;Gk.mergeConfigObjects=Hk;function Kk(){}
367
- function Lk(){var a=Infinity;navigator.connection&&navigator.connection.saveData&&(a=360);var b={retryParameters:Te(),servers:{},clearKeys:{},advanced:{},delayLicenseRequestUntilPlayed:!1,initDataTransform:function(g,h,k){return Jk([g,h,k],g)},logLicenseExchange:!1,updateExpirationTime:1,preferredKeySystems:[],keySystemsMapping:{}},c={retryParameters:Te(),availabilityWindowOverride:NaN,disableAudio:!1,disableVideo:!1,disableText:!1,disableThumbnails:!1,defaultPresentationDelay:0,segmentRelativeVttTiming:!1,dash:{clockSyncUri:"",
359
+ break;case "start":k.push("align:start");break;case "end":k.push("align:end")}switch(h.writingMode){case "vertical-lr":k.push("vertical:lr");break;case "vertical-rl":k.push("vertical:rl")}return k.length?" "+k.join(" "):""}(g)+"\n",f+=g.payload+"\n\n";return f}J("shaka.text.WebVttGenerator",function(){});function pk(a,b){this.h=a;this.g=b;this.j="";this.A=void 0;this.i=!1;this.m=!0;this.l=!1}function qk(a,b,c){try{if(a.g.enabled){var d={d:1E3*c.duration,st:a.h.U()?rk:sk};d.ot=tk(c);var e=d.ot===uk||d.ot===vk||d.ot===wk||d.ot===xk;e&&(d.bl=yk(a,c.type));c.bandwidth&&(d.br=c.bandwidth/1E3);e&&d.ot!==xk&&(d.tb=zk(a,d.ot)/1E3);Ak(a,b,d)}}catch(f){Va("CMCD_SEGMENT_ERROR","Could not generate segment CMCD data.",f)}}
360
+ function Bk(a,b,c){try{if(!a.g.enabled)return b;var d=Ck(a);a:{switch(c){case "video/webm":case "video/mp4":var e=wk;break a;case "application/x-mpegurl":e=Dk;break a}e=void 0}d.ot=e;d.su=!0;var f=Ek(d);return Fk(b,f)}catch(g){return Va("CMCD_SRC_ERROR","Could not generate src CMCD data.",g),b}}function Ck(a){a.j||(a.j=a.g.sessionId||window.crypto.randomUUID());return{v:1,sf:a.A,sid:a.j,cid:a.g.contentId,mtp:a.h.getBandwidthEstimate()/1E3}}
361
+ function Ak(a,b,c){c=void 0===c?{}:c;var d=void 0===d?a.g.useHeaders:d;if(a.g.enabled){Object.assign(c,Ck(a));c.pr=a.h.zb();var e=c.ot===uk||c.ot===wk;a.l&&e&&(c.bs=!0,c.su=!0,a.l=!1);null==c.su&&(c.su=a.m);if(d)a=Gk(c),Object.keys(a).length&&Object.assign(b.headers,a);else{var f=Ek(c);f&&(b.uris=b.uris.map(function(g){return Fk(g,f)}))}}}
362
+ function tk(a){var b=a.type;if(a.init)return Hk;if("video"==b)return a.codecs.includes(",")?wk:uk;if("audio"==b)return vk;if("text"==b)return"application/mp4"===a.mimeType?xk:Ik}function yk(a,b){var c=a.h.kb()[b];if(!c.length)return NaN;var d=a.h.getCurrentTime();return(c=c.find(function(e){return e.start<=d&&e.end>=d}))?1E3*(c.end-d):NaN}
363
+ function zk(a,b){var c=a.h.Qa();if(!c.length)return NaN;var d=c[0];c=t(c);for(var e=c.next();!e.done;e=c.next())e=e.value,"variant"===e.type&&e.bandwidth>d.bandwidth&&(d=e);switch(b){case uk:return d.videoBandwidth||NaN;case vk:return d.audioBandwidth||NaN;default:return d.bandwidth}}
364
+ function Ek(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"===
365
+ l?h:"symbol"===l?h+"="+k.description:h+"="+k;e.push(m)}}return e.join(",")}function Gk(a){var b=Object.keys(a),c={},d=["Object","Request","Session","Status"],e=[{},{},{},{}],f={br:0,d:0,ot:0,tb:0,bl:1,dl:1,mtp:1,nor:1,nrr:1,su:1,cid:2,pr:2,sf:2,sid:2,st:2,v:2,bs:3,rtp:3};b=t(b);for(var g=b.next();!g.done;g=b.next())g=g.value,e[null!=f[g]?f[g]:1][g]=a[g];for(a=0;a<e.length;a++)(f=Ek(e[a]))&&(c["CMCD-"+d[a]]=f);return c}
366
+ function Fk(a,b){if(!b||a.includes("offline:"))return a;var c=new lb(a);c.g.set("CMCD",b);return c.toString()}var Dk="m",vk="a",uk="v",wk="av",Hk="i",Ik="c",xk="tt",sk="v",rk="l";J("shaka.util.CmcdManager.StreamingFormat",{Hh:"d",Wh:"h",Ei:"s",li:"o"});function Jk(){}
367
+ function Kk(a,b,c,d,e){var f=e in d,g=!0,h;for(h in b){var k=e+"."+h,l=f?d[e]:c[h];f||h in c?void 0===b[h]?void 0===l||f?delete a[h]:a[h]=ef(l):l.constructor==Object&&b[h]&&b[h].constructor==Object?(a[h]||(a[h]=ef(l)),k=Kk(a[h],b[h],l,d,k),g=g&&k):typeof b[h]!=typeof l||null==b[h]||"function"!=typeof b[h]&&b[h].constructor!=l.constructor?(Ta("Invalid config, wrong type for "+k),g=!1):("function"==typeof c[h]&&c[h].length!=b[h].length&&Ua("Unexpected number of arguments for "+k),a[h]=b[h]):(Ta("Invalid config, unrecognized key "+
368
+ k),g=!1)}return g}function Lk(a,b){for(var c={},d=c,e=0,f=0;;){e=a.indexOf(".",e);if(0>e)break;if(0==e||"\\"!=a[e-1])f=a.substring(f,e).replace(/\\\./g,"."),d[f]={},d=d[f],f=e+1;e+=1}d[a.substring(f).replace(/\\\./g,".")]=b;return c}function Mk(a,b){return a&&b}J("shaka.util.ConfigUtils",Jk);Jk.convertToConfigObject=Lk;Jk.mergeConfigObjects=Kk;function Nk(){}
369
+ function Ok(){var a=Infinity;navigator.connection&&navigator.connection.saveData&&(a=360);var b={retryParameters:We(),servers:{},clearKeys:{},advanced:{},delayLicenseRequestUntilPlayed:!1,initDataTransform:function(g,h,k){return Mk([g,h,k],g)},logLicenseExchange:!1,updateExpirationTime:1,preferredKeySystems:[],keySystemsMapping:{}},c={retryParameters:We(),availabilityWindowOverride:NaN,disableAudio:!1,disableVideo:!1,disableText:!1,disableThumbnails:!1,defaultPresentationDelay:0,segmentRelativeVttTiming:!1,dash:{clockSyncUri:"",
368
370
  ignoreDrmInfo:!1,disableXlinkProcessing:!1,xlinkFailGracefully:!1,ignoreMinBufferTime:!1,autoCorrectDrift:!0,initialSegmentLimit:1E3,ignoreSuggestedPresentationDelay:!1,ignoreEmptyAdaptationSet:!1,ignoreMaxSegmentDuration:!1,keySystemsByURI:{"urn:uuid:1077efec-c0b2-4d02-ace3-3c1e52e2fb4b":"org.w3.clearkey","urn:uuid:e2719d58-a985-b3c9-781a-b030af78d30e":"org.w3.clearkey","urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":"com.widevine.alpha","urn:uuid:9a04f079-9840-4286-ab92-e65be0885f95":"com.microsoft.playready",
369
- "urn:uuid:79f0049a-4098-8642-ab92-e65be0885f95":"com.microsoft.playready","urn:uuid:f239e769-efa3-4850-9c16-a903c6932efb":"com.adobe.primetime"},manifestPreprocessor:function(g){return Jk([g],g)}},hls:{ignoreTextStreamFailures:!1,ignoreImageStreamFailures:!1,defaultAudioCodec:"mp4a.40.2",defaultVideoCodec:"avc1.42E01E",ignoreManifestProgramDateTime:!1,mediaPlaylistFullMimeType:'video/mp2t; codecs="avc1.42E01E, mp4a.40.2"'}},d={retryParameters:Te(),failureCallback:function(g){return Jk([g],void 0)},
371
+ "urn:uuid:79f0049a-4098-8642-ab92-e65be0885f95":"com.microsoft.playready","urn:uuid:f239e769-efa3-4850-9c16-a903c6932efb":"com.adobe.primetime"},manifestPreprocessor:function(g){return Mk([g],g)}},hls:{ignoreTextStreamFailures:!1,ignoreImageStreamFailures:!1,defaultAudioCodec:"mp4a.40.2",defaultVideoCodec:"avc1.42E01E",ignoreManifestProgramDateTime:!1,mediaPlaylistFullMimeType:'video/mp2t; codecs="avc1.42E01E, mp4a.40.2"'}},d={retryParameters:We(),failureCallback:function(g){return Mk([g],void 0)},
370
372
  rebufferingGoal:2,bufferingGoal:10,bufferBehind:30,ignoreTextStreamFailures:!1,alwaysStreamText:!1,startAtSegmentBoundary:!1,gapDetectionThreshold:.1,durationBackoff:1,forceTransmuxTS:!1,safeSeekOffset:5,stallEnabled:!0,stallThreshold:1,stallSkip:.1,useNativeHlsOnSafari:!0,inaccurateManifestTolerance:2,lowLatencyMode:!1,autoLowLatencyMode:!1,forceHTTPS:!1,preferNativeHls:!1,updateIntervalSeconds:1,dispatchAllEmsgBoxes:!1,observeQualityChanges:!1,maxDisabledTime:30};if(navigator.userAgent.match(/Edge\//)||
371
- Gd()||Hd())d.gapDetectionThreshold=.5;if(Fd("Web0S")||Gd()||Hd())d.stallSkip=0;var e={trackSelectionCallback:function(g){return I(function(h){return h["return"](g)})},downloadSizeCallback:function(g){var h;return I(function(k){if(1==k.g)return navigator.storage&&navigator.storage.estimate?u(k,navigator.storage.estimate(),3):k["return"](!0);h=k.h;return k["return"](h.usage+g<.95*h.quota)})},progressCallback:function(g,h){return Jk([g,h],void 0)},usePersistentLicense:!0,numberOfParallelDownloads:5},
372
- f={drm:b,manifest:c,streaming:d,offline:e,abrFactory:function(){return new Be},abr:{enabled:!0,useNetworkInformation:!0,defaultBandwidthEstimate:1E6,switchInterval:8,bandwidthUpgradeTarget:.85,bandwidthDowngradeTarget:.95,restrictions:{minWidth:0,maxWidth:Infinity,minHeight:0,maxHeight:a,minPixels:0,maxPixels:Infinity,minFrameRate:0,maxFrameRate:Infinity,minBandwidth:0,maxBandwidth:Infinity},advanced:{minTotalBytes:128E3,minBytes:16E3,fastHalfLife:2,slowHalfLife:5}},preferredAudioLanguage:"",preferredTextLanguage:"",
373
+ Wc()||Yc())d.gapDetectionThreshold=.5;if(Vc("Web0S")||Wc()||Yc())d.stallSkip=0;var e={trackSelectionCallback:function(g){return I(function(h){return h["return"](g)})},downloadSizeCallback:function(g){var h;return I(function(k){if(1==k.g)return navigator.storage&&navigator.storage.estimate?u(k,navigator.storage.estimate(),3):k["return"](!0);h=k.h;return k["return"](h.usage+g<.95*h.quota)})},progressCallback:function(g,h){return Mk([g,h],void 0)},usePersistentLicense:!0,numberOfParallelDownloads:5},
374
+ f={drm:b,manifest:c,streaming:d,offline:e,abrFactory:function(){return new Fe},abr:{enabled:!0,useNetworkInformation:!0,defaultBandwidthEstimate:1E6,switchInterval:8,bandwidthUpgradeTarget:.85,bandwidthDowngradeTarget:.95,restrictions:{minWidth:0,maxWidth:Infinity,minHeight:0,maxHeight:a,minPixels:0,maxPixels:Infinity,minFrameRate:0,maxFrameRate:Infinity,minBandwidth:0,maxBandwidth:Infinity},advanced:{minTotalBytes:128E3,minBytes:16E3,fastHalfLife:2,slowHalfLife:5}},preferredAudioLanguage:"",preferredTextLanguage:"",
373
375
  preferredVariantRole:"",preferredTextRole:"",preferredAudioChannelCount:2,preferredVideoCodecs:[],preferredAudioCodecs:[],preferForcedSubs:!1,preferredDecodingAttributes:[],restrictions:{minWidth:0,maxWidth:Infinity,minHeight:0,maxHeight:Infinity,minPixels:0,maxPixels:Infinity,minFrameRate:0,maxFrameRate:Infinity,minBandwidth:0,maxBandwidth:Infinity},playRangeStart:0,playRangeEnd:Infinity,textDisplayFactory:function(){return null},cmcd:{enabled:!1,sessionId:"",contentId:"",useHeaders:!1}};e.trackSelectionCallback=
374
- function(g){return I(function(h){return h["return"](Mk(g,f.preferredAudioLanguage))})};return f}function Nk(a,b,c){var d={".drm.servers":"",".drm.clearKeys":"",".drm.advanced":{distinctiveIdentifierRequired:!1,persistentStateRequired:!1,videoRobustness:"",audioRobustness:"",sessionType:"",serverCertificate:new Uint8Array(0),serverCertificateUri:"",individualizationServer:""}};return Hk(a,b,c||Lk(),d,"")}
375
- function Mk(a,b){var c=a.filter(function(h){return"variant"==h.type}),d=[],e=Ub(b,c.map(function(h){return h.language}));e&&(d=c.filter(function(h){return Mb(h.language)==e}));0==d.length&&(d=c.filter(function(h){return h.primary}));0==d.length&&(c.map(function(h){return h.language}),d=c);var f=d.filter(function(h){return h.height&&480>=h.height});f.length&&(f.sort(function(h,k){return k.height-h.height}),d=f.filter(function(h){return h.height==f[0].height}));c=[];if(d.length){var g=Math.floor(d.length/
376
- 2);d.sort(function(h,k){return h.bandwidth-k.bandwidth});c.push(d[g])}d=t(a);for(g=d.next();!g.done;g=d.next())g=g.value,g.type!=Ib&&"image"!=g.type||c.push(g);return c}J("shaka.util.PlayerConfiguration",Kk);Kk.mergeConfigObjects=Nk;Kk.createDefault=Lk;function Ok(){this.g=null;this.h=[]}function Pk(a,b){if(null==a.g)a.g={timestamp:Date.now()/1E3,state:b,duration:0};else{var c=Date.now()/1E3;a.g.duration=c-a.g.timestamp;a.g.state!=b&&(a.h.push(a.g),a.g={timestamp:c,state:b,duration:0})}}function Qk(a,b){var c=0;a.g&&a.g.state==b&&(c+=a.g.duration);for(var d=t(a.h),e=d.next();!e.done;e=d.next())e=e.value,c+=e.state==b?e.duration:0;return c}
377
- function Rk(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 Sk(){this.i=this.h=null;this.g=[]}function Tk(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 Uk(){this.A=this.B=this.H=this.F=this.m=this.j=this.G=this.l=this.i=this.N=this.P=this.I=this.J=this.K=this.C=this.S=NaN;this.g=new Ok;this.h=new Sk};function S(a,b){fb.call(this);var c=this;this.l=Vk;this.od=this.g=null;this.ba=!1;this.sd=new tf;this.hb=new tf;this.A=new tf;this.pe=this.C=this.gb=this.i=this.ud=this.J=this.j=this.ea=this.S=this.Bd=this.N=this.pd=this.I=this.Xa=this.F=this.K=this.m=this.H=null;this.Pf=1E9;this.h=Wk(this);this.Bc={width:Infinity,height:Infinity};this.B=null;this.ya=new Ke(this.h.preferredAudioLanguage,this.h.preferredVariantRole,this.h.preferredAudioChannelCount);this.za=this.h.preferredTextLanguage;this.wb=this.h.preferredTextRole;
378
- this.ib=this.h.preferForcedSubs;this.fb=[];this.Hc=null;b&&b(this);this.H=Xk(this);this.H.Ce(this.h.streaming.forceHTTPS);this.G=null;Yk&&(this.G=Yk());this.sd.o(window,"online",function(){c.se()});this.P={name:"detach"};this.X={name:"attach"};this.aa={name:"unload"};this.Se={name:"manifest-parser"};this.Re={name:"manifest"};this.La={name:"media-source"};this.ue={name:"drm-engine"};this.$={name:"load"};this.Te={name:"src-equals-drm-engine"};this.Ya={name:"src-equals"};var d=new Map;d.set(this.X,function(e,
379
- f){return Ze(Zk(c,e,f))});d.set(this.P,function(e){e.O&&(c.hb.Qc(),e.O=null);c.G&&c.G.release();c.g=null;e=Promise.resolve();return Ze(e)});d.set(this.aa,function(e){return Ze($k(c,e))});d.set(this.La,function(e){e=al(c,e);return Ze(e)});d.set(this.Se,function(e,f){var g=bl(c,e,f);return Ze(g)});d.set(this.Re,function(e){return cl(c,e)});d.set(this.ue,function(e){e=dl(c,e);return Ze(e)});d.set(this.$,function(e,f){return Ze(el(c,e,f))});d.set(this.Te,function(e,f){var g=fl(c,e,f);return Ze(g)});d.set(this.Ya,
380
- function(e,f){return gl(c,e,f)});this.ma=new Rj(this.P,{yg:function(e,f,g,h){var k=null;e==c.P&&(k=g==c.P?c.P:c.X);e==c.X&&(k=g==c.P||f.O!=h.O?c.P:g==c.X?c.X:g==c.La||g==c.$?c.La:g==c.Ya?c.Te:null);e==c.La&&(k=g==c.$&&f.O==h.O?c.Se:c.aa);e==c.Se&&(k=hl(c.$,c.Re,c.aa,g,f,h));e==c.Re&&(k=hl(c.$,c.ue,c.aa,g,f,h));e==c.ue&&(k=hl(c.$,c.$,c.aa,g,f,h));e==c.Te&&(k=g==c.Ya&&f.O==h.O?c.Ya:c.aa);if(e==c.$||e==c.Ya)k=c.aa;e==c.aa&&(k=h.O&&f.O==h.O?c.X:c.P);return k},cg:function(e,f,g){c.dispatchEvent(il("onstatechange",
381
- (new Map).set("state",e.name)));return d.get(e)(f,g)},handleError:function(e){return I(function(f){return 1==f.g?u(f,$k(c,e),2):f["return"](e.O?c.X:c.P)})},Sg:function(e){c.dispatchEvent(il("onstateidle",(new Map).set("state",e.name)))}});this.Of=new P(function(){$d(c.i.variants,c.h.restrictions,c.Bc)&&jl(c)});a&&this.yc(a,!0)}qa(S,fb);function il(a,b){return new M(a,b)}q=S.prototype;
382
- q.destroy=function(){var a=this,b;return I(function(c){switch(c.g){case 1:if(a.l==kl)return c["return"]();a.l=kl;b=Wj(a.ma,function(){return{node:a.P,payload:Sj(),Jb:!1}});return u(c,new Promise(function(d){b.jc=function(){};b.vd=function(){d()};b.Pb=function(){d()};b.onError=function(){d()};b.xd=function(){d()}}),2);case 2:return u(c,a.ma.destroy(),3);case 3:a.sd&&(a.sd.release(),a.sd=null);a.hb&&(a.hb.release(),a.hb=null);a.A&&(a.A.release(),a.A=null);a.pe=null;a.C=null;a.h=null;a.B=null;a.od=null;
376
+ function(g){return I(function(h){return h["return"](Pk(g,f.preferredAudioLanguage))})};return f}function Qk(a,b,c){var d={".drm.servers":"",".drm.clearKeys":"",".drm.advanced":{distinctiveIdentifierRequired:!1,persistentStateRequired:!1,videoRobustness:"",audioRobustness:"",sessionType:"",serverCertificate:new Uint8Array(0),serverCertificateUri:"",individualizationServer:""}};return Kk(a,b,c||Ok(),d,"")}
377
+ function Pk(a,b){var c=a.filter(function(h){return"variant"==h.type}),d=[],e=Ub(b,c.map(function(h){return h.language}));e&&(d=c.filter(function(h){return Mb(h.language)==e}));0==d.length&&(d=c.filter(function(h){return h.primary}));0==d.length&&(c.map(function(h){return h.language}),d=c);var f=d.filter(function(h){return h.height&&480>=h.height});f.length&&(f.sort(function(h,k){return k.height-h.height}),d=f.filter(function(h){return h.height==f[0].height}));c=[];if(d.length){var g=Math.floor(d.length/
378
+ 2);d.sort(function(h,k){return h.bandwidth-k.bandwidth});c.push(d[g])}d=t(a);for(g=d.next();!g.done;g=d.next())g=g.value,g.type!=Ib&&"image"!=g.type||c.push(g);return c}J("shaka.util.PlayerConfiguration",Nk);Nk.mergeConfigObjects=Qk;Nk.createDefault=Ok;function Rk(){this.g=null;this.h=[]}function Sk(a,b){if(null==a.g)a.g={timestamp:Date.now()/1E3,state:b,duration:0};else{var c=Date.now()/1E3;a.g.duration=c-a.g.timestamp;a.g.state!=b&&(a.h.push(a.g),a.g={timestamp:c,state:b,duration:0})}}function Tk(a,b){var c=0;a.g&&a.g.state==b&&(c+=a.g.duration);for(var d=t(a.h),e=d.next();!e.done;e=d.next())e=e.value,c+=e.state==b?e.duration:0;return c}
379
+ function Uk(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 Vk(){this.i=this.h=null;this.g=[]}function Wk(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 Xk(){this.A=this.B=this.H=this.F=this.m=this.j=this.G=this.l=this.i=this.N=this.P=this.I=this.J=this.K=this.C=this.S=NaN;this.g=new Rk;this.h=new Vk};function S(a,b){fb.call(this);var c=this;this.l=Yk;this.od=this.g=null;this.ba=!1;this.sd=new wf;this.hb=new wf;this.A=new wf;this.qe=this.C=this.gb=this.i=this.ud=this.J=this.j=this.ea=this.S=this.Bd=this.N=this.pd=this.I=this.Xa=this.F=this.K=this.m=this.H=null;this.Qf=1E9;this.h=Zk(this);this.Bc={width:Infinity,height:Infinity};this.B=null;this.ya=new Ne(this.h.preferredAudioLanguage,this.h.preferredVariantRole,this.h.preferredAudioChannelCount);this.za=this.h.preferredTextLanguage;this.wb=this.h.preferredTextRole;
380
+ this.ib=this.h.preferForcedSubs;this.fb=[];this.Hc=null;b&&b(this);this.H=$k(this);this.H.De(this.h.streaming.forceHTTPS);this.G=null;al&&(this.G=al());this.sd.o(window,"online",function(){c.ue()});this.P={name:"detach"};this.X={name:"attach"};this.aa={name:"unload"};this.Te={name:"manifest-parser"};this.Se={name:"manifest"};this.La={name:"media-source"};this.ve={name:"drm-engine"};this.$={name:"load"};this.Ue={name:"src-equals-drm-engine"};this.Ya={name:"src-equals"};var d=new Map;d.set(this.X,function(e,
381
+ f){return bf(bl(c,e,f))});d.set(this.P,function(e){e.O&&(c.hb.Qc(),e.O=null);c.G&&c.G.release();c.g=null;e=Promise.resolve();return bf(e)});d.set(this.aa,function(e){return bf(cl(c,e))});d.set(this.La,function(e){e=dl(c,e);return bf(e)});d.set(this.Te,function(e,f){var g=el(c,e,f);return bf(g)});d.set(this.Se,function(e){return fl(c,e)});d.set(this.ve,function(e){e=gl(c,e);return bf(e)});d.set(this.$,function(e,f){return bf(hl(c,e,f))});d.set(this.Ue,function(e,f){var g=il(c,e,f);return bf(g)});d.set(this.Ya,
382
+ function(e,f){return jl(c,e,f)});this.ma=new Uj(this.P,{zg:function(e,f,g,h){var k=null;e==c.P&&(k=g==c.P?c.P:c.X);e==c.X&&(k=g==c.P||f.O!=h.O?c.P:g==c.X?c.X:g==c.La||g==c.$?c.La:g==c.Ya?c.Ue:null);e==c.La&&(k=g==c.$&&f.O==h.O?c.Te:c.aa);e==c.Te&&(k=kl(c.$,c.Se,c.aa,g,f,h));e==c.Se&&(k=kl(c.$,c.ve,c.aa,g,f,h));e==c.ve&&(k=kl(c.$,c.$,c.aa,g,f,h));e==c.Ue&&(k=g==c.Ya&&f.O==h.O?c.Ya:c.aa);if(e==c.$||e==c.Ya)k=c.aa;e==c.aa&&(k=h.O&&f.O==h.O?c.X:c.P);return k},dg:function(e,f,g){c.dispatchEvent(ll("onstatechange",
383
+ (new Map).set("state",e.name)));return d.get(e)(f,g)},handleError:function(e){return I(function(f){return 1==f.g?u(f,cl(c,e),2):f["return"](e.O?c.X:c.P)})},Tg:function(e){c.dispatchEvent(ll("onstateidle",(new Map).set("state",e.name)))}});this.Pf=new P(function(){ce(c.i.variants,c.h.restrictions,c.Bc)&&ml(c)});a&&this.yc(a,!0)}qa(S,fb);function ll(a,b){return new L(a,b)}q=S.prototype;
384
+ q.destroy=function(){var a=this,b;return I(function(c){switch(c.g){case 1:if(a.l==nl)return c["return"]();a.l=nl;b=Zj(a.ma,function(){return{node:a.P,payload:Vj(),Jb:!1}});return u(c,new Promise(function(d){b.jc=function(){};b.vd=function(){d()};b.Pb=function(){d()};b.onError=function(){d()};b.xd=function(){d()}}),2);case 2:return u(c,a.ma.destroy(),3);case 3:a.sd&&(a.sd.release(),a.sd=null);a.hb&&(a.hb.release(),a.hb=null);a.A&&(a.A.release(),a.A=null);a.qe=null;a.C=null;a.h=null;a.B=null;a.od=null;
383
385
  a.S=null;if(!a.H){c.D(4);break}return u(c,a.H.destroy(),5);case 5:a.H=null;case 4:fb.prototype.release.call(a),z(c)}})};
384
- function ll(){window.Promise||Ua("A Promise implementation or polyfill is required");window.TextDecoder&&window.TextEncoder||Ua("A TextDecoder/TextEncoder implementation or polyfill is required");if(!(window.Promise&&window.Uint8Array&&window.TextDecoder&&window.TextEncoder&&Array.prototype.forEach)||Fd("Trident/"))return!1;var a=Jd();return a&&13>a||!(window.MediaKeys&&window.navigator&&window.navigator.requestMediaKeySystemAccess&&window.MediaKeySystemAccess&&window.MediaKeySystemAccess.prototype.getConfiguration)?
385
- !1:yd()?!0:zd("application/x-mpegurl")}q.yc=function(a,b){b=void 0===b?!0:b;if(this.l==kl)return Promise.reject(ml());var c=Sj();c.O=a;yd()||(b=!1);var d=b?this.La:this.X,e=Wj(this.ma,function(){return{node:d,payload:c,Jb:!1}});e.jc=function(){};return nl(e)};q.detach=function(){var a=this;if(this.l==kl)return Promise.reject(ml());var b=Wj(this.ma,function(){return{node:a.P,payload:Sj(),Jb:!1}});b.jc=function(){};return nl(b)};
386
- q.Pe=function(a){var b=this;a=void 0===a?!0:a;if(this.l==kl)return Promise.reject(ml());yd()||(a=!1);var c=Sj(),d=Wj(this.ma,function(e){var f=e.O&&a?b.La:e.O?b.X:b.P;c.O=e.O;return{node:f,payload:c,Jb:!1}});d.jc=function(){};return nl(d)};q.sh=function(a){this.Hc=a};
387
- q.load=function(a,b,c){var d=this;this.Hc=null;if(this.l==kl)return Promise.reject(ml());this.dispatchEvent(il("loading"));var e=Sj();e.uri=a;e.Je=Date.now()/1E3;c&&(e.mimeType=c);void 0!==b&&(e.startTime=b);var f=ol(this,e)?this.Ya:this.$,g=Wj(this.ma,function(h){if(null==h.O)return null;e.O=h.O;return{node:f,payload:e,Jb:!0}});this.B=new Uk;this.S=pl(this);g.jc=function(){};return new Promise(function(h,k){g.xd=function(){return k(new O(2,7,7002))};g.vd=function(){h();d.dispatchEvent(il("loaded"))};
388
- g.Pb=function(){return k(ml())};g.onError=function(l){return k(l)}})};function ol(a,b){if(!yd())return!0;var c=b.mimeType,d=b.uri||"";c||(c=rg(d),c=ql[c]);if(c){if(""==(b.O||Ad()).canPlayType(c))return!1;if(!yd()||!(c in qg||rg(d)in sg)||a.h.streaming.preferNativeHls)return!0;if(Id())return a.h.streaming.useNativeHlsOnSafari}return!1}function Zk(a,b,c){null==b.O&&(b.O=c.O,a.hb.o(b.O,"error",function(){var d=rl(a);d&&sl(a,d)}));a.g=b.O;return Promise.resolve()}
389
- function $k(a,b){var c,d,e,f,g,h,k,l,m;return I(function(n){switch(n.g){case 1:return a.l!=kl&&(a.l=Vk),c=a.fb.map(function(p){return p()}),a.fb=[],u(n,Promise.all(c),2);case 2:a.dispatchEvent(il("unloading"));b.mimeType=null;b.startTime=null;b.uri=null;b.O&&a.A.Qc();a.Of.stop();a.Xa&&(a.Xa.release(),a.Xa=null);a.pd&&(a.pd.stop(),a.pd=null);if(!a.J){n.D(3);break}return u(n,a.J.stop(),4);case 4:a.J=null,a.ud=null;case 3:if(!a.C){n.D(5);break}return u(n,a.C.stop(),5);case 5:if(!a.j){n.D(7);break}return u(n,
386
+ function ol(){window.Promise||Ua("A Promise implementation or polyfill is required");window.TextDecoder&&window.TextEncoder||Ua("A TextDecoder/TextEncoder implementation or polyfill is required");if(!(window.Promise&&window.Uint8Array&&window.TextDecoder&&window.TextEncoder&&Array.prototype.forEach)||Vc("Trident/"))return!1;var a=ad();return a&&13>a||!(window.MediaKeys&&window.navigator&&window.navigator.requestMediaKeySystemAccess&&window.MediaKeySystemAccess&&window.MediaKeySystemAccess.prototype.getConfiguration)?
387
+ !1:Rc()?!0:Sc("application/x-mpegurl")}q.yc=function(a,b){b=void 0===b?!0:b;if(this.l==nl)return Promise.reject(pl());var c=Vj();c.O=a;Rc()||(b=!1);var d=b?this.La:this.X,e=Zj(this.ma,function(){return{node:d,payload:c,Jb:!1}});e.jc=function(){};return ql(e)};q.detach=function(){var a=this;if(this.l==nl)return Promise.reject(pl());var b=Zj(this.ma,function(){return{node:a.P,payload:Vj(),Jb:!1}});b.jc=function(){};return ql(b)};
388
+ q.Qe=function(a){var b=this;a=void 0===a?!0:a;if(this.l==nl)return Promise.reject(pl());Rc()||(a=!1);var c=Vj(),d=Zj(this.ma,function(e){var f=e.O&&a?b.La:e.O?b.X:b.P;c.O=e.O;return{node:f,payload:c,Jb:!1}});d.jc=function(){};return ql(d)};q.uh=function(a){this.Hc=a};
389
+ q.load=function(a,b,c){var d=this;this.Hc=null;if(this.l==nl)return Promise.reject(pl());this.dispatchEvent(ll("loading"));var e=Vj();e.uri=a;e.Ke=Date.now()/1E3;c&&(e.mimeType=c);void 0!==b&&(e.startTime=b);var f=rl(this,e)?this.Ya:this.$,g=Zj(this.ma,function(h){if(null==h.O)return null;e.O=h.O;return{node:f,payload:e,Jb:!0}});this.B=new Xk;this.S=sl(this);g.jc=function(){};return new Promise(function(h,k){g.xd=function(){return k(new O(2,7,7002))};g.vd=function(){h();d.dispatchEvent(ll("loaded"))};
390
+ g.Pb=function(){return k(pl())};g.onError=function(l){return k(l)}})};function rl(a,b){if(!Rc())return!0;var c=b.mimeType,d=b.uri||"";c||(c=ug(d),c=tl[c]);if(c){if(""==(b.O||Tc()).canPlayType(c))return!1;if(!Rc()||!(c in tg||ug(d)in vg)||a.h.streaming.preferNativeHls)return!0;if(Zc())return a.h.streaming.useNativeHlsOnSafari}return!1}function bl(a,b,c){null==b.O&&(b.O=c.O,a.hb.o(b.O,"error",function(){var d=ul(a);d&&vl(a,d)}));a.g=b.O;return Promise.resolve()}
391
+ function cl(a,b){var c,d,e,f,g,h,k,l,m;return I(function(n){switch(n.g){case 1:return a.l!=nl&&(a.l=Yk),c=a.fb.map(function(p){return p()}),a.fb=[],u(n,Promise.all(c),2);case 2:a.dispatchEvent(ll("unloading"));b.mimeType=null;b.startTime=null;b.uri=null;b.O&&a.A.Qc();a.Pf.stop();a.Xa&&(a.Xa.release(),a.Xa=null);a.pd&&(a.pd.stop(),a.pd=null);if(!a.J){n.D(3);break}return u(n,a.J.stop(),4);case 4:a.J=null,a.ud=null;case 3:if(!a.C){n.D(5);break}return u(n,a.C.stop(),5);case 5:if(!a.j){n.D(7);break}return u(n,
390
392
  a.j.destroy(),8);case 8:a.j=null;case 7:a.I&&(a.I.release(),a.I=null);a.F&&(a.F.release(),a.F=null);if(!a.K){n.D(9);break}return u(n,a.K.destroy(),10);case 10:a.K=null;case 9:if(a.G)a.G.onAssetUnload();if(!b.O||!b.O.src){n.D(11);break}return u(n,new Promise(function(p){return(new P(p)).T(.1)}),12);case 12:for(b.O.removeAttribute("src"),b.O.load();b.O.lastChild;)b.O.removeChild(b.O.firstChild);case 11:if(!a.m){n.D(13);break}return u(n,a.m.destroy(),14);case 14:a.m=null;case 13:a.gb=null;a.N=null;if(a.i){d=
391
- t(a.i.variants);for(e=d.next();!e.done;e=d.next())for(f=e.value,g=t([f.audio,f.video]),h=g.next();!h.done;h=g.next())(k=h.value)&&k.segmentIndex&&k.segmentIndex.release();l=t(a.i.textStreams);for(h=l.next();!h.done;h=l.next())m=h.value,m.segmentIndex&&m.segmentIndex.release()}a.i=null;a.B=new Uk;a.Oe=null;tl(a);z(n)}})}
392
- function al(a,b){var c,d,e,f,g,h;return I(function(k){if(1==k.g)return c=new Rh,d=a.h.textDisplayFactory,e=d(),a.Oe=d,f=ul(b.O,c,e,function(l,m,n){l=t(l);for(var p=l.next();!p.done;p=l.next())if(p=p.value,p.data&&p.cueTime&&p.frames){for(var r=p.cueTime+m,x=n,y=t(p.frames),w=y.next();!w.done;w=y.next())vl(a,r,x,"ID3",w.value);if(a.G)a.G.onHlsTimedMetadata(p,r)}}),g=a.h.manifest,h=g.segmentRelativeVttTiming,f.H=h,u(k,f.I,2);a.K=f;z(k)})}
393
- function bl(a,b,c){var d,e,f,g;return I(function(h){if(1==h.g)return b.mimeType=c.mimeType,b.uri=c.uri,d=b.uri,e=a.H,a.gb=d,f=a,u(h,pg(d,e,a.h.manifest.retryParameters,b.mimeType),2);f.ud=h.h;a.J=a.ud();g=bf(a.h.manifest);c.O&&"AUDIO"===c.O.nodeName&&(g.disableVideo=!0);a.J.configure(g);z(h)})}
394
- function cl(a,b){var c=b.uri,d=a.H;a.Bd=new ij(function(){return a.Ia()});a.Bd.addEventListener("regionadd",function(g){g=g.region;wl(a,"timelineregionadded",g);if(a.G)a.G.onDashTimedMetadata(g)});a.ea=null;a.h.streaming.observeQualityChanges&&(a.ea=new ej(function(){return a.kb()}),a.ea.addEventListener("qualitychange",function(g){var h=g.quality;g=g.position;h=(new Map).set("mediaQuality",{bandwidth:h.bandwidth,audioSamplingRate:h.audioSamplingRate,codecs:h.codecs,contentType:h.contentType,frameRate:h.frameRate,
395
- height:h.height,mimeType:h.mimeType,channelsCount:h.channelsCount,pixelAspectRatio:h.pixelAspectRatio,width:h.width}).set("position",g);a.dispatchEvent(il("mediaqualitychanged",h))}));var e={networkingEngine:d,modifyManifestRequest:function(g,h){var k=a.S;try{k.g.enabled&&(k.A=h.format,xk(k,g,{ot:Ak,su:!k.i}))}catch(l){Va("CMCD_MANIFEST_ERROR","Could not generate manifest CMCD data.",l)}},modifySegmentRequest:function(g,h){nk(a.S,g,h)},filter:function(g){return xl(a,g)},makeTextStreamsForClosedCaptions:function(g){return yl(a,
396
- g)},onTimelineRegionAdded:function(g){var h=a.Bd;a:{var k=t(h.g);for(var l=k.next();!l.done;l=k.next())if(l=l.value,l.schemeIdUri==g.schemeIdUri&&l.id==g.id&&l.startTime==g.startTime&&l.endTime==g.endTime){k=l;break a}k=null}null==k&&(h.g.add(g),g=new M("regionadd",new Map([["region",g]])),h.dispatchEvent(g))},onEvent:function(g){return a.dispatchEvent(g)},onError:function(g){return sl(a,g)},isLowLatencyMode:function(){return a.h.streaming.lowLatencyMode},isAutoLowLatencyMode:function(){return a.h.streaming.autoLowLatencyMode},
397
- enableLowLatencyMode:function(){a.configure("streaming.lowLatencyMode",!0)}},f=Date.now()/1E3;return new Ve(function(){var g,h,k,l;return I(function(m){if(1==m.g)return g=a,u(m,a.J.start(c,e),2);g.i=m.h;h=il("manifestparsed");a.dispatchEvent(h);if(0==a.i.variants.length)throw new O(2,4,4036);zl(a.i);k=Date.now()/1E3;l=k-f;a.B.G=l;z(m)})}(),function(){return a.J.stop()})}
398
- function dl(a,b){var c,d;return I(function(e){return 1==e.g?(c=Date.now()/1E3,d=!0,a.m=Al(a,{Ob:a.H,onError:function(f){sl(a,f)},wd:function(f){Bl(a,f)},onExpirationUpdated:function(f,g){Cl(a,f,g)},onEvent:function(f){a.dispatchEvent(f);"drmsessionupdate"==f.type&&d&&(d=!1,a.B.j=Date.now()/1E3-c)}}),a.m.configure(a.h.drm),u(e,If(a.m,a.i.variants,a.i.offlineSessionIds),2)):3!=e.g?u(e,a.m.yc(b.O),3):u(e,xl(a,a.i),0)})}
399
- function el(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,x;return I(function(y){switch(y.g){case 1:b.startTime=c.startTime;null!=a.Hc&&(b.startTime=a.Hc,a.Hc=null);d=b.O;e=b.uri;a.gb=e;a.I=new aj({md:function(){return d.playbackRate},jd:function(){return d.defaultPlaybackRate},Ee:function(w){d.playbackRate=w},yf:function(w){d.currentTime+=w}});f=function(){return Dl(a)};g=function(){return El(a)};a.A.o(d,"playing",f);a.A.o(d,"pause",f);a.A.o(d,"ended",f);a.A.o(d,"ratechange",g);h=a.h.abrFactory;a.C&&a.pe==h||
400
- (a.pe=h,a.C=h(),a.C.configure(a.h.abr));a.ya=new Ke(a.h.preferredAudioLanguage,a.h.preferredVariantRole,a.h.preferredAudioChannelCount);a.za=a.h.preferredTextLanguage;a.wb=a.h.preferredTextRole;a.ib=a.h.preferForcedSubs;Fl(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd);a.C.init(function(w,v,D){a.j&&w!=a.j.l&&Gl(a,w,!0,void 0===v?!1:v,void 0===D?0:D)});a.F=Hl(a,b.startTime);a.Xa=Il(a);k=Math.max(a.i.minBufferTime,a.h.streaming.rebufferingGoal);Jl(a,k);Md(a.i,a.h.preferredVideoCodecs,
401
- a.h.preferredAudioCodecs,a.h.preferredAudioChannelCount,a.h.preferredDecodingAttributes);a.j=Kl(a);a.j.configure(a.h.streaming);a.l=Ll;d.textTracks&&a.A.o(d.textTracks,"addtrack",function(w){if(w.track)switch(w=w.track,w.kind){case "chapters":Ml(a,w)}});a.dispatchEvent(il("streaming"));l=null;if(m=a.Qa().find(function(w){return w.active})){y.D(2);break}l=jl(a);Gl(a,l,!0,!1,0);if(!a.h.streaming.startAtSegmentBoundary){y.D(3);break}n=a.F.bd();return u(y,Nl(l,n),4);case 4:p=y.h,a.F.Yd(p);case 3:Ol(a,
402
- null,oe(l));case 2:return r=a.Ab().find(function(w){return w.active}),r||((x=ye(a.i.textStreams,a.za,a.wb,a.ib)[0]||null)&&Tk(a.B.h,x,!0),l&&(x?(l.audio&&Pl(a,l.audio,x)&&(a.ba=!0),a.ba&&a.K.m.setTextVisibility(!0),Ql(a)):a.ba=!1),x&&(a.h.streaming.alwaysStreamText||a.Nb())&&Bj(a.j,x)),u(y,a.j.start(),5);case 5:a.h.abr.enabled&&(a.C.enable(),Rl(a)),ce(a.j?a.j.l:null,a.i),Sl(a.i),Tl(a),Ul(a),a.i.variants.some(function(w){return w.primary}),a.A.Fa(d,"loadedmetadata",function(){a.B.l=Date.now()/1E3-
403
- c.Je}),z(y)}})}
404
- function fl(a,b,c){var d,e,f,g,h,k,l;return I(function(m){return 1==m.g?(d=Jb,e=Date.now()/1E3,f=!0,a.m=Al(a,{Ob:a.H,onError:function(n){sl(a,n)},wd:function(n){Bl(a,n)},onExpirationUpdated:function(n,p){Cl(a,n,p)},onEvent:function(n){a.dispatchEvent(n);"drmsessionupdate"==n.type&&f&&(f=!1,a.B.j=Date.now()/1E3-e)}}),a.m.configure(a.h.drm),g=c.uri||"",h=rg(g),k=ql[h],"application/x-mpegurl"==k&&Id()&&(k="application/vnd.apple.mpegurl"),k||(k="video/mp4"),l={id:0,language:"und",disabledUntilTime:0,primary:!1,
405
- audio:null,video:{id:0,originalId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:c.mimeType?c.mimeType.split(";")[0]:k,codecs:c.mimeType?nd(c.mimeType):"",encrypted:!0,drmInfos:[],keyIds:new Set,language:"und",label:null,type:d.Ma,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null},bandwidth:100,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},
406
- a.m.X=!0,u(m,If(a.m,[l],[]),2)):u(m,a.m.yc(b.O),0)})}
407
- function gl(a,b,c){function d(){return Dl(a)}b.uri=c.uri;b.startTime=c.startTime;a.gb=b.uri;var e=b.O;a.F=new Qi(e);var f=!1;a.fb.push(function(){f=!0});null!=b.startTime&&a.F.Yd(b.startTime);a.I=new aj({md:function(){return e.playbackRate},jd:function(){return e.defaultPlaybackRate},Ee:function(k){e.playbackRate=k},yf:function(k){e.currentTime+=k}});Jl(a,a.h.streaming.rebufferingGoal);a.A.o(e,"playing",d);a.A.o(e,"pause",d);a.A.o(e,"ended",d);a.A.o(e,"ratechange",function(){return El(a)});"none"!=
408
- e.preload&&a.A.Fa(e,"loadedmetadata",function(){a.B.l=Date.now()/1E3-c.Je});e.audioTracks&&(a.A.o(e.audioTracks,"addtrack",function(){return Tl(a)}),a.A.o(e.audioTracks,"removetrack",function(){return Tl(a)}),a.A.o(e.audioTracks,"change",function(){return Tl(a)}));e.textTracks&&(a.A.o(e.textTracks,"addtrack",function(k){if(k.track)switch(k=k.track,k.kind){case "metadata":Vl(a,k);break;case "chapters":Ml(a,k);break;default:Tl(a)}}),a.A.o(e.textTracks,"removetrack",function(){return Tl(a)}),a.A.o(e.textTracks,
409
- "change",function(){return Tl(a)}));var g=rg(b.uri);e.src=yk(a.S,b.uri,ql[g]);(Gd()||Fd("Web0S"))&&e.load();a.l=Wl;a.dispatchEvent(il("streaming"));var h=new Nc;Hi(e,HTMLMediaElement.HAVE_METADATA,a.A,function(){h.resolve()});Hi(e,HTMLMediaElement.HAVE_CURRENT_DATA,a.A,function(){var k;return I(function(l){if(1==l.g)return Xl(a),k=Yl(a),k.find(function(m){return"disabled"!=m.mode})?l.D(2):u(l,new Promise(function(m){a.A.Fa(e.textTracks,"change",m);(new P(m)).T(1)}),2);if(f)return l["return"]();Zl(a);
410
- z(l)})});e.error?h.reject(rl(a)):"none"==e.preload&&(Ua('With <video preload="none">, the browser will not load anything until play() is called. We are unable to measure load latency in a meaningful way, and we cannot provide track info yet. Please do not use preload="none" with Shaka Player.'),h.resolve());a.A.Fa(e,"error",function(){h.reject(rl(a))});return new Ve(h,function(){h.reject(new O(2,7,7001));return Promise.resolve()})}
411
- function Xl(a){var b=a.h.preferredAudioLanguage;if(""!=b){a.Ed(b);var c=a.h.preferredVariantRole;""!=c&&a.Ed(b,c)}}function Zl(a){var b=a.h.preferredTextLanguage,c=a.h.preferForcedSubs;if(""!=b){a.xe(b,"",c);var d=a.h.preferredTextRole;""!=d&&a.xe(b,d,c)}}
412
- function Vl(a,b){if("metadata"==b.kind){b.mode="hidden";a.A.o(b,"cuechange",function(){if(b.activeCues)for(var d=t(b.activeCues),e=d.next();!e.done;e=d.next())if(e=e.value,vl(a,e.startTime,e.endTime,e.type,e.value),a.G)a.G.onCueMetadataChange(e.value)});var c=(new P(function(){var d=$l(a);d=t(d);for(var e=d.next();!e.done;e=d.next())e.value.mode="hidden"})).xa().T(.5);a.fb.push(function(){c.stop()})}}
413
- function vl(a,b,c,d,e){b=(new Map).set("startTime",b).set("endTime",c).set("metadataType",d).set("payload",e);a.dispatchEvent(il("metadata",b))}function Ml(a,b){if(b&&"chapters"==b.kind){b.mode="hidden";var c=(new P(function(){b.mode="hidden"})).xa().T(.5);a.fb.push(function(){c.stop()})}}function zl(a){function b(c){return c.video&&c.audio||c.video&&c.video.codecs.includes(",")}a.variants.some(b)&&(a.variants=a.variants.filter(b))}function Al(a,b){return new Bf(b,a.h.drm.updateExpirationTime)}
414
- function Xk(a){return new ff(function(b,c){a.C&&a.C.segmentDownloaded(b,c)},function(b,c,d){b=(new Map).set("headers",b).set("request",c).set("requestType",d);a.dispatchEvent(il("downloadheadersreceived",b))},function(b,c,d,e){b=(new Map).set("request",b).set("error",c).set("httpResponseCode",d).set("aborted",e);a.dispatchEvent(il("downloadfailed",b))})}
415
- function Hl(a,b){return new Ri(a.g,a.i,a.h.streaming,b,function(){a.Xa&&dj(a.Xa,!0);a.j&&a.j.Rc();a.N&&am(a)},function(c){return a.dispatchEvent(c)})}
416
- function Il(a){var b=new jj(a.Bd);b.addEventListener("enter",function(d){wl(a,"timelineregionenter",d.region)});b.addEventListener("exit",function(d){wl(a,"timelineregionexit",d.region)});b.addEventListener("skip",function(d){var e=d.region;d.seeking||(wl(a,"timelineregionenter",e),wl(a,"timelineregionexit",e))});var c=new cj(a.g);c.g.add(b);a.ea&&c.g.add(a.ea);return c}function Jl(a,b){a.N=new Oe;a.N.g=Qe;Re(a.N,b,Math.min(.5,b/2));tl(a);a.pd=(new P(function(){am(a)})).ka(.25)}
417
- function am(a){switch(a.l){case Wl:if(a.g.ended)var b=!0;else{var c=Uh(a.g.buffered);b=null!=c&&c>=a.g.duration-1}break;case Ll:a:if(a.g.ended||ei(a.K))b=!0;else{if(a.i.presentationTimeline.U()){c=a.i.presentationTimeline.Ib();var d=Uh(a.g.buffered);if(null!=d&&d>=c){b=!0;break a}}b=!1}break;default:b=!1}d=Wh(a.g.buffered,a.g.currentTime);c=a.N;var e=b,f=c.h.get(c.g);b=c.g;d=e||d>=f?Pe:Qe;c.g=d;b!=d&&tl(a)}function ul(a,b,c,d){return new Zh(a,b,c,d)}
418
- function pl(a){return new mk({getBandwidthEstimate:function(){return a.C?a.C.getBandwidthEstimate():NaN},kb:function(){return a.kb()},getCurrentTime:function(){return a.g?a.g.currentTime:0},Qa:function(){return a.Qa()},zb:function(){return a.zb()},U:function(){return a.U()}},a.h.cmcd)}
419
- function Kl(a){return new pj(a.i,{ld:function(){return a.F.bd()},getBandwidthEstimate:function(){return a.C.getBandwidthEstimate()},modifySegmentRequest:function(b,c){nk(a.S,b,c)},V:a.K,Ob:a.H,onError:function(b){return sl(a,b)},onEvent:function(b){return a.dispatchEvent(b)},Ug:function(){a.J&&a.J.update&&a.J.update()},oe:function(){a.F&&a.F.zf();am(a)},Tg:function(b,c){var d=c.ie;d&&a.ea&&gj(a.ea,d,b)}})}
420
- q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=Ik(a,b));a.streaming&&a.streaming.lowLatencyMode&&(void 0==a.streaming.inaccurateManifestTolerance&&(a.streaming.inaccurateManifestTolerance=0),void 0==a.streaming.rebufferingGoal&&(a.streaming.rebufferingGoal=.01));var c=Nk(this.h,a,Wk(this));bm(this);return c};
421
- function bm(a){if(a.J){var b=bf(a.h.manifest);a.g&&"AUDIO"===a.g.nodeName&&(b.disableVideo=!0);a.J.configure(b)}a.m&&a.m.configure(a.h.drm);if(a.j){a.j.configure(a.h.streaming);try{cm(a,a.i)}catch(f){sl(a,f)}a.C&&Ul(a);b=a.j.l;!b||b.allowedByApplication&&b.allowedByKeySystem||dm(a)}a.H&&a.H.Ce(a.h.streaming.forceHTTPS);if(a.K&&(a.K.H=a.h.manifest.segmentRelativeVttTiming,b=a.h.textDisplayFactory,a.Oe!=b)){var c=b(),d=a.K,e=d.m;d.m=c;e&&(c.setTextVisibility(e.isTextVisible()),e.destroy());d.g&&(d.g.i=
422
- c);a.Oe=b;a.j&&(b=a.j,(c=b.h.get(Ib))&&zj(b,c.stream,!0,0,!0))}a.C&&(a.C.configure(a.h.abr),a.h.abr.enabled?a.C.enable():a.C.disable(),Rl(a));a.N&&(b=a.h.streaming.rebufferingGoal,a.i&&(b=Math.max(b,a.i.minBufferTime)),Re(a.N,b,Math.min(.5,b/2)));a.i&&Fl(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd)}q.getConfiguration=function(){var a=Wk(this);Nk(a,this.h,Wk(this));return a};
423
- q.fg=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.Ia().end);if(a>=b)return 1;if(!(a<=this.g.currentTime)&&a<b)return(a-this.g.currentTime)/(b-this.g.currentTime)}return 0};q.eh=function(){for(var a in this.h)delete this.h[a];Nk(this.h,Wk(this),Wk(this));bm(this)};q.qf=function(){return this.l};q.xg=function(){return this.g};q.Ec=function(){return this.H};q.Zd=function(){return this.gb};
393
+ t(a.i.variants);for(e=d.next();!e.done;e=d.next())for(f=e.value,g=t([f.audio,f.video]),h=g.next();!h.done;h=g.next())(k=h.value)&&k.segmentIndex&&k.segmentIndex.release();l=t(a.i.textStreams);for(h=l.next();!h.done;h=l.next())m=h.value,m.segmentIndex&&m.segmentIndex.release()}a.i=null;a.B=new Xk;a.Pe=null;wl(a);z(n)}})}
394
+ function dl(a,b){var c,d,e,f,g,h;return I(function(k){if(1==k.g)return c=new Uh,d=a.h.textDisplayFactory,e=d(),a.Pe=d,f=xl(b.O,c,e,function(l,m,n){l=t(l);for(var p=l.next();!p.done;p=l.next())if(p=p.value,p.data&&p.cueTime&&p.frames){for(var r=p.cueTime+m,w=n,y=t(p.frames),x=y.next();!x.done;x=y.next())yl(a,r,w,"ID3",x.value);if(a.G)a.G.onHlsTimedMetadata(p,r)}}),g=a.h.manifest,h=g.segmentRelativeVttTiming,f.H=h,u(k,f.I,2);a.K=f;z(k)})}
395
+ function el(a,b,c){var d,e,f,g;return I(function(h){if(1==h.g)return b.mimeType=c.mimeType,b.uri=c.uri,d=b.uri,e=a.H,a.gb=d,f=a,u(h,sg(d,e,a.h.manifest.retryParameters,b.mimeType),2);f.ud=h.h;a.J=a.ud();g=ef(a.h.manifest);c.O&&"AUDIO"===c.O.nodeName&&(g.disableVideo=!0);a.J.configure(g);z(h)})}
396
+ function fl(a,b){var c=b.uri,d=a.H;a.Bd=new lj(function(){return a.Ia()});a.Bd.addEventListener("regionadd",function(g){g=g.region;zl(a,"timelineregionadded",g);if(a.G)a.G.onDashTimedMetadata(g)});a.ea=null;a.h.streaming.observeQualityChanges&&(a.ea=new hj(function(){return a.kb()}),a.ea.addEventListener("qualitychange",function(g){var h=g.quality;g=g.position;h=(new Map).set("mediaQuality",{bandwidth:h.bandwidth,audioSamplingRate:h.audioSamplingRate,codecs:h.codecs,contentType:h.contentType,frameRate:h.frameRate,
397
+ height:h.height,mimeType:h.mimeType,channelsCount:h.channelsCount,pixelAspectRatio:h.pixelAspectRatio,width:h.width}).set("position",g);a.dispatchEvent(ll("mediaqualitychanged",h))}));var e={networkingEngine:d,modifyManifestRequest:function(g,h){var k=a.S;try{k.g.enabled&&(k.A=h.format,Ak(k,g,{ot:Dk,su:!k.i}))}catch(l){Va("CMCD_MANIFEST_ERROR","Could not generate manifest CMCD data.",l)}},modifySegmentRequest:function(g,h){qk(a.S,g,h)},filter:function(g){return Al(a,g)},makeTextStreamsForClosedCaptions:function(g){return Bl(a,
398
+ g)},onTimelineRegionAdded:function(g){var h=a.Bd;a:{var k=t(h.g);for(var l=k.next();!l.done;l=k.next())if(l=l.value,l.schemeIdUri==g.schemeIdUri&&l.id==g.id&&l.startTime==g.startTime&&l.endTime==g.endTime){k=l;break a}k=null}null==k&&(h.g.add(g),g=new L("regionadd",new Map([["region",g]])),h.dispatchEvent(g))},onEvent:function(g){return a.dispatchEvent(g)},onError:function(g){return vl(a,g)},isLowLatencyMode:function(){return a.h.streaming.lowLatencyMode},isAutoLowLatencyMode:function(){return a.h.streaming.autoLowLatencyMode},
399
+ enableLowLatencyMode:function(){a.configure("streaming.lowLatencyMode",!0)}},f=Date.now()/1E3;return new Ye(function(){var g,h,k,l;return I(function(m){if(1==m.g)return g=a,u(m,a.J.start(c,e),2);g.i=m.h;h=ll("manifestparsed");a.dispatchEvent(h);if(0==a.i.variants.length)throw new O(2,4,4036);Cl(a.i);k=Date.now()/1E3;l=k-f;a.B.G=l;z(m)})}(),function(){return a.J.stop()})}
400
+ function gl(a,b){var c,d;return I(function(e){return 1==e.g?(c=Date.now()/1E3,d=!0,a.m=Dl(a,{Ob:a.H,onError:function(f){vl(a,f)},wd:function(f){El(a,f)},onExpirationUpdated:function(f,g){Fl(a,f,g)},onEvent:function(f){a.dispatchEvent(f);"drmsessionupdate"==f.type&&d&&(d=!1,a.B.j=Date.now()/1E3-c)}}),a.m.configure(a.h.drm),u(e,Lf(a.m,a.i.variants,a.i.offlineSessionIds),2)):3!=e.g?u(e,a.m.yc(b.O),3):u(e,Al(a,a.i),0)})}
401
+ function hl(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,w;return I(function(y){switch(y.g){case 1:b.startTime=c.startTime;null!=a.Hc&&(b.startTime=a.Hc,a.Hc=null);d=b.O;e=b.uri;a.gb=e;a.I=new dj({md:function(){return d.playbackRate},jd:function(){return d.defaultPlaybackRate},Fe:function(x){d.playbackRate=x},zf:function(x){d.currentTime+=x}});f=function(){return Gl(a)};g=function(){return Hl(a)};a.A.o(d,"playing",f);a.A.o(d,"pause",f);a.A.o(d,"ended",f);a.A.o(d,"ratechange",g);h=a.h.abrFactory;a.C&&a.qe==h||
402
+ (a.qe=h,a.C=h(),a.C.configure(a.h.abr));a.ya=new Ne(a.h.preferredAudioLanguage,a.h.preferredVariantRole,a.h.preferredAudioChannelCount);a.za=a.h.preferredTextLanguage;a.wb=a.h.preferredTextRole;a.ib=a.h.preferForcedSubs;Il(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd);a.C.init(function(x,v,D){a.j&&x!=a.j.l&&Jl(a,x,!0,void 0===v?!1:v,void 0===D?0:D)});a.F=Kl(a,b.startTime);a.Xa=Ll(a);k=Math.max(a.i.minBufferTime,a.h.streaming.rebufferingGoal);Ml(a,k);Pd(a.i,a.h.preferredVideoCodecs,
403
+ a.h.preferredAudioCodecs,a.h.preferredAudioChannelCount,a.h.preferredDecodingAttributes);a.j=Nl(a);a.j.configure(a.h.streaming);a.l=Ol;d.textTracks&&a.A.o(d.textTracks,"addtrack",function(x){if(x.track)switch(x=x.track,x.kind){case "chapters":Pl(a,x)}});a.dispatchEvent(ll("streaming"));l=null;if(m=a.Qa().find(function(x){return x.active})){y.D(2);break}l=ml(a);Jl(a,l,!0,!1,0);if(!a.h.streaming.startAtSegmentBoundary){y.D(3);break}n=a.F.bd();return u(y,Ql(l,n),4);case 4:p=y.h,a.F.Yd(p);case 3:Rl(a,
404
+ null,re(l));case 2:return r=a.Ab().find(function(x){return x.active}),r||((w=Be(a.i.textStreams,a.za,a.wb,a.ib)[0]||null)&&Wk(a.B.h,w,!0),l&&(w?(l.audio&&Sl(a,l.audio,w)&&(a.ba=!0),a.ba&&a.K.m.setTextVisibility(!0),Tl(a)):a.ba=!1),w&&(a.h.streaming.alwaysStreamText||a.Nb())&&Ej(a.j,w)),u(y,a.j.start(),5);case 5:a.h.abr.enabled&&(a.C.enable(),Ul(a)),fe(a.j?a.j.l:null,a.i),Vl(a.i),Wl(a),Xl(a),a.i.variants.some(function(x){return x.primary}),a.A.Fa(d,"loadedmetadata",function(){a.B.l=Date.now()/1E3-
405
+ c.Ke}),z(y)}})}
406
+ function il(a,b,c){var d,e,f,g,h,k,l;return I(function(m){return 1==m.g?(d=Jb,e=Date.now()/1E3,f=!0,a.m=Dl(a,{Ob:a.H,onError:function(n){vl(a,n)},wd:function(n){El(a,n)},onExpirationUpdated:function(n,p){Fl(a,n,p)},onEvent:function(n){a.dispatchEvent(n);"drmsessionupdate"==n.type&&f&&(f=!1,a.B.j=Date.now()/1E3-e)}}),a.m.configure(a.h.drm),g=c.uri||"",h=ug(g),k=tl[h],"application/x-mpegurl"==k&&Zc()&&(k="application/vnd.apple.mpegurl"),k||(k="video/mp4"),l={id:0,language:"und",disabledUntilTime:0,primary:!1,
407
+ audio:null,video:{id:0,originalId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:null,mimeType:c.mimeType?c.mimeType.split(";")[0]:k,codecs:c.mimeType?Fd(c.mimeType):"",encrypted:!0,drmInfos:[],keyIds:new Set,language:"und",label:null,type:d.Ma,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null},bandwidth:100,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},
408
+ a.m.X=!0,u(m,Lf(a.m,[l],[]),2)):u(m,a.m.yc(b.O),0)})}
409
+ function jl(a,b,c){function d(){return Gl(a)}b.uri=c.uri;b.startTime=c.startTime;a.gb=b.uri;var e=b.O;a.F=new Ti(e);var f=!1;a.fb.push(function(){f=!0});null!=b.startTime&&a.F.Yd(b.startTime);a.I=new dj({md:function(){return e.playbackRate},jd:function(){return e.defaultPlaybackRate},Fe:function(k){e.playbackRate=k},zf:function(k){e.currentTime+=k}});Ml(a,a.h.streaming.rebufferingGoal);a.A.o(e,"playing",d);a.A.o(e,"pause",d);a.A.o(e,"ended",d);a.A.o(e,"ratechange",function(){return Hl(a)});"none"!=
410
+ e.preload&&a.A.Fa(e,"loadedmetadata",function(){a.B.l=Date.now()/1E3-c.Ke});e.audioTracks&&(a.A.o(e.audioTracks,"addtrack",function(){return Wl(a)}),a.A.o(e.audioTracks,"removetrack",function(){return Wl(a)}),a.A.o(e.audioTracks,"change",function(){return Wl(a)}));e.textTracks&&(a.A.o(e.textTracks,"addtrack",function(k){if(k.track)switch(k=k.track,k.kind){case "metadata":Yl(a,k);break;case "chapters":Pl(a,k);break;default:Wl(a)}}),a.A.o(e.textTracks,"removetrack",function(){return Wl(a)}),a.A.o(e.textTracks,
411
+ "change",function(){return Wl(a)}));var g=ug(b.uri);e.src=Bk(a.S,b.uri,tl[g]);(Wc()||Vc("Web0S"))&&e.load();a.l=Zl;a.dispatchEvent(ll("streaming"));var h=new Nc;Ki(e,HTMLMediaElement.HAVE_METADATA,a.A,function(){h.resolve()});Ki(e,HTMLMediaElement.HAVE_CURRENT_DATA,a.A,function(){var k;return I(function(l){if(1==l.g)return $l(a),k=am(a),k.find(function(m){return"disabled"!=m.mode})?l.D(2):u(l,new Promise(function(m){a.A.Fa(e.textTracks,"change",m);(new P(m)).T(1)}),2);if(f)return l["return"]();bm(a);
412
+ z(l)})});e.error?h.reject(ul(a)):"none"==e.preload&&(Ua('With <video preload="none">, the browser will not load anything until play() is called. We are unable to measure load latency in a meaningful way, and we cannot provide track info yet. Please do not use preload="none" with Shaka Player.'),h.resolve());a.A.Fa(e,"error",function(){h.reject(ul(a))});return new Ye(h,function(){h.reject(new O(2,7,7001));return Promise.resolve()})}
413
+ function $l(a){var b=a.h.preferredAudioLanguage;if(""!=b){a.Ed(b);var c=a.h.preferredVariantRole;""!=c&&a.Ed(b,c)}}function bm(a){var b=a.h.preferredTextLanguage,c=a.h.preferForcedSubs;if(""!=b){a.ye(b,"",c);var d=a.h.preferredTextRole;""!=d&&a.ye(b,d,c)}}
414
+ function Yl(a,b){if("metadata"==b.kind){b.mode="hidden";a.A.o(b,"cuechange",function(){if(b.activeCues)for(var d=t(b.activeCues),e=d.next();!e.done;e=d.next())if(e=e.value,yl(a,e.startTime,e.endTime,e.type,e.value),a.G)a.G.onCueMetadataChange(e.value)});var c=(new P(function(){var d=cm(a);d=t(d);for(var e=d.next();!e.done;e=d.next())e.value.mode="hidden"})).xa().T(.5);a.fb.push(function(){c.stop()})}}
415
+ function yl(a,b,c,d,e){b=(new Map).set("startTime",b).set("endTime",c).set("metadataType",d).set("payload",e);a.dispatchEvent(ll("metadata",b))}function Pl(a,b){if(b&&"chapters"==b.kind){b.mode="hidden";var c=(new P(function(){b.mode="hidden"})).xa().T(.5);a.fb.push(function(){c.stop()})}}function Cl(a){function b(c){return c.video&&c.audio||c.video&&c.video.codecs.includes(",")}a.variants.some(b)&&(a.variants=a.variants.filter(b))}function Dl(a,b){return new Ef(b,a.h.drm.updateExpirationTime)}
416
+ function $k(a){return new jf(function(b,c){a.C&&a.C.segmentDownloaded(b,c)},function(b,c,d){b=(new Map).set("headers",b).set("request",c).set("requestType",d);a.dispatchEvent(ll("downloadheadersreceived",b))},function(b,c,d,e){b=(new Map).set("request",b).set("error",c).set("httpResponseCode",d).set("aborted",e);a.dispatchEvent(ll("downloadfailed",b))})}
417
+ function Kl(a,b){return new Ui(a.g,a.i,a.h.streaming,b,function(){a.Xa&&gj(a.Xa,!0);a.j&&a.j.Rc();a.N&&dm(a)},function(c){return a.dispatchEvent(c)})}
418
+ function Ll(a){var b=new mj(a.Bd);b.addEventListener("enter",function(d){zl(a,"timelineregionenter",d.region)});b.addEventListener("exit",function(d){zl(a,"timelineregionexit",d.region)});b.addEventListener("skip",function(d){var e=d.region;d.seeking||(zl(a,"timelineregionenter",e),zl(a,"timelineregionexit",e))});var c=new fj(a.g);c.g.add(b);a.ea&&c.g.add(a.ea);return c}function Ml(a,b){a.N=new Re;a.N.g=Te;Ue(a.N,b,Math.min(.5,b/2));wl(a);a.pd=(new P(function(){dm(a)})).ka(.25)}
419
+ function dm(a){switch(a.l){case Zl:if(a.g.ended)var b=!0;else{var c=bi(a.g.buffered);b=null!=c&&c>=a.g.duration-1}break;case Ol:a:if(a.g.ended||mi(a.K))b=!0;else{if(a.i.presentationTimeline.U()){c=a.i.presentationTimeline.Ib();var d=bi(a.g.buffered);if(null!=d&&d>=c){b=!0;break a}}b=!1}break;default:b=!1}d=di(a.g.buffered,a.g.currentTime);c=a.N;var e=b,f=c.h.get(c.g);b=c.g;d=e||d>=f?Se:Te;c.g=d;b!=d&&wl(a)}function xl(a,b,c,d){return new gi(a,b,c,d)}
420
+ function sl(a){return new pk({getBandwidthEstimate:function(){return a.C?a.C.getBandwidthEstimate():NaN},kb:function(){return a.kb()},getCurrentTime:function(){return a.g?a.g.currentTime:0},Qa:function(){return a.Qa()},zb:function(){return a.zb()},U:function(){return a.U()}},a.h.cmcd)}
421
+ function Nl(a){return new sj(a.i,{ld:function(){return a.F.bd()},getBandwidthEstimate:function(){return a.C.getBandwidthEstimate()},modifySegmentRequest:function(b,c){qk(a.S,b,c)},V:a.K,Ob:a.H,onError:function(b){return vl(a,b)},onEvent:function(b){return a.dispatchEvent(b)},Vg:function(){a.J&&a.J.update&&a.J.update()},pe:function(){a.F&&a.F.Af();dm(a)},Ug:function(b,c){var d=c.je;d&&a.ea&&jj(a.ea,d,b)}})}
422
+ q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=Lk(a,b));a.streaming&&a.streaming.lowLatencyMode&&(void 0==a.streaming.inaccurateManifestTolerance&&(a.streaming.inaccurateManifestTolerance=0),void 0==a.streaming.rebufferingGoal&&(a.streaming.rebufferingGoal=.01));var c=Qk(this.h,a,Zk(this));em(this);return c};
423
+ function em(a){if(a.J){var b=ef(a.h.manifest);a.g&&"AUDIO"===a.g.nodeName&&(b.disableVideo=!0);a.J.configure(b)}a.m&&a.m.configure(a.h.drm);if(a.j){a.j.configure(a.h.streaming);try{fm(a,a.i)}catch(f){vl(a,f)}a.C&&Xl(a);b=a.j.l;!b||b.allowedByApplication&&b.allowedByKeySystem||gm(a)}a.H&&a.H.De(a.h.streaming.forceHTTPS);if(a.K&&(a.K.H=a.h.manifest.segmentRelativeVttTiming,b=a.h.textDisplayFactory,a.Pe!=b)){var c=b(),d=a.K,e=d.m;d.m=c;e&&(c.setTextVisibility(e.isTextVisible()),e.destroy());d.g&&(d.g.i=
424
+ c);a.Pe=b;a.j&&(b=a.j,(c=b.h.get(Ib))&&Cj(b,c.stream,!0,0,!0))}a.C&&(a.C.configure(a.h.abr),a.h.abr.enabled?a.C.enable():a.C.disable(),Ul(a));a.N&&(b=a.h.streaming.rebufferingGoal,a.i&&(b=Math.max(b,a.i.minBufferTime)),Ue(a.N,b,Math.min(.5,b/2)));a.i&&Il(a.i.presentationTimeline,a.h.playRangeStart,a.h.playRangeEnd)}q.getConfiguration=function(){var a=Zk(this);Qk(a,this.h,Zk(this));return a};
425
+ q.gg=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.Ia().end);if(a>=b)return 1;if(!(a<=this.g.currentTime)&&a<b)return(a-this.g.currentTime)/(b-this.g.currentTime)}return 0};q.fh=function(){for(var a in this.h)delete this.h[a];Qk(this.h,Zk(this),Zk(this));em(this)};q.rf=function(){return this.l};q.yg=function(){return this.g};q.Ec=function(){return this.H};q.Zd=function(){return this.gb};
424
426
  q.hd=function(){return this.G?this.G:null};q.U=function(){return this.i?this.i.presentationTimeline.U():this.g&&this.g.src?Infinity==this.g.duration:!1};q.Lb=function(){return this.i?this.i.presentationTimeline.Lb():!1};q.ec=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};
425
- q.Ia=function(){if(this.i){var a=this.i.presentationTimeline;return{start:a.cc(),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}};q.Ig=function(){this.U()&&(this.g.currentTime=this.Ia().end)};q.keySystem=function(){var a=this.drmInfo();return a?a.keySystem:""};q.drmInfo=function(){return this.m?this.m.g:null};q.Dc=function(){return this.m?this.m.Dc():Infinity};q.kd=function(){return this.m?this.m.kd():{}};
426
- q.Kc=function(){return this.N?this.N.g==Qe:!1};q.zb=function(){return this.g?this.I?this.I.i:1:0};q.Ne=function(a){0==a?Ua("A trick play rate of 0 is unsupported!"):(this.g.paused&&this.g.play(),this.I.set(a),this.l==Ll&&(this.C.playbackRateChanged(a),yj(this.j,1<Math.abs(a))))};q.Ze=function(){var a=this.I.jd();this.l==Wl&&this.I.set(a);this.l==Ll&&(this.I.set(a),this.C.playbackRateChanged(a),yj(this.j,!1))};
427
- q.Qa=function(){if(this.i){for(var a=this.j?this.j.l:null,b=[],c=0,d=t(this.i.variants),e=d.next();!e.done;e=d.next())if(e=e.value,we(e)){var f=oe(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 ve(g)}):[]};
428
- q.Ab=function(){if(this.i){for(var a=this.j?this.j.A:null,b=[],c=t(this.i.textStreams),d=c.next();!d.done;d=c.next()){d=d.value;var e=pe(d);e.active=d==a;b.push(e)}return b}return this.g&&this.g.src&&this.g.textTracks?Yl(this).map(function(f){return te(f)}):[]};q.og=function(){return this.i?this.i.imageStreams.map(function(a){return qe(a)}):[]};
429
- q.Eg=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,p,r,x,y,w,v,D,C,B;return I(function(G){if(1==G.g)return c.i?(d=c.i.imageStreams.find(function(E){return E.id==a}))?d.segmentIndex?G.D(3):u(G,d.createSegmentIndex(),3):G["return"](null):G.D(2);if(2!=G.g){e=d.segmentIndex.find(b);if(null==e)return G["return"](null);f=d.segmentIndex.get(e);g=f.tilesLayout||d.tilesLayout;h=/(\d+)x(\d+)/.exec(g);if(!h)return G["return"](null);k=d.width||0;l=d.height||0;m=parseInt(h[1],10);n=parseInt(h[2],10);p=k/m;r=l/n;
430
- x=m*n;y=f.j-f.startTime;w=f.l||y/x;v=f.startTime;C=D=0;1<x&&(B=Math.floor((b-f.startTime)/w),v=f.startTime+B*w,D=B%m*p,C=Math.floor(B/m)*r);return G["return"]({imageHeight:l,imageWidth:k,height:r,positionX:D,positionY:C,startTime:v,duration:w,uris:f.Pa(),width:p})}return G["return"](null)})};
431
- q.ye=function(a){if(this.i&&this.j){var b=this.i.textStreams.find(function(d){return d.id==a.id});b&&b!=this.j.A&&(Tk(this.B.h,b,!1),Bj(this.j,b),em(this),this.za=b.language)}else if(this.g&&this.g.src&&this.g.textTracks){b=Yl(this);b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,re(c)==a.id?c.mode=this.ba?"showing":"hidden":c.mode="disabled";em(this)}};
432
- q.ze=function(a,b,c){b=void 0===b?!1:b;c=void 0===c?0:c;if(this.i&&this.j){this.h.abr.enabled&&Ua("Changing tracks while abr manager is enabled will likely result in the selected track being overriden. Consider disabling abr before calling selectVariantTrack().");var d=this.i.variants.find(function(e){return e.id==a.id});d&&we(d)&&(Gl(this,d,!1,b,c),this.ya=new Je(d),Ul(this))}else if(this.g&&this.g.audioTracks)for(b=Array.from(this.g.audioTracks),b=t(b),c=b.next();!c.done;c=b.next())if(c=c.value,
433
- re(c)==a.id){fm(this,c);break}};q.eg=function(){return gm(this.Qa())};q.Dg=function(){return gm(this.Ab())};q.dg=function(){return Array.from(hm(this.Qa()))};q.Cg=function(){return Array.from(hm(this.Ab()))};
434
- q.Ed=function(a,b){if(this.i&&this.F){this.ya=new Ke(a,b||"",0,"");var c=function(k,l){return k.video||l.video?k.video&&l.video?Math.abs((k.video.height||0)-(l.video.height||0))+Math.abs((k.video.width||0)-(l.video.width||0)):Infinity:0},d=this.j.l,e=this.ya.create(this.i.variants),f=null;e=t(e.values());for(var g=e.next();!g.done;g=e.next())if(g=g.value,!f||c(f,d)>c(g,d))f=g;f?(c=oe(f),this.ze(c,!0)):dm(this)}else if(this.g&&this.g.audioTracks){e=Array.from(this.g.audioTracks);c=Mb(a);f=d=null;e=
435
- t(e);for(g=e.next();!g.done;g=e.next()){g=g.value;var h=ve(g);Mb(h.language)==c&&(d=g,b?h.roles.includes(b)&&(f=g):0==h.roles.length&&(f=g))}f?fm(this,f):d&&fm(this,d)}};
436
- q.xe=function(a,b,c){c=void 0===c?!1:c;if(this.i&&this.F){if(this.za=a,this.wb=b||"",this.ib=c,(a=ye(this.i.textStreams,this.za,this.wb,this.ib)[0]||null)&&a!=this.j.A&&(Tk(this.B.h,a,!1),this.h.streaming.alwaysStreamText||this.Nb()))Bj(this.j,a),em(this)}else{var d=Mb(a);(a=this.Ab().find(function(e){return Mb(e.language)==d&&(!b||e.roles.includes(b))&&e.forced==c}))&&this.ye(a)}};
437
- q.hh=function(a){if(this.i&&this.F){for(var b=null,c=t(this.i.variants),d=c.next();!d.done;d=c.next())if(d=d.value,d.audio.label==a){b=d;break}null!=b&&(this.ya=new Ke(b.language,"",0,a),dm(this))}};q.Nb=function(){var a=this.ba;return this.K?this.K.m.isTextVisible():this.g&&this.g.src&&this.g.textTracks?Yl(this).some(function(b){return"showing"==b.mode}):a};q.nf=function(){return this.g&&this.g.src&&this.g.textTracks?im(this).map(function(a){return te(a)}):[]};
438
- q.hg=function(a){var b=Mb(a),c=im(this).filter(function(g){return Mb(g.language)==b});if(!c||!c.length)return[];a=[];c=t(c);for(var d=c.next();!d.done;d=c.next())if((d=d.value)&&d.cues){d=t(d.cues);for(var e=d.next();!e.done;e=d.next()){e=e.value;var f=e.id;f&&""!=f||(f=e.startTime+"-"+e.endTime+"-"+e.text);a.push({id:f,title:e.text,startTime:e.startTime,endTime:e.endTime})}}return a};
439
- function Yl(a){return Array.from(a.g.textTracks).filter(function(b){return"metadata"!=b.kind&&"chapters"!=b.kind&&"Shaka Player TextTrack"!=b.label})}function $l(a){return Array.from(a.g.textTracks).filter(function(b){return"metadata"==b.kind})}function im(a){return Array.from(a.g.textTracks).filter(function(b){return"chapters"==b.kind})}
440
- q.He=function(a){a=!!a;if(this.ba!=a){this.ba=a;if(this.l==Ll)this.K.m.setTextVisibility(a),this.h.streaming.alwaysStreamText||(a?this.j.A||(a=ye(this.i.textStreams,this.za,this.wb,this.ib),0<a.length&&(Bj(this.j,a[0]),em(this))):xj(this.j));else if(this.g&&this.g.src&&this.g.textTracks){var b=Yl(this);b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,"disabled"!=c.mode&&(c.mode=a?"showing":"hidden")}Ql(this)}};
441
- q.zg=function(){if(!this.U())return null;var a=this.ma.l,b=0;if(this.F)b=this.F.bd();else if(a){if(null==a.startTime)return new Date;b=a.startTime}return this.i?new Date(1E3*(this.i.presentationTimeline.l+b)):this.g&&this.g.getStartDate?(a=this.g.getStartDate(),isNaN(a.getTime())?null:new Date(a.getTime()+1E3*b)):null};
442
- q.rf=function(){if(!this.U())return null;if(this.i)return new Date(1E3*this.i.presentationTimeline.l);if(this.g&&this.g.getStartDate){var a=this.g.getStartDate();return isNaN(a.getTime())?null:a}return null};q.kb=function(){if(this.l==Ll)return this.K.kb();var a={total:[],audio:[],video:[],text:[]};this.l==Wl&&(a.total=Xh(this.g.buffered));return a};
443
- q.getStats=function(){if(this.l!=Ll&&this.l!=Wl)return{width:NaN,height:NaN,streamBandwidth:NaN,decodedFrames:NaN,droppedFrames:NaN,corruptedFrames:NaN,stallsDetected:NaN,gapsJumped:NaN,estimatedBandwidth:NaN,completionPercent:NaN,loadLatency:NaN,manifestTimeSeconds:NaN,drmTimeSeconds:NaN,playTime:NaN,pauseTime:NaN,bufferingTime:NaN,licenseTime:NaN,liveLatency:NaN,maxSegmentDuration:NaN,switchHistory:[],stateHistory:[]};Dl(this);var a=this.g,b=a.currentTime/a.duration;if(!isNaN(b)){var c=this.B;b=
444
- Math.round(100*b);c.i=isNaN(c.i)?b:Math.max(c.i,b)}this.F&&(this.B.N=this.F.Ue(),this.B.P=this.F.Ve());a.getVideoPlaybackQuality&&(a=a.getVideoPlaybackQuality(),c=this.B,b=Number(a.totalVideoFrames),c.K=Number(a.droppedVideoFrames),c.J=b,this.B.I=Number(a.corruptedVideoFrames));this.m?(a=this.m,a=a.J?a.J:NaN):a=NaN;this.B.m=a;if(this.l==Ll){if(a=this.j.l)this.B.B=(this.I?this.I.i:1)*a.bandwidth;a&&a.video&&(c=this.B,b=a.video.height||NaN,c.S=a.video.width||NaN,c.C=b);this.U()&&(a=this.rf().valueOf()+
445
- 1E3*this.Ia().end,this.B.F=(Date.now()-a)/1E3);this.i&&this.i.presentationTimeline&&(this.B.H=this.i.presentationTimeline.g);a=this.C.getBandwidthEstimate();this.B.A=a}var d=this.B;a=d.S;c=d.C;b=d.B;var e=d.J,f=d.K,g=d.I,h=d.P,k=d.N,l=d.A,m=d.i,n=d.l,p=d.G,r=d.j,x=Qk(d.g,"playing"),y=Qk(d.g,"paused"),w=Qk(d.g,"buffering"),v=d.m,D=d.F,C=d.H,B=Rk(d.g),G=[];d=t(d.h.g);for(var E=d.next();!E.done;E=d.next())E=E.value,G.push({timestamp:E.timestamp,id:E.id,type:E.type,fromAdaptation:E.fromAdaptation,bandwidth:E.bandwidth});
446
- return{width:a,height:c,streamBandwidth:b,decodedFrames:e,droppedFrames:f,corruptedFrames:g,stallsDetected:h,gapsJumped:k,estimatedBandwidth:l,completionPercent:m,loadLatency:n,manifestTimeSeconds:p,drmTimeSeconds:r,playTime:x,pauseTime:y,bufferingTime:w,licenseTime:v,liveLatency:D,maxSegmentDuration:C,stateHistory:B,switchHistory:G}};
447
- q.Uf=function(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h=this,k,l,m,n,p,r,x,y,w,v,D;return I(function(C){switch(C.g){case 1:if(h.l!=Ll&&h.l!=Wl)throw new O(1,7,7004);if(d){C.D(2);break}return u(C,jm(h,a),3);case 3:d=C.h;case 2:k=[];if(h.G)try{k=h.G.getServerSideCuePoints()}catch(B){}if(h.l!=Wl){C.D(4);break}g&&(c="forced");return u(C,km(h,a,b,c,d,f||"",k),5);case 5:l=h.Ab();if(m=l.find(function(B){return B.language==b&&B.label==(f||"")&&B.kind==c}))return Tl(h),C["return"](m);throw new O(1,2,2012);case 4:n=
448
- Jb;p=h.i.presentationTimeline.getDuration();if(Infinity==p)throw new O(1,4,4033);if(!k.length){C.D(6);break}return u(C,lm(h,a,h.H,h.h.streaming.retryParameters),7);case 7:r=C.h,x=mm(h,r,d,k),y=new Blob([x],{type:"text/vtt"}),a=bi(y),d="text/vtt";case 6:w={id:h.Pf++,originalId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:Zi(0,p,[a]),mimeType:d||"",codecs:e||"",kind:c,encrypted:!1,drmInfos:[],keyIds:new Set,language:b,label:f||null,type:n.ha,primary:!1,trickModeVideo:null,
449
- emsgSchemeIdUris:null,roles:[],forced:!!g,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null};v=jd(w.mimeType,w.codecs);D=pd(v);if(!D)throw new O(2,2,2014,d);h.i.textStreams.push(w);Tl(h);return C["return"](pe(w))}})};
450
- q.Tf=function(a,b,c){var d=this,e,f,g,h;return I(function(k){switch(k.g){case 1:if(d.l!=Ll&&d.l!=Wl)throw new O(1,7,7004);if(c){k.D(2);break}return u(k,jm(d,a),3);case 3:c=k.h;case 2:e=[];if(d.G)try{e=d.G.getServerSideCuePoints()}catch(l){}return u(k,km(d,a,b,"chapters",c,"",e),4);case 4:f=k.h;g=d.nf();h=g.find(function(l){return l.language==b});if(!h){k.D(5);break}return u(k,new Promise(function(l,m){d.A.Fa(f,"load",l);d.A.Fa(f,"error",function(){m(new O(1,2,2015))})}),6);case 6:return k["return"](h);
451
- case 5:throw new O(1,2,2012);}})};function jm(a,b){var c,d;return I(function(e){switch(e.g){case 1:c=rg(b);if(d=nm[c])return e["return"](d);A(e,2);return u(e,tg(b,a.H,a.h.streaming.retryParameters),4);case 4:d=e.h;va(e,3);break;case 2:F(e);case 3:if(d)return e["return"](d);throw new O(1,2,2011,c);}})}
452
- function km(a,b,c,d,e,f,g){var h,k,l,m;return I(function(n){if(1==n.g)return"text/vtt"!=e||g.length?u(n,lm(a,b,a.H,a.h.streaming.retryParameters),3):n.D(2);2!=n.g&&(h=n.h,k=mm(a,h,e,g),l=new Blob([k],{type:"text/vtt"}),b=bi(l),e="text/vtt");m=document.createElement("track");var p=a.S,r=b;try{if(p.g.enabled){var x=zk(p);x.ot=Fk;x.su=!0;var y=Bk(x);var w=Ck(r,y)}else w=r}catch(v){Va("CMCD_TEXT_TRACK_ERROR","Could not generate text track CMCD data.",v),w=r}m.src=w;m.label=f;m.kind=d;m.srclang=c;a.g.getAttribute("crossorigin")||
453
- a.g.setAttribute("crossorigin","anonymous");a.g.appendChild(m);return n["return"](m)})}function lm(a,b,c,d){var e,f,g;return I(function(h){if(1==h.g){e=qf;f=kf([b],d);f.method="GET";var k=a.S;try{k.g.enabled&&xk(k,f,{ot:Fk,su:!0})}catch(l){Va("CMCD_TEXT_ERROR","Could not generate text CMCD data.",l)}return u(h,c.request(e,f).promise,2)}g=h.h;return h["return"](g.data)})}
454
- function mm(a,b,c,d){var e=qd[c];if(e)return c=e(),a={periodStart:0,segmentStart:0,segmentEnd:a.g.duration,vttOffset:0},b=Gc(b),b=c.parseMedia(b,a),lk(b,d);throw new O(2,2,2014,c);}q.De=function(a,b){this.Bc.width=a;this.Bc.height=b};q.se=function(){if(this.l==Ll){var a=this.j;if(a.j.g)a=!1;else if(a.B)a=!1;else{for(var b=t(a.h.values()),c=b.next();!c.done;c=b.next())c=c.value,c.Ic&&(c.Ic=!1,wj(a,c,.1));a=!0}}else a=!1;return a};
455
- q.ug=function(){Ua("Shaka Player's internal Manifest structure is NOT covered by semantic versioning compatibility guarantees. It may change at any time! Please consider filing a feature request for whatever you use getManifest() for.");return this.i};q.vg=function(){return this.ud};
456
- function Wk(a){var b=Lk();b.streaming.failureCallback=function(c){var d=[1001,1002,1003];a.U()&&d.includes(c.code)&&(c.severity=1,a.se())};b.textDisplayFactory=function(){return a.od?new ek(a.g,a.od):new Yj(a.g)};return b}q.Ie=function(a){this.od=a};
457
- function yl(a,b){for(var c=new Set,d=t(b.textStreams),e=d.next();!e.done;e=d.next())e=e.value,"application/cea-608"!=e.mimeType&&"application/cea-708"!=e.mimeType||c.add(e.originalId);d=t(b.variants);for(e=d.next();!e.done;e=d.next())if((e=e.value.video)&&e.closedCaptions)for(var f=t(e.closedCaptions.keys()),g=f.next();!g.done;g=f.next())if(g=g.value,!c.has(g)){var h=g.startsWith("CC")?"application/cea-608":"application/cea-708",k=new $i;h={id:a.Pf++,originalId:g,createSegmentIndex:function(){return Promise.resolve()},
458
- segmentIndex:k,mimeType:h,codecs:"",kind:"caption",encrypted:!1,drmInfos:[],keyIds:new Set,language:e.closedCaptions.get(g),label:null,type:Ib,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:e.roles,forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null};b.textStreams.push(h);c.add(g)}}function xl(a,b){return I(function(c){if(1==c.g)return u(c,om(a,b),2);cm(a,b);z(c)})}
459
- function om(a,b){var c;return I(function(d){if(1==d.g)return c=a.j?a.j.l:null,u(d,ae(c,b),2);Sl(b);z(d)})}
460
- function cm(a,b){if(a.l!=kl){$d(b.variants,a.h.restrictions,a.Bc)&&a.j&&Tl(a);var c=a.m?a.m.g:null;if(c&&a.m.B)for(var d=t(b.variants),e=d.next();!e.done;e=d.next()){e=e.value;e=t((e.video?e.video.drmInfos:[]).concat(e.audio?e.audio.drmInfos:[]));for(var f=e.next();!f.done;f=e.next())if(f=f.value,f.keySystem==c.keySystem){f=t(f.initData||[]);for(var g=f.next();!g.done;g=f.next())g=g.value,Rf(a.m,g.initDataType,g.initData)}}pm(a,b)}}
461
- function Nl(a,b){var c,d,e,f,g;return I(function(h){if(1==h.g)return c=a.audio,d=a.video,e=function(k,l){var m,n,p;return I(function(r){if(1==r.g)return k?u(r,k.createSegmentIndex(),2):r["return"](null);n=(m=k.segmentIndex.ac(l))?m.next().value:null;if(!n)return r["return"](null);p=n.startTime;return r["return"](p)})},u(h,e(c,b),2);if(3!=h.g)return f=h.h,u(h,e(d,b),3);g=h.h;return null!=g&&null!=f?h["return"](Math.max(g,f)):null!=g?h["return"](g):null!=f?h["return"](f):h["return"](b)})}
462
- function tl(a){var b=a.Kc();if(a.B&&a.N&&a.F){var c=a.I;c.j=b;bj(c);a.S&&(c=a.S,b||c.i||(c.i=!0),c.i&&b&&(c.l=!0),c.m=b);Dl(a)}b=(new Map).set("buffering",b);a.dispatchEvent(il("buffering",b))}function El(a){var b=a.g.playbackRate;0!=b&&(a.I&&a.I.set(b),b=il("ratechange"),a.dispatchEvent(b))}function Dl(a){if(a.B&&a.N){var b=a.B.g;a.N.g==Qe?Pk(b,"buffering"):a.g.paused?Pk(b,"paused"):a.g.ended?Pk(b,"ended"):Pk(b,"playing")}}
463
- function Ul(a){try{pm(a,a.i)}catch(c){return sl(a,c),!1}var b=a.i.variants.filter(function(c){return we(c)});b=a.ya.create(b);a.C.setVariants(Array.from(b.values()));return!0}function jl(a){return Ul(a)?a.C.chooseVariant():null}function dm(a){var b=jl(a);b&&Gl(a,b,!0,!0,0)}
464
- function Gl(a,b,c,d,e){var f=a.j.l;if(b==f)d&&Aj(a.j,b,d,e,!0);else{var g=a.B.h;g.h!=b&&(g.h=b,g.g.push({timestamp:Date.now()/1E3,id:b.id,type:"variant",fromAdaptation:c,bandwidth:b.bandwidth}));Aj(a.j,b,d,e);d=null;f&&(d=oe(f));b=oe(b);c?Ol(a,d,b):qm(a,d,b)}}function fm(a,b){var c=Array.from(a.g.audioTracks).find(function(e){return e.enabled});b.enabled=!0;b.id!==c.id&&(c.enabled=!1);c=ve(c);var d=ve(b);qm(a,c,d)}
465
- function Pl(a,b,c){a=Mb(a.h.preferredTextLanguage);b=Mb(b.language);c=Mb(c.language);return Lb(c,a)&&!Lb(b,c)}function Ol(a,b,c){b=(new Map).set("oldTrack",b).set("newTrack",c);b=il("adaptation",b);rm(a,b)}function Tl(a){var b=il("trackschanged");rm(a,b)}function qm(a,b,c){b=(new Map).set("oldTrack",b).set("newTrack",c);b=il("variantchanged",b);rm(a,b)}function em(a){var b=il("textchanged");rm(a,b)}function Ql(a){var b=il("texttrackvisibility");rm(a,b)}
466
- function Rl(a){var b=(new Map).set("newStatus",a.h.abr.enabled);rm(a,il("abrstatuschanged",b))}
467
- function sm(a,b){if(1002!=b.code&&1011!=b.code||1!=b.category)return!1;var c=a.h.streaming.maxDisabledTime;if(0==c)if(1011==b.code)c=1;else return!1;for(var d=a.Qa().find(function(h){return h.active}),e=a.i,f=t(e.variants),g=f.next();!g.done;g=f.next())g=g.value,g.id===d.id&&(g.disabledUntilTime=Date.now()/1E3+c);$d(e.variants,a.h.restrictions,a.Bc);d=jl(a);if(!d)return!1;e=a.kb().video.reduce(function(h,k){return h+k.end-k.start},0);Gl(a,d,!1,!0,e);a.Of.T(c);return!0}
468
- function sl(a,b){if(a.l!=kl)if(sm(a,b))b.handled=!0;else{var c=il("error",(new Map).set("detail",b));a.dispatchEvent(c);c.defaultPrevented&&(b.handled=!0)}}function wl(a,b,c){c=(new Map).set("detail",{schemeIdUri:c.schemeIdUri,value:c.value,startTime:c.startTime,endTime:c.endTime,id:c.id,eventElement:c.eventElement});a.dispatchEvent(il(b,c))}
469
- function rl(a){if(!a.g.error)return null;var b=a.g.error.code;if(1==b)return null;var c=a.g.error.msExtendedCode;c&&(0>c&&(c+=Math.pow(2,32)),c=c.toString(16));return new O(2,3,3016,b,c,a.g.error.message)}
470
- function Bl(a,b){if(a.j){var c=Object.keys(b),d=1==c.length&&"00"==c[0],e=!1;if(c.length){c=t(a.i.variants);for(var f=c.next();!f.done;f=c.next()){f=f.value;var g=[];f.audio&&g.push(f.audio);f.video&&g.push(f.video);g=t(g);for(var h=g.next();!h.done;h=g.next()){var k=h.value;h=f.allowedByKeySystem;if(k.keyIds.size){f.allowedByKeySystem=!0;k=t(k.keyIds);for(var l=k.next();!l.done;l=k.next())l=l.value,l=b[d?"00":l],f.allowedByKeySystem=f.allowedByKeySystem&&!!l&&!tm.includes(l)}h!=f.allowedByKeySystem&&
471
- (e=!0)}}}if(!e||Ul(a))(d=a.j.l)&&!d.allowedByKeySystem&&dm(a),e&&Tl(a)}}function Cl(a,b,c){if(a.J&&a.J.onExpirationUpdated)a.J.onExpirationUpdated(b,c);b=il("expirationupdated");a.dispatchEvent(b)}function Fl(a,b,c){0<b&&(a.U()||a.If(b));b=a.getDuration();c<b&&(a.U()||a.bb(c))}
472
- function pm(a,b){var c=a.m?a.m.kd():{},d=Object.keys(c);d=d.length&&"00"==d[0];for(var e=!1,f=!1,g=new Set,h=new Set,k=t(b.variants),l=k.next();!l.done;l=k.next()){l=l.value;var m=[];l.audio&&m.push(l.audio);l.video&&m.push(l.video);m=t(m);for(var n=m.next();!n.done;n=m.next())if(n=n.value,n.keyIds.size){n=t(n.keyIds);for(var p=n.next();!p.done;p=n.next()){p=p.value;var r=c[d?"00":p];r?tm.includes(r)&&h.add(r):g.add(p)}}l.allowedByApplication?l.allowedByKeySystem&&(e=!0):f=!0}if(!e)throw c={hasAppRestrictions:f,
473
- missingKeys:Array.from(g),restrictedKeyStatuses:Array.from(h)},new O(2,4,4012,c);}function Sl(a){if(!a.variants.some(we))throw new O(2,4,4032);}function rm(a,b){I(function(c){if(1==c.g)return u(c,Promise.resolve(),2);a.l!=kl&&a.dispatchEvent(b);z(c)})}function hm(a){var b=new Set;a=t(a);for(var c=a.next();!c.done;c=a.next())c=c.value,c.language?b.add(Mb(c.language)):b.add("und");return b}
474
- function gm(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=Mb(d.language));"variant"==d.type?f=d.audioRoles:f=d.roles;f&&f.length||(f=[""]);b.has(e)||b.set(e,new Set);f=t(f);for(var g=f.next();!g.done;g=f.next())g=g.value,b.get(e).add(g),d.label&&(c.has(e)||c.set(e,new Map),c.get(e).set(g,d.label))}var h=[];b.forEach(function(k,l){for(var m=t(k),n=m.next();!n.done;n=m.next()){n=n.value;var p=null;c.has(l)&&c.get(l).has(n)&&(p=c.get(l).get(n));
475
- h.push({language:l,role:n,label:p})}});return h}function ml(){return new O(2,7,7E3)}function hl(a,b,c,d,e,f){return d==a&&e.O==f.O&&e.uri==f.uri&&e.mimeType==f.mimeType?b:c}function Sj(){return{O:null,mimeType:null,startTime:null,Je:NaN,uri:null}}function nl(a){return new Promise(function(b,c){a.Pb=function(){return c(ml())};a.vd=function(){return b()};a.onError=function(d){return c(d)};a.xd=function(){return c(ml())}})}J("shaka.Player",S);S.prototype.setVideoContainer=S.prototype.Ie;
476
- S.prototype.getManifestParserFactory=S.prototype.vg;S.prototype.getManifest=S.prototype.ug;S.prototype.retryStreaming=S.prototype.se;S.prototype.setMaxHardwareResolution=S.prototype.De;S.prototype.addChaptersTrack=S.prototype.Tf;S.prototype.addTextTrackAsync=S.prototype.Uf;S.prototype.getStats=S.prototype.getStats;S.prototype.getBufferedInfo=S.prototype.kb;S.prototype.getPresentationStartTimeAsDate=S.prototype.rf;S.prototype.getPlayheadTimeAsDate=S.prototype.zg;
477
- S.prototype.setTextTrackVisibility=S.prototype.He;S.prototype.getChapters=S.prototype.hg;S.prototype.getChaptersTracks=S.prototype.nf;S.prototype.isTextTrackVisible=S.prototype.Nb;S.prototype.selectVariantsByLabel=S.prototype.hh;S.prototype.selectTextLanguage=S.prototype.xe;S.prototype.selectAudioLanguage=S.prototype.Ed;S.prototype.getTextLanguages=S.prototype.Cg;S.prototype.getAudioLanguages=S.prototype.dg;S.prototype.getTextLanguagesAndRoles=S.prototype.Dg;
478
- S.prototype.getAudioLanguagesAndRoles=S.prototype.eg;S.prototype.selectVariantTrack=S.prototype.ze;S.prototype.selectTextTrack=S.prototype.ye;S.prototype.getThumbnails=S.prototype.Eg;S.prototype.getImageTracks=S.prototype.og;S.prototype.getTextTracks=S.prototype.Ab;S.prototype.getVariantTracks=S.prototype.Qa;S.prototype.cancelTrickPlay=S.prototype.Ze;S.prototype.trickPlay=S.prototype.Ne;S.prototype.getPlaybackRate=S.prototype.zb;S.prototype.isBuffering=S.prototype.Kc;S.prototype.getKeyStatuses=S.prototype.kd;
479
- S.prototype.getExpiration=S.prototype.Dc;S.prototype.drmInfo=S.prototype.drmInfo;S.prototype.keySystem=S.prototype.keySystem;S.prototype.goToLive=S.prototype.Ig;S.prototype.seekRange=S.prototype.Ia;S.prototype.isAudioOnly=S.prototype.ec;S.prototype.isInProgress=S.prototype.Lb;S.prototype.isLive=S.prototype.U;S.prototype.getAdManager=S.prototype.hd;S.prototype.getAssetUri=S.prototype.Zd;S.prototype.getNetworkingEngine=S.prototype.Ec;S.prototype.getMediaElement=S.prototype.xg;
480
- S.prototype.getLoadMode=S.prototype.qf;S.prototype.resetConfiguration=S.prototype.eh;S.prototype.getBufferFullness=S.prototype.fg;S.prototype.getConfiguration=S.prototype.getConfiguration;S.prototype.configure=S.prototype.configure;S.prototype.load=S.prototype.load;S.prototype.updateStartTime=S.prototype.sh;S.prototype.unload=S.prototype.Pe;S.prototype.detach=S.prototype.detach;S.prototype.attach=S.prototype.yc;
481
- S.probeSupport=function(a){a=void 0===a?!0:a;var b,c,d,e,f,g;return I(function(h){if(1==h.g)return b={},a?u(h,hg(),3):h.D(2);2!=h.g&&(b=h.h);var k={};if(yd()){for(var l in qg)k[l]=!0;for(var m in sg)k[m]=!0}l={mpd:"application/dash+xml",m3u8:"application/x-mpegurl",ism:"application/vnd.ms-sstr+xml"};m=t(["application/dash+xml","application/x-mpegurl","application/vnd.apple.mpegurl","application/vnd.ms-sstr+xml"]);for(var n=m.next();!n.done;n=m.next())n=n.value,k[n]=yd()?!!qg[n]:zd(n);for(var p in l)k[p]=
482
- yd()?!!sg[p]:zd(l[p]);c=k;p='video/mp4; codecs="avc1.42E01E",video/mp4; codecs="avc3.42E01E",video/mp4; codecs="hev1.1.6.L93.90",video/mp4; codecs="hvc1.1.6.L93.90",video/mp4; codecs="hev1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="hvc1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="vp9",video/mp4; codecs="vp09.00.10.08",video/mp4; codecs="av01.0.01M.08",audio/mp4; codecs="mp4a.40.2",audio/mp4; codecs="ac-3",audio/mp4; codecs="ec-3",audio/mp4; codecs="opus",audio/mp4; codecs="flac",video/webm; codecs="vp8",video/webm; codecs="vp9",video/webm; codecs="vp09.00.10.08",audio/webm; codecs="vorbis",audio/webm; codecs="opus",video/mp2t; codecs="avc1.42E01E",video/mp2t; codecs="avc3.42E01E",video/mp2t; codecs="hvc1.1.6.L93.90",video/mp2t; codecs="mp4a.40.2",video/mp2t; codecs="ac-3",video/mp2t; codecs="ec-3",text/vtt,application/mp4; codecs="wvtt",application/ttml+xml,application/mp4; codecs="stpp"'.split(",").concat(ia(vi));
483
- k={};p=t(p);for(l=p.next();!l.done;l=p.next())l=l.value,k[l]=yd()?pd(l)?!0:MediaSource.isTypeSupported(l)||ed(l):zd(l),m=l.split(";")[0],k[m]=k[m]||k[l];d=k;e={manifest:c,media:d,drm:b};f=um;for(g in f)e[g]=f[g]();return h["return"](e)})};S.isBrowserSupported=ll;S.setAdManagerFactory=function(a){Yk=a};S.registerSupportPlugin=function(a,b){um[a]=b};S.prototype.destroy=S.prototype.destroy;var kl=0,Vk=1,Ll=2,Wl=3;S.LoadMode={DESTROYED:kl,NOT_LOADED:Vk,MEDIA_SOURCE:Ll,SRC_EQUALS:Wl};S.version="v4.1.1";
484
- var tm=["output-restricted","internal-error"],um={},Yk=null,ql={mp4:"video/mp4",m4v:"video/mp4",m4a:"audio/mp4",webm:"video/webm",weba:"audio/webm",mkv:"video/webm",ts:"video/mp2t",ogv:"video/ogg",ogg:"audio/ogg",mpg:"video/mpeg",mpeg:"video/mpeg",m3u8:"application/x-mpegurl",mpd:"application/dash+xml",mp3:"audio/mpeg",aac:"audio/aac",flac:"audio/flac",wav:"audio/wav"},nm={sbv:"text/x-subviewer",srt:"text/srt",vtt:"text/vtt",webvtt:"text/vtt",ttml:"application/ttml+xml",lrc:"application/x-subtitle-lrc",
485
- ssa:"text/x-ssa",ass:"text/x-ssa"};function vm(){this.h=[];this.j=this.i=this.g=0};function wm(a,b,c){var d=this;this.h=a;this.g=b;this.m=c;this.i=!1;this.l=this.g.getVolume();this.j=new tf;this.j.o(this.g,google.ima.AdEvent.Type.PAUSED,function(){d.i=!0});this.j.o(this.g,google.ima.AdEvent.Type.RESUMED,function(){d.i=!1})}q=wm.prototype;q.getDuration=function(){return this.h.getDuration()};q.getMinSuggestedDuration=function(){return this.h.getMinSuggestedDuration()};q.getRemainingTime=function(){return this.g.getRemainingTime()};q.isPaused=function(){return this.i};
427
+ q.Ia=function(){if(this.i){var a=this.i.presentationTimeline;return{start:a.cc(),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}};q.Jg=function(){this.U()&&(this.g.currentTime=this.Ia().end)};q.keySystem=function(){var a=this.drmInfo();return a?a.keySystem:""};q.drmInfo=function(){return this.m?this.m.g:null};q.Dc=function(){return this.m?this.m.Dc():Infinity};q.kd=function(){return this.m?this.m.kd():{}};
428
+ q.Kc=function(){return this.N?this.N.g==Te:!1};q.zb=function(){return this.g?this.I?this.I.i:1:0};q.Oe=function(a){0==a?Ua("A trick play rate of 0 is unsupported!"):(this.g.paused&&this.g.play(),this.I.set(a),this.l==Ol&&(this.C.playbackRateChanged(a),Bj(this.j,1<Math.abs(a))))};q.$e=function(){var a=this.I.jd();this.l==Zl&&this.I.set(a);this.l==Ol&&(this.I.set(a),this.C.playbackRateChanged(a),Bj(this.j,!1))};
429
+ q.Qa=function(){if(this.i){for(var a=this.j?this.j.l:null,b=[],c=0,d=t(this.i.variants),e=d.next();!e.done;e=d.next())if(e=e.value,ze(e)){var f=re(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 ye(g)}):[]};
430
+ q.Ab=function(){if(this.i){for(var a=this.j?this.j.A:null,b=[],c=t(this.i.textStreams),d=c.next();!d.done;d=c.next()){d=d.value;var e=se(d);e.active=d==a;b.push(e)}return b}return this.g&&this.g.src&&this.g.textTracks?am(this).map(function(f){return we(f)}):[]};q.pg=function(){return this.i?this.i.imageStreams.map(function(a){return te(a)}):[]};
431
+ q.Fg=function(a,b){var c=this,d,e,f,g,h,k,l,m,n,p,r,w,y,x,v,D,C,B;return I(function(G){if(1==G.g)return c.i?(d=c.i.imageStreams.find(function(E){return E.id==a}))?d.segmentIndex?G.D(3):u(G,d.createSegmentIndex(),3):G["return"](null):G.D(2);if(2!=G.g){e=d.segmentIndex.find(b);if(null==e)return G["return"](null);f=d.segmentIndex.get(e);g=f.tilesLayout||d.tilesLayout;h=/(\d+)x(\d+)/.exec(g);if(!h)return G["return"](null);k=d.width||0;l=d.height||0;m=parseInt(h[1],10);n=parseInt(h[2],10);p=k/m;r=l/n;
432
+ w=m*n;y=f.j-f.startTime;x=f.l||y/w;v=f.startTime;C=D=0;1<w&&(B=Math.floor((b-f.startTime)/x),v=f.startTime+B*x,D=B%m*p,C=Math.floor(B/m)*r);return G["return"]({imageHeight:l,imageWidth:k,height:r,positionX:D,positionY:C,startTime:v,duration:x,uris:f.Pa(),width:p})}return G["return"](null)})};
433
+ q.ze=function(a){if(this.i&&this.j){var b=this.i.textStreams.find(function(d){return d.id==a.id});b&&b!=this.j.A&&(Wk(this.B.h,b,!1),Ej(this.j,b),hm(this),this.za=b.language)}else if(this.g&&this.g.src&&this.g.textTracks){b=am(this);b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,ue(c)==a.id?c.mode=this.ba?"showing":"hidden":c.mode="disabled";hm(this)}};
434
+ q.Ae=function(a,b,c){b=void 0===b?!1:b;c=void 0===c?0:c;if(this.i&&this.j){this.h.abr.enabled&&Ua("Changing tracks while abr manager is enabled will likely result in the selected track being overriden. Consider disabling abr before calling selectVariantTrack().");var d=this.i.variants.find(function(e){return e.id==a.id});d&&ze(d)&&(Jl(this,d,!1,b,c),this.ya=new Me(d),Xl(this))}else if(this.g&&this.g.audioTracks)for(b=Array.from(this.g.audioTracks),b=t(b),c=b.next();!c.done;c=b.next())if(c=c.value,
435
+ ue(c)==a.id){im(this,c);break}};q.fg=function(){return jm(this.Qa())};q.Eg=function(){return jm(this.Ab())};q.eg=function(){return Array.from(km(this.Qa()))};q.Dg=function(){return Array.from(km(this.Ab()))};
436
+ q.Ed=function(a,b){if(this.i&&this.F){this.ya=new Ne(a,b||"",0,"");var c=function(k,l){return k.video||l.video?k.video&&l.video?Math.abs((k.video.height||0)-(l.video.height||0))+Math.abs((k.video.width||0)-(l.video.width||0)):Infinity:0},d=this.j.l,e=this.ya.create(this.i.variants),f=null;e=t(e.values());for(var g=e.next();!g.done;g=e.next())if(g=g.value,!f||c(f,d)>c(g,d))f=g;f?(c=re(f),this.Ae(c,!0)):gm(this)}else if(this.g&&this.g.audioTracks){e=Array.from(this.g.audioTracks);c=Mb(a);f=d=null;e=
437
+ t(e);for(g=e.next();!g.done;g=e.next()){g=g.value;var h=ye(g);Mb(h.language)==c&&(d=g,b?h.roles.includes(b)&&(f=g):0==h.roles.length&&(f=g))}f?im(this,f):d&&im(this,d)}};
438
+ q.ye=function(a,b,c){c=void 0===c?!1:c;if(this.i&&this.F){if(this.za=a,this.wb=b||"",this.ib=c,(a=Be(this.i.textStreams,this.za,this.wb,this.ib)[0]||null)&&a!=this.j.A&&(Wk(this.B.h,a,!1),this.h.streaming.alwaysStreamText||this.Nb()))Ej(this.j,a),hm(this)}else{var d=Mb(a);(a=this.Ab().find(function(e){return Mb(e.language)==d&&(!b||e.roles.includes(b))&&e.forced==c}))&&this.ze(a)}};
439
+ q.ih=function(a){if(this.i&&this.F){for(var b=null,c=t(this.i.variants),d=c.next();!d.done;d=c.next())if(d=d.value,d.audio.label==a){b=d;break}null!=b&&(this.ya=new Ne(b.language,"",0,a),gm(this))}};q.Nb=function(){var a=this.ba;return this.K?this.K.m.isTextVisible():this.g&&this.g.src&&this.g.textTracks?am(this).some(function(b){return"showing"==b.mode}):a};q.pf=function(){return this.g&&this.g.src&&this.g.textTracks?lm(this).map(function(a){return we(a)}):[]};
440
+ q.ig=function(a){var b=Mb(a),c=lm(this).filter(function(g){return Mb(g.language)==b});if(!c||!c.length)return[];a=[];c=t(c);for(var d=c.next();!d.done;d=c.next())if((d=d.value)&&d.cues){d=t(d.cues);for(var e=d.next();!e.done;e=d.next()){e=e.value;var f=e.id;f&&""!=f||(f=e.startTime+"-"+e.endTime+"-"+e.text);a.push({id:f,title:e.text,startTime:e.startTime,endTime:e.endTime})}}return a};
441
+ function am(a){return Array.from(a.g.textTracks).filter(function(b){return"metadata"!=b.kind&&"chapters"!=b.kind&&"Shaka Player TextTrack"!=b.label})}function cm(a){return Array.from(a.g.textTracks).filter(function(b){return"metadata"==b.kind})}function lm(a){return Array.from(a.g.textTracks).filter(function(b){return"chapters"==b.kind})}
442
+ q.Ie=function(a){a=!!a;if(this.ba!=a){this.ba=a;if(this.l==Ol)this.K.m.setTextVisibility(a),this.h.streaming.alwaysStreamText||(a?this.j.A||(a=Be(this.i.textStreams,this.za,this.wb,this.ib),0<a.length&&(Ej(this.j,a[0]),hm(this))):Aj(this.j));else if(this.g&&this.g.src&&this.g.textTracks){var b=am(this);b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value,"disabled"!=c.mode&&(c.mode=a?"showing":"hidden")}Tl(this)}};
443
+ q.Ag=function(){if(!this.U())return null;var a=this.ma.l,b=0;if(this.F)b=this.F.bd();else if(a){if(null==a.startTime)return new Date;b=a.startTime}return this.i?new Date(1E3*(this.i.presentationTimeline.l+b)):this.g&&this.g.getStartDate?(a=this.g.getStartDate(),isNaN(a.getTime())?null:new Date(a.getTime()+1E3*b)):null};
444
+ q.tf=function(){if(!this.U())return null;if(this.i)return new Date(1E3*this.i.presentationTimeline.l);if(this.g&&this.g.getStartDate){var a=this.g.getStartDate();return isNaN(a.getTime())?null:a}return null};q.kb=function(){if(this.l==Ol)return this.K.kb();var a={total:[],audio:[],video:[],text:[]};this.l==Zl&&(a.total=ei(this.g.buffered));return a};
445
+ q.getStats=function(){if(this.l!=Ol&&this.l!=Zl)return{width:NaN,height:NaN,streamBandwidth:NaN,decodedFrames:NaN,droppedFrames:NaN,corruptedFrames:NaN,stallsDetected:NaN,gapsJumped:NaN,estimatedBandwidth:NaN,completionPercent:NaN,loadLatency:NaN,manifestTimeSeconds:NaN,drmTimeSeconds:NaN,playTime:NaN,pauseTime:NaN,bufferingTime:NaN,licenseTime:NaN,liveLatency:NaN,maxSegmentDuration:NaN,switchHistory:[],stateHistory:[]};Gl(this);var a=this.g,b=a.currentTime/a.duration;if(!isNaN(b)){var c=this.B;b=
446
+ Math.round(100*b);c.i=isNaN(c.i)?b:Math.max(c.i,b)}this.F&&(this.B.N=this.F.Ve(),this.B.P=this.F.We());a.getVideoPlaybackQuality&&(a=a.getVideoPlaybackQuality(),c=this.B,b=Number(a.totalVideoFrames),c.K=Number(a.droppedVideoFrames),c.J=b,this.B.I=Number(a.corruptedVideoFrames));this.m?(a=this.m,a=a.J?a.J:NaN):a=NaN;this.B.m=a;if(this.l==Ol){if(a=this.j.l)this.B.B=(this.I?this.I.i:1)*a.bandwidth;a&&a.video&&(c=this.B,b=a.video.height||NaN,c.S=a.video.width||NaN,c.C=b);this.U()&&(a=this.tf().valueOf()+
447
+ 1E3*this.Ia().end,this.B.F=(Date.now()-a)/1E3);this.i&&this.i.presentationTimeline&&(this.B.H=this.i.presentationTimeline.g);a=this.C.getBandwidthEstimate();this.B.A=a}var d=this.B;a=d.S;c=d.C;b=d.B;var e=d.J,f=d.K,g=d.I,h=d.P,k=d.N,l=d.A,m=d.i,n=d.l,p=d.G,r=d.j,w=Tk(d.g,"playing"),y=Tk(d.g,"paused"),x=Tk(d.g,"buffering"),v=d.m,D=d.F,C=d.H,B=Uk(d.g),G=[];d=t(d.h.g);for(var E=d.next();!E.done;E=d.next())E=E.value,G.push({timestamp:E.timestamp,id:E.id,type:E.type,fromAdaptation:E.fromAdaptation,bandwidth:E.bandwidth});
448
+ return{width:a,height:c,streamBandwidth:b,decodedFrames:e,droppedFrames:f,corruptedFrames:g,stallsDetected:h,gapsJumped:k,estimatedBandwidth:l,completionPercent:m,loadLatency:n,manifestTimeSeconds:p,drmTimeSeconds:r,playTime:w,pauseTime:y,bufferingTime:x,licenseTime:v,liveLatency:D,maxSegmentDuration:C,stateHistory:B,switchHistory:G}};
449
+ q.Vf=function(a,b,c,d,e,f,g){g=void 0===g?!1:g;var h=this,k,l,m,n,p,r,w,y,x,v,D;return I(function(C){switch(C.g){case 1:if(h.l!=Ol&&h.l!=Zl)throw new O(1,7,7004);if(d){C.D(2);break}return u(C,mm(h,a),3);case 3:d=C.h;case 2:k=[];if(h.G)try{k=h.G.getServerSideCuePoints()}catch(B){}if(h.l!=Zl){C.D(4);break}g&&(c="forced");return u(C,nm(h,a,b,c,d,f||"",k),5);case 5:l=h.Ab();if(m=l.find(function(B){return B.language==b&&B.label==(f||"")&&B.kind==c}))return Wl(h),C["return"](m);throw new O(1,2,2012);case 4:n=
450
+ Jb;p=h.i.presentationTimeline.getDuration();if(Infinity==p)throw new O(1,4,4033);if(!k.length){C.D(6);break}return u(C,om(h,a,h.H,h.h.streaming.retryParameters),7);case 7:r=C.h,w=pm(h,r,d,k),y=new Blob([w],{type:"text/vtt"}),a=ji(y),d="text/vtt";case 6:x={id:h.Qf++,originalId:null,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:bj(0,p,[a]),mimeType:d||"",codecs:e||"",kind:c,encrypted:!1,drmInfos:[],keyIds:new Set,language:b,label:f||null,type:n.ha,primary:!1,trickModeVideo:null,
451
+ emsgSchemeIdUris:null,roles:[],forced:!!g,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null};v=yd(x.mimeType,x.codecs);D=Hd(v);if(!D)throw new O(2,2,2014,d);h.i.textStreams.push(x);Wl(h);return C["return"](se(x))}})};
452
+ q.Uf=function(a,b,c){var d=this,e,f,g,h;return I(function(k){switch(k.g){case 1:if(d.l!=Ol&&d.l!=Zl)throw new O(1,7,7004);if(c){k.D(2);break}return u(k,mm(d,a),3);case 3:c=k.h;case 2:e=[];if(d.G)try{e=d.G.getServerSideCuePoints()}catch(l){}return u(k,nm(d,a,b,"chapters",c,"",e),4);case 4:f=k.h;g=d.pf();h=g.find(function(l){return l.language==b});if(!h){k.D(5);break}return u(k,new Promise(function(l,m){d.A.Fa(f,"load",l);d.A.Fa(f,"error",function(){m(new O(1,2,2015))})}),6);case 6:return k["return"](h);
453
+ case 5:throw new O(1,2,2012);}})};function mm(a,b){var c,d;return I(function(e){switch(e.g){case 1:c=ug(b);if(d=qm[c])return e["return"](d);A(e,2);return u(e,wg(b,a.H,a.h.streaming.retryParameters),4);case 4:d=e.h;va(e,3);break;case 2:F(e);case 3:if(d)return e["return"](d);throw new O(1,2,2011,c);}})}
454
+ function nm(a,b,c,d,e,f,g){var h,k,l,m;return I(function(n){if(1==n.g)return"text/vtt"!=e||g.length?u(n,om(a,b,a.H,a.h.streaming.retryParameters),3):n.D(2);2!=n.g&&(h=n.h,k=pm(a,h,e,g),l=new Blob([k],{type:"text/vtt"}),b=ji(l),e="text/vtt");m=document.createElement("track");var p=a.S,r=b;try{if(p.g.enabled){var w=Ck(p);w.ot=Ik;w.su=!0;var y=Ek(w);var x=Fk(r,y)}else x=r}catch(v){Va("CMCD_TEXT_TRACK_ERROR","Could not generate text track CMCD data.",v),x=r}m.src=x;m.label=f;m.kind=d;m.srclang=c;a.g.getAttribute("crossorigin")||
455
+ a.g.setAttribute("crossorigin","anonymous");a.g.appendChild(m);return n["return"](m)})}function om(a,b,c,d){var e,f,g;return I(function(h){if(1==h.g){e=tf;f=nf([b],d);f.method="GET";var k=a.S;try{k.g.enabled&&Ak(k,f,{ot:Ik,su:!0})}catch(l){Va("CMCD_TEXT_ERROR","Could not generate text CMCD data.",l)}return u(h,c.request(e,f).promise,2)}g=h.h;return h["return"](g.data)})}
456
+ function pm(a,b,c,d){var e=Id[c];if(e)return c=e(),a={periodStart:0,segmentStart:0,segmentEnd:a.g.duration,vttOffset:0},b=Gc(b),b=c.parseMedia(b,a),ok(b,d);throw new O(2,2,2014,c);}q.Ee=function(a,b){this.Bc.width=a;this.Bc.height=b};q.ue=function(){if(this.l==Ol){var a=this.j;if(a.j.g)a=!1;else if(a.B)a=!1;else{for(var b=t(a.h.values()),c=b.next();!c.done;c=b.next())c=c.value,c.Ic&&(c.Ic=!1,zj(a,c,.1));a=!0}}else a=!1;return a};
457
+ q.vg=function(){Ua("Shaka Player's internal Manifest structure is NOT covered by semantic versioning compatibility guarantees. It may change at any time! Please consider filing a feature request for whatever you use getManifest() for.");return this.i};q.wg=function(){return this.ud};
458
+ function Zk(a){var b=Ok();b.streaming.failureCallback=function(c){var d=[1001,1002,1003];a.U()&&d.includes(c.code)&&(c.severity=1,a.ue())};b.textDisplayFactory=function(){return a.od?new hk(a.g,a.od):new bk(a.g)};return b}q.Je=function(a){this.od=a};
459
+ function Bl(a,b){for(var c=new Set,d=t(b.textStreams),e=d.next();!e.done;e=d.next())e=e.value,"application/cea-608"!=e.mimeType&&"application/cea-708"!=e.mimeType||c.add(e.originalId);d=t(b.variants);for(e=d.next();!e.done;e=d.next())if((e=e.value.video)&&e.closedCaptions)for(var f=t(e.closedCaptions.keys()),g=f.next();!g.done;g=f.next())if(g=g.value,!c.has(g)){var h=g.startsWith("CC")?"application/cea-608":"application/cea-708",k=new cj;h={id:a.Qf++,originalId:g,createSegmentIndex:function(){return Promise.resolve()},
460
+ segmentIndex:k,mimeType:h,codecs:"",kind:"caption",encrypted:!1,drmInfos:[],keyIds:new Set,language:e.closedCaptions.get(g),label:null,type:Ib,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:e.roles,forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null};b.textStreams.push(h);c.add(g)}}function Al(a,b){return I(function(c){if(1==c.g)return u(c,rm(a,b),2);fm(a,b);z(c)})}
461
+ function rm(a,b){var c;return I(function(d){if(1==d.g)return c=a.j?a.j.l:null,u(d,de(c,b),2);Vl(b);z(d)})}
462
+ function fm(a,b){if(a.l!=nl){ce(b.variants,a.h.restrictions,a.Bc)&&a.j&&Wl(a);var c=a.m?a.m.g:null;if(c&&a.m.B)for(var d=t(b.variants),e=d.next();!e.done;e=d.next()){e=e.value;e=t((e.video?e.video.drmInfos:[]).concat(e.audio?e.audio.drmInfos:[]));for(var f=e.next();!f.done;f=e.next())if(f=f.value,f.keySystem==c.keySystem){f=t(f.initData||[]);for(var g=f.next();!g.done;g=f.next())g=g.value,Uf(a.m,g.initDataType,g.initData)}}sm(a,b)}}
463
+ function Ql(a,b){var c,d,e,f,g;return I(function(h){if(1==h.g)return c=a.audio,d=a.video,e=function(k,l){var m,n,p;return I(function(r){if(1==r.g)return k?u(r,k.createSegmentIndex(),2):r["return"](null);n=(m=k.segmentIndex.ac(l))?m.next().value:null;if(!n)return r["return"](null);p=n.startTime;return r["return"](p)})},u(h,e(c,b),2);if(3!=h.g)return f=h.h,u(h,e(d,b),3);g=h.h;return null!=g&&null!=f?h["return"](Math.max(g,f)):null!=g?h["return"](g):null!=f?h["return"](f):h["return"](b)})}
464
+ function wl(a){var b=a.Kc();if(a.B&&a.N&&a.F){var c=a.I;c.j=b;ej(c);a.S&&(c=a.S,b||c.i||(c.i=!0),c.i&&b&&(c.l=!0),c.m=b);Gl(a)}b=(new Map).set("buffering",b);a.dispatchEvent(ll("buffering",b))}function Hl(a){var b=a.g.playbackRate;0!=b&&(a.I&&a.I.set(b),b=ll("ratechange"),a.dispatchEvent(b))}function Gl(a){if(a.B&&a.N){var b=a.B.g;a.N.g==Te?Sk(b,"buffering"):a.g.paused?Sk(b,"paused"):a.g.ended?Sk(b,"ended"):Sk(b,"playing")}}
465
+ function Xl(a){try{sm(a,a.i)}catch(c){return vl(a,c),!1}var b=a.i.variants.filter(function(c){return ze(c)});b=a.ya.create(b);a.C.setVariants(Array.from(b.values()));return!0}function ml(a){return Xl(a)?a.C.chooseVariant():null}function gm(a){var b=ml(a);b&&Jl(a,b,!0,!0,0)}
466
+ function Jl(a,b,c,d,e){var f=a.j.l;if(b==f)d&&Dj(a.j,b,d,e,!0);else{var g=a.B.h;g.h!=b&&(g.h=b,g.g.push({timestamp:Date.now()/1E3,id:b.id,type:"variant",fromAdaptation:c,bandwidth:b.bandwidth}));Dj(a.j,b,d,e);d=null;f&&(d=re(f));b=re(b);c?Rl(a,d,b):tm(a,d,b)}}function im(a,b){var c=Array.from(a.g.audioTracks).find(function(e){return e.enabled});b.enabled=!0;b.id!==c.id&&(c.enabled=!1);c=ye(c);var d=ye(b);tm(a,c,d)}
467
+ function Sl(a,b,c){a=Mb(a.h.preferredTextLanguage);b=Mb(b.language);c=Mb(c.language);return Lb(c,a)&&!Lb(b,c)}function Rl(a,b,c){b=(new Map).set("oldTrack",b).set("newTrack",c);b=ll("adaptation",b);um(a,b)}function Wl(a){var b=ll("trackschanged");um(a,b)}function tm(a,b,c){b=(new Map).set("oldTrack",b).set("newTrack",c);b=ll("variantchanged",b);um(a,b)}function hm(a){var b=ll("textchanged");um(a,b)}function Tl(a){var b=ll("texttrackvisibility");um(a,b)}
468
+ function Ul(a){var b=(new Map).set("newStatus",a.h.abr.enabled);um(a,ll("abrstatuschanged",b))}
469
+ function vm(a,b){if(1002!=b.code&&1011!=b.code||1!=b.category)return!1;var c=a.h.streaming.maxDisabledTime;if(0==c)if(1011==b.code)c=1;else return!1;for(var d=a.Qa().find(function(h){return h.active}),e=a.i,f=t(e.variants),g=f.next();!g.done;g=f.next())g=g.value,g.id===d.id&&(g.disabledUntilTime=Date.now()/1E3+c);ce(e.variants,a.h.restrictions,a.Bc);d=ml(a);if(!d)return!1;e=a.kb().video.reduce(function(h,k){return h+k.end-k.start},0);Jl(a,d,!1,!0,e);a.Pf.T(c);return!0}
470
+ function vl(a,b){if(a.l!=nl)if(vm(a,b))b.handled=!0;else{var c=ll("error",(new Map).set("detail",b));a.dispatchEvent(c);c.defaultPrevented&&(b.handled=!0)}}function zl(a,b,c){c=(new Map).set("detail",{schemeIdUri:c.schemeIdUri,value:c.value,startTime:c.startTime,endTime:c.endTime,id:c.id,eventElement:c.eventElement});a.dispatchEvent(ll(b,c))}
471
+ function ul(a){if(!a.g.error)return null;var b=a.g.error.code;if(1==b)return null;var c=a.g.error.msExtendedCode;c&&(0>c&&(c+=Math.pow(2,32)),c=c.toString(16));return new O(2,3,3016,b,c,a.g.error.message)}
472
+ function El(a,b){if(a.j){var c=Object.keys(b),d=1==c.length&&"00"==c[0],e=!1;if(c.length){c=t(a.i.variants);for(var f=c.next();!f.done;f=c.next()){f=f.value;var g=[];f.audio&&g.push(f.audio);f.video&&g.push(f.video);g=t(g);for(var h=g.next();!h.done;h=g.next()){var k=h.value;h=f.allowedByKeySystem;if(k.keyIds.size){f.allowedByKeySystem=!0;k=t(k.keyIds);for(var l=k.next();!l.done;l=k.next())l=l.value,l=b[d?"00":l],f.allowedByKeySystem=f.allowedByKeySystem&&!!l&&!wm.includes(l)}h!=f.allowedByKeySystem&&
473
+ (e=!0)}}}if(!e||Xl(a))(d=a.j.l)&&!d.allowedByKeySystem&&gm(a),e&&Wl(a)}}function Fl(a,b,c){if(a.J&&a.J.onExpirationUpdated)a.J.onExpirationUpdated(b,c);b=ll("expirationupdated");a.dispatchEvent(b)}function Il(a,b,c){0<b&&(a.U()||a.Jf(b));b=a.getDuration();c<b&&(a.U()||a.bb(c))}
474
+ function sm(a,b){var c=a.m?a.m.kd():{},d=Object.keys(c);d=d.length&&"00"==d[0];for(var e=!1,f=!1,g=new Set,h=new Set,k=t(b.variants),l=k.next();!l.done;l=k.next()){l=l.value;var m=[];l.audio&&m.push(l.audio);l.video&&m.push(l.video);m=t(m);for(var n=m.next();!n.done;n=m.next())if(n=n.value,n.keyIds.size){n=t(n.keyIds);for(var p=n.next();!p.done;p=n.next()){p=p.value;var r=c[d?"00":p];r?wm.includes(r)&&h.add(r):g.add(p)}}l.allowedByApplication?l.allowedByKeySystem&&(e=!0):f=!0}if(!e)throw c={hasAppRestrictions:f,
475
+ missingKeys:Array.from(g),restrictedKeyStatuses:Array.from(h)},new O(2,4,4012,c);}function Vl(a){if(!a.variants.some(ze))throw new O(2,4,4032);}function um(a,b){I(function(c){if(1==c.g)return u(c,Promise.resolve(),2);a.l!=nl&&a.dispatchEvent(b);z(c)})}function km(a){var b=new Set;a=t(a);for(var c=a.next();!c.done;c=a.next())c=c.value,c.language?b.add(Mb(c.language)):b.add("und");return b}
476
+ function jm(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=Mb(d.language));"variant"==d.type?f=d.audioRoles:f=d.roles;f&&f.length||(f=[""]);b.has(e)||b.set(e,new Set);f=t(f);for(var g=f.next();!g.done;g=f.next())g=g.value,b.get(e).add(g),d.label&&(c.has(e)||c.set(e,new Map),c.get(e).set(g,d.label))}var h=[];b.forEach(function(k,l){for(var m=t(k),n=m.next();!n.done;n=m.next()){n=n.value;var p=null;c.has(l)&&c.get(l).has(n)&&(p=c.get(l).get(n));
477
+ h.push({language:l,role:n,label:p})}});return h}function pl(){return new O(2,7,7E3)}function kl(a,b,c,d,e,f){return d==a&&e.O==f.O&&e.uri==f.uri&&e.mimeType==f.mimeType?b:c}function Vj(){return{O:null,mimeType:null,startTime:null,Ke:NaN,uri:null}}function ql(a){return new Promise(function(b,c){a.Pb=function(){return c(pl())};a.vd=function(){return b()};a.onError=function(d){return c(d)};a.xd=function(){return c(pl())}})}J("shaka.Player",S);S.prototype.setVideoContainer=S.prototype.Je;
478
+ S.prototype.getManifestParserFactory=S.prototype.wg;S.prototype.getManifest=S.prototype.vg;S.prototype.retryStreaming=S.prototype.ue;S.prototype.setMaxHardwareResolution=S.prototype.Ee;S.prototype.addChaptersTrack=S.prototype.Uf;S.prototype.addTextTrackAsync=S.prototype.Vf;S.prototype.getStats=S.prototype.getStats;S.prototype.getBufferedInfo=S.prototype.kb;S.prototype.getPresentationStartTimeAsDate=S.prototype.tf;S.prototype.getPlayheadTimeAsDate=S.prototype.Ag;
479
+ S.prototype.setTextTrackVisibility=S.prototype.Ie;S.prototype.getChapters=S.prototype.ig;S.prototype.getChaptersTracks=S.prototype.pf;S.prototype.isTextTrackVisible=S.prototype.Nb;S.prototype.selectVariantsByLabel=S.prototype.ih;S.prototype.selectTextLanguage=S.prototype.ye;S.prototype.selectAudioLanguage=S.prototype.Ed;S.prototype.getTextLanguages=S.prototype.Dg;S.prototype.getAudioLanguages=S.prototype.eg;S.prototype.getTextLanguagesAndRoles=S.prototype.Eg;
480
+ S.prototype.getAudioLanguagesAndRoles=S.prototype.fg;S.prototype.selectVariantTrack=S.prototype.Ae;S.prototype.selectTextTrack=S.prototype.ze;S.prototype.getThumbnails=S.prototype.Fg;S.prototype.getImageTracks=S.prototype.pg;S.prototype.getTextTracks=S.prototype.Ab;S.prototype.getVariantTracks=S.prototype.Qa;S.prototype.cancelTrickPlay=S.prototype.$e;S.prototype.trickPlay=S.prototype.Oe;S.prototype.getPlaybackRate=S.prototype.zb;S.prototype.isBuffering=S.prototype.Kc;S.prototype.getKeyStatuses=S.prototype.kd;
481
+ S.prototype.getExpiration=S.prototype.Dc;S.prototype.drmInfo=S.prototype.drmInfo;S.prototype.keySystem=S.prototype.keySystem;S.prototype.goToLive=S.prototype.Jg;S.prototype.seekRange=S.prototype.Ia;S.prototype.isAudioOnly=S.prototype.ec;S.prototype.isInProgress=S.prototype.Lb;S.prototype.isLive=S.prototype.U;S.prototype.getAdManager=S.prototype.hd;S.prototype.getAssetUri=S.prototype.Zd;S.prototype.getNetworkingEngine=S.prototype.Ec;S.prototype.getMediaElement=S.prototype.yg;
482
+ S.prototype.getLoadMode=S.prototype.rf;S.prototype.resetConfiguration=S.prototype.fh;S.prototype.getBufferFullness=S.prototype.gg;S.prototype.getConfiguration=S.prototype.getConfiguration;S.prototype.configure=S.prototype.configure;S.prototype.load=S.prototype.load;S.prototype.updateStartTime=S.prototype.uh;S.prototype.unload=S.prototype.Qe;S.prototype.detach=S.prototype.detach;S.prototype.attach=S.prototype.yc;
483
+ S.probeSupport=function(a){a=void 0===a?!0:a;var b,c,d,e,f,g;return I(function(h){if(1==h.g)return b={},a?u(h,mg(),3):h.D(2);2!=h.g&&(b=h.h);var k={};if(Rc()){for(var l in tg)k[l]=!0;for(var m in vg)k[m]=!0}l={mpd:"application/dash+xml",m3u8:"application/x-mpegurl",ism:"application/vnd.ms-sstr+xml"};m=t(["application/dash+xml","application/x-mpegurl","application/vnd.apple.mpegurl","application/vnd.ms-sstr+xml"]);for(var n=m.next();!n.done;n=m.next())n=n.value,k[n]=Rc()?!!tg[n]:Sc(n);for(var p in l)k[p]=
484
+ Rc()?!!vg[p]:Sc(l[p]);c=k;p='video/mp4; codecs="avc1.42E01E",video/mp4; codecs="avc3.42E01E",video/mp4; codecs="hev1.1.6.L93.90",video/mp4; codecs="hvc1.1.6.L93.90",video/mp4; codecs="hev1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="hvc1.2.4.L153.B0"; eotf="smpte2084",video/mp4; codecs="vp9",video/mp4; codecs="vp09.00.10.08",video/mp4; codecs="av01.0.01M.08",audio/mp4; codecs="mp4a.40.2",audio/mp4; codecs="ac-3",audio/mp4; codecs="ec-3",audio/mp4; codecs="opus",audio/mp4; codecs="flac",video/webm; codecs="vp8",video/webm; codecs="vp9",video/webm; codecs="vp09.00.10.08",audio/webm; codecs="vorbis",audio/webm; codecs="opus",video/mp2t; codecs="avc1.42E01E",video/mp2t; codecs="avc3.42E01E",video/mp2t; codecs="hvc1.1.6.L93.90",video/mp2t; codecs="mp4a.40.2",video/mp2t; codecs="ac-3",video/mp2t; codecs="ec-3",text/vtt,application/mp4; codecs="wvtt",application/ttml+xml,application/mp4; codecs="stpp"'.split(",").concat(ia(Di));
485
+ k={};p=t(p);for(l=p.next();!l.done;l=p.next())l=l.value,k[l]=Rc()?Hd(l)?!0:MediaSource.isTypeSupported(l)||td(l):Sc(l),m=l.split(";")[0],k[m]=k[m]||k[l];d=k;e={manifest:c,media:d,drm:b};f=xm;for(g in f)e[g]=f[g]();return h["return"](e)})};S.isBrowserSupported=ol;S.setAdManagerFactory=function(a){al=a};S.registerSupportPlugin=function(a,b){xm[a]=b};S.prototype.destroy=S.prototype.destroy;var nl=0,Yk=1,Ol=2,Zl=3;S.LoadMode={DESTROYED:nl,NOT_LOADED:Yk,MEDIA_SOURCE:Ol,SRC_EQUALS:Zl};S.version="v4.1.2";
486
+ var wm=["output-restricted","internal-error"],xm={},al=null,tl={mp4:"video/mp4",m4v:"video/mp4",m4a:"audio/mp4",webm:"video/webm",weba:"audio/webm",mkv:"video/webm",ts:"video/mp2t",ogv:"video/ogg",ogg:"audio/ogg",mpg:"video/mpeg",mpeg:"video/mpeg",m3u8:"application/x-mpegurl",mpd:"application/dash+xml",mp3:"audio/mpeg",aac:"audio/aac",flac:"audio/flac",wav:"audio/wav"},qm={sbv:"text/x-subviewer",srt:"text/srt",vtt:"text/vtt",webvtt:"text/vtt",ttml:"application/ttml+xml",lrc:"application/x-subtitle-lrc",
487
+ ssa:"text/x-ssa",ass:"text/x-ssa"};function ym(){this.h=[];this.j=this.i=this.g=0};function zm(a,b,c){var d=this;this.h=a;this.g=b;this.m=c;this.i=!1;this.l=this.g.getVolume();this.j=new wf;this.j.o(this.g,google.ima.AdEvent.Type.PAUSED,function(){d.i=!0});this.j.o(this.g,google.ima.AdEvent.Type.RESUMED,function(){d.i=!1})}q=zm.prototype;q.getDuration=function(){return this.h.getDuration()};q.getMinSuggestedDuration=function(){return this.h.getMinSuggestedDuration()};q.getRemainingTime=function(){return this.g.getRemainingTime()};q.isPaused=function(){return this.i};
486
488
  q.isSkippable=function(){return 0<=this.h.getSkipTimeOffset()};q.getTimeUntilSkippable=function(){var a=this.h.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};q.canSkipNow=function(){return this.g.getAdSkippableState()};q.skip=function(){return this.g.skip()};q.pause=function(){return this.g.pause()};q.play=function(){return this.g.resume()};q.getVolume=function(){return this.g.getVolume()};q.setVolume=function(a){return this.g.setVolume(a)};q.isMuted=function(){return 0==this.g.getVolume()};
487
489
  q.isLinear=function(){return this.h.isLinear()};q.resize=function(a,b){var c=!1,d=this.m;document.fullscreenEnabled?c=!!document.fullscreenElement:d.webkitSupportsFullscreen&&(c=d.webkitDisplayingFullscreen);this.g.resize(a,b,c?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)};q.setMuted=function(a){a?(this.l=this.getVolume(),this.setVolume(0)):this.setVolume(this.l)};q.getSequenceLength=function(){var a=this.h.getAdPodInfo();return null==a?1:a.getTotalAds()};
488
- q.getPositionInSequence=function(){var a=this.h.getAdPodInfo();return null==a?1:a.getAdPosition()};q.release=function(){this.g=this.h=null};J("shaka.ads.ClientSideAd",wm);wm.prototype.release=wm.prototype.release;wm.prototype.getPositionInSequence=wm.prototype.getPositionInSequence;wm.prototype.getSequenceLength=wm.prototype.getSequenceLength;wm.prototype.setMuted=wm.prototype.setMuted;wm.prototype.resize=wm.prototype.resize;wm.prototype.isLinear=wm.prototype.isLinear;wm.prototype.isMuted=wm.prototype.isMuted;
489
- wm.prototype.setVolume=wm.prototype.setVolume;wm.prototype.getVolume=wm.prototype.getVolume;wm.prototype.play=wm.prototype.play;wm.prototype.pause=wm.prototype.pause;wm.prototype.skip=wm.prototype.skip;wm.prototype.canSkipNow=wm.prototype.canSkipNow;wm.prototype.getTimeUntilSkippable=wm.prototype.getTimeUntilSkippable;wm.prototype.isSkippable=wm.prototype.isSkippable;wm.prototype.isPaused=wm.prototype.isPaused;wm.prototype.getRemainingTime=wm.prototype.getRemainingTime;
490
- wm.prototype.getMinSuggestedDuration=wm.prototype.getMinSuggestedDuration;wm.prototype.getDuration=wm.prototype.getDuration;function xm(a,b,c,d){var e=this;this.A=a;this.i=b;this.B=null;this.C=NaN;this.j=d;this.m=null;this.h=new tf;google.ima.settings.setLocale(c);a=new google.ima.AdDisplayContainer(this.A,this.i);a.initialize();this.l=new google.ima.AdsLoader(a);this.l.getSettings().setPlayerType("shaka-player");this.l.getSettings().setPlayerVersion("v4.1.1");this.g=null;this.h.Fa(this.l,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,function(f){ym(e,f)});this.h.o(this.l,google.ima.AdErrorEvent.Type.AD_ERROR,
491
- function(f){zm(e,f)});this.i.onended=function(){e.l.contentComplete()}}xm.prototype.stop=function(){this.g&&this.g.stop();this.A&&dk(this.A)};xm.prototype.release=function(){this.stop();this.B&&this.B.disconnect();this.h&&this.h.release();this.g&&this.g.destroy();this.l.destroy()};function zm(a,b){b.getError();Am(a,null);a.j(new M("ad-cue-points-changed",(new Map).set("cuepoints",[])))}
492
- function ym(a,b){a.j(new M("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.C)));a.g=b.getAdsManager(a.i);a.j(new M("ima-ad-manager-loaded",(new Map).set("imaAdManager",a.g)));var c=a.g.getCuePoints();if(c.length){var d=[];c=t(c);for(var e=c.next();!e.done;e=c.next())d.push({start:e.value,end:null});a.j(new M("ad-cue-points-changed",(new Map).set("cuepoints",d)))}Bm(a);try{a.g.init(a.i.offsetWidth,a.i.offsetHeight,Cm(a)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL),a.h.o(a.i,"loadeddata",
493
- function(){a.g.resize(a.i.offsetWidth,a.i.offsetHeight,Cm(a)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),"ResizeObserver"in window&&(a.B=new ResizeObserver(function(){a.g.resize(a.i.offsetWidth,a.i.offsetHeight,Cm(a)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),a.B.observe(a.i)),a.g.start()}catch(f){Am(a,null)}}function Cm(a){if(document.fullscreenEnabled)return!!document.fullscreenElement;a=a.i;return a.webkitSupportsFullscreen?a.webkitDisplayingFullscreen:!1}
494
- function Bm(a){function b(c,d){var e=(new Map).set("originalEvent",c);a.j(new M(d,e))}a.h.o(a.g,google.ima.AdErrorEvent.Type.AD_ERROR,function(c){zm(a,c)});a.h.o(a.g,google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED,function(c){Dm(a,c)});a.h.o(a.g,google.ima.AdEvent.Type.STARTED,function(c){Dm(a,c)});a.h.o(a.g,google.ima.AdEvent.Type.FIRST_QUARTILE,function(c){b(c,"ad-first-quartile")});a.h.o(a.g,google.ima.AdEvent.Type.MIDPOINT,function(c){b(c,"ad-midpoint")});a.h.o(a.g,google.ima.AdEvent.Type.THIRD_QUARTILE,
495
- function(c){b(c,"ad-third-quartile")});a.h.o(a.g,google.ima.AdEvent.Type.COMPLETE,function(c){b(c,"ad-complete")});a.h.o(a.g,google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED,function(c){Am(a,c)});a.h.o(a.g,google.ima.AdEvent.Type.ALL_ADS_COMPLETED,function(c){Am(a,c)});a.h.o(a.g,google.ima.AdEvent.Type.SKIPPED,function(c){b(c,"ad-skipped")});a.h.o(a.g,google.ima.AdEvent.Type.VOLUME_CHANGED,function(c){b(c,"ad-volume-changed")});a.h.o(a.g,google.ima.AdEvent.Type.VOLUME_MUTED,function(c){b(c,"ad-muted")});
490
+ q.getPositionInSequence=function(){var a=this.h.getAdPodInfo();return null==a?1:a.getAdPosition()};q.release=function(){this.g=this.h=null};J("shaka.ads.ClientSideAd",zm);zm.prototype.release=zm.prototype.release;zm.prototype.getPositionInSequence=zm.prototype.getPositionInSequence;zm.prototype.getSequenceLength=zm.prototype.getSequenceLength;zm.prototype.setMuted=zm.prototype.setMuted;zm.prototype.resize=zm.prototype.resize;zm.prototype.isLinear=zm.prototype.isLinear;zm.prototype.isMuted=zm.prototype.isMuted;
491
+ zm.prototype.setVolume=zm.prototype.setVolume;zm.prototype.getVolume=zm.prototype.getVolume;zm.prototype.play=zm.prototype.play;zm.prototype.pause=zm.prototype.pause;zm.prototype.skip=zm.prototype.skip;zm.prototype.canSkipNow=zm.prototype.canSkipNow;zm.prototype.getTimeUntilSkippable=zm.prototype.getTimeUntilSkippable;zm.prototype.isSkippable=zm.prototype.isSkippable;zm.prototype.isPaused=zm.prototype.isPaused;zm.prototype.getRemainingTime=zm.prototype.getRemainingTime;
492
+ zm.prototype.getMinSuggestedDuration=zm.prototype.getMinSuggestedDuration;zm.prototype.getDuration=zm.prototype.getDuration;function Am(a,b,c,d){var e=this;this.A=a;this.i=b;this.B=null;this.C=NaN;this.j=d;this.m=null;this.h=new wf;google.ima.settings.setLocale(c);a=new google.ima.AdDisplayContainer(this.A,this.i);a.initialize();this.l=new google.ima.AdsLoader(a);this.l.getSettings().setPlayerType("shaka-player");this.l.getSettings().setPlayerVersion("v4.1.2");this.g=null;this.h.Fa(this.l,google.ima.AdsManagerLoadedEvent.Type.ADS_MANAGER_LOADED,function(f){Bm(e,f)});this.h.o(this.l,google.ima.AdErrorEvent.Type.AD_ERROR,
493
+ function(f){Cm(e,f)});this.i.onended=function(){e.l.contentComplete()}}Am.prototype.stop=function(){this.g&&this.g.stop();this.A&&gk(this.A)};Am.prototype.release=function(){this.stop();this.B&&this.B.disconnect();this.h&&this.h.release();this.g&&this.g.destroy();this.l.destroy()};function Cm(a,b){b.getError();Dm(a,null);a.j(new L("ad-cue-points-changed",(new Map).set("cuepoints",[])))}
494
+ function Bm(a,b){a.j(new L("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.C)));a.g=b.getAdsManager(a.i);a.j(new L("ima-ad-manager-loaded",(new Map).set("imaAdManager",a.g)));var c=a.g.getCuePoints();if(c.length){var d=[];c=t(c);for(var e=c.next();!e.done;e=c.next())d.push({start:e.value,end:null});a.j(new L("ad-cue-points-changed",(new Map).set("cuepoints",d)))}Em(a);try{a.g.init(a.i.offsetWidth,a.i.offsetHeight,Fm(a)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL),a.h.o(a.i,"loadeddata",
495
+ function(){a.g.resize(a.i.offsetWidth,a.i.offsetHeight,Fm(a)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),"ResizeObserver"in window&&(a.B=new ResizeObserver(function(){a.g.resize(a.i.offsetWidth,a.i.offsetHeight,Fm(a)?google.ima.ViewMode.FULLSCREEN:google.ima.ViewMode.NORMAL)}),a.B.observe(a.i)),a.g.start()}catch(f){Dm(a,null)}}function Fm(a){if(document.fullscreenEnabled)return!!document.fullscreenElement;a=a.i;return a.webkitSupportsFullscreen?a.webkitDisplayingFullscreen:!1}
496
+ function Em(a){function b(c,d){var e=(new Map).set("originalEvent",c);a.j(new L(d,e))}a.h.o(a.g,google.ima.AdErrorEvent.Type.AD_ERROR,function(c){Cm(a,c)});a.h.o(a.g,google.ima.AdEvent.Type.CONTENT_PAUSE_REQUESTED,function(c){Gm(a,c)});a.h.o(a.g,google.ima.AdEvent.Type.STARTED,function(c){Gm(a,c)});a.h.o(a.g,google.ima.AdEvent.Type.FIRST_QUARTILE,function(c){b(c,"ad-first-quartile")});a.h.o(a.g,google.ima.AdEvent.Type.MIDPOINT,function(c){b(c,"ad-midpoint")});a.h.o(a.g,google.ima.AdEvent.Type.THIRD_QUARTILE,
497
+ function(c){b(c,"ad-third-quartile")});a.h.o(a.g,google.ima.AdEvent.Type.COMPLETE,function(c){b(c,"ad-complete")});a.h.o(a.g,google.ima.AdEvent.Type.CONTENT_RESUME_REQUESTED,function(c){Dm(a,c)});a.h.o(a.g,google.ima.AdEvent.Type.ALL_ADS_COMPLETED,function(c){Dm(a,c)});a.h.o(a.g,google.ima.AdEvent.Type.SKIPPED,function(c){b(c,"ad-skipped")});a.h.o(a.g,google.ima.AdEvent.Type.VOLUME_CHANGED,function(c){b(c,"ad-volume-changed")});a.h.o(a.g,google.ima.AdEvent.Type.VOLUME_MUTED,function(c){b(c,"ad-muted")});
496
498
  a.h.o(a.g,google.ima.AdEvent.Type.PAUSED,function(c){a.m.i=!0;b(c,"ad-paused")});a.h.o(a.g,google.ima.AdEvent.Type.RESUMED,function(c){a.m.i=!1;b(c,"ad-resumed")});a.h.o(a.g,google.ima.AdEvent.Type.SKIPPABLE_STATE_CHANGED,function(c){b(c,"ad-skip-state-changed")});a.h.o(a.g,google.ima.AdEvent.Type.CLICK,function(c){b(c,"ad-clicked")});a.h.o(a.g,google.ima.AdEvent.Type.AD_PROGRESS,function(c){b(c,"ad-progress")});a.h.o(a.g,google.ima.AdEvent.Type.AD_BUFFERING,function(c){b(c,"ad-buffering")});a.h.o(a.g,
497
499
  google.ima.AdEvent.Type.IMPRESSION,function(c){b(c,"ad-impression")});a.h.o(a.g,google.ima.AdEvent.Type.DURATION_CHANGE,function(c){b(c,"ad-duration-changed")});a.h.o(a.g,google.ima.AdEvent.Type.USER_CLOSE,function(c){b(c,"ad-closed")});a.h.o(a.g,google.ima.AdEvent.Type.LOADED,function(c){b(c,"ad-loaded")});a.h.o(a.g,google.ima.AdEvent.Type.ALL_ADS_COMPLETED,function(c){b(c,"all-ads-completed")});a.h.o(a.g,google.ima.AdEvent.Type.LINEAR_CHANGED,function(c){b(c,"ad-linear-changed")});a.h.o(a.g,google.ima.AdEvent.Type.AD_METADATA,
498
- function(c){b(c,"ad-metadata")});a.h.o(a.g,google.ima.AdEvent.Type.LOG,function(c){b(c,"ad-recoverable-error")});a.h.o(a.g,google.ima.AdEvent.Type.AD_BREAK_READY,function(c){b(c,"ad-break-ready")});a.h.o(a.g,google.ima.AdEvent.Type.INTERACTION,function(c){b(c,"ad-interaction")})}function Dm(a,b){var c=b.getAd();a.m=new wm(c,a.g,a.i);c=(new Map).set("ad",a.m).set("sdkAdObject",c).set("originalEvent",b);a.j(new M("ad-started",c));a.m.isLinear()&&(a.A.setAttribute("ad-active","true"),a.i.pause())}
499
- function Am(a,b){a.j(new M("ad-stopped",(new Map).set("originalEvent",b)));a.m.isLinear()&&(a.A.removeAttribute("ad-active"),a.i.play())};function Em(a,b){this.i=a;this.h=null;this.g=b}q=Em.prototype;q.getDuration=function(){return this.h?this.h.duration:-1};q.getMinSuggestedDuration=function(){return this.getDuration()};q.getRemainingTime=function(){return this.h?this.h.duration-this.h.currentTime:-1};q.isPaused=function(){return this.g.paused};q.isSkippable=function(){return this.i.isSkippable()};q.getTimeUntilSkippable=function(){var a=this.i.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};
500
+ function(c){b(c,"ad-metadata")});a.h.o(a.g,google.ima.AdEvent.Type.LOG,function(c){b(c,"ad-recoverable-error")});a.h.o(a.g,google.ima.AdEvent.Type.AD_BREAK_READY,function(c){b(c,"ad-break-ready")});a.h.o(a.g,google.ima.AdEvent.Type.INTERACTION,function(c){b(c,"ad-interaction")})}function Gm(a,b){var c=b.getAd();a.m=new zm(c,a.g,a.i);c=(new Map).set("ad",a.m).set("sdkAdObject",c).set("originalEvent",b);a.j(new L("ad-started",c));a.m.isLinear()&&(a.A.setAttribute("ad-active","true"),a.i.pause())}
501
+ function Dm(a,b){a.j(new L("ad-stopped",(new Map).set("originalEvent",b)));a.m.isLinear()&&(a.A.removeAttribute("ad-active"),a.i.play())};function Hm(a,b){this.i=a;this.h=null;this.g=b}q=Hm.prototype;q.getDuration=function(){return this.h?this.h.duration:-1};q.getMinSuggestedDuration=function(){return this.getDuration()};q.getRemainingTime=function(){return this.h?this.h.duration-this.h.currentTime:-1};q.isPaused=function(){return this.g.paused};q.isSkippable=function(){return this.i.isSkippable()};q.getTimeUntilSkippable=function(){var a=this.i.getSkipTimeOffset();a=this.getRemainingTime()-a;return Math.max(a,0)};
500
502
  q.canSkipNow=function(){return 0==this.getTimeUntilSkippable()};q.skip=function(){this.g.currentTime+=this.getRemainingTime()};q.pause=function(){return this.g.pause()};q.play=function(){return this.g.play()};q.getVolume=function(){return this.g.volume};q.setVolume=function(a){this.g.volume=a};q.isMuted=function(){return this.g.muted};q.isLinear=function(){return!0};q.resize=function(){};q.setMuted=function(a){this.g.muted=a};
501
- q.getSequenceLength=function(){var a=this.i.getAdPodInfo();return null==a?1:a.getTotalAds()};q.getPositionInSequence=function(){var a=this.i.getAdPodInfo();return null==a?1:a.getAdPosition()};q.release=function(){this.g=this.h=this.i=null};J("shaka.ads.ServerSideAd",Em);Em.prototype.release=Em.prototype.release;Em.prototype.getPositionInSequence=Em.prototype.getPositionInSequence;Em.prototype.getSequenceLength=Em.prototype.getSequenceLength;Em.prototype.setMuted=Em.prototype.setMuted;
502
- Em.prototype.resize=Em.prototype.resize;Em.prototype.isLinear=Em.prototype.isLinear;Em.prototype.isMuted=Em.prototype.isMuted;Em.prototype.setVolume=Em.prototype.setVolume;Em.prototype.getVolume=Em.prototype.getVolume;Em.prototype.play=Em.prototype.play;Em.prototype.pause=Em.prototype.pause;Em.prototype.skip=Em.prototype.skip;Em.prototype.canSkipNow=Em.prototype.canSkipNow;Em.prototype.getTimeUntilSkippable=Em.prototype.getTimeUntilSkippable;Em.prototype.isSkippable=Em.prototype.isSkippable;
503
- Em.prototype.isPaused=Em.prototype.isPaused;Em.prototype.getRemainingTime=Em.prototype.getRemainingTime;Em.prototype.getMinSuggestedDuration=Em.prototype.getMinSuggestedDuration;Em.prototype.getDuration=Em.prototype.getDuration;function Fm(a,b,c,d){var e=this;this.B=a;this.l=b;this.j=null;this.I=NaN;this.i=d;this.H=!1;this.C=this.m=this.A=null;this.F="";this.G=[];this.h=new tf;a=new google.ima.dai.api.UiSettings;a.setLocale(c);this.g=new google.ima.dai.api.StreamManager(this.l,this.B,a);this.i(new M("ima-stream-manager-loaded",(new Map).set("imaStreamManager",this.g)));this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.LOADED,function(f){Gm(e,f)});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.ERROR,function(){e.F.length?
504
- e.j.resolve(e.F):e.j.reject("IMA Stream request returned an error and there was no backup asset uri provided.");e.j=null});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.AD_BREAK_STARTED,function(){});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.STARTED,function(f){f=f.getAd();e.m=new Em(f,e.l);e.C&&(e.m.h=e.C);e.i(new M("ad-started",(new Map).set("ad",e.m)));e.B.setAttribute("ad-active","true")});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.AD_BREAK_ENDED,function(){e.B.removeAttribute("ad-active");
505
- var f=e.l.currentTime;e.A&&e.A>f&&(e.l.currentTime=e.A,e.A=null)});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.AD_PROGRESS,function(f){e.C=f.getStreamData().adProgressData;e.m&&(e.m.h=e.C)});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.FIRST_QUARTILE,function(){e.i(new M("ad-first-quartile"))});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.MIDPOINT,function(){e.i(new M("ad-midpoint"))});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.THIRD_QUARTILE,function(){e.i(new M("ad-third-quartile"))});
506
- this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.COMPLETE,function(){e.i(new M("ad-complete"));e.i(new M("ad-stopped"));e.B.removeAttribute("ad-active");e.m=null});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.SKIPPED,function(){e.i(new M("ad-skipped"));e.i(new M("ad-stopped"))});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.CUEPOINTS_CHANGED,function(f){var g=f.getStreamData();f=[];g=t(g.cuepoints);for(var h=g.next();!h.done;h=g.next())h=h.value,f.push({start:h.start,end:h.end});e.G=
507
- f;e.i(new M("ad-cue-points-changed",(new Map).set("cuepoints",f)))})}Fm.prototype.stop=function(){this.F="";this.A=null;this.G=[]};Fm.prototype.release=function(){this.stop();this.h&&this.h.release()};Fm.prototype.onCueMetadataChange=function(a){if(a.key&&a.data){var b={};b[a.key]=a.data;this.g.onTimedMetadata(b)}};
508
- function Gm(a,b){a.i(new M("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.I)));var c=b.getStreamData().url;a.j.resolve(c);a.j=null;a.H||a.h.o(a.l,"seeked",function(){var d=a.l.currentTime;if(0!=d){a.g.streamTimeForContentTime(d);var e=a.g.previousCuePointForStreamTime(d);e&&!e.played&&(a.A=d,a.l.currentTime=e.start)}})};function T(){fb.call(this);this.g=this.i=null;this.h=new vm;this.j=navigator.language}qa(T,fb);q=T.prototype;q.setLocale=function(a){this.j=a};q.initClientSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.AdsLoader)throw new O(2,10,1E4);this.i&&this.i.release();this.i=new xm(a,b,this.j,function(d){if(d&&d.type)switch(d.type){case "ads-loaded":c.h.h.push(d.loadTime);break;case "ad-started":c.h.g++;break;case "ad-complete":c.h.i++;break;case "ad-skipped":c.h.j++}c.dispatchEvent(d)})};
509
- q.release=function(){this.i&&(this.i.release(),this.i=null);this.g&&(this.g.release(),this.g=null);fb.prototype.release.call(this)};q.onAssetUnload=function(){this.i&&this.i.stop();this.g&&this.g.stop();this.dispatchEvent(new M("ad-stopped"));this.h=new vm};q.requestClientSideAds=function(a){if(!this.i)throw new O(1,10,10001);var b=this.i;b.C=Date.now()/1E3;b.l.requestAds(a)};
510
- q.initServerSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.dai)throw new O(2,10,10002);this.g&&this.g.release();this.g=new Fm(a,b,this.j,function(d){if(d&&d.type)switch(d.type){case "ads-loaded":c.h.h.push(d.loadTime);break;case "ad-started":c.h.g++;break;case "ad-complete":c.h.i++;break;case "ad-skipped":c.h.j++}c.dispatchEvent(d)})};
511
- q.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new O(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Ua('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.adTagParameters.mpt="shaka-player";a.adTagParameters.mpv="v4.1.1";c=this.g;var d=b;c.j?c=Promise.reject(new O(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
512
- (c.H=!0),c.j=new Nc,c.g.requestStream(a),c.F=d||"",c.I=Date.now()/1E3,c=c.j);return c};q.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new O(1,10,10003);(a.mpt||a.mpv)&&Ua('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.mpt="Shaka Player";a.mpv="v4.1.1";this.g.g.replaceAdTagParameters(a)};q.getServerSideCuePoints=function(){if(!this.g)throw new O(1,10,10003);return this.g.G};
503
+ q.getSequenceLength=function(){var a=this.i.getAdPodInfo();return null==a?1:a.getTotalAds()};q.getPositionInSequence=function(){var a=this.i.getAdPodInfo();return null==a?1:a.getAdPosition()};q.release=function(){this.g=this.h=this.i=null};J("shaka.ads.ServerSideAd",Hm);Hm.prototype.release=Hm.prototype.release;Hm.prototype.getPositionInSequence=Hm.prototype.getPositionInSequence;Hm.prototype.getSequenceLength=Hm.prototype.getSequenceLength;Hm.prototype.setMuted=Hm.prototype.setMuted;
504
+ Hm.prototype.resize=Hm.prototype.resize;Hm.prototype.isLinear=Hm.prototype.isLinear;Hm.prototype.isMuted=Hm.prototype.isMuted;Hm.prototype.setVolume=Hm.prototype.setVolume;Hm.prototype.getVolume=Hm.prototype.getVolume;Hm.prototype.play=Hm.prototype.play;Hm.prototype.pause=Hm.prototype.pause;Hm.prototype.skip=Hm.prototype.skip;Hm.prototype.canSkipNow=Hm.prototype.canSkipNow;Hm.prototype.getTimeUntilSkippable=Hm.prototype.getTimeUntilSkippable;Hm.prototype.isSkippable=Hm.prototype.isSkippable;
505
+ Hm.prototype.isPaused=Hm.prototype.isPaused;Hm.prototype.getRemainingTime=Hm.prototype.getRemainingTime;Hm.prototype.getMinSuggestedDuration=Hm.prototype.getMinSuggestedDuration;Hm.prototype.getDuration=Hm.prototype.getDuration;function Im(a,b,c,d){var e=this;this.B=a;this.l=b;this.j=null;this.I=NaN;this.i=d;this.H=!1;this.C=this.m=this.A=null;this.F="";this.G=[];this.h=new wf;a=new google.ima.dai.api.UiSettings;a.setLocale(c);this.g=new google.ima.dai.api.StreamManager(this.l,this.B,a);this.i(new L("ima-stream-manager-loaded",(new Map).set("imaStreamManager",this.g)));this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.LOADED,function(f){Jm(e,f)});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.ERROR,function(){e.F.length?
506
+ e.j.resolve(e.F):e.j.reject("IMA Stream request returned an error and there was no backup asset uri provided.");e.j=null});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.AD_BREAK_STARTED,function(){});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.STARTED,function(f){f=f.getAd();e.m=new Hm(f,e.l);e.C&&(e.m.h=e.C);e.i(new L("ad-started",(new Map).set("ad",e.m)));e.B.setAttribute("ad-active","true")});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.AD_BREAK_ENDED,function(){e.B.removeAttribute("ad-active");
507
+ var f=e.l.currentTime;e.A&&e.A>f&&(e.l.currentTime=e.A,e.A=null)});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.AD_PROGRESS,function(f){e.C=f.getStreamData().adProgressData;e.m&&(e.m.h=e.C)});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.FIRST_QUARTILE,function(){e.i(new L("ad-first-quartile"))});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.MIDPOINT,function(){e.i(new L("ad-midpoint"))});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.THIRD_QUARTILE,function(){e.i(new L("ad-third-quartile"))});
508
+ this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.COMPLETE,function(){e.i(new L("ad-complete"));e.i(new L("ad-stopped"));e.B.removeAttribute("ad-active");e.m=null});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.SKIPPED,function(){e.i(new L("ad-skipped"));e.i(new L("ad-stopped"))});this.h.o(this.g,google.ima.dai.api.StreamEvent.Type.CUEPOINTS_CHANGED,function(f){var g=f.getStreamData();f=[];g=t(g.cuepoints);for(var h=g.next();!h.done;h=g.next())h=h.value,f.push({start:h.start,end:h.end});e.G=
509
+ f;e.i(new L("ad-cue-points-changed",(new Map).set("cuepoints",f)))})}Im.prototype.stop=function(){this.F="";this.A=null;this.G=[]};Im.prototype.release=function(){this.stop();this.h&&this.h.release()};Im.prototype.onCueMetadataChange=function(a){if(a.key&&a.data){var b={};b[a.key]=a.data;this.g.onTimedMetadata(b)}};
510
+ function Jm(a,b){a.i(new L("ads-loaded",(new Map).set("loadTime",Date.now()/1E3-a.I)));var c=b.getStreamData().url;a.j.resolve(c);a.j=null;a.H||a.h.o(a.l,"seeked",function(){var d=a.l.currentTime;if(0!=d){a.g.streamTimeForContentTime(d);var e=a.g.previousCuePointForStreamTime(d);e&&!e.played&&(a.A=d,a.l.currentTime=e.start)}})};function T(){fb.call(this);this.g=this.i=null;this.h=new ym;this.j=navigator.language}qa(T,fb);q=T.prototype;q.setLocale=function(a){this.j=a};q.initClientSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.AdsLoader)throw new O(2,10,1E4);this.i&&this.i.release();this.i=new Am(a,b,this.j,function(d){if(d&&d.type)switch(d.type){case "ads-loaded":c.h.h.push(d.loadTime);break;case "ad-started":c.h.g++;break;case "ad-complete":c.h.i++;break;case "ad-skipped":c.h.j++}c.dispatchEvent(d)})};
511
+ q.release=function(){this.i&&(this.i.release(),this.i=null);this.g&&(this.g.release(),this.g=null);fb.prototype.release.call(this)};q.onAssetUnload=function(){this.i&&this.i.stop();this.g&&this.g.stop();this.dispatchEvent(new L("ad-stopped"));this.h=new ym};q.requestClientSideAds=function(a){if(!this.i)throw new O(1,10,10001);var b=this.i;b.C=Date.now()/1E3;b.l.requestAds(a)};
512
+ q.initServerSide=function(a,b){var c=this;if(!window.google||!google.ima||!google.ima.dai)throw new O(2,10,10002);this.g&&this.g.release();this.g=new Im(a,b,this.j,function(d){if(d&&d.type)switch(d.type){case "ads-loaded":c.h.h.push(d.loadTime);break;case "ad-started":c.h.g++;break;case "ad-complete":c.h.i++;break;case "ad-skipped":c.h.j++}c.dispatchEvent(d)})};
513
+ q.requestServerSideStream=function(a,b){b=void 0===b?"":b;if(!this.g)throw new O(1,10,10003);a.adTagParameters||(a.adTagParameters={});var c=a.adTagParameters;(c.mpt||c.mpv)&&Ua('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.adTagParameters.mpt="shaka-player";a.adTagParameters.mpv="v4.1.2";c=this.g;var d=b;c.j?c=Promise.reject(new O(1,10,10004)):(a instanceof google.ima.dai.api.LiveStreamRequest&&
514
+ (c.H=!0),c.j=new Nc,c.g.requestStream(a),c.F=d||"",c.I=Date.now()/1E3,c=c.j);return c};q.replaceServerSideAdTagParameters=function(a){if(!this.g)throw new O(1,10,10003);(a.mpt||a.mpv)&&Ua('You have attempted to set "mpt" and/or "mpv" parameters of the ad tag. Please note that those parameters are used for Shaka adoption tracking and will be overriden.');a.mpt="Shaka Player";a.mpv="v4.1.2";this.g.g.replaceAdTagParameters(a)};q.getServerSideCuePoints=function(){if(!this.g)throw new O(1,10,10003);return this.g.G};
513
515
  q.getStats=function(){var a=this.h;return{loadTimes:a.h,started:a.g,playedCompletely:a.i,skipped:a.j}};q.onDashTimedMetadata=function(a){if(this.g&&"urn:google:dai:2018"==a.schemeIdUri){var b=a.schemeIdUri,c=a.eventElement?a.eventElement.getAttribute("messageData"):null;this.g.g.processMetadata(b,c,a.startTime)}};q.onHlsTimedMetadata=function(a,b){this.g&&this.g.g.processMetadata("ID3",a.data,b)};q.onCueMetadataChange=function(a){if(this.g)this.g.onCueMetadataChange(a)};J("shaka.ads.AdManager",T);
514
516
  T.prototype.onCueMetadataChange=T.prototype.onCueMetadataChange;T.prototype.onHlsTimedMetadata=T.prototype.onHlsTimedMetadata;T.prototype.onDashTimedMetadata=T.prototype.onDashTimedMetadata;T.prototype.getStats=T.prototype.getStats;T.prototype.getServerSideCuePoints=T.prototype.getServerSideCuePoints;T.prototype.replaceServerSideAdTagParameters=T.prototype.replaceServerSideAdTagParameters;T.prototype.requestServerSideStream=T.prototype.requestServerSideStream;T.prototype.initServerSide=T.prototype.initServerSide;
515
517
  T.prototype.requestClientSideAds=T.prototype.requestClientSideAds;T.prototype.onAssetUnload=T.prototype.onAssetUnload;T.prototype.release=T.prototype.release;T.prototype.initClientSide=T.prototype.initClientSide;T.prototype.setLocale=T.prototype.setLocale;T.ADS_LOADED="ads-loaded";T.AD_STARTED="ad-started";T.AD_FIRST_QUARTILE="ad-first-quartile";T.AD_MIDPOINT="ad-midpoint";T.AD_THIRD_QUARTILE="ad-third-quartile";T.AD_COMPLETE="ad-complete";T.AD_STOPPED="ad-stopped";T.AD_SKIPPED="ad-skipped";
516
518
  T.AD_VOLUME_CHANGED="ad-volume-changed";T.AD_MUTED="ad-muted";T.AD_PAUSED="ad-paused";T.AD_RESUMED="ad-resumed";T.AD_SKIP_STATE_CHANGED="ad-skip-state-changed";T.CUEPOINTS_CHANGED="ad-cue-points-changed";T.IMA_AD_MANAGER_LOADED="ima-ad-manager-loaded";T.IMA_STREAM_MANAGER_LOADED="ima-stream-manager-loaded";T.AD_CLICKED="ad-clicked";T.AD_PROGRESS="ad-progress";T.AD_BUFFERING="ad-buffering";T.AD_IMPRESSION="ad-impression";T.AD_DURATION_CHANGED="ad-duration-changed";T.AD_CLOSED="ad-closed";
517
- T.AD_LOADED="ad-loaded";T.ALL_ADS_COMPLETED="all-ads-completed";T.AD_LINEAR_CHANGED="ad-linear-changed";T.AD_METADATA="ad-metadata";T.AD_RECOVERABLE_ERROR="ad-recoverable-error";T.AD_BREAK_READY="ad-break-ready";T.AD_INTERACTION="ad-interaction";Yk=function(){return new T};function Hm(a){return JSON.stringify(a,function(b,c){if("function"!=typeof c){if(c instanceof Event||c instanceof M){var d={};for(f in c){var e=c[f];e&&"object"==typeof e?"detail"==f&&(d[f]=e):f in Event||(d[f]=e)}return d}if(c instanceof Error){var f=new Set(["name","message","stack"]);for(d in c)f.add(d);e=t(Object.getOwnPropertyNames(c));for(d=e.next();!d.done;d=e.next())f.add(d.value);e={};f=t(f);for(d=f.next();!d.done;d=f.next())d=d.value,e[d]=c[d];f={__type__:"Error",contents:e}}else if(c instanceof
518
- TimeRanges)for(f={__type__:"TimeRanges",length:c.length,start:[],end:[]},d=t(Xh(c)),e=d.next();!e.done;e=d.next()){e=e.value;var g=e.end;f.start.push(e.start);f.end.push(g)}else f=c instanceof Uint8Array?{__type__:"Uint8Array",entries:Array.from(c)}:"number"==typeof c?isNaN(c)?"NaN":isFinite(c)?c:0>c?"-Infinity":"Infinity":c;return f}})}
519
- function Im(a){return JSON.parse(a,function(b,c){if("NaN"==c)var d=NaN;else if("-Infinity"==c)d=-Infinity;else if("Infinity"==c)d=Infinity;else if(c&&"object"==typeof c&&"TimeRanges"==c.__type__)d=Jm(c);else if(c&&"object"==typeof c&&"Uint8Array"==c.__type__)d=new Uint8Array(c.entries);else if(c&&"object"==typeof c&&"Error"==c.__type__){d=c.contents;var e=Error(d.message),f;for(f in d)e[f]=d[f];d=e}else d=c;return d})}
520
- function Jm(a){return{length:a.length,start:function(b){return a.start[b]},end:function(b){return a.end[b]}}}
521
- var Km="ended play playing pause pausing ratechange seeked seeking timeupdate volumechange".split(" "),Lm="buffered currentTime duration ended loop muted paused playbackRate seeking videoHeight videoWidth volume".split(" "),Mm=["loop","playbackRate"],Nm=["pause","play"],Om={getAssetUri:2,getAudioLanguages:4,getAudioLanguagesAndRoles:4,getBufferFullness:1,getBufferedInfo:2,getConfiguration:4,getExpiration:2,getKeyStatuses:2,getPlaybackRate:2,getTextLanguages:4,getTextLanguagesAndRoles:4,getTextTracks:2,
522
- getStats:5,getVariantTracks:2,getImageTracks:2,getThumbnails:2,isAudioOnly:10,isBuffering:1,isInProgress:1,isLive:10,isTextTrackVisible:1,keySystem:10,seekRange:1,getLoadMode:10},Pm={getPlayheadTimeAsDate:1,getPresentationStartTimeAsDate:20},Qm=[["getConfiguration","configure"]],Rm=[["isTextTrackVisible","setTextTrackVisibility"]],Sm="addChaptersTrack addTextTrackAsync cancelTrickPlay configure getChapters getChaptersTracks resetConfiguration retryStreaming selectAudioLanguage selectTextLanguage selectTextTrack selectVariantTrack selectVariantsByLabel setTextTrackVisibility trickPlay updateStartTime goToLive".split(" "),
523
- Tm=["attach","detach","load","unload"];function Um(a,b,c,d,e,f,g){var h=this;this.I=a;this.P=g;this.j=new P(b);this.S=c;this.C=!1;this.B=d;this.H=e;this.K=f;this.h=this.m=!1;this.N="";this.A=null;this.F=function(){return Vm(h)};this.G=function(k,l){var m=Im(l);switch(m.type){case "event":var n=m.targetName;m=Pa(m.event);h.B(n,m);break;case "update":n=m.update;for(var p in n){m=h.g[p]||{};for(var r in n[p])m[r]=n[p][r]}h.C&&(h.S(),h.C=!1);break;case "asyncComplete":if(p=m.id,m=m.error,r=h.i[p],delete h.i[p],r)if(m){p=new O(m.severity,m.category,
524
- m.code);for(n in m)p[n]=m[n];r.reject(p)}else r.resolve()}};this.g={video:{},player:{}};this.J=0;this.i={};this.l=null;Wm.add(this)}q=Um.prototype;q.destroy=function(){Wm["delete"](this);Xm(this);Ym&&Zm(this);this.j&&(this.j.stop(),this.j=null);this.H=this.B=null;this.h=this.m=!1;this.G=this.F=this.l=this.i=this.g=this.A=null;return Promise.resolve()};q.qa=function(){return this.h};q.Cd=function(){return this.N};
525
- q.init=function(){if(this.I.length)if(window.chrome&&chrome.cast&&chrome.cast.isAvailable){this.m=!0;this.j.xa();var a=new chrome.cast.SessionRequest(this.I,[],null,this.P,null);a=new chrome.cast.ApiConfig(a,function(b){for(var c=t(Wm),d=c.next();!d.done;d=c.next())$m(d.value,b)},function(b){for(var c=t(Wm),d=c.next();!d.done;d=c.next())d=d.value,an="available"==b,d.j.xa()},"origin_scoped");chrome.cast.initialize(a,function(){},function(){});an&&this.j.T(bn);(a=Ym)&&a.status!=chrome.cast.SessionStatus.STOPPED?
526
- $m(this,a):Ym=null}else window.__onGCastApiAvailable||(window.__onGCastApiAvailable=cn),window.__onGCastApiAvailable!=cn&&Ua("A global Cast SDK hook is already installed! Shaka Player will be unable to receive a notification when the Cast SDK is ready.")};q.Ae=function(a){this.A=a;this.h&&dn(this,{type:"appData",appData:this.A})};
527
- q.cast=function(a){var b=this;return I(function(c){if(!b.m)throw new O(1,8,8E3);if(!an)throw new O(1,8,8001);if(b.h)throw new O(1,8,8002);b.l=new Nc;chrome.cast.requestSession(function(d){return en(b,a,d)},function(d){return fn(b,d)});return u(c,b.l,0)})};function gn(a){if(a.h){var b=a.K();chrome.cast.requestSession(function(c){return en(a,b,c)},function(c){return fn(a,c)})}}q.Zb=function(){if(this.h){Xm(this);if(Ym){Zm(this);try{Ym.stop(function(){},function(){})}catch(a){}Ym=null}Vm(this)}};
528
- q.get=function(a,b){var c=this;if("video"==a){if(Nm.includes(b))return function(){return c.Cf.apply(c,[a,b].concat(ia(Ha.apply(0,arguments))))}}else if("player"==a){if(Pm[b]&&!this.get("player","isLive")())return function(){};if(Sm.includes(b))return function(){return c.Cf.apply(c,[a,b].concat(ia(Ha.apply(0,arguments))))};if(Tm.includes(b))return function(){return c.ah.apply(c,[a,b].concat(ia(Ha.apply(0,arguments))))};if(Om[b])return function(){return c.g[a][b]}}return this.g[a][b]};
529
- q.set=function(a,b,c){this.g[a][b]=c;dn(this,{type:"set",targetName:a,property:b,value:c})};function en(a,b,c){Ym=c;c.addUpdateListener(a.F);c.addMessageListener("urn:x-cast:com.google.shaka.v2",a.G);Vm(a);dn(a,{type:"init",initState:b,appData:a.A});a.l.resolve()}function fn(a,b){var c=8003;switch(b.code){case "cancel":c=8004;break;case "timeout":c=8005;break;case "receiver_unavailable":c=8006}a.l.reject(new O(2,8,c,b))}
530
- q.Cf=function(a,b){dn(this,{type:"call",targetName:a,methodName:b,args:Ha.apply(2,arguments)})};q.ah=function(a,b){var c=Ha.apply(2,arguments),d=new Nc,e=this.J.toString();this.J++;this.i[e]=d;try{dn(this,{type:"asyncCall",targetName:a,methodName:b,args:c,id:e})}catch(f){d.reject(f)}return d};function $m(a,b){var c=a.K();a.l=new Nc;a.C=!0;en(a,c,b)}function Zm(a){var b=Ym;b.removeUpdateListener(a.F);b.removeMessageListener("urn:x-cast:com.google.shaka.v2",a.G)}
531
- function Vm(a){var b=Ym?"connected"==Ym.status:!1;if(a.h&&!b){a.H();for(var c in a.g)a.g[c]={};Xm(a)}a.h=b;a.N=b?Ym.receiver.friendlyName:"";a.j.xa()}function Xm(a){for(var b in a.i){var c=a.i[b];delete a.i[b];c.reject(new O(1,7,7E3))}}function dn(a,b){var c=Hm(b),d=Ym;try{d.sendMessage("urn:x-cast:com.google.shaka.v2",c,function(){},Xa)}catch(e){throw c=new O(2,8,8005,e),d=new M("error",(new Map).set("detail",c)),a.B("player",d),a.Zb(),c;}}var bn=.02,an=!1,Ym=null,Wm=new Set;
532
- function cn(a){if(a){a=t(Wm);for(var b=a.next();!b.done;b=a.next())b.value.init()}};function hn(a,b,c,d){d=void 0===d?!1:d;fb.call(this);var e=this;this.i=a;this.h=b;this.m=this.A=this.j=this.B=this.l=null;this.G=c;this.F=d;this.C=new Map;this.g=new Um(c,function(){return jn(e)},function(){return kn(e)},function(f,g){return ln(e,f,g)},function(){return mn(e)},function(){return nn(e)},d);on(this)}qa(hn,fb);q=hn.prototype;
533
- q.destroy=function(a){a&&this.g.Zb();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.B=this.l=this.i=null;fb.prototype.release.call(this);return Promise.all(a)};q.Bb=function(){return this.l};q.bc=function(){return this.B};q.Ye=function(){return this.g.m&&an};q.qa=function(){return this.g.qa()};q.Cd=function(){return this.g.Cd()};
534
- q.cast=function(){var a=this,b;return I(function(c){return 1==c.g?(b=nn(a),u(c,a.g.cast(b),2)):a.h?u(c,a.h.Pe(),0):c["return"]()})};q.Ae=function(a){this.g.Ae(a)};q.Kf=function(){gn(this.g)};q.Zb=function(){this.g.Zb()};
535
- q.cf=function(a,b){b=void 0===b?!1:b;var c=this;return I(function(d){if(1==d.g){if(a==c.G&&b==c.F)return d["return"]();c.G=a;c.F=b;c.g.Zb();return u(d,c.g.destroy(),2)}c.g=null;c.g=new Um(a,function(){return jn(c)},function(){return kn(c)},function(e,f){return ln(c,e,f)},function(){return mn(c)},function(){return nn(c)},b);c.g.init();z(d)})};
536
- function on(a){a.g.init();a.m=new tf;for(var b=t(Km),c=b.next();!c.done;c=b.next())a.m.o(a.i,c.value,function(f){a.g.qa()||(f=Pa(f),a.j.dispatchEvent(f))});for(var d in Qa)a.m.o(a.h,Qa[d],function(f){a.g.qa()||a.A.dispatchEvent(f)});a.l={};b={};for(var e in a.i)b.sc=e,Object.defineProperty(a.l,b.sc,{configurable:!1,enumerable:!0,get:function(f){return function(){return pn(a,f.sc)}}(b),set:function(f){return function(g){var h=f.sc;a.g.qa()?a.g.set("video",h,g):a.i[h]=g}}(b)}),b={sc:b.sc};a.B={};qn(a,
537
- function(f){Object.defineProperty(a.B,f,{configurable:!1,enumerable:!0,get:function(){return rn(a,f)}})});sn(a);a.j=new fb;a.j.rd=a.l;a.A=new fb;a.A.rd=a.B}function sn(a){var b=new Map;qn(a,function(c,d){if(b.has(d)){var e=b.get(d);c.length<e.length?a.C.set(c,e):a.C.set(e,c)}else b.set(d,c)})}
538
- function qn(a,b){function c(l){return"constructor"==l||"function"!=typeof d[l]?!1:!e.has(l)}var d=a.h,e=new Set;for(f in d)c(f)&&(e.add(f),b(f,d[f]));var f=Object.getPrototypeOf(d);for(var g=Object.getPrototypeOf({});f&&f!=g;){for(var h=t(Object.getOwnPropertyNames(f)),k=h.next();!k.done;k=h.next())k=k.value,c(k)&&(e.add(k),b(k,d[k]));f=Object.getPrototypeOf(f)}}
539
- function nn(a){var b={video:{},player:{},playerAfterLoad:{},manifest:a.h.Zd(),startTime:null};a.i.pause();for(var c=t(Mm),d=c.next();!d.done;d=c.next())d=d.value,b.video[d]=a.i[d];a.i.ended||(b.startTime=a.i.currentTime);c=t(Qm);for(d=c.next();!d.done;d=c.next()){var e=d.value;d=e[1];e=a.h[e[0]]();b.player[d]=e}c=t(Rm);for(d=c.next();!d.done;d=c.next())e=d.value,d=e[1],e=a.h[e[0]](),b.playerAfterLoad[d]=e;return b}function jn(a){var b=new M("caststatuschanged");a.dispatchEvent(b)}
540
- function kn(a){var b=new M(a.l.paused?"pause":"play");a.j.dispatchEvent(b)}
541
- function mn(a){for(var b=t(Qm),c=b.next();!c.done;c=b.next()){var d=c.value;c=d[1];d=a.g.get("player",d[0])();a.h[c](d)}var e=a.g.get("player","getAssetUri")();c=a.g.get("video","ended");b=Promise.resolve();var f=a.i.autoplay;d=null;c||(d=a.g.get("video","currentTime"));e&&(a.i.autoplay=!1,b=a.h.load(e,d));var g={};c=t(Mm);for(d=c.next();!d.done;d=c.next())d=d.value,g[d]=a.g.get("video",d);b.then(function(){if(a.i){for(var h=t(Mm),k=h.next();!k.done;k=h.next())k=k.value,a.i[k]=g[k];h=t(Rm);for(k=
542
- h.next();!k.done;k=h.next()){var l=k.value;k=l[1];l=a.g.get("player",l[0])();a.h[k](l)}a.i.autoplay=f;e&&a.i.play()}},function(h){h=(new Map).set("detail",h);h=new M("error",h);a.h.dispatchEvent(h)})}
543
- function pn(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.qa()&&0==Object.keys(a.g.g.video).length){var c=a.i[b];if("function"!=typeof c)return c}return a.g.qa()?a.g.get("video",b):(c=a.i[b],"function"==typeof c&&(c=c.bind(a.i)),c)}
544
- function rn(a,b){a.C.has(b)&&(b=a.C.get(b));if("addEventListener"==b)return function(c,d,e){return a.A.addEventListener(c,d,e)};if("removeEventListener"==b)return function(c,d,e){return a.A.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.Ec()};if("getDrmEngine"==b)return function(){return a.h.m};if("getAdManager"==b)return function(){return a.h.hd()};
545
- if("setVideoContainer"==b)return function(c){return a.h.Ie(c)};if(a.g.qa()){if("getManifest"==b||"drmInfo"==b)return function(){Ua(b+"() does not work while casting!");return null};if("attach"==b||"detach"==b)return function(){Ua(b+"() does not work while casting!");return Promise.resolve()}}return a.g.qa()&&0==Object.keys(a.g.g.video).length&&Om[b]||!a.g.qa()?a.h[b].bind(a.h):a.g.get("player",b)}function ln(a,b,c){a.g.qa()&&("video"==b?a.j.dispatchEvent(c):"player"==b&&a.A.dispatchEvent(c))}
546
- J("shaka.cast.CastProxy",hn);hn.prototype.changeReceiverId=hn.prototype.cf;hn.prototype.forceDisconnect=hn.prototype.Zb;hn.prototype.suggestDisconnect=hn.prototype.Kf;hn.prototype.setAppData=hn.prototype.Ae;hn.prototype.cast=hn.prototype.cast;hn.prototype.receiverName=hn.prototype.Cd;hn.prototype.isCasting=hn.prototype.qa;hn.prototype.canCast=hn.prototype.Ye;hn.prototype.getPlayer=hn.prototype.bc;hn.prototype.getVideo=hn.prototype.Bb;hn.prototype.destroy=hn.prototype.destroy;function tn(a,b,c,d){fb.call(this);var e=this;this.g=a;this.h=b;this.j=new tf;this.J={video:a,player:b};this.G=c||function(){};this.K=d||function(f){return f};this.i=null;this.H=!1;this.A=!0;this.m=0;this.F=!1;this.C=!0;this.B=this.l=null;this.I=new P(function(){un(e)});vn(this)}qa(tn,fb);q=tn.prototype;q.isConnected=function(){return this.H};q.Lg=function(){return this.A};q.kh=function(a){this.i=a};q.$f=function(){this.i=null};
547
- q.lh=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.title=a};q.jh=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.images=[{url:a}]};q.ih=function(a){this.i||(this.i={});this.i.artist=a;this.i.metadataType=cast.receiver.media.MetadataType.MUSIC_TRACK};
519
+ T.AD_LOADED="ad-loaded";T.ALL_ADS_COMPLETED="all-ads-completed";T.AD_LINEAR_CHANGED="ad-linear-changed";T.AD_METADATA="ad-metadata";T.AD_RECOVERABLE_ERROR="ad-recoverable-error";T.AD_BREAK_READY="ad-break-ready";T.AD_INTERACTION="ad-interaction";al=function(){return new T};function Km(a){return JSON.stringify(a,function(b,c){if("function"!=typeof c){if(c instanceof Event||c instanceof L){var d={};for(f in c){var e=c[f];e&&"object"==typeof e?"detail"==f&&(d[f]=e):f in Event||(d[f]=e)}return d}if(c instanceof Error){var f=new Set(["name","message","stack"]);for(d in c)f.add(d);e=t(Object.getOwnPropertyNames(c));for(d=e.next();!d.done;d=e.next())f.add(d.value);e={};f=t(f);for(d=f.next();!d.done;d=f.next())d=d.value,e[d]=c[d];f={__type__:"Error",contents:e}}else if(c instanceof
520
+ TimeRanges)for(f={__type__:"TimeRanges",length:c.length,start:[],end:[]},d=t(ei(c)),e=d.next();!e.done;e=d.next()){e=e.value;var g=e.end;f.start.push(e.start);f.end.push(g)}else f=c instanceof Uint8Array?{__type__:"Uint8Array",entries:Array.from(c)}:"number"==typeof c?isNaN(c)?"NaN":isFinite(c)?c:0>c?"-Infinity":"Infinity":c;return f}})}
521
+ function Lm(a){return JSON.parse(a,function(b,c){if("NaN"==c)var d=NaN;else if("-Infinity"==c)d=-Infinity;else if("Infinity"==c)d=Infinity;else if(c&&"object"==typeof c&&"TimeRanges"==c.__type__)d=Mm(c);else if(c&&"object"==typeof c&&"Uint8Array"==c.__type__)d=new Uint8Array(c.entries);else if(c&&"object"==typeof c&&"Error"==c.__type__){d=c.contents;var e=Error(d.message),f;for(f in d)e[f]=d[f];d=e}else d=c;return d})}
522
+ function Mm(a){return{length:a.length,start:function(b){return a.start[b]},end:function(b){return a.end[b]}}}
523
+ var Nm="ended play playing pause pausing ratechange seeked seeking timeupdate volumechange".split(" "),Om="buffered currentTime duration ended loop muted paused playbackRate seeking videoHeight videoWidth volume".split(" "),Pm=["loop","playbackRate"],Qm=["pause","play"],Rm={getAssetUri:2,getAudioLanguages:4,getAudioLanguagesAndRoles:4,getBufferFullness:1,getBufferedInfo:2,getConfiguration:4,getExpiration:2,getKeyStatuses:2,getPlaybackRate:2,getTextLanguages:4,getTextLanguagesAndRoles:4,getTextTracks:2,
524
+ getStats:5,getVariantTracks:2,getImageTracks:2,getThumbnails:2,isAudioOnly:10,isBuffering:1,isInProgress:1,isLive:10,isTextTrackVisible:1,keySystem:10,seekRange:1,getLoadMode:10},Sm={getPlayheadTimeAsDate:1,getPresentationStartTimeAsDate:20},Tm=[["getConfiguration","configure"]],Um=[["isTextTrackVisible","setTextTrackVisibility"]],Vm="addChaptersTrack addTextTrackAsync cancelTrickPlay configure getChapters getChaptersTracks resetConfiguration retryStreaming selectAudioLanguage selectTextLanguage selectTextTrack selectVariantTrack selectVariantsByLabel setTextTrackVisibility trickPlay updateStartTime goToLive".split(" "),
525
+ Wm=["attach","detach","load","unload"];function Xm(a,b,c,d,e,f,g){var h=this;this.I=a;this.P=g;this.j=new P(b);this.S=c;this.C=!1;this.B=d;this.H=e;this.K=f;this.h=this.m=!1;this.N="";this.A=null;this.F=function(){return Ym(h)};this.G=function(k,l){var m=Lm(l);switch(m.type){case "event":var n=m.targetName;m=Pa(m.event);h.B(n,m);break;case "update":n=m.update;for(var p in n){m=h.g[p]||{};for(var r in n[p])m[r]=n[p][r]}h.C&&(h.S(),h.C=!1);break;case "asyncComplete":if(p=m.id,m=m.error,r=h.i[p],delete h.i[p],r)if(m){p=new O(m.severity,m.category,
526
+ m.code);for(n in m)p[n]=m[n];r.reject(p)}else r.resolve()}};this.g={video:{},player:{}};this.J=0;this.i={};this.l=null;Zm.add(this)}q=Xm.prototype;q.destroy=function(){Zm["delete"](this);$m(this);an&&bn(this);this.j&&(this.j.stop(),this.j=null);this.H=this.B=null;this.h=this.m=!1;this.G=this.F=this.l=this.i=this.g=this.A=null;return Promise.resolve()};q.qa=function(){return this.h};q.Cd=function(){return this.N};
527
+ q.init=function(){if(this.I.length)if(window.chrome&&chrome.cast&&chrome.cast.isAvailable){this.m=!0;this.j.xa();var a=new chrome.cast.SessionRequest(this.I,[],null,this.P,null);a=new chrome.cast.ApiConfig(a,function(b){for(var c=t(Zm),d=c.next();!d.done;d=c.next())cn(d.value,b)},function(b){for(var c=t(Zm),d=c.next();!d.done;d=c.next())d=d.value,dn="available"==b,d.j.xa()},"origin_scoped");chrome.cast.initialize(a,function(){},function(){});dn&&this.j.T(en);(a=an)&&a.status!=chrome.cast.SessionStatus.STOPPED?
528
+ cn(this,a):an=null}else window.__onGCastApiAvailable||(window.__onGCastApiAvailable=fn),window.__onGCastApiAvailable!=fn&&Ua("A global Cast SDK hook is already installed! Shaka Player will be unable to receive a notification when the Cast SDK is ready.")};q.Be=function(a){this.A=a;this.h&&gn(this,{type:"appData",appData:this.A})};
529
+ q.cast=function(a){var b=this;return I(function(c){if(!b.m)throw new O(1,8,8E3);if(!dn)throw new O(1,8,8001);if(b.h)throw new O(1,8,8002);b.l=new Nc;chrome.cast.requestSession(function(d){return hn(b,a,d)},function(d){return jn(b,d)});return u(c,b.l,0)})};function kn(a){if(a.h){var b=a.K();chrome.cast.requestSession(function(c){return hn(a,b,c)},function(c){return jn(a,c)})}}q.Zb=function(){if(this.h){$m(this);if(an){bn(this);try{an.stop(function(){},function(){})}catch(a){}an=null}Ym(this)}};
530
+ q.get=function(a,b){var c=this;if("video"==a){if(Qm.includes(b))return function(){return c.Df.apply(c,[a,b].concat(ia(Ha.apply(0,arguments))))}}else if("player"==a){if(Sm[b]&&!this.get("player","isLive")())return function(){};if(Vm.includes(b))return function(){return c.Df.apply(c,[a,b].concat(ia(Ha.apply(0,arguments))))};if(Wm.includes(b))return function(){return c.bh.apply(c,[a,b].concat(ia(Ha.apply(0,arguments))))};if(Rm[b])return function(){return c.g[a][b]}}return this.g[a][b]};
531
+ q.set=function(a,b,c){this.g[a][b]=c;gn(this,{type:"set",targetName:a,property:b,value:c})};function hn(a,b,c){an=c;c.addUpdateListener(a.F);c.addMessageListener("urn:x-cast:com.google.shaka.v2",a.G);Ym(a);gn(a,{type:"init",initState:b,appData:a.A});a.l.resolve()}function jn(a,b){var c=8003;switch(b.code){case "cancel":c=8004;break;case "timeout":c=8005;break;case "receiver_unavailable":c=8006}a.l.reject(new O(2,8,c,b))}
532
+ q.Df=function(a,b){gn(this,{type:"call",targetName:a,methodName:b,args:Ha.apply(2,arguments)})};q.bh=function(a,b){var c=Ha.apply(2,arguments),d=new Nc,e=this.J.toString();this.J++;this.i[e]=d;try{gn(this,{type:"asyncCall",targetName:a,methodName:b,args:c,id:e})}catch(f){d.reject(f)}return d};function cn(a,b){var c=a.K();a.l=new Nc;a.C=!0;hn(a,c,b)}function bn(a){var b=an;b.removeUpdateListener(a.F);b.removeMessageListener("urn:x-cast:com.google.shaka.v2",a.G)}
533
+ function Ym(a){var b=an?"connected"==an.status:!1;if(a.h&&!b){a.H();for(var c in a.g)a.g[c]={};$m(a)}a.h=b;a.N=b?an.receiver.friendlyName:"";a.j.xa()}function $m(a){for(var b in a.i){var c=a.i[b];delete a.i[b];c.reject(new O(1,7,7E3))}}function gn(a,b){var c=Km(b),d=an;try{d.sendMessage("urn:x-cast:com.google.shaka.v2",c,function(){},Xa)}catch(e){throw c=new O(2,8,8005,e),d=new L("error",(new Map).set("detail",c)),a.B("player",d),a.Zb(),c;}}var en=.02,dn=!1,an=null,Zm=new Set;
534
+ function fn(a){if(a){a=t(Zm);for(var b=a.next();!b.done;b=a.next())b.value.init()}};function ln(a,b,c,d){d=void 0===d?!1:d;fb.call(this);var e=this;this.i=a;this.h=b;this.m=this.A=this.j=this.B=this.l=null;this.G=c;this.F=d;this.C=new Map;this.g=new Xm(c,function(){return mn(e)},function(){return nn(e)},function(f,g){return on(e,f,g)},function(){return pn(e)},function(){return qn(e)},d);rn(this)}qa(ln,fb);q=ln.prototype;
535
+ q.destroy=function(a){a&&this.g.Zb();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.B=this.l=this.i=null;fb.prototype.release.call(this);return Promise.all(a)};q.Bb=function(){return this.l};q.bc=function(){return this.B};q.Ze=function(){return this.g.m&&dn};q.qa=function(){return this.g.qa()};q.Cd=function(){return this.g.Cd()};
536
+ q.cast=function(){var a=this,b;return I(function(c){return 1==c.g?(b=qn(a),u(c,a.g.cast(b),2)):a.h?u(c,a.h.Qe(),0):c["return"]()})};q.Be=function(a){this.g.Be(a)};q.Lf=function(){kn(this.g)};q.Zb=function(){this.g.Zb()};
537
+ q.df=function(a,b){b=void 0===b?!1:b;var c=this;return I(function(d){if(1==d.g){if(a==c.G&&b==c.F)return d["return"]();c.G=a;c.F=b;c.g.Zb();return u(d,c.g.destroy(),2)}c.g=null;c.g=new Xm(a,function(){return mn(c)},function(){return nn(c)},function(e,f){return on(c,e,f)},function(){return pn(c)},function(){return qn(c)},b);c.g.init();z(d)})};
538
+ function rn(a){a.g.init();a.m=new wf;for(var b=t(Nm),c=b.next();!c.done;c=b.next())a.m.o(a.i,c.value,function(f){a.g.qa()||(f=Pa(f),a.j.dispatchEvent(f))});for(var d in Qa)a.m.o(a.h,Qa[d],function(f){a.g.qa()||a.A.dispatchEvent(f)});a.l={};b={};for(var e in a.i)b.sc=e,Object.defineProperty(a.l,b.sc,{configurable:!1,enumerable:!0,get:function(f){return function(){return sn(a,f.sc)}}(b),set:function(f){return function(g){var h=f.sc;a.g.qa()?a.g.set("video",h,g):a.i[h]=g}}(b)}),b={sc:b.sc};a.B={};tn(a,
539
+ function(f){Object.defineProperty(a.B,f,{configurable:!1,enumerable:!0,get:function(){return un(a,f)}})});vn(a);a.j=new fb;a.j.rd=a.l;a.A=new fb;a.A.rd=a.B}function vn(a){var b=new Map;tn(a,function(c,d){if(b.has(d)){var e=b.get(d);c.length<e.length?a.C.set(c,e):a.C.set(e,c)}else b.set(d,c)})}
540
+ function tn(a,b){function c(l){return"constructor"==l||"function"!=typeof d[l]?!1:!e.has(l)}var d=a.h,e=new Set;for(f in d)c(f)&&(e.add(f),b(f,d[f]));var f=Object.getPrototypeOf(d);for(var g=Object.getPrototypeOf({});f&&f!=g;){for(var h=t(Object.getOwnPropertyNames(f)),k=h.next();!k.done;k=h.next())k=k.value,c(k)&&(e.add(k),b(k,d[k]));f=Object.getPrototypeOf(f)}}
541
+ function qn(a){var b={video:{},player:{},playerAfterLoad:{},manifest:a.h.Zd(),startTime:null};a.i.pause();for(var c=t(Pm),d=c.next();!d.done;d=c.next())d=d.value,b.video[d]=a.i[d];a.i.ended||(b.startTime=a.i.currentTime);c=t(Tm);for(d=c.next();!d.done;d=c.next()){var e=d.value;d=e[1];e=a.h[e[0]]();b.player[d]=e}c=t(Um);for(d=c.next();!d.done;d=c.next())e=d.value,d=e[1],e=a.h[e[0]](),b.playerAfterLoad[d]=e;return b}function mn(a){var b=new L("caststatuschanged");a.dispatchEvent(b)}
542
+ function nn(a){var b=new L(a.l.paused?"pause":"play");a.j.dispatchEvent(b)}
543
+ function pn(a){for(var b=t(Tm),c=b.next();!c.done;c=b.next()){var d=c.value;c=d[1];d=a.g.get("player",d[0])();a.h[c](d)}var e=a.g.get("player","getAssetUri")();c=a.g.get("video","ended");b=Promise.resolve();var f=a.i.autoplay;d=null;c||(d=a.g.get("video","currentTime"));e&&(a.i.autoplay=!1,b=a.h.load(e,d));var g={};c=t(Pm);for(d=c.next();!d.done;d=c.next())d=d.value,g[d]=a.g.get("video",d);b.then(function(){if(a.i){for(var h=t(Pm),k=h.next();!k.done;k=h.next())k=k.value,a.i[k]=g[k];h=t(Um);for(k=
544
+ h.next();!k.done;k=h.next()){var l=k.value;k=l[1];l=a.g.get("player",l[0])();a.h[k](l)}a.i.autoplay=f;e&&a.i.play()}},function(h){h=(new Map).set("detail",h);h=new L("error",h);a.h.dispatchEvent(h)})}
545
+ function sn(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.qa()&&0==Object.keys(a.g.g.video).length){var c=a.i[b];if("function"!=typeof c)return c}return a.g.qa()?a.g.get("video",b):(c=a.i[b],"function"==typeof c&&(c=c.bind(a.i)),c)}
546
+ function un(a,b){a.C.has(b)&&(b=a.C.get(b));if("addEventListener"==b)return function(c,d,e){return a.A.addEventListener(c,d,e)};if("removeEventListener"==b)return function(c,d,e){return a.A.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.Ec()};if("getDrmEngine"==b)return function(){return a.h.m};if("getAdManager"==b)return function(){return a.h.hd()};
547
+ if("setVideoContainer"==b)return function(c){return a.h.Je(c)};if(a.g.qa()){if("getManifest"==b||"drmInfo"==b)return function(){Ua(b+"() does not work while casting!");return null};if("attach"==b||"detach"==b)return function(){Ua(b+"() does not work while casting!");return Promise.resolve()}}return a.g.qa()&&0==Object.keys(a.g.g.video).length&&Rm[b]||!a.g.qa()?a.h[b].bind(a.h):a.g.get("player",b)}function on(a,b,c){a.g.qa()&&("video"==b?a.j.dispatchEvent(c):"player"==b&&a.A.dispatchEvent(c))}
548
+ J("shaka.cast.CastProxy",ln);ln.prototype.changeReceiverId=ln.prototype.df;ln.prototype.forceDisconnect=ln.prototype.Zb;ln.prototype.suggestDisconnect=ln.prototype.Lf;ln.prototype.setAppData=ln.prototype.Be;ln.prototype.cast=ln.prototype.cast;ln.prototype.receiverName=ln.prototype.Cd;ln.prototype.isCasting=ln.prototype.qa;ln.prototype.canCast=ln.prototype.Ze;ln.prototype.getPlayer=ln.prototype.bc;ln.prototype.getVideo=ln.prototype.Bb;ln.prototype.destroy=ln.prototype.destroy;function wn(a,b,c,d){fb.call(this);var e=this;this.g=a;this.h=b;this.j=new wf;this.J={video:a,player:b};this.G=c||function(){};this.K=d||function(f){return f};this.i=null;this.H=!1;this.A=!0;this.m=0;this.F=!1;this.C=!0;this.B=this.l=null;this.I=new P(function(){xn(e)});yn(this)}qa(wn,fb);q=wn.prototype;q.isConnected=function(){return this.H};q.Mg=function(){return this.A};q.lh=function(a){this.i=a};q.ag=function(){this.i=null};
549
+ q.mh=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.title=a};q.kh=function(a){this.i||(this.i={metadataType:cast.receiver.media.MetadataType.GENERIC});this.i.images=[{url:a}]};q.jh=function(a){this.i||(this.i={});this.i.artist=a;this.i.metadataType=cast.receiver.media.MetadataType.MUSIC_TRACK};
548
550
  q.destroy=function(){var a=this,b,c;return I(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.A=!0,a.l=null,a.B=null,fb.prototype.release.call(a),u(d,Promise.all(b),2);c=cast.receiver.CastReceiverManager.getInstance();c.stop();z(d)})};
549
- function vn(a){var b=cast.receiver.CastReceiverManager.getInstance();b.onSenderConnected=function(){return wn(a)};b.onSenderDisconnected=function(){return wn(a)};b.onSystemVolumeChanged=function(){var e=cast.receiver.CastReceiverManager.getInstance().getSystemVolume();e&&xn(a,{type:"update",update:{video:{volume:e.level,muted:e.muted}}},a.l);xn(a,{type:"event",targetName:"video",event:{type:"volumechange"}},a.l)};a.B=b.getCastMessageBus("urn:x-cast:com.google.cast.media");a.B.onMessage=function(e){return yn(a,
550
- e)};a.l=b.getCastMessageBus("urn:x-cast:com.google.shaka.v2");a.l.onMessage=function(e){return zn(a,e)};b.start();b=t(Km);for(var c=b.next();!c.done;c=b.next())a.j.o(a.g,c.value,function(e){return An(a,"video",e)});for(var d in Qa)a.j.o(a.h,Qa[d],function(e){return An(a,"player",e)});cast.__platform__&&cast.__platform__.canDisplayType('video/mp4; codecs="avc1.640028"; width=3840; height=2160')?a.h.De(3840,2160):a.h.De(1920,1080);a.j.o(a.g,"loadeddata",function(){a.F=!0});a.j.o(a.h,"loading",function(){a.A=
551
- !1;Bn(a)});a.j.o(a.g,"playing",function(){a.A=!1;Bn(a)});a.j.o(a.g,"pause",function(){Bn(a)});a.j.o(a.h,"unloading",function(){a.A=!0;Bn(a)});a.j.o(a.g,"ended",function(){(new P(function(){a.g&&a.g.ended&&(a.A=!0,Bn(a))})).T(Cn)})}function wn(a){a.m=0;a.C=!0;a.H=0!=cast.receiver.CastReceiverManager.getInstance().getSenders().length;Bn(a)}
552
- function Bn(a){var b;I(function(c){if(1==c.g)return u(c,Promise.resolve(),2);if(!a.h)return c["return"]();b=new M("caststatuschanged");a.dispatchEvent(b);Dn(a)||En(a);z(c)})}
553
- function Fn(a,b,c){var d,e,f,g,h,k,l,m,n,p;I(function(r){switch(r.g){case 1:for(d in b.player)e=b.player[d],a.h[d](e);a.G(c);f=a.g.autoplay;return b.manifest?(a.g.autoplay=!1,A(r,5),u(r,a.h.load(b.manifest,b.startTime),7)):u(r,Promise.resolve(),3);case 7:va(r,3);break;case 5:return g=F(r),h=(new Map).set("detail",g),k=new M("error",h),a.h&&a.h.dispatchEvent(k),r["return"]();case 3:if(!a.h)return r["return"]();for(l in b.video)m=b.video[l],a.g[l]=m;for(n in b.playerAfterLoad)p=b.playerAfterLoad[n],
554
- a.h[n](p);a.g.autoplay=f;b.manifest&&(a.g.play(),En(a));z(r)}})}function An(a,b,c){a.h&&(un(a),xn(a,{type:"event",targetName:b,event:c},a.l))}
555
- function un(a){a.I.T(Gn);for(var b={video:{},player:{}},c=t(Lm),d=c.next();!d.done;d=c.next())d=d.value,b.video[d]=a.g[d];if(a.h.U())for(var e in Pm)0==a.m%Pm[e]&&(b.player[e]=a.h[e]());for(var f in Om)0==a.m%Om[f]&&(b.player[f]=a.h[f]());if(c=cast.receiver.CastReceiverManager.getInstance().getSystemVolume())b.video.volume=c.level,b.video.muted=c.muted;a.F&&(a.m+=1);xn(a,{type:"update",update:b},a.l);Dn(a)}function Dn(a){return a.C&&(a.g.duration||a.h.U())?(Hn(a),a.C=!1,!0):!1}
556
- function Hn(a,b){var c={contentId:a.h.Zd(),streamType:a.h.U()?"LIVE":"BUFFERED",contentType:""};a.h.U()||(c.duration=a.g.duration);a.i&&(c.metadata=a.i);En(a,void 0===b?0:b,c)}
557
- function zn(a,b){var c=Im(b.data);switch(c.type){case "init":a.m=0;a.F=!1;a.C=!0;Fn(a,c.initState,c.appData);un(a);break;case "appData":a.G(c.appData);break;case "set":var d=c.targetName,e=c.property;c=c.value;if("video"==d){var f=cast.receiver.CastReceiverManager.getInstance();if("volume"==e){f.setSystemVolumeLevel(c);break}else if("muted"==e){f.setSystemVolumeMuted(c);break}}a.J[d][e]=c;break;case "call":d=a.J[c.targetName];d[c.methodName].apply(d,c.args);break;case "asyncCall":d=c.targetName;e=
558
- c.methodName;"player"==d&&"load"==e&&(a.m=0,a.F=!1);var g=c.id,h=b.senderId;f=a.J[d];c=f[e].apply(f,c.args);"player"==d&&"load"==e&&(c=c.then(function(){a.C=!0}));c.then(function(){return In(a,h,g,null)},function(k){return In(a,h,g,k)})}}
559
- function yn(a,b){var c=Im(b.data);switch(c.type){case "PLAY":a.g.play();En(a);break;case "PAUSE":a.g.pause();En(a);break;case "SEEK":var d=c.currentTime,e=c.resumeState;null!=d&&(a.g.currentTime=Number(d));e&&"PLAYBACK_START"==e?(a.g.play(),En(a)):e&&"PLAYBACK_PAUSE"==e&&(a.g.pause(),En(a));break;case "STOP":a.h.Pe().then(function(){a.h&&En(a)});break;case "GET_STATUS":Hn(a,Number(c.requestId));break;case "VOLUME":e=c.volume;d=e.level;e=e.muted;var f=a.g.volume,g=a.g.muted;null!=d&&(a.g.volume=Number(d));
560
- null!=e&&(a.g.muted=e);f==a.g.volume&&g==a.g.muted||En(a);break;case "LOAD":a.m=0;a.F=!1;a.C=!1;d=c.media;e=c.currentTime;f=a.K(d.contentId);g=c.autoplay||!0;a.G(d.customData);g&&(a.g.autoplay=!0);a.h.load(f,e).then(function(){a.h&&Hn(a)})["catch"](function(h){var k="LOAD_FAILED";7==h.category&&7E3==h.code&&(k="LOAD_CANCELLED");xn(a,{requestId:Number(c.requestId),type:k},a.B)});break;default:xn(a,{requestId:Number(c.requestId),type:"INVALID_REQUEST",reason:"INVALID_COMMAND"},a.B)}}
561
- function In(a,b,c,d){a.h&&xn(a,{type:"asyncComplete",id:c,error:d},a.l,b)}function xn(a,b,c,d){a.H&&(a=Hm(b),d?c.getCastChannel(d).send(a):c.broadcast(a))}function En(a,b,c){c=void 0===c?null:c;var d={mediaSessionId:0,playbackRate:a.g.playbackRate,playerState:a.A?Jn:a.h.Kc()?Kn:a.g.paused?Ln:Mn,currentTime:a.g.currentTime,supportedMediaCommands:63,volume:{level:a.g.volume,muted:a.g.muted}};c&&(d.media=c);xn(a,{requestId:void 0===b?0:b,type:"MEDIA_STATUS",status:[d]},a.B)}
562
- J("shaka.cast.CastReceiver",tn);tn.prototype.destroy=tn.prototype.destroy;tn.prototype.setContentArtist=tn.prototype.ih;tn.prototype.setContentImage=tn.prototype.jh;tn.prototype.setContentTitle=tn.prototype.lh;tn.prototype.clearContentMetadata=tn.prototype.$f;tn.prototype.setContentMetadata=tn.prototype.kh;tn.prototype.isIdle=tn.prototype.Lg;tn.prototype.isConnected=tn.prototype.isConnected;var Gn=.5,Cn=5,Jn="IDLE",Mn="PLAYING",Kn="BUFFERING",Ln="PAUSED";function Nn(a){var b=this;this.g=[];this.h=[];this.data=[];(new xg).box("moov",Bg).Y("pssh",function(c){if(!(1<c.version)){var d=Gc(c.reader.W,-12,c.size);b.data.push(d);b.g.push(bd(c.reader.Cb(16)));if(0<c.version){d=c.reader.R();for(var e=0;e<d;e++){var f=bd(c.reader.Cb(16));b.h.push(f)}}}}).parse(a)}
563
- function On(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=Jc(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=ad(c.value),g.set(c,k),k+=c.length;h.setUint32(k,e);g.set(a,k+4);return g};function Pn(a,b){var c=Qn(a,b);return 1!=c.length?null:c[0]}function Rn(a,b,c){a=Sn(a,b,c);return 1!=a.length?null:a[0]}function Qn(a,b){for(var c=[],d=t(a.childNodes),e=d.next();!e.done;e=d.next())e=e.value,e instanceof Element&&e.tagName==b&&c.push(e);return c}function Tn(a){return Array.from(a.childNodes).filter(function(b){return b instanceof Element})}
564
- function Sn(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 Un(a,b,c){return a.hasAttributeNS(b,c)?a.getAttributeNS(b,c):null}function Vn(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 Wn(a){return Array.from(a.childNodes).every(Xn)?a.textContent.trim():null}
565
- function Xn(a){return a.nodeType==Node.TEXT_NODE||a.nodeType==Node.CDATA_SECTION_NODE}function Yn(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 Zn(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}
566
- function $n(a){if(!a)return null;a=RegExp("^P(?:([0-9]*)Y)?(?:([0-9]*)M)?(?:([0-9]*)D)?(?:T(?:([0-9]*)H)?(?:([0-9]*)M)?(?:([0-9.]*)S)?)?$").exec(a);if(!a)return null;a=31536E3*Number(a[1]||null)+2592E3*Number(a[2]||null)+86400*Number(a[3]||null)+3600*Number(a[4]||null)+60*Number(a[5]||null)+Number(a[6]||null);return isFinite(a)?a:null}
567
- function ao(a){var b=/([0-9]+)-([0-9]+)/.exec(a);if(!b)return null;a=Number(b[1]);if(!isFinite(a))return null;b=Number(b[2]);return isFinite(b)?{start:a,end:b}:null}function bo(a){a=Number(a);return 0===a%1?a:null}function co(a){a=Number(a);return 0===a%1&&0<a?a:null}function eo(a){a=Number(a);return 0===a%1&&0<=a?a:null}function fo(a){a=Number(a);return isNaN(a)?null:a}function go(a){var b;var c=(b=a.match(/^(\d+)\/(\d+)$/))?Number(b[1])/Number(b[2]):Number(a);return isNaN(c)?null:c}
568
- function ho(a,b){var c=new DOMParser,d=null;try{d=c.parseFromString(a,"text/xml")}catch(e){return null}c=d.documentElement;return!c||c.getElementsByTagName("parsererror").length||d.documentElement.tagName!=b?null:c}function io(a,b){try{var c=Rc(a);return ho(c,b)}catch(d){return null}};function jo(a,b,c){var d=ko(a),e=null;a=[];var f=[],g=new Set(d.map(function(h){return h.keyId}));g["delete"](null);if(1<g.size)throw new O(2,4,4010);b||(f=d.filter(function(h){return"urn:mpeg:dash:mp4protection:2011"==h.we?(e=h.init||e,!1):!0}),f.length&&(a=lo(e,f,c,g),0==a.length&&(a=[Eb("",e)])));if(d.length&&(b||!f.length))for(a=[],b=t(Object.values(c)),c=b.next();!c.done;c=b.next())c=c.value,"org.w3.clearkey"!=c&&a.push(Eb(c,e));if(g=Array.from(g)[0]||null)for(b=t(a),c=b.next();!c.done;c=b.next())for(c=
569
- t(c.value.initData),d=c.next();!d.done;d=c.next())d.value.keyId=g;return{hf:g,Vi:e,drmInfos:a,mf:!0}}function mo(a,b,c,d){var e=jo(a,c,d);if(b.mf){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.mf=!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 O(2,4,4008);return e.hf||b.hf}
570
- function no(a){var b=0,c=Jc(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=Gc(c,a,e);b.push({type:d,value:f});a+=e}c=b}return c}
571
- function oo(a){a=t(a.getElementsByTagName("DATA"));for(var b=a.next();!b.done;b=a.next()){b=t(b.value.childNodes);for(var c=b.next();!c.done;c=b.next())if(c=c.value,c instanceof Element&&"LA_URL"==c.tagName)return c.textContent}return""}function po(a){a=Rn(a.node,"urn:microsoft:playready","pro");if(!a)return"";a=$c(a.textContent);a=no(a).filter(function(b){return b.type===qo})[0];if(!a)return"";a=Sc(a.value,!0);return(a=ho(a,"WRMHEADER"))?oo(a):""}
572
- function lo(a,b,c,d){var e=[];b=t(b);for(var f=b.next();!f.done;f=b.next()){f=f.value;var g=c[f.we];if(g){var h;if(h=Rn(f.node,"urn:microsoft:playready","pro")){h=$c(h.textContent);var k=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);h=[{initData:On(h,k,new Set,0),initDataType:"cenc",keyId:f.keyId}]}else h=null;k=null;if("urn:uuid:e2719d58-a985-b3c9-781a-b030af78d30e"===f.we)if(k=d,0==k.size)k=null;else{var l=new Uint8Array([16,119,239,236,192,178,77,2,172,227,60,30,82,
573
- 226,251,75]),m=new Uint8Array([]);k=[{initData:On(m,l,k,1),initDataType:"cenc",keyId:f.keyId}]}h=Eb(g,f.init||a||h||k);if(g=ro.get(g))h.licenseServerUri=g(f);e.push(h)}}return e}function ko(a){var b=[];a=t(a);for(var c=a.next();!c.done;c=a.next())(c=so(c.value))&&b.push(c);return b}
574
- function so(a){var b=a.getAttribute("schemeIdUri"),c=Un(a,"urn:mpeg:cenc:2013","default_KID"),d=Sn(a,"urn:mpeg:cenc:2013","pssh").map(Wn);if(!b)return null;b=b.toLowerCase();if(c&&(c=c.replace(/-/g,"").toLowerCase(),c.includes(" ")))throw new O(2,4,4009);var e=[];try{e=d.map(function(f){return{initDataType:"cenc",initData:$c(f),keyId:null}})}catch(f){throw new O(2,4,4007);}return{node:a,we:b,keyId:c,init:0<e.length?e:null}}
575
- var qo=1,ro=(new Map).set("com.widevine.alpha",function(a){return(a=Rn(a.node,"urn:microsoft","laurl"))?a.getAttribute("licenseUrl")||"":""}).set("com.microsoft.playready",po).set("com.microsoft.playready.recommendation",po).set("com.microsoft.playready.software",po).set("com.microsoft.playready.hardware",po).set("org.w3.clearkey",function(a){return(a=Rn(a.node,"http://dashif.org/guidelines/clearKey","Laurl"))&&"EME-1.0"===a.getAttribute("Lic_type")&&a.textContent?a.textContent:""});function to(a,b,c,d,e){var f={RepresentationID:b,Number:c,Bandwidth:d,Time:e};return a.replace(/\$(RepresentationID|Number|Bandwidth|Time)?(?:%0([0-9]+)([diouxX]))?\$/g,function(g,h,k,l){if("$$"==g)return"$";var m=f[h];if(null==m)return g;"RepresentationID"==h&&k&&(k=void 0);"Time"==h&&(m=Math.round(m));switch(l){case void 0:case "d":case "i":case "u":g=m.toString();break;case "o":g=m.toString(8);break;case "x":g=m.toString(16);break;case "X":g=m.toString(16).toUpperCase();break;default:g=m.toString()}k=
551
+ function yn(a){var b=cast.receiver.CastReceiverManager.getInstance();b.onSenderConnected=function(){return zn(a)};b.onSenderDisconnected=function(){return zn(a)};b.onSystemVolumeChanged=function(){var e=cast.receiver.CastReceiverManager.getInstance().getSystemVolume();e&&An(a,{type:"update",update:{video:{volume:e.level,muted:e.muted}}},a.l);An(a,{type:"event",targetName:"video",event:{type:"volumechange"}},a.l)};a.B=b.getCastMessageBus("urn:x-cast:com.google.cast.media");a.B.onMessage=function(e){return Bn(a,
552
+ e)};a.l=b.getCastMessageBus("urn:x-cast:com.google.shaka.v2");a.l.onMessage=function(e){return Cn(a,e)};b.start();b=t(Nm);for(var c=b.next();!c.done;c=b.next())a.j.o(a.g,c.value,function(e){return Dn(a,"video",e)});for(var d in Qa)a.j.o(a.h,Qa[d],function(e){return Dn(a,"player",e)});cast.__platform__&&cast.__platform__.canDisplayType('video/mp4; codecs="avc1.640028"; width=3840; height=2160')?a.h.Ee(3840,2160):a.h.Ee(1920,1080);a.j.o(a.g,"loadeddata",function(){a.F=!0});a.j.o(a.h,"loading",function(){a.A=
553
+ !1;En(a)});a.j.o(a.g,"playing",function(){a.A=!1;En(a)});a.j.o(a.g,"pause",function(){En(a)});a.j.o(a.h,"unloading",function(){a.A=!0;En(a)});a.j.o(a.g,"ended",function(){(new P(function(){a.g&&a.g.ended&&(a.A=!0,En(a))})).T(Fn)})}function zn(a){a.m=0;a.C=!0;a.H=0!=cast.receiver.CastReceiverManager.getInstance().getSenders().length;En(a)}
554
+ function En(a){var b;I(function(c){if(1==c.g)return u(c,Promise.resolve(),2);if(!a.h)return c["return"]();b=new L("caststatuschanged");a.dispatchEvent(b);Gn(a)||Hn(a);z(c)})}
555
+ function In(a,b,c){var d,e,f,g,h,k,l,m,n,p;I(function(r){switch(r.g){case 1:for(d in b.player)e=b.player[d],a.h[d](e);a.G(c);f=a.g.autoplay;return b.manifest?(a.g.autoplay=!1,A(r,5),u(r,a.h.load(b.manifest,b.startTime),7)):u(r,Promise.resolve(),3);case 7:va(r,3);break;case 5:return g=F(r),h=(new Map).set("detail",g),k=new L("error",h),a.h&&a.h.dispatchEvent(k),r["return"]();case 3:if(!a.h)return r["return"]();for(l in b.video)m=b.video[l],a.g[l]=m;for(n in b.playerAfterLoad)p=b.playerAfterLoad[n],
556
+ a.h[n](p);a.g.autoplay=f;b.manifest&&(a.g.play(),Hn(a));z(r)}})}function Dn(a,b,c){a.h&&(xn(a),An(a,{type:"event",targetName:b,event:c},a.l))}
557
+ function xn(a){a.I.T(Jn);for(var b={video:{},player:{}},c=t(Om),d=c.next();!d.done;d=c.next())d=d.value,b.video[d]=a.g[d];if(a.h.U())for(var e in Sm)0==a.m%Sm[e]&&(b.player[e]=a.h[e]());for(var f in Rm)0==a.m%Rm[f]&&(b.player[f]=a.h[f]());if(c=cast.receiver.CastReceiverManager.getInstance().getSystemVolume())b.video.volume=c.level,b.video.muted=c.muted;a.F&&(a.m+=1);An(a,{type:"update",update:b},a.l);Gn(a)}function Gn(a){return a.C&&(a.g.duration||a.h.U())?(Kn(a),a.C=!1,!0):!1}
558
+ function Kn(a,b){var c={contentId:a.h.Zd(),streamType:a.h.U()?"LIVE":"BUFFERED",contentType:""};a.h.U()||(c.duration=a.g.duration);a.i&&(c.metadata=a.i);Hn(a,void 0===b?0:b,c)}
559
+ function Cn(a,b){var c=Lm(b.data);switch(c.type){case "init":a.m=0;a.F=!1;a.C=!0;In(a,c.initState,c.appData);xn(a);break;case "appData":a.G(c.appData);break;case "set":var d=c.targetName,e=c.property;c=c.value;if("video"==d){var f=cast.receiver.CastReceiverManager.getInstance();if("volume"==e){f.setSystemVolumeLevel(c);break}else if("muted"==e){f.setSystemVolumeMuted(c);break}}a.J[d][e]=c;break;case "call":d=a.J[c.targetName];d[c.methodName].apply(d,c.args);break;case "asyncCall":d=c.targetName;e=
560
+ c.methodName;"player"==d&&"load"==e&&(a.m=0,a.F=!1);var g=c.id,h=b.senderId;f=a.J[d];c=f[e].apply(f,c.args);"player"==d&&"load"==e&&(c=c.then(function(){a.C=!0}));c.then(function(){return Ln(a,h,g,null)},function(k){return Ln(a,h,g,k)})}}
561
+ function Bn(a,b){var c=Lm(b.data);switch(c.type){case "PLAY":a.g.play();Hn(a);break;case "PAUSE":a.g.pause();Hn(a);break;case "SEEK":var d=c.currentTime,e=c.resumeState;null!=d&&(a.g.currentTime=Number(d));e&&"PLAYBACK_START"==e?(a.g.play(),Hn(a)):e&&"PLAYBACK_PAUSE"==e&&(a.g.pause(),Hn(a));break;case "STOP":a.h.Qe().then(function(){a.h&&Hn(a)});break;case "GET_STATUS":Kn(a,Number(c.requestId));break;case "VOLUME":e=c.volume;d=e.level;e=e.muted;var f=a.g.volume,g=a.g.muted;null!=d&&(a.g.volume=Number(d));
562
+ null!=e&&(a.g.muted=e);f==a.g.volume&&g==a.g.muted||Hn(a);break;case "LOAD":a.m=0;a.F=!1;a.C=!1;d=c.media;e=c.currentTime;f=a.K(d.contentId);g=c.autoplay||!0;a.G(d.customData);g&&(a.g.autoplay=!0);a.h.load(f,e).then(function(){a.h&&Kn(a)})["catch"](function(h){var k="LOAD_FAILED";7==h.category&&7E3==h.code&&(k="LOAD_CANCELLED");An(a,{requestId:Number(c.requestId),type:k},a.B)});break;default:An(a,{requestId:Number(c.requestId),type:"INVALID_REQUEST",reason:"INVALID_COMMAND"},a.B)}}
563
+ function Ln(a,b,c,d){a.h&&An(a,{type:"asyncComplete",id:c,error:d},a.l,b)}function An(a,b,c,d){a.H&&(a=Km(b),d?c.getCastChannel(d).send(a):c.broadcast(a))}function Hn(a,b,c){c=void 0===c?null:c;var d={mediaSessionId:0,playbackRate:a.g.playbackRate,playerState:a.A?Mn:a.h.Kc()?Nn:a.g.paused?On:Pn,currentTime:a.g.currentTime,supportedMediaCommands:63,volume:{level:a.g.volume,muted:a.g.muted}};c&&(d.media=c);An(a,{requestId:void 0===b?0:b,type:"MEDIA_STATUS",status:[d]},a.B)}
564
+ J("shaka.cast.CastReceiver",wn);wn.prototype.destroy=wn.prototype.destroy;wn.prototype.setContentArtist=wn.prototype.jh;wn.prototype.setContentImage=wn.prototype.kh;wn.prototype.setContentTitle=wn.prototype.mh;wn.prototype.clearContentMetadata=wn.prototype.ag;wn.prototype.setContentMetadata=wn.prototype.lh;wn.prototype.isIdle=wn.prototype.Mg;wn.prototype.isConnected=wn.prototype.isConnected;var Jn=.5,Fn=5,Mn="IDLE",Pn="PLAYING",Nn="BUFFERING",On="PAUSED";function Qn(a){var b=this;this.g=[];this.h=[];this.data=[];(new Ag).box("moov",Eg).Y("pssh",function(c){if(!(1<c.version)){var d=Gc(c.reader.W,-12,c.size);b.data.push(d);b.g.push(qd(c.reader.Cb(16)));if(0<c.version){d=c.reader.R();for(var e=0;e<d;e++){var f=qd(c.reader.Cb(16));b.h.push(f)}}}}).parse(a)}
565
+ function Rn(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=Jc(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=pd(c.value),g.set(c,k),k+=c.length;h.setUint32(k,e);g.set(a,k+4);return g};function Sn(a,b){var c=Tn(a,b);return 1!=c.length?null:c[0]}function Un(a,b,c){a=Vn(a,b,c);return 1!=a.length?null:a[0]}function Tn(a,b){for(var c=[],d=t(a.childNodes),e=d.next();!e.done;e=d.next())e=e.value,e instanceof Element&&e.tagName==b&&c.push(e);return c}function Wn(a){return Array.from(a.childNodes).filter(function(b){return b instanceof Element})}
566
+ function Vn(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 Xn(a,b,c){return a.hasAttributeNS(b,c)?a.getAttributeNS(b,c):null}function Yn(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 Zn(a){return Array.from(a.childNodes).every($n)?a.textContent.trim():null}
567
+ function $n(a){return a.nodeType==Node.TEXT_NODE||a.nodeType==Node.CDATA_SECTION_NODE}function ao(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 bo(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}
568
+ function co(a){if(!a)return null;a=RegExp("^P(?:([0-9]*)Y)?(?:([0-9]*)M)?(?:([0-9]*)D)?(?:T(?:([0-9]*)H)?(?:([0-9]*)M)?(?:([0-9.]*)S)?)?$").exec(a);if(!a)return null;a=31536E3*Number(a[1]||null)+2592E3*Number(a[2]||null)+86400*Number(a[3]||null)+3600*Number(a[4]||null)+60*Number(a[5]||null)+Number(a[6]||null);return isFinite(a)?a:null}
569
+ function eo(a){var b=/([0-9]+)-([0-9]+)/.exec(a);if(!b)return null;a=Number(b[1]);if(!isFinite(a))return null;b=Number(b[2]);return isFinite(b)?{start:a,end:b}:null}function fo(a){a=Number(a);return 0===a%1?a:null}function go(a){a=Number(a);return 0===a%1&&0<a?a:null}function ho(a){a=Number(a);return 0===a%1&&0<=a?a:null}function io(a){a=Number(a);return isNaN(a)?null:a}function jo(a){var b;var c=(b=a.match(/^(\d+)\/(\d+)$/))?Number(b[1])/Number(b[2]):Number(a);return isNaN(c)?null:c}
570
+ function ko(a,b){var c=new DOMParser,d=null;try{d=c.parseFromString(a,"text/xml")}catch(e){return null}c=d.documentElement;return!c||c.getElementsByTagName("parsererror").length||d.documentElement.tagName!=b?null:c}function lo(a,b){try{var c=ed(a);return ko(c,b)}catch(d){return null}};function mo(a,b,c){var d=no(a),e=null;a=[];var f=[],g=new Set(d.map(function(h){return h.keyId}));g["delete"](null);if(1<g.size)throw new O(2,4,4010);b||(f=d.filter(function(h){return"urn:mpeg:dash:mp4protection:2011"==h.xe?(e=h.init||e,!1):!0}),f.length&&(a=oo(e,f,c,g),0==a.length&&(a=[Eb("",e)])));if(d.length&&(b||!f.length))for(a=[],b=t(Object.values(c)),c=b.next();!c.done;c=b.next())c=c.value,"org.w3.clearkey"!=c&&a.push(Eb(c,e));if(g=Array.from(g)[0]||null)for(b=t(a),c=b.next();!c.done;c=b.next())for(c=
571
+ t(c.value.initData),d=c.next();!d.done;d=c.next())d.value.keyId=g;return{jf:g,Wi:e,drmInfos:a,nf:!0}}function po(a,b,c,d){var e=mo(a,c,d);if(b.nf){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.nf=!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 O(2,4,4008);return e.jf||b.jf}
572
+ function qo(a){var b=0,c=Jc(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=Gc(c,a,e);b.push({type:d,value:f});a+=e}c=b}return c}
573
+ function ro(a){a=t(a.getElementsByTagName("DATA"));for(var b=a.next();!b.done;b=a.next()){b=t(b.value.childNodes);for(var c=b.next();!c.done;c=b.next())if(c=c.value,c instanceof Element&&"LA_URL"==c.tagName)return c.textContent}return""}function so(a){a=Un(a.node,"urn:microsoft:playready","pro");if(!a)return"";a=od(a.textContent);a=qo(a).filter(function(b){return b.type===to})[0];if(!a)return"";a=gd(a.value,!0);return(a=ko(a,"WRMHEADER"))?ro(a):""}
574
+ function oo(a,b,c,d){var e=[];b=t(b);for(var f=b.next();!f.done;f=b.next()){f=f.value;var g=c[f.xe];if(g){var h;if(h=Un(f.node,"urn:microsoft:playready","pro")){h=od(h.textContent);var k=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);h=[{initData:Rn(h,k,new Set,0),initDataType:"cenc",keyId:f.keyId}]}else h=null;k=null;if("urn:uuid:e2719d58-a985-b3c9-781a-b030af78d30e"===f.xe)if(k=d,0==k.size)k=null;else{var l=new Uint8Array([16,119,239,236,192,178,77,2,172,227,60,30,82,
575
+ 226,251,75]),m=new Uint8Array([]);k=[{initData:Rn(m,l,k,1),initDataType:"cenc",keyId:f.keyId}]}h=Eb(g,f.init||a||h||k);if(g=uo.get(g))h.licenseServerUri=g(f);e.push(h)}}return e}function no(a){var b=[];a=t(a);for(var c=a.next();!c.done;c=a.next())(c=vo(c.value))&&b.push(c);return b}
576
+ function vo(a){var b=a.getAttribute("schemeIdUri"),c=Xn(a,"urn:mpeg:cenc:2013","default_KID"),d=Vn(a,"urn:mpeg:cenc:2013","pssh").map(Zn);if(!b)return null;b=b.toLowerCase();if(c&&(c=c.replace(/-/g,"").toLowerCase(),c.includes(" ")))throw new O(2,4,4009);var e=[];try{e=d.map(function(f){return{initDataType:"cenc",initData:od(f),keyId:null}})}catch(f){throw new O(2,4,4007);}return{node:a,xe:b,keyId:c,init:0<e.length?e:null}}
577
+ var to=1,uo=(new Map).set("com.widevine.alpha",function(a){return(a=Un(a.node,"urn:microsoft","laurl"))?a.getAttribute("licenseUrl")||"":""}).set("com.microsoft.playready",so).set("com.microsoft.playready.recommendation",so).set("com.microsoft.playready.software",so).set("com.microsoft.playready.hardware",so).set("org.w3.clearkey",function(a){return(a=Un(a.node,"http://dashif.org/guidelines/clearKey","Laurl"))&&"EME-1.0"===a.getAttribute("Lic_type")&&a.textContent?a.textContent:""});function wo(a,b,c,d,e){var f={RepresentationID:b,Number:c,Bandwidth:d,Time:e};return a.replace(/\$(RepresentationID|Number|Bandwidth|Time)?(?:%0([0-9]+)([diouxX]))?\$/g,function(g,h,k,l){if("$$"==g)return"$";var m=f[h];if(null==m)return g;"RepresentationID"==h&&k&&(k=void 0);"Time"==h&&(m=Math.round(m));switch(l){case void 0:case "d":case "i":case "u":g=m.toString();break;case "o":g=m.toString(8);break;case "x":g=m.toString(16);break;case "X":g=m.toString(16).toUpperCase();break;default:g=m.toString()}k=
576
578
  window.parseInt(k,10)||1;return Array(Math.max(0,k-g.length)+1).join("0")+g})}
577
- function uo(a,b){var c=vo(a,b,"timescale"),d=1;c&&(d=co(c)||1);var e=vo(a,b,"duration");c=co(e||"");"image"==a.L.contentType&&(c=fo(e||""));c&&(c/=d);var f=vo(a,b,"startNumber");e=Number(vo(a,b,"presentationTimeOffset"))||0;var g=eo(f||"");if(null==f||null==g)g=1;var h=wo(a,b,"SegmentTimeline");f=null;if(h){f=d;var k=a.Z.duration||Infinity;h=Qn(h,"S");for(var l=[],m=-e,n=0;n<h.length;++n){var p=h[n],r=h[n+1],x=Yn(p,"t",eo),y=Yn(p,"d",eo);p=Yn(p,"r",bo);null!=x&&(x-=e);if(!y)break;x=null!=x?x:m;p=
578
- p||0;if(0>p)if(r){r=Yn(r,"t",eo);if(null==r)break;else if(x>=r)break;p=Math.ceil((r-x)/y)-1}else{if(Infinity==k)break;else if(x/f>=k)break;p=Math.ceil((k*f-x)/y)-1}0<l.length&&x!=m&&(l[l.length-1].end=x/f);for(r=0;r<=p;++r)m=x+y,l.push({start:x/f,end:m/f,qh:x}),x=m}f=l}return{timescale:d,wa:c,mc:g,rb:e/d||0,Qe:e,timeline:f}}function vo(a,b,c){return[b(a.L),b(a.Aa),b(a.ra)].filter(Cb).map(function(d){return d.getAttribute(c)}).reduce(function(d,e){return d||e})}
579
- function wo(a,b,c){return[b(a.L),b(a.Aa),b(a.ra)].filter(Cb).map(function(d){return Pn(d,c)}).reduce(function(d,e){return d||e})}
580
- function xo(a,b,c,d,e,f){for(var g=Un(a,"http://www.w3.org/1999/xlink","href"),h=Un(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 We(new O(2,4,4028));if("onLoad"!=h)return We(new O(2,4,4027));var m=Db([d],[g]);return e.request(0,kf(m,b)).na(function(n){n=io(n.data,a.tagName);if(!n)return We(new O(2,4,4001,g));
581
- for(;a.childNodes.length;)a.removeChild(a.childNodes[0]);for(;n.childNodes.length;){var p=n.childNodes[0];n.removeChild(p);a.appendChild(p)}n=t(Array.from(n.attributes));for(p=n.next();!p.done;p=n.next())a.setAttributeNode(p.value.cloneNode(!1));return yo(a,b,c,m[0],e,f+1)})}
582
- function yo(a,b,c,d,e,f){f=void 0===f?0:f;if(Un(a,"http://www.w3.org/1999/xlink","href")){var g=xo(a,b,c,d,e,f);c&&(g=g.na(void 0,function(){return yo(a,b,c,d,e,f)}));return g}g=[];for(var h=t(Array.from(a.childNodes)),k=h.next();!k.done;k=h.next())k=k.value,k instanceof Element&&("urn:mpeg:dash:resolve-to-zero:2013"==Un(k,"http://www.w3.org/1999/xlink","href")?a.removeChild(k):"SegmentTimeline"!=k.tagName&&g.push(yo(k,b,c,d,e,f)));return $e(g).na(function(){return a})};function zo(a,b,c,d,e,f,g){var h,k=(new xg).Y("sidx",function(l){h=Ao(b,d,e,f,g,c,l)});a&&k.parse(a);if(h)return h;throw new O(2,3,3004);}
583
- function Ao(a,b,c,d,e,f,g){var h=[];g.reader.skip(4);var k=g.reader.R();if(0==k)throw new O(2,3,3005);if(0==g.version){var l=g.reader.R();var m=g.reader.R()}else l=g.reader.lc(),m=g.reader.lc();g.reader.skip(2);var n=g.reader.qe();a=a+g.size+m;for(m=0;m<n;m++){var p=g.reader.R(),r=(p&2147483648)>>>31;p&=2147483647;var x=g.reader.R();g.reader.skip(4);if(1==r)throw new O(2,3,3006);h.push(new yi(l/k+c,(l+x)/k+c,function(){return f},a,a+p-1,b,c,d,e));l+=x;a+=p}g.parser.stop();return h};function Bo(a){this.h=Jc(a);this.g=new ug(this.h,0)}Bo.prototype.Da=function(){return this.g.Da()};
584
- function Co(a){var b=Do(a);if(7<b.length)throw new O(2,3,3002);var c=0;b=t(b);for(var d=b.next();!d.done;d=b.next())c=256*c+d.value;b=Do(a);a:{d=t(Eo);for(var e=d.next();!e.done;e=d.next())if(Ec(b,new Uint8Array(e.value))){d=!0;break a}d=!1}if(d)b=a.h.byteLength-a.g.oa();else{if(8==b.length&&b[1]&224)throw new O(2,3,3001);for(e=d=0;e<b.length;e++){var f=b[e];d=0==e?f&(1<<8-b.length)-1:256*d+f}b=d}b=a.g.oa()+b<=a.h.byteLength?b:a.h.byteLength-a.g.oa();d=Jc(a.h,a.g.oa(),b);a.g.skip(b);return new Fo(c,
585
- d)}function Do(a){var b=a.g.oa(),c=a.g.qb();if(0==c)throw new O(2,3,3002);c=8-Math.floor(Math.log2(c));a.g.skip(c-1);return Gc(a.h,b,c)}var Eo=[[255],[127,255],[63,255,255],[31,255,255,255],[15,255,255,255,255],[7,255,255,255,255,255],[3,255,255,255,255,255,255],[1,255,255,255,255,255,255,255]];function Fo(a,b){this.id=a;this.g=b}
586
- function Go(a){if(8<a.g.byteLength)throw new O(2,3,3002);if(8==a.g.byteLength&&a.g.getUint8(0)&224)throw new O(2,3,3001);for(var b=0,c=0;c<a.g.byteLength;c++){var d=a.g.getUint8(c);b=256*b+d}return b};function Ho(a,b,c,d,e,f,g,h,k){function l(){return e}var m=[];a=new Bo(a.g);for(var n=null,p=null;a.Da();){var r=Co(a);if(187==r.id){var x=Io(r);x&&(r=c*x.rh,x=b+x.$g,null!=n&&m.push(new yi(n+g,r+g,l,p,x-1,f,g,h,k)),n=r,p=x)}}null!=n&&m.push(new yi(n+g,d+g,l,p,null,f,g,h,k));return m}
587
- function Io(a){var b=new Bo(a.g);a=Co(b);if(179!=a.id)throw new O(2,3,3013);a=Go(a);b=Co(b);if(183!=b.id)throw new O(2,3,3012);b=new Bo(b.g);for(var c=0;b.Da();){var d=Co(b);if(241==d.id){c=Go(d);break}}return{rh:a,$g:c}};function Jo(a,b){var c=wo(a,b,"Initialization");if(!c)return null;var d=a.L.Na,e=c.getAttribute("sourceURL");e&&(d=Db(a.L.Na,[e]));e=0;var f=null;if(c=Yn(c,"range",ao))e=c.start,f=c.end;return new wi(function(){return d},e,f,Ko(a))}
588
- function Lo(a,b){var c=Number(vo(a,Mo,"presentationTimeOffset"))||0,d=vo(a,Mo,"timescale"),e=1;d&&(e=co(d)||1);var f=c/e||0,g=Jo(a,Mo);Oo(a,g);var h=cf(a);return{$b:function(){var k=wo(h,Mo,"RepresentationIndex"),l=h.L.Na;k&&(k=k.getAttribute("sourceURL"))&&(l=Db(h.L.Na,[k]));k=Po(h);return Qo(h,b,g,l,k.start,k.end,f)}}}
589
- function Qo(a,b,c,d,e,f,g){var h,k,l,m,n,p,r,x,y,w,v,D,C,B,G;return I(function(E){if(1==E.g)return h=a.presentationTimeline,k=!a.xb||!a.Z.xf,l=a.Z.start,m=a.Z.duration,n=a.L.mimeType.split("/")[1],p=b,r=null,x=[p(d,e,f),"webm"==n?p(c.Pa(),c.Ta,c.Ca):null],p=null,u(E,Promise.all(x),2);y=E.h;w=y[0];v=y[1]||null;D=null;C=l-g;B=l;G=m?l+m:Infinity;if("mp4"==n)var H=zo(w,e,d,c,C,B,G);else{H=new Bo(v);if(440786851!=Co(H).id)throw new O(2,3,3008);var L=Co(H);if(408125543!=L.id)throw new O(2,3,3009);H=L.g.byteOffset;
590
- L=new Bo(L.g);for(var K=null;L.Da();){var N=Co(L);if(357149030==N.id){K=N;break}}if(!K)throw new O(2,3,3010);K=new Bo(K.g);N=1E6;for(L=null;K.Da();){var V=Co(K);if(2807729==V.id)N=Go(V);else if(17545==V.id)if(4==V.g.byteLength)L=V.g.getFloat32(0);else if(8==V.g.byteLength)L=V.g.getFloat64(0);else throw new O(2,3,3003);}if(null==L)throw new O(2,3,3011);K=N/1E9;L*=K;N=Co(new Bo(w));if(475249515!=N.id)throw new O(2,3,3007);H=Ho(N,H,K,L,d,c,C,B,G)}D=H;h.ic(D);r=new Xi(D);k&&r.yb(B,G,!0);return E["return"](r)})}
591
- function Mo(a){return a.Sc}function Po(a){var b=wo(a,Mo,"RepresentationIndex");a=vo(a,Mo,"indexRange");a=ao(a||"");b&&(a=Yn(b,"range",ao,a));return a}function Oo(a,b){Ro(a,b);if(!Po(a))throw new O(2,4,4002);}function Ro(a,b){var c=a.L.mimeType.split("/")[1];if(a.L.contentType!=Ib&&"mp4"!=c&&"webm"!=c)throw new O(2,4,4006);if("webm"==c&&!b)throw new O(2,4,4005);}
592
- function Ko(a){var b=a.L;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.td,pixelAspectRatio:b.pixelAspectRatio||null,width:b.width||null}};function So(a,b){var c=Jo(a,To),d=Uo(a);if(!d.wa&&!d.timeline&&1<d.fc.length)throw new O(2,4,4002);if(!d.wa&&!a.Z.duration&&!d.timeline&&1==d.fc.length)throw new O(2,4,4002);if(d.timeline&&0==d.timeline.length)throw new O(2,4,4002);var e=null,f=null;a.ra.id&&a.L.id&&(f=b[a.ra.id+","+a.L.id])&&(e=f.segmentIndex);var g=Vo(a.Z.start,a.Z.duration,a.L.Na,d,c);c=!e;e?e.hc(g,a.presentationTimeline.ob()):e=new Xi(g);a.presentationTimeline.ic(g);a.xb&&a.Z.xf||e.yb(a.Z.start,a.Z.duration?a.Z.start+a.Z.duration:
593
- Infinity,c);f&&(f.segmentIndex=e);return{$b:function(){e&&0!=e.M.length||e.Mc(g);return Promise.resolve(e)}}}function To(a){return a.Db}function Uo(a){var b=Wo(a);a=uo(a,To);var c=a.mc;0==c&&(c=1);var d=0;a.wa?d=a.wa*(c-1):a.timeline&&0<a.timeline.length&&(d=a.timeline[0].start);return{wa:a.wa,startTime:d,mc:c,rb:a.rb,timeline:a.timeline,fc:b}}
594
- function Vo(a,b,c,d,e){var f=d.fc.length;d.timeline&&d.timeline.length!=d.fc.length&&(f=Math.min(d.timeline.length,d.fc.length));for(var g=a-d.rb,h=b?a+b:Infinity,k=[],l=d.startTime,m={},n=0;n<f;m={Od:m.Od},n++){var p=d.fc[n];m.Od=Db(c,[p.Rg]);var r=void 0;r=null!=d.wa?l+d.wa:d.timeline?d.timeline[n].end:l+b;k.push(new yi(a+l,a+r,function(x){return function(){return x.Od}}(m),p.start,p.end,e,g,a,h));l=r}return k}
595
- function Wo(a){return[a.L.Db,a.Aa.Db,a.ra.Db].filter(Cb).map(function(b){return Qn(b,"SegmentURL")}).reduce(function(b,c){return 0<b.length?b:c}).map(function(b){b.getAttribute("indexRange")&&!a.vf&&(a.vf=!0);var c=b.getAttribute("media");b=Yn(b,"mediaRange",ao,{start:0,end:null});return{Rg:c,start:b.start,end:b.end}})};function Xo(a,b,c,d,e,f){var g=Yo(a),h=Zo(a);$o(h);var k=cf(a);if(h.Jc)return Ro(a,g),{$b:function(){var r=to(h.Jc,k.L.id,null,k.bandwidth||null,null);r=Db(k.L.Na,[r]);return Qo(k,b,g,r,0,null,h.rb)}};if(h.wa)return d||(a.presentationTimeline.ke(h.wa),a.presentationTimeline.le(a.Z.start)),{$b:function(){return ap(k,h,e,g,f)}};var l=null;d=d=null;a.ra.id&&a.L.id&&(d=a.ra.id+","+a.L.id,d=c[d])&&(l=d.segmentIndex);var m=bp(k,h,g);c=a.Z.start;var n=a.Z.duration?a.Z.start+a.Z.duration:Infinity,p=Infinity!=
596
- n;l?(p&&(new Xi(m)).yb(c,n,!0),l.hc(m,a.presentationTimeline.ob())):l=new Xi(m);a.presentationTimeline.ic(m);p&&l.yb(c,n);d&&a.xb&&(d.segmentIndex=l);return{$b:function(){l&&0!=l.M.length||l.Mc(m);return Promise.resolve(l)}}}function cp(a){return a.Tc}function Zo(a){var b=uo(a,cp),c=vo(a,cp,"media");a=vo(a,cp,"index");return{wa:b.wa,timescale:b.timescale,mc:b.mc,rb:b.rb,Qe:b.Qe,timeline:b.timeline,je:c,Jc:a}}
597
- function $o(a){var b=a.Jc?1:0;b+=a.timeline?1:0;b+=a.wa?1:0;if(0==b)throw new O(2,4,4002);1!=b&&(a.Jc&&(a.timeline=null),a.wa=null);if(!a.Jc&&!a.je)throw new O(2,4,4002);}
598
- function ap(a,b,c,d,e){function f(K){var N=(K-r)*p,V=N+b.rb,Z=N+l;N=Z+p;var ha=Math.min(N,h());Z=new yi(Z,ha,function(){var ja=to(y,v,K,w,V*x);return Db(D,[ja])},0,null,d,C,l,h());Z.j=N;return Z}function g(){var K=[Math.max(k.ob(),l),Math.min(k.Ib(),h())].map(function(N){return N-l});return[Math.ceil(K[0]/p),Math.ceil(K[1]/p)-1].map(function(N){return N+r})}function h(){var K=null!=m&&e[m]||n;return K?l+K:Infinity}var k=a.presentationTimeline,l=a.Z.start,m=a.ra.id,n=a.Z.duration,p=b.wa,r=b.mc,x=b.timescale,
599
- y=b.je,w=a.bandwidth||null,v=a.L.id,D=a.L.Na,C=l-b.rb,B=g();a=a.xb?Math.max(B[0],B[1]-c+1):B[0];B=B[1];c=[];for(var G=a;G<=B;++G){var E=f(G);c.push(E)}var H=new Xi(c);c=k.Ib()<h();G=k.U();if(c||G){var L=Math.max(a,B+1);H.Fd(p,function(){var K=k.ob();H.Gb(K);var N=t(g());N.next();N=N.next().value;for(var V=[];L<=N;){var Z=f(L);V.push(Z);L++}return K>h()&&!V.length?null:V})}return Promise.resolve(H)}
600
- function bp(a,b,c){var d=a.Z.start,e=a.Z.duration,f=d-b.rb;e=e?d+e:Infinity;for(var g=[],h={},k=0;k<b.timeline.length;h={Nd:h.Nd,Rd:h.Rd,Ud:h.Ud,Kd:h.Kd,Wd:h.Wd,Ld:h.Ld},k++){var l=b.timeline[k],m=l.start,n=l.qh;l=l.end;h.Ud=k+b.mc;h.Wd=n+b.Qe;h.Rd=a.L.id;h.Kd=a.bandwidth||null;h.Nd=b.je;h.Ld=a.L.Na;g.push(new yi(d+m,d+l,function(p){return function(){var r=to(p.Nd,p.Rd,p.Ud,p.Kd||null,p.Wd);return Db(p.Ld,[r]).map(function(x){return x.toString()})}}(h),0,null,c,f,d,e))}return g}
601
- function Yo(a){var b=vo(a,cp,"initialization");if(!b)return null;var c=a.L.id,d=a.bandwidth||null,e=a.L.Na;return new wi(function(){var f=to(b,c,null,d,null);return Db(e,[f])},0,null,Ko(a))};function dp(){this.l=[];this.g=[];this.h=[];this.j=[];this.i=[];this.m=new Set}dp.prototype.release=function(){for(var a=t(this.g.concat(this.h,this.j,this.i)),b=a.next();!b.done;b=a.next())b=b.value,b.segmentIndex&&b.segmentIndex.release();this.g=[];this.h=[];this.j=[];this.i=[];this.l=[]};
602
- function ep(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,x,y,w,v,D,C,B,G,E,H,L,K,N,V,Z,ha,ja,xa,La;return I(function(Fa){switch(Fa.g){case 1:d=Jb;fp(b);gp(b);hp(b);ip(b);if(!c&&1==b.length){e=b[0];a.g=e.dd;a.h=e.Hd;a.j=e.textStreams;a.i=e.imageStreams;Fa.D(2);break}f=-1;for(g=0;g<b.length;g++)h=b[g],a.m.has(h.id)||(a.m.add(h.id),-1==f&&(f=g));if(-1==f)return Fa["return"]();k=b.map(function(Ra){return Ra.dd});l=b.map(function(Ra){return Ra.Hd});m=b.map(function(Ra){return Ra.textStreams});n=b.map(function(Ra){return Ra.imageStreams});
603
- p=t(m);for(r=p.next();!r.done;r=p.next())x=r.value,x.push(jp(d.ha));y=t(n);for(w=y.next();!w.done;w=y.next())v=w.value,v.push(jp(d.xc));return u(Fa,kp(a.g,k,f,lp,mp),3);case 3:return u(Fa,kp(a.h,l,f,lp,mp),4);case 4:return u(Fa,kp(a.j,m,f,lp,mp),5);case 5:return u(Fa,kp(a.i,n,f,lp,mp),2);case 2:D=0;C=[];if(a.h.length&&a.g.length)for(K=t(a.g),N=K.next();!N.done;N=K.next())for(V=N.value,Z=t(a.h),ha=Z.next();!ha.done;ha=Z.next())ja=ha.value,xa=mg(V.drmInfos,ja.drmInfos),V.drmInfos.length&&ja.drmInfos.length&&
604
- !xa.length||(La=D++,C.push({id:La,language:V.language,primary:V.primary,audio:V,video:ja,bandwidth:(V.bandwidth||0)+(ja.bandwidth||0),drmInfos:xa,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]}));else for(B=a.h.concat(a.g),G=t(B),E=G.next();!E.done;E=G.next())H=E.value,L=D++,C.push({id:L,language:H.language,primary:H.primary,audio:H.type==d.Fb?H:null,video:H.type==d.Ma?H:null,bandwidth:H.bandwidth||0,drmInfos:H.drmInfos,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});
605
- a.l=C;z(Fa)}})}function fp(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;for(var c=[],d=t(b.dd),e=d.next();!e.done;e=d.next()){e=e.value;for(var f=!1,g=t(c),h=g.next();!h.done;h=g.next())h=h.value,e.id!=h.id&&e.channelsCount==h.channelsCount&&e.language==h.language&&e.bandwidth==h.bandwidth&&e.label==h.label&&e.codecs==h.codecs&&e.mimeType==h.mimeType&&ec(e.roles,h.roles)&&e.audioSamplingRate==h.audioSamplingRate&&e.primary==h.primary&&(f=!0);f||c.push(e)}b.dd=c}}
606
- function hp(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;for(var c=[],d=t(b.textStreams),e=d.next();!e.done;e=d.next()){e=e.value;for(var f=!1,g=t(c),h=g.next();!h.done;h=g.next())h=h.value,e.id!=h.id&&e.language==h.language&&e.label==h.label&&e.codecs==h.codecs&&e.mimeType==h.mimeType&&e.bandwidth==h.bandwidth&&ec(e.roles,h.roles)&&(f=!0);f||c.push(e)}b.textStreams=c}}
607
- function gp(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;for(var c=[],d=t(b.Hd),e=d.next();!e.done;e=d.next()){e=e.value;for(var f=!1,g=t(c),h=g.next();!h.done;h=g.next())h=h.value,e.id!=h.id&&e.width==h.width&&e.frameRate==h.frameRate&&e.codecs==h.codecs&&e.mimeType==h.mimeType&&e.label==h.label&&ec(e.roles,h.roles)&&Af(e.closedCaptions,h.closedCaptions)&&e.bandwidth==h.bandwidth&&(f=!0);f||c.push(e)}b.Hd=c}}
608
- function ip(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;for(var c=[],d=t(b.imageStreams),e=d.next();!e.done;e=d.next()){e=e.value;for(var f=!1,g=t(c),h=g.next();!h.done;h=g.next())h=h.value,e.id!=h.id&&e.width==h.width&&e.codecs==h.codecs&&e.mimeType==h.mimeType&&(f=!0);f||c.push(e)}b.imageStreams=c}}
609
- function np(a){var b,c,d,e,f,g,h,k,l,m,n,p,r,x,y,w,v,D,C,B,G,E,H,L,K,N,V;return I(function(Z){switch(Z.g){case 1:b=Jb;if(1==a.length)return Z["return"](a[0]);c=a.map(function(ha){return ha.filter(function(ja){return ja.type==b.Fb})});d=a.map(function(ha){return ha.filter(function(ja){return ja.type==b.Ma})});e=a.map(function(ha){return ha.filter(function(ja){return ja.type==b.ha})});f=a.map(function(ha){return ha.filter(function(ja){return ja.type==b.xc})});g=t(e);for(h=g.next();!h.done;h=g.next())k=
610
- h.value,k.push(op(b.ha));l=t(f);for(m=l.next();!m.done;m=l.next())n=m.value,n.push(op(b.xc));return u(Z,kp([],c,0,pp,qp),2);case 2:return p=Z.h,u(Z,kp([],d,0,pp,qp),3);case 3:return r=Z.h,u(Z,kp([],e,0,pp,qp),4);case 4:return x=Z.h,u(Z,kp([],f,0,pp,qp),5);case 5:y=Z.h;w=0;if(r.length&&p.length)for(G=t(p),E=G.next();!E.done;E=G.next())for(H=E.value,L=t(r),K=L.next();!K.done;K=L.next())N=K.value,V=w++,N.variantIds.push(V),H.variantIds.push(V);else for(v=r.concat(p),D=t(v),C=D.next();!C.done;C=D.next())B=
611
- C.value,B.variantIds=[w++];return Z["return"](r.concat(p).concat(x).concat(y))}})}
612
- function kp(a,b,c,d,e){var f,g,h,k,l,m,n,p,r,x,y,w,v,D,C,B,G,E,H,L,K;return I(function(N){switch(N.g){case 1:f=Jb;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){N.D(4);break}m=l.value;return u(N,rp(m,b,c,e,g),5);case 5:n=N.h;if(!n)throw new O(2,4,4037);l=k.next();N.D(2);break;case 4:p=t(g);for(r=p.next();!r.done;r=p.next())for(x=r.value,y=t(x),w=y.next();!w.done;w=y.next())v=w.value,(D=sp(v,b,d,e,g))&&a.push(D);C=t(g);for(r=C.next();!r.done;r=
613
- C.next())for(B=r.value,G={},E=t(B),w=E.next();!w.done;G={vb:G.vb},w=E.next())if(G.vb=w.value,H=G.vb.type==f.ha&&!G.vb.language,L=G.vb.type==f.xc&&!G.vb.tilesLayout,!H&&!L&&(K=a.some(function(V){return function(Z){return Z.mimeType==V.vb.mimeType&&ld(Z.codecs)==ld(V.vb.codecs)}}(G))))throw new O(2,4,4037);return N["return"](a)}})}
614
- function rp(a,b,c,d,e){return I(function(f){if(1==f.g)return tp(b,a),a.matchedStreams?a.segmentIndex?u(f,up(a,c),2):f.D(2):f["return"](!1);vp(a,c,d,e);return f["return"](!0)})}
615
- function up(a,b){var c,d,e,f,g,h,k;return I(function(l){if(1==l.g){c=[];d=a.matchedStreams;e=t(d);for(f=e.next();!f.done;f=e.next())g=f.value,c.push(g.createSegmentIndex()),g.trickModeVideo&&!g.trickModeVideo.segmentIndex&&c.push(g.trickModeVideo.createSegmentIndex());return u(l,Promise.all(c),2)}if(a.segmentIndex instanceof $i)for(h=0;h<d.length;h++)k=d[h],k.segmentIndex&&h>=b&&a.segmentIndex.j.push(k.segmentIndex);z(l)})}
616
- function sp(a,b,c,d,e){var f=c(a);tp(b,f);f.createSegmentIndex&&(f.createSegmentIndex=function(){return I(function(g){if(f.segmentIndex)return g.D(0);f.segmentIndex=new $i;return u(g,up(f,0),0)})});if(!f.matchedStreams)return null;vp(f,0,d,e);return f}function vp(a,b,c,d){for(var e=a.matchedStreams,f=0;f<e.length;f++)if(f>=b){var g=e[f];c(a,g);var h=!0;"audio"==a.type&&0==Sb(a.language,g.language)&&(h=!1);h&&d[f]["delete"](g)}}
617
- function lp(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}
618
- function pp(a){a=Object.assign({},a);a.keyIds=new Set;a.segments=[];a.variantIds=[];a.closedCaptions=null;return a}
619
- function mp(a,b){a.roles=Array.from(new Set(a.roles.concat(b.roles)));b.emsgSchemeIdUris&&(a.emsgSchemeIdUris=Array.from(new Set(a.emsgSchemeIdUris.concat(b.emsgSchemeIdUris))));a.keyIds=function(f,g){return new Set([].concat(ia(f),ia(g)))}(a.keyIds,b.keyIds);null==a.originalId?a.originalId=b.originalId:a.originalId+=","+(b.originalId||"");var c=mg(a.drmInfos,b.drmInfos);if(b.drmInfos.length&&a.drmInfos.length&&!c.length)throw new O(2,4,4038);a.drmInfos=c;a.encrypted=a.encrypted||b.encrypted;if(b.closedCaptions){a.closedCaptions||
620
- (a.closedCaptions=new Map);c=t(b.closedCaptions);for(var d=c.next();!d.done;d=c.next()){var e=t(d.value);d=e.next().value;e=e.next().value;a.closedCaptions.set(d,e)}}b.trickModeVideo?(a.trickModeVideo||(a.trickModeVideo=lp(b.trickModeVideo),a.trickModeVideo.createSegmentIndex=function(){a.trickModeVideo.segmentIndex=a.segmentIndex.clone();return Promise.resolve()}),mp(a.trickModeVideo,b.trickModeVideo)):a.trickModeVideo&&mp(a.trickModeVideo,b)}
621
- function qp(a,b){a.roles=Array.from(new Set(a.roles.concat(b.roles)));var c=b.keyIds;c=new Set([].concat(ia(a.keyIds),ia(c)));a.keyIds=c;a.encrypted=a.encrypted&&b.encrypted;a.segments.push.apply(a.segments,ia(b.segments));if(b.closedCaptions){a.closedCaptions||(a.closedCaptions=new Map);c=t(b.closedCaptions);for(var d=c.next();!d.done;d=c.next()){var e=t(d.value);d=e.next().value;e=e.next().value;a.closedCaptions.set(d,e)}}}
622
- function tp(a,b){for(var c=[],d=t(a),e=d.next();!e.done;e=d.next()){var f=b,g={audio:wp,video:wp,text:xp,image:yp}[f.type],h={audio:zp,video:Ap,text:Bp,image:Cp}[f.type],k=null;e=t(e.value);for(var l=e.next();!l.done;l=e.next())l=l.value,!g(f,l)||k&&!h(f,k,l)||(k=l);f=k;if(!f)return;c.push(f)}b.matchedStreams=c}function wp(a,b){var c;if(!(c=b.mimeType!=a.mimeType||ld(b.codecs)!=ld(a.codecs))&&(c=a.drmInfos)){c=a.drmInfos;var d=b.drmInfos;c=!(c.length&&d.length?0<mg(c,d).length:1)}return c?!1:!0}
623
- function xp(a,b){return a.language?b.language?0==Sb(a.language,b.language)||b.kind!=a.kind?!1:!0:!0:!1}function yp(a){return a.tilesLayout?!0:!1}
624
- function zp(a,b,c){if(a.id==c.id)return!0;var d=Sb(a.language,b.language),e=Sb(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)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;
625
- d=Dp(a.channelsCount,b.channelsCount,c.channelsCount);if(d==Ep)return!0;if(d==Fp)return!1;d=Dp(a.audioSamplingRate,b.audioSamplingRate,c.audioSamplingRate);return d==Ep?!0:d==Fp?!1:a.bandwidth&&Gp(a.bandwidth,b.bandwidth,c.bandwidth)==Ep?!0:!1}
626
- function Ap(a,b,c){if(a.id==c.id)return!0;var d=Dp(a.width*a.height,b.width*b.height,c.width*c.height);if(d==Ep)return!0;if(d==Fp)return!1;if(a.frameRate){d=Dp(a.frameRate,b.frameRate,c.frameRate);if(d==Ep)return!0;if(d==Fp)return!1}return a.bandwidth&&Gp(a.bandwidth,b.bandwidth,c.bandwidth)==Ep?!0:!1}
627
- function Bp(a,b,c){if(a.id==c.id)return!0;var d=Sb(a.language,b.language),e=Sb(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!=
628
- a.mimeType||c.codecs!=a.codecs||b.mimeType==a.mimeType&&b.codecs==a.codecs?!1:!0}function Cp(a,b,c){return a.id==c.id?!0:Dp(a.width*a.height,b.width*b.height,c.width*c.height)==Ep?!0:!1}function op(a){return{id:0,originalId:"",primary:!1,type:a,mimeType:"",codecs:"",language:"",label:null,width:null,height:null,encrypted:!1,keyIds:new Set,segments:[],variantIds:[],roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null}}
629
- function jp(a){return{id:0,originalId:"",createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Xi([]),mimeType:"",codecs:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"",label:null,type:a,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null}}
630
- function Dp(a,b,c){if(b==a&&a!=c)return Fp;if(c==a&&a!=b)return Ep;if(b>a){if(c<=a||c-a<b-a)return Ep;if(c-a>b-a)return Fp}else{if(c>a)return Fp;if(a-c<a-b)return Ep;if(a-c>a-b)return Fp}return Hp}function Gp(a,b,c){b=Math.abs(a-b);a=Math.abs(a-c);return a<b?Ep:b<a?Fp:Hp}var Ep=1,Hp=0,Fp=-1;function Ip(){var a=this;this.h=this.g=null;this.m=[];this.i=null;this.I=1;this.l={};this.N={};this.j=new dp;this.H=0;this.J=new $b(5);this.G=new P(function(){Jp(a)});this.A=new df;this.B=null;this.K=[];this.C=Infinity;this.F=!1}q=Ip.prototype;q.configure=function(a){this.g=a};q.start=function(a,b){var c=this,d;return I(function(e){if(1==e.g)return c.F=b.isLowLatencyMode(),c.m=[a],c.h=b,u(e,Kp(c),2);d=e.h;c.h&&Lp(c,d);if(!c.h)throw new O(2,7,7001);return e["return"](c.i)})};
631
- q.stop=function(){for(var a=t(Object.values(this.l)),b=a.next();!b.done;b=a.next())b=b.value,b.segmentIndex&&b.segmentIndex.release();this.j&&this.j.release();this.g=this.h=null;this.m=[];this.i=null;this.l={};this.j=null;null!=this.G&&(this.G.stop(),this.G=null);return this.A.destroy()};q.update=function(){var a=this,b;return I(function(c){if(1==c.g)return A(c,2),u(c,Kp(a),4);if(2!=c.g)return va(c,0);b=F(c);if(!a.h||!b)return c["return"]();a.h.onError(b);z(c)})};q.onExpirationUpdated=function(){};
632
- function Kp(a){var b,c,d,e,f,g,h;return I(function(k){if(1==k.g)return b=kf(a.m,a.g.retryParameters),c=a.h.networkingEngine,a.h.modifyManifestRequest(b,{format:"d"}),d=Date.now(),e=c.request(0,b),ef(a.A,e),u(k,e.promise,2);if(3!=k.g){f=k.h;if(!a.h)return k["return"](0);f.uri&&!a.m.includes(f.uri)&&a.m.unshift(f.uri);return u(k,Mp(a,f.data,f.uri),3)}g=Date.now();h=(g-d)/1E3;a.J.sample(1,h);return k["return"](h)})}
633
- function Mp(a,b,c){var d,e,f,g,h;return I(function(k){if(1==k.g){d=io(b,"MPD");if(!d)throw new O(2,4,4001,c);if(e=a.g.dash.disableXlinkProcessing)return k["return"](Np(a,d,c));f=a.g.dash.xlinkFailGracefully;g=yo(d,a.g.retryParameters,f,c,a.h.networkingEngine);ef(a.A,g);return u(k,g.promise,2)}h=k.h;return k["return"](Np(a,h,c))})}
634
- function Np(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,x,y,w,v,D,C,B,G,E,H,L,K,N,V,Z,ha,ja,xa,La,Fa,Ra;return I(function(Ga){switch(Ga.g){case 1:(d=a.g.dash.manifestPreprocessor)&&d(b);e=[c];f=Qn(b,"Location").map(Wn).filter(Cb);0<f.length&&(g=Db(e,f),e=a.m=g);h=Qn(b,"BaseURL");k=h.map(Wn);l=Db(e,k);m=0;h&&h.length&&(m=Yn(h[0],"availabilityTimeOffset",fo)||0);n=a.g.dash.ignoreMinBufferTime;p=0;n||(p=Yn(b,"minBufferTime",$n)||0);a.H=Yn(b,"minimumUpdatePeriod",$n,-1);r=Yn(b,"availabilityStartTime",Zn);x=Yn(b,
635
- "timeShiftBufferDepth",$n);y=a.g.dash.ignoreSuggestedPresentationDelay;w=null;y||(w=Yn(b,"suggestedPresentationDelay",$n));v=a.g.dash.ignoreMaxSegmentDuration;D=null;v||(D=Yn(b,"maxSegmentDuration",$n));C=b.getAttribute("type")||"static";if(a.i)for(B=a.i.presentationTimeline,G=t(Object.values(a.l)),E=G.next();!E.done;E=G.next())H=E.value,H.segmentIndex&&H.segmentIndex.Gb(B.ob());else L=a.g.defaultPresentationDelay||1.5*p,K=null!=w?w:L,B=new Q(r,K,a.g.dash.autoCorrectDrift);B.Uc("static"==C);(N=B.U())&&
636
- !isNaN(a.g.availabilityWindowOverride)&&(x=a.g.availabilityWindowOverride);null==x&&(x=Infinity);B.Ge(x);V=b.getAttribute("profiles")||"";Z={xb:"static"!=C,presentationTimeline:B,ra:null,Z:null,Aa:null,L:null,bandwidth:0,vf:!1,Yb:m,profiles:V.split(",")};ha=Op(a,Z,l,b);ja=ha.duration;xa=ha.periods;"static"!=C&&ha.kf||B.bb(ja||Infinity);a.C&&!a.F&&(La=a.h.isAutoLowLatencyMode())&&(a.h.enableLowLatencyMode(),a.F=a.h.isLowLatencyMode());a.F?B.Ef(a.C):a.C&&Ua("Low-latency DASH live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details.");
637
- B.ke(D||1);return u(Ga,ep(a.j,xa,Z.xb),2);case 2:if(a.i){a.i.variants=a.j.l;a.i.textStreams=a.j.j.slice();a.i.imageStreams=a.j.i;a.h.filter(a.i);Ga.D(3);break}a.i={presentationTimeline:B,variants:a.j.l,textStreams:a.j.j.slice(),imageStreams:a.j.i,offlineSessionIds:[],minBufferTime:p||0,sequenceMode:!1};if(!B.Mf()){Ga.D(3);break}Fa=Qn(b,"UTCTiming");return u(Ga,Pp(a,l,Fa),5);case 5:Ra=Ga.h;if(!a.h)return Ga["return"]();B.Ff(Ra);case 3:a.h.makeTextStreamsForClosedCaptions(a.i),z(Ga)}})}
638
- function Op(a,b,c,d){var e=Yn(d,"mediaPresentationDuration",$n),f=[],g=0;d=Qn(d,"Period");for(var h=0;h<d.length;h++){var k=d[h],l=d[h+1],m=Yn(k,"start",$n,g),n=k.id,p=Yn(k,"duration",$n),r=null;if(l){var x=Yn(l,"start",$n);null!=x&&(r=x-m)}else null!=e&&(r=e-m);null==r&&(r=p);if(!(null!==a.B&&null!==n&&null!==m&&m<a.B)||a.K.includes(n)||h+1==d.length){null!==m&&(null===a.B||m>a.B)&&(a.B=m);g=Qp(a,b,c,{start:m,duration:r,node:k,xf:null==r||!l});f.push(g);b.ra.id&&r&&(a.N[b.ra.id]=r);if(null==r){g=
639
- null;break}g=m+r}}a.K=f.map(function(y){return y.id});return null!=e?{periods:f,duration:e,kf:!1}:{periods:f,duration:g,kf:!0}}
640
- function Qp(a,b,c,d){b.ra=Rp(d.node,null,c);b.Z=d;b.ra.Yb=b.Yb;b.ra.id||(b.ra.id="__shaka_period_"+d.start);var e=Qn(d.node,"EventStream");c=b.presentationTimeline.ob();e=t(e);for(var f=e.next();!f.done;f=e.next())Sp(a,d.start,d.duration,f.value,c);c=Qn(d.node,"AdaptationSet").map(function(m){return Tp(a,b,m)}).filter(Cb);if(b.xb){d=[];e=t(c);for(f=e.next();!f.done;f=e.next()){f=t(f.value.dh);for(var g=f.next();!g.done;g=f.next())d.push(g.value)}if(d.length!=(new Set(d)).size)throw new O(2,4,4018);
641
- }d=c.filter(function(m){return!m.Me});c=c.filter(function(m){return m.Me});c=t(c);for(e=c.next();!e.done;e=c.next()){e=e.value;f=e.Me.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={$c:h.$c},l=k.next())h.$c=l.value,h.$c.trickModeVideo=e.streams.find(function(m){return function(n){return ld(m.$c.codecs)==ld(n.codecs)}}(h))}}}e=a.g.disableAudio?[]:Up(d,"audio");g=a.g.disableVideo?[]:Up(d,"video");f=a.g.disableText?
642
- []:Up(d,Ib);c=a.g.disableThumbnails?[]:Up(d,"image");if(!g.length&&!e.length)throw new O(2,4,4004);d=[];e=t(e);for(h=e.next();!h.done;h=e.next())d.push.apply(d,ia(h.value.streams));e=[];g=t(g);for(h=g.next();!h.done;h=g.next())e.push.apply(e,ia(h.value.streams));g=[];f=t(f);for(h=f.next();!h.done;h=f.next())g.push.apply(g,ia(h.value.streams));f=[];c=t(c);for(h=c.next();!h.done;h=c.next())f.push.apply(f,ia(h.value.streams));return{id:b.ra.id,dd:d,Hd:e,textStreams:g,imageStreams:f}}
643
- function Up(a,b){return a.filter(function(c){return c.contentType==b})}
644
- function Tp(a,b,c){function d(E){switch(E){case 1:case 6:case 13:case 14:case 15:return"SDR";case 16:return"PQ";case 18:return"HLG"}}b.Aa=Rp(c,b.ra,null);var e=!1,f=Qn(c,"Role"),g=f.map(function(E){return E.getAttribute("value")}).filter(Cb),h=void 0,k=b.Aa.contentType==Ib;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=
645
- l}}var n;m=Qn(c,"EssentialProperty");f=null;l=!1;m=t(m);for(var p=m.next();!p.done;p=m.next()){p=p.value;var r=p.getAttribute("schemeIdUri");"http://dashif.org/guidelines/trickmode"==r?f=p.getAttribute("value"):"urn:mpeg:mpegB:cicp:TransferCharacteristics"==r?n=d(parseInt(p.getAttribute("value"),10)):l=!0}m=Qn(c,"SupplementalProperty");m=t(m);for(p=m.next();!p.done;p=m.next())p=p.value,"urn:mpeg:mpegB:cicp:TransferCharacteristics"==p.getAttribute("schemeIdUri")&&(n=d(parseInt(p.getAttribute("value"),
646
- 10)));m=Qn(c,"Accessibility");var x=new Map;m=t(m);for(p=m.next();!p.done;p=m.next())if(r=p.value,p=r.getAttribute("schemeIdUri"),r=r.getAttribute("value"),"urn:scte:dash:cc:cea-608:2015"==p)if(p=1,null!=r){r=r.split(";");for(var y=t(r),w=y.next();!w.done;w=y.next()){var v=w.value,D=w=void 0;v.includes("=")?(v=v.split("="),w=v[0].startsWith("CC")?v[0]:"CC"+v[0],D=v[1]||"und"):(w="CC"+p,2==r.length?p+=2:p++,D=v);x.set(w,Mb(D))}}else x.set("CC1","und");else if("urn:scte:dash:cc:cea-708:2015"==p)if(p=
647
- 1,null!=r)for(r=t(r.split(";")),w=r.next();!w.done;w=r.next())w=w.value,v=y=void 0,w.includes("=")?(w=w.split("="),y="svc"+w[0],v=w[1].split(",")[0].split(":").pop()):(y="svc"+p,p++,v=w),x.set(y,Mb(v));else x.set("svc1","und");else"urn:mpeg:dash:role:2011"==p&&null!=r&&(g.push(r),"captions"==r&&(h="caption"));if(l)return null;l=Qn(c,"ContentProtection");var C=jo(l,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI),B=Mb(c.getAttribute("lang")||"und"),G=c.getAttribute("label");(l=Qn(c,"Label"))&&l.length&&
648
- (l=l[0],l.textContent&&(G=l.textContent));l=Qn(c,"Representation");c=l.map(function(E){if(E=Vp(a,b,C,h,B,G,e,g,x,E))E.hdr=E.hdr||n;return E}).filter(function(E){return!!E});if(0==c.length){f="image"==b.Aa.contentType;if(a.g.dash.ignoreEmptyAdaptationSet||k||f)return null;throw new O(2,4,4003);}if(!b.Aa.contentType||"application"==b.Aa.contentType)for(b.Aa.contentType=Wp(c[0].mimeType,c[0].codecs),k=t(c),m=k.next();!m.done;m=k.next())m.value.type=b.Aa.contentType;k=t(c);for(m=k.next();!m.done;m=k.next())for(m=
649
- m.value,p=t(C.drmInfos),r=p.next();!r.done;r=p.next())r=r.value,r.keyIds=r.keyIds&&m.keyIds?new Set([].concat(ia(r.keyIds),ia(m.keyIds))):r.keyIds||m.keyIds;k=l.map(function(E){return E.getAttribute("id")}).filter(Cb);return{id:b.Aa.id||"__fake__"+a.I++,contentType:b.Aa.contentType,language:B,Wi:e,streams:c,drmInfos:C.drmInfos,Me:f,dh:k}}
650
- function Vp(a,b,c,d,e,f,g,h,k,l){b.L=Rp(l,b.Aa,null);a.C=Math.min(a.C,b.L.Yb);if(!Xp(b.L))return null;var m=b.Z.start;b.bandwidth=Yn(l,"bandwidth",co)||0;var n=b.L.contentType,p=n==Ib||"application"==n;n="image"==n;try{var r=function(H,L,K){return Yp(a,H,L,K)};if(b.L.Sc)var x=Lo(b,r);else if(b.L.Db)x=So(b,a.l);else if(b.L.Tc)x=Xo(b,r,a.l,!!a.i,a.g.dash.initialSegmentLimit,a.N);else{var y=b.L.Na,w=b.Z.duration||0;x={$b:function(){return Promise.resolve(Zi(m,w,y))}}}}catch(H){if((p||n)&&4002==H.code)return null;
651
- throw H;}r=Qn(l,"ContentProtection");r=mo(r,c,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI);r=new Set(r?[r]:[]);var v=!1;Qn(l,"SupplementalProperty").some(function(H){return"tag:dolby.com,2018:dash:EC3_ExtensionType:2018"==H.getAttribute("schemeIdUri")&&"JOC"==H.getAttribute("value")})&&(v=!0);var D=!1;p&&(D=h.includes("forced_subtitle")||h.includes("forced-subtitle"));var C;if(n&&((l=Qn(l,"EssentialProperty").find(function(H){return["http://dashif.org/thumbnail_tile","http://dashif.org/guidelines/thumbnail_tile"].includes(H.getAttribute("schemeIdUri"))}))&&
652
- (C=l.getAttribute("value")),!C))return null;var B;l=b.L.codecs;b.profiles.includes("http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10")&&(l.includes("hvc1.2.4.L153.B0")||l.includes("hev1.2.4.L153.B0"))&&(B="PQ");var G=b.L.id?b.ra.id+","+b.L.id:"",E={id:a.I++,originalId:b.L.id,createSegmentIndex:function(){var H,L,K;return I(function(N){if(1==N.g){L=(H=G&&b.xb&&a.l[G])?a.l[G]:E;if(L.segmentIndex)return N.D(0);K=L;return u(N,x.$b(),3)}K.segmentIndex=N.h;z(N)})},closeSegmentIndex:function(){E.segmentIndex&&
579
+ function xo(a,b){var c=yo(a,b,"timescale"),d=1;c&&(d=go(c)||1);var e=yo(a,b,"duration");c=go(e||"");"image"==a.L.contentType&&(c=io(e||""));c&&(c/=d);var f=yo(a,b,"startNumber");e=Number(yo(a,b,"presentationTimeOffset"))||0;var g=ho(f||"");if(null==f||null==g)g=1;var h=zo(a,b,"SegmentTimeline");f=null;if(h){f=d;var k=a.Z.duration||Infinity;h=Tn(h,"S");for(var l=[],m=-e,n=0;n<h.length;++n){var p=h[n],r=h[n+1],w=ao(p,"t",ho),y=ao(p,"d",ho);p=ao(p,"r",fo);null!=w&&(w-=e);if(!y)break;w=null!=w?w:m;p=
580
+ p||0;if(0>p)if(r){r=ao(r,"t",ho);if(null==r)break;else if(w>=r)break;p=Math.ceil((r-w)/y)-1}else{if(Infinity==k)break;else if(w/f>=k)break;p=Math.ceil((k*f-w)/y)-1}0<l.length&&w!=m&&(l[l.length-1].end=w/f);for(r=0;r<=p;++r)m=w+y,l.push({start:w/f,end:m/f,rh:w}),w=m}f=l}return{timescale:d,wa:c,mc:g,rb:e/d||0,Re:e,timeline:f}}function yo(a,b,c){return[b(a.L),b(a.Aa),b(a.ra)].filter(Cb).map(function(d){return d.getAttribute(c)}).reduce(function(d,e){return d||e})}
581
+ function zo(a,b,c){return[b(a.L),b(a.Aa),b(a.ra)].filter(Cb).map(function(d){return Sn(d,c)}).reduce(function(d,e){return d||e})}
582
+ function Ao(a,b,c,d,e,f){for(var g=Xn(a,"http://www.w3.org/1999/xlink","href"),h=Xn(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 Ze(new O(2,4,4028));if("onLoad"!=h)return Ze(new O(2,4,4027));var m=Db([d],[g]);return e.request(0,nf(m,b)).na(function(n){n=lo(n.data,a.tagName);if(!n)return Ze(new O(2,4,4001,g));
583
+ for(;a.childNodes.length;)a.removeChild(a.childNodes[0]);for(;n.childNodes.length;){var p=n.childNodes[0];n.removeChild(p);a.appendChild(p)}n=t(Array.from(n.attributes));for(p=n.next();!p.done;p=n.next())a.setAttributeNode(p.value.cloneNode(!1));return Bo(a,b,c,m[0],e,f+1)})}
584
+ function Bo(a,b,c,d,e,f){f=void 0===f?0:f;if(Xn(a,"http://www.w3.org/1999/xlink","href")){var g=Ao(a,b,c,d,e,f);c&&(g=g.na(void 0,function(){return Bo(a,b,c,d,e,f)}));return g}g=[];for(var h=t(Array.from(a.childNodes)),k=h.next();!k.done;k=h.next())k=k.value,k instanceof Element&&("urn:mpeg:dash:resolve-to-zero:2013"==Xn(k,"http://www.w3.org/1999/xlink","href")?a.removeChild(k):"SegmentTimeline"!=k.tagName&&g.push(Bo(k,b,c,d,e,f)));return cf(g).na(function(){return a})};function Co(a,b,c,d,e,f,g){var h,k=(new Ag).Y("sidx",function(l){h=Do(b,d,e,f,g,c,l)});a&&k.parse(a);if(h)return h;throw new O(2,3,3004);}
585
+ function Do(a,b,c,d,e,f,g){var h=[];g.reader.skip(4);var k=g.reader.R();if(0==k)throw new O(2,3,3005);if(0==g.version){var l=g.reader.R();var m=g.reader.R()}else l=g.reader.lc(),m=g.reader.lc();g.reader.skip(2);var n=g.reader.re();a=a+g.size+m;for(m=0;m<n;m++){var p=g.reader.R(),r=(p&2147483648)>>>31;p&=2147483647;var w=g.reader.R();g.reader.skip(4);if(1==r)throw new O(2,3,3006);h.push(new Yh(l/k+c,(l+w)/k+c,function(){return f},a,a+p-1,b,c,d,e));l+=w;a+=p}g.parser.stop();return h};function Eo(a){this.h=Jc(a);this.g=new xg(this.h,0)}Eo.prototype.Da=function(){return this.g.Da()};
586
+ function Fo(a){var b=Go(a);if(7<b.length)throw new O(2,3,3002);var c=0;b=t(b);for(var d=b.next();!d.done;d=b.next())c=256*c+d.value;b=Go(a);a:{d=t(Ho);for(var e=d.next();!e.done;e=d.next())if(Ec(b,new Uint8Array(e.value))){d=!0;break a}d=!1}if(d)b=a.h.byteLength-a.g.oa();else{if(8==b.length&&b[1]&224)throw new O(2,3,3001);for(e=d=0;e<b.length;e++){var f=b[e];d=0==e?f&(1<<8-b.length)-1:256*d+f}b=d}b=a.g.oa()+b<=a.h.byteLength?b:a.h.byteLength-a.g.oa();d=Jc(a.h,a.g.oa(),b);a.g.skip(b);return new Io(c,
587
+ d)}function Go(a){var b=a.g.oa(),c=a.g.qb();if(0==c)throw new O(2,3,3002);c=8-Math.floor(Math.log2(c));a.g.skip(c-1);return Gc(a.h,b,c)}var Ho=[[255],[127,255],[63,255,255],[31,255,255,255],[15,255,255,255,255],[7,255,255,255,255,255],[3,255,255,255,255,255,255],[1,255,255,255,255,255,255,255]];function Io(a,b){this.id=a;this.g=b}
588
+ function Jo(a){if(8<a.g.byteLength)throw new O(2,3,3002);if(8==a.g.byteLength&&a.g.getUint8(0)&224)throw new O(2,3,3001);for(var b=0,c=0;c<a.g.byteLength;c++){var d=a.g.getUint8(c);b=256*b+d}return b};function Ko(a,b,c,d,e,f,g,h,k){function l(){return e}var m=[];a=new Eo(a.g);for(var n=null,p=null;a.Da();){var r=Fo(a);if(187==r.id){var w=Lo(r);w&&(r=c*w.sh,w=b+w.ah,null!=n&&m.push(new Yh(n+g,r+g,l,p,w-1,f,g,h,k)),n=r,p=w)}}null!=n&&m.push(new Yh(n+g,d+g,l,p,null,f,g,h,k));return m}
589
+ function Lo(a){var b=new Eo(a.g);a=Fo(b);if(179!=a.id)throw new O(2,3,3013);a=Jo(a);b=Fo(b);if(183!=b.id)throw new O(2,3,3012);b=new Eo(b.g);for(var c=0;b.Da();){var d=Fo(b);if(241==d.id){c=Jo(d);break}}return{sh:a,ah:c}};function Mo(a,b){var c=zo(a,b,"Initialization");if(!c)return null;var d=a.L.Na,e=c.getAttribute("sourceURL");e&&(d=Db(a.L.Na,[e]));e=0;var f=null;if(c=ao(c,"range",eo))e=c.start,f=c.end;return new Wh(function(){return d},e,f,No(a))}
590
+ function Oo(a,b){var c=Number(yo(a,Qo,"presentationTimeOffset"))||0,d=yo(a,Qo,"timescale"),e=1;d&&(e=go(d)||1);var f=c/e||0,g=Mo(a,Qo);Ro(a,g);var h=ff(a);return{$b:function(){var k=zo(h,Qo,"RepresentationIndex"),l=h.L.Na;k&&(k=k.getAttribute("sourceURL"))&&(l=Db(h.L.Na,[k]));k=So(h);return To(h,b,g,l,k.start,k.end,f)}}}
591
+ function To(a,b,c,d,e,f,g){var h,k,l,m,n,p,r,w,y,x,v,D,C,B,G;return I(function(E){if(1==E.g)return h=a.presentationTimeline,k=!a.xb||!a.Z.yf,l=a.Z.start,m=a.Z.duration,n=a.L.mimeType.split("/")[1],p=b,r=null,w=[p(d,e,f),"webm"==n?p(c.Pa(),c.Ta,c.Ca):null],p=null,u(E,Promise.all(w),2);y=E.h;x=y[0];v=y[1]||null;D=null;C=l-g;B=l;G=m?l+m:Infinity;if("mp4"==n)var H=Co(x,e,d,c,C,B,G);else{H=new Eo(v);if(440786851!=Fo(H).id)throw new O(2,3,3008);var N=Fo(H);if(408125543!=N.id)throw new O(2,3,3009);H=N.g.byteOffset;
592
+ N=new Eo(N.g);for(var K=null;N.Da();){var M=Fo(N);if(357149030==M.id){K=M;break}}if(!K)throw new O(2,3,3010);K=new Eo(K.g);M=1E6;for(N=null;K.Da();){var V=Fo(K);if(2807729==V.id)M=Jo(V);else if(17545==V.id)if(4==V.g.byteLength)N=V.g.getFloat32(0);else if(8==V.g.byteLength)N=V.g.getFloat64(0);else throw new O(2,3,3003);}if(null==N)throw new O(2,3,3011);K=M/1E9;N*=K;M=Fo(new Eo(x));if(475249515!=M.id)throw new O(2,3,3007);H=Ko(M,H,K,N,d,c,C,B,G)}D=H;h.ic(D);r=new $i(D);k&&r.yb(B,G,!0);return E["return"](r)})}
593
+ function Qo(a){return a.Sc}function So(a){var b=zo(a,Qo,"RepresentationIndex");a=yo(a,Qo,"indexRange");a=eo(a||"");b&&(a=ao(b,"range",eo,a));return a}function Ro(a,b){Uo(a,b);if(!So(a))throw new O(2,4,4002);}function Uo(a,b){var c=a.L.mimeType.split("/")[1];if(a.L.contentType!=Ib&&"mp4"!=c&&"webm"!=c)throw new O(2,4,4006);if("webm"==c&&!b)throw new O(2,4,4005);}
594
+ function No(a){var b=a.L;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.td,pixelAspectRatio:b.pixelAspectRatio||null,width:b.width||null}};function Vo(a,b){var c=Mo(a,Wo),d=Xo(a);if(!d.wa&&!d.timeline&&1<d.fc.length)throw new O(2,4,4002);if(!d.wa&&!a.Z.duration&&!d.timeline&&1==d.fc.length)throw new O(2,4,4002);if(d.timeline&&0==d.timeline.length)throw new O(2,4,4002);var e=null,f=null;a.ra.id&&a.L.id&&(f=b[a.ra.id+","+a.L.id])&&(e=f.segmentIndex);var g=Yo(a.Z.start,a.Z.duration,a.L.Na,d,c);c=!e;e?e.hc(g,a.presentationTimeline.ob()):e=new $i(g);a.presentationTimeline.ic(g);a.xb&&a.Z.yf||e.yb(a.Z.start,a.Z.duration?a.Z.start+a.Z.duration:
595
+ Infinity,c);f&&(f.segmentIndex=e);return{$b:function(){e&&0!=e.M.length||e.Mc(g);return Promise.resolve(e)}}}function Wo(a){return a.Db}function Xo(a){var b=Zo(a);a=xo(a,Wo);var c=a.mc;0==c&&(c=1);var d=0;a.wa?d=a.wa*(c-1):a.timeline&&0<a.timeline.length&&(d=a.timeline[0].start);return{wa:a.wa,startTime:d,mc:c,rb:a.rb,timeline:a.timeline,fc:b}}
596
+ function Yo(a,b,c,d,e){var f=d.fc.length;d.timeline&&d.timeline.length!=d.fc.length&&(f=Math.min(d.timeline.length,d.fc.length));for(var g=a-d.rb,h=b?a+b:Infinity,k=[],l=d.startTime,m={},n=0;n<f;m={Od:m.Od},n++){var p=d.fc[n];m.Od=Db(c,[p.Sg]);var r=void 0;r=null!=d.wa?l+d.wa:d.timeline?d.timeline[n].end:l+b;k.push(new Yh(a+l,a+r,function(w){return function(){return w.Od}}(m),p.start,p.end,e,g,a,h));l=r}return k}
597
+ function Zo(a){return[a.L.Db,a.Aa.Db,a.ra.Db].filter(Cb).map(function(b){return Tn(b,"SegmentURL")}).reduce(function(b,c){return 0<b.length?b:c}).map(function(b){b.getAttribute("indexRange")&&!a.wf&&(a.wf=!0);var c=b.getAttribute("media");b=ao(b,"mediaRange",eo,{start:0,end:null});return{Sg:c,start:b.start,end:b.end}})};function $o(a,b,c,d,e,f){var g=ap(a),h=bp(a);cp(h);var k=ff(a);if(h.Jc)return Uo(a,g),{$b:function(){var r=wo(h.Jc,k.L.id,null,k.bandwidth||null,null);r=Db(k.L.Na,[r]);return To(k,b,g,r,0,null,h.rb)}};if(h.wa)return d||(a.presentationTimeline.le(h.wa),a.presentationTimeline.me(a.Z.start)),{$b:function(){return dp(k,h,e,g,f)}};var l=null;d=d=null;a.ra.id&&a.L.id&&(d=a.ra.id+","+a.L.id,d=c[d])&&(l=d.segmentIndex);var m=ep(k,h,g);c=a.Z.start;var n=a.Z.duration?a.Z.start+a.Z.duration:Infinity,p=Infinity!=
598
+ n;l?(p&&(new $i(m)).yb(c,n,!0),l.hc(m,a.presentationTimeline.ob())):l=new $i(m);a.presentationTimeline.ic(m);p&&l.yb(c,n);d&&a.xb&&(d.segmentIndex=l);return{$b:function(){l&&0!=l.M.length||l.Mc(m);return Promise.resolve(l)}}}function fp(a){return a.Tc}function bp(a){var b=xo(a,fp),c=yo(a,fp,"media");a=yo(a,fp,"index");return{wa:b.wa,timescale:b.timescale,mc:b.mc,rb:b.rb,Re:b.Re,timeline:b.timeline,ke:c,Jc:a}}
599
+ function cp(a){var b=a.Jc?1:0;b+=a.timeline?1:0;b+=a.wa?1:0;if(0==b)throw new O(2,4,4002);1!=b&&(a.Jc&&(a.timeline=null),a.wa=null);if(!a.Jc&&!a.ke)throw new O(2,4,4002);}
600
+ function dp(a,b,c,d,e){function f(K){var M=(K-r)*p,V=M+b.rb,Z=M+l;M=Z+p;var ha=Math.min(M,h());Z=new Yh(Z,ha,function(){var ja=wo(y,v,K,x,V*w);return Db(D,[ja])},0,null,d,C,l,h());Z.j=M;return Z}function g(){var K=[Math.max(k.ob(),l),Math.min(k.Ib(),h())].map(function(M){return M-l});return[Math.ceil(K[0]/p),Math.ceil(K[1]/p)-1].map(function(M){return M+r})}function h(){var K=null!=m&&e[m]||n;return K?l+K:Infinity}var k=a.presentationTimeline,l=a.Z.start,m=a.ra.id,n=a.Z.duration,p=b.wa,r=b.mc,w=b.timescale,
601
+ y=b.ke,x=a.bandwidth||null,v=a.L.id,D=a.L.Na,C=l-b.rb,B=g();a=a.xb?Math.max(B[0],B[1]-c+1):B[0];B=B[1];c=[];for(var G=a;G<=B;++G){var E=f(G);c.push(E)}var H=new $i(c);c=k.Ib()<h();G=k.U();if(c||G){var N=Math.max(a,B+1);H.Fd(p,function(){var K=k.ob();H.Gb(K);var M=t(g());M.next();M=M.next().value;for(var V=[];N<=M;){var Z=f(N);V.push(Z);N++}return K>h()&&!V.length?null:V})}return Promise.resolve(H)}
602
+ function ep(a,b,c){var d=a.Z.start,e=a.Z.duration,f=d-b.rb;e=e?d+e:Infinity;for(var g=[],h={},k=0;k<b.timeline.length;h={Nd:h.Nd,Rd:h.Rd,Ud:h.Ud,Kd:h.Kd,Wd:h.Wd,Ld:h.Ld},k++){var l=b.timeline[k],m=l.start,n=l.rh;l=l.end;h.Ud=k+b.mc;h.Wd=n+b.Re;h.Rd=a.L.id;h.Kd=a.bandwidth||null;h.Nd=b.ke;h.Ld=a.L.Na;g.push(new Yh(d+m,d+l,function(p){return function(){var r=wo(p.Nd,p.Rd,p.Ud,p.Kd||null,p.Wd);return Db(p.Ld,[r]).map(function(w){return w.toString()})}}(h),0,null,c,f,d,e))}return g}
603
+ function ap(a){var b=yo(a,fp,"initialization");if(!b)return null;var c=a.L.id,d=a.bandwidth||null,e=a.L.Na;return new Wh(function(){var f=wo(b,c,null,d,null);return Db(e,[f])},0,null,No(a))};function gp(){this.l=[];this.g=[];this.h=[];this.j=[];this.i=[];this.m=new Set}gp.prototype.release=function(){for(var a=t(this.g.concat(this.h,this.j,this.i)),b=a.next();!b.done;b=a.next())b=b.value,b.segmentIndex&&b.segmentIndex.release();this.g=[];this.h=[];this.j=[];this.i=[];this.l=[]};
604
+ function hp(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,w,y,x,v,D,C,B,G,E,H,N,K,M,V,Z,ha,ja,xa,La;return I(function(Fa){switch(Fa.g){case 1:d=Jb;ip(b);jp(b);kp(b);lp(b);if(!c&&1==b.length){e=b[0];a.g=e.dd;a.h=e.Hd;a.j=e.textStreams;a.i=e.imageStreams;Fa.D(2);break}f=-1;for(g=0;g<b.length;g++)h=b[g],a.m.has(h.id)||(a.m.add(h.id),-1==f&&(f=g));if(-1==f)return Fa["return"]();k=b.map(function(Sa){return Sa.dd});l=b.map(function(Sa){return Sa.Hd});m=b.map(function(Sa){return Sa.textStreams});n=b.map(function(Sa){return Sa.imageStreams});
605
+ p=t(m);for(r=p.next();!r.done;r=p.next())w=r.value,w.push(mp(d.ha));y=t(n);for(x=y.next();!x.done;x=y.next())v=x.value,v.push(mp(d.xc));return u(Fa,np(a.g,k,f,op,pp),3);case 3:return u(Fa,np(a.h,l,f,op,pp),4);case 4:return u(Fa,np(a.j,m,f,op,pp),5);case 5:return u(Fa,np(a.i,n,f,op,pp),2);case 2:D=0;C=[];if(a.h.length&&a.g.length)for(K=t(a.g),M=K.next();!M.done;M=K.next())for(V=M.value,Z=t(a.h),ha=Z.next();!ha.done;ha=Z.next())ja=ha.value,xa=pg(V.drmInfos,ja.drmInfos),V.drmInfos.length&&ja.drmInfos.length&&
606
+ !xa.length||(La=D++,C.push({id:La,language:V.language,primary:V.primary,audio:V,video:ja,bandwidth:(V.bandwidth||0)+(ja.bandwidth||0),drmInfos:xa,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]}));else for(B=a.h.concat(a.g),G=t(B),E=G.next();!E.done;E=G.next())H=E.value,N=D++,C.push({id:N,language:H.language,primary:H.primary,audio:H.type==d.Fb?H:null,video:H.type==d.Ma?H:null,bandwidth:H.bandwidth||0,drmInfos:H.drmInfos,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});
607
+ a.l=C;z(Fa)}})}function ip(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;for(var c=[],d=t(b.dd),e=d.next();!e.done;e=d.next()){e=e.value;for(var f=!1,g=t(c),h=g.next();!h.done;h=g.next())h=h.value,e.id!=h.id&&e.channelsCount==h.channelsCount&&e.language==h.language&&e.bandwidth==h.bandwidth&&e.label==h.label&&e.codecs==h.codecs&&e.mimeType==h.mimeType&&ec(e.roles,h.roles)&&e.audioSamplingRate==h.audioSamplingRate&&e.primary==h.primary&&(f=!0);f||c.push(e)}b.dd=c}}
608
+ function kp(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;for(var c=[],d=t(b.textStreams),e=d.next();!e.done;e=d.next()){e=e.value;for(var f=!1,g=t(c),h=g.next();!h.done;h=g.next())h=h.value,e.id!=h.id&&e.language==h.language&&e.label==h.label&&e.codecs==h.codecs&&e.mimeType==h.mimeType&&e.bandwidth==h.bandwidth&&ec(e.roles,h.roles)&&(f=!0);f||c.push(e)}b.textStreams=c}}
609
+ function jp(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;for(var c=[],d=t(b.Hd),e=d.next();!e.done;e=d.next()){e=e.value;for(var f=!1,g=t(c),h=g.next();!h.done;h=g.next())h=h.value,e.id!=h.id&&e.width==h.width&&e.frameRate==h.frameRate&&e.codecs==h.codecs&&e.mimeType==h.mimeType&&e.label==h.label&&ec(e.roles,h.roles)&&Df(e.closedCaptions,h.closedCaptions)&&e.bandwidth==h.bandwidth&&(f=!0);f||c.push(e)}b.Hd=c}}
610
+ function lp(a){a=t(a);for(var b=a.next();!b.done;b=a.next()){b=b.value;for(var c=[],d=t(b.imageStreams),e=d.next();!e.done;e=d.next()){e=e.value;for(var f=!1,g=t(c),h=g.next();!h.done;h=g.next())h=h.value,e.id!=h.id&&e.width==h.width&&e.codecs==h.codecs&&e.mimeType==h.mimeType&&(f=!0);f||c.push(e)}b.imageStreams=c}}
611
+ function qp(a){var b,c,d,e,f,g,h,k,l,m,n,p,r,w,y,x,v,D,C,B,G,E,H,N,K,M,V;return I(function(Z){switch(Z.g){case 1:b=Jb;if(1==a.length)return Z["return"](a[0]);c=a.map(function(ha){return ha.filter(function(ja){return ja.type==b.Fb})});d=a.map(function(ha){return ha.filter(function(ja){return ja.type==b.Ma})});e=a.map(function(ha){return ha.filter(function(ja){return ja.type==b.ha})});f=a.map(function(ha){return ha.filter(function(ja){return ja.type==b.xc})});g=t(e);for(h=g.next();!h.done;h=g.next())k=
612
+ h.value,k.push(rp(b.ha));l=t(f);for(m=l.next();!m.done;m=l.next())n=m.value,n.push(rp(b.xc));return u(Z,np([],c,0,sp,tp),2);case 2:return p=Z.h,u(Z,np([],d,0,sp,tp),3);case 3:return r=Z.h,u(Z,np([],e,0,sp,tp),4);case 4:return w=Z.h,u(Z,np([],f,0,sp,tp),5);case 5:y=Z.h;x=0;if(r.length&&p.length)for(G=t(p),E=G.next();!E.done;E=G.next())for(H=E.value,N=t(r),K=N.next();!K.done;K=N.next())M=K.value,V=x++,M.variantIds.push(V),H.variantIds.push(V);else for(v=r.concat(p),D=t(v),C=D.next();!C.done;C=D.next())B=
613
+ C.value,B.variantIds=[x++];return Z["return"](r.concat(p).concat(w).concat(y))}})}
614
+ function np(a,b,c,d,e){var f,g,h,k,l,m,n,p,r,w,y,x,v,D,C,B,G,E,H,N,K;return I(function(M){switch(M.g){case 1:f=Jb;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){M.D(4);break}m=l.value;return u(M,up(m,b,c,e,g),5);case 5:n=M.h;if(!n)throw new O(2,4,4037);l=k.next();M.D(2);break;case 4:p=t(g);for(r=p.next();!r.done;r=p.next())for(w=r.value,y=t(w),x=y.next();!x.done;x=y.next())v=x.value,(D=vp(v,b,d,e,g))&&a.push(D);C=t(g);for(r=C.next();!r.done;r=
615
+ C.next())for(B=r.value,G={},E=t(B),x=E.next();!x.done;G={vb:G.vb},x=E.next())if(G.vb=x.value,H=G.vb.type==f.ha&&!G.vb.language,N=G.vb.type==f.xc&&!G.vb.tilesLayout,!H&&!N&&(K=a.some(function(V){return function(Z){return Z.mimeType==V.vb.mimeType&&Ad(Z.codecs)==Ad(V.vb.codecs)}}(G))))throw new O(2,4,4037);return M["return"](a)}})}
616
+ function up(a,b,c,d,e){return I(function(f){if(1==f.g)return wp(b,a),a.matchedStreams?a.segmentIndex?u(f,xp(a,c),2):f.D(2):f["return"](!1);yp(a,c,d,e);return f["return"](!0)})}
617
+ function xp(a,b){var c,d,e,f,g,h,k;return I(function(l){if(1==l.g){c=[];d=a.matchedStreams;e=t(d);for(f=e.next();!f.done;f=e.next())g=f.value,c.push(g.createSegmentIndex()),g.trickModeVideo&&!g.trickModeVideo.segmentIndex&&c.push(g.trickModeVideo.createSegmentIndex());return u(l,Promise.all(c),2)}if(a.segmentIndex instanceof cj)for(h=0;h<d.length;h++)k=d[h],k.segmentIndex&&h>=b&&a.segmentIndex.j.push(k.segmentIndex);z(l)})}
618
+ function vp(a,b,c,d,e){var f=c(a);wp(b,f);f.createSegmentIndex&&(f.createSegmentIndex=function(){return I(function(g){if(f.segmentIndex)return g.D(0);f.segmentIndex=new cj;return u(g,xp(f,0),0)})});if(!f.matchedStreams)return null;yp(f,0,d,e);return f}function yp(a,b,c,d){for(var e=a.matchedStreams,f=0;f<e.length;f++)if(f>=b){var g=e[f];c(a,g);var h=!0;"audio"==a.type&&0==Sb(a.language,g.language)&&(h=!1);h&&d[f]["delete"](g)}}
619
+ function op(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}
620
+ function sp(a){a=Object.assign({},a);a.keyIds=new Set;a.segments=[];a.variantIds=[];a.closedCaptions=null;return a}
621
+ function pp(a,b){a.roles=Array.from(new Set(a.roles.concat(b.roles)));b.emsgSchemeIdUris&&(a.emsgSchemeIdUris=Array.from(new Set(a.emsgSchemeIdUris.concat(b.emsgSchemeIdUris))));a.keyIds=function(f,g){return new Set([].concat(ia(f),ia(g)))}(a.keyIds,b.keyIds);null==a.originalId?a.originalId=b.originalId:a.originalId+=","+(b.originalId||"");var c=pg(a.drmInfos,b.drmInfos);if(b.drmInfos.length&&a.drmInfos.length&&!c.length)throw new O(2,4,4038);a.drmInfos=c;a.encrypted=a.encrypted||b.encrypted;if(b.closedCaptions){a.closedCaptions||
622
+ (a.closedCaptions=new Map);c=t(b.closedCaptions);for(var d=c.next();!d.done;d=c.next()){var e=t(d.value);d=e.next().value;e=e.next().value;a.closedCaptions.set(d,e)}}b.trickModeVideo?(a.trickModeVideo||(a.trickModeVideo=op(b.trickModeVideo),a.trickModeVideo.createSegmentIndex=function(){a.trickModeVideo.segmentIndex=a.segmentIndex.clone();return Promise.resolve()}),pp(a.trickModeVideo,b.trickModeVideo)):a.trickModeVideo&&pp(a.trickModeVideo,b)}
623
+ function tp(a,b){a.roles=Array.from(new Set(a.roles.concat(b.roles)));var c=b.keyIds;c=new Set([].concat(ia(a.keyIds),ia(c)));a.keyIds=c;a.encrypted=a.encrypted&&b.encrypted;a.segments.push.apply(a.segments,ia(b.segments));if(b.closedCaptions){a.closedCaptions||(a.closedCaptions=new Map);c=t(b.closedCaptions);for(var d=c.next();!d.done;d=c.next()){var e=t(d.value);d=e.next().value;e=e.next().value;a.closedCaptions.set(d,e)}}}
624
+ function wp(a,b){for(var c=[],d=t(a),e=d.next();!e.done;e=d.next()){var f=b,g={audio:zp,video:zp,text:Ap,image:Bp}[f.type],h={audio:Cp,video:Dp,text:Ep,image:Fp}[f.type],k=null;e=t(e.value);for(var l=e.next();!l.done;l=e.next())l=l.value,!g(f,l)||k&&!h(f,k,l)||(k=l);f=k;if(!f)return;c.push(f)}b.matchedStreams=c}function zp(a,b){var c;if(!(c=b.mimeType!=a.mimeType||Ad(b.codecs)!=Ad(a.codecs))&&(c=a.drmInfos)){c=a.drmInfos;var d=b.drmInfos;c=!(c.length&&d.length?0<pg(c,d).length:1)}return c?!1:!0}
625
+ function Ap(a,b){return a.language?b.language?0==Sb(a.language,b.language)||b.kind!=a.kind?!1:!0:!0:!1}function Bp(a){return a.tilesLayout?!0:!1}
626
+ function Cp(a,b,c){if(a.id==c.id)return!0;var d=Sb(a.language,b.language),e=Sb(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)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;
627
+ d=Gp(a.channelsCount,b.channelsCount,c.channelsCount);if(d==Hp)return!0;if(d==Ip)return!1;d=Gp(a.audioSamplingRate,b.audioSamplingRate,c.audioSamplingRate);return d==Hp?!0:d==Ip?!1:a.bandwidth&&Jp(a.bandwidth,b.bandwidth,c.bandwidth)==Hp?!0:!1}
628
+ function Dp(a,b,c){if(a.id==c.id)return!0;var d=Gp(a.width*a.height,b.width*b.height,c.width*c.height);if(d==Hp)return!0;if(d==Ip)return!1;if(a.frameRate){d=Gp(a.frameRate,b.frameRate,c.frameRate);if(d==Hp)return!0;if(d==Ip)return!1}return a.bandwidth&&Jp(a.bandwidth,b.bandwidth,c.bandwidth)==Hp?!0:!1}
629
+ function Ep(a,b,c){if(a.id==c.id)return!0;var d=Sb(a.language,b.language),e=Sb(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!=
630
+ a.mimeType||c.codecs!=a.codecs||b.mimeType==a.mimeType&&b.codecs==a.codecs?!1:!0}function Fp(a,b,c){return a.id==c.id?!0:Gp(a.width*a.height,b.width*b.height,c.width*c.height)==Hp?!0:!1}function rp(a){return{id:0,originalId:"",primary:!1,type:a,mimeType:"",codecs:"",language:"",label:null,width:null,height:null,encrypted:!1,keyIds:new Set,segments:[],variantIds:[],roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null}}
631
+ function mp(a){return{id:0,originalId:"",createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new $i([]),mimeType:"",codecs:"",encrypted:!1,drmInfos:[],keyIds:new Set,language:"",label:null,type:a,primary:!1,trickModeVideo:null,emsgSchemeIdUris:null,roles:[],forced:!1,channelsCount:null,audioSamplingRate:null,spatialAudio:!1,closedCaptions:null}}
632
+ function Gp(a,b,c){if(b==a&&a!=c)return Ip;if(c==a&&a!=b)return Hp;if(b>a){if(c<=a||c-a<b-a)return Hp;if(c-a>b-a)return Ip}else{if(c>a)return Ip;if(a-c<a-b)return Hp;if(a-c>a-b)return Ip}return Kp}function Jp(a,b,c){b=Math.abs(a-b);a=Math.abs(a-c);return a<b?Hp:b<a?Ip:Kp}var Hp=1,Kp=0,Ip=-1;function Lp(){var a=this;this.h=this.g=null;this.m=[];this.i=null;this.I=1;this.l={};this.N={};this.j=new gp;this.H=0;this.J=new $b(5);this.G=new P(function(){Mp(a)});this.A=new gf;this.B=null;this.K=[];this.C=Infinity;this.F=!1}q=Lp.prototype;q.configure=function(a){this.g=a};q.start=function(a,b){var c=this,d;return I(function(e){if(1==e.g)return c.F=b.isLowLatencyMode(),c.m=[a],c.h=b,u(e,Np(c),2);d=e.h;c.h&&Op(c,d);if(!c.h)throw new O(2,7,7001);return e["return"](c.i)})};
633
+ q.stop=function(){for(var a=t(Object.values(this.l)),b=a.next();!b.done;b=a.next())b=b.value,b.segmentIndex&&b.segmentIndex.release();this.j&&this.j.release();this.g=this.h=null;this.m=[];this.i=null;this.l={};this.j=null;null!=this.G&&(this.G.stop(),this.G=null);return this.A.destroy()};q.update=function(){var a=this,b;return I(function(c){if(1==c.g)return A(c,2),u(c,Np(a),4);if(2!=c.g)return va(c,0);b=F(c);if(!a.h||!b)return c["return"]();a.h.onError(b);z(c)})};q.onExpirationUpdated=function(){};
634
+ function Np(a){var b,c,d,e,f,g,h;return I(function(k){if(1==k.g)return b=nf(a.m,a.g.retryParameters),c=a.h.networkingEngine,a.h.modifyManifestRequest(b,{format:"d"}),d=Date.now(),e=c.request(0,b),hf(a.A,e),u(k,e.promise,2);if(3!=k.g){f=k.h;if(!a.h)return k["return"](0);f.uri&&!a.m.includes(f.uri)&&a.m.unshift(f.uri);return u(k,Pp(a,f.data,f.uri),3)}g=Date.now();h=(g-d)/1E3;a.J.sample(1,h);return k["return"](h)})}
635
+ function Pp(a,b,c){var d,e,f,g,h;return I(function(k){if(1==k.g){d=lo(b,"MPD");if(!d)throw new O(2,4,4001,c);if(e=a.g.dash.disableXlinkProcessing)return k["return"](Qp(a,d,c));f=a.g.dash.xlinkFailGracefully;g=Bo(d,a.g.retryParameters,f,c,a.h.networkingEngine);hf(a.A,g);return u(k,g.promise,2)}h=k.h;return k["return"](Qp(a,h,c))})}
636
+ function Qp(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,w,y,x,v,D,C,B,G,E,H,N,K,M,V,Z,ha,ja,xa,La,Fa,Sa;return I(function(Ga){switch(Ga.g){case 1:(d=a.g.dash.manifestPreprocessor)&&d(b);e=[c];f=Tn(b,"Location").map(Zn).filter(Cb);0<f.length&&(g=Db(e,f),e=a.m=g);h=Tn(b,"BaseURL");k=h.map(Zn);l=Db(e,k);m=0;h&&h.length&&(m=ao(h[0],"availabilityTimeOffset",io)||0);n=a.g.dash.ignoreMinBufferTime;p=0;n||(p=ao(b,"minBufferTime",co)||0);a.H=ao(b,"minimumUpdatePeriod",co,-1);r=ao(b,"availabilityStartTime",bo);w=ao(b,
637
+ "timeShiftBufferDepth",co);y=a.g.dash.ignoreSuggestedPresentationDelay;x=null;y||(x=ao(b,"suggestedPresentationDelay",co));v=a.g.dash.ignoreMaxSegmentDuration;D=null;v||(D=ao(b,"maxSegmentDuration",co));C=b.getAttribute("type")||"static";if(a.i)for(B=a.i.presentationTimeline,G=t(Object.values(a.l)),E=G.next();!E.done;E=G.next())H=E.value,H.segmentIndex&&H.segmentIndex.Gb(B.ob());else N=a.g.defaultPresentationDelay||1.5*p,K=null!=x?x:N,B=new Q(r,K,a.g.dash.autoCorrectDrift);B.Uc("static"==C);(M=B.U())&&
638
+ !isNaN(a.g.availabilityWindowOverride)&&(w=a.g.availabilityWindowOverride);null==w&&(w=Infinity);B.He(w);V=b.getAttribute("profiles")||"";Z={xb:"static"!=C,presentationTimeline:B,ra:null,Z:null,Aa:null,L:null,bandwidth:0,wf:!1,Yb:m,profiles:V.split(",")};ha=Rp(a,Z,l,b);ja=ha.duration;xa=ha.periods;"static"!=C&&ha.lf||B.bb(ja||Infinity);a.C&&!a.F&&(La=a.h.isAutoLowLatencyMode())&&(a.h.enableLowLatencyMode(),a.F=a.h.isLowLatencyMode());a.F?B.Ff(a.C):a.C&&Ua("Low-latency DASH live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details.");
639
+ B.le(D||1);return u(Ga,hp(a.j,xa,Z.xb),2);case 2:if(a.i){a.i.variants=a.j.l;a.i.textStreams=a.j.j.slice();a.i.imageStreams=a.j.i;a.h.filter(a.i);Ga.D(3);break}a.i={presentationTimeline:B,variants:a.j.l,textStreams:a.j.j.slice(),imageStreams:a.j.i,offlineSessionIds:[],minBufferTime:p||0,sequenceMode:!1};if(!B.Nf()){Ga.D(4);break}Fa=Tn(b,"UTCTiming");return u(Ga,Sp(a,l,Fa),5);case 5:Sa=Ga.h;if(!a.h)return Ga["return"]();B.Gf(Sa);case 4:B.ge();case 3:a.h.makeTextStreamsForClosedCaptions(a.i),z(Ga)}})}
640
+ function Rp(a,b,c,d){var e=ao(d,"mediaPresentationDuration",co),f=[],g=0;d=Tn(d,"Period");for(var h=0;h<d.length;h++){var k=d[h],l=d[h+1],m=ao(k,"start",co,g),n=k.id,p=ao(k,"duration",co),r=null;if(l){var w=ao(l,"start",co);null!=w&&(r=w-m)}else null!=e&&(r=e-m);null==r&&(r=p);if(!(null!==a.B&&null!==n&&null!==m&&m<a.B)||a.K.includes(n)||h+1==d.length){null!==m&&(null===a.B||m>a.B)&&(a.B=m);g=Tp(a,b,c,{start:m,duration:r,node:k,yf:null==r||!l});f.push(g);b.ra.id&&r&&(a.N[b.ra.id]=r);if(null==r){g=
641
+ null;break}g=m+r}}a.K=f.map(function(y){return y.id});return null!=e?{periods:f,duration:e,lf:!1}:{periods:f,duration:g,lf:!0}}
642
+ function Tp(a,b,c,d){b.ra=Up(d.node,null,c);b.Z=d;b.ra.Yb=b.Yb;b.ra.id||(b.ra.id="__shaka_period_"+d.start);var e=Tn(d.node,"EventStream");c=b.presentationTimeline.ob();e=t(e);for(var f=e.next();!f.done;f=e.next())Vp(a,d.start,d.duration,f.value,c);c=Tn(d.node,"AdaptationSet").map(function(m){return Wp(a,b,m)}).filter(Cb);if(b.xb){d=[];e=t(c);for(f=e.next();!f.done;f=e.next()){f=t(f.value.eh);for(var g=f.next();!g.done;g=f.next())d.push(g.value)}if(d.length!=(new Set(d)).size)throw new O(2,4,4018);
643
+ }d=c.filter(function(m){return!m.Ne});c=c.filter(function(m){return m.Ne});c=t(c);for(e=c.next();!e.done;e=c.next()){e=e.value;f=e.Ne.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={$c:h.$c},l=k.next())h.$c=l.value,h.$c.trickModeVideo=e.streams.find(function(m){return function(n){return Ad(m.$c.codecs)==Ad(n.codecs)}}(h))}}}e=a.g.disableAudio?[]:Xp(d,"audio");g=a.g.disableVideo?[]:Xp(d,"video");f=a.g.disableText?
644
+ []:Xp(d,Ib);c=a.g.disableThumbnails?[]:Xp(d,"image");if(!g.length&&!e.length)throw new O(2,4,4004);d=[];e=t(e);for(h=e.next();!h.done;h=e.next())d.push.apply(d,ia(h.value.streams));e=[];g=t(g);for(h=g.next();!h.done;h=g.next())e.push.apply(e,ia(h.value.streams));g=[];f=t(f);for(h=f.next();!h.done;h=f.next())g.push.apply(g,ia(h.value.streams));f=[];c=t(c);for(h=c.next();!h.done;h=c.next())f.push.apply(f,ia(h.value.streams));return{id:b.ra.id,dd:d,Hd:e,textStreams:g,imageStreams:f}}
645
+ function Xp(a,b){return a.filter(function(c){return c.contentType==b})}
646
+ function Wp(a,b,c){function d(E){switch(E){case 1:case 6:case 13:case 14:case 15:return"SDR";case 16:return"PQ";case 18:return"HLG"}}b.Aa=Up(c,b.ra,null);var e=!1,f=Tn(c,"Role"),g=f.map(function(E){return E.getAttribute("value")}).filter(Cb),h=void 0,k=b.Aa.contentType==Ib;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=
647
+ l}}var n;m=Tn(c,"EssentialProperty");f=null;l=!1;m=t(m);for(var p=m.next();!p.done;p=m.next()){p=p.value;var r=p.getAttribute("schemeIdUri");"http://dashif.org/guidelines/trickmode"==r?f=p.getAttribute("value"):"urn:mpeg:mpegB:cicp:TransferCharacteristics"==r?n=d(parseInt(p.getAttribute("value"),10)):l=!0}m=Tn(c,"SupplementalProperty");m=t(m);for(p=m.next();!p.done;p=m.next())p=p.value,"urn:mpeg:mpegB:cicp:TransferCharacteristics"==p.getAttribute("schemeIdUri")&&(n=d(parseInt(p.getAttribute("value"),
648
+ 10)));m=Tn(c,"Accessibility");var w=new Map;m=t(m);for(p=m.next();!p.done;p=m.next())if(r=p.value,p=r.getAttribute("schemeIdUri"),r=r.getAttribute("value"),"urn:scte:dash:cc:cea-608:2015"==p)if(p=1,null!=r){r=r.split(";");for(var y=t(r),x=y.next();!x.done;x=y.next()){var v=x.value,D=x=void 0;v.includes("=")?(v=v.split("="),x=v[0].startsWith("CC")?v[0]:"CC"+v[0],D=v[1]||"und"):(x="CC"+p,2==r.length?p+=2:p++,D=v);w.set(x,Mb(D))}}else w.set("CC1","und");else if("urn:scte:dash:cc:cea-708:2015"==p)if(p=
649
+ 1,null!=r)for(r=t(r.split(";")),x=r.next();!x.done;x=r.next())x=x.value,v=y=void 0,x.includes("=")?(x=x.split("="),y="svc"+x[0],v=x[1].split(",")[0].split(":").pop()):(y="svc"+p,p++,v=x),w.set(y,Mb(v));else w.set("svc1","und");else"urn:mpeg:dash:role:2011"==p&&null!=r&&(g.push(r),"captions"==r&&(h="caption"));if(l)return null;l=Tn(c,"ContentProtection");var C=mo(l,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI),B=Mb(c.getAttribute("lang")||"und"),G=c.getAttribute("label");(l=Tn(c,"Label"))&&l.length&&
650
+ (l=l[0],l.textContent&&(G=l.textContent));l=Tn(c,"Representation");c=l.map(function(E){if(E=Yp(a,b,C,h,B,G,e,g,w,E))E.hdr=E.hdr||n;return E}).filter(function(E){return!!E});if(0==c.length){f="image"==b.Aa.contentType;if(a.g.dash.ignoreEmptyAdaptationSet||k||f)return null;throw new O(2,4,4003);}if(!b.Aa.contentType||"application"==b.Aa.contentType)for(b.Aa.contentType=Zp(c[0].mimeType,c[0].codecs),k=t(c),m=k.next();!m.done;m=k.next())m.value.type=b.Aa.contentType;k=t(c);for(m=k.next();!m.done;m=k.next())for(m=
651
+ m.value,p=t(C.drmInfos),r=p.next();!r.done;r=p.next())r=r.value,r.keyIds=r.keyIds&&m.keyIds?new Set([].concat(ia(r.keyIds),ia(m.keyIds))):r.keyIds||m.keyIds;k=l.map(function(E){return E.getAttribute("id")}).filter(Cb);return{id:b.Aa.id||"__fake__"+a.I++,contentType:b.Aa.contentType,language:B,Xi:e,streams:c,drmInfos:C.drmInfos,Ne:f,eh:k}}
652
+ function Yp(a,b,c,d,e,f,g,h,k,l){b.L=Up(l,b.Aa,null);a.C=Math.min(a.C,b.L.Yb);if(!$p(b.L))return null;var m=b.Z.start;b.bandwidth=ao(l,"bandwidth",go)||0;var n=b.L.contentType,p=n==Ib||"application"==n;n="image"==n;try{var r=function(H,N,K){return aq(a,H,N,K)};if(b.L.Sc)var w=Oo(b,r);else if(b.L.Db)w=Vo(b,a.l);else if(b.L.Tc)w=$o(b,r,a.l,!!a.i,a.g.dash.initialSegmentLimit,a.N);else{var y=b.L.Na,x=b.Z.duration||0;w={$b:function(){return Promise.resolve(bj(m,x,y))}}}}catch(H){if((p||n)&&4002==H.code)return null;
653
+ throw H;}r=Tn(l,"ContentProtection");r=po(r,c,a.g.dash.ignoreDrmInfo,a.g.dash.keySystemsByURI);r=new Set(r?[r]:[]);var v=!1;Tn(l,"SupplementalProperty").some(function(H){return"tag:dolby.com,2018:dash:EC3_ExtensionType:2018"==H.getAttribute("schemeIdUri")&&"JOC"==H.getAttribute("value")})&&(v=!0);var D=!1;p&&(D=h.includes("forced_subtitle")||h.includes("forced-subtitle"));var C;if(n&&((l=Tn(l,"EssentialProperty").find(function(H){return["http://dashif.org/thumbnail_tile","http://dashif.org/guidelines/thumbnail_tile"].includes(H.getAttribute("schemeIdUri"))}))&&
654
+ (C=l.getAttribute("value")),!C))return null;var B;l=b.L.codecs;b.profiles.includes("http://dashif.org/guidelines/dash-if-uhd#hevc-hdr-pq10")&&(l.includes("hvc1.2.4.L153.B0")||l.includes("hev1.2.4.L153.B0"))&&(B="PQ");var G=b.L.id?b.ra.id+","+b.L.id:"",E={id:a.I++,originalId:b.L.id,createSegmentIndex:function(){var H,N,K;return I(function(M){if(1==M.g){N=(H=G&&b.xb&&a.l[G])?a.l[G]:E;if(N.segmentIndex)return M.D(0);K=N;return u(M,w.$b(),3)}K.segmentIndex=M.h;z(M)})},closeSegmentIndex:function(){E.segmentIndex&&
653
655
  (E.segmentIndex.release(),E.segmentIndex=null)},segmentIndex:null,mimeType:b.L.mimeType,codecs:b.L.codecs,frameRate:b.L.frameRate,pixelAspectRatio:b.L.pixelAspectRatio,bandwidth:b.bandwidth,width:b.L.width,height:b.L.height,kind:d,encrypted:0<c.drmInfos.length,drmInfos:c.drmInfos,keyIds:r,language:e,label:f,type:b.Aa.contentType,primary:g,trickModeVideo:null,emsgSchemeIdUris:b.L.emsgSchemeIdUris,roles:h,forced:D,channelsCount:b.L.td,audioSamplingRate:b.L.audioSamplingRate,spatialAudio:v,closedCaptions:k,
654
- hdr:B,tilesLayout:C,matchedStreams:[]};G&&b.xb&&!a.l[G]&&(a.l[G]=E);return E}function Jp(a){var b,c;I(function(d){switch(d.g){case 1:return b=0,A(d,2),u(d,Kp(a),4);case 4:b=d.h;va(d,3);break;case 2:c=F(d),a.h&&(c.severity=1,a.h.onError(c));case 3:if(!a.h)return d["return"]();Lp(a,b);z(d)}})}function Lp(a,b){0>a.H||a.G.T(Math.max(3,a.H-b,ac(a.J)))}
655
- function Rp(a,b,c){b=b||{contentType:"",mimeType:"",codecs:"",emsgSchemeIdUris:[],frameRate:void 0,pixelAspectRatio:void 0,td:null,audioSamplingRate:null,Yb:0};c=c||b.Na;var d=Qn(a,"BaseURL"),e=d.map(Wn),f=a.getAttribute("contentType")||b.contentType,g=a.getAttribute("mimeType")||b.mimeType,h=a.getAttribute("codecs")||b.codecs,k=Yn(a,"frameRate",go)||b.frameRate,l=a.getAttribute("sar")||b.pixelAspectRatio,m=Qn(a,"InbandEventStream"),n=b.emsgSchemeIdUris.slice();m=t(m);for(var p=m.next();!p.done;p=
656
- m.next())p=p.value.getAttribute("schemeIdUri"),n.includes(p)||n.push(p);m=Qn(a,"AudioChannelConfiguration");m=Zp(m)||b.td;p=Yn(a,"audioSamplingRate",eo)||b.audioSamplingRate;f||(f=Wp(g,h));var r=Pn(a,"SegmentBase"),x=Pn(a,"SegmentTemplate"),y=r?Yn(r,"availabilityTimeOffset",fo)||0:0,w=x?Yn(x,"availabilityTimeOffset",fo)||0:0;d=d&&d.length?Yn(d[0],"availabilityTimeOffset",fo)||0:0;d=b.Yb+d+y+w;return{Na:Db(c,e),Sc:r||b.Sc,Db:Pn(a,"SegmentList")||b.Db,Tc:x||b.Tc,width:Yn(a,"width",eo)||b.width,height:Yn(a,
657
- "height",eo)||b.height,contentType:f,mimeType:g,codecs:h,frameRate:k,pixelAspectRatio:l,emsgSchemeIdUris:n,id:a.getAttribute("id"),td:m,audioSamplingRate:p,Yb:d}}
658
- function Zp(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=
659
- 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 Xp(a){var b=a.Sc?1:0;b+=a.Db?1:0;b+=a.Tc?1:0;if(0==b)return a.contentType==Ib||"application"==a.contentType?!0:!1;1!=b&&(a.Sc&&(a.Db=null),a.Tc=null);return!0}
660
- function $p(a,b,c,d){var e,f,g,h,k,l;return I(function(m){if(1==m.g)return e=Db(b,[c]),f=kf(e,a.g.retryParameters),f.method=d,g=a.h.networkingEngine.request(4,f),ef(a.A,g),u(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=Rc(h.data);l=Date.parse(k);return isNaN(l)?m["return"](0):m["return"](l-Date.now())})}
661
- function Pp(a,b,c){var d,e,f,g,h,k,l,m;return I(function(n){switch(n.g){case 1:d=c.map(function(p){return{scheme:p.getAttribute("schemeIdUri"),value:p.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.D(4);break}h=g.value;A(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.D(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.D(8);
662
- 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":Ua("NTP UTCTiming scheme is not supported");break;default:Ua("Unrecognized scheme in UTCTiming element",k)}n.D(9);break;case 7:return u(n,$p(a,b,l,"HEAD"),10);case 10:return n["return"](n.h);case 8:return u(n,$p(a,b,l,"GET"),11);case 11:return n["return"](n.h);
656
+ hdr:B,tilesLayout:C,matchedStreams:[]};G&&b.xb&&!a.l[G]&&(a.l[G]=E);return E}function Mp(a){var b,c;I(function(d){switch(d.g){case 1:return b=0,A(d,2),u(d,Np(a),4);case 4:b=d.h;va(d,3);break;case 2:c=F(d),a.h&&(c.severity=1,a.h.onError(c));case 3:if(!a.h)return d["return"]();Op(a,b);z(d)}})}function Op(a,b){0>a.H||a.G.T(Math.max(3,a.H-b,ac(a.J)))}
657
+ function Up(a,b,c){b=b||{contentType:"",mimeType:"",codecs:"",emsgSchemeIdUris:[],frameRate:void 0,pixelAspectRatio:void 0,td:null,audioSamplingRate:null,Yb:0};c=c||b.Na;var d=Tn(a,"BaseURL"),e=d.map(Zn),f=a.getAttribute("contentType")||b.contentType,g=a.getAttribute("mimeType")||b.mimeType,h=a.getAttribute("codecs")||b.codecs,k=ao(a,"frameRate",jo)||b.frameRate,l=a.getAttribute("sar")||b.pixelAspectRatio,m=Tn(a,"InbandEventStream"),n=b.emsgSchemeIdUris.slice();m=t(m);for(var p=m.next();!p.done;p=
658
+ m.next())p=p.value.getAttribute("schemeIdUri"),n.includes(p)||n.push(p);m=Tn(a,"AudioChannelConfiguration");m=bq(m)||b.td;p=ao(a,"audioSamplingRate",ho)||b.audioSamplingRate;f||(f=Zp(g,h));var r=Sn(a,"SegmentBase"),w=Sn(a,"SegmentTemplate"),y=r?ao(r,"availabilityTimeOffset",io)||0:0,x=w?ao(w,"availabilityTimeOffset",io)||0:0;d=d&&d.length?ao(d[0],"availabilityTimeOffset",io)||0:0;d=b.Yb+d+y+x;return{Na:Db(c,e),Sc:r||b.Sc,Db:Sn(a,"SegmentList")||b.Db,Tc:w||b.Tc,width:ao(a,"width",ho)||b.width,height:ao(a,
659
+ "height",ho)||b.height,contentType:f,mimeType:g,codecs:h,frameRate:k,pixelAspectRatio:l,emsgSchemeIdUris:n,id:a.getAttribute("id"),td:m,audioSamplingRate:p,Yb:d}}
660
+ function bq(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=
661
+ 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 $p(a){var b=a.Sc?1:0;b+=a.Db?1:0;b+=a.Tc?1:0;if(0==b)return a.contentType==Ib||"application"==a.contentType?!0:!1;1!=b&&(a.Sc&&(a.Db=null),a.Tc=null);return!0}
662
+ function cq(a,b,c,d){var e,f,g,h,k,l;return I(function(m){if(1==m.g)return e=Db(b,[c]),f=nf(e,a.g.retryParameters),f.method=d,g=a.h.networkingEngine.request(4,f),hf(a.A,g),u(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=ed(h.data);l=Date.parse(k);return isNaN(l)?m["return"](0):m["return"](l-Date.now())})}
663
+ function Sp(a,b,c){var d,e,f,g,h,k,l,m;return I(function(n){switch(n.g){case 1:d=c.map(function(p){return{scheme:p.getAttribute("schemeIdUri"),value:p.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.D(4);break}h=g.value;A(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.D(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.D(8);
664
+ 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":Ua("NTP UTCTiming scheme is not supported");break;default:Ua("Unrecognized scheme in UTCTiming element",k)}n.D(9);break;case 7:return u(n,cq(a,b,l,"HEAD"),10);case 10:return n["return"](n.h);case 8:return u(n,cq(a,b,l,"GET"),11);case 11:return n["return"](n.h);
663
665
  case 9:va(n,3);break;case 5:F(n);case 3:g=f.next();n.D(2);break;case 4:return Ua("A UTCTiming element should always be given in live manifests! This content may not play on clients with bad clocks!"),n["return"](0)}})}
664
- function Sp(a,b,c,d,e){var f=d.getAttribute("schemeIdUri")||"",g=d.getAttribute("value")||"",h=Yn(d,"timescale",eo)||1;d=t(Qn(d,"Event"));for(var k=d.next();!k.done;k=d.next()){k=k.value;var l=Yn(k,"presentationTime",eo)||0,m=Yn(k,"duration",eo)||0;l=l/h+b;m=l+m/h;null!=c&&(l=Math.min(l,b+c),m=Math.min(m,b+c));m<e||(k={schemeIdUri:f,value:g,startTime:l,endTime:m,id:k.getAttribute("id")||"",eventElement:k},a.h.onTimelineRegionAdded(k))}}
665
- function Yp(a,b,c,d){var e,f,g,h,k;return I(function(l){if(1==l.g)return e=qf,f=oj(b,c,d,a.g.retryParameters),g=a.h.networkingEngine,h=g.request(e,f),ef(a.A,h),u(l,h.promise,2);k=l.h;return l["return"](k.data)})}function Wp(a,b){return pd(jd(a,b))?Ib:a.split("/")[0]}J("shaka.dash.DashParser",Ip);sg.mpd=function(){return new Ip};qg["application/dash+xml"]=function(){return new Ip};qg["video/vnd.mpeg.dash.mpd"]=function(){return new Ip};function aq(a,b,c,d){this.h=a;this.type=b;this.g=c;this.segments=d||null}function bq(a,b,c,d){this.id=a;this.name=b;this.g=c;this.value=void 0===d?null:d}bq.prototype.toString=function(){function a(d){return d.name+"="+(isNaN(Number(d.value))?'"'+d.value+'"':d.value)}var b="#"+this.name,c=this.g?this.g.map(a):[];this.value&&c.unshift(this.value);0<c.length&&(b+=":"+c.join(","));return b};
666
- bq.prototype.getAttribute=function(a){var b=this.g.filter(function(c){return c.name==a});return b.length?b[0]:null};function U(a,b,c){return(a=a.getAttribute(b))?a.value:c||null}function cq(a,b){var c=a.getAttribute(b);if(!c)throw new O(2,4,4023,b);return c.value}function dq(a,b,c){c=void 0===c?[]:c;this.h=b;this.i=a;this.g=c}function eq(a,b){this.name=a;this.value=b};function fq(a,b){return a.filter(function(c){return c.name==b})}function gq(a,b){return a.filter(function(c){return cq(c,"TYPE")==b})}function hq(a,b){var c=fq(a,b);return c.length?c[0]:null}function iq(a){var b=0;b=void 0===b?0:b;return(a=hq(a,"EXT-X-MEDIA-SEQUENCE"))?Number(a.value):b};function jq(a){this.h=a;this.g=0}function kq(a){lq(a,/[ \t]+/gm)}function lq(a,b){b.lastIndex=a.g;var c=b.exec(a.h);c=null==c?null:{position:c.index,length:c[0].length,results:c};if(a.g==a.h.length||null==c||c.position!=a.g)return null;a.g+=c.length;return c.results}function mq(a){return a.g==a.h.length?null:(a=lq(a,/[^ \t\n]*/gm))?a[0]:null};function nq(){this.g=0}
667
- function oq(a,b,c){b=Rc(b);b=b.replace(/\r\n|\r(?=[^\n]|$)/gm,"\n").trim();var d=b.split(/\n+/m);if(!/^#EXTM3U($|[ \t\n])/m.test(d[0]))throw new O(2,4,4015);b=0;for(var e=!0,f=t(d),g=f.next();!g.done;g=f.next())if(g=g.value,/^#(?!EXT)/m.test(g)||e)e=!1;else if(g=pq(a,g),--a.g,qq.includes(g.name)){b=1;break}else"EXT-X-STREAM-INF"==g.name&&(e=!0);f=[];e=!0;for(g=0;g<d.length;g++){var h=d[g],k=d[g+1];if(/^#(?!EXT)/m.test(h)||e)e=!1;else{h=pq(a,h);if(rq.includes(h.name)){if(1!=b)throw new O(2,4,4017);
668
- var l=d.splice(g,d.length-g);d=c;e=[];g=[];k=[];h=null;l=t(l);for(var m=l.next();!m.done;m=l.next())m=m.value,/^(#EXT)/.test(m)?(m=pq(a,m),qq.includes(m.name)?f.push(m):"EXT-X-MAP"==m.name?h=m:"EXT-X-PART"==m.name?k.push(m):"EXT-X-PRELOAD-HINT"==m.name?"PART"==U(m,"TYPE")?k.push(m):"MAP"==U(m,"TYPE")&&(m.name="EXT-X-MAP",h=m):g.push(m)):/^#(?!EXT)/m.test(m)||(m=Db([d],[m.trim()])[0],h&&g.push(h),e.push(new dq(m,g,k)),g=[],k=[]);k.length&&(h&&g.push(h),e.push(new dq("",g,k)));return new aq(c,b,f,e)}f.push(h);
669
- "EXT-X-STREAM-INF"==h.name&&(h.g.push(new eq("URI",k)),e=!0)}}return new aq(c,b,f)}function pq(a,b){var c=a.g++,d=b.match(/^#(EXT[^:]*)(?::(.*))?$/);if(!d)throw new O(2,4,4016,b);var e=d[1],f=d[2];d=[];var g;if(f){f=new jq(f);var h;(h=lq(f,/^([^,=]+)(?:,|$)/g))&&(g=h[1]);for(var k=/([^=]+)=(?:"([^"]*)"|([^",]*))(?:,|$)/g;h=lq(f,k);)d.push(new eq(h[1],h[2]||h[3])),kq(f)}return new bq(c,e,d,g)}
670
- var qq="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".split(" "),rq="EXTINF EXT-X-BYTERANGE EXT-X-DISCONTINUITY EXT-X-PROGRAM-DATE-TIME EXT-X-KEY EXT-X-DATERANGE EXT-X-MAP".split(" ");function sq(){}function tq(a){try{var b=uq(a);return Ye({uri:a,Af:a,data:b.data,headers:{"content-type":b.contentType}})}catch(c){return We(c)}}function uq(a){var b=a.split(":");if(2>b.length||"data"!=b[0])throw new O(2,1,1004,a);b=b.slice(1).join(":").split(",");if(2>b.length)throw new O(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=$c(a):e=Vc(a);return{data:e,contentType:c}}
671
- J("shaka.net.DataUriPlugin",sq);sq.parse=tq;gf("data",tq);function vq(){var a=this;this.h=this.i=null;this.ya=1;this.A=new Map;this.C=new Map;this.ma=new Set;this.g=new Map;this.j=null;this.K="";this.$=new nq;this.ea=0;this.S=!1;this.N=null;this.F=new P(function(){wq(a)});this.m=xq;this.I=null;this.aa=0;this.H=Infinity;this.X=this.ba=0;this.G=new df;this.P=[];this.J=new Map;this.za=!1;this.B=new Map;this.ua=new Map;this.l=!1}q=vq.prototype;q.configure=function(a){this.h=a};
672
- q.start=function(a,b){var c=this,d,e;return I(function(f){if(1==f.g)return c.i=b,c.l=b.isLowLatencyMode(),u(f,yq(c,a),2);if(3!=f.g)return d=f.h,c.K=d.uri,u(f,zq(c,d.data,a),3);e=c.ea;0<e&&c.F.T(e);return f["return"](c.I)})};q.stop=function(){this.F&&(this.F.stop(),this.F=null);var a=[];this.G&&(a.push(this.G.destroy()),this.G=null);this.h=this.i=null;this.ma.clear();this.I=null;this.g.clear();this.C.clear();this.B.clear();this.A.clear();return Promise.all(a)};
673
- q.update=function(){var a=this,b,c,d;return I(function(e){if(1==e.g){if(a.m==xq)return e["return"]();b=[];c=Array.from(a.g.values());return c.length?u(e,Aq(a,c[0]),2):e.D(2)}for(d=1;d<c.length;d++)b.push(Aq(a,c[d]));return u(e,Promise.all(b),0)})};
674
- function Aq(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,x;return I(function(y){if(1==y.g)return c=Bq,d=b.Sf,e=new lb(d),a.l&&b.Xf&&ob(e,new rb("_HLS_skip=YES")),u(y,yq(a,e.toString()),2);f=y.h;g=oq(a.$,f.data,f.uri);if(1!=g.type)throw new O(2,4,4017);h=fq(g.g,"EXT-X-DEFINE");k=Cq(a,h);l=b.stream;m=Dq(a,g,l.type,b.Lc,k);l.segmentIndex.hc(m,a.j.ob());m.length&&(n=iq(g.g),p=b.Lc.get(n),l.segmentIndex.Gb(p));r=m[m.length-1];if(x=hq(g.g,"EXT-X-ENDLIST"))Eq(a,c.Rf),a.j.bb(r.endTime);z(y)})}q.onExpirationUpdated=function(){};
675
- function Fq(a){if(!a.S){for(var b=-1,c=new Map,d=t(a.g.values()),e=d.next();!e.done;e=d.next()){e=e.value;var f=e.stream.segmentIndex;if(f&&(f=f.M[0]||null))for(var g=t(e.Lc),h=g.next();!h.done;h=g.next()){h=t(h.value);var k=h.next().value;if(h.next().value==f.startTime){c.set(e,k);b=Math.max(b,k);break}}}if(!(0>b)){a.N=b;b=t(a.g.values());for(e=b.next();!e.done;e=b.next())if(d=e.value,e=d.stream.segmentIndex)f=a.N-c.get(d),e.M.splice(0,f),(e=e.M[0]||null)&&Gq(d,-e.startTime);a.S=!0}}}
676
- function Hq(a){if(!a.S){for(var b=Infinity,c=t(a.g.values()),d=c.next();!d.done;d=c.next())if(d=d.value.stream.segmentIndex)d=d.M[0]||null,null!=d&&null!=d.g&&(b=Math.min(b,d.g));if(Infinity!=b){c=t(a.g.values());for(d=c.next();!d.done;d=c.next()){d=d.value;var e=d.stream.segmentIndex;null!=e&&(e=e.M[0]||null,null==e.g?Ta("Missing EXT-X-PROGRAM-DATE-TIME for stream",d.Gd,"Expect AV sync issues!"):Gq(d,e.g-b-e.startTime))}a.S=!0}}}
677
- function Gq(a,b){a.stream.segmentIndex.offset(b);a.ge+=b;for(var c=t(a.Lc),d=c.next();!d.done;d=c.next()){var e=t(d.value);d=e.next().value;e=e.next().value;a.Lc.set(d,e+b)}}
678
- function zq(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,x,y,w,v,D,C,B,G,E,H,L,K,N,V,Z,ha,ja,xa,La,Fa,Ra,Ga,qc,Qc,Cd,Dd,qb,Ed,rc,De;return I(function(ab){switch(ab.g){case 1:d=oq(a.$,b,a.K);e=fq(d.g,"EXT-X-DEFINE");Iq(a,e);f=[];g=[];h=[];if(1==d.type)return G=a.h.hls.mediaPlaylistFullMimeType,E=G.split(";")[0],H=E.split("/")[0],L=nd(G),K=new Map,u(ab,Jq(a,d,c,c,L,H,"",!0,"Media Playlist",null,K,null,!1,!1,E),8);k=fq(d.g,"EXT-X-MEDIA");l=fq(d.g,"EXT-X-STREAM-INF");m=fq(d.g,"EXT-X-IMAGE-STREAM-INF");Kq(a,l);n=
679
- fq(d.g,"EXT-X-SESSION-DATA");p=t(n);for(r=p.next();!r.done;r=p.next())if(x=r.value,y=U(x,"DATA-ID"),w=U(x,"URI"),v=U(x,"LANGUAGE"),D=U(x,"VALUE"),C=(new Map).set("id",y),w&&C.set("uri",Db([a.K],[w])[0]),v&&C.set("language",v),D&&C.set("value",D),B=new M("sessiondata",C),a.i)a.i.onEvent(B);return u(ab,Lq(a,k),4);case 4:return Mq(a,k),u(ab,Nq(a,l),5);case 5:return f=ab.h,u(ab,Oq(a,k),6);case 6:return g=ab.h,u(ab,Pq(a,m),7);case 7:h=ab.h;ab.D(3);break;case 8:N=ab.h,a.g.set(c,N),f.push({id:0,language:"und",
680
- disabledUntilTime:0,primary:!0,audio:"audio"==H?N.stream:null,video:"video"==H?N.stream:null,bandwidth:0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});case 3:if(!a.i)throw new O(2,7,7001);a.h.hls.ignoreManifestProgramDateTime?Fq(a):Hq(a);if(a.za&&0==f.length)throw new O(2,4,4034);V=Infinity;Z=t(a.g.values());for(ha=Z.next();!ha.done;ha=Z.next())ja=ha.value,"text"!=ja.stream.type&&(V=Math.min(V,ja.ge));a.m!=xq?(a.j=new Q(0,a.h.defaultPresentationDelay?a.h.defaultPresentationDelay:
681
- a.X?a.X:3*a.aa),a.j.Uc(!1)):(a.j=new Q(null,0),a.j.Uc(!0));Qq(a);if(a.m!=xq)a.ea=a.H,xa=Bq,a.m==xa.We&&(La=a.j.zd,isNaN(a.h.availabilityWindowOverride)||(La=a.h.availabilityWindowOverride),a.j.Ge(La));else for(a.j.bb(V),Fa=t(a.g.values()),ha=Fa.next();!ha.done;ha=Fa.next())Ra=ha.value,Ra.stream.segmentIndex.yb(0,V);a.P=[];Ga=[];qc=t(f);for(Qc=qc.next();!Qc.done;Qc=qc.next())for(Cd=Qc.value,Dd=t([Cd.video,Cd.audio]),qb=Dd.next();!qb.done;qb=Dd.next())(Ed=qb.value)&&Ga.push(Ed);return u(ab,Promise.all(Ga.map(function(ig){return I(function(jg){return u(jg,
682
- ig.createSegmentIndex(),0)})})),9);case 9:rc=t(Ga);for(qb=rc.next();!qb.done;qb=rc.next())De=qb.value,a.P.push(De.segmentIndex.M);Qq(a);a.I={presentationTimeline:a.j,variants:f,textStreams:g,imageStreams:h,offlineSessionIds:[],minBufferTime:0,sequenceMode:!0};a.i.makeTextStreamsForClosedCaptions(a.I);z(ab)}})}function Iq(a,b){for(var c=t(b),d=c.next();!d.done;d=c.next()){var e=d.value;d=U(e,"NAME");e=U(e,"VALUE");d&&e&&(a.A.has(d)||a.A.set(d,e))}}
683
- function Cq(a,b){for(var c=new Map,d=t(b),e=d.next();!e.done;e=d.next()){var f=e.value;e=U(f,"NAME");var g=U(f,"VALUE");f=U(f,"IMPORT");e&&g&&c.set(e,g);f&&(e=a.A.get(f))&&c.set(f,e)}return c}function Kq(a,b){for(var c=t(b),d=c.next();!d.done;d=c.next()){var e=d.value,f=U(e,"AUDIO");d=U(e,"VIDEO");var g=U(e,"SUBTITLES");e=Rq(a,e);if(g){var h=Gb(Ib,e);a.B.set(g,h);dc(e,h)}f&&(g=Fb("audio",e),a.B.set(f,g));d&&(f=Fb("video",e),a.B.set(d,f))}}
684
- function Oq(a,b){var c,d,e,f,g,h,k,l,m,n,p,r;return I(function(x){if(1==x.g)return c=gq(b,"SUBTITLES"),d=c.map(function(y){var w,v,D;return I(function(C){if(1==C.g){if(w=a.h.disableText)return C["return"](null);A(C,2);return u(C,Sq(a,y),4)}if(2!=C.g)return v=C.h,C["return"](v.stream);D=F(C);if(a.h.hls.ignoreTextStreamFailures)return C["return"](null);throw D;})}),u(x,Promise.all(d),2);e=x.h;f=t(c);for(g=f.next();!g.done;g=f.next())if(h=g.value,k=cq(h,"GROUP-ID"),l=a.B.get(k))if(m=a.C.get(k))for(n=
685
- t(m),p=n.next();!p.done;p=n.next())r=p.value,r.stream.codecs=l;return x["return"](e.filter(function(y){return y}))})}
686
- function Pq(a,b){var c,d;return I(function(e){if(1==e.g)return c=b.map(function(f){var g,h,k;return I(function(l){if(1==l.g){if(g=a.h.disableThumbnails)return l["return"](null);A(l,2);return u(l,Tq(a,f),4)}if(2!=l.g)return h=l.h,l["return"](h.stream);k=F(l);if(a.h.hls.ignoreImageStreamFailures)return l["return"](null);throw k;})}),u(e,Promise.all(c),2);d=e.h;return e["return"](d.filter(function(f){return f}))})}
687
- function Lq(a,b){var c;return I(function(d){b=b.filter(function(e){var f=U(e,"URI")||"";return"SUBTITLES"!=U(e,"TYPE")&&""!=f});c=b.map(function(e){return Sq(a,e)});return u(d,Promise.all(c),0)})}
688
- function Nq(a,b){var c,d,e;return I(function(f){if(1==f.g)return c=b.map(function(g){var h,k,l,m,n,p,r,x;return I(function(y){if(1==y.g)return h=U(g,"FRAME-RATE"),k=Number(U(g,"AVERAGE-BANDWIDTH"))||Number(cq(g,"BANDWIDTH")),l=U(g,"RESOLUTION"),m=t(l?l.split("x"):[null,null]),n=m.next().value,p=m.next().value,r=U(g,"VIDEO-RANGE"),u(y,Uq(a,g),2);if(x=y.h){for(var w=y["return"],v=x.audio,D=x.video,C=t(D),B=C.next();!B.done;B=C.next())if(B=B.value.stream)B.width=Number(n)||void 0,B.height=Number(p)||
689
- void 0,B.frameRate=Number(h)||void 0,B.hdr=r||void 0;C=a.h.disableAudio;if(!v.length||C)v=[null];C=a.h.disableVideo;if(!D.length||C)D=[null];C=[];v=t(v);for(B=v.next();!B.done;B=v.next()){B=B.value;for(var G=t(D),E=G.next();!E.done;E=G.next()){var H=E.value;E=B?B.stream:null;var L=H?H.stream:null,K=B?B.stream.drmInfos:null,N=H?H.stream.drmInfos:null;H=(H?H.Gd:"")+" - "+(B?B.Gd:"");E&&L&&K.length&&N.length&&!(0<mg(K,N).length)||a.ma.has(H)||(E={id:a.ya++,language:E?E.language:"und",primary:!!E&&E.primary||
690
- !!L&&L.primary,audio:E,video:L,bandwidth:k,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},C.push(E),a.ma.add(H))}}y=w.call(y,C)}else y=y["return"]([]);return y})}),u(f,Promise.all(c),2);d=f.h;e=d.reduce(Ab,[]);e=e.filter(function(g){return null!=g});return f["return"](e)})}
691
- function Uq(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,x,y;return I(function(w){if(1==w.g)return c=Jb,d=Rq(a,b),e=U(b,"AUDIO"),f=U(b,"VIDEO"),h=(g=e||f)&&a.C.has(g)?a.C.get(g):[],k={audio:e?h:[],video:f?h:[]},m=!1,n=cq(b,"URI"),p=k.audio.find(function(v){return v&&v.Gd==n}),r=Gb(c.Ma,d),(x=Gb(c.Fb,d))&&!r?l=c.Fb:!h.length&&x&&r?(l=c.Ma,d=[[r,x].join()]):k.audio.length&&p?(l=c.Fb,m=!0):l=k.video.length?c.Fb:c.Ma,m?w.D(2):u(w,Vq(a,b,d,l),3);2!=w.g&&(y=w.h);if(y)k[y.stream.type]=[y];else if(null===y)return w["return"](null);
692
- Wq(k);return w["return"](k)})}function Rq(a,b){var c=[];a.h.disableVideo||c.push(a.h.hls.defaultVideoCodec);a.h.disableAudio||c.push(a.h.hls.defaultAudioCodec);var d=U(b,"CODECS",c.join(",")).split(/\s*,\s*/);c=new Set;var e=[];d=t(d);for(var f=d.next();!f.done;f=d.next()){f=f.value;var g=md(f)[0];c.has(g)||(e.push(f),c.add(g))}return e}function Xq(a){a=U(a,"LANGUAGE")||"und";return Mb(a)}
693
- function Wq(a){a=t(a.audio.concat(a.video));for(var b=a.next();!b.done;b=a.next())if(b=b.value){var c=b.stream.codecs.split(",");c=c.filter(function(d){return"mp4a.40.34"!=d});b.stream.codecs=c.join(",")}}function Mq(a,b){var c=gq(b,"CLOSED-CAPTIONS");c=t(c);for(var d=c.next();!d.done;d=c.next()){var e=d.value;d=Xq(e);var f=cq(e,"GROUP-ID");e=cq(e,"INSTREAM-ID");a.J.get(f)||a.J.set(f,new Map);a.J.get(f).set(e,d)}}
694
- function Sq(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,x,y;return I(function(w){if(1==w.g){c=cq(b,"GROUP-ID");d="";var v=cq(b,"TYPE").toLowerCase();"subtitles"==v&&(v=Ib);e=v;e!=Ib&&c&&a.B.has(c)&&(d=a.B.get(c));f=Yq(cq(b,"URI"),a.A);if(a.g.has(f))return w["return"](a.g.get(f));g=Xq(b);h=U(b,"NAME");k=U(b,"DEFAULT");l="YES"==k;"audio"==e?v=(v=U(b,"CHANNELS"))?parseInt(v.split("/")[0],10):null:v=null;m=v;"audio"==e?v=(v=U(b,"CHANNELS"))?v.includes("/JOC"):!1:v=!1;n=v;p=U(b,"CHARACTERISTICS");r=U(b,"FORCED");
695
- x="YES"==r;return u(w,Zq(a,f,d,e,g,l,h,m,null,p,x,n),2)}y=w.h;a.C.has(c)?a.C.get(c).push(y):a.C.set(c,[y]);if(null==y)return w["return"](null);if(a.g.has(f))return w["return"](a.g.get(f));a.g.set(f,y);return w["return"](y)})}
696
- function Tq(a,b){var c,d,e,f,g,h,k,l,m,n;return I(function(p){if(1==p.g){c=Yq(cq(b,"URI"),a.A);d=U(b,"CODECS","jpeg")||"";if(a.g.has(c))return p["return"](a.g.get(c));e=Xq(b);f=U(b,"NAME");g=U(b,"CHARACTERISTICS");return u(p,Zq(a,c,d,"image",e,!1,f,null,null,g,!1,!1),2)}h=p.h;if(null==h)return p["return"](null);if(a.g.has(c))return p["return"](a.g.get(c));if(k=U(b,"RESOLUTION"))if(l=h.stream.segmentIndex.get(0),m=l.tilesLayout)h.stream.width=Number(k.split("x")[0])*Number(m.split("x")[0]),h.stream.height=
666
+ function Vp(a,b,c,d,e){var f=d.getAttribute("schemeIdUri")||"",g=d.getAttribute("value")||"",h=ao(d,"timescale",ho)||1;d=t(Tn(d,"Event"));for(var k=d.next();!k.done;k=d.next()){k=k.value;var l=ao(k,"presentationTime",ho)||0,m=ao(k,"duration",ho)||0;l=l/h+b;m=l+m/h;null!=c&&(l=Math.min(l,b+c),m=Math.min(m,b+c));m<e||(k={schemeIdUri:f,value:g,startTime:l,endTime:m,id:k.getAttribute("id")||"",eventElement:k},a.h.onTimelineRegionAdded(k))}}
667
+ function aq(a,b,c,d){var e,f,g,h,k;return I(function(l){if(1==l.g)return e=tf,f=rj(b,c,d,a.g.retryParameters),g=a.h.networkingEngine,h=g.request(e,f),hf(a.A,h),u(l,h.promise,2);k=l.h;return l["return"](k.data)})}function Zp(a,b){return Hd(yd(a,b))?Ib:a.split("/")[0]}J("shaka.dash.DashParser",Lp);vg.mpd=function(){return new Lp};tg["application/dash+xml"]=function(){return new Lp};tg["video/vnd.mpeg.dash.mpd"]=function(){return new Lp};function dq(a,b,c,d){this.h=a;this.type=b;this.g=c;this.segments=d||null}function eq(a,b,c,d){this.id=a;this.name=b;this.g=c;this.value=void 0===d?null:d}eq.prototype.toString=function(){function a(d){return d.name+"="+(isNaN(Number(d.value))?'"'+d.value+'"':d.value)}var b="#"+this.name,c=this.g?this.g.map(a):[];this.value&&c.unshift(this.value);0<c.length&&(b+=":"+c.join(","));return b};
668
+ eq.prototype.getAttribute=function(a){var b=this.g.filter(function(c){return c.name==a});return b.length?b[0]:null};function U(a,b,c){return(a=a.getAttribute(b))?a.value:c||null}function fq(a,b){var c=a.getAttribute(b);if(!c)throw new O(2,4,4023,b);return c.value}function gq(a,b,c){c=void 0===c?[]:c;this.h=b;this.i=a;this.g=c}function hq(a,b){this.name=a;this.value=b};function iq(a,b){return a.filter(function(c){return c.name==b})}function jq(a,b){return a.filter(function(c){return fq(c,"TYPE")==b})}function kq(a,b){var c=iq(a,b);return c.length?c[0]:null}function lq(a){var b=0;b=void 0===b?0:b;return(a=kq(a,"EXT-X-MEDIA-SEQUENCE"))?Number(a.value):b};function mq(a){this.h=a;this.g=0}function nq(a){oq(a,/[ \t]+/gm)}function oq(a,b){b.lastIndex=a.g;var c=b.exec(a.h);c=null==c?null:{position:c.index,length:c[0].length,results:c};if(a.g==a.h.length||null==c||c.position!=a.g)return null;a.g+=c.length;return c.results}function pq(a){return a.g==a.h.length?null:(a=oq(a,/[^ \t\n]*/gm))?a[0]:null};function qq(){this.g=0}
669
+ function rq(a,b,c){b=ed(b);b=b.replace(/\r\n|\r(?=[^\n]|$)/gm,"\n").trim();var d=b.split(/\n+/m);if(!/^#EXTM3U($|[ \t\n])/m.test(d[0]))throw new O(2,4,4015);b=0;for(var e=!0,f=t(d),g=f.next();!g.done;g=f.next())if(g=g.value,/^#(?!EXT)/m.test(g)||e)e=!1;else if(g=sq(a,g),--a.g,tq.includes(g.name)){b=1;break}else"EXT-X-STREAM-INF"==g.name&&(e=!0);f=[];e=!0;for(g=0;g<d.length;g++){var h=d[g],k=d[g+1];if(/^#(?!EXT)/m.test(h)||e)e=!1;else{h=sq(a,h);if(uq.includes(h.name)){if(1!=b)throw new O(2,4,4017);
670
+ var l=d.splice(g,d.length-g);d=c;e=[];g=[];k=[];h=null;l=t(l);for(var m=l.next();!m.done;m=l.next())m=m.value,/^(#EXT)/.test(m)?(m=sq(a,m),tq.includes(m.name)?f.push(m):"EXT-X-MAP"==m.name?h=m:"EXT-X-PART"==m.name?k.push(m):"EXT-X-PRELOAD-HINT"==m.name?"PART"==U(m,"TYPE")?k.push(m):"MAP"==U(m,"TYPE")&&(m.name="EXT-X-MAP",h=m):g.push(m)):/^#(?!EXT)/m.test(m)||(m=Db([d],[m.trim()])[0],h&&g.push(h),e.push(new gq(m,g,k)),g=[],k=[]);k.length&&(h&&g.push(h),e.push(new gq("",g,k)));return new dq(c,b,f,e)}f.push(h);
671
+ "EXT-X-STREAM-INF"==h.name&&(h.g.push(new hq("URI",k)),e=!0)}}return new dq(c,b,f)}function sq(a,b){var c=a.g++,d=b.match(/^#(EXT[^:]*)(?::(.*))?$/);if(!d)throw new O(2,4,4016,b);var e=d[1],f=d[2];d=[];var g;if(f){f=new mq(f);var h;(h=oq(f,/^([^,=]+)(?:,|$)/g))&&(g=h[1]);for(var k=/([^=]+)=(?:"([^"]*)"|([^",]*))(?:,|$)/g;h=oq(f,k);)d.push(new hq(h[1],h[2]||h[3])),nq(f)}return new eq(c,e,d,g)}
672
+ var tq="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".split(" "),uq="EXTINF EXT-X-BYTERANGE EXT-X-DISCONTINUITY EXT-X-PROGRAM-DATE-TIME EXT-X-KEY EXT-X-DATERANGE EXT-X-MAP".split(" ");function vq(){}function wq(a){try{var b=xq(a);return af({uri:a,Bf:a,data:b.data,headers:{"content-type":b.contentType}})}catch(c){return Ze(c)}}function xq(a){var b=a.split(":");if(2>b.length||"data"!=b[0])throw new O(2,1,1004,a);b=b.slice(1).join(":").split(",");if(2>b.length)throw new O(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=od(a):e=id(a);return{data:e,contentType:c}}
673
+ J("shaka.net.DataUriPlugin",vq);vq.parse=wq;kf("data",wq);function yq(){var a=this;this.h=this.j=null;this.ya=1;this.A=new Map;this.C=new Map;this.ma=new Set;this.g=new Map;this.i=null;this.K="";this.$=new qq;this.ea=0;this.S=!1;this.N=null;this.F=new P(function(){zq(a)});this.m=Aq;this.I=null;this.aa=0;this.H=Infinity;this.X=this.ba=0;this.G=new gf;this.P=[];this.J=new Map;this.za=!1;this.B=new Map;this.ua=new Map;this.l=!1}q=yq.prototype;q.configure=function(a){this.h=a};
674
+ q.start=function(a,b){var c=this,d,e;return I(function(f){if(1==f.g)return c.j=b,c.l=b.isLowLatencyMode(),u(f,Bq(c,a),2);if(3!=f.g)return d=f.h,c.K=d.uri,u(f,Cq(c,d.data,a),3);e=c.ea;0<e&&c.F.T(e);return f["return"](c.I)})};q.stop=function(){this.F&&(this.F.stop(),this.F=null);var a=[];this.G&&(a.push(this.G.destroy()),this.G=null);this.h=this.j=null;this.ma.clear();this.I=null;this.g.clear();this.C.clear();this.B.clear();this.A.clear();return Promise.all(a)};
675
+ q.update=function(){var a=this,b,c,d;return I(function(e){if(1==e.g){if(a.m==Aq)return e["return"]();b=[];c=Array.from(a.g.values());return c.length?u(e,Dq(a,c[0]),2):e.D(2)}for(d=1;d<c.length;d++)b.push(Dq(a,c[d]));return u(e,Promise.all(b),0)})};
676
+ function Dq(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,w;return I(function(y){if(1==y.g)return c=Eq,d=b.Tf,e=new lb(d),a.l&&b.Yf&&ob(e,new rb("_HLS_skip=YES")),u(y,Bq(a,e.toString()),2);f=y.h;g=rq(a.$,f.data,f.uri);if(1!=g.type)throw new O(2,4,4017);h=iq(g.g,"EXT-X-DEFINE");k=Fq(a,h);l=b.stream;m=Gq(a,g,l.type,b.Lc,k);l.segmentIndex.hc(m,a.i.ob());m.length&&(n=lq(g.g),p=b.Lc.get(n),l.segmentIndex.Gb(p));r=m[m.length-1];if(w=kq(g.g,"EXT-X-ENDLIST"))Hq(a,c.Sf),a.i.bb(r.endTime);z(y)})}q.onExpirationUpdated=function(){};
677
+ function Iq(a){if(!a.S){for(var b=-1,c=new Map,d=t(a.g.values()),e=d.next();!e.done;e=d.next()){e=e.value;var f=e.stream.segmentIndex;if(f&&(f=f.M[0]||null))for(var g=t(e.Lc),h=g.next();!h.done;h=g.next()){h=t(h.value);var k=h.next().value;if(h.next().value==f.startTime){c.set(e,k);b=Math.max(b,k);break}}}if(!(0>b)){a.N=b;b=t(a.g.values());for(e=b.next();!e.done;e=b.next())if(d=e.value,e=d.stream.segmentIndex)f=a.N-c.get(d),e.M.splice(0,f),(e=e.M[0]||null)&&Jq(d,-e.startTime);a.S=!0}}}
678
+ function Kq(a){if(!a.S){for(var b=Infinity,c=t(a.g.values()),d=c.next();!d.done;d=c.next())if(d=d.value.stream.segmentIndex)d=d.M[0]||null,null!=d&&null!=d.g&&(b=Math.min(b,d.g));if(Infinity!=b){c=t(a.g.values());for(d=c.next();!d.done;d=c.next()){d=d.value;var e=d.stream.segmentIndex;null!=e&&(e=e.M[0]||null,null==e.g?Ta("Missing EXT-X-PROGRAM-DATE-TIME for stream",d.Gd,"Expect AV sync issues!"):Jq(d,e.g-b-e.startTime))}a.S=!0}}}
679
+ function Jq(a,b){a.stream.segmentIndex.offset(b);a.ie+=b;for(var c=t(a.Lc),d=c.next();!d.done;d=c.next()){var e=t(d.value);d=e.next().value;e=e.next().value;a.Lc.set(d,e+b)}}
680
+ function Cq(a,b,c){var d,e,f,g,h,k,l,m,n,p,r,w,y,x,v,D,C,B,G,E,H,N,K,M,V,Z,ha,ja,xa,La,Fa,Sa,Ga,rc,Qc,Cd,Dd,qb,Ed,sc,De;return I(function(ab){switch(ab.g){case 1:d=rq(a.$,b,a.K);e=iq(d.g,"EXT-X-DEFINE");Lq(a,e);f=[];g=[];h=[];if(1==d.type)return G=a.h.hls.mediaPlaylistFullMimeType,E=G.split(";")[0],H=E.split("/")[0],N=Fd(G),K=new Map,u(ab,Mq(a,d,c,c,N,H,"",!0,"Media Playlist",null,K,null,!1,!1,E),8);k=iq(d.g,"EXT-X-MEDIA");l=iq(d.g,"EXT-X-STREAM-INF");m=iq(d.g,"EXT-X-IMAGE-STREAM-INF");Nq(a,l);n=
681
+ iq(d.g,"EXT-X-SESSION-DATA");p=t(n);for(r=p.next();!r.done;r=p.next())if(w=r.value,y=U(w,"DATA-ID"),x=U(w,"URI"),v=U(w,"LANGUAGE"),D=U(w,"VALUE"),C=(new Map).set("id",y),x&&C.set("uri",Db([a.K],[x])[0]),v&&C.set("language",v),D&&C.set("value",D),B=new L("sessiondata",C),a.j)a.j.onEvent(B);return u(ab,Oq(a,k),4);case 4:return Pq(a,k),u(ab,Qq(a,l),5);case 5:return f=ab.h,u(ab,Rq(a,k),6);case 6:return g=ab.h,u(ab,Sq(a,m),7);case 7:h=ab.h;ab.D(3);break;case 8:M=ab.h,a.g.set(c,M),f.push({id:0,language:"und",
682
+ disabledUntilTime:0,primary:!0,audio:"audio"==H?M.stream:null,video:"video"==H?M.stream:null,bandwidth:0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});case 3:if(!a.j)throw new O(2,7,7001);a.h.hls.ignoreManifestProgramDateTime?Iq(a):Kq(a);if(a.za&&0==f.length)throw new O(2,4,4034);V=Infinity;Z=t(a.g.values());for(ha=Z.next();!ha.done;ha=Z.next())ja=ha.value,"text"!=ja.stream.type&&(V=Math.min(V,ja.ie));a.m!=Aq?(a.i=new Q(0,a.h.defaultPresentationDelay?a.h.defaultPresentationDelay:
683
+ a.X?a.X:3*a.aa),a.i.Uc(!1)):(a.i=new Q(null,0),a.i.Uc(!0));if(a.m!=Aq)a.ea=a.H,xa=Eq,a.m==xa.Xe&&(La=a.i.zd,isNaN(a.h.availabilityWindowOverride)||(La=a.h.availabilityWindowOverride),a.i.He(La));else for(a.i.bb(V),Fa=t(a.g.values()),ha=Fa.next();!ha.done;ha=Fa.next())Sa=ha.value,Sa.stream.segmentIndex.yb(0,V);a.P=[];Ga=[];rc=t(f);for(Qc=rc.next();!Qc.done;Qc=rc.next())for(Cd=Qc.value,Dd=t([Cd.video,Cd.audio]),qb=Dd.next();!qb.done;qb=Dd.next())(Ed=qb.value)&&Ga.push(Ed);return u(ab,Promise.all(Ga.map(function(jg){return I(function(kg){return u(kg,
684
+ jg.createSegmentIndex(),0)})})),9);case 9:sc=t(Ga);for(qb=sc.next();!qb.done;qb=sc.next())De=qb.value,a.P.push(De.segmentIndex.M);Tq(a);a.i.ge();a.I={presentationTimeline:a.i,variants:f,textStreams:g,imageStreams:h,offlineSessionIds:[],minBufferTime:0,sequenceMode:!0};a.j.makeTextStreamsForClosedCaptions(a.I);z(ab)}})}function Lq(a,b){for(var c=t(b),d=c.next();!d.done;d=c.next()){var e=d.value;d=U(e,"NAME");e=U(e,"VALUE");d&&e&&(a.A.has(d)||a.A.set(d,e))}}
685
+ function Fq(a,b){for(var c=new Map,d=t(b),e=d.next();!e.done;e=d.next()){var f=e.value;e=U(f,"NAME");var g=U(f,"VALUE");f=U(f,"IMPORT");e&&g&&c.set(e,g);f&&(e=a.A.get(f))&&c.set(f,e)}return c}function Nq(a,b){for(var c=t(b),d=c.next();!d.done;d=c.next()){var e=d.value,f=U(e,"AUDIO");d=U(e,"VIDEO");var g=U(e,"SUBTITLES");e=Uq(a,e);if(g){var h=Gb(Ib,e);a.B.set(g,h);dc(e,h)}f&&(g=Fb("audio",e),a.B.set(f,g));d&&(f=Fb("video",e),a.B.set(d,f))}}
686
+ function Rq(a,b){var c,d,e,f,g,h,k,l,m,n,p,r;return I(function(w){if(1==w.g)return c=jq(b,"SUBTITLES"),d=c.map(function(y){var x,v,D;return I(function(C){if(1==C.g){if(x=a.h.disableText)return C["return"](null);A(C,2);return u(C,Vq(a,y),4)}if(2!=C.g)return v=C.h,C["return"](v.stream);D=F(C);if(a.h.hls.ignoreTextStreamFailures)return C["return"](null);throw D;})}),u(w,Promise.all(d),2);e=w.h;f=t(c);for(g=f.next();!g.done;g=f.next())if(h=g.value,k=fq(h,"GROUP-ID"),l=a.B.get(k))if(m=a.C.get(k))for(n=
687
+ t(m),p=n.next();!p.done;p=n.next())r=p.value,r.stream.codecs=l;return w["return"](e.filter(function(y){return y}))})}
688
+ function Sq(a,b){var c,d;return I(function(e){if(1==e.g)return c=b.map(function(f){var g,h,k;return I(function(l){if(1==l.g){if(g=a.h.disableThumbnails)return l["return"](null);A(l,2);return u(l,Wq(a,f),4)}if(2!=l.g)return h=l.h,l["return"](h.stream);k=F(l);if(a.h.hls.ignoreImageStreamFailures)return l["return"](null);throw k;})}),u(e,Promise.all(c),2);d=e.h;return e["return"](d.filter(function(f){return f}))})}
689
+ function Oq(a,b){var c;return I(function(d){b=b.filter(function(e){var f=U(e,"URI")||"";return"SUBTITLES"!=U(e,"TYPE")&&""!=f});c=b.map(function(e){return Vq(a,e)});return u(d,Promise.all(c),0)})}
690
+ function Qq(a,b){var c,d,e;return I(function(f){if(1==f.g)return c=b.map(function(g){var h,k,l,m,n,p,r,w;return I(function(y){if(1==y.g)return h=U(g,"FRAME-RATE"),k=Number(U(g,"AVERAGE-BANDWIDTH"))||Number(fq(g,"BANDWIDTH")),l=U(g,"RESOLUTION"),m=t(l?l.split("x"):[null,null]),n=m.next().value,p=m.next().value,r=U(g,"VIDEO-RANGE"),u(y,Xq(a,g),2);if(w=y.h){for(var x=y["return"],v=w.audio,D=w.video,C=t(D),B=C.next();!B.done;B=C.next())if(B=B.value.stream)B.width=Number(n)||void 0,B.height=Number(p)||
691
+ void 0,B.frameRate=Number(h)||void 0,B.hdr=r||void 0;C=a.h.disableAudio;if(!v.length||C)v=[null];C=a.h.disableVideo;if(!D.length||C)D=[null];C=[];v=t(v);for(B=v.next();!B.done;B=v.next()){B=B.value;for(var G=t(D),E=G.next();!E.done;E=G.next()){var H=E.value;E=B?B.stream:null;var N=H?H.stream:null,K=B?B.stream.drmInfos:null,M=H?H.stream.drmInfos:null;H=(H?H.Gd:"")+" - "+(B?B.Gd:"");E&&N&&K.length&&M.length&&!(0<pg(K,M).length)||a.ma.has(H)||(E={id:a.ya++,language:E?E.language:"und",primary:!!E&&E.primary||
692
+ !!N&&N.primary,audio:E,video:N,bandwidth:k,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]},C.push(E),a.ma.add(H))}}y=x.call(y,C)}else y=y["return"]([]);return y})}),u(f,Promise.all(c),2);d=f.h;e=d.reduce(Ab,[]);e=e.filter(function(g){return null!=g});return f["return"](e)})}
693
+ function Xq(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,w,y;return I(function(x){if(1==x.g)return c=Jb,d=Uq(a,b),e=U(b,"AUDIO"),f=U(b,"VIDEO"),h=(g=e||f)&&a.C.has(g)?a.C.get(g):[],k={audio:e?h:[],video:f?h:[]},m=!1,n=fq(b,"URI"),p=k.audio.find(function(v){return v&&v.Gd==n}),r=Gb(c.Ma,d),(w=Gb(c.Fb,d))&&!r?l=c.Fb:!h.length&&w&&r?(l=c.Ma,d=[[r,w].join()]):k.audio.length&&p?(l=c.Fb,m=!0):l=k.video.length?c.Fb:c.Ma,m?x.D(2):u(x,Yq(a,b,d,l),3);2!=x.g&&(y=x.h);if(y)k[y.stream.type]=[y];else if(null===y)return x["return"](null);
694
+ Zq(k);return x["return"](k)})}function Uq(a,b){var c=[];a.h.disableVideo||c.push(a.h.hls.defaultVideoCodec);a.h.disableAudio||c.push(a.h.hls.defaultAudioCodec);var d=U(b,"CODECS",c.join(",")).split(/\s*,\s*/);c=new Set;var e=[];d=t(d);for(var f=d.next();!f.done;f=d.next()){f=f.value;var g=Bd(f)[0];c.has(g)||(e.push(f),c.add(g))}return e}function $q(a){a=U(a,"LANGUAGE")||"und";return Mb(a)}
695
+ function Zq(a){a=t(a.audio.concat(a.video));for(var b=a.next();!b.done;b=a.next())if(b=b.value){var c=b.stream.codecs.split(",");c=c.filter(function(d){return"mp4a.40.34"!=d});b.stream.codecs=c.join(",")}}function Pq(a,b){var c=jq(b,"CLOSED-CAPTIONS");c=t(c);for(var d=c.next();!d.done;d=c.next()){var e=d.value;d=$q(e);var f=fq(e,"GROUP-ID");e=fq(e,"INSTREAM-ID");a.J.get(f)||a.J.set(f,new Map);a.J.get(f).set(e,d)}}
696
+ function Vq(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,w,y;return I(function(x){if(1==x.g){c=fq(b,"GROUP-ID");d="";var v=fq(b,"TYPE").toLowerCase();"subtitles"==v&&(v=Ib);e=v;e!=Ib&&c&&a.B.has(c)&&(d=a.B.get(c));f=ar(fq(b,"URI"),a.A);if(a.g.has(f))return x["return"](a.g.get(f));g=$q(b);h=U(b,"NAME");k=U(b,"DEFAULT");l="YES"==k;"audio"==e?v=(v=U(b,"CHANNELS"))?parseInt(v.split("/")[0],10):null:v=null;m=v;"audio"==e?v=(v=U(b,"CHANNELS"))?v.includes("/JOC"):!1:v=!1;n=v;p=U(b,"CHARACTERISTICS");r=U(b,"FORCED");
697
+ w="YES"==r;return u(x,br(a,f,d,e,g,l,h,m,null,p,w,n),2)}y=x.h;a.C.has(c)?a.C.get(c).push(y):a.C.set(c,[y]);if(null==y)return x["return"](null);if(a.g.has(f))return x["return"](a.g.get(f));a.g.set(f,y);return x["return"](y)})}
698
+ function Wq(a,b){var c,d,e,f,g,h,k,l,m,n;return I(function(p){if(1==p.g){c=ar(fq(b,"URI"),a.A);d=U(b,"CODECS","jpeg")||"";if(a.g.has(c))return p["return"](a.g.get(c));e=$q(b);f=U(b,"NAME");g=U(b,"CHARACTERISTICS");return u(p,br(a,c,d,"image",e,!1,f,null,null,g,!1,!1),2)}h=p.h;if(null==h)return p["return"](null);if(a.g.has(c))return p["return"](a.g.get(c));if(k=U(b,"RESOLUTION"))if(l=h.stream.segmentIndex.get(0),m=l.tilesLayout)h.stream.width=Number(k.split("x")[0])*Number(m.split("x")[0]),h.stream.height=
697
699
  Number(k.split("x")[1])*Number(m.split("x")[1]);if(n=U(b,"BANDWIDTH"))h.stream.bandwidth=Number(n);a.g.set(c,h);return p["return"](h)})}
698
- function Vq(a,b,c,d){var e,f,g,h;return I(function(k){if(1==k.g){e=Yq(cq(b,"URI"),a.A);if(a.g.has(e))return k["return"](a.g.get(e));var l=U(b,"CLOSED-CAPTIONS");f="video"==d&&l&&"NONE"!=l?a.J.get(l):null;g=Fb(d,c);return u(k,Zq(a,e,g,d,"und",!1,null,null,f,null,!1,!1),2)}h=k.h;if(null==h)return k["return"](null);if(a.g.has(e))return k["return"](a.g.get(e));a.g.set(e,h);return k["return"](h)})}
699
- function Zq(a,b,c,d,e,f,g,h,k,l,m,n){var p,r,x;return I(function(y){if(1==y.g)return p=Db([a.K],[b])[0],u(y,yq(a,p),2);r=y.h;p=r.uri;x=oq(a.$,r.data,p);return y["return"](Jq(a,x,b,p,c,d,e,f,g,h,k,l,m,n))})}
700
- function Jq(a,b,c,d,e,f,g,h,k,l,m,n,p,r,x){var y,w,v,D,C,B,G,E,H,L,K,N,V,Z,ha,ja,xa,La,Fa,Ra,Ga,qc,Qc,Cd,Dd,qb,Ed,rc,De,ab,ig,jg;return I(function(sc){if(1==sc.g){if(1!=b.type)throw new O(2,4,4017);y=fq(b.g,"EXT-X-DEFINE");w=Cq(a,y);$q(a,b);return x?sc.D(2):u(sc,ar(a,f,e,b,w),3)}2!=sc.g&&(x=sc.h);v=[];if(b.segments)for(D=t(b.segments),C=D.next();!C.done;C=D.next())B=C.value,G=fq(B.h,"EXT-X-KEY"),v.push.apply(v,ia(G));E=!1;H=[];L=new Set;K=t(v);for(N=K.next();!N.done;N=K.next())if(V=N.value,Z=cq(V,
701
- "METHOD"),"NONE"!=Z){E=!0;if("AES-128"==Z)return a.za=!0,sc["return"](null);ha=cq(V,"KEYFORMAT");if(xa=(ja=br[ha])?ja(V,x):null){if(xa.keyIds)for(La=t(xa.keyIds),Fa=La.next();!Fa.done;Fa=La.next())Ra=Fa.value,L.add(Ra);H.push(xa)}}if(E&&!H.length)throw new O(2,4,4026);vi.includes(x)&&(e="");Ga=new Map;try{qc=Dq(a,b,f,Ga,w)}catch(No){if(4035==No.code)return Ua("Skipping unsupported HLS stream",x,c),sc["return"](null);throw No;}Qc=qc[qc.length-1].endTime;Cd=new Xi(qc);Dd=f==Ib?"subtitle":void 0;qb=
702
- [];if(n)for(Ed=t(n.split(",")),rc=Ed.next();!rc.done;rc=Ed.next())De=rc.value,qb.push(De);ig=(ab=hq(b.g,"EXT-X-SERVER-CONTROL"))?null!=ab.getAttribute("CAN-SKIP-UNTIL"):!1;jg={id:a.ya++,originalId:k,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:Cd,mimeType:x,codecs:e,kind:Dd,encrypted:E,drmInfos:H,keyIds:L,language:g,label:k,type:f,primary:h,trickModeVideo:null,emsgSchemeIdUris:null,frameRate:void 0,pixelAspectRatio:void 0,width:void 0,height:void 0,bandwidth:void 0,roles:qb,
703
- forced:p,channelsCount:l,audioSamplingRate:null,spatialAudio:r,closedCaptions:m,hdr:void 0,tilesLayout:void 0};return sc["return"]({stream:jg,Gd:c,Sf:d,ge:Qc,Lc:Ga,Xf:ig})})}
704
- function $q(a,b){var c=hq(b.g,"EXT-X-PLAYLIST-TYPE"),d=hq(b.g,"EXT-X-ENDLIST");d=c&&"VOD"==c.value||d;c=c&&"EVENT"==c.value&&!d;c=!d&&!c;if(d)Eq(a,xq);else{c?Eq(a,cr):Eq(a,dr);d=hq(b.g,"EXT-X-TARGETDURATION");if(!d)throw new O(2,4,4024,"EXT-X-TARGETDURATION");d=Number(d.value);c=hq(b.g,"EXT-X-PART-INF");a.l&&c?(a.ba=Number(cq(c,"PART-TARGET")),a.H=Math.min(a.ba,a.H),c=hq(b.g,"EXT-X-SERVER-CONTROL"),a.X=c?Number(cq(c,"PART-HOLD-BACK")):0):a.H=Math.min(d,a.H);a.aa=Math.max(d,a.aa)}}
705
- function er(a,b,c,d){c=hq(c,"EXT-X-MAP");if(!c)return null;var e=cq(c,"URI");d=Yq(Db([b],[e])[0],d);b=[d,U(c,"BYTERANGE","")].join("-");a.ua.has(b)||(c=fr(d,c),a.ua.set(b,c));return a.ua.get(b)}function fr(a,b){var c=0,d=null,e=U(b,"BYTERANGE");e&&(c=e.split("@"),d=Number(c[0]),c=Number(c[1]),d=c+d-1);return new wi(function(){return[a]},c,d)}
706
- function gr(a,b,c,d,e,f,g,h){var k=d.h,l=Yq(d.i,f),m=hq(k,"EXTINF"),n=f=0,p=null;d.g.length&&!a.l&&Ua("Low-latency HLS live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details.");var r=null;if(!a.h.hls.ignoreManifestProgramDateTime){var x=hq(k,"EXT-X-PROGRAM-DATE-TIME");x&&x.value&&(r=Zn(x.value))}x=zi;hq(k,"EXT-X-GAP")&&(x=2);if(!m){if(0==d.g.length)throw new O(2,4,4024,"EXTINF");
707
- if(!a.l)return null}var y=[];if(a.l)for(var w={},v=0;v<d.g.length;w={Pd:w.Pd},v++){var D=d.g[v],C=0==v?c:y[y.length-1],B=0==v?e:C.endTime,G=Number(U(D,"DURATION"))||a.ba;if(G){G=B+G;var E=0,H=null;"EXT-X-PRELOAD-HINT"==D.name?E=(E=U(D,"BYTERANGE-START"))?Number(E):0:(E=U(D,"BYTERANGE"),H=t(hr(C,E)),E=H.next().value,H=H.next().value);if(C=U(D,"URI"))w.Pd=Db([g],[C])[0],C=zi,"YES"==U(D,"GAP")&&(C=2),y.push(new yi(B,G,function(L){return function(){return[L.Pd]}}(w),E,H,b,0,0,Infinity,[],"",null,null,
708
- C))}}m?f=e+Number(m.value.split(",")[0]):f=y[y.length-1].endTime;(a=hq(k,"EXT-X-BYTERANGE"))?(p=t(hr(c,a.value)),n=p.next().value,p=p.next().value):y.length&&(n=y[0].Ta,p=y[y.length-1].Ca);c="";a=null;"image"==h&&(c="1x1",h=hq(k,"EXT-X-TILES"))&&(c=cq(h,"LAYOUT"),(h=U(h,"DURATION"))&&(a=Number(h)));return new yi(e,f,function(){return l.length?[l]:[]},n,p,b,0,0,Infinity,y,c,a,r,x)}function hr(a,b){var c=0,d=null;b&&(c=b.split("@"),d=Number(c[0]),c=c[1]?Number(c[1]):a.Ca+1,d=c+d-1);return[c,d]}
709
- function Qq(a){if(a.j){for(var b=t(a.P),c=b.next();!c.done;c=b.next())a.j.ic(c.value);a.P=[]}}
710
- function Dq(a,b,c,d,e){var f=b.segments,g=iq(b.g),h=hq(b.g,"EXT-X-SKIP");h=h?Number(U(h,"SKIPPED-SEGMENTS")):0;var k=g+h,l=0;a.m!=xq&&d.has(k)&&(l=d.get(k));for(var m=[],n=null,p=0;p<f.length;p++){var r=f[p],x=0==p?l:n.endTime;k=g+h+p;d.set(k,x);var y=er(a,b.h,r.h,e);!a.l&&a.i.isAutoLowLatencyMode()&&(a.i.enableLowLatencyMode(),a.l=a.i.isLowLatencyMode());(n=y=gr(a,y,n,r,x,e,b.h,c))&&(a.h.hls.ignoreManifestProgramDateTime&&null!=a.N&&k<a.N||m.push(y))}if(a=m.some(function(w){return null!=w.g}))for(b=
711
- {},c=0;c<m.length;b={rc:b.rc,qc:b.qc,Vc:b.Vc,sb:b.sb,pc:b.pc},c++)if(b.sb=m[c],null==b.sb.g)for(b.qc=0,b.rc=c,d=function(w){return function(){var v=m[w.rc];if(v){if(null!=v.g)return v.g+w.qc;w.qc-=v.endTime-v.startTime;w.rc+=1}return null}}(b),b.pc=0,b.Vc=c,e=function(w){return function(){var v=m[w.Vc];if(v){v!=w.sb&&(w.pc+=v.endTime-v.startTime);if(null!=v.g)return v.g+w.pc;--w.Vc}return null}}(b);null==b.sb.g;)b.sb.g=e(),null==b.sb.g&&(b.sb.g=d());if(a)for(a=t(m),b=a.next();!b.done;b=a.next())for(c=
712
- b.value,b=c.g,c=t(c.h),d=c.next();!d.done;d=c.next())d=d.value,d.g=b,b+=d.endTime-d.startTime;return m}function Yq(a,b){var c=String(a).replace(/%7B/g,"{").replace(/%7D/g,"}"),d=c.match(/{\$\w*}/g);if(d){d=t(d);for(var e=d.next();!e.done;e=d.next()){e=e.value;var f=e.slice(2,e.length-1),g=b.get(f);if(g)c=c.replace(e,g);else throw new O(2,4,4039,f);}}return c}
713
- function ar(a,b,c,d,e){var f,g,h,k,l,m,n,p,r,x,y,w;return I(function(v){if(1==v.g){f=Jb;g=qf;h=Math.trunc((d.segments.length-1)/2);k=Yq(d.segments[h].i,e);l=new lb(k);m=l.Ka.split(".").pop();n=ir[b];if(p=n[m])return v["return"](p);if(b==f.ha){if("vtt"==c||"wvtt"==c)return v["return"]("text/vtt");if(c&&""!==c)return v["return"]("application/mp4")}if(b==f.xc&&(!c||"jpeg"==c))return v["return"]("image/jpeg");r=kf([k],a.h.retryParameters);r.method="HEAD";return u(v,jr(a,r,g),2)}x=v.h;y=x.headers["content-type"];
714
- if(!y){if(b==f.ha)return v["return"]("text/vtt");w=n.mp4;return v["return"](w)}return v["return"](y.split(";")[0])})}function yq(a,b){var c=kf([b],a.h.retryParameters);a.i.modifyManifestRequest(c,{format:"h"});return jr(a,c,0)}function wq(a){var b,c;I(function(d){if(1==d.g){if(!a.i)return d["return"]();A(d,2);return u(d,a.update(),4)}if(2!=d.g)return b=a.ea,a.F.T(b),va(d,0);c=F(d);if(!a.i)return d["return"]();c.severity=1;a.i.onError(c);a.F.T(.1);z(d)})}
715
- function Eq(a,b){a.m=b;a.j&&a.j.Uc(a.m==xq);a.m!=xq||a.F.stop()}function jr(a,b,c){if(!a.G)throw new O(2,7,7001);b=a.i.networkingEngine.request(c,b);ef(a.G,b);return b.promise}J("shaka.hls.HlsParser",vq);
716
- var ir={audio:{mp4:"audio/mp4",mp4a:"audio/mp4",m4s:"audio/mp4",m4i:"audio/mp4",m4a:"audio/mp4",m4f:"audio/mp4",cmfa:"audio/mp4",ts:"video/mp2t",aac:"audio/aac",ac3:"audio/ac3",ec3:"audio/ec3",mp3:"audio/mpeg"},video:{mp4:"video/mp4",mp4v:"video/mp4",m4s:"video/mp4",m4i:"video/mp4",m4v:"video/mp4",m4f:"video/mp4",cmfv:"video/mp4",ts:"video/mp2t"},text:{mp4:"application/mp4",m4s:"application/mp4",m4i:"application/mp4",m4f:"application/mp4",cmft:"application/mp4",vtt:"text/vtt",ttml:"application/ttml+xml"},
717
- image:{jpg:"image/jpeg",png:"image/png",svg:"image/svg+xml",webp:"image/webp",avif:"image/avif"}},br={"com.apple.streamingkeydelivery":function(a,b){if("video/mp2t"==b)throw new O(2,4,4040);return Eb("com.apple.fps",[{initDataType:"sinf",initData:new Uint8Array(0)}])},"urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":function(a){var b=cq(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;b=cq(a,"URI");b=uq(b);b=Gc(b.data);b=Eb("com.widevine.alpha",[{initDataType:"cenc",initData:b}]);
718
- if(a=U(a,"KEYID"))b.keyIds=new Set([a.toLowerCase().substr(2)]);return b},"com.microsoft.playready":function(a){var b=cq(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;a=cq(a,"URI");a=uq(a);a=Gc(a.data);b=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);a=On(a,b,new Set,0);return Eb("com.microsoft.playready",[{initDataType:"cenc",initData:a}])}},xq="VOD",dr="EVENT",cr="LIVE",Bq={Rf:xq,Mh:dr,We:cr};
719
- Fd("Tizen 3")||Fd("Tizen 2")||Fd("Web0S")&&Fd("Chrome/38.0.2125.122 Safari/537.36")||(sg.m3u8=function(){return new vq},qg["application/x-mpegurl"]=function(){return new vq},qg["application/vnd.apple.mpegurl"]=function(){return new vq});function kr(a,b,c,d,e,f){if(200<=c&&299>=c&&202!=c)return{uri:e||d,Af:d,data:b,status:c,headers:a,fromCache:!!a["x-shaka-from-cache"]};e=null;try{e=Uc(b)}catch(g){}throw new O(401==c||403==c?2:1,1,1001,d,c,e,a,f);};function lr(){}function mr(a,b,c,d,e){var f=new nr;yf(b.headers).forEach(function(l,m){f.append(m,l)});var g=new or,h={$e:!1,Lf:!1};a=pr(a,c,{body:b.body||void 0,headers:f,method:b.method,signal:g.signal,credentials:b.allowCrossSiteCredentials?"include":void 0},h,d,e,b.streamDataCallback);a=new Ve(a,function(){h.$e=!0;g.abort();return Promise.resolve()});if(b=b.retryParameters.timeout){var k=new P(function(){h.Lf=!0;g.abort()});k.T(b/1E3);a["finally"](function(){k.stop()})}return a}
720
- function pr(a,b,c,d,e,f,g){var h,k,l,m,n,p,r,x,y,w,v,D,C;return I(function(B){switch(B.g){case 1:return h=qr,k=rr,p=n=0,r=Date.now(),A(B,2),u(B,h(a,c),4);case 4:return l=B.h,f(sr(l.headers)),x=l.clone().body.getReader(),w=(y=l.headers.get("Content-Length"))?parseInt(y,10):0,v=function(G){function E(){var H,L;return I(function(K){switch(K.g){case 1:return A(K,2),u(K,x.read(),4);case 4:H=K.h;va(K,3);break;case 2:return F(K),K["return"]();case 3:if(H.done){K.D(5);break}n+=H.value.byteLength;if(!g){K.D(5);
721
- break}return u(K,g(H.value),5);case 5:L=Date.now();if(100<L-r||H.done)e(L-r,n-p,w-n),p=n,r=L;H.done?G.close():(G.enqueue(H.value),E());z(K)}})}E()},new k({start:v}),u(B,l.arrayBuffer(),5);case 5:m=B.h;va(B,3);break;case 2:D=F(B);if(d.$e)throw new O(1,1,7001,a,b);if(d.Lf)throw new O(1,1,1003,a,b);throw new O(1,1,1002,a,D,b);case 3:return C=sr(l.headers),B["return"](kr(C,m,l.status,a,l.url,b))}})}function sr(a){var b={};a.forEach(function(c,d){b[d.trim()]=c});return b}
722
- function tr(){if(window.ReadableStream)try{new ReadableStream({})}catch(a){return!1}else return!1;return!(!window.fetch||!window.AbortController)}J("shaka.net.HttpFetchPlugin",lr);lr.isSupported=tr;lr.parse=mr;var qr=window.fetch,or=window.AbortController,rr=window.ReadableStream,nr=window.Headers;tr()&&(gf("http",mr,2,!0),gf("https",mr,2,!0),gf("blob",mr,2,!0));function ur(){}
723
- function vr(a,b,c,d,e){var f=new wr,g=Date.now(),h=0,k=new Promise(function(l,m){f.open(b.method,a,!0);f.responseType="arraybuffer";f.timeout=b.retryParameters.timeout;f.withCredentials=b.allowCrossSiteCredentials;f.onabort=function(){m(new O(1,1,7001,a,c))};var n=!1;f.onreadystatechange=function(){if(2==f.readyState&&!n){var r=xr(f);e(r);n=!0}};f.onload=function(){var r=xr(f),x=f.response;try{var y=kr(r,x,f.status,a,f.responseURL,c);l(y)}catch(w){m(w)}};f.onerror=function(r){m(new O(1,1,1002,a,r,
724
- c))};f.ontimeout=function(){m(new O(1,1,1003,a,c))};f.onprogress=function(r){var x=Date.now();if(100<x-g||r.lengthComputable&&r.loaded==r.total)d(x-g,r.loaded-h,r.total-r.loaded),h=r.loaded,g=x};for(var p in b.headers)f.setRequestHeader(p.toLowerCase(),b.headers[p]);f.send(b.body)});return new Ve(k,function(){f.abort();return Promise.resolve()})}
725
- function xr(a){var b=a.getAllResponseHeaders().trim().split("\r\n");a={};b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value.split(": "),a[c[0].toLowerCase()]=c.slice(1).join(": ");return a}J("shaka.net.HttpXHRPlugin",ur);ur.parse=vr;var wr=window.XMLHttpRequest;gf("http",vr,1,!0);gf("https",vr,1,!0);gf("blob",vr,1,!0);function yr(a,b,c,d){this.g=a;this.i=b;this.groupId=c;this.h=d}function zr(a){return a.Pa().map(function(b){return"{"+encodeURI(b)+"}"}).join("")+":"+a.Ta+":"+a.Ca}function Ar(a,b){return oj(a.g.Pa(),a.g.Ta,a.g.Ca,b.streaming.retryParameters)};function Br(){this.h=this.j=this.i=0;this.g=new Map;this.l=0}function Cr(a,b){a.i+=b;var c=a.l;a.l++;a.g.set(c,b);return c}Br.prototype.close=function(a,b){if(this.g.has(a)){var c=this.g.get(a);this.g["delete"](a);this.j+=c;this.h+=b}};function Dr(a){var b=this;this.A=a;this.j=new Map;this.i=new rf(function(){return Er(b)["catch"](function(){})});this.h=[];this.m=function(){};this.l=function(){};this.g=new Br}Dr.prototype.destroy=function(){return this.i.destroy()};function Fr(a,b,c){a.m=b;a.l=c}function Er(a){var b=a.h.map(function(c){return c()});a.h=[];return Promise.all(b)}
726
- function Gr(a,b,c,d,e,f){sf(a.i);var g=(a.j.get(b)||Promise.resolve()).then(function(){var h,k,l,m,n,p,r;return I(function(x){if(1==x.g)return u(x,Hr(a,c),2);h=x.h;if(a.i.g)throw new O(2,9,7001);if(e)for(m in k=Gc(h),l=new Nn(k),l.data)n=Number(m),p=l.data[n],r=l.g[n],a.l(p,r);a.g.close(d,h.byteLength);var y=a.g;a.m(0==y.i?0:y.j/y.i,a.g.h);return x["return"](f(h))})});a.j.set(b,g)}function Ir(a){return I(function(b){return 1==b.g?u(b,Promise.all(a.j.values()),2):b["return"](a.g.h)})}
727
- function Hr(a,b){var c,d,e,f;return I(function(g){if(1==g.g)return c=qf,d=a.A.request(c,b),e=function(){return d.abort()},a.h.push(e),u(g,d.promise,2);f=g.h;dc(a.h,e);return g["return"](f.data)})};function Jr(a,b){var c=this;this.i=a;this.h=a.objectStore(b);this.g=new Nc;a.onabort=function(d){d.preventDefault();c.g.reject()};a.onerror=function(d){d.preventDefault();c.g.reject()};a.oncomplete=function(){c.g.resolve()}}Jr.prototype.abort=function(){var a=this;return I(function(b){if(1==b.g){try{a.i.abort()}catch(c){}A(b,2);return u(b,a.g,4)}if(2!=b.g)return va(b,0);F(b);z(b)})};
728
- function Kr(a,b){return new Promise(function(c,d){var e=a.h.openCursor();e.onerror=d;e.onsuccess=function(){var f;return I(function(g){if(1==g.g){if(null==e.result)return c(),g["return"]();f=e.result;return u(g,b(f.key,f.value,f),2)}f["continue"]();z(g)})}})}Jr.prototype.store=function(){return this.h};Jr.prototype.promise=function(){return this.g};function Lr(a){this.h=a;this.g=[]}Lr.prototype.destroy=function(){return Promise.all(this.g.map(function(a){return a.abort()}))};function Mr(a,b){return Nr(a,b,"readwrite")}function Nr(a,b,c){c=a.h.transaction([b],c);var d=new Jr(c,b);a.g.push(d);d.promise().then(function(){dc(a.g,d)},function(){dc(a.g,d)});return d};function Or(a,b,c){this.h=new Lr(a);this.i=b;this.g=c}q=Or.prototype;q.destroy=function(){return this.h.destroy()};q.hasFixedKeySpace=function(){return!0};q.addSegments=function(){return Pr(this.i)};q.removeSegments=function(a,b){return Qr(this,this.i,a,b)};q.getSegments=function(a){var b=this,c;return I(function(d){if(1==d.g)return u(d,Rr(b,b.i,a),2);c=d.h;return d["return"](c.map(function(e){return b.df(e)}))})};q.addManifests=function(){return Pr(this.g)};
729
- q.updateManifest=function(){return Promise.reject(new O(2,9,9016,"Cannot modify values in "+this.g))};function Sr(a,b,c){a=Mr(a.h,a.g);var d=a.store();d.get(b).onsuccess=function(){d.put(c,b)};return a.promise()}q.updateManifestExpiration=function(a,b){var c=Mr(this.h,this.g),d=c.store();d.get(a).onsuccess=function(e){if(e=e.target.result)e.expiration=b,d.put(e,a)};return c.promise()};q.removeManifests=function(a,b){return Qr(this,this.g,a,b)};
730
- q.getManifests=function(a){var b=this,c;return I(function(d){if(1==d.g)return u(d,Rr(b,b.g,a),2);c=d.h;return d["return"](Promise.all(c.map(function(e){return b.Ac(e)})))})};q.getAllManifests=function(){var a=this,b,c;return I(function(d){return 1==d.g?(b=Nr(a.h,a.g,"readonly"),c=new Map,u(d,Kr(b,function(e,f){var g;return I(function(h){if(1==h.g)return u(h,a.Ac(f),2);g=h.h;c.set(e,g);z(h)})}),2)):3!=d.g?u(d,b.promise(),3):d["return"](c)})};q.df=function(a){return a};q.Ac=function(a){return Promise.resolve(a)};
731
- function Pr(a){return Promise.reject(new O(2,9,9011,"Cannot add new value to "+a))}q.add=function(a,b){var c=this,d,e,f,g,h,k,l;return I(function(m){if(1==m.g){d=Mr(c.h,a);e=d.store();f=[];g={};h=t(b);for(k=h.next();!k.done;g={Zc:g.Zc},k=h.next())l=k.value,g.Zc=e.add(l),g.Zc.onsuccess=function(n){return function(){f.push(n.Zc.result)}}(g);return u(m,d.promise(),2)}return m["return"](f)})};
732
- function Qr(a,b,c,d){a=Mr(a.h,b);b=a.store();var e={};c=t(c);for(var f=c.next();!f.done;e={Yc:e.Yc},f=c.next())e.Yc=f.value,b["delete"](e.Yc).onsuccess=function(g){return function(){return d(g.Yc)}}(e);return a.promise()}
733
- function Rr(a,b,c){var d,e,f,g,h,k,l;return I(function(m){if(1==m.g){d=Nr(a.h,b,"readonly");e=d.store();f={};g=[];h={};k=t(c);for(l=k.next();!l.done;h={wc:h.wc,tc:h.tc},l=k.next())h.tc=l.value,h.wc=e.get(h.tc),h.wc.onsuccess=function(n){return function(){void 0==n.wc.result&&g.push(n.tc);f[n.tc]=n.wc.result}}(h);return u(m,d.promise(),2)}if(g.length)throw new O(2,9,9012,"Could not find values for "+g);return m["return"](c.map(function(n){return f[n]}))})};function Tr(a){this.g=new Lr(a)}Tr.prototype.destroy=function(){return this.g.destroy()};Tr.prototype.getAll=function(){var a=this,b,c;return I(function(d){return 1==d.g?(b=Nr(a.g,"session-ids","readonly"),c=[],u(d,Kr(b,function(e,f){c.push(f)}),2)):3!=d.g?u(d,b.promise(),3):d["return"](c)})};Tr.prototype.add=function(a){var b=Mr(this.g,"session-ids"),c=b.store();a=t(a);for(var d=a.next();!d.done;d=a.next())c.add(d.value);return b.promise()};
734
- Tr.prototype.remove=function(a){var b=this,c;return I(function(d){return 1==d.g?(c=Mr(b.g,"session-ids"),u(d,Kr(c,function(e,f,g){a.includes(f.sessionId)&&g["delete"]()}),2)):u(d,c.promise(),0)})};function Ur(){this.g=new Map}Ur.prototype.destroy=function(){for(var a=[],b=t(this.g.values()),c=b.next();!c.done;c=b.next())a.push(c.value.destroy());this.g.clear();return Promise.all(a)};Ur.prototype.init=function(){var a=this;Vr.forEach(function(e,f){var g=e();g&&a.g.set(f,g)});for(var b=[],c=t(this.g.values()),d=c.next();!d.done;d=c.next())b.push(d.value.init());return Promise.all(b)};
735
- function Wr(a){var b=null;a.g.forEach(function(c,d){c.getCells().forEach(function(e,f){e.hasFixedKeySpace()||b||(b={path:{Sa:d,Ba:f},Ba:e})})});if(b)return b;throw new O(2,9,9013,"Could not find a cell that supports add-operations");}function Xr(a,b){a.g.forEach(function(c,d){c.getCells().forEach(function(e,f){b({Sa:d,Ba:f},e)})})}
736
- function Yr(a,b,c){a=a.g.get(b);if(!a)throw new O(2,9,9013,"Could not find mechanism with name "+b);b=a.getCells().get(c);if(!b)throw new O(2,9,9013,"Could not find cell with name "+c);return b}function Zr(a,b){a.g.forEach(function(c){b(c.getEmeSessionCell())})}function $r(a){var b=Array.from(a.g.keys());if(!b.length)throw new O(2,9,9E3,"No supported storage mechanisms found");return a.g.get(b[0]).getEmeSessionCell()}
737
- function as(a){var b,c,d;return I(function(e){return 1==e.g?(b=Array.from(a.g.values()),c=0<b.length,c||(d=Vr,d.forEach(function(f){(f=f())&&b.push(f)})),u(e,Promise.all(b.map(function(f){return f.erase()})),2)):c?e.D(0):u(e,Promise.all(b.map(function(f){return f.destroy()})),0)})}function bs(a,b){Vr.set(a,b)}J("shaka.offline.StorageMuxer",Ur);Ur.unregister=function(a){Vr["delete"](a)};Ur.register=bs;Ur.prototype.destroy=Ur.prototype.destroy;var Vr=new Map;function cs(){Or.apply(this,arguments)}qa(cs,Or);cs.prototype.updateManifestExpiration=function(a,b){var c=this,d,e,f;return I(function(g){d=Mr(c.h,c.g);e=d.store();f=new Nc;e.get(a).onsuccess=function(h){(h=h.target.result)?(h.expiration=b,e.put(h),f.resolve()):f.reject(new O(2,9,9012,"Could not find values for "+a))};return u(g,Promise.all([d.promise(),f]),0)})};
738
- cs.prototype.Ac=function(a){var b,c,d,e,f,g;return I(function(h){if(1==h.g){b=[];for(c=0;c<a.periods.length;++c)d=c==a.periods.length-1?a.duration:a.periods[c+1].startTime,e=d-a.periods[c].startTime,f=ds(a.periods[c],e),b.push(f);return u(h,np(b),2)}g=h.h;return h["return"]({creationTime:0,originalManifestUri:a.originalManifestUri,duration:a.duration,size:a.size,expiration:null==a.expiration?Infinity:a.expiration,streams:g,sessionIds:a.sessionIds,drmInfo:a.drmInfo,appMetadata:a.appMetadata,sequenceMode:!1})})};
739
- function ds(a,b){es(a);for(var c=t(a.streams),d=c.next();!d.done;d=c.next());return a.streams.map(function(e){return fs(e,a.startTime,b)})}
740
- function fs(a,b,c){var d=a.initSegmentUri?gs(a.initSegmentUri):null,e=b+a.presentationTimeOffset,f=b+c;return{id:a.id,originalId:null,primary:a.primary,type:a.contentType,mimeType:a.mimeType,codecs:a.codecs,frameRate:a.frameRate,pixelAspectRatio:void 0,hdr:void 0,kind:a.kind,language:a.language,label:a.label,width:a.width,height:a.height,initSegmentKey:d,encrypted:a.encrypted,keyIds:new Set([a.keyId]),segments:a.segments.map(function(g){var h=gs(g.uri);return{startTime:b+g.startTime,endTime:b+g.endTime,
741
- dataKey:h,initSegmentKey:d,appendWindowStart:b,appendWindowEnd:f,timestampOffset:e,tilesLayout:""}}),variantIds:a.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0}}cs.prototype.df=function(a){return{data:a.data}};function gs(a){var b;if((b=/^offline:[0-9]+\/[0-9]+\/([0-9]+)$/.exec(a))||(b=/^offline:segment\/([0-9]+)$/.exec(a)))return Number(b[1]);throw new O(2,9,9004,"Could not parse uri "+a);}
742
- function es(a){var b=a.streams.filter(function(h){return"audio"==h.contentType});a=a.streams.filter(function(h){return"video"==h.contentType});if(!b.every(function(h){return h.variantIds})||!a.every(function(h){return h.variantIds})){for(var c=t(b),d=c.next();!d.done;d=c.next())d.value.variantIds=[];c=t(a);for(d=c.next();!d.done;d=c.next())d.value.variantIds=[];c=0;if(a.length&&!b.length){var e=c++,f=t(a);for(d=f.next();!d.done;d=f.next())d.value.variantIds.push(e)}if(!a.length&&b.length)for(e=c++,
743
- f=t(b),d=f.next();!d.done;d=f.next())d.value.variantIds.push(e);if(a.length&&b.length)for(b=t(b),d=b.next();!d.done;d=b.next())for(d=d.value,e=t(a),f=e.next();!f.done;f=e.next()){f=f.value;var g=c++;d.variantIds.push(g);f.variantIds.push(g)}}};function hs(){Or.apply(this,arguments)}qa(hs,Or);
744
- hs.prototype.Ac=function(a){var b,c,d,e,f,g;return I(function(h){if(1==h.g){b=[];for(c=0;c<a.periods.length;++c){d=c==a.periods.length-1?a.duration:a.periods[c+1].startTime;e=d-a.periods[c].startTime;for(var k=a.periods[c],l=[],m=t(k.streams),n=m.next();!n.done;n=m.next())n=n.value,0!=n.variantIds.length&&l.push(is(n,k.startTime,k.startTime+e));f=l;b.push(f)}return u(h,np(b),2)}g=h.h;return h["return"]({appMetadata:a.appMetadata,creationTime:0,drmInfo:a.drmInfo,duration:a.duration,expiration:null==
700
+ function Yq(a,b,c,d){var e,f,g,h;return I(function(k){if(1==k.g){e=ar(fq(b,"URI"),a.A);if(a.g.has(e))return k["return"](a.g.get(e));var l=U(b,"CLOSED-CAPTIONS");f="video"==d&&l&&"NONE"!=l?a.J.get(l):null;g=Fb(d,c);return u(k,br(a,e,g,d,"und",!1,null,null,f,null,!1,!1),2)}h=k.h;if(null==h)return k["return"](null);if(a.g.has(e))return k["return"](a.g.get(e));a.g.set(e,h);return k["return"](h)})}
701
+ function br(a,b,c,d,e,f,g,h,k,l,m,n){var p,r,w;return I(function(y){if(1==y.g)return p=Db([a.K],[b])[0],u(y,Bq(a,p),2);r=y.h;p=r.uri;w=rq(a.$,r.data,p);return y["return"](Mq(a,w,b,p,c,d,e,f,g,h,k,l,m,n))})}
702
+ function Mq(a,b,c,d,e,f,g,h,k,l,m,n,p,r,w){var y,x,v,D,C,B,G,E,H,N,K,M,V,Z,ha,ja,xa,La,Fa,Sa,Ga,rc,Qc,Cd,Dd,qb,Ed,sc,De,ab,jg,kg;return I(function(tc){if(1==tc.g){if(1!=b.type)throw new O(2,4,4017);y=iq(b.g,"EXT-X-DEFINE");x=Fq(a,y);cr(a,b);return w?tc.D(2):u(tc,dr(a,f,e,b,x),3)}2!=tc.g&&(w=tc.h);v=[];if(b.segments)for(D=t(b.segments),C=D.next();!C.done;C=D.next())B=C.value,G=iq(B.h,"EXT-X-KEY"),v.push.apply(v,ia(G));E=!1;H=[];N=new Set;K=t(v);for(M=K.next();!M.done;M=K.next())if(V=M.value,Z=fq(V,
703
+ "METHOD"),"NONE"!=Z){E=!0;if("AES-128"==Z)return a.za=!0,tc["return"](null);ha=fq(V,"KEYFORMAT");if(xa=(ja=er[ha])?ja(V,w):null){if(xa.keyIds)for(La=t(xa.keyIds),Fa=La.next();!Fa.done;Fa=La.next())Sa=Fa.value,N.add(Sa);H.push(xa)}}if(E&&!H.length)throw new O(2,4,4026);Di.includes(w)&&(e="");Ga=new Map;try{rc=Gq(a,b,f,Ga,x)}catch(Po){if(4035==Po.code)return Ua("Skipping unsupported HLS stream",w,c),tc["return"](null);throw Po;}Qc=rc[rc.length-1].endTime;Cd=new $i(rc);Dd=f==Ib?"subtitle":void 0;qb=
704
+ [];if(n)for(Ed=t(n.split(",")),sc=Ed.next();!sc.done;sc=Ed.next())De=sc.value,qb.push(De);jg=(ab=kq(b.g,"EXT-X-SERVER-CONTROL"))?null!=ab.getAttribute("CAN-SKIP-UNTIL"):!1;kg={id:a.ya++,originalId:k,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:Cd,mimeType:w,codecs:e,kind:Dd,encrypted:E,drmInfos:H,keyIds:N,language:g,label:k,type:f,primary:h,trickModeVideo:null,emsgSchemeIdUris:null,frameRate:void 0,pixelAspectRatio:void 0,width:void 0,height:void 0,bandwidth:void 0,roles:qb,
705
+ forced:p,channelsCount:l,audioSamplingRate:null,spatialAudio:r,closedCaptions:m,hdr:void 0,tilesLayout:void 0};return tc["return"]({stream:kg,Gd:c,Tf:d,ie:Qc,Lc:Ga,Yf:jg})})}
706
+ function cr(a,b){var c=kq(b.g,"EXT-X-PLAYLIST-TYPE"),d=kq(b.g,"EXT-X-ENDLIST");d=c&&"VOD"==c.value||d;c=c&&"EVENT"==c.value&&!d;c=!d&&!c;if(d)Hq(a,Aq);else{c?Hq(a,fr):Hq(a,gr);d=kq(b.g,"EXT-X-TARGETDURATION");if(!d)throw new O(2,4,4024,"EXT-X-TARGETDURATION");d=Number(d.value);c=kq(b.g,"EXT-X-PART-INF");a.l&&c?(a.ba=Number(fq(c,"PART-TARGET")),a.H=Math.min(a.ba,a.H),c=kq(b.g,"EXT-X-SERVER-CONTROL"),a.X=c?Number(fq(c,"PART-HOLD-BACK")):0):a.H=Math.min(d,a.H);a.aa=Math.max(d,a.aa)}}
707
+ function hr(a,b,c,d){c=kq(c,"EXT-X-MAP");if(!c)return null;var e=fq(c,"URI");d=ar(Db([b],[e])[0],d);b=[d,U(c,"BYTERANGE","")].join("-");a.ua.has(b)||(c=ir(d,c),a.ua.set(b,c));return a.ua.get(b)}function ir(a,b){var c=0,d=null,e=U(b,"BYTERANGE");e&&(c=e.split("@"),d=Number(c[0]),c=Number(c[1]),d=c+d-1);return new Wh(function(){return[a]},c,d)}
708
+ function jr(a,b,c,d,e,f,g,h){var k=d.h,l=ar(d.i,f),m=kq(k,"EXTINF"),n=f=0,p=null;d.g.length&&!a.l&&Ua("Low-latency HLS live stream detected, but low-latency streaming mode is not enabled in Shaka Player. Set streaming.lowLatencyMode configuration to true, and see https://bit.ly/3clctcj for details.");var r=null;if(!a.h.hls.ignoreManifestProgramDateTime){var w=kq(k,"EXT-X-PROGRAM-DATE-TIME");w&&w.value&&(r=bo(w.value))}w=Zh;kq(k,"EXT-X-GAP")&&(w=2);if(!m){if(0==d.g.length)throw new O(2,4,4024,"EXTINF");
709
+ if(!a.l)return null}var y=[];if(a.l)for(var x={},v=0;v<d.g.length;x={Pd:x.Pd},v++){var D=d.g[v],C=0==v?c:y[y.length-1],B=0==v?e:C.endTime,G=Number(U(D,"DURATION"))||a.ba;if(G){G=B+G;var E=0,H=null;"EXT-X-PRELOAD-HINT"==D.name?E=(E=U(D,"BYTERANGE-START"))?Number(E):0:(E=U(D,"BYTERANGE"),H=t(kr(C,E)),E=H.next().value,H=H.next().value);if(C=U(D,"URI"))x.Pd=Db([g],[C])[0],C=Zh,"YES"==U(D,"GAP")&&(C=2),y.push(new Yh(B,G,function(N){return function(){return[N.Pd]}}(x),E,H,b,0,0,Infinity,[],"",null,null,
710
+ C))}}m?f=e+Number(m.value.split(",")[0]):f=y[y.length-1].endTime;(a=kq(k,"EXT-X-BYTERANGE"))?(p=t(kr(c,a.value)),n=p.next().value,p=p.next().value):y.length&&(n=y[0].Ta,p=y[y.length-1].Ca);c="";a=null;"image"==h&&(c="1x1",h=kq(k,"EXT-X-TILES"))&&(c=fq(h,"LAYOUT"),(h=U(h,"DURATION"))&&(a=Number(h)));return new Yh(e,f,function(){return l.length?[l]:[]},n,p,b,0,0,Infinity,y,c,a,r,w)}function kr(a,b){var c=0,d=null;b&&(c=b.split("@"),d=Number(c[0]),c=c[1]?Number(c[1]):a.Ca+1,d=c+d-1);return[c,d]}
711
+ function Tq(a){if(a.i){for(var b=t(a.P),c=b.next();!c.done;c=b.next())a.i.ic(c.value);a.P=[]}}
712
+ function Gq(a,b,c,d,e){var f=b.segments,g=lq(b.g),h=kq(b.g,"EXT-X-SKIP");h=h?Number(U(h,"SKIPPED-SEGMENTS")):0;var k=g+h,l=0;a.m!=Aq&&d.has(k)&&(l=d.get(k));for(var m=[],n=null,p=0;p<f.length;p++){var r=f[p],w=0==p?l:n.endTime;k=g+h+p;d.set(k,w);var y=hr(a,b.h,r.h,e);!a.l&&a.j.isAutoLowLatencyMode()&&(a.j.enableLowLatencyMode(),a.l=a.j.isLowLatencyMode());(n=y=jr(a,y,n,r,w,e,b.h,c))&&(a.h.hls.ignoreManifestProgramDateTime&&null!=a.N&&k<a.N||m.push(y))}if(a=m.some(function(x){return null!=x.g}))for(b=
713
+ {},c=0;c<m.length;b={rc:b.rc,qc:b.qc,Vc:b.Vc,sb:b.sb,pc:b.pc},c++)if(b.sb=m[c],null==b.sb.g)for(b.qc=0,b.rc=c,d=function(x){return function(){var v=m[x.rc];if(v){if(null!=v.g)return v.g+x.qc;x.qc-=v.endTime-v.startTime;x.rc+=1}return null}}(b),b.pc=0,b.Vc=c,e=function(x){return function(){var v=m[x.Vc];if(v){v!=x.sb&&(x.pc+=v.endTime-v.startTime);if(null!=v.g)return v.g+x.pc;--x.Vc}return null}}(b);null==b.sb.g;)b.sb.g=e(),null==b.sb.g&&(b.sb.g=d());if(a)for(a=t(m),b=a.next();!b.done;b=a.next())for(c=
714
+ b.value,b=c.g,c=t(c.h),d=c.next();!d.done;d=c.next())d=d.value,d.g=b,b+=d.endTime-d.startTime;return m}function ar(a,b){var c=String(a).replace(/%7B/g,"{").replace(/%7D/g,"}"),d=c.match(/{\$\w*}/g);if(d){d=t(d);for(var e=d.next();!e.done;e=d.next()){e=e.value;var f=e.slice(2,e.length-1),g=b.get(f);if(g)c=c.replace(e,g);else throw new O(2,4,4039,f);}}return c}
715
+ function dr(a,b,c,d,e){var f,g,h,k,l,m,n,p,r,w,y,x;return I(function(v){if(1==v.g){f=Jb;g=tf;h=Math.trunc((d.segments.length-1)/2);k=ar(d.segments[h].i,e);l=new lb(k);m=l.Ka.split(".").pop();n=lr[b];if(p=n[m])return v["return"](p);if(b==f.ha){if("vtt"==c||"wvtt"==c)return v["return"]("text/vtt");if(c&&""!==c)return v["return"]("application/mp4")}if(b==f.xc&&(!c||"jpeg"==c))return v["return"]("image/jpeg");r=nf([k],a.h.retryParameters);r.method="HEAD";return u(v,mr(a,r,g),2)}w=v.h;y=w.headers["content-type"];
716
+ if(!y){if(b==f.ha)return v["return"]("text/vtt");x=n.mp4;return v["return"](x)}return v["return"](y.split(";")[0])})}function Bq(a,b){var c=nf([b],a.h.retryParameters);a.j.modifyManifestRequest(c,{format:"h"});return mr(a,c,0)}function zq(a){var b,c;I(function(d){if(1==d.g){if(!a.j)return d["return"]();A(d,2);return u(d,a.update(),4)}if(2!=d.g)return b=a.ea,a.F.T(b),va(d,0);c=F(d);if(!a.j)return d["return"]();c.severity=1;a.j.onError(c);a.F.T(.1);z(d)})}
717
+ function Hq(a,b){a.m=b;a.i&&a.i.Uc(a.m==Aq);a.m!=Aq||a.F.stop()}function mr(a,b,c){if(!a.G)throw new O(2,7,7001);b=a.j.networkingEngine.request(c,b);hf(a.G,b);return b.promise}J("shaka.hls.HlsParser",yq);
718
+ var lr={audio:{mp4:"audio/mp4",mp4a:"audio/mp4",m4s:"audio/mp4",m4i:"audio/mp4",m4a:"audio/mp4",m4f:"audio/mp4",cmfa:"audio/mp4",ts:"video/mp2t",aac:"audio/aac",ac3:"audio/ac3",ec3:"audio/ec3",mp3:"audio/mpeg"},video:{mp4:"video/mp4",mp4v:"video/mp4",m4s:"video/mp4",m4i:"video/mp4",m4v:"video/mp4",m4f:"video/mp4",cmfv:"video/mp4",ts:"video/mp2t"},text:{mp4:"application/mp4",m4s:"application/mp4",m4i:"application/mp4",m4f:"application/mp4",cmft:"application/mp4",vtt:"text/vtt",ttml:"application/ttml+xml"},
719
+ image:{jpg:"image/jpeg",png:"image/png",svg:"image/svg+xml",webp:"image/webp",avif:"image/avif"}},er={"com.apple.streamingkeydelivery":function(a,b){if("video/mp2t"==b)throw new O(2,4,4040);return Eb("com.apple.fps",[{initDataType:"sinf",initData:new Uint8Array(0)}])},"urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed":function(a){var b=fq(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;b=fq(a,"URI");b=xq(b);b=Gc(b.data);b=Eb("com.widevine.alpha",[{initDataType:"cenc",initData:b}]);
720
+ if(a=U(a,"KEYID"))b.keyIds=new Set([a.toLowerCase().substr(2)]);return b},"com.microsoft.playready":function(a){var b=fq(a,"METHOD");if(!["SAMPLE-AES","SAMPLE-AES-CTR"].includes(b))return null;a=fq(a,"URI");a=xq(a);a=Gc(a.data);b=new Uint8Array([154,4,240,121,152,64,66,134,171,146,230,91,224,136,95,149]);a=Rn(a,b,new Set,0);return Eb("com.microsoft.playready",[{initDataType:"cenc",initData:a}])}},Aq="VOD",gr="EVENT",fr="LIVE",Eq={Sf:Aq,Nh:gr,Xe:fr};
721
+ Vc("Tizen 3")||Vc("Tizen 2")||Xc()||(vg.m3u8=function(){return new yq},tg["application/x-mpegurl"]=function(){return new yq},tg["application/vnd.apple.mpegurl"]=function(){return new yq});function nr(a,b,c,d,e,f){if(200<=c&&299>=c&&202!=c)return{uri:e||d,Bf:d,data:b,status:c,headers:a,fromCache:!!a["x-shaka-from-cache"]};e=null;try{e=hd(b)}catch(g){}throw new O(401==c||403==c?2:1,1,1001,d,c,e,a,f);};function or(){}function pr(a,b,c,d,e){var f=new qr;Bf(b.headers).forEach(function(l,m){f.append(m,l)});var g=new rr,h={bf:!1,Mf:!1};a=sr(a,c,{body:b.body||void 0,headers:f,method:b.method,signal:g.signal,credentials:b.allowCrossSiteCredentials?"include":void 0},h,d,e,b.streamDataCallback);a=new Ye(a,function(){h.bf=!0;g.abort();return Promise.resolve()});if(b=b.retryParameters.timeout){var k=new P(function(){h.Mf=!0;g.abort()});k.T(b/1E3);a["finally"](function(){k.stop()})}return a}
722
+ function sr(a,b,c,d,e,f,g){var h,k,l,m,n,p,r,w,y,x,v,D,C;return I(function(B){switch(B.g){case 1:return h=tr,k=ur,p=n=0,r=Date.now(),A(B,2),u(B,h(a,c),4);case 4:return l=B.h,f(vr(l.headers)),w=l.clone().body.getReader(),x=(y=l.headers.get("Content-Length"))?parseInt(y,10):0,v=function(G){function E(){var H,N;return I(function(K){switch(K.g){case 1:return A(K,2),u(K,w.read(),4);case 4:H=K.h;va(K,3);break;case 2:return F(K),K["return"]();case 3:if(H.done){K.D(5);break}n+=H.value.byteLength;if(!g){K.D(5);
723
+ break}return u(K,g(H.value),5);case 5:N=Date.now();if(100<N-r||H.done)e(N-r,n-p,x-n),p=n,r=N;H.done?G.close():(G.enqueue(H.value),E());z(K)}})}E()},new k({start:v}),u(B,l.arrayBuffer(),5);case 5:m=B.h;va(B,3);break;case 2:D=F(B);if(d.bf)throw new O(1,1,7001,a,b);if(d.Mf)throw new O(1,1,1003,a,b);throw new O(1,1,1002,a,D,b);case 3:return C=vr(l.headers),B["return"](nr(C,m,l.status,a,l.url,b))}})}function vr(a){var b={};a.forEach(function(c,d){b[d.trim()]=c});return b}
724
+ function wr(){if(window.ReadableStream)try{new ReadableStream({})}catch(a){return!1}else return!1;return!(!window.fetch||!window.AbortController)}J("shaka.net.HttpFetchPlugin",or);or.isSupported=wr;or.parse=pr;var tr=window.fetch,rr=window.AbortController,ur=window.ReadableStream,qr=window.Headers;wr()&&(kf("http",pr,2,!0),kf("https",pr,2,!0),kf("blob",pr,2,!0));function xr(){}
725
+ function yr(a,b,c,d,e){var f=new zr,g=Date.now(),h=0,k=new Promise(function(l,m){f.open(b.method,a,!0);f.responseType="arraybuffer";f.timeout=b.retryParameters.timeout;f.withCredentials=b.allowCrossSiteCredentials;f.onabort=function(){m(new O(1,1,7001,a,c))};var n=!1;f.onreadystatechange=function(){if(2==f.readyState&&!n){var r=Ar(f);e(r);n=!0}};f.onload=function(){var r=Ar(f),w=f.response;try{var y=nr(r,w,f.status,a,f.responseURL,c);l(y)}catch(x){m(x)}};f.onerror=function(r){m(new O(1,1,1002,a,r,
726
+ c))};f.ontimeout=function(){m(new O(1,1,1003,a,c))};f.onprogress=function(r){var w=Date.now();if(100<w-g||r.lengthComputable&&r.loaded==r.total)d(w-g,r.loaded-h,r.total-r.loaded),h=r.loaded,g=w};for(var p in b.headers)f.setRequestHeader(p.toLowerCase(),b.headers[p]);f.send(b.body)});return new Ye(k,function(){f.abort();return Promise.resolve()})}
727
+ function Ar(a){var b=a.getAllResponseHeaders().trim().split("\r\n");a={};b=t(b);for(var c=b.next();!c.done;c=b.next())c=c.value.split(": "),a[c[0].toLowerCase()]=c.slice(1).join(": ");return a}J("shaka.net.HttpXHRPlugin",xr);xr.parse=yr;var zr=window.XMLHttpRequest;kf("http",yr,1,!0);kf("https",yr,1,!0);kf("blob",yr,1,!0);function Br(a,b,c,d){this.g=a;this.i=b;this.groupId=c;this.h=d}function Cr(a){return a.Pa().map(function(b){return"{"+encodeURI(b)+"}"}).join("")+":"+a.Ta+":"+a.Ca}function Dr(a,b){return rj(a.g.Pa(),a.g.Ta,a.g.Ca,b.streaming.retryParameters)};function Er(){this.h=this.j=this.i=0;this.g=new Map;this.l=0}function Fr(a,b){a.i+=b;var c=a.l;a.l++;a.g.set(c,b);return c}Er.prototype.close=function(a,b){if(this.g.has(a)){var c=this.g.get(a);this.g["delete"](a);this.j+=c;this.h+=b}};function Gr(a){var b=this;this.A=a;this.j=new Map;this.i=new uf(function(){return Hr(b)["catch"](function(){})});this.h=[];this.m=function(){};this.l=function(){};this.g=new Er}Gr.prototype.destroy=function(){return this.i.destroy()};function Ir(a,b,c){a.m=b;a.l=c}function Hr(a){var b=a.h.map(function(c){return c()});a.h=[];return Promise.all(b)}
728
+ function Jr(a,b,c,d,e,f){vf(a.i);var g=(a.j.get(b)||Promise.resolve()).then(function(){var h,k,l,m,n,p,r;return I(function(w){if(1==w.g)return u(w,Kr(a,c),2);h=w.h;if(a.i.g)throw new O(2,9,7001);if(e)for(m in k=Gc(h),l=new Qn(k),l.data)n=Number(m),p=l.data[n],r=l.g[n],a.l(p,r);a.g.close(d,h.byteLength);var y=a.g;a.m(0==y.i?0:y.j/y.i,a.g.h);return w["return"](f(h))})});a.j.set(b,g)}function Lr(a){return I(function(b){return 1==b.g?u(b,Promise.all(a.j.values()),2):b["return"](a.g.h)})}
729
+ function Kr(a,b){var c,d,e,f;return I(function(g){if(1==g.g)return c=tf,d=a.A.request(c,b),e=function(){return d.abort()},a.h.push(e),u(g,d.promise,2);f=g.h;dc(a.h,e);return g["return"](f.data)})};function Mr(a,b){var c=this;this.i=a;this.h=a.objectStore(b);this.g=new Nc;a.onabort=function(d){d.preventDefault();c.g.reject()};a.onerror=function(d){d.preventDefault();c.g.reject()};a.oncomplete=function(){c.g.resolve()}}Mr.prototype.abort=function(){var a=this;return I(function(b){if(1==b.g){try{a.i.abort()}catch(c){}A(b,2);return u(b,a.g,4)}if(2!=b.g)return va(b,0);F(b);z(b)})};
730
+ function Nr(a,b){return new Promise(function(c,d){var e=a.h.openCursor();e.onerror=d;e.onsuccess=function(){var f;return I(function(g){if(1==g.g){if(null==e.result)return c(),g["return"]();f=e.result;return u(g,b(f.key,f.value,f),2)}f["continue"]();z(g)})}})}Mr.prototype.store=function(){return this.h};Mr.prototype.promise=function(){return this.g};function Or(a){this.h=a;this.g=[]}Or.prototype.destroy=function(){return Promise.all(this.g.map(function(a){return a.abort()}))};function Pr(a,b){return Qr(a,b,"readwrite")}function Qr(a,b,c){c=a.h.transaction([b],c);var d=new Mr(c,b);a.g.push(d);d.promise().then(function(){dc(a.g,d)},function(){dc(a.g,d)});return d};function Rr(a,b,c){this.h=new Or(a);this.i=b;this.g=c}q=Rr.prototype;q.destroy=function(){return this.h.destroy()};q.hasFixedKeySpace=function(){return!0};q.addSegments=function(){return Sr(this.i)};q.removeSegments=function(a,b){return Tr(this,this.i,a,b)};q.getSegments=function(a){var b=this,c;return I(function(d){if(1==d.g)return u(d,Ur(b,b.i,a),2);c=d.h;return d["return"](c.map(function(e){return b.ef(e)}))})};q.addManifests=function(){return Sr(this.g)};
731
+ q.updateManifest=function(){return Promise.reject(new O(2,9,9016,"Cannot modify values in "+this.g))};function Vr(a,b,c){a=Pr(a.h,a.g);var d=a.store();d.get(b).onsuccess=function(){d.put(c,b)};return a.promise()}q.updateManifestExpiration=function(a,b){var c=Pr(this.h,this.g),d=c.store();d.get(a).onsuccess=function(e){if(e=e.target.result)e.expiration=b,d.put(e,a)};return c.promise()};q.removeManifests=function(a,b){return Tr(this,this.g,a,b)};
732
+ q.getManifests=function(a){var b=this,c;return I(function(d){if(1==d.g)return u(d,Ur(b,b.g,a),2);c=d.h;return d["return"](Promise.all(c.map(function(e){return b.Ac(e)})))})};q.getAllManifests=function(){var a=this,b,c;return I(function(d){return 1==d.g?(b=Qr(a.h,a.g,"readonly"),c=new Map,u(d,Nr(b,function(e,f){var g;return I(function(h){if(1==h.g)return u(h,a.Ac(f),2);g=h.h;c.set(e,g);z(h)})}),2)):3!=d.g?u(d,b.promise(),3):d["return"](c)})};q.ef=function(a){return a};q.Ac=function(a){return Promise.resolve(a)};
733
+ function Sr(a){return Promise.reject(new O(2,9,9011,"Cannot add new value to "+a))}q.add=function(a,b){var c=this,d,e,f,g,h,k,l;return I(function(m){if(1==m.g){d=Pr(c.h,a);e=d.store();f=[];g={};h=t(b);for(k=h.next();!k.done;g={Zc:g.Zc},k=h.next())l=k.value,g.Zc=e.add(l),g.Zc.onsuccess=function(n){return function(){f.push(n.Zc.result)}}(g);return u(m,d.promise(),2)}return m["return"](f)})};
734
+ function Tr(a,b,c,d){a=Pr(a.h,b);b=a.store();var e={};c=t(c);for(var f=c.next();!f.done;e={Yc:e.Yc},f=c.next())e.Yc=f.value,b["delete"](e.Yc).onsuccess=function(g){return function(){return d(g.Yc)}}(e);return a.promise()}
735
+ function Ur(a,b,c){var d,e,f,g,h,k,l;return I(function(m){if(1==m.g){d=Qr(a.h,b,"readonly");e=d.store();f={};g=[];h={};k=t(c);for(l=k.next();!l.done;h={wc:h.wc,tc:h.tc},l=k.next())h.tc=l.value,h.wc=e.get(h.tc),h.wc.onsuccess=function(n){return function(){void 0==n.wc.result&&g.push(n.tc);f[n.tc]=n.wc.result}}(h);return u(m,d.promise(),2)}if(g.length)throw new O(2,9,9012,"Could not find values for "+g);return m["return"](c.map(function(n){return f[n]}))})};function Wr(a){this.g=new Or(a)}Wr.prototype.destroy=function(){return this.g.destroy()};Wr.prototype.getAll=function(){var a=this,b,c;return I(function(d){return 1==d.g?(b=Qr(a.g,"session-ids","readonly"),c=[],u(d,Nr(b,function(e,f){c.push(f)}),2)):3!=d.g?u(d,b.promise(),3):d["return"](c)})};Wr.prototype.add=function(a){var b=Pr(this.g,"session-ids"),c=b.store();a=t(a);for(var d=a.next();!d.done;d=a.next())c.add(d.value);return b.promise()};
736
+ Wr.prototype.remove=function(a){var b=this,c;return I(function(d){return 1==d.g?(c=Pr(b.g,"session-ids"),u(d,Nr(c,function(e,f,g){a.includes(f.sessionId)&&g["delete"]()}),2)):u(d,c.promise(),0)})};function Xr(){this.g=new Map}Xr.prototype.destroy=function(){for(var a=[],b=t(this.g.values()),c=b.next();!c.done;c=b.next())a.push(c.value.destroy());this.g.clear();return Promise.all(a)};Xr.prototype.init=function(){var a=this;Yr.forEach(function(e,f){var g=e();g&&a.g.set(f,g)});for(var b=[],c=t(this.g.values()),d=c.next();!d.done;d=c.next())b.push(d.value.init());return Promise.all(b)};
737
+ function Zr(a){var b=null;a.g.forEach(function(c,d){c.getCells().forEach(function(e,f){e.hasFixedKeySpace()||b||(b={path:{Sa:d,Ba:f},Ba:e})})});if(b)return b;throw new O(2,9,9013,"Could not find a cell that supports add-operations");}function $r(a,b){a.g.forEach(function(c,d){c.getCells().forEach(function(e,f){b({Sa:d,Ba:f},e)})})}
738
+ function as(a,b,c){a=a.g.get(b);if(!a)throw new O(2,9,9013,"Could not find mechanism with name "+b);b=a.getCells().get(c);if(!b)throw new O(2,9,9013,"Could not find cell with name "+c);return b}function bs(a,b){a.g.forEach(function(c){b(c.getEmeSessionCell())})}function cs(a){var b=Array.from(a.g.keys());if(!b.length)throw new O(2,9,9E3,"No supported storage mechanisms found");return a.g.get(b[0]).getEmeSessionCell()}
739
+ function ds(a){var b,c,d;return I(function(e){return 1==e.g?(b=Array.from(a.g.values()),c=0<b.length,c||(d=Yr,d.forEach(function(f){(f=f())&&b.push(f)})),u(e,Promise.all(b.map(function(f){return f.erase()})),2)):c?e.D(0):u(e,Promise.all(b.map(function(f){return f.destroy()})),0)})}function es(a,b){Yr.set(a,b)}J("shaka.offline.StorageMuxer",Xr);Xr.unregister=function(a){Yr["delete"](a)};Xr.register=es;Xr.prototype.destroy=Xr.prototype.destroy;var Yr=new Map;function fs(){Rr.apply(this,arguments)}qa(fs,Rr);fs.prototype.updateManifestExpiration=function(a,b){var c=this,d,e,f;return I(function(g){d=Pr(c.h,c.g);e=d.store();f=new Nc;e.get(a).onsuccess=function(h){(h=h.target.result)?(h.expiration=b,e.put(h),f.resolve()):f.reject(new O(2,9,9012,"Could not find values for "+a))};return u(g,Promise.all([d.promise(),f]),0)})};
740
+ fs.prototype.Ac=function(a){var b,c,d,e,f,g;return I(function(h){if(1==h.g){b=[];for(c=0;c<a.periods.length;++c)d=c==a.periods.length-1?a.duration:a.periods[c+1].startTime,e=d-a.periods[c].startTime,f=gs(a.periods[c],e),b.push(f);return u(h,qp(b),2)}g=h.h;return h["return"]({creationTime:0,originalManifestUri:a.originalManifestUri,duration:a.duration,size:a.size,expiration:null==a.expiration?Infinity:a.expiration,streams:g,sessionIds:a.sessionIds,drmInfo:a.drmInfo,appMetadata:a.appMetadata,sequenceMode:!1})})};
741
+ function gs(a,b){hs(a);for(var c=t(a.streams),d=c.next();!d.done;d=c.next());return a.streams.map(function(e){return is(e,a.startTime,b)})}
742
+ function is(a,b,c){var d=a.initSegmentUri?js(a.initSegmentUri):null,e=b+a.presentationTimeOffset,f=b+c;return{id:a.id,originalId:null,primary:a.primary,type:a.contentType,mimeType:a.mimeType,codecs:a.codecs,frameRate:a.frameRate,pixelAspectRatio:void 0,hdr:void 0,kind:a.kind,language:a.language,label:a.label,width:a.width,height:a.height,initSegmentKey:d,encrypted:a.encrypted,keyIds:new Set([a.keyId]),segments:a.segments.map(function(g){var h=js(g.uri);return{startTime:b+g.startTime,endTime:b+g.endTime,
743
+ dataKey:h,initSegmentKey:d,appendWindowStart:b,appendWindowEnd:f,timestampOffset:e,tilesLayout:""}}),variantIds:a.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0}}fs.prototype.ef=function(a){return{data:a.data}};function js(a){var b;if((b=/^offline:[0-9]+\/[0-9]+\/([0-9]+)$/.exec(a))||(b=/^offline:segment\/([0-9]+)$/.exec(a)))return Number(b[1]);throw new O(2,9,9004,"Could not parse uri "+a);}
744
+ function hs(a){var b=a.streams.filter(function(h){return"audio"==h.contentType});a=a.streams.filter(function(h){return"video"==h.contentType});if(!b.every(function(h){return h.variantIds})||!a.every(function(h){return h.variantIds})){for(var c=t(b),d=c.next();!d.done;d=c.next())d.value.variantIds=[];c=t(a);for(d=c.next();!d.done;d=c.next())d.value.variantIds=[];c=0;if(a.length&&!b.length){var e=c++,f=t(a);for(d=f.next();!d.done;d=f.next())d.value.variantIds.push(e)}if(!a.length&&b.length)for(e=c++,
745
+ f=t(b),d=f.next();!d.done;d=f.next())d.value.variantIds.push(e);if(a.length&&b.length)for(b=t(b),d=b.next();!d.done;d=b.next())for(d=d.value,e=t(a),f=e.next();!f.done;f=e.next()){f=f.value;var g=c++;d.variantIds.push(g);f.variantIds.push(g)}}};function ks(){Rr.apply(this,arguments)}qa(ks,Rr);
746
+ ks.prototype.Ac=function(a){var b,c,d,e,f,g;return I(function(h){if(1==h.g){b=[];for(c=0;c<a.periods.length;++c){d=c==a.periods.length-1?a.duration:a.periods[c+1].startTime;e=d-a.periods[c].startTime;for(var k=a.periods[c],l=[],m=t(k.streams),n=m.next();!n.done;n=m.next())n=n.value,0!=n.variantIds.length&&l.push(ls(n,k.startTime,k.startTime+e));f=l;b.push(f)}return u(h,qp(b),2)}g=h.h;return h["return"]({appMetadata:a.appMetadata,creationTime:0,drmInfo:a.drmInfo,duration:a.duration,expiration:null==
745
747
  a.expiration?Infinity:a.expiration,originalManifestUri:a.originalManifestUri,sessionIds:a.sessionIds,size:a.size,streams:g,sequenceMode:!1})})};
746
- function is(a,b,c){return{id:a.id,originalId:a.originalId,primary:a.primary,type:a.contentType,mimeType:a.mimeType,codecs:a.codecs,frameRate:a.frameRate,pixelAspectRatio:a.pixelAspectRatio,hdr:void 0,kind:a.kind,language:a.language,label:a.label,width:a.width,height:a.height,encrypted:a.encrypted,keyIds:new Set([a.keyId]),segments:a.segments.map(function(d){return{startTime:b+d.startTime,endTime:b+d.endTime,initSegmentKey:a.initSegmentKey,appendWindowStart:b,appendWindowEnd:c,timestampOffset:b-a.presentationTimeOffset,
747
- dataKey:d.dataKey,tilesLayout:""}}),variantIds:a.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0}};function js(){Or.apply(this,arguments)}qa(js,Or);q=js.prototype;q.hasFixedKeySpace=function(){return!1};q.addSegments=function(a){return this.add(this.i,a)};q.addManifests=function(a){return this.add(this.g,a)};q.updateManifest=function(a,b){return Sr(this,a,b)};q.Ac=function(a){null==a.expiration&&(a.expiration=Infinity);return Promise.resolve(a)};function ks(){this.m=this.j=this.i=this.h=this.g=this.l=null}q=ks.prototype;
748
- q.init=function(){var a=this,b=new Nc,c=window.indexedDB.open("shaka_offline_db",5);c.onsuccess=function(){var d=c.result;a.l=d;var e=d.objectStoreNames;e=e.contains("manifest")&&e.contains("segment")?new cs(d,"segment","manifest"):null;a.g=e;e=d.objectStoreNames;e=e.contains("manifest-v2")&&e.contains("segment-v2")?new hs(d,"segment-v2","manifest-v2"):null;a.h=e;e=d.objectStoreNames;e=e.contains("manifest-v3")&&e.contains("segment-v3")?new hs(d,"segment-v3","manifest-v3"):null;a.i=e;e=d.objectStoreNames;
749
- e=e.contains("manifest-v5")&&e.contains("segment-v5")?new js(d,"segment-v5","manifest-v5"):null;a.j=e;d=d.objectStoreNames.contains("session-ids")?new Tr(d):null;a.m=d;b.resolve()};c.onupgradeneeded=function(){for(var d=c.result,e=t(["segment-v5","manifest-v5","session-ids"]),f=e.next();!f.done;f=e.next())f=f.value,d.objectStoreNames.contains(f)||d.createObjectStore(f,{autoIncrement:!0})};c.onerror=function(d){b.reject(new O(2,9,9001,c.error));d.preventDefault()};return b};
748
+ function ls(a,b,c){return{id:a.id,originalId:a.originalId,primary:a.primary,type:a.contentType,mimeType:a.mimeType,codecs:a.codecs,frameRate:a.frameRate,pixelAspectRatio:a.pixelAspectRatio,hdr:void 0,kind:a.kind,language:a.language,label:a.label,width:a.width,height:a.height,encrypted:a.encrypted,keyIds:new Set([a.keyId]),segments:a.segments.map(function(d){return{startTime:b+d.startTime,endTime:b+d.endTime,initSegmentKey:a.initSegmentKey,appendWindowStart:b,appendWindowEnd:c,timestampOffset:b-a.presentationTimeOffset,
749
+ dataKey:d.dataKey,tilesLayout:""}}),variantIds:a.variantIds,roles:[],forced:!1,audioSamplingRate:null,channelsCount:null,spatialAudio:!1,closedCaptions:null,tilesLayout:void 0}};function ms(){Rr.apply(this,arguments)}qa(ms,Rr);q=ms.prototype;q.hasFixedKeySpace=function(){return!1};q.addSegments=function(a){return this.add(this.i,a)};q.addManifests=function(a){return this.add(this.g,a)};q.updateManifest=function(a,b){return Vr(this,a,b)};q.Ac=function(a){null==a.expiration&&(a.expiration=Infinity);return Promise.resolve(a)};function ns(){this.m=this.j=this.i=this.h=this.g=this.l=null}q=ns.prototype;
750
+ q.init=function(){var a=this,b=new Nc,c=window.indexedDB.open("shaka_offline_db",5);c.onsuccess=function(){var d=c.result;a.l=d;var e=d.objectStoreNames;e=e.contains("manifest")&&e.contains("segment")?new fs(d,"segment","manifest"):null;a.g=e;e=d.objectStoreNames;e=e.contains("manifest-v2")&&e.contains("segment-v2")?new ks(d,"segment-v2","manifest-v2"):null;a.h=e;e=d.objectStoreNames;e=e.contains("manifest-v3")&&e.contains("segment-v3")?new ks(d,"segment-v3","manifest-v3"):null;a.i=e;e=d.objectStoreNames;
751
+ e=e.contains("manifest-v5")&&e.contains("segment-v5")?new ms(d,"segment-v5","manifest-v5"):null;a.j=e;d=d.objectStoreNames.contains("session-ids")?new Wr(d):null;a.m=d;b.resolve()};c.onupgradeneeded=function(){for(var d=c.result,e=t(["segment-v5","manifest-v5","session-ids"]),f=e.next();!f.done;f=e.next())f=f.value,d.objectStoreNames.contains(f)||d.createObjectStore(f,{autoIncrement:!0})};c.onerror=function(d){b.reject(new O(2,9,9001,c.error));d.preventDefault()};return b};
750
752
  q.destroy=function(){var a=this;return I(function(b){switch(b.g){case 1:if(!a.g){b.D(2);break}return u(b,a.g.destroy(),2);case 2:if(!a.h){b.D(4);break}return u(b,a.h.destroy(),4);case 4:if(!a.i){b.D(6);break}return u(b,a.i.destroy(),6);case 6:if(!a.j){b.D(8);break}return u(b,a.j.destroy(),8);case 8:if(!a.m){b.D(10);break}return u(b,a.m.destroy(),10);case 10:a.l&&a.l.close(),z(b)}})};
751
753
  q.getCells=function(){var a=new Map;this.g&&a.set("v1",this.g);this.h&&a.set("v2",this.h);this.i&&a.set("v3",this.i);this.j&&a.set("v5",this.j);return a};q.getEmeSessionCell=function(){return this.m};
752
- q.erase=function(){var a=this;return I(function(b){switch(b.g){case 1:if(!a.g){b.D(2);break}return u(b,a.g.destroy(),2);case 2:if(!a.h){b.D(4);break}return u(b,a.h.destroy(),4);case 4:if(!a.i){b.D(6);break}return u(b,a.i.destroy(),6);case 6:if(!a.j){b.D(8);break}return u(b,a.j.destroy(),8);case 8:return a.l&&a.l.close(),u(b,ls(),10);case 10:return a.l=null,a.g=null,a.h=null,a.i=null,a.j=null,u(b,a.init(),0)}})};
753
- function ls(){var a=new Nc,b=window.indexedDB.deleteDatabase("shaka_offline_db");b.onblocked=function(){};b.onsuccess=function(){a.resolve()};b.onerror=function(c){a.reject(new O(2,9,9001,b.error));c.preventDefault()};return a}bs("idb",function(){return Hd()||Bd()||!window.indexedDB?null:new ks});function ms(a,b,c,d){this.g=a;this.i=b;this.h=c;this.l=d;this.j=["offline:",a,"/",b,"/",c,"/",d].join("")}ms.prototype.Sa=function(){return this.i};ms.prototype.Ba=function(){return this.h};ms.prototype.key=function(){return this.l};ms.prototype.toString=function(){return this.j};
754
- function ns(a){a=/^offline:([a-z]+)\/([^/]+)\/([^/]+)\/([0-9]+)$/.exec(a);if(null==a)return null;var b=a[1];if("manifest"!=b&&"segment"!=b)return null;var c=a[2];if(!c)return null;var d=a[3];return d&&null!=b?new ms(b,c,d,Number(a[4])):null};function os(a,b){this.h=a;this.g=b}
755
- function ps(a,b){var c=new Q(null,0);c.bb(b.duration);var d=b.streams.filter(function(l){return"audio"==l.type}),e=b.streams.filter(function(l){return"video"==l.type});d=qs(a,d,e,c);e=b.streams.filter(function(l){return l.type==Ib}).map(function(l){return rs(a,l,c)});var f=b.streams.filter(function(l){return"image"==l.type}).map(function(l){return rs(a,l,c)}),g=b.drmInfo?[b.drmInfo]:[];if(b.drmInfo)for(var h=t(d.values()),k=h.next();!k.done;k=h.next())k=k.value,k.audio&&k.audio.encrypted&&(k.audio.drmInfos=
754
+ q.erase=function(){var a=this;return I(function(b){switch(b.g){case 1:if(!a.g){b.D(2);break}return u(b,a.g.destroy(),2);case 2:if(!a.h){b.D(4);break}return u(b,a.h.destroy(),4);case 4:if(!a.i){b.D(6);break}return u(b,a.i.destroy(),6);case 6:if(!a.j){b.D(8);break}return u(b,a.j.destroy(),8);case 8:return a.l&&a.l.close(),u(b,os(),10);case 10:return a.l=null,a.g=null,a.h=null,a.i=null,a.j=null,u(b,a.init(),0)}})};
755
+ function os(){var a=new Nc,b=window.indexedDB.deleteDatabase("shaka_offline_db");b.onblocked=function(){};b.onsuccess=function(){a.resolve()};b.onerror=function(c){a.reject(new O(2,9,9001,b.error));c.preventDefault()};return a}es("idb",function(){return Yc()||Uc()||!window.indexedDB?null:new ns});function ps(a,b,c,d){this.g=a;this.i=b;this.h=c;this.l=d;this.j=["offline:",a,"/",b,"/",c,"/",d].join("")}ps.prototype.Sa=function(){return this.i};ps.prototype.Ba=function(){return this.h};ps.prototype.key=function(){return this.l};ps.prototype.toString=function(){return this.j};
756
+ function qs(a){a=/^offline:([a-z]+)\/([^/]+)\/([^/]+)\/([0-9]+)$/.exec(a);if(null==a)return null;var b=a[1];if("manifest"!=b&&"segment"!=b)return null;var c=a[2];if(!c)return null;var d=a[3];return d&&null!=b?new ps(b,c,d,Number(a[4])):null};function rs(a,b){this.h=a;this.g=b}
757
+ function ss(a,b){var c=new Q(null,0);c.bb(b.duration);var d=b.streams.filter(function(l){return"audio"==l.type}),e=b.streams.filter(function(l){return"video"==l.type});d=ts(a,d,e,c);e=b.streams.filter(function(l){return l.type==Ib}).map(function(l){return us(a,l,c)});var f=b.streams.filter(function(l){return"image"==l.type}).map(function(l){return us(a,l,c)}),g=b.drmInfo?[b.drmInfo]:[];if(b.drmInfo)for(var h=t(d.values()),k=h.next();!k.done;k=h.next())k=k.value,k.audio&&k.audio.encrypted&&(k.audio.drmInfos=
756
758
  g),k.video&&k.video.encrypted&&(k.video.drmInfos=g);return{presentationTimeline:c,minBufferTime:2,offlineSessionIds:b.sessionIds,variants:Array.from(d.values()),textStreams:e,imageStreams:f,sequenceMode:b.sequenceMode||!1}}
757
- function qs(a,b,c,d){for(var e=new Set,f=t(b),g=f.next();!g.done;g=f.next()){var h=t(g.value.variantIds);for(g=h.next();!g.done;g=h.next())e.add(g.value)}f=t(c);for(g=f.next();!g.done;g=f.next())for(h=t(g.value.variantIds),g=h.next();!g.done;g=h.next())e.add(g.value);f=new Map;e=t(e);for(g=e.next();!g.done;g=e.next())g=g.value,f.set(g,{id:g,language:"",disabledUntilTime:0,primary:!1,audio:null,video:null,bandwidth:0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});b=t(b);for(e=b.next();!e.done;e=
758
- b.next())for(e=e.value,g=rs(a,e,d),h=t(e.variantIds),e=h.next();!e.done;e=h.next())e=f.get(e.value),e.language=g.language,e.primary=e.primary||g.primary,e.audio=g;c=t(c);for(b=c.next();!b.done;b=c.next())for(e=b.value,b=rs(a,e,d),g=t(e.variantIds),e=g.next();!e.done;e=g.next())e=f.get(e.value),e.primary=e.primary||b.primary,e.video=b;return f}
759
- function rs(a,b,c){var d=b.segments.map(function(e){return ss(a,e)});c.ic(d);return{id:b.id,originalId:b.originalId,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new Xi(d),mimeType:b.mimeType,codecs:b.codecs,width:b.width||void 0,height:b.height||void 0,frameRate:b.frameRate,pixelAspectRatio:b.pixelAspectRatio,hdr:b.hdr,kind:b.kind,encrypted:b.encrypted,drmInfos:[],keyIds:b.keyIds,language:b.language,label:b.label,type:b.type,primary:b.primary,trickModeVideo:null,emsgSchemeIdUris:null,
760
- roles:b.roles,forced:b.forced,channelsCount:b.channelsCount,audioSamplingRate:b.audioSamplingRate,spatialAudio:b.spatialAudio,closedCaptions:b.closedCaptions,tilesLayout:b.tilesLayout}}function ss(a,b){var c=new ms("segment",a.h,a.g,b.dataKey);return new yi(b.startTime,b.endTime,function(){return[c.toString()]},0,null,null!=b.initSegmentKey?ts(a,b.initSegmentKey):null,b.timestampOffset,b.appendWindowStart,b.appendWindowEnd,[],b.tilesLayout||"")}
761
- function ts(a,b){var c=new ms("segment",a.h,a.g,b);return new wi(function(){return[c.toString()]},0,null)};function us(){this.g=null}q=us.prototype;q.configure=function(){};
762
- q.start=function(a,b){var c=this,d,e,f,g,h,k,l;return I(function(m){switch(m.g){case 1:d=ns(a);c.g=d;if(null==d||"manifest"!=d.g)throw new O(2,1,9004,a);e=new Ur;ua(m);return u(m,e.init(),4);case 4:return u(m,Yr(e,d.Sa(),d.Ba()),5);case 5:return f=m.h,u(m,f.getManifests([d.key()]),6);case 6:return g=m.h,h=g[0],k=new os(d.Sa(),d.Ba()),l=ps(k,h),b.makeTextStreamsForClosedCaptions(l),m["return"](l);case 2:return wa(m),u(m,e.destroy(),7);case 7:ya(m,0)}})};q.stop=function(){return Promise.resolve()};
763
- q.update=function(){};q.onExpirationUpdated=function(a,b){var c=this,d,e,f,g,h,k,l;return I(function(m){switch(m.g){case 1:return d=c.g,e=new Ur,A(m,2,3),u(m,e.init(),5);case 5:return u(m,Yr(e,d.Sa(),d.Ba()),6);case 6:return f=m.h,u(m,f.getManifests([d.key()]),7);case 7:g=m.h;h=g[0];k=h.sessionIds.includes(a);l=void 0==h.expiration||h.expiration>b;if(!k||!l){m.D(3);break}return u(m,f.updateManifestExpiration(d.key(),b),3);case 3:return wa(m),u(m,e.destroy(),10);case 10:ya(m,0);break;case 2:F(m),m.D(3)}})};
764
- qg["application/x-offline-manifest"]=function(){return new us};function vs(){}function ws(a){var b=ns(a);b&&"manifest"==b.g?(a={uri:a,Af:a,data:new ArrayBuffer(0),headers:{"content-type":"application/x-offline-manifest"}},a=Ye(a)):a=b&&"segment"==b.g?xs(b.key(),b):We(new O(2,1,9004,a));return a}
765
- function xs(a,b){var c=new Ur;return Ye(void 0).na(function(){return c.init()}).na(function(){return Yr(c,b.Sa(),b.Ba())}).na(function(d){return d.getSegments([b.key()])}).na(function(d){return{uri:b,data:d[0].data,headers:{}}})["finally"](function(){return c.destroy()})}J("shaka.offline.OfflineScheme",vs);vs.plugin=ws;gf("offline",ws);function ys(a,b,c){var d,e,f,g,h,k;return I(function(l){switch(l.g){case 1:d=[];for(var m=[],n=t(c),p=n.next();!p.done;p=n.next()){p=p.value;for(var r=!1,x=t(m),y=x.next();!y.done;y=x.next())if(y=y.value,zs(y.info,p)){y.sessionIds.push(p.sessionId);r=!0;break}r||m.push({info:p,sessionIds:[p.sessionId]})}e=t(m);f=e.next();case 2:if(f.done){l.D(4);break}g=f.value;h=As(a,b,g);return u(l,h,5);case 5:k=l.h;d=d.concat(k);f=e.next();l.D(2);break;case 4:return l["return"](d)}})}
766
- function As(a,b,c){var d,e;return I(function(f){switch(f.g){case 1:return d=new Bf({Ob:b,onError:function(){},wd:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),A(f,2),d.configure(a),u(f,Jf(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 F(f),u(f,d.destroy(),5);case 5:return f["return"]([]);case 3:return A(f,6),u(f,Uf(d),8);case 8:va(f,7);break;case 6:return F(f),u(f,d.destroy(),
767
- 9);case 9:return f["return"]([]);case 7:return e=[],u(f,Promise.all(c.sessionIds.map(function(g){return I(function(h){if(1==h.g)return A(h,2),u(h,Vf(d,g),4);if(2!=h.g)return e.push(g),va(h,0);F(h);z(h)})})),10);case 10:return u(f,d.destroy(),11);case 11:return f["return"](e)}})}
768
- function zs(a,b){function c(d,e){return d.robustness==e.robustness&&d.contentType==e.contentType}return a.keySystem==b.keySystem&&a.licenseUri==b.licenseUri&&ec(a.audioCapabilities,b.audioCapabilities,c)&&ec(a.videoCapabilities,b.videoCapabilities,c)};function Bs(a,b,c){var d=b.presentationTimeline.getDuration();b=Cs(b);return{offlineUri:null,originalManifestUri:a,duration:d,size:0,expiration:Infinity,tracks:b,appMetadata:c,isIncomplete:!1}}function Ds(a,b){var c=ps(new os(a.Sa(),a.Ba()),b),d=b.appMetadata||{};c=Cs(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}}
769
- function Cs(a){var b=[],c=xe(a.variants);c=t(c);for(var d=c.next();!d.done;d=c.next())b.push(oe(d.value));a=t(a.textStreams);for(c=a.next();!c.done;c=a.next())b.push(pe(c.value));return b};function Es(){this.g={}}function Fs(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 Gs(a,b){a.g[b.id]=b.bandwidth||2048}function Hs(a,b){var c=a.g[b];null==c&&(c=0);return c};function Is(a){var b=this;if(a&&a.constructor!=S)throw new O(2,9,9008);this.g=this.h=null;a?(this.h=a.h,this.g=a.Ec()):(this.h=Lk(),this.g=new ff);this.i=[];this.j=[];var c=!a;this.l=new rf(function(){var d,e,f,g,h;return I(function(k){switch(k.g){case 1:return u(k,Promise.all(b.j.map(function(l){return Er(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 u(k,Promise.all(e),3);case 3:if(!c){k.D(4);break}return u(k,b.g.destroy(),4);
770
- case 4:b.h=null,b.g=null,z(k)}})})}function Js(){if(yd())a:{var a=t(Vr.values());for(var b=a.next();!b.done;b=a.next())if(b=b.value,b=b()){b.destroy();a=!0;break a}a=!1}else a=!1;return a}q=Is.prototype;q.destroy=function(){return this.l.destroy()};q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=Ik(a,b));return Nk(this.h,a)};q.getConfiguration=function(){var a=Lk();Nk(a,this.h,Lk());return a};q.Ec=function(){return this.g};
771
- q.store=function(a,b,c){var d=this,e=this.getConfiguration(),f=new Dr(this.g);this.j.push(f);b=Ks(this,a,b||{},function(){var g;return I(function(h){if(1==h.g)return u(h,pg(a,d.g,e.manifest.retryParameters,c||null),2);g=h.h;return h["return"](g())})},e,f);b=new Ve(b,function(){return Er(f)});b["finally"](function(){dc(d.j,f)});return Ls(this,b)};
772
- function Ks(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,x,y,w,v,D,C;return I(function(B){switch(B.g){case 1:return Ms(),h=g=null,k=new Ur,n=m=l=null,A(B,2,3),u(B,d(),5);case 5:return g=B.h,u(B,Ns(a,b,g,e),6);case 6:p=B.h;Os(a);r=!p.presentationTimeline.U()&&!p.presentationTimeline.Lb();if(!r)throw new O(2,9,9005,b);return u(B,Ps(a,p,function(G){n=n||G},e),7);case 7:h=B.h;Os(a);if(n)throw n;return u(B,Qs(p,e),8);case 8:return u(B,k.init(),9);case 9:return Os(a),u(B,Wr(k),10);case 10:return l=B.h,Os(a),x=Rs(h,
773
- p,b,c,e,f),y=x.Og,w=x.Ke,u(B,l.Ba.addManifests([y]),11);case 11:v=B.h;Os(a);m=v[0];Os(a);if(n)throw n;return u(B,Ss(a,w,m,y,f,e,l.Ba,p,h),12);case 12:return Os(a),D=new ms("manifest",l.path.Sa,l.path.Ba,m),B["return"](Ds(D,y));case 3:return wa(B),u(B,k.destroy(),13);case 13:if(!g){B.D(14);break}return u(B,g.stop(),14);case 14:if(!h){B.D(16);break}return u(B,h.destroy(),16);case 16:ya(B,0);break;case 2:C=F(B);if(null==m){B.D(18);break}return u(B,Ts(m),18);case 18:throw n||C;}})}
774
- function Ss(a,b,c,d,e,f,g,h,k){var l,m,n,p,r,x,y,w,v,D;return I(function(C){switch(C.g){case 1:l={};m=0;n=function(B,G){var E,H,L,K,N,V,Z;return I(function(ha){if(1==ha.g){E={};H=t(B);for(L=H.next();!L.done;E={Eb:E.Eb},L=H.next())E.Eb=L.value,K=Ar(E.Eb,f),N=E.Eb.i,V=E.Eb.h,Z=function(ja){return function(xa){var La,Fa,Ra;return I(function(Ga){if(1==Ga.g)return u(Ga,g.addSegments([{data:xa}]),2);La=Ga.h;Os(a);Fa=ja.Eb.g;Ra=zr(Fa);l[Ra]=La[0];m+=xa.byteLength;z(Ga)})}}(E),Gr(e,E.Eb.groupId,K,N,V,Z);
775
- return u(ha,Ir(e),2)}if(!G)return ha.D(0);Os(a);Us(h,d,k,f);return u(ha,g.updateManifest(c,d),0)})};p=!1;A(C,2);if(!Vs(h)||!p||Ws(h)){C.D(4);break}return u(C,n(b.filter(function(B){return B.h}),!0),5);case 5:return Os(a),b=b.filter(function(B){return!B.h}),r=l,x=m,l={},m=0,u(C,Xs(g,c,d,r,x,function(){return Os(a)}),6);case 6:Os(a);case 4:if(p){C.D(7);break}return u(C,n(b,!1),8);case 8:return Os(a),y=l,w=m,l={},m=0,u(C,Xs(g,c,d,y,w,function(){return Os(a)}),9);case 9:Os(a);case 7:va(C,0);break;case 2:return v=
776
- F(C),D=Object.values(l),u(C,g.removeSegments(D,function(){}),10);case 10:throw v;}})}function Ts(a){var b,c,d,e;return I(function(f){switch(f.g){case 1:return b=new Ur,u(f,b.init(),2);case 2:return u(f,Wr(b),3);case 3:return c=f.h,d=new ms("manifest",c.path.Sa,c.path.Ba,a),u(f,b.destroy(),4);case 4:return e=new Is,u(f,e.remove(d.toString()),0)}})}
777
- function Xs(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,x,y,w;return I(function(v){switch(v.g){case 1:g=!1;A(v,2);h=!0;k=t(c.streams);for(l=k.next();!l.done;l=k.next())for(m=l.value,n=t(m.segments),p=n.next();!p.done;p=n.next())r=p.value,x=r.pendingSegmentRefId?d[r.pendingSegmentRefId]:null,null!=x&&(r.dataKey=x,r.pendingSegmentRefId=void 0),x=r.pendingInitSegmentRefId?d[r.pendingInitSegmentRefId]:null,null!=x&&(r.initSegmentKey=x,r.pendingInitSegmentRefId=void 0),r.pendingSegmentRefId&&(h=!1),r.pendingInitSegmentRefId&&
778
- (h=!1);c.size+=e;h&&(c.isIncomplete=!1);return u(v,a.updateManifest(b,c),4);case 4:g=!0;f();va(v,0);break;case 2:return y=F(v),u(v,Ts(b),5);case 5:if(g){v.D(6);break}w=Object.values(d);return u(v,a.removeSegments(w,function(){}),6);case 6:throw y;}})}
779
- function Qs(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,x,y,w,v,D,C,B,G,E,H,L,K,N,V,Z,ha,ja;return I(function(xa){switch(xa.g){case 1:return c={width:Infinity,height:Infinity},Yd(a,b.restrictions,c),u(xa,be(a,b.offline.usePersistentLicense),2);case 2:d=[];e=b.preferredAudioChannelCount;f=b.preferredDecodingAttributes;g=b.preferredVideoCodecs;h=b.preferredAudioCodecs;Md(a,g,h,e,f);k=t(a.variants);for(l=k.next();!l.done;l=k.next())m=l.value,d.push(oe(m));n=t(a.textStreams);for(p=n.next();!p.done;p=n.next())r=
780
- p.value,d.push(pe(r));x=t(a.imageStreams);for(y=x.next();!y.done;y=x.next())w=y.value,d.push(qe(w));return u(xa,b.offline.trackSelectionCallback(d),3);case 3:v=xa.h;D=a.presentationTimeline.getDuration();C=0;B=t(v);for(G=B.next();!G.done;G=B.next())E=G.value,H=E.bandwidth*D/8,C+=H;A(xa,4);return u(xa,b.offline.downloadSizeCallback(C),6);case 6:L=xa.h;if(!L)throw new O(2,9,9014);va(xa,5);break;case 4:K=F(xa);if(K instanceof O)throw K;throw new O(2,9,9015);case 5:N=new Set;V=new Set;Z=new Set;ha=t(v);
781
- for(G=ha.next();!G.done;G=ha.next())ja=G.value,"variant"==ja.type&&N.add(ja.id),"text"==ja.type&&V.add(ja.id),"image"==ja.type&&Z.add(ja.id);a.variants=a.variants.filter(function(La){return N.has(La.id)});a.textStreams=a.textStreams.filter(function(La){return V.has(La.id)});a.imageStreams=a.imageStreams.filter(function(La){return Z.has(La.id)});Ys(a);z(xa)}})}
782
- function Rs(a,b,c,d,e,f){var g=Bs(c,b,d),h=e.offline.progressCallback;Fr(f,function(r,x){g.size=x;h(g,r)},function(r,x){k&&e.offline.usePersistentLicense&&l==x&&Rf(a,"cenc",r)});var k=Vs(b)&&!Ws(b),l=null;k&&(l=Zs.get(a.g.keySystem));for(var m=new Es,n=t(b.textStreams),p=n.next();!p.done;p=n.next())m.g[p.value.id]=52;n=t(b.imageStreams);for(p=n.next();!p.done;p=n.next())Gs(m,p.value);p=t(b.variants);for(n=p.next();!n.done;n=p.next())Fs(m,n.value);m=$s(f,m,b,e);f=m.streams;m=m.Ke;p=a.g;n=e.offline.usePersistentLicense;
783
- p&&n&&(p.initData=[]);return{Og:{creationTime:Date.now(),originalManifestUri:c,duration:b.presentationTimeline.getDuration(),size:0,expiration:a.Dc(),streams:f,sessionIds:n?Zf(a):[],drmInfo:p,appMetadata:d,isIncomplete:!0,sequenceMode:b.sequenceMode},Ke:m}}function Vs(a){return a.variants.some(function(b){var c=b.audio&&b.audio.encrypted;return b.video&&b.video.encrypted||c})}
784
- function Ws(a){return a.variants.some(function(b){return(b.video?b.video.drmInfos:[]).concat(b.audio?b.audio.drmInfos:[]).some(function(c){return c.initData&&c.initData.length})})}function Us(a,b,c,d){b.expiration=c.Dc();c=Zf(c);b.sessionIds=d.offline.usePersistentLicense?c:[];if(Vs(a)&&d.offline.usePersistentLicense&&!c.length)throw new O(2,9,9007);}q.remove=function(a){return at(this,bt(this,a))};
785
- function bt(a,b){var c,d,e,f,g,h;return I(function(k){switch(k.g){case 1:Ms();c=ns(b);if(null==c||"manifest"!=c.g)throw new O(2,9,9004,b);d=c;e=new Ur;ua(k);return u(k,e.init(),4);case 4:return u(k,Yr(e,d.Sa(),d.Ba()),5);case 5:return f=k.h,u(k,f.getManifests([d.key()]),6);case 6:return g=k.h,h=g[0],u(k,Promise.all([ct(a,h,e),dt(f,d,h)]),2);case 2:return wa(k),u(k,e.destroy(),8);case 8:ya(k,0)}})}
786
- function et(a,b){for(var c=[],d=t(a.streams),e=d.next();!e.done;e=d.next())e=e.value,b&&"video"==e.type?c.push({contentType:jd(e.mimeType,e.codecs),robustness:a.drmInfo.videoRobustness}):b||"audio"!=e.type||c.push({contentType:jd(e.mimeType,e.codecs),robustness:a.drmInfo.audioRobustness});return c}function ct(a,b,c){return I(function(d){return u(d,ft(a.g,a.h.drm,c,b),0)})}
787
- function dt(a,b,c){function d(){}var e=gt(c);Ds(b,c);return Promise.all([a.removeSegments(e,d),a.removeManifests([b.key()],d)])}q.bh=function(){return at(this,ht(this))};
788
- function ht(a){var b,c,d,e,f,g,h,k,l,m;return I(function(n){switch(n.g){case 1:return Ms(),b=a.g,c=a.h.drm,d=new Ur,e=!1,ua(n),u(n,d.init(),4);case 4:f=[],Zr(d,function(p){return f.push(p)}),g=t(f),h=g.next();case 5:if(h.done){n.D(2);break}k=h.value;return u(n,k.getAll(),8);case 8:return l=n.h,u(n,ys(c,b,l),9);case 9:return m=n.h,u(n,k.remove(m),10);case 10:m.length!=l.length&&(e=!0);h=g.next();n.D(5);break;case 2:return wa(n),u(n,d.destroy(),11);case 11:ya(n,3);break;case 3:return n["return"](!e)}})}
789
- q.list=function(){return at(this,it())};function it(){var a,b,c;return I(function(d){switch(d.g){case 1:return Ms(),a=[],b=new Ur,ua(d),u(d,b.init(),4);case 4:return c=Promise.resolve(),Xr(b,function(e,f){c=c.then(function(){var g;return I(function(h){if(1==h.g)return u(h,f.getAllManifests(),2);g=h.h;g.forEach(function(k,l){var m=Ds(new ms("manifest",e.Sa,e.Ba,l),k);a.push(m)});z(h)})})}),u(d,c,2);case 2:return wa(d),u(d,b.destroy(),6);case 6:ya(d,3);break;case 3:return d["return"](a)}})}
790
- function Ns(a,b,c,d){var e,f,g,h,k;return I(function(l){if(1==l.g)return e=null,f=a.g,g={networkingEngine:f,modifyManifestRequest:function(){},modifySegmentRequest:function(){},filter:function(){return Promise.resolve()},makeTextStreamsForClosedCaptions:function(){},onTimelineRegionAdded:function(){},onEvent:function(){},onError:function(m){e=m},isLowLatencyMode:function(){return!1},isAutoLowLatencyMode:function(){return!1},enableLowLatencyMode:function(){}},c.configure(d.manifest),Os(a),u(l,c.start(b,
791
- g),2);if(3!=l.g)return h=l.h,Os(a),k=jt(h),u(l,Promise.all(gb(k,function(m){return m.createSegmentIndex()})),3);Os(a);if(e)throw e;return l["return"](h)})}function Ps(a,b,c,d){var e;return I(function(f){switch(f.g){case 1:return e=new Bf({Ob:a.g,onError:c,wd:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),e.configure(d.drm),u(f,Gf(e,b.variants,d.offline.usePersistentLicense),2);case 2:return u(f,Uf(e),3);case 3:return u(f,Tf(e),4);case 4:return f["return"](e)}})}
792
- function $s(a,b,c,d){var e=new Map,f=jt(c),g=new Map;f=t(f);for(var h=f.next();!h.done;h=f.next()){h=h.value;var k=kt(a,b,c,h,d,e);g.set(h.id,k)}a=t(c.variants);for(b=a.next();!b.done;b=a.next())b=b.value,b.audio&&g.get(b.audio.id).variantIds.push(b.id),b.video&&g.get(b.video.id).variantIds.push(b.id);return{streams:Array.from(g.values()),Ke:Array.from(e.values())}}
793
- function kt(a,b,c,d,e,f){var g={id:d.id,originalId:d.originalId,primary:d.primary,type:d.type,mimeType:d.mimeType,codecs:d.codecs,frameRate:d.frameRate,pixelAspectRatio:d.pixelAspectRatio,hdr:d.hdr,kind:d.kind,language:d.language,label:d.label,width:d.width||null,height:d.height||null,encrypted:d.encrypted,keyIds:d.keyIds,segments:[],variantIds:[],roles:d.roles,forced:d.forced,channelsCount:d.channelsCount,audioSamplingRate:d.audioSamplingRate,spatialAudio:d.spatialAudio,closedCaptions:d.closedCaptions,
794
- tilesLayout:d.tilesLayout},h=e.offline.numberOfParallelDownloads,k=0;lt(d,c.presentationTimeline.ob(),function(l){var m=zr(l),n=void 0;if(!f.has(m)){var p=l.endTime-l.startTime;p=Hs(b,d.id)*p;p=Cr(a.g,p);f.set(m,new yr(l,p,k,!1))}l.i&&(n=zr(l.i),f.has(n)||(p=.5*Hs(b,d.id),p=Cr(a.g,p),f.set(n,new yr(l.i,p,k,!0))));g.segments.push({pendingInitSegmentRefId:n,initSegmentKey:n?0:null,startTime:l.startTime,endTime:l.endTime,appendWindowStart:l.appendWindowStart,appendWindowEnd:l.appendWindowEnd,timestampOffset:l.timestampOffset,
795
- tilesLayout:l.tilesLayout,pendingSegmentRefId:m,dataKey:0});k=(k+1)%h});return g}function lt(a,b,c){b=a.segmentIndex.find(b);if(null!=b)for(var d=a.segmentIndex.get(b);d;)c(d),d=a.segmentIndex.get(++b)}function Os(a){if(a.l.g)throw new O(2,9,7001);}function Ms(){if(!Js())throw new O(2,9,9E3);}function at(a,b){return I(function(c){if(1==c.g)return a.i.push(b),ua(c),u(c,b,4);if(2!=c.g)return c["return"](c.h);wa(c);dc(a.i,b);return ya(c,0)})}
796
- function Ls(a,b){var c=b.promise;a.i.push(c);return b["finally"](function(){dc(a.i,c)})}function gt(a){var b=new Set;a=t(a.streams);for(var c=a.next();!c.done;c=a.next()){c=t(c.value.segments);for(var d=c.next();!d.done;d=c.next())d=d.value,null!=d.initSegmentKey&&b.add(d.initSegmentKey),b.add(d.dataKey)}return Array.from(b)}
797
- function ft(a,b,c,d){var e,f,g;return I(function(h){if(1==h.g){if(!d.drmInfo)return h["return"]();e=$r(c);f=d.sessionIds.map(function(k){return{sessionId:k,keySystem:d.drmInfo.keySystem,licenseUri:d.drmInfo.licenseServerUri,serverCertificate:d.drmInfo.serverCertificate,audioCapabilities:et(d,!1),videoCapabilities:et(d,!0)}});return u(h,ys(b,a,f),2)}return 3!=h.g?(g=h.h,u(h,e.remove(g),3)):u(h,e.add(f.filter(function(k){return!g.includes(k.sessionId)})),0)})}
798
- function jt(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}
799
- function Ys(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());}J("shaka.offline.Storage",Is);Is.deleteAll=function(){var a;return I(function(b){return 1==b.g?(a=new Ur,ua(b),u(b,as(a),2)):5!=b.g?(wa(b),u(b,a.destroy(),5)):ya(b,0)})};Is.prototype.list=Is.prototype.list;
800
- Is.prototype.removeEmeSessions=Is.prototype.bh;Is.prototype.remove=Is.prototype.remove;Is.prototype.store=Is.prototype.store;Is.prototype.getNetworkingEngine=Is.prototype.Ec;Is.prototype.getConfiguration=Is.prototype.getConfiguration;Is.prototype.configure=Is.prototype.configure;Is.prototype.destroy=Is.prototype.destroy;Is.support=Js;
801
- var Zs=(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");
802
- um.offline=Js;function mt(){}function nt(){for(var a=t(ot),b=a.next();!b.done;b=a.next()){b=b.value;try{b.Wf()}catch(c){Ua("Error installing polyfill!",c)}}}function pt(a,b){for(var c={priority:b||0,Wf:a},d=0;d<ot.length;d++)if(ot[d].priority<c.priority){ot.splice(d,0,c);return}ot.push(c)}J("shaka.polyfill",mt);mt.register=pt;mt.installAll=nt;var ot=[];function qt(){}function rt(){if(!Object.getOwnPropertyDescriptor(Element.prototype,"ariaHidden"))for(var a=t(["ariaHidden","ariaLabel","ariaPressed","ariaSelected"]),b=a.next();!b.done;b=a.next())st(b.value)}function st(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)}})}mt.Aria=qt;qt.install=rt;pt(rt);function tt(){}function ut(){vt()}mt.EncryptionScheme=tt;tt.install=ut;pt(ut,-2);function wt(){}
803
- function xt(){if(window.Document){var a=Element.prototype;a.requestFullscreen=a.requestFullscreen||a.mozRequestFullScreen||a.msRequestFullscreen||a.webkitRequestFullscreen;a=Document.prototype;a.exitFullscreen=a.exitFullscreen||a.mozCancelFullScreen||a.msExitFullscreen||a.webkitCancelFullScreen;"fullscreenElement"in document||(Object.defineProperty(document,"fullscreenElement",{get:function(){return document.mozFullScreenElement||document.msFullscreenElement||document.webkitCurrentFullScreenElement||document.webkitFullscreenElement}}),
804
- Object.defineProperty(document,"fullscreenEnabled",{get:function(){return document.mozFullScreenEnabled||document.msFullscreenEnabled||document.webkitFullscreenEnabled}}));document.addEventListener("webkitfullscreenchange",yt);document.addEventListener("webkitfullscreenerror",yt);document.addEventListener("mozfullscreenchange",yt);document.addEventListener("mozfullscreenerror",yt);document.addEventListener("MSFullscreenChange",yt);document.addEventListener("MSFullscreenError",yt)}}
805
- function yt(a){var b=a.type.replace(/^(webkit|moz|MS)/,"").toLowerCase(),c=document.createEvent("Event");c.initEvent(b,a.bubbles,a.cancelable);a.target.dispatchEvent(c)}mt.Fullscreen=wt;wt.install=xt;pt(xt);function zt(){}function At(){var a=!0;if(Id()||Fd("PlayStation 5")||Hd())a=!1;Hd()&&Fd("Android")&&(a=!0);a&&navigator.mediaCapabilities||(navigator.mediaCapabilities||(navigator.mediaCapabilities={}),Bt=navigator.mediaCapabilities,navigator.mediaCapabilities.decodingInfo=Ct)}
806
- function Ct(a){var b,c,d,e,f,g,h,k,l,m,n,p,r,x,y,w;return I(function(v){switch(v.g){case 1:b={supported:!1,powerEfficient:!0,smooth:!0,keySystemAccess:null,configuration:a};if(!a)return v["return"](b);if("media-source"==a.type){if(!yd()||a.video&&(c=a.video.contentType,d=MediaSource.isTypeSupported(c),!d)||a.audio&&(e=a.audio.contentType,f=MediaSource.isTypeSupported(e),!f))return v["return"](b)}else if("file"==a.type){if(a.video&&(g=a.video.contentType,h=zd(g),!h)||a.audio&&(k=a.audio.contentType,
807
- l=zd(k),!l))return v["return"](b)}else return v["return"](b);if(!a.keySystemConfiguration)return b.supported=!0,v["return"](Promise.resolve(b));m=a.keySystemConfiguration;n=[];p=[];m.audio&&(r={robustness:m.audio.robustness||"",contentType:a.audio.contentType},n.push(r));m.video&&(x={robustness:m.video.robustness||"",contentType:a.video.contentType},p.push(x));y={initDataTypes:[m.initDataType],distinctiveIdentifier:m.distinctiveIdentifier,persistentState:m.persistentState,sessionTypes:m.sessionTypes};
808
- n.length&&(y.audioCapabilities=n);p.length&&(y.videoCapabilities=p);A(v,3);return u(v,navigator.requestMediaKeySystemAccess(m.keySystem,[y]),5);case 5:w=v.h;va(v,4);break;case 3:F(v);case 4:w&&(b.supported=!0,b.keySystemAccess=w);case 2:return v["return"](b)}})}mt.MediaCapabilities=zt;zt.install=At;var Bt=null;zt.originalMcap=Bt;pt(At,-1);function Dt(){}function Et(){var a=Jd();window.MediaSource&&(window.cast&&cast.__platform__&&cast.__platform__.canDisplayType?Ft():a?12>=a?(Gt(),Ht()):Gt():(Fd("Tizen 2")||Fd("Tizen 3")||Fd("Tizen 4"))&&It());window.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&Jt()}
809
- function Gt(){var a=MediaSource.prototype.addSourceBuffer;MediaSource.prototype.addSourceBuffer=function(){var b=a.apply(this,Ha.apply(0,arguments));b.abort=function(){};return b}}function Ht(){var a=SourceBuffer.prototype.remove;SourceBuffer.prototype.remove=function(b,c){return a.call(this,b,c-.001)}}function It(){var a=MediaSource.isTypeSupported;MediaSource.isTypeSupported=function(b){return"opus"!=md(b)[0]&&a(b)}}
810
- function Ft(){var a=MediaSource.isTypeSupported;MediaSource.isTypeSupported=function(b){var c=b.split(/ *; */);c.shift();return c.some(function(d){return d.startsWith("codecs=")})?cast.__platform__.canDisplayType(b):a(b)}}
811
- function Jt(){var a=MediaSource.isTypeSupported;Fd("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)})}mt.MediaSource=Dt;Dt.install=Et;pt(Et);function Kt(){}function Lt(){screen.orientation||void 0!=window.orientation&&Mt()}function Mt(){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 Nt;screen.orientation=b;a();window.addEventListener("orientationchange",function(){a();var c=new M("change");b.dispatchEvent(c)})}mt.Orientation=Kt;
812
- Kt.install=Lt;function Nt(){fb.call(this);this.type="";this.angle=0}qa(Nt,fb);
813
- Nt.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)};
814
- Nt.prototype.unlock=function(){screen.unlockOrientation?screen.unlockOrientation():screen.mozUnlockOrientation?screen.mozUnlockOrientation():screen.msUnlockOrientation&&screen.msUnlockOrientation()};pt(Lt);function Ot(){}function Pt(){!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=Qt,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=Rt,window.MediaKeys=St,window.MediaKeySystemAccess=Tt,window.shakaMediaKeysPolyfill=!0)}function Qt(){return Promise.reject(Error("The key system specified is not supported."))}
815
- function Rt(a){return null==a?Promise.resolve():Promise.reject(Error("MediaKeys not supported."))}mt.PatchedMediaKeysNop=Ot;Ot.install=Pt;function St(){throw new TypeError("Illegal constructor.");}St.prototype.createSession=function(){};St.prototype.setServerCertificate=function(){};function Tt(){this.keySystem="";throw new TypeError("Illegal constructor.");}Tt.prototype.getConfiguration=function(){};Tt.prototype.createMediaKeys=function(){};pt(Pt,-10);function Ut(){}
816
- function Vt(){if(!(!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration)){if(HTMLMediaElement.prototype.webkitGenerateKeyRequest)Wt="webkit";else if(!HTMLMediaElement.prototype.generateKeyRequest)return;navigator.requestMediaKeySystemAccess=Xt;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=Yt;window.MediaKeys=Zt;window.MediaKeySystemAccess=$t;window.shakaMediaKeysPolyfill=!0}}
817
- function au(a){var b=Wt;return b?b+a.charAt(0).toUpperCase()+a.slice(1):a}function Xt(a,b){try{var c=new $t(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}}function Yt(a){var b=this.mediaKeys;b&&b!=a&&bu(b,null);delete this.mediaKeys;(this.mediaKeys=a)&&bu(a,this);return Promise.resolve()}mt.PatchedMediaKeysWebkit=Ut;Ut.install=Vt;
818
- function $t(a,b){this.g=this.keySystem=a;var c=!1;"org.w3.clearkey"==a&&(this.g="webkit-org.w3.clearkey",c=!1);var d=!1;var e=document.getElementsByTagName("video");e=e.length?e[0]:document.createElement("video");for(var f=t(b),g=f.next();!g.done;g=f.next()){g=g.value;var h={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:g.initDataTypes,sessionTypes:["temporary"],label:g.label},k=!1;if(g.audioCapabilities)for(var l=t(g.audioCapabilities),
759
+ function ts(a,b,c,d){for(var e=new Set,f=t(b),g=f.next();!g.done;g=f.next()){var h=t(g.value.variantIds);for(g=h.next();!g.done;g=h.next())e.add(g.value)}f=t(c);for(g=f.next();!g.done;g=f.next())for(h=t(g.value.variantIds),g=h.next();!g.done;g=h.next())e.add(g.value);f=new Map;e=t(e);for(g=e.next();!g.done;g=e.next())g=g.value,f.set(g,{id:g,language:"",disabledUntilTime:0,primary:!1,audio:null,video:null,bandwidth:0,allowedByApplication:!0,allowedByKeySystem:!0,decodingInfos:[]});b=t(b);for(e=b.next();!e.done;e=
760
+ b.next())for(e=e.value,g=us(a,e,d),h=t(e.variantIds),e=h.next();!e.done;e=h.next())e=f.get(e.value),e.language=g.language,e.primary=e.primary||g.primary,e.audio=g;c=t(c);for(b=c.next();!b.done;b=c.next())for(e=b.value,b=us(a,e,d),g=t(e.variantIds),e=g.next();!e.done;e=g.next())e=f.get(e.value),e.primary=e.primary||b.primary,e.video=b;return f}
761
+ function us(a,b,c){var d=b.segments.map(function(e){return vs(a,e)});c.ic(d);return{id:b.id,originalId:b.originalId,createSegmentIndex:function(){return Promise.resolve()},segmentIndex:new $i(d),mimeType:b.mimeType,codecs:b.codecs,width:b.width||void 0,height:b.height||void 0,frameRate:b.frameRate,pixelAspectRatio:b.pixelAspectRatio,hdr:b.hdr,kind:b.kind,encrypted:b.encrypted,drmInfos:[],keyIds:b.keyIds,language:b.language,label:b.label,type:b.type,primary:b.primary,trickModeVideo:null,emsgSchemeIdUris:null,
762
+ roles:b.roles,forced:b.forced,channelsCount:b.channelsCount,audioSamplingRate:b.audioSamplingRate,spatialAudio:b.spatialAudio,closedCaptions:b.closedCaptions,tilesLayout:b.tilesLayout}}function vs(a,b){var c=new ps("segment",a.h,a.g,b.dataKey);return new Yh(b.startTime,b.endTime,function(){return[c.toString()]},0,null,null!=b.initSegmentKey?ws(a,b.initSegmentKey):null,b.timestampOffset,b.appendWindowStart,b.appendWindowEnd,[],b.tilesLayout||"")}
763
+ function ws(a,b){var c=new ps("segment",a.h,a.g,b);return new Wh(function(){return[c.toString()]},0,null)};function xs(){this.g=null}q=xs.prototype;q.configure=function(){};
764
+ q.start=function(a,b){var c=this,d,e,f,g,h,k,l;return I(function(m){switch(m.g){case 1:d=qs(a);c.g=d;if(null==d||"manifest"!=d.g)throw new O(2,1,9004,a);e=new Xr;ua(m);return u(m,e.init(),4);case 4:return u(m,as(e,d.Sa(),d.Ba()),5);case 5:return f=m.h,u(m,f.getManifests([d.key()]),6);case 6:return g=m.h,h=g[0],k=new rs(d.Sa(),d.Ba()),l=ss(k,h),b.makeTextStreamsForClosedCaptions(l),m["return"](l);case 2:return wa(m),u(m,e.destroy(),7);case 7:ya(m,0)}})};q.stop=function(){return Promise.resolve()};
765
+ q.update=function(){};q.onExpirationUpdated=function(a,b){var c=this,d,e,f,g,h,k,l;return I(function(m){switch(m.g){case 1:return d=c.g,e=new Xr,A(m,2,3),u(m,e.init(),5);case 5:return u(m,as(e,d.Sa(),d.Ba()),6);case 6:return f=m.h,u(m,f.getManifests([d.key()]),7);case 7:g=m.h;h=g[0];k=h.sessionIds.includes(a);l=void 0==h.expiration||h.expiration>b;if(!k||!l){m.D(3);break}return u(m,f.updateManifestExpiration(d.key(),b),3);case 3:return wa(m),u(m,e.destroy(),10);case 10:ya(m,0);break;case 2:F(m),m.D(3)}})};
766
+ tg["application/x-offline-manifest"]=function(){return new xs};function ys(){}function zs(a){var b=qs(a);b&&"manifest"==b.g?(a={uri:a,Bf:a,data:new ArrayBuffer(0),headers:{"content-type":"application/x-offline-manifest"}},a=af(a)):a=b&&"segment"==b.g?As(b.key(),b):Ze(new O(2,1,9004,a));return a}
767
+ function As(a,b){var c=new Xr;return af(void 0).na(function(){return c.init()}).na(function(){return as(c,b.Sa(),b.Ba())}).na(function(d){return d.getSegments([b.key()])}).na(function(d){return{uri:b,data:d[0].data,headers:{}}})["finally"](function(){return c.destroy()})}J("shaka.offline.OfflineScheme",ys);ys.plugin=zs;kf("offline",zs);function Bs(a,b,c){var d,e,f,g,h,k;return I(function(l){switch(l.g){case 1:d=[];for(var m=[],n=t(c),p=n.next();!p.done;p=n.next()){p=p.value;for(var r=!1,w=t(m),y=w.next();!y.done;y=w.next())if(y=y.value,Cs(y.info,p)){y.sessionIds.push(p.sessionId);r=!0;break}r||m.push({info:p,sessionIds:[p.sessionId]})}e=t(m);f=e.next();case 2:if(f.done){l.D(4);break}g=f.value;h=Ds(a,b,g);return u(l,h,5);case 5:k=l.h;d=d.concat(k);f=e.next();l.D(2);break;case 4:return l["return"](d)}})}
768
+ function Ds(a,b,c){var d,e;return I(function(f){switch(f.g){case 1:return d=new Ef({Ob:b,onError:function(){},wd:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),A(f,2),d.configure(a),u(f,Mf(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 F(f),u(f,d.destroy(),5);case 5:return f["return"]([]);case 3:return A(f,6),u(f,Xf(d),8);case 8:va(f,7);break;case 6:return F(f),u(f,d.destroy(),
769
+ 9);case 9:return f["return"]([]);case 7:return e=[],u(f,Promise.all(c.sessionIds.map(function(g){return I(function(h){if(1==h.g)return A(h,2),u(h,Yf(d,g),4);if(2!=h.g)return e.push(g),va(h,0);F(h);z(h)})})),10);case 10:return u(f,d.destroy(),11);case 11:return f["return"](e)}})}
770
+ function Cs(a,b){function c(d,e){return d.robustness==e.robustness&&d.contentType==e.contentType}return a.keySystem==b.keySystem&&a.licenseUri==b.licenseUri&&ec(a.audioCapabilities,b.audioCapabilities,c)&&ec(a.videoCapabilities,b.videoCapabilities,c)};function Es(a,b,c){var d=b.presentationTimeline.getDuration();b=Fs(b);return{offlineUri:null,originalManifestUri:a,duration:d,size:0,expiration:Infinity,tracks:b,appMetadata:c,isIncomplete:!1}}function Gs(a,b){var c=ss(new rs(a.Sa(),a.Ba()),b),d=b.appMetadata||{};c=Fs(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}}
771
+ function Fs(a){var b=[],c=Ae(a.variants);c=t(c);for(var d=c.next();!d.done;d=c.next())b.push(re(d.value));a=t(a.textStreams);for(c=a.next();!c.done;c=a.next())b.push(se(c.value));return b};function Hs(){this.g={}}function Is(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 Js(a,b){a.g[b.id]=b.bandwidth||2048}function Ks(a,b){var c=a.g[b];null==c&&(c=0);return c};function Ls(a){var b=this;if(a&&a.constructor!=S)throw new O(2,9,9008);this.g=this.h=null;a?(this.h=a.h,this.g=a.Ec()):(this.h=Ok(),this.g=new jf);this.i=[];this.j=[];var c=!a;this.l=new uf(function(){var d,e,f,g,h;return I(function(k){switch(k.g){case 1:return u(k,Promise.all(b.j.map(function(l){return Hr(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 u(k,Promise.all(e),3);case 3:if(!c){k.D(4);break}return u(k,b.g.destroy(),4);
772
+ case 4:b.h=null,b.g=null,z(k)}})})}function Ms(){if(Rc())a:{var a=t(Yr.values());for(var b=a.next();!b.done;b=a.next())if(b=b.value,b=b()){b.destroy();a=!0;break a}a=!1}else a=!1;return a}q=Ls.prototype;q.destroy=function(){return this.l.destroy()};q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=Lk(a,b));return Qk(this.h,a)};q.getConfiguration=function(){var a=Ok();Qk(a,this.h,Ok());return a};q.Ec=function(){return this.g};
773
+ q.store=function(a,b,c){var d=this,e=this.getConfiguration(),f=new Gr(this.g);this.j.push(f);b=Ns(this,a,b||{},function(){var g;return I(function(h){if(1==h.g)return u(h,sg(a,d.g,e.manifest.retryParameters,c||null),2);g=h.h;return h["return"](g())})},e,f);b=new Ye(b,function(){return Hr(f)});b["finally"](function(){dc(d.j,f)});return Os(this,b)};
774
+ function Ns(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,w,y,x,v,D,C;return I(function(B){switch(B.g){case 1:return Ps(),h=g=null,k=new Xr,n=m=l=null,A(B,2,3),u(B,d(),5);case 5:return g=B.h,u(B,Qs(a,b,g,e),6);case 6:p=B.h;Rs(a);r=!p.presentationTimeline.U()&&!p.presentationTimeline.Lb();if(!r)throw new O(2,9,9005,b);return u(B,Ss(a,p,function(G){n=n||G},e),7);case 7:h=B.h;Rs(a);if(n)throw n;return u(B,Ts(p,e),8);case 8:return u(B,k.init(),9);case 9:return Rs(a),u(B,Zr(k),10);case 10:return l=B.h,Rs(a),w=Us(h,
775
+ p,b,c,e,f),y=w.Pg,x=w.Le,u(B,l.Ba.addManifests([y]),11);case 11:v=B.h;Rs(a);m=v[0];Rs(a);if(n)throw n;return u(B,Vs(a,x,m,y,f,e,l.Ba,p,h),12);case 12:return Rs(a),D=new ps("manifest",l.path.Sa,l.path.Ba,m),B["return"](Gs(D,y));case 3:return wa(B),u(B,k.destroy(),13);case 13:if(!g){B.D(14);break}return u(B,g.stop(),14);case 14:if(!h){B.D(16);break}return u(B,h.destroy(),16);case 16:ya(B,0);break;case 2:C=F(B);if(null==m){B.D(18);break}return u(B,Ws(m),18);case 18:throw n||C;}})}
776
+ function Vs(a,b,c,d,e,f,g,h,k){var l,m,n,p,r,w,y,x,v,D;return I(function(C){switch(C.g){case 1:l={};m=0;n=function(B,G){var E,H,N,K,M,V,Z;return I(function(ha){if(1==ha.g){E={};H=t(B);for(N=H.next();!N.done;E={Eb:E.Eb},N=H.next())E.Eb=N.value,K=Dr(E.Eb,f),M=E.Eb.i,V=E.Eb.h,Z=function(ja){return function(xa){var La,Fa,Sa;return I(function(Ga){if(1==Ga.g)return u(Ga,g.addSegments([{data:xa}]),2);La=Ga.h;Rs(a);Fa=ja.Eb.g;Sa=Cr(Fa);l[Sa]=La[0];m+=xa.byteLength;z(Ga)})}}(E),Jr(e,E.Eb.groupId,K,M,V,Z);
777
+ return u(ha,Lr(e),2)}if(!G)return ha.D(0);Rs(a);Xs(h,d,k,f);return u(ha,g.updateManifest(c,d),0)})};p=!1;A(C,2);if(!Ys(h)||!p||Zs(h)){C.D(4);break}return u(C,n(b.filter(function(B){return B.h}),!0),5);case 5:return Rs(a),b=b.filter(function(B){return!B.h}),r=l,w=m,l={},m=0,u(C,$s(g,c,d,r,w,function(){return Rs(a)}),6);case 6:Rs(a);case 4:if(p){C.D(7);break}return u(C,n(b,!1),8);case 8:return Rs(a),y=l,x=m,l={},m=0,u(C,$s(g,c,d,y,x,function(){return Rs(a)}),9);case 9:Rs(a);case 7:va(C,0);break;case 2:return v=
778
+ F(C),D=Object.values(l),u(C,g.removeSegments(D,function(){}),10);case 10:throw v;}})}function Ws(a){var b,c,d,e;return I(function(f){switch(f.g){case 1:return b=new Xr,u(f,b.init(),2);case 2:return u(f,Zr(b),3);case 3:return c=f.h,d=new ps("manifest",c.path.Sa,c.path.Ba,a),u(f,b.destroy(),4);case 4:return e=new Ls,u(f,e.remove(d.toString()),0)}})}
779
+ function $s(a,b,c,d,e,f){var g,h,k,l,m,n,p,r,w,y,x;return I(function(v){switch(v.g){case 1:g=!1;A(v,2);h=!0;k=t(c.streams);for(l=k.next();!l.done;l=k.next())for(m=l.value,n=t(m.segments),p=n.next();!p.done;p=n.next())r=p.value,w=r.pendingSegmentRefId?d[r.pendingSegmentRefId]:null,null!=w&&(r.dataKey=w,r.pendingSegmentRefId=void 0),w=r.pendingInitSegmentRefId?d[r.pendingInitSegmentRefId]:null,null!=w&&(r.initSegmentKey=w,r.pendingInitSegmentRefId=void 0),r.pendingSegmentRefId&&(h=!1),r.pendingInitSegmentRefId&&
780
+ (h=!1);c.size+=e;h&&(c.isIncomplete=!1);return u(v,a.updateManifest(b,c),4);case 4:g=!0;f();va(v,0);break;case 2:return y=F(v),u(v,Ws(b),5);case 5:if(g){v.D(6);break}x=Object.values(d);return u(v,a.removeSegments(x,function(){}),6);case 6:throw y;}})}
781
+ function Ts(a,b){var c,d,e,f,g,h,k,l,m,n,p,r,w,y,x,v,D,C,B,G,E,H,N,K,M,V,Z,ha,ja;return I(function(xa){switch(xa.g){case 1:return c={width:Infinity,height:Infinity},ae(a,b.restrictions,c),u(xa,ee(a,b.offline.usePersistentLicense),2);case 2:d=[];e=b.preferredAudioChannelCount;f=b.preferredDecodingAttributes;g=b.preferredVideoCodecs;h=b.preferredAudioCodecs;Pd(a,g,h,e,f);k=t(a.variants);for(l=k.next();!l.done;l=k.next())m=l.value,d.push(re(m));n=t(a.textStreams);for(p=n.next();!p.done;p=n.next())r=
782
+ p.value,d.push(se(r));w=t(a.imageStreams);for(y=w.next();!y.done;y=w.next())x=y.value,d.push(te(x));return u(xa,b.offline.trackSelectionCallback(d),3);case 3:v=xa.h;D=a.presentationTimeline.getDuration();C=0;B=t(v);for(G=B.next();!G.done;G=B.next())E=G.value,H=E.bandwidth*D/8,C+=H;A(xa,4);return u(xa,b.offline.downloadSizeCallback(C),6);case 6:N=xa.h;if(!N)throw new O(2,9,9014);va(xa,5);break;case 4:K=F(xa);if(K instanceof O)throw K;throw new O(2,9,9015);case 5:M=new Set;V=new Set;Z=new Set;ha=t(v);
783
+ for(G=ha.next();!G.done;G=ha.next())ja=G.value,"variant"==ja.type&&M.add(ja.id),"text"==ja.type&&V.add(ja.id),"image"==ja.type&&Z.add(ja.id);a.variants=a.variants.filter(function(La){return M.has(La.id)});a.textStreams=a.textStreams.filter(function(La){return V.has(La.id)});a.imageStreams=a.imageStreams.filter(function(La){return Z.has(La.id)});at(a);z(xa)}})}
784
+ function Us(a,b,c,d,e,f){var g=Es(c,b,d),h=e.offline.progressCallback;Ir(f,function(r,w){g.size=w;h(g,r)},function(r,w){k&&e.offline.usePersistentLicense&&l==w&&Uf(a,"cenc",r)});var k=Ys(b)&&!Zs(b),l=null;k&&(l=bt.get(a.g.keySystem));for(var m=new Hs,n=t(b.textStreams),p=n.next();!p.done;p=n.next())m.g[p.value.id]=52;n=t(b.imageStreams);for(p=n.next();!p.done;p=n.next())Js(m,p.value);p=t(b.variants);for(n=p.next();!n.done;n=p.next())Is(m,n.value);m=ct(f,m,b,e);f=m.streams;m=m.Le;p=a.g;n=e.offline.usePersistentLicense;
785
+ p&&n&&(p.initData=[]);return{Pg:{creationTime:Date.now(),originalManifestUri:c,duration:b.presentationTimeline.getDuration(),size:0,expiration:a.Dc(),streams:f,sessionIds:n?bg(a):[],drmInfo:p,appMetadata:d,isIncomplete:!0,sequenceMode:b.sequenceMode},Le:m}}function Ys(a){return a.variants.some(function(b){var c=b.audio&&b.audio.encrypted;return b.video&&b.video.encrypted||c})}
786
+ function Zs(a){return a.variants.some(function(b){return(b.video?b.video.drmInfos:[]).concat(b.audio?b.audio.drmInfos:[]).some(function(c){return c.initData&&c.initData.length})})}function Xs(a,b,c,d){b.expiration=c.Dc();c=bg(c);b.sessionIds=d.offline.usePersistentLicense?c:[];if(Ys(a)&&d.offline.usePersistentLicense&&!c.length)throw new O(2,9,9007);}q.remove=function(a){return dt(this,et(this,a))};
787
+ function et(a,b){var c,d,e,f,g,h;return I(function(k){switch(k.g){case 1:Ps();c=qs(b);if(null==c||"manifest"!=c.g)throw new O(2,9,9004,b);d=c;e=new Xr;ua(k);return u(k,e.init(),4);case 4:return u(k,as(e,d.Sa(),d.Ba()),5);case 5:return f=k.h,u(k,f.getManifests([d.key()]),6);case 6:return g=k.h,h=g[0],u(k,Promise.all([ft(a,h,e),gt(f,d,h)]),2);case 2:return wa(k),u(k,e.destroy(),8);case 8:ya(k,0)}})}
788
+ function ht(a,b){for(var c=[],d=t(a.streams),e=d.next();!e.done;e=d.next())e=e.value,b&&"video"==e.type?c.push({contentType:yd(e.mimeType,e.codecs),robustness:a.drmInfo.videoRobustness}):b||"audio"!=e.type||c.push({contentType:yd(e.mimeType,e.codecs),robustness:a.drmInfo.audioRobustness});return c}function ft(a,b,c){return I(function(d){return u(d,it(a.g,a.h.drm,c,b),0)})}
789
+ function gt(a,b,c){function d(){}var e=jt(c);Gs(b,c);return Promise.all([a.removeSegments(e,d),a.removeManifests([b.key()],d)])}q.dh=function(){return dt(this,kt(this))};
790
+ function kt(a){var b,c,d,e,f,g,h,k,l,m;return I(function(n){switch(n.g){case 1:return Ps(),b=a.g,c=a.h.drm,d=new Xr,e=!1,ua(n),u(n,d.init(),4);case 4:f=[],bs(d,function(p){return f.push(p)}),g=t(f),h=g.next();case 5:if(h.done){n.D(2);break}k=h.value;return u(n,k.getAll(),8);case 8:return l=n.h,u(n,Bs(c,b,l),9);case 9:return m=n.h,u(n,k.remove(m),10);case 10:m.length!=l.length&&(e=!0);h=g.next();n.D(5);break;case 2:return wa(n),u(n,d.destroy(),11);case 11:ya(n,3);break;case 3:return n["return"](!e)}})}
791
+ q.list=function(){return dt(this,lt())};function lt(){var a,b,c;return I(function(d){switch(d.g){case 1:return Ps(),a=[],b=new Xr,ua(d),u(d,b.init(),4);case 4:return c=Promise.resolve(),$r(b,function(e,f){c=c.then(function(){var g;return I(function(h){if(1==h.g)return u(h,f.getAllManifests(),2);g=h.h;g.forEach(function(k,l){var m=Gs(new ps("manifest",e.Sa,e.Ba,l),k);a.push(m)});z(h)})})}),u(d,c,2);case 2:return wa(d),u(d,b.destroy(),6);case 6:ya(d,3);break;case 3:return d["return"](a)}})}
792
+ function Qs(a,b,c,d){var e,f,g,h,k;return I(function(l){if(1==l.g)return e=null,f=a.g,g={networkingEngine:f,modifyManifestRequest:function(){},modifySegmentRequest:function(){},filter:function(){return Promise.resolve()},makeTextStreamsForClosedCaptions:function(){},onTimelineRegionAdded:function(){},onEvent:function(){},onError:function(m){e=m},isLowLatencyMode:function(){return!1},isAutoLowLatencyMode:function(){return!1},enableLowLatencyMode:function(){}},c.configure(d.manifest),Rs(a),u(l,c.start(b,
793
+ g),2);if(3!=l.g)return h=l.h,Rs(a),k=mt(h),u(l,Promise.all(gb(k,function(m){return m.createSegmentIndex()})),3);Rs(a);if(e)throw e;return l["return"](h)})}function Ss(a,b,c,d){var e;return I(function(f){switch(f.g){case 1:return e=new Ef({Ob:a.g,onError:c,wd:function(){},onExpirationUpdated:function(){},onEvent:function(){}}),e.configure(d.drm),u(f,Jf(e,b.variants,d.offline.usePersistentLicense),2);case 2:return u(f,Xf(e),3);case 3:return u(f,Wf(e),4);case 4:return f["return"](e)}})}
794
+ function ct(a,b,c,d){var e=new Map,f=mt(c),g=new Map;f=t(f);for(var h=f.next();!h.done;h=f.next()){h=h.value;var k=nt(a,b,c,h,d,e);g.set(h.id,k)}a=t(c.variants);for(b=a.next();!b.done;b=a.next())b=b.value,b.audio&&g.get(b.audio.id).variantIds.push(b.id),b.video&&g.get(b.video.id).variantIds.push(b.id);return{streams:Array.from(g.values()),Le:Array.from(e.values())}}
795
+ function nt(a,b,c,d,e,f){var g={id:d.id,originalId:d.originalId,primary:d.primary,type:d.type,mimeType:d.mimeType,codecs:d.codecs,frameRate:d.frameRate,pixelAspectRatio:d.pixelAspectRatio,hdr:d.hdr,kind:d.kind,language:d.language,label:d.label,width:d.width||null,height:d.height||null,encrypted:d.encrypted,keyIds:d.keyIds,segments:[],variantIds:[],roles:d.roles,forced:d.forced,channelsCount:d.channelsCount,audioSamplingRate:d.audioSamplingRate,spatialAudio:d.spatialAudio,closedCaptions:d.closedCaptions,
796
+ tilesLayout:d.tilesLayout},h=e.offline.numberOfParallelDownloads,k=0;ot(d,c.presentationTimeline.ob(),function(l){var m=Cr(l),n=void 0;if(!f.has(m)){var p=l.endTime-l.startTime;p=Ks(b,d.id)*p;p=Fr(a.g,p);f.set(m,new Br(l,p,k,!1))}l.i&&(n=Cr(l.i),f.has(n)||(p=.5*Ks(b,d.id),p=Fr(a.g,p),f.set(n,new Br(l.i,p,k,!0))));g.segments.push({pendingInitSegmentRefId:n,initSegmentKey:n?0:null,startTime:l.startTime,endTime:l.endTime,appendWindowStart:l.appendWindowStart,appendWindowEnd:l.appendWindowEnd,timestampOffset:l.timestampOffset,
797
+ tilesLayout:l.tilesLayout,pendingSegmentRefId:m,dataKey:0});k=(k+1)%h});return g}function ot(a,b,c){b=a.segmentIndex.find(b);if(null!=b)for(var d=a.segmentIndex.get(b);d;)c(d),d=a.segmentIndex.get(++b)}function Rs(a){if(a.l.g)throw new O(2,9,7001);}function Ps(){if(!Ms())throw new O(2,9,9E3);}function dt(a,b){return I(function(c){if(1==c.g)return a.i.push(b),ua(c),u(c,b,4);if(2!=c.g)return c["return"](c.h);wa(c);dc(a.i,b);return ya(c,0)})}
798
+ function Os(a,b){var c=b.promise;a.i.push(c);return b["finally"](function(){dc(a.i,c)})}function jt(a){var b=new Set;a=t(a.streams);for(var c=a.next();!c.done;c=a.next()){c=t(c.value.segments);for(var d=c.next();!d.done;d=c.next())d=d.value,null!=d.initSegmentKey&&b.add(d.initSegmentKey),b.add(d.dataKey)}return Array.from(b)}
799
+ function it(a,b,c,d){var e,f,g;return I(function(h){if(1==h.g){if(!d.drmInfo)return h["return"]();e=cs(c);f=d.sessionIds.map(function(k){return{sessionId:k,keySystem:d.drmInfo.keySystem,licenseUri:d.drmInfo.licenseServerUri,serverCertificate:d.drmInfo.serverCertificate,audioCapabilities:ht(d,!1),videoCapabilities:ht(d,!0)}});return u(h,Bs(b,a,f),2)}return 3!=h.g?(g=h.h,u(h,e.remove(g),3)):u(h,e.add(f.filter(function(k){return!g.includes(k.sessionId)})),0)})}
800
+ function mt(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}
801
+ function at(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());}J("shaka.offline.Storage",Ls);Ls.deleteAll=function(){var a;return I(function(b){return 1==b.g?(a=new Xr,ua(b),u(b,ds(a),2)):5!=b.g?(wa(b),u(b,a.destroy(),5)):ya(b,0)})};Ls.prototype.list=Ls.prototype.list;
802
+ Ls.prototype.removeEmeSessions=Ls.prototype.dh;Ls.prototype.remove=Ls.prototype.remove;Ls.prototype.store=Ls.prototype.store;Ls.prototype.getNetworkingEngine=Ls.prototype.Ec;Ls.prototype.getConfiguration=Ls.prototype.getConfiguration;Ls.prototype.configure=Ls.prototype.configure;Ls.prototype.destroy=Ls.prototype.destroy;Ls.support=Ms;
803
+ var bt=(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");
804
+ xm.offline=Ms;function pt(){}function qt(){for(var a=t(rt),b=a.next();!b.done;b=a.next()){b=b.value;try{b.Xf()}catch(c){Ua("Error installing polyfill!",c)}}}function st(a,b){for(var c={priority:b||0,Xf:a},d=0;d<rt.length;d++)if(rt[d].priority<c.priority){rt.splice(d,0,c);return}rt.push(c)}J("shaka.polyfill",pt);pt.register=st;pt.installAll=qt;var rt=[];function tt(){}function ut(){if(!Object.getOwnPropertyDescriptor(Element.prototype,"ariaHidden"))for(var a=t(["ariaHidden","ariaLabel","ariaPressed","ariaSelected"]),b=a.next();!b.done;b=a.next())vt(b.value)}function vt(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)}})}pt.Aria=tt;tt.install=ut;st(ut);function wt(){}function xt(){yt()}pt.EncryptionScheme=wt;wt.install=xt;st(xt,-2);function zt(){}
805
+ function At(){if(window.Document){var a=Element.prototype;a.requestFullscreen=a.requestFullscreen||a.mozRequestFullScreen||a.msRequestFullscreen||a.webkitRequestFullscreen;a=Document.prototype;a.exitFullscreen=a.exitFullscreen||a.mozCancelFullScreen||a.msExitFullscreen||a.webkitCancelFullScreen;"fullscreenElement"in document||(Object.defineProperty(document,"fullscreenElement",{get:function(){return document.mozFullScreenElement||document.msFullscreenElement||document.webkitCurrentFullScreenElement||document.webkitFullscreenElement}}),
806
+ Object.defineProperty(document,"fullscreenEnabled",{get:function(){return document.mozFullScreenEnabled||document.msFullscreenEnabled||document.webkitFullscreenEnabled}}));document.addEventListener("webkitfullscreenchange",Bt);document.addEventListener("webkitfullscreenerror",Bt);document.addEventListener("mozfullscreenchange",Bt);document.addEventListener("mozfullscreenerror",Bt);document.addEventListener("MSFullscreenChange",Bt);document.addEventListener("MSFullscreenError",Bt)}}
807
+ function Bt(a){var b=a.type.replace(/^(webkit|moz|MS)/,"").toLowerCase(),c=document.createEvent("Event");c.initEvent(b,a.bubbles,a.cancelable);a.target.dispatchEvent(c)}pt.Fullscreen=zt;zt.install=At;st(At);function Ct(){}function Dt(){var a=!0;if(Zc()||Vc("PlayStation 5")||$c()||Yc())a=!1;Yc()&&Vc("Android")&&(a=!0);a&&navigator.mediaCapabilities||(navigator.mediaCapabilities||(navigator.mediaCapabilities={}),Et=navigator.mediaCapabilities,navigator.mediaCapabilities.decodingInfo=Ft)}
808
+ function Ft(a){var b,c,d,e,f,g,h,k,l,m,n,p,r,w,y,x;return I(function(v){switch(v.g){case 1:b={supported:!1,powerEfficient:!0,smooth:!0,keySystemAccess:null,configuration:a};if(!a)return v["return"](b);if("media-source"==a.type){if(!Rc()||a.video&&(c=a.video.contentType,d=MediaSource.isTypeSupported(c),!d)||a.audio&&(e=a.audio.contentType,f=MediaSource.isTypeSupported(e),!f))return v["return"](b)}else if("file"==a.type){if(a.video&&(g=a.video.contentType,h=Sc(g),!h)||a.audio&&(k=a.audio.contentType,
809
+ l=Sc(k),!l))return v["return"](b)}else return v["return"](b);if(!a.keySystemConfiguration)return b.supported=!0,v["return"](Promise.resolve(b));m=a.keySystemConfiguration;n=[];p=[];m.audio&&(r={robustness:m.audio.robustness||"",contentType:a.audio.contentType},n.push(r));m.video&&(w={robustness:m.video.robustness||"",contentType:a.video.contentType},p.push(w));y={initDataTypes:[m.initDataType],distinctiveIdentifier:m.distinctiveIdentifier,persistentState:m.persistentState,sessionTypes:m.sessionTypes};
810
+ n.length&&(y.audioCapabilities=n);p.length&&(y.videoCapabilities=p);A(v,3);return u(v,navigator.requestMediaKeySystemAccess(m.keySystem,[y]),5);case 5:x=v.h;va(v,4);break;case 3:F(v);case 4:x&&(b.supported=!0,b.keySystemAccess=x);case 2:return v["return"](b)}})}pt.MediaCapabilities=Ct;Ct.install=Dt;var Et=null;Ct.originalMcap=Et;st(Dt,-1);function Gt(){}function Ht(){var a=ad();window.MediaSource&&(window.cast&&cast.__platform__&&cast.__platform__.canDisplayType?It():a?12>=a?(Jt(),Kt()):Jt():(Vc("Tizen 2")||Vc("Tizen 3")||Vc("Tizen 4"))&&Lt());window.MediaSource&&MediaSource.isTypeSupported('video/webm; codecs="vp9"')&&!MediaSource.isTypeSupported('video/webm; codecs="vp09.00.10.08"')&&Mt()}
811
+ function Jt(){var a=MediaSource.prototype.addSourceBuffer;MediaSource.prototype.addSourceBuffer=function(){var b=a.apply(this,Ha.apply(0,arguments));b.abort=function(){};return b}}function Kt(){var a=SourceBuffer.prototype.remove;SourceBuffer.prototype.remove=function(b,c){return a.call(this,b,c-.001)}}function Lt(){var a=MediaSource.isTypeSupported;MediaSource.isTypeSupported=function(b){return"opus"!=Bd(b)[0]&&a(b)}}
812
+ function It(){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)}}
813
+ function Mt(){var a=MediaSource.isTypeSupported;Vc("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)})}pt.MediaSource=Gt;Gt.install=Ht;st(Ht);function Nt(){}function Ot(){screen.orientation||void 0!=window.orientation&&Pt()}function Pt(){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 Qt;screen.orientation=b;a();window.addEventListener("orientationchange",function(){a();var c=new L("change");b.dispatchEvent(c)})}pt.Orientation=Nt;
814
+ Nt.install=Ot;function Qt(){fb.call(this);this.type="";this.angle=0}qa(Qt,fb);
815
+ Qt.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)};
816
+ Qt.prototype.unlock=function(){screen.unlockOrientation?screen.unlockOrientation():screen.mozUnlockOrientation?screen.mozUnlockOrientation():screen.msUnlockOrientation&&screen.msUnlockOrientation()};st(Ot);function Rt(){}function St(){!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration||(navigator.requestMediaKeySystemAccess=Tt,delete HTMLMediaElement.prototype.mediaKeys,HTMLMediaElement.prototype.mediaKeys=null,HTMLMediaElement.prototype.setMediaKeys=Ut,window.MediaKeys=Vt,window.MediaKeySystemAccess=Wt,window.shakaMediaKeysPolyfill=!0)}function Tt(){return Promise.reject(Error("The key system specified is not supported."))}
817
+ function Ut(a){return null==a?Promise.resolve():Promise.reject(Error("MediaKeys not supported."))}pt.PatchedMediaKeysNop=Rt;Rt.install=St;function Vt(){throw new TypeError("Illegal constructor.");}Vt.prototype.createSession=function(){};Vt.prototype.setServerCertificate=function(){};function Wt(){this.keySystem="";throw new TypeError("Illegal constructor.");}Wt.prototype.getConfiguration=function(){};Wt.prototype.createMediaKeys=function(){};st(St,-10);function Xt(){}
818
+ function Yt(){if(!(!window.HTMLVideoElement||navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration)){if(HTMLMediaElement.prototype.webkitGenerateKeyRequest)Zt="webkit";else if(!HTMLMediaElement.prototype.generateKeyRequest)return;navigator.requestMediaKeySystemAccess=$t;delete HTMLMediaElement.prototype.mediaKeys;HTMLMediaElement.prototype.mediaKeys=null;HTMLMediaElement.prototype.setMediaKeys=au;window.MediaKeys=bu;window.MediaKeySystemAccess=cu;window.shakaMediaKeysPolyfill=!0}}
819
+ function du(a){var b=Zt;return b?b+a.charAt(0).toUpperCase()+a.slice(1):a}function $t(a,b){try{var c=new cu(a,b);return Promise.resolve(c)}catch(d){return Promise.reject(d)}}function au(a){var b=this.mediaKeys;b&&b!=a&&eu(b,null);delete this.mediaKeys;(this.mediaKeys=a)&&eu(a,this);return Promise.resolve()}pt.PatchedMediaKeysWebkit=Xt;Xt.install=Yt;
820
+ function cu(a,b){this.g=this.keySystem=a;var c=!1;"org.w3.clearkey"==a&&(this.g="webkit-org.w3.clearkey",c=!1);var d=!1;var e=document.getElementsByTagName("video");e=e.length?e[0]:document.createElement("video");for(var f=t(b),g=f.next();!g.done;g=f.next()){g=g.value;var h={audioCapabilities:[],videoCapabilities:[],persistentState:"optional",distinctiveIdentifier:"optional",initDataTypes:g.initDataTypes,sessionTypes:["temporary"],label:g.label},k=!1;if(g.audioCapabilities)for(var l=t(g.audioCapabilities),
819
821
  m=l.next();!m.done;m=l.next())m=m.value,m.contentType&&(k=!0,e.canPlayType(m.contentType.split(";")[0],this.g)&&(h.audioCapabilities.push(m),d=!0));if(g.videoCapabilities)for(l=t(g.videoCapabilities),m=l.next();!m.done;m=l.next())m=m.value,m.contentType&&(k=!0,e.canPlayType(m.contentType,this.g)&&(h.videoCapabilities.push(m),d=!0));k||(d=e.canPlayType("video/mp4",this.g)||e.canPlayType("video/webm",this.g));"required"==g.persistentState&&(c?(h.persistentState="required",h.sessionTypes=["persistent-license"]):
820
- d=!1);if(d){this.h=h;return}}c="Unsupported keySystem";if("org.w3.clearkey"==a||"com.widevine.alpha"==a)c="None of the requested configurations were supported.";c=Error(c);c.name="NotSupportedError";c.code=DOMException.NOT_SUPPORTED_ERR;throw c;}$t.prototype.createMediaKeys=function(){var a=new Zt(this.g);return Promise.resolve(a)};$t.prototype.getConfiguration=function(){return this.h};function Zt(a){this.l=a;this.h=null;this.g=new tf;this.i=[];this.j=new Map}
821
- function bu(a,b){a.h=b;a.g.Qc();var c=Wt;b&&(a.g.o(b,c+"needkey",function(d){var e=new CustomEvent("encrypted");e.initDataType="cenc";e.initData=Hc(d.initData);a.h.dispatchEvent(e)}),a.g.o(b,c+"keymessage",function(d){var e=cu(a,d.sessionId);e&&(d=(new Map).set("messageType",void 0==e.keyStatuses.nd()?"licenserequest":"licenserenewal").set("message",d.message),d=new M("message",d),e.h&&(e.h.resolve(),e.h=null),e.dispatchEvent(d))}),a.g.o(b,c+"keyadded",function(d){if(d=cu(a,d.sessionId))du(d,"usable"),
822
- d.g&&d.g.resolve(),d.g=null}),a.g.o(b,c+"keyerror",function(d){var e=cu(a,d.sessionId);e&&e.handleError(d)}))}Zt.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 eu(b,this.l,a);this.i.push(a);return a};Zt.prototype.setServerCertificate=function(){return Promise.resolve(!1)};
823
- function cu(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 eu(a,b,c){fb.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 Nc;this.keyStatuses=new fu}qa(eu,fb);q=eu.prototype;
824
- q.handleError=function(a){var b=Error("EME v0.1b key error"),c=a.errorCode;c.systemCode=a.systemCode;b.errorCode=c;!a.sessionId&&this.h?(45==a.systemCode&&(b.message="Unsupported session type."),this.h.reject(b),this.h=null):a.sessionId&&this.g?(this.g.reject(b),this.g=null):(b=a.systemCode,a.errorCode.code==MediaKeyError.MEDIA_KEYERR_OUTPUT?du(this,"output-restricted"):1==b?du(this,"expired"):du(this,"internal-error"))};
825
- function gu(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=Gc(Vc("LOAD_SESSION|"+c));else{var e=Vc("PERSISTENT|");d=cd(e,b)}else d=Gc(b)}catch(g){return Promise.reject(g)}a.h=new Nc;var f=au("generateKeyRequest");try{a.j[f](a.i,d)}catch(g){if("InvalidStateError"!=g.name)return a.h=null,Promise.reject(g);(new P(function(){try{a.j[f](a.i,d)}catch(h){a.h.reject(h),a.h=null}})).T(.01)}return a.h}
826
- function hu(a,b,c){if(a.g)a.g.then(function(){return hu(a,b,c)})["catch"](function(){return hu(a,b,c)});else{a.g=b;if("webkit-org.w3.clearkey"==a.i){var d=Rc(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=$c(e.keys[0].k);e=$c(e.keys[0].kid)}else d=Gc(c),e=null;var f=au("addKey");try{a.j[f](a.i,d,e,a.sessionId)}catch(g){a.g.reject(g),a.g=null}}}
827
- function du(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;c=new M("keystatuseschange");a.dispatchEvent(c)}q.generateRequest=function(a,b){return gu(this,b,null)};q.load=function(a){return"persistent-license"==this.l?gu(this,null,a):Promise.reject(Error("Not a persistent session."))};q.update=function(a){var b=new Nc;hu(this,b,a);return b};
828
- q.close=function(){if("persistent-license"!=this.l){if(!this.sessionId)return this.closed.reject(Error("The session is not callable.")),this.closed;var a=au("cancelKeyRequest");try{this.j[a](this.i,this.sessionId)}catch(b){}}this.closed.resolve();return this.closed};q.remove=function(){return"persistent-license"!=this.l?Promise.reject(Error("Not a persistent session.")):this.close()};function fu(){this.size=0;this.g=void 0}q=fu.prototype;q.nd=function(){return this.g};
829
- q.forEach=function(a){this.g&&a(this.g,ng.value())};q.get=function(a){if(this.has(a))return this.g};q.has=function(a){var b=ng.value();return this.g&&Ec(a,b)?!0:!1};q.entries=function(){};q.keys=function(){};q.values=function(){};var Wt="";pt(Vt);function iu(){}function ju(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;a.requestPictureInPicture&&document.exitPictureInPicture||!a.webkitSupportsPresentationMode||(document.pictureInPictureEnabled=!0,document.pictureInPictureElement=null,a.requestPictureInPicture=ku,Object.defineProperty(a,"disablePictureInPicture",{get:lu,set:mu,enumerable:!0,configurable:!0}),document.exitPictureInPicture=nu,document.addEventListener("webkitpresentationmodechanged",ou,!0))}}
830
- function ou(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)}
831
- function ku(){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 nu(){var a=document.pictureInPictureElement;return a?(a.webkitSetPresentationMode("inline"),document.pictureInPictureElement=null,Promise.resolve()):Promise.reject(Error("No picture in picture element found"))}
832
- function lu(){return this.hasAttribute("disablePictureInPicture")?!0:!this.webkitSupportsPresentationMode("picture-in-picture")}function mu(a){a?this.setAttribute("disablePictureInPicture",""):this.removeAttribute("disablePictureInPicture")}mt.PiPWebkit=iu;iu.install=ju;pt(ju);function pu(){}function qu(){window.crypto&&("randomUUID"in window.crypto||(window.crypto.randomUUID=ru))}function ru(){var a=URL.createObjectURL(new Blob),b=a.toString();URL.revokeObjectURL(a);return b.substr(b.lastIndexOf("/")+1)}mt.RandomUUID=pu;pu.install=qu;pt(qu);function su(){}function tu(){navigator.storage&&navigator.storage.estimate||!navigator.webkitTemporaryStorage||!navigator.webkitTemporaryStorage.queryUsageAndQuota||("storage"in navigator||(navigator.storage={}),navigator.storage.estimate=uu)}function uu(){return new Promise(function(a,b){navigator.webkitTemporaryStorage.queryUsageAndQuota(function(c,d){a({usage:c,quota:d})},b)})}mt.StorageEstimate=su;su.install=tu;pt(tu);function vu(){}function wu(){var a=Symbol.prototype;"description"in a||Object.defineProperty(a,"description",{get:xu})}function xu(){var a=/\((.*)\)/.exec(this.toString());return a?a[1]:void 0}mt.Symbol=vu;vu.install=wu;pt(wu);function yu(){}function zu(){if(window.HTMLMediaElement){var a=HTMLMediaElement.prototype.play;HTMLMediaElement.prototype.play=function(){var b=a.apply(this);b&&b["catch"](function(){});return b}}}mt.VideoPlayPromise=yu;yu.install=zu;pt(zu);function Au(){}function Bu(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;!a.getVideoPlaybackQuality&&"webkitDroppedFrameCount"in a&&(a.getVideoPlaybackQuality=Cu)}}function Cu(){return{droppedVideoFrames:this.webkitDroppedFrameCount,totalVideoFrames:this.webkitDecodedFrameCount,corruptedVideoFrames:0,creationTime:NaN,totalFrameDelay:0}}mt.VideoPlaybackQuality=Au;Au.install=Bu;pt(Bu);function Du(){}function Eu(){if(!window.VTTCue&&window.TextTrackCue){var a=null,b=TextTrackCue.length;if(3==b)a=Fu;else if(6==b)a=Gu;else{try{var c=!!Fu(1,2,"")}catch(d){c=!1}c&&(a=Fu)}a&&(window.VTTCue=function(d,e,f){return a(d,e,f)})}}function Fu(a,b,c){return new window.TextTrackCue(a,b,c)}function Gu(a,b,c){return new window.TextTrackCue(a+"-"+b+"-"+c,a,b,c)}mt.VTTCue=Du;Du.install=Eu;pt(Eu);function Hu(){}Hu.prototype.parseInit=function(){};Hu.prototype.setSequenceMode=function(){};Hu.prototype.parseMedia=function(a,b){var c=null,d=[],e=Rc(a).split(/\r?\n/);e=t(e);for(var f=e.next();!f.done;f=e.next())if((f=f.value)&&!/^\s+$/.test(f)&&(f=Iu.exec(f))){var g=Ju.exec(f[1]);g=60*parseInt(g[1],10)+parseFloat(g[2].replace(",","."));f=new gc(g,b.segmentEnd?b.segmentEnd:g+2,f[2]);c&&(c.endTime=g,d.push(c));c=f}c&&d.push(c);return d};J("shaka.text.LrcTextParser",Hu);Hu.prototype.parseMedia=Hu.prototype.parseMedia;
833
- Hu.prototype.setSequenceMode=Hu.prototype.setSequenceMode;Hu.prototype.parseInit=Hu.prototype.parseInit;var Iu=/^\[(\d{1,2}:\d{1,2}(?:[.,]\d{1,3})?)\](.*)/,Ju=/^(\d+):(\d{1,2}(?:[.,]\d{1,3})?)$/;qd["application/x-subtitle-lrc"]=function(){return new Hu};function Ku(){}Ku.prototype.parseInit=function(){};Ku.prototype.setSequenceMode=function(){};
834
- Ku.prototype.parseMedia=function(a,b){var c=Rc(a),d=[],e=new DOMParser,f=null;if(""==c)return d;try{f=e.parseFromString(c,"text/xml")}catch(C){throw new O(2,2,2005,"Failed to parse TTML.");}if(f){if(c=f.getElementsByTagName("parsererror")[0])throw new O(2,2,2005,c.textContent);var g=f.getElementsByTagName("tt")[0];if(!g)throw new O(2,2,2005,"TTML does not contain <tt> tag.");f=g.getElementsByTagName("body")[0];if(!f)return[];var h=Vn(g,Lu,"frameRate"),k=Vn(g,Lu,"subFrameRate"),l=Vn(g,Lu,"frameRateMultiplier"),
835
- m=Vn(g,Lu,"tickRate"),n=Vn(g,Lu,"cellResolution");c=g.getAttribute("xml:space")||"default";e=Vn(g,Mu,"extent");if("default"!=c&&"preserve"!=c)throw new O(2,2,2005,"Invalid xml:space value: "+c);c="default"==c;h=new Nu(h,k,l,m);n=n?(n=/^(\d+) (\d+)$/.exec(n))?{columns:parseInt(n[1],10),rows:parseInt(n[2],10)}:null:null;k=(k=g.getElementsByTagName("metadata")[0])?Tn(k):[];l=Array.from(g.getElementsByTagName("style"));g=Array.from(g.getElementsByTagName("region"));m=[];for(var p=t(g),r=p.next();!r.done;r=
836
- p.next()){var x=r.value;r=new ic;var y=x.getAttribute("xml:id");if(y){r.id=y;var w=null;e&&(w=Ou.exec(e)||Pu.exec(e));y=w?Number(w[1]):null;w=w?Number(w[2]):null;var v,D;if(v=Qu(x,l,"extent"))v=(D=Ou.exec(v))||Pu.exec(v),null!=v&&(r.width=Number(v[1]),r.height=Number(v[2]),D||(null!=y&&(r.width=100*r.width/y),null!=w&&(r.height=100*r.height/w)),r.widthUnits=D||null!=y?Bc:0,r.heightUnits=D||null!=w?Bc:0);if(x=Qu(x,l,"origin"))v=(D=Ou.exec(x))||Pu.exec(x),null!=v&&(r.viewportAnchorX=Number(v[1]),r.viewportAnchorY=
837
- Number(v[2]),D||(null!=w&&(r.viewportAnchorY=100*r.viewportAnchorY/w),null!=y&&(r.viewportAnchorX=100*r.viewportAnchorX/y)),r.viewportAnchorUnits=D||null!=y?Bc:0)}else r=null;r&&m.push(r)}if(Qn(f,"p").length)throw new O(2,2,2001,"<p> can only be inside <div> in TTML");e=t(Qn(f,"div"));for(p=e.next();!p.done;p=e.next())if(Qn(p.value,"span").length)throw new O(2,2,2001,"<span> can only be inside <p> in TTML");(f=Ru(f,b.periodStart,h,k,l,g,m,c,n,null,!1))&&d.push(f)}return d};
838
- function Ru(a,b,c,d,e,f,g,h,k,l,m){var n=a.parentNode;if(a.nodeType==Node.COMMENT_NODE)return null;if(a.nodeType==Node.TEXT_NODE){if(!m)return null;var p=document.createElement("span");p.textContent=a.textContent}else p=a;for(var r=null,x=t(Su),y=x.next();!y.done&&!(r=Tu(p,"backgroundImage",d,"#",y.value)[0]);y=x.next());x=m;if("p"==a.nodeName||r)m=!0;h="default"==(p.getAttribute("xml:space")||(h?"default":"preserve"));y=Array.from(p.childNodes).every(function(B){return B.nodeType==Node.TEXT_NODE});
839
- a=[];if(!y)for(var w=t(p.childNodes),v=w.next();!v.done;v=w.next())(v=Ru(v.value,b,c,d,e,f,g,h,k,p,m))&&a.push(v);d=null!=l;w=/\S/.test(p.textContent);var D=p.hasAttribute("begin")||p.hasAttribute("end")||p.hasAttribute("dur");if(!(D||w||"br"==p.tagName||0!=a.length||d&&!h))return null;v=Uu(p,c);w=v.start;for(v=v.end;n&&n.nodeType==Node.ELEMENT_NODE&&"tt"!=n.tagName;)v=Vu(n,c,w,v),w=v.start,v=v.end,n=n.parentNode;null==w&&(w=0);w+=b;v=null==v?Infinity:v+b;if(!D&&0<a.length)for(w=Infinity,v=0,b=t(a),
840
- c=b.next();!c.done;c=b.next())c=c.value,w=Math.min(w,c.startTime),v=Math.max(v,c.endTime);if("br"==p.tagName)return e=new gc(w,v,""),e.lineBreak=!0,e;b="";y&&(b=p.textContent,h&&(b=b.trim(),b=b.replace(/\s+/g," ")));b=new gc(w,v,b);b.nestedCues=a;m||(b.isContainer=!0);k&&(b.cellResolution=k);k=Tu(p,"region",f,"")[0];if(p.hasAttribute("region")&&k&&k.getAttribute("xml:id")){var C=k.getAttribute("xml:id");b.region=g.filter(function(B){return B.id==C})[0]}g=k;l&&d&&!p.getAttribute("region")&&!p.getAttribute("style")&&
841
- (g=Tu(l,"region",f,"")[0]);Wu(b,p,g,r,e,x,0==a.length);return b}
842
- function Wu(a,b,c,d,e,f,g){f=f||g;"rtl"==Xu(b,c,e,"direction",f)&&(a.direction="rtl");g=Xu(b,c,e,"writingMode",f);"tb"==g||"tblr"==g?a.writingMode="vertical-lr":"tbrl"==g?a.writingMode="vertical-rl":"rltb"==g||"rl"==g?a.direction="rtl":g&&(a.direction=hc);(g=Xu(b,c,e,"textAlign",!0))?(a.positionAlign=Yu[g],a.lineAlign=Zu[g],a.textAlign=vc[g.toUpperCase()]):a.textAlign=kc;if(g=Xu(b,c,e,"displayAlign",!0))a.displayAlign=wc[g.toUpperCase()];if(g=Xu(b,c,e,"color",f))a.color=g;if(g=Xu(b,c,e,"backgroundColor",
843
- f))a.backgroundColor=g;if(g=Xu(b,c,e,"border",f))a.border=g;if(g=Xu(b,c,e,"fontFamily",f))a.fontFamily=g;(g=Xu(b,c,e,"fontWeight",f))&&"bold"==g&&(a.fontWeight=700);g=Xu(b,c,e,"wrapOption",f);a.wrapLine=g&&"noWrap"==g?!1:!0;(g=Xu(b,c,e,"lineHeight",f))&&g.match($u)&&(a.lineHeight=g);(g=Xu(b,c,e,"fontSize",f))&&(g.match($u)||g.match(av))&&(a.fontSize=g);if(g=Xu(b,c,e,"fontStyle",f))a.fontStyle=Ac[g.toUpperCase()];if(d){g=d.getAttribute("imageType")||d.getAttribute("imagetype");var h=d.getAttribute("encoding");
844
- d=d.textContent.trim();"PNG"==g&&"Base64"==h&&d&&(a.backgroundImage="data:image/png;base64,"+d)}if(d=Xu(b,c,e,"textOutline",f))d=d.split(" "),d[0].match($u)?a.textStrokeColor=a.color:(a.textStrokeColor=d[0],d.shift()),d[0]&&d[0].match($u)?a.textStrokeWidth=d[0]:a.textStrokeColor="";(d=Xu(b,c,e,"letterSpacing",f))&&d.match($u)&&(a.letterSpacing=d);(d=Xu(b,c,e,"linePadding",f))&&d.match($u)&&(a.linePadding=d);if(f=Xu(b,c,e,"opacity",f))a.opacity=parseFloat(f);(c=Qu(c,e,"textDecoration"))&&bv(a,c);(b=
845
- cv(b,e,"textDecoration"))&&bv(a,b)}
846
- function bv(a,b){for(var c=t(b.split(" ")),d=c.next();!d.done;d=c.next())switch(d.value){case "underline":a.textDecoration.includes("underline")||a.textDecoration.push("underline");break;case "noUnderline":a.textDecoration.includes("underline")&&dc(a.textDecoration,"underline");break;case "lineThrough":a.textDecoration.includes("lineThrough")||a.textDecoration.push("lineThrough");break;case "noLineThrough":a.textDecoration.includes("lineThrough")&&dc(a.textDecoration,"lineThrough");break;case "overline":a.textDecoration.includes("overline")||
847
- a.textDecoration.push("overline");break;case "noOverline":a.textDecoration.includes("overline")&&dc(a.textDecoration,"overline")}}function Xu(a,b,c,d,e){e=void 0===e?!0:e;return(a=cv(a,c,d))?a:e?Qu(b,c,d):null}function Qu(a,b,c){if(!a)return null;var d=Vn(a,Mu,c);return d?d:dv(a,b,c)}function cv(a,b,c){var d=Vn(a,Mu,c);return d?d:dv(a,b,c)}
848
- function dv(a,b,c){a=Tu(a,"style",b,"");for(var d=null,e=0;e<a.length;e++){var f=Un(a[e],"urn:ebu:tt:style",c);f||(f=Vn(a[e],Mu,c));f||(f=cv(a[e],b,c));f&&(d=f)}return d}
849
- function Tu(a,b,c,d,e){var f=[];if(!a||1>c.length)return f;var g=a;for(a=null;g&&!(a=e?Un(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 Vu(a,b,c,d){a=Uu(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}}
850
- function Uu(a,b){var c=ev(a.getAttribute("begin"),b),d=ev(a.getAttribute("end"),b),e=ev(a.getAttribute("dur"),b);null==d&&null!=e&&(d=c+e);return{start:c,end:d}}
851
- function ev(a,b){var c=null;if(fv.test(a)){c=fv.exec(a);var d=Number(c[1]),e=Number(c[2]),f=Number(c[3]),g=Number(c[4]);g+=(Number(c[5])||0)/b.h;f+=g/b.frameRate;c=f+60*e+3600*d}else if(gv.test(a))c=hv(gv,a);else if(iv.test(a))c=hv(iv,a);else if(jv.test(a))c=jv.exec(a),c=Number(c[1])/b.frameRate;else if(kv.test(a))c=kv.exec(a),c=Number(c[1])/b.g;else if(lv.test(a))c=hv(lv,a);else if(a)throw new O(2,2,2001,"Could not parse cue time range in TTML");return c}
852
- function hv(a,b){var c=a.exec(b);return null==c||""==c[0]?null:(Number(c[4])||0)/1E3+(Number(c[3])||0)+60*(Number(c[2])||0)+3600*(Number(c[1])||0)}J("shaka.text.TtmlTextParser",Ku);Ku.prototype.parseMedia=Ku.prototype.parseMedia;Ku.prototype.setSequenceMode=Ku.prototype.setSequenceMode;Ku.prototype.parseInit=Ku.prototype.parseInit;
853
- function Nu(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]))}
854
- var Ou=/^(\d{1,2}(?:\.\d+)?|100(?:\.0+)?)% (\d{1,2}(?:\.\d+)?|100(?:\.0+)?)%$/,av=/^(\d{1,2}(?:\.\d+)?|100)%$/,$u=/^(\d+px|\d+em|\d*\.?\d+c)$/,Pu=/^(\d+)px (\d+)px$/,fv=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,gv=/^(?:(\d{2,}):)?(\d{2}):(\d{2})$/,iv=/^(?:(\d{2,}):)?(\d{2}):(\d{2}\.\d{2,})$/,jv=/^(\d*(?:\.\d*)?)f$/,kv=/^(\d*(?:\.\d*)?)t$/,lv=RegExp("^(?:(\\d*(?:\\.\\d*)?)h)?(?:(\\d*(?:\\.\\d*)?)m)?(?:(\\d*(?:\\.\\d*)?)s)?(?:(\\d*(?:\\.\\d*)?)ms)?$"),Zu={left:nc,center:"center",right:"end",start:nc,
855
- end:"end"},Yu={left:"line-left",center:"center",right:"line-right"},Lu=["http://www.w3.org/ns/ttml#parameter","http://www.w3.org/2006/10/ttaf1#parameter"],Mu=["http://www.w3.org/ns/ttml#styling","http://www.w3.org/2006/10/ttaf1#styling"],Su=["http://www.smpte-ra.org/schemas/2052-1/2010/smpte-tt","http://www.smpte-ra.org/schemas/2052-1/2013/smpte-tt"];qd["application/ttml+xml"]=function(){return new Ku};function mv(){this.g=new Ku}mv.prototype.parseInit=function(a){var b=!1;(new xg).box("moov",Bg).box("trak",Bg).box("mdia",Bg).box("minf",Bg).box("stbl",Bg).Y("stsd",Dg).box("stpp",function(c){b=!0;c.parser.stop()}).parse(a);if(!b)throw new O(2,2,2007);};mv.prototype.setSequenceMode=function(){};mv.prototype.parseMedia=function(a,b){var c=this,d=!1,e=[];(new xg).box("mdat",Eg(function(f){d=!0;e=e.concat(c.g.parseMedia(f,b))})).parse(a,!1);if(!d)throw new O(2,2,2007);return e};
856
- J("shaka.text.Mp4TtmlParser",mv);mv.prototype.parseMedia=mv.prototype.parseMedia;mv.prototype.setSequenceMode=mv.prototype.setSequenceMode;mv.prototype.parseInit=mv.prototype.parseInit;qd['application/mp4; codecs="stpp"']=function(){return new mv};qd['application/mp4; codecs="stpp.ttml"']=function(){return new mv};qd['application/mp4; codecs="stpp.ttml.im1t"']=function(){return new mv};qd['application/mp4; codecs="stpp.TTML.im1t"']=function(){return new mv};function nv(){this.g=!1}nv.prototype.parseInit=function(){};nv.prototype.setSequenceMode=function(a){this.g=a};
857
- nv.prototype.parseMedia=function(a,b){var c=Rc(a);c=c.replace(/\r\n|\r(?=[^\n]|$)/gm,"\n");var d=c.split(/\n{2,}/m);if(!/^WEBVTT($|[ \t\n])/m.test(d[0]))throw new O(2,2,2E3);c=b.vttOffset;if(d[0].includes("X-TIMESTAMP-MAP")&&this.g){var e=d[0].match(/LOCAL:((?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{3}))/m),f=d[0].match(/MPEGTS:(\d+)/m);if(e&&f){c=ov(new jq(e[1]));if(null==c)throw new O(2,2,2E3);f=Number(f[1]);for(e=b.segmentStart;95443.7176888889<=e;)e-=95443.7176888889,f+=8589934592;c=b.periodStart+f/9E4-
858
- c}}f=[];e=t(d[0].split("\n"));for(var g=e.next();!g.done;g=e.next())if(g=g.value,/^Region:/.test(g)){g=new jq(g);var h=new ic;mq(g);kq(g);for(var k=mq(g);k;){var l=h,m=k;(k=/^id=(.*)$/.exec(m))?l.id=k[1]:(k=/^width=(\d{1,2}|100)%$/.exec(m))?l.width=Number(k[1]):(k=/^lines=(\d+)$/.exec(m))?(l.height=Number(k[1]),l.heightUnits=2):(k=/^regionanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(m))?(l.regionAnchorX=Number(k[1]),l.regionAnchorY=Number(k[2])):(k=/^viewportanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(m))?
859
- (l.viewportAnchorX=Number(k[1]),l.viewportAnchorY=Number(k[2])):/^scroll=up$/.exec(m)&&(l.scroll="up");kq(g);k=mq(g)}f.push(h)}e=new Map;pv(e);g=[];d=t(d.slice(1));for(h=d.next();!h.done;h=d.next()){h=h.value.split("\n");if((1!=h.length||h[0])&&!/^NOTE($|[ \t])/.test(h[0])&&"STYLE"==h[0]&&h[1].includes("::cue")){l="global";(k=h[1].match(/\((.*)\)/))&&(l=k.pop());k=h.slice(2,-1);h[1].includes("}")&&(m=/\{(.*?)\}/.exec(h[1]))&&(k=m[1].split(";"));m=new gc(0,0,"");for(var n=!1,p=0;p<k.length;p++){var r=
860
- /^\s*([^:]+):\s*(.*)/.exec(k[p]);if(r){var x=r[2].trim().replace(";","");switch(r[1].trim()){case "background-color":n=!0;m.backgroundColor=x;break;case "color":n=!0;m.color=x;break;case "font-family":n=!0;m.fontFamily=x;break;case "font-size":n=!0;m.fontSize=x;break;case "font-weight":700<=parseInt(x,10)&&(n=!0,m.fontWeight=700);break;case "font-style":switch(x){case "normal":n=!0;m.fontStyle=tc;break;case "italic":n=!0;m.fontStyle="italic";break;case "oblique":n=!0,m.fontStyle="oblique"}break;case "opacity":n=
861
- !0;m.opacity=parseFloat(x);break;case "text-shadow":n=!0;m.textShadow=x;break;case "white-space":n=!0,m.wrapLine="noWrap"!=x}}}n&&e.set(l,m)}p=c;if(1==h.length&&!h[0]||/^NOTE($|[ \t])/.test(h[0])||"STYLE"==h[0])h=null;else{l=null;h[0].includes("--\x3e")||(l=h[0],h.splice(0,1));k=new jq(h[0]);m=ov(k);r=lq(k,/[ \t]+--\x3e[ \t]+/g);n=ov(k);if(null==m||null==r||null==n)throw new O(2,2,2001,"Could not parse cue time range in WebVTT");m+=p;n+=p;p=h.slice(1).join("\n").trim();e.has("global")?(h=e.get("global").clone(),
862
- h.startTime=m,h.endTime=n,h.payload=""):h=new gc(m,n,"");qv(p,h,e);kq(k);for(m=mq(k);m;)rv(h,m,f),kq(k),m=mq(k);null!=l&&(h.id=l)}h&&g.push(h)}return g};function pv(a){for(var b=t(Object.entries(yc)),c=b.next();!c.done;c=b.next()){var d=t(c.value);c=d.next().value;d=d.next().value;var e=new gc(0,0,"");e.color=d;a.set(c,e)}b=t(Object.entries(zc));for(c=b.next();!c.done;c=b.next())d=t(c.value),c=d.next().value,d=d.next().value,e=new gc(0,0,""),e.backgroundColor=d,a.set(c,e)}
863
- function qv(a,b,c){0===c.size&&pv(c);a=sv(a);var d=ho("<span>"+a+"</span>","span");if(d){var e=[];d=d.childNodes;if(1==d.length){var f=d[0];if(f.nodeType==Node.TEXT_NODE||f.nodeType==Node.CDATA_SECTION_NODE){b.payload=a;return}}a=t(d);for(d=a.next();!d.done;d=a.next())tv(d.value,b,e,c);b.nestedCues=e}else b.payload=a}
864
- function sv(a){for(var b=[],c=-1,d="",e=0;e<a.length;e++)if("/"===a[e]){var f=a.indexOf(">",e);if(f<=e)return a;f=a.substring(e+1,f);var g=b.pop();if(f&&g){if(g===f)d+="/"+f+">";else{if(!g.startsWith("c.")||"c"!==f)return a;d+="/"+g+">"}e+=f.length+1}else return a}else"<"===a[e]?c=e+1:">"===a[e]&&0<c&&(b.push(a.substr(c,e-c)),c=-1),d+=a[e];return d}function uv(a,b){return a&&0<a.length?a:b}
865
- function tv(a,b,c,d){var e=b.clone();if(a.nodeType===Node.ELEMENT_NODE&&a.nodeName)for(var f=t(a.nodeName.split(/[ .]+/)),g=f.next();!g.done;g=f.next()){g=g.value;if(d.has(g)){var h=d.get(g);h&&(e.backgroundColor=uv(h.backgroundColor,e.backgroundColor),e.color=uv(h.color,e.color),e.fontFamily=uv(h.fontFamily,e.fontFamily),e.fontSize=uv(h.fontSize,e.fontSize),e.fontWeight=h.fontWeight,e.fontStyle=h.fontStyle,e.opacity=h.opacity,e.wrapLine=h.wrapLine)}switch(g){case "b":e.fontWeight=700;break;case "i":e.fontStyle=
866
- "italic";break;case "u":e.textDecoration.push("underline")}}if(Xn(a))for(f=!0,d=t(a.textContent.split("\n")),a=d.next();!a.done;a=d.next())a=a.value,f||(f=b.clone(),f.lineBreak=!0,c.push(f)),0<a.length&&(f=e.clone(),f.payload=a,c.push(f)),f=!1;else for(b=t(a.childNodes),a=b.next();!a.done;a=b.next())tv(a.value,e,c,d)}
867
- function rv(a,b,c){var d;if(d=/^align:(start|middle|center|end|left|right)$/.exec(b))b=d[1],"middle"==b?a.textAlign=kc:a.textAlign=vc[b.toUpperCase()];else if(d=/^vertical:(lr|rl)$/.exec(b))a.writingMode="lr"==d[1]?"vertical-lr":"vertical-rl";else if(d=/^size:([\d.]+)%$/.exec(b))a.size=Number(d[1]);else if(d=/^position:([\d.]+)%(?:,(line-left|line-right|center|start|end))?$/.exec(b))a.position=Number(d[1]),d[2]&&(b=d[2],a.positionAlign="line-left"==b||"start"==b?"line-left":"line-right"==b||"end"==
868
- b?"line-right":"center");else if(d=/^region:(.*)$/.exec(b)){if(b=vv(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=xc[c[2].toUpperCase()]);else if(c=/^line:(-?\d+)(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=mc,a.line=Number(c[1]),c[2]&&(a.lineAlign=xc[c[2].toUpperCase()])}function vv(a,b){var c=a.filter(function(d){return d.id==b});return c.length?c[0]:null}
869
- function ov(a){a=lq(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)}J("shaka.text.VttTextParser",nv);nv.prototype.parseMedia=nv.prototype.parseMedia;nv.prototype.setSequenceMode=nv.prototype.setSequenceMode;nv.prototype.parseInit=nv.prototype.parseInit;qd["text/vtt"]=function(){return new nv};qd['text/vtt; codecs="vtt"']=function(){return new nv};
870
- qd['text/vtt; codecs="wvtt"']=function(){return new nv};function wv(){this.g=null}wv.prototype.parseInit=function(a){var b=this,c=!1;(new xg).box("moov",Bg).box("trak",Bg).box("mdia",Bg).Y("mdhd",function(d){d=Oh(d.reader,d.version);b.g=d.timescale}).box("minf",Bg).box("stbl",Bg).Y("stsd",Dg).box("wvtt",function(){c=!0}).parse(a);if(!this.g)throw new O(2,2,2008);if(!c)throw new O(2,2,2008);};wv.prototype.setSequenceMode=function(){};
871
- wv.prototype.parseMedia=function(a,b){if(!this.g)throw new O(2,2,2008);var c=0,d=[],e,f=[],g=!1,h=!1,k=!1,l=null;(new xg).box("moof",Bg).box("traf",Bg).Y("tfdt",function(B){g=!0;c=Nh(B.reader,B.version).Xe}).Y("tfhd",function(B){l=Mh(B.reader,B.flags).jf}).Y("trun",function(B){h=!0;d=Ph(B.reader,B.version,B.flags).Df}).box("mdat",Eg(function(B){k=!0;e=B})).parse(a,!1);if(!k&&!g&&!h)throw new O(2,2,2008);for(var m=c,n=new ug(e,0),p=t(d),r=p.next();!r.done;r=p.next()){r=r.value;var x=r.ve||l,y=r.Dd?
872
- c+r.Dd:m;m=y+(x||0);var w=0;do{var v=n.R();w+=v;var D=n.R(),C=null;"vttc"==Fg(D)?8<v&&(C=n.Cb(v-8)):n.skip(v-8);x&&C&&(v=xv(C,b.periodStart+y/this.g,b.periodStart+m/this.g),f.push(v))}while(r.sampleSize&&w<r.sampleSize)}return f.filter(Cb)};function xv(a,b,c){var d,e,f;(new xg).box("payl",Eg(function(g){d=Rc(g)})).box("iden",Eg(function(g){e=Rc(g)})).box("sttg",Eg(function(g){f=Rc(g)})).parse(a);return d?yv(d,e,f,b,c):null}
873
- function yv(a,b,c,d,e){d=new gc(d,e,"");qv(a,d,new Map);b&&(d.id=b);if(c)for(a=new jq(c),b=mq(a);b;)rv(d,b,[]),kq(a),b=mq(a);return d}J("shaka.text.Mp4VttParser",wv);wv.prototype.parseMedia=wv.prototype.parseMedia;wv.prototype.setSequenceMode=wv.prototype.setSequenceMode;wv.prototype.parseInit=wv.prototype.parseInit;qd['application/mp4; codecs="wvtt"']=function(){return new wv};function zv(){}zv.prototype.parseInit=function(){};zv.prototype.setSequenceMode=function(){};zv.prototype.parseMedia=function(a){var b=Rc(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 jq(c[0]),e=Av(d),f=lq(d,/,/g);d=Av(d);if(null==e||null==f||null==d)throw new O(2,2,2001,"Could not parse cue time range in SubViewer");a.push(new gc(e,d,c.slice(1).join("\n").trim()))}return a};
874
- function Av(a){a=lq(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)}J("shaka.text.SbvTextParser",zv);zv.prototype.parseMedia=zv.prototype.parseMedia;zv.prototype.setSequenceMode=zv.prototype.setSequenceMode;zv.prototype.parseInit=zv.prototype.parseInit;qd["text/x-subviewer"]=function(){return new zv};function Bv(){this.g=new nv}Bv.prototype.parseInit=function(){};Bv.prototype.setSequenceMode=function(){};Bv.prototype.parseMedia=function(a,b){var c=Rc(a);c=Cv(c);c=Gc(Vc(c));return this.g.parseMedia(c,b)};function Cv(a){var b="WEBVTT\n\n";if(""==a)return b;a=a.replace(/\r+/g,"");a=a.trim();a=t(a.split("\n\n"));for(var c=a.next();!c.done;c=a.next())c=c.value.split(/\n/),c[0].match(/\d+/)&&c.shift(),c[0]=c[0].replace(/,/g,"."),b+=c.join("\n")+"\n\n";return b}J("shaka.text.SrtTextParser",Bv);
875
- Bv.srt2webvtt=Cv;Bv.prototype.parseMedia=Bv.prototype.parseMedia;Bv.prototype.setSequenceMode=Bv.prototype.setSequenceMode;Bv.prototype.parseInit=Bv.prototype.parseInit;qd["text/srt"]=function(){return new Bv};function Dv(){}Dv.prototype.parseInit=function(){};Dv.prototype.setSequenceMode=function(){};
876
- Dv.prototype.parseMedia=function(a){var b="",c="";a=Rc(a).split(/\r?\n\s*\r?\n/);a=t(a);for(var d=a.next();!d.done;d=a.next()){var e=Ev.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=Fv.exec(e)))if(e=f[1].trim(),f=f[2].trim(),"Format"==e)d=f.split(Gv);else if("Style"==e){e=f.split(Gv);f={};for(var g=0;g<d.length&&g<e.length;g++)f[d[g]]=e[g];a.push(f)}d=
877
- [];b=null;e={};c=t(c.split(/\r?\n/));for(f=c.next();!f.done;e={Vd:e.Vd},f=c.next())if(f=f.value,!/^\s*;/.test(f)&&(g=Fv.exec(f)))if(f=g[1].trim(),g=g[2].trim(),"Format"==f)b=g.split(Gv);else if("Dialogue"==f){g=g.split(Gv);f={};for(var h=0;h<b.length&&h<g.length;h++)f[b[h]]=g[h];h=Hv(f.Start);var k=Hv(f.End);g=new gc(h,k,g.slice(b.length-1).join(",").replace(/\\N/g,"\n").replace(/\{[^}]+\}/g,""));e.Vd=f.Style;(f=a.find(function(l){return function(m){return m.Name==l.Vd}}(e)))&&Iv(g,f);d.push(g)}return d};
878
- function Iv(a,b){var c=b.Fontname;c&&(a.fontFamily=c);if(c=b.Fontsize)a.fontSize=c+"px";if(c=b.PrimaryColour)if(c=Jv(c))a.color=c;if(c=b.BackColour)if(c=Jv(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=oc;a.textAlign="start";break;case 2:a.displayAlign=oc;a.textAlign=kc;break;case 3:a.displayAlign=oc;a.textAlign="end";
822
+ d=!1);if(d){this.h=h;return}}c="Unsupported keySystem";if("org.w3.clearkey"==a||"com.widevine.alpha"==a)c="None of the requested configurations were supported.";c=Error(c);c.name="NotSupportedError";c.code=DOMException.NOT_SUPPORTED_ERR;throw c;}cu.prototype.createMediaKeys=function(){var a=new bu(this.g);return Promise.resolve(a)};cu.prototype.getConfiguration=function(){return this.h};function bu(a){this.l=a;this.h=null;this.g=new wf;this.i=[];this.j=new Map}
823
+ function eu(a,b){a.h=b;a.g.Qc();var c=Zt;b&&(a.g.o(b,c+"needkey",function(d){var e=new CustomEvent("encrypted");e.initDataType="cenc";e.initData=Hc(d.initData);a.h.dispatchEvent(e)}),a.g.o(b,c+"keymessage",function(d){var e=fu(a,d.sessionId);e&&(d=(new Map).set("messageType",void 0==e.keyStatuses.nd()?"licenserequest":"licenserenewal").set("message",d.message),d=new L("message",d),e.h&&(e.h.resolve(),e.h=null),e.dispatchEvent(d))}),a.g.o(b,c+"keyadded",function(d){if(d=fu(a,d.sessionId))gu(d,"usable"),
824
+ d.g&&d.g.resolve(),d.g=null}),a.g.o(b,c+"keyerror",function(d){var e=fu(a,d.sessionId);e&&e.handleError(d)}))}bu.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 hu(b,this.l,a);this.i.push(a);return a};bu.prototype.setServerCertificate=function(){return Promise.resolve(!1)};
825
+ function fu(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 hu(a,b,c){fb.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 Nc;this.keyStatuses=new iu}qa(hu,fb);q=hu.prototype;
826
+ q.handleError=function(a){var b=Error("EME v0.1b key error"),c=a.errorCode;c.systemCode=a.systemCode;b.errorCode=c;!a.sessionId&&this.h?(45==a.systemCode&&(b.message="Unsupported session type."),this.h.reject(b),this.h=null):a.sessionId&&this.g?(this.g.reject(b),this.g=null):(b=a.systemCode,a.errorCode.code==MediaKeyError.MEDIA_KEYERR_OUTPUT?gu(this,"output-restricted"):1==b?gu(this,"expired"):gu(this,"internal-error"))};
827
+ function ju(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=Gc(id("LOAD_SESSION|"+c));else{var e=id("PERSISTENT|");d=rd(e,b)}else d=Gc(b)}catch(g){return Promise.reject(g)}a.h=new Nc;var f=du("generateKeyRequest");try{a.j[f](a.i,d)}catch(g){if("InvalidStateError"!=g.name)return a.h=null,Promise.reject(g);(new P(function(){try{a.j[f](a.i,d)}catch(h){a.h.reject(h),a.h=null}})).T(.01)}return a.h}
828
+ function ku(a,b,c){if(a.g)a.g.then(function(){return ku(a,b,c)})["catch"](function(){return ku(a,b,c)});else{a.g=b;if("webkit-org.w3.clearkey"==a.i){var d=ed(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=od(e.keys[0].k);e=od(e.keys[0].kid)}else d=Gc(c),e=null;var f=du("addKey");try{a.j[f](a.i,d,e,a.sessionId)}catch(g){a.g.reject(g),a.g=null}}}
829
+ function gu(a,b){var c=a.keyStatuses;c.size=void 0==b?0:1;c.g=b;c=new L("keystatuseschange");a.dispatchEvent(c)}q.generateRequest=function(a,b){return ju(this,b,null)};q.load=function(a){return"persistent-license"==this.l?ju(this,null,a):Promise.reject(Error("Not a persistent session."))};q.update=function(a){var b=new Nc;ku(this,b,a);return b};
830
+ q.close=function(){if("persistent-license"!=this.l){if(!this.sessionId)return this.closed.reject(Error("The session is not callable.")),this.closed;var a=du("cancelKeyRequest");try{this.j[a](this.i,this.sessionId)}catch(b){}}this.closed.resolve();return this.closed};q.remove=function(){return"persistent-license"!=this.l?Promise.reject(Error("Not a persistent session.")):this.close()};function iu(){this.size=0;this.g=void 0}q=iu.prototype;q.nd=function(){return this.g};
831
+ q.forEach=function(a){this.g&&a(this.g,qg.value())};q.get=function(a){if(this.has(a))return this.g};q.has=function(a){var b=qg.value();return this.g&&Ec(a,b)?!0:!1};q.entries=function(){};q.keys=function(){};q.values=function(){};var Zt="";st(Yt);function lu(){}function mu(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;a.requestPictureInPicture&&document.exitPictureInPicture||!a.webkitSupportsPresentationMode||(document.pictureInPictureEnabled=!0,document.pictureInPictureElement=null,a.requestPictureInPicture=nu,Object.defineProperty(a,"disablePictureInPicture",{get:ou,set:pu,enumerable:!0,configurable:!0}),document.exitPictureInPicture=qu,document.addEventListener("webkitpresentationmodechanged",ru,!0))}}
832
+ function ru(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)}
833
+ function nu(){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 qu(){var a=document.pictureInPictureElement;return a?(a.webkitSetPresentationMode("inline"),document.pictureInPictureElement=null,Promise.resolve()):Promise.reject(Error("No picture in picture element found"))}
834
+ function ou(){return this.hasAttribute("disablePictureInPicture")?!0:!this.webkitSupportsPresentationMode("picture-in-picture")}function pu(a){a?this.setAttribute("disablePictureInPicture",""):this.removeAttribute("disablePictureInPicture")}pt.PiPWebkit=lu;lu.install=mu;st(mu);function su(){}function tu(){window.crypto&&("randomUUID"in window.crypto||(window.crypto.randomUUID=uu))}function uu(){var a=URL.createObjectURL(new Blob),b=a.toString();URL.revokeObjectURL(a);return b.substr(b.lastIndexOf("/")+1)}pt.RandomUUID=su;su.install=tu;st(tu);function vu(){}function wu(){navigator.storage&&navigator.storage.estimate||!navigator.webkitTemporaryStorage||!navigator.webkitTemporaryStorage.queryUsageAndQuota||("storage"in navigator||(navigator.storage={}),navigator.storage.estimate=xu)}function xu(){return new Promise(function(a,b){navigator.webkitTemporaryStorage.queryUsageAndQuota(function(c,d){a({usage:c,quota:d})},b)})}pt.StorageEstimate=vu;vu.install=wu;st(wu);function yu(){}function zu(){var a=Symbol.prototype;"description"in a||Object.defineProperty(a,"description",{get:Au})}function Au(){var a=/\((.*)\)/.exec(this.toString());return a?a[1]:void 0}pt.Symbol=yu;yu.install=zu;st(zu);function Bu(){}function Cu(){if(window.HTMLMediaElement){var a=HTMLMediaElement.prototype.play;HTMLMediaElement.prototype.play=function(){var b=a.apply(this);b&&b["catch"](function(){});return b}}}pt.VideoPlayPromise=Bu;Bu.install=Cu;st(Cu);function Du(){}function Eu(){if(window.HTMLVideoElement){var a=HTMLVideoElement.prototype;!a.getVideoPlaybackQuality&&("webkitDroppedFrameCount"in a||Xc())&&(a.getVideoPlaybackQuality=Fu)}}function Fu(){return{droppedVideoFrames:this.webkitDroppedFrameCount,totalVideoFrames:this.webkitDecodedFrameCount,corruptedVideoFrames:0,creationTime:NaN,totalFrameDelay:0}}pt.VideoPlaybackQuality=Du;Du.install=Eu;st(Eu);function Gu(){}function Hu(){if(!window.VTTCue&&window.TextTrackCue){var a=null,b=TextTrackCue.length;if(3==b)a=Iu;else if(6==b)a=Ju;else{try{var c=!!Iu(1,2,"")}catch(d){c=!1}c&&(a=Iu)}a&&(window.VTTCue=function(d,e,f){return a(d,e,f)})}}function Iu(a,b,c){return new window.TextTrackCue(a,b,c)}function Ju(a,b,c){return new window.TextTrackCue(a+"-"+b+"-"+c,a,b,c)}pt.VTTCue=Gu;Gu.install=Hu;st(Hu);function Ku(){}Ku.prototype.parseInit=function(){};Ku.prototype.setSequenceMode=function(){};Ku.prototype.parseMedia=function(a,b){var c=null,d=[],e=ed(a).split(/\r?\n/);e=t(e);for(var f=e.next();!f.done;f=e.next())if((f=f.value)&&!/^\s+$/.test(f)&&(f=Lu.exec(f))){var g=Mu.exec(f[1]);g=60*parseInt(g[1],10)+parseFloat(g[2].replace(",","."));f=new gc(g,b.segmentEnd?b.segmentEnd:g+2,f[2]);c&&(c.endTime=g,d.push(c));c=f}c&&d.push(c);return d};J("shaka.text.LrcTextParser",Ku);Ku.prototype.parseMedia=Ku.prototype.parseMedia;
835
+ Ku.prototype.setSequenceMode=Ku.prototype.setSequenceMode;Ku.prototype.parseInit=Ku.prototype.parseInit;var Lu=/^\[(\d{1,2}:\d{1,2}(?:[.,]\d{1,3})?)\](.*)/,Mu=/^(\d+):(\d{1,2}(?:[.,]\d{1,3})?)$/;Id["application/x-subtitle-lrc"]=function(){return new Ku};function Nu(){}Nu.prototype.parseInit=function(){};Nu.prototype.setSequenceMode=function(){};
836
+ Nu.prototype.parseMedia=function(a,b){var c=ed(a),d=[],e=new DOMParser,f=null;if(""==c)return d;try{f=e.parseFromString(c,"text/xml")}catch(C){throw new O(2,2,2005,"Failed to parse TTML.");}if(f){if(c=f.getElementsByTagName("parsererror")[0])throw new O(2,2,2005,c.textContent);var g=f.getElementsByTagName("tt")[0];if(!g)throw new O(2,2,2005,"TTML does not contain <tt> tag.");f=g.getElementsByTagName("body")[0];if(!f)return[];var h=Yn(g,Ou,"frameRate"),k=Yn(g,Ou,"subFrameRate"),l=Yn(g,Ou,"frameRateMultiplier"),
837
+ m=Yn(g,Ou,"tickRate"),n=Yn(g,Ou,"cellResolution");c=g.getAttribute("xml:space")||"default";e=Yn(g,Pu,"extent");if("default"!=c&&"preserve"!=c)throw new O(2,2,2005,"Invalid xml:space value: "+c);c="default"==c;h=new Qu(h,k,l,m);n=n?(n=/^(\d+) (\d+)$/.exec(n))?{columns:parseInt(n[1],10),rows:parseInt(n[2],10)}:null:null;k=(k=g.getElementsByTagName("metadata")[0])?Wn(k):[];l=Array.from(g.getElementsByTagName("style"));g=Array.from(g.getElementsByTagName("region"));m=[];for(var p=t(g),r=p.next();!r.done;r=
838
+ p.next()){var w=r.value;r=new ic;var y=w.getAttribute("xml:id");if(y){r.id=y;var x=null;e&&(x=Ru.exec(e)||Su.exec(e));y=x?Number(x[1]):null;x=x?Number(x[2]):null;var v,D;if(v=Tu(w,l,"extent"))v=(D=Ru.exec(v))||Su.exec(v),null!=v&&(r.width=Number(v[1]),r.height=Number(v[2]),D||(null!=y&&(r.width=100*r.width/y),null!=x&&(r.height=100*r.height/x)),r.widthUnits=D||null!=y?Bc:0,r.heightUnits=D||null!=x?Bc:0);if(w=Tu(w,l,"origin"))v=(D=Ru.exec(w))||Su.exec(w),null!=v&&(r.viewportAnchorX=Number(v[1]),r.viewportAnchorY=
839
+ Number(v[2]),D||(null!=x&&(r.viewportAnchorY=100*r.viewportAnchorY/x),null!=y&&(r.viewportAnchorX=100*r.viewportAnchorX/y)),r.viewportAnchorUnits=D||null!=y?Bc:0)}else r=null;r&&m.push(r)}if(Tn(f,"p").length)throw new O(2,2,2001,"<p> can only be inside <div> in TTML");e=t(Tn(f,"div"));for(p=e.next();!p.done;p=e.next())if(Tn(p.value,"span").length)throw new O(2,2,2001,"<span> can only be inside <p> in TTML");(f=Uu(f,b.periodStart,h,k,l,g,m,c,n,null,!1))&&d.push(f)}return d};
840
+ function Uu(a,b,c,d,e,f,g,h,k,l,m){var n=a.parentNode;if(a.nodeType==Node.COMMENT_NODE)return null;if(a.nodeType==Node.TEXT_NODE){if(!m)return null;var p=document.createElement("span");p.textContent=a.textContent}else p=a;for(var r=null,w=t(Vu),y=w.next();!y.done&&!(r=Wu(p,"backgroundImage",d,"#",y.value)[0]);y=w.next());w=m;if("p"==a.nodeName||r)m=!0;h="default"==(p.getAttribute("xml:space")||(h?"default":"preserve"));y=Array.from(p.childNodes).every(function(B){return B.nodeType==Node.TEXT_NODE});
841
+ a=[];if(!y)for(var x=t(p.childNodes),v=x.next();!v.done;v=x.next())(v=Uu(v.value,b,c,d,e,f,g,h,k,p,m))&&a.push(v);d=null!=l;x=/\S/.test(p.textContent);var D=p.hasAttribute("begin")||p.hasAttribute("end")||p.hasAttribute("dur");if(!(D||x||"br"==p.tagName||0!=a.length||d&&!h))return null;v=Xu(p,c);x=v.start;for(v=v.end;n&&n.nodeType==Node.ELEMENT_NODE&&"tt"!=n.tagName;)v=Yu(n,c,x,v),x=v.start,v=v.end,n=n.parentNode;null==x&&(x=0);x+=b;v=null==v?Infinity:v+b;if(!D&&0<a.length)for(x=Infinity,v=0,b=t(a),
842
+ c=b.next();!c.done;c=b.next())c=c.value,x=Math.min(x,c.startTime),v=Math.max(v,c.endTime);if("br"==p.tagName)return e=new gc(x,v,""),e.lineBreak=!0,e;b="";y&&(b=p.textContent,h&&(b=b.trim(),b=b.replace(/\s+/g," ")));b=new gc(x,v,b);b.nestedCues=a;m||(b.isContainer=!0);k&&(b.cellResolution=k);k=Wu(p,"region",f,"")[0];if(p.hasAttribute("region")&&k&&k.getAttribute("xml:id")){var C=k.getAttribute("xml:id");b.region=g.filter(function(B){return B.id==C})[0]}g=k;l&&d&&!p.getAttribute("region")&&!p.getAttribute("style")&&
843
+ (g=Wu(l,"region",f,"")[0]);Zu(b,p,g,r,e,w,0==a.length);return b}
844
+ function Zu(a,b,c,d,e,f,g){f=f||g;"rtl"==$u(b,c,e,"direction",f)&&(a.direction="rtl");g=$u(b,c,e,"writingMode",f);"tb"==g||"tblr"==g?a.writingMode="vertical-lr":"tbrl"==g?a.writingMode="vertical-rl":"rltb"==g||"rl"==g?a.direction="rtl":g&&(a.direction=hc);(g=$u(b,c,e,"textAlign",!0))?(a.positionAlign=av[g],a.lineAlign=bv[g],a.textAlign=vc[g.toUpperCase()]):a.textAlign=kc;if(g=$u(b,c,e,"displayAlign",!0))a.displayAlign=wc[g.toUpperCase()];if(g=$u(b,c,e,"color",f))a.color=g;if(g=$u(b,c,e,"backgroundColor",
845
+ f))a.backgroundColor=g;if(g=$u(b,c,e,"border",f))a.border=g;if(g=$u(b,c,e,"fontFamily",f))a.fontFamily=g;(g=$u(b,c,e,"fontWeight",f))&&"bold"==g&&(a.fontWeight=700);g=$u(b,c,e,"wrapOption",f);a.wrapLine=g&&"noWrap"==g?!1:!0;(g=$u(b,c,e,"lineHeight",f))&&g.match(cv)&&(a.lineHeight=g);(g=$u(b,c,e,"fontSize",f))&&(g.match(cv)||g.match(dv))&&(a.fontSize=g);if(g=$u(b,c,e,"fontStyle",f))a.fontStyle=Ac[g.toUpperCase()];if(d){g=d.getAttribute("imageType")||d.getAttribute("imagetype");var h=d.getAttribute("encoding");
846
+ d=d.textContent.trim();"PNG"==g&&"Base64"==h&&d&&(a.backgroundImage="data:image/png;base64,"+d)}if(d=$u(b,c,e,"textOutline",f))d=d.split(" "),d[0].match(cv)?a.textStrokeColor=a.color:(a.textStrokeColor=d[0],d.shift()),d[0]&&d[0].match(cv)?a.textStrokeWidth=d[0]:a.textStrokeColor="";(d=$u(b,c,e,"letterSpacing",f))&&d.match(cv)&&(a.letterSpacing=d);(d=$u(b,c,e,"linePadding",f))&&d.match(cv)&&(a.linePadding=d);if(f=$u(b,c,e,"opacity",f))a.opacity=parseFloat(f);(c=Tu(c,e,"textDecoration"))&&ev(a,c);(b=
847
+ fv(b,e,"textDecoration"))&&ev(a,b)}
848
+ function ev(a,b){for(var c=t(b.split(" ")),d=c.next();!d.done;d=c.next())switch(d.value){case "underline":a.textDecoration.includes("underline")||a.textDecoration.push("underline");break;case "noUnderline":a.textDecoration.includes("underline")&&dc(a.textDecoration,"underline");break;case "lineThrough":a.textDecoration.includes("lineThrough")||a.textDecoration.push("lineThrough");break;case "noLineThrough":a.textDecoration.includes("lineThrough")&&dc(a.textDecoration,"lineThrough");break;case "overline":a.textDecoration.includes("overline")||
849
+ a.textDecoration.push("overline");break;case "noOverline":a.textDecoration.includes("overline")&&dc(a.textDecoration,"overline")}}function $u(a,b,c,d,e){e=void 0===e?!0:e;return(a=fv(a,c,d))?a:e?Tu(b,c,d):null}function Tu(a,b,c){if(!a)return null;var d=Yn(a,Pu,c);return d?d:gv(a,b,c)}function fv(a,b,c){var d=Yn(a,Pu,c);return d?d:gv(a,b,c)}
850
+ function gv(a,b,c){a=Wu(a,"style",b,"");for(var d=null,e=0;e<a.length;e++){var f=Xn(a[e],"urn:ebu:tt:style",c);f||(f=Yn(a[e],Pu,c));f||(f=fv(a[e],b,c));f&&(d=f)}return d}
851
+ function Wu(a,b,c,d,e){var f=[];if(!a||1>c.length)return f;var g=a;for(a=null;g&&!(a=e?Xn(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 Yu(a,b,c,d){a=Xu(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}}
852
+ function Xu(a,b){var c=hv(a.getAttribute("begin"),b),d=hv(a.getAttribute("end"),b),e=hv(a.getAttribute("dur"),b);null==d&&null!=e&&(d=c+e);return{start:c,end:d}}
853
+ function hv(a,b){var c=null;if(iv.test(a)){c=iv.exec(a);var d=Number(c[1]),e=Number(c[2]),f=Number(c[3]),g=Number(c[4]);g+=(Number(c[5])||0)/b.h;f+=g/b.frameRate;c=f+60*e+3600*d}else if(jv.test(a))c=kv(jv,a);else if(lv.test(a))c=kv(lv,a);else if(mv.test(a))c=mv.exec(a),c=Number(c[1])/b.frameRate;else if(nv.test(a))c=nv.exec(a),c=Number(c[1])/b.g;else if(ov.test(a))c=kv(ov,a);else if(a)throw new O(2,2,2001,"Could not parse cue time range in TTML");return c}
854
+ function kv(a,b){var c=a.exec(b);return null==c||""==c[0]?null:(Number(c[4])||0)/1E3+(Number(c[3])||0)+60*(Number(c[2])||0)+3600*(Number(c[1])||0)}J("shaka.text.TtmlTextParser",Nu);Nu.prototype.parseMedia=Nu.prototype.parseMedia;Nu.prototype.setSequenceMode=Nu.prototype.setSequenceMode;Nu.prototype.parseInit=Nu.prototype.parseInit;
855
+ function Qu(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]))}
856
+ var Ru=/^(\d{1,2}(?:\.\d+)?|100(?:\.0+)?)% (\d{1,2}(?:\.\d+)?|100(?:\.0+)?)%$/,dv=/^(\d{1,2}(?:\.\d+)?|100)%$/,cv=/^(\d+px|\d+em|\d*\.?\d+c)$/,Su=/^(\d+)px (\d+)px$/,iv=/^(\d{2,}):(\d{2}):(\d{2}):(\d{2})\.?(\d+)?$/,jv=/^(?:(\d{2,}):)?(\d{2}):(\d{2})$/,lv=/^(?:(\d{2,}):)?(\d{2}):(\d{2}\.\d{2,})$/,mv=/^(\d*(?:\.\d*)?)f$/,nv=/^(\d*(?:\.\d*)?)t$/,ov=RegExp("^(?:(\\d*(?:\\.\\d*)?)h)?(?:(\\d*(?:\\.\\d*)?)m)?(?:(\\d*(?:\\.\\d*)?)s)?(?:(\\d*(?:\\.\\d*)?)ms)?$"),bv={left:nc,center:"center",right:"end",start:nc,
857
+ end:"end"},av={left:"line-left",center:"center",right:"line-right"},Ou=["http://www.w3.org/ns/ttml#parameter","http://www.w3.org/2006/10/ttaf1#parameter"],Pu=["http://www.w3.org/ns/ttml#styling","http://www.w3.org/2006/10/ttaf1#styling"],Vu=["http://www.smpte-ra.org/schemas/2052-1/2010/smpte-tt","http://www.smpte-ra.org/schemas/2052-1/2013/smpte-tt"];Id["application/ttml+xml"]=function(){return new Nu};function pv(){this.g=new Nu}pv.prototype.parseInit=function(a){var b=!1;(new Ag).box("moov",Eg).box("trak",Eg).box("mdia",Eg).box("minf",Eg).box("stbl",Eg).Y("stsd",Gg).box("stpp",function(c){b=!0;c.parser.stop()}).parse(a);if(!b)throw new O(2,2,2007);};pv.prototype.setSequenceMode=function(){};pv.prototype.parseMedia=function(a,b){var c=this,d=!1,e=[];(new Ag).box("mdat",Hg(function(f){d=!0;e=e.concat(c.g.parseMedia(f,b))})).parse(a,!1);if(!d)throw new O(2,2,2007);return e};
858
+ J("shaka.text.Mp4TtmlParser",pv);pv.prototype.parseMedia=pv.prototype.parseMedia;pv.prototype.setSequenceMode=pv.prototype.setSequenceMode;pv.prototype.parseInit=pv.prototype.parseInit;Id['application/mp4; codecs="stpp"']=function(){return new pv};Id['application/mp4; codecs="stpp.ttml"']=function(){return new pv};Id['application/mp4; codecs="stpp.ttml.im1t"']=function(){return new pv};Id['application/mp4; codecs="stpp.TTML.im1t"']=function(){return new pv};function qv(){this.g=!1}qv.prototype.parseInit=function(){};qv.prototype.setSequenceMode=function(a){this.g=a};
859
+ qv.prototype.parseMedia=function(a,b){var c=ed(a);c=c.replace(/\r\n|\r(?=[^\n]|$)/gm,"\n");var d=c.split(/\n{2,}/m);if(!/^WEBVTT($|[ \t\n])/m.test(d[0]))throw new O(2,2,2E3);c=b.vttOffset;if(d[0].includes("X-TIMESTAMP-MAP")&&this.g){var e=d[0].match(/LOCAL:((?:(\d{1,}):)?(\d{2}):(\d{2})\.(\d{3}))/m),f=d[0].match(/MPEGTS:(\d+)/m);if(e&&f){c=rv(new mq(e[1]));if(null==c)throw new O(2,2,2E3);f=Number(f[1]);for(e=b.segmentStart;95443.7176888889<=e;)e-=95443.7176888889,f+=8589934592;c=b.periodStart+f/9E4-
860
+ c}}f=[];e=t(d[0].split("\n"));for(var g=e.next();!g.done;g=e.next())if(g=g.value,/^Region:/.test(g)){g=new mq(g);var h=new ic;pq(g);nq(g);for(var k=pq(g);k;){var l=h,m=k;(k=/^id=(.*)$/.exec(m))?l.id=k[1]:(k=/^width=(\d{1,2}|100)%$/.exec(m))?l.width=Number(k[1]):(k=/^lines=(\d+)$/.exec(m))?(l.height=Number(k[1]),l.heightUnits=2):(k=/^regionanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(m))?(l.regionAnchorX=Number(k[1]),l.regionAnchorY=Number(k[2])):(k=/^viewportanchor=(\d{1,2}|100)%,(\d{1,2}|100)%$/.exec(m))?
861
+ (l.viewportAnchorX=Number(k[1]),l.viewportAnchorY=Number(k[2])):/^scroll=up$/.exec(m)&&(l.scroll="up");nq(g);k=pq(g)}f.push(h)}e=new Map;sv(e);g=[];d=t(d.slice(1));for(h=d.next();!h.done;h=d.next()){h=h.value.split("\n");if((1!=h.length||h[0])&&!/^NOTE($|[ \t])/.test(h[0])&&"STYLE"==h[0]&&h[1].includes("::cue")){l="global";(k=h[1].match(/\((.*)\)/))&&(l=k.pop());k=h.slice(2,-1);h[1].includes("}")&&(m=/\{(.*?)\}/.exec(h[1]))&&(k=m[1].split(";"));m=new gc(0,0,"");for(var n=!1,p=0;p<k.length;p++){var r=
862
+ /^\s*([^:]+):\s*(.*)/.exec(k[p]);if(r){var w=r[2].trim().replace(";","");switch(r[1].trim()){case "background-color":n=!0;m.backgroundColor=w;break;case "color":n=!0;m.color=w;break;case "font-family":n=!0;m.fontFamily=w;break;case "font-size":n=!0;m.fontSize=w;break;case "font-weight":700<=parseInt(w,10)&&(n=!0,m.fontWeight=700);break;case "font-style":switch(w){case "normal":n=!0;m.fontStyle=qc;break;case "italic":n=!0;m.fontStyle="italic";break;case "oblique":n=!0,m.fontStyle="oblique"}break;case "opacity":n=
863
+ !0;m.opacity=parseFloat(w);break;case "text-shadow":n=!0;m.textShadow=w;break;case "white-space":n=!0,m.wrapLine="noWrap"!=w}}}n&&e.set(l,m)}p=c;if(1==h.length&&!h[0]||/^NOTE($|[ \t])/.test(h[0])||"STYLE"==h[0])h=null;else{l=null;h[0].includes("--\x3e")||(l=h[0],h.splice(0,1));k=new mq(h[0]);m=rv(k);r=oq(k,/[ \t]+--\x3e[ \t]+/g);n=rv(k);if(null==m||null==r||null==n)throw new O(2,2,2001,"Could not parse cue time range in WebVTT");m+=p;n+=p;p=h.slice(1).join("\n").trim();e.has("global")?(h=e.get("global").clone(),
864
+ h.startTime=m,h.endTime=n,h.payload=""):h=new gc(m,n,"");tv(p,h,e);nq(k);for(m=pq(k);m;)uv(h,m,f),nq(k),m=pq(k);null!=l&&(h.id=l)}h&&g.push(h)}return g};function sv(a){for(var b=t(Object.entries(yc)),c=b.next();!c.done;c=b.next()){var d=t(c.value);c=d.next().value;d=d.next().value;var e=new gc(0,0,"");e.color=d;a.set(c,e)}b=t(Object.entries(zc));for(c=b.next();!c.done;c=b.next())d=t(c.value),c=d.next().value,d=d.next().value,e=new gc(0,0,""),e.backgroundColor=d,a.set(c,e)}
865
+ function tv(a,b,c){0===c.size&&sv(c);a=vv(a);var d=ko("<span>"+a+"</span>","span");if(d){var e=[];d=d.childNodes;if(1==d.length){var f=d[0];if(f.nodeType==Node.TEXT_NODE||f.nodeType==Node.CDATA_SECTION_NODE){b.payload=a;return}}a=t(d);for(d=a.next();!d.done;d=a.next())wv(d.value,b,e,c);b.nestedCues=e}else b.payload=a}
866
+ function vv(a){for(var b=[],c=-1,d="",e=0;e<a.length;e++)if("/"===a[e]){var f=a.indexOf(">",e);if(f<=e)return a;f=a.substring(e+1,f);var g=b.pop();if(f&&g){if(g===f)d+="/"+f+">";else{if(!g.startsWith("c.")||"c"!==f)return a;d+="/"+g+">"}e+=f.length+1}else return a}else"<"===a[e]?c=e+1:">"===a[e]&&0<c&&(b.push(a.substr(c,e-c)),c=-1),d+=a[e];return d}function xv(a,b){return a&&0<a.length?a:b}
867
+ function wv(a,b,c,d){var e=b.clone();if(a.nodeType===Node.ELEMENT_NODE&&a.nodeName)for(var f=t(a.nodeName.split(/[ .]+/)),g=f.next();!g.done;g=f.next()){g=g.value;if(d.has(g)){var h=d.get(g);h&&(e.backgroundColor=xv(h.backgroundColor,e.backgroundColor),e.color=xv(h.color,e.color),e.fontFamily=xv(h.fontFamily,e.fontFamily),e.fontSize=xv(h.fontSize,e.fontSize),e.fontWeight=h.fontWeight,e.fontStyle=h.fontStyle,e.opacity=h.opacity,e.wrapLine=h.wrapLine)}switch(g){case "b":e.fontWeight=700;break;case "i":e.fontStyle=
868
+ "italic";break;case "u":e.textDecoration.push("underline")}}if($n(a))for(f=!0,d=t(a.textContent.split("\n")),a=d.next();!a.done;a=d.next())a=a.value,f||(f=b.clone(),f.lineBreak=!0,c.push(f)),0<a.length&&(f=e.clone(),f.payload=a,c.push(f)),f=!1;else for(b=t(a.childNodes),a=b.next();!a.done;a=b.next())wv(a.value,e,c,d)}
869
+ function uv(a,b,c){var d;if(d=/^align:(start|middle|center|end|left|right)$/.exec(b))b=d[1],"middle"==b?a.textAlign=kc:a.textAlign=vc[b.toUpperCase()];else if(d=/^vertical:(lr|rl)$/.exec(b))a.writingMode="lr"==d[1]?"vertical-lr":"vertical-rl";else if(d=/^size:([\d.]+)%$/.exec(b))a.size=Number(d[1]);else if(d=/^position:([\d.]+)%(?:,(line-left|line-right|center|start|end))?$/.exec(b))a.position=Number(d[1]),d[2]&&(b=d[2],a.positionAlign="line-left"==b||"start"==b?"line-left":"line-right"==b||"end"==
870
+ b?"line-right":"center");else if(d=/^region:(.*)$/.exec(b)){if(b=yv(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=xc[c[2].toUpperCase()]);else if(c=/^line:(-?\d+)(?:,(start|end|center))?$/.exec(b))a.lineInterpretation=mc,a.line=Number(c[1]),c[2]&&(a.lineAlign=xc[c[2].toUpperCase()])}function yv(a,b){var c=a.filter(function(d){return d.id==b});return c.length?c[0]:null}
871
+ function rv(a){a=oq(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)}J("shaka.text.VttTextParser",qv);qv.prototype.parseMedia=qv.prototype.parseMedia;qv.prototype.setSequenceMode=qv.prototype.setSequenceMode;qv.prototype.parseInit=qv.prototype.parseInit;Id["text/vtt"]=function(){return new qv};Id['text/vtt; codecs="vtt"']=function(){return new qv};
872
+ Id['text/vtt; codecs="wvtt"']=function(){return new qv};function zv(){this.g=null}zv.prototype.parseInit=function(a){var b=this,c=!1;(new Ag).box("moov",Eg).box("trak",Eg).box("mdia",Eg).Y("mdhd",function(d){d=Rh(d.reader,d.version);b.g=d.timescale}).box("minf",Eg).box("stbl",Eg).Y("stsd",Gg).box("wvtt",function(){c=!0}).parse(a);if(!this.g)throw new O(2,2,2008);if(!c)throw new O(2,2,2008);};zv.prototype.setSequenceMode=function(){};
873
+ zv.prototype.parseMedia=function(a,b){if(!this.g)throw new O(2,2,2008);var c=0,d=[],e,f=[],g=!1,h=!1,k=!1,l=null;(new Ag).box("moof",Eg).box("traf",Eg).Y("tfdt",function(B){g=!0;c=Qh(B.reader,B.version).Ye}).Y("tfhd",function(B){l=Ph(B.reader,B.flags).kf}).Y("trun",function(B){h=!0;d=Sh(B.reader,B.version,B.flags).Ef}).box("mdat",Hg(function(B){k=!0;e=B})).parse(a,!1);if(!k&&!g&&!h)throw new O(2,2,2008);for(var m=c,n=new xg(e,0),p=t(d),r=p.next();!r.done;r=p.next()){r=r.value;var w=r.we||l,y=r.Dd?
874
+ c+r.Dd:m;m=y+(w||0);var x=0;do{var v=n.R();x+=v;var D=n.R(),C=null;"vttc"==Ig(D)?8<v&&(C=n.Cb(v-8)):n.skip(v-8);w&&C&&(v=Av(C,b.periodStart+y/this.g,b.periodStart+m/this.g),f.push(v))}while(r.sampleSize&&x<r.sampleSize)}return f.filter(Cb)};function Av(a,b,c){var d,e,f;(new Ag).box("payl",Hg(function(g){d=ed(g)})).box("iden",Hg(function(g){e=ed(g)})).box("sttg",Hg(function(g){f=ed(g)})).parse(a);return d?Bv(d,e,f,b,c):null}
875
+ function Bv(a,b,c,d,e){d=new gc(d,e,"");tv(a,d,new Map);b&&(d.id=b);if(c)for(a=new mq(c),b=pq(a);b;)uv(d,b,[]),nq(a),b=pq(a);return d}J("shaka.text.Mp4VttParser",zv);zv.prototype.parseMedia=zv.prototype.parseMedia;zv.prototype.setSequenceMode=zv.prototype.setSequenceMode;zv.prototype.parseInit=zv.prototype.parseInit;Id['application/mp4; codecs="wvtt"']=function(){return new zv};function Cv(){}Cv.prototype.parseInit=function(){};Cv.prototype.setSequenceMode=function(){};Cv.prototype.parseMedia=function(a){var b=ed(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 mq(c[0]),e=Dv(d),f=oq(d,/,/g);d=Dv(d);if(null==e||null==f||null==d)throw new O(2,2,2001,"Could not parse cue time range in SubViewer");a.push(new gc(e,d,c.slice(1).join("\n").trim()))}return a};
876
+ function Dv(a){a=oq(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)}J("shaka.text.SbvTextParser",Cv);Cv.prototype.parseMedia=Cv.prototype.parseMedia;Cv.prototype.setSequenceMode=Cv.prototype.setSequenceMode;Cv.prototype.parseInit=Cv.prototype.parseInit;Id["text/x-subviewer"]=function(){return new Cv};function Ev(){this.g=new qv}Ev.prototype.parseInit=function(){};Ev.prototype.setSequenceMode=function(){};Ev.prototype.parseMedia=function(a,b){var c=ed(a);c=Fv(c);c=Gc(id(c));return this.g.parseMedia(c,b)};function Fv(a){var b="WEBVTT\n\n";if(""==a)return b;a=a.replace(/\r+/g,"");a=a.trim();a=t(a.split("\n\n"));for(var c=a.next();!c.done;c=a.next())c=c.value.split(/\n/),c[0].match(/\d+/)&&c.shift(),c[0]=c[0].replace(/,/g,"."),b+=c.join("\n")+"\n\n";return b}J("shaka.text.SrtTextParser",Ev);
877
+ Ev.srt2webvtt=Fv;Ev.prototype.parseMedia=Ev.prototype.parseMedia;Ev.prototype.setSequenceMode=Ev.prototype.setSequenceMode;Ev.prototype.parseInit=Ev.prototype.parseInit;Id["text/srt"]=function(){return new Ev};function Gv(){}Gv.prototype.parseInit=function(){};Gv.prototype.setSequenceMode=function(){};
878
+ Gv.prototype.parseMedia=function(a){var b="",c="";a=ed(a).split(/\r?\n\s*\r?\n/);a=t(a);for(var d=a.next();!d.done;d=a.next()){var e=Hv.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=Iv.exec(e)))if(e=f[1].trim(),f=f[2].trim(),"Format"==e)d=f.split(Jv);else if("Style"==e){e=f.split(Jv);f={};for(var g=0;g<d.length&&g<e.length;g++)f[d[g]]=e[g];a.push(f)}d=
879
+ [];b=null;e={};c=t(c.split(/\r?\n/));for(f=c.next();!f.done;e={Vd:e.Vd},f=c.next())if(f=f.value,!/^\s*;/.test(f)&&(g=Iv.exec(f)))if(f=g[1].trim(),g=g[2].trim(),"Format"==f)b=g.split(Jv);else if("Dialogue"==f){g=g.split(Jv);f={};for(var h=0;h<b.length&&h<g.length;h++)f[b[h]]=g[h];h=Kv(f.Start);var k=Kv(f.End);g=new gc(h,k,g.slice(b.length-1).join(",").replace(/\\N/g,"\n").replace(/\{[^}]+\}/g,""));e.Vd=f.Style;(f=a.find(function(l){return function(m){return m.Name==l.Vd}}(e)))&&Lv(g,f);d.push(g)}return d};
880
+ function Lv(a,b){var c=b.Fontname;c&&(a.fontFamily=c);if(c=b.Fontsize)a.fontSize=c+"px";if(c=b.PrimaryColour)if(c=Mv(c))a.color=c;if(c=b.BackColour)if(c=Mv(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=oc;a.textAlign="start";break;case 2:a.displayAlign=oc;a.textAlign=kc;break;case 3:a.displayAlign=oc;a.textAlign="end";
879
881
  break;case 5:a.displayAlign="before";a.textAlign="start";break;case 6:a.displayAlign="before";a.textAlign=kc;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=kc;break;case 11:a.displayAlign="center",a.textAlign="end"}if(c=b.AlphaLevel)a.opacity=parseFloat(c)}
880
- function Jv(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 Hv(a){a=Kv.exec(a);return 3600*(a[1]?parseInt(a[1].replace(":",""),10):0)+60*parseInt(a[2],10)+parseFloat(a[3])}J("shaka.text.SsaTextParser",Dv);Dv.prototype.parseMedia=Dv.prototype.parseMedia;Dv.prototype.setSequenceMode=Dv.prototype.setSequenceMode;Dv.prototype.parseInit=Dv.prototype.parseInit;
881
- var Ev=/^\s*\[([^\]]+)\]\r?\n([\s\S]*)/,Fv=/^\s*([^:]+):\s*(.*)/,Gv=/\s*,\s*/,Kv=/^(\d+:)?(\d{1,2}):(\d{1,2}(?:[.]\d{1,3})?)?$/;qd["text/x-ssa"]=function(){return new Dv};function Lv(){}J("shaka.util.FairPlayUtils",Lv);Lv.commonFairPlayResponse=function(a,b){if(2===a){try{var c=Rc(b.data)}catch(f){return}var d=!1;c=c.trim();"<ckc>"===c.substr(0,5)&&"</ckc>"===c.substr(-6)&&(c=c.slice(5,-6),d=!0);try{var e=JSON.parse(c);e.ckc&&(c=e.ckc,d=!0);e.CkcMessage&&(c=e.CkcMessage,d=!0);e.License&&(c=e.License,d=!0)}catch(f){}d&&(b.data=Hc($c(c)))}};
882
- Lv.spcFairPlayRequest=function(a,b){if(2===a){var c=Gc(b.body);c=Zc(c);b.headers["Content-Type"]="application/x-www-form-urlencoded";b.body=Vc("spc="+c)}};Lv.initDataTransform=function(a,b,c){function d(h){Jc(f).setUint32(g,h.byteLength,!0);g+=4;f.set(Gc(h),g);g+=h.byteLength}if(!c||!c.byteLength)throw new O(2,6,6015);var e;"string"==typeof b?e=Wc(b,!0):e=b;a=Uc(a);a=Wc(a,!0);var f=new Uint8Array(12+a.byteLength+e.byteLength+c.byteLength),g=0;d(a);d(e);d(c);return f};
883
- Lv.defaultGetContentId=function(a){a=Uc(a);return(new lb(a)).Za};Lv.isFairPlaySupported=function(){var a;return I(function(b){if(1==b.g)return a={initDataTypes:["cenc","sinf","skd"],videoCapabilities:[{contentType:'video/mp4; codecs="avc1.42E01E"'}]},A(b,2),u(b,navigator.requestMediaKeySystemAccess("com.apple.fps",[a]),4);if(2!=b.g)return b["return"](!0);F(b);return b["return"](!1)})};/*
882
+ function Mv(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 Kv(a){a=Nv.exec(a);return 3600*(a[1]?parseInt(a[1].replace(":",""),10):0)+60*parseInt(a[2],10)+parseFloat(a[3])}J("shaka.text.SsaTextParser",Gv);Gv.prototype.parseMedia=Gv.prototype.parseMedia;Gv.prototype.setSequenceMode=Gv.prototype.setSequenceMode;Gv.prototype.parseInit=Gv.prototype.parseInit;
883
+ var Hv=/^\s*\[([^\]]+)\]\r?\n([\s\S]*)/,Iv=/^\s*([^:]+):\s*(.*)/,Jv=/\s*,\s*/,Nv=/^(\d+:)?(\d{1,2}):(\d{1,2}(?:[.]\d{1,3})?)?$/;Id["text/x-ssa"]=function(){return new Gv};function Ov(){}J("shaka.util.FairPlayUtils",Ov);Ov.commonFairPlayResponse=function(a,b){if(2===a){try{var c=ed(b.data)}catch(f){return}var d=!1;c=c.trim();"<ckc>"===c.substr(0,5)&&"</ckc>"===c.substr(-6)&&(c=c.slice(5,-6),d=!0);try{var e=JSON.parse(c);e.ckc&&(c=e.ckc,d=!0);e.CkcMessage&&(c=e.CkcMessage,d=!0);e.License&&(c=e.License,d=!0)}catch(f){}d&&(b.data=Hc(od(c)))}};
884
+ Ov.spcFairPlayRequest=function(a,b){if(2===a){var c=Gc(b.body);c=nd(c);b.headers["Content-Type"]="application/x-www-form-urlencoded";b.body=id("spc="+c)}};Ov.initDataTransform=function(a,b,c){function d(h){Jc(f).setUint32(g,h.byteLength,!0);g+=4;f.set(Gc(h),g);g+=h.byteLength}if(!c||!c.byteLength)throw new O(2,6,6015);var e;"string"==typeof b?e=jd(b,!0):e=b;a=hd(a);a=jd(a,!0);var f=new Uint8Array(12+a.byteLength+e.byteLength+c.byteLength),g=0;d(a);d(e);d(c);return f};
885
+ Ov.defaultGetContentId=function(a){a=hd(a);return(new lb(a)).Za};Ov.isFairPlaySupported=function(){var a;return I(function(b){if(1==b.g)return a={initDataTypes:["cenc","sinf","skd"],videoCapabilities:[{contentType:'video/mp4; codecs="avc1.42E01E"'}]},A(b,2),u(b,navigator.requestMediaKeySystemAccess("com.apple.fps",[a]),4);if(2!=b.g)return b["return"](!0);F(b);return b["return"](!1)})};/*
884
886
  @license
885
887
  EME Encryption Scheme Polyfill
886
888
  Copyright 2019 Google LLC
887
889
  SPDX-License-Identifier: Apache-2.0
888
890
  */
889
- function Mv(){}var Nv;function Ov(){Nv?console.debug("EmeEncryptionSchemePolyfill: Already installed."):navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration?(Nv=navigator.requestMediaKeySystemAccess,console.debug("EmeEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.requestMediaKeySystemAccess=Pv):console.debug("EmeEncryptionSchemePolyfill: EME not found")}
890
- function Pv(a,b){var c=this,d;return I(function(e){if(1==e.g)return console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess'),u(e,Nv.call(c,a,b),2);d=e.h;if(Qv(d))return console.debug("EmeEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.requestMediaKeySystemAccess=Nv,e["return"](d);console.debug("EmeEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");navigator.requestMediaKeySystemAccess=Rv;return e["return"](Rv.call(c,
891
+ function Pv(){}var Qv;function Rv(){Qv?console.debug("EmeEncryptionSchemePolyfill: Already installed."):navigator.requestMediaKeySystemAccess&&MediaKeySystemAccess.prototype.getConfiguration?(Qv=navigator.requestMediaKeySystemAccess,console.debug("EmeEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.requestMediaKeySystemAccess=Sv):console.debug("EmeEncryptionSchemePolyfill: EME not found")}
892
+ function Sv(a,b){var c=this,d;return I(function(e){if(1==e.g)return console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess'),u(e,Qv.call(c,a,b),2);d=e.h;if(Tv(d))return console.debug("EmeEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.requestMediaKeySystemAccess=Qv,e["return"](d);console.debug("EmeEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");navigator.requestMediaKeySystemAccess=Uv;return e["return"](Uv.call(c,
891
893
  a,b))})}
892
- function Rv(a,b){var c=this,d,e,f,g,h,k,l,m,n,p;return I(function(r){if(1==r.g){console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess');d=Sv(a);e=[];f=t(b);for(g=f.next();!g.done;g=f.next())h=g.value,k=Tv(h.videoCapabilities,d),l=Tv(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."),
893
- n.name="NotSupportedError",n.code=DOMException.NOT_SUPPORTED_ERR,n;return u(r,Nv.call(c,a,e),2)}p=r.h;return r["return"](new Uv(p,d))})}function Tv(a,b){return a?a.filter(function(c){return!c.encryptionScheme||c.encryptionScheme==b}):a}J("EmeEncryptionSchemePolyfill",Mv);Mv.install=Ov;function Vv(){}var Wv;
894
- function Xv(){Wv?console.debug("McEncryptionSchemePolyfill: Already installed."):navigator.mediaCapabilities?(Wv=navigator.mediaCapabilities.decodingInfo,console.debug("McEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.mediaCapabilities.decodingInfo=Yv):console.debug("McEncryptionSchemePolyfill: MediaCapabilities not found")}
895
- function Yv(a){var b=this,c,d,e;return I(function(f){switch(f.g){case 1:return console.assert(b==navigator.mediaCapabilities,'bad "this" for decodingInfo'),u(f,Wv.call(b,a),2);case 2:c=f.h;if(!a.keySystemConfiguration)return f["return"](c);if((d=c.keySystemAccess)&&Qv(d))return console.debug("McEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.mediaCapabilities.decodingInfo=Wv,f["return"](c);console.debug("McEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");
896
- navigator.mediaCapabilities.decodingInfo=Zv;if(d){f.D(3);break}e=c;return u(f,$v(a),4);case 4:return e.keySystemAccess=f.h,f["return"](c);case 3:return f["return"](Zv.call(b,a))}})}
897
- function Zv(a){var b=this,c,d,e,f,g,h,k,l;return I(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=Sv(e),h={powerEfficient:!1,smooth:!1,supported:!1,keySystemAccess:null,configuration:a},f&&f!=c||g&&g!=c)?m["return"](h):u(m,Wv.call(b,a),2);case 2:k=m.h;if(k.keySystemAccess){k.keySystemAccess=
898
- new Uv(k.keySystemAccess,c);m.D(3);break}if(!a.keySystemConfiguration){m.D(3);break}l=k;return u(m,$v(a),5);case 5:l.keySystemAccess=m.h;case 3:return m["return"](k)}})}
899
- function $v(a){var b,c;return I(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 u(d,
900
- navigator.requestMediaKeySystemAccess(a.keySystemConfiguration.keySystem,[b]),2)}c=d.h;return d["return"](c)})}J("McEncryptionSchemePolyfill",Vv);Vv.install=Xv;function Uv(a,b){this.h=a;this.g=b;this.keySystem=a.keySystem}
901
- Uv.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};Uv.prototype.createMediaKeys=function(){return this.h.createMediaKeys()};
902
- function Sv(a){if(a.startsWith("com.widevine")||a.startsWith("com.microsoft")||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 Qv(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}function aw(){}
903
- function vt(){Ov();Xv()}J("EncryptionSchemePolyfills",aw);aw.install=vt;"undefined"!==typeof module&&module.exports&&(module.exports=aw);/*
894
+ function Uv(a,b){var c=this,d,e,f,g,h,k,l,m,n,p;return I(function(r){if(1==r.g){console.assert(c==navigator,'bad "this" for requestMediaKeySystemAccess');d=Vv(a);e=[];f=t(b);for(g=f.next();!g.done;g=f.next())h=g.value,k=Wv(h.videoCapabilities,d),l=Wv(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."),
895
+ n.name="NotSupportedError",n.code=DOMException.NOT_SUPPORTED_ERR,n;return u(r,Qv.call(c,a,e),2)}p=r.h;return r["return"](new Xv(p,d))})}function Wv(a,b){return a?a.filter(function(c){return!c.encryptionScheme||c.encryptionScheme==b}):a}J("EmeEncryptionSchemePolyfill",Pv);Pv.install=Rv;function Yv(){}var Zv;
896
+ function $v(){Zv?console.debug("McEncryptionSchemePolyfill: Already installed."):navigator.mediaCapabilities?(Zv=navigator.mediaCapabilities.decodingInfo,console.debug("McEncryptionSchemePolyfill: Waiting to detect encryptionScheme support."),navigator.mediaCapabilities.decodingInfo=aw):console.debug("McEncryptionSchemePolyfill: MediaCapabilities not found")}
897
+ function aw(a){var b=this,c,d,e;return I(function(f){switch(f.g){case 1:return console.assert(b==navigator.mediaCapabilities,'bad "this" for decodingInfo'),u(f,Zv.call(b,a),2);case 2:c=f.h;if(!a.keySystemConfiguration)return f["return"](c);if((d=c.keySystemAccess)&&Tv(d))return console.debug("McEncryptionSchemePolyfill: Native encryptionScheme support found."),navigator.mediaCapabilities.decodingInfo=Zv,f["return"](c);console.debug("McEncryptionSchemePolyfill: No native encryptionScheme support found. Patching encryptionScheme support.");
898
+ navigator.mediaCapabilities.decodingInfo=bw;if(d){f.D(3);break}e=c;return u(f,cw(a),4);case 4:return e.keySystemAccess=f.h,f["return"](c);case 3:return f["return"](bw.call(b,a))}})}
899
+ function bw(a){var b=this,c,d,e,f,g,h,k,l;return I(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=Vv(e),h={powerEfficient:!1,smooth:!1,supported:!1,keySystemAccess:null,configuration:a},f&&f!=c||g&&g!=c)?m["return"](h):u(m,Zv.call(b,a),2);case 2:k=m.h;if(k.keySystemAccess){k.keySystemAccess=
900
+ new Xv(k.keySystemAccess,c);m.D(3);break}if(!a.keySystemConfiguration){m.D(3);break}l=k;return u(m,cw(a),5);case 5:l.keySystemAccess=m.h;case 3:return m["return"](k)}})}
901
+ function cw(a){var b,c;return I(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 u(d,
902
+ navigator.requestMediaKeySystemAccess(a.keySystemConfiguration.keySystem,[b]),2)}c=d.h;return d["return"](c)})}J("McEncryptionSchemePolyfill",Yv);Yv.install=$v;function Xv(a,b){this.h=a;this.g=b;this.keySystem=a.keySystem}
903
+ Xv.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};Xv.prototype.createMediaKeys=function(){return this.h.createMediaKeys()};
904
+ function Vv(a){if(a.startsWith("com.widevine")||a.startsWith("com.microsoft")||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 Tv(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}function dw(){}
905
+ function yt(){Rv();$v()}J("EncryptionSchemePolyfills",dw);dw.install=yt;"undefined"!==typeof module&&module.exports&&(module.exports=dw);/*
904
906
  @license
905
907
  Copyright 2013 Ali Al Dallal
906
908
 
@@ -924,7 +926,7 @@ function vt(){Ov();Xv()}J("EncryptionSchemePolyfills",aw);aw.install=vt;"undefin
924
926
  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
925
927
  SOFTWARE.
926
928
  */
927
- for(var bw={ach:{s:"Lwo",u:"Acholi"},ady:{s:"\u0410\u0434\u044b\u0433\u044d\u0431\u0437\u044d",u:"Adyghe"},af:{s:"Afrikaans",u:"Afrikaans"},"af-NA":{s:"Afrikaans (Namibia)",u:"Afrikaans (Namibia)"},"af-ZA":{s:"Afrikaans (South Africa)",u:"Afrikaans (South Africa)"},ak:{s:"T\u0255\u0265i",u:"Akan"},ar:{s:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",u:"Arabic"},"ar-AR":{s:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",u:"Arabic"},"ar-MA":{s:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",u:"Arabic (Morocco)"},
929
+ for(var ew={ach:{s:"Lwo",u:"Acholi"},ady:{s:"\u0410\u0434\u044b\u0433\u044d\u0431\u0437\u044d",u:"Adyghe"},af:{s:"Afrikaans",u:"Afrikaans"},"af-NA":{s:"Afrikaans (Namibia)",u:"Afrikaans (Namibia)"},"af-ZA":{s:"Afrikaans (South Africa)",u:"Afrikaans (South Africa)"},ak:{s:"T\u0255\u0265i",u:"Akan"},ar:{s:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",u:"Arabic"},"ar-AR":{s:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",u:"Arabic"},"ar-MA":{s:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629",u:"Arabic (Morocco)"},
928
930
  "ar-SA":{s:"\u0627\u0644\u0639\u0631\u0628\u064a\u0629 (\u0627\u0644\u0633\u0639\u0648\u062f\u064a\u0629)",u:"Arabic (Saudi Arabia)"},"ay-BO":{s:"Aymar aru",u:"Aymara"},az:{s:"Az\u0259rbaycan dili",u:"Azerbaijani"},"az-AZ":{s:"Az\u0259rbaycan dili",u:"Azerbaijani"},"be-BY":{s:"\u0411\u0435\u043b\u0430\u0440\u0443\u0441\u043a\u0430\u044f",u:"Belarusian"},bg:{s:"\u0411\u044a\u043b\u0433\u0430\u0440\u0441\u043a\u0438",u:"Bulgarian"},"bg-BG":{s:"\u0411\u044a\u043b\u0433\u0430\u0440\u0441\u043a\u0438",
929
931
  u:"Bulgarian"},bn:{s:"\u09ac\u09be\u0982\u09b2\u09be",u:"Bengali"},"bn-IN":{s:"\u09ac\u09be\u0982\u09b2\u09be (\u09ad\u09be\u09b0\u09a4)",u:"Bengali (India)"},"bn-BD":{s:"\u09ac\u09be\u0982\u09b2\u09be(\u09ac\u09be\u0982\u09b2\u09be\u09a6\u09c7\u09b6)",u:"Bengali (Bangladesh)"},"bs-BA":{s:"Bosanski",u:"Bosnian"},ca:{s:"Catal\u00e0",u:"Catalan"},"ca-ES":{s:"Catal\u00e0",u:"Catalan"},cak:{s:"Maya Kaqchikel",u:"Kaqchikel"},"ck-US":{s:"\u13e3\u13b3\u13a9 (tsalagi)",u:"Cherokee"},cs:{s:"\u010ce\u0161tina",
930
932
  u:"Czech"},"cs-CZ":{s:"\u010ce\u0161tina",u:"Czech"},cy:{s:"Cymraeg",u:"Welsh"},"cy-GB":{s:"Cymraeg",u:"Welsh"},da:{s:"Dansk",u:"Danish"},"da-DK":{s:"Dansk",u:"Danish"},de:{s:"Deutsch",u:"German"},"de-AT":{s:"Deutsch (\u00d6sterreich)",u:"German (Austria)"},"de-DE":{s:"Deutsch (Deutschland)",u:"German (Germany)"},"de-CH":{s:"Deutsch (Schweiz)",u:"German (Switzerland)"},dsb:{s:"Dolnoserb\u0161\u0107ina",u:"Lower Sorbian"},el:{s:"\u0395\u03bb\u03bb\u03b7\u03bd\u03b9\u03ba\u03ac",u:"Greek"},"el-GR":{s:"\u0395\u03bb\u03bb\u03b7\u03bd\u03b9\u03ba\u03ac",
@@ -945,55 +947,55 @@ u:"Slovak"},"sk-SK":{s:"Sloven\u010dina (Slovakia)",u:"Slovak (Slovakia)"},sl:{s
945
947
  sw:{s:"Kiswahili",u:"Swahili"},"sw-KE":{s:"Kiswahili",u:"Swahili (Kenya)"},ta:{s:"\u0ba4\u0bae\u0bbf\u0bb4\u0bcd",u:"Tamil"},"ta-IN":{s:"\u0ba4\u0bae\u0bbf\u0bb4\u0bcd",u:"Tamil"},te:{s:"\u0c24\u0c46\u0c32\u0c41\u0c17\u0c41",u:"Telugu"},"te-IN":{s:"\u0c24\u0c46\u0c32\u0c41\u0c17\u0c41",u:"Telugu"},tg:{s:"\u0437\u0430\u0431\u043e\u0301\u043d\u0438 \u0442\u043e\u04b7\u0438\u043a\u04e3\u0301",u:"Tajik"},"tg-TJ":{s:"\u0442\u043e\u04b7\u0438\u043a\u04e3",u:"Tajik"},th:{s:"\u0e20\u0e32\u0e29\u0e32\u0e44\u0e17\u0e22",
946
948
  u:"Thai"},"th-TH":{s:"\u0e20\u0e32\u0e29\u0e32\u0e44\u0e17\u0e22 (\u0e1b\u0e23\u0e30\u0e40\u0e17\u0e28\u0e44\u0e17\u0e22)",u:"Thai (Thailand)"},tl:{s:"Filipino",u:"Filipino"},"tl-PH":{s:"Filipino",u:"Filipino"},tlh:{s:"tlhIngan-Hol",u:"Klingon"},tr:{s:"T\u00fcrk\u00e7e",u:"Turkish"},"tr-TR":{s:"T\u00fcrk\u00e7e",u:"Turkish"},"tt-RU":{s:"\u0442\u0430\u0442\u0430\u0440\u0447\u0430",u:"Tatar"},uk:{s:"\u0423\u043a\u0440\u0430\u0457\u043d\u0441\u044c\u043a\u0430",u:"Ukrainian"},"uk-UA":{s:"\u0423\u043a\u0440\u0430\u0457\u043d\u0441\u044c\u043a\u0430",
947
949
  u:"Ukrainian"},ur:{s:"\u0627\u0631\u062f\u0648",u:"Urdu"},"ur-PK":{s:"\u0627\u0631\u062f\u0648",u:"Urdu"},uz:{s:"O'zbek",u:"Uzbek"},"uz-UZ":{s:"O'zbek",u:"Uzbek"},vi:{s:"Ti\u1ebfng Vi\u1ec7t",u:"Vietnamese"},"vi-VN":{s:"Ti\u1ebfng Vi\u1ec7t",u:"Vietnamese"},"xh-ZA":{s:"isiXhosa",u:"Xhosa"},yi:{s:"\u05d9\u05d9\u05b4\u05d3\u05d9\u05e9",u:"Yiddish"},"yi-DE":{s:"\u05d9\u05d9\u05b4\u05d3\u05d9\u05e9 (German)",u:"Yiddish (German)"},zh:{s:"\u4e2d\u6587",u:"Chinese"},"zh-HANS":{s:"\u4e2d\u6587\u7b80\u4f53",
948
- u:"Chinese Simplified"},"zh-HANT":{s:"\u4e2d\u6587\u7e41\u9ad4",u:"Chinese Traditional"},"zh-CN":{s:"\u4e2d\u6587\uff08\u4e2d\u56fd\uff09",u:"Chinese Simplified (China)"},"zh-HK":{s:"\u4e2d\u6587\uff08\u9999\u6e2f\uff09",u:"Chinese Traditional (Hong Kong)"},"zh-SG":{s:"\u4e2d\u6587\uff08\u65b0\u52a0\u5761\uff09",u:"Chinese Simplified (Singapore)"},"zh-TW":{s:"\u4e2d\u6587\uff08\u53f0\u7063\uff09",u:"Chinese Traditional (Taiwan)"},"zu-ZA":{s:"isiZulu",u:"Zulu"}},cw=t(Object.keys(bw)),dw=cw.next();!dw.done;dw=
949
- cw.next()){var ew=dw.value;bw[ew.toLowerCase()]=bw[ew]};function W(a,b){var c=this;this.parent=a;this.controls=b;this.eventManager=new tf;this.localization=this.controls.za;this.player=this.controls.bc();this.video=this.controls.Bb();this.adManager=this.player.hd();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})}
950
- W.prototype.release=function(){this.eventManager.release();this.ad=this.adManager=this.video=this.player=this.localization=this.eventManager=this.controls=this.parent=null};J("shaka.ui.Element",W);W.prototype.release=W.prototype.release;function fw(a){return gw(a,"shaka-back-to-overflow-button")}function gw(a,b){var c=a.getElementsByClassName(b);return c.length?c[0]:null}function hw(a){a&&(a=gw(a,"shaka-chosen-item"))&&a.parentElement.focus()}function iw(){var a=R("i");a.classList.add("material-icons-round");a.classList.add("shaka-chosen-item");a.textContent="done";a.ariaHidden="true";return a}function X(a,b){a&&(b?a.classList.remove("shaka-hidden"):a.classList.add("shaka-hidden"))}
951
- function jw(a,b){var c=Math.floor(a/3600),d=Math.floor(a/60%60),e=Math.floor(a%60);10>e&&(e="0"+e);e=d+":"+e;b&&(10>d&&(e="0"+e),e=c+":"+e);return e};function kw(a,b){W.call(this,a,b);var c=this;this.i=R("div");this.i.classList.add("shaka-ad-counter");this.parent.appendChild(this.i);this.h=R("span");this.h.classList.add("shaka-ad-counter-span");this.i.appendChild(this.h);this.g=new P(function(){var d=Math.round(c.ad.getRemainingTime()),e=c.ad.getDuration();-1!=d&&-1!=e&&(0<d?(d=jw(e-d,!1)+" / "+jw(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=
952
- ""))});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.xa();c.g.ka(.5)});this.eventManager.o(this.adManager,"ad-stopped",function(){c.g.stop();c.h.textContent=""});this.ad&&(this.g.xa(),this.g.ka(.5))}qa(kw,W);kw.prototype.release=function(){this.g.stop();this.g=null;W.prototype.release.call(this)};J("shaka.ui.AdCounter",kw);function lw(a,b){W.call(this,a,b);var c=this;this.g=R("div");this.g.classList.add("shaka-ad-position");X(this.g,!1);this.parent.appendChild(this.g);this.h=R("span");this.h.classList.add("shaka-ad-position-span");this.g.appendChild(this.h);this.eventManager.o(this.localization,"locale-updated",function(){c.ad&&mw(c)});this.eventManager.o(this.localization,"locale-changed",function(){c.ad&&mw(c)});this.eventManager.o(this.adManager,"ad-started",function(){mw(c)});this.eventManager.o(this.adManager,
953
- "ad-stopped",function(){c.h.textContent="";X(c.g,!1)});this.ad&&mw(this)}qa(lw,W);function mw(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));X(a.g,!0)}}J("shaka.ui.AdPosition",lw);function nw(a,b){W.call(this,a,b);var c=this;this.button=ck();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();
954
- 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.button,"click",function(){c.ad&&c.ad.isLinear()?ow(c.controls):pw(c.controls)});this.ad&&(this.g(),this.h())}qa(nw,W);nw.prototype.isPaused=function(){if(this.ad&&this.ad.isLinear())var a=this.ad.isPaused();else a=this.controls,a=a.B.paused&&!a.$;return a};nw.prototype.g=function(){};nw.prototype.h=function(){};
955
- J("shaka.ui.PlayButton",nw);function qw(a,b){nw.call(this,a,b);this.button.classList.add("shaka-play-button");this.button.classList.add("shaka-no-propagation");this.h();this.g()}qa(qw,nw);qw.prototype.h=function(){this.isPaused()?this.button.setAttribute("icon","play"):this.button.setAttribute("icon","pause")};qw.prototype.g=function(){var a=this.isPaused()?"PLAY":"PAUSE";this.button.ariaLabel=this.localization.resolve(a)};J("shaka.ui.BigPlayButton",qw);function rw(a,b){W.call(this,a,b);var c=this;this.j=this.controls.i;this.h=this.controls.g;this.i=[];this.g=R("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";X(c.g,!0)}else X(c.g,
956
- !1)});this.eventManager.o(window,"click",function(){X(c.g,!1)});sw(this)}qa(rw,W);rw.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=[];W.prototype.release.call(this)};function tw(a,b){uw.set(a,b)}function sw(a){for(var b=t(a.j.contextMenuElements),c=b.next();!c.done;c=b.next()){c=c.value;var d=uw.get(c);d?a.i.push(d.create(a.g,a.controls)):Ua("Unrecognized context menu element:",c)}}J("shaka.ui.ContextMenu",rw);
957
- rw.registerElement=tw;var uw=new Map;function vw(a,b,c,d){W.call(this,a,b);var e=this;this.container=R("div");this.container.classList.add("shaka-range-container");this.container.classList.add.apply(this.container.classList,ia(c));this.g=!1;this.bar=document.createElement("input");this.l=new P(function(){e.onChangeEnd();e.g=!1});this.bar.classList.add("shaka-range-element");this.bar.classList.add.apply(this.bar.classList,ia(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);
958
- this.parent.appendChild(this.container);this.eventManager.o(this.bar,"mousedown",function(){e.controls.Mb()&&(e.g=!0,e.onChangeStart())});this.eventManager.o(this.bar,"touchstart",function(f){e.controls.Mb()&&(e.g=!0,ww(e,f),e.onChangeStart())});this.eventManager.o(this.bar,"input",function(){e.onChange()});this.eventManager.o(this.bar,"touchmove",function(f){e.g&&(ww(e,f),e.onChange())});this.eventManager.o(this.bar,"touchend",function(f){e.g&&(e.g=!1,ww(e,f),e.onChangeEnd())});this.eventManager.o(this.bar,
959
- "mouseup",function(){e.g&&(e.g=!1,e.onChangeEnd())})}qa(vw,W);q=vw.prototype;q.release=function(){this.l&&(this.l.stop(),this.l=null);W.prototype.release.call(this)};q.setRange=function(a,b){this.bar.min=a;this.bar.max=b};q.onChangeStart=function(){};q.onChange=function(){};q.onChangeEnd=function(){};q.changeTo=function(a){this.g||(this.g=!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.l.T(.5)};q.getValue=function(){return parseFloat(this.bar.value)};
960
- q.setValue=function(a){this.g||(this.bar.value=a)};function ww(a,b){b.preventDefault();var c=b.changedTouches[0],d=a.bar.getBoundingClientRect(),e=parseFloat(a.bar.min),f=parseFloat(a.bar.max);c=e+(f-e)/d.width*(c.clientX-d.left);c<e?c=e:c>f&&(c=f);a.bar.value=c}J("shaka.ui.RangeElement",vw);vw.prototype.setValue=vw.prototype.setValue;vw.prototype.getValue=vw.prototype.getValue;vw.prototype.changeTo=vw.prototype.changeTo;vw.prototype.onChangeEnd=vw.prototype.onChangeEnd;vw.prototype.onChange=vw.prototype.onChange;
961
- vw.prototype.onChangeStart=vw.prototype.onChangeStart;vw.prototype.setRange=vw.prototype.setRange;function xw(a,b){vw.call(this,a,b,["shaka-seek-bar-container"],["shaka-seek-bar","shaka-no-propagation","shaka-show-controls-on-mouse-over"]);var c=this;this.j=R("div");this.j.classList.add("shaka-ad-markers");this.container.insertBefore(this.j,this.container.childNodes[0]);this.m=this.controls.i;this.h=new P(function(){c.video.currentTime=c.getValue()});this.A=new P(function(){yw(c)});this.B=!1;this.i=[];this.eventManager.o(this.localization,"locale-updated",function(){return zw(c)});this.eventManager.o(this.localization,
962
- "locale-changed",function(){return zw(c)});this.eventManager.o(this.adManager,"ad-started",function(){Aw(c)||X(c.container,!1)});this.eventManager.o(this.adManager,"ad-stopped",function(){Aw(c)&&X(c.container,!0)});this.eventManager.o(this.adManager,"ad-cue-points-changed",function(d){c.i=d.cuepoints;Bw(c)});this.eventManager.o(this.player,"unloading",function(){c.i=[];Bw(c)});this.setValue(this.video.currentTime);this.update();zw(this);this.ad&&X(this.container,!1)}qa(xw,vw);q=xw.prototype;
963
- q.release=function(){this.h&&(this.h.stop(),this.h=null,this.A.stop(),this.A=null);vw.prototype.release.call(this)};q.onChangeStart=function(){this.B=!this.video.paused;this.controls.Fe(!0);this.video.pause()};q.onChange=function(){this.video.duration&&(this.update(),this.h.T(.125))};q.onChangeEnd=function(){this.h.xa();this.controls.Fe(!1);this.B&&this.video.play()};q.isShowing=function(){return!this.container.classList.contains("shaka-hidden")};
964
- q.update=function(){var a=this.m.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.Ia(),g=f.end-f.start;this.setRange(f.start,f.end);Aw(this)?(X(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.m.showUnbufferedStart?
950
+ u:"Chinese Simplified"},"zh-HANT":{s:"\u4e2d\u6587\u7e41\u9ad4",u:"Chinese Traditional"},"zh-CN":{s:"\u4e2d\u6587\uff08\u4e2d\u56fd\uff09",u:"Chinese Simplified (China)"},"zh-HK":{s:"\u4e2d\u6587\uff08\u9999\u6e2f\uff09",u:"Chinese Traditional (Hong Kong)"},"zh-SG":{s:"\u4e2d\u6587\uff08\u65b0\u52a0\u5761\uff09",u:"Chinese Simplified (Singapore)"},"zh-TW":{s:"\u4e2d\u6587\uff08\u53f0\u7063\uff09",u:"Chinese Traditional (Taiwan)"},"zu-ZA":{s:"isiZulu",u:"Zulu"}},fw=t(Object.keys(ew)),gw=fw.next();!gw.done;gw=
951
+ fw.next()){var hw=gw.value;ew[hw.toLowerCase()]=ew[hw]};function W(a,b){var c=this;this.parent=a;this.controls=b;this.eventManager=new wf;this.localization=this.controls.za;this.player=this.controls.bc();this.video=this.controls.Bb();this.adManager=this.player.hd();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})}
952
+ W.prototype.release=function(){this.eventManager.release();this.ad=this.adManager=this.video=this.player=this.localization=this.eventManager=this.controls=this.parent=null};J("shaka.ui.Element",W);W.prototype.release=W.prototype.release;function iw(a){return jw(a,"shaka-back-to-overflow-button")}function jw(a,b){var c=a.getElementsByClassName(b);return c.length?c[0]:null}function kw(a){a&&(a=jw(a,"shaka-chosen-item"))&&a.parentElement.focus()}function lw(){var a=R("i");a.classList.add("material-icons-round");a.classList.add("shaka-chosen-item");a.textContent="done";a.ariaHidden="true";return a}function X(a,b){a&&(b?a.classList.remove("shaka-hidden"):a.classList.add("shaka-hidden"))}
953
+ function mw(a,b){var c=Math.floor(a/3600),d=Math.floor(a/60%60),e=Math.floor(a%60);10>e&&(e="0"+e);e=d+":"+e;b&&(10>d&&(e="0"+e),e=c+":"+e);return e};function nw(a,b){W.call(this,a,b);var c=this;this.i=R("div");this.i.classList.add("shaka-ad-counter");this.parent.appendChild(this.i);this.h=R("span");this.h.classList.add("shaka-ad-counter-span");this.i.appendChild(this.h);this.g=new P(function(){var d=Math.round(c.ad.getRemainingTime()),e=c.ad.getDuration();-1!=d&&-1!=e&&(0<d?(d=mw(e-d,!1)+" / "+mw(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=
954
+ ""))});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.xa();c.g.ka(.5)});this.eventManager.o(this.adManager,"ad-stopped",function(){c.g.stop();c.h.textContent=""});this.ad&&(this.g.xa(),this.g.ka(.5))}qa(nw,W);nw.prototype.release=function(){this.g.stop();this.g=null;W.prototype.release.call(this)};J("shaka.ui.AdCounter",nw);function ow(a,b){W.call(this,a,b);var c=this;this.g=R("div");this.g.classList.add("shaka-ad-position");X(this.g,!1);this.parent.appendChild(this.g);this.h=R("span");this.h.classList.add("shaka-ad-position-span");this.g.appendChild(this.h);this.eventManager.o(this.localization,"locale-updated",function(){c.ad&&pw(c)});this.eventManager.o(this.localization,"locale-changed",function(){c.ad&&pw(c)});this.eventManager.o(this.adManager,"ad-started",function(){pw(c)});this.eventManager.o(this.adManager,
955
+ "ad-stopped",function(){c.h.textContent="";X(c.g,!1)});this.ad&&pw(this)}qa(ow,W);function pw(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));X(a.g,!0)}}J("shaka.ui.AdPosition",ow);function qw(a,b){W.call(this,a,b);var c=this;this.button=fk();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();
956
+ 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.button,"click",function(){c.ad&&c.ad.isLinear()?rw(c.controls):sw(c.controls)});this.ad&&(this.g(),this.h())}qa(qw,W);qw.prototype.isPaused=function(){if(this.ad&&this.ad.isLinear())var a=this.ad.isPaused();else a=this.controls,a=a.B.paused&&!a.$;return a};qw.prototype.g=function(){};qw.prototype.h=function(){};
957
+ J("shaka.ui.PlayButton",qw);function tw(a,b){qw.call(this,a,b);this.button.classList.add("shaka-play-button");this.button.classList.add("shaka-no-propagation");this.h();this.g()}qa(tw,qw);tw.prototype.h=function(){this.isPaused()?this.button.setAttribute("icon","play"):this.button.setAttribute("icon","pause")};tw.prototype.g=function(){var a=this.isPaused()?"PLAY":"PAUSE";this.button.ariaLabel=this.localization.resolve(a)};J("shaka.ui.BigPlayButton",tw);function uw(a,b){W.call(this,a,b);var c=this;this.j=this.controls.i;this.h=this.controls.g;this.i=[];this.g=R("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";X(c.g,!0)}else X(c.g,
958
+ !1)});this.eventManager.o(window,"click",function(){X(c.g,!1)});vw(this)}qa(uw,W);uw.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=[];W.prototype.release.call(this)};function ww(a,b){xw.set(a,b)}function vw(a){for(var b=t(a.j.contextMenuElements),c=b.next();!c.done;c=b.next()){c=c.value;var d=xw.get(c);d?a.i.push(d.create(a.g,a.controls)):Ua("Unrecognized context menu element:",c)}}J("shaka.ui.ContextMenu",uw);
959
+ uw.registerElement=ww;var xw=new Map;function yw(a,b,c,d){W.call(this,a,b);var e=this;this.container=R("div");this.container.classList.add("shaka-range-container");this.container.classList.add.apply(this.container.classList,ia(c));this.g=!1;this.bar=document.createElement("input");this.l=new P(function(){e.onChangeEnd();e.g=!1});this.bar.classList.add("shaka-range-element");this.bar.classList.add.apply(this.bar.classList,ia(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);
960
+ this.parent.appendChild(this.container);this.eventManager.o(this.bar,"mousedown",function(){e.controls.Mb()&&(e.g=!0,e.onChangeStart())});this.eventManager.o(this.bar,"touchstart",function(f){e.controls.Mb()&&(e.g=!0,zw(e,f),e.onChangeStart())});this.eventManager.o(this.bar,"input",function(){e.onChange()});this.eventManager.o(this.bar,"touchmove",function(f){e.g&&(zw(e,f),e.onChange())});this.eventManager.o(this.bar,"touchend",function(f){e.g&&(e.g=!1,zw(e,f),e.onChangeEnd())});this.eventManager.o(this.bar,
961
+ "mouseup",function(){e.g&&(e.g=!1,e.onChangeEnd())})}qa(yw,W);q=yw.prototype;q.release=function(){this.l&&(this.l.stop(),this.l=null);W.prototype.release.call(this)};q.setRange=function(a,b){this.bar.min=a;this.bar.max=b};q.onChangeStart=function(){};q.onChange=function(){};q.onChangeEnd=function(){};q.changeTo=function(a){this.g||(this.g=!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.l.T(.5)};q.getValue=function(){return parseFloat(this.bar.value)};
962
+ q.setValue=function(a){this.g||(this.bar.value=a)};function zw(a,b){b.preventDefault();var c=b.changedTouches[0],d=a.bar.getBoundingClientRect(),e=parseFloat(a.bar.min),f=parseFloat(a.bar.max);c=e+(f-e)/d.width*(c.clientX-d.left);c<e?c=e:c>f&&(c=f);a.bar.value=c}J("shaka.ui.RangeElement",yw);yw.prototype.setValue=yw.prototype.setValue;yw.prototype.getValue=yw.prototype.getValue;yw.prototype.changeTo=yw.prototype.changeTo;yw.prototype.onChangeEnd=yw.prototype.onChangeEnd;yw.prototype.onChange=yw.prototype.onChange;
963
+ yw.prototype.onChangeStart=yw.prototype.onChangeStart;yw.prototype.setRange=yw.prototype.setRange;function Aw(a,b){yw.call(this,a,b,["shaka-seek-bar-container"],["shaka-seek-bar","shaka-no-propagation","shaka-show-controls-on-mouse-over"]);var c=this;this.j=R("div");this.j.classList.add("shaka-ad-markers");this.container.insertBefore(this.j,this.container.childNodes[0]);this.m=this.controls.i;this.h=new P(function(){c.video.currentTime=c.getValue()});this.A=new P(function(){Bw(c)});this.B=!1;this.i=[];this.eventManager.o(this.localization,"locale-updated",function(){return Cw(c)});this.eventManager.o(this.localization,
964
+ "locale-changed",function(){return Cw(c)});this.eventManager.o(this.adManager,"ad-started",function(){Dw(c)||X(c.container,!1)});this.eventManager.o(this.adManager,"ad-stopped",function(){Dw(c)&&X(c.container,!0)});this.eventManager.o(this.adManager,"ad-cue-points-changed",function(d){c.i=d.cuepoints;Ew(c)});this.eventManager.o(this.player,"unloading",function(){c.i=[];Ew(c)});this.setValue(this.video.currentTime);this.update();Cw(this);this.ad&&X(this.container,!1)}qa(Aw,yw);q=Aw.prototype;
965
+ q.release=function(){this.h&&(this.h.stop(),this.h=null,this.A.stop(),this.A=null);yw.prototype.release.call(this)};q.onChangeStart=function(){this.B=!this.video.paused;this.controls.Ge(!0);this.video.pause()};q.onChange=function(){this.video.duration&&(this.update(),this.h.T(.125))};q.onChangeEnd=function(){this.h.xa();this.controls.Ge(!1);this.B&&this.video.play()};q.isShowing=function(){return!this.container.classList.contains("shaka-hidden")};
966
+ q.update=function(){var a=this.m.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.Ia(),g=f.end-f.start;this.setRange(f.start,f.end);Dw(this)?(X(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.m.showUnbufferedStart?
965
967
  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()+")")):X(this.container,!1)};
966
- function yw(a){if(a.i.length){for(var b=a.player.Ia(),c=b.end-b.start,d=["to right"],e=[],f=a.m.seekBarColors.adBreaks,g=!1,h=t(a.i),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 "+
967
- 100*c.end+"%");g&&(d.push("transparent 99%"),d.push(f+" 99%"));a.j.style.background="linear-gradient("+d.join(",")+")"}else a.j.style.background="transparent"}function Bw(a){yw(a);var b=a.player.Ia();b=b.end-b.start;a.player.U()&&5<b&&a.A.ka(1)}function Aw(a){var b=a.player.Ia();b=b.end-b.start;return a.player.U()&&5>b?!1:null==a.ad||!a.ad.isLinear()}function zw(a){a.bar.ariaLabel=a.localization.resolve("SEEK")}J("shaka.ui.SeekBar",xw);function Cw(){}
968
- Cw.prototype.create=function(a,b){return new xw(a,b)};xw.Factory=Cw;function Y(a,b,c,d){fb.call(this);var e=this;this.S=!0;this.i=d;this.C=new hn(c,a,this.i.castReceiverAppId,this.i.castAndroidReceiverCompatible);this.gb=!0;this.B=this.C.Bb();this.A=c;this.F=this.C.bc();this.ya=a;this.j=b;this.Xa=this.F.hd();this.m=this.l=null;this.$=!1;this.G=[];this.wb=[];this.ib=!1;this.aa=new P(function(){e.j.style.cursor="none";e.ib=!1;Dw(e)});this.ea=new P(function(){e.g.removeAttribute("shown");e.I.T(2)});this.I=new P(function(){for(var f=t(e.G),g=f.next();!g.done;g=f.next())X(g.value,
969
- !1)});this.La=new P(function(){e.Mb()&&Ew(e)});this.J=null;this.H=[];this.za=Fw();this.h=new tf;this.configure(this.i);Gw(this);this.ma=new Set;Hw(this);this.La.ka(.125);this.h.o(this.za,"locale-changed",function(f){e.Xa.setLocale(f.locales[0])})}qa(Y,fb);q=Y.prototype;
970
- q.destroy=function(){var a=this;return I(function(b){switch(b.g){case 1:if(document.pictureInPictureElement!=a.A){b.D(2);break}return u(b,document.exitPictureInPicture(),2);case 2:a.h&&(a.h.release(),a.h=null);a.aa&&(a.aa.stop(),a.aa=null);a.ea&&(a.ea.stop(),a.ea=null);a.I&&(a.I.stop(),a.I=null);a.La&&(a.La.stop(),a.La=null);Iw(a);a.g&&(a.j.removeChild(a.g),a.g=null);if(!a.C){b.D(4);break}return u(b,a.C.destroy(),5);case 5:a.C=null;case 4:if(!a.ya){b.D(6);break}return u(b,a.ya.destroy(),7);case 7:a.ya=
971
- null;case 6:a.F=null,a.A=null,a.B=null,a.za=null,a.ma.clear(),fb.prototype.release.call(a),z(b)}})};function Iw(a){for(var b=t(a.H),c=b.next();!c.done;c=b.next())c.value.release();a.H=[]}function Jw(a,b){Kw.set(a,b)}q.Vf=function(a){this.gb=a;Hw(this)};q.Ng=function(){Dw(this)};
972
- q.configure=function(a){this.i=a;this.C.cf(a.castReceiverAppId,a.castAndroidReceiverCompatible);this.m&&(this.m=null);this.fb&&(this.fb=null);this.Ya&&(this.Ya=null);this.g?(dk(this.g),Iw(this)):(Lw(this),Mw(this));this.j.classList.add("shaka-video-container");this.A.classList.add("shaka-video");Nw(this);this.i.addBigPlayButton&&Ow(this);this.i.customContextMenu&&(this.Ya=new rw(this.X,this),this.H.push(this.Ya));this.ba||Pw(this);this.hb=R("div");this.hb.classList.add("shaka-server-side-ad-container");
973
- this.g.appendChild(this.hb);Qw(this);this.G=Array.from(this.j.getElementsByClassName("shaka-settings-menu"));this.G.push.apply(this.G,ia(Array.from(this.j.getElementsByClassName("shaka-overflow-menu"))));Rw(this);this.wb=Array.from(this.j.getElementsByClassName("shaka-show-controls-on-mouse-over"));Dw(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.h.o(b,"click",c);this.h.o(b,"dblclick",
974
- c)}};q.Be=function(a){(this.S=a)?(this.j.setAttribute("shaka-controls","true"),this.A.tabIndex=-1,this.A.controls=!1):this.j.removeAttribute("shaka-controls");Dw(this)};q.Gf=function(a){this.A.controls=a;this.A.tabIndex=a?0:-1;a&&this.Be(!1)};q.getAd=function(){return this.l};q.gg=function(){return this.C};q.sg=function(){return this.za};q.Hg=function(){return this.j};q.Bb=function(){return this.B};q.rg=function(){return this.A};q.bc=function(){return this.F};q.qg=function(){return this.ya};
975
- q.lg=function(){return this.g};q.Bg=function(){return this.hb};q.ig=function(){return this.P};q.jg=function(){return this.i};q.Mg=function(){return this.$};q.Fe=function(a){this.$=a};q.Kg=function(){return this.gb};q.pf=function(){return this.m?this.m.getValue():this.B.currentTime};q.Hf=function(a){this.J=a};q.cd=function(){return this.G.some(function(a){return!a.classList.contains("shaka-hidden")})};q.dc=function(){this.I.xa()};
968
+ function Bw(a){if(a.i.length){for(var b=a.player.Ia(),c=b.end-b.start,d=["to right"],e=[],f=a.m.seekBarColors.adBreaks,g=!1,h=t(a.i),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 "+
969
+ 100*c.end+"%");g&&(d.push("transparent 99%"),d.push(f+" 99%"));a.j.style.background="linear-gradient("+d.join(",")+")"}else a.j.style.background="transparent"}function Ew(a){Bw(a);var b=a.player.Ia();b=b.end-b.start;a.player.U()&&5<b&&a.A.ka(1)}function Dw(a){var b=a.player.Ia();b=b.end-b.start;return a.player.U()&&5>b?!1:null==a.ad||!a.ad.isLinear()}function Cw(a){a.bar.ariaLabel=a.localization.resolve("SEEK")}J("shaka.ui.SeekBar",Aw);function Fw(){}
970
+ Fw.prototype.create=function(a,b){return new Aw(a,b)};Aw.Factory=Fw;function Y(a,b,c,d){fb.call(this);var e=this;this.S=!0;this.i=d;this.C=new ln(c,a,this.i.castReceiverAppId,this.i.castAndroidReceiverCompatible);this.gb=!0;this.B=this.C.Bb();this.A=c;this.F=this.C.bc();this.ya=a;this.j=b;this.Xa=this.F.hd();this.m=this.l=null;this.$=!1;this.G=[];this.wb=[];this.ib=!1;this.aa=new P(function(){e.j.style.cursor="none";e.ib=!1;Gw(e)});this.ea=new P(function(){e.g.removeAttribute("shown");e.I.T(2)});this.I=new P(function(){for(var f=t(e.G),g=f.next();!g.done;g=f.next())X(g.value,
971
+ !1)});this.La=new P(function(){e.Mb()&&Hw(e)});this.J=null;this.H=[];this.za=Iw();this.h=new wf;this.configure(this.i);Jw(this);this.ma=new Set;Kw(this);this.La.ka(.125);this.h.o(this.za,"locale-changed",function(f){e.Xa.setLocale(f.locales[0])})}qa(Y,fb);q=Y.prototype;
972
+ q.destroy=function(){var a=this;return I(function(b){switch(b.g){case 1:if(document.pictureInPictureElement!=a.A){b.D(2);break}return u(b,document.exitPictureInPicture(),2);case 2:a.h&&(a.h.release(),a.h=null);a.aa&&(a.aa.stop(),a.aa=null);a.ea&&(a.ea.stop(),a.ea=null);a.I&&(a.I.stop(),a.I=null);a.La&&(a.La.stop(),a.La=null);Lw(a);a.g&&(a.j.removeChild(a.g),a.g=null);if(!a.C){b.D(4);break}return u(b,a.C.destroy(),5);case 5:a.C=null;case 4:if(!a.ya){b.D(6);break}return u(b,a.ya.destroy(),7);case 7:a.ya=
973
+ null;case 6:a.F=null,a.A=null,a.B=null,a.za=null,a.ma.clear(),fb.prototype.release.call(a),z(b)}})};function Lw(a){for(var b=t(a.H),c=b.next();!c.done;c=b.next())c.value.release();a.H=[]}function Mw(a,b){Nw.set(a,b)}q.Wf=function(a){this.gb=a;Kw(this)};q.Og=function(){Gw(this)};
974
+ q.configure=function(a){this.i=a;this.C.df(a.castReceiverAppId,a.castAndroidReceiverCompatible);this.m&&(this.m=null);this.fb&&(this.fb=null);this.Ya&&(this.Ya=null);this.g?(gk(this.g),Lw(this)):(Ow(this),Pw(this));this.j.classList.add("shaka-video-container");this.A.classList.add("shaka-video");Qw(this);this.i.addBigPlayButton&&Rw(this);this.i.customContextMenu&&(this.Ya=new uw(this.X,this),this.H.push(this.Ya));this.ba||Sw(this);this.hb=R("div");this.hb.classList.add("shaka-server-side-ad-container");
975
+ this.g.appendChild(this.hb);Tw(this);this.G=Array.from(this.j.getElementsByClassName("shaka-settings-menu"));this.G.push.apply(this.G,ia(Array.from(this.j.getElementsByClassName("shaka-overflow-menu"))));Uw(this);this.wb=Array.from(this.j.getElementsByClassName("shaka-show-controls-on-mouse-over"));Gw(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.h.o(b,"click",c);this.h.o(b,"dblclick",
976
+ c)}};q.Ce=function(a){(this.S=a)?(this.j.setAttribute("shaka-controls","true"),this.A.tabIndex=-1,this.A.controls=!1):this.j.removeAttribute("shaka-controls");Gw(this)};q.Hf=function(a){this.A.controls=a;this.A.tabIndex=a?0:-1;a&&this.Ce(!1)};q.getAd=function(){return this.l};q.hg=function(){return this.C};q.ug=function(){return this.za};q.Ig=function(){return this.j};q.Bb=function(){return this.B};q.sg=function(){return this.A};q.bc=function(){return this.F};q.rg=function(){return this.ya};
977
+ q.mg=function(){return this.g};q.Cg=function(){return this.hb};q.jg=function(){return this.P};q.kg=function(){return this.i};q.Ng=function(){return this.$};q.Ge=function(a){this.$=a};q.Lg=function(){return this.gb};q.qf=function(){return this.m?this.m.getValue():this.B.currentTime};q.If=function(a){this.J=a};q.cd=function(){return this.G.some(function(a){return!a.classList.contains("shaka-hidden")})};q.dc=function(){this.I.xa()};
976
978
  q.ae=function(){return document.fullscreenEnabled||this.A.webkitSupportsFullscreen?!0:!1};q.$d=function(){if(document.fullscreenEnabled)return!!document.fullscreenElement;var a=this.A;return a.webkitSupportsFullscreen?a.webkitDisplayingFullscreen:!1};
977
- q.Le=function(){var a=this,b,c;return I(function(d){switch(d.g){case 1:if(!document.fullscreenEnabled){b=a.A;b.webkitSupportsFullscreen&&(b.webkitDisplayingFullscreen?b.webkitExitFullscreen():b.webkitEnterFullscreen());d.D(0);break}if(document.fullscreenElement)return screen.orientation&&screen.orientation.unlock(),u(d,document.exitFullscreen(),0);A(d,5);if(!document.pictureInPictureElement){d.D(7);break}return u(d,document.exitPictureInPicture(),7);case 7:return u(d,a.j.requestFullscreen({navigationUI:"hide"}),
978
- 9);case 9:if(!a.i.forceLandscapeOnFullscreen||!screen.orientation){d.D(10);break}A(d,11);return u(d,screen.orientation.lock("landscape"),13);case 13:va(d,10,5);break;case 11:F(d,5);case 10:va(d,0);break;case 5:c=F(d),a.dispatchEvent(new M("error",(new Map).set("detail",c))),d.D(0)}})};q.Jf=function(){X(this.K,!0);X(this.P,!0);this.g.setAttribute("ad-active","true")};q.tf=function(){X(this.K,!1);X(this.P,!1);this.g.removeAttribute("ad-active")};
979
- function pw(a){a.S&&a.B.duration&&(a.F.Ze(),a.B.paused&&!a.$?a.B.play():a.B.pause())}function ow(a){a.l&&a.l.isPaused()?a.l.play():a.l&&a.l.pause()}
980
- function Lw(a){a.g=R("div");a.g.classList.add("shaka-controls-container");a.j.appendChild(a.g);a.j.setAttribute("shaka-controls","true");a.h.o(a.g,"touchstart",function(b){a.B.duration&&(a.Mb()?a.J=Date.now():(Sw(a,b),b.preventDefault()))},{passive:!1});a.h.o(a.g,"click",function(){Tw(a)});a.h.o(a.g,"dblclick",function(){a.i.doubleClickForFullscreen&&a.ae()&&a.Le()})}function Ow(a){var b=R("div");b.classList.add("shaka-play-button-container");a.g.appendChild(b);a.fb=new qw(b,a);a.H.push(a.fb)}
981
- function Nw(a){var b=R("div");b.classList.add("shaka-scrim-container");a.g.appendChild(b)}function Uw(a){a.K=R("div");a.K.classList.add("shaka-ad-controls");var b=null!=a.l&&a.l.isLinear();X(a.K,b);a.N.appendChild(a.K);b=new lw(a.K,a);a.H.push(b);b=new kw(a.K,a);a.H.push(b)}
982
- function Pw(a){a.ba=R("div");a.ba.classList.add("shaka-spinner-container");a.j.appendChild(a.ba);var b=R("div");b.classList.add("shaka-spinner");a.ba.appendChild(b);a=document.createElementNS("http://www.w3.org/2000/svg","svg");a.classList.add("shaka-spinner-svg");a.setAttribute("viewBox","0 0 30 30");b.appendChild(a);b=document.createElementNS("http://www.w3.org/2000/svg","circle");b.classList.add("shaka-spinner-path");b.setAttribute("cx","15");b.setAttribute("cy","15");b.setAttribute("r","14.5");
979
+ q.Me=function(){var a=this,b,c;return I(function(d){switch(d.g){case 1:if(!document.fullscreenEnabled){b=a.A;b.webkitSupportsFullscreen&&(b.webkitDisplayingFullscreen?b.webkitExitFullscreen():b.webkitEnterFullscreen());d.D(0);break}if(document.fullscreenElement)return screen.orientation&&screen.orientation.unlock(),u(d,document.exitFullscreen(),0);A(d,5);if(!document.pictureInPictureElement){d.D(7);break}return u(d,document.exitPictureInPicture(),7);case 7:return u(d,a.j.requestFullscreen({navigationUI:"hide"}),
980
+ 9);case 9:if(!a.i.forceLandscapeOnFullscreen||!screen.orientation){d.D(10);break}A(d,11);return u(d,screen.orientation.lock("landscape"),13);case 13:va(d,10,5);break;case 11:F(d,5);case 10:va(d,0);break;case 5:c=F(d),a.dispatchEvent(new L("error",(new Map).set("detail",c))),d.D(0)}})};q.Kf=function(){X(this.K,!0);X(this.P,!0);this.g.setAttribute("ad-active","true")};q.uf=function(){X(this.K,!1);X(this.P,!1);this.g.removeAttribute("ad-active")};
981
+ function sw(a){a.S&&a.B.duration&&(a.F.$e(),a.B.paused&&!a.$?a.B.play():a.B.pause())}function rw(a){a.l&&a.l.isPaused()?a.l.play():a.l&&a.l.pause()}
982
+ function Ow(a){a.g=R("div");a.g.classList.add("shaka-controls-container");a.j.appendChild(a.g);a.j.setAttribute("shaka-controls","true");a.h.o(a.g,"touchstart",function(b){a.B.duration&&(a.Mb()?a.J=Date.now():(Vw(a,b),b.preventDefault()))},{passive:!1});a.h.o(a.g,"click",function(){Ww(a)});a.h.o(a.g,"dblclick",function(){a.i.doubleClickForFullscreen&&a.ae()&&a.Me()})}function Rw(a){var b=R("div");b.classList.add("shaka-play-button-container");a.g.appendChild(b);a.fb=new tw(b,a);a.H.push(a.fb)}
983
+ function Qw(a){var b=R("div");b.classList.add("shaka-scrim-container");a.g.appendChild(b)}function Xw(a){a.K=R("div");a.K.classList.add("shaka-ad-controls");var b=null!=a.l&&a.l.isLinear();X(a.K,b);a.N.appendChild(a.K);b=new ow(a.K,a);a.H.push(b);b=new nw(a.K,a);a.H.push(b)}
984
+ function Sw(a){a.ba=R("div");a.ba.classList.add("shaka-spinner-container");a.j.appendChild(a.ba);var b=R("div");b.classList.add("shaka-spinner");a.ba.appendChild(b);a=document.createElementNS("http://www.w3.org/2000/svg","svg");a.classList.add("shaka-spinner-svg");a.setAttribute("viewBox","0 0 30 30");b.appendChild(a);b=document.createElementNS("http://www.w3.org/2000/svg","circle");b.classList.add("shaka-spinner-path");b.setAttribute("cx","15");b.setAttribute("cy","15");b.setAttribute("r","14.5");
983
985
  b.setAttribute("fill","none");b.setAttribute("stroke-width","1");b.setAttribute("stroke-miterlimit","10");a.appendChild(b)}
984
- function Qw(a){a.N=R("div");a.N.classList.add("shaka-bottom-controls");a.N.classList.add("shaka-no-propagation");a.g.appendChild(a.N);a.h.o(a.N,"click",function(d){d.target.closest(".shaka-overflow-button")||a.dc()});Uw(a);a.X=R("div");a.X.classList.add("shaka-controls-button-panel");a.X.classList.add("shaka-show-controls-on-mouse-over");a.i.enableTooltips&&a.X.classList.add("shaka-tooltips-on");a.N.appendChild(a.X);for(var b=t(a.i.controlPanelElements),c=b.next();!c.done;c=b.next())c=c.value,Kw.get(c)?
985
- (c=Kw.get(c).create(a.X,a),a.H.push(c)):Ua("Unrecognized control panel element requested:",c)}function Rw(a){if(a.i.addSeekBar)a.m=Vw.create(a.N,a),a.H.push(a.m);else{a=t(a.G);for(var b=a.next();!b.done;b=a.next())b.value.classList.add("shaka-low-position")}}function Mw(a){a.P=R("div");a.P.classList.add("shaka-client-side-ad-container");X(a.P,!1);a.h.o(a.P,"click",function(){Tw(a)});a.j.appendChild(a.P)}
986
- function Gw(a){a.h.o(a.F,"buffering",function(){a.S&&X(a.ba,a.F.Kc())});a.S&&X(a.ba,a.F.Kc());a.h.o(window,"keydown",function(b){Ww(a,b)});a.h.o(window,"click",function(){return a.dc()});a.h.o(a,"submenuopen",function(){a.dc()});a.h.o(a.B,"play",function(){Dw(a)});a.h.o(a.B,"pause",function(){Dw(a)});a.h.o(a.j,"mousemove",function(b){Sw(a,b)});a.h.o(a.j,"touchmove",function(b){Sw(a,b)},{passive:!0});a.h.o(a.j,"touchend",function(b){Sw(a,b)},{passive:!0});a.h.o(a.j,"mouseleave",function(){a.J||a.aa.xa()});
987
- a.h.o(a.C,"caststatuschanged",function(){Hw(a)});a.h.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.g.contains(c)&&Sw(a,b);if(a.i.enableKeyboardPlaybackControls)switch(c=a.i.keyboardSeekDistance,b.key){case "ArrowLeft":a.m&&!d&&0<c&&(b.preventDefault(),Xw(a,a.m.getValue()-c));break;case "ArrowRight":a.m&&!d&&0<c&&(b.preventDefault(),Xw(a,a.m.getValue()+c));break;case "Home":a.m&&
988
- Xw(a,a.F.Ia().start);break;case "End":a.m&&Xw(a,a.F.Ia().end);break;case " ":e&&Yw(a)}});a.h.o(a.j,"keyup",function(b){a.ma["delete"](b.key)});a.h.o(a.Xa,"ad-started",function(b){a.l=b.ad;a.Jf()});a.h.o(a.Xa,"ad-stopped",function(){a.l=null;a.tf()});screen.orientation&&a.h.o(screen.orientation,"change",function(){return I(function(b){return u(b,Zw(a),0)})});a.h.o(document,"fullscreenchange",function(){a.l&&a.l.resize(a.A.offsetWidth,a.A.offsetHeight)})}
989
- function Zw(a){return I(function(b){return a.B&&0!=a.B.readyState&&!a.C.qa()&&a.i.enableFullscreenOnRotation?screen.orientation.type.includes("landscape")&&!document.fullscreenElement?u(b,a.j.requestFullscreen({navigationUI:"hide"}),0):screen.orientation.type.includes("portrait")&&document.fullscreenElement?u(b,document.exitFullscreen(),0):b.D(0):b["return"]()})}
990
- function Sw(a,b){"mousemove"==b.type&&(a.g.classList.remove("shaka-keyboard-navigation"),Dw(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.ib=!0,a.I.stop(),a.Mb()||(Ew(a),Dw(a)),a.aa.stop(),"touchend"!=b.type&&"keyup"!=b.type&&a.J||a.aa.T(3))}function $w(a){return window.matchMedia("hover: hover").matches?a.wb.some(function(b){return b.matches(":hover")}):!1}
991
- function Dw(a){var b=a.l?a.l.isPaused():!1,c=a.B.paused&&!a.$,d=a.g.classList.contains("shaka-keyboard-navigation");b||(!a.l||!a.l.isLinear())&&c||a.ib||d||$w(a)?(Ew(a),a.g.setAttribute("shown","true"),a.ea.stop()):a.ea.T(a.i.fadeDelay)}function Tw(a){a.S&&(a.cd()?a.I.xa():a.i.singleClickForPlayAndPause&&Yw(a))}function Yw(a){a.l&&a.l.isLinear()?ow(a):pw(a)}
992
- function Hw(a){var b=a.C.qa();a.dispatchEvent(new M("caststatuschanged",(new Map).set("newStatus",b)));b?a.g.setAttribute("casting","true"):a.g.removeAttribute("casting")}q.Mb=function(){return this.S?null!=this.g.getAttribute("shown")||null!=this.g.getAttribute("casting"):!1};function Xw(a,b){a.m.changeTo(b);a.Mb()&&Ew(a)}
993
- function Ew(a){if(a.m)if(a.m.setValue(a.B.currentTime),a.m.update(),a.m.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 M("timeandseekrangeupdated"))}
994
- function Ww(a,b){a.ma.add(b.key);var c=a.cd();"Tab"==b.key&&(a.g.classList.add("shaka-keyboard-navigation"),Dw(a),a.h.o(window,"mousedown",function(){a.h.nc(window,"mousedown")}));"Escape"==b.key&&a.I.xa();c&&a.ma.has("Tab")&&ax(a,b)}
995
- function ax(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.ma.has("Shift")?e==c&&(b.preventDefault(),d.focus()):e==d&&(b.preventDefault(),c.focus())}}}
996
- function Fw(){var a=new Vb("en");a.ia("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..."],
986
+ function Tw(a){a.N=R("div");a.N.classList.add("shaka-bottom-controls");a.N.classList.add("shaka-no-propagation");a.g.appendChild(a.N);a.h.o(a.N,"click",function(d){d.target.closest(".shaka-overflow-button")||a.dc()});Xw(a);a.X=R("div");a.X.classList.add("shaka-controls-button-panel");a.X.classList.add("shaka-show-controls-on-mouse-over");a.i.enableTooltips&&a.X.classList.add("shaka-tooltips-on");a.N.appendChild(a.X);for(var b=t(a.i.controlPanelElements),c=b.next();!c.done;c=b.next())c=c.value,Nw.get(c)?
987
+ (c=Nw.get(c).create(a.X,a),a.H.push(c)):Ua("Unrecognized control panel element requested:",c)}function Uw(a){if(a.i.addSeekBar)a.m=Yw.create(a.N,a),a.H.push(a.m);else{a=t(a.G);for(var b=a.next();!b.done;b=a.next())b.value.classList.add("shaka-low-position")}}function Pw(a){a.P=R("div");a.P.classList.add("shaka-client-side-ad-container");X(a.P,!1);a.h.o(a.P,"click",function(){Ww(a)});a.j.appendChild(a.P)}
988
+ function Jw(a){a.h.o(a.F,"buffering",function(){a.S&&X(a.ba,a.F.Kc())});a.S&&X(a.ba,a.F.Kc());a.h.o(window,"keydown",function(b){Zw(a,b)});a.h.o(window,"click",function(){return a.dc()});a.h.o(a,"submenuopen",function(){a.dc()});a.h.o(a.B,"play",function(){Gw(a)});a.h.o(a.B,"pause",function(){Gw(a)});a.h.o(a.j,"mousemove",function(b){Vw(a,b)});a.h.o(a.j,"touchmove",function(b){Vw(a,b)},{passive:!0});a.h.o(a.j,"touchend",function(b){Vw(a,b)},{passive:!0});a.h.o(a.j,"mouseleave",function(){a.J||a.aa.xa()});
989
+ a.h.o(a.C,"caststatuschanged",function(){Kw(a)});a.h.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.g.contains(c)&&Vw(a,b);if(a.i.enableKeyboardPlaybackControls)switch(c=a.i.keyboardSeekDistance,b.key){case "ArrowLeft":a.m&&!d&&0<c&&(b.preventDefault(),$w(a,a.m.getValue()-c));break;case "ArrowRight":a.m&&!d&&0<c&&(b.preventDefault(),$w(a,a.m.getValue()+c));break;case "Home":a.m&&
990
+ $w(a,a.F.Ia().start);break;case "End":a.m&&$w(a,a.F.Ia().end);break;case " ":e&&ax(a)}});a.h.o(a.j,"keyup",function(b){a.ma["delete"](b.key)});a.h.o(a.Xa,"ad-started",function(b){a.l=b.ad;a.Kf()});a.h.o(a.Xa,"ad-stopped",function(){a.l=null;a.uf()});screen.orientation&&a.h.o(screen.orientation,"change",function(){return I(function(b){return u(b,bx(a),0)})});a.h.o(document,"fullscreenchange",function(){a.l&&a.l.resize(a.A.offsetWidth,a.A.offsetHeight)})}
991
+ function bx(a){return I(function(b){return a.B&&0!=a.B.readyState&&!a.C.qa()&&a.i.enableFullscreenOnRotation?screen.orientation.type.includes("landscape")&&!document.fullscreenElement?u(b,a.j.requestFullscreen({navigationUI:"hide"}),0):screen.orientation.type.includes("portrait")&&document.fullscreenElement?u(b,document.exitFullscreen(),0):b.D(0):b["return"]()})}
992
+ function Vw(a,b){"mousemove"==b.type&&(a.g.classList.remove("shaka-keyboard-navigation"),Gw(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.ib=!0,a.I.stop(),a.Mb()||(Hw(a),Gw(a)),a.aa.stop(),"touchend"!=b.type&&"keyup"!=b.type&&a.J||a.aa.T(3))}function cx(a){return window.matchMedia("hover: hover").matches?a.wb.some(function(b){return b.matches(":hover")}):!1}
993
+ function Gw(a){var b=a.l?a.l.isPaused():!1,c=a.B.paused&&!a.$,d=a.g.classList.contains("shaka-keyboard-navigation");b||(!a.l||!a.l.isLinear())&&c||a.ib||d||cx(a)?(Hw(a),a.g.setAttribute("shown","true"),a.ea.stop()):a.ea.T(a.i.fadeDelay)}function Ww(a){a.S&&(a.cd()?a.I.xa():a.i.singleClickForPlayAndPause&&ax(a))}function ax(a){a.l&&a.l.isLinear()?rw(a):sw(a)}
994
+ function Kw(a){var b=a.C.qa();a.dispatchEvent(new L("caststatuschanged",(new Map).set("newStatus",b)));b?a.g.setAttribute("casting","true"):a.g.removeAttribute("casting")}q.Mb=function(){return this.S?null!=this.g.getAttribute("shown")||null!=this.g.getAttribute("casting"):!1};function $w(a,b){a.m.changeTo(b);a.Mb()&&Hw(a)}
995
+ function Hw(a){if(a.m)if(a.m.setValue(a.B.currentTime),a.m.update(),a.m.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 L("timeandseekrangeupdated"))}
996
+ function Zw(a,b){a.ma.add(b.key);var c=a.cd();"Tab"==b.key&&(a.g.classList.add("shaka-keyboard-navigation"),Gw(a),a.h.o(window,"mousedown",function(){a.h.nc(window,"mousedown")}));"Escape"==b.key&&a.I.xa();c&&a.ma.has("Tab")&&dx(a,b)}
997
+ function dx(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.ma.has("Shift")?e==c&&(b.preventDefault(),d.focus()):e==d&&(b.preventDefault(),c.focus())}}}
998
+ function Iw(){var a=new Vb("en");a.ia("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..."],
997
999
  ["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"],
998
1000
  ["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"],
999
1001
  ["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"],
@@ -1051,77 +1053,77 @@ a.ia("en",new Map([["AD_DURATION","Ad duration"],["AD_PROGRESS","Ad [AD_ON] of [
1051
1053
  ["PLAY","\u64ad\u653e"],["PLAYBACK_RATE","\u64ad\u653e\u901f\u5ea6"],["RESOLUTION","\u5206\u8fa8\u7387"],["REWIND","\u5feb\u9000"],["SEEK","\u8fdb\u5ea6"],["SKIP_AD","\u8df3\u8fc7\u5e7f\u544a"],["SKIP_TO_LIVE","\u8df3\u81f3\u5f53\u524d\u76f4\u64ad"],["UNDETERMINED_LANGUAGE","\u672a\u786e\u5b9a"],["UNMUTE","\u53d6\u6d88\u9759\u97f3"],["UNRECOGNIZED_LANGUAGE","\u65e0\u6cd5\u8bc6\u522b"],["VOLUME","\u97f3\u91cf"]]));a.ia("zh-TW",new Map([["AD_DURATION","\u5ee3\u544a\u9577\u5ea6"],["AD_PROGRESS","\u5ee3\u544a [AD_ON]/[NUM_ADS]"],
1052
1054
  ["AD_TIME","\u5ee3\u544a\uff1a[AD_TIME]"],["AUTO_QUALITY","\u81ea\u52d5"],["BACK","\u8fd4\u56de"],["CAPTIONS","\u5b57\u5e55"],["CAST","\u6295\u653e..."],["ENTER_LOOP_MODE","\u5faa\u74b0\u64ad\u653e\u76ee\u524d\u7684\u5f71\u7247"],["ENTER_PICTURE_IN_PICTURE","\u9032\u5165\u5b50\u6bcd\u756b\u9762"],["EXIT_FULL_SCREEN","\u9000\u51fa\u5168\u87a2\u5e55\u6a21\u5f0f"],["EXIT_LOOP_MODE","\u505c\u6b62\u5faa\u74b0\u64ad\u653e\u76ee\u524d\u7684\u5f71\u7247"],["EXIT_PICTURE_IN_PICTURE","\u96e2\u958b\u5b50\u6bcd\u756b\u9762"],
1053
1055
  ["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"],
1054
- ["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.bf(navigator.languages||[]);return a}J("shaka.ui.Controls",Y);Y.prototype.isOpaque=Y.prototype.Mb;Y.prototype.hideAdUI=Y.prototype.tf;Y.prototype.showAdUI=Y.prototype.Jf;
1055
- Y.prototype.toggleFullScreen=Y.prototype.Le;Y.prototype.isFullScreenEnabled=Y.prototype.$d;Y.prototype.isFullScreenSupported=Y.prototype.ae;Y.prototype.hideSettingsMenus=Y.prototype.dc;Y.prototype.anySettingsMenusAreOpen=Y.prototype.cd;Y.prototype.setLastTouchEventTime=Y.prototype.Hf;Y.prototype.getDisplayTime=Y.prototype.pf;Y.prototype.isCastAllowed=Y.prototype.Kg;Y.prototype.setSeeking=Y.prototype.Fe;Y.prototype.isSeeking=Y.prototype.Mg;Y.prototype.getConfig=Y.prototype.jg;
1056
- Y.prototype.getClientSideAdContainer=Y.prototype.ig;Y.prototype.getServerSideAdContainer=Y.prototype.Bg;Y.prototype.getControlsContainer=Y.prototype.lg;Y.prototype.getLocalPlayer=Y.prototype.qg;Y.prototype.getPlayer=Y.prototype.bc;Y.prototype.getLocalVideo=Y.prototype.rg;Y.prototype.getVideo=Y.prototype.Bb;Y.prototype.getVideoContainer=Y.prototype.Hg;Y.prototype.getLocalization=Y.prototype.sg;Y.prototype.getCastProxy=Y.prototype.gg;Y.prototype.getAd=Y.prototype.getAd;
1057
- Y.prototype.setEnabledNativeControls=Y.prototype.Gf;Y.prototype.setEnabledShakaControls=Y.prototype.Be;Y.prototype.configure=Y.prototype.configure;Y.prototype.loadComplete=Y.prototype.Ng;Y.prototype.allowCast=Y.prototype.Vf;Y.registerSeekBar=function(a){Vw=a};Y.registerElement=Jw;Y.prototype.destroy=Y.prototype.destroy;var Kw=new Map,Vw=new Cw;function bx(a,b){W.call(this,a,b);var c=this;this.l=this.controls.i;this.j=this.controls.g;this.i=[];this.g=ck();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=R("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");
1058
- this.h.classList.add("shaka-hidden");this.j.appendChild(this.h);cx(this);this.eventManager.o(this.localization,"locale-updated",function(){dx(c)});this.eventManager.o(this.localization,"locale-changed",function(){dx(c)});this.eventManager.o(this.adManager,"ad-started",function(){c.ad&&c.ad.isLinear()&&X(c.g,!1)});this.eventManager.o(this.adManager,"ad-stopped",function(){X(c.g,!0)});this.eventManager.o(this.controls,"submenuopen",function(){X(c.h,!1)});this.eventManager.o(this.h,"touchstart",function(d){c.controls.Hf(Date.now());
1059
- d.stopPropagation()});this.eventManager.o(this.g,"click",function(){ex(c)});dx(this);this.ad&&this.ad.isLinear()&&X(this.g,!1)}qa(bx,W);bx.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=[];W.prototype.release.call(this)};function fx(a,b){gx.set(a,b)}
1060
- function cx(a){for(var b=t(a.l.overflowMenuButtons),c=b.next();!c.done;c=b.next())c=c.value,gx.get(c)?(c=gx.get(c),a.i.push(c.create(a.h,a.controls))):Ua("Unrecognized overflow menu element requested:",c)}function ex(a){if(a.controls.cd())a.controls.dc();else{X(a.h,!0);Dw(a.controls);var b=function(c){return 0==c.classList.contains("shaka-hidden")};ib(a.h.childNodes,b)&&jb(a.h.childNodes,b)[0].focus()}}function dx(a){a.g.ariaLabel=a.localization.resolve("MORE_SETTINGS")}
1061
- J("shaka.ui.OverflowMenu",bx);bx.registerElement=fx;function hx(){}hx.prototype.create=function(a,b){return new bx(a,b)};Jw("overflow_menu",new hx);var gx=new Map;function ix(a,b){W.call(this,a,b);var c=this;this.g=ck();this.g.classList.add("shaka-airplay-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.h=R("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");var d=R("label");d.classList.add("shaka-overflow-button-label");d.classList.add("shaka-overflow-menu-only");this.j=R("span");d.appendChild(this.j);
1062
- this.i=R("span");this.i.classList.add("shaka-current-selection-span");d.appendChild(this.i);this.g.appendChild(d);this.parent.appendChild(this.g);jx(this);kx(this);this.eventManager.o(this.localization,"locale-updated",function(){jx(c)});this.eventManager.o(this.localization,"locale-changed",function(){jx(c)});this.eventManager.o(this.g,"click",function(){c.controls.Bb().webkitShowPlaybackTargetPicker()});d=this.controls.Bb();this.eventManager.o(d,"webkitplaybacktargetavailabilitychanged",function(e){var f=
1063
- c.player.qf()==Wl;X(c.g,"available"==e.availability&&f)});this.eventManager.o(d,"webkitcurrentplaybacktargetiswirelesschanged",function(){kx(c)})}qa(ix,W);function kx(a){var b=a.controls.Bb();a.g.ariaPressed=b&&b.webkitCurrentPlaybackTargetIsWireless?"true":"false"}function jx(a){a.g.ariaLabel=a.localization.resolve("AIRPLAY");a.j.textContent=a.localization.resolve("AIRPLAY")}J("shaka.ui.AirPlayButton",ix);function lx(){}lx.prototype.create=function(a,b){return new ix(a,b)};fx("airplay",new lx);
1064
- Jw("airplay",new lx);function mx(a,b,c){this.i=a;this.h=nx(this);b.dataset.shakaPlayerContainer="";b.ui=this;this.be()&&b.classList.add("shaka-mobile");this.g=new Y(a,b,c,this.h);this.configure({});c.controls||a.Ie(b);b.ui=this;c.ui=this}q=mx.prototype;q.destroy=function(){var a=this;return I(function(b){if(1==b.g)return a.g?u(b,a.g.destroy(),2):b.D(2);if(4!=b.g)return a.g=null,a.i?u(b,a.i.destroy(),4):b.D(4);a.i=null;z(b)})};q.be=function(){return/(?:iPhone|iPad|iPod|Android)/.test(navigator.userAgent)?!0:Id()&&1<navigator.maxTouchPoints};
1065
- q.getConfiguration=function(){var a=nx(this);Hk(a,this.h,nx(this),{},"");return a};q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=Ik(a,b));Hk(this.h,a,nx(this),{},"");this.h.castReceiverAppId&&!this.h.overflowMenuButtons.includes("cast")&&this.h.overflowMenuButtons.push("cast");this.g.configure(this.h);this.g.dispatchEvent(new M("uiupdated"))};q.kg=function(){return this.g};q.nh=function(a){this.g.Be(a)};
1066
- function nx(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",
1056
+ ["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.cf(navigator.languages||[]);return a}J("shaka.ui.Controls",Y);Y.prototype.isOpaque=Y.prototype.Mb;Y.prototype.hideAdUI=Y.prototype.uf;Y.prototype.showAdUI=Y.prototype.Kf;
1057
+ Y.prototype.toggleFullScreen=Y.prototype.Me;Y.prototype.isFullScreenEnabled=Y.prototype.$d;Y.prototype.isFullScreenSupported=Y.prototype.ae;Y.prototype.hideSettingsMenus=Y.prototype.dc;Y.prototype.anySettingsMenusAreOpen=Y.prototype.cd;Y.prototype.setLastTouchEventTime=Y.prototype.If;Y.prototype.getDisplayTime=Y.prototype.qf;Y.prototype.isCastAllowed=Y.prototype.Lg;Y.prototype.setSeeking=Y.prototype.Ge;Y.prototype.isSeeking=Y.prototype.Ng;Y.prototype.getConfig=Y.prototype.kg;
1058
+ Y.prototype.getClientSideAdContainer=Y.prototype.jg;Y.prototype.getServerSideAdContainer=Y.prototype.Cg;Y.prototype.getControlsContainer=Y.prototype.mg;Y.prototype.getLocalPlayer=Y.prototype.rg;Y.prototype.getPlayer=Y.prototype.bc;Y.prototype.getLocalVideo=Y.prototype.sg;Y.prototype.getVideo=Y.prototype.Bb;Y.prototype.getVideoContainer=Y.prototype.Ig;Y.prototype.getLocalization=Y.prototype.ug;Y.prototype.getCastProxy=Y.prototype.hg;Y.prototype.getAd=Y.prototype.getAd;
1059
+ Y.prototype.setEnabledNativeControls=Y.prototype.Hf;Y.prototype.setEnabledShakaControls=Y.prototype.Ce;Y.prototype.configure=Y.prototype.configure;Y.prototype.loadComplete=Y.prototype.Og;Y.prototype.allowCast=Y.prototype.Wf;Y.registerSeekBar=function(a){Yw=a};Y.registerElement=Mw;Y.prototype.destroy=Y.prototype.destroy;var Nw=new Map,Yw=new Fw;function ex(a,b){W.call(this,a,b);var c=this;this.l=this.controls.i;this.j=this.controls.g;this.i=[];this.g=fk();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=R("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");
1060
+ this.h.classList.add("shaka-hidden");this.j.appendChild(this.h);fx(this);this.eventManager.o(this.localization,"locale-updated",function(){gx(c)});this.eventManager.o(this.localization,"locale-changed",function(){gx(c)});this.eventManager.o(this.adManager,"ad-started",function(){c.ad&&c.ad.isLinear()&&X(c.g,!1)});this.eventManager.o(this.adManager,"ad-stopped",function(){X(c.g,!0)});this.eventManager.o(this.controls,"submenuopen",function(){X(c.h,!1)});this.eventManager.o(this.h,"touchstart",function(d){c.controls.If(Date.now());
1061
+ d.stopPropagation()});this.eventManager.o(this.g,"click",function(){hx(c)});gx(this);this.ad&&this.ad.isLinear()&&X(this.g,!1)}qa(ex,W);ex.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=[];W.prototype.release.call(this)};function ix(a,b){jx.set(a,b)}
1062
+ function fx(a){for(var b=t(a.l.overflowMenuButtons),c=b.next();!c.done;c=b.next())c=c.value,jx.get(c)?(c=jx.get(c),a.i.push(c.create(a.h,a.controls))):Ua("Unrecognized overflow menu element requested:",c)}function hx(a){if(a.controls.cd())a.controls.dc();else{X(a.h,!0);Gw(a.controls);var b=function(c){return 0==c.classList.contains("shaka-hidden")};ib(a.h.childNodes,b)&&jb(a.h.childNodes,b)[0].focus()}}function gx(a){a.g.ariaLabel=a.localization.resolve("MORE_SETTINGS")}
1063
+ J("shaka.ui.OverflowMenu",ex);ex.registerElement=ix;function kx(){}kx.prototype.create=function(a,b){return new ex(a,b)};Mw("overflow_menu",new kx);var jx=new Map;function lx(a,b){W.call(this,a,b);var c=this;this.g=fk();this.g.classList.add("shaka-airplay-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.h=R("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");var d=R("label");d.classList.add("shaka-overflow-button-label");d.classList.add("shaka-overflow-menu-only");this.j=R("span");d.appendChild(this.j);
1064
+ this.i=R("span");this.i.classList.add("shaka-current-selection-span");d.appendChild(this.i);this.g.appendChild(d);this.parent.appendChild(this.g);mx(this);nx(this);this.eventManager.o(this.localization,"locale-updated",function(){mx(c)});this.eventManager.o(this.localization,"locale-changed",function(){mx(c)});this.eventManager.o(this.g,"click",function(){c.controls.Bb().webkitShowPlaybackTargetPicker()});d=this.controls.Bb();this.eventManager.o(d,"webkitplaybacktargetavailabilitychanged",function(e){var f=
1065
+ c.player.rf()==Zl;X(c.g,"available"==e.availability&&f)});this.eventManager.o(d,"webkitcurrentplaybacktargetiswirelesschanged",function(){nx(c)})}qa(lx,W);function nx(a){var b=a.controls.Bb();a.g.ariaPressed=b&&b.webkitCurrentPlaybackTargetIsWireless?"true":"false"}function mx(a){a.g.ariaLabel=a.localization.resolve("AIRPLAY");a.j.textContent=a.localization.resolve("AIRPLAY")}J("shaka.ui.AirPlayButton",lx);function ox(){}ox.prototype.create=function(a,b){return new lx(a,b)};ix("airplay",new ox);
1066
+ Mw("airplay",new ox);function px(a,b,c){this.i=a;this.h=qx(this);b.dataset.shakaPlayerContainer="";b.ui=this;this.be()&&b.classList.add("shaka-mobile");this.g=new Y(a,b,c,this.h);this.configure({});c.controls||a.Je(b);b.ui=this;c.ui=this}q=px.prototype;q.destroy=function(){var a=this;return I(function(b){if(1==b.g)return a.g?u(b,a.g.destroy(),2):b.D(2);if(4!=b.g)return a.g=null,a.i?u(b,a.i.destroy(),4):b.D(4);a.i=null;z(b)})};q.be=function(){return/(?:iPhone|iPad|iPod|Android)/.test(navigator.userAgent)?!0:Zc()&&1<navigator.maxTouchPoints};
1067
+ q.getConfiguration=function(){var a=qx(this);Kk(a,this.h,qx(this),{},"");return a};q.configure=function(a,b){2==arguments.length&&"string"==typeof a&&(a=Lk(a,b));Kk(this.h,a,qx(this),{},"");this.h.castReceiverAppId&&!this.h.overflowMenuButtons.includes("cast")&&this.h.overflowMenuButtons.push("cast");this.g.configure(this.h);this.g.dispatchEvent(new L("uiupdated"))};q.lg=function(){return this.g};q.oh=function(a){this.g.Ce(a)};
1068
+ function qx(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",
1067
1069
  "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)"},
1068
- trackLabelFormat:ox,fadeDelay:0,doubleClickForFullscreen:!0,singleClickForPlayAndPause:!0,enableKeyboardPlaybackControls:!0,enableFullscreenOnRotation:!0,forceLandscapeOnFullscreen:!0,enableTooltips:!1,keyboardSeekDistance:5};window.WebKitPlaybackTargetAvailabilityEvent&&b.overflowMenuButtons.push("airplay");a.be()&&(b.addBigPlayButton=!0,b.controlPanelElements=b.controlPanelElements.filter(function(c){return"play_pause"!=c&&"volume"!=c}));return b}
1069
- function px(){var a,b,c,d,e,f,g,h,k,l,m,n,p;return I(function(r){switch(r.g){case 1:nt();if(!ll())return qx("shaka-ui-load-failed",rx),r["return"]();a=document.querySelectorAll("[data-shaka-player-container]");b=document.querySelectorAll("[data-shaka-player]");if(!b.length&&!a.length){r.D(2);break}if(b.length&&!a.length){c=t(b);for(d=c.next();!d.done;d=c.next())e=d.value,e.ui||(f=document.createElement("div"),g=e.parentElement,g.replaceChild(f,e),f.appendChild(e),sx(f,e));r.D(2);break}h=t(a);k=h.next();
1070
- case 4:if(k.done){r.D(2);break}l=k.value;if(l.ui){r.D(5);break}m=null;n=t(b);for(d=n.next();!d.done;d=n.next())if(p=d.value,p.parentElement==l){m=p;break}m||(m=document.createElement("video"),m.setAttribute("playsinline",""),l.appendChild(m));A(r,7);return u(r,sx(l,m),9);case 9:va(r,5);break;case 7:return F(r),qx("shaka-ui-load-failed",tx),r["return"]();case 5:k=h.next();r.D(4);break;case 2:qx("shaka-ui-loaded"),z(r)}})}
1071
- function qx(a,b){var c=null;void 0!=b&&(c={reasonCode:b});c=new CustomEvent(a,{detail:c});document.dispatchEvent(c)}
1072
- function sx(a,b){var c,d,e,f,g,h,k,l,m;return I(function(n){switch(n.g){case 1:c=new S(b);d=new mx(c,a,b);e="";f=!1;a.dataset&&a.dataset.shakaPlayerCastReceiverId?(e=a.dataset.shakaPlayerCastReceiverId,f="true"===a.dataset.shakaPlayerCastAndroidReceiverCompatible):b.dataset&&b.dataset.shakaPlayerCastReceiverId&&(e=b.dataset.shakaPlayerCastReceiverId,f="true"===b.dataset.shakaPlayerCastAndroidReceiverCompatible);e.length&&d.configure({castReceiverAppId:e,castAndroidReceiverCompatible:f});b.controls&&
1073
- d.g.Gf(!0);if(g=b.getAttribute("src"))h=document.createElement("source"),h.setAttribute("src",g),b.appendChild(h),b.removeAttribute("src");k=t(b.querySelectorAll("source"));l=k.next();case 2:if(l.done){n.D(0);break}m=l.value;A(n,5);return u(n,d.g.bc().load(m.getAttribute("src")),7);case 7:n.D(0);break;case 5:F(n);case 3:l=k.next(),n.D(2)}})}J("shaka.ui.Overlay",mx);mx.prototype.setEnabled=mx.prototype.nh;mx.prototype.getControls=mx.prototype.kg;mx.prototype.configure=mx.prototype.configure;
1074
- mx.prototype.getConfiguration=mx.prototype.getConfiguration;mx.prototype.isMobile=mx.prototype.be;mx.prototype.destroy=mx.prototype.destroy;var ox=0;mx.TrackLabelFormat={LANGUAGE:ox,ROLE:1,LANGUAGE_ROLE:2,LABEL:3};var rx=0,tx=1;mx.FailReasonCode={NO_BROWSER_SUPPORT:rx,PLAYER_FAILED_TO_LOAD:tx};"complete"==document.readyState?I(function(a){if(1==a.g)return u(a,Promise.resolve(),2);px();z(a)}):window.addEventListener("load",px);function ux(a,b,c,d,e,f,g){function h(C,B){return C+": "+B}function k(C){return"variant"==C.type?C.audioRoles?C.audioRoles.join(", "):void 0:C.roles.join(", ")}var l=a.find(function(C){return 1==C.active}),m=fw(b);dk(b);b.appendChild(m);m=new Map;for(var n=t(a),p=n.next();!p.done;p=n.next())p=p.value,m.has(p.language)||m.set(p.language,new Set),m.get(p.language).add(k(p));m=new Set;l=l?h(l.language,k(l)):"";n={};a=t(a);for(p=a.next();!p.done;n={Va:n.Va},p=a.next()){n.Va=p.value;p=n.Va.language;var r=
1075
- n.Va.forced,x=f.resolve(Zb.Qf),y=k(n.Va),w=h(p,y);if(!m.has(w)){m.add(w);var v=ck();v.addEventListener("click",function(C){return function(){c(C.Va)}}(n));var D=R("span");v.appendChild(D);D.textContent=vx(p,f);switch(g){case ox:r&&(D.textContent+=" ("+x+")");break;case 1:y?D.textContent=y:(Ua("Track #"+n.Va.id+" does not have a role, but the UI is configured to only show role."),D.textContent="?");r&&(D.textContent+=" ("+x+")");break;case 2:y&&(D.textContent+=": "+y);r&&(D.textContent+=" ("+x+")");
1076
- break;case 3:n.Va.label?D.textContent=n.Va.label:(Ua("Track #"+n.Va.id+" does not have a label, but the UI is configured to only show labels."),D.textContent="?")}d&&w==l&&(v.appendChild(iw()),D.classList.add("shaka-chosen-item"),v.ariaSelected="true",e.textContent=D.textContent);b.appendChild(v)}}}
1077
- function vx(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=Rb(a);return a in bw?bw[a].s:c in bw?bw[c].s+" ("+a+")":b.resolve("UNRECOGNIZED_LANGUAGE")+" ("+a+")"};function wx(a,b,c){W.call(this,a,b);var d=this;xx(this,c);yx(this);zx(this);this.eventManager.o(this.button,"click",function(){d.menu.classList.contains("shaka-hidden")?(d.controls.dispatchEvent(new M("submenuopen")),X(d.menu,!0),hw(d.menu)):X(d.menu,!1)})}qa(wx,W);
1078
- function xx(a,b){a.button=ck();a.button.classList.add("shaka-overflow-button");a.icon=R("i");a.icon.classList.add("material-icons-round");a.icon.textContent=b;a.button.appendChild(a.icon);var c=R("label");c.classList.add("shaka-overflow-button-label");c.classList.add("shaka-overflow-menu-only");a.nameSpan=R("span");c.appendChild(a.nameSpan);a.currentSelection=R("span");a.currentSelection.classList.add("shaka-current-selection-span");c.appendChild(a.currentSelection);a.button.appendChild(c);a.parent.appendChild(a.button)}
1079
- function yx(a){a.menu=R("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=ck();a.backButton.classList.add("shaka-back-to-overflow-button");a.menu.appendChild(a.backButton);a.eventManager.o(a.backButton,"click",function(){a.controls.dc()});var b=R("i");b.classList.add("material-icons-round");b.textContent="close";a.backButton.appendChild(b);a.backSpan=
1080
- R("span");a.backButton.appendChild(a.backSpan);a.controls.g.appendChild(a.menu)}function zx(a){a.parent.classList.contains("shaka-overflow-menu")&&(a.backButton.firstChild.textContent="arrow_back",a.eventManager.o(a.backButton,"click",function(){X(a.parent,!0);a.parent.childNodes[0].focus();Dw(a.controls)}))}J("shaka.ui.SettingsMenu",wx);function Ax(a,b){wx.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(){Bx(c)});this.eventManager.o(this.localization,"locale-changed",function(){Bx(c)});this.eventManager.o(this.player,"trackschanged",function(){var d=0<c.player.Qa().length;X(c.button,d);Cx(c)});this.eventManager.o(this.player,"variantchanged",
1081
- function(){Cx(c)});Bx(this);Cx(this)}qa(Ax,wx);function Cx(a){var b=a.player.Qa();ux(b,a.menu,function(c){a.player.Ed(c.language,c.roles[0])},!0,a.currentSelection,a.localization,a.controls.i.trackLabelFormat);hw(a.menu);a.controls.dispatchEvent(new M("languageselectionupdated"));a.button.setAttribute("shaka-status",a.currentSelection.innerText)}
1082
- function Bx(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")}J("shaka.ui.AudioLanguageSelection",Ax);function Dx(){}Dx.prototype.create=function(a,b){return new Ax(a,b)};fx("language",new Dx);Jw("language",new Dx);function Ex(a,b){W.call(this,a,b);var c=this;this.h=this.controls.C;this.g=ck();this.g.classList.add("shaka-cast-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.i=R("i");this.i.classList.add("material-icons-round");this.i.textContent="cast";this.g.appendChild(this.i);var d=R("label");d.classList.add("shaka-overflow-button-label");d.classList.add("shaka-overflow-menu-only");this.l=R("span");d.appendChild(this.l);this.j=R("span");this.j.classList.add("shaka-current-selection-span");
1083
- d.appendChild(this.j);this.g.appendChild(d);this.parent.appendChild(this.g);Fx(this);Gx(this);this.eventManager.o(this.localization,"locale-updated",function(){Fx(c)});this.eventManager.o(this.localization,"locale-changed",function(){Fx(c)});this.eventManager.o(this.g,"click",function(){Hx(c)});this.eventManager.o(this.controls,"caststatuschanged",function(){Gx(c)})}qa(Ex,W);
1084
- function Hx(a){var b;I(function(c){if(1==c.g){if(a.h.qa())return a.h.Kf(),c.D(0);A(c,3);a.g.disabled=!0;return u(c,a.h.cast(),5)}if(3!=c.g)return a.g.disabled=!1,va(c,0);b=F(c);a.g.disabled=!1;8004!=b.code&&a.controls.dispatchEvent(new M("error",(new Map).set("detail",b)));z(c)})}function Gx(a){var b=a.h.Ye()&&a.controls.gb,c=a.h.qa();X(a.g,b);a.i.textContent=c?"cast_connected":"cast";b&&(a.g.ariaPressed=c?"true":"false");Ix(a)}
1085
- function Ix(a){a.j.textContent=a.h.qa()?a.h.Cd():a.localization.resolve("OFF")}function Fx(a){a.g.ariaLabel=a.localization.resolve("CAST");a.l.textContent=a.localization.resolve("CAST");Ix(a)}J("shaka.ui.CastButton",Ex);function Jx(){}Jx.prototype.create=function(a,b){return new Ex(a,b)};fx("cast",new Jx);Jw("cast",new Jx);function Kx(a,b){W.call(this,a,b);var c=this;this.g=ck();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);Lx(this);this.h=this.controls.i.fastForwardRates;this.eventManager.o(this.localization,"locale-updated",function(){Lx(c)});this.eventManager.o(this.localization,"locale-changed",function(){Lx(c)});
1086
- this.eventManager.o(this.g,"click",function(){if(c.video.duration){var d=c.h.indexOf(c.player.zb())+1;d=d!=c.h.length?c.h[d]:c.h[0];c.player.Ne(d);c.g.setAttribute("shaka-status",d+"x")}})}qa(Kx,W);function Lx(a){a.g.ariaLabel=a.localization.resolve("FAST_FORWARD")}J("shaka.ui.FastForwardButton",Kx);function Mx(){}Mx.prototype.create=function(a,b){return new Kx(a,b)};Jw("fast_forward",new Mx);function Nx(a,b){W.call(this,a,b);var c=this;this.h=this.controls.A;this.g=ck();this.g.classList.add("shaka-fullscreen-button");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");Ox(this);this.g.textContent="fullscreen";this.parent.appendChild(this.g);Px(this);this.eventManager.o(this.localization,"locale-updated",function(){Px(c)});this.eventManager.o(this.localization,"locale-changed",function(){Px(c)});this.eventManager.o(this.g,"click",function(){return I(function(d){return u(d,
1087
- c.controls.Le(),0)})});this.eventManager.o(document,"fullscreenchange",function(){c.g.textContent=c.controls.$d()?"fullscreen_exit":"fullscreen";Px(c)});this.eventManager.o(this.h,"loadedmetadata",function(){Ox(c)});this.eventManager.o(this.h,"loadeddata",function(){Ox(c)})}qa(Nx,W);function Ox(a){a.controls.ae()?a.g.classList.remove("shaka-hidden"):a.g.classList.add("shaka-hidden")}function Px(a){a.g.ariaLabel=a.localization.resolve(a.controls.$d()?"EXIT_FULL_SCREEN":"FULL_SCREEN")}
1088
- J("shaka.ui.FullscreenButton",Nx);function Qx(){}Qx.prototype.create=function(a,b){return new Nx(a,b)};Jw("fullscreen",new Qx);function Rx(a,b){W.call(this,a,b);var c=this;this.g=ck();this.g.classList.add("shaka-loop-button");this.g.classList.add("shaka-tooltip");this.i=R("i");this.i.classList.add("material-icons-round");this.i.textContent="repeat";this.g.appendChild(this.i);var d=R("label");d.classList.add("shaka-overflow-button-label");d.classList.add("shaka-overflow-menu-only");this.j=R("span");this.j.textContent=this.localization.resolve("LOOP");d.appendChild(this.j);this.l=R("span");this.l.classList.add("shaka-current-selection-span");
1089
- d.appendChild(this.l);this.g.appendChild(d);Sx(this);this.parent.appendChild(this.g);this.eventManager.o(this.localization,"locale-updated",function(){Sx(c)});this.eventManager.o(this.localization,"locale-changed",function(){Sx(c)});this.eventManager.o(this.g,"click",function(){c.video.loop=!c.video.loop;c.h.xa();c.h.ka(1)});this.m=this.video.loop;this.h=new P(function(){c.m!=c.video.loop&&(Sx(c),c.m=c.video.loop)});this.h.ka(1)}qa(Rx,W);Rx.prototype.release=function(){this.h.stop();this.h=null;W.prototype.release.call(this)};
1090
- function Sx(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")}J("shaka.ui.LoopButton",Rx);function Tx(){}Tx.prototype.create=function(a,b){return new Rx(a,b)};fx("loop",new Tx);Jw("loop",new Tx);tw("loop",new Tx);function Ux(a,b){W.call(this,a,b);var c=this;this.g=ck();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);Vx(this);Wx(this);this.eventManager.o(this.localization,"locale-updated",function(){Vx(c)});this.eventManager.o(this.localization,"locale-changed",function(){Vx(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});
1091
- this.eventManager.o(this.video,"volumechange",function(){Vx(c);Wx(c)});this.eventManager.o(this.adManager,"ad-volume-changed",function(){Vx(c);Wx(c)});this.eventManager.o(this.adManager,"ad-muted",function(){Vx(c);Wx(c)});this.eventManager.o(this.adManager,"ad-stopped",function(){c.ad=null;Vx(c);Wx(c)})}qa(Ux,W);function Vx(a){var b=a.ad?a.ad.isMuted()?"UNMUTE":"MUTE":a.video.muted?"UNMUTE":"MUTE";a.g.ariaLabel=a.localization.resolve(b)}
1092
- function Wx(a){var b=a.ad?a.ad.isMuted()?"volume_off":"volume_up":a.video.muted?"volume_off":"volume_up";a.g.textContent=b}J("shaka.ui.MuteButton",Ux);function Xx(){}Xx.prototype.create=function(a,b){return new Ux(a,b)};Jw("mute",new Xx);function Yx(a,b){W.call(this,a,b);var c=this;this.l=this.controls.A;this.g=ck();this.g.classList.add("shaka-pip-button");this.g.classList.add("shaka-tooltip");this.i=R("i");this.i.classList.add("material-icons-round");this.i.textContent="picture_in_picture_alt";this.g.appendChild(this.i);var d=R("label");d.classList.add("shaka-overflow-button-label");d.classList.add("shaka-overflow-menu-only");this.j=R("span");this.j.textContent=this.localization.resolve("PICTURE_IN_PICTURE");d.appendChild(this.j);
1093
- this.h=R("span");this.h.classList.add("shaka-current-selection-span");d.appendChild(this.h);this.g.appendChild(d);Zx(this);this.parent.appendChild(this.g);document.pictureInPictureEnabled&&!this.video.disablePictureInPicture||X(this.g,!1);this.eventManager.o(this.localization,"locale-updated",function(){Zx(c)});this.eventManager.o(this.localization,"locale-changed",function(){Zx(c)});this.eventManager.o(this.g,"click",function(){$x(c)});this.eventManager.o(this.l,"enterpictureinpicture",function(){c.i.textContent=
1070
+ trackLabelFormat:rx,fadeDelay:0,doubleClickForFullscreen:!0,singleClickForPlayAndPause:!0,enableKeyboardPlaybackControls:!0,enableFullscreenOnRotation:!0,forceLandscapeOnFullscreen:!0,enableTooltips:!1,keyboardSeekDistance:5};window.WebKitPlaybackTargetAvailabilityEvent&&b.overflowMenuButtons.push("airplay");a.be()&&(b.addBigPlayButton=!0,b.controlPanelElements=b.controlPanelElements.filter(function(c){return"play_pause"!=c&&"volume"!=c}));return b}
1071
+ function sx(){var a,b,c,d,e,f,g,h,k,l,m,n,p;return I(function(r){switch(r.g){case 1:qt();if(!ol())return tx("shaka-ui-load-failed",ux),r["return"]();a=document.querySelectorAll("[data-shaka-player-container]");b=document.querySelectorAll("[data-shaka-player]");if(!b.length&&!a.length){r.D(2);break}if(b.length&&!a.length){c=t(b);for(d=c.next();!d.done;d=c.next())e=d.value,e.ui||(f=document.createElement("div"),g=e.parentElement,g.replaceChild(f,e),f.appendChild(e),vx(f,e));r.D(2);break}h=t(a);k=h.next();
1072
+ case 4:if(k.done){r.D(2);break}l=k.value;if(l.ui){r.D(5);break}m=null;n=t(b);for(d=n.next();!d.done;d=n.next())if(p=d.value,p.parentElement==l){m=p;break}m||(m=document.createElement("video"),m.setAttribute("playsinline",""),l.appendChild(m));A(r,7);return u(r,vx(l,m),9);case 9:va(r,5);break;case 7:return F(r),tx("shaka-ui-load-failed",wx),r["return"]();case 5:k=h.next();r.D(4);break;case 2:tx("shaka-ui-loaded"),z(r)}})}
1073
+ function tx(a,b){var c=null;void 0!=b&&(c={reasonCode:b});c=new CustomEvent(a,{detail:c});document.dispatchEvent(c)}
1074
+ function vx(a,b){var c,d,e,f,g,h,k,l,m;return I(function(n){switch(n.g){case 1:c=new S(b);d=new px(c,a,b);e="";f=!1;a.dataset&&a.dataset.shakaPlayerCastReceiverId?(e=a.dataset.shakaPlayerCastReceiverId,f="true"===a.dataset.shakaPlayerCastAndroidReceiverCompatible):b.dataset&&b.dataset.shakaPlayerCastReceiverId&&(e=b.dataset.shakaPlayerCastReceiverId,f="true"===b.dataset.shakaPlayerCastAndroidReceiverCompatible);e.length&&d.configure({castReceiverAppId:e,castAndroidReceiverCompatible:f});b.controls&&
1075
+ d.g.Hf(!0);if(g=b.getAttribute("src"))h=document.createElement("source"),h.setAttribute("src",g),b.appendChild(h),b.removeAttribute("src");k=t(b.querySelectorAll("source"));l=k.next();case 2:if(l.done){n.D(0);break}m=l.value;A(n,5);return u(n,d.g.bc().load(m.getAttribute("src")),7);case 7:n.D(0);break;case 5:F(n);case 3:l=k.next(),n.D(2)}})}J("shaka.ui.Overlay",px);px.prototype.setEnabled=px.prototype.oh;px.prototype.getControls=px.prototype.lg;px.prototype.configure=px.prototype.configure;
1076
+ px.prototype.getConfiguration=px.prototype.getConfiguration;px.prototype.isMobile=px.prototype.be;px.prototype.destroy=px.prototype.destroy;var rx=0;px.TrackLabelFormat={LANGUAGE:rx,ROLE:1,LANGUAGE_ROLE:2,LABEL:3};var ux=0,wx=1;px.FailReasonCode={NO_BROWSER_SUPPORT:ux,PLAYER_FAILED_TO_LOAD:wx};"complete"==document.readyState?I(function(a){if(1==a.g)return u(a,Promise.resolve(),2);sx();z(a)}):window.addEventListener("load",sx);function xx(a,b,c,d,e,f,g){function h(C,B){return C+": "+B}function k(C){return"variant"==C.type?C.audioRoles?C.audioRoles.join(", "):void 0:C.roles.join(", ")}var l=a.find(function(C){return 1==C.active}),m=iw(b);gk(b);b.appendChild(m);m=new Map;for(var n=t(a),p=n.next();!p.done;p=n.next())p=p.value,m.has(p.language)||m.set(p.language,new Set),m.get(p.language).add(k(p));m=new Set;l=l?h(l.language,k(l)):"";n={};a=t(a);for(p=a.next();!p.done;n={Va:n.Va},p=a.next()){n.Va=p.value;p=n.Va.language;var r=
1077
+ n.Va.forced,w=f.resolve(Zb.Rf),y=k(n.Va),x=h(p,y);if(!m.has(x)){m.add(x);var v=fk();v.addEventListener("click",function(C){return function(){c(C.Va)}}(n));var D=R("span");v.appendChild(D);D.textContent=yx(p,f);switch(g){case rx:r&&(D.textContent+=" ("+w+")");break;case 1:y?D.textContent=y:(Ua("Track #"+n.Va.id+" does not have a role, but the UI is configured to only show role."),D.textContent="?");r&&(D.textContent+=" ("+w+")");break;case 2:y&&(D.textContent+=": "+y);r&&(D.textContent+=" ("+w+")");
1078
+ break;case 3:n.Va.label?D.textContent=n.Va.label:(Ua("Track #"+n.Va.id+" does not have a label, but the UI is configured to only show labels."),D.textContent="?")}d&&x==l&&(v.appendChild(lw()),D.classList.add("shaka-chosen-item"),v.ariaSelected="true",e.textContent=D.textContent);b.appendChild(v)}}}
1079
+ function yx(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=Rb(a);return a in ew?ew[a].s:c in ew?ew[c].s+" ("+a+")":b.resolve("UNRECOGNIZED_LANGUAGE")+" ("+a+")"};function zx(a,b,c){W.call(this,a,b);var d=this;Ax(this,c);Bx(this);Cx(this);this.eventManager.o(this.button,"click",function(){d.menu.classList.contains("shaka-hidden")?(d.controls.dispatchEvent(new L("submenuopen")),X(d.menu,!0),kw(d.menu)):X(d.menu,!1)})}qa(zx,W);
1080
+ function Ax(a,b){a.button=fk();a.button.classList.add("shaka-overflow-button");a.icon=R("i");a.icon.classList.add("material-icons-round");a.icon.textContent=b;a.button.appendChild(a.icon);var c=R("label");c.classList.add("shaka-overflow-button-label");c.classList.add("shaka-overflow-menu-only");a.nameSpan=R("span");c.appendChild(a.nameSpan);a.currentSelection=R("span");a.currentSelection.classList.add("shaka-current-selection-span");c.appendChild(a.currentSelection);a.button.appendChild(c);a.parent.appendChild(a.button)}
1081
+ function Bx(a){a.menu=R("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=fk();a.backButton.classList.add("shaka-back-to-overflow-button");a.menu.appendChild(a.backButton);a.eventManager.o(a.backButton,"click",function(){a.controls.dc()});var b=R("i");b.classList.add("material-icons-round");b.textContent="close";a.backButton.appendChild(b);a.backSpan=
1082
+ R("span");a.backButton.appendChild(a.backSpan);a.controls.g.appendChild(a.menu)}function Cx(a){a.parent.classList.contains("shaka-overflow-menu")&&(a.backButton.firstChild.textContent="arrow_back",a.eventManager.o(a.backButton,"click",function(){X(a.parent,!0);a.parent.childNodes[0].focus();Gw(a.controls)}))}J("shaka.ui.SettingsMenu",zx);function Dx(a,b){zx.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(){Ex(c)});this.eventManager.o(this.localization,"locale-changed",function(){Ex(c)});this.eventManager.o(this.player,"trackschanged",function(){var d=0<c.player.Qa().length;X(c.button,d);Fx(c)});this.eventManager.o(this.player,"variantchanged",
1083
+ function(){Fx(c)});Ex(this);Fx(this)}qa(Dx,zx);function Fx(a){var b=a.player.Qa();xx(b,a.menu,function(c){a.player.Ed(c.language,c.roles[0])},!0,a.currentSelection,a.localization,a.controls.i.trackLabelFormat);kw(a.menu);a.controls.dispatchEvent(new L("languageselectionupdated"));a.button.setAttribute("shaka-status",a.currentSelection.innerText)}
1084
+ function Ex(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")}J("shaka.ui.AudioLanguageSelection",Dx);function Gx(){}Gx.prototype.create=function(a,b){return new Dx(a,b)};ix("language",new Gx);Mw("language",new Gx);function Hx(a,b){W.call(this,a,b);var c=this;this.h=this.controls.C;this.g=fk();this.g.classList.add("shaka-cast-button");this.g.classList.add("shaka-tooltip");this.g.ariaPressed="false";this.i=R("i");this.i.classList.add("material-icons-round");this.i.textContent="cast";this.g.appendChild(this.i);var d=R("label");d.classList.add("shaka-overflow-button-label");d.classList.add("shaka-overflow-menu-only");this.l=R("span");d.appendChild(this.l);this.j=R("span");this.j.classList.add("shaka-current-selection-span");
1085
+ d.appendChild(this.j);this.g.appendChild(d);this.parent.appendChild(this.g);Ix(this);Jx(this);this.eventManager.o(this.localization,"locale-updated",function(){Ix(c)});this.eventManager.o(this.localization,"locale-changed",function(){Ix(c)});this.eventManager.o(this.g,"click",function(){Kx(c)});this.eventManager.o(this.controls,"caststatuschanged",function(){Jx(c)})}qa(Hx,W);
1086
+ function Kx(a){var b;I(function(c){if(1==c.g){if(a.h.qa())return a.h.Lf(),c.D(0);A(c,3);a.g.disabled=!0;return u(c,a.h.cast(),5)}if(3!=c.g)return a.g.disabled=!1,va(c,0);b=F(c);a.g.disabled=!1;8004!=b.code&&a.controls.dispatchEvent(new L("error",(new Map).set("detail",b)));z(c)})}function Jx(a){var b=a.h.Ze()&&a.controls.gb,c=a.h.qa();X(a.g,b);a.i.textContent=c?"cast_connected":"cast";b&&(a.g.ariaPressed=c?"true":"false");Lx(a)}
1087
+ function Lx(a){a.j.textContent=a.h.qa()?a.h.Cd():a.localization.resolve("OFF")}function Ix(a){a.g.ariaLabel=a.localization.resolve("CAST");a.l.textContent=a.localization.resolve("CAST");Lx(a)}J("shaka.ui.CastButton",Hx);function Mx(){}Mx.prototype.create=function(a,b){return new Hx(a,b)};ix("cast",new Mx);Mw("cast",new Mx);function Nx(a,b){W.call(this,a,b);var c=this;this.g=fk();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);Ox(this);this.h=this.controls.i.fastForwardRates;this.eventManager.o(this.localization,"locale-updated",function(){Ox(c)});this.eventManager.o(this.localization,"locale-changed",function(){Ox(c)});
1088
+ this.eventManager.o(this.g,"click",function(){if(c.video.duration){var d=c.h.indexOf(c.player.zb())+1;d=d!=c.h.length?c.h[d]:c.h[0];c.player.Oe(d);c.g.setAttribute("shaka-status",d+"x")}})}qa(Nx,W);function Ox(a){a.g.ariaLabel=a.localization.resolve("FAST_FORWARD")}J("shaka.ui.FastForwardButton",Nx);function Px(){}Px.prototype.create=function(a,b){return new Nx(a,b)};Mw("fast_forward",new Px);function Qx(a,b){W.call(this,a,b);var c=this;this.h=this.controls.A;this.g=fk();this.g.classList.add("shaka-fullscreen-button");this.g.classList.add("material-icons-round");this.g.classList.add("shaka-tooltip");Rx(this);this.g.textContent="fullscreen";this.parent.appendChild(this.g);Sx(this);this.eventManager.o(this.localization,"locale-updated",function(){Sx(c)});this.eventManager.o(this.localization,"locale-changed",function(){Sx(c)});this.eventManager.o(this.g,"click",function(){return I(function(d){return u(d,
1089
+ c.controls.Me(),0)})});this.eventManager.o(document,"fullscreenchange",function(){c.g.textContent=c.controls.$d()?"fullscreen_exit":"fullscreen";Sx(c)});this.eventManager.o(this.h,"loadedmetadata",function(){Rx(c)});this.eventManager.o(this.h,"loadeddata",function(){Rx(c)})}qa(Qx,W);function Rx(a){a.controls.ae()?a.g.classList.remove("shaka-hidden"):a.g.classList.add("shaka-hidden")}function Sx(a){a.g.ariaLabel=a.localization.resolve(a.controls.$d()?"EXIT_FULL_SCREEN":"FULL_SCREEN")}
1090
+ J("shaka.ui.FullscreenButton",Qx);function Tx(){}Tx.prototype.create=function(a,b){return new Qx(a,b)};Mw("fullscreen",new Tx);function Ux(a,b){W.call(this,a,b);var c=this;this.g=fk();this.g.classList.add("shaka-loop-button");this.g.classList.add("shaka-tooltip");this.i=R("i");this.i.classList.add("material-icons-round");this.i.textContent="repeat";this.g.appendChild(this.i);var d=R("label");d.classList.add("shaka-overflow-button-label");d.classList.add("shaka-overflow-menu-only");this.j=R("span");this.j.textContent=this.localization.resolve("LOOP");d.appendChild(this.j);this.l=R("span");this.l.classList.add("shaka-current-selection-span");
1091
+ d.appendChild(this.l);this.g.appendChild(d);Vx(this);this.parent.appendChild(this.g);this.eventManager.o(this.localization,"locale-updated",function(){Vx(c)});this.eventManager.o(this.localization,"locale-changed",function(){Vx(c)});this.eventManager.o(this.g,"click",function(){c.video.loop=!c.video.loop;c.h.xa();c.h.ka(1)});this.m=this.video.loop;this.h=new P(function(){c.m!=c.video.loop&&(Vx(c),c.m=c.video.loop)});this.h.ka(1)}qa(Ux,W);Ux.prototype.release=function(){this.h.stop();this.h=null;W.prototype.release.call(this)};
1092
+ function Vx(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")}J("shaka.ui.LoopButton",Ux);function Wx(){}Wx.prototype.create=function(a,b){return new Ux(a,b)};ix("loop",new Wx);Mw("loop",new Wx);ww("loop",new Wx);function Xx(a,b){W.call(this,a,b);var c=this;this.g=fk();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);Yx(this);Zx(this);this.eventManager.o(this.localization,"locale-updated",function(){Yx(c)});this.eventManager.o(this.localization,"locale-changed",function(){Yx(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});
1093
+ this.eventManager.o(this.video,"volumechange",function(){Yx(c);Zx(c)});this.eventManager.o(this.adManager,"ad-volume-changed",function(){Yx(c);Zx(c)});this.eventManager.o(this.adManager,"ad-muted",function(){Yx(c);Zx(c)});this.eventManager.o(this.adManager,"ad-stopped",function(){c.ad=null;Yx(c);Zx(c)})}qa(Xx,W);function Yx(a){var b=a.ad?a.ad.isMuted()?"UNMUTE":"MUTE":a.video.muted?"UNMUTE":"MUTE";a.g.ariaLabel=a.localization.resolve(b)}
1094
+ function Zx(a){var b=a.ad?a.ad.isMuted()?"volume_off":"volume_up":a.video.muted?"volume_off":"volume_up";a.g.textContent=b}J("shaka.ui.MuteButton",Xx);function $x(){}$x.prototype.create=function(a,b){return new Xx(a,b)};Mw("mute",new $x);function ay(a,b){W.call(this,a,b);var c=this;this.l=this.controls.A;this.g=fk();this.g.classList.add("shaka-pip-button");this.g.classList.add("shaka-tooltip");this.i=R("i");this.i.classList.add("material-icons-round");this.i.textContent="picture_in_picture_alt";this.g.appendChild(this.i);var d=R("label");d.classList.add("shaka-overflow-button-label");d.classList.add("shaka-overflow-menu-only");this.j=R("span");this.j.textContent=this.localization.resolve("PICTURE_IN_PICTURE");d.appendChild(this.j);
1095
+ this.h=R("span");this.h.classList.add("shaka-current-selection-span");d.appendChild(this.h);this.g.appendChild(d);by(this);this.parent.appendChild(this.g);document.pictureInPictureEnabled&&!this.video.disablePictureInPicture||X(this.g,!1);this.eventManager.o(this.localization,"locale-updated",function(){by(c)});this.eventManager.o(this.localization,"locale-changed",function(){by(c)});this.eventManager.o(this.g,"click",function(){cy(c)});this.eventManager.o(this.l,"enterpictureinpicture",function(){c.i.textContent=
1094
1096
  "branding_watermark";c.g.ariaLabel=c.localization.resolve("EXIT_PICTURE_IN_PICTURE");c.h.textContent=c.localization.resolve("ON")});this.eventManager.o(this.l,"leavepictureinpicture",function(){c.i.textContent="picture_in_picture_alt";c.g.ariaLabel=c.localization.resolve("ENTER_PICTURE_IN_PICTURE");c.h.textContent=c.localization.resolve("OFF")});this.eventManager.o(this.controls,"caststatuschanged",function(e){e.newStatus?document.pictureInPictureEnabled&&!c.video.disablePictureInPicture&&X(c.g,!1):
1095
- document.pictureInPictureEnabled&&!c.video.disablePictureInPicture&&X(c.g,!0)});this.eventManager.o(this.player,"trackschanged",function(){ay(c)})}qa(Yx,W);function $x(a){var b;I(function(c){if(1==c.g)return A(c,2),document.pictureInPictureElement?u(c,document.exitPictureInPicture(),5):(document.fullscreenElement&&document.exitFullscreen(),u(c,a.video.requestPictureInPicture(),5));if(2!=c.g)return va(c,0);b=F(c);a.controls.dispatchEvent(new M("error",(new Map).set("detail",b)));z(c)})}
1096
- function Zx(a){a.j.textContent=a.localization.resolve("PICTURE_IN_PICTURE");a.g.ariaLabel=a.localization.resolve(document.pictureInPictureElement?"EXIT_PICTURE_IN_PICTURE":"ENTER_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve(document.pictureInPictureElement?"ON":"OFF")}
1097
- function ay(a){I(function(b){if(!document.pictureInPictureEnabled||a.video.disablePictureInPicture)return X(a.g,!1),b.D(0);if(!a.player||!a.player.ec())return X(a.g,!0),b.D(0);X(a.g,!1);return document.pictureInPictureElement?u(b,document.exitPictureInPicture(),0):b.D(0)})}J("shaka.ui.PipButton",Yx);function by(){}by.prototype.create=function(a,b){return new Yx(a,b)};fx("picture_in_picture",new by);Jw("picture_in_picture",new by);tw("picture_in_picture",new by);function cy(a,b){wx.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(){dy(c)});this.eventManager.o(this.localization,"locale-changed",function(){dy(c)});this.eventManager.o(this.player,"ratechange",function(){ey(c,c.player.zb())});this.g=new Map(this.controls.i.playbackRates.map(function(d){return[d+
1098
- "x",d]}));dy(this);fy(this);ey(this,this.player.zb())}qa(cy,wx);function dy(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")}
1099
- function ey(a,b){var c=gw(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(iw()),d.ariaSelected="true",c.classList.add("shaka-chosen-item");a.currentSelection.textContent=b+"x";a.button.setAttribute("shaka-status",b+
1100
- "x")}function fy(a){for(var b={},c=t(a.g.keys()),d=c.next();!d.done;b={uc:b.uc},d=c.next()){b.uc=d.value;d=ck();var e=R("span");e.textContent=b.uc;d.appendChild(e);a.eventManager.o(d,"click",function(f){return function(){a.video.playbackRate=a.g.get(f.uc);a.video.defaultPlaybackRate=a.g.get(f.uc)}}(b));a.menu.appendChild(d)}hw(a.menu)}J("shaka.ui.PlaybackRateSelection",cy);function gy(){}gy.prototype.create=function(a,b){return new cy(a,b)};fx("playback_rate",new gy);Jw("playback_rate",new gy);function hy(a,b){W.call(this,a,b);var c=this;this.g=ck();this.g.classList.add("shaka-current-time");iy(this,"0:00");this.parent.appendChild(this.g);this.eventManager.o(this.g,"click",function(){c.player.U()&&(c.video.currentTime=c.player.Ia().end)});this.eventManager.o(this.controls,"timeandseekrangeupdated",function(){var d=c.controls.$,e=c.controls.pf(),f=c.video.duration,g=c.player.Ia(),h=g.end-g.start;c.player.U()?(e=Math.max(0,Math.floor(g.end-e)),f=3600<=h,1<=e||d?(iy(c,"- "+jw(e,f)),c.g.disabled=
1101
- !1):(iy(c,c.localization.resolve("LIVE")),c.g.disabled=!0)):(d=3600<=f,e=jw(e,d),f&&(e+=" / "+jw(f,d)),iy(c,e),c.g.disabled=!0)});this.eventManager.o(this.player,"trackschanged",function(){c.player.U()&&(c.g.ariaLabel=c.localization.resolve("SKIP_TO_LIVE"))})}qa(hy,W);function iy(a,b){b!=a.g.textContent&&(a.g.textContent=b)}J("shaka.ui.PresentationTimeTracker",hy);function jy(){}jy.prototype.create=function(a,b){return new hy(a,b)};Jw("time_and_duration",new jy);function ky(a,b){wx.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(){ly(c)});this.eventManager.o(this.localization,"locale-changed",function(){ly(c)});this.eventManager.o(this.player,"variantchanged",function(){my(c)});this.eventManager.o(this.player,"trackschanged",function(){my(c)});this.eventManager.o(this.player,
1102
- "abrstatuschanged",function(){my(c)});my(this)}qa(ky,wx);
1103
- function my(a){var b=a.player.Qa(),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){return(a.player.ec()?b.findIndex(function(m){return m.bandwidth==k.bandwidth}):b.findIndex(function(m){return m.height==k.height}))==l});a.player.ec()?b.sort(function(k,l){return l.bandwidth-k.bandwidth}):b.sort(function(k,l){return l.height-k.height});var d=fw(a.menu);dk(a.menu);a.menu.appendChild(d);d=a.player.getConfiguration().abr.enabled;
1104
- for(var e={},f=t(b),g=f.next();!g.done;e={Xb:e.Xb},g=f.next()){e.Xb=g.value;g=ck();g.classList.add("explicit-resolution");a.eventManager.o(g,"click",function(k){return function(){var l=k.Xb;a.player.configure({abr:{enabled:!1}});a.player.ze(l,a.controls.i.clearBufferOnQualityChange)}}(e));var h=R("span");h.textContent=a.player.ec()?Math.round(e.Xb.bandwidth/1E3)+" kbits/s":e.Xb.height+"p";g.appendChild(h);d||e.Xb!=c||(g.ariaSelected="true",g.appendChild(iw()),h.classList.add("shaka-chosen-item"),
1105
- a.currentSelection.textContent=h.textContent);a.menu.appendChild(g)}e=ck();e.classList.add("shaka-enable-abr-button");a.eventManager.o(e,"click",function(){a.player.configure({abr:{enabled:!0}});my(a)});a.g=R("span");a.g.classList.add("shaka-auto-span");a.g.textContent=a.localization.resolve("AUTO_QUALITY");e.appendChild(a.g);d&&(e.ariaSelected="true",e.appendChild(iw()),a.g.classList.add("shaka-chosen-item"),a.currentSelection.textContent=a.localization.resolve("AUTO_QUALITY"));a.button.setAttribute("shaka-status",
1106
- a.currentSelection.textContent);a.menu.appendChild(e);hw(a.menu);a.controls.dispatchEvent(new M("resolutionselectionupdated"));ly(a)}
1107
- function ly(a){var b=a.player.ec()?"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"))}J("shaka.ui.ResolutionSelection",ky);function ny(){}
1108
- ny.prototype.create=function(a,b){return new ky(a,b)};fx("quality",new ny);Jw("quality",new ny);function oy(a,b){W.call(this,a,b);var c=this;this.g=ck();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);py(this);this.h=this.controls.i.rewindRates;this.eventManager.o(this.localization,"locale-updated",function(){py(c)});this.eventManager.o(this.localization,"locale-changed",function(){py(c)});
1109
- this.eventManager.o(this.g,"click",function(){if(c.video.duration){var d=c.h.indexOf(c.player.zb())+1;d=d!=c.h.length?c.h[d]:c.h[0];c.player.Ne(d);c.g.setAttribute("shaka-status",d+"x")}})}qa(oy,W);function py(a){a.g.ariaLabel=a.localization.resolve("REWIND")}J("shaka.ui.RewindButton",oy);function qy(){}qy.prototype.create=function(a,b){return new oy(a,b)};Jw("rewind",new qy);function ry(a,b){W.call(this,a,b);var c=this;this.j=R("div");this.j.classList.add("shaka-skip-ad-container");this.parent.appendChild(this.j);this.h=R("div");this.h.classList.add("shaka-skip-ad-counter");X(this.h,!1);this.j.appendChild(this.h);this.g=ck();this.g.classList.add("shaka-skip-ad-button");this.g.disabled=!0;X(this.g,!1);this.g.classList.add("shaka-no-propagation");this.j.appendChild(this.g);sy(this);this.i=new P(function(){var d=Math.round(c.ad.getTimeUntilSkippable());0<d?c.h.textContent=
1110
- d:(c.i.stop(),X(c.h,!1))});this.eventManager.o(this.localization,"locale-updated",function(){sy(c)});this.eventManager.o(this.localization,"locale-changed",function(){sy(c)});this.eventManager.o(this.adManager,"ad-started",function(){ty(c)});this.eventManager.o(this.adManager,"ad-skip-state-changed",function(){c.ad.canSkipNow()&&(c.g.disabled=!1,c.i.stop(),X(c.h,!1))});this.eventManager.o(this.adManager,"ad-stopped",function(){c.i.stop();c.g.disabled=!0;X(c.g,!1);X(c.h,!1)});this.eventManager.o(this.g,
1111
- "click",function(){c.ad.skip()});this.ad&&ty(this)}qa(ry,W);ry.prototype.release=function(){this.i.stop();this.i=null;W.prototype.release.call(this)};function sy(a){a.g.textContent=a.localization.resolve("SKIP_AD")}function ty(a){a.ad.isSkippable()&&(X(a.g,!0),X(a.h,!0),a.h.textContent="",a.i.xa(),a.i.ka(.5))}J("shaka.ui.SkipAdButton",ry);function uy(a,b){nw.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()}qa(uy,nw);uy.prototype.h=function(){this.button.textContent=this.video.ended?"replay":this.isPaused()?"play_arrow":"pause"};uy.prototype.g=function(){if(this.video.ended)this.button.ariaLabel=this.localization.resolve("REPLAY");else{var a=this.isPaused()?"PLAY":"PAUSE";this.button.ariaLabel=this.localization.resolve(a)}};
1112
- J("shaka.ui.SmallPlayButton",uy);function vy(){}vy.prototype.create=function(a,b){return new uy(a,b)};Jw("play_pause",new vy);function wy(a,b){W.call(this,a,b);var c=R("div");c.classList.add("shaka-spacer");c.ariaHidden="true";this.parent.appendChild(c)}qa(wy,W);J("shaka.ui.Spacer",wy);function xy(){}xy.prototype.create=function(a,b){return new wy(a,b)};Jw("spacer",new xy);function yy(a,b){function c(l){return jw(h.h[l],!1)+" (m)"}function d(l){return Math.round(h.h[l]/1E3)+" (kbits/s)"}function e(l){return h.h[l].toFixed(2)+" (s)"}function f(l){return h.h[l]+" (frames)"}function g(l){return h.h[l]+" (px)"}W.call(this,a,b);var h=this;this.i=ck();this.i.classList.add("shaka-statistics-button");this.j=R("i");this.j.classList.add("material-icons-round");this.j.textContent="insert_chart_outlined";this.i.appendChild(this.j);var k=R("label");k.classList.add("shaka-overflow-button-label");
1097
+ document.pictureInPictureEnabled&&!c.video.disablePictureInPicture&&X(c.g,!0)});this.eventManager.o(this.player,"trackschanged",function(){dy(c)})}qa(ay,W);function cy(a){var b;I(function(c){if(1==c.g)return A(c,2),document.pictureInPictureElement?u(c,document.exitPictureInPicture(),5):(document.fullscreenElement&&document.exitFullscreen(),u(c,a.video.requestPictureInPicture(),5));if(2!=c.g)return va(c,0);b=F(c);a.controls.dispatchEvent(new L("error",(new Map).set("detail",b)));z(c)})}
1098
+ function by(a){a.j.textContent=a.localization.resolve("PICTURE_IN_PICTURE");a.g.ariaLabel=a.localization.resolve(document.pictureInPictureElement?"EXIT_PICTURE_IN_PICTURE":"ENTER_PICTURE_IN_PICTURE");a.h.textContent=a.localization.resolve(document.pictureInPictureElement?"ON":"OFF")}
1099
+ function dy(a){I(function(b){if(!document.pictureInPictureEnabled||a.video.disablePictureInPicture)return X(a.g,!1),b.D(0);if(!a.player||!a.player.ec())return X(a.g,!0),b.D(0);X(a.g,!1);return document.pictureInPictureElement?u(b,document.exitPictureInPicture(),0):b.D(0)})}J("shaka.ui.PipButton",ay);function ey(){}ey.prototype.create=function(a,b){return new ay(a,b)};ix("picture_in_picture",new ey);Mw("picture_in_picture",new ey);ww("picture_in_picture",new ey);function fy(a,b){zx.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(){gy(c)});this.eventManager.o(this.localization,"locale-changed",function(){gy(c)});this.eventManager.o(this.player,"ratechange",function(){hy(c,c.player.zb())});this.g=new Map(this.controls.i.playbackRates.map(function(d){return[d+
1100
+ "x",d]}));gy(this);iy(this);hy(this,this.player.zb())}qa(fy,zx);function gy(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")}
1101
+ function hy(a,b){var c=jw(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(lw()),d.ariaSelected="true",c.classList.add("shaka-chosen-item");a.currentSelection.textContent=b+"x";a.button.setAttribute("shaka-status",b+
1102
+ "x")}function iy(a){for(var b={},c=t(a.g.keys()),d=c.next();!d.done;b={uc:b.uc},d=c.next()){b.uc=d.value;d=fk();var e=R("span");e.textContent=b.uc;d.appendChild(e);a.eventManager.o(d,"click",function(f){return function(){a.video.playbackRate=a.g.get(f.uc);a.video.defaultPlaybackRate=a.g.get(f.uc)}}(b));a.menu.appendChild(d)}kw(a.menu)}J("shaka.ui.PlaybackRateSelection",fy);function jy(){}jy.prototype.create=function(a,b){return new fy(a,b)};ix("playback_rate",new jy);Mw("playback_rate",new jy);function ky(a,b){W.call(this,a,b);var c=this;this.g=fk();this.g.classList.add("shaka-current-time");ly(this,"0:00");this.parent.appendChild(this.g);this.eventManager.o(this.g,"click",function(){c.player.U()&&(c.video.currentTime=c.player.Ia().end)});this.eventManager.o(this.controls,"timeandseekrangeupdated",function(){var d=c.controls.$,e=c.controls.qf(),f=c.video.duration,g=c.player.Ia(),h=g.end-g.start;c.player.U()?(e=Math.max(0,Math.floor(g.end-e)),f=3600<=h,1<=e||d?(ly(c,"- "+mw(e,f)),c.g.disabled=
1103
+ !1):(ly(c,c.localization.resolve("LIVE")),c.g.disabled=!0)):(d=3600<=f,e=mw(e,d),f&&(e+=" / "+mw(f,d)),ly(c,e),c.g.disabled=!0)});this.eventManager.o(this.player,"trackschanged",function(){c.player.U()&&(c.g.ariaLabel=c.localization.resolve("SKIP_TO_LIVE"))})}qa(ky,W);function ly(a,b){b!=a.g.textContent&&(a.g.textContent=b)}J("shaka.ui.PresentationTimeTracker",ky);function my(){}my.prototype.create=function(a,b){return new ky(a,b)};Mw("time_and_duration",new my);function ny(a,b){zx.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(){oy(c)});this.eventManager.o(this.localization,"locale-changed",function(){oy(c)});this.eventManager.o(this.player,"variantchanged",function(){py(c)});this.eventManager.o(this.player,"trackschanged",function(){py(c)});this.eventManager.o(this.player,
1104
+ "abrstatuschanged",function(){py(c)});py(this)}qa(ny,zx);
1105
+ function py(a){var b=a.player.Qa(),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){return(a.player.ec()?b.findIndex(function(m){return m.bandwidth==k.bandwidth}):b.findIndex(function(m){return m.height==k.height}))==l});a.player.ec()?b.sort(function(k,l){return l.bandwidth-k.bandwidth}):b.sort(function(k,l){return l.height-k.height});var d=iw(a.menu);gk(a.menu);a.menu.appendChild(d);d=a.player.getConfiguration().abr.enabled;
1106
+ for(var e={},f=t(b),g=f.next();!g.done;e={Xb:e.Xb},g=f.next()){e.Xb=g.value;g=fk();g.classList.add("explicit-resolution");a.eventManager.o(g,"click",function(k){return function(){var l=k.Xb;a.player.configure({abr:{enabled:!1}});a.player.Ae(l,a.controls.i.clearBufferOnQualityChange)}}(e));var h=R("span");h.textContent=a.player.ec()?Math.round(e.Xb.bandwidth/1E3)+" kbits/s":e.Xb.height+"p";g.appendChild(h);d||e.Xb!=c||(g.ariaSelected="true",g.appendChild(lw()),h.classList.add("shaka-chosen-item"),
1107
+ a.currentSelection.textContent=h.textContent);a.menu.appendChild(g)}e=fk();e.classList.add("shaka-enable-abr-button");a.eventManager.o(e,"click",function(){a.player.configure({abr:{enabled:!0}});py(a)});a.g=R("span");a.g.classList.add("shaka-auto-span");a.g.textContent=a.localization.resolve("AUTO_QUALITY");e.appendChild(a.g);d&&(e.ariaSelected="true",e.appendChild(lw()),a.g.classList.add("shaka-chosen-item"),a.currentSelection.textContent=a.localization.resolve("AUTO_QUALITY"));a.button.setAttribute("shaka-status",
1108
+ a.currentSelection.textContent);a.menu.appendChild(e);kw(a.menu);a.controls.dispatchEvent(new L("resolutionselectionupdated"));oy(a)}
1109
+ function oy(a){var b=a.player.ec()?"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"))}J("shaka.ui.ResolutionSelection",ny);function qy(){}
1110
+ qy.prototype.create=function(a,b){return new ny(a,b)};ix("quality",new qy);Mw("quality",new qy);function ry(a,b){W.call(this,a,b);var c=this;this.g=fk();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);sy(this);this.h=this.controls.i.rewindRates;this.eventManager.o(this.localization,"locale-updated",function(){sy(c)});this.eventManager.o(this.localization,"locale-changed",function(){sy(c)});
1111
+ this.eventManager.o(this.g,"click",function(){if(c.video.duration){var d=c.h.indexOf(c.player.zb())+1;d=d!=c.h.length?c.h[d]:c.h[0];c.player.Oe(d);c.g.setAttribute("shaka-status",d+"x")}})}qa(ry,W);function sy(a){a.g.ariaLabel=a.localization.resolve("REWIND")}J("shaka.ui.RewindButton",ry);function ty(){}ty.prototype.create=function(a,b){return new ry(a,b)};Mw("rewind",new ty);function uy(a,b){W.call(this,a,b);var c=this;this.j=R("div");this.j.classList.add("shaka-skip-ad-container");this.parent.appendChild(this.j);this.h=R("div");this.h.classList.add("shaka-skip-ad-counter");X(this.h,!1);this.j.appendChild(this.h);this.g=fk();this.g.classList.add("shaka-skip-ad-button");this.g.disabled=!0;X(this.g,!1);this.g.classList.add("shaka-no-propagation");this.j.appendChild(this.g);vy(this);this.i=new P(function(){var d=Math.round(c.ad.getTimeUntilSkippable());0<d?c.h.textContent=
1112
+ d:(c.i.stop(),X(c.h,!1))});this.eventManager.o(this.localization,"locale-updated",function(){vy(c)});this.eventManager.o(this.localization,"locale-changed",function(){vy(c)});this.eventManager.o(this.adManager,"ad-started",function(){wy(c)});this.eventManager.o(this.adManager,"ad-skip-state-changed",function(){c.ad.canSkipNow()&&(c.g.disabled=!1,c.i.stop(),X(c.h,!1))});this.eventManager.o(this.adManager,"ad-stopped",function(){c.i.stop();c.g.disabled=!0;X(c.g,!1);X(c.h,!1)});this.eventManager.o(this.g,
1113
+ "click",function(){c.ad.skip()});this.ad&&wy(this)}qa(uy,W);uy.prototype.release=function(){this.i.stop();this.i=null;W.prototype.release.call(this)};function vy(a){a.g.textContent=a.localization.resolve("SKIP_AD")}function wy(a){a.ad.isSkippable()&&(X(a.g,!0),X(a.h,!0),a.h.textContent="",a.i.xa(),a.i.ka(.5))}J("shaka.ui.SkipAdButton",uy);function xy(a,b){qw.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()}qa(xy,qw);xy.prototype.h=function(){this.button.textContent=this.video.ended?"replay":this.isPaused()?"play_arrow":"pause"};xy.prototype.g=function(){if(this.video.ended)this.button.ariaLabel=this.localization.resolve("REPLAY");else{var a=this.isPaused()?"PLAY":"PAUSE";this.button.ariaLabel=this.localization.resolve(a)}};
1114
+ J("shaka.ui.SmallPlayButton",xy);function yy(){}yy.prototype.create=function(a,b){return new xy(a,b)};Mw("play_pause",new yy);function zy(a,b){W.call(this,a,b);var c=R("div");c.classList.add("shaka-spacer");c.ariaHidden="true";this.parent.appendChild(c)}qa(zy,W);J("shaka.ui.Spacer",zy);function Ay(){}Ay.prototype.create=function(a,b){return new zy(a,b)};Mw("spacer",new Ay);function By(a,b){function c(l){return mw(h.h[l],!1)+" (m)"}function d(l){return Math.round(h.h[l]/1E3)+" (kbits/s)"}function e(l){return h.h[l].toFixed(2)+" (s)"}function f(l){return h.h[l]+" (frames)"}function g(l){return h.h[l]+" (px)"}W.call(this,a,b);var h=this;this.i=fk();this.i.classList.add("shaka-statistics-button");this.j=R("i");this.j.classList.add("material-icons-round");this.j.textContent="insert_chart_outlined";this.i.appendChild(this.j);var k=R("label");k.classList.add("shaka-overflow-button-label");
1113
1115
  this.A=R("span");k.appendChild(this.A);this.m=R("span");this.m.classList.add("shaka-current-selection-span");k.appendChild(this.m);this.i.appendChild(k);this.parent.appendChild(this.i);this.g=R("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.g.appendChild(this.g);this.F=[];this.G=["stateHistory","switchHistory"];this.h=this.player.getStats();
1114
1116
  this.B={};this.C={width:g,height:g,completionPercent:function(l){return h.h[l]+" (%)"},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(l){return h.h[l]+" (stalls)"},gapsJumped:function(l){return h.h[l]+" (gaps)"}};this.l=new P(function(){h.h=h.player.getStats();for(var l=t(h.F),m=l.next();!m.done;m=
1115
- l.next())m=m.value,h.B[m].textContent=h.C[m](m)});zy(this);Ay(this);this.eventManager.o(this.localization,"locale-updated",function(){zy(h)});this.eventManager.o(this.localization,"locale-changed",function(){zy(h)});this.eventManager.o(this.i,"click",function(){X(h.parent,!1);h.g.classList.contains("shaka-hidden")?(h.j.textContent="insert_chart",h.l.ka(.1),X(h.g,!0)):(h.j.textContent="insert_chart_outlined",h.l.stop(),X(h.g,!1));zy(h)})}qa(yy,W);
1116
- function zy(a){a.A.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")}
1117
- function Ay(a){for(var b=t(a.controls.i.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=R("div"),h=R("label");h.textContent=c+":";g.appendChild(h);h=R("span");h.textContent=f.C[c](c);g.appendChild(h);f.B[c]=h;e.call(d,g);a.F.push(c)}else Ua("Unrecognized statistic element:",c)}yy.prototype.release=function(){this.l.stop();this.l=null;W.prototype.release.call(this)};J("shaka.ui.StatisticsButton",yy);function By(){}
1118
- By.prototype.create=function(a,b){return new yy(a,b)};fx("statistics",new By);tw("statistics",new By);function Cy(a,b){wx.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.Nb()?this.button.ariaPressed="true":this.button.ariaPressed="false";Dy(this);this.eventManager.o(this.localization,"locale-updated",function(){Ey(c);Fy(c)});this.eventManager.o(this.localization,"locale-changed",function(){Ey(c);Fy(c)});this.eventManager.o(this.player,
1119
- "texttrackvisibility",function(){Gy(c);Fy(c)});this.eventManager.o(this.player,"textchanged",function(){Fy(c)});this.eventManager.o(this.player,"trackschanged",function(){Hy(c)});Gy(this);Ey(this);Fy(this);Hy(this)}qa(Cy,wx);function Dy(a){var b=ck();b.ariaSelected="true";a.menu.appendChild(b);b.appendChild(iw());a.g=R("span");a.g.classList.add("shaka-auto-span");b.appendChild(a.g)}
1120
- function Gy(a){a.player.Nb()?(a.icon.textContent="closed_caption_disabled",a.button.ariaPressed="true"):(a.icon.textContent="closed_caption",a.button.ariaPressed="false");a.controls.dispatchEvent(new M("captionselectionupdated"))}
1121
- function Fy(a){var b=a.player.Ab();ux(b,a.menu,function(c){return Iy(a,c)},a.player.Nb(),a.currentSelection,a.localization,a.controls.i.trackLabelFormat);b=ck();b.classList.add("shaka-turn-captions-off-button");a.eventManager.o(b,"click",function(){a.player.He(!1);Fy(a)});b.appendChild(a.g);a.menu.appendChild(b);a.player.Nb()||(b.ariaSelected="true",b.appendChild(iw()),a.g.classList.add("shaka-chosen-item"),a.currentSelection.textContent=a.localization.resolve("OFF"));a.button.setAttribute("shaka-status",
1122
- a.currentSelection.textContent);hw(a.menu);a.controls.dispatchEvent(new M("captionselectionupdated"))}function Iy(a,b){return I(function(c){a.player.ye(b);return u(c,a.player.He(!0),0)})}function Ey(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")}
1123
- function Hy(a){var b=0<a.player.Ab().length;X(a.button,b);Fy(a)}J("shaka.ui.TextSelection",Cy);function Jy(){}Jy.prototype.create=function(a,b){return new Cy(a,b)};fx("captions",new Jy);Jw("captions",new Jy);function Ky(a,b){vw.call(this,a,b,["shaka-volume-bar-container"],["shaka-volume-bar"]);var c=this;this.h=this.controls.i;this.eventManager.o(this.video,"volumechange",function(){return Ly(c)});this.eventManager.o(this.adManager,"ad-volume-changed",function(){return My(c)});this.eventManager.o(this.adManager,"ad-muted",function(){return My(c)});this.eventManager.o(this.adManager,"ad-stopped",function(){return Ly(c)});this.eventManager.o(this.localization,"locale-updated",function(){return Ny(c)});
1124
- this.eventManager.o(this.localization,"locale-changed",function(){return Ny(c)});Ly(this);Ny(this);if(this.ad)this.onChange()}qa(Ky,vw);Ky.prototype.onChange=function(){this.ad&&this.ad.isLinear()?this.ad.setVolume(this.getValue()):(this.video.volume=this.getValue(),this.video.muted=0==this.video.volume?!0:!1)};function Ly(a){a.video.muted?a.setValue(0):a.setValue(a.video.volume);Oy(a)}function My(a){var b=a.ad.getVolume();a.setValue(b);Oy(a)}
1125
- function Oy(a){var b=a.h.volumeBarColors,c=["to right"];c.push(b.level+100*a.getValue()+"%");c.push(b.base+100*a.getValue()+"%");c.push(b.base+"100%");a.container.style.background="linear-gradient("+c.join(",")+")"}function Ny(a){a.bar.ariaLabel=a.localization.resolve("VOLUME")}J("shaka.ui.VolumeBar",Ky);function Py(){}Py.prototype.create=function(a,b){return new Ky(a,b)};Jw("volume",new Py);}).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})();
1117
+ l.next())m=m.value,h.B[m].textContent=h.C[m](m)});Cy(this);Dy(this);this.eventManager.o(this.localization,"locale-updated",function(){Cy(h)});this.eventManager.o(this.localization,"locale-changed",function(){Cy(h)});this.eventManager.o(this.i,"click",function(){X(h.parent,!1);h.g.classList.contains("shaka-hidden")?(h.j.textContent="insert_chart",h.l.ka(.1),X(h.g,!0)):(h.j.textContent="insert_chart_outlined",h.l.stop(),X(h.g,!1));Cy(h)})}qa(By,W);
1118
+ function Cy(a){a.A.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")}
1119
+ function Dy(a){for(var b=t(a.controls.i.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=R("div"),h=R("label");h.textContent=c+":";g.appendChild(h);h=R("span");h.textContent=f.C[c](c);g.appendChild(h);f.B[c]=h;e.call(d,g);a.F.push(c)}else Ua("Unrecognized statistic element:",c)}By.prototype.release=function(){this.l.stop();this.l=null;W.prototype.release.call(this)};J("shaka.ui.StatisticsButton",By);function Ey(){}
1120
+ Ey.prototype.create=function(a,b){return new By(a,b)};ix("statistics",new Ey);ww("statistics",new Ey);function Fy(a,b){zx.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.Nb()?this.button.ariaPressed="true":this.button.ariaPressed="false";Gy(this);this.eventManager.o(this.localization,"locale-updated",function(){Hy(c);Iy(c)});this.eventManager.o(this.localization,"locale-changed",function(){Hy(c);Iy(c)});this.eventManager.o(this.player,
1121
+ "texttrackvisibility",function(){Jy(c);Iy(c)});this.eventManager.o(this.player,"textchanged",function(){Iy(c)});this.eventManager.o(this.player,"trackschanged",function(){Ky(c)});Jy(this);Hy(this);Iy(this);Ky(this)}qa(Fy,zx);function Gy(a){var b=fk();b.ariaSelected="true";a.menu.appendChild(b);b.appendChild(lw());a.g=R("span");a.g.classList.add("shaka-auto-span");b.appendChild(a.g)}
1122
+ function Jy(a){a.player.Nb()?(a.icon.textContent="closed_caption_disabled",a.button.ariaPressed="true"):(a.icon.textContent="closed_caption",a.button.ariaPressed="false");a.controls.dispatchEvent(new L("captionselectionupdated"))}
1123
+ function Iy(a){var b=a.player.Ab();xx(b,a.menu,function(c){return Ly(a,c)},a.player.Nb(),a.currentSelection,a.localization,a.controls.i.trackLabelFormat);b=fk();b.classList.add("shaka-turn-captions-off-button");a.eventManager.o(b,"click",function(){a.player.Ie(!1);Iy(a)});b.appendChild(a.g);a.menu.appendChild(b);a.player.Nb()||(b.ariaSelected="true",b.appendChild(lw()),a.g.classList.add("shaka-chosen-item"),a.currentSelection.textContent=a.localization.resolve("OFF"));a.button.setAttribute("shaka-status",
1124
+ a.currentSelection.textContent);kw(a.menu);a.controls.dispatchEvent(new L("captionselectionupdated"))}function Ly(a,b){return I(function(c){a.player.ze(b);return u(c,a.player.Ie(!0),0)})}function Hy(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")}
1125
+ function Ky(a){var b=0<a.player.Ab().length;X(a.button,b);Iy(a)}J("shaka.ui.TextSelection",Fy);function My(){}My.prototype.create=function(a,b){return new Fy(a,b)};ix("captions",new My);Mw("captions",new My);function Ny(a,b){yw.call(this,a,b,["shaka-volume-bar-container"],["shaka-volume-bar"]);var c=this;this.h=this.controls.i;this.eventManager.o(this.video,"volumechange",function(){return Oy(c)});this.eventManager.o(this.adManager,"ad-volume-changed",function(){return Py(c)});this.eventManager.o(this.adManager,"ad-muted",function(){return Py(c)});this.eventManager.o(this.adManager,"ad-stopped",function(){return Oy(c)});this.eventManager.o(this.localization,"locale-updated",function(){return Qy(c)});
1126
+ this.eventManager.o(this.localization,"locale-changed",function(){return Qy(c)});Oy(this);Qy(this);if(this.ad)this.onChange()}qa(Ny,yw);Ny.prototype.onChange=function(){this.ad&&this.ad.isLinear()?this.ad.setVolume(this.getValue()):(this.video.volume=this.getValue(),this.video.muted=0==this.video.volume?!0:!1)};function Oy(a){a.video.muted?a.setValue(0):a.setValue(a.video.volume);Ry(a)}function Py(a){var b=a.ad.getVolume();a.setValue(b);Ry(a)}
1127
+ function Ry(a){var b=a.h.volumeBarColors,c=["to right"];c.push(b.level+100*a.getValue()+"%");c.push(b.base+100*a.getValue()+"%");c.push(b.base+"100%");a.container.style.background="linear-gradient("+c.join(",")+")"}function Qy(a){a.bar.ariaLabel=a.localization.resolve("VOLUME")}J("shaka.ui.VolumeBar",Ny);function Sy(){}Sy.prototype.create=function(a,b){return new Ny(a,b)};Mw("volume",new Sy);}).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})();
1126
1128
 
1127
1129
  //# sourceMappingURL=shaka-player.ui.map