@theoplayer/extended 6.8.0 → 6.9.0
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.
- package/THEOplayer.chromeless.d.ts +2 -2
- package/THEOplayer.chromeless.esm.js +3 -3
- package/THEOplayer.chromeless.js +3 -3
- package/THEOplayer.common.d.ts +33 -8
- package/THEOplayer.common.esm.js +3 -3
- package/THEOplayer.d.ts +2 -2
- package/THEOplayer.esm.js +3 -3
- package/THEOplayer.js +3 -3
- package/THEOplayer.transmux.asmjs.js +3 -3
- package/THEOplayer.transmux.js +3 -3
- package/package.json +1 -1
- package/theoplayer.d.js +3 -3
package/THEOplayer.esm.js
CHANGED
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
THEOplayer is based on patented technology developed by
|
|
35
35
|
THEO Technologies (https://www.theoplayer.com).
|
|
36
36
|
|
|
37
|
-
Version: 6.
|
|
38
|
-
Created: 2024-01-
|
|
37
|
+
Version: 6.9.0
|
|
38
|
+
Created: 2024-01-30T10:55:59.063Z
|
|
39
39
|
*/
|
|
40
|
-
var s="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:void 0!==a?a:"undefined"!=typeof global?global:this,a=s.window,h=s.document,u=(s.location,s.navigator,s.setTimeout),c=s.clearTimeout,v=(s.setInterval,s.clearInterval,s.Error),p=s.TypeError,m=s.SyntaxError,g=s.Object,w=s.Math,k=s.parseInt,_=s.parseFloat,j=s.isNaN,x=s.Uint8Array;s.Worker,s.WorkerGlobalScope,s.XMLHttpRequest;import{$ as S,$a as T,A as C,Aa as P,B as A,Ba as M,C as I,Ca as E,D,Da as N,E as F,Ea as $,F as B,Fa as R,G as O,Ga as V,H as L,Ha as U,I as H,Ia as z,J as W,Ja as q,K as G,Ka as X,L as J,La as Q,M as Y,Ma as K,N as Z,Na as tt,O as it,Oa as st,P as et,Pa as nt,Q as rt,Qa as ht,R as ot,Ra as at,S as ut,Sa as ct,T as lt,Ta as ft,U as dt,Ua as vt,V as pt,Va as mt,W as gt,Wa as yt,X as bt,Xa as wt,Y as kt,Ya as _t,Z as jt,Za as xt,_ as St,_a as Tt,a as Ct,aa as Pt,ab as At,b as Mt,ba as It,bb as Et,c as Dt,ca as Nt,cb as Ft,d as $t,da as Bt,db as Rt,e as Ot,ea as Vt,eb as Lt,f as Ut,fa as Ht,fb as zt,g as Wt,ga as qt,gb as Gt,h as Xt,ha as Jt,hb as Qt,i as Yt,ia as Kt,ib as Zt,j as ti,ja as ii,jb as si,k as ei,ka as ni,kb as ri,l as hi,la as oi,lb as ai,m as ui,ma as ci,mb as li,n as fi,na as di,nb as vi,o as pi,oa as mi,ob as gi,p as yi,pa as bi,pb as wi,q as ki,qa as _i,qb as ji,r as xi,ra as Si,rb as Ti,s as Ci,sa as Pi,sb as Ai,t as Mi,ta as Ii,tb as Ei,u as Di,ua as Ni,v as Fi,va as $i,w as Bi,wa as Ri,x as Oi,xa as Vi,y as Li,ya as Ui,z as Hi,za as zi}from"./THEOplayer.common.esm.js";var Wi=[];var qi=[];var o=void 0!==a?a:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},Gi=void 0!==h?h:{createElement:function(){}};function Xi(t,i){return i||(i=t.slice(0)),t.raw=i,t}var Ji=1;function Qi(){return Ji++}var Yi,Ki=g.prototype.toString,Zi=function(t){return ss(t)?g.keys(t):[]};function ts(t,i){Zi(t).forEach((function(s){return i(t[s],s)}))}function is(t){for(var i=arguments.length,s=new Array(i>1?i-1:0),e=1;e<i;e++)s[e-1]=arguments[e];return g.assign?g.assign.apply(g,[t].concat(s)):(s.forEach((function(i){i&&ts(i,(function(i,s){t[s]=i}))})),t)}function ss(t){return!!t&&"object"==typeof t}function es(t){return ss(t)&&"[object Object]"===Ki.call(t)&&t.constructor===g}var ns=function(t,i,s){void 0===s&&(s=!!ie&&ie<11),"log"!==t&&i.unshift(t.toUpperCase()+":"),Yi.history.push(i),i.unshift("VIDEOJS:");var e=o.console&&o.console[t];e&&(s&&(i=i.map((function(t){if(ss(t)||Array.isArray(t))try{return JSON.stringify(t)}catch(i){return String(t)}return String(t)})).join(" ")),e.apply?e[Array.isArray(i)?"apply":"call"](o.console,i):e(i))};(Yi=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];ns("log",i)}).history=[],Yi.error=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return ns("error",i)},Yi.warn=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return ns("warn",i)};var n=Yi,rs="undefined"!=typeof globalThis?globalThis:void 0!==a?a:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function hs(t){return t.replace(/\n\r?\s*/g,"")}var os,as=function(t){for(var i="",s=0;s<arguments.length;s++)i+=hs(t[s])+(arguments[s+1]||"");return i};function us(t){return"string"==typeof t&&/\S/.test(t)}function cs(t){if(/\s/.test(t))throw new v("class has illegal whitespace characters")}function ls(){return Gi===o.document&&void 0!==Gi.createElement}function fs(t){return ss(t)&&1===t.nodeType}function ds(t){return function(i,s){if(!us(i))return Gi[t](null);us(s)&&(s=Gi.querySelector(s));var e=fs(s)?s:Gi;return e[t]&&e[t](i)}}function vs(t,i,s,e){void 0===t&&(t="div"),void 0===i&&(i={}),void 0===s&&(s={});var r=Gi.createElement(t);return g.getOwnPropertyNames(i).forEach((function(t){var s=i[t];-1!==t.indexOf("aria-")||"role"===t||"type"===t?(n.warn(as(os||(os=Xi(["Setting attributes in the second argument of createEl()\n has been deprecated. Use the third argument instead.\n createEl(type, properties, attributes). Attempting to set "," to ","."])),t,s)),r.setAttribute(t,s)):"textContent"===t?ps(r,s):r[t]=s})),g.getOwnPropertyNames(s).forEach((function(t){r.setAttribute(t,s[t])})),e&&Ns(r,e),r}function ps(t,i){return void 0===t.textContent?t.innerText=i:t.textContent=i,t}function ms(t,i){i.firstChild?i.insertBefore(t,i.firstChild):i.appendChild(t)}var gs={},ys="vdata"+(new Date).getTime();function bs(t){var i=t[ys];return i||(i=t[ys]=Qi()),gs[i]||(gs[i]={}),gs[i]}function ws(t){var i=t[ys];return!!i&&!!g.getOwnPropertyNames(gs[i]).length}function ks(t){var i=t[ys];if(i){delete gs[i];try{delete t[ys]}catch(i){t.removeAttribute?t.removeAttribute(ys):t[ys]=null}}}function _s(t,i){return cs(i),t.classList?t.classList.contains(i):function(t){return new RegExp("(^|\\s)"+t+"($|\\s)")}(i).test(t.className)}function js(t,i){return t.classList?t.classList.add(i):_s(t,i)||(t.className=(t.className+" "+i).trim()),t}function xs(t,i){return t.classList?t.classList.remove(i):(cs(i),t.className=t.className.split(/\s+/).filter((function(t){return t!==i})).join(" ")),t}function Ss(t,i,s){var e=_s(t,i);if("function"==typeof s&&(s=s(t,i)),"boolean"!=typeof s&&(s=!e),s!==e)return s?js(t,i):xs(t,i),t}function Ts(t,i){g.getOwnPropertyNames(i).forEach((function(s){var e=i[s];null==e||!1===e?t.removeAttribute(s):t.setAttribute(s,!0===e?"":e)}))}function Cs(t){var i={};if(t&&t.attributes&&t.attributes.length>0)for(var s=t.attributes,e=s.length-1;e>=0;e--){var n=s[e].name,r=s[e].value;"boolean"!=typeof t[n]&&-1===",autoplay,controls,playsinline,loop,muted,default,defaultMuted,".indexOf(","+n+",")||(r=null!==r),i[n]=r}return i}function Ps(t,i,s){t.setAttribute(i,s)}function As(t,i){t.removeAttribute(i)}function Ms(t){var i;if(t.getBoundingClientRect&&t.parentNode&&(i=t.getBoundingClientRect()),!i)return{left:0,top:0};var s=Gi.documentElement,e=Gi.body,n=s.clientLeft||e.clientLeft||0,r=o.pageXOffset||e.scrollLeft,h=i.left+r-n,a=s.clientTop||e.clientTop||0,u=o.pageYOffset||e.scrollTop,c=i.top+u-a;return{left:w.round(h),top:w.round(c)}}function Is(t,i){var s={},e=Ms(t),n=t.offsetWidth,r=t.offsetHeight,h=e.top,o=e.left,a=i.pageY,u=i.pageX;return i.changedTouches&&(u=i.changedTouches[0].pageX,a=i.changedTouches[0].pageY),s.y=w.max(0,w.min(1,(h-a+r)/r)),s.x=w.max(0,w.min(1,(u-o)/n)),s}function Es(t){return ss(t)&&3===t.nodeType}function Ds(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function Ns(t,i){return function(t){return"function"==typeof t&&(t=t()),(Array.isArray(t)?t:[t]).map((function(t){return"function"==typeof t&&(t=t()),fs(t)||Es(t)?t:"string"==typeof t&&/\S/.test(t)?Gi.createTextNode(t):void 0})).filter((function(t){return t}))}(i).forEach((function(i){return t.appendChild(i)})),t}function Fs(t,i){return Ns(Ds(t),i)}var y,$s=ds("querySelector"),Bs=ds("querySelectorAll"),Rs=o.navigator&&o.navigator.userAgent||"",Os=/AppleWebKit\/([\d.]+)/i.exec(Rs),Vs=Os?_(Os.pop()):null,Ls=/iPad/i.test(Rs),Us=/iPhone/i.test(Rs)&&!Ls,Hs=/iPod/i.test(Rs),zs=Us||Ls||Hs,Ws=(y=Rs.match(/OS (\d+)_/i))&&y[1]?y[1]:null,qs=/Android/i.test(Rs),Gs=function(){var t=Rs.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!t)return null;var i=t[1]&&_(t[1]),s=t[2]&&_(t[2]);return i&&s?_(t[1]+"."+t[2]):i||null}(),Xs=qs&&/webkit/i.test(Rs)&&Gs<2.3,Js=qs&&Gs<5&&Vs<537,Qs=/Firefox/i.test(Rs),Ys=/Edge/i.test(Rs),Ks=!Ys&&/Chrome/i.test(Rs),Zs=function(){var t=Rs.match(/Chrome\/(\d+)/);return t&&t[1]?_(t[1]):null}(),te=/MSIE\s8\.0/.test(Rs),ie=function(){var t=/MSIE\s(\d+)\.\d/.exec(Rs),i=t&&_(t[1]);return!i&&/Trident\/7.0/i.test(Rs)&&/rv:11.0/.test(Rs)&&(i=11),i}(),se=/Safari/i.test(Rs)&&!Ks&&!qs&&!Ys,ee=se||zs,ne=ls()&&("ontouchstart"in o||o.DocumentTouch&&o.document instanceof o.DocumentTouch),re=ls()&&"backgroundSize"in o.document.createElement("video").style,he=g.freeze({__proto__:null,IS_IPAD:Ls,IS_IPHONE:Us,IS_IPOD:Hs,IS_IOS:zs,IOS_VERSION:Ws,IS_ANDROID:qs,ANDROID_VERSION:Gs,IS_OLD_ANDROID:Xs,IS_NATIVE_ANDROID:Js,IS_FIREFOX:Qs,IS_EDGE:Ys,IS_CHROME:Ks,CHROME_VERSION:Zs,IS_IE8:te,IE_VERSION:ie,IS_SAFARI:se,IS_ANY_SAFARI:ee,TOUCH_ENABLED:ne,BACKGROUND_SIZE_SUPPORTED:re});function oe(t,i){var s=bs(t);0===s.handlers[i].length&&(delete s.handlers[i],t.removeEventListener?t.removeEventListener(i,s.dispatcher,!1):t.detachEvent&&t.detachEvent("on"+i,s.dispatcher)),g.getOwnPropertyNames(s.handlers).length<=0&&(delete s.handlers,delete s.dispatcher,delete s.disabled),0===g.getOwnPropertyNames(s).length&&ks(t)}function ae(t,i,s,e){s.forEach((function(s){t(i,s,e)}))}function ue(t){function i(){return!0}function s(){return!1}if(!t||!t.isPropagationStopped||!t.isImmediatePropagationStopped){var e=t||o.event;for(var n in t={},e)"layerX"!==n&&"layerY"!==n&&"keyLocation"!==n&&"webkitMovementX"!==n&&"webkitMovementY"!==n&&"path"!==n&&("returnValue"===n&&e.preventDefault||(t[n]=e[n]));if(t.target||(t.target=t.srcElement||Gi),t.relatedTarget||(t.relatedTarget=t.fromElement===t.target?t.toElement:t.fromElement),t.preventDefault=function(){e.preventDefault&&e.preventDefault(),t.returnValue=!1,e.returnValue=!1,t.defaultPrevented=!0},t.defaultPrevented=!1,t.stopPropagation=function(){e.stopPropagation&&e.stopPropagation(),t.cancelBubble=!0,e.cancelBubble=!0,t.isPropagationStopped=i},t.isPropagationStopped=s,t.stopImmediatePropagation=function(){e.stopImmediatePropagation&&e.stopImmediatePropagation(),t.isImmediatePropagationStopped=i,t.stopPropagation()},t.isImmediatePropagationStopped=s,null!==t.clientX&&void 0!==t.clientX){var r=Gi.documentElement,h=Gi.body;t.pageX=t.clientX+(r&&r.scrollLeft||h&&h.scrollLeft||0)-(r&&r.clientLeft||h&&h.clientLeft||0),t.pageY=t.clientY+(r&&r.scrollTop||h&&h.scrollTop||0)-(r&&r.clientTop||h&&h.clientTop||0)}t.which=t.charCode||t.keyCode,null!==t.button&&void 0!==t.button&&(t.button=1&t.button?0:4&t.button?1:2&t.button?2:0)}return t}var ce=!1;!function(){try{var t=g.defineProperty({},"passive",{get:function(){ce=!0}});o.addEventListener("test",null,t)}catch(t){}}();var le=["touchstart","touchmove"];function fe(t,i,s){if(Array.isArray(i))return ae(fe,t,i,s);var e=bs(t);if(e.handlers||(e.handlers={}),e.handlers[i]||(e.handlers[i]=[]),s.guid||(s.guid=Qi()),e.handlers[i].push(s),e.dispatcher||(e.disabled=!1,e.dispatcher=function(i,s){if(!e.disabled){i=ue(i);var r=e.handlers[i.type];if(r)for(var h=r.slice(0),o=0,a=h.length;o<a&&!i.isImmediatePropagationStopped();o++)try{h[o].call(t,i,s)}catch(t){n.error(t)}}}),1===e.handlers[i].length)if(t.addEventListener){var r=!1;ce&&le.indexOf(i)>-1&&(r={passive:!0}),t.addEventListener(i,e.dispatcher,r)}else t.attachEvent&&t.attachEvent("on"+i,e.dispatcher)}function de(t,i,s){if(ws(t)){var e=bs(t);if(e.handlers){if(Array.isArray(i))return ae(de,t,i,s);var n=function(i){e.handlers[i]=[],oe(t,i)};if(i){var r=e.handlers[i];if(r)if(s){if(s.guid)for(var h=0;h<r.length;h++)r[h].guid===s.guid&&r.splice(h--,1);oe(t,i)}else n(i)}else for(var o in e.handlers)n(o)}}}function ve(t,i,s){var e=ws(t)?bs(t):{},n=t.parentNode||t.ownerDocument;if("string"==typeof i&&(i={type:i,target:t}),i=ue(i),e.dispatcher&&e.dispatcher.call(t,i,s),n&&!i.isPropagationStopped()&&!0===i.bubbles)ve.call(null,n,i,s);else if(!n&&!i.defaultPrevented){var r=bs(i.target);i.target[i.type]&&(r.disabled=!0,"function"==typeof i.target[i.type]&&i.target[i.type](),r.disabled=!1)}return!i.defaultPrevented}function pe(t,i,s){if(Array.isArray(i))return ae(pe,t,i,s);var e=function e(){de(t,i,e),s.apply(this,arguments)};e.guid=s.guid=s.guid||Qi(),fe(t,i,e)}var me,ge=!1,ye=function(){if(ls()){var t=Gi.getElementsByTagName("video"),i=Gi.getElementsByTagName("audio"),s=[];if(t&&t.length>0)for(var e=0,n=t.length;e<n;e++)s.push(t[e]);if(i&&i.length>0)for(var r=0,h=i.length;r<h;r++)s.push(i[r]);if(s&&s.length>0)for(var o=0,a=s.length;o<a;o++){var u=s[o];if(!u||!u.getAttribute){be(1);break}void 0===u.player&&null!==u.getAttribute("data-setup")&&me(u)}else ge||be(1)}};function be(t,i){i&&(me=i),o.setTimeout(ye,t)}ls()&&"complete"===Gi.readyState?ge=!0:pe(o,"load",(function(){ge=!0}));var we=function(t){var i=Gi.createElement("style");return i.className=t,i},ke=function(t,i){t.styleSheet?t.styleSheet.cssText=i:t.textContent=i},_e=function(t,i,s){i.guid||(i.guid=Qi());var e=function(){return i.apply(t,arguments)};return e.guid=s?s+"_"+i.guid:i.guid,e};function je(t){return"string"!=typeof t?t:t.charAt(0).toUpperCase()+t.slice(1)}function xe(){for(var t={},i=arguments.length,s=new Array(i),e=0;e<i;e++)s[e]=arguments[e];return s.forEach((function(i){i&&ts(i,(function(i,s){es(i)?(es(t[s])||(t[s]={}),t[s]=xe(t[s],i)):t[s]=i}))})),t}var Se=function(){function t(t,i,s){if(!t&&this.play?this.t=t=this:this.t=t,this.h=xe({},this.h),i=this.h=xe(this.h,i),this.o=i.id||i.el&&i.el.id,!this.o){var e=t&&t.id&&t.id()||"no_player";this.o=e+"u"+Qi()}this.l=i.name||null,i.el?this.v=i.el:!1!==i.createEl&&(this.v=this.createEl()),this.m=[],this.k={},this.j={},!1!==i.initChildren&&this.initChildren(),this.ready(s),!1!==i.reportTouchActivity&&this.enableTouchActivity()}var i=t.prototype;return i.dispose=function(){if(this.trigger({type:"dispose",bubbles:!1}),this.m)for(var t=this.m.length-1;t>=0;t--)this.m[t].dispose&&this.m[t].dispose();this.m=null,this.k=null,this.j=null,this.off(),this.v.parentNode&&this.v.parentNode.removeChild(this.v),ks(this.v),this.v=null},i.player=function(){return this.t},i.options=function(t){return n.warn("this.options() has been deprecated and will be moved to the constructor in 6.0"),t?(this.h=xe(this.h,t),this.h):this.h},i.el=function(){return this.v},i.createEl=function(t,i,s){return vs(t,i,s)},i.localize=function(t){var i=this.t.language&&this.t.language(),s=this.t.languages&&this.t.languages();if(!i||!s)return t;var e=s[i];if(e&&e[t])return e[t];var n=s[i.split("-")[0]];return n&&n[t]?n[t]:t},i.contentEl=function(){return this.S||this.v},i.id=function(){return this.o},i.name=function(){return this.l},i.children=function(){return this.m},i.getChildById=function(t){return this.k[t]},i.getChild=function(t){if(t)return t=je(t),this.j[t]},i.addChild=function(i,s,e){var r,h;if(void 0===s&&(s={}),void 0===e&&(e=this.m.length),"string"==typeof i){h=je(i),s||(s={}),!0===s&&(n.warn("Initializing a child component with `true` is deprecated.Children should be defined in an array when possible, but if necessary use an object instead of `true`."),s={});var o=s.componentClass||h;s.name=h;var a=t.getComponent(o);if(!a)throw new v("Component "+o+" does not exist");if("function"!=typeof a)return null;r=new a(this.t||this,s)}else r=i;if(this.m.splice(e,0,r),"function"==typeof r.id&&(this.k[r.id()]=r),(h=h||r.name&&je(r.name()))&&(this.j[h]=r),"function"==typeof r.el&&r.el()){var u=this.contentEl().children[e]||null;this.contentEl().insertBefore(r.el(),u)}return r},i.removeChild=function(t){if("string"==typeof t&&(t=this.getChild(t)),t&&this.m){for(var i=!1,s=this.m.length-1;s>=0;s--)if(this.m[s]===t){i=!0,this.m.splice(s,1);break}if(i){this.k[t.id()]=null,this.j[t.name()]=null;var e=t.el();e&&e.parentNode===this.contentEl()&&this.contentEl().removeChild(t.el())}}},i.initChildren=function(){var i=this,s=this.h.children;if(s){var e,n=this.h,r=t.getComponent("Tech");(e=Array.isArray(s)?s:g.keys(s)).concat(g.keys(this.h).filter((function(t){return!e.some((function(i){return"string"==typeof i?t===i:t===i.name}))}))).map((function(t){var e,n;return"string"==typeof t?n=s[e=t]||i.h[e]||{}:(e=t.name,n=t),{name:e,opts:n}})).filter((function(i){var s=t.getComponent(i.opts.componentClass||je(i.name));return s&&!r.isTech(s)})).forEach((function(t){var s=t.name,e=t.opts;if(void 0!==n[s]&&(e=n[s]),!1!==e){!0===e&&(e={}),e.playerOptions=i.h.playerOptions;var r=i.addChild(s,e);r&&(i[s]=r)}}))}},i.buildCSSClass=function(){return""},i.on=function(t,i,s){var e=this;if("string"==typeof t||Array.isArray(t))fe(this.v,t,_e(this,i));else{var n=t,r=i,h=_e(this,s),o=function(){return e.off(n,r,h)};o.guid=h.guid,this.on("dispose",o);var a=function(){return e.off("dispose",o)};a.guid=h.guid,t.nodeName?(fe(n,r,h),fe(n,"dispose",a)):"function"==typeof t.on&&(n.on(r,h),n.on("dispose",a))}return this},i.off=function(t,i,s){if(!t||"string"==typeof t||Array.isArray(t))de(this.v,t,i);else{var e=t,n=i,r=_e(this,s);this.off("dispose",r),t.nodeName?(de(e,n,r),de(e,"dispose",r)):(e.off(n,r),e.off("dispose",r))}return this},i.one=function(t,i,s){var e=arguments,n=this;if("string"==typeof t||Array.isArray(t))pe(this.v,t,_e(this,i));else{var r=t,h=i,o=_e(this,s),a=function t(){n.off(r,h,t),o.apply(null,e)};a.guid=o.guid,this.on(r,h,a)}return this},i.trigger=function(t,i){return ve(this.v,t,i),this},i.ready=function(t,i){return void 0===i&&(i=!1),t&&(this.T?i?t.call(this):this.setTimeout(t,1):(this.C=this.C||[],this.C.push(t))),this},i.triggerReady=function(){this.T=!0,this.setTimeout((function(){var t=this.C;this.C=[],t&&t.length>0&&t.forEach((function(t){t.call(this)}),this),this.trigger("ready")}),1)},i.$=function(t,i){return $s(t,i||this.contentEl())},i.$$=function(t,i){return Bs(t,i||this.contentEl())},i.hasClass=function(t){return _s(this.v,t)},i.addClass=function(t){return js(this.v,t),this},i.removeClass=function(t){return xs(this.v,t),this},i.toggleClass=function(t,i){return Ss(this.v,t,i),this},i.show=function(){return this.removeClass("vjs-hidden"),this},i.hide=function(){return this.addClass("vjs-hidden"),this},i.lockShowing=function(){return this.addClass("vjs-lock-showing"),this},i.unlockShowing=function(){return this.removeClass("vjs-lock-showing"),this},i.getAttribute=function(t){return function(t,i){return t.getAttribute(i)}(this.v,t)},i.setAttribute=function(t,i){return Ps(this.v,t,i),this},i.removeAttribute=function(t){return As(this.v,t),this},i.width=function(t,i){return this.dimension("width",t,i)},i.height=function(t,i){return this.dimension("height",t,i)},i.dimensions=function(t,i){return this.width(t,!0).height(i)},i.dimension=function(t,i,s){if(void 0!==i)return null!==i&&i==i||(i=0),-1!==(""+i).indexOf("%")||-1!==(""+i).indexOf("px")?this.v.style[t]=i:this.v.style[t]="auto"===i?"":i+"px",s||this.trigger("resize"),this;if(!this.v)return 0;var e=this.v.style[t],n=e.indexOf("px");return k(-1!==n?e.slice(0,n):this.v["offset"+je(t)],10)},i.currentDimension=function(t){var i=0;if("width"!==t&&"height"!==t)throw new v("currentDimension only accepts width or height value");if("function"==typeof o.getComputedStyle){var s=o.getComputedStyle(this.v);i=s.getPropertyValue(t)||s[t]}if(0===(i=_(i))){var e="offset"+je(t);i=this.v[e]}return i},i.currentDimensions=function(){return{width:this.currentDimension("width"),height:this.currentDimension("height")}},i.currentWidth=function(){return this.currentDimension("width")},i.currentHeight=function(){return this.currentDimension("height")},i.focus=function(){this.v.focus()},i.blur=function(){this.v.blur()},i.emitTapEvents=function(){var t,i=0,s=null;this.on("touchstart",(function(e){1===e.touches.length&&(s={pageX:e.touches[0].pageX,pageY:e.touches[0].pageY},i=(new Date).getTime(),t=!0)})),this.on("touchmove",(function(i){if(i.touches.length>1)t=!1;else if(s){var e=i.touches[0].pageX-s.pageX,n=i.touches[0].pageY-s.pageY;w.sqrt(e*e+n*n)>10&&(t=!1)}}));var e=function(){t=!1};this.on("touchleave",e),this.on("touchcancel",e),this.on("touchend",(function(e){(s=null,!0===t)&&((new Date).getTime()-i<200&&(e.preventDefault(),this.trigger("tap")))}))},i.enableTouchActivity=function(){if(this.player()&&this.player().reportUserActivity){var t,i=_e(this.player(),this.player().reportUserActivity);this.on("touchstart",(function(){i(),this.clearInterval(t),t=this.setInterval(i,250)}));var s=function(s){i(),this.clearInterval(t)};this.on("touchmove",i),this.on("touchend",s),this.on("touchcancel",s)}},i.setTimeout=function(t,i){t=_e(this,t);var s=o.setTimeout(t,i),e=function(){this.clearTimeout(s)};return e.guid="vjs-timeout-"+s,this.on("dispose",e),s},i.clearTimeout=function(t){o.clearTimeout(t);var i=function(){};return i.guid="vjs-timeout-"+t,this.off("dispose",i),t},i.setInterval=function(t,i){t=_e(this,t);var s=o.setInterval(t,i),e=function(){this.clearInterval(s)};return e.guid="vjs-interval-"+s,this.on("dispose",e),s},i.clearInterval=function(t){o.clearInterval(t);var i=function(){};return i.guid="vjs-interval-"+t,this.off("dispose",i),t},t.registerComponent=function(i,s){if(i){if(i=je(i),t.P||(t.P={}),"Player"===i&&t.P[i]){var e=t.P[i];if(e.players&&g.keys(e.players).length>0&&g.keys(e.players).map((function(t){return e.players[t]})).every(Boolean))throw new v("Can not register Player component after player has been created")}return t.P[i]=s,s}},t.getComponent=function(i){if(i)return i=je(i),t.P&&t.P[i]?t.P[i]:o&&o.videojs&&o.videojs[i]?(n.warn("The "+i+" component was added to the videojs object when it should be registered using videojs.registerComponent(name, component)"),o.videojs[i]):void 0},t.extend=function(i){i=i||{},n.warn("Component.extend({}) has been deprecated, use videojs.extend(Component, {}) instead");var s=i.init||i.init||this.prototype.init||this.prototype.init||function(){},e=function(){s.apply(this,arguments)};for(var r in(e.prototype=g.create(this.prototype)).constructor=e,e.extend=t.extend,i)i.hasOwnProperty(r)&&(e.prototype[r]=i[r]);return e},t}();Se.registerComponent("Component",Se);var Te=function(){};function Ce(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Pe(t,i){return(Pe=g.setPrototypeOf?g.setPrototypeOf.bind():function(t,i){return t.__proto__=i,t})(t,i)}function Ae(t,i){t.prototype=g.create(i.prototype),t.prototype.constructor=t,Pe(t,i)}function Me(t,i,s,e){return void 0===e&&(n.warn("DEPRECATED: Function '"+t+"' on 'TimeRanges' called without an index argument."),e=0),function(t,i,s){if(i<0||i>s)throw new v("Failed to execute '"+t+"' on 'TimeRanges': The index provided ("+i+") is greater than or equal to the maximum bound ("+s+").")}(t,e,s.length-1),s[e][i]}function Ie(t){return void 0===t||0===t.length?{length:0,start:function(){throw new v("This TimeRanges object is empty")},end:function(){throw new v("This TimeRanges object is empty")}}:{length:t.length,start:Me.bind(null,"start",0,t),end:Me.bind(null,"end",1,t)}}function Ee(t,i){return Array.isArray(t)?Ie(t):void 0===t||void 0===i?Ie():Ie([[t,i]])}function De(t,i){var s,e,n=0;if(!i)return 0;t&&t.length||(t=Ee(0,0));for(var r=0;r<t.length;r++)s=t.start(r),(e=t.end(r))>i&&(e=i),n+=e-s;return n/i}Te.prototype.A={},Te.prototype.on=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},fe(this,t,i),this.addEventListener=s},Te.prototype.addEventListener=Te.prototype.on,Te.prototype.off=function(t,i){de(this,t,i)},Te.prototype.removeEventListener=Te.prototype.off,Te.prototype.one=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},pe(this,t,i),this.addEventListener=s},Te.prototype.trigger=function(t){var i=t.type||t;"string"==typeof t&&(t={type:i}),t=ue(t),this.A[i]&&this["on"+i]&&this["on"+i](t),ve(this,t)},Te.prototype.dispatchEvent=Te.prototype.trigger;var Ne,Fe,$e,Be,Re={prefixed:!0},Oe=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]],Ve=Oe[0];for(Fe=0;Fe<Oe.length;Fe++)if(Oe[Fe][1]in Gi){Ne=Oe[Fe];break}if(Ne){for($e=0;$e<Ne.length;$e++)Re[Ve[$e]]=Ne[$e];Re.prefixed=Ne[0]!==Ve[0]}function Le(t){if(t instanceof Le)return t;"number"==typeof t?this.code=t:"string"==typeof t?this.message=t:ss(t)&&("number"==typeof t.code&&(this.code=t.code),is(this,t)),this.message||(this.message=Le.defaultMessages[this.code]||"")}for(Le.prototype.code=0,Le.prototype.message="",Le.prototype.status=null,Le.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],Le.defaultMessages={1:"You aborted the media playback",2:"A network error caused the media download to fail part-way.",3:"The media playback was aborted due to a corruption problem or because the media used features your browser did not support.",4:"The media could not be loaded, either because the server or network failed or because the format is not supported.",5:"The media is encrypted and we do not have the keys to decrypt it."},Be=0;Be<Le.errorTypes.length;Be++)Le[Le.errorTypes[Be]]=Be,Le.prototype[Le.errorTypes[Be]]=Be;var Ue=function(t,i){var s,e=null;try{s=JSON.parse(t,i)}catch(t){e=t}return[e,s]};var He=function(t){return["kind","label","language","id","inBandMetadataTrackDispatchType","mode","src"].reduce((function(i,s,e){return t[s]&&(i[s]=t[s]),i}),{cues:t.cues&&Array.prototype.map.call(t.cues,(function(t){return{startTime:t.startTime,endTime:t.endTime,text:t.text,id:t.id}}))})},ze=function(t){var i=t.$$("track"),s=Array.prototype.map.call(i,(function(t){return t.track}));return Array.prototype.map.call(i,(function(t){var i=He(t.track);return t.src&&(i.src=t.src),i})).concat(Array.prototype.filter.call(t.textTracks(),(function(t){return-1===s.indexOf(t)})).map(He))},We=function(t,i){return t.forEach((function(t){var s=i.addRemoteTextTrack(t).track;!t.src&&t.cues&&t.cues.forEach((function(t){return s.addCue(t)}))})),i.textTracks()},qe="vjs-modal-dialog",Ge=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).M=e.I=e.D=!1,e.closeable(!e.h.uncloseable),e.content(e.h.content),e.S=vs("div",{className:qe+"-content"},{role:"document"}),e.N=vs("p",{className:qe+"-description vjs-offscreen",id:e.el().getAttribute("aria-describedby")}),ps(e.N,e.description()),e.v.appendChild(e.N),e.v.appendChild(e.S),e.on(i,"languagechange",e.handleLanguagechange),e}Ae(i,t);var s=i.prototype;return s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-describedby":this.id()+"F","aria-hidden":"true","aria-label":this.label(),role:"dialog"})},s.buildCSSClass=function(){return qe+" vjs-hidden "+t.prototype.buildCSSClass.call(this)},s.handleKeyPress=function(t){27===t.which&&this.closeable()&&this.close()},s.label=function(){return this.h.label||this.localize("Modal Window")},s.description=function(){var t=this.h.description||this.localize("This is a modal window.");return this.closeable()&&(t+=" "+this.localize("This modal can be closed by pressing the Escape key or activating the close button.")),t},s.open=function(){if(!this.M){var t=this.player();this.trigger("beforemodalopen"),this.M=!0,(this.h.fillAlways||!this.I&&!this.D)&&this.fill(),this.B=!t.paused(),this.h.pauseOnOpen&&this.B&&t.pause(),this.closeable()&&this.on(this.v.ownerDocument,"keydown",_e(this,this.handleKeyPress)),t.controls(!1),this.show(),this.el().setAttribute("aria-hidden","false"),this.trigger("modalopen"),this.I=!0}return this},s.opened=function(t){return"boolean"==typeof t&&this[t?"open":"close"](),this.M},s.close=function(){if(this.M){var t=this.player();this.trigger("beforemodalclose"),this.M=!1,this.B&&this.h.pauseOnOpen&&t.play(),this.closeable()&&this.off(this.v.ownerDocument,"keydown",_e(this,this.handleKeyPress)),t.controls(!0),this.hide(),this.el().setAttribute("aria-hidden","true"),this.trigger("modalclose"),this.h.temporary&&this.dispose()}return this},s.closeable=function(t){if("boolean"==typeof t){var i=this.R=!!t,s=this.getChild("closeButton");if(i&&!s){var e=this.S;this.S=this.v,s=this.addChild("closeButton",{controlText:"Close Modal Dialog"}),this.S=e,this.on(s,"close",this.close)}!i&&s&&(this.off(s,"close",this.close),this.removeChild(s),s.dispose())}return this.R},s.fill=function(){return this.fillWith(this.content())},s.fillWith=function(t){var i=this.contentEl(),s=i.parentNode,e=i.nextSibling;return this.trigger("beforemodalfill"),this.D=!0,s.removeChild(i),this.empty(),Fs(i,t),this.trigger("modalfill"),e?s.insertBefore(i,e):s.appendChild(i),this},s.empty=function(){return this.trigger("beforemodalempty"),Ds(this.contentEl()),this.trigger("modalempty"),this},s.content=function(t){return void 0!==t&&(this.O=t),this.O},s.handleLanguagechange=function(){this.v.setAttribute("aria-label",this.label()),ps(this.N,this.description()),this.opened()?this.fill():(this.I||this.D)&&(this.I=!1,this.D=!1,this.empty())},i}(Se);Ge.prototype.h={pauseOnOpen:!0,temporary:!0},Se.registerComponent("ModalDialog",Ge);var Xe=function(){function t(i){var s=this;if(te)for(var e in s=Gi.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);if(t.prototype.V.call(s,i),g.defineProperty(s,"length",{get:function(){return this.L}}),te)return s}var i=t.prototype;return i.V=function(t){var i=this.length||0,s=0,e=t.length;this.U=t,this.L=t.length;var n=function(t){""+t in this||g.defineProperty(this,""+t,{get:function(){return this.U[t]}})};if(i<e)for(s=i;s<e;s++)n.call(this,s)},i.getCueById=function(t){for(var i=null,s=0,e=this.length;s<e;s++){var n=this[s];if(n.id===t){i=n;break}}return i},t}(),Je={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},Qe={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},Ye={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},Ke={disabled:"disabled",hidden:"hidden",showing:"showing"},Ze=function(t){function i(s){var e;void 0===s&&(s={});var n=Ce(e=t.call(this)||this);if(te)for(var r in n=Gi.createElement("custom"),i.prototype)"constructor"!==r&&(n[r]=i.prototype[r]);var h={id:s.id||["vjs_track",Qi()].join("_"),kind:s.kind||"",label:s.label||"",language:s.language||""},o=function(t){g.defineProperty(n,t,{get:function(){return h[t]},set:function(){}})};for(var a in h)o(a);return n||Ce(e)}return Ae(i,t),i}(Te),tn=function(t){var i=["protocol","hostname","port","pathname","search","hash","host"],s=Gi.createElement("a");s.href=t;var e,n=""===s.host&&"file:"!==s.protocol;n&&((e=Gi.createElement("div")).innerHTML='<a href="'+t+'"></a>',s=e.firstChild,e.setAttribute("style","display:none; position:absolute;"),Gi.body.appendChild(e));for(var r={},h=0;h<i.length;h++)r[i[h]]=s[i[h]];return"http:"===r.protocol&&(r.host=r.host.replace(/:80$/,"")),"https:"===r.protocol&&(r.host=r.host.replace(/:443$/,"")),n&&Gi.body.removeChild(e),r},sn=function(t){var i=o.location,s=tn(t);return(":"===s.protocol?i.protocol:s.protocol)+s.host!==i.protocol+i.host},en={exports:{}};void 0!==a?en.exports=a:void 0!==rs?en.exports=rs:"undefined"!=typeof self?en.exports=self:en.exports={};var nn=function(t){var i=rn.call(t);return"[object Function]"===i||"function"==typeof t&&"[object RegExp]"!==i||void 0!==a&&(t===a.setTimeout||t===a.alert||t===a.confirm||t===a.prompt)},rn=g.prototype.toString;var hn,on,an,un,cn,ln,fn,dn,vn,pn,mn,gn,yn=Array.prototype.slice,bn=g.prototype.toString,wn=function(t){var i=this;if("function"!=typeof i||"[object Function]"!==bn.call(i))throw new p("Function.prototype.bind called on incompatible "+i);for(var s,e=yn.call(arguments,1),n=w.max(0,i.length-e.length),r=[],h=0;h<n;h++)r.push("$"+h);if(s=Function("binder","return function ("+r.join(",")+"){ return binder.apply(this,arguments); }")((function(){if(this instanceof s){var n=i.apply(this,e.concat(yn.call(arguments)));return g(n)===n?n:this}return i.apply(t,e.concat(yn.call(arguments)))})),i.prototype){var o=function(){};o.prototype=i.prototype,s.prototype=new o,o.prototype=null}return s},kn=Function.prototype.bind||wn,_n=g.prototype.toString,jn=function(t){var i=_n.call(t),s="[object Arguments]"===i;return s||(s="[object Array]"!==i&&null!==t&&"object"==typeof t&&"number"==typeof t.length&&t.length>=0&&"[object Function]"===_n.call(t.callee)),s};g.keys||(on=g.prototype.hasOwnProperty,an=g.prototype.toString,un=jn,cn=g.prototype.propertyIsEnumerable,ln=!cn.call({toString:null},"toString"),fn=cn.call((function(){}),"prototype"),dn=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],vn=function(t){var i=t.constructor;return i&&i.prototype===t},pn={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},mn=function(){if(void 0===a)return!1;for(var t in a)try{if(!pn["$"+t]&&on.call(a,t)&&null!==a[t]&&"object"==typeof a[t])try{vn(a[t])}catch(t){return!0}}catch(t){return!0}return!1}(),gn=function(t){if(void 0===a||!mn)return vn(t);try{return vn(t)}catch(t){return!1}},hn=function(t){var i=null!==t&&"object"==typeof t,s="[object Function]"===an.call(t),e=un(t),n=i&&"[object String]"===an.call(t),r=[];if(!i&&!s&&!e)throw new p("Object.keys called on a non-object");var h=fn&&s;if(n&&t.length>0&&!on.call(t,0))for(var o=0;o<t.length;++o)r.push(String(o));if(e&&t.length>0)for(var a=0;a<t.length;++a)r.push(String(a));else for(var u in t)h&&"prototype"===u||!on.call(t,u)||r.push(String(u));if(ln)for(var c=gn(t),l=0;l<dn.length;++l)c&&"constructor"===dn[l]||!on.call(t,dn[l])||r.push(dn[l]);return r});var xn=hn,Sn=Array.prototype.slice,Tn=jn,Cn=g.keys,Pn=Cn?function(t){return Cn(t)}:xn,An=g.keys;Pn.shim=function(){if(g.keys){var t=function(){var t=g.keys(arguments);return t&&t.length===arguments.length}(1,2);t||(g.keys=function(t){return Tn(t)?An(Sn.call(t)):An(t)})}else g.keys=Pn;return g.keys||Pn};var Mn=Pn,In="function"==typeof Symbol&&"symbol"==typeof Symbol("foo"),En=g.prototype.toString,Dn=Array.prototype.concat,Nn=g.defineProperty,Fn=Nn&&function(){var t={};try{for(var i in Nn(t,"x",{enumerable:!1,value:t}),t)return!1;return t.x===t}catch(t){return!1}}(),$n=function(t,i,s,e){(!(i in t)||function(t){return"function"==typeof t&&"[object Function]"===En.call(t)}(e)&&e())&&(Fn?Nn(t,i,{configurable:!0,enumerable:!1,value:s,writable:!0}):t[i]=s)},Bn=function(t,i){var s=arguments.length>2?arguments[2]:{},e=Mn(i);In&&(e=Dn.call(e,g.getOwnPropertySymbols(i)));for(var n=0;n<e.length;n+=1)$n(t,e[n],i[e[n]],s[e[n]])};Bn.supportsDescriptors=!!Fn;var Rn,On=Bn,Vn=g.getOwnPropertyDescriptor?function(){return g.getOwnPropertyDescriptor(arguments,"callee").get}():function(){throw new p},Ln="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator,Un=g.getPrototypeOf||function(t){return t.__proto__},Hn=void 0===x?Rn:Un(x),zn={"$ %Array%":Array,"$ %ArrayBuffer%":"undefined"==typeof ArrayBuffer?Rn:ArrayBuffer,"$ %ArrayBufferPrototype%":"undefined"==typeof ArrayBuffer?Rn:ArrayBuffer.prototype,"$ %ArrayIteratorPrototype%":Ln?Un([][Symbol.iterator]()):Rn,"$ %ArrayPrototype%":Array.prototype,"$ %ArrayProto_entries%":Array.prototype.entries,"$ %ArrayProto_forEach%":Array.prototype.forEach,"$ %ArrayProto_keys%":Array.prototype.keys,"$ %ArrayProto_values%":Array.prototype.values,"$ %AsyncFromSyncIteratorPrototype%":Rn,"$ %AsyncFunction%":undefined,"$ %AsyncFunctionPrototype%":Rn,"$ %AsyncGenerator%":Rn,"$ %AsyncGeneratorFunction%":undefined,"$ %AsyncGeneratorPrototype%":Rn,"$ %AsyncIteratorPrototype%":Rn,"$ %Atomics%":"undefined"==typeof Atomics?Rn:Atomics,"$ %Boolean%":Boolean,"$ %BooleanPrototype%":Boolean.prototype,"$ %DataView%":"undefined"==typeof DataView?Rn:DataView,"$ %DataViewPrototype%":"undefined"==typeof DataView?Rn:DataView.prototype,"$ %Date%":Date,"$ %DatePrototype%":Date.prototype,"$ %decodeURI%":decodeURI,"$ %decodeURIComponent%":decodeURIComponent,"$ %encodeURI%":encodeURI,"$ %encodeURIComponent%":encodeURIComponent,"$ %Error%":v,"$ %ErrorPrototype%":v.prototype,"$ %eval%":eval,"$ %EvalError%":EvalError,"$ %EvalErrorPrototype%":EvalError.prototype,"$ %Float32Array%":"undefined"==typeof Float32Array?Rn:Float32Array,"$ %Float32ArrayPrototype%":"undefined"==typeof Float32Array?Rn:Float32Array.prototype,"$ %Float64Array%":"undefined"==typeof Float64Array?Rn:Float64Array,"$ %Float64ArrayPrototype%":"undefined"==typeof Float64Array?Rn:Float64Array.prototype,"$ %Function%":Function,"$ %FunctionPrototype%":Function.prototype,"$ %Generator%":Rn,"$ %GeneratorFunction%":undefined,"$ %GeneratorPrototype%":Rn,"$ %Int8Array%":"undefined"==typeof Int8Array?Rn:Int8Array,"$ %Int8ArrayPrototype%":"undefined"==typeof Int8Array?Rn:Int8Array.prototype,"$ %Int16Array%":"undefined"==typeof Int16Array?Rn:Int16Array,"$ %Int16ArrayPrototype%":"undefined"==typeof Int16Array?Rn:Int8Array.prototype,"$ %Int32Array%":"undefined"==typeof Int32Array?Rn:Int32Array,"$ %Int32ArrayPrototype%":"undefined"==typeof Int32Array?Rn:Int32Array.prototype,"$ %isFinite%":isFinite,"$ %isNaN%":j,"$ %IteratorPrototype%":Ln?Un(Un([][Symbol.iterator]())):Rn,"$ %JSON%":JSON,"$ %JSONParse%":JSON.parse,"$ %Map%":"undefined"==typeof Map?Rn:Map,"$ %MapIteratorPrototype%":"undefined"!=typeof Map&&Ln?Un((new Map)[Symbol.iterator]()):Rn,"$ %MapPrototype%":"undefined"==typeof Map?Rn:Map.prototype,"$ %Math%":w,"$ %Number%":Number,"$ %NumberPrototype%":Number.prototype,"$ %Object%":g,"$ %ObjectPrototype%":g.prototype,"$ %ObjProto_toString%":g.prototype.toString,"$ %ObjProto_valueOf%":g.prototype.valueOf,"$ %parseFloat%":_,"$ %parseInt%":k,"$ %Promise%":"undefined"==typeof Promise?Rn:Promise,"$ %PromisePrototype%":"undefined"==typeof Promise?Rn:Promise.prototype,"$ %PromiseProto_then%":"undefined"==typeof Promise?Rn:Promise.prototype.then,"$ %Promise_all%":"undefined"==typeof Promise?Rn:Promise.all,"$ %Promise_reject%":"undefined"==typeof Promise?Rn:Promise.reject,"$ %Promise_resolve%":"undefined"==typeof Promise?Rn:Promise.resolve,"$ %Proxy%":"undefined"==typeof Proxy?Rn:Proxy,"$ %RangeError%":RangeError,"$ %RangeErrorPrototype%":RangeError.prototype,"$ %ReferenceError%":ReferenceError,"$ %ReferenceErrorPrototype%":ReferenceError.prototype,"$ %Reflect%":"undefined"==typeof Reflect?Rn:Reflect,"$ %RegExp%":RegExp,"$ %RegExpPrototype%":RegExp.prototype,"$ %Set%":"undefined"==typeof Set?Rn:Set,"$ %SetIteratorPrototype%":"undefined"!=typeof Set&&Ln?Un((new Set)[Symbol.iterator]()):Rn,"$ %SetPrototype%":"undefined"==typeof Set?Rn:Set.prototype,"$ %SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?Rn:SharedArrayBuffer,"$ %SharedArrayBufferPrototype%":"undefined"==typeof SharedArrayBuffer?Rn:SharedArrayBuffer.prototype,"$ %String%":String,"$ %StringIteratorPrototype%":Ln?Un(""[Symbol.iterator]()):Rn,"$ %StringPrototype%":String.prototype,"$ %Symbol%":Ln?Symbol:Rn,"$ %SymbolPrototype%":Ln?Symbol.prototype:Rn,"$ %SyntaxError%":m,"$ %SyntaxErrorPrototype%":m.prototype,"$ %ThrowTypeError%":Vn,"$ %TypedArray%":Hn,"$ %TypedArrayPrototype%":Hn?Hn.prototype:Rn,"$ %TypeError%":p,"$ %TypeErrorPrototype%":p.prototype,"$ %Uint8Array%":void 0===x?Rn:x,"$ %Uint8ArrayPrototype%":void 0===x?Rn:x.prototype,"$ %Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?Rn:Uint8ClampedArray,"$ %Uint8ClampedArrayPrototype%":"undefined"==typeof Uint8ClampedArray?Rn:Uint8ClampedArray.prototype,"$ %Uint16Array%":"undefined"==typeof Uint16Array?Rn:Uint16Array,"$ %Uint16ArrayPrototype%":"undefined"==typeof Uint16Array?Rn:Uint16Array.prototype,"$ %Uint32Array%":"undefined"==typeof Uint32Array?Rn:Uint32Array,"$ %Uint32ArrayPrototype%":"undefined"==typeof Uint32Array?Rn:Uint32Array.prototype,"$ %URIError%":URIError,"$ %URIErrorPrototype%":URIError.prototype,"$ %WeakMap%":"undefined"==typeof WeakMap?Rn:WeakMap,"$ %WeakMapPrototype%":"undefined"==typeof WeakMap?Rn:WeakMap.prototype,"$ %WeakSet%":"undefined"==typeof WeakSet?Rn:WeakSet,"$ %WeakSetPrototype%":"undefined"==typeof WeakSet?Rn:WeakSet.prototype},Wn=function(t,i){if(arguments.length>1&&"boolean"!=typeof i)throw new p('"allowMissing" argument must be a boolean');var s="$ "+t;if(!(s in zn))throw new m("intrinsic "+t+" does not exist!");if(void 0===zn[s]&&!i)throw new p("intrinsic "+t+" exists, but is not available. Please file an issue!");return zn[s]},qn=kn.call(Function.call,g.prototype.hasOwnProperty),Gn=Wn,Xn=Gn("%TypeError%"),Jn=Gn("%SyntaxError%"),Qn=qn,Yn={"Property Descriptor":function(t,i){if("Object"!==t.Type(i))return!1;var s={"[[Configurable]]":!0,"[[Enumerable]]":!0,"[[Get]]":!0,"[[Set]]":!0,"[[Value]]":!0,"[[Writable]]":!0};for(var e in i)if(Qn(i,e)&&!s[e])return!1;var n=Qn(i,"[[Value]]"),r=Qn(i,"[[Get]]")||Qn(i,"[[Set]]");if(n&&r)throw new Xn("Property Descriptors may not be both accessor and data descriptors");return!0}},Kn=Number.isNaN||function(t){return t!=t},Zn=Number.isNaN||function(t){return t!=t},tr=Number.isFinite||function(t){return"number"==typeof t&&!Zn(t)&&t!==1/0&&t!==-1/0},ir=Function.prototype.toString,sr=/^\s*class\b/,er=function(t){try{var i=ir.call(t);return sr.test(i)}catch(t){return!1}},nr=g.prototype.toString,rr="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,hr=function(t){if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if("function"==typeof t&&!t.prototype)return!0;if(rr)return function(t){try{return!er(t)&&(ir.call(t),!0)}catch(t){return!1}}(t);if(er(t))return!1;var i=nr.call(t);return"[object Function]"===i||"[object GeneratorFunction]"===i},or=g.prototype.toString,ar=function(t){return null===t||"function"!=typeof t&&"object"!=typeof t},ur=hr,cr=function(t){var i;if((i=arguments.length>1?arguments[1]:"[object Date]"===or.call(t)?String:Number)===String||i===Number){var s,e,n=i===String?["toString","valueOf"]:["valueOf","toString"];for(e=0;e<n.length;++e)if(ur(t[n[e]])&&(s=t[n[e]](),ar(s)))return s;throw new p("No default value")}throw new p("invalid [[DefaultValue]] hint supplied")},lr=Wn,fr=lr("%Object%"),dr=lr("%TypeError%"),vr=lr("%String%"),pr=function(t,i,s,e){var n=Yn[i];if("function"!=typeof n)throw new Jn("unknown record type: "+i);if(!n(t,e))throw new Xn(s+" must be a "+i);console.log(n(t,e),e)},mr=Kn,gr=tr,yr=function(t){return t>=0?1:-1},br=function(t,i){var s=t%i;return w.floor(s>=0?s:s+i)},wr=qn,kr={ToPrimitive:function(t){return ar(t)?t:arguments.length>1?cr(t,arguments[1]):cr(t)},ToBoolean:function(t){return!!t},ToNumber:function(t){return+t},ToInteger:function(t){var i=this.ToNumber(t);return mr(i)?0:0!==i&&gr(i)?yr(i)*w.floor(w.abs(i)):i},ToInt32:function(t){return this.ToNumber(t)>>0},ToUint32:function(t){return this.ToNumber(t)>>>0},ToUint16:function(t){var i=this.ToNumber(t);if(mr(i)||0===i||!gr(i))return 0;var s=yr(i)*w.floor(w.abs(i));return br(s,65536)},ToString:function(t){return vr(t)},ToObject:function(t){return this.CheckObjectCoercible(t),fr(t)},CheckObjectCoercible:function(t,i){if(null==t)throw new dr(i||"Cannot call method on "+t);return t},IsCallable:hr,SameValue:function(t,i){return t===i?0!==t||1/t==1/i:mr(t)&&mr(i)},Type:function(t){return null===t?"Null":void 0===t?"Undefined":"function"==typeof t||"object"==typeof t?"Object":"number"==typeof t?"Number":"boolean"==typeof t?"Boolean":"string"==typeof t?"String":void 0},IsPropertyDescriptor:function(t){if("Object"!==this.Type(t))return!1;var i={"[[Configurable]]":!0,"[[Enumerable]]":!0,"[[Get]]":!0,"[[Set]]":!0,"[[Value]]":!0,"[[Writable]]":!0};for(var s in t)if(wr(t,s)&&!i[s])return!1;var e=wr(t,"[[Value]]"),n=wr(t,"[[Get]]")||wr(t,"[[Set]]");if(e&&n)throw new dr("Property Descriptors may not be both accessor and data descriptors");return!0},IsAccessorDescriptor:function(t){return void 0!==t&&(pr(this,"Property Descriptor","Desc",t),!(!wr(t,"[[Get]]")&&!wr(t,"[[Set]]")))},IsDataDescriptor:function(t){return void 0!==t&&(pr(this,"Property Descriptor","Desc",t),!(!wr(t,"[[Value]]")&&!wr(t,"[[Writable]]")))},IsGenericDescriptor:function(t){return void 0!==t&&(pr(this,"Property Descriptor","Desc",t),!this.IsAccessorDescriptor(t)&&!this.IsDataDescriptor(t))},FromPropertyDescriptor:function(t){if(void 0===t)return t;if(pr(this,"Property Descriptor","Desc",t),this.IsDataDescriptor(t))return{value:t["[[Value]]"],writable:!!t["[[Writable]]"],enumerable:!!t["[[Enumerable]]"],configurable:!!t["[[Configurable]]"]};if(this.IsAccessorDescriptor(t))return{get:t["[[Get]]"],set:t["[[Set]]"],enumerable:!!t["[[Enumerable]]"],configurable:!!t["[[Configurable]]"]};throw new dr("FromPropertyDescriptor must be called with a fully populated Property Descriptor")},ToPropertyDescriptor:function(t){if("Object"!==this.Type(t))throw new dr("ToPropertyDescriptor requires an object");var i={};if(wr(t,"enumerable")&&(i["[[Enumerable]]"]=this.ToBoolean(t.enumerable)),wr(t,"configurable")&&(i["[[Configurable]]"]=this.ToBoolean(t.configurable)),wr(t,"value")&&(i["[[Value]]"]=t.value),wr(t,"writable")&&(i["[[Writable]]"]=this.ToBoolean(t.writable)),wr(t,"get")){var s=t.get;if(void 0!==s&&!this.IsCallable(s))throw new p("getter must be a function");i["[[Get]]"]=s}if(wr(t,"set")){var e=t.set;if(void 0!==e&&!this.IsCallable(e))throw new dr("setter must be a function");i["[[Set]]"]=e}if((wr(i,"[[Get]]")||wr(i,"[[Set]]"))&&(wr(i,"[[Value]]")||wr(i,"[[Writable]]")))throw new dr("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return i}},_r=kn.call(Function.call,String.prototype.replace),jr=/^[\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF]+/,xr=/[\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF]+$/,Sr=function(){var t=kr.ToString(kr.CheckObjectCoercible(this));return _r(_r(t,jr,""),xr,"")},Tr=Sr,Cr=function(){return String.prototype.trim&&"\u200b"==="\u200b".trim()?String.prototype.trim:Tr},Pr=On,Ar=Cr,Mr=On,Ir=Sr,Er=Cr,Dr=function(){var t=Ar();return Pr(String.prototype,{trim:t},{trim:function(){return String.prototype.trim!==t}}),t},Nr=kn.call(Function.call,Er());Mr(Nr,{getPolyfill:Er,implementation:Ir,shim:Dr});var Fr=Nr,$r=hr,Br=g.prototype.toString,Rr=g.prototype.hasOwnProperty,Or=Fr,Vr=function(t,i,s){if(!$r(i))throw new p("iterator must be a function");var e;arguments.length>=3&&(e=s),"[object Array]"===Br.call(t)?function(t,i,s){for(var e=0,n=t.length;e<n;e++)Rr.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))}(t,i,e):"string"==typeof t?function(t,i,s){for(var e=0,n=t.length;e<n;e++)null==s?i(t.charAt(e),e,t):i.call(s,t.charAt(e),e,t)}(t,i,e):function(t,i,s){for(var e in t)Rr.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))}(t,i,e)},Lr=function(){for(var t={},i=0;i<arguments.length;i++){var s=arguments[i];for(var e in s)Ur.call(s,e)&&(t[e]=s[e])}return t},Ur=g.prototype.hasOwnProperty;var Hr=en.exports,zr=nn,Wr=function(t){if(!t)return{};var i={};return Vr(Or(t).split("\n"),(function(t){var s=t.indexOf(":"),e=Or(t.slice(0,s)).toLowerCase(),n=Or(t.slice(s+1));void 0===i[e]?i[e]=n:!function(t){return"[object Array]"===g.prototype.toString.call(t)}(i[e])?i[e]=[i[e],n]:i[e].push(n)})),i},qr=Lr,Gr=Jr;function Xr(t,i,s){var e=t;return zr(i)?(s=i,"string"==typeof t&&(e={uri:t})):e=qr(i,{uri:t}),e.callback=s,e}function Jr(t,i,s){return Qr(i=Xr(t,i,s))}function Qr(t){if(void 0===t.callback)throw new v("callback argument missing");var i=!1,s=function(s,e,n){i||(i=!0,t.callback(s,e,n))};function e(){var t=void 0;if(t=l.response?l.response:l.responseText||function(t){if("document"===t.responseType)return t.responseXML;var i=204===t.status&&t.responseXML&&"parsererror"===t.responseXML.documentElement.nodeName;if(""===t.responseType&&!i)return t.responseXML;return null}(l),b)try{t=JSON.parse(t)}catch(t){}return t}var n={body:void 0,headers:{},statusCode:0,method:p,url:d,rawRequest:l};function r(t){return c(f),t instanceof v||(t=new v(""+(t||"Unknown XMLHttpRequest Error"))),t.statusCode=0,s(t,n)}function h(){if(!a){var i;c(f),i=t.useXDR&&void 0===l.status?200:1223===l.status?204:l.status;var r=n,h=null;return 0!==i?(r={body:e(),statusCode:i,method:p,headers:{},url:d,rawRequest:l},l.getAllResponseHeaders&&(r.headers=Wr(l.getAllResponseHeaders()))):h=new v("Internal XMLHttpRequest Error"),s(h,r,r.body)}}var o,a,l=t.xhr||null;l||(l=t.cors||t.useXDR?new Jr.XDomainRequest:new Jr.XMLHttpRequest);var f,d=l.url=t.uri||t.url,p=l.method=t.method||"GET",m=t.body||t.data||null,g=l.headers=t.headers||{},y=!!t.sync,b=!1;if("json"in t&&(b=!0,g.accept||g.Accept||(g.Accept="application/json"),"GET"!==p&&"HEAD"!==p&&(g["content-type"]||g["Content-Type"]||(g["Content-Type"]="application/json"),m=JSON.stringify(t.json))),l.onreadystatechange=function(){4===l.readyState&&h()},l.onload=h,l.onerror=r,l.onprogress=function(){},l.ontimeout=r,l.open(p,d,!y,t.username,t.password),y||(l.withCredentials=!!t.withCredentials),!y&&t.timeout>0&&(f=u((function(){a=!0,l.abort("timeout");var t=new v("XMLHttpRequest timeout");t.code="ETIMEDOUT",r(t)}),t.timeout)),l.setRequestHeader)for(o in g)g.hasOwnProperty(o)&&l.setRequestHeader(o,g[o]);else if(t.headers&&!function(t){for(var i in t)if(t.hasOwnProperty(i))return!1;return!0}(t.headers))throw new v("Headers cannot be set on an XDomainRequest object");return"responseType"in t&&(l.responseType=t.responseType),"beforeSend"in t&&"function"==typeof t.beforeSend&&t.beforeSend(l),l.send(m),l}Jr.XMLHttpRequest=Hr.XMLHttpRequest||function(){},Jr.XDomainRequest="withCredentials"in new Jr.XMLHttpRequest?Jr.XMLHttpRequest:Hr.XDomainRequest,function(t,i){for(var s=0;s<t.length;s++)i(t[s])}(["get","put","post","patch","head","delete"],(function(t){Jr["delete"===t?"del":t]=function(i,s,e){return(s=Xr(i,s,e)).method=t.toUpperCase(),Qr(s)}}));var Yr=function(t,i){var s=new o.WebVTT.Parser(o,o.vttjs,o.WebVTT.StringDecoder()),e=[];s.oncue=function(t){i.addCue(t)},s.onparsingerror=function(t){e.push(t)},s.onflush=function(){i.trigger({type:"loadeddata",target:i})},s.parse(t),e.length>0&&(o.console&&o.console.groupCollapsed&&o.console.groupCollapsed("Text Track parsing errors for "+i.src),e.forEach((function(t){return n.error(t)})),o.console&&o.console.groupEnd&&o.console.groupEnd()),s.flush()},Kr=function(t){function i(s){var e;if(void 0===s&&(s={}),!s.tech)throw new v("A tech was not provided.");var r=xe(s,{kind:Ye[s.kind]||"subtitles",language:s.language||s.srclang||""}),h=Ke[r.mode]||"disabled",a=r.default;"metadata"!==r.kind&&"chapters"!==r.kind||(h="hidden");var u=e=t.call(this,r)||this;if(u.H=r.tech,te)for(var c in i.prototype)"constructor"!==c&&(u[c]=i.prototype[c]);u.U=[],u.W=[];var l=new Xe(u.U),f=new Xe(u.W),d=!1,p=_e(u,(function(){this.activeCues,d&&(this.trigger("cuechange"),d=!1)}));return"disabled"!==h&&u.H.ready((function(){u.H.on("timeupdate",p)}),!0),g.defineProperty(u,"default",{get:function(){return a},set:function(){}}),g.defineProperty(u,"mode",{get:function(){return h},set:function(t){var i=this;Ke[t]&&("showing"===(h=t)&&this.H.ready((function(){i.H.on("timeupdate",p)}),!0),this.trigger("modechange"))}}),g.defineProperty(u,"cues",{get:function(){return this.q?l:null},set:function(){}}),g.defineProperty(u,"activeCues",{get:function(){if(!this.q)return null;if(0===this.cues.length)return f;for(var t=this.H.currentTime(),i=[],s=0,e=this.cues.length;s<e;s++){var n=this.cues[s];(n.startTime<=t&&n.endTime>=t||n.startTime===n.endTime&&n.startTime<=t&&n.startTime+.5>=t)&&i.push(n)}if(d=!1,i.length!==this.W.length)d=!0;else for(var r=0;r<i.length;r++)-1===this.W.indexOf(i[r])&&(d=!0);return this.W=i,f.V(this.W),f},set:function(){}}),r.src?(u.src=r.src,function(t,i){var s={uri:t},e=sn(t);e&&(s.cors=e),Gr(s,_e(this,(function(t,s,e){if(t)return n.error(t,s);if(i.q=!0,"function"!=typeof o.WebVTT){if(i.H){var r=function(){return Yr(e,i)};i.H.on("vttjsloaded",r),i.H.on("vttjserror",(function(){n.error("vttjs failed to load, stopping trying to process "+i.src),i.H.off("vttjsloaded",r)}))}}else Yr(e,i)})))}(r.src,u)):u.q=!0,u||Ce(e)}Ae(i,t);var s=i.prototype;return s.addCue=function(t){var i=t;if(o.vttjs&&!(t instanceof o.vttjs.VTTCue)){for(var s in i=new o.vttjs.VTTCue(t.startTime,t.endTime,t.text),t)s in i||(i[s]=t[s]);i.id=t.id,i.G=t}var e=this.H.textTracks();if(e)for(var n=0;n<e.length;n++)e[n]!==this&&e[n].removeCue(i);this.U.push(i),this.cues.V(this.U)},s.removeCue=function(t){for(var i=this.U.length;i--;){var s=this.U[i];if(s===t||s.G&&s.G===t){this.U.splice(i,1),this.cues.V(this.U);break}}},i}(Ze);Kr.prototype.A={cuechange:"cuechange"};var Zr=function(t){function i(s){var e,n;void 0===s&&(s={});var r=Ce(e=t.call(this)||this);if(te)for(var h in r=Gi.createElement("custom"),i.prototype)"constructor"!==h&&(r[h]=i.prototype[h]);var o=new Kr(s);return r.kind=o.kind,r.src=o.src,r.srclang=o.language,r.label=o.label,r.default=o.default,g.defineProperty(r,"readyState",{get:function(){return n}}),g.defineProperty(r,"track",{get:function(){return o}}),n=0,o.addEventListener("loadeddata",(function(){n=2,r.trigger({type:"load",target:r})})),te?r||Ce(e):e}return Ae(i,t),i}(Te);Zr.prototype.A={load:"load"},Zr.NONE=0,Zr.LOADING=1,Zr.LOADED=2,Zr.ERROR=3;var th,ih=function(){function t(i){void 0===i&&(i=[]);var s=this;if(te)for(var e in s=Gi.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);s.X=[],g.defineProperty(s,"length",{get:function(){return this.X.length}});for(var n=0,r=i.length;n<r;n++)s.J(i[n]);if(te)return s}var i=t.prototype;return i.J=function(t){var i=this.X.length;""+i in this||g.defineProperty(this,i,{get:function(){return this.X[i]}}),-1===this.X.indexOf(t)&&this.X.push(t)},i.Y=function(t){for(var i,s=0,e=this.X.length;s<e;s++)if(t===this.X[s].track){i=this.X[s];break}return i},i.K=function(t){for(var i=0,s=this.X.length;i<s;i++)if(t===this.X[i]){this.X.splice(i,1);break}},t}(),sh=function(t){function i(s,e){var n;if(void 0===s&&(s=[]),void 0===e&&(e=null),n=t.call(this)||this,!e&&(e=Ce(n),te))for(var r in e=Gi.createElement("custom"),i.prototype)"constructor"!==r&&(e[r]=i.prototype[r]);e.Z=[],g.defineProperty(e,"length",{get:function(){return this.Z.length}});for(var h=0;h<s.length;h++)e.tt(s[h]);return e||Ce(n)}Ae(i,t);var s=i.prototype;return s.tt=function(t){var i=this.Z.length;""+i in this||g.defineProperty(this,i,{get:function(){return this.Z[i]}}),-1===this.Z.indexOf(t)&&(this.Z.push(t),this.trigger({track:t,type:"addtrack"}))},s.it=function(t){for(var i,s=0,e=this.length;s<e;s++)if(this[s]===t){(i=this[s]).off&&i.off(),this.Z.splice(s,1);break}i&&this.trigger({track:i,type:"removetrack"})},s.getTrackById=function(t){for(var i=null,s=0,e=this.length;s<e;s++){var n=this[s];if(n.id===t){i=n;break}}return i},i}(Te);for(th in sh.prototype.A={change:"change",addtrack:"addtrack",removetrack:"removetrack"},sh.prototype.A)sh.prototype["on"+th]=null;var eh=function(t){function i(s){var e,n;if(void 0===s&&(s=[]),te){for(var r in n=Gi.createElement("custom"),sh.prototype)"constructor"!==r&&(n[r]=sh.prototype[r]);for(var h in i.prototype)"constructor"!==h&&(n[h]=i.prototype[h])}return(n=e=t.call(this,s,n)||this)||Ce(e)}return Ae(i,t),i.prototype.tt=function(i){t.prototype.tt.call(this,i),i.addEventListener("modechange",_e(this,(function(){this.trigger("change")})))},i}(sh),nh=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].selected=!1)},rh=function(t){function i(s){var e,n;void 0===s&&(s=[]);for(var r=s.length-1;r>=0;r--)if(s[r].selected){nh(s,s[r]);break}if(te){for(var h in n=Gi.createElement("custom"),sh.prototype)"constructor"!==h&&(n[h]=sh.prototype[h]);for(var o in i.prototype)"constructor"!==o&&(n[o]=i.prototype[o])}return(n=e=t.call(this,s,n)||this).st=!1,g.defineProperty(n,"selectedIndex",{get:function(){for(var t=0;t<this.length;t++)if(this[t].selected)return t;return-1},set:function(){}}),n||Ce(e)}Ae(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.selected&&nh(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("selectedchange",(function(){s.st||(s.st=!0,nh(s,i),s.st=!1,s.trigger("change"))}))},s.addTrack=function(t){this.tt(t)},s.removeTrack=function(i){t.prototype.it.call(this,i)},i}(sh),hh=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].enabled=!1)},oh=function(t){function i(s){var e,n;void 0===s&&(s=[]);for(var r=s.length-1;r>=0;r--)if(s[r].enabled){hh(s,s[r]);break}if(te){for(var h in n=Gi.createElement("custom"),sh.prototype)"constructor"!==h&&(n[h]=sh.prototype[h]);for(var o in i.prototype)"constructor"!==o&&(n[o]=i.prototype[o])}return(n=e=t.call(this,s,n)||this).st=!1,n||Ce(e)}Ae(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.enabled&&hh(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("enabledchange",(function(){s.st||(s.st=!0,hh(s,i),s.st=!1,s.trigger("change"))}))},s.addTrack=function(t){this.tt(t)},s.removeTrack=function(i){t.prototype.it.call(this,i)},i}(sh),ah=void 0;var uh=function(t){function i(i,s){var e;return void 0===i&&(i={}),void 0===s&&(s=function(){}),i.reportTouchActivity=!1,(e=t.call(this,null,i,s)||this).et=!1,e.on("playing",(function(){this.et=!0})),e.on("loadstart",(function(){this.et=!1})),e.nt=i.textTracks,e.rt=i.videoTracks,e.ht=i.audioTracks,e.featuresProgressEvents||e.manualProgressOn(),e.featuresTimeupdateEvents||e.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach((function(t){!1===i["native"+t+"Tracks"]&&(e["featuresNative"+t+"Tracks"]=!1)})),!1===i.nativeCaptions&&(e.featuresNativeTextTracks=!1),e.featuresNativeTextTracks||e.emulateTextTracks(),e.ot=new eh,e.initTextTrackListeners(),e.initTrackListeners(),i.nativeControlsForTouch||e.emitTapEvents(),e.constructor&&(e.l=e.constructor.name||"Unknown Tech"),e}Ae(i,t);var s=i.prototype;return s.manualProgressOn=function(){this.on("durationchange",this.onDurationChange),this.manualProgress=!0,this.one("ready",this.trackProgress)},s.manualProgressOff=function(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange)},s.trackProgress=function(t){this.stopTrackingProgress(),this.progressInterval=this.setInterval(_e(this,(function(){var t=this.bufferedPercent();this.ut!==t&&this.trigger("progress"),this.ut=t,1===t&&this.stopTrackingProgress()})),500)},s.onDurationChange=function(t){this.ct=this.duration()},s.buffered=function(){return Ee(0,0)},s.bufferedPercent=function(){return De(this.buffered(),this.ct)},s.stopTrackingProgress=function(){this.clearInterval(this.progressInterval)},s.manualTimeUpdatesOn=function(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime),this.on("pause",this.stopTrackingCurrentTime)},s.manualTimeUpdatesOff=function(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime),this.off("pause",this.stopTrackingCurrentTime)},s.trackCurrentTime=function(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval((function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}),250)},s.stopTrackingCurrentTime=function(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},s.dispose=function(){this.clearTracks(["audio","video","text"]),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),t.prototype.dispose.call(this)},s.clearTracks=function(t){var i=this;(t=[].concat(t)).forEach((function(t){for(var s=i[t+"Tracks"]()||[],e=s.length;e--;){var n=s[e];"text"===t&&i.removeRemoteTextTrack(n),s.it(n)}}))},s.cleanupAutoTextTracks=function(){for(var t=this.ot||[],i=t.length;i--;){var s=t[i];this.removeRemoteTextTrack(s)}},s.reset=function(){},s.error=function(t){return void 0!==t&&(this.lt=new Le(t),this.trigger("error")),this.lt},s.played=function(){return this.et?Ee(0,0):Ee()},s.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},s.initTextTrackListeners=function(){var t=_e(this,(function(){this.trigger("texttrackchange")})),i=this.textTracks();i&&(i.addEventListener("removetrack",t),i.addEventListener("addtrack",t),this.on("dispose",_e(this,(function(){i.removeEventListener("removetrack",t),i.removeEventListener("addtrack",t)}))))},s.initTrackListeners=function(){var t=this;["video","audio"].forEach((function(i){var s=function(){t.trigger(i+"trackchange")},e=t[i+"Tracks"]();e.addEventListener("removetrack",s),e.addEventListener("addtrack",s),t.on("dispose",(function(){e.removeEventListener("removetrack",s),e.removeEventListener("addtrack",s)}))}))},s.ft=function(){var t=this;if(!o.WebVTT)if(Gi.body.contains(this.el())){if(!this.h["vtt.js"]&&es(ah)&&g.keys(ah).length>0)return void this.trigger("vttjsloaded");var i=Gi.createElement("script");i.src=this.h["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.12.4/vtt.min.js",i.onload=function(){t.trigger("vttjsloaded")},i.onerror=function(){t.trigger("vttjserror")},this.on("dispose",(function(){i.onload=null,i.onerror=null})),o.WebVTT=!0,this.el().parentNode.appendChild(i)}else this.ready(this.ft)},s.emulateTextTracks=function(){var t=this,i=this.textTracks();if(i){var s=this.remoteTextTracks(),e=function(t){return i.tt(t.track)},n=function(t){return i.it(t.track)};s.on("addtrack",e),s.on("removetrack",n),this.ft();var r=function(){return t.trigger("texttrackchange")},h=function(){r();for(var t=0;t<i.length;t++){var s=i[t];s.removeEventListener("cuechange",r),"showing"===s.mode&&s.addEventListener("cuechange",r)}};h(),i.addEventListener("change",h),i.addEventListener("addtrack",h),i.addEventListener("removetrack",h),this.on("dispose",(function(){s.off("addtrack",e),s.off("removetrack",n),i.removeEventListener("change",h),i.removeEventListener("addtrack",h),i.removeEventListener("removetrack",h);for(var t=0;t<i.length;t++){i[t].removeEventListener("cuechange",r)}}))}},s.videoTracks=function(){return this.rt=this.rt||new rh,this.rt},s.audioTracks=function(){return this.ht=this.ht||new oh,this.ht},s.textTracks=function(){return this.nt=this.nt||new eh,this.nt},s.remoteTextTracks=function(){return this.dt=this.dt||new eh,this.dt},s.remoteTextTrackEls=function(){return this.vt=this.vt||new ih,this.vt},s.addTextTrack=function(t,i,s){if(!t)throw new v("TextTrack kind is required but was not provided");return function(t,i,s,e,n){void 0===n&&(n={});var r=t.textTracks();n.kind=i,s&&(n.label=s),e&&(n.language=e),n.tech=t;var h=new Kr(n);return r.tt(h),h}(this,t,i,s)},s.createRemoteTextTrack=function(t){var i=xe(t,{tech:this});return new Zr(i)},s.addRemoteTextTrack=function(t,i){void 0===t&&(t={});var s=this.createRemoteTextTrack(t);return!0!==i&&!1!==i&&(n.warn('Calling addRemoteTextTrack without explicitly setting the "manualCleanup" parameter to `true` is deprecated and default to `false` in future version of video.js'),i=!0),this.remoteTextTrackEls().J(s),this.remoteTextTracks().tt(s.track),!0!==i&&this.ot.tt(s.track),s},s.removeRemoteTextTrack=function(t){var i=this.remoteTextTrackEls().Y(t);this.remoteTextTrackEls().K(i),this.remoteTextTracks().it(t),this.ot.it(t)},s.getVideoPlaybackQuality=function(){return{}},s.setPoster=function(){},s.playsinline=function(){},s.setPlaysinline=function(){},s.canPlayType=function(){return""},i.isTech=function(t){return t.prototype instanceof i||t instanceof i||t===i},i.registerTech=function(t,s){if(i.gt||(i.gt={}),!i.isTech(s))throw new v("Tech "+t+" must be a Tech");return i.gt[t]=s,s},i.getTech=function(t){return i.gt&&i.gt[t]?i.gt[t]:o&&o.videojs&&o.videojs[t]?(n.warn("The "+t+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),o.videojs[t]):void 0},i}(Se);uh.prototype.nt,uh.prototype.ht,uh.prototype.rt,uh.prototype.featuresVolumeControl=!0,uh.prototype.featuresFullscreenResize=!1,uh.prototype.featuresPlaybackRate=!1,uh.prototype.featuresProgressEvents=!1,uh.prototype.featuresTimeupdateEvents=!1,uh.prototype.featuresNativeTextTracks=!1,uh.withSourceHandlers=function(t){t.registerSourceHandler=function(i,s){var e=t.sourceHandlers;e||(e=t.sourceHandlers=[]),void 0===s&&(s=e.length),e.splice(s,0,i)},t.canPlayType=function(i){for(var s,e=t.sourceHandlers||[],n=0;n<e.length;n++)if(s=e[n].canPlayType(i))return s;return""},t.selectSourceHandler=function(i,s){for(var e=t.sourceHandlers||[],n=0;n<e.length;n++)if(e[n].canHandleSource(i,s))return e[n];return null},t.canPlaySource=function(i,s){var e=t.selectSourceHandler(i,s);return e?e.canHandleSource(i,s):""};["seekable","duration"].forEach((function(t){var i=this[t];"function"==typeof i&&(this[t]=function(){return this.yt&&this.yt[t]?this.yt[t].apply(this.yt,arguments):i.apply(this,arguments)})}),t.prototype),t.prototype.setSource=function(i){var s=t.selectSourceHandler(i,this.h);return s||(t.nativeSourceHandler?s=t.nativeSourceHandler:n.error("No source hander found for the current source.")),this.disposeSourceHandler(),this.off("dispose",this.disposeSourceHandler),s!==t.nativeSourceHandler&&(this.bt=i,this.off(this.v,"loadstart",t.prototype.wt),this.off(this.v,"loadstart",t.prototype.kt),this.one(this.v,"loadstart",t.prototype.wt)),this.yt=s.handleSource(i,this,this.h),this.on("dispose",this.disposeSourceHandler),this},t.prototype.wt=function(){this.one(this.v,"loadstart",t.prototype.kt)},t.prototype.kt=function(){this.disposeSourceHandler(),this.one(this.v,"loadstart",t.prototype.kt)},t.prototype.disposeSourceHandler=function(){this.bt&&(this.clearTracks(["audio","video"]),this.bt=null),this.cleanupAutoTextTracks(),this.yt&&(this.off(this.v,"loadstart",t.prototype.wt),this.off(this.v,"loadstart",t.prototype.kt),this.yt.dispose&&this.yt.dispose(),this.yt=null)}},Se.registerComponent("Tech",uh),Se.registerComponent("MediaTechController",uh),uh.registerTech("Tech",uh);var ch=function(t){function i(i,s,e){var n;if(n=t.call(this,i,s,e)||this,s.playerOptions.sources&&0!==s.playerOptions.sources.length)i.src(s.playerOptions.sources);else for(var r=0,h=s.playerOptions.techOrder;r<h.length;r++){var o=je(h[r]),a=uh.getTech(o);if(o||(a=Se.getComponent(o)),a&&a.isSupported()){i._t(o);break}}return n}return Ae(i,t),i}(Se);Se.registerComponent("MediaLoader",ch);var lh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).emitTapEvents(),e.on(i,"languagechange",e.handleLanguagechange),e.enable(),e}Ae(i,t);var s=i.prototype;return s.createEl=function(i,s,e){void 0===i&&(i="div"),void 0===s&&(s={}),void 0===e&&(e={}),s=is({className:this.buildCSSClass(),tabIndex:0},s),"button"===i&&n.error("Creating a ClickableComponent with an HTML element of "+i+" is not supported; use a Button instead."),e=is({role:"button","aria-live":"polite"},e),this.jt=s.tabIndex;var r=t.prototype.createEl.call(this,i,s,e);return this.createControlTextEl(r),r},s.createControlTextEl=function(t){return this.xt=vs("span",{className:"vjs-control-text"}),t&&t.appendChild(this.xt),this.controlText(this.St,t),this.xt},s.controlText=function(t,i){if(void 0===i&&(i=this.el()),void 0===t)return this.St||"Need Text";var s=this.localize(t);return this.St=t,this.xt.innerHTML=s,this.nonIconControl||i.setAttribute("title",s),this},s.buildCSSClass=function(){return"vjs-control vjs-button "+t.prototype.buildCSSClass.call(this)},s.enable=function(){return this.removeClass("vjs-disabled"),this.v.setAttribute("aria-disabled","false"),void 0!==this.jt&&this.v.setAttribute("tabIndex",this.jt),this.off(["tap","click"],this.handleClick),this.off("focus",this.handleFocus),this.off("blur",this.handleBlur),this.on(["tap","click"],this.handleClick),this.on("focus",this.handleFocus),this.on("blur",this.handleBlur),this},s.disable=function(){return this.addClass("vjs-disabled"),this.v.setAttribute("aria-disabled","true"),void 0!==this.jt&&this.v.removeAttribute("tabIndex"),this.off(["tap","click"],this.handleClick),this.off("focus",this.handleFocus),this.off("blur",this.handleBlur),this},s.handleLanguagechange=function(){this.controlText(this.St)},s.handleClick=function(t){},s.handleFocus=function(t){fe(Gi,"keydown",_e(this,this.handleKeyPress))},s.handleKeyPress=function(i){32===i.which||13===i.which?(i.preventDefault(),this.handleClick(i)):t.prototype.handleKeyPress&&t.prototype.handleKeyPress.call(this,i)},s.handleBlur=function(t){de(Gi,"keydown",_e(this,this.handleKeyPress))},i}(Se);Se.registerComponent("ClickableComponent",lh);var fh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).update(),i.on("posterchange",_e(Ce(e),e.update)),e}Ae(i,t);var s=i.prototype;return s.dispose=function(){this.player().off("posterchange",this.update),t.prototype.dispose.call(this)},s.createEl=function(){var t=vs("div",{className:"vjs-poster",tabIndex:-1});return re||(this.Tt=vs("img"),t.appendChild(this.Tt)),t},s.update=function(t){var i=this.player().poster();this.setSrc(i),i?this.show():this.hide()},s.setSrc=function(t){if(this.Tt)this.Tt.src=t;else{var i="";t&&(i='url("'+t+'")'),this.v.style.backgroundImage=i}},s.handleClick=function(t){this.t.controls()&&(this.t.paused()?this.t.play():this.t.pause())},i}(lh);Se.registerComponent("PosterImage",fh);var dh="#222",vh={monospace:"monospace",sansSerif:"sans-serif",serif:"serif",monospaceSansSerif:'"Andale Mono", "Lucida Console", monospace',monospaceSerif:'"Courier New", monospace',proportionalSansSerif:"sans-serif",proportionalSerif:"serif",casual:'"Comic Sans MS", Impact, fantasy',script:'"Monotype Corsiva", cursive',smallcaps:'"Andale Mono", "Lucida Console", monospace, sans-serif'};function ph(t,i){return"rgba("+k(t[1]+t[1],16)+","+k(t[2]+t[2],16)+","+k(t[3]+t[3],16)+","+i+")"}function mh(t,i,s){try{t.style[i]=s}catch(t){return}}var gh=function(t){function i(i,s,e){var n;return n=t.call(this,i,s,e)||this,i.on("loadstart",_e(Ce(n),n.toggleDisplay)),i.on("texttrackchange",_e(Ce(n),n.updateDisplay)),i.ready(_e(Ce(n),(function(){if(i.H&&i.H.featuresNativeTextTracks)this.hide();else{i.on("fullscreenchange",_e(this,this.updateDisplay));for(var t=this.h.playerOptions.tracks||[],s=0;s<t.length;s++)this.t.addRemoteTextTrack(t[s],!0);var e,n,r={captions:1,subtitles:1},h=this.t.textTracks();if(h){for(var o=0;o<h.length;o++){var a=h[o];a.default&&("descriptions"!==a.kind||e?a.kind in r&&!n&&(n=a):e=a)}n?n.mode="showing":e&&(e.mode="showing")}}}))),n}Ae(i,t);var s=i.prototype;return s.toggleDisplay=function(){this.t.H&&this.t.H.featuresNativeTextTracks?this.hide():this.show()},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-text-track-display"},{"aria-live":"off","aria-atomic":"true"})},s.clearDisplay=function(){"function"==typeof o.WebVTT&&o.WebVTT.processCues(o,[],this.v)},s.updateDisplay=function(){var t=this.t.textTracks();if(this.clearDisplay(),t){for(var i=null,s=null,e=t.length;e--;){var n=t[e];"showing"===n.mode&&("descriptions"===n.kind?i=n:s=n)}s?("off"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","off"),this.updateForTrack(s)):i&&("assertive"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","assertive"),this.updateForTrack(i))}},s.updateForTrack=function(t){if("function"==typeof o.WebVTT&&t.activeCues){for(var i=this.t.textTrackSettings.getValues(),s=[],e=0;e<t.activeCues.length;e++)s.push(t.activeCues[e]);o.WebVTT.processCues(o,s,this.v);for(var n=s.length;n--;){var r=s[n];if(r){var h=r.displayState;if(i.color&&(h.firstChild.style.color=i.color),i.textOpacity&&mh(h.firstChild,"color",ph(i.color||"#fff",i.textOpacity)),i.backgroundColor&&(h.firstChild.style.backgroundColor=i.backgroundColor),i.backgroundOpacity&&mh(h.firstChild,"backgroundColor",ph(i.backgroundColor||"#000",i.backgroundOpacity)),i.windowColor&&(i.windowOpacity?mh(h,"backgroundColor",ph(i.windowColor,i.windowOpacity)):h.style.backgroundColor=i.windowColor),i.edgeStyle&&("dropshadow"===i.edgeStyle?h.firstChild.style.textShadow="2px 2px 3px #222, 2px 2px 4px #222, 2px 2px 5px "+dh:"raised"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #222, 2px 2px #222, 3px 3px "+dh:"depressed"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #ccc, 0 1px #ccc, -1px -1px #222, 0 -1px "+dh:"uniform"===i.edgeStyle&&(h.firstChild.style.textShadow="0 0 4px #222, 0 0 4px #222, 0 0 4px #222, 0 0 4px "+dh)),i.fontPercent&&1!==i.fontPercent){var a=o.parseFloat(h.style.fontSize);h.style.fontSize=a*i.fontPercent+"px",h.style.height="auto",h.style.top="auto",h.style.bottom="2px"}i.fontFamily&&"default"!==i.fontFamily&&("small-caps"===i.fontFamily?h.firstChild.style.fontVariant="small-caps":h.firstChild.style.fontFamily=vh[i.fontFamily])}}}},i}(Se);Se.registerComponent("TextTrackDisplay",gh);var yh=function(t){function i(){return t.apply(this,arguments)||this}return Ae(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"})},i}(Se);Se.registerComponent("LoadingSpinner",yh);var bh=function(t){function i(){return t.apply(this,arguments)||this}Ae(i,t);var s=i.prototype;return s.createEl=function(t,i,s){void 0===t&&(t="button"),void 0===i&&(i={}),void 0===s&&(s={}),i=is({className:this.buildCSSClass()},i),"button"!==t&&(n.warn("Creating a Button with an HTML element of "+t+" is deprecated; use ClickableComponent instead."),i=is({tabIndex:0},i),s=is({role:"button"},s)),s=is({type:"button","aria-live":"polite"},s);var e=Se.prototype.createEl.call(this,t,i,s);return this.createControlTextEl(e),e},s.addChild=function(t,i){void 0===i&&(i={});var s=this.constructor.name;return n.warn("Adding an actionable (user controllable) child to a Button ("+s+") is not supported; use a ClickableComponent instead."),Se.prototype.addChild.call(this,t,i)},s.enable=function(){t.prototype.enable.call(this),this.v.removeAttribute("disabled")},s.disable=function(){t.prototype.disable.call(this),this.v.setAttribute("disabled","disabled")},s.handleKeyPress=function(i){32!==i.which&&13!==i.which&&t.prototype.handleKeyPress.call(this,i)},i}(lh);Se.registerComponent("Button",bh);var wh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Ct=!1,e.on("mousedown",e.handleMouseDown),e}Ae(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-big-play-button"},s.handleClick=function(t){var i=this.t.play();if(!(this.Ct&&t.clientX&&t.clientY)){var s=this.t.getChild("controlBar"),e=s&&s.getChild("playToggle");if(e){var n=function(){return e.focus()};if(i&&i.then){i.then(n,(function(){}))}else this.setTimeout(n,1)}else this.t.focus()}},s.handleKeyPress=function(i){this.Ct=!1,t.prototype.handleKeyPress.call(this,i)},s.handleMouseDown=function(t){this.Ct=!0},i}(bh);wh.prototype.St="Play Video",Se.registerComponent("BigPlayButton",wh);var kh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).controlText(s&&s.controlText||"Close"),e}Ae(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-close-button "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.trigger({type:"close",bubbles:!1})},i}(bh);Se.registerComponent("CloseButton",kh);var _h=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"play",e.handlePlay),e.on(i,"pause",e.handlePause),e}Ae(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-play-control "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.t.paused()?this.t.play():this.t.pause()},s.handlePlay=function(t){this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.controlText("Pause")},s.handlePause=function(t){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.controlText("Play")},i}(bh);function jh(t,i){void 0===i&&(i=t),t=t<0?0:t;var s=w.floor(t%60),e=w.floor(t/60%60),n=w.floor(t/3600),r=w.floor(i/60%60),h=w.floor(i/3600);return(j(t)||t===1/0)&&(n=e=s="-"),(n=n>0||h>0?n+":":"")+(e=((n||r>=10)&&e<10?"0"+e:e)+":")+(s=s<10?"0"+s:s)}_h.prototype.St="Play",Se.registerComponent("PlayToggle",_h);var xh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"timeupdate",e.updateContent),e.on(i,"languagechange",e.updateContent),e}Ae(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-current-time vjs-time-control vjs-control"});return this.S=vs("div",{className:"vjs-current-time-display",innerHTML:'<span class="vjs-control-text">Current Time </span>0:00'},{"aria-live":"off"}),i.appendChild(this.S),i},s.updateContent=function(t){var i=this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime(),s=this.localize("Current Time"),e=jh(i,this.t.duration());e!==this.Pt&&(this.Pt=e,this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e)},i}(Se);Se.registerComponent("CurrentTimeDisplay",xh);var Sh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"durationchange",e.updateContent),e.on(i,"timeupdate",e.updateContent),e.on(i,"loadedmetadata",e.updateContent),e.on(i,"languagechange",e.updateContent),e}Ae(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-duration vjs-time-control vjs-control"});return this.S=vs("div",{className:"vjs-duration-display",innerHTML:'<span class="vjs-control-text">'+this.localize("Duration Time")+"</span> 0:00"},{"aria-live":"off"}),i.appendChild(this.S),i},s.updateContent=function(t){var i=this.t.duration();if(i&&this.ct!==i){this.ct=i;var s=this.localize("Duration Time"),e=jh(i);this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e}},i}(Se);Se.registerComponent("DurationDisplay",Sh);var Th=function(t){function i(){return t.apply(this,arguments)||this}return Ae(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-time-control vjs-time-divider",innerHTML:"<div><span>/</span></div>"})},i}(Se);Se.registerComponent("TimeDivider",Th);var Ch=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"timeupdate",e.updateContent),e.on(i,"durationchange",e.updateContent),e.on(i,"languagechange",e.updateContent),e}Ae(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-remaining-time vjs-time-control vjs-control"});return this.S=vs("div",{className:"vjs-remaining-time-display",innerHTML:'<span class="vjs-control-text">'+this.localize("Remaining Time")+"</span> -0:00"},{"aria-live":"off"}),i.appendChild(this.S),i},s.updateContent=function(t){if(this.t.duration()){var i=this.localize("Remaining Time"),s=jh(this.t.remainingTime());s!==this.Pt&&(this.Pt=s,this.S.innerHTML='<span class="vjs-control-text">'+i+"</span> -"+s)}},i}(Se);Se.registerComponent("RemainingTimeDisplay",Ch);var Ph=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).updateShowing(),e.on(e.player(),"durationchange",e.updateShowing),e.on(e.player(),"languagechange",e.handleLanguagechange),e}Ae(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-live-control vjs-control"});return this.S=vs("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.xt=vs("span",{className:"vjs-control-text",innerHTML:this.localize("Stream Type")}),this.At=Gi.createTextNode(this.localize("LIVE")),this.S.appendChild(this.xt),this.S.appendChild(this.At),i.appendChild(this.S),i},s.updateShowing=function(t){this.player().duration()===1/0?this.show():this.hide()},s.handleLanguagechange=function(){this.xt.innerHTML=this.localize("Stream Type"),this.At.innerHTML=this.localize("LIVE")},i}(Se);Se.registerComponent("LiveDisplay",Ph);var Ah=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).bar=e.getChild(e.h.barName),e.vertical(!!e.h.vertical),e.on("mousedown",e.handleMouseDown),e.on("touchstart",e.handleMouseDown),e.on("focus",e.handleFocus),e.on("blur",e.handleBlur),e.on("click",e.handleClick),e.on(i,"controlsvisible",e.update),e.on(i,e.playerEvent,e.update),e}Ae(i,t);var s=i.prototype;return s.createEl=function(i,s,e){return void 0===s&&(s={}),void 0===e&&(e={}),s.className=s.className+" vjs-slider",s=is({tabIndex:0},s),e=is({role:"slider","aria-valuenow":0,"aria-valuemin":0,"aria-valuemax":100,tabIndex:0},e),t.prototype.createEl.call(this,i,s,e)},s.handleMouseDown=function(t){var i=this.bar.v.ownerDocument;t.preventDefault(),Gi.body.focus(),Gi.onselectstart=function(){return!1},this.addClass("vjs-sliding"),this.trigger("slideractive"),this.on(i,"mousemove",this.handleMouseMove),this.on(i,"mouseup",this.handleMouseUp),this.on(i,"touchmove",this.handleMouseMove),this.on(i,"touchend",this.handleMouseUp),this.handleMouseMove(t)},s.handleMouseMove=function(t){},s.handleMouseUp=function(){var t=this.bar.v.ownerDocument;Gi.onselectstart=function(){return!0},this.removeClass("vjs-sliding"),this.trigger("sliderinactive"),this.off(t,"mousemove",this.handleMouseMove),this.off(t,"mouseup",this.handleMouseUp),this.off(t,"touchmove",this.handleMouseMove),this.off(t,"touchend",this.handleMouseUp),this.update()},s.update=function(){if(this.v){var t=this.getPercent(),i=this.bar;if(i){("number"!=typeof t||t!=t||t<0||t===1/0)&&(t=0);var s=(100*t).toFixed(2)+"%";this.vertical()?i.el().style.height=s:i.el().style.width=s}}},s.calculateDistance=function(t){var i=Is(this.v,t);return this.vertical()?i.y:i.x},s.handleFocus=function(){this.on(this.bar.v.ownerDocument,"keydown",this.handleKeyPress)},s.handleKeyPress=function(t){37===t.which||40===t.which?(t.preventDefault(),this.stepBack()):38!==t.which&&39!==t.which||(t.preventDefault(),this.stepForward())},s.handleBlur=function(){this.off(this.bar.v.ownerDocument,"keydown",this.handleKeyPress)},s.handleClick=function(t){t.stopImmediatePropagation(),t.preventDefault()},s.vertical=function(t){return void 0===t?this.Mt||!1:(this.Mt=!!t,this.Mt?this.addClass("vjs-slider-vertical"):this.addClass("vjs-slider-horizontal"),this)},i}(Se);function Mh(t,i){if(!t||!i)return"";if("function"==typeof o.getComputedStyle){var s=o.getComputedStyle(t);return s?s[i]:""}return t.currentStyle[i]||""}Se.registerComponent("Slider",Ah);var Ih=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).It=[],e.on(i,"progress",e.update),e.on(i,"languagechange",e.handleLanguagechange),e}Ae(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-load-progress"});return this.Et=vs("span",{innerHTML:this.localize("Loaded")}),this.Dt=Gi.createTextNode(": 0%"),this.xt=vs("span",{className:"vjs-control-text"}),this.xt.appendChild(this.Et),this.xt.appendChild(this.Dt),i.appendChild(this.xt),i},s.update=function(t){var i=this.t.buffered(),s=this.t.duration(),e=this.t.bufferedEnd(),n=this.It,r=function(t,i){var s=t/i||0;return 100*(s>=1?1:s)+"%"};this.v.style.width=r(e,s);for(var h=0;h<i.length;h++){var o=i.start(h),a=i.end(h),u=n[h];u||(u=this.v.appendChild(vs()),n[h]=u),u.style.left=r(o,e),u.style.width=r(a-o,e)}for(var c=n.length;c>i.length;c--)this.v.removeChild(n[c-1]);n.length=i.length},s.handleLanguagechange=function(){this.Et.innerHTML=this.localize("Loaded")},i}(Se);Se.registerComponent("LoadProgressBar",Ih);var Eh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).updateDataAttr(),e.on(i,"timeupdate",e.updateDataAttr),e.on(i,"languagechange",e.handleLanguagechange),i.ready(_e(Ce(e),e.updateDataAttr)),s.playerOptions&&s.playerOptions.controlBar&&s.playerOptions.controlBar.progressControl&&s.playerOptions.controlBar.progressControl.keepTooltipsInside&&(e.keepTooltipsInside=s.playerOptions.controlBar.progressControl.keepTooltipsInside),e.keepTooltipsInside&&e.addClass("vjs-keep-tooltips-inside"),e}Ae(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-play-progress vjs-slider-bar"});return this.Nt=vs("span",{innerHTML:this.localize("Progress")}),this.Ft=Gi.createTextNode(": 0%"),this.xt=vs("span",{className:"vjs-control-text"}),this.xt.appendChild(this.Nt),this.xt.appendChild(this.Ft),i.appendChild(this.xt),i},s.updateDataAttr=function(t){var i=this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime();this.v.setAttribute("data-current-time",jh(i,this.t.duration()))},s.handleLanguagechange=function(){this.Nt.innerHTML=this.localize("Progress")},i}(Se);Se.registerComponent("PlayProgressBar",Eh);var Dh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).updateDataAttr(),e.on(i,"timeupdate",e.updateDataAttr),e.on(i,"languagechange",e.handleLanguagechange),i.ready(_e(Ce(e),e.updateDataAttr)),e}Ae(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-tooltip-progress-bar vjs-slider-bar"});return this.tooltip=vs("div",{className:"vjs-time-tooltip"}),this.Nt=vs("span",{innerHTML:this.localize("Progress")}),this.Ft=Gi.createTextNode(": 0%"),this.xt=vs("span",{className:"vjs-control-text"}),this.xt.appendChild(this.Nt),this.xt.appendChild(this.Ft),i.appendChild(this.tooltip),i.appendChild(this.xt),i},s.updateDataAttr=function(t){var i=jh(this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime(),this.t.duration());this.v.setAttribute("data-current-time",i),this.tooltip.innerHTML=i},s.handleLanguagechange=function(){this.Nt.innerHTML=this.localize("Progress")},i}(Se);Se.registerComponent("TooltipProgressBar",Dh);var Nh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"timeupdate",e.updateProgress),e.on(i,"ended",e.updateProgress),i.ready(_e(Ce(e),e.updateProgress)),s.playerOptions&&s.playerOptions.controlBar&&s.playerOptions.controlBar.progressControl&&s.playerOptions.controlBar.progressControl.keepTooltipsInside&&(e.keepTooltipsInside=s.playerOptions.controlBar.progressControl.keepTooltipsInside),e.keepTooltipsInside&&(e.tooltipProgressBar=e.addChild("TooltipProgressBar")),e}Ae(i,t);var s=i.prototype;return s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-holder"},{"aria-label":"progress bar"})},s.updateProgress=function(t){if(this.updateAriaAttributes(this.v),this.keepTooltipsInside){this.updateAriaAttributes(this.tooltipProgressBar.v),this.tooltipProgressBar.v.style.width=this.bar.v.style.width;var i=_(Mh(this.player().el(),"width")),s=_(Mh(this.tooltipProgressBar.tooltip,"width")),e=this.tooltipProgressBar.el().style;e.maxWidth=w.floor(i-s/2)+"px",e.minWidth=w.ceil(s/2)+"px",e.right="-"+s/2+"px"}},s.updateAriaAttributes=function(t){var i=this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime();t.setAttribute("aria-valuenow",(100*this.getPercent()).toFixed(2)),t.setAttribute("aria-valuetext",jh(i,this.t.duration()))},s.getPercent=function(){var t=this.t.currentTime()/this.t.duration();return t>=1?1:t},s.handleMouseDown=function(i){this.t.scrubbing(!0),this.videoWasPlaying=!this.t.paused(),this.t.pause(),t.prototype.handleMouseDown.call(this,i)},s.handleMouseMove=function(t){var i=this.calculateDistance(t)*this.t.duration();i===this.t.duration()&&(i-=.1),this.t.currentTime(i)},s.handleMouseUp=function(i){t.prototype.handleMouseUp.call(this,i),this.t.scrubbing(!1),this.videoWasPlaying&&this.t.play()},s.stepForward=function(){this.t.currentTime(this.t.currentTime()+5)},s.stepBack=function(){this.t.currentTime(this.t.currentTime()-5)},i}(Ah);Nh.prototype.h={children:["loadProgressBar","mouseTimeDisplay","playProgressBar"],barName:"playProgressBar"},Nh.prototype.playerEvent="timeupdate",Se.registerComponent("SeekBar",Nh);var Fh=function(t){function i(i,s){var e;return e=t.call(this,i,s)||this,s.playerOptions&&s.playerOptions.controlBar&&s.playerOptions.controlBar.progressControl&&s.playerOptions.controlBar.progressControl.keepTooltipsInside&&(e.keepTooltipsInside=s.playerOptions.controlBar.progressControl.keepTooltipsInside),e.keepTooltipsInside&&(e.tooltip=vs("div",{className:"vjs-time-tooltip"}),e.el().appendChild(e.tooltip),e.addClass("vjs-keep-tooltips-inside")),e.update(0,0),i.on("ready",(function(){e.on(i.controlBar.progressControl.el(),"mousemove",function(t,i){var s=Date.now();return function(){var e=Date.now();e-s>=i&&(t.apply(void 0,arguments),s=e)}}(_e(Ce(e),e.handleMouseMove),25))})),e}Ae(i,t);var s=i.prototype;return s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-mouse-display"})},s.handleMouseMove=function(t){var i=this.t.duration(),s=this.calculateDistance(t)*i,e=t.pageX-Ms(this.el().parentNode).left;this.update(s,e)},s.update=function(t,i){var s=jh(t,this.t.duration());if(this.el().style.left=i+"px",this.el().setAttribute("data-current-time",s),this.keepTooltipsInside){var e=i-this.$t(i)+1,n=_(Mh(this.tooltip,"width"))/2;this.tooltip.innerHTML=s,this.tooltip.style.right="-"+(n-e)+"px"}},s.calculateDistance=function(t){return Is(this.el().parentNode,t).x},s.$t=function(t){if(!this.keepTooltipsInside)return t;var i=_(Mh(this.player().el(),"width")),s=_(Mh(this.tooltip,"width"))/2,e=t;return t<s?e=w.ceil(s):t>i-s&&(e=w.floor(i-s)),e},i}(Se);Se.registerComponent("MouseTimeDisplay",Fh);var $h=function(t){function i(){return t.apply(this,arguments)||this}return Ae(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},i}(Se);$h.prototype.h={children:["seekBar"]},Se.registerComponent("ProgressControl",$h);var Bh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"fullscreenchange",e.handleFullscreenChange),e}Ae(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-fullscreen-control "+t.prototype.buildCSSClass.call(this)},s.handleFullscreenChange=function(t){this.t.isFullscreen()?this.controlText("Non-Fullscreen"):this.controlText("Fullscreen")},s.handleClick=function(t){this.t.isFullscreen()?this.t.exitFullscreen():this.t.requestFullscreen()},i}(bh);Bh.prototype.St="Fullscreen",Se.registerComponent("FullscreenToggle",Bh);var Rh=function(t){function i(){return t.apply(this,arguments)||this}return Ae(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-level",innerHTML:'<span class="vjs-control-text"></span>'})},i}(Se);Se.registerComponent("VolumeLevel",Rh);var Oh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.updateARIAAttributes),i.ready(_e(Ce(e),e.updateARIAAttributes)),e}Ae(i,t);var s=i.prototype;return s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-bar vjs-slider-bar"},{"aria-label":"volume level"})},s.handleMouseMove=function(t){this.checkMuted(),this.t.volume(this.calculateDistance(t))},s.checkMuted=function(){this.t.muted()&&this.t.muted(!1)},s.getPercent=function(){return this.t.muted()?0:this.t.volume()},s.stepForward=function(){this.checkMuted(),this.t.volume(this.t.volume()+.1)},s.stepBack=function(){this.checkMuted(),this.t.volume(this.t.volume()-.1)},s.updateARIAAttributes=function(t){var i=(100*this.t.volume()).toFixed(2);this.v.setAttribute("aria-valuenow",i),this.v.setAttribute("aria-valuetext",i+"%")},i}(Ah);Oh.prototype.h={children:["volumeLevel"],barName:"volumeLevel"},Oh.prototype.playerEvent="volumechange",Se.registerComponent("VolumeBar",Oh);var Vh=function(t){function i(i,s){var e;return e=t.call(this,i,s)||this,i.H&&!1===i.H.featuresVolumeControl&&e.addClass("vjs-hidden"),e.on(i,"loadstart",(function(){!1===i.H.featuresVolumeControl?this.addClass("vjs-hidden"):this.removeClass("vjs-hidden")})),e}return Ae(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control"})},i}(Se);Vh.prototype.h={children:["volumeBar"]},Se.registerComponent("VolumeControl",Vh);var Lh=function(t){function i(){return t.apply(this,arguments)||this}Ae(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",_e(this,(function(){this.unlockShowing()})))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=vs(i,{className:"vjs-menu-content"});var s=t.prototype.createEl.call(this,"div",{append:this.S,className:"vjs-menu"});return s.appendChild(this.S),fe(s,"click",(function(t){t.preventDefault(),t.stopImmediatePropagation()})),s},i}(Se);Se.registerComponent("Popup",Lh);var Uh=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e}Ae(i,t);var s=i.prototype;return s.update=function(){var t=this.createPopup();this.popup&&this.removeChild(this.popup),this.popup=t,this.addChild(t),this.items&&0===this.items.length?this.hide():this.items&&this.items.length>1&&this.show()},s.createPopup=function(){},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass()})},s.buildCSSClass=function(){var i="vjs-menu-button";return!0===this.h.inline?i+="-inline":i+="-popup","vjs-menu-button "+i+" "+t.prototype.buildCSSClass.call(this)},i}(lh);Se.registerComponent("PopupButton",Uh);var Hh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.update),i.H&&!1===i.H.featuresVolumeControl&&e.addClass("vjs-hidden"),e.on(i,"loadstart",(function(){this.update(),!1===i.H.featuresVolumeControl?this.addClass("vjs-hidden"):this.removeClass("vjs-hidden")})),e}Ae(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-mute-control "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.t.muted(!this.t.muted())},s.update=function(t){var i=this.t.volume(),s=3;this.t.muted()?s=0:i<.33?s=1:i<.67&&(s=2);var e=this.t.muted()?"Unmute":"Mute";this.controlText()!==e&&this.controlText(e);for(var n=0;n<4;n++)xs(this.v,"vjs-vol-"+n);js(this.v,"vjs-vol-"+s)},i}(bh);Hh.prototype.St="Mute",Se.registerComponent("MuteToggle",Hh);var zh=function(t){function i(i,s){var e;function n(){i.H&&!1===i.H.featuresVolumeControl?this.addClass("vjs-hidden"):this.removeClass("vjs-hidden")}return void 0===s&&(s={}),void 0===s.inline&&(s.inline=!0),void 0===s.vertical&&(s.inline?s.vertical=!1:s.vertical=!0),s.volumeBar=s.volumeBar||{},s.volumeBar.vertical=!!s.vertical,(e=t.call(this,i,s)||this).on(i,"volumechange",e.volumeUpdate),e.on(i,"loadstart",e.volumeUpdate),n.call(Ce(e)),e.on(i,"loadstart",n),e.on(e.volumeBar,["slideractive","focus"],(function(){this.addClass("vjs-slider-active")})),e.on(e.volumeBar,["sliderinactive","blur"],(function(){this.removeClass("vjs-slider-active")})),e.on(e.volumeBar,["focus"],(function(){this.addClass("vjs-lock-showing")})),e.on(e.volumeBar,["blur"],(function(){this.removeClass("vjs-lock-showing")})),e}Ae(i,t);var s=i.prototype;return s.buildCSSClass=function(){var i="";return i=this.h.vertical?"vjs-volume-menu-button-vertical":"vjs-volume-menu-button-horizontal","vjs-volume-menu-button "+t.prototype.buildCSSClass.call(this)+" "+i},s.createPopup=function(){var t=new Lh(this.t,{contentElType:"div"}),i=new Oh(this.t,this.h.volumeBar);return t.addChild(i),this.menuContent=t,this.volumeBar=i,this.attachVolumeBarEvents(),t},s.handleClick=function(i){Hh.prototype.handleClick.call(this),t.prototype.handleClick.call(this)},s.attachVolumeBarEvents=function(){this.menuContent.on(["mousedown","touchdown"],_e(this,this.handleMouseDown))},s.handleMouseDown=function(t){this.on(["mousemove","touchmove"],_e(this.volumeBar,this.volumeBar.handleMouseMove)),this.on(this.v.ownerDocument,["mouseup","touchend"],this.handleMouseUp)},s.handleMouseUp=function(t){this.off(["mousemove","touchmove"],_e(this.volumeBar,this.volumeBar.handleMouseMove))},i}(Uh);zh.prototype.volumeUpdate=Hh.prototype.update,zh.prototype.St="Mute",Se.registerComponent("VolumeMenuButton",zh);var Wh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Bt=-1,e.on("keydown",e.handleKeyPress),e}Ae(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",_e(this,(function(t){this.unlockShowing()})))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=vs(i,{className:"vjs-menu-content"}),this.S.setAttribute("role","menu");var s=t.prototype.createEl.call(this,"div",{append:this.S,className:"vjs-menu"});return s.setAttribute("role","presentation"),s.appendChild(this.S),fe(s,"click",(function(t){t.preventDefault(),t.stopImmediatePropagation()})),s},s.handleKeyPress=function(t){37===t.which||40===t.which?(t.preventDefault(),this.stepForward()):38!==t.which&&39!==t.which||(t.preventDefault(),this.stepBack())},s.stepForward=function(){var t=0;void 0!==this.Bt&&(t=this.Bt+1),this.focus(t)},s.stepBack=function(){var t=0;void 0!==this.Bt&&(t=this.Bt-1),this.focus(t)},s.focus=function(t){void 0===t&&(t=0);var i=this.children().slice();i.length&&i[0].className&&/vjs-menu-title/.test(i[0].className)&&i.shift(),i.length>0&&(t<0?t=0:t>=i.length&&(t=i.length-1),this.Bt=t,i[t].v.focus())},i}(Se);Se.registerComponent("Menu",Wh);var qh=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e.Rt=!0,e.v.setAttribute("aria-haspopup","true"),e.v.setAttribute("role","menuitem"),e.on("keydown",e.handleSubmenuKeyPress),e}Ae(i,t);var s=i.prototype;return s.update=function(){var t=this.createMenu();this.menu&&this.removeChild(this.menu),this.menu=t,this.addChild(t),this.Ot=!1,this.v.setAttribute("aria-expanded","false"),this.items&&this.items.length<=this.Vt?this.hide():this.show()},s.createMenu=function(){var t=new Wh(this.t);if(this.Vt=0,this.h.title){var i=vs("li",{className:"vjs-menu-title",innerHTML:je(this.h.title),tabIndex:-1});this.Vt+=1,t.m.unshift(i),ms(i,t.contentEl())}if(this.items=this.createItems(),this.items)for(var s=0;s<this.items.length;s++)t.addItem(this.items[s]);return t},s.createItems=function(){},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass()})},s.buildCSSClass=function(){var i="vjs-menu-button";return!0===this.h.inline?i+="-inline":i+="-popup","vjs-menu-button "+i+" "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.one(this.menu.contentEl(),"mouseleave",_e(this,(function(t){this.unpressButton(),this.v.blur()}))),this.Ot?this.unpressButton():this.pressButton()},s.handleKeyPress=function(i){27===i.which||9===i.which?(this.Ot&&this.unpressButton(),9!==i.which&&i.preventDefault()):38===i.which||40===i.which?this.Ot||(this.pressButton(),i.preventDefault()):t.prototype.handleKeyPress.call(this,i)},s.handleSubmenuKeyPress=function(t){27!==t.which&&9!==t.which||(this.Ot&&this.unpressButton(),9!==t.which&&t.preventDefault())},s.pressButton=function(){this.Rt&&(this.Ot=!0,this.menu.lockShowing(),this.v.setAttribute("aria-expanded","true"),this.menu.focus())},s.unpressButton=function(){this.Rt&&(this.Ot=!1,this.menu.unlockShowing(),this.v.setAttribute("aria-expanded","false"),this.v.focus())},s.disable=function(){return this.Ot=!1,this.menu.unlockShowing(),this.v.setAttribute("aria-expanded","false"),this.Rt=!1,t.prototype.disable.call(this)},s.enable=function(){return this.Rt=!0,t.prototype.enable.call(this)},i}(lh);Se.registerComponent("MenuButton",qh);var Gh=function(t){function i(i,s){var e,n=s.tracks;if((e=t.call(this,i,s)||this).items.length<=1&&e.hide(),!n)return Ce(e);var r=_e(Ce(e),e.update);return n.addEventListener("removetrack",r),n.addEventListener("addtrack",r),e.t.on("dispose",(function(){n.removeEventListener("removetrack",r),n.removeEventListener("addtrack",r)})),e}return Ae(i,t),i}(qh);Se.registerComponent("TrackButton",Gh);var Xh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).selectable=s.selectable,e.selected(s.selected),e.selectable?e.v.setAttribute("role","menuitemcheckbox"):e.v.setAttribute("role","menuitem"),e}Ae(i,t);var s=i.prototype;return s.createEl=function(i,s,e){this.nonIconControl=!0;var n=t.prototype.createEl.call(this,"li",is({className:"vjs-menu-item",tabIndex:-1},s),e);return this.Lt=Gi.createTextNode(this.localize(this.h.label)),n.appendChild(this.Lt),n},s.handleClick=function(t){this.selected(!0)},s.selected=function(t){this.selectable&&(t?(this.addClass("vjs-selected"),this.v.setAttribute("aria-checked","true"),this.controlText(", selected")):(this.removeClass("vjs-selected"),this.v.setAttribute("aria-checked","false"),this.controlText("")))},s.handleLanguagechange=function(){t.prototype.handleLanguagechange.call(this),this.Lt.innerHTML=this.localize(this.h.label)},i}(lh);Se.registerComponent("MenuItem",Xh);var Jh=function(t){function i(i,s){var e,n,r=s.track,h=i.textTracks();if(s.label=r.label||r.language||"Unknown",s.selected=r.default||"showing"===r.mode,(e=t.call(this,i,s)||this).track=r,h){var a=_e(Ce(e),e.handleTracksChange);i.on(["loadstart","texttrackchange"],a),h.addEventListener("change",a),e.on("dispose",(function(){h.removeEventListener("change",a)}))}h&&void 0===h.onchange&&e.on(["tap","click"],(function(){if("object"!=typeof o.Event)try{n=new o.Event("change")}catch(t){}n||(n=Gi.createEvent("Event")).initEvent("change",!0,!0),h.dispatchEvent(n)}));return e}Ae(i,t);var s=i.prototype;return s.handleClick=function(i){var s=this.track.kind,e=this.t.textTracks();if(t.prototype.handleClick.call(this,i),e)for(var n=0;n<e.length;n++){var r=e[n];r.kind===s&&(r===this.track?"showing"!==r.mode&&(r.mode="showing"):"disabled"!==r.mode&&(r.mode="disabled"))}},s.handleTracksChange=function(t){this.selected("showing"===this.track.mode)},i}(Xh);Se.registerComponent("TextTrackMenuItem",Jh);var Qh=function(t){function i(i,s){var e;return s.track={player:i,kind:s.kind,label:s.kind+" off",default:!1,mode:"disabled"},s.selectable=!0,(e=t.call(this,i,s)||this).selected(!0),e}return Ae(i,t),i.prototype.handleTracksChange=function(t){for(var i=this.player().textTracks(),s=!0,e=0,n=i.length;e<n;e++){var r=i[e];if(r.kind===this.track.kind&&"showing"===r.mode){s=!1;break}}this.selected(s)},i}(Jh);Se.registerComponent("OffTextTrackMenuItem",Qh);var Yh=function(t){function i(i,s){return void 0===s&&(s={}),s.tracks=i.textTracks(),t.call(this,i,s)||this}return Ae(i,t),i.prototype.createItems=function(t){void 0===t&&(t=[]),t.push(new Qh(this.t,{kind:this.Ut})),this.Vt+=1;var i=this.t.textTracks();if(!i)return t;for(var s=0;s<i.length;s++){var e=i[s];e.kind===this.Ut&&t.push(new Jh(this.t,{track:e,selectable:!0}))}return t},i}(Gh);Se.registerComponent("TextTrackButton",Yh);var Kh=function(t){function i(i,s){var e,n=s.track,r=s.cue,h=i.currentTime();return s.selectable=!0,s.label=r.text,s.selected=r.startTime<=h&&h<r.endTime,(e=t.call(this,i,s)||this).track=n,e.cue=r,n.addEventListener("cuechange",_e(Ce(e),e.update)),e}Ae(i,t);var s=i.prototype;return s.handleClick=function(i){t.prototype.handleClick.call(this),this.t.currentTime(this.cue.startTime),this.update(this.cue.startTime)},s.update=function(t){var i=this.cue,s=this.t.currentTime();this.selected(i.startTime<=s&&s<i.endTime)},i}(Xh);Se.registerComponent("ChaptersTrackMenuItem",Kh);var Zh=function(t){function i(i,s,e){var n;return(n=t.call(this,i,s,e)||this).v.setAttribute("aria-label","Chapters Menu"),n}Ae(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-chapters-button "+t.prototype.buildCSSClass.call(this)},s.update=function(i){this.Ht&&(!i||"addtrack"!==i.type&&"removetrack"!==i.type)||this.setTrack(this.findChaptersTrack()),t.prototype.update.call(this)},s.setTrack=function(t){if(this.Ht!==t){if(this.zt||(this.zt=this.update.bind(this)),this.Ht){var i=this.t.remoteTextTrackEls().Y(this.Ht);i&&i.removeEventListener("load",this.zt),this.Ht=null}if(this.Ht=t,this.Ht){this.Ht.mode="hidden";var s=this.t.remoteTextTrackEls().Y(this.Ht);s&&s.addEventListener("load",this.zt)}}},s.findChaptersTrack=function(){for(var t=this.t.textTracks()||[],i=t.length-1;i>=0;i--){var s=t[i];if(s.kind===this.Ut)return s}},s.getMenuCaption=function(){return this.Ht&&this.Ht.label?this.Ht.label:this.localize(je(this.Ut))},s.createMenu=function(){return this.h.title=this.getMenuCaption(),t.prototype.createMenu.call(this)},s.createItems=function(){var t=[];if(!this.Ht)return t;var i=this.Ht.cues;if(!i)return t;for(var s=0,e=i.length;s<e;s++){var n=i[s],r=new Kh(this.t,{track:this.Ht,cue:n});t.push(r)}return t},i}(Yh);Zh.prototype.Ut="chapters",Zh.prototype.St="Chapters",Se.registerComponent("ChaptersButton",Zh);var to=function(t){function i(i,s,e){var n;(n=t.call(this,i,s,e)||this).v.setAttribute("aria-label","Descriptions Menu");var r=i.textTracks();if(r){var h=_e(Ce(n),n.handleTracksChange);r.addEventListener("change",h),n.on("dispose",(function(){r.removeEventListener("change",h)}))}return n}Ae(i,t);var s=i.prototype;return s.handleTracksChange=function(t){for(var i=this.player().textTracks(),s=!1,e=0,n=i.length;e<n;e++){var r=i[e];if(r.kind!==this.Ut&&"showing"===r.mode){s=!0;break}}s?this.disable():this.enable()},s.buildCSSClass=function(){return"vjs-descriptions-button "+t.prototype.buildCSSClass.call(this)},i}(Yh);to.prototype.Ut="descriptions",to.prototype.St="Descriptions",Se.registerComponent("DescriptionsButton",to);var io=function(t){function i(i,s,e){var n;return(n=t.call(this,i,s,e)||this).v.setAttribute("aria-label","Subtitles Menu"),n}return Ae(i,t),i.prototype.buildCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildCSSClass.call(this)},i}(Yh);io.prototype.Ut="subtitles",io.prototype.St="Subtitles",Se.registerComponent("SubtitlesButton",io);var so=function(t){function i(i,s){var e;return s.track={player:i,kind:s.kind,label:s.kind+" settings",selectable:!1,default:!1,mode:"disabled"},s.selectable=!1,(e=t.call(this,i,s)||this).addClass("vjs-texttrack-settings"),e.controlText(", opens "+s.kind+" settings dialog"),e}return Ae(i,t),i.prototype.handleClick=function(t){this.player().getChild("textTrackSettings").show(),this.player().getChild("textTrackSettings").v.focus()},i}(Jh);Se.registerComponent("CaptionSettingsMenuItem",so);var eo=function(t){function i(i,s,e){var n;return(n=t.call(this,i,s,e)||this).v.setAttribute("aria-label","Captions Menu"),n}Ae(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-captions-button "+t.prototype.buildCSSClass.call(this)},s.createItems=function(){var i=[];return this.player().H&&this.player().H.featuresNativeTextTracks||(i.push(new so(this.t,{kind:this.Ut})),this.Vt+=1),t.prototype.createItems.call(this,i)},i}(Yh);eo.prototype.Ut="captions",eo.prototype.St="Captions",Se.registerComponent("CaptionsButton",eo);var no=function(t){function i(i,s){var e,n=s.track,r=i.audioTracks();if(s.label=n.label||n.language||"Unknown",s.selected=n.enabled,(e=t.call(this,i,s)||this).track=n,r){var h=_e(Ce(e),e.handleTracksChange);r.addEventListener("change",h),e.on("dispose",(function(){r.removeEventListener("change",h)}))}return e}Ae(i,t);var s=i.prototype;return s.handleClick=function(i){var s=this.t.audioTracks();if(t.prototype.handleClick.call(this,i),s)for(var e=0;e<s.length;e++){var n=s[e];n.enabled=n===this.track}},s.handleTracksChange=function(t){this.selected(this.track.enabled)},i}(Xh);Se.registerComponent("AudioTrackMenuItem",no);var ro=function(t){function i(i,s){var e;return void 0===s&&(s={}),s.tracks=i.audioTracks&&i.audioTracks(),(e=t.call(this,i,s)||this).v.setAttribute("aria-label","Audio Menu"),e}Ae(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-audio-button "+t.prototype.buildCSSClass.call(this)},s.createItems=function(t){void 0===t&&(t=[]),this.Vt=1;var i=this.t.audioTracks&&this.t.audioTracks();if(!i)return t;for(var s=0;s<i.length;s++){var e=i[s];t.push(new no(this.t,{track:e,selectable:!0}))}return t},i}(Gh);ro.prototype.St="Audio Track",Se.registerComponent("AudioTrackButton",ro);var ho=function(t){function i(i,s){var e,n=s.rate,r=_(n,10);return s.label=n,s.selected=1===r,s.selectable=!0,(e=t.call(this,i,s)||this).label=n,e.rate=r,e.on(i,"ratechange",e.update),e}Ae(i,t);var s=i.prototype;return s.handleClick=function(i){t.prototype.handleClick.call(this),this.player().playbackRate(this.rate)},s.update=function(t){this.selected(this.player().playbackRate()===this.rate)},i}(Xh);ho.prototype.contentElType="button",Se.registerComponent("PlaybackRateMenuItem",ho);var oo=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).updateVisibility(),e.updateLabel(),e.on(i,"loadstart",e.updateVisibility),e.on(i,"ratechange",e.updateLabel),e}Ae(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this);return this.Lt=vs("div",{className:"vjs-playback-rate-value",innerHTML:1}),i.appendChild(this.Lt),i},s.buildCSSClass=function(){return"vjs-playback-rate "+t.prototype.buildCSSClass.call(this)},s.createMenu=function(){var t=new Wh(this.player()),i=this.playbackRates();if(i)for(var s=i.length-1;s>=0;s--)t.addChild(new ho(this.player(),{rate:i[s]+"x"}));return t},s.updateARIAAttributes=function(){this.el().setAttribute("aria-valuenow",this.player().playbackRate())},s.handleClick=function(t){for(var i=this.player().playbackRate(),s=this.playbackRates(),e=s[0],n=0;n<s.length;n++)if(s[n]>i){e=s[n];break}this.player().playbackRate(e)},s.playbackRates=function(){return this.h.playbackRates||this.h.playerOptions&&this.h.playerOptions.playbackRates},s.playbackRateSupported=function(){return this.player().H&&this.player().H.featuresPlaybackRate&&this.playbackRates()&&this.playbackRates().length>0},s.updateVisibility=function(t){this.playbackRateSupported()?this.removeClass("vjs-hidden"):this.addClass("vjs-hidden")},s.updateLabel=function(t){this.playbackRateSupported()&&(this.Lt.innerHTML=this.player().playbackRate()+"x")},i}(qh);oo.prototype.St="Playback Rate",Se.registerComponent("PlaybackRateMenuButton",oo);var ao=function(t){function i(){return t.apply(this,arguments)||this}Ae(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-spacer "+t.prototype.buildCSSClass.call(this)},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass()})},i}(Se);Se.registerComponent("Spacer",ao);var uo=function(t){function i(){return t.apply(this,arguments)||this}Ae(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-custom-control-spacer "+t.prototype.buildCSSClass.call(this)},s.createEl=function(){var i=t.prototype.createEl.call(this,{className:this.buildCSSClass()});return i.innerHTML=" ",i},i}(ao);Se.registerComponent("CustomControlSpacer",uo);var co=function(t){function i(){return t.apply(this,arguments)||this}return Ae(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"},{role:"group"})},i}(Se);co.prototype.h={children:["playToggle","volumeMenuButton","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subtitlesButton","captionsButton","audioTrackButton","fullscreenToggle"]},Se.registerComponent("ControlBar",co);var lo=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"error",e.open),e}Ae(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-error-display "+t.prototype.buildCSSClass.call(this)},s.content=function(){var t=this.player().error();return t?this.localize(t.message):""},i}(Ge);lo.prototype.h=xe(Ge.prototype.h,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),Se.registerComponent("ErrorDisplay",lo);var fo="vjs-text-track-settings",vo=["#000","Black"],po=["#00F","Blue"],mo=["#0FF","Cyan"],go=["#0F0","Green"],yo=["#F0F","Magenta"],bo=["#F00","Red"],wo=["#FFF","White"],ko=["#FF0","Yellow"],_o=["1","Opaque"],jo=["0.5","Semi-Transparent"],xo=["0","Transparent"],So={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[vo,wo,bo,go,po,ko,yo,mo]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[_o,jo,xo]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[wo,vo,bo,go,po,ko,yo,mo]},edgeStyle:{selector:".vjs-edge-style > select",id:"%s",label:"Text Edge Style",options:[["none","None"],["raised","Raised"],["depressed","Depressed"],["uniform","Uniform"],["dropshadow","Dropshadow"]]},fontFamily:{selector:".vjs-font-family > select",id:"captions-font-family-%s",label:"Font Family",options:[["proportionalSansSerif","Proportional Sans-Serif"],["monospaceSansSerif","Monospace Sans-Serif"],["proportionalSerif","Proportional Serif"],["monospaceSerif","Monospace Serif"],["casual","Casual"],["script","Script"],["small-caps","Small Caps"]]},fontPercent:{selector:".vjs-font-percent > select",id:"captions-font-size-%s",label:"Font Size",options:[["0.50","50%"],["0.75","75%"],["1.00","100%"],["1.25","125%"],["1.50","150%"],["1.75","175%"],["2.00","200%"],["3.00","300%"],["4.00","400%"]],default:2,parser:function(t){return"1.00"===t?null:Number(t)}},textOpacity:{selector:".vjs-text-opacity > select",id:"captions-foreground-opacity-%s",label:"Transparency",options:[_o,jo]},windowColor:{selector:".vjs-window-color > select",id:"captions-window-color-%s",label:"Color"},windowOpacity:{selector:".vjs-window-opacity > select",id:"captions-window-opacity-%s",label:"Transparency",options:[xo,jo,_o]}};function To(t,i){if(i&&(t=i(t)),t&&"none"!==t)return t}So.windowColor.options=So.backgroundColor.options;var Co,Po=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).setDefaults(),e.hide(),e.updateDisplay=_e(Ce(e),e.updateDisplay),void 0===s.persistTextTrackSettings&&(e.h.persistTextTrackSettings=e.h.playerOptions.persistTextTrackSettings),e.on(e.$(".vjs-done-button"),"click",(function(){e.saveSettings(),e.hide()})),e.on(e.$(".vjs-default-button"),"click",(function(){e.setDefaults(),e.updateDisplay()})),ts(So,(function(t){e.on(e.$(t.selector),"change",e.updateDisplay)})),e.h.persistTextTrackSettings&&e.restoreSettings(),e}Ae(i,t);var s=i.prototype;return s.Wt=function(t){var i=this,s=So[t],e=s.id.replace("%s",this.o);return[vs("label",{className:"vjs-label",textContent:s.label},{for:e}),vs("select",{id:e},void 0,s.options.map((function(t){return vs("option",{textContent:i.localize(t[1]),value:t[0]})})))]},s.qt=function(){var t=vs("legend",{textContent:this.localize("Text")}),i=this.Wt("color"),s=vs("span",{className:"vjs-text-opacity vjs-opacity"},void 0,this.Wt("textOpacity"));return vs("fieldset",{className:"vjs-fg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Gt=function(){var t=vs("legend",{textContent:this.localize("Background")}),i=this.Wt("backgroundColor"),s=vs("span",{className:"vjs-bg-opacity vjs-opacity"},void 0,this.Wt("backgroundOpacity"));return vs("fieldset",{className:"vjs-bg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Xt=function(){var t=vs("legend",{textContent:this.localize("Window")}),i=this.Wt("windowColor"),s=vs("span",{className:"vjs-window-opacity vjs-opacity"},void 0,this.Wt("windowOpacity"));return vs("fieldset",{className:"vjs-window-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Jt=function(){return vs("div",{className:"vjs-tracksettings-colors"},void 0,[this.qt(),this.Gt(),this.Xt()])},s.Qt=function(){var t=vs("div",{className:"vjs-font-percent vjs-tracksetting"},void 0,this.Wt("fontPercent")),i=vs("div",{className:"vjs-edge-style vjs-tracksetting"},void 0,this.Wt("edgeStyle")),s=vs("div",{className:"vjs-font-family vjs-tracksetting"},void 0,this.Wt("fontFamily"));return vs("div",{className:"vjs-tracksettings-font"},void 0,[t,i,s])},s.Yt=function(){var t=vs("button",{className:"vjs-default-button",textContent:this.localize("Defaults")}),i=vs("button",{className:"vjs-done-button",textContent:"Done"});return vs("div",{className:"vjs-tracksettings-controls"},void 0,[t,i])},s.createEl=function(){var t=vs("div",{className:"vjs-tracksettings"},void 0,[this.Jt(),this.Qt(),this.Yt()]),i=vs("div",{className:"vjs-control-text",id:"TTsettingsDialogLabel-"+this.o,textContent:"Caption Settings Dialog"},{"aria-level":"1",role:"heading"}),s=vs("div",{className:"vjs-control-text",id:"TTsettingsDialogDescription-"+this.o,textContent:"Beginning of dialog window. Escape will cancel and close the window."}),e=vs("div",void 0,{role:"document"},[i,s,t]);return vs("div",{className:"vjs-caption-settings vjs-modal-overlay",tabIndex:-1},{role:"dialog","aria-labelledby":i.id,"aria-describedby":s.id},e)},s.getValues=function(){var t=this;return function(t,i,s){return void 0===s&&(s=0),Zi(t).reduce((function(s,e){return i(s,t[e],e)}),s)}(So,(function(i,s,e){var n=function(t,i){return To(t.options[t.options.selectedIndex].value,i)}(t.$(s.selector),s.parser);return void 0!==n&&(i[e]=n),i}),{})},s.setValues=function(t){var i=this;ts(So,(function(s,e){!function(t,i,s){if(i)for(var e=0;e<t.options.length;e++)if(To(t.options[e].value,s)===i){t.selectedIndex=e;break}}(i.$(s.selector),t[e],s.parser)}))},s.setDefaults=function(){var t=this;ts(So,(function(i){var s=i.hasOwnProperty("default")?i.default:0;t.$(i.selector).selectedIndex=s}))},s.restoreSettings=function(){var t;try{t=JSON.parse(o.localStorage.getItem(fo))}catch(t){n.warn(t)}t&&this.setValues(t)},s.saveSettings=function(){if(this.h.persistTextTrackSettings){var t=this.getValues();try{g.keys(t).length?o.localStorage.setItem(fo,JSON.stringify(t)):o.localStorage.removeItem(fo)}catch(t){n.warn(t)}}},s.updateDisplay=function(){var t=this.t.getChild("textTrackDisplay");t&&t.updateDisplay()},i}(Se);Se.registerComponent("TextTrackSettings",Po);var Ao,Mo=function(t){function i(i,s){var e;e=t.call(this,i,s)||this;var r=i.source,h=!1;if(r&&(e.v.currentSrc!==r.src||i.tag&&3===i.tag.Kt)?e.setSource(r):e.Zt(e.v),e.v.hasChildNodes()){for(var o=e.v.childNodes,a=o.length,u=[];a--;){var c=o[a];"track"===c.nodeName.toLowerCase()&&(e.featuresNativeTextTracks?(e.remoteTextTrackEls().J(c),e.remoteTextTracks().tt(c.track),h||e.v.hasAttribute("crossorigin")||!sn(c.src)||(h=!0)):u.push(c))}for(var l=0;l<u.length;l++)e.v.removeChild(u[l])}return["audio","video"].forEach((function(t){var i=e.el()[t+"Tracks"],s=e[t+"Tracks"](),n=je(t);e["featuresNative"+n+"Tracks"]&&i&&i.addEventListener&&(e["handle"+n+"ti"]=function(t){s.trigger({type:"change",target:s,currentTarget:s,srcElement:s})},e["handle"+n+"ii"]=function(t){return s.addTrack(t.track)},e["handle"+n+"si"]=function(t){return s.removeTrack(t.track)},i.addEventListener("change",e["handle"+n+"ti"]),i.addEventListener("addtrack",e["handle"+n+"ii"]),i.addEventListener("removetrack",e["handle"+n+"si"]),e["removeOld"+n+"ei"]=function(t){return e.ni(s,i)},e.on("loadstart",e["removeOld"+n+"ei"]))})),e.featuresNativeTextTracks&&(h&&n.warn(as(Co||(Co=Xi(["Text Tracks are being loaded from another origin but the crossorigin attribute isn't used.\n This may prevent text tracks from loading."])))),e.ri=_e(Ce(e),e.handleTextTrackChange),e.hi=_e(Ce(e),e.handleTextTrackAdd),e.oi=_e(Ce(e),e.handleTextTrackRemove),e.ai()),e.ci(),(ne||Us||Js)&&!0===i.nativeControlsForTouch&&e.setControls(!0),e.fi(),e.triggerReady(),e}Ae(i,t);var s=i.prototype;return s.dispose=function(){var s=this;["audio","video","text"].forEach((function(t){var i=je(t),e=s.v[t+"Tracks"];e&&e.removeEventListener&&(e.removeEventListener("change",s["handle"+i+"ti"]),e.removeEventListener("addtrack",s["handle"+i+"ii"]),e.removeEventListener("removetrack",s["handle"+i+"si"])),e&&s.off("loadstart",s["removeOld"+i+"ei"])})),i.disposeMediaElement(this.v),t.prototype.dispose.call(this)},s.ci=function(){var t,i=this.textTracks(),s=function(){t=[];for(var s=0;s<i.length;s++){var e=i[s];"metadata"===e.kind&&t.push({track:e,storedMode:e.mode})}};s(),i.addEventListener("change",s);var e=function s(){for(var e=0;e<t.length;e++){var n=t[e];"disabled"===n.track.mode&&n.track.mode!==n.storedMode&&(n.track.mode=n.storedMode)}i.removeEventListener("change",s)};this.on("webkitbeginfullscreen",(function(){i.removeEventListener("change",s),i.removeEventListener("change",e),i.addEventListener("change",e)})),this.on("webkitendfullscreen",(function(){i.removeEventListener("change",s),i.addEventListener("change",s),i.removeEventListener("change",e)}))},s.createEl=function(){var t=this.h.tag;if(!t||!this.h.playerElIngest&&!this.movingMediaElementInDOM){if(t){var s=t.cloneNode(!0);t.parentNode&&t.parentNode.insertBefore(s,t),i.disposeMediaElement(t),t=s}else{t=Gi.createElement("video");var e=xe({},this.h.tag&&Cs(this.h.tag));ne&&!0===this.h.nativeControlsForTouch||delete e.controls,Ts(t,is(e,{id:this.h.techId,class:"vjs-tech"}))}t.playerId=this.h.playerId}void 0!==this.h.preload&&Ps(t,"preload",this.h.preload);for(var n=["loop","muted","playsinline","autoplay"],r=n.length-1;r>=0;r--){var h=n[r],o=this.h[h];void 0!==o&&(o?Ps(t,h,h):As(t,h),t[h]=o)}return t},s.Zt=function(t){if(0!==t.networkState&&3!==t.networkState){if(0===t.readyState){var i=!1,s=function(){i=!0};this.on("loadstart",s);var e=function(){i||this.trigger("loadstart")};return this.on("loadedmetadata",e),void this.ready((function(){this.off("loadstart",s),this.off("loadedmetadata",e),i||this.trigger("loadstart")}))}var n=["loadstart"];n.push("loadedmetadata"),t.readyState>=2&&n.push("loadeddata"),t.readyState>=3&&n.push("canplay"),t.readyState>=4&&n.push("canplaythrough"),this.ready((function(){n.forEach((function(t){this.trigger(t)}),this)}))}},s.ai=function(){var t=this.el().textTracks;if(t){for(var i=0;i<t.length;i++)this.textTracks().tt(t[i]);t.addEventListener&&(t.addEventListener("change",this.ri),t.addEventListener("addtrack",this.hi),t.addEventListener("removetrack",this.oi)),this.on("loadstart",this.di)}},s.handleTextTrackChange=function(t){var i=this.textTracks();this.textTracks().trigger({type:"change",target:i,currentTarget:i,srcElement:i})},s.handleTextTrackAdd=function(t){this.textTracks().tt(t.track)},s.handleTextTrackRemove=function(t){this.textTracks().it(t.track)},s.ni=function(t,i){var s=[];if(i){for(var e=0;e<t.length;e++){for(var n=t[e],r=!1,h=0;h<i.length;h++)if(i[h]===n){r=!0;break}r||s.push(n)}for(var o=0;o<s.length;o++){var a=s[o];t.it(a)}}},s.di=function(t){var i=this.textTracks(),s=this.el().textTracks;this.ni(i,s)},s.play=function(){var t=this.v.play();void 0!==t&&"function"==typeof t.then&&t.then(null,(function(t){}))},s.setCurrentTime=function(t){try{this.v.currentTime=t}catch(t){n(t,"Video is not ready. (Video.js)")}},s.duration=function(){var t=this;if(this.v.duration===1/0&&qs&&Ks&&0===this.v.currentTime){return this.on("timeupdate",(function i(){t.v.currentTime>0&&(t.v.duration===1/0&&t.trigger("durationchange"),t.off("timeupdate",i))})),NaN}return this.v.duration||NaN},s.width=function(){return this.v.offsetWidth},s.height=function(){return this.v.offsetHeight},s.fi=function(){var t=this;if("webkitDisplayingFullscreen"in this.v){var i=function(){this.trigger("fullscreenchange",{isFullscreen:!1})},s=function(){"webkitPresentationMode"in this.v&&"picture-in-picture"!==this.v.webkitPresentationMode&&(this.one("webkitendfullscreen",i),this.trigger("fullscreenchange",{isFullscreen:!0,nativeIOSFullscreen:!0}))};this.on("webkitbeginfullscreen",s),this.on("dispose",(function(){t.off("webkitbeginfullscreen",s),t.off("webkitendfullscreen",i)}))}},s.supportsFullScreen=function(){if("function"==typeof this.v.webkitEnterFullScreen){var t=o.navigator&&o.navigator.userAgent||"";if(/Android/.test(t)||!/Chrome|Mac OS X 10.5/.test(t))return!0}return!1},s.enterFullScreen=function(){var t=this.v;t.paused&&t.networkState<=t.HAVE_METADATA?(this.v.play(),this.setTimeout((function(){t.pause(),t.webkitEnterFullScreen()}),0)):t.webkitEnterFullScreen()},s.exitFullScreen=function(){this.v.webkitExitFullScreen()},s.src=function(t){if(void 0===t)return this.v.src;this.setSrc(t)},s.reset=function(){i.resetMediaElement(this.v)},s.currentSrc=function(){return this.bt?this.bt.src:this.v.currentSrc},s.setControls=function(t){this.v.controls=!!t},s.addTextTrack=function(i,s,e){return this.featuresNativeTextTracks?this.v.addTextTrack(i,s,e):t.prototype.addTextTrack.call(this,i,s,e)},s.createRemoteTextTrack=function(i){if(!this.featuresNativeTextTracks)return t.prototype.createRemoteTextTrack.call(this,i);var s=Gi.createElement("track");return i.kind&&(s.kind=i.kind),i.label&&(s.label=i.label),(i.language||i.srclang)&&(s.srclang=i.language||i.srclang),i.default&&(s.default=i.default),i.id&&(s.id=i.id),i.src&&(s.src=i.src),s},s.addRemoteTextTrack=function(i,s){var e=t.prototype.addRemoteTextTrack.call(this,i,s);return this.featuresNativeTextTracks&&this.el().appendChild(e),e},s.removeRemoteTextTrack=function(i){if(t.prototype.removeRemoteTextTrack.call(this,i),this.featuresNativeTextTracks)for(var s=this.$$("track"),e=s.length;e--;)i!==s[e]&&i!==s[e].track||this.el().removeChild(s[e])},s.getVideoPlaybackQuality=function(){if("function"==typeof this.el().getVideoPlaybackQuality)return this.el().getVideoPlaybackQuality();var t={};return void 0!==this.el().webkitDroppedFrameCount&&void 0!==this.el().webkitDecodedFrameCount&&(t.droppedVideoFrames=this.el().webkitDroppedFrameCount,t.totalVideoFrames=this.el().webkitDecodedFrameCount),o.performance&&"function"==typeof o.performance.now?t.creationTime=o.performance.now():o.performance&&o.performance.timing&&"number"==typeof o.performance.timing.navigationStart&&(t.creationTime=o.Date.now()-o.performance.timing.navigationStart),t},i}(uh);ls()&&(Mo.TEST_VID=Gi.createElement("video"),(Ao=Gi.createElement("track")).kind="captions",Ao.srclang="en",Ao.label="English",Mo.TEST_VID.appendChild(Ao)),Mo.isSupported=function(){try{Mo.TEST_VID.volume=.5}catch(t){return!1}return!(!Mo.TEST_VID||!Mo.TEST_VID.canPlayType)},Mo.canControlVolume=function(){try{var t=Mo.TEST_VID.volume;return Mo.TEST_VID.volume=t/2+.1,t!==Mo.TEST_VID.volume}catch(t){return!1}},Mo.canControlPlaybackRate=function(){if(qs&&Ks&&Zs<58)return!1;try{var t=Mo.TEST_VID.playbackRate;return Mo.TEST_VID.playbackRate=t/2+.1,t!==Mo.TEST_VID.playbackRate}catch(t){return!1}},Mo.supportsNativeTextTracks=function(){return ee},Mo.supportsNativeVideoTracks=function(){return!(!Mo.TEST_VID||!Mo.TEST_VID.videoTracks)},Mo.supportsNativeAudioTracks=function(){return!(!Mo.TEST_VID||!Mo.TEST_VID.audioTracks)},Mo.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange"],Mo.prototype.featuresVolumeControl=Mo.canControlVolume(),Mo.prototype.featuresPlaybackRate=Mo.canControlPlaybackRate(),Mo.prototype.movingMediaElementInDOM=!zs,Mo.prototype.featuresFullscreenResize=!0,Mo.prototype.featuresProgressEvents=!0,Mo.prototype.featuresTimeupdateEvents=!0,Mo.prototype.featuresNativeTextTracks=Mo.supportsNativeTextTracks(),Mo.prototype.featuresNativeVideoTracks=Mo.supportsNativeVideoTracks(),Mo.prototype.featuresNativeAudioTracks=Mo.supportsNativeAudioTracks();var Io=Mo.TEST_VID&&Mo.TEST_VID.constructor.prototype.canPlayType,Eo=/^application\/(?:x-|vnd\.apple\.)mpegurl/i,Do=/^video\/mp4/i;Mo.patchCanPlayType=function(){Gs>=4&&!Qs?Mo.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&Eo.test(t)?"maybe":Io.call(this,t)}:Xs&&(Mo.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&Do.test(t)?"maybe":Io.call(this,t)})},Mo.unpatchCanPlayType=function(){var t=Mo.TEST_VID.constructor.prototype.canPlayType;return Mo.TEST_VID.constructor.prototype.canPlayType=Io,t},Mo.patchCanPlayType(),Mo.disposeMediaElement=function(t){if(t){var i=t.nodeName.toLowerCase();if("video"===i||"audio"===i){for(t.parentNode&&t.parentNode.removeChild(t);t.hasChildNodes();)t.removeChild(t.firstChild);t.removeAttribute("src"),"function"==typeof t.load&&function(){try{t.load()}catch(t){}}()}}},Mo.resetMediaElement=function(t){if(t){for(var i=t.querySelectorAll("source"),s=i.length;s--;)t.removeChild(i[s]);t.removeAttribute("src"),"function"==typeof t.load&&function(){try{t.load()}catch(t){}}()}},["muted","defaultMuted","autoplay","controls","loop","playsinline"].forEach((function(t){Mo.prototype[t]=function(){return this.v[t]||this.v.hasAttribute(t)}})),["muted","defaultMuted","autoplay","loop","playsinline"].forEach((function(t){Mo.prototype["set"+je(t)]=function(i){this.v[t]=i,i?this.v.setAttribute(t,t):this.v.removeAttribute(t)}})),["paused","currentTime","buffered","volume","poster","preload","error","seeking","seekable","ended","playbackRate","played","networkState","readyState","videoWidth","videoHeight"].forEach((function(t){Mo.prototype[t]=function(){return this.v[t]}})),["volume","src","poster","preload","playbackRate"].forEach((function(t){Mo.prototype["set"+je(t)]=function(i){this.v[t]=i}})),["pause","load"].forEach((function(t){Mo.prototype[t]=function(){return this.v[t]()}})),uh.withSourceHandlers(Mo),Mo.nativeSourceHandler={},Mo.nativeSourceHandler.canPlayType=function(t){try{return Mo.TEST_VID.canPlayType(t)}catch(t){return""}},Mo.nativeSourceHandler.canHandleSource=function(t,i){if(t.type)return Mo.nativeSourceHandler.canPlayType(t.type);if(t.src){var s=function(t){if("string"==typeof t){var i=/^(\/?)([\s\S]*?)((?:\.{1,2}|[^\/]+?)(\.([^\.\/\?]+)))(?:[\/]*|[\?].*)$/i.exec(t);if(i)return i.pop().toLowerCase()}return""}(t.src);return Mo.nativeSourceHandler.canPlayType("video/"+s)}return""},Mo.nativeSourceHandler.handleSource=function(t,i,s){i.setSrc(t.src)},Mo.nativeSourceHandler.dispose=function(){},Mo.registerSourceHandler(Mo.nativeSourceHandler),Se.registerComponent("Html5",Mo),uh.registerTech("Html5",Mo);var No=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","ratechange","volumechange","texttrackchange"],Fo=function(t){function i(s,e,r){var h;if(s.id=s.id||["vjs_video",Qi()].join("_"),(e=is(i.getTagSettings(s),e)).initChildren=!1,e.createEl=!1,e.reportTouchActivity=!1,!e.language)if("function"==typeof s.closest){var o=s.closest("[lang]");o&&(e.language=o.getAttribute("lang"))}else for(var a=s;a&&1===a.nodeType;){if(Cs(a).hasOwnProperty("lang")){e.language=a.getAttribute("lang");break}a=a.parentNode}if(!(h=t.call(this,null,e,r)||this).h||!h.h.techOrder||!h.h.techOrder.length)throw new v("No techOrder specified. Did you overwrite videojs.options instead of just changing the properties you want to override?");if(h.tag=s,h.tagAttributes=s&&Cs(s),h.language(h.h.language),e.languages){var u={};g.getOwnPropertyNames(e.languages).forEach((function(t){u[t.toLowerCase()]=e.languages[t]})),h.vi=u}else h.vi=i.prototype.h.languages;h.pi={},h.mi=e.poster||"",h.gi=!!e.controls,s.controls=!1,h.yi=!1,h.v=h.createEl();var c=xe(h.h);if(e.plugins){var l=e.plugins;g.getOwnPropertyNames(l).forEach((function(t){"function"==typeof this[t]?this[t](l[t]):n.error("Unable to find plugin:",t)}),Ce(h))}h.h.playerOptions=c,h.initChildren(),h.isAudio("audio"===s.nodeName.toLowerCase()),h.controls()?h.addClass("vjs-controls-enabled"):h.addClass("vjs-controls-disabled"),h.v.setAttribute("role","region"),h.isAudio()?h.v.setAttribute("aria-label","audio player"):h.v.setAttribute("aria-label","video player"),h.isAudio()&&h.addClass("vjs-audio"),h.bi()&&h.addClass("vjs-no-flex"),zs||h.addClass("vjs-workinghover"),i.players[h.o]=Ce(h);var f="5.20.6-opentelly.12".split(".")[0];return h.addClass("vjs-v"+f),h.userActive(!0),h.reportUserActivity(),h.wi(),h.on("fullscreenchange",h.ki),h.on("stageclick",h._i),h}Ae(i,t);var s=i.prototype;return s.dispose=function(){this.trigger("dispose"),this.off("dispose"),this.ji&&this.ji.parentNode&&this.ji.parentNode.removeChild(this.ji),i.players[this.o]=null,this.tag&&this.tag.player&&(this.tag.player=null),this.v&&this.v.player&&(this.v.player=null),this.H&&this.H.dispose(),t.prototype.dispose.call(this)},s.createEl=function(){var i,s=this.tag,e=this.xi=s.parentNode&&s.parentNode.hasAttribute&&s.parentNode.hasAttribute("data-vjs-player");i=this.v=e?s.parentNode:t.prototype.createEl.call(this,"div"),s.setAttribute("tabindex","-1"),s.removeAttribute("width"),s.removeAttribute("height");var n=Cs(s);if(g.getOwnPropertyNames(n).forEach((function(t){"class"===t?i.className+=" "+n[t]:i.setAttribute(t,n[t])})),s.playerId=s.id,s.id+="Si",s.className="vjs-tech",s.player=i.player=this,this.addClass("vjs-paused"),!0!==o.VIDEOJS_NO_DYNAMIC_STYLE){this.ji=we("vjs-styles-dimensions");var r=$s(".vjs-styles-defaults"),h=$s("head");h.insertBefore(this.ji,r?r.nextSibling:h.firstChild)}this.width(this.h.width),this.height(this.h.height),this.fluid(this.h.fluid),this.aspectRatio(this.h.aspectRatio);for(var a=s.getElementsByTagName("a"),u=0;u<a.length;u++){var c=a.item(u);js(c,"vjs-hidden"),c.setAttribute("hidden","hidden")}return s.Kt=s.networkState,s.parentNode&&!e&&s.parentNode.insertBefore(i,s),ms(s,i),this.m.unshift(s),this.v=i,i},s.width=function(t){return this.dimension("width",t)},s.height=function(t){return this.dimension("height",t)},s.dimension=function(t,i){var s="width"===t?"Ti":"Ci";if(void 0===i)return this[s]||0;if(""===i)this[s]=void 0;else{var e=_(i);if(j(e))return n.error('Improper value "'+i+'" supplied for for '+t),this;this[s]=e}return this.Pi(),this},s.fluid=function(t){if(void 0===t)return!!this.Ai;this.Ai=!!t,t?this.addClass("vjs-fluid"):this.removeClass("vjs-fluid"),this.Pi()},s.aspectRatio=function(t){if(void 0===t)return this.Mi;if(!/^\d+\:\d+$/.test(t))throw new v("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.Mi=t,this.fluid(!0),this.Pi()},s.Pi=function(){if(!0!==o.VIDEOJS_NO_DYNAMIC_STYLE){var t,i,s,e=(void 0!==this.Mi&&"auto"!==this.Mi?this.Mi:this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9").split(":"),n=e[1]/e[0];t=void 0!==this.Ti?this.Ti:void 0!==this.Ci?this.Ci/n:this.videoWidth()||300,i=void 0!==this.Ci?this.Ci:t*n,s=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(s),ke(this.ji,"\n ."+s+" {\n width: "+t+"px;\n height: "+i+"px;\n }\n\n ."+s+".vjs-fluid {\n padding-top: "+100*n+"%;\n }\n ")}else{var r="number"==typeof this.Ti?this.Ti:this.h.width,h="number"==typeof this.Ci?this.Ci:this.h.height,a=this.H&&this.H.el();a&&(r>=0&&(a.width=r),h>=0&&(a.height=h))}},s._t=function(t,i){var s=this;this.H&&this.Ii(),"Html5"!==t&&this.tag&&(uh.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.Ei=t,this.T=!1;var e=is({source:i,nativeControlsForTouch:this.h.nativeControlsForTouch,playerId:this.id(),techId:this.id()+"_"+t+"Di",videoTracks:this.rt,textTracks:this.nt,audioTracks:this.ht,autoplay:this.h.autoplay,playsinline:this.h.playsinline,preload:this.h.preload,loop:this.h.loop,muted:this.h.muted,poster:this.poster(),language:this.language(),playerElIngest:this.xi||!1,"vtt.js":this.h["vtt.js"]},this.h[t.toLowerCase()]);this.tag&&(e.tag=this.tag),i&&(this.Ni=i.type,i.src===this.pi.src&&this.pi.currentTime>0&&(e.startTime=this.pi.currentTime),this.pi.sources=null,this.pi.source=i,this.pi.src=i.src);var n=uh.getTech(t);n||(n=Se.getComponent(t)),this.H=new n(e),this.H.ready(_e(this,this.Fi),!0),We(this.$i||[],this.H),No.forEach((function(t){s.on(s.H,t,s["handleTech"+je(t)+"_"])})),this.on(this.H,"loadstart",this.Bi),this.on(this.H,"waiting",this.Ri),this.on(this.H,"canplay",this.Oi),this.on(this.H,"canplaythrough",this.Vi),this.on(this.H,"playing",this.Li),this.on(this.H,"ended",this.Ui),this.on(this.H,"seeking",this.Hi),this.on(this.H,"seeked",this.zi),this.on(this.H,"play",this.Wi),this.on(this.H,"firstplay",this.qi),this.on(this.H,"pause",this.Gi),this.on(this.H,"durationchange",this.Xi),this.on(this.H,"fullscreenchange",this.Ji),this.on(this.H,"error",this.Qi),this.on(this.H,"loadedmetadata",this.Pi),this.on(this.H,"resize",this.Pi),this.on(this.H,"posterchange",this.Yi),this.on(this.H,"textdata",this.Ki),this.usingNativeControls(this.Zi("controls")),this.controls()&&!this.usingNativeControls()&&this.ts(),this.H.el().parentNode===this.contentEl()||"Html5"===t&&this.tag||ms(this.H.el(),this.contentEl()),this.tag&&(this.tag.player=null,this.tag=null)},s.Ii=function(){this.rt=this.videoTracks(),this.nt=this.textTracks(),this.ht=this.audioTracks(),this.$i=ze(this.H),this.T=!1,this.H.dispose(),this.H=!1},s.tech=function(t){if(t&&t.IWillNotUseThisInPlugins)return this.H;var i="\n Please make sure that you are not using this inside of a plugin.\n To disable this alert and error, please pass in an object with\n `IWillNotUseThisInPlugins` to the `tech` method. See\n https://github.com/videojs/video.js/issues/2617 for more info.\n ";throw o.alert(i),new v(i)},s.ts=function(){this.ss(),this.on(this.H,"mousedown",this.es),this.on(this.H,"touchstart",this.ns),this.on(this.H,"touchmove",this.rs),this.on(this.H,"touchend",this.hs),this.on(this.H,"tap",this.os)},s.ss=function(){this.off(this.H,"tap",this.os),this.off(this.H,"touchstart",this.ns),this.off(this.H,"touchmove",this.rs),this.off(this.H,"touchend",this.hs),this.off(this.H,"mousedown",this.es)},s.Fi=function(){if(this.triggerReady(),this.pi.volume&&this.us("setVolume",this.pi.volume),this.Yi(),this.Xi(),(this.src()||this.currentSrc())&&this.tag&&this.h.autoplay&&this.paused()){try{delete this.tag.poster}catch(t){n("deleting tag.poster throws in some browsers",t)}this.play()}},s.Bi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-seeking"),this.error(null),this.paused()?(this.hasStarted(!1),this.trigger("loadstart")):(this.trigger("loadstart"),this.trigger("firstplay"))},s.hasStarted=function(t){return void 0!==t?(this.et!==t&&(this.et=t,t?(this.addClass("vjs-has-started"),this.trigger("firstplay")):this.removeClass("vjs-has-started")),this):!!this.et},s.Wi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},s.Ri=function(){var t=this;this.addClass("vjs-waiting"),this.trigger("waiting"),this.one("timeupdate",(function(){return t.removeClass("vjs-waiting")}))},s.Oi=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},s.Vi=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},s.Li=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},s.Hi=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},s.zi=function(){this.removeClass("vjs-seeking"),this.trigger("seeked")},s.qi=function(){this.h.starttime&&(n.warn("Passing the `starttime` option to the player will be deprecated in 6.0"),this.currentTime(this.h.starttime)),this.addClass("vjs-has-started"),this.trigger("firstplay")},s.Gi=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},s.Ui=function(){this.addClass("vjs-ended"),this.h.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},s.Xi=function(){this.duration(this.Zi("duration"))},s.es=function(t){0===t.button&&this.controls()&&(void 0!==this.h&&void 0!==this.h.userActions&&void 0!==this.h.userActions.click&&!1===this.h.userActions.click||(void 0!==this.h&&void 0!==this.h.userActions&&"function"==typeof this.h.userActions.click?this.h.userActions.click.call(this,t):this.paused()?this.play():this.pause()))},s.os=function(){this.userActive(!this.userActive())},s.ns=function(){this.userWasActive=this.userActive()},s.rs=function(){this.userWasActive&&this.reportUserActivity()},s.hs=function(t){t.cancelable&&t.preventDefault()},s.ki=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},s._i=function(){this.reportUserActivity()},s.Ji=function(t,i){i&&(this.toggleClass("vjs-ios-native-fs",!(!i.nativeIOSFullscreen||!i.isFullscreen)),this.isFullscreen(i.isFullscreen)),this.trigger("fullscreenchange")},s.Qi=function(){var t=this.H.error();this.error(t)},s.Ki=function(){var t=null;arguments.length>1&&(t=arguments[1]),this.trigger("textdata",t)},s.getCache=function(){return this.pi},s.us=function(t,i){if(this.H&&!this.H.T)this.H.ready((function(){this[t](i)}),!0);else try{this.H&&this.H[t](i)}catch(t){throw n(t),t}},s.Zi=function(t){if(this.H&&this.H.T)try{return this.H[t]()}catch(i){throw void 0===this.H[t]?n("Video.js: "+t+" method not defined for "+this.Ei+" playback technology.",i):"TypeError"===i.name?(n("Video.js: "+t+" unavailable on "+this.Ei+" playback technology element.",i),this.H.T=!1):n(i),i}},s.play=function(){return this.src()||this.currentSrc()?this.us("play"):this.H.one("loadstart",(function(){this.play()})),this},s.pause=function(){return this.us("pause"),this},s.paused=function(){return!1!==this.Zi("paused")},s.scrubbing=function(t){return void 0!==t?(this.yi=!!t,t?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing"),this):this.yi},s.currentTime=function(t){return void 0!==t?(this.us("setCurrentTime",t),this):(this.pi.currentTime=this.Zi("currentTime")||0,this.pi.currentTime)},s.duration=function(t){return void 0===t?void 0!==this.pi.duration?this.pi.duration:NaN:((t=_(t))<0&&(t=1/0),t!==this.pi.duration&&(this.pi.duration=t,t===1/0?this.addClass("vjs-live"):this.removeClass("vjs-live"),this.trigger("durationchange")),this)},s.remainingTime=function(){return this.duration()-this.currentTime()},s.buffered=function(){var t=this.Zi("buffered");return t&&t.length||(t=Ee(0,0)),t},s.bufferedPercent=function(){return De(this.buffered(),this.duration())},s.bufferedEnd=function(){var t=this.buffered(),i=this.duration(),s=t.end(t.length-1);return s>i&&(s=i),s},s.volume=function(t){var i;return void 0!==t?(i=w.max(0,w.min(1,_(t))),this.pi.volume=i,this.us("setVolume",i),this):(i=_(this.Zi("volume")),j(i)?1:i)},s.muted=function(t){return void 0!==t?(this.us("setMuted",t),this):this.Zi("muted")||!1},s.supportsFullScreen=function(){return this.Zi("supportsFullScreen")||!1},s.isFullscreen=function(t){return void 0!==t?(this.cs=!!t,this):!!this.cs},s.requestFullscreen=function(t){var i,s=Re;return this.isFullscreen(!0),s.requestFullscreen?(fe(Gi,s.fullscreenchange,_e(this,(function t(i){this.isFullscreen(Gi[s.fullscreenElement]),!1===this.isFullscreen()&&de(Gi,s.fullscreenchange,t),this.trigger("fullscreenchange")}))),s.prefixed||(i=this.h.fullscreenOptions,void 0!==t&&(i=t)),this.v[s.requestFullscreen](i)):this.H.supportsFullScreen()?this.us("enterFullScreen"):(this.enterFullWindow(),this.trigger("fullscreenchange")),this},s.exitFullscreen=function(){var t=Re;return this.isFullscreen(!1),t.requestFullscreen?Gi[t.exitFullscreen]():this.H.supportsFullScreen()?this.us("exitFullScreen"):(this.exitFullWindow(),this.trigger("fullscreenchange")),this},s.enterFullWindow=function(){this.isFullWindow=!0,this.docOrigOverflow=Gi.documentElement.style.overflow,fe(Gi,"keydown",_e(this,this.fullWindowOnEscKey)),Gi.documentElement.style.overflow="hidden",js(Gi.body,"vjs-full-window"),this.trigger("enterFullWindow")},s.fullWindowOnEscKey=function(t){27===t.keyCode&&(!0===this.isFullscreen()?this.exitFullscreen():this.exitFullWindow())},s.exitFullWindow=function(){this.isFullWindow=!1,de(Gi,"keydown",this.fullWindowOnEscKey),Gi.documentElement.style.overflow=this.docOrigOverflow,xs(Gi.body,"vjs-full-window"),this.trigger("exitFullWindow")},s.canPlayType=function(t){for(var i,s=0,e=this.h.techOrder;s<e.length;s++){var r=je(e[s]),h=uh.getTech(r);if(h||(h=Se.getComponent(r)),h){if(h.isSupported()&&(i=h.canPlayType(t)))return i}else n.error('The "'+r+'" tech is undefined. Skipped browser support check for that tech.')}return""},s.selectSource=function(t){var i,s=this,e=this.h.techOrder.map(je).map((function(t){return[t,uh.getTech(t)||Se.getComponent(t)]})).filter((function(t){var i=t[0],s=t[1];return s?s.isSupported():(n.error('The "'+i+'" tech is undefined. Skipped browser support check for that tech.'),!1)})),r=function(t,i,s){var e;return t.some((function(t){return i.some((function(i){if(e=s(t,i))return!0}))})),e},h=function(t,i){var e=t[0];if(t[1].canPlaySource(i,s.h[e.toLowerCase()]))return{source:i,tech:e}};return(this.h.sourceOrder?r(t,e,(i=h,function(t,s){return i(s,t)})):r(e,t,h))||!1},s.src=function(t){if(void 0===t)return this.Zi("src");var i=uh.getTech(this.Ei);return i||(i=Se.getComponent(this.Ei)),Array.isArray(t)?this.ls(t):"string"==typeof t?this.src({src:t}):t instanceof g&&(t.type&&!i.canPlaySource(t,this.h[this.Ei.toLowerCase()])?this.ls([t]):(this.pi.sources=null,this.pi.source=t,this.pi.src=t.src,this.Ni=t.type||"",this.ready((function(){i.prototype.hasOwnProperty("setSource")?this.us("setSource",t):this.us("src",t.src),"auto"===this.h.preload&&this.load(),this.h.autoplay&&this.play()}),!0))),this},s.ls=function(t){var i=this.selectSource(t);i?(i.tech===this.Ei?this.src(i.source):this._t(i.tech,i.source),this.pi.sources=t):(this.setTimeout((function(){this.error({code:4,message:this.localize(this.h.notSupportedMessage)})}),0),this.triggerReady())},s.load=function(){return this.us("load"),this},s.reset=function(){return this._t(je(this.h.techOrder[0]),null),this.us("reset"),this},s.currentSources=function(){var t=this.currentSource(),i=[];return 0!==g.keys(t).length&&i.push(t),this.pi.sources||i},s.currentSource=function(){var t={},i=this.currentSrc();return i&&(t.src=i),this.pi.source||t},s.currentSrc=function(){return this.Zi("currentSrc")||this.pi.src||""},s.currentType=function(){return this.Ni||""},s.preload=function(t){return void 0!==t?(this.us("setPreload",t),this.h.preload=t,this):this.Zi("preload")},s.autoplay=function(t){return void 0!==t?(this.us("setAutoplay",t),this.h.autoplay=t,this):this.Zi("autoplay",t)},s.playsinline=function(t){return void 0!==t?(this.us("setPlaysinline",t),this.h.playsinline=t,this):this.Zi("playsinline")},s.loop=function(t){return void 0!==t?(this.us("setLoop",t),this.h.loop=t,this):this.Zi("loop")},s.poster=function(t){return void 0===t?this.mi:(t||(t=""),this.mi=t,this.us("setPoster",t),this.trigger("posterchange"),this)},s.Yi=function(){!this.mi&&this.H&&this.H.poster&&(this.mi=this.H.poster()||"",this.trigger("posterchange"))},s.controls=function(t){return void 0!==t?(t=!!t,this.gi!==t&&(this.gi=t,this.usingNativeControls()&&this.us("setControls",t),t?(this.removeClass("vjs-controls-disabled"),this.addClass("vjs-controls-enabled"),this.trigger("controlsenabled"),this.usingNativeControls()||this.ts()):(this.removeClass("vjs-controls-enabled"),this.addClass("vjs-controls-disabled"),this.trigger("controlsdisabled"),this.usingNativeControls()||this.ss())),this):!!this.gi},s.usingNativeControls=function(t){return void 0!==t?(t=!!t,this.fs!==t&&(this.fs=t,t?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols"))),this):!!this.fs},s.error=function(t){return void 0===t?this.lt||null:null===t?(this.lt=t,this.removeClass("vjs-error"),this.errorDisplay&&this.errorDisplay.close(),this):(this.lt=new Le(t),this.addClass("vjs-error"),n.error("(CODE:"+this.lt.code+" "+Le.errorTypes[this.lt.code]+")",this.lt.message,this.lt),this.trigger("error"),this)},s.reportUserActivity=function(t){this.ds=!0},s.userActive=function(t){return void 0!==t?((t=!!t)!==this.vs&&(this.vs=t,t?(this.ds=!0,this.removeClass("vjs-user-inactive"),this.addClass("vjs-user-active"),this.trigger("useractive")):(this.ds=!1,this.H&&this.H.one("mousemove",(function(t){t.stopPropagation(),t.preventDefault()})),this.removeClass("vjs-user-active"),this.addClass("vjs-user-inactive"),this.trigger("userinactive"))),this):this.vs},s.wi=function(){var t,i,s,e,n=_e(this,this.reportUserActivity);this.on("mousedown",(function(){n(),this.clearInterval(t),t=this.setInterval(n,250)})),this.on("mousemove",(function(t){t.screenX===i&&t.screenY===s||(i=t.screenX,s=t.screenY,n())})),this.on("mouseup",(function(i){n(),this.clearInterval(t)})),this.on("keydown",n),this.on("keyup",n),this.setInterval((function(){if(this.ds){this.ds=!1,this.userActive(!0),this.clearTimeout(e);var t=this.h.inactivityTimeout;t>0&&(e=this.setTimeout((function(){this.ds||this.userActive(!1)}),t))}}),250)},s.playbackRate=function(t){return void 0!==t?(this.us("setPlaybackRate",t),this):this.H&&this.H.featuresPlaybackRate?this.Zi("playbackRate"):1},s.isAudio=function(t){return void 0!==t?(this.ps=!!t,this):!!this.ps},s.videoTracks=function(){return this.H?this.H.videoTracks():(this.rt=this.rt||new rh,this.rt)},s.audioTracks=function(){return this.H?this.H.audioTracks():(this.ht=this.ht||new oh,this.ht)},s.textTracks=function(){if(this.H)return this.H.textTracks()},s.remoteTextTracks=function(){if(this.H)return this.H.remoteTextTracks()},s.remoteTextTrackEls=function(){if(this.H)return this.H.remoteTextTrackEls()},s.addTextTrack=function(t,i,s){if(this.H)return this.H.addTextTrack(t,i,s)},s.addRemoteTextTrack=function(t,i){if(this.H)return this.H.addRemoteTextTrack(t,i)},s.removeRemoteTextTrack=function(t){var i=(void 0===t?{}:t).track,s=void 0===i?arguments[0]:i;if(this.H)return this.H.removeRemoteTextTrack(s)},s.getVideoPlaybackQuality=function(){return this.Zi("getVideoPlaybackQuality")},s.videoWidth=function(){return this.H&&this.H.videoWidth&&this.H.videoWidth()||0},s.videoHeight=function(){return this.H&&this.H.videoHeight&&this.H.videoHeight()||0},s.language=function(t){return void 0===t?this.gs:(this.gs!==String(t).toLowerCase()&&(this.gs=String(t).toLowerCase(),void 0!==this.v&&this.trigger("languagechange")),this)},s.languages=function(){return xe(i.prototype.h.languages,this.vi)},s.toJSON=function(){var t=xe(this.h),i=t.tracks;t.tracks=[];for(var s=0;s<i.length;s++){var e=i[s];(e=xe(e)).player=void 0,t.tracks[s]=e}return t},s.createModal=function(t,i){var s=this;(i=i||{}).content=t||"";var e=new Ge(this,i);return this.addChild(e),e.on("dispose",(function(){s.removeChild(e)})),e.open()},i.getTagSettings=function(t){var i={sources:[],tracks:[]},s=Cs(t),e=s["data-setup"];if(_s(t,"vjs-fluid")&&(s.fluid=!0),null!==e){var r=Ue(e||"{}"),h=r[0],o=r[1];h&&n.error(h),is(s,o)}if(is(i,s),t.hasChildNodes())for(var a=t.childNodes,u=0,c=a.length;u<c;u++){var l=a[u],f=l.nodeName.toLowerCase();"source"===f?i.sources.push(Cs(l)):"track"===f&&i.tracks.push(Cs(l))}return i},s.bi=function(){var t=Gi.createElement("i");return!("flexBasis"in t.style||"webkitFlexBasis"in t.style||"mozFlexBasis"in t.style||"msFlexBasis"in t.style||"msFlexOrder"in t.style)},i}(Se);Fo.players={};var $o=o.navigator;Fo.prototype.h={techOrder:["html5","flash"],html5:{},flash:{},defaultVolume:0,inactivityTimeout:2e3,playbackRates:[],children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","controlBar","errorDisplay","textTrackSettings"],language:$o&&($o.languages&&$o.languages[0]||$o.userLanguage||$o.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",fullscreenOptions:{navigationUI:"hide"}},["ended","seeking","seekable","networkState","readyState"].forEach((function(t){Fo.prototype[t]=function(){return this.Zi(t)}})),No.forEach((function(t){Fo.prototype["handleTech"+je(t)+"_"]=function(){return this.trigger(t)}})),Se.registerComponent("Player",Fo);var Bo,Ro,Oo=function(t){function i(s){var e;void 0===s&&(s={});var n=xe(s,{kind:Qe[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(te)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return g.defineProperty(r,"enabled",{get:function(){return h},set:function(t){"boolean"==typeof t&&t!==h&&(h=t,this.trigger("enabledchange"))}}),n.enabled&&(r.enabled=n.enabled),r.q=!0,r||Ce(e)}return Ae(i,t),i}(Ze),Vo=function(t){function i(s){var e;void 0===s&&(s={});var n=xe(s,{kind:Je[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(te)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return g.defineProperty(r,"selected",{get:function(){return h},set:function(t){"boolean"==typeof t&&t!==h&&(h=t,this.trigger("selectedchange"))}}),n.selected&&(r.selected=n.selected),r||Ce(e)}return Ae(i,t),i}(Ze);function Lo(t,i,s){var e;if("string"==typeof t){if(0===t.indexOf("#")&&(t=t.slice(1)),Lo.getPlayers()[t])return i&&n.warn('Player "'+t+'" is already initialised. Options will not be applied.'),s&&Lo.getPlayers()[t].ready(s),Lo.getPlayers()[t];e=function(t){return 0===t.indexOf("#")&&(t=t.slice(1)),Gi.getElementById(t)}(t)}else e=t;if(!e||!e.nodeName)throw new p("The element or ID supplied is not valid. (videojs)");if(e.player||Fo.players[e.playerId])return e.player||Fo.players[e.playerId];i=i||{},Lo.hooks("beforesetup").forEach((function(t){var s=t(e,xe(i));ss(s)&&!Array.isArray(s)?i=xe(i,s):n.error("please return an object in beforesetup hooks")}));var r=new(Se.getComponent("Player"))(e,i,s);return Lo.hooks("setup").forEach((function(t){return t(r)})),r}"undefined"==typeof HTMLVideoElement&&ls()&&(Gi.createElement("video"),Gi.createElement("audio"),Gi.createElement("track")),Lo.ys={},Lo.hooks=function(t,i){return Lo.ys[t]=Lo.ys[t]||[],i&&(Lo.ys[t]=Lo.ys[t].concat(i)),Lo.ys[t]},Lo.hook=function(t,i){Lo.hooks(t,i)},Lo.removeHook=function(t,i){var s=Lo.hooks(t).indexOf(i);return!(s<=-1)&&(Lo.ys[t]=Lo.ys[t].slice(),Lo.ys[t].splice(s,1),!0)},!0!==o.VIDEOJS_NO_DYNAMIC_STYLE&&ls()&&((Bo=$s(".vjs-styles-defaults"))||(Bo=we("vjs-styles-defaults"),(Ro=$s("head"))&&Ro.insertBefore(Bo,Ro.firstChild),ke(Bo,"\n .video-js {\n width: 300px;\n height: 150px;\n }\n\n .vjs-fluid {\n padding-top: 56.25%\n }\n "))),be(1,Lo),Lo.VERSION="5.20.6-opentelly.12",Lo.options=Fo.prototype.h,Lo.getPlayers=function(){return Fo.players},Lo.players=Fo.players,Lo.getComponent=Se.getComponent,Lo.registerComponent=function(t,i){uh.isTech(i)&&n.warn("The "+t+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),Se.registerComponent.call(Se,t,i)},Lo.getTech=uh.getTech,Lo.registerTech=uh.registerTech,Lo.browser=he,Lo.TOUCH_ENABLED=ne,Lo.extend=function(t,i){void 0===i&&(i={});var s=function(){t.apply(this,arguments)},e={};for(var r in ss(i)?("function"==typeof i.init&&(n.warn("Constructor logic via init() is deprecated; please use constructor() instead."),i.constructor=i.init),i.constructor!==g.prototype.constructor&&(s=i.constructor),e=i):"function"==typeof i&&(s=i),function(t,i){if("function"!=typeof i&&null!==i)throw new p("Super expression must either be null or a function, not "+typeof i);t.prototype=g.create(i&&i.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),i&&(t.bs=i)}(s,t),e)e.hasOwnProperty(r)&&(s.prototype[r]=e[r]);return s},Lo.mergeOptions=xe,Lo.bind=_e,Lo.plugin=function(t,i){Fo.prototype[t]=i},Lo.addLanguage=function(t,i){var s;return t=(""+t).toLowerCase(),Lo.options.languages=xe(Lo.options.languages,((s={})[t]=i,s)),Lo.options.languages[t]},Lo.log=n,Lo.createTimeRange=Lo.createTimeRanges=Ee,Lo.formatTime=jh,Lo.parseUrl=tn,Lo.isCrossOrigin=sn,Lo.EventTarget=Te,Lo.on=fe,Lo.one=pe,Lo.off=de,Lo.trigger=ve,Lo.xhr=Gr,Lo.TextTrack=Kr,Lo.AudioTrack=Oo,Lo.VideoTrack=Vo,Lo.isEl=fs,Lo.isTextNode=Es,Lo.createEl=vs,Lo.hasClass=_s,Lo.addClass=js,Lo.removeClass=xs,Lo.toggleClass=Ss,Lo.setAttributes=Ts,Lo.getAttributes=Cs,Lo.emptyEl=Ds,Lo.appendContent=Ns,Lo.insertContent=Fs,Lo.computedStyle=Mh;var Uo=10,Ho=60;function zo(t){return t.duration()===1/0}function Wo(t){return t.scrubbing()?t.getCache().currentTime:t.currentTime()}function qo(t){let i=Jo(t);return zo(t)?i.end(i.length-1):i.start(0)}function Go(t){return Jo(t).start(0)}function Xo(t){let i=Jo(t);return i.end(i.length-1)-i.start(0)}function Jo(t){let i=t.seekable();if(i&&i.length)return i;let s=t.duration();return s=isFinite(s)?s:0,new $i([0,s]).ws()}function Qo(t,i){void 0===i&&(i=t);let s=t<0?"-":"";t=w.abs(t);let e=w.floor(t%60),n=w.floor(t/60%60),r=w.floor(t/3600);const h=w.floor(i/60%60),o=w.floor(i/3600);return(j(t)||t===1/0)&&(r=n=e="-"),r=+r>0||o>0?r+":":"",n=((r||h>=10)&&+n<10?"0"+n:n)+":",e=+e<10?"0"+e:e,s+r+n+e}function Yo(){let t=this,i=Wo(t);t.toggleClass("theo-at-live",function(t,i){if(zo(t)){let s=Jo(t);return s.end(s.length-1)-i<Uo}return!1}(t,i)),t.toggleClass("theo-dvr",function(t){return zo(t)&&Xo(t)>=Ho}(t))}var Ko="theo-ad-playing",Zo="theo-dai-ad-playing";function ta(t,i,s){t.toggleClass(Ko,i),t.toggleClass(Zo,i&&s)}function ia(){this.userActive(!1)}var sa,ea,na=class{constructor(t,i){this.type=t.type,this.target=i,this.playerEvent=t}};!function(t){t.ks="unavailable",t._s="available",t.js="presenting"}(sa||(sa={})),function(t){t.LOADED="DAILoaded",t.AD_BREAK_STARTED="DAIAdBreakStarted",t.AD_BREAK_ENDED="DAIAdBreakEnded",t.AD_PERIOD_STARTED="DAIAdPeriodStarted",t.AD_PERIOD_ENDED="DAIAdPeriodEnded",t.AD_PROGRESS="DAIAdProgress",t.CUEPOINTS_CHANGED="DAICuePointsChanged",t.CLICK="DAIClick",t.ERROR="DAIError",t.STARTED="DAIStarted",t.FIRST_QUARTILE="DAIFirstQuartile",t.MIDPOINT="DAIMidpoint",t.STREAM_INITIALIZED="DAIStreamInitialized",t.THIRD_QUARTILE="DAIThirdQuartile",t.COMPLETE="DAIComplete"}(ea||(ea={}));var ra=["loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange","resize"],ha=Lo.getTech("Tech"),oa=Lo.getTech("Html5"),aa=class extends ha{xs(){var t;for(const t of ra)this.Ss.addEventListener(t,this.Ts);this.Ss.addEventListener("error",this.Cs),this.Ss.addEventListener("contentprotectionerror",this.Cs),this.Ss.addEventListener("sourcechange",this.Ps),this.Ss.addEventListener("loadstart",this.As),null==(t=this.Ss.presentation)||t.addEventListener("presentationmodechange",this.Ms),this.Ss.textTracks.addEventListener("addtrack",this.Is),this.Ss.textTracks.addEventListener("removetrack",this.Es),this.Ss.textTracks.addEventListener("change",this.Ds),this.Ss.audioTracks.addEventListener("addtrack",this.Ns),this.Ss.audioTracks.addEventListener("removetrack",this.Fs),this.Ss.audioTracks.addEventListener("change",this.$s)}Bs(){var t;for(const t of ra)this.Ss.removeEventListener(t,this.Ts);this.Ss.removeEventListener("error",this.Cs),this.Ss.removeEventListener("contentprotectionerror",this.Cs),this.Ss.removeEventListener("sourcechange",this.Ps),this.Ss.removeEventListener("loadstart",this.As),null==(t=this.Ss.presentation)||t.removeEventListener("presentationmodechange",this.Ms),this.Ss.textTracks.removeEventListener("addtrack",this.Is),this.Ss.textTracks.removeEventListener("removetrack",this.Es),this.Ss.textTracks.removeEventListener("change",this.Ds),this.Ss.audioTracks.removeEventListener("addtrack",this.Ns),this.Ss.audioTracks.removeEventListener("removetrack",this.Fs),this.Ss.audioTracks.removeEventListener("change",this.$s)}Rs(t){this.trigger(new na(t,this))}createEl(){let t=this.h,i=t.player;if(!i)throw new v(this.localize('Missing required tech option "player"'));let s=i.element;return Lo.setAttributes(s,{id:t.techId}),s}theoplayer(){return this.Ss}addTextTrack(t,i,s){return super.addTextTrack(t,i,s)}buffered(){return this.Ss.buffered}played(){return this.Ss.played}reset(){this.Ss.stop()}play(){this.Ss.play()}pause(){this.Ss.pause()}paused(){return this.Ss.paused}currentTime(){return this.Ss.currentTime}setCurrentTime(t){this.Ss.currentTime=t}duration(){return this.Ss.duration}volume(){return this.Ss.volume}setVolume(t){this.Ss.volume=t}muted(){return this.Ss.muted}setMuted(t){this.Ss.muted=t}src(t){if(void 0!==t)this.setSrc(t);else{if(this.Ss.src)return this.Ss.src;if(this.Ss.source){if(!E(this.Ss.source.ads))return this.Ss.source.ads[0].sources;if(function(t){if(t.sources)if($t(t.sources)){for(const i of t.sources)if(!Ut(i)&&"verizon-media"===i.integration)return!0}else if(!Ut(t.sources))return"verizon-media"===t.sources.integration;return!1}(this.Ss.source))return"This source is managed by the Verizon Media integration extension.";if(function(t){if(t.sources)if($t(t.sources)){for(const i of t.sources)if(ii(i))return!0}else if(Ot(t.sources))return ii(t.sources);return!1}(this.Ss.source))return"This source is managed by the DAI integration extension."}}}setSrc(t){return this.setSource({src:t})}setSource(t){this.lt=null,this.trigger("error")}currentSrc(){return this.Ss.src}load(){this.setPreload("auto")}preload(){return this.Ss.preload}setPreload(t){this.Ss.preload=t}autoplay(){return this.Ss.autoplay}setAutoplay(t){this.Ss.autoplay=!!t}seeking(){return this.Ss.seeking}seekable(){return this.Ss.seekable}ended(){return this.Ss.ended}playbackRate(){return this.Ss.playbackRate}setPlaybackRate(t){this.Ss.playbackRate=t}readyState(){return this.Ss.readyState}networkState(){return 0}controls(){return!1}videoHeight(){return this.Ss.videoHeight}videoWidth(){return this.Ss.videoWidth}supportsFullScreen(){return this.Ss.presentation.supportsMode(Ui.FULLSCREEN)}enterFullScreen(){this.Ss.presentation.requestMode(Ui.FULLSCREEN)}exitFullScreen(){this.Ss.presentation.requestMode(Ui.INLINE)}Os(){let t=this.Ss.ads;if(t&&t.playing)return!0;let i=this.Ss.vr;return!(!i||i.state===sa.ks)}initTextTrackListeners(){return this.on("touchend",(t=>{this.Os()&&(t.preventDefault=()=>{})})),super.initTextTrackListeners()}Zt(){if(!this.src())return;const t=this.readyState();if(0===t){let t=!1,i=()=>{t=!0};this.on("loadstart",i);let s=()=>{t||this.trigger("loadstart")};return this.on("loadedmetadata",s),void this.ready((()=>{this.off("loadstart",i),this.off("loadedmetadata",s),t||this.trigger("loadstart")}))}let i=["loadstart"];i.push("loadedmetadata"),t>=2&&i.push("loadeddata"),t>=3&&i.push("canplay"),t>=4&&i.push("canplaythrough"),this.ready((()=>{for(const t of i)this.trigger(t)}))}dispose(){this.Bs(),this.Ss=null,super.dispose()}static isSupported(){return!0}static canPlayType(){return"maybe"}static canPlaySource(t){return"maybe"}get featuresVolumeControl(){return Mi}constructor(t={},i){super(t,i),this.Ts=t=>this.Rs(t),this.Vs=!1,this.Ps=()=>{this.Rs(new ni(this.Ss.currentTime,this.Ss.readyState)),this.Rs(new ft)},this.As=()=>{this.Rs(new Pt(this.Ss.currentTime))},this.Is=t=>{this.textTracks().tt(t.track)},this.Ns=t=>{this.audioTracks().tt(t.track)},this.Es=t=>{this.textTracks().it(t.track)},this.Fs=t=>{this.audioTracks().it(t.track)},this.Ds=()=>{let t=this.textTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.$s=()=>{let t=this.audioTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Ms=()=>{if(!this.supportsFullScreen())return;let t=this.Vs,i=this.Ss.presentation.currentMode===Ui.FULLSCREEN;t!==i&&(this.Vs=i,this.trigger("fullscreenchange",{isFullscreen:i,nativeIOSFullscreen:!0}))},this.Cs=()=>{const t=this.Ss.errorObject,i=t&&rt(t.code)||-1,s=t&&t.message||"An unknown error occurred.";this.error({code:i,message:this.localize(s)})},this.Ss=this.h.player,this.xs();const s=!this.paused();s&&this.pause(),t.preload&&this.setPreload(t.preload),t.autoplay&&this.setAutoplay(t.autoplay),t.muted&&this.setMuted(t.muted),t.source?this.setSrc(t.source):this.Zt(),s&&this.ready((()=>this.play())),this.triggerReady()}};function ua(t){return class extends t{get Ss(){return this.Ls||(this.Ls=this.player().tech({IWillNotUseThisInPlugins:!0}).theoplayer()),this.Ls}dispose(){this.Ls=void 0,super.dispose()}constructor(...t){super(...t),this.Ls=void 0}}}aa.prototype.featuresFullscreenResize=oa.prototype.featuresFullscreenResize,aa.prototype.featuresPlaybackRate=oa.prototype.featuresPlaybackRate,aa.prototype.featuresProgressEvents=!0,aa.prototype.featuresTimeupdateEvents=!0,aa.prototype.featuresNativeTextTracks=!0,Lo.registerTech("THEOplayer",aa);var ca=class{constructor(t){this.Us=t=>{fi(this.Hs,"theo-mobile-button-hover"),t.stopImmediatePropagation()},this.zs=t=>{pi(this.Hs,"theo-mobile-button-hover")},this.Ws=t=>{this.Hs.blur()},this.Hs=t,t.addEventListener("touchstart",this.Us),t.addEventListener("touchend",this.zs),t.addEventListener("focusin",this.Ws)}},la=Lo.getComponent("Menu"),fa=class extends(ua(la)){get qs(){return this.player().el()}Gs(){fi(this.qs,"theo-menu-opened")}Xs(){pi(this.qs,"theo-menu-opened")}constructor(t,i){super(t,i)}},da=Lo.getComponent("MenuItem"),va=class extends(ua(da)){get parentMenu(){return this.Js}buildCSSClass(){return"theo-menu-item vjs-menu-item"}createEl(){let t=super.createEl("li",{className:this.buildCSSClass(),tabIndex:0},{"aria-live":"off","aria-label":""});return t.innerHTML="",t}handleClick(t){this.Qs||(this.parentMenu.Ys(this),"tap"!==t.type&&"keydown"!==t.type||(this.Qs=!0,this.trigger("click"),this.Qs=!1))}dispose(){Ct.Zs.Ks&&(this.el().removeEventListener("touchstart",this.Us),this.el().removeEventListener("touchend",this.zs)),super.dispose()}constructor(t,i,s){super(t,Di({selectable:!0},i)),this.Qs=!1,this.Us=t=>{fi(this.el(),"theo-mobile-menu-item-hover"),t.stopImmediatePropagation()},this.zs=t=>{pi(this.el(),"theo-mobile-menu-item-hover")},this.Js=s,Ct.Zs.Ks&&(this.el().addEventListener("touchstart",this.Us),this.el().addEventListener("touchend",this.zs))}},pa=Lo.getComponent("ClickableComponent"),ma=class extends pa{get parentMenu(){return this.Js}get te(){return this.ie}set te(t){this.ie=t,this.el().setAttribute("tabindex",this.te?"0":"-1"),this.se()}buildCSSClass(){return"theo-primary-background theo-menu-header"}createEl(){let t=super.createEl("div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-live":"off","aria-label":""});return t.innerHTML="",t}handleClick(t){!this.Qs&&this.te&&(this.Js.ee(),"tap"===t.type&&(this.Qs=!0,this.trigger("click"),this.Qs=!1))}se(){this.te?this.el().setAttribute("aria-label",this.localize("Go back to the previous menu")):this.el().setAttribute("aria-label","")}constructor(t,i,s){super(t,i),this.Qs=!1,this.ie=!1,this.Js=s,this.on(t,"languagechange",this.se)}},ga=class extends fa{get menuHeader(){return this.ne}get menuItems(){return this.children()}addMenuItem(t){t=Di({playerOptions:this.h.playerOptions},t);let i=new va(this.player(),t,this);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}addSubMenuItem(t){t=Di({playerOptions:this.h.playerOptions},t);let i=this.re(this.player(),t);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}removeMenuItem(t){this.removeChild(t),this.trigger("menuchange")}buildCSSClass(){return"theo-menu vjs-menu"}Gs(){super.Gs(),a.removeEventListener("resize",this.he),a.addEventListener("resize",this.he),this.show()}oe(){let t=this.ae();if(!t)return;let i=t.getClientRects();Ct.Zs.Ks?this.ue(t,i):this.ce(t,i)}ae(){var t;return null!=(t=this.contentEl().parentElement)?t:void 0}ce(t,i){}ue(t,i){}Xs(){a.removeEventListener("resize",this.he),super.Xs(),this.hide(),Ct.Zs.Ks&&(this.el().removeAttribute("style"),this.contentEl().removeAttribute("style"))}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=this.contentEl();fi(i,"theo-menu-content");let s=new ma(this.player(),this.h,this);return i.parentNode.insertBefore(s.el(),i),this.ne=s,t}Ys(t){}show(){return this.oe(),super.show()}dispose(){this.ne&&this.ne.dispose(),super.dispose()}constructor(t,i){super(t,i),this.he=()=>this.oe(),this.le=this.player().el(),this.hide(),this.on("menuchange",this.oe)}},ya=class extends ga{get fe(){return this.de}set fe(t){this.de&&this.de.ve(this),this.de=t,t&&t.pe(this)}me(t){this.fe.ge(t,"replace")}ye(t){t.fe.ge(this,"restore")}be(){pi(this.we,"vjs-hidden"),this.we.style.opacity="1",super.show()}ke(){fi(this.we,"vjs-hidden")}Gs(){this.fe&&this.fe.Gs(),super.Gs()}Xs(){this.fe&&this.fe.Xs(),super.Xs(),fi(this.we,"vjs-hidden")}ae(){if(this.fe&&this.fe._e)return this.fe._e.we}ce(t,i){if(i.length>0){let t=i[0].height,s=i[0].width;this.de.je.style.height=t+"px",this.de.je.style.width=s+"px"}super.ce(t,i)}constructor(t,i){super(t,i)}},ba=class{get je(){return this.Hs}get _e(){return this.xe}pe(t){t.ke(),this.Hs.appendChild(t.we)}ve(t){this.Hs.removeChild(t.we)}ge(t,i){if(t==this.xe)return;let s=this.xe;if(this.xe=t,this.xe.be(),this._e.focus(),Ct.Zs.Ks)s.ke();else{const t="translateX(100%)",e="translateX(-100%)",n=q("transform");s.we.style.opacity="0",s.we.style[n]="replace"===i?e:t,this.xe.we.style.opacity="1",this.xe.we.style[n]="",u((()=>{s.ke(),s.we.style[n]=""}),300)}}Gs(){this.Se(),this.xe.be(),this.Te()}Xs(){this.Se(),this.xe.ke(),this.Ce.ke(),this.xe=this.Ce,this.Te()}Te(){U((()=>{pi(this.Hs,"theo-no-transition"),pi(this.xe.we,"theo-no-transition")}))}Se(){fi(this.Hs,"theo-no-transition"),fi(this.xe.we,"theo-no-transition")}constructor(t){this.Ce=this.xe=t,this.Hs=h.createElement("div"),this.Hs.className="theo-tertiary-background theo-menu-animation-container",this.Hs.appendChild(this.Ce.we),this.le=this.xe.player().el()}},wa=class extends ya{get we(){return this.el()}get parentMenu(){return this.Pe}re(t,i){let s=new ka(t,i,this);return s.subMenu.fe=this.fe,s}ee(){this.Ae()}Ys(t){super.Ys(t),this.Ae()}Ae(){this.parentMenu.ye(this)}buildCSSClass(){return"theo-submenu "+(this.Me?"":"theo-leaf-submenu ")+"theo-menu-content theo-menu-content-animatable "+super.buildCSSClass()}addSubMenuItem(t){this.Me=!0;let i=super.addSubMenuItem(t);return this.removeClass("theo-leaf-submenu"),i}constructor(t,i,s){super(t,i),this.Me=!1,this.Pe=s,this.menuHeader.te=!0}},ka=class extends va{get subMenu(){return this.Ie}handleClick(t){this.parentMenu.me(this.subMenu)}constructor(t,i,s){super(t,Di({selectable:!1},i),s),this.Ie=new wa(t,i,s)}},_a=class extends ya{get menuButton(){return this.Ee}createEl(){let t=Lo.createEl("div",{className:this.buildCSSClass()});return this.De=super.createEl(),this.De.className=super.buildCSSClass(),fi(this.De,"theo-menu-content-animatable"),t.appendChild(this.De),this.fe=new ba(this),t.appendChild(this.fe.je),t}buildCSSClass(){return"theo-menu-animatable "+super.buildCSSClass()}re(t,i){let s=new ka(t,i,this);return s.subMenu.fe=this.fe,s}ce(t,i){super.ce(t,i);let s=this.le.getClientRects(),e=s.length>0?s[0]:void 0,n=_(getComputedStyle(this.el()).fontSize);At(this.el(),this.Ee.el(),e,n)}get we(){return this.De}ee(){this.Ee.closeMenu()}dispose(){this.Ne||(this.Ne=!0,super.dispose())}constructor(t,i,s){super(t,i),this.Ne=!1,this.Ee=s}},ja=class{set Fe(t){this.$e.innerHTML=this.Be.localize(t),this.Re(),this.Oe(),ki(this.Be.el())}get Fe(){return this.$e.textContent||""}Ve(){this.Be.off("mouseover",this.Oe),this.Be.off("mouseout",this.Re),this.Be.off("dispose",this.Le),hi(this.$e)}constructor(t,i){this.Oe=()=>{pi(this.$e,"vjs-hidden");let t=this.Be.player().contentEl().getClientRects(),i=t.length>0?t[0]:void 0,s=_(getComputedStyle(this.$e).fontSize);At(this.$e,this.Be.el(),i,s)},this.Re=()=>{fi(this.$e,"vjs-hidden")},this.Le=()=>this.Ve(),this.Be=t,ki(t.el()),xi(t.el()),this.$e=h.createElement("span"),this.$e.innerHTML=this.Be.localize(i),this.$e.className="theo-button-tooltip vjs-hidden",this.$e.setAttribute("aria-hidden","true"),this.Be.el().appendChild(this.$e),this.Be.on("mouseover",this.Oe),this.Be.on("mouseout",this.Re),this.Be.on("dispose",this.Le)}},xa=Lo.getComponent("Button"),Sa=class extends(ua(xa)){get Ue(){const t=this.el().parentElement;return!!t&&null!==t.querySelector(".theo-mobile-menu-background")}get menu(){return this.He}isMenuOpen(){return this.ze}openMenu(){this.We&&!this.ze&&(this.He.Gs(),this.el().setAttribute("aria-expanded","true"),this.ze=!0,this.He.focus())}closeMenu(){this.We&&this.ze&&(this.He.Xs(),this.el().setAttribute("aria-expanded","false"),this.ze=!1)}set minimumMenuItems(t){this.qe=t,this.Ge()}buildCSSClass(){return"theo-controlbar-button vjs-menu-button vjs-menu-button-popup "+super.buildCSSClass()}createEl(t,i,s){return super.createEl("button",{},{"aria-live":"off"})}handleClick(){this.ze?this.closeMenu():this.openMenu()}enable(){return this.We=!0,super.enable()}disable(){return this.closeMenu(),this.We=!1,super.disable()}se(){this.$e.Fe=this.controlText()}dispose(){this.player().removeChild(this.He),this.He.dispose(),this.$e.Ve(),this.Ss.removeEventListener("seeking",this.Xe),super.dispose()}constructor(t,i){super(t,i),this.ze=!1,this.qe=1,this.We=!0,this.Je=t=>{let i=this.el().contains(t.target),s=this.He.el().contains(t.target),e=!1;var n;Ct.Zs.Ks&&this.Ue&&(e=(null==(n=this.el().parentElement)?void 0:n.querySelector(".theo-mobile-menu-background"))===t.target);i||s||!this.ze||(e&&t.preventDefault(),this.closeMenu())},this.Qe=t=>{27===t.which&&(this.closeMenu(),this.focus())},this.Xe=()=>{this.ze&&this.closeMenu()},this.Ge=()=>{this.He.menuItems.length>=this.qe?this.show():(this.closeMenu(),this.hide())},this.He=new _a(t,i,this),this.player().getChild("controlBarMenuContainer").addChild(this.He),this.$e=new ja(this,this.controlText()),this.el().setAttribute("aria-haspopup","true"),Ct.Zs.Ye?(this.on(h,"touchend",this.Je),new ca(this.el())):(this.on(h,"click",this.Je),this.on(h,"keydown",this.Qe),K&&this.on(h,K.Ke,this.closeMenu)),this.Ss.addEventListener("seeking",this.Xe),this.on(this.He,"menuchange",this.Ge),this.on(t,"languagechange",this.se),this.Ge()}},Ta=Lo.getComponent("Component"),Ca=class extends(Lo.getComponent("ControlBar")){addMenuButton(t){t=Di({playerOptions:this.h.playerOptions},t);let i=new Sa(this.player(),t);return this.addChild(i),i}removeMenuButton(t){this.removeChild(t)}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-secondary-color vjs-control-bar "+super.buildCSSClass()}constructor(t,i){super(t,i),this.addChild("THEOControlBarShadow",void 0,0)}};Lo.registerComponent("THEOControlBarShadow",class extends Ta{createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-tertiary-color theo-control-bar-shadow"}});var Pa=Lo.getComponent("VolumeBar"),Aa=class extends Pa{handleFocus(t){super.handleFocus(t),this.Ze.addClass("focus-within")}handleBlur(t){super.handleBlur(t),this.Ze.removeClass("focus-within")}constructor(t,i){super(t,i),this.Ze=i.tn}},Ma=Lo.getComponent("VolumeControl"),Ia=class extends Ma{constructor(t,i){super(t,i),this.sn=new Aa(t,{tn:this}),this.addChild(this.sn)}};Ia.prototype.h=Di({},Ma.prototype.h,{children:[]}),Lo.registerComponent("VolumeControl",Ia);var Ea=class extends(ua(Ca)){nn(){return this.el().getBoundingClientRect().height}dispose(){this.el().removeEventListener("transitionstart",this.rn),this.el().removeEventListener("transitionend",this.hn),this.un.an(z.cn,this.ln),this.un.fn(),super.dispose()}constructor(t,i){super(t,i),this.rn=t=>{if("opacity"===t.propertyName){const t=this.nn();this.Ss.textTrackStyle.marginBottom!==t&&(this.Ss.textTrackStyle.marginBottom=t)}},this.hn=t=>{"opacity"===t.propertyName&&"0"===a.getComputedStyle(this.el()).opacity&&(this.Ss.textTrackStyle.marginBottom=void 0)},this.ln=()=>{void 0!==this.Ss.textTrackStyle.marginBottom&&(this.Ss.textTrackStyle.marginBottom=this.nn())},this.el().addEventListener("transitionstart",this.rn),this.el().addEventListener("transitionend",this.hn),this.un=new X(this.el()),this.un.dn(z.cn,this.ln),this.un.vn(!0)}};Ea.prototype.h=Di({},Ca.prototype.h,{children:["progressControl","playToggle","muteToggle","volumeControl","currentTimeDisplay","timeDivider","durationDisplay","liveDisplay","remainingTimeDisplay","customControlSpacer","activeQualityLabel","vrButton","descriptionsButton","subtitlesButton","chromecastButton","airplayButton","multiViewButton","audioTrackButton","SettingsButton","fullscreenToggle"]}),Lo.registerComponent("ControlBar",Ea);var Da=class extends Ca{buildCSSClass(){return"theo-top-controlbar "+super.buildCSSClass()}constructor(t,i){super(t,i),t.topControlBar=this}};Da.prototype.h=Di({},Ca.prototype.h,{children:[]}),Lo.registerComponent("TopControlBar",Da);var Na=Lo.getComponent("CurrentTimeDisplay");Lo.registerComponent("CurrentTimeDisplay",class extends Na{updateContent(){let t=this.player(),i=Wo(t),s=Go(t),e=this.localize("Current Time"),n=Qo(w.max(0,i-s),Xo(t));n!==this.Pt&&(this.Pt=n,this.contentEl().innerHTML='<span class="vjs-control-text">'+e+"</span> "+n)}constructor(t,i){super(t,i),this.on(t,"timeupdate",this.updateContent),this.on(t,"emptied",this.updateContent)}});var Fa=Lo.getComponent("DurationDisplay"),$a=class extends(ua(Fa)){updateContent(){const t=j(this.Ss.duration)?NaN:Xo(this.player()),i=this.Ss.clip.endTime-this.Ss.clip.startTime,s=w.min(t,i)||0;if(this.ct!==s){this.ct=s;const t=this.localize("Duration Time"),i=Qo(s);this.S.innerHTML='<span class="vjs-control-text">'+t+"</span> "+i}}constructor(t,i){super(t,i),this.pn=()=>this.updateContent(),this.off(t,"durationchange",this.updateContent),this.on(t,"durationchange",this.updateContent),this.off(t,"timeupdate",this.updateContent),this.on(t,"timeupdate",this.updateContent),this.off(t,"emptied",this.updateContent),this.on(t,"emptied",this.updateContent),this.Ss&&this.Ss.clip.addEventListener("change",this.pn)}};Lo.registerComponent("DurationDisplay",$a);var Ba=Lo.getComponent("Button"),Ra=class extends(ua(Ba)){buildCSSClass(){return"theo-live-control "+super.buildCSSClass()}createEl(){let t=super.createEl("button",{},{"aria-live":"off"});return this.mn=Lo.createEl("span",{className:"theo-live-control-indicator"}),t.insertBefore(this.mn,t.firstChild),t}createControlTextEl(t){let i=super.createControlTextEl(t);return Lo.removeClass(i,"vjs-control-text"),Lo.addClass(i,"theo-live-control-text"),i}handleClick(){var t;const i=this.Ss;if(void 0!==(null==(t=i.hesp)?void 0:t.manifest))i.hesp.goLive();else{const t=this.player();t.currentTime(qo(t)),t.play()}}gn(){zo(this.player())?this.show():this.hide()}constructor(t,i){super(t,i),this.controlText("Live"),this.gn(),this.on(this.player(),"durationchange",this.gn),Ct.Zs.Ye&&new ca(this.el())}};Lo.registerComponent("LiveDisplay",Ra);var Oa=Lo.getComponent("LoadingSpinner");Lo.registerComponent("LoadingSpinner",class extends Oa{buildCSSClass(){return"theo-secondary-color vjs-loading-spinner "+super.buildCSSClass()}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=Lo.createEl("div",{className:"theo-loading-spinner-rotator"}),s=Lo.createEl("div",{className:"theo-loading-spinner-circle-left"}),e=Lo.createEl("div",{className:"theo-loading-spinner-circle-right"});return i.appendChild(s),i.appendChild(e),t.appendChild(i),t}constructor(t,i){super(t,i)}});var Va=Lo.getComponent("LoadProgressBar");function La(t,i){let s=t/i||0;return 100*(s>=1?1:s)+"%"}Lo.registerComponent("LoadProgressBar",class extends Va{update(){let t=this.player(),i=$i.yn(Jo(t)),s=i.bn(0),e=$i.yn(t.buffered()).wn(i),n=i.kn(0)-s,r=e.L&&e.kn(e.L-1)||0;r=w.max(0,r-s);let o=this.el(),a=this._n;o.style.width=La(r,n);for(let t=0;t<e.L;t++){let i=e.bn(t),n=e.kn(t),u=a[t];u||(u=h.createElement("div"),a.push(u),o.appendChild(u)),u.style.left=La(i-s,r),u.style.width=La(n-i,r)}for(let t=a.length;t>e.L;t--)o.removeChild(a[t-1]);a.length=e.L}constructor(t,i){super(t,i),this._n=[],this.on(t,"emptied",this.update)}});var Ua=Lo.getComponent("MouseTimeDisplay"),Ha=class extends(ua(Ua)){handleMouseMove(t){let i=t,s=this.player(),e=Go(s)+this.calculateDistance(i)*Xo(s),n=i.pageX-T(this.el().parentNode).left;this.update(e,n+"px")}handleTouchMove(t){let i=t,s=this.player(),e=Go(s)+this.calculateDistance(i)*Xo(s),n=i.touches[0].pageX-T(this.el().parentNode).left;this.update(e,n+"px")}createEl(){let t=super.createEl();return this.jn=Lo.createEl("span",{className:"theo-time-tooltip-text"}),t}update(t,i){this.xn=t;let s=this.Sn(t);this.el().style.left=i,this.el().setAttribute("data-current-time",s),this.keepTooltipsInside&&(Et(this.jn,s),this.Tn())}Tn(){if(this.keepTooltipsInside&&this.tooltip.offsetParent){let t=this.player().contentEl(),i=t.getClientRects(),s=i.length>0?i[0]:void 0,e=_(getComputedStyle(t).fontSize);At(this.tooltip,this.el(),s,e)}}Sn(t){let i=this.player();const s=t-qo(i);return Qo(zo(i)?w.min(s,0):s,Xo(i))}dispose(){var t;this.Ss.removeEventListener("dimensionchange",this.Cn),null==(t=this.Ss.presentation)||t.removeEventListener("presentationmodechange",this.Cn),super.dispose()}constructor(t,i){var s;(super(t,i),this.xn=NaN,this.Cn=()=>{let t=this.player(),i=t.scrubbing()?t.getCache().currentTime:t.currentTime(),s=(i-Go(t))/Xo(t)||0;s=Yt(s,0,1),this.update(i,100*s+"%")},this.keepTooltipsInside&&(Lo.addClass(this.tooltip,"theo-secondary-color"),this.tooltip.appendChild(this.jn)),this.on(t,"ready",(()=>{this.on(t.controlBar.progressControl,"mouseenter",this.handleMouseMove)})),Mt.Ks)&&(this.on(t,"firstplay",this.Cn),this.on(t,"play",this.Cn),this.on(t,"seeking",this.Cn),this.on(t,"seeked",this.Cn),this.on(t,"timeupdate",this.Cn),this.Ss.addEventListener("dimensionchange",this.Cn),null==(s=this.Ss.presentation)||s.addEventListener("presentationmodechange",this.Cn),this.on(t,"ready",(()=>{this.on(t.controlBar.progressControl,"touchstart",this.handleTouchMove),this.on(t.controlBar.progressControl,"touchmove",Xt((t=>this.handleTouchMove(t)),25)),this.Cn()})))}};Lo.registerComponent("MouseTimeDisplay",Ha);var za=Lo.getComponent("PlayProgressBar");Lo.registerComponent("PlayProgressBar",class extends za{updateDataAttr(){let t=Wo(this.player());this.el().setAttribute("data-current-time",this.Sn(t))}Sn(t){let i=this.player();return Qo(t-qo(i),Xo(i))}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-play-progress vjs-slider-bar "+super.buildCSSClass()}constructor(t,i){super(t,i)}});var Wa=Lo.getComponent("RemainingTimeDisplay");Lo.registerComponent("RemainingTimeDisplay",class extends Wa{updateContent(){const t=this.player(),i=Xo(t);if(i){const s=Jo(t).end(0),e=this.localize("Remaining Time"),n=Qo(w.max(0,s-t.currentTime()),i);n!==this.Pt&&(this.Pt=n,this.contentEl().innerHTML='<span class="vjs-control-text">'+e+"</span> -"+n)}}constructor(t,i){super(t,i),this.on(t,"timeupdate",this.updateContent),this.on(t,"emptied",this.updateContent)}});var qa=class{get Ss(){return this.Ls||(this.Ls=this.Pn.tech({IWillNotUseThisInPlugins:!0}).theoplayer()),this.Ls}An(t){if(t.kind!==dt.Mn)return;if(0===this.Ss.seekable.length)return;this.In=t;const i=t.cues.slice();this.Dn.En(i);for(let t=0;t<i.length;t++){let s=i[t],e=i[t+1],n=!e||s.endTime!==e.startTime,r=new Ga(s,this.Ss,n);this.Nn.push(r),this.Fn.appendChild(r.je)}}$n(){this.Ss.addEventListener("loadedmetadata",this.Bn),this.Ss.addEventListener("loadeddata",this.Bn),this.Ss.addEventListener("sourcechange",this.Bn),this.Ss.textTracks.addEventListener("addtrack",this.Rn),this.Ss.textTracks.addEventListener("removetrack",this.On),this.Ss.textTracks.addEventListener("change",this.Bn)}Vn(){this.Ss.removeEventListener("loadedmetadata",this.Bn),this.Ss.removeEventListener("loadeddata",this.Bn),this.Ss.removeEventListener("sourcechange",this.Bn),this.Ss.textTracks.removeEventListener("addtrack",this.Rn),this.Ss.textTracks.removeEventListener("removetrack",this.On),this.Ss.textTracks.removeEventListener("change",this.Bn)}Ln(){if(!(this.Ss.readyState<jt.Un))for(let t of this.Ss.textTracks)if(t.kind===dt.Mn&&t.mode===ut.Hn&&t.cues.length>0&&t.readyState!==ot.ERROR)return t}zn(t){this.Dn.Wn(t)}qn(){this.Dn.be()}Gn(){this.Dn.ke()}Xn(){for(let t of this.Nn)t.Ve();this.Dn.Xn(),this.Nn=[],this.In=void 0}Ve(){this.Vn(),this.Jn.removeEventListener("mousemove",this.Qn),this.Jn.removeEventListener("mouseenter",this.Yn),this.Jn.removeEventListener("mouseleave",this.Kn),this.Xn(),this.Dn.Ve(),this.Ls=void 0}constructor(t,i){this.Pn=i,this.Nn=[],this.Ls=void 0,this.Rn=t=>{let i=t.track;i.kind===dt.Mn&&(i.addEventListener("addcue",this.Bn),i.addEventListener("removecue",this.Bn),i.addEventListener("readystatechange",this.Bn)),this.Bn()},this.On=t=>{let i=t.track;i.kind===dt.Mn&&(i.removeEventListener("addcue",this.Bn),i.removeEventListener("removecue",this.Bn),i.removeEventListener("readystatechange",this.Bn)),this.Bn()},this.Qn=t=>{let i=this.Pn,s=function(t,i){let s,e,n=T(t),r=t.offsetWidth,h=t.offsetHeight,o=n.top,a=n.left;!function(t){return void 0!==t.changedTouches}(i)?(e=i.pageX,s=i.pageY):(e=i.changedTouches[0].pageX,s=i.changedTouches[0].pageY);let u=Yt((o-s+h)/h,0,1),c=Yt((e-a)/r,0,1);return{x:c,y:u}}(this.Fn,t),e=Go(i)+s.x*Xo(i);e===i.duration()&&(e-=.1),this.zn(e)},this.Kn=()=>{this.Dn.ke()},this.Yn=()=>{this.Dn.be()},this.Bn=()=>{let t=this.Ln();t!==this.In&&(this.Xn(),t&&this.An(t))},this.Jn=t,this.Dn=new Xa,this.Pn.contentEl().appendChild(this.Dn.je),this.Fn=h.createElement("div"),fi(this.Fn,"theoplayer-chapterbar"),this.Jn.appendChild(this.Fn),this.Jn.addEventListener("mousemove",this.Qn),this.Jn.addEventListener("mouseenter",this.Yn),this.Jn.addEventListener("mouseleave",this.Kn),this.$n()}},Ga=class{get je(){return this.Hs}Zn(){Ja(this.tr,this.t.currentTime)&&this.ir(),this.tr.addEventListener("enter",this.ir),this.tr.addEventListener("exit",this.sr)}er(){let t=this.t.seekable.start(0),i=this.t.seekable.end(this.t.seekable.length-1)-t,s=this.tr.startTime,e=this.tr.endTime-s,n=h.createElement("div");fi(n,"theoplayer-chapter-indicator");let r=h.createElement("div");fi(r,"theoplayer-chapter-indicator-highlight"),n.appendChild(r),this.nr&&fi(n,"theoplayer-chapter-indicator-discontinuous");let o=w.min(s/i*100,100),a=100-o,u=w.min(e/i*100,a);return n.style.width=u+"%",n.style.left=o+"%",n}Ve(){this.tr.removeEventListener("enter",this.ir),this.tr.removeEventListener("exit",this.sr),hi(this.Hs)}constructor(t,i,s){this.tr=t,this.t=i,this.nr=s,this.ir=()=>{fi(this.je,"theoplayer-chapter-indicator-active")},this.sr=()=>{pi(this.je,"theoplayer-chapter-indicator-active")},this.Hs=this.er(),this.Zn()}},Xa=class{ke(){this.rr--,0===this.rr&&pi(this.je,"theoplayer-chapter-hovering")}En(t){this.hr=t||[],this.hr.length>0&&(this.je.style.display="")}ar(t){Et(this.ur,t.content)}Xn(){this.hr=[],Et(this.ur,""),this.je.style.display="none"}be(){this.rr++,this.rr>0&&fi(this.je,"theoplayer-chapter-hovering")}Wn(t){for(let i of this.hr)if(Ja(i,t)){this.ar(i);break}}Ve(){hi(this.je)}constructor(){this.hr=[],this.rr=0,this.je=h.createElement("div"),fi(this.je,"theoplayer-chaptertitle"),this.je.style.display="none",this.ur=h.createElement("p"),this.je.appendChild(this.ur)}};function Ja(t,i){return new $i([t.startTime,t.endTime]).cr(i)}var Qa=Lo.getComponent("SeekBar"),Ya=class extends(ua(Qa)){updateAriaAttributes(t){let i=this.player(),s=Wo(i);t.setAttribute("aria-valuenow",(100*this.lr(s)).toFixed(2)),t.setAttribute("aria-valuetext",Qo(s-qo(i),Xo(i)))}getPercent(){return this.lr(this.player().currentTime())}handleMouseMove(t){if(this.Ss&&this.Ss.ads&&this.Ss.ads.playing)return;let i=this.player(),s=Go(i)+this.calculateDistance(t)*Xo(i);s>=i.duration()&&(s=i.duration()-.1),this.Fn.zn(s),i.currentTime(s)}handleMouseDown(t){this.playingStates.push(!this.player().paused()),this.Fn.qn(),super.handleMouseDown(t)}handleMouseUp(t){this.videoWasPlaying=Boolean(this.playingStates.pop()),this.Fn.Gn(),super.handleMouseUp(t)}lr(t){let i=this.player(),s=(t-Go(i))/Xo(i);return Yt(s,0,1)}dispose(){this.Fn.Ve(),A(this.playingStates)}constructor(t,i){super(t,i),this.playingStates=[],this.on(t,"emptied",this.update),this.on(t,"seeking",this.update),this.Fn=new qa(this.el(),t)}};Lo.registerComponent("SeekBar",Ya);var Ka=Lo.getComponent("ProgressControl");Ct.Zs.Ks&&Lo.registerComponent("ProgressControl",class extends Ka{createEl(){return super.createEl("div",{className:"vjs-progress-control vjs-control"})}handleMouseMove(t){this.seekBar.handleMouseMove(t)}handleMouseDown(t){this.seekBar.handleMouseDown(t)}constructor(t,i){super(t,i),this.on(this,"touchmove",this.handleMouseMove),this.on("touchstart",this.handleMouseDown),this.seekBar.off(["touchmove","touchstart"])}});var Za=Lo.getComponent("TooltipProgressBar");function tu(t){for(const i of t)if(i.enabled)return i}function iu(t){if(t)return t.label&&""!==t.label?{name:t.label,hd:!1}:{name:su(t),description:eu(t),hd:!!t.height&&t.height>=720}}function su(t){return t.height?t.height+"p":t.bandwidth?eu(t):""}function eu(t){return t.bandwidth?t.bandwidth>1e7?(t.bandwidth/1e6).toFixed(0)+"Mbps":t.bandwidth>1e6?(t.bandwidth/1e6).toFixed(1)+"Mbps":(t.bandwidth/1e3).toFixed(0)+"kbps":""}Lo.registerComponent("TooltipProgressBar",class extends Za{updateDataAttr(){let t=Wo(this.player()),i=this.Sn(t);this.el().setAttribute("data-current-time",i),this.tooltip.innerHTML=i}Sn(t){let i=this.player();return Qo(t-qo(i),Xo(i))}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-tooltip-progress-bar vjs-slider-bar "+super.buildCSSClass()}constructor(t,i){super(t,i)}});var nu=class{get dr(){return this.pr}set dr(t){let i=this.pr;for(let s=i.length-1;s>=0;s--){let e=i[s];C(t,e)||this.mr(e)}for(let i of t)this.gr(i);this.yr.oe()}get br(){return this.yr.menuItems}wr(t){let i=this.br;if(i)for(let s of i)if(s.kr===t)return s}_r(t){let i=this.yr.addMenuItem();return i.kr=t,i.on("click",(()=>this.jr(i))),i.el().setAttribute("role","menuitemradio"),i}Sr(t){t.dispose()}Tr(t){return!0}gr(t){if(this.Tr(t)){C(this.pr,t)||this.pr.push(t);let i=this.wr(t)||this._r(t);return this.Cr(i),i}this.mr(t)}mr(t){let i=this.wr(t);i&&(this.yr.removeMenuItem(i),this.Sr(i)),Hi(this.pr,t)}Ve(){const t=[];for(let i of this.pr)t.push(i);for(let i of t)this.mr(i);A(t)}constructor(t){this.pr=[],this.yr=t}},ru=class extends nu{Pr(){return this.Ar=h.createElement("span"),this.Ar.className="theo-settings-control-menu-item-title",Et(this.Ar,this.Mr.localize("Quality")),this.Ar}Ir(){return this.Er=h.createElement("span"),this.Er.className="theo-settings-control-menu-quality-automatic",Et(this.Er,this.Mr.localize("Automatic")),this.Er}Dr(){return this.Nr=h.createElement("span"),Et(this.Nr,this.Mr.localize("Automatic")),this.Nr}Fr(){return this.$r=h.createElement("span"),this.$r.className="theo-primary-color theo-settings-control-menu-item-hd-label",Et(this.$r,this.Mr.localize("HD")),this.$r}Br(){let t=h.createElement("span");t.className="theo-primary-color theo-settings-control-menu-item-value",t.appendChild(this.Er),t.appendChild(h.createTextNode(" ")),t.appendChild(this.Nr),t.appendChild(h.createTextNode(" ")),t.appendChild(this.$r),this.Rr.el().appendChild(this.Ar),this.Rr.el().appendChild(t),this.Rr.el().setAttribute("aria-label",this.Mr.localize("Open the video quality settings menu"))}Or(){let t=this.Vr,i=t&&fu(t.targetQuality),s=t&&t.activeQuality,e=iu(this.Lr(i||s))||{name:this.Mr.localize("Automatic")};Et(this.Nr,e.name),yi(this.Er,"vjs-hidden",!!i),yi(this.$r,"vjs-hidden",!e.hd)}Cr(t){let i=iu(t.kr)||{name:this.Mr.localize("Automatic")},s=i.name;i.hd&&(s+='<span class="theo-primary-color theo-settings-control-menu-item-hd-label">'+this.Mr.localize("HD")+"</span>"),i.description&&(s+='<span class="theo-settings-control-submenu-item-alternate-value">'+i.description+"</span>"),t.el().innerHTML=s,t.el().setAttribute("aria-label",this.Mr.localize("Set video quality to ")+i.name),t.kr?t.selected(t.kr===this.Ur):t.selected(!this.Ur)}jr(t){this.Vr&&(this.Vr.targetQuality=t.kr&&t.kr.videoQualities)}Lr(t,i){const s=i||this.dr;for(let i of s)if(t&&i&&-1!==i.videoQualities.indexOf(t))return i}Ve(){this.Ls.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.Hr),this.Mr.off("languagechange",this.se),this.Vr&&(this.Vr.removeEventListener("activequalitychanged",this.zr),this.Vr.removeEventListener("targetqualitychanged",this.Wr),this.Vr.removeEventListener("update",this.qr)),super.Ve()}constructor(t,i,s){super(t.subMenu),this.Vr=void 0,this.Ur=void 0,this.Hr=()=>{let t=tu(this.Ls.videoTracks);if(t===this.Vr)return;let i=[];if(this.Vr&&(this.Vr.removeEventListener("activequalitychanged",this.zr),this.Vr.removeEventListener("targetqualitychanged",this.Wr),this.Vr.removeEventListener("update",this.qr)),this.Vr=t,t){t.addEventListener("activequalitychanged",this.zr),t.addEventListener("targetqualitychanged",this.Wr),t.addEventListener("update",this.qr);const s=ou(cu(t.qualities.filter((t=>t.available))));i=s.length>1?[void 0,...s]:[void 0]}this.dr=i,this.Wr(),this.zr()},this.qr=t=>{const i=t.track;if(i!==this.Vr)return;const s=ou(cu(i.qualities.filter((t=>t.available)))),e=i&&fu(i.targetQuality);let n;this.Ur=this.Lr(e,s),n=s.length>1?[void 0,...s]:[void 0],this.dr=n,this.Or()},this.zr=()=>{this.gr(void 0),this.Or()},this.Wr=()=>{let t=tu(this.Ls.videoTracks),i=t&&fu(t.targetQuality),s=this.Lr(i),e=this.Ur;s!==e&&(this.Ur=s,s&&e||this.gr(void 0),e&&C(this.dr,e)&&this.gr(e),i&&this.gr(s),this.Or())},this.se=()=>{Et(this.yr.menuHeader.el(),this.Mr.localize("Quality")),Et(this.Ar,this.Mr.localize("Quality")),Et(this.Er,this.Mr.localize("Automatic")),Et(this.Nr,this.Mr.localize("Automatic")),Et(this.$r,this.Mr.localize("HD")),this.Rr.el().setAttribute("aria-label",this.Mr.localize("Open the video quality settings menu"));for(const t of this.br)this.Cr(t);this.Or()},this.Rr=t,this.Ls=i,this.Mr=s,this.Ar=this.Pr(),this.Er=this.Ir(),this.Nr=this.Dr(),this.$r=this.Fr(),this.Br(),Et(this.yr.menuHeader.el(),this.Mr.localize("Quality")),this.dr=[void 0],this.Ls.videoTracks.addEventListener(["addtrack","removetrack","change"],this.Hr),this.Mr.on("languagechange",this.se),this.Hr()}},hu=class{get height(){return this.Gr[0].height}get bandwidth(){return this.Gr[0].bandwidth}get videoQualities(){return this.Gr}get label(){return this.Gr[0].label}add(t){this.Gr.push(t)}constructor(t){this.Gr=t}};function ou(t){let i=[];for(let s of t){let t=s,e=!1;for(let s of i)if(lu(s,t)){s.add(t),e=!0;break}e||i.push(new hu([t]))}return i}function au(t,i){return t&&i?Oi(t,i):Bi.Xr}function uu(t,i){return t===i?Bi.Xr:au(t.height,i.height)||au(t.width,i.width)||au(t.bandwidth,i.bandwidth)}function cu(t){return Fi(t,uu).reverse()}function lu(t,i){return t.label&&i.label&&t.label===i.label||Z(iu(t),iu(i))}function fu(t){return $t(t)?1===t.length?t[0]:void 0:t}function du(t){return 1===t?"Normal":""+w.round(100*t)/100}var vu=class extends nu{Pr(){return this.Ar=h.createElement("span"),this.Ar.className="theo-settings-control-menu-item-title",Et(this.Ar,this.Mr.localize("Speed")),this.Ar}Br(){const t=h.createElement("span");return t.className="theo-primary-color theo-settings-control-menu-item-value",this.Rr.el().appendChild(this.Ar),this.Rr.el().appendChild(t),this.Rr.el().setAttribute("aria-label",this.Mr.localize("Open the video speed settings menu")),t}_r(t){let i=super._r(t);return this.Cr(i),i}Cr(t){const i=t.kr,s=this.Mr.localize(du(i));Et(t.el(),s),t.el().setAttribute("aria-label",this.Mr.localize("Set video speed to ")+s),t.selected(t.kr===this.Ls.playbackRate)}jr(t){this.Ls.playbackRate=t.kr}Ve(){this.Ls.removeEventListener("ratechange",this.Jr),this.Mr.off("languagechange",this.se),super.Ve()}constructor(t,i,s,e){super(t.subMenu),this.Qr=void 0,this.Jr=()=>{this.Qr&&this.gr(this.Qr);let t=this.Ls.playbackRate;this.Qr=t,Et(this.Yr,this.Mr.localize(du(t))),t&&this.gr(t)},this.se=()=>{Et(this.yr.menuHeader.el(),this.Mr.localize("Speed")),Et(this.Ar,this.Mr.localize("Speed")),this.Rr.el().setAttribute("aria-label",this.Mr.localize("Open the video speed settings menu"));for(const t of this.br)this.Cr(t);this.Jr()},this.Rr=t,this.Ls=i,this.Mr=s,this.Ar=this.Pr(),this.Yr=this.Br(),Et(this.yr.menuHeader.el(),this.Mr.localize("Speed")),this.dr=e,this.Ls.addEventListener("ratechange",this.Jr),this.Mr.on("languagechange",this.se),this.Jr()}};Lo.registerComponent("SettingsButton",class extends Sa{createEl(){let t=super.createEl();return this.Kr=Lo.createEl("span",{className:"theo-settings-control-label-hd theo-primary-background"}),Et(this.Kr,this.localize("HD")),t.appendChild(this.Kr),t}buildCSSClass(){return"vjs-icon-cog theo-settings-control-button "+super.buildCSSClass()}se(){super.se(),Et(this.Kr,this.localize("HD")),Et(this.menu.menuHeader.el(),this.localize("Settings"))}dispose(){this.Vr&&(this.Vr.removeEventListener("activequalitychanged",this.zr),this.Vr=void 0),this.Ss.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.Zr),this.th.Ve(),this.ih.Ve(),super.dispose()}constructor(t,i){var s,e;super(t,i),this.Vr=void 0,this.Zr=()=>{let t=tu(this.Ss.videoTracks);t!==this.Vr&&(this.Vr&&this.Vr.removeEventListener("activequalitychanged",this.zr),this.Vr=t,t&&t.addEventListener("activequalitychanged",this.zr),this.zr())},this.zr=()=>{var t;const i=null==(t=this.Vr)?void 0:t.activeQuality,s=!!(i&&i.height>=720);this.player().toggleClass("theo-hd",s)},fi(this.menu.el(),"theo-settings-control-menu"),Et(this.menu.menuHeader.el(),t.localize("Settings")),this.controlText("Settings"),this.$e.Fe=this.controlText(),this.sh=this.menu.addSubMenuItem({name:"QualityMenuItem"}),this.th=new ru(this.sh,this.Ss,t);let n=null!=(e=null==i||null==(s=i.playerOptions)?void 0:s.playbackRates)?e:[];this.eh=this.menu.addSubMenuItem({name:"PlaybackRateMenuItem"}),this.ih=new vu(this.eh,this.Ss,t,n),this.Ss.videoTracks.addEventListener(["addtrack","removetrack","change"],this.Zr),this.Zr()}});var pu=class extends nu{nh(t){let i=t.label;if(i)return i;let s=t.language;if(s){let t=wi(s);if(t)return t.rh}return s||""}hh(){this.dr=this.oh}Ve(){this.oh.removeEventListener("addtrack",this.ah),this.oh.removeEventListener("removetrack",this.uh),this.oh.removeEventListener("change",this.lh),super.Ve()}constructor(t,i){super(t),this.ah=t=>{const i=t.track;this.gr(i),i.addEventListener("update",this.fh)},this.uh=t=>{const i=t.track;this.mr(i),i.removeEventListener("update",this.fh)},this.lh=t=>this.hh(),this.fh=()=>{for(const t of this.dr)this.gr(t)},this.oh=i,this.oh.addEventListener("addtrack",this.ah),this.oh.addEventListener("removetrack",this.uh),this.oh.addEventListener("change",this.lh),this.hh()}},mu=class extends pu{Cr(t){let i=t.kr,s=this.Mr.localize(this.nh(i));Et(t.el(),s),t.el().setAttribute("aria-label",this.Mr.localize("Set the audio language to")+" "+s),t.selected(i.enabled)}jr(t){let i=t.kr;for(let t of this.Ss.audioTracks)t!==i&&(t.enabled=!1);i.enabled=!0}Ve(){this.Mr.off("languagechange",this.se),super.Ve()}constructor(t,i,s){super(t,i.audioTracks),this.se=()=>{Et(this.yr.menuHeader.el(),this.Mr.localize("Language"));for(const t of this.br)this.Cr(t)},this.Ss=i,this.Mr=s,Et(this.yr.menuHeader.el(),this.Mr.localize("Language")),this.Mr.on("languagechange",this.se)}};Lo.registerComponent("audioTrackButton",class extends Sa{buildCSSClass(){return"vjs-icon-audio theo-audio-track-control-button "+super.buildCSSClass()}dispose(){this.dh.Ve(),super.dispose()}constructor(t,i){super(t,i),this.minimumMenuItems=2,this.dh=new mu(this.menu,this.Ss,t),this.controlText("Language"),this.$e.Fe=this.controlText()}});var gu=class extends pu{Tr(t){return!!super.Tr(t)&&(!t.forced&>(t.kind))}_r(t){let i=super._r(t);fi(i.el(),"theo-text-track-menu-item");let s=h.createElement("span");i.ph=s;let e=h.createElement("div");e.className="theo-text-track-menu-item-toggle",i.mh=e;let n=t=>this.gh(t,i);i.yh=n,e.addEventListener("click",n);let r=h.createElement("div");return r.className="theo-text-track-menu-item-toggle-slider",e.appendChild(r),i.el().appendChild(s),i.el().appendChild(e),i}Cr(t){let i=t,s=i.kr,e=this.Mr.localize(this.nh(s));Et(i.ph,e),i.el().setAttribute("aria-label",this.Mr.localize("Set the subtitle language to")+" "+e),i.el().setAttribute("role","menuitemcheckbox"),i.selected(s.mode===ut.Hn)}Sr(t){let i=t;i.mh.removeEventListener("click",i.yh),super.Sr(t)}jr(t){let i=t.kr;for(let t of this.Ss.textTracks)t!==i&&pt(t.kind,i.kind)&&(t.mode=ut.bh);i.mode!==ut.Hn?i.mode=ut.Hn:i.mode=ut.bh}gh(t,i){t.stopImmediatePropagation(),this.jr(i)}Ve(){this.Mr.off("languagechange",this.se),super.Ve()}constructor(t,i,s){super(t,i.textTracks),this.se=()=>{Et(this.yr.menuHeader.el(),this.Mr.localize("Subtitles"));for(const t of this.br)this.Cr(t)},this.Ss=i,this.Mr=s,Et(this.yr.menuHeader.el(),s.localize("Subtitles")),this.Mr.on("languagechange",this.se)}};Lo.registerComponent("subtitlesButton",class extends Sa{buildCSSClass(){return"vjs-icon-subtitles theo-text-track-control-button "+super.buildCSSClass()}dispose(){this.dh.Ve(),super.dispose()}constructor(t,i){super(t,i),this.dh=new gu(this.menu,this.Ss,t),this.controlText("Subtitles"),this.$e.Fe=this.controlText()}});var yu,bu=Lo.getComponent("playToggle");!function(t){t.wh="Pause",t.kh="Play",t._h="Replay"}(yu||(yu={}));var wu=class extends(ua(bu)){handleClick(t){this.Ss.muted||this.Ss.prepareWithUserAction(),super.handleClick(t)}handlePlay(t){super.handlePlay(t),this.controlText("Pause"),this.$e.Fe=this.controlText()}handlePause(t){this.Ss.ended||(super.handlePause(t),this.controlText("Play"),this.$e.Fe=this.controlText())}se(){this.$e.Fe=this.controlText()}dispose(){this.$e.Ve(),this.Ss.removeEventListener("ended",this.jh),super.dispose()}constructor(t,i){super(t,i),this.jh=()=>{this.controlText("Replay"),this.$e.Fe=this.controlText()},this.controlText("Play"),this.$e=new ja(this,this.controlText()),this.Ss.addEventListener("ended",this.jh),this.on(t,"languagechange",this.se),Ct.Zs.Ye&&new ca(this.el())}};Lo.registerComponent("playToggle",wu);var ku,_u=Lo.getComponent("fullscreenToggle");!function(t){t.xh="Exit fullscreen",t.Sh="Fullscreen"}(ku||(ku={}));var ju=class extends(ua(_u)){handleClick(t){this.Ss.prepareWithUserAction(),super.handleClick(t)}handleFullscreenChange(t){super.handleFullscreenChange(t),this.updateContent()}updateContent(){const t=this.player().isFullscreen()?"Exit fullscreen":"Fullscreen";this.controlText(t),this.$e.Fe=this.controlText()}dispose(){this.$e.Ve(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Fullscreen"),this.$e=new ja(this,this.controlText()),Ct.Zs.Ye&&new ca(this.el()),this.on(t,"languagechange",this.updateContent)}};Lo.registerComponent("fullscreenToggle",ju);var xu,Su=Lo.getComponent("muteToggle");!function(t){t.Th="Unmute",t.Ch="Mute"}(xu||(xu={}));var Tu=class extends(ua(Su)){handleClick(t){this.Ss.muted&&!this.Ss.paused&&this.Ss.prepareWithUserAction(),super.handleClick(t)}update(t){super.update(t),this.se()}se(){const t=this.player().muted()?"Unmute":"Mute";this.controlText(t),this.$e.Fe=this.controlText()}dispose(){this.$e.Ve(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Mute"),this.$e=new ja(this,this.controlText()),Ct.Zs.Ye&&new ca(this.el()),this.on(t,"languagechange",this.se),Ci&&(this.removeClass("vjs-hidden"),this.on(t,"loadstart",(()=>{this.removeClass("vjs-hidden")})))}};Lo.registerComponent("muteToggle",Tu);var Cu=Lo.getComponent("BigPlayButton"),Pu=class extends(ua(Cu)){createEl(){let t=super.createEl(),i=Lo.createEl("div",{className:"theo-big-play-button-svg-container"});return i.innerHTML='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 150 150" fill="currentColor">\n <circle cx="75" cy="75" r="73" fill="#000" fill-opacity="0.2"></circle>\n <circle cx="75" cy="75" r="73" class="theo-play-svg-circle" stroke-width="4" stroke="currentColor" fill="none" transform="rotate(-90,75,75)"></circle>\n <g transform="translate(85,75) scale(0.5625) translate(-75,-75)">\n <path d="m 123.89639,85.432 c -12.865,9.167 -29.482997,19.402 -49.848997,30.7 -19.634,11.035 -36.851,19.7 -51.65,26 l -16.3990002,6.099 c -1.033,-4.433 -2,-11.002 -2.9,-19.7 -2.033,-17.333 -3.04999998,-36.466 -3.04999998,-57.399 0,-19.167 1.38199998,-37.081 4.14799998,-53.75 l 4.0019995,-19.1499994 17.3990007,5.849 c 15.068,5.9999994 31.401,14.5169994 49,25.5509994 18.631,11.666 34.616997,22.766 47.948997,33.3 6.663,5.3 11.463,9.383 14.396,12.25 l -13.046,10.25"></path>\n </g>\n</svg>',t.appendChild(i),t}buildCSSClass(){return"theo-primary-color "+super.buildCSSClass()}handleClick(t){this.Ss.muted||this.Ss.prepareWithUserAction(),super.handleClick(t),void 0!==this.Ss.vr&&"unavailable"!==this.Ss.vr.state&&(this.Ss.vr.useDeviceMotionControls=!0)}};Lo.registerComponent("BigPlayButton",Pu);var Au=/^([^#]*)#xywh=(\d+),(\d+),(\d+),(\d+)\s*$/;Lo.registerComponent("MouseTimeDisplay",class extends Ha{Ph(t){const i=t.track;"metadata"===i.kind&&"thumbnails"===i.label&&void 0===this.Ah&&(this.Ah=i,this.Mh=i.src?Ct.Ih(i.src).href:void 0,this.Ah.addEventListener(["addcue","removecue"],this.Eh),this.Dh())}Nh(t){t.track===this.Ah&&this.Fh()}createEl(){const t=super.createEl();return this.$h=Lo.createEl("img",{className:"theo-time-tooltip-thumbnail"}),this.Bh=Lo.createEl("canvas",{className:"theo-time-tooltip-thumbnail"}),t}update(t,i){super.update(t,i),this.keepTooltipsInside&&this.Rh(t)}Rh(t){let i;if(this.Ah&&this.Ah.cues){let s=function(t,i){let s=t[0];for(let e of t)if(e.startTime<=i)s=e;else if(i>=e.endTime)return s;return s}(this.Ah.cues,t);i=s&&s.content}if(i===this.Oh)return;if(this.Oh=i,Lo.toggleClass(this.el(),"theo-time-tooltip-has-thumbnail",!!i),!i)return void this.Vh();const s=i.match(Au);if(s){let[,t,i,e,n,r]=s;t=this.Lh(t);const h={Uh:+i,Hh:+e,Ti:+n,Ci:+r};this.zh(t,h)}else{const t=this.Lh(i);this.zh(t)}}Dh(){j(this.xn)||this.Rh(this.xn)}Lh(t){return this.Ah&&this.Mh?Ct.Ih(t,this.Mh).href:t}zh(t,i){this.$h&&(this.$h.src!==t?(this.$h.onload=()=>{this.Wh(i)},this.$h.src="",this.$h.src=t):this.Wh(i))}Wh(t){if(!this.Bh||!this.$h)return;const i=this.Bh.getContext("2d");i&&(null!=t||(t={Uh:0,Hh:0,Ti:this.$h.naturalWidth,Ci:this.$h.naturalHeight}),this.Bh.width=t.Ti,this.Bh.height=t.Ci,i.drawImage(this.$h,t.Uh,t.Hh,t.Ti,t.Ci,0,0,t.Ti,t.Ci),this.qh(this.Bh))}qh(t){this.Gh||(this.tooltip.firstChild?this.tooltip.insertBefore(t,this.tooltip.firstChild):this.tooltip.appendChild(t),this.Gh=t),this.Tn()}Vh(){this.Gh&&(this.tooltip.removeChild(this.Gh),this.Gh=void 0,this.Tn())}Fh(){void 0!==this.Ah&&(this.Ah.removeEventListener(["addcue","removecue"],this.Eh),this.Ah=void 0),this.Mh=void 0,this.Vh(),this.Oh=void 0}dispose(){this.Fh(),super.dispose()}constructor(t,i){super(t,i),this.Gh=void 0,this.Ah=void 0,this.Mh=void 0,this.Xh=t=>this.Ph(t),this.Jh=t=>this.Nh(t),this.Eh=t=>this.Dh(),this.showThumbnails=()=>{this.Gh&&this.Gh.hidden&&(this.Gh.hidden=!1,this.Tn())},this.hideThumbnails=()=>{!this.Gh||this.Gh.hidden||this.player().scrubbing()||(this.Gh.hidden=!0,this.Tn())},this.on(this.player().textTracks(),"addtrack",this.Xh),this.on(this.player().textTracks(),"removetrack",this.Jh),Mt.Ks&&(this.on(t,"seeking",this.showThumbnails),this.on(t,"seeked",this.hideThumbnails))}});var Mu=Lo.getComponent("VolumeLevel");Lo.registerComponent("VolumeLevel",class extends Mu{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-volume-level "+super.buildCSSClass()}});var Iu=Lo.getComponent("Component"),Eu=class extends Iu{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-menu-container "+super.buildCSSClass()}};Eu.prototype.h=Di({},Eu.prototype.h,{children:[]}),Lo.registerComponent("controlBarMenuContainer",Eu);var Du=Lo.getComponent("Player"),Nu=class extends Du{dispose(){const t=this.el(),i=this.contentEl(),s=t.parentNode,e=t.nextSibling;super.dispose(),hi(i),this.xi&&s&&(e?s.insertBefore(t,e):s.appendChild(t)),h.body.removeEventListener("keydown",this.handleKeyPress),h.body.removeEventListener("click",this.handleClick)}constructor(t,i,s){super(t,i,s),this.handleKeyPress=t=>{9===t.which&&this.addClass("theo-probably-keyboard-focus")},this.handleClick=t=>{0===t.x&&0===t.y||this.removeClass("theo-probably-keyboard-focus")},h.body.addEventListener("keydown",this.handleKeyPress),h.body.addEventListener("click",this.handleClick)}};Nu.prototype.h=Di({},Du.prototype.h,{children:["bigPlayButton","AdControlPanel","TopControlBar","mediaLoader","upNextContainer","posterImage","chromecastOverlay","upcomingAdNotificationText","controlBarMenuContainer","controlBar","textTrackDisplay","loadingSpinner","errorDisplay","textTrackSettings","xrCompass"]}),Lo.registerComponent("Player",Nu);var Fu=Lo.getComponent("Player"),$u=Fu.prototype.es;Fu.prototype.es=function(t){if(!(this.H&&this.H.Os&&this.H.Os()))return $u.call(this,t)};var Bu=Fu.prototype.createEl;function Ru(t,i,s,e){let n=Di({controls:!0,playbackRates:[.25,.5,1,1.25,1.5,2]},s);n.controlBar=Di({progressControl:{keepTooltipsInside:!0}},n.controlBar);let r=n.techOrder||(n.techOrder=[]);-1===r.indexOf("THEOplayer")&&r.unshift("THEOplayer"),(n.theoplayer||(n.theoplayer={})).player=t,s&&Ot(s.language)&&(n.languages=Di({},n.languages,{[gi]:s.language}),n.language=gi),i.setAttribute("data-vjs-player","");let h=i.getAttribute("style"),o=Lo(t.element,n,e);return o.ready((()=>{!function(t){t.on("timeupdate",Yo),t.on("durationchange",Yo)}(o),function(t,i){if(i){if(i.ads){const s=i=>{const s="adbreakbegin"===i.type,e=i.adBreak.integration===Ti.Qh;ta(t,s,e)};i.ads.addEventListener("adbreakbegin",s),i.ads.addEventListener("adbreakend",s)}if(i.verizonMedia){const s=i=>{const s="adbreakbegin"===i.type;ta(t,s,!1)};i.verizonMedia.ads.adBreaks.addEventListener("addadbreak",(t=>{t.adBreak.addEventListener("adbreakbegin",s),t.adBreak.addEventListener("adbreakend",s)}))}i.addEventListener("sourcechange",(()=>{ta(t,!1,!1)}))}}(o,t),function(t){t.on("mouseleave",ia)}(o)})),i.removeAttribute("data-vjs-player"),h?i.setAttribute("style",h):i.removeAttribute("style"),Ct.Zs.Ks&&(fi(i,"theo-mobile"),Ou(i)),function(t){t.on("seeking",(()=>{ui(t.el(),"vjs-ended")&&t.currentTime()!==t.duration()&&t.play()}))}(o),o}function Ou(t){a.outerHeight>a.outerWidth?(pi(t,"theo-mobile-landscape"),fi(t,"theo-mobile-portrait")):(pi(t,"theo-mobile-portrait"),fi(t,"theo-mobile-landscape"))}Fu.prototype.createEl=function(){let t=Bu.call(this),i=Lo.createEl("div");for(i.className="theo-player-wrapper";t.firstChild;)i.appendChild(t.firstChild);return t.appendChild(i),this.S=i,t};var Vu=Lo.getComponent("Button");var Lu="THEOPiPCloseButton";Lo.registerComponent(Lu,class extends Vu{buildCSSClass(){return"theo-close-button theo-pip-close"}handleClick(){this.Kh.Yh()}constructor(t,i){if(super(t,i),this.controlText("Close Picture-in-Picture"),!function(t){return!!t&&Boolean(t.Kh)}(i))throw new v("Invalid Picture-in-picture options.");this.Kh=i.Kh}});var Uu,Hu=class extends F{get Zh(){return this.io}get so(){return this.t.cs()}eo(){this.t.dn(W.kh,this.no),this.ro||this.t.dn(W.ho,this.oo),this.t.ao.on("languagechange",this.se)}uo(){let t=this.co;if(t)return"theo-pip-"+t}lo(t){let i=this.fo;if(i&&!this.so){this.do||this.vo(),this.po(),fi(i,"theo-pip");let s=this.uo();s&&fi(i,s),this.io=!0,this.mo=t,this.yo=!1,this.bo(new Vi(Ui.PICTURE_IN_PICTURE))}}wo(t){let i=this.fo;if(i){this.ko(),pi(i,"theo-pip");let s=this.uo();s&&pi(i,s),this.io=!1,this.yo=t,this._o=this.mo,this.mo=!1,this.bo(new Vi(Ui.INLINE))}}vo(){if(!this.do){let t=this.t.ao;t.addChild(Lu,{Kh:this});let i=h.createElement("div");i.className="theo-pip-overlay",this.jo=h.createElement("div"),this.jo.className="theo-pip-overlay-text",Et(this.jo,t.localize("Video playing in Picture-in-Picture mode")),i.appendChild(this.jo),t.el().appendChild(i),this.xo=i,this.do=!0}}So(){this.To&&!this.Co&&this.t.Po&&(this.Ao=this.t.Po.Mo(Ft,this.Io),this.Co=!0)}Eo(){this.Ao&&this.t.Po&&(this.t.Po.Do(this.Ao),this.Co=!1)}po(){let t=this.t.ao.contentEl(),i=t.getBoundingClientRect(),s=h.documentElement.clientWidth,e=h.documentElement.clientHeight;t.style.top=i.top+"px",t.style.bottom=e-i.bottom+"px",t.style.right=s-i.right+"px",t.style.left=i.left+"px",t.style.width=i.width+"px",t.style.height=i.height+"px",t.style.position="fixed"}ko(){let t=this.t.ao.contentEl();t.style.top="",t.style.bottom="",t.style.right="",t.style.left="",t.style.width="",t.style.height="",t.style.position=""}No(){pi(this.fo,"theo-pip"),this.Zh&&this.co&&pi(this.fo,"theo-pip-"+this.co),this.xo&&(hi(this.xo),this.xo=void 0)}fn(){this.No(),this.Eo(),this.Fo(),this.t.an(W.kh,this.no),this.t.an(W.ho,this.oo),this.t.ao.off("languagechange",this.se),this.t=void 0}constructor(t,i,s){super(),this.$o=!1,this.io=!1,this.yo=!1,this.mo=!1,this.do=!1,this.Co=!1,this._o=!1,this.no=()=>{this.$o=!0,this.To&&!this.Zh&&this.Ao&&this.Bo&&this.Ao.Ro<=this.Bo&&this.lo(!1)},this.oo=()=>{this.ro||(this.$o=!1,this.wo(!1))},this.se=()=>{if(this.jo){const t=this.t.ao;Et(this.jo,t.localize("Video playing in Picture-in-Picture mode"))}},this.Io=t=>{!this.mo&&this.To&&(j(t)||(this.Bo&&t<=this.Bo||this._o?this.io||this.yo||this.lo(!1):this.io?this.wo(!1):this.yo=!1))},this.Bo=i.visibility,this.co=i.position,this.ro=i.retainPresentationModeOnSourceChange,this.To=void 0!==this.Bo,this.t=t,this.fo=t.Oo,this.Yh=s,this.eo()}},zu=class extends zi{Vo(){let t=super.Vo();return t===Ui.INLINE&&this.Lo&&this.Lo.Zh?Ui.PICTURE_IN_PICTURE:t}Uo(t){return t===Ui.PICTURE_IN_PICTURE||super.Uo(t)}Ho(t,i){t===Ui.FULLSCREEN&&this.Lo.Eo(),super.Ho(t,i),t!==Ui.FULLSCREEN&&this.Lo.So()}zo(t,i){t!==i&&(t===Ui.FULLSCREEN&&this.Lo.wo(!1),t===Ui.INLINE&&i===Ui.PICTURE_IN_PICTURE&&this.Lo.wo(!0),super.zo(t,i),t===Ui.PICTURE_IN_PICTURE&&(i===Ui.INLINE?this.Lo.lo(!0):this.Lo.lo(!1)))}fn(){super.fn(),this.Lo.fn(),this.Wo.an(W.kh,this.qo),this.Wo=void 0}constructor(t,i,s){super(i),this.Go=()=>this.qr(),this.Yh=()=>this.Xo(Ui.INLINE),this.qo=()=>{this.Vo()!==Ui.FULLSCREEN&&this.Lo.So(),this.Wo.an(W.kh,this.qo)},this.Wo=t,this.Lo=new Hu(t,s.pip,this.Yh),this.Lo.dn("presentationmodechange",this.Go),this.Wo.dn(W.kh,this.qo),this.qr()}},Wu=class extends F{get Jo(){return tt.Qo(this.ao.el())||this.ao.supportsFullScreen()}get cs(){return this.ao.isFullscreen()||this.Yo}lo(){this.ao.requestFullscreen()}wo(){this.ao.exitFullscreen(),this.Ko.wo()}fn(){this.Fo(),this.ao.off("fullscreenchange",this.Zo),this.Ko.an(Ri.ta,this.Zo),this.Ko.an(Ri.ia,this.Rs),this.ao.isFullWindow&&this.ao.exitFullscreen()}constructor(t,i){super(),this.Vs=!1,this.Yo=!1,this.sa=!1,this.Zo=()=>{if(this.sa)return;let t=this.Vs,i=this.cs;t!==i&&(this.Vs=i,this.bo(new Q))},this.ea=()=>{this.Yo=this.Ko.cs,this.Zo()},this.na=()=>{this.sa||(this.ao.isFullWindow&&this.ao.supportsFullScreen()||this.Yo&&!this.ao.supportsFullScreen())&&(this.sa=!0,this.ao.exitFullscreen(),this.ao.requestFullscreen(),this.sa=!1,this.Zo())},this.ao=t,this.Ko=i,this.ao.on("fullscreenchange",this.Zo),this.Ko.dn(Ri.ta,this.ea),this.Ko.dn(Ri.ra,this.na),this.Ko.dn(Ri.ia,this.Rs),this.Zo()}};function qu(t){return class extends t{get Po(){return this.ha}cs(){return"fullscreen"===this.oa.Vo()}aa(){return function(t,i){let s=g.create(t);const e=i.ao;return Y(s,{get controls(){return e.controls()},set controls(t){e.controls(it(t))},get presentation(){return i.oa.ua},get presentationMode(){return i.oa.Vo()},set presentationMode(t){const s=P(t);s&&i.oa.Xo(s)},get ui(){return e},get visibility(){return i.Po.ua}})}(this.ca,this)}fn(){super.fn(),this.oa.fn(),this.la.fn(),this.ao.dispose(),this.ha.fn()}fa(t){this.ao.src(""),super.fa(t)}constructor(t,i,s){super(i,s),this.Oo=t,this.ha=new Rt(t),this.ca=super.aa(),g.defineProperty(this.ca,"constructor",{value:Qt}),this.ao=Ru(this.ca,this.Oo,s.ui),this.la=new Wu(this.ao,this.da),this.oa=new zu(this,this.la,s),this.oa.dn("presentationmodechange",this.Rs)}}}function Gu(t){return(t=t||{}).position=function(t){switch(t){case"top-left":case"top-right":case"bottom-left":case"bottom-right":return t;default:return}}(t.position),t.visibility=function(t){if(Dt(t)&&!j(t))return Yt(t,0,1)}(t.visibility),t.retainPresentationModeOnSourceChange=it(t.retainPresentationModeOnSourceChange),t}function Xu(t){const i=Ni(t);return i.ui=i.ui||{},void 0!==(null==t?void 0:t.width)&&void 0===i.ui.width&&(i.ui.width=t.width),void 0!==(null==t?void 0:t.height)&&void 0===i.ui.height&&(i.ui.height=t.height),void 0!==(null==t?void 0:t.fluid)&&void 0===i.ui.fluid&&(i.ui.fluid=t.fluid),i.pip=Gu(i.pip),i}function Ju(){return Uu||(Uu=function(t){let i=t;for(const t of Wi)i=t(i);return i}(Uu=qu(Gt()))),Uu}function Qu(t,i){const s=Xu(i),e=h.createElement("div");e.style.position="absolute",t.appendChild(e);const n=new(Ju())(t,e,s);n.va=n;let r=n.ua;return n.pa(),n.ma(Lt),g.defineProperty(r,"constructor",{value:Qu}),r=J(r),qt(n),function(t){for(const i of qi)i(t)}(n),r}var Yu="theo-cast-",Ku=Lo.getComponent("Button"),Zu=class extends(ua(Ku)){get ga(){throw new v("ya")}get ba(){return this.h.ba}get wa(){return this.h.wa}buildCSSClass(){return Yu+"button theo-"+this.wa+"-button theo-controlbar-button "+super.buildCSSClass()}createEl(t,i,s){const e=super.createEl(),n=h.createElement("div");n.className="theo-button-icon-blur";const r=h.createElement("div");return r.className=Yu+"svg-container",r.innerHTML=this.ba,e.appendChild(n),e.appendChild(r),e}handleClick(t){var i;if(super.handleClick(t),this.ka===M.AVAILABLE)null==(i=this.ga)||i.start();else if(this.ka===M.CONNECTED||this.ka===M.CONNECTING){var s;null==(s=this.ga)||s.stop()}}_a(t){pi(this.fo,"theo-"+this.wa+"-"+this.ka),this.ka=t,fi(this.fo,"theo-"+this.wa+"-"+this.ka),this.se()}se(){this.ja(this.ka),this.$e.Fe=this.controlText()}ja(t){t===M.CONNECTED?this.controlText("Stop Casting"):t===M.AVAILABLE?this.controlText("Start Casting"):t===M.CONNECTING?this.controlText("Connecting"):this.controlText("Unavailable")}constructor(t,i){var s;super(t,i),this.fo=t.el(),this.ka=M.UNAVAILABLE,this.controlText("Unavailable"),this.$e=new ja(this,this.controlText()),null==(s=this.ga)||s.addEventListener("statechange",(t=>{const i=t;this._a(i.state)})),Ct.Zs.Ye&&(this.xa=new ca(this.el())),this._a(this.ga?this.ga.state:M.UNAVAILABLE),this.on(t,"languagechange",this.se)}},tc=0;function ic(){const t='\n <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48" fill="currentColor">\n <defs>\n <clipPath id="theo-chromecast-rings-mask-'+tc+'">\n <path d="M0-36h44V0H0z"/>\n </clipPath>\n </defs>\n <path class="theo-chromecast-outer" d="M2 10a4 4 0 0 1 4-4h36a4 4 0 0 1 4 4v28a4 4 0 0 1-4 4H28v-4h14V10H6v6H2z"/>\n <path class="theo-chromecast-inner" d="M10 14h28v20H26.74A26 26 0 0 0 10 17.26z"/>\n <g class="theo-chromecast-rings" fill="none" stroke="currentColor" stroke-width="4" transform="translate(2 42)" clip-path="url(#theo-chromecast-rings-mask-'+tc+')">\n <circle stroke="none" cx="0" cy="0" r="30" />\n <circle class="theo-chromecast-ring theo-chromecast-ring1" stroke-width="6" cx="0" cy="0" r="3" />\n <circle class="theo-chromecast-ring theo-chromecast-ring2" cx="0" cy="0" r="12" />\n <circle class="theo-chromecast-ring theo-chromecast-ring3" cx="0" cy="0" r="20"/>\n <path class="theo-chromecast-ring theo-chromecast-ring4" stroke-linecap="round" d="M0-20A20 20 0 0 1 20 0" />\n </g>\n </svg>';return tc++,t}Lo.registerComponent("chromecastButton",class extends Zu{get ga(){var t;return null==(t=this.Ss.cast)?void 0:t.chromecast}constructor(t,i){super(t,Di({},i,{wa:"chromecast",ba:ic()}))}});var sc="theo-chromecast-",ec=Lo.getComponent("Component"),nc=class t extends(ua(ec)){buildCSSClass(){return sc+"overlay "+super.buildCSSClass()}createEl(){const i=super.createEl();fi(i,sc+"overlay");const s=Lo.createEl("div",{className:sc+"status-icon",innerHTML:t.ICON_SVG}),e=Lo.createEl("div",{className:sc+"status-info"});Et(e,"Playing on");const n=Lo.createEl("div",{className:sc+"status-title"}),r=Lo.createEl("div",{className:sc+"status"});return this.ur=n,r.appendChild(s),r.appendChild(e),r.appendChild(n),i.appendChild(r),i}dispose(){var t;null==(t=this.Sa)||t.removeEventListener("statechange",this.update),this.Sa=void 0,this.Ss.removeEventListener("play",this.update),super.dispose()}constructor(t,i){var s,e;super(t,i),this.update=()=>{this.Sa?(this.ur&&Et(this.ur,this.Sa.receiverName||""),this.Sa.state===M.CONNECTED?this.show():this.hide()):this.hide()},this.Sa=null==(s=this.Ss.cast)?void 0:s.chromecast,null==(e=this.Sa)||e.addEventListener("statechange",this.update),this.Ss.addEventListener("play",this.update),this.update()}};nc.ICON_SVG='\n<svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 36 36" fill="currentColor">\n <path d="M7 24v3h3c0-1.66-1.34-3-3-3zm0-4v2c2.76 0 5 2.24 5 5h2c0-3.87-3.13-7-7-7zm18-7H11v1.63c3.96 1.28 7.09 4.41 8.37 8.37H25V13zM7 16v2a9 9 0 0 1 9 9h2c0-6.08-4.93-11-11-11zm20-7H9c-1.1 0-2 .9-2 2v3h2v-3h18v14h-7v2h7c1.1 0 2-.9 2-2V11c0-1.1-.9-2-2-2z"/>\n</svg>',Lo.registerComponent("chromecastOverlay",nc);Lo.registerComponent("airplayButton",class extends Zu{dispose(){var t,i;null==(t=this.Ss.ads)||t.removeEventListener("adbreakbegin",this.Ta),null==(i=this.Ss.ads)||i.removeEventListener("adbreakend",this.Ca),this.Ss.removeEventListener("currentsourcechange",this.Ca),super.dispose()}get ga(){var t;return null==(t=this.Ss.cast)?void 0:t.airplay}constructor(t,i){var s,e;super(t,Di({},i,{wa:"airplay",ba:'\n<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24">\n <path class="theo-cast-inner" d="M5 7h14v8H5z"/>\n <path d="M6 22h12l-6-6zM21 3H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h4v-2H3V5h18v12h-4v2h4c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/>\n</svg>'})),this.Ca=()=>{this.enable()},this.Ta=()=>{this.disable()},null==(s=this.Ss.ads)||s.addEventListener("adbreakbegin",this.Ta),null==(e=this.Ss.ads)||e.addEventListener("adbreakend",this.Ca),this.Ss.addEventListener("currentsourcechange",this.Ca)}});var rc={Default:"","Monospaced Serif":mt.Pa,"Proportional Serif":mt.Aa,"Monospaced Sans-Serif":mt.Ma,"Proportional Sans-Serif":mt.Ia},hc={White:"#ffffff",Yellow:"#ffff00",Green:"#00ff00",Cyan:"#00ffff",Blue:"#0000ff",Magenta:"#ff00ff",Red:"#ff0000",Black:"#000000"},oc=[50,75,100,150,200];function ac(t){return{label:t+"%",value:t}}function uc(t){return g.keys(t).map((i=>({label:i,value:t[i]})))}oc.map((function(t){return{label:t+"%",value:t/100+"em"}}));var cc=oc.map((function(t){return{label:t+"%",value:t+"%"}})),lc=[25,50,75,100].map(ac),fc=[0,25,50,75,100].map(ac),dc=uc(hc),vc=uc(rc),pc=uc({None:"none","Drop Shadow":"dropshadow",Raised:"raised",Depressed:"depressed",Uniform:"uniform"}),mc=100,gc="#000000",yc="#FFFFFF",bc="#000000",wc=class extends nu{Ea(){let t=this.Mr.localize(this.Da);Et(this.Na.subMenu.menuHeader.el(),t),this.Ar=h.createElement("span"),this.Ar.className="theo-settings-control-menu-item-title",Et(this.Ar,t);let i=h.createElement("span");return i.className="theo-primary-color theo-settings-control-menu-item-value",fi(this.Na.el(),"theo-subtitle-options-menu-item"),this.Na.el().appendChild(this.Ar),this.Na.el().appendChild(i),i}Fa(t){const i=this.wr(t);i&&this.$a(i)}Ba(){return this.dr}jr(t){this.Ra(t.kr)}$a(t){for(let t of this.yr.menuItems)t.selected(!1);t?(t.selected(!0),this.Oa(t.kr.label)):this.Oa("Custom")}Oa(t){this.Va=t,Et(this.La,this.Mr.localize(t)),this.Na.parentMenu.oe()}_r(t){let i=super._r(t);return fi(i.el(),"theo-subtitle-options-menu-item"),this.Cr(i),i}Cr(t){const i=this.Mr.localize(t.kr.label);Et(t.el(),i);const s=this.Mr.localize("Set "+this.Da+" to ")+i;t.el().setAttribute("aria-label",s)}Ve(){this.Mr.off("languagechange",this.se),super.Ve()}constructor(t,i,s,e){super(t.subMenu),this.Na=t,this.Mr=e,this.Va="",this.se=()=>{let t=this.Mr.localize(this.Da);Et(this.Na.subMenu.menuHeader.el(),t),Et(this.Ar,t),this.Oa(this.Va);for(const t of this.br)this.Cr(t)},this.Da=i,this.Ra=s.Go,this.La=this.Ea(),this.dr=s.Ua,this.Mr.on("languagechange",this.se)}},kc=class t{static Ha(t,i,s,e){if(void 0===t&&void 0===i)return;return Tt(void 0===t?s:t,void 0===i?e:i)}constructor(i){this.za=i,this.Wa=t=>{this.za.fontFamily=t.value},this.qa=t=>{this.za.fontSize=t.value},this.Ga=i=>{this.Xa=i.value,this.za.fontColor=t.Ha(this.Ja,this.Xa,yc,mc)},this.Qa=i=>{this.Ja=i.value,this.za.fontColor=t.Ha(this.Ja,this.Xa,yc,mc)},this.Ya=i=>{this.Ka=i.value,this.za.backgroundColor=t.Ha(this.Ka,this.Za,gc,mc)},this.tu=i=>{this.Za=i.value,this.za.backgroundColor=t.Ha(this.Ka,this.Za,gc,mc)},this.iu=i=>{this.su=i.value,this.za.windowColor=t.Ha(this.su,this.eu,bc,mc)},this.nu=i=>{this.eu=i.value,this.za.windowColor=t.Ha(this.su,this.eu,bc,mc)},this.ru=t=>{this.za.edgeStyle=t.value}}},_c=class{hu(t,i){const s=this.ou(t,i.Ba());s&&i.Fa(s)}ou(t,i){return Li(i,(i=>i.value===t))}au(t,i,s){let e,n;if(void 0===t)e=this.ou(void 0,i.Ba()),n=this.ou(void 0,s.Ba());else if(t){let r=function(t){let i=xt(t);i||(i=xt(t.slice(0,t.length-1).replace("rgb","rgba")+",1)"));i||(i=yt(wt(t),1));if(!i){let s=t.charAt(0).toUpperCase()+t.toLowerCase().slice(1);i=yt(wt(hc[s]),1)}return i}(t);if(r){let t=_t(r),h=100*r.uu;e=this.ou(t,i.Ba()),n=this.ou(h,s.Ba())}}e&&i.Fa(e),n&&s.Fa(n)}constructor(t,i){this.za=t,this.cu=i,this.lu=()=>{let t=this.za.fontFamily;this.hu(t,this.cu["Font family"]);let i=this.za.fontColor;this.au(i,this.cu["Font color"],this.cu["Font opacity"]);let s=this.za.fontSize;this.hu(s,this.cu["Font size"]);let e=this.za.backgroundColor;this.au(e,this.cu["Background color"],this.cu["Background opacity"]);let n=this.za.windowColor;this.au(n,this.cu["Window color"],this.cu["Window opacity"]);let r=this.za.edgeStyle;this.hu(r,this.cu["Character edge style"])},this.za.addEventListener("change",this.lu),this.lu()}};var jc,xc=class extends nu{fu(){return{"Font family":{Ua:Sc(vc),Go:this.du.Wa},"Font color":{Ua:Sc(dc),Go:this.du.Qa},"Font opacity":{Ua:Sc(lc),Go:this.du.Ga},"Font size":{Ua:Sc(cc),Go:this.du.qa},"Background color":{Ua:Sc(dc),Go:this.du.Ya},"Background opacity":{Ua:Sc(fc),Go:this.du.tu},"Window color":{Ua:Sc(dc),Go:this.du.iu},"Window opacity":{Ua:Sc(fc),Go:this.du.nu},"Character edge style":{Ua:Sc(pc),Go:this.du.ru}}}vu(){this.Ar=h.createElement("span"),this.Ar.className="theo-settings-control-menu-item-title",this.pu=h.createElement("span"),this.pu.className="theo-primary-color theo-settings-control-menu-item-value",this.Rr.el().appendChild(this.Ar),this.Rr.el().appendChild(this.pu),this.se()}_r(t){let i=this.yr.addSubMenuItem();return i.kr=t,this.cu[t]=new wc(i,t,this.mu[t],this.Mr),i}Cr(t){}jr(t){}Ve(){this.Mr.off("languagechange",this.se),this.gu.removeEventListener(["addtrack","removetrack"],this.yu),super.Ve()}constructor(t,i,s,e){super(t.subMenu),this.Rr=t,this.gu=i,this.Mr=e,this.cu={},this.yu=()=>{this.gu.some((t=>gt(t.kind)))?this.Rr.show():this.Rr.hide()},this.se=()=>{Et(this.yr.menuHeader.el(),this.Mr.localize("Subtitle Options")),Et(this.Ar,this.Mr.localize("Subtitle")),Et(this.pu,this.Mr.localize("Options")),this.Rr.el().setAttribute("aria-label",this.Mr.localize("Open the subtitle options menu"))},this.du=new kc(s),this.mu=this.fu(),this.dr=g.keys(this.mu),this.vu(),this.bu=new _c(s,this.cu),this.Mr.on("languagechange",this.se),this.gu.addEventListener(["addtrack","removetrack"],this.yu),this.yu()}};function Sc(t){let i=[{label:"Default",value:void 0}];for(let s of t)"Default"!==s.label&&i.push(s);return i}!function(t){qi.push(t)}((function(t){const i=t.ao.controlBar.getChild("SettingsButton").menu,s=i.addSubMenuItem({name:"TextTrackOptionsMenuItem"}),e=new xc(s,t.nt.ua,t.wu.ua,t.ao);t.ao.on("dispose",(()=>{i.removeMenuItem(s),s.dispose(),e.Ve(),i.dispose()}))})),function(t){t.GALLERY="gallery",t.OVERLAY="overlay",t.SPOTLIGHT="spotlight"}(jc||(jc={}));var Tc=.02,Cc=class{ku(t){const i=t-this.ju._u-20,s=t-this.ju._u+20;if(0===this.ju.co)return;const e=this.ju.t.currentProgramDateTime.valueOf();e>s?this.xu(this.Su):e<i?this.xu(this.Tu):this.xu(this.Cu)}Pu(t){const i=t-this.ju._u/1e3-Tc,s=t-this.ju._u/1e3+Tc;if(0===this.ju.co)return;const e=this.ju.t.currentTime;e>s?this.xu(this.Su):e<i?this.xu(this.Tu):this.xu(this.Cu)}Au(){this.Cu=this.Wo.Mu,this.Su=this.Wo.Mu-.05,this.Tu=this.Wo.Mu+.05}xu(t){const i=this.ju.t;if(i.playbackRate!==t&&0!==i.playbackRate){t>=.2&&t<=2.05?i.playbackRate=t:this.Wo.Iu(this.ju)}}Eu(){this.Wo.an(W.Du,this.Nu),this.Wo.an(W.Fu,this.$u)}constructor(t,i){this.Cu=1,this.Su=1.05,this.Tu=.95,this.Nu=()=>{this.Au()},this.$u=()=>{if(!this.Wo.Bu)return;const t=this.Wo.Bu._u,i=this.Wo.Ru,s=this.Wo.Ou;null!==s?this.ku(s.valueOf()+t):this.Pu(i+t/1e3)},this.ju=t,this.Wo=i,this.Wo.dn(W.Du,this.Nu),this.Wo.dn(W.Fu,this.$u)}},Pc=class{get t(){return this.Wo}get ua(){var t;return null!=(t=this.Vu)?t:this.Vu=function(t){return{get label(){return t.ph},get position(){return t.co},set position(i){t.co=i},get muted(){return t.Lu},set muted(i){t.Lu=i},get canResize(){return t.Uu},get x(){return t.Uh},set x(i){t.Uh=i},get y(){return t.Hh},set y(i){t.Hh=i},get width(){return t.Ti},set width(i){t.Ti=i},get height(){return t.Ci},set height(i){t.Ci=i},get enabled(){return t.Rt},set enabled(i){t.Rt=i},get offset(){return t._u},set offset(i){t._u=i},remove(){t.Hu()}}}(this)}get ph(){return this.zu}get co(){return this.qu.Wu.indexOf(this)}set co(t){this.qu.Gu(this,t)}get Lu(){return this.Wo.muted}set Lu(t){this.Rt&&(this.qu.Xu=this,this.Ju(t))}get Uu(){return 0!==this.co&&this.qu.Qu===jc.OVERLAY}get Uh(){return this.Yu}set Uh(t){this.Uu&&(this.Ku||(this.Ku=!0),this.Yu=t>1-this.Ti?1-this.Ti:w.max(t,0),this.t.element.style.setProperty("left",100*this.Yu+"%"))}get Hh(){return this.Zu}set Hh(t){this.Uu&&(this.Ku||(this.Ku=!0),this.Zu=t>1-this.Ci?1-this.Ci:w.max(t,0),this.t.element.style.setProperty("top",100*this.Zu+"%"))}get Ti(){return this.tc}set Ti(t){this.Uu&&this.ic(t)}get Ci(){return this.sc}set Ci(t){this.Uu&&this.ic(t)}get Rt(){return this.We}set Rt(t){t!==this.We&&0!==this.co&&(t?(D(this.qu.Iu(this)),this.qu.ec(this),this.t.element.style.setProperty("display","block")):(this.t.pause(),this.t.element.style.setProperty("display","none")),this.We=t,this.qu.nc(this))}get rc(){return this.Ku}set rc(t){this.Ku=t}get hc(){return this.oc}set hc(t){this.oc=t}get _u(){return this.ac}set _u(t){this.ac=t,this.uc(this.qu.Ru,this.qu.Ou)}cc(t,i,s,e,n){!this.Ku&&n&&(this.Ku=!0),this.Yu=t,this.Zu=i,this.tc=s,this.sc=e}Ju(t){this.Wo.muted=t}Hu(){0!==this.co&&this.qu.lc(this)}fc(){this.t.element.style.setProperty("top",100*this.Zu+"%"),this.t.element.style.setProperty("left",100*this.Yu+"%"),this.t.element.style.setProperty("width",100*this.tc+"%")}ic(t){const i=this.Yu+this.tc,s=w.min(t,i),e=.9-this.Zu,n=w.min(t,e),r=w.max(w.min(s,n),.1),h=this.tc-r;this.tc=r,this.sc=r,this.Uh+=h,this.t.element.style.setProperty("width",100*r+"%")}uc(t,i){if(null!==i){const t=i.valueOf()-this._u;this.Wo.currentProgramDateTime=new Date(t)}else this.Wo.currentTime=t-this._u/1e3}dc(t){const i=this.t.element.getElementsByClassName(Oc)[0],s=t?Lc:Vc;pi(i,t?Vc:Lc),fi(i,s)}Eu(){this.vc.Eu(),this.Wo.element.remove(),this.Wo.destroy()}constructor(t,i,s,e){this.We=!0,this.Ku=!1,this.oc=0,this.zu=t,this.Wo=i,this.qu=s,this.vc=new Cc(this,s),this.ac=null!=e?e:0,this.tc=.2,this.sc=.2,this.Yu=.76,this.Zu=0}};var Ac,Mc=class{get multiViewPlayer(){return this.qu}get abr(){}get analytics(){}get audioTracks(){return this.mc}get autoplay(){return this.qu.autoplay}set autoplay(t){this.qu.autoplay=t}get buffered(){return this.qu.buffered}get canvas(){}get clip(){return this.gc.ua}get currentProgramDateTime(){return null}get currentTime(){return this.qu.currentTime}set currentTime(t){this.qu.currentTime=t}get duration(){return this.qu.duration}get element(){return this.Hs}get ended(){return this.qu.ended}get error(){}get errorObject(){return this.qu.errorObject}get latency(){}get loop(){return!1}get metrics(){}get muted(){return this.qu.muted}set muted(t){this.qu.muted=t}get network(){}get paused(){return this.qu.paused}get playbackRate(){return this.qu.playbackRate}set playbackRate(t){this.qu.playbackRate=t}get played(){return this.qu.played}get poster(){return""}get preload(){return""}get presentation(){}get readyState(){return this.qu.readyState}get seekable(){return this.qu.seekable}get seeking(){return this.qu.seeking}get source(){}get src(){return"dummySource"}get textTrackStyle(){return this.yc}get textTracks(){return this.bc}get uid(){return 0}get videoHeight(){return 0}get videoTracks(){return this.mc}get videoWidth(){return 0}get volume(){return this.qu.volume}set volume(t){this.qu.volume=t}get views(){return this.qu.views}get visibility(){}get layout(){return this.qu.layout}set layout(t){this.qu.layout=t}play(){this.qu.play()}pause(){this.qu.pause()}stop(){this.qu.stop()}destroy(){this.qu.destroy()}prepareWithUserAction(){this.qu.prepareWithUserAction()}addEventListener(t,i){this.wc.dn(t,i)}removeEventListener(t,i){this.wc.an(t,i)}setSource(t){}constructor(t,i){this.wc=new F,this.qu=t,this.Hs=i,this.gc=new st,this.mc=(new Jt).ua,this.bc=(new Kt).ua,this.yc=(new at).ua,this.qu.addEventListener(["play","pause","seeking","seeked","timeupdate","ended","playing","waiting","sourcechange","readystatechange","loadedmetadata","loadeddata","canplay","canplaythrough","loadstart","progress","durationchange","volumechange","ratechange","error"],this.wc.Rs)}},Ic=class extends B{constructor(t){super(Ac.kc),this.view=t}},Ec=class extends B{constructor(t,i){super(Ac.VIEW_POSITION_CHANGE),this.oldPosition=t,this.newPosition=i}},Dc=class extends B{constructor(t){super(Ac._c),this.view=t}},Nc=class extends B{constructor(t){super(Ac.VIEW_CHANGE),this.view=t}},Fc=class extends B{constructor(t){super(Ac.jc),this.layout=t}},$c=class extends F{get Ru(){return this.Wo.Ru}get xc(){return this.Wo.xc}get lt(){return this.Wo.Sc}get Tc(){return this.Wo.Tc}get Cc(){return this.Wo.Cc}get Pc(){return this.Wo.Pc}get Ac(){return!1}get Mc(){return!1}Eu(){this.Fo()}constructor(t){super(),this.Ic=t=>{this.Rs(new zt(t.source))},this.Ec=t=>{this.Rs(new ci(t.currentTime))},this.Dc=t=>{this.Rs(new oi(t.currentTime))},this.Nc=t=>{this.Rs(new _i(t.currentTime))},this.Fc=t=>{this.Rs(new Si(t.currentTime))},this.$c=t=>{this.Rs(new G(t.currentTime,t.currentProgramDateTime))},this.Bc=t=>{this.Rs(new bi(t.currentTime))},this.Rc=t=>{this.Rs(new Bt(t.currentTime))},this.Oc=t=>{this.Rs(new Pt(t.currentTime))},this.Vc=t=>{this.Rs(new kt(t.currentTime,t.readyState))},this.Lc=t=>{this.Rs(new St(t.currentTime,this.Cc))},this.Uc=t=>{this.Rs(new S(t.currentTime,this.Cc))},this.Hc=t=>{this.Rs(new It(t.currentTime,this.Cc))},this.zc=t=>{this.Rs(new Nt(t.currentTime,this.Cc))},this.Wc=()=>{this.Rs(new ft)},this.qc=t=>{this.Rs(new ct(t.currentTime))},this.Gc=t=>{this.Rs(new di(t.duration))},this.Xc=t=>{this.Rs(new Pi(this.Ru,t.volume))},this.Jc=t=>{this.Rs(new mi(this.Ru,t.playbackRate))},this.Qc=t=>{this.Rs(new ji(t.errorObject))},this.Yc=()=>{this.Rs(new Q)},this.Wo=t,this.Wo.dn("sourcechange",this.Ic),this.Wo.dn("play",this.Ec),this.Wo.dn("pause",this.Dc),this.Wo.dn("seeking",this.Nc),this.Wo.dn("seeked",this.Fc),this.Wo.dn("timeupdate",this.$c),this.Wo.dn("ended",this.Bc),this.Wo.dn("playing",this.Rc),this.Wo.dn("waiting",this.Oc),this.Wo.dn("readystatechange",this.Vc),this.Wo.dn("loadedmetadata",this.Lc),this.Wo.dn("loadeddata",this.Uc),this.Wo.dn("canplay",this.Hc),this.Wo.dn("canplaythrough",this.zc),this.Wo.dn("loadstart",this.Wc),this.Wo.dn("progress",this.qc),this.Wo.dn("durationchange",this.Gc),this.Wo.dn("volumechange",this.Xc),this.Wo.dn("ratechange",this.Jc),this.Wo.dn("error",this.Qc),this.Wo.dn("fullscreenchange",this.Yc)}},Bc=class{async Kc(){const t=this.Wo;if(!t.Zc||!t.Tc)return;const i=this.tl.mutedAutoplay;switch(await this.sl.il(t.Lu)){case"all":t.Lu||t.nl(),t.rl();break;case"muted":(t.Lu||i===Ii.ALL)&&(t.Lu=!0,t.rl())}}fn(){this.sl.fn(),this.un.fn()}constructor(t,i,s){this.Wo=t,this.tl=s,this.yc=new at,this.un=new X(i);const e=new ti(this.un,this.yc,1,[et.hl]);this.sl=new ei(e)}},Rc=[bt.ol,bt.al,bt.cl,bt.ll],Oc="theo-switch-audio-button",Vc="vjs-icon-volume-mute",Lc="vjs-icon-volume-high",Uc="theo-main-view",Hc="theo-layout-";!function(t){t.kc="addview",t._c="removeview",t.VIEW_CHANGE="viewchange",t.VIEW_POSITION_CHANGE="viewpositionchange",t.jc="layoutchange"}(Ac||(Ac={}));var zc=class extends F{get ua(){var t;return null!=(t=this.Vu)?t:this.Vu=function(t){return{load:(i,s,e,n)=>t.En(i,s,e,n),get views(){return t.Wu.map((t=>t.ua))},get mainVideoView(){var i;return null==(i=t.Bu)?void 0:i.ua},get mainAudioView(){var i;return null==(i=t.Xu)?void 0:i.ua},get layout(){return t.Qu},set layout(i){t.Qu=i},get buffered(){return t.fl},get currentTime(){return t.Ru},set currentTime(i){t.Ru=i},get autoplay(){return t.Zc},set autoplay(i){t.Zc=i},get duration(){return t.ct},get ended(){return t.xc},get errorObject(){return t.Sc},get muted(){return t.Lu},set muted(i){t.Lu=i},get paused(){return t.Tc},get playbackRate(){return t.Mu},set playbackRate(i){t.Mu=i},get played(){return t.dl},get readyState(){return t.Cc},get seekable(){return t.vl},get seeking(){return t.Pc},get volume(){return t.pl},set volume(i){t.pl=i},play(){t.rl()},pause(){t.ml()},stop(){t.gl()},destroy(){t.Eu(),t=null},requestFullscreen(i){t.yl(i)},exitFullscreen(){t.bl()},prepareWithUserAction(){t.nl()},addEventListener(i,s){t.dn(i,s)},removeEventListener(i,s){t.an(i,s)}}}(this)}get ao(){return this.wl}get Wu(){return this.kl}get Bu(){return this._l}get Xu(){var t;return null!=(t=this.jl)?t:this._l}set Xu(t){if(this.jl===t)return;const i=this.Xu,s=null!=t?t:this.Bu;i.t.removeEventListener(W.xl,this.Sl),i.dc(!1),i.Lu||(i.Ju(!0),s.Ju(!1)),s.t.addEventListener(W.xl,this.Sl),s.dc(!0),this.jl=t}get Qu(){return this.Tl}set Qu(t){if(t!==this.Tl){if(this.Qu===jc.OVERLAY)for(const t of this.Wu)t.t.element.style.setProperty("left","auto"),t.t.element.style.setProperty("top","auto"),t.t.element.style.removeProperty("z-index");pi(this.Hs,Hc+this.Tl),this.Tl=t,fi(this.Hs,Hc+this.Tl),this.fc(),this.bo(new Fc(t))}}get fl(){if(0===this.Wu.length)return $i.Cl().ws();return this.Pl().reduce(((t,i)=>t.wn($i.yn(i.t.buffered))),new $i([0,1/0])).ws()}get Ru(){return this._l&&this.Al?this._l.t.currentTime+this._l._u/1e3:0}set Ru(t){this.Ml();const i=this.Pl();let s=null;if(null!==this.Ou){s=this.Ou;const i=t-this.Ru;s.setSeconds(s.getSeconds()+i)}for(const e of i)e.uc(t,s)}get Ou(){if(!this._l)return null;return this.Wu.every((t=>null!==t.t.currentProgramDateTime))?new Date(this._l.t.currentProgramDateTime.valueOf()+this._l._u):null}get Zc(){return this.Il}set Zc(t){this.Il=t,this.El.Kc()}get ct(){if(0===this.Wu.length)return NaN;let t=1/0;for(const i of this.Pl())t=w.min(i.t.duration,t);return t}get xc(){return this.Wu.some((t=>t.t.ended))}get lt(){return this.Sc}get Sc(){if(this.Dl)return this.Dl;for(const t of this.Wu){const i=t.t.errorObject;if(void 0!==i)return i}}get Lu(){var t,i;return null!=(i=null==(t=this.Xu)?void 0:t.Lu)&&i}set Lu(t){this.Xu&&this.Xu.Ju(t),this.Sl()}get Tc(){if(!this.Wu.length)return!0;return this.Pl().some((t=>t.t.paused))}get Mu(){var t,i,s;return null!=(s=null!=(i=this.Nl)?i:null==(t=this._l)?void 0:t.t.playbackRate)?s:1}set Mu(t){if(void 0!==this.Nl)this.Nl=t;else for(const i of this.Wu)i.t.playbackRate=t;this.Fl()}get dl(){return this.Wu.reduce(((t,i)=>t.$l($i.yn(i.t.played))),$i.Cl()).ws()}get Cc(){if(0===this.Wu.length)return jt.Bl;let t=jt.Rl;for(const i of this.Pl())i.t.readyState<t&&(t=i.t.readyState);return t}get vl(){if(0===this.Wu.length)return $i.Cl().ws();return this.Pl().reduce(((t,i)=>t.wn($i.yn(i.t.seekable))),new $i([0,1/0])).ws()}get Pc(){return this.Wu.some((t=>t.t.seeking))}get pl(){var t,i;return null!=(i=null==(t=this.Xu)?void 0:t.t.volume)?i:1}set pl(t){for(const i of this.Wu)i.t.volume=t;this.Sl()}En(t,i,s,e){if(this.Ol)throw this.Dl;const n=this.Wu.filter((i=>i.ph===t))[0];return n?n.ua:this.Vl(t,i,s,e)}rl(){if(!this._l||!this.Tc)return;this.Ml();const t=this.Pl();for(const i of t)i.t.play()}ml(){const t=this.Pl();for(const i of t)i.t.pause()}gl(){for(let t=this.Wu.length-1;t>=0;t--)this.lc(this.Wu[t]);this._l=void 0,this.jl=void 0,this.Dl=void 0,this.Ll&&(this.Ll.Ul(),this.Ll=void 0),this.Hl=!0,this.zl=!1,this.Wl=!1,this.ql=-1,this.Gl=jt.Bl,this.Xl=!1,this.Nl=void 0,this.Jl=!1,this.Ql=-1,this.Yl=!1,this.Kl=-1,this.Al=!1,this.Zl.Xn(),this.bo(new zt(void 0))}Eu(){for(let t=this.Wu.length-1;t>=0;t--)this.lc(this.Wu[t]);this.Fo(),this.Zl.fn(),this.tf.Eu(),this.if.Eu(),this.El.fn(),this.ao.dispose()}yl(t){this.bo(new Q),this.Hs.requestFullscreen(t).catch(Wt)}bl(){this.bo(new Q),h.exitFullscreen().catch(Wt)}nl(){for(const t of this.Wu)t.t.prepareWithUserAction()}Vl(t,i,s,e){const n=h.createElement("div");fi(n,"theo-view"),this.Hs.appendChild(n);const r=new(Gt())(n,this.tl).ua;r.source=i;const o=new Pc(t,r,this,e);if(s){const t=h.createElement("div");t.className="theo-view-description";const i=h.createElement("span");i.textContent=s,t.appendChild(i),n.appendChild(t),o.t.addEventListener("dimensionchange",(()=>{this.sf(t)}))}return this.ef(o),this.Wu.push(o),1===this.Wu.length?(this._l=o,this.nf(this._l),fi(this._l.t.element,Uc)):(this.rf(r),0!==this.Ru&&D(this.Iu(o,!0))),this.fc(),this.bo(new Ic(o.ua)),o.ua}Pl(){return this.Wu.filter((t=>t.Rt))}hf(){return this.Wu.filter((t=>t.Rt&&t!==this._l))}rf(t){t.volume=this._l.t.volume,t.muted=!0,t.playbackRate=this._l.t.playbackRate}ef(t){t.hc=this.Wu.length;const i=t.t.element;i.addEventListener("dblclick",(()=>{this.af(t)})),i.addEventListener("touchend",(i=>{this.uf>=i.timeStamp?(i.preventDefault(),this.af(t),this.uf=0):this.uf=i.timeStamp+500}));const s=h.createElement("div"),e=0===this.Wu.length?Lc:Vc;s.className="theo-primary-color "+Oc+" "+e,s.addEventListener("click",(()=>{this.Xu=t})),s.addEventListener("touchend",(()=>{this.Xu=t})),i.appendChild(s);const n=h.createElement("div");n.className="theo-primary-color theo-disable-button vjs-icon-close",n.addEventListener("click",(()=>{t.Rt=!1})),n.addEventListener("touchend",(()=>{t.Rt=!1})),i.appendChild(n),this.cf(t,i),this.lf(t),this.ff(t)}cf(t,i){const s=h.createElement("div");let e=0;const n=i=>{if(this.df=!0,this.ec(t),i.preventDefault(),"touchstart"===i.type){e=i.changedTouches[0].clientX,h.addEventListener("touchmove",r),h.addEventListener("touchend",o),h.addEventListener("touchcancel",o)}else{e=i.x,h.addEventListener("mousemove",r),h.addEventListener("mouseup",o)}},r=i=>{let s;if("touchmove"===i.type){s=i.changedTouches[0].clientX}else{s=i.x}const n=e-s,r=t.t.element.parentElement.clientWidth,h=(t.t.element.clientWidth+n)/r;t.Ti=h,t.Ci=h,e=s},o=t=>{this.df=!1,"mouseup"===t.type?(h.removeEventListener("mousemove",r),h.removeEventListener("mouseup",o)):(h.removeEventListener("touchmove",r),h.removeEventListener("touchend",o),h.removeEventListener("touchcancel",o))};s.addEventListener("mousedown",n),s.addEventListener("touchstart",n),s.className="theo-resize-button theo-primary-color vjs-icon-resize-handle-sw",i.appendChild(s)}sf(t){const i=t.parentElement.clientWidth/100,s=w.min(40,5.23*i);t.style.fontSize=s+"px"}lf(t){const i=t.t.element,s=i.parentElement;let e={x:0,y:0};const n=i=>{if(!this.df&&t.Uu)if(this.ec(t),i.preventDefault(),"touchstart"===i.type){const t=i;e.x=t.changedTouches[0].clientX,e.y=t.changedTouches[0].clientY,h.addEventListener("touchmove",r),h.addEventListener("touchend",o),h.addEventListener("touchcancel",o)}else{const t=i;e.x=t.x,e.y=t.y,h.addEventListener("mousemove",r),h.addEventListener("mouseup",o)}},r=n=>{let r;if("touchmove"===n.type){const t=n;r={x:t.changedTouches[0].clientX,y:t.changedTouches[0].clientY}}else{const t=n;r={x:t.x,y:t.y}}const h=r.x-e.x,o=r.y-e.y,a=i.offsetLeft,u=s.clientWidth;t.Uh=(a+h)/u;const c=s.offsetHeight,l=i.offsetTop;t.Hh=(l+o)/c,e=r},o=t=>{"mouseup"===t.type?(h.removeEventListener("mouseup",o),h.removeEventListener("mousemove",r)):(h.removeEventListener("touchmove",r),h.removeEventListener("touchend",o),h.removeEventListener("touchcancel",o))};i.addEventListener("mousedown",n),i.addEventListener("touchstart",n)}ec(t){for(const i of this.Wu)i.hc>t.hc&&(i.hc-=1,i.t.element.style.setProperty("z-index",""+i.hc));t.hc=this.Wu.length,t.t.element.style.setProperty("z-index",""+t.hc)}Ml(){if(void 0!==this.Nl)return;this.Nl=this.Mu;const t=this.Pl();for(const i of t)i.t.playbackRate=0}vf(){if(void 0===this.Nl)return;if(this.Pc||this.Cc<jt.pf){if(this._l&&!this.Al){this.Al=!0;for(const t of this.hf())this._l._u!==t._u&&t.uc(this.Ru,this.Ou)}return}const t=this.Pl();for(const i of t)i.t.playbackRate=this.Nl;this.Nl=void 0,this.Al=!0}nc(t){t.Rt||t!==this.jl||(this.Xu=void 0),this.bo(new Nc(t.ua)),this.fc()}async Iu(t,i){void 0===i&&(i=!1),this.Ml();const s=t.t;i&&(this.Ll=new O,s.addEventListener(W.ho,this.Ps),await this.Ll.mf,s.removeEventListener(W.ho,this.Ps)),s.readyState===jt.Bl&&(this.Jl=!0,s.play()),this.Tc?s.pause():s.play(),t.uc(this.Ru,this.Ou)}fc(){const t=this.Pl();if(!t.length)return;let i=0;switch(this.Qu){case jc.SPOTLIGHT:{t.length>1?this.Hs.style.gridTemplateColumns="80% 20%":this.Hs.style.gridTemplateColumns="100%";let s=1/0;for(const e of t)if(i>=s+1)e.Rt=!1;else if(e.t.element.style.setProperty("width","100%"),i++,2===i){const i=e.t.element.clientHeight,n=e.t.element.parentElement.clientHeight,r=w.floor(n/i);s=w.min(t.length-1,r),this.Hs.style.gridTemplateRows="repeat("+s+", 1fr)"}break}case jc.OVERLAY:{let s=0;for(i=1;i<t.length;i++){const e=t[i];if(i>=5)e.Rt=!1;else{if(!e.rc){const t=.04+.24*s;e.cc(e.Uh,t,e.Ti,e.Ci,!1),this.ec(e),s++}e.t.element.style.setProperty("z-index",""+e.hc),e.fc()}}break}case jc.GALLERY:{const s=t.length,e=w.ceil(w.sqrt(s));for(const s of t)i>=9?s.Rt=!1:(s.t.element.style.setProperty("width",100/e+"%"),i++);break}}}Gu(t,i){const s=i>=0?w.min(w.floor(i),this.Wu.length-1):0,e=t.co,n=w.min(e,s),r=w.max(e,s),h=0===n;if(!(!this.Wu[n].Rt||!this.Wu[r].Rt)||!h){if(this.Qu===jc.OVERLAY){const t=this.Wu[r],i=this.Wu[n],s=t.Uh,e=t.Hh,h=t.Ti,o=t.Ci,a=i.rc||t.rc;t.cc(i.Uh,i.Hh,i.Ti,i.Ci,a),[this.Wu[n],this.Wu[r]]=[this.Wu[r],this.Wu[n]],i.cc(s,e,h,o,a)}else[this.Wu[n],this.Wu[r]]=[this.Wu[r],this.Wu[n]];h&&this.gf(this.Wu[0]),this.bo(new Ec(e,s))}}lc(t){t===this.jl&&(this.Xu=void 0),t.Eu(),Hi(this.Wu,t),this.fc(),this.bo(new Dc(t.ua))}af(t){this.xc||0===this.dl.length||this._l===t||this.Tl===jc.GALLERY||this.Gu(t,0)}gf(t,i){void 0===i&&(i=!1);let s=!1;const e=this._l;this._l=t,t.rc=!1,this.yf(e),pi(e.t.element,Uc),this.jl||(s=e.Lu,e.Ju(!0),e.dc(!1),t.dc(!0),i&&!s?this.bo(new Pi(this.Ru,0)):t.Ju(s)),this.ec(e),fi(this._l.t.element,Uc),this.nf(this._l),this.Qu===jc.OVERLAY&&this.fc()}ff(t){t.t.addEventListener(W.bf,this.wf),t.t.addEventListener(W.kf,this.jh),t.t.addEventListener(W.kh,this._f),t.t.addEventListener(W.wh,this.jf),t.t.addEventListener(W.xf,this.Xe),t.t.addEventListener(W.Sf,this.Tf),t.t.addEventListener(W.Cf,this.Pf),t.t.addEventListener(bt.Af,this.Mf),t.t.addEventListener(lt.ia,this.Cs)}nf(t){t.t.addEventListener(W.If,this.Rs),t.t.addEventListener(W.Du,this.Fl),t.t.addEventListener(W.Fu,this.Ef),this.jl||t.t.addEventListener(W.xl,this.Sl)}yf(t){t.t.removeEventListener(W.If,this.Rs),t.t.removeEventListener(W.Du,this.Fl),t.t.removeEventListener(W.Fu,this.Ef),this.jl||t.t.removeEventListener(W.xl,this.Sl)}constructor(t,i){super(),this.kl=[],this.Tl=jc.GALLERY,this.df=!1,this.Ol=!1,this.Hl=!0,this.zl=!1,this.Wl=!1,this.ql=-1,this.Gl=jt.Bl,this.Xl=!1,this.uf=0,this.Nl=void 0,this.Jl=!1,this.Il=!1,this.Ql=-1,this.Yl=!1,this.Kl=-1,this.Al=!1,this.Df=t=>{this.vf(),I((()=>this.Rs(t)))},this.Nf=t=>{this.Ml(),this.Rs(t)},this.Ps=()=>{var t;null==(t=this.Ll)||t.Ff(),this.Ll=void 0},this.Fl=()=>{const t=this.Mu;this.Kl!==t&&(this.Kl=t,this.Rs(new mi(this.Ru,t)))},this.Sl=()=>{const t=this.pl,i=this.Lu;this.Ql===t&&this.Yl===i||(this.Ql=t,this.Yl=i,this.Rs(new Pi(this.Ru,t)))},this.Ef=t=>{(this.Cc>jt.$f||this.Pc)&&this.Rs(t)},this.wf=t=>{this.vf(),this.Pc||(this.zl=!1,this.Rs(t))},this.Pf=t=>{const i=this.ct;this.ql!==i&&(this.ql=i,this.Rs(t))},this.Cs=t=>{this.Rs(t)},this._f=t=>{if(this.Hl){if(this.Jl)return void(this.Jl=!1);this.Hl=!1,this.Wl=!1,this.Rs(t)}},this.Xe=t=>{this.zl||(this.zl=!0,this.Rs(t))},this.jf=t=>{!this.Hl&&this.Tc&&(this.Hl=!0,this.Rs(t))},this.jh=t=>{this.Wl||(this.Wl=!0,this.Rs(t))},this.Tf=t=>{this.Xl||(this.Xl=!0,this.Rs(t))},this.Mf=t=>{const i=this.Cc;this.Gl!==i&&(this.Gl=i,this.Rs(t))},this.Bf=async()=>{try{await this.Of.Rf([N.MULTIVIEW])}catch(t){this.Dl=t,this.gl(),this.Ol=!0,this.bo(new Ht(t))}},this.Hs=t,this.tl=i;const s=Ct.Vf,e=new ht,n=new V("6.8.0",s,e),r=new R(i.isEmbeddable,"6.8.0",$());if(this.Of=new nt(s,r,n,e,i,$()),this.Of.Lf().then(this.Bf),this.Uf=new Mc(this.ua,t),this.wl=Ru(this.Uf,this.Hs,i.ui),fi(this.Hs,Hc+this.Tl),Ct.Zs.Ks){const t=this.wl.el();fi(t,"theo-mobile"),Ou(t)}this.if=new $c(this),this.tf=new vt(this.if),this.tf.dn(bt.Hf,this.Df),this.Zl=new Vt(this,!0),this.Zl.dn(Rc,this.Rs),this.Zl.dn(bt.zf,this.Nf),this.El=new Bc(this,t,i)}};function Wc(t,i){var s;const e=Xu(Di({},i||{},{allowNativeFullscreen:!1,ui:Di({},(null==i?void 0:i.ui)||{},{userActions:Di({},(null==i||null==(s=i.ui)?void 0:s.userActions)||{},{click:!1})}),abr:Di({},(null==i?void 0:i.abr)||{},{restrictToPlayerSize:!0})}));let n=new zc(t,e).ua;return g.defineProperty(n,"constructor",{value:Wc}),n=J(n),n}var qc="vjs-selected",Gc=class extends nu{Cr(t){const i=t.kr,s=this.Mr.localize(i.label);Et(t.ph,s),t.el().setAttribute("aria-label",this.Mr.localize("Enable/disable")+" "+s),t.el().setAttribute("role","menuitemcheckbox"),t.selected(i.enabled)}_r(t){const i=super._r(t);fi(i.el(),"theo-multi-view-menu-item"),2===this.br.length&&fi(i.el(),"theo-multi-view-menu-item-position-zero");const s=h.createElement("span");i.ph=s;const e=h.createElement("div");e.className="theo-multi-view-menu-item-toggle",i.mh=e;const n=t=>this.gh(t,i);i.yh=n,e.addEventListener("click",n);const r=h.createElement("div");return r.className="theo-multi-view-menu-item-toggle-slider",e.appendChild(r),i.el().appendChild(s),i.el().appendChild(e),this.Wf.before(i.el()),i}qf(){const t=this.yr.addMenuItem().el();fi(t,"theo-multi-view-menu-item"),fi(t,"theo-multi-view-menu-layout-select");const i=h.createElement("button");i.className="vjs-icon-view-grid",i.addEventListener("click",(()=>{this.Ls.layout=jc.GALLERY})),t.appendChild(i),this.Gf=i;const s=h.createElement("button");s.className="vjs-icon-view-spotlight",s.addEventListener("click",(()=>{this.Ls.layout=jc.SPOTLIGHT})),t.appendChild(s),this.Xf=s;const e=h.createElement("button");return e.className="vjs-icon-multi-view",e.addEventListener("click",(()=>{this.Ls.layout=jc.OVERLAY})),t.appendChild(e),this.Jf=e,t}gh(t,i){t.stopImmediatePropagation(),this.jr(i)}jr(t){const i=t.kr;for(const t of this.Ls.views)t===i&&(t.enabled=!t.enabled);this.Cr(t)}Sr(t){t.mh.removeEventListener("click",t.yh),super.Sr(t)}constructor(t,i,s){super(t),this.Qf=t=>{this.gr(t.view)},this.Yf=t=>{this.mr(t.view)},this.Kf=t=>{const i=t.oldPosition,s=t.newPosition,e=w.max(i,s),n=w.min(i,s),r=h.getElementsByClassName("theo-multi-view-menu-item");r[e].before(r[n]),r[n].before(r[e]),0===n&&(pi(r[e],"theo-multi-view-menu-item-position-zero"),fi(r[n],"theo-multi-view-menu-item-position-zero"))},this.Zf=()=>{const t=this.Ls.layout;yi(this.Gf,qc,t===jc.GALLERY),yi(this.Xf,qc,t===jc.SPOTLIGHT),yi(this.Jf,qc,t===jc.OVERLAY)},i.views&&(this.Ls=i,this.Mr=s,this.Ls.multiViewPlayer.addEventListener(Ac.kc,this.Qf),this.Ls.multiViewPlayer.addEventListener(Ac._c,this.Yf),this.Ls.multiViewPlayer.addEventListener(Ac.VIEW_CHANGE,this.Qf),this.Ls.multiViewPlayer.addEventListener(Ac.VIEW_POSITION_CHANGE,this.Kf),this.Ls.multiViewPlayer.addEventListener(Ac.jc,this.Zf),Et(this.yr.menuHeader.el(),this.Mr.localize("MultiView")),this.Wf=this.qf(),this.Zf())}};Lo.registerComponent("multiViewButton",class extends Sa{buildCSSClass(){return"vjs-icon-view-grid "+super.buildCSSClass()}dispose(){this.dh.Ve(),super.dispose()}constructor(t,i){super(t,i),this.minimumMenuItems=3,this.dh=new Gc(this.menu,this.Ss,t),this.controlText(t.localize("Views")),this.$e.Fe=this.controlText()}});export{Qt as ChromelessPlayer,H as ErrorCategory,L as ErrorCode,Wc as MultiViewPlayer,Qu as Player,Ei as cache,Ai as cast,si as features,ai as playerSuiteVersion,li as players,vi as registerContentProtectionIntegration,Zt as utils,ri as version,Lo as videojs};
|
|
40
|
+
var s="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:void 0!==a?a:"undefined"!=typeof global?global:this,a=s.window,h=s.document,u=(s.location,s.navigator,s.setTimeout),c=s.clearTimeout,v=(s.setInterval,s.clearInterval,s.Error),p=s.TypeError,m=s.SyntaxError,g=s.Object,w=s.Math,k=s.parseInt,_=s.parseFloat,j=s.isNaN,x=s.Uint8Array;s.Worker,s.WorkerGlobalScope,s.XMLHttpRequest;import{$ as S,$a as T,A as C,Aa as P,B as A,Ba as M,C as I,Ca as E,D,Da as N,E as F,Ea as $,F as B,Fa as R,G as O,Ga as V,H as L,Ha as U,I as H,Ia as z,J as W,Ja as q,K as G,Ka as X,L as J,La as Q,M as Y,Ma as K,N as Z,Na as tt,O as it,Oa as st,P as et,Pa as nt,Q as rt,Qa as ht,R as ot,Ra as at,S as ut,Sa as ct,T as lt,Ta as ft,U as dt,Ua as vt,V as pt,Va as mt,W as gt,Wa as yt,X as bt,Xa as wt,Y as kt,Ya as _t,Z as jt,Za as xt,_ as St,_a as Tt,a as Ct,aa as Pt,ab as At,b as Mt,ba as It,bb as Et,c as Dt,ca as Nt,cb as Ft,d as $t,da as Bt,db as Rt,e as Ot,ea as Vt,eb as Lt,f as Ut,fa as Ht,fb as zt,g as Wt,ga as qt,gb as Gt,h as Xt,ha as Jt,hb as Qt,i as Yt,ia as Kt,ib as Zt,j as ti,ja as ii,jb as si,k as ei,ka as ni,kb as ri,l as hi,la as oi,lb as ai,m as ui,ma as ci,mb as li,n as fi,na as di,nb as vi,o as pi,oa as mi,ob as gi,p as yi,pa as bi,pb as wi,q as ki,qa as _i,qb as ji,r as xi,ra as Si,rb as Ti,s as Ci,sa as Pi,sb as Ai,t as Mi,ta as Ii,tb as Ei,u as Di,ua as Ni,ub as Fi,v as $i,va as Bi,w as Ri,wa as Oi,x as Vi,xa as Li,y as Ui,ya as Hi,z as zi,za as Wi}from"./THEOplayer.common.esm.js";var qi=[];var Gi=[];var o=void 0!==a?a:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},Xi=void 0!==h?h:{createElement:function(){}};function Ji(t,i){return i||(i=t.slice(0)),t.raw=i,t}var Qi=1;function Yi(){return Qi++}var Ki,Zi=g.prototype.toString,ts=function(t){return es(t)?g.keys(t):[]};function is(t,i){ts(t).forEach((function(s){return i(t[s],s)}))}function ss(t){for(var i=arguments.length,s=new Array(i>1?i-1:0),e=1;e<i;e++)s[e-1]=arguments[e];return g.assign?g.assign.apply(g,[t].concat(s)):(s.forEach((function(i){i&&is(i,(function(i,s){t[s]=i}))})),t)}function es(t){return!!t&&"object"==typeof t}function ns(t){return es(t)&&"[object Object]"===Zi.call(t)&&t.constructor===g}var rs=function(t,i,s){void 0===s&&(s=!!ne&&ne<11),"log"!==t&&i.unshift(t.toUpperCase()+":"),Ki.history.push(i),i.unshift("VIDEOJS:");var e=o.console&&o.console[t];e&&(s&&(i=i.map((function(t){if(es(t)||Array.isArray(t))try{return JSON.stringify(t)}catch(i){return String(t)}return String(t)})).join(" ")),e.apply?e[Array.isArray(i)?"apply":"call"](o.console,i):e(i))};(Ki=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];rs("log",i)}).history=[],Ki.error=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return rs("error",i)},Ki.warn=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return rs("warn",i)};var hs=Ki,os="undefined"!=typeof globalThis?globalThis:void 0!==a?a:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function as(t){return t.replace(/\n\r?\s*/g,"")}var us,cs=function(t){for(var i="",s=0;s<arguments.length;s++)i+=as(t[s])+(arguments[s+1]||"");return i};function ls(t){return"string"==typeof t&&/\S/.test(t)}function fs(t){if(/\s/.test(t))throw new v("class has illegal whitespace characters")}function ds(){return Xi===o.document&&void 0!==Xi.createElement}function vs(t){return es(t)&&1===t.nodeType}function ps(t){return function(i,s){if(!ls(i))return Xi[t](null);ls(s)&&(s=Xi.querySelector(s));var e=vs(s)?s:Xi;return e[t]&&e[t](i)}}function ms(t,i,s,e){void 0===t&&(t="div"),void 0===i&&(i={}),void 0===s&&(s={});var n=Xi.createElement(t);return g.getOwnPropertyNames(i).forEach((function(t){var s=i[t];-1!==t.indexOf("aria-")||"role"===t||"type"===t?(hs.warn(cs(us||(us=Ji(["Setting attributes in the second argument of createEl()\n has been deprecated. Use the third argument instead.\n createEl(type, properties, attributes). Attempting to set "," to ","."])),t,s)),n.setAttribute(t,s)):"textContent"===t?gs(n,s):n[t]=s})),g.getOwnPropertyNames(s).forEach((function(t){n.setAttribute(t,s[t])})),e&&$s(n,e),n}function gs(t,i){return void 0===t.textContent?t.innerText=i:t.textContent=i,t}function ys(t,i){i.firstChild?i.insertBefore(t,i.firstChild):i.appendChild(t)}var bs={},ws="vdata"+(new Date).getTime();function ks(t){var i=t[ws];return i||(i=t[ws]=Yi()),bs[i]||(bs[i]={}),bs[i]}function _s(t){var i=t[ws];return!!i&&!!g.getOwnPropertyNames(bs[i]).length}function js(t){var i=t[ws];if(i){delete bs[i];try{delete t[ws]}catch(i){t.removeAttribute?t.removeAttribute(ws):t[ws]=null}}}function xs(t,i){return fs(i),t.classList?t.classList.contains(i):function(t){return new RegExp("(^|\\s)"+t+"($|\\s)")}(i).test(t.className)}function Ss(t,i){return t.classList?t.classList.add(i):xs(t,i)||(t.className=(t.className+" "+i).trim()),t}function Ts(t,i){return t.classList?t.classList.remove(i):(fs(i),t.className=t.className.split(/\s+/).filter((function(t){return t!==i})).join(" ")),t}function Cs(t,i,s){var e=xs(t,i);if("function"==typeof s&&(s=s(t,i)),"boolean"!=typeof s&&(s=!e),s!==e)return s?Ss(t,i):Ts(t,i),t}function Ps(t,i){g.getOwnPropertyNames(i).forEach((function(s){var e=i[s];null==e||!1===e?t.removeAttribute(s):t.setAttribute(s,!0===e?"":e)}))}function As(t){var i={};if(t&&t.attributes&&t.attributes.length>0)for(var s=t.attributes,e=s.length-1;e>=0;e--){var n=s[e].name,r=s[e].value;"boolean"!=typeof t[n]&&-1===",autoplay,controls,playsinline,loop,muted,default,defaultMuted,".indexOf(","+n+",")||(r=null!==r),i[n]=r}return i}function Ms(t,i,s){t.setAttribute(i,s)}function Is(t,i){t.removeAttribute(i)}function Es(t){var i;if(t.getBoundingClientRect&&t.parentNode&&(i=t.getBoundingClientRect()),!i)return{left:0,top:0};var s=Xi.documentElement,e=Xi.body,n=s.clientLeft||e.clientLeft||0,r=o.pageXOffset||e.scrollLeft,h=i.left+r-n,a=s.clientTop||e.clientTop||0,u=o.pageYOffset||e.scrollTop,c=i.top+u-a;return{left:w.round(h),top:w.round(c)}}function Ds(t,i){var s={},e=Es(t),n=t.offsetWidth,r=t.offsetHeight,h=e.top,o=e.left,a=i.pageY,u=i.pageX;return i.changedTouches&&(u=i.changedTouches[0].pageX,a=i.changedTouches[0].pageY),s.y=w.max(0,w.min(1,(h-a+r)/r)),s.x=w.max(0,w.min(1,(u-o)/n)),s}function Ns(t){return es(t)&&3===t.nodeType}function Fs(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function $s(t,i){return function(t){return"function"==typeof t&&(t=t()),(Array.isArray(t)?t:[t]).map((function(t){return"function"==typeof t&&(t=t()),vs(t)||Ns(t)?t:"string"==typeof t&&/\S/.test(t)?Xi.createTextNode(t):void 0})).filter((function(t){return t}))}(i).forEach((function(i){return t.appendChild(i)})),t}function Bs(t,i){return $s(Fs(t),i)}var Rs,Os=ps("querySelector"),Vs=ps("querySelectorAll"),Ls=o.navigator&&o.navigator.userAgent||"",Us=/AppleWebKit\/([\d.]+)/i.exec(Ls),Hs=Us?_(Us.pop()):null,zs=/iPad/i.test(Ls),Ws=/iPhone/i.test(Ls)&&!zs,qs=/iPod/i.test(Ls),Gs=Ws||zs||qs,Xs=(Rs=Ls.match(/OS (\d+)_/i))&&Rs[1]?Rs[1]:null,Js=/Android/i.test(Ls),Qs=function(){var t=Ls.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!t)return null;var i=t[1]&&_(t[1]),s=t[2]&&_(t[2]);return i&&s?_(t[1]+"."+t[2]):i||null}(),Ys=Js&&/webkit/i.test(Ls)&&Qs<2.3,Ks=Js&&Qs<5&&Hs<537,Zs=/Firefox/i.test(Ls),te=/Edge/i.test(Ls),ie=!te&&/Chrome/i.test(Ls),se=function(){var t=Ls.match(/Chrome\/(\d+)/);return t&&t[1]?_(t[1]):null}(),ee=/MSIE\s8\.0/.test(Ls),ne=function(){var t=/MSIE\s(\d+)\.\d/.exec(Ls),i=t&&_(t[1]);return!i&&/Trident\/7.0/i.test(Ls)&&/rv:11.0/.test(Ls)&&(i=11),i}(),re=/Safari/i.test(Ls)&&!ie&&!Js&&!te,he=re||Gs,oe=ds()&&("ontouchstart"in o||o.DocumentTouch&&o.document instanceof o.DocumentTouch),ae=ds()&&"backgroundSize"in o.document.createElement("video").style,ue=g.freeze({__proto__:null,IS_IPAD:zs,IS_IPHONE:Ws,IS_IPOD:qs,IS_IOS:Gs,IOS_VERSION:Xs,IS_ANDROID:Js,ANDROID_VERSION:Qs,IS_OLD_ANDROID:Ys,IS_NATIVE_ANDROID:Ks,IS_FIREFOX:Zs,IS_EDGE:te,IS_CHROME:ie,CHROME_VERSION:se,IS_IE8:ee,IE_VERSION:ne,IS_SAFARI:re,IS_ANY_SAFARI:he,TOUCH_ENABLED:oe,BACKGROUND_SIZE_SUPPORTED:ae});function ce(t,i){var s=ks(t);0===s.handlers[i].length&&(delete s.handlers[i],t.removeEventListener?t.removeEventListener(i,s.dispatcher,!1):t.detachEvent&&t.detachEvent("on"+i,s.dispatcher)),g.getOwnPropertyNames(s.handlers).length<=0&&(delete s.handlers,delete s.dispatcher,delete s.disabled),0===g.getOwnPropertyNames(s).length&&js(t)}function le(t,i,s,e){s.forEach((function(s){t(i,s,e)}))}function fe(t){function i(){return!0}function s(){return!1}if(!t||!t.isPropagationStopped||!t.isImmediatePropagationStopped){var e=t||o.event;for(var n in t={},e)"layerX"!==n&&"layerY"!==n&&"keyLocation"!==n&&"webkitMovementX"!==n&&"webkitMovementY"!==n&&"path"!==n&&("returnValue"===n&&e.preventDefault||(t[n]=e[n]));if(t.target||(t.target=t.srcElement||Xi),t.relatedTarget||(t.relatedTarget=t.fromElement===t.target?t.toElement:t.fromElement),t.preventDefault=function(){e.preventDefault&&e.preventDefault(),t.returnValue=!1,e.returnValue=!1,t.defaultPrevented=!0},t.defaultPrevented=!1,t.stopPropagation=function(){e.stopPropagation&&e.stopPropagation(),t.cancelBubble=!0,e.cancelBubble=!0,t.isPropagationStopped=i},t.isPropagationStopped=s,t.stopImmediatePropagation=function(){e.stopImmediatePropagation&&e.stopImmediatePropagation(),t.isImmediatePropagationStopped=i,t.stopPropagation()},t.isImmediatePropagationStopped=s,null!==t.clientX&&void 0!==t.clientX){var r=Xi.documentElement,h=Xi.body;t.pageX=t.clientX+(r&&r.scrollLeft||h&&h.scrollLeft||0)-(r&&r.clientLeft||h&&h.clientLeft||0),t.pageY=t.clientY+(r&&r.scrollTop||h&&h.scrollTop||0)-(r&&r.clientTop||h&&h.clientTop||0)}t.which=t.charCode||t.keyCode,null!==t.button&&void 0!==t.button&&(t.button=1&t.button?0:4&t.button?1:2&t.button?2:0)}return t}var de=!1;!function(){try{var t=g.defineProperty({},"passive",{get:function(){de=!0}});o.addEventListener("test",null,t)}catch(t){}}();var ve=["touchstart","touchmove"];function pe(t,i,s){if(Array.isArray(i))return le(pe,t,i,s);var e=ks(t);if(e.handlers||(e.handlers={}),e.handlers[i]||(e.handlers[i]=[]),s.guid||(s.guid=Yi()),e.handlers[i].push(s),e.dispatcher||(e.disabled=!1,e.dispatcher=function(i,s){if(!e.disabled){i=fe(i);var n=e.handlers[i.type];if(n)for(var r=n.slice(0),h=0,o=r.length;h<o&&!i.isImmediatePropagationStopped();h++)try{r[h].call(t,i,s)}catch(t){hs.error(t)}}}),1===e.handlers[i].length)if(t.addEventListener){var n=!1;de&&ve.indexOf(i)>-1&&(n={passive:!0}),t.addEventListener(i,e.dispatcher,n)}else t.attachEvent&&t.attachEvent("on"+i,e.dispatcher)}function me(t,i,s){if(_s(t)){var e=ks(t);if(e.handlers){if(Array.isArray(i))return le(me,t,i,s);var n=function(i){e.handlers[i]=[],ce(t,i)};if(i){var r=e.handlers[i];if(r)if(s){if(s.guid)for(var h=0;h<r.length;h++)r[h].guid===s.guid&&r.splice(h--,1);ce(t,i)}else n(i)}else for(var o in e.handlers)n(o)}}}function ge(t,i,s){var e=_s(t)?ks(t):{},n=t.parentNode||t.ownerDocument;if("string"==typeof i&&(i={type:i,target:t}),i=fe(i),e.dispatcher&&e.dispatcher.call(t,i,s),n&&!i.isPropagationStopped()&&!0===i.bubbles)ge.call(null,n,i,s);else if(!n&&!i.defaultPrevented){var r=ks(i.target);i.target[i.type]&&(r.disabled=!0,"function"==typeof i.target[i.type]&&i.target[i.type](),r.disabled=!1)}return!i.defaultPrevented}function ye(t,i,s){if(Array.isArray(i))return le(ye,t,i,s);var e=function e(){me(t,i,e),s.apply(this,arguments)};e.guid=s.guid=s.guid||Yi(),pe(t,i,e)}var be,we=!1,ke=function(){if(ds()){var t=Xi.getElementsByTagName("video"),i=Xi.getElementsByTagName("audio"),s=[];if(t&&t.length>0)for(var e=0,n=t.length;e<n;e++)s.push(t[e]);if(i&&i.length>0)for(var r=0,h=i.length;r<h;r++)s.push(i[r]);if(s&&s.length>0)for(var o=0,a=s.length;o<a;o++){var u=s[o];if(!u||!u.getAttribute){_e(1);break}void 0===u.player&&null!==u.getAttribute("data-setup")&&be(u)}else we||_e(1)}};function _e(t,i){i&&(be=i),o.setTimeout(ke,t)}ds()&&"complete"===Xi.readyState?we=!0:ye(o,"load",(function(){we=!0}));var je=function(t){var i=Xi.createElement("style");return i.className=t,i},xe=function(t,i){t.styleSheet?t.styleSheet.cssText=i:t.textContent=i},Se=function(t,i,s){i.guid||(i.guid=Yi());var e=function(){return i.apply(t,arguments)};return e.guid=s?s+"_"+i.guid:i.guid,e};function Te(t){return"string"!=typeof t?t:t.charAt(0).toUpperCase()+t.slice(1)}function Ce(){for(var t={},i=arguments.length,s=new Array(i),e=0;e<i;e++)s[e]=arguments[e];return s.forEach((function(i){i&&is(i,(function(i,s){ns(i)?(ns(t[s])||(t[s]={}),t[s]=Ce(t[s],i)):t[s]=i}))})),t}var Pe=function(){function t(t,i,s){if(!t&&this.play?this.t=t=this:this.t=t,this.h=Ce({},this.h),i=this.h=Ce(this.h,i),this.o=i.id||i.el&&i.el.id,!this.o){var e=t&&t.id&&t.id()||"no_player";this.o=e+"u"+Yi()}this.l=i.name||null,i.el?this.v=i.el:!1!==i.createEl&&(this.v=this.createEl()),this.m=[],this.k={},this.j={},!1!==i.initChildren&&this.initChildren(),this.ready(s),!1!==i.reportTouchActivity&&this.enableTouchActivity()}var i=t.prototype;return i.dispose=function(){if(this.trigger({type:"dispose",bubbles:!1}),this.m)for(var t=this.m.length-1;t>=0;t--)this.m[t].dispose&&this.m[t].dispose();this.m=null,this.k=null,this.j=null,this.off(),this.v.parentNode&&this.v.parentNode.removeChild(this.v),js(this.v),this.v=null},i.player=function(){return this.t},i.options=function(t){return hs.warn("this.options() has been deprecated and will be moved to the constructor in 6.0"),t?(this.h=Ce(this.h,t),this.h):this.h},i.el=function(){return this.v},i.createEl=function(t,i,s){return ms(t,i,s)},i.localize=function(t){var i=this.t.language&&this.t.language(),s=this.t.languages&&this.t.languages();if(!i||!s)return t;var e=s[i];if(e&&e[t])return e[t];var n=s[i.split("-")[0]];return n&&n[t]?n[t]:t},i.contentEl=function(){return this.S||this.v},i.id=function(){return this.o},i.name=function(){return this.l},i.children=function(){return this.m},i.getChildById=function(t){return this.k[t]},i.getChild=function(t){if(t)return t=Te(t),this.j[t]},i.addChild=function(i,s,e){var n,r;if(void 0===s&&(s={}),void 0===e&&(e=this.m.length),"string"==typeof i){r=Te(i),s||(s={}),!0===s&&(hs.warn("Initializing a child component with `true` is deprecated.Children should be defined in an array when possible, but if necessary use an object instead of `true`."),s={});var h=s.componentClass||r;s.name=r;var o=t.getComponent(h);if(!o)throw new v("Component "+h+" does not exist");if("function"!=typeof o)return null;n=new o(this.t||this,s)}else n=i;if(this.m.splice(e,0,n),"function"==typeof n.id&&(this.k[n.id()]=n),(r=r||n.name&&Te(n.name()))&&(this.j[r]=n),"function"==typeof n.el&&n.el()){var a=this.contentEl().children[e]||null;this.contentEl().insertBefore(n.el(),a)}return n},i.removeChild=function(t){if("string"==typeof t&&(t=this.getChild(t)),t&&this.m){for(var i=!1,s=this.m.length-1;s>=0;s--)if(this.m[s]===t){i=!0,this.m.splice(s,1);break}if(i){this.k[t.id()]=null,this.j[t.name()]=null;var e=t.el();e&&e.parentNode===this.contentEl()&&this.contentEl().removeChild(t.el())}}},i.initChildren=function(){var i=this,s=this.h.children;if(s){var e,n=this.h,r=t.getComponent("Tech");(e=Array.isArray(s)?s:g.keys(s)).concat(g.keys(this.h).filter((function(t){return!e.some((function(i){return"string"==typeof i?t===i:t===i.name}))}))).map((function(t){var e,n;return"string"==typeof t?n=s[e=t]||i.h[e]||{}:(e=t.name,n=t),{name:e,opts:n}})).filter((function(i){var s=t.getComponent(i.opts.componentClass||Te(i.name));return s&&!r.isTech(s)})).forEach((function(t){var s=t.name,e=t.opts;if(void 0!==n[s]&&(e=n[s]),!1!==e){!0===e&&(e={}),e.playerOptions=i.h.playerOptions;var r=i.addChild(s,e);r&&(i[s]=r)}}))}},i.buildCSSClass=function(){return""},i.on=function(t,i,s){var e=this;if("string"==typeof t||Array.isArray(t))pe(this.v,t,Se(this,i));else{var n=t,r=i,h=Se(this,s),o=function(){return e.off(n,r,h)};o.guid=h.guid,this.on("dispose",o);var a=function(){return e.off("dispose",o)};a.guid=h.guid,t.nodeName?(pe(n,r,h),pe(n,"dispose",a)):"function"==typeof t.on&&(n.on(r,h),n.on("dispose",a))}return this},i.off=function(t,i,s){if(!t||"string"==typeof t||Array.isArray(t))me(this.v,t,i);else{var e=t,n=i,r=Se(this,s);this.off("dispose",r),t.nodeName?(me(e,n,r),me(e,"dispose",r)):(e.off(n,r),e.off("dispose",r))}return this},i.one=function(t,i,s){var e=arguments,n=this;if("string"==typeof t||Array.isArray(t))ye(this.v,t,Se(this,i));else{var r=t,h=i,o=Se(this,s),a=function t(){n.off(r,h,t),o.apply(null,e)};a.guid=o.guid,this.on(r,h,a)}return this},i.trigger=function(t,i){return ge(this.v,t,i),this},i.ready=function(t,i){return void 0===i&&(i=!1),t&&(this.T?i?t.call(this):this.setTimeout(t,1):(this.C=this.C||[],this.C.push(t))),this},i.triggerReady=function(){this.T=!0,this.setTimeout((function(){var t=this.C;this.C=[],t&&t.length>0&&t.forEach((function(t){t.call(this)}),this),this.trigger("ready")}),1)},i.$=function(t,i){return Os(t,i||this.contentEl())},i.$$=function(t,i){return Vs(t,i||this.contentEl())},i.hasClass=function(t){return xs(this.v,t)},i.addClass=function(t){return Ss(this.v,t),this},i.removeClass=function(t){return Ts(this.v,t),this},i.toggleClass=function(t,i){return Cs(this.v,t,i),this},i.show=function(){return this.removeClass("vjs-hidden"),this},i.hide=function(){return this.addClass("vjs-hidden"),this},i.lockShowing=function(){return this.addClass("vjs-lock-showing"),this},i.unlockShowing=function(){return this.removeClass("vjs-lock-showing"),this},i.getAttribute=function(t){return function(t,i){return t.getAttribute(i)}(this.v,t)},i.setAttribute=function(t,i){return Ms(this.v,t,i),this},i.removeAttribute=function(t){return Is(this.v,t),this},i.width=function(t,i){return this.dimension("width",t,i)},i.height=function(t,i){return this.dimension("height",t,i)},i.dimensions=function(t,i){return this.width(t,!0).height(i)},i.dimension=function(t,i,s){if(void 0!==i)return null!==i&&i==i||(i=0),-1!==(""+i).indexOf("%")||-1!==(""+i).indexOf("px")?this.v.style[t]=i:this.v.style[t]="auto"===i?"":i+"px",s||this.trigger("resize"),this;if(!this.v)return 0;var e=this.v.style[t],n=e.indexOf("px");return k(-1!==n?e.slice(0,n):this.v["offset"+Te(t)],10)},i.currentDimension=function(t){var i=0;if("width"!==t&&"height"!==t)throw new v("currentDimension only accepts width or height value");if("function"==typeof o.getComputedStyle){var s=o.getComputedStyle(this.v);i=s.getPropertyValue(t)||s[t]}if(0===(i=_(i))){var e="offset"+Te(t);i=this.v[e]}return i},i.currentDimensions=function(){return{width:this.currentDimension("width"),height:this.currentDimension("height")}},i.currentWidth=function(){return this.currentDimension("width")},i.currentHeight=function(){return this.currentDimension("height")},i.focus=function(){this.v.focus()},i.blur=function(){this.v.blur()},i.emitTapEvents=function(){var t,i=0,s=null;this.on("touchstart",(function(e){1===e.touches.length&&(s={pageX:e.touches[0].pageX,pageY:e.touches[0].pageY},i=(new Date).getTime(),t=!0)})),this.on("touchmove",(function(i){if(i.touches.length>1)t=!1;else if(s){var e=i.touches[0].pageX-s.pageX,n=i.touches[0].pageY-s.pageY;w.sqrt(e*e+n*n)>10&&(t=!1)}}));var e=function(){t=!1};this.on("touchleave",e),this.on("touchcancel",e),this.on("touchend",(function(e){(s=null,!0===t)&&((new Date).getTime()-i<200&&(e.preventDefault(),this.trigger("tap")))}))},i.enableTouchActivity=function(){if(this.player()&&this.player().reportUserActivity){var t,i=Se(this.player(),this.player().reportUserActivity);this.on("touchstart",(function(){i(),this.clearInterval(t),t=this.setInterval(i,250)}));var s=function(s){i(),this.clearInterval(t)};this.on("touchmove",i),this.on("touchend",s),this.on("touchcancel",s)}},i.setTimeout=function(t,i){t=Se(this,t);var s=o.setTimeout(t,i),e=function(){this.clearTimeout(s)};return e.guid="vjs-timeout-"+s,this.on("dispose",e),s},i.clearTimeout=function(t){o.clearTimeout(t);var i=function(){};return i.guid="vjs-timeout-"+t,this.off("dispose",i),t},i.setInterval=function(t,i){t=Se(this,t);var s=o.setInterval(t,i),e=function(){this.clearInterval(s)};return e.guid="vjs-interval-"+s,this.on("dispose",e),s},i.clearInterval=function(t){o.clearInterval(t);var i=function(){};return i.guid="vjs-interval-"+t,this.off("dispose",i),t},t.registerComponent=function(i,s){if(i){if(i=Te(i),t.P||(t.P={}),"Player"===i&&t.P[i]){var e=t.P[i];if(e.players&&g.keys(e.players).length>0&&g.keys(e.players).map((function(t){return e.players[t]})).every(Boolean))throw new v("Can not register Player component after player has been created")}return t.P[i]=s,s}},t.getComponent=function(i){if(i)return i=Te(i),t.P&&t.P[i]?t.P[i]:o&&o.videojs&&o.videojs[i]?(hs.warn("The "+i+" component was added to the videojs object when it should be registered using videojs.registerComponent(name, component)"),o.videojs[i]):void 0},t.extend=function(i){i=i||{},hs.warn("Component.extend({}) has been deprecated, use videojs.extend(Component, {}) instead");var s=i.init||i.init||this.prototype.init||this.prototype.init||function(){},e=function(){s.apply(this,arguments)};for(var n in(e.prototype=g.create(this.prototype)).constructor=e,e.extend=t.extend,i)i.hasOwnProperty(n)&&(e.prototype[n]=i[n]);return e},t}();Pe.registerComponent("Component",Pe);var Ae=function(){};function Me(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Ie(t,i){return(Ie=g.setPrototypeOf?g.setPrototypeOf.bind():function(t,i){return t.__proto__=i,t})(t,i)}function Ee(t,i){t.prototype=g.create(i.prototype),t.prototype.constructor=t,Ie(t,i)}function De(t,i,s,e){return void 0===e&&(hs.warn("DEPRECATED: Function '"+t+"' on 'TimeRanges' called without an index argument."),e=0),function(t,i,s){if(i<0||i>s)throw new v("Failed to execute '"+t+"' on 'TimeRanges': The index provided ("+i+") is greater than or equal to the maximum bound ("+s+").")}(t,e,s.length-1),s[e][i]}function Ne(t){return void 0===t||0===t.length?{length:0,start:function(){throw new v("This TimeRanges object is empty")},end:function(){throw new v("This TimeRanges object is empty")}}:{length:t.length,start:De.bind(null,"start",0,t),end:De.bind(null,"end",1,t)}}function Fe(t,i){return Array.isArray(t)?Ne(t):void 0===t||void 0===i?Ne():Ne([[t,i]])}function $e(t,i){var s,e,n=0;if(!i)return 0;t&&t.length||(t=Fe(0,0));for(var r=0;r<t.length;r++)s=t.start(r),(e=t.end(r))>i&&(e=i),n+=e-s;return n/i}Ae.prototype.A={},Ae.prototype.on=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},pe(this,t,i),this.addEventListener=s},Ae.prototype.addEventListener=Ae.prototype.on,Ae.prototype.off=function(t,i){me(this,t,i)},Ae.prototype.removeEventListener=Ae.prototype.off,Ae.prototype.one=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},ye(this,t,i),this.addEventListener=s},Ae.prototype.trigger=function(t){var i=t.type||t;"string"==typeof t&&(t={type:i}),t=fe(t),this.A[i]&&this["on"+i]&&this["on"+i](t),ge(this,t)},Ae.prototype.dispatchEvent=Ae.prototype.trigger;var Be,Re,Oe,Ve,Le={prefixed:!0},Ue=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]],He=Ue[0];for(Re=0;Re<Ue.length;Re++)if(Ue[Re][1]in Xi){Be=Ue[Re];break}if(Be){for(Oe=0;Oe<Be.length;Oe++)Le[He[Oe]]=Be[Oe];Le.prefixed=Be[0]!==He[0]}function ze(t){if(t instanceof ze)return t;"number"==typeof t?this.code=t:"string"==typeof t?this.message=t:es(t)&&("number"==typeof t.code&&(this.code=t.code),ss(this,t)),this.message||(this.message=ze.defaultMessages[this.code]||"")}for(ze.prototype.code=0,ze.prototype.message="",ze.prototype.status=null,ze.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],ze.defaultMessages={1:"You aborted the media playback",2:"A network error caused the media download to fail part-way.",3:"The media playback was aborted due to a corruption problem or because the media used features your browser did not support.",4:"The media could not be loaded, either because the server or network failed or because the format is not supported.",5:"The media is encrypted and we do not have the keys to decrypt it."},Ve=0;Ve<ze.errorTypes.length;Ve++)ze[ze.errorTypes[Ve]]=Ve,ze.prototype[ze.errorTypes[Ve]]=Ve;var We=function(t,i){var s,e=null;try{s=JSON.parse(t,i)}catch(t){e=t}return[e,s]};var qe=function(t){return["kind","label","language","id","inBandMetadataTrackDispatchType","mode","src"].reduce((function(i,s,e){return t[s]&&(i[s]=t[s]),i}),{cues:t.cues&&Array.prototype.map.call(t.cues,(function(t){return{startTime:t.startTime,endTime:t.endTime,text:t.text,id:t.id}}))})},Ge=function(t){var i=t.$$("track"),s=Array.prototype.map.call(i,(function(t){return t.track}));return Array.prototype.map.call(i,(function(t){var i=qe(t.track);return t.src&&(i.src=t.src),i})).concat(Array.prototype.filter.call(t.textTracks(),(function(t){return-1===s.indexOf(t)})).map(qe))},Xe=function(t,i){return t.forEach((function(t){var s=i.addRemoteTextTrack(t).track;!t.src&&t.cues&&t.cues.forEach((function(t){return s.addCue(t)}))})),i.textTracks()},Je="vjs-modal-dialog",Qe=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).M=e.I=e.D=!1,e.closeable(!e.h.uncloseable),e.content(e.h.content),e.S=ms("div",{className:Je+"-content"},{role:"document"}),e.N=ms("p",{className:Je+"-description vjs-offscreen",id:e.el().getAttribute("aria-describedby")}),gs(e.N,e.description()),e.v.appendChild(e.N),e.v.appendChild(e.S),e.on(i,"languagechange",e.handleLanguagechange),e}Ee(i,t);var s=i.prototype;return s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-describedby":this.id()+"F","aria-hidden":"true","aria-label":this.label(),role:"dialog"})},s.buildCSSClass=function(){return Je+" vjs-hidden "+t.prototype.buildCSSClass.call(this)},s.handleKeyPress=function(t){27===t.which&&this.closeable()&&this.close()},s.label=function(){return this.h.label||this.localize("Modal Window")},s.description=function(){var t=this.h.description||this.localize("This is a modal window.");return this.closeable()&&(t+=" "+this.localize("This modal can be closed by pressing the Escape key or activating the close button.")),t},s.open=function(){if(!this.M){var t=this.player();this.trigger("beforemodalopen"),this.M=!0,(this.h.fillAlways||!this.I&&!this.D)&&this.fill(),this.B=!t.paused(),this.h.pauseOnOpen&&this.B&&t.pause(),this.closeable()&&this.on(this.v.ownerDocument,"keydown",Se(this,this.handleKeyPress)),t.controls(!1),this.show(),this.el().setAttribute("aria-hidden","false"),this.trigger("modalopen"),this.I=!0}return this},s.opened=function(t){return"boolean"==typeof t&&this[t?"open":"close"](),this.M},s.close=function(){if(this.M){var t=this.player();this.trigger("beforemodalclose"),this.M=!1,this.B&&this.h.pauseOnOpen&&t.play(),this.closeable()&&this.off(this.v.ownerDocument,"keydown",Se(this,this.handleKeyPress)),t.controls(!0),this.hide(),this.el().setAttribute("aria-hidden","true"),this.trigger("modalclose"),this.h.temporary&&this.dispose()}return this},s.closeable=function(t){if("boolean"==typeof t){var i=this.R=!!t,s=this.getChild("closeButton");if(i&&!s){var e=this.S;this.S=this.v,s=this.addChild("closeButton",{controlText:"Close Modal Dialog"}),this.S=e,this.on(s,"close",this.close)}!i&&s&&(this.off(s,"close",this.close),this.removeChild(s),s.dispose())}return this.R},s.fill=function(){return this.fillWith(this.content())},s.fillWith=function(t){var i=this.contentEl(),s=i.parentNode,e=i.nextSibling;return this.trigger("beforemodalfill"),this.D=!0,s.removeChild(i),this.empty(),Bs(i,t),this.trigger("modalfill"),e?s.insertBefore(i,e):s.appendChild(i),this},s.empty=function(){return this.trigger("beforemodalempty"),Fs(this.contentEl()),this.trigger("modalempty"),this},s.content=function(t){return void 0!==t&&(this.O=t),this.O},s.handleLanguagechange=function(){this.v.setAttribute("aria-label",this.label()),gs(this.N,this.description()),this.opened()?this.fill():(this.I||this.D)&&(this.I=!1,this.D=!1,this.empty())},i}(Pe);Qe.prototype.h={pauseOnOpen:!0,temporary:!0},Pe.registerComponent("ModalDialog",Qe);var Ye=function(){function t(i){var s=this;if(ee)for(var e in s=Xi.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);if(t.prototype.V.call(s,i),g.defineProperty(s,"length",{get:function(){return this.L}}),ee)return s}var i=t.prototype;return i.V=function(t){var i=this.length||0,s=0,e=t.length;this.U=t,this.L=t.length;var n=function(t){""+t in this||g.defineProperty(this,""+t,{get:function(){return this.U[t]}})};if(i<e)for(s=i;s<e;s++)n.call(this,s)},i.getCueById=function(t){for(var i=null,s=0,e=this.length;s<e;s++){var n=this[s];if(n.id===t){i=n;break}}return i},t}(),Ke={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},Ze={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},tn={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},sn={disabled:"disabled",hidden:"hidden",showing:"showing"},en=function(t){function i(s){var e;void 0===s&&(s={});var n=Me(e=t.call(this)||this);if(ee)for(var r in n=Xi.createElement("custom"),i.prototype)"constructor"!==r&&(n[r]=i.prototype[r]);var h={id:s.id||["vjs_track",Yi()].join("_"),kind:s.kind||"",label:s.label||"",language:s.language||""},o=function(t){g.defineProperty(n,t,{get:function(){return h[t]},set:function(){}})};for(var a in h)o(a);return n||Me(e)}return Ee(i,t),i}(Ae),nn=function(t){var i=["protocol","hostname","port","pathname","search","hash","host"],s=Xi.createElement("a");s.href=t;var e,n=""===s.host&&"file:"!==s.protocol;n&&((e=Xi.createElement("div")).innerHTML='<a href="'+t+'"></a>',s=e.firstChild,e.setAttribute("style","display:none; position:absolute;"),Xi.body.appendChild(e));for(var r={},h=0;h<i.length;h++)r[i[h]]=s[i[h]];return"http:"===r.protocol&&(r.host=r.host.replace(/:80$/,"")),"https:"===r.protocol&&(r.host=r.host.replace(/:443$/,"")),n&&Xi.body.removeChild(e),r},rn=function(t){var i=o.location,s=nn(t);return(":"===s.protocol?i.protocol:s.protocol)+s.host!==i.protocol+i.host},hn={exports:{}};void 0!==a?hn.exports=a:void 0!==os?hn.exports=os:"undefined"!=typeof self?hn.exports=self:hn.exports={};var on=function(t){var i=an.call(t);return"[object Function]"===i||"function"==typeof t&&"[object RegExp]"!==i||void 0!==a&&(t===a.setTimeout||t===a.alert||t===a.confirm||t===a.prompt)},an=g.prototype.toString;var un,cn,ln,fn,dn,vn,pn,mn,gn,yn,bn,wn,kn=Array.prototype.slice,_n=g.prototype.toString,jn=function(t){var i=this;if("function"!=typeof i||"[object Function]"!==_n.call(i))throw new p("Function.prototype.bind called on incompatible "+i);for(var s,e=kn.call(arguments,1),n=w.max(0,i.length-e.length),r=[],h=0;h<n;h++)r.push("$"+h);if(s=Function("binder","return function ("+r.join(",")+"){ return binder.apply(this,arguments); }")((function(){if(this instanceof s){var n=i.apply(this,e.concat(kn.call(arguments)));return g(n)===n?n:this}return i.apply(t,e.concat(kn.call(arguments)))})),i.prototype){var o=function(){};o.prototype=i.prototype,s.prototype=new o,o.prototype=null}return s},xn=Function.prototype.bind||jn,Sn=g.prototype.toString,Tn=function(t){var i=Sn.call(t),s="[object Arguments]"===i;return s||(s="[object Array]"!==i&&null!==t&&"object"==typeof t&&"number"==typeof t.length&&t.length>=0&&"[object Function]"===Sn.call(t.callee)),s};g.keys||(cn=g.prototype.hasOwnProperty,ln=g.prototype.toString,fn=Tn,dn=g.prototype.propertyIsEnumerable,vn=!dn.call({toString:null},"toString"),pn=dn.call((function(){}),"prototype"),mn=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],gn=function(t){var i=t.constructor;return i&&i.prototype===t},yn={$applicationCache:!0,$console:!0,$external:!0,$frame:!0,$frameElement:!0,$frames:!0,$innerHeight:!0,$innerWidth:!0,$onmozfullscreenchange:!0,$onmozfullscreenerror:!0,$outerHeight:!0,$outerWidth:!0,$pageXOffset:!0,$pageYOffset:!0,$parent:!0,$scrollLeft:!0,$scrollTop:!0,$scrollX:!0,$scrollY:!0,$self:!0,$webkitIndexedDB:!0,$webkitStorageInfo:!0,$window:!0},bn=function(){if(void 0===a)return!1;for(var t in a)try{if(!yn["$"+t]&&cn.call(a,t)&&null!==a[t]&&"object"==typeof a[t])try{gn(a[t])}catch(t){return!0}}catch(t){return!0}return!1}(),wn=function(t){if(void 0===a||!bn)return gn(t);try{return gn(t)}catch(t){return!1}},un=function(t){var i=null!==t&&"object"==typeof t,s="[object Function]"===ln.call(t),e=fn(t),n=i&&"[object String]"===ln.call(t),r=[];if(!i&&!s&&!e)throw new p("Object.keys called on a non-object");var h=pn&&s;if(n&&t.length>0&&!cn.call(t,0))for(var o=0;o<t.length;++o)r.push(String(o));if(e&&t.length>0)for(var a=0;a<t.length;++a)r.push(String(a));else for(var u in t)h&&"prototype"===u||!cn.call(t,u)||r.push(String(u));if(vn)for(var c=wn(t),l=0;l<mn.length;++l)c&&"constructor"===mn[l]||!cn.call(t,mn[l])||r.push(mn[l]);return r});var Cn=un,Pn=Array.prototype.slice,An=Tn,Mn=g.keys,In=Mn?function(t){return Mn(t)}:Cn,En=g.keys;In.shim=function(){if(g.keys){var t=function(){var t=g.keys(arguments);return t&&t.length===arguments.length}(1,2);t||(g.keys=function(t){return An(t)?En(Pn.call(t)):En(t)})}else g.keys=In;return g.keys||In};var Dn=In,Nn="function"==typeof Symbol&&"symbol"==typeof Symbol("foo"),Fn=g.prototype.toString,$n=Array.prototype.concat,Bn=g.defineProperty,Rn=Bn&&function(){var t={};try{for(var i in Bn(t,"x",{enumerable:!1,value:t}),t)return!1;return t.x===t}catch(t){return!1}}(),On=function(t,i,s,e){(!(i in t)||function(t){return"function"==typeof t&&"[object Function]"===Fn.call(t)}(e)&&e())&&(Rn?Bn(t,i,{configurable:!0,enumerable:!1,value:s,writable:!0}):t[i]=s)},Vn=function(t,i){var s=arguments.length>2?arguments[2]:{},e=Dn(i);Nn&&(e=$n.call(e,g.getOwnPropertySymbols(i)));for(var n=0;n<e.length;n+=1)On(t,e[n],i[e[n]],s[e[n]])};Vn.supportsDescriptors=!!Rn;var Ln,Un=Vn,Hn=g.getOwnPropertyDescriptor?function(){return g.getOwnPropertyDescriptor(arguments,"callee").get}():function(){throw new p},zn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator,Wn=g.getPrototypeOf||function(t){return t.__proto__},qn=void 0===x?Ln:Wn(x),Gn={"$ %Array%":Array,"$ %ArrayBuffer%":"undefined"==typeof ArrayBuffer?Ln:ArrayBuffer,"$ %ArrayBufferPrototype%":"undefined"==typeof ArrayBuffer?Ln:ArrayBuffer.prototype,"$ %ArrayIteratorPrototype%":zn?Wn([][Symbol.iterator]()):Ln,"$ %ArrayPrototype%":Array.prototype,"$ %ArrayProto_entries%":Array.prototype.entries,"$ %ArrayProto_forEach%":Array.prototype.forEach,"$ %ArrayProto_keys%":Array.prototype.keys,"$ %ArrayProto_values%":Array.prototype.values,"$ %AsyncFromSyncIteratorPrototype%":Ln,"$ %AsyncFunction%":undefined,"$ %AsyncFunctionPrototype%":Ln,"$ %AsyncGenerator%":Ln,"$ %AsyncGeneratorFunction%":undefined,"$ %AsyncGeneratorPrototype%":Ln,"$ %AsyncIteratorPrototype%":Ln,"$ %Atomics%":"undefined"==typeof Atomics?Ln:Atomics,"$ %Boolean%":Boolean,"$ %BooleanPrototype%":Boolean.prototype,"$ %DataView%":"undefined"==typeof DataView?Ln:DataView,"$ %DataViewPrototype%":"undefined"==typeof DataView?Ln:DataView.prototype,"$ %Date%":Date,"$ %DatePrototype%":Date.prototype,"$ %decodeURI%":decodeURI,"$ %decodeURIComponent%":decodeURIComponent,"$ %encodeURI%":encodeURI,"$ %encodeURIComponent%":encodeURIComponent,"$ %Error%":v,"$ %ErrorPrototype%":v.prototype,"$ %eval%":eval,"$ %EvalError%":EvalError,"$ %EvalErrorPrototype%":EvalError.prototype,"$ %Float32Array%":"undefined"==typeof Float32Array?Ln:Float32Array,"$ %Float32ArrayPrototype%":"undefined"==typeof Float32Array?Ln:Float32Array.prototype,"$ %Float64Array%":"undefined"==typeof Float64Array?Ln:Float64Array,"$ %Float64ArrayPrototype%":"undefined"==typeof Float64Array?Ln:Float64Array.prototype,"$ %Function%":Function,"$ %FunctionPrototype%":Function.prototype,"$ %Generator%":Ln,"$ %GeneratorFunction%":undefined,"$ %GeneratorPrototype%":Ln,"$ %Int8Array%":"undefined"==typeof Int8Array?Ln:Int8Array,"$ %Int8ArrayPrototype%":"undefined"==typeof Int8Array?Ln:Int8Array.prototype,"$ %Int16Array%":"undefined"==typeof Int16Array?Ln:Int16Array,"$ %Int16ArrayPrototype%":"undefined"==typeof Int16Array?Ln:Int8Array.prototype,"$ %Int32Array%":"undefined"==typeof Int32Array?Ln:Int32Array,"$ %Int32ArrayPrototype%":"undefined"==typeof Int32Array?Ln:Int32Array.prototype,"$ %isFinite%":isFinite,"$ %isNaN%":j,"$ %IteratorPrototype%":zn?Wn(Wn([][Symbol.iterator]())):Ln,"$ %JSON%":JSON,"$ %JSONParse%":JSON.parse,"$ %Map%":"undefined"==typeof Map?Ln:Map,"$ %MapIteratorPrototype%":"undefined"!=typeof Map&&zn?Wn((new Map)[Symbol.iterator]()):Ln,"$ %MapPrototype%":"undefined"==typeof Map?Ln:Map.prototype,"$ %Math%":w,"$ %Number%":Number,"$ %NumberPrototype%":Number.prototype,"$ %Object%":g,"$ %ObjectPrototype%":g.prototype,"$ %ObjProto_toString%":g.prototype.toString,"$ %ObjProto_valueOf%":g.prototype.valueOf,"$ %parseFloat%":_,"$ %parseInt%":k,"$ %Promise%":"undefined"==typeof Promise?Ln:Promise,"$ %PromisePrototype%":"undefined"==typeof Promise?Ln:Promise.prototype,"$ %PromiseProto_then%":"undefined"==typeof Promise?Ln:Promise.prototype.then,"$ %Promise_all%":"undefined"==typeof Promise?Ln:Promise.all,"$ %Promise_reject%":"undefined"==typeof Promise?Ln:Promise.reject,"$ %Promise_resolve%":"undefined"==typeof Promise?Ln:Promise.resolve,"$ %Proxy%":"undefined"==typeof Proxy?Ln:Proxy,"$ %RangeError%":RangeError,"$ %RangeErrorPrototype%":RangeError.prototype,"$ %ReferenceError%":ReferenceError,"$ %ReferenceErrorPrototype%":ReferenceError.prototype,"$ %Reflect%":"undefined"==typeof Reflect?Ln:Reflect,"$ %RegExp%":RegExp,"$ %RegExpPrototype%":RegExp.prototype,"$ %Set%":"undefined"==typeof Set?Ln:Set,"$ %SetIteratorPrototype%":"undefined"!=typeof Set&&zn?Wn((new Set)[Symbol.iterator]()):Ln,"$ %SetPrototype%":"undefined"==typeof Set?Ln:Set.prototype,"$ %SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?Ln:SharedArrayBuffer,"$ %SharedArrayBufferPrototype%":"undefined"==typeof SharedArrayBuffer?Ln:SharedArrayBuffer.prototype,"$ %String%":String,"$ %StringIteratorPrototype%":zn?Wn(""[Symbol.iterator]()):Ln,"$ %StringPrototype%":String.prototype,"$ %Symbol%":zn?Symbol:Ln,"$ %SymbolPrototype%":zn?Symbol.prototype:Ln,"$ %SyntaxError%":m,"$ %SyntaxErrorPrototype%":m.prototype,"$ %ThrowTypeError%":Hn,"$ %TypedArray%":qn,"$ %TypedArrayPrototype%":qn?qn.prototype:Ln,"$ %TypeError%":p,"$ %TypeErrorPrototype%":p.prototype,"$ %Uint8Array%":void 0===x?Ln:x,"$ %Uint8ArrayPrototype%":void 0===x?Ln:x.prototype,"$ %Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?Ln:Uint8ClampedArray,"$ %Uint8ClampedArrayPrototype%":"undefined"==typeof Uint8ClampedArray?Ln:Uint8ClampedArray.prototype,"$ %Uint16Array%":"undefined"==typeof Uint16Array?Ln:Uint16Array,"$ %Uint16ArrayPrototype%":"undefined"==typeof Uint16Array?Ln:Uint16Array.prototype,"$ %Uint32Array%":"undefined"==typeof Uint32Array?Ln:Uint32Array,"$ %Uint32ArrayPrototype%":"undefined"==typeof Uint32Array?Ln:Uint32Array.prototype,"$ %URIError%":URIError,"$ %URIErrorPrototype%":URIError.prototype,"$ %WeakMap%":"undefined"==typeof WeakMap?Ln:WeakMap,"$ %WeakMapPrototype%":"undefined"==typeof WeakMap?Ln:WeakMap.prototype,"$ %WeakSet%":"undefined"==typeof WeakSet?Ln:WeakSet,"$ %WeakSetPrototype%":"undefined"==typeof WeakSet?Ln:WeakSet.prototype},Xn=function(t,i){if(arguments.length>1&&"boolean"!=typeof i)throw new p('"allowMissing" argument must be a boolean');var s="$ "+t;if(!(s in Gn))throw new m("intrinsic "+t+" does not exist!");if(void 0===Gn[s]&&!i)throw new p("intrinsic "+t+" exists, but is not available. Please file an issue!");return Gn[s]},Jn=xn.call(Function.call,g.prototype.hasOwnProperty),Qn=Xn,Yn=Qn("%TypeError%"),Kn=Qn("%SyntaxError%"),Zn=Jn,tr={"Property Descriptor":function(t,i){if("Object"!==t.Type(i))return!1;var s={"[[Configurable]]":!0,"[[Enumerable]]":!0,"[[Get]]":!0,"[[Set]]":!0,"[[Value]]":!0,"[[Writable]]":!0};for(var e in i)if(Zn(i,e)&&!s[e])return!1;var n=Zn(i,"[[Value]]"),r=Zn(i,"[[Get]]")||Zn(i,"[[Set]]");if(n&&r)throw new Yn("Property Descriptors may not be both accessor and data descriptors");return!0}},ir=Number.isNaN||function(t){return t!=t},sr=Number.isNaN||function(t){return t!=t},er=Number.isFinite||function(t){return"number"==typeof t&&!sr(t)&&t!==1/0&&t!==-1/0},nr=Function.prototype.toString,rr=/^\s*class\b/,hr=function(t){try{var i=nr.call(t);return rr.test(i)}catch(t){return!1}},or=g.prototype.toString,ar="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,ur=function(t){if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if("function"==typeof t&&!t.prototype)return!0;if(ar)return function(t){try{return!hr(t)&&(nr.call(t),!0)}catch(t){return!1}}(t);if(hr(t))return!1;var i=or.call(t);return"[object Function]"===i||"[object GeneratorFunction]"===i},cr=g.prototype.toString,lr=function(t){return null===t||"function"!=typeof t&&"object"!=typeof t},fr=ur,dr=function(t){var i;if((i=arguments.length>1?arguments[1]:"[object Date]"===cr.call(t)?String:Number)===String||i===Number){var s,e,n=i===String?["toString","valueOf"]:["valueOf","toString"];for(e=0;e<n.length;++e)if(fr(t[n[e]])&&(s=t[n[e]](),lr(s)))return s;throw new p("No default value")}throw new p("invalid [[DefaultValue]] hint supplied")},vr=Xn,pr=vr("%Object%"),mr=vr("%TypeError%"),gr=vr("%String%"),yr=function(t,i,s,e){var n=tr[i];if("function"!=typeof n)throw new Kn("unknown record type: "+i);if(!n(t,e))throw new Yn(s+" must be a "+i);console.log(n(t,e),e)},br=ir,wr=er,kr=function(t){return t>=0?1:-1},_r=function(t,i){var s=t%i;return w.floor(s>=0?s:s+i)},jr=Jn,xr={ToPrimitive:function(t){return lr(t)?t:arguments.length>1?dr(t,arguments[1]):dr(t)},ToBoolean:function(t){return!!t},ToNumber:function(t){return+t},ToInteger:function(t){var i=this.ToNumber(t);return br(i)?0:0!==i&&wr(i)?kr(i)*w.floor(w.abs(i)):i},ToInt32:function(t){return this.ToNumber(t)>>0},ToUint32:function(t){return this.ToNumber(t)>>>0},ToUint16:function(t){var i=this.ToNumber(t);if(br(i)||0===i||!wr(i))return 0;var s=kr(i)*w.floor(w.abs(i));return _r(s,65536)},ToString:function(t){return gr(t)},ToObject:function(t){return this.CheckObjectCoercible(t),pr(t)},CheckObjectCoercible:function(t,i){if(null==t)throw new mr(i||"Cannot call method on "+t);return t},IsCallable:ur,SameValue:function(t,i){return t===i?0!==t||1/t==1/i:br(t)&&br(i)},Type:function(t){return null===t?"Null":void 0===t?"Undefined":"function"==typeof t||"object"==typeof t?"Object":"number"==typeof t?"Number":"boolean"==typeof t?"Boolean":"string"==typeof t?"String":void 0},IsPropertyDescriptor:function(t){if("Object"!==this.Type(t))return!1;var i={"[[Configurable]]":!0,"[[Enumerable]]":!0,"[[Get]]":!0,"[[Set]]":!0,"[[Value]]":!0,"[[Writable]]":!0};for(var s in t)if(jr(t,s)&&!i[s])return!1;var e=jr(t,"[[Value]]"),n=jr(t,"[[Get]]")||jr(t,"[[Set]]");if(e&&n)throw new mr("Property Descriptors may not be both accessor and data descriptors");return!0},IsAccessorDescriptor:function(t){return void 0!==t&&(yr(this,"Property Descriptor","Desc",t),!(!jr(t,"[[Get]]")&&!jr(t,"[[Set]]")))},IsDataDescriptor:function(t){return void 0!==t&&(yr(this,"Property Descriptor","Desc",t),!(!jr(t,"[[Value]]")&&!jr(t,"[[Writable]]")))},IsGenericDescriptor:function(t){return void 0!==t&&(yr(this,"Property Descriptor","Desc",t),!this.IsAccessorDescriptor(t)&&!this.IsDataDescriptor(t))},FromPropertyDescriptor:function(t){if(void 0===t)return t;if(yr(this,"Property Descriptor","Desc",t),this.IsDataDescriptor(t))return{value:t["[[Value]]"],writable:!!t["[[Writable]]"],enumerable:!!t["[[Enumerable]]"],configurable:!!t["[[Configurable]]"]};if(this.IsAccessorDescriptor(t))return{get:t["[[Get]]"],set:t["[[Set]]"],enumerable:!!t["[[Enumerable]]"],configurable:!!t["[[Configurable]]"]};throw new mr("FromPropertyDescriptor must be called with a fully populated Property Descriptor")},ToPropertyDescriptor:function(t){if("Object"!==this.Type(t))throw new mr("ToPropertyDescriptor requires an object");var i={};if(jr(t,"enumerable")&&(i["[[Enumerable]]"]=this.ToBoolean(t.enumerable)),jr(t,"configurable")&&(i["[[Configurable]]"]=this.ToBoolean(t.configurable)),jr(t,"value")&&(i["[[Value]]"]=t.value),jr(t,"writable")&&(i["[[Writable]]"]=this.ToBoolean(t.writable)),jr(t,"get")){var s=t.get;if(void 0!==s&&!this.IsCallable(s))throw new p("getter must be a function");i["[[Get]]"]=s}if(jr(t,"set")){var e=t.set;if(void 0!==e&&!this.IsCallable(e))throw new mr("setter must be a function");i["[[Set]]"]=e}if((jr(i,"[[Get]]")||jr(i,"[[Set]]"))&&(jr(i,"[[Value]]")||jr(i,"[[Writable]]")))throw new mr("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return i}},Sr=xn.call(Function.call,String.prototype.replace),Tr=/^[\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF]+/,Cr=/[\x09\x0A\x0B\x0C\x0D\x20\xA0\u1680\u180E\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200A\u202F\u205F\u3000\u2028\u2029\uFEFF]+$/,Pr=function(){var t=xr.ToString(xr.CheckObjectCoercible(this));return Sr(Sr(t,Tr,""),Cr,"")},Ar=Pr,Mr=function(){return String.prototype.trim&&"\u200b"==="\u200b".trim()?String.prototype.trim:Ar},Ir=Un,Er=Mr,Dr=Un,Nr=Pr,Fr=Mr,$r=function(){var t=Er();return Ir(String.prototype,{trim:t},{trim:function(){return String.prototype.trim!==t}}),t},Br=xn.call(Function.call,Fr());Dr(Br,{getPolyfill:Fr,implementation:Nr,shim:$r});var Rr=Br,Or=ur,Vr=g.prototype.toString,Lr=g.prototype.hasOwnProperty,Ur=Rr,Hr=function(t,i,s){if(!Or(i))throw new p("iterator must be a function");var e;arguments.length>=3&&(e=s),"[object Array]"===Vr.call(t)?function(t,i,s){for(var e=0,n=t.length;e<n;e++)Lr.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))}(t,i,e):"string"==typeof t?function(t,i,s){for(var e=0,n=t.length;e<n;e++)null==s?i(t.charAt(e),e,t):i.call(s,t.charAt(e),e,t)}(t,i,e):function(t,i,s){for(var e in t)Lr.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))}(t,i,e)},zr=function(){for(var t={},i=0;i<arguments.length;i++){var s=arguments[i];for(var e in s)Wr.call(s,e)&&(t[e]=s[e])}return t},Wr=g.prototype.hasOwnProperty;var qr=hn.exports,Gr=on,Xr=function(t){if(!t)return{};var i={};return Hr(Ur(t).split("\n"),(function(t){var s=t.indexOf(":"),e=Ur(t.slice(0,s)).toLowerCase(),n=Ur(t.slice(s+1));void 0===i[e]?i[e]=n:!function(t){return"[object Array]"===g.prototype.toString.call(t)}(i[e])?i[e]=[i[e],n]:i[e].push(n)})),i},Jr=zr,Qr=Kr;function Yr(t,i,s){var e=t;return Gr(i)?(s=i,"string"==typeof t&&(e={uri:t})):e=Jr(i,{uri:t}),e.callback=s,e}function Kr(t,i,s){return Zr(i=Yr(t,i,s))}function Zr(t){if(void 0===t.callback)throw new v("callback argument missing");var i=!1,s=function(s,e,n){i||(i=!0,t.callback(s,e,n))};function e(){var t=void 0;if(t=l.response?l.response:l.responseText||function(t){if("document"===t.responseType)return t.responseXML;var i=204===t.status&&t.responseXML&&"parsererror"===t.responseXML.documentElement.nodeName;if(""===t.responseType&&!i)return t.responseXML;return null}(l),b)try{t=JSON.parse(t)}catch(t){}return t}var n={body:void 0,headers:{},statusCode:0,method:p,url:d,rawRequest:l};function r(t){return c(f),t instanceof v||(t=new v(""+(t||"Unknown XMLHttpRequest Error"))),t.statusCode=0,s(t,n)}function h(){if(!a){var i;c(f),i=t.useXDR&&void 0===l.status?200:1223===l.status?204:l.status;var r=n,h=null;return 0!==i?(r={body:e(),statusCode:i,method:p,headers:{},url:d,rawRequest:l},l.getAllResponseHeaders&&(r.headers=Xr(l.getAllResponseHeaders()))):h=new v("Internal XMLHttpRequest Error"),s(h,r,r.body)}}var o,a,l=t.xhr||null;l||(l=t.cors||t.useXDR?new Kr.XDomainRequest:new Kr.XMLHttpRequest);var f,d=l.url=t.uri||t.url,p=l.method=t.method||"GET",m=t.body||t.data||null,g=l.headers=t.headers||{},y=!!t.sync,b=!1;if("json"in t&&(b=!0,g.accept||g.Accept||(g.Accept="application/json"),"GET"!==p&&"HEAD"!==p&&(g["content-type"]||g["Content-Type"]||(g["Content-Type"]="application/json"),m=JSON.stringify(t.json))),l.onreadystatechange=function(){4===l.readyState&&h()},l.onload=h,l.onerror=r,l.onprogress=function(){},l.ontimeout=r,l.open(p,d,!y,t.username,t.password),y||(l.withCredentials=!!t.withCredentials),!y&&t.timeout>0&&(f=u((function(){a=!0,l.abort("timeout");var t=new v("XMLHttpRequest timeout");t.code="ETIMEDOUT",r(t)}),t.timeout)),l.setRequestHeader)for(o in g)g.hasOwnProperty(o)&&l.setRequestHeader(o,g[o]);else if(t.headers&&!function(t){for(var i in t)if(t.hasOwnProperty(i))return!1;return!0}(t.headers))throw new v("Headers cannot be set on an XDomainRequest object");return"responseType"in t&&(l.responseType=t.responseType),"beforeSend"in t&&"function"==typeof t.beforeSend&&t.beforeSend(l),l.send(m),l}Kr.XMLHttpRequest=qr.XMLHttpRequest||function(){},Kr.XDomainRequest="withCredentials"in new Kr.XMLHttpRequest?Kr.XMLHttpRequest:qr.XDomainRequest,function(t,i){for(var s=0;s<t.length;s++)i(t[s])}(["get","put","post","patch","head","delete"],(function(t){Kr["delete"===t?"del":t]=function(i,s,e){return(s=Yr(i,s,e)).method=t.toUpperCase(),Zr(s)}}));var th=function(t,i){var s=new o.WebVTT.Parser(o,o.vttjs,o.WebVTT.StringDecoder()),e=[];s.oncue=function(t){i.addCue(t)},s.onparsingerror=function(t){e.push(t)},s.onflush=function(){i.trigger({type:"loadeddata",target:i})},s.parse(t),e.length>0&&(o.console&&o.console.groupCollapsed&&o.console.groupCollapsed("Text Track parsing errors for "+i.src),e.forEach((function(t){return hs.error(t)})),o.console&&o.console.groupEnd&&o.console.groupEnd()),s.flush()},ih=function(t){function i(s){var e;if(void 0===s&&(s={}),!s.tech)throw new v("A tech was not provided.");var n=Ce(s,{kind:tn[s.kind]||"subtitles",language:s.language||s.srclang||""}),r=sn[n.mode]||"disabled",h=n.default;"metadata"!==n.kind&&"chapters"!==n.kind||(r="hidden");var a=e=t.call(this,n)||this;if(a.H=n.tech,ee)for(var u in i.prototype)"constructor"!==u&&(a[u]=i.prototype[u]);a.U=[],a.W=[];var c=new Ye(a.U),l=new Ye(a.W),f=!1,d=Se(a,(function(){this.activeCues,f&&(this.trigger("cuechange"),f=!1)}));return"disabled"!==r&&a.H.ready((function(){a.H.on("timeupdate",d)}),!0),g.defineProperty(a,"default",{get:function(){return h},set:function(){}}),g.defineProperty(a,"mode",{get:function(){return r},set:function(t){var i=this;sn[t]&&("showing"===(r=t)&&this.H.ready((function(){i.H.on("timeupdate",d)}),!0),this.trigger("modechange"))}}),g.defineProperty(a,"cues",{get:function(){return this.q?c:null},set:function(){}}),g.defineProperty(a,"activeCues",{get:function(){if(!this.q)return null;if(0===this.cues.length)return l;for(var t=this.H.currentTime(),i=[],s=0,e=this.cues.length;s<e;s++){var n=this.cues[s];(n.startTime<=t&&n.endTime>=t||n.startTime===n.endTime&&n.startTime<=t&&n.startTime+.5>=t)&&i.push(n)}if(f=!1,i.length!==this.W.length)f=!0;else for(var r=0;r<i.length;r++)-1===this.W.indexOf(i[r])&&(f=!0);return this.W=i,l.V(this.W),l},set:function(){}}),n.src?(a.src=n.src,function(t,i){var s={uri:t},e=rn(t);e&&(s.cors=e),Qr(s,Se(this,(function(t,s,e){if(t)return hs.error(t,s);if(i.q=!0,"function"!=typeof o.WebVTT){if(i.H){var n=function(){return th(e,i)};i.H.on("vttjsloaded",n),i.H.on("vttjserror",(function(){hs.error("vttjs failed to load, stopping trying to process "+i.src),i.H.off("vttjsloaded",n)}))}}else th(e,i)})))}(n.src,a)):a.q=!0,a||Me(e)}Ee(i,t);var s=i.prototype;return s.addCue=function(t){var i=t;if(o.vttjs&&!(t instanceof o.vttjs.VTTCue)){for(var s in i=new o.vttjs.VTTCue(t.startTime,t.endTime,t.text),t)s in i||(i[s]=t[s]);i.id=t.id,i.G=t}var e=this.H.textTracks();if(e)for(var n=0;n<e.length;n++)e[n]!==this&&e[n].removeCue(i);this.U.push(i),this.cues.V(this.U)},s.removeCue=function(t){for(var i=this.U.length;i--;){var s=this.U[i];if(s===t||s.G&&s.G===t){this.U.splice(i,1),this.cues.V(this.U);break}}},i}(en);ih.prototype.A={cuechange:"cuechange"};var sh=function(t){function i(s){var e,n;void 0===s&&(s={});var r=Me(e=t.call(this)||this);if(ee)for(var h in r=Xi.createElement("custom"),i.prototype)"constructor"!==h&&(r[h]=i.prototype[h]);var o=new ih(s);return r.kind=o.kind,r.src=o.src,r.srclang=o.language,r.label=o.label,r.default=o.default,g.defineProperty(r,"readyState",{get:function(){return n}}),g.defineProperty(r,"track",{get:function(){return o}}),n=0,o.addEventListener("loadeddata",(function(){n=2,r.trigger({type:"load",target:r})})),ee?r||Me(e):e}return Ee(i,t),i}(Ae);sh.prototype.A={load:"load"},sh.NONE=0,sh.LOADING=1,sh.LOADED=2,sh.ERROR=3;var eh,nh=function(){function t(i){void 0===i&&(i=[]);var s=this;if(ee)for(var e in s=Xi.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);s.X=[],g.defineProperty(s,"length",{get:function(){return this.X.length}});for(var n=0,r=i.length;n<r;n++)s.J(i[n]);if(ee)return s}var i=t.prototype;return i.J=function(t){var i=this.X.length;""+i in this||g.defineProperty(this,i,{get:function(){return this.X[i]}}),-1===this.X.indexOf(t)&&this.X.push(t)},i.Y=function(t){for(var i,s=0,e=this.X.length;s<e;s++)if(t===this.X[s].track){i=this.X[s];break}return i},i.K=function(t){for(var i=0,s=this.X.length;i<s;i++)if(t===this.X[i]){this.X.splice(i,1);break}},t}(),rh=function(t){function i(s,e){var n;if(void 0===s&&(s=[]),void 0===e&&(e=null),n=t.call(this)||this,!e&&(e=Me(n),ee))for(var r in e=Xi.createElement("custom"),i.prototype)"constructor"!==r&&(e[r]=i.prototype[r]);e.Z=[],g.defineProperty(e,"length",{get:function(){return this.Z.length}});for(var h=0;h<s.length;h++)e.tt(s[h]);return e||Me(n)}Ee(i,t);var s=i.prototype;return s.tt=function(t){var i=this.Z.length;""+i in this||g.defineProperty(this,i,{get:function(){return this.Z[i]}}),-1===this.Z.indexOf(t)&&(this.Z.push(t),this.trigger({track:t,type:"addtrack"}))},s.it=function(t){for(var i,s=0,e=this.length;s<e;s++)if(this[s]===t){(i=this[s]).off&&i.off(),this.Z.splice(s,1);break}i&&this.trigger({track:i,type:"removetrack"})},s.getTrackById=function(t){for(var i=null,s=0,e=this.length;s<e;s++){var n=this[s];if(n.id===t){i=n;break}}return i},i}(Ae);for(eh in rh.prototype.A={change:"change",addtrack:"addtrack",removetrack:"removetrack"},rh.prototype.A)rh.prototype["on"+eh]=null;var hh=function(t){function i(s){var e,n;if(void 0===s&&(s=[]),ee){for(var r in n=Xi.createElement("custom"),rh.prototype)"constructor"!==r&&(n[r]=rh.prototype[r]);for(var h in i.prototype)"constructor"!==h&&(n[h]=i.prototype[h])}return(n=e=t.call(this,s,n)||this)||Me(e)}return Ee(i,t),i.prototype.tt=function(i){t.prototype.tt.call(this,i),i.addEventListener("modechange",Se(this,(function(){this.trigger("change")})))},i}(rh),oh=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].selected=!1)},ah=function(t){function i(s){var e,n;void 0===s&&(s=[]);for(var r=s.length-1;r>=0;r--)if(s[r].selected){oh(s,s[r]);break}if(ee){for(var h in n=Xi.createElement("custom"),rh.prototype)"constructor"!==h&&(n[h]=rh.prototype[h]);for(var o in i.prototype)"constructor"!==o&&(n[o]=i.prototype[o])}return(n=e=t.call(this,s,n)||this).st=!1,g.defineProperty(n,"selectedIndex",{get:function(){for(var t=0;t<this.length;t++)if(this[t].selected)return t;return-1},set:function(){}}),n||Me(e)}Ee(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.selected&&oh(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("selectedchange",(function(){s.st||(s.st=!0,oh(s,i),s.st=!1,s.trigger("change"))}))},s.addTrack=function(t){this.tt(t)},s.removeTrack=function(i){t.prototype.it.call(this,i)},i}(rh),uh=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].enabled=!1)},ch=function(t){function i(s){var e,n;void 0===s&&(s=[]);for(var r=s.length-1;r>=0;r--)if(s[r].enabled){uh(s,s[r]);break}if(ee){for(var h in n=Xi.createElement("custom"),rh.prototype)"constructor"!==h&&(n[h]=rh.prototype[h]);for(var o in i.prototype)"constructor"!==o&&(n[o]=i.prototype[o])}return(n=e=t.call(this,s,n)||this).st=!1,n||Me(e)}Ee(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.enabled&&uh(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("enabledchange",(function(){s.st||(s.st=!0,uh(s,i),s.st=!1,s.trigger("change"))}))},s.addTrack=function(t){this.tt(t)},s.removeTrack=function(i){t.prototype.it.call(this,i)},i}(rh),lh=void 0;var fh=function(t){function i(i,s){var e;return void 0===i&&(i={}),void 0===s&&(s=function(){}),i.reportTouchActivity=!1,(e=t.call(this,null,i,s)||this).et=!1,e.on("playing",(function(){this.et=!0})),e.on("loadstart",(function(){this.et=!1})),e.nt=i.textTracks,e.rt=i.videoTracks,e.ht=i.audioTracks,e.featuresProgressEvents||e.manualProgressOn(),e.featuresTimeupdateEvents||e.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach((function(t){!1===i["native"+t+"Tracks"]&&(e["featuresNative"+t+"Tracks"]=!1)})),!1===i.nativeCaptions&&(e.featuresNativeTextTracks=!1),e.featuresNativeTextTracks||e.emulateTextTracks(),e.ot=new hh,e.initTextTrackListeners(),e.initTrackListeners(),i.nativeControlsForTouch||e.emitTapEvents(),e.constructor&&(e.l=e.constructor.name||"Unknown Tech"),e}Ee(i,t);var s=i.prototype;return s.manualProgressOn=function(){this.on("durationchange",this.onDurationChange),this.manualProgress=!0,this.one("ready",this.trackProgress)},s.manualProgressOff=function(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange)},s.trackProgress=function(t){this.stopTrackingProgress(),this.progressInterval=this.setInterval(Se(this,(function(){var t=this.bufferedPercent();this.ut!==t&&this.trigger("progress"),this.ut=t,1===t&&this.stopTrackingProgress()})),500)},s.onDurationChange=function(t){this.ct=this.duration()},s.buffered=function(){return Fe(0,0)},s.bufferedPercent=function(){return $e(this.buffered(),this.ct)},s.stopTrackingProgress=function(){this.clearInterval(this.progressInterval)},s.manualTimeUpdatesOn=function(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime),this.on("pause",this.stopTrackingCurrentTime)},s.manualTimeUpdatesOff=function(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime),this.off("pause",this.stopTrackingCurrentTime)},s.trackCurrentTime=function(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval((function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}),250)},s.stopTrackingCurrentTime=function(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},s.dispose=function(){this.clearTracks(["audio","video","text"]),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),t.prototype.dispose.call(this)},s.clearTracks=function(t){var i=this;(t=[].concat(t)).forEach((function(t){for(var s=i[t+"Tracks"]()||[],e=s.length;e--;){var n=s[e];"text"===t&&i.removeRemoteTextTrack(n),s.it(n)}}))},s.cleanupAutoTextTracks=function(){for(var t=this.ot||[],i=t.length;i--;){var s=t[i];this.removeRemoteTextTrack(s)}},s.reset=function(){},s.error=function(t){return void 0!==t&&(this.lt=new ze(t),this.trigger("error")),this.lt},s.played=function(){return this.et?Fe(0,0):Fe()},s.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},s.initTextTrackListeners=function(){var t=Se(this,(function(){this.trigger("texttrackchange")})),i=this.textTracks();i&&(i.addEventListener("removetrack",t),i.addEventListener("addtrack",t),this.on("dispose",Se(this,(function(){i.removeEventListener("removetrack",t),i.removeEventListener("addtrack",t)}))))},s.initTrackListeners=function(){var t=this;["video","audio"].forEach((function(i){var s=function(){t.trigger(i+"trackchange")},e=t[i+"Tracks"]();e.addEventListener("removetrack",s),e.addEventListener("addtrack",s),t.on("dispose",(function(){e.removeEventListener("removetrack",s),e.removeEventListener("addtrack",s)}))}))},s.ft=function(){var t=this;if(!o.WebVTT)if(Xi.body.contains(this.el())){if(!this.h["vtt.js"]&&ns(lh)&&g.keys(lh).length>0)return void this.trigger("vttjsloaded");var i=Xi.createElement("script");i.src=this.h["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.12.4/vtt.min.js",i.onload=function(){t.trigger("vttjsloaded")},i.onerror=function(){t.trigger("vttjserror")},this.on("dispose",(function(){i.onload=null,i.onerror=null})),o.WebVTT=!0,this.el().parentNode.appendChild(i)}else this.ready(this.ft)},s.emulateTextTracks=function(){var t=this,i=this.textTracks();if(i){var s=this.remoteTextTracks(),e=function(t){return i.tt(t.track)},n=function(t){return i.it(t.track)};s.on("addtrack",e),s.on("removetrack",n),this.ft();var r=function(){return t.trigger("texttrackchange")},h=function(){r();for(var t=0;t<i.length;t++){var s=i[t];s.removeEventListener("cuechange",r),"showing"===s.mode&&s.addEventListener("cuechange",r)}};h(),i.addEventListener("change",h),i.addEventListener("addtrack",h),i.addEventListener("removetrack",h),this.on("dispose",(function(){s.off("addtrack",e),s.off("removetrack",n),i.removeEventListener("change",h),i.removeEventListener("addtrack",h),i.removeEventListener("removetrack",h);for(var t=0;t<i.length;t++){i[t].removeEventListener("cuechange",r)}}))}},s.videoTracks=function(){return this.rt=this.rt||new ah,this.rt},s.audioTracks=function(){return this.ht=this.ht||new ch,this.ht},s.textTracks=function(){return this.nt=this.nt||new hh,this.nt},s.remoteTextTracks=function(){return this.dt=this.dt||new hh,this.dt},s.remoteTextTrackEls=function(){return this.vt=this.vt||new nh,this.vt},s.addTextTrack=function(t,i,s){if(!t)throw new v("TextTrack kind is required but was not provided");return function(t,i,s,e,n){void 0===n&&(n={});var r=t.textTracks();n.kind=i,s&&(n.label=s),e&&(n.language=e),n.tech=t;var h=new ih(n);return r.tt(h),h}(this,t,i,s)},s.createRemoteTextTrack=function(t){var i=Ce(t,{tech:this});return new sh(i)},s.addRemoteTextTrack=function(t,i){void 0===t&&(t={});var s=this.createRemoteTextTrack(t);return!0!==i&&!1!==i&&(hs.warn('Calling addRemoteTextTrack without explicitly setting the "manualCleanup" parameter to `true` is deprecated and default to `false` in future version of video.js'),i=!0),this.remoteTextTrackEls().J(s),this.remoteTextTracks().tt(s.track),!0!==i&&this.ot.tt(s.track),s},s.removeRemoteTextTrack=function(t){var i=this.remoteTextTrackEls().Y(t);this.remoteTextTrackEls().K(i),this.remoteTextTracks().it(t),this.ot.it(t)},s.getVideoPlaybackQuality=function(){return{}},s.setPoster=function(){},s.playsinline=function(){},s.setPlaysinline=function(){},s.canPlayType=function(){return""},i.isTech=function(t){return t.prototype instanceof i||t instanceof i||t===i},i.registerTech=function(t,s){if(i.gt||(i.gt={}),!i.isTech(s))throw new v("Tech "+t+" must be a Tech");return i.gt[t]=s,s},i.getTech=function(t){return i.gt&&i.gt[t]?i.gt[t]:o&&o.videojs&&o.videojs[t]?(hs.warn("The "+t+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),o.videojs[t]):void 0},i}(Pe);fh.prototype.nt,fh.prototype.ht,fh.prototype.rt,fh.prototype.featuresVolumeControl=!0,fh.prototype.featuresFullscreenResize=!1,fh.prototype.featuresPlaybackRate=!1,fh.prototype.featuresProgressEvents=!1,fh.prototype.featuresTimeupdateEvents=!1,fh.prototype.featuresNativeTextTracks=!1,fh.withSourceHandlers=function(t){t.registerSourceHandler=function(i,s){var e=t.sourceHandlers;e||(e=t.sourceHandlers=[]),void 0===s&&(s=e.length),e.splice(s,0,i)},t.canPlayType=function(i){for(var s,e=t.sourceHandlers||[],n=0;n<e.length;n++)if(s=e[n].canPlayType(i))return s;return""},t.selectSourceHandler=function(i,s){for(var e=t.sourceHandlers||[],n=0;n<e.length;n++)if(e[n].canHandleSource(i,s))return e[n];return null},t.canPlaySource=function(i,s){var e=t.selectSourceHandler(i,s);return e?e.canHandleSource(i,s):""};["seekable","duration"].forEach((function(t){var i=this[t];"function"==typeof i&&(this[t]=function(){return this.yt&&this.yt[t]?this.yt[t].apply(this.yt,arguments):i.apply(this,arguments)})}),t.prototype),t.prototype.setSource=function(i){var s=t.selectSourceHandler(i,this.h);return s||(t.nativeSourceHandler?s=t.nativeSourceHandler:hs.error("No source hander found for the current source.")),this.disposeSourceHandler(),this.off("dispose",this.disposeSourceHandler),s!==t.nativeSourceHandler&&(this.bt=i,this.off(this.v,"loadstart",t.prototype.wt),this.off(this.v,"loadstart",t.prototype.kt),this.one(this.v,"loadstart",t.prototype.wt)),this.yt=s.handleSource(i,this,this.h),this.on("dispose",this.disposeSourceHandler),this},t.prototype.wt=function(){this.one(this.v,"loadstart",t.prototype.kt)},t.prototype.kt=function(){this.disposeSourceHandler(),this.one(this.v,"loadstart",t.prototype.kt)},t.prototype.disposeSourceHandler=function(){this.bt&&(this.clearTracks(["audio","video"]),this.bt=null),this.cleanupAutoTextTracks(),this.yt&&(this.off(this.v,"loadstart",t.prototype.wt),this.off(this.v,"loadstart",t.prototype.kt),this.yt.dispose&&this.yt.dispose(),this.yt=null)}},Pe.registerComponent("Tech",fh),Pe.registerComponent("MediaTechController",fh),fh.registerTech("Tech",fh);var dh=function(t){function i(i,s,e){var n;if(n=t.call(this,i,s,e)||this,s.playerOptions.sources&&0!==s.playerOptions.sources.length)i.src(s.playerOptions.sources);else for(var r=0,h=s.playerOptions.techOrder;r<h.length;r++){var o=Te(h[r]),a=fh.getTech(o);if(o||(a=Pe.getComponent(o)),a&&a.isSupported()){i._t(o);break}}return n}return Ee(i,t),i}(Pe);Pe.registerComponent("MediaLoader",dh);var vh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).emitTapEvents(),e.on(i,"languagechange",e.handleLanguagechange),e.enable(),e}Ee(i,t);var s=i.prototype;return s.createEl=function(i,s,e){void 0===i&&(i="div"),void 0===s&&(s={}),void 0===e&&(e={}),s=ss({className:this.buildCSSClass(),tabIndex:0},s),"button"===i&&hs.error("Creating a ClickableComponent with an HTML element of "+i+" is not supported; use a Button instead."),e=ss({role:"button","aria-live":"polite"},e),this.jt=s.tabIndex;var n=t.prototype.createEl.call(this,i,s,e);return this.createControlTextEl(n),n},s.createControlTextEl=function(t){return this.xt=ms("span",{className:"vjs-control-text"}),t&&t.appendChild(this.xt),this.controlText(this.St,t),this.xt},s.controlText=function(t,i){if(void 0===i&&(i=this.el()),void 0===t)return this.St||"Need Text";var s=this.localize(t);return this.St=t,this.xt.innerHTML=s,this.nonIconControl||i.setAttribute("title",s),this},s.buildCSSClass=function(){return"vjs-control vjs-button "+t.prototype.buildCSSClass.call(this)},s.enable=function(){return this.removeClass("vjs-disabled"),this.v.setAttribute("aria-disabled","false"),void 0!==this.jt&&this.v.setAttribute("tabIndex",this.jt),this.off(["tap","click"],this.handleClick),this.off("focus",this.handleFocus),this.off("blur",this.handleBlur),this.on(["tap","click"],this.handleClick),this.on("focus",this.handleFocus),this.on("blur",this.handleBlur),this},s.disable=function(){return this.addClass("vjs-disabled"),this.v.setAttribute("aria-disabled","true"),void 0!==this.jt&&this.v.removeAttribute("tabIndex"),this.off(["tap","click"],this.handleClick),this.off("focus",this.handleFocus),this.off("blur",this.handleBlur),this},s.handleLanguagechange=function(){this.controlText(this.St)},s.handleClick=function(t){},s.handleFocus=function(t){pe(Xi,"keydown",Se(this,this.handleKeyPress))},s.handleKeyPress=function(i){32===i.which||13===i.which?(i.preventDefault(),this.handleClick(i)):t.prototype.handleKeyPress&&t.prototype.handleKeyPress.call(this,i)},s.handleBlur=function(t){me(Xi,"keydown",Se(this,this.handleKeyPress))},i}(Pe);Pe.registerComponent("ClickableComponent",vh);var ph=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).update(),i.on("posterchange",Se(Me(e),e.update)),e}Ee(i,t);var s=i.prototype;return s.dispose=function(){this.player().off("posterchange",this.update),t.prototype.dispose.call(this)},s.createEl=function(){var t=ms("div",{className:"vjs-poster",tabIndex:-1});return ae||(this.Tt=ms("img"),t.appendChild(this.Tt)),t},s.update=function(t){var i=this.player().poster();this.setSrc(i),i?this.show():this.hide()},s.setSrc=function(t){if(this.Tt)this.Tt.src=t;else{var i="";t&&(i='url("'+t+'")'),this.v.style.backgroundImage=i}},s.handleClick=function(t){this.t.controls()&&(this.t.paused()?this.t.play():this.t.pause())},i}(vh);Pe.registerComponent("PosterImage",ph);var mh="#222",gh={monospace:"monospace",sansSerif:"sans-serif",serif:"serif",monospaceSansSerif:'"Andale Mono", "Lucida Console", monospace',monospaceSerif:'"Courier New", monospace',proportionalSansSerif:"sans-serif",proportionalSerif:"serif",casual:'"Comic Sans MS", Impact, fantasy',script:'"Monotype Corsiva", cursive',smallcaps:'"Andale Mono", "Lucida Console", monospace, sans-serif'};function yh(t,i){return"rgba("+k(t[1]+t[1],16)+","+k(t[2]+t[2],16)+","+k(t[3]+t[3],16)+","+i+")"}function bh(t,i,s){try{t.style[i]=s}catch(t){return}}var wh=function(t){function i(i,s,e){var n;return n=t.call(this,i,s,e)||this,i.on("loadstart",Se(Me(n),n.toggleDisplay)),i.on("texttrackchange",Se(Me(n),n.updateDisplay)),i.ready(Se(Me(n),(function(){if(i.H&&i.H.featuresNativeTextTracks)this.hide();else{i.on("fullscreenchange",Se(this,this.updateDisplay));for(var t=this.h.playerOptions.tracks||[],s=0;s<t.length;s++)this.t.addRemoteTextTrack(t[s],!0);var e,n,r={captions:1,subtitles:1},h=this.t.textTracks();if(h){for(var o=0;o<h.length;o++){var a=h[o];a.default&&("descriptions"!==a.kind||e?a.kind in r&&!n&&(n=a):e=a)}n?n.mode="showing":e&&(e.mode="showing")}}}))),n}Ee(i,t);var s=i.prototype;return s.toggleDisplay=function(){this.t.H&&this.t.H.featuresNativeTextTracks?this.hide():this.show()},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-text-track-display"},{"aria-live":"off","aria-atomic":"true"})},s.clearDisplay=function(){"function"==typeof o.WebVTT&&o.WebVTT.processCues(o,[],this.v)},s.updateDisplay=function(){var t=this.t.textTracks();if(this.clearDisplay(),t){for(var i=null,s=null,e=t.length;e--;){var n=t[e];"showing"===n.mode&&("descriptions"===n.kind?i=n:s=n)}s?("off"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","off"),this.updateForTrack(s)):i&&("assertive"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","assertive"),this.updateForTrack(i))}},s.updateForTrack=function(t){if("function"==typeof o.WebVTT&&t.activeCues){for(var i=this.t.textTrackSettings.getValues(),s=[],e=0;e<t.activeCues.length;e++)s.push(t.activeCues[e]);o.WebVTT.processCues(o,s,this.v);for(var n=s.length;n--;){var r=s[n];if(r){var h=r.displayState;if(i.color&&(h.firstChild.style.color=i.color),i.textOpacity&&bh(h.firstChild,"color",yh(i.color||"#fff",i.textOpacity)),i.backgroundColor&&(h.firstChild.style.backgroundColor=i.backgroundColor),i.backgroundOpacity&&bh(h.firstChild,"backgroundColor",yh(i.backgroundColor||"#000",i.backgroundOpacity)),i.windowColor&&(i.windowOpacity?bh(h,"backgroundColor",yh(i.windowColor,i.windowOpacity)):h.style.backgroundColor=i.windowColor),i.edgeStyle&&("dropshadow"===i.edgeStyle?h.firstChild.style.textShadow="2px 2px 3px #222, 2px 2px 4px #222, 2px 2px 5px "+mh:"raised"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #222, 2px 2px #222, 3px 3px "+mh:"depressed"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #ccc, 0 1px #ccc, -1px -1px #222, 0 -1px "+mh:"uniform"===i.edgeStyle&&(h.firstChild.style.textShadow="0 0 4px #222, 0 0 4px #222, 0 0 4px #222, 0 0 4px "+mh)),i.fontPercent&&1!==i.fontPercent){var a=o.parseFloat(h.style.fontSize);h.style.fontSize=a*i.fontPercent+"px",h.style.height="auto",h.style.top="auto",h.style.bottom="2px"}i.fontFamily&&"default"!==i.fontFamily&&("small-caps"===i.fontFamily?h.firstChild.style.fontVariant="small-caps":h.firstChild.style.fontFamily=gh[i.fontFamily])}}}},i}(Pe);Pe.registerComponent("TextTrackDisplay",wh);var kh=function(t){function i(){return t.apply(this,arguments)||this}return Ee(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"})},i}(Pe);Pe.registerComponent("LoadingSpinner",kh);var _h=function(t){function i(){return t.apply(this,arguments)||this}Ee(i,t);var s=i.prototype;return s.createEl=function(t,i,s){void 0===t&&(t="button"),void 0===i&&(i={}),void 0===s&&(s={}),i=ss({className:this.buildCSSClass()},i),"button"!==t&&(hs.warn("Creating a Button with an HTML element of "+t+" is deprecated; use ClickableComponent instead."),i=ss({tabIndex:0},i),s=ss({role:"button"},s)),s=ss({type:"button","aria-live":"polite"},s);var e=Pe.prototype.createEl.call(this,t,i,s);return this.createControlTextEl(e),e},s.addChild=function(t,i){void 0===i&&(i={});var s=this.constructor.name;return hs.warn("Adding an actionable (user controllable) child to a Button ("+s+") is not supported; use a ClickableComponent instead."),Pe.prototype.addChild.call(this,t,i)},s.enable=function(){t.prototype.enable.call(this),this.v.removeAttribute("disabled")},s.disable=function(){t.prototype.disable.call(this),this.v.setAttribute("disabled","disabled")},s.handleKeyPress=function(i){32!==i.which&&13!==i.which&&t.prototype.handleKeyPress.call(this,i)},i}(vh);Pe.registerComponent("Button",_h);var jh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Ct=!1,e.on("mousedown",e.handleMouseDown),e}Ee(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-big-play-button"},s.handleClick=function(t){var i=this.t.play();if(!(this.Ct&&t.clientX&&t.clientY)){var s=this.t.getChild("controlBar"),e=s&&s.getChild("playToggle");if(e){var n=function(){return e.focus()};if(i&&i.then){i.then(n,(function(){}))}else this.setTimeout(n,1)}else this.t.focus()}},s.handleKeyPress=function(i){this.Ct=!1,t.prototype.handleKeyPress.call(this,i)},s.handleMouseDown=function(t){this.Ct=!0},i}(_h);jh.prototype.St="Play Video",Pe.registerComponent("BigPlayButton",jh);var xh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).controlText(s&&s.controlText||"Close"),e}Ee(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-close-button "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.trigger({type:"close",bubbles:!1})},i}(_h);Pe.registerComponent("CloseButton",xh);var Sh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"play",e.handlePlay),e.on(i,"pause",e.handlePause),e}Ee(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-play-control "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.t.paused()?this.t.play():this.t.pause()},s.handlePlay=function(t){this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.controlText("Pause")},s.handlePause=function(t){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.controlText("Play")},i}(_h);function Th(t,i){void 0===i&&(i=t),t=t<0?0:t;var s=w.floor(t%60),e=w.floor(t/60%60),n=w.floor(t/3600),r=w.floor(i/60%60),h=w.floor(i/3600);return(j(t)||t===1/0)&&(n=e=s="-"),(n=n>0||h>0?n+":":"")+(e=((n||r>=10)&&e<10?"0"+e:e)+":")+(s=s<10?"0"+s:s)}Sh.prototype.St="Play",Pe.registerComponent("PlayToggle",Sh);var Ch=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"timeupdate",e.updateContent),e.on(i,"languagechange",e.updateContent),e}Ee(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-current-time vjs-time-control vjs-control"});return this.S=ms("div",{className:"vjs-current-time-display",innerHTML:'<span class="vjs-control-text">Current Time </span>0:00'},{"aria-live":"off"}),i.appendChild(this.S),i},s.updateContent=function(t){var i=this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime(),s=this.localize("Current Time"),e=Th(i,this.t.duration());e!==this.Pt&&(this.Pt=e,this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e)},i}(Pe);Pe.registerComponent("CurrentTimeDisplay",Ch);var Ph=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"durationchange",e.updateContent),e.on(i,"timeupdate",e.updateContent),e.on(i,"loadedmetadata",e.updateContent),e.on(i,"languagechange",e.updateContent),e}Ee(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-duration vjs-time-control vjs-control"});return this.S=ms("div",{className:"vjs-duration-display",innerHTML:'<span class="vjs-control-text">'+this.localize("Duration Time")+"</span> 0:00"},{"aria-live":"off"}),i.appendChild(this.S),i},s.updateContent=function(t){var i=this.t.duration();if(i&&this.ct!==i){this.ct=i;var s=this.localize("Duration Time"),e=Th(i);this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e}},i}(Pe);Pe.registerComponent("DurationDisplay",Ph);var Ah=function(t){function i(){return t.apply(this,arguments)||this}return Ee(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-time-control vjs-time-divider",innerHTML:"<div><span>/</span></div>"})},i}(Pe);Pe.registerComponent("TimeDivider",Ah);var Mh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"timeupdate",e.updateContent),e.on(i,"durationchange",e.updateContent),e.on(i,"languagechange",e.updateContent),e}Ee(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-remaining-time vjs-time-control vjs-control"});return this.S=ms("div",{className:"vjs-remaining-time-display",innerHTML:'<span class="vjs-control-text">'+this.localize("Remaining Time")+"</span> -0:00"},{"aria-live":"off"}),i.appendChild(this.S),i},s.updateContent=function(t){if(this.t.duration()){var i=this.localize("Remaining Time"),s=Th(this.t.remainingTime());s!==this.Pt&&(this.Pt=s,this.S.innerHTML='<span class="vjs-control-text">'+i+"</span> -"+s)}},i}(Pe);Pe.registerComponent("RemainingTimeDisplay",Mh);var Ih=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).updateShowing(),e.on(e.player(),"durationchange",e.updateShowing),e.on(e.player(),"languagechange",e.handleLanguagechange),e}Ee(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-live-control vjs-control"});return this.S=ms("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.xt=ms("span",{className:"vjs-control-text",innerHTML:this.localize("Stream Type")}),this.At=Xi.createTextNode(this.localize("LIVE")),this.S.appendChild(this.xt),this.S.appendChild(this.At),i.appendChild(this.S),i},s.updateShowing=function(t){this.player().duration()===1/0?this.show():this.hide()},s.handleLanguagechange=function(){this.xt.innerHTML=this.localize("Stream Type"),this.At.innerHTML=this.localize("LIVE")},i}(Pe);Pe.registerComponent("LiveDisplay",Ih);var Eh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).bar=e.getChild(e.h.barName),e.vertical(!!e.h.vertical),e.on("mousedown",e.handleMouseDown),e.on("touchstart",e.handleMouseDown),e.on("focus",e.handleFocus),e.on("blur",e.handleBlur),e.on("click",e.handleClick),e.on(i,"controlsvisible",e.update),e.on(i,e.playerEvent,e.update),e}Ee(i,t);var s=i.prototype;return s.createEl=function(i,s,e){return void 0===s&&(s={}),void 0===e&&(e={}),s.className=s.className+" vjs-slider",s=ss({tabIndex:0},s),e=ss({role:"slider","aria-valuenow":0,"aria-valuemin":0,"aria-valuemax":100,tabIndex:0},e),t.prototype.createEl.call(this,i,s,e)},s.handleMouseDown=function(t){var i=this.bar.v.ownerDocument;t.preventDefault(),Xi.body.focus(),Xi.onselectstart=function(){return!1},this.addClass("vjs-sliding"),this.trigger("slideractive"),this.on(i,"mousemove",this.handleMouseMove),this.on(i,"mouseup",this.handleMouseUp),this.on(i,"touchmove",this.handleMouseMove),this.on(i,"touchend",this.handleMouseUp),this.handleMouseMove(t)},s.handleMouseMove=function(t){},s.handleMouseUp=function(){var t=this.bar.v.ownerDocument;Xi.onselectstart=function(){return!0},this.removeClass("vjs-sliding"),this.trigger("sliderinactive"),this.off(t,"mousemove",this.handleMouseMove),this.off(t,"mouseup",this.handleMouseUp),this.off(t,"touchmove",this.handleMouseMove),this.off(t,"touchend",this.handleMouseUp),this.update()},s.update=function(){if(this.v){var t=this.getPercent(),i=this.bar;if(i){("number"!=typeof t||t!=t||t<0||t===1/0)&&(t=0);var s=(100*t).toFixed(2)+"%";this.vertical()?i.el().style.height=s:i.el().style.width=s}}},s.calculateDistance=function(t){var i=Ds(this.v,t);return this.vertical()?i.y:i.x},s.handleFocus=function(){this.on(this.bar.v.ownerDocument,"keydown",this.handleKeyPress)},s.handleKeyPress=function(t){37===t.which||40===t.which?(t.preventDefault(),this.stepBack()):38!==t.which&&39!==t.which||(t.preventDefault(),this.stepForward())},s.handleBlur=function(){this.off(this.bar.v.ownerDocument,"keydown",this.handleKeyPress)},s.handleClick=function(t){t.stopImmediatePropagation(),t.preventDefault()},s.vertical=function(t){return void 0===t?this.Mt||!1:(this.Mt=!!t,this.Mt?this.addClass("vjs-slider-vertical"):this.addClass("vjs-slider-horizontal"),this)},i}(Pe);function Dh(t,i){if(!t||!i)return"";if("function"==typeof o.getComputedStyle){var s=o.getComputedStyle(t);return s?s[i]:""}return t.currentStyle[i]||""}Pe.registerComponent("Slider",Eh);var Nh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).It=[],e.on(i,"progress",e.update),e.on(i,"languagechange",e.handleLanguagechange),e}Ee(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-load-progress"});return this.Et=ms("span",{innerHTML:this.localize("Loaded")}),this.Dt=Xi.createTextNode(": 0%"),this.xt=ms("span",{className:"vjs-control-text"}),this.xt.appendChild(this.Et),this.xt.appendChild(this.Dt),i.appendChild(this.xt),i},s.update=function(t){var i=this.t.buffered(),s=this.t.duration(),e=this.t.bufferedEnd(),n=this.It,r=function(t,i){var s=t/i||0;return 100*(s>=1?1:s)+"%"};this.v.style.width=r(e,s);for(var h=0;h<i.length;h++){var o=i.start(h),a=i.end(h),u=n[h];u||(u=this.v.appendChild(ms()),n[h]=u),u.style.left=r(o,e),u.style.width=r(a-o,e)}for(var c=n.length;c>i.length;c--)this.v.removeChild(n[c-1]);n.length=i.length},s.handleLanguagechange=function(){this.Et.innerHTML=this.localize("Loaded")},i}(Pe);Pe.registerComponent("LoadProgressBar",Nh);var Fh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).updateDataAttr(),e.on(i,"timeupdate",e.updateDataAttr),e.on(i,"languagechange",e.handleLanguagechange),i.ready(Se(Me(e),e.updateDataAttr)),s.playerOptions&&s.playerOptions.controlBar&&s.playerOptions.controlBar.progressControl&&s.playerOptions.controlBar.progressControl.keepTooltipsInside&&(e.keepTooltipsInside=s.playerOptions.controlBar.progressControl.keepTooltipsInside),e.keepTooltipsInside&&e.addClass("vjs-keep-tooltips-inside"),e}Ee(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-play-progress vjs-slider-bar"});return this.Nt=ms("span",{innerHTML:this.localize("Progress")}),this.Ft=Xi.createTextNode(": 0%"),this.xt=ms("span",{className:"vjs-control-text"}),this.xt.appendChild(this.Nt),this.xt.appendChild(this.Ft),i.appendChild(this.xt),i},s.updateDataAttr=function(t){var i=this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime();this.v.setAttribute("data-current-time",Th(i,this.t.duration()))},s.handleLanguagechange=function(){this.Nt.innerHTML=this.localize("Progress")},i}(Pe);Pe.registerComponent("PlayProgressBar",Fh);var $h=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).updateDataAttr(),e.on(i,"timeupdate",e.updateDataAttr),e.on(i,"languagechange",e.handleLanguagechange),i.ready(Se(Me(e),e.updateDataAttr)),e}Ee(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-tooltip-progress-bar vjs-slider-bar"});return this.tooltip=ms("div",{className:"vjs-time-tooltip"}),this.Nt=ms("span",{innerHTML:this.localize("Progress")}),this.Ft=Xi.createTextNode(": 0%"),this.xt=ms("span",{className:"vjs-control-text"}),this.xt.appendChild(this.Nt),this.xt.appendChild(this.Ft),i.appendChild(this.tooltip),i.appendChild(this.xt),i},s.updateDataAttr=function(t){var i=Th(this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime(),this.t.duration());this.v.setAttribute("data-current-time",i),this.tooltip.innerHTML=i},s.handleLanguagechange=function(){this.Nt.innerHTML=this.localize("Progress")},i}(Pe);Pe.registerComponent("TooltipProgressBar",$h);var Bh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"timeupdate",e.updateProgress),e.on(i,"ended",e.updateProgress),i.ready(Se(Me(e),e.updateProgress)),s.playerOptions&&s.playerOptions.controlBar&&s.playerOptions.controlBar.progressControl&&s.playerOptions.controlBar.progressControl.keepTooltipsInside&&(e.keepTooltipsInside=s.playerOptions.controlBar.progressControl.keepTooltipsInside),e.keepTooltipsInside&&(e.tooltipProgressBar=e.addChild("TooltipProgressBar")),e}Ee(i,t);var s=i.prototype;return s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-holder"},{"aria-label":"progress bar"})},s.updateProgress=function(t){if(this.updateAriaAttributes(this.v),this.keepTooltipsInside){this.updateAriaAttributes(this.tooltipProgressBar.v),this.tooltipProgressBar.v.style.width=this.bar.v.style.width;var i=_(Dh(this.player().el(),"width")),s=_(Dh(this.tooltipProgressBar.tooltip,"width")),e=this.tooltipProgressBar.el().style;e.maxWidth=w.floor(i-s/2)+"px",e.minWidth=w.ceil(s/2)+"px",e.right="-"+s/2+"px"}},s.updateAriaAttributes=function(t){var i=this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime();t.setAttribute("aria-valuenow",(100*this.getPercent()).toFixed(2)),t.setAttribute("aria-valuetext",Th(i,this.t.duration()))},s.getPercent=function(){var t=this.t.currentTime()/this.t.duration();return t>=1?1:t},s.handleMouseDown=function(i){this.t.scrubbing(!0),this.videoWasPlaying=!this.t.paused(),this.t.pause(),t.prototype.handleMouseDown.call(this,i)},s.handleMouseMove=function(t){var i=this.calculateDistance(t)*this.t.duration();i===this.t.duration()&&(i-=.1),this.t.currentTime(i)},s.handleMouseUp=function(i){t.prototype.handleMouseUp.call(this,i),this.t.scrubbing(!1),this.videoWasPlaying&&this.t.play()},s.stepForward=function(){this.t.currentTime(this.t.currentTime()+5)},s.stepBack=function(){this.t.currentTime(this.t.currentTime()-5)},i}(Eh);Bh.prototype.h={children:["loadProgressBar","mouseTimeDisplay","playProgressBar"],barName:"playProgressBar"},Bh.prototype.playerEvent="timeupdate",Pe.registerComponent("SeekBar",Bh);var Rh=function(t){function i(i,s){var e;return e=t.call(this,i,s)||this,s.playerOptions&&s.playerOptions.controlBar&&s.playerOptions.controlBar.progressControl&&s.playerOptions.controlBar.progressControl.keepTooltipsInside&&(e.keepTooltipsInside=s.playerOptions.controlBar.progressControl.keepTooltipsInside),e.keepTooltipsInside&&(e.tooltip=ms("div",{className:"vjs-time-tooltip"}),e.el().appendChild(e.tooltip),e.addClass("vjs-keep-tooltips-inside")),e.update(0,0),i.on("ready",(function(){e.on(i.controlBar.progressControl.el(),"mousemove",function(t,i){var s=Date.now();return function(){var e=Date.now();e-s>=i&&(t.apply(void 0,arguments),s=e)}}(Se(Me(e),e.handleMouseMove),25))})),e}Ee(i,t);var s=i.prototype;return s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-mouse-display"})},s.handleMouseMove=function(t){var i=this.t.duration(),s=this.calculateDistance(t)*i,e=t.pageX-Es(this.el().parentNode).left;this.update(s,e)},s.update=function(t,i){var s=Th(t,this.t.duration());if(this.el().style.left=i+"px",this.el().setAttribute("data-current-time",s),this.keepTooltipsInside){var e=i-this.$t(i)+1,n=_(Dh(this.tooltip,"width"))/2;this.tooltip.innerHTML=s,this.tooltip.style.right="-"+(n-e)+"px"}},s.calculateDistance=function(t){return Ds(this.el().parentNode,t).x},s.$t=function(t){if(!this.keepTooltipsInside)return t;var i=_(Dh(this.player().el(),"width")),s=_(Dh(this.tooltip,"width"))/2,e=t;return t<s?e=w.ceil(s):t>i-s&&(e=w.floor(i-s)),e},i}(Pe);Pe.registerComponent("MouseTimeDisplay",Rh);var Oh=function(t){function i(){return t.apply(this,arguments)||this}return Ee(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},i}(Pe);Oh.prototype.h={children:["seekBar"]},Pe.registerComponent("ProgressControl",Oh);var Vh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"fullscreenchange",e.handleFullscreenChange),e}Ee(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-fullscreen-control "+t.prototype.buildCSSClass.call(this)},s.handleFullscreenChange=function(t){this.t.isFullscreen()?this.controlText("Non-Fullscreen"):this.controlText("Fullscreen")},s.handleClick=function(t){this.t.isFullscreen()?this.t.exitFullscreen():this.t.requestFullscreen()},i}(_h);Vh.prototype.St="Fullscreen",Pe.registerComponent("FullscreenToggle",Vh);var Lh=function(t){function i(){return t.apply(this,arguments)||this}return Ee(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-level",innerHTML:'<span class="vjs-control-text"></span>'})},i}(Pe);Pe.registerComponent("VolumeLevel",Lh);var Uh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.updateARIAAttributes),i.ready(Se(Me(e),e.updateARIAAttributes)),e}Ee(i,t);var s=i.prototype;return s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-bar vjs-slider-bar"},{"aria-label":"volume level"})},s.handleMouseMove=function(t){this.checkMuted(),this.t.volume(this.calculateDistance(t))},s.checkMuted=function(){this.t.muted()&&this.t.muted(!1)},s.getPercent=function(){return this.t.muted()?0:this.t.volume()},s.stepForward=function(){this.checkMuted(),this.t.volume(this.t.volume()+.1)},s.stepBack=function(){this.checkMuted(),this.t.volume(this.t.volume()-.1)},s.updateARIAAttributes=function(t){var i=(100*this.t.volume()).toFixed(2);this.v.setAttribute("aria-valuenow",i),this.v.setAttribute("aria-valuetext",i+"%")},i}(Eh);Uh.prototype.h={children:["volumeLevel"],barName:"volumeLevel"},Uh.prototype.playerEvent="volumechange",Pe.registerComponent("VolumeBar",Uh);var Hh=function(t){function i(i,s){var e;return e=t.call(this,i,s)||this,i.H&&!1===i.H.featuresVolumeControl&&e.addClass("vjs-hidden"),e.on(i,"loadstart",(function(){!1===i.H.featuresVolumeControl?this.addClass("vjs-hidden"):this.removeClass("vjs-hidden")})),e}return Ee(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control"})},i}(Pe);Hh.prototype.h={children:["volumeBar"]},Pe.registerComponent("VolumeControl",Hh);var zh=function(t){function i(){return t.apply(this,arguments)||this}Ee(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",Se(this,(function(){this.unlockShowing()})))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=ms(i,{className:"vjs-menu-content"});var s=t.prototype.createEl.call(this,"div",{append:this.S,className:"vjs-menu"});return s.appendChild(this.S),pe(s,"click",(function(t){t.preventDefault(),t.stopImmediatePropagation()})),s},i}(Pe);Pe.registerComponent("Popup",zh);var Wh=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e}Ee(i,t);var s=i.prototype;return s.update=function(){var t=this.createPopup();this.popup&&this.removeChild(this.popup),this.popup=t,this.addChild(t),this.items&&0===this.items.length?this.hide():this.items&&this.items.length>1&&this.show()},s.createPopup=function(){},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass()})},s.buildCSSClass=function(){var i="vjs-menu-button";return!0===this.h.inline?i+="-inline":i+="-popup","vjs-menu-button "+i+" "+t.prototype.buildCSSClass.call(this)},i}(vh);Pe.registerComponent("PopupButton",Wh);var qh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.update),i.H&&!1===i.H.featuresVolumeControl&&e.addClass("vjs-hidden"),e.on(i,"loadstart",(function(){this.update(),!1===i.H.featuresVolumeControl?this.addClass("vjs-hidden"):this.removeClass("vjs-hidden")})),e}Ee(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-mute-control "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.t.muted(!this.t.muted())},s.update=function(t){var i=this.t.volume(),s=3;this.t.muted()?s=0:i<.33?s=1:i<.67&&(s=2);var e=this.t.muted()?"Unmute":"Mute";this.controlText()!==e&&this.controlText(e);for(var n=0;n<4;n++)Ts(this.v,"vjs-vol-"+n);Ss(this.v,"vjs-vol-"+s)},i}(_h);qh.prototype.St="Mute",Pe.registerComponent("MuteToggle",qh);var Gh=function(t){function i(i,s){var e;function n(){i.H&&!1===i.H.featuresVolumeControl?this.addClass("vjs-hidden"):this.removeClass("vjs-hidden")}return void 0===s&&(s={}),void 0===s.inline&&(s.inline=!0),void 0===s.vertical&&(s.inline?s.vertical=!1:s.vertical=!0),s.volumeBar=s.volumeBar||{},s.volumeBar.vertical=!!s.vertical,(e=t.call(this,i,s)||this).on(i,"volumechange",e.volumeUpdate),e.on(i,"loadstart",e.volumeUpdate),n.call(Me(e)),e.on(i,"loadstart",n),e.on(e.volumeBar,["slideractive","focus"],(function(){this.addClass("vjs-slider-active")})),e.on(e.volumeBar,["sliderinactive","blur"],(function(){this.removeClass("vjs-slider-active")})),e.on(e.volumeBar,["focus"],(function(){this.addClass("vjs-lock-showing")})),e.on(e.volumeBar,["blur"],(function(){this.removeClass("vjs-lock-showing")})),e}Ee(i,t);var s=i.prototype;return s.buildCSSClass=function(){var i="";return i=this.h.vertical?"vjs-volume-menu-button-vertical":"vjs-volume-menu-button-horizontal","vjs-volume-menu-button "+t.prototype.buildCSSClass.call(this)+" "+i},s.createPopup=function(){var t=new zh(this.t,{contentElType:"div"}),i=new Uh(this.t,this.h.volumeBar);return t.addChild(i),this.menuContent=t,this.volumeBar=i,this.attachVolumeBarEvents(),t},s.handleClick=function(i){qh.prototype.handleClick.call(this),t.prototype.handleClick.call(this)},s.attachVolumeBarEvents=function(){this.menuContent.on(["mousedown","touchdown"],Se(this,this.handleMouseDown))},s.handleMouseDown=function(t){this.on(["mousemove","touchmove"],Se(this.volumeBar,this.volumeBar.handleMouseMove)),this.on(this.v.ownerDocument,["mouseup","touchend"],this.handleMouseUp)},s.handleMouseUp=function(t){this.off(["mousemove","touchmove"],Se(this.volumeBar,this.volumeBar.handleMouseMove))},i}(Wh);Gh.prototype.volumeUpdate=qh.prototype.update,Gh.prototype.St="Mute",Pe.registerComponent("VolumeMenuButton",Gh);var Xh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Bt=-1,e.on("keydown",e.handleKeyPress),e}Ee(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",Se(this,(function(t){this.unlockShowing()})))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=ms(i,{className:"vjs-menu-content"}),this.S.setAttribute("role","menu");var s=t.prototype.createEl.call(this,"div",{append:this.S,className:"vjs-menu"});return s.setAttribute("role","presentation"),s.appendChild(this.S),pe(s,"click",(function(t){t.preventDefault(),t.stopImmediatePropagation()})),s},s.handleKeyPress=function(t){37===t.which||40===t.which?(t.preventDefault(),this.stepForward()):38!==t.which&&39!==t.which||(t.preventDefault(),this.stepBack())},s.stepForward=function(){var t=0;void 0!==this.Bt&&(t=this.Bt+1),this.focus(t)},s.stepBack=function(){var t=0;void 0!==this.Bt&&(t=this.Bt-1),this.focus(t)},s.focus=function(t){void 0===t&&(t=0);var i=this.children().slice();i.length&&i[0].className&&/vjs-menu-title/.test(i[0].className)&&i.shift(),i.length>0&&(t<0?t=0:t>=i.length&&(t=i.length-1),this.Bt=t,i[t].v.focus())},i}(Pe);Pe.registerComponent("Menu",Xh);var Jh=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e.Rt=!0,e.v.setAttribute("aria-haspopup","true"),e.v.setAttribute("role","menuitem"),e.on("keydown",e.handleSubmenuKeyPress),e}Ee(i,t);var s=i.prototype;return s.update=function(){var t=this.createMenu();this.menu&&this.removeChild(this.menu),this.menu=t,this.addChild(t),this.Ot=!1,this.v.setAttribute("aria-expanded","false"),this.items&&this.items.length<=this.Vt?this.hide():this.show()},s.createMenu=function(){var t=new Xh(this.t);if(this.Vt=0,this.h.title){var i=ms("li",{className:"vjs-menu-title",innerHTML:Te(this.h.title),tabIndex:-1});this.Vt+=1,t.m.unshift(i),ys(i,t.contentEl())}if(this.items=this.createItems(),this.items)for(var s=0;s<this.items.length;s++)t.addItem(this.items[s]);return t},s.createItems=function(){},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass()})},s.buildCSSClass=function(){var i="vjs-menu-button";return!0===this.h.inline?i+="-inline":i+="-popup","vjs-menu-button "+i+" "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.one(this.menu.contentEl(),"mouseleave",Se(this,(function(t){this.unpressButton(),this.v.blur()}))),this.Ot?this.unpressButton():this.pressButton()},s.handleKeyPress=function(i){27===i.which||9===i.which?(this.Ot&&this.unpressButton(),9!==i.which&&i.preventDefault()):38===i.which||40===i.which?this.Ot||(this.pressButton(),i.preventDefault()):t.prototype.handleKeyPress.call(this,i)},s.handleSubmenuKeyPress=function(t){27!==t.which&&9!==t.which||(this.Ot&&this.unpressButton(),9!==t.which&&t.preventDefault())},s.pressButton=function(){this.Rt&&(this.Ot=!0,this.menu.lockShowing(),this.v.setAttribute("aria-expanded","true"),this.menu.focus())},s.unpressButton=function(){this.Rt&&(this.Ot=!1,this.menu.unlockShowing(),this.v.setAttribute("aria-expanded","false"),this.v.focus())},s.disable=function(){return this.Ot=!1,this.menu.unlockShowing(),this.v.setAttribute("aria-expanded","false"),this.Rt=!1,t.prototype.disable.call(this)},s.enable=function(){return this.Rt=!0,t.prototype.enable.call(this)},i}(vh);Pe.registerComponent("MenuButton",Jh);var Qh=function(t){function i(i,s){var e,n=s.tracks;if((e=t.call(this,i,s)||this).items.length<=1&&e.hide(),!n)return Me(e);var r=Se(Me(e),e.update);return n.addEventListener("removetrack",r),n.addEventListener("addtrack",r),e.t.on("dispose",(function(){n.removeEventListener("removetrack",r),n.removeEventListener("addtrack",r)})),e}return Ee(i,t),i}(Jh);Pe.registerComponent("TrackButton",Qh);var Yh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).selectable=s.selectable,e.selected(s.selected),e.selectable?e.v.setAttribute("role","menuitemcheckbox"):e.v.setAttribute("role","menuitem"),e}Ee(i,t);var s=i.prototype;return s.createEl=function(i,s,e){this.nonIconControl=!0;var n=t.prototype.createEl.call(this,"li",ss({className:"vjs-menu-item",tabIndex:-1},s),e);return this.Lt=Xi.createTextNode(this.localize(this.h.label)),n.appendChild(this.Lt),n},s.handleClick=function(t){this.selected(!0)},s.selected=function(t){this.selectable&&(t?(this.addClass("vjs-selected"),this.v.setAttribute("aria-checked","true"),this.controlText(", selected")):(this.removeClass("vjs-selected"),this.v.setAttribute("aria-checked","false"),this.controlText("")))},s.handleLanguagechange=function(){t.prototype.handleLanguagechange.call(this),this.Lt.innerHTML=this.localize(this.h.label)},i}(vh);Pe.registerComponent("MenuItem",Yh);var Kh=function(t){function i(i,s){var e,n,r=s.track,h=i.textTracks();if(s.label=r.label||r.language||"Unknown",s.selected=r.default||"showing"===r.mode,(e=t.call(this,i,s)||this).track=r,h){var a=Se(Me(e),e.handleTracksChange);i.on(["loadstart","texttrackchange"],a),h.addEventListener("change",a),e.on("dispose",(function(){h.removeEventListener("change",a)}))}h&&void 0===h.onchange&&e.on(["tap","click"],(function(){if("object"!=typeof o.Event)try{n=new o.Event("change")}catch(t){}n||(n=Xi.createEvent("Event")).initEvent("change",!0,!0),h.dispatchEvent(n)}));return e}Ee(i,t);var s=i.prototype;return s.handleClick=function(i){var s=this.track.kind,e=this.t.textTracks();if(t.prototype.handleClick.call(this,i),e)for(var n=0;n<e.length;n++){var r=e[n];r.kind===s&&(r===this.track?"showing"!==r.mode&&(r.mode="showing"):"disabled"!==r.mode&&(r.mode="disabled"))}},s.handleTracksChange=function(t){this.selected("showing"===this.track.mode)},i}(Yh);Pe.registerComponent("TextTrackMenuItem",Kh);var Zh=function(t){function i(i,s){var e;return s.track={player:i,kind:s.kind,label:s.kind+" off",default:!1,mode:"disabled"},s.selectable=!0,(e=t.call(this,i,s)||this).selected(!0),e}return Ee(i,t),i.prototype.handleTracksChange=function(t){for(var i=this.player().textTracks(),s=!0,e=0,n=i.length;e<n;e++){var r=i[e];if(r.kind===this.track.kind&&"showing"===r.mode){s=!1;break}}this.selected(s)},i}(Kh);Pe.registerComponent("OffTextTrackMenuItem",Zh);var to=function(t){function i(i,s){return void 0===s&&(s={}),s.tracks=i.textTracks(),t.call(this,i,s)||this}return Ee(i,t),i.prototype.createItems=function(t){void 0===t&&(t=[]),t.push(new Zh(this.t,{kind:this.Ut})),this.Vt+=1;var i=this.t.textTracks();if(!i)return t;for(var s=0;s<i.length;s++){var e=i[s];e.kind===this.Ut&&t.push(new Kh(this.t,{track:e,selectable:!0}))}return t},i}(Qh);Pe.registerComponent("TextTrackButton",to);var io=function(t){function i(i,s){var e,n=s.track,r=s.cue,h=i.currentTime();return s.selectable=!0,s.label=r.text,s.selected=r.startTime<=h&&h<r.endTime,(e=t.call(this,i,s)||this).track=n,e.cue=r,n.addEventListener("cuechange",Se(Me(e),e.update)),e}Ee(i,t);var s=i.prototype;return s.handleClick=function(i){t.prototype.handleClick.call(this),this.t.currentTime(this.cue.startTime),this.update(this.cue.startTime)},s.update=function(t){var i=this.cue,s=this.t.currentTime();this.selected(i.startTime<=s&&s<i.endTime)},i}(Yh);Pe.registerComponent("ChaptersTrackMenuItem",io);var so=function(t){function i(i,s,e){var n;return(n=t.call(this,i,s,e)||this).v.setAttribute("aria-label","Chapters Menu"),n}Ee(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-chapters-button "+t.prototype.buildCSSClass.call(this)},s.update=function(i){this.Ht&&(!i||"addtrack"!==i.type&&"removetrack"!==i.type)||this.setTrack(this.findChaptersTrack()),t.prototype.update.call(this)},s.setTrack=function(t){if(this.Ht!==t){if(this.zt||(this.zt=this.update.bind(this)),this.Ht){var i=this.t.remoteTextTrackEls().Y(this.Ht);i&&i.removeEventListener("load",this.zt),this.Ht=null}if(this.Ht=t,this.Ht){this.Ht.mode="hidden";var s=this.t.remoteTextTrackEls().Y(this.Ht);s&&s.addEventListener("load",this.zt)}}},s.findChaptersTrack=function(){for(var t=this.t.textTracks()||[],i=t.length-1;i>=0;i--){var s=t[i];if(s.kind===this.Ut)return s}},s.getMenuCaption=function(){return this.Ht&&this.Ht.label?this.Ht.label:this.localize(Te(this.Ut))},s.createMenu=function(){return this.h.title=this.getMenuCaption(),t.prototype.createMenu.call(this)},s.createItems=function(){var t=[];if(!this.Ht)return t;var i=this.Ht.cues;if(!i)return t;for(var s=0,e=i.length;s<e;s++){var n=i[s],r=new io(this.t,{track:this.Ht,cue:n});t.push(r)}return t},i}(to);so.prototype.Ut="chapters",so.prototype.St="Chapters",Pe.registerComponent("ChaptersButton",so);var eo=function(t){function i(i,s,e){var n;(n=t.call(this,i,s,e)||this).v.setAttribute("aria-label","Descriptions Menu");var r=i.textTracks();if(r){var h=Se(Me(n),n.handleTracksChange);r.addEventListener("change",h),n.on("dispose",(function(){r.removeEventListener("change",h)}))}return n}Ee(i,t);var s=i.prototype;return s.handleTracksChange=function(t){for(var i=this.player().textTracks(),s=!1,e=0,n=i.length;e<n;e++){var r=i[e];if(r.kind!==this.Ut&&"showing"===r.mode){s=!0;break}}s?this.disable():this.enable()},s.buildCSSClass=function(){return"vjs-descriptions-button "+t.prototype.buildCSSClass.call(this)},i}(to);eo.prototype.Ut="descriptions",eo.prototype.St="Descriptions",Pe.registerComponent("DescriptionsButton",eo);var no=function(t){function i(i,s,e){var n;return(n=t.call(this,i,s,e)||this).v.setAttribute("aria-label","Subtitles Menu"),n}return Ee(i,t),i.prototype.buildCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildCSSClass.call(this)},i}(to);no.prototype.Ut="subtitles",no.prototype.St="Subtitles",Pe.registerComponent("SubtitlesButton",no);var ro=function(t){function i(i,s){var e;return s.track={player:i,kind:s.kind,label:s.kind+" settings",selectable:!1,default:!1,mode:"disabled"},s.selectable=!1,(e=t.call(this,i,s)||this).addClass("vjs-texttrack-settings"),e.controlText(", opens "+s.kind+" settings dialog"),e}return Ee(i,t),i.prototype.handleClick=function(t){this.player().getChild("textTrackSettings").show(),this.player().getChild("textTrackSettings").v.focus()},i}(Kh);Pe.registerComponent("CaptionSettingsMenuItem",ro);var ho=function(t){function i(i,s,e){var n;return(n=t.call(this,i,s,e)||this).v.setAttribute("aria-label","Captions Menu"),n}Ee(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-captions-button "+t.prototype.buildCSSClass.call(this)},s.createItems=function(){var i=[];return this.player().H&&this.player().H.featuresNativeTextTracks||(i.push(new ro(this.t,{kind:this.Ut})),this.Vt+=1),t.prototype.createItems.call(this,i)},i}(to);ho.prototype.Ut="captions",ho.prototype.St="Captions",Pe.registerComponent("CaptionsButton",ho);var oo=function(t){function i(i,s){var e,n=s.track,r=i.audioTracks();if(s.label=n.label||n.language||"Unknown",s.selected=n.enabled,(e=t.call(this,i,s)||this).track=n,r){var h=Se(Me(e),e.handleTracksChange);r.addEventListener("change",h),e.on("dispose",(function(){r.removeEventListener("change",h)}))}return e}Ee(i,t);var s=i.prototype;return s.handleClick=function(i){var s=this.t.audioTracks();if(t.prototype.handleClick.call(this,i),s)for(var e=0;e<s.length;e++){var n=s[e];n.enabled=n===this.track}},s.handleTracksChange=function(t){this.selected(this.track.enabled)},i}(Yh);Pe.registerComponent("AudioTrackMenuItem",oo);var ao=function(t){function i(i,s){var e;return void 0===s&&(s={}),s.tracks=i.audioTracks&&i.audioTracks(),(e=t.call(this,i,s)||this).v.setAttribute("aria-label","Audio Menu"),e}Ee(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-audio-button "+t.prototype.buildCSSClass.call(this)},s.createItems=function(t){void 0===t&&(t=[]),this.Vt=1;var i=this.t.audioTracks&&this.t.audioTracks();if(!i)return t;for(var s=0;s<i.length;s++){var e=i[s];t.push(new oo(this.t,{track:e,selectable:!0}))}return t},i}(Qh);ao.prototype.St="Audio Track",Pe.registerComponent("AudioTrackButton",ao);var uo=function(t){function i(i,s){var e,n=s.rate,r=_(n,10);return s.label=n,s.selected=1===r,s.selectable=!0,(e=t.call(this,i,s)||this).label=n,e.rate=r,e.on(i,"ratechange",e.update),e}Ee(i,t);var s=i.prototype;return s.handleClick=function(i){t.prototype.handleClick.call(this),this.player().playbackRate(this.rate)},s.update=function(t){this.selected(this.player().playbackRate()===this.rate)},i}(Yh);uo.prototype.contentElType="button",Pe.registerComponent("PlaybackRateMenuItem",uo);var co=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).updateVisibility(),e.updateLabel(),e.on(i,"loadstart",e.updateVisibility),e.on(i,"ratechange",e.updateLabel),e}Ee(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this);return this.Lt=ms("div",{className:"vjs-playback-rate-value",innerHTML:1}),i.appendChild(this.Lt),i},s.buildCSSClass=function(){return"vjs-playback-rate "+t.prototype.buildCSSClass.call(this)},s.createMenu=function(){var t=new Xh(this.player()),i=this.playbackRates();if(i)for(var s=i.length-1;s>=0;s--)t.addChild(new uo(this.player(),{rate:i[s]+"x"}));return t},s.updateARIAAttributes=function(){this.el().setAttribute("aria-valuenow",this.player().playbackRate())},s.handleClick=function(t){for(var i=this.player().playbackRate(),s=this.playbackRates(),e=s[0],n=0;n<s.length;n++)if(s[n]>i){e=s[n];break}this.player().playbackRate(e)},s.playbackRates=function(){return this.h.playbackRates||this.h.playerOptions&&this.h.playerOptions.playbackRates},s.playbackRateSupported=function(){return this.player().H&&this.player().H.featuresPlaybackRate&&this.playbackRates()&&this.playbackRates().length>0},s.updateVisibility=function(t){this.playbackRateSupported()?this.removeClass("vjs-hidden"):this.addClass("vjs-hidden")},s.updateLabel=function(t){this.playbackRateSupported()&&(this.Lt.innerHTML=this.player().playbackRate()+"x")},i}(Jh);co.prototype.St="Playback Rate",Pe.registerComponent("PlaybackRateMenuButton",co);var lo=function(t){function i(){return t.apply(this,arguments)||this}Ee(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-spacer "+t.prototype.buildCSSClass.call(this)},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass()})},i}(Pe);Pe.registerComponent("Spacer",lo);var fo=function(t){function i(){return t.apply(this,arguments)||this}Ee(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-custom-control-spacer "+t.prototype.buildCSSClass.call(this)},s.createEl=function(){var i=t.prototype.createEl.call(this,{className:this.buildCSSClass()});return i.innerHTML=" ",i},i}(lo);Pe.registerComponent("CustomControlSpacer",fo);var vo=function(t){function i(){return t.apply(this,arguments)||this}return Ee(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"},{role:"group"})},i}(Pe);vo.prototype.h={children:["playToggle","volumeMenuButton","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subtitlesButton","captionsButton","audioTrackButton","fullscreenToggle"]},Pe.registerComponent("ControlBar",vo);var po=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"error",e.open),e}Ee(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-error-display "+t.prototype.buildCSSClass.call(this)},s.content=function(){var t=this.player().error();return t?this.localize(t.message):""},i}(Qe);po.prototype.h=Ce(Qe.prototype.h,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),Pe.registerComponent("ErrorDisplay",po);var mo="vjs-text-track-settings",go=["#000","Black"],yo=["#00F","Blue"],bo=["#0FF","Cyan"],wo=["#0F0","Green"],ko=["#F0F","Magenta"],_o=["#F00","Red"],jo=["#FFF","White"],xo=["#FF0","Yellow"],So=["1","Opaque"],To=["0.5","Semi-Transparent"],Co=["0","Transparent"],Po={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[go,jo,_o,wo,yo,xo,ko,bo]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[So,To,Co]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[jo,go,_o,wo,yo,xo,ko,bo]},edgeStyle:{selector:".vjs-edge-style > select",id:"%s",label:"Text Edge Style",options:[["none","None"],["raised","Raised"],["depressed","Depressed"],["uniform","Uniform"],["dropshadow","Dropshadow"]]},fontFamily:{selector:".vjs-font-family > select",id:"captions-font-family-%s",label:"Font Family",options:[["proportionalSansSerif","Proportional Sans-Serif"],["monospaceSansSerif","Monospace Sans-Serif"],["proportionalSerif","Proportional Serif"],["monospaceSerif","Monospace Serif"],["casual","Casual"],["script","Script"],["small-caps","Small Caps"]]},fontPercent:{selector:".vjs-font-percent > select",id:"captions-font-size-%s",label:"Font Size",options:[["0.50","50%"],["0.75","75%"],["1.00","100%"],["1.25","125%"],["1.50","150%"],["1.75","175%"],["2.00","200%"],["3.00","300%"],["4.00","400%"]],default:2,parser:function(t){return"1.00"===t?null:Number(t)}},textOpacity:{selector:".vjs-text-opacity > select",id:"captions-foreground-opacity-%s",label:"Transparency",options:[So,To]},windowColor:{selector:".vjs-window-color > select",id:"captions-window-color-%s",label:"Color"},windowOpacity:{selector:".vjs-window-opacity > select",id:"captions-window-opacity-%s",label:"Transparency",options:[Co,To,So]}};function Ao(t,i){if(i&&(t=i(t)),t&&"none"!==t)return t}Po.windowColor.options=Po.backgroundColor.options;var Mo,Io=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).setDefaults(),e.hide(),e.updateDisplay=Se(Me(e),e.updateDisplay),void 0===s.persistTextTrackSettings&&(e.h.persistTextTrackSettings=e.h.playerOptions.persistTextTrackSettings),e.on(e.$(".vjs-done-button"),"click",(function(){e.saveSettings(),e.hide()})),e.on(e.$(".vjs-default-button"),"click",(function(){e.setDefaults(),e.updateDisplay()})),is(Po,(function(t){e.on(e.$(t.selector),"change",e.updateDisplay)})),e.h.persistTextTrackSettings&&e.restoreSettings(),e}Ee(i,t);var s=i.prototype;return s.Wt=function(t){var i=this,s=Po[t],e=s.id.replace("%s",this.o);return[ms("label",{className:"vjs-label",textContent:s.label},{for:e}),ms("select",{id:e},void 0,s.options.map((function(t){return ms("option",{textContent:i.localize(t[1]),value:t[0]})})))]},s.qt=function(){var t=ms("legend",{textContent:this.localize("Text")}),i=this.Wt("color"),s=ms("span",{className:"vjs-text-opacity vjs-opacity"},void 0,this.Wt("textOpacity"));return ms("fieldset",{className:"vjs-fg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Gt=function(){var t=ms("legend",{textContent:this.localize("Background")}),i=this.Wt("backgroundColor"),s=ms("span",{className:"vjs-bg-opacity vjs-opacity"},void 0,this.Wt("backgroundOpacity"));return ms("fieldset",{className:"vjs-bg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Xt=function(){var t=ms("legend",{textContent:this.localize("Window")}),i=this.Wt("windowColor"),s=ms("span",{className:"vjs-window-opacity vjs-opacity"},void 0,this.Wt("windowOpacity"));return ms("fieldset",{className:"vjs-window-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Jt=function(){return ms("div",{className:"vjs-tracksettings-colors"},void 0,[this.qt(),this.Gt(),this.Xt()])},s.Qt=function(){var t=ms("div",{className:"vjs-font-percent vjs-tracksetting"},void 0,this.Wt("fontPercent")),i=ms("div",{className:"vjs-edge-style vjs-tracksetting"},void 0,this.Wt("edgeStyle")),s=ms("div",{className:"vjs-font-family vjs-tracksetting"},void 0,this.Wt("fontFamily"));return ms("div",{className:"vjs-tracksettings-font"},void 0,[t,i,s])},s.Yt=function(){var t=ms("button",{className:"vjs-default-button",textContent:this.localize("Defaults")}),i=ms("button",{className:"vjs-done-button",textContent:"Done"});return ms("div",{className:"vjs-tracksettings-controls"},void 0,[t,i])},s.createEl=function(){var t=ms("div",{className:"vjs-tracksettings"},void 0,[this.Jt(),this.Qt(),this.Yt()]),i=ms("div",{className:"vjs-control-text",id:"TTsettingsDialogLabel-"+this.o,textContent:"Caption Settings Dialog"},{"aria-level":"1",role:"heading"}),s=ms("div",{className:"vjs-control-text",id:"TTsettingsDialogDescription-"+this.o,textContent:"Beginning of dialog window. Escape will cancel and close the window."}),e=ms("div",void 0,{role:"document"},[i,s,t]);return ms("div",{className:"vjs-caption-settings vjs-modal-overlay",tabIndex:-1},{role:"dialog","aria-labelledby":i.id,"aria-describedby":s.id},e)},s.getValues=function(){var t=this;return function(t,i,s){return void 0===s&&(s=0),ts(t).reduce((function(s,e){return i(s,t[e],e)}),s)}(Po,(function(i,s,e){var n=function(t,i){return Ao(t.options[t.options.selectedIndex].value,i)}(t.$(s.selector),s.parser);return void 0!==n&&(i[e]=n),i}),{})},s.setValues=function(t){var i=this;is(Po,(function(s,e){!function(t,i,s){if(i)for(var e=0;e<t.options.length;e++)if(Ao(t.options[e].value,s)===i){t.selectedIndex=e;break}}(i.$(s.selector),t[e],s.parser)}))},s.setDefaults=function(){var t=this;is(Po,(function(i){var s=i.hasOwnProperty("default")?i.default:0;t.$(i.selector).selectedIndex=s}))},s.restoreSettings=function(){var t;try{t=JSON.parse(o.localStorage.getItem(mo))}catch(t){hs.warn(t)}t&&this.setValues(t)},s.saveSettings=function(){if(this.h.persistTextTrackSettings){var t=this.getValues();try{g.keys(t).length?o.localStorage.setItem(mo,JSON.stringify(t)):o.localStorage.removeItem(mo)}catch(t){hs.warn(t)}}},s.updateDisplay=function(){var t=this.t.getChild("textTrackDisplay");t&&t.updateDisplay()},i}(Pe);Pe.registerComponent("TextTrackSettings",Io);var Eo,Do=function(t){function i(i,s){var e;e=t.call(this,i,s)||this;var n=i.source,r=!1;if(n&&(e.v.currentSrc!==n.src||i.tag&&3===i.tag.Kt)?e.setSource(n):e.Zt(e.v),e.v.hasChildNodes()){for(var h=e.v.childNodes,o=h.length,a=[];o--;){var u=h[o];"track"===u.nodeName.toLowerCase()&&(e.featuresNativeTextTracks?(e.remoteTextTrackEls().J(u),e.remoteTextTracks().tt(u.track),r||e.v.hasAttribute("crossorigin")||!rn(u.src)||(r=!0)):a.push(u))}for(var c=0;c<a.length;c++)e.v.removeChild(a[c])}return["audio","video"].forEach((function(t){var i=e.el()[t+"Tracks"],s=e[t+"Tracks"](),n=Te(t);e["featuresNative"+n+"Tracks"]&&i&&i.addEventListener&&(e["handle"+n+"ti"]=function(t){s.trigger({type:"change",target:s,currentTarget:s,srcElement:s})},e["handle"+n+"ii"]=function(t){return s.addTrack(t.track)},e["handle"+n+"si"]=function(t){return s.removeTrack(t.track)},i.addEventListener("change",e["handle"+n+"ti"]),i.addEventListener("addtrack",e["handle"+n+"ii"]),i.addEventListener("removetrack",e["handle"+n+"si"]),e["removeOld"+n+"ei"]=function(t){return e.ni(s,i)},e.on("loadstart",e["removeOld"+n+"ei"]))})),e.featuresNativeTextTracks&&(r&&hs.warn(cs(Mo||(Mo=Ji(["Text Tracks are being loaded from another origin but the crossorigin attribute isn't used.\n This may prevent text tracks from loading."])))),e.ri=Se(Me(e),e.handleTextTrackChange),e.hi=Se(Me(e),e.handleTextTrackAdd),e.oi=Se(Me(e),e.handleTextTrackRemove),e.ai()),e.ci(),(oe||Ws||Ks)&&!0===i.nativeControlsForTouch&&e.setControls(!0),e.fi(),e.triggerReady(),e}Ee(i,t);var s=i.prototype;return s.dispose=function(){var s=this;["audio","video","text"].forEach((function(t){var i=Te(t),e=s.v[t+"Tracks"];e&&e.removeEventListener&&(e.removeEventListener("change",s["handle"+i+"ti"]),e.removeEventListener("addtrack",s["handle"+i+"ii"]),e.removeEventListener("removetrack",s["handle"+i+"si"])),e&&s.off("loadstart",s["removeOld"+i+"ei"])})),i.disposeMediaElement(this.v),t.prototype.dispose.call(this)},s.ci=function(){var t,i=this.textTracks(),s=function(){t=[];for(var s=0;s<i.length;s++){var e=i[s];"metadata"===e.kind&&t.push({track:e,storedMode:e.mode})}};s(),i.addEventListener("change",s);var e=function s(){for(var e=0;e<t.length;e++){var n=t[e];"disabled"===n.track.mode&&n.track.mode!==n.storedMode&&(n.track.mode=n.storedMode)}i.removeEventListener("change",s)};this.on("webkitbeginfullscreen",(function(){i.removeEventListener("change",s),i.removeEventListener("change",e),i.addEventListener("change",e)})),this.on("webkitendfullscreen",(function(){i.removeEventListener("change",s),i.addEventListener("change",s),i.removeEventListener("change",e)}))},s.createEl=function(){var t=this.h.tag;if(!t||!this.h.playerElIngest&&!this.movingMediaElementInDOM){if(t){var s=t.cloneNode(!0);t.parentNode&&t.parentNode.insertBefore(s,t),i.disposeMediaElement(t),t=s}else{t=Xi.createElement("video");var e=Ce({},this.h.tag&&As(this.h.tag));oe&&!0===this.h.nativeControlsForTouch||delete e.controls,Ps(t,ss(e,{id:this.h.techId,class:"vjs-tech"}))}t.playerId=this.h.playerId}void 0!==this.h.preload&&Ms(t,"preload",this.h.preload);for(var n=["loop","muted","playsinline","autoplay"],r=n.length-1;r>=0;r--){var h=n[r],o=this.h[h];void 0!==o&&(o?Ms(t,h,h):Is(t,h),t[h]=o)}return t},s.Zt=function(t){if(0!==t.networkState&&3!==t.networkState){if(0===t.readyState){var i=!1,s=function(){i=!0};this.on("loadstart",s);var e=function(){i||this.trigger("loadstart")};return this.on("loadedmetadata",e),void this.ready((function(){this.off("loadstart",s),this.off("loadedmetadata",e),i||this.trigger("loadstart")}))}var n=["loadstart"];n.push("loadedmetadata"),t.readyState>=2&&n.push("loadeddata"),t.readyState>=3&&n.push("canplay"),t.readyState>=4&&n.push("canplaythrough"),this.ready((function(){n.forEach((function(t){this.trigger(t)}),this)}))}},s.ai=function(){var t=this.el().textTracks;if(t){for(var i=0;i<t.length;i++)this.textTracks().tt(t[i]);t.addEventListener&&(t.addEventListener("change",this.ri),t.addEventListener("addtrack",this.hi),t.addEventListener("removetrack",this.oi)),this.on("loadstart",this.di)}},s.handleTextTrackChange=function(t){var i=this.textTracks();this.textTracks().trigger({type:"change",target:i,currentTarget:i,srcElement:i})},s.handleTextTrackAdd=function(t){this.textTracks().tt(t.track)},s.handleTextTrackRemove=function(t){this.textTracks().it(t.track)},s.ni=function(t,i){var s=[];if(i){for(var e=0;e<t.length;e++){for(var n=t[e],r=!1,h=0;h<i.length;h++)if(i[h]===n){r=!0;break}r||s.push(n)}for(var o=0;o<s.length;o++){var a=s[o];t.it(a)}}},s.di=function(t){var i=this.textTracks(),s=this.el().textTracks;this.ni(i,s)},s.play=function(){var t=this.v.play();void 0!==t&&"function"==typeof t.then&&t.then(null,(function(t){}))},s.setCurrentTime=function(t){try{this.v.currentTime=t}catch(t){hs(t,"Video is not ready. (Video.js)")}},s.duration=function(){var t=this;if(this.v.duration===1/0&&Js&&ie&&0===this.v.currentTime){return this.on("timeupdate",(function i(){t.v.currentTime>0&&(t.v.duration===1/0&&t.trigger("durationchange"),t.off("timeupdate",i))})),NaN}return this.v.duration||NaN},s.width=function(){return this.v.offsetWidth},s.height=function(){return this.v.offsetHeight},s.fi=function(){var t=this;if("webkitDisplayingFullscreen"in this.v){var i=function(){this.trigger("fullscreenchange",{isFullscreen:!1})},s=function(){"webkitPresentationMode"in this.v&&"picture-in-picture"!==this.v.webkitPresentationMode&&(this.one("webkitendfullscreen",i),this.trigger("fullscreenchange",{isFullscreen:!0,nativeIOSFullscreen:!0}))};this.on("webkitbeginfullscreen",s),this.on("dispose",(function(){t.off("webkitbeginfullscreen",s),t.off("webkitendfullscreen",i)}))}},s.supportsFullScreen=function(){if("function"==typeof this.v.webkitEnterFullScreen){var t=o.navigator&&o.navigator.userAgent||"";if(/Android/.test(t)||!/Chrome|Mac OS X 10.5/.test(t))return!0}return!1},s.enterFullScreen=function(){var t=this.v;t.paused&&t.networkState<=t.HAVE_METADATA?(this.v.play(),this.setTimeout((function(){t.pause(),t.webkitEnterFullScreen()}),0)):t.webkitEnterFullScreen()},s.exitFullScreen=function(){this.v.webkitExitFullScreen()},s.src=function(t){if(void 0===t)return this.v.src;this.setSrc(t)},s.reset=function(){i.resetMediaElement(this.v)},s.currentSrc=function(){return this.bt?this.bt.src:this.v.currentSrc},s.setControls=function(t){this.v.controls=!!t},s.addTextTrack=function(i,s,e){return this.featuresNativeTextTracks?this.v.addTextTrack(i,s,e):t.prototype.addTextTrack.call(this,i,s,e)},s.createRemoteTextTrack=function(i){if(!this.featuresNativeTextTracks)return t.prototype.createRemoteTextTrack.call(this,i);var s=Xi.createElement("track");return i.kind&&(s.kind=i.kind),i.label&&(s.label=i.label),(i.language||i.srclang)&&(s.srclang=i.language||i.srclang),i.default&&(s.default=i.default),i.id&&(s.id=i.id),i.src&&(s.src=i.src),s},s.addRemoteTextTrack=function(i,s){var e=t.prototype.addRemoteTextTrack.call(this,i,s);return this.featuresNativeTextTracks&&this.el().appendChild(e),e},s.removeRemoteTextTrack=function(i){if(t.prototype.removeRemoteTextTrack.call(this,i),this.featuresNativeTextTracks)for(var s=this.$$("track"),e=s.length;e--;)i!==s[e]&&i!==s[e].track||this.el().removeChild(s[e])},s.getVideoPlaybackQuality=function(){if("function"==typeof this.el().getVideoPlaybackQuality)return this.el().getVideoPlaybackQuality();var t={};return void 0!==this.el().webkitDroppedFrameCount&&void 0!==this.el().webkitDecodedFrameCount&&(t.droppedVideoFrames=this.el().webkitDroppedFrameCount,t.totalVideoFrames=this.el().webkitDecodedFrameCount),o.performance&&"function"==typeof o.performance.now?t.creationTime=o.performance.now():o.performance&&o.performance.timing&&"number"==typeof o.performance.timing.navigationStart&&(t.creationTime=o.Date.now()-o.performance.timing.navigationStart),t},i}(fh);ds()&&(Do.TEST_VID=Xi.createElement("video"),(Eo=Xi.createElement("track")).kind="captions",Eo.srclang="en",Eo.label="English",Do.TEST_VID.appendChild(Eo)),Do.isSupported=function(){try{Do.TEST_VID.volume=.5}catch(t){return!1}return!(!Do.TEST_VID||!Do.TEST_VID.canPlayType)},Do.canControlVolume=function(){try{var t=Do.TEST_VID.volume;return Do.TEST_VID.volume=t/2+.1,t!==Do.TEST_VID.volume}catch(t){return!1}},Do.canControlPlaybackRate=function(){if(Js&&ie&&se<58)return!1;try{var t=Do.TEST_VID.playbackRate;return Do.TEST_VID.playbackRate=t/2+.1,t!==Do.TEST_VID.playbackRate}catch(t){return!1}},Do.supportsNativeTextTracks=function(){return he},Do.supportsNativeVideoTracks=function(){return!(!Do.TEST_VID||!Do.TEST_VID.videoTracks)},Do.supportsNativeAudioTracks=function(){return!(!Do.TEST_VID||!Do.TEST_VID.audioTracks)},Do.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange"],Do.prototype.featuresVolumeControl=Do.canControlVolume(),Do.prototype.featuresPlaybackRate=Do.canControlPlaybackRate(),Do.prototype.movingMediaElementInDOM=!Gs,Do.prototype.featuresFullscreenResize=!0,Do.prototype.featuresProgressEvents=!0,Do.prototype.featuresTimeupdateEvents=!0,Do.prototype.featuresNativeTextTracks=Do.supportsNativeTextTracks(),Do.prototype.featuresNativeVideoTracks=Do.supportsNativeVideoTracks(),Do.prototype.featuresNativeAudioTracks=Do.supportsNativeAudioTracks();var No=Do.TEST_VID&&Do.TEST_VID.constructor.prototype.canPlayType,Fo=/^application\/(?:x-|vnd\.apple\.)mpegurl/i,$o=/^video\/mp4/i;Do.patchCanPlayType=function(){Qs>=4&&!Zs?Do.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&Fo.test(t)?"maybe":No.call(this,t)}:Ys&&(Do.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&$o.test(t)?"maybe":No.call(this,t)})},Do.unpatchCanPlayType=function(){var t=Do.TEST_VID.constructor.prototype.canPlayType;return Do.TEST_VID.constructor.prototype.canPlayType=No,t},Do.patchCanPlayType(),Do.disposeMediaElement=function(t){if(t){var i=t.nodeName.toLowerCase();if("video"===i||"audio"===i){for(t.parentNode&&t.parentNode.removeChild(t);t.hasChildNodes();)t.removeChild(t.firstChild);t.removeAttribute("src"),"function"==typeof t.load&&function(){try{t.load()}catch(t){}}()}}},Do.resetMediaElement=function(t){if(t){for(var i=t.querySelectorAll("source"),s=i.length;s--;)t.removeChild(i[s]);t.removeAttribute("src"),"function"==typeof t.load&&function(){try{t.load()}catch(t){}}()}},["muted","defaultMuted","autoplay","controls","loop","playsinline"].forEach((function(t){Do.prototype[t]=function(){return this.v[t]||this.v.hasAttribute(t)}})),["muted","defaultMuted","autoplay","loop","playsinline"].forEach((function(t){Do.prototype["set"+Te(t)]=function(i){this.v[t]=i,i?this.v.setAttribute(t,t):this.v.removeAttribute(t)}})),["paused","currentTime","buffered","volume","poster","preload","error","seeking","seekable","ended","playbackRate","played","networkState","readyState","videoWidth","videoHeight"].forEach((function(t){Do.prototype[t]=function(){return this.v[t]}})),["volume","src","poster","preload","playbackRate"].forEach((function(t){Do.prototype["set"+Te(t)]=function(i){this.v[t]=i}})),["pause","load"].forEach((function(t){Do.prototype[t]=function(){return this.v[t]()}})),fh.withSourceHandlers(Do),Do.nativeSourceHandler={},Do.nativeSourceHandler.canPlayType=function(t){try{return Do.TEST_VID.canPlayType(t)}catch(t){return""}},Do.nativeSourceHandler.canHandleSource=function(t,i){if(t.type)return Do.nativeSourceHandler.canPlayType(t.type);if(t.src){var s=function(t){if("string"==typeof t){var i=/^(\/?)([\s\S]*?)((?:\.{1,2}|[^\/]+?)(\.([^\.\/\?]+)))(?:[\/]*|[\?].*)$/i.exec(t);if(i)return i.pop().toLowerCase()}return""}(t.src);return Do.nativeSourceHandler.canPlayType("video/"+s)}return""},Do.nativeSourceHandler.handleSource=function(t,i,s){i.setSrc(t.src)},Do.nativeSourceHandler.dispose=function(){},Do.registerSourceHandler(Do.nativeSourceHandler),Pe.registerComponent("Html5",Do),fh.registerTech("Html5",Do);var Bo=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","ratechange","volumechange","texttrackchange"],Ro=function(t){function i(s,e,n){var r;if(s.id=s.id||["vjs_video",Yi()].join("_"),(e=ss(i.getTagSettings(s),e)).initChildren=!1,e.createEl=!1,e.reportTouchActivity=!1,!e.language)if("function"==typeof s.closest){var h=s.closest("[lang]");h&&(e.language=h.getAttribute("lang"))}else for(var o=s;o&&1===o.nodeType;){if(As(o).hasOwnProperty("lang")){e.language=o.getAttribute("lang");break}o=o.parentNode}if(!(r=t.call(this,null,e,n)||this).h||!r.h.techOrder||!r.h.techOrder.length)throw new v("No techOrder specified. Did you overwrite videojs.options instead of just changing the properties you want to override?");if(r.tag=s,r.tagAttributes=s&&As(s),r.language(r.h.language),e.languages){var a={};g.getOwnPropertyNames(e.languages).forEach((function(t){a[t.toLowerCase()]=e.languages[t]})),r.vi=a}else r.vi=i.prototype.h.languages;r.pi={},r.mi=e.poster||"",r.gi=!!e.controls,s.controls=!1,r.yi=!1,r.v=r.createEl();var u=Ce(r.h);if(e.plugins){var c=e.plugins;g.getOwnPropertyNames(c).forEach((function(t){"function"==typeof this[t]?this[t](c[t]):hs.error("Unable to find plugin:",t)}),Me(r))}r.h.playerOptions=u,r.initChildren(),r.isAudio("audio"===s.nodeName.toLowerCase()),r.controls()?r.addClass("vjs-controls-enabled"):r.addClass("vjs-controls-disabled"),r.v.setAttribute("role","region"),r.isAudio()?r.v.setAttribute("aria-label","audio player"):r.v.setAttribute("aria-label","video player"),r.isAudio()&&r.addClass("vjs-audio"),r.bi()&&r.addClass("vjs-no-flex"),Gs||r.addClass("vjs-workinghover"),i.players[r.o]=Me(r);var l="5.20.6-opentelly.12".split(".")[0];return r.addClass("vjs-v"+l),r.userActive(!0),r.reportUserActivity(),r.wi(),r.on("fullscreenchange",r.ki),r.on("stageclick",r._i),r}Ee(i,t);var s=i.prototype;return s.dispose=function(){this.trigger("dispose"),this.off("dispose"),this.ji&&this.ji.parentNode&&this.ji.parentNode.removeChild(this.ji),i.players[this.o]=null,this.tag&&this.tag.player&&(this.tag.player=null),this.v&&this.v.player&&(this.v.player=null),this.H&&this.H.dispose(),t.prototype.dispose.call(this)},s.createEl=function(){var i,s=this.tag,e=this.xi=s.parentNode&&s.parentNode.hasAttribute&&s.parentNode.hasAttribute("data-vjs-player");i=this.v=e?s.parentNode:t.prototype.createEl.call(this,"div"),s.setAttribute("tabindex","-1"),s.removeAttribute("width"),s.removeAttribute("height");var n=As(s);if(g.getOwnPropertyNames(n).forEach((function(t){"class"===t?i.className+=" "+n[t]:i.setAttribute(t,n[t])})),s.playerId=s.id,s.id+="Si",s.className="vjs-tech",s.player=i.player=this,this.addClass("vjs-paused"),!0!==o.VIDEOJS_NO_DYNAMIC_STYLE){this.ji=je("vjs-styles-dimensions");var r=Os(".vjs-styles-defaults"),h=Os("head");h.insertBefore(this.ji,r?r.nextSibling:h.firstChild)}this.width(this.h.width),this.height(this.h.height),this.fluid(this.h.fluid),this.aspectRatio(this.h.aspectRatio);for(var a=s.getElementsByTagName("a"),u=0;u<a.length;u++){var c=a.item(u);Ss(c,"vjs-hidden"),c.setAttribute("hidden","hidden")}return s.Kt=s.networkState,s.parentNode&&!e&&s.parentNode.insertBefore(i,s),ys(s,i),this.m.unshift(s),this.v=i,i},s.width=function(t){return this.dimension("width",t)},s.height=function(t){return this.dimension("height",t)},s.dimension=function(t,i){var s="width"===t?"Ti":"Ci";if(void 0===i)return this[s]||0;if(""===i)this[s]=void 0;else{var e=_(i);if(j(e))return hs.error('Improper value "'+i+'" supplied for for '+t),this;this[s]=e}return this.Pi(),this},s.fluid=function(t){if(void 0===t)return!!this.Ai;this.Ai=!!t,t?this.addClass("vjs-fluid"):this.removeClass("vjs-fluid"),this.Pi()},s.aspectRatio=function(t){if(void 0===t)return this.Mi;if(!/^\d+\:\d+$/.test(t))throw new v("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.Mi=t,this.fluid(!0),this.Pi()},s.Pi=function(){if(!0!==o.VIDEOJS_NO_DYNAMIC_STYLE){var t,i,s,e=(void 0!==this.Mi&&"auto"!==this.Mi?this.Mi:this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9").split(":"),n=e[1]/e[0];t=void 0!==this.Ti?this.Ti:void 0!==this.Ci?this.Ci/n:this.videoWidth()||300,i=void 0!==this.Ci?this.Ci:t*n,s=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(s),xe(this.ji,"\n ."+s+" {\n width: "+t+"px;\n height: "+i+"px;\n }\n\n ."+s+".vjs-fluid {\n padding-top: "+100*n+"%;\n }\n ")}else{var r="number"==typeof this.Ti?this.Ti:this.h.width,h="number"==typeof this.Ci?this.Ci:this.h.height,a=this.H&&this.H.el();a&&(r>=0&&(a.width=r),h>=0&&(a.height=h))}},s._t=function(t,i){var s=this;this.H&&this.Ii(),"Html5"!==t&&this.tag&&(fh.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.Ei=t,this.T=!1;var e=ss({source:i,nativeControlsForTouch:this.h.nativeControlsForTouch,playerId:this.id(),techId:this.id()+"_"+t+"Di",videoTracks:this.rt,textTracks:this.nt,audioTracks:this.ht,autoplay:this.h.autoplay,playsinline:this.h.playsinline,preload:this.h.preload,loop:this.h.loop,muted:this.h.muted,poster:this.poster(),language:this.language(),playerElIngest:this.xi||!1,"vtt.js":this.h["vtt.js"]},this.h[t.toLowerCase()]);this.tag&&(e.tag=this.tag),i&&(this.Ni=i.type,i.src===this.pi.src&&this.pi.currentTime>0&&(e.startTime=this.pi.currentTime),this.pi.sources=null,this.pi.source=i,this.pi.src=i.src);var n=fh.getTech(t);n||(n=Pe.getComponent(t)),this.H=new n(e),this.H.ready(Se(this,this.Fi),!0),Xe(this.$i||[],this.H),Bo.forEach((function(t){s.on(s.H,t,s["handleTech"+Te(t)+"_"])})),this.on(this.H,"loadstart",this.Bi),this.on(this.H,"waiting",this.Ri),this.on(this.H,"canplay",this.Oi),this.on(this.H,"canplaythrough",this.Vi),this.on(this.H,"playing",this.Li),this.on(this.H,"ended",this.Ui),this.on(this.H,"seeking",this.Hi),this.on(this.H,"seeked",this.zi),this.on(this.H,"play",this.Wi),this.on(this.H,"firstplay",this.qi),this.on(this.H,"pause",this.Gi),this.on(this.H,"durationchange",this.Xi),this.on(this.H,"fullscreenchange",this.Ji),this.on(this.H,"error",this.Qi),this.on(this.H,"loadedmetadata",this.Pi),this.on(this.H,"resize",this.Pi),this.on(this.H,"posterchange",this.Yi),this.on(this.H,"textdata",this.Ki),this.usingNativeControls(this.Zi("controls")),this.controls()&&!this.usingNativeControls()&&this.ts(),this.H.el().parentNode===this.contentEl()||"Html5"===t&&this.tag||ys(this.H.el(),this.contentEl()),this.tag&&(this.tag.player=null,this.tag=null)},s.Ii=function(){this.rt=this.videoTracks(),this.nt=this.textTracks(),this.ht=this.audioTracks(),this.$i=Ge(this.H),this.T=!1,this.H.dispose(),this.H=!1},s.tech=function(t){if(t&&t.IWillNotUseThisInPlugins)return this.H;var i="\n Please make sure that you are not using this inside of a plugin.\n To disable this alert and error, please pass in an object with\n `IWillNotUseThisInPlugins` to the `tech` method. See\n https://github.com/videojs/video.js/issues/2617 for more info.\n ";throw o.alert(i),new v(i)},s.ts=function(){this.ss(),this.on(this.H,"mousedown",this.es),this.on(this.H,"touchstart",this.ns),this.on(this.H,"touchmove",this.rs),this.on(this.H,"touchend",this.hs),this.on(this.H,"tap",this.os)},s.ss=function(){this.off(this.H,"tap",this.os),this.off(this.H,"touchstart",this.ns),this.off(this.H,"touchmove",this.rs),this.off(this.H,"touchend",this.hs),this.off(this.H,"mousedown",this.es)},s.Fi=function(){if(this.triggerReady(),this.pi.volume&&this.us("setVolume",this.pi.volume),this.Yi(),this.Xi(),(this.src()||this.currentSrc())&&this.tag&&this.h.autoplay&&this.paused()){try{delete this.tag.poster}catch(t){hs("deleting tag.poster throws in some browsers",t)}this.play()}},s.Bi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-seeking"),this.error(null),this.paused()?(this.hasStarted(!1),this.trigger("loadstart")):(this.trigger("loadstart"),this.trigger("firstplay"))},s.hasStarted=function(t){return void 0!==t?(this.et!==t&&(this.et=t,t?(this.addClass("vjs-has-started"),this.trigger("firstplay")):this.removeClass("vjs-has-started")),this):!!this.et},s.Wi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},s.Ri=function(){var t=this;this.addClass("vjs-waiting"),this.trigger("waiting"),this.one("timeupdate",(function(){return t.removeClass("vjs-waiting")}))},s.Oi=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},s.Vi=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},s.Li=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},s.Hi=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},s.zi=function(){this.removeClass("vjs-seeking"),this.trigger("seeked")},s.qi=function(){this.h.starttime&&(hs.warn("Passing the `starttime` option to the player will be deprecated in 6.0"),this.currentTime(this.h.starttime)),this.addClass("vjs-has-started"),this.trigger("firstplay")},s.Gi=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},s.Ui=function(){this.addClass("vjs-ended"),this.h.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},s.Xi=function(){this.duration(this.Zi("duration"))},s.es=function(t){0===t.button&&this.controls()&&(void 0!==this.h&&void 0!==this.h.userActions&&void 0!==this.h.userActions.click&&!1===this.h.userActions.click||(void 0!==this.h&&void 0!==this.h.userActions&&"function"==typeof this.h.userActions.click?this.h.userActions.click.call(this,t):this.paused()?this.play():this.pause()))},s.os=function(){this.userActive(!this.userActive())},s.ns=function(){this.userWasActive=this.userActive()},s.rs=function(){this.userWasActive&&this.reportUserActivity()},s.hs=function(t){t.cancelable&&t.preventDefault()},s.ki=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},s._i=function(){this.reportUserActivity()},s.Ji=function(t,i){i&&(this.toggleClass("vjs-ios-native-fs",!(!i.nativeIOSFullscreen||!i.isFullscreen)),this.isFullscreen(i.isFullscreen)),this.trigger("fullscreenchange")},s.Qi=function(){var t=this.H.error();this.error(t)},s.Ki=function(){var t=null;arguments.length>1&&(t=arguments[1]),this.trigger("textdata",t)},s.getCache=function(){return this.pi},s.us=function(t,i){if(this.H&&!this.H.T)this.H.ready((function(){this[t](i)}),!0);else try{this.H&&this.H[t](i)}catch(t){throw hs(t),t}},s.Zi=function(t){if(this.H&&this.H.T)try{return this.H[t]()}catch(i){throw void 0===this.H[t]?hs("Video.js: "+t+" method not defined for "+this.Ei+" playback technology.",i):"TypeError"===i.name?(hs("Video.js: "+t+" unavailable on "+this.Ei+" playback technology element.",i),this.H.T=!1):hs(i),i}},s.play=function(){return this.src()||this.currentSrc()?this.us("play"):this.H.one("loadstart",(function(){this.play()})),this},s.pause=function(){return this.us("pause"),this},s.paused=function(){return!1!==this.Zi("paused")},s.scrubbing=function(t){return void 0!==t?(this.yi=!!t,t?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing"),this):this.yi},s.currentTime=function(t){return void 0!==t?(this.us("setCurrentTime",t),this):(this.pi.currentTime=this.Zi("currentTime")||0,this.pi.currentTime)},s.duration=function(t){return void 0===t?void 0!==this.pi.duration?this.pi.duration:NaN:((t=_(t))<0&&(t=1/0),t!==this.pi.duration&&(this.pi.duration=t,t===1/0?this.addClass("vjs-live"):this.removeClass("vjs-live"),this.trigger("durationchange")),this)},s.remainingTime=function(){return this.duration()-this.currentTime()},s.buffered=function(){var t=this.Zi("buffered");return t&&t.length||(t=Fe(0,0)),t},s.bufferedPercent=function(){return $e(this.buffered(),this.duration())},s.bufferedEnd=function(){var t=this.buffered(),i=this.duration(),s=t.end(t.length-1);return s>i&&(s=i),s},s.volume=function(t){var i;return void 0!==t?(i=w.max(0,w.min(1,_(t))),this.pi.volume=i,this.us("setVolume",i),this):(i=_(this.Zi("volume")),j(i)?1:i)},s.muted=function(t){return void 0!==t?(this.us("setMuted",t),this):this.Zi("muted")||!1},s.supportsFullScreen=function(){return this.Zi("supportsFullScreen")||!1},s.isFullscreen=function(t){return void 0!==t?(this.cs=!!t,this):!!this.cs},s.requestFullscreen=function(t){var i,s=Le;return this.isFullscreen(!0),s.requestFullscreen?(pe(Xi,s.fullscreenchange,Se(this,(function t(i){this.isFullscreen(Xi[s.fullscreenElement]),!1===this.isFullscreen()&&me(Xi,s.fullscreenchange,t),this.trigger("fullscreenchange")}))),s.prefixed||(i=this.h.fullscreenOptions,void 0!==t&&(i=t)),this.v[s.requestFullscreen](i)):this.H.supportsFullScreen()?this.us("enterFullScreen"):(this.enterFullWindow(),this.trigger("fullscreenchange")),this},s.exitFullscreen=function(){var t=Le;return this.isFullscreen(!1),t.requestFullscreen?Xi[t.exitFullscreen]():this.H.supportsFullScreen()?this.us("exitFullScreen"):(this.exitFullWindow(),this.trigger("fullscreenchange")),this},s.enterFullWindow=function(){this.isFullWindow=!0,this.docOrigOverflow=Xi.documentElement.style.overflow,pe(Xi,"keydown",Se(this,this.fullWindowOnEscKey)),Xi.documentElement.style.overflow="hidden",Ss(Xi.body,"vjs-full-window"),this.trigger("enterFullWindow")},s.fullWindowOnEscKey=function(t){27===t.keyCode&&(!0===this.isFullscreen()?this.exitFullscreen():this.exitFullWindow())},s.exitFullWindow=function(){this.isFullWindow=!1,me(Xi,"keydown",this.fullWindowOnEscKey),Xi.documentElement.style.overflow=this.docOrigOverflow,Ts(Xi.body,"vjs-full-window"),this.trigger("exitFullWindow")},s.canPlayType=function(t){for(var i,s=0,e=this.h.techOrder;s<e.length;s++){var n=Te(e[s]),r=fh.getTech(n);if(r||(r=Pe.getComponent(n)),r){if(r.isSupported()&&(i=r.canPlayType(t)))return i}else hs.error('The "'+n+'" tech is undefined. Skipped browser support check for that tech.')}return""},s.selectSource=function(t){var i,s=this,e=this.h.techOrder.map(Te).map((function(t){return[t,fh.getTech(t)||Pe.getComponent(t)]})).filter((function(t){var i=t[0],s=t[1];return s?s.isSupported():(hs.error('The "'+i+'" tech is undefined. Skipped browser support check for that tech.'),!1)})),n=function(t,i,s){var e;return t.some((function(t){return i.some((function(i){if(e=s(t,i))return!0}))})),e},r=function(t,i){var e=t[0];if(t[1].canPlaySource(i,s.h[e.toLowerCase()]))return{source:i,tech:e}};return(this.h.sourceOrder?n(t,e,(i=r,function(t,s){return i(s,t)})):n(e,t,r))||!1},s.src=function(t){if(void 0===t)return this.Zi("src");var i=fh.getTech(this.Ei);return i||(i=Pe.getComponent(this.Ei)),Array.isArray(t)?this.ls(t):"string"==typeof t?this.src({src:t}):t instanceof g&&(t.type&&!i.canPlaySource(t,this.h[this.Ei.toLowerCase()])?this.ls([t]):(this.pi.sources=null,this.pi.source=t,this.pi.src=t.src,this.Ni=t.type||"",this.ready((function(){i.prototype.hasOwnProperty("setSource")?this.us("setSource",t):this.us("src",t.src),"auto"===this.h.preload&&this.load(),this.h.autoplay&&this.play()}),!0))),this},s.ls=function(t){var i=this.selectSource(t);i?(i.tech===this.Ei?this.src(i.source):this._t(i.tech,i.source),this.pi.sources=t):(this.setTimeout((function(){this.error({code:4,message:this.localize(this.h.notSupportedMessage)})}),0),this.triggerReady())},s.load=function(){return this.us("load"),this},s.reset=function(){return this._t(Te(this.h.techOrder[0]),null),this.us("reset"),this},s.currentSources=function(){var t=this.currentSource(),i=[];return 0!==g.keys(t).length&&i.push(t),this.pi.sources||i},s.currentSource=function(){var t={},i=this.currentSrc();return i&&(t.src=i),this.pi.source||t},s.currentSrc=function(){return this.Zi("currentSrc")||this.pi.src||""},s.currentType=function(){return this.Ni||""},s.preload=function(t){return void 0!==t?(this.us("setPreload",t),this.h.preload=t,this):this.Zi("preload")},s.autoplay=function(t){return void 0!==t?(this.us("setAutoplay",t),this.h.autoplay=t,this):this.Zi("autoplay",t)},s.playsinline=function(t){return void 0!==t?(this.us("setPlaysinline",t),this.h.playsinline=t,this):this.Zi("playsinline")},s.loop=function(t){return void 0!==t?(this.us("setLoop",t),this.h.loop=t,this):this.Zi("loop")},s.poster=function(t){return void 0===t?this.mi:(t||(t=""),this.mi=t,this.us("setPoster",t),this.trigger("posterchange"),this)},s.Yi=function(){!this.mi&&this.H&&this.H.poster&&(this.mi=this.H.poster()||"",this.trigger("posterchange"))},s.controls=function(t){return void 0!==t?(t=!!t,this.gi!==t&&(this.gi=t,this.usingNativeControls()&&this.us("setControls",t),t?(this.removeClass("vjs-controls-disabled"),this.addClass("vjs-controls-enabled"),this.trigger("controlsenabled"),this.usingNativeControls()||this.ts()):(this.removeClass("vjs-controls-enabled"),this.addClass("vjs-controls-disabled"),this.trigger("controlsdisabled"),this.usingNativeControls()||this.ss())),this):!!this.gi},s.usingNativeControls=function(t){return void 0!==t?(t=!!t,this.fs!==t&&(this.fs=t,t?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols"))),this):!!this.fs},s.error=function(t){return void 0===t?this.lt||null:null===t?(this.lt=t,this.removeClass("vjs-error"),this.errorDisplay&&this.errorDisplay.close(),this):(this.lt=new ze(t),this.addClass("vjs-error"),hs.error("(CODE:"+this.lt.code+" "+ze.errorTypes[this.lt.code]+")",this.lt.message,this.lt),this.trigger("error"),this)},s.reportUserActivity=function(t){this.ds=!0},s.userActive=function(t){return void 0!==t?((t=!!t)!==this.vs&&(this.vs=t,t?(this.ds=!0,this.removeClass("vjs-user-inactive"),this.addClass("vjs-user-active"),this.trigger("useractive")):(this.ds=!1,this.H&&this.H.one("mousemove",(function(t){t.stopPropagation(),t.preventDefault()})),this.removeClass("vjs-user-active"),this.addClass("vjs-user-inactive"),this.trigger("userinactive"))),this):this.vs},s.wi=function(){var t,i,s,e,n=Se(this,this.reportUserActivity);this.on("mousedown",(function(){n(),this.clearInterval(t),t=this.setInterval(n,250)})),this.on("mousemove",(function(t){t.screenX===i&&t.screenY===s||(i=t.screenX,s=t.screenY,n())})),this.on("mouseup",(function(i){n(),this.clearInterval(t)})),this.on("keydown",n),this.on("keyup",n),this.setInterval((function(){if(this.ds){this.ds=!1,this.userActive(!0),this.clearTimeout(e);var t=this.h.inactivityTimeout;t>0&&(e=this.setTimeout((function(){this.ds||this.userActive(!1)}),t))}}),250)},s.playbackRate=function(t){return void 0!==t?(this.us("setPlaybackRate",t),this):this.H&&this.H.featuresPlaybackRate?this.Zi("playbackRate"):1},s.isAudio=function(t){return void 0!==t?(this.ps=!!t,this):!!this.ps},s.videoTracks=function(){return this.H?this.H.videoTracks():(this.rt=this.rt||new ah,this.rt)},s.audioTracks=function(){return this.H?this.H.audioTracks():(this.ht=this.ht||new ch,this.ht)},s.textTracks=function(){if(this.H)return this.H.textTracks()},s.remoteTextTracks=function(){if(this.H)return this.H.remoteTextTracks()},s.remoteTextTrackEls=function(){if(this.H)return this.H.remoteTextTrackEls()},s.addTextTrack=function(t,i,s){if(this.H)return this.H.addTextTrack(t,i,s)},s.addRemoteTextTrack=function(t,i){if(this.H)return this.H.addRemoteTextTrack(t,i)},s.removeRemoteTextTrack=function(t){var i=(void 0===t?{}:t).track,s=void 0===i?arguments[0]:i;if(this.H)return this.H.removeRemoteTextTrack(s)},s.getVideoPlaybackQuality=function(){return this.Zi("getVideoPlaybackQuality")},s.videoWidth=function(){return this.H&&this.H.videoWidth&&this.H.videoWidth()||0},s.videoHeight=function(){return this.H&&this.H.videoHeight&&this.H.videoHeight()||0},s.language=function(t){return void 0===t?this.gs:(this.gs!==String(t).toLowerCase()&&(this.gs=String(t).toLowerCase(),void 0!==this.v&&this.trigger("languagechange")),this)},s.languages=function(){return Ce(i.prototype.h.languages,this.vi)},s.toJSON=function(){var t=Ce(this.h),i=t.tracks;t.tracks=[];for(var s=0;s<i.length;s++){var e=i[s];(e=Ce(e)).player=void 0,t.tracks[s]=e}return t},s.createModal=function(t,i){var s=this;(i=i||{}).content=t||"";var e=new Qe(this,i);return this.addChild(e),e.on("dispose",(function(){s.removeChild(e)})),e.open()},i.getTagSettings=function(t){var i={sources:[],tracks:[]},s=As(t),e=s["data-setup"];if(xs(t,"vjs-fluid")&&(s.fluid=!0),null!==e){var n=We(e||"{}"),r=n[0],h=n[1];r&&hs.error(r),ss(s,h)}if(ss(i,s),t.hasChildNodes())for(var o=t.childNodes,a=0,u=o.length;a<u;a++){var c=o[a],l=c.nodeName.toLowerCase();"source"===l?i.sources.push(As(c)):"track"===l&&i.tracks.push(As(c))}return i},s.bi=function(){var t=Xi.createElement("i");return!("flexBasis"in t.style||"webkitFlexBasis"in t.style||"mozFlexBasis"in t.style||"msFlexBasis"in t.style||"msFlexOrder"in t.style)},i}(Pe);Ro.players={};var Oo=o.navigator;Ro.prototype.h={techOrder:["html5","flash"],html5:{},flash:{},defaultVolume:0,inactivityTimeout:2e3,playbackRates:[],children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","controlBar","errorDisplay","textTrackSettings"],language:Oo&&(Oo.languages&&Oo.languages[0]||Oo.userLanguage||Oo.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",fullscreenOptions:{navigationUI:"hide"}},["ended","seeking","seekable","networkState","readyState"].forEach((function(t){Ro.prototype[t]=function(){return this.Zi(t)}})),Bo.forEach((function(t){Ro.prototype["handleTech"+Te(t)+"_"]=function(){return this.trigger(t)}})),Pe.registerComponent("Player",Ro);var Vo,Lo,Uo=function(t){function i(s){var e;void 0===s&&(s={});var n=Ce(s,{kind:Ze[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(ee)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return g.defineProperty(r,"enabled",{get:function(){return h},set:function(t){"boolean"==typeof t&&t!==h&&(h=t,this.trigger("enabledchange"))}}),n.enabled&&(r.enabled=n.enabled),r.q=!0,r||Me(e)}return Ee(i,t),i}(en),Ho=function(t){function i(s){var e;void 0===s&&(s={});var n=Ce(s,{kind:Ke[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(ee)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return g.defineProperty(r,"selected",{get:function(){return h},set:function(t){"boolean"==typeof t&&t!==h&&(h=t,this.trigger("selectedchange"))}}),n.selected&&(r.selected=n.selected),r||Me(e)}return Ee(i,t),i}(en);function zo(t,i,s){var e;if("string"==typeof t){if(0===t.indexOf("#")&&(t=t.slice(1)),zo.getPlayers()[t])return i&&hs.warn('Player "'+t+'" is already initialised. Options will not be applied.'),s&&zo.getPlayers()[t].ready(s),zo.getPlayers()[t];e=function(t){return 0===t.indexOf("#")&&(t=t.slice(1)),Xi.getElementById(t)}(t)}else e=t;if(!e||!e.nodeName)throw new p("The element or ID supplied is not valid. (videojs)");if(e.player||Ro.players[e.playerId])return e.player||Ro.players[e.playerId];i=i||{},zo.hooks("beforesetup").forEach((function(t){var s=t(e,Ce(i));es(s)&&!Array.isArray(s)?i=Ce(i,s):hs.error("please return an object in beforesetup hooks")}));var n=new(Pe.getComponent("Player"))(e,i,s);return zo.hooks("setup").forEach((function(t){return t(n)})),n}"undefined"==typeof HTMLVideoElement&&ds()&&(Xi.createElement("video"),Xi.createElement("audio"),Xi.createElement("track")),zo.ys={},zo.hooks=function(t,i){return zo.ys[t]=zo.ys[t]||[],i&&(zo.ys[t]=zo.ys[t].concat(i)),zo.ys[t]},zo.hook=function(t,i){zo.hooks(t,i)},zo.removeHook=function(t,i){var s=zo.hooks(t).indexOf(i);return!(s<=-1)&&(zo.ys[t]=zo.ys[t].slice(),zo.ys[t].splice(s,1),!0)},!0!==o.VIDEOJS_NO_DYNAMIC_STYLE&&ds()&&((Vo=Os(".vjs-styles-defaults"))||(Vo=je("vjs-styles-defaults"),(Lo=Os("head"))&&Lo.insertBefore(Vo,Lo.firstChild),xe(Vo,"\n .video-js {\n width: 300px;\n height: 150px;\n }\n\n .vjs-fluid {\n padding-top: 56.25%\n }\n "))),_e(1,zo),zo.VERSION="5.20.6-opentelly.12",zo.options=Ro.prototype.h,zo.getPlayers=function(){return Ro.players},zo.players=Ro.players,zo.getComponent=Pe.getComponent,zo.registerComponent=function(t,i){fh.isTech(i)&&hs.warn("The "+t+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),Pe.registerComponent.call(Pe,t,i)},zo.getTech=fh.getTech,zo.registerTech=fh.registerTech,zo.browser=ue,zo.TOUCH_ENABLED=oe,zo.extend=function(t,i){void 0===i&&(i={});var s=function(){t.apply(this,arguments)},e={};for(var n in es(i)?("function"==typeof i.init&&(hs.warn("Constructor logic via init() is deprecated; please use constructor() instead."),i.constructor=i.init),i.constructor!==g.prototype.constructor&&(s=i.constructor),e=i):"function"==typeof i&&(s=i),function(t,i){if("function"!=typeof i&&null!==i)throw new p("Super expression must either be null or a function, not "+typeof i);t.prototype=g.create(i&&i.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),i&&(t.bs=i)}(s,t),e)e.hasOwnProperty(n)&&(s.prototype[n]=e[n]);return s},zo.mergeOptions=Ce,zo.bind=Se,zo.plugin=function(t,i){Ro.prototype[t]=i},zo.addLanguage=function(t,i){var s;return t=(""+t).toLowerCase(),zo.options.languages=Ce(zo.options.languages,((s={})[t]=i,s)),zo.options.languages[t]},zo.log=hs,zo.createTimeRange=zo.createTimeRanges=Fe,zo.formatTime=Th,zo.parseUrl=nn,zo.isCrossOrigin=rn,zo.EventTarget=Ae,zo.on=pe,zo.one=ye,zo.off=me,zo.trigger=ge,zo.xhr=Qr,zo.TextTrack=ih,zo.AudioTrack=Uo,zo.VideoTrack=Ho,zo.isEl=vs,zo.isTextNode=Ns,zo.createEl=ms,zo.hasClass=xs,zo.addClass=Ss,zo.removeClass=Ts,zo.toggleClass=Cs,zo.setAttributes=Ps,zo.getAttributes=As,zo.emptyEl=Fs,zo.appendContent=$s,zo.insertContent=Bs,zo.computedStyle=Dh;var Wo=10;function qo(t){const i=t.duration;if(j(i)){var s;const i=null==(s=t.source)?void 0:s.streamType;return"live"===i||"dvr"===i}return i===1/0}function Go(t){return t.scrubbing()?t.getCache().currentTime:t.currentTime()}function Xo(t){const i=Yo(t);return qo(t)?i.end(i.length-1):i.start(0)}function Jo(t){return Yo(t).start(0)}function Qo(t){const i=Yo(t);return i.end(i.length-1)-i.start(0)}function Yo(t){const i=t.seekable;if(i&&i.length)return i;let s=t.duration;return s=isFinite(s)?s:0,new Bi([0,s]).ws()}function Ko(t,i){void 0===i&&(i=t);let s=t<0?"-":"";t=w.abs(t);let e=w.floor(t%60),n=w.floor(t/60%60),r=w.floor(t/3600);const h=w.floor(i/60%60),o=w.floor(i/3600);return(j(t)||t===1/0)&&(r=n=e="-"),r=+r>0||o>0?r+":":"",n=((r||h>=10)&&+n<10?"0"+n:n)+":",e=+e<10?"0"+e:e,s+r+n+e}function n(t){return class extends t{get ks(){var t;return null!=(t=this._s)?t:this._s=Zo(this.player())}dispose(){this._s=void 0,super.dispose()}constructor(...t){super(...t),this._s=void 0}}}function Zo(t){return t.tech({IWillNotUseThisInPlugins:!0}).theoplayer()}function ta(t){const i=Zo(t),s=()=>{const s=Go(t);t.toggleClass("theo-at-live",function(t,i){if(qo(t)){let s=t.seekable;return 0===s.length||s.end(s.length-1)-i<Wo}return!1}(i,s)),t.toggleClass("vjs-live",qo(i)),t.toggleClass("theo-dvr",function(t){var i;return"dvr"===Ai(t.duration,t.seekable,null==(i=t.source)?void 0:i.streamType)}(i))};t.on("emptied",s),t.on("timeupdate",s),t.on("durationchange",s)}var ia="theo-ad-playing",sa="theo-dai-ad-playing";function ea(t,i,s){t.toggleClass(ia,i),t.toggleClass(sa,i&&s)}function na(){this.userActive(!1)}var ra,ha,oa=class{constructor(t,i){this.type=t.type,this.target=i,this.playerEvent=t}};!function(t){t.js="unavailable",t.xs="available",t.Ss="presenting"}(ra||(ra={})),function(t){t.LOADED="DAILoaded",t.AD_BREAK_STARTED="DAIAdBreakStarted",t.AD_BREAK_ENDED="DAIAdBreakEnded",t.AD_PERIOD_STARTED="DAIAdPeriodStarted",t.AD_PERIOD_ENDED="DAIAdPeriodEnded",t.AD_PROGRESS="DAIAdProgress",t.CUEPOINTS_CHANGED="DAICuePointsChanged",t.CLICK="DAIClick",t.ERROR="DAIError",t.STARTED="DAIStarted",t.FIRST_QUARTILE="DAIFirstQuartile",t.MIDPOINT="DAIMidpoint",t.STREAM_INITIALIZED="DAIStreamInitialized",t.THIRD_QUARTILE="DAIThirdQuartile",t.COMPLETE="DAIComplete"}(ha||(ha={}));var aa=["loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange","resize"],ua=zo.getTech("Tech"),ca=zo.getTech("Html5"),la=class extends ua{Ts(){var t;for(const t of aa)this.ks.addEventListener(t,this.Cs);this.ks.addEventListener("error",this.Ps),this.ks.addEventListener("contentprotectionerror",this.Ps),this.ks.addEventListener("sourcechange",this.As),this.ks.addEventListener("loadstart",this.Ms),null==(t=this.ks.presentation)||t.addEventListener("presentationmodechange",this.Is),this.ks.textTracks.addEventListener("addtrack",this.Es),this.ks.textTracks.addEventListener("removetrack",this.Ds),this.ks.textTracks.addEventListener("change",this.Ns),this.ks.audioTracks.addEventListener("addtrack",this.Fs),this.ks.audioTracks.addEventListener("removetrack",this.$s),this.ks.audioTracks.addEventListener("change",this.Bs)}Rs(){var t;for(const t of aa)this.ks.removeEventListener(t,this.Cs);this.ks.removeEventListener("error",this.Ps),this.ks.removeEventListener("contentprotectionerror",this.Ps),this.ks.removeEventListener("sourcechange",this.As),this.ks.removeEventListener("loadstart",this.Ms),null==(t=this.ks.presentation)||t.removeEventListener("presentationmodechange",this.Is),this.ks.textTracks.removeEventListener("addtrack",this.Es),this.ks.textTracks.removeEventListener("removetrack",this.Ds),this.ks.textTracks.removeEventListener("change",this.Ns),this.ks.audioTracks.removeEventListener("addtrack",this.Fs),this.ks.audioTracks.removeEventListener("removetrack",this.$s),this.ks.audioTracks.removeEventListener("change",this.Bs)}Os(t){this.trigger(new oa(t,this))}createEl(){let t=this.h,i=t.player;if(!i)throw new v(this.localize('Missing required tech option "player"'));let s=i.element;return zo.setAttributes(s,{id:t.techId}),s}theoplayer(){return this.ks}addTextTrack(t,i,s){return super.addTextTrack(t,i,s)}buffered(){return this.ks.buffered}played(){return this.ks.played}reset(){this.ks.stop()}play(){this.ks.play()}pause(){this.ks.pause()}paused(){return this.ks.paused}currentTime(){return this.ks.currentTime}setCurrentTime(t){this.ks.currentTime=t}duration(){return this.ks.duration}volume(){return this.ks.volume}setVolume(t){this.ks.volume=t}muted(){return this.ks.muted}setMuted(t){this.ks.muted=t}src(t){if(void 0!==t)this.setSrc(t);else{if(this.ks.src)return this.ks.src;if(this.ks.source){if(!E(this.ks.source.ads))return this.ks.source.ads[0].sources;if(function(t){if(t.sources)if($t(t.sources)){for(const i of t.sources)if(!Ut(i)&&"verizon-media"===i.integration)return!0}else if(!Ut(t.sources))return"verizon-media"===t.sources.integration;return!1}(this.ks.source))return"This source is managed by the Verizon Media integration extension.";if(function(t){if(t.sources)if($t(t.sources)){for(const i of t.sources)if(ii(i))return!0}else if(Ot(t.sources))return ii(t.sources);return!1}(this.ks.source))return"This source is managed by the DAI integration extension."}}}setSrc(t){return this.setSource({src:t})}setSource(t){this.lt=null,this.trigger("error")}currentSrc(){return this.ks.src}load(){this.setPreload("auto")}preload(){return this.ks.preload}setPreload(t){this.ks.preload=t}autoplay(){return this.ks.autoplay}setAutoplay(t){this.ks.autoplay=!!t}seeking(){return this.ks.seeking}seekable(){return this.ks.seekable}ended(){return this.ks.ended}playbackRate(){return this.ks.playbackRate}setPlaybackRate(t){this.ks.playbackRate=t}readyState(){return this.ks.readyState}networkState(){return 0}controls(){return!1}videoHeight(){return this.ks.videoHeight}videoWidth(){return this.ks.videoWidth}supportsFullScreen(){return this.ks.presentation.supportsMode(Hi.FULLSCREEN)}enterFullScreen(){this.ks.presentation.requestMode(Hi.FULLSCREEN)}exitFullScreen(){this.ks.presentation.requestMode(Hi.INLINE)}Vs(){let t=this.ks.ads;if(t&&t.playing)return!0;let i=this.ks.vr;return!(!i||i.state===ra.js)}initTextTrackListeners(){return this.on("touchend",(t=>{this.Vs()&&(t.preventDefault=()=>{})})),super.initTextTrackListeners()}Zt(){if(!this.src())return;const t=this.readyState();if(0===t){let t=!1,i=()=>{t=!0};this.on("loadstart",i);let s=()=>{t||this.trigger("loadstart")};return this.on("loadedmetadata",s),void this.ready((()=>{this.off("loadstart",i),this.off("loadedmetadata",s),t||this.trigger("loadstart")}))}let i=["loadstart"];i.push("loadedmetadata"),t>=2&&i.push("loadeddata"),t>=3&&i.push("canplay"),t>=4&&i.push("canplaythrough"),this.ready((()=>{for(const t of i)this.trigger(t)}))}dispose(){this.Rs(),this.ks=null,super.dispose()}static isSupported(){return!0}static canPlayType(){return"maybe"}static canPlaySource(t){return"maybe"}get featuresVolumeControl(){return Mi}constructor(t={},i){super(t,i),this.Cs=t=>this.Os(t),this.Ls=!1,this.As=()=>{this.Os(new ni(this.ks.currentTime,this.ks.readyState)),this.Os(new ft),this.Os(new di(this.ks.duration))},this.Ms=()=>{this.Os(new Pt(this.ks.currentTime))},this.Es=t=>{this.textTracks().tt(t.track)},this.Fs=t=>{this.audioTracks().tt(t.track)},this.Ds=t=>{this.textTracks().it(t.track)},this.$s=t=>{this.audioTracks().it(t.track)},this.Ns=()=>{let t=this.textTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Bs=()=>{let t=this.audioTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Is=()=>{if(!this.supportsFullScreen())return;let t=this.Ls,i=this.ks.presentation.currentMode===Hi.FULLSCREEN;t!==i&&(this.Ls=i,this.trigger("fullscreenchange",{isFullscreen:i,nativeIOSFullscreen:!0}))},this.Ps=()=>{const t=this.ks.errorObject,i=t&&rt(t.code)||-1,s=t&&t.message||"An unknown error occurred.";this.error({code:i,message:this.localize(s)})},this.ks=this.h.player,this.Ts();const s=!this.paused();s&&this.pause(),t.preload&&this.setPreload(t.preload),t.autoplay&&this.setAutoplay(t.autoplay),t.muted&&this.setMuted(t.muted),t.source?this.setSrc(t.source):this.Zt(),s&&this.ready((()=>this.play())),this.triggerReady()}};la.prototype.featuresFullscreenResize=ca.prototype.featuresFullscreenResize,la.prototype.featuresPlaybackRate=ca.prototype.featuresPlaybackRate,la.prototype.featuresProgressEvents=!0,la.prototype.featuresTimeupdateEvents=!0,la.prototype.featuresNativeTextTracks=!0,zo.registerTech("THEOplayer",la);var fa=class{constructor(t){this.Us=t=>{fi(this.Hs,"theo-mobile-button-hover"),t.stopImmediatePropagation()},this.zs=t=>{pi(this.Hs,"theo-mobile-button-hover")},this.Ws=t=>{this.Hs.blur()},this.Hs=t,t.addEventListener("touchstart",this.Us),t.addEventListener("touchend",this.zs),t.addEventListener("focusin",this.Ws)}},da=zo.getComponent("Menu"),va=class extends(n(da)){get qs(){return this.player().el()}Gs(){fi(this.qs,"theo-menu-opened")}Xs(){pi(this.qs,"theo-menu-opened")}constructor(t,i){super(t,i)}},pa=zo.getComponent("MenuItem"),ma=class extends(n(pa)){get parentMenu(){return this.Js}buildCSSClass(){return"theo-menu-item vjs-menu-item"}createEl(){let t=super.createEl("li",{className:this.buildCSSClass(),tabIndex:0},{"aria-live":"off","aria-label":""});return t.innerHTML="",t}handleClick(t){this.Qs||(this.parentMenu.Ys(this),"tap"!==t.type&&"keydown"!==t.type||(this.Qs=!0,this.trigger("click"),this.Qs=!1))}dispose(){Ct.Zs.Ks&&(this.el().removeEventListener("touchstart",this.Us),this.el().removeEventListener("touchend",this.zs)),super.dispose()}constructor(t,i,s){super(t,Di({selectable:!0},i)),this.Qs=!1,this.Us=t=>{fi(this.el(),"theo-mobile-menu-item-hover"),t.stopImmediatePropagation()},this.zs=t=>{pi(this.el(),"theo-mobile-menu-item-hover")},this.Js=s,Ct.Zs.Ks&&(this.el().addEventListener("touchstart",this.Us),this.el().addEventListener("touchend",this.zs))}},ga=zo.getComponent("ClickableComponent"),ya=class extends ga{get parentMenu(){return this.Js}get te(){return this.ie}set te(t){this.ie=t,this.el().setAttribute("tabindex",this.te?"0":"-1"),this.se()}buildCSSClass(){return"theo-primary-background theo-menu-header"}createEl(){let t=super.createEl("div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-live":"off","aria-label":""});return t.innerHTML="",t}handleClick(t){!this.Qs&&this.te&&(this.Js.ee(),"tap"===t.type&&(this.Qs=!0,this.trigger("click"),this.Qs=!1))}se(){this.te?this.el().setAttribute("aria-label",this.localize("Go back to the previous menu")):this.el().setAttribute("aria-label","")}constructor(t,i,s){super(t,i),this.Qs=!1,this.ie=!1,this.Js=s,this.on(t,"languagechange",this.se)}},ba=class extends va{get menuHeader(){return this.ne}get menuItems(){return this.children()}addMenuItem(t){t=Di({playerOptions:this.h.playerOptions},t);let i=new ma(this.player(),t,this);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}addSubMenuItem(t){t=Di({playerOptions:this.h.playerOptions},t);let i=this.re(this.player(),t);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}removeMenuItem(t){this.removeChild(t),this.trigger("menuchange")}buildCSSClass(){return"theo-menu vjs-menu"}Gs(){super.Gs(),a.removeEventListener("resize",this.he),a.addEventListener("resize",this.he),this.show()}oe(){let t=this.ae();if(!t)return;let i=t.getClientRects();Ct.Zs.Ks?this.ue(t,i):this.ce(t,i)}ae(){var t;return null!=(t=this.contentEl().parentElement)?t:void 0}ce(t,i){}ue(t,i){}Xs(){a.removeEventListener("resize",this.he),super.Xs(),this.hide(),Ct.Zs.Ks&&(this.el().removeAttribute("style"),this.contentEl().removeAttribute("style"))}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=this.contentEl();fi(i,"theo-menu-content");let s=new ya(this.player(),this.h,this);return i.parentNode.insertBefore(s.el(),i),this.ne=s,t}Ys(t){}show(){return this.oe(),super.show()}dispose(){this.ne&&this.ne.dispose(),super.dispose()}constructor(t,i){super(t,i),this.he=()=>this.oe(),this.le=this.player().el(),this.hide(),this.on("menuchange",this.oe)}},wa=class extends ba{get fe(){return this.de}set fe(t){this.de&&this.de.ve(this),this.de=t,t&&t.pe(this)}me(t){this.fe.ge(t,"replace")}ye(t){t.fe.ge(this,"restore")}be(){pi(this.we,"vjs-hidden"),this.we.style.opacity="1",super.show()}ke(){fi(this.we,"vjs-hidden")}Gs(){this.fe&&this.fe.Gs(),super.Gs()}Xs(){this.fe&&this.fe.Xs(),super.Xs(),fi(this.we,"vjs-hidden")}ae(){if(this.fe&&this.fe._e)return this.fe._e.we}ce(t,i){if(i.length>0){let t=i[0].height,s=i[0].width;this.de.je.style.height=t+"px",this.de.je.style.width=s+"px"}super.ce(t,i)}constructor(t,i){super(t,i)}},ka=class{get je(){return this.Hs}get _e(){return this.xe}pe(t){t.ke(),this.Hs.appendChild(t.we)}ve(t){this.Hs.removeChild(t.we)}ge(t,i){if(t==this.xe)return;let s=this.xe;if(this.xe=t,this.xe.be(),this._e.focus(),Ct.Zs.Ks)s.ke();else{const t="translateX(100%)",e="translateX(-100%)",n=q("transform");s.we.style.opacity="0",s.we.style[n]="replace"===i?e:t,this.xe.we.style.opacity="1",this.xe.we.style[n]="",u((()=>{s.ke(),s.we.style[n]=""}),300)}}Gs(){this.Se(),this.xe.be(),this.Te()}Xs(){this.Se(),this.xe.ke(),this.Ce.ke(),this.xe=this.Ce,this.Te()}Te(){U((()=>{pi(this.Hs,"theo-no-transition"),pi(this.xe.we,"theo-no-transition")}))}Se(){fi(this.Hs,"theo-no-transition"),fi(this.xe.we,"theo-no-transition")}constructor(t){this.Ce=this.xe=t,this.Hs=h.createElement("div"),this.Hs.className="theo-tertiary-background theo-menu-animation-container",this.Hs.appendChild(this.Ce.we),this.le=this.xe.player().el()}},_a=class extends wa{get we(){return this.el()}get parentMenu(){return this.Pe}re(t,i){let s=new ja(t,i,this);return s.subMenu.fe=this.fe,s}ee(){this.Ae()}Ys(t){super.Ys(t),this.Ae()}Ae(){this.parentMenu.ye(this)}buildCSSClass(){return"theo-submenu "+(this.Me?"":"theo-leaf-submenu ")+"theo-menu-content theo-menu-content-animatable "+super.buildCSSClass()}addSubMenuItem(t){this.Me=!0;let i=super.addSubMenuItem(t);return this.removeClass("theo-leaf-submenu"),i}constructor(t,i,s){super(t,i),this.Me=!1,this.Pe=s,this.menuHeader.te=!0}},ja=class extends ma{get subMenu(){return this.Ie}handleClick(t){this.parentMenu.me(this.subMenu)}constructor(t,i,s){super(t,Di({selectable:!1},i),s),this.Ie=new _a(t,i,s)}},xa=class extends wa{get menuButton(){return this.Ee}createEl(){let t=zo.createEl("div",{className:this.buildCSSClass()});return this.De=super.createEl(),this.De.className=super.buildCSSClass(),fi(this.De,"theo-menu-content-animatable"),t.appendChild(this.De),this.fe=new ka(this),t.appendChild(this.fe.je),t}buildCSSClass(){return"theo-menu-animatable "+super.buildCSSClass()}re(t,i){let s=new ja(t,i,this);return s.subMenu.fe=this.fe,s}ce(t,i){super.ce(t,i);let s=this.le.getClientRects(),e=s.length>0?s[0]:void 0,n=_(getComputedStyle(this.el()).fontSize);At(this.el(),this.Ee.el(),e,n)}get we(){return this.De}ee(){this.Ee.closeMenu()}dispose(){this.Ne||(this.Ne=!0,super.dispose())}constructor(t,i,s){super(t,i),this.Ne=!1,this.Ee=s}},Sa=class{set Fe(t){this.$e.innerHTML=this.Be.localize(t),this.Re(),this.Oe(),ki(this.Be.el())}get Fe(){return this.$e.textContent||""}Ve(){this.Be.off("mouseover",this.Oe),this.Be.off("mouseout",this.Re),this.Be.off("dispose",this.Le),hi(this.$e)}constructor(t,i){this.Oe=()=>{pi(this.$e,"vjs-hidden");let t=this.Be.player().contentEl().getClientRects(),i=t.length>0?t[0]:void 0,s=_(getComputedStyle(this.$e).fontSize);At(this.$e,this.Be.el(),i,s)},this.Re=()=>{fi(this.$e,"vjs-hidden")},this.Le=()=>this.Ve(),this.Be=t,ki(t.el()),xi(t.el()),this.$e=h.createElement("span"),this.$e.innerHTML=this.Be.localize(i),this.$e.className="theo-button-tooltip vjs-hidden",this.$e.setAttribute("aria-hidden","true"),this.Be.el().appendChild(this.$e),this.Be.on("mouseover",this.Oe),this.Be.on("mouseout",this.Re),this.Be.on("dispose",this.Le)}},Ta=zo.getComponent("Button"),Ca=class extends(n(Ta)){get Ue(){const t=this.el().parentElement;return!!t&&null!==t.querySelector(".theo-mobile-menu-background")}get menu(){return this.He}isMenuOpen(){return this.ze}openMenu(){this.We&&!this.ze&&(this.He.Gs(),this.el().setAttribute("aria-expanded","true"),this.ze=!0,this.He.focus())}closeMenu(){this.We&&this.ze&&(this.He.Xs(),this.el().setAttribute("aria-expanded","false"),this.ze=!1)}set minimumMenuItems(t){this.qe=t,this.Ge()}buildCSSClass(){return"theo-controlbar-button vjs-menu-button vjs-menu-button-popup "+super.buildCSSClass()}createEl(t,i,s){return super.createEl("button",{},{"aria-live":"off"})}handleClick(){this.ze?this.closeMenu():this.openMenu()}enable(){return this.We=!0,super.enable()}disable(){return this.closeMenu(),this.We=!1,super.disable()}se(){this.$e.Fe=this.controlText()}dispose(){this.player().removeChild(this.He),this.He.dispose(),this.$e.Ve(),this.ks.removeEventListener("seeking",this.Xe),super.dispose()}constructor(t,i){super(t,i),this.ze=!1,this.qe=1,this.We=!0,this.Je=t=>{let i=this.el().contains(t.target),s=this.He.el().contains(t.target),e=!1;var n;Ct.Zs.Ks&&this.Ue&&(e=(null==(n=this.el().parentElement)?void 0:n.querySelector(".theo-mobile-menu-background"))===t.target);i||s||!this.ze||(e&&t.preventDefault(),this.closeMenu())},this.Qe=t=>{27===t.which&&(this.closeMenu(),this.focus())},this.Xe=()=>{this.ze&&this.closeMenu()},this.Ge=()=>{this.He.menuItems.length>=this.qe?this.show():(this.closeMenu(),this.hide())},this.He=new xa(t,i,this),this.player().getChild("controlBarMenuContainer").addChild(this.He),this.$e=new Sa(this,this.controlText()),this.el().setAttribute("aria-haspopup","true"),Ct.Zs.Ye?(this.on(h,"touchend",this.Je),new fa(this.el())):(this.on(h,"click",this.Je),this.on(h,"keydown",this.Qe),K&&this.on(h,K.Ke,this.closeMenu)),this.ks.addEventListener("seeking",this.Xe),this.on(this.He,"menuchange",this.Ge),this.on(t,"languagechange",this.se),this.Ge()}},Pa=zo.getComponent("Component"),Aa=class extends(zo.getComponent("ControlBar")){addMenuButton(t){t=Di({playerOptions:this.h.playerOptions},t);let i=new Ca(this.player(),t);return this.addChild(i),i}removeMenuButton(t){this.removeChild(t)}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-secondary-color vjs-control-bar "+super.buildCSSClass()}constructor(t,i){super(t,i),this.addChild("THEOControlBarShadow",void 0,0)}};zo.registerComponent("THEOControlBarShadow",class extends Pa{createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-tertiary-color theo-control-bar-shadow"}});var Ma=zo.getComponent("VolumeBar"),Ia=class extends Ma{handleFocus(t){super.handleFocus(t),this.Ze.addClass("focus-within")}handleBlur(t){super.handleBlur(t),this.Ze.removeClass("focus-within")}constructor(t,i){super(t,i),this.Ze=i.tn}},Ea=zo.getComponent("VolumeControl"),Da=class extends Ea{constructor(t,i){super(t,i),this.sn=new Ia(t,{tn:this}),this.addChild(this.sn)}};Da.prototype.h=Di({},Ea.prototype.h,{children:[]}),zo.registerComponent("VolumeControl",Da);var Na=class extends(n(Aa)){nn(){return this.el().getBoundingClientRect().height}dispose(){this.el().removeEventListener("transitionstart",this.rn),this.el().removeEventListener("transitionend",this.hn),this.un.an(z.cn,this.ln),this.un.fn(),super.dispose()}constructor(t,i){super(t,i),this.rn=t=>{if("opacity"===t.propertyName){const t=this.nn();this.ks.textTrackStyle.marginBottom!==t&&(this.ks.textTrackStyle.marginBottom=t)}},this.hn=t=>{"opacity"===t.propertyName&&"0"===a.getComputedStyle(this.el()).opacity&&(this.ks.textTrackStyle.marginBottom=void 0)},this.ln=()=>{void 0!==this.ks.textTrackStyle.marginBottom&&(this.ks.textTrackStyle.marginBottom=this.nn())},this.el().addEventListener("transitionstart",this.rn),this.el().addEventListener("transitionend",this.hn),this.un=new X(this.el()),this.un.dn(z.cn,this.ln),this.un.vn(!0)}};Na.prototype.h=Di({},Aa.prototype.h,{children:["progressControl","playToggle","muteToggle","volumeControl","currentTimeDisplay","timeDivider","durationDisplay","liveDisplay","remainingTimeDisplay","customControlSpacer","activeQualityLabel","vrButton","descriptionsButton","subtitlesButton","chromecastButton","airplayButton","multiViewButton","audioTrackButton","SettingsButton","fullscreenToggle"]}),zo.registerComponent("ControlBar",Na);var Fa=class extends Aa{buildCSSClass(){return"theo-top-controlbar "+super.buildCSSClass()}constructor(t,i){super(t,i),t.topControlBar=this}};Fa.prototype.h=Di({},Aa.prototype.h,{children:[]}),zo.registerComponent("TopControlBar",Fa);var $a=zo.getComponent("CurrentTimeDisplay"),Ba=class extends(n($a)){updateContent(){const t=Go(this.player()),i=this.ks,s=Jo(i),e=this.localize("Current Time"),n=Ko(w.max(0,t-s),Qo(i));n!==this.Pt&&(this.Pt=n,this.contentEl().innerHTML='<span class="vjs-control-text">'+e+"</span> "+n)}constructor(t,i){super(t,i),this.on(t,"timeupdate",this.updateContent),this.on(t,"emptied",this.updateContent)}};zo.registerComponent("CurrentTimeDisplay",Ba);var Ra=zo.getComponent("DurationDisplay"),Oa=class extends(n(Ra)){updateContent(){const t=this.ks,i=j(t.duration)?NaN:Qo(t),s=t.clip.endTime-t.clip.startTime,e=w.min(i,s)||0;if(this.ct!==e){this.ct=e;const t=this.localize("Duration Time"),i=Ko(e);this.S.innerHTML='<span class="vjs-control-text">'+t+"</span> "+i}}dispose(){var t;null==(t=this.ks)||t.clip.removeEventListener("change",this.pn),super.dispose()}constructor(t,i){var s;super(t,i),this.pn=()=>this.updateContent(),this.off(t,"durationchange",this.updateContent),this.on(t,"durationchange",this.updateContent),this.off(t,"timeupdate",this.updateContent),this.on(t,"timeupdate",this.updateContent),this.off(t,"emptied",this.updateContent),this.on(t,"emptied",this.updateContent),null==(s=this.ks)||s.clip.addEventListener("change",this.pn)}};zo.registerComponent("DurationDisplay",Oa);var Va=zo.getComponent("Button"),La=class extends(n(Va)){buildCSSClass(){return"theo-live-control "+super.buildCSSClass()}createEl(){let t=super.createEl("button",{},{"aria-live":"off"});return this.mn=zo.createEl("span",{className:"theo-live-control-indicator"}),t.insertBefore(this.mn,t.firstChild),t}createControlTextEl(t){let i=super.createControlTextEl(t);return zo.removeClass(i,"vjs-control-text"),zo.addClass(i,"theo-live-control-text"),i}handleClick(){var t;const i=this.ks;if(void 0!==(null==(t=i.hesp)?void 0:t.manifest))i.hesp.goLive();else{const t=this.player();t.currentTime(Xo(i)),t.play()}}gn(){qo(this.ks)?this.show():this.hide()}constructor(t,i){super(t,i),this.controlText("Live"),this.gn(),this.on(t,"emptied",this.gn),this.on(t,"durationchange",this.gn),Ct.Zs.Ye&&new fa(this.el())}};zo.registerComponent("LiveDisplay",La);var Ua=zo.getComponent("LoadingSpinner");zo.registerComponent("LoadingSpinner",class extends Ua{buildCSSClass(){return"theo-secondary-color vjs-loading-spinner "+super.buildCSSClass()}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=zo.createEl("div",{className:"theo-loading-spinner-rotator"}),s=zo.createEl("div",{className:"theo-loading-spinner-circle-left"}),e=zo.createEl("div",{className:"theo-loading-spinner-circle-right"});return i.appendChild(s),i.appendChild(e),t.appendChild(i),t}constructor(t,i){super(t,i)}});var Ha=zo.getComponent("LoadProgressBar"),za=class extends(n(Ha)){update(){let t=this.ks,i=Bi.yn(Yo(t)),s=i.bn(0),e=Bi.yn(t.buffered).wn(i),n=i.kn(0)-s,r=e.L&&e.kn(e.L-1)||0;r=w.max(0,r-s);let o=this.el(),a=this._n;o.style.width=Wa(r,n);for(let t=0;t<e.L;t++){let i=e.bn(t),n=e.kn(t),u=a[t];u||(u=h.createElement("div"),a.push(u),o.appendChild(u)),u.style.left=Wa(i-s,r),u.style.width=Wa(n-i,r)}for(let t=a.length;t>e.L;t--)o.removeChild(a[t-1]);a.length=e.L}constructor(t,i){super(t,i),this._n=[],this.on(t,"emptied",this.update)}};function Wa(t,i){let s=t/i||0;return 100*(s>=1?1:s)+"%"}zo.registerComponent("LoadProgressBar",za);var qa=zo.getComponent("MouseTimeDisplay"),Ga=class extends(n(qa)){handleMouseMove(t){let i=t,s=this.ks,e=Jo(s)+this.calculateDistance(i)*Qo(s),n=i.pageX-T(this.el().parentNode).left;this.update(e,n+"px")}handleTouchMove(t){let i=t,s=this.ks,e=Jo(s)+this.calculateDistance(i)*Qo(s),n=i.touches[0].pageX-T(this.el().parentNode).left;this.update(e,n+"px")}createEl(){let t=super.createEl();return this.jn=zo.createEl("span",{className:"theo-time-tooltip-text"}),t}update(t,i){this.xn=t;let s=this.Sn(t);this.el().style.left=i,this.el().setAttribute("data-current-time",s),this.keepTooltipsInside&&(Et(this.jn,s),this.Tn())}Tn(){if(this.keepTooltipsInside&&this.tooltip.offsetParent){let t=this.player().contentEl(),i=t.getClientRects(),s=i.length>0?i[0]:void 0,e=_(getComputedStyle(t).fontSize);At(this.tooltip,this.el(),s,e)}}Sn(t){const i=this.ks,s=t-Xo(i);return Ko(qo(i)?w.min(s,0):s,Qo(i))}dispose(){var t;this.ks.removeEventListener("dimensionchange",this.Cn),null==(t=this.ks.presentation)||t.removeEventListener("presentationmodechange",this.Cn),super.dispose()}constructor(t,i){var s;(super(t,i),this.xn=NaN,this.Cn=()=>{let t=Go(this.player());const i=this.ks;let s=(t-Jo(i))/Qo(i)||0;s=Yt(s,0,1),this.update(t,100*s+"%")},this.keepTooltipsInside&&(zo.addClass(this.tooltip,"theo-secondary-color"),this.tooltip.appendChild(this.jn)),this.on(t,"ready",(()=>{this.on(t.controlBar.progressControl,"mouseenter",this.handleMouseMove)})),Mt.Ks)&&(this.on(t,"firstplay",this.Cn),this.on(t,"play",this.Cn),this.on(t,"seeking",this.Cn),this.on(t,"seeked",this.Cn),this.on(t,"timeupdate",this.Cn),this.ks.addEventListener("dimensionchange",this.Cn),null==(s=this.ks.presentation)||s.addEventListener("presentationmodechange",this.Cn),this.on(t,"ready",(()=>{this.on(t.controlBar.progressControl,"touchstart",this.handleTouchMove),this.on(t.controlBar.progressControl,"touchmove",Xt((t=>this.handleTouchMove(t)),25)),this.Cn()})))}};zo.registerComponent("MouseTimeDisplay",Ga);var Xa=zo.getComponent("PlayProgressBar"),Ja=class extends(n(Xa)){updateDataAttr(){let t=Go(this.player());this.el().setAttribute("data-current-time",this.Sn(t))}Sn(t){let i=this.ks;return Ko(t-Xo(i),Qo(i))}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-play-progress vjs-slider-bar "+super.buildCSSClass()}constructor(t,i){super(t,i)}};zo.registerComponent("PlayProgressBar",Ja);var Qa=zo.getComponent("RemainingTimeDisplay"),Ya=class extends(n(Qa)){updateContent(){const t=this.ks,i=Qo(t);if(i){const s=Yo(t).end(0),e=this.localize("Remaining Time"),n=Ko(w.max(0,s-this.player().currentTime()),i);n!==this.Pt&&(this.Pt=n,this.contentEl().innerHTML='<span class="vjs-control-text">'+e+"</span> -"+n)}}constructor(t,i){super(t,i),this.on(t,"timeupdate",this.updateContent),this.on(t,"emptied",this.updateContent)}};zo.registerComponent("RemainingTimeDisplay",Ya);var Ka=class{get ks(){return this._s||(this._s=this.Pn.tech({IWillNotUseThisInPlugins:!0}).theoplayer()),this._s}An(t){if(t.kind!==dt.Mn)return;if(0===this.ks.seekable.length)return;this.In=t;const i=t.cues.slice();this.Dn.En(i);for(let t=0;t<i.length;t++){let s=i[t],e=i[t+1],n=!e||s.endTime!==e.startTime,r=new Za(s,this.ks,n);this.Nn.push(r),this.Fn.appendChild(r.je)}}$n(){this.ks.addEventListener("loadedmetadata",this.Bn),this.ks.addEventListener("loadeddata",this.Bn),this.ks.addEventListener("sourcechange",this.Bn),this.ks.textTracks.addEventListener("addtrack",this.Rn),this.ks.textTracks.addEventListener("removetrack",this.On),this.ks.textTracks.addEventListener("change",this.Bn)}Vn(){this.ks.removeEventListener("loadedmetadata",this.Bn),this.ks.removeEventListener("loadeddata",this.Bn),this.ks.removeEventListener("sourcechange",this.Bn),this.ks.textTracks.removeEventListener("addtrack",this.Rn),this.ks.textTracks.removeEventListener("removetrack",this.On),this.ks.textTracks.removeEventListener("change",this.Bn)}Ln(){if(!(this.ks.readyState<jt.Un))for(let t of this.ks.textTracks)if(t.kind===dt.Mn&&t.mode===ut.Hn&&t.cues.length>0&&t.readyState!==ot.ERROR)return t}zn(t){this.Dn.Wn(t)}qn(){this.Dn.be()}Gn(){this.Dn.ke()}Xn(){for(let t of this.Nn)t.Ve();this.Dn.Xn(),this.Nn=[],this.In=void 0}Ve(){this.Vn(),this.Jn.removeEventListener("mousemove",this.Qn),this.Jn.removeEventListener("mouseenter",this.Yn),this.Jn.removeEventListener("mouseleave",this.Kn),this.Xn(),this.Dn.Ve(),this._s=void 0}constructor(t,i){this.Pn=i,this.Nn=[],this._s=void 0,this.Rn=t=>{let i=t.track;i.kind===dt.Mn&&(i.addEventListener("addcue",this.Bn),i.addEventListener("removecue",this.Bn),i.addEventListener("readystatechange",this.Bn)),this.Bn()},this.On=t=>{let i=t.track;i.kind===dt.Mn&&(i.removeEventListener("addcue",this.Bn),i.removeEventListener("removecue",this.Bn),i.removeEventListener("readystatechange",this.Bn)),this.Bn()},this.Qn=t=>{let i=this.ks,s=function(t,i){let s,e,n=T(t),r=t.offsetWidth,h=t.offsetHeight,o=n.top,a=n.left;!function(t){return void 0!==t.changedTouches}(i)?(e=i.pageX,s=i.pageY):(e=i.changedTouches[0].pageX,s=i.changedTouches[0].pageY);let u=Yt((o-s+h)/h,0,1),c=Yt((e-a)/r,0,1);return{x:c,y:u}}(this.Fn,t),e=Jo(i)+s.x*Qo(i);e===i.duration&&(e-=.1),this.zn(e)},this.Kn=()=>{this.Dn.ke()},this.Yn=()=>{this.Dn.be()},this.Bn=()=>{let t=this.Ln();t!==this.In&&(this.Xn(),t&&this.An(t))},this.Jn=t,this.Dn=new tu,this.Pn.contentEl().appendChild(this.Dn.je),this.Fn=h.createElement("div"),fi(this.Fn,"theoplayer-chapterbar"),this.Jn.appendChild(this.Fn),this.Jn.addEventListener("mousemove",this.Qn),this.Jn.addEventListener("mouseenter",this.Yn),this.Jn.addEventListener("mouseleave",this.Kn),this.$n()}},Za=class{get je(){return this.Hs}Zn(){iu(this.tr,this.t.currentTime)&&this.ir(),this.tr.addEventListener("enter",this.ir),this.tr.addEventListener("exit",this.sr)}er(){let t=this.t.seekable.start(0),i=this.t.seekable.end(this.t.seekable.length-1)-t,s=this.tr.startTime,e=this.tr.endTime-s,n=h.createElement("div");fi(n,"theoplayer-chapter-indicator");let r=h.createElement("div");fi(r,"theoplayer-chapter-indicator-highlight"),n.appendChild(r),this.nr&&fi(n,"theoplayer-chapter-indicator-discontinuous");let o=w.min(s/i*100,100),a=100-o,u=w.min(e/i*100,a);return n.style.width=u+"%",n.style.left=o+"%",n}Ve(){this.tr.removeEventListener("enter",this.ir),this.tr.removeEventListener("exit",this.sr),hi(this.Hs)}constructor(t,i,s){this.tr=t,this.t=i,this.nr=s,this.ir=()=>{fi(this.je,"theoplayer-chapter-indicator-active")},this.sr=()=>{pi(this.je,"theoplayer-chapter-indicator-active")},this.Hs=this.er(),this.Zn()}},tu=class{ke(){this.rr--,0===this.rr&&pi(this.je,"theoplayer-chapter-hovering")}En(t){this.hr=t||[],this.hr.length>0&&(this.je.style.display="")}ar(t){Et(this.ur,t.content)}Xn(){this.hr=[],Et(this.ur,""),this.je.style.display="none"}be(){this.rr++,this.rr>0&&fi(this.je,"theoplayer-chapter-hovering")}Wn(t){for(let i of this.hr)if(iu(i,t)){this.ar(i);break}}Ve(){hi(this.je)}constructor(){this.hr=[],this.rr=0,this.je=h.createElement("div"),fi(this.je,"theoplayer-chaptertitle"),this.je.style.display="none",this.ur=h.createElement("p"),this.je.appendChild(this.ur)}};function iu(t,i){return new Bi([t.startTime,t.endTime]).cr(i)}var su=zo.getComponent("SeekBar"),eu=class extends(n(su)){updateAriaAttributes(t){const i=Go(this.player()),s=this.ks;t.setAttribute("aria-valuenow",(100*this.lr(i)).toFixed(2)),t.setAttribute("aria-valuetext",Ko(i-Xo(s),Qo(s)))}getPercent(){return this.lr(this.player().currentTime())}handleMouseMove(t){if(this.ks&&this.ks.ads&&this.ks.ads.playing)return;const i=this.ks;let s=Jo(i)+this.calculateDistance(t)*Qo(i);s>=i.duration&&(s=i.duration-.1),this.Fn.zn(s),this.player().currentTime(s)}handleMouseDown(t){this.playingStates.push(!this.player().paused()),this.Fn.qn(),super.handleMouseDown(t)}handleMouseUp(t){this.videoWasPlaying=Boolean(this.playingStates.pop()),this.Fn.Gn(),super.handleMouseUp(t)}lr(t){let i=this.ks,s=(t-Jo(i))/Qo(i);return Yt(s,0,1)}dispose(){this.Fn.Ve(),A(this.playingStates)}constructor(t,i){super(t,i),this.playingStates=[],this.on(t,"emptied",this.update),this.on(t,"seeking",this.update),this.Fn=new Ka(this.el(),t)}};zo.registerComponent("SeekBar",eu);var nu=zo.getComponent("ProgressControl");Ct.Zs.Ks&&zo.registerComponent("ProgressControl",class extends nu{createEl(){return super.createEl("div",{className:"vjs-progress-control vjs-control"})}handleMouseMove(t){this.seekBar.handleMouseMove(t)}handleMouseDown(t){this.seekBar.handleMouseDown(t)}constructor(t,i){super(t,i),this.on(this,"touchmove",this.handleMouseMove),this.on("touchstart",this.handleMouseDown),this.seekBar.off(["touchmove","touchstart"])}});var ru=zo.getComponent("TooltipProgressBar"),hu=class extends(n(ru)){updateDataAttr(){let t=Go(this.player()),i=this.Sn(t);this.el().setAttribute("data-current-time",i),this.tooltip.innerHTML=i}Sn(t){const i=this.ks;return Ko(t-Xo(i),Qo(i))}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-tooltip-progress-bar vjs-slider-bar "+super.buildCSSClass()}constructor(t,i){super(t,i)}};function ou(t){for(const i of t)if(i.enabled)return i}function au(t){if(t)return t.label&&""!==t.label?{name:t.label,hd:!1}:{name:uu(t),description:cu(t),hd:!!t.height&&t.height>=720}}function uu(t){return t.height?t.height+"p":t.bandwidth?cu(t):""}function cu(t){return t.bandwidth?t.bandwidth>1e7?(t.bandwidth/1e6).toFixed(0)+"Mbps":t.bandwidth>1e6?(t.bandwidth/1e6).toFixed(1)+"Mbps":(t.bandwidth/1e3).toFixed(0)+"kbps":""}zo.registerComponent("TooltipProgressBar",hu);var lu=class{get dr(){return this.pr}set dr(t){let i=this.pr;for(let s=i.length-1;s>=0;s--){let e=i[s];C(t,e)||this.mr(e)}for(let i of t)this.gr(i);this.yr.oe()}get br(){return this.yr.menuItems}wr(t){let i=this.br;if(i)for(let s of i)if(s.kr===t)return s}_r(t){let i=this.yr.addMenuItem();return i.kr=t,i.on("click",(()=>this.jr(i))),i.el().setAttribute("role","menuitemradio"),i}Sr(t){t.dispose()}Tr(t){return!0}gr(t){if(this.Tr(t)){C(this.pr,t)||this.pr.push(t);let i=this.wr(t)||this._r(t);return this.Cr(i),i}this.mr(t)}mr(t){let i=this.wr(t);i&&(this.yr.removeMenuItem(i),this.Sr(i)),zi(this.pr,t)}Ve(){const t=[];for(let i of this.pr)t.push(i);for(let i of t)this.mr(i);A(t)}constructor(t){this.pr=[],this.yr=t}},fu=class extends lu{Pr(){return this.Ar=h.createElement("span"),this.Ar.className="theo-settings-control-menu-item-title",Et(this.Ar,this.Mr.localize("Quality")),this.Ar}Ir(){return this.Er=h.createElement("span"),this.Er.className="theo-settings-control-menu-quality-automatic",Et(this.Er,this.Mr.localize("Automatic")),this.Er}Dr(){return this.Nr=h.createElement("span"),Et(this.Nr,this.Mr.localize("Automatic")),this.Nr}Fr(){return this.$r=h.createElement("span"),this.$r.className="theo-primary-color theo-settings-control-menu-item-hd-label",Et(this.$r,this.Mr.localize("HD")),this.$r}Br(){let t=h.createElement("span");t.className="theo-primary-color theo-settings-control-menu-item-value",t.appendChild(this.Er),t.appendChild(h.createTextNode(" ")),t.appendChild(this.Nr),t.appendChild(h.createTextNode(" ")),t.appendChild(this.$r),this.Rr.el().appendChild(this.Ar),this.Rr.el().appendChild(t),this.Rr.el().setAttribute("aria-label",this.Mr.localize("Open the video quality settings menu"))}Or(){let t=this.Vr,i=t&&bu(t.targetQuality),s=t&&t.activeQuality,e=au(this.Lr(i||s))||{name:this.Mr.localize("Automatic")};Et(this.Nr,e.name),yi(this.Er,"vjs-hidden",!!i),yi(this.$r,"vjs-hidden",!e.hd)}Cr(t){let i=au(t.kr)||{name:this.Mr.localize("Automatic")},s=i.name;i.hd&&(s+='<span class="theo-primary-color theo-settings-control-menu-item-hd-label">'+this.Mr.localize("HD")+"</span>"),i.description&&(s+='<span class="theo-settings-control-submenu-item-alternate-value">'+i.description+"</span>"),t.el().innerHTML=s,t.el().setAttribute("aria-label",this.Mr.localize("Set video quality to ")+i.name),t.kr?t.selected(t.kr===this.Ur):t.selected(!this.Ur)}jr(t){this.Vr&&(this.Vr.targetQuality=t.kr&&t.kr.videoQualities)}Lr(t,i){const s=i||this.dr;for(let i of s)if(t&&i&&-1!==i.videoQualities.indexOf(t))return i}Ve(){this._s.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.Hr),this.Mr.off("languagechange",this.se),this.Vr&&(this.Vr.removeEventListener("activequalitychanged",this.zr),this.Vr.removeEventListener("targetqualitychanged",this.Wr),this.Vr.removeEventListener("update",this.qr)),super.Ve()}constructor(t,i,s){super(t.subMenu),this.Vr=void 0,this.Ur=void 0,this.Hr=()=>{let t=ou(this._s.videoTracks);if(t===this.Vr)return;let i=[];if(this.Vr&&(this.Vr.removeEventListener("activequalitychanged",this.zr),this.Vr.removeEventListener("targetqualitychanged",this.Wr),this.Vr.removeEventListener("update",this.qr)),this.Vr=t,t){t.addEventListener("activequalitychanged",this.zr),t.addEventListener("targetqualitychanged",this.Wr),t.addEventListener("update",this.qr);const s=vu(gu(t.qualities.filter((t=>t.available))));i=s.length>1?[void 0,...s]:[void 0]}this.dr=i,this.Wr(),this.zr()},this.qr=t=>{const i=t.track;if(i!==this.Vr)return;const s=vu(gu(i.qualities.filter((t=>t.available)))),e=i&&bu(i.targetQuality);let n;this.Ur=this.Lr(e,s),n=s.length>1?[void 0,...s]:[void 0],this.dr=n,this.Or()},this.zr=()=>{this.gr(void 0),this.Or()},this.Wr=()=>{let t=ou(this._s.videoTracks),i=t&&bu(t.targetQuality),s=this.Lr(i),e=this.Ur;s!==e&&(this.Ur=s,s&&e||this.gr(void 0),e&&C(this.dr,e)&&this.gr(e),i&&this.gr(s),this.Or())},this.se=()=>{Et(this.yr.menuHeader.el(),this.Mr.localize("Quality")),Et(this.Ar,this.Mr.localize("Quality")),Et(this.Er,this.Mr.localize("Automatic")),Et(this.Nr,this.Mr.localize("Automatic")),Et(this.$r,this.Mr.localize("HD")),this.Rr.el().setAttribute("aria-label",this.Mr.localize("Open the video quality settings menu"));for(const t of this.br)this.Cr(t);this.Or()},this.Rr=t,this._s=i,this.Mr=s,this.Ar=this.Pr(),this.Er=this.Ir(),this.Nr=this.Dr(),this.$r=this.Fr(),this.Br(),Et(this.yr.menuHeader.el(),this.Mr.localize("Quality")),this.dr=[void 0],this._s.videoTracks.addEventListener(["addtrack","removetrack","change"],this.Hr),this.Mr.on("languagechange",this.se),this.Hr()}},du=class{get height(){return this.Gr[0].height}get bandwidth(){return this.Gr[0].bandwidth}get videoQualities(){return this.Gr}get label(){return this.Gr[0].label}add(t){this.Gr.push(t)}constructor(t){this.Gr=t}};function vu(t){let i=[];for(let s of t){let t=s,e=!1;for(let s of i)if(yu(s,t)){s.add(t),e=!0;break}e||i.push(new du([t]))}return i}function pu(t,i){return t&&i?Vi(t,i):Ri.Xr}function mu(t,i){return t===i?Ri.Xr:pu(t.height,i.height)||pu(t.width,i.width)||pu(t.bandwidth,i.bandwidth)}function gu(t){return $i(t,mu).reverse()}function yu(t,i){return t.label&&i.label&&t.label===i.label||Z(au(t),au(i))}function bu(t){return $t(t)?1===t.length?t[0]:void 0:t}function wu(t){return 1===t?"Normal":""+w.round(100*t)/100}var ku=class extends lu{Pr(){return this.Ar=h.createElement("span"),this.Ar.className="theo-settings-control-menu-item-title",Et(this.Ar,this.Mr.localize("Speed")),this.Ar}Br(){const t=h.createElement("span");return t.className="theo-primary-color theo-settings-control-menu-item-value",this.Rr.el().appendChild(this.Ar),this.Rr.el().appendChild(t),this.Rr.el().setAttribute("aria-label",this.Mr.localize("Open the video speed settings menu")),t}_r(t){let i=super._r(t);return this.Cr(i),i}Cr(t){const i=t.kr,s=this.Mr.localize(wu(i));Et(t.el(),s),t.el().setAttribute("aria-label",this.Mr.localize("Set video speed to ")+s),t.selected(t.kr===this._s.playbackRate)}jr(t){this._s.playbackRate=t.kr}Ve(){this._s.removeEventListener("ratechange",this.Jr),this.Mr.off("languagechange",this.se),super.Ve()}constructor(t,i,s,e){super(t.subMenu),this.Qr=void 0,this.Jr=()=>{this.Qr&&this.gr(this.Qr);let t=this._s.playbackRate;this.Qr=t,Et(this.Yr,this.Mr.localize(wu(t))),t&&this.gr(t)},this.se=()=>{Et(this.yr.menuHeader.el(),this.Mr.localize("Speed")),Et(this.Ar,this.Mr.localize("Speed")),this.Rr.el().setAttribute("aria-label",this.Mr.localize("Open the video speed settings menu"));for(const t of this.br)this.Cr(t);this.Jr()},this.Rr=t,this._s=i,this.Mr=s,this.Ar=this.Pr(),this.Yr=this.Br(),Et(this.yr.menuHeader.el(),this.Mr.localize("Speed")),this.dr=e,this._s.addEventListener("ratechange",this.Jr),this.Mr.on("languagechange",this.se),this.Jr()}};zo.registerComponent("SettingsButton",class extends Ca{createEl(){let t=super.createEl();return this.Kr=zo.createEl("span",{className:"theo-settings-control-label-hd theo-primary-background"}),Et(this.Kr,this.localize("HD")),t.appendChild(this.Kr),t}buildCSSClass(){return"vjs-icon-cog theo-settings-control-button "+super.buildCSSClass()}se(){super.se(),Et(this.Kr,this.localize("HD")),Et(this.menu.menuHeader.el(),this.localize("Settings"))}dispose(){this.Vr&&(this.Vr.removeEventListener("activequalitychanged",this.zr),this.Vr=void 0),this.ks.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.Zr),this.th.Ve(),this.ih.Ve(),super.dispose()}constructor(t,i){var s,e;super(t,i),this.Vr=void 0,this.Zr=()=>{let t=ou(this.ks.videoTracks);t!==this.Vr&&(this.Vr&&this.Vr.removeEventListener("activequalitychanged",this.zr),this.Vr=t,t&&t.addEventListener("activequalitychanged",this.zr),this.zr())},this.zr=()=>{var t;const i=null==(t=this.Vr)?void 0:t.activeQuality,s=!!(i&&i.height>=720);this.player().toggleClass("theo-hd",s)},fi(this.menu.el(),"theo-settings-control-menu"),Et(this.menu.menuHeader.el(),t.localize("Settings")),this.controlText("Settings"),this.$e.Fe=this.controlText(),this.sh=this.menu.addSubMenuItem({name:"QualityMenuItem"}),this.th=new fu(this.sh,this.ks,t);let n=null!=(e=null==i||null==(s=i.playerOptions)?void 0:s.playbackRates)?e:[];this.eh=this.menu.addSubMenuItem({name:"PlaybackRateMenuItem"}),this.ih=new ku(this.eh,this.ks,t,n),this.ks.videoTracks.addEventListener(["addtrack","removetrack","change"],this.Zr),this.Zr()}});var _u=class extends lu{nh(t){let i=t.label;if(i)return i;let s=t.language;if(s){let t=wi(s);if(t)return t.rh}return s||""}hh(){this.dr=this.oh}Ve(){this.oh.removeEventListener("addtrack",this.ah),this.oh.removeEventListener("removetrack",this.uh),this.oh.removeEventListener("change",this.lh),super.Ve()}constructor(t,i){super(t),this.ah=t=>{const i=t.track;this.gr(i),i.addEventListener("update",this.fh)},this.uh=t=>{const i=t.track;this.mr(i),i.removeEventListener("update",this.fh)},this.lh=t=>this.hh(),this.fh=()=>{for(const t of this.dr)this.gr(t)},this.oh=i,this.oh.addEventListener("addtrack",this.ah),this.oh.addEventListener("removetrack",this.uh),this.oh.addEventListener("change",this.lh),this.hh()}},ju=class extends _u{Cr(t){let i=t.kr,s=this.Mr.localize(this.nh(i));Et(t.el(),s),t.el().setAttribute("aria-label",this.Mr.localize("Set the audio language to")+" "+s),t.selected(i.enabled)}jr(t){let i=t.kr;for(let t of this.ks.audioTracks)t!==i&&(t.enabled=!1);i.enabled=!0}Ve(){this.Mr.off("languagechange",this.se),super.Ve()}constructor(t,i,s){super(t,i.audioTracks),this.se=()=>{Et(this.yr.menuHeader.el(),this.Mr.localize("Language"));for(const t of this.br)this.Cr(t)},this.ks=i,this.Mr=s,Et(this.yr.menuHeader.el(),this.Mr.localize("Language")),this.Mr.on("languagechange",this.se)}};zo.registerComponent("audioTrackButton",class extends Ca{buildCSSClass(){return"vjs-icon-audio theo-audio-track-control-button "+super.buildCSSClass()}dispose(){this.dh.Ve(),super.dispose()}constructor(t,i){super(t,i),this.minimumMenuItems=2,this.dh=new ju(this.menu,this.ks,t),this.controlText("Language"),this.$e.Fe=this.controlText()}});var xu=class extends _u{Tr(t){return!!super.Tr(t)&&(!t.forced&>(t.kind))}_r(t){let i=super._r(t);fi(i.el(),"theo-text-track-menu-item");let s=h.createElement("span");i.ph=s;let e=h.createElement("div");e.className="theo-text-track-menu-item-toggle",i.mh=e;let n=t=>this.gh(t,i);i.yh=n,e.addEventListener("click",n);let r=h.createElement("div");return r.className="theo-text-track-menu-item-toggle-slider",e.appendChild(r),i.el().appendChild(s),i.el().appendChild(e),i}Cr(t){let i=t,s=i.kr,e=this.Mr.localize(this.nh(s));Et(i.ph,e),i.el().setAttribute("aria-label",this.Mr.localize("Set the subtitle language to")+" "+e),i.el().setAttribute("role","menuitemcheckbox"),i.selected(s.mode===ut.Hn)}Sr(t){let i=t;i.mh.removeEventListener("click",i.yh),super.Sr(t)}jr(t){let i=t.kr;for(let t of this.ks.textTracks)t!==i&&pt(t.kind,i.kind)&&(t.mode=ut.bh);i.mode!==ut.Hn?i.mode=ut.Hn:i.mode=ut.bh}gh(t,i){t.stopImmediatePropagation(),this.jr(i)}Ve(){this.Mr.off("languagechange",this.se),super.Ve()}constructor(t,i,s){super(t,i.textTracks),this.se=()=>{Et(this.yr.menuHeader.el(),this.Mr.localize("Subtitles"));for(const t of this.br)this.Cr(t)},this.ks=i,this.Mr=s,Et(this.yr.menuHeader.el(),s.localize("Subtitles")),this.Mr.on("languagechange",this.se)}};zo.registerComponent("subtitlesButton",class extends Ca{buildCSSClass(){return"vjs-icon-subtitles theo-text-track-control-button "+super.buildCSSClass()}dispose(){this.dh.Ve(),super.dispose()}constructor(t,i){super(t,i),this.dh=new xu(this.menu,this.ks,t),this.controlText("Subtitles"),this.$e.Fe=this.controlText()}});var Su,Tu=zo.getComponent("playToggle");!function(t){t.wh="Pause",t.kh="Play",t._h="Replay"}(Su||(Su={}));var Cu=class extends(n(Tu)){handleClick(t){this.ks.muted||this.ks.prepareWithUserAction(),super.handleClick(t)}handlePlay(t){super.handlePlay(t),this.controlText("Pause"),this.$e.Fe=this.controlText()}handlePause(t){this.ks.ended||(super.handlePause(t),this.controlText("Play"),this.$e.Fe=this.controlText())}se(){this.$e.Fe=this.controlText()}dispose(){this.$e.Ve(),this.ks.removeEventListener("ended",this.jh),super.dispose()}constructor(t,i){super(t,i),this.jh=()=>{this.controlText("Replay"),this.$e.Fe=this.controlText()},this.controlText("Play"),this.$e=new Sa(this,this.controlText()),this.ks.addEventListener("ended",this.jh),this.on(t,"languagechange",this.se),Ct.Zs.Ye&&new fa(this.el())}};zo.registerComponent("playToggle",Cu);var Pu,Au=zo.getComponent("fullscreenToggle");!function(t){t.xh="Exit fullscreen",t.Sh="Fullscreen"}(Pu||(Pu={}));var Mu=class extends(n(Au)){handleClick(t){this.ks.prepareWithUserAction(),super.handleClick(t)}handleFullscreenChange(t){super.handleFullscreenChange(t),this.updateContent()}updateContent(){const t=this.player().isFullscreen()?"Exit fullscreen":"Fullscreen";this.controlText(t),this.$e.Fe=this.controlText()}dispose(){this.$e.Ve(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Fullscreen"),this.$e=new Sa(this,this.controlText()),Ct.Zs.Ye&&new fa(this.el()),this.on(t,"languagechange",this.updateContent)}};zo.registerComponent("fullscreenToggle",Mu);var Iu,Eu=zo.getComponent("muteToggle");!function(t){t.Th="Unmute",t.Ch="Mute"}(Iu||(Iu={}));var Du=class extends(n(Eu)){handleClick(t){this.ks.muted&&!this.ks.paused&&this.ks.prepareWithUserAction(),super.handleClick(t)}update(t){super.update(t),this.se()}se(){const t=this.player().muted()?"Unmute":"Mute";this.controlText(t),this.$e.Fe=this.controlText()}dispose(){this.$e.Ve(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Mute"),this.$e=new Sa(this,this.controlText()),Ct.Zs.Ye&&new fa(this.el()),this.on(t,"languagechange",this.se),Ci&&(this.removeClass("vjs-hidden"),this.on(t,"loadstart",(()=>{this.removeClass("vjs-hidden")})))}};zo.registerComponent("muteToggle",Du);var Nu=zo.getComponent("BigPlayButton"),Fu=class extends(n(Nu)){createEl(){let t=super.createEl(),i=zo.createEl("div",{className:"theo-big-play-button-svg-container"});return i.innerHTML='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 150 150" fill="currentColor">\n <circle cx="75" cy="75" r="73" fill="#000" fill-opacity="0.2"></circle>\n <circle cx="75" cy="75" r="73" class="theo-play-svg-circle" stroke-width="4" stroke="currentColor" fill="none" transform="rotate(-90,75,75)"></circle>\n <g transform="translate(85,75) scale(0.5625) translate(-75,-75)">\n <path d="m 123.89639,85.432 c -12.865,9.167 -29.482997,19.402 -49.848997,30.7 -19.634,11.035 -36.851,19.7 -51.65,26 l -16.3990002,6.099 c -1.033,-4.433 -2,-11.002 -2.9,-19.7 -2.033,-17.333 -3.04999998,-36.466 -3.04999998,-57.399 0,-19.167 1.38199998,-37.081 4.14799998,-53.75 l 4.0019995,-19.1499994 17.3990007,5.849 c 15.068,5.9999994 31.401,14.5169994 49,25.5509994 18.631,11.666 34.616997,22.766 47.948997,33.3 6.663,5.3 11.463,9.383 14.396,12.25 l -13.046,10.25"></path>\n </g>\n</svg>',t.appendChild(i),t}buildCSSClass(){return"theo-primary-color "+super.buildCSSClass()}handleClick(t){this.ks.muted||this.ks.prepareWithUserAction(),super.handleClick(t),void 0!==this.ks.vr&&"unavailable"!==this.ks.vr.state&&(this.ks.vr.useDeviceMotionControls=!0)}};zo.registerComponent("BigPlayButton",Fu);var $u=/^([^#]*)#xywh=(\d+),(\d+),(\d+),(\d+)\s*$/;zo.registerComponent("MouseTimeDisplay",class extends Ga{Ph(t){const i=t.track;"metadata"===i.kind&&"thumbnails"===i.label&&void 0===this.Ah&&(this.Ah=i,this.Mh=i.src?Ct.Ih(i.src).href:void 0,this.Ah.addEventListener(["addcue","removecue"],this.Eh),this.Dh())}Nh(t){t.track===this.Ah&&this.Fh()}createEl(){const t=super.createEl();return this.$h=zo.createEl("img",{className:"theo-time-tooltip-thumbnail"}),this.Bh=zo.createEl("canvas",{className:"theo-time-tooltip-thumbnail"}),t}update(t,i){super.update(t,i),this.keepTooltipsInside&&this.Rh(t)}Rh(t){let i;if(this.Ah&&this.Ah.cues){let s=function(t,i){let s=t[0];for(let e of t)if(e.startTime<=i)s=e;else if(i>=e.endTime)return s;return s}(this.Ah.cues,t);i=s&&s.content}if(i===this.Oh)return;if(this.Oh=i,zo.toggleClass(this.el(),"theo-time-tooltip-has-thumbnail",!!i),!i)return void this.Vh();const s=i.match($u);if(s){let[,t,i,e,n,r]=s;t=this.Lh(t);const h={Uh:+i,Hh:+e,Ti:+n,Ci:+r};this.zh(t,h)}else{const t=this.Lh(i);this.zh(t)}}Dh(){j(this.xn)||this.Rh(this.xn)}Lh(t){return this.Ah&&this.Mh?Ct.Ih(t,this.Mh).href:t}zh(t,i){this.$h&&(this.$h.src!==t?(this.$h.onload=()=>{this.Wh(i)},this.$h.src="",this.$h.src=t):this.Wh(i))}Wh(t){if(!this.Bh||!this.$h)return;const i=this.Bh.getContext("2d");i&&(null!=t||(t={Uh:0,Hh:0,Ti:this.$h.naturalWidth,Ci:this.$h.naturalHeight}),this.Bh.width=t.Ti,this.Bh.height=t.Ci,i.drawImage(this.$h,t.Uh,t.Hh,t.Ti,t.Ci,0,0,t.Ti,t.Ci),this.qh(this.Bh))}qh(t){this.Gh||(this.tooltip.firstChild?this.tooltip.insertBefore(t,this.tooltip.firstChild):this.tooltip.appendChild(t),this.Gh=t),this.Tn()}Vh(){this.Gh&&(this.tooltip.removeChild(this.Gh),this.Gh=void 0,this.Tn())}Fh(){void 0!==this.Ah&&(this.Ah.removeEventListener(["addcue","removecue"],this.Eh),this.Ah=void 0),this.Mh=void 0,this.Vh(),this.Oh=void 0}dispose(){this.Fh(),super.dispose()}constructor(t,i){super(t,i),this.Gh=void 0,this.Ah=void 0,this.Mh=void 0,this.Xh=t=>this.Ph(t),this.Jh=t=>this.Nh(t),this.Eh=t=>this.Dh(),this.showThumbnails=()=>{this.Gh&&this.Gh.hidden&&(this.Gh.hidden=!1,this.Tn())},this.hideThumbnails=()=>{!this.Gh||this.Gh.hidden||this.player().scrubbing()||(this.Gh.hidden=!0,this.Tn())},this.on(this.player().textTracks(),"addtrack",this.Xh),this.on(this.player().textTracks(),"removetrack",this.Jh),Mt.Ks&&(this.on(t,"seeking",this.showThumbnails),this.on(t,"seeked",this.hideThumbnails))}});var Bu=zo.getComponent("VolumeLevel");zo.registerComponent("VolumeLevel",class extends Bu{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-volume-level "+super.buildCSSClass()}});var Ru=zo.getComponent("Component"),Ou=class extends Ru{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-menu-container "+super.buildCSSClass()}};Ou.prototype.h=Di({},Ou.prototype.h,{children:[]}),zo.registerComponent("controlBarMenuContainer",Ou);var Vu=zo.getComponent("Player"),Lu=class extends Vu{dispose(){const t=this.el(),i=this.contentEl(),s=t.parentNode,e=t.nextSibling;super.dispose(),hi(i),this.xi&&s&&(e?s.insertBefore(t,e):s.appendChild(t)),h.body.removeEventListener("keydown",this.handleKeyPress),h.body.removeEventListener("click",this.handleClick)}constructor(t,i,s){super(t,i,s),this.handleKeyPress=t=>{9===t.which&&this.addClass("theo-probably-keyboard-focus")},this.handleClick=t=>{0===t.x&&0===t.y||this.removeClass("theo-probably-keyboard-focus")},h.body.addEventListener("keydown",this.handleKeyPress),h.body.addEventListener("click",this.handleClick)}};Lu.prototype.h=Di({},Vu.prototype.h,{children:["bigPlayButton","AdControlPanel","TopControlBar","mediaLoader","upNextContainer","posterImage","chromecastOverlay","upcomingAdNotificationText","controlBarMenuContainer","controlBar","textTrackDisplay","loadingSpinner","errorDisplay","textTrackSettings","xrCompass"]}),zo.registerComponent("Player",Lu);var Uu=zo.getComponent("Player"),Hu=Uu.prototype.es;Uu.prototype.es=function(t){if(!(this.H&&this.H.Vs&&this.H.Vs()))return Hu.call(this,t)};var zu=Uu.prototype.createEl;function Wu(t,i,s,e){let n=Di({controls:!0,playbackRates:[.25,.5,1,1.25,1.5,2]},s);n.controlBar=Di({progressControl:{keepTooltipsInside:!0}},n.controlBar);let r=n.techOrder||(n.techOrder=[]);-1===r.indexOf("THEOplayer")&&r.unshift("THEOplayer"),(n.theoplayer||(n.theoplayer={})).player=t,s&&Ot(s.language)&&(n.languages=Di({},n.languages,{[gi]:s.language}),n.language=gi),i.setAttribute("data-vjs-player","");let h=i.getAttribute("style"),o=zo(t.element,n,e);return o.ready((()=>{ta(o),function(t,i){if(i){if(i.ads){const s=i=>{const s="adbreakbegin"===i.type,e=i.adBreak.integration===Ti.Qh;ea(t,s,e)};i.ads.addEventListener("adbreakbegin",s),i.ads.addEventListener("adbreakend",s)}if(i.verizonMedia){const s=i=>{const s="adbreakbegin"===i.type;ea(t,s,!1)};i.verizonMedia.ads.adBreaks.addEventListener("addadbreak",(t=>{t.adBreak.addEventListener("adbreakbegin",s),t.adBreak.addEventListener("adbreakend",s)}))}i.addEventListener("sourcechange",(()=>{ea(t,!1,!1)}))}}(o,t),function(t){t.on("mouseleave",na)}(o)})),i.removeAttribute("data-vjs-player"),h?i.setAttribute("style",h):i.removeAttribute("style"),Ct.Zs.Ks&&(fi(i,"theo-mobile"),qu(i)),function(t){t.on("seeking",(()=>{ui(t.el(),"vjs-ended")&&t.currentTime()!==t.duration()&&t.play()}))}(o),o}function qu(t){a.outerHeight>a.outerWidth?(pi(t,"theo-mobile-landscape"),fi(t,"theo-mobile-portrait")):(pi(t,"theo-mobile-portrait"),fi(t,"theo-mobile-landscape"))}Uu.prototype.createEl=function(){let t=zu.call(this),i=zo.createEl("div");for(i.className="theo-player-wrapper";t.firstChild;)i.appendChild(t.firstChild);return t.appendChild(i),this.S=i,t};var Gu=zo.getComponent("Button");var Xu="THEOPiPCloseButton";zo.registerComponent(Xu,class extends Gu{buildCSSClass(){return"theo-close-button theo-pip-close"}handleClick(){this.Kh.Yh()}constructor(t,i){if(super(t,i),this.controlText("Close Picture-in-Picture"),!function(t){return!!t&&Boolean(t.Kh)}(i))throw new v("Invalid Picture-in-picture options.");this.Kh=i.Kh}});var Ju,Qu=class extends F{get Zh(){return this.io}get so(){return this.t.cs()}eo(){this.t.dn(W.kh,this.no),this.ro||this.t.dn(W.ho,this.oo),this.t.ao.on("languagechange",this.se)}uo(){let t=this.co;if(t)return"theo-pip-"+t}lo(t){let i=this.fo;if(i&&!this.so){this.do||this.vo(),this.po(),fi(i,"theo-pip");let s=this.uo();s&&fi(i,s),this.io=!0,this.mo=t,this.yo=!1,this.bo(new Li(Hi.PICTURE_IN_PICTURE))}}wo(t){let i=this.fo;if(i){this.ko(),pi(i,"theo-pip");let s=this.uo();s&&pi(i,s),this.io=!1,this.yo=t,this._o=this.mo,this.mo=!1,this.bo(new Li(Hi.INLINE))}}vo(){if(!this.do){let t=this.t.ao;t.addChild(Xu,{Kh:this});let i=h.createElement("div");i.className="theo-pip-overlay",this.jo=h.createElement("div"),this.jo.className="theo-pip-overlay-text",Et(this.jo,t.localize("Video playing in Picture-in-Picture mode")),i.appendChild(this.jo),t.el().appendChild(i),this.xo=i,this.do=!0}}So(){this.To&&!this.Co&&this.t.Po&&(this.Ao=this.t.Po.Mo(Ft,this.Io),this.Co=!0)}Eo(){this.Ao&&this.t.Po&&(this.t.Po.Do(this.Ao),this.Co=!1)}po(){let t=this.t.ao.contentEl(),i=t.getBoundingClientRect(),s=h.documentElement.clientWidth,e=h.documentElement.clientHeight;t.style.top=i.top+"px",t.style.bottom=e-i.bottom+"px",t.style.right=s-i.right+"px",t.style.left=i.left+"px",t.style.width=i.width+"px",t.style.height=i.height+"px",t.style.position="fixed"}ko(){let t=this.t.ao.contentEl();t.style.top="",t.style.bottom="",t.style.right="",t.style.left="",t.style.width="",t.style.height="",t.style.position=""}No(){pi(this.fo,"theo-pip"),this.Zh&&this.co&&pi(this.fo,"theo-pip-"+this.co),this.xo&&(hi(this.xo),this.xo=void 0)}fn(){this.No(),this.Eo(),this.Fo(),this.t.an(W.kh,this.no),this.t.an(W.ho,this.oo),this.t.ao.off("languagechange",this.se),this.t=void 0}constructor(t,i,s){super(),this.$o=!1,this.io=!1,this.yo=!1,this.mo=!1,this.do=!1,this.Co=!1,this._o=!1,this.no=()=>{this.$o=!0,this.To&&!this.Zh&&this.Ao&&this.Bo&&this.Ao.Ro<=this.Bo&&this.lo(!1)},this.oo=()=>{this.ro||(this.$o=!1,this.wo(!1))},this.se=()=>{if(this.jo){const t=this.t.ao;Et(this.jo,t.localize("Video playing in Picture-in-Picture mode"))}},this.Io=t=>{!this.mo&&this.To&&(j(t)||(this.Bo&&t<=this.Bo||this._o?this.io||this.yo||this.lo(!1):this.io?this.wo(!1):this.yo=!1))},this.Bo=i.visibility,this.co=i.position,this.ro=i.retainPresentationModeOnSourceChange,this.To=void 0!==this.Bo,this.t=t,this.fo=t.Oo,this.Yh=s,this.eo()}},Yu=class extends Wi{Vo(){let t=super.Vo();return t===Hi.INLINE&&this.Lo&&this.Lo.Zh?Hi.PICTURE_IN_PICTURE:t}Uo(t){return t===Hi.PICTURE_IN_PICTURE||super.Uo(t)}Ho(t,i){t===Hi.FULLSCREEN&&this.Lo.Eo(),super.Ho(t,i),t!==Hi.FULLSCREEN&&this.Lo.So()}zo(t,i){t!==i&&(t===Hi.FULLSCREEN&&this.Lo.wo(!1),t===Hi.INLINE&&i===Hi.PICTURE_IN_PICTURE&&this.Lo.wo(!0),super.zo(t,i),t===Hi.PICTURE_IN_PICTURE&&(i===Hi.INLINE?this.Lo.lo(!0):this.Lo.lo(!1)))}fn(){super.fn(),this.Lo.fn(),this.Wo.an(W.kh,this.qo),this.Wo=void 0}constructor(t,i,s){super(i),this.Go=()=>this.qr(),this.Yh=()=>this.Xo(Hi.INLINE),this.qo=()=>{this.Vo()!==Hi.FULLSCREEN&&this.Lo.So(),this.Wo.an(W.kh,this.qo)},this.Wo=t,this.Lo=new Qu(t,s.pip,this.Yh),this.Lo.dn("presentationmodechange",this.Go),this.Wo.dn(W.kh,this.qo),this.qr()}},Ku=class extends F{get Jo(){return tt.Qo(this.ao.el())||this.ao.supportsFullScreen()}get cs(){return this.ao.isFullscreen()||this.Yo}lo(){this.ao.requestFullscreen()}wo(){this.ao.exitFullscreen(),this.Ko.wo()}fn(){this.Fo(),this.ao.off("fullscreenchange",this.Zo),this.Ko.an(Oi.ta,this.Zo),this.Ko.an(Oi.ia,this.Os),this.ao.isFullWindow&&this.ao.exitFullscreen()}constructor(t,i){super(),this.Ls=!1,this.Yo=!1,this.sa=!1,this.Zo=()=>{if(this.sa)return;let t=this.Ls,i=this.cs;t!==i&&(this.Ls=i,this.bo(new Q))},this.ea=()=>{this.Yo=this.Ko.cs,this.Zo()},this.na=()=>{this.sa||(this.ao.isFullWindow&&this.ao.supportsFullScreen()||this.Yo&&!this.ao.supportsFullScreen())&&(this.sa=!0,this.ao.exitFullscreen(),this.ao.requestFullscreen(),this.sa=!1,this.Zo())},this.ao=t,this.Ko=i,this.ao.on("fullscreenchange",this.Zo),this.Ko.dn(Oi.ta,this.ea),this.Ko.dn(Oi.ra,this.na),this.Ko.dn(Oi.ia,this.Os),this.Zo()}};function Zu(t){return class extends t{get Po(){return this.ha}cs(){return"fullscreen"===this.oa.Vo()}aa(){return function(t,i){let s=g.create(t);const e=i.ao;return Y(s,{get controls(){return e.controls()},set controls(t){e.controls(it(t))},get presentation(){return i.oa.ua},get presentationMode(){return i.oa.Vo()},set presentationMode(t){const s=P(t);s&&i.oa.Xo(s)},get ui(){return e},get visibility(){return i.Po.ua}})}(this.ca,this)}fn(){super.fn(),this.oa.fn(),this.la.fn(),this.ao.dispose(),this.ha.fn()}fa(t){this.ao.src(""),super.fa(t)}constructor(t,i,s){super(i,s),this.Oo=t,this.ha=new Rt(t),this.ca=super.aa(),g.defineProperty(this.ca,"constructor",{value:Qt}),this.ao=Wu(this.ca,this.Oo,s.ui),this.la=new Ku(this.ao,this.da),this.oa=new Yu(this,this.la,s),this.oa.dn("presentationmodechange",this.Os)}}}function tc(t){return(t=t||{}).position=function(t){switch(t){case"top-left":case"top-right":case"bottom-left":case"bottom-right":return t;default:return}}(t.position),t.visibility=function(t){if(Dt(t)&&!j(t))return Yt(t,0,1)}(t.visibility),t.retainPresentationModeOnSourceChange=it(t.retainPresentationModeOnSourceChange),t}function ic(t){const i=Ni(t);return i.ui=i.ui||{},void 0!==(null==t?void 0:t.width)&&void 0===i.ui.width&&(i.ui.width=t.width),void 0!==(null==t?void 0:t.height)&&void 0===i.ui.height&&(i.ui.height=t.height),void 0!==(null==t?void 0:t.fluid)&&void 0===i.ui.fluid&&(i.ui.fluid=t.fluid),i.pip=tc(i.pip),i}function sc(){return Ju||(Ju=function(t){let i=t;for(const t of qi)i=t(i);return i}(Ju=Zu(Gt()))),Ju}function ec(t,i){const s=ic(i),e=h.createElement("div");e.style.position="absolute",t.appendChild(e);const n=new(sc())(t,e,s);n.va=n;let r=n.ua;return n.pa(),n.ma(Lt),g.defineProperty(r,"constructor",{value:ec}),r=J(r),qt(n),function(t){for(const i of Gi)i(t)}(n),r}var nc="theo-cast-",rc=zo.getComponent("Button"),hc=class extends(n(rc)){get ga(){throw new v("ya")}get ba(){return this.h.ba}get wa(){return this.h.wa}buildCSSClass(){return nc+"button theo-"+this.wa+"-button theo-controlbar-button "+super.buildCSSClass()}createEl(t,i,s){const e=super.createEl(),n=h.createElement("div");n.className="theo-button-icon-blur";const r=h.createElement("div");return r.className=nc+"svg-container",r.innerHTML=this.ba,e.appendChild(n),e.appendChild(r),e}handleClick(t){var i;if(super.handleClick(t),this.ka===M.AVAILABLE)null==(i=this.ga)||i.start();else if(this.ka===M.CONNECTED||this.ka===M.CONNECTING){var s;null==(s=this.ga)||s.stop()}}_a(t){pi(this.fo,"theo-"+this.wa+"-"+this.ka),this.ka=t,fi(this.fo,"theo-"+this.wa+"-"+this.ka),this.se()}se(){this.ja(this.ka),this.$e.Fe=this.controlText()}ja(t){t===M.CONNECTED?this.controlText("Stop Casting"):t===M.AVAILABLE?this.controlText("Start Casting"):t===M.CONNECTING?this.controlText("Connecting"):this.controlText("Unavailable")}constructor(t,i){var s;super(t,i),this.fo=t.el(),this.ka=M.UNAVAILABLE,this.controlText("Unavailable"),this.$e=new Sa(this,this.controlText()),null==(s=this.ga)||s.addEventListener("statechange",(t=>{const i=t;this._a(i.state)})),Ct.Zs.Ye&&(this.xa=new fa(this.el())),this._a(this.ga?this.ga.state:M.UNAVAILABLE),this.on(t,"languagechange",this.se)}},oc=0;function ac(){const t='\n <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48" fill="currentColor">\n <defs>\n <clipPath id="theo-chromecast-rings-mask-'+oc+'">\n <path d="M0-36h44V0H0z"/>\n </clipPath>\n </defs>\n <path class="theo-chromecast-outer" d="M2 10a4 4 0 0 1 4-4h36a4 4 0 0 1 4 4v28a4 4 0 0 1-4 4H28v-4h14V10H6v6H2z"/>\n <path class="theo-chromecast-inner" d="M10 14h28v20H26.74A26 26 0 0 0 10 17.26z"/>\n <g class="theo-chromecast-rings" fill="none" stroke="currentColor" stroke-width="4" transform="translate(2 42)" clip-path="url(#theo-chromecast-rings-mask-'+oc+')">\n <circle stroke="none" cx="0" cy="0" r="30" />\n <circle class="theo-chromecast-ring theo-chromecast-ring1" stroke-width="6" cx="0" cy="0" r="3" />\n <circle class="theo-chromecast-ring theo-chromecast-ring2" cx="0" cy="0" r="12" />\n <circle class="theo-chromecast-ring theo-chromecast-ring3" cx="0" cy="0" r="20"/>\n <path class="theo-chromecast-ring theo-chromecast-ring4" stroke-linecap="round" d="M0-20A20 20 0 0 1 20 0" />\n </g>\n </svg>';return oc++,t}zo.registerComponent("chromecastButton",class extends hc{get ga(){var t;return null==(t=this.ks.cast)?void 0:t.chromecast}constructor(t,i){super(t,Di({},i,{wa:"chromecast",ba:ac()}))}});var uc="theo-chromecast-",cc=zo.getComponent("Component"),lc=class t extends(n(cc)){buildCSSClass(){return uc+"overlay "+super.buildCSSClass()}createEl(){const i=super.createEl();fi(i,uc+"overlay");const s=zo.createEl("div",{className:uc+"status-icon",innerHTML:t.ICON_SVG}),e=zo.createEl("div",{className:uc+"status-info"});Et(e,"Playing on");const n=zo.createEl("div",{className:uc+"status-title"}),r=zo.createEl("div",{className:uc+"status"});return this.ur=n,r.appendChild(s),r.appendChild(e),r.appendChild(n),i.appendChild(r),i}dispose(){var t;null==(t=this.Sa)||t.removeEventListener("statechange",this.update),this.Sa=void 0,this.ks.removeEventListener("play",this.update),super.dispose()}constructor(t,i){var s,e;super(t,i),this.update=()=>{this.Sa?(this.ur&&Et(this.ur,this.Sa.receiverName||""),this.Sa.state===M.CONNECTED?this.show():this.hide()):this.hide()},this.Sa=null==(s=this.ks.cast)?void 0:s.chromecast,null==(e=this.Sa)||e.addEventListener("statechange",this.update),this.ks.addEventListener("play",this.update),this.update()}};lc.ICON_SVG='\n<svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 36 36" fill="currentColor">\n <path d="M7 24v3h3c0-1.66-1.34-3-3-3zm0-4v2c2.76 0 5 2.24 5 5h2c0-3.87-3.13-7-7-7zm18-7H11v1.63c3.96 1.28 7.09 4.41 8.37 8.37H25V13zM7 16v2a9 9 0 0 1 9 9h2c0-6.08-4.93-11-11-11zm20-7H9c-1.1 0-2 .9-2 2v3h2v-3h18v14h-7v2h7c1.1 0 2-.9 2-2V11c0-1.1-.9-2-2-2z"/>\n</svg>',zo.registerComponent("chromecastOverlay",lc);zo.registerComponent("airplayButton",class extends hc{dispose(){var t,i;null==(t=this.ks.ads)||t.removeEventListener("adbreakbegin",this.Ta),null==(i=this.ks.ads)||i.removeEventListener("adbreakend",this.Ca),this.ks.removeEventListener("currentsourcechange",this.Ca),super.dispose()}get ga(){var t;return null==(t=this.ks.cast)?void 0:t.airplay}constructor(t,i){var s,e;super(t,Di({},i,{wa:"airplay",ba:'\n<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24">\n <path class="theo-cast-inner" d="M5 7h14v8H5z"/>\n <path d="M6 22h12l-6-6zM21 3H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h4v-2H3V5h18v12h-4v2h4c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/>\n</svg>'})),this.Ca=()=>{this.enable()},this.Ta=()=>{this.disable()},null==(s=this.ks.ads)||s.addEventListener("adbreakbegin",this.Ta),null==(e=this.ks.ads)||e.addEventListener("adbreakend",this.Ca),this.ks.addEventListener("currentsourcechange",this.Ca)}});var fc={Default:"","Monospaced Serif":mt.Pa,"Proportional Serif":mt.Aa,"Monospaced Sans-Serif":mt.Ma,"Proportional Sans-Serif":mt.Ia},dc={White:"#ffffff",Yellow:"#ffff00",Green:"#00ff00",Cyan:"#00ffff",Blue:"#0000ff",Magenta:"#ff00ff",Red:"#ff0000",Black:"#000000"},vc=[50,75,100,150,200];function pc(t){return{label:t+"%",value:t}}function mc(t){return g.keys(t).map((i=>({label:i,value:t[i]})))}vc.map((function(t){return{label:t+"%",value:t/100+"em"}}));var gc=vc.map((function(t){return{label:t+"%",value:t+"%"}})),yc=[25,50,75,100].map(pc),bc=[0,25,50,75,100].map(pc),wc=mc(dc),kc=mc(fc),_c=mc({None:"none","Drop Shadow":"dropshadow",Raised:"raised",Depressed:"depressed",Uniform:"uniform"}),jc=100,xc="#000000",Sc="#FFFFFF",Tc="#000000",Cc=class extends lu{Ea(){let t=this.Mr.localize(this.Da);Et(this.Na.subMenu.menuHeader.el(),t),this.Ar=h.createElement("span"),this.Ar.className="theo-settings-control-menu-item-title",Et(this.Ar,t);let i=h.createElement("span");return i.className="theo-primary-color theo-settings-control-menu-item-value",fi(this.Na.el(),"theo-subtitle-options-menu-item"),this.Na.el().appendChild(this.Ar),this.Na.el().appendChild(i),i}Fa(t){const i=this.wr(t);i&&this.$a(i)}Ba(){return this.dr}jr(t){this.Ra(t.kr)}$a(t){for(let t of this.yr.menuItems)t.selected(!1);t?(t.selected(!0),this.Oa(t.kr.label)):this.Oa("Custom")}Oa(t){this.Va=t,Et(this.La,this.Mr.localize(t)),this.Na.parentMenu.oe()}_r(t){let i=super._r(t);return fi(i.el(),"theo-subtitle-options-menu-item"),this.Cr(i),i}Cr(t){const i=this.Mr.localize(t.kr.label);Et(t.el(),i);const s=this.Mr.localize("Set "+this.Da+" to ")+i;t.el().setAttribute("aria-label",s)}Ve(){this.Mr.off("languagechange",this.se),super.Ve()}constructor(t,i,s,e){super(t.subMenu),this.Na=t,this.Mr=e,this.Va="",this.se=()=>{let t=this.Mr.localize(this.Da);Et(this.Na.subMenu.menuHeader.el(),t),Et(this.Ar,t),this.Oa(this.Va);for(const t of this.br)this.Cr(t)},this.Da=i,this.Ra=s.Go,this.La=this.Ea(),this.dr=s.Ua,this.Mr.on("languagechange",this.se)}},Pc=class t{static Ha(t,i,s,e){if(void 0===t&&void 0===i)return;return Tt(void 0===t?s:t,void 0===i?e:i)}constructor(i){this.za=i,this.Wa=t=>{this.za.fontFamily=t.value},this.qa=t=>{this.za.fontSize=t.value},this.Ga=i=>{this.Xa=i.value,this.za.fontColor=t.Ha(this.Ja,this.Xa,Sc,jc)},this.Qa=i=>{this.Ja=i.value,this.za.fontColor=t.Ha(this.Ja,this.Xa,Sc,jc)},this.Ya=i=>{this.Ka=i.value,this.za.backgroundColor=t.Ha(this.Ka,this.Za,xc,jc)},this.tu=i=>{this.Za=i.value,this.za.backgroundColor=t.Ha(this.Ka,this.Za,xc,jc)},this.iu=i=>{this.su=i.value,this.za.windowColor=t.Ha(this.su,this.eu,Tc,jc)},this.nu=i=>{this.eu=i.value,this.za.windowColor=t.Ha(this.su,this.eu,Tc,jc)},this.ru=t=>{this.za.edgeStyle=t.value}}},Ac=class{hu(t,i){const s=this.ou(t,i.Ba());s&&i.Fa(s)}ou(t,i){return Ui(i,(i=>i.value===t))}au(t,i,s){let e,n;if(void 0===t)e=this.ou(void 0,i.Ba()),n=this.ou(void 0,s.Ba());else if(t){let r=function(t){let i=xt(t);i||(i=xt(t.slice(0,t.length-1).replace("rgb","rgba")+",1)"));i||(i=yt(wt(t),1));if(!i){let s=t.charAt(0).toUpperCase()+t.toLowerCase().slice(1);i=yt(wt(dc[s]),1)}return i}(t);if(r){let t=_t(r),h=100*r.uu;e=this.ou(t,i.Ba()),n=this.ou(h,s.Ba())}}e&&i.Fa(e),n&&s.Fa(n)}constructor(t,i){this.za=t,this.cu=i,this.lu=()=>{let t=this.za.fontFamily;this.hu(t,this.cu["Font family"]);let i=this.za.fontColor;this.au(i,this.cu["Font color"],this.cu["Font opacity"]);let s=this.za.fontSize;this.hu(s,this.cu["Font size"]);let e=this.za.backgroundColor;this.au(e,this.cu["Background color"],this.cu["Background opacity"]);let n=this.za.windowColor;this.au(n,this.cu["Window color"],this.cu["Window opacity"]);let r=this.za.edgeStyle;this.hu(r,this.cu["Character edge style"])},this.za.addEventListener("change",this.lu),this.lu()}};var Mc,Ic=class extends lu{fu(){return{"Font family":{Ua:Ec(kc),Go:this.du.Wa},"Font color":{Ua:Ec(wc),Go:this.du.Qa},"Font opacity":{Ua:Ec(yc),Go:this.du.Ga},"Font size":{Ua:Ec(gc),Go:this.du.qa},"Background color":{Ua:Ec(wc),Go:this.du.Ya},"Background opacity":{Ua:Ec(bc),Go:this.du.tu},"Window color":{Ua:Ec(wc),Go:this.du.iu},"Window opacity":{Ua:Ec(bc),Go:this.du.nu},"Character edge style":{Ua:Ec(_c),Go:this.du.ru}}}vu(){this.Ar=h.createElement("span"),this.Ar.className="theo-settings-control-menu-item-title",this.pu=h.createElement("span"),this.pu.className="theo-primary-color theo-settings-control-menu-item-value",this.Rr.el().appendChild(this.Ar),this.Rr.el().appendChild(this.pu),this.se()}_r(t){let i=this.yr.addSubMenuItem();return i.kr=t,this.cu[t]=new Cc(i,t,this.mu[t],this.Mr),i}Cr(t){}jr(t){}Ve(){this.Mr.off("languagechange",this.se),this.gu.removeEventListener(["addtrack","removetrack"],this.yu),super.Ve()}constructor(t,i,s,e){super(t.subMenu),this.Rr=t,this.gu=i,this.Mr=e,this.cu={},this.yu=()=>{this.gu.some((t=>gt(t.kind)))?this.Rr.show():this.Rr.hide()},this.se=()=>{Et(this.yr.menuHeader.el(),this.Mr.localize("Subtitle Options")),Et(this.Ar,this.Mr.localize("Subtitle")),Et(this.pu,this.Mr.localize("Options")),this.Rr.el().setAttribute("aria-label",this.Mr.localize("Open the subtitle options menu"))},this.du=new Pc(s),this.mu=this.fu(),this.dr=g.keys(this.mu),this.vu(),this.bu=new Ac(s,this.cu),this.Mr.on("languagechange",this.se),this.gu.addEventListener(["addtrack","removetrack"],this.yu),this.yu()}};function Ec(t){let i=[{label:"Default",value:void 0}];for(let s of t)"Default"!==s.label&&i.push(s);return i}!function(t){Gi.push(t)}((function(t){const i=t.ao.controlBar.getChild("SettingsButton").menu,s=i.addSubMenuItem({name:"TextTrackOptionsMenuItem"}),e=new Ic(s,t.nt.ua,t.wu.ua,t.ao);t.ao.on("dispose",(()=>{i.removeMenuItem(s),s.dispose(),e.Ve(),i.dispose()}))})),function(t){t.GALLERY="gallery",t.OVERLAY="overlay",t.SPOTLIGHT="spotlight"}(Mc||(Mc={}));var Dc=.02,Nc=class{ku(t){const i=t-this.ju._u-20,s=t-this.ju._u+20;if(0===this.ju.co)return;const e=this.ju.t.currentProgramDateTime.valueOf();e>s?this.xu(this.Su):e<i?this.xu(this.Tu):this.xu(this.Cu)}Pu(t){const i=t-this.ju._u/1e3-Dc,s=t-this.ju._u/1e3+Dc;if(0===this.ju.co)return;const e=this.ju.t.currentTime;e>s?this.xu(this.Su):e<i?this.xu(this.Tu):this.xu(this.Cu)}Au(){this.Cu=this.Wo.Mu,this.Su=this.Wo.Mu-.05,this.Tu=this.Wo.Mu+.05}xu(t){const i=this.ju.t;if(i.playbackRate!==t&&0!==i.playbackRate){t>=.2&&t<=2.05?i.playbackRate=t:this.Wo.Iu(this.ju)}}Eu(){this.Wo.an(W.Du,this.Nu),this.Wo.an(W.Fu,this.$u)}constructor(t,i){this.Cu=1,this.Su=1.05,this.Tu=.95,this.Nu=()=>{this.Au()},this.$u=()=>{if(!this.Wo.Bu)return;const t=this.Wo.Bu._u,i=this.Wo.Ru,s=this.Wo.Ou;null!==s?this.ku(s.valueOf()+t):this.Pu(i+t/1e3)},this.ju=t,this.Wo=i,this.Wo.dn(W.Du,this.Nu),this.Wo.dn(W.Fu,this.$u)}},Fc=class{get t(){return this.Wo}get ua(){var t;return null!=(t=this.Vu)?t:this.Vu=function(t){return{get label(){return t.ph},get position(){return t.co},set position(i){t.co=i},get muted(){return t.Lu},set muted(i){t.Lu=i},get canResize(){return t.Uu},get x(){return t.Uh},set x(i){t.Uh=i},get y(){return t.Hh},set y(i){t.Hh=i},get width(){return t.Ti},set width(i){t.Ti=i},get height(){return t.Ci},set height(i){t.Ci=i},get enabled(){return t.Rt},set enabled(i){t.Rt=i},get offset(){return t._u},set offset(i){t._u=i},remove(){t.Hu()}}}(this)}get ph(){return this.zu}get co(){return this.qu.Wu.indexOf(this)}set co(t){this.qu.Gu(this,t)}get Lu(){return this.Wo.muted}set Lu(t){this.Rt&&(this.qu.Xu=this,this.Ju(t))}get Uu(){return 0!==this.co&&this.qu.Qu===Mc.OVERLAY}get Uh(){return this.Yu}set Uh(t){this.Uu&&(this.Ku||(this.Ku=!0),this.Yu=t>1-this.Ti?1-this.Ti:w.max(t,0),this.t.element.style.setProperty("left",100*this.Yu+"%"))}get Hh(){return this.Zu}set Hh(t){this.Uu&&(this.Ku||(this.Ku=!0),this.Zu=t>1-this.Ci?1-this.Ci:w.max(t,0),this.t.element.style.setProperty("top",100*this.Zu+"%"))}get Ti(){return this.tc}set Ti(t){this.Uu&&this.ic(t)}get Ci(){return this.sc}set Ci(t){this.Uu&&this.ic(t)}get Rt(){return this.We}set Rt(t){t!==this.We&&0!==this.co&&(t?(D(this.qu.Iu(this)),this.qu.ec(this),this.t.element.style.setProperty("display","block")):(this.t.pause(),this.t.element.style.setProperty("display","none")),this.We=t,this.qu.nc(this))}get rc(){return this.Ku}set rc(t){this.Ku=t}get hc(){return this.oc}set hc(t){this.oc=t}get _u(){return this.ac}set _u(t){this.ac=t,this.uc(this.qu.Ru,this.qu.Ou)}cc(t,i,s,e,n){!this.Ku&&n&&(this.Ku=!0),this.Yu=t,this.Zu=i,this.tc=s,this.sc=e}Ju(t){this.Wo.muted=t}Hu(){0!==this.co&&this.qu.lc(this)}fc(){this.t.element.style.setProperty("top",100*this.Zu+"%"),this.t.element.style.setProperty("left",100*this.Yu+"%"),this.t.element.style.setProperty("width",100*this.tc+"%")}ic(t){const i=this.Yu+this.tc,s=w.min(t,i),e=.9-this.Zu,n=w.min(t,e),r=w.max(w.min(s,n),.1),h=this.tc-r;this.tc=r,this.sc=r,this.Uh+=h,this.t.element.style.setProperty("width",100*r+"%")}uc(t,i){if(null!==i){const t=i.valueOf()-this._u;this.Wo.currentProgramDateTime=new Date(t)}else this.Wo.currentTime=t-this._u/1e3}dc(t){const i=this.t.element.getElementsByClassName(qc)[0],s=t?Xc:Gc;pi(i,t?Gc:Xc),fi(i,s)}Eu(){this.vc.Eu(),this.Wo.element.remove(),this.Wo.destroy()}constructor(t,i,s,e){this.We=!0,this.Ku=!1,this.oc=0,this.zu=t,this.Wo=i,this.qu=s,this.vc=new Nc(this,s),this.ac=null!=e?e:0,this.tc=.2,this.sc=.2,this.Yu=.76,this.Zu=0}};var $c,Bc=class{get multiViewPlayer(){return this.qu}get abr(){}get analytics(){}get audioTracks(){return this.mc}get autoplay(){return this.qu.autoplay}set autoplay(t){this.qu.autoplay=t}get buffered(){return this.qu.buffered}get canvas(){}get clip(){return this.gc.ua}get currentProgramDateTime(){return null}get currentTime(){return this.qu.currentTime}set currentTime(t){this.qu.currentTime=t}get duration(){return this.qu.duration}get element(){return this.Hs}get ended(){return this.qu.ended}get error(){}get errorObject(){return this.qu.errorObject}get latency(){}get loop(){return!1}get metrics(){}get muted(){return this.qu.muted}set muted(t){this.qu.muted=t}get network(){}get paused(){return this.qu.paused}get playbackRate(){return this.qu.playbackRate}set playbackRate(t){this.qu.playbackRate=t}get played(){return this.qu.played}get poster(){return""}get preload(){return""}get presentation(){}get readyState(){return this.qu.readyState}get seekable(){return this.qu.seekable}get seeking(){return this.qu.seeking}get source(){}get src(){return"dummySource"}get textTrackStyle(){return this.yc}get textTracks(){return this.bc}get uid(){return 0}get videoHeight(){return 0}get videoTracks(){return this.mc}get videoWidth(){return 0}get volume(){return this.qu.volume}set volume(t){this.qu.volume=t}get views(){return this.qu.views}get visibility(){}get layout(){return this.qu.layout}set layout(t){this.qu.layout=t}play(){this.qu.play()}pause(){this.qu.pause()}stop(){this.qu.stop()}destroy(){this.qu.destroy()}prepareWithUserAction(){this.qu.prepareWithUserAction()}addEventListener(t,i){this.wc.dn(t,i)}removeEventListener(t,i){this.wc.an(t,i)}setSource(t){}constructor(t,i){this.wc=new F,this.qu=t,this.Hs=i,this.gc=new st,this.mc=(new Jt).ua,this.bc=(new Kt).ua,this.yc=(new at).ua,this.qu.addEventListener(["play","pause","seeking","seeked","timeupdate","ended","playing","waiting","sourcechange","readystatechange","loadedmetadata","loadeddata","canplay","canplaythrough","loadstart","progress","durationchange","volumechange","ratechange","error"],this.wc.Os)}},Rc=class extends B{constructor(t){super($c.kc),this.view=t}},Oc=class extends B{constructor(t,i){super($c.VIEW_POSITION_CHANGE),this.oldPosition=t,this.newPosition=i}},Vc=class extends B{constructor(t){super($c._c),this.view=t}},Lc=class extends B{constructor(t){super($c.VIEW_CHANGE),this.view=t}},Uc=class extends B{constructor(t){super($c.jc),this.layout=t}},Hc=class extends F{get Ru(){return this.Wo.Ru}get xc(){return this.Wo.xc}get lt(){return this.Wo.Sc}get Tc(){return this.Wo.Tc}get Cc(){return this.Wo.Cc}get Pc(){return this.Wo.Pc}get Ac(){return!1}get Mc(){return!1}Eu(){this.Fo()}constructor(t){super(),this.Ic=t=>{this.Os(new zt(t.source))},this.Ec=t=>{this.Os(new ci(t.currentTime))},this.Dc=t=>{this.Os(new oi(t.currentTime))},this.Nc=t=>{this.Os(new _i(t.currentTime))},this.Fc=t=>{this.Os(new Si(t.currentTime))},this.$c=t=>{this.Os(new G(t.currentTime,t.currentProgramDateTime))},this.Bc=t=>{this.Os(new bi(t.currentTime))},this.Rc=t=>{this.Os(new Bt(t.currentTime))},this.Oc=t=>{this.Os(new Pt(t.currentTime))},this.Vc=t=>{this.Os(new kt(t.currentTime,t.readyState))},this.Lc=t=>{this.Os(new St(t.currentTime,this.Cc))},this.Uc=t=>{this.Os(new S(t.currentTime,this.Cc))},this.Hc=t=>{this.Os(new It(t.currentTime,this.Cc))},this.zc=t=>{this.Os(new Nt(t.currentTime,this.Cc))},this.Wc=()=>{this.Os(new ft)},this.qc=t=>{this.Os(new ct(t.currentTime))},this.Gc=t=>{this.Os(new di(t.duration))},this.Xc=t=>{this.Os(new Pi(this.Ru,t.volume))},this.Jc=t=>{this.Os(new mi(this.Ru,t.playbackRate))},this.Qc=t=>{this.Os(new ji(t.errorObject))},this.Yc=()=>{this.Os(new Q)},this.Wo=t,this.Wo.dn("sourcechange",this.Ic),this.Wo.dn("play",this.Ec),this.Wo.dn("pause",this.Dc),this.Wo.dn("seeking",this.Nc),this.Wo.dn("seeked",this.Fc),this.Wo.dn("timeupdate",this.$c),this.Wo.dn("ended",this.Bc),this.Wo.dn("playing",this.Rc),this.Wo.dn("waiting",this.Oc),this.Wo.dn("readystatechange",this.Vc),this.Wo.dn("loadedmetadata",this.Lc),this.Wo.dn("loadeddata",this.Uc),this.Wo.dn("canplay",this.Hc),this.Wo.dn("canplaythrough",this.zc),this.Wo.dn("loadstart",this.Wc),this.Wo.dn("progress",this.qc),this.Wo.dn("durationchange",this.Gc),this.Wo.dn("volumechange",this.Xc),this.Wo.dn("ratechange",this.Jc),this.Wo.dn("error",this.Qc),this.Wo.dn("fullscreenchange",this.Yc)}},zc=class{async Kc(){const t=this.Wo;if(!t.Zc||!t.Tc)return;const i=this.tl.mutedAutoplay;switch(await this.sl.il(t.Lu)){case"all":t.Lu||t.nl(),t.rl();break;case"muted":(t.Lu||i===Ii.ALL)&&(t.Lu=!0,t.rl())}}fn(){this.sl.fn(),this.un.fn()}constructor(t,i,s){this.Wo=t,this.tl=s,this.yc=new at,this.un=new X(i);const e=new ti(this.un,this.yc,1,[et.hl]);this.sl=new ei(e)}},Wc=[bt.ol,bt.al,bt.cl,bt.ll],qc="theo-switch-audio-button",Gc="vjs-icon-volume-mute",Xc="vjs-icon-volume-high",Jc="theo-main-view",Qc="theo-layout-";!function(t){t.kc="addview",t._c="removeview",t.VIEW_CHANGE="viewchange",t.VIEW_POSITION_CHANGE="viewpositionchange",t.jc="layoutchange"}($c||($c={}));var Yc=class extends F{get ua(){var t;return null!=(t=this.Vu)?t:this.Vu=function(t){return{load:(i,s,e,n)=>t.En(i,s,e,n),get views(){return t.Wu.map((t=>t.ua))},get mainVideoView(){var i;return null==(i=t.Bu)?void 0:i.ua},get mainAudioView(){var i;return null==(i=t.Xu)?void 0:i.ua},get layout(){return t.Qu},set layout(i){t.Qu=i},get buffered(){return t.fl},get currentTime(){return t.Ru},set currentTime(i){t.Ru=i},get autoplay(){return t.Zc},set autoplay(i){t.Zc=i},get duration(){return t.ct},get ended(){return t.xc},get errorObject(){return t.Sc},get muted(){return t.Lu},set muted(i){t.Lu=i},get paused(){return t.Tc},get playbackRate(){return t.Mu},set playbackRate(i){t.Mu=i},get played(){return t.dl},get readyState(){return t.Cc},get seekable(){return t.vl},get seeking(){return t.Pc},get volume(){return t.pl},set volume(i){t.pl=i},play(){t.rl()},pause(){t.ml()},stop(){t.gl()},destroy(){t.Eu(),t=null},requestFullscreen(i){t.yl(i)},exitFullscreen(){t.bl()},prepareWithUserAction(){t.nl()},addEventListener(i,s){t.dn(i,s)},removeEventListener(i,s){t.an(i,s)}}}(this)}get ao(){return this.wl}get Wu(){return this.kl}get Bu(){return this._l}get Xu(){var t;return null!=(t=this.jl)?t:this._l}set Xu(t){if(this.jl===t)return;const i=this.Xu,s=null!=t?t:this.Bu;i.t.removeEventListener(W.xl,this.Sl),i.dc(!1),i.Lu||(i.Ju(!0),s.Ju(!1)),s.t.addEventListener(W.xl,this.Sl),s.dc(!0),this.jl=t}get Qu(){return this.Tl}set Qu(t){if(t!==this.Tl){if(this.Qu===Mc.OVERLAY)for(const t of this.Wu)t.t.element.style.setProperty("left","auto"),t.t.element.style.setProperty("top","auto"),t.t.element.style.removeProperty("z-index");pi(this.Hs,Qc+this.Tl),this.Tl=t,fi(this.Hs,Qc+this.Tl),this.fc(),this.bo(new Uc(t))}}get fl(){if(0===this.Wu.length)return Bi.Cl().ws();return this.Pl().reduce(((t,i)=>t.wn(Bi.yn(i.t.buffered))),new Bi([0,1/0])).ws()}get Ru(){return this._l&&this.Al?this._l.t.currentTime+this._l._u/1e3:0}set Ru(t){this.Ml();const i=this.Pl();let s=null;if(null!==this.Ou){s=this.Ou;const i=t-this.Ru;s.setSeconds(s.getSeconds()+i)}for(const e of i)e.uc(t,s)}get Ou(){if(!this._l)return null;return this.Wu.every((t=>null!==t.t.currentProgramDateTime))?new Date(this._l.t.currentProgramDateTime.valueOf()+this._l._u):null}get Zc(){return this.Il}set Zc(t){this.Il=t,this.El.Kc()}get ct(){if(0===this.Wu.length)return NaN;let t=1/0;for(const i of this.Pl())t=w.min(i.t.duration,t);return t}get xc(){return this.Wu.some((t=>t.t.ended))}get lt(){return this.Sc}get Sc(){if(this.Dl)return this.Dl;for(const t of this.Wu){const i=t.t.errorObject;if(void 0!==i)return i}}get Lu(){var t,i;return null!=(i=null==(t=this.Xu)?void 0:t.Lu)&&i}set Lu(t){this.Xu&&this.Xu.Ju(t),this.Sl()}get Tc(){if(!this.Wu.length)return!0;return this.Pl().some((t=>t.t.paused))}get Mu(){var t,i,s;return null!=(s=null!=(i=this.Nl)?i:null==(t=this._l)?void 0:t.t.playbackRate)?s:1}set Mu(t){if(void 0!==this.Nl)this.Nl=t;else for(const i of this.Wu)i.t.playbackRate=t;this.Fl()}get dl(){return this.Wu.reduce(((t,i)=>t.$l(Bi.yn(i.t.played))),Bi.Cl()).ws()}get Cc(){if(0===this.Wu.length)return jt.Bl;let t=jt.Rl;for(const i of this.Pl())i.t.readyState<t&&(t=i.t.readyState);return t}get vl(){if(0===this.Wu.length)return Bi.Cl().ws();return this.Pl().reduce(((t,i)=>t.wn(Bi.yn(i.t.seekable))),new Bi([0,1/0])).ws()}get Pc(){return this.Wu.some((t=>t.t.seeking))}get pl(){var t,i;return null!=(i=null==(t=this.Xu)?void 0:t.t.volume)?i:1}set pl(t){for(const i of this.Wu)i.t.volume=t;this.Sl()}En(t,i,s,e){if(this.Ol)throw this.Dl;const n=this.Wu.filter((i=>i.ph===t))[0];return n?n.ua:this.Vl(t,i,s,e)}rl(){if(!this._l||!this.Tc)return;this.Ml();const t=this.Pl();for(const i of t)i.t.play()}ml(){const t=this.Pl();for(const i of t)i.t.pause()}gl(){for(let t=this.Wu.length-1;t>=0;t--)this.lc(this.Wu[t]);this._l=void 0,this.jl=void 0,this.Dl=void 0,this.Ll&&(this.Ll.Ul(),this.Ll=void 0),this.Hl=!0,this.zl=!1,this.Wl=!1,this.ql=-1,this.Gl=jt.Bl,this.Xl=!1,this.Nl=void 0,this.Jl=!1,this.Ql=-1,this.Yl=!1,this.Kl=-1,this.Al=!1,this.Zl.Xn(),this.bo(new zt(void 0))}Eu(){for(let t=this.Wu.length-1;t>=0;t--)this.lc(this.Wu[t]);this.Fo(),this.Zl.fn(),this.tf.Eu(),this.if.Eu(),this.El.fn(),this.ao.dispose()}yl(t){this.bo(new Q),this.Hs.requestFullscreen(t).catch(Wt)}bl(){this.bo(new Q),h.exitFullscreen().catch(Wt)}nl(){for(const t of this.Wu)t.t.prepareWithUserAction()}Vl(t,i,s,e){const n=h.createElement("div");fi(n,"theo-view"),this.Hs.appendChild(n);const r=new(Gt())(n,this.tl).ua;r.source=i;const o=new Fc(t,r,this,e);if(s){const t=h.createElement("div");t.className="theo-view-description";const i=h.createElement("span");i.textContent=s,t.appendChild(i),n.appendChild(t),o.t.addEventListener("dimensionchange",(()=>{this.sf(t)}))}return this.ef(o),this.Wu.push(o),1===this.Wu.length?(this._l=o,this.nf(this._l),fi(this._l.t.element,Jc)):(this.rf(r),0!==this.Ru&&D(this.Iu(o,!0))),this.fc(),this.bo(new Rc(o.ua)),o.ua}Pl(){return this.Wu.filter((t=>t.Rt))}hf(){return this.Wu.filter((t=>t.Rt&&t!==this._l))}rf(t){t.volume=this._l.t.volume,t.muted=!0,t.playbackRate=this._l.t.playbackRate}ef(t){t.hc=this.Wu.length;const i=t.t.element;i.addEventListener("dblclick",(()=>{this.af(t)})),i.addEventListener("touchend",(i=>{this.uf>=i.timeStamp?(i.preventDefault(),this.af(t),this.uf=0):this.uf=i.timeStamp+500}));const s=h.createElement("div"),e=0===this.Wu.length?Xc:Gc;s.className="theo-primary-color "+qc+" "+e,s.addEventListener("click",(()=>{this.Xu=t})),s.addEventListener("touchend",(()=>{this.Xu=t})),i.appendChild(s);const n=h.createElement("div");n.className="theo-primary-color theo-disable-button vjs-icon-close",n.addEventListener("click",(()=>{t.Rt=!1})),n.addEventListener("touchend",(()=>{t.Rt=!1})),i.appendChild(n),this.cf(t,i),this.lf(t),this.ff(t)}cf(t,i){const s=h.createElement("div");let e=0;const n=i=>{if(this.df=!0,this.ec(t),i.preventDefault(),"touchstart"===i.type){e=i.changedTouches[0].clientX,h.addEventListener("touchmove",r),h.addEventListener("touchend",o),h.addEventListener("touchcancel",o)}else{e=i.x,h.addEventListener("mousemove",r),h.addEventListener("mouseup",o)}},r=i=>{let s;if("touchmove"===i.type){s=i.changedTouches[0].clientX}else{s=i.x}const n=e-s,r=t.t.element.parentElement.clientWidth,h=(t.t.element.clientWidth+n)/r;t.Ti=h,t.Ci=h,e=s},o=t=>{this.df=!1,"mouseup"===t.type?(h.removeEventListener("mousemove",r),h.removeEventListener("mouseup",o)):(h.removeEventListener("touchmove",r),h.removeEventListener("touchend",o),h.removeEventListener("touchcancel",o))};s.addEventListener("mousedown",n),s.addEventListener("touchstart",n),s.className="theo-resize-button theo-primary-color vjs-icon-resize-handle-sw",i.appendChild(s)}sf(t){const i=t.parentElement.clientWidth/100,s=w.min(40,5.23*i);t.style.fontSize=s+"px"}lf(t){const i=t.t.element,s=i.parentElement;let e={x:0,y:0};const n=i=>{if(!this.df&&t.Uu)if(this.ec(t),i.preventDefault(),"touchstart"===i.type){const t=i;e.x=t.changedTouches[0].clientX,e.y=t.changedTouches[0].clientY,h.addEventListener("touchmove",r),h.addEventListener("touchend",o),h.addEventListener("touchcancel",o)}else{const t=i;e.x=t.x,e.y=t.y,h.addEventListener("mousemove",r),h.addEventListener("mouseup",o)}},r=n=>{let r;if("touchmove"===n.type){const t=n;r={x:t.changedTouches[0].clientX,y:t.changedTouches[0].clientY}}else{const t=n;r={x:t.x,y:t.y}}const h=r.x-e.x,o=r.y-e.y,a=i.offsetLeft,u=s.clientWidth;t.Uh=(a+h)/u;const c=s.offsetHeight,l=i.offsetTop;t.Hh=(l+o)/c,e=r},o=t=>{"mouseup"===t.type?(h.removeEventListener("mouseup",o),h.removeEventListener("mousemove",r)):(h.removeEventListener("touchmove",r),h.removeEventListener("touchend",o),h.removeEventListener("touchcancel",o))};i.addEventListener("mousedown",n),i.addEventListener("touchstart",n)}ec(t){for(const i of this.Wu)i.hc>t.hc&&(i.hc-=1,i.t.element.style.setProperty("z-index",""+i.hc));t.hc=this.Wu.length,t.t.element.style.setProperty("z-index",""+t.hc)}Ml(){if(void 0!==this.Nl)return;this.Nl=this.Mu;const t=this.Pl();for(const i of t)i.t.playbackRate=0}vf(){if(void 0===this.Nl)return;if(this.Pc||this.Cc<jt.pf){if(this._l&&!this.Al){this.Al=!0;for(const t of this.hf())this._l._u!==t._u&&t.uc(this.Ru,this.Ou)}return}const t=this.Pl();for(const i of t)i.t.playbackRate=this.Nl;this.Nl=void 0,this.Al=!0}nc(t){t.Rt||t!==this.jl||(this.Xu=void 0),this.bo(new Lc(t.ua)),this.fc()}async Iu(t,i){void 0===i&&(i=!1),this.Ml();const s=t.t;i&&(this.Ll=new O,s.addEventListener(W.ho,this.As),await this.Ll.mf,s.removeEventListener(W.ho,this.As)),s.readyState===jt.Bl&&(this.Jl=!0,s.play()),this.Tc?s.pause():s.play(),t.uc(this.Ru,this.Ou)}fc(){const t=this.Pl();if(!t.length)return;let i=0;switch(this.Qu){case Mc.SPOTLIGHT:{t.length>1?this.Hs.style.gridTemplateColumns="80% 20%":this.Hs.style.gridTemplateColumns="100%";let s=1/0;for(const e of t)if(i>=s+1)e.Rt=!1;else if(e.t.element.style.setProperty("width","100%"),i++,2===i){const i=e.t.element.clientHeight,n=e.t.element.parentElement.clientHeight,r=w.floor(n/i);s=w.min(t.length-1,r),this.Hs.style.gridTemplateRows="repeat("+s+", 1fr)"}break}case Mc.OVERLAY:{let s=0;for(i=1;i<t.length;i++){const e=t[i];if(i>=5)e.Rt=!1;else{if(!e.rc){const t=.04+.24*s;e.cc(e.Uh,t,e.Ti,e.Ci,!1),this.ec(e),s++}e.t.element.style.setProperty("z-index",""+e.hc),e.fc()}}break}case Mc.GALLERY:{const s=t.length,e=w.ceil(w.sqrt(s));for(const s of t)i>=9?s.Rt=!1:(s.t.element.style.setProperty("width",100/e+"%"),i++);break}}}Gu(t,i){const s=i>=0?w.min(w.floor(i),this.Wu.length-1):0,e=t.co,n=w.min(e,s),r=w.max(e,s),h=0===n;if(!(!this.Wu[n].Rt||!this.Wu[r].Rt)||!h){if(this.Qu===Mc.OVERLAY){const t=this.Wu[r],i=this.Wu[n],s=t.Uh,e=t.Hh,h=t.Ti,o=t.Ci,a=i.rc||t.rc;t.cc(i.Uh,i.Hh,i.Ti,i.Ci,a),[this.Wu[n],this.Wu[r]]=[this.Wu[r],this.Wu[n]],i.cc(s,e,h,o,a)}else[this.Wu[n],this.Wu[r]]=[this.Wu[r],this.Wu[n]];h&&this.gf(this.Wu[0]),this.bo(new Oc(e,s))}}lc(t){t===this.jl&&(this.Xu=void 0),t.Eu(),zi(this.Wu,t),this.fc(),this.bo(new Vc(t.ua))}af(t){this.xc||0===this.dl.length||this._l===t||this.Tl===Mc.GALLERY||this.Gu(t,0)}gf(t,i){void 0===i&&(i=!1);let s=!1;const e=this._l;this._l=t,t.rc=!1,this.yf(e),pi(e.t.element,Jc),this.jl||(s=e.Lu,e.Ju(!0),e.dc(!1),t.dc(!0),i&&!s?this.bo(new Pi(this.Ru,0)):t.Ju(s)),this.ec(e),fi(this._l.t.element,Jc),this.nf(this._l),this.Qu===Mc.OVERLAY&&this.fc()}ff(t){t.t.addEventListener(W.bf,this.wf),t.t.addEventListener(W.kf,this.jh),t.t.addEventListener(W.kh,this._f),t.t.addEventListener(W.wh,this.jf),t.t.addEventListener(W.xf,this.Xe),t.t.addEventListener(W.Sf,this.Tf),t.t.addEventListener(W.Cf,this.Pf),t.t.addEventListener(bt.Af,this.Mf),t.t.addEventListener(lt.ia,this.Ps)}nf(t){t.t.addEventListener(W.If,this.Os),t.t.addEventListener(W.Du,this.Fl),t.t.addEventListener(W.Fu,this.Ef),this.jl||t.t.addEventListener(W.xl,this.Sl)}yf(t){t.t.removeEventListener(W.If,this.Os),t.t.removeEventListener(W.Du,this.Fl),t.t.removeEventListener(W.Fu,this.Ef),this.jl||t.t.removeEventListener(W.xl,this.Sl)}constructor(t,i){super(),this.kl=[],this.Tl=Mc.GALLERY,this.df=!1,this.Ol=!1,this.Hl=!0,this.zl=!1,this.Wl=!1,this.ql=-1,this.Gl=jt.Bl,this.Xl=!1,this.uf=0,this.Nl=void 0,this.Jl=!1,this.Il=!1,this.Ql=-1,this.Yl=!1,this.Kl=-1,this.Al=!1,this.Df=t=>{this.vf(),I((()=>this.Os(t)))},this.Nf=t=>{this.Ml(),this.Os(t)},this.As=()=>{var t;null==(t=this.Ll)||t.Ff(),this.Ll=void 0},this.Fl=()=>{const t=this.Mu;this.Kl!==t&&(this.Kl=t,this.Os(new mi(this.Ru,t)))},this.Sl=()=>{const t=this.pl,i=this.Lu;this.Ql===t&&this.Yl===i||(this.Ql=t,this.Yl=i,this.Os(new Pi(this.Ru,t)))},this.Ef=t=>{(this.Cc>jt.$f||this.Pc)&&this.Os(t)},this.wf=t=>{this.vf(),this.Pc||(this.zl=!1,this.Os(t))},this.Pf=t=>{const i=this.ct;this.ql!==i&&(this.ql=i,this.Os(t))},this.Ps=t=>{this.Os(t)},this._f=t=>{if(this.Hl){if(this.Jl)return void(this.Jl=!1);this.Hl=!1,this.Wl=!1,this.Os(t)}},this.Xe=t=>{this.zl||(this.zl=!0,this.Os(t))},this.jf=t=>{!this.Hl&&this.Tc&&(this.Hl=!0,this.Os(t))},this.jh=t=>{this.Wl||(this.Wl=!0,this.Os(t))},this.Tf=t=>{this.Xl||(this.Xl=!0,this.Os(t))},this.Mf=t=>{const i=this.Cc;this.Gl!==i&&(this.Gl=i,this.Os(t))},this.Bf=async()=>{try{await this.Of.Rf([N.MULTIVIEW])}catch(t){this.Dl=t,this.gl(),this.Ol=!0,this.bo(new Ht(t))}},this.Hs=t,this.tl=i;const s=Ct.Vf,e=new ht,n=new V("6.9.0",s,e),r=new R(i.isEmbeddable,"6.9.0",$());if(this.Of=new nt(s,r,n,e,i,$()),this.Of.Lf().then(this.Bf),this.Uf=new Bc(this.ua,t),this.wl=Wu(this.Uf,this.Hs,i.ui),fi(this.Hs,Qc+this.Tl),Ct.Zs.Ks){const t=this.wl.el();fi(t,"theo-mobile"),qu(t)}this.if=new Hc(this),this.tf=new vt(this.if),this.tf.dn(bt.Hf,this.Df),this.Zl=new Vt(this,!0),this.Zl.dn(Wc,this.Os),this.Zl.dn(bt.zf,this.Nf),this.El=new zc(this,t,i)}};function Kc(t,i){var s;const e=ic(Di({},i||{},{allowNativeFullscreen:!1,ui:Di({},(null==i?void 0:i.ui)||{},{userActions:Di({},(null==i||null==(s=i.ui)?void 0:s.userActions)||{},{click:!1})}),abr:Di({},(null==i?void 0:i.abr)||{},{restrictToPlayerSize:!0})}));let n=new Yc(t,e).ua;return g.defineProperty(n,"constructor",{value:Kc}),n=J(n),n}var Zc="vjs-selected",tl=class extends lu{Cr(t){const i=t.kr,s=this.Mr.localize(i.label);Et(t.ph,s),t.el().setAttribute("aria-label",this.Mr.localize("Enable/disable")+" "+s),t.el().setAttribute("role","menuitemcheckbox"),t.selected(i.enabled)}_r(t){const i=super._r(t);fi(i.el(),"theo-multi-view-menu-item"),2===this.br.length&&fi(i.el(),"theo-multi-view-menu-item-position-zero");const s=h.createElement("span");i.ph=s;const e=h.createElement("div");e.className="theo-multi-view-menu-item-toggle",i.mh=e;const n=t=>this.gh(t,i);i.yh=n,e.addEventListener("click",n);const r=h.createElement("div");return r.className="theo-multi-view-menu-item-toggle-slider",e.appendChild(r),i.el().appendChild(s),i.el().appendChild(e),this.Wf.before(i.el()),i}qf(){const t=this.yr.addMenuItem().el();fi(t,"theo-multi-view-menu-item"),fi(t,"theo-multi-view-menu-layout-select");const i=h.createElement("button");i.className="vjs-icon-view-grid",i.addEventListener("click",(()=>{this._s.layout=Mc.GALLERY})),t.appendChild(i),this.Gf=i;const s=h.createElement("button");s.className="vjs-icon-view-spotlight",s.addEventListener("click",(()=>{this._s.layout=Mc.SPOTLIGHT})),t.appendChild(s),this.Xf=s;const e=h.createElement("button");return e.className="vjs-icon-multi-view",e.addEventListener("click",(()=>{this._s.layout=Mc.OVERLAY})),t.appendChild(e),this.Jf=e,t}gh(t,i){t.stopImmediatePropagation(),this.jr(i)}jr(t){const i=t.kr;for(const t of this._s.views)t===i&&(t.enabled=!t.enabled);this.Cr(t)}Sr(t){t.mh.removeEventListener("click",t.yh),super.Sr(t)}constructor(t,i,s){super(t),this.Qf=t=>{this.gr(t.view)},this.Yf=t=>{this.mr(t.view)},this.Kf=t=>{const i=t.oldPosition,s=t.newPosition,e=w.max(i,s),n=w.min(i,s),r=h.getElementsByClassName("theo-multi-view-menu-item");r[e].before(r[n]),r[n].before(r[e]),0===n&&(pi(r[e],"theo-multi-view-menu-item-position-zero"),fi(r[n],"theo-multi-view-menu-item-position-zero"))},this.Zf=()=>{const t=this._s.layout;yi(this.Gf,Zc,t===Mc.GALLERY),yi(this.Xf,Zc,t===Mc.SPOTLIGHT),yi(this.Jf,Zc,t===Mc.OVERLAY)},i.views&&(this._s=i,this.Mr=s,this._s.multiViewPlayer.addEventListener($c.kc,this.Qf),this._s.multiViewPlayer.addEventListener($c._c,this.Yf),this._s.multiViewPlayer.addEventListener($c.VIEW_CHANGE,this.Qf),this._s.multiViewPlayer.addEventListener($c.VIEW_POSITION_CHANGE,this.Kf),this._s.multiViewPlayer.addEventListener($c.jc,this.Zf),Et(this.yr.menuHeader.el(),this.Mr.localize("MultiView")),this.Wf=this.qf(),this.Zf())}};zo.registerComponent("multiViewButton",class extends Ca{buildCSSClass(){return"vjs-icon-view-grid "+super.buildCSSClass()}dispose(){this.dh.Ve(),super.dispose()}constructor(t,i){super(t,i),this.minimumMenuItems=3,this.dh=new tl(this.menu,this.ks,t),this.controlText(t.localize("Views")),this.$e.Fe=this.controlText()}});export{Qt as ChromelessPlayer,H as ErrorCategory,L as ErrorCode,Kc as MultiViewPlayer,ec as Player,Fi as cache,Ei as cast,si as features,ai as playerSuiteVersion,li as players,vi as registerContentProtectionIntegration,Zt as utils,ri as version,zo as videojs};
|