@theoplayer/theoads 8.6.2 → 8.6.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/THEOplayer.chromeless.d.ts +1 -1
- package/THEOplayer.chromeless.esm.js +2 -2
- package/THEOplayer.chromeless.js +3 -3
- 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 +3 -3
package/THEOplayer.esm.js
CHANGED
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
THEOplayer is based on patented technology developed by
|
|
35
35
|
THEO Technologies (https://www.theoplayer.com).
|
|
36
36
|
|
|
37
|
-
Version: 8.6.
|
|
38
|
-
Created: 2024-12-
|
|
37
|
+
Version: 8.6.3
|
|
38
|
+
Created: 2024-12-12T16:56:33.413Z
|
|
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,b=a.Error,w=a.TypeError,k=a.SyntaxError,_=a.Object,x=a.Math,C=a.parseInt,S=a.parseFloat,j=a.isNaN,T=a.Uint8Array;a.Worker,a.WorkerGlobalScope,a.XMLHttpRequest;import{$ as M,$a as A,A as P,Aa as E,B as N,Ba as I,C as B,Ca as F,D,Da as $,E as R,Ea as O,F as V,Fa as U,G as z,Ga as L,H,Ha as q,I as W,Ia as f,J as G,Ja as X,K as J,Ka as Q,L as Y,La as K,M as Z,Ma as tt,N as it,Na as st,O as et,Oa as nt,P as rt,Pa as ht,Q as ot,Qa as at,R as ut,Ra as ct,S as lt,Sa as dt,T as ft,Ta as vt,U as pt,Ua as mt,V as gt,Va as yt,W as bt,Wa as wt,X as kt,Xa as _t,Y as xt,Ya as Ct,Z as St,Za as jt,_ as Tt,_a as Mt,a as At,aa as Pt,ab as Et,b as Nt,ba as It,bb as Bt,c as d,ca as Ft,cb as Dt,d as $t,da as Rt,e as Ot,ea as Vt,f as Ut,fa as zt,g as Lt,ga as Ht,h as qt,ha as Wt,i as Gt,ia as Xt,j as Jt,ja as Qt,k as Yt,ka as Kt,l as Zt,la as ti,m as ii,ma as si,n as ei,na as ni,o as ri,oa as hi,p as oi,pa as ai,q as ui,qa as ci,r as li,ra as di,s as fi,sa as vi,t as pi,ta as mi,u as gi,ua as yi,v as bi,va as wi,w as ki,wa as _i,x as xi,xa as Ci,y as Si,ya as ji,z as Ti,za as Mi}from"./THEOplayer.common.esm.js";d(),d(),d(),d();var Ai=[];function Pi(t){Ai.push(t)}var Ei=[];function Ni(t){Ei.push(t)}d(),d(),d(),d();var p=void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},Ii=void 0!==h?h:{createElement:function(){}};function Bi(t,i){return i||(i=t.slice(0)),t.raw=i,t}var Fi=1;function Di(){return Fi++}var $i,Ri=_.prototype.toString,Oi=function(t){return zi(t)?_.keys(t):[]};function Vi(t,i){Oi(t).forEach((function(s){return i(t[s],s)}))}function Ui(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 _.assign?_.assign.apply(_,[t].concat(s)):(s.forEach((function(i){i&&Vi(i,(function(i,s){t[s]=i}))})),t)}function zi(t){return!!t&&"object"==typeof t}function Li(t){return zi(t)&&"[object Object]"===Ri.call(t)&&t.constructor===_}var Hi=function(t,i,s){void 0===s&&(s=!!Ls&&Ls<11),"log"!==t&&i.unshift(t.toUpperCase()+":"),$i.history.push(i),i.unshift("VIDEOJS:");var e=p.console&&p.console[t];e&&(s&&(i=i.map((function(t){if(zi(t)||Array.isArray(t))try{return JSON.stringify(t)}catch(i){return String(t)}return String(t)})).join(" ")),e.apply?e[Array.isArray(i)?"apply":"call"](p.console,i):e(i))};($i=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];Hi("log",i)}).history=[],$i.error=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Hi("error",i)},$i.warn=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Hi("warn",i)};var qi=$i,Wi="undefined"!=typeof globalThis?globalThis:void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Gi(t){return t.replace(/\n\r?\s*/g,"")}var Xi,Ji=function(t){for(var i="",s=0;s<arguments.length;s++)i+=Gi(t[s])+(arguments[s+1]||"");return i};function Qi(t){return"string"==typeof t&&/\S/.test(t)}function Yi(t){if(/\s/.test(t))throw new b("class has illegal whitespace characters")}function Ki(){return Ii===p.document&&void 0!==Ii.createElement}function Zi(t){return zi(t)&&1===t.nodeType}function ts(t){return function(i,s){if(!Qi(i))return Ii[t](null);Qi(s)&&(s=Ii.querySelector(s));var e=Zi(s)?s:Ii;return e[t]&&e[t](i)}}function is(t,i,s,e){void 0===t&&(t="div"),void 0===i&&(i={}),void 0===s&&(s={});var n=Ii.createElement(t);return _.getOwnPropertyNames(i).forEach((function(t){var s=i[t];-1!==t.indexOf("aria-")||"role"===t||"type"===t?(qi.warn(Ji(Xi||(Xi=Bi(["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?ss(n,s):n[t]=s})),_.getOwnPropertyNames(s).forEach((function(t){n.setAttribute(t,s[t])})),e&&ks(n,e),n}function ss(t,i){return void 0===t.textContent?t.innerText=i:t.textContent=i,t}function es(t,i){i.firstChild?i.insertBefore(t,i.firstChild):i.appendChild(t)}var ns={},rs="vdata"+(new Date).getTime();function hs(t){var i=t[rs];return i||(i=t[rs]=Di()),ns[i]||(ns[i]={}),ns[i]}function os(t){var i=t[rs];return!!i&&!!_.getOwnPropertyNames(ns[i]).length}function as(t){var i=t[rs];if(i){delete ns[i];try{delete t[rs]}catch(i){t.removeAttribute?t.removeAttribute(rs):t[rs]=null}}}function us(t,i){return Yi(i),t.classList?t.classList.contains(i):function(t){return new RegExp("(^|\\s)"+t+"($|\\s)")}(i).test(t.className)}function cs(t,i){return t.classList?t.classList.add(i):us(t,i)||(t.className=(t.className+" "+i).trim()),t}function ls(t,i){return t.classList?t.classList.remove(i):(Yi(i),t.className=t.className.split(/\s+/).filter((function(t){return t!==i})).join(" ")),t}function ds(t,i,s){var e=us(t,i);if("function"==typeof s&&(s=s(t,i)),"boolean"!=typeof s&&(s=!e),s!==e)return s?cs(t,i):ls(t,i),t}function fs(t,i){_.getOwnPropertyNames(i).forEach((function(s){var e=i[s];null==e||!1===e?t.removeAttribute(s):t.setAttribute(s,!0===e?"":e)}))}function vs(t){var i={};if(t&&t.attributes&&t.attributes.length>0)for(var s=t.attributes,e=s.length-1;e>=0;e--){var n=s[e].name,r=s[e].value;"boolean"!=typeof t[n]&&-1===",autoplay,controls,playsinline,loop,muted,default,defaultMuted,".indexOf(","+n+",")||(r=null!==r),i[n]=r}return i}function ps(t,i,s){t.setAttribute(i,s)}function ms(t,i){t.removeAttribute(i)}function gs(t){var i;if(t.getBoundingClientRect&&t.parentNode&&(i=t.getBoundingClientRect()),!i)return{left:0,top:0};var s=Ii.documentElement,e=Ii.body,n=s.clientLeft||e.clientLeft||0,r=p.pageXOffset||e.scrollLeft,h=i.left+r-n,o=s.clientTop||e.clientTop||0,a=p.pageYOffset||e.scrollTop,u=i.top+a-o;return{left:x.round(h),top:x.round(u)}}function ys(t,i){var s={},e=gs(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=x.max(0,x.min(1,(h-a+r)/r)),s.x=x.max(0,x.min(1,(u-o)/n)),s}function bs(t){return zi(t)&&3===t.nodeType}function ws(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function ks(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()),Zi(t)||bs(t)?t:"string"==typeof t&&/\S/.test(t)?Ii.createTextNode(t):void 0})).filter((function(t){return t}))}(i).forEach((function(i){return t.appendChild(i)})),t}function _s(t,i){return ks(ws(t),i)}var xs,Cs=ts("querySelector"),Ss=ts("querySelectorAll"),js=p.navigator&&p.navigator.userAgent||"",Ts=/AppleWebKit\/([\d.]+)/i.exec(js),Ms=Ts?S(Ts.pop()):null,As=/iPad/i.test(js),Ps=/iPhone/i.test(js)&&!As,Es=/iPod/i.test(js),Ns=Ps||As||Es,Is=(xs=js.match(/OS (\d+)_/i))&&xs[1]?xs[1]:null,Bs=/Android/i.test(js),Fs=function(){var t=js.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!t)return null;var i=t[1]&&S(t[1]),s=t[2]&&S(t[2]);return i&&s?S(t[1]+"."+t[2]):i||null}(),Ds=Bs&&/webkit/i.test(js)&&Fs<2.3,$s=Bs&&Fs<5&&Ms<537,Rs=/Firefox/i.test(js),Os=/Edge/i.test(js),Vs=!Os&&/Chrome/i.test(js),Us=function(){var t=js.match(/Chrome\/(\d+)/);return t&&t[1]?S(t[1]):null}(),zs=/MSIE\s8\.0/.test(js),Ls=function(){var t=/MSIE\s(\d+)\.\d/.exec(js),i=t&&S(t[1]);return!i&&/Trident\/7.0/i.test(js)&&/rv:11.0/.test(js)&&(i=11),i}(),Hs=/Safari/i.test(js)&&!Vs&&!Bs&&!Os,qs=Hs||Ns,Ws=Ki()&&("ontouchstart"in p||p.DocumentTouch&&p.document instanceof p.DocumentTouch),Gs=Ki()&&"backgroundSize"in p.document.createElement("video").style,Xs=_.freeze({__proto__:null,IS_IPAD:As,IS_IPHONE:Ps,IS_IPOD:Es,IS_IOS:Ns,IOS_VERSION:Is,IS_ANDROID:Bs,ANDROID_VERSION:Fs,IS_OLD_ANDROID:Ds,IS_NATIVE_ANDROID:$s,IS_FIREFOX:Rs,IS_EDGE:Os,IS_CHROME:Vs,CHROME_VERSION:Us,IS_IE8:zs,IE_VERSION:Ls,IS_SAFARI:Hs,IS_ANY_SAFARI:qs,TOUCH_ENABLED:Ws,BACKGROUND_SIZE_SUPPORTED:Gs});function Js(t,i){var s=hs(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)),_.getOwnPropertyNames(s.handlers).length<=0&&(delete s.handlers,delete s.dispatcher,delete s.disabled),0===_.getOwnPropertyNames(s).length&&as(t)}function Qs(t,i,s,e){s.forEach((function(s){t(i,s,e)}))}function Ys(t){function i(){return!0}function s(){return!1}if(!t||!t.isPropagationStopped||!t.isImmediatePropagationStopped){var e=t||p.event;for(var n in t={},e)"layerX"!==n&&"layerY"!==n&&"keyLocation"!==n&&"webkitMovementX"!==n&&"webkitMovementY"!==n&&"path"!==n&&("returnValue"===n&&e.preventDefault||(t[n]=e[n]));if(t.target||(t.target=t.srcElement||Ii),t.relatedTarget||(t.relatedTarget=t.fromElement===t.target?t.toElement:t.fromElement),t.preventDefault=function(){e.preventDefault&&e.preventDefault(),t.returnValue=!1,e.returnValue=!1,t.defaultPrevented=!0},t.defaultPrevented=!1,t.stopPropagation=function(){e.stopPropagation&&e.stopPropagation(),t.cancelBubble=!0,e.cancelBubble=!0,t.isPropagationStopped=i},t.isPropagationStopped=s,t.stopImmediatePropagation=function(){e.stopImmediatePropagation&&e.stopImmediatePropagation(),t.isImmediatePropagationStopped=i,t.stopPropagation()},t.isImmediatePropagationStopped=s,null!==t.clientX&&void 0!==t.clientX){var r=Ii.documentElement,h=Ii.body;t.pageX=t.clientX+(r&&r.scrollLeft||h&&h.scrollLeft||0)-(r&&r.clientLeft||h&&h.clientLeft||0),t.pageY=t.clientY+(r&&r.scrollTop||h&&h.scrollTop||0)-(r&&r.clientTop||h&&h.clientTop||0)}t.which=t.charCode||t.keyCode,null!==t.button&&void 0!==t.button&&(t.button=1&t.button?0:4&t.button?1:2&t.button?2:0)}return t}var Ks=!1;!function(){try{var t=_.defineProperty({},"passive",{get:function(){Ks=!0}});p.addEventListener("test",null,t)}catch(t){}}();var Zs=["touchstart","touchmove"];function te(t,i,s){if(Array.isArray(i))return Qs(te,t,i,s);var e=hs(t);if(e.handlers||(e.handlers={}),e.handlers[i]||(e.handlers[i]=[]),s.guid||(s.guid=Di()),e.handlers[i].push(s),e.dispatcher||(e.disabled=!1,e.dispatcher=function(i,s){if(!e.disabled){i=Ys(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){qi.error(t)}}}),1===e.handlers[i].length)if(t.addEventListener){var n=!1;Ks&&Zs.indexOf(i)>-1&&(n={passive:!0}),t.addEventListener(i,e.dispatcher,n)}else t.attachEvent&&t.attachEvent("on"+i,e.dispatcher)}function ie(t,i,s){if(os(t)){var e=hs(t);if(e.handlers){if(Array.isArray(i))return Qs(ie,t,i,s);var n=function(i){e.handlers[i]=[],Js(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);Js(t,i)}else n(i)}else for(var o in e.handlers)n(o)}}}function se(t,i,s){var e=os(t)?hs(t):{},n=t.parentNode||t.ownerDocument;if("string"==typeof i&&(i={type:i,target:t}),i=Ys(i),e.dispatcher&&e.dispatcher.call(t,i,s),n&&!i.isPropagationStopped()&&!0===i.bubbles)se.call(null,n,i,s);else if(!n&&!i.defaultPrevented){var r=hs(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 ee(t,i,s){if(Array.isArray(i))return Qs(ee,t,i,s);var e=function e(){ie(t,i,e),s.apply(this,arguments)};e.guid=s.guid=s.guid||Di(),te(t,i,e)}var ne,re=!1,he=function(){if(Ki()){var t=Ii.getElementsByTagName("video"),i=Ii.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){oe(1);break}void 0===u.player&&null!==u.getAttribute("data-setup")&&ne(u)}else re||oe(1)}};function oe(t,i){i&&(ne=i),p.setTimeout(he,t)}Ki()&&"complete"===Ii.readyState?re=!0:ee(p,"load",(function(){re=!0}));var ae=function(t){var i=Ii.createElement("style");return i.className=t,i},ue=function(t,i){t.styleSheet?t.styleSheet.cssText=i:t.textContent=i},ce=function(t,i,s){i.guid||(i.guid=Di());var e=function(){return i.apply(t,arguments)};return e.guid=s?s+"_"+i.guid:i.guid,e};function le(t){return"string"!=typeof t?t:t.charAt(0).toUpperCase()+t.slice(1)}function de(){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&&Vi(i,(function(i,s){Li(i)?(Li(t[s])||(t[s]={}),t[s]=de(t[s],i)):t[s]=i}))})),t}var fe=function(){function t(t,i,s){if(!t&&this.play?this.t=t=this:this.t=t,this.h=de({},this.h),i=this.h=de(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"+Di()}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 i=t.prototype;return i.dispose=function(){if(this.trigger({type:"dispose",bubbles:!1}),this.m)for(var t=this.m.length-1;t>=0;t--)this.m[t].dispose&&this.m[t].dispose();this.m=null,this.k=null,this.C=null,this.off(),this.v.parentNode&&this.v.parentNode.removeChild(this.v),as(this.v),this.v=null},i.player=function(){return this.t},i.options=function(t){return qi.warn("this.options() has been deprecated and will be moved to the constructor in 6.0"),t?(this.h=de(this.h,t),this.h):this.h},i.el=function(){return this.v},i.createEl=function(t,i,s){return is(t,i,s)},i.localize=function(t){var i=this.t.language&&this.t.language(),s=this.t.languages&&this.t.languages();if(!i||!s)return t;var e=s[i];if(e&&e[t])return e[t];var n=s[i.split("-")[0]];return n&&n[t]?n[t]:t},i.contentEl=function(){return this.S||this.v},i.id=function(){return this.o},i.name=function(){return this.l},i.children=function(){return this.m},i.getChildById=function(t){return this.k[t]},i.getChild=function(t){if(t)return t=le(t),this.C[t]},i.addChild=function(i,s,e){var n,r;if(void 0===s&&(s={}),void 0===e&&(e=this.m.length),"string"==typeof i){r=le(i),s||(s={}),!0===s&&(qi.warn("Initializing a child component with `true` is deprecated.Children should be defined in an array when possible, but if necessary use an object instead of `true`."),s={});var h=s.componentClass||r;s.name=r;var o=t.getComponent(h);if(!o)throw new b("Component "+h+" does not exist");if("function"!=typeof o)return null;n=new o(this.t||this,s)}else n=i;if(this.m.splice(e,0,n),"function"==typeof n.id&&(this.k[n.id()]=n),(r=r||n.name&&le(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},i.removeChild=function(t){if("string"==typeof t&&(t=this.getChild(t)),t&&this.m){for(var i=!1,s=this.m.length-1;s>=0;s--)if(this.m[s]===t){i=!0,this.m.splice(s,1);break}if(i){this.k[t.id()]=null,this.C[t.name()]=null;var e=t.el();e&&e.parentNode===this.contentEl()&&this.contentEl().removeChild(t.el())}}},i.initChildren=function(){var i=this,s=this.h.children;if(s){var e,n=this.h,r=t.getComponent("Tech");(e=Array.isArray(s)?s:_.keys(s)).concat(_.keys(this.h).filter((function(t){return!e.some((function(i){return"string"==typeof i?t===i:t===i.name}))}))).map((function(t){var e,n;return"string"==typeof t?n=s[e=t]||i.h[e]||{}:(e=t.name,n=t),{name:e,opts:n}})).filter((function(i){var s=t.getComponent(i.opts.componentClass||le(i.name));return s&&!r.isTech(s)})).forEach((function(t){var s=t.name,e=t.opts;if(void 0!==n[s]&&(e=n[s]),!1!==e){!0===e&&(e={}),e.playerOptions=i.h.playerOptions;var r=i.addChild(s,e);r&&(i[s]=r)}}))}},i.buildCSSClass=function(){return""},i.on=function(t,i,s){var e=this;if("string"==typeof t||Array.isArray(t))te(this.v,t,ce(this,i));else{var n=t,r=i,h=ce(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?(te(n,r,h),te(n,"dispose",a)):"function"==typeof t.on&&(n.on(r,h),n.on("dispose",a))}return this},i.off=function(t,i,s){if(!t||"string"==typeof t||Array.isArray(t))ie(this.v,t,i);else{var e=t,n=i,r=ce(this,s);this.off("dispose",r),t.nodeName?(ie(e,n,r),ie(e,"dispose",r)):(e.off(n,r),e.off("dispose",r))}return this},i.one=function(t,i,s){var e=arguments,n=this;if("string"==typeof t||Array.isArray(t))ee(this.v,t,ce(this,i));else{var r=t,h=i,o=ce(this,s),a=function t(){n.off(r,h,t),o.apply(null,e)};a.guid=o.guid,this.on(r,h,a)}return this},i.trigger=function(t,i){return se(this.v,t,i),this},i.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},i.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)},i.$=function(t,i){return Cs(t,i||this.contentEl())},i.$$=function(t,i){return Ss(t,i||this.contentEl())},i.hasClass=function(t){return us(this.v,t)},i.addClass=function(t){return cs(this.v,t),this},i.removeClass=function(t){return ls(this.v,t),this},i.toggleClass=function(t,i){return ds(this.v,t,i),this},i.show=function(){return this.removeClass("vjs-hidden"),this},i.hide=function(){return this.addClass("vjs-hidden"),this},i.lockShowing=function(){return this.addClass("vjs-lock-showing"),this},i.unlockShowing=function(){return this.removeClass("vjs-lock-showing"),this},i.getAttribute=function(t){return function(t,i){return t.getAttribute(i)}(this.v,t)},i.setAttribute=function(t,i){return ps(this.v,t,i),this},i.removeAttribute=function(t){return ms(this.v,t),this},i.width=function(t,i){return this.dimension("width",t,i)},i.height=function(t,i){return this.dimension("height",t,i)},i.dimensions=function(t,i){return this.width(t,!0).height(i)},i.dimension=function(t,i,s){if(void 0!==i)return null!==i&&i==i||(i=0),-1!==(""+i).indexOf("%")||-1!==(""+i).indexOf("px")?this.v.style[t]=i:this.v.style[t]="auto"===i?"":i+"px",s||this.trigger("resize"),this;if(!this.v)return 0;var e=this.v.style[t],n=e.indexOf("px");return C(-1!==n?e.slice(0,n):this.v["offset"+le(t)],10)},i.currentDimension=function(t){var i=0;if("width"!==t&&"height"!==t)throw new b("currentDimension only accepts width or height value");if("function"==typeof p.getComputedStyle){var s=p.getComputedStyle(this.v);i=s.getPropertyValue(t)||s[t]}if(0===(i=S(i))){var e="offset"+le(t);i=this.v[e]}return i},i.currentDimensions=function(){return{width:this.currentDimension("width"),height:this.currentDimension("height")}},i.currentWidth=function(){return this.currentDimension("width")},i.currentHeight=function(){return this.currentDimension("height")},i.focus=function(){this.v.focus()},i.blur=function(){this.v.blur()},i.emitTapEvents=function(){var t,i=0,s=null;this.on("touchstart",(function(e){1===e.touches.length&&(s={pageX:e.touches[0].pageX,pageY:e.touches[0].pageY},i=(new Date).getTime(),t=!0)})),this.on("touchmove",(function(i){if(i.touches.length>1)t=!1;else if(s){var e=i.touches[0].pageX-s.pageX,n=i.touches[0].pageY-s.pageY;x.sqrt(e*e+n*n)>10&&(t=!1)}}));var e=function(){t=!1};this.on("touchleave",e),this.on("touchcancel",e),this.on("touchend",(function(e){(s=null,!0===t)&&((new Date).getTime()-i<200&&(e.preventDefault(),this.trigger("tap")))}))},i.enableTouchActivity=function(){if(this.player()&&this.player().reportUserActivity){var t,i=ce(this.player(),this.player().reportUserActivity);this.on("touchstart",(function(){i(),this.clearInterval(t),t=this.setInterval(i,250)}));var s=function(s){i(),this.clearInterval(t)};this.on("touchmove",i),this.on("touchend",s),this.on("touchcancel",s)}},i.setTimeout=function(t,i){t=ce(this,t);var s=p.setTimeout(t,i),e=function(){this.clearTimeout(s)};return e.guid="vjs-timeout-"+s,this.on("dispose",e),s},i.clearTimeout=function(t){p.clearTimeout(t);var i=function(){};return i.guid="vjs-timeout-"+t,this.off("dispose",i),t},i.setInterval=function(t,i){t=ce(this,t);var s=p.setInterval(t,i),e=function(){this.clearInterval(s)};return e.guid="vjs-interval-"+s,this.on("dispose",e),s},i.clearInterval=function(t){p.clearInterval(t);var i=function(){};return i.guid="vjs-interval-"+t,this.off("dispose",i),t},t.registerComponent=function(i,s){if(i){if(i=le(i),t.M||(t.M={}),"Player"===i&&t.M[i]){var e=t.M[i];if(e.players&&_.keys(e.players).length>0&&_.keys(e.players).map((function(t){return e.players[t]})).every(Boolean))throw new b("Can not register Player component after player has been created")}return t.M[i]=s,s}},t.getComponent=function(i){if(i)return i=le(i),t.M&&t.M[i]?t.M[i]:p&&p.videojs&&p.videojs[i]?(qi.warn("The "+i+" component was added to the videojs object when it should be registered using videojs.registerComponent(name, component)"),p.videojs[i]):void 0},t.extend=function(i){i=i||{},qi.warn("Component.extend({}) has been deprecated, use videojs.extend(Component, {}) instead");var s=i.init||i.init||this.prototype.init||this.prototype.init||function(){},e=function(){s.apply(this,arguments)};for(var n in(e.prototype=_.create(this.prototype)).constructor=e,e.extend=t.extend,i)i.hasOwnProperty(n)&&(e.prototype[n]=i[n]);return e},t}();fe.registerComponent("Component",fe);var ve=function(){};function pe(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function me(t,i){return(me=_.setPrototypeOf?_.setPrototypeOf.bind():function(t,i){return t.__proto__=i,t})(t,i)}function ge(t,i){t.prototype=_.create(i.prototype),t.prototype.constructor=t,me(t,i)}function ye(t,i,s,e){return void 0===e&&(qi.warn("DEPRECATED: Function '"+t+"' on 'TimeRanges' called without an index argument."),e=0),function(t,i,s){if(i<0||i>s)throw new b("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 be(t){return void 0===t||0===t.length?{length:0,start:function(){throw new b("This TimeRanges object is empty")},end:function(){throw new b("This TimeRanges object is empty")}}:{length:t.length,start:ye.bind(null,"start",0,t),end:ye.bind(null,"end",1,t)}}function we(t,i){return Array.isArray(t)?be(t):void 0===t||void 0===i?be():be([[t,i]])}function ke(t,i){var s,e,n=0;if(!i)return 0;t&&t.length||(t=we(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}ve.prototype.A={},ve.prototype.on=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},te(this,t,i),this.addEventListener=s},ve.prototype.addEventListener=ve.prototype.on,ve.prototype.off=function(t,i){ie(this,t,i)},ve.prototype.removeEventListener=ve.prototype.off,ve.prototype.one=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},ee(this,t,i),this.addEventListener=s},ve.prototype.trigger=function(t){var i=t.type||t;"string"==typeof t&&(t={type:i}),t=Ys(t),this.A[i]&&this["on"+i]&&this["on"+i](t),se(this,t)},ve.prototype.dispatchEvent=ve.prototype.trigger;var _e,xe,Ce,Se,je={prefixed:!0},Te=[["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"]],Me=Te[0];for(xe=0;xe<Te.length;xe++)if(Te[xe][1]in Ii){_e=Te[xe];break}if(_e){for(Ce=0;Ce<_e.length;Ce++)je[Me[Ce]]=_e[Ce];je.prefixed=_e[0]!==Me[0]}function Ae(t){if(t instanceof Ae)return t;"number"==typeof t?this.code=t:"string"==typeof t?this.message=t:zi(t)&&("number"==typeof t.code&&(this.code=t.code),Ui(this,t)),this.message||(this.message=Ae.defaultMessages[this.code]||"")}for(Ae.prototype.code=0,Ae.prototype.message="",Ae.prototype.status=null,Ae.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],Ae.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."},Se=0;Se<Ae.errorTypes.length;Se++)Ae[Ae.errorTypes[Se]]=Se,Ae.prototype[Ae.errorTypes[Se]]=Se;var Pe=function(t,i){var s,e=null;try{s=JSON.parse(t,i)}catch(t){e=t}return[e,s]};var Ee=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}}))})},Ne=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=Ee(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(Ee))},Ie=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()},Be="vjs-modal-dialog",Fe=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).P=e.N=e.I=!1,e.closeable(!e.h.uncloseable),e.content(e.h.content),e.S=is("div",{className:Be+"-content"},{role:"document"}),e.B=is("p",{className:Be+"-description vjs-offscreen",id:e.el().getAttribute("aria-describedby")}),ss(e.B,e.description()),e.v.appendChild(e.B),e.v.appendChild(e.S),e.on(i,"languagechange",e.handleLanguagechange),e}ge(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 Be+" 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.I)&&this.fill(),this.D=!t.paused(),this.h.pauseOnOpen&&this.D&&t.pause(),this.closeable()&&this.on(this.v.ownerDocument,"keydown",ce(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",ce(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.I=!0,s.removeChild(i),this.empty(),_s(i,t),this.trigger("modalfill"),e?s.insertBefore(i,e):s.appendChild(i),this},s.empty=function(){return this.trigger("beforemodalempty"),ws(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()),ss(this.B,this.description()),this.opened()?this.fill():(this.N||this.I)&&(this.N=!1,this.I=!1,this.empty())},i}(fe);Fe.prototype.h={pauseOnOpen:!0,temporary:!0},fe.registerComponent("ModalDialog",Fe);var De=function(){function t(i){var s=this;if(zs)for(var e in s=Ii.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);if(t.prototype.V.call(s,i),_.defineProperty(s,"length",{get:function(){return this.U}}),zs)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||_.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}(),$e={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},Re={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},Oe={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},Ve={disabled:"disabled",hidden:"hidden",showing:"showing"},Ue=function(t){function i(s){var e;void 0===s&&(s={});var n=pe(e=t.call(this)||this);if(zs)for(var r in n=Ii.createElement("custom"),i.prototype)"constructor"!==r&&(n[r]=i.prototype[r]);var h={id:s.id||["vjs_track",Di()].join("_"),kind:s.kind||"",label:s.label||"",language:s.language||""},o=function(t){_.defineProperty(n,t,{get:function(){return h[t]},set:function(){}})};for(var a in h)o(a);return n||pe(e)}return ge(i,t),i}(ve),ze=function(t){var i=["protocol","hostname","port","pathname","search","hash","host"],s=Ii.createElement("a");s.href=t;var e,n=""===s.host&&"file:"!==s.protocol;n&&((e=Ii.createElement("div")).innerHTML='<a href="'+t+'"></a>',s=e.firstChild,e.setAttribute("style","display:none; position:absolute;"),Ii.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&&Ii.body.removeChild(e),r},Le=function(t){var i=p.location,s=ze(t);return(":"===s.protocol?i.protocol:s.protocol)+s.host!==i.protocol+i.host},He={exports:{}};void 0!==s?He.exports=s:void 0!==Wi?He.exports=Wi:"undefined"!=typeof self?He.exports=self:He.exports={};var qe=function(t){var i=We.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)},We=_.prototype.toString;var Ge,Xe,Je,Qe,Ye,Ke,Ze,tn,sn,en,nn,rn,hn=Array.prototype.slice,on=_.prototype.toString,an=function(t){var i=this;if("function"!=typeof i||"[object Function]"!==on.call(i))throw new w("Function.prototype.bind called on incompatible "+i);for(var s,e=hn.call(arguments,1),n=x.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(hn.call(arguments)));return _(n)===n?n:this}return i.apply(t,e.concat(hn.call(arguments)))})),i.prototype){var o=function(){};o.prototype=i.prototype,s.prototype=new o,o.prototype=null}return s},un=Function.prototype.bind||an,cn=_.prototype.toString,ln=function(t){var i=cn.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]"===cn.call(t.callee)),s};_.keys||(Xe=_.prototype.hasOwnProperty,Je=_.prototype.toString,Qe=ln,Ye=_.prototype.propertyIsEnumerable,Ke=!Ye.call({toString:null},"toString"),Ze=Ye.call((function(){}),"prototype"),tn=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],sn=function(t){var i=t.constructor;return i&&i.prototype===t},en={$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},nn=function(){if(void 0===s)return!1;for(var t in s)try{if(!en["$"+t]&&Xe.call(s,t)&&null!==s[t]&&"object"==typeof s[t])try{sn(s[t])}catch(t){return!0}}catch(t){return!0}return!1}(),rn=function(t){if(void 0===s||!nn)return sn(t);try{return sn(t)}catch(t){return!1}},Ge=function(t){var i=null!==t&&"object"==typeof t,s="[object Function]"===Je.call(t),e=Qe(t),n=i&&"[object String]"===Je.call(t),r=[];if(!i&&!s&&!e)throw new w("Object.keys called on a non-object");var h=Ze&&s;if(n&&t.length>0&&!Xe.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||!Xe.call(t,u)||r.push(String(u));if(Ke)for(var c=rn(t),l=0;l<tn.length;++l)c&&"constructor"===tn[l]||!Xe.call(t,tn[l])||r.push(tn[l]);return r});var dn=Ge,fn=Array.prototype.slice,vn=ln,pn=_.keys,mn=pn?function(t){return pn(t)}:dn,gn=_.keys;mn.shim=function(){if(_.keys){var t=function(){var t=_.keys(arguments);return t&&t.length===arguments.length}(1,2);t||(_.keys=function(t){return vn(t)?gn(fn.call(t)):gn(t)})}else _.keys=mn;return _.keys||mn};var yn=mn,bn="function"==typeof At&&"symbol"==typeof At("foo"),wn=_.prototype.toString,kn=Array.prototype.concat,_n=_.defineProperty,xn=_n&&function(){var t={};try{for(var i in _n(t,"x",{enumerable:!1,value:t}),t)return!1;return t.x===t}catch(t){return!1}}(),Cn=function(t,i,s,e){(!(i in t)||function(t){return"function"==typeof t&&"[object Function]"===wn.call(t)}(e)&&e())&&(xn?_n(t,i,{configurable:!0,enumerable:!1,value:s,writable:!0}):t[i]=s)},Sn=function(t,i){var s=arguments.length>2?arguments[2]:{},e=yn(i);bn&&(e=kn.call(e,_.getOwnPropertySymbols(i)));for(var n=0;n<e.length;n+=1)Cn(t,e[n],i[e[n]],s[e[n]])};Sn.supportsDescriptors=!!xn;var jn,Tn=Sn,Mn=_.getOwnPropertyDescriptor?function(){return _.getOwnPropertyDescriptor(arguments,"callee").get}():function(){throw new w},An="function"==typeof At&&"symbol"==typeof Nt,Pn=_.getPrototypeOf||function(t){return t.__proto__},En=void 0===T?jn:Pn(T),Nn={"$ %Array%":Array,"$ %ArrayBuffer%":"undefined"==typeof ArrayBuffer?jn:ArrayBuffer,"$ %ArrayBufferPrototype%":"undefined"==typeof ArrayBuffer?jn:ArrayBuffer.prototype,"$ %ArrayIteratorPrototype%":An?Pn([][Nt]()):jn,"$ %ArrayPrototype%":Array.prototype,"$ %ArrayProto_entries%":Array.prototype.entries,"$ %ArrayProto_forEach%":Array.prototype.forEach,"$ %ArrayProto_keys%":Array.prototype.keys,"$ %ArrayProto_values%":Array.prototype.values,"$ %AsyncFromSyncIteratorPrototype%":jn,"$ %AsyncFunction%":undefined,"$ %AsyncFunctionPrototype%":jn,"$ %AsyncGenerator%":jn,"$ %AsyncGeneratorFunction%":undefined,"$ %AsyncGeneratorPrototype%":jn,"$ %AsyncIteratorPrototype%":jn,"$ %Atomics%":"undefined"==typeof Atomics?jn:Atomics,"$ %Boolean%":Boolean,"$ %BooleanPrototype%":Boolean.prototype,"$ %DataView%":"undefined"==typeof DataView?jn:DataView,"$ %DataViewPrototype%":"undefined"==typeof DataView?jn:DataView.prototype,"$ %Date%":Date,"$ %DatePrototype%":Date.prototype,"$ %decodeURI%":decodeURI,"$ %decodeURIComponent%":decodeURIComponent,"$ %encodeURI%":encodeURI,"$ %encodeURIComponent%":encodeURIComponent,"$ %Error%":b,"$ %ErrorPrototype%":b.prototype,"$ %eval%":eval,"$ %EvalError%":EvalError,"$ %EvalErrorPrototype%":EvalError.prototype,"$ %Float32Array%":"undefined"==typeof Float32Array?jn:Float32Array,"$ %Float32ArrayPrototype%":"undefined"==typeof Float32Array?jn:Float32Array.prototype,"$ %Float64Array%":"undefined"==typeof Float64Array?jn:Float64Array,"$ %Float64ArrayPrototype%":"undefined"==typeof Float64Array?jn:Float64Array.prototype,"$ %Function%":Function,"$ %FunctionPrototype%":Function.prototype,"$ %Generator%":jn,"$ %GeneratorFunction%":undefined,"$ %GeneratorPrototype%":jn,"$ %Int8Array%":"undefined"==typeof Int8Array?jn:Int8Array,"$ %Int8ArrayPrototype%":"undefined"==typeof Int8Array?jn:Int8Array.prototype,"$ %Int16Array%":"undefined"==typeof Int16Array?jn:Int16Array,"$ %Int16ArrayPrototype%":"undefined"==typeof Int16Array?jn:Int8Array.prototype,"$ %Int32Array%":"undefined"==typeof Int32Array?jn:Int32Array,"$ %Int32ArrayPrototype%":"undefined"==typeof Int32Array?jn:Int32Array.prototype,"$ %isFinite%":isFinite,"$ %isNaN%":j,"$ %IteratorPrototype%":An?Pn(Pn([][Nt]())):jn,"$ %JSON%":JSON,"$ %JSONParse%":JSON.parse,"$ %Map%":"undefined"==typeof Map?jn:Map,"$ %MapIteratorPrototype%":"undefined"!=typeof Map&&An?Pn((new Map)[Nt]()):jn,"$ %MapPrototype%":"undefined"==typeof Map?jn:Map.prototype,"$ %Math%":x,"$ %Number%":Number,"$ %NumberPrototype%":Number.prototype,"$ %Object%":_,"$ %ObjectPrototype%":_.prototype,"$ %ObjProto_toString%":_.prototype.toString,"$ %ObjProto_valueOf%":_.prototype.valueOf,"$ %parseFloat%":S,"$ %parseInt%":C,"$ %Promise%":"undefined"==typeof Promise?jn:Promise,"$ %PromisePrototype%":"undefined"==typeof Promise?jn:Promise.prototype,"$ %PromiseProto_then%":"undefined"==typeof Promise?jn:Promise.prototype.then,"$ %Promise_all%":"undefined"==typeof Promise?jn:Promise.all,"$ %Promise_reject%":"undefined"==typeof Promise?jn:Promise.reject,"$ %Promise_resolve%":"undefined"==typeof Promise?jn:Promise.resolve,"$ %Proxy%":"undefined"==typeof Proxy?jn:Proxy,"$ %RangeError%":RangeError,"$ %RangeErrorPrototype%":RangeError.prototype,"$ %ReferenceError%":ReferenceError,"$ %ReferenceErrorPrototype%":ReferenceError.prototype,"$ %Reflect%":"undefined"==typeof Reflect?jn:Reflect,"$ %RegExp%":RegExp,"$ %RegExpPrototype%":RegExp.prototype,"$ %Set%":"undefined"==typeof Set?jn:Set,"$ %SetIteratorPrototype%":"undefined"!=typeof Set&&An?Pn((new Set)[Nt]()):jn,"$ %SetPrototype%":"undefined"==typeof Set?jn:Set.prototype,"$ %SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?jn:SharedArrayBuffer,"$ %SharedArrayBufferPrototype%":"undefined"==typeof SharedArrayBuffer?jn:SharedArrayBuffer.prototype,"$ %String%":String,"$ %StringIteratorPrototype%":An?Pn(""[Nt]()):jn,"$ %StringPrototype%":String.prototype,"$ %Symbol%":An?At:jn,"$ %SymbolPrototype%":An?At.prototype:jn,"$ %SyntaxError%":k,"$ %SyntaxErrorPrototype%":k.prototype,"$ %ThrowTypeError%":Mn,"$ %TypedArray%":En,"$ %TypedArrayPrototype%":En?En.prototype:jn,"$ %TypeError%":w,"$ %TypeErrorPrototype%":w.prototype,"$ %Uint8Array%":void 0===T?jn:T,"$ %Uint8ArrayPrototype%":void 0===T?jn:T.prototype,"$ %Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?jn:Uint8ClampedArray,"$ %Uint8ClampedArrayPrototype%":"undefined"==typeof Uint8ClampedArray?jn:Uint8ClampedArray.prototype,"$ %Uint16Array%":"undefined"==typeof Uint16Array?jn:Uint16Array,"$ %Uint16ArrayPrototype%":"undefined"==typeof Uint16Array?jn:Uint16Array.prototype,"$ %Uint32Array%":"undefined"==typeof Uint32Array?jn:Uint32Array,"$ %Uint32ArrayPrototype%":"undefined"==typeof Uint32Array?jn:Uint32Array.prototype,"$ %URIError%":URIError,"$ %URIErrorPrototype%":URIError.prototype,"$ %WeakMap%":"undefined"==typeof WeakMap?jn:WeakMap,"$ %WeakMapPrototype%":"undefined"==typeof WeakMap?jn:WeakMap.prototype,"$ %WeakSet%":"undefined"==typeof WeakSet?jn:WeakSet,"$ %WeakSetPrototype%":"undefined"==typeof WeakSet?jn:WeakSet.prototype},In=function(t,i){if(arguments.length>1&&"boolean"!=typeof i)throw new w('"allowMissing" argument must be a boolean');var s="$ "+t;if(!(s in Nn))throw new k("intrinsic "+t+" does not exist!");if(void 0===Nn[s]&&!i)throw new w("intrinsic "+t+" exists, but is not available. Please file an issue!");return Nn[s]},Bn=un.call(Function.call,_.prototype.hasOwnProperty),Fn=In,Dn=Fn("%TypeError%"),$n=Fn("%SyntaxError%"),Rn=Bn,On={"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(Rn(i,e)&&!s[e])return!1;var n=Rn(i,"[[Value]]"),r=Rn(i,"[[Get]]")||Rn(i,"[[Set]]");if(n&&r)throw new Dn("Property Descriptors may not be both accessor and data descriptors");return!0}},Vn=Number.isNaN||function(t){return t!=t},Un=Number.isNaN||function(t){return t!=t},zn=Number.isFinite||function(t){return"number"==typeof t&&!Un(t)&&t!==1/0&&t!==-1/0},Ln=Function.prototype.toString,Hn=/^\s*class\b/,qn=function(t){try{var i=Ln.call(t);return Hn.test(i)}catch(t){return!1}},Wn=_.prototype.toString,Gn="function"==typeof At&&"symbol"==typeof At.toStringTag,Xn=function(t){if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if("function"==typeof t&&!t.prototype)return!0;if(Gn)return function(t){try{return!qn(t)&&(Ln.call(t),!0)}catch(t){return!1}}(t);if(qn(t))return!1;var i=Wn.call(t);return"[object Function]"===i||"[object GeneratorFunction]"===i},Jn=_.prototype.toString,Qn=function(t){return null===t||"function"!=typeof t&&"object"!=typeof t},Yn=Xn,Kn=function(t){var i;if((i=arguments.length>1?arguments[1]:"[object Date]"===Jn.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(Yn(t[n[e]])&&(s=t[n[e]](),Qn(s)))return s;throw new w("No default value")}throw new w("invalid [[DefaultValue]] hint supplied")},Zn=In,tr=Zn("%Object%"),ir=Zn("%TypeError%"),sr=Zn("%String%"),er=function(t,i,s,e){var n=On[i];if("function"!=typeof n)throw new $n("unknown record type: "+i);if(!n(t,e))throw new Dn(s+" must be a "+i);console.log(n(t,e),e)},nr=Vn,rr=zn,hr=function(t){return t>=0?1:-1},or=function(t,i){var s=t%i;return x.floor(s>=0?s:s+i)},ar=Bn,ur={ToPrimitive:function(t){return Qn(t)?t:arguments.length>1?Kn(t,arguments[1]):Kn(t)},ToBoolean:function(t){return!!t},ToNumber:function(t){return+t},ToInteger:function(t){var i=this.ToNumber(t);return nr(i)?0:0!==i&&rr(i)?hr(i)*x.floor(x.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(nr(i)||0===i||!rr(i))return 0;var s=hr(i)*x.floor(x.abs(i));return or(s,65536)},ToString:function(t){return sr(t)},ToObject:function(t){return this.CheckObjectCoercible(t),tr(t)},CheckObjectCoercible:function(t,i){if(null==t)throw new ir(i||"Cannot call method on "+t);return t},IsCallable:Xn,SameValue:function(t,i){return t===i?0!==t||1/t==1/i:nr(t)&&nr(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(ar(t,s)&&!i[s])return!1;var e=ar(t,"[[Value]]"),n=ar(t,"[[Get]]")||ar(t,"[[Set]]");if(e&&n)throw new ir("Property Descriptors may not be both accessor and data descriptors");return!0},IsAccessorDescriptor:function(t){return void 0!==t&&(er(this,"Property Descriptor","Desc",t),!(!ar(t,"[[Get]]")&&!ar(t,"[[Set]]")))},IsDataDescriptor:function(t){return void 0!==t&&(er(this,"Property Descriptor","Desc",t),!(!ar(t,"[[Value]]")&&!ar(t,"[[Writable]]")))},IsGenericDescriptor:function(t){return void 0!==t&&(er(this,"Property Descriptor","Desc",t),!this.IsAccessorDescriptor(t)&&!this.IsDataDescriptor(t))},FromPropertyDescriptor:function(t){if(void 0===t)return t;if(er(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 ir("FromPropertyDescriptor must be called with a fully populated Property Descriptor")},ToPropertyDescriptor:function(t){if("Object"!==this.Type(t))throw new ir("ToPropertyDescriptor requires an object");var i={};if(ar(t,"enumerable")&&(i["[[Enumerable]]"]=this.ToBoolean(t.enumerable)),ar(t,"configurable")&&(i["[[Configurable]]"]=this.ToBoolean(t.configurable)),ar(t,"value")&&(i["[[Value]]"]=t.value),ar(t,"writable")&&(i["[[Writable]]"]=this.ToBoolean(t.writable)),ar(t,"get")){var s=t.get;if(void 0!==s&&!this.IsCallable(s))throw new w("getter must be a function");i["[[Get]]"]=s}if(ar(t,"set")){var e=t.set;if(void 0!==e&&!this.IsCallable(e))throw new ir("setter must be a function");i["[[Set]]"]=e}if((ar(i,"[[Get]]")||ar(i,"[[Set]]"))&&(ar(i,"[[Value]]")||ar(i,"[[Writable]]")))throw new ir("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return i}},cr=un.call(Function.call,String.prototype.replace),lr=/^[\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]+/,dr=/[\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]+$/,fr=function(){var t=ur.ToString(ur.CheckObjectCoercible(this));return cr(cr(t,lr,""),dr,"")},vr=fr,pr=function(){return String.prototype.trim&&"\u200b"==="\u200b".trim()?String.prototype.trim:vr},mr=Tn,gr=pr,yr=Tn,br=fr,wr=pr,kr=function(){var t=gr();return mr(String.prototype,{trim:t},{trim:function(){return String.prototype.trim!==t}}),t},_r=un.call(Function.call,wr());yr(_r,{getPolyfill:wr,implementation:br,shim:kr});var xr=_r,Cr=Xn,Sr=_.prototype.toString,jr=_.prototype.hasOwnProperty,Tr=xr,Mr=function(t,i,s){if(!Cr(i))throw new w("iterator must be a function");var e;arguments.length>=3&&(e=s),"[object Array]"===Sr.call(t)?function(t,i,s){for(var e=0,n=t.length;e<n;e++)jr.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)jr.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))}(t,i,e)},Ar=function(){for(var t={},i=0;i<arguments.length;i++){var s=arguments[i];for(var e in s)Pr.call(s,e)&&(t[e]=s[e])}return t},Pr=_.prototype.hasOwnProperty;var Er=He.exports,Nr=qe,Ir=function(t){if(!t)return{};var i={};return Mr(Tr(t).split("\n"),(function(t){var s=t.indexOf(":"),e=Tr(t.slice(0,s)).toLowerCase(),n=Tr(t.slice(s+1));void 0===i[e]?i[e]=n:!function(t){return"[object Array]"===_.prototype.toString.call(t)}(i[e])?i[e]=[i[e],n]:i[e].push(n)})),i},Br=Ar,Fr=$r;function Dr(t,i,s){var e=t;return Nr(i)?(s=i,"string"==typeof t&&(e={uri:t})):e=Br(i,{uri:t}),e.callback=s,e}function $r(t,i,s){return Rr(i=Dr(t,i,s))}function Rr(t){if(void 0===t.callback)throw new b("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),y)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 b||(t=new b(""+(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=Ir(l.getAllResponseHeaders()))):h=new b("Internal XMLHttpRequest Error"),s(h,r,r.body)}}var o,a,l=t.xhr||null;l||(l=t.cors||t.useXDR?new $r.XDomainRequest:new $r.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||{},g=!!t.sync,y=!1;if("json"in t&&(y=!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,!g,t.username,t.password),g||(l.withCredentials=!!t.withCredentials),!g&&t.timeout>0&&(d=u((function(){a=!0,l.abort("timeout");var t=new b("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 b("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}$r.XMLHttpRequest=Er.XMLHttpRequest||function(){},$r.XDomainRequest="withCredentials"in new $r.XMLHttpRequest?$r.XMLHttpRequest:Er.XDomainRequest,function(t,i){for(var s=0;s<t.length;s++)i(t[s])}(["get","put","post","patch","head","delete"],(function(t){$r["delete"===t?"del":t]=function(i,s,e){return(s=Dr(i,s,e)).method=t.toUpperCase(),Rr(s)}}));var Or=function(t,i){var s=new p.WebVTT.Parser(p,p.vttjs,p.WebVTT.StringDecoder()),e=[];s.oncue=function(t){i.addCue(t)},s.onparsingerror=function(t){e.push(t)},s.onflush=function(){i.trigger({type:"loadeddata",target:i})},s.parse(t),e.length>0&&(p.console&&p.console.groupCollapsed&&p.console.groupCollapsed("Text Track parsing errors for "+i.src),e.forEach((function(t){return qi.error(t)})),p.console&&p.console.groupEnd&&p.console.groupEnd()),s.flush()},Vr=function(t){function i(s){var e;if(void 0===s&&(s={}),!s.tech)throw new b("A tech was not provided.");var n=de(s,{kind:Oe[s.kind]||"subtitles",language:s.language||s.srclang||""}),r=Ve[n.mode]||"disabled",h=n.default;"metadata"!==n.kind&&"chapters"!==n.kind||(r="hidden");var o=e=t.call(this,n)||this;if(o.H=n.tech,zs)for(var a in i.prototype)"constructor"!==a&&(o[a]=i.prototype[a]);o.L=[],o.q=[];var u=new De(o.L),c=new De(o.q),l=!1,d=ce(o,(function(){this.activeCues,l&&(this.trigger("cuechange"),l=!1)}));return"disabled"!==r&&o.H.ready((function(){o.H.on("timeupdate",d)}),!0),_.defineProperty(o,"default",{get:function(){return h},set:function(){}}),_.defineProperty(o,"mode",{get:function(){return r},set:function(t){var i=this;Ve[t]&&("showing"===(r=t)&&this.H.ready((function(){i.H.on("timeupdate",d)}),!0),this.trigger("modechange"))}}),_.defineProperty(o,"cues",{get:function(){return this.W?u:null},set:function(){}}),_.defineProperty(o,"activeCues",{get:function(){if(!this.W)return null;if(0===this.cues.length)return c;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(l=!1,i.length!==this.q.length)l=!0;else for(var r=0;r<i.length;r++)-1===this.q.indexOf(i[r])&&(l=!0);return this.q=i,c.V(this.q),c},set:function(){}}),n.src?(o.src=n.src,function(t,i){var s={uri:t},e=Le(t);e&&(s.cors=e),Fr(s,ce(this,(function(t,s,e){if(t)return qi.error(t,s);if(i.W=!0,"function"!=typeof p.WebVTT){if(i.H){var n=function(){return Or(e,i)};i.H.on("vttjsloaded",n),i.H.on("vttjserror",(function(){qi.error("vttjs failed to load, stopping trying to process "+i.src),i.H.off("vttjsloaded",n)}))}}else Or(e,i)})))}(n.src,o)):o.W=!0,o||pe(e)}ge(i,t);var s=i.prototype;return s.addCue=function(t){var i=t;if(p.vttjs&&!(t instanceof p.vttjs.VTTCue)){for(var s in i=new p.vttjs.VTTCue(t.startTime,t.endTime,t.text),t)s in i||(i[s]=t[s]);i.id=t.id,i.G=t}var e=this.H.textTracks();if(e)for(var n=0;n<e.length;n++)e[n]!==this&&e[n].removeCue(i);this.L.push(i),this.cues.V(this.L)},s.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}}},i}(Ue);Vr.prototype.A={cuechange:"cuechange"};var Ur=function(t){function i(s){var e,n;void 0===s&&(s={});var r=pe(e=t.call(this)||this);if(zs)for(var h in r=Ii.createElement("custom"),i.prototype)"constructor"!==h&&(r[h]=i.prototype[h]);var o=new Vr(s);return r.kind=o.kind,r.src=o.src,r.srclang=o.language,r.label=o.label,r.default=o.default,_.defineProperty(r,"readyState",{get:function(){return n}}),_.defineProperty(r,"track",{get:function(){return o}}),n=0,o.addEventListener("loadeddata",(function(){n=2,r.trigger({type:"load",target:r})})),zs?r||pe(e):e}return ge(i,t),i}(ve);Ur.prototype.A={load:"load"},Ur.NONE=0,Ur.LOADING=1,Ur.LOADED=2,Ur.ERROR=3;var zr,Lr=function(){function t(i){void 0===i&&(i=[]);var s=this;if(zs)for(var e in s=Ii.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);s.X=[],_.defineProperty(s,"length",{get:function(){return this.X.length}});for(var n=0,r=i.length;n<r;n++)s.J(i[n]);if(zs)return s}var i=t.prototype;return i.J=function(t){var i=this.X.length;""+i in this||_.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}(),Hr=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=pe(n),zs))for(var r in e=Ii.createElement("custom"),i.prototype)"constructor"!==r&&(e[r]=i.prototype[r]);e.Z=[],_.defineProperty(e,"length",{get:function(){return this.Z.length}});for(var h=0;h<s.length;h++)e.tt(s[h]);return e||pe(n)}ge(i,t);var s=i.prototype;return s.tt=function(t){var i=this.Z.length;""+i in this||_.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}(ve);for(zr in Hr.prototype.A={change:"change",addtrack:"addtrack",removetrack:"removetrack"},Hr.prototype.A)Hr.prototype["on"+zr]=null;var qr=function(t){function i(s){var e,n;if(void 0===s&&(s=[]),zs){for(var r in n=Ii.createElement("custom"),Hr.prototype)"constructor"!==r&&(n[r]=Hr.prototype[r]);for(var h in i.prototype)"constructor"!==h&&(n[h]=i.prototype[h])}return(n=e=t.call(this,s,n)||this)||pe(e)}return ge(i,t),i.prototype.tt=function(i){t.prototype.tt.call(this,i),i.addEventListener("modechange",ce(this,(function(){this.trigger("change")})))},i}(Hr),Wr=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].selected=!1)},Gr=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){Wr(s,s[r]);break}if(zs){for(var h in n=Ii.createElement("custom"),Hr.prototype)"constructor"!==h&&(n[h]=Hr.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,_.defineProperty(n,"selectedIndex",{get:function(){for(var t=0;t<this.length;t++)if(this[t].selected)return t;return-1},set:function(){}}),n||pe(e)}ge(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.selected&&Wr(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("selectedchange",(function(){s.st||(s.st=!0,Wr(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}(Hr),Xr=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].enabled=!1)},Jr=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){Xr(s,s[r]);break}if(zs){for(var h in n=Ii.createElement("custom"),Hr.prototype)"constructor"!==h&&(n[h]=Hr.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||pe(e)}ge(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.enabled&&Xr(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("enabledchange",(function(){s.st||(s.st=!0,Xr(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}(Hr),Qr=void 0;var Yr=function(t){function i(i,s){var e;return void 0===i&&(i={}),void 0===s&&(s=function(){}),i.reportTouchActivity=!1,(e=t.call(this,null,i,s)||this).et=!1,e.on("playing",(function(){this.et=!0})),e.on("loadstart",(function(){this.et=!1})),e.nt=i.textTracks,e.rt=i.videoTracks,e.ht=i.audioTracks,e.featuresProgressEvents||e.manualProgressOn(),e.featuresTimeupdateEvents||e.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach((function(t){!1===i["native"+t+"Tracks"]&&(e["featuresNative"+t+"Tracks"]=!1)})),!1===i.nativeCaptions&&(e.featuresNativeTextTracks=!1),e.featuresNativeTextTracks||e.emulateTextTracks(),e.ot=new qr,e.initTextTrackListeners(),e.initTrackListeners(),i.nativeControlsForTouch||e.emitTapEvents(),e.constructor&&(e.l=e.constructor.name||"Unknown Tech"),e}ge(i,t);var s=i.prototype;return s.manualProgressOn=function(){this.on("durationchange",this.onDurationChange),this.manualProgress=!0,this.one("ready",this.trackProgress)},s.manualProgressOff=function(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange)},s.trackProgress=function(t){this.stopTrackingProgress(),this.progressInterval=this.setInterval(ce(this,(function(){var t=this.bufferedPercent();this.ut!==t&&this.trigger("progress"),this.ut=t,1===t&&this.stopTrackingProgress()})),500)},s.onDurationChange=function(t){this.ct=this.duration()},s.buffered=function(){return we(0,0)},s.bufferedPercent=function(){return ke(this.buffered(),this.ct)},s.stopTrackingProgress=function(){this.clearInterval(this.progressInterval)},s.manualTimeUpdatesOn=function(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime),this.on("pause",this.stopTrackingCurrentTime)},s.manualTimeUpdatesOff=function(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime),this.off("pause",this.stopTrackingCurrentTime)},s.trackCurrentTime=function(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval((function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}),250)},s.stopTrackingCurrentTime=function(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},s.dispose=function(){this.clearTracks(["audio","video","text"]),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),t.prototype.dispose.call(this)},s.clearTracks=function(t){var i=this;(t=[].concat(t)).forEach((function(t){for(var s=i[t+"Tracks"]()||[],e=s.length;e--;){var n=s[e];"text"===t&&i.removeRemoteTextTrack(n),s.it(n)}}))},s.cleanupAutoTextTracks=function(){for(var t=this.ot||[],i=t.length;i--;){var s=t[i];this.removeRemoteTextTrack(s)}},s.reset=function(){},s.error=function(t){return void 0!==t&&(this.lt=new Ae(t),this.trigger("error")),this.lt},s.played=function(){return this.et?we(0,0):we()},s.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},s.initTextTrackListeners=function(){var t=ce(this,(function(){this.trigger("texttrackchange")})),i=this.textTracks();i&&(i.addEventListener("removetrack",t),i.addEventListener("addtrack",t),this.on("dispose",ce(this,(function(){i.removeEventListener("removetrack",t),i.removeEventListener("addtrack",t)}))))},s.initTrackListeners=function(){var t=this;["video","audio"].forEach((function(i){var s=function(){t.trigger(i+"trackchange")},e=t[i+"Tracks"]();e.addEventListener("removetrack",s),e.addEventListener("addtrack",s),t.on("dispose",(function(){e.removeEventListener("removetrack",s),e.removeEventListener("addtrack",s)}))}))},s.dt=function(){var t=this;if(!p.WebVTT)if(Ii.body.contains(this.el())){if(!this.h["vtt.js"]&&Li(Qr)&&_.keys(Qr).length>0)return void this.trigger("vttjsloaded");var i=Ii.createElement("script");i.src=this.h["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.12.4/vtt.min.js",i.onload=function(){t.trigger("vttjsloaded")},i.onerror=function(){t.trigger("vttjserror")},this.on("dispose",(function(){i.onload=null,i.onerror=null})),p.WebVTT=!0,this.el().parentNode.appendChild(i)}else this.ready(this.dt)},s.emulateTextTracks=function(){var t=this,i=this.textTracks();if(i){var s=this.remoteTextTracks(),e=function(t){return i.tt(t.track)},n=function(t){return i.it(t.track)};s.on("addtrack",e),s.on("removetrack",n),this.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)}}))}},s.videoTracks=function(){return this.rt=this.rt||new Gr,this.rt},s.audioTracks=function(){return this.ht=this.ht||new Jr,this.ht},s.textTracks=function(){return this.nt=this.nt||new qr,this.nt},s.remoteTextTracks=function(){return this.ft=this.ft||new qr,this.ft},s.remoteTextTrackEls=function(){return this.vt=this.vt||new Lr,this.vt},s.addTextTrack=function(t,i,s){if(!t)throw new b("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 Vr(n);return r.tt(h),h}(this,t,i,s)},s.createRemoteTextTrack=function(t){var i=de(t,{tech:this});return new Ur(i)},s.addRemoteTextTrack=function(t,i){void 0===t&&(t={});var s=this.createRemoteTextTrack(t);return!0!==i&&!1!==i&&(qi.warn('Calling addRemoteTextTrack without explicitly setting the "manualCleanup" parameter to `true` is deprecated and default to `false` in future version of video.js'),i=!0),this.remoteTextTrackEls().J(s),this.remoteTextTracks().tt(s.track),!0!==i&&this.ot.tt(s.track),s},s.removeRemoteTextTrack=function(t){var i=this.remoteTextTrackEls().Y(t);this.remoteTextTrackEls().K(i),this.remoteTextTracks().it(t),this.ot.it(t)},s.getVideoPlaybackQuality=function(){return{}},s.setPoster=function(){},s.playsinline=function(){},s.setPlaysinline=function(){},s.canPlayType=function(){return""},i.isTech=function(t){return t.prototype instanceof i||t instanceof i||t===i},i.registerTech=function(t,s){if(i.gt||(i.gt={}),!i.isTech(s))throw new b("Tech "+t+" must be a Tech");return i.gt[t]=s,s},i.getTech=function(t){return i.gt&&i.gt[t]?i.gt[t]:p&&p.videojs&&p.videojs[t]?(qi.warn("The "+t+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),p.videojs[t]):void 0},i}(fe);Yr.prototype.nt,Yr.prototype.ht,Yr.prototype.rt,Yr.prototype.featuresVolumeControl=!0,Yr.prototype.featuresFullscreenResize=!1,Yr.prototype.featuresPlaybackRate=!1,Yr.prototype.featuresProgressEvents=!1,Yr.prototype.featuresTimeupdateEvents=!1,Yr.prototype.featuresNativeTextTracks=!1,Yr.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:qi.error("No source hander found for the current source.")),this.disposeSourceHandler(),this.off("dispose",this.disposeSourceHandler),s!==t.nativeSourceHandler&&(this.bt=i,this.off(this.v,"loadstart",t.prototype.wt),this.off(this.v,"loadstart",t.prototype.kt),this.one(this.v,"loadstart",t.prototype.wt)),this.yt=s.handleSource(i,this,this.h),this.on("dispose",this.disposeSourceHandler),this},t.prototype.wt=function(){this.one(this.v,"loadstart",t.prototype.kt)},t.prototype.kt=function(){this.disposeSourceHandler(),this.one(this.v,"loadstart",t.prototype.kt)},t.prototype.disposeSourceHandler=function(){this.bt&&(this.clearTracks(["audio","video"]),this.bt=null),this.cleanupAutoTextTracks(),this.yt&&(this.off(this.v,"loadstart",t.prototype.wt),this.off(this.v,"loadstart",t.prototype.kt),this.yt.dispose&&this.yt.dispose(),this.yt=null)}},fe.registerComponent("Tech",Yr),fe.registerComponent("MediaTechController",Yr),Yr.registerTech("Tech",Yr);var Kr=function(t){function i(i,s,e){var n;if(n=t.call(this,i,s,e)||this,s.playerOptions.sources&&0!==s.playerOptions.sources.length)i.src(s.playerOptions.sources);else for(var r=0,h=s.playerOptions.techOrder;r<h.length;r++){var o=le(h[r]),a=Yr.getTech(o);if(o||(a=fe.getComponent(o)),a&&a.isSupported()){i._t(o);break}}return n}return ge(i,t),i}(fe);fe.registerComponent("MediaLoader",Kr);var Zr=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}ge(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=Ui({className:this.buildCSSClass(),tabIndex:0},s),"button"===i&&qi.error("Creating a ClickableComponent with an HTML element of "+i+" is not supported; use a Button instead."),e=Ui({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=is("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){te(Ii,"keydown",ce(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){ie(Ii,"keydown",ce(this,this.handleKeyPress))},i}(fe);fe.registerComponent("ClickableComponent",Zr);var th=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).update(),i.on("posterchange",ce(pe(e),e.update)),e}ge(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=is("div",{className:"vjs-poster",tabIndex:-1});return Gs||(this.jt=is("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}(Zr);fe.registerComponent("PosterImage",th);var ih="#222",sh={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 eh(t,i){return"rgba("+C(t[1]+t[1],16)+","+C(t[2]+t[2],16)+","+C(t[3]+t[3],16)+","+i+")"}function nh(t,i,s){try{t.style[i]=s}catch(t){return}}var rh=function(t){function i(i,s,e){var n;return n=t.call(this,i,s,e)||this,i.on("loadstart",ce(pe(n),n.toggleDisplay)),i.on("texttrackchange",ce(pe(n),n.updateDisplay)),i.ready(ce(pe(n),(function(){if(i.H&&i.H.featuresNativeTextTracks)this.hide();else{i.on("fullscreenchange",ce(this,this.updateDisplay));for(var t=this.h.playerOptions.tracks||[],s=0;s<t.length;s++)this.t.addRemoteTextTrack(t[s],!0);var e,n,r={captions:1,subtitles:1},h=this.t.textTracks();if(h){for(var o=0;o<h.length;o++){var a=h[o];a.default&&("descriptions"!==a.kind||e?a.kind in r&&!n&&(n=a):e=a)}n?n.mode="showing":e&&(e.mode="showing")}}}))),n}ge(i,t);var s=i.prototype;return s.toggleDisplay=function(){this.t.H&&this.t.H.featuresNativeTextTracks?this.hide():this.show()},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-text-track-display"},{"aria-live":"off","aria-atomic":"true"})},s.clearDisplay=function(){"function"==typeof p.WebVTT&&p.WebVTT.processCues(p,[],this.v)},s.updateDisplay=function(){var t=this.t.textTracks();if(this.clearDisplay(),t){for(var i=null,s=null,e=t.length;e--;){var n=t[e];"showing"===n.mode&&("descriptions"===n.kind?i=n:s=n)}s?("off"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","off"),this.updateForTrack(s)):i&&("assertive"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","assertive"),this.updateForTrack(i))}},s.updateForTrack=function(t){if("function"==typeof p.WebVTT&&t.activeCues){for(var i=this.t.textTrackSettings.getValues(),s=[],e=0;e<t.activeCues.length;e++)s.push(t.activeCues[e]);p.WebVTT.processCues(p,s,this.v);for(var n=s.length;n--;){var r=s[n];if(r){var h=r.displayState;if(i.color&&(h.firstChild.style.color=i.color),i.textOpacity&&nh(h.firstChild,"color",eh(i.color||"#fff",i.textOpacity)),i.backgroundColor&&(h.firstChild.style.backgroundColor=i.backgroundColor),i.backgroundOpacity&&nh(h.firstChild,"backgroundColor",eh(i.backgroundColor||"#000",i.backgroundOpacity)),i.windowColor&&(i.windowOpacity?nh(h,"backgroundColor",eh(i.windowColor,i.windowOpacity)):h.style.backgroundColor=i.windowColor),i.edgeStyle&&("dropshadow"===i.edgeStyle?h.firstChild.style.textShadow="2px 2px 3px #222, 2px 2px 4px #222, 2px 2px 5px "+ih:"raised"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #222, 2px 2px #222, 3px 3px "+ih:"depressed"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #ccc, 0 1px #ccc, -1px -1px #222, 0 -1px "+ih:"uniform"===i.edgeStyle&&(h.firstChild.style.textShadow="0 0 4px #222, 0 0 4px #222, 0 0 4px #222, 0 0 4px "+ih)),i.fontPercent&&1!==i.fontPercent){var o=p.parseFloat(h.style.fontSize);h.style.fontSize=o*i.fontPercent+"px",h.style.height="auto",h.style.top="auto",h.style.bottom="2px"}i.fontFamily&&"default"!==i.fontFamily&&("small-caps"===i.fontFamily?h.firstChild.style.fontVariant="small-caps":h.firstChild.style.fontFamily=sh[i.fontFamily])}}}},i}(fe);fe.registerComponent("TextTrackDisplay",rh);var hh=function(t){function i(){return t.apply(this,arguments)||this}return ge(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"})},i}(fe);fe.registerComponent("LoadingSpinner",hh);var oh=function(t){function i(){return t.apply(this,arguments)||this}ge(i,t);var s=i.prototype;return s.createEl=function(t,i,s){void 0===t&&(t="button"),void 0===i&&(i={}),void 0===s&&(s={}),i=Ui({className:this.buildCSSClass()},i),"button"!==t&&(qi.warn("Creating a Button with an HTML element of "+t+" is deprecated; use ClickableComponent instead."),i=Ui({tabIndex:0},i),s=Ui({role:"button"},s)),s=Ui({type:"button","aria-live":"polite"},s);var e=fe.prototype.createEl.call(this,t,i,s);return this.createControlTextEl(e),e},s.addChild=function(t,i){void 0===i&&(i={});var s=this.constructor.name;return qi.warn("Adding an actionable (user controllable) child to a Button ("+s+") is not supported; use a ClickableComponent instead."),fe.prototype.addChild.call(this,t,i)},s.enable=function(){t.prototype.enable.call(this),this.v.removeAttribute("disabled")},s.disable=function(){t.prototype.disable.call(this),this.v.setAttribute("disabled","disabled")},s.handleKeyPress=function(i){32!==i.which&&13!==i.which&&t.prototype.handleKeyPress.call(this,i)},i}(Zr);fe.registerComponent("Button",oh);var ah=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Tt=!1,e.on("mousedown",e.handleMouseDown),e}ge(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}(oh);ah.prototype.St="Play Video",fe.registerComponent("BigPlayButton",ah);var uh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).controlText(s&&s.controlText||"Close"),e}ge(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}(oh);fe.registerComponent("CloseButton",uh);var ch=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}ge(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}(oh);function lh(t,i){void 0===i&&(i=t),t=t<0?0:t;var s=x.floor(t%60),e=x.floor(t/60%60),n=x.floor(t/3600),r=x.floor(i/60%60),h=x.floor(i/3600);return(j(t)||t===1/0)&&(n=e=s="-"),(n=n>0||h>0?n+":":"")+(e=((n||r>=10)&&e<10?"0"+e:e)+":")+(s=s<10?"0"+s:s)}ch.prototype.St="Play",fe.registerComponent("PlayToggle",ch);var dh=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}ge(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=is("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=lh(i,this.t.duration());e!==this.Mt&&(this.Mt=e,this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e)},i}(fe);fe.registerComponent("CurrentTimeDisplay",dh);var fh=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}ge(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=is("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=lh(i);this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e}},i}(fe);fe.registerComponent("DurationDisplay",fh);var vh=function(t){function i(){return t.apply(this,arguments)||this}return ge(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}(fe);fe.registerComponent("TimeDivider",vh);var ph=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}ge(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=is("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=lh(this.t.remainingTime());s!==this.Mt&&(this.Mt=s,this.S.innerHTML='<span class="vjs-control-text">'+i+"</span> -"+s)}},i}(fe);fe.registerComponent("RemainingTimeDisplay",ph);var mh=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}ge(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=is("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.Ct=is("span",{className:"vjs-control-text",innerHTML:this.localize("Stream Type")}),this.At=Ii.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}(fe);fe.registerComponent("LiveDisplay",mh);var gh=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}ge(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=Ui({tabIndex:0},s),e=Ui({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(),Ii.body.focus(),Ii.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;Ii.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=ys(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}(fe);function yh(t,i){if(!t||!i)return"";if("function"==typeof p.getComputedStyle){var s=p.getComputedStyle(t);return s?s[i]:""}return t.currentStyle[i]||""}fe.registerComponent("Slider",gh);var bh=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}ge(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=is("span",{innerHTML:this.localize("Loaded")}),this.It=Ii.createTextNode(": 0%"),this.Ct=is("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.Nt),this.Ct.appendChild(this.It),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(is()),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}(fe);fe.registerComponent("LoadProgressBar",bh);var wh=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(ce(pe(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}ge(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.Bt=is("span",{innerHTML:this.localize("Progress")}),this.Ft=Ii.createTextNode(": 0%"),this.Ct=is("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.Bt),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",lh(i,this.t.duration()))},s.handleLanguagechange=function(){this.Bt.innerHTML=this.localize("Progress")},i}(fe);fe.registerComponent("PlayProgressBar",wh);var kh=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(ce(pe(e),e.updateDataAttr)),e}ge(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=is("div",{className:"vjs-time-tooltip"}),this.Bt=is("span",{innerHTML:this.localize("Progress")}),this.Ft=Ii.createTextNode(": 0%"),this.Ct=is("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.Bt),this.Ct.appendChild(this.Ft),i.appendChild(this.tooltip),i.appendChild(this.Ct),i},s.updateDataAttr=function(t){var i=lh(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.Bt.innerHTML=this.localize("Progress")},i}(fe);fe.registerComponent("TooltipProgressBar",kh);var _h=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(ce(pe(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}ge(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=S(yh(this.player().el(),"width")),s=S(yh(this.tooltipProgressBar.tooltip,"width")),e=this.tooltipProgressBar.el().style;e.maxWidth=x.floor(i-s/2)+"px",e.minWidth=x.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",lh(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}(gh);_h.prototype.h={children:["loadProgressBar","mouseTimeDisplay","playProgressBar"],barName:"playProgressBar"},_h.prototype.playerEvent="timeupdate",fe.registerComponent("SeekBar",_h);var xh=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=is("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)}}(ce(pe(e),e.handleMouseMove),25))})),e}ge(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-gs(this.el().parentNode).left;this.update(s,e)},s.update=function(t,i){var s=lh(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=S(yh(this.tooltip,"width"))/2;this.tooltip.innerHTML=s,this.tooltip.style.right="-"+(n-e)+"px"}},s.calculateDistance=function(t){return ys(this.el().parentNode,t).x},s.Dt=function(t){if(!this.keepTooltipsInside)return t;var i=S(yh(this.player().el(),"width")),s=S(yh(this.tooltip,"width"))/2,e=t;return t<s?e=x.ceil(s):t>i-s&&(e=x.floor(i-s)),e},i}(fe);fe.registerComponent("MouseTimeDisplay",xh);var Ch=function(t){function i(){return t.apply(this,arguments)||this}return ge(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},i}(fe);Ch.prototype.h={children:["seekBar"]},fe.registerComponent("ProgressControl",Ch);var Sh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"fullscreenchange",e.handleFullscreenChange),e}ge(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}(oh);Sh.prototype.St="Fullscreen",fe.registerComponent("FullscreenToggle",Sh);var jh=function(t){function i(){return t.apply(this,arguments)||this}return ge(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}(fe);fe.registerComponent("VolumeLevel",jh);var Th=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.updateARIAAttributes),i.ready(ce(pe(e),e.updateARIAAttributes)),e}ge(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}(gh);Th.prototype.h={children:["volumeLevel"],barName:"volumeLevel"},Th.prototype.playerEvent="volumechange",fe.registerComponent("VolumeBar",Th);var Mh=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 ge(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control"})},i}(fe);Mh.prototype.h={children:["volumeBar"]},fe.registerComponent("VolumeControl",Mh);var Ah=function(t){function i(){return t.apply(this,arguments)||this}ge(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",ce(this,(function(){this.unlockShowing()})))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=is(i,{className:"vjs-menu-content"});var s=t.prototype.createEl.call(this,"div",{append:this.S,className:"vjs-menu"});return s.appendChild(this.S),te(s,"click",(function(t){t.preventDefault(),t.stopImmediatePropagation()})),s},i}(fe);fe.registerComponent("Popup",Ah);var Ph=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e}ge(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}(Zr);fe.registerComponent("PopupButton",Ph);var Eh=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}ge(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++)ls(this.v,"vjs-vol-"+n);cs(this.v,"vjs-vol-"+s)},i}(oh);Eh.prototype.St="Mute",fe.registerComponent("MuteToggle",Eh);var Nh=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(pe(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}ge(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 Ah(this.t,{contentElType:"div"}),i=new Th(this.t,this.h.volumeBar);return t.addChild(i),this.menuContent=t,this.volumeBar=i,this.attachVolumeBarEvents(),t},s.handleClick=function(i){Eh.prototype.handleClick.call(this),t.prototype.handleClick.call(this)},s.attachVolumeBarEvents=function(){this.menuContent.on(["mousedown","touchdown"],ce(this,this.handleMouseDown))},s.handleMouseDown=function(t){this.on(["mousemove","touchmove"],ce(this.volumeBar,this.volumeBar.handleMouseMove)),this.on(this.v.ownerDocument,["mouseup","touchend"],this.handleMouseUp)},s.handleMouseUp=function(t){this.off(["mousemove","touchmove"],ce(this.volumeBar,this.volumeBar.handleMouseMove))},i}(Ph);Nh.prototype.volumeUpdate=Eh.prototype.update,Nh.prototype.St="Mute",fe.registerComponent("VolumeMenuButton",Nh);var Ih=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).$t=-1,e.on("keydown",e.handleKeyPress),e}ge(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",ce(this,(function(t){this.unlockShowing()})))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=is(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),te(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}(fe);fe.registerComponent("Menu",Ih);var Bh=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}ge(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 Ih(this.t);if(this.Vt=0,this.h.title){var i=is("li",{className:"vjs-menu-title",innerHTML:le(this.h.title),tabIndex:-1});this.Vt+=1,t.m.unshift(i),es(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",ce(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}(Zr);fe.registerComponent("MenuButton",Bh);var Fh=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 pe(e);var r=ce(pe(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 ge(i,t),i}(Bh);fe.registerComponent("TrackButton",Fh);var Dh=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}ge(i,t);var s=i.prototype;return s.createEl=function(i,s,e){this.nonIconControl=!0;var n=t.prototype.createEl.call(this,"li",Ui({className:"vjs-menu-item",tabIndex:-1},s),e);return this.Ut=Ii.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}(Zr);fe.registerComponent("MenuItem",Dh);var $h=function(t){function i(i,s){var e,n,r=s.track,h=i.textTracks();if(s.label=r.label||r.language||"Unknown",s.selected=r.default||"showing"===r.mode,(e=t.call(this,i,s)||this).track=r,h){var o=ce(pe(e),e.handleTracksChange);i.on(["loadstart","texttrackchange"],o),h.addEventListener("change",o),e.on("dispose",(function(){h.removeEventListener("change",o)}))}h&&void 0===h.onchange&&e.on(["tap","click"],(function(){if("object"!=typeof p.Event)try{n=new p.Event("change")}catch(t){}n||(n=Ii.createEvent("Event")).initEvent("change",!0,!0),h.dispatchEvent(n)}));return e}ge(i,t);var s=i.prototype;return s.handleClick=function(i){var s=this.track.kind,e=this.t.textTracks();if(t.prototype.handleClick.call(this,i),e)for(var n=0;n<e.length;n++){var r=e[n];r.kind===s&&(r===this.track?"showing"!==r.mode&&(r.mode="showing"):"disabled"!==r.mode&&(r.mode="disabled"))}},s.handleTracksChange=function(t){this.selected("showing"===this.track.mode)},i}(Dh);fe.registerComponent("TextTrackMenuItem",$h);var Rh=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 ge(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}($h);fe.registerComponent("OffTextTrackMenuItem",Rh);var Oh=function(t){function i(i,s){return void 0===s&&(s={}),s.tracks=i.textTracks(),t.call(this,i,s)||this}return ge(i,t),i.prototype.createItems=function(t){void 0===t&&(t=[]),t.push(new Rh(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 $h(this.t,{track:e,selectable:!0}))}return t},i}(Fh);fe.registerComponent("TextTrackButton",Oh);var Vh=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",ce(pe(e),e.update)),e}ge(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}(Dh);fe.registerComponent("ChaptersTrackMenuItem",Vh);var Uh=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}ge(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(le(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 Vh(this.t,{track:this.Lt,cue:n});t.push(r)}return t},i}(Oh);Uh.prototype.zt="chapters",Uh.prototype.St="Chapters",fe.registerComponent("ChaptersButton",Uh);var zh=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=ce(pe(n),n.handleTracksChange);r.addEventListener("change",h),n.on("dispose",(function(){r.removeEventListener("change",h)}))}return n}ge(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}(Oh);zh.prototype.zt="descriptions",zh.prototype.St="Descriptions",fe.registerComponent("DescriptionsButton",zh);var Lh=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 ge(i,t),i.prototype.buildCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildCSSClass.call(this)},i}(Oh);Lh.prototype.zt="subtitles",Lh.prototype.St="Subtitles",fe.registerComponent("SubtitlesButton",Lh);var Hh=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 ge(i,t),i.prototype.handleClick=function(t){this.player().getChild("textTrackSettings").show(),this.player().getChild("textTrackSettings").v.focus()},i}($h);fe.registerComponent("CaptionSettingsMenuItem",Hh);var qh=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}ge(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 Hh(this.t,{kind:this.zt})),this.Vt+=1),t.prototype.createItems.call(this,i)},i}(Oh);qh.prototype.zt="captions",qh.prototype.St="Captions",fe.registerComponent("CaptionsButton",qh);var Wh=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=ce(pe(e),e.handleTracksChange);r.addEventListener("change",h),e.on("dispose",(function(){r.removeEventListener("change",h)}))}return e}ge(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}(Dh);fe.registerComponent("AudioTrackMenuItem",Wh);var Gh=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}ge(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 Wh(this.t,{track:e,selectable:!0}))}return t},i}(Fh);Gh.prototype.St="Audio Track",fe.registerComponent("AudioTrackButton",Gh);var Xh=function(t){function i(i,s){var e,n=s.rate,r=S(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}ge(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}(Dh);Xh.prototype.contentElType="button",fe.registerComponent("PlaybackRateMenuItem",Xh);var Jh=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}ge(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this);return this.Ut=is("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 Ih(this.player()),i=this.playbackRates();if(i)for(var s=i.length-1;s>=0;s--)t.addChild(new Xh(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}(Bh);Jh.prototype.St="Playback Rate",fe.registerComponent("PlaybackRateMenuButton",Jh);var Qh=function(t){function i(){return t.apply(this,arguments)||this}ge(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}(fe);fe.registerComponent("Spacer",Qh);var Yh=function(t){function i(){return t.apply(this,arguments)||this}ge(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);fe.registerComponent("CustomControlSpacer",Yh);var Kh=function(t){function i(){return t.apply(this,arguments)||this}return ge(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"},{role:"group"})},i}(fe);Kh.prototype.h={children:["playToggle","volumeMenuButton","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subtitlesButton","captionsButton","audioTrackButton","fullscreenToggle"]},fe.registerComponent("ControlBar",Kh);var Zh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"error",e.open),e}ge(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}(Fe);Zh.prototype.h=de(Fe.prototype.h,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),fe.registerComponent("ErrorDisplay",Zh);var to="vjs-text-track-settings",io=["#000","Black"],so=["#00F","Blue"],eo=["#0FF","Cyan"],no=["#0F0","Green"],ro=["#F0F","Magenta"],ho=["#F00","Red"],oo=["#FFF","White"],ao=["#FF0","Yellow"],uo=["1","Opaque"],co=["0.5","Semi-Transparent"],lo=["0","Transparent"],fo={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[io,oo,ho,no,so,ao,ro,eo]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[uo,co,lo]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[oo,io,ho,no,so,ao,ro,eo]},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:[uo,co]},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:[lo,co,uo]}};function vo(t,i){if(i&&(t=i(t)),t&&"none"!==t)return t}fo.windowColor.options=fo.backgroundColor.options;var po,mo=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).setDefaults(),e.hide(),e.updateDisplay=ce(pe(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()})),Vi(fo,(function(t){e.on(e.$(t.selector),"change",e.updateDisplay)})),e.h.persistTextTrackSettings&&e.restoreSettings(),e}ge(i,t);var s=i.prototype;return s.qt=function(t){var i=this,s=fo[t],e=s.id.replace("%s",this.o);return[is("label",{className:"vjs-label",textContent:s.label},{for:e}),is("select",{id:e},void 0,s.options.map((function(t){return is("option",{textContent:i.localize(t[1]),value:t[0]})})))]},s.Wt=function(){var t=is("legend",{textContent:this.localize("Text")}),i=this.qt("color"),s=is("span",{className:"vjs-text-opacity vjs-opacity"},void 0,this.qt("textOpacity"));return is("fieldset",{className:"vjs-fg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Gt=function(){var t=is("legend",{textContent:this.localize("Background")}),i=this.qt("backgroundColor"),s=is("span",{className:"vjs-bg-opacity vjs-opacity"},void 0,this.qt("backgroundOpacity"));return is("fieldset",{className:"vjs-bg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Xt=function(){var t=is("legend",{textContent:this.localize("Window")}),i=this.qt("windowColor"),s=is("span",{className:"vjs-window-opacity vjs-opacity"},void 0,this.qt("windowOpacity"));return is("fieldset",{className:"vjs-window-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Jt=function(){return is("div",{className:"vjs-tracksettings-colors"},void 0,[this.Wt(),this.Gt(),this.Xt()])},s.Qt=function(){var t=is("div",{className:"vjs-font-percent vjs-tracksetting"},void 0,this.qt("fontPercent")),i=is("div",{className:"vjs-edge-style vjs-tracksetting"},void 0,this.qt("edgeStyle")),s=is("div",{className:"vjs-font-family vjs-tracksetting"},void 0,this.qt("fontFamily"));return is("div",{className:"vjs-tracksettings-font"},void 0,[t,i,s])},s.Yt=function(){var t=is("button",{className:"vjs-default-button",textContent:this.localize("Defaults")}),i=is("button",{className:"vjs-done-button",textContent:"Done"});return is("div",{className:"vjs-tracksettings-controls"},void 0,[t,i])},s.createEl=function(){var t=is("div",{className:"vjs-tracksettings"},void 0,[this.Jt(),this.Qt(),this.Yt()]),i=is("div",{className:"vjs-control-text",id:"TTsettingsDialogLabel-"+this.o,textContent:"Caption Settings Dialog"},{"aria-level":"1",role:"heading"}),s=is("div",{className:"vjs-control-text",id:"TTsettingsDialogDescription-"+this.o,textContent:"Beginning of dialog window. Escape will cancel and close the window."}),e=is("div",void 0,{role:"document"},[i,s,t]);return is("div",{className:"vjs-caption-settings vjs-modal-overlay",tabIndex:-1},{role:"dialog","aria-labelledby":i.id,"aria-describedby":s.id},e)},s.getValues=function(){var t=this;return function(t,i,s){return void 0===s&&(s=0),Oi(t).reduce((function(s,e){return i(s,t[e],e)}),s)}(fo,(function(i,s,e){var n=function(t,i){return vo(t.options[t.options.selectedIndex].value,i)}(t.$(s.selector),s.parser);return void 0!==n&&(i[e]=n),i}),{})},s.setValues=function(t){var i=this;Vi(fo,(function(s,e){!function(t,i,s){if(i)for(var e=0;e<t.options.length;e++)if(vo(t.options[e].value,s)===i){t.selectedIndex=e;break}}(i.$(s.selector),t[e],s.parser)}))},s.setDefaults=function(){var t=this;Vi(fo,(function(i){var s=i.hasOwnProperty("default")?i.default:0;t.$(i.selector).selectedIndex=s}))},s.restoreSettings=function(){var t;try{t=JSON.parse(p.localStorage.getItem(to))}catch(t){qi.warn(t)}t&&this.setValues(t)},s.saveSettings=function(){if(this.h.persistTextTrackSettings){var t=this.getValues();try{_.keys(t).length?p.localStorage.setItem(to,JSON.stringify(t)):p.localStorage.removeItem(to)}catch(t){qi.warn(t)}}},s.updateDisplay=function(){var t=this.t.getChild("textTrackDisplay");t&&t.updateDisplay()},i}(fe);fe.registerComponent("TextTrackSettings",mo);var go,e=function(t){function i(i,s){var e;e=t.call(this,i,s)||this;var n=i.source,r=!1;if(n&&(e.v.currentSrc!==n.src||i.tag&&3===i.tag.Kt)?e.setSource(n):e.Zt(e.v),e.v.hasChildNodes()){for(var h=e.v.childNodes,o=h.length,a=[];o--;){var u=h[o];"track"===u.nodeName.toLowerCase()&&(e.featuresNativeTextTracks?(e.remoteTextTrackEls().J(u),e.remoteTextTracks().tt(u.track),r||e.v.hasAttribute("crossorigin")||!Le(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=le(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&&qi.warn(Ji(po||(po=Bi(["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=ce(pe(e),e.handleTextTrackChange),e.hi=ce(pe(e),e.handleTextTrackAdd),e.oi=ce(pe(e),e.handleTextTrackRemove),e.ai()),e.ci(),(Ws||Ps||$s)&&!0===i.nativeControlsForTouch&&e.setControls(!0),e.di(),e.triggerReady(),e}ge(i,t);var s=i.prototype;return s.dispose=function(){var s=this;["audio","video","text"].forEach((function(t){var i=le(t),e=s.v[t+"Tracks"];e&&e.removeEventListener&&(e.removeEventListener("change",s["handle"+i+"ti"]),e.removeEventListener("addtrack",s["handle"+i+"ii"]),e.removeEventListener("removetrack",s["handle"+i+"si"])),e&&s.off("loadstart",s["removeOld"+i+"ei"])})),i.disposeMediaElement(this.v),t.prototype.dispose.call(this)},s.ci=function(){var t,i=this.textTracks(),s=function(){t=[];for(var s=0;s<i.length;s++){var e=i[s];"metadata"===e.kind&&t.push({track:e,storedMode:e.mode})}};s(),i.addEventListener("change",s);var e=function s(){for(var e=0;e<t.length;e++){var n=t[e];"disabled"===n.track.mode&&n.track.mode!==n.storedMode&&(n.track.mode=n.storedMode)}i.removeEventListener("change",s)};this.on("webkitbeginfullscreen",(function(){i.removeEventListener("change",s),i.removeEventListener("change",e),i.addEventListener("change",e)})),this.on("webkitendfullscreen",(function(){i.removeEventListener("change",s),i.addEventListener("change",s),i.removeEventListener("change",e)}))},s.createEl=function(){var t=this.h.tag;if(!t||!this.h.playerElIngest&&!this.movingMediaElementInDOM){if(t){var s=t.cloneNode(!0);t.parentNode&&t.parentNode.insertBefore(s,t),i.disposeMediaElement(t),t=s}else{t=Ii.createElement("video");var e=de({},this.h.tag&&vs(this.h.tag));Ws&&!0===this.h.nativeControlsForTouch||delete e.controls,fs(t,Ui(e,{id:this.h.techId,class:"vjs-tech"}))}t.playerId=this.h.playerId}void 0!==this.h.preload&&ps(t,"preload",this.h.preload);for(var n=["loop","muted","playsinline","autoplay"],r=n.length-1;r>=0;r--){var h=n[r],o=this.h[h];void 0!==o&&(o?ps(t,h,h):ms(t,h),t[h]=o)}return t},s.Zt=function(t){if(0!==t.networkState&&3!==t.networkState){if(0===t.readyState){var i=!1,s=function(){i=!0};this.on("loadstart",s);var e=function(){i||this.trigger("loadstart")};return this.on("loadedmetadata",e),void this.ready((function(){this.off("loadstart",s),this.off("loadedmetadata",e),i||this.trigger("loadstart")}))}var n=["loadstart"];n.push("loadedmetadata"),t.readyState>=2&&n.push("loadeddata"),t.readyState>=3&&n.push("canplay"),t.readyState>=4&&n.push("canplaythrough"),this.ready((function(){n.forEach((function(t){this.trigger(t)}),this)}))}},s.ai=function(){var t=this.el().textTracks;if(t){for(var i=0;i<t.length;i++)this.textTracks().tt(t[i]);t.addEventListener&&(t.addEventListener("change",this.ri),t.addEventListener("addtrack",this.hi),t.addEventListener("removetrack",this.oi)),this.on("loadstart",this.fi)}},s.handleTextTrackChange=function(t){var i=this.textTracks();this.textTracks().trigger({type:"change",target:i,currentTarget:i,srcElement:i})},s.handleTextTrackAdd=function(t){this.textTracks().tt(t.track)},s.handleTextTrackRemove=function(t){this.textTracks().it(t.track)},s.ni=function(t,i){var s=[];if(i){for(var e=0;e<t.length;e++){for(var n=t[e],r=!1,h=0;h<i.length;h++)if(i[h]===n){r=!0;break}r||s.push(n)}for(var o=0;o<s.length;o++){var a=s[o];t.it(a)}}},s.fi=function(t){var i=this.textTracks(),s=this.el().textTracks;this.ni(i,s)},s.play=function(){var t=this.v.play();void 0!==t&&"function"==typeof t.then&&t.then(null,(function(t){}))},s.setCurrentTime=function(t){try{this.v.currentTime=t}catch(t){qi(t,"Video is not ready. (Video.js)")}},s.duration=function(){var t=this;if(this.v.duration===1/0&&Bs&&Vs&&0===this.v.currentTime){return this.on("timeupdate",(function i(){t.v.currentTime>0&&(t.v.duration===1/0&&t.trigger("durationchange"),t.off("timeupdate",i))})),NaN}return this.v.duration||NaN},s.width=function(){return this.v.offsetWidth},s.height=function(){return this.v.offsetHeight},s.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)}))}},s.supportsFullScreen=function(){if("function"==typeof this.v.webkitEnterFullScreen){var t=p.navigator&&p.navigator.userAgent||"";if(/Android/.test(t)||!/Chrome|Mac OS X 10.5/.test(t))return!0}return!1},s.enterFullScreen=function(){var t=this.v;t.paused&&t.networkState<=t.HAVE_METADATA?(this.v.play(),this.setTimeout((function(){t.pause(),t.webkitEnterFullScreen()}),0)):t.webkitEnterFullScreen()},s.exitFullScreen=function(){this.v.webkitExitFullScreen()},s.src=function(t){if(void 0===t)return this.v.src;this.setSrc(t)},s.reset=function(){i.resetMediaElement(this.v)},s.currentSrc=function(){return this.bt?this.bt.src:this.v.currentSrc},s.setControls=function(t){this.v.controls=!!t},s.addTextTrack=function(i,s,e){return this.featuresNativeTextTracks?this.v.addTextTrack(i,s,e):t.prototype.addTextTrack.call(this,i,s,e)},s.createRemoteTextTrack=function(i){if(!this.featuresNativeTextTracks)return t.prototype.createRemoteTextTrack.call(this,i);var s=Ii.createElement("track");return i.kind&&(s.kind=i.kind),i.label&&(s.label=i.label),(i.language||i.srclang)&&(s.srclang=i.language||i.srclang),i.default&&(s.default=i.default),i.id&&(s.id=i.id),i.src&&(s.src=i.src),s},s.addRemoteTextTrack=function(i,s){var e=t.prototype.addRemoteTextTrack.call(this,i,s);return this.featuresNativeTextTracks&&this.el().appendChild(e),e},s.removeRemoteTextTrack=function(i){if(t.prototype.removeRemoteTextTrack.call(this,i),this.featuresNativeTextTracks)for(var s=this.$$("track"),e=s.length;e--;)i!==s[e]&&i!==s[e].track||this.el().removeChild(s[e])},s.getVideoPlaybackQuality=function(){if("function"==typeof this.el().getVideoPlaybackQuality)return this.el().getVideoPlaybackQuality();var t={};return void 0!==this.el().webkitDroppedFrameCount&&void 0!==this.el().webkitDecodedFrameCount&&(t.droppedVideoFrames=this.el().webkitDroppedFrameCount,t.totalVideoFrames=this.el().webkitDecodedFrameCount),p.performance&&"function"==typeof p.performance.now?t.creationTime=p.performance.now():p.performance&&p.performance.timing&&"number"==typeof p.performance.timing.navigationStart&&(t.creationTime=p.Date.now()-p.performance.timing.navigationStart),t},i}(Yr);Ki()&&(e.TEST_VID=Ii.createElement("video"),(go=Ii.createElement("track")).kind="captions",go.srclang="en",go.label="English",e.TEST_VID.appendChild(go)),e.isSupported=function(){try{e.TEST_VID.volume=.5}catch(t){return!1}return!(!e.TEST_VID||!e.TEST_VID.canPlayType)},e.canControlVolume=function(){try{var t=e.TEST_VID.volume;return e.TEST_VID.volume=t/2+.1,t!==e.TEST_VID.volume}catch(t){return!1}},e.canControlPlaybackRate=function(){if(Bs&&Vs&&Us<58)return!1;try{var t=e.TEST_VID.playbackRate;return e.TEST_VID.playbackRate=t/2+.1,t!==e.TEST_VID.playbackRate}catch(t){return!1}},e.supportsNativeTextTracks=function(){return qs},e.supportsNativeVideoTracks=function(){return!(!e.TEST_VID||!e.TEST_VID.videoTracks)},e.supportsNativeAudioTracks=function(){return!(!e.TEST_VID||!e.TEST_VID.audioTracks)},e.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange"],e.prototype.featuresVolumeControl=e.canControlVolume(),e.prototype.featuresPlaybackRate=e.canControlPlaybackRate(),e.prototype.movingMediaElementInDOM=!Ns,e.prototype.featuresFullscreenResize=!0,e.prototype.featuresProgressEvents=!0,e.prototype.featuresTimeupdateEvents=!0,e.prototype.featuresNativeTextTracks=e.supportsNativeTextTracks(),e.prototype.featuresNativeVideoTracks=e.supportsNativeVideoTracks(),e.prototype.featuresNativeAudioTracks=e.supportsNativeAudioTracks();var yo=e.TEST_VID&&e.TEST_VID.constructor.prototype.canPlayType,bo=/^application\/(?:x-|vnd\.apple\.)mpegurl/i,wo=/^video\/mp4/i;e.patchCanPlayType=function(){Fs>=4&&!Rs?e.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&bo.test(t)?"maybe":yo.call(this,t)}:Ds&&(e.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&wo.test(t)?"maybe":yo.call(this,t)})},e.unpatchCanPlayType=function(){var t=e.TEST_VID.constructor.prototype.canPlayType;return e.TEST_VID.constructor.prototype.canPlayType=yo,t},e.patchCanPlayType(),e.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){}}()}}},e.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){e.prototype[t]=function(){return this.v[t]||this.v.hasAttribute(t)}})),["muted","defaultMuted","autoplay","loop","playsinline"].forEach((function(t){e.prototype["set"+le(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){e.prototype[t]=function(){return this.v[t]}})),["volume","src","poster","preload","playbackRate"].forEach((function(t){e.prototype["set"+le(t)]=function(i){this.v[t]=i}})),["pause","load"].forEach((function(t){e.prototype[t]=function(){return this.v[t]()}})),Yr.withSourceHandlers(e),e.nativeSourceHandler={},e.nativeSourceHandler.canPlayType=function(t){try{return e.TEST_VID.canPlayType(t)}catch(t){return""}},e.nativeSourceHandler.canHandleSource=function(t,i){if(t.type)return e.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 e.nativeSourceHandler.canPlayType("video/"+s)}return""},e.nativeSourceHandler.handleSource=function(t,i,s){i.setSrc(t.src)},e.nativeSourceHandler.dispose=function(){},e.registerSourceHandler(e.nativeSourceHandler),fe.registerComponent("Html5",e),Yr.registerTech("Html5",e);var ko=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","ratechange","volumechange","texttrackchange"],_o=function(t){function i(s,e,n){var r;if(s.id=s.id||["vjs_video",Di()].join("_"),(e=Ui(i.getTagSettings(s),e)).initChildren=!1,e.createEl=!1,e.reportTouchActivity=!1,!e.language)if("function"==typeof s.closest){var h=s.closest("[lang]");h&&(e.language=h.getAttribute("lang"))}else for(var o=s;o&&1===o.nodeType;){if(vs(o).hasOwnProperty("lang")){e.language=o.getAttribute("lang");break}o=o.parentNode}if(!(r=t.call(this,null,e,n)||this).h||!r.h.techOrder||!r.h.techOrder.length)throw new b("No techOrder specified. Did you overwrite videojs.options instead of just changing the properties you want to override?");if(r.tag=s,r.tagAttributes=s&&vs(s),r.language(r.h.language),e.languages){var a={};_.getOwnPropertyNames(e.languages).forEach((function(t){a[t.toLowerCase()]=e.languages[t]})),r.vi=a}else r.vi=i.prototype.h.languages;r.pi={},r.mi=e.poster||"",r.gi=!!e.controls,s.controls=!1,r.yi=!1,r.v=r.createEl();var u=de(r.h);if(e.plugins){var c=e.plugins;_.getOwnPropertyNames(c).forEach((function(t){"function"==typeof this[t]?this[t](c[t]):qi.error("Unable to find plugin:",t)}),pe(r))}r.h.playerOptions=u,r.initChildren(),r.isAudio("audio"===s.nodeName.toLowerCase()),r.controls()?r.addClass("vjs-controls-enabled"):r.addClass("vjs-controls-disabled"),r.v.setAttribute("role","region"),r.isAudio()?r.v.setAttribute("aria-label","audio player"):r.v.setAttribute("aria-label","video player"),r.isAudio()&&r.addClass("vjs-audio"),r.bi()&&r.addClass("vjs-no-flex"),Ns||r.addClass("vjs-workinghover"),i.players[r.o]=pe(r);var l="5.20.6-opentelly.14".split(".")[0];return r.addClass("vjs-v"+l),r.userActive(!0),r.reportUserActivity(),r.wi(),r.on("fullscreenchange",r.ki),r.on("stageclick",r._i),r}ge(i,t);var s=i.prototype;return s.dispose=function(){this.trigger("dispose"),this.off("dispose"),this.xi&&this.xi.parentNode&&this.xi.parentNode.removeChild(this.xi),i.players[this.o]=null,this.tag&&this.tag.player&&(this.tag.player=null),this.v&&this.v.player&&(this.v.player=null),this.H&&this.H.dispose(),t.prototype.dispose.call(this)},s.createEl=function(){var i,s=this.tag,e=this.Ci=s.parentNode&&s.parentNode.hasAttribute&&s.parentNode.hasAttribute("data-vjs-player");i=this.v=e?s.parentNode:t.prototype.createEl.call(this,"div"),s.setAttribute("tabindex","-1"),s.removeAttribute("width"),s.removeAttribute("height");var n=vs(s);if(_.getOwnPropertyNames(n).forEach((function(t){"class"===t?i.className+=" "+n[t]:i.setAttribute(t,n[t])})),s.playerId=s.id,s.id+="Si",s.className="vjs-tech",s.player=i.player=this,this.addClass("vjs-paused"),!0!==p.VIDEOJS_NO_DYNAMIC_STYLE){this.xi=ae("vjs-styles-dimensions");var r=Cs(".vjs-styles-defaults"),h=Cs("head");h.insertBefore(this.xi,r?r.nextSibling:h.firstChild)}this.width(this.h.width),this.height(this.h.height),this.fluid(this.h.fluid),this.aspectRatio(this.h.aspectRatio);for(var o=s.getElementsByTagName("a"),a=0;a<o.length;a++){var u=o.item(a);cs(u,"vjs-hidden"),u.setAttribute("hidden","hidden")}return s.Kt=s.networkState,s.parentNode&&!e&&s.parentNode.insertBefore(i,s),es(s,i),this.m.unshift(s),this.v=i,i},s.width=function(t){return this.dimension("width",t)},s.height=function(t){return this.dimension("height",t)},s.dimension=function(t,i){var s="width"===t?"ji":"Ti";if(void 0===i)return this[s]||0;if(""===i)this[s]=void 0;else{var e=S(i);if(j(e))return qi.error('Improper value "'+i+'" supplied for for '+t),this;this[s]=e}return this.Mi(),this},s.fluid=function(t){if(void 0===t)return!!this.Ai;this.Ai=!!t,t?this.addClass("vjs-fluid"):this.removeClass("vjs-fluid"),this.Mi()},s.aspectRatio=function(t){if(void 0===t)return this.Pi;if(!/^\d+\:\d+$/.test(t))throw new b("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.Pi=t,this.fluid(!0),this.Mi()},s.Mi=function(){if(!0!==p.VIDEOJS_NO_DYNAMIC_STYLE){var t,i,s,e=(void 0!==this.Pi&&"auto"!==this.Pi?this.Pi:this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9").split(":"),n=e[1]/e[0];t=void 0!==this.ji?this.ji:void 0!==this.Ti?this.Ti/n:this.videoWidth()||300,i=void 0!==this.Ti?this.Ti:t*n,s=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(s),ue(this.xi,"\n ."+s+" {\n width: "+t+"px;\n height: "+i+"px;\n }\n\n ."+s+".vjs-fluid {\n padding-top: "+100*n+"%;\n }\n ")}else{var r="number"==typeof this.ji?this.ji:this.h.width,h="number"==typeof this.Ti?this.Ti:this.h.height,o=this.H&&this.H.el();o&&(r>=0&&(o.width=r),h>=0&&(o.height=h))}},s._t=function(t,i){var s=this;this.H&&this.Ei(),"Html5"!==t&&this.tag&&(Yr.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.Ni=t,this.j=!1;var e=Ui({source:i,nativeControlsForTouch:this.h.nativeControlsForTouch,playerId:this.id(),techId:this.id()+"_"+t+"Ii",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&&(e.tag=this.tag),i&&(this.Bi=i.type,i.src===this.pi.src&&this.pi.currentTime>0&&(e.startTime=this.pi.currentTime),this.pi.sources=null,this.pi.source=i,this.pi.src=i.src);var n=Yr.getTech(t);n||(n=fe.getComponent(t)),this.H=new n(e),this.H.ready(ce(this,this.Fi),!0),Ie(this.Di||[],this.H),ko.forEach((function(t){s.on(s.H,t,s["handleTech"+le(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||es(this.H.el(),this.contentEl()),this.tag&&(this.tag.player=null,this.tag=null)},s.Ei=function(){this.rt=this.videoTracks(),this.nt=this.textTracks(),this.ht=this.audioTracks(),this.Di=Ne(this.H),this.j=!1,this.H.dispose(),this.H=!1},s.tech=function(t){if(t&&t.IWillNotUseThisInPlugins)return this.H;var i="\n Please make sure that you are not using this inside of a plugin.\n To disable this alert and error, please pass in an object with\n `IWillNotUseThisInPlugins` to the `tech` method. See\n https://github.com/videojs/video.js/issues/2617 for more info.\n ";throw p.alert(i),new b(i)},s.ts=function(){this.ss(),this.on(this.H,"mousedown",this.es),this.on(this.H,"touchstart",this.ns),this.on(this.H,"touchmove",this.rs),this.on(this.H,"touchend",this.hs),this.on(this.H,"tap",this.os)},s.ss=function(){this.off(this.H,"tap",this.os),this.off(this.H,"touchstart",this.ns),this.off(this.H,"touchmove",this.rs),this.off(this.H,"touchend",this.hs),this.off(this.H,"mousedown",this.es)},s.Fi=function(){if(this.triggerReady(),this.pi.volume&&this.us("setVolume",this.pi.volume),this.Yi(),this.Xi(),(this.src()||this.currentSrc())&&this.tag&&this.h.autoplay&&this.paused()){try{delete this.tag.poster}catch(t){qi("deleting tag.poster throws in some browsers",t)}this.play()}},s.$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"))},s.hasStarted=function(t){return void 0!==t?(this.et!==t&&(this.et=t,t?(this.addClass("vjs-has-started"),this.trigger("firstplay")):this.removeClass("vjs-has-started")),this):!!this.et},s.qi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},s.Ri=function(){var t=this;this.addClass("vjs-waiting"),this.trigger("waiting"),this.one("timeupdate",(function(){return t.removeClass("vjs-waiting")}))},s.Oi=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},s.Vi=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},s.Ui=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},s.Li=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},s.Hi=function(){this.removeClass("vjs-seeking"),this.trigger("seeked")},s.Wi=function(){this.h.starttime&&(qi.warn("Passing the `starttime` option to the player will be deprecated in 6.0"),this.currentTime(this.h.starttime)),this.addClass("vjs-has-started"),this.trigger("firstplay")},s.Gi=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},s.zi=function(){this.addClass("vjs-ended"),this.h.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},s.Xi=function(){this.duration(this.Zi("duration"))},s.es=function(t){0===t.button&&this.controls()&&(void 0!==this.h&&void 0!==this.h.userActions&&void 0!==this.h.userActions.click&&!1===this.h.userActions.click||(void 0!==this.h&&void 0!==this.h.userActions&&"function"==typeof this.h.userActions.click?this.h.userActions.click.call(this,t):this.paused()?this.play():this.pause()))},s.os=function(){this.userActive(!this.userActive())},s.ns=function(){this.userWasActive=this.userActive()},s.rs=function(){this.userWasActive&&this.reportUserActivity()},s.hs=function(t){t.cancelable&&t.preventDefault()},s.ki=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},s._i=function(){this.reportUserActivity()},s.Ji=function(t,i){i&&(this.toggleClass("vjs-ios-native-fs",!(!i.nativeIOSFullscreen||!i.isFullscreen)),this.isFullscreen(i.isFullscreen)),this.trigger("fullscreenchange")},s.Qi=function(){var t=this.H.error();this.error(t)},s.Ki=function(){var t=null;arguments.length>1&&(t=arguments[1]),this.trigger("textdata",t)},s.getCache=function(){return this.pi},s.us=function(t,i){if(this.H&&!this.H.j)this.H.ready((function(){this[t](i)}),!0);else try{this.H&&this.H[t](i)}catch(t){throw qi(t),t}},s.Zi=function(t){if(this.H&&this.H.j)try{return this.H[t]()}catch(i){throw void 0===this.H[t]?qi("Video.js: "+t+" method not defined for "+this.Ni+" playback technology.",i):"TypeError"===i.name?(qi("Video.js: "+t+" unavailable on "+this.Ni+" playback technology element.",i),this.H.j=!1):qi(i),i}},s.play=function(){return this.src()||this.currentSrc()?this.us("play"):this.H.one("loadstart",(function(){this.play()})),this},s.pause=function(){return this.us("pause"),this},s.paused=function(){return!1!==this.Zi("paused")},s.scrubbing=function(t){return void 0!==t?(this.yi=!!t,t?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing"),this):this.yi},s.currentTime=function(t){return void 0!==t?(this.us("setCurrentTime",t),this):(this.pi.currentTime=this.Zi("currentTime")||0,this.pi.currentTime)},s.duration=function(t){return void 0===t?void 0!==this.pi.duration?this.pi.duration:NaN:((t=S(t))<0&&(t=1/0),t!==this.pi.duration&&(this.pi.duration=t,t===1/0?this.addClass("vjs-live"):this.removeClass("vjs-live"),this.trigger("durationchange")),this)},s.remainingTime=function(){return this.duration()-this.currentTime()},s.buffered=function(){var t=this.Zi("buffered");return t&&t.length||(t=we(0,0)),t},s.bufferedPercent=function(){return ke(this.buffered(),this.duration())},s.bufferedEnd=function(){var t=this.buffered(),i=this.duration(),s=t.end(t.length-1);return s>i&&(s=i),s},s.volume=function(t){var i;return void 0!==t?(i=x.max(0,x.min(1,S(t))),this.pi.volume=i,this.us("setVolume",i),this):(i=S(this.Zi("volume")),j(i)?1:i)},s.muted=function(t){return void 0!==t?(this.us("setMuted",t),this):this.Zi("muted")||!1},s.supportsFullScreen=function(){return this.Zi("supportsFullScreen")||!1},s.isFullscreen=function(t){return void 0!==t?(this.cs=!!t,this):!!this.cs},s.requestFullscreen=function(t){var i,s=je;return this.isFullscreen(!0),s.requestFullscreen?(te(Ii,s.fullscreenchange,ce(this,(function t(i){this.isFullscreen(Ii[s.fullscreenElement]),!1===this.isFullscreen()&&ie(Ii,s.fullscreenchange,t),this.trigger("fullscreenchange")}))),s.prefixed||(i=this.h.fullscreenOptions,void 0!==t&&(i=t)),this.v[s.requestFullscreen](i)):this.H.supportsFullScreen()?this.us("enterFullScreen"):(this.enterFullWindow(),this.trigger("fullscreenchange")),this},s.exitFullscreen=function(){var t=je;return this.isFullscreen(!1),t.requestFullscreen?Ii[t.exitFullscreen]():this.H.supportsFullScreen()?this.us("exitFullScreen"):(this.exitFullWindow(),this.trigger("fullscreenchange")),this},s.enterFullWindow=function(){this.isFullWindow=!0,this.docOrigOverflow=Ii.documentElement.style.overflow,te(Ii,"keydown",ce(this,this.fullWindowOnEscKey)),Ii.documentElement.style.overflow="hidden",cs(Ii.body,"vjs-full-window"),this.trigger("enterFullWindow")},s.fullWindowOnEscKey=function(t){27===t.keyCode&&(!0===this.isFullscreen()?this.exitFullscreen():this.exitFullWindow())},s.exitFullWindow=function(){this.isFullWindow=!1,ie(Ii,"keydown",this.fullWindowOnEscKey),Ii.documentElement.style.overflow=this.docOrigOverflow,ls(Ii.body,"vjs-full-window"),this.trigger("exitFullWindow")},s.canPlayType=function(t){for(var i,s=0,e=this.h.techOrder;s<e.length;s++){var n=le(e[s]),r=Yr.getTech(n);if(r||(r=fe.getComponent(n)),r){if(r.isSupported()&&(i=r.canPlayType(t)))return i}else qi.error('The "'+n+'" tech is undefined. Skipped browser support check for that tech.')}return""},s.selectSource=function(t){var i,s=this,e=this.h.techOrder.map(le).map((function(t){return[t,Yr.getTech(t)||fe.getComponent(t)]})).filter((function(t){var i=t[0],s=t[1];return s?s.isSupported():(qi.error('The "'+i+'" tech is undefined. Skipped browser support check for that tech.'),!1)})),n=function(t,i,s){var e;return t.some((function(t){return i.some((function(i){if(e=s(t,i))return!0}))})),e},r=function(t,i){var e=t[0];if(t[1].canPlaySource(i,s.h[e.toLowerCase()]))return{source:i,tech:e}};return(this.h.sourceOrder?n(t,e,(i=r,function(t,s){return i(s,t)})):n(e,t,r))||!1},s.src=function(t){if(void 0===t)return this.Zi("src");var i=Yr.getTech(this.Ni);return i||(i=fe.getComponent(this.Ni)),Array.isArray(t)?this.ls(t):"string"==typeof t?this.src({src:t}):t instanceof _&&(t.type&&!i.canPlaySource(t,this.h[this.Ni.toLowerCase()])?this.ls([t]):(this.pi.sources=null,this.pi.source=t,this.pi.src=t.src,this.Bi=t.type||"",this.ready((function(){i.prototype.hasOwnProperty("setSource")?this.us("setSource",t):this.us("src",t.src),"auto"===this.h.preload&&this.load(),this.h.autoplay&&this.play()}),!0))),this},s.ls=function(t){var i=this.selectSource(t);i?(i.tech===this.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())},s.load=function(){return this.us("load"),this},s.reset=function(){return this._t(le(this.h.techOrder[0]),null),this.us("reset"),this},s.currentSources=function(){var t=this.currentSource(),i=[];return 0!==_.keys(t).length&&i.push(t),this.pi.sources||i},s.currentSource=function(){var t={},i=this.currentSrc();return i&&(t.src=i),this.pi.source||t},s.currentSrc=function(){return this.Zi("currentSrc")||this.pi.src||""},s.currentType=function(){return this.Bi||""},s.preload=function(t){return void 0!==t?(this.us("setPreload",t),this.h.preload=t,this):this.Zi("preload")},s.autoplay=function(t){return void 0!==t?(this.us("setAutoplay",t),this.h.autoplay=t,this):this.Zi("autoplay",t)},s.playsinline=function(t){return void 0!==t?(this.us("setPlaysinline",t),this.h.playsinline=t,this):this.Zi("playsinline")},s.loop=function(t){return void 0!==t?(this.us("setLoop",t),this.h.loop=t,this):this.Zi("loop")},s.poster=function(t){return void 0===t?this.mi:(t||(t=""),this.mi=t,this.us("setPoster",t),this.trigger("posterchange"),this)},s.Yi=function(){!this.mi&&this.H&&this.H.poster&&(this.mi=this.H.poster()||"",this.trigger("posterchange"))},s.controls=function(t){return void 0!==t?(t=!!t,this.gi!==t&&(this.gi=t,this.usingNativeControls()&&this.us("setControls",t),t?(this.removeClass("vjs-controls-disabled"),this.addClass("vjs-controls-enabled"),this.trigger("controlsenabled"),this.usingNativeControls()||this.ts()):(this.removeClass("vjs-controls-enabled"),this.addClass("vjs-controls-disabled"),this.trigger("controlsdisabled"),this.usingNativeControls()||this.ss())),this):!!this.gi},s.usingNativeControls=function(t){return void 0!==t?(t=!!t,this.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},s.error=function(t){return void 0===t?this.lt||null:null===t?(this.lt=t,this.removeClass("vjs-error"),this.errorDisplay&&this.errorDisplay.close(),this):(this.lt=new Ae(t),this.addClass("vjs-error"),qi.error("(CODE:"+this.lt.code+" "+Ae.errorTypes[this.lt.code]+")",this.lt.message,this.lt),this.trigger("error"),this)},s.reportUserActivity=function(t){this.fs=!0},s.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},s.wi=function(){var t,i,s,e,n=ce(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)},s.playbackRate=function(t){return void 0!==t?(this.us("setPlaybackRate",t),this):this.H&&this.H.featuresPlaybackRate?this.Zi("playbackRate"):1},s.isAudio=function(t){return void 0!==t?(this.ps=!!t,this):!!this.ps},s.videoTracks=function(){return this.H?this.H.videoTracks():(this.rt=this.rt||new Gr,this.rt)},s.audioTracks=function(){return this.H?this.H.audioTracks():(this.ht=this.ht||new Jr,this.ht)},s.textTracks=function(){if(this.H)return this.H.textTracks()},s.remoteTextTracks=function(){if(this.H)return this.H.remoteTextTracks()},s.remoteTextTrackEls=function(){if(this.H)return this.H.remoteTextTrackEls()},s.addTextTrack=function(t,i,s){if(this.H)return this.H.addTextTrack(t,i,s)},s.addRemoteTextTrack=function(t,i){if(this.H)return this.H.addRemoteTextTrack(t,i)},s.removeRemoteTextTrack=function(t){var i=(void 0===t?{}:t).track,s=void 0===i?arguments[0]:i;if(this.H)return this.H.removeRemoteTextTrack(s)},s.getVideoPlaybackQuality=function(){return this.Zi("getVideoPlaybackQuality")},s.videoWidth=function(){return this.H&&this.H.videoWidth&&this.H.videoWidth()||0},s.videoHeight=function(){return this.H&&this.H.videoHeight&&this.H.videoHeight()||0},s.language=function(t){return void 0===t?this.gs:(this.gs!==String(t).toLowerCase()&&(this.gs=String(t).toLowerCase(),void 0!==this.v&&this.trigger("languagechange")),this)},s.languages=function(){return de(i.prototype.h.languages,this.vi)},s.toJSON=function(){var t=de(this.h),i=t.tracks;t.tracks=[];for(var s=0;s<i.length;s++){var e=i[s];(e=de(e)).player=void 0,t.tracks[s]=e}return t},s.createModal=function(t,i){var s=this;(i=i||{}).content=t||"";var e=new Fe(this,i);return this.addChild(e),e.on("dispose",(function(){s.removeChild(e)})),e.open()},i.getTagSettings=function(t){var i={sources:[],tracks:[]},s=vs(t),e=s["data-setup"];if(us(t,"vjs-fluid")&&(s.fluid=!0),null!==e){var n=Pe(e||"{}"),r=n[0],h=n[1];r&&qi.error(r),Ui(s,h)}if(Ui(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(vs(c)):"track"===l&&i.tracks.push(vs(c))}return i},s.bi=function(){var t=Ii.createElement("i");return!("flexBasis"in t.style||"webkitFlexBasis"in t.style||"mozFlexBasis"in t.style||"msFlexBasis"in t.style||"msFlexOrder"in t.style)},i}(fe);_o.players={};var xo=p.navigator;_o.prototype.h={techOrder:["html5","flash"],html5:{},flash:{},defaultVolume:0,inactivityTimeout:2e3,playbackRates:[],children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","controlBar","errorDisplay","textTrackSettings"],language:xo&&(xo.languages&&xo.languages[0]||xo.userLanguage||xo.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",fullscreenOptions:{navigationUI:"hide"}},["ended","seeking","seekable","networkState","readyState"].forEach((function(t){_o.prototype[t]=function(){return this.Zi(t)}})),ko.forEach((function(t){_o.prototype["handleTech"+le(t)+"_"]=function(){return this.trigger(t)}})),fe.registerComponent("Player",_o);var Co,So,jo=function(t){function i(s){var e;void 0===s&&(s={});var n=de(s,{kind:Re[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(zs)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return _.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||pe(e)}return ge(i,t),i}(Ue),To=function(t){function i(s){var e;void 0===s&&(s={});var n=de(s,{kind:$e[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(zs)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return _.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||pe(e)}return ge(i,t),i}(Ue);function Mo(t,i,s){var e;if("string"==typeof t){if(0===t.indexOf("#")&&(t=t.slice(1)),Mo.getPlayers()[t])return i&&qi.warn('Player "'+t+'" is already initialised. Options will not be applied.'),s&&Mo.getPlayers()[t].ready(s),Mo.getPlayers()[t];e=function(t){return 0===t.indexOf("#")&&(t=t.slice(1)),Ii.getElementById(t)}(t)}else e=t;if(!e||!e.nodeName)throw new w("The element or ID supplied is not valid. (videojs)");if(e.player||_o.players[e.playerId])return e.player||_o.players[e.playerId];i=i||{},Mo.hooks("beforesetup").forEach((function(t){var s=t(e,de(i));zi(s)&&!Array.isArray(s)?i=de(i,s):qi.error("please return an object in beforesetup hooks")}));var n=new(fe.getComponent("Player"))(e,i,s);return Mo.hooks("setup").forEach((function(t){return t(n)})),n}"undefined"==typeof HTMLVideoElement&&Ki()&&(Ii.createElement("video"),Ii.createElement("audio"),Ii.createElement("track")),Mo.ys={},Mo.hooks=function(t,i){return Mo.ys[t]=Mo.ys[t]||[],i&&(Mo.ys[t]=Mo.ys[t].concat(i)),Mo.ys[t]},Mo.hook=function(t,i){Mo.hooks(t,i)},Mo.removeHook=function(t,i){var s=Mo.hooks(t).indexOf(i);return!(s<=-1)&&(Mo.ys[t]=Mo.ys[t].slice(),Mo.ys[t].splice(s,1),!0)},!0!==p.VIDEOJS_NO_DYNAMIC_STYLE&&Ki()&&((Co=Cs(".vjs-styles-defaults"))||(Co=ae("vjs-styles-defaults"),(So=Cs("head"))&&So.insertBefore(Co,So.firstChild),ue(Co,"\n .video-js {\n width: 300px;\n height: 150px;\n }\n\n .vjs-fluid {\n padding-top: 56.25%\n }\n "))),oe(1,Mo),Mo.VERSION="5.20.6-opentelly.14",Mo.options=_o.prototype.h,Mo.getPlayers=function(){return _o.players},Mo.players=_o.players,Mo.getComponent=fe.getComponent,Mo.registerComponent=function(t,i){Yr.isTech(i)&&qi.warn("The "+t+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),fe.registerComponent.call(fe,t,i)},Mo.getTech=Yr.getTech,Mo.registerTech=Yr.registerTech,Mo.browser=Xs,Mo.TOUCH_ENABLED=Ws,Mo.extend=function(t,i){void 0===i&&(i={});var s=function(){t.apply(this,arguments)},e={};for(var n in zi(i)?("function"==typeof i.init&&(qi.warn("Constructor logic via init() is deprecated; please use constructor() instead."),i.constructor=i.init),i.constructor!==_.prototype.constructor&&(s=i.constructor),e=i):"function"==typeof i&&(s=i),function(t,i){if("function"!=typeof i&&null!==i)throw new w("Super expression must either be null or a function, not "+typeof i);t.prototype=_.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},Mo.mergeOptions=de,Mo.bind=ce,Mo.plugin=function(t,i){_o.prototype[t]=i},Mo.addLanguage=function(t,i){var s;return t=(""+t).toLowerCase(),Mo.options.languages=de(Mo.options.languages,((s={})[t]=i,s)),Mo.options.languages[t]},Mo.log=qi,Mo.createTimeRange=Mo.createTimeRanges=we,Mo.formatTime=lh,Mo.parseUrl=ze,Mo.isCrossOrigin=Le,Mo.EventTarget=ve,Mo.on=te,Mo.one=ee,Mo.off=ie,Mo.trigger=se,Mo.xhr=Fr,Mo.TextTrack=Vr,Mo.AudioTrack=jo,Mo.VideoTrack=To,Mo.isEl=Zi,Mo.isTextNode=bs,Mo.createEl=is,Mo.hasClass=us,Mo.addClass=cs,Mo.removeClass=ls,Mo.toggleClass=ds,Mo.setAttributes=fs,Mo.getAttributes=vs,Mo.emptyEl=ws,Mo.appendContent=ks,Mo.insertContent=_s,Mo.computedStyle=yh,d(),d();var Ao=10;function Po(t){const i=t.duration;if(j(i)){var s;const i=null==(s=t.source)?void 0:s.streamType;return"live"===i||"dvr"===i}return i===1/0}function Eo(t){return t.scrubbing()?t.getCache().currentTime:t.currentTime()}function No(t){const i=Fo(t);return Po(t)?i.end(i.length-1):i.start(0)}function Io(t){return Fo(t).start(0)}function Bo(t){const i=Fo(t);return i.end(i.length-1)-i.start(0)}function Fo(t){const i=t.seekable;if(i&&i.length)return i;let s=t.duration;return s=isFinite(s)?s:0,new Ft([0,s]).ws()}function Do(t,i){void 0===i&&(i=t);let s=t<0?"-":"";t=x.abs(t);let e=x.floor(t%60),n=x.floor(t/60%60),r=x.floor(t/3600);const h=x.floor(i/60%60),o=x.floor(i/3600);return(j(t)||t===1/0)&&(r=n=e="-"),r=+r>0||o>0?r+":":"",n=((r||h>=10)&&+n<10?"0"+n:n)+":",e=+e<10?"0"+e:e,s+r+n+e}function $o(t){return class extends t{get ks(){var t;return null!=(t=this._s)?t:this._s=Ro(this.player())}dispose(){this._s=void 0,super.dispose()}constructor(...t){super(...t),this._s=void 0}}}function Ro(t){return t.tech({IWillNotUseThisInPlugins:!0}).theoplayer()}function Oo(t){const i=Ro(t),s=()=>{const s=Eo(t);t.toggleClass("theo-at-live",function(t,i){if(Po(t)){let s=t.seekable;return 0===s.length||s.end(s.length-1)-i<Ao}return!1}(i,s)),t.toggleClass("vjs-live",Po(i)),t.toggleClass("theo-dvr",function(t){var i;return"dvr"===Ct(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)}d(),d();var Vo="theo-ad-playing",Uo="theo-dai-ad-playing";function zo(t,i,s){t.toggleClass(Vo,i),t.toggleClass(Uo,i&&s)}function Lo(){this.userActive(!1)}d(),d(),d();var Ho=class{constructor(t,i){this.type=t.type,this.target=i,this.playerEvent=t}},qo=["loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange","resize"],Wo=Mo.getTech("Tech"),Go=Mo.getTech("Html5"),Xo=class extends Wo{xs(){var t;for(const t of qo)this.ks.addEventListener(t,this.Cs);this.ks.addEventListener("error",this.Ss),this.ks.addEventListener("contentprotectionerror",this.Ss),this.ks.addEventListener("sourcechange",this.js),this.ks.addEventListener("loadstart",this.Ts),null==(t=this.ks.presentation)||t.addEventListener("presentationmodechange",this.Ms),this.ks.textTracks.addEventListener("addtrack",this.As),this.ks.textTracks.addEventListener("removetrack",this.Ps),this.ks.textTracks.addEventListener("change",this.Es),this.ks.audioTracks.addEventListener("addtrack",this.Ns),this.ks.audioTracks.addEventListener("removetrack",this.Is),this.ks.audioTracks.addEventListener("change",this.Bs)}Fs(){var t;for(const t of qo)this.ks.removeEventListener(t,this.Cs);this.ks.removeEventListener("error",this.Ss),this.ks.removeEventListener("contentprotectionerror",this.Ss),this.ks.removeEventListener("sourcechange",this.js),this.ks.removeEventListener("loadstart",this.Ts),null==(t=this.ks.presentation)||t.removeEventListener("presentationmodechange",this.Ms),this.ks.textTracks.removeEventListener("addtrack",this.As),this.ks.textTracks.removeEventListener("removetrack",this.Ps),this.ks.textTracks.removeEventListener("change",this.Es),this.ks.audioTracks.removeEventListener("addtrack",this.Ns),this.ks.audioTracks.removeEventListener("removetrack",this.Is),this.ks.audioTracks.removeEventListener("change",this.Bs)}Ds(t){this.trigger(new Ho(t,this))}createEl(){let t=this.h,i=t.player;if(!i)throw new b(this.localize('Missing required tech option "player"'));let s=i.element;return Mo.setAttributes(s,{id:t.techId}),s}theoplayer(){return this.ks}addTextTrack(t,i,s){return super.addTextTrack(t,i,s)}buffered(){return this.ks.buffered}played(){return this.ks.played}reset(){this.ks.stop()}play(){this.ks.play()}pause(){this.ks.pause()}paused(){return this.ks.paused}currentTime(){return this.ks.currentTime}setCurrentTime(t){this.ks.currentTime=t}duration(){return this.ks.duration}volume(){return this.ks.volume}setVolume(t){this.ks.volume=t}muted(){return this.ks.muted}setMuted(t){this.ks.muted=t}src(t){if(void 0!==t)this.setSrc(t);else{if(this.ks.src)return this.ks.src;if(this.ks.source){if(!hi(this.ks.source.ads))return this.ks.source.ads[0].sources;if(Dt(this.ks.source))return"This source is managed by the Verizon Media integration extension.";if(Bt(this.ks.source))return"This source is managed by the DAI integration extension.";if(Rt(this.ks.source))return"This source is managed by Millicast."}}}setSrc(t){return this.setSource({src:t})}setSource(t){this.lt=null,this.trigger("error")}currentSrc(){return this.ks.src}load(){this.setPreload("auto")}preload(){return this.ks.preload}setPreload(t){this.ks.preload=t}autoplay(){return this.ks.autoplay}setAutoplay(t){this.ks.autoplay=!!t}seeking(){return this.ks.seeking}seekable(){return this.ks.seekable}ended(){return this.ks.ended}playbackRate(){return this.ks.playbackRate}setPlaybackRate(t){this.ks.playbackRate=t}readyState(){return this.ks.readyState}networkState(){return 0}controls(){return!1}videoHeight(){return this.ks.videoHeight}videoWidth(){return this.ks.videoWidth}supportsFullScreen(){return this.ks.presentation.supportsMode(Kt.FULLSCREEN)}enterFullScreen(){this.ks.presentation.requestMode(Kt.FULLSCREEN)}exitFullScreen(){this.ks.presentation.requestMode(Kt.INLINE)}$s(){let t=this.ks.ads;if(t&&t.playing)return!0;let i=this.ks.vr;return!(!i||i.state===Mt.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.ks=null,super.dispose()}static isSupported(){return!0}static canPlayType(){return"maybe"}static canPlaySource(t){return"maybe"}get featuresVolumeControl(){return ki}constructor(t={},i){super(t,i),this.Cs=t=>this.Ds(t),this.Os=!1,this.js=()=>{void 0===this.ks.errorObject&&(this.Ds(new Vt(this.ks.currentTime,this.ks.readyState)),this.Ds(new Ci),this.Ds(new zt(this.ks.duration)))},this.Ts=()=>{this.Ds(new Tt(this.ks.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.Is=t=>{this.audioTracks().it(t.track)},this.Es=()=>{let t=this.textTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Bs=()=>{let t=this.audioTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Ms=()=>{if(!this.supportsFullScreen())return;let t=this.Os,i=this.ks.presentation.currentMode===Kt.FULLSCREEN;t!==i&&(this.Os=i,this.trigger("fullscreenchange",{isFullscreen:i,nativeIOSFullscreen:!0}))},this.Ss=()=>{const t=this.ks.errorObject,i=t&<(t.code)||-1,s=t&&t.message||"An unknown error occurred.";this.error({code:i,message:this.localize(s)})},this.ks=this.h.player,this.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()}};Xo.prototype.featuresFullscreenResize=Go.prototype.featuresFullscreenResize,Xo.prototype.featuresPlaybackRate=Go.prototype.featuresPlaybackRate,Xo.prototype.featuresProgressEvents=!0,Xo.prototype.featuresTimeupdateEvents=!0,Xo.prototype.featuresNativeTextTracks=!0,Mo.registerTech("THEOplayer",Xo),d(),d(),d(),d();var Jo=class{constructor(t){this.Vs=t=>{oi(this.Us,"theo-mobile-button-hover"),t.stopImmediatePropagation()},this.zs=t=>{ui(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)}};d(),d(),d(),d();var Qo=Mo.getComponent("Menu"),Yo=class extends($o(Qo)){get Hs(){return this.player().el()}qs(){oi(this.Hs,"theo-menu-opened")}Ws(){ui(this.Hs,"theo-menu-opened")}constructor(t,i){super(t,i)}};d();var Ko=Mo.getComponent("MenuItem"),Zo=class extends($o(Ko)){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(){$t.Ys.Qs&&(this.el().removeEventListener("touchstart",this.Vs),this.el().removeEventListener("touchend",this.zs)),super.dispose()}constructor(t,i,s){super(t,xi({selectable:!0},i)),this.Xs=!1,this.Vs=t=>{oi(this.el(),"theo-mobile-menu-item-hover"),t.stopImmediatePropagation()},this.zs=t=>{ui(this.el(),"theo-mobile-menu-item-hover")},this.Gs=s,$t.Ys.Qs&&(this.el().addEventListener("touchstart",this.Vs),this.el().addEventListener("touchend",this.zs))}};d();var ta=Mo.getComponent("ClickableComponent"),ia=class extends ta{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)}},sa=class extends Yo{get menuHeader(){return this.se}get menuItems(){return this.children()}addMenuItem(t){t=xi({playerOptions:this.h.playerOptions},t);let i=new Zo(this.player(),t,this);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}addSubMenuItem(t){t=xi({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();$t.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(),$t.Ys.Qs&&(this.el().removeAttribute("style"),this.contentEl().removeAttribute("style"))}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=this.contentEl();oi(i,"theo-menu-content");let s=new ia(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)}},ea=class extends sa{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(){ui(this.ye,"vjs-hidden"),this.ye.style.opacity="1",super.show()}be(){oi(this.ye,"vjs-hidden")}qs(){this.ce&&this.ce.qs(),super.qs()}Ws(){this.ce&&this.ce.Ws(),super.Ws(),oi(this.ye,"vjs-hidden")}he(){if(this.ce&&this.ce.we)return this.ce.we.ye}ae(t,i){if(i.length>0){let t=i[0].height,s=i[0].width;this.le.ke.style.height=t+"px",this.le.ke.style.width=s+"px"}super.ae(t,i)}constructor(t,i){super(t,i)}};d();var na=class{get ke(){return this.Us}get we(){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.we.focus(),$t.Ys.Qs)s.be();else{const t="translateX(100%)",e="translateX(-100%)",n=vi("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(){ai((()=>{ui(this.Us,"theo-no-transition"),ui(this._e.ye,"theo-no-transition")}))}xe(){oi(this.Us,"theo-no-transition"),oi(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()}};d(),d();var ra=class extends ea{get ye(){return this.el()}get parentMenu(){return this.je}ee(t,i){let s=new ha(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}},ha=class extends Zo{get subMenu(){return this.Ae}handleClick(t){this.parentMenu.ve(this.subMenu)}constructor(t,i,s){super(t,xi({selectable:!1},i),s),this.Ae=new ra(t,i,s)}},oa=class extends ea{get menuButton(){return this.Pe}createEl(){let t=Mo.createEl("div",{className:this.buildCSSClass()});return this.Ee=super.createEl(),this.Ee.className=super.buildCSSClass(),oi(this.Ee,"theo-menu-content-animatable"),t.appendChild(this.Ee),this.ce=new na(this),t.appendChild(this.ce.ke),t}buildCSSClass(){return"theo-menu-animatable "+super.buildCSSClass()}ee(t,i){let s=new ha(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=S(getComputedStyle(this.el()).fontSize);U(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}};d();var aa=class{set Ie(t){this.Be.innerHTML=this.Fe.localize(t),this.De(),this.$e(),pi(this.Fe.el())}get Ie(){return this.Be.textContent||""}Re(){this.Fe.off("mouseover",this.$e),this.Fe.off("mouseout",this.De),this.Fe.off("dispose",this.Oe),ii(this.Be)}constructor(t,i){this.$e=()=>{ui(this.Be,"vjs-hidden");let t=this.Fe.player().contentEl().getClientRects(),i=t.length>0?t[0]:void 0,s=S(getComputedStyle(this.Be).fontSize);U(this.Be,this.Fe.el(),i,s)},this.De=()=>{oi(this.Be,"vjs-hidden")},this.Oe=()=>this.Re(),this.Fe=t,pi(t.el()),gi(t.el()),this.Be=h.createElement("span"),this.Be.innerHTML=this.Fe.localize(i),this.Be.className="theo-button-tooltip vjs-hidden",this.Be.setAttribute("aria-hidden","true"),this.Fe.el().appendChild(this.Be),this.Fe.on("mouseover",this.$e),this.Fe.on("mouseout",this.De),this.Fe.on("dispose",this.Oe)}},ua=Mo.getComponent("Button"),ca=class extends($o(ua)){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.Be.Ie=this.controlText()}dispose(){this.player().removeChild(this.Ue),this.Ue.dispose(),this.Be.Re(),this.ks.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;$t.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 oa(t,i,this),this.player().getChild("controlBarMenuContainer").addChild(this.Ue),this.Be=new aa(this,this.controlText()),this.el().setAttribute("aria-haspopup","true"),$t.Ys.Je?(this.on(h,"touchend",this.Ge),new Jo(this.el())):(this.on(h,"click",this.Ge),this.on(h,"keydown",this.Xe),wi&&this.on(h,wi.Qe,this.closeMenu)),this.ks.addEventListener("seeking",this.We),this.on(this.Ue,"menuchange",this.qe),this.on(t,"languagechange",this.te),this.qe()}},la=Mo.getComponent("Component"),da=class extends(Mo.getComponent("ControlBar")){addMenuButton(t){t=xi({playerOptions:this.h.playerOptions},t);let i=new ca(this.player(),t);return this.addChild(i),i}removeMenuButton(t){this.removeChild(t)}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-secondary-color vjs-control-bar "+super.buildCSSClass()}constructor(t,i){super(t,i),this.addChild("THEOControlBarShadow",void 0,0)}};Mo.registerComponent("THEOControlBarShadow",class extends la{createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-tertiary-color theo-control-bar-shadow"}}),d(),d();var fa=Mo.getComponent("VolumeBar"),va=class extends fa{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}};d();var pa=Mo.getComponent("VolumeControl"),ma=class extends pa{constructor(t,i){super(t,i),this.Ze=new va(t,{Ke:this}),this.addChild(this.Ze)}};ma.prototype.h=xi({},pa.prototype.h,{children:[]}),Mo.registerComponent("VolumeControl",ma);var ga=class extends($o(da)){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.ks.textTrackStyle.marginBottom=void 0)}dn(){const t=this.el().getBoundingClientRect().height;this.ks.textTrackStyle.marginBottom!==t&&(this.ks.textTrackStyle.marginBottom=t)}dispose(){c(this.hn),this.hn=0,this.vn.fn(ci.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 mi(this.el()),this.vn.yn(ci.pn,this.mn),this.vn.bn(!0)}};ga.prototype.h=xi({},da.prototype.h,{children:["progressControl","playToggle","muteToggle","volumeControl","currentTimeDisplay","timeDivider","durationDisplay","liveDisplay","remainingTimeDisplay","customControlSpacer","activeQualityLabel","vrButton","descriptionsButton","subtitlesButton","chromecastButton","airplayButton","multiViewButton","audioTrackButton","SettingsButton","fullscreenToggle"]}),Mo.registerComponent("ControlBar",ga),d();var ya=class extends da{buildCSSClass(){return"theo-top-controlbar "+super.buildCSSClass()}constructor(t,i){super(t,i),t.topControlBar=this}};ya.prototype.h=xi({},da.prototype.h,{children:[]}),Mo.registerComponent("TopControlBar",ya),d();var ba=Mo.getComponent("CurrentTimeDisplay"),wa=class extends($o(ba)){updateContent(){const t=Eo(this.player()),i=this.ks,s=Io(i),e=this.localize("Current Time"),n=Do(x.max(0,t-s),Bo(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)}};Mo.registerComponent("CurrentTimeDisplay",wa),d();var ka=Mo.getComponent("DurationDisplay"),_a=class extends($o(ka)){updateContent(){const t=this.ks,i=j(t.duration)?NaN:Bo(t),s=t.clip.endTime-t.clip.startTime,e=x.min(i,s)||0;if(this.ct!==e){this.ct=e;const t=this.localize("Duration Time"),i=Do(e);this.S.innerHTML='<span class="vjs-control-text">'+t+"</span> "+i}}dispose(){var t;null==(t=this.ks)||t.clip.removeEventListener("change",this.wn),super.dispose()}constructor(t,i){var s;super(t,i),this.wn=()=>this.updateContent(),this.off(t,"durationchange",this.updateContent),this.on(t,"durationchange",this.updateContent),this.off(t,"timeupdate",this.updateContent),this.on(t,"timeupdate",this.updateContent),this.off(t,"emptied",this.updateContent),this.on(t,"emptied",this.updateContent),null==(s=this.ks)||s.clip.addEventListener("change",this.wn)}};Mo.registerComponent("DurationDisplay",_a),d();var xa=Mo.getComponent("Button"),Ca=class extends($o(xa)){buildCSSClass(){return"theo-live-control "+super.buildCSSClass()}createEl(){let t=super.createEl("button",{},{"aria-live":"off"});return this.kn=Mo.createEl("span",{className:"theo-live-control-indicator"}),ei(t,this.kn),t}createControlTextEl(t){let i=super.createControlTextEl(t);return Mo.removeClass(i,"vjs-control-text"),Mo.addClass(i,"theo-live-control-text"),i}handleClick(){var t;const i=this.ks;if(void 0!==(null==(t=i.hesp)?void 0:t.manifest))i.hesp.goLive();else{const t=this.player();t.currentTime(No(i)),t.play()}}_n(){Po(this.ks)?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),$t.Ys.Je&&new Jo(this.el())}};Mo.registerComponent("LiveDisplay",Ca),d();var Sa=Mo.getComponent("LoadingSpinner");Mo.registerComponent("LoadingSpinner",class extends Sa{buildCSSClass(){return"theo-secondary-color vjs-loading-spinner "+super.buildCSSClass()}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=Mo.createEl("div",{className:"theo-loading-spinner-rotator"}),s=Mo.createEl("div",{className:"theo-loading-spinner-circle-left"}),e=Mo.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)}}),d();var ja=Mo.getComponent("LoadProgressBar"),Ta=class extends($o(ja)){update(){let t=this.ks,i=Ft.xn(Fo(t)),s=i.Cn(0),e=Ft.xn(t.buffered).Sn(i),n=i.jn(0)-s,r=e.U&&e.jn(e.U-1)||0;r=x.max(0,r-s);let o=this.el(),a=this.Tn;o.style.width=Ma(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=Ma(i-s,r),u.style.width=Ma(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 Ma(t,i){let s=t/i||0;return 100*(s>=1?1:s)+"%"}Mo.registerComponent("LoadProgressBar",Ta),d();var Aa=Mo.getComponent("MouseTimeDisplay"),Pa=class extends($o(Aa)){handleMouseMove(t){let i=t,s=this.ks,e=Io(s)+this.calculateDistance(i)*Bo(s),n=i.pageX-O(this.el().parentNode).left;this.update(e,n+"px")}handleTouchMove(t){let i=t,s=this.ks,e=Io(s)+this.calculateDistance(i)*Bo(s),n=i.touches[0].pageX-O(this.el().parentNode).left;this.update(e,n+"px")}createEl(){let t=super.createEl();return this.Mn=Mo.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&&(f(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=S(getComputedStyle(t).fontSize);U(this.tooltip,this.el(),s,e)}}Pn(t){const i=this.ks,s=t-No(i);return Do(Po(i)?x.min(s,0):s,Bo(i))}dispose(){var t;this.ks.removeEventListener("dimensionchange",this.Nn),null==(t=this.ks.presentation)||t.removeEventListener("presentationmodechange",this.Nn),super.dispose()}constructor(t,i){var s;(super(t,i),this.An=NaN,this.Nn=()=>{let t=Eo(this.player());const i=this.ks;let s=(t-Io(i))/Bo(i)||0;s=Yt(s,0,1),this.update(t,100*s+"%")},this.keepTooltipsInside&&(Mo.addClass(this.tooltip,"theo-secondary-color"),this.tooltip.appendChild(this.Mn)),this.on(t,"ready",(()=>{this.on(t.controlBar.progressControl,"mouseenter",this.handleMouseMove)})),Ot.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.ks.addEventListener("dimensionchange",this.Nn),null==(s=this.ks.presentation)||s.addEventListener("presentationmodechange",this.Nn),this.on(t,"ready",(()=>{this.on(t.controlBar.progressControl,"touchstart",this.handleTouchMove),this.on(t.controlBar.progressControl,"touchmove",Jt((t=>this.handleTouchMove(t)),25)),this.Nn()})))}};Mo.registerComponent("MouseTimeDisplay",Pa),d();var Ea=Mo.getComponent("PlayProgressBar"),Na=class extends($o(Ea)){updateDataAttr(){let t=Eo(this.player());this.el().setAttribute("data-current-time",this.Pn(t))}Pn(t){let i=this.ks;return Do(t-No(i),Bo(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)}};Mo.registerComponent("PlayProgressBar",Na),d();var Ia=Mo.getComponent("RemainingTimeDisplay"),Ba=class extends($o(Ia)){updateContent(){const t=this.ks,i=Bo(t);if(i){const s=Fo(t).end(0),e=this.localize("Remaining Time"),n=Do(x.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)}};Mo.registerComponent("RemainingTimeDisplay",Ba),d(),d();var Fa=class{get ks(){return this._s||(this._s=this.In.tech({IWillNotUseThisInPlugins:!0}).theoplayer()),this._s}Bn(t){if(t.kind!==bt.Fn)return;if(0===this.ks.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 Da(s,this.ks,n);this.On.push(r),this.Vn.appendChild(r.ke)}t.addEventListener("cuechange",this.Un),this.Un()}zn(){this.ks.addEventListener("loadedmetadata",this.Ln),this.ks.addEventListener("loadeddata",this.Ln),this.ks.addEventListener("sourcechange",this.Ln),this.ks.textTracks.addEventListener("addtrack",this.Hn),this.ks.textTracks.addEventListener("removetrack",this.qn),this.ks.textTracks.addEventListener("change",this.Ln)}Wn(){this.ks.removeEventListener("loadedmetadata",this.Ln),this.ks.removeEventListener("loadeddata",this.Ln),this.ks.removeEventListener("sourcechange",this.Ln),this.ks.textTracks.removeEventListener("addtrack",this.Hn),this.ks.textTracks.removeEventListener("removetrack",this.qn),this.ks.textTracks.removeEventListener("change",this.Ln)}Gn(){if(!(this.ks.readyState<St.Xn))for(let t of this.ks.textTracks)if(t.kind===bt.Fn&&t.mode===gt.Jn&&t.cues.length>0&&t.readyState!==ft.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.In=i,this.On=[],this._s=void 0,this.Hn=t=>{let i=t.track;i.kind===bt.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===bt.Fn&&(i.removeEventListener("addcue",this.Ln),i.removeEventListener("removecue",this.Ln),i.removeEventListener("readystatechange",this.Ln)),this.Ln()},this.er=t=>{let i=this.ks,s=function(t,i){let s,e,n=O(t),r=t.offsetWidth,h=t.offsetHeight,o=n.top,a=n.left;!function(t){return void 0!==t.changedTouches}(i)?(e=i.pageX,s=i.pageY):(e=i.changedTouches[0].pageX,s=i.changedTouches[0].pageY);let u=Yt((o-s+h)/h,0,1),c=Yt((e-a)/r,0,1);return{x:c,y:u}}(this.Vn,t),e=Io(i)+s.x*Bo(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.Bn(t))},this.Un=()=>{var t,i,s;const e=null==(i=this.Dn)||null==(t=i.activeCues)?void 0:t[0],n=D(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 $a,this.In.contentEl().appendChild(this.Rn.ke),this.Vn=h.createElement("div"),oi(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()}},Da=class{get ke(){return this.Us}ur(){oi(this.Us,"theoplayer-chapter-indicator-active")}ar(){ui(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");oi(o,"theoplayer-chapter-indicator");let a=h.createElement("div");oi(a,"theoplayer-chapter-indicator-highlight"),o.appendChild(a),i&&oi(o,"theoplayer-chapter-indicator-discontinuous");let u=x.min(n/e*100,100),c=100-u,l=x.min(r/e*100,c);return o.style.width=l+"%",o.style.left=u+"%",o}Re(){ii(this.Us)}constructor(t,i,s){this.hr=t,this.Us=this.cr(i,s)}},$a=class{be(){this.lr--,0===this.lr&&ui(this.ke,"theoplayer-chapter-hovering")}$n(t){this.dr=t||[],this.dr.length>0&&(this.ke.style.display="")}pr(t){f(this.mr,t.content)}tr(){this.dr=[],f(this.mr,""),this.ke.style.display="none"}ge(){this.lr++,this.lr>0&&oi(this.ke,"theoplayer-chapter-hovering")}Yn(t){for(let i of this.dr)if(Ra(i,t)){this.pr(i);break}}Re(){ii(this.ke)}constructor(){this.dr=[],this.lr=0,this.ke=h.createElement("div"),oi(this.ke,"theoplayer-chaptertitle"),this.ke.style.display="none",this.mr=h.createElement("p"),this.ke.appendChild(this.mr)}};function Ra(t,i){return new Ft([t.startTime,t.endTime]).gr(i)}var Oa=Mo.getComponent("SeekBar"),Va=class extends($o(Oa)){updateAriaAttributes(t){const i=Eo(this.player()),s=this.ks;t.setAttribute("aria-valuenow",(100*this.yr(i)).toFixed(2)),t.setAttribute("aria-valuetext",Do(i-No(s),Bo(s)))}getPercent(){return this.yr(this.player().currentTime())}handleMouseMove(t){if(this.ks&&this.ks.ads&&this.ks.ads.playing)return;const i=this.ks;let s=Io(i)+this.calculateDistance(t)*Bo(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.ks,s=(t-Io(i))/Bo(i);return Yt(s,0,1)}dispose(){this.Vn.Re(),z(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 Fa(this.el(),t)}};Mo.registerComponent("SeekBar",Va),d();var Ua=Mo.getComponent("ProgressControl");$t.Ys.Qs&&Mo.registerComponent("ProgressControl",class extends Ua{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"])}}),d();var za=Mo.getComponent("TooltipProgressBar"),La=class extends($o(za)){updateDataAttr(){let t=Eo(this.player()),i=this.Pn(t);this.el().setAttribute("data-current-time",i),this.tooltip.innerHTML=i}Pn(t){const i=this.ks;return Do(t-No(i),Bo(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 Ha(t){for(const i of t)if(i.enabled)return i}function qa(t){if(t)return t.label&&""!==t.label?{name:t.label,hd:!1}:{name:Wa(t),description:Ga(t),hd:!!t.height&&t.height>=720}}function Wa(t){return t.height?t.height+"p":t.bandwidth?Ga(t):""}function Ga(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":""}Mo.registerComponent("TooltipProgressBar",La),d(),d(),d(),d(),d();var Xa=class{get br(){return this.wr}set br(t){let i=this.wr;for(let s=i.length-1;s>=0;s--){let e=i[s];V(t,e)||this.kr(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)){V(this.wr,t)||this.wr.push(t);let i=this.jr(t)||this.Mr(t);return this.Nr(i),i}this.kr(t)}kr(t){let i=this.jr(t);i&&(this.Cr.removeMenuItem(i),this.Pr(i)),R(this.wr,t)}Re(){const t=[];for(let i of this.wr)t.push(i);for(let i of t)this.kr(i);z(t)}constructor(t){this.wr=[],this.Cr=t}},Ja=class extends Xa{Ir(){return this.Br=h.createElement("span"),this.Br.className="theo-settings-control-menu-item-title",f(this.Br,this.Fr.localize("Quality")),this.Br}Dr(){return this.$r=h.createElement("span"),this.$r.className="theo-settings-control-menu-quality-automatic",f(this.$r,this.Fr.localize("Automatic")),this.$r}Rr(){return this.Or=h.createElement("span"),f(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",f(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.Br),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&&su(t.targetQuality),s=t&&t.activeQuality,e=qa(this.Wr(i||s))||{name:this.Fr.localize("Automatic")};f(this.Or,e.name),li(this.$r,"vjs-hidden",!!i),li(this.Ur,"vjs-hidden",!e.hd)}Nr(t){let i=qa(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=Ha(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=Ya(tu(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=Ya(tu(i.qualities.filter((t=>t.available)))),e=i&&su(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=Ha(this._s.videoTracks),i=t&&su(t.targetQuality),s=this.Wr(i),e=this.Gr;s!==e&&(this.Gr=s,s&&e||this._r(void 0),e&&V(this.br,e)&&this._r(e),i&&this._r(s),this.Hr())},this.te=()=>{f(this.Cr.menuHeader.el(),this.Fr.localize("Quality")),f(this.Br,this.Fr.localize("Quality")),f(this.$r,this.Fr.localize("Automatic")),f(this.Or,this.Fr.localize("Automatic")),f(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.Br=this.Ir(),this.$r=this.Dr(),this.Or=this.Rr(),this.Ur=this.Vr(),this.zr(),f(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()}},Qa=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 Ya(t){let i=[];for(let s of t){let t=s,e=!1;for(let s of i)if(iu(s,t)){s.add(t),e=!0;break}e||i.push(new Qa([t]))}return i}function Ka(t,i){return t&&i?B(t,i):N.Zr}function Za(t,i){return t===i?N.Zr:Ka(t.height,i.height)||Ka(t.width,i.width)||Ka(t.bandwidth,i.bandwidth)}function tu(t){return P(t,Za).reverse()}function iu(t,i){return t.label&&i.label&&t.label===i.label||et(qa(t),qa(i))}function su(t){return Lt(t)?1===t.length?t[0]:void 0:t}function eu(t){return 1===t?"Normal":""+x.round(100*t)/100}d();var nu=class extends Xa{Ir(){return this.Br=h.createElement("span"),this.Br.className="theo-settings-control-menu-item-title",f(this.Br,this.Fr.localize("Speed")),this.Br}zr(){const t=h.createElement("span");return t.className="theo-primary-color theo-settings-control-menu-item-value",this.Lr.el().appendChild(this.Br),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(eu(i));f(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,f(this.sh,this.Fr.localize(eu(t))),t&&this._r(t)},this.te=()=>{f(this.Cr.menuHeader.el(),this.Fr.localize("Speed")),f(this.Br,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.Br=this.Ir(),this.sh=this.zr(),f(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()}};Mo.registerComponent("SettingsButton",class extends ca{createEl(){let t=super.createEl();return this.eh=Mo.createEl("span",{className:"theo-settings-control-label-hd theo-primary-background"}),f(this.eh,this.localize("HD")),t.appendChild(this.eh),t}buildCSSClass(){return"vjs-icon-cog theo-settings-control-button "+super.buildCSSClass()}te(){super.te(),f(this.eh,this.localize("HD")),f(this.menu.menuHeader.el(),this.localize("Settings"))}dispose(){this.qr&&(this.qr.removeEventListener("activequalitychanged",this.Jr),this.qr=void 0),this.ks.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=Ha(this.ks.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)},oi(this.menu.el(),"theo-settings-control-menu"),f(this.menu.menuHeader.el(),t.localize("Settings")),this.controlText("Settings"),this.Be.Ie=this.controlText(),this.oh=this.menu.addSubMenuItem({name:"QualityMenuItem"}),this.rh=new Ja(this.oh,this.ks,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 nu(this.ah,this.ks,t,n),this.ks.videoTracks.addEventListener(["addtrack","removetrack","change"],this.nh),this.nh()}}),d(),d(),d();var ru=class extends Xa{uh(t){let i=t.label;if(i)return i;let s=t.language;if(s){let t=yt(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.kr(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()}},hu=class extends ru{Nr(t){let i=t.Tr,s=this.Fr.localize(this.uh(i));f(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.ks.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=()=>{f(this.Cr.menuHeader.el(),this.Fr.localize("Language"));for(const t of this.Sr)this.Nr(t)},this.ks=i,this.Fr=s,f(this.Cr.menuHeader.el(),this.Fr.localize("Language")),this.Fr.on("languagechange",this.te)}};Mo.registerComponent("audioTrackButton",class extends ca{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 hu(this.menu,this.ks,t),this.controlText("Language"),this.Be.Ie=this.controlText()}}),d(),d();var ou=class extends ru{Er(t){return!!super.Er(t)&&(!t.forced&&xt(t.kind))}Mr(t){let i=super.Mr(t);oi(i.el(),"theo-text-track-menu-item");let s=h.createElement("span");i.wh=s;let e=h.createElement("div");e.className="theo-text-track-menu-item-toggle",i.kh=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));f(i.wh,e),i.el().setAttribute("aria-label",this.Fr.localize("Set the subtitle language to")+" "+e),i.el().setAttribute("role","menuitemcheckbox"),i.selected(s.mode===gt.Jn)}Pr(t){let i=t;i.kh.removeEventListener("click",i.xh),super.Pr(t)}Ar(t){let i=t.Tr;for(let t of this.ks.textTracks)t!==i&&kt(t.kind,i.kind)&&(t.mode=gt.Ch);i.mode!==gt.Jn?i.mode=gt.Jn:i.mode=gt.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=()=>{f(this.Cr.menuHeader.el(),this.Fr.localize("Subtitles"));for(const t of this.Sr)this.Nr(t)},this.ks=i,this.Fr=s,f(this.Cr.menuHeader.el(),s.localize("Subtitles")),this.Fr.on("languagechange",this.te)}};Mo.registerComponent("subtitlesButton",class extends ca{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 ou(this.menu,this.ks,t),this.controlText("Subtitles"),this.Be.Ie=this.controlText()}}),d();var au=Mo.getComponent("playToggle"),uu=class extends($o(au)){handleClick(t){this.ks.muted||this.ks.prepareWithUserAction(),super.handleClick(t)}handlePlay(t){super.handlePlay(t),this.controlText("Pause"),this.Be.Ie=this.controlText()}handlePause(t){this.ks.ended||(super.handlePause(t),this.controlText("Play"),this.Be.Ie=this.controlText())}te(){this.Be.Ie=this.controlText()}dispose(){this.Be.Re(),this.ks.removeEventListener("ended",this.Sh),super.dispose()}constructor(t,i){super(t,i),this.Sh=()=>{this.controlText("Replay"),this.Be.Ie=this.controlText()},this.controlText("Play"),this.Be=new aa(this,this.controlText()),this.ks.addEventListener("ended",this.Sh),this.on(t,"languagechange",this.te),$t.Ys.Je&&new Jo(this.el())}};Mo.registerComponent("playToggle",uu),d();var cu=Mo.getComponent("fullscreenToggle"),lu=class extends($o(cu)){handleClick(t){this.ks.prepareWithUserAction(),super.handleClick(t)}handleFullscreenChange(t){super.handleFullscreenChange(t),this.updateContent()}updateContent(){const t=this.player().isFullscreen()?"Exit fullscreen":"Fullscreen";this.controlText(t),this.Be.Ie=this.controlText()}dispose(){this.Be.Re(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Fullscreen"),this.Be=new aa(this,this.controlText()),$t.Ys.Je&&new Jo(this.el()),this.on(t,"languagechange",this.updateContent)}};Mo.registerComponent("fullscreenToggle",lu),d();var du=Mo.getComponent("muteToggle"),fu=class extends($o(du)){handleClick(t){this.ks.muted&&!this.ks.paused&&this.ks.prepareWithUserAction(),super.handleClick(t)}update(t){super.update(t),this.te()}te(){const t=this.player().muted()?"Unmute":"Mute";this.controlText(t),this.Be.Ie=this.controlText()}dispose(){this.Be.Re(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Mute"),this.Be=new aa(this,this.controlText()),$t.Ys.Je&&new Jo(this.el()),this.on(t,"languagechange",this.te),bi&&(this.removeClass("vjs-hidden"),this.on(t,"loadstart",(()=>{this.removeClass("vjs-hidden")})))}};Mo.registerComponent("muteToggle",fu),d();var vu=Mo.getComponent("BigPlayButton"),pu="theo-play-svg-circle",mu='<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="'+pu+'" 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>',gu=class extends($o(vu)){createEl(){let t=super.createEl(),i=Mo.createEl("div",{className:"theo-big-play-button-svg-container"});return i.innerHTML=mu,t.appendChild(i),t}buildCSSClass(){return"theo-primary-color "+super.buildCSSClass()}handleClick(t){this.ks.muted||this.ks.prepareWithUserAction(),super.handleClick(t),void 0!==this.ks.vr&&"unavailable"!==this.ks.vr.state&&(this.ks.vr.useDeviceMotionControls=!0)}};Mo.registerComponent("BigPlayButton",gu),d();var yu=/^([^#]*)#xywh=(\d+),(\d+),(\d+),(\d+)\s*$/;Mo.registerComponent("MouseTimeDisplay",class extends Pa{jh(t){const i=t.track;"metadata"===i.kind&&"thumbnails"===i.label&&void 0===this.Th&&(this.Th=i,this.Mh=i.src?$t.Ah(i.src).href:void 0,this.Th.addEventListener(["addcue","removecue"],this.Ph),this.Eh())}Nh(t){t.track===this.Th&&this.Ih()}createEl(){const t=super.createEl();return this.Bh=Mo.createEl("img",{className:"theo-time-tooltip-thumbnail"}),this.Fh=Mo.createEl("canvas",{className:"theo-time-tooltip-thumbnail"}),t}update(t,i){super.update(t,i),this.keepTooltipsInside&&this.Dh(t)}Dh(t){let i;if(this.Th&&this.Th.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.Th.cues,t);i=s&&s.content}if(i===this.$h)return;if(this.$h=i,Mo.toggleClass(this.el(),"theo-time-tooltip-has-thumbnail",!!i),!i)return void this.Rh();const s=i.match(yu);if(s){let[,t,i,e,n,r]=s;t=this.Oh(t);const h={Vh:+i,Uh:+e,ji:+n,Ti:+r};this.zh(t,h)}else{const t=this.Oh(i);this.zh(t)}}Eh(){j(this.An)||this.Dh(this.An)}Oh(t){return this.Th&&this.Mh?$t.Ah(t,this.Mh).href:t}zh(t,i){this.Bh&&(this.Bh.src!==t?(this.Bh.onload=()=>{this.Lh(i)},this.Bh.src="",this.Bh.src=t):this.Lh(i))}Lh(t){if(!this.Fh||!this.Bh)return;const i=this.Fh.getContext("2d");i&&(null!=t||(t={Vh:0,Uh:0,ji:this.Bh.naturalWidth,Ti:this.Bh.naturalHeight}),this.Fh.width=t.ji,this.Fh.height=t.Ti,i.drawImage(this.Bh,t.Vh,t.Uh,t.ji,t.Ti,0,0,t.ji,t.Ti),this.Hh(this.Fh))}Hh(t){this.qh||(ei(this.tooltip,t),this.qh=t),this.En()}Rh(){this.qh&&(this.tooltip.removeChild(this.qh),this.qh=void 0,this.En())}Ih(){void 0!==this.Th&&(this.Th.removeEventListener(["addcue","removecue"],this.Ph),this.Th=void 0),this.Mh=void 0,this.Rh(),this.$h=void 0}dispose(){this.Ih(),super.dispose()}constructor(t,i){super(t,i),this.qh=void 0,this.Th=void 0,this.Mh=void 0,this.Wh=t=>this.jh(t),this.Gh=t=>this.Nh(t),this.Ph=t=>this.Eh(),this.showThumbnails=()=>{this.qh&&this.qh.hidden&&(this.qh.hidden=!1,this.En())},this.hideThumbnails=()=>{!this.qh||this.qh.hidden||this.player().scrubbing()||(this.qh.hidden=!0,this.En())},this.on(this.player().textTracks(),"addtrack",this.Wh),this.on(this.player().textTracks(),"removetrack",this.Gh),Ot.Qs&&(this.on(t,"seeking",this.showThumbnails),this.on(t,"seeked",this.hideThumbnails))}}),d();var bu=Mo.getComponent("VolumeLevel");Mo.registerComponent("VolumeLevel",class extends bu{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-volume-level "+super.buildCSSClass()}}),d(),d();var wu=Mo.getComponent("Component"),ku=class extends wu{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-menu-container "+super.buildCSSClass()}};ku.prototype.h=xi({},ku.prototype.h,{children:[]}),Mo.registerComponent("controlBarMenuContainer",ku);var _u=Mo.getComponent("Player"),xu=class extends _u{dispose(){const t=this.el(),i=this.contentEl(),s=t.parentNode,e=t.nextSibling;super.dispose(),ii(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)}};xu.prototype.h=xi({},_u.prototype.h,{children:["bigPlayButton","AdControlPanel","TopControlBar","mediaLoader","upNextContainer","posterImage","chromecastOverlay","upcomingAdNotificationText","controlBarMenuContainer","controlBar","textTrackDisplay","loadingSpinner","errorDisplay","textTrackSettings","xrCompass"]}),Mo.registerComponent("Player",xu),d(),d();var Cu=Mo.getComponent("Player"),Su=Cu.prototype.es;Cu.prototype.es=function(t){if(!(this.H&&this.H.$s&&this.H.$s()))return Su.call(this,t)};var ju=Cu.prototype.createEl;function Tu(t,i,e,n){let r=xi({controls:!0,playbackRates:[.25,.5,1,1.25,1.5,2]},e);r.controlBar=xi({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&&qt(e.language)&&(r.languages=xi({},r.languages,{[mt]:e.language}),r.language=mt),i.setAttribute("data-vjs-player","");let o=i.getAttribute("style"),a=Mo(t.element,r,n);return a.ready((()=>{Oo(a),function(t,i){if(i){if(i.ads){const s=i=>{const s="adbreakbegin"===i.type,e=i.adBreak.integration===wt.Xh;zo(t,s,e)};i.ads.addEventListener("adbreakbegin",s),i.ads.addEventListener("adbreakend",s)}if(i.verizonMedia){const s=i=>{const s="adbreakbegin"===i.type;zo(t,s,!1)};i.verizonMedia.ads.adBreaks.addEventListener("addadbreak",(t=>{t.adBreak.addEventListener("adbreakbegin",s),t.adBreak.addEventListener("adbreakend",s)}))}i.addEventListener("sourcechange",(()=>{zo(t,!1,!1)}))}}(a,t),function(t){t.on("mouseleave",Lo)}(a)})),i.removeAttribute("data-vjs-player"),o?i.setAttribute("style",o):i.removeAttribute("style"),$t.Ys.Qs&&(oi(i,"theo-mobile"),function(t){let i=s.outerHeight,e=s.outerWidth,n=i>e;n?(ui(t,"theo-mobile-landscape"),oi(t,"theo-mobile-portrait")):(ui(t,"theo-mobile-portrait"),oi(t,"theo-mobile-landscape"))}(i)),function(t){t.on("seeking",(()=>{ri(t.el(),"vjs-ended")&&t.currentTime()!==t.duration()&&t.play()}))}(a),a}Cu.prototype.createEl=function(){let t=ju.call(this),i=Mo.createEl("div");for(i.className="theo-player-wrapper";t.firstChild;)i.appendChild(t.firstChild);return t.appendChild(i),this.S=i,t},d(),d(),d(),d();var Mu=Mo.getComponent("Button");var Au="THEOPiPCloseButton";Mo.registerComponent(Au,class extends Mu{buildCSSClass(){return"theo-close-button theo-pip-close"}handleClick(){this.Qh.Jh()}constructor(t,i){if(super(t,i),this.controlText("Close Picture-in-Picture"),!function(t){return!!t&&Boolean(t.Qh)}(i))throw new b("Invalid Picture-in-picture options.");this.Qh=i.Qh}});var Pu=class extends H{get Yh(){return this.Kh}get Zh(){return this.t.cs()}io(){this.t.yn(G.so,this.eo),this.no||this.t.yn(G.ro,this.ho),this.t.oo.on("languagechange",this.te)}ao(){var t;return"theo-pip-"+(null!=(t=this.uo)?t:"bottom-right")}co(t){let i=this.lo;i&&!this.Zh&&(this.do||this.fo(),this.vo(),oi(i,"theo-pip"),oi(i,this.ao()),this.Kh=!0,this.po=t,this.mo=!1,this.yo(new Xt(Kt.PICTURE_IN_PICTURE)))}bo(t){let i=this.lo;i&&(this.wo(),ui(i,"theo-pip"),ui(i,this.ao()),this.Kh=!1,this.mo=t,this.ko=this.po,this.po=!1,this.yo(new Xt(Kt.INLINE)))}fo(){if(!this.do){let t=this.t.oo;t.addChild(Au,{Qh:this});let i=h.createElement("div");i.className="theo-pip-overlay",this._o=h.createElement("div"),this._o.className="theo-pip-overlay-text",f(this._o,t.localize("Video playing in Picture-in-Picture mode")),i.appendChild(this._o),ei(t.el(),i),this.xo=i,this.do=!0}}Co(){this.So&&!this.jo&&this.t.To&&(this.Mo=this.t.To.Ao(X,this.Po),this.jo=!0)}Eo(){this.Mo&&this.t.To&&(this.t.To.No(this.Mo),this.jo=!1)}vo(){let t=this.t.oo.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"}wo(){let t=this.t.oo.contentEl();t.style.top="",t.style.bottom="",t.style.right="",t.style.left="",t.style.width="",t.style.height="",t.style.position=""}Io(){ui(this.lo,"theo-pip"),this.Yh&&this.uo&&ui(this.lo,"theo-pip-"+this.uo),this.xo&&(ii(this.xo),this.xo=void 0)}gn(){this.Io(),this.Eo(),this.Bo(),this.t.fn(G.so,this.eo),this.t.fn(G.ro,this.ho),this.t.oo.off("languagechange",this.te),this.t=void 0}constructor(t,i,s){super(),this.Fo=!1,this.Kh=!1,this.mo=!1,this.po=!1,this.do=!1,this.jo=!1,this.ko=!1,this.eo=()=>{this.Fo=!0,this.So&&!this.Yh&&this.Mo&&this.Do&&this.Mo.$o<=this.Do&&this.co(!1)},this.ho=()=>{this.no||(this.Fo=!1,this.bo(!1))},this.te=()=>{if(this._o){const t=this.t.oo;f(this._o,t.localize("Video playing in Picture-in-Picture mode"))}},this.Po=t=>{!this.po&&this.So&&(j(t)||(this.Do&&t<=this.Do||this.ko?this.Kh||this.mo||this.co(!1):this.Kh?this.bo(!1):this.mo=!1))},this.Do=i.visibility,this.uo=i.position,this.no=i.retainPresentationModeOnSourceChange,this.So=void 0!==this.Do,this.t=t,this.lo=t.Ro,this.Jh=s,this.io()}},Eu=class extends ti{Oo(){let t=super.Oo();return t===Kt.INLINE&&this.Vo&&this.Vo.Yh?Kt.PICTURE_IN_PICTURE:t}Uo(t){return t===Kt.PICTURE_IN_PICTURE||super.Uo(t)}zo(t,i){t===Kt.FULLSCREEN&&this.Vo.Eo(),super.zo(t,i),t!==Kt.FULLSCREEN&&this.Vo.Co()}Lo(t,i){t!==i&&(t===Kt.FULLSCREEN&&this.Vo.bo(!1),t===Kt.INLINE&&i===Kt.PICTURE_IN_PICTURE&&this.Vo.bo(!0),super.Lo(t,i),t===Kt.PICTURE_IN_PICTURE&&(i===Kt.INLINE?this.Vo.co(!0):this.Vo.co(!1)))}gn(){super.gn(),this.Vo.gn(),this.Ho.fn(G.so,this.qo),this.Ho=void 0}constructor(t,i,s){super(i),this.Wo=()=>this.Yr(),this.Jh=()=>this.Go(Kt.INLINE),this.qo=()=>{this.Oo()!==Kt.FULLSCREEN&&this.Vo.Co(),this.Ho.fn(G.so,this.qo)},this.Ho=t,this.Vo=new Pu(t,s.pip,this.Jh),this.Vo.yn("presentationmodechange",this.Wo),this.Ho.yn(G.so,this.qo),this.Yr()}};d();var Nu,Iu=class extends H{get Xo(){return _i.Jo(this.oo.el())||this.oo.supportsFullScreen()}get cs(){return this.oo.isFullscreen()||this.Qo}co(){this.oo.requestFullscreen()}bo(){this.oo.exitFullscreen(),this.Yo.bo()}gn(){this.Bo(),this.oo.off("fullscreenchange",this.Ko),this.Yo.fn(Wt.Zo,this.Ko),this.Yo.fn(Wt.ta,this.Ds),this.oo.isFullWindow&&this.oo.exitFullscreen()}constructor(t,i){super(),this.Os=!1,this.Qo=!1,this.ia=!1,this.Ko=()=>{if(this.ia)return;const t=this.Os,i=this.cs;t!==i&&(this.Os=i,this.yo(new yi))},this.sa=()=>{this.Qo=this.Yo.cs,this.Ko()},this.ea=()=>{this.ia||(this.oo.isFullWindow&&this.oo.supportsFullScreen()||this.Qo&&!this.oo.supportsFullScreen())&&(this.ia=!0,this.oo.exitFullscreen(),this.oo.requestFullscreen(),this.ia=!1,this.Ko())},this.oo=t,this.Yo=i,this.oo.on("fullscreenchange",this.Ko),this.Yo.yn(Wt.Zo,this.sa),this.Yo.yn(Wt.na,this.ea),this.Yo.yn(Wt.ta,this.Ds),this.Ko()}};function Bu(t){return class extends t{get To(){return this.ra}cs(){return"fullscreen"===this.ha.Oo()}oa(){return function(t,i){let s=_.create(t);const e=i.oo;return it(s,{get controls(){return e.controls()},set controls(t){e.controls(ot(t))},get presentation(){return i.ha.aa},get presentationMode(){return i.ha.Oo()},set presentationMode(t){const s=si(t);s&&i.ha.Go(s)},get ui(){return e},get visibility(){return i.To.aa}})}(this.ua,this)}gn(){super.gn(),this.ha.gn(),this.ca.gn(),this.oo.dispose(),this.ra.gn()}la(t){this.oo.src(""),super.la(t)}constructor(t,i,s){super(i,s),this.Ro=t,this.ra=new Q(t),this.ua=super.oa(),_.defineProperty(this.ua,"constructor",{value:st}),this.oo=Tu(this.ua,this.Ro,s.ui),this.ca=new Iu(this.oo,this.da),this.ha=new Eu(this,this.ca,s),this.ha.yn("presentationmodechange",this.Ds)}}}function Fu(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(Ut(t)&&!j(t))return Yt(t,0,1)}(t.visibility),t.retainPresentationModeOnSourceChange=ot(t.retainPresentationModeOnSourceChange),t}function Du(){return Nu||(Nu=function(t){let i=t;for(const t of Ai)i=t(i);return i}(Nu=Bu(tt()))),Nu}function $u(t,i){const s=function(t){const i=Ht(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=Fu(i.pip),i}(i),e=h.createElement("div");fi(e),t.appendChild(e);const n=new(Du())(t,e,s);n.fa=n;let r=n.aa;return n.va(),n.pa(K),_.defineProperty(r,"constructor",{value:$u}),r=Z(r),It(n),function(t){for(const i of Ei)i(t)}(n),r}d(),d(),d(),d(),d();var Ru="theo-cast-",Ou=Mo.getComponent("Button"),Vu=class extends($o(Ou)){get ma(){throw new b("ga")}get ya(){return this.h.ya}get ba(){return this.h.ba}buildCSSClass(){return Ru+"button theo-"+this.ba+"-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=Ru+"svg-container",r.innerHTML=this.ya,e.appendChild(n),e.appendChild(r),e}handleClick(t){var i;if(super.handleClick(t),this.wa===ni.AVAILABLE)null==(i=this.ma)||i.start();else if(this.wa===ni.CONNECTED||this.wa===ni.CONNECTING){var s;null==(s=this.ma)||s.stop()}}ka(t){ui(this.lo,"theo-"+this.ba+"-"+this.wa),this.wa=t,oi(this.lo,"theo-"+this.ba+"-"+this.wa),this.te()}te(){this._a(this.wa),this.Be.Ie=this.controlText()}_a(t){t===ni.CONNECTED?this.controlText("Stop Casting"):t===ni.AVAILABLE?this.controlText("Start Casting"):t===ni.CONNECTING?this.controlText("Connecting"):this.controlText("Unavailable")}constructor(t,i){var s;super(t,i),this.lo=t.el(),this.wa=ni.UNAVAILABLE,this.controlText("Unavailable"),this.Be=new aa(this,this.controlText()),null==(s=this.ma)||s.addEventListener("statechange",(t=>{const i=t;this.ka(i.state)})),$t.Ys.Je&&(this.xa=new Jo(this.el())),this.ka(this.ma?this.ma.state:ni.UNAVAILABLE),this.on(t,"languagechange",this.te)}},Uu=0;function zu(){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-'+Uu+'">\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-'+Uu+')">\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 Uu++,t}Mo.registerComponent("chromecastButton",class extends Vu{get ma(){var t;return null==(t=this.ks.cast)?void 0:t.chromecast}constructor(t,i){super(t,xi({},i,{ba:"chromecast",ya:zu()}))}}),d();var Lu="theo-chromecast-",Hu=Mo.getComponent("Component"),qu=class t extends($o(Hu)){buildCSSClass(){return Lu+"overlay "+super.buildCSSClass()}createEl(){const i=super.createEl();oi(i,Lu+"overlay");const s=Mo.createEl("div",{className:Lu+"status-icon",innerHTML:t.ICON_SVG}),e=Mo.createEl("div",{className:Lu+"status-info"});f(e,"Playing on");const n=Mo.createEl("div",{className:Lu+"status-title"}),r=Mo.createEl("div",{className:Lu+"status"});return this.mr=n,r.appendChild(s),r.appendChild(e),r.appendChild(n),i.appendChild(r),i}dispose(){var t;null==(t=this.Ca)||t.removeEventListener("statechange",this.update),this.Ca=void 0,this.ks.removeEventListener("play",this.update),super.dispose()}constructor(t,i){var s,e;super(t,i),this.update=()=>{this.Ca?(this.mr&&f(this.mr,this.Ca.receiverName||""),this.Ca.state===ni.CONNECTED?this.show():this.hide()):this.hide()},this.Ca=null==(s=this.ks.cast)?void 0:s.chromecast,null==(e=this.Ca)||e.addEventListener("statechange",this.update),this.ks.addEventListener("play",this.update),this.update()}};qu.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>',Mo.registerComponent("chromecastOverlay",qu),d(),d();Mo.registerComponent("airplayButton",class extends Vu{dispose(){var t,i;null==(t=this.ks.ads)||t.removeEventListener("adbreakbegin",this.Sa),null==(i=this.ks.ads)||i.removeEventListener("adbreakend",this.ja),this.ks.removeEventListener("currentsourcechange",this.ja),super.dispose()}get ma(){var t;return null==(t=this.ks.cast)?void 0:t.airplay}constructor(t,i){var s,e;super(t,xi({},i,{ba:"airplay",ya:'\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.ja=()=>{this.enable()},this.Sa=()=>{this.disable()},null==(s=this.ks.ads)||s.addEventListener("adbreakbegin",this.Sa),null==(e=this.ks.ads)||e.addEventListener("adbreakend",this.ja),this.ks.addEventListener("currentsourcechange",this.ja)}}),d(),d(),d();var Wu=Mo.getComponent("Button"),Gu=class extends($o(Wu)){buildCSSClass(){return"theo-vr-button theo-controlbar-button "+super.buildCSSClass()}handleClick(){this.ks.vr.stereo=!this.ks.vr.stereo,this.te()}_n(){this.ks.vr&&this.ks.vr.state!==Mt.Rs?(this.show(),this.ks.vr.canPresentVR?(this.enable(),this.te()):(this.disable(),this.controlText("No VR capable device found"),this.Ta.Ie=this.controlText())):this.hide()}te(){var t;this.controlText((null==(t=this.ks.vr)?void 0:t.stereo)?"Stop watching in VR":"Watch in VR"),this.Ta.Ie=this.controlText()}dispose(){var t;null==(t=this.ks.vr)||t.removeEventListener("statechange",this.Ma),super.dispose()}constructor(t,i){var s;super(t,i),this.Ma=()=>this._n(),this.controlText("Watch in VR"),this.Ta=new aa(this,this.controlText()),null==(s=this.ks.vr)||s.addEventListener("statechange",this.Ma),this._n(),$t.Ys.Je&&new Jo(this.el()),this.on(t,"languagechange",this.te)}};Mo.registerComponent("vrButton",Gu),d();var Xu=Mo.getComponent("Component"),Ju=class extends Xu{createEl(){let t=super.createEl("div",{className:this.buildCSSClass()}),i=Mo.createEl("div",{className:"theo-360-fov"});return t.appendChild(i),this.Aa=i,t}buildCSSClass(){return"theo-360-compass "+super.buildCSSClass()}_n(){this.ks.vr.state===Mt.Rs?this.hide():this.show()}Pa(){let t=-this.ks.vr.direction.yaw+40;this.Aa.style[vi("transform")]="scale(0.875) rotate("+t+"deg) skew("+"-10deg)"}dispose(){this.ks.vr.removeEventListener("statechange",this.Ma),this.ks.vr.removeEventListener("directionchange",this.Ea),super.dispose()}constructor(t,i,s){super(t,i),this.Ma=()=>this._n(),this.Ea=()=>this.Pa(),this.ks=s,this.ks.vr.addEventListener("statechange",this.Ma),this.ks.vr.addEventListener("directionchange",this.Ea),this._n(),this.Pa()}};d();var Qu=x.pow(2,31)-1,Yu=Mo.getComponent("Component"),Ku=class extends Yu{Na(){this.ks.vr.state===Mt.Ia?this.Ba():this.Fa()}Ba(){if(this.Da)return;this.Da=!0;let t=this.ks.element;this.$a=t.style.zIndex||"",t.style.zIndex=""+Qu,this.Ra=this.player().isFullscreen(),this.player().requestFullscreen()}Fa(){if(!this.Da)return;this.Da=!1,this.ks.element.style.zIndex=this.$a,this.Ra?this.player().requestFullscreen():this.player().exitFullscreen()}dispose(){this.Fa(),this.ks.vr.removeEventListener("statechange",this.Oa),super.dispose()}constructor(t,i,s){super(t,i),this.Da=!1,this.Ra=!1,this.$a="",this.Oa=()=>this.Na(),this.ks=s,this.ks.vr.addEventListener("statechange",this.Oa),this.Na()}};Ni((function(t){let i=t.aa;if(!i.vr)return;let s=t.oo,e=new Ju(s,{},i);if(t.yn(G.ro,(()=>{var i;s.removeChild(e);let n=null==(i=t.Va())?void 0:i.vr;void 0===n||n.nativeVR||s.addChild(e)})),Ot.Ua){let t=new Ku(s,{},i);s.addChild(t)}})),d(),d(),d();var Zu=class extends W{constructor(){super("relatedchange")}},tc=["relatedchange"],ic=class extends H{get aa(){return this.za||(this.za=function(t){let i,s={get sources(){return t.La},set sources(i){t.La=i},addEventListener(t,s){i.yn(t,s)},removeEventListener(t,s){i.fn(t,s)}};return i=new Qt(tc,!0,s),i.Ha(t),s}(this)),this.za}get La(){return this.qa}set La(t){this.qa=function(t){return t.filter((t=>t&&(Gt(t.link)||rt(t,["source"]))))}(t),t.length>this.qa.length&&console.warn("One or more of the configured related content sources are invalid. Check if they have a source or a link."),this.yo(new Zu)}gn(){this.Bo(),this.qa=[]}constructor(...t){super(...t),this.qa=[]}};Pt((function(t){return class extends t{oa(){const t=this.Wa;return it(super.oa(),{get related(){return t.aa}})}gn(){this.Wa.gn(),super.gn()}constructor(t,i){super(t,i),this.Wa=new ic}}}),M.Ga),d(),d();var sc=Mo.getComponent("Button"),ec=class extends sc{buildCSSClass(){return"vjs-icon-view-grid theo-related-button "+super.buildCSSClass()}handleClick(){this.Ja.Xa?this.Ja.be():this.Ja.ge()}te(){this.Be.Ie=this.controlText()}dispose(){this.player().topControlBar.removeChild(this),super.dispose()}constructor(t,i,s){super(t,s),this.lo=t.el(),this.Ja=i,this.player().topControlBar.addChild(this),this.hide(),this.controlText(this.localize("Related content")),this.Be=new aa(this,this.controlText()),this.on(t,"languagechange",this.te)}};d(),d();var nc=Mo.getComponent("Button"),rc=class extends nc{buildCSSClass(){return"theo-secondary-background theo-close-button"}handleClick(){this.Qa.hide()}constructor(t,i){super(t),this.Qa=i}},hc=(()=>{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 oc(t,i,s){let e=hc.cloneNode(!0),n=e.querySelector(".theo-related-grid-tile-content");rt(s,["source"])?(n.style.cursor="pointer",n.addEventListener("click",(()=>{t.source=s.source,i.be()}))):Gt(s.link)&&n.setAttribute("href",s.link);let r=e.querySelector(".theo-related-grid-tile-image");r.style.backgroundImage='url("'+Ti(s.image)+'")',r.removeAttribute("id");let h=e.querySelector(".theo-related-grid-tile-title");s.title?(f(h,s.title),h.removeAttribute("id")):ii(h);let o=e.querySelector(".theo-related-grid-tile-duration");return s.duration?(f(o,s.duration),o.removeAttribute("id")):ii(o),e}var ac=[15,12,9,8,6,4,3,2,1];var uc=class{get Ya(){return"theo-"+this.Ka+"-item-grid"}Za(){this.tu.focus()}iu(t){this.su(),function(t){if(t.length)for(let i of ac)if(t.length>=i){t.length=i;break}}(t),this.eu(t.length);for(let i of t){let t=oc(this.nu.aa,this.ru,i);this.hu.appendChild(t)}}su(){this.hu.innerHTML=""}ou(){let t=h.createElement("div");t.className="theo-overlay-panel";const i=h.createElement("div");return i.className="theo-related-grid",this.au.className="theo-related",this.tu.controlText("Close Related Content"),this.uu.appendChild(this.au),this.au.appendChild(t),t.appendChild(this.tu.el()),t.appendChild(i),i}eu(t){ui(this.hu,this.Ya),this.Ka=t,oi(this.hu,this.Ya)}gn(){ii(this.au),this.cu.gn(),this.lu.gn(),this.tu.dispose(),this.nu=void 0}constructor(t,i,s,e,n){this.nu=t,this.du=i,this.ru=s,this.uu=e,this.Ka=12,this.fu=t=>{this.hu.style.width=t.width+"px"},this.au=h.createElement("div"),this.tu=new rc(this.du,{hide:()=>{this.ru.be()}}),this.hu=this.ou(),this.lu=new cc(n),this.lu.yn(ci.pn,this.fu),this.cu=new _t(this.hu,this.lu),this.eu(12)}},cc=class extends H{get vu(){return this.pu||0}get mu(){return this.gu.mu}gn(){this.Bo(),this.gu.fn(ci.pn,this.yu)}constructor(t){super(),this.gu=t,this.yu=t=>{let i=t.width;if(9*(t.width/16)>t.height){i=16*(t.height/9)}this.pu=i,this.yo(new di(this.vu,t.height))},this.gu.yn(ci.pn,this.yu)}};d();var lc=class extends W{constructor(){super("show")}};d();var dc=class extends W{constructor(){super("hide")}},fc="theo-related-available",vc="theo-related-showing",pc=[...tc,"show","hide"],mc=class extends H{get aa(){return this.za||(this.za=function(t){let i;const s={get sources(){return t.La},set sources(i){t.La=i},get showing(){return t.Xa},show(){t.ge()},hide(){t.be()},addEventListener(t,s){i.yn(t,s)},removeEventListener(t,s){i.fn(t,s)}};return i=new Qt(pc,!0,s),i.Ha(t),s}(this)),this.za}get La(){return this.bu.La}set La(t){this.bu.La=t}get Xa(){return this.wu}ge(){let t=this.wu;this.wu=!0,this.ku(vc),this._u.Za(),this.du.paused()?this.xu=!0:this.du.pause(),t!==this.wu&&this.yo(new lc)}be(){let t=this.wu;this.wu=!1,this.Cu(vc),this.Su.focus(),this.xu||this.du.play(),this.xu=!1,t!==this.wu&&this.yo(new dc)}ku(t){this.du.el().classList.add(t)}Cu(t){this.du.el().classList.remove(t)}gn(){this.Bo(),this._u.gn()}constructor(t,i,s,e){super(),this.wu=!1,this.xu=!1,this.ju=t=>{const i=this.La;this._u.iu(i),i.length?(this.ku(fc),this.Su.show()):(this.Cu(fc),this.Su.hide()),this.yo(t)},this.bu=i,this.bu.yn("relatedchange",this.ju),this.du=s,this._u=new uc(t,this.du,this,s.contentEl(),e),this.Su=new ec(s,this,{})}};Pi((function(t){return class extends t{oa(){const t=this.Tu;return it(super.oa(),{get related(){return t.aa}})}gn(){this.Tu.gn(),super.gn()}constructor(t,i,s){super(t,i,s),this.Tu=new mc(this,this.Wa,this.oo,this.Mu)}}})),d(),d(),d();var gc=Mo.getComponent("Button"),yc=class extends gc{buildCSSClass(){return"vjs-icon-share theo-social-button "+super.buildCSSClass()}handleClick(){this.Au.showing?this.Au.hide():this.Au.show()}te(){this.Be.Ie=this.controlText()}dispose(){this.player().topControlBar.removeChild(this),super.dispose()}constructor(t,i,s){super(t,s),this.lo=t.el(),this.Au=i,this.player().topControlBar.addChild(this),this.hide(),this.controlText("Share Video"),this.Be=new aa(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="Pu",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",f(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,f(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",f(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="Pu",n.href=i,f(n,i),e.appendChild(n),s.appendChild(e),s}(t,s)}}d();var wc="<URL>";var kc=class{get ke(){return this.au}Eu(t){this.su();for(let i of t)this.Nu(i)}Za(){this.tu.focus()}Nu(t){let i=function(t,i){return t.src?Si(t.src,wc)?t.src.replace(wc,i):t.src:i}(t,this.ru.Iu),s=function(t){if(t)return t.icon?"iconurl":t.text?"text":"texturl"}(t),e=bc(t,s,i);e&&("iconurl"===s?this.Bu.appendChild(e):this.Fu.appendChild(e))}su(){this.Bu.innerHTML="",this.Fu.innerHTML=""}gn(){ii(this.au),this.Du.gn()}constructor(t,i,s,e){this.Ho=t,this.ru=i,this.uu=s,this.$u=e;const n=h.createElement("div");n.className="theo-overlay-panel",this.tu=new rc(this.Ho,this.ru.aa),this.tu.controlText("Close Share"),this._u=h.createElement("div"),this._u.className="theo-social-container",this.au=h.createElement("div"),this.au.className="theo-social",this.Bu=h.createElement("div"),this.Bu.className="theo-social-icon-container",this.Fu=h.createElement("div"),this.Fu.className="theo-social-text-container",this.uu.appendChild(this.au),this.au.appendChild(n),this._u.appendChild(this.Bu),this._u.appendChild(this.Fu),n.appendChild(this.tu.el()),n.appendChild(this._u),this.Du=new _t(this.au,this.$u)}},_c="theo-social-available",xc="theo-social-showing",Cc=class{get aa(){return this.za}get Xa(){return this.wu}get Ru(){return this.Ou}set Ru(t){this.Ou=t,this._u.Eu(t),t.length?(this.ku(_c),this.Su.show()):(this.Cu(_c),this.Su.hide())}get Iu(){return this.Vu||Zt()}set Iu(t){this.Vu=t}ge(){this.wu=!0,this.ku(xc),this._u.Za(),this.Uu.paused()?this.xu=!0:this.Uu.pause()}be(){this.wu=!1,this.Cu(xc),this.Su.focus(),this.xu||this.Uu.play(),this.xu=!1}ku(t){this.Uu.el().classList.add(t)}Cu(t){this.Uu.el().classList.remove(t)}gn(){this.Su.dispose(),this._u.gn()}constructor(t,i){this.wu=!1,this.Ou=[],this.xu=!1,this.za=function(t){return{get showing(){return t.Xa},get items(){return t.Ru},set items(i){t.Ru=i},get url(){return t.Iu},set url(i){t.Iu=i},show(){t.ge()},hide(){t.be()}}}(this),this.Uu=t,this._u=new kc(this.Uu,this,t.contentEl(),i),this.Su=new yc(t,this.za,{})}};Pi((function(t){return class extends t{oa(){let t=this.Au;return it(super.oa(),{get social(){return t.aa}})}constructor(t,i,s){super(t,i,s),this.Au=new Cc(this.oo,this.Mu)}}})),d(),d();var Sc=Mo.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=xi({},jc.prototype.h,{children:[]}),Mo.registerComponent("upNextContainer",jc),d(),d();var Tc="theo-upnext-bar-",Mc=Mo.getComponent("Component"),Ac=class extends Mc{get Xa(){return this.wu}set Xa(t){this.wu=t,this.zu&&(this.zu.tabIndex=t?0:-1)}get Lu(){return this.Hu}set Lu(t){this.Hu=t}la(t){this.su(),this.qu(t)}qu(t){if(t&&t.link&&t.image){const i=h.createElement("div");oi(i,Tc+"content"),i.onclick=()=>{this.Wu.next()},i.onkeypress=t=>{13===t.which&&this.Wu.next()};let s=h.createElement("div");if(s.style.backgroundImage='url("'+Ti(t.image)+'")',oi(s,Tc+"image"),i.appendChild(s),t.duration){let i=h.createElement("span");oi(i,Tc+"duration"),i.innerHTML=""+t.duration,s.appendChild(i)}let e=h.createElement("div");oi(e,Tc+"text");let n=h.createElement("div");if(oi(n,Tc+"upnext"),f(n,this.localize("Up Next")),e.appendChild(n),t.title){let i=h.createElement("div");oi(i,Tc+"title"),f(i,t.title),e.appendChild(i)}i.appendChild(e),this.zu=i,this.Gu=n,this.el().appendChild(this.zu)}}su(){this.el().innerHTML="",this.zu=void 0,this.Gu=void 0}te(){this.Gu&&f(this.Gu,this.localize("Up Next"))}createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-upnext-bar "+super.buildCSSClass()}dispose(){this.Du.gn(),super.dispose()}constructor(t,i,s,e){super(t,s),this.zu=void 0,this.Gu=void 0,this.Wu=i,this.Du=new _t(this.el(),e),this.wu=!1,this.Hu=10,this.on(t,"languagechange",this.te)}};d();var Pc="theo-upnext-panel-",Ec=pu,Nc=Mo.getComponent("Component"),Ic=class extends Nc{get Xa(){return this.wu}set Xa(t){this.wu=t}get Xu(){return this.Ju}set Xu(t){this.Ju=t}get Qu(){return this.Yu}set Qu(t){this.Yu=t}la(t){this.su(),this.Ku(t)}Ku(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("'+Ti(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",f(n,this.localize("Up Next")),e.appendChild(n),t.title){let i=h.createElement("div");i.className=Pc+"title",f(i,t.title),e.appendChild(i)}i.appendChild(e),this.Zu=h.createElement("div"),this.Zu.className=Pc+"autoplay",this.Zu.innerHTML=mu;let r=this.Zu.querySelector("svg");r.onclick=()=>{this.Wu.next()},r.tabIndex=0,r.onkeypress=t=>{13===t.which&&this.Wu.next()},this.tc=n,this.ic=this.Zu.querySelector("."+Ec),i.appendChild(this.Zu),this.el().appendChild(i)}}get sc(){return this.ec}set sc(t){this.ec=t,this.ic.style.strokeDashoffset=""+x.round(1e5*t)/1e5}su(){this.el().innerHTML="",this.tc=void 0,this.ic=void 0}te(){this.tc&&f(this.tc,this.localize("Up Next"))}createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-upnext-panel "+super.buildCSSClass()}dispose(){this.Du.gn(),super.dispose()}constructor(t,i,s,e){super(t,s),this.ec=0,this.Wu=i,this.Du=new _t(this.el(),e),this.wu=!1,this.Ju=10,this.Yu=!0,this.on(t,"languagechange",this.te)}},Bc="theo-upnext-panel-showing",Fc="theo-upnext-bar-showing",Dc=2*x.PI*73,$c=class t{get aa(){return this.za}get nc(){return this.rc}get hc(){return this.oc}get ac(){return this.uc}set ac(t){this.uc=t,this._u.la(t),this.cc.la(t),this.Uu.off("timeupdate",this.lc),this.Uu.off("ended",this.dc),t&&(this.Uu.on("timeupdate",this.lc),this.Uu.on("ended",this.dc))}fc(){this._u.Xu?this.vc=ut(this._u.Xu):0===this._u.Xu?this.vc=0:this.vc=10,0!==this.vc?(isFinite(this.vc)&&(this.mc=!0),this._u.Xa=!0,this.ku(Bc),this.mc&&(this._u.sc=Dc-Dc/this.vc,this.gc=v(this.yc,1e3))):this.bc()}wc(){this._u.Xa=!1,this.Cu(Bc),this.mc&&(m(this.gc),this.kc=1,this._u.sc=Dc)}_c(){this.cc.Xa=!0,this.ku(Fc)}xc(){this.cc.Xa=!1,this.Cu(Fc)}bc(){m(this.gc),this.ac&&(s.location.href=this.ac.link)}ku(t){this.Uu.el().classList.add(t)}Cu(t){this.Uu.el().classList.remove(t)}Cc(t,i){const s=t>=i&&!(this.Sc&&this.Sc.jc);this.cc.Xa&&!s?this.xc():!this.cc.Xa&&s&&this._c()}Tc(t,i){this._u.Xa&&t<i&&!this.Uu.ended()&&this.wc()}static Mc(t,i){let s=ut(t);if(!j(s))return i-s;let e=(""+t).match(/^([1-9]?\d|100)%$/);if(e){return i*(1-C(e[1],10)/100)}}gn(){this.gc&&m(this.gc),this.Uu.getChild("upNextContainer").removeChild(this._u),this.Uu.getChild("upNextContainer").removeChild(this.cc),this._u.dispose(),this.cc.dispose()}constructor(i,s,e){this.uc=void 0,this.vc=10,this.kc=1,this.gc=void 0,this.mc=!0,this.yc=()=>{this.kc!==this.vc?(this._u.sc-=Dc/this.vc,this.kc+=1):this.bc()},this.dc=()=>{this._u.Xa||this.fc()},this.lc=()=>{let i=this.Uu.currentTime(),s=this.Uu.duration(),e=s?t.Mc(this.cc.Lu,s):void 0;void 0!==e&&this.Cc(i,e),this._u.Qu&&this.Tc(i,s)},this.za=function(t){return{get source(){return t.ac},set source(i){t.ac=i},get bar(){return t.nc},get panel(){return t.hc},next(){t.bc()}}}(this),this.cc=new Ac(i,this.za,{},s),this._u=new Ic(i,this.za,{},s),this.rc=function(t,i){return{get showing(){return i.Xa},get offset(){return i.Lu},set offset(t){i.Lu=t},show(){t._c()},hide(){t.xc()}}}(this,this.cc),this.oc=function(t,i){return{get showing(){return i.Xa},get countdownDuration(){return i.Xu},set countdownDuration(t){i.Xu=t},get showUpNextPanel(){return i.Qu},set showUpNextPanel(t){i.Qu=t},show(){t.fc()},hide(){t.wc()}}}(this,this._u),this.Uu=i,this.Sc=e,i.getChild("upNextContainer").addChild(this.cc,{}),i.getChild("upNextContainer").addChild(this._u,{})}};Pi((function(t){return class extends t{oa(){let t=this.Ac;return it(super.oa(),{get upnext(){return t.aa}})}gn(){this.Ac.gn(),super.gn()}constructor(t,i,s){super(t,i,s),this.Ac=new $c(this.oo,this.Mu,this.Pc)}}})),d(),d();var Rc=Mo.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",f(n,"Powered by THEOplayer 8.6.2"),s.appendChild(n),s.href="https://www.theoplayer.com/player-referral",s.target="Pu",t.appendChild(i),t}Ec(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=S(getComputedStyle(this.el()).fontSize);L(this.el(),r,n,h);let o=i.clientY-s.getBoundingClientRect().top;q(this.el(),o,n,h),this.Nc()}Ic(){this.hide(),this.clearTimeout(this.Bc)}Nc(){this.Bc=this.setTimeout(this.Ic,4e3)}Fc(){this.clearTimeout(this.Bc)}dispose(){this.Ic(),this.off(this.player(),"contextmenu",this.Ec),this.el().removeEventListener("mousedown",Vc,!0),this.off(h,"mousedown",this.Ic),this.off("mouseout",this.Nc),this.off("mouseover",this.Fc),super.dispose()}constructor(t,i){super(t,i),this.Bc=0,this.on(this.player(),"contextmenu",this.Ec),this.el().addEventListener("mousedown",Vc,!0),this.on(h,"mousedown",this.Ic),this.on("mouseout",this.Nc),this.on("mouseover",this.Fc),this.Ic()}};function Vc(t){t.stopPropagation()}Ni((function(t){const i=new Oc(t.oo,{});t.oo.addChild(i),t.oo.on("dispose",(()=>{t.oo.removeChild(i),i.dispose()}))})),d(),d(),d(),d();var Uc={Default:"","Monospaced Serif":ji.Dc,"Proportional Serif":ji.$c,"Monospaced Sans-Serif":ji.Rc,"Proportional Sans-Serif":ji.Oc},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 _.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";d();var sl=class extends Xa{Vc(){let t=this.Fr.localize(this.Uc);f(this.zc.subMenu.menuHeader.el(),t),this.Br=h.createElement("span"),this.Br.className="theo-settings-control-menu-item-title",f(this.Br,t);let i=h.createElement("span");return i.className="theo-primary-color theo-settings-control-menu-item-value",oi(this.zc.el(),"theo-subtitle-options-menu-item"),this.zc.el().appendChild(this.Br),this.zc.el().appendChild(i),i}Lc(t){const i=this.jr(t);i&&this.Hc(i)}qc(){return this.br}Ar(t){this.Wc(t.Tr)}Hc(t){for(let t of this.Cr.menuItems)t.selected(!1);t?(t.selected(!0),this.Gc(t.Tr.label)):this.Gc("Custom")}Gc(t){this.Xc=t,f(this.Jc,this.Fr.localize(t)),this.zc.parentMenu.re()}Mr(t){let i=super.Mr(t);return oi(i.el(),"theo-subtitle-options-menu-item"),this.Nr(i),i}Nr(t){const i=this.Fr.localize(t.Tr.label);f(t.el(),i);const s=this.Fr.localize("Set "+this.Uc+" 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.zc=t,this.Fr=e,this.Xc="",this.te=()=>{let t=this.Fr.localize(this.Uc);f(this.zc.subMenu.menuHeader.el(),t),f(this.Br,t),this.Gc(this.Xc);for(const t of this.Sr)this.Nr(t)},this.Uc=i,this.Wc=s.Wo,this.Jc=this.Vc(),this.br=s.Qc,this.Fr.on("languagechange",this.te)}};d();var el=class t{static Yc(t,i,s,e){if(void 0===t&&void 0===i)return;return $(void 0===t?s:t,void 0===i?e:i)}constructor(i){this.Kc=i,this.Zc=t=>{this.Kc.fontFamily=t.value},this.tl=t=>{this.Kc.fontSize=t.value},this.il=i=>{this.sl=i.value,this.Kc.fontColor=t.Yc(this.nl,this.sl,tl,Kc)},this.rl=i=>{this.nl=i.value,this.Kc.fontColor=t.Yc(this.nl,this.sl,tl,Kc)},this.hl=i=>{this.ol=i.value,this.Kc.backgroundColor=t.Yc(this.ol,this.al,Zc,Kc)},this.cl=i=>{this.al=i.value,this.Kc.backgroundColor=t.Yc(this.ol,this.al,Zc,Kc)},this.ll=i=>{this.dl=i.value,this.Kc.windowColor=t.Yc(this.dl,this.fl,il,Kc)},this.vl=i=>{this.fl=i.value,this.Kc.windowColor=t.Yc(this.dl,this.fl,il,Kc)},this.pl=t=>{this.Kc.edgeStyle=t.value}}};d();var nl=class{ml(t,i){const s=this.gl(t,i.qc());s&&i.Lc(s)}gl(t,i){return D(i,(i=>i.value===t))}yl(t,i,s){let e,n;if(void 0===t)e=this.gl(void 0,i.qc()),n=this.gl(void 0,s.qc());else if(t){let r=function(t){let i=F(t);i||(i=F(t.slice(0,t.length-1).replace("rgb","rgba")+",1)"));i||(i=Mi(E(t),1));if(!i){let s=t.charAt(0).toUpperCase()+t.toLowerCase().slice(1);i=Mi(E(zc[s]),1)}return i}(t);if(r){let t=I(r),h=100*r.bl;e=this.gl(t,i.qc()),n=this.gl(h,s.qc())}}e&&i.Lc(e),n&&s.Lc(n)}constructor(t,i){this.Kc=t,this.wl=i,this.kl=()=>{let t=this.Kc.fontFamily;this.ml(t,this.wl["Font family"]);let i=this.Kc.fontColor;this.yl(i,this.wl["Font color"],this.wl["Font opacity"]);let s=this.Kc.fontSize;this.ml(s,this.wl["Font size"]);let e=this.Kc.backgroundColor;this.yl(e,this.wl["Background color"],this.wl["Background opacity"]);let n=this.Kc.windowColor;this.yl(n,this.wl["Window color"],this.wl["Window opacity"]);let r=this.Kc.edgeStyle;this.ml(r,this.wl["Character edge style"])},this.Kc.addEventListener("change",this.kl),this.kl()}};var rl=class extends Xa{_l(){return{"Font family":{Qc:hl(Qc),Wo:this.xl.Zc},"Font color":{Qc:hl(Jc),Wo:this.xl.rl},"Font opacity":{Qc:hl(Gc),Wo:this.xl.il},"Font size":{Qc:hl(Wc),Wo:this.xl.tl},"Background color":{Qc:hl(Jc),Wo:this.xl.hl},"Background opacity":{Qc:hl(Xc),Wo:this.xl.cl},"Window color":{Qc:hl(Jc),Wo:this.xl.ll},"Window opacity":{Qc:hl(Xc),Wo:this.xl.vl},"Character edge style":{Qc:hl(Yc),Wo:this.xl.pl}}}Cl(){this.Br=h.createElement("span"),this.Br.className="theo-settings-control-menu-item-title",this.Sl=h.createElement("span"),this.Sl.className="theo-primary-color theo-settings-control-menu-item-value",this.Lr.el().appendChild(this.Br),this.Lr.el().appendChild(this.Sl),this.te()}Mr(t){let i=this.Cr.addSubMenuItem();return i.Tr=t,this.wl[t]=new sl(i,t,this.jl[t],this.Fr),i}Nr(t){}Ar(t){}Re(){this.Fr.off("languagechange",this.te),this.Tl.removeEventListener(["addtrack","removetrack"],this.Ml),super.Re()}constructor(t,i,s,e){super(t.subMenu),this.Lr=t,this.Tl=i,this.Fr=e,this.wl={},this.Ml=()=>{this.Tl.some((t=>xt(t.kind)))?this.Lr.show():this.Lr.hide()},this.te=()=>{f(this.Cr.menuHeader.el(),this.Fr.localize("Subtitle Options")),f(this.Br,this.Fr.localize("Subtitle")),f(this.Sl,this.Fr.localize("Options")),this.Lr.el().setAttribute("aria-label",this.Fr.localize("Open the subtitle options menu"))},this.xl=new el(s),this.jl=this._l(),this.br=_.keys(this.jl),this.Cl(),this.Al=new nl(s,this.wl),this.Fr.on("languagechange",this.te),this.Tl.addEventListener(["addtrack","removetrack"],this.Ml),this.Ml()}};function hl(t){let i=[{label:"Default",value:void 0}];for(let s of t)"Default"!==s.label&&i.push(s);return i}Ni((function(t){const i=t.oo.controlBar.getChild("SettingsButton").menu,s=i.addSubMenuItem({name:"TextTrackOptionsMenuItem"}),e=new rl(s,t.nt.aa,t.Pl.aa,t.oo);t.oo.on("dispose",(()=>{i.removeMenuItem(s),s.dispose(),e.Re(),i.dispose()}))})),d(),d();var ol=Mo.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=xi({},ol.prototype.h,{children:[]}),Mo.registerComponent("AdControlPanel",al),d(),d();var ul=Mo.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}El(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.Ho=t,this.za=i,this.te=()=>{const t=this.za.ads;t.playing&&t.currentAdBreak&&t.currentAds.length&&f(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=x.ceil(t.maxRemainingDuration);return n+=s("The content will resume in {1} seconds.").replace("{1}",""+h),n}(t.currentAdBreak,t.currentAds[0],(t=>this.Ho.localize(t))))},this.lo=t.el(),this.El(i,i.ads),this.on(t,"languagechange",this.te)}};d();var dl=Mo.getComponent("ClickableComponent"),fl=class extends dl{buildCSSClass(){return Et}createEl(t,i,s){return this.h.aa.element.querySelector("."+Et)}emitTapEvents(){}te(){f(this.el(),this.localize("Learn more"))}constructor(t,i){super(t,i),f(this.el(),t.localize("Learn more")),this.za=i.aa,this.lo=t.el(),this.on(t,"languagechange",this.te)}};Ni((function(t){if(t.aa.ads&&t.Nl){const i=t.oo,s=new ll(i,t.aa);i.adControlBar.addChild(s);if(t.aa.element.querySelector("."+Et)){const s=new fl(i,{aa:t.aa});i.adControlBar.addChild(s)}}})),d(),d();var vl=Mo.getComponent("Component"),pl=["addtrack","removetrack","change"],ml=class extends($o(vl)){createEl(){let t=super.createEl();return this.qualityLabel=Mo.createEl("div",{className:"theo-quality-label-text"}),t.appendChild(this.qualityLabel),pi(this.qualityLabel),t}dispose(){this.qr&&(this.qr.removeEventListener("activequalitychanged",this.Il),this.qr=void 0),this.ks.videoTracks.removeEventListener(pl,this.nh),super.dispose()}constructor(t,i){super(t,i),this.qr=void 0,this.nh=()=>{const t=Ha(this.ks.videoTracks);t!==this.qr&&(this.qr&&this.qr.removeEventListener("activequalitychanged",this.Il),this.qr=t,t&&t.addEventListener("activequalitychanged",this.Il),this.Il())},this.Il=()=>{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&&(f(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.ks.videoTracks&&(this.ks.videoTracks.addEventListener(pl,this.nh),this.nh())}};Mo.registerComponent("activeQualityLabel",ml),d(),d();var gl="theo-upcoming-ad-notification",yl=["adbreakbegin","adbreakend","adadded","adloaded","adbegin","adend"],bl=class extends($o(la)){createEl(){const t=Mo.createEl("div",{className:gl});return this.notificationText=Mo.createEl("div",{className:gl+"text"}),t.appendChild(this.notificationText),t}Bl(){if(!this.ks.ads)return;const t=this.ks.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))}Fl(){if(!this.ks.ads||this.ks.ads.playing||!this.currentAdBreak||!this.currentAdBreakValid||0===this.currentAdBreak.timeOffset)return void this.Dl();const t=this.ks.currentTime;if(this.currentAdBreak.timeOffset>t+10)return void this.Dl();const i=x.ceil(this.currentAdBreak.timeOffset-t);i<0?this.Dl():this.$l(i)}$l(t){this.Rl!==t&&(f(this.notificationText,"Your video will be temporarily interrupted in 0:"+(t<10?"0"+t:t)),this.Rl=t,this.show())}Dl(){this.Rl=NaN,this.hide()}dispose(){var t;this.ks.removeEventListener("timeupdate",this.handleTimeUpdate),null==(t=this.ks.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.Rl=NaN,this.handleTimeUpdate=()=>{this.Fl()},this.handleAdEvent=()=>{this.Bl(),this.Fl()},this.ks.ads&&(this.hide(),this.ks.addEventListener("timeupdate",this.handleTimeUpdate),this.ks.ads.addEventListener(yl,this.handleAdEvent))}};Mo.registerComponent("upcomingAdNotificationText",bl),d(),d();var wl=Mo.getComponent("Component");Mo.registerComponent("VerizonMediaAdBreakBar",class extends wl{createEl(){const t=h.createElement("div");return t.className="theoplayer-ad-overlay-component theo-ad-remaining-container",t}get Ol(){return this.h.adBreakProvider()}te(t,i){if(this.Ol&&this.Ol.endTime){const s=x.max(this.Ol.endTime-t,0);f(i,"Content will resume in "+x.ceil(s)+"s"),this.show()}else this.hide()}constructor(t,i){super(t,i),this.Vl=()=>{this.te(this.player().currentTime(),this.el())},this.on(t,"timeupdate",this.Vl)}}),d();var kl=Mo.getComponent("ClickableComponent");Mo.registerComponent("VerizonMediaAdSkipButton",class extends kl{createEl(){const t=h.createElement("div");return t.className="theoplayer-ad-overlay-component theoplayer-ad-skip theoplayer-ad-skip-countdown",this.Ul=h.createElement("span"),t.appendChild(this.Ul),this.te(t,this.Ul),t}handleClick(){this.h.skipCallback()}te(t,i){this.zl<=pt.Hl.Ll?(ui(t,"theoplayer-ad-skip-countdown"),oi(t,"theoplayer-ad-skip-button"),f(i,"Skip ads")):f(i,"Skip ads in "+x.ceil(this.zl)+"s")}get zl(){return this.h.adBreak.startTime+this.h.adBreak.skipOffset-this.player().currentTime()}constructor(t,i){super(t,i),this.Vl=()=>{this.te(this.el(),this.Ul)},this.on(t,"timeupdate",this.Vl)}}),d(),d();var _l=Mo.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)}};Mo.registerComponent("VerizonMediaAdBreakMarkerBar",class extends xl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-bar-adbreak"}}),d(),d();var Cl=Mo.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=x.max(this.startTime-n,0),a=void 0!==this.endTime?x.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)}};Mo.registerComponent("VerizonMediaAdBreakMarker",class extends Sl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-adbreak"}}),d();Mo.registerComponent("VerizonMediaAssetMarkerBar",class extends xl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-bar-asset"}}),d();Mo.registerComponent("VerizonMediaAssetMarker",class extends Sl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-asset"}}),d();var jl=Mo.getComponent("Component");Mo.registerComponent("VerizonMediaContentNotificationBar",class extends jl{buildCSSClass(){const t="theo-verizonmedia-content-notification-bar",i=t+"-ios";return t+(Ot.Ua||Ot.ql?" "+i:"")}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}constructor(t,i){super(t,i)}}),d();var Tl=Mo.getComponent("Component");function Ml(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])}Mo.registerComponent("VerizonMediaContentNotification",class extends Tl{get Wl(){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}fo(){const t=h.createElement("img");t.src=this.Wl.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.Wl.description);f(i,s),this.el().appendChild(i),this.Gl=h.createElement("div"),this.Gl.className=this.buildCSSClass()+"-countdown",f(this.Gl,this.Xl),this.el().appendChild(this.Gl)}get Xl(){const t=x.min(10,this.Jl);return"Starting in "+x.ceil(t)+" seconds"}get Jl(){return x.max(0,this.Wl.startTime-this.player().currentTime())}Ql(){const t=this.Jl;t>10||t<=0?this.hide():(f(this.Gl,this.Xl),this.show())}constructor(t,i){super(t,i),this.fo(),this.on(t,"timeupdate",this.Ql),this.hide()}}),d(),Pi((function(t){return class extends t{get Yl(){return this.oo.controlBar.progressControl.seekBar}la(t){this.Kl=!1,this.aa.removeEventListener("timeupdate",this.Zl),this.oo.removeChild("VerizonMediaAdBreakBar"),this.oo.removeChild("VerizonMediaAdSkipButton"),this.Yl.removeChild("VerizonMediaAdBreakMarkerBar"),this.Yl.removeChild("VerizonMediaAssetMarkerBar"),this.oo.removeChild("VerizonMediaContentNotificationBar"),super.la(t)}td(){if(!function(t){return Ml(t,"assetMarkers")}(this.sd)||!this.Kl)return;const t=this.aa.verizonMedia.assets.map((t=>({name:"VerizonMediaAssetMarker",startTime:t.startTime,endTime:t.endTime})));this.Yl.removeChild("VerizonMediaAssetMarkerBar"),this.Yl.addChild("VerizonMediaAssetMarkerBar",{children:t})}ed(){if(!function(t){return Ml(t,"contentNotification")}(this.sd))return;const t=this.aa.verizonMedia.assets.map((t=>({name:"VerizonMediaContentNotification",asset:t})));this.oo.removeChild("VerizonMediaContentNotificationBar"),this.oo.addChild("VerizonMediaContentNotificationBar",{children:t})}gn(){this.aa.removeEventListener("timeupdate",this.Zl),this.aa.verizonMedia.ads.adBreaks.removeEventListener("addadbreak",this.nd),this.aa.verizonMedia.ads.adBreaks.removeEventListener("removeadbreak",this.rd),this.aa.verizonMedia.assets.removeEventListener("addasset",this.od),this.aa.verizonMedia.assets.removeEventListener("removeasset",this.od),this.aa.removeEventListener("loadeddata",this.ad),super.gn()}constructor(t,i,s){super(t,i,s),this.Kl=!1,this.ad=()=>{this.Kl=!0,isFinite(this.ud())||this.aa.addEventListener("timeupdate",this.Zl),this.Zl(),this.td(),this.ed()},this.nd=t=>{t.adBreak.addEventListener("adbreakbegin",this.ld),t.adBreak.addEventListener("adbreakend",this.dd),this.Zl()},this.rd=t=>{t.adBreak.removeEventListener("adbreakbegin",this.ld),t.adBreak.removeEventListener("adbreakend",this.dd),this.Zl()},this.Zl=()=>{if(!function(t){return Ml(t,"adBreakMarkers")}(this.sd)||!this.Kl)return;const t=this.aa.verizonMedia.ads.adBreaks.map((t=>({name:"VerizonMediaAdBreakMarker",startTime:t.startTime,endTime:t.endTime})));this.Yl.removeChild("VerizonMediaAdBreakMarkerBar"),this.Yl.addChild("VerizonMediaAdBreakMarkerBar",{children:t})},this.ld=()=>{if(function(t){return Ml(t,"adNotification")}(this.sd)){const t=this.aa.verizonMedia.ads.currentAdBreak;this.oo.addChild("VerizonMediaAdBreakBar",{adBreakProvider:this.fd}),-1!==t.skipOffset&&this.oo.addChild("VerizonMediaAdSkipButton",{adBreak:t,skipCallback:this.aa.verizonMedia.ads.skip})}},this.fd=()=>this.aa.verizonMedia.ads.currentAdBreak,this.dd=()=>{this.oo.removeChild("VerizonMediaAdBreakBar"),this.oo.removeChild("VerizonMediaAdSkipButton")},this.od=()=>{this.td(),this.ed()},this.aa.verizonMedia.ads.adBreaks.addEventListener("addadbreak",this.nd),this.aa.verizonMedia.ads.adBreaks.addEventListener("removeadbreak",this.rd),this.aa.verizonMedia.assets.addEventListener("addasset",this.od),this.aa.verizonMedia.assets.addEventListener("removeasset",this.od),this.aa.addEventListener("loadeddata",this.ad)}}}));export{st as ChromelessPlayer,Y as ErrorCategory,J as ErrorCode,$u as Player,A as cache,jt as cast,ht as features,ct as playerSuiteVersion,dt as players,vt as registerContentProtectionIntegration,nt as utils,at as version,Mo 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,b=a.Error,w=a.TypeError,k=a.SyntaxError,_=a.Object,x=a.Math,C=a.parseInt,S=a.parseFloat,j=a.isNaN,T=a.Uint8Array;a.Worker,a.WorkerGlobalScope,a.XMLHttpRequest;import{$ as M,$a as A,A as P,Aa as E,B as N,Ba as I,C as B,Ca as F,D,Da as $,E as R,Ea as O,F as V,Fa as U,G as z,Ga as L,H,Ha as q,I as W,Ia as f,J as G,Ja as X,K as J,Ka as Q,L as Y,La as K,M as Z,Ma as tt,N as it,Na as st,O as et,Oa as nt,P as rt,Pa as ht,Q as ot,Qa as at,R as ut,Ra as ct,S as lt,Sa as dt,T as ft,Ta as vt,U as pt,Ua as mt,V as gt,Va as yt,W as bt,Wa as wt,X as kt,Xa as _t,Y as xt,Ya as Ct,Z as St,Za as jt,_ as Tt,_a as Mt,a as At,aa as Pt,ab as Et,b as Nt,ba as It,bb as Bt,c as d,ca as Ft,cb as Dt,d as $t,da as Rt,e as Ot,ea as Vt,f as Ut,fa as zt,g as Lt,ga as Ht,h as qt,ha as Wt,i as Gt,ia as Xt,j as Jt,ja as Qt,k as Yt,ka as Kt,l as Zt,la as ti,m as ii,ma as si,n as ei,na as ni,o as ri,oa as hi,p as oi,pa as ai,q as ui,qa as ci,r as li,ra as di,s as fi,sa as vi,t as pi,ta as mi,u as gi,ua as yi,v as bi,va as wi,w as ki,wa as _i,x as xi,xa as Ci,y as Si,ya as ji,z as Ti,za as Mi}from"./THEOplayer.common.esm.js";d(),d(),d(),d();var Ai=[];function Pi(t){Ai.push(t)}var Ei=[];function Ni(t){Ei.push(t)}d(),d(),d(),d();var p=void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},Ii=void 0!==h?h:{createElement:function(){}};function Bi(t,i){return i||(i=t.slice(0)),t.raw=i,t}var Fi=1;function Di(){return Fi++}var $i,Ri=_.prototype.toString,Oi=function(t){return zi(t)?_.keys(t):[]};function Vi(t,i){Oi(t).forEach((function(s){return i(t[s],s)}))}function Ui(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 _.assign?_.assign.apply(_,[t].concat(s)):(s.forEach((function(i){i&&Vi(i,(function(i,s){t[s]=i}))})),t)}function zi(t){return!!t&&"object"==typeof t}function Li(t){return zi(t)&&"[object Object]"===Ri.call(t)&&t.constructor===_}var Hi=function(t,i,s){void 0===s&&(s=!!Ls&&Ls<11),"log"!==t&&i.unshift(t.toUpperCase()+":"),$i.history.push(i),i.unshift("VIDEOJS:");var e=p.console&&p.console[t];e&&(s&&(i=i.map((function(t){if(zi(t)||Array.isArray(t))try{return JSON.stringify(t)}catch(i){return String(t)}return String(t)})).join(" ")),e.apply?e[Array.isArray(i)?"apply":"call"](p.console,i):e(i))};($i=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];Hi("log",i)}).history=[],$i.error=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Hi("error",i)},$i.warn=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Hi("warn",i)};var qi=$i,Wi="undefined"!=typeof globalThis?globalThis:void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Gi(t){return t.replace(/\n\r?\s*/g,"")}var Xi,Ji=function(t){for(var i="",s=0;s<arguments.length;s++)i+=Gi(t[s])+(arguments[s+1]||"");return i};function Qi(t){return"string"==typeof t&&/\S/.test(t)}function Yi(t){if(/\s/.test(t))throw new b("class has illegal whitespace characters")}function Ki(){return Ii===p.document&&void 0!==Ii.createElement}function Zi(t){return zi(t)&&1===t.nodeType}function ts(t){return function(i,s){if(!Qi(i))return Ii[t](null);Qi(s)&&(s=Ii.querySelector(s));var e=Zi(s)?s:Ii;return e[t]&&e[t](i)}}function is(t,i,s,e){void 0===t&&(t="div"),void 0===i&&(i={}),void 0===s&&(s={});var n=Ii.createElement(t);return _.getOwnPropertyNames(i).forEach((function(t){var s=i[t];-1!==t.indexOf("aria-")||"role"===t||"type"===t?(qi.warn(Ji(Xi||(Xi=Bi(["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?ss(n,s):n[t]=s})),_.getOwnPropertyNames(s).forEach((function(t){n.setAttribute(t,s[t])})),e&&ks(n,e),n}function ss(t,i){return void 0===t.textContent?t.innerText=i:t.textContent=i,t}function es(t,i){i.firstChild?i.insertBefore(t,i.firstChild):i.appendChild(t)}var ns={},rs="vdata"+(new Date).getTime();function hs(t){var i=t[rs];return i||(i=t[rs]=Di()),ns[i]||(ns[i]={}),ns[i]}function os(t){var i=t[rs];return!!i&&!!_.getOwnPropertyNames(ns[i]).length}function as(t){var i=t[rs];if(i){delete ns[i];try{delete t[rs]}catch(i){t.removeAttribute?t.removeAttribute(rs):t[rs]=null}}}function us(t,i){return Yi(i),t.classList?t.classList.contains(i):function(t){return new RegExp("(^|\\s)"+t+"($|\\s)")}(i).test(t.className)}function cs(t,i){return t.classList?t.classList.add(i):us(t,i)||(t.className=(t.className+" "+i).trim()),t}function ls(t,i){return t.classList?t.classList.remove(i):(Yi(i),t.className=t.className.split(/\s+/).filter((function(t){return t!==i})).join(" ")),t}function ds(t,i,s){var e=us(t,i);if("function"==typeof s&&(s=s(t,i)),"boolean"!=typeof s&&(s=!e),s!==e)return s?cs(t,i):ls(t,i),t}function fs(t,i){_.getOwnPropertyNames(i).forEach((function(s){var e=i[s];null==e||!1===e?t.removeAttribute(s):t.setAttribute(s,!0===e?"":e)}))}function vs(t){var i={};if(t&&t.attributes&&t.attributes.length>0)for(var s=t.attributes,e=s.length-1;e>=0;e--){var n=s[e].name,r=s[e].value;"boolean"!=typeof t[n]&&-1===",autoplay,controls,playsinline,loop,muted,default,defaultMuted,".indexOf(","+n+",")||(r=null!==r),i[n]=r}return i}function ps(t,i,s){t.setAttribute(i,s)}function ms(t,i){t.removeAttribute(i)}function gs(t){var i;if(t.getBoundingClientRect&&t.parentNode&&(i=t.getBoundingClientRect()),!i)return{left:0,top:0};var s=Ii.documentElement,e=Ii.body,n=s.clientLeft||e.clientLeft||0,r=p.pageXOffset||e.scrollLeft,h=i.left+r-n,o=s.clientTop||e.clientTop||0,a=p.pageYOffset||e.scrollTop,u=i.top+a-o;return{left:x.round(h),top:x.round(u)}}function ys(t,i){var s={},e=gs(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=x.max(0,x.min(1,(h-a+r)/r)),s.x=x.max(0,x.min(1,(u-o)/n)),s}function bs(t){return zi(t)&&3===t.nodeType}function ws(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function ks(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()),Zi(t)||bs(t)?t:"string"==typeof t&&/\S/.test(t)?Ii.createTextNode(t):void 0})).filter((function(t){return t}))}(i).forEach((function(i){return t.appendChild(i)})),t}function _s(t,i){return ks(ws(t),i)}var xs,Cs=ts("querySelector"),Ss=ts("querySelectorAll"),js=p.navigator&&p.navigator.userAgent||"",Ts=/AppleWebKit\/([\d.]+)/i.exec(js),Ms=Ts?S(Ts.pop()):null,As=/iPad/i.test(js),Ps=/iPhone/i.test(js)&&!As,Es=/iPod/i.test(js),Ns=Ps||As||Es,Is=(xs=js.match(/OS (\d+)_/i))&&xs[1]?xs[1]:null,Bs=/Android/i.test(js),Fs=function(){var t=js.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!t)return null;var i=t[1]&&S(t[1]),s=t[2]&&S(t[2]);return i&&s?S(t[1]+"."+t[2]):i||null}(),Ds=Bs&&/webkit/i.test(js)&&Fs<2.3,$s=Bs&&Fs<5&&Ms<537,Rs=/Firefox/i.test(js),Os=/Edge/i.test(js),Vs=!Os&&/Chrome/i.test(js),Us=function(){var t=js.match(/Chrome\/(\d+)/);return t&&t[1]?S(t[1]):null}(),zs=/MSIE\s8\.0/.test(js),Ls=function(){var t=/MSIE\s(\d+)\.\d/.exec(js),i=t&&S(t[1]);return!i&&/Trident\/7.0/i.test(js)&&/rv:11.0/.test(js)&&(i=11),i}(),Hs=/Safari/i.test(js)&&!Vs&&!Bs&&!Os,qs=Hs||Ns,Ws=Ki()&&("ontouchstart"in p||p.DocumentTouch&&p.document instanceof p.DocumentTouch),Gs=Ki()&&"backgroundSize"in p.document.createElement("video").style,Xs=_.freeze({__proto__:null,IS_IPAD:As,IS_IPHONE:Ps,IS_IPOD:Es,IS_IOS:Ns,IOS_VERSION:Is,IS_ANDROID:Bs,ANDROID_VERSION:Fs,IS_OLD_ANDROID:Ds,IS_NATIVE_ANDROID:$s,IS_FIREFOX:Rs,IS_EDGE:Os,IS_CHROME:Vs,CHROME_VERSION:Us,IS_IE8:zs,IE_VERSION:Ls,IS_SAFARI:Hs,IS_ANY_SAFARI:qs,TOUCH_ENABLED:Ws,BACKGROUND_SIZE_SUPPORTED:Gs});function Js(t,i){var s=hs(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)),_.getOwnPropertyNames(s.handlers).length<=0&&(delete s.handlers,delete s.dispatcher,delete s.disabled),0===_.getOwnPropertyNames(s).length&&as(t)}function Qs(t,i,s,e){s.forEach((function(s){t(i,s,e)}))}function Ys(t){function i(){return!0}function s(){return!1}if(!t||!t.isPropagationStopped||!t.isImmediatePropagationStopped){var e=t||p.event;for(var n in t={},e)"layerX"!==n&&"layerY"!==n&&"keyLocation"!==n&&"webkitMovementX"!==n&&"webkitMovementY"!==n&&"path"!==n&&("returnValue"===n&&e.preventDefault||(t[n]=e[n]));if(t.target||(t.target=t.srcElement||Ii),t.relatedTarget||(t.relatedTarget=t.fromElement===t.target?t.toElement:t.fromElement),t.preventDefault=function(){e.preventDefault&&e.preventDefault(),t.returnValue=!1,e.returnValue=!1,t.defaultPrevented=!0},t.defaultPrevented=!1,t.stopPropagation=function(){e.stopPropagation&&e.stopPropagation(),t.cancelBubble=!0,e.cancelBubble=!0,t.isPropagationStopped=i},t.isPropagationStopped=s,t.stopImmediatePropagation=function(){e.stopImmediatePropagation&&e.stopImmediatePropagation(),t.isImmediatePropagationStopped=i,t.stopPropagation()},t.isImmediatePropagationStopped=s,null!==t.clientX&&void 0!==t.clientX){var r=Ii.documentElement,h=Ii.body;t.pageX=t.clientX+(r&&r.scrollLeft||h&&h.scrollLeft||0)-(r&&r.clientLeft||h&&h.clientLeft||0),t.pageY=t.clientY+(r&&r.scrollTop||h&&h.scrollTop||0)-(r&&r.clientTop||h&&h.clientTop||0)}t.which=t.charCode||t.keyCode,null!==t.button&&void 0!==t.button&&(t.button=1&t.button?0:4&t.button?1:2&t.button?2:0)}return t}var Ks=!1;!function(){try{var t=_.defineProperty({},"passive",{get:function(){Ks=!0}});p.addEventListener("test",null,t)}catch(t){}}();var Zs=["touchstart","touchmove"];function te(t,i,s){if(Array.isArray(i))return Qs(te,t,i,s);var e=hs(t);if(e.handlers||(e.handlers={}),e.handlers[i]||(e.handlers[i]=[]),s.guid||(s.guid=Di()),e.handlers[i].push(s),e.dispatcher||(e.disabled=!1,e.dispatcher=function(i,s){if(!e.disabled){i=Ys(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){qi.error(t)}}}),1===e.handlers[i].length)if(t.addEventListener){var n=!1;Ks&&Zs.indexOf(i)>-1&&(n={passive:!0}),t.addEventListener(i,e.dispatcher,n)}else t.attachEvent&&t.attachEvent("on"+i,e.dispatcher)}function ie(t,i,s){if(os(t)){var e=hs(t);if(e.handlers){if(Array.isArray(i))return Qs(ie,t,i,s);var n=function(i){e.handlers[i]=[],Js(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);Js(t,i)}else n(i)}else for(var o in e.handlers)n(o)}}}function se(t,i,s){var e=os(t)?hs(t):{},n=t.parentNode||t.ownerDocument;if("string"==typeof i&&(i={type:i,target:t}),i=Ys(i),e.dispatcher&&e.dispatcher.call(t,i,s),n&&!i.isPropagationStopped()&&!0===i.bubbles)se.call(null,n,i,s);else if(!n&&!i.defaultPrevented){var r=hs(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 ee(t,i,s){if(Array.isArray(i))return Qs(ee,t,i,s);var e=function e(){ie(t,i,e),s.apply(this,arguments)};e.guid=s.guid=s.guid||Di(),te(t,i,e)}var ne,re=!1,he=function(){if(Ki()){var t=Ii.getElementsByTagName("video"),i=Ii.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){oe(1);break}void 0===u.player&&null!==u.getAttribute("data-setup")&&ne(u)}else re||oe(1)}};function oe(t,i){i&&(ne=i),p.setTimeout(he,t)}Ki()&&"complete"===Ii.readyState?re=!0:ee(p,"load",(function(){re=!0}));var ae=function(t){var i=Ii.createElement("style");return i.className=t,i},ue=function(t,i){t.styleSheet?t.styleSheet.cssText=i:t.textContent=i},ce=function(t,i,s){i.guid||(i.guid=Di());var e=function(){return i.apply(t,arguments)};return e.guid=s?s+"_"+i.guid:i.guid,e};function le(t){return"string"!=typeof t?t:t.charAt(0).toUpperCase()+t.slice(1)}function de(){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&&Vi(i,(function(i,s){Li(i)?(Li(t[s])||(t[s]={}),t[s]=de(t[s],i)):t[s]=i}))})),t}var fe=function(){function t(t,i,s){if(!t&&this.play?this.t=t=this:this.t=t,this.h=de({},this.h),i=this.h=de(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"+Di()}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 i=t.prototype;return i.dispose=function(){if(this.trigger({type:"dispose",bubbles:!1}),this.m)for(var t=this.m.length-1;t>=0;t--)this.m[t].dispose&&this.m[t].dispose();this.m=null,this.k=null,this.C=null,this.off(),this.v.parentNode&&this.v.parentNode.removeChild(this.v),as(this.v),this.v=null},i.player=function(){return this.t},i.options=function(t){return qi.warn("this.options() has been deprecated and will be moved to the constructor in 6.0"),t?(this.h=de(this.h,t),this.h):this.h},i.el=function(){return this.v},i.createEl=function(t,i,s){return is(t,i,s)},i.localize=function(t){var i=this.t.language&&this.t.language(),s=this.t.languages&&this.t.languages();if(!i||!s)return t;var e=s[i];if(e&&e[t])return e[t];var n=s[i.split("-")[0]];return n&&n[t]?n[t]:t},i.contentEl=function(){return this.S||this.v},i.id=function(){return this.o},i.name=function(){return this.l},i.children=function(){return this.m},i.getChildById=function(t){return this.k[t]},i.getChild=function(t){if(t)return t=le(t),this.C[t]},i.addChild=function(i,s,e){var n,r;if(void 0===s&&(s={}),void 0===e&&(e=this.m.length),"string"==typeof i){r=le(i),s||(s={}),!0===s&&(qi.warn("Initializing a child component with `true` is deprecated.Children should be defined in an array when possible, but if necessary use an object instead of `true`."),s={});var h=s.componentClass||r;s.name=r;var o=t.getComponent(h);if(!o)throw new b("Component "+h+" does not exist");if("function"!=typeof o)return null;n=new o(this.t||this,s)}else n=i;if(this.m.splice(e,0,n),"function"==typeof n.id&&(this.k[n.id()]=n),(r=r||n.name&&le(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},i.removeChild=function(t){if("string"==typeof t&&(t=this.getChild(t)),t&&this.m){for(var i=!1,s=this.m.length-1;s>=0;s--)if(this.m[s]===t){i=!0,this.m.splice(s,1);break}if(i){this.k[t.id()]=null,this.C[t.name()]=null;var e=t.el();e&&e.parentNode===this.contentEl()&&this.contentEl().removeChild(t.el())}}},i.initChildren=function(){var i=this,s=this.h.children;if(s){var e,n=this.h,r=t.getComponent("Tech");(e=Array.isArray(s)?s:_.keys(s)).concat(_.keys(this.h).filter((function(t){return!e.some((function(i){return"string"==typeof i?t===i:t===i.name}))}))).map((function(t){var e,n;return"string"==typeof t?n=s[e=t]||i.h[e]||{}:(e=t.name,n=t),{name:e,opts:n}})).filter((function(i){var s=t.getComponent(i.opts.componentClass||le(i.name));return s&&!r.isTech(s)})).forEach((function(t){var s=t.name,e=t.opts;if(void 0!==n[s]&&(e=n[s]),!1!==e){!0===e&&(e={}),e.playerOptions=i.h.playerOptions;var r=i.addChild(s,e);r&&(i[s]=r)}}))}},i.buildCSSClass=function(){return""},i.on=function(t,i,s){var e=this;if("string"==typeof t||Array.isArray(t))te(this.v,t,ce(this,i));else{var n=t,r=i,h=ce(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?(te(n,r,h),te(n,"dispose",a)):"function"==typeof t.on&&(n.on(r,h),n.on("dispose",a))}return this},i.off=function(t,i,s){if(!t||"string"==typeof t||Array.isArray(t))ie(this.v,t,i);else{var e=t,n=i,r=ce(this,s);this.off("dispose",r),t.nodeName?(ie(e,n,r),ie(e,"dispose",r)):(e.off(n,r),e.off("dispose",r))}return this},i.one=function(t,i,s){var e=arguments,n=this;if("string"==typeof t||Array.isArray(t))ee(this.v,t,ce(this,i));else{var r=t,h=i,o=ce(this,s),a=function t(){n.off(r,h,t),o.apply(null,e)};a.guid=o.guid,this.on(r,h,a)}return this},i.trigger=function(t,i){return se(this.v,t,i),this},i.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},i.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)},i.$=function(t,i){return Cs(t,i||this.contentEl())},i.$$=function(t,i){return Ss(t,i||this.contentEl())},i.hasClass=function(t){return us(this.v,t)},i.addClass=function(t){return cs(this.v,t),this},i.removeClass=function(t){return ls(this.v,t),this},i.toggleClass=function(t,i){return ds(this.v,t,i),this},i.show=function(){return this.removeClass("vjs-hidden"),this},i.hide=function(){return this.addClass("vjs-hidden"),this},i.lockShowing=function(){return this.addClass("vjs-lock-showing"),this},i.unlockShowing=function(){return this.removeClass("vjs-lock-showing"),this},i.getAttribute=function(t){return function(t,i){return t.getAttribute(i)}(this.v,t)},i.setAttribute=function(t,i){return ps(this.v,t,i),this},i.removeAttribute=function(t){return ms(this.v,t),this},i.width=function(t,i){return this.dimension("width",t,i)},i.height=function(t,i){return this.dimension("height",t,i)},i.dimensions=function(t,i){return this.width(t,!0).height(i)},i.dimension=function(t,i,s){if(void 0!==i)return null!==i&&i==i||(i=0),-1!==(""+i).indexOf("%")||-1!==(""+i).indexOf("px")?this.v.style[t]=i:this.v.style[t]="auto"===i?"":i+"px",s||this.trigger("resize"),this;if(!this.v)return 0;var e=this.v.style[t],n=e.indexOf("px");return C(-1!==n?e.slice(0,n):this.v["offset"+le(t)],10)},i.currentDimension=function(t){var i=0;if("width"!==t&&"height"!==t)throw new b("currentDimension only accepts width or height value");if("function"==typeof p.getComputedStyle){var s=p.getComputedStyle(this.v);i=s.getPropertyValue(t)||s[t]}if(0===(i=S(i))){var e="offset"+le(t);i=this.v[e]}return i},i.currentDimensions=function(){return{width:this.currentDimension("width"),height:this.currentDimension("height")}},i.currentWidth=function(){return this.currentDimension("width")},i.currentHeight=function(){return this.currentDimension("height")},i.focus=function(){this.v.focus()},i.blur=function(){this.v.blur()},i.emitTapEvents=function(){var t,i=0,s=null;this.on("touchstart",(function(e){1===e.touches.length&&(s={pageX:e.touches[0].pageX,pageY:e.touches[0].pageY},i=(new Date).getTime(),t=!0)})),this.on("touchmove",(function(i){if(i.touches.length>1)t=!1;else if(s){var e=i.touches[0].pageX-s.pageX,n=i.touches[0].pageY-s.pageY;x.sqrt(e*e+n*n)>10&&(t=!1)}}));var e=function(){t=!1};this.on("touchleave",e),this.on("touchcancel",e),this.on("touchend",(function(e){(s=null,!0===t)&&((new Date).getTime()-i<200&&(e.preventDefault(),this.trigger("tap")))}))},i.enableTouchActivity=function(){if(this.player()&&this.player().reportUserActivity){var t,i=ce(this.player(),this.player().reportUserActivity);this.on("touchstart",(function(){i(),this.clearInterval(t),t=this.setInterval(i,250)}));var s=function(s){i(),this.clearInterval(t)};this.on("touchmove",i),this.on("touchend",s),this.on("touchcancel",s)}},i.setTimeout=function(t,i){t=ce(this,t);var s=p.setTimeout(t,i),e=function(){this.clearTimeout(s)};return e.guid="vjs-timeout-"+s,this.on("dispose",e),s},i.clearTimeout=function(t){p.clearTimeout(t);var i=function(){};return i.guid="vjs-timeout-"+t,this.off("dispose",i),t},i.setInterval=function(t,i){t=ce(this,t);var s=p.setInterval(t,i),e=function(){this.clearInterval(s)};return e.guid="vjs-interval-"+s,this.on("dispose",e),s},i.clearInterval=function(t){p.clearInterval(t);var i=function(){};return i.guid="vjs-interval-"+t,this.off("dispose",i),t},t.registerComponent=function(i,s){if(i){if(i=le(i),t.M||(t.M={}),"Player"===i&&t.M[i]){var e=t.M[i];if(e.players&&_.keys(e.players).length>0&&_.keys(e.players).map((function(t){return e.players[t]})).every(Boolean))throw new b("Can not register Player component after player has been created")}return t.M[i]=s,s}},t.getComponent=function(i){if(i)return i=le(i),t.M&&t.M[i]?t.M[i]:p&&p.videojs&&p.videojs[i]?(qi.warn("The "+i+" component was added to the videojs object when it should be registered using videojs.registerComponent(name, component)"),p.videojs[i]):void 0},t.extend=function(i){i=i||{},qi.warn("Component.extend({}) has been deprecated, use videojs.extend(Component, {}) instead");var s=i.init||i.init||this.prototype.init||this.prototype.init||function(){},e=function(){s.apply(this,arguments)};for(var n in(e.prototype=_.create(this.prototype)).constructor=e,e.extend=t.extend,i)i.hasOwnProperty(n)&&(e.prototype[n]=i[n]);return e},t}();fe.registerComponent("Component",fe);var ve=function(){};function pe(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function me(t,i){return(me=_.setPrototypeOf?_.setPrototypeOf.bind():function(t,i){return t.__proto__=i,t})(t,i)}function ge(t,i){t.prototype=_.create(i.prototype),t.prototype.constructor=t,me(t,i)}function ye(t,i,s,e){return void 0===e&&(qi.warn("DEPRECATED: Function '"+t+"' on 'TimeRanges' called without an index argument."),e=0),function(t,i,s){if(i<0||i>s)throw new b("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 be(t){return void 0===t||0===t.length?{length:0,start:function(){throw new b("This TimeRanges object is empty")},end:function(){throw new b("This TimeRanges object is empty")}}:{length:t.length,start:ye.bind(null,"start",0,t),end:ye.bind(null,"end",1,t)}}function we(t,i){return Array.isArray(t)?be(t):void 0===t||void 0===i?be():be([[t,i]])}function ke(t,i){var s,e,n=0;if(!i)return 0;t&&t.length||(t=we(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}ve.prototype.A={},ve.prototype.on=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},te(this,t,i),this.addEventListener=s},ve.prototype.addEventListener=ve.prototype.on,ve.prototype.off=function(t,i){ie(this,t,i)},ve.prototype.removeEventListener=ve.prototype.off,ve.prototype.one=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},ee(this,t,i),this.addEventListener=s},ve.prototype.trigger=function(t){var i=t.type||t;"string"==typeof t&&(t={type:i}),t=Ys(t),this.A[i]&&this["on"+i]&&this["on"+i](t),se(this,t)},ve.prototype.dispatchEvent=ve.prototype.trigger;var _e,xe,Ce,Se,je={prefixed:!0},Te=[["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"]],Me=Te[0];for(xe=0;xe<Te.length;xe++)if(Te[xe][1]in Ii){_e=Te[xe];break}if(_e){for(Ce=0;Ce<_e.length;Ce++)je[Me[Ce]]=_e[Ce];je.prefixed=_e[0]!==Me[0]}function Ae(t){if(t instanceof Ae)return t;"number"==typeof t?this.code=t:"string"==typeof t?this.message=t:zi(t)&&("number"==typeof t.code&&(this.code=t.code),Ui(this,t)),this.message||(this.message=Ae.defaultMessages[this.code]||"")}for(Ae.prototype.code=0,Ae.prototype.message="",Ae.prototype.status=null,Ae.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],Ae.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."},Se=0;Se<Ae.errorTypes.length;Se++)Ae[Ae.errorTypes[Se]]=Se,Ae.prototype[Ae.errorTypes[Se]]=Se;var Pe=function(t,i){var s,e=null;try{s=JSON.parse(t,i)}catch(t){e=t}return[e,s]};var Ee=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}}))})},Ne=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=Ee(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(Ee))},Ie=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()},Be="vjs-modal-dialog",Fe=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).P=e.N=e.I=!1,e.closeable(!e.h.uncloseable),e.content(e.h.content),e.S=is("div",{className:Be+"-content"},{role:"document"}),e.B=is("p",{className:Be+"-description vjs-offscreen",id:e.el().getAttribute("aria-describedby")}),ss(e.B,e.description()),e.v.appendChild(e.B),e.v.appendChild(e.S),e.on(i,"languagechange",e.handleLanguagechange),e}ge(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 Be+" 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.I)&&this.fill(),this.D=!t.paused(),this.h.pauseOnOpen&&this.D&&t.pause(),this.closeable()&&this.on(this.v.ownerDocument,"keydown",ce(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",ce(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.I=!0,s.removeChild(i),this.empty(),_s(i,t),this.trigger("modalfill"),e?s.insertBefore(i,e):s.appendChild(i),this},s.empty=function(){return this.trigger("beforemodalempty"),ws(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()),ss(this.B,this.description()),this.opened()?this.fill():(this.N||this.I)&&(this.N=!1,this.I=!1,this.empty())},i}(fe);Fe.prototype.h={pauseOnOpen:!0,temporary:!0},fe.registerComponent("ModalDialog",Fe);var De=function(){function t(i){var s=this;if(zs)for(var e in s=Ii.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);if(t.prototype.V.call(s,i),_.defineProperty(s,"length",{get:function(){return this.U}}),zs)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||_.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}(),$e={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},Re={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},Oe={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},Ve={disabled:"disabled",hidden:"hidden",showing:"showing"},Ue=function(t){function i(s){var e;void 0===s&&(s={});var n=pe(e=t.call(this)||this);if(zs)for(var r in n=Ii.createElement("custom"),i.prototype)"constructor"!==r&&(n[r]=i.prototype[r]);var h={id:s.id||["vjs_track",Di()].join("_"),kind:s.kind||"",label:s.label||"",language:s.language||""},o=function(t){_.defineProperty(n,t,{get:function(){return h[t]},set:function(){}})};for(var a in h)o(a);return n||pe(e)}return ge(i,t),i}(ve),ze=function(t){var i=["protocol","hostname","port","pathname","search","hash","host"],s=Ii.createElement("a");s.href=t;var e,n=""===s.host&&"file:"!==s.protocol;n&&((e=Ii.createElement("div")).innerHTML='<a href="'+t+'"></a>',s=e.firstChild,e.setAttribute("style","display:none; position:absolute;"),Ii.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&&Ii.body.removeChild(e),r},Le=function(t){var i=p.location,s=ze(t);return(":"===s.protocol?i.protocol:s.protocol)+s.host!==i.protocol+i.host},He={exports:{}};void 0!==s?He.exports=s:void 0!==Wi?He.exports=Wi:"undefined"!=typeof self?He.exports=self:He.exports={};var qe=function(t){var i=We.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)},We=_.prototype.toString;var Ge,Xe,Je,Qe,Ye,Ke,Ze,tn,sn,en,nn,rn,hn=Array.prototype.slice,on=_.prototype.toString,an=function(t){var i=this;if("function"!=typeof i||"[object Function]"!==on.call(i))throw new w("Function.prototype.bind called on incompatible "+i);for(var s,e=hn.call(arguments,1),n=x.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(hn.call(arguments)));return _(n)===n?n:this}return i.apply(t,e.concat(hn.call(arguments)))})),i.prototype){var o=function(){};o.prototype=i.prototype,s.prototype=new o,o.prototype=null}return s},un=Function.prototype.bind||an,cn=_.prototype.toString,ln=function(t){var i=cn.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]"===cn.call(t.callee)),s};_.keys||(Xe=_.prototype.hasOwnProperty,Je=_.prototype.toString,Qe=ln,Ye=_.prototype.propertyIsEnumerable,Ke=!Ye.call({toString:null},"toString"),Ze=Ye.call((function(){}),"prototype"),tn=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],sn=function(t){var i=t.constructor;return i&&i.prototype===t},en={$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},nn=function(){if(void 0===s)return!1;for(var t in s)try{if(!en["$"+t]&&Xe.call(s,t)&&null!==s[t]&&"object"==typeof s[t])try{sn(s[t])}catch(t){return!0}}catch(t){return!0}return!1}(),rn=function(t){if(void 0===s||!nn)return sn(t);try{return sn(t)}catch(t){return!1}},Ge=function(t){var i=null!==t&&"object"==typeof t,s="[object Function]"===Je.call(t),e=Qe(t),n=i&&"[object String]"===Je.call(t),r=[];if(!i&&!s&&!e)throw new w("Object.keys called on a non-object");var h=Ze&&s;if(n&&t.length>0&&!Xe.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||!Xe.call(t,u)||r.push(String(u));if(Ke)for(var c=rn(t),l=0;l<tn.length;++l)c&&"constructor"===tn[l]||!Xe.call(t,tn[l])||r.push(tn[l]);return r});var dn=Ge,fn=Array.prototype.slice,vn=ln,pn=_.keys,mn=pn?function(t){return pn(t)}:dn,gn=_.keys;mn.shim=function(){if(_.keys){var t=function(){var t=_.keys(arguments);return t&&t.length===arguments.length}(1,2);t||(_.keys=function(t){return vn(t)?gn(fn.call(t)):gn(t)})}else _.keys=mn;return _.keys||mn};var yn=mn,bn="function"==typeof At&&"symbol"==typeof At("foo"),wn=_.prototype.toString,kn=Array.prototype.concat,_n=_.defineProperty,xn=_n&&function(){var t={};try{for(var i in _n(t,"x",{enumerable:!1,value:t}),t)return!1;return t.x===t}catch(t){return!1}}(),Cn=function(t,i,s,e){(!(i in t)||function(t){return"function"==typeof t&&"[object Function]"===wn.call(t)}(e)&&e())&&(xn?_n(t,i,{configurable:!0,enumerable:!1,value:s,writable:!0}):t[i]=s)},Sn=function(t,i){var s=arguments.length>2?arguments[2]:{},e=yn(i);bn&&(e=kn.call(e,_.getOwnPropertySymbols(i)));for(var n=0;n<e.length;n+=1)Cn(t,e[n],i[e[n]],s[e[n]])};Sn.supportsDescriptors=!!xn;var jn,Tn=Sn,Mn=_.getOwnPropertyDescriptor?function(){return _.getOwnPropertyDescriptor(arguments,"callee").get}():function(){throw new w},An="function"==typeof At&&"symbol"==typeof Nt,Pn=_.getPrototypeOf||function(t){return t.__proto__},En=void 0===T?jn:Pn(T),Nn={"$ %Array%":Array,"$ %ArrayBuffer%":"undefined"==typeof ArrayBuffer?jn:ArrayBuffer,"$ %ArrayBufferPrototype%":"undefined"==typeof ArrayBuffer?jn:ArrayBuffer.prototype,"$ %ArrayIteratorPrototype%":An?Pn([][Nt]()):jn,"$ %ArrayPrototype%":Array.prototype,"$ %ArrayProto_entries%":Array.prototype.entries,"$ %ArrayProto_forEach%":Array.prototype.forEach,"$ %ArrayProto_keys%":Array.prototype.keys,"$ %ArrayProto_values%":Array.prototype.values,"$ %AsyncFromSyncIteratorPrototype%":jn,"$ %AsyncFunction%":undefined,"$ %AsyncFunctionPrototype%":jn,"$ %AsyncGenerator%":jn,"$ %AsyncGeneratorFunction%":undefined,"$ %AsyncGeneratorPrototype%":jn,"$ %AsyncIteratorPrototype%":jn,"$ %Atomics%":"undefined"==typeof Atomics?jn:Atomics,"$ %Boolean%":Boolean,"$ %BooleanPrototype%":Boolean.prototype,"$ %DataView%":"undefined"==typeof DataView?jn:DataView,"$ %DataViewPrototype%":"undefined"==typeof DataView?jn:DataView.prototype,"$ %Date%":Date,"$ %DatePrototype%":Date.prototype,"$ %decodeURI%":decodeURI,"$ %decodeURIComponent%":decodeURIComponent,"$ %encodeURI%":encodeURI,"$ %encodeURIComponent%":encodeURIComponent,"$ %Error%":b,"$ %ErrorPrototype%":b.prototype,"$ %eval%":eval,"$ %EvalError%":EvalError,"$ %EvalErrorPrototype%":EvalError.prototype,"$ %Float32Array%":"undefined"==typeof Float32Array?jn:Float32Array,"$ %Float32ArrayPrototype%":"undefined"==typeof Float32Array?jn:Float32Array.prototype,"$ %Float64Array%":"undefined"==typeof Float64Array?jn:Float64Array,"$ %Float64ArrayPrototype%":"undefined"==typeof Float64Array?jn:Float64Array.prototype,"$ %Function%":Function,"$ %FunctionPrototype%":Function.prototype,"$ %Generator%":jn,"$ %GeneratorFunction%":undefined,"$ %GeneratorPrototype%":jn,"$ %Int8Array%":"undefined"==typeof Int8Array?jn:Int8Array,"$ %Int8ArrayPrototype%":"undefined"==typeof Int8Array?jn:Int8Array.prototype,"$ %Int16Array%":"undefined"==typeof Int16Array?jn:Int16Array,"$ %Int16ArrayPrototype%":"undefined"==typeof Int16Array?jn:Int8Array.prototype,"$ %Int32Array%":"undefined"==typeof Int32Array?jn:Int32Array,"$ %Int32ArrayPrototype%":"undefined"==typeof Int32Array?jn:Int32Array.prototype,"$ %isFinite%":isFinite,"$ %isNaN%":j,"$ %IteratorPrototype%":An?Pn(Pn([][Nt]())):jn,"$ %JSON%":JSON,"$ %JSONParse%":JSON.parse,"$ %Map%":"undefined"==typeof Map?jn:Map,"$ %MapIteratorPrototype%":"undefined"!=typeof Map&&An?Pn((new Map)[Nt]()):jn,"$ %MapPrototype%":"undefined"==typeof Map?jn:Map.prototype,"$ %Math%":x,"$ %Number%":Number,"$ %NumberPrototype%":Number.prototype,"$ %Object%":_,"$ %ObjectPrototype%":_.prototype,"$ %ObjProto_toString%":_.prototype.toString,"$ %ObjProto_valueOf%":_.prototype.valueOf,"$ %parseFloat%":S,"$ %parseInt%":C,"$ %Promise%":"undefined"==typeof Promise?jn:Promise,"$ %PromisePrototype%":"undefined"==typeof Promise?jn:Promise.prototype,"$ %PromiseProto_then%":"undefined"==typeof Promise?jn:Promise.prototype.then,"$ %Promise_all%":"undefined"==typeof Promise?jn:Promise.all,"$ %Promise_reject%":"undefined"==typeof Promise?jn:Promise.reject,"$ %Promise_resolve%":"undefined"==typeof Promise?jn:Promise.resolve,"$ %Proxy%":"undefined"==typeof Proxy?jn:Proxy,"$ %RangeError%":RangeError,"$ %RangeErrorPrototype%":RangeError.prototype,"$ %ReferenceError%":ReferenceError,"$ %ReferenceErrorPrototype%":ReferenceError.prototype,"$ %Reflect%":"undefined"==typeof Reflect?jn:Reflect,"$ %RegExp%":RegExp,"$ %RegExpPrototype%":RegExp.prototype,"$ %Set%":"undefined"==typeof Set?jn:Set,"$ %SetIteratorPrototype%":"undefined"!=typeof Set&&An?Pn((new Set)[Nt]()):jn,"$ %SetPrototype%":"undefined"==typeof Set?jn:Set.prototype,"$ %SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?jn:SharedArrayBuffer,"$ %SharedArrayBufferPrototype%":"undefined"==typeof SharedArrayBuffer?jn:SharedArrayBuffer.prototype,"$ %String%":String,"$ %StringIteratorPrototype%":An?Pn(""[Nt]()):jn,"$ %StringPrototype%":String.prototype,"$ %Symbol%":An?At:jn,"$ %SymbolPrototype%":An?At.prototype:jn,"$ %SyntaxError%":k,"$ %SyntaxErrorPrototype%":k.prototype,"$ %ThrowTypeError%":Mn,"$ %TypedArray%":En,"$ %TypedArrayPrototype%":En?En.prototype:jn,"$ %TypeError%":w,"$ %TypeErrorPrototype%":w.prototype,"$ %Uint8Array%":void 0===T?jn:T,"$ %Uint8ArrayPrototype%":void 0===T?jn:T.prototype,"$ %Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?jn:Uint8ClampedArray,"$ %Uint8ClampedArrayPrototype%":"undefined"==typeof Uint8ClampedArray?jn:Uint8ClampedArray.prototype,"$ %Uint16Array%":"undefined"==typeof Uint16Array?jn:Uint16Array,"$ %Uint16ArrayPrototype%":"undefined"==typeof Uint16Array?jn:Uint16Array.prototype,"$ %Uint32Array%":"undefined"==typeof Uint32Array?jn:Uint32Array,"$ %Uint32ArrayPrototype%":"undefined"==typeof Uint32Array?jn:Uint32Array.prototype,"$ %URIError%":URIError,"$ %URIErrorPrototype%":URIError.prototype,"$ %WeakMap%":"undefined"==typeof WeakMap?jn:WeakMap,"$ %WeakMapPrototype%":"undefined"==typeof WeakMap?jn:WeakMap.prototype,"$ %WeakSet%":"undefined"==typeof WeakSet?jn:WeakSet,"$ %WeakSetPrototype%":"undefined"==typeof WeakSet?jn:WeakSet.prototype},In=function(t,i){if(arguments.length>1&&"boolean"!=typeof i)throw new w('"allowMissing" argument must be a boolean');var s="$ "+t;if(!(s in Nn))throw new k("intrinsic "+t+" does not exist!");if(void 0===Nn[s]&&!i)throw new w("intrinsic "+t+" exists, but is not available. Please file an issue!");return Nn[s]},Bn=un.call(Function.call,_.prototype.hasOwnProperty),Fn=In,Dn=Fn("%TypeError%"),$n=Fn("%SyntaxError%"),Rn=Bn,On={"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(Rn(i,e)&&!s[e])return!1;var n=Rn(i,"[[Value]]"),r=Rn(i,"[[Get]]")||Rn(i,"[[Set]]");if(n&&r)throw new Dn("Property Descriptors may not be both accessor and data descriptors");return!0}},Vn=Number.isNaN||function(t){return t!=t},Un=Number.isNaN||function(t){return t!=t},zn=Number.isFinite||function(t){return"number"==typeof t&&!Un(t)&&t!==1/0&&t!==-1/0},Ln=Function.prototype.toString,Hn=/^\s*class\b/,qn=function(t){try{var i=Ln.call(t);return Hn.test(i)}catch(t){return!1}},Wn=_.prototype.toString,Gn="function"==typeof At&&"symbol"==typeof At.toStringTag,Xn=function(t){if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if("function"==typeof t&&!t.prototype)return!0;if(Gn)return function(t){try{return!qn(t)&&(Ln.call(t),!0)}catch(t){return!1}}(t);if(qn(t))return!1;var i=Wn.call(t);return"[object Function]"===i||"[object GeneratorFunction]"===i},Jn=_.prototype.toString,Qn=function(t){return null===t||"function"!=typeof t&&"object"!=typeof t},Yn=Xn,Kn=function(t){var i;if((i=arguments.length>1?arguments[1]:"[object Date]"===Jn.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(Yn(t[n[e]])&&(s=t[n[e]](),Qn(s)))return s;throw new w("No default value")}throw new w("invalid [[DefaultValue]] hint supplied")},Zn=In,tr=Zn("%Object%"),ir=Zn("%TypeError%"),sr=Zn("%String%"),er=function(t,i,s,e){var n=On[i];if("function"!=typeof n)throw new $n("unknown record type: "+i);if(!n(t,e))throw new Dn(s+" must be a "+i);console.log(n(t,e),e)},nr=Vn,rr=zn,hr=function(t){return t>=0?1:-1},or=function(t,i){var s=t%i;return x.floor(s>=0?s:s+i)},ar=Bn,ur={ToPrimitive:function(t){return Qn(t)?t:arguments.length>1?Kn(t,arguments[1]):Kn(t)},ToBoolean:function(t){return!!t},ToNumber:function(t){return+t},ToInteger:function(t){var i=this.ToNumber(t);return nr(i)?0:0!==i&&rr(i)?hr(i)*x.floor(x.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(nr(i)||0===i||!rr(i))return 0;var s=hr(i)*x.floor(x.abs(i));return or(s,65536)},ToString:function(t){return sr(t)},ToObject:function(t){return this.CheckObjectCoercible(t),tr(t)},CheckObjectCoercible:function(t,i){if(null==t)throw new ir(i||"Cannot call method on "+t);return t},IsCallable:Xn,SameValue:function(t,i){return t===i?0!==t||1/t==1/i:nr(t)&&nr(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(ar(t,s)&&!i[s])return!1;var e=ar(t,"[[Value]]"),n=ar(t,"[[Get]]")||ar(t,"[[Set]]");if(e&&n)throw new ir("Property Descriptors may not be both accessor and data descriptors");return!0},IsAccessorDescriptor:function(t){return void 0!==t&&(er(this,"Property Descriptor","Desc",t),!(!ar(t,"[[Get]]")&&!ar(t,"[[Set]]")))},IsDataDescriptor:function(t){return void 0!==t&&(er(this,"Property Descriptor","Desc",t),!(!ar(t,"[[Value]]")&&!ar(t,"[[Writable]]")))},IsGenericDescriptor:function(t){return void 0!==t&&(er(this,"Property Descriptor","Desc",t),!this.IsAccessorDescriptor(t)&&!this.IsDataDescriptor(t))},FromPropertyDescriptor:function(t){if(void 0===t)return t;if(er(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 ir("FromPropertyDescriptor must be called with a fully populated Property Descriptor")},ToPropertyDescriptor:function(t){if("Object"!==this.Type(t))throw new ir("ToPropertyDescriptor requires an object");var i={};if(ar(t,"enumerable")&&(i["[[Enumerable]]"]=this.ToBoolean(t.enumerable)),ar(t,"configurable")&&(i["[[Configurable]]"]=this.ToBoolean(t.configurable)),ar(t,"value")&&(i["[[Value]]"]=t.value),ar(t,"writable")&&(i["[[Writable]]"]=this.ToBoolean(t.writable)),ar(t,"get")){var s=t.get;if(void 0!==s&&!this.IsCallable(s))throw new w("getter must be a function");i["[[Get]]"]=s}if(ar(t,"set")){var e=t.set;if(void 0!==e&&!this.IsCallable(e))throw new ir("setter must be a function");i["[[Set]]"]=e}if((ar(i,"[[Get]]")||ar(i,"[[Set]]"))&&(ar(i,"[[Value]]")||ar(i,"[[Writable]]")))throw new ir("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return i}},cr=un.call(Function.call,String.prototype.replace),lr=/^[\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]+/,dr=/[\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]+$/,fr=function(){var t=ur.ToString(ur.CheckObjectCoercible(this));return cr(cr(t,lr,""),dr,"")},vr=fr,pr=function(){return String.prototype.trim&&"\u200b"==="\u200b".trim()?String.prototype.trim:vr},mr=Tn,gr=pr,yr=Tn,br=fr,wr=pr,kr=function(){var t=gr();return mr(String.prototype,{trim:t},{trim:function(){return String.prototype.trim!==t}}),t},_r=un.call(Function.call,wr());yr(_r,{getPolyfill:wr,implementation:br,shim:kr});var xr=_r,Cr=Xn,Sr=_.prototype.toString,jr=_.prototype.hasOwnProperty,Tr=xr,Mr=function(t,i,s){if(!Cr(i))throw new w("iterator must be a function");var e;arguments.length>=3&&(e=s),"[object Array]"===Sr.call(t)?function(t,i,s){for(var e=0,n=t.length;e<n;e++)jr.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)jr.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))}(t,i,e)},Ar=function(){for(var t={},i=0;i<arguments.length;i++){var s=arguments[i];for(var e in s)Pr.call(s,e)&&(t[e]=s[e])}return t},Pr=_.prototype.hasOwnProperty;var Er=He.exports,Nr=qe,Ir=function(t){if(!t)return{};var i={};return Mr(Tr(t).split("\n"),(function(t){var s=t.indexOf(":"),e=Tr(t.slice(0,s)).toLowerCase(),n=Tr(t.slice(s+1));void 0===i[e]?i[e]=n:!function(t){return"[object Array]"===_.prototype.toString.call(t)}(i[e])?i[e]=[i[e],n]:i[e].push(n)})),i},Br=Ar,Fr=$r;function Dr(t,i,s){var e=t;return Nr(i)?(s=i,"string"==typeof t&&(e={uri:t})):e=Br(i,{uri:t}),e.callback=s,e}function $r(t,i,s){return Rr(i=Dr(t,i,s))}function Rr(t){if(void 0===t.callback)throw new b("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),y)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 b||(t=new b(""+(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=Ir(l.getAllResponseHeaders()))):h=new b("Internal XMLHttpRequest Error"),s(h,r,r.body)}}var o,a,l=t.xhr||null;l||(l=t.cors||t.useXDR?new $r.XDomainRequest:new $r.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||{},g=!!t.sync,y=!1;if("json"in t&&(y=!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,!g,t.username,t.password),g||(l.withCredentials=!!t.withCredentials),!g&&t.timeout>0&&(d=u((function(){a=!0,l.abort("timeout");var t=new b("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 b("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}$r.XMLHttpRequest=Er.XMLHttpRequest||function(){},$r.XDomainRequest="withCredentials"in new $r.XMLHttpRequest?$r.XMLHttpRequest:Er.XDomainRequest,function(t,i){for(var s=0;s<t.length;s++)i(t[s])}(["get","put","post","patch","head","delete"],(function(t){$r["delete"===t?"del":t]=function(i,s,e){return(s=Dr(i,s,e)).method=t.toUpperCase(),Rr(s)}}));var Or=function(t,i){var s=new p.WebVTT.Parser(p,p.vttjs,p.WebVTT.StringDecoder()),e=[];s.oncue=function(t){i.addCue(t)},s.onparsingerror=function(t){e.push(t)},s.onflush=function(){i.trigger({type:"loadeddata",target:i})},s.parse(t),e.length>0&&(p.console&&p.console.groupCollapsed&&p.console.groupCollapsed("Text Track parsing errors for "+i.src),e.forEach((function(t){return qi.error(t)})),p.console&&p.console.groupEnd&&p.console.groupEnd()),s.flush()},Vr=function(t){function i(s){var e;if(void 0===s&&(s={}),!s.tech)throw new b("A tech was not provided.");var n=de(s,{kind:Oe[s.kind]||"subtitles",language:s.language||s.srclang||""}),r=Ve[n.mode]||"disabled",h=n.default;"metadata"!==n.kind&&"chapters"!==n.kind||(r="hidden");var o=e=t.call(this,n)||this;if(o.H=n.tech,zs)for(var a in i.prototype)"constructor"!==a&&(o[a]=i.prototype[a]);o.L=[],o.q=[];var u=new De(o.L),c=new De(o.q),l=!1,d=ce(o,(function(){this.activeCues,l&&(this.trigger("cuechange"),l=!1)}));return"disabled"!==r&&o.H.ready((function(){o.H.on("timeupdate",d)}),!0),_.defineProperty(o,"default",{get:function(){return h},set:function(){}}),_.defineProperty(o,"mode",{get:function(){return r},set:function(t){var i=this;Ve[t]&&("showing"===(r=t)&&this.H.ready((function(){i.H.on("timeupdate",d)}),!0),this.trigger("modechange"))}}),_.defineProperty(o,"cues",{get:function(){return this.W?u:null},set:function(){}}),_.defineProperty(o,"activeCues",{get:function(){if(!this.W)return null;if(0===this.cues.length)return c;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(l=!1,i.length!==this.q.length)l=!0;else for(var r=0;r<i.length;r++)-1===this.q.indexOf(i[r])&&(l=!0);return this.q=i,c.V(this.q),c},set:function(){}}),n.src?(o.src=n.src,function(t,i){var s={uri:t},e=Le(t);e&&(s.cors=e),Fr(s,ce(this,(function(t,s,e){if(t)return qi.error(t,s);if(i.W=!0,"function"!=typeof p.WebVTT){if(i.H){var n=function(){return Or(e,i)};i.H.on("vttjsloaded",n),i.H.on("vttjserror",(function(){qi.error("vttjs failed to load, stopping trying to process "+i.src),i.H.off("vttjsloaded",n)}))}}else Or(e,i)})))}(n.src,o)):o.W=!0,o||pe(e)}ge(i,t);var s=i.prototype;return s.addCue=function(t){var i=t;if(p.vttjs&&!(t instanceof p.vttjs.VTTCue)){for(var s in i=new p.vttjs.VTTCue(t.startTime,t.endTime,t.text),t)s in i||(i[s]=t[s]);i.id=t.id,i.G=t}var e=this.H.textTracks();if(e)for(var n=0;n<e.length;n++)e[n]!==this&&e[n].removeCue(i);this.L.push(i),this.cues.V(this.L)},s.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}}},i}(Ue);Vr.prototype.A={cuechange:"cuechange"};var Ur=function(t){function i(s){var e,n;void 0===s&&(s={});var r=pe(e=t.call(this)||this);if(zs)for(var h in r=Ii.createElement("custom"),i.prototype)"constructor"!==h&&(r[h]=i.prototype[h]);var o=new Vr(s);return r.kind=o.kind,r.src=o.src,r.srclang=o.language,r.label=o.label,r.default=o.default,_.defineProperty(r,"readyState",{get:function(){return n}}),_.defineProperty(r,"track",{get:function(){return o}}),n=0,o.addEventListener("loadeddata",(function(){n=2,r.trigger({type:"load",target:r})})),zs?r||pe(e):e}return ge(i,t),i}(ve);Ur.prototype.A={load:"load"},Ur.NONE=0,Ur.LOADING=1,Ur.LOADED=2,Ur.ERROR=3;var zr,Lr=function(){function t(i){void 0===i&&(i=[]);var s=this;if(zs)for(var e in s=Ii.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);s.X=[],_.defineProperty(s,"length",{get:function(){return this.X.length}});for(var n=0,r=i.length;n<r;n++)s.J(i[n]);if(zs)return s}var i=t.prototype;return i.J=function(t){var i=this.X.length;""+i in this||_.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}(),Hr=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=pe(n),zs))for(var r in e=Ii.createElement("custom"),i.prototype)"constructor"!==r&&(e[r]=i.prototype[r]);e.Z=[],_.defineProperty(e,"length",{get:function(){return this.Z.length}});for(var h=0;h<s.length;h++)e.tt(s[h]);return e||pe(n)}ge(i,t);var s=i.prototype;return s.tt=function(t){var i=this.Z.length;""+i in this||_.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}(ve);for(zr in Hr.prototype.A={change:"change",addtrack:"addtrack",removetrack:"removetrack"},Hr.prototype.A)Hr.prototype["on"+zr]=null;var qr=function(t){function i(s){var e,n;if(void 0===s&&(s=[]),zs){for(var r in n=Ii.createElement("custom"),Hr.prototype)"constructor"!==r&&(n[r]=Hr.prototype[r]);for(var h in i.prototype)"constructor"!==h&&(n[h]=i.prototype[h])}return(n=e=t.call(this,s,n)||this)||pe(e)}return ge(i,t),i.prototype.tt=function(i){t.prototype.tt.call(this,i),i.addEventListener("modechange",ce(this,(function(){this.trigger("change")})))},i}(Hr),Wr=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].selected=!1)},Gr=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){Wr(s,s[r]);break}if(zs){for(var h in n=Ii.createElement("custom"),Hr.prototype)"constructor"!==h&&(n[h]=Hr.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,_.defineProperty(n,"selectedIndex",{get:function(){for(var t=0;t<this.length;t++)if(this[t].selected)return t;return-1},set:function(){}}),n||pe(e)}ge(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.selected&&Wr(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("selectedchange",(function(){s.st||(s.st=!0,Wr(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}(Hr),Xr=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].enabled=!1)},Jr=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){Xr(s,s[r]);break}if(zs){for(var h in n=Ii.createElement("custom"),Hr.prototype)"constructor"!==h&&(n[h]=Hr.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||pe(e)}ge(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.enabled&&Xr(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("enabledchange",(function(){s.st||(s.st=!0,Xr(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}(Hr),Qr=void 0;var Yr=function(t){function i(i,s){var e;return void 0===i&&(i={}),void 0===s&&(s=function(){}),i.reportTouchActivity=!1,(e=t.call(this,null,i,s)||this).et=!1,e.on("playing",(function(){this.et=!0})),e.on("loadstart",(function(){this.et=!1})),e.nt=i.textTracks,e.rt=i.videoTracks,e.ht=i.audioTracks,e.featuresProgressEvents||e.manualProgressOn(),e.featuresTimeupdateEvents||e.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach((function(t){!1===i["native"+t+"Tracks"]&&(e["featuresNative"+t+"Tracks"]=!1)})),!1===i.nativeCaptions&&(e.featuresNativeTextTracks=!1),e.featuresNativeTextTracks||e.emulateTextTracks(),e.ot=new qr,e.initTextTrackListeners(),e.initTrackListeners(),i.nativeControlsForTouch||e.emitTapEvents(),e.constructor&&(e.l=e.constructor.name||"Unknown Tech"),e}ge(i,t);var s=i.prototype;return s.manualProgressOn=function(){this.on("durationchange",this.onDurationChange),this.manualProgress=!0,this.one("ready",this.trackProgress)},s.manualProgressOff=function(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange)},s.trackProgress=function(t){this.stopTrackingProgress(),this.progressInterval=this.setInterval(ce(this,(function(){var t=this.bufferedPercent();this.ut!==t&&this.trigger("progress"),this.ut=t,1===t&&this.stopTrackingProgress()})),500)},s.onDurationChange=function(t){this.ct=this.duration()},s.buffered=function(){return we(0,0)},s.bufferedPercent=function(){return ke(this.buffered(),this.ct)},s.stopTrackingProgress=function(){this.clearInterval(this.progressInterval)},s.manualTimeUpdatesOn=function(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime),this.on("pause",this.stopTrackingCurrentTime)},s.manualTimeUpdatesOff=function(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime),this.off("pause",this.stopTrackingCurrentTime)},s.trackCurrentTime=function(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval((function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}),250)},s.stopTrackingCurrentTime=function(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},s.dispose=function(){this.clearTracks(["audio","video","text"]),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),t.prototype.dispose.call(this)},s.clearTracks=function(t){var i=this;(t=[].concat(t)).forEach((function(t){for(var s=i[t+"Tracks"]()||[],e=s.length;e--;){var n=s[e];"text"===t&&i.removeRemoteTextTrack(n),s.it(n)}}))},s.cleanupAutoTextTracks=function(){for(var t=this.ot||[],i=t.length;i--;){var s=t[i];this.removeRemoteTextTrack(s)}},s.reset=function(){},s.error=function(t){return void 0!==t&&(this.lt=new Ae(t),this.trigger("error")),this.lt},s.played=function(){return this.et?we(0,0):we()},s.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},s.initTextTrackListeners=function(){var t=ce(this,(function(){this.trigger("texttrackchange")})),i=this.textTracks();i&&(i.addEventListener("removetrack",t),i.addEventListener("addtrack",t),this.on("dispose",ce(this,(function(){i.removeEventListener("removetrack",t),i.removeEventListener("addtrack",t)}))))},s.initTrackListeners=function(){var t=this;["video","audio"].forEach((function(i){var s=function(){t.trigger(i+"trackchange")},e=t[i+"Tracks"]();e.addEventListener("removetrack",s),e.addEventListener("addtrack",s),t.on("dispose",(function(){e.removeEventListener("removetrack",s),e.removeEventListener("addtrack",s)}))}))},s.dt=function(){var t=this;if(!p.WebVTT)if(Ii.body.contains(this.el())){if(!this.h["vtt.js"]&&Li(Qr)&&_.keys(Qr).length>0)return void this.trigger("vttjsloaded");var i=Ii.createElement("script");i.src=this.h["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.12.4/vtt.min.js",i.onload=function(){t.trigger("vttjsloaded")},i.onerror=function(){t.trigger("vttjserror")},this.on("dispose",(function(){i.onload=null,i.onerror=null})),p.WebVTT=!0,this.el().parentNode.appendChild(i)}else this.ready(this.dt)},s.emulateTextTracks=function(){var t=this,i=this.textTracks();if(i){var s=this.remoteTextTracks(),e=function(t){return i.tt(t.track)},n=function(t){return i.it(t.track)};s.on("addtrack",e),s.on("removetrack",n),this.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)}}))}},s.videoTracks=function(){return this.rt=this.rt||new Gr,this.rt},s.audioTracks=function(){return this.ht=this.ht||new Jr,this.ht},s.textTracks=function(){return this.nt=this.nt||new qr,this.nt},s.remoteTextTracks=function(){return this.ft=this.ft||new qr,this.ft},s.remoteTextTrackEls=function(){return this.vt=this.vt||new Lr,this.vt},s.addTextTrack=function(t,i,s){if(!t)throw new b("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 Vr(n);return r.tt(h),h}(this,t,i,s)},s.createRemoteTextTrack=function(t){var i=de(t,{tech:this});return new Ur(i)},s.addRemoteTextTrack=function(t,i){void 0===t&&(t={});var s=this.createRemoteTextTrack(t);return!0!==i&&!1!==i&&(qi.warn('Calling addRemoteTextTrack without explicitly setting the "manualCleanup" parameter to `true` is deprecated and default to `false` in future version of video.js'),i=!0),this.remoteTextTrackEls().J(s),this.remoteTextTracks().tt(s.track),!0!==i&&this.ot.tt(s.track),s},s.removeRemoteTextTrack=function(t){var i=this.remoteTextTrackEls().Y(t);this.remoteTextTrackEls().K(i),this.remoteTextTracks().it(t),this.ot.it(t)},s.getVideoPlaybackQuality=function(){return{}},s.setPoster=function(){},s.playsinline=function(){},s.setPlaysinline=function(){},s.canPlayType=function(){return""},i.isTech=function(t){return t.prototype instanceof i||t instanceof i||t===i},i.registerTech=function(t,s){if(i.gt||(i.gt={}),!i.isTech(s))throw new b("Tech "+t+" must be a Tech");return i.gt[t]=s,s},i.getTech=function(t){return i.gt&&i.gt[t]?i.gt[t]:p&&p.videojs&&p.videojs[t]?(qi.warn("The "+t+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),p.videojs[t]):void 0},i}(fe);Yr.prototype.nt,Yr.prototype.ht,Yr.prototype.rt,Yr.prototype.featuresVolumeControl=!0,Yr.prototype.featuresFullscreenResize=!1,Yr.prototype.featuresPlaybackRate=!1,Yr.prototype.featuresProgressEvents=!1,Yr.prototype.featuresTimeupdateEvents=!1,Yr.prototype.featuresNativeTextTracks=!1,Yr.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:qi.error("No source hander found for the current source.")),this.disposeSourceHandler(),this.off("dispose",this.disposeSourceHandler),s!==t.nativeSourceHandler&&(this.bt=i,this.off(this.v,"loadstart",t.prototype.wt),this.off(this.v,"loadstart",t.prototype.kt),this.one(this.v,"loadstart",t.prototype.wt)),this.yt=s.handleSource(i,this,this.h),this.on("dispose",this.disposeSourceHandler),this},t.prototype.wt=function(){this.one(this.v,"loadstart",t.prototype.kt)},t.prototype.kt=function(){this.disposeSourceHandler(),this.one(this.v,"loadstart",t.prototype.kt)},t.prototype.disposeSourceHandler=function(){this.bt&&(this.clearTracks(["audio","video"]),this.bt=null),this.cleanupAutoTextTracks(),this.yt&&(this.off(this.v,"loadstart",t.prototype.wt),this.off(this.v,"loadstart",t.prototype.kt),this.yt.dispose&&this.yt.dispose(),this.yt=null)}},fe.registerComponent("Tech",Yr),fe.registerComponent("MediaTechController",Yr),Yr.registerTech("Tech",Yr);var Kr=function(t){function i(i,s,e){var n;if(n=t.call(this,i,s,e)||this,s.playerOptions.sources&&0!==s.playerOptions.sources.length)i.src(s.playerOptions.sources);else for(var r=0,h=s.playerOptions.techOrder;r<h.length;r++){var o=le(h[r]),a=Yr.getTech(o);if(o||(a=fe.getComponent(o)),a&&a.isSupported()){i._t(o);break}}return n}return ge(i,t),i}(fe);fe.registerComponent("MediaLoader",Kr);var Zr=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}ge(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=Ui({className:this.buildCSSClass(),tabIndex:0},s),"button"===i&&qi.error("Creating a ClickableComponent with an HTML element of "+i+" is not supported; use a Button instead."),e=Ui({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=is("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){te(Ii,"keydown",ce(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){ie(Ii,"keydown",ce(this,this.handleKeyPress))},i}(fe);fe.registerComponent("ClickableComponent",Zr);var th=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).update(),i.on("posterchange",ce(pe(e),e.update)),e}ge(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=is("div",{className:"vjs-poster",tabIndex:-1});return Gs||(this.jt=is("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}(Zr);fe.registerComponent("PosterImage",th);var ih="#222",sh={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 eh(t,i){return"rgba("+C(t[1]+t[1],16)+","+C(t[2]+t[2],16)+","+C(t[3]+t[3],16)+","+i+")"}function nh(t,i,s){try{t.style[i]=s}catch(t){return}}var rh=function(t){function i(i,s,e){var n;return n=t.call(this,i,s,e)||this,i.on("loadstart",ce(pe(n),n.toggleDisplay)),i.on("texttrackchange",ce(pe(n),n.updateDisplay)),i.ready(ce(pe(n),(function(){if(i.H&&i.H.featuresNativeTextTracks)this.hide();else{i.on("fullscreenchange",ce(this,this.updateDisplay));for(var t=this.h.playerOptions.tracks||[],s=0;s<t.length;s++)this.t.addRemoteTextTrack(t[s],!0);var e,n,r={captions:1,subtitles:1},h=this.t.textTracks();if(h){for(var o=0;o<h.length;o++){var a=h[o];a.default&&("descriptions"!==a.kind||e?a.kind in r&&!n&&(n=a):e=a)}n?n.mode="showing":e&&(e.mode="showing")}}}))),n}ge(i,t);var s=i.prototype;return s.toggleDisplay=function(){this.t.H&&this.t.H.featuresNativeTextTracks?this.hide():this.show()},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-text-track-display"},{"aria-live":"off","aria-atomic":"true"})},s.clearDisplay=function(){"function"==typeof p.WebVTT&&p.WebVTT.processCues(p,[],this.v)},s.updateDisplay=function(){var t=this.t.textTracks();if(this.clearDisplay(),t){for(var i=null,s=null,e=t.length;e--;){var n=t[e];"showing"===n.mode&&("descriptions"===n.kind?i=n:s=n)}s?("off"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","off"),this.updateForTrack(s)):i&&("assertive"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","assertive"),this.updateForTrack(i))}},s.updateForTrack=function(t){if("function"==typeof p.WebVTT&&t.activeCues){for(var i=this.t.textTrackSettings.getValues(),s=[],e=0;e<t.activeCues.length;e++)s.push(t.activeCues[e]);p.WebVTT.processCues(p,s,this.v);for(var n=s.length;n--;){var r=s[n];if(r){var h=r.displayState;if(i.color&&(h.firstChild.style.color=i.color),i.textOpacity&&nh(h.firstChild,"color",eh(i.color||"#fff",i.textOpacity)),i.backgroundColor&&(h.firstChild.style.backgroundColor=i.backgroundColor),i.backgroundOpacity&&nh(h.firstChild,"backgroundColor",eh(i.backgroundColor||"#000",i.backgroundOpacity)),i.windowColor&&(i.windowOpacity?nh(h,"backgroundColor",eh(i.windowColor,i.windowOpacity)):h.style.backgroundColor=i.windowColor),i.edgeStyle&&("dropshadow"===i.edgeStyle?h.firstChild.style.textShadow="2px 2px 3px #222, 2px 2px 4px #222, 2px 2px 5px "+ih:"raised"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #222, 2px 2px #222, 3px 3px "+ih:"depressed"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #ccc, 0 1px #ccc, -1px -1px #222, 0 -1px "+ih:"uniform"===i.edgeStyle&&(h.firstChild.style.textShadow="0 0 4px #222, 0 0 4px #222, 0 0 4px #222, 0 0 4px "+ih)),i.fontPercent&&1!==i.fontPercent){var o=p.parseFloat(h.style.fontSize);h.style.fontSize=o*i.fontPercent+"px",h.style.height="auto",h.style.top="auto",h.style.bottom="2px"}i.fontFamily&&"default"!==i.fontFamily&&("small-caps"===i.fontFamily?h.firstChild.style.fontVariant="small-caps":h.firstChild.style.fontFamily=sh[i.fontFamily])}}}},i}(fe);fe.registerComponent("TextTrackDisplay",rh);var hh=function(t){function i(){return t.apply(this,arguments)||this}return ge(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"})},i}(fe);fe.registerComponent("LoadingSpinner",hh);var oh=function(t){function i(){return t.apply(this,arguments)||this}ge(i,t);var s=i.prototype;return s.createEl=function(t,i,s){void 0===t&&(t="button"),void 0===i&&(i={}),void 0===s&&(s={}),i=Ui({className:this.buildCSSClass()},i),"button"!==t&&(qi.warn("Creating a Button with an HTML element of "+t+" is deprecated; use ClickableComponent instead."),i=Ui({tabIndex:0},i),s=Ui({role:"button"},s)),s=Ui({type:"button","aria-live":"polite"},s);var e=fe.prototype.createEl.call(this,t,i,s);return this.createControlTextEl(e),e},s.addChild=function(t,i){void 0===i&&(i={});var s=this.constructor.name;return qi.warn("Adding an actionable (user controllable) child to a Button ("+s+") is not supported; use a ClickableComponent instead."),fe.prototype.addChild.call(this,t,i)},s.enable=function(){t.prototype.enable.call(this),this.v.removeAttribute("disabled")},s.disable=function(){t.prototype.disable.call(this),this.v.setAttribute("disabled","disabled")},s.handleKeyPress=function(i){32!==i.which&&13!==i.which&&t.prototype.handleKeyPress.call(this,i)},i}(Zr);fe.registerComponent("Button",oh);var ah=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Tt=!1,e.on("mousedown",e.handleMouseDown),e}ge(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}(oh);ah.prototype.St="Play Video",fe.registerComponent("BigPlayButton",ah);var uh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).controlText(s&&s.controlText||"Close"),e}ge(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}(oh);fe.registerComponent("CloseButton",uh);var ch=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}ge(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}(oh);function lh(t,i){void 0===i&&(i=t),t=t<0?0:t;var s=x.floor(t%60),e=x.floor(t/60%60),n=x.floor(t/3600),r=x.floor(i/60%60),h=x.floor(i/3600);return(j(t)||t===1/0)&&(n=e=s="-"),(n=n>0||h>0?n+":":"")+(e=((n||r>=10)&&e<10?"0"+e:e)+":")+(s=s<10?"0"+s:s)}ch.prototype.St="Play",fe.registerComponent("PlayToggle",ch);var dh=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}ge(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=is("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=lh(i,this.t.duration());e!==this.Mt&&(this.Mt=e,this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e)},i}(fe);fe.registerComponent("CurrentTimeDisplay",dh);var fh=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}ge(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=is("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=lh(i);this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e}},i}(fe);fe.registerComponent("DurationDisplay",fh);var vh=function(t){function i(){return t.apply(this,arguments)||this}return ge(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}(fe);fe.registerComponent("TimeDivider",vh);var ph=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}ge(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=is("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=lh(this.t.remainingTime());s!==this.Mt&&(this.Mt=s,this.S.innerHTML='<span class="vjs-control-text">'+i+"</span> -"+s)}},i}(fe);fe.registerComponent("RemainingTimeDisplay",ph);var mh=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}ge(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=is("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.Ct=is("span",{className:"vjs-control-text",innerHTML:this.localize("Stream Type")}),this.At=Ii.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}(fe);fe.registerComponent("LiveDisplay",mh);var gh=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}ge(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=Ui({tabIndex:0},s),e=Ui({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(),Ii.body.focus(),Ii.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;Ii.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=ys(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}(fe);function yh(t,i){if(!t||!i)return"";if("function"==typeof p.getComputedStyle){var s=p.getComputedStyle(t);return s?s[i]:""}return t.currentStyle[i]||""}fe.registerComponent("Slider",gh);var bh=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}ge(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=is("span",{innerHTML:this.localize("Loaded")}),this.It=Ii.createTextNode(": 0%"),this.Ct=is("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.Nt),this.Ct.appendChild(this.It),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(is()),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}(fe);fe.registerComponent("LoadProgressBar",bh);var wh=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(ce(pe(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}ge(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.Bt=is("span",{innerHTML:this.localize("Progress")}),this.Ft=Ii.createTextNode(": 0%"),this.Ct=is("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.Bt),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",lh(i,this.t.duration()))},s.handleLanguagechange=function(){this.Bt.innerHTML=this.localize("Progress")},i}(fe);fe.registerComponent("PlayProgressBar",wh);var kh=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(ce(pe(e),e.updateDataAttr)),e}ge(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=is("div",{className:"vjs-time-tooltip"}),this.Bt=is("span",{innerHTML:this.localize("Progress")}),this.Ft=Ii.createTextNode(": 0%"),this.Ct=is("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.Bt),this.Ct.appendChild(this.Ft),i.appendChild(this.tooltip),i.appendChild(this.Ct),i},s.updateDataAttr=function(t){var i=lh(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.Bt.innerHTML=this.localize("Progress")},i}(fe);fe.registerComponent("TooltipProgressBar",kh);var _h=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(ce(pe(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}ge(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=S(yh(this.player().el(),"width")),s=S(yh(this.tooltipProgressBar.tooltip,"width")),e=this.tooltipProgressBar.el().style;e.maxWidth=x.floor(i-s/2)+"px",e.minWidth=x.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",lh(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}(gh);_h.prototype.h={children:["loadProgressBar","mouseTimeDisplay","playProgressBar"],barName:"playProgressBar"},_h.prototype.playerEvent="timeupdate",fe.registerComponent("SeekBar",_h);var xh=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=is("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)}}(ce(pe(e),e.handleMouseMove),25))})),e}ge(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-gs(this.el().parentNode).left;this.update(s,e)},s.update=function(t,i){var s=lh(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=S(yh(this.tooltip,"width"))/2;this.tooltip.innerHTML=s,this.tooltip.style.right="-"+(n-e)+"px"}},s.calculateDistance=function(t){return ys(this.el().parentNode,t).x},s.Dt=function(t){if(!this.keepTooltipsInside)return t;var i=S(yh(this.player().el(),"width")),s=S(yh(this.tooltip,"width"))/2,e=t;return t<s?e=x.ceil(s):t>i-s&&(e=x.floor(i-s)),e},i}(fe);fe.registerComponent("MouseTimeDisplay",xh);var Ch=function(t){function i(){return t.apply(this,arguments)||this}return ge(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},i}(fe);Ch.prototype.h={children:["seekBar"]},fe.registerComponent("ProgressControl",Ch);var Sh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"fullscreenchange",e.handleFullscreenChange),e}ge(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}(oh);Sh.prototype.St="Fullscreen",fe.registerComponent("FullscreenToggle",Sh);var jh=function(t){function i(){return t.apply(this,arguments)||this}return ge(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}(fe);fe.registerComponent("VolumeLevel",jh);var Th=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.updateARIAAttributes),i.ready(ce(pe(e),e.updateARIAAttributes)),e}ge(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}(gh);Th.prototype.h={children:["volumeLevel"],barName:"volumeLevel"},Th.prototype.playerEvent="volumechange",fe.registerComponent("VolumeBar",Th);var Mh=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 ge(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control"})},i}(fe);Mh.prototype.h={children:["volumeBar"]},fe.registerComponent("VolumeControl",Mh);var Ah=function(t){function i(){return t.apply(this,arguments)||this}ge(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",ce(this,(function(){this.unlockShowing()})))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=is(i,{className:"vjs-menu-content"});var s=t.prototype.createEl.call(this,"div",{append:this.S,className:"vjs-menu"});return s.appendChild(this.S),te(s,"click",(function(t){t.preventDefault(),t.stopImmediatePropagation()})),s},i}(fe);fe.registerComponent("Popup",Ah);var Ph=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e}ge(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}(Zr);fe.registerComponent("PopupButton",Ph);var Eh=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}ge(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++)ls(this.v,"vjs-vol-"+n);cs(this.v,"vjs-vol-"+s)},i}(oh);Eh.prototype.St="Mute",fe.registerComponent("MuteToggle",Eh);var Nh=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(pe(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}ge(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 Ah(this.t,{contentElType:"div"}),i=new Th(this.t,this.h.volumeBar);return t.addChild(i),this.menuContent=t,this.volumeBar=i,this.attachVolumeBarEvents(),t},s.handleClick=function(i){Eh.prototype.handleClick.call(this),t.prototype.handleClick.call(this)},s.attachVolumeBarEvents=function(){this.menuContent.on(["mousedown","touchdown"],ce(this,this.handleMouseDown))},s.handleMouseDown=function(t){this.on(["mousemove","touchmove"],ce(this.volumeBar,this.volumeBar.handleMouseMove)),this.on(this.v.ownerDocument,["mouseup","touchend"],this.handleMouseUp)},s.handleMouseUp=function(t){this.off(["mousemove","touchmove"],ce(this.volumeBar,this.volumeBar.handleMouseMove))},i}(Ph);Nh.prototype.volumeUpdate=Eh.prototype.update,Nh.prototype.St="Mute",fe.registerComponent("VolumeMenuButton",Nh);var Ih=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).$t=-1,e.on("keydown",e.handleKeyPress),e}ge(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",ce(this,(function(t){this.unlockShowing()})))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=is(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),te(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}(fe);fe.registerComponent("Menu",Ih);var Bh=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}ge(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 Ih(this.t);if(this.Vt=0,this.h.title){var i=is("li",{className:"vjs-menu-title",innerHTML:le(this.h.title),tabIndex:-1});this.Vt+=1,t.m.unshift(i),es(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",ce(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}(Zr);fe.registerComponent("MenuButton",Bh);var Fh=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 pe(e);var r=ce(pe(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 ge(i,t),i}(Bh);fe.registerComponent("TrackButton",Fh);var Dh=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}ge(i,t);var s=i.prototype;return s.createEl=function(i,s,e){this.nonIconControl=!0;var n=t.prototype.createEl.call(this,"li",Ui({className:"vjs-menu-item",tabIndex:-1},s),e);return this.Ut=Ii.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}(Zr);fe.registerComponent("MenuItem",Dh);var $h=function(t){function i(i,s){var e,n,r=s.track,h=i.textTracks();if(s.label=r.label||r.language||"Unknown",s.selected=r.default||"showing"===r.mode,(e=t.call(this,i,s)||this).track=r,h){var o=ce(pe(e),e.handleTracksChange);i.on(["loadstart","texttrackchange"],o),h.addEventListener("change",o),e.on("dispose",(function(){h.removeEventListener("change",o)}))}h&&void 0===h.onchange&&e.on(["tap","click"],(function(){if("object"!=typeof p.Event)try{n=new p.Event("change")}catch(t){}n||(n=Ii.createEvent("Event")).initEvent("change",!0,!0),h.dispatchEvent(n)}));return e}ge(i,t);var s=i.prototype;return s.handleClick=function(i){var s=this.track.kind,e=this.t.textTracks();if(t.prototype.handleClick.call(this,i),e)for(var n=0;n<e.length;n++){var r=e[n];r.kind===s&&(r===this.track?"showing"!==r.mode&&(r.mode="showing"):"disabled"!==r.mode&&(r.mode="disabled"))}},s.handleTracksChange=function(t){this.selected("showing"===this.track.mode)},i}(Dh);fe.registerComponent("TextTrackMenuItem",$h);var Rh=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 ge(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}($h);fe.registerComponent("OffTextTrackMenuItem",Rh);var Oh=function(t){function i(i,s){return void 0===s&&(s={}),s.tracks=i.textTracks(),t.call(this,i,s)||this}return ge(i,t),i.prototype.createItems=function(t){void 0===t&&(t=[]),t.push(new Rh(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 $h(this.t,{track:e,selectable:!0}))}return t},i}(Fh);fe.registerComponent("TextTrackButton",Oh);var Vh=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",ce(pe(e),e.update)),e}ge(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}(Dh);fe.registerComponent("ChaptersTrackMenuItem",Vh);var Uh=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}ge(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(le(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 Vh(this.t,{track:this.Lt,cue:n});t.push(r)}return t},i}(Oh);Uh.prototype.zt="chapters",Uh.prototype.St="Chapters",fe.registerComponent("ChaptersButton",Uh);var zh=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=ce(pe(n),n.handleTracksChange);r.addEventListener("change",h),n.on("dispose",(function(){r.removeEventListener("change",h)}))}return n}ge(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}(Oh);zh.prototype.zt="descriptions",zh.prototype.St="Descriptions",fe.registerComponent("DescriptionsButton",zh);var Lh=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 ge(i,t),i.prototype.buildCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildCSSClass.call(this)},i}(Oh);Lh.prototype.zt="subtitles",Lh.prototype.St="Subtitles",fe.registerComponent("SubtitlesButton",Lh);var Hh=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 ge(i,t),i.prototype.handleClick=function(t){this.player().getChild("textTrackSettings").show(),this.player().getChild("textTrackSettings").v.focus()},i}($h);fe.registerComponent("CaptionSettingsMenuItem",Hh);var qh=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}ge(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 Hh(this.t,{kind:this.zt})),this.Vt+=1),t.prototype.createItems.call(this,i)},i}(Oh);qh.prototype.zt="captions",qh.prototype.St="Captions",fe.registerComponent("CaptionsButton",qh);var Wh=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=ce(pe(e),e.handleTracksChange);r.addEventListener("change",h),e.on("dispose",(function(){r.removeEventListener("change",h)}))}return e}ge(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}(Dh);fe.registerComponent("AudioTrackMenuItem",Wh);var Gh=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}ge(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 Wh(this.t,{track:e,selectable:!0}))}return t},i}(Fh);Gh.prototype.St="Audio Track",fe.registerComponent("AudioTrackButton",Gh);var Xh=function(t){function i(i,s){var e,n=s.rate,r=S(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}ge(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}(Dh);Xh.prototype.contentElType="button",fe.registerComponent("PlaybackRateMenuItem",Xh);var Jh=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}ge(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this);return this.Ut=is("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 Ih(this.player()),i=this.playbackRates();if(i)for(var s=i.length-1;s>=0;s--)t.addChild(new Xh(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}(Bh);Jh.prototype.St="Playback Rate",fe.registerComponent("PlaybackRateMenuButton",Jh);var Qh=function(t){function i(){return t.apply(this,arguments)||this}ge(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}(fe);fe.registerComponent("Spacer",Qh);var Yh=function(t){function i(){return t.apply(this,arguments)||this}ge(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);fe.registerComponent("CustomControlSpacer",Yh);var Kh=function(t){function i(){return t.apply(this,arguments)||this}return ge(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"},{role:"group"})},i}(fe);Kh.prototype.h={children:["playToggle","volumeMenuButton","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subtitlesButton","captionsButton","audioTrackButton","fullscreenToggle"]},fe.registerComponent("ControlBar",Kh);var Zh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"error",e.open),e}ge(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}(Fe);Zh.prototype.h=de(Fe.prototype.h,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),fe.registerComponent("ErrorDisplay",Zh);var to="vjs-text-track-settings",io=["#000","Black"],so=["#00F","Blue"],eo=["#0FF","Cyan"],no=["#0F0","Green"],ro=["#F0F","Magenta"],ho=["#F00","Red"],oo=["#FFF","White"],ao=["#FF0","Yellow"],uo=["1","Opaque"],co=["0.5","Semi-Transparent"],lo=["0","Transparent"],fo={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[io,oo,ho,no,so,ao,ro,eo]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[uo,co,lo]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[oo,io,ho,no,so,ao,ro,eo]},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:[uo,co]},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:[lo,co,uo]}};function vo(t,i){if(i&&(t=i(t)),t&&"none"!==t)return t}fo.windowColor.options=fo.backgroundColor.options;var po,mo=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).setDefaults(),e.hide(),e.updateDisplay=ce(pe(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()})),Vi(fo,(function(t){e.on(e.$(t.selector),"change",e.updateDisplay)})),e.h.persistTextTrackSettings&&e.restoreSettings(),e}ge(i,t);var s=i.prototype;return s.qt=function(t){var i=this,s=fo[t],e=s.id.replace("%s",this.o);return[is("label",{className:"vjs-label",textContent:s.label},{for:e}),is("select",{id:e},void 0,s.options.map((function(t){return is("option",{textContent:i.localize(t[1]),value:t[0]})})))]},s.Wt=function(){var t=is("legend",{textContent:this.localize("Text")}),i=this.qt("color"),s=is("span",{className:"vjs-text-opacity vjs-opacity"},void 0,this.qt("textOpacity"));return is("fieldset",{className:"vjs-fg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Gt=function(){var t=is("legend",{textContent:this.localize("Background")}),i=this.qt("backgroundColor"),s=is("span",{className:"vjs-bg-opacity vjs-opacity"},void 0,this.qt("backgroundOpacity"));return is("fieldset",{className:"vjs-bg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Xt=function(){var t=is("legend",{textContent:this.localize("Window")}),i=this.qt("windowColor"),s=is("span",{className:"vjs-window-opacity vjs-opacity"},void 0,this.qt("windowOpacity"));return is("fieldset",{className:"vjs-window-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Jt=function(){return is("div",{className:"vjs-tracksettings-colors"},void 0,[this.Wt(),this.Gt(),this.Xt()])},s.Qt=function(){var t=is("div",{className:"vjs-font-percent vjs-tracksetting"},void 0,this.qt("fontPercent")),i=is("div",{className:"vjs-edge-style vjs-tracksetting"},void 0,this.qt("edgeStyle")),s=is("div",{className:"vjs-font-family vjs-tracksetting"},void 0,this.qt("fontFamily"));return is("div",{className:"vjs-tracksettings-font"},void 0,[t,i,s])},s.Yt=function(){var t=is("button",{className:"vjs-default-button",textContent:this.localize("Defaults")}),i=is("button",{className:"vjs-done-button",textContent:"Done"});return is("div",{className:"vjs-tracksettings-controls"},void 0,[t,i])},s.createEl=function(){var t=is("div",{className:"vjs-tracksettings"},void 0,[this.Jt(),this.Qt(),this.Yt()]),i=is("div",{className:"vjs-control-text",id:"TTsettingsDialogLabel-"+this.o,textContent:"Caption Settings Dialog"},{"aria-level":"1",role:"heading"}),s=is("div",{className:"vjs-control-text",id:"TTsettingsDialogDescription-"+this.o,textContent:"Beginning of dialog window. Escape will cancel and close the window."}),e=is("div",void 0,{role:"document"},[i,s,t]);return is("div",{className:"vjs-caption-settings vjs-modal-overlay",tabIndex:-1},{role:"dialog","aria-labelledby":i.id,"aria-describedby":s.id},e)},s.getValues=function(){var t=this;return function(t,i,s){return void 0===s&&(s=0),Oi(t).reduce((function(s,e){return i(s,t[e],e)}),s)}(fo,(function(i,s,e){var n=function(t,i){return vo(t.options[t.options.selectedIndex].value,i)}(t.$(s.selector),s.parser);return void 0!==n&&(i[e]=n),i}),{})},s.setValues=function(t){var i=this;Vi(fo,(function(s,e){!function(t,i,s){if(i)for(var e=0;e<t.options.length;e++)if(vo(t.options[e].value,s)===i){t.selectedIndex=e;break}}(i.$(s.selector),t[e],s.parser)}))},s.setDefaults=function(){var t=this;Vi(fo,(function(i){var s=i.hasOwnProperty("default")?i.default:0;t.$(i.selector).selectedIndex=s}))},s.restoreSettings=function(){var t;try{t=JSON.parse(p.localStorage.getItem(to))}catch(t){qi.warn(t)}t&&this.setValues(t)},s.saveSettings=function(){if(this.h.persistTextTrackSettings){var t=this.getValues();try{_.keys(t).length?p.localStorage.setItem(to,JSON.stringify(t)):p.localStorage.removeItem(to)}catch(t){qi.warn(t)}}},s.updateDisplay=function(){var t=this.t.getChild("textTrackDisplay");t&&t.updateDisplay()},i}(fe);fe.registerComponent("TextTrackSettings",mo);var go,e=function(t){function i(i,s){var e;e=t.call(this,i,s)||this;var n=i.source,r=!1;if(n&&(e.v.currentSrc!==n.src||i.tag&&3===i.tag.Kt)?e.setSource(n):e.Zt(e.v),e.v.hasChildNodes()){for(var h=e.v.childNodes,o=h.length,a=[];o--;){var u=h[o];"track"===u.nodeName.toLowerCase()&&(e.featuresNativeTextTracks?(e.remoteTextTrackEls().J(u),e.remoteTextTracks().tt(u.track),r||e.v.hasAttribute("crossorigin")||!Le(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=le(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&&qi.warn(Ji(po||(po=Bi(["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=ce(pe(e),e.handleTextTrackChange),e.hi=ce(pe(e),e.handleTextTrackAdd),e.oi=ce(pe(e),e.handleTextTrackRemove),e.ai()),e.ci(),(Ws||Ps||$s)&&!0===i.nativeControlsForTouch&&e.setControls(!0),e.di(),e.triggerReady(),e}ge(i,t);var s=i.prototype;return s.dispose=function(){var s=this;["audio","video","text"].forEach((function(t){var i=le(t),e=s.v[t+"Tracks"];e&&e.removeEventListener&&(e.removeEventListener("change",s["handle"+i+"ti"]),e.removeEventListener("addtrack",s["handle"+i+"ii"]),e.removeEventListener("removetrack",s["handle"+i+"si"])),e&&s.off("loadstart",s["removeOld"+i+"ei"])})),i.disposeMediaElement(this.v),t.prototype.dispose.call(this)},s.ci=function(){var t,i=this.textTracks(),s=function(){t=[];for(var s=0;s<i.length;s++){var e=i[s];"metadata"===e.kind&&t.push({track:e,storedMode:e.mode})}};s(),i.addEventListener("change",s);var e=function s(){for(var e=0;e<t.length;e++){var n=t[e];"disabled"===n.track.mode&&n.track.mode!==n.storedMode&&(n.track.mode=n.storedMode)}i.removeEventListener("change",s)};this.on("webkitbeginfullscreen",(function(){i.removeEventListener("change",s),i.removeEventListener("change",e),i.addEventListener("change",e)})),this.on("webkitendfullscreen",(function(){i.removeEventListener("change",s),i.addEventListener("change",s),i.removeEventListener("change",e)}))},s.createEl=function(){var t=this.h.tag;if(!t||!this.h.playerElIngest&&!this.movingMediaElementInDOM){if(t){var s=t.cloneNode(!0);t.parentNode&&t.parentNode.insertBefore(s,t),i.disposeMediaElement(t),t=s}else{t=Ii.createElement("video");var e=de({},this.h.tag&&vs(this.h.tag));Ws&&!0===this.h.nativeControlsForTouch||delete e.controls,fs(t,Ui(e,{id:this.h.techId,class:"vjs-tech"}))}t.playerId=this.h.playerId}void 0!==this.h.preload&&ps(t,"preload",this.h.preload);for(var n=["loop","muted","playsinline","autoplay"],r=n.length-1;r>=0;r--){var h=n[r],o=this.h[h];void 0!==o&&(o?ps(t,h,h):ms(t,h),t[h]=o)}return t},s.Zt=function(t){if(0!==t.networkState&&3!==t.networkState){if(0===t.readyState){var i=!1,s=function(){i=!0};this.on("loadstart",s);var e=function(){i||this.trigger("loadstart")};return this.on("loadedmetadata",e),void this.ready((function(){this.off("loadstart",s),this.off("loadedmetadata",e),i||this.trigger("loadstart")}))}var n=["loadstart"];n.push("loadedmetadata"),t.readyState>=2&&n.push("loadeddata"),t.readyState>=3&&n.push("canplay"),t.readyState>=4&&n.push("canplaythrough"),this.ready((function(){n.forEach((function(t){this.trigger(t)}),this)}))}},s.ai=function(){var t=this.el().textTracks;if(t){for(var i=0;i<t.length;i++)this.textTracks().tt(t[i]);t.addEventListener&&(t.addEventListener("change",this.ri),t.addEventListener("addtrack",this.hi),t.addEventListener("removetrack",this.oi)),this.on("loadstart",this.fi)}},s.handleTextTrackChange=function(t){var i=this.textTracks();this.textTracks().trigger({type:"change",target:i,currentTarget:i,srcElement:i})},s.handleTextTrackAdd=function(t){this.textTracks().tt(t.track)},s.handleTextTrackRemove=function(t){this.textTracks().it(t.track)},s.ni=function(t,i){var s=[];if(i){for(var e=0;e<t.length;e++){for(var n=t[e],r=!1,h=0;h<i.length;h++)if(i[h]===n){r=!0;break}r||s.push(n)}for(var o=0;o<s.length;o++){var a=s[o];t.it(a)}}},s.fi=function(t){var i=this.textTracks(),s=this.el().textTracks;this.ni(i,s)},s.play=function(){var t=this.v.play();void 0!==t&&"function"==typeof t.then&&t.then(null,(function(t){}))},s.setCurrentTime=function(t){try{this.v.currentTime=t}catch(t){qi(t,"Video is not ready. (Video.js)")}},s.duration=function(){var t=this;if(this.v.duration===1/0&&Bs&&Vs&&0===this.v.currentTime){return this.on("timeupdate",(function i(){t.v.currentTime>0&&(t.v.duration===1/0&&t.trigger("durationchange"),t.off("timeupdate",i))})),NaN}return this.v.duration||NaN},s.width=function(){return this.v.offsetWidth},s.height=function(){return this.v.offsetHeight},s.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)}))}},s.supportsFullScreen=function(){if("function"==typeof this.v.webkitEnterFullScreen){var t=p.navigator&&p.navigator.userAgent||"";if(/Android/.test(t)||!/Chrome|Mac OS X 10.5/.test(t))return!0}return!1},s.enterFullScreen=function(){var t=this.v;t.paused&&t.networkState<=t.HAVE_METADATA?(this.v.play(),this.setTimeout((function(){t.pause(),t.webkitEnterFullScreen()}),0)):t.webkitEnterFullScreen()},s.exitFullScreen=function(){this.v.webkitExitFullScreen()},s.src=function(t){if(void 0===t)return this.v.src;this.setSrc(t)},s.reset=function(){i.resetMediaElement(this.v)},s.currentSrc=function(){return this.bt?this.bt.src:this.v.currentSrc},s.setControls=function(t){this.v.controls=!!t},s.addTextTrack=function(i,s,e){return this.featuresNativeTextTracks?this.v.addTextTrack(i,s,e):t.prototype.addTextTrack.call(this,i,s,e)},s.createRemoteTextTrack=function(i){if(!this.featuresNativeTextTracks)return t.prototype.createRemoteTextTrack.call(this,i);var s=Ii.createElement("track");return i.kind&&(s.kind=i.kind),i.label&&(s.label=i.label),(i.language||i.srclang)&&(s.srclang=i.language||i.srclang),i.default&&(s.default=i.default),i.id&&(s.id=i.id),i.src&&(s.src=i.src),s},s.addRemoteTextTrack=function(i,s){var e=t.prototype.addRemoteTextTrack.call(this,i,s);return this.featuresNativeTextTracks&&this.el().appendChild(e),e},s.removeRemoteTextTrack=function(i){if(t.prototype.removeRemoteTextTrack.call(this,i),this.featuresNativeTextTracks)for(var s=this.$$("track"),e=s.length;e--;)i!==s[e]&&i!==s[e].track||this.el().removeChild(s[e])},s.getVideoPlaybackQuality=function(){if("function"==typeof this.el().getVideoPlaybackQuality)return this.el().getVideoPlaybackQuality();var t={};return void 0!==this.el().webkitDroppedFrameCount&&void 0!==this.el().webkitDecodedFrameCount&&(t.droppedVideoFrames=this.el().webkitDroppedFrameCount,t.totalVideoFrames=this.el().webkitDecodedFrameCount),p.performance&&"function"==typeof p.performance.now?t.creationTime=p.performance.now():p.performance&&p.performance.timing&&"number"==typeof p.performance.timing.navigationStart&&(t.creationTime=p.Date.now()-p.performance.timing.navigationStart),t},i}(Yr);Ki()&&(e.TEST_VID=Ii.createElement("video"),(go=Ii.createElement("track")).kind="captions",go.srclang="en",go.label="English",e.TEST_VID.appendChild(go)),e.isSupported=function(){try{e.TEST_VID.volume=.5}catch(t){return!1}return!(!e.TEST_VID||!e.TEST_VID.canPlayType)},e.canControlVolume=function(){try{var t=e.TEST_VID.volume;return e.TEST_VID.volume=t/2+.1,t!==e.TEST_VID.volume}catch(t){return!1}},e.canControlPlaybackRate=function(){if(Bs&&Vs&&Us<58)return!1;try{var t=e.TEST_VID.playbackRate;return e.TEST_VID.playbackRate=t/2+.1,t!==e.TEST_VID.playbackRate}catch(t){return!1}},e.supportsNativeTextTracks=function(){return qs},e.supportsNativeVideoTracks=function(){return!(!e.TEST_VID||!e.TEST_VID.videoTracks)},e.supportsNativeAudioTracks=function(){return!(!e.TEST_VID||!e.TEST_VID.audioTracks)},e.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange"],e.prototype.featuresVolumeControl=e.canControlVolume(),e.prototype.featuresPlaybackRate=e.canControlPlaybackRate(),e.prototype.movingMediaElementInDOM=!Ns,e.prototype.featuresFullscreenResize=!0,e.prototype.featuresProgressEvents=!0,e.prototype.featuresTimeupdateEvents=!0,e.prototype.featuresNativeTextTracks=e.supportsNativeTextTracks(),e.prototype.featuresNativeVideoTracks=e.supportsNativeVideoTracks(),e.prototype.featuresNativeAudioTracks=e.supportsNativeAudioTracks();var yo=e.TEST_VID&&e.TEST_VID.constructor.prototype.canPlayType,bo=/^application\/(?:x-|vnd\.apple\.)mpegurl/i,wo=/^video\/mp4/i;e.patchCanPlayType=function(){Fs>=4&&!Rs?e.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&bo.test(t)?"maybe":yo.call(this,t)}:Ds&&(e.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&wo.test(t)?"maybe":yo.call(this,t)})},e.unpatchCanPlayType=function(){var t=e.TEST_VID.constructor.prototype.canPlayType;return e.TEST_VID.constructor.prototype.canPlayType=yo,t},e.patchCanPlayType(),e.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){}}()}}},e.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){e.prototype[t]=function(){return this.v[t]||this.v.hasAttribute(t)}})),["muted","defaultMuted","autoplay","loop","playsinline"].forEach((function(t){e.prototype["set"+le(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){e.prototype[t]=function(){return this.v[t]}})),["volume","src","poster","preload","playbackRate"].forEach((function(t){e.prototype["set"+le(t)]=function(i){this.v[t]=i}})),["pause","load"].forEach((function(t){e.prototype[t]=function(){return this.v[t]()}})),Yr.withSourceHandlers(e),e.nativeSourceHandler={},e.nativeSourceHandler.canPlayType=function(t){try{return e.TEST_VID.canPlayType(t)}catch(t){return""}},e.nativeSourceHandler.canHandleSource=function(t,i){if(t.type)return e.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 e.nativeSourceHandler.canPlayType("video/"+s)}return""},e.nativeSourceHandler.handleSource=function(t,i,s){i.setSrc(t.src)},e.nativeSourceHandler.dispose=function(){},e.registerSourceHandler(e.nativeSourceHandler),fe.registerComponent("Html5",e),Yr.registerTech("Html5",e);var ko=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","ratechange","volumechange","texttrackchange"],_o=function(t){function i(s,e,n){var r;if(s.id=s.id||["vjs_video",Di()].join("_"),(e=Ui(i.getTagSettings(s),e)).initChildren=!1,e.createEl=!1,e.reportTouchActivity=!1,!e.language)if("function"==typeof s.closest){var h=s.closest("[lang]");h&&(e.language=h.getAttribute("lang"))}else for(var o=s;o&&1===o.nodeType;){if(vs(o).hasOwnProperty("lang")){e.language=o.getAttribute("lang");break}o=o.parentNode}if(!(r=t.call(this,null,e,n)||this).h||!r.h.techOrder||!r.h.techOrder.length)throw new b("No techOrder specified. Did you overwrite videojs.options instead of just changing the properties you want to override?");if(r.tag=s,r.tagAttributes=s&&vs(s),r.language(r.h.language),e.languages){var a={};_.getOwnPropertyNames(e.languages).forEach((function(t){a[t.toLowerCase()]=e.languages[t]})),r.vi=a}else r.vi=i.prototype.h.languages;r.pi={},r.mi=e.poster||"",r.gi=!!e.controls,s.controls=!1,r.yi=!1,r.v=r.createEl();var u=de(r.h);if(e.plugins){var c=e.plugins;_.getOwnPropertyNames(c).forEach((function(t){"function"==typeof this[t]?this[t](c[t]):qi.error("Unable to find plugin:",t)}),pe(r))}r.h.playerOptions=u,r.initChildren(),r.isAudio("audio"===s.nodeName.toLowerCase()),r.controls()?r.addClass("vjs-controls-enabled"):r.addClass("vjs-controls-disabled"),r.v.setAttribute("role","region"),r.isAudio()?r.v.setAttribute("aria-label","audio player"):r.v.setAttribute("aria-label","video player"),r.isAudio()&&r.addClass("vjs-audio"),r.bi()&&r.addClass("vjs-no-flex"),Ns||r.addClass("vjs-workinghover"),i.players[r.o]=pe(r);var l="5.20.6-opentelly.14".split(".")[0];return r.addClass("vjs-v"+l),r.userActive(!0),r.reportUserActivity(),r.wi(),r.on("fullscreenchange",r.ki),r.on("stageclick",r._i),r}ge(i,t);var s=i.prototype;return s.dispose=function(){this.trigger("dispose"),this.off("dispose"),this.xi&&this.xi.parentNode&&this.xi.parentNode.removeChild(this.xi),i.players[this.o]=null,this.tag&&this.tag.player&&(this.tag.player=null),this.v&&this.v.player&&(this.v.player=null),this.H&&this.H.dispose(),t.prototype.dispose.call(this)},s.createEl=function(){var i,s=this.tag,e=this.Ci=s.parentNode&&s.parentNode.hasAttribute&&s.parentNode.hasAttribute("data-vjs-player");i=this.v=e?s.parentNode:t.prototype.createEl.call(this,"div"),s.setAttribute("tabindex","-1"),s.removeAttribute("width"),s.removeAttribute("height");var n=vs(s);if(_.getOwnPropertyNames(n).forEach((function(t){"class"===t?i.className+=" "+n[t]:i.setAttribute(t,n[t])})),s.playerId=s.id,s.id+="Si",s.className="vjs-tech",s.player=i.player=this,this.addClass("vjs-paused"),!0!==p.VIDEOJS_NO_DYNAMIC_STYLE){this.xi=ae("vjs-styles-dimensions");var r=Cs(".vjs-styles-defaults"),h=Cs("head");h.insertBefore(this.xi,r?r.nextSibling:h.firstChild)}this.width(this.h.width),this.height(this.h.height),this.fluid(this.h.fluid),this.aspectRatio(this.h.aspectRatio);for(var o=s.getElementsByTagName("a"),a=0;a<o.length;a++){var u=o.item(a);cs(u,"vjs-hidden"),u.setAttribute("hidden","hidden")}return s.Kt=s.networkState,s.parentNode&&!e&&s.parentNode.insertBefore(i,s),es(s,i),this.m.unshift(s),this.v=i,i},s.width=function(t){return this.dimension("width",t)},s.height=function(t){return this.dimension("height",t)},s.dimension=function(t,i){var s="width"===t?"ji":"Ti";if(void 0===i)return this[s]||0;if(""===i)this[s]=void 0;else{var e=S(i);if(j(e))return qi.error('Improper value "'+i+'" supplied for for '+t),this;this[s]=e}return this.Mi(),this},s.fluid=function(t){if(void 0===t)return!!this.Ai;this.Ai=!!t,t?this.addClass("vjs-fluid"):this.removeClass("vjs-fluid"),this.Mi()},s.aspectRatio=function(t){if(void 0===t)return this.Pi;if(!/^\d+\:\d+$/.test(t))throw new b("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.Pi=t,this.fluid(!0),this.Mi()},s.Mi=function(){if(!0!==p.VIDEOJS_NO_DYNAMIC_STYLE){var t,i,s,e=(void 0!==this.Pi&&"auto"!==this.Pi?this.Pi:this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9").split(":"),n=e[1]/e[0];t=void 0!==this.ji?this.ji:void 0!==this.Ti?this.Ti/n:this.videoWidth()||300,i=void 0!==this.Ti?this.Ti:t*n,s=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(s),ue(this.xi,"\n ."+s+" {\n width: "+t+"px;\n height: "+i+"px;\n }\n\n ."+s+".vjs-fluid {\n padding-top: "+100*n+"%;\n }\n ")}else{var r="number"==typeof this.ji?this.ji:this.h.width,h="number"==typeof this.Ti?this.Ti:this.h.height,o=this.H&&this.H.el();o&&(r>=0&&(o.width=r),h>=0&&(o.height=h))}},s._t=function(t,i){var s=this;this.H&&this.Ei(),"Html5"!==t&&this.tag&&(Yr.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.Ni=t,this.j=!1;var e=Ui({source:i,nativeControlsForTouch:this.h.nativeControlsForTouch,playerId:this.id(),techId:this.id()+"_"+t+"Ii",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&&(e.tag=this.tag),i&&(this.Bi=i.type,i.src===this.pi.src&&this.pi.currentTime>0&&(e.startTime=this.pi.currentTime),this.pi.sources=null,this.pi.source=i,this.pi.src=i.src);var n=Yr.getTech(t);n||(n=fe.getComponent(t)),this.H=new n(e),this.H.ready(ce(this,this.Fi),!0),Ie(this.Di||[],this.H),ko.forEach((function(t){s.on(s.H,t,s["handleTech"+le(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||es(this.H.el(),this.contentEl()),this.tag&&(this.tag.player=null,this.tag=null)},s.Ei=function(){this.rt=this.videoTracks(),this.nt=this.textTracks(),this.ht=this.audioTracks(),this.Di=Ne(this.H),this.j=!1,this.H.dispose(),this.H=!1},s.tech=function(t){if(t&&t.IWillNotUseThisInPlugins)return this.H;var i="\n Please make sure that you are not using this inside of a plugin.\n To disable this alert and error, please pass in an object with\n `IWillNotUseThisInPlugins` to the `tech` method. See\n https://github.com/videojs/video.js/issues/2617 for more info.\n ";throw p.alert(i),new b(i)},s.ts=function(){this.ss(),this.on(this.H,"mousedown",this.es),this.on(this.H,"touchstart",this.ns),this.on(this.H,"touchmove",this.rs),this.on(this.H,"touchend",this.hs),this.on(this.H,"tap",this.os)},s.ss=function(){this.off(this.H,"tap",this.os),this.off(this.H,"touchstart",this.ns),this.off(this.H,"touchmove",this.rs),this.off(this.H,"touchend",this.hs),this.off(this.H,"mousedown",this.es)},s.Fi=function(){if(this.triggerReady(),this.pi.volume&&this.us("setVolume",this.pi.volume),this.Yi(),this.Xi(),(this.src()||this.currentSrc())&&this.tag&&this.h.autoplay&&this.paused()){try{delete this.tag.poster}catch(t){qi("deleting tag.poster throws in some browsers",t)}this.play()}},s.$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"))},s.hasStarted=function(t){return void 0!==t?(this.et!==t&&(this.et=t,t?(this.addClass("vjs-has-started"),this.trigger("firstplay")):this.removeClass("vjs-has-started")),this):!!this.et},s.qi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},s.Ri=function(){var t=this;this.addClass("vjs-waiting"),this.trigger("waiting"),this.one("timeupdate",(function(){return t.removeClass("vjs-waiting")}))},s.Oi=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},s.Vi=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},s.Ui=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},s.Li=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},s.Hi=function(){this.removeClass("vjs-seeking"),this.trigger("seeked")},s.Wi=function(){this.h.starttime&&(qi.warn("Passing the `starttime` option to the player will be deprecated in 6.0"),this.currentTime(this.h.starttime)),this.addClass("vjs-has-started"),this.trigger("firstplay")},s.Gi=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},s.zi=function(){this.addClass("vjs-ended"),this.h.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},s.Xi=function(){this.duration(this.Zi("duration"))},s.es=function(t){0===t.button&&this.controls()&&(void 0!==this.h&&void 0!==this.h.userActions&&void 0!==this.h.userActions.click&&!1===this.h.userActions.click||(void 0!==this.h&&void 0!==this.h.userActions&&"function"==typeof this.h.userActions.click?this.h.userActions.click.call(this,t):this.paused()?this.play():this.pause()))},s.os=function(){this.userActive(!this.userActive())},s.ns=function(){this.userWasActive=this.userActive()},s.rs=function(){this.userWasActive&&this.reportUserActivity()},s.hs=function(t){t.cancelable&&t.preventDefault()},s.ki=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},s._i=function(){this.reportUserActivity()},s.Ji=function(t,i){i&&(this.toggleClass("vjs-ios-native-fs",!(!i.nativeIOSFullscreen||!i.isFullscreen)),this.isFullscreen(i.isFullscreen)),this.trigger("fullscreenchange")},s.Qi=function(){var t=this.H.error();this.error(t)},s.Ki=function(){var t=null;arguments.length>1&&(t=arguments[1]),this.trigger("textdata",t)},s.getCache=function(){return this.pi},s.us=function(t,i){if(this.H&&!this.H.j)this.H.ready((function(){this[t](i)}),!0);else try{this.H&&this.H[t](i)}catch(t){throw qi(t),t}},s.Zi=function(t){if(this.H&&this.H.j)try{return this.H[t]()}catch(i){throw void 0===this.H[t]?qi("Video.js: "+t+" method not defined for "+this.Ni+" playback technology.",i):"TypeError"===i.name?(qi("Video.js: "+t+" unavailable on "+this.Ni+" playback technology element.",i),this.H.j=!1):qi(i),i}},s.play=function(){return this.src()||this.currentSrc()?this.us("play"):this.H.one("loadstart",(function(){this.play()})),this},s.pause=function(){return this.us("pause"),this},s.paused=function(){return!1!==this.Zi("paused")},s.scrubbing=function(t){return void 0!==t?(this.yi=!!t,t?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing"),this):this.yi},s.currentTime=function(t){return void 0!==t?(this.us("setCurrentTime",t),this):(this.pi.currentTime=this.Zi("currentTime")||0,this.pi.currentTime)},s.duration=function(t){return void 0===t?void 0!==this.pi.duration?this.pi.duration:NaN:((t=S(t))<0&&(t=1/0),t!==this.pi.duration&&(this.pi.duration=t,t===1/0?this.addClass("vjs-live"):this.removeClass("vjs-live"),this.trigger("durationchange")),this)},s.remainingTime=function(){return this.duration()-this.currentTime()},s.buffered=function(){var t=this.Zi("buffered");return t&&t.length||(t=we(0,0)),t},s.bufferedPercent=function(){return ke(this.buffered(),this.duration())},s.bufferedEnd=function(){var t=this.buffered(),i=this.duration(),s=t.end(t.length-1);return s>i&&(s=i),s},s.volume=function(t){var i;return void 0!==t?(i=x.max(0,x.min(1,S(t))),this.pi.volume=i,this.us("setVolume",i),this):(i=S(this.Zi("volume")),j(i)?1:i)},s.muted=function(t){return void 0!==t?(this.us("setMuted",t),this):this.Zi("muted")||!1},s.supportsFullScreen=function(){return this.Zi("supportsFullScreen")||!1},s.isFullscreen=function(t){return void 0!==t?(this.cs=!!t,this):!!this.cs},s.requestFullscreen=function(t){var i,s=je;return this.isFullscreen(!0),s.requestFullscreen?(te(Ii,s.fullscreenchange,ce(this,(function t(i){this.isFullscreen(Ii[s.fullscreenElement]),!1===this.isFullscreen()&&ie(Ii,s.fullscreenchange,t),this.trigger("fullscreenchange")}))),s.prefixed||(i=this.h.fullscreenOptions,void 0!==t&&(i=t)),this.v[s.requestFullscreen](i)):this.H.supportsFullScreen()?this.us("enterFullScreen"):(this.enterFullWindow(),this.trigger("fullscreenchange")),this},s.exitFullscreen=function(){var t=je;return this.isFullscreen(!1),t.requestFullscreen?Ii[t.exitFullscreen]():this.H.supportsFullScreen()?this.us("exitFullScreen"):(this.exitFullWindow(),this.trigger("fullscreenchange")),this},s.enterFullWindow=function(){this.isFullWindow=!0,this.docOrigOverflow=Ii.documentElement.style.overflow,te(Ii,"keydown",ce(this,this.fullWindowOnEscKey)),Ii.documentElement.style.overflow="hidden",cs(Ii.body,"vjs-full-window"),this.trigger("enterFullWindow")},s.fullWindowOnEscKey=function(t){27===t.keyCode&&(!0===this.isFullscreen()?this.exitFullscreen():this.exitFullWindow())},s.exitFullWindow=function(){this.isFullWindow=!1,ie(Ii,"keydown",this.fullWindowOnEscKey),Ii.documentElement.style.overflow=this.docOrigOverflow,ls(Ii.body,"vjs-full-window"),this.trigger("exitFullWindow")},s.canPlayType=function(t){for(var i,s=0,e=this.h.techOrder;s<e.length;s++){var n=le(e[s]),r=Yr.getTech(n);if(r||(r=fe.getComponent(n)),r){if(r.isSupported()&&(i=r.canPlayType(t)))return i}else qi.error('The "'+n+'" tech is undefined. Skipped browser support check for that tech.')}return""},s.selectSource=function(t){var i,s=this,e=this.h.techOrder.map(le).map((function(t){return[t,Yr.getTech(t)||fe.getComponent(t)]})).filter((function(t){var i=t[0],s=t[1];return s?s.isSupported():(qi.error('The "'+i+'" tech is undefined. Skipped browser support check for that tech.'),!1)})),n=function(t,i,s){var e;return t.some((function(t){return i.some((function(i){if(e=s(t,i))return!0}))})),e},r=function(t,i){var e=t[0];if(t[1].canPlaySource(i,s.h[e.toLowerCase()]))return{source:i,tech:e}};return(this.h.sourceOrder?n(t,e,(i=r,function(t,s){return i(s,t)})):n(e,t,r))||!1},s.src=function(t){if(void 0===t)return this.Zi("src");var i=Yr.getTech(this.Ni);return i||(i=fe.getComponent(this.Ni)),Array.isArray(t)?this.ls(t):"string"==typeof t?this.src({src:t}):t instanceof _&&(t.type&&!i.canPlaySource(t,this.h[this.Ni.toLowerCase()])?this.ls([t]):(this.pi.sources=null,this.pi.source=t,this.pi.src=t.src,this.Bi=t.type||"",this.ready((function(){i.prototype.hasOwnProperty("setSource")?this.us("setSource",t):this.us("src",t.src),"auto"===this.h.preload&&this.load(),this.h.autoplay&&this.play()}),!0))),this},s.ls=function(t){var i=this.selectSource(t);i?(i.tech===this.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())},s.load=function(){return this.us("load"),this},s.reset=function(){return this._t(le(this.h.techOrder[0]),null),this.us("reset"),this},s.currentSources=function(){var t=this.currentSource(),i=[];return 0!==_.keys(t).length&&i.push(t),this.pi.sources||i},s.currentSource=function(){var t={},i=this.currentSrc();return i&&(t.src=i),this.pi.source||t},s.currentSrc=function(){return this.Zi("currentSrc")||this.pi.src||""},s.currentType=function(){return this.Bi||""},s.preload=function(t){return void 0!==t?(this.us("setPreload",t),this.h.preload=t,this):this.Zi("preload")},s.autoplay=function(t){return void 0!==t?(this.us("setAutoplay",t),this.h.autoplay=t,this):this.Zi("autoplay",t)},s.playsinline=function(t){return void 0!==t?(this.us("setPlaysinline",t),this.h.playsinline=t,this):this.Zi("playsinline")},s.loop=function(t){return void 0!==t?(this.us("setLoop",t),this.h.loop=t,this):this.Zi("loop")},s.poster=function(t){return void 0===t?this.mi:(t||(t=""),this.mi=t,this.us("setPoster",t),this.trigger("posterchange"),this)},s.Yi=function(){!this.mi&&this.H&&this.H.poster&&(this.mi=this.H.poster()||"",this.trigger("posterchange"))},s.controls=function(t){return void 0!==t?(t=!!t,this.gi!==t&&(this.gi=t,this.usingNativeControls()&&this.us("setControls",t),t?(this.removeClass("vjs-controls-disabled"),this.addClass("vjs-controls-enabled"),this.trigger("controlsenabled"),this.usingNativeControls()||this.ts()):(this.removeClass("vjs-controls-enabled"),this.addClass("vjs-controls-disabled"),this.trigger("controlsdisabled"),this.usingNativeControls()||this.ss())),this):!!this.gi},s.usingNativeControls=function(t){return void 0!==t?(t=!!t,this.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},s.error=function(t){return void 0===t?this.lt||null:null===t?(this.lt=t,this.removeClass("vjs-error"),this.errorDisplay&&this.errorDisplay.close(),this):(this.lt=new Ae(t),this.addClass("vjs-error"),qi.error("(CODE:"+this.lt.code+" "+Ae.errorTypes[this.lt.code]+")",this.lt.message,this.lt),this.trigger("error"),this)},s.reportUserActivity=function(t){this.fs=!0},s.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},s.wi=function(){var t,i,s,e,n=ce(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)},s.playbackRate=function(t){return void 0!==t?(this.us("setPlaybackRate",t),this):this.H&&this.H.featuresPlaybackRate?this.Zi("playbackRate"):1},s.isAudio=function(t){return void 0!==t?(this.ps=!!t,this):!!this.ps},s.videoTracks=function(){return this.H?this.H.videoTracks():(this.rt=this.rt||new Gr,this.rt)},s.audioTracks=function(){return this.H?this.H.audioTracks():(this.ht=this.ht||new Jr,this.ht)},s.textTracks=function(){if(this.H)return this.H.textTracks()},s.remoteTextTracks=function(){if(this.H)return this.H.remoteTextTracks()},s.remoteTextTrackEls=function(){if(this.H)return this.H.remoteTextTrackEls()},s.addTextTrack=function(t,i,s){if(this.H)return this.H.addTextTrack(t,i,s)},s.addRemoteTextTrack=function(t,i){if(this.H)return this.H.addRemoteTextTrack(t,i)},s.removeRemoteTextTrack=function(t){var i=(void 0===t?{}:t).track,s=void 0===i?arguments[0]:i;if(this.H)return this.H.removeRemoteTextTrack(s)},s.getVideoPlaybackQuality=function(){return this.Zi("getVideoPlaybackQuality")},s.videoWidth=function(){return this.H&&this.H.videoWidth&&this.H.videoWidth()||0},s.videoHeight=function(){return this.H&&this.H.videoHeight&&this.H.videoHeight()||0},s.language=function(t){return void 0===t?this.gs:(this.gs!==String(t).toLowerCase()&&(this.gs=String(t).toLowerCase(),void 0!==this.v&&this.trigger("languagechange")),this)},s.languages=function(){return de(i.prototype.h.languages,this.vi)},s.toJSON=function(){var t=de(this.h),i=t.tracks;t.tracks=[];for(var s=0;s<i.length;s++){var e=i[s];(e=de(e)).player=void 0,t.tracks[s]=e}return t},s.createModal=function(t,i){var s=this;(i=i||{}).content=t||"";var e=new Fe(this,i);return this.addChild(e),e.on("dispose",(function(){s.removeChild(e)})),e.open()},i.getTagSettings=function(t){var i={sources:[],tracks:[]},s=vs(t),e=s["data-setup"];if(us(t,"vjs-fluid")&&(s.fluid=!0),null!==e){var n=Pe(e||"{}"),r=n[0],h=n[1];r&&qi.error(r),Ui(s,h)}if(Ui(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(vs(c)):"track"===l&&i.tracks.push(vs(c))}return i},s.bi=function(){var t=Ii.createElement("i");return!("flexBasis"in t.style||"webkitFlexBasis"in t.style||"mozFlexBasis"in t.style||"msFlexBasis"in t.style||"msFlexOrder"in t.style)},i}(fe);_o.players={};var xo=p.navigator;_o.prototype.h={techOrder:["html5","flash"],html5:{},flash:{},defaultVolume:0,inactivityTimeout:2e3,playbackRates:[],children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","controlBar","errorDisplay","textTrackSettings"],language:xo&&(xo.languages&&xo.languages[0]||xo.userLanguage||xo.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",fullscreenOptions:{navigationUI:"hide"}},["ended","seeking","seekable","networkState","readyState"].forEach((function(t){_o.prototype[t]=function(){return this.Zi(t)}})),ko.forEach((function(t){_o.prototype["handleTech"+le(t)+"_"]=function(){return this.trigger(t)}})),fe.registerComponent("Player",_o);var Co,So,jo=function(t){function i(s){var e;void 0===s&&(s={});var n=de(s,{kind:Re[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(zs)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return _.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||pe(e)}return ge(i,t),i}(Ue),To=function(t){function i(s){var e;void 0===s&&(s={});var n=de(s,{kind:$e[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(zs)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return _.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||pe(e)}return ge(i,t),i}(Ue);function Mo(t,i,s){var e;if("string"==typeof t){if(0===t.indexOf("#")&&(t=t.slice(1)),Mo.getPlayers()[t])return i&&qi.warn('Player "'+t+'" is already initialised. Options will not be applied.'),s&&Mo.getPlayers()[t].ready(s),Mo.getPlayers()[t];e=function(t){return 0===t.indexOf("#")&&(t=t.slice(1)),Ii.getElementById(t)}(t)}else e=t;if(!e||!e.nodeName)throw new w("The element or ID supplied is not valid. (videojs)");if(e.player||_o.players[e.playerId])return e.player||_o.players[e.playerId];i=i||{},Mo.hooks("beforesetup").forEach((function(t){var s=t(e,de(i));zi(s)&&!Array.isArray(s)?i=de(i,s):qi.error("please return an object in beforesetup hooks")}));var n=new(fe.getComponent("Player"))(e,i,s);return Mo.hooks("setup").forEach((function(t){return t(n)})),n}"undefined"==typeof HTMLVideoElement&&Ki()&&(Ii.createElement("video"),Ii.createElement("audio"),Ii.createElement("track")),Mo.ys={},Mo.hooks=function(t,i){return Mo.ys[t]=Mo.ys[t]||[],i&&(Mo.ys[t]=Mo.ys[t].concat(i)),Mo.ys[t]},Mo.hook=function(t,i){Mo.hooks(t,i)},Mo.removeHook=function(t,i){var s=Mo.hooks(t).indexOf(i);return!(s<=-1)&&(Mo.ys[t]=Mo.ys[t].slice(),Mo.ys[t].splice(s,1),!0)},!0!==p.VIDEOJS_NO_DYNAMIC_STYLE&&Ki()&&((Co=Cs(".vjs-styles-defaults"))||(Co=ae("vjs-styles-defaults"),(So=Cs("head"))&&So.insertBefore(Co,So.firstChild),ue(Co,"\n .video-js {\n width: 300px;\n height: 150px;\n }\n\n .vjs-fluid {\n padding-top: 56.25%\n }\n "))),oe(1,Mo),Mo.VERSION="5.20.6-opentelly.14",Mo.options=_o.prototype.h,Mo.getPlayers=function(){return _o.players},Mo.players=_o.players,Mo.getComponent=fe.getComponent,Mo.registerComponent=function(t,i){Yr.isTech(i)&&qi.warn("The "+t+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),fe.registerComponent.call(fe,t,i)},Mo.getTech=Yr.getTech,Mo.registerTech=Yr.registerTech,Mo.browser=Xs,Mo.TOUCH_ENABLED=Ws,Mo.extend=function(t,i){void 0===i&&(i={});var s=function(){t.apply(this,arguments)},e={};for(var n in zi(i)?("function"==typeof i.init&&(qi.warn("Constructor logic via init() is deprecated; please use constructor() instead."),i.constructor=i.init),i.constructor!==_.prototype.constructor&&(s=i.constructor),e=i):"function"==typeof i&&(s=i),function(t,i){if("function"!=typeof i&&null!==i)throw new w("Super expression must either be null or a function, not "+typeof i);t.prototype=_.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},Mo.mergeOptions=de,Mo.bind=ce,Mo.plugin=function(t,i){_o.prototype[t]=i},Mo.addLanguage=function(t,i){var s;return t=(""+t).toLowerCase(),Mo.options.languages=de(Mo.options.languages,((s={})[t]=i,s)),Mo.options.languages[t]},Mo.log=qi,Mo.createTimeRange=Mo.createTimeRanges=we,Mo.formatTime=lh,Mo.parseUrl=ze,Mo.isCrossOrigin=Le,Mo.EventTarget=ve,Mo.on=te,Mo.one=ee,Mo.off=ie,Mo.trigger=se,Mo.xhr=Fr,Mo.TextTrack=Vr,Mo.AudioTrack=jo,Mo.VideoTrack=To,Mo.isEl=Zi,Mo.isTextNode=bs,Mo.createEl=is,Mo.hasClass=us,Mo.addClass=cs,Mo.removeClass=ls,Mo.toggleClass=ds,Mo.setAttributes=fs,Mo.getAttributes=vs,Mo.emptyEl=ws,Mo.appendContent=ks,Mo.insertContent=_s,Mo.computedStyle=yh,d(),d();var Ao=10;function Po(t){const i=t.duration;if(j(i)){var s;const i=null==(s=t.source)?void 0:s.streamType;return"live"===i||"dvr"===i}return i===1/0}function Eo(t){return t.scrubbing()?t.getCache().currentTime:t.currentTime()}function No(t){const i=Fo(t);return Po(t)?i.end(i.length-1):i.start(0)}function Io(t){return Fo(t).start(0)}function Bo(t){const i=Fo(t);return i.end(i.length-1)-i.start(0)}function Fo(t){const i=t.seekable;if(i&&i.length)return i;let s=t.duration;return s=isFinite(s)?s:0,new Ft([0,s]).ws()}function Do(t,i){void 0===i&&(i=t);let s=t<0?"-":"";t=x.abs(t);let e=x.floor(t%60),n=x.floor(t/60%60),r=x.floor(t/3600);const h=x.floor(i/60%60),o=x.floor(i/3600);return(j(t)||t===1/0)&&(r=n=e="-"),r=+r>0||o>0?r+":":"",n=((r||h>=10)&&+n<10?"0"+n:n)+":",e=+e<10?"0"+e:e,s+r+n+e}function $o(t){return class extends t{get ks(){var t;return null!=(t=this._s)?t:this._s=Ro(this.player())}dispose(){this._s=void 0,super.dispose()}constructor(...t){super(...t),this._s=void 0}}}function Ro(t){return t.tech({IWillNotUseThisInPlugins:!0}).theoplayer()}function Oo(t){const i=Ro(t),s=()=>{const s=Eo(t);t.toggleClass("theo-at-live",function(t,i){if(Po(t)){let s=t.seekable;return 0===s.length||s.end(s.length-1)-i<Ao}return!1}(i,s)),t.toggleClass("vjs-live",Po(i)),t.toggleClass("theo-dvr",function(t){var i;return"dvr"===Ct(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)}d(),d();var Vo="theo-ad-playing",Uo="theo-dai-ad-playing";function zo(t,i,s){t.toggleClass(Vo,i),t.toggleClass(Uo,i&&s)}function Lo(){this.userActive(!1)}d(),d(),d();var Ho=class{constructor(t,i){this.type=t.type,this.target=i,this.playerEvent=t}},qo=["loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange","resize"],Wo=Mo.getTech("Tech"),Go=Mo.getTech("Html5"),Xo=class extends Wo{xs(){var t;for(const t of qo)this.ks.addEventListener(t,this.Cs);this.ks.addEventListener("error",this.Ss),this.ks.addEventListener("contentprotectionerror",this.Ss),this.ks.addEventListener("sourcechange",this.js),this.ks.addEventListener("loadstart",this.Ts),null==(t=this.ks.presentation)||t.addEventListener("presentationmodechange",this.Ms),this.ks.textTracks.addEventListener("addtrack",this.As),this.ks.textTracks.addEventListener("removetrack",this.Ps),this.ks.textTracks.addEventListener("change",this.Es),this.ks.audioTracks.addEventListener("addtrack",this.Ns),this.ks.audioTracks.addEventListener("removetrack",this.Is),this.ks.audioTracks.addEventListener("change",this.Bs)}Fs(){var t;for(const t of qo)this.ks.removeEventListener(t,this.Cs);this.ks.removeEventListener("error",this.Ss),this.ks.removeEventListener("contentprotectionerror",this.Ss),this.ks.removeEventListener("sourcechange",this.js),this.ks.removeEventListener("loadstart",this.Ts),null==(t=this.ks.presentation)||t.removeEventListener("presentationmodechange",this.Ms),this.ks.textTracks.removeEventListener("addtrack",this.As),this.ks.textTracks.removeEventListener("removetrack",this.Ps),this.ks.textTracks.removeEventListener("change",this.Es),this.ks.audioTracks.removeEventListener("addtrack",this.Ns),this.ks.audioTracks.removeEventListener("removetrack",this.Is),this.ks.audioTracks.removeEventListener("change",this.Bs)}Ds(t){this.trigger(new Ho(t,this))}createEl(){let t=this.h,i=t.player;if(!i)throw new b(this.localize('Missing required tech option "player"'));let s=i.element;return Mo.setAttributes(s,{id:t.techId}),s}theoplayer(){return this.ks}addTextTrack(t,i,s){return super.addTextTrack(t,i,s)}buffered(){return this.ks.buffered}played(){return this.ks.played}reset(){this.ks.stop()}play(){this.ks.play()}pause(){this.ks.pause()}paused(){return this.ks.paused}currentTime(){return this.ks.currentTime}setCurrentTime(t){this.ks.currentTime=t}duration(){return this.ks.duration}volume(){return this.ks.volume}setVolume(t){this.ks.volume=t}muted(){return this.ks.muted}setMuted(t){this.ks.muted=t}src(t){if(void 0!==t)this.setSrc(t);else{if(this.ks.src)return this.ks.src;if(this.ks.source){if(!hi(this.ks.source.ads))return this.ks.source.ads[0].sources;if(Dt(this.ks.source))return"This source is managed by the Verizon Media integration extension.";if(Bt(this.ks.source))return"This source is managed by the DAI integration extension.";if(Rt(this.ks.source))return"This source is managed by Millicast."}}}setSrc(t){return this.setSource({src:t})}setSource(t){this.lt=null,this.trigger("error")}currentSrc(){return this.ks.src}load(){this.setPreload("auto")}preload(){return this.ks.preload}setPreload(t){this.ks.preload=t}autoplay(){return this.ks.autoplay}setAutoplay(t){this.ks.autoplay=!!t}seeking(){return this.ks.seeking}seekable(){return this.ks.seekable}ended(){return this.ks.ended}playbackRate(){return this.ks.playbackRate}setPlaybackRate(t){this.ks.playbackRate=t}readyState(){return this.ks.readyState}networkState(){return 0}controls(){return!1}videoHeight(){return this.ks.videoHeight}videoWidth(){return this.ks.videoWidth}supportsFullScreen(){return this.ks.presentation.supportsMode(Kt.FULLSCREEN)}enterFullScreen(){this.ks.presentation.requestMode(Kt.FULLSCREEN)}exitFullScreen(){this.ks.presentation.requestMode(Kt.INLINE)}$s(){let t=this.ks.ads;if(t&&t.playing)return!0;let i=this.ks.vr;return!(!i||i.state===Mt.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.ks=null,super.dispose()}static isSupported(){return!0}static canPlayType(){return"maybe"}static canPlaySource(t){return"maybe"}get featuresVolumeControl(){return ki}constructor(t={},i){super(t,i),this.Cs=t=>this.Ds(t),this.Os=!1,this.js=()=>{void 0===this.ks.errorObject&&(this.Ds(new Vt(this.ks.currentTime,this.ks.readyState)),this.Ds(new Ci),this.Ds(new zt(this.ks.duration)))},this.Ts=()=>{this.Ds(new Tt(this.ks.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.Is=t=>{this.audioTracks().it(t.track)},this.Es=()=>{let t=this.textTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Bs=()=>{let t=this.audioTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Ms=()=>{if(!this.supportsFullScreen())return;let t=this.Os,i=this.ks.presentation.currentMode===Kt.FULLSCREEN;t!==i&&(this.Os=i,this.trigger("fullscreenchange",{isFullscreen:i,nativeIOSFullscreen:!0}))},this.Ss=()=>{const t=this.ks.errorObject,i=t&<(t.code)||-1,s=t&&t.message||"An unknown error occurred.";this.error({code:i,message:this.localize(s)})},this.ks=this.h.player,this.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()}};Xo.prototype.featuresFullscreenResize=Go.prototype.featuresFullscreenResize,Xo.prototype.featuresPlaybackRate=Go.prototype.featuresPlaybackRate,Xo.prototype.featuresProgressEvents=!0,Xo.prototype.featuresTimeupdateEvents=!0,Xo.prototype.featuresNativeTextTracks=!0,Mo.registerTech("THEOplayer",Xo),d(),d(),d(),d();var Jo=class{constructor(t){this.Vs=t=>{oi(this.Us,"theo-mobile-button-hover"),t.stopImmediatePropagation()},this.zs=t=>{ui(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)}};d(),d(),d(),d();var Qo=Mo.getComponent("Menu"),Yo=class extends($o(Qo)){get Hs(){return this.player().el()}qs(){oi(this.Hs,"theo-menu-opened")}Ws(){ui(this.Hs,"theo-menu-opened")}constructor(t,i){super(t,i)}};d();var Ko=Mo.getComponent("MenuItem"),Zo=class extends($o(Ko)){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(){$t.Ys.Qs&&(this.el().removeEventListener("touchstart",this.Vs),this.el().removeEventListener("touchend",this.zs)),super.dispose()}constructor(t,i,s){super(t,xi({selectable:!0},i)),this.Xs=!1,this.Vs=t=>{oi(this.el(),"theo-mobile-menu-item-hover"),t.stopImmediatePropagation()},this.zs=t=>{ui(this.el(),"theo-mobile-menu-item-hover")},this.Gs=s,$t.Ys.Qs&&(this.el().addEventListener("touchstart",this.Vs),this.el().addEventListener("touchend",this.zs))}};d();var ta=Mo.getComponent("ClickableComponent"),ia=class extends ta{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)}},sa=class extends Yo{get menuHeader(){return this.se}get menuItems(){return this.children()}addMenuItem(t){t=xi({playerOptions:this.h.playerOptions},t);let i=new Zo(this.player(),t,this);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}addSubMenuItem(t){t=xi({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();$t.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(),$t.Ys.Qs&&(this.el().removeAttribute("style"),this.contentEl().removeAttribute("style"))}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=this.contentEl();oi(i,"theo-menu-content");let s=new ia(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)}},ea=class extends sa{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(){ui(this.ye,"vjs-hidden"),this.ye.style.opacity="1",super.show()}be(){oi(this.ye,"vjs-hidden")}qs(){this.ce&&this.ce.qs(),super.qs()}Ws(){this.ce&&this.ce.Ws(),super.Ws(),oi(this.ye,"vjs-hidden")}he(){if(this.ce&&this.ce.we)return this.ce.we.ye}ae(t,i){if(i.length>0){let t=i[0].height,s=i[0].width;this.le.ke.style.height=t+"px",this.le.ke.style.width=s+"px"}super.ae(t,i)}constructor(t,i){super(t,i)}};d();var na=class{get ke(){return this.Us}get we(){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.we.focus(),$t.Ys.Qs)s.be();else{const t="translateX(100%)",e="translateX(-100%)",n=vi("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(){ai((()=>{ui(this.Us,"theo-no-transition"),ui(this._e.ye,"theo-no-transition")}))}xe(){oi(this.Us,"theo-no-transition"),oi(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()}};d(),d();var ra=class extends ea{get ye(){return this.el()}get parentMenu(){return this.je}ee(t,i){let s=new ha(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}},ha=class extends Zo{get subMenu(){return this.Ae}handleClick(t){this.parentMenu.ve(this.subMenu)}constructor(t,i,s){super(t,xi({selectable:!1},i),s),this.Ae=new ra(t,i,s)}},oa=class extends ea{get menuButton(){return this.Pe}createEl(){let t=Mo.createEl("div",{className:this.buildCSSClass()});return this.Ee=super.createEl(),this.Ee.className=super.buildCSSClass(),oi(this.Ee,"theo-menu-content-animatable"),t.appendChild(this.Ee),this.ce=new na(this),t.appendChild(this.ce.ke),t}buildCSSClass(){return"theo-menu-animatable "+super.buildCSSClass()}ee(t,i){let s=new ha(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=S(getComputedStyle(this.el()).fontSize);U(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}};d();var aa=class{set Ie(t){this.Be.innerHTML=this.Fe.localize(t),this.De(),this.$e(),pi(this.Fe.el())}get Ie(){return this.Be.textContent||""}Re(){this.Fe.off("mouseover",this.$e),this.Fe.off("mouseout",this.De),this.Fe.off("dispose",this.Oe),ii(this.Be)}constructor(t,i){this.$e=()=>{ui(this.Be,"vjs-hidden");let t=this.Fe.player().contentEl().getClientRects(),i=t.length>0?t[0]:void 0,s=S(getComputedStyle(this.Be).fontSize);U(this.Be,this.Fe.el(),i,s)},this.De=()=>{oi(this.Be,"vjs-hidden")},this.Oe=()=>this.Re(),this.Fe=t,pi(t.el()),gi(t.el()),this.Be=h.createElement("span"),this.Be.innerHTML=this.Fe.localize(i),this.Be.className="theo-button-tooltip vjs-hidden",this.Be.setAttribute("aria-hidden","true"),this.Fe.el().appendChild(this.Be),this.Fe.on("mouseover",this.$e),this.Fe.on("mouseout",this.De),this.Fe.on("dispose",this.Oe)}},ua=Mo.getComponent("Button"),ca=class extends($o(ua)){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.Be.Ie=this.controlText()}dispose(){this.player().removeChild(this.Ue),this.Ue.dispose(),this.Be.Re(),this.ks.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;$t.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 oa(t,i,this),this.player().getChild("controlBarMenuContainer").addChild(this.Ue),this.Be=new aa(this,this.controlText()),this.el().setAttribute("aria-haspopup","true"),$t.Ys.Je?(this.on(h,"touchend",this.Ge),new Jo(this.el())):(this.on(h,"click",this.Ge),this.on(h,"keydown",this.Xe),wi&&this.on(h,wi.Qe,this.closeMenu)),this.ks.addEventListener("seeking",this.We),this.on(this.Ue,"menuchange",this.qe),this.on(t,"languagechange",this.te),this.qe()}},la=Mo.getComponent("Component"),da=class extends(Mo.getComponent("ControlBar")){addMenuButton(t){t=xi({playerOptions:this.h.playerOptions},t);let i=new ca(this.player(),t);return this.addChild(i),i}removeMenuButton(t){this.removeChild(t)}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-secondary-color vjs-control-bar "+super.buildCSSClass()}constructor(t,i){super(t,i),this.addChild("THEOControlBarShadow",void 0,0)}};Mo.registerComponent("THEOControlBarShadow",class extends la{createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-tertiary-color theo-control-bar-shadow"}}),d(),d();var fa=Mo.getComponent("VolumeBar"),va=class extends fa{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}};d();var pa=Mo.getComponent("VolumeControl"),ma=class extends pa{constructor(t,i){super(t,i),this.Ze=new va(t,{Ke:this}),this.addChild(this.Ze)}};ma.prototype.h=xi({},pa.prototype.h,{children:[]}),Mo.registerComponent("VolumeControl",ma);var ga=class extends($o(da)){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.ks.textTrackStyle.marginBottom=void 0)}dn(){const t=this.el().getBoundingClientRect().height;this.ks.textTrackStyle.marginBottom!==t&&(this.ks.textTrackStyle.marginBottom=t)}dispose(){c(this.hn),this.hn=0,this.vn.fn(ci.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 mi(this.el()),this.vn.yn(ci.pn,this.mn),this.vn.bn(!0)}};ga.prototype.h=xi({},da.prototype.h,{children:["progressControl","playToggle","muteToggle","volumeControl","currentTimeDisplay","timeDivider","durationDisplay","liveDisplay","remainingTimeDisplay","customControlSpacer","activeQualityLabel","vrButton","descriptionsButton","subtitlesButton","chromecastButton","airplayButton","multiViewButton","audioTrackButton","SettingsButton","fullscreenToggle"]}),Mo.registerComponent("ControlBar",ga),d();var ya=class extends da{buildCSSClass(){return"theo-top-controlbar "+super.buildCSSClass()}constructor(t,i){super(t,i),t.topControlBar=this}};ya.prototype.h=xi({},da.prototype.h,{children:[]}),Mo.registerComponent("TopControlBar",ya),d();var ba=Mo.getComponent("CurrentTimeDisplay"),wa=class extends($o(ba)){updateContent(){const t=Eo(this.player()),i=this.ks,s=Io(i),e=this.localize("Current Time"),n=Do(x.max(0,t-s),Bo(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)}};Mo.registerComponent("CurrentTimeDisplay",wa),d();var ka=Mo.getComponent("DurationDisplay"),_a=class extends($o(ka)){updateContent(){const t=this.ks,i=j(t.duration)?NaN:Bo(t),s=t.clip.endTime-t.clip.startTime,e=x.min(i,s)||0;if(this.ct!==e){this.ct=e;const t=this.localize("Duration Time"),i=Do(e);this.S.innerHTML='<span class="vjs-control-text">'+t+"</span> "+i}}dispose(){var t;null==(t=this.ks)||t.clip.removeEventListener("change",this.wn),super.dispose()}constructor(t,i){var s;super(t,i),this.wn=()=>this.updateContent(),this.off(t,"durationchange",this.updateContent),this.on(t,"durationchange",this.updateContent),this.off(t,"timeupdate",this.updateContent),this.on(t,"timeupdate",this.updateContent),this.off(t,"emptied",this.updateContent),this.on(t,"emptied",this.updateContent),null==(s=this.ks)||s.clip.addEventListener("change",this.wn)}};Mo.registerComponent("DurationDisplay",_a),d();var xa=Mo.getComponent("Button"),Ca=class extends($o(xa)){buildCSSClass(){return"theo-live-control "+super.buildCSSClass()}createEl(){let t=super.createEl("button",{},{"aria-live":"off"});return this.kn=Mo.createEl("span",{className:"theo-live-control-indicator"}),ei(t,this.kn),t}createControlTextEl(t){let i=super.createControlTextEl(t);return Mo.removeClass(i,"vjs-control-text"),Mo.addClass(i,"theo-live-control-text"),i}handleClick(){var t;const i=this.ks;if(void 0!==(null==(t=i.hesp)?void 0:t.manifest))i.hesp.goLive();else{const t=this.player();t.currentTime(No(i)),t.play()}}_n(){Po(this.ks)?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),$t.Ys.Je&&new Jo(this.el())}};Mo.registerComponent("LiveDisplay",Ca),d();var Sa=Mo.getComponent("LoadingSpinner");Mo.registerComponent("LoadingSpinner",class extends Sa{buildCSSClass(){return"theo-secondary-color vjs-loading-spinner "+super.buildCSSClass()}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=Mo.createEl("div",{className:"theo-loading-spinner-rotator"}),s=Mo.createEl("div",{className:"theo-loading-spinner-circle-left"}),e=Mo.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)}}),d();var ja=Mo.getComponent("LoadProgressBar"),Ta=class extends($o(ja)){update(){let t=this.ks,i=Ft.xn(Fo(t)),s=i.Cn(0),e=Ft.xn(t.buffered).Sn(i),n=i.jn(0)-s,r=e.U&&e.jn(e.U-1)||0;r=x.max(0,r-s);let o=this.el(),a=this.Tn;o.style.width=Ma(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=Ma(i-s,r),u.style.width=Ma(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 Ma(t,i){let s=t/i||0;return 100*(s>=1?1:s)+"%"}Mo.registerComponent("LoadProgressBar",Ta),d();var Aa=Mo.getComponent("MouseTimeDisplay"),Pa=class extends($o(Aa)){handleMouseMove(t){let i=t,s=this.ks,e=Io(s)+this.calculateDistance(i)*Bo(s),n=i.pageX-O(this.el().parentNode).left;this.update(e,n+"px")}handleTouchMove(t){let i=t,s=this.ks,e=Io(s)+this.calculateDistance(i)*Bo(s),n=i.touches[0].pageX-O(this.el().parentNode).left;this.update(e,n+"px")}createEl(){let t=super.createEl();return this.Mn=Mo.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&&(f(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=S(getComputedStyle(t).fontSize);U(this.tooltip,this.el(),s,e)}}Pn(t){const i=this.ks,s=t-No(i);return Do(Po(i)?x.min(s,0):s,Bo(i))}dispose(){var t;this.ks.removeEventListener("dimensionchange",this.Nn),null==(t=this.ks.presentation)||t.removeEventListener("presentationmodechange",this.Nn),super.dispose()}constructor(t,i){var s;(super(t,i),this.An=NaN,this.Nn=()=>{let t=Eo(this.player());const i=this.ks;let s=(t-Io(i))/Bo(i)||0;s=Yt(s,0,1),this.update(t,100*s+"%")},this.keepTooltipsInside&&(Mo.addClass(this.tooltip,"theo-secondary-color"),this.tooltip.appendChild(this.Mn)),this.on(t,"ready",(()=>{this.on(t.controlBar.progressControl,"mouseenter",this.handleMouseMove)})),Ot.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.ks.addEventListener("dimensionchange",this.Nn),null==(s=this.ks.presentation)||s.addEventListener("presentationmodechange",this.Nn),this.on(t,"ready",(()=>{this.on(t.controlBar.progressControl,"touchstart",this.handleTouchMove),this.on(t.controlBar.progressControl,"touchmove",Jt((t=>this.handleTouchMove(t)),25)),this.Nn()})))}};Mo.registerComponent("MouseTimeDisplay",Pa),d();var Ea=Mo.getComponent("PlayProgressBar"),Na=class extends($o(Ea)){updateDataAttr(){let t=Eo(this.player());this.el().setAttribute("data-current-time",this.Pn(t))}Pn(t){let i=this.ks;return Do(t-No(i),Bo(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)}};Mo.registerComponent("PlayProgressBar",Na),d();var Ia=Mo.getComponent("RemainingTimeDisplay"),Ba=class extends($o(Ia)){updateContent(){const t=this.ks,i=Bo(t);if(i){const s=Fo(t).end(0),e=this.localize("Remaining Time"),n=Do(x.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)}};Mo.registerComponent("RemainingTimeDisplay",Ba),d(),d();var Fa=class{get ks(){return this._s||(this._s=this.In.tech({IWillNotUseThisInPlugins:!0}).theoplayer()),this._s}Bn(t){if(t.kind!==bt.Fn)return;if(0===this.ks.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 Da(s,this.ks,n);this.On.push(r),this.Vn.appendChild(r.ke)}t.addEventListener("cuechange",this.Un),this.Un()}zn(){this.ks.addEventListener("loadedmetadata",this.Ln),this.ks.addEventListener("loadeddata",this.Ln),this.ks.addEventListener("sourcechange",this.Ln),this.ks.textTracks.addEventListener("addtrack",this.Hn),this.ks.textTracks.addEventListener("removetrack",this.qn),this.ks.textTracks.addEventListener("change",this.Ln)}Wn(){this.ks.removeEventListener("loadedmetadata",this.Ln),this.ks.removeEventListener("loadeddata",this.Ln),this.ks.removeEventListener("sourcechange",this.Ln),this.ks.textTracks.removeEventListener("addtrack",this.Hn),this.ks.textTracks.removeEventListener("removetrack",this.qn),this.ks.textTracks.removeEventListener("change",this.Ln)}Gn(){if(!(this.ks.readyState<St.Xn))for(let t of this.ks.textTracks)if(t.kind===bt.Fn&&t.mode===gt.Jn&&t.cues.length>0&&t.readyState!==ft.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.In=i,this.On=[],this._s=void 0,this.Hn=t=>{let i=t.track;i.kind===bt.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===bt.Fn&&(i.removeEventListener("addcue",this.Ln),i.removeEventListener("removecue",this.Ln),i.removeEventListener("readystatechange",this.Ln)),this.Ln()},this.er=t=>{let i=this.ks,s=function(t,i){let s,e,n=O(t),r=t.offsetWidth,h=t.offsetHeight,o=n.top,a=n.left;!function(t){return void 0!==t.changedTouches}(i)?(e=i.pageX,s=i.pageY):(e=i.changedTouches[0].pageX,s=i.changedTouches[0].pageY);let u=Yt((o-s+h)/h,0,1),c=Yt((e-a)/r,0,1);return{x:c,y:u}}(this.Vn,t),e=Io(i)+s.x*Bo(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.Bn(t))},this.Un=()=>{var t,i,s;const e=null==(i=this.Dn)||null==(t=i.activeCues)?void 0:t[0],n=D(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 $a,this.In.contentEl().appendChild(this.Rn.ke),this.Vn=h.createElement("div"),oi(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()}},Da=class{get ke(){return this.Us}ur(){oi(this.Us,"theoplayer-chapter-indicator-active")}ar(){ui(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");oi(o,"theoplayer-chapter-indicator");let a=h.createElement("div");oi(a,"theoplayer-chapter-indicator-highlight"),o.appendChild(a),i&&oi(o,"theoplayer-chapter-indicator-discontinuous");let u=x.min(n/e*100,100),c=100-u,l=x.min(r/e*100,c);return o.style.width=l+"%",o.style.left=u+"%",o}Re(){ii(this.Us)}constructor(t,i,s){this.hr=t,this.Us=this.cr(i,s)}},$a=class{be(){this.lr--,0===this.lr&&ui(this.ke,"theoplayer-chapter-hovering")}$n(t){this.dr=t||[],this.dr.length>0&&(this.ke.style.display="")}pr(t){f(this.mr,t.content)}tr(){this.dr=[],f(this.mr,""),this.ke.style.display="none"}ge(){this.lr++,this.lr>0&&oi(this.ke,"theoplayer-chapter-hovering")}Yn(t){for(let i of this.dr)if(Ra(i,t)){this.pr(i);break}}Re(){ii(this.ke)}constructor(){this.dr=[],this.lr=0,this.ke=h.createElement("div"),oi(this.ke,"theoplayer-chaptertitle"),this.ke.style.display="none",this.mr=h.createElement("p"),this.ke.appendChild(this.mr)}};function Ra(t,i){return new Ft([t.startTime,t.endTime]).gr(i)}var Oa=Mo.getComponent("SeekBar"),Va=class extends($o(Oa)){updateAriaAttributes(t){const i=Eo(this.player()),s=this.ks;t.setAttribute("aria-valuenow",(100*this.yr(i)).toFixed(2)),t.setAttribute("aria-valuetext",Do(i-No(s),Bo(s)))}getPercent(){return this.yr(this.player().currentTime())}handleMouseMove(t){if(this.ks&&this.ks.ads&&this.ks.ads.playing)return;const i=this.ks;let s=Io(i)+this.calculateDistance(t)*Bo(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.ks,s=(t-Io(i))/Bo(i);return Yt(s,0,1)}dispose(){this.Vn.Re(),z(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 Fa(this.el(),t)}};Mo.registerComponent("SeekBar",Va),d();var Ua=Mo.getComponent("ProgressControl");$t.Ys.Qs&&Mo.registerComponent("ProgressControl",class extends Ua{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"])}}),d();var za=Mo.getComponent("TooltipProgressBar"),La=class extends($o(za)){updateDataAttr(){let t=Eo(this.player()),i=this.Pn(t);this.el().setAttribute("data-current-time",i),this.tooltip.innerHTML=i}Pn(t){const i=this.ks;return Do(t-No(i),Bo(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 Ha(t){for(const i of t)if(i.enabled)return i}function qa(t){if(t)return t.label&&""!==t.label?{name:t.label,hd:!1}:{name:Wa(t),description:Ga(t),hd:!!t.height&&t.height>=720}}function Wa(t){return t.height?t.height+"p":t.bandwidth?Ga(t):""}function Ga(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":""}Mo.registerComponent("TooltipProgressBar",La),d(),d(),d(),d(),d();var Xa=class{get br(){return this.wr}set br(t){let i=this.wr;for(let s=i.length-1;s>=0;s--){let e=i[s];V(t,e)||this.kr(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)){V(this.wr,t)||this.wr.push(t);let i=this.jr(t)||this.Mr(t);return this.Nr(i),i}this.kr(t)}kr(t){let i=this.jr(t);i&&(this.Cr.removeMenuItem(i),this.Pr(i)),R(this.wr,t)}Re(){const t=[];for(let i of this.wr)t.push(i);for(let i of t)this.kr(i);z(t)}constructor(t){this.wr=[],this.Cr=t}},Ja=class extends Xa{Ir(){return this.Br=h.createElement("span"),this.Br.className="theo-settings-control-menu-item-title",f(this.Br,this.Fr.localize("Quality")),this.Br}Dr(){return this.$r=h.createElement("span"),this.$r.className="theo-settings-control-menu-quality-automatic",f(this.$r,this.Fr.localize("Automatic")),this.$r}Rr(){return this.Or=h.createElement("span"),f(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",f(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.Br),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&&su(t.targetQuality),s=t&&t.activeQuality,e=qa(this.Wr(i||s))||{name:this.Fr.localize("Automatic")};f(this.Or,e.name),li(this.$r,"vjs-hidden",!!i),li(this.Ur,"vjs-hidden",!e.hd)}Nr(t){let i=qa(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=Ha(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=Ya(tu(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=Ya(tu(i.qualities.filter((t=>t.available)))),e=i&&su(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=Ha(this._s.videoTracks),i=t&&su(t.targetQuality),s=this.Wr(i),e=this.Gr;s!==e&&(this.Gr=s,s&&e||this._r(void 0),e&&V(this.br,e)&&this._r(e),i&&this._r(s),this.Hr())},this.te=()=>{f(this.Cr.menuHeader.el(),this.Fr.localize("Quality")),f(this.Br,this.Fr.localize("Quality")),f(this.$r,this.Fr.localize("Automatic")),f(this.Or,this.Fr.localize("Automatic")),f(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.Br=this.Ir(),this.$r=this.Dr(),this.Or=this.Rr(),this.Ur=this.Vr(),this.zr(),f(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()}},Qa=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 Ya(t){let i=[];for(let s of t){let t=s,e=!1;for(let s of i)if(iu(s,t)){s.add(t),e=!0;break}e||i.push(new Qa([t]))}return i}function Ka(t,i){return t&&i?B(t,i):N.Zr}function Za(t,i){return t===i?N.Zr:Ka(t.height,i.height)||Ka(t.width,i.width)||Ka(t.bandwidth,i.bandwidth)}function tu(t){return P(t,Za).reverse()}function iu(t,i){return t.label&&i.label&&t.label===i.label||et(qa(t),qa(i))}function su(t){return Lt(t)?1===t.length?t[0]:void 0:t}function eu(t){return 1===t?"Normal":""+x.round(100*t)/100}d();var nu=class extends Xa{Ir(){return this.Br=h.createElement("span"),this.Br.className="theo-settings-control-menu-item-title",f(this.Br,this.Fr.localize("Speed")),this.Br}zr(){const t=h.createElement("span");return t.className="theo-primary-color theo-settings-control-menu-item-value",this.Lr.el().appendChild(this.Br),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(eu(i));f(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,f(this.sh,this.Fr.localize(eu(t))),t&&this._r(t)},this.te=()=>{f(this.Cr.menuHeader.el(),this.Fr.localize("Speed")),f(this.Br,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.Br=this.Ir(),this.sh=this.zr(),f(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()}};Mo.registerComponent("SettingsButton",class extends ca{createEl(){let t=super.createEl();return this.eh=Mo.createEl("span",{className:"theo-settings-control-label-hd theo-primary-background"}),f(this.eh,this.localize("HD")),t.appendChild(this.eh),t}buildCSSClass(){return"vjs-icon-cog theo-settings-control-button "+super.buildCSSClass()}te(){super.te(),f(this.eh,this.localize("HD")),f(this.menu.menuHeader.el(),this.localize("Settings"))}dispose(){this.qr&&(this.qr.removeEventListener("activequalitychanged",this.Jr),this.qr=void 0),this.ks.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=Ha(this.ks.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)},oi(this.menu.el(),"theo-settings-control-menu"),f(this.menu.menuHeader.el(),t.localize("Settings")),this.controlText("Settings"),this.Be.Ie=this.controlText(),this.oh=this.menu.addSubMenuItem({name:"QualityMenuItem"}),this.rh=new Ja(this.oh,this.ks,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 nu(this.ah,this.ks,t,n),this.ks.videoTracks.addEventListener(["addtrack","removetrack","change"],this.nh),this.nh()}}),d(),d(),d();var ru=class extends Xa{uh(t){let i=t.label;if(i)return i;let s=t.language;if(s){let t=yt(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.kr(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()}},hu=class extends ru{Nr(t){let i=t.Tr,s=this.Fr.localize(this.uh(i));f(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.ks.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=()=>{f(this.Cr.menuHeader.el(),this.Fr.localize("Language"));for(const t of this.Sr)this.Nr(t)},this.ks=i,this.Fr=s,f(this.Cr.menuHeader.el(),this.Fr.localize("Language")),this.Fr.on("languagechange",this.te)}};Mo.registerComponent("audioTrackButton",class extends ca{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 hu(this.menu,this.ks,t),this.controlText("Language"),this.Be.Ie=this.controlText()}}),d(),d();var ou=class extends ru{Er(t){return!!super.Er(t)&&(!t.forced&&xt(t.kind))}Mr(t){let i=super.Mr(t);oi(i.el(),"theo-text-track-menu-item");let s=h.createElement("span");i.wh=s;let e=h.createElement("div");e.className="theo-text-track-menu-item-toggle",i.kh=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));f(i.wh,e),i.el().setAttribute("aria-label",this.Fr.localize("Set the subtitle language to")+" "+e),i.el().setAttribute("role","menuitemcheckbox"),i.selected(s.mode===gt.Jn)}Pr(t){let i=t;i.kh.removeEventListener("click",i.xh),super.Pr(t)}Ar(t){let i=t.Tr;for(let t of this.ks.textTracks)t!==i&&kt(t.kind,i.kind)&&(t.mode=gt.Ch);i.mode!==gt.Jn?i.mode=gt.Jn:i.mode=gt.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=()=>{f(this.Cr.menuHeader.el(),this.Fr.localize("Subtitles"));for(const t of this.Sr)this.Nr(t)},this.ks=i,this.Fr=s,f(this.Cr.menuHeader.el(),s.localize("Subtitles")),this.Fr.on("languagechange",this.te)}};Mo.registerComponent("subtitlesButton",class extends ca{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 ou(this.menu,this.ks,t),this.controlText("Subtitles"),this.Be.Ie=this.controlText()}}),d();var au=Mo.getComponent("playToggle"),uu=class extends($o(au)){handleClick(t){this.ks.muted||this.ks.prepareWithUserAction(),super.handleClick(t)}handlePlay(t){super.handlePlay(t),this.controlText("Pause"),this.Be.Ie=this.controlText()}handlePause(t){this.ks.ended||(super.handlePause(t),this.controlText("Play"),this.Be.Ie=this.controlText())}te(){this.Be.Ie=this.controlText()}dispose(){this.Be.Re(),this.ks.removeEventListener("ended",this.Sh),super.dispose()}constructor(t,i){super(t,i),this.Sh=()=>{this.controlText("Replay"),this.Be.Ie=this.controlText()},this.controlText("Play"),this.Be=new aa(this,this.controlText()),this.ks.addEventListener("ended",this.Sh),this.on(t,"languagechange",this.te),$t.Ys.Je&&new Jo(this.el())}};Mo.registerComponent("playToggle",uu),d();var cu=Mo.getComponent("fullscreenToggle"),lu=class extends($o(cu)){handleClick(t){this.ks.prepareWithUserAction(),super.handleClick(t)}handleFullscreenChange(t){super.handleFullscreenChange(t),this.updateContent()}updateContent(){const t=this.player().isFullscreen()?"Exit fullscreen":"Fullscreen";this.controlText(t),this.Be.Ie=this.controlText()}dispose(){this.Be.Re(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Fullscreen"),this.Be=new aa(this,this.controlText()),$t.Ys.Je&&new Jo(this.el()),this.on(t,"languagechange",this.updateContent)}};Mo.registerComponent("fullscreenToggle",lu),d();var du=Mo.getComponent("muteToggle"),fu=class extends($o(du)){handleClick(t){this.ks.muted&&!this.ks.paused&&this.ks.prepareWithUserAction(),super.handleClick(t)}update(t){super.update(t),this.te()}te(){const t=this.player().muted()?"Unmute":"Mute";this.controlText(t),this.Be.Ie=this.controlText()}dispose(){this.Be.Re(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Mute"),this.Be=new aa(this,this.controlText()),$t.Ys.Je&&new Jo(this.el()),this.on(t,"languagechange",this.te),bi&&(this.removeClass("vjs-hidden"),this.on(t,"loadstart",(()=>{this.removeClass("vjs-hidden")})))}};Mo.registerComponent("muteToggle",fu),d();var vu=Mo.getComponent("BigPlayButton"),pu="theo-play-svg-circle",mu='<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="'+pu+'" 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>',gu=class extends($o(vu)){createEl(){let t=super.createEl(),i=Mo.createEl("div",{className:"theo-big-play-button-svg-container"});return i.innerHTML=mu,t.appendChild(i),t}buildCSSClass(){return"theo-primary-color "+super.buildCSSClass()}handleClick(t){this.ks.muted||this.ks.prepareWithUserAction(),super.handleClick(t),void 0!==this.ks.vr&&"unavailable"!==this.ks.vr.state&&(this.ks.vr.useDeviceMotionControls=!0)}};Mo.registerComponent("BigPlayButton",gu),d();var yu=/^([^#]*)#xywh=(\d+),(\d+),(\d+),(\d+)\s*$/;Mo.registerComponent("MouseTimeDisplay",class extends Pa{jh(t){const i=t.track;"metadata"===i.kind&&"thumbnails"===i.label&&void 0===this.Th&&(this.Th=i,this.Mh=i.src?$t.Ah(i.src).href:void 0,this.Th.addEventListener(["addcue","removecue"],this.Ph),this.Eh())}Nh(t){t.track===this.Th&&this.Ih()}createEl(){const t=super.createEl();return this.Bh=Mo.createEl("img",{className:"theo-time-tooltip-thumbnail"}),this.Fh=Mo.createEl("canvas",{className:"theo-time-tooltip-thumbnail"}),t}update(t,i){super.update(t,i),this.keepTooltipsInside&&this.Dh(t)}Dh(t){let i;if(this.Th&&this.Th.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.Th.cues,t);i=s&&s.content}if(i===this.$h)return;if(this.$h=i,Mo.toggleClass(this.el(),"theo-time-tooltip-has-thumbnail",!!i),!i)return void this.Rh();const s=i.match(yu);if(s){let[,t,i,e,n,r]=s;t=this.Oh(t);const h={Vh:+i,Uh:+e,ji:+n,Ti:+r};this.zh(t,h)}else{const t=this.Oh(i);this.zh(t)}}Eh(){j(this.An)||this.Dh(this.An)}Oh(t){return this.Th&&this.Mh?$t.Ah(t,this.Mh).href:t}zh(t,i){this.Bh&&(this.Bh.src!==t?(this.Bh.onload=()=>{this.Lh(i)},this.Bh.src="",this.Bh.src=t):this.Lh(i))}Lh(t){if(!this.Fh||!this.Bh)return;const i=this.Fh.getContext("2d");i&&(null!=t||(t={Vh:0,Uh:0,ji:this.Bh.naturalWidth,Ti:this.Bh.naturalHeight}),this.Fh.width=t.ji,this.Fh.height=t.Ti,i.drawImage(this.Bh,t.Vh,t.Uh,t.ji,t.Ti,0,0,t.ji,t.Ti),this.Hh(this.Fh))}Hh(t){this.qh||(ei(this.tooltip,t),this.qh=t),this.En()}Rh(){this.qh&&(this.tooltip.removeChild(this.qh),this.qh=void 0,this.En())}Ih(){void 0!==this.Th&&(this.Th.removeEventListener(["addcue","removecue"],this.Ph),this.Th=void 0),this.Mh=void 0,this.Rh(),this.$h=void 0}dispose(){this.Ih(),super.dispose()}constructor(t,i){super(t,i),this.qh=void 0,this.Th=void 0,this.Mh=void 0,this.Wh=t=>this.jh(t),this.Gh=t=>this.Nh(t),this.Ph=t=>this.Eh(),this.showThumbnails=()=>{this.qh&&this.qh.hidden&&(this.qh.hidden=!1,this.En())},this.hideThumbnails=()=>{!this.qh||this.qh.hidden||this.player().scrubbing()||(this.qh.hidden=!0,this.En())},this.on(this.player().textTracks(),"addtrack",this.Wh),this.on(this.player().textTracks(),"removetrack",this.Gh),Ot.Qs&&(this.on(t,"seeking",this.showThumbnails),this.on(t,"seeked",this.hideThumbnails))}}),d();var bu=Mo.getComponent("VolumeLevel");Mo.registerComponent("VolumeLevel",class extends bu{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-volume-level "+super.buildCSSClass()}}),d(),d();var wu=Mo.getComponent("Component"),ku=class extends wu{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-menu-container "+super.buildCSSClass()}};ku.prototype.h=xi({},ku.prototype.h,{children:[]}),Mo.registerComponent("controlBarMenuContainer",ku);var _u=Mo.getComponent("Player"),xu=class extends _u{dispose(){const t=this.el(),i=this.contentEl(),s=t.parentNode,e=t.nextSibling;super.dispose(),ii(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)}};xu.prototype.h=xi({},_u.prototype.h,{children:["bigPlayButton","AdControlPanel","TopControlBar","mediaLoader","upNextContainer","posterImage","chromecastOverlay","upcomingAdNotificationText","controlBarMenuContainer","controlBar","textTrackDisplay","loadingSpinner","errorDisplay","textTrackSettings","xrCompass"]}),Mo.registerComponent("Player",xu),d(),d();var Cu=Mo.getComponent("Player"),Su=Cu.prototype.es;Cu.prototype.es=function(t){if(!(this.H&&this.H.$s&&this.H.$s()))return Su.call(this,t)};var ju=Cu.prototype.createEl;function Tu(t,i,e,n){let r=xi({controls:!0,playbackRates:[.25,.5,1,1.25,1.5,2]},e);r.controlBar=xi({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&&qt(e.language)&&(r.languages=xi({},r.languages,{[mt]:e.language}),r.language=mt),i.setAttribute("data-vjs-player","");let o=i.getAttribute("style"),a=Mo(t.element,r,n);return a.ready((()=>{Oo(a),function(t,i){if(i){if(i.ads){const s=i=>{const s="adbreakbegin"===i.type,e=i.adBreak.integration===wt.Xh;zo(t,s,e)};i.ads.addEventListener("adbreakbegin",s),i.ads.addEventListener("adbreakend",s)}if(i.verizonMedia){const s=i=>{const s="adbreakbegin"===i.type;zo(t,s,!1)};i.verizonMedia.ads.adBreaks.addEventListener("addadbreak",(t=>{t.adBreak.addEventListener("adbreakbegin",s),t.adBreak.addEventListener("adbreakend",s)}))}i.addEventListener("sourcechange",(()=>{zo(t,!1,!1)}))}}(a,t),function(t){t.on("mouseleave",Lo)}(a)})),i.removeAttribute("data-vjs-player"),o?i.setAttribute("style",o):i.removeAttribute("style"),$t.Ys.Qs&&(oi(i,"theo-mobile"),function(t){let i=s.outerHeight,e=s.outerWidth,n=i>e;n?(ui(t,"theo-mobile-landscape"),oi(t,"theo-mobile-portrait")):(ui(t,"theo-mobile-portrait"),oi(t,"theo-mobile-landscape"))}(i)),function(t){t.on("seeking",(()=>{ri(t.el(),"vjs-ended")&&t.currentTime()!==t.duration()&&t.play()}))}(a),a}Cu.prototype.createEl=function(){let t=ju.call(this),i=Mo.createEl("div");for(i.className="theo-player-wrapper";t.firstChild;)i.appendChild(t.firstChild);return t.appendChild(i),this.S=i,t},d(),d(),d(),d();var Mu=Mo.getComponent("Button");var Au="THEOPiPCloseButton";Mo.registerComponent(Au,class extends Mu{buildCSSClass(){return"theo-close-button theo-pip-close"}handleClick(){this.Qh.Jh()}constructor(t,i){if(super(t,i),this.controlText("Close Picture-in-Picture"),!function(t){return!!t&&Boolean(t.Qh)}(i))throw new b("Invalid Picture-in-picture options.");this.Qh=i.Qh}});var Pu=class extends H{get Yh(){return this.Kh}get Zh(){return this.t.cs()}io(){this.t.yn(G.so,this.eo),this.no||this.t.yn(G.ro,this.ho),this.t.oo.on("languagechange",this.te)}ao(){var t;return"theo-pip-"+(null!=(t=this.uo)?t:"bottom-right")}co(t){let i=this.lo;i&&!this.Zh&&(this.do||this.fo(),this.vo(),oi(i,"theo-pip"),oi(i,this.ao()),this.Kh=!0,this.po=t,this.mo=!1,this.yo(new Xt(Kt.PICTURE_IN_PICTURE)))}bo(t){let i=this.lo;i&&(this.wo(),ui(i,"theo-pip"),ui(i,this.ao()),this.Kh=!1,this.mo=t,this.ko=this.po,this.po=!1,this.yo(new Xt(Kt.INLINE)))}fo(){if(!this.do){let t=this.t.oo;t.addChild(Au,{Qh:this});let i=h.createElement("div");i.className="theo-pip-overlay",this._o=h.createElement("div"),this._o.className="theo-pip-overlay-text",f(this._o,t.localize("Video playing in Picture-in-Picture mode")),i.appendChild(this._o),ei(t.el(),i),this.xo=i,this.do=!0}}Co(){this.So&&!this.jo&&this.t.To&&(this.Mo=this.t.To.Ao(X,this.Po),this.jo=!0)}Eo(){this.Mo&&this.t.To&&(this.t.To.No(this.Mo),this.jo=!1)}vo(){let t=this.t.oo.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"}wo(){let t=this.t.oo.contentEl();t.style.top="",t.style.bottom="",t.style.right="",t.style.left="",t.style.width="",t.style.height="",t.style.position=""}Io(){ui(this.lo,"theo-pip"),this.Yh&&this.uo&&ui(this.lo,"theo-pip-"+this.uo),this.xo&&(ii(this.xo),this.xo=void 0)}gn(){this.Io(),this.Eo(),this.Bo(),this.t.fn(G.so,this.eo),this.t.fn(G.ro,this.ho),this.t.oo.off("languagechange",this.te),this.t=void 0}constructor(t,i,s){super(),this.Fo=!1,this.Kh=!1,this.mo=!1,this.po=!1,this.do=!1,this.jo=!1,this.ko=!1,this.eo=()=>{this.Fo=!0,this.So&&!this.Yh&&this.Mo&&this.Do&&this.Mo.$o<=this.Do&&this.co(!1)},this.ho=()=>{this.no||(this.Fo=!1,this.bo(!1))},this.te=()=>{if(this._o){const t=this.t.oo;f(this._o,t.localize("Video playing in Picture-in-Picture mode"))}},this.Po=t=>{!this.po&&this.So&&(j(t)||(this.Do&&t<=this.Do||this.ko?this.Kh||this.mo||this.co(!1):this.Kh?this.bo(!1):this.mo=!1))},this.Do=i.visibility,this.uo=i.position,this.no=i.retainPresentationModeOnSourceChange,this.So=void 0!==this.Do,this.t=t,this.lo=t.Ro,this.Jh=s,this.io()}},Eu=class extends ti{Oo(){let t=super.Oo();return t===Kt.INLINE&&this.Vo&&this.Vo.Yh?Kt.PICTURE_IN_PICTURE:t}Uo(t){return t===Kt.PICTURE_IN_PICTURE||super.Uo(t)}zo(t,i){t===Kt.FULLSCREEN&&this.Vo.Eo(),super.zo(t,i),t!==Kt.FULLSCREEN&&this.Vo.Co()}Lo(t,i){t!==i&&(t===Kt.FULLSCREEN&&this.Vo.bo(!1),t===Kt.INLINE&&i===Kt.PICTURE_IN_PICTURE&&this.Vo.bo(!0),super.Lo(t,i),t===Kt.PICTURE_IN_PICTURE&&(i===Kt.INLINE?this.Vo.co(!0):this.Vo.co(!1)))}gn(){super.gn(),this.Vo.gn(),this.Ho.fn(G.so,this.qo),this.Ho=void 0}constructor(t,i,s){super(i),this.Wo=()=>this.Yr(),this.Jh=()=>this.Go(Kt.INLINE),this.qo=()=>{this.Oo()!==Kt.FULLSCREEN&&this.Vo.Co(),this.Ho.fn(G.so,this.qo)},this.Ho=t,this.Vo=new Pu(t,s.pip,this.Jh),this.Vo.yn("presentationmodechange",this.Wo),this.Ho.yn(G.so,this.qo),this.Yr()}};d();var Nu,Iu=class extends H{get Xo(){return _i.Jo(this.oo.el())||this.oo.supportsFullScreen()}get cs(){return this.oo.isFullscreen()||this.Qo}co(){this.oo.requestFullscreen()}bo(){this.oo.exitFullscreen(),this.Yo.bo()}gn(){this.Bo(),this.oo.off("fullscreenchange",this.Ko),this.Yo.fn(Wt.Zo,this.Ko),this.Yo.fn(Wt.ta,this.Ds),this.oo.isFullWindow&&this.oo.exitFullscreen()}constructor(t,i){super(),this.Os=!1,this.Qo=!1,this.ia=!1,this.Ko=()=>{if(this.ia)return;const t=this.Os,i=this.cs;t!==i&&(this.Os=i,this.yo(new yi))},this.sa=()=>{this.Qo=this.Yo.cs,this.Ko()},this.ea=()=>{this.ia||(this.oo.isFullWindow&&this.oo.supportsFullScreen()||this.Qo&&!this.oo.supportsFullScreen())&&(this.ia=!0,this.oo.exitFullscreen(),this.oo.requestFullscreen(),this.ia=!1,this.Ko())},this.oo=t,this.Yo=i,this.oo.on("fullscreenchange",this.Ko),this.Yo.yn(Wt.Zo,this.sa),this.Yo.yn(Wt.na,this.ea),this.Yo.yn(Wt.ta,this.Ds),this.Ko()}};function Bu(t){return class extends t{get To(){return this.ra}cs(){return"fullscreen"===this.ha.Oo()}oa(){return function(t,i){let s=_.create(t);const e=i.oo;return it(s,{get controls(){return e.controls()},set controls(t){e.controls(ot(t))},get presentation(){return i.ha.aa},get presentationMode(){return i.ha.Oo()},set presentationMode(t){const s=si(t);s&&i.ha.Go(s)},get ui(){return e},get visibility(){return i.To.aa}})}(this.ua,this)}gn(){super.gn(),this.ha.gn(),this.ca.gn(),this.oo.dispose(),this.ra.gn()}la(t){this.oo.src(""),super.la(t)}constructor(t,i,s){super(i,s),this.Ro=t,this.ra=new Q(t),this.ua=super.oa(),_.defineProperty(this.ua,"constructor",{value:st}),this.oo=Tu(this.ua,this.Ro,s.ui),this.ca=new Iu(this.oo,this.da),this.ha=new Eu(this,this.ca,s),this.ha.yn("presentationmodechange",this.Ds)}}}function Fu(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(Ut(t)&&!j(t))return Yt(t,0,1)}(t.visibility),t.retainPresentationModeOnSourceChange=ot(t.retainPresentationModeOnSourceChange),t}function Du(){return Nu||(Nu=function(t){let i=t;for(const t of Ai)i=t(i);return i}(Nu=Bu(tt()))),Nu}function $u(t,i){const s=function(t){const i=Ht(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=Fu(i.pip),i}(i),e=h.createElement("div");fi(e),t.appendChild(e);const n=new(Du())(t,e,s);n.fa=n;let r=n.aa;return n.va(),n.pa(K),_.defineProperty(r,"constructor",{value:$u}),r=Z(r),It(n),function(t){for(const i of Ei)i(t)}(n),r}d(),d(),d(),d(),d();var Ru="theo-cast-",Ou=Mo.getComponent("Button"),Vu=class extends($o(Ou)){get ma(){throw new b("ga")}get ya(){return this.h.ya}get ba(){return this.h.ba}buildCSSClass(){return Ru+"button theo-"+this.ba+"-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=Ru+"svg-container",r.innerHTML=this.ya,e.appendChild(n),e.appendChild(r),e}handleClick(t){var i;if(super.handleClick(t),this.wa===ni.AVAILABLE)null==(i=this.ma)||i.start();else if(this.wa===ni.CONNECTED||this.wa===ni.CONNECTING){var s;null==(s=this.ma)||s.stop()}}ka(t){ui(this.lo,"theo-"+this.ba+"-"+this.wa),this.wa=t,oi(this.lo,"theo-"+this.ba+"-"+this.wa),this.te()}te(){this._a(this.wa),this.Be.Ie=this.controlText()}_a(t){t===ni.CONNECTED?this.controlText("Stop Casting"):t===ni.AVAILABLE?this.controlText("Start Casting"):t===ni.CONNECTING?this.controlText("Connecting"):this.controlText("Unavailable")}constructor(t,i){var s;super(t,i),this.lo=t.el(),this.wa=ni.UNAVAILABLE,this.controlText("Unavailable"),this.Be=new aa(this,this.controlText()),null==(s=this.ma)||s.addEventListener("statechange",(t=>{const i=t;this.ka(i.state)})),$t.Ys.Je&&(this.xa=new Jo(this.el())),this.ka(this.ma?this.ma.state:ni.UNAVAILABLE),this.on(t,"languagechange",this.te)}},Uu=0;function zu(){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-'+Uu+'">\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-'+Uu+')">\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 Uu++,t}Mo.registerComponent("chromecastButton",class extends Vu{get ma(){var t;return null==(t=this.ks.cast)?void 0:t.chromecast}constructor(t,i){super(t,xi({},i,{ba:"chromecast",ya:zu()}))}}),d();var Lu="theo-chromecast-",Hu=Mo.getComponent("Component"),qu=class t extends($o(Hu)){buildCSSClass(){return Lu+"overlay "+super.buildCSSClass()}createEl(){const i=super.createEl();oi(i,Lu+"overlay");const s=Mo.createEl("div",{className:Lu+"status-icon",innerHTML:t.ICON_SVG}),e=Mo.createEl("div",{className:Lu+"status-info"});f(e,"Playing on");const n=Mo.createEl("div",{className:Lu+"status-title"}),r=Mo.createEl("div",{className:Lu+"status"});return this.mr=n,r.appendChild(s),r.appendChild(e),r.appendChild(n),i.appendChild(r),i}dispose(){var t;null==(t=this.Ca)||t.removeEventListener("statechange",this.update),this.Ca=void 0,this.ks.removeEventListener("play",this.update),super.dispose()}constructor(t,i){var s,e;super(t,i),this.update=()=>{this.Ca?(this.mr&&f(this.mr,this.Ca.receiverName||""),this.Ca.state===ni.CONNECTED?this.show():this.hide()):this.hide()},this.Ca=null==(s=this.ks.cast)?void 0:s.chromecast,null==(e=this.Ca)||e.addEventListener("statechange",this.update),this.ks.addEventListener("play",this.update),this.update()}};qu.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>',Mo.registerComponent("chromecastOverlay",qu),d(),d();Mo.registerComponent("airplayButton",class extends Vu{dispose(){var t,i;null==(t=this.ks.ads)||t.removeEventListener("adbreakbegin",this.Sa),null==(i=this.ks.ads)||i.removeEventListener("adbreakend",this.ja),this.ks.removeEventListener("currentsourcechange",this.ja),super.dispose()}get ma(){var t;return null==(t=this.ks.cast)?void 0:t.airplay}constructor(t,i){var s,e;super(t,xi({},i,{ba:"airplay",ya:'\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.ja=()=>{this.enable()},this.Sa=()=>{this.disable()},null==(s=this.ks.ads)||s.addEventListener("adbreakbegin",this.Sa),null==(e=this.ks.ads)||e.addEventListener("adbreakend",this.ja),this.ks.addEventListener("currentsourcechange",this.ja)}}),d(),d(),d();var Wu=Mo.getComponent("Button"),Gu=class extends($o(Wu)){buildCSSClass(){return"theo-vr-button theo-controlbar-button "+super.buildCSSClass()}handleClick(){this.ks.vr.stereo=!this.ks.vr.stereo,this.te()}_n(){this.ks.vr&&this.ks.vr.state!==Mt.Rs?(this.show(),this.ks.vr.canPresentVR?(this.enable(),this.te()):(this.disable(),this.controlText("No VR capable device found"),this.Ta.Ie=this.controlText())):this.hide()}te(){var t;this.controlText((null==(t=this.ks.vr)?void 0:t.stereo)?"Stop watching in VR":"Watch in VR"),this.Ta.Ie=this.controlText()}dispose(){var t;null==(t=this.ks.vr)||t.removeEventListener("statechange",this.Ma),super.dispose()}constructor(t,i){var s;super(t,i),this.Ma=()=>this._n(),this.controlText("Watch in VR"),this.Ta=new aa(this,this.controlText()),null==(s=this.ks.vr)||s.addEventListener("statechange",this.Ma),this._n(),$t.Ys.Je&&new Jo(this.el()),this.on(t,"languagechange",this.te)}};Mo.registerComponent("vrButton",Gu),d();var Xu=Mo.getComponent("Component"),Ju=class extends Xu{createEl(){let t=super.createEl("div",{className:this.buildCSSClass()}),i=Mo.createEl("div",{className:"theo-360-fov"});return t.appendChild(i),this.Aa=i,t}buildCSSClass(){return"theo-360-compass "+super.buildCSSClass()}_n(){this.ks.vr.state===Mt.Rs?this.hide():this.show()}Pa(){let t=-this.ks.vr.direction.yaw+40;this.Aa.style[vi("transform")]="scale(0.875) rotate("+t+"deg) skew("+"-10deg)"}dispose(){this.ks.vr.removeEventListener("statechange",this.Ma),this.ks.vr.removeEventListener("directionchange",this.Ea),super.dispose()}constructor(t,i,s){super(t,i),this.Ma=()=>this._n(),this.Ea=()=>this.Pa(),this.ks=s,this.ks.vr.addEventListener("statechange",this.Ma),this.ks.vr.addEventListener("directionchange",this.Ea),this._n(),this.Pa()}};d();var Qu=x.pow(2,31)-1,Yu=Mo.getComponent("Component"),Ku=class extends Yu{Na(){this.ks.vr.state===Mt.Ia?this.Ba():this.Fa()}Ba(){if(this.Da)return;this.Da=!0;let t=this.ks.element;this.$a=t.style.zIndex||"",t.style.zIndex=""+Qu,this.Ra=this.player().isFullscreen(),this.player().requestFullscreen()}Fa(){if(!this.Da)return;this.Da=!1,this.ks.element.style.zIndex=this.$a,this.Ra?this.player().requestFullscreen():this.player().exitFullscreen()}dispose(){this.Fa(),this.ks.vr.removeEventListener("statechange",this.Oa),super.dispose()}constructor(t,i,s){super(t,i),this.Da=!1,this.Ra=!1,this.$a="",this.Oa=()=>this.Na(),this.ks=s,this.ks.vr.addEventListener("statechange",this.Oa),this.Na()}};Ni((function(t){let i=t.aa;if(!i.vr)return;let s=t.oo,e=new Ju(s,{},i);if(t.yn(G.ro,(()=>{var i;s.removeChild(e);let n=null==(i=t.Va())?void 0:i.vr;void 0===n||n.nativeVR||s.addChild(e)})),Ot.Ua){let t=new Ku(s,{},i);s.addChild(t)}})),d(),d(),d();var Zu=class extends W{constructor(){super("relatedchange")}},tc=["relatedchange"],ic=class extends H{get aa(){return this.za||(this.za=function(t){let i,s={get sources(){return t.La},set sources(i){t.La=i},addEventListener(t,s){i.yn(t,s)},removeEventListener(t,s){i.fn(t,s)}};return i=new Qt(tc,!0,s),i.Ha(t),s}(this)),this.za}get La(){return this.qa}set La(t){this.qa=function(t){return t.filter((t=>t&&(Gt(t.link)||rt(t,["source"]))))}(t),t.length>this.qa.length&&console.warn("One or more of the configured related content sources are invalid. Check if they have a source or a link."),this.yo(new Zu)}gn(){this.Bo(),this.qa=[]}constructor(...t){super(...t),this.qa=[]}};Pt((function(t){return class extends t{oa(){const t=this.Wa;return it(super.oa(),{get related(){return t.aa}})}gn(){this.Wa.gn(),super.gn()}constructor(t,i){super(t,i),this.Wa=new ic}}}),M.Ga),d(),d();var sc=Mo.getComponent("Button"),ec=class extends sc{buildCSSClass(){return"vjs-icon-view-grid theo-related-button "+super.buildCSSClass()}handleClick(){this.Ja.Xa?this.Ja.be():this.Ja.ge()}te(){this.Be.Ie=this.controlText()}dispose(){this.player().topControlBar.removeChild(this),super.dispose()}constructor(t,i,s){super(t,s),this.lo=t.el(),this.Ja=i,this.player().topControlBar.addChild(this),this.hide(),this.controlText(this.localize("Related content")),this.Be=new aa(this,this.controlText()),this.on(t,"languagechange",this.te)}};d(),d();var nc=Mo.getComponent("Button"),rc=class extends nc{buildCSSClass(){return"theo-secondary-background theo-close-button"}handleClick(){this.Qa.hide()}constructor(t,i){super(t),this.Qa=i}},hc=(()=>{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 oc(t,i,s){let e=hc.cloneNode(!0),n=e.querySelector(".theo-related-grid-tile-content");rt(s,["source"])?(n.style.cursor="pointer",n.addEventListener("click",(()=>{t.source=s.source,i.be()}))):Gt(s.link)&&n.setAttribute("href",s.link);let r=e.querySelector(".theo-related-grid-tile-image");r.style.backgroundImage='url("'+Ti(s.image)+'")',r.removeAttribute("id");let h=e.querySelector(".theo-related-grid-tile-title");s.title?(f(h,s.title),h.removeAttribute("id")):ii(h);let o=e.querySelector(".theo-related-grid-tile-duration");return s.duration?(f(o,s.duration),o.removeAttribute("id")):ii(o),e}var ac=[15,12,9,8,6,4,3,2,1];var uc=class{get Ya(){return"theo-"+this.Ka+"-item-grid"}Za(){this.tu.focus()}iu(t){this.su(),function(t){if(t.length)for(let i of ac)if(t.length>=i){t.length=i;break}}(t),this.eu(t.length);for(let i of t){let t=oc(this.nu.aa,this.ru,i);this.hu.appendChild(t)}}su(){this.hu.innerHTML=""}ou(){let t=h.createElement("div");t.className="theo-overlay-panel";const i=h.createElement("div");return i.className="theo-related-grid",this.au.className="theo-related",this.tu.controlText("Close Related Content"),this.uu.appendChild(this.au),this.au.appendChild(t),t.appendChild(this.tu.el()),t.appendChild(i),i}eu(t){ui(this.hu,this.Ya),this.Ka=t,oi(this.hu,this.Ya)}gn(){ii(this.au),this.cu.gn(),this.lu.gn(),this.tu.dispose(),this.nu=void 0}constructor(t,i,s,e,n){this.nu=t,this.du=i,this.ru=s,this.uu=e,this.Ka=12,this.fu=t=>{this.hu.style.width=t.width+"px"},this.au=h.createElement("div"),this.tu=new rc(this.du,{hide:()=>{this.ru.be()}}),this.hu=this.ou(),this.lu=new cc(n),this.lu.yn(ci.pn,this.fu),this.cu=new _t(this.hu,this.lu),this.eu(12)}},cc=class extends H{get vu(){return this.pu||0}get mu(){return this.gu.mu}gn(){this.Bo(),this.gu.fn(ci.pn,this.yu)}constructor(t){super(),this.gu=t,this.yu=t=>{let i=t.width;if(9*(t.width/16)>t.height){i=16*(t.height/9)}this.pu=i,this.yo(new di(this.vu,t.height))},this.gu.yn(ci.pn,this.yu)}};d();var lc=class extends W{constructor(){super("show")}};d();var dc=class extends W{constructor(){super("hide")}},fc="theo-related-available",vc="theo-related-showing",pc=[...tc,"show","hide"],mc=class extends H{get aa(){return this.za||(this.za=function(t){let i;const s={get sources(){return t.La},set sources(i){t.La=i},get showing(){return t.Xa},show(){t.ge()},hide(){t.be()},addEventListener(t,s){i.yn(t,s)},removeEventListener(t,s){i.fn(t,s)}};return i=new Qt(pc,!0,s),i.Ha(t),s}(this)),this.za}get La(){return this.bu.La}set La(t){this.bu.La=t}get Xa(){return this.wu}ge(){let t=this.wu;this.wu=!0,this.ku(vc),this._u.Za(),this.du.paused()?this.xu=!0:this.du.pause(),t!==this.wu&&this.yo(new lc)}be(){let t=this.wu;this.wu=!1,this.Cu(vc),this.Su.focus(),this.xu||this.du.play(),this.xu=!1,t!==this.wu&&this.yo(new dc)}ku(t){this.du.el().classList.add(t)}Cu(t){this.du.el().classList.remove(t)}gn(){this.Bo(),this._u.gn()}constructor(t,i,s,e){super(),this.wu=!1,this.xu=!1,this.ju=t=>{const i=this.La;this._u.iu(i),i.length?(this.ku(fc),this.Su.show()):(this.Cu(fc),this.Su.hide()),this.yo(t)},this.bu=i,this.bu.yn("relatedchange",this.ju),this.du=s,this._u=new uc(t,this.du,this,s.contentEl(),e),this.Su=new ec(s,this,{})}};Pi((function(t){return class extends t{oa(){const t=this.Tu;return it(super.oa(),{get related(){return t.aa}})}gn(){this.Tu.gn(),super.gn()}constructor(t,i,s){super(t,i,s),this.Tu=new mc(this,this.Wa,this.oo,this.Mu)}}})),d(),d(),d();var gc=Mo.getComponent("Button"),yc=class extends gc{buildCSSClass(){return"vjs-icon-share theo-social-button "+super.buildCSSClass()}handleClick(){this.Au.showing?this.Au.hide():this.Au.show()}te(){this.Be.Ie=this.controlText()}dispose(){this.player().topControlBar.removeChild(this),super.dispose()}constructor(t,i,s){super(t,s),this.lo=t.el(),this.Au=i,this.player().topControlBar.addChild(this),this.hide(),this.controlText("Share Video"),this.Be=new aa(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="Pu",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",f(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,f(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",f(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="Pu",n.href=i,f(n,i),e.appendChild(n),s.appendChild(e),s}(t,s)}}d();var wc="<URL>";var kc=class{get ke(){return this.au}Eu(t){this.su();for(let i of t)this.Nu(i)}Za(){this.tu.focus()}Nu(t){let i=function(t,i){return t.src?Si(t.src,wc)?t.src.replace(wc,i):t.src:i}(t,this.ru.Iu),s=function(t){if(t)return t.icon?"iconurl":t.text?"text":"texturl"}(t),e=bc(t,s,i);e&&("iconurl"===s?this.Bu.appendChild(e):this.Fu.appendChild(e))}su(){this.Bu.innerHTML="",this.Fu.innerHTML=""}gn(){ii(this.au),this.Du.gn()}constructor(t,i,s,e){this.Ho=t,this.ru=i,this.uu=s,this.$u=e;const n=h.createElement("div");n.className="theo-overlay-panel",this.tu=new rc(this.Ho,this.ru.aa),this.tu.controlText("Close Share"),this._u=h.createElement("div"),this._u.className="theo-social-container",this.au=h.createElement("div"),this.au.className="theo-social",this.Bu=h.createElement("div"),this.Bu.className="theo-social-icon-container",this.Fu=h.createElement("div"),this.Fu.className="theo-social-text-container",this.uu.appendChild(this.au),this.au.appendChild(n),this._u.appendChild(this.Bu),this._u.appendChild(this.Fu),n.appendChild(this.tu.el()),n.appendChild(this._u),this.Du=new _t(this.au,this.$u)}},_c="theo-social-available",xc="theo-social-showing",Cc=class{get aa(){return this.za}get Xa(){return this.wu}get Ru(){return this.Ou}set Ru(t){this.Ou=t,this._u.Eu(t),t.length?(this.ku(_c),this.Su.show()):(this.Cu(_c),this.Su.hide())}get Iu(){return this.Vu||Zt()}set Iu(t){this.Vu=t}ge(){this.wu=!0,this.ku(xc),this._u.Za(),this.Uu.paused()?this.xu=!0:this.Uu.pause()}be(){this.wu=!1,this.Cu(xc),this.Su.focus(),this.xu||this.Uu.play(),this.xu=!1}ku(t){this.Uu.el().classList.add(t)}Cu(t){this.Uu.el().classList.remove(t)}gn(){this.Su.dispose(),this._u.gn()}constructor(t,i){this.wu=!1,this.Ou=[],this.xu=!1,this.za=function(t){return{get showing(){return t.Xa},get items(){return t.Ru},set items(i){t.Ru=i},get url(){return t.Iu},set url(i){t.Iu=i},show(){t.ge()},hide(){t.be()}}}(this),this.Uu=t,this._u=new kc(this.Uu,this,t.contentEl(),i),this.Su=new yc(t,this.za,{})}};Pi((function(t){return class extends t{oa(){let t=this.Au;return it(super.oa(),{get social(){return t.aa}})}constructor(t,i,s){super(t,i,s),this.Au=new Cc(this.oo,this.Mu)}}})),d(),d();var Sc=Mo.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=xi({},jc.prototype.h,{children:[]}),Mo.registerComponent("upNextContainer",jc),d(),d();var Tc="theo-upnext-bar-",Mc=Mo.getComponent("Component"),Ac=class extends Mc{get Xa(){return this.wu}set Xa(t){this.wu=t,this.zu&&(this.zu.tabIndex=t?0:-1)}get Lu(){return this.Hu}set Lu(t){this.Hu=t}la(t){this.su(),this.qu(t)}qu(t){if(t&&t.link&&t.image){const i=h.createElement("div");oi(i,Tc+"content"),i.onclick=()=>{this.Wu.next()},i.onkeypress=t=>{13===t.which&&this.Wu.next()};let s=h.createElement("div");if(s.style.backgroundImage='url("'+Ti(t.image)+'")',oi(s,Tc+"image"),i.appendChild(s),t.duration){let i=h.createElement("span");oi(i,Tc+"duration"),i.innerHTML=""+t.duration,s.appendChild(i)}let e=h.createElement("div");oi(e,Tc+"text");let n=h.createElement("div");if(oi(n,Tc+"upnext"),f(n,this.localize("Up Next")),e.appendChild(n),t.title){let i=h.createElement("div");oi(i,Tc+"title"),f(i,t.title),e.appendChild(i)}i.appendChild(e),this.zu=i,this.Gu=n,this.el().appendChild(this.zu)}}su(){this.el().innerHTML="",this.zu=void 0,this.Gu=void 0}te(){this.Gu&&f(this.Gu,this.localize("Up Next"))}createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-upnext-bar "+super.buildCSSClass()}dispose(){this.Du.gn(),super.dispose()}constructor(t,i,s,e){super(t,s),this.zu=void 0,this.Gu=void 0,this.Wu=i,this.Du=new _t(this.el(),e),this.wu=!1,this.Hu=10,this.on(t,"languagechange",this.te)}};d();var Pc="theo-upnext-panel-",Ec=pu,Nc=Mo.getComponent("Component"),Ic=class extends Nc{get Xa(){return this.wu}set Xa(t){this.wu=t}get Xu(){return this.Ju}set Xu(t){this.Ju=t}get Qu(){return this.Yu}set Qu(t){this.Yu=t}la(t){this.su(),this.Ku(t)}Ku(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("'+Ti(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",f(n,this.localize("Up Next")),e.appendChild(n),t.title){let i=h.createElement("div");i.className=Pc+"title",f(i,t.title),e.appendChild(i)}i.appendChild(e),this.Zu=h.createElement("div"),this.Zu.className=Pc+"autoplay",this.Zu.innerHTML=mu;let r=this.Zu.querySelector("svg");r.onclick=()=>{this.Wu.next()},r.tabIndex=0,r.onkeypress=t=>{13===t.which&&this.Wu.next()},this.tc=n,this.ic=this.Zu.querySelector("."+Ec),i.appendChild(this.Zu),this.el().appendChild(i)}}get sc(){return this.ec}set sc(t){this.ec=t,this.ic.style.strokeDashoffset=""+x.round(1e5*t)/1e5}su(){this.el().innerHTML="",this.tc=void 0,this.ic=void 0}te(){this.tc&&f(this.tc,this.localize("Up Next"))}createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-upnext-panel "+super.buildCSSClass()}dispose(){this.Du.gn(),super.dispose()}constructor(t,i,s,e){super(t,s),this.ec=0,this.Wu=i,this.Du=new _t(this.el(),e),this.wu=!1,this.Ju=10,this.Yu=!0,this.on(t,"languagechange",this.te)}},Bc="theo-upnext-panel-showing",Fc="theo-upnext-bar-showing",Dc=2*x.PI*73,$c=class t{get aa(){return this.za}get nc(){return this.rc}get hc(){return this.oc}get ac(){return this.uc}set ac(t){this.uc=t,this._u.la(t),this.cc.la(t),this.Uu.off("timeupdate",this.lc),this.Uu.off("ended",this.dc),t&&(this.Uu.on("timeupdate",this.lc),this.Uu.on("ended",this.dc))}fc(){this._u.Xu?this.vc=ut(this._u.Xu):0===this._u.Xu?this.vc=0:this.vc=10,0!==this.vc?(isFinite(this.vc)&&(this.mc=!0),this._u.Xa=!0,this.ku(Bc),this.mc&&(this._u.sc=Dc-Dc/this.vc,this.gc=v(this.yc,1e3))):this.bc()}wc(){this._u.Xa=!1,this.Cu(Bc),this.mc&&(m(this.gc),this.kc=1,this._u.sc=Dc)}_c(){this.cc.Xa=!0,this.ku(Fc)}xc(){this.cc.Xa=!1,this.Cu(Fc)}bc(){m(this.gc),this.ac&&(s.location.href=this.ac.link)}ku(t){this.Uu.el().classList.add(t)}Cu(t){this.Uu.el().classList.remove(t)}Cc(t,i){const s=t>=i&&!(this.Sc&&this.Sc.jc);this.cc.Xa&&!s?this.xc():!this.cc.Xa&&s&&this._c()}Tc(t,i){this._u.Xa&&t<i&&!this.Uu.ended()&&this.wc()}static Mc(t,i){let s=ut(t);if(!j(s))return i-s;let e=(""+t).match(/^([1-9]?\d|100)%$/);if(e){return i*(1-C(e[1],10)/100)}}gn(){this.gc&&m(this.gc),this.Uu.getChild("upNextContainer").removeChild(this._u),this.Uu.getChild("upNextContainer").removeChild(this.cc),this._u.dispose(),this.cc.dispose()}constructor(i,s,e){this.uc=void 0,this.vc=10,this.kc=1,this.gc=void 0,this.mc=!0,this.yc=()=>{this.kc!==this.vc?(this._u.sc-=Dc/this.vc,this.kc+=1):this.bc()},this.dc=()=>{this._u.Xa||this.fc()},this.lc=()=>{let i=this.Uu.currentTime(),s=this.Uu.duration(),e=s?t.Mc(this.cc.Lu,s):void 0;void 0!==e&&this.Cc(i,e),this._u.Qu&&this.Tc(i,s)},this.za=function(t){return{get source(){return t.ac},set source(i){t.ac=i},get bar(){return t.nc},get panel(){return t.hc},next(){t.bc()}}}(this),this.cc=new Ac(i,this.za,{},s),this._u=new Ic(i,this.za,{},s),this.rc=function(t,i){return{get showing(){return i.Xa},get offset(){return i.Lu},set offset(t){i.Lu=t},show(){t._c()},hide(){t.xc()}}}(this,this.cc),this.oc=function(t,i){return{get showing(){return i.Xa},get countdownDuration(){return i.Xu},set countdownDuration(t){i.Xu=t},get showUpNextPanel(){return i.Qu},set showUpNextPanel(t){i.Qu=t},show(){t.fc()},hide(){t.wc()}}}(this,this._u),this.Uu=i,this.Sc=e,i.getChild("upNextContainer").addChild(this.cc,{}),i.getChild("upNextContainer").addChild(this._u,{})}};Pi((function(t){return class extends t{oa(){let t=this.Ac;return it(super.oa(),{get upnext(){return t.aa}})}gn(){this.Ac.gn(),super.gn()}constructor(t,i,s){super(t,i,s),this.Ac=new $c(this.oo,this.Mu,this.Pc)}}})),d(),d();var Rc=Mo.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",f(n,"Powered by THEOplayer 8.6.3"),s.appendChild(n),s.href="https://www.theoplayer.com/player-referral",s.target="Pu",t.appendChild(i),t}Ec(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=S(getComputedStyle(this.el()).fontSize);L(this.el(),r,n,h);let o=i.clientY-s.getBoundingClientRect().top;q(this.el(),o,n,h),this.Nc()}Ic(){this.hide(),this.clearTimeout(this.Bc)}Nc(){this.Bc=this.setTimeout(this.Ic,4e3)}Fc(){this.clearTimeout(this.Bc)}dispose(){this.Ic(),this.off(this.player(),"contextmenu",this.Ec),this.el().removeEventListener("mousedown",Vc,!0),this.off(h,"mousedown",this.Ic),this.off("mouseout",this.Nc),this.off("mouseover",this.Fc),super.dispose()}constructor(t,i){super(t,i),this.Bc=0,this.on(this.player(),"contextmenu",this.Ec),this.el().addEventListener("mousedown",Vc,!0),this.on(h,"mousedown",this.Ic),this.on("mouseout",this.Nc),this.on("mouseover",this.Fc),this.Ic()}};function Vc(t){t.stopPropagation()}Ni((function(t){const i=new Oc(t.oo,{});t.oo.addChild(i),t.oo.on("dispose",(()=>{t.oo.removeChild(i),i.dispose()}))})),d(),d(),d(),d();var Uc={Default:"","Monospaced Serif":ji.Dc,"Proportional Serif":ji.$c,"Monospaced Sans-Serif":ji.Rc,"Proportional Sans-Serif":ji.Oc},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 _.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";d();var sl=class extends Xa{Vc(){let t=this.Fr.localize(this.Uc);f(this.zc.subMenu.menuHeader.el(),t),this.Br=h.createElement("span"),this.Br.className="theo-settings-control-menu-item-title",f(this.Br,t);let i=h.createElement("span");return i.className="theo-primary-color theo-settings-control-menu-item-value",oi(this.zc.el(),"theo-subtitle-options-menu-item"),this.zc.el().appendChild(this.Br),this.zc.el().appendChild(i),i}Lc(t){const i=this.jr(t);i&&this.Hc(i)}qc(){return this.br}Ar(t){this.Wc(t.Tr)}Hc(t){for(let t of this.Cr.menuItems)t.selected(!1);t?(t.selected(!0),this.Gc(t.Tr.label)):this.Gc("Custom")}Gc(t){this.Xc=t,f(this.Jc,this.Fr.localize(t)),this.zc.parentMenu.re()}Mr(t){let i=super.Mr(t);return oi(i.el(),"theo-subtitle-options-menu-item"),this.Nr(i),i}Nr(t){const i=this.Fr.localize(t.Tr.label);f(t.el(),i);const s=this.Fr.localize("Set "+this.Uc+" 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.zc=t,this.Fr=e,this.Xc="",this.te=()=>{let t=this.Fr.localize(this.Uc);f(this.zc.subMenu.menuHeader.el(),t),f(this.Br,t),this.Gc(this.Xc);for(const t of this.Sr)this.Nr(t)},this.Uc=i,this.Wc=s.Wo,this.Jc=this.Vc(),this.br=s.Qc,this.Fr.on("languagechange",this.te)}};d();var el=class t{static Yc(t,i,s,e){if(void 0===t&&void 0===i)return;return $(void 0===t?s:t,void 0===i?e:i)}constructor(i){this.Kc=i,this.Zc=t=>{this.Kc.fontFamily=t.value},this.tl=t=>{this.Kc.fontSize=t.value},this.il=i=>{this.sl=i.value,this.Kc.fontColor=t.Yc(this.nl,this.sl,tl,Kc)},this.rl=i=>{this.nl=i.value,this.Kc.fontColor=t.Yc(this.nl,this.sl,tl,Kc)},this.hl=i=>{this.ol=i.value,this.Kc.backgroundColor=t.Yc(this.ol,this.al,Zc,Kc)},this.cl=i=>{this.al=i.value,this.Kc.backgroundColor=t.Yc(this.ol,this.al,Zc,Kc)},this.ll=i=>{this.dl=i.value,this.Kc.windowColor=t.Yc(this.dl,this.fl,il,Kc)},this.vl=i=>{this.fl=i.value,this.Kc.windowColor=t.Yc(this.dl,this.fl,il,Kc)},this.pl=t=>{this.Kc.edgeStyle=t.value}}};d();var nl=class{ml(t,i){const s=this.gl(t,i.qc());s&&i.Lc(s)}gl(t,i){return D(i,(i=>i.value===t))}yl(t,i,s){let e,n;if(void 0===t)e=this.gl(void 0,i.qc()),n=this.gl(void 0,s.qc());else if(t){let r=function(t){let i=F(t);i||(i=F(t.slice(0,t.length-1).replace("rgb","rgba")+",1)"));i||(i=Mi(E(t),1));if(!i){let s=t.charAt(0).toUpperCase()+t.toLowerCase().slice(1);i=Mi(E(zc[s]),1)}return i}(t);if(r){let t=I(r),h=100*r.bl;e=this.gl(t,i.qc()),n=this.gl(h,s.qc())}}e&&i.Lc(e),n&&s.Lc(n)}constructor(t,i){this.Kc=t,this.wl=i,this.kl=()=>{let t=this.Kc.fontFamily;this.ml(t,this.wl["Font family"]);let i=this.Kc.fontColor;this.yl(i,this.wl["Font color"],this.wl["Font opacity"]);let s=this.Kc.fontSize;this.ml(s,this.wl["Font size"]);let e=this.Kc.backgroundColor;this.yl(e,this.wl["Background color"],this.wl["Background opacity"]);let n=this.Kc.windowColor;this.yl(n,this.wl["Window color"],this.wl["Window opacity"]);let r=this.Kc.edgeStyle;this.ml(r,this.wl["Character edge style"])},this.Kc.addEventListener("change",this.kl),this.kl()}};var rl=class extends Xa{_l(){return{"Font family":{Qc:hl(Qc),Wo:this.xl.Zc},"Font color":{Qc:hl(Jc),Wo:this.xl.rl},"Font opacity":{Qc:hl(Gc),Wo:this.xl.il},"Font size":{Qc:hl(Wc),Wo:this.xl.tl},"Background color":{Qc:hl(Jc),Wo:this.xl.hl},"Background opacity":{Qc:hl(Xc),Wo:this.xl.cl},"Window color":{Qc:hl(Jc),Wo:this.xl.ll},"Window opacity":{Qc:hl(Xc),Wo:this.xl.vl},"Character edge style":{Qc:hl(Yc),Wo:this.xl.pl}}}Cl(){this.Br=h.createElement("span"),this.Br.className="theo-settings-control-menu-item-title",this.Sl=h.createElement("span"),this.Sl.className="theo-primary-color theo-settings-control-menu-item-value",this.Lr.el().appendChild(this.Br),this.Lr.el().appendChild(this.Sl),this.te()}Mr(t){let i=this.Cr.addSubMenuItem();return i.Tr=t,this.wl[t]=new sl(i,t,this.jl[t],this.Fr),i}Nr(t){}Ar(t){}Re(){this.Fr.off("languagechange",this.te),this.Tl.removeEventListener(["addtrack","removetrack"],this.Ml),super.Re()}constructor(t,i,s,e){super(t.subMenu),this.Lr=t,this.Tl=i,this.Fr=e,this.wl={},this.Ml=()=>{this.Tl.some((t=>xt(t.kind)))?this.Lr.show():this.Lr.hide()},this.te=()=>{f(this.Cr.menuHeader.el(),this.Fr.localize("Subtitle Options")),f(this.Br,this.Fr.localize("Subtitle")),f(this.Sl,this.Fr.localize("Options")),this.Lr.el().setAttribute("aria-label",this.Fr.localize("Open the subtitle options menu"))},this.xl=new el(s),this.jl=this._l(),this.br=_.keys(this.jl),this.Cl(),this.Al=new nl(s,this.wl),this.Fr.on("languagechange",this.te),this.Tl.addEventListener(["addtrack","removetrack"],this.Ml),this.Ml()}};function hl(t){let i=[{label:"Default",value:void 0}];for(let s of t)"Default"!==s.label&&i.push(s);return i}Ni((function(t){const i=t.oo.controlBar.getChild("SettingsButton").menu,s=i.addSubMenuItem({name:"TextTrackOptionsMenuItem"}),e=new rl(s,t.nt.aa,t.Pl.aa,t.oo);t.oo.on("dispose",(()=>{i.removeMenuItem(s),s.dispose(),e.Re(),i.dispose()}))})),d(),d();var ol=Mo.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=xi({},ol.prototype.h,{children:[]}),Mo.registerComponent("AdControlPanel",al),d(),d();var ul=Mo.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}El(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.Ho=t,this.za=i,this.te=()=>{const t=this.za.ads;t.playing&&t.currentAdBreak&&t.currentAds.length&&f(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=x.ceil(t.maxRemainingDuration);return n+=s("The content will resume in {1} seconds.").replace("{1}",""+h),n}(t.currentAdBreak,t.currentAds[0],(t=>this.Ho.localize(t))))},this.lo=t.el(),this.El(i,i.ads),this.on(t,"languagechange",this.te)}};d();var dl=Mo.getComponent("ClickableComponent"),fl=class extends dl{buildCSSClass(){return Et}createEl(t,i,s){return this.h.aa.element.querySelector("."+Et)}emitTapEvents(){}te(){f(this.el(),this.localize("Learn more"))}constructor(t,i){super(t,i),f(this.el(),t.localize("Learn more")),this.za=i.aa,this.lo=t.el(),this.on(t,"languagechange",this.te)}};Ni((function(t){if(t.aa.ads&&t.Nl){const i=t.oo,s=new ll(i,t.aa);i.adControlBar.addChild(s);if(t.aa.element.querySelector("."+Et)){const s=new fl(i,{aa:t.aa});i.adControlBar.addChild(s)}}})),d(),d();var vl=Mo.getComponent("Component"),pl=["addtrack","removetrack","change"],ml=class extends($o(vl)){createEl(){let t=super.createEl();return this.qualityLabel=Mo.createEl("div",{className:"theo-quality-label-text"}),t.appendChild(this.qualityLabel),pi(this.qualityLabel),t}dispose(){this.qr&&(this.qr.removeEventListener("activequalitychanged",this.Il),this.qr=void 0),this.ks.videoTracks.removeEventListener(pl,this.nh),super.dispose()}constructor(t,i){super(t,i),this.qr=void 0,this.nh=()=>{const t=Ha(this.ks.videoTracks);t!==this.qr&&(this.qr&&this.qr.removeEventListener("activequalitychanged",this.Il),this.qr=t,t&&t.addEventListener("activequalitychanged",this.Il),this.Il())},this.Il=()=>{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&&(f(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.ks.videoTracks&&(this.ks.videoTracks.addEventListener(pl,this.nh),this.nh())}};Mo.registerComponent("activeQualityLabel",ml),d(),d();var gl="theo-upcoming-ad-notification",yl=["adbreakbegin","adbreakend","adadded","adloaded","adbegin","adend"],bl=class extends($o(la)){createEl(){const t=Mo.createEl("div",{className:gl});return this.notificationText=Mo.createEl("div",{className:gl+"text"}),t.appendChild(this.notificationText),t}Bl(){if(!this.ks.ads)return;const t=this.ks.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))}Fl(){if(!this.ks.ads||this.ks.ads.playing||!this.currentAdBreak||!this.currentAdBreakValid||0===this.currentAdBreak.timeOffset)return void this.Dl();const t=this.ks.currentTime;if(this.currentAdBreak.timeOffset>t+10)return void this.Dl();const i=x.ceil(this.currentAdBreak.timeOffset-t);i<0?this.Dl():this.$l(i)}$l(t){this.Rl!==t&&(f(this.notificationText,"Your video will be temporarily interrupted in 0:"+(t<10?"0"+t:t)),this.Rl=t,this.show())}Dl(){this.Rl=NaN,this.hide()}dispose(){var t;this.ks.removeEventListener("timeupdate",this.handleTimeUpdate),null==(t=this.ks.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.Rl=NaN,this.handleTimeUpdate=()=>{this.Fl()},this.handleAdEvent=()=>{this.Bl(),this.Fl()},this.ks.ads&&(this.hide(),this.ks.addEventListener("timeupdate",this.handleTimeUpdate),this.ks.ads.addEventListener(yl,this.handleAdEvent))}};Mo.registerComponent("upcomingAdNotificationText",bl),d(),d();var wl=Mo.getComponent("Component");Mo.registerComponent("VerizonMediaAdBreakBar",class extends wl{createEl(){const t=h.createElement("div");return t.className="theoplayer-ad-overlay-component theo-ad-remaining-container",t}get Ol(){return this.h.adBreakProvider()}te(t,i){if(this.Ol&&this.Ol.endTime){const s=x.max(this.Ol.endTime-t,0);f(i,"Content will resume in "+x.ceil(s)+"s"),this.show()}else this.hide()}constructor(t,i){super(t,i),this.Vl=()=>{this.te(this.player().currentTime(),this.el())},this.on(t,"timeupdate",this.Vl)}}),d();var kl=Mo.getComponent("ClickableComponent");Mo.registerComponent("VerizonMediaAdSkipButton",class extends kl{createEl(){const t=h.createElement("div");return t.className="theoplayer-ad-overlay-component theoplayer-ad-skip theoplayer-ad-skip-countdown",this.Ul=h.createElement("span"),t.appendChild(this.Ul),this.te(t,this.Ul),t}handleClick(){this.h.skipCallback()}te(t,i){this.zl<=pt.Hl.Ll?(ui(t,"theoplayer-ad-skip-countdown"),oi(t,"theoplayer-ad-skip-button"),f(i,"Skip ads")):f(i,"Skip ads in "+x.ceil(this.zl)+"s")}get zl(){return this.h.adBreak.startTime+this.h.adBreak.skipOffset-this.player().currentTime()}constructor(t,i){super(t,i),this.Vl=()=>{this.te(this.el(),this.Ul)},this.on(t,"timeupdate",this.Vl)}}),d(),d();var _l=Mo.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)}};Mo.registerComponent("VerizonMediaAdBreakMarkerBar",class extends xl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-bar-adbreak"}}),d(),d();var Cl=Mo.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=x.max(this.startTime-n,0),a=void 0!==this.endTime?x.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)}};Mo.registerComponent("VerizonMediaAdBreakMarker",class extends Sl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-adbreak"}}),d();Mo.registerComponent("VerizonMediaAssetMarkerBar",class extends xl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-bar-asset"}}),d();Mo.registerComponent("VerizonMediaAssetMarker",class extends Sl{buildCSSClass(){return super.buildCSSClass()+" theo-verizonmedia-marker-asset"}}),d();var jl=Mo.getComponent("Component");Mo.registerComponent("VerizonMediaContentNotificationBar",class extends jl{buildCSSClass(){const t="theo-verizonmedia-content-notification-bar",i=t+"-ios";return t+(Ot.Ua||Ot.ql?" "+i:"")}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}constructor(t,i){super(t,i)}}),d();var Tl=Mo.getComponent("Component");function Ml(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])}Mo.registerComponent("VerizonMediaContentNotification",class extends Tl{get Wl(){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}fo(){const t=h.createElement("img");t.src=this.Wl.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.Wl.description);f(i,s),this.el().appendChild(i),this.Gl=h.createElement("div"),this.Gl.className=this.buildCSSClass()+"-countdown",f(this.Gl,this.Xl),this.el().appendChild(this.Gl)}get Xl(){const t=x.min(10,this.Jl);return"Starting in "+x.ceil(t)+" seconds"}get Jl(){return x.max(0,this.Wl.startTime-this.player().currentTime())}Ql(){const t=this.Jl;t>10||t<=0?this.hide():(f(this.Gl,this.Xl),this.show())}constructor(t,i){super(t,i),this.fo(),this.on(t,"timeupdate",this.Ql),this.hide()}}),d(),Pi((function(t){return class extends t{get Yl(){return this.oo.controlBar.progressControl.seekBar}la(t){this.Kl=!1,this.aa.removeEventListener("timeupdate",this.Zl),this.oo.removeChild("VerizonMediaAdBreakBar"),this.oo.removeChild("VerizonMediaAdSkipButton"),this.Yl.removeChild("VerizonMediaAdBreakMarkerBar"),this.Yl.removeChild("VerizonMediaAssetMarkerBar"),this.oo.removeChild("VerizonMediaContentNotificationBar"),super.la(t)}td(){if(!function(t){return Ml(t,"assetMarkers")}(this.sd)||!this.Kl)return;const t=this.aa.verizonMedia.assets.map((t=>({name:"VerizonMediaAssetMarker",startTime:t.startTime,endTime:t.endTime})));this.Yl.removeChild("VerizonMediaAssetMarkerBar"),this.Yl.addChild("VerizonMediaAssetMarkerBar",{children:t})}ed(){if(!function(t){return Ml(t,"contentNotification")}(this.sd))return;const t=this.aa.verizonMedia.assets.map((t=>({name:"VerizonMediaContentNotification",asset:t})));this.oo.removeChild("VerizonMediaContentNotificationBar"),this.oo.addChild("VerizonMediaContentNotificationBar",{children:t})}gn(){this.aa.removeEventListener("timeupdate",this.Zl),this.aa.verizonMedia.ads.adBreaks.removeEventListener("addadbreak",this.nd),this.aa.verizonMedia.ads.adBreaks.removeEventListener("removeadbreak",this.rd),this.aa.verizonMedia.assets.removeEventListener("addasset",this.od),this.aa.verizonMedia.assets.removeEventListener("removeasset",this.od),this.aa.removeEventListener("loadeddata",this.ad),super.gn()}constructor(t,i,s){super(t,i,s),this.Kl=!1,this.ad=()=>{this.Kl=!0,isFinite(this.ud())||this.aa.addEventListener("timeupdate",this.Zl),this.Zl(),this.td(),this.ed()},this.nd=t=>{t.adBreak.addEventListener("adbreakbegin",this.ld),t.adBreak.addEventListener("adbreakend",this.dd),this.Zl()},this.rd=t=>{t.adBreak.removeEventListener("adbreakbegin",this.ld),t.adBreak.removeEventListener("adbreakend",this.dd),this.Zl()},this.Zl=()=>{if(!function(t){return Ml(t,"adBreakMarkers")}(this.sd)||!this.Kl)return;const t=this.aa.verizonMedia.ads.adBreaks.map((t=>({name:"VerizonMediaAdBreakMarker",startTime:t.startTime,endTime:t.endTime})));this.Yl.removeChild("VerizonMediaAdBreakMarkerBar"),this.Yl.addChild("VerizonMediaAdBreakMarkerBar",{children:t})},this.ld=()=>{if(function(t){return Ml(t,"adNotification")}(this.sd)){const t=this.aa.verizonMedia.ads.currentAdBreak;this.oo.addChild("VerizonMediaAdBreakBar",{adBreakProvider:this.fd}),-1!==t.skipOffset&&this.oo.addChild("VerizonMediaAdSkipButton",{adBreak:t,skipCallback:this.aa.verizonMedia.ads.skip})}},this.fd=()=>this.aa.verizonMedia.ads.currentAdBreak,this.dd=()=>{this.oo.removeChild("VerizonMediaAdBreakBar"),this.oo.removeChild("VerizonMediaAdSkipButton")},this.od=()=>{this.td(),this.ed()},this.aa.verizonMedia.ads.adBreaks.addEventListener("addadbreak",this.nd),this.aa.verizonMedia.ads.adBreaks.addEventListener("removeadbreak",this.rd),this.aa.verizonMedia.assets.addEventListener("addasset",this.od),this.aa.verizonMedia.assets.addEventListener("removeasset",this.od),this.aa.addEventListener("loadeddata",this.ad)}}}));export{st as ChromelessPlayer,Y as ErrorCategory,J as ErrorCode,$u as Player,A as cache,jt as cast,ht as features,ct as playerSuiteVersion,dt as players,vt as registerContentProtectionIntegration,nt as utils,at as version,Mo as videojs};
|