@theoplayer/theoads 8.1.2 → 8.2.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/README.md +1 -1
- package/THEOplayer.chromeless.d.ts +1 -1
- package/THEOplayer.chromeless.esm.js +2 -2
- package/THEOplayer.chromeless.js +3 -3
- package/THEOplayer.common.d.ts +39 -0
- package/THEOplayer.common.esm.js +3 -3
- package/THEOplayer.d.ts +1 -1
- 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.sw.js +30 -0
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: 8.
|
|
38
|
-
Created: 2024-10-
|
|
37
|
+
Version: 8.2.0
|
|
38
|
+
Created: 2024-10-10T09:08:07.000Z
|
|
39
39
|
*/
|
|
40
|
-
var a="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:void 0!==s?s:"undefined"!=typeof global?global:this,s=a.window,h=a.document,u=(a.location,a.navigator,a.setTimeout),c=a.clearTimeout,v=a.setInterval,m=a.clearInterval,g=a.Error,b=a.TypeError,k=a.SyntaxError,w=a.Object,_=a.Math,x=a.parseInt,C=a.parseFloat,S=a.isNaN,j=a.Uint8Array;a.Worker,a.WorkerGlobalScope,a.XMLHttpRequest;import{$ as T,A as M,Aa as A,B as P,Ba as E,C as N,Ca as B,D as I,Da as F,E as D,Ea as l,F as $,Fa as R,G as O,Ga as V,H as U,Ha as z,I as L,Ia as H,J as q,Ja as W,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 dt,U as ft,Ua as vt,V as pt,Va as mt,W as gt,Wa as yt,X as bt,Xa as kt,Y as wt,Ya as _t,Z as xt,Za as Ct,_ as St,_a as jt,a as Tt,aa as Mt,b as At,ba as Pt,c as Et,ca as Nt,d as Bt,da as It,e as Ft,ea as Dt,f as $t,fa as Rt,g as Ot,ga as Vt,h as Ut,ha as zt,i as Lt,ia as Ht,j as qt,ja as Wt,k as Gt,ka as Xt,l as Jt,la as Qt,m as Yt,ma as Kt,n as Zt,na as ti,o as ii,oa as si,p as ei,pa as ni,q as ri,qa as hi,r as oi,ra as ai,s as ui,sa as ci,t as li,ta as di,u as fi,ua as vi,v as pi,va as mi,w as gi,wa as yi,x as bi,xa as ki,y as wi,ya as _i,z as xi,za as Ci}from"./THEOplayer.common.esm.js";var Si=[];function ji(t){Si.push(t)}var Ti=[];function Mi(t){Ti.push(t)}var t=void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},Ai=void 0!==h?h:{createElement:function(){}};function Pi(t,i){return i||(i=t.slice(0)),t.raw=i,t}var Ei=1;function Ni(){return Ei++}var Bi,Ii=w.prototype.toString,Fi=function(t){return Ri(t)?w.keys(t):[]};function Di(t,i){Fi(t).forEach((function(s){return i(t[s],s)}))}function $i(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 w.assign?w.assign.apply(w,[t].concat(s)):(s.forEach((function(i){i&&Di(i,(function(i,s){t[s]=i}))})),t)}function Ri(t){return!!t&&"object"==typeof t}function Oi(t){return Ri(t)&&"[object Object]"===Ii.call(t)&&t.constructor===w}var Vi=function(i,s,e){void 0===e&&(e=!!Os&&Os<11),"log"!==i&&s.unshift(i.toUpperCase()+":"),Bi.history.push(s),s.unshift("VIDEOJS:");var n=t.console&&t.console[i];n&&(e&&(s=s.map((function(t){if(Ri(t)||Array.isArray(t))try{return JSON.stringify(t)}catch(i){return String(t)}return String(t)})).join(" ")),n.apply?n[Array.isArray(s)?"apply":"call"](t.console,s):n(s))};(Bi=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];Vi("log",i)}).history=[],Bi.error=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Vi("error",i)},Bi.warn=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Vi("warn",i)};var Ui=Bi,zi="undefined"!=typeof globalThis?globalThis:void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Li(t){return t.replace(/\n\r?\s*/g,"")}var Hi,qi=function(t){for(var i="",s=0;s<arguments.length;s++)i+=Li(t[s])+(arguments[s+1]||"");return i};function Wi(t){return"string"==typeof t&&/\S/.test(t)}function Gi(t){if(/\s/.test(t))throw new g("class has illegal whitespace characters")}function Xi(){return Ai===t.document&&void 0!==Ai.createElement}function Ji(t){return Ri(t)&&1===t.nodeType}function Qi(t){return function(i,s){if(!Wi(i))return Ai[t](null);Wi(s)&&(s=Ai.querySelector(s));var e=Ji(s)?s:Ai;return e[t]&&e[t](i)}}function Yi(t,i,s,e){void 0===t&&(t="div"),void 0===i&&(i={}),void 0===s&&(s={});var n=Ai.createElement(t);return w.getOwnPropertyNames(i).forEach((function(t){var s=i[t];-1!==t.indexOf("aria-")||"role"===t||"type"===t?(Ui.warn(qi(Hi||(Hi=Pi(["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?Ki(n,s):n[t]=s})),w.getOwnPropertyNames(s).forEach((function(t){n.setAttribute(t,s[t])})),e&&gs(n,e),n}function Ki(t,i){return void 0===t.textContent?t.innerText=i:t.textContent=i,t}function Zi(t,i){i.firstChild?i.insertBefore(t,i.firstChild):i.appendChild(t)}var ts={},is="vdata"+(new Date).getTime();function ss(t){var i=t[is];return i||(i=t[is]=Ni()),ts[i]||(ts[i]={}),ts[i]}function es(t){var i=t[is];return!!i&&!!w.getOwnPropertyNames(ts[i]).length}function ns(t){var i=t[is];if(i){delete ts[i];try{delete t[is]}catch(i){t.removeAttribute?t.removeAttribute(is):t[is]=null}}}function rs(t,i){return Gi(i),t.classList?t.classList.contains(i):function(t){return new RegExp("(^|\\s)"+t+"($|\\s)")}(i).test(t.className)}function hs(t,i){return t.classList?t.classList.add(i):rs(t,i)||(t.className=(t.className+" "+i).trim()),t}function os(t,i){return t.classList?t.classList.remove(i):(Gi(i),t.className=t.className.split(/\s+/).filter((function(t){return t!==i})).join(" ")),t}function as(t,i,s){var e=rs(t,i);if("function"==typeof s&&(s=s(t,i)),"boolean"!=typeof s&&(s=!e),s!==e)return s?hs(t,i):os(t,i),t}function us(t,i){w.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 ls(t,i,s){t.setAttribute(i,s)}function ds(t,i){t.removeAttribute(i)}function fs(i){var s;if(i.getBoundingClientRect&&i.parentNode&&(s=i.getBoundingClientRect()),!s)return{left:0,top:0};var e=Ai.documentElement,n=Ai.body,r=e.clientLeft||n.clientLeft||0,h=t.pageXOffset||n.scrollLeft,o=s.left+h-r,a=e.clientTop||n.clientTop||0,u=t.pageYOffset||n.scrollTop,c=s.top+u-a;return{left:_.round(o),top:_.round(c)}}function vs(t,i){var s={},e=fs(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=_.max(0,_.min(1,(h-a+r)/r)),s.x=_.max(0,_.min(1,(u-o)/n)),s}function ps(t){return Ri(t)&&3===t.nodeType}function ms(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function gs(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()),Ji(t)||ps(t)?t:"string"==typeof t&&/\S/.test(t)?Ai.createTextNode(t):void 0})).filter((function(t){return t}))}(i).forEach((function(i){return t.appendChild(i)})),t}function ys(t,i){return gs(ms(t),i)}var bs,ks=Qi("querySelector"),ws=Qi("querySelectorAll"),_s=t.navigator&&t.navigator.userAgent||"",xs=/AppleWebKit\/([\d.]+)/i.exec(_s),Cs=xs?C(xs.pop()):null,Ss=/iPad/i.test(_s),js=/iPhone/i.test(_s)&&!Ss,Ts=/iPod/i.test(_s),Ms=js||Ss||Ts,As=(bs=_s.match(/OS (\d+)_/i))&&bs[1]?bs[1]:null,Ps=/Android/i.test(_s),Es=function(){var t=_s.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!t)return null;var i=t[1]&&C(t[1]),s=t[2]&&C(t[2]);return i&&s?C(t[1]+"."+t[2]):i||null}(),Ns=Ps&&/webkit/i.test(_s)&&Es<2.3,Bs=Ps&&Es<5&&Cs<537,Is=/Firefox/i.test(_s),Fs=/Edge/i.test(_s),Ds=!Fs&&/Chrome/i.test(_s),$s=function(){var t=_s.match(/Chrome\/(\d+)/);return t&&t[1]?C(t[1]):null}(),Rs=/MSIE\s8\.0/.test(_s),Os=function(){var t=/MSIE\s(\d+)\.\d/.exec(_s),i=t&&C(t[1]);return!i&&/Trident\/7.0/i.test(_s)&&/rv:11.0/.test(_s)&&(i=11),i}(),Vs=/Safari/i.test(_s)&&!Ds&&!Ps&&!Fs,Us=Vs||Ms,zs=Xi()&&("ontouchstart"in t||t.DocumentTouch&&t.document instanceof t.DocumentTouch),Ls=Xi()&&"backgroundSize"in t.document.createElement("video").style,Hs=w.freeze({__proto__:null,IS_IPAD:Ss,IS_IPHONE:js,IS_IPOD:Ts,IS_IOS:Ms,IOS_VERSION:As,IS_ANDROID:Ps,ANDROID_VERSION:Es,IS_OLD_ANDROID:Ns,IS_NATIVE_ANDROID:Bs,IS_FIREFOX:Is,IS_EDGE:Fs,IS_CHROME:Ds,CHROME_VERSION:$s,IS_IE8:Rs,IE_VERSION:Os,IS_SAFARI:Vs,IS_ANY_SAFARI:Us,TOUCH_ENABLED:zs,BACKGROUND_SIZE_SUPPORTED:Ls});function qs(t,i){var s=ss(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)),w.getOwnPropertyNames(s.handlers).length<=0&&(delete s.handlers,delete s.dispatcher,delete s.disabled),0===w.getOwnPropertyNames(s).length&&ns(t)}function Ws(t,i,s,e){s.forEach((function(s){t(i,s,e)}))}function Gs(i){function s(){return!0}function e(){return!1}if(!i||!i.isPropagationStopped||!i.isImmediatePropagationStopped){var n=i||t.event;for(var r in i={},n)"layerX"!==r&&"layerY"!==r&&"keyLocation"!==r&&"webkitMovementX"!==r&&"webkitMovementY"!==r&&"path"!==r&&("returnValue"===r&&n.preventDefault||(i[r]=n[r]));if(i.target||(i.target=i.srcElement||Ai),i.relatedTarget||(i.relatedTarget=i.fromElement===i.target?i.toElement:i.fromElement),i.preventDefault=function(){n.preventDefault&&n.preventDefault(),i.returnValue=!1,n.returnValue=!1,i.defaultPrevented=!0},i.defaultPrevented=!1,i.stopPropagation=function(){n.stopPropagation&&n.stopPropagation(),i.cancelBubble=!0,n.cancelBubble=!0,i.isPropagationStopped=s},i.isPropagationStopped=e,i.stopImmediatePropagation=function(){n.stopImmediatePropagation&&n.stopImmediatePropagation(),i.isImmediatePropagationStopped=s,i.stopPropagation()},i.isImmediatePropagationStopped=e,null!==i.clientX&&void 0!==i.clientX){var h=Ai.documentElement,o=Ai.body;i.pageX=i.clientX+(h&&h.scrollLeft||o&&o.scrollLeft||0)-(h&&h.clientLeft||o&&o.clientLeft||0),i.pageY=i.clientY+(h&&h.scrollTop||o&&o.scrollTop||0)-(h&&h.clientTop||o&&o.clientTop||0)}i.which=i.charCode||i.keyCode,null!==i.button&&void 0!==i.button&&(i.button=1&i.button?0:4&i.button?1:2&i.button?2:0)}return i}var Xs=!1;!function(){try{var i=w.defineProperty({},"passive",{get:function(){Xs=!0}});t.addEventListener("test",null,i)}catch(t){}}();var Js=["touchstart","touchmove"];function Qs(t,i,s){if(Array.isArray(i))return Ws(Qs,t,i,s);var e=ss(t);if(e.handlers||(e.handlers={}),e.handlers[i]||(e.handlers[i]=[]),s.guid||(s.guid=Ni()),e.handlers[i].push(s),e.dispatcher||(e.disabled=!1,e.dispatcher=function(i,s){if(!e.disabled){i=Gs(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){Ui.error(t)}}}),1===e.handlers[i].length)if(t.addEventListener){var n=!1;Xs&&Js.indexOf(i)>-1&&(n={passive:!0}),t.addEventListener(i,e.dispatcher,n)}else t.attachEvent&&t.attachEvent("on"+i,e.dispatcher)}function Ys(t,i,s){if(es(t)){var e=ss(t);if(e.handlers){if(Array.isArray(i))return Ws(Ys,t,i,s);var n=function(i){e.handlers[i]=[],qs(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);qs(t,i)}else n(i)}else for(var o in e.handlers)n(o)}}}function Ks(t,i,s){var e=es(t)?ss(t):{},n=t.parentNode||t.ownerDocument;if("string"==typeof i&&(i={type:i,target:t}),i=Gs(i),e.dispatcher&&e.dispatcher.call(t,i,s),n&&!i.isPropagationStopped()&&!0===i.bubbles)Ks.call(null,n,i,s);else if(!n&&!i.defaultPrevented){var r=ss(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 Zs(t,i,s){if(Array.isArray(i))return Ws(Zs,t,i,s);var e=function e(){Ys(t,i,e),s.apply(this,arguments)};e.guid=s.guid=s.guid||Ni(),Qs(t,i,e)}var te,ie=!1,se=function(){if(Xi()){var t=Ai.getElementsByTagName("video"),i=Ai.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){ee(1);break}void 0===u.player&&null!==u.getAttribute("data-setup")&&te(u)}else ie||ee(1)}};function ee(i,s){s&&(te=s),t.setTimeout(se,i)}Xi()&&"complete"===Ai.readyState?ie=!0:Zs(t,"load",(function(){ie=!0}));var ne=function(t){var i=Ai.createElement("style");return i.className=t,i},re=function(t,i){t.styleSheet?t.styleSheet.cssText=i:t.textContent=i},he=function(t,i,s){i.guid||(i.guid=Ni());var e=function(){return i.apply(t,arguments)};return e.guid=s?s+"_"+i.guid:i.guid,e};function oe(t){return"string"!=typeof t?t:t.charAt(0).toUpperCase()+t.slice(1)}function ae(){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&&Di(i,(function(i,s){Oi(i)?(Oi(t[s])||(t[s]={}),t[s]=ae(t[s],i)):t[s]=i}))})),t}var i=function(){function i(t,i,s){if(!t&&this.play?this.t=t=this:this.t=t,this.h=ae({},this.h),i=this.h=ae(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"+Ni()}this.l=i.name||null,i.el?this.v=i.el:!1!==i.createEl&&(this.v=this.createEl()),this.m=[],this.k={},this.C={},!1!==i.initChildren&&this.initChildren(),this.ready(s),!1!==i.reportTouchActivity&&this.enableTouchActivity()}var s=i.prototype;return s.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.C=null,this.off(),this.v.parentNode&&this.v.parentNode.removeChild(this.v),ns(this.v),this.v=null},s.player=function(){return this.t},s.options=function(t){return Ui.warn("this.options() has been deprecated and will be moved to the constructor in 6.0"),t?(this.h=ae(this.h,t),this.h):this.h},s.el=function(){return this.v},s.createEl=function(t,i,s){return Yi(t,i,s)},s.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},s.contentEl=function(){return this.S||this.v},s.id=function(){return this.o},s.name=function(){return this.l},s.children=function(){return this.m},s.getChildById=function(t){return this.k[t]},s.getChild=function(t){if(t)return t=oe(t),this.C[t]},s.addChild=function(t,s,e){var n,r;if(void 0===s&&(s={}),void 0===e&&(e=this.m.length),"string"==typeof t){r=oe(t),s||(s={}),!0===s&&(Ui.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=i.getComponent(h);if(!o)throw new g("Component "+h+" does not exist");if("function"!=typeof o)return null;n=new o(this.t||this,s)}else n=t;if(this.m.splice(e,0,n),"function"==typeof n.id&&(this.k[n.id()]=n),(r=r||n.name&&oe(n.name()))&&(this.C[r]=n),"function"==typeof n.el&&n.el()){var a=this.contentEl().children[e]||null;this.contentEl().insertBefore(n.el(),a)}return n},s.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.C[t.name()]=null;var e=t.el();e&&e.parentNode===this.contentEl()&&this.contentEl().removeChild(t.el())}}},s.initChildren=function(){var t=this,s=this.h.children;if(s){var e,n=this.h,r=i.getComponent("Tech");(e=Array.isArray(s)?s:w.keys(s)).concat(w.keys(this.h).filter((function(t){return!e.some((function(i){return"string"==typeof i?t===i:t===i.name}))}))).map((function(i){var e,n;return"string"==typeof i?n=s[e=i]||t.h[e]||{}:(e=i.name,n=i),{name:e,opts:n}})).filter((function(t){var s=i.getComponent(t.opts.componentClass||oe(t.name));return s&&!r.isTech(s)})).forEach((function(i){var s=i.name,e=i.opts;if(void 0!==n[s]&&(e=n[s]),!1!==e){!0===e&&(e={}),e.playerOptions=t.h.playerOptions;var r=t.addChild(s,e);r&&(t[s]=r)}}))}},s.buildCSSClass=function(){return""},s.on=function(t,i,s){var e=this;if("string"==typeof t||Array.isArray(t))Qs(this.v,t,he(this,i));else{var n=t,r=i,h=he(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?(Qs(n,r,h),Qs(n,"dispose",a)):"function"==typeof t.on&&(n.on(r,h),n.on("dispose",a))}return this},s.off=function(t,i,s){if(!t||"string"==typeof t||Array.isArray(t))Ys(this.v,t,i);else{var e=t,n=i,r=he(this,s);this.off("dispose",r),t.nodeName?(Ys(e,n,r),Ys(e,"dispose",r)):(e.off(n,r),e.off("dispose",r))}return this},s.one=function(t,i,s){var e=arguments,n=this;if("string"==typeof t||Array.isArray(t))Zs(this.v,t,he(this,i));else{var r=t,h=i,o=he(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},s.trigger=function(t,i){return Ks(this.v,t,i),this},s.ready=function(t,i){return void 0===i&&(i=!1),t&&(this.j?i?t.call(this):this.setTimeout(t,1):(this.T=this.T||[],this.T.push(t))),this},s.triggerReady=function(){this.j=!0,this.setTimeout((function(){var t=this.T;this.T=[],t&&t.length>0&&t.forEach((function(t){t.call(this)}),this),this.trigger("ready")}),1)},s.$=function(t,i){return ks(t,i||this.contentEl())},s.$$=function(t,i){return ws(t,i||this.contentEl())},s.hasClass=function(t){return rs(this.v,t)},s.addClass=function(t){return hs(this.v,t),this},s.removeClass=function(t){return os(this.v,t),this},s.toggleClass=function(t,i){return as(this.v,t,i),this},s.show=function(){return this.removeClass("vjs-hidden"),this},s.hide=function(){return this.addClass("vjs-hidden"),this},s.lockShowing=function(){return this.addClass("vjs-lock-showing"),this},s.unlockShowing=function(){return this.removeClass("vjs-lock-showing"),this},s.getAttribute=function(t){return function(t,i){return t.getAttribute(i)}(this.v,t)},s.setAttribute=function(t,i){return ls(this.v,t,i),this},s.removeAttribute=function(t){return ds(this.v,t),this},s.width=function(t,i){return this.dimension("width",t,i)},s.height=function(t,i){return this.dimension("height",t,i)},s.dimensions=function(t,i){return this.width(t,!0).height(i)},s.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 x(-1!==n?e.slice(0,n):this.v["offset"+oe(t)],10)},s.currentDimension=function(i){var s=0;if("width"!==i&&"height"!==i)throw new g("currentDimension only accepts width or height value");if("function"==typeof t.getComputedStyle){var e=t.getComputedStyle(this.v);s=e.getPropertyValue(i)||e[i]}if(0===(s=C(s))){var n="offset"+oe(i);s=this.v[n]}return s},s.currentDimensions=function(){return{width:this.currentDimension("width"),height:this.currentDimension("height")}},s.currentWidth=function(){return this.currentDimension("width")},s.currentHeight=function(){return this.currentDimension("height")},s.focus=function(){this.v.focus()},s.blur=function(){this.v.blur()},s.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;_.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")))}))},s.enableTouchActivity=function(){if(this.player()&&this.player().reportUserActivity){var t,i=he(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)}},s.setTimeout=function(i,s){i=he(this,i);var e=t.setTimeout(i,s),n=function(){this.clearTimeout(e)};return n.guid="vjs-timeout-"+e,this.on("dispose",n),e},s.clearTimeout=function(i){t.clearTimeout(i);var s=function(){};return s.guid="vjs-timeout-"+i,this.off("dispose",s),i},s.setInterval=function(i,s){i=he(this,i);var e=t.setInterval(i,s),n=function(){this.clearInterval(e)};return n.guid="vjs-interval-"+e,this.on("dispose",n),e},s.clearInterval=function(i){t.clearInterval(i);var s=function(){};return s.guid="vjs-interval-"+i,this.off("dispose",s),i},i.registerComponent=function(t,s){if(t){if(t=oe(t),i.M||(i.M={}),"Player"===t&&i.M[t]){var e=i.M[t];if(e.players&&w.keys(e.players).length>0&&w.keys(e.players).map((function(t){return e.players[t]})).every(Boolean))throw new g("Can not register Player component after player has been created")}return i.M[t]=s,s}},i.getComponent=function(s){if(s)return s=oe(s),i.M&&i.M[s]?i.M[s]:t&&t.videojs&&t.videojs[s]?(Ui.warn("The "+s+" component was added to the videojs object when it should be registered using videojs.registerComponent(name, component)"),t.videojs[s]):void 0},i.extend=function(t){t=t||{},Ui.warn("Component.extend({}) has been deprecated, use videojs.extend(Component, {}) instead");var s=t.init||t.init||this.prototype.init||this.prototype.init||function(){},e=function(){s.apply(this,arguments)};for(var n in(e.prototype=w.create(this.prototype)).constructor=e,e.extend=i.extend,t)t.hasOwnProperty(n)&&(e.prototype[n]=t[n]);return e},i}();i.registerComponent("Component",i);var ue=function(){};function ce(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function le(t,i){return(le=w.setPrototypeOf?w.setPrototypeOf.bind():function(t,i){return t.__proto__=i,t})(t,i)}function de(t,i){t.prototype=w.create(i.prototype),t.prototype.constructor=t,le(t,i)}function fe(t,i,s,e){return void 0===e&&(Ui.warn("DEPRECATED: Function '"+t+"' on 'TimeRanges' called without an index argument."),e=0),function(t,i,s){if(i<0||i>s)throw new g("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 ve(t){return void 0===t||0===t.length?{length:0,start:function(){throw new g("This TimeRanges object is empty")},end:function(){throw new g("This TimeRanges object is empty")}}:{length:t.length,start:fe.bind(null,"start",0,t),end:fe.bind(null,"end",1,t)}}function pe(t,i){return Array.isArray(t)?ve(t):void 0===t||void 0===i?ve():ve([[t,i]])}function me(t,i){var s,e,n=0;if(!i)return 0;t&&t.length||(t=pe(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}ue.prototype.A={},ue.prototype.on=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},Qs(this,t,i),this.addEventListener=s},ue.prototype.addEventListener=ue.prototype.on,ue.prototype.off=function(t,i){Ys(this,t,i)},ue.prototype.removeEventListener=ue.prototype.off,ue.prototype.one=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},Zs(this,t,i),this.addEventListener=s},ue.prototype.trigger=function(t){var i=t.type||t;"string"==typeof t&&(t={type:i}),t=Gs(t),this.A[i]&&this["on"+i]&&this["on"+i](t),Ks(this,t)},ue.prototype.dispatchEvent=ue.prototype.trigger;var ge,ye,be,ke,we={prefixed:!0},_e=[["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"]],xe=_e[0];for(ye=0;ye<_e.length;ye++)if(_e[ye][1]in Ai){ge=_e[ye];break}if(ge){for(be=0;be<ge.length;be++)we[xe[be]]=ge[be];we.prefixed=ge[0]!==xe[0]}function Ce(t){if(t instanceof Ce)return t;"number"==typeof t?this.code=t:"string"==typeof t?this.message=t:Ri(t)&&("number"==typeof t.code&&(this.code=t.code),$i(this,t)),this.message||(this.message=Ce.defaultMessages[this.code]||"")}for(Ce.prototype.code=0,Ce.prototype.message="",Ce.prototype.status=null,Ce.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],Ce.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."},ke=0;ke<Ce.errorTypes.length;ke++)Ce[Ce.errorTypes[ke]]=ke,Ce.prototype[Ce.errorTypes[ke]]=ke;var Se=function(t,i){var s,e=null;try{s=JSON.parse(t,i)}catch(t){e=t}return[e,s]};var je=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}}))})},Te=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=je(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(je))},Me=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()},Ae="vjs-modal-dialog",Pe=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).P=e.N=e.B=!1,e.closeable(!e.h.uncloseable),e.content(e.h.content),e.S=Yi("div",{className:Ae+"-content"},{role:"document"}),e.I=Yi("p",{className:Ae+"-description vjs-offscreen",id:e.el().getAttribute("aria-describedby")}),Ki(e.I,e.description()),e.v.appendChild(e.I),e.v.appendChild(e.S),e.on(i,"languagechange",e.handleLanguagechange),e}de(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 Ae+" 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.P){var t=this.player();this.trigger("beforemodalopen"),this.P=!0,(this.h.fillAlways||!this.N&&!this.B)&&this.fill(),this.D=!t.paused(),this.h.pauseOnOpen&&this.D&&t.pause(),this.closeable()&&this.on(this.v.ownerDocument,"keydown",he(this,this.handleKeyPress)),t.controls(!1),this.show(),this.el().setAttribute("aria-hidden","false"),this.trigger("modalopen"),this.N=!0}return this},s.opened=function(t){return"boolean"==typeof t&&this[t?"open":"close"](),this.P},s.close=function(){if(this.P){var t=this.player();this.trigger("beforemodalclose"),this.P=!1,this.D&&this.h.pauseOnOpen&&t.play(),this.closeable()&&this.off(this.v.ownerDocument,"keydown",he(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.B=!0,s.removeChild(i),this.empty(),ys(i,t),this.trigger("modalfill"),e?s.insertBefore(i,e):s.appendChild(i),this},s.empty=function(){return this.trigger("beforemodalempty"),ms(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()),Ki(this.I,this.description()),this.opened()?this.fill():(this.N||this.B)&&(this.N=!1,this.B=!1,this.empty())},i}(i);Pe.prototype.h={pauseOnOpen:!0,temporary:!0},i.registerComponent("ModalDialog",Pe);var Ee=function(){function t(i){var s=this;if(Rs)for(var e in s=Ai.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);if(t.prototype.V.call(s,i),w.defineProperty(s,"length",{get:function(){return this.U}}),Rs)return s}var i=t.prototype;return i.V=function(t){var i=this.length||0,s=0,e=t.length;this.L=t,this.U=t.length;var n=function(t){""+t in this||w.defineProperty(this,""+t,{get:function(){return this.L[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}(),Ne={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},Be={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},Ie={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},Fe={disabled:"disabled",hidden:"hidden",showing:"showing"},De=function(t){function i(s){var e;void 0===s&&(s={});var n=ce(e=t.call(this)||this);if(Rs)for(var r in n=Ai.createElement("custom"),i.prototype)"constructor"!==r&&(n[r]=i.prototype[r]);var h={id:s.id||["vjs_track",Ni()].join("_"),kind:s.kind||"",label:s.label||"",language:s.language||""},o=function(t){w.defineProperty(n,t,{get:function(){return h[t]},set:function(){}})};for(var a in h)o(a);return n||ce(e)}return de(i,t),i}(ue),$e=function(t){var i=["protocol","hostname","port","pathname","search","hash","host"],s=Ai.createElement("a");s.href=t;var e,n=""===s.host&&"file:"!==s.protocol;n&&((e=Ai.createElement("div")).innerHTML='<a href="'+t+'"></a>',s=e.firstChild,e.setAttribute("style","display:none; position:absolute;"),Ai.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&&Ai.body.removeChild(e),r},Re=function(i){var s=t.location,e=$e(i);return(":"===e.protocol?s.protocol:e.protocol)+e.host!==s.protocol+s.host},Oe={exports:{}};void 0!==s?Oe.exports=s:void 0!==zi?Oe.exports=zi:"undefined"!=typeof self?Oe.exports=self:Oe.exports={};var Ve=function(t){var i=Ue.call(t);return"[object Function]"===i||"function"==typeof t&&"[object RegExp]"!==i||void 0!==s&&(t===s.setTimeout||t===s.alert||t===s.confirm||t===s.prompt)},Ue=w.prototype.toString;var ze,Le,He,qe,We,Ge,Xe,Je,Qe,Ye,Ke,Ze,tn=Array.prototype.slice,sn=w.prototype.toString,en=function(t){var i=this;if("function"!=typeof i||"[object Function]"!==sn.call(i))throw new b("Function.prototype.bind called on incompatible "+i);for(var s,e=tn.call(arguments,1),n=_.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(tn.call(arguments)));return w(n)===n?n:this}return i.apply(t,e.concat(tn.call(arguments)))})),i.prototype){var o=function(){};o.prototype=i.prototype,s.prototype=new o,o.prototype=null}return s},nn=Function.prototype.bind||en,rn=w.prototype.toString,hn=function(t){var i=rn.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]"===rn.call(t.callee)),s};w.keys||(Le=w.prototype.hasOwnProperty,He=w.prototype.toString,qe=hn,We=w.prototype.propertyIsEnumerable,Ge=!We.call({toString:null},"toString"),Xe=We.call((function(){}),"prototype"),Je=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],Qe=function(t){var i=t.constructor;return i&&i.prototype===t},Ye={$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},Ke=function(){if(void 0===s)return!1;for(var t in s)try{if(!Ye["$"+t]&&Le.call(s,t)&&null!==s[t]&&"object"==typeof s[t])try{Qe(s[t])}catch(t){return!0}}catch(t){return!0}return!1}(),Ze=function(t){if(void 0===s||!Ke)return Qe(t);try{return Qe(t)}catch(t){return!1}},ze=function(t){var i=null!==t&&"object"==typeof t,s="[object Function]"===He.call(t),e=qe(t),n=i&&"[object String]"===He.call(t),r=[];if(!i&&!s&&!e)throw new b("Object.keys called on a non-object");var h=Xe&&s;if(n&&t.length>0&&!Le.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||!Le.call(t,u)||r.push(String(u));if(Ge)for(var c=Ze(t),l=0;l<Je.length;++l)c&&"constructor"===Je[l]||!Le.call(t,Je[l])||r.push(Je[l]);return r});var on=ze,an=Array.prototype.slice,un=hn,cn=w.keys,ln=cn?function(t){return cn(t)}:on,dn=w.keys;ln.shim=function(){if(w.keys){var t=function(){var t=w.keys(arguments);return t&&t.length===arguments.length}(1,2);t||(w.keys=function(t){return un(t)?dn(an.call(t)):dn(t)})}else w.keys=ln;return w.keys||ln};var fn=ln,vn="function"==typeof Symbol&&"symbol"==typeof Symbol("foo"),pn=w.prototype.toString,mn=Array.prototype.concat,gn=w.defineProperty,yn=gn&&function(){var t={};try{for(var i in gn(t,"x",{enumerable:!1,value:t}),t)return!1;return t.x===t}catch(t){return!1}}(),bn=function(t,i,s,e){(!(i in t)||function(t){return"function"==typeof t&&"[object Function]"===pn.call(t)}(e)&&e())&&(yn?gn(t,i,{configurable:!0,enumerable:!1,value:s,writable:!0}):t[i]=s)},kn=function(t,i){var s=arguments.length>2?arguments[2]:{},e=fn(i);vn&&(e=mn.call(e,w.getOwnPropertySymbols(i)));for(var n=0;n<e.length;n+=1)bn(t,e[n],i[e[n]],s[e[n]])};kn.supportsDescriptors=!!yn;var wn,_n=kn,xn=w.getOwnPropertyDescriptor?function(){return w.getOwnPropertyDescriptor(arguments,"callee").get}():function(){throw new b},Cn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator,Sn=w.getPrototypeOf||function(t){return t.__proto__},jn=void 0===j?wn:Sn(j),Tn={"$ %Array%":Array,"$ %ArrayBuffer%":"undefined"==typeof ArrayBuffer?wn:ArrayBuffer,"$ %ArrayBufferPrototype%":"undefined"==typeof ArrayBuffer?wn:ArrayBuffer.prototype,"$ %ArrayIteratorPrototype%":Cn?Sn([][Symbol.iterator]()):wn,"$ %ArrayPrototype%":Array.prototype,"$ %ArrayProto_entries%":Array.prototype.entries,"$ %ArrayProto_forEach%":Array.prototype.forEach,"$ %ArrayProto_keys%":Array.prototype.keys,"$ %ArrayProto_values%":Array.prototype.values,"$ %AsyncFromSyncIteratorPrototype%":wn,"$ %AsyncFunction%":undefined,"$ %AsyncFunctionPrototype%":wn,"$ %AsyncGenerator%":wn,"$ %AsyncGeneratorFunction%":undefined,"$ %AsyncGeneratorPrototype%":wn,"$ %AsyncIteratorPrototype%":wn,"$ %Atomics%":"undefined"==typeof Atomics?wn:Atomics,"$ %Boolean%":Boolean,"$ %BooleanPrototype%":Boolean.prototype,"$ %DataView%":"undefined"==typeof DataView?wn:DataView,"$ %DataViewPrototype%":"undefined"==typeof DataView?wn:DataView.prototype,"$ %Date%":Date,"$ %DatePrototype%":Date.prototype,"$ %decodeURI%":decodeURI,"$ %decodeURIComponent%":decodeURIComponent,"$ %encodeURI%":encodeURI,"$ %encodeURIComponent%":encodeURIComponent,"$ %Error%":g,"$ %ErrorPrototype%":g.prototype,"$ %eval%":eval,"$ %EvalError%":EvalError,"$ %EvalErrorPrototype%":EvalError.prototype,"$ %Float32Array%":"undefined"==typeof Float32Array?wn:Float32Array,"$ %Float32ArrayPrototype%":"undefined"==typeof Float32Array?wn:Float32Array.prototype,"$ %Float64Array%":"undefined"==typeof Float64Array?wn:Float64Array,"$ %Float64ArrayPrototype%":"undefined"==typeof Float64Array?wn:Float64Array.prototype,"$ %Function%":Function,"$ %FunctionPrototype%":Function.prototype,"$ %Generator%":wn,"$ %GeneratorFunction%":undefined,"$ %GeneratorPrototype%":wn,"$ %Int8Array%":"undefined"==typeof Int8Array?wn:Int8Array,"$ %Int8ArrayPrototype%":"undefined"==typeof Int8Array?wn:Int8Array.prototype,"$ %Int16Array%":"undefined"==typeof Int16Array?wn:Int16Array,"$ %Int16ArrayPrototype%":"undefined"==typeof Int16Array?wn:Int8Array.prototype,"$ %Int32Array%":"undefined"==typeof Int32Array?wn:Int32Array,"$ %Int32ArrayPrototype%":"undefined"==typeof Int32Array?wn:Int32Array.prototype,"$ %isFinite%":isFinite,"$ %isNaN%":S,"$ %IteratorPrototype%":Cn?Sn(Sn([][Symbol.iterator]())):wn,"$ %JSON%":JSON,"$ %JSONParse%":JSON.parse,"$ %Map%":"undefined"==typeof Map?wn:Map,"$ %MapIteratorPrototype%":"undefined"!=typeof Map&&Cn?Sn((new Map)[Symbol.iterator]()):wn,"$ %MapPrototype%":"undefined"==typeof Map?wn:Map.prototype,"$ %Math%":_,"$ %Number%":Number,"$ %NumberPrototype%":Number.prototype,"$ %Object%":w,"$ %ObjectPrototype%":w.prototype,"$ %ObjProto_toString%":w.prototype.toString,"$ %ObjProto_valueOf%":w.prototype.valueOf,"$ %parseFloat%":C,"$ %parseInt%":x,"$ %Promise%":"undefined"==typeof Promise?wn:Promise,"$ %PromisePrototype%":"undefined"==typeof Promise?wn:Promise.prototype,"$ %PromiseProto_then%":"undefined"==typeof Promise?wn:Promise.prototype.then,"$ %Promise_all%":"undefined"==typeof Promise?wn:Promise.all,"$ %Promise_reject%":"undefined"==typeof Promise?wn:Promise.reject,"$ %Promise_resolve%":"undefined"==typeof Promise?wn:Promise.resolve,"$ %Proxy%":"undefined"==typeof Proxy?wn:Proxy,"$ %RangeError%":RangeError,"$ %RangeErrorPrototype%":RangeError.prototype,"$ %ReferenceError%":ReferenceError,"$ %ReferenceErrorPrototype%":ReferenceError.prototype,"$ %Reflect%":"undefined"==typeof Reflect?wn:Reflect,"$ %RegExp%":RegExp,"$ %RegExpPrototype%":RegExp.prototype,"$ %Set%":"undefined"==typeof Set?wn:Set,"$ %SetIteratorPrototype%":"undefined"!=typeof Set&&Cn?Sn((new Set)[Symbol.iterator]()):wn,"$ %SetPrototype%":"undefined"==typeof Set?wn:Set.prototype,"$ %SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?wn:SharedArrayBuffer,"$ %SharedArrayBufferPrototype%":"undefined"==typeof SharedArrayBuffer?wn:SharedArrayBuffer.prototype,"$ %String%":String,"$ %StringIteratorPrototype%":Cn?Sn(""[Symbol.iterator]()):wn,"$ %StringPrototype%":String.prototype,"$ %Symbol%":Cn?Symbol:wn,"$ %SymbolPrototype%":Cn?Symbol.prototype:wn,"$ %SyntaxError%":k,"$ %SyntaxErrorPrototype%":k.prototype,"$ %ThrowTypeError%":xn,"$ %TypedArray%":jn,"$ %TypedArrayPrototype%":jn?jn.prototype:wn,"$ %TypeError%":b,"$ %TypeErrorPrototype%":b.prototype,"$ %Uint8Array%":void 0===j?wn:j,"$ %Uint8ArrayPrototype%":void 0===j?wn:j.prototype,"$ %Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?wn:Uint8ClampedArray,"$ %Uint8ClampedArrayPrototype%":"undefined"==typeof Uint8ClampedArray?wn:Uint8ClampedArray.prototype,"$ %Uint16Array%":"undefined"==typeof Uint16Array?wn:Uint16Array,"$ %Uint16ArrayPrototype%":"undefined"==typeof Uint16Array?wn:Uint16Array.prototype,"$ %Uint32Array%":"undefined"==typeof Uint32Array?wn:Uint32Array,"$ %Uint32ArrayPrototype%":"undefined"==typeof Uint32Array?wn:Uint32Array.prototype,"$ %URIError%":URIError,"$ %URIErrorPrototype%":URIError.prototype,"$ %WeakMap%":"undefined"==typeof WeakMap?wn:WeakMap,"$ %WeakMapPrototype%":"undefined"==typeof WeakMap?wn:WeakMap.prototype,"$ %WeakSet%":"undefined"==typeof WeakSet?wn:WeakSet,"$ %WeakSetPrototype%":"undefined"==typeof WeakSet?wn:WeakSet.prototype},Mn=function(t,i){if(arguments.length>1&&"boolean"!=typeof i)throw new b('"allowMissing" argument must be a boolean');var s="$ "+t;if(!(s in Tn))throw new k("intrinsic "+t+" does not exist!");if(void 0===Tn[s]&&!i)throw new b("intrinsic "+t+" exists, but is not available. Please file an issue!");return Tn[s]},An=nn.call(Function.call,w.prototype.hasOwnProperty),Pn=Mn,En=Pn("%TypeError%"),Nn=Pn("%SyntaxError%"),Bn=An,In={"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(Bn(i,e)&&!s[e])return!1;var n=Bn(i,"[[Value]]"),r=Bn(i,"[[Get]]")||Bn(i,"[[Set]]");if(n&&r)throw new En("Property Descriptors may not be both accessor and data descriptors");return!0}},Fn=Number.isNaN||function(t){return t!=t},Dn=Number.isNaN||function(t){return t!=t},$n=Number.isFinite||function(t){return"number"==typeof t&&!Dn(t)&&t!==1/0&&t!==-1/0},Rn=Function.prototype.toString,On=/^\s*class\b/,Vn=function(t){try{var i=Rn.call(t);return On.test(i)}catch(t){return!1}},Un=w.prototype.toString,zn="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,Ln=function(t){if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if("function"==typeof t&&!t.prototype)return!0;if(zn)return function(t){try{return!Vn(t)&&(Rn.call(t),!0)}catch(t){return!1}}(t);if(Vn(t))return!1;var i=Un.call(t);return"[object Function]"===i||"[object GeneratorFunction]"===i},Hn=w.prototype.toString,qn=function(t){return null===t||"function"!=typeof t&&"object"!=typeof t},Wn=Ln,Gn=function(t){var i;if((i=arguments.length>1?arguments[1]:"[object Date]"===Hn.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(Wn(t[n[e]])&&(s=t[n[e]](),qn(s)))return s;throw new b("No default value")}throw new b("invalid [[DefaultValue]] hint supplied")},Xn=Mn,Jn=Xn("%Object%"),Qn=Xn("%TypeError%"),Yn=Xn("%String%"),Kn=function(t,i,s,e){var n=In[i];if("function"!=typeof n)throw new Nn("unknown record type: "+i);if(!n(t,e))throw new En(s+" must be a "+i);console.log(n(t,e),e)},Zn=Fn,tr=$n,ir=function(t){return t>=0?1:-1},sr=function(t,i){var s=t%i;return _.floor(s>=0?s:s+i)},er=An,nr={ToPrimitive:function(t){return qn(t)?t:arguments.length>1?Gn(t,arguments[1]):Gn(t)},ToBoolean:function(t){return!!t},ToNumber:function(t){return+t},ToInteger:function(t){var i=this.ToNumber(t);return Zn(i)?0:0!==i&&tr(i)?ir(i)*_.floor(_.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(Zn(i)||0===i||!tr(i))return 0;var s=ir(i)*_.floor(_.abs(i));return sr(s,65536)},ToString:function(t){return Yn(t)},ToObject:function(t){return this.CheckObjectCoercible(t),Jn(t)},CheckObjectCoercible:function(t,i){if(null==t)throw new Qn(i||"Cannot call method on "+t);return t},IsCallable:Ln,SameValue:function(t,i){return t===i?0!==t||1/t==1/i:Zn(t)&&Zn(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(er(t,s)&&!i[s])return!1;var e=er(t,"[[Value]]"),n=er(t,"[[Get]]")||er(t,"[[Set]]");if(e&&n)throw new Qn("Property Descriptors may not be both accessor and data descriptors");return!0},IsAccessorDescriptor:function(t){return void 0!==t&&(Kn(this,"Property Descriptor","Desc",t),!(!er(t,"[[Get]]")&&!er(t,"[[Set]]")))},IsDataDescriptor:function(t){return void 0!==t&&(Kn(this,"Property Descriptor","Desc",t),!(!er(t,"[[Value]]")&&!er(t,"[[Writable]]")))},IsGenericDescriptor:function(t){return void 0!==t&&(Kn(this,"Property Descriptor","Desc",t),!this.IsAccessorDescriptor(t)&&!this.IsDataDescriptor(t))},FromPropertyDescriptor:function(t){if(void 0===t)return t;if(Kn(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 Qn("FromPropertyDescriptor must be called with a fully populated Property Descriptor")},ToPropertyDescriptor:function(t){if("Object"!==this.Type(t))throw new Qn("ToPropertyDescriptor requires an object");var i={};if(er(t,"enumerable")&&(i["[[Enumerable]]"]=this.ToBoolean(t.enumerable)),er(t,"configurable")&&(i["[[Configurable]]"]=this.ToBoolean(t.configurable)),er(t,"value")&&(i["[[Value]]"]=t.value),er(t,"writable")&&(i["[[Writable]]"]=this.ToBoolean(t.writable)),er(t,"get")){var s=t.get;if(void 0!==s&&!this.IsCallable(s))throw new b("getter must be a function");i["[[Get]]"]=s}if(er(t,"set")){var e=t.set;if(void 0!==e&&!this.IsCallable(e))throw new Qn("setter must be a function");i["[[Set]]"]=e}if((er(i,"[[Get]]")||er(i,"[[Set]]"))&&(er(i,"[[Value]]")||er(i,"[[Writable]]")))throw new Qn("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return i}},rr=nn.call(Function.call,String.prototype.replace),hr=/^[\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]+/,or=/[\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]+$/,ar=function(){var t=nr.ToString(nr.CheckObjectCoercible(this));return rr(rr(t,hr,""),or,"")},ur=ar,cr=function(){return String.prototype.trim&&"\u200b"==="\u200b".trim()?String.prototype.trim:ur},lr=_n,dr=cr,fr=_n,vr=ar,pr=cr,mr=function(){var t=dr();return lr(String.prototype,{trim:t},{trim:function(){return String.prototype.trim!==t}}),t},gr=nn.call(Function.call,pr());fr(gr,{getPolyfill:pr,implementation:vr,shim:mr});var yr=gr,br=Ln,kr=w.prototype.toString,wr=w.prototype.hasOwnProperty,_r=yr,xr=function(t,i,s){if(!br(i))throw new b("iterator must be a function");var e;arguments.length>=3&&(e=s),"[object Array]"===kr.call(t)?function(t,i,s){for(var e=0,n=t.length;e<n;e++)wr.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)wr.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))}(t,i,e)},Cr=function(){for(var t={},i=0;i<arguments.length;i++){var s=arguments[i];for(var e in s)Sr.call(s,e)&&(t[e]=s[e])}return t},Sr=w.prototype.hasOwnProperty;var jr=Oe.exports,Tr=Ve,Mr=function(t){if(!t)return{};var i={};return xr(_r(t).split("\n"),(function(t){var s=t.indexOf(":"),e=_r(t.slice(0,s)).toLowerCase(),n=_r(t.slice(s+1));void 0===i[e]?i[e]=n:!function(t){return"[object Array]"===w.prototype.toString.call(t)}(i[e])?i[e]=[i[e],n]:i[e].push(n)})),i},Ar=Cr,Pr=Nr;function Er(t,i,s){var e=t;return Tr(i)?(s=i,"string"==typeof t&&(e={uri:t})):e=Ar(i,{uri:t}),e.callback=s,e}function Nr(t,i,s){return Br(i=Er(t,i,s))}function Br(t){if(void 0===t.callback)throw new g("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:v,url:f,rawRequest:l};function r(t){return c(d),t instanceof g||(t=new g(""+(t||"Unknown XMLHttpRequest Error"))),t.statusCode=0,s(t,n)}function h(){if(!a){var i;c(d),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:v,headers:{},url:f,rawRequest:l},l.getAllResponseHeaders&&(r.headers=Mr(l.getAllResponseHeaders()))):h=new g("Internal XMLHttpRequest Error"),s(h,r,r.body)}}var o,a,l=t.xhr||null;l||(l=t.cors||t.useXDR?new Nr.XDomainRequest:new Nr.XMLHttpRequest);var d,f=l.url=t.uri||t.url,v=l.method=t.method||"GET",p=t.body||t.data||null,m=l.headers=t.headers||{},y=!!t.sync,b=!1;if("json"in t&&(b=!0,m.accept||m.Accept||(m.Accept="application/json"),"GET"!==v&&"HEAD"!==v&&(m["content-type"]||m["Content-Type"]||(m["Content-Type"]="application/json"),p=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(v,f,!y,t.username,t.password),y||(l.withCredentials=!!t.withCredentials),!y&&t.timeout>0&&(d=u((function(){a=!0,l.abort("timeout");var t=new g("XMLHttpRequest timeout");t.code="ETIMEDOUT",r(t)}),t.timeout)),l.setRequestHeader)for(o in m)m.hasOwnProperty(o)&&l.setRequestHeader(o,m[o]);else if(t.headers&&!function(t){for(var i in t)if(t.hasOwnProperty(i))return!1;return!0}(t.headers))throw new g("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(p),l}Nr.XMLHttpRequest=jr.XMLHttpRequest||function(){},Nr.XDomainRequest="withCredentials"in new Nr.XMLHttpRequest?Nr.XMLHttpRequest:jr.XDomainRequest,function(t,i){for(var s=0;s<t.length;s++)i(t[s])}(["get","put","post","patch","head","delete"],(function(t){Nr["delete"===t?"del":t]=function(i,s,e){return(s=Er(i,s,e)).method=t.toUpperCase(),Br(s)}}));var Ir=function(i,s){var e=new t.WebVTT.Parser(t,t.vttjs,t.WebVTT.StringDecoder()),n=[];e.oncue=function(t){s.addCue(t)},e.onparsingerror=function(t){n.push(t)},e.onflush=function(){s.trigger({type:"loadeddata",target:s})},e.parse(i),n.length>0&&(t.console&&t.console.groupCollapsed&&t.console.groupCollapsed("Text Track parsing errors for "+s.src),n.forEach((function(t){return Ui.error(t)})),t.console&&t.console.groupEnd&&t.console.groupEnd()),e.flush()},Fr=function(i){function s(e){var n;if(void 0===e&&(e={}),!e.tech)throw new g("A tech was not provided.");var r=ae(e,{kind:Ie[e.kind]||"subtitles",language:e.language||e.srclang||""}),h=Fe[r.mode]||"disabled",o=r.default;"metadata"!==r.kind&&"chapters"!==r.kind||(h="hidden");var a=n=i.call(this,r)||this;if(a.H=r.tech,Rs)for(var u in s.prototype)"constructor"!==u&&(a[u]=s.prototype[u]);a.L=[],a.q=[];var c=new Ee(a.L),l=new Ee(a.q),d=!1,f=he(a,(function(){this.activeCues,d&&(this.trigger("cuechange"),d=!1)}));return"disabled"!==h&&a.H.ready((function(){a.H.on("timeupdate",f)}),!0),w.defineProperty(a,"default",{get:function(){return o},set:function(){}}),w.defineProperty(a,"mode",{get:function(){return h},set:function(t){var i=this;Fe[t]&&("showing"===(h=t)&&this.H.ready((function(){i.H.on("timeupdate",f)}),!0),this.trigger("modechange"))}}),w.defineProperty(a,"cues",{get:function(){return this.W?c:null},set:function(){}}),w.defineProperty(a,"activeCues",{get:function(){if(!this.W)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(d=!1,i.length!==this.q.length)d=!0;else for(var r=0;r<i.length;r++)-1===this.q.indexOf(i[r])&&(d=!0);return this.q=i,l.V(this.q),l},set:function(){}}),r.src?(a.src=r.src,function(i,s){var e={uri:i},n=Re(i);n&&(e.cors=n),Pr(e,he(this,(function(i,e,n){if(i)return Ui.error(i,e);if(s.W=!0,"function"!=typeof t.WebVTT){if(s.H){var r=function(){return Ir(n,s)};s.H.on("vttjsloaded",r),s.H.on("vttjserror",(function(){Ui.error("vttjs failed to load, stopping trying to process "+s.src),s.H.off("vttjsloaded",r)}))}}else Ir(n,s)})))}(r.src,a)):a.W=!0,a||ce(n)}de(s,i);var e=s.prototype;return e.addCue=function(i){var s=i;if(t.vttjs&&!(i instanceof t.vttjs.VTTCue)){for(var e in s=new t.vttjs.VTTCue(i.startTime,i.endTime,i.text),i)e in s||(s[e]=i[e]);s.id=i.id,s.G=i}var n=this.H.textTracks();if(n)for(var r=0;r<n.length;r++)n[r]!==this&&n[r].removeCue(s);this.L.push(s),this.cues.V(this.L)},e.removeCue=function(t){for(var i=this.L.length;i--;){var s=this.L[i];if(s===t||s.G&&s.G===t){this.L.splice(i,1),this.cues.V(this.L);break}}},s}(De);Fr.prototype.A={cuechange:"cuechange"};var Dr=function(t){function i(s){var e,n;void 0===s&&(s={});var r=ce(e=t.call(this)||this);if(Rs)for(var h in r=Ai.createElement("custom"),i.prototype)"constructor"!==h&&(r[h]=i.prototype[h]);var o=new Fr(s);return r.kind=o.kind,r.src=o.src,r.srclang=o.language,r.label=o.label,r.default=o.default,w.defineProperty(r,"readyState",{get:function(){return n}}),w.defineProperty(r,"track",{get:function(){return o}}),n=0,o.addEventListener("loadeddata",(function(){n=2,r.trigger({type:"load",target:r})})),Rs?r||ce(e):e}return de(i,t),i}(ue);Dr.prototype.A={load:"load"},Dr.NONE=0,Dr.LOADING=1,Dr.LOADED=2,Dr.ERROR=3;var $r,Rr=function(){function t(i){void 0===i&&(i=[]);var s=this;if(Rs)for(var e in s=Ai.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);s.X=[],w.defineProperty(s,"length",{get:function(){return this.X.length}});for(var n=0,r=i.length;n<r;n++)s.J(i[n]);if(Rs)return s}var i=t.prototype;return i.J=function(t){var i=this.X.length;""+i in this||w.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}(),Or=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),Rs))for(var r in e=Ai.createElement("custom"),i.prototype)"constructor"!==r&&(e[r]=i.prototype[r]);e.Z=[],w.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)}de(i,t);var s=i.prototype;return s.tt=function(t){var i=this.Z.length;""+i in this||w.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}(ue);for($r in Or.prototype.A={change:"change",addtrack:"addtrack",removetrack:"removetrack"},Or.prototype.A)Or.prototype["on"+$r]=null;var Vr=function(t){function i(s){var e,n;if(void 0===s&&(s=[]),Rs){for(var r in n=Ai.createElement("custom"),Or.prototype)"constructor"!==r&&(n[r]=Or.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 de(i,t),i.prototype.tt=function(i){t.prototype.tt.call(this,i),i.addEventListener("modechange",he(this,(function(){this.trigger("change")})))},i}(Or),Ur=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].selected=!1)},zr=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){Ur(s,s[r]);break}if(Rs){for(var h in n=Ai.createElement("custom"),Or.prototype)"constructor"!==h&&(n[h]=Or.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,w.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)}de(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.selected&&Ur(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("selectedchange",(function(){s.st||(s.st=!0,Ur(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}(Or),Lr=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].enabled=!1)},Hr=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){Lr(s,s[r]);break}if(Rs){for(var h in n=Ai.createElement("custom"),Or.prototype)"constructor"!==h&&(n[h]=Or.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)}de(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.enabled&&Lr(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("enabledchange",(function(){s.st||(s.st=!0,Lr(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}(Or),qr=void 0;var Wr=function(i){function s(t,s){var e;return void 0===t&&(t={}),void 0===s&&(s=function(){}),t.reportTouchActivity=!1,(e=i.call(this,null,t,s)||this).et=!1,e.on("playing",(function(){this.et=!0})),e.on("loadstart",(function(){this.et=!1})),e.nt=t.textTracks,e.rt=t.videoTracks,e.ht=t.audioTracks,e.featuresProgressEvents||e.manualProgressOn(),e.featuresTimeupdateEvents||e.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach((function(i){!1===t["native"+i+"Tracks"]&&(e["featuresNative"+i+"Tracks"]=!1)})),!1===t.nativeCaptions&&(e.featuresNativeTextTracks=!1),e.featuresNativeTextTracks||e.emulateTextTracks(),e.ot=new Vr,e.initTextTrackListeners(),e.initTrackListeners(),t.nativeControlsForTouch||e.emitTapEvents(),e.constructor&&(e.l=e.constructor.name||"Unknown Tech"),e}de(s,i);var e=s.prototype;return e.manualProgressOn=function(){this.on("durationchange",this.onDurationChange),this.manualProgress=!0,this.one("ready",this.trackProgress)},e.manualProgressOff=function(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange)},e.trackProgress=function(t){this.stopTrackingProgress(),this.progressInterval=this.setInterval(he(this,(function(){var t=this.bufferedPercent();this.ut!==t&&this.trigger("progress"),this.ut=t,1===t&&this.stopTrackingProgress()})),500)},e.onDurationChange=function(t){this.ct=this.duration()},e.buffered=function(){return pe(0,0)},e.bufferedPercent=function(){return me(this.buffered(),this.ct)},e.stopTrackingProgress=function(){this.clearInterval(this.progressInterval)},e.manualTimeUpdatesOn=function(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime),this.on("pause",this.stopTrackingCurrentTime)},e.manualTimeUpdatesOff=function(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime),this.off("pause",this.stopTrackingCurrentTime)},e.trackCurrentTime=function(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval((function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}),250)},e.stopTrackingCurrentTime=function(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},e.dispose=function(){this.clearTracks(["audio","video","text"]),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),i.prototype.dispose.call(this)},e.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)}}))},e.cleanupAutoTextTracks=function(){for(var t=this.ot||[],i=t.length;i--;){var s=t[i];this.removeRemoteTextTrack(s)}},e.reset=function(){},e.error=function(t){return void 0!==t&&(this.lt=new Ce(t),this.trigger("error")),this.lt},e.played=function(){return this.et?pe(0,0):pe()},e.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},e.initTextTrackListeners=function(){var t=he(this,(function(){this.trigger("texttrackchange")})),i=this.textTracks();i&&(i.addEventListener("removetrack",t),i.addEventListener("addtrack",t),this.on("dispose",he(this,(function(){i.removeEventListener("removetrack",t),i.removeEventListener("addtrack",t)}))))},e.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)}))}))},e.dt=function(){var i=this;if(!t.WebVTT)if(Ai.body.contains(this.el())){if(!this.h["vtt.js"]&&Oi(qr)&&w.keys(qr).length>0)return void this.trigger("vttjsloaded");var s=Ai.createElement("script");s.src=this.h["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.12.4/vtt.min.js",s.onload=function(){i.trigger("vttjsloaded")},s.onerror=function(){i.trigger("vttjserror")},this.on("dispose",(function(){s.onload=null,s.onerror=null})),t.WebVTT=!0,this.el().parentNode.appendChild(s)}else this.ready(this.dt)},e.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.dt();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)}}))}},e.videoTracks=function(){return this.rt=this.rt||new zr,this.rt},e.audioTracks=function(){return this.ht=this.ht||new Hr,this.ht},e.textTracks=function(){return this.nt=this.nt||new Vr,this.nt},e.remoteTextTracks=function(){return this.ft=this.ft||new Vr,this.ft},e.remoteTextTrackEls=function(){return this.vt=this.vt||new Rr,this.vt},e.addTextTrack=function(t,i,s){if(!t)throw new g("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 Fr(n);return r.tt(h),h}(this,t,i,s)},e.createRemoteTextTrack=function(t){var i=ae(t,{tech:this});return new Dr(i)},e.addRemoteTextTrack=function(t,i){void 0===t&&(t={});var s=this.createRemoteTextTrack(t);return!0!==i&&!1!==i&&(Ui.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},e.removeRemoteTextTrack=function(t){var i=this.remoteTextTrackEls().Y(t);this.remoteTextTrackEls().K(i),this.remoteTextTracks().it(t),this.ot.it(t)},e.getVideoPlaybackQuality=function(){return{}},e.setPoster=function(){},e.playsinline=function(){},e.setPlaysinline=function(){},e.canPlayType=function(){return""},s.isTech=function(t){return t.prototype instanceof s||t instanceof s||t===s},s.registerTech=function(t,i){if(s.gt||(s.gt={}),!s.isTech(i))throw new g("Tech "+t+" must be a Tech");return s.gt[t]=i,i},s.getTech=function(i){return s.gt&&s.gt[i]?s.gt[i]:t&&t.videojs&&t.videojs[i]?(Ui.warn("The "+i+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),t.videojs[i]):void 0},s}(i);Wr.prototype.nt,Wr.prototype.ht,Wr.prototype.rt,Wr.prototype.featuresVolumeControl=!0,Wr.prototype.featuresFullscreenResize=!1,Wr.prototype.featuresPlaybackRate=!1,Wr.prototype.featuresProgressEvents=!1,Wr.prototype.featuresTimeupdateEvents=!1,Wr.prototype.featuresNativeTextTracks=!1,Wr.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:Ui.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.kt),this.off(this.v,"loadstart",t.prototype.wt),this.one(this.v,"loadstart",t.prototype.kt)),this.yt=s.handleSource(i,this,this.h),this.on("dispose",this.disposeSourceHandler),this},t.prototype.kt=function(){this.one(this.v,"loadstart",t.prototype.wt)},t.prototype.wt=function(){this.disposeSourceHandler(),this.one(this.v,"loadstart",t.prototype.wt)},t.prototype.disposeSourceHandler=function(){this.bt&&(this.clearTracks(["audio","video"]),this.bt=null),this.cleanupAutoTextTracks(),this.yt&&(this.off(this.v,"loadstart",t.prototype.kt),this.off(this.v,"loadstart",t.prototype.wt),this.yt.dispose&&this.yt.dispose(),this.yt=null)}},i.registerComponent("Tech",Wr),i.registerComponent("MediaTechController",Wr),Wr.registerTech("Tech",Wr);var Gr=function(t){function s(s,e,n){var r;if(r=t.call(this,s,e,n)||this,e.playerOptions.sources&&0!==e.playerOptions.sources.length)s.src(e.playerOptions.sources);else for(var h=0,o=e.playerOptions.techOrder;h<o.length;h++){var a=oe(o[h]),u=Wr.getTech(a);if(a||(u=i.getComponent(a)),u&&u.isSupported()){s._t(a);break}}return r}return de(s,t),s}(i);i.registerComponent("MediaLoader",Gr);var Xr=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}de(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=$i({className:this.buildCSSClass(),tabIndex:0},s),"button"===i&&Ui.error("Creating a ClickableComponent with an HTML element of "+i+" is not supported; use a Button instead."),e=$i({role:"button","aria-live":"polite"},e),this.xt=s.tabIndex;var n=t.prototype.createEl.call(this,i,s,e);return this.createControlTextEl(n),n},s.createControlTextEl=function(t){return this.Ct=Yi("span",{className:"vjs-control-text"}),t&&t.appendChild(this.Ct),this.controlText(this.St,t),this.Ct},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.Ct.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.xt&&this.v.setAttribute("tabIndex",this.xt),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.xt&&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){Qs(Ai,"keydown",he(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){Ys(Ai,"keydown",he(this,this.handleKeyPress))},i}(i);i.registerComponent("ClickableComponent",Xr);var Jr=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).update(),i.on("posterchange",he(ce(e),e.update)),e}de(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=Yi("div",{className:"vjs-poster",tabIndex:-1});return Ls||(this.jt=Yi("img"),t.appendChild(this.jt)),t},s.update=function(t){var i=this.player().poster();this.setSrc(i),i?this.show():this.hide()},s.setSrc=function(t){if(this.jt)this.jt.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}(Xr);i.registerComponent("PosterImage",Jr);var Qr="#222",Yr={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 Kr(t,i){return"rgba("+x(t[1]+t[1],16)+","+x(t[2]+t[2],16)+","+x(t[3]+t[3],16)+","+i+")"}function Zr(t,i,s){try{t.style[i]=s}catch(t){return}}var th=function(i){function s(t,s,e){var n;return n=i.call(this,t,s,e)||this,t.on("loadstart",he(ce(n),n.toggleDisplay)),t.on("texttrackchange",he(ce(n),n.updateDisplay)),t.ready(he(ce(n),(function(){if(t.H&&t.H.featuresNativeTextTracks)this.hide();else{t.on("fullscreenchange",he(this,this.updateDisplay));for(var i=this.h.playerOptions.tracks||[],s=0;s<i.length;s++)this.t.addRemoteTextTrack(i[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}de(s,i);var e=s.prototype;return e.toggleDisplay=function(){this.t.H&&this.t.H.featuresNativeTextTracks?this.hide():this.show()},e.createEl=function(){return i.prototype.createEl.call(this,"div",{className:"vjs-text-track-display"},{"aria-live":"off","aria-atomic":"true"})},e.clearDisplay=function(){"function"==typeof t.WebVTT&&t.WebVTT.processCues(t,[],this.v)},e.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))}},e.updateForTrack=function(i){if("function"==typeof t.WebVTT&&i.activeCues){for(var s=this.t.textTrackSettings.getValues(),e=[],n=0;n<i.activeCues.length;n++)e.push(i.activeCues[n]);t.WebVTT.processCues(t,e,this.v);for(var r=e.length;r--;){var h=e[r];if(h){var o=h.displayState;if(s.color&&(o.firstChild.style.color=s.color),s.textOpacity&&Zr(o.firstChild,"color",Kr(s.color||"#fff",s.textOpacity)),s.backgroundColor&&(o.firstChild.style.backgroundColor=s.backgroundColor),s.backgroundOpacity&&Zr(o.firstChild,"backgroundColor",Kr(s.backgroundColor||"#000",s.backgroundOpacity)),s.windowColor&&(s.windowOpacity?Zr(o,"backgroundColor",Kr(s.windowColor,s.windowOpacity)):o.style.backgroundColor=s.windowColor),s.edgeStyle&&("dropshadow"===s.edgeStyle?o.firstChild.style.textShadow="2px 2px 3px #222, 2px 2px 4px #222, 2px 2px 5px "+Qr:"raised"===s.edgeStyle?o.firstChild.style.textShadow="1px 1px #222, 2px 2px #222, 3px 3px "+Qr:"depressed"===s.edgeStyle?o.firstChild.style.textShadow="1px 1px #ccc, 0 1px #ccc, -1px -1px #222, 0 -1px "+Qr:"uniform"===s.edgeStyle&&(o.firstChild.style.textShadow="0 0 4px #222, 0 0 4px #222, 0 0 4px #222, 0 0 4px "+Qr)),s.fontPercent&&1!==s.fontPercent){var a=t.parseFloat(o.style.fontSize);o.style.fontSize=a*s.fontPercent+"px",o.style.height="auto",o.style.top="auto",o.style.bottom="2px"}s.fontFamily&&"default"!==s.fontFamily&&("small-caps"===s.fontFamily?o.firstChild.style.fontVariant="small-caps":o.firstChild.style.fontFamily=Yr[s.fontFamily])}}}},s}(i);i.registerComponent("TextTrackDisplay",th);var ih=function(t){function i(){return t.apply(this,arguments)||this}return de(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"})},i}(i);i.registerComponent("LoadingSpinner",ih);var sh=function(t){function s(){return t.apply(this,arguments)||this}de(s,t);var e=s.prototype;return e.createEl=function(t,s,e){void 0===t&&(t="button"),void 0===s&&(s={}),void 0===e&&(e={}),s=$i({className:this.buildCSSClass()},s),"button"!==t&&(Ui.warn("Creating a Button with an HTML element of "+t+" is deprecated; use ClickableComponent instead."),s=$i({tabIndex:0},s),e=$i({role:"button"},e)),e=$i({type:"button","aria-live":"polite"},e);var n=i.prototype.createEl.call(this,t,s,e);return this.createControlTextEl(n),n},e.addChild=function(t,s){void 0===s&&(s={});var e=this.constructor.name;return Ui.warn("Adding an actionable (user controllable) child to a Button ("+e+") is not supported; use a ClickableComponent instead."),i.prototype.addChild.call(this,t,s)},e.enable=function(){t.prototype.enable.call(this),this.v.removeAttribute("disabled")},e.disable=function(){t.prototype.disable.call(this),this.v.setAttribute("disabled","disabled")},e.handleKeyPress=function(i){32!==i.which&&13!==i.which&&t.prototype.handleKeyPress.call(this,i)},s}(Xr);i.registerComponent("Button",sh);var eh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Tt=!1,e.on("mousedown",e.handleMouseDown),e}de(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-big-play-button"},s.handleClick=function(t){var i=this;if(this.Tt&&t.clientX&&t.clientY)this.t.play();else{var s=this.t.getChild("controlBar"),e=s&&s.getChild("playToggle");this.one(this.t,"play",(function(){e?e.focus():i.t.focus()})),this.t.play()}},s.handleKeyPress=function(i){this.Tt=!1,t.prototype.handleKeyPress.call(this,i)},s.handleMouseDown=function(t){this.Tt=!0},i}(sh);eh.prototype.St="Play Video",i.registerComponent("BigPlayButton",eh);var nh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).controlText(s&&s.controlText||"Close"),e}de(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}(sh);i.registerComponent("CloseButton",nh);var rh=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}de(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}(sh);function hh(t,i){void 0===i&&(i=t),t=t<0?0:t;var s=_.floor(t%60),e=_.floor(t/60%60),n=_.floor(t/3600),r=_.floor(i/60%60),h=_.floor(i/3600);return(S(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)}rh.prototype.St="Play",i.registerComponent("PlayToggle",rh);var oh=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}de(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=Yi("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=hh(i,this.t.duration());e!==this.Mt&&(this.Mt=e,this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e)},i}(i);i.registerComponent("CurrentTimeDisplay",oh);var ah=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}de(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=Yi("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=hh(i);this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e}},i}(i);i.registerComponent("DurationDisplay",ah);var uh=function(t){function i(){return t.apply(this,arguments)||this}return de(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}(i);i.registerComponent("TimeDivider",uh);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}de(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=Yi("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=hh(this.t.remainingTime());s!==this.Mt&&(this.Mt=s,this.S.innerHTML='<span class="vjs-control-text">'+i+"</span> -"+s)}},i}(i);i.registerComponent("RemainingTimeDisplay",ch);var lh=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}de(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=Yi("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.Ct=Yi("span",{className:"vjs-control-text",innerHTML:this.localize("Stream Type")}),this.At=Ai.createTextNode(this.localize("LIVE")),this.S.appendChild(this.Ct),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.Ct.innerHTML=this.localize("Stream Type"),this.At.innerHTML=this.localize("LIVE")},i}(i);i.registerComponent("LiveDisplay",lh);var dh=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}de(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=$i({tabIndex:0},s),e=$i({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(),Ai.body.focus(),Ai.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;Ai.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=vs(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.Pt||!1:(this.Pt=!!t,this.Pt?this.addClass("vjs-slider-vertical"):this.addClass("vjs-slider-horizontal"),this)},i}(i);function fh(i,s){if(!i||!s)return"";if("function"==typeof t.getComputedStyle){var e=t.getComputedStyle(i);return e?e[s]:""}return i.currentStyle[s]||""}i.registerComponent("Slider",dh);var vh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Et=[],e.on(i,"progress",e.update),e.on(i,"languagechange",e.handleLanguagechange),e}de(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-load-progress"});return this.Nt=Yi("span",{innerHTML:this.localize("Loaded")}),this.Bt=Ai.createTextNode(": 0%"),this.Ct=Yi("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.Nt),this.Ct.appendChild(this.Bt),i.appendChild(this.Ct),i},s.update=function(t){var i=this.t.buffered(),s=this.t.duration(),e=this.t.bufferedEnd(),n=this.Et,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(Yi()),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.Nt.innerHTML=this.localize("Loaded")},i}(i);i.registerComponent("LoadProgressBar",vh);var ph=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(he(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}de(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.It=Yi("span",{innerHTML:this.localize("Progress")}),this.Ft=Ai.createTextNode(": 0%"),this.Ct=Yi("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.It),this.Ct.appendChild(this.Ft),i.appendChild(this.Ct),i},s.updateDataAttr=function(t){var i=this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime();this.v.setAttribute("data-current-time",hh(i,this.t.duration()))},s.handleLanguagechange=function(){this.It.innerHTML=this.localize("Progress")},i}(i);i.registerComponent("PlayProgressBar",ph);var mh=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(he(ce(e),e.updateDataAttr)),e}de(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=Yi("div",{className:"vjs-time-tooltip"}),this.It=Yi("span",{innerHTML:this.localize("Progress")}),this.Ft=Ai.createTextNode(": 0%"),this.Ct=Yi("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.It),this.Ct.appendChild(this.Ft),i.appendChild(this.tooltip),i.appendChild(this.Ct),i},s.updateDataAttr=function(t){var i=hh(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.It.innerHTML=this.localize("Progress")},i}(i);i.registerComponent("TooltipProgressBar",mh);var gh=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(he(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}de(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=C(fh(this.player().el(),"width")),s=C(fh(this.tooltipProgressBar.tooltip,"width")),e=this.tooltipProgressBar.el().style;e.maxWidth=_.floor(i-s/2)+"px",e.minWidth=_.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",hh(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}(dh);gh.prototype.h={children:["loadProgressBar","mouseTimeDisplay","playProgressBar"],barName:"playProgressBar"},gh.prototype.playerEvent="timeupdate",i.registerComponent("SeekBar",gh);var yh=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=Yi("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)}}(he(ce(e),e.handleMouseMove),25))})),e}de(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-fs(this.el().parentNode).left;this.update(s,e)},s.update=function(t,i){var s=hh(t,this.t.duration());if(this.el().style.left=i+"px",this.el().setAttribute("data-current-time",s),this.keepTooltipsInside){var e=i-this.Dt(i)+1,n=C(fh(this.tooltip,"width"))/2;this.tooltip.innerHTML=s,this.tooltip.style.right="-"+(n-e)+"px"}},s.calculateDistance=function(t){return vs(this.el().parentNode,t).x},s.Dt=function(t){if(!this.keepTooltipsInside)return t;var i=C(fh(this.player().el(),"width")),s=C(fh(this.tooltip,"width"))/2,e=t;return t<s?e=_.ceil(s):t>i-s&&(e=_.floor(i-s)),e},i}(i);i.registerComponent("MouseTimeDisplay",yh);var bh=function(t){function i(){return t.apply(this,arguments)||this}return de(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},i}(i);bh.prototype.h={children:["seekBar"]},i.registerComponent("ProgressControl",bh);var kh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"fullscreenchange",e.handleFullscreenChange),e}de(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}(sh);kh.prototype.St="Fullscreen",i.registerComponent("FullscreenToggle",kh);var wh=function(t){function i(){return t.apply(this,arguments)||this}return de(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}(i);i.registerComponent("VolumeLevel",wh);var _h=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.updateARIAAttributes),i.ready(he(ce(e),e.updateARIAAttributes)),e}de(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}(dh);_h.prototype.h={children:["volumeLevel"],barName:"volumeLevel"},_h.prototype.playerEvent="volumechange",i.registerComponent("VolumeBar",_h);var xh=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 de(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control"})},i}(i);xh.prototype.h={children:["volumeBar"]},i.registerComponent("VolumeControl",xh);var Ch=function(t){function i(){return t.apply(this,arguments)||this}de(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",he(this,(function(){this.unlockShowing()})))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=Yi(i,{className:"vjs-menu-content"});var s=t.prototype.createEl.call(this,"div",{append:this.S,className:"vjs-menu"});return s.appendChild(this.S),Qs(s,"click",(function(t){t.preventDefault(),t.stopImmediatePropagation()})),s},i}(i);i.registerComponent("Popup",Ch);var Sh=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e}de(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}(Xr);i.registerComponent("PopupButton",Sh);var jh=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}de(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++)os(this.v,"vjs-vol-"+n);hs(this.v,"vjs-vol-"+s)},i}(sh);jh.prototype.St="Mute",i.registerComponent("MuteToggle",jh);var Th=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}de(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 Ch(this.t,{contentElType:"div"}),i=new _h(this.t,this.h.volumeBar);return t.addChild(i),this.menuContent=t,this.volumeBar=i,this.attachVolumeBarEvents(),t},s.handleClick=function(i){jh.prototype.handleClick.call(this),t.prototype.handleClick.call(this)},s.attachVolumeBarEvents=function(){this.menuContent.on(["mousedown","touchdown"],he(this,this.handleMouseDown))},s.handleMouseDown=function(t){this.on(["mousemove","touchmove"],he(this.volumeBar,this.volumeBar.handleMouseMove)),this.on(this.v.ownerDocument,["mouseup","touchend"],this.handleMouseUp)},s.handleMouseUp=function(t){this.off(["mousemove","touchmove"],he(this.volumeBar,this.volumeBar.handleMouseMove))},i}(Sh);Th.prototype.volumeUpdate=jh.prototype.update,Th.prototype.St="Mute",i.registerComponent("VolumeMenuButton",Th);var Mh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).$t=-1,e.on("keydown",e.handleKeyPress),e}de(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",he(this,(function(t){this.unlockShowing()})))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=Yi(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),Qs(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.$t&&(t=this.$t+1),this.focus(t)},s.stepBack=function(){var t=0;void 0!==this.$t&&(t=this.$t-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.$t=t,i[t].v.focus())},i}(i);i.registerComponent("Menu",Mh);var Ah=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}de(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 Mh(this.t);if(this.Vt=0,this.h.title){var i=Yi("li",{className:"vjs-menu-title",innerHTML:oe(this.h.title),tabIndex:-1});this.Vt+=1,t.m.unshift(i),Zi(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",he(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}(Xr);i.registerComponent("MenuButton",Ah);var Ph=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=he(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 de(i,t),i}(Ah);i.registerComponent("TrackButton",Ph);var Eh=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}de(i,t);var s=i.prototype;return s.createEl=function(i,s,e){this.nonIconControl=!0;var n=t.prototype.createEl.call(this,"li",$i({className:"vjs-menu-item",tabIndex:-1},s),e);return this.Ut=Ai.createTextNode(this.localize(this.h.label)),n.appendChild(this.Ut),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.Ut.innerHTML=this.localize(this.h.label)},i}(Xr);i.registerComponent("MenuItem",Eh);var Nh=function(i){function s(s,e){var n,r,h=e.track,o=s.textTracks();if(e.label=h.label||h.language||"Unknown",e.selected=h.default||"showing"===h.mode,(n=i.call(this,s,e)||this).track=h,o){var a=he(ce(n),n.handleTracksChange);s.on(["loadstart","texttrackchange"],a),o.addEventListener("change",a),n.on("dispose",(function(){o.removeEventListener("change",a)}))}o&&void 0===o.onchange&&n.on(["tap","click"],(function(){if("object"!=typeof t.Event)try{r=new t.Event("change")}catch(t){}r||(r=Ai.createEvent("Event")).initEvent("change",!0,!0),o.dispatchEvent(r)}));return n}de(s,i);var e=s.prototype;return e.handleClick=function(t){var s=this.track.kind,e=this.t.textTracks();if(i.prototype.handleClick.call(this,t),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"))}},e.handleTracksChange=function(t){this.selected("showing"===this.track.mode)},s}(Eh);i.registerComponent("TextTrackMenuItem",Nh);var Bh=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 de(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}(Nh);i.registerComponent("OffTextTrackMenuItem",Bh);var Ih=function(t){function i(i,s){return void 0===s&&(s={}),s.tracks=i.textTracks(),t.call(this,i,s)||this}return de(i,t),i.prototype.createItems=function(t){void 0===t&&(t=[]),t.push(new Bh(this.t,{kind:this.zt})),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.zt&&t.push(new Nh(this.t,{track:e,selectable:!0}))}return t},i}(Ph);i.registerComponent("TextTrackButton",Ih);var Fh=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",he(ce(e),e.update)),e}de(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}(Eh);i.registerComponent("ChaptersTrackMenuItem",Fh);var Dh=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}de(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-chapters-button "+t.prototype.buildCSSClass.call(this)},s.update=function(i){this.Lt&&(!i||"addtrack"!==i.type&&"removetrack"!==i.type)||this.setTrack(this.findChaptersTrack()),t.prototype.update.call(this)},s.setTrack=function(t){if(this.Lt!==t){if(this.Ht||(this.Ht=this.update.bind(this)),this.Lt){var i=this.t.remoteTextTrackEls().Y(this.Lt);i&&i.removeEventListener("load",this.Ht),this.Lt=null}if(this.Lt=t,this.Lt){this.Lt.mode="hidden";var s=this.t.remoteTextTrackEls().Y(this.Lt);s&&s.addEventListener("load",this.Ht)}}},s.findChaptersTrack=function(){for(var t=this.t.textTracks()||[],i=t.length-1;i>=0;i--){var s=t[i];if(s.kind===this.zt)return s}},s.getMenuCaption=function(){return this.Lt&&this.Lt.label?this.Lt.label:this.localize(oe(this.zt))},s.createMenu=function(){return this.h.title=this.getMenuCaption(),t.prototype.createMenu.call(this)},s.createItems=function(){var t=[];if(!this.Lt)return t;var i=this.Lt.cues;if(!i)return t;for(var s=0,e=i.length;s<e;s++){var n=i[s],r=new Fh(this.t,{track:this.Lt,cue:n});t.push(r)}return t},i}(Ih);Dh.prototype.zt="chapters",Dh.prototype.St="Chapters",i.registerComponent("ChaptersButton",Dh);var $h=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=he(ce(n),n.handleTracksChange);r.addEventListener("change",h),n.on("dispose",(function(){r.removeEventListener("change",h)}))}return n}de(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.zt&&"showing"===r.mode){s=!0;break}}s?this.disable():this.enable()},s.buildCSSClass=function(){return"vjs-descriptions-button "+t.prototype.buildCSSClass.call(this)},i}(Ih);$h.prototype.zt="descriptions",$h.prototype.St="Descriptions",i.registerComponent("DescriptionsButton",$h);var Rh=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 de(i,t),i.prototype.buildCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildCSSClass.call(this)},i}(Ih);Rh.prototype.zt="subtitles",Rh.prototype.St="Subtitles",i.registerComponent("SubtitlesButton",Rh);var Oh=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 de(i,t),i.prototype.handleClick=function(t){this.player().getChild("textTrackSettings").show(),this.player().getChild("textTrackSettings").v.focus()},i}(Nh);i.registerComponent("CaptionSettingsMenuItem",Oh);var Vh=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}de(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 Oh(this.t,{kind:this.zt})),this.Vt+=1),t.prototype.createItems.call(this,i)},i}(Ih);Vh.prototype.zt="captions",Vh.prototype.St="Captions",i.registerComponent("CaptionsButton",Vh);var Uh=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=he(ce(e),e.handleTracksChange);r.addEventListener("change",h),e.on("dispose",(function(){r.removeEventListener("change",h)}))}return e}de(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}(Eh);i.registerComponent("AudioTrackMenuItem",Uh);var zh=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}de(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 Uh(this.t,{track:e,selectable:!0}))}return t},i}(Ph);zh.prototype.St="Audio Track",i.registerComponent("AudioTrackButton",zh);var Lh=function(t){function i(i,s){var e,n=s.rate,r=C(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}de(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}(Eh);Lh.prototype.contentElType="button",i.registerComponent("PlaybackRateMenuItem",Lh);var Hh=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}de(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this);return this.Ut=Yi("div",{className:"vjs-playback-rate-value",innerHTML:1}),i.appendChild(this.Ut),i},s.buildCSSClass=function(){return"vjs-playback-rate "+t.prototype.buildCSSClass.call(this)},s.createMenu=function(){var t=new Mh(this.player()),i=this.playbackRates();if(i)for(var s=i.length-1;s>=0;s--)t.addChild(new Lh(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.Ut.innerHTML=this.player().playbackRate()+"x")},i}(Ah);Hh.prototype.St="Playback Rate",i.registerComponent("PlaybackRateMenuButton",Hh);var qh=function(t){function i(){return t.apply(this,arguments)||this}de(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}(i);i.registerComponent("Spacer",qh);var Wh=function(t){function i(){return t.apply(this,arguments)||this}de(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}(qh);i.registerComponent("CustomControlSpacer",Wh);var Gh=function(t){function i(){return t.apply(this,arguments)||this}return de(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"},{role:"group"})},i}(i);Gh.prototype.h={children:["playToggle","volumeMenuButton","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subtitlesButton","captionsButton","audioTrackButton","fullscreenToggle"]},i.registerComponent("ControlBar",Gh);var Xh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"error",e.open),e}de(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}(Pe);Xh.prototype.h=ae(Pe.prototype.h,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),i.registerComponent("ErrorDisplay",Xh);var Jh="vjs-text-track-settings",Qh=["#000","Black"],Yh=["#00F","Blue"],Kh=["#0FF","Cyan"],Zh=["#0F0","Green"],to=["#F0F","Magenta"],io=["#F00","Red"],so=["#FFF","White"],eo=["#FF0","Yellow"],no=["1","Opaque"],ro=["0.5","Semi-Transparent"],ho=["0","Transparent"],oo={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[Qh,so,io,Zh,Yh,eo,to,Kh]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[no,ro,ho]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[so,Qh,io,Zh,Yh,eo,to,Kh]},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:[no,ro]},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:[ho,ro,no]}};function ao(t,i){if(i&&(t=i(t)),t&&"none"!==t)return t}oo.windowColor.options=oo.backgroundColor.options;var uo,co=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).setDefaults(),e.hide(),e.updateDisplay=he(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()})),Di(oo,(function(t){e.on(e.$(t.selector),"change",e.updateDisplay)})),e.h.persistTextTrackSettings&&e.restoreSettings(),e}de(s,i);var e=s.prototype;return e.qt=function(t){var i=this,s=oo[t],e=s.id.replace("%s",this.o);return[Yi("label",{className:"vjs-label",textContent:s.label},{for:e}),Yi("select",{id:e},void 0,s.options.map((function(t){return Yi("option",{textContent:i.localize(t[1]),value:t[0]})})))]},e.Wt=function(){var t=Yi("legend",{textContent:this.localize("Text")}),i=this.qt("color"),s=Yi("span",{className:"vjs-text-opacity vjs-opacity"},void 0,this.qt("textOpacity"));return Yi("fieldset",{className:"vjs-fg-color vjs-tracksetting"},void 0,[t].concat(i,s))},e.Gt=function(){var t=Yi("legend",{textContent:this.localize("Background")}),i=this.qt("backgroundColor"),s=Yi("span",{className:"vjs-bg-opacity vjs-opacity"},void 0,this.qt("backgroundOpacity"));return Yi("fieldset",{className:"vjs-bg-color vjs-tracksetting"},void 0,[t].concat(i,s))},e.Xt=function(){var t=Yi("legend",{textContent:this.localize("Window")}),i=this.qt("windowColor"),s=Yi("span",{className:"vjs-window-opacity vjs-opacity"},void 0,this.qt("windowOpacity"));return Yi("fieldset",{className:"vjs-window-color vjs-tracksetting"},void 0,[t].concat(i,s))},e.Jt=function(){return Yi("div",{className:"vjs-tracksettings-colors"},void 0,[this.Wt(),this.Gt(),this.Xt()])},e.Qt=function(){var t=Yi("div",{className:"vjs-font-percent vjs-tracksetting"},void 0,this.qt("fontPercent")),i=Yi("div",{className:"vjs-edge-style vjs-tracksetting"},void 0,this.qt("edgeStyle")),s=Yi("div",{className:"vjs-font-family vjs-tracksetting"},void 0,this.qt("fontFamily"));return Yi("div",{className:"vjs-tracksettings-font"},void 0,[t,i,s])},e.Yt=function(){var t=Yi("button",{className:"vjs-default-button",textContent:this.localize("Defaults")}),i=Yi("button",{className:"vjs-done-button",textContent:"Done"});return Yi("div",{className:"vjs-tracksettings-controls"},void 0,[t,i])},e.createEl=function(){var t=Yi("div",{className:"vjs-tracksettings"},void 0,[this.Jt(),this.Qt(),this.Yt()]),i=Yi("div",{className:"vjs-control-text",id:"TTsettingsDialogLabel-"+this.o,textContent:"Caption Settings Dialog"},{"aria-level":"1",role:"heading"}),s=Yi("div",{className:"vjs-control-text",id:"TTsettingsDialogDescription-"+this.o,textContent:"Beginning of dialog window. Escape will cancel and close the window."}),e=Yi("div",void 0,{role:"document"},[i,s,t]);return Yi("div",{className:"vjs-caption-settings vjs-modal-overlay",tabIndex:-1},{role:"dialog","aria-labelledby":i.id,"aria-describedby":s.id},e)},e.getValues=function(){var t=this;return function(t,i,s){return void 0===s&&(s=0),Fi(t).reduce((function(s,e){return i(s,t[e],e)}),s)}(oo,(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}),{})},e.setValues=function(t){var i=this;Di(oo,(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)}))},e.setDefaults=function(){var t=this;Di(oo,(function(i){var s=i.hasOwnProperty("default")?i.default:0;t.$(i.selector).selectedIndex=s}))},e.restoreSettings=function(){var i;try{i=JSON.parse(t.localStorage.getItem(Jh))}catch(t){Ui.warn(t)}i&&this.setValues(i)},e.saveSettings=function(){if(this.h.persistTextTrackSettings){var i=this.getValues();try{w.keys(i).length?t.localStorage.setItem(Jh,JSON.stringify(i)):t.localStorage.removeItem(Jh)}catch(t){Ui.warn(t)}}},e.updateDisplay=function(){var t=this.t.getChild("textTrackDisplay");t&&t.updateDisplay()},s}(i);i.registerComponent("TextTrackSettings",co);var lo,fo=function(i){function s(t,s){var e;e=i.call(this,t,s)||this;var n=t.source,r=!1;if(n&&(e.v.currentSrc!==n.src||t.tag&&3===t.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")||!Re(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=oe(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&&Ui.warn(qi(uo||(uo=Pi(["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=he(ce(e),e.handleTextTrackChange),e.hi=he(ce(e),e.handleTextTrackAdd),e.oi=he(ce(e),e.handleTextTrackRemove),e.ai()),e.ci(),(zs||js||Bs)&&!0===t.nativeControlsForTouch&&e.setControls(!0),e.di(),e.triggerReady(),e}de(s,i);var e=s.prototype;return e.dispose=function(){var t=this;["audio","video","text"].forEach((function(i){var s=oe(i),e=t.v[i+"Tracks"];e&&e.removeEventListener&&(e.removeEventListener("change",t["handle"+s+"ti"]),e.removeEventListener("addtrack",t["handle"+s+"ii"]),e.removeEventListener("removetrack",t["handle"+s+"si"])),e&&t.off("loadstart",t["removeOld"+s+"ei"])})),s.disposeMediaElement(this.v),i.prototype.dispose.call(this)},e.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)}))},e.createEl=function(){var t=this.h.tag;if(!t||!this.h.playerElIngest&&!this.movingMediaElementInDOM){if(t){var i=t.cloneNode(!0);t.parentNode&&t.parentNode.insertBefore(i,t),s.disposeMediaElement(t),t=i}else{t=Ai.createElement("video");var e=ae({},this.h.tag&&cs(this.h.tag));zs&&!0===this.h.nativeControlsForTouch||delete e.controls,us(t,$i(e,{id:this.h.techId,class:"vjs-tech"}))}t.playerId=this.h.playerId}void 0!==this.h.preload&&ls(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?ls(t,h,h):ds(t,h),t[h]=o)}return t},e.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)}))}},e.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.fi)}},e.handleTextTrackChange=function(t){var i=this.textTracks();this.textTracks().trigger({type:"change",target:i,currentTarget:i,srcElement:i})},e.handleTextTrackAdd=function(t){this.textTracks().tt(t.track)},e.handleTextTrackRemove=function(t){this.textTracks().it(t.track)},e.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)}}},e.fi=function(t){var i=this.textTracks(),s=this.el().textTracks;this.ni(i,s)},e.play=function(){var t=this.v.play();void 0!==t&&"function"==typeof t.then&&t.then(null,(function(t){}))},e.setCurrentTime=function(t){try{this.v.currentTime=t}catch(t){Ui(t,"Video is not ready. (Video.js)")}},e.duration=function(){var t=this;if(this.v.duration===1/0&&Ps&&Ds&&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},e.width=function(){return this.v.offsetWidth},e.height=function(){return this.v.offsetHeight},e.di=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)}))}},e.supportsFullScreen=function(){if("function"==typeof this.v.webkitEnterFullScreen){var i=t.navigator&&t.navigator.userAgent||"";if(/Android/.test(i)||!/Chrome|Mac OS X 10.5/.test(i))return!0}return!1},e.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()},e.exitFullScreen=function(){this.v.webkitExitFullScreen()},e.src=function(t){if(void 0===t)return this.v.src;this.setSrc(t)},e.reset=function(){s.resetMediaElement(this.v)},e.currentSrc=function(){return this.bt?this.bt.src:this.v.currentSrc},e.setControls=function(t){this.v.controls=!!t},e.addTextTrack=function(t,s,e){return this.featuresNativeTextTracks?this.v.addTextTrack(t,s,e):i.prototype.addTextTrack.call(this,t,s,e)},e.createRemoteTextTrack=function(t){if(!this.featuresNativeTextTracks)return i.prototype.createRemoteTextTrack.call(this,t);var s=Ai.createElement("track");return t.kind&&(s.kind=t.kind),t.label&&(s.label=t.label),(t.language||t.srclang)&&(s.srclang=t.language||t.srclang),t.default&&(s.default=t.default),t.id&&(s.id=t.id),t.src&&(s.src=t.src),s},e.addRemoteTextTrack=function(t,s){var e=i.prototype.addRemoteTextTrack.call(this,t,s);return this.featuresNativeTextTracks&&this.el().appendChild(e),e},e.removeRemoteTextTrack=function(t){if(i.prototype.removeRemoteTextTrack.call(this,t),this.featuresNativeTextTracks)for(var s=this.$$("track"),e=s.length;e--;)t!==s[e]&&t!==s[e].track||this.el().removeChild(s[e])},e.getVideoPlaybackQuality=function(){if("function"==typeof this.el().getVideoPlaybackQuality)return this.el().getVideoPlaybackQuality();var i={};return void 0!==this.el().webkitDroppedFrameCount&&void 0!==this.el().webkitDecodedFrameCount&&(i.droppedVideoFrames=this.el().webkitDroppedFrameCount,i.totalVideoFrames=this.el().webkitDecodedFrameCount),t.performance&&"function"==typeof t.performance.now?i.creationTime=t.performance.now():t.performance&&t.performance.timing&&"number"==typeof t.performance.timing.navigationStart&&(i.creationTime=t.Date.now()-t.performance.timing.navigationStart),i},s}(Wr);Xi()&&(fo.TEST_VID=Ai.createElement("video"),(lo=Ai.createElement("track")).kind="captions",lo.srclang="en",lo.label="English",fo.TEST_VID.appendChild(lo)),fo.isSupported=function(){try{fo.TEST_VID.volume=.5}catch(t){return!1}return!(!fo.TEST_VID||!fo.TEST_VID.canPlayType)},fo.canControlVolume=function(){try{var t=fo.TEST_VID.volume;return fo.TEST_VID.volume=t/2+.1,t!==fo.TEST_VID.volume}catch(t){return!1}},fo.canControlPlaybackRate=function(){if(Ps&&Ds&&$s<58)return!1;try{var t=fo.TEST_VID.playbackRate;return fo.TEST_VID.playbackRate=t/2+.1,t!==fo.TEST_VID.playbackRate}catch(t){return!1}},fo.supportsNativeTextTracks=function(){return Us},fo.supportsNativeVideoTracks=function(){return!(!fo.TEST_VID||!fo.TEST_VID.videoTracks)},fo.supportsNativeAudioTracks=function(){return!(!fo.TEST_VID||!fo.TEST_VID.audioTracks)},fo.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange"],fo.prototype.featuresVolumeControl=fo.canControlVolume(),fo.prototype.featuresPlaybackRate=fo.canControlPlaybackRate(),fo.prototype.movingMediaElementInDOM=!Ms,fo.prototype.featuresFullscreenResize=!0,fo.prototype.featuresProgressEvents=!0,fo.prototype.featuresTimeupdateEvents=!0,fo.prototype.featuresNativeTextTracks=fo.supportsNativeTextTracks(),fo.prototype.featuresNativeVideoTracks=fo.supportsNativeVideoTracks(),fo.prototype.featuresNativeAudioTracks=fo.supportsNativeAudioTracks();var vo=fo.TEST_VID&&fo.TEST_VID.constructor.prototype.canPlayType,po=/^application\/(?:x-|vnd\.apple\.)mpegurl/i,mo=/^video\/mp4/i;fo.patchCanPlayType=function(){Es>=4&&!Is?fo.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&po.test(t)?"maybe":vo.call(this,t)}:Ns&&(fo.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&mo.test(t)?"maybe":vo.call(this,t)})},fo.unpatchCanPlayType=function(){var t=fo.TEST_VID.constructor.prototype.canPlayType;return fo.TEST_VID.constructor.prototype.canPlayType=vo,t},fo.patchCanPlayType(),fo.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){}}()}}},fo.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){fo.prototype[t]=function(){return this.v[t]||this.v.hasAttribute(t)}})),["muted","defaultMuted","autoplay","loop","playsinline"].forEach((function(t){fo.prototype["set"+oe(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){fo.prototype[t]=function(){return this.v[t]}})),["volume","src","poster","preload","playbackRate"].forEach((function(t){fo.prototype["set"+oe(t)]=function(i){this.v[t]=i}})),["pause","load"].forEach((function(t){fo.prototype[t]=function(){return this.v[t]()}})),Wr.withSourceHandlers(fo),fo.nativeSourceHandler={},fo.nativeSourceHandler.canPlayType=function(t){try{return fo.TEST_VID.canPlayType(t)}catch(t){return""}},fo.nativeSourceHandler.canHandleSource=function(t,i){if(t.type)return fo.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 fo.nativeSourceHandler.canPlayType("video/"+s)}return""},fo.nativeSourceHandler.handleSource=function(t,i,s){i.setSrc(t.src)},fo.nativeSourceHandler.dispose=function(){},fo.registerSourceHandler(fo.nativeSourceHandler),i.registerComponent("Html5",fo),Wr.registerTech("Html5",fo);var go=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","ratechange","volumechange","texttrackchange"],yo=function(s){function e(t,i,n){var r;if(t.id=t.id||["vjs_video",Ni()].join("_"),(i=$i(e.getTagSettings(t),i)).initChildren=!1,i.createEl=!1,i.reportTouchActivity=!1,!i.language)if("function"==typeof t.closest){var h=t.closest("[lang]");h&&(i.language=h.getAttribute("lang"))}else for(var o=t;o&&1===o.nodeType;){if(cs(o).hasOwnProperty("lang")){i.language=o.getAttribute("lang");break}o=o.parentNode}if(!(r=s.call(this,null,i,n)||this).h||!r.h.techOrder||!r.h.techOrder.length)throw new g("No techOrder specified. Did you overwrite videojs.options instead of just changing the properties you want to override?");if(r.tag=t,r.tagAttributes=t&&cs(t),r.language(r.h.language),i.languages){var a={};w.getOwnPropertyNames(i.languages).forEach((function(t){a[t.toLowerCase()]=i.languages[t]})),r.vi=a}else r.vi=e.prototype.h.languages;r.pi={},r.mi=i.poster||"",r.gi=!!i.controls,t.controls=!1,r.yi=!1,r.v=r.createEl();var u=ae(r.h);if(i.plugins){var c=i.plugins;w.getOwnPropertyNames(c).forEach((function(t){"function"==typeof this[t]?this[t](c[t]):Ui.error("Unable to find plugin:",t)}),ce(r))}r.h.playerOptions=u,r.initChildren(),r.isAudio("audio"===t.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"),Ms||r.addClass("vjs-workinghover"),e.players[r.o]=ce(r);var l="5.20.6-opentelly.14".split(".")[0];return r.addClass("vjs-v"+l),r.userActive(!0),r.reportUserActivity(),r.ki(),r.on("fullscreenchange",r.wi),r.on("stageclick",r._i),r}de(e,s);var n=e.prototype;return n.dispose=function(){this.trigger("dispose"),this.off("dispose"),this.xi&&this.xi.parentNode&&this.xi.parentNode.removeChild(this.xi),e.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(),s.prototype.dispose.call(this)},n.createEl=function(){var i,e=this.tag,n=this.Ci=e.parentNode&&e.parentNode.hasAttribute&&e.parentNode.hasAttribute("data-vjs-player");i=this.v=n?e.parentNode:s.prototype.createEl.call(this,"div"),e.setAttribute("tabindex","-1"),e.removeAttribute("width"),e.removeAttribute("height");var r=cs(e);if(w.getOwnPropertyNames(r).forEach((function(t){"class"===t?i.className+=" "+r[t]:i.setAttribute(t,r[t])})),e.playerId=e.id,e.id+="Si",e.className="vjs-tech",e.player=i.player=this,this.addClass("vjs-paused"),!0!==t.VIDEOJS_NO_DYNAMIC_STYLE){this.xi=ne("vjs-styles-dimensions");var h=ks(".vjs-styles-defaults"),o=ks("head");o.insertBefore(this.xi,h?h.nextSibling:o.firstChild)}this.width(this.h.width),this.height(this.h.height),this.fluid(this.h.fluid),this.aspectRatio(this.h.aspectRatio);for(var a=e.getElementsByTagName("a"),u=0;u<a.length;u++){var c=a.item(u);hs(c,"vjs-hidden"),c.setAttribute("hidden","hidden")}return e.Kt=e.networkState,e.parentNode&&!n&&e.parentNode.insertBefore(i,e),Zi(e,i),this.m.unshift(e),this.v=i,i},n.width=function(t){return this.dimension("width",t)},n.height=function(t){return this.dimension("height",t)},n.dimension=function(t,i){var s="width"===t?"ji":"Ti";if(void 0===i)return this[s]||0;if(""===i)this[s]=void 0;else{var e=C(i);if(S(e))return Ui.error('Improper value "'+i+'" supplied for for '+t),this;this[s]=e}return this.Mi(),this},n.fluid=function(t){if(void 0===t)return!!this.Ai;this.Ai=!!t,t?this.addClass("vjs-fluid"):this.removeClass("vjs-fluid"),this.Mi()},n.aspectRatio=function(t){if(void 0===t)return this.Pi;if(!/^\d+\:\d+$/.test(t))throw new g("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.Pi=t,this.fluid(!0),this.Mi()},n.Mi=function(){if(!0!==t.VIDEOJS_NO_DYNAMIC_STYLE){var i,s,e,n=(void 0!==this.Pi&&"auto"!==this.Pi?this.Pi:this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9").split(":"),r=n[1]/n[0];i=void 0!==this.ji?this.ji:void 0!==this.Ti?this.Ti/r:this.videoWidth()||300,s=void 0!==this.Ti?this.Ti:i*r,e=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(e),re(this.xi,"\n ."+e+" {\n width: "+i+"px;\n height: "+s+"px;\n }\n\n ."+e+".vjs-fluid {\n padding-top: "+100*r+"%;\n }\n ")}else{var h="number"==typeof this.ji?this.ji:this.h.width,o="number"==typeof this.Ti?this.Ti:this.h.height,a=this.H&&this.H.el();a&&(h>=0&&(a.width=h),o>=0&&(a.height=o))}},n._t=function(t,s){var e=this;this.H&&this.Ei(),"Html5"!==t&&this.tag&&(Wr.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.Ni=t,this.j=!1;var n=$i({source:s,nativeControlsForTouch:this.h.nativeControlsForTouch,playerId:this.id(),techId:this.id()+"_"+t+"Bi",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.Ci||!1,"vtt.js":this.h["vtt.js"]},this.h[t.toLowerCase()]);this.tag&&(n.tag=this.tag),s&&(this.Ii=s.type,s.src===this.pi.src&&this.pi.currentTime>0&&(n.startTime=this.pi.currentTime),this.pi.sources=null,this.pi.source=s,this.pi.src=s.src);var r=Wr.getTech(t);r||(r=i.getComponent(t)),this.H=new r(n),this.H.ready(he(this,this.Fi),!0),Me(this.Di||[],this.H),go.forEach((function(t){e.on(e.H,t,e["handleTech"+oe(t)+"_"])})),this.on(this.H,"loadstart",this.$i),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.Ui),this.on(this.H,"ended",this.zi),this.on(this.H,"seeking",this.Li),this.on(this.H,"seeked",this.Hi),this.on(this.H,"play",this.qi),this.on(this.H,"firstplay",this.Wi),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.Mi),this.on(this.H,"resize",this.Mi),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||Zi(this.H.el(),this.contentEl()),this.tag&&(this.tag.player=null,this.tag=null)},n.Ei=function(){this.rt=this.videoTracks(),this.nt=this.textTracks(),this.ht=this.audioTracks(),this.Di=Te(this.H),this.j=!1,this.H.dispose(),this.H=!1},n.tech=function(i){if(i&&i.IWillNotUseThisInPlugins)return this.H;var s="\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 t.alert(s),new g(s)},n.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)},n.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)},n.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){Ui("deleting tag.poster throws in some browsers",t)}this.play()}},n.$i=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"))},n.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},n.qi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},n.Ri=function(){var t=this;this.addClass("vjs-waiting"),this.trigger("waiting"),this.one("timeupdate",(function(){return t.removeClass("vjs-waiting")}))},n.Oi=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},n.Vi=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},n.Ui=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},n.Li=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},n.Hi=function(){this.removeClass("vjs-seeking"),this.trigger("seeked")},n.Wi=function(){this.h.starttime&&(Ui.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")},n.Gi=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},n.zi=function(){this.addClass("vjs-ended"),this.h.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},n.Xi=function(){this.duration(this.Zi("duration"))},n.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()))},n.os=function(){this.userActive(!this.userActive())},n.ns=function(){this.userWasActive=this.userActive()},n.rs=function(){this.userWasActive&&this.reportUserActivity()},n.hs=function(t){t.cancelable&&t.preventDefault()},n.wi=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},n._i=function(){this.reportUserActivity()},n.Ji=function(t,i){i&&(this.toggleClass("vjs-ios-native-fs",!(!i.nativeIOSFullscreen||!i.isFullscreen)),this.isFullscreen(i.isFullscreen)),this.trigger("fullscreenchange")},n.Qi=function(){var t=this.H.error();this.error(t)},n.Ki=function(){var t=null;arguments.length>1&&(t=arguments[1]),this.trigger("textdata",t)},n.getCache=function(){return this.pi},n.us=function(t,i){if(this.H&&!this.H.j)this.H.ready((function(){this[t](i)}),!0);else try{this.H&&this.H[t](i)}catch(t){throw Ui(t),t}},n.Zi=function(t){if(this.H&&this.H.j)try{return this.H[t]()}catch(i){throw void 0===this.H[t]?Ui("Video.js: "+t+" method not defined for "+this.Ni+" playback technology.",i):"TypeError"===i.name?(Ui("Video.js: "+t+" unavailable on "+this.Ni+" playback technology element.",i),this.H.j=!1):Ui(i),i}},n.play=function(){return this.src()||this.currentSrc()?this.us("play"):this.H.one("loadstart",(function(){this.play()})),this},n.pause=function(){return this.us("pause"),this},n.paused=function(){return!1!==this.Zi("paused")},n.scrubbing=function(t){return void 0!==t?(this.yi=!!t,t?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing"),this):this.yi},n.currentTime=function(t){return void 0!==t?(this.us("setCurrentTime",t),this):(this.pi.currentTime=this.Zi("currentTime")||0,this.pi.currentTime)},n.duration=function(t){return void 0===t?void 0!==this.pi.duration?this.pi.duration:NaN:((t=C(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)},n.remainingTime=function(){return this.duration()-this.currentTime()},n.buffered=function(){var t=this.Zi("buffered");return t&&t.length||(t=pe(0,0)),t},n.bufferedPercent=function(){return me(this.buffered(),this.duration())},n.bufferedEnd=function(){var t=this.buffered(),i=this.duration(),s=t.end(t.length-1);return s>i&&(s=i),s},n.volume=function(t){var i;return void 0!==t?(i=_.max(0,_.min(1,C(t))),this.pi.volume=i,this.us("setVolume",i),this):(i=C(this.Zi("volume")),S(i)?1:i)},n.muted=function(t){return void 0!==t?(this.us("setMuted",t),this):this.Zi("muted")||!1},n.supportsFullScreen=function(){return this.Zi("supportsFullScreen")||!1},n.isFullscreen=function(t){return void 0!==t?(this.cs=!!t,this):!!this.cs},n.requestFullscreen=function(t){var i,s=we;return this.isFullscreen(!0),s.requestFullscreen?(Qs(Ai,s.fullscreenchange,he(this,(function t(i){this.isFullscreen(Ai[s.fullscreenElement]),!1===this.isFullscreen()&&Ys(Ai,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},n.exitFullscreen=function(){var t=we;return this.isFullscreen(!1),t.requestFullscreen?Ai[t.exitFullscreen]():this.H.supportsFullScreen()?this.us("exitFullScreen"):(this.exitFullWindow(),this.trigger("fullscreenchange")),this},n.enterFullWindow=function(){this.isFullWindow=!0,this.docOrigOverflow=Ai.documentElement.style.overflow,Qs(Ai,"keydown",he(this,this.fullWindowOnEscKey)),Ai.documentElement.style.overflow="hidden",hs(Ai.body,"vjs-full-window"),this.trigger("enterFullWindow")},n.fullWindowOnEscKey=function(t){27===t.keyCode&&(!0===this.isFullscreen()?this.exitFullscreen():this.exitFullWindow())},n.exitFullWindow=function(){this.isFullWindow=!1,Ys(Ai,"keydown",this.fullWindowOnEscKey),Ai.documentElement.style.overflow=this.docOrigOverflow,os(Ai.body,"vjs-full-window"),this.trigger("exitFullWindow")},n.canPlayType=function(t){for(var s,e=0,n=this.h.techOrder;e<n.length;e++){var r=oe(n[e]),h=Wr.getTech(r);if(h||(h=i.getComponent(r)),h){if(h.isSupported()&&(s=h.canPlayType(t)))return s}else Ui.error('The "'+r+'" tech is undefined. Skipped browser support check for that tech.')}return""},n.selectSource=function(t){var s,e=this,n=this.h.techOrder.map(oe).map((function(t){return[t,Wr.getTech(t)||i.getComponent(t)]})).filter((function(t){var i=t[0],s=t[1];return s?s.isSupported():(Ui.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 s=t[0];if(t[1].canPlaySource(i,e.h[s.toLowerCase()]))return{source:i,tech:s}};return(this.h.sourceOrder?r(t,n,(s=h,function(t,i){return s(i,t)})):r(n,t,h))||!1},n.src=function(t){if(void 0===t)return this.Zi("src");var s=Wr.getTech(this.Ni);return s||(s=i.getComponent(this.Ni)),Array.isArray(t)?this.ls(t):"string"==typeof t?this.src({src:t}):t instanceof w&&(t.type&&!s.canPlaySource(t,this.h[this.Ni.toLowerCase()])?this.ls([t]):(this.pi.sources=null,this.pi.source=t,this.pi.src=t.src,this.Ii=t.type||"",this.ready((function(){s.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},n.ls=function(t){var i=this.selectSource(t);i?(i.tech===this.Ni?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())},n.load=function(){return this.us("load"),this},n.reset=function(){return this._t(oe(this.h.techOrder[0]),null),this.us("reset"),this},n.currentSources=function(){var t=this.currentSource(),i=[];return 0!==w.keys(t).length&&i.push(t),this.pi.sources||i},n.currentSource=function(){var t={},i=this.currentSrc();return i&&(t.src=i),this.pi.source||t},n.currentSrc=function(){return this.Zi("currentSrc")||this.pi.src||""},n.currentType=function(){return this.Ii||""},n.preload=function(t){return void 0!==t?(this.us("setPreload",t),this.h.preload=t,this):this.Zi("preload")},n.autoplay=function(t){return void 0!==t?(this.us("setAutoplay",t),this.h.autoplay=t,this):this.Zi("autoplay",t)},n.playsinline=function(t){return void 0!==t?(this.us("setPlaysinline",t),this.h.playsinline=t,this):this.Zi("playsinline")},n.loop=function(t){return void 0!==t?(this.us("setLoop",t),this.h.loop=t,this):this.Zi("loop")},n.poster=function(t){return void 0===t?this.mi:(t||(t=""),this.mi=t,this.us("setPoster",t),this.trigger("posterchange"),this)},n.Yi=function(){!this.mi&&this.H&&this.H.poster&&(this.mi=this.H.poster()||"",this.trigger("posterchange"))},n.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},n.usingNativeControls=function(t){return void 0!==t?(t=!!t,this.ds!==t&&(this.ds=t,t?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols"))),this):!!this.ds},n.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 Ce(t),this.addClass("vjs-error"),Ui.error("(CODE:"+this.lt.code+" "+Ce.errorTypes[this.lt.code]+")",this.lt.message,this.lt),this.trigger("error"),this)},n.reportUserActivity=function(t){this.fs=!0},n.userActive=function(t){return void 0!==t?((t=!!t)!==this.vs&&(this.vs=t,t?(this.fs=!0,this.removeClass("vjs-user-inactive"),this.addClass("vjs-user-active"),this.trigger("useractive")):(this.fs=!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},n.ki=function(){var t,i,s,e,n=he(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.fs){this.fs=!1,this.userActive(!0),this.clearTimeout(e);var t=this.h.inactivityTimeout;t>0&&(e=this.setTimeout((function(){this.fs||this.userActive(!1)}),t))}}),250)},n.playbackRate=function(t){return void 0!==t?(this.us("setPlaybackRate",t),this):this.H&&this.H.featuresPlaybackRate?this.Zi("playbackRate"):1},n.isAudio=function(t){return void 0!==t?(this.ps=!!t,this):!!this.ps},n.videoTracks=function(){return this.H?this.H.videoTracks():(this.rt=this.rt||new zr,this.rt)},n.audioTracks=function(){return this.H?this.H.audioTracks():(this.ht=this.ht||new Hr,this.ht)},n.textTracks=function(){if(this.H)return this.H.textTracks()},n.remoteTextTracks=function(){if(this.H)return this.H.remoteTextTracks()},n.remoteTextTrackEls=function(){if(this.H)return this.H.remoteTextTrackEls()},n.addTextTrack=function(t,i,s){if(this.H)return this.H.addTextTrack(t,i,s)},n.addRemoteTextTrack=function(t,i){if(this.H)return this.H.addRemoteTextTrack(t,i)},n.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)},n.getVideoPlaybackQuality=function(){return this.Zi("getVideoPlaybackQuality")},n.videoWidth=function(){return this.H&&this.H.videoWidth&&this.H.videoWidth()||0},n.videoHeight=function(){return this.H&&this.H.videoHeight&&this.H.videoHeight()||0},n.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)},n.languages=function(){return ae(e.prototype.h.languages,this.vi)},n.toJSON=function(){var t=ae(this.h),i=t.tracks;t.tracks=[];for(var s=0;s<i.length;s++){var e=i[s];(e=ae(e)).player=void 0,t.tracks[s]=e}return t},n.createModal=function(t,i){var s=this;(i=i||{}).content=t||"";var e=new Pe(this,i);return this.addChild(e),e.on("dispose",(function(){s.removeChild(e)})),e.open()},e.getTagSettings=function(t){var i={sources:[],tracks:[]},s=cs(t),e=s["data-setup"];if(rs(t,"vjs-fluid")&&(s.fluid=!0),null!==e){var n=Se(e||"{}"),r=n[0],h=n[1];r&&Ui.error(r),$i(s,h)}if($i(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(cs(c)):"track"===l&&i.tracks.push(cs(c))}return i},n.bi=function(){var t=Ai.createElement("i");return!("flexBasis"in t.style||"webkitFlexBasis"in t.style||"mozFlexBasis"in t.style||"msFlexBasis"in t.style||"msFlexOrder"in t.style)},e}(i);yo.players={};var bo=t.navigator;yo.prototype.h={techOrder:["html5","flash"],html5:{},flash:{},defaultVolume:0,inactivityTimeout:2e3,playbackRates:[],children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","controlBar","errorDisplay","textTrackSettings"],language:bo&&(bo.languages&&bo.languages[0]||bo.userLanguage||bo.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",fullscreenOptions:{navigationUI:"hide"}},["ended","seeking","seekable","networkState","readyState"].forEach((function(t){yo.prototype[t]=function(){return this.Zi(t)}})),go.forEach((function(t){yo.prototype["handleTech"+oe(t)+"_"]=function(){return this.trigger(t)}})),i.registerComponent("Player",yo);var ko,wo,_o=function(t){function i(s){var e;void 0===s&&(s={});var n=ae(s,{kind:Be[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(Rs)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return w.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.W=!0,r||ce(e)}return de(i,t),i}(De),xo=function(t){function i(s){var e;void 0===s&&(s={});var n=ae(s,{kind:Ne[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(Rs)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return w.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 de(i,t),i}(De);function Co(t,s,e){var n;if("string"==typeof t){if(0===t.indexOf("#")&&(t=t.slice(1)),Co.getPlayers()[t])return s&&Ui.warn('Player "'+t+'" is already initialised. Options will not be applied.'),e&&Co.getPlayers()[t].ready(e),Co.getPlayers()[t];n=function(t){return 0===t.indexOf("#")&&(t=t.slice(1)),Ai.getElementById(t)}(t)}else n=t;if(!n||!n.nodeName)throw new b("The element or ID supplied is not valid. (videojs)");if(n.player||yo.players[n.playerId])return n.player||yo.players[n.playerId];s=s||{},Co.hooks("beforesetup").forEach((function(t){var i=t(n,ae(s));Ri(i)&&!Array.isArray(i)?s=ae(s,i):Ui.error("please return an object in beforesetup hooks")}));var r=new(i.getComponent("Player"))(n,s,e);return Co.hooks("setup").forEach((function(t){return t(r)})),r}"undefined"==typeof HTMLVideoElement&&Xi()&&(Ai.createElement("video"),Ai.createElement("audio"),Ai.createElement("track")),Co.ys={},Co.hooks=function(t,i){return Co.ys[t]=Co.ys[t]||[],i&&(Co.ys[t]=Co.ys[t].concat(i)),Co.ys[t]},Co.hook=function(t,i){Co.hooks(t,i)},Co.removeHook=function(t,i){var s=Co.hooks(t).indexOf(i);return!(s<=-1)&&(Co.ys[t]=Co.ys[t].slice(),Co.ys[t].splice(s,1),!0)},!0!==t.VIDEOJS_NO_DYNAMIC_STYLE&&Xi()&&((ko=ks(".vjs-styles-defaults"))||(ko=ne("vjs-styles-defaults"),(wo=ks("head"))&&wo.insertBefore(ko,wo.firstChild),re(ko,"\n .video-js {\n width: 300px;\n height: 150px;\n }\n\n .vjs-fluid {\n padding-top: 56.25%\n }\n "))),ee(1,Co),Co.VERSION="5.20.6-opentelly.14",Co.options=yo.prototype.h,Co.getPlayers=function(){return yo.players},Co.players=yo.players,Co.getComponent=i.getComponent,Co.registerComponent=function(t,s){Wr.isTech(s)&&Ui.warn("The "+t+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),i.registerComponent.call(i,t,s)},Co.getTech=Wr.getTech,Co.registerTech=Wr.registerTech,Co.browser=Hs,Co.TOUCH_ENABLED=zs,Co.extend=function(t,i){void 0===i&&(i={});var s=function(){t.apply(this,arguments)},e={};for(var n in Ri(i)?("function"==typeof i.init&&(Ui.warn("Constructor logic via init() is deprecated; please use constructor() instead."),i.constructor=i.init),i.constructor!==w.prototype.constructor&&(s=i.constructor),e=i):"function"==typeof i&&(s=i),function(t,i){if("function"!=typeof i&&null!==i)throw new b("Super expression must either be null or a function, not "+typeof i);t.prototype=w.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},Co.mergeOptions=ae,Co.bind=he,Co.plugin=function(t,i){yo.prototype[t]=i},Co.addLanguage=function(t,i){var s;return t=(""+t).toLowerCase(),Co.options.languages=ae(Co.options.languages,((s={})[t]=i,s)),Co.options.languages[t]},Co.log=Ui,Co.createTimeRange=Co.createTimeRanges=pe,Co.formatTime=hh,Co.parseUrl=$e,Co.isCrossOrigin=Re,Co.EventTarget=ue,Co.on=Qs,Co.one=Zs,Co.off=Ys,Co.trigger=Ks,Co.xhr=Pr,Co.TextTrack=Fr,Co.AudioTrack=_o,Co.VideoTrack=xo,Co.isEl=Ji,Co.isTextNode=ps,Co.createEl=Yi,Co.hasClass=rs,Co.addClass=hs,Co.removeClass=os,Co.toggleClass=as,Co.setAttributes=us,Co.getAttributes=cs,Co.emptyEl=ms,Co.appendContent=gs,Co.insertContent=ys,Co.computedStyle=fh;var So=10;function jo(t){const i=t.duration;if(S(i)){var s;const i=null==(s=t.source)?void 0:s.streamType;return"live"===i||"dvr"===i}return i===1/0}function To(t){return t.scrubbing()?t.getCache().currentTime:t.currentTime()}function Mo(t){const i=Eo(t);return jo(t)?i.end(i.length-1):i.start(0)}function Ao(t){return Eo(t).start(0)}function Po(t){const i=Eo(t);return i.end(i.length-1)-i.start(0)}function Eo(t){const i=t.seekable;if(i&&i.length)return i;let s=t.duration;return s=isFinite(s)?s:0,new Nt([0,s]).ks()}function No(t,i){void 0===i&&(i=t);let s=t<0?"-":"";t=_.abs(t);let e=_.floor(t%60),n=_.floor(t/60%60),r=_.floor(t/3600);const h=_.floor(i/60%60),o=_.floor(i/3600);return(S(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 Bo(t){return class extends t{get ws(){var t;return null!=(t=this._s)?t:this._s=Io(this.player())}dispose(){this._s=void 0,super.dispose()}constructor(...t){super(...t),this._s=void 0}}}function Io(t){return t.tech({IWillNotUseThisInPlugins:!0}).theoplayer()}function Fo(t){const i=Io(t),s=()=>{const s=To(t);t.toggleClass("theo-at-live",function(t,i){if(jo(t)){let s=t.seekable;return 0===s.length||s.end(s.length-1)-i<So}return!1}(i,s)),t.toggleClass("vjs-live",jo(i)),t.toggleClass("theo-dvr",function(t){var i;return"dvr"===vt(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 Do="theo-ad-playing",$o="theo-dai-ad-playing";function Ro(t,i,s){t.toggleClass(Do,i),t.toggleClass($o,i&&s)}function Oo(){this.userActive(!1)}var Vo=class{constructor(t,i){this.type=t.type,this.target=i,this.playerEvent=t}},Uo=["loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange","resize"],zo=Co.getTech("Tech"),Lo=Co.getTech("Html5"),Ho=class extends zo{xs(){var t;for(const t of Uo)this.ws.addEventListener(t,this.Cs);this.ws.addEventListener("error",this.Ss),this.ws.addEventListener("contentprotectionerror",this.Ss),this.ws.addEventListener("sourcechange",this.js),this.ws.addEventListener("loadstart",this.Ts),null==(t=this.ws.presentation)||t.addEventListener("presentationmodechange",this.Ms),this.ws.textTracks.addEventListener("addtrack",this.As),this.ws.textTracks.addEventListener("removetrack",this.Ps),this.ws.textTracks.addEventListener("change",this.Es),this.ws.audioTracks.addEventListener("addtrack",this.Ns),this.ws.audioTracks.addEventListener("removetrack",this.Bs),this.ws.audioTracks.addEventListener("change",this.Is)}Fs(){var t;for(const t of Uo)this.ws.removeEventListener(t,this.Cs);this.ws.removeEventListener("error",this.Ss),this.ws.removeEventListener("contentprotectionerror",this.Ss),this.ws.removeEventListener("sourcechange",this.js),this.ws.removeEventListener("loadstart",this.Ts),null==(t=this.ws.presentation)||t.removeEventListener("presentationmodechange",this.Ms),this.ws.textTracks.removeEventListener("addtrack",this.As),this.ws.textTracks.removeEventListener("removetrack",this.Ps),this.ws.textTracks.removeEventListener("change",this.Es),this.ws.audioTracks.removeEventListener("addtrack",this.Ns),this.ws.audioTracks.removeEventListener("removetrack",this.Bs),this.ws.audioTracks.removeEventListener("change",this.Is)}Ds(t){this.trigger(new Vo(t,this))}createEl(){let t=this.h,i=t.player;if(!i)throw new g(this.localize('Missing required tech option "player"'));let s=i.element;return Co.setAttributes(s,{id:t.techId}),s}theoplayer(){return this.ws}addTextTrack(t,i,s){return super.addTextTrack(t,i,s)}buffered(){return this.ws.buffered}played(){return this.ws.played}reset(){this.ws.stop()}play(){this.ws.play()}pause(){this.ws.pause()}paused(){return this.ws.paused}currentTime(){return this.ws.currentTime}setCurrentTime(t){this.ws.currentTime=t}duration(){return this.ws.duration}volume(){return this.ws.volume}setVolume(t){this.ws.volume=t}muted(){return this.ws.muted}setMuted(t){this.ws.muted=t}src(t){if(void 0!==t)this.setSrc(t);else{if(this.ws.src)return this.ws.src;if(this.ws.source){if(!Xt(this.ws.source.ads))return this.ws.source.ads[0].sources;if(jt(this.ws.source))return"This source is managed by the Verizon Media integration extension.";if(Ct(this.ws.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.ws.src}load(){this.setPreload("auto")}preload(){return this.ws.preload}setPreload(t){this.ws.preload=t}autoplay(){return this.ws.autoplay}setAutoplay(t){this.ws.autoplay=!!t}seeking(){return this.ws.seeking}seekable(){return this.ws.seekable}ended(){return this.ws.ended}playbackRate(){return this.ws.playbackRate}setPlaybackRate(t){this.ws.playbackRate=t}readyState(){return this.ws.readyState}networkState(){return 0}controls(){return!1}videoHeight(){return this.ws.videoHeight}videoWidth(){return this.ws.videoWidth}supportsFullScreen(){return this.ws.presentation.supportsMode(Vt.FULLSCREEN)}enterFullScreen(){this.ws.presentation.requestMode(Vt.FULLSCREEN)}exitFullScreen(){this.ws.presentation.requestMode(Vt.INLINE)}$s(){let t=this.ws.ads;if(t&&t.playing)return!0;let i=this.ws.vr;return!(!i||i.state===yt.Rs)}initTextTrackListeners(){return this.on("touchend",(t=>{this.$s()&&(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.Fs(),this.ws=null,super.dispose()}static isSupported(){return!0}static canPlayType(){return"maybe"}static canPlaySource(t){return"maybe"}get featuresVolumeControl(){return li}constructor(t={},i){super(t,i),this.Cs=t=>this.Ds(t),this.Os=!1,this.js=()=>{void 0===this.ws.errorObject&&(this.Ds(new T(this.ws.currentTime,this.ws.readyState)),this.Ds(new di),this.Ds(new Mt(this.ws.duration)))},this.Ts=()=>{this.Ds(new bt(this.ws.currentTime))},this.As=t=>{this.textTracks().tt(t.track)},this.Ns=t=>{this.audioTracks().tt(t.track)},this.Ps=t=>{this.textTracks().it(t.track)},this.Bs=t=>{this.audioTracks().it(t.track)},this.Es=()=>{let t=this.textTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Is=()=>{let t=this.audioTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Ms=()=>{if(!this.supportsFullScreen())return;let t=this.Os,i=this.ws.presentation.currentMode===Vt.FULLSCREEN;t!==i&&(this.Os=i,this.trigger("fullscreenchange",{isFullscreen:i,nativeIOSFullscreen:!0}))},this.Ss=()=>{const t=this.ws.errorObject,i=t&&et(t.code)||-1,s=t&&t.message||"An unknown error occurred.";this.error({code:i,message:this.localize(s)})},this.ws=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()}};Ho.prototype.featuresFullscreenResize=Lo.prototype.featuresFullscreenResize,Ho.prototype.featuresPlaybackRate=Lo.prototype.featuresPlaybackRate,Ho.prototype.featuresProgressEvents=!0,Ho.prototype.featuresTimeupdateEvents=!0,Ho.prototype.featuresNativeTextTracks=!0,Co.registerTech("THEOplayer",Ho);var qo=class{constructor(t){this.Vs=t=>{Yt(this.Us,"theo-mobile-button-hover"),t.stopImmediatePropagation()},this.zs=t=>{Zt(this.Us,"theo-mobile-button-hover")},this.Ls=t=>{this.Us.blur()},this.Us=t,t.addEventListener("touchstart",this.Vs),t.addEventListener("touchend",this.zs),t.addEventListener("focusin",this.Ls)}},Wo=Co.getComponent("Menu"),Go=class extends(Bo(Wo)){get Hs(){return this.player().el()}qs(){Yt(this.Hs,"theo-menu-opened")}Ws(){Zt(this.Hs,"theo-menu-opened")}constructor(t,i){super(t,i)}},Xo=Co.getComponent("MenuItem"),Jo=class extends(Bo(Xo)){get parentMenu(){return this.Gs}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.Xs||(this.parentMenu.Js(this),"tap"!==t.type&&"keydown"!==t.type||(this.Xs=!0,this.trigger("click"),this.Xs=!1))}dispose(){Tt.Ys.Qs&&(this.el().removeEventListener("touchstart",this.Vs),this.el().removeEventListener("touchend",this.zs)),super.dispose()}constructor(t,i,s){super(t,fi({selectable:!0},i)),this.Xs=!1,this.Vs=t=>{Yt(this.el(),"theo-mobile-menu-item-hover"),t.stopImmediatePropagation()},this.zs=t=>{Zt(this.el(),"theo-mobile-menu-item-hover")},this.Gs=s,Tt.Ys.Qs&&(this.el().addEventListener("touchstart",this.Vs),this.el().addEventListener("touchend",this.zs))}},Qo=Co.getComponent("ClickableComponent"),Yo=class extends Qo{get parentMenu(){return this.Gs}get Ks(){return this.Zs}set Ks(t){this.Zs=t,this.el().setAttribute("tabindex",this.Ks?"0":"-1"),this.te()}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.Xs&&this.Ks&&(this.Gs.ie(),"tap"===t.type&&(this.Xs=!0,this.trigger("click"),this.Xs=!1))}te(){this.Ks?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.Xs=!1,this.Zs=!1,this.Gs=s,this.on(t,"languagechange",this.te)}},Ko=class extends Go{get menuHeader(){return this.se}get menuItems(){return this.children()}addMenuItem(t){t=fi({playerOptions:this.h.playerOptions},t);let i=new Jo(this.player(),t,this);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}addSubMenuItem(t){t=fi({playerOptions:this.h.playerOptions},t);let i=this.ee(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"}qs(){super.qs(),s.removeEventListener("resize",this.ne),s.addEventListener("resize",this.ne),this.show()}re(){let t=this.he();if(!t)return;let i=t.getClientRects();Tt.Ys.Qs?this.oe(t,i):this.ae(t,i)}he(){var t;return null!=(t=this.contentEl().parentElement)?t:void 0}ae(t,i){}oe(t,i){}Ws(){s.removeEventListener("resize",this.ne),super.Ws(),this.hide(),Tt.Ys.Qs&&(this.el().removeAttribute("style"),this.contentEl().removeAttribute("style"))}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=this.contentEl();Yt(i,"theo-menu-content");let s=new Yo(this.player(),this.h,this);return i.parentNode.insertBefore(s.el(),i),this.se=s,t}Js(t){}show(){return this.re(),super.show()}dispose(){this.se&&this.se.dispose(),super.dispose()}constructor(t,i){super(t,i),this.ne=()=>this.re(),this.ue=this.player().el(),this.hide(),this.on("menuchange",this.re)}},Zo=class extends Ko{get ce(){return this.le}set ce(t){this.le&&this.le.de(this),this.le=t,t&&t.fe(this)}ve(t){this.ce.pe(t,"replace")}me(t){t.ce.pe(this,"restore")}ge(){Zt(this.ye,"vjs-hidden"),this.ye.style.opacity="1",super.show()}be(){Yt(this.ye,"vjs-hidden")}qs(){this.ce&&this.ce.qs(),super.qs()}Ws(){this.ce&&this.ce.Ws(),super.Ws(),Yt(this.ye,"vjs-hidden")}he(){if(this.ce&&this.ce.ke)return this.ce.ke.ye}ae(t,i){if(i.length>0){let t=i[0].height,s=i[0].width;this.le.we.style.height=t+"px",this.le.we.style.width=s+"px"}super.ae(t,i)}constructor(t,i){super(t,i)}},ta=class{get we(){return this.Us}get ke(){return this._e}fe(t){t.be(),this.Us.appendChild(t.ye)}de(t){this.Us.removeChild(t.ye)}pe(t,i){if(t==this._e)return;let s=this._e;if(this._e=t,this._e.ge(),this.ke.focus(),Tt.Ys.Qs)s.be();else{const t="translateX(100%)",e="translateX(-100%)",n=si("transform");s.ye.style.opacity="0",s.ye.style[n]="replace"===i?e:t,this._e.ye.style.opacity="1",this._e.ye.style[n]="",u((()=>{s.be(),s.ye.style[n]=""}),300)}}qs(){this.xe(),this._e.ge(),this.Ce()}Ws(){this.xe(),this._e.be(),this.Se.be(),this._e=this.Se,this.Ce()}Ce(){Qt((()=>{Zt(this.Us,"theo-no-transition"),Zt(this._e.ye,"theo-no-transition")}))}xe(){Yt(this.Us,"theo-no-transition"),Yt(this._e.ye,"theo-no-transition")}constructor(t){this.Se=this._e=t,this.Us=h.createElement("div"),this.Us.className="theo-tertiary-background theo-menu-animation-container",this.Us.appendChild(this.Se.ye),this.ue=this._e.player().el()}},ia=class extends Zo{get ye(){return this.el()}get parentMenu(){return this.je}ee(t,i){let s=new sa(t,i,this);return s.subMenu.ce=this.ce,s}ie(){this.Te()}Js(t){super.Js(t),this.Te()}Te(){this.parentMenu.me(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.je=s,this.menuHeader.Ks=!0}},sa=class extends Jo{get subMenu(){return this.Ae}handleClick(t){this.parentMenu.ve(this.subMenu)}constructor(t,i,s){super(t,fi({selectable:!1},i),s),this.Ae=new ia(t,i,s)}},ea=class extends Zo{get menuButton(){return this.Pe}createEl(){let t=Co.createEl("div",{className:this.buildCSSClass()});return this.Ee=super.createEl(),this.Ee.className=super.buildCSSClass(),Yt(this.Ee,"theo-menu-content-animatable"),t.appendChild(this.Ee),this.ce=new ta(this),t.appendChild(this.ce.we),t}buildCSSClass(){return"theo-menu-animatable "+super.buildCSSClass()}ee(t,i){let s=new sa(t,i,this);return s.subMenu.ce=this.ce,s}ae(t,i){super.ae(t,i);let s=this.ue.getClientRects(),e=s.length>0?s[0]:void 0,n=C(getComputedStyle(this.el()).fontSize);E(this.el(),this.Pe.el(),e,n)}get ye(){return this.Ee}ie(){this.Pe.closeMenu()}dispose(){this.Ne||(this.Ne=!0,super.dispose())}constructor(t,i,s){super(t,i),this.Ne=!1,this.Pe=s}},na=class{set Be(t){this.Ie.innerHTML=this.Fe.localize(t),this.De(),this.$e(),ri(this.Fe.el())}get Be(){return this.Ie.textContent||""}Re(){this.Fe.off("mouseover",this.$e),this.Fe.off("mouseout",this.De),this.Fe.off("dispose",this.Oe),qt(this.Ie)}constructor(t,i){this.$e=()=>{Zt(this.Ie,"vjs-hidden");let t=this.Fe.player().contentEl().getClientRects(),i=t.length>0?t[0]:void 0,s=C(getComputedStyle(this.Ie).fontSize);E(this.Ie,this.Fe.el(),i,s)},this.De=()=>{Yt(this.Ie,"vjs-hidden")},this.Oe=()=>this.Re(),this.Fe=t,ri(t.el()),oi(t.el()),this.Ie=h.createElement("span"),this.Ie.innerHTML=this.Fe.localize(i),this.Ie.className="theo-button-tooltip vjs-hidden",this.Ie.setAttribute("aria-hidden","true"),this.Fe.el().appendChild(this.Ie),this.Fe.on("mouseover",this.$e),this.Fe.on("mouseout",this.De),this.Fe.on("dispose",this.Oe)}},ra=Co.getComponent("Button"),ha=class extends(Bo(ra)){get Ve(){const t=this.el().parentElement;return!!t&&null!==t.querySelector(".theo-mobile-menu-background")}get menu(){return this.Ue}isMenuOpen(){return this.ze}openMenu(){this.Le&&!this.ze&&(this.Ue.qs(),this.el().setAttribute("aria-expanded","true"),this.ze=!0,this.Ue.focus())}closeMenu(){this.Le&&this.ze&&(this.Ue.Ws(),this.el().setAttribute("aria-expanded","false"),this.ze=!1)}set minimumMenuItems(t){this.He=t,this.qe()}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.Le=!0,super.enable()}disable(){return this.closeMenu(),this.Le=!1,super.disable()}te(){this.Ie.Be=this.controlText()}dispose(){this.player().removeChild(this.Ue),this.Ue.dispose(),this.Ie.Re(),this.ws.removeEventListener("seeking",this.We),super.dispose()}constructor(t,i){super(t,i),this.ze=!1,this.He=1,this.Le=!0,this.Ge=t=>{let i=this.el().contains(t.target),s=this.Ue.el().contains(t.target),e=!1;var n;Tt.Ys.Qs&&this.Ve&&(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.Xe=t=>{27===t.which&&(this.closeMenu(),this.focus())},this.We=()=>{this.ze&&this.closeMenu()},this.qe=()=>{this.Ue.menuItems.length>=this.He?this.show():(this.closeMenu(),this.hide())},this.Ue=new ea(t,i,this),this.player().getChild("controlBarMenuContainer").addChild(this.Ue),this.Ie=new na(this,this.controlText()),this.el().setAttribute("aria-haspopup","true"),Tt.Ys.Je?(this.on(h,"touchend",this.Ge),new qo(this.el())):(this.on(h,"click",this.Ge),this.on(h,"keydown",this.Xe),ai&&this.on(h,ai.Qe,this.closeMenu)),this.ws.addEventListener("seeking",this.We),this.on(this.Ue,"menuchange",this.qe),this.on(t,"languagechange",this.te),this.qe()}},oa=Co.getComponent("Component"),aa=class extends(Co.getComponent("ControlBar")){addMenuButton(t){t=fi({playerOptions:this.h.playerOptions},t);let i=new ha(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)}};Co.registerComponent("THEOControlBarShadow",class extends oa{createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-tertiary-color theo-control-bar-shadow"}});var ua=Co.getComponent("VolumeBar"),ca=class extends ua{handleFocus(t){super.handleFocus(t),this.Ye.addClass("focus-within")}handleBlur(t){super.handleBlur(t),this.Ye.removeClass("focus-within")}constructor(t,i){super(t,i),this.Ye=i.Ke}},la=Co.getComponent("VolumeControl"),da=class extends la{constructor(t,i){super(t,i),this.Ze=new ca(t,{Ke:this}),this.addChild(this.Ze)}};da.prototype.h=fi({},la.prototype.h,{children:[]}),Co.registerComponent("VolumeControl",da);var fa=class extends(Bo(aa)){tn(){this.sn(this.nn())}rn(){0===this.hn&&(this.hn=u(this.an,100))}un(t){"opacity"===t.propertyName&&(0!==this.hn&&(c(this.hn),this.hn=0),this.sn(!0))}cn(t){"opacity"===t.propertyName&&(this.nn()||this.sn(!1))}nn(){return"0"!==s.getComputedStyle(this.el()).opacity}sn(t){this.ln!==t&&(this.ln=t,t?this.dn():this.ws.textTrackStyle.marginBottom=void 0)}dn(){const t=this.el().getBoundingClientRect().height;this.ws.textTrackStyle.marginBottom!==t&&(this.ws.textTrackStyle.marginBottom=t)}dispose(){c(this.hn),this.hn=0,this.vn.fn(Kt.pn,this.mn),this.vn.gn(),super.dispose()}constructor(t,i){super(t,i),this.ln=!1,this.hn=0,this.an=()=>{0!==this.hn&&(this.hn=0,this.sn(this.nn()))},this.mn=()=>{this.ln&&this.dn()},this.on(t,"ready",this.tn),this.on(t,"pause",this.tn),this.on(t,"useractive",this.tn),this.on(t,"firstplay",this.rn),this.on(t,"play",this.rn),this.on(t,"userinactive",this.rn),this.on("transitionstart",this.un),this.on("transitionend",this.cn),this.vn=new ni(this.el()),this.vn.yn(Kt.pn,this.mn),this.vn.bn(!0)}};fa.prototype.h=fi({},aa.prototype.h,{children:["progressControl","playToggle","muteToggle","volumeControl","currentTimeDisplay","timeDivider","durationDisplay","liveDisplay","remainingTimeDisplay","customControlSpacer","activeQualityLabel","vrButton","descriptionsButton","subtitlesButton","chromecastButton","airplayButton","multiViewButton","audioTrackButton","SettingsButton","fullscreenToggle"]}),Co.registerComponent("ControlBar",fa);var va=class extends aa{buildCSSClass(){return"theo-top-controlbar "+super.buildCSSClass()}constructor(t,i){super(t,i),t.topControlBar=this}};va.prototype.h=fi({},aa.prototype.h,{children:[]}),Co.registerComponent("TopControlBar",va);var pa=Co.getComponent("CurrentTimeDisplay"),ma=class extends(Bo(pa)){updateContent(){const t=To(this.player()),i=this.ws,s=Ao(i),e=this.localize("Current Time"),n=No(_.max(0,t-s),Po(i));n!==this.Mt&&(this.Mt=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)}};Co.registerComponent("CurrentTimeDisplay",ma);var ga=Co.getComponent("DurationDisplay"),ya=class extends(Bo(ga)){updateContent(){const t=this.ws,i=S(t.duration)?NaN:Po(t),s=t.clip.endTime-t.clip.startTime,e=_.min(i,s)||0;if(this.ct!==e){this.ct=e;const t=this.localize("Duration Time"),i=No(e);this.S.innerHTML='<span class="vjs-control-text">'+t+"</span> "+i}}dispose(){var t;null==(t=this.ws)||t.clip.removeEventListener("change",this.kn),super.dispose()}constructor(t,i){var s;super(t,i),this.kn=()=>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.ws)||s.clip.addEventListener("change",this.kn)}};Co.registerComponent("DurationDisplay",ya);var ba=Co.getComponent("Button"),ka=class extends(Bo(ba)){buildCSSClass(){return"theo-live-control "+super.buildCSSClass()}createEl(){let t=super.createEl("button",{},{"aria-live":"off"});return this.wn=Co.createEl("span",{className:"theo-live-control-indicator"}),Gt(t,this.wn),t}createControlTextEl(t){let i=super.createControlTextEl(t);return Co.removeClass(i,"vjs-control-text"),Co.addClass(i,"theo-live-control-text"),i}handleClick(){var t;const i=this.ws;if(void 0!==(null==(t=i.hesp)?void 0:t.manifest))i.hesp.goLive();else{const t=this.player();t.currentTime(Mo(i)),t.play()}}_n(){jo(this.ws)?this.show():this.hide()}constructor(t,i){super(t,i),this.controlText("Live"),this._n(),this.on(t,"emptied",this._n),this.on(t,"durationchange",this._n),Tt.Ys.Je&&new qo(this.el())}};Co.registerComponent("LiveDisplay",ka);var wa=Co.getComponent("LoadingSpinner");Co.registerComponent("LoadingSpinner",class extends wa{buildCSSClass(){return"theo-secondary-color vjs-loading-spinner "+super.buildCSSClass()}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=Co.createEl("div",{className:"theo-loading-spinner-rotator"}),s=Co.createEl("div",{className:"theo-loading-spinner-circle-left"}),e=Co.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 _a=Co.getComponent("LoadProgressBar"),xa=class extends(Bo(_a)){update(){let t=this.ws,i=Nt.xn(Eo(t)),s=i.Cn(0),e=Nt.xn(t.buffered).Sn(i),n=i.jn(0)-s,r=e.U&&e.jn(e.U-1)||0;r=_.max(0,r-s);let o=this.el(),a=this.Tn;o.style.width=Ca(r,n);for(let t=0;t<e.U;t++){let i=e.Cn(t),n=e.jn(t),u=a[t];u||(u=h.createElement("div"),a.push(u),o.appendChild(u)),u.style.left=Ca(i-s,r),u.style.width=Ca(n-i,r)}for(let t=a.length;t>e.U;t--)o.removeChild(a[t-1]);a.length=e.U}constructor(t,i){super(t,i),this.Tn=[],this.on(t,"emptied",this.update)}};function Ca(t,i){let s=t/i||0;return 100*(s>=1?1:s)+"%"}Co.registerComponent("LoadProgressBar",xa);var Sa=Co.getComponent("MouseTimeDisplay"),ja=class extends(Bo(Sa)){handleMouseMove(t){let i=t,s=this.ws,e=Ao(s)+this.calculateDistance(i)*Po(s),n=i.pageX-A(this.el().parentNode).left;this.update(e,n+"px")}handleTouchMove(t){let i=t,s=this.ws,e=Ao(s)+this.calculateDistance(i)*Po(s),n=i.touches[0].pageX-A(this.el().parentNode).left;this.update(e,n+"px")}createEl(){let t=super.createEl();return this.Mn=Co.createEl("span",{className:"theo-time-tooltip-text"}),t}update(t,i){this.An=t;let s=this.Pn(t);this.el().style.left=i,this.el().setAttribute("data-current-time",s),this.keepTooltipsInside&&(l(this.Mn,s),this.En())}En(){if(this.keepTooltipsInside&&this.tooltip.offsetParent){let t=this.player().contentEl(),i=t.getClientRects(),s=i.length>0?i[0]:void 0,e=C(getComputedStyle(t).fontSize);E(this.tooltip,this.el(),s,e)}}Pn(t){const i=this.ws,s=t-Mo(i);return No(jo(i)?_.min(s,0):s,Po(i))}dispose(){var t;this.ws.removeEventListener("dimensionchange",this.Nn),null==(t=this.ws.presentation)||t.removeEventListener("presentationmodechange",this.Nn),super.dispose()}constructor(t,i){var s;(super(t,i),this.An=NaN,this.Nn=()=>{let t=To(this.player());const i=this.ws;let s=(t-Ao(i))/Po(i)||0;s=Ut(s,0,1),this.update(t,100*s+"%")},this.keepTooltipsInside&&(Co.addClass(this.tooltip,"theo-secondary-color"),this.tooltip.appendChild(this.Mn)),this.on(t,"ready",(()=>{this.on(t.controlBar.progressControl,"mouseenter",this.handleMouseMove)})),At.Qs)&&(this.on(t,"firstplay",this.Nn),this.on(t,"play",this.Nn),this.on(t,"seeking",this.Nn),this.on(t,"seeked",this.Nn),this.on(t,"timeupdate",this.Nn),this.ws.addEventListener("dimensionchange",this.Nn),null==(s=this.ws.presentation)||s.addEventListener("presentationmodechange",this.Nn),this.on(t,"ready",(()=>{this.on(t.controlBar.progressControl,"touchstart",this.handleTouchMove),this.on(t.controlBar.progressControl,"touchmove",Ot((t=>this.handleTouchMove(t)),25)),this.Nn()})))}};Co.registerComponent("MouseTimeDisplay",ja);var Ta=Co.getComponent("PlayProgressBar"),Ma=class extends(Bo(Ta)){updateDataAttr(){let t=To(this.player());this.el().setAttribute("data-current-time",this.Pn(t))}Pn(t){let i=this.ws;return No(t-Mo(i),Po(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)}};Co.registerComponent("PlayProgressBar",Ma);var Aa=Co.getComponent("RemainingTimeDisplay"),Pa=class extends(Bo(Aa)){updateContent(){const t=this.ws,i=Po(t);if(i){const s=Eo(t).end(0),e=this.localize("Remaining Time"),n=No(_.max(0,s-this.player().currentTime()),i);n!==this.Mt&&(this.Mt=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)}};Co.registerComponent("RemainingTimeDisplay",Pa);var Ea=class{get ws(){return this._s||(this._s=this.Bn.tech({IWillNotUseThisInPlugins:!0}).theoplayer()),this._s}In(t){if(t.kind!==lt.Fn)return;if(0===this.ws.seekable.length)return;this.Dn=t;const i=t.cues.slice();this.Rn.$n(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 Na(s,this.ws,n);this.On.push(r),this.Vn.appendChild(r.we)}t.addEventListener("cuechange",this.Un),this.Un()}zn(){this.ws.addEventListener("loadedmetadata",this.Ln),this.ws.addEventListener("loadeddata",this.Ln),this.ws.addEventListener("sourcechange",this.Ln),this.ws.textTracks.addEventListener("addtrack",this.Hn),this.ws.textTracks.addEventListener("removetrack",this.qn),this.ws.textTracks.addEventListener("change",this.Ln)}Wn(){this.ws.removeEventListener("loadedmetadata",this.Ln),this.ws.removeEventListener("loadeddata",this.Ln),this.ws.removeEventListener("sourcechange",this.Ln),this.ws.textTracks.removeEventListener("addtrack",this.Hn),this.ws.textTracks.removeEventListener("removetrack",this.qn),this.ws.textTracks.removeEventListener("change",this.Ln)}Gn(){if(!(this.ws.readyState<gt.Xn))for(let t of this.ws.textTracks)if(t.kind===lt.Fn&&t.mode===ut.Jn&&t.cues.length>0&&t.readyState!==rt.ERROR)return t}Qn(t){this.Rn.Yn(t)}Kn(){this.Rn.ge()}Zn(){this.Rn.be()}tr(){for(let t of this.On)t.Re();this.Rn.tr(),this.On=[],this.ir=void 0,this.Dn&&this.Dn.removeEventListener("cuechange",this.Un),this.Dn=void 0}Re(){this.Wn(),this.sr.removeEventListener("mousemove",this.er),this.sr.removeEventListener("mouseenter",this.nr),this.sr.removeEventListener("mouseleave",this.rr),this.tr(),this.Rn.Re(),this._s=void 0}constructor(t,i){this.Bn=i,this.On=[],this._s=void 0,this.Hn=t=>{let i=t.track;i.kind===lt.Fn&&(i.addEventListener("addcue",this.Ln),i.addEventListener("removecue",this.Ln),i.addEventListener("readystatechange",this.Ln)),this.Ln()},this.qn=t=>{let i=t.track;i.kind===lt.Fn&&(i.removeEventListener("addcue",this.Ln),i.removeEventListener("removecue",this.Ln),i.removeEventListener("readystatechange",this.Ln)),this.Ln()},this.er=t=>{let i=this.ws,s=function(t,i){let s,e,n=A(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=Ut((o-s+h)/h,0,1),c=Ut((e-a)/r,0,1);return{x:c,y:u}}(this.Vn,t),e=Ao(i)+s.x*Po(i);e===i.duration&&(e-=.1),this.Qn(e)},this.rr=()=>{this.Rn.be()},this.nr=()=>{this.Rn.ge()},this.Ln=()=>{let t=this.Gn();t!==this.Dn&&(this.tr(),t&&this.In(t))},this.Un=()=>{var t,i,s;const e=null==(i=this.Dn)||null==(t=i.activeCues)?void 0:t[0],n=M(this.On,(t=>t.hr===e));n!==this.ir&&(null==(s=this.ir)||s.ar(),this.ir=n,null==n||n.ur())},this.sr=t,this.Rn=new Ba,this.Bn.contentEl().appendChild(this.Rn.we),this.Vn=h.createElement("div"),Yt(this.Vn,"theoplayer-chapterbar"),this.sr.appendChild(this.Vn),this.sr.addEventListener("mousemove",this.er),this.sr.addEventListener("mouseenter",this.nr),this.sr.addEventListener("mouseleave",this.rr),this.zn()}},Na=class{get we(){return this.Us}ur(){Yt(this.Us,"theoplayer-chapter-indicator-active")}ar(){Zt(this.Us,"theoplayer-chapter-indicator-active")}cr(t,i){let s=t.seekable.start(0),e=t.seekable.end(t.seekable.length-1)-s,n=this.hr.startTime,r=this.hr.endTime-n,o=h.createElement("div");Yt(o,"theoplayer-chapter-indicator");let a=h.createElement("div");Yt(a,"theoplayer-chapter-indicator-highlight"),o.appendChild(a),i&&Yt(o,"theoplayer-chapter-indicator-discontinuous");let u=_.min(n/e*100,100),c=100-u,l=_.min(r/e*100,c);return o.style.width=l+"%",o.style.left=u+"%",o}Re(){qt(this.Us)}constructor(t,i,s){this.hr=t,this.Us=this.cr(i,s)}},Ba=class{be(){this.lr--,0===this.lr&&Zt(this.we,"theoplayer-chapter-hovering")}$n(t){this.dr=t||[],this.dr.length>0&&(this.we.style.display="")}pr(t){l(this.mr,t.content)}tr(){this.dr=[],l(this.mr,""),this.we.style.display="none"}ge(){this.lr++,this.lr>0&&Yt(this.we,"theoplayer-chapter-hovering")}Yn(t){for(let i of this.dr)if(Ia(i,t)){this.pr(i);break}}Re(){qt(this.we)}constructor(){this.dr=[],this.lr=0,this.we=h.createElement("div"),Yt(this.we,"theoplayer-chaptertitle"),this.we.style.display="none",this.mr=h.createElement("p"),this.we.appendChild(this.mr)}};function Ia(t,i){return new Nt([t.startTime,t.endTime]).gr(i)}var Fa=Co.getComponent("SeekBar"),Da=class extends(Bo(Fa)){updateAriaAttributes(t){const i=To(this.player()),s=this.ws;t.setAttribute("aria-valuenow",(100*this.yr(i)).toFixed(2)),t.setAttribute("aria-valuetext",No(i-Mo(s),Po(s)))}getPercent(){return this.yr(this.player().currentTime())}handleMouseMove(t){if(this.ws&&this.ws.ads&&this.ws.ads.playing)return;const i=this.ws;let s=Ao(i)+this.calculateDistance(t)*Po(i);s>=i.duration&&(s=i.duration-.1),this.Vn.Qn(s),this.player().currentTime(s)}handleMouseDown(t){this.playingStates.push(!this.player().paused()),this.Vn.Kn(),super.handleMouseDown(t)}handleMouseUp(t){this.videoWasPlaying=Boolean(this.playingStates.pop()),this.Vn.Zn(),super.handleMouseUp(t)}yr(t){let i=this.ws,s=(t-Ao(i))/Po(i);return Ut(s,0,1)}dispose(){this.Vn.Re(),I(this.playingStates)}constructor(t,i){super(t,i),this.playingStates=[],this.on(t,"emptied",this.update),this.on(t,"seeking",this.update),this.Vn=new Ea(this.el(),t)}};Co.registerComponent("SeekBar",Da);var $a=Co.getComponent("ProgressControl");Tt.Ys.Qs&&Co.registerComponent("ProgressControl",class extends $a{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 Ra=Co.getComponent("TooltipProgressBar"),Oa=class extends(Bo(Ra)){updateDataAttr(){let t=To(this.player()),i=this.Pn(t);this.el().setAttribute("data-current-time",i),this.tooltip.innerHTML=i}Pn(t){const i=this.ws;return No(t-Mo(i),Po(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 Va(t){for(const i of t)if(i.enabled)return i}function Ua(t){if(t)return t.label&&""!==t.label?{name:t.label,hd:!1}:{name:za(t),description:La(t),hd:!!t.height&&t.height>=720}}function za(t){return t.height?t.height+"p":t.bandwidth?La(t):""}function La(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":""}Co.registerComponent("TooltipProgressBar",Oa);var Ha=class{get br(){return this.kr}set br(t){let i=this.kr;for(let s=i.length-1;s>=0;s--){let e=i[s];N(t,e)||this.wr(e)}for(let i of t)this._r(i);this.Cr.re()}get Sr(){return this.Cr.menuItems}jr(t){let i=this.Sr;if(i)for(let s of i)if(s.Tr===t)return s}Mr(t){let i=this.Cr.addMenuItem();return i.Tr=t,i.on("click",(()=>this.Ar(i))),i.el().setAttribute("role","menuitemradio"),i}Pr(t){t.dispose()}Er(t){return!0}_r(t){if(this.Er(t)){N(this.kr,t)||this.kr.push(t);let i=this.jr(t)||this.Mr(t);return this.Nr(i),i}this.wr(t)}wr(t){let i=this.jr(t);i&&(this.Cr.removeMenuItem(i),this.Pr(i)),P(this.kr,t)}Re(){const t=[];for(let i of this.kr)t.push(i);for(let i of t)this.wr(i);I(t)}constructor(t){this.kr=[],this.Cr=t}},qa=class extends Ha{Br(){return this.Ir=h.createElement("span"),this.Ir.className="theo-settings-control-menu-item-title",l(this.Ir,this.Fr.localize("Quality")),this.Ir}Dr(){return this.$r=h.createElement("span"),this.$r.className="theo-settings-control-menu-quality-automatic",l(this.$r,this.Fr.localize("Automatic")),this.$r}Rr(){return this.Or=h.createElement("span"),l(this.Or,this.Fr.localize("Automatic")),this.Or}Vr(){return this.Ur=h.createElement("span"),this.Ur.className="theo-primary-color theo-settings-control-menu-item-hd-label",l(this.Ur,this.Fr.localize("HD")),this.Ur}zr(){let t=h.createElement("span");t.className="theo-primary-color theo-settings-control-menu-item-value",t.appendChild(this.$r),t.appendChild(h.createTextNode(" ")),t.appendChild(this.Or),t.appendChild(h.createTextNode(" ")),t.appendChild(this.Ur),this.Lr.el().appendChild(this.Ir),this.Lr.el().appendChild(t),this.Lr.el().setAttribute("aria-label",this.Fr.localize("Open the video quality settings menu"))}Hr(){let t=this.qr,i=t&&Ka(t.targetQuality),s=t&&t.activeQuality,e=Ua(this.Wr(i||s))||{name:this.Fr.localize("Automatic")};l(this.Or,e.name),ii(this.$r,"vjs-hidden",!!i),ii(this.Ur,"vjs-hidden",!e.hd)}Nr(t){let i=Ua(t.Tr)||{name:this.Fr.localize("Automatic")},s=i.name;i.hd&&(s+='<span class="theo-primary-color theo-settings-control-menu-item-hd-label">'+this.Fr.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.Fr.localize("Set video quality to ")+i.name),t.Tr?t.selected(t.Tr===this.Gr):t.selected(!this.Gr)}Ar(t){this.qr&&(this.qr.targetQuality=t.Tr&&t.Tr.videoQualities)}Wr(t,i){const s=i||this.br;for(let i of s)if(t&&i&&-1!==i.videoQualities.indexOf(t))return i}Re(){this._s.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.Xr),this.Fr.off("languagechange",this.te),this.qr&&(this.qr.removeEventListener("activequalitychanged",this.Jr),this.qr.removeEventListener("targetqualitychanged",this.Qr),this.qr.removeEventListener("update",this.Yr)),super.Re()}constructor(t,i,s){super(t.subMenu),this.qr=void 0,this.Gr=void 0,this.Xr=()=>{let t=Va(this._s.videoTracks);if(t===this.qr)return;let i=[];if(this.qr&&(this.qr.removeEventListener("activequalitychanged",this.Jr),this.qr.removeEventListener("targetqualitychanged",this.Qr),this.qr.removeEventListener("update",this.Yr)),this.qr=t,t){t.addEventListener("activequalitychanged",this.Jr),t.addEventListener("targetqualitychanged",this.Qr),t.addEventListener("update",this.Yr);const s=Ga(Qa(t.qualities.filter((t=>t.available))));i=s.length>1?[void 0,...s]:[void 0]}this.br=i,this.Qr(),this.Jr()},this.Yr=t=>{const i=t.track;if(i!==this.qr)return;const s=Ga(Qa(i.qualities.filter((t=>t.available)))),e=i&&Ka(i.targetQuality);let n;this.Gr=this.Wr(e,s),n=s.length>1?[void 0,...s]:[void 0],this.br=n,this.Hr()},this.Jr=()=>{this._r(void 0),this.Hr()},this.Qr=()=>{let t=Va(this._s.videoTracks),i=t&&Ka(t.targetQuality),s=this.Wr(i),e=this.Gr;s!==e&&(this.Gr=s,s&&e||this._r(void 0),e&&N(this.br,e)&&this._r(e),i&&this._r(s),this.Hr())},this.te=()=>{l(this.Cr.menuHeader.el(),this.Fr.localize("Quality")),l(this.Ir,this.Fr.localize("Quality")),l(this.$r,this.Fr.localize("Automatic")),l(this.Or,this.Fr.localize("Automatic")),l(this.Ur,this.Fr.localize("HD")),this.Lr.el().setAttribute("aria-label",this.Fr.localize("Open the video quality settings menu"));for(const t of this.Sr)this.Nr(t);this.Hr()},this.Lr=t,this._s=i,this.Fr=s,this.Ir=this.Br(),this.$r=this.Dr(),this.Or=this.Rr(),this.Ur=this.Vr(),this.zr(),l(this.Cr.menuHeader.el(),this.Fr.localize("Quality")),this.br=[void 0],this._s.videoTracks.addEventListener(["addtrack","removetrack","change"],this.Xr),this.Fr.on("languagechange",this.te),this.Xr()}},Wa=class{get height(){return this.Kr[0].height}get bandwidth(){return this.Kr[0].bandwidth}get videoQualities(){return this.Kr}get label(){return this.Kr[0].label}add(t){this.Kr.push(t)}constructor(t){this.Kr=t}};function Ga(t){let i=[];for(let s of t){let t=s,e=!1;for(let s of i)if(Ya(s,t)){s.add(t),e=!0;break}e||i.push(new Wa([t]))}return i}function Xa(t,i){return t&&i?xi(t,i):wi.Zr}function Ja(t,i){return t===i?wi.Zr:Xa(t.height,i.height)||Xa(t.width,i.width)||Xa(t.bandwidth,i.bandwidth)}function Qa(t){return bi(t,Ja).reverse()}function Ya(t,i){return t.label&&i.label&&t.label===i.label||J(Ua(t),Ua(i))}function Ka(t){return Bt(t)?1===t.length?t[0]:void 0:t}function Za(t){return 1===t?"Normal":""+_.round(100*t)/100}var tu=class extends Ha{Br(){return this.Ir=h.createElement("span"),this.Ir.className="theo-settings-control-menu-item-title",l(this.Ir,this.Fr.localize("Speed")),this.Ir}zr(){const t=h.createElement("span");return t.className="theo-primary-color theo-settings-control-menu-item-value",this.Lr.el().appendChild(this.Ir),this.Lr.el().appendChild(t),this.Lr.el().setAttribute("aria-label",this.Fr.localize("Open the video speed settings menu")),t}Mr(t){let i=super.Mr(t);return this.Nr(i),i}Nr(t){const i=t.Tr,s=this.Fr.localize(Za(i));l(t.el(),s),t.el().setAttribute("aria-label",this.Fr.localize("Set video speed to ")+s),t.selected(t.Tr===this._s.playbackRate)}Ar(t){this._s.playbackRate=t.Tr}Re(){this._s.removeEventListener("ratechange",this.th),this.Fr.off("languagechange",this.te),super.Re()}constructor(t,i,s,e){super(t.subMenu),this.ih=void 0,this.th=()=>{this.ih&&this._r(this.ih);let t=this._s.playbackRate;this.ih=t,l(this.sh,this.Fr.localize(Za(t))),t&&this._r(t)},this.te=()=>{l(this.Cr.menuHeader.el(),this.Fr.localize("Speed")),l(this.Ir,this.Fr.localize("Speed")),this.Lr.el().setAttribute("aria-label",this.Fr.localize("Open the video speed settings menu"));for(const t of this.Sr)this.Nr(t);this.th()},this.Lr=t,this._s=i,this.Fr=s,this.Ir=this.Br(),this.sh=this.zr(),l(this.Cr.menuHeader.el(),this.Fr.localize("Speed")),this.br=e,this._s.addEventListener("ratechange",this.th),this.Fr.on("languagechange",this.te),this.th()}};Co.registerComponent("SettingsButton",class extends ha{createEl(){let t=super.createEl();return this.eh=Co.createEl("span",{className:"theo-settings-control-label-hd theo-primary-background"}),l(this.eh,this.localize("HD")),t.appendChild(this.eh),t}buildCSSClass(){return"vjs-icon-cog theo-settings-control-button "+super.buildCSSClass()}te(){super.te(),l(this.eh,this.localize("HD")),l(this.menu.menuHeader.el(),this.localize("Settings"))}dispose(){this.qr&&(this.qr.removeEventListener("activequalitychanged",this.Jr),this.qr=void 0),this.ws.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.nh),this.rh.Re(),this.hh.Re(),super.dispose()}constructor(t,i){var s,e;super(t,i),this.qr=void 0,this.nh=()=>{let t=Va(this.ws.videoTracks);t!==this.qr&&(this.qr&&this.qr.removeEventListener("activequalitychanged",this.Jr),this.qr=t,t&&t.addEventListener("activequalitychanged",this.Jr),this.Jr())},this.Jr=()=>{var t;const i=null==(t=this.qr)?void 0:t.activeQuality,s=!!(i&&i.height>=720);this.player().toggleClass("theo-hd",s)},Yt(this.menu.el(),"theo-settings-control-menu"),l(this.menu.menuHeader.el(),t.localize("Settings")),this.controlText("Settings"),this.Ie.Be=this.controlText(),this.oh=this.menu.addSubMenuItem({name:"QualityMenuItem"}),this.rh=new qa(this.oh,this.ws,t);let n=null!=(e=null==i||null==(s=i.playerOptions)?void 0:s.playbackRates)?e:[];this.ah=this.menu.addSubMenuItem({name:"PlaybackRateMenuItem"}),this.hh=new tu(this.ah,this.ws,t,n),this.ws.videoTracks.addEventListener(["addtrack","removetrack","change"],this.nh),this.nh()}});var iu=class extends Ha{uh(t){let i=t.label;if(i)return i;let s=t.language;if(s){let t=at(s);if(t)return t.lh}return s||""}dh(){this.br=this.fh}Re(){this.fh.removeEventListener("addtrack",this.ph),this.fh.removeEventListener("removetrack",this.mh),this.fh.removeEventListener("change",this.gh),super.Re()}constructor(t,i){super(t),this.ph=t=>{const i=t.track;this._r(i),i.addEventListener("update",this.yh)},this.mh=t=>{const i=t.track;this.wr(i),i.removeEventListener("update",this.yh)},this.gh=t=>this.dh(),this.yh=()=>{for(const t of this.br)this._r(t)},this.fh=i,this.fh.addEventListener("addtrack",this.ph),this.fh.addEventListener("removetrack",this.mh),this.fh.addEventListener("change",this.gh),this.dh()}},su=class extends iu{Nr(t){let i=t.Tr,s=this.Fr.localize(this.uh(i));l(t.el(),s),t.el().setAttribute("aria-label",this.Fr.localize("Set the audio language to")+" "+s),t.selected(i.enabled)}Ar(t){let i=t.Tr;for(let t of this.ws.audioTracks)t!==i&&(t.enabled=!1);i.enabled=!0}Re(){this.Fr.off("languagechange",this.te),super.Re()}constructor(t,i,s){super(t,i.audioTracks),this.te=()=>{l(this.Cr.menuHeader.el(),this.Fr.localize("Language"));for(const t of this.Sr)this.Nr(t)},this.ws=i,this.Fr=s,l(this.Cr.menuHeader.el(),this.Fr.localize("Language")),this.Fr.on("languagechange",this.te)}};Co.registerComponent("audioTrackButton",class extends ha{buildCSSClass(){return"vjs-icon-audio theo-audio-track-control-button "+super.buildCSSClass()}dispose(){this.bh.Re(),super.dispose()}constructor(t,i){super(t,i),this.minimumMenuItems=2,this.bh=new su(this.menu,this.ws,t),this.controlText("Language"),this.Ie.Be=this.controlText()}});var eu=class extends iu{Er(t){return!!super.Er(t)&&(!t.forced&&pt(t.kind))}Mr(t){let i=super.Mr(t);Yt(i.el(),"theo-text-track-menu-item");let s=h.createElement("span");i.kh=s;let e=h.createElement("div");e.className="theo-text-track-menu-item-toggle",i.wh=e;let n=t=>this._h(t,i);i.xh=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}Nr(t){let i=t,s=i.Tr,e=this.Fr.localize(this.uh(s));l(i.kh,e),i.el().setAttribute("aria-label",this.Fr.localize("Set the subtitle language to")+" "+e),i.el().setAttribute("role","menuitemcheckbox"),i.selected(s.mode===ut.Jn)}Pr(t){let i=t;i.wh.removeEventListener("click",i.xh),super.Pr(t)}Ar(t){let i=t.Tr;for(let t of this.ws.textTracks)t!==i&&ft(t.kind,i.kind)&&(t.mode=ut.Ch);i.mode!==ut.Jn?i.mode=ut.Jn:i.mode=ut.Ch}_h(t,i){t.stopImmediatePropagation(),this.Ar(i)}Re(){this.Fr.off("languagechange",this.te),super.Re()}constructor(t,i,s){super(t,i.textTracks),this.te=()=>{l(this.Cr.menuHeader.el(),this.Fr.localize("Subtitles"));for(const t of this.Sr)this.Nr(t)},this.ws=i,this.Fr=s,l(this.Cr.menuHeader.el(),s.localize("Subtitles")),this.Fr.on("languagechange",this.te)}};Co.registerComponent("subtitlesButton",class extends ha{buildCSSClass(){return"vjs-icon-subtitles theo-text-track-control-button "+super.buildCSSClass()}dispose(){this.bh.Re(),super.dispose()}constructor(t,i){super(t,i),this.bh=new eu(this.menu,this.ws,t),this.controlText("Subtitles"),this.Ie.Be=this.controlText()}});var nu,ru=Co.getComponent("playToggle");!function(t){t.Sh="Pause",t.jh="Play",t.Th="Replay"}(nu||(nu={}));var hu=class extends(Bo(ru)){handleClick(t){this.ws.muted||this.ws.prepareWithUserAction(),super.handleClick(t)}handlePlay(t){super.handlePlay(t),this.controlText("Pause"),this.Ie.Be=this.controlText()}handlePause(t){this.ws.ended||(super.handlePause(t),this.controlText("Play"),this.Ie.Be=this.controlText())}te(){this.Ie.Be=this.controlText()}dispose(){this.Ie.Re(),this.ws.removeEventListener("ended",this.Mh),super.dispose()}constructor(t,i){super(t,i),this.Mh=()=>{this.controlText("Replay"),this.Ie.Be=this.controlText()},this.controlText("Play"),this.Ie=new na(this,this.controlText()),this.ws.addEventListener("ended",this.Mh),this.on(t,"languagechange",this.te),Tt.Ys.Je&&new qo(this.el())}};Co.registerComponent("playToggle",hu);var ou,au=Co.getComponent("fullscreenToggle");!function(t){t.Ah="Exit fullscreen",t.Ph="Fullscreen"}(ou||(ou={}));var uu=class extends(Bo(au)){handleClick(t){this.ws.prepareWithUserAction(),super.handleClick(t)}handleFullscreenChange(t){super.handleFullscreenChange(t),this.updateContent()}updateContent(){const t=this.player().isFullscreen()?"Exit fullscreen":"Fullscreen";this.controlText(t),this.Ie.Be=this.controlText()}dispose(){this.Ie.Re(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Fullscreen"),this.Ie=new na(this,this.controlText()),Tt.Ys.Je&&new qo(this.el()),this.on(t,"languagechange",this.updateContent)}};Co.registerComponent("fullscreenToggle",uu);var cu,lu=Co.getComponent("muteToggle");!function(t){t.Eh="Unmute",t.Nh="Mute"}(cu||(cu={}));var du=class extends(Bo(lu)){handleClick(t){this.ws.muted&&!this.ws.paused&&this.ws.prepareWithUserAction(),super.handleClick(t)}update(t){super.update(t),this.te()}te(){const t=this.player().muted()?"Unmute":"Mute";this.controlText(t),this.Ie.Be=this.controlText()}dispose(){this.Ie.Re(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Mute"),this.Ie=new na(this,this.controlText()),Tt.Ys.Je&&new qo(this.el()),this.on(t,"languagechange",this.te),ui&&(this.removeClass("vjs-hidden"),this.on(t,"loadstart",(()=>{this.removeClass("vjs-hidden")})))}};Co.registerComponent("muteToggle",du);var fu=Co.getComponent("BigPlayButton"),vu="theo-play-svg-circle",pu='<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="'+vu+'" 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>',mu=class extends(Bo(fu)){createEl(){let t=super.createEl(),i=Co.createEl("div",{className:"theo-big-play-button-svg-container"});return i.innerHTML=pu,t.appendChild(i),t}buildCSSClass(){return"theo-primary-color "+super.buildCSSClass()}handleClick(t){this.ws.muted||this.ws.prepareWithUserAction(),super.handleClick(t),void 0!==this.ws.vr&&"unavailable"!==this.ws.vr.state&&(this.ws.vr.useDeviceMotionControls=!0)}};Co.registerComponent("BigPlayButton",mu);var gu=/^([^#]*)#xywh=(\d+),(\d+),(\d+),(\d+)\s*$/;Co.registerComponent("MouseTimeDisplay",class extends ja{Bh(t){const i=t.track;"metadata"===i.kind&&"thumbnails"===i.label&&void 0===this.Ih&&(this.Ih=i,this.Fh=i.src?Tt.Dh(i.src).href:void 0,this.Ih.addEventListener(["addcue","removecue"],this.$h),this.Rh())}Oh(t){t.track===this.Ih&&this.Vh()}createEl(){const t=super.createEl();return this.Uh=Co.createEl("img",{className:"theo-time-tooltip-thumbnail"}),this.zh=Co.createEl("canvas",{className:"theo-time-tooltip-thumbnail"}),t}update(t,i){super.update(t,i),this.keepTooltipsInside&&this.Lh(t)}Lh(t){let i;if(this.Ih&&this.Ih.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.Ih.cues,t);i=s&&s.content}if(i===this.Hh)return;if(this.Hh=i,Co.toggleClass(this.el(),"theo-time-tooltip-has-thumbnail",!!i),!i)return void this.qh();const s=i.match(gu);if(s){let[,t,i,e,n,r]=s;t=this.Wh(t);const h={Gh:+i,Xh:+e,ji:+n,Ti:+r};this.Jh(t,h)}else{const t=this.Wh(i);this.Jh(t)}}Rh(){S(this.An)||this.Lh(this.An)}Wh(t){return this.Ih&&this.Fh?Tt.Dh(t,this.Fh).href:t}Jh(t,i){this.Uh&&(this.Uh.src!==t?(this.Uh.onload=()=>{this.Qh(i)},this.Uh.src="",this.Uh.src=t):this.Qh(i))}Qh(t){if(!this.zh||!this.Uh)return;const i=this.zh.getContext("2d");i&&(null!=t||(t={Gh:0,Xh:0,ji:this.Uh.naturalWidth,Ti:this.Uh.naturalHeight}),this.zh.width=t.ji,this.zh.height=t.Ti,i.drawImage(this.Uh,t.Gh,t.Xh,t.ji,t.Ti,0,0,t.ji,t.Ti),this.Yh(this.zh))}Yh(t){this.Kh||(Gt(this.tooltip,t),this.Kh=t),this.En()}qh(){this.Kh&&(this.tooltip.removeChild(this.Kh),this.Kh=void 0,this.En())}Vh(){void 0!==this.Ih&&(this.Ih.removeEventListener(["addcue","removecue"],this.$h),this.Ih=void 0),this.Fh=void 0,this.qh(),this.Hh=void 0}dispose(){this.Vh(),super.dispose()}constructor(t,i){super(t,i),this.Kh=void 0,this.Ih=void 0,this.Fh=void 0,this.Zh=t=>this.Bh(t),this.io=t=>this.Oh(t),this.$h=t=>this.Rh(),this.showThumbnails=()=>{this.Kh&&this.Kh.hidden&&(this.Kh.hidden=!1,this.En())},this.hideThumbnails=()=>{!this.Kh||this.Kh.hidden||this.player().scrubbing()||(this.Kh.hidden=!0,this.En())},this.on(this.player().textTracks(),"addtrack",this.Zh),this.on(this.player().textTracks(),"removetrack",this.io),At.Qs&&(this.on(t,"seeking",this.showThumbnails),this.on(t,"seeked",this.hideThumbnails))}});var yu=Co.getComponent("VolumeLevel");Co.registerComponent("VolumeLevel",class extends yu{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-volume-level "+super.buildCSSClass()}});var bu=Co.getComponent("Component"),ku=class extends bu{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-menu-container "+super.buildCSSClass()}};ku.prototype.h=fi({},ku.prototype.h,{children:[]}),Co.registerComponent("controlBarMenuContainer",ku);var wu=Co.getComponent("Player"),_u=class extends wu{dispose(){const t=this.el(),i=this.contentEl(),s=t.parentNode,e=t.nextSibling;super.dispose(),qt(i),this.Ci&&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)}};_u.prototype.h=fi({},wu.prototype.h,{children:["bigPlayButton","AdControlPanel","TopControlBar","mediaLoader","upNextContainer","posterImage","chromecastOverlay","upcomingAdNotificationText","controlBarMenuContainer","controlBar","textTrackDisplay","loadingSpinner","errorDisplay","textTrackSettings","xrCompass"]}),Co.registerComponent("Player",_u);var xu=Co.getComponent("Player"),Cu=xu.prototype.es;xu.prototype.es=function(t){if(!(this.H&&this.H.$s&&this.H.$s()))return Cu.call(this,t)};var Su=xu.prototype.createEl;function ju(t,i,e,n){let r=fi({controls:!0,playbackRates:[.25,.5,1,1.25,1.5,2]},e);r.controlBar=fi({progressControl:{keepTooltipsInside:!0}},r.controlBar);let h=r.techOrder||(r.techOrder=[]);-1===h.indexOf("THEOplayer")&&h.unshift("THEOplayer"),(r.theoplayer||(r.theoplayer={})).player=t,e&&Ft(e.language)&&(r.languages=fi({},r.languages,{[ht]:e.language}),r.language=ht),i.setAttribute("data-vjs-player","");let o=i.getAttribute("style"),a=Co(t.element,r,n);return a.ready((()=>{Fo(a),function(t,i){if(i){if(i.ads){const s=i=>{const s="adbreakbegin"===i.type,e=i.adBreak.integration===ct.so;Ro(t,s,e)};i.ads.addEventListener("adbreakbegin",s),i.ads.addEventListener("adbreakend",s)}if(i.verizonMedia){const s=i=>{const s="adbreakbegin"===i.type;Ro(t,s,!1)};i.verizonMedia.ads.adBreaks.addEventListener("addadbreak",(t=>{t.adBreak.addEventListener("adbreakbegin",s),t.adBreak.addEventListener("adbreakend",s)}))}i.addEventListener("sourcechange",(()=>{Ro(t,!1,!1)}))}}(a,t),function(t){t.on("mouseleave",Oo)}(a)})),i.removeAttribute("data-vjs-player"),o?i.setAttribute("style",o):i.removeAttribute("style"),Tt.Ys.Qs&&(Yt(i,"theo-mobile"),function(t){let i=s.outerHeight,e=s.outerWidth,n=i>e;n?(Zt(t,"theo-mobile-landscape"),Yt(t,"theo-mobile-portrait")):(Zt(t,"theo-mobile-portrait"),Yt(t,"theo-mobile-landscape"))}(i)),function(t){t.on("seeking",(()=>{Jt(t.el(),"vjs-ended")&&t.currentTime()!==t.duration()&&t.play()}))}(a),a}xu.prototype.createEl=function(){let t=Su.call(this),i=Co.createEl("div");for(i.className="theo-player-wrapper";t.firstChild;)i.appendChild(t.firstChild);return t.appendChild(i),this.S=i,t};var Tu=Co.getComponent("Button");var Mu="THEOPiPCloseButton";Co.registerComponent(Mu,class extends Tu{buildCSSClass(){return"theo-close-button theo-pip-close"}handleClick(){this.no.eo()}constructor(t,i){if(super(t,i),this.controlText("Close Picture-in-Picture"),!function(t){return!!t&&Boolean(t.no)}(i))throw new g("Invalid Picture-in-picture options.");this.no=i.no}});var Au,Pu=class extends D{get ro(){return this.ho}get oo(){return this.t.cs()}ao(){this.t.yn(L.jh,this.uo),this.co||this.t.yn(L.lo,this.do),this.t.fo.on("languagechange",this.te)}vo(){var t;return"theo-pip-"+(null!=(t=this.po)?t:"bottom-right")}mo(t){let i=this.yo;i&&!this.oo&&(this.bo||this.ko(),this.wo(),Yt(i,"theo-pip"),Yt(i,this.vo()),this.ho=!0,this._o=t,this.xo=!1,this.Co(new Dt(Vt.PICTURE_IN_PICTURE)))}So(t){let i=this.yo;i&&(this.jo(),Zt(i,"theo-pip"),Zt(i,this.vo()),this.ho=!1,this.xo=t,this.To=this._o,this._o=!1,this.Co(new Dt(Vt.INLINE)))}ko(){if(!this.bo){let t=this.t.fo;t.addChild(Mu,{no:this});let i=h.createElement("div");i.className="theo-pip-overlay",this.Mo=h.createElement("div"),this.Mo.className="theo-pip-overlay-text",l(this.Mo,t.localize("Video playing in Picture-in-Picture mode")),i.appendChild(this.Mo),Gt(t.el(),i),this.Ao=i,this.bo=!0}}Po(){this.Eo&&!this.No&&this.t.Bo&&(this.Io=this.t.Bo.Fo(R,this.Do),this.No=!0)}$o(){this.Io&&this.t.Bo&&(this.t.Bo.Ro(this.Io),this.No=!1)}wo(){let t=this.t.fo.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"}jo(){let t=this.t.fo.contentEl();t.style.top="",t.style.bottom="",t.style.right="",t.style.left="",t.style.width="",t.style.height="",t.style.position=""}Oo(){Zt(this.yo,"theo-pip"),this.ro&&this.po&&Zt(this.yo,"theo-pip-"+this.po),this.Ao&&(qt(this.Ao),this.Ao=void 0)}gn(){this.Oo(),this.$o(),this.Vo(),this.t.fn(L.jh,this.uo),this.t.fn(L.lo,this.do),this.t.fo.off("languagechange",this.te),this.t=void 0}constructor(t,i,s){super(),this.Uo=!1,this.ho=!1,this.xo=!1,this._o=!1,this.bo=!1,this.No=!1,this.To=!1,this.uo=()=>{this.Uo=!0,this.Eo&&!this.ro&&this.Io&&this.zo&&this.Io.Lo<=this.zo&&this.mo(!1)},this.do=()=>{this.co||(this.Uo=!1,this.So(!1))},this.te=()=>{if(this.Mo){const t=this.t.fo;l(this.Mo,t.localize("Video playing in Picture-in-Picture mode"))}},this.Do=t=>{!this._o&&this.Eo&&(S(t)||(this.zo&&t<=this.zo||this.To?this.ho||this.xo||this.mo(!1):this.ho?this.So(!1):this.xo=!1))},this.zo=i.visibility,this.po=i.position,this.co=i.retainPresentationModeOnSourceChange,this.Eo=void 0!==this.zo,this.t=t,this.yo=t.Ho,this.eo=s,this.ao()}},Eu=class extends zt{qo(){let t=super.qo();return t===Vt.INLINE&&this.Wo&&this.Wo.ro?Vt.PICTURE_IN_PICTURE:t}Go(t){return t===Vt.PICTURE_IN_PICTURE||super.Go(t)}Xo(t,i){t===Vt.FULLSCREEN&&this.Wo.$o(),super.Xo(t,i),t!==Vt.FULLSCREEN&&this.Wo.Po()}Jo(t,i){t!==i&&(t===Vt.FULLSCREEN&&this.Wo.So(!1),t===Vt.INLINE&&i===Vt.PICTURE_IN_PICTURE&&this.Wo.So(!0),super.Jo(t,i),t===Vt.PICTURE_IN_PICTURE&&(i===Vt.INLINE?this.Wo.mo(!0):this.Wo.mo(!1)))}gn(){super.gn(),this.Wo.gn(),this.Qo.fn(L.jh,this.Yo),this.Qo=void 0}constructor(t,i,s){super(i),this.Ko=()=>this.Yr(),this.eo=()=>this.Zo(Vt.INLINE),this.Yo=()=>{this.qo()!==Vt.FULLSCREEN&&this.Wo.Po(),this.Qo.fn(L.jh,this.Yo)},this.Qo=t,this.Wo=new Pu(t,s.pip,this.eo),this.Wo.yn("presentationmodechange",this.Ko),this.Qo.yn(L.jh,this.Yo),this.Yr()}},Nu=class extends D{get ta(){return ci.ia(this.fo.el())||this.fo.supportsFullScreen()}get cs(){return this.fo.isFullscreen()||this.sa}mo(){this.fo.requestFullscreen()}So(){this.fo.exitFullscreen(),this.ea.So()}gn(){this.Vo(),this.fo.off("fullscreenchange",this.na),this.ea.fn(It.ra,this.na),this.ea.fn(It.ha,this.Ds),this.fo.isFullWindow&&this.fo.exitFullscreen()}constructor(t,i){super(),this.Os=!1,this.sa=!1,this.oa=!1,this.na=()=>{if(this.oa)return;let t=this.Os,i=this.cs;t!==i&&(this.Os=i,this.Co(new hi))},this.aa=()=>{this.sa=this.ea.cs,this.na()},this.ua=()=>{this.oa||(this.fo.isFullWindow&&this.fo.supportsFullScreen()||this.sa&&!this.fo.supportsFullScreen())&&(this.oa=!0,this.fo.exitFullscreen(),this.fo.requestFullscreen(),this.oa=!1,this.na())},this.fo=t,this.ea=i,this.fo.on("fullscreenchange",this.na),this.ea.yn(It.ra,this.aa),this.ea.yn(It.ca,this.ua),this.ea.yn(It.ha,this.Ds),this.na()}};function Bu(t){return class extends t{get Bo(){return this.la}cs(){return"fullscreen"===this.da.qo()}fa(){return function(t,i){let s=w.create(t);const e=i.fo;return G(s,{get controls(){return e.controls()},set controls(t){e.controls(Z(t))},get presentation(){return i.da.va},get presentationMode(){return i.da.qo()},set presentationMode(t){const s=Ht(t);s&&i.da.Zo(s)},get ui(){return e},get visibility(){return i.Bo.va}})}(this.pa,this)}gn(){super.gn(),this.da.gn(),this.ma.gn(),this.fo.dispose(),this.la.gn()}ga(t){this.fo.src(""),super.ga(t)}constructor(t,i,s){super(i,s),this.Ho=t,this.la=new V(t),this.pa=super.fa(),w.defineProperty(this.pa,"constructor",{value:W}),this.fo=ju(this.pa,this.Ho,s.ui),this.ma=new Nu(this.fo,this.ya),this.da=new Eu(this,this.ma,s),this.da.yn("presentationmodechange",this.Ds)}}}function Iu(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(Et(t)&&!S(t))return Ut(t,0,1)}(t.visibility),t.retainPresentationModeOnSourceChange=Z(t.retainPresentationModeOnSourceChange),t}function Fu(){return Au||(Au=function(t){let i=t;for(const t of Si)i=t(i);return i}(Au=Bu(H()))),Au}function Du(t,i){const s=function(t){const i=Pt(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=Iu(i.pip),i}(i),e=h.createElement("div");ei(e),t.appendChild(e);const n=new(Fu())(t,e,s);n.ba=n;let r=n.va;return n.ka(),n.wa(z),w.defineProperty(r,"constructor",{value:Du}),r=q(r),St(n),function(t){for(const i of Ti)i(t)}(n),r}var $u="theo-cast-",Ru=Co.getComponent("Button"),Ou=class extends(Bo(Ru)){get _a(){throw new g("xa")}get Ca(){return this.h.Ca}get Sa(){return this.h.Sa}buildCSSClass(){return $u+"button theo-"+this.Sa+"-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=$u+"svg-container",r.innerHTML=this.Ca,e.appendChild(n),e.appendChild(r),e}handleClick(t){var i;if(super.handleClick(t),this.ja===Wt.AVAILABLE)null==(i=this._a)||i.start();else if(this.ja===Wt.CONNECTED||this.ja===Wt.CONNECTING){var s;null==(s=this._a)||s.stop()}}Ta(t){Zt(this.yo,"theo-"+this.Sa+"-"+this.ja),this.ja=t,Yt(this.yo,"theo-"+this.Sa+"-"+this.ja),this.te()}te(){this.Ma(this.ja),this.Ie.Be=this.controlText()}Ma(t){t===Wt.CONNECTED?this.controlText("Stop Casting"):t===Wt.AVAILABLE?this.controlText("Start Casting"):t===Wt.CONNECTING?this.controlText("Connecting"):this.controlText("Unavailable")}constructor(t,i){var s;super(t,i),this.yo=t.el(),this.ja=Wt.UNAVAILABLE,this.controlText("Unavailable"),this.Ie=new na(this,this.controlText()),null==(s=this._a)||s.addEventListener("statechange",(t=>{const i=t;this.Ta(i.state)})),Tt.Ys.Je&&(this.Aa=new qo(this.el())),this.Ta(this._a?this._a.state:Wt.UNAVAILABLE),this.on(t,"languagechange",this.te)}},Vu=0;function Uu(){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-'+Vu+'">\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-'+Vu+')">\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 Vu++,t}Co.registerComponent("chromecastButton",class extends Ou{get _a(){var t;return null==(t=this.ws.cast)?void 0:t.chromecast}constructor(t,i){super(t,fi({},i,{Sa:"chromecast",Ca:Uu()}))}});var zu="theo-chromecast-",Lu=Co.getComponent("Component"),Hu=class t extends(Bo(Lu)){buildCSSClass(){return zu+"overlay "+super.buildCSSClass()}createEl(){const i=super.createEl();Yt(i,zu+"overlay");const s=Co.createEl("div",{className:zu+"status-icon",innerHTML:t.ICON_SVG}),e=Co.createEl("div",{className:zu+"status-info"});l(e,"Playing on");const n=Co.createEl("div",{className:zu+"status-title"}),r=Co.createEl("div",{className:zu+"status"});return this.mr=n,r.appendChild(s),r.appendChild(e),r.appendChild(n),i.appendChild(r),i}dispose(){var t;null==(t=this.Pa)||t.removeEventListener("statechange",this.update),this.Pa=void 0,this.ws.removeEventListener("play",this.update),super.dispose()}constructor(t,i){var s,e;super(t,i),this.update=()=>{this.Pa?(this.mr&&l(this.mr,this.Pa.receiverName||""),this.Pa.state===Wt.CONNECTED?this.show():this.hide()):this.hide()},this.Pa=null==(s=this.ws.cast)?void 0:s.chromecast,null==(e=this.Pa)||e.addEventListener("statechange",this.update),this.ws.addEventListener("play",this.update),this.update()}};Hu.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>',Co.registerComponent("chromecastOverlay",Hu);Co.registerComponent("airplayButton",class extends Ou{dispose(){var t,i;null==(t=this.ws.ads)||t.removeEventListener("adbreakbegin",this.Ea),null==(i=this.ws.ads)||i.removeEventListener("adbreakend",this.Na),this.ws.removeEventListener("currentsourcechange",this.Na),super.dispose()}get _a(){var t;return null==(t=this.ws.cast)?void 0:t.airplay}constructor(t,i){var s,e;super(t,fi({},i,{Sa:"airplay",Ca:'\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.Na=()=>{this.enable()},this.Ea=()=>{this.disable()},null==(s=this.ws.ads)||s.addEventListener("adbreakbegin",this.Ea),null==(e=this.ws.ads)||e.addEventListener("adbreakend",this.Na),this.ws.addEventListener("currentsourcechange",this.Na)}});var qu=Co.getComponent("Button"),Wu=class extends(Bo(qu)){buildCSSClass(){return"theo-vr-button theo-controlbar-button "+super.buildCSSClass()}handleClick(){this.ws.vr.stereo=!this.ws.vr.stereo,this.te()}_n(){this.ws.vr&&this.ws.vr.state!==yt.Rs?(this.show(),this.ws.vr.canPresentVR?(this.enable(),this.te()):(this.disable(),this.controlText("No VR capable device found"),this.Ba.Be=this.controlText())):this.hide()}te(){var t;this.controlText((null==(t=this.ws.vr)?void 0:t.stereo)?"Stop watching in VR":"Watch in VR"),this.Ba.Be=this.controlText()}dispose(){var t;null==(t=this.ws.vr)||t.removeEventListener("statechange",this.Ia),super.dispose()}constructor(t,i){var s;super(t,i),this.Ia=()=>this._n(),this.controlText("Watch in VR"),this.Ba=new na(this,this.controlText()),null==(s=this.ws.vr)||s.addEventListener("statechange",this.Ia),this._n(),Tt.Ys.Je&&new qo(this.el()),this.on(t,"languagechange",this.te)}};Co.registerComponent("vrButton",Wu);var Gu=Co.getComponent("Component"),Xu=class extends Gu{createEl(){let t=super.createEl("div",{className:this.buildCSSClass()}),i=Co.createEl("div",{className:"theo-360-fov"});return t.appendChild(i),this.Fa=i,t}buildCSSClass(){return"theo-360-compass "+super.buildCSSClass()}_n(){this.ws.vr.state===yt.Rs?this.hide():this.show()}Da(){let t=-this.ws.vr.direction.yaw+40;this.Fa.style[si("transform")]="scale(0.875) rotate("+t+"deg) skew("+"-10deg)"}dispose(){this.ws.vr.removeEventListener("statechange",this.Ia),this.ws.vr.removeEventListener("directionchange",this.$a),super.dispose()}constructor(t,i,s){super(t,i),this.Ia=()=>this._n(),this.$a=()=>this.Da(),this.ws=s,this.ws.vr.addEventListener("statechange",this.Ia),this.ws.vr.addEventListener("directionchange",this.$a),this._n(),this.Da()}},Ju=_.pow(2,31)-1,Qu=Co.getComponent("Component"),Yu=class extends Qu{Ra(){this.ws.vr.state===yt.Oa?this.Va():this.Ua()}Va(){if(this.za)return;this.za=!0;let t=this.ws.element;this.La=t.style.zIndex||"",t.style.zIndex=""+Ju,this.Ha=this.player().isFullscreen(),this.player().requestFullscreen()}Ua(){if(!this.za)return;this.za=!1,this.ws.element.style.zIndex=this.La,this.Ha?this.player().requestFullscreen():this.player().exitFullscreen()}dispose(){this.Ua(),this.ws.vr.removeEventListener("statechange",this.qa),super.dispose()}constructor(t,i,s){super(t,i),this.za=!1,this.Ha=!1,this.La="",this.qa=()=>this.Ra(),this.ws=s,this.ws.vr.addEventListener("statechange",this.qa),this.Ra()}};Mi((function(t){let i=t.va;if(!i.vr)return;let s=t.fo,e=new Xu(s,{},i);if(t.yn(L.lo,(()=>{var i;s.removeChild(e);let n=null==(i=t.Wa())?void 0:i.vr;void 0===n||n.nativeVR||s.addChild(e)})),At.Ga){let t=new Yu(s,{},i);s.addChild(t)}}));var Ku=class extends ${constructor(){super("relatedchange")}},Zu=["relatedchange"],tc=class extends D{get va(){return this.Xa||(this.Xa=function(t){let i,s={get sources(){return t.Ja},set sources(i){t.Ja=i},addEventListener(t,s){i.yn(t,s)},removeEventListener(t,s){i.fn(t,s)}};return i=new Rt(Zu,!0,s),i.Qa(t),s}(this)),this.Xa}get Ja(){return this.Ya}set Ja(t){this.Ya=function(t){return t.filter((t=>t&&($t(t.link)||Y(t,["source"]))))}(t),t.length>this.Ya.length&&console.warn("One or more of the configured related content sources are invalid. Check if they have a source or a link."),this.Co(new Ku)}gn(){this.Vo(),this.Ya=[]}constructor(...t){super(...t),this.Ya=[]}};xt((function(t){return class extends t{fa(){const t=this.Ka;return G(super.fa(),{get related(){return t.va}})}gn(){this.Ka.gn(),super.gn()}constructor(t,i){super(t,i),this.Ka=new tc}}}),wt.Za);var ic=Co.getComponent("Button"),sc=class extends ic{buildCSSClass(){return"vjs-icon-view-grid theo-related-button "+super.buildCSSClass()}handleClick(){this.iu.tu?this.iu.be():this.iu.ge()}te(){this.Ie.Be=this.controlText()}dispose(){this.player().topControlBar.removeChild(this),super.dispose()}constructor(t,i,s){super(t,s),this.yo=t.el(),this.iu=i,this.player().topControlBar.addChild(this),this.hide(),this.controlText(this.localize("Related content")),this.Ie=new na(this,this.controlText()),this.on(t,"languagechange",this.te)}},ec=Co.getComponent("Button"),nc=class extends ec{buildCSSClass(){return"theo-secondary-background theo-close-button"}handleClick(){this.su.hide()}constructor(t,i){super(t),this.su=i}},rc=(()=>{let t=h.createElement("div");return t.className="theo-related-grid-tile",t.innerHTML='<a class="theo-related-grid-tile-content"><div class="theo-related-grid-tile-image"></div><span class="theo-related-grid-tile-title theo-primary-border theo-tertiary-background"></span><span class="theo-related-grid-tile-duration"></span></a>',t})();function hc(t,i,s){let e=rc.cloneNode(!0),n=e.querySelector(".theo-related-grid-tile-content");Y(s,["source"])?(n.style.cursor="pointer",n.addEventListener("click",(()=>{t.source=s.source,i.be()}))):$t(s.link)&&n.setAttribute("href",s.link);let r=e.querySelector(".theo-related-grid-tile-image");r.style.backgroundImage='url("'+gi(s.image)+'")',r.removeAttribute("id");let h=e.querySelector(".theo-related-grid-tile-title");s.title?(l(h,s.title),h.removeAttribute("id")):qt(h);let o=e.querySelector(".theo-related-grid-tile-duration");return s.duration?(l(o,s.duration),o.removeAttribute("id")):qt(o),e}var oc=[15,12,9,8,6,4,3,2,1];var ac=class{get eu(){return"theo-"+this.nu+"-item-grid"}ru(){this.hu.focus()}ou(t){this.au(),function(t){if(t.length)for(let i of oc)if(t.length>=i){t.length=i;break}}(t),this.uu(t.length);for(let i of t){let t=hc(this.cu.va,this.lu,i);this.du.appendChild(t)}}au(){this.du.innerHTML=""}fu(){let t=h.createElement("div");t.className="theo-overlay-panel";const i=h.createElement("div");return i.className="theo-related-grid",this.vu.className="theo-related",this.hu.controlText("Close Related Content"),this.pu.appendChild(this.vu),this.vu.appendChild(t),t.appendChild(this.hu.el()),t.appendChild(i),i}uu(t){Zt(this.du,this.eu),this.nu=t,Yt(this.du,this.eu)}gn(){qt(this.vu),this.mu.gn(),this.gu.gn(),this.hu.dispose(),this.cu=void 0}constructor(t,i,s,e,n){this.cu=t,this.yu=i,this.lu=s,this.pu=e,this.nu=12,this.bu=t=>{this.du.style.width=t.width+"px"},this.vu=h.createElement("div"),this.hu=new nc(this.yu,{hide:()=>{this.lu.be()}}),this.du=this.fu(),this.gu=new uc(n),this.gu.yn(Kt.pn,this.bu),this.mu=new dt(this.du,this.gu),this.uu(12)}},uc=class extends D{get ku(){return this.wu||0}get _u(){return this.xu._u}gn(){this.Vo(),this.xu.fn(Kt.pn,this.Cu)}constructor(t){super(),this.xu=t,this.Cu=t=>{let i=t.width;if(9*(t.width/16)>t.height){i=16*(t.height/9)}this.wu=i,this.Co(new ti(this.ku,t.height))},this.xu.yn(Kt.pn,this.Cu)}},cc=class extends ${constructor(){super("show")}},lc=class extends ${constructor(){super("hide")}},dc="theo-related-available",fc="theo-related-showing",vc=[...Zu,"show","hide"],pc=class extends D{get va(){return this.Xa||(this.Xa=function(t){let i;const s={get sources(){return t.Ja},set sources(i){t.Ja=i},get showing(){return t.tu},show(){t.ge()},hide(){t.be()},addEventListener(t,s){i.yn(t,s)},removeEventListener(t,s){i.fn(t,s)}};return i=new Rt(vc,!0,s),i.Qa(t),s}(this)),this.Xa}get Ja(){return this.Su.Ja}set Ja(t){this.Su.Ja=t}get tu(){return this.ju}ge(){let t=this.ju;this.ju=!0,this.Tu(fc),this.Mu.ru(),this.yu.paused()?this.Au=!0:this.yu.pause(),t!==this.ju&&this.Co(new cc)}be(){let t=this.ju;this.ju=!1,this.Pu(fc),this.Eu.focus(),this.Au||this.yu.play(),this.Au=!1,t!==this.ju&&this.Co(new lc)}Tu(t){this.yu.el().classList.add(t)}Pu(t){this.yu.el().classList.remove(t)}gn(){this.Vo(),this.Mu.gn()}constructor(t,i,s,e){super(),this.ju=!1,this.Au=!1,this.Nu=t=>{const i=this.Ja;this.Mu.ou(i),i.length?(this.Tu(dc),this.Eu.show()):(this.Pu(dc),this.Eu.hide()),this.Co(t)},this.Su=i,this.Su.yn("relatedchange",this.Nu),this.yu=s,this.Mu=new ac(t,this.yu,this,s.contentEl(),e),this.Eu=new sc(s,this,{})}};ji((function(t){return class extends t{fa(){const t=this.Bu;return G(super.fa(),{get related(){return t.va}})}gn(){this.Bu.gn(),super.gn()}constructor(t,i,s){super(t,i,s),this.Bu=new pc(this,this.Ka,this.fo,this.Iu)}}}));var mc,gc=Co.getComponent("Button"),yc=class extends gc{buildCSSClass(){return"vjs-icon-share theo-social-button "+super.buildCSSClass()}handleClick(){this.Fu.showing?this.Fu.hide():this.Fu.show()}te(){this.Ie.Be=this.controlText()}dispose(){this.player().topControlBar.removeChild(this),super.dispose()}constructor(t,i,s){super(t,s),this.yo=t.el(),this.Fu=i,this.player().topControlBar.addChild(this),this.hide(),this.controlText("Share Video"),this.Ie=new na(this,this.controlText()),this.on(t,"languagechange",this.te)}};function bc(t,i,s){switch(i){case"iconurl":return function(t,i){let s=h.createElement("a");var e;s.className="theo-social-iconurl",s.title=null!=(e=t.label)?e:"",s.target="Du",s.href=i;const n=h.createElement("img");var r,o;return n.src=null!=(r=t.icon)?r:"",n.alt=null!=(o=t.label)?o:"",n.width=25,n.height=25,s.appendChild(n),s}(t,s);case"text":return function(t){let i=h.createElement("div");if(i.className="theo-social-text",t.label){let s=h.createElement("h5");s.className="theo-primary-background theo-social-label",l(s,t.label),i.appendChild(s)}let s=h.createElement("p");var e;return s.className="theo-social-content-container theo-tertiary-background",s.tabIndex=0,l(s,null!=(e=t.text)?e:""),i.appendChild(s),i}(t);case"texturl":return function(t,i){let s=h.createElement("div");if(s.className="theo-social-texturl",t.label){let i=h.createElement("h5");i.className="theo-primary-background theo-social-label",l(i,t.label),s.appendChild(i)}let e=h.createElement("div");e.className="theo-social-content-container theo-tertiary-background";let n=h.createElement("a");return n.target="Du",n.href=i,l(n,i),e.appendChild(n),s.appendChild(e),s}(t,s)}}!function(t){t.$u="iconurl",t.Ru="text",t.Ou="texturl"}(mc||(mc={}));var kc="<URL>";var wc=class{get we(){return this.vu}Vu(t){this.au();for(let i of t)this.Uu(i)}ru(){this.hu.focus()}Uu(t){let i=function(t,i){return t.src?pi(t.src,kc)?t.src.replace(kc,i):t.src:i}(t,this.lu.zu),s=function(t){if(t)return t.icon?"iconurl":t.text?"text":"texturl"}(t),e=bc(t,s,i);e&&("iconurl"===s?this.Lu.appendChild(e):this.Hu.appendChild(e))}au(){this.Lu.innerHTML="",this.Hu.innerHTML=""}gn(){qt(this.vu),this.qu.gn()}constructor(t,i,s,e){this.Qo=t,this.lu=i,this.pu=s,this.Wu=e;const n=h.createElement("div");n.className="theo-overlay-panel",this.hu=new nc(this.Qo,this.lu.va),this.hu.controlText("Close Share"),this.Mu=h.createElement("div"),this.Mu.className="theo-social-container",this.vu=h.createElement("div"),this.vu.className="theo-social",this.Lu=h.createElement("div"),this.Lu.className="theo-social-icon-container",this.Hu=h.createElement("div"),this.Hu.className="theo-social-text-container",this.pu.appendChild(this.vu),this.vu.appendChild(n),this.Mu.appendChild(this.Lu),this.Mu.appendChild(this.Hu),n.appendChild(this.hu.el()),n.appendChild(this.Mu),this.qu=new dt(this.vu,this.Wu)}},_c="theo-social-available",xc="theo-social-showing",Cc=class{get va(){return this.Xa}get tu(){return this.ju}get Gu(){return this.Xu}set Gu(t){this.Xu=t,this.Mu.Vu(t),t.length?(this.Tu(_c),this.Eu.show()):(this.Pu(_c),this.Eu.hide())}get zu(){return this.Ju||Lt()}set zu(t){this.Ju=t}ge(){this.ju=!0,this.Tu(xc),this.Mu.ru(),this.Qu.paused()?this.Au=!0:this.Qu.pause()}be(){this.ju=!1,this.Pu(xc),this.Eu.focus(),this.Au||this.Qu.play(),this.Au=!1}Tu(t){this.Qu.el().classList.add(t)}Pu(t){this.Qu.el().classList.remove(t)}gn(){this.Eu.dispose(),this.Mu.gn()}constructor(t,i){this.ju=!1,this.Xu=[],this.Au=!1,this.Xa=function(t){return{get showing(){return t.tu},get items(){return t.Gu},set items(i){t.Gu=i},get url(){return t.zu},set url(i){t.zu=i},show(){t.ge()},hide(){t.be()}}}(this),this.Qu=t,this.Mu=new wc(this.Qu,this,t.contentEl(),i),this.Eu=new yc(t,this.Xa,{})}};ji((function(t){return class extends t{fa(){let t=this.Fu;return G(super.fa(),{get social(){return t.va}})}constructor(t,i,s){super(t,i,s),this.Fu=new Cc(this.fo,this.Iu)}}}));var Sc=Co.getComponent("Component"),jc=class extends Sc{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-upnext-container "+super.buildCSSClass()}};jc.prototype.h=fi({},jc.prototype.h,{children:[]}),Co.registerComponent("upNextContainer",jc);var Tc="theo-upnext-bar-",Mc=Co.getComponent("Component"),Ac=class extends Mc{get tu(){return this.ju}set tu(t){this.ju=t,this.Yu&&(this.Yu.tabIndex=t?0:-1)}get Ku(){return this.Zu}set Ku(t){this.Zu=t}ga(t){this.au(),this.tc(t)}tc(t){if(t&&t.link&&t.image){const i=h.createElement("div");Yt(i,Tc+"content"),i.onclick=()=>{this.ic.next()},i.onkeypress=t=>{13===t.which&&this.ic.next()};let s=h.createElement("div");if(s.style.backgroundImage='url("'+gi(t.image)+'")',Yt(s,Tc+"image"),i.appendChild(s),t.duration){let i=h.createElement("span");Yt(i,Tc+"duration"),i.innerHTML=""+t.duration,s.appendChild(i)}let e=h.createElement("div");Yt(e,Tc+"text");let n=h.createElement("div");if(Yt(n,Tc+"upnext"),l(n,this.localize("Up Next")),e.appendChild(n),t.title){let i=h.createElement("div");Yt(i,Tc+"title"),l(i,t.title),e.appendChild(i)}i.appendChild(e),this.Yu=i,this.sc=n,this.el().appendChild(this.Yu)}}au(){this.el().innerHTML="",this.Yu=void 0,this.sc=void 0}te(){this.sc&&l(this.sc,this.localize("Up Next"))}createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-upnext-bar "+super.buildCSSClass()}dispose(){this.qu.gn(),super.dispose()}constructor(t,i,s,e){super(t,s),this.Yu=void 0,this.sc=void 0,this.ic=i,this.qu=new dt(this.el(),e),this.ju=!1,this.Zu=10,this.on(t,"languagechange",this.te)}},Pc="theo-upnext-panel-",Ec=vu,Nc=Co.getComponent("Component"),Bc=class extends Nc{get tu(){return this.ju}set tu(t){this.ju=t}get ec(){return this.nc}set ec(t){this.nc=t}get rc(){return this.hc}set rc(t){this.hc=t}ga(t){this.au(),this.oc(t)}oc(t){if(t&&t.link&&t.image){let i=h.createElement("div");i.className=Pc+"content";let s=h.createElement("div");s.style.backgroundImage='url("'+gi(t.image)+'")',s.className=Pc+"image",i.appendChild(s);let e=h.createElement("div");e.className=Pc+"text";let n=h.createElement("div");if(n.className=Pc+"upnext",l(n,this.localize("Up Next")),e.appendChild(n),t.title){let i=h.createElement("div");i.className=Pc+"title",l(i,t.title),e.appendChild(i)}i.appendChild(e),this.ac=h.createElement("div"),this.ac.className=Pc+"autoplay",this.ac.innerHTML=pu;let r=this.ac.querySelector("svg");r.onclick=()=>{this.ic.next()},r.tabIndex=0,r.onkeypress=t=>{13===t.which&&this.ic.next()},this.uc=n,this.cc=this.ac.querySelector("."+Ec),i.appendChild(this.ac),this.el().appendChild(i)}}get lc(){return this.dc}set lc(t){this.dc=t,this.cc.style.strokeDashoffset=""+_.round(1e5*t)/1e5}au(){this.el().innerHTML="",this.uc=void 0,this.cc=void 0}te(){this.uc&&l(this.uc,this.localize("Up Next"))}createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-upnext-panel "+super.buildCSSClass()}dispose(){this.qu.gn(),super.dispose()}constructor(t,i,s,e){super(t,s),this.dc=0,this.ic=i,this.qu=new dt(this.el(),e),this.ju=!1,this.nc=10,this.hc=!0,this.on(t,"languagechange",this.te)}},Ic="theo-upnext-panel-showing",Fc="theo-upnext-bar-showing",Dc=2*_.PI*73,$c=class t{get va(){return this.Xa}get fc(){return this.vc}get mc(){return this.gc}get yc(){return this.bc}set yc(t){this.bc=t,this.Mu.ga(t),this.kc.ga(t),this.Qu.off("timeupdate",this.wc),this.Qu.off("ended",this._c),t&&(this.Qu.on("timeupdate",this.wc),this.Qu.on("ended",this._c))}xc(){this.Mu.ec?this.Cc=it(this.Mu.ec):0===this.Mu.ec?this.Cc=0:this.Cc=10,0!==this.Cc?(isFinite(this.Cc)&&(this.Sc=!0),this.Mu.tu=!0,this.Tu(Ic),this.Sc&&(this.Mu.lc=Dc-Dc/this.Cc,this.jc=v(this.Tc,1e3))):this.Mc()}Ac(){this.Mu.tu=!1,this.Pu(Ic),this.Sc&&(m(this.jc),this.Pc=1,this.Mu.lc=Dc)}Ec(){this.kc.tu=!0,this.Tu(Fc)}Nc(){this.kc.tu=!1,this.Pu(Fc)}Mc(){m(this.jc),this.yc&&(s.location.href=this.yc.link)}Tu(t){this.Qu.el().classList.add(t)}Pu(t){this.Qu.el().classList.remove(t)}Bc(t,i){const s=t>=i&&!(this.Ic&&this.Ic.Fc);this.kc.tu&&!s?this.Nc():!this.kc.tu&&s&&this.Ec()}Dc(t,i){this.Mu.tu&&t<i&&!this.Qu.ended()&&this.Ac()}static $c(t,i){let s=it(t);if(!S(s))return i-s;let e=(""+t).match(/^([1-9]?\d|100)%$/);if(e){return i*(1-x(e[1],10)/100)}}gn(){this.jc&&m(this.jc),this.Qu.getChild("upNextContainer").removeChild(this.Mu),this.Qu.getChild("upNextContainer").removeChild(this.kc),this.Mu.dispose(),this.kc.dispose()}constructor(i,s,e){this.bc=void 0,this.Cc=10,this.Pc=1,this.jc=void 0,this.Sc=!0,this.Tc=()=>{this.Pc!==this.Cc?(this.Mu.lc-=Dc/this.Cc,this.Pc+=1):this.Mc()},this._c=()=>{this.Mu.tu||this.xc()},this.wc=()=>{let i=this.Qu.currentTime(),s=this.Qu.duration(),e=s?t.$c(this.kc.Ku,s):void 0;void 0!==e&&this.Bc(i,e),this.Mu.rc&&this.Dc(i,s)},this.Xa=function(t){return{get source(){return t.yc},set source(i){t.yc=i},get bar(){return t.fc},get panel(){return t.mc},next(){t.Mc()}}}(this),this.kc=new Ac(i,this.Xa,{},s),this.Mu=new Bc(i,this.Xa,{},s),this.vc=function(t,i){return{get showing(){return i.tu},get offset(){return i.Ku},set offset(t){i.Ku=t},show(){t.Ec()},hide(){t.Nc()}}}(this,this.kc),this.gc=function(t,i){return{get showing(){return i.tu},get countdownDuration(){return i.ec},set countdownDuration(t){i.ec=t},get showUpNextPanel(){return i.rc},set showUpNextPanel(t){i.rc=t},show(){t.xc()},hide(){t.Ac()}}}(this,this.Mu),this.Qu=i,this.Ic=e,i.getChild("upNextContainer").addChild(this.kc,{}),i.getChild("upNextContainer").addChild(this.Mu,{})}};ji((function(t){return class extends t{fa(){let t=this.Rc;return G(super.fa(),{get upnext(){return t.va}})}gn(){this.Rc.gn(),super.gn()}constructor(t,i,s){super(t,i,s),this.Rc=new $c(this.fo,this.Iu,this.Oc)}}}));var Rc=Co.getComponent("Component"),Oc=class extends Rc{createEl(){let t=super.createEl("ul",{className:"theo-context-menu"}),i=h.createElement("li"),s=h.createElement("a"),e=h.createElement("div");s.className="theo-context-menu-a",i.appendChild(s),e.className="theo-context-menu-logo",e.innerHTML='<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"\n\t width="507.262px" height="399.16px" viewBox="0 0.1 507.262 399.16" enable-background="new 0 0.1 507.262 399.16"\n\t xml:space="preserve" class=\'theo-context-menu-logo-svg\'>\n\t<g transform="matrix(1.90897, 0, 0, 1.90897, 212.4, 144.6)">\n\t\t<path fill="#FFFFFF" d="M-38.416-53.802C-53.351-38.867-60.82-20.814-60.82,0.353c0,21.253,7.466,39.392,22.404,54.413\n\t\t\tc6.83,6.658,13.827,11.778,20.996,15.363c5.122,2.561,10.583,4.397,16.388,5.507v1.024h-78.481\n\t\t\tc-21.168,0-31.752-10.584-31.752-31.752v-88.724c0-21.252,10.584-31.879,31.752-31.879h79.377v0.896\n\t\t\tc-6.145,1.196-11.95,3.116-17.411,5.762C-24.632-65.538-31.586-60.46-38.416-53.802"/>\n\t</g>\n\t<g transform="matrix(0.535073, 0, 0, 0.535073, 242.35, 104.7)">\n\t\t<path fill="#FFFFFF" d="M188.354,104.104c-32.941,23.472-75.492,49.679-127.641,78.61c-50.275,28.254-94.358,50.44-132.254,66.572l-41.989,15.616\n\t\t\tc-2.645-11.348-5.122-28.17-7.426-50.44c-5.205-44.383-7.809-93.375-7.809-146.975c0-49.079,3.538-94.947,10.622-137.631\n\t\t\tl10.249-49.034l44.551,14.978C-24.762-88.838,17.06-67.03,62.124-38.777c47.705,29.871,88.638,58.294,122.773,85.266\n\t\t\tc17.061,13.571,29.351,24.028,36.862,31.367L188.354,104.104"/>\n\t</g>\n\t<g transform="matrix(1.91028, 0, 0, 1.91028, 327.15, 144.6)">\n\t\t<path fill="#FFFFFF" d="M94.286-43.816v88.723c0,21.168-10.583,31.751-31.751,31.751h-80.018v-1.025\n\t\t\tc14.683-2.816,27.527-9.77,38.537-20.867c14.936-15.024,22.405-33.16,22.405-54.413c0-21.168-7.467-39.22-22.405-54.156\n\t\t\tC9.871-64.985-3.188-71.939-18.123-74.671v-1.024h80.658C83.702-75.696,94.286-65.069,94.286-43.816"/>\n\t</g>\n</svg>\n',s.appendChild(e);let n=h.createElement("div");return n.className="theo-context-version",l(n,"Powered by THEOplayer 8.1.2"),s.appendChild(n),s.href="https://www.theoplayer.com/player-referral",s.target="Du",t.appendChild(i),t}Vc(t){const i=t;i.preventDefault(),this.show(),this.el().style.left="0",this.el().style.top="0";let s=this.player().contentEl(),e=s.getClientRects(),n=e.length>0?e[0]:void 0,r=i.clientX-s.getBoundingClientRect().left,h=C(getComputedStyle(this.el()).fontSize);B(this.el(),r,n,h);let o=i.clientY-s.getBoundingClientRect().top;F(this.el(),o,n,h),this.Uc()}zc(){this.hide(),this.clearTimeout(this.Lc)}Uc(){this.Lc=this.setTimeout(this.zc,4e3)}Hc(){this.clearTimeout(this.Lc)}dispose(){this.zc(),this.off(this.player(),"contextmenu",this.Vc),this.el().removeEventListener("mousedown",Vc,!0),this.off(h,"mousedown",this.zc),this.off("mouseout",this.Uc),this.off("mouseover",this.Hc),super.dispose()}constructor(t,i){super(t,i),this.Lc=0,this.on(this.player(),"contextmenu",this.Vc),this.el().addEventListener("mousedown",Vc,!0),this.on(h,"mousedown",this.zc),this.on("mouseout",this.Uc),this.on("mouseover",this.Hc),this.zc()}};function Vc(t){t.stopPropagation()}Mi((function(t){const i=new Oc(t.fo,{});t.fo.addChild(i),t.fo.on("dispose",(()=>{t.fo.removeChild(i),i.dispose()}))}));var Uc={Default:"","Monospaced Serif":vi.qc,"Proportional Serif":vi.Wc,"Monospaced Sans-Serif":vi.Gc,"Proportional Sans-Serif":vi.Xc},zc={White:"#ffffff",Yellow:"#ffff00",Green:"#00ff00",Cyan:"#00ffff",Blue:"#0000ff",Magenta:"#ff00ff",Red:"#ff0000",Black:"#000000"},Lc=[50,75,100,150,200];function Hc(t){return{label:t+"%",value:t}}function qc(t){return w.keys(t).map((i=>({label:i,value:t[i]})))}Lc.map((function(t){return{label:t+"%",value:t/100+"em"}}));var Wc=Lc.map((function(t){return{label:t+"%",value:t+"%"}})),Gc=[25,50,75,100].map(Hc),Xc=[0,25,50,75,100].map(Hc),Jc=qc(zc),Qc=qc(Uc),Yc=qc({None:"none","Drop Shadow":"dropshadow",Raised:"raised",Depressed:"depressed",Uniform:"uniform"}),Kc=100,Zc="#000000",tl="#FFFFFF",il="#000000",sl=class extends Ha{Jc(){let t=this.Fr.localize(this.Qc);l(this.Yc.subMenu.menuHeader.el(),t),this.Ir=h.createElement("span"),this.Ir.className="theo-settings-control-menu-item-title",l(this.Ir,t);let i=h.createElement("span");return i.className="theo-primary-color theo-settings-control-menu-item-value",Yt(this.Yc.el(),"theo-subtitle-options-menu-item"),this.Yc.el().appendChild(this.Ir),this.Yc.el().appendChild(i),i}Kc(t){const i=this.jr(t);i&&this.Zc(i)}tl(){return this.br}Ar(t){this.il(t.Tr)}Zc(t){for(let t of this.Cr.menuItems)t.selected(!1);t?(t.selected(!0),this.sl(t.Tr.label)):this.sl("Custom")}sl(t){this.nl=t,l(this.rl,this.Fr.localize(t)),this.Yc.parentMenu.re()}Mr(t){let i=super.Mr(t);return Yt(i.el(),"theo-subtitle-options-menu-item"),this.Nr(i),i}Nr(t){const i=this.Fr.localize(t.Tr.label);l(t.el(),i);const s=this.Fr.localize("Set "+this.Qc+" to ")+i;t.el().setAttribute("aria-label",s)}Re(){this.Fr.off("languagechange",this.te),super.Re()}constructor(t,i,s,e){super(t.subMenu),this.Yc=t,this.Fr=e,this.nl="",this.te=()=>{let t=this.Fr.localize(this.Qc);l(this.Yc.subMenu.menuHeader.el(),t),l(this.Ir,t),this.sl(this.nl);for(const t of this.Sr)this.Nr(t)},this.Qc=i,this.il=s.Ko,this.rl=this.Jc(),this.br=s.hl,this.Fr.on("languagechange",this.te)}},el=class t{static ol(t,i,s,e){if(void 0===t&&void 0===i)return;return Ci(void 0===t?s:t,void 0===i?e:i)}constructor(i){this.al=i,this.cl=t=>{this.al.fontFamily=t.value},this.ll=t=>{this.al.fontSize=t.value},this.dl=i=>{this.fl=i.value,this.al.fontColor=t.ol(this.vl,this.fl,tl,Kc)},this.pl=i=>{this.vl=i.value,this.al.fontColor=t.ol(this.vl,this.fl,tl,Kc)},this.ml=i=>{this.gl=i.value,this.al.backgroundColor=t.ol(this.gl,this.yl,Zc,Kc)},this.bl=i=>{this.yl=i.value,this.al.backgroundColor=t.ol(this.gl,this.yl,Zc,Kc)},this.kl=i=>{this.wl=i.value,this.al.windowColor=t.ol(this.wl,this._l,il,Kc)},this.xl=i=>{this._l=i.value,this.al.windowColor=t.ol(this.wl,this._l,il,Kc)},this.Cl=t=>{this.al.edgeStyle=t.value}}},nl=class{Sl(t,i){const s=this.jl(t,i.tl());s&&i.Kc(s)}jl(t,i){return M(i,(i=>i.value===t))}Tl(t,i,s){let e,n;if(void 0===t)e=this.jl(void 0,i.tl()),n=this.jl(void 0,s.tl());else if(t){let r=function(t){let i=_i(t);i||(i=_i(t.slice(0,t.length-1).replace("rgb","rgba")+",1)"));i||(i=mi(yi(t),1));if(!i){let s=t.charAt(0).toUpperCase()+t.toLowerCase().slice(1);i=mi(yi(zc[s]),1)}return i}(t);if(r){let t=ki(r),h=100*r.Ml;e=this.jl(t,i.tl()),n=this.jl(h,s.tl())}}e&&i.Kc(e),n&&s.Kc(n)}constructor(t,i){this.al=t,this.Al=i,this.Pl=()=>{let t=this.al.fontFamily;this.Sl(t,this.Al["Font family"]);let i=this.al.fontColor;this.Tl(i,this.Al["Font color"],this.Al["Font opacity"]);let s=this.al.fontSize;this.Sl(s,this.Al["Font size"]);let e=this.al.backgroundColor;this.Tl(e,this.Al["Background color"],this.Al["Background opacity"]);let n=this.al.windowColor;this.Tl(n,this.Al["Window color"],this.Al["Window opacity"]);let r=this.al.edgeStyle;this.Sl(r,this.Al["Character edge style"])},this.al.addEventListener("change",this.Pl),this.Pl()}};var rl=class extends Ha{El(){return{"Font family":{hl:hl(Qc),Ko:this.Nl.cl},"Font color":{hl:hl(Jc),Ko:this.Nl.pl},"Font opacity":{hl:hl(Gc),Ko:this.Nl.dl},"Font size":{hl:hl(Wc),Ko:this.Nl.ll},"Background color":{hl:hl(Jc),Ko:this.Nl.ml},"Background opacity":{hl:hl(Xc),Ko:this.Nl.bl},"Window color":{hl:hl(Jc),Ko:this.Nl.kl},"Window opacity":{hl:hl(Xc),Ko:this.Nl.xl},"Character edge style":{hl:hl(Yc),Ko:this.Nl.Cl}}}Bl(){this.Ir=h.createElement("span"),this.Ir.className="theo-settings-control-menu-item-title",this.Il=h.createElement("span"),this.Il.className="theo-primary-color theo-settings-control-menu-item-value",this.Lr.el().appendChild(this.Ir),this.Lr.el().appendChild(this.Il),this.te()}Mr(t){let i=this.Cr.addSubMenuItem();return i.Tr=t,this.Al[t]=new sl(i,t,this.Fl[t],this.Fr),i}Nr(t){}Ar(t){}Re(){this.Fr.off("languagechange",this.te),this.Dl.removeEventListener(["addtrack","removetrack"],this.$l),super.Re()}constructor(t,i,s,e){super(t.subMenu),this.Lr=t,this.Dl=i,this.Fr=e,this.Al={},this.$l=()=>{this.Dl.some((t=>pt(t.kind)))?this.Lr.show():this.Lr.hide()},this.te=()=>{l(this.Cr.menuHeader.el(),this.Fr.localize("Subtitle Options")),l(this.Ir,this.Fr.localize("Subtitle")),l(this.Il,this.Fr.localize("Options")),this.Lr.el().setAttribute("aria-label",this.Fr.localize("Open the subtitle options menu"))},this.Nl=new el(s),this.Fl=this.El(),this.br=w.keys(this.Fl),this.Bl(),this.Rl=new nl(s,this.Al),this.Fr.on("languagechange",this.te),this.Dl.addEventListener(["addtrack","removetrack"],this.$l),this.$l()}};function hl(t){let i=[{label:"Default",value:void 0}];for(let s of t)"Default"!==s.label&&i.push(s);return i}Mi((function(t){const i=t.fo.controlBar.getChild("SettingsButton").menu,s=i.addSubMenuItem({name:"TextTrackOptionsMenuItem"}),e=new rl(s,t.nt.va,t.Ol.va,t.fo);t.fo.on("dispose",(()=>{i.removeMenuItem(s),s.dispose(),e.Re(),i.dispose()}))}));var ol=Co.getComponent("Component"),al=class extends ol{buildCSSClass(){return"theo-ad-control-panel"}createEl(){const t=super.createEl();return t.className=this.buildCSSClass(),t}constructor(t,i){super(t,i),t.adControlBar=this}};al.prototype.h=fi({},ol.prototype.h,{children:[]}),Co.registerComponent("AdControlPanel",al);var ul=Co.getComponent("Component"),cl="theo-dai-countdown",ll=class extends ul{buildCSSClass(){return cl}createEl(t,i,s){const e=h.createElement("div");return e.className=cl,e}Vl(t,i){i.addEventListener("adbreakbegin",(()=>this.show())),i.addEventListener("adbreakend",(()=>this.hide())),t.addEventListener("timeupdate",this.te)}constructor(t,i,s){super(t,s),this.Qo=t,this.Xa=i,this.te=()=>{const t=this.Xa.ads;t.playing&&t.currentAdBreak&&t.currentAds.length&&l(this.contentEl(),function(t,i,s){const e=t.ads;let n="";const r=e.length;if(r>1){const t=e.indexOf(i)+1;n=s("Ad")+" "+t+"/"+r+". "}const h=_.ceil(t.maxRemainingDuration);return n+=s("The content will resume in {1} seconds.").replace("{1}",""+h),n}(t.currentAdBreak,t.currentAds[0],(t=>this.Qo.localize(t))))},this.yo=t.el(),this.Vl(i,i.ads),this.on(t,"languagechange",this.te)}};var dl=Co.getComponent("ClickableComponent"),fl=class extends dl{buildCSSClass(){return _t}createEl(t,i,s){return this.h.va.element.querySelector("."+_t)}emitTapEvents(){}te(){l(this.el(),this.localize("Learn more"))}constructor(t,i){super(t,i),l(this.el(),t.localize("Learn more")),this.Xa=i.va,this.yo=t.el(),this.on(t,"languagechange",this.te)}};Mi((function(t){if(t.va.ads&&t.Ul){const i=t.fo,s=new ll(i,t.va),e=new fl(i,{va:t.va});i.adControlBar.addChild(s),i.adControlBar.addChild(e)}}));var vl=Co.getComponent("Component"),pl=["addtrack","removetrack","change"],ml=class extends(Bo(vl)){createEl(){let t=super.createEl();return this.qualityLabel=Co.createEl("div",{className:"theo-quality-label-text"}),t.appendChild(this.qualityLabel),ri(this.qualityLabel),t}dispose(){this.qr&&(this.qr.removeEventListener("activequalitychanged",this.zl),this.qr=void 0),this.ws.videoTracks.removeEventListener(pl,this.nh),super.dispose()}constructor(t,i){super(t,i),this.qr=void 0,this.nh=()=>{const t=Va(this.ws.videoTracks);t!==this.qr&&(this.qr&&this.qr.removeEventListener("activequalitychanged",this.zl),this.qr=t,t&&t.addEventListener("activequalitychanged",this.zl),this.zl())},this.zl=()=>{const t=this.qr&&this.qr.activeQuality;if(!this.qualityLabel||!t)return;const i=t.label?t.label:t.height?t.height+"p":void 0;i&&(l(this.qualityLabel,i),this.addClass("theo-quality-label-show"),this.hideActiveQualityLabel())},this.hideActiveQualityLabel=()=>{this.resetTimeout(),this.startFadeOutID=this.setTimeout(this.fadeoutLabel,3750),this.removeLabelClassesID=this.setTimeout(this.hideLabel,4e3)},this.resetTimeout=()=>{this.startFadeOutID&&this.clearTimeout(this.startFadeOutID),this.removeLabelClassesID&&this.clearTimeout(this.removeLabelClassesID)},this.fadeoutLabel=()=>{this.addClass("theo-quality-label-fadeout")},this.hideLabel=()=>{this.removeClass("theo-quality-label-show"),this.removeClass("theo-quality-label-fadeout")},super.addClass("theo-quality-label"),this.ws.videoTracks&&(this.ws.videoTracks.addEventListener(pl,this.nh),this.nh())}};Co.registerComponent("activeQualityLabel",ml);var gl="theo-upcoming-ad-notification",yl=["adbreakbegin","adbreakend","adadded","adloaded","adbegin","adend"],bl=class extends(Bo(oa)){createEl(){const t=Co.createEl("div",{className:gl});return this.notificationText=Co.createEl("div",{className:gl+"text"}),t.appendChild(this.notificationText),t}Ll(){if(!this.ws.ads)return;const t=this.ws.ads.scheduledAdBreaks;let i,s=1/0;for(let e=0;e<t.length;e++){const n=t[e];let r=n.timeOffset;-1!==r&&r<s&&(s=r,i=n)}this.currentAdBreak=i,this.currentAdBreakValid=void 0!==i&&void 0!==i.ads&&i.ads.some((t=>"linear"===t.type))}Hl(){if(!this.ws.ads||this.ws.ads.playing||!this.currentAdBreak||!this.currentAdBreakValid||0===this.currentAdBreak.timeOffset)return void this.ql();const t=this.ws.currentTime;if(this.currentAdBreak.timeOffset>t+10)return void this.ql();const i=_.ceil(this.currentAdBreak.timeOffset-t);i<0?this.ql():this.Wl(i)}Wl(t){this.Gl!==t&&(l(this.notificationText,"Your video will be temporarily interrupted in 0:"+(t<10?"0"+t:t)),this.Gl=t,this.show())}ql(){this.Gl=NaN,this.hide()}dispose(){var t;this.ws.removeEventListener("timeupdate",this.handleTimeUpdate),null==(t=this.ws.ads)||t.removeEventListener(yl,this.handleAdEvent),this.currentAdBreak=void 0,super.dispose()}constructor(t,i){super(t,i),this.currentAdBreak=void 0,this.currentAdBreakValid=!1,this.Gl=NaN,this.handleTimeUpdate=()=>{this.Hl()},this.handleAdEvent=()=>{this.Ll(),this.Hl()},this.ws.ads&&(this.hide(),this.ws.addEventListener("timeupdate",this.handleTimeUpdate),this.ws.ads.addEventListener(yl,this.handleAdEvent))}};Co.registerComponent("upcomingAdNotificationText",bl);var kl=Co.getComponent("Component");Co.registerComponent("VerizonMediaAdBreakBar",class extends kl{createEl(){const t=h.createElement("div");return t.className="theoplayer-ad-overlay-component theo-ad-remaining-container",t}get Xl(){return this.h.adBreakProvider()}te(t,i){if(this.Xl&&this.Xl.endTime){const s=_.max(this.Xl.endTime-t,0);l(i,"Content will resume in "+_.ceil(s)+"s"),this.show()}else this.hide()}constructor(t,i){super(t,i),this.Jl=()=>{this.te(this.player().currentTime(),this.el())},this.on(t,"timeupdate",this.Jl)}});var wl=Co.getComponent("ClickableComponent");Co.registerComponent("VerizonMediaAdSkipButton",class extends wl{createEl(){const t=h.createElement("div");return t.className="theoplayer-ad-overlay-component theoplayer-ad-skip theoplayer-ad-skip-countdown",this.Ql=h.createElement("span"),t.appendChild(this.Ql),this.te(t,this.Ql),t}handleClick(){this.h.skipCallback()}te(t,i){this.Yl<=ot.Zl.Kl?(Zt(t,"theoplayer-ad-skip-countdown"),Yt(t,"theoplayer-ad-skip-button"),l(i,"Skip ads")):l(i,"Skip ads in "+_.ceil(this.Yl)+"s")}get Yl(){return this.h.adBreak.startTime+this.h.adBreak.skipOffset-this.player().currentTime()}constructor(t,i){super(t,i),this.Jl=()=>{this.te(this.el(),this.Ql)},this.on(t,"timeupdate",this.Jl)}});var _l=Co.getComponent("Component"),xl=class extends _l{buildCSSClass(){return"theo-verizonmedia-marker-bar"}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}constructor(t,i){super(t,i)}};Co.registerComponent("VerizonMediaAdBreakMarkerBar",class extends xl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-bar-adbreak"}});var Cl=Co.getComponent("Component"),Sl=class extends Cl{get startTime(){return this.h.startTime}get endTime(){return this.h.endTime}get seekable(){return this.player().seekable()}buildCSSClass(){return"theo-verizonmedia-marker"}createEl(t,i,s){const e=h.createElement("div");e.className=this.buildCSSClass();const n=this.seekable.start(0),r=this.seekable.end(this.seekable.length-1),o=_.max(this.startTime-n,0),a=void 0!==this.endTime?_.max(r-this.endTime,0):0,u=r-n;return e.style.left=o/u*100+"%",e.style.right=a/u*100+"%",e}constructor(t,i){super(t,i)}};Co.registerComponent("VerizonMediaAdBreakMarker",class extends Sl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-adbreak"}});Co.registerComponent("VerizonMediaAssetMarkerBar",class extends xl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-bar-asset"}});Co.registerComponent("VerizonMediaAssetMarker",class extends Sl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-asset"}});var jl=Co.getComponent("Component");Co.registerComponent("VerizonMediaContentNotificationBar",class extends jl{buildCSSClass(){const t="theo-verizonmedia-content-notification-bar",i=t+"-ios";return t+(At.Ga||At.td?" "+i:"")}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}constructor(t,i){super(t,i)}});var Tl,Ml=Co.getComponent("Component");function Al(t,i){return Boolean(t&&void 0===t.verizonMedia)||Boolean(t&&t.verizonMedia&&void 0===t.verizonMedia.ui)||Boolean(t&&t.verizonMedia&&t.verizonMedia.ui&&void 0===t.verizonMedia.ui[i])||Boolean(t&&t.verizonMedia&&t.verizonMedia.ui&&!0===t.verizonMedia.ui[i])}Co.registerComponent("VerizonMediaContentNotification",class extends Ml{get sd(){return this.h.asset}buildCSSClass(){return"theo-verizonmedia-content-notification"}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}ko(){const t=h.createElement("img");t.src=this.sd.posterUrl,t.className=this.buildCSSClass()+"-thumbnail",this.el().appendChild(t);const i=h.createElement("div");i.className=this.buildCSSClass()+"-description";const s=function(t){return"Next: "+t}(this.sd.description);l(i,s),this.el().appendChild(i),this.ed=h.createElement("div"),this.ed.className=this.buildCSSClass()+"-countdown",l(this.ed,this.nd),this.el().appendChild(this.ed)}get nd(){const t=_.min(10,this.rd);return"Starting in "+_.ceil(t)+" seconds"}get rd(){return _.max(0,this.sd.startTime-this.player().currentTime())}od(){const t=this.rd;t>10||t<=0?this.hide():(l(this.ed,this.nd),this.show())}constructor(t,i){super(t,i),this.ko(),this.on(t,"timeupdate",this.od),this.hide()}}),function(t){t.ad="VerizonMediaAdBreakBar",t.ud="VerizonMediaAdSkipButton",t.ld="VerizonMediaAdBreakMarkerBar",t.dd="VerizonMediaAdBreakMarker",t.fd="VerizonMediaAssetMarkerBar",t.vd="VerizonMediaAssetMarker",t.pd="VerizonMediaContentNotificationBar",t.md="VerizonMediaContentNotification"}(Tl||(Tl={})),ji((function(t){return class extends t{get gd(){return this.fo.controlBar.progressControl.seekBar}ga(t){this.yd=!1,this.va.removeEventListener("timeupdate",this.bd),this.fo.removeChild("VerizonMediaAdBreakBar"),this.fo.removeChild("VerizonMediaAdSkipButton"),this.gd.removeChild("VerizonMediaAdBreakMarkerBar"),this.gd.removeChild("VerizonMediaAssetMarkerBar"),this.fo.removeChild("VerizonMediaContentNotificationBar"),super.ga(t)}kd(){if(!function(t){return Al(t,"assetMarkers")}(this.wd)||!this.yd)return;const t=this.va.verizonMedia.assets.map((t=>({name:"VerizonMediaAssetMarker",startTime:t.startTime,endTime:t.endTime})));this.gd.removeChild("VerizonMediaAssetMarkerBar"),this.gd.addChild("VerizonMediaAssetMarkerBar",{children:t})}_d(){if(!function(t){return Al(t,"contentNotification")}(this.wd))return;const t=this.va.verizonMedia.assets.map((t=>({name:"VerizonMediaContentNotification",asset:t})));this.fo.removeChild("VerizonMediaContentNotificationBar"),this.fo.addChild("VerizonMediaContentNotificationBar",{children:t})}gn(){this.va.removeEventListener("timeupdate",this.bd),this.va.verizonMedia.ads.adBreaks.removeEventListener("addadbreak",this.xd),this.va.verizonMedia.ads.adBreaks.removeEventListener("removeadbreak",this.Cd),this.va.verizonMedia.assets.removeEventListener("addasset",this.Sd),this.va.verizonMedia.assets.removeEventListener("removeasset",this.Sd),this.va.removeEventListener("loadeddata",this.jd),super.gn()}constructor(t,i,s){super(t,i,s),this.yd=!1,this.jd=()=>{this.yd=!0,isFinite(this.Td())||this.va.addEventListener("timeupdate",this.bd),this.bd(),this.kd(),this._d()},this.xd=t=>{t.adBreak.addEventListener("adbreakbegin",this.Md),t.adBreak.addEventListener("adbreakend",this.Pd),this.bd()},this.Cd=t=>{t.adBreak.removeEventListener("adbreakbegin",this.Md),t.adBreak.removeEventListener("adbreakend",this.Pd),this.bd()},this.bd=()=>{if(!function(t){return Al(t,"adBreakMarkers")}(this.wd)||!this.yd)return;const t=this.va.verizonMedia.ads.adBreaks.map((t=>({name:"VerizonMediaAdBreakMarker",startTime:t.startTime,endTime:t.endTime})));this.gd.removeChild("VerizonMediaAdBreakMarkerBar"),this.gd.addChild("VerizonMediaAdBreakMarkerBar",{children:t})},this.Md=()=>{if(function(t){return Al(t,"adNotification")}(this.wd)){const t=this.va.verizonMedia.ads.currentAdBreak;this.fo.addChild("VerizonMediaAdBreakBar",{adBreakProvider:this.Ed}),-1!==t.skipOffset&&this.fo.addChild("VerizonMediaAdSkipButton",{adBreak:t,skipCallback:this.va.verizonMedia.ads.skip})}},this.Ed=()=>this.va.verizonMedia.ads.currentAdBreak,this.Pd=()=>{this.fo.removeChild("VerizonMediaAdBreakBar"),this.fo.removeChild("VerizonMediaAdSkipButton")},this.Sd=()=>{this.kd(),this._d()},this.va.verizonMedia.ads.adBreaks.addEventListener("addadbreak",this.xd),this.va.verizonMedia.ads.adBreaks.addEventListener("removeadbreak",this.Cd),this.va.verizonMedia.assets.addEventListener("addasset",this.Sd),this.va.verizonMedia.assets.addEventListener("removeasset",this.Sd),this.va.addEventListener("loadeddata",this.jd)}}}));export{W as ChromelessPlayer,U as ErrorCategory,O as ErrorCode,Du as Player,kt as cache,mt as cast,Q as features,tt as playerSuiteVersion,st as players,nt as registerContentProtectionIntegration,X as utils,K as version,Co as videojs};
|
|
40
|
+
var a="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:void 0!==s?s:"undefined"!=typeof global?global:this,s=a.window,h=a.document,u=(a.location,a.navigator,a.setTimeout),c=a.clearTimeout,v=a.setInterval,m=a.clearInterval,g=a.Error,b=a.TypeError,k=a.SyntaxError,w=a.Object,_=a.Math,x=a.parseInt,C=a.parseFloat,S=a.isNaN,j=a.Uint8Array;a.Worker,a.WorkerGlobalScope,a.XMLHttpRequest;import{$ as T,A as M,Aa as A,B as P,Ba as E,C as N,Ca as B,D as I,Da as F,E as D,Ea as l,F as $,Fa as R,G as O,Ga as V,H as U,Ha as z,I as L,Ia as H,J as q,Ja as W,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 dt,U as ft,Ua as vt,V as pt,Va as mt,W as gt,Wa as yt,X as bt,Xa as kt,Y as wt,Ya as _t,Z as xt,Za as Ct,_ as St,_a as jt,a as Tt,aa as Mt,b as At,ba as Pt,c as Et,ca as Nt,d as Bt,da as It,e as Ft,ea as Dt,f as $t,fa as Rt,g as Ot,ga as Vt,h as Ut,ha as zt,i as Lt,ia as Ht,j as qt,ja as Wt,k as Gt,ka as Xt,l as Jt,la as Qt,m as Yt,ma as Kt,n as Zt,na as ti,o as ii,oa as si,p as ei,pa as ni,q as ri,qa as hi,r as oi,ra as ai,s as ui,sa as ci,t as li,ta as di,u as fi,ua as vi,v as pi,va as mi,w as gi,wa as yi,x as bi,xa as ki,y as wi,ya as _i,z as xi,za as Ci}from"./THEOplayer.common.esm.js";var Si=[];function ji(t){Si.push(t)}var Ti=[];function Mi(t){Ti.push(t)}var t=void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},Ai=void 0!==h?h:{createElement:function(){}};function Pi(t,i){return i||(i=t.slice(0)),t.raw=i,t}var Ei=1;function Ni(){return Ei++}var Bi,Ii=w.prototype.toString,Fi=function(t){return Ri(t)?w.keys(t):[]};function Di(t,i){Fi(t).forEach((function(s){return i(t[s],s)}))}function $i(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 w.assign?w.assign.apply(w,[t].concat(s)):(s.forEach((function(i){i&&Di(i,(function(i,s){t[s]=i}))})),t)}function Ri(t){return!!t&&"object"==typeof t}function Oi(t){return Ri(t)&&"[object Object]"===Ii.call(t)&&t.constructor===w}var Vi=function(i,s,e){void 0===e&&(e=!!Os&&Os<11),"log"!==i&&s.unshift(i.toUpperCase()+":"),Bi.history.push(s),s.unshift("VIDEOJS:");var n=t.console&&t.console[i];n&&(e&&(s=s.map((function(t){if(Ri(t)||Array.isArray(t))try{return JSON.stringify(t)}catch(i){return String(t)}return String(t)})).join(" ")),n.apply?n[Array.isArray(s)?"apply":"call"](t.console,s):n(s))};(Bi=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];Vi("log",i)}).history=[],Bi.error=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Vi("error",i)},Bi.warn=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Vi("warn",i)};var Ui=Bi,zi="undefined"!=typeof globalThis?globalThis:void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Li(t){return t.replace(/\n\r?\s*/g,"")}var Hi,qi=function(t){for(var i="",s=0;s<arguments.length;s++)i+=Li(t[s])+(arguments[s+1]||"");return i};function Wi(t){return"string"==typeof t&&/\S/.test(t)}function Gi(t){if(/\s/.test(t))throw new g("class has illegal whitespace characters")}function Xi(){return Ai===t.document&&void 0!==Ai.createElement}function Ji(t){return Ri(t)&&1===t.nodeType}function Qi(t){return function(i,s){if(!Wi(i))return Ai[t](null);Wi(s)&&(s=Ai.querySelector(s));var e=Ji(s)?s:Ai;return e[t]&&e[t](i)}}function Yi(t,i,s,e){void 0===t&&(t="div"),void 0===i&&(i={}),void 0===s&&(s={});var n=Ai.createElement(t);return w.getOwnPropertyNames(i).forEach((function(t){var s=i[t];-1!==t.indexOf("aria-")||"role"===t||"type"===t?(Ui.warn(qi(Hi||(Hi=Pi(["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?Ki(n,s):n[t]=s})),w.getOwnPropertyNames(s).forEach((function(t){n.setAttribute(t,s[t])})),e&&gs(n,e),n}function Ki(t,i){return void 0===t.textContent?t.innerText=i:t.textContent=i,t}function Zi(t,i){i.firstChild?i.insertBefore(t,i.firstChild):i.appendChild(t)}var ts={},is="vdata"+(new Date).getTime();function ss(t){var i=t[is];return i||(i=t[is]=Ni()),ts[i]||(ts[i]={}),ts[i]}function es(t){var i=t[is];return!!i&&!!w.getOwnPropertyNames(ts[i]).length}function ns(t){var i=t[is];if(i){delete ts[i];try{delete t[is]}catch(i){t.removeAttribute?t.removeAttribute(is):t[is]=null}}}function rs(t,i){return Gi(i),t.classList?t.classList.contains(i):function(t){return new RegExp("(^|\\s)"+t+"($|\\s)")}(i).test(t.className)}function hs(t,i){return t.classList?t.classList.add(i):rs(t,i)||(t.className=(t.className+" "+i).trim()),t}function os(t,i){return t.classList?t.classList.remove(i):(Gi(i),t.className=t.className.split(/\s+/).filter((function(t){return t!==i})).join(" ")),t}function as(t,i,s){var e=rs(t,i);if("function"==typeof s&&(s=s(t,i)),"boolean"!=typeof s&&(s=!e),s!==e)return s?hs(t,i):os(t,i),t}function us(t,i){w.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 ls(t,i,s){t.setAttribute(i,s)}function ds(t,i){t.removeAttribute(i)}function fs(i){var s;if(i.getBoundingClientRect&&i.parentNode&&(s=i.getBoundingClientRect()),!s)return{left:0,top:0};var e=Ai.documentElement,n=Ai.body,r=e.clientLeft||n.clientLeft||0,h=t.pageXOffset||n.scrollLeft,o=s.left+h-r,a=e.clientTop||n.clientTop||0,u=t.pageYOffset||n.scrollTop,c=s.top+u-a;return{left:_.round(o),top:_.round(c)}}function vs(t,i){var s={},e=fs(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=_.max(0,_.min(1,(h-a+r)/r)),s.x=_.max(0,_.min(1,(u-o)/n)),s}function ps(t){return Ri(t)&&3===t.nodeType}function ms(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function gs(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()),Ji(t)||ps(t)?t:"string"==typeof t&&/\S/.test(t)?Ai.createTextNode(t):void 0})).filter((function(t){return t}))}(i).forEach((function(i){return t.appendChild(i)})),t}function ys(t,i){return gs(ms(t),i)}var bs,ks=Qi("querySelector"),ws=Qi("querySelectorAll"),_s=t.navigator&&t.navigator.userAgent||"",xs=/AppleWebKit\/([\d.]+)/i.exec(_s),Cs=xs?C(xs.pop()):null,Ss=/iPad/i.test(_s),js=/iPhone/i.test(_s)&&!Ss,Ts=/iPod/i.test(_s),Ms=js||Ss||Ts,As=(bs=_s.match(/OS (\d+)_/i))&&bs[1]?bs[1]:null,Ps=/Android/i.test(_s),Es=function(){var t=_s.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!t)return null;var i=t[1]&&C(t[1]),s=t[2]&&C(t[2]);return i&&s?C(t[1]+"."+t[2]):i||null}(),Ns=Ps&&/webkit/i.test(_s)&&Es<2.3,Bs=Ps&&Es<5&&Cs<537,Is=/Firefox/i.test(_s),Fs=/Edge/i.test(_s),Ds=!Fs&&/Chrome/i.test(_s),$s=function(){var t=_s.match(/Chrome\/(\d+)/);return t&&t[1]?C(t[1]):null}(),Rs=/MSIE\s8\.0/.test(_s),Os=function(){var t=/MSIE\s(\d+)\.\d/.exec(_s),i=t&&C(t[1]);return!i&&/Trident\/7.0/i.test(_s)&&/rv:11.0/.test(_s)&&(i=11),i}(),Vs=/Safari/i.test(_s)&&!Ds&&!Ps&&!Fs,Us=Vs||Ms,zs=Xi()&&("ontouchstart"in t||t.DocumentTouch&&t.document instanceof t.DocumentTouch),Ls=Xi()&&"backgroundSize"in t.document.createElement("video").style,Hs=w.freeze({__proto__:null,IS_IPAD:Ss,IS_IPHONE:js,IS_IPOD:Ts,IS_IOS:Ms,IOS_VERSION:As,IS_ANDROID:Ps,ANDROID_VERSION:Es,IS_OLD_ANDROID:Ns,IS_NATIVE_ANDROID:Bs,IS_FIREFOX:Is,IS_EDGE:Fs,IS_CHROME:Ds,CHROME_VERSION:$s,IS_IE8:Rs,IE_VERSION:Os,IS_SAFARI:Vs,IS_ANY_SAFARI:Us,TOUCH_ENABLED:zs,BACKGROUND_SIZE_SUPPORTED:Ls});function qs(t,i){var s=ss(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)),w.getOwnPropertyNames(s.handlers).length<=0&&(delete s.handlers,delete s.dispatcher,delete s.disabled),0===w.getOwnPropertyNames(s).length&&ns(t)}function Ws(t,i,s,e){s.forEach((function(s){t(i,s,e)}))}function Gs(i){function s(){return!0}function e(){return!1}if(!i||!i.isPropagationStopped||!i.isImmediatePropagationStopped){var n=i||t.event;for(var r in i={},n)"layerX"!==r&&"layerY"!==r&&"keyLocation"!==r&&"webkitMovementX"!==r&&"webkitMovementY"!==r&&"path"!==r&&("returnValue"===r&&n.preventDefault||(i[r]=n[r]));if(i.target||(i.target=i.srcElement||Ai),i.relatedTarget||(i.relatedTarget=i.fromElement===i.target?i.toElement:i.fromElement),i.preventDefault=function(){n.preventDefault&&n.preventDefault(),i.returnValue=!1,n.returnValue=!1,i.defaultPrevented=!0},i.defaultPrevented=!1,i.stopPropagation=function(){n.stopPropagation&&n.stopPropagation(),i.cancelBubble=!0,n.cancelBubble=!0,i.isPropagationStopped=s},i.isPropagationStopped=e,i.stopImmediatePropagation=function(){n.stopImmediatePropagation&&n.stopImmediatePropagation(),i.isImmediatePropagationStopped=s,i.stopPropagation()},i.isImmediatePropagationStopped=e,null!==i.clientX&&void 0!==i.clientX){var h=Ai.documentElement,o=Ai.body;i.pageX=i.clientX+(h&&h.scrollLeft||o&&o.scrollLeft||0)-(h&&h.clientLeft||o&&o.clientLeft||0),i.pageY=i.clientY+(h&&h.scrollTop||o&&o.scrollTop||0)-(h&&h.clientTop||o&&o.clientTop||0)}i.which=i.charCode||i.keyCode,null!==i.button&&void 0!==i.button&&(i.button=1&i.button?0:4&i.button?1:2&i.button?2:0)}return i}var Xs=!1;!function(){try{var i=w.defineProperty({},"passive",{get:function(){Xs=!0}});t.addEventListener("test",null,i)}catch(t){}}();var Js=["touchstart","touchmove"];function Qs(t,i,s){if(Array.isArray(i))return Ws(Qs,t,i,s);var e=ss(t);if(e.handlers||(e.handlers={}),e.handlers[i]||(e.handlers[i]=[]),s.guid||(s.guid=Ni()),e.handlers[i].push(s),e.dispatcher||(e.disabled=!1,e.dispatcher=function(i,s){if(!e.disabled){i=Gs(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){Ui.error(t)}}}),1===e.handlers[i].length)if(t.addEventListener){var n=!1;Xs&&Js.indexOf(i)>-1&&(n={passive:!0}),t.addEventListener(i,e.dispatcher,n)}else t.attachEvent&&t.attachEvent("on"+i,e.dispatcher)}function Ys(t,i,s){if(es(t)){var e=ss(t);if(e.handlers){if(Array.isArray(i))return Ws(Ys,t,i,s);var n=function(i){e.handlers[i]=[],qs(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);qs(t,i)}else n(i)}else for(var o in e.handlers)n(o)}}}function Ks(t,i,s){var e=es(t)?ss(t):{},n=t.parentNode||t.ownerDocument;if("string"==typeof i&&(i={type:i,target:t}),i=Gs(i),e.dispatcher&&e.dispatcher.call(t,i,s),n&&!i.isPropagationStopped()&&!0===i.bubbles)Ks.call(null,n,i,s);else if(!n&&!i.defaultPrevented){var r=ss(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 Zs(t,i,s){if(Array.isArray(i))return Ws(Zs,t,i,s);var e=function e(){Ys(t,i,e),s.apply(this,arguments)};e.guid=s.guid=s.guid||Ni(),Qs(t,i,e)}var te,ie=!1,se=function(){if(Xi()){var t=Ai.getElementsByTagName("video"),i=Ai.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){ee(1);break}void 0===u.player&&null!==u.getAttribute("data-setup")&&te(u)}else ie||ee(1)}};function ee(i,s){s&&(te=s),t.setTimeout(se,i)}Xi()&&"complete"===Ai.readyState?ie=!0:Zs(t,"load",(function(){ie=!0}));var ne=function(t){var i=Ai.createElement("style");return i.className=t,i},re=function(t,i){t.styleSheet?t.styleSheet.cssText=i:t.textContent=i},he=function(t,i,s){i.guid||(i.guid=Ni());var e=function(){return i.apply(t,arguments)};return e.guid=s?s+"_"+i.guid:i.guid,e};function oe(t){return"string"!=typeof t?t:t.charAt(0).toUpperCase()+t.slice(1)}function ae(){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&&Di(i,(function(i,s){Oi(i)?(Oi(t[s])||(t[s]={}),t[s]=ae(t[s],i)):t[s]=i}))})),t}var i=function(){function i(t,i,s){if(!t&&this.play?this.t=t=this:this.t=t,this.h=ae({},this.h),i=this.h=ae(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"+Ni()}this.l=i.name||null,i.el?this.v=i.el:!1!==i.createEl&&(this.v=this.createEl()),this.m=[],this.k={},this.C={},!1!==i.initChildren&&this.initChildren(),this.ready(s),!1!==i.reportTouchActivity&&this.enableTouchActivity()}var s=i.prototype;return s.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.C=null,this.off(),this.v.parentNode&&this.v.parentNode.removeChild(this.v),ns(this.v),this.v=null},s.player=function(){return this.t},s.options=function(t){return Ui.warn("this.options() has been deprecated and will be moved to the constructor in 6.0"),t?(this.h=ae(this.h,t),this.h):this.h},s.el=function(){return this.v},s.createEl=function(t,i,s){return Yi(t,i,s)},s.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},s.contentEl=function(){return this.S||this.v},s.id=function(){return this.o},s.name=function(){return this.l},s.children=function(){return this.m},s.getChildById=function(t){return this.k[t]},s.getChild=function(t){if(t)return t=oe(t),this.C[t]},s.addChild=function(t,s,e){var n,r;if(void 0===s&&(s={}),void 0===e&&(e=this.m.length),"string"==typeof t){r=oe(t),s||(s={}),!0===s&&(Ui.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=i.getComponent(h);if(!o)throw new g("Component "+h+" does not exist");if("function"!=typeof o)return null;n=new o(this.t||this,s)}else n=t;if(this.m.splice(e,0,n),"function"==typeof n.id&&(this.k[n.id()]=n),(r=r||n.name&&oe(n.name()))&&(this.C[r]=n),"function"==typeof n.el&&n.el()){var a=this.contentEl().children[e]||null;this.contentEl().insertBefore(n.el(),a)}return n},s.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.C[t.name()]=null;var e=t.el();e&&e.parentNode===this.contentEl()&&this.contentEl().removeChild(t.el())}}},s.initChildren=function(){var t=this,s=this.h.children;if(s){var e,n=this.h,r=i.getComponent("Tech");(e=Array.isArray(s)?s:w.keys(s)).concat(w.keys(this.h).filter((function(t){return!e.some((function(i){return"string"==typeof i?t===i:t===i.name}))}))).map((function(i){var e,n;return"string"==typeof i?n=s[e=i]||t.h[e]||{}:(e=i.name,n=i),{name:e,opts:n}})).filter((function(t){var s=i.getComponent(t.opts.componentClass||oe(t.name));return s&&!r.isTech(s)})).forEach((function(i){var s=i.name,e=i.opts;if(void 0!==n[s]&&(e=n[s]),!1!==e){!0===e&&(e={}),e.playerOptions=t.h.playerOptions;var r=t.addChild(s,e);r&&(t[s]=r)}}))}},s.buildCSSClass=function(){return""},s.on=function(t,i,s){var e=this;if("string"==typeof t||Array.isArray(t))Qs(this.v,t,he(this,i));else{var n=t,r=i,h=he(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?(Qs(n,r,h),Qs(n,"dispose",a)):"function"==typeof t.on&&(n.on(r,h),n.on("dispose",a))}return this},s.off=function(t,i,s){if(!t||"string"==typeof t||Array.isArray(t))Ys(this.v,t,i);else{var e=t,n=i,r=he(this,s);this.off("dispose",r),t.nodeName?(Ys(e,n,r),Ys(e,"dispose",r)):(e.off(n,r),e.off("dispose",r))}return this},s.one=function(t,i,s){var e=arguments,n=this;if("string"==typeof t||Array.isArray(t))Zs(this.v,t,he(this,i));else{var r=t,h=i,o=he(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},s.trigger=function(t,i){return Ks(this.v,t,i),this},s.ready=function(t,i){return void 0===i&&(i=!1),t&&(this.j?i?t.call(this):this.setTimeout(t,1):(this.T=this.T||[],this.T.push(t))),this},s.triggerReady=function(){this.j=!0,this.setTimeout((function(){var t=this.T;this.T=[],t&&t.length>0&&t.forEach((function(t){t.call(this)}),this),this.trigger("ready")}),1)},s.$=function(t,i){return ks(t,i||this.contentEl())},s.$$=function(t,i){return ws(t,i||this.contentEl())},s.hasClass=function(t){return rs(this.v,t)},s.addClass=function(t){return hs(this.v,t),this},s.removeClass=function(t){return os(this.v,t),this},s.toggleClass=function(t,i){return as(this.v,t,i),this},s.show=function(){return this.removeClass("vjs-hidden"),this},s.hide=function(){return this.addClass("vjs-hidden"),this},s.lockShowing=function(){return this.addClass("vjs-lock-showing"),this},s.unlockShowing=function(){return this.removeClass("vjs-lock-showing"),this},s.getAttribute=function(t){return function(t,i){return t.getAttribute(i)}(this.v,t)},s.setAttribute=function(t,i){return ls(this.v,t,i),this},s.removeAttribute=function(t){return ds(this.v,t),this},s.width=function(t,i){return this.dimension("width",t,i)},s.height=function(t,i){return this.dimension("height",t,i)},s.dimensions=function(t,i){return this.width(t,!0).height(i)},s.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 x(-1!==n?e.slice(0,n):this.v["offset"+oe(t)],10)},s.currentDimension=function(i){var s=0;if("width"!==i&&"height"!==i)throw new g("currentDimension only accepts width or height value");if("function"==typeof t.getComputedStyle){var e=t.getComputedStyle(this.v);s=e.getPropertyValue(i)||e[i]}if(0===(s=C(s))){var n="offset"+oe(i);s=this.v[n]}return s},s.currentDimensions=function(){return{width:this.currentDimension("width"),height:this.currentDimension("height")}},s.currentWidth=function(){return this.currentDimension("width")},s.currentHeight=function(){return this.currentDimension("height")},s.focus=function(){this.v.focus()},s.blur=function(){this.v.blur()},s.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;_.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")))}))},s.enableTouchActivity=function(){if(this.player()&&this.player().reportUserActivity){var t,i=he(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)}},s.setTimeout=function(i,s){i=he(this,i);var e=t.setTimeout(i,s),n=function(){this.clearTimeout(e)};return n.guid="vjs-timeout-"+e,this.on("dispose",n),e},s.clearTimeout=function(i){t.clearTimeout(i);var s=function(){};return s.guid="vjs-timeout-"+i,this.off("dispose",s),i},s.setInterval=function(i,s){i=he(this,i);var e=t.setInterval(i,s),n=function(){this.clearInterval(e)};return n.guid="vjs-interval-"+e,this.on("dispose",n),e},s.clearInterval=function(i){t.clearInterval(i);var s=function(){};return s.guid="vjs-interval-"+i,this.off("dispose",s),i},i.registerComponent=function(t,s){if(t){if(t=oe(t),i.M||(i.M={}),"Player"===t&&i.M[t]){var e=i.M[t];if(e.players&&w.keys(e.players).length>0&&w.keys(e.players).map((function(t){return e.players[t]})).every(Boolean))throw new g("Can not register Player component after player has been created")}return i.M[t]=s,s}},i.getComponent=function(s){if(s)return s=oe(s),i.M&&i.M[s]?i.M[s]:t&&t.videojs&&t.videojs[s]?(Ui.warn("The "+s+" component was added to the videojs object when it should be registered using videojs.registerComponent(name, component)"),t.videojs[s]):void 0},i.extend=function(t){t=t||{},Ui.warn("Component.extend({}) has been deprecated, use videojs.extend(Component, {}) instead");var s=t.init||t.init||this.prototype.init||this.prototype.init||function(){},e=function(){s.apply(this,arguments)};for(var n in(e.prototype=w.create(this.prototype)).constructor=e,e.extend=i.extend,t)t.hasOwnProperty(n)&&(e.prototype[n]=t[n]);return e},i}();i.registerComponent("Component",i);var ue=function(){};function ce(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function le(t,i){return(le=w.setPrototypeOf?w.setPrototypeOf.bind():function(t,i){return t.__proto__=i,t})(t,i)}function de(t,i){t.prototype=w.create(i.prototype),t.prototype.constructor=t,le(t,i)}function fe(t,i,s,e){return void 0===e&&(Ui.warn("DEPRECATED: Function '"+t+"' on 'TimeRanges' called without an index argument."),e=0),function(t,i,s){if(i<0||i>s)throw new g("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 ve(t){return void 0===t||0===t.length?{length:0,start:function(){throw new g("This TimeRanges object is empty")},end:function(){throw new g("This TimeRanges object is empty")}}:{length:t.length,start:fe.bind(null,"start",0,t),end:fe.bind(null,"end",1,t)}}function pe(t,i){return Array.isArray(t)?ve(t):void 0===t||void 0===i?ve():ve([[t,i]])}function me(t,i){var s,e,n=0;if(!i)return 0;t&&t.length||(t=pe(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}ue.prototype.A={},ue.prototype.on=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},Qs(this,t,i),this.addEventListener=s},ue.prototype.addEventListener=ue.prototype.on,ue.prototype.off=function(t,i){Ys(this,t,i)},ue.prototype.removeEventListener=ue.prototype.off,ue.prototype.one=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},Zs(this,t,i),this.addEventListener=s},ue.prototype.trigger=function(t){var i=t.type||t;"string"==typeof t&&(t={type:i}),t=Gs(t),this.A[i]&&this["on"+i]&&this["on"+i](t),Ks(this,t)},ue.prototype.dispatchEvent=ue.prototype.trigger;var ge,ye,be,ke,we={prefixed:!0},_e=[["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"]],xe=_e[0];for(ye=0;ye<_e.length;ye++)if(_e[ye][1]in Ai){ge=_e[ye];break}if(ge){for(be=0;be<ge.length;be++)we[xe[be]]=ge[be];we.prefixed=ge[0]!==xe[0]}function Ce(t){if(t instanceof Ce)return t;"number"==typeof t?this.code=t:"string"==typeof t?this.message=t:Ri(t)&&("number"==typeof t.code&&(this.code=t.code),$i(this,t)),this.message||(this.message=Ce.defaultMessages[this.code]||"")}for(Ce.prototype.code=0,Ce.prototype.message="",Ce.prototype.status=null,Ce.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],Ce.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."},ke=0;ke<Ce.errorTypes.length;ke++)Ce[Ce.errorTypes[ke]]=ke,Ce.prototype[Ce.errorTypes[ke]]=ke;var Se=function(t,i){var s,e=null;try{s=JSON.parse(t,i)}catch(t){e=t}return[e,s]};var je=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}}))})},Te=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=je(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(je))},Me=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()},Ae="vjs-modal-dialog",Pe=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).P=e.N=e.B=!1,e.closeable(!e.h.uncloseable),e.content(e.h.content),e.S=Yi("div",{className:Ae+"-content"},{role:"document"}),e.I=Yi("p",{className:Ae+"-description vjs-offscreen",id:e.el().getAttribute("aria-describedby")}),Ki(e.I,e.description()),e.v.appendChild(e.I),e.v.appendChild(e.S),e.on(i,"languagechange",e.handleLanguagechange),e}de(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 Ae+" 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.P){var t=this.player();this.trigger("beforemodalopen"),this.P=!0,(this.h.fillAlways||!this.N&&!this.B)&&this.fill(),this.D=!t.paused(),this.h.pauseOnOpen&&this.D&&t.pause(),this.closeable()&&this.on(this.v.ownerDocument,"keydown",he(this,this.handleKeyPress)),t.controls(!1),this.show(),this.el().setAttribute("aria-hidden","false"),this.trigger("modalopen"),this.N=!0}return this},s.opened=function(t){return"boolean"==typeof t&&this[t?"open":"close"](),this.P},s.close=function(){if(this.P){var t=this.player();this.trigger("beforemodalclose"),this.P=!1,this.D&&this.h.pauseOnOpen&&t.play(),this.closeable()&&this.off(this.v.ownerDocument,"keydown",he(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.B=!0,s.removeChild(i),this.empty(),ys(i,t),this.trigger("modalfill"),e?s.insertBefore(i,e):s.appendChild(i),this},s.empty=function(){return this.trigger("beforemodalempty"),ms(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()),Ki(this.I,this.description()),this.opened()?this.fill():(this.N||this.B)&&(this.N=!1,this.B=!1,this.empty())},i}(i);Pe.prototype.h={pauseOnOpen:!0,temporary:!0},i.registerComponent("ModalDialog",Pe);var Ee=function(){function t(i){var s=this;if(Rs)for(var e in s=Ai.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);if(t.prototype.V.call(s,i),w.defineProperty(s,"length",{get:function(){return this.U}}),Rs)return s}var i=t.prototype;return i.V=function(t){var i=this.length||0,s=0,e=t.length;this.L=t,this.U=t.length;var n=function(t){""+t in this||w.defineProperty(this,""+t,{get:function(){return this.L[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}(),Ne={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},Be={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},Ie={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},Fe={disabled:"disabled",hidden:"hidden",showing:"showing"},De=function(t){function i(s){var e;void 0===s&&(s={});var n=ce(e=t.call(this)||this);if(Rs)for(var r in n=Ai.createElement("custom"),i.prototype)"constructor"!==r&&(n[r]=i.prototype[r]);var h={id:s.id||["vjs_track",Ni()].join("_"),kind:s.kind||"",label:s.label||"",language:s.language||""},o=function(t){w.defineProperty(n,t,{get:function(){return h[t]},set:function(){}})};for(var a in h)o(a);return n||ce(e)}return de(i,t),i}(ue),$e=function(t){var i=["protocol","hostname","port","pathname","search","hash","host"],s=Ai.createElement("a");s.href=t;var e,n=""===s.host&&"file:"!==s.protocol;n&&((e=Ai.createElement("div")).innerHTML='<a href="'+t+'"></a>',s=e.firstChild,e.setAttribute("style","display:none; position:absolute;"),Ai.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&&Ai.body.removeChild(e),r},Re=function(i){var s=t.location,e=$e(i);return(":"===e.protocol?s.protocol:e.protocol)+e.host!==s.protocol+s.host},Oe={exports:{}};void 0!==s?Oe.exports=s:void 0!==zi?Oe.exports=zi:"undefined"!=typeof self?Oe.exports=self:Oe.exports={};var Ve=function(t){var i=Ue.call(t);return"[object Function]"===i||"function"==typeof t&&"[object RegExp]"!==i||void 0!==s&&(t===s.setTimeout||t===s.alert||t===s.confirm||t===s.prompt)},Ue=w.prototype.toString;var ze,Le,He,qe,We,Ge,Xe,Je,Qe,Ye,Ke,Ze,tn=Array.prototype.slice,sn=w.prototype.toString,en=function(t){var i=this;if("function"!=typeof i||"[object Function]"!==sn.call(i))throw new b("Function.prototype.bind called on incompatible "+i);for(var s,e=tn.call(arguments,1),n=_.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(tn.call(arguments)));return w(n)===n?n:this}return i.apply(t,e.concat(tn.call(arguments)))})),i.prototype){var o=function(){};o.prototype=i.prototype,s.prototype=new o,o.prototype=null}return s},nn=Function.prototype.bind||en,rn=w.prototype.toString,hn=function(t){var i=rn.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]"===rn.call(t.callee)),s};w.keys||(Le=w.prototype.hasOwnProperty,He=w.prototype.toString,qe=hn,We=w.prototype.propertyIsEnumerable,Ge=!We.call({toString:null},"toString"),Xe=We.call((function(){}),"prototype"),Je=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],Qe=function(t){var i=t.constructor;return i&&i.prototype===t},Ye={$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},Ke=function(){if(void 0===s)return!1;for(var t in s)try{if(!Ye["$"+t]&&Le.call(s,t)&&null!==s[t]&&"object"==typeof s[t])try{Qe(s[t])}catch(t){return!0}}catch(t){return!0}return!1}(),Ze=function(t){if(void 0===s||!Ke)return Qe(t);try{return Qe(t)}catch(t){return!1}},ze=function(t){var i=null!==t&&"object"==typeof t,s="[object Function]"===He.call(t),e=qe(t),n=i&&"[object String]"===He.call(t),r=[];if(!i&&!s&&!e)throw new b("Object.keys called on a non-object");var h=Xe&&s;if(n&&t.length>0&&!Le.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||!Le.call(t,u)||r.push(String(u));if(Ge)for(var c=Ze(t),l=0;l<Je.length;++l)c&&"constructor"===Je[l]||!Le.call(t,Je[l])||r.push(Je[l]);return r});var on=ze,an=Array.prototype.slice,un=hn,cn=w.keys,ln=cn?function(t){return cn(t)}:on,dn=w.keys;ln.shim=function(){if(w.keys){var t=function(){var t=w.keys(arguments);return t&&t.length===arguments.length}(1,2);t||(w.keys=function(t){return un(t)?dn(an.call(t)):dn(t)})}else w.keys=ln;return w.keys||ln};var fn=ln,vn="function"==typeof Symbol&&"symbol"==typeof Symbol("foo"),pn=w.prototype.toString,mn=Array.prototype.concat,gn=w.defineProperty,yn=gn&&function(){var t={};try{for(var i in gn(t,"x",{enumerable:!1,value:t}),t)return!1;return t.x===t}catch(t){return!1}}(),bn=function(t,i,s,e){(!(i in t)||function(t){return"function"==typeof t&&"[object Function]"===pn.call(t)}(e)&&e())&&(yn?gn(t,i,{configurable:!0,enumerable:!1,value:s,writable:!0}):t[i]=s)},kn=function(t,i){var s=arguments.length>2?arguments[2]:{},e=fn(i);vn&&(e=mn.call(e,w.getOwnPropertySymbols(i)));for(var n=0;n<e.length;n+=1)bn(t,e[n],i[e[n]],s[e[n]])};kn.supportsDescriptors=!!yn;var wn,_n=kn,xn=w.getOwnPropertyDescriptor?function(){return w.getOwnPropertyDescriptor(arguments,"callee").get}():function(){throw new b},Cn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator,Sn=w.getPrototypeOf||function(t){return t.__proto__},jn=void 0===j?wn:Sn(j),Tn={"$ %Array%":Array,"$ %ArrayBuffer%":"undefined"==typeof ArrayBuffer?wn:ArrayBuffer,"$ %ArrayBufferPrototype%":"undefined"==typeof ArrayBuffer?wn:ArrayBuffer.prototype,"$ %ArrayIteratorPrototype%":Cn?Sn([][Symbol.iterator]()):wn,"$ %ArrayPrototype%":Array.prototype,"$ %ArrayProto_entries%":Array.prototype.entries,"$ %ArrayProto_forEach%":Array.prototype.forEach,"$ %ArrayProto_keys%":Array.prototype.keys,"$ %ArrayProto_values%":Array.prototype.values,"$ %AsyncFromSyncIteratorPrototype%":wn,"$ %AsyncFunction%":undefined,"$ %AsyncFunctionPrototype%":wn,"$ %AsyncGenerator%":wn,"$ %AsyncGeneratorFunction%":undefined,"$ %AsyncGeneratorPrototype%":wn,"$ %AsyncIteratorPrototype%":wn,"$ %Atomics%":"undefined"==typeof Atomics?wn:Atomics,"$ %Boolean%":Boolean,"$ %BooleanPrototype%":Boolean.prototype,"$ %DataView%":"undefined"==typeof DataView?wn:DataView,"$ %DataViewPrototype%":"undefined"==typeof DataView?wn:DataView.prototype,"$ %Date%":Date,"$ %DatePrototype%":Date.prototype,"$ %decodeURI%":decodeURI,"$ %decodeURIComponent%":decodeURIComponent,"$ %encodeURI%":encodeURI,"$ %encodeURIComponent%":encodeURIComponent,"$ %Error%":g,"$ %ErrorPrototype%":g.prototype,"$ %eval%":eval,"$ %EvalError%":EvalError,"$ %EvalErrorPrototype%":EvalError.prototype,"$ %Float32Array%":"undefined"==typeof Float32Array?wn:Float32Array,"$ %Float32ArrayPrototype%":"undefined"==typeof Float32Array?wn:Float32Array.prototype,"$ %Float64Array%":"undefined"==typeof Float64Array?wn:Float64Array,"$ %Float64ArrayPrototype%":"undefined"==typeof Float64Array?wn:Float64Array.prototype,"$ %Function%":Function,"$ %FunctionPrototype%":Function.prototype,"$ %Generator%":wn,"$ %GeneratorFunction%":undefined,"$ %GeneratorPrototype%":wn,"$ %Int8Array%":"undefined"==typeof Int8Array?wn:Int8Array,"$ %Int8ArrayPrototype%":"undefined"==typeof Int8Array?wn:Int8Array.prototype,"$ %Int16Array%":"undefined"==typeof Int16Array?wn:Int16Array,"$ %Int16ArrayPrototype%":"undefined"==typeof Int16Array?wn:Int8Array.prototype,"$ %Int32Array%":"undefined"==typeof Int32Array?wn:Int32Array,"$ %Int32ArrayPrototype%":"undefined"==typeof Int32Array?wn:Int32Array.prototype,"$ %isFinite%":isFinite,"$ %isNaN%":S,"$ %IteratorPrototype%":Cn?Sn(Sn([][Symbol.iterator]())):wn,"$ %JSON%":JSON,"$ %JSONParse%":JSON.parse,"$ %Map%":"undefined"==typeof Map?wn:Map,"$ %MapIteratorPrototype%":"undefined"!=typeof Map&&Cn?Sn((new Map)[Symbol.iterator]()):wn,"$ %MapPrototype%":"undefined"==typeof Map?wn:Map.prototype,"$ %Math%":_,"$ %Number%":Number,"$ %NumberPrototype%":Number.prototype,"$ %Object%":w,"$ %ObjectPrototype%":w.prototype,"$ %ObjProto_toString%":w.prototype.toString,"$ %ObjProto_valueOf%":w.prototype.valueOf,"$ %parseFloat%":C,"$ %parseInt%":x,"$ %Promise%":"undefined"==typeof Promise?wn:Promise,"$ %PromisePrototype%":"undefined"==typeof Promise?wn:Promise.prototype,"$ %PromiseProto_then%":"undefined"==typeof Promise?wn:Promise.prototype.then,"$ %Promise_all%":"undefined"==typeof Promise?wn:Promise.all,"$ %Promise_reject%":"undefined"==typeof Promise?wn:Promise.reject,"$ %Promise_resolve%":"undefined"==typeof Promise?wn:Promise.resolve,"$ %Proxy%":"undefined"==typeof Proxy?wn:Proxy,"$ %RangeError%":RangeError,"$ %RangeErrorPrototype%":RangeError.prototype,"$ %ReferenceError%":ReferenceError,"$ %ReferenceErrorPrototype%":ReferenceError.prototype,"$ %Reflect%":"undefined"==typeof Reflect?wn:Reflect,"$ %RegExp%":RegExp,"$ %RegExpPrototype%":RegExp.prototype,"$ %Set%":"undefined"==typeof Set?wn:Set,"$ %SetIteratorPrototype%":"undefined"!=typeof Set&&Cn?Sn((new Set)[Symbol.iterator]()):wn,"$ %SetPrototype%":"undefined"==typeof Set?wn:Set.prototype,"$ %SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?wn:SharedArrayBuffer,"$ %SharedArrayBufferPrototype%":"undefined"==typeof SharedArrayBuffer?wn:SharedArrayBuffer.prototype,"$ %String%":String,"$ %StringIteratorPrototype%":Cn?Sn(""[Symbol.iterator]()):wn,"$ %StringPrototype%":String.prototype,"$ %Symbol%":Cn?Symbol:wn,"$ %SymbolPrototype%":Cn?Symbol.prototype:wn,"$ %SyntaxError%":k,"$ %SyntaxErrorPrototype%":k.prototype,"$ %ThrowTypeError%":xn,"$ %TypedArray%":jn,"$ %TypedArrayPrototype%":jn?jn.prototype:wn,"$ %TypeError%":b,"$ %TypeErrorPrototype%":b.prototype,"$ %Uint8Array%":void 0===j?wn:j,"$ %Uint8ArrayPrototype%":void 0===j?wn:j.prototype,"$ %Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?wn:Uint8ClampedArray,"$ %Uint8ClampedArrayPrototype%":"undefined"==typeof Uint8ClampedArray?wn:Uint8ClampedArray.prototype,"$ %Uint16Array%":"undefined"==typeof Uint16Array?wn:Uint16Array,"$ %Uint16ArrayPrototype%":"undefined"==typeof Uint16Array?wn:Uint16Array.prototype,"$ %Uint32Array%":"undefined"==typeof Uint32Array?wn:Uint32Array,"$ %Uint32ArrayPrototype%":"undefined"==typeof Uint32Array?wn:Uint32Array.prototype,"$ %URIError%":URIError,"$ %URIErrorPrototype%":URIError.prototype,"$ %WeakMap%":"undefined"==typeof WeakMap?wn:WeakMap,"$ %WeakMapPrototype%":"undefined"==typeof WeakMap?wn:WeakMap.prototype,"$ %WeakSet%":"undefined"==typeof WeakSet?wn:WeakSet,"$ %WeakSetPrototype%":"undefined"==typeof WeakSet?wn:WeakSet.prototype},Mn=function(t,i){if(arguments.length>1&&"boolean"!=typeof i)throw new b('"allowMissing" argument must be a boolean');var s="$ "+t;if(!(s in Tn))throw new k("intrinsic "+t+" does not exist!");if(void 0===Tn[s]&&!i)throw new b("intrinsic "+t+" exists, but is not available. Please file an issue!");return Tn[s]},An=nn.call(Function.call,w.prototype.hasOwnProperty),Pn=Mn,En=Pn("%TypeError%"),Nn=Pn("%SyntaxError%"),Bn=An,In={"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(Bn(i,e)&&!s[e])return!1;var n=Bn(i,"[[Value]]"),r=Bn(i,"[[Get]]")||Bn(i,"[[Set]]");if(n&&r)throw new En("Property Descriptors may not be both accessor and data descriptors");return!0}},Fn=Number.isNaN||function(t){return t!=t},Dn=Number.isNaN||function(t){return t!=t},$n=Number.isFinite||function(t){return"number"==typeof t&&!Dn(t)&&t!==1/0&&t!==-1/0},Rn=Function.prototype.toString,On=/^\s*class\b/,Vn=function(t){try{var i=Rn.call(t);return On.test(i)}catch(t){return!1}},Un=w.prototype.toString,zn="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,Ln=function(t){if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if("function"==typeof t&&!t.prototype)return!0;if(zn)return function(t){try{return!Vn(t)&&(Rn.call(t),!0)}catch(t){return!1}}(t);if(Vn(t))return!1;var i=Un.call(t);return"[object Function]"===i||"[object GeneratorFunction]"===i},Hn=w.prototype.toString,qn=function(t){return null===t||"function"!=typeof t&&"object"!=typeof t},Wn=Ln,Gn=function(t){var i;if((i=arguments.length>1?arguments[1]:"[object Date]"===Hn.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(Wn(t[n[e]])&&(s=t[n[e]](),qn(s)))return s;throw new b("No default value")}throw new b("invalid [[DefaultValue]] hint supplied")},Xn=Mn,Jn=Xn("%Object%"),Qn=Xn("%TypeError%"),Yn=Xn("%String%"),Kn=function(t,i,s,e){var n=In[i];if("function"!=typeof n)throw new Nn("unknown record type: "+i);if(!n(t,e))throw new En(s+" must be a "+i);console.log(n(t,e),e)},Zn=Fn,tr=$n,ir=function(t){return t>=0?1:-1},sr=function(t,i){var s=t%i;return _.floor(s>=0?s:s+i)},er=An,nr={ToPrimitive:function(t){return qn(t)?t:arguments.length>1?Gn(t,arguments[1]):Gn(t)},ToBoolean:function(t){return!!t},ToNumber:function(t){return+t},ToInteger:function(t){var i=this.ToNumber(t);return Zn(i)?0:0!==i&&tr(i)?ir(i)*_.floor(_.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(Zn(i)||0===i||!tr(i))return 0;var s=ir(i)*_.floor(_.abs(i));return sr(s,65536)},ToString:function(t){return Yn(t)},ToObject:function(t){return this.CheckObjectCoercible(t),Jn(t)},CheckObjectCoercible:function(t,i){if(null==t)throw new Qn(i||"Cannot call method on "+t);return t},IsCallable:Ln,SameValue:function(t,i){return t===i?0!==t||1/t==1/i:Zn(t)&&Zn(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(er(t,s)&&!i[s])return!1;var e=er(t,"[[Value]]"),n=er(t,"[[Get]]")||er(t,"[[Set]]");if(e&&n)throw new Qn("Property Descriptors may not be both accessor and data descriptors");return!0},IsAccessorDescriptor:function(t){return void 0!==t&&(Kn(this,"Property Descriptor","Desc",t),!(!er(t,"[[Get]]")&&!er(t,"[[Set]]")))},IsDataDescriptor:function(t){return void 0!==t&&(Kn(this,"Property Descriptor","Desc",t),!(!er(t,"[[Value]]")&&!er(t,"[[Writable]]")))},IsGenericDescriptor:function(t){return void 0!==t&&(Kn(this,"Property Descriptor","Desc",t),!this.IsAccessorDescriptor(t)&&!this.IsDataDescriptor(t))},FromPropertyDescriptor:function(t){if(void 0===t)return t;if(Kn(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 Qn("FromPropertyDescriptor must be called with a fully populated Property Descriptor")},ToPropertyDescriptor:function(t){if("Object"!==this.Type(t))throw new Qn("ToPropertyDescriptor requires an object");var i={};if(er(t,"enumerable")&&(i["[[Enumerable]]"]=this.ToBoolean(t.enumerable)),er(t,"configurable")&&(i["[[Configurable]]"]=this.ToBoolean(t.configurable)),er(t,"value")&&(i["[[Value]]"]=t.value),er(t,"writable")&&(i["[[Writable]]"]=this.ToBoolean(t.writable)),er(t,"get")){var s=t.get;if(void 0!==s&&!this.IsCallable(s))throw new b("getter must be a function");i["[[Get]]"]=s}if(er(t,"set")){var e=t.set;if(void 0!==e&&!this.IsCallable(e))throw new Qn("setter must be a function");i["[[Set]]"]=e}if((er(i,"[[Get]]")||er(i,"[[Set]]"))&&(er(i,"[[Value]]")||er(i,"[[Writable]]")))throw new Qn("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return i}},rr=nn.call(Function.call,String.prototype.replace),hr=/^[\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]+/,or=/[\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]+$/,ar=function(){var t=nr.ToString(nr.CheckObjectCoercible(this));return rr(rr(t,hr,""),or,"")},ur=ar,cr=function(){return String.prototype.trim&&"\u200b"==="\u200b".trim()?String.prototype.trim:ur},lr=_n,dr=cr,fr=_n,vr=ar,pr=cr,mr=function(){var t=dr();return lr(String.prototype,{trim:t},{trim:function(){return String.prototype.trim!==t}}),t},gr=nn.call(Function.call,pr());fr(gr,{getPolyfill:pr,implementation:vr,shim:mr});var yr=gr,br=Ln,kr=w.prototype.toString,wr=w.prototype.hasOwnProperty,_r=yr,xr=function(t,i,s){if(!br(i))throw new b("iterator must be a function");var e;arguments.length>=3&&(e=s),"[object Array]"===kr.call(t)?function(t,i,s){for(var e=0,n=t.length;e<n;e++)wr.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)wr.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))}(t,i,e)},Cr=function(){for(var t={},i=0;i<arguments.length;i++){var s=arguments[i];for(var e in s)Sr.call(s,e)&&(t[e]=s[e])}return t},Sr=w.prototype.hasOwnProperty;var jr=Oe.exports,Tr=Ve,Mr=function(t){if(!t)return{};var i={};return xr(_r(t).split("\n"),(function(t){var s=t.indexOf(":"),e=_r(t.slice(0,s)).toLowerCase(),n=_r(t.slice(s+1));void 0===i[e]?i[e]=n:!function(t){return"[object Array]"===w.prototype.toString.call(t)}(i[e])?i[e]=[i[e],n]:i[e].push(n)})),i},Ar=Cr,Pr=Nr;function Er(t,i,s){var e=t;return Tr(i)?(s=i,"string"==typeof t&&(e={uri:t})):e=Ar(i,{uri:t}),e.callback=s,e}function Nr(t,i,s){return Br(i=Er(t,i,s))}function Br(t){if(void 0===t.callback)throw new g("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:v,url:f,rawRequest:l};function r(t){return c(d),t instanceof g||(t=new g(""+(t||"Unknown XMLHttpRequest Error"))),t.statusCode=0,s(t,n)}function h(){if(!a){var i;c(d),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:v,headers:{},url:f,rawRequest:l},l.getAllResponseHeaders&&(r.headers=Mr(l.getAllResponseHeaders()))):h=new g("Internal XMLHttpRequest Error"),s(h,r,r.body)}}var o,a,l=t.xhr||null;l||(l=t.cors||t.useXDR?new Nr.XDomainRequest:new Nr.XMLHttpRequest);var d,f=l.url=t.uri||t.url,v=l.method=t.method||"GET",p=t.body||t.data||null,m=l.headers=t.headers||{},y=!!t.sync,b=!1;if("json"in t&&(b=!0,m.accept||m.Accept||(m.Accept="application/json"),"GET"!==v&&"HEAD"!==v&&(m["content-type"]||m["Content-Type"]||(m["Content-Type"]="application/json"),p=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(v,f,!y,t.username,t.password),y||(l.withCredentials=!!t.withCredentials),!y&&t.timeout>0&&(d=u((function(){a=!0,l.abort("timeout");var t=new g("XMLHttpRequest timeout");t.code="ETIMEDOUT",r(t)}),t.timeout)),l.setRequestHeader)for(o in m)m.hasOwnProperty(o)&&l.setRequestHeader(o,m[o]);else if(t.headers&&!function(t){for(var i in t)if(t.hasOwnProperty(i))return!1;return!0}(t.headers))throw new g("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(p),l}Nr.XMLHttpRequest=jr.XMLHttpRequest||function(){},Nr.XDomainRequest="withCredentials"in new Nr.XMLHttpRequest?Nr.XMLHttpRequest:jr.XDomainRequest,function(t,i){for(var s=0;s<t.length;s++)i(t[s])}(["get","put","post","patch","head","delete"],(function(t){Nr["delete"===t?"del":t]=function(i,s,e){return(s=Er(i,s,e)).method=t.toUpperCase(),Br(s)}}));var Ir=function(i,s){var e=new t.WebVTT.Parser(t,t.vttjs,t.WebVTT.StringDecoder()),n=[];e.oncue=function(t){s.addCue(t)},e.onparsingerror=function(t){n.push(t)},e.onflush=function(){s.trigger({type:"loadeddata",target:s})},e.parse(i),n.length>0&&(t.console&&t.console.groupCollapsed&&t.console.groupCollapsed("Text Track parsing errors for "+s.src),n.forEach((function(t){return Ui.error(t)})),t.console&&t.console.groupEnd&&t.console.groupEnd()),e.flush()},Fr=function(i){function s(e){var n;if(void 0===e&&(e={}),!e.tech)throw new g("A tech was not provided.");var r=ae(e,{kind:Ie[e.kind]||"subtitles",language:e.language||e.srclang||""}),h=Fe[r.mode]||"disabled",o=r.default;"metadata"!==r.kind&&"chapters"!==r.kind||(h="hidden");var a=n=i.call(this,r)||this;if(a.H=r.tech,Rs)for(var u in s.prototype)"constructor"!==u&&(a[u]=s.prototype[u]);a.L=[],a.q=[];var c=new Ee(a.L),l=new Ee(a.q),d=!1,f=he(a,(function(){this.activeCues,d&&(this.trigger("cuechange"),d=!1)}));return"disabled"!==h&&a.H.ready((function(){a.H.on("timeupdate",f)}),!0),w.defineProperty(a,"default",{get:function(){return o},set:function(){}}),w.defineProperty(a,"mode",{get:function(){return h},set:function(t){var i=this;Fe[t]&&("showing"===(h=t)&&this.H.ready((function(){i.H.on("timeupdate",f)}),!0),this.trigger("modechange"))}}),w.defineProperty(a,"cues",{get:function(){return this.W?c:null},set:function(){}}),w.defineProperty(a,"activeCues",{get:function(){if(!this.W)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(d=!1,i.length!==this.q.length)d=!0;else for(var r=0;r<i.length;r++)-1===this.q.indexOf(i[r])&&(d=!0);return this.q=i,l.V(this.q),l},set:function(){}}),r.src?(a.src=r.src,function(i,s){var e={uri:i},n=Re(i);n&&(e.cors=n),Pr(e,he(this,(function(i,e,n){if(i)return Ui.error(i,e);if(s.W=!0,"function"!=typeof t.WebVTT){if(s.H){var r=function(){return Ir(n,s)};s.H.on("vttjsloaded",r),s.H.on("vttjserror",(function(){Ui.error("vttjs failed to load, stopping trying to process "+s.src),s.H.off("vttjsloaded",r)}))}}else Ir(n,s)})))}(r.src,a)):a.W=!0,a||ce(n)}de(s,i);var e=s.prototype;return e.addCue=function(i){var s=i;if(t.vttjs&&!(i instanceof t.vttjs.VTTCue)){for(var e in s=new t.vttjs.VTTCue(i.startTime,i.endTime,i.text),i)e in s||(s[e]=i[e]);s.id=i.id,s.G=i}var n=this.H.textTracks();if(n)for(var r=0;r<n.length;r++)n[r]!==this&&n[r].removeCue(s);this.L.push(s),this.cues.V(this.L)},e.removeCue=function(t){for(var i=this.L.length;i--;){var s=this.L[i];if(s===t||s.G&&s.G===t){this.L.splice(i,1),this.cues.V(this.L);break}}},s}(De);Fr.prototype.A={cuechange:"cuechange"};var Dr=function(t){function i(s){var e,n;void 0===s&&(s={});var r=ce(e=t.call(this)||this);if(Rs)for(var h in r=Ai.createElement("custom"),i.prototype)"constructor"!==h&&(r[h]=i.prototype[h]);var o=new Fr(s);return r.kind=o.kind,r.src=o.src,r.srclang=o.language,r.label=o.label,r.default=o.default,w.defineProperty(r,"readyState",{get:function(){return n}}),w.defineProperty(r,"track",{get:function(){return o}}),n=0,o.addEventListener("loadeddata",(function(){n=2,r.trigger({type:"load",target:r})})),Rs?r||ce(e):e}return de(i,t),i}(ue);Dr.prototype.A={load:"load"},Dr.NONE=0,Dr.LOADING=1,Dr.LOADED=2,Dr.ERROR=3;var $r,Rr=function(){function t(i){void 0===i&&(i=[]);var s=this;if(Rs)for(var e in s=Ai.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);s.X=[],w.defineProperty(s,"length",{get:function(){return this.X.length}});for(var n=0,r=i.length;n<r;n++)s.J(i[n]);if(Rs)return s}var i=t.prototype;return i.J=function(t){var i=this.X.length;""+i in this||w.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}(),Or=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),Rs))for(var r in e=Ai.createElement("custom"),i.prototype)"constructor"!==r&&(e[r]=i.prototype[r]);e.Z=[],w.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)}de(i,t);var s=i.prototype;return s.tt=function(t){var i=this.Z.length;""+i in this||w.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}(ue);for($r in Or.prototype.A={change:"change",addtrack:"addtrack",removetrack:"removetrack"},Or.prototype.A)Or.prototype["on"+$r]=null;var Vr=function(t){function i(s){var e,n;if(void 0===s&&(s=[]),Rs){for(var r in n=Ai.createElement("custom"),Or.prototype)"constructor"!==r&&(n[r]=Or.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 de(i,t),i.prototype.tt=function(i){t.prototype.tt.call(this,i),i.addEventListener("modechange",he(this,(function(){this.trigger("change")})))},i}(Or),Ur=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].selected=!1)},zr=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){Ur(s,s[r]);break}if(Rs){for(var h in n=Ai.createElement("custom"),Or.prototype)"constructor"!==h&&(n[h]=Or.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,w.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)}de(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.selected&&Ur(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("selectedchange",(function(){s.st||(s.st=!0,Ur(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}(Or),Lr=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].enabled=!1)},Hr=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){Lr(s,s[r]);break}if(Rs){for(var h in n=Ai.createElement("custom"),Or.prototype)"constructor"!==h&&(n[h]=Or.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)}de(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.enabled&&Lr(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("enabledchange",(function(){s.st||(s.st=!0,Lr(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}(Or),qr=void 0;var Wr=function(i){function s(t,s){var e;return void 0===t&&(t={}),void 0===s&&(s=function(){}),t.reportTouchActivity=!1,(e=i.call(this,null,t,s)||this).et=!1,e.on("playing",(function(){this.et=!0})),e.on("loadstart",(function(){this.et=!1})),e.nt=t.textTracks,e.rt=t.videoTracks,e.ht=t.audioTracks,e.featuresProgressEvents||e.manualProgressOn(),e.featuresTimeupdateEvents||e.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach((function(i){!1===t["native"+i+"Tracks"]&&(e["featuresNative"+i+"Tracks"]=!1)})),!1===t.nativeCaptions&&(e.featuresNativeTextTracks=!1),e.featuresNativeTextTracks||e.emulateTextTracks(),e.ot=new Vr,e.initTextTrackListeners(),e.initTrackListeners(),t.nativeControlsForTouch||e.emitTapEvents(),e.constructor&&(e.l=e.constructor.name||"Unknown Tech"),e}de(s,i);var e=s.prototype;return e.manualProgressOn=function(){this.on("durationchange",this.onDurationChange),this.manualProgress=!0,this.one("ready",this.trackProgress)},e.manualProgressOff=function(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange)},e.trackProgress=function(t){this.stopTrackingProgress(),this.progressInterval=this.setInterval(he(this,(function(){var t=this.bufferedPercent();this.ut!==t&&this.trigger("progress"),this.ut=t,1===t&&this.stopTrackingProgress()})),500)},e.onDurationChange=function(t){this.ct=this.duration()},e.buffered=function(){return pe(0,0)},e.bufferedPercent=function(){return me(this.buffered(),this.ct)},e.stopTrackingProgress=function(){this.clearInterval(this.progressInterval)},e.manualTimeUpdatesOn=function(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime),this.on("pause",this.stopTrackingCurrentTime)},e.manualTimeUpdatesOff=function(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime),this.off("pause",this.stopTrackingCurrentTime)},e.trackCurrentTime=function(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval((function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}),250)},e.stopTrackingCurrentTime=function(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},e.dispose=function(){this.clearTracks(["audio","video","text"]),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),i.prototype.dispose.call(this)},e.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)}}))},e.cleanupAutoTextTracks=function(){for(var t=this.ot||[],i=t.length;i--;){var s=t[i];this.removeRemoteTextTrack(s)}},e.reset=function(){},e.error=function(t){return void 0!==t&&(this.lt=new Ce(t),this.trigger("error")),this.lt},e.played=function(){return this.et?pe(0,0):pe()},e.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},e.initTextTrackListeners=function(){var t=he(this,(function(){this.trigger("texttrackchange")})),i=this.textTracks();i&&(i.addEventListener("removetrack",t),i.addEventListener("addtrack",t),this.on("dispose",he(this,(function(){i.removeEventListener("removetrack",t),i.removeEventListener("addtrack",t)}))))},e.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)}))}))},e.dt=function(){var i=this;if(!t.WebVTT)if(Ai.body.contains(this.el())){if(!this.h["vtt.js"]&&Oi(qr)&&w.keys(qr).length>0)return void this.trigger("vttjsloaded");var s=Ai.createElement("script");s.src=this.h["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.12.4/vtt.min.js",s.onload=function(){i.trigger("vttjsloaded")},s.onerror=function(){i.trigger("vttjserror")},this.on("dispose",(function(){s.onload=null,s.onerror=null})),t.WebVTT=!0,this.el().parentNode.appendChild(s)}else this.ready(this.dt)},e.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.dt();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)}}))}},e.videoTracks=function(){return this.rt=this.rt||new zr,this.rt},e.audioTracks=function(){return this.ht=this.ht||new Hr,this.ht},e.textTracks=function(){return this.nt=this.nt||new Vr,this.nt},e.remoteTextTracks=function(){return this.ft=this.ft||new Vr,this.ft},e.remoteTextTrackEls=function(){return this.vt=this.vt||new Rr,this.vt},e.addTextTrack=function(t,i,s){if(!t)throw new g("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 Fr(n);return r.tt(h),h}(this,t,i,s)},e.createRemoteTextTrack=function(t){var i=ae(t,{tech:this});return new Dr(i)},e.addRemoteTextTrack=function(t,i){void 0===t&&(t={});var s=this.createRemoteTextTrack(t);return!0!==i&&!1!==i&&(Ui.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},e.removeRemoteTextTrack=function(t){var i=this.remoteTextTrackEls().Y(t);this.remoteTextTrackEls().K(i),this.remoteTextTracks().it(t),this.ot.it(t)},e.getVideoPlaybackQuality=function(){return{}},e.setPoster=function(){},e.playsinline=function(){},e.setPlaysinline=function(){},e.canPlayType=function(){return""},s.isTech=function(t){return t.prototype instanceof s||t instanceof s||t===s},s.registerTech=function(t,i){if(s.gt||(s.gt={}),!s.isTech(i))throw new g("Tech "+t+" must be a Tech");return s.gt[t]=i,i},s.getTech=function(i){return s.gt&&s.gt[i]?s.gt[i]:t&&t.videojs&&t.videojs[i]?(Ui.warn("The "+i+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),t.videojs[i]):void 0},s}(i);Wr.prototype.nt,Wr.prototype.ht,Wr.prototype.rt,Wr.prototype.featuresVolumeControl=!0,Wr.prototype.featuresFullscreenResize=!1,Wr.prototype.featuresPlaybackRate=!1,Wr.prototype.featuresProgressEvents=!1,Wr.prototype.featuresTimeupdateEvents=!1,Wr.prototype.featuresNativeTextTracks=!1,Wr.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:Ui.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.kt),this.off(this.v,"loadstart",t.prototype.wt),this.one(this.v,"loadstart",t.prototype.kt)),this.yt=s.handleSource(i,this,this.h),this.on("dispose",this.disposeSourceHandler),this},t.prototype.kt=function(){this.one(this.v,"loadstart",t.prototype.wt)},t.prototype.wt=function(){this.disposeSourceHandler(),this.one(this.v,"loadstart",t.prototype.wt)},t.prototype.disposeSourceHandler=function(){this.bt&&(this.clearTracks(["audio","video"]),this.bt=null),this.cleanupAutoTextTracks(),this.yt&&(this.off(this.v,"loadstart",t.prototype.kt),this.off(this.v,"loadstart",t.prototype.wt),this.yt.dispose&&this.yt.dispose(),this.yt=null)}},i.registerComponent("Tech",Wr),i.registerComponent("MediaTechController",Wr),Wr.registerTech("Tech",Wr);var Gr=function(t){function s(s,e,n){var r;if(r=t.call(this,s,e,n)||this,e.playerOptions.sources&&0!==e.playerOptions.sources.length)s.src(e.playerOptions.sources);else for(var h=0,o=e.playerOptions.techOrder;h<o.length;h++){var a=oe(o[h]),u=Wr.getTech(a);if(a||(u=i.getComponent(a)),u&&u.isSupported()){s._t(a);break}}return r}return de(s,t),s}(i);i.registerComponent("MediaLoader",Gr);var Xr=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}de(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=$i({className:this.buildCSSClass(),tabIndex:0},s),"button"===i&&Ui.error("Creating a ClickableComponent with an HTML element of "+i+" is not supported; use a Button instead."),e=$i({role:"button","aria-live":"polite"},e),this.xt=s.tabIndex;var n=t.prototype.createEl.call(this,i,s,e);return this.createControlTextEl(n),n},s.createControlTextEl=function(t){return this.Ct=Yi("span",{className:"vjs-control-text"}),t&&t.appendChild(this.Ct),this.controlText(this.St,t),this.Ct},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.Ct.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.xt&&this.v.setAttribute("tabIndex",this.xt),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.xt&&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){Qs(Ai,"keydown",he(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){Ys(Ai,"keydown",he(this,this.handleKeyPress))},i}(i);i.registerComponent("ClickableComponent",Xr);var Jr=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).update(),i.on("posterchange",he(ce(e),e.update)),e}de(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=Yi("div",{className:"vjs-poster",tabIndex:-1});return Ls||(this.jt=Yi("img"),t.appendChild(this.jt)),t},s.update=function(t){var i=this.player().poster();this.setSrc(i),i?this.show():this.hide()},s.setSrc=function(t){if(this.jt)this.jt.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}(Xr);i.registerComponent("PosterImage",Jr);var Qr="#222",Yr={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 Kr(t,i){return"rgba("+x(t[1]+t[1],16)+","+x(t[2]+t[2],16)+","+x(t[3]+t[3],16)+","+i+")"}function Zr(t,i,s){try{t.style[i]=s}catch(t){return}}var th=function(i){function s(t,s,e){var n;return n=i.call(this,t,s,e)||this,t.on("loadstart",he(ce(n),n.toggleDisplay)),t.on("texttrackchange",he(ce(n),n.updateDisplay)),t.ready(he(ce(n),(function(){if(t.H&&t.H.featuresNativeTextTracks)this.hide();else{t.on("fullscreenchange",he(this,this.updateDisplay));for(var i=this.h.playerOptions.tracks||[],s=0;s<i.length;s++)this.t.addRemoteTextTrack(i[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}de(s,i);var e=s.prototype;return e.toggleDisplay=function(){this.t.H&&this.t.H.featuresNativeTextTracks?this.hide():this.show()},e.createEl=function(){return i.prototype.createEl.call(this,"div",{className:"vjs-text-track-display"},{"aria-live":"off","aria-atomic":"true"})},e.clearDisplay=function(){"function"==typeof t.WebVTT&&t.WebVTT.processCues(t,[],this.v)},e.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))}},e.updateForTrack=function(i){if("function"==typeof t.WebVTT&&i.activeCues){for(var s=this.t.textTrackSettings.getValues(),e=[],n=0;n<i.activeCues.length;n++)e.push(i.activeCues[n]);t.WebVTT.processCues(t,e,this.v);for(var r=e.length;r--;){var h=e[r];if(h){var o=h.displayState;if(s.color&&(o.firstChild.style.color=s.color),s.textOpacity&&Zr(o.firstChild,"color",Kr(s.color||"#fff",s.textOpacity)),s.backgroundColor&&(o.firstChild.style.backgroundColor=s.backgroundColor),s.backgroundOpacity&&Zr(o.firstChild,"backgroundColor",Kr(s.backgroundColor||"#000",s.backgroundOpacity)),s.windowColor&&(s.windowOpacity?Zr(o,"backgroundColor",Kr(s.windowColor,s.windowOpacity)):o.style.backgroundColor=s.windowColor),s.edgeStyle&&("dropshadow"===s.edgeStyle?o.firstChild.style.textShadow="2px 2px 3px #222, 2px 2px 4px #222, 2px 2px 5px "+Qr:"raised"===s.edgeStyle?o.firstChild.style.textShadow="1px 1px #222, 2px 2px #222, 3px 3px "+Qr:"depressed"===s.edgeStyle?o.firstChild.style.textShadow="1px 1px #ccc, 0 1px #ccc, -1px -1px #222, 0 -1px "+Qr:"uniform"===s.edgeStyle&&(o.firstChild.style.textShadow="0 0 4px #222, 0 0 4px #222, 0 0 4px #222, 0 0 4px "+Qr)),s.fontPercent&&1!==s.fontPercent){var a=t.parseFloat(o.style.fontSize);o.style.fontSize=a*s.fontPercent+"px",o.style.height="auto",o.style.top="auto",o.style.bottom="2px"}s.fontFamily&&"default"!==s.fontFamily&&("small-caps"===s.fontFamily?o.firstChild.style.fontVariant="small-caps":o.firstChild.style.fontFamily=Yr[s.fontFamily])}}}},s}(i);i.registerComponent("TextTrackDisplay",th);var ih=function(t){function i(){return t.apply(this,arguments)||this}return de(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"})},i}(i);i.registerComponent("LoadingSpinner",ih);var sh=function(t){function s(){return t.apply(this,arguments)||this}de(s,t);var e=s.prototype;return e.createEl=function(t,s,e){void 0===t&&(t="button"),void 0===s&&(s={}),void 0===e&&(e={}),s=$i({className:this.buildCSSClass()},s),"button"!==t&&(Ui.warn("Creating a Button with an HTML element of "+t+" is deprecated; use ClickableComponent instead."),s=$i({tabIndex:0},s),e=$i({role:"button"},e)),e=$i({type:"button","aria-live":"polite"},e);var n=i.prototype.createEl.call(this,t,s,e);return this.createControlTextEl(n),n},e.addChild=function(t,s){void 0===s&&(s={});var e=this.constructor.name;return Ui.warn("Adding an actionable (user controllable) child to a Button ("+e+") is not supported; use a ClickableComponent instead."),i.prototype.addChild.call(this,t,s)},e.enable=function(){t.prototype.enable.call(this),this.v.removeAttribute("disabled")},e.disable=function(){t.prototype.disable.call(this),this.v.setAttribute("disabled","disabled")},e.handleKeyPress=function(i){32!==i.which&&13!==i.which&&t.prototype.handleKeyPress.call(this,i)},s}(Xr);i.registerComponent("Button",sh);var eh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Tt=!1,e.on("mousedown",e.handleMouseDown),e}de(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-big-play-button"},s.handleClick=function(t){var i=this;if(this.Tt&&t.clientX&&t.clientY)this.t.play();else{var s=this.t.getChild("controlBar"),e=s&&s.getChild("playToggle");this.one(this.t,"play",(function(){e?e.focus():i.t.focus()})),this.t.play()}},s.handleKeyPress=function(i){this.Tt=!1,t.prototype.handleKeyPress.call(this,i)},s.handleMouseDown=function(t){this.Tt=!0},i}(sh);eh.prototype.St="Play Video",i.registerComponent("BigPlayButton",eh);var nh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).controlText(s&&s.controlText||"Close"),e}de(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}(sh);i.registerComponent("CloseButton",nh);var rh=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}de(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}(sh);function hh(t,i){void 0===i&&(i=t),t=t<0?0:t;var s=_.floor(t%60),e=_.floor(t/60%60),n=_.floor(t/3600),r=_.floor(i/60%60),h=_.floor(i/3600);return(S(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)}rh.prototype.St="Play",i.registerComponent("PlayToggle",rh);var oh=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}de(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=Yi("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=hh(i,this.t.duration());e!==this.Mt&&(this.Mt=e,this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e)},i}(i);i.registerComponent("CurrentTimeDisplay",oh);var ah=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}de(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=Yi("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=hh(i);this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e}},i}(i);i.registerComponent("DurationDisplay",ah);var uh=function(t){function i(){return t.apply(this,arguments)||this}return de(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}(i);i.registerComponent("TimeDivider",uh);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}de(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=Yi("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=hh(this.t.remainingTime());s!==this.Mt&&(this.Mt=s,this.S.innerHTML='<span class="vjs-control-text">'+i+"</span> -"+s)}},i}(i);i.registerComponent("RemainingTimeDisplay",ch);var lh=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}de(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=Yi("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.Ct=Yi("span",{className:"vjs-control-text",innerHTML:this.localize("Stream Type")}),this.At=Ai.createTextNode(this.localize("LIVE")),this.S.appendChild(this.Ct),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.Ct.innerHTML=this.localize("Stream Type"),this.At.innerHTML=this.localize("LIVE")},i}(i);i.registerComponent("LiveDisplay",lh);var dh=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}de(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=$i({tabIndex:0},s),e=$i({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(),Ai.body.focus(),Ai.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;Ai.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=vs(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.Pt||!1:(this.Pt=!!t,this.Pt?this.addClass("vjs-slider-vertical"):this.addClass("vjs-slider-horizontal"),this)},i}(i);function fh(i,s){if(!i||!s)return"";if("function"==typeof t.getComputedStyle){var e=t.getComputedStyle(i);return e?e[s]:""}return i.currentStyle[s]||""}i.registerComponent("Slider",dh);var vh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Et=[],e.on(i,"progress",e.update),e.on(i,"languagechange",e.handleLanguagechange),e}de(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-load-progress"});return this.Nt=Yi("span",{innerHTML:this.localize("Loaded")}),this.Bt=Ai.createTextNode(": 0%"),this.Ct=Yi("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.Nt),this.Ct.appendChild(this.Bt),i.appendChild(this.Ct),i},s.update=function(t){var i=this.t.buffered(),s=this.t.duration(),e=this.t.bufferedEnd(),n=this.Et,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(Yi()),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.Nt.innerHTML=this.localize("Loaded")},i}(i);i.registerComponent("LoadProgressBar",vh);var ph=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(he(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}de(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.It=Yi("span",{innerHTML:this.localize("Progress")}),this.Ft=Ai.createTextNode(": 0%"),this.Ct=Yi("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.It),this.Ct.appendChild(this.Ft),i.appendChild(this.Ct),i},s.updateDataAttr=function(t){var i=this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime();this.v.setAttribute("data-current-time",hh(i,this.t.duration()))},s.handleLanguagechange=function(){this.It.innerHTML=this.localize("Progress")},i}(i);i.registerComponent("PlayProgressBar",ph);var mh=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(he(ce(e),e.updateDataAttr)),e}de(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=Yi("div",{className:"vjs-time-tooltip"}),this.It=Yi("span",{innerHTML:this.localize("Progress")}),this.Ft=Ai.createTextNode(": 0%"),this.Ct=Yi("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.It),this.Ct.appendChild(this.Ft),i.appendChild(this.tooltip),i.appendChild(this.Ct),i},s.updateDataAttr=function(t){var i=hh(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.It.innerHTML=this.localize("Progress")},i}(i);i.registerComponent("TooltipProgressBar",mh);var gh=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(he(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}de(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=C(fh(this.player().el(),"width")),s=C(fh(this.tooltipProgressBar.tooltip,"width")),e=this.tooltipProgressBar.el().style;e.maxWidth=_.floor(i-s/2)+"px",e.minWidth=_.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",hh(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}(dh);gh.prototype.h={children:["loadProgressBar","mouseTimeDisplay","playProgressBar"],barName:"playProgressBar"},gh.prototype.playerEvent="timeupdate",i.registerComponent("SeekBar",gh);var yh=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=Yi("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)}}(he(ce(e),e.handleMouseMove),25))})),e}de(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-fs(this.el().parentNode).left;this.update(s,e)},s.update=function(t,i){var s=hh(t,this.t.duration());if(this.el().style.left=i+"px",this.el().setAttribute("data-current-time",s),this.keepTooltipsInside){var e=i-this.Dt(i)+1,n=C(fh(this.tooltip,"width"))/2;this.tooltip.innerHTML=s,this.tooltip.style.right="-"+(n-e)+"px"}},s.calculateDistance=function(t){return vs(this.el().parentNode,t).x},s.Dt=function(t){if(!this.keepTooltipsInside)return t;var i=C(fh(this.player().el(),"width")),s=C(fh(this.tooltip,"width"))/2,e=t;return t<s?e=_.ceil(s):t>i-s&&(e=_.floor(i-s)),e},i}(i);i.registerComponent("MouseTimeDisplay",yh);var bh=function(t){function i(){return t.apply(this,arguments)||this}return de(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},i}(i);bh.prototype.h={children:["seekBar"]},i.registerComponent("ProgressControl",bh);var kh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"fullscreenchange",e.handleFullscreenChange),e}de(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}(sh);kh.prototype.St="Fullscreen",i.registerComponent("FullscreenToggle",kh);var wh=function(t){function i(){return t.apply(this,arguments)||this}return de(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}(i);i.registerComponent("VolumeLevel",wh);var _h=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.updateARIAAttributes),i.ready(he(ce(e),e.updateARIAAttributes)),e}de(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}(dh);_h.prototype.h={children:["volumeLevel"],barName:"volumeLevel"},_h.prototype.playerEvent="volumechange",i.registerComponent("VolumeBar",_h);var xh=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 de(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control"})},i}(i);xh.prototype.h={children:["volumeBar"]},i.registerComponent("VolumeControl",xh);var Ch=function(t){function i(){return t.apply(this,arguments)||this}de(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",he(this,(function(){this.unlockShowing()})))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=Yi(i,{className:"vjs-menu-content"});var s=t.prototype.createEl.call(this,"div",{append:this.S,className:"vjs-menu"});return s.appendChild(this.S),Qs(s,"click",(function(t){t.preventDefault(),t.stopImmediatePropagation()})),s},i}(i);i.registerComponent("Popup",Ch);var Sh=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e}de(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}(Xr);i.registerComponent("PopupButton",Sh);var jh=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}de(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++)os(this.v,"vjs-vol-"+n);hs(this.v,"vjs-vol-"+s)},i}(sh);jh.prototype.St="Mute",i.registerComponent("MuteToggle",jh);var Th=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}de(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 Ch(this.t,{contentElType:"div"}),i=new _h(this.t,this.h.volumeBar);return t.addChild(i),this.menuContent=t,this.volumeBar=i,this.attachVolumeBarEvents(),t},s.handleClick=function(i){jh.prototype.handleClick.call(this),t.prototype.handleClick.call(this)},s.attachVolumeBarEvents=function(){this.menuContent.on(["mousedown","touchdown"],he(this,this.handleMouseDown))},s.handleMouseDown=function(t){this.on(["mousemove","touchmove"],he(this.volumeBar,this.volumeBar.handleMouseMove)),this.on(this.v.ownerDocument,["mouseup","touchend"],this.handleMouseUp)},s.handleMouseUp=function(t){this.off(["mousemove","touchmove"],he(this.volumeBar,this.volumeBar.handleMouseMove))},i}(Sh);Th.prototype.volumeUpdate=jh.prototype.update,Th.prototype.St="Mute",i.registerComponent("VolumeMenuButton",Th);var Mh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).$t=-1,e.on("keydown",e.handleKeyPress),e}de(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",he(this,(function(t){this.unlockShowing()})))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=Yi(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),Qs(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.$t&&(t=this.$t+1),this.focus(t)},s.stepBack=function(){var t=0;void 0!==this.$t&&(t=this.$t-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.$t=t,i[t].v.focus())},i}(i);i.registerComponent("Menu",Mh);var Ah=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}de(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 Mh(this.t);if(this.Vt=0,this.h.title){var i=Yi("li",{className:"vjs-menu-title",innerHTML:oe(this.h.title),tabIndex:-1});this.Vt+=1,t.m.unshift(i),Zi(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",he(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}(Xr);i.registerComponent("MenuButton",Ah);var Ph=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=he(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 de(i,t),i}(Ah);i.registerComponent("TrackButton",Ph);var Eh=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}de(i,t);var s=i.prototype;return s.createEl=function(i,s,e){this.nonIconControl=!0;var n=t.prototype.createEl.call(this,"li",$i({className:"vjs-menu-item",tabIndex:-1},s),e);return this.Ut=Ai.createTextNode(this.localize(this.h.label)),n.appendChild(this.Ut),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.Ut.innerHTML=this.localize(this.h.label)},i}(Xr);i.registerComponent("MenuItem",Eh);var Nh=function(i){function s(s,e){var n,r,h=e.track,o=s.textTracks();if(e.label=h.label||h.language||"Unknown",e.selected=h.default||"showing"===h.mode,(n=i.call(this,s,e)||this).track=h,o){var a=he(ce(n),n.handleTracksChange);s.on(["loadstart","texttrackchange"],a),o.addEventListener("change",a),n.on("dispose",(function(){o.removeEventListener("change",a)}))}o&&void 0===o.onchange&&n.on(["tap","click"],(function(){if("object"!=typeof t.Event)try{r=new t.Event("change")}catch(t){}r||(r=Ai.createEvent("Event")).initEvent("change",!0,!0),o.dispatchEvent(r)}));return n}de(s,i);var e=s.prototype;return e.handleClick=function(t){var s=this.track.kind,e=this.t.textTracks();if(i.prototype.handleClick.call(this,t),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"))}},e.handleTracksChange=function(t){this.selected("showing"===this.track.mode)},s}(Eh);i.registerComponent("TextTrackMenuItem",Nh);var Bh=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 de(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}(Nh);i.registerComponent("OffTextTrackMenuItem",Bh);var Ih=function(t){function i(i,s){return void 0===s&&(s={}),s.tracks=i.textTracks(),t.call(this,i,s)||this}return de(i,t),i.prototype.createItems=function(t){void 0===t&&(t=[]),t.push(new Bh(this.t,{kind:this.zt})),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.zt&&t.push(new Nh(this.t,{track:e,selectable:!0}))}return t},i}(Ph);i.registerComponent("TextTrackButton",Ih);var Fh=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",he(ce(e),e.update)),e}de(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}(Eh);i.registerComponent("ChaptersTrackMenuItem",Fh);var Dh=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}de(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-chapters-button "+t.prototype.buildCSSClass.call(this)},s.update=function(i){this.Lt&&(!i||"addtrack"!==i.type&&"removetrack"!==i.type)||this.setTrack(this.findChaptersTrack()),t.prototype.update.call(this)},s.setTrack=function(t){if(this.Lt!==t){if(this.Ht||(this.Ht=this.update.bind(this)),this.Lt){var i=this.t.remoteTextTrackEls().Y(this.Lt);i&&i.removeEventListener("load",this.Ht),this.Lt=null}if(this.Lt=t,this.Lt){this.Lt.mode="hidden";var s=this.t.remoteTextTrackEls().Y(this.Lt);s&&s.addEventListener("load",this.Ht)}}},s.findChaptersTrack=function(){for(var t=this.t.textTracks()||[],i=t.length-1;i>=0;i--){var s=t[i];if(s.kind===this.zt)return s}},s.getMenuCaption=function(){return this.Lt&&this.Lt.label?this.Lt.label:this.localize(oe(this.zt))},s.createMenu=function(){return this.h.title=this.getMenuCaption(),t.prototype.createMenu.call(this)},s.createItems=function(){var t=[];if(!this.Lt)return t;var i=this.Lt.cues;if(!i)return t;for(var s=0,e=i.length;s<e;s++){var n=i[s],r=new Fh(this.t,{track:this.Lt,cue:n});t.push(r)}return t},i}(Ih);Dh.prototype.zt="chapters",Dh.prototype.St="Chapters",i.registerComponent("ChaptersButton",Dh);var $h=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=he(ce(n),n.handleTracksChange);r.addEventListener("change",h),n.on("dispose",(function(){r.removeEventListener("change",h)}))}return n}de(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.zt&&"showing"===r.mode){s=!0;break}}s?this.disable():this.enable()},s.buildCSSClass=function(){return"vjs-descriptions-button "+t.prototype.buildCSSClass.call(this)},i}(Ih);$h.prototype.zt="descriptions",$h.prototype.St="Descriptions",i.registerComponent("DescriptionsButton",$h);var Rh=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 de(i,t),i.prototype.buildCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildCSSClass.call(this)},i}(Ih);Rh.prototype.zt="subtitles",Rh.prototype.St="Subtitles",i.registerComponent("SubtitlesButton",Rh);var Oh=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 de(i,t),i.prototype.handleClick=function(t){this.player().getChild("textTrackSettings").show(),this.player().getChild("textTrackSettings").v.focus()},i}(Nh);i.registerComponent("CaptionSettingsMenuItem",Oh);var Vh=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}de(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 Oh(this.t,{kind:this.zt})),this.Vt+=1),t.prototype.createItems.call(this,i)},i}(Ih);Vh.prototype.zt="captions",Vh.prototype.St="Captions",i.registerComponent("CaptionsButton",Vh);var Uh=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=he(ce(e),e.handleTracksChange);r.addEventListener("change",h),e.on("dispose",(function(){r.removeEventListener("change",h)}))}return e}de(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}(Eh);i.registerComponent("AudioTrackMenuItem",Uh);var zh=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}de(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 Uh(this.t,{track:e,selectable:!0}))}return t},i}(Ph);zh.prototype.St="Audio Track",i.registerComponent("AudioTrackButton",zh);var Lh=function(t){function i(i,s){var e,n=s.rate,r=C(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}de(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}(Eh);Lh.prototype.contentElType="button",i.registerComponent("PlaybackRateMenuItem",Lh);var Hh=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}de(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this);return this.Ut=Yi("div",{className:"vjs-playback-rate-value",innerHTML:1}),i.appendChild(this.Ut),i},s.buildCSSClass=function(){return"vjs-playback-rate "+t.prototype.buildCSSClass.call(this)},s.createMenu=function(){var t=new Mh(this.player()),i=this.playbackRates();if(i)for(var s=i.length-1;s>=0;s--)t.addChild(new Lh(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.Ut.innerHTML=this.player().playbackRate()+"x")},i}(Ah);Hh.prototype.St="Playback Rate",i.registerComponent("PlaybackRateMenuButton",Hh);var qh=function(t){function i(){return t.apply(this,arguments)||this}de(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}(i);i.registerComponent("Spacer",qh);var Wh=function(t){function i(){return t.apply(this,arguments)||this}de(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}(qh);i.registerComponent("CustomControlSpacer",Wh);var Gh=function(t){function i(){return t.apply(this,arguments)||this}return de(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"},{role:"group"})},i}(i);Gh.prototype.h={children:["playToggle","volumeMenuButton","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subtitlesButton","captionsButton","audioTrackButton","fullscreenToggle"]},i.registerComponent("ControlBar",Gh);var Xh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"error",e.open),e}de(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}(Pe);Xh.prototype.h=ae(Pe.prototype.h,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),i.registerComponent("ErrorDisplay",Xh);var Jh="vjs-text-track-settings",Qh=["#000","Black"],Yh=["#00F","Blue"],Kh=["#0FF","Cyan"],Zh=["#0F0","Green"],to=["#F0F","Magenta"],io=["#F00","Red"],so=["#FFF","White"],eo=["#FF0","Yellow"],no=["1","Opaque"],ro=["0.5","Semi-Transparent"],ho=["0","Transparent"],oo={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[Qh,so,io,Zh,Yh,eo,to,Kh]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[no,ro,ho]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[so,Qh,io,Zh,Yh,eo,to,Kh]},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:[no,ro]},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:[ho,ro,no]}};function ao(t,i){if(i&&(t=i(t)),t&&"none"!==t)return t}oo.windowColor.options=oo.backgroundColor.options;var uo,co=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).setDefaults(),e.hide(),e.updateDisplay=he(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()})),Di(oo,(function(t){e.on(e.$(t.selector),"change",e.updateDisplay)})),e.h.persistTextTrackSettings&&e.restoreSettings(),e}de(s,i);var e=s.prototype;return e.qt=function(t){var i=this,s=oo[t],e=s.id.replace("%s",this.o);return[Yi("label",{className:"vjs-label",textContent:s.label},{for:e}),Yi("select",{id:e},void 0,s.options.map((function(t){return Yi("option",{textContent:i.localize(t[1]),value:t[0]})})))]},e.Wt=function(){var t=Yi("legend",{textContent:this.localize("Text")}),i=this.qt("color"),s=Yi("span",{className:"vjs-text-opacity vjs-opacity"},void 0,this.qt("textOpacity"));return Yi("fieldset",{className:"vjs-fg-color vjs-tracksetting"},void 0,[t].concat(i,s))},e.Gt=function(){var t=Yi("legend",{textContent:this.localize("Background")}),i=this.qt("backgroundColor"),s=Yi("span",{className:"vjs-bg-opacity vjs-opacity"},void 0,this.qt("backgroundOpacity"));return Yi("fieldset",{className:"vjs-bg-color vjs-tracksetting"},void 0,[t].concat(i,s))},e.Xt=function(){var t=Yi("legend",{textContent:this.localize("Window")}),i=this.qt("windowColor"),s=Yi("span",{className:"vjs-window-opacity vjs-opacity"},void 0,this.qt("windowOpacity"));return Yi("fieldset",{className:"vjs-window-color vjs-tracksetting"},void 0,[t].concat(i,s))},e.Jt=function(){return Yi("div",{className:"vjs-tracksettings-colors"},void 0,[this.Wt(),this.Gt(),this.Xt()])},e.Qt=function(){var t=Yi("div",{className:"vjs-font-percent vjs-tracksetting"},void 0,this.qt("fontPercent")),i=Yi("div",{className:"vjs-edge-style vjs-tracksetting"},void 0,this.qt("edgeStyle")),s=Yi("div",{className:"vjs-font-family vjs-tracksetting"},void 0,this.qt("fontFamily"));return Yi("div",{className:"vjs-tracksettings-font"},void 0,[t,i,s])},e.Yt=function(){var t=Yi("button",{className:"vjs-default-button",textContent:this.localize("Defaults")}),i=Yi("button",{className:"vjs-done-button",textContent:"Done"});return Yi("div",{className:"vjs-tracksettings-controls"},void 0,[t,i])},e.createEl=function(){var t=Yi("div",{className:"vjs-tracksettings"},void 0,[this.Jt(),this.Qt(),this.Yt()]),i=Yi("div",{className:"vjs-control-text",id:"TTsettingsDialogLabel-"+this.o,textContent:"Caption Settings Dialog"},{"aria-level":"1",role:"heading"}),s=Yi("div",{className:"vjs-control-text",id:"TTsettingsDialogDescription-"+this.o,textContent:"Beginning of dialog window. Escape will cancel and close the window."}),e=Yi("div",void 0,{role:"document"},[i,s,t]);return Yi("div",{className:"vjs-caption-settings vjs-modal-overlay",tabIndex:-1},{role:"dialog","aria-labelledby":i.id,"aria-describedby":s.id},e)},e.getValues=function(){var t=this;return function(t,i,s){return void 0===s&&(s=0),Fi(t).reduce((function(s,e){return i(s,t[e],e)}),s)}(oo,(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}),{})},e.setValues=function(t){var i=this;Di(oo,(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)}))},e.setDefaults=function(){var t=this;Di(oo,(function(i){var s=i.hasOwnProperty("default")?i.default:0;t.$(i.selector).selectedIndex=s}))},e.restoreSettings=function(){var i;try{i=JSON.parse(t.localStorage.getItem(Jh))}catch(t){Ui.warn(t)}i&&this.setValues(i)},e.saveSettings=function(){if(this.h.persistTextTrackSettings){var i=this.getValues();try{w.keys(i).length?t.localStorage.setItem(Jh,JSON.stringify(i)):t.localStorage.removeItem(Jh)}catch(t){Ui.warn(t)}}},e.updateDisplay=function(){var t=this.t.getChild("textTrackDisplay");t&&t.updateDisplay()},s}(i);i.registerComponent("TextTrackSettings",co);var lo,fo=function(i){function s(t,s){var e;e=i.call(this,t,s)||this;var n=t.source,r=!1;if(n&&(e.v.currentSrc!==n.src||t.tag&&3===t.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")||!Re(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=oe(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&&Ui.warn(qi(uo||(uo=Pi(["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=he(ce(e),e.handleTextTrackChange),e.hi=he(ce(e),e.handleTextTrackAdd),e.oi=he(ce(e),e.handleTextTrackRemove),e.ai()),e.ci(),(zs||js||Bs)&&!0===t.nativeControlsForTouch&&e.setControls(!0),e.di(),e.triggerReady(),e}de(s,i);var e=s.prototype;return e.dispose=function(){var t=this;["audio","video","text"].forEach((function(i){var s=oe(i),e=t.v[i+"Tracks"];e&&e.removeEventListener&&(e.removeEventListener("change",t["handle"+s+"ti"]),e.removeEventListener("addtrack",t["handle"+s+"ii"]),e.removeEventListener("removetrack",t["handle"+s+"si"])),e&&t.off("loadstart",t["removeOld"+s+"ei"])})),s.disposeMediaElement(this.v),i.prototype.dispose.call(this)},e.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)}))},e.createEl=function(){var t=this.h.tag;if(!t||!this.h.playerElIngest&&!this.movingMediaElementInDOM){if(t){var i=t.cloneNode(!0);t.parentNode&&t.parentNode.insertBefore(i,t),s.disposeMediaElement(t),t=i}else{t=Ai.createElement("video");var e=ae({},this.h.tag&&cs(this.h.tag));zs&&!0===this.h.nativeControlsForTouch||delete e.controls,us(t,$i(e,{id:this.h.techId,class:"vjs-tech"}))}t.playerId=this.h.playerId}void 0!==this.h.preload&&ls(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?ls(t,h,h):ds(t,h),t[h]=o)}return t},e.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)}))}},e.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.fi)}},e.handleTextTrackChange=function(t){var i=this.textTracks();this.textTracks().trigger({type:"change",target:i,currentTarget:i,srcElement:i})},e.handleTextTrackAdd=function(t){this.textTracks().tt(t.track)},e.handleTextTrackRemove=function(t){this.textTracks().it(t.track)},e.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)}}},e.fi=function(t){var i=this.textTracks(),s=this.el().textTracks;this.ni(i,s)},e.play=function(){var t=this.v.play();void 0!==t&&"function"==typeof t.then&&t.then(null,(function(t){}))},e.setCurrentTime=function(t){try{this.v.currentTime=t}catch(t){Ui(t,"Video is not ready. (Video.js)")}},e.duration=function(){var t=this;if(this.v.duration===1/0&&Ps&&Ds&&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},e.width=function(){return this.v.offsetWidth},e.height=function(){return this.v.offsetHeight},e.di=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)}))}},e.supportsFullScreen=function(){if("function"==typeof this.v.webkitEnterFullScreen){var i=t.navigator&&t.navigator.userAgent||"";if(/Android/.test(i)||!/Chrome|Mac OS X 10.5/.test(i))return!0}return!1},e.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()},e.exitFullScreen=function(){this.v.webkitExitFullScreen()},e.src=function(t){if(void 0===t)return this.v.src;this.setSrc(t)},e.reset=function(){s.resetMediaElement(this.v)},e.currentSrc=function(){return this.bt?this.bt.src:this.v.currentSrc},e.setControls=function(t){this.v.controls=!!t},e.addTextTrack=function(t,s,e){return this.featuresNativeTextTracks?this.v.addTextTrack(t,s,e):i.prototype.addTextTrack.call(this,t,s,e)},e.createRemoteTextTrack=function(t){if(!this.featuresNativeTextTracks)return i.prototype.createRemoteTextTrack.call(this,t);var s=Ai.createElement("track");return t.kind&&(s.kind=t.kind),t.label&&(s.label=t.label),(t.language||t.srclang)&&(s.srclang=t.language||t.srclang),t.default&&(s.default=t.default),t.id&&(s.id=t.id),t.src&&(s.src=t.src),s},e.addRemoteTextTrack=function(t,s){var e=i.prototype.addRemoteTextTrack.call(this,t,s);return this.featuresNativeTextTracks&&this.el().appendChild(e),e},e.removeRemoteTextTrack=function(t){if(i.prototype.removeRemoteTextTrack.call(this,t),this.featuresNativeTextTracks)for(var s=this.$$("track"),e=s.length;e--;)t!==s[e]&&t!==s[e].track||this.el().removeChild(s[e])},e.getVideoPlaybackQuality=function(){if("function"==typeof this.el().getVideoPlaybackQuality)return this.el().getVideoPlaybackQuality();var i={};return void 0!==this.el().webkitDroppedFrameCount&&void 0!==this.el().webkitDecodedFrameCount&&(i.droppedVideoFrames=this.el().webkitDroppedFrameCount,i.totalVideoFrames=this.el().webkitDecodedFrameCount),t.performance&&"function"==typeof t.performance.now?i.creationTime=t.performance.now():t.performance&&t.performance.timing&&"number"==typeof t.performance.timing.navigationStart&&(i.creationTime=t.Date.now()-t.performance.timing.navigationStart),i},s}(Wr);Xi()&&(fo.TEST_VID=Ai.createElement("video"),(lo=Ai.createElement("track")).kind="captions",lo.srclang="en",lo.label="English",fo.TEST_VID.appendChild(lo)),fo.isSupported=function(){try{fo.TEST_VID.volume=.5}catch(t){return!1}return!(!fo.TEST_VID||!fo.TEST_VID.canPlayType)},fo.canControlVolume=function(){try{var t=fo.TEST_VID.volume;return fo.TEST_VID.volume=t/2+.1,t!==fo.TEST_VID.volume}catch(t){return!1}},fo.canControlPlaybackRate=function(){if(Ps&&Ds&&$s<58)return!1;try{var t=fo.TEST_VID.playbackRate;return fo.TEST_VID.playbackRate=t/2+.1,t!==fo.TEST_VID.playbackRate}catch(t){return!1}},fo.supportsNativeTextTracks=function(){return Us},fo.supportsNativeVideoTracks=function(){return!(!fo.TEST_VID||!fo.TEST_VID.videoTracks)},fo.supportsNativeAudioTracks=function(){return!(!fo.TEST_VID||!fo.TEST_VID.audioTracks)},fo.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange"],fo.prototype.featuresVolumeControl=fo.canControlVolume(),fo.prototype.featuresPlaybackRate=fo.canControlPlaybackRate(),fo.prototype.movingMediaElementInDOM=!Ms,fo.prototype.featuresFullscreenResize=!0,fo.prototype.featuresProgressEvents=!0,fo.prototype.featuresTimeupdateEvents=!0,fo.prototype.featuresNativeTextTracks=fo.supportsNativeTextTracks(),fo.prototype.featuresNativeVideoTracks=fo.supportsNativeVideoTracks(),fo.prototype.featuresNativeAudioTracks=fo.supportsNativeAudioTracks();var vo=fo.TEST_VID&&fo.TEST_VID.constructor.prototype.canPlayType,po=/^application\/(?:x-|vnd\.apple\.)mpegurl/i,mo=/^video\/mp4/i;fo.patchCanPlayType=function(){Es>=4&&!Is?fo.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&po.test(t)?"maybe":vo.call(this,t)}:Ns&&(fo.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&mo.test(t)?"maybe":vo.call(this,t)})},fo.unpatchCanPlayType=function(){var t=fo.TEST_VID.constructor.prototype.canPlayType;return fo.TEST_VID.constructor.prototype.canPlayType=vo,t},fo.patchCanPlayType(),fo.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){}}()}}},fo.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){fo.prototype[t]=function(){return this.v[t]||this.v.hasAttribute(t)}})),["muted","defaultMuted","autoplay","loop","playsinline"].forEach((function(t){fo.prototype["set"+oe(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){fo.prototype[t]=function(){return this.v[t]}})),["volume","src","poster","preload","playbackRate"].forEach((function(t){fo.prototype["set"+oe(t)]=function(i){this.v[t]=i}})),["pause","load"].forEach((function(t){fo.prototype[t]=function(){return this.v[t]()}})),Wr.withSourceHandlers(fo),fo.nativeSourceHandler={},fo.nativeSourceHandler.canPlayType=function(t){try{return fo.TEST_VID.canPlayType(t)}catch(t){return""}},fo.nativeSourceHandler.canHandleSource=function(t,i){if(t.type)return fo.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 fo.nativeSourceHandler.canPlayType("video/"+s)}return""},fo.nativeSourceHandler.handleSource=function(t,i,s){i.setSrc(t.src)},fo.nativeSourceHandler.dispose=function(){},fo.registerSourceHandler(fo.nativeSourceHandler),i.registerComponent("Html5",fo),Wr.registerTech("Html5",fo);var go=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","ratechange","volumechange","texttrackchange"],yo=function(s){function e(t,i,n){var r;if(t.id=t.id||["vjs_video",Ni()].join("_"),(i=$i(e.getTagSettings(t),i)).initChildren=!1,i.createEl=!1,i.reportTouchActivity=!1,!i.language)if("function"==typeof t.closest){var h=t.closest("[lang]");h&&(i.language=h.getAttribute("lang"))}else for(var o=t;o&&1===o.nodeType;){if(cs(o).hasOwnProperty("lang")){i.language=o.getAttribute("lang");break}o=o.parentNode}if(!(r=s.call(this,null,i,n)||this).h||!r.h.techOrder||!r.h.techOrder.length)throw new g("No techOrder specified. Did you overwrite videojs.options instead of just changing the properties you want to override?");if(r.tag=t,r.tagAttributes=t&&cs(t),r.language(r.h.language),i.languages){var a={};w.getOwnPropertyNames(i.languages).forEach((function(t){a[t.toLowerCase()]=i.languages[t]})),r.vi=a}else r.vi=e.prototype.h.languages;r.pi={},r.mi=i.poster||"",r.gi=!!i.controls,t.controls=!1,r.yi=!1,r.v=r.createEl();var u=ae(r.h);if(i.plugins){var c=i.plugins;w.getOwnPropertyNames(c).forEach((function(t){"function"==typeof this[t]?this[t](c[t]):Ui.error("Unable to find plugin:",t)}),ce(r))}r.h.playerOptions=u,r.initChildren(),r.isAudio("audio"===t.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"),Ms||r.addClass("vjs-workinghover"),e.players[r.o]=ce(r);var l="5.20.6-opentelly.14".split(".")[0];return r.addClass("vjs-v"+l),r.userActive(!0),r.reportUserActivity(),r.ki(),r.on("fullscreenchange",r.wi),r.on("stageclick",r._i),r}de(e,s);var n=e.prototype;return n.dispose=function(){this.trigger("dispose"),this.off("dispose"),this.xi&&this.xi.parentNode&&this.xi.parentNode.removeChild(this.xi),e.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(),s.prototype.dispose.call(this)},n.createEl=function(){var i,e=this.tag,n=this.Ci=e.parentNode&&e.parentNode.hasAttribute&&e.parentNode.hasAttribute("data-vjs-player");i=this.v=n?e.parentNode:s.prototype.createEl.call(this,"div"),e.setAttribute("tabindex","-1"),e.removeAttribute("width"),e.removeAttribute("height");var r=cs(e);if(w.getOwnPropertyNames(r).forEach((function(t){"class"===t?i.className+=" "+r[t]:i.setAttribute(t,r[t])})),e.playerId=e.id,e.id+="Si",e.className="vjs-tech",e.player=i.player=this,this.addClass("vjs-paused"),!0!==t.VIDEOJS_NO_DYNAMIC_STYLE){this.xi=ne("vjs-styles-dimensions");var h=ks(".vjs-styles-defaults"),o=ks("head");o.insertBefore(this.xi,h?h.nextSibling:o.firstChild)}this.width(this.h.width),this.height(this.h.height),this.fluid(this.h.fluid),this.aspectRatio(this.h.aspectRatio);for(var a=e.getElementsByTagName("a"),u=0;u<a.length;u++){var c=a.item(u);hs(c,"vjs-hidden"),c.setAttribute("hidden","hidden")}return e.Kt=e.networkState,e.parentNode&&!n&&e.parentNode.insertBefore(i,e),Zi(e,i),this.m.unshift(e),this.v=i,i},n.width=function(t){return this.dimension("width",t)},n.height=function(t){return this.dimension("height",t)},n.dimension=function(t,i){var s="width"===t?"ji":"Ti";if(void 0===i)return this[s]||0;if(""===i)this[s]=void 0;else{var e=C(i);if(S(e))return Ui.error('Improper value "'+i+'" supplied for for '+t),this;this[s]=e}return this.Mi(),this},n.fluid=function(t){if(void 0===t)return!!this.Ai;this.Ai=!!t,t?this.addClass("vjs-fluid"):this.removeClass("vjs-fluid"),this.Mi()},n.aspectRatio=function(t){if(void 0===t)return this.Pi;if(!/^\d+\:\d+$/.test(t))throw new g("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.Pi=t,this.fluid(!0),this.Mi()},n.Mi=function(){if(!0!==t.VIDEOJS_NO_DYNAMIC_STYLE){var i,s,e,n=(void 0!==this.Pi&&"auto"!==this.Pi?this.Pi:this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9").split(":"),r=n[1]/n[0];i=void 0!==this.ji?this.ji:void 0!==this.Ti?this.Ti/r:this.videoWidth()||300,s=void 0!==this.Ti?this.Ti:i*r,e=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(e),re(this.xi,"\n ."+e+" {\n width: "+i+"px;\n height: "+s+"px;\n }\n\n ."+e+".vjs-fluid {\n padding-top: "+100*r+"%;\n }\n ")}else{var h="number"==typeof this.ji?this.ji:this.h.width,o="number"==typeof this.Ti?this.Ti:this.h.height,a=this.H&&this.H.el();a&&(h>=0&&(a.width=h),o>=0&&(a.height=o))}},n._t=function(t,s){var e=this;this.H&&this.Ei(),"Html5"!==t&&this.tag&&(Wr.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.Ni=t,this.j=!1;var n=$i({source:s,nativeControlsForTouch:this.h.nativeControlsForTouch,playerId:this.id(),techId:this.id()+"_"+t+"Bi",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.Ci||!1,"vtt.js":this.h["vtt.js"]},this.h[t.toLowerCase()]);this.tag&&(n.tag=this.tag),s&&(this.Ii=s.type,s.src===this.pi.src&&this.pi.currentTime>0&&(n.startTime=this.pi.currentTime),this.pi.sources=null,this.pi.source=s,this.pi.src=s.src);var r=Wr.getTech(t);r||(r=i.getComponent(t)),this.H=new r(n),this.H.ready(he(this,this.Fi),!0),Me(this.Di||[],this.H),go.forEach((function(t){e.on(e.H,t,e["handleTech"+oe(t)+"_"])})),this.on(this.H,"loadstart",this.$i),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.Ui),this.on(this.H,"ended",this.zi),this.on(this.H,"seeking",this.Li),this.on(this.H,"seeked",this.Hi),this.on(this.H,"play",this.qi),this.on(this.H,"firstplay",this.Wi),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.Mi),this.on(this.H,"resize",this.Mi),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||Zi(this.H.el(),this.contentEl()),this.tag&&(this.tag.player=null,this.tag=null)},n.Ei=function(){this.rt=this.videoTracks(),this.nt=this.textTracks(),this.ht=this.audioTracks(),this.Di=Te(this.H),this.j=!1,this.H.dispose(),this.H=!1},n.tech=function(i){if(i&&i.IWillNotUseThisInPlugins)return this.H;var s="\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 t.alert(s),new g(s)},n.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)},n.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)},n.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){Ui("deleting tag.poster throws in some browsers",t)}this.play()}},n.$i=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"))},n.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},n.qi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},n.Ri=function(){var t=this;this.addClass("vjs-waiting"),this.trigger("waiting"),this.one("timeupdate",(function(){return t.removeClass("vjs-waiting")}))},n.Oi=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},n.Vi=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},n.Ui=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},n.Li=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},n.Hi=function(){this.removeClass("vjs-seeking"),this.trigger("seeked")},n.Wi=function(){this.h.starttime&&(Ui.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")},n.Gi=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},n.zi=function(){this.addClass("vjs-ended"),this.h.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},n.Xi=function(){this.duration(this.Zi("duration"))},n.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()))},n.os=function(){this.userActive(!this.userActive())},n.ns=function(){this.userWasActive=this.userActive()},n.rs=function(){this.userWasActive&&this.reportUserActivity()},n.hs=function(t){t.cancelable&&t.preventDefault()},n.wi=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},n._i=function(){this.reportUserActivity()},n.Ji=function(t,i){i&&(this.toggleClass("vjs-ios-native-fs",!(!i.nativeIOSFullscreen||!i.isFullscreen)),this.isFullscreen(i.isFullscreen)),this.trigger("fullscreenchange")},n.Qi=function(){var t=this.H.error();this.error(t)},n.Ki=function(){var t=null;arguments.length>1&&(t=arguments[1]),this.trigger("textdata",t)},n.getCache=function(){return this.pi},n.us=function(t,i){if(this.H&&!this.H.j)this.H.ready((function(){this[t](i)}),!0);else try{this.H&&this.H[t](i)}catch(t){throw Ui(t),t}},n.Zi=function(t){if(this.H&&this.H.j)try{return this.H[t]()}catch(i){throw void 0===this.H[t]?Ui("Video.js: "+t+" method not defined for "+this.Ni+" playback technology.",i):"TypeError"===i.name?(Ui("Video.js: "+t+" unavailable on "+this.Ni+" playback technology element.",i),this.H.j=!1):Ui(i),i}},n.play=function(){return this.src()||this.currentSrc()?this.us("play"):this.H.one("loadstart",(function(){this.play()})),this},n.pause=function(){return this.us("pause"),this},n.paused=function(){return!1!==this.Zi("paused")},n.scrubbing=function(t){return void 0!==t?(this.yi=!!t,t?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing"),this):this.yi},n.currentTime=function(t){return void 0!==t?(this.us("setCurrentTime",t),this):(this.pi.currentTime=this.Zi("currentTime")||0,this.pi.currentTime)},n.duration=function(t){return void 0===t?void 0!==this.pi.duration?this.pi.duration:NaN:((t=C(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)},n.remainingTime=function(){return this.duration()-this.currentTime()},n.buffered=function(){var t=this.Zi("buffered");return t&&t.length||(t=pe(0,0)),t},n.bufferedPercent=function(){return me(this.buffered(),this.duration())},n.bufferedEnd=function(){var t=this.buffered(),i=this.duration(),s=t.end(t.length-1);return s>i&&(s=i),s},n.volume=function(t){var i;return void 0!==t?(i=_.max(0,_.min(1,C(t))),this.pi.volume=i,this.us("setVolume",i),this):(i=C(this.Zi("volume")),S(i)?1:i)},n.muted=function(t){return void 0!==t?(this.us("setMuted",t),this):this.Zi("muted")||!1},n.supportsFullScreen=function(){return this.Zi("supportsFullScreen")||!1},n.isFullscreen=function(t){return void 0!==t?(this.cs=!!t,this):!!this.cs},n.requestFullscreen=function(t){var i,s=we;return this.isFullscreen(!0),s.requestFullscreen?(Qs(Ai,s.fullscreenchange,he(this,(function t(i){this.isFullscreen(Ai[s.fullscreenElement]),!1===this.isFullscreen()&&Ys(Ai,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},n.exitFullscreen=function(){var t=we;return this.isFullscreen(!1),t.requestFullscreen?Ai[t.exitFullscreen]():this.H.supportsFullScreen()?this.us("exitFullScreen"):(this.exitFullWindow(),this.trigger("fullscreenchange")),this},n.enterFullWindow=function(){this.isFullWindow=!0,this.docOrigOverflow=Ai.documentElement.style.overflow,Qs(Ai,"keydown",he(this,this.fullWindowOnEscKey)),Ai.documentElement.style.overflow="hidden",hs(Ai.body,"vjs-full-window"),this.trigger("enterFullWindow")},n.fullWindowOnEscKey=function(t){27===t.keyCode&&(!0===this.isFullscreen()?this.exitFullscreen():this.exitFullWindow())},n.exitFullWindow=function(){this.isFullWindow=!1,Ys(Ai,"keydown",this.fullWindowOnEscKey),Ai.documentElement.style.overflow=this.docOrigOverflow,os(Ai.body,"vjs-full-window"),this.trigger("exitFullWindow")},n.canPlayType=function(t){for(var s,e=0,n=this.h.techOrder;e<n.length;e++){var r=oe(n[e]),h=Wr.getTech(r);if(h||(h=i.getComponent(r)),h){if(h.isSupported()&&(s=h.canPlayType(t)))return s}else Ui.error('The "'+r+'" tech is undefined. Skipped browser support check for that tech.')}return""},n.selectSource=function(t){var s,e=this,n=this.h.techOrder.map(oe).map((function(t){return[t,Wr.getTech(t)||i.getComponent(t)]})).filter((function(t){var i=t[0],s=t[1];return s?s.isSupported():(Ui.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 s=t[0];if(t[1].canPlaySource(i,e.h[s.toLowerCase()]))return{source:i,tech:s}};return(this.h.sourceOrder?r(t,n,(s=h,function(t,i){return s(i,t)})):r(n,t,h))||!1},n.src=function(t){if(void 0===t)return this.Zi("src");var s=Wr.getTech(this.Ni);return s||(s=i.getComponent(this.Ni)),Array.isArray(t)?this.ls(t):"string"==typeof t?this.src({src:t}):t instanceof w&&(t.type&&!s.canPlaySource(t,this.h[this.Ni.toLowerCase()])?this.ls([t]):(this.pi.sources=null,this.pi.source=t,this.pi.src=t.src,this.Ii=t.type||"",this.ready((function(){s.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},n.ls=function(t){var i=this.selectSource(t);i?(i.tech===this.Ni?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())},n.load=function(){return this.us("load"),this},n.reset=function(){return this._t(oe(this.h.techOrder[0]),null),this.us("reset"),this},n.currentSources=function(){var t=this.currentSource(),i=[];return 0!==w.keys(t).length&&i.push(t),this.pi.sources||i},n.currentSource=function(){var t={},i=this.currentSrc();return i&&(t.src=i),this.pi.source||t},n.currentSrc=function(){return this.Zi("currentSrc")||this.pi.src||""},n.currentType=function(){return this.Ii||""},n.preload=function(t){return void 0!==t?(this.us("setPreload",t),this.h.preload=t,this):this.Zi("preload")},n.autoplay=function(t){return void 0!==t?(this.us("setAutoplay",t),this.h.autoplay=t,this):this.Zi("autoplay",t)},n.playsinline=function(t){return void 0!==t?(this.us("setPlaysinline",t),this.h.playsinline=t,this):this.Zi("playsinline")},n.loop=function(t){return void 0!==t?(this.us("setLoop",t),this.h.loop=t,this):this.Zi("loop")},n.poster=function(t){return void 0===t?this.mi:(t||(t=""),this.mi=t,this.us("setPoster",t),this.trigger("posterchange"),this)},n.Yi=function(){!this.mi&&this.H&&this.H.poster&&(this.mi=this.H.poster()||"",this.trigger("posterchange"))},n.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},n.usingNativeControls=function(t){return void 0!==t?(t=!!t,this.ds!==t&&(this.ds=t,t?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols"))),this):!!this.ds},n.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 Ce(t),this.addClass("vjs-error"),Ui.error("(CODE:"+this.lt.code+" "+Ce.errorTypes[this.lt.code]+")",this.lt.message,this.lt),this.trigger("error"),this)},n.reportUserActivity=function(t){this.fs=!0},n.userActive=function(t){return void 0!==t?((t=!!t)!==this.vs&&(this.vs=t,t?(this.fs=!0,this.removeClass("vjs-user-inactive"),this.addClass("vjs-user-active"),this.trigger("useractive")):(this.fs=!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},n.ki=function(){var t,i,s,e,n=he(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.fs){this.fs=!1,this.userActive(!0),this.clearTimeout(e);var t=this.h.inactivityTimeout;t>0&&(e=this.setTimeout((function(){this.fs||this.userActive(!1)}),t))}}),250)},n.playbackRate=function(t){return void 0!==t?(this.us("setPlaybackRate",t),this):this.H&&this.H.featuresPlaybackRate?this.Zi("playbackRate"):1},n.isAudio=function(t){return void 0!==t?(this.ps=!!t,this):!!this.ps},n.videoTracks=function(){return this.H?this.H.videoTracks():(this.rt=this.rt||new zr,this.rt)},n.audioTracks=function(){return this.H?this.H.audioTracks():(this.ht=this.ht||new Hr,this.ht)},n.textTracks=function(){if(this.H)return this.H.textTracks()},n.remoteTextTracks=function(){if(this.H)return this.H.remoteTextTracks()},n.remoteTextTrackEls=function(){if(this.H)return this.H.remoteTextTrackEls()},n.addTextTrack=function(t,i,s){if(this.H)return this.H.addTextTrack(t,i,s)},n.addRemoteTextTrack=function(t,i){if(this.H)return this.H.addRemoteTextTrack(t,i)},n.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)},n.getVideoPlaybackQuality=function(){return this.Zi("getVideoPlaybackQuality")},n.videoWidth=function(){return this.H&&this.H.videoWidth&&this.H.videoWidth()||0},n.videoHeight=function(){return this.H&&this.H.videoHeight&&this.H.videoHeight()||0},n.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)},n.languages=function(){return ae(e.prototype.h.languages,this.vi)},n.toJSON=function(){var t=ae(this.h),i=t.tracks;t.tracks=[];for(var s=0;s<i.length;s++){var e=i[s];(e=ae(e)).player=void 0,t.tracks[s]=e}return t},n.createModal=function(t,i){var s=this;(i=i||{}).content=t||"";var e=new Pe(this,i);return this.addChild(e),e.on("dispose",(function(){s.removeChild(e)})),e.open()},e.getTagSettings=function(t){var i={sources:[],tracks:[]},s=cs(t),e=s["data-setup"];if(rs(t,"vjs-fluid")&&(s.fluid=!0),null!==e){var n=Se(e||"{}"),r=n[0],h=n[1];r&&Ui.error(r),$i(s,h)}if($i(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(cs(c)):"track"===l&&i.tracks.push(cs(c))}return i},n.bi=function(){var t=Ai.createElement("i");return!("flexBasis"in t.style||"webkitFlexBasis"in t.style||"mozFlexBasis"in t.style||"msFlexBasis"in t.style||"msFlexOrder"in t.style)},e}(i);yo.players={};var bo=t.navigator;yo.prototype.h={techOrder:["html5","flash"],html5:{},flash:{},defaultVolume:0,inactivityTimeout:2e3,playbackRates:[],children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","controlBar","errorDisplay","textTrackSettings"],language:bo&&(bo.languages&&bo.languages[0]||bo.userLanguage||bo.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",fullscreenOptions:{navigationUI:"hide"}},["ended","seeking","seekable","networkState","readyState"].forEach((function(t){yo.prototype[t]=function(){return this.Zi(t)}})),go.forEach((function(t){yo.prototype["handleTech"+oe(t)+"_"]=function(){return this.trigger(t)}})),i.registerComponent("Player",yo);var ko,wo,_o=function(t){function i(s){var e;void 0===s&&(s={});var n=ae(s,{kind:Be[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(Rs)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return w.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.W=!0,r||ce(e)}return de(i,t),i}(De),xo=function(t){function i(s){var e;void 0===s&&(s={});var n=ae(s,{kind:Ne[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(Rs)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return w.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 de(i,t),i}(De);function Co(t,s,e){var n;if("string"==typeof t){if(0===t.indexOf("#")&&(t=t.slice(1)),Co.getPlayers()[t])return s&&Ui.warn('Player "'+t+'" is already initialised. Options will not be applied.'),e&&Co.getPlayers()[t].ready(e),Co.getPlayers()[t];n=function(t){return 0===t.indexOf("#")&&(t=t.slice(1)),Ai.getElementById(t)}(t)}else n=t;if(!n||!n.nodeName)throw new b("The element or ID supplied is not valid. (videojs)");if(n.player||yo.players[n.playerId])return n.player||yo.players[n.playerId];s=s||{},Co.hooks("beforesetup").forEach((function(t){var i=t(n,ae(s));Ri(i)&&!Array.isArray(i)?s=ae(s,i):Ui.error("please return an object in beforesetup hooks")}));var r=new(i.getComponent("Player"))(n,s,e);return Co.hooks("setup").forEach((function(t){return t(r)})),r}"undefined"==typeof HTMLVideoElement&&Xi()&&(Ai.createElement("video"),Ai.createElement("audio"),Ai.createElement("track")),Co.ys={},Co.hooks=function(t,i){return Co.ys[t]=Co.ys[t]||[],i&&(Co.ys[t]=Co.ys[t].concat(i)),Co.ys[t]},Co.hook=function(t,i){Co.hooks(t,i)},Co.removeHook=function(t,i){var s=Co.hooks(t).indexOf(i);return!(s<=-1)&&(Co.ys[t]=Co.ys[t].slice(),Co.ys[t].splice(s,1),!0)},!0!==t.VIDEOJS_NO_DYNAMIC_STYLE&&Xi()&&((ko=ks(".vjs-styles-defaults"))||(ko=ne("vjs-styles-defaults"),(wo=ks("head"))&&wo.insertBefore(ko,wo.firstChild),re(ko,"\n .video-js {\n width: 300px;\n height: 150px;\n }\n\n .vjs-fluid {\n padding-top: 56.25%\n }\n "))),ee(1,Co),Co.VERSION="5.20.6-opentelly.14",Co.options=yo.prototype.h,Co.getPlayers=function(){return yo.players},Co.players=yo.players,Co.getComponent=i.getComponent,Co.registerComponent=function(t,s){Wr.isTech(s)&&Ui.warn("The "+t+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),i.registerComponent.call(i,t,s)},Co.getTech=Wr.getTech,Co.registerTech=Wr.registerTech,Co.browser=Hs,Co.TOUCH_ENABLED=zs,Co.extend=function(t,i){void 0===i&&(i={});var s=function(){t.apply(this,arguments)},e={};for(var n in Ri(i)?("function"==typeof i.init&&(Ui.warn("Constructor logic via init() is deprecated; please use constructor() instead."),i.constructor=i.init),i.constructor!==w.prototype.constructor&&(s=i.constructor),e=i):"function"==typeof i&&(s=i),function(t,i){if("function"!=typeof i&&null!==i)throw new b("Super expression must either be null or a function, not "+typeof i);t.prototype=w.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},Co.mergeOptions=ae,Co.bind=he,Co.plugin=function(t,i){yo.prototype[t]=i},Co.addLanguage=function(t,i){var s;return t=(""+t).toLowerCase(),Co.options.languages=ae(Co.options.languages,((s={})[t]=i,s)),Co.options.languages[t]},Co.log=Ui,Co.createTimeRange=Co.createTimeRanges=pe,Co.formatTime=hh,Co.parseUrl=$e,Co.isCrossOrigin=Re,Co.EventTarget=ue,Co.on=Qs,Co.one=Zs,Co.off=Ys,Co.trigger=Ks,Co.xhr=Pr,Co.TextTrack=Fr,Co.AudioTrack=_o,Co.VideoTrack=xo,Co.isEl=Ji,Co.isTextNode=ps,Co.createEl=Yi,Co.hasClass=rs,Co.addClass=hs,Co.removeClass=os,Co.toggleClass=as,Co.setAttributes=us,Co.getAttributes=cs,Co.emptyEl=ms,Co.appendContent=gs,Co.insertContent=ys,Co.computedStyle=fh;var So=10;function jo(t){const i=t.duration;if(S(i)){var s;const i=null==(s=t.source)?void 0:s.streamType;return"live"===i||"dvr"===i}return i===1/0}function To(t){return t.scrubbing()?t.getCache().currentTime:t.currentTime()}function Mo(t){const i=Eo(t);return jo(t)?i.end(i.length-1):i.start(0)}function Ao(t){return Eo(t).start(0)}function Po(t){const i=Eo(t);return i.end(i.length-1)-i.start(0)}function Eo(t){const i=t.seekable;if(i&&i.length)return i;let s=t.duration;return s=isFinite(s)?s:0,new Nt([0,s]).ks()}function No(t,i){void 0===i&&(i=t);let s=t<0?"-":"";t=_.abs(t);let e=_.floor(t%60),n=_.floor(t/60%60),r=_.floor(t/3600);const h=_.floor(i/60%60),o=_.floor(i/3600);return(S(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 Bo(t){return class extends t{get ws(){var t;return null!=(t=this._s)?t:this._s=Io(this.player())}dispose(){this._s=void 0,super.dispose()}constructor(...t){super(...t),this._s=void 0}}}function Io(t){return t.tech({IWillNotUseThisInPlugins:!0}).theoplayer()}function Fo(t){const i=Io(t),s=()=>{const s=To(t);t.toggleClass("theo-at-live",function(t,i){if(jo(t)){let s=t.seekable;return 0===s.length||s.end(s.length-1)-i<So}return!1}(i,s)),t.toggleClass("vjs-live",jo(i)),t.toggleClass("theo-dvr",function(t){var i;return"dvr"===vt(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 Do="theo-ad-playing",$o="theo-dai-ad-playing";function Ro(t,i,s){t.toggleClass(Do,i),t.toggleClass($o,i&&s)}function Oo(){this.userActive(!1)}var Vo=class{constructor(t,i){this.type=t.type,this.target=i,this.playerEvent=t}},Uo=["loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange","resize"],zo=Co.getTech("Tech"),Lo=Co.getTech("Html5"),Ho=class extends zo{xs(){var t;for(const t of Uo)this.ws.addEventListener(t,this.Cs);this.ws.addEventListener("error",this.Ss),this.ws.addEventListener("contentprotectionerror",this.Ss),this.ws.addEventListener("sourcechange",this.js),this.ws.addEventListener("loadstart",this.Ts),null==(t=this.ws.presentation)||t.addEventListener("presentationmodechange",this.Ms),this.ws.textTracks.addEventListener("addtrack",this.As),this.ws.textTracks.addEventListener("removetrack",this.Ps),this.ws.textTracks.addEventListener("change",this.Es),this.ws.audioTracks.addEventListener("addtrack",this.Ns),this.ws.audioTracks.addEventListener("removetrack",this.Bs),this.ws.audioTracks.addEventListener("change",this.Is)}Fs(){var t;for(const t of Uo)this.ws.removeEventListener(t,this.Cs);this.ws.removeEventListener("error",this.Ss),this.ws.removeEventListener("contentprotectionerror",this.Ss),this.ws.removeEventListener("sourcechange",this.js),this.ws.removeEventListener("loadstart",this.Ts),null==(t=this.ws.presentation)||t.removeEventListener("presentationmodechange",this.Ms),this.ws.textTracks.removeEventListener("addtrack",this.As),this.ws.textTracks.removeEventListener("removetrack",this.Ps),this.ws.textTracks.removeEventListener("change",this.Es),this.ws.audioTracks.removeEventListener("addtrack",this.Ns),this.ws.audioTracks.removeEventListener("removetrack",this.Bs),this.ws.audioTracks.removeEventListener("change",this.Is)}Ds(t){this.trigger(new Vo(t,this))}createEl(){let t=this.h,i=t.player;if(!i)throw new g(this.localize('Missing required tech option "player"'));let s=i.element;return Co.setAttributes(s,{id:t.techId}),s}theoplayer(){return this.ws}addTextTrack(t,i,s){return super.addTextTrack(t,i,s)}buffered(){return this.ws.buffered}played(){return this.ws.played}reset(){this.ws.stop()}play(){this.ws.play()}pause(){this.ws.pause()}paused(){return this.ws.paused}currentTime(){return this.ws.currentTime}setCurrentTime(t){this.ws.currentTime=t}duration(){return this.ws.duration}volume(){return this.ws.volume}setVolume(t){this.ws.volume=t}muted(){return this.ws.muted}setMuted(t){this.ws.muted=t}src(t){if(void 0!==t)this.setSrc(t);else{if(this.ws.src)return this.ws.src;if(this.ws.source){if(!Xt(this.ws.source.ads))return this.ws.source.ads[0].sources;if(jt(this.ws.source))return"This source is managed by the Verizon Media integration extension.";if(Ct(this.ws.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.ws.src}load(){this.setPreload("auto")}preload(){return this.ws.preload}setPreload(t){this.ws.preload=t}autoplay(){return this.ws.autoplay}setAutoplay(t){this.ws.autoplay=!!t}seeking(){return this.ws.seeking}seekable(){return this.ws.seekable}ended(){return this.ws.ended}playbackRate(){return this.ws.playbackRate}setPlaybackRate(t){this.ws.playbackRate=t}readyState(){return this.ws.readyState}networkState(){return 0}controls(){return!1}videoHeight(){return this.ws.videoHeight}videoWidth(){return this.ws.videoWidth}supportsFullScreen(){return this.ws.presentation.supportsMode(Vt.FULLSCREEN)}enterFullScreen(){this.ws.presentation.requestMode(Vt.FULLSCREEN)}exitFullScreen(){this.ws.presentation.requestMode(Vt.INLINE)}$s(){let t=this.ws.ads;if(t&&t.playing)return!0;let i=this.ws.vr;return!(!i||i.state===yt.Rs)}initTextTrackListeners(){return this.on("touchend",(t=>{this.$s()&&(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.Fs(),this.ws=null,super.dispose()}static isSupported(){return!0}static canPlayType(){return"maybe"}static canPlaySource(t){return"maybe"}get featuresVolumeControl(){return li}constructor(t={},i){super(t,i),this.Cs=t=>this.Ds(t),this.Os=!1,this.js=()=>{void 0===this.ws.errorObject&&(this.Ds(new T(this.ws.currentTime,this.ws.readyState)),this.Ds(new di),this.Ds(new Mt(this.ws.duration)))},this.Ts=()=>{this.Ds(new bt(this.ws.currentTime))},this.As=t=>{this.textTracks().tt(t.track)},this.Ns=t=>{this.audioTracks().tt(t.track)},this.Ps=t=>{this.textTracks().it(t.track)},this.Bs=t=>{this.audioTracks().it(t.track)},this.Es=()=>{let t=this.textTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Is=()=>{let t=this.audioTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Ms=()=>{if(!this.supportsFullScreen())return;let t=this.Os,i=this.ws.presentation.currentMode===Vt.FULLSCREEN;t!==i&&(this.Os=i,this.trigger("fullscreenchange",{isFullscreen:i,nativeIOSFullscreen:!0}))},this.Ss=()=>{const t=this.ws.errorObject,i=t&&et(t.code)||-1,s=t&&t.message||"An unknown error occurred.";this.error({code:i,message:this.localize(s)})},this.ws=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()}};Ho.prototype.featuresFullscreenResize=Lo.prototype.featuresFullscreenResize,Ho.prototype.featuresPlaybackRate=Lo.prototype.featuresPlaybackRate,Ho.prototype.featuresProgressEvents=!0,Ho.prototype.featuresTimeupdateEvents=!0,Ho.prototype.featuresNativeTextTracks=!0,Co.registerTech("THEOplayer",Ho);var qo=class{constructor(t){this.Vs=t=>{Yt(this.Us,"theo-mobile-button-hover"),t.stopImmediatePropagation()},this.zs=t=>{Zt(this.Us,"theo-mobile-button-hover")},this.Ls=t=>{this.Us.blur()},this.Us=t,t.addEventListener("touchstart",this.Vs),t.addEventListener("touchend",this.zs),t.addEventListener("focusin",this.Ls)}},Wo=Co.getComponent("Menu"),Go=class extends(Bo(Wo)){get Hs(){return this.player().el()}qs(){Yt(this.Hs,"theo-menu-opened")}Ws(){Zt(this.Hs,"theo-menu-opened")}constructor(t,i){super(t,i)}},Xo=Co.getComponent("MenuItem"),Jo=class extends(Bo(Xo)){get parentMenu(){return this.Gs}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.Xs||(this.parentMenu.Js(this),"tap"!==t.type&&"keydown"!==t.type||(this.Xs=!0,this.trigger("click"),this.Xs=!1))}dispose(){Tt.Ys.Qs&&(this.el().removeEventListener("touchstart",this.Vs),this.el().removeEventListener("touchend",this.zs)),super.dispose()}constructor(t,i,s){super(t,fi({selectable:!0},i)),this.Xs=!1,this.Vs=t=>{Yt(this.el(),"theo-mobile-menu-item-hover"),t.stopImmediatePropagation()},this.zs=t=>{Zt(this.el(),"theo-mobile-menu-item-hover")},this.Gs=s,Tt.Ys.Qs&&(this.el().addEventListener("touchstart",this.Vs),this.el().addEventListener("touchend",this.zs))}},Qo=Co.getComponent("ClickableComponent"),Yo=class extends Qo{get parentMenu(){return this.Gs}get Ks(){return this.Zs}set Ks(t){this.Zs=t,this.el().setAttribute("tabindex",this.Ks?"0":"-1"),this.te()}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.Xs&&this.Ks&&(this.Gs.ie(),"tap"===t.type&&(this.Xs=!0,this.trigger("click"),this.Xs=!1))}te(){this.Ks?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.Xs=!1,this.Zs=!1,this.Gs=s,this.on(t,"languagechange",this.te)}},Ko=class extends Go{get menuHeader(){return this.se}get menuItems(){return this.children()}addMenuItem(t){t=fi({playerOptions:this.h.playerOptions},t);let i=new Jo(this.player(),t,this);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}addSubMenuItem(t){t=fi({playerOptions:this.h.playerOptions},t);let i=this.ee(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"}qs(){super.qs(),s.removeEventListener("resize",this.ne),s.addEventListener("resize",this.ne),this.show()}re(){let t=this.he();if(!t)return;let i=t.getClientRects();Tt.Ys.Qs?this.oe(t,i):this.ae(t,i)}he(){var t;return null!=(t=this.contentEl().parentElement)?t:void 0}ae(t,i){}oe(t,i){}Ws(){s.removeEventListener("resize",this.ne),super.Ws(),this.hide(),Tt.Ys.Qs&&(this.el().removeAttribute("style"),this.contentEl().removeAttribute("style"))}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=this.contentEl();Yt(i,"theo-menu-content");let s=new Yo(this.player(),this.h,this);return i.parentNode.insertBefore(s.el(),i),this.se=s,t}Js(t){}show(){return this.re(),super.show()}dispose(){this.se&&this.se.dispose(),super.dispose()}constructor(t,i){super(t,i),this.ne=()=>this.re(),this.ue=this.player().el(),this.hide(),this.on("menuchange",this.re)}},Zo=class extends Ko{get ce(){return this.le}set ce(t){this.le&&this.le.de(this),this.le=t,t&&t.fe(this)}ve(t){this.ce.pe(t,"replace")}me(t){t.ce.pe(this,"restore")}ge(){Zt(this.ye,"vjs-hidden"),this.ye.style.opacity="1",super.show()}be(){Yt(this.ye,"vjs-hidden")}qs(){this.ce&&this.ce.qs(),super.qs()}Ws(){this.ce&&this.ce.Ws(),super.Ws(),Yt(this.ye,"vjs-hidden")}he(){if(this.ce&&this.ce.ke)return this.ce.ke.ye}ae(t,i){if(i.length>0){let t=i[0].height,s=i[0].width;this.le.we.style.height=t+"px",this.le.we.style.width=s+"px"}super.ae(t,i)}constructor(t,i){super(t,i)}},ta=class{get we(){return this.Us}get ke(){return this._e}fe(t){t.be(),this.Us.appendChild(t.ye)}de(t){this.Us.removeChild(t.ye)}pe(t,i){if(t==this._e)return;let s=this._e;if(this._e=t,this._e.ge(),this.ke.focus(),Tt.Ys.Qs)s.be();else{const t="translateX(100%)",e="translateX(-100%)",n=si("transform");s.ye.style.opacity="0",s.ye.style[n]="replace"===i?e:t,this._e.ye.style.opacity="1",this._e.ye.style[n]="",u((()=>{s.be(),s.ye.style[n]=""}),300)}}qs(){this.xe(),this._e.ge(),this.Ce()}Ws(){this.xe(),this._e.be(),this.Se.be(),this._e=this.Se,this.Ce()}Ce(){Qt((()=>{Zt(this.Us,"theo-no-transition"),Zt(this._e.ye,"theo-no-transition")}))}xe(){Yt(this.Us,"theo-no-transition"),Yt(this._e.ye,"theo-no-transition")}constructor(t){this.Se=this._e=t,this.Us=h.createElement("div"),this.Us.className="theo-tertiary-background theo-menu-animation-container",this.Us.appendChild(this.Se.ye),this.ue=this._e.player().el()}},ia=class extends Zo{get ye(){return this.el()}get parentMenu(){return this.je}ee(t,i){let s=new sa(t,i,this);return s.subMenu.ce=this.ce,s}ie(){this.Te()}Js(t){super.Js(t),this.Te()}Te(){this.parentMenu.me(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.je=s,this.menuHeader.Ks=!0}},sa=class extends Jo{get subMenu(){return this.Ae}handleClick(t){this.parentMenu.ve(this.subMenu)}constructor(t,i,s){super(t,fi({selectable:!1},i),s),this.Ae=new ia(t,i,s)}},ea=class extends Zo{get menuButton(){return this.Pe}createEl(){let t=Co.createEl("div",{className:this.buildCSSClass()});return this.Ee=super.createEl(),this.Ee.className=super.buildCSSClass(),Yt(this.Ee,"theo-menu-content-animatable"),t.appendChild(this.Ee),this.ce=new ta(this),t.appendChild(this.ce.we),t}buildCSSClass(){return"theo-menu-animatable "+super.buildCSSClass()}ee(t,i){let s=new sa(t,i,this);return s.subMenu.ce=this.ce,s}ae(t,i){super.ae(t,i);let s=this.ue.getClientRects(),e=s.length>0?s[0]:void 0,n=C(getComputedStyle(this.el()).fontSize);E(this.el(),this.Pe.el(),e,n)}get ye(){return this.Ee}ie(){this.Pe.closeMenu()}dispose(){this.Ne||(this.Ne=!0,super.dispose())}constructor(t,i,s){super(t,i),this.Ne=!1,this.Pe=s}},na=class{set Be(t){this.Ie.innerHTML=this.Fe.localize(t),this.De(),this.$e(),ri(this.Fe.el())}get Be(){return this.Ie.textContent||""}Re(){this.Fe.off("mouseover",this.$e),this.Fe.off("mouseout",this.De),this.Fe.off("dispose",this.Oe),qt(this.Ie)}constructor(t,i){this.$e=()=>{Zt(this.Ie,"vjs-hidden");let t=this.Fe.player().contentEl().getClientRects(),i=t.length>0?t[0]:void 0,s=C(getComputedStyle(this.Ie).fontSize);E(this.Ie,this.Fe.el(),i,s)},this.De=()=>{Yt(this.Ie,"vjs-hidden")},this.Oe=()=>this.Re(),this.Fe=t,ri(t.el()),oi(t.el()),this.Ie=h.createElement("span"),this.Ie.innerHTML=this.Fe.localize(i),this.Ie.className="theo-button-tooltip vjs-hidden",this.Ie.setAttribute("aria-hidden","true"),this.Fe.el().appendChild(this.Ie),this.Fe.on("mouseover",this.$e),this.Fe.on("mouseout",this.De),this.Fe.on("dispose",this.Oe)}},ra=Co.getComponent("Button"),ha=class extends(Bo(ra)){get Ve(){const t=this.el().parentElement;return!!t&&null!==t.querySelector(".theo-mobile-menu-background")}get menu(){return this.Ue}isMenuOpen(){return this.ze}openMenu(){this.Le&&!this.ze&&(this.Ue.qs(),this.el().setAttribute("aria-expanded","true"),this.ze=!0,this.Ue.focus())}closeMenu(){this.Le&&this.ze&&(this.Ue.Ws(),this.el().setAttribute("aria-expanded","false"),this.ze=!1)}set minimumMenuItems(t){this.He=t,this.qe()}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.Le=!0,super.enable()}disable(){return this.closeMenu(),this.Le=!1,super.disable()}te(){this.Ie.Be=this.controlText()}dispose(){this.player().removeChild(this.Ue),this.Ue.dispose(),this.Ie.Re(),this.ws.removeEventListener("seeking",this.We),super.dispose()}constructor(t,i){super(t,i),this.ze=!1,this.He=1,this.Le=!0,this.Ge=t=>{let i=this.el().contains(t.target),s=this.Ue.el().contains(t.target),e=!1;var n;Tt.Ys.Qs&&this.Ve&&(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.Xe=t=>{27===t.which&&(this.closeMenu(),this.focus())},this.We=()=>{this.ze&&this.closeMenu()},this.qe=()=>{this.Ue.menuItems.length>=this.He?this.show():(this.closeMenu(),this.hide())},this.Ue=new ea(t,i,this),this.player().getChild("controlBarMenuContainer").addChild(this.Ue),this.Ie=new na(this,this.controlText()),this.el().setAttribute("aria-haspopup","true"),Tt.Ys.Je?(this.on(h,"touchend",this.Ge),new qo(this.el())):(this.on(h,"click",this.Ge),this.on(h,"keydown",this.Xe),ai&&this.on(h,ai.Qe,this.closeMenu)),this.ws.addEventListener("seeking",this.We),this.on(this.Ue,"menuchange",this.qe),this.on(t,"languagechange",this.te),this.qe()}},oa=Co.getComponent("Component"),aa=class extends(Co.getComponent("ControlBar")){addMenuButton(t){t=fi({playerOptions:this.h.playerOptions},t);let i=new ha(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)}};Co.registerComponent("THEOControlBarShadow",class extends oa{createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-tertiary-color theo-control-bar-shadow"}});var ua=Co.getComponent("VolumeBar"),ca=class extends ua{handleFocus(t){super.handleFocus(t),this.Ye.addClass("focus-within")}handleBlur(t){super.handleBlur(t),this.Ye.removeClass("focus-within")}constructor(t,i){super(t,i),this.Ye=i.Ke}},la=Co.getComponent("VolumeControl"),da=class extends la{constructor(t,i){super(t,i),this.Ze=new ca(t,{Ke:this}),this.addChild(this.Ze)}};da.prototype.h=fi({},la.prototype.h,{children:[]}),Co.registerComponent("VolumeControl",da);var fa=class extends(Bo(aa)){tn(){this.sn(this.nn())}rn(){0===this.hn&&(this.hn=u(this.an,100))}un(t){"opacity"===t.propertyName&&(0!==this.hn&&(c(this.hn),this.hn=0),this.sn(!0))}cn(t){"opacity"===t.propertyName&&(this.nn()||this.sn(!1))}nn(){return"0"!==s.getComputedStyle(this.el()).opacity}sn(t){this.ln!==t&&(this.ln=t,t?this.dn():this.ws.textTrackStyle.marginBottom=void 0)}dn(){const t=this.el().getBoundingClientRect().height;this.ws.textTrackStyle.marginBottom!==t&&(this.ws.textTrackStyle.marginBottom=t)}dispose(){c(this.hn),this.hn=0,this.vn.fn(Kt.pn,this.mn),this.vn.gn(),super.dispose()}constructor(t,i){super(t,i),this.ln=!1,this.hn=0,this.an=()=>{0!==this.hn&&(this.hn=0,this.sn(this.nn()))},this.mn=()=>{this.ln&&this.dn()},this.on(t,"ready",this.tn),this.on(t,"pause",this.tn),this.on(t,"useractive",this.tn),this.on(t,"firstplay",this.rn),this.on(t,"play",this.rn),this.on(t,"userinactive",this.rn),this.on("transitionstart",this.un),this.on("transitionend",this.cn),this.vn=new ni(this.el()),this.vn.yn(Kt.pn,this.mn),this.vn.bn(!0)}};fa.prototype.h=fi({},aa.prototype.h,{children:["progressControl","playToggle","muteToggle","volumeControl","currentTimeDisplay","timeDivider","durationDisplay","liveDisplay","remainingTimeDisplay","customControlSpacer","activeQualityLabel","vrButton","descriptionsButton","subtitlesButton","chromecastButton","airplayButton","multiViewButton","audioTrackButton","SettingsButton","fullscreenToggle"]}),Co.registerComponent("ControlBar",fa);var va=class extends aa{buildCSSClass(){return"theo-top-controlbar "+super.buildCSSClass()}constructor(t,i){super(t,i),t.topControlBar=this}};va.prototype.h=fi({},aa.prototype.h,{children:[]}),Co.registerComponent("TopControlBar",va);var pa=Co.getComponent("CurrentTimeDisplay"),ma=class extends(Bo(pa)){updateContent(){const t=To(this.player()),i=this.ws,s=Ao(i),e=this.localize("Current Time"),n=No(_.max(0,t-s),Po(i));n!==this.Mt&&(this.Mt=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)}};Co.registerComponent("CurrentTimeDisplay",ma);var ga=Co.getComponent("DurationDisplay"),ya=class extends(Bo(ga)){updateContent(){const t=this.ws,i=S(t.duration)?NaN:Po(t),s=t.clip.endTime-t.clip.startTime,e=_.min(i,s)||0;if(this.ct!==e){this.ct=e;const t=this.localize("Duration Time"),i=No(e);this.S.innerHTML='<span class="vjs-control-text">'+t+"</span> "+i}}dispose(){var t;null==(t=this.ws)||t.clip.removeEventListener("change",this.kn),super.dispose()}constructor(t,i){var s;super(t,i),this.kn=()=>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.ws)||s.clip.addEventListener("change",this.kn)}};Co.registerComponent("DurationDisplay",ya);var ba=Co.getComponent("Button"),ka=class extends(Bo(ba)){buildCSSClass(){return"theo-live-control "+super.buildCSSClass()}createEl(){let t=super.createEl("button",{},{"aria-live":"off"});return this.wn=Co.createEl("span",{className:"theo-live-control-indicator"}),Gt(t,this.wn),t}createControlTextEl(t){let i=super.createControlTextEl(t);return Co.removeClass(i,"vjs-control-text"),Co.addClass(i,"theo-live-control-text"),i}handleClick(){var t;const i=this.ws;if(void 0!==(null==(t=i.hesp)?void 0:t.manifest))i.hesp.goLive();else{const t=this.player();t.currentTime(Mo(i)),t.play()}}_n(){jo(this.ws)?this.show():this.hide()}constructor(t,i){super(t,i),this.controlText("Live"),this._n(),this.on(t,"emptied",this._n),this.on(t,"durationchange",this._n),Tt.Ys.Je&&new qo(this.el())}};Co.registerComponent("LiveDisplay",ka);var wa=Co.getComponent("LoadingSpinner");Co.registerComponent("LoadingSpinner",class extends wa{buildCSSClass(){return"theo-secondary-color vjs-loading-spinner "+super.buildCSSClass()}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=Co.createEl("div",{className:"theo-loading-spinner-rotator"}),s=Co.createEl("div",{className:"theo-loading-spinner-circle-left"}),e=Co.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 _a=Co.getComponent("LoadProgressBar"),xa=class extends(Bo(_a)){update(){let t=this.ws,i=Nt.xn(Eo(t)),s=i.Cn(0),e=Nt.xn(t.buffered).Sn(i),n=i.jn(0)-s,r=e.U&&e.jn(e.U-1)||0;r=_.max(0,r-s);let o=this.el(),a=this.Tn;o.style.width=Ca(r,n);for(let t=0;t<e.U;t++){let i=e.Cn(t),n=e.jn(t),u=a[t];u||(u=h.createElement("div"),a.push(u),o.appendChild(u)),u.style.left=Ca(i-s,r),u.style.width=Ca(n-i,r)}for(let t=a.length;t>e.U;t--)o.removeChild(a[t-1]);a.length=e.U}constructor(t,i){super(t,i),this.Tn=[],this.on(t,"emptied",this.update)}};function Ca(t,i){let s=t/i||0;return 100*(s>=1?1:s)+"%"}Co.registerComponent("LoadProgressBar",xa);var Sa=Co.getComponent("MouseTimeDisplay"),ja=class extends(Bo(Sa)){handleMouseMove(t){let i=t,s=this.ws,e=Ao(s)+this.calculateDistance(i)*Po(s),n=i.pageX-A(this.el().parentNode).left;this.update(e,n+"px")}handleTouchMove(t){let i=t,s=this.ws,e=Ao(s)+this.calculateDistance(i)*Po(s),n=i.touches[0].pageX-A(this.el().parentNode).left;this.update(e,n+"px")}createEl(){let t=super.createEl();return this.Mn=Co.createEl("span",{className:"theo-time-tooltip-text"}),t}update(t,i){this.An=t;let s=this.Pn(t);this.el().style.left=i,this.el().setAttribute("data-current-time",s),this.keepTooltipsInside&&(l(this.Mn,s),this.En())}En(){if(this.keepTooltipsInside&&this.tooltip.offsetParent){let t=this.player().contentEl(),i=t.getClientRects(),s=i.length>0?i[0]:void 0,e=C(getComputedStyle(t).fontSize);E(this.tooltip,this.el(),s,e)}}Pn(t){const i=this.ws,s=t-Mo(i);return No(jo(i)?_.min(s,0):s,Po(i))}dispose(){var t;this.ws.removeEventListener("dimensionchange",this.Nn),null==(t=this.ws.presentation)||t.removeEventListener("presentationmodechange",this.Nn),super.dispose()}constructor(t,i){var s;(super(t,i),this.An=NaN,this.Nn=()=>{let t=To(this.player());const i=this.ws;let s=(t-Ao(i))/Po(i)||0;s=Ut(s,0,1),this.update(t,100*s+"%")},this.keepTooltipsInside&&(Co.addClass(this.tooltip,"theo-secondary-color"),this.tooltip.appendChild(this.Mn)),this.on(t,"ready",(()=>{this.on(t.controlBar.progressControl,"mouseenter",this.handleMouseMove)})),At.Qs)&&(this.on(t,"firstplay",this.Nn),this.on(t,"play",this.Nn),this.on(t,"seeking",this.Nn),this.on(t,"seeked",this.Nn),this.on(t,"timeupdate",this.Nn),this.ws.addEventListener("dimensionchange",this.Nn),null==(s=this.ws.presentation)||s.addEventListener("presentationmodechange",this.Nn),this.on(t,"ready",(()=>{this.on(t.controlBar.progressControl,"touchstart",this.handleTouchMove),this.on(t.controlBar.progressControl,"touchmove",Ot((t=>this.handleTouchMove(t)),25)),this.Nn()})))}};Co.registerComponent("MouseTimeDisplay",ja);var Ta=Co.getComponent("PlayProgressBar"),Ma=class extends(Bo(Ta)){updateDataAttr(){let t=To(this.player());this.el().setAttribute("data-current-time",this.Pn(t))}Pn(t){let i=this.ws;return No(t-Mo(i),Po(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)}};Co.registerComponent("PlayProgressBar",Ma);var Aa=Co.getComponent("RemainingTimeDisplay"),Pa=class extends(Bo(Aa)){updateContent(){const t=this.ws,i=Po(t);if(i){const s=Eo(t).end(0),e=this.localize("Remaining Time"),n=No(_.max(0,s-this.player().currentTime()),i);n!==this.Mt&&(this.Mt=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)}};Co.registerComponent("RemainingTimeDisplay",Pa);var Ea=class{get ws(){return this._s||(this._s=this.Bn.tech({IWillNotUseThisInPlugins:!0}).theoplayer()),this._s}In(t){if(t.kind!==lt.Fn)return;if(0===this.ws.seekable.length)return;this.Dn=t;const i=t.cues.slice();this.Rn.$n(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 Na(s,this.ws,n);this.On.push(r),this.Vn.appendChild(r.we)}t.addEventListener("cuechange",this.Un),this.Un()}zn(){this.ws.addEventListener("loadedmetadata",this.Ln),this.ws.addEventListener("loadeddata",this.Ln),this.ws.addEventListener("sourcechange",this.Ln),this.ws.textTracks.addEventListener("addtrack",this.Hn),this.ws.textTracks.addEventListener("removetrack",this.qn),this.ws.textTracks.addEventListener("change",this.Ln)}Wn(){this.ws.removeEventListener("loadedmetadata",this.Ln),this.ws.removeEventListener("loadeddata",this.Ln),this.ws.removeEventListener("sourcechange",this.Ln),this.ws.textTracks.removeEventListener("addtrack",this.Hn),this.ws.textTracks.removeEventListener("removetrack",this.qn),this.ws.textTracks.removeEventListener("change",this.Ln)}Gn(){if(!(this.ws.readyState<gt.Xn))for(let t of this.ws.textTracks)if(t.kind===lt.Fn&&t.mode===ut.Jn&&t.cues.length>0&&t.readyState!==rt.ERROR)return t}Qn(t){this.Rn.Yn(t)}Kn(){this.Rn.ge()}Zn(){this.Rn.be()}tr(){for(let t of this.On)t.Re();this.Rn.tr(),this.On=[],this.ir=void 0,this.Dn&&this.Dn.removeEventListener("cuechange",this.Un),this.Dn=void 0}Re(){this.Wn(),this.sr.removeEventListener("mousemove",this.er),this.sr.removeEventListener("mouseenter",this.nr),this.sr.removeEventListener("mouseleave",this.rr),this.tr(),this.Rn.Re(),this._s=void 0}constructor(t,i){this.Bn=i,this.On=[],this._s=void 0,this.Hn=t=>{let i=t.track;i.kind===lt.Fn&&(i.addEventListener("addcue",this.Ln),i.addEventListener("removecue",this.Ln),i.addEventListener("readystatechange",this.Ln)),this.Ln()},this.qn=t=>{let i=t.track;i.kind===lt.Fn&&(i.removeEventListener("addcue",this.Ln),i.removeEventListener("removecue",this.Ln),i.removeEventListener("readystatechange",this.Ln)),this.Ln()},this.er=t=>{let i=this.ws,s=function(t,i){let s,e,n=A(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=Ut((o-s+h)/h,0,1),c=Ut((e-a)/r,0,1);return{x:c,y:u}}(this.Vn,t),e=Ao(i)+s.x*Po(i);e===i.duration&&(e-=.1),this.Qn(e)},this.rr=()=>{this.Rn.be()},this.nr=()=>{this.Rn.ge()},this.Ln=()=>{let t=this.Gn();t!==this.Dn&&(this.tr(),t&&this.In(t))},this.Un=()=>{var t,i,s;const e=null==(i=this.Dn)||null==(t=i.activeCues)?void 0:t[0],n=M(this.On,(t=>t.hr===e));n!==this.ir&&(null==(s=this.ir)||s.ar(),this.ir=n,null==n||n.ur())},this.sr=t,this.Rn=new Ba,this.Bn.contentEl().appendChild(this.Rn.we),this.Vn=h.createElement("div"),Yt(this.Vn,"theoplayer-chapterbar"),this.sr.appendChild(this.Vn),this.sr.addEventListener("mousemove",this.er),this.sr.addEventListener("mouseenter",this.nr),this.sr.addEventListener("mouseleave",this.rr),this.zn()}},Na=class{get we(){return this.Us}ur(){Yt(this.Us,"theoplayer-chapter-indicator-active")}ar(){Zt(this.Us,"theoplayer-chapter-indicator-active")}cr(t,i){let s=t.seekable.start(0),e=t.seekable.end(t.seekable.length-1)-s,n=this.hr.startTime,r=this.hr.endTime-n,o=h.createElement("div");Yt(o,"theoplayer-chapter-indicator");let a=h.createElement("div");Yt(a,"theoplayer-chapter-indicator-highlight"),o.appendChild(a),i&&Yt(o,"theoplayer-chapter-indicator-discontinuous");let u=_.min(n/e*100,100),c=100-u,l=_.min(r/e*100,c);return o.style.width=l+"%",o.style.left=u+"%",o}Re(){qt(this.Us)}constructor(t,i,s){this.hr=t,this.Us=this.cr(i,s)}},Ba=class{be(){this.lr--,0===this.lr&&Zt(this.we,"theoplayer-chapter-hovering")}$n(t){this.dr=t||[],this.dr.length>0&&(this.we.style.display="")}pr(t){l(this.mr,t.content)}tr(){this.dr=[],l(this.mr,""),this.we.style.display="none"}ge(){this.lr++,this.lr>0&&Yt(this.we,"theoplayer-chapter-hovering")}Yn(t){for(let i of this.dr)if(Ia(i,t)){this.pr(i);break}}Re(){qt(this.we)}constructor(){this.dr=[],this.lr=0,this.we=h.createElement("div"),Yt(this.we,"theoplayer-chaptertitle"),this.we.style.display="none",this.mr=h.createElement("p"),this.we.appendChild(this.mr)}};function Ia(t,i){return new Nt([t.startTime,t.endTime]).gr(i)}var Fa=Co.getComponent("SeekBar"),Da=class extends(Bo(Fa)){updateAriaAttributes(t){const i=To(this.player()),s=this.ws;t.setAttribute("aria-valuenow",(100*this.yr(i)).toFixed(2)),t.setAttribute("aria-valuetext",No(i-Mo(s),Po(s)))}getPercent(){return this.yr(this.player().currentTime())}handleMouseMove(t){if(this.ws&&this.ws.ads&&this.ws.ads.playing)return;const i=this.ws;let s=Ao(i)+this.calculateDistance(t)*Po(i);s>=i.duration&&(s=i.duration-.1),this.Vn.Qn(s),this.player().currentTime(s)}handleMouseDown(t){this.playingStates.push(!this.player().paused()),this.Vn.Kn(),super.handleMouseDown(t)}handleMouseUp(t){this.videoWasPlaying=Boolean(this.playingStates.pop()),this.Vn.Zn(),super.handleMouseUp(t)}yr(t){let i=this.ws,s=(t-Ao(i))/Po(i);return Ut(s,0,1)}dispose(){this.Vn.Re(),I(this.playingStates)}constructor(t,i){super(t,i),this.playingStates=[],this.on(t,"emptied",this.update),this.on(t,"seeking",this.update),this.Vn=new Ea(this.el(),t)}};Co.registerComponent("SeekBar",Da);var $a=Co.getComponent("ProgressControl");Tt.Ys.Qs&&Co.registerComponent("ProgressControl",class extends $a{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 Ra=Co.getComponent("TooltipProgressBar"),Oa=class extends(Bo(Ra)){updateDataAttr(){let t=To(this.player()),i=this.Pn(t);this.el().setAttribute("data-current-time",i),this.tooltip.innerHTML=i}Pn(t){const i=this.ws;return No(t-Mo(i),Po(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 Va(t){for(const i of t)if(i.enabled)return i}function Ua(t){if(t)return t.label&&""!==t.label?{name:t.label,hd:!1}:{name:za(t),description:La(t),hd:!!t.height&&t.height>=720}}function za(t){return t.height?t.height+"p":t.bandwidth?La(t):""}function La(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":""}Co.registerComponent("TooltipProgressBar",Oa);var Ha=class{get br(){return this.kr}set br(t){let i=this.kr;for(let s=i.length-1;s>=0;s--){let e=i[s];N(t,e)||this.wr(e)}for(let i of t)this._r(i);this.Cr.re()}get Sr(){return this.Cr.menuItems}jr(t){let i=this.Sr;if(i)for(let s of i)if(s.Tr===t)return s}Mr(t){let i=this.Cr.addMenuItem();return i.Tr=t,i.on("click",(()=>this.Ar(i))),i.el().setAttribute("role","menuitemradio"),i}Pr(t){t.dispose()}Er(t){return!0}_r(t){if(this.Er(t)){N(this.kr,t)||this.kr.push(t);let i=this.jr(t)||this.Mr(t);return this.Nr(i),i}this.wr(t)}wr(t){let i=this.jr(t);i&&(this.Cr.removeMenuItem(i),this.Pr(i)),P(this.kr,t)}Re(){const t=[];for(let i of this.kr)t.push(i);for(let i of t)this.wr(i);I(t)}constructor(t){this.kr=[],this.Cr=t}},qa=class extends Ha{Br(){return this.Ir=h.createElement("span"),this.Ir.className="theo-settings-control-menu-item-title",l(this.Ir,this.Fr.localize("Quality")),this.Ir}Dr(){return this.$r=h.createElement("span"),this.$r.className="theo-settings-control-menu-quality-automatic",l(this.$r,this.Fr.localize("Automatic")),this.$r}Rr(){return this.Or=h.createElement("span"),l(this.Or,this.Fr.localize("Automatic")),this.Or}Vr(){return this.Ur=h.createElement("span"),this.Ur.className="theo-primary-color theo-settings-control-menu-item-hd-label",l(this.Ur,this.Fr.localize("HD")),this.Ur}zr(){let t=h.createElement("span");t.className="theo-primary-color theo-settings-control-menu-item-value",t.appendChild(this.$r),t.appendChild(h.createTextNode(" ")),t.appendChild(this.Or),t.appendChild(h.createTextNode(" ")),t.appendChild(this.Ur),this.Lr.el().appendChild(this.Ir),this.Lr.el().appendChild(t),this.Lr.el().setAttribute("aria-label",this.Fr.localize("Open the video quality settings menu"))}Hr(){let t=this.qr,i=t&&Ka(t.targetQuality),s=t&&t.activeQuality,e=Ua(this.Wr(i||s))||{name:this.Fr.localize("Automatic")};l(this.Or,e.name),ii(this.$r,"vjs-hidden",!!i),ii(this.Ur,"vjs-hidden",!e.hd)}Nr(t){let i=Ua(t.Tr)||{name:this.Fr.localize("Automatic")},s=i.name;i.hd&&(s+='<span class="theo-primary-color theo-settings-control-menu-item-hd-label">'+this.Fr.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.Fr.localize("Set video quality to ")+i.name),t.Tr?t.selected(t.Tr===this.Gr):t.selected(!this.Gr)}Ar(t){this.qr&&(this.qr.targetQuality=t.Tr&&t.Tr.videoQualities)}Wr(t,i){const s=i||this.br;for(let i of s)if(t&&i&&-1!==i.videoQualities.indexOf(t))return i}Re(){this._s.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.Xr),this.Fr.off("languagechange",this.te),this.qr&&(this.qr.removeEventListener("activequalitychanged",this.Jr),this.qr.removeEventListener("targetqualitychanged",this.Qr),this.qr.removeEventListener("update",this.Yr)),super.Re()}constructor(t,i,s){super(t.subMenu),this.qr=void 0,this.Gr=void 0,this.Xr=()=>{let t=Va(this._s.videoTracks);if(t===this.qr)return;let i=[];if(this.qr&&(this.qr.removeEventListener("activequalitychanged",this.Jr),this.qr.removeEventListener("targetqualitychanged",this.Qr),this.qr.removeEventListener("update",this.Yr)),this.qr=t,t){t.addEventListener("activequalitychanged",this.Jr),t.addEventListener("targetqualitychanged",this.Qr),t.addEventListener("update",this.Yr);const s=Ga(Qa(t.qualities.filter((t=>t.available))));i=s.length>1?[void 0,...s]:[void 0]}this.br=i,this.Qr(),this.Jr()},this.Yr=t=>{const i=t.track;if(i!==this.qr)return;const s=Ga(Qa(i.qualities.filter((t=>t.available)))),e=i&&Ka(i.targetQuality);let n;this.Gr=this.Wr(e,s),n=s.length>1?[void 0,...s]:[void 0],this.br=n,this.Hr()},this.Jr=()=>{this._r(void 0),this.Hr()},this.Qr=()=>{let t=Va(this._s.videoTracks),i=t&&Ka(t.targetQuality),s=this.Wr(i),e=this.Gr;s!==e&&(this.Gr=s,s&&e||this._r(void 0),e&&N(this.br,e)&&this._r(e),i&&this._r(s),this.Hr())},this.te=()=>{l(this.Cr.menuHeader.el(),this.Fr.localize("Quality")),l(this.Ir,this.Fr.localize("Quality")),l(this.$r,this.Fr.localize("Automatic")),l(this.Or,this.Fr.localize("Automatic")),l(this.Ur,this.Fr.localize("HD")),this.Lr.el().setAttribute("aria-label",this.Fr.localize("Open the video quality settings menu"));for(const t of this.Sr)this.Nr(t);this.Hr()},this.Lr=t,this._s=i,this.Fr=s,this.Ir=this.Br(),this.$r=this.Dr(),this.Or=this.Rr(),this.Ur=this.Vr(),this.zr(),l(this.Cr.menuHeader.el(),this.Fr.localize("Quality")),this.br=[void 0],this._s.videoTracks.addEventListener(["addtrack","removetrack","change"],this.Xr),this.Fr.on("languagechange",this.te),this.Xr()}},Wa=class{get height(){return this.Kr[0].height}get bandwidth(){return this.Kr[0].bandwidth}get videoQualities(){return this.Kr}get label(){return this.Kr[0].label}add(t){this.Kr.push(t)}constructor(t){this.Kr=t}};function Ga(t){let i=[];for(let s of t){let t=s,e=!1;for(let s of i)if(Ya(s,t)){s.add(t),e=!0;break}e||i.push(new Wa([t]))}return i}function Xa(t,i){return t&&i?xi(t,i):wi.Zr}function Ja(t,i){return t===i?wi.Zr:Xa(t.height,i.height)||Xa(t.width,i.width)||Xa(t.bandwidth,i.bandwidth)}function Qa(t){return bi(t,Ja).reverse()}function Ya(t,i){return t.label&&i.label&&t.label===i.label||J(Ua(t),Ua(i))}function Ka(t){return Bt(t)?1===t.length?t[0]:void 0:t}function Za(t){return 1===t?"Normal":""+_.round(100*t)/100}var tu=class extends Ha{Br(){return this.Ir=h.createElement("span"),this.Ir.className="theo-settings-control-menu-item-title",l(this.Ir,this.Fr.localize("Speed")),this.Ir}zr(){const t=h.createElement("span");return t.className="theo-primary-color theo-settings-control-menu-item-value",this.Lr.el().appendChild(this.Ir),this.Lr.el().appendChild(t),this.Lr.el().setAttribute("aria-label",this.Fr.localize("Open the video speed settings menu")),t}Mr(t){let i=super.Mr(t);return this.Nr(i),i}Nr(t){const i=t.Tr,s=this.Fr.localize(Za(i));l(t.el(),s),t.el().setAttribute("aria-label",this.Fr.localize("Set video speed to ")+s),t.selected(t.Tr===this._s.playbackRate)}Ar(t){this._s.playbackRate=t.Tr}Re(){this._s.removeEventListener("ratechange",this.th),this.Fr.off("languagechange",this.te),super.Re()}constructor(t,i,s,e){super(t.subMenu),this.ih=void 0,this.th=()=>{this.ih&&this._r(this.ih);let t=this._s.playbackRate;this.ih=t,l(this.sh,this.Fr.localize(Za(t))),t&&this._r(t)},this.te=()=>{l(this.Cr.menuHeader.el(),this.Fr.localize("Speed")),l(this.Ir,this.Fr.localize("Speed")),this.Lr.el().setAttribute("aria-label",this.Fr.localize("Open the video speed settings menu"));for(const t of this.Sr)this.Nr(t);this.th()},this.Lr=t,this._s=i,this.Fr=s,this.Ir=this.Br(),this.sh=this.zr(),l(this.Cr.menuHeader.el(),this.Fr.localize("Speed")),this.br=e,this._s.addEventListener("ratechange",this.th),this.Fr.on("languagechange",this.te),this.th()}};Co.registerComponent("SettingsButton",class extends ha{createEl(){let t=super.createEl();return this.eh=Co.createEl("span",{className:"theo-settings-control-label-hd theo-primary-background"}),l(this.eh,this.localize("HD")),t.appendChild(this.eh),t}buildCSSClass(){return"vjs-icon-cog theo-settings-control-button "+super.buildCSSClass()}te(){super.te(),l(this.eh,this.localize("HD")),l(this.menu.menuHeader.el(),this.localize("Settings"))}dispose(){this.qr&&(this.qr.removeEventListener("activequalitychanged",this.Jr),this.qr=void 0),this.ws.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.nh),this.rh.Re(),this.hh.Re(),super.dispose()}constructor(t,i){var s,e;super(t,i),this.qr=void 0,this.nh=()=>{let t=Va(this.ws.videoTracks);t!==this.qr&&(this.qr&&this.qr.removeEventListener("activequalitychanged",this.Jr),this.qr=t,t&&t.addEventListener("activequalitychanged",this.Jr),this.Jr())},this.Jr=()=>{var t;const i=null==(t=this.qr)?void 0:t.activeQuality,s=!!(i&&i.height>=720);this.player().toggleClass("theo-hd",s)},Yt(this.menu.el(),"theo-settings-control-menu"),l(this.menu.menuHeader.el(),t.localize("Settings")),this.controlText("Settings"),this.Ie.Be=this.controlText(),this.oh=this.menu.addSubMenuItem({name:"QualityMenuItem"}),this.rh=new qa(this.oh,this.ws,t);let n=null!=(e=null==i||null==(s=i.playerOptions)?void 0:s.playbackRates)?e:[];this.ah=this.menu.addSubMenuItem({name:"PlaybackRateMenuItem"}),this.hh=new tu(this.ah,this.ws,t,n),this.ws.videoTracks.addEventListener(["addtrack","removetrack","change"],this.nh),this.nh()}});var iu=class extends Ha{uh(t){let i=t.label;if(i)return i;let s=t.language;if(s){let t=at(s);if(t)return t.lh}return s||""}dh(){this.br=this.fh}Re(){this.fh.removeEventListener("addtrack",this.ph),this.fh.removeEventListener("removetrack",this.mh),this.fh.removeEventListener("change",this.gh),super.Re()}constructor(t,i){super(t),this.ph=t=>{const i=t.track;this._r(i),i.addEventListener("update",this.yh)},this.mh=t=>{const i=t.track;this.wr(i),i.removeEventListener("update",this.yh)},this.gh=t=>this.dh(),this.yh=()=>{for(const t of this.br)this._r(t)},this.fh=i,this.fh.addEventListener("addtrack",this.ph),this.fh.addEventListener("removetrack",this.mh),this.fh.addEventListener("change",this.gh),this.dh()}},su=class extends iu{Nr(t){let i=t.Tr,s=this.Fr.localize(this.uh(i));l(t.el(),s),t.el().setAttribute("aria-label",this.Fr.localize("Set the audio language to")+" "+s),t.selected(i.enabled)}Ar(t){let i=t.Tr;for(let t of this.ws.audioTracks)t!==i&&(t.enabled=!1);i.enabled=!0}Re(){this.Fr.off("languagechange",this.te),super.Re()}constructor(t,i,s){super(t,i.audioTracks),this.te=()=>{l(this.Cr.menuHeader.el(),this.Fr.localize("Language"));for(const t of this.Sr)this.Nr(t)},this.ws=i,this.Fr=s,l(this.Cr.menuHeader.el(),this.Fr.localize("Language")),this.Fr.on("languagechange",this.te)}};Co.registerComponent("audioTrackButton",class extends ha{buildCSSClass(){return"vjs-icon-audio theo-audio-track-control-button "+super.buildCSSClass()}dispose(){this.bh.Re(),super.dispose()}constructor(t,i){super(t,i),this.minimumMenuItems=2,this.bh=new su(this.menu,this.ws,t),this.controlText("Language"),this.Ie.Be=this.controlText()}});var eu=class extends iu{Er(t){return!!super.Er(t)&&(!t.forced&&pt(t.kind))}Mr(t){let i=super.Mr(t);Yt(i.el(),"theo-text-track-menu-item");let s=h.createElement("span");i.kh=s;let e=h.createElement("div");e.className="theo-text-track-menu-item-toggle",i.wh=e;let n=t=>this._h(t,i);i.xh=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}Nr(t){let i=t,s=i.Tr,e=this.Fr.localize(this.uh(s));l(i.kh,e),i.el().setAttribute("aria-label",this.Fr.localize("Set the subtitle language to")+" "+e),i.el().setAttribute("role","menuitemcheckbox"),i.selected(s.mode===ut.Jn)}Pr(t){let i=t;i.wh.removeEventListener("click",i.xh),super.Pr(t)}Ar(t){let i=t.Tr;for(let t of this.ws.textTracks)t!==i&&ft(t.kind,i.kind)&&(t.mode=ut.Ch);i.mode!==ut.Jn?i.mode=ut.Jn:i.mode=ut.Ch}_h(t,i){t.stopImmediatePropagation(),this.Ar(i)}Re(){this.Fr.off("languagechange",this.te),super.Re()}constructor(t,i,s){super(t,i.textTracks),this.te=()=>{l(this.Cr.menuHeader.el(),this.Fr.localize("Subtitles"));for(const t of this.Sr)this.Nr(t)},this.ws=i,this.Fr=s,l(this.Cr.menuHeader.el(),s.localize("Subtitles")),this.Fr.on("languagechange",this.te)}};Co.registerComponent("subtitlesButton",class extends ha{buildCSSClass(){return"vjs-icon-subtitles theo-text-track-control-button "+super.buildCSSClass()}dispose(){this.bh.Re(),super.dispose()}constructor(t,i){super(t,i),this.bh=new eu(this.menu,this.ws,t),this.controlText("Subtitles"),this.Ie.Be=this.controlText()}});var nu,ru=Co.getComponent("playToggle");!function(t){t.Sh="Pause",t.jh="Play",t.Th="Replay"}(nu||(nu={}));var hu=class extends(Bo(ru)){handleClick(t){this.ws.muted||this.ws.prepareWithUserAction(),super.handleClick(t)}handlePlay(t){super.handlePlay(t),this.controlText("Pause"),this.Ie.Be=this.controlText()}handlePause(t){this.ws.ended||(super.handlePause(t),this.controlText("Play"),this.Ie.Be=this.controlText())}te(){this.Ie.Be=this.controlText()}dispose(){this.Ie.Re(),this.ws.removeEventListener("ended",this.Mh),super.dispose()}constructor(t,i){super(t,i),this.Mh=()=>{this.controlText("Replay"),this.Ie.Be=this.controlText()},this.controlText("Play"),this.Ie=new na(this,this.controlText()),this.ws.addEventListener("ended",this.Mh),this.on(t,"languagechange",this.te),Tt.Ys.Je&&new qo(this.el())}};Co.registerComponent("playToggle",hu);var ou,au=Co.getComponent("fullscreenToggle");!function(t){t.Ah="Exit fullscreen",t.Ph="Fullscreen"}(ou||(ou={}));var uu=class extends(Bo(au)){handleClick(t){this.ws.prepareWithUserAction(),super.handleClick(t)}handleFullscreenChange(t){super.handleFullscreenChange(t),this.updateContent()}updateContent(){const t=this.player().isFullscreen()?"Exit fullscreen":"Fullscreen";this.controlText(t),this.Ie.Be=this.controlText()}dispose(){this.Ie.Re(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Fullscreen"),this.Ie=new na(this,this.controlText()),Tt.Ys.Je&&new qo(this.el()),this.on(t,"languagechange",this.updateContent)}};Co.registerComponent("fullscreenToggle",uu);var cu,lu=Co.getComponent("muteToggle");!function(t){t.Eh="Unmute",t.Nh="Mute"}(cu||(cu={}));var du=class extends(Bo(lu)){handleClick(t){this.ws.muted&&!this.ws.paused&&this.ws.prepareWithUserAction(),super.handleClick(t)}update(t){super.update(t),this.te()}te(){const t=this.player().muted()?"Unmute":"Mute";this.controlText(t),this.Ie.Be=this.controlText()}dispose(){this.Ie.Re(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Mute"),this.Ie=new na(this,this.controlText()),Tt.Ys.Je&&new qo(this.el()),this.on(t,"languagechange",this.te),ui&&(this.removeClass("vjs-hidden"),this.on(t,"loadstart",(()=>{this.removeClass("vjs-hidden")})))}};Co.registerComponent("muteToggle",du);var fu=Co.getComponent("BigPlayButton"),vu="theo-play-svg-circle",pu='<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="'+vu+'" 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>',mu=class extends(Bo(fu)){createEl(){let t=super.createEl(),i=Co.createEl("div",{className:"theo-big-play-button-svg-container"});return i.innerHTML=pu,t.appendChild(i),t}buildCSSClass(){return"theo-primary-color "+super.buildCSSClass()}handleClick(t){this.ws.muted||this.ws.prepareWithUserAction(),super.handleClick(t),void 0!==this.ws.vr&&"unavailable"!==this.ws.vr.state&&(this.ws.vr.useDeviceMotionControls=!0)}};Co.registerComponent("BigPlayButton",mu);var gu=/^([^#]*)#xywh=(\d+),(\d+),(\d+),(\d+)\s*$/;Co.registerComponent("MouseTimeDisplay",class extends ja{Bh(t){const i=t.track;"metadata"===i.kind&&"thumbnails"===i.label&&void 0===this.Ih&&(this.Ih=i,this.Fh=i.src?Tt.Dh(i.src).href:void 0,this.Ih.addEventListener(["addcue","removecue"],this.$h),this.Rh())}Oh(t){t.track===this.Ih&&this.Vh()}createEl(){const t=super.createEl();return this.Uh=Co.createEl("img",{className:"theo-time-tooltip-thumbnail"}),this.zh=Co.createEl("canvas",{className:"theo-time-tooltip-thumbnail"}),t}update(t,i){super.update(t,i),this.keepTooltipsInside&&this.Lh(t)}Lh(t){let i;if(this.Ih&&this.Ih.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.Ih.cues,t);i=s&&s.content}if(i===this.Hh)return;if(this.Hh=i,Co.toggleClass(this.el(),"theo-time-tooltip-has-thumbnail",!!i),!i)return void this.qh();const s=i.match(gu);if(s){let[,t,i,e,n,r]=s;t=this.Wh(t);const h={Gh:+i,Xh:+e,ji:+n,Ti:+r};this.Jh(t,h)}else{const t=this.Wh(i);this.Jh(t)}}Rh(){S(this.An)||this.Lh(this.An)}Wh(t){return this.Ih&&this.Fh?Tt.Dh(t,this.Fh).href:t}Jh(t,i){this.Uh&&(this.Uh.src!==t?(this.Uh.onload=()=>{this.Qh(i)},this.Uh.src="",this.Uh.src=t):this.Qh(i))}Qh(t){if(!this.zh||!this.Uh)return;const i=this.zh.getContext("2d");i&&(null!=t||(t={Gh:0,Xh:0,ji:this.Uh.naturalWidth,Ti:this.Uh.naturalHeight}),this.zh.width=t.ji,this.zh.height=t.Ti,i.drawImage(this.Uh,t.Gh,t.Xh,t.ji,t.Ti,0,0,t.ji,t.Ti),this.Yh(this.zh))}Yh(t){this.Kh||(Gt(this.tooltip,t),this.Kh=t),this.En()}qh(){this.Kh&&(this.tooltip.removeChild(this.Kh),this.Kh=void 0,this.En())}Vh(){void 0!==this.Ih&&(this.Ih.removeEventListener(["addcue","removecue"],this.$h),this.Ih=void 0),this.Fh=void 0,this.qh(),this.Hh=void 0}dispose(){this.Vh(),super.dispose()}constructor(t,i){super(t,i),this.Kh=void 0,this.Ih=void 0,this.Fh=void 0,this.Zh=t=>this.Bh(t),this.io=t=>this.Oh(t),this.$h=t=>this.Rh(),this.showThumbnails=()=>{this.Kh&&this.Kh.hidden&&(this.Kh.hidden=!1,this.En())},this.hideThumbnails=()=>{!this.Kh||this.Kh.hidden||this.player().scrubbing()||(this.Kh.hidden=!0,this.En())},this.on(this.player().textTracks(),"addtrack",this.Zh),this.on(this.player().textTracks(),"removetrack",this.io),At.Qs&&(this.on(t,"seeking",this.showThumbnails),this.on(t,"seeked",this.hideThumbnails))}});var yu=Co.getComponent("VolumeLevel");Co.registerComponent("VolumeLevel",class extends yu{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-volume-level "+super.buildCSSClass()}});var bu=Co.getComponent("Component"),ku=class extends bu{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-menu-container "+super.buildCSSClass()}};ku.prototype.h=fi({},ku.prototype.h,{children:[]}),Co.registerComponent("controlBarMenuContainer",ku);var wu=Co.getComponent("Player"),_u=class extends wu{dispose(){const t=this.el(),i=this.contentEl(),s=t.parentNode,e=t.nextSibling;super.dispose(),qt(i),this.Ci&&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)}};_u.prototype.h=fi({},wu.prototype.h,{children:["bigPlayButton","AdControlPanel","TopControlBar","mediaLoader","upNextContainer","posterImage","chromecastOverlay","upcomingAdNotificationText","controlBarMenuContainer","controlBar","textTrackDisplay","loadingSpinner","errorDisplay","textTrackSettings","xrCompass"]}),Co.registerComponent("Player",_u);var xu=Co.getComponent("Player"),Cu=xu.prototype.es;xu.prototype.es=function(t){if(!(this.H&&this.H.$s&&this.H.$s()))return Cu.call(this,t)};var Su=xu.prototype.createEl;function ju(t,i,e,n){let r=fi({controls:!0,playbackRates:[.25,.5,1,1.25,1.5,2]},e);r.controlBar=fi({progressControl:{keepTooltipsInside:!0}},r.controlBar);let h=r.techOrder||(r.techOrder=[]);-1===h.indexOf("THEOplayer")&&h.unshift("THEOplayer"),(r.theoplayer||(r.theoplayer={})).player=t,e&&Ft(e.language)&&(r.languages=fi({},r.languages,{[ht]:e.language}),r.language=ht),i.setAttribute("data-vjs-player","");let o=i.getAttribute("style"),a=Co(t.element,r,n);return a.ready((()=>{Fo(a),function(t,i){if(i){if(i.ads){const s=i=>{const s="adbreakbegin"===i.type,e=i.adBreak.integration===ct.so;Ro(t,s,e)};i.ads.addEventListener("adbreakbegin",s),i.ads.addEventListener("adbreakend",s)}if(i.verizonMedia){const s=i=>{const s="adbreakbegin"===i.type;Ro(t,s,!1)};i.verizonMedia.ads.adBreaks.addEventListener("addadbreak",(t=>{t.adBreak.addEventListener("adbreakbegin",s),t.adBreak.addEventListener("adbreakend",s)}))}i.addEventListener("sourcechange",(()=>{Ro(t,!1,!1)}))}}(a,t),function(t){t.on("mouseleave",Oo)}(a)})),i.removeAttribute("data-vjs-player"),o?i.setAttribute("style",o):i.removeAttribute("style"),Tt.Ys.Qs&&(Yt(i,"theo-mobile"),function(t){let i=s.outerHeight,e=s.outerWidth,n=i>e;n?(Zt(t,"theo-mobile-landscape"),Yt(t,"theo-mobile-portrait")):(Zt(t,"theo-mobile-portrait"),Yt(t,"theo-mobile-landscape"))}(i)),function(t){t.on("seeking",(()=>{Jt(t.el(),"vjs-ended")&&t.currentTime()!==t.duration()&&t.play()}))}(a),a}xu.prototype.createEl=function(){let t=Su.call(this),i=Co.createEl("div");for(i.className="theo-player-wrapper";t.firstChild;)i.appendChild(t.firstChild);return t.appendChild(i),this.S=i,t};var Tu=Co.getComponent("Button");var Mu="THEOPiPCloseButton";Co.registerComponent(Mu,class extends Tu{buildCSSClass(){return"theo-close-button theo-pip-close"}handleClick(){this.no.eo()}constructor(t,i){if(super(t,i),this.controlText("Close Picture-in-Picture"),!function(t){return!!t&&Boolean(t.no)}(i))throw new g("Invalid Picture-in-picture options.");this.no=i.no}});var Au,Pu=class extends D{get ro(){return this.ho}get oo(){return this.t.cs()}ao(){this.t.yn(L.jh,this.uo),this.co||this.t.yn(L.lo,this.do),this.t.fo.on("languagechange",this.te)}vo(){var t;return"theo-pip-"+(null!=(t=this.po)?t:"bottom-right")}mo(t){let i=this.yo;i&&!this.oo&&(this.bo||this.ko(),this.wo(),Yt(i,"theo-pip"),Yt(i,this.vo()),this.ho=!0,this._o=t,this.xo=!1,this.Co(new Dt(Vt.PICTURE_IN_PICTURE)))}So(t){let i=this.yo;i&&(this.jo(),Zt(i,"theo-pip"),Zt(i,this.vo()),this.ho=!1,this.xo=t,this.To=this._o,this._o=!1,this.Co(new Dt(Vt.INLINE)))}ko(){if(!this.bo){let t=this.t.fo;t.addChild(Mu,{no:this});let i=h.createElement("div");i.className="theo-pip-overlay",this.Mo=h.createElement("div"),this.Mo.className="theo-pip-overlay-text",l(this.Mo,t.localize("Video playing in Picture-in-Picture mode")),i.appendChild(this.Mo),Gt(t.el(),i),this.Ao=i,this.bo=!0}}Po(){this.Eo&&!this.No&&this.t.Bo&&(this.Io=this.t.Bo.Fo(R,this.Do),this.No=!0)}$o(){this.Io&&this.t.Bo&&(this.t.Bo.Ro(this.Io),this.No=!1)}wo(){let t=this.t.fo.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"}jo(){let t=this.t.fo.contentEl();t.style.top="",t.style.bottom="",t.style.right="",t.style.left="",t.style.width="",t.style.height="",t.style.position=""}Oo(){Zt(this.yo,"theo-pip"),this.ro&&this.po&&Zt(this.yo,"theo-pip-"+this.po),this.Ao&&(qt(this.Ao),this.Ao=void 0)}gn(){this.Oo(),this.$o(),this.Vo(),this.t.fn(L.jh,this.uo),this.t.fn(L.lo,this.do),this.t.fo.off("languagechange",this.te),this.t=void 0}constructor(t,i,s){super(),this.Uo=!1,this.ho=!1,this.xo=!1,this._o=!1,this.bo=!1,this.No=!1,this.To=!1,this.uo=()=>{this.Uo=!0,this.Eo&&!this.ro&&this.Io&&this.zo&&this.Io.Lo<=this.zo&&this.mo(!1)},this.do=()=>{this.co||(this.Uo=!1,this.So(!1))},this.te=()=>{if(this.Mo){const t=this.t.fo;l(this.Mo,t.localize("Video playing in Picture-in-Picture mode"))}},this.Do=t=>{!this._o&&this.Eo&&(S(t)||(this.zo&&t<=this.zo||this.To?this.ho||this.xo||this.mo(!1):this.ho?this.So(!1):this.xo=!1))},this.zo=i.visibility,this.po=i.position,this.co=i.retainPresentationModeOnSourceChange,this.Eo=void 0!==this.zo,this.t=t,this.yo=t.Ho,this.eo=s,this.ao()}},Eu=class extends zt{qo(){let t=super.qo();return t===Vt.INLINE&&this.Wo&&this.Wo.ro?Vt.PICTURE_IN_PICTURE:t}Go(t){return t===Vt.PICTURE_IN_PICTURE||super.Go(t)}Xo(t,i){t===Vt.FULLSCREEN&&this.Wo.$o(),super.Xo(t,i),t!==Vt.FULLSCREEN&&this.Wo.Po()}Jo(t,i){t!==i&&(t===Vt.FULLSCREEN&&this.Wo.So(!1),t===Vt.INLINE&&i===Vt.PICTURE_IN_PICTURE&&this.Wo.So(!0),super.Jo(t,i),t===Vt.PICTURE_IN_PICTURE&&(i===Vt.INLINE?this.Wo.mo(!0):this.Wo.mo(!1)))}gn(){super.gn(),this.Wo.gn(),this.Qo.fn(L.jh,this.Yo),this.Qo=void 0}constructor(t,i,s){super(i),this.Ko=()=>this.Yr(),this.eo=()=>this.Zo(Vt.INLINE),this.Yo=()=>{this.qo()!==Vt.FULLSCREEN&&this.Wo.Po(),this.Qo.fn(L.jh,this.Yo)},this.Qo=t,this.Wo=new Pu(t,s.pip,this.eo),this.Wo.yn("presentationmodechange",this.Ko),this.Qo.yn(L.jh,this.Yo),this.Yr()}},Nu=class extends D{get ta(){return ci.ia(this.fo.el())||this.fo.supportsFullScreen()}get cs(){return this.fo.isFullscreen()||this.sa}mo(){this.fo.requestFullscreen()}So(){this.fo.exitFullscreen(),this.ea.So()}gn(){this.Vo(),this.fo.off("fullscreenchange",this.na),this.ea.fn(It.ra,this.na),this.ea.fn(It.ha,this.Ds),this.fo.isFullWindow&&this.fo.exitFullscreen()}constructor(t,i){super(),this.Os=!1,this.sa=!1,this.oa=!1,this.na=()=>{if(this.oa)return;let t=this.Os,i=this.cs;t!==i&&(this.Os=i,this.Co(new hi))},this.aa=()=>{this.sa=this.ea.cs,this.na()},this.ua=()=>{this.oa||(this.fo.isFullWindow&&this.fo.supportsFullScreen()||this.sa&&!this.fo.supportsFullScreen())&&(this.oa=!0,this.fo.exitFullscreen(),this.fo.requestFullscreen(),this.oa=!1,this.na())},this.fo=t,this.ea=i,this.fo.on("fullscreenchange",this.na),this.ea.yn(It.ra,this.aa),this.ea.yn(It.ca,this.ua),this.ea.yn(It.ha,this.Ds),this.na()}};function Bu(t){return class extends t{get Bo(){return this.la}cs(){return"fullscreen"===this.da.qo()}fa(){return function(t,i){let s=w.create(t);const e=i.fo;return G(s,{get controls(){return e.controls()},set controls(t){e.controls(Z(t))},get presentation(){return i.da.va},get presentationMode(){return i.da.qo()},set presentationMode(t){const s=Ht(t);s&&i.da.Zo(s)},get ui(){return e},get visibility(){return i.Bo.va}})}(this.pa,this)}gn(){super.gn(),this.da.gn(),this.ma.gn(),this.fo.dispose(),this.la.gn()}ga(t){this.fo.src(""),super.ga(t)}constructor(t,i,s){super(i,s),this.Ho=t,this.la=new V(t),this.pa=super.fa(),w.defineProperty(this.pa,"constructor",{value:W}),this.fo=ju(this.pa,this.Ho,s.ui),this.ma=new Nu(this.fo,this.ya),this.da=new Eu(this,this.ma,s),this.da.yn("presentationmodechange",this.Ds)}}}function Iu(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(Et(t)&&!S(t))return Ut(t,0,1)}(t.visibility),t.retainPresentationModeOnSourceChange=Z(t.retainPresentationModeOnSourceChange),t}function Fu(){return Au||(Au=function(t){let i=t;for(const t of Si)i=t(i);return i}(Au=Bu(H()))),Au}function Du(t,i){const s=function(t){const i=Pt(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=Iu(i.pip),i}(i),e=h.createElement("div");ei(e),t.appendChild(e);const n=new(Fu())(t,e,s);n.ba=n;let r=n.va;return n.ka(),n.wa(z),w.defineProperty(r,"constructor",{value:Du}),r=q(r),St(n),function(t){for(const i of Ti)i(t)}(n),r}var $u="theo-cast-",Ru=Co.getComponent("Button"),Ou=class extends(Bo(Ru)){get _a(){throw new g("xa")}get Ca(){return this.h.Ca}get Sa(){return this.h.Sa}buildCSSClass(){return $u+"button theo-"+this.Sa+"-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=$u+"svg-container",r.innerHTML=this.Ca,e.appendChild(n),e.appendChild(r),e}handleClick(t){var i;if(super.handleClick(t),this.ja===Wt.AVAILABLE)null==(i=this._a)||i.start();else if(this.ja===Wt.CONNECTED||this.ja===Wt.CONNECTING){var s;null==(s=this._a)||s.stop()}}Ta(t){Zt(this.yo,"theo-"+this.Sa+"-"+this.ja),this.ja=t,Yt(this.yo,"theo-"+this.Sa+"-"+this.ja),this.te()}te(){this.Ma(this.ja),this.Ie.Be=this.controlText()}Ma(t){t===Wt.CONNECTED?this.controlText("Stop Casting"):t===Wt.AVAILABLE?this.controlText("Start Casting"):t===Wt.CONNECTING?this.controlText("Connecting"):this.controlText("Unavailable")}constructor(t,i){var s;super(t,i),this.yo=t.el(),this.ja=Wt.UNAVAILABLE,this.controlText("Unavailable"),this.Ie=new na(this,this.controlText()),null==(s=this._a)||s.addEventListener("statechange",(t=>{const i=t;this.Ta(i.state)})),Tt.Ys.Je&&(this.Aa=new qo(this.el())),this.Ta(this._a?this._a.state:Wt.UNAVAILABLE),this.on(t,"languagechange",this.te)}},Vu=0;function Uu(){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-'+Vu+'">\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-'+Vu+')">\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 Vu++,t}Co.registerComponent("chromecastButton",class extends Ou{get _a(){var t;return null==(t=this.ws.cast)?void 0:t.chromecast}constructor(t,i){super(t,fi({},i,{Sa:"chromecast",Ca:Uu()}))}});var zu="theo-chromecast-",Lu=Co.getComponent("Component"),Hu=class t extends(Bo(Lu)){buildCSSClass(){return zu+"overlay "+super.buildCSSClass()}createEl(){const i=super.createEl();Yt(i,zu+"overlay");const s=Co.createEl("div",{className:zu+"status-icon",innerHTML:t.ICON_SVG}),e=Co.createEl("div",{className:zu+"status-info"});l(e,"Playing on");const n=Co.createEl("div",{className:zu+"status-title"}),r=Co.createEl("div",{className:zu+"status"});return this.mr=n,r.appendChild(s),r.appendChild(e),r.appendChild(n),i.appendChild(r),i}dispose(){var t;null==(t=this.Pa)||t.removeEventListener("statechange",this.update),this.Pa=void 0,this.ws.removeEventListener("play",this.update),super.dispose()}constructor(t,i){var s,e;super(t,i),this.update=()=>{this.Pa?(this.mr&&l(this.mr,this.Pa.receiverName||""),this.Pa.state===Wt.CONNECTED?this.show():this.hide()):this.hide()},this.Pa=null==(s=this.ws.cast)?void 0:s.chromecast,null==(e=this.Pa)||e.addEventListener("statechange",this.update),this.ws.addEventListener("play",this.update),this.update()}};Hu.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>',Co.registerComponent("chromecastOverlay",Hu);Co.registerComponent("airplayButton",class extends Ou{dispose(){var t,i;null==(t=this.ws.ads)||t.removeEventListener("adbreakbegin",this.Ea),null==(i=this.ws.ads)||i.removeEventListener("adbreakend",this.Na),this.ws.removeEventListener("currentsourcechange",this.Na),super.dispose()}get _a(){var t;return null==(t=this.ws.cast)?void 0:t.airplay}constructor(t,i){var s,e;super(t,fi({},i,{Sa:"airplay",Ca:'\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.Na=()=>{this.enable()},this.Ea=()=>{this.disable()},null==(s=this.ws.ads)||s.addEventListener("adbreakbegin",this.Ea),null==(e=this.ws.ads)||e.addEventListener("adbreakend",this.Na),this.ws.addEventListener("currentsourcechange",this.Na)}});var qu=Co.getComponent("Button"),Wu=class extends(Bo(qu)){buildCSSClass(){return"theo-vr-button theo-controlbar-button "+super.buildCSSClass()}handleClick(){this.ws.vr.stereo=!this.ws.vr.stereo,this.te()}_n(){this.ws.vr&&this.ws.vr.state!==yt.Rs?(this.show(),this.ws.vr.canPresentVR?(this.enable(),this.te()):(this.disable(),this.controlText("No VR capable device found"),this.Ba.Be=this.controlText())):this.hide()}te(){var t;this.controlText((null==(t=this.ws.vr)?void 0:t.stereo)?"Stop watching in VR":"Watch in VR"),this.Ba.Be=this.controlText()}dispose(){var t;null==(t=this.ws.vr)||t.removeEventListener("statechange",this.Ia),super.dispose()}constructor(t,i){var s;super(t,i),this.Ia=()=>this._n(),this.controlText("Watch in VR"),this.Ba=new na(this,this.controlText()),null==(s=this.ws.vr)||s.addEventListener("statechange",this.Ia),this._n(),Tt.Ys.Je&&new qo(this.el()),this.on(t,"languagechange",this.te)}};Co.registerComponent("vrButton",Wu);var Gu=Co.getComponent("Component"),Xu=class extends Gu{createEl(){let t=super.createEl("div",{className:this.buildCSSClass()}),i=Co.createEl("div",{className:"theo-360-fov"});return t.appendChild(i),this.Fa=i,t}buildCSSClass(){return"theo-360-compass "+super.buildCSSClass()}_n(){this.ws.vr.state===yt.Rs?this.hide():this.show()}Da(){let t=-this.ws.vr.direction.yaw+40;this.Fa.style[si("transform")]="scale(0.875) rotate("+t+"deg) skew("+"-10deg)"}dispose(){this.ws.vr.removeEventListener("statechange",this.Ia),this.ws.vr.removeEventListener("directionchange",this.$a),super.dispose()}constructor(t,i,s){super(t,i),this.Ia=()=>this._n(),this.$a=()=>this.Da(),this.ws=s,this.ws.vr.addEventListener("statechange",this.Ia),this.ws.vr.addEventListener("directionchange",this.$a),this._n(),this.Da()}},Ju=_.pow(2,31)-1,Qu=Co.getComponent("Component"),Yu=class extends Qu{Ra(){this.ws.vr.state===yt.Oa?this.Va():this.Ua()}Va(){if(this.za)return;this.za=!0;let t=this.ws.element;this.La=t.style.zIndex||"",t.style.zIndex=""+Ju,this.Ha=this.player().isFullscreen(),this.player().requestFullscreen()}Ua(){if(!this.za)return;this.za=!1,this.ws.element.style.zIndex=this.La,this.Ha?this.player().requestFullscreen():this.player().exitFullscreen()}dispose(){this.Ua(),this.ws.vr.removeEventListener("statechange",this.qa),super.dispose()}constructor(t,i,s){super(t,i),this.za=!1,this.Ha=!1,this.La="",this.qa=()=>this.Ra(),this.ws=s,this.ws.vr.addEventListener("statechange",this.qa),this.Ra()}};Mi((function(t){let i=t.va;if(!i.vr)return;let s=t.fo,e=new Xu(s,{},i);if(t.yn(L.lo,(()=>{var i;s.removeChild(e);let n=null==(i=t.Wa())?void 0:i.vr;void 0===n||n.nativeVR||s.addChild(e)})),At.Ga){let t=new Yu(s,{},i);s.addChild(t)}}));var Ku=class extends ${constructor(){super("relatedchange")}},Zu=["relatedchange"],tc=class extends D{get va(){return this.Xa||(this.Xa=function(t){let i,s={get sources(){return t.Ja},set sources(i){t.Ja=i},addEventListener(t,s){i.yn(t,s)},removeEventListener(t,s){i.fn(t,s)}};return i=new Rt(Zu,!0,s),i.Qa(t),s}(this)),this.Xa}get Ja(){return this.Ya}set Ja(t){this.Ya=function(t){return t.filter((t=>t&&($t(t.link)||Y(t,["source"]))))}(t),t.length>this.Ya.length&&console.warn("One or more of the configured related content sources are invalid. Check if they have a source or a link."),this.Co(new Ku)}gn(){this.Vo(),this.Ya=[]}constructor(...t){super(...t),this.Ya=[]}};xt((function(t){return class extends t{fa(){const t=this.Ka;return G(super.fa(),{get related(){return t.va}})}gn(){this.Ka.gn(),super.gn()}constructor(t,i){super(t,i),this.Ka=new tc}}}),wt.Za);var ic=Co.getComponent("Button"),sc=class extends ic{buildCSSClass(){return"vjs-icon-view-grid theo-related-button "+super.buildCSSClass()}handleClick(){this.iu.tu?this.iu.be():this.iu.ge()}te(){this.Ie.Be=this.controlText()}dispose(){this.player().topControlBar.removeChild(this),super.dispose()}constructor(t,i,s){super(t,s),this.yo=t.el(),this.iu=i,this.player().topControlBar.addChild(this),this.hide(),this.controlText(this.localize("Related content")),this.Ie=new na(this,this.controlText()),this.on(t,"languagechange",this.te)}},ec=Co.getComponent("Button"),nc=class extends ec{buildCSSClass(){return"theo-secondary-background theo-close-button"}handleClick(){this.su.hide()}constructor(t,i){super(t),this.su=i}},rc=(()=>{let t=h.createElement("div");return t.className="theo-related-grid-tile",t.innerHTML='<a class="theo-related-grid-tile-content"><div class="theo-related-grid-tile-image"></div><span class="theo-related-grid-tile-title theo-primary-border theo-tertiary-background"></span><span class="theo-related-grid-tile-duration"></span></a>',t})();function hc(t,i,s){let e=rc.cloneNode(!0),n=e.querySelector(".theo-related-grid-tile-content");Y(s,["source"])?(n.style.cursor="pointer",n.addEventListener("click",(()=>{t.source=s.source,i.be()}))):$t(s.link)&&n.setAttribute("href",s.link);let r=e.querySelector(".theo-related-grid-tile-image");r.style.backgroundImage='url("'+gi(s.image)+'")',r.removeAttribute("id");let h=e.querySelector(".theo-related-grid-tile-title");s.title?(l(h,s.title),h.removeAttribute("id")):qt(h);let o=e.querySelector(".theo-related-grid-tile-duration");return s.duration?(l(o,s.duration),o.removeAttribute("id")):qt(o),e}var oc=[15,12,9,8,6,4,3,2,1];var ac=class{get eu(){return"theo-"+this.nu+"-item-grid"}ru(){this.hu.focus()}ou(t){this.au(),function(t){if(t.length)for(let i of oc)if(t.length>=i){t.length=i;break}}(t),this.uu(t.length);for(let i of t){let t=hc(this.cu.va,this.lu,i);this.du.appendChild(t)}}au(){this.du.innerHTML=""}fu(){let t=h.createElement("div");t.className="theo-overlay-panel";const i=h.createElement("div");return i.className="theo-related-grid",this.vu.className="theo-related",this.hu.controlText("Close Related Content"),this.pu.appendChild(this.vu),this.vu.appendChild(t),t.appendChild(this.hu.el()),t.appendChild(i),i}uu(t){Zt(this.du,this.eu),this.nu=t,Yt(this.du,this.eu)}gn(){qt(this.vu),this.mu.gn(),this.gu.gn(),this.hu.dispose(),this.cu=void 0}constructor(t,i,s,e,n){this.cu=t,this.yu=i,this.lu=s,this.pu=e,this.nu=12,this.bu=t=>{this.du.style.width=t.width+"px"},this.vu=h.createElement("div"),this.hu=new nc(this.yu,{hide:()=>{this.lu.be()}}),this.du=this.fu(),this.gu=new uc(n),this.gu.yn(Kt.pn,this.bu),this.mu=new dt(this.du,this.gu),this.uu(12)}},uc=class extends D{get ku(){return this.wu||0}get _u(){return this.xu._u}gn(){this.Vo(),this.xu.fn(Kt.pn,this.Cu)}constructor(t){super(),this.xu=t,this.Cu=t=>{let i=t.width;if(9*(t.width/16)>t.height){i=16*(t.height/9)}this.wu=i,this.Co(new ti(this.ku,t.height))},this.xu.yn(Kt.pn,this.Cu)}},cc=class extends ${constructor(){super("show")}},lc=class extends ${constructor(){super("hide")}},dc="theo-related-available",fc="theo-related-showing",vc=[...Zu,"show","hide"],pc=class extends D{get va(){return this.Xa||(this.Xa=function(t){let i;const s={get sources(){return t.Ja},set sources(i){t.Ja=i},get showing(){return t.tu},show(){t.ge()},hide(){t.be()},addEventListener(t,s){i.yn(t,s)},removeEventListener(t,s){i.fn(t,s)}};return i=new Rt(vc,!0,s),i.Qa(t),s}(this)),this.Xa}get Ja(){return this.Su.Ja}set Ja(t){this.Su.Ja=t}get tu(){return this.ju}ge(){let t=this.ju;this.ju=!0,this.Tu(fc),this.Mu.ru(),this.yu.paused()?this.Au=!0:this.yu.pause(),t!==this.ju&&this.Co(new cc)}be(){let t=this.ju;this.ju=!1,this.Pu(fc),this.Eu.focus(),this.Au||this.yu.play(),this.Au=!1,t!==this.ju&&this.Co(new lc)}Tu(t){this.yu.el().classList.add(t)}Pu(t){this.yu.el().classList.remove(t)}gn(){this.Vo(),this.Mu.gn()}constructor(t,i,s,e){super(),this.ju=!1,this.Au=!1,this.Nu=t=>{const i=this.Ja;this.Mu.ou(i),i.length?(this.Tu(dc),this.Eu.show()):(this.Pu(dc),this.Eu.hide()),this.Co(t)},this.Su=i,this.Su.yn("relatedchange",this.Nu),this.yu=s,this.Mu=new ac(t,this.yu,this,s.contentEl(),e),this.Eu=new sc(s,this,{})}};ji((function(t){return class extends t{fa(){const t=this.Bu;return G(super.fa(),{get related(){return t.va}})}gn(){this.Bu.gn(),super.gn()}constructor(t,i,s){super(t,i,s),this.Bu=new pc(this,this.Ka,this.fo,this.Iu)}}}));var mc,gc=Co.getComponent("Button"),yc=class extends gc{buildCSSClass(){return"vjs-icon-share theo-social-button "+super.buildCSSClass()}handleClick(){this.Fu.showing?this.Fu.hide():this.Fu.show()}te(){this.Ie.Be=this.controlText()}dispose(){this.player().topControlBar.removeChild(this),super.dispose()}constructor(t,i,s){super(t,s),this.yo=t.el(),this.Fu=i,this.player().topControlBar.addChild(this),this.hide(),this.controlText("Share Video"),this.Ie=new na(this,this.controlText()),this.on(t,"languagechange",this.te)}};function bc(t,i,s){switch(i){case"iconurl":return function(t,i){let s=h.createElement("a");var e;s.className="theo-social-iconurl",s.title=null!=(e=t.label)?e:"",s.target="Du",s.href=i;const n=h.createElement("img");var r,o;return n.src=null!=(r=t.icon)?r:"",n.alt=null!=(o=t.label)?o:"",n.width=25,n.height=25,s.appendChild(n),s}(t,s);case"text":return function(t){let i=h.createElement("div");if(i.className="theo-social-text",t.label){let s=h.createElement("h5");s.className="theo-primary-background theo-social-label",l(s,t.label),i.appendChild(s)}let s=h.createElement("p");var e;return s.className="theo-social-content-container theo-tertiary-background",s.tabIndex=0,l(s,null!=(e=t.text)?e:""),i.appendChild(s),i}(t);case"texturl":return function(t,i){let s=h.createElement("div");if(s.className="theo-social-texturl",t.label){let i=h.createElement("h5");i.className="theo-primary-background theo-social-label",l(i,t.label),s.appendChild(i)}let e=h.createElement("div");e.className="theo-social-content-container theo-tertiary-background";let n=h.createElement("a");return n.target="Du",n.href=i,l(n,i),e.appendChild(n),s.appendChild(e),s}(t,s)}}!function(t){t.$u="iconurl",t.Ru="text",t.Ou="texturl"}(mc||(mc={}));var kc="<URL>";var wc=class{get we(){return this.vu}Vu(t){this.au();for(let i of t)this.Uu(i)}ru(){this.hu.focus()}Uu(t){let i=function(t,i){return t.src?pi(t.src,kc)?t.src.replace(kc,i):t.src:i}(t,this.lu.zu),s=function(t){if(t)return t.icon?"iconurl":t.text?"text":"texturl"}(t),e=bc(t,s,i);e&&("iconurl"===s?this.Lu.appendChild(e):this.Hu.appendChild(e))}au(){this.Lu.innerHTML="",this.Hu.innerHTML=""}gn(){qt(this.vu),this.qu.gn()}constructor(t,i,s,e){this.Qo=t,this.lu=i,this.pu=s,this.Wu=e;const n=h.createElement("div");n.className="theo-overlay-panel",this.hu=new nc(this.Qo,this.lu.va),this.hu.controlText("Close Share"),this.Mu=h.createElement("div"),this.Mu.className="theo-social-container",this.vu=h.createElement("div"),this.vu.className="theo-social",this.Lu=h.createElement("div"),this.Lu.className="theo-social-icon-container",this.Hu=h.createElement("div"),this.Hu.className="theo-social-text-container",this.pu.appendChild(this.vu),this.vu.appendChild(n),this.Mu.appendChild(this.Lu),this.Mu.appendChild(this.Hu),n.appendChild(this.hu.el()),n.appendChild(this.Mu),this.qu=new dt(this.vu,this.Wu)}},_c="theo-social-available",xc="theo-social-showing",Cc=class{get va(){return this.Xa}get tu(){return this.ju}get Gu(){return this.Xu}set Gu(t){this.Xu=t,this.Mu.Vu(t),t.length?(this.Tu(_c),this.Eu.show()):(this.Pu(_c),this.Eu.hide())}get zu(){return this.Ju||Lt()}set zu(t){this.Ju=t}ge(){this.ju=!0,this.Tu(xc),this.Mu.ru(),this.Qu.paused()?this.Au=!0:this.Qu.pause()}be(){this.ju=!1,this.Pu(xc),this.Eu.focus(),this.Au||this.Qu.play(),this.Au=!1}Tu(t){this.Qu.el().classList.add(t)}Pu(t){this.Qu.el().classList.remove(t)}gn(){this.Eu.dispose(),this.Mu.gn()}constructor(t,i){this.ju=!1,this.Xu=[],this.Au=!1,this.Xa=function(t){return{get showing(){return t.tu},get items(){return t.Gu},set items(i){t.Gu=i},get url(){return t.zu},set url(i){t.zu=i},show(){t.ge()},hide(){t.be()}}}(this),this.Qu=t,this.Mu=new wc(this.Qu,this,t.contentEl(),i),this.Eu=new yc(t,this.Xa,{})}};ji((function(t){return class extends t{fa(){let t=this.Fu;return G(super.fa(),{get social(){return t.va}})}constructor(t,i,s){super(t,i,s),this.Fu=new Cc(this.fo,this.Iu)}}}));var Sc=Co.getComponent("Component"),jc=class extends Sc{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-upnext-container "+super.buildCSSClass()}};jc.prototype.h=fi({},jc.prototype.h,{children:[]}),Co.registerComponent("upNextContainer",jc);var Tc="theo-upnext-bar-",Mc=Co.getComponent("Component"),Ac=class extends Mc{get tu(){return this.ju}set tu(t){this.ju=t,this.Yu&&(this.Yu.tabIndex=t?0:-1)}get Ku(){return this.Zu}set Ku(t){this.Zu=t}ga(t){this.au(),this.tc(t)}tc(t){if(t&&t.link&&t.image){const i=h.createElement("div");Yt(i,Tc+"content"),i.onclick=()=>{this.ic.next()},i.onkeypress=t=>{13===t.which&&this.ic.next()};let s=h.createElement("div");if(s.style.backgroundImage='url("'+gi(t.image)+'")',Yt(s,Tc+"image"),i.appendChild(s),t.duration){let i=h.createElement("span");Yt(i,Tc+"duration"),i.innerHTML=""+t.duration,s.appendChild(i)}let e=h.createElement("div");Yt(e,Tc+"text");let n=h.createElement("div");if(Yt(n,Tc+"upnext"),l(n,this.localize("Up Next")),e.appendChild(n),t.title){let i=h.createElement("div");Yt(i,Tc+"title"),l(i,t.title),e.appendChild(i)}i.appendChild(e),this.Yu=i,this.sc=n,this.el().appendChild(this.Yu)}}au(){this.el().innerHTML="",this.Yu=void 0,this.sc=void 0}te(){this.sc&&l(this.sc,this.localize("Up Next"))}createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-upnext-bar "+super.buildCSSClass()}dispose(){this.qu.gn(),super.dispose()}constructor(t,i,s,e){super(t,s),this.Yu=void 0,this.sc=void 0,this.ic=i,this.qu=new dt(this.el(),e),this.ju=!1,this.Zu=10,this.on(t,"languagechange",this.te)}},Pc="theo-upnext-panel-",Ec=vu,Nc=Co.getComponent("Component"),Bc=class extends Nc{get tu(){return this.ju}set tu(t){this.ju=t}get ec(){return this.nc}set ec(t){this.nc=t}get rc(){return this.hc}set rc(t){this.hc=t}ga(t){this.au(),this.oc(t)}oc(t){if(t&&t.link&&t.image){let i=h.createElement("div");i.className=Pc+"content";let s=h.createElement("div");s.style.backgroundImage='url("'+gi(t.image)+'")',s.className=Pc+"image",i.appendChild(s);let e=h.createElement("div");e.className=Pc+"text";let n=h.createElement("div");if(n.className=Pc+"upnext",l(n,this.localize("Up Next")),e.appendChild(n),t.title){let i=h.createElement("div");i.className=Pc+"title",l(i,t.title),e.appendChild(i)}i.appendChild(e),this.ac=h.createElement("div"),this.ac.className=Pc+"autoplay",this.ac.innerHTML=pu;let r=this.ac.querySelector("svg");r.onclick=()=>{this.ic.next()},r.tabIndex=0,r.onkeypress=t=>{13===t.which&&this.ic.next()},this.uc=n,this.cc=this.ac.querySelector("."+Ec),i.appendChild(this.ac),this.el().appendChild(i)}}get lc(){return this.dc}set lc(t){this.dc=t,this.cc.style.strokeDashoffset=""+_.round(1e5*t)/1e5}au(){this.el().innerHTML="",this.uc=void 0,this.cc=void 0}te(){this.uc&&l(this.uc,this.localize("Up Next"))}createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-upnext-panel "+super.buildCSSClass()}dispose(){this.qu.gn(),super.dispose()}constructor(t,i,s,e){super(t,s),this.dc=0,this.ic=i,this.qu=new dt(this.el(),e),this.ju=!1,this.nc=10,this.hc=!0,this.on(t,"languagechange",this.te)}},Ic="theo-upnext-panel-showing",Fc="theo-upnext-bar-showing",Dc=2*_.PI*73,$c=class t{get va(){return this.Xa}get fc(){return this.vc}get mc(){return this.gc}get yc(){return this.bc}set yc(t){this.bc=t,this.Mu.ga(t),this.kc.ga(t),this.Qu.off("timeupdate",this.wc),this.Qu.off("ended",this._c),t&&(this.Qu.on("timeupdate",this.wc),this.Qu.on("ended",this._c))}xc(){this.Mu.ec?this.Cc=it(this.Mu.ec):0===this.Mu.ec?this.Cc=0:this.Cc=10,0!==this.Cc?(isFinite(this.Cc)&&(this.Sc=!0),this.Mu.tu=!0,this.Tu(Ic),this.Sc&&(this.Mu.lc=Dc-Dc/this.Cc,this.jc=v(this.Tc,1e3))):this.Mc()}Ac(){this.Mu.tu=!1,this.Pu(Ic),this.Sc&&(m(this.jc),this.Pc=1,this.Mu.lc=Dc)}Ec(){this.kc.tu=!0,this.Tu(Fc)}Nc(){this.kc.tu=!1,this.Pu(Fc)}Mc(){m(this.jc),this.yc&&(s.location.href=this.yc.link)}Tu(t){this.Qu.el().classList.add(t)}Pu(t){this.Qu.el().classList.remove(t)}Bc(t,i){const s=t>=i&&!(this.Ic&&this.Ic.Fc);this.kc.tu&&!s?this.Nc():!this.kc.tu&&s&&this.Ec()}Dc(t,i){this.Mu.tu&&t<i&&!this.Qu.ended()&&this.Ac()}static $c(t,i){let s=it(t);if(!S(s))return i-s;let e=(""+t).match(/^([1-9]?\d|100)%$/);if(e){return i*(1-x(e[1],10)/100)}}gn(){this.jc&&m(this.jc),this.Qu.getChild("upNextContainer").removeChild(this.Mu),this.Qu.getChild("upNextContainer").removeChild(this.kc),this.Mu.dispose(),this.kc.dispose()}constructor(i,s,e){this.bc=void 0,this.Cc=10,this.Pc=1,this.jc=void 0,this.Sc=!0,this.Tc=()=>{this.Pc!==this.Cc?(this.Mu.lc-=Dc/this.Cc,this.Pc+=1):this.Mc()},this._c=()=>{this.Mu.tu||this.xc()},this.wc=()=>{let i=this.Qu.currentTime(),s=this.Qu.duration(),e=s?t.$c(this.kc.Ku,s):void 0;void 0!==e&&this.Bc(i,e),this.Mu.rc&&this.Dc(i,s)},this.Xa=function(t){return{get source(){return t.yc},set source(i){t.yc=i},get bar(){return t.fc},get panel(){return t.mc},next(){t.Mc()}}}(this),this.kc=new Ac(i,this.Xa,{},s),this.Mu=new Bc(i,this.Xa,{},s),this.vc=function(t,i){return{get showing(){return i.tu},get offset(){return i.Ku},set offset(t){i.Ku=t},show(){t.Ec()},hide(){t.Nc()}}}(this,this.kc),this.gc=function(t,i){return{get showing(){return i.tu},get countdownDuration(){return i.ec},set countdownDuration(t){i.ec=t},get showUpNextPanel(){return i.rc},set showUpNextPanel(t){i.rc=t},show(){t.xc()},hide(){t.Ac()}}}(this,this.Mu),this.Qu=i,this.Ic=e,i.getChild("upNextContainer").addChild(this.kc,{}),i.getChild("upNextContainer").addChild(this.Mu,{})}};ji((function(t){return class extends t{fa(){let t=this.Rc;return G(super.fa(),{get upnext(){return t.va}})}gn(){this.Rc.gn(),super.gn()}constructor(t,i,s){super(t,i,s),this.Rc=new $c(this.fo,this.Iu,this.Oc)}}}));var Rc=Co.getComponent("Component"),Oc=class extends Rc{createEl(){let t=super.createEl("ul",{className:"theo-context-menu"}),i=h.createElement("li"),s=h.createElement("a"),e=h.createElement("div");s.className="theo-context-menu-a",i.appendChild(s),e.className="theo-context-menu-logo",e.innerHTML='<svg version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"\n\t width="507.262px" height="399.16px" viewBox="0 0.1 507.262 399.16" enable-background="new 0 0.1 507.262 399.16"\n\t xml:space="preserve" class=\'theo-context-menu-logo-svg\'>\n\t<g transform="matrix(1.90897, 0, 0, 1.90897, 212.4, 144.6)">\n\t\t<path fill="#FFFFFF" d="M-38.416-53.802C-53.351-38.867-60.82-20.814-60.82,0.353c0,21.253,7.466,39.392,22.404,54.413\n\t\t\tc6.83,6.658,13.827,11.778,20.996,15.363c5.122,2.561,10.583,4.397,16.388,5.507v1.024h-78.481\n\t\t\tc-21.168,0-31.752-10.584-31.752-31.752v-88.724c0-21.252,10.584-31.879,31.752-31.879h79.377v0.896\n\t\t\tc-6.145,1.196-11.95,3.116-17.411,5.762C-24.632-65.538-31.586-60.46-38.416-53.802"/>\n\t</g>\n\t<g transform="matrix(0.535073, 0, 0, 0.535073, 242.35, 104.7)">\n\t\t<path fill="#FFFFFF" d="M188.354,104.104c-32.941,23.472-75.492,49.679-127.641,78.61c-50.275,28.254-94.358,50.44-132.254,66.572l-41.989,15.616\n\t\t\tc-2.645-11.348-5.122-28.17-7.426-50.44c-5.205-44.383-7.809-93.375-7.809-146.975c0-49.079,3.538-94.947,10.622-137.631\n\t\t\tl10.249-49.034l44.551,14.978C-24.762-88.838,17.06-67.03,62.124-38.777c47.705,29.871,88.638,58.294,122.773,85.266\n\t\t\tc17.061,13.571,29.351,24.028,36.862,31.367L188.354,104.104"/>\n\t</g>\n\t<g transform="matrix(1.91028, 0, 0, 1.91028, 327.15, 144.6)">\n\t\t<path fill="#FFFFFF" d="M94.286-43.816v88.723c0,21.168-10.583,31.751-31.751,31.751h-80.018v-1.025\n\t\t\tc14.683-2.816,27.527-9.77,38.537-20.867c14.936-15.024,22.405-33.16,22.405-54.413c0-21.168-7.467-39.22-22.405-54.156\n\t\t\tC9.871-64.985-3.188-71.939-18.123-74.671v-1.024h80.658C83.702-75.696,94.286-65.069,94.286-43.816"/>\n\t</g>\n</svg>\n',s.appendChild(e);let n=h.createElement("div");return n.className="theo-context-version",l(n,"Powered by THEOplayer 8.2.0"),s.appendChild(n),s.href="https://www.theoplayer.com/player-referral",s.target="Du",t.appendChild(i),t}Vc(t){const i=t;i.preventDefault(),this.show(),this.el().style.left="0",this.el().style.top="0";let s=this.player().contentEl(),e=s.getClientRects(),n=e.length>0?e[0]:void 0,r=i.clientX-s.getBoundingClientRect().left,h=C(getComputedStyle(this.el()).fontSize);B(this.el(),r,n,h);let o=i.clientY-s.getBoundingClientRect().top;F(this.el(),o,n,h),this.Uc()}zc(){this.hide(),this.clearTimeout(this.Lc)}Uc(){this.Lc=this.setTimeout(this.zc,4e3)}Hc(){this.clearTimeout(this.Lc)}dispose(){this.zc(),this.off(this.player(),"contextmenu",this.Vc),this.el().removeEventListener("mousedown",Vc,!0),this.off(h,"mousedown",this.zc),this.off("mouseout",this.Uc),this.off("mouseover",this.Hc),super.dispose()}constructor(t,i){super(t,i),this.Lc=0,this.on(this.player(),"contextmenu",this.Vc),this.el().addEventListener("mousedown",Vc,!0),this.on(h,"mousedown",this.zc),this.on("mouseout",this.Uc),this.on("mouseover",this.Hc),this.zc()}};function Vc(t){t.stopPropagation()}Mi((function(t){const i=new Oc(t.fo,{});t.fo.addChild(i),t.fo.on("dispose",(()=>{t.fo.removeChild(i),i.dispose()}))}));var Uc={Default:"","Monospaced Serif":vi.qc,"Proportional Serif":vi.Wc,"Monospaced Sans-Serif":vi.Gc,"Proportional Sans-Serif":vi.Xc},zc={White:"#ffffff",Yellow:"#ffff00",Green:"#00ff00",Cyan:"#00ffff",Blue:"#0000ff",Magenta:"#ff00ff",Red:"#ff0000",Black:"#000000"},Lc=[50,75,100,150,200];function Hc(t){return{label:t+"%",value:t}}function qc(t){return w.keys(t).map((i=>({label:i,value:t[i]})))}Lc.map((function(t){return{label:t+"%",value:t/100+"em"}}));var Wc=Lc.map((function(t){return{label:t+"%",value:t+"%"}})),Gc=[25,50,75,100].map(Hc),Xc=[0,25,50,75,100].map(Hc),Jc=qc(zc),Qc=qc(Uc),Yc=qc({None:"none","Drop Shadow":"dropshadow",Raised:"raised",Depressed:"depressed",Uniform:"uniform"}),Kc=100,Zc="#000000",tl="#FFFFFF",il="#000000",sl=class extends Ha{Jc(){let t=this.Fr.localize(this.Qc);l(this.Yc.subMenu.menuHeader.el(),t),this.Ir=h.createElement("span"),this.Ir.className="theo-settings-control-menu-item-title",l(this.Ir,t);let i=h.createElement("span");return i.className="theo-primary-color theo-settings-control-menu-item-value",Yt(this.Yc.el(),"theo-subtitle-options-menu-item"),this.Yc.el().appendChild(this.Ir),this.Yc.el().appendChild(i),i}Kc(t){const i=this.jr(t);i&&this.Zc(i)}tl(){return this.br}Ar(t){this.il(t.Tr)}Zc(t){for(let t of this.Cr.menuItems)t.selected(!1);t?(t.selected(!0),this.sl(t.Tr.label)):this.sl("Custom")}sl(t){this.nl=t,l(this.rl,this.Fr.localize(t)),this.Yc.parentMenu.re()}Mr(t){let i=super.Mr(t);return Yt(i.el(),"theo-subtitle-options-menu-item"),this.Nr(i),i}Nr(t){const i=this.Fr.localize(t.Tr.label);l(t.el(),i);const s=this.Fr.localize("Set "+this.Qc+" to ")+i;t.el().setAttribute("aria-label",s)}Re(){this.Fr.off("languagechange",this.te),super.Re()}constructor(t,i,s,e){super(t.subMenu),this.Yc=t,this.Fr=e,this.nl="",this.te=()=>{let t=this.Fr.localize(this.Qc);l(this.Yc.subMenu.menuHeader.el(),t),l(this.Ir,t),this.sl(this.nl);for(const t of this.Sr)this.Nr(t)},this.Qc=i,this.il=s.Ko,this.rl=this.Jc(),this.br=s.hl,this.Fr.on("languagechange",this.te)}},el=class t{static ol(t,i,s,e){if(void 0===t&&void 0===i)return;return Ci(void 0===t?s:t,void 0===i?e:i)}constructor(i){this.al=i,this.cl=t=>{this.al.fontFamily=t.value},this.ll=t=>{this.al.fontSize=t.value},this.dl=i=>{this.fl=i.value,this.al.fontColor=t.ol(this.vl,this.fl,tl,Kc)},this.pl=i=>{this.vl=i.value,this.al.fontColor=t.ol(this.vl,this.fl,tl,Kc)},this.ml=i=>{this.gl=i.value,this.al.backgroundColor=t.ol(this.gl,this.yl,Zc,Kc)},this.bl=i=>{this.yl=i.value,this.al.backgroundColor=t.ol(this.gl,this.yl,Zc,Kc)},this.kl=i=>{this.wl=i.value,this.al.windowColor=t.ol(this.wl,this._l,il,Kc)},this.xl=i=>{this._l=i.value,this.al.windowColor=t.ol(this.wl,this._l,il,Kc)},this.Cl=t=>{this.al.edgeStyle=t.value}}},nl=class{Sl(t,i){const s=this.jl(t,i.tl());s&&i.Kc(s)}jl(t,i){return M(i,(i=>i.value===t))}Tl(t,i,s){let e,n;if(void 0===t)e=this.jl(void 0,i.tl()),n=this.jl(void 0,s.tl());else if(t){let r=function(t){let i=_i(t);i||(i=_i(t.slice(0,t.length-1).replace("rgb","rgba")+",1)"));i||(i=mi(yi(t),1));if(!i){let s=t.charAt(0).toUpperCase()+t.toLowerCase().slice(1);i=mi(yi(zc[s]),1)}return i}(t);if(r){let t=ki(r),h=100*r.Ml;e=this.jl(t,i.tl()),n=this.jl(h,s.tl())}}e&&i.Kc(e),n&&s.Kc(n)}constructor(t,i){this.al=t,this.Al=i,this.Pl=()=>{let t=this.al.fontFamily;this.Sl(t,this.Al["Font family"]);let i=this.al.fontColor;this.Tl(i,this.Al["Font color"],this.Al["Font opacity"]);let s=this.al.fontSize;this.Sl(s,this.Al["Font size"]);let e=this.al.backgroundColor;this.Tl(e,this.Al["Background color"],this.Al["Background opacity"]);let n=this.al.windowColor;this.Tl(n,this.Al["Window color"],this.Al["Window opacity"]);let r=this.al.edgeStyle;this.Sl(r,this.Al["Character edge style"])},this.al.addEventListener("change",this.Pl),this.Pl()}};var rl=class extends Ha{El(){return{"Font family":{hl:hl(Qc),Ko:this.Nl.cl},"Font color":{hl:hl(Jc),Ko:this.Nl.pl},"Font opacity":{hl:hl(Gc),Ko:this.Nl.dl},"Font size":{hl:hl(Wc),Ko:this.Nl.ll},"Background color":{hl:hl(Jc),Ko:this.Nl.ml},"Background opacity":{hl:hl(Xc),Ko:this.Nl.bl},"Window color":{hl:hl(Jc),Ko:this.Nl.kl},"Window opacity":{hl:hl(Xc),Ko:this.Nl.xl},"Character edge style":{hl:hl(Yc),Ko:this.Nl.Cl}}}Bl(){this.Ir=h.createElement("span"),this.Ir.className="theo-settings-control-menu-item-title",this.Il=h.createElement("span"),this.Il.className="theo-primary-color theo-settings-control-menu-item-value",this.Lr.el().appendChild(this.Ir),this.Lr.el().appendChild(this.Il),this.te()}Mr(t){let i=this.Cr.addSubMenuItem();return i.Tr=t,this.Al[t]=new sl(i,t,this.Fl[t],this.Fr),i}Nr(t){}Ar(t){}Re(){this.Fr.off("languagechange",this.te),this.Dl.removeEventListener(["addtrack","removetrack"],this.$l),super.Re()}constructor(t,i,s,e){super(t.subMenu),this.Lr=t,this.Dl=i,this.Fr=e,this.Al={},this.$l=()=>{this.Dl.some((t=>pt(t.kind)))?this.Lr.show():this.Lr.hide()},this.te=()=>{l(this.Cr.menuHeader.el(),this.Fr.localize("Subtitle Options")),l(this.Ir,this.Fr.localize("Subtitle")),l(this.Il,this.Fr.localize("Options")),this.Lr.el().setAttribute("aria-label",this.Fr.localize("Open the subtitle options menu"))},this.Nl=new el(s),this.Fl=this.El(),this.br=w.keys(this.Fl),this.Bl(),this.Rl=new nl(s,this.Al),this.Fr.on("languagechange",this.te),this.Dl.addEventListener(["addtrack","removetrack"],this.$l),this.$l()}};function hl(t){let i=[{label:"Default",value:void 0}];for(let s of t)"Default"!==s.label&&i.push(s);return i}Mi((function(t){const i=t.fo.controlBar.getChild("SettingsButton").menu,s=i.addSubMenuItem({name:"TextTrackOptionsMenuItem"}),e=new rl(s,t.nt.va,t.Ol.va,t.fo);t.fo.on("dispose",(()=>{i.removeMenuItem(s),s.dispose(),e.Re(),i.dispose()}))}));var ol=Co.getComponent("Component"),al=class extends ol{buildCSSClass(){return"theo-ad-control-panel"}createEl(){const t=super.createEl();return t.className=this.buildCSSClass(),t}constructor(t,i){super(t,i),t.adControlBar=this}};al.prototype.h=fi({},ol.prototype.h,{children:[]}),Co.registerComponent("AdControlPanel",al);var ul=Co.getComponent("Component"),cl="theo-dai-countdown",ll=class extends ul{buildCSSClass(){return cl}createEl(t,i,s){const e=h.createElement("div");return e.className=cl,e}Vl(t,i){i.addEventListener("adbreakbegin",(()=>this.show())),i.addEventListener("adbreakend",(()=>this.hide())),t.addEventListener("timeupdate",this.te)}constructor(t,i,s){super(t,s),this.Qo=t,this.Xa=i,this.te=()=>{const t=this.Xa.ads;t.playing&&t.currentAdBreak&&t.currentAds.length&&l(this.contentEl(),function(t,i,s){const e=t.ads;let n="";const r=e.length;if(r>1){const t=e.indexOf(i)+1;n=s("Ad")+" "+t+"/"+r+". "}const h=_.ceil(t.maxRemainingDuration);return n+=s("The content will resume in {1} seconds.").replace("{1}",""+h),n}(t.currentAdBreak,t.currentAds[0],(t=>this.Qo.localize(t))))},this.yo=t.el(),this.Vl(i,i.ads),this.on(t,"languagechange",this.te)}};var dl=Co.getComponent("ClickableComponent"),fl=class extends dl{buildCSSClass(){return _t}createEl(t,i,s){return this.h.va.element.querySelector("."+_t)}emitTapEvents(){}te(){l(this.el(),this.localize("Learn more"))}constructor(t,i){super(t,i),l(this.el(),t.localize("Learn more")),this.Xa=i.va,this.yo=t.el(),this.on(t,"languagechange",this.te)}};Mi((function(t){if(t.va.ads&&t.Ul){const i=t.fo,s=new ll(i,t.va),e=new fl(i,{va:t.va});i.adControlBar.addChild(s),i.adControlBar.addChild(e)}}));var vl=Co.getComponent("Component"),pl=["addtrack","removetrack","change"],ml=class extends(Bo(vl)){createEl(){let t=super.createEl();return this.qualityLabel=Co.createEl("div",{className:"theo-quality-label-text"}),t.appendChild(this.qualityLabel),ri(this.qualityLabel),t}dispose(){this.qr&&(this.qr.removeEventListener("activequalitychanged",this.zl),this.qr=void 0),this.ws.videoTracks.removeEventListener(pl,this.nh),super.dispose()}constructor(t,i){super(t,i),this.qr=void 0,this.nh=()=>{const t=Va(this.ws.videoTracks);t!==this.qr&&(this.qr&&this.qr.removeEventListener("activequalitychanged",this.zl),this.qr=t,t&&t.addEventListener("activequalitychanged",this.zl),this.zl())},this.zl=()=>{const t=this.qr&&this.qr.activeQuality;if(!this.qualityLabel||!t)return;const i=t.label?t.label:t.height?t.height+"p":void 0;i&&(l(this.qualityLabel,i),this.addClass("theo-quality-label-show"),this.hideActiveQualityLabel())},this.hideActiveQualityLabel=()=>{this.resetTimeout(),this.startFadeOutID=this.setTimeout(this.fadeoutLabel,3750),this.removeLabelClassesID=this.setTimeout(this.hideLabel,4e3)},this.resetTimeout=()=>{this.startFadeOutID&&this.clearTimeout(this.startFadeOutID),this.removeLabelClassesID&&this.clearTimeout(this.removeLabelClassesID)},this.fadeoutLabel=()=>{this.addClass("theo-quality-label-fadeout")},this.hideLabel=()=>{this.removeClass("theo-quality-label-show"),this.removeClass("theo-quality-label-fadeout")},super.addClass("theo-quality-label"),this.ws.videoTracks&&(this.ws.videoTracks.addEventListener(pl,this.nh),this.nh())}};Co.registerComponent("activeQualityLabel",ml);var gl="theo-upcoming-ad-notification",yl=["adbreakbegin","adbreakend","adadded","adloaded","adbegin","adend"],bl=class extends(Bo(oa)){createEl(){const t=Co.createEl("div",{className:gl});return this.notificationText=Co.createEl("div",{className:gl+"text"}),t.appendChild(this.notificationText),t}Ll(){if(!this.ws.ads)return;const t=this.ws.ads.scheduledAdBreaks;let i,s=1/0;for(let e=0;e<t.length;e++){const n=t[e];let r=n.timeOffset;-1!==r&&r<s&&(s=r,i=n)}this.currentAdBreak=i,this.currentAdBreakValid=void 0!==i&&void 0!==i.ads&&i.ads.some((t=>"linear"===t.type))}Hl(){if(!this.ws.ads||this.ws.ads.playing||!this.currentAdBreak||!this.currentAdBreakValid||0===this.currentAdBreak.timeOffset)return void this.ql();const t=this.ws.currentTime;if(this.currentAdBreak.timeOffset>t+10)return void this.ql();const i=_.ceil(this.currentAdBreak.timeOffset-t);i<0?this.ql():this.Wl(i)}Wl(t){this.Gl!==t&&(l(this.notificationText,"Your video will be temporarily interrupted in 0:"+(t<10?"0"+t:t)),this.Gl=t,this.show())}ql(){this.Gl=NaN,this.hide()}dispose(){var t;this.ws.removeEventListener("timeupdate",this.handleTimeUpdate),null==(t=this.ws.ads)||t.removeEventListener(yl,this.handleAdEvent),this.currentAdBreak=void 0,super.dispose()}constructor(t,i){super(t,i),this.currentAdBreak=void 0,this.currentAdBreakValid=!1,this.Gl=NaN,this.handleTimeUpdate=()=>{this.Hl()},this.handleAdEvent=()=>{this.Ll(),this.Hl()},this.ws.ads&&(this.hide(),this.ws.addEventListener("timeupdate",this.handleTimeUpdate),this.ws.ads.addEventListener(yl,this.handleAdEvent))}};Co.registerComponent("upcomingAdNotificationText",bl);var kl=Co.getComponent("Component");Co.registerComponent("VerizonMediaAdBreakBar",class extends kl{createEl(){const t=h.createElement("div");return t.className="theoplayer-ad-overlay-component theo-ad-remaining-container",t}get Xl(){return this.h.adBreakProvider()}te(t,i){if(this.Xl&&this.Xl.endTime){const s=_.max(this.Xl.endTime-t,0);l(i,"Content will resume in "+_.ceil(s)+"s"),this.show()}else this.hide()}constructor(t,i){super(t,i),this.Jl=()=>{this.te(this.player().currentTime(),this.el())},this.on(t,"timeupdate",this.Jl)}});var wl=Co.getComponent("ClickableComponent");Co.registerComponent("VerizonMediaAdSkipButton",class extends wl{createEl(){const t=h.createElement("div");return t.className="theoplayer-ad-overlay-component theoplayer-ad-skip theoplayer-ad-skip-countdown",this.Ql=h.createElement("span"),t.appendChild(this.Ql),this.te(t,this.Ql),t}handleClick(){this.h.skipCallback()}te(t,i){this.Yl<=ot.Zl.Kl?(Zt(t,"theoplayer-ad-skip-countdown"),Yt(t,"theoplayer-ad-skip-button"),l(i,"Skip ads")):l(i,"Skip ads in "+_.ceil(this.Yl)+"s")}get Yl(){return this.h.adBreak.startTime+this.h.adBreak.skipOffset-this.player().currentTime()}constructor(t,i){super(t,i),this.Jl=()=>{this.te(this.el(),this.Ql)},this.on(t,"timeupdate",this.Jl)}});var _l=Co.getComponent("Component"),xl=class extends _l{buildCSSClass(){return"theo-verizonmedia-marker-bar"}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}constructor(t,i){super(t,i)}};Co.registerComponent("VerizonMediaAdBreakMarkerBar",class extends xl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-bar-adbreak"}});var Cl=Co.getComponent("Component"),Sl=class extends Cl{get startTime(){return this.h.startTime}get endTime(){return this.h.endTime}get seekable(){return this.player().seekable()}buildCSSClass(){return"theo-verizonmedia-marker"}createEl(t,i,s){const e=h.createElement("div");e.className=this.buildCSSClass();const n=this.seekable.start(0),r=this.seekable.end(this.seekable.length-1),o=_.max(this.startTime-n,0),a=void 0!==this.endTime?_.max(r-this.endTime,0):0,u=r-n;return e.style.left=o/u*100+"%",e.style.right=a/u*100+"%",e}constructor(t,i){super(t,i)}};Co.registerComponent("VerizonMediaAdBreakMarker",class extends Sl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-adbreak"}});Co.registerComponent("VerizonMediaAssetMarkerBar",class extends xl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-bar-asset"}});Co.registerComponent("VerizonMediaAssetMarker",class extends Sl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-asset"}});var jl=Co.getComponent("Component");Co.registerComponent("VerizonMediaContentNotificationBar",class extends jl{buildCSSClass(){const t="theo-verizonmedia-content-notification-bar",i=t+"-ios";return t+(At.Ga||At.td?" "+i:"")}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}constructor(t,i){super(t,i)}});var Tl,Ml=Co.getComponent("Component");function Al(t,i){return Boolean(t&&void 0===t.verizonMedia)||Boolean(t&&t.verizonMedia&&void 0===t.verizonMedia.ui)||Boolean(t&&t.verizonMedia&&t.verizonMedia.ui&&void 0===t.verizonMedia.ui[i])||Boolean(t&&t.verizonMedia&&t.verizonMedia.ui&&!0===t.verizonMedia.ui[i])}Co.registerComponent("VerizonMediaContentNotification",class extends Ml{get sd(){return this.h.asset}buildCSSClass(){return"theo-verizonmedia-content-notification"}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}ko(){const t=h.createElement("img");t.src=this.sd.posterUrl,t.className=this.buildCSSClass()+"-thumbnail",this.el().appendChild(t);const i=h.createElement("div");i.className=this.buildCSSClass()+"-description";const s=function(t){return"Next: "+t}(this.sd.description);l(i,s),this.el().appendChild(i),this.ed=h.createElement("div"),this.ed.className=this.buildCSSClass()+"-countdown",l(this.ed,this.nd),this.el().appendChild(this.ed)}get nd(){const t=_.min(10,this.rd);return"Starting in "+_.ceil(t)+" seconds"}get rd(){return _.max(0,this.sd.startTime-this.player().currentTime())}od(){const t=this.rd;t>10||t<=0?this.hide():(l(this.ed,this.nd),this.show())}constructor(t,i){super(t,i),this.ko(),this.on(t,"timeupdate",this.od),this.hide()}}),function(t){t.ad="VerizonMediaAdBreakBar",t.ud="VerizonMediaAdSkipButton",t.ld="VerizonMediaAdBreakMarkerBar",t.dd="VerizonMediaAdBreakMarker",t.fd="VerizonMediaAssetMarkerBar",t.vd="VerizonMediaAssetMarker",t.pd="VerizonMediaContentNotificationBar",t.md="VerizonMediaContentNotification"}(Tl||(Tl={})),ji((function(t){return class extends t{get gd(){return this.fo.controlBar.progressControl.seekBar}ga(t){this.yd=!1,this.va.removeEventListener("timeupdate",this.bd),this.fo.removeChild("VerizonMediaAdBreakBar"),this.fo.removeChild("VerizonMediaAdSkipButton"),this.gd.removeChild("VerizonMediaAdBreakMarkerBar"),this.gd.removeChild("VerizonMediaAssetMarkerBar"),this.fo.removeChild("VerizonMediaContentNotificationBar"),super.ga(t)}kd(){if(!function(t){return Al(t,"assetMarkers")}(this.wd)||!this.yd)return;const t=this.va.verizonMedia.assets.map((t=>({name:"VerizonMediaAssetMarker",startTime:t.startTime,endTime:t.endTime})));this.gd.removeChild("VerizonMediaAssetMarkerBar"),this.gd.addChild("VerizonMediaAssetMarkerBar",{children:t})}_d(){if(!function(t){return Al(t,"contentNotification")}(this.wd))return;const t=this.va.verizonMedia.assets.map((t=>({name:"VerizonMediaContentNotification",asset:t})));this.fo.removeChild("VerizonMediaContentNotificationBar"),this.fo.addChild("VerizonMediaContentNotificationBar",{children:t})}gn(){this.va.removeEventListener("timeupdate",this.bd),this.va.verizonMedia.ads.adBreaks.removeEventListener("addadbreak",this.xd),this.va.verizonMedia.ads.adBreaks.removeEventListener("removeadbreak",this.Cd),this.va.verizonMedia.assets.removeEventListener("addasset",this.Sd),this.va.verizonMedia.assets.removeEventListener("removeasset",this.Sd),this.va.removeEventListener("loadeddata",this.jd),super.gn()}constructor(t,i,s){super(t,i,s),this.yd=!1,this.jd=()=>{this.yd=!0,isFinite(this.Td())||this.va.addEventListener("timeupdate",this.bd),this.bd(),this.kd(),this._d()},this.xd=t=>{t.adBreak.addEventListener("adbreakbegin",this.Md),t.adBreak.addEventListener("adbreakend",this.Pd),this.bd()},this.Cd=t=>{t.adBreak.removeEventListener("adbreakbegin",this.Md),t.adBreak.removeEventListener("adbreakend",this.Pd),this.bd()},this.bd=()=>{if(!function(t){return Al(t,"adBreakMarkers")}(this.wd)||!this.yd)return;const t=this.va.verizonMedia.ads.adBreaks.map((t=>({name:"VerizonMediaAdBreakMarker",startTime:t.startTime,endTime:t.endTime})));this.gd.removeChild("VerizonMediaAdBreakMarkerBar"),this.gd.addChild("VerizonMediaAdBreakMarkerBar",{children:t})},this.Md=()=>{if(function(t){return Al(t,"adNotification")}(this.wd)){const t=this.va.verizonMedia.ads.currentAdBreak;this.fo.addChild("VerizonMediaAdBreakBar",{adBreakProvider:this.Ed}),-1!==t.skipOffset&&this.fo.addChild("VerizonMediaAdSkipButton",{adBreak:t,skipCallback:this.va.verizonMedia.ads.skip})}},this.Ed=()=>this.va.verizonMedia.ads.currentAdBreak,this.Pd=()=>{this.fo.removeChild("VerizonMediaAdBreakBar"),this.fo.removeChild("VerizonMediaAdSkipButton")},this.Sd=()=>{this.kd(),this._d()},this.va.verizonMedia.ads.adBreaks.addEventListener("addadbreak",this.xd),this.va.verizonMedia.ads.adBreaks.addEventListener("removeadbreak",this.Cd),this.va.verizonMedia.assets.addEventListener("addasset",this.Sd),this.va.verizonMedia.assets.addEventListener("removeasset",this.Sd),this.va.addEventListener("loadeddata",this.jd)}}}));export{W as ChromelessPlayer,U as ErrorCategory,O as ErrorCode,Du as Player,kt as cache,mt as cast,Q as features,tt as playerSuiteVersion,st as players,nt as registerContentProtectionIntegration,X as utils,K as version,Co as videojs};
|