theoplayer 11.2.0 → 11.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/THEOplayer.esm.js CHANGED
@@ -34,8 +34,8 @@
34
34
  THEOplayer is based on patented technology developed by
35
35
  THEO Technologies (https://www.theoplayer.com).
36
36
 
37
- Version: 11.2.0
38
- Created: 2026-05-07T15:23:41.619Z
37
+ Version: 11.4.0
38
+ Created: 2026-06-04T13:21:43.149Z
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,p=a.clearInterval,m=a.Error,g=a.TypeError,k=a.SyntaxError,w=a.Object,_=a.Math,x=a.parseInt,C=a.parseFloat,S=a.isNaN,j=a.Uint8Array;a.Worker,a.WorkerGlobalScope,a.XMLHttpRequest;import{$ as T,$a as M,A,Aa as P,B as N,Ba as E,C as B,Ca as I,D as F,Da as D,E as $,Ea as U,F as R,Fa as O,G as V,Ga as L,H,Ha as q,I as z,Ia as W,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 d,O as st,Oa as et,P as nt,Pa as rt,Q as ht,Qa as ot,R as at,Ra as ut,S as ct,Sa as lt,T as dt,Ta as ft,U as vt,Ua as pt,V as mt,Va as gt,W as yt,Wa as bt,X as kt,Xa as wt,Y as _t,Ya as xt,Z as Ct,Za as St,_ as jt,_a as Tt,a as Mt,aa as At,ab as Pt,b as Nt,ba as Et,bb as Bt,c as f,ca as It,cb as Ft,d as Dt,da as $t,db as Ut,e as Rt,ea as Ot,eb as Vt,f as Lt,fa as Ht,fb as qt,g as zt,ga as Wt,gb as Gt,h as Xt,ha as Jt,hb as Qt,i as Yt,ia as Kt,j as Zt,ja as ti,k as ii,ka as si,l as ei,la as ni,m as ri,ma as hi,n as oi,na as ai,o as ui,oa as ci,p as li,pa as di,q as fi,qa as vi,r as pi,ra as mi,s as gi,sa as yi,t as bi,ta as ki,u as wi,ua as _i,v as xi,va as Ci,w as Si,wa as ji,x as Ti,xa as Mi,y as Ai,ya as Pi,z as Ni,za as Ei}from"./THEOplayer.common.esm.js";f(),f(),f(),f();var Bi=[];function Ii(t){Bi.push(t)}var Fi=[];function Di(t){Fi.push(t)}f(),f(),f(),f();var b=void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},$i=void 0!==h?h:{createElement:function(){}};function Ui(t,i){return i||(i=t.slice(0)),t.raw=i,t}var Ri=1;function Oi(){return Ri++}var Vi,Li=w.prototype.toString,Hi=function(t){return Wi(t)?w.keys(t):[]};function qi(t,i){Hi(t).forEach(function(s){return i(t[s],s)})}function zi(t){for(var i=arguments.length,s=new Array(i>1?i-1:0),e=1;e<i;e++)s[e-1]=arguments[e];return w.assign?w.assign.apply(w,[t].concat(s)):(s.forEach(function(i){i&&qi(i,function(i,s){t[s]=i})}),t)}function Wi(t){return!!t&&"object"==typeof t}function Gi(t){return Wi(t)&&"[object Object]"===Li.call(t)&&t.constructor===w}var Xi=function(t,i,s){void 0===s&&(s=!!Gs&&Gs<11),"log"!==t&&i.unshift(t.toUpperCase()+":"),Vi.history.push(i),i.unshift("VIDEOJS:");var e=b.console&&b.console[t];e&&(s&&(i=i.map(function(t){if(Wi(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"](b.console,i):e(i))};(Vi=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];Xi("log",i)}).history=[],Vi.error=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Xi("error",i)},Vi.warn=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Xi("warn",i)};var Ji=Vi,Qi="undefined"!=typeof globalThis?globalThis:void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Yi(t){return t.replace(/\n\r?\s*/g,"")}var Ki,Zi=function(t){for(var i="",s=0;s<arguments.length;s++)i+=Yi(t[s])+(arguments[s+1]||"");return i};function ts(t){return"string"==typeof t&&/\S/.test(t)}function is(t){if(/\s/.test(t))throw new m("class has illegal whitespace characters")}function ss(){return $i===b.document&&void 0!==$i.createElement}function es(t){return Wi(t)&&1===t.nodeType}function ns(t){return function(i,s){if(!ts(i))return $i[t](null);ts(s)&&(s=$i.querySelector(s));var e=es(s)?s:$i;return e[t]&&e[t](i)}}function rs(t,i,s,e){void 0===t&&(t="div"),void 0===i&&(i={}),void 0===s&&(s={});var n=$i.createElement(t);return w.getOwnPropertyNames(i).forEach(function(t){var s=i[t];-1!==t.indexOf("aria-")||"role"===t||"type"===t?(Ji.warn(Zi(Ki||(Ki=Ui(["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?hs(n,s):n[t]=s}),w.getOwnPropertyNames(s).forEach(function(t){n.setAttribute(t,s[t])}),e&&Ss(n,e),n}function hs(t,i){return void 0===t.textContent?t.innerText=i:t.textContent=i,t}function os(t,i){i.firstChild?i.insertBefore(t,i.firstChild):i.appendChild(t)}var as={},us="vdata"+(new Date).getTime();function cs(t){var i=t[us];return i||(i=t[us]=Oi()),as[i]||(as[i]={}),as[i]}function ls(t){var i=t[us];return!!i&&!!w.getOwnPropertyNames(as[i]).length}function ds(t){var i=t[us];if(i){delete as[i];try{delete t[us]}catch(i){t.removeAttribute?t.removeAttribute(us):t[us]=null}}}function fs(t,i){return is(i),t.classList?t.classList.contains(i):function(t){return new RegExp("(^|\\s)"+t+"($|\\s)")}(i).test(t.className)}function vs(t,i){return t.classList?t.classList.add(i):fs(t,i)||(t.className=(t.className+" "+i).trim()),t}function ps(t,i){return t.classList?t.classList.remove(i):(is(i),t.className=t.className.split(/\s+/).filter(function(t){return t!==i}).join(" ")),t}function ms(t,i,s){var e=fs(t,i);if("function"==typeof s&&(s=s(t,i)),"boolean"!=typeof s&&(s=!e),s!==e)return s?vs(t,i):ps(t,i),t}function gs(t,i){w.getOwnPropertyNames(i).forEach(function(s){var e=i[s];null==e||!1===e?t.removeAttribute(s):t.setAttribute(s,!0===e?"":e)})}function ys(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 bs(t,i,s){t.setAttribute(i,s)}function ks(t,i){t.removeAttribute(i)}function ws(t){var i;if(t.getBoundingClientRect&&t.parentNode&&(i=t.getBoundingClientRect()),!i)return{left:0,top:0};var s=$i.documentElement,e=$i.body,n=s.clientLeft||e.clientLeft||0,r=b.pageXOffset||e.scrollLeft,h=i.left+r-n,o=s.clientTop||e.clientTop||0,a=b.pageYOffset||e.scrollTop,u=i.top+a-o;return{left:_.round(h),top:_.round(u)}}function _s(t,i){var s={},e=ws(t),n=t.offsetWidth,r=t.offsetHeight,h=e.top,o=e.left,a=i.pageY,u=i.pageX;return i.changedTouches&&(u=i.changedTouches[0].pageX,a=i.changedTouches[0].pageY),s.y=_.max(0,_.min(1,(h-a+r)/r)),s.x=_.max(0,_.min(1,(u-o)/n)),s}function xs(t){return Wi(t)&&3===t.nodeType}function Cs(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function Ss(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()),es(t)||xs(t)?t:"string"==typeof t&&/\S/.test(t)?$i.createTextNode(t):void 0}).filter(function(t){return t})}(i).forEach(function(i){return t.appendChild(i)}),t}function js(t,i){return Ss(Cs(t),i)}var Ts,Ms=ns("querySelector"),As=ns("querySelectorAll"),Ps=b.navigator&&b.navigator.userAgent||"",Ns=/AppleWebKit\/([\d.]+)/i.exec(Ps),Es=Ns?C(Ns.pop()):null,Bs=/iPad/i.test(Ps),Is=/iPhone/i.test(Ps)&&!Bs,Fs=/iPod/i.test(Ps),Ds=Is||Bs||Fs,$s=(Ts=Ps.match(/OS (\d+)_/i))&&Ts[1]?Ts[1]:null,Us=/Android/i.test(Ps),Rs=function(){var t=Ps.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!t)return null;var i=t[1]&&C(t[1]),s=t[2]&&C(t[2]);return i&&s?C(t[1]+"."+t[2]):i||null}(),Os=Us&&/webkit/i.test(Ps)&&Rs<2.3,Vs=Us&&Rs<5&&Es<537,Ls=/Firefox/i.test(Ps),Hs=/Edge/i.test(Ps),qs=!Hs&&/Chrome/i.test(Ps),zs=function(){var t=Ps.match(/Chrome\/(\d+)/);return t&&t[1]?C(t[1]):null}(),Ws=/MSIE\s8\.0/.test(Ps),Gs=function(){var t=/MSIE\s(\d+)\.\d/.exec(Ps),i=t&&C(t[1]);return!i&&/Trident\/7.0/i.test(Ps)&&/rv:11.0/.test(Ps)&&(i=11),i}(),Xs=/Safari/i.test(Ps)&&!qs&&!Us&&!Hs,Js=Xs||Ds,Qs=ss()&&("ontouchstart"in b||b.DocumentTouch&&b.document instanceof b.DocumentTouch),Ys=ss()&&"backgroundSize"in b.document.createElement("video").style,Ks=w.freeze({__proto__:null,IS_IPAD:Bs,IS_IPHONE:Is,IS_IPOD:Fs,IS_IOS:Ds,IOS_VERSION:$s,IS_ANDROID:Us,ANDROID_VERSION:Rs,IS_OLD_ANDROID:Os,IS_NATIVE_ANDROID:Vs,IS_FIREFOX:Ls,IS_EDGE:Hs,IS_CHROME:qs,CHROME_VERSION:zs,IS_IE8:Ws,IE_VERSION:Gs,IS_SAFARI:Xs,IS_ANY_SAFARI:Js,TOUCH_ENABLED:Qs,BACKGROUND_SIZE_SUPPORTED:Ys});function Zs(t,i){var s=cs(t);0===s.handlers[i].length&&(delete s.handlers[i],t.removeEventListener?t.removeEventListener(i,s.dispatcher,!1):t.detachEvent&&t.detachEvent("on"+i,s.dispatcher)),w.getOwnPropertyNames(s.handlers).length<=0&&(delete s.handlers,delete s.dispatcher,delete s.disabled),0===w.getOwnPropertyNames(s).length&&ds(t)}function te(t,i,s,e){s.forEach(function(s){t(i,s,e)})}function ie(t){function i(){return!0}function s(){return!1}if(!t||!t.isPropagationStopped||!t.isImmediatePropagationStopped){var e=t||b.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||$i),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=$i.documentElement,h=$i.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 se=!1;!function(){try{var t=w.defineProperty({},"passive",{get:function(){se=!0}});b.addEventListener("test",null,t)}catch(t){}}();var ee=["touchstart","touchmove"];function ne(t,i,s){if(Array.isArray(i))return te(ne,t,i,s);var e=cs(t);if(e.handlers||(e.handlers={}),e.handlers[i]||(e.handlers[i]=[]),s.guid||(s.guid=Oi()),e.handlers[i].push(s),e.dispatcher||(e.disabled=!1,e.dispatcher=function(i,s){if(!e.disabled){i=ie(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){Ji.error(t)}}}),1===e.handlers[i].length)if(t.addEventListener){var n=!1;se&&ee.indexOf(i)>-1&&(n={passive:!0}),t.addEventListener(i,e.dispatcher,n)}else t.attachEvent&&t.attachEvent("on"+i,e.dispatcher)}function re(t,i,s){if(ls(t)){var e=cs(t);if(e.handlers){if(Array.isArray(i))return te(re,t,i,s);var n=function(i){e.handlers[i]=[],Zs(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);Zs(t,i)}else n(i)}else for(var o in e.handlers)n(o)}}}function he(t,i,s){var e=ls(t)?cs(t):{},n=t.parentNode||t.ownerDocument;if("string"==typeof i&&(i={type:i,target:t}),i=ie(i),e.dispatcher&&e.dispatcher.call(t,i,s),n&&!i.isPropagationStopped()&&!0===i.bubbles)he.call(null,n,i,s);else if(!n&&!i.defaultPrevented){var r=cs(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 oe(t,i,s){if(Array.isArray(i))return te(oe,t,i,s);var e=function e(){re(t,i,e),s.apply(this,arguments)};e.guid=s.guid=s.guid||Oi(),ne(t,i,e)}var ae,ue=!1,ce=function(){if(ss()){var t=$i.getElementsByTagName("video"),i=$i.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){le(1);break}void 0===u.player&&null!==u.getAttribute("data-setup")&&ae(u)}else ue||le(1)}};function le(t,i){i&&(ae=i),b.setTimeout(ce,t)}ss()&&"complete"===$i.readyState?ue=!0:oe(b,"load",function(){ue=!0});var de=function(t){var i=$i.createElement("style");return i.className=t,i},fe=function(t,i){t.styleSheet?t.styleSheet.cssText=i:t.textContent=i},n=function(t,i,s){i.guid||(i.guid=Oi());var e=function(){return i.apply(t,arguments)};return e.guid=s?s+"_"+i.guid:i.guid,e};function ve(t){return"string"!=typeof t?t:t.charAt(0).toUpperCase()+t.slice(1)}function pe(){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&&qi(i,function(i,s){Gi(i)?(Gi(t[s])||(t[s]={}),t[s]=pe(t[s],i)):t[s]=i})}),t}var me=function(){function t(t,i,s){if(!t&&this.play?this.t=t=this:this.t=t,this.h=pe({},this.h),i=this.h=pe(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"+Oi()}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),ds(this.v),this.v=null},i.player=function(){return this.t},i.options=function(t){return Ji.warn("this.options() has been deprecated and will be moved to the constructor in 6.0"),t?(this.h=pe(this.h,t),this.h):this.h},i.el=function(){return this.v},i.createEl=function(t,i,s){return rs(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=ve(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=ve(i),s||(s={}),!0===s&&(Ji.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 m("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&&ve(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:w.keys(s)).concat(w.keys(this.h).filter(function(t){return!e.some(function(i){return"string"==typeof i?t===i:t===i.name})})).map(function(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||ve(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))ne(this.v,t,n(this,i));else{var r=t,h=i,o=n(this,s),a=function(){return e.off(r,h,o)};a.guid=o.guid,this.on("dispose",a);var u=function(){return e.off("dispose",a)};u.guid=o.guid,t.nodeName?(ne(r,h,o),ne(r,"dispose",u)):"function"==typeof t.on&&(r.on(h,o),r.on("dispose",u))}return this},i.off=function(t,i,s){if(!t||"string"==typeof t||Array.isArray(t))re(this.v,t,i);else{var e=t,r=i,h=n(this,s);this.off("dispose",h),t.nodeName?(re(e,r,h),re(e,"dispose",h)):(e.off(r,h),e.off("dispose",h))}return this},i.one=function(t,i,s){var e=arguments,r=this;if("string"==typeof t||Array.isArray(t))oe(this.v,t,n(this,i));else{var h=t,o=i,a=n(this,s),u=function t(){r.off(h,o,t),a.apply(null,e)};u.guid=a.guid,this.on(h,o,u)}return this},i.trigger=function(t,i){return he(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 Ms(t,i||this.contentEl())},i.$$=function(t,i){return As(t,i||this.contentEl())},i.hasClass=function(t){return fs(this.v,t)},i.addClass=function(t){return vs(this.v,t),this},i.removeClass=function(t){return ps(this.v,t),this},i.toggleClass=function(t,i){return ms(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 bs(this.v,t,i),this},i.removeAttribute=function(t){return ks(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 x(-1!==n?e.slice(0,n):this.v["offset"+ve(t)],10)},i.currentDimension=function(t){var i=0;if("width"!==t&&"height"!==t)throw new m("currentDimension only accepts width or height value");if("function"==typeof b.getComputedStyle){var s=b.getComputedStyle(this.v);i=s.getPropertyValue(t)||s[t]}if(0===(i=C(i))){var e="offset"+ve(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;_.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=n(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=n(this,t);var s=b.setTimeout(t,i),e=function(){this.clearTimeout(s)};return e.guid="vjs-timeout-"+s,this.on("dispose",e),s},i.clearTimeout=function(t){b.clearTimeout(t);var i=function(){};return i.guid="vjs-timeout-"+t,this.off("dispose",i),t},i.setInterval=function(t,i){t=n(this,t);var s=b.setInterval(t,i),e=function(){this.clearInterval(s)};return e.guid="vjs-interval-"+s,this.on("dispose",e),s},i.clearInterval=function(t){b.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=ve(i),t.M||(t.M={}),"Player"===i&&t.M[i]){var e=t.M[i];if(e.players&&w.keys(e.players).length>0&&w.keys(e.players).map(function(t){return e.players[t]}).every(Boolean))throw new m("Can not register Player component after player has been created")}return t.M[i]=s,s}},t.getComponent=function(i){if(i)return i=ve(i),t.M&&t.M[i]?t.M[i]:b&&b.videojs&&b.videojs[i]?(Ji.warn("The "+i+" component was added to the videojs object when it should be registered using videojs.registerComponent(name, component)"),b.videojs[i]):void 0},t.extend=function(i){i=i||{},Ji.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=w.create(this.prototype)).constructor=e,e.extend=t.extend,i)i.hasOwnProperty(n)&&(e.prototype[n]=i[n]);return e},t}();me.registerComponent("Component",me);var ge=function(){};function ye(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function be(t,i){return(be=w.setPrototypeOf?w.setPrototypeOf.bind():function(t,i){return t.__proto__=i,t})(t,i)}function ke(t,i){t.prototype=w.create(i.prototype),t.prototype.constructor=t,be(t,i)}function we(t,i,s,e){return void 0===e&&(Ji.warn("DEPRECATED: Function '"+t+"' on 'TimeRanges' called without an index argument."),e=0),function(t,i,s){if(i<0||i>s)throw new m("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 _e(t){return void 0===t||0===t.length?{length:0,start:function(){throw new m("This TimeRanges object is empty")},end:function(){throw new m("This TimeRanges object is empty")}}:{length:t.length,start:we.bind(null,"start",0,t),end:we.bind(null,"end",1,t)}}function xe(t,i){return Array.isArray(t)?_e(t):void 0===t||void 0===i?_e():_e([[t,i]])}function Ce(t,i){var s,e,n=0;if(!i)return 0;t&&t.length||(t=xe(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}ge.prototype.A={},ge.prototype.on=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},ne(this,t,i),this.addEventListener=s},ge.prototype.addEventListener=ge.prototype.on,ge.prototype.off=function(t,i){re(this,t,i)},ge.prototype.removeEventListener=ge.prototype.off,ge.prototype.one=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},oe(this,t,i),this.addEventListener=s},ge.prototype.trigger=function(t){var i=t.type||t;"string"==typeof t&&(t={type:i}),t=ie(t),this.A[i]&&this["on"+i]&&this["on"+i](t),he(this,t)},ge.prototype.dispatchEvent=ge.prototype.trigger;var Se,je,Te,Me,Ae={prefixed:!0},Pe=[["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"]],Ne=Pe[0];for(je=0;je<Pe.length;je++)if(Pe[je][1]in $i){Se=Pe[je];break}if(Se){for(Te=0;Te<Se.length;Te++)Ae[Ne[Te]]=Se[Te];Ae.prefixed=Se[0]!==Ne[0]}function Ee(t){if(t instanceof Ee)return t;"number"==typeof t?this.code=t:"string"==typeof t?this.message=t:Wi(t)&&("number"==typeof t.code&&(this.code=t.code),zi(this,t)),this.message||(this.message=Ee.defaultMessages[this.code]||"")}for(Ee.prototype.code=0,Ee.prototype.message="",Ee.prototype.status=null,Ee.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],Ee.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."},Me=0;Me<Ee.errorTypes.length;Me++)Ee[Ee.errorTypes[Me]]=Me,Ee.prototype[Ee.errorTypes[Me]]=Me;var Be=function(t,i){var s,e=null;try{s=JSON.parse(t,i)}catch(t){e=t}return[e,s]};var Ie=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}})})},Fe=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=Ie(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(Ie))},De=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()},$e="vjs-modal-dialog",Ue=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).P=e.N=e.B=!1,e.closeable(!e.h.uncloseable),e.content(e.h.content),e.S=rs("div",{className:$e+"-content"},{role:"document"}),e.I=rs("p",{className:$e+"-description vjs-offscreen",id:e.el().getAttribute("aria-describedby")}),hs(e.I,e.description()),e.v.appendChild(e.I),e.v.appendChild(e.S),e.on(i,"languagechange",e.handleLanguagechange),e}ke(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 $e+" vjs-hidden "+t.prototype.buildCSSClass.call(this)},s.handleKeyPress=function(t){27===t.which&&this.closeable()&&this.close()},s.label=function(){return this.h.label||this.localize("Modal Window")},s.description=function(){var t=this.h.description||this.localize("This is a modal window.");return this.closeable()&&(t+=" "+this.localize("This modal can be closed by pressing the Escape key or activating the close button.")),t},s.open=function(){if(!this.P){var t=this.player();this.trigger("beforemodalopen"),this.P=!0,(this.h.fillAlways||!this.N&&!this.B)&&this.fill(),this.D=!t.paused(),this.h.pauseOnOpen&&this.D&&t.pause(),this.closeable()&&this.on(this.v.ownerDocument,"keydown",n(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",n(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.U=!!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.U},s.fill=function(){return this.fillWith(this.content())},s.fillWith=function(t){var i=this.contentEl(),s=i.parentNode,e=i.nextSibling;return this.trigger("beforemodalfill"),this.B=!0,s.removeChild(i),this.empty(),js(i,t),this.trigger("modalfill"),e?s.insertBefore(i,e):s.appendChild(i),this},s.empty=function(){return this.trigger("beforemodalempty"),Cs(this.contentEl()),this.trigger("modalempty"),this},s.content=function(t){return void 0!==t&&(this.R=t),this.R},s.handleLanguagechange=function(){this.v.setAttribute("aria-label",this.label()),hs(this.I,this.description()),this.opened()?this.fill():(this.N||this.B)&&(this.N=!1,this.B=!1,this.empty())},i}(me);Ue.prototype.h={pauseOnOpen:!0,temporary:!0},me.registerComponent("ModalDialog",Ue);var Re=function(){function t(i){var s=this;if(Ws)for(var e in s=$i.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);if(t.prototype.O.call(s,i),w.defineProperty(s,"length",{get:function(){return this.V}}),Ws)return s}var i=t.prototype;return i.O=function(t){var i=this.length||0,s=0,e=t.length;this.L=t,this.V=t.length;var n=function(t){""+t in this||w.defineProperty(this,""+t,{get:function(){return this.L[t]}})};if(i<e)for(s=i;s<e;s++)n.call(this,s)},i.getCueById=function(t){for(var i=null,s=0,e=this.length;s<e;s++){var n=this[s];if(n.id===t){i=n;break}}return i},t}(),Oe={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},Ve={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},Le={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},He={disabled:"disabled",hidden:"hidden",showing:"showing"},qe=function(t){function i(s){var e;void 0===s&&(s={});var n=ye(e=t.call(this)||this);if(Ws)for(var r in n=$i.createElement("custom"),i.prototype)"constructor"!==r&&(n[r]=i.prototype[r]);var h={id:s.id||["vjs_track",Oi()].join("_"),kind:s.kind||"",label:s.label||"",language:s.language||""},o=function(t){w.defineProperty(n,t,{get:function(){return h[t]},set:function(){}})};for(var a in h)o(a);return n||ye(e)}return ke(i,t),i}(ge),ze=function(t){var i=["protocol","hostname","port","pathname","search","hash","host"],s=$i.createElement("a");s.href=t;var e,n=""===s.host&&"file:"!==s.protocol;n&&((e=$i.createElement("div")).innerHTML='<a href="'+t+'"></a>',s=e.firstChild,e.setAttribute("style","display:none; position:absolute;"),$i.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&&$i.body.removeChild(e),r},We=function(t){var i=b.location,s=ze(t);return(":"===s.protocol?i.protocol:s.protocol)+s.host!==i.protocol+i.host},Ge={exports:{}};void 0!==s?Ge.exports=s:void 0!==Qi?Ge.exports=Qi:"undefined"!=typeof self?Ge.exports=self:Ge.exports={};var Xe=function(t){var i=Je.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)},Je=w.prototype.toString;var Qe,Ye,Ke,Ze,tn,sn,en,nn,rn,hn,on,an,un=Array.prototype.slice,cn=w.prototype.toString,ln=function(t){var i=this;if("function"!=typeof i||"[object Function]"!==cn.call(i))throw new g("Function.prototype.bind called on incompatible "+i);for(var s,e=un.call(arguments,1),n=_.max(0,i.length-e.length),r=[],h=0;h<n;h++)r.push("$"+h);if(s=Function("binder","return function ("+r.join(",")+"){ return binder.apply(this,arguments); }")(function(){if(this instanceof s){var n=i.apply(this,e.concat(un.call(arguments)));return w(n)===n?n:this}return i.apply(t,e.concat(un.call(arguments)))}),i.prototype){var o=function(){};o.prototype=i.prototype,s.prototype=new o,o.prototype=null}return s},dn=Function.prototype.bind||ln,fn=w.prototype.toString,vn=function(t){var i=fn.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]"===fn.call(t.callee)),s};w.keys||(Ye=w.prototype.hasOwnProperty,Ke=w.prototype.toString,Ze=vn,tn=w.prototype.propertyIsEnumerable,sn=!tn.call({toString:null},"toString"),en=tn.call(function(){},"prototype"),nn=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],rn=function(t){var i=t.constructor;return i&&i.prototype===t},hn={$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},on=function(){if(void 0===s)return!1;for(var t in s)try{if(!hn["$"+t]&&Ye.call(s,t)&&null!==s[t]&&"object"==typeof s[t])try{rn(s[t])}catch(t){return!0}}catch(t){return!0}return!1}(),an=function(t){if(void 0===s||!on)return rn(t);try{return rn(t)}catch(t){return!1}},Qe=function(t){var i=null!==t&&"object"==typeof t,s="[object Function]"===Ke.call(t),e=Ze(t),n=i&&"[object String]"===Ke.call(t),r=[];if(!i&&!s&&!e)throw new g("Object.keys called on a non-object");var h=en&&s;if(n&&t.length>0&&!Ye.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||!Ye.call(t,u)||r.push(String(u));if(sn)for(var c=an(t),l=0;l<nn.length;++l)c&&"constructor"===nn[l]||!Ye.call(t,nn[l])||r.push(nn[l]);return r});var pn=Qe,mn=Array.prototype.slice,gn=vn,yn=w.keys,bn=yn?function(t){return yn(t)}:pn,kn=w.keys;bn.shim=function(){if(w.keys){var t=function(){var t=w.keys(arguments);return t&&t.length===arguments.length}(1,2);t||(w.keys=function(t){return gn(t)?kn(mn.call(t)):kn(t)})}else w.keys=bn;return w.keys||bn};var wn=bn,_n="function"==typeof Mt&&"symbol"==typeof Mt("foo"),xn=w.prototype.toString,Cn=Array.prototype.concat,Sn=w.defineProperty,jn=Sn&&function(){var t={};try{for(var i in Sn(t,"x",{enumerable:!1,value:t}),t)return!1;return t.x===t}catch(t){return!1}}(),Tn=function(t,i,s,e){(!(i in t)||function(t){return"function"==typeof t&&"[object Function]"===xn.call(t)}(e)&&e())&&(jn?Sn(t,i,{configurable:!0,enumerable:!1,value:s,writable:!0}):t[i]=s)},Mn=function(t,i){var s=arguments.length>2?arguments[2]:{},e=wn(i);_n&&(e=Cn.call(e,w.getOwnPropertySymbols(i)));for(var n=0;n<e.length;n+=1)Tn(t,e[n],i[e[n]],s[e[n]])};Mn.supportsDescriptors=!!jn;var An,Pn=Mn,Nn=w.getOwnPropertyDescriptor?function(){return w.getOwnPropertyDescriptor(arguments,"callee").get}():function(){throw new g},En="function"==typeof Mt&&"symbol"==typeof Nt,Bn=w.getPrototypeOf||function(t){return t.__proto__},In=An,Fn=An,Dn=An,$n=void 0===j?An:Bn(j),Un={"$ %Array%":Array,"$ %ArrayBuffer%":"undefined"==typeof ArrayBuffer?An:ArrayBuffer,"$ %ArrayBufferPrototype%":"undefined"==typeof ArrayBuffer?An:ArrayBuffer.prototype,"$ %ArrayIteratorPrototype%":En?Bn([][Nt]()):An,"$ %ArrayPrototype%":Array.prototype,"$ %ArrayProto_entries%":Array.prototype.entries,"$ %ArrayProto_forEach%":Array.prototype.forEach,"$ %ArrayProto_keys%":Array.prototype.keys,"$ %ArrayProto_values%":Array.prototype.values,"$ %AsyncFromSyncIteratorPrototype%":An,"$ %AsyncFunction%":Fn,"$ %AsyncFunctionPrototype%":An,"$ %AsyncGenerator%":An,"$ %AsyncGeneratorFunction%":Dn,"$ %AsyncGeneratorPrototype%":An,"$ %AsyncIteratorPrototype%":An,"$ %Atomics%":"undefined"==typeof Atomics?An:Atomics,"$ %Boolean%":Boolean,"$ %BooleanPrototype%":Boolean.prototype,"$ %DataView%":"undefined"==typeof DataView?An:DataView,"$ %DataViewPrototype%":"undefined"==typeof DataView?An:DataView.prototype,"$ %Date%":Date,"$ %DatePrototype%":Date.prototype,"$ %decodeURI%":decodeURI,"$ %decodeURIComponent%":decodeURIComponent,"$ %encodeURI%":encodeURI,"$ %encodeURIComponent%":encodeURIComponent,"$ %Error%":m,"$ %ErrorPrototype%":m.prototype,"$ %eval%":eval,"$ %EvalError%":EvalError,"$ %EvalErrorPrototype%":EvalError.prototype,"$ %Float32Array%":"undefined"==typeof Float32Array?An:Float32Array,"$ %Float32ArrayPrototype%":"undefined"==typeof Float32Array?An:Float32Array.prototype,"$ %Float64Array%":"undefined"==typeof Float64Array?An:Float64Array,"$ %Float64ArrayPrototype%":"undefined"==typeof Float64Array?An:Float64Array.prototype,"$ %Function%":Function,"$ %FunctionPrototype%":Function.prototype,"$ %Generator%":An,"$ %GeneratorFunction%":In,"$ %GeneratorPrototype%":An,"$ %Int8Array%":"undefined"==typeof Int8Array?An:Int8Array,"$ %Int8ArrayPrototype%":"undefined"==typeof Int8Array?An:Int8Array.prototype,"$ %Int16Array%":"undefined"==typeof Int16Array?An:Int16Array,"$ %Int16ArrayPrototype%":"undefined"==typeof Int16Array?An:Int8Array.prototype,"$ %Int32Array%":"undefined"==typeof Int32Array?An:Int32Array,"$ %Int32ArrayPrototype%":"undefined"==typeof Int32Array?An:Int32Array.prototype,"$ %isFinite%":isFinite,"$ %isNaN%":S,"$ %IteratorPrototype%":En?Bn(Bn([][Nt]())):An,"$ %JSON%":JSON,"$ %JSONParse%":JSON.parse,"$ %Map%":"undefined"==typeof Map?An:Map,"$ %MapIteratorPrototype%":"undefined"!=typeof Map&&En?Bn((new Map)[Nt]()):An,"$ %MapPrototype%":"undefined"==typeof Map?An:Map.prototype,"$ %Math%":_,"$ %Number%":Number,"$ %NumberPrototype%":Number.prototype,"$ %Object%":w,"$ %ObjectPrototype%":w.prototype,"$ %ObjProto_toString%":w.prototype.toString,"$ %ObjProto_valueOf%":w.prototype.valueOf,"$ %parseFloat%":C,"$ %parseInt%":x,"$ %Promise%":"undefined"==typeof Promise?An:Promise,"$ %PromisePrototype%":"undefined"==typeof Promise?An:Promise.prototype,"$ %PromiseProto_then%":"undefined"==typeof Promise?An:Promise.prototype.then,"$ %Promise_all%":"undefined"==typeof Promise?An:Promise.all,"$ %Promise_reject%":"undefined"==typeof Promise?An:Promise.reject,"$ %Promise_resolve%":"undefined"==typeof Promise?An:Promise.resolve,"$ %Proxy%":"undefined"==typeof Proxy?An:Proxy,"$ %RangeError%":RangeError,"$ %RangeErrorPrototype%":RangeError.prototype,"$ %ReferenceError%":ReferenceError,"$ %ReferenceErrorPrototype%":ReferenceError.prototype,"$ %Reflect%":"undefined"==typeof Reflect?An:Reflect,"$ %RegExp%":RegExp,"$ %RegExpPrototype%":RegExp.prototype,"$ %Set%":"undefined"==typeof Set?An:Set,"$ %SetIteratorPrototype%":"undefined"!=typeof Set&&En?Bn((new Set)[Nt]()):An,"$ %SetPrototype%":"undefined"==typeof Set?An:Set.prototype,"$ %SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?An:SharedArrayBuffer,"$ %SharedArrayBufferPrototype%":"undefined"==typeof SharedArrayBuffer?An:SharedArrayBuffer.prototype,"$ %String%":String,"$ %StringIteratorPrototype%":En?Bn(""[Nt]()):An,"$ %StringPrototype%":String.prototype,"$ %Symbol%":En?Mt:An,"$ %SymbolPrototype%":En?Mt.prototype:An,"$ %SyntaxError%":k,"$ %SyntaxErrorPrototype%":k.prototype,"$ %ThrowTypeError%":Nn,"$ %TypedArray%":$n,"$ %TypedArrayPrototype%":$n?$n.prototype:An,"$ %TypeError%":g,"$ %TypeErrorPrototype%":g.prototype,"$ %Uint8Array%":void 0===j?An:j,"$ %Uint8ArrayPrototype%":void 0===j?An:j.prototype,"$ %Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?An:Uint8ClampedArray,"$ %Uint8ClampedArrayPrototype%":"undefined"==typeof Uint8ClampedArray?An:Uint8ClampedArray.prototype,"$ %Uint16Array%":"undefined"==typeof Uint16Array?An:Uint16Array,"$ %Uint16ArrayPrototype%":"undefined"==typeof Uint16Array?An:Uint16Array.prototype,"$ %Uint32Array%":"undefined"==typeof Uint32Array?An:Uint32Array,"$ %Uint32ArrayPrototype%":"undefined"==typeof Uint32Array?An:Uint32Array.prototype,"$ %URIError%":URIError,"$ %URIErrorPrototype%":URIError.prototype,"$ %WeakMap%":"undefined"==typeof WeakMap?An:WeakMap,"$ %WeakMapPrototype%":"undefined"==typeof WeakMap?An:WeakMap.prototype,"$ %WeakSet%":"undefined"==typeof WeakSet?An:WeakSet,"$ %WeakSetPrototype%":"undefined"==typeof WeakSet?An:WeakSet.prototype},Rn=function(t,i){if(arguments.length>1&&"boolean"!=typeof i)throw new g('"allowMissing" argument must be a boolean');var s="$ "+t;if(!(s in Un))throw new k("intrinsic "+t+" does not exist!");if(void 0===Un[s]&&!i)throw new g("intrinsic "+t+" exists, but is not available. Please file an issue!");return Un[s]},On=dn.call(Function.call,w.prototype.hasOwnProperty),Vn=Rn,Ln=Vn("%TypeError%"),Hn=Vn("%SyntaxError%"),qn=On,zn={"Property Descriptor":function(t,i){if("Object"!==t.Type(i))return!1;var s={"[[Configurable]]":!0,"[[Enumerable]]":!0,"[[Get]]":!0,"[[Set]]":!0,"[[Value]]":!0,"[[Writable]]":!0};for(var e in i)if(qn(i,e)&&!s[e])return!1;var n=qn(i,"[[Value]]"),r=qn(i,"[[Get]]")||qn(i,"[[Set]]");if(n&&r)throw new Ln("Property Descriptors may not be both accessor and data descriptors");return!0}},Wn=Number.isNaN||function(t){return t!=t},Gn=Number.isNaN||function(t){return t!=t},Xn=Number.isFinite||function(t){return"number"==typeof t&&!Gn(t)&&t!==1/0&&t!==-1/0},Jn=Function.prototype.toString,Qn=/^\s*class\b/,Yn=function(t){try{var i=Jn.call(t);return Qn.test(i)}catch(t){return!1}},Kn=w.prototype.toString,Zn="function"==typeof Mt&&"symbol"==typeof Mt.toStringTag,tr=function(t){if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if("function"==typeof t&&!t.prototype)return!0;if(Zn)return function(t){try{return!Yn(t)&&(Jn.call(t),!0)}catch(t){return!1}}(t);if(Yn(t))return!1;var i=Kn.call(t);return"[object Function]"===i||"[object GeneratorFunction]"===i},ir=w.prototype.toString,sr=function(t){return null===t||"function"!=typeof t&&"object"!=typeof t},er=tr,nr=function(t){var i;if((i=arguments.length>1?arguments[1]:"[object Date]"===ir.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(er(t[n[e]])&&(s=t[n[e]](),sr(s)))return s;throw new g("No default value")}throw new g("invalid [[DefaultValue]] hint supplied")},rr=Rn,hr=rr("%Object%"),or=rr("%TypeError%"),ar=rr("%String%"),ur=function(t,i,s,e){var n=zn[i];if("function"!=typeof n)throw new Hn("unknown record type: "+i);if(!n(t,e))throw new Ln(s+" must be a "+i);console.log(n(t,e),e)},cr=Wn,lr=Xn,dr=function(t){return t>=0?1:-1},fr=function(t,i){var s=t%i;return _.floor(s>=0?s:s+i)},vr=On,pr={ToPrimitive:function(t){return sr(t)?t:arguments.length>1?nr(t,arguments[1]):nr(t)},ToBoolean:function(t){return!!t},ToNumber:function(t){return+t},ToInteger:function(t){var i=this.ToNumber(t);return cr(i)?0:0!==i&&lr(i)?dr(i)*_.floor(_.abs(i)):i},ToInt32:function(t){return this.ToNumber(t)|0},ToUint32:function(t){return this.ToNumber(t)>>>0},ToUint16:function(t){var i=this.ToNumber(t);if(cr(i)||0===i||!lr(i))return 0;var s=dr(i)*_.floor(_.abs(i));return fr(s,65536)},ToString:function(t){return ar(t)},ToObject:function(t){return this.CheckObjectCoercible(t),hr(t)},CheckObjectCoercible:function(t,i){if(null==t)throw new or(i||"Cannot call method on "+t);return t},IsCallable:tr,SameValue:function(t,i){return t===i?0!==t||1/t==1/i:cr(t)&&cr(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(vr(t,s)&&!i[s])return!1;var e=vr(t,"[[Value]]"),n=vr(t,"[[Get]]")||vr(t,"[[Set]]");if(e&&n)throw new or("Property Descriptors may not be both accessor and data descriptors");return!0},IsAccessorDescriptor:function(t){return void 0!==t&&(ur(this,"Property Descriptor","Desc",t),!(!vr(t,"[[Get]]")&&!vr(t,"[[Set]]")))},IsDataDescriptor:function(t){return void 0!==t&&(ur(this,"Property Descriptor","Desc",t),!(!vr(t,"[[Value]]")&&!vr(t,"[[Writable]]")))},IsGenericDescriptor:function(t){return void 0!==t&&(ur(this,"Property Descriptor","Desc",t),!this.IsAccessorDescriptor(t)&&!this.IsDataDescriptor(t))},FromPropertyDescriptor:function(t){if(void 0===t)return t;if(ur(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 or("FromPropertyDescriptor must be called with a fully populated Property Descriptor")},ToPropertyDescriptor:function(t){if("Object"!==this.Type(t))throw new or("ToPropertyDescriptor requires an object");var i={};if(vr(t,"enumerable")&&(i["[[Enumerable]]"]=this.ToBoolean(t.enumerable)),vr(t,"configurable")&&(i["[[Configurable]]"]=this.ToBoolean(t.configurable)),vr(t,"value")&&(i["[[Value]]"]=t.value),vr(t,"writable")&&(i["[[Writable]]"]=this.ToBoolean(t.writable)),vr(t,"get")){var s=t.get;if(void 0!==s&&!this.IsCallable(s))throw new g("getter must be a function");i["[[Get]]"]=s}if(vr(t,"set")){var e=t.set;if(void 0!==e&&!this.IsCallable(e))throw new or("setter must be a function");i["[[Set]]"]=e}if((vr(i,"[[Get]]")||vr(i,"[[Set]]"))&&(vr(i,"[[Value]]")||vr(i,"[[Writable]]")))throw new or("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return i}},mr=dn.call(Function.call,String.prototype.replace),gr=/^[\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]+/,yr=/[\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]+$/,br=function(){var t=pr.ToString(pr.CheckObjectCoercible(this));return mr(mr(t,gr,""),yr,"")},kr=br,wr=function(){return String.prototype.trim&&"\u200b"==="\u200b".trim()?String.prototype.trim:kr},_r=Pn,xr=wr,Cr=Pn,Sr=br,jr=wr,Tr=function(){var t=xr();return _r(String.prototype,{trim:t},{trim:function(){return String.prototype.trim!==t}}),t},Mr=dn.call(Function.call,jr());Cr(Mr,{getPolyfill:jr,implementation:Sr,shim:Tr});var Ar=Mr,Pr=tr,Nr=w.prototype.toString,Er=w.prototype.hasOwnProperty,Br=Ar,Ir=function(t,i,s){if(!Pr(i))throw new g("iterator must be a function");var e;arguments.length>=3&&(e=s),"[object Array]"===Nr.call(t)?function(t,i,s){for(var e=0,n=t.length;e<n;e++)Er.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)Er.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))}(t,i,e)},Fr=function(){for(var t={},i=0;i<arguments.length;i++){var s=arguments[i];for(var e in s)Dr.call(s,e)&&(t[e]=s[e])}return t},Dr=w.prototype.hasOwnProperty;var $r=Ge.exports,Ur=Xe,Rr=function(t){if(!t)return{};var i={};return Ir(Br(t).split("\n"),function(t){var s=t.indexOf(":"),e=Br(t.slice(0,s)).toLowerCase(),n=Br(t.slice(s+1));void 0===i[e]?i[e]=n:!function(t){return"[object Array]"===w.prototype.toString.call(t)}(i[e])?i[e]=[i[e],n]:i[e].push(n)}),i},Or=Fr,Vr=Hr;function Lr(t,i,s){var e=t;return Ur(i)?(s=i,"string"==typeof t&&(e={uri:t})):e=Or(i,{uri:t}),e.callback=s,e}function Hr(t,i,s){return qr(i=Lr(t,i,s))}function qr(t){if(void 0===t.callback)throw new m("callback argument missing");var i=!1,s=function(s,e,n){i||(i=!0,t.callback(s,e,n))};function e(){var t=void 0;if(t=l.response?l.response:l.responseText||function(t){if("document"===t.responseType)return t.responseXML;var i=204===t.status&&t.responseXML&&"parsererror"===t.responseXML.documentElement.nodeName;if(""===t.responseType&&!i)return t.responseXML;return null}(l),b)try{t=JSON.parse(t)}catch(t){}return t}var n={body:void 0,headers:{},statusCode:0,method:v,url:f,rawRequest:l};function r(t){return c(d),t instanceof m||(t=new m(""+(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=Rr(l.getAllResponseHeaders()))):h=new m("Internal XMLHttpRequest Error"),s(h,r,r.body)}}var o,a,l=t.xhr||null;l||(l=t.cors||t.useXDR?new Hr.XDomainRequest:new Hr.XMLHttpRequest);var d,f=l.url=t.uri||t.url,v=l.method=t.method||"GET",p=t.body||t.data||null,g=l.headers=t.headers||{},y=!!t.sync,b=!1;if("json"in t&&(b=!0,g.accept||g.Accept||(g.Accept="application/json"),"GET"!==v&&"HEAD"!==v&&(g["content-type"]||g["Content-Type"]||(g["Content-Type"]="application/json"),p=JSON.stringify(t.json))),l.onreadystatechange=function(){4===l.readyState&&h()},l.onload=h,l.onerror=r,l.onprogress=function(){},l.ontimeout=r,l.open(v,f,!y,t.username,t.password),y||(l.withCredentials=!!t.withCredentials),!y&&t.timeout>0&&(d=u(function(){a=!0,l.abort("timeout");var t=new m("XMLHttpRequest timeout");t.code="ETIMEDOUT",r(t)},t.timeout)),l.setRequestHeader)for(o in g)g.hasOwnProperty(o)&&l.setRequestHeader(o,g[o]);else if(t.headers&&!function(t){for(var i in t)if(t.hasOwnProperty(i))return!1;return!0}(t.headers))throw new m("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}Hr.XMLHttpRequest=$r.XMLHttpRequest||function(){},Hr.XDomainRequest="withCredentials"in new Hr.XMLHttpRequest?Hr.XMLHttpRequest:$r.XDomainRequest,function(t,i){for(var s=0;s<t.length;s++)i(t[s])}(["get","put","post","patch","head","delete"],function(t){Hr["delete"===t?"del":t]=function(i,s,e){return(s=Lr(i,s,e)).method=t.toUpperCase(),qr(s)}});var zr=function(t,i){var s=new b.WebVTT.Parser(b,b.vttjs,b.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&&(b.console&&b.console.groupCollapsed&&b.console.groupCollapsed("Text Track parsing errors for "+i.src),e.forEach(function(t){return Ji.error(t)}),b.console&&b.console.groupEnd&&b.console.groupEnd()),s.flush()},Wr=function(t){function i(s){var e;if(void 0===s&&(s={}),!s.tech)throw new m("A tech was not provided.");var r=pe(s,{kind:Le[s.kind]||"subtitles",language:s.language||s.srclang||""}),h=He[r.mode]||"disabled",o=r.default;"metadata"!==r.kind&&"chapters"!==r.kind||(h="hidden");var a=e=t.call(this,r)||this;if(a.H=r.tech,Ws)for(var u in i.prototype)"constructor"!==u&&(a[u]=i.prototype[u]);a.L=[],a.q=[];var c=new Re(a.L),l=new Re(a.q),d=!1,f=n(a,function(){this.activeCues,d&&(this.trigger("cuechange"),d=!1)});return"disabled"!==h&&a.H.ready(function(){a.H.on("timeupdate",f)},!0),w.defineProperty(a,"default",{get:function(){return o},set:function(){}}),w.defineProperty(a,"mode",{get:function(){return h},set:function(t){var i=this;He[t]&&("showing"===(h=t)&&this.H.ready(function(){i.H.on("timeupdate",f)},!0),this.trigger("modechange"))}}),w.defineProperty(a,"cues",{get:function(){return this.W?c:null},set:function(){}}),w.defineProperty(a,"activeCues",{get:function(){if(!this.W)return null;if(0===this.cues.length)return l;for(var t=this.H.currentTime(),i=[],s=0,e=this.cues.length;s<e;s++){var n=this.cues[s];(n.startTime<=t&&n.endTime>=t||n.startTime===n.endTime&&n.startTime<=t&&n.startTime+.5>=t)&&i.push(n)}if(d=!1,i.length!==this.q.length)d=!0;else for(var r=0;r<i.length;r++)-1===this.q.indexOf(i[r])&&(d=!0);return this.q=i,l.O(this.q),l},set:function(){}}),r.src?(a.src=r.src,function(t,i){var s={uri:t},e=We(t);e&&(s.cors=e),Vr(s,n(this,function(t,s,e){if(t)return Ji.error(t,s);if(i.W=!0,"function"!=typeof b.WebVTT){if(i.H){var n=function(){return zr(e,i)};i.H.on("vttjsloaded",n),i.H.on("vttjserror",function(){Ji.error("vttjs failed to load, stopping trying to process "+i.src),i.H.off("vttjsloaded",n)})}}else zr(e,i)}))}(r.src,a)):a.W=!0,a||ye(e)}ke(i,t);var s=i.prototype;return s.addCue=function(t){var i=t;if(b.vttjs&&!(t instanceof b.vttjs.VTTCue)){for(var s in i=new b.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.O(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.O(this.L);break}}},i}(qe);Wr.prototype.A={cuechange:"cuechange"};var Gr=function(t){function i(s){var e,n;void 0===s&&(s={});var r=ye(e=t.call(this)||this);if(Ws)for(var h in r=$i.createElement("custom"),i.prototype)"constructor"!==h&&(r[h]=i.prototype[h]);var o=new Wr(s);return r.kind=o.kind,r.src=o.src,r.srclang=o.language,r.label=o.label,r.default=o.default,w.defineProperty(r,"readyState",{get:function(){return n}}),w.defineProperty(r,"track",{get:function(){return o}}),n=0,o.addEventListener("loadeddata",function(){n=2,r.trigger({type:"load",target:r})}),Ws?r||ye(e):e}return ke(i,t),i}(ge);Gr.prototype.A={load:"load"},Gr.NONE=0,Gr.LOADING=1,Gr.LOADED=2,Gr.ERROR=3;var Xr,Jr=function(){function t(i){void 0===i&&(i=[]);var s=this;if(Ws)for(var e in s=$i.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);s.X=[],w.defineProperty(s,"length",{get:function(){return this.X.length}});for(var n=0,r=i.length;n<r;n++)s.J(i[n]);if(Ws)return s}var i=t.prototype;return i.J=function(t){var i=this.X.length;""+i in this||w.defineProperty(this,i,{get:function(){return this.X[i]}}),-1===this.X.indexOf(t)&&this.X.push(t)},i.Y=function(t){for(var i,s=0,e=this.X.length;s<e;s++)if(t===this.X[s].track){i=this.X[s];break}return i},i.K=function(t){for(var i=0,s=this.X.length;i<s;i++)if(t===this.X[i]){this.X.splice(i,1);break}},t}(),Qr=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=ye(n),Ws))for(var r in e=$i.createElement("custom"),i.prototype)"constructor"!==r&&(e[r]=i.prototype[r]);e.Z=[],w.defineProperty(e,"length",{get:function(){return this.Z.length}});for(var h=0;h<s.length;h++)e.tt(s[h]);return e||ye(n)}ke(i,t);var s=i.prototype;return s.tt=function(t){var i=this.Z.length;""+i in this||w.defineProperty(this,i,{get:function(){return this.Z[i]}}),-1===this.Z.indexOf(t)&&(this.Z.push(t),this.trigger({track:t,type:"addtrack"}))},s.it=function(t){for(var i,s=0,e=this.length;s<e;s++)if(this[s]===t){(i=this[s]).off&&i.off(),this.Z.splice(s,1);break}i&&this.trigger({track:i,type:"removetrack"})},s.getTrackById=function(t){for(var i=null,s=0,e=this.length;s<e;s++){var n=this[s];if(n.id===t){i=n;break}}return i},i}(ge);for(Xr in Qr.prototype.A={change:"change",addtrack:"addtrack",removetrack:"removetrack"},Qr.prototype.A)Qr.prototype["on"+Xr]=null;var Yr=function(t){function i(s){var e,n;if(void 0===s&&(s=[]),Ws){for(var r in n=$i.createElement("custom"),Qr.prototype)"constructor"!==r&&(n[r]=Qr.prototype[r]);for(var h in i.prototype)"constructor"!==h&&(n[h]=i.prototype[h])}return(n=e=t.call(this,s,n)||this)||ye(e)}return ke(i,t),i.prototype.tt=function(i){t.prototype.tt.call(this,i),i.addEventListener("modechange",n(this,function(){this.trigger("change")}))},i}(Qr),Kr=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].selected=!1)},Zr=function(t){function i(s){var e,n;void 0===s&&(s=[]);for(var r=s.length-1;r>=0;r--)if(s[r].selected){Kr(s,s[r]);break}if(Ws){for(var h in n=$i.createElement("custom"),Qr.prototype)"constructor"!==h&&(n[h]=Qr.prototype[h]);for(var o in i.prototype)"constructor"!==o&&(n[o]=i.prototype[o])}return(n=e=t.call(this,s,n)||this).st=!1,w.defineProperty(n,"selectedIndex",{get:function(){for(var t=0;t<this.length;t++)if(this[t].selected)return t;return-1},set:function(){}}),n||ye(e)}ke(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.selected&&Kr(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("selectedchange",function(){s.st||(s.st=!0,Kr(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}(Qr),th=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].enabled=!1)},ih=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){th(s,s[r]);break}if(Ws){for(var h in n=$i.createElement("custom"),Qr.prototype)"constructor"!==h&&(n[h]=Qr.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||ye(e)}ke(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.enabled&&th(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("enabledchange",function(){s.st||(s.st=!0,th(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}(Qr),sh=void 0;var eh=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 Yr,e.initTextTrackListeners(),e.initTrackListeners(),i.nativeControlsForTouch||e.emitTapEvents(),e.constructor&&(e.l=e.constructor.name||"Unknown Tech"),e}ke(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(n(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 xe(0,0)},s.bufferedPercent=function(){return Ce(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 Ee(t),this.trigger("error")),this.lt},s.played=function(){return this.et?xe(0,0):xe()},s.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},s.initTextTrackListeners=function(){var t=n(this,function(){this.trigger("texttrackchange")}),i=this.textTracks();i&&(i.addEventListener("removetrack",t),i.addEventListener("addtrack",t),this.on("dispose",n(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(!b.WebVTT)if($i.body.contains(this.el())){if(!this.h["vtt.js"]&&Gi(sh)&&w.keys(sh).length>0)return void this.trigger("vttjsloaded");var i=$i.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}),b.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 Zr,this.rt},s.audioTracks=function(){return this.ht=this.ht||new ih,this.ht},s.textTracks=function(){return this.nt=this.nt||new Yr,this.nt},s.remoteTextTracks=function(){return this.ft=this.ft||new Yr,this.ft},s.remoteTextTrackEls=function(){return this.vt=this.vt||new Jr,this.vt},s.addTextTrack=function(t,i,s){if(!t)throw new m("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 Wr(n);return r.tt(h),h}(this,t,i,s)},s.createRemoteTextTrack=function(t){var i=pe(t,{tech:this});return new Gr(i)},s.addRemoteTextTrack=function(t,i){void 0===t&&(t={});var s=this.createRemoteTextTrack(t);return!0!==i&&!1!==i&&(Ji.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 m("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]:b&&b.videojs&&b.videojs[t]?(Ji.warn("The "+t+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),b.videojs[t]):void 0},i}(me);eh.prototype.nt,eh.prototype.ht,eh.prototype.rt,eh.prototype.featuresVolumeControl=!0,eh.prototype.featuresFullscreenResize=!1,eh.prototype.featuresPlaybackRate=!1,eh.prototype.featuresProgressEvents=!1,eh.prototype.featuresTimeupdateEvents=!1,eh.prototype.featuresNativeTextTracks=!1,eh.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:Ji.error("No source hander found for the current source.")),this.disposeSourceHandler(),this.off("dispose",this.disposeSourceHandler),s!==t.nativeSourceHandler&&(this.bt=i,this.off(this.v,"loadstart",t.prototype.kt),this.off(this.v,"loadstart",t.prototype.wt),this.one(this.v,"loadstart",t.prototype.kt)),this.yt=s.handleSource(i,this,this.h),this.on("dispose",this.disposeSourceHandler),this},t.prototype.kt=function(){this.one(this.v,"loadstart",t.prototype.wt)},t.prototype.wt=function(){this.disposeSourceHandler(),this.one(this.v,"loadstart",t.prototype.wt)},t.prototype.disposeSourceHandler=function(){this.bt&&(this.clearTracks(["audio","video"]),this.bt=null),this.cleanupAutoTextTracks(),this.yt&&(this.off(this.v,"loadstart",t.prototype.kt),this.off(this.v,"loadstart",t.prototype.wt),this.yt.dispose&&this.yt.dispose(),this.yt=null)}},me.registerComponent("Tech",eh),me.registerComponent("MediaTechController",eh),eh.registerTech("Tech",eh);var nh=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=ve(h[r]),a=eh.getTech(o);if(o||(a=me.getComponent(o)),a&&a.isSupported()){i._t(o);break}}return n}return ke(i,t),i}(me);me.registerComponent("MediaLoader",nh);var rh=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}ke(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=zi({className:this.buildCSSClass(),tabIndex:0},s),"button"===i&&Ji.error("Creating a ClickableComponent with an HTML element of "+i+" is not supported; use a Button instead."),e=zi({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=rs("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){ne($i,"keydown",n(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){re($i,"keydown",n(this,this.handleKeyPress))},i}(me);me.registerComponent("ClickableComponent",rh);var hh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).update(),i.on("posterchange",n(ye(e),e.update)),e}ke(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=rs("div",{className:"vjs-poster",tabIndex:-1});return Ys||(this.jt=rs("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}(rh);me.registerComponent("PosterImage",hh);var oh="#222",ah={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 uh(t,i){return"rgba("+x(t[1]+t[1],16)+","+x(t[2]+t[2],16)+","+x(t[3]+t[3],16)+","+i+")"}function ch(t,i,s){try{t.style[i]=s}catch(t){return}}var lh=function(t){function i(i,s,e){var r;return r=t.call(this,i,s,e)||this,i.on("loadstart",n(ye(r),r.toggleDisplay)),i.on("texttrackchange",n(ye(r),r.updateDisplay)),i.ready(n(ye(r),function(){if(i.H&&i.H.featuresNativeTextTracks)this.hide();else{i.on("fullscreenchange",n(this,this.updateDisplay));for(var t=this.h.playerOptions.tracks||[],s=0;s<t.length;s++)this.t.addRemoteTextTrack(t[s],!0);var e,r,h={captions:1,subtitles:1},o=this.t.textTracks();if(o){for(var a=0;a<o.length;a++){var u=o[a];u.default&&("descriptions"!==u.kind||e?u.kind in h&&!r&&(r=u):e=u)}r?r.mode="showing":e&&(e.mode="showing")}}})),r}ke(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 b.WebVTT&&b.WebVTT.processCues(b,[],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 b.WebVTT&&t.activeCues){for(var i=this.t.textTrackSettings.getValues(),s=[],e=0;e<t.activeCues.length;e++)s.push(t.activeCues[e]);b.WebVTT.processCues(b,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&&ch(h.firstChild,"color",uh(i.color||"#fff",i.textOpacity)),i.backgroundColor&&(h.firstChild.style.backgroundColor=i.backgroundColor),i.backgroundOpacity&&ch(h.firstChild,"backgroundColor",uh(i.backgroundColor||"#000",i.backgroundOpacity)),i.windowColor&&(i.windowOpacity?ch(h,"backgroundColor",uh(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 "+oh:"raised"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #222, 2px 2px #222, 3px 3px "+oh:"depressed"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #ccc, 0 1px #ccc, -1px -1px #222, 0 -1px "+oh:"uniform"===i.edgeStyle&&(h.firstChild.style.textShadow="0 0 4px #222, 0 0 4px #222, 0 0 4px #222, 0 0 4px "+oh)),i.fontPercent&&1!==i.fontPercent){var o=b.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=ah[i.fontFamily])}}}},i}(me);me.registerComponent("TextTrackDisplay",lh);var dh=function(t){function i(){return t.apply(this,arguments)||this}return ke(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"})},i}(me);me.registerComponent("LoadingSpinner",dh);var fh=function(t){function i(){return t.apply(this,arguments)||this}ke(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=zi({className:this.buildCSSClass()},i),"button"!==t&&(Ji.warn("Creating a Button with an HTML element of "+t+" is deprecated; use ClickableComponent instead."),i=zi({tabIndex:0},i),s=zi({role:"button"},s)),s=zi({type:"button","aria-live":"polite"},s);var e=me.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 Ji.warn("Adding an actionable (user controllable) child to a Button ("+s+") is not supported; use a ClickableComponent instead."),me.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}(rh);me.registerComponent("Button",fh);var vh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Tt=!1,e.on("mousedown",e.handleMouseDown),e}ke(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}(fh);vh.prototype.St="Play Video",me.registerComponent("BigPlayButton",vh);var ph=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).controlText(s&&s.controlText||"Close"),e}ke(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}(fh);me.registerComponent("CloseButton",ph);var mh=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}ke(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}(fh);function gh(t,i){void 0===i&&(i=t),t=t<0?0:t;var s=_.floor(t%60),e=_.floor(t/60%60),n=_.floor(t/3600),r=_.floor(i/60%60),h=_.floor(i/3600);return(S(t)||t===1/0)&&(n=e=s="-"),(n=n>0||h>0?n+":":"")+(e=((n||r>=10)&&e<10?"0"+e:e)+":")+(s=s<10?"0"+s:s)}mh.prototype.St="Play",me.registerComponent("PlayToggle",mh);var yh=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}ke(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=rs("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=gh(i,this.t.duration());e!==this.Mt&&(this.Mt=e,this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e)},i}(me);me.registerComponent("CurrentTimeDisplay",yh);var bh=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}ke(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=rs("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=gh(i);this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e}},i}(me);me.registerComponent("DurationDisplay",bh);var kh=function(t){function i(){return t.apply(this,arguments)||this}return ke(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}(me);me.registerComponent("TimeDivider",kh);var wh=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}ke(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=rs("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=gh(this.t.remainingTime());s!==this.Mt&&(this.Mt=s,this.S.innerHTML='<span class="vjs-control-text">'+i+"</span> -"+s)}},i}(me);me.registerComponent("RemainingTimeDisplay",wh);var _h=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}ke(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=rs("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.Ct=rs("span",{className:"vjs-control-text",innerHTML:this.localize("Stream Type")}),this.At=$i.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}(me);me.registerComponent("LiveDisplay",_h);var xh=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}ke(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=zi({tabIndex:0},s),e=zi({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(),$i.body.focus(),$i.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;$i.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=_s(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}(me);function Ch(t,i){if(!t||!i)return"";if("function"==typeof b.getComputedStyle){var s=b.getComputedStyle(t);return s?s[i]:""}return t.currentStyle[i]||""}me.registerComponent("Slider",xh);var Sh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Nt=[],e.on(i,"progress",e.update),e.on(i,"languagechange",e.handleLanguagechange),e}ke(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-load-progress"});return this.Et=rs("span",{innerHTML:this.localize("Loaded")}),this.Bt=$i.createTextNode(": 0%"),this.Ct=rs("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.Et),this.Ct.appendChild(this.Bt),i.appendChild(this.Ct),i},s.update=function(t){var i=this.t.buffered(),s=this.t.duration(),e=this.t.bufferedEnd(),n=this.Nt,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(rs()),n[h]=u),u.style.left=r(o,e),u.style.width=r(a-o,e)}for(var c=n.length;c>i.length;c--)this.v.removeChild(n[c-1]);n.length=i.length},s.handleLanguagechange=function(){this.Et.innerHTML=this.localize("Loaded")},i}(me);me.registerComponent("LoadProgressBar",Sh);var jh=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(n(ye(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}ke(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-play-progress vjs-slider-bar"});return this.It=rs("span",{innerHTML:this.localize("Progress")}),this.Ft=$i.createTextNode(": 0%"),this.Ct=rs("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.It),this.Ct.appendChild(this.Ft),i.appendChild(this.Ct),i},s.updateDataAttr=function(t){var i=this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime();this.v.setAttribute("data-current-time",gh(i,this.t.duration()))},s.handleLanguagechange=function(){this.It.innerHTML=this.localize("Progress")},i}(me);me.registerComponent("PlayProgressBar",jh);var Th=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(n(ye(e),e.updateDataAttr)),e}ke(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=rs("div",{className:"vjs-time-tooltip"}),this.It=rs("span",{innerHTML:this.localize("Progress")}),this.Ft=$i.createTextNode(": 0%"),this.Ct=rs("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.It),this.Ct.appendChild(this.Ft),i.appendChild(this.tooltip),i.appendChild(this.Ct),i},s.updateDataAttr=function(t){var i=gh(this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime(),this.t.duration());this.v.setAttribute("data-current-time",i),this.tooltip.innerHTML=i},s.handleLanguagechange=function(){this.It.innerHTML=this.localize("Progress")},i}(me);me.registerComponent("TooltipProgressBar",Th);var Mh=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(n(ye(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}ke(i,t);var s=i.prototype;return s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-holder"},{"aria-label":"progress bar"})},s.updateProgress=function(t){if(this.updateAriaAttributes(this.v),this.keepTooltipsInside){this.updateAriaAttributes(this.tooltipProgressBar.v),this.tooltipProgressBar.v.style.width=this.bar.v.style.width;var i=C(Ch(this.player().el(),"width")),s=C(Ch(this.tooltipProgressBar.tooltip,"width")),e=this.tooltipProgressBar.el().style;e.maxWidth=_.floor(i-s/2)+"px",e.minWidth=_.ceil(s/2)+"px",e.right="-"+s/2+"px"}},s.updateAriaAttributes=function(t){var i=this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime();t.setAttribute("aria-valuenow",(100*this.getPercent()).toFixed(2)),t.setAttribute("aria-valuetext",gh(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}(xh);Mh.prototype.h={children:["loadProgressBar","mouseTimeDisplay","playProgressBar"],barName:"playProgressBar"},Mh.prototype.playerEvent="timeupdate",me.registerComponent("SeekBar",Mh);var Ah=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=rs("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)}}(n(ye(e),e.handleMouseMove),25))}),e}ke(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-ws(this.el().parentNode).left;this.update(s,e)},s.update=function(t,i){var s=gh(t,this.t.duration());if(this.el().style.left=i+"px",this.el().setAttribute("data-current-time",s),this.keepTooltipsInside){var e=i-this.Dt(i)+1,n=C(Ch(this.tooltip,"width"))/2;this.tooltip.innerHTML=s,this.tooltip.style.right="-"+(n-e)+"px"}},s.calculateDistance=function(t){return _s(this.el().parentNode,t).x},s.Dt=function(t){if(!this.keepTooltipsInside)return t;var i=C(Ch(this.player().el(),"width")),s=C(Ch(this.tooltip,"width"))/2,e=t;return t<s?e=_.ceil(s):t>i-s&&(e=_.floor(i-s)),e},i}(me);me.registerComponent("MouseTimeDisplay",Ah);var Ph=function(t){function i(){return t.apply(this,arguments)||this}return ke(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},i}(me);Ph.prototype.h={children:["seekBar"]},me.registerComponent("ProgressControl",Ph);var Nh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"fullscreenchange",e.handleFullscreenChange),e}ke(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}(fh);Nh.prototype.St="Fullscreen",me.registerComponent("FullscreenToggle",Nh);var Eh=function(t){function i(){return t.apply(this,arguments)||this}return ke(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}(me);me.registerComponent("VolumeLevel",Eh);var Bh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.updateARIAAttributes),i.ready(n(ye(e),e.updateARIAAttributes)),e}ke(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}(xh);Bh.prototype.h={children:["volumeLevel"],barName:"volumeLevel"},Bh.prototype.playerEvent="volumechange",me.registerComponent("VolumeBar",Bh);var Ih=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 ke(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control"})},i}(me);Ih.prototype.h={children:["volumeBar"]},me.registerComponent("VolumeControl",Ih);var Fh=function(t){function i(){return t.apply(this,arguments)||this}ke(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",n(this,function(){this.unlockShowing()}))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=rs(i,{className:"vjs-menu-content"});var s=t.prototype.createEl.call(this,"div",{append:this.S,className:"vjs-menu"});return s.appendChild(this.S),ne(s,"click",function(t){t.preventDefault(),t.stopImmediatePropagation()}),s},i}(me);me.registerComponent("Popup",Fh);var Dh=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e}ke(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}(rh);me.registerComponent("PopupButton",Dh);var $h=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}ke(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++)ps(this.v,"vjs-vol-"+n);vs(this.v,"vjs-vol-"+s)},i}(fh);$h.prototype.St="Mute",me.registerComponent("MuteToggle",$h);var Uh=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(ye(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}ke(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 Fh(this.t,{contentElType:"div"}),i=new Bh(this.t,this.h.volumeBar);return t.addChild(i),this.menuContent=t,this.volumeBar=i,this.attachVolumeBarEvents(),t},s.handleClick=function(i){$h.prototype.handleClick.call(this),t.prototype.handleClick.call(this)},s.attachVolumeBarEvents=function(){this.menuContent.on(["mousedown","touchdown"],n(this,this.handleMouseDown))},s.handleMouseDown=function(t){this.on(["mousemove","touchmove"],n(this.volumeBar,this.volumeBar.handleMouseMove)),this.on(this.v.ownerDocument,["mouseup","touchend"],this.handleMouseUp)},s.handleMouseUp=function(t){this.off(["mousemove","touchmove"],n(this.volumeBar,this.volumeBar.handleMouseMove))},i}(Dh);Uh.prototype.volumeUpdate=$h.prototype.update,Uh.prototype.St="Mute",me.registerComponent("VolumeMenuButton",Uh);var Rh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).$t=-1,e.on("keydown",e.handleKeyPress),e}ke(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",n(this,function(t){this.unlockShowing()}))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=rs(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),ne(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}(me);me.registerComponent("Menu",Rh);var Oh=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e.Ut=!0,e.v.setAttribute("aria-haspopup","true"),e.v.setAttribute("role","menuitem"),e.on("keydown",e.handleSubmenuKeyPress),e}ke(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.Rt=!1,this.v.setAttribute("aria-expanded","false"),this.items&&this.items.length<=this.Ot?this.hide():this.show()},s.createMenu=function(){var t=new Rh(this.t);if(this.Ot=0,this.h.title){var i=rs("li",{className:"vjs-menu-title",innerHTML:ve(this.h.title),tabIndex:-1});this.Ot+=1,t.m.unshift(i),os(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",n(this,function(t){this.unpressButton(),this.v.blur()})),this.Rt?this.unpressButton():this.pressButton()},s.handleKeyPress=function(i){27===i.which||9===i.which?(this.Rt&&this.unpressButton(),9!==i.which&&i.preventDefault()):38===i.which||40===i.which?this.Rt||(this.pressButton(),i.preventDefault()):t.prototype.handleKeyPress.call(this,i)},s.handleSubmenuKeyPress=function(t){27!==t.which&&9!==t.which||(this.Rt&&this.unpressButton(),9!==t.which&&t.preventDefault())},s.pressButton=function(){this.Ut&&(this.Rt=!0,this.menu.lockShowing(),this.v.setAttribute("aria-expanded","true"),this.menu.focus())},s.unpressButton=function(){this.Ut&&(this.Rt=!1,this.menu.unlockShowing(),this.v.setAttribute("aria-expanded","false"),this.v.focus())},s.disable=function(){return this.Rt=!1,this.menu.unlockShowing(),this.v.setAttribute("aria-expanded","false"),this.Ut=!1,t.prototype.disable.call(this)},s.enable=function(){return this.Ut=!0,t.prototype.enable.call(this)},i}(rh);me.registerComponent("MenuButton",Oh);var Vh=function(t){function i(i,s){var e,r=s.tracks;if((e=t.call(this,i,s)||this).items.length<=1&&e.hide(),!r)return ye(e);var h=n(ye(e),e.update);return r.addEventListener("removetrack",h),r.addEventListener("addtrack",h),e.t.on("dispose",function(){r.removeEventListener("removetrack",h),r.removeEventListener("addtrack",h)}),e}return ke(i,t),i}(Oh);me.registerComponent("TrackButton",Vh);var Lh=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}ke(i,t);var s=i.prototype;return s.createEl=function(i,s,e){this.nonIconControl=!0;var n=t.prototype.createEl.call(this,"li",zi({className:"vjs-menu-item",tabIndex:-1},s),e);return this.Vt=$i.createTextNode(this.localize(this.h.label)),n.appendChild(this.Vt),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.Vt.innerHTML=this.localize(this.h.label)},i}(rh);me.registerComponent("MenuItem",Lh);var Hh=function(t){function i(i,s){var e,r,h=s.track,o=i.textTracks();if(s.label=h.label||h.language||"Unknown",s.selected=h.default||"showing"===h.mode,(e=t.call(this,i,s)||this).track=h,o){var a=n(ye(e),e.handleTracksChange);i.on(["loadstart","texttrackchange"],a),o.addEventListener("change",a),e.on("dispose",function(){o.removeEventListener("change",a)})}o&&void 0===o.onchange&&e.on(["tap","click"],function(){if("object"!=typeof b.Event)try{r=new b.Event("change")}catch(t){}r||(r=$i.createEvent("Event")).initEvent("change",!0,!0),o.dispatchEvent(r)});return e}ke(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}(Lh);me.registerComponent("TextTrackMenuItem",Hh);var qh=function(t){function i(i,s){var e;return s.track={player:i,kind:s.kind,label:s.kind+" off",default:!1,mode:"disabled"},s.selectable=!0,(e=t.call(this,i,s)||this).selected(!0),e}return ke(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}(Hh);me.registerComponent("OffTextTrackMenuItem",qh);var zh=function(t){function i(i,s){return void 0===s&&(s={}),s.tracks=i.textTracks(),t.call(this,i,s)||this}return ke(i,t),i.prototype.createItems=function(t){void 0===t&&(t=[]),t.push(new qh(this.t,{kind:this.Lt})),this.Ot+=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.Lt&&t.push(new Hh(this.t,{track:e,selectable:!0}))}return t},i}(Vh);me.registerComponent("TextTrackButton",zh);var Wh=function(t){function i(i,s){var e,r=s.track,h=s.cue,o=i.currentTime();return s.selectable=!0,s.label=h.text,s.selected=h.startTime<=o&&o<h.endTime,(e=t.call(this,i,s)||this).track=r,e.cue=h,r.addEventListener("cuechange",n(ye(e),e.update)),e}ke(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}(Lh);me.registerComponent("ChaptersTrackMenuItem",Wh);var Gh=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}ke(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-chapters-button "+t.prototype.buildCSSClass.call(this)},s.update=function(i){this.Ht&&(!i||"addtrack"!==i.type&&"removetrack"!==i.type)||this.setTrack(this.findChaptersTrack()),t.prototype.update.call(this)},s.setTrack=function(t){if(this.Ht!==t){if(this.qt||(this.qt=this.update.bind(this)),this.Ht){var i=this.t.remoteTextTrackEls().Y(this.Ht);i&&i.removeEventListener("load",this.qt),this.Ht=null}if(this.Ht=t,this.Ht){this.Ht.mode="hidden";var s=this.t.remoteTextTrackEls().Y(this.Ht);s&&s.addEventListener("load",this.qt)}}},s.findChaptersTrack=function(){for(var t=this.t.textTracks()||[],i=t.length-1;i>=0;i--){var s=t[i];if(s.kind===this.Lt)return s}},s.getMenuCaption=function(){return this.Ht&&this.Ht.label?this.Ht.label:this.localize(ve(this.Lt))},s.createMenu=function(){return this.h.title=this.getMenuCaption(),t.prototype.createMenu.call(this)},s.createItems=function(){var t=[];if(!this.Ht)return t;var i=this.Ht.cues;if(!i)return t;for(var s=0,e=i.length;s<e;s++){var n=i[s],r=new Wh(this.t,{track:this.Ht,cue:n});t.push(r)}return t},i}(zh);Gh.prototype.Lt="chapters",Gh.prototype.St="Chapters",me.registerComponent("ChaptersButton",Gh);var Xh=function(t){function i(i,s,e){var r;(r=t.call(this,i,s,e)||this).v.setAttribute("aria-label","Descriptions Menu");var h=i.textTracks();if(h){var o=n(ye(r),r.handleTracksChange);h.addEventListener("change",o),r.on("dispose",function(){h.removeEventListener("change",o)})}return r}ke(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.Lt&&"showing"===r.mode){s=!0;break}}s?this.disable():this.enable()},s.buildCSSClass=function(){return"vjs-descriptions-button "+t.prototype.buildCSSClass.call(this)},i}(zh);Xh.prototype.Lt="descriptions",Xh.prototype.St="Descriptions",me.registerComponent("DescriptionsButton",Xh);var Jh=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 ke(i,t),i.prototype.buildCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildCSSClass.call(this)},i}(zh);Jh.prototype.Lt="subtitles",Jh.prototype.St="Subtitles",me.registerComponent("SubtitlesButton",Jh);var Qh=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 ke(i,t),i.prototype.handleClick=function(t){this.player().getChild("textTrackSettings").show(),this.player().getChild("textTrackSettings").v.focus()},i}(Hh);me.registerComponent("CaptionSettingsMenuItem",Qh);var Yh=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}ke(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 Qh(this.t,{kind:this.Lt})),this.Ot+=1),t.prototype.createItems.call(this,i)},i}(zh);Yh.prototype.Lt="captions",Yh.prototype.St="Captions",me.registerComponent("CaptionsButton",Yh);var Kh=function(t){function i(i,s){var e,r=s.track,h=i.audioTracks();if(s.label=r.label||r.language||"Unknown",s.selected=r.enabled,(e=t.call(this,i,s)||this).track=r,h){var o=n(ye(e),e.handleTracksChange);h.addEventListener("change",o),e.on("dispose",function(){h.removeEventListener("change",o)})}return e}ke(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}(Lh);me.registerComponent("AudioTrackMenuItem",Kh);var Zh=function(t){function i(i,s){var e;return void 0===s&&(s={}),s.tracks=i.audioTracks&&i.audioTracks(),(e=t.call(this,i,s)||this).v.setAttribute("aria-label","Audio Menu"),e}ke(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.Ot=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 Kh(this.t,{track:e,selectable:!0}))}return t},i}(Vh);Zh.prototype.St="Audio Track",me.registerComponent("AudioTrackButton",Zh);var to=function(t){function i(i,s){var e,n=s.rate,r=C(n,10);return s.label=n,s.selected=1===r,s.selectable=!0,(e=t.call(this,i,s)||this).label=n,e.rate=r,e.on(i,"ratechange",e.update),e}ke(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}(Lh);to.prototype.contentElType="button",me.registerComponent("PlaybackRateMenuItem",to);var io=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}ke(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this);return this.Vt=rs("div",{className:"vjs-playback-rate-value",innerHTML:1}),i.appendChild(this.Vt),i},s.buildCSSClass=function(){return"vjs-playback-rate "+t.prototype.buildCSSClass.call(this)},s.createMenu=function(){var t=new Rh(this.player()),i=this.playbackRates();if(i)for(var s=i.length-1;s>=0;s--)t.addChild(new to(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.Vt.innerHTML=this.player().playbackRate()+"x")},i}(Oh);io.prototype.St="Playback Rate",me.registerComponent("PlaybackRateMenuButton",io);var so=function(t){function i(){return t.apply(this,arguments)||this}ke(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}(me);me.registerComponent("Spacer",so);var eo=function(t){function i(){return t.apply(this,arguments)||this}ke(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="&nbsp;",i},i}(so);me.registerComponent("CustomControlSpacer",eo);var no=function(t){function i(){return t.apply(this,arguments)||this}return ke(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"},{role:"group"})},i}(me);no.prototype.h={children:["playToggle","volumeMenuButton","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subtitlesButton","captionsButton","audioTrackButton","fullscreenToggle"]},me.registerComponent("ControlBar",no);var ro=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"error",e.open),e}ke(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}(Ue);ro.prototype.h=pe(Ue.prototype.h,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),me.registerComponent("ErrorDisplay",ro);var ho="vjs-text-track-settings",oo=["#000","Black"],ao=["#00F","Blue"],uo=["#0FF","Cyan"],co=["#0F0","Green"],lo=["#F0F","Magenta"],fo=["#F00","Red"],vo=["#FFF","White"],po=["#FF0","Yellow"],mo=["1","Opaque"],go=["0.5","Semi-Transparent"],yo=["0","Transparent"],bo={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[oo,vo,fo,co,ao,po,lo,uo]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[mo,go,yo]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[vo,oo,fo,co,ao,po,lo,uo]},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:[mo,go]},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:[yo,go,mo]}};function ko(t,i){if(i&&(t=i(t)),t&&"none"!==t)return t}bo.windowColor.options=bo.backgroundColor.options;var wo,_o=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).setDefaults(),e.hide(),e.updateDisplay=n(ye(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()}),qi(bo,function(t){e.on(e.$(t.selector),"change",e.updateDisplay)}),e.h.persistTextTrackSettings&&e.restoreSettings(),e}ke(i,t);var s=i.prototype;return s.zt=function(t){var i=this,s=bo[t],e=s.id.replace("%s",this.o);return[rs("label",{className:"vjs-label",textContent:s.label},{for:e}),rs("select",{id:e},void 0,s.options.map(function(t){return rs("option",{textContent:i.localize(t[1]),value:t[0]})}))]},s.Wt=function(){var t=rs("legend",{textContent:this.localize("Text")}),i=this.zt("color"),s=rs("span",{className:"vjs-text-opacity vjs-opacity"},void 0,this.zt("textOpacity"));return rs("fieldset",{className:"vjs-fg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Gt=function(){var t=rs("legend",{textContent:this.localize("Background")}),i=this.zt("backgroundColor"),s=rs("span",{className:"vjs-bg-opacity vjs-opacity"},void 0,this.zt("backgroundOpacity"));return rs("fieldset",{className:"vjs-bg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Xt=function(){var t=rs("legend",{textContent:this.localize("Window")}),i=this.zt("windowColor"),s=rs("span",{className:"vjs-window-opacity vjs-opacity"},void 0,this.zt("windowOpacity"));return rs("fieldset",{className:"vjs-window-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Jt=function(){return rs("div",{className:"vjs-tracksettings-colors"},void 0,[this.Wt(),this.Gt(),this.Xt()])},s.Qt=function(){var t=rs("div",{className:"vjs-font-percent vjs-tracksetting"},void 0,this.zt("fontPercent")),i=rs("div",{className:"vjs-edge-style vjs-tracksetting"},void 0,this.zt("edgeStyle")),s=rs("div",{className:"vjs-font-family vjs-tracksetting"},void 0,this.zt("fontFamily"));return rs("div",{className:"vjs-tracksettings-font"},void 0,[t,i,s])},s.Yt=function(){var t=rs("button",{className:"vjs-default-button",textContent:this.localize("Defaults")}),i=rs("button",{className:"vjs-done-button",textContent:"Done"});return rs("div",{className:"vjs-tracksettings-controls"},void 0,[t,i])},s.createEl=function(){var t=rs("div",{className:"vjs-tracksettings"},void 0,[this.Jt(),this.Qt(),this.Yt()]),i=rs("div",{className:"vjs-control-text",id:"TTsettingsDialogLabel-"+this.o,textContent:"Caption Settings Dialog"},{"aria-level":"1",role:"heading"}),s=rs("div",{className:"vjs-control-text",id:"TTsettingsDialogDescription-"+this.o,textContent:"Beginning of dialog window. Escape will cancel and close the window."}),e=rs("div",void 0,{role:"document"},[i,s,t]);return rs("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),Hi(t).reduce(function(s,e){return i(s,t[e],e)},s)}(bo,function(i,s,e){var n=function(t,i){return ko(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;qi(bo,function(s,e){!function(t,i,s){if(i)for(var e=0;e<t.options.length;e++)if(ko(t.options[e].value,s)===i){t.selectedIndex=e;break}}(i.$(s.selector),t[e],s.parser)})},s.setDefaults=function(){var t=this;qi(bo,function(i){var s=i.hasOwnProperty("default")?i.default:0;t.$(i.selector).selectedIndex=s})},s.restoreSettings=function(){var t;try{t=JSON.parse(b.localStorage.getItem(ho))}catch(t){Ji.warn(t)}t&&this.setValues(t)},s.saveSettings=function(){if(this.h.persistTextTrackSettings){var t=this.getValues();try{w.keys(t).length?b.localStorage.setItem(ho,JSON.stringify(t)):b.localStorage.removeItem(ho)}catch(t){Ji.warn(t)}}},s.updateDisplay=function(){var t=this.t.getChild("textTrackDisplay");t&&t.updateDisplay()},i}(me);me.registerComponent("TextTrackSettings",_o);var xo,Co=function(t){function i(i,s){var e;e=t.call(this,i,s)||this;var r=i.source,h=!1;if(r&&(e.v.currentSrc!==r.src||i.tag&&3===i.tag.Kt)?e.setSource(r):e.Zt(e.v),e.v.hasChildNodes()){for(var o=e.v.childNodes,a=o.length,u=[];a--;){var c=o[a];"track"===c.nodeName.toLowerCase()&&(e.featuresNativeTextTracks?(e.remoteTextTrackEls().J(c),e.remoteTextTracks().tt(c.track),h||e.v.hasAttribute("crossorigin")||!We(c.src)||(h=!0)):u.push(c))}for(var l=0;l<u.length;l++)e.v.removeChild(u[l])}return["audio","video"].forEach(function(t){var i=e.el()[t+"Tracks"],s=e[t+"Tracks"](),n=ve(t);e["featuresNative"+n+"Tracks"]&&i&&i.addEventListener&&(e["handle"+n+"ti"]=function(t){s.trigger({type:"change",target:s,currentTarget:s,srcElement:s})},e["handle"+n+"ii"]=function(t){return s.addTrack(t.track)},e["handle"+n+"si"]=function(t){return s.removeTrack(t.track)},i.addEventListener("change",e["handle"+n+"ti"]),i.addEventListener("addtrack",e["handle"+n+"ii"]),i.addEventListener("removetrack",e["handle"+n+"si"]),e["removeOld"+n+"ei"]=function(t){return e.ni(s,i)},e.on("loadstart",e["removeOld"+n+"ei"]))}),e.featuresNativeTextTracks&&(h&&Ji.warn(Zi(wo||(wo=Ui(["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=n(ye(e),e.handleTextTrackChange),e.hi=n(ye(e),e.handleTextTrackAdd),e.oi=n(ye(e),e.handleTextTrackRemove),e.ai()),e.ci(),(Qs||Is||Vs)&&!0===i.nativeControlsForTouch&&e.setControls(!0),e.di(),e.triggerReady(),e}ke(i,t);var s=i.prototype;return s.dispose=function(){var s=this;["audio","video","text"].forEach(function(t){var i=ve(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=$i.createElement("video");var e=pe({},this.h.tag&&ys(this.h.tag));Qs&&!0===this.h.nativeControlsForTouch||delete e.controls,gs(t,zi(e,{id:this.h.techId,class:"vjs-tech"}))}t.playerId=this.h.playerId}void 0!==this.h.preload&&bs(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?bs(t,h,h):ks(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){Ji(t,"Video is not ready. (Video.js)")}},s.duration=function(){var t=this;if(this.v.duration===1/0&&Us&&qs&&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=b.navigator&&b.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=$i.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),b.performance&&"function"==typeof b.performance.now?t.creationTime=b.performance.now():b.performance&&b.performance.timing&&"number"==typeof b.performance.timing.navigationStart&&(t.creationTime=b.Date.now()-b.performance.timing.navigationStart),t},i}(eh);ss()&&(Co.TEST_VID=$i.createElement("video"),(xo=$i.createElement("track")).kind="captions",xo.srclang="en",xo.label="English",Co.TEST_VID.appendChild(xo)),Co.isSupported=function(){try{Co.TEST_VID.volume=.5}catch(t){return!1}return!(!Co.TEST_VID||!Co.TEST_VID.canPlayType)},Co.canControlVolume=function(){try{var t=Co.TEST_VID.volume;return Co.TEST_VID.volume=t/2+.1,t!==Co.TEST_VID.volume}catch(t){return!1}},Co.canControlPlaybackRate=function(){if(Us&&qs&&zs<58)return!1;try{var t=Co.TEST_VID.playbackRate;return Co.TEST_VID.playbackRate=t/2+.1,t!==Co.TEST_VID.playbackRate}catch(t){return!1}},Co.supportsNativeTextTracks=function(){return Js},Co.supportsNativeVideoTracks=function(){return!(!Co.TEST_VID||!Co.TEST_VID.videoTracks)},Co.supportsNativeAudioTracks=function(){return!(!Co.TEST_VID||!Co.TEST_VID.audioTracks)},Co.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange"],Co.prototype.featuresVolumeControl=Co.canControlVolume(),Co.prototype.featuresPlaybackRate=Co.canControlPlaybackRate(),Co.prototype.movingMediaElementInDOM=!Ds,Co.prototype.featuresFullscreenResize=!0,Co.prototype.featuresProgressEvents=!0,Co.prototype.featuresTimeupdateEvents=!0,Co.prototype.featuresNativeTextTracks=Co.supportsNativeTextTracks(),Co.prototype.featuresNativeVideoTracks=Co.supportsNativeVideoTracks(),Co.prototype.featuresNativeAudioTracks=Co.supportsNativeAudioTracks();var So=Co.TEST_VID&&Co.TEST_VID.constructor.prototype.canPlayType,jo=/^application\/(?:x-|vnd\.apple\.)mpegurl/i,To=/^video\/mp4/i;Co.patchCanPlayType=function(){Rs>=4&&!Ls?Co.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&jo.test(t)?"maybe":So.call(this,t)}:Os&&(Co.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&To.test(t)?"maybe":So.call(this,t)})},Co.unpatchCanPlayType=function(){var t=Co.TEST_VID.constructor.prototype.canPlayType;return Co.TEST_VID.constructor.prototype.canPlayType=So,t},Co.patchCanPlayType(),Co.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){}}()}}},Co.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){Co.prototype[t]=function(){return this.v[t]||this.v.hasAttribute(t)}}),["muted","defaultMuted","autoplay","loop","playsinline"].forEach(function(t){Co.prototype["set"+ve(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){Co.prototype[t]=function(){return this.v[t]}}),["volume","src","poster","preload","playbackRate"].forEach(function(t){Co.prototype["set"+ve(t)]=function(i){this.v[t]=i}}),["pause","load"].forEach(function(t){Co.prototype[t]=function(){return this.v[t]()}}),eh.withSourceHandlers(Co),Co.nativeSourceHandler={},Co.nativeSourceHandler.canPlayType=function(t){try{return Co.TEST_VID.canPlayType(t)}catch(t){return""}},Co.nativeSourceHandler.canHandleSource=function(t,i){if(t.type)return Co.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 Co.nativeSourceHandler.canPlayType("video/"+s)}return""},Co.nativeSourceHandler.handleSource=function(t,i,s){i.setSrc(t.src)},Co.nativeSourceHandler.dispose=function(){},Co.registerSourceHandler(Co.nativeSourceHandler),me.registerComponent("Html5",Co),eh.registerTech("Html5",Co);var Mo=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","ratechange","volumechange","texttrackchange"],Ao=function(t){function i(s,e,n){var r;if(s.id=s.id||["vjs_video",Oi()].join("_"),(e=zi(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(ys(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 m("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&&ys(s),r.language(r.h.language),e.languages){var a={};w.getOwnPropertyNames(e.languages).forEach(function(t){a[t.toLowerCase()]=e.languages[t]}),r.pi=a}else r.pi=i.prototype.h.languages;r.mi={},r.gi=e.poster||"",r.yi=!!e.controls,s.controls=!1,r.bi=!1,r.v=r.createEl();var u=pe(r.h);if(e.plugins){var c=e.plugins;w.getOwnPropertyNames(c).forEach(function(t){"function"==typeof this[t]?this[t](c[t]):Ji.error("Unable to find plugin:",t)},ye(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.ki()&&r.addClass("vjs-no-flex"),Ds||r.addClass("vjs-workinghover"),i.players[r.o]=ye(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._i),r.on("stageclick",r.xi),r}ke(i,t);var s=i.prototype;return s.dispose=function(){this.trigger("dispose"),this.off("dispose"),this.Ci&&this.Ci.parentNode&&this.Ci.parentNode.removeChild(this.Ci),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.Si=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=ys(s);if(w.getOwnPropertyNames(n).forEach(function(t){"class"===t?i.className+=" "+n[t]:i.setAttribute(t,n[t])}),s.playerId=s.id,s.id+="ji",s.className="vjs-tech",s.player=i.player=this,this.addClass("vjs-paused"),!0!==b.VIDEOJS_NO_DYNAMIC_STYLE){this.Ci=de("vjs-styles-dimensions");var r=Ms(".vjs-styles-defaults"),h=Ms("head");h.insertBefore(this.Ci,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);vs(u,"vjs-hidden"),u.setAttribute("hidden","hidden")}return s.Kt=s.networkState,s.parentNode&&!e&&s.parentNode.insertBefore(i,s),os(s,i),this.m.unshift(s),this.v=i,i},s.width=function(t){return this.dimension("width",t)},s.height=function(t){return this.dimension("height",t)},s.dimension=function(t,i){var s="width"===t?"Ti":"Mi";if(void 0===i)return this[s]||0;if(""===i)this[s]=void 0;else{var e=C(i);if(S(e))return Ji.error('Improper value "'+i+'" supplied for for '+t),this;this[s]=e}return this.Ai(),this},s.fluid=function(t){if(void 0===t)return!!this.Pi;this.Pi=!!t,t?this.addClass("vjs-fluid"):this.removeClass("vjs-fluid"),this.Ai()},s.aspectRatio=function(t){if(void 0===t)return this.Ni;if(!/^\d+\:\d+$/.test(t))throw new m("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.Ni=t,this.fluid(!0),this.Ai()},s.Ai=function(){if(!0!==b.VIDEOJS_NO_DYNAMIC_STYLE){var t,i,s,e=(void 0!==this.Ni&&"auto"!==this.Ni?this.Ni:this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9").split(":"),n=e[1]/e[0];t=void 0!==this.Ti?this.Ti:void 0!==this.Mi?this.Mi/n:this.videoWidth()||300,i=void 0!==this.Mi?this.Mi:t*n,s=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(s),fe(this.Ci,"\n ."+s+" {\n width: "+t+"px;\n height: "+i+"px;\n }\n\n ."+s+".vjs-fluid {\n padding-top: "+100*n+"%;\n }\n ")}else{var r="number"==typeof this.Ti?this.Ti:this.h.width,h="number"==typeof this.Mi?this.Mi: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&&(eh.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.Bi=t,this.j=!1;var e=zi({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.Si||!1,"vtt.js":this.h["vtt.js"]},this.h[t.toLowerCase()]);this.tag&&(e.tag=this.tag),i&&(this.Fi=i.type,i.src===this.mi.src&&this.mi.currentTime>0&&(e.startTime=this.mi.currentTime),this.mi.sources=null,this.mi.source=i,this.mi.src=i.src);var r=eh.getTech(t);r||(r=me.getComponent(t)),this.H=new r(e),this.H.ready(n(this,this.Di),!0),De(this.$i||[],this.H),Mo.forEach(function(t){s.on(s.H,t,s["handleTech"+ve(t)+"_"])}),this.on(this.H,"loadstart",this.Ui),this.on(this.H,"waiting",this.Ri),this.on(this.H,"canplay",this.Oi),this.on(this.H,"canplaythrough",this.Vi),this.on(this.H,"playing",this.Li),this.on(this.H,"ended",this.Hi),this.on(this.H,"seeking",this.qi),this.on(this.H,"seeked",this.zi),this.on(this.H,"play",this.Wi),this.on(this.H,"firstplay",this.Gi),this.on(this.H,"pause",this.Xi),this.on(this.H,"durationchange",this.Ji),this.on(this.H,"fullscreenchange",this.Qi),this.on(this.H,"error",this.Yi),this.on(this.H,"loadedmetadata",this.Ai),this.on(this.H,"resize",this.Ai),this.on(this.H,"posterchange",this.Ki),this.on(this.H,"textdata",this.Zi),this.usingNativeControls(this.ts("controls")),this.controls()&&!this.usingNativeControls()&&this.ss(),this.H.el().parentNode===this.contentEl()||"Html5"===t&&this.tag||os(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.$i=Fe(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 b.alert(i),new m(i)},s.ss=function(){this.es(),this.on(this.H,"mousedown",this.ns),this.on(this.H,"touchstart",this.rs),this.on(this.H,"touchmove",this.hs),this.on(this.H,"touchend",this.us),this.on(this.H,"tap",this.cs)},s.es=function(){this.off(this.H,"tap",this.cs),this.off(this.H,"touchstart",this.rs),this.off(this.H,"touchmove",this.hs),this.off(this.H,"touchend",this.us),this.off(this.H,"mousedown",this.ns)},s.Di=function(){if(this.triggerReady(),this.mi.volume&&this.ls("setVolume",this.mi.volume),this.Ki(),this.Ji(),(this.src()||this.currentSrc())&&this.tag&&this.h.autoplay&&this.paused()){try{delete this.tag.poster}catch(t){Ji("deleting tag.poster throws in some browsers",t)}this.play()}},s.Ui=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-seeking"),this.error(null),this.paused()?(this.hasStarted(!1),this.trigger("loadstart")):(this.trigger("loadstart"),this.trigger("firstplay"))},s.hasStarted=function(t){return void 0!==t?(this.et!==t&&(this.et=t,t?(this.addClass("vjs-has-started"),this.trigger("firstplay")):this.removeClass("vjs-has-started")),this):!!this.et},s.Wi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},s.Ri=function(){var t=this;this.addClass("vjs-waiting"),this.trigger("waiting"),this.one("timeupdate",function(){return t.removeClass("vjs-waiting")})},s.Oi=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},s.Vi=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},s.Li=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},s.qi=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},s.zi=function(){this.removeClass("vjs-seeking"),this.trigger("seeked")},s.Gi=function(){this.h.starttime&&(Ji.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.Xi=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},s.Hi=function(){this.addClass("vjs-ended"),this.h.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},s.Ji=function(){this.duration(this.ts("duration"))},s.ns=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.cs=function(){this.userActive(!this.userActive())},s.rs=function(){this.userWasActive=this.userActive()},s.hs=function(){this.userWasActive&&this.reportUserActivity()},s.us=function(t){t.cancelable&&t.preventDefault()},s._i=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},s.xi=function(){this.reportUserActivity()},s.Qi=function(t,i){i&&(this.toggleClass("vjs-ios-native-fs",!(!i.nativeIOSFullscreen||!i.isFullscreen)),this.isFullscreen(i.isFullscreen)),this.trigger("fullscreenchange")},s.Yi=function(){var t=this.H.error();this.error(t)},s.Zi=function(){var t=null;arguments.length>1&&(t=arguments[1]),this.trigger("textdata",t)},s.getCache=function(){return this.mi},s.ls=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 Ji(t),t}},s.ts=function(t){if(this.H&&this.H.j)try{return this.H[t]()}catch(i){throw void 0===this.H[t]?Ji("Video.js: "+t+" method not defined for "+this.Bi+" playback technology.",i):"TypeError"===i.name?(Ji("Video.js: "+t+" unavailable on "+this.Bi+" playback technology element.",i),this.H.j=!1):Ji(i),i}},s.play=function(){return this.src()||this.currentSrc()?this.ls("play"):this.H.one("loadstart",function(){this.play()}),this},s.pause=function(){return this.ls("pause"),this},s.paused=function(){return!1!==this.ts("paused")},s.scrubbing=function(t){return void 0!==t?(this.bi=!!t,t?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing"),this):this.bi},s.currentTime=function(t){return void 0!==t?(this.ls("setCurrentTime",t),this):(this.mi.currentTime=this.ts("currentTime")||0,this.mi.currentTime)},s.duration=function(t){return void 0===t?void 0!==this.mi.duration?this.mi.duration:NaN:((t=C(t))<0&&(t=1/0),t!==this.mi.duration&&(this.mi.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.ts("buffered");return t&&t.length||(t=xe(0,0)),t},s.bufferedPercent=function(){return Ce(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=_.max(0,_.min(1,C(t))),this.mi.volume=i,this.ls("setVolume",i),this):(i=C(this.ts("volume")),S(i)?1:i)},s.muted=function(t){return void 0!==t?(this.ls("setMuted",t),this):this.ts("muted")||!1},s.supportsFullScreen=function(){return this.ts("supportsFullScreen")||!1},s.isFullscreen=function(t){return void 0!==t?(this.ds=!!t,this):!!this.ds},s.requestFullscreen=function(t){var i,s=Ae;return this.isFullscreen(!0),s.requestFullscreen?(ne($i,s.fullscreenchange,n(this,function t(i){this.isFullscreen($i[s.fullscreenElement]),!1===this.isFullscreen()&&re($i,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.ls("enterFullScreen"):(this.enterFullWindow(),this.trigger("fullscreenchange")),this},s.exitFullscreen=function(){var t=Ae;return this.isFullscreen(!1),t.requestFullscreen?$i[t.exitFullscreen]():this.H.supportsFullScreen()?this.ls("exitFullScreen"):(this.exitFullWindow(),this.trigger("fullscreenchange")),this},s.enterFullWindow=function(){this.isFullWindow=!0,this.docOrigOverflow=$i.documentElement.style.overflow,ne($i,"keydown",n(this,this.fullWindowOnEscKey)),$i.documentElement.style.overflow="hidden",vs($i.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,re($i,"keydown",this.fullWindowOnEscKey),$i.documentElement.style.overflow=this.docOrigOverflow,ps($i.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=ve(e[s]),r=eh.getTech(n);if(r||(r=me.getComponent(n)),r){if(r.isSupported()&&(i=r.canPlayType(t)))return i}else Ji.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(ve).map(function(t){return[t,eh.getTech(t)||me.getComponent(t)]}).filter(function(t){var i=t[0],s=t[1];return s?s.isSupported():(Ji.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.ts("src");var i=eh.getTech(this.Bi);return i||(i=me.getComponent(this.Bi)),Array.isArray(t)?this.fs(t):"string"==typeof t?this.src({src:t}):t instanceof w&&(t.type&&!i.canPlaySource(t,this.h[this.Bi.toLowerCase()])?this.fs([t]):(this.mi.sources=null,this.mi.source=t,this.mi.src=t.src,this.Fi=t.type||"",this.ready(function(){i.prototype.hasOwnProperty("setSource")?this.ls("setSource",t):this.ls("src",t.src),"auto"===this.h.preload&&this.load(),this.h.autoplay&&this.play()},!0))),this},s.fs=function(t){var i=this.selectSource(t);i?(i.tech===this.Bi?this.src(i.source):this._t(i.tech,i.source),this.mi.sources=t):(this.setTimeout(function(){this.error({code:4,message:this.localize(this.h.notSupportedMessage)})},0),this.triggerReady())},s.load=function(){return this.ls("load"),this},s.reset=function(){return this._t(ve(this.h.techOrder[0]),null),this.ls("reset"),this},s.currentSources=function(){var t=this.currentSource(),i=[];return 0!==w.keys(t).length&&i.push(t),this.mi.sources||i},s.currentSource=function(){var t={},i=this.currentSrc();return i&&(t.src=i),this.mi.source||t},s.currentSrc=function(){return this.ts("currentSrc")||this.mi.src||""},s.currentType=function(){return this.Fi||""},s.preload=function(t){return void 0!==t?(this.ls("setPreload",t),this.h.preload=t,this):this.ts("preload")},s.autoplay=function(t){return void 0!==t?(this.ls("setAutoplay",t),this.h.autoplay=t,this):this.ts("autoplay",t)},s.playsinline=function(t){return void 0!==t?(this.ls("setPlaysinline",t),this.h.playsinline=t,this):this.ts("playsinline")},s.loop=function(t){return void 0!==t?(this.ls("setLoop",t),this.h.loop=t,this):this.ts("loop")},s.poster=function(t){return void 0===t?this.gi:(t||(t=""),this.gi=t,this.ls("setPoster",t),this.trigger("posterchange"),this)},s.Ki=function(){!this.gi&&this.H&&this.H.poster&&(this.gi=this.H.poster()||"",this.trigger("posterchange"))},s.controls=function(t){return void 0!==t?(t=!!t,this.yi!==t&&(this.yi=t,this.usingNativeControls()&&this.ls("setControls",t),t?(this.removeClass("vjs-controls-disabled"),this.addClass("vjs-controls-enabled"),this.trigger("controlsenabled"),this.usingNativeControls()||this.ss()):(this.removeClass("vjs-controls-enabled"),this.addClass("vjs-controls-disabled"),this.trigger("controlsdisabled"),this.usingNativeControls()||this.es())),this):!!this.yi},s.usingNativeControls=function(t){return void 0!==t?(t=!!t,this.vs!==t&&(this.vs=t,t?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols"))),this):!!this.vs},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 Ee(t),this.addClass("vjs-error"),Ji.error("(CODE:"+this.lt.code+" "+Ee.errorTypes[this.lt.code]+")",this.lt.message,this.lt),this.trigger("error"),this)},s.reportUserActivity=function(t){this.ps=!0},s.userActive=function(t){return void 0!==t?((t=!!t)!==this.gs&&(this.gs=t,t?(this.ps=!0,this.removeClass("vjs-user-inactive"),this.addClass("vjs-user-active"),this.trigger("useractive")):(this.ps=!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.gs},s.wi=function(){var t,i,s,e,r=n(this,this.reportUserActivity);this.on("mousedown",function(){r(),this.clearInterval(t),t=this.setInterval(r,250)}),this.on("mousemove",function(t){t.screenX===i&&t.screenY===s||(i=t.screenX,s=t.screenY,r())}),this.on("mouseup",function(i){r(),this.clearInterval(t)}),this.on("keydown",r),this.on("keyup",r),this.setInterval(function(){if(this.ps){this.ps=!1,this.userActive(!0),this.clearTimeout(e);var t=this.h.inactivityTimeout;t>0&&(e=this.setTimeout(function(){this.ps||this.userActive(!1)},t))}},250)},s.playbackRate=function(t){return void 0!==t?(this.ls("setPlaybackRate",t),this):this.H&&this.H.featuresPlaybackRate?this.ts("playbackRate"):1},s.isAudio=function(t){return void 0!==t?(this.ys=!!t,this):!!this.ys},s.videoTracks=function(){return this.H?this.H.videoTracks():(this.rt=this.rt||new Zr,this.rt)},s.audioTracks=function(){return this.H?this.H.audioTracks():(this.ht=this.ht||new ih,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.ts("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.bs:(this.bs!==String(t).toLowerCase()&&(this.bs=String(t).toLowerCase(),void 0!==this.v&&this.trigger("languagechange")),this)},s.languages=function(){return pe(i.prototype.h.languages,this.pi)},s.toJSON=function(){var t=pe(this.h),i=t.tracks;t.tracks=[];for(var s=0;s<i.length;s++){var e=i[s];(e=pe(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 Ue(this,i);return this.addChild(e),e.on("dispose",function(){s.removeChild(e)}),e.open()},i.getTagSettings=function(t){var i={sources:[],tracks:[]},s=ys(t),e=s["data-setup"];if(fs(t,"vjs-fluid")&&(s.fluid=!0),null!==e){var n=Be(e||"{}"),r=n[0],h=n[1];r&&Ji.error(r),zi(s,h)}if(zi(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(ys(c)):"track"===l&&i.tracks.push(ys(c))}return i},s.ki=function(){var t=$i.createElement("i");return!("flexBasis"in t.style||"webkitFlexBasis"in t.style||"mozFlexBasis"in t.style||"msFlexBasis"in t.style||"msFlexOrder"in t.style)},i}(me);Ao.players={};var Po=b.navigator;Ao.prototype.h={techOrder:["html5","flash"],html5:{},flash:{},defaultVolume:0,inactivityTimeout:2e3,playbackRates:[],children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","controlBar","errorDisplay","textTrackSettings"],language:Po&&(Po.languages&&Po.languages[0]||Po.userLanguage||Po.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",fullscreenOptions:{navigationUI:"hide"}},["ended","seeking","seekable","networkState","readyState"].forEach(function(t){Ao.prototype[t]=function(){return this.ts(t)}}),Mo.forEach(function(t){Ao.prototype["handleTech"+ve(t)+"_"]=function(){return this.trigger(t)}}),me.registerComponent("Player",Ao);var No,Eo,Bo=function(t){function i(s){var e;void 0===s&&(s={});var n=pe(s,{kind:Ve[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(Ws)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return w.defineProperty(r,"enabled",{get:function(){return h},set:function(t){"boolean"==typeof t&&t!==h&&(h=t,this.trigger("enabledchange"))}}),n.enabled&&(r.enabled=n.enabled),r.W=!0,r||ye(e)}return ke(i,t),i}(qe),Io=function(t){function i(s){var e;void 0===s&&(s={});var n=pe(s,{kind:Oe[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(Ws)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return w.defineProperty(r,"selected",{get:function(){return h},set:function(t){"boolean"==typeof t&&t!==h&&(h=t,this.trigger("selectedchange"))}}),n.selected&&(r.selected=n.selected),r||ye(e)}return ke(i,t),i}(qe);function Fo(t,i,s){var e;if("string"==typeof t){if(0===t.indexOf("#")&&(t=t.slice(1)),Fo.getPlayers()[t])return i&&Ji.warn('Player "'+t+'" is already initialised. Options will not be applied.'),s&&Fo.getPlayers()[t].ready(s),Fo.getPlayers()[t];e=function(t){return 0===t.indexOf("#")&&(t=t.slice(1)),$i.getElementById(t)}(t)}else e=t;if(!e||!e.nodeName)throw new g("The element or ID supplied is not valid. (videojs)");if(e.player||Ao.players[e.playerId])return e.player||Ao.players[e.playerId];i=i||{},Fo.hooks("beforesetup").forEach(function(t){var s=t(e,pe(i));Wi(s)&&!Array.isArray(s)?i=pe(i,s):Ji.error("please return an object in beforesetup hooks")});var n=new(me.getComponent("Player"))(e,i,s);return Fo.hooks("setup").forEach(function(t){return t(n)}),n}"undefined"==typeof HTMLVideoElement&&ss()&&($i.createElement("video"),$i.createElement("audio"),$i.createElement("track")),Fo.ks={},Fo.hooks=function(t,i){return Fo.ks[t]=Fo.ks[t]||[],i&&(Fo.ks[t]=Fo.ks[t].concat(i)),Fo.ks[t]},Fo.hook=function(t,i){Fo.hooks(t,i)},Fo.removeHook=function(t,i){var s=Fo.hooks(t).indexOf(i);return!(s<=-1)&&(Fo.ks[t]=Fo.ks[t].slice(),Fo.ks[t].splice(s,1),!0)},!0!==b.VIDEOJS_NO_DYNAMIC_STYLE&&ss()&&((No=Ms(".vjs-styles-defaults"))||(No=de("vjs-styles-defaults"),(Eo=Ms("head"))&&Eo.insertBefore(No,Eo.firstChild),fe(No,"\n .video-js {\n width: 300px;\n height: 150px;\n }\n\n .vjs-fluid {\n padding-top: 56.25%\n }\n "))),le(1,Fo),Fo.VERSION="5.20.6-opentelly.14",Fo.options=Ao.prototype.h,Fo.getPlayers=function(){return Ao.players},Fo.players=Ao.players,Fo.getComponent=me.getComponent,Fo.registerComponent=function(t,i){eh.isTech(i)&&Ji.warn("The "+t+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),me.registerComponent.call(me,t,i)},Fo.getTech=eh.getTech,Fo.registerTech=eh.registerTech,Fo.browser=Ks,Fo.TOUCH_ENABLED=Qs,Fo.extend=function(t,i){void 0===i&&(i={});var s=function(){t.apply(this,arguments)},e={};for(var n in Wi(i)?("function"==typeof i.init&&(Ji.warn("Constructor logic via init() is deprecated; please use constructor() instead."),i.constructor=i.init),i.constructor!==w.prototype.constructor&&(s=i.constructor),e=i):"function"==typeof i&&(s=i),function(t,i){if("function"!=typeof i&&null!==i)throw new g("Super expression must either be null or a function, not "+typeof i);t.prototype=w.create(i&&i.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),i&&(t.ws=i)}(s,t),e)e.hasOwnProperty(n)&&(s.prototype[n]=e[n]);return s},Fo.mergeOptions=pe,Fo.bind=n,Fo.plugin=function(t,i){Ao.prototype[t]=i},Fo.addLanguage=function(t,i){var s;return t=(""+t).toLowerCase(),Fo.options.languages=pe(Fo.options.languages,((s={})[t]=i,s)),Fo.options.languages[t]},Fo.log=Ji,Fo.createTimeRange=Fo.createTimeRanges=xe,Fo.formatTime=gh,Fo.parseUrl=ze,Fo.isCrossOrigin=We,Fo.EventTarget=ge,Fo.on=ne,Fo.one=oe,Fo.off=re,Fo.trigger=he,Fo.xhr=Vr,Fo.TextTrack=Wr,Fo.AudioTrack=Bo,Fo.VideoTrack=Io,Fo.isEl=es,Fo.isTextNode=xs,Fo.createEl=rs,Fo.hasClass=fs,Fo.addClass=vs,Fo.removeClass=ps,Fo.toggleClass=ms,Fo.setAttributes=gs,Fo.getAttributes=ys,Fo.emptyEl=Cs,Fo.appendContent=Ss,Fo.insertContent=js,Fo.computedStyle=Ch,f(),f();function Do(t){const i=t.duration;if(S(i)){var s;const i=null==(s=t.source)?void 0:s.streamType;return"live"===i||"dvr"===i}return i===1/0}function $o(t){return t.scrubbing()?t.getCache().currentTime:t.currentTime()}function Uo(t){const i=Vo(t);return Do(t)?i.end(i.length-1):i.start(0)}function Ro(t){return Vo(t).start(0)}function Oo(t){const i=Vo(t);return i.end(i.length-1)-i.start(0)}function Vo(t){const i=t.seekable;if(i&&i.length)return i;let s=t.duration;return s=isFinite(s)?s:0,new Wt([0,s])._s()}function Lo(t,i){void 0===i&&(i=t);const s=t<0?"-":"";t=_.abs(t);let e=_.floor(t%60),n=_.floor(t/60%60),r=_.floor(t/3600);const h=_.floor(i/60%60),o=_.floor(i/3600);return(S(t)||t===1/0)&&(r=n=e="-"),r=Number(r)>0||o>0?r+":":"",n=((r||h>=10)&&Number(n)<10?"0"+n:n)+":",e=Number(e)<10?"0"+e:e,s+r+n+e}function Ho(t){return class extends t{get xs(){var t;return null!=(t=this.Cs)?t:this.Cs=qo(this.player())}dispose(){this.Cs=void 0,super.dispose()}constructor(...t){super(...t),this.Cs=void 0}}}function qo(t){return t.tech({IWillNotUseThisInPlugins:!0}).theoplayer()}function zo(t){const i=qo(t),s=()=>{const s=$o(t);t.toggleClass("theo-at-live",function(t,i){if(Do(t)){const s=t.seekable;return 0===s.length||s.end(s.length-1)-i<10}return!1}(i,s)),t.toggleClass("vjs-live",Do(i)),t.toggleClass("theo-dvr",function(t){return"dvr"===Tt(t.duration,t.seekable,t.source)}(i))};t.on("emptied",s),t.on("timeupdate",s),t.on("durationchange",s)}f(),f();function Wo(t,i,s){t.toggleClass("theo-ad-playing",i),t.toggleClass("theo-dai-ad-playing",i&&s)}function Go(){this.userActive(!1)}f(),f(),f();var Xo=class{constructor(t,i){this.type=void 0,this.target=void 0,this.playerEvent=void 0,this.type=t.type,this.target=i,this.playerEvent=t}},Jo=["loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange","resize"],Qo=Fo.getTech("Tech"),Yo=Fo.getTech("Html5"),Ko=class extends Qo{Ss(){var t;for(const t of Jo)this.xs.addEventListener(t,this.js);this.xs.addEventListener("error",this.Ts),this.xs.addEventListener("contentprotectionerror",this.Ts),this.xs.addEventListener("sourcechange",this.Ms),this.xs.addEventListener("loadstart",this.As),null==(t=this.xs.presentation)||t.addEventListener(Pi.MODE_CHANGE,this.Ps),this.xs.textTracks.addEventListener("addtrack",this.Ns),this.xs.textTracks.addEventListener("removetrack",this.Es),this.xs.textTracks.addEventListener("change",this.Bs),this.xs.audioTracks.addEventListener("addtrack",this.Is),this.xs.audioTracks.addEventListener("removetrack",this.Fs),this.xs.audioTracks.addEventListener("change",this.Ds)}$s(){var t;for(const t of Jo)this.xs.removeEventListener(t,this.js);this.xs.removeEventListener("error",this.Ts),this.xs.removeEventListener("contentprotectionerror",this.Ts),this.xs.removeEventListener("sourcechange",this.Ms),this.xs.removeEventListener("loadstart",this.As),null==(t=this.xs.presentation)||t.removeEventListener(Pi.MODE_CHANGE,this.Ps),this.xs.textTracks.removeEventListener("addtrack",this.Ns),this.xs.textTracks.removeEventListener("removetrack",this.Es),this.xs.textTracks.removeEventListener("change",this.Bs),this.xs.audioTracks.removeEventListener("addtrack",this.Is),this.xs.audioTracks.removeEventListener("removetrack",this.Fs),this.xs.audioTracks.removeEventListener("change",this.Ds)}Us(t){this.trigger(new Xo(t,this))}createEl(){const t=this.h,i=t.player;if(!i)throw new m(this.localize('Missing required tech option "player"'));const s=i.element;return Fo.setAttributes(s,{id:t.techId}),s}theoplayer(){return this.xs}addTextTrack(t,i,s){return super.addTextTrack(t,i,s)}buffered(){return this.xs.buffered}played(){return this.xs.played}reset(){this.xs.stop()}play(){this.xs.play()}pause(){this.xs.pause()}paused(){return this.xs.paused}currentTime(){return this.xs.currentTime}setCurrentTime(t){this.xs.currentTime=t}duration(){return this.xs.duration}volume(){return this.xs.volume}setVolume(t){this.xs.volume=t}muted(){return this.xs.muted}setMuted(t){this.xs.muted=t}src(t){if(void 0!==t)this.setSrc(t);else{if(this.xs.src)return this.xs.src;if(this.xs.source){if(!di(this.xs.source.ads))return this.xs.source.ads[0].sources;if(Qt(this.xs.source))return"This source is managed by the Uplynk integration extension.";if(Ft(this.xs.source))return"This source is managed by the DAI integration extension.";if(Jt(this.xs.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.xs.src}load(){this.setPreload("auto")}preload(){return this.xs.preload}setPreload(t){this.xs.preload=t}autoplay(){return this.xs.autoplay}setAutoplay(t){this.xs.autoplay=Boolean(t)}seeking(){return this.xs.seeking}seekable(){return this.xs.seekable}ended(){return this.xs.ended}playbackRate(){return this.xs.playbackRate}setPlaybackRate(t){this.xs.playbackRate=t}readyState(){return this.xs.readyState}networkState(){return 0}controls(){return!1}videoHeight(){return this.xs.videoHeight}videoWidth(){return this.xs.videoWidth}supportsFullScreen(){return this.xs.presentation.supportsMode(si.FULLSCREEN)}enterFullScreen(){this.xs.presentation.requestMode(si.FULLSCREEN)}exitFullScreen(){this.xs.presentation.requestMode(si.INLINE)}Rs(){const t=this.xs.ads;if(t&&t.playing)return!0;const i=this.xs.vr;return!(!i||i.state===Vt.Os)}initTextTrackListeners(){return this.on("touchend",t=>{this.Rs()&&(t.preventDefault=()=>{})}),super.initTextTrackListeners()}Zt(){if(!this.src())return;const t=this.readyState();if(0===t){let t=!1;const i=()=>{t=!0};this.on("loadstart",i);const 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")})}const 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.$s(),this.xs=null,super.dispose()}static isSupported(){return!0}static canPlayType(){return"maybe"}static canPlaySource(t){return"maybe"}get featuresVolumeControl(){return V}constructor(t={},i){super(t,i),this.xs=void 0,this.js=t=>this.Us(t),this.Vs=!1,this.Ms=()=>{void 0===this.xs.errorObject&&(this.Us(new Kt(this.xs.currentTime,this.xs.readyState)),this.Us(new I),this.Us(new ti(this.xs.duration)))},this.As=()=>{this.Us(new It(this.xs.currentTime))},this.Ns=t=>{this.textTracks().tt(t.track)},this.Is=t=>{this.audioTracks().tt(t.track)},this.Es=t=>{this.textTracks().it(t.track)},this.Fs=t=>{this.audioTracks().it(t.track)},this.Bs=()=>{const t=this.textTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Ds=()=>{const t=this.audioTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Ps=()=>{if(!this.supportsFullScreen())return;const t=this.Vs,i=this.xs.presentation.currentMode===si.FULLSCREEN;t!==i&&(this.Vs=i,this.trigger("fullscreenchange",{isFullscreen:i,nativeIOSFullscreen:!0}))},this.Ts=()=>{const t=this.xs.errorObject,i=t&&yt(t.code)||-1,s=t&&t.message||"An unknown error occurred.";this.error({code:i,message:this.localize(s)})},this.xs=this.h.player,this.Ss();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()}};Ko.prototype.featuresFullscreenResize=Yo.prototype.featuresFullscreenResize,Ko.prototype.featuresPlaybackRate=Yo.prototype.featuresPlaybackRate,Ko.prototype.featuresProgressEvents=!0,Ko.prototype.featuresTimeupdateEvents=!0,Ko.prototype.featuresNativeTextTracks=!0,Fo.registerTech("THEOplayer",Ko),f(),f(),f(),f();var Zo=class{constructor(t){this.Ls=void 0,this.Hs=t=>{ei(this.Ls,"theo-mobile-button-hover"),t.stopImmediatePropagation()},this.qs=t=>{ri(this.Ls,"theo-mobile-button-hover")},this.zs=t=>{this.Ls.blur()},this.Ls=t,t.addEventListener("touchstart",this.Hs),t.addEventListener("touchend",this.qs),t.addEventListener("focusin",this.zs)}};f(),f(),f(),f();var ta=Fo.getComponent("Menu"),ia=class extends(Ho(ta)){get Ws(){return this.player().el()}Gs(){ei(this.Ws,"theo-menu-opened")}Xs(){ri(this.Ws,"theo-menu-opened")}constructor(t,i){super(t,i)}};f();var sa=Fo.getComponent("MenuItem"),ea=class extends(Ho(sa)){get parentMenu(){return this.Js}buildCSSClass(){return"theo-menu-item vjs-menu-item"}createEl(){const t=super.createEl("li",{className:this.buildCSSClass(),tabIndex:0},{"aria-live":"off","aria-label":""});return t.innerHTML="",t}handleClick(t){this.Qs||(this.parentMenu.Ys(this),"tap"!==t.type&&"keydown"!==t.type||(this.Qs=!0,this.trigger("click"),this.Qs=!1))}dispose(){pi.Zs.Ks&&(this.el().removeEventListener("touchstart",this.Hs),this.el().removeEventListener("touchend",this.qs)),super.dispose()}constructor(t,i,s){super(t,z({selectable:!0},i)),this.Js=void 0,this.Qs=!1,this.Hs=t=>{ei(this.el(),"theo-mobile-menu-item-hover"),t.stopImmediatePropagation()},this.qs=t=>{ri(this.el(),"theo-mobile-menu-item-hover")},this.Js=s,pi.Zs.Ks&&(this.el().addEventListener("touchstart",this.Hs),this.el().addEventListener("touchend",this.qs))}};f();var na=Fo.getComponent("ClickableComponent"),ra=class extends na{get parentMenu(){return this.Js}get te(){return this.ie}set te(t){this.ie=t,this.el().setAttribute("tabindex",this.te?"0":"-1"),this.se()}buildCSSClass(){return"theo-primary-background theo-menu-header"}createEl(){const t=super.createEl("div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-live":"off","aria-label":""});return t.innerHTML="",t}handleClick(t){!this.Qs&&this.te&&(this.Js.ee(),"tap"===t.type&&(this.Qs=!0,this.trigger("click"),this.Qs=!1))}se(){this.te?this.el().setAttribute("aria-label",this.localize("Go back to the previous menu")):this.el().setAttribute("aria-label","")}constructor(t,i,s){super(t,i),this.Js=void 0,this.Qs=!1,this.ie=!1,this.Js=s,this.on(t,"languagechange",this.se)}},ha=class extends ia{get menuHeader(){return this.ne}get menuItems(){return this.children()}addMenuItem(t){t=z({playerOptions:this.h.playerOptions},t);const i=new ea(this.player(),t,this);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}addSubMenuItem(t){t=z({playerOptions:this.h.playerOptions},t);const i=this.re(this.player(),t);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}removeMenuItem(t){this.removeChild(t),this.trigger("menuchange")}buildCSSClass(){return"theo-menu vjs-menu"}Gs(){super.Gs(),s.removeEventListener("resize",this.he),s.addEventListener("resize",this.he),this.show()}oe(){const t=this.ae();if(!t)return;const i=t.getClientRects();pi.Zs.Ks?this.ue(t,i):this.ce(t,i)}ae(){var t;return null!=(t=this.contentEl().parentElement)?t:void 0}ce(t,i){}ue(t,i){}Xs(){s.removeEventListener("resize",this.he),super.Xs(),this.hide(),pi.Zs.Ks&&(this.el().removeAttribute("style"),this.contentEl().removeAttribute("style"))}createEl(){const t=super.createEl();t.className=this.buildCSSClass();const i=this.contentEl();ei(i,"theo-menu-content");const s=new ra(this.player(),this.h,this);return i.parentNode.insertBefore(s.el(),i),this.ne=s,t}Ys(t){}show(){return this.oe(),super.show()}dispose(){this.ne&&this.ne.dispose(),super.dispose()}constructor(t,i){super(t,i),this.le=void 0,this.he=()=>this.oe(),this.le=this.player().el(),this.hide(),this.on("menuchange",this.oe)}},oa=class extends ha{get de(){return this.fe}set de(t){this.fe&&this.fe.ve(this),this.fe=t,t&&t.pe(this)}me(t){this.de.ge(t,"replace")}ye(t){t.de.ge(this,"restore")}be(){ri(this.ke,"vjs-hidden"),this.ke.style.opacity="1",super.show()}we(){ei(this.ke,"vjs-hidden")}Gs(){this.de&&this.de.Gs(),super.Gs()}Xs(){this.de&&this.de.Xs(),super.Xs(),ei(this.ke,"vjs-hidden")}ae(){if(this.de&&this.de._e)return this.de._e.ke}ce(t,i){if(i.length>0){const t=i[0].height,s=i[0].width;this.fe.xe.style.height=t+"px",this.fe.xe.style.width=s+"px"}super.ce(t,i)}constructor(t,i){super(t,i)}};f();var aa=class{get xe(){return this.Ls}get _e(){return this.Ce}pe(t){t.we(),this.Ls.appendChild(t.ke)}ve(t){this.Ls.removeChild(t.ke)}ge(t,i){if(t==this.Ce)return;const s=this.Ce;if(this.Ce=t,this.Ce.be(),this._e.focus(),pi.Zs.Ks)s.we();else{const t="translateX(100%)",e="translateX(-100%)",n=ki("transform");s.ke.style.opacity="0",s.ke.style[n]="replace"===i?e:t,this.Ce.ke.style.opacity="1",this.Ce.ke.style[n]="",u(()=>{s.we(),s.ke.style[n]=""},300)}}Gs(){this.Se(),this.Ce.be(),this.je()}Xs(){this.Se(),this.Ce.we(),this.Te.we(),this.Ce=this.Te,this.je()}je(){vi(()=>{ri(this.Ls,"theo-no-transition"),ri(this.Ce.ke,"theo-no-transition")})}Se(){ei(this.Ls,"theo-no-transition"),ei(this.Ce.ke,"theo-no-transition")}constructor(t){this.Ce=void 0,this.Te=void 0,this.Ls=void 0,this.le=void 0,this.Te=this.Ce=t,this.Ls=h.createElement("div"),this.Ls.className="theo-tertiary-background theo-menu-animation-container",this.Ls.appendChild(this.Te.ke),this.le=this.Ce.player().el()}};f(),f();var ua=class extends oa{get ke(){return this.el()}get parentMenu(){return this.Me}re(t,i){const s=new ca(t,i,this);return s.subMenu.de=this.de,s}ee(){this.Ae()}Ys(t){super.Ys(t),this.Ae()}Ae(){this.parentMenu.ye(this)}buildCSSClass(){return"theo-submenu "+(this.Pe?"":"theo-leaf-submenu ")+"theo-menu-content theo-menu-content-animatable "+super.buildCSSClass()}addSubMenuItem(t){this.Pe=!0;const i=super.addSubMenuItem(t);return this.removeClass("theo-leaf-submenu"),i}constructor(t,i,s){super(t,i),this.Me=void 0,this.Pe=!1,this.Me=s,this.menuHeader.te=!0}},ca=class extends ea{get subMenu(){return this.Ne}handleClick(t){this.parentMenu.me(this.subMenu)}constructor(t,i,s){super(t,z({selectable:!1},i),s),this.Ne=void 0,this.Ne=new ua(t,i,s)}},la=class extends oa{get menuButton(){return this.Ee}createEl(){const t=Fo.createEl("div",{className:this.buildCSSClass()});return this.Be=super.createEl(),this.Be.className=super.buildCSSClass(),ei(this.Be,"theo-menu-content-animatable"),t.appendChild(this.Be),this.de=new aa(this),t.appendChild(this.de.xe),t}buildCSSClass(){return"theo-menu-animatable "+super.buildCSSClass()}re(t,i){const s=new ca(t,i,this);return s.subMenu.de=this.de,s}ce(t,i){super.ce(t,i);const s=this.le.getClientRects(),e=s.length>0?s[0]:void 0,n=C(getComputedStyle(this.el()).fontSize);Q(this.el(),this.Ee.el(),e,n)}get ke(){return this.Be}ee(){this.Ee.closeMenu()}dispose(){this.Ie||(this.Ie=!0,super.dispose())}constructor(t,i,s){super(t,i),this.Ee=void 0,this.Ie=!1,this.Ee=s}};f();var da=class{set Fe(t){this.De.innerHTML=this.$e.localize(t),this.Ue()&&this.Re(),li(this.$e.el())}get Fe(){return this.De.textContent||""}Ue(){return!ii(this.De,"vjs-hidden")}Oe(){this.$e.off("mouseover",this.Re),this.$e.off("mouseout",this.Ve),this.$e.off("dispose",this.Le),Yt(this.De)}constructor(t,i){this.De=void 0,this.$e=void 0,this.Re=()=>{ri(this.De,"vjs-hidden");const t=this.$e.player().contentEl().getClientRects(),i=t.length>0?t[0]:void 0,s=C(getComputedStyle(this.De).fontSize);Q(this.De,this.$e.el(),i,s)},this.Ve=()=>{ei(this.De,"vjs-hidden")},this.Le=()=>this.Oe(),this.$e=t,li(t.el()),fi(t.el()),this.De=h.createElement("span"),this.De.innerHTML=this.$e.localize(i),this.De.className="theo-button-tooltip vjs-hidden",this.De.setAttribute("aria-hidden","true"),this.$e.el().appendChild(this.De),this.$e.on("mouseover",this.Re),this.$e.on("mouseout",this.Ve),this.$e.on("dispose",this.Le)}},fa=Fo.getComponent("Button"),va=class extends(Ho(fa)){get He(){const t=this.el().parentElement;return!!t&&null!==t.querySelector(".theo-mobile-menu-background")}get menu(){return this.qe}isMenuOpen(){return this.ze}openMenu(){this.We&&!this.ze&&(this.qe.Gs(),this.el().setAttribute("aria-expanded","true"),this.ze=!0,this.qe.focus())}closeMenu(){this.We&&this.ze&&(this.qe.Xs(),this.el().setAttribute("aria-expanded","false"),this.ze=!1)}set minimumMenuItems(t){this.Ge=t,this.Xe()}buildCSSClass(){return"theo-controlbar-button vjs-menu-button vjs-menu-button-popup "+super.buildCSSClass()}createEl(t,i,s){return super.createEl("button",{},{"aria-live":"off"})}handleClick(){this.ze?this.closeMenu():this.openMenu()}enable(){return this.We=!0,super.enable()}disable(){return this.closeMenu(),this.We=!1,super.disable()}se(){this.De.Fe=this.controlText()}dispose(){this.player().removeChild(this.qe),this.qe.dispose(),this.De.Oe(),this.xs.removeEventListener("seeking",this.Je),super.dispose()}constructor(t,i){super(t,i),this.qe=void 0,this.De=void 0,this.ze=!1,this.Ge=1,this.We=!0,this.Qe=t=>{const i=this.el().contains(t.target),s=this.qe.el().contains(t.target);let e=!1;var n;pi.Zs.Ks&&this.He&&(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.Ye=t=>{27===t.which&&(this.closeMenu(),this.focus())},this.Je=()=>{this.ze&&this.closeMenu()},this.Xe=()=>{this.qe.menuItems.length>=this.Ge?this.show():(this.closeMenu(),this.hide())},this.qe=new la(t,i,this),this.player().getChild("controlBarMenuContainer").addChild(this.qe),this.De=new da(this,this.controlText()),this.el().setAttribute("aria-haspopup","true"),pi.Zs.Ke?(this.on(h,"touchend",this.Qe),new Zo(this.el())):(this.on(h,"click",this.Qe),this.on(h,"keydown",this.Ye),ji&&this.on(h,ji.Ze,this.closeMenu)),this.xs.addEventListener("seeking",this.Je),this.on(this.qe,"menuchange",this.Xe),this.on(t,"languagechange",this.se),this.Xe()}},pa=Fo.getComponent("Component"),ma=class extends(Fo.getComponent("ControlBar")){addMenuButton(t){t=z({playerOptions:this.h.playerOptions},t);const i=new va(this.player(),t);return this.addChild(i),i}removeMenuButton(t){this.removeChild(t)}createEl(){const 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)}};Fo.registerComponent("THEOControlBarShadow",class extends pa{createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-tertiary-color theo-control-bar-shadow"}}),f(),f();var ga=Fo.getComponent("VolumeBar"),ya=class extends ga{handleFocus(t){super.handleFocus(t),this.tn.addClass("focus-within")}handleBlur(t){super.handleBlur(t),this.tn.removeClass("focus-within")}constructor(t,i){super(t,i),this.tn=void 0,this.tn=i.sn}};f();var ba=Fo.getComponent("VolumeControl"),ka=class extends ba{constructor(t,i){super(t,i),this.nn=void 0,this.nn=new ya(t,{sn:this}),this.addChild(this.nn)}};ka.prototype.h=z({},ba.prototype.h,{children:[]}),Fo.registerComponent("VolumeControl",ka);var wa=class extends(Ho(ma)){rn(){this.hn(this.an())}un(){0===this.cn&&(this.cn=u(this.ln,100))}dn(t){"opacity"===t.propertyName&&(0!==this.cn&&(c(this.cn),this.cn=0),this.hn(!0))}fn(t){"opacity"===t.propertyName&&(this.an()||this.hn(!1))}an(){return"0"!==s.getComputedStyle(this.el()).opacity}hn(t){this.vn!==t&&(this.vn=t,t?this.pn():this.xs.textTrackStyle.marginBottom=void 0)}pn(){const t=this.el().getBoundingClientRect().height;this.xs.textTrackStyle.marginBottom!==t&&(this.xs.textTrackStyle.marginBottom=t)}dispose(){c(this.cn),this.cn=0,this.gn.mn(mi.yn,this.bn),this.gn.kn(),super.dispose()}constructor(t,i){super(t,i),this.gn=void 0,this.vn=!1,this.cn=0,this.ln=()=>{0!==this.cn&&(this.cn=0,this.hn(this.an()))},this.bn=()=>{this.vn&&this.pn()},this.on(t,"ready",this.rn),this.on(t,"pause",this.rn),this.on(t,"useractive",this.rn),this.on(t,"firstplay",this.un),this.on(t,"play",this.un),this.on(t,"userinactive",this.un),this.on("transitionstart",this.dn),this.on("transitionend",this.fn),this.gn=new _i(this.el()),this.gn.wn(mi.yn,this.bn),this.gn._n(!0)}};wa.prototype.h=z({},ma.prototype.h,{children:["progressControl","playToggle","muteToggle","volumeControl","currentTimeDisplay","timeDivider","durationDisplay","liveDisplay","remainingTimeDisplay","customControlSpacer","activeQualityLabel","vrButton","descriptionsButton","subtitlesButton","chromecastButton","airplayButton","multiViewButton","audioTrackButton","SettingsButton","fullscreenToggle"]}),Fo.registerComponent("ControlBar",wa),f();var _a=class extends ma{buildCSSClass(){return"theo-top-controlbar "+super.buildCSSClass()}constructor(t,i){super(t,i),t.topControlBar=this}};_a.prototype.h=z({},ma.prototype.h,{children:[]}),Fo.registerComponent("TopControlBar",_a),f();var xa=Fo.getComponent("CurrentTimeDisplay"),Ca=class extends(Ho(xa)){updateContent(){const t=$o(this.player()),i=this.xs,s=Ro(i),e=this.localize("Current Time"),n=Lo(_.max(0,t-s),Oo(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)}};Fo.registerComponent("CurrentTimeDisplay",Ca),f();var Sa=Fo.getComponent("DurationDisplay"),ja=class extends(Ho(Sa)){updateContent(){const t=this.xs,i=S(t.duration)?NaN:Oo(t),s=t.clip.endTime-t.clip.startTime,e=_.min(i,s)||0;if(this.ct!==e){this.ct=e;const t=this.localize("Duration Time"),i=Lo(e);this.S.innerHTML='<span class="vjs-control-text">'+t+"</span> "+i}}dispose(){var t;null==(t=this.xs)||t.clip.removeEventListener("change",this.xn),super.dispose()}constructor(t,i){var s;super(t,i),this.xn=()=>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.xs)||s.clip.addEventListener("change",this.xn)}};Fo.registerComponent("DurationDisplay",ja),f();var Ta=Fo.getComponent("Button"),Ma=class extends(Ho(Ta)){buildCSSClass(){return"theo-live-control "+super.buildCSSClass()}createEl(){const t=super.createEl("button",{},{"aria-live":"off"});return this.Cn=Fo.createEl("span",{className:"theo-live-control-indicator"}),Zt(t,this.Cn),t}createControlTextEl(t){const i=super.createControlTextEl(t);return Fo.removeClass(i,"vjs-control-text"),Fo.addClass(i,"theo-live-control-text"),i}handleClick(){var t;const i=this.xs;if(void 0!==(null==(t=i.hesp)?void 0:t.manifest))i.hesp.goLive();else{const t=this.player();t.currentTime(1/0),t.play()}}Sn(){Do(this.xs)?this.show():this.hide()}constructor(t,i){super(t,i),this.controlText("Live"),this.Sn(),this.on(t,"emptied",this.Sn),this.on(t,"durationchange",this.Sn),pi.Zs.Ke&&new Zo(this.el())}};Fo.registerComponent("LiveDisplay",Ma),f();var Aa=Fo.getComponent("LoadingSpinner");Fo.registerComponent("LoadingSpinner",class extends Aa{buildCSSClass(){return"theo-secondary-color vjs-loading-spinner "+super.buildCSSClass()}createEl(){const t=super.createEl();t.className=this.buildCSSClass();const i=Fo.createEl("div",{className:"theo-loading-spinner-rotator"}),s=Fo.createEl("div",{className:"theo-loading-spinner-circle-left"}),e=Fo.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)}}),f();var Pa=Fo.getComponent("LoadProgressBar"),Na=class extends(Ho(Pa)){update(){const t=this.xs,i=Wt.jn(Vo(t)),s=i.Tn(0),e=Wt.jn(t.buffered).Mn(i),n=i.An(0)-s;let r=e.V&&e.An(e.V-1)||0;r=_.max(0,r-s);const o=this.el(),a=this.Pn;o.style.width=Ea(r,n);for(let t=0;t<e.V;t++){const i=e.Tn(t),n=e.An(t);let u=a[t];u||(u=h.createElement("div"),a.push(u),o.appendChild(u)),u.style.left=Ea(i-s,r),u.style.width=Ea(n-i,r)}for(let t=a.length;t>e.V;t--)o.removeChild(a[t-1]);a.length=e.V}constructor(t,i){super(t,i),this.Pn=[],this.on(t,"emptied",this.update)}};function Ea(t,i){const s=t/i||0;return 100*(s>=1?1:s)+"%"}Fo.registerComponent("LoadProgressBar",Na),f();var Ba=Fo.getComponent("MouseTimeDisplay"),Ia=class extends(Ho(Ba)){handleMouseMove(t){const i=t,s=this.xs,e=Ro(s)+this.calculateDistance(i)*Oo(s),n=i.pageX-X(this.el().parentNode).left;this.update(e,n+"px")}handleTouchMove(t){const i=t,s=this.xs,e=Ro(s)+this.calculateDistance(i)*Oo(s),n=i.touches[0].pageX-X(this.el().parentNode).left;this.update(e,n+"px")}createEl(){const t=super.createEl();return this.Nn=Fo.createEl("span",{className:"theo-time-tooltip-text"}),t}update(t,i){this.En=t;const s=this.Bn(t);this.el().style.left=i,this.el().setAttribute("data-current-time",s),this.keepTooltipsInside&&(d(this.Nn,s),this.In())}In(){if(this.keepTooltipsInside&&this.tooltip.offsetParent){const t=this.player().contentEl(),i=t.getClientRects(),s=i.length>0?i[0]:void 0,e=C(getComputedStyle(t).fontSize);Q(this.tooltip,this.el(),s,e)}}Bn(t){const i=this.xs,s=t-Uo(i);return Lo(Do(i)?_.min(s,0):s,Oo(i))}dispose(){var t;this.xs.removeEventListener("dimensionchange",this.Fn),null==(t=this.xs.presentation)||t.removeEventListener(Pi.MODE_CHANGE,this.Fn),super.dispose()}constructor(t,i){var s;(super(t,i),this.En=NaN,this.Fn=()=>{const t=$o(this.player()),i=this.xs;let s=(t-Ro(i))/Oo(i)||0;s=Si(s,0,1),this.update(t,100*s+"%")},this.keepTooltipsInside&&(Fo.addClass(this.tooltip,"theo-secondary-color"),this.tooltip.appendChild(this.Nn)),this.on(t,"ready",()=>{this.on(t.controlBar.progressControl,"mouseenter",this.handleMouseMove)}),Dt.Ks)&&(this.on(t,"firstplay",this.Fn),this.on(t,"play",this.Fn),this.on(t,"seeking",this.Fn),this.on(t,"seeked",this.Fn),this.on(t,"timeupdate",this.Fn),this.xs.addEventListener("dimensionchange",this.Fn),null==(s=this.xs.presentation)||s.addEventListener(Pi.MODE_CHANGE,this.Fn),this.on(t,"ready",()=>{this.on(t.controlBar.progressControl,"touchstart",this.handleTouchMove),this.on(t.controlBar.progressControl,"touchmove",bi(t=>this.handleTouchMove(t),25)),this.Fn()}))}};Fo.registerComponent("MouseTimeDisplay",Ia),f();var Fa=Fo.getComponent("PlayProgressBar"),Da=class extends(Ho(Fa)){updateDataAttr(){const t=$o(this.player());this.el().setAttribute("data-current-time",this.Bn(t))}Bn(t){const i=this.xs;return Lo(t-Uo(i),Oo(i))}createEl(){const 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)}};Fo.registerComponent("PlayProgressBar",Da),f();var $a=Fo.getComponent("RemainingTimeDisplay"),Ua=class extends(Ho($a)){updateContent(){const t=this.xs,i=Oo(t);if(i){const s=Vo(t).end(0),e=this.localize("Remaining Time"),n=Lo(_.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)}};Fo.registerComponent("RemainingTimeDisplay",Ua),f(),f();var Ra=class{get xs(){var t;return null!=(t=this.Cs)?t:this.Cs=qo(this.Dn)}$n(){const t=this.Un;if(!t)return;const i=this.xs;if(0===i.seekable.length)return;const s=t.cues.slice();this.On.Rn(s);for(let t=0;t<s.length;t++){const e=s[t],n=s[t+1],r=!n||e.endTime!==n.startTime,h=new Oa(e,i,r);this.Vn.push(h),this.Ln.appendChild(h.xe)}}Hn(){this.xs.addEventListener("loadedmetadata",this.qn),this.xs.addEventListener("loadeddata",this.qn),this.xs.addEventListener("sourcechange",this.qn),this.xs.addEventListener("durationchange",this.zn),this.xs.clip.addEventListener("change",this.zn),this.xs.textTracks.addEventListener("addtrack",this.Wn),this.xs.textTracks.addEventListener("removetrack",this.Gn),this.xs.textTracks.addEventListener("change",this.qn)}Xn(){this.xs.removeEventListener("loadedmetadata",this.qn),this.xs.removeEventListener("loadeddata",this.qn),this.xs.removeEventListener("sourcechange",this.qn),this.xs.removeEventListener("durationchange",this.zn),this.xs.clip.removeEventListener("change",this.zn),this.xs.textTracks.removeEventListener("addtrack",this.Wn),this.xs.textTracks.removeEventListener("removetrack",this.Gn),this.xs.textTracks.removeEventListener("change",this.qn)}Jn(){if(!(this.xs.readyState<Et.Qn))for(const t of this.xs.textTracks)if(t.kind===jt.Yn&&t.mode===Ct.Kn&&t.cues.length>0&&t.readyState!==kt.ERROR)return t}Zn(t){const i=this.Un;t!==i&&(i&&(this.tr(),i.removeEventListener("cuechange",this.ir)),this.Un=t,t&&(t.addEventListener("cuechange",this.ir),this.zn()))}sr(t){this.On.er(t)}nr(){this.On.be()}rr(){this.On.we()}tr(){for(const t of this.Vn)t.Oe();this.On.hr(),this.Vn=[],this.ar=void 0}Oe(){this.Xn(),this.ur.removeEventListener("mousemove",this.cr),this.ur.removeEventListener("mouseenter",this.lr),this.ur.removeEventListener("mouseleave",this.dr),this.Zn(void 0),this.On.Oe(),this.Cs=void 0}constructor(t,i){this.Dn=void 0,this.Ln=void 0,this.On=void 0,this.ur=void 0,this.Un=void 0,this.Vn=void 0,this.ar=void 0,this.Cs=void 0,this.qn=void 0,this.Wn=void 0,this.Gn=void 0,this.cr=void 0,this.dr=void 0,this.lr=void 0,this.zn=void 0,this.ir=void 0,this.Dn=i,this.Vn=[],this.Cs=void 0,this.qn=()=>{this.Zn(this.Jn())},this.Wn=t=>{const i=t.track;i.kind===jt.Yn&&(i.addEventListener("addcue",this.qn),i.addEventListener("removecue",this.qn),i.addEventListener("readystatechange",this.qn)),this.qn()},this.Gn=t=>{const i=t.track;i.kind===jt.Yn&&(i.removeEventListener("addcue",this.qn),i.removeEventListener("removecue",this.qn),i.removeEventListener("readystatechange",this.qn)),this.qn()},this.cr=t=>{const i=this.xs,s=function(t,i){const s=X(t),e=t.offsetWidth,n=t.offsetHeight,r=s.top,h=s.left;let o,a;!function(t){return void 0!==t.changedTouches}(i)?(a=i.pageX,o=i.pageY):(a=i.changedTouches[0].pageX,o=i.changedTouches[0].pageY);const u=Si((r-o+n)/n,0,1),c=Si((a-h)/e,0,1);return{x:c,y:u}}(this.Ln,t);let e=Ro(i)+s.x*Oo(i);e===i.duration&&(e-=.1),this.sr(e)},this.dr=()=>{this.On.we()},this.lr=()=>{this.On.be()},this.zn=()=>{this.Un&&(this.tr(),this.$n(),this.ir())},this.ir=()=>{var t,i,s;const e=null==(i=this.Un)||null==(t=i.activeCues)?void 0:t[0],n=Ni(this.Vn,t=>t.pr===e);n!==this.ar&&(null==(s=this.ar)||s.mr(),this.ar=n,null==n||n.gr())},this.ur=t,this.On=new Va,this.Dn.contentEl().appendChild(this.On.xe),this.Ln=h.createElement("div"),ei(this.Ln,"theoplayer-chapterbar"),this.ur.appendChild(this.Ln),this.ur.addEventListener("mousemove",this.cr),this.ur.addEventListener("mouseenter",this.lr),this.ur.addEventListener("mouseleave",this.dr),this.Hn()}},Oa=class{get xe(){return this.Ls}gr(){ei(this.Ls,"theoplayer-chapter-indicator-active")}mr(){ri(this.Ls,"theoplayer-chapter-indicator-active")}yr(t,i){const s=t.seekable.start(0),e=t.seekable.end(t.seekable.length-1),n=e-s,r=this.pr.startTime,o=this.pr.endTime,a=o>=s&&r<=e,u=Si(r-s,0,n),c=Si(o-s,0,n),l=_.max(0,c-u),d=h.createElement("div");ei(d,"theoplayer-chapter-indicator");const f=h.createElement("div");ei(f,"theoplayer-chapter-indicator-highlight"),d.appendChild(f),i&&ei(d,"theoplayer-chapter-indicator-discontinuous");const v=u/n*100,p=l/n*100;return d.style.display=a?"":"none",d.style.width=p+"%",d.style.left=v+"%",d}Oe(){Yt(this.Ls)}constructor(t,i,s){this.pr=void 0,this.Ls=void 0,this.pr=t,this.Ls=this.yr(i,s)}},Va=class{we(){this.br--,0===this.br&&ri(this.xe,"theoplayer-chapter-hovering")}Rn(t){this.kr=t||[],this.kr.length>0&&(this.xe.style.display="")}wr(t){d(this._r,t.content)}hr(){this.kr=[],d(this._r,""),this.xe.style.display="none"}be(){this.br++,this.br>0&&ei(this.xe,"theoplayer-chapter-hovering")}er(t){for(const i of this.kr)if(La(i,t)){this.wr(i);break}}Oe(){Yt(this.xe)}constructor(){this.kr=[],this.xe=void 0,this._r=void 0,this.br=0,this.xe=h.createElement("div"),ei(this.xe,"theoplayer-chaptertitle"),this.xe.style.display="none",this._r=h.createElement("p"),this.xe.appendChild(this._r)}};function La(t,i){return new Wt([t.startTime,t.endTime]).Cr(i)}var Ha=Fo.getComponent("SeekBar"),qa=class extends(Ho(Ha)){updateAriaAttributes(t){const i=$o(this.player()),s=this.xs;t.setAttribute("aria-valuenow",(100*this.Sr(i)).toFixed(2)),t.setAttribute("aria-valuetext",Lo(i-Uo(s),Oo(s)))}getPercent(){return this.Sr(this.player().currentTime())}handleMouseMove(t){if(this.xs&&this.xs.ads&&this.xs.ads.playing)return;const i=this.xs;let s=Ro(i)+this.calculateDistance(t)*Oo(i);s>=i.duration&&(s=i.duration-.1),this.Ln.sr(s),this.player().currentTime(s)}handleMouseDown(t){this.playingStates.push(!this.player().paused()),this.Ln.nr(),super.handleMouseDown(t)}handleMouseUp(t){this.videoWasPlaying=Boolean(this.playingStates.pop()),this.Ln.rr(),super.handleMouseUp(t)}Sr(t){const i=this.xs,s=(t-Ro(i))/Oo(i);return Si(s,0,1)}dispose(){this.Ln.Oe(),B(this.playingStates)}constructor(t,i){super(t,i),this.Ln=void 0,this.playingStates=[],this.on(t,"emptied",this.update),this.on(t,"seeking",this.update),this.Ln=new Ra(this.el(),t)}};Fo.registerComponent("SeekBar",qa),f();var za=Fo.getComponent("ProgressControl");pi.Zs.Ks&&Fo.registerComponent("ProgressControl",class extends za{createEl(){return super.createEl("div",{className:"vjs-progress-control vjs-control"})}handleMouseMove(t){this.seekBar.handleMouseMove(t)}handleMouseDown(t){null==t.preventDefault||t.preventDefault.call(t),this.seekBar.handleMouseDown(t)}handleMouseUp(t){null==t.preventDefault||t.preventDefault.call(t),this.seekBar.handleMouseUp(t)}constructor(t,i){super(t,i),this.on(this,"touchmove",this.handleMouseMove),this.on("touchstart",this.handleMouseDown),this.on("touchend",this.handleMouseUp),this.seekBar.off(["touchmove","touchstart","touchend"])}}),f();var Wa=Fo.getComponent("TooltipProgressBar"),Ga=class extends(Ho(Wa)){updateDataAttr(){const t=$o(this.player()),i=this.Bn(t);this.el().setAttribute("data-current-time",i),this.tooltip.innerHTML=i}Bn(t){const i=this.xs;return Lo(t-Uo(i),Oo(i))}createEl(){const 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 Xa(t){for(const i of t)if(i.enabled)return i}function Ja(t){if(t)return t.label&&""!==t.label?{name:t.label,hd:!1}:{name:Qa(t),description:Ya(t),hd:!!t.height&&t.height>=720}}function Qa(t){return t.height?t.height+"p":t.bandwidth?Ya(t):""}function Ya(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":""}Fo.registerComponent("TooltipProgressBar",Ga),f(),f(),f(),f(),f();var Ka=class{get jr(){return this.Tr}set jr(t){const i=this.Tr;for(let s=i.length-1;s>=0;s--){const e=i[s];N(t,e)||this.Mr(e)}for(const i of t)this.Ar(i);this.Pr.oe()}get Nr(){return this.Pr.menuItems}Er(t){const i=this.Nr;if(i)for(const s of i)if(s.Br===t)return s}Ir(t){const i=this.Pr.addMenuItem();return i.Br=t,i.on("click",()=>this.Fr(i)),i.el().setAttribute("role","menuitemradio"),i}Dr(t){t.dispose()}$r(t){return!0}Ar(t){if(this.$r(t)){N(this.Tr,t)||this.Tr.push(t);const i=this.Er(t)||this.Ir(t);return this.Ur(i),i}this.Mr(t)}Mr(t){const i=this.Er(t);i&&(this.Pr.removeMenuItem(i),this.Dr(i)),A(this.Tr,t)}Oe(){const t=[];for(const i of this.Tr)t.push(i);for(const i of t)this.Mr(i);B(t)}constructor(t){this.Pr=void 0,this.Tr=[],this.Pr=t}},Za=class extends Ka{Rr(){return this.Or=h.createElement("span"),this.Or.className="theo-settings-control-menu-item-title",d(this.Or,this.Vr.localize("Quality")),this.Or}Lr(){return this.Hr=h.createElement("span"),this.Hr.className="theo-settings-control-menu-quality-automatic",d(this.Hr,this.Vr.localize("Automatic")),this.Hr}qr(){return this.zr=h.createElement("span"),d(this.zr,this.Vr.localize("Automatic")),this.zr}Wr(){return this.Gr=h.createElement("span"),this.Gr.className="theo-primary-color theo-settings-control-menu-item-hd-label",d(this.Gr,this.Vr.localize("HD")),this.Gr}Xr(){const t=h.createElement("span");t.className="theo-primary-color theo-settings-control-menu-item-value",t.appendChild(this.Hr),t.appendChild(h.createTextNode(" ")),t.appendChild(this.zr),t.appendChild(h.createTextNode(" ")),t.appendChild(this.Gr),this.Jr.el().appendChild(this.Or),this.Jr.el().appendChild(t),this.Jr.el().setAttribute("aria-label",this.Vr.localize("Open the video quality settings menu"))}Qr(){const t=this.Yr,i=t&&hu(t.targetQuality),s=t&&t.activeQuality,e=Ja(this.Kr(i||s))||{name:this.Vr.localize("Automatic")};d(this.zr,e.name),oi(this.Hr,"vjs-hidden",Boolean(i)),oi(this.Gr,"vjs-hidden",!e.hd)}Ur(t){const i=Ja(t.Br)||{name:this.Vr.localize("Automatic")};let s=i.name;i.hd&&(s+='<span class="theo-primary-color theo-settings-control-menu-item-hd-label">'+this.Vr.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.Vr.localize("Set video quality to ")+i.name),t.Br?t.selected(t.Br===this.Zr):t.selected(!this.Zr)}Fr(t){this.Yr&&(this.Yr.targetQuality=t.Br&&t.Br.videoQualities)}Kr(t,i){const s=i||this.jr;for(const i of s)if(t&&i&&-1!==i.videoQualities.indexOf(t))return i}Oe(){this.Cs.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.th),this.Vr.off("languagechange",this.se),this.Yr&&(this.Yr.removeEventListener("activequalitychanged",this.ih),this.Yr.removeEventListener("targetqualitychanged",this.sh),this.Yr.removeEventListener("update",this.eh)),super.Oe()}constructor(t,i,s){super(t.subMenu),this.Jr=void 0,this.Cs=void 0,this.Vr=void 0,this.Yr=void 0,this.Zr=void 0,this.Or=void 0,this.Hr=void 0,this.zr=void 0,this.Gr=void 0,this.th=()=>{const t=Xa(this.Cs.videoTracks);if(t===this.Yr)return;let i=[];if(this.Yr&&(this.Yr.removeEventListener("activequalitychanged",this.ih),this.Yr.removeEventListener("targetqualitychanged",this.sh),this.Yr.removeEventListener("update",this.eh)),this.Yr=t,t){t.addEventListener("activequalitychanged",this.ih),t.addEventListener("targetqualitychanged",this.sh),t.addEventListener("update",this.eh);const s=iu(nu(t.qualities.filter(t=>t.available)));i=s.length>1?[void 0,...s]:[void 0]}this.jr=i,this.sh(),this.ih()},this.eh=t=>{const i=t.track;if(i!==this.Yr)return;const s=iu(nu(i.qualities.filter(t=>t.available))),e=i&&hu(i.targetQuality);let n;this.Zr=this.Kr(e,s),n=s.length>1?[void 0,...s]:[void 0],this.jr=n,this.Qr()},this.ih=()=>{this.Ar(void 0),this.Qr()},this.sh=()=>{const t=Xa(this.Cs.videoTracks),i=t&&hu(t.targetQuality),s=this.Kr(i),e=this.Zr;s!==e&&(this.Zr=s,s&&e||this.Ar(void 0),e&&N(this.jr,e)&&this.Ar(e),i&&this.Ar(s),this.Qr())},this.se=()=>{d(this.Pr.menuHeader.el(),this.Vr.localize("Quality")),d(this.Or,this.Vr.localize("Quality")),d(this.Hr,this.Vr.localize("Automatic")),d(this.zr,this.Vr.localize("Automatic")),d(this.Gr,this.Vr.localize("HD")),this.Jr.el().setAttribute("aria-label",this.Vr.localize("Open the video quality settings menu"));for(const t of this.Nr)this.Ur(t);this.Qr()},this.Jr=t,this.Cs=i,this.Vr=s,this.Or=this.Rr(),this.Hr=this.Lr(),this.zr=this.qr(),this.Gr=this.Wr(),this.Xr(),d(this.Pr.menuHeader.el(),this.Vr.localize("Quality")),this.jr=[void 0],this.Cs.videoTracks.addEventListener(["addtrack","removetrack","change"],this.th),this.Vr.on("languagechange",this.se),this.th()}},tu=class{get height(){return this.nh[0].height}get bandwidth(){return this.nh[0].bandwidth}get videoQualities(){return this.nh}get label(){return this.nh[0].label}add(t){this.nh.push(t)}constructor(t){this.nh=void 0,this.nh=t}};function iu(t){const i=[];for(const s of t){const t=s;let e=!1;for(const s of i)if(ru(s,t)){s.add(t),e=!0;break}e||i.push(new tu([t]))}return i}function su(t,i){return t&&i?Ai(t,i):Ti.rh}function eu(t,i){return t===i?Ti.rh:su(t.height,i.height)||su(t.width,i.width)||su(t.bandwidth,i.bandwidth)}function nu(t){return xi(t,eu).reverse()}function ru(t,i){return t.label&&i.label&&t.label===i.label||ct(Ja(t),Ja(i))}function hu(t){return Lt(t)?1===t.length?t[0]:void 0:t}function ou(t){return 1===t?"Normal":""+_.round(100*t)/100}f();var au=class extends Ka{Rr(){return this.Or=h.createElement("span"),this.Or.className="theo-settings-control-menu-item-title",d(this.Or,this.Vr.localize("Speed")),this.Or}Xr(){const t=h.createElement("span");return t.className="theo-primary-color theo-settings-control-menu-item-value",this.Jr.el().appendChild(this.Or),this.Jr.el().appendChild(t),this.Jr.el().setAttribute("aria-label",this.Vr.localize("Open the video speed settings menu")),t}Ir(t){const i=super.Ir(t);return this.Ur(i),i}Ur(t){const i=t.Br,s=this.Vr.localize(ou(i));d(t.el(),s),t.el().setAttribute("aria-label",this.Vr.localize("Set video speed to ")+s),t.selected(t.Br===this.Cs.playbackRate)}Fr(t){this.Cs.playbackRate=t.Br}Oe(){this.Cs.removeEventListener("ratechange",this.hh),this.Vr.off("languagechange",this.se),super.Oe()}constructor(t,i,s,e){super(t.subMenu),this.Jr=void 0,this.Cs=void 0,this.Vr=void 0,this.oh=void 0,this.Or=void 0,this.ah=void 0,this.hh=()=>{this.oh&&this.Ar(this.oh);const t=this.Cs.playbackRate;this.oh=t,d(this.ah,this.Vr.localize(ou(t))),t&&this.Ar(t)},this.se=()=>{d(this.Pr.menuHeader.el(),this.Vr.localize("Speed")),d(this.Or,this.Vr.localize("Speed")),this.Jr.el().setAttribute("aria-label",this.Vr.localize("Open the video speed settings menu"));for(const t of this.Nr)this.Ur(t);this.hh()},this.Jr=t,this.Cs=i,this.Vr=s,this.Or=this.Rr(),this.ah=this.Xr(),d(this.Pr.menuHeader.el(),this.Vr.localize("Speed")),this.jr=e,this.Cs.addEventListener("ratechange",this.hh),this.Vr.on("languagechange",this.se),this.hh()}};Fo.registerComponent("SettingsButton",class extends va{createEl(){const t=super.createEl();return this.uh=Fo.createEl("span",{className:"theo-settings-control-label-hd theo-primary-background"}),d(this.uh,this.localize("HD")),t.appendChild(this.uh),t}buildCSSClass(){return"vjs-icon-cog theo-settings-control-button "+super.buildCSSClass()}se(){super.se(),d(this.uh,this.localize("HD")),d(this.menu.menuHeader.el(),this.localize("Settings"))}dispose(){this.Yr&&(this.Yr.removeEventListener("activequalitychanged",this.ih),this.Yr=void 0),this.xs.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.dh),this.fh.Oe(),this.ph.Oe(),super.dispose()}constructor(t,i){var s,e;super(t,i),this.mh=void 0,this.fh=void 0,this.gh=void 0,this.ph=void 0,this.Yr=void 0,this.dh=()=>{const t=Xa(this.xs.videoTracks);t!==this.Yr&&(this.Yr&&this.Yr.removeEventListener("activequalitychanged",this.ih),this.Yr=t,t&&t.addEventListener("activequalitychanged",this.ih),this.ih())},this.ih=()=>{var t;const i=null==(t=this.Yr)?void 0:t.activeQuality,s=Boolean(i&&i.height>=720);this.player().toggleClass("theo-hd",s)},ei(this.menu.el(),"theo-settings-control-menu"),d(this.menu.menuHeader.el(),t.localize("Settings")),this.controlText("Settings"),this.De.Fe=this.controlText(),this.mh=this.menu.addSubMenuItem({name:"QualityMenuItem"}),this.fh=new Za(this.mh,this.xs,t);const n=null!=(e=null==i||null==(s=i.playerOptions)?void 0:s.playbackRates)?e:[];this.gh=this.menu.addSubMenuItem({name:"PlaybackRateMenuItem"}),this.ph=new au(this.gh,this.xs,t,n),this.xs.videoTracks.addEventListener(["addtrack","removetrack","change"],this.dh),this.dh()}}),f(),f(),f();var uu=class extends Ka{yh(t){const i=t.label;if(i)return i;const s=t.language;if(s){const t=St(s);if(t)return t.bh}return s||""}kh(){this.jr=this.wh}Oe(){this.wh.removeEventListener("addtrack",this._h),this.wh.removeEventListener("removetrack",this.xh),this.wh.removeEventListener("change",this.Ch),super.Oe()}constructor(t,i){super(t),this.wh=void 0,this._h=t=>{const i=t.track;this.Ar(i),i.addEventListener("update",this.Sh)},this.xh=t=>{const i=t.track;this.Mr(i),i.removeEventListener("update",this.Sh)},this.Ch=t=>this.kh(),this.Sh=()=>{for(const t of this.jr)this.Ar(t)},this.wh=i,this.wh.addEventListener("addtrack",this._h),this.wh.addEventListener("removetrack",this.xh),this.wh.addEventListener("change",this.Ch),this.kh()}},cu=class extends uu{Ur(t){const i=t.Br,s=this.Vr.localize(this.yh(i));d(t.el(),s),t.el().setAttribute("aria-label",this.Vr.localize("Set the audio language to")+" "+s),t.selected(i.enabled)}Fr(t){const i=t.Br;for(const t of this.xs.audioTracks)t!==i&&(t.enabled=!1);i.enabled=!0}Oe(){this.Vr.off("languagechange",this.se),super.Oe()}constructor(t,i,s){super(t,i.audioTracks),this.xs=void 0,this.Vr=void 0,this.se=()=>{d(this.Pr.menuHeader.el(),this.Vr.localize("Language"));for(const t of this.Nr)this.Ur(t)},this.xs=i,this.Vr=s,d(this.Pr.menuHeader.el(),this.Vr.localize("Language")),this.Vr.on("languagechange",this.se)}};Fo.registerComponent("audioTrackButton",class extends va{buildCSSClass(){return"vjs-icon-audio theo-audio-track-control-button "+super.buildCSSClass()}dispose(){this.jh.Oe(),super.dispose()}constructor(t,i){super(t,i),this.jh=void 0,this.minimumMenuItems=2,this.jh=new cu(this.menu,this.xs,t),this.controlText("Language"),this.De.Fe=this.controlText()}}),f(),f();var lu=class extends uu{$r(t){return!!super.$r(t)&&(!t.forced&&At(t.kind))}Ir(t){const i=super.Ir(t);ei(i.el(),"theo-text-track-menu-item");const s=h.createElement("span");i.Th=s;const e=h.createElement("div");e.className="theo-text-track-menu-item-toggle",i.Mh=e;const n=t=>this.Ah(t,i);i.Ph=n,e.addEventListener("click",n);const 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}Ur(t){const i=t,s=i.Br,e=this.Vr.localize(this.yh(s));d(i.Th,e),i.el().setAttribute("aria-label",this.Vr.localize("Set the subtitle language to")+" "+e),i.el().setAttribute("role","menuitemcheckbox"),i.selected(s.mode===Ct.Kn)}Dr(t){const i=t;i.Mh.removeEventListener("click",i.Ph),super.Dr(t)}Fr(t){const i=t.Br;for(const t of this.xs.textTracks)t!==i&&T(t.kind,i.kind)&&(t.mode=Ct.Nh);i.mode!==Ct.Kn?i.mode=Ct.Kn:i.mode=Ct.Nh}Ah(t,i){t.stopImmediatePropagation(),this.Fr(i)}Oe(){this.Vr.off("languagechange",this.se),super.Oe()}constructor(t,i,s){super(t,i.textTracks),this.xs=void 0,this.Vr=void 0,this.se=()=>{d(this.Pr.menuHeader.el(),this.Vr.localize("Subtitles"));for(const t of this.Nr)this.Ur(t)},this.xs=i,this.Vr=s,d(this.Pr.menuHeader.el(),s.localize("Subtitles")),this.Vr.on("languagechange",this.se)}};Fo.registerComponent("subtitlesButton",class extends va{buildCSSClass(){return"vjs-icon-subtitles theo-text-track-control-button "+super.buildCSSClass()}dispose(){this.jh.Oe(),super.dispose()}constructor(t,i){super(t,i),this.jh=void 0,this.jh=new lu(this.menu,this.xs,t),this.controlText("Subtitles"),this.De.Fe=this.controlText()}}),f();var du=Fo.getComponent("playToggle"),fu=class extends(Ho(du)){handleClick(t){this.xs.muted||this.xs.prepareWithUserAction(),super.handleClick(t)}handlePlay(t){super.handlePlay(t),this.controlText("Pause"),this.De.Fe=this.controlText()}handlePause(t){this.xs.ended||(super.handlePause(t),this.controlText("Play"),this.De.Fe=this.controlText())}se(){this.De.Fe=this.controlText()}dispose(){this.De.Oe(),this.xs.removeEventListener("ended",this.Eh),super.dispose()}constructor(t,i){super(t,i),this.De=void 0,this.Eh=()=>{this.controlText("Replay"),this.De.Fe=this.controlText()},this.controlText("Play"),this.De=new da(this,this.controlText()),this.xs.addEventListener("ended",this.Eh),this.on(t,"languagechange",this.se),pi.Zs.Ke&&new Zo(this.el())}};Fo.registerComponent("playToggle",fu),f();var vu=Fo.getComponent("fullscreenToggle"),pu=class extends(Ho(vu)){handleClick(t){this.xs.prepareWithUserAction(),super.handleClick(t)}handleFullscreenChange(t){super.handleFullscreenChange(t),this.updateContent()}updateContent(){const t=this.player().isFullscreen()?"Exit fullscreen":"Fullscreen";this.controlText(t),this.De.Fe=this.controlText()}dispose(){this.De.Oe(),super.dispose()}constructor(t,i){super(t,i),this.De=void 0,this.controlText("Fullscreen"),this.De=new da(this,this.controlText()),pi.Zs.Ke&&new Zo(this.el()),this.on(t,"languagechange",this.updateContent)}};Fo.registerComponent("fullscreenToggle",pu),f();var mu=Fo.getComponent("muteToggle"),gu=class extends(Ho(mu)){handleClick(t){this.xs.muted&&!this.xs.paused&&this.xs.prepareWithUserAction(),super.handleClick(t)}update(t){super.update(t),this.se()}se(){const t=this.player().muted()?"Unmute":"Mute";this.controlText(t),this.De.Fe=this.controlText()}dispose(){this.De.Oe(),super.dispose()}constructor(t,i){super(t,i),this.De=void 0,this.controlText("Mute"),this.De=new da(this,this.controlText()),pi.Zs.Ke&&new Zo(this.el()),this.on(t,"languagechange",this.se),R&&(this.removeClass("vjs-hidden"),this.on(t,"loadstart",()=>{this.removeClass("vjs-hidden")}))}};Fo.registerComponent("muteToggle",gu),f();var yu=Fo.getComponent("BigPlayButton"),bu="theo-play-svg-circle",ku='<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="'+bu+'" 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>',wu=class extends(Ho(yu)){createEl(){const t=super.createEl(),i=Fo.createEl("div",{className:"theo-big-play-button-svg-container"});return i.innerHTML=ku,t.appendChild(i),t}buildCSSClass(){return"theo-primary-color "+super.buildCSSClass()}handleClick(t){this.xs.muted||this.xs.prepareWithUserAction(),super.handleClick(t),void 0!==this.xs.vr&&"unavailable"!==this.xs.vr.state&&(this.xs.vr.useDeviceMotionControls=!0)}};Fo.registerComponent("BigPlayButton",wu),f();var _u=/^([^#]*)#xywh=(\d+),(\d+),(\d+),(\d+)\s*$/;Fo.registerComponent("MouseTimeDisplay",class extends Ia{Bh(t){const i=t.track;"metadata"===i.kind&&"thumbnails"===i.label&&void 0===this.Ih&&(this.Ih=i,this.Fh=i.src?pi.Dh(i.src).href:void 0,this.Ih.addEventListener(["addcue","removecue"],this.$h),this.Uh())}Rh(t){t.track===this.Ih&&this.Oh()}createEl(){const t=super.createEl();return this.Vh=Fo.createEl("img",{className:"theo-time-tooltip-thumbnail"}),this.Lh=Fo.createEl("canvas",{className:"theo-time-tooltip-thumbnail"}),t}update(t,i){super.update(t,i),this.keepTooltipsInside&&this.Hh(t)}Hh(t){let i;if(this.Ih&&this.Ih.cues){const s=function(t,i){let s=t[0];for(const e of t)if(e.startTime<=i)s=e;else if(i>=e.endTime)return s;return s}(this.Ih.cues,t);i=s&&s.content}if(i===this.qh)return;if(this.qh=i,Fo.toggleClass(this.el(),"theo-time-tooltip-has-thumbnail",Boolean(i)),!i)return void this.zh();const s=i.match(_u);if(s){let[,t,i,e,n,r]=s;t=this.Wh(t);const h={Gh:Number(i),Xh:Number(e),Ti:Number(n),Mi:Number(r)};this.Jh(t,h)}else{const t=this.Wh(i);this.Jh(t)}}Uh(){S(this.En)||this.Hh(this.En)}Wh(t){return this.Ih&&this.Fh?pi.Dh(t,this.Fh).href:t}Jh(t,i){this.Vh&&(this.Vh.src!==t?(this.Vh.onload=()=>{this.Qh(i)},this.Vh.src="",this.Vh.src=t):this.Qh(i))}Qh(t){if(!this.Lh||!this.Vh)return;const i=this.Lh.getContext("2d");i&&(null!=t||(t={Gh:0,Xh:0,Ti:this.Vh.naturalWidth,Mi:this.Vh.naturalHeight}),this.Lh.width=t.Ti,this.Lh.height=t.Mi,i.drawImage(this.Vh,t.Gh,t.Xh,t.Ti,t.Mi,0,0,t.Ti,t.Mi),this.Yh(this.Lh))}Yh(t){this.Kh||(Zt(this.tooltip,t),this.Kh=t),this.In()}zh(){this.Kh&&(this.tooltip.removeChild(this.Kh),this.Kh=void 0,this.In())}Oh(){void 0!==this.Ih&&(this.Ih.removeEventListener(["addcue","removecue"],this.$h),this.Ih=void 0),this.Fh=void 0,this.zh(),this.qh=void 0}dispose(){this.Oh(),super.dispose()}constructor(t,i){super(t,i),this.Kh=void 0,this.Ih=void 0,this.Fh=void 0,this.Zh=t=>this.Bh(t),this.io=t=>this.Rh(t),this.$h=t=>this.Uh(),this.qh=void 0,this.showThumbnails=()=>{this.Kh&&this.Kh.hidden&&(this.Kh.hidden=!1,this.In())},this.hideThumbnails=()=>{!this.Kh||this.Kh.hidden||this.player().scrubbing()||(this.Kh.hidden=!0,this.In())},this.on(this.player().textTracks(),"addtrack",this.Zh),this.on(this.player().textTracks(),"removetrack",this.io),Dt.Ks&&(this.on(t,"seeking",this.showThumbnails),this.on(t,"seeked",this.hideThumbnails))}}),f();var xu=Fo.getComponent("VolumeLevel");Fo.registerComponent("VolumeLevel",class extends xu{createEl(){const t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-volume-level "+super.buildCSSClass()}}),f(),f();var Cu=Fo.getComponent("Component"),Su=class extends Cu{createEl(){const t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-menu-container "+super.buildCSSClass()}};Su.prototype.h=z({},Su.prototype.h,{children:[]}),Fo.registerComponent("controlBarMenuContainer",Su);var ju=Fo.getComponent("Player"),Tu=class extends ju{dispose(){const t=this.el(),i=this.contentEl(),s=t.parentNode,e=t.nextSibling;super.dispose(),Yt(i),this.Si&&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)}};Tu.prototype.h=z({},ju.prototype.h,{children:["bigPlayButton","AdControlPanel","TopControlBar","mediaLoader","upNextContainer","posterImage","chromecastOverlay","upcomingAdNotificationText","controlBarMenuContainer","controlBar","textTrackDisplay","loadingSpinner","errorDisplay","textTrackSettings","xrCompass"]}),Fo.registerComponent("Player",Tu),f(),f();var Mu=Fo.getComponent("Player"),Au=Mu.prototype.ns;Mu.prototype.ns=function(t){if(!(this.H&&this.H.Rs&&this.H.Rs()))return Au.call(this,t)};var Pu=Mu.prototype.createEl;function Nu(t,i,e,n){const r=z({controls:!0,playbackRates:[.25,.5,1,1.25,1.5,2]},e);r.controlBar=z({progressControl:{keepTooltipsInside:!0}},r.controlBar);const h=r.techOrder||(r.techOrder=[]);-1===h.indexOf("THEOplayer")&&h.unshift("THEOplayer");(r.theoplayer||(r.theoplayer={})).player=t,e&&zt(e.language)&&(r.languages=z({},r.languages,{[xt]:e.language}),r.language=xt),i.setAttribute("data-vjs-player","");const o=i.getAttribute("style"),a=Fo(t.element,r,n);return a.ready(()=>{zo(a),function(t,i){if(i){if(i.ads){const s=i=>{const s="adbreakbegin"===i.type,e=i.adBreak.integration===M.so;Wo(t,s,e)};i.ads.addEventListener("adbreakbegin",s),i.ads.addEventListener("adbreakend",s)}if(i.uplynk){var s;const e=i=>{const s="adbreakbegin"===i.type;Wo(t,s,!1)};null==(s=i.uplynk)||s.ads.adBreaks.addEventListener("addadbreak",t=>{t.adBreak.addEventListener("adbreakbegin",e),t.adBreak.addEventListener("adbreakend",e)})}i.addEventListener("sourcechange",()=>{Wo(t,!1,!1)})}}(a,t),function(t){t.on("mouseleave",Go)}(a)}),i.removeAttribute("data-vjs-player"),o?i.setAttribute("style",o):i.removeAttribute("style"),pi.Zs.Ks&&(ei(i,"theo-mobile"),function(t){const i=s.outerHeight,e=s.outerWidth,n=i>e;n?(ri(t,"theo-mobile-landscape"),ei(t,"theo-mobile-portrait")):(ri(t,"theo-mobile-portrait"),ei(t,"theo-mobile-landscape"))}(i)),function(t){t.on("seeking",()=>{ii(t.el(),"vjs-ended")&&t.currentTime()!==t.duration()&&t.play()})}(a),a}Mu.prototype.createEl=function(){const t=Pu.call(this),i=Fo.createEl("div");for(i.className="theo-player-wrapper";t.firstChild;)i.appendChild(t.firstChild);return t.appendChild(i),this.S=i,t},f(),f(),f(),f();var Eu=Fo.getComponent("Button");var Bu="THEOPiPCloseButton";Fo.registerComponent(Bu,class extends Eu{buildCSSClass(){return"theo-close-button theo-pip-close"}handleClick(){this.no.eo()}constructor(t,i){if(super(t,i),this.no=void 0,this.controlText("Close Picture-in-Picture"),!function(t){return!!t&&Boolean(t.no)}(i))throw new m("Invalid Picture-in-picture options.");this.no=i.no}});var Iu=class extends Y{get ro(){return this.ho}get oo(){return this.t.ds()}ao(){this.t.wn(it.uo,this.co),this.lo||this.t.wn(it.do,this.fo),this.t.vo.on("languagechange",this.se)}po(){var t;return"theo-pip-"+(null!=(t=this.mo)?t:"bottom-right")}yo(t){const i=this.bo;i&&!this.oo&&(this.ko||this.wo(),this._o(),ei(i,"theo-pip"),ei(i,this.po()),this.ho=!0,this.xo=t,this.Co=!1,this.So(new Ei(si.PICTURE_IN_PICTURE)))}jo(t){const i=this.bo;i&&(this.To(),ri(i,"theo-pip"),ri(i,this.po()),this.ho=!1,this.Co=t,this.Mo=this.xo,this.xo=!1,this.So(new Ei(si.INLINE)))}wo(){if(!this.ko){const t=this.t.vo;t.addChild(Bu,{no:this});const i=h.createElement("div");i.className="theo-pip-overlay",this.Ao=h.createElement("div"),this.Ao.className="theo-pip-overlay-text",d(this.Ao,t.localize("Video playing in Picture-in-Picture mode")),i.appendChild(this.Ao),Zt(t.el(),i),this.Po=i,this.ko=!0}}No(){this.Eo&&!this.Bo&&this.t.Io&&(this.Fo=this.t.Io.Do(et,this.$o),this.Bo=!0)}Uo(){this.Fo&&this.t.Io&&(this.t.Io.Ro(this.Fo),this.Bo=!1)}_o(){const t=this.t.vo.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"}To(){const t=this.t.vo.contentEl();t.style.top="",t.style.bottom="",t.style.right="",t.style.left="",t.style.width="",t.style.height="",t.style.position=""}Oo(){ri(this.bo,"theo-pip"),this.ro&&this.mo&&ri(this.bo,"theo-pip-"+this.mo),this.Po&&(Yt(this.Po),this.Po=void 0)}kn(){this.Oo(),this.Uo(),this.Vo(),this.t.mn(it.uo,this.co),this.t.mn(it.do,this.fo),this.t.vo.off("languagechange",this.se),this.t=void 0}constructor(t,i,s){super(),this.Lo=void 0,this.mo=void 0,this.lo=void 0,this.t=void 0,this.bo=void 0,this.Ho=!1,this.ho=!1,this.Co=!1,this.xo=!1,this.ko=!1,this.eo=void 0,this.Bo=!1,this.Fo=void 0,this.Po=void 0,this.Ao=void 0,this.Mo=!1,this.Eo=void 0,this.co=()=>{this.Ho=!0,this.Eo&&!this.ro&&this.Fo&&this.Lo&&this.Fo.qo<=this.Lo&&this.yo(!1)},this.fo=()=>{this.lo||(this.Ho=!1,this.eo(),this.jo(!1))},this.se=()=>{if(this.Ao){const t=this.t.vo;d(this.Ao,t.localize("Video playing in Picture-in-Picture mode"))}},this.$o=t=>{!this.xo&&this.Eo&&(S(t)||(this.Lo&&t<=this.Lo||this.Mo?this.ho||this.Co||this.yo(!1):this.ho?this.jo(!1):this.Co=!1))},this.Lo=i.visibility,this.mo=i.position,this.lo=i.retainPresentationModeOnSourceChange,this.Eo=void 0!==this.Lo,this.t=t,this.bo=t.zo,this.eo=s,this.ao()}},Fu=class extends E{Wo(){const t=super.Wo();return t===si.INLINE&&this.Go.ro?si.PICTURE_IN_PICTURE:t}Xo(t){return t===si.PICTURE_IN_PICTURE||super.Xo(t)}Jo(t){this.Qo=this.Yo,t===si.FULLSCREEN||t===si.NATIVE_PICTURE_IN_PICTURE?this.Go.Uo():this.Go.No(),super.Jo(t)}Ko(t){super.Ko(t),t===si.PICTURE_IN_PICTURE?$(this.ta.Zo(t=>this.ia(t))):t===si.FULLSCREEN?this.Go.jo(!1):this.Go.jo(!0)}async ia(t){F(t),await Promise.all([this.sa(),this.ea.jo()]).catch(gi),F(t),this.Go.yo(!this.na),this.So(new Ei(this.Yo)),this.na=!1,this.ra=!1}_i(){this.ra||(this.Go.ro&&this.ha.ds?this.Jo(si.FULLSCREEN):this.Qo!==si.PICTURE_IN_PICTURE||this.ha.ds?super._i():(this.na=!0,this.Jo(si.PICTURE_IN_PICTURE)))}kn(){super.kn(),this.Go.kn(),this.oa.mn(it.uo,this.aa),this.oa=void 0}constructor(t,i,s,e){super(i,s),this.oa=void 0,this.Go=void 0,this.Qo=si.INLINE,this.na=!1,this.eo=()=>{this.Yo===si.PICTURE_IN_PICTURE&&this.Jo(si.INLINE)},this.ua=t=>{this.ra||(this.Yo!==si.PICTURE_IN_PICTURE||this.Go.ro?this.Yo!==si.PICTURE_IN_PICTURE&&this.Go.ro&&(this.na=!0,this.Jo(si.PICTURE_IN_PICTURE)):this.Jo(si.INLINE))},this.aa=()=>{this.Wo()!==si.PICTURE_IN_PICTURE&&this.Wo()!==si.INLINE||this.Go.No(),this.oa.mn(it.uo,this.aa)},this.oa=t,this.Go=new Iu(t,e.pip,this.eo),this.Go.wn(Pi.MODE_CHANGE,this.ua),this.oa.wn(it.uo,this.aa)}};f();var Du=class extends Y{get ca(){return Mi.la(this.vo.el())||this.vo.supportsFullScreen()}get ds(){return this.vo.isFullscreen()||this.da}yo(){this.vo.requestFullscreen()}jo(){this.vo.exitFullscreen(),this.fa.jo()}kn(){this.Vo(),this.vo.off("fullscreenchange",this.va),this.fa.mn(ai.pa,this.va),this.fa.mn(ai.ma,this.Us),this.vo.isFullWindow&&this.vo.exitFullscreen()}constructor(t,i){super(),this.vo=void 0,this.fa=void 0,this.Vs=!1,this.da=!1,this.ga=!1,this.va=()=>{if(this.ga)return;const t=this.Vs,i=this.ds;t!==i&&(this.Vs=i,this.So(new Ci))},this.ya=()=>{this.da=this.fa.ds,this.va()},this.ba=()=>{this.ga||(this.vo.isFullWindow&&this.vo.supportsFullScreen()||this.da&&!this.vo.supportsFullScreen())&&(this.ga=!0,this.vo.exitFullscreen(),this.vo.requestFullscreen(),this.ga=!1,this.va())},this.vo=t,this.fa=i,this.vo.on("fullscreenchange",this.va),this.fa.wn(ai.pa,this.ya),this.fa.wn(ai.ka,this.ba),this.fa.wn(ai.ma,this.Us),this.va()}};function $u(t){return class extends t{get Io(){return this.wa}ds(){return this._a.Wo()===si.FULLSCREEN}xa(){return function(t,i){const s=w.create(t),e=i.vo;return at(s,{get controls(){return e.controls()},set controls(t){e.controls(vt(t))},get presentation(){return i._a.Ca},get presentationMode(){return i._a.Wo()},set presentationMode(t){const s=hi(t);s&&i._a.Jo(s)},get ui(){return e},get visibility(){return i.Io.Ca}})}(this.Sa,this)}kn(){super.kn(),this._a.kn(),this.ja.kn(),this.vo.dispose(),this.wa.kn()}Ta(t){this.vo.src(""),super.Ta(t)}constructor(t,i,s){super(i,s),this.zo=void 0,this.vo=void 0,this.Sa=void 0,this.wa=void 0,this._a=void 0,this.ja=void 0,this.zo=t,this.wa=new rt(t),this.Sa=super.xa(),w.defineProperty(this.Sa,"constructor",{value:lt}),this.vo=Nu(this.Sa,this.zo,s.ui),this.ja=new Du(this.vo,this.Ma),this._a=new Fu(this,this.ja,this.Pa.Aa(),s),this._a.wn(Pi.MODE_CHANGE,this.Us)}}}function Uu(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(Rt(t)&&!S(t))return Si(t,0,1)}(t.visibility),t.retainPresentationModeOnSourceChange=vt(t.retainPresentationModeOnSourceChange),t}f(),f();var Ru=wi(()=>{let t=$u(ut());return t=function(t){let i=t;for(const t of Bi)i=t(i);return i}(t),t});function Ou(t,i){const s=function(t){const i=ni(t);return i.ui=i.ui||{},void 0!==(null==t?void 0:t.width)&&void 0===i.ui.width&&(i.ui.width=t.width),void 0!==(null==t?void 0:t.height)&&void 0===i.ui.height&&(i.ui.height=t.height),void 0!==(null==t?void 0:t.fluid)&&void 0===i.ui.fluid&&(i.ui.fluid=t.fluid),i.pip=Uu(i.pip),i}(i),e=h.createElement("div");ui(e),t.appendChild(e);const n=new(Ru())(t,e,s);n.Na=n;let r=n.Ca;return n.Ea(),n.Ba(ot),w.defineProperty(r,"constructor",{value:Ou}),r=ht(r),Ht(n),function(t){for(const i of Fi)i(t)}(n),r}f(),f(),f();var Vu="theo-cast-",Lu=Fo.getComponent("Button"),Hu=class extends(Ho(Lu)){get Ia(){throw new m("Fa")}get Da(){return this.h.Da}get $a(){return this.h.$a}buildCSSClass(){return Vu+"button theo-"+this.$a+"-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=Vu+"svg-container",r.innerHTML=this.Da,e.appendChild(n),e.appendChild(r),e}handleClick(t){var i;if(super.handleClick(t),this.Ua===ci.AVAILABLE)null==(i=this.Ia)||i.start();else if(this.Ua===ci.CONNECTED||this.Ua===ci.CONNECTING){var s;null==(s=this.Ia)||s.stop()}}Ra(t){ri(this.bo,"theo-"+this.$a+"-"+this.Ua),this.Ua=t,ei(this.bo,"theo-"+this.$a+"-"+this.Ua),this.se()}se(){this.Oa(this.Ua),this.De.Fe=this.controlText()}Oa(t){t===ci.CONNECTED?this.controlText("Stop Casting"):t===ci.AVAILABLE?this.controlText("Start Casting"):t===ci.CONNECTING?this.controlText("Connecting"):this.controlText("Unavailable")}constructor(t,i){var s;super(t,i),this.bo=void 0,this.Ua=void 0,this.De=void 0,this.Va=void 0,this.bo=t.el(),this.Ua=ci.UNAVAILABLE,this.controlText("Unavailable"),this.De=new da(this,this.controlText()),null==(s=this.Ia)||s.addEventListener("statechange",t=>{const i=t;this.Ra(i.state)}),pi.Zs.Ke&&(this.Va=new Zo(this.el())),this.Ra(this.Ia?this.Ia.state:ci.UNAVAILABLE),this.on(t,"languagechange",this.se)}},qu=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-'+qu+'">\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-'+qu+')">\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 qu++,t}Fo.registerComponent("chromecastButton",class extends Hu{get Ia(){var t;return null==(t=this.xs.cast)?void 0:t.chromecast}constructor(t,i){super(t,z({},i,{$a:"chromecast",Da:zu()}))}}),f();var Wu="theo-chromecast-",Gu=Fo.getComponent("Component"),Xu=class t extends(Ho(Gu)){buildCSSClass(){return Wu+"overlay "+super.buildCSSClass()}createEl(){const i=super.createEl();ei(i,Wu+"overlay");const s=Fo.createEl("div",{className:Wu+"status-icon",innerHTML:t.ICON_SVG}),e=Fo.createEl("div",{className:Wu+"status-info"});d(e,"Playing on");const n=Fo.createEl("div",{className:Wu+"status-title"}),r=Fo.createEl("div",{className:Wu+"status"});return this._r=n,r.appendChild(s),r.appendChild(e),r.appendChild(n),i.appendChild(r),i}dispose(){var t;null==(t=this.La)||t.removeEventListener("statechange",this.update),this.La=void 0,this.xs.removeEventListener("play",this.update),super.dispose()}constructor(t,i){var s,e;super(t,i),this.La=void 0,this.update=()=>{this.La?(this._r&&d(this._r,this.La.receiverName||""),this.La.state===ci.CONNECTED?this.show():this.hide()):this.hide()},this.La=null==(s=this.xs.cast)?void 0:s.chromecast,null==(e=this.La)||e.addEventListener("statechange",this.update),this.xs.addEventListener("play",this.update),this.update()}};Xu.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>',Fo.registerComponent("chromecastOverlay",Xu),f(),f();Fo.registerComponent("airplayButton",class extends Hu{dispose(){var t,i;null==(t=this.xs.ads)||t.removeEventListener("adbreakbegin",this.Ha),null==(i=this.xs.ads)||i.removeEventListener("adbreakend",this.qa),this.xs.removeEventListener("currentsourcechange",this.qa),super.dispose()}get Ia(){var t;return null==(t=this.xs.cast)?void 0:t.airplay}constructor(t,i){var s,e;super(t,z({},i,{$a:"airplay",Da:'\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.qa=()=>{this.enable()},this.Ha=t=>{"theoads"!==t.adBreak.integration&&"google-dai"!==t.adBreak.integration&&this.disable()},null==(s=this.xs.ads)||s.addEventListener("adbreakbegin",this.Ha),null==(e=this.xs.ads)||e.addEventListener("adbreakend",this.qa),this.xs.addEventListener("currentsourcechange",this.qa)}}),f(),f(),f();var Ju=Fo.getComponent("Button"),Qu=class extends(Ho(Ju)){buildCSSClass(){return"theo-vr-button theo-controlbar-button "+super.buildCSSClass()}handleClick(){this.xs.vr.stereo=!this.xs.vr.stereo,this.se()}Sn(){const t=this.xs.vr;t&&t.state!==Vt.Os?(this.show(),t.canPresentVR?this.enable():this.disable()):this.hide(),this.se()}se(){const t=this.xs.vr;t&&t.state!==Vt.Os&&(t.stereo?this.controlText("Stop watching in VR"):t.canPresentVR?this.controlText("Watch in VR"):this.controlText("No VR capable device found"),this.za.Fe=this.controlText())}dispose(){var t;null==(t=this.xs.vr)||t.removeEventListener(["statechange","stereochange"],this.Wa),super.dispose()}constructor(t,i){var s;super(t,i),this.za=void 0,this.Va=void 0,this.Wa=()=>this.Sn(),this.controlText("Watch in VR"),this.za=new da(this,this.controlText()),null==(s=this.xs.vr)||s.addEventListener(["statechange","stereochange"],this.Wa),this.Sn(),pi.Zs.Ke&&(this.Va=new Zo(this.el())),this.on(t,"languagechange",this.se)}};Fo.registerComponent("vrButton",Qu),f();var Yu=Fo.getComponent("Component"),Ku=class extends Yu{createEl(){const t=super.createEl("div",{className:this.buildCSSClass()}),i=Fo.createEl("div",{className:"theo-360-fov"});return t.appendChild(i),this.Ga=i,t}buildCSSClass(){return"theo-360-compass "+super.buildCSSClass()}Sn(){this.xs.vr.state===Vt.Os?this.hide():this.show()}Xa(){const t=-this.xs.vr.direction.yaw+40;this.Ga.style[ki("transform")]="scale(0.875) rotate("+t+"deg) skew("+"-10deg)"}dispose(){this.xs.vr.removeEventListener("statechange",this.Wa),this.xs.vr.removeEventListener("directionchange",this.Ja),super.dispose()}constructor(t,i,s){super(t,i),this.xs=void 0,this.Wa=()=>this.Sn(),this.Ja=()=>this.Xa(),this.xs=s,this.xs.vr.addEventListener("statechange",this.Wa),this.xs.vr.addEventListener("directionchange",this.Ja),this.Sn(),this.Xa()}};f();var Zu=Fo.getComponent("Component"),tc=class extends Zu{Qa(){this.xs.vr.state===Vt.Ya?this.Ka():this.Za()}Ka(){if(this.tu)return;this.tu=!0;const t=this.xs.element;this.iu=t.style.zIndex||"",t.style.zIndex="2147483647",this.su=this.player().isFullscreen(),this.player().requestFullscreen()}Za(){if(!this.tu)return;this.tu=!1;this.xs.element.style.zIndex=this.iu,this.su?this.player().requestFullscreen():this.player().exitFullscreen()}dispose(){this.Za(),this.xs.vr.removeEventListener("statechange",this.eu),super.dispose()}constructor(t,i,s){super(t,i),this.xs=void 0,this.tu=!1,this.su=!1,this.iu="",this.eu=()=>this.Qa(),this.xs=s,this.xs.vr.addEventListener("statechange",this.eu),this.Qa()}};Di(function(t){const i=t.Ca;if(!i.vr)return;const s=t.vo,e=new Ku(s,{},i);if(t.wn(it.do,()=>{var i;s.removeChild(e);const n=null==(i=t.nu())?void 0:i.vr;void 0===n||n.nativeVR||s.addChild(e)}),Dt.ru){const t=new tc(s,{},i);s.addChild(t)}}),f(),f(),f();var ic=class extends Z{constructor(){super("relatedchange")}},sc=["relatedchange"],ec=class extends Y{get Ca(){return this.hu||(this.hu=function(t){let i;const s={get sources(){return t.ou},set sources(i){t.ou=i},addEventListener(t,s){i.wn(t,s)},removeEventListener(t,s){i.mn(t,s)}};return i=new P(sc,!0,s),i.au(t),s}(this)),this.hu}get ou(){return this.uu}set ou(t){this.uu=function(t){return t.filter(t=>t&&(Xt(t.link)||dt(t,["source"])))}(t),t.length>this.uu.length&&console.warn("One or more of the configured related content sources are invalid. Check if they have a source or a link."),this.So(new ic)}kn(){this.Vo(),this.uu=[]}constructor(...t){super(...t),this.hu=void 0,this.uu=[]}};Ot(function(t){return class extends t{xa(){const t=this.cu;return at(super.xa(),{get related(){return t.Ca}})}kn(){this.cu.kn(),super.kn()}constructor(t,i){super(t,i),this.cu=void 0,this.cu=new ec}}},$t.lu),f(),f();var nc=Fo.getComponent("Button"),rc=class extends nc{buildCSSClass(){return"vjs-icon-view-grid theo-related-button "+super.buildCSSClass()}handleClick(){this.fu.du?this.fu.we():this.fu.be()}se(){this.De.Fe=this.controlText()}dispose(){this.player().topControlBar.removeChild(this),super.dispose()}constructor(t,i,s){super(t,s),this.bo=void 0,this.fu=void 0,this.De=void 0,this.bo=t.el(),this.fu=i,this.player().topControlBar.addChild(this),this.hide(),this.controlText(this.localize("Related content")),this.De=new da(this,this.controlText()),this.on(t,"languagechange",this.se)}};f(),f();var hc=Fo.getComponent("Button"),oc=class extends hc{buildCSSClass(){return"theo-secondary-background theo-close-button"}handleClick(){this.vu.hide()}constructor(t,i){super(t),this.vu=void 0,this.vu=i}},ac=(()=>{const 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 uc(t,i,s){const e=ac.cloneNode(!0),n=e.querySelector(".theo-related-grid-tile-content");dt(s,["source"])?(n.style.cursor="pointer",n.addEventListener("click",()=>{t.source=s.source,i.we()})):Xt(s.link)&&n.setAttribute("href",s.link);const r=e.querySelector(".theo-related-grid-tile-image");r.style.backgroundImage='url("'+J(s.image)+'")',r.removeAttribute("id");const h=e.querySelector(".theo-related-grid-tile-title");s.title?(d(h,s.title),h.removeAttribute("id")):Yt(h);const o=e.querySelector(".theo-related-grid-tile-duration");return s.duration?(d(o,s.duration),o.removeAttribute("id")):Yt(o),e}var cc=[15,12,9,8,6,4,3,2,1];var lc=class{get pu(){return"theo-"+this.mu+"-item-grid"}gu(){this.yu.focus()}bu(t){this.ku(),function(t){if(t.length)for(const i of cc)if(t.length>=i){t.length=i;break}}(t),this.wu(t.length);for(const i of t){const t=uc(this._u.Ca,this.xu,i);this.Cu.appendChild(t)}}ku(){this.Cu.innerHTML=""}Su(){const t=h.createElement("div");t.className="theo-overlay-panel";const i=h.createElement("div");return i.className="theo-related-grid",this.ju.className="theo-related",this.yu.controlText("Close Related Content"),this.Tu.appendChild(this.ju),this.ju.appendChild(t),t.appendChild(this.yu.el()),t.appendChild(i),i}wu(t){ri(this.Cu,this.pu),this.mu=t,ei(this.Cu,this.pu)}kn(){Yt(this.ju),this.Mu.kn(),this.Au.kn(),this.yu.dispose(),this._u=void 0}constructor(t,i,s,e,n){this._u=void 0,this.Pu=void 0,this.xu=void 0,this.Tu=void 0,this.mu=void 0,this.yu=void 0,this.Cu=void 0,this.ju=void 0,this.Mu=void 0,this.Au=void 0,this.Nu=void 0,this._u=t,this.Pu=i,this.xu=s,this.Tu=e,this.mu=12,this.Nu=t=>{this.Cu.style.width=t.width+"px"},this.ju=h.createElement("div"),this.yu=new oc(this.Pu,{hide:()=>{this.xu.we()}}),this.Cu=this.Su(),this.Au=new dc(n),this.Au.wn(mi.yn,this.Nu),this.Mu=new Pt(this.Cu,this.Au),this.wu(12)}},dc=class extends Y{get Eu(){return this.Bu||0}get Iu(){return this.Fu.Iu}kn(){this.Vo(),this.Fu.mn(mi.yn,this.Du)}constructor(t){super(),this.Fu=void 0,this.Bu=void 0,this.Du=void 0,this.Fu=t,this.Du=t=>{let i=t.width;if(9*(t.width/16)>t.height){i=16*(t.height/9)}this.Bu=i,this.So(new yi(this.Eu,t.height))},this.Fu.wn(mi.yn,this.Du)}};f();var fc=class extends Z{constructor(){super("show")}};f();var vc=class extends Z{constructor(){super("hide")}},pc="theo-related-available",mc="theo-related-showing",gc=[...sc,"show","hide"],yc=class extends Y{get Ca(){return this.hu||(this.hu=function(t){let i;const s={get sources(){return t.ou},set sources(i){t.ou=i},get showing(){return t.du},show(){t.be()},hide(){t.we()},addEventListener(t,s){i.wn(t,s)},removeEventListener(t,s){i.mn(t,s)}};return i=new P(gc,!0,s),i.au(t),s}(this)),this.hu}get ou(){return this.$u.ou}set ou(t){this.$u.ou=t}get du(){return this.Uu}be(){const t=this.Uu;this.Uu=!0,this.Ru(mc),this.Ou.gu(),this.Pu.paused()?this.Vu=!0:this.Pu.pause(),t!==this.Uu&&this.So(new fc)}we(){const t=this.Uu;this.Uu=!1,this.Lu(mc),this.Hu.focus(),this.Vu||this.Pu.play(),this.Vu=!1,t!==this.Uu&&this.So(new vc)}Ru(t){this.Pu.el().classList.add(t)}Lu(t){this.Pu.el().classList.remove(t)}kn(){this.Vo(),this.Ou.kn()}constructor(t,i,s,e){super(),this.$u=void 0,this.Hu=void 0,this.hu=void 0,this.Pu=void 0,this.Ou=void 0,this.Uu=!1,this.Vu=!1,this.qu=t=>{const i=this.ou;this.Ou.bu(i),i.length?(this.Ru(pc),this.Hu.show()):(this.Lu(pc),this.Hu.hide()),this.So(t)},this.$u=i,this.$u.wn("relatedchange",this.qu),this.Pu=s,this.Ou=new lc(t,this.Pu,this,s.contentEl(),e),this.Hu=new rc(s,this,{})}};Ii(function(t){return class extends t{xa(){const t=this.zu;return at(super.xa(),{get related(){return t.Ca}})}kn(){this.zu.kn(),super.kn()}constructor(t,i,s){super(t,i,s),this.zu=void 0,this.zu=new yc(this,this.cu,this.vo,this.Wu)}}}),f(),f(),f();var bc=Fo.getComponent("Button"),kc=class extends bc{buildCSSClass(){return"vjs-icon-share theo-social-button "+super.buildCSSClass()}handleClick(){this.Gu.showing?this.Gu.hide():this.Gu.show()}se(){this.De.Fe=this.controlText()}dispose(){this.player().topControlBar.removeChild(this),super.dispose()}constructor(t,i,s){super(t,s),this.bo=void 0,this.Gu=void 0,this.De=void 0,this.bo=t.el(),this.Gu=i,this.player().topControlBar.addChild(this),this.hide(),this.controlText("Share Video"),this.De=new da(this,this.controlText()),this.on(t,"languagechange",this.se)}};function wc(t,i,s){switch(i){case"iconurl":return function(t,i){const s=h.createElement("a");var e;s.className="theo-social-iconurl",s.title=null!=(e=t.label)?e:"",s.target="Xu",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){const i=h.createElement("div");if(i.className="theo-social-text",t.label){const s=h.createElement("h5");s.className="theo-primary-background theo-social-label",d(s,t.label),i.appendChild(s)}const s=h.createElement("p");var e;return s.className="theo-social-content-container theo-tertiary-background",s.tabIndex=0,d(s,null!=(e=t.text)?e:""),i.appendChild(s),i}(t);case"texturl":return function(t,i){const s=h.createElement("div");if(s.className="theo-social-texturl",t.label){const i=h.createElement("h5");i.className="theo-primary-background theo-social-label",d(i,t.label),s.appendChild(i)}const e=h.createElement("div");e.className="theo-social-content-container theo-tertiary-background";const n=h.createElement("a");return n.target="Xu",n.href=i,d(n,i),e.appendChild(n),s.appendChild(e),s}(t,s)}}f();var _c="<URL>";var xc=class{get xe(){return this.ju}Ju(t){this.ku();for(const i of t)this.Qu(i)}gu(){this.yu.focus()}Qu(t){const i=function(t,i){return t.src?G(t.src,_c)?t.src.replace(_c,i):t.src:i}(t,this.xu.Yu),s=function(t){if(t)return t.icon?"iconurl":t.text?"text":"texturl"}(t),e=wc(t,s,i);e&&("iconurl"===s?this.Ku.appendChild(e):this.Zu.appendChild(e))}ku(){this.Ku.innerHTML="",this.Zu.innerHTML=""}kn(){Yt(this.ju),this.tc.kn()}constructor(t,i,s,e){this.oa=void 0,this.xu=void 0,this.Tu=void 0,this.sc=void 0,this.yu=void 0,this.Ou=void 0,this.ju=void 0,this.Ku=void 0,this.Zu=void 0,this.tc=void 0,this.oa=t,this.xu=i,this.Tu=s,this.sc=e;const n=h.createElement("div");n.className="theo-overlay-panel",this.yu=new oc(this.oa,this.xu.Ca),this.yu.controlText("Close Share"),this.Ou=h.createElement("div"),this.Ou.className="theo-social-container",this.ju=h.createElement("div"),this.ju.className="theo-social",this.Ku=h.createElement("div"),this.Ku.className="theo-social-icon-container",this.Zu=h.createElement("div"),this.Zu.className="theo-social-text-container",this.Tu.appendChild(this.ju),this.ju.appendChild(n),this.Ou.appendChild(this.Ku),this.Ou.appendChild(this.Zu),n.appendChild(this.yu.el()),n.appendChild(this.Ou),this.tc=new Pt(this.ju,this.sc)}},Cc="theo-social-available",Sc="theo-social-showing",jc=class{get Ca(){return this.hu}get du(){return this.Uu}get ec(){return this.nc}set ec(t){this.nc=t,this.Ou.Ju(t),t.length?(this.Ru(Cc),this.Hu.show()):(this.Lu(Cc),this.Hu.hide())}get Yu(){return this.rc||H()}set Yu(t){this.rc=t}be(){this.Uu=!0,this.Ru(Sc),this.Ou.gu(),this.hc.paused()?this.Vu=!0:this.hc.pause()}we(){this.Uu=!1,this.Lu(Sc),this.Hu.focus(),this.Vu||this.hc.play(),this.Vu=!1}Ru(t){this.hc.el().classList.add(t)}Lu(t){this.hc.el().classList.remove(t)}kn(){this.Hu.dispose(),this.Ou.kn()}constructor(t,i){this.Hu=void 0,this.hu=void 0,this.hc=void 0,this.Ou=void 0,this.Uu=!1,this.nc=[],this.rc=void 0,this.Vu=!1,this.hu=function(t){return{get showing(){return t.du},get items(){return t.ec},set items(i){t.ec=i},get url(){return t.Yu},set url(i){t.Yu=i},show(){t.be()},hide(){t.we()}}}(this),this.hc=t,this.Ou=new xc(this.hc,this,t.contentEl(),i),this.Hu=new kc(t,this.hu,{})}};Ii(function(t){return class extends t{xa(){const t=this.Gu;return at(super.xa(),{get social(){return t.Ca}})}constructor(t,i,s){super(t,i,s),this.Gu=void 0,this.Gu=new jc(this.vo,this.Wu)}}}),f(),f();var Tc=Fo.getComponent("Component"),Mc=class extends Tc{createEl(){const t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-upnext-container "+super.buildCSSClass()}};Mc.prototype.h=z({},Mc.prototype.h,{children:[]}),Fo.registerComponent("upNextContainer",Mc),f(),f();var Ac="theo-upnext-bar-",Pc=Fo.getComponent("Component"),Nc=class extends Pc{get du(){return this.Uu}set du(t){this.Uu=t,this.oc&&(this.oc.tabIndex=t?0:-1)}get ac(){return this.uc}set ac(t){this.uc=t}Ta(t){this.ku(),this.cc(t)}cc(t){if(t&&t.link&&t.image){const i=h.createElement("div");ei(i,Ac+"content"),i.onclick=()=>{this.lc.next()},i.onkeypress=t=>{13===t.which&&this.lc.next()};const s=h.createElement("div");if(s.style.backgroundImage='url("'+J(t.image)+'")',ei(s,Ac+"image"),i.appendChild(s),t.duration){const i=h.createElement("span");ei(i,Ac+"duration"),i.innerHTML=""+t.duration,s.appendChild(i)}const e=h.createElement("div");ei(e,Ac+"text");const n=h.createElement("div");if(ei(n,Ac+"upnext"),d(n,this.localize("Up Next")),e.appendChild(n),t.title){const i=h.createElement("div");ei(i,Ac+"title"),d(i,t.title),e.appendChild(i)}i.appendChild(e),this.oc=i,this.dc=n,this.el().appendChild(this.oc)}}ku(){this.el().innerHTML="",this.oc=void 0,this.dc=void 0}se(){this.dc&&d(this.dc,this.localize("Up Next"))}createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-upnext-bar "+super.buildCSSClass()}dispose(){this.tc.kn(),super.dispose()}constructor(t,i,s,e){super(t,s),this.lc=void 0,this.tc=void 0,this.Uu=void 0,this.uc=void 0,this.oc=void 0,this.dc=void 0,this.lc=i,this.tc=new Pt(this.el(),e),this.Uu=!1,this.uc=10,this.on(t,"languagechange",this.se)}};f();var Ec="theo-upnext-panel-",Bc=bu,Ic=Fo.getComponent("Component"),Fc=class extends Ic{get du(){return this.Uu}set du(t){this.Uu=t}get fc(){return this.vc}set fc(t){this.vc=t}get mc(){return this.gc}set mc(t){this.gc=t}Ta(t){this.ku(),this.yc(t)}yc(t){if(t&&t.link&&t.image){const i=h.createElement("div");i.className=Ec+"content";const s=h.createElement("div");s.style.backgroundImage='url("'+J(t.image)+'")',s.className=Ec+"image",i.appendChild(s);const e=h.createElement("div");e.className=Ec+"text";const n=h.createElement("div");if(n.className=Ec+"upnext",d(n,this.localize("Up Next")),e.appendChild(n),t.title){const i=h.createElement("div");i.className=Ec+"title",d(i,t.title),e.appendChild(i)}i.appendChild(e),this.bc=h.createElement("div"),this.bc.className=Ec+"autoplay",this.bc.innerHTML=ku;const r=this.bc.querySelector("svg");r.onclick=()=>{this.lc.next()},r.tabIndex=0,r.onkeypress=t=>{13===t.which&&this.lc.next()},this.kc=n,this.wc=this.bc.querySelector("."+Bc),i.appendChild(this.bc),this.el().appendChild(i)}}get _c(){return this.xc}set _c(t){this.xc=t,this.wc.style.strokeDashoffset=""+_.round(1e5*t)/1e5}ku(){this.el().innerHTML="",this.kc=void 0,this.wc=void 0}se(){this.kc&&d(this.kc,this.localize("Up Next"))}createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-upnext-panel "+super.buildCSSClass()}dispose(){this.tc.kn(),super.dispose()}constructor(t,i,s,e){super(t,s),this.lc=void 0,this.tc=void 0,this.kc=void 0,this.bc=void 0,this.wc=void 0,this.xc=0,this.Uu=void 0,this.vc=void 0,this.gc=void 0,this.lc=i,this.tc=new Pt(this.el(),e),this.Uu=!1,this.vc=10,this.gc=!0,this.on(t,"languagechange",this.se)}},Dc="theo-upnext-panel-showing",$c="theo-upnext-bar-showing",Uc=2*_.PI*73,Rc=class t{get Ca(){return this.hu}get Cc(){return this.Sc}get jc(){return this.Tc}get Mc(){return this.Ac}set Mc(t){this.Ac=t,this.Ou.Ta(t),this.Pc.Ta(t),this.hc.off("timeupdate",this.Nc),this.hc.off("ended",this.Ec),t&&(this.hc.on("timeupdate",this.Nc),this.hc.on("ended",this.Ec))}Bc(){this.Ou.fc?this.Ic=mt(this.Ou.fc):0===this.Ou.fc?this.Ic=0:this.Ic=10,0!==this.Ic?(isFinite(this.Ic)&&(this.Fc=!0),this.Ou.du=!0,this.Ru(Dc),this.Fc&&(this.Ou._c=Uc-Uc/this.Ic,this.Dc=v(this.$c,1e3))):this.Uc()}Rc(){this.Ou.du=!1,this.Lu(Dc),this.Fc&&(p(this.Dc),this.Oc=1,this.Ou._c=Uc)}Vc(){this.Pc.du=!0,this.Ru($c)}Lc(){this.Pc.du=!1,this.Lu($c)}Uc(){p(this.Dc),this.Mc&&(s.location.href=this.Mc.link)}Ru(t){this.hc.el().classList.add(t)}Lu(t){this.hc.el().classList.remove(t)}Hc(t,i){const s=t>=i&&!(this.qc&&this.qc.zc);this.Pc.du&&!s?this.Lc():!this.Pc.du&&s&&this.Vc()}Wc(t,i){this.Ou.du&&t<i&&!this.hc.ended()&&this.Rc()}static Gc(t,i){const s=mt(t);if(!S(s))return i-s;const e=(""+t).match(/^([1-9]?\d|100)%$/);if(e){return i*(1-x(e[1],10)/100)}}kn(){this.Dc&&p(this.Dc),this.hc.getChild("upNextContainer").removeChild(this.Ou),this.hc.getChild("upNextContainer").removeChild(this.Pc),this.Ou.dispose(),this.Pc.dispose()}constructor(i,s,e){this.Pc=void 0,this.Ou=void 0,this.hu=void 0,this.Sc=void 0,this.Tc=void 0,this.hc=void 0,this.Ac=void 0,this.Ic=10,this.Oc=1,this.Dc=void 0,this.Fc=!0,this.qc=void 0,this.$c=()=>{this.Oc!==this.Ic?(this.Ou._c-=Uc/this.Ic,this.Oc+=1):this.Uc()},this.Ec=()=>{this.Ou.du||this.Bc()},this.Nc=()=>{const i=this.hc.currentTime(),s=this.hc.duration(),e=s?t.Gc(this.Pc.ac,s):void 0;void 0!==e&&this.Hc(i,e),this.Ou.mc&&this.Wc(i,s)},this.hu=function(t){return{get source(){return t.Mc},set source(i){t.Mc=i},get bar(){return t.Cc},get panel(){return t.jc},next(){t.Uc()}}}(this),this.Pc=new Nc(i,this.hu,{},s),this.Ou=new Fc(i,this.hu,{},s),this.Sc=function(t,i){return{get showing(){return i.du},get offset(){return i.ac},set offset(t){i.ac=t},show(){t.Vc()},hide(){t.Lc()}}}(this,this.Pc),this.Tc=function(t,i){return{get showing(){return i.du},get countdownDuration(){return i.fc},set countdownDuration(t){i.fc=t},get showUpNextPanel(){return i.mc},set showUpNextPanel(t){i.mc=t},show(){t.Bc()},hide(){t.Rc()}}}(this,this.Ou),this.hc=i,this.qc=e,i.getChild("upNextContainer").addChild(this.Pc,{}),i.getChild("upNextContainer").addChild(this.Ou,{})}};Ii(function(t){return class extends t{xa(){const t=this.Xc;return at(super.xa(),{get upnext(){return t.Ca}})}kn(){this.Xc.kn(),super.kn()}constructor(t,i,s){super(t,i,s),this.Xc=void 0,this.Xc=new Rc(this.vo,this.Wu,this.Jc)}}}),f(),f();var Oc=Fo.getComponent("Component"),Vc=class extends Oc{createEl(){const 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);const n=h.createElement("div");return n.className="theo-context-version",d(n,"Powered by THEOplayer 11.2.0"),s.appendChild(n),s.href="https://www.theoplayer.com/player-referral",s.target="Xu",t.appendChild(i),t}Qc(t){const i=t;i.preventDefault(),this.show(),this.el().style.left="0",this.el().style.top="0";const s=this.player().contentEl(),e=s.getClientRects(),n=e.length>0?e[0]:void 0,r=i.clientX-s.getBoundingClientRect().left,h=C(getComputedStyle(this.el()).fontSize);K(this.el(),r,n,h);const o=i.clientY-s.getBoundingClientRect().top;tt(this.el(),o,n,h),this.Yc()}Kc(){this.hide(),this.clearTimeout(this.Zc)}Yc(){this.Zc=this.setTimeout(this.Kc,4e3)}tl(){this.clearTimeout(this.Zc)}dispose(){this.Kc(),this.off(this.player(),"contextmenu",this.Qc),this.el().removeEventListener("mousedown",Lc,!0),this.off(h,"mousedown",this.Kc),this.off("mouseout",this.Yc),this.off("mouseover",this.tl),super.dispose()}constructor(t,i){super(t,i),this.Zc=0,this.on(this.player(),"contextmenu",this.Qc),this.el().addEventListener("mousedown",Lc,!0),this.on(h,"mousedown",this.Kc),this.on("mouseout",this.Yc),this.on("mouseover",this.tl),this.Kc()}};function Lc(t){t.stopPropagation()}Di(function(t){const i=new Vc(t.vo,{});t.vo.addChild(i),t.vo.on("dispose",()=>{t.vo.removeChild(i),i.dispose()})}),f(),f(),f(),f();var Hc={Default:"","Monospaced Serif":D.il,"Proportional Serif":D.sl,"Monospaced Sans-Serif":D.nl,"Proportional Sans-Serif":D.rl},qc={White:"#ffffff",Yellow:"#ffff00",Green:"#00ff00",Cyan:"#00ffff",Blue:"#0000ff",Magenta:"#ff00ff",Red:"#ff0000",Black:"#000000"},zc=[50,75,100,150,200];function Wc(t){return{label:t+"%",value:t}}function Gc(t){return w.keys(t).map(i=>({label:i,value:t[i]}))}zc.map(function(t){return{label:t+"%",value:t/100+"em"}});var Xc=zc.map(function(t){return{label:t+"%",value:t+"%"}}),Jc=[25,50,75,100].map(Wc),Qc=[0,25,50,75,100].map(Wc),Yc=Gc(qc),Kc=Gc(Hc),Zc=Gc({None:"none","Drop Shadow":"dropshadow",Raised:"raised",Depressed:"depressed",Uniform:"uniform"}),tl=100,il="#000000",sl="#FFFFFF",el="#000000";f();var nl=class extends Ka{hl(){const t=this.Vr.localize(this.ol);d(this.al.subMenu.menuHeader.el(),t),this.Or=h.createElement("span"),this.Or.className="theo-settings-control-menu-item-title",d(this.Or,t);const i=h.createElement("span");return i.className="theo-primary-color theo-settings-control-menu-item-value",ei(this.al.el(),"theo-subtitle-options-menu-item"),this.al.el().appendChild(this.Or),this.al.el().appendChild(i),i}cl(t){const i=this.Er(t);i&&this.ll(i)}dl(){return this.jr}Fr(t){this.fl(t.Br)}ll(t){for(const t of this.Pr.menuItems)t.selected(!1);t?(t.selected(!0),this.vl(t.Br.label)):this.vl("Custom")}vl(t){this.pl=t,d(this.ml,this.Vr.localize(t)),this.al.parentMenu.oe()}Ir(t){const i=super.Ir(t);return ei(i.el(),"theo-subtitle-options-menu-item"),this.Ur(i),i}Ur(t){const i=this.Vr.localize(t.Br.label);d(t.el(),i);const s=this.Vr.localize("Set "+this.ol+" to ")+i;t.el().setAttribute("aria-label",s)}Oe(){this.Vr.off("languagechange",this.se),super.Oe()}constructor(t,i,s,e){super(t.subMenu),this.al=void 0,this.Vr=void 0,this.ol=void 0,this.Or=void 0,this.ml=void 0,this.pl=void 0,this.fl=void 0,this.se=void 0,this.al=t,this.Vr=e,this.pl="",this.se=()=>{const t=this.Vr.localize(this.ol);d(this.al.subMenu.menuHeader.el(),t),d(this.Or,t),this.vl(this.pl);for(const t of this.Nr)this.Ur(t)},this.ol=i,this.fl=s.gl,this.ml=this.hl(),this.jr=s.yl,this.Vr.on("languagechange",this.se)}};f();var rl=class t{static bl(t,i,s,e){if(void 0===t&&void 0===i)return;return W(void 0===t?s:t,void 0===i?e:i)}constructor(i){this.kl=void 0,this.wl=void 0,this._l=void 0,this.xl=void 0,this.Cl=void 0,this.Sl=void 0,this.jl=void 0,this.Tl=void 0,this.Ml=void 0,this.Al=void 0,this.Pl=void 0,this.Nl=void 0,this.El=void 0,this.Bl=void 0,this.Il=void 0,this.Fl=void 0,this.kl=i,this.Tl=t=>{this.kl.fontFamily=t.value},this.Ml=t=>{this.kl.fontSize=t.value},this.Al=i=>{this.wl=i.value,this.kl.fontColor=t.bl(this._l,this.wl,sl,tl)},this.Pl=i=>{this._l=i.value,this.kl.fontColor=t.bl(this._l,this.wl,sl,tl)},this.Nl=i=>{this.Cl=i.value,this.kl.backgroundColor=t.bl(this.Cl,this.xl,il,tl)},this.El=i=>{this.xl=i.value,this.kl.backgroundColor=t.bl(this.Cl,this.xl,il,tl)},this.Bl=i=>{this.jl=i.value,this.kl.windowColor=t.bl(this.jl,this.Sl,el,tl)},this.Il=i=>{this.Sl=i.value,this.kl.windowColor=t.bl(this.jl,this.Sl,el,tl)},this.Fl=t=>{this.kl.edgeStyle=t.value}}};f();var hl=class{Dl(t,i){const s=this.$l(t,i.dl());s&&i.cl(s)}$l(t,i){return Ni(i,i=>i.value===t)}Ul(t,i,s){let e,n;if(void 0===t)e=this.$l(void 0,i.dl()),n=this.$l(void 0,s.dl());else if(t){const r=function(t){let i=q(t);i||(i=q(t.slice(0,t.length-1).replace("rgb","rgba")+",1)"));i||(i=U(O(t),1));if(!i){const s=t.charAt(0).toUpperCase()+t.toLowerCase().slice(1);i=U(O(qc[s]),1)}return i}(t);if(r){const t=L(r),h=100*r.Rl;e=this.$l(t,i.dl()),n=this.$l(h,s.dl())}}e&&i.cl(e),n&&s.cl(n)}constructor(t,i){this.kl=void 0,this.Ol=void 0,this.Vl=void 0,this.kl=t,this.Ol=i,this.Vl=()=>{const t=this.kl.fontFamily;this.Dl(t,this.Ol["Font family"]);const i=this.kl.fontColor;this.Ul(i,this.Ol["Font color"],this.Ol["Font opacity"]);const s=this.kl.fontSize;this.Dl(s,this.Ol["Font size"]);const e=this.kl.backgroundColor;this.Ul(e,this.Ol["Background color"],this.Ol["Background opacity"]);const n=this.kl.windowColor;this.Ul(n,this.Ol["Window color"],this.Ol["Window opacity"]);const r=this.kl.edgeStyle;this.Dl(r,this.Ol["Character edge style"])},this.kl.addEventListener("change",this.Vl),this.Vl()}};var ol=class extends Ka{Ll(){return{"Font family":{yl:al(Kc),gl:this.Hl.Tl},"Font color":{yl:al(Yc),gl:this.Hl.Pl},"Font opacity":{yl:al(Jc),gl:this.Hl.Al},"Font size":{yl:al(Xc),gl:this.Hl.Ml},"Background color":{yl:al(Yc),gl:this.Hl.Nl},"Background opacity":{yl:al(Qc),gl:this.Hl.El},"Window color":{yl:al(Yc),gl:this.Hl.Bl},"Window opacity":{yl:al(Qc),gl:this.Hl.Il},"Character edge style":{yl:al(Zc),gl:this.Hl.Fl}}}ql(){this.Or=h.createElement("span"),this.Or.className="theo-settings-control-menu-item-title",this.zl=h.createElement("span"),this.zl.className="theo-primary-color theo-settings-control-menu-item-value",this.Jr.el().appendChild(this.Or),this.Jr.el().appendChild(this.zl),this.se()}Ir(t){const i=this.Pr.addSubMenuItem();return i.Br=t,this.Ol[t]=new nl(i,t,this.Wl[t],this.Vr),i}Ur(t){}Fr(t){}Oe(){this.Vr.off("languagechange",this.se),this.Gl.removeEventListener(["addtrack","removetrack"],this.Xl),super.Oe()}constructor(t,i,s,e){super(t.subMenu),this.Jr=void 0,this.Gl=void 0,this.Vr=void 0,this.Hl=void 0,this.Jl=void 0,this.Wl=void 0,this.Ol=void 0,this.Or=void 0,this.zl=void 0,this.Xl=void 0,this.se=void 0,this.Jr=t,this.Gl=i,this.Vr=e,this.Ol={},this.Xl=()=>{this.Gl.some(t=>At(t.kind))?this.Jr.show():this.Jr.hide()},this.se=()=>{d(this.Pr.menuHeader.el(),this.Vr.localize("Subtitle Options")),d(this.Or,this.Vr.localize("Subtitle")),d(this.zl,this.Vr.localize("Options")),this.Jr.el().setAttribute("aria-label",this.Vr.localize("Open the subtitle options menu"))},this.Hl=new rl(s),this.Wl=this.Ll(),this.jr=w.keys(this.Wl),this.ql(),this.Jl=new hl(s,this.Ol),this.Vr.on("languagechange",this.se),this.Gl.addEventListener(["addtrack","removetrack"],this.Xl),this.Xl()}};function al(t){const i=[{label:"Default",value:void 0}];for(const s of t)"Default"!==s.label&&i.push(s);return i}Di(function(t){const i=t.vo.controlBar.getChild("SettingsButton").menu,s=i.addSubMenuItem({name:"TextTrackOptionsMenuItem"}),e=new ol(s,t.nt.Ca,t.Ql.Ca,t.vo);t.vo.on("dispose",()=>{i.removeMenuItem(s),s.dispose(),e.Oe(),i.dispose()})}),f(),f();var ul=Fo.getComponent("Component"),cl=class extends ul{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}};cl.prototype.h=z({},ul.prototype.h,{children:[]}),Fo.registerComponent("AdControlPanel",cl),f(),f();var ll=Fo.getComponent("Component"),dl="theo-dai-countdown",fl=class extends ll{buildCSSClass(){return dl}createEl(t,i,s){const e=h.createElement("div");return e.className=dl,e}Yl(t,i){i.addEventListener("adbreakbegin",()=>this.show()),i.addEventListener("adbreakend",()=>this.hide()),t.addEventListener("timeupdate",this.se)}constructor(t,i,s){super(t,s),this.oa=void 0,this.hu=void 0,this.se=void 0,this.oa=t,this.hu=i,this.se=()=>{const t=this.hu.ads;t.playing&&t.currentAdBreak&&t.currentAds.length&&d(this.contentEl(),function(t,i,s){const e=t.ads;let n="";const r=e.length;if(r>1){const t=e.indexOf(i)+1;n=s("Ad")+" "+t+"/"+r+". "}const h=_.ceil(t.maxRemainingDuration);return n+=s("The content will resume in {1} seconds.").replace("{1}",""+h),n}(t.currentAdBreak,t.currentAds[0],t=>this.oa.localize(t)))},this.Yl(i,i.ads),this.on(t,"languagechange",this.se)}};f();var vl=Fo.getComponent("ClickableComponent"),pl=class extends vl{buildCSSClass(){return Ut}createEl(t,i,s){return this.h.Ca.element.querySelector("."+Ut)}emitTapEvents(){}se(){d(this.el(),this.localize("Learn more"))}constructor(t,i){super(t,i),d(this.el(),t.localize("Learn more")),this.on(t,"languagechange",this.se)}};Di(function(t){const i=t.Ca.ads;if(i&&i.dai){const i=t.vo,s=new fl(i,t.Ca);i.adControlBar.addChild(s);if(t.Ca.element.querySelector("."+Ut)){const s=new pl(i,{Ca:t.Ca});i.adControlBar.addChild(s)}}}),f(),f();var ml=Fo.getComponent("Component"),gl=["addtrack","removetrack","change"],yl=class extends(Ho(ml)){createEl(){const t=super.createEl();return this.qualityLabel=Fo.createEl("div",{className:"theo-quality-label-text"}),t.appendChild(this.qualityLabel),li(this.qualityLabel),t}dispose(){this.Yr&&(this.Yr.removeEventListener("activequalitychanged",this.Kl),this.Yr=void 0),this.xs.videoTracks.removeEventListener(gl,this.dh),super.dispose()}constructor(t,i){super(t,i),this.qualityLabel=void 0,this.Yr=void 0,this.startFadeOutID=void 0,this.removeLabelClassesID=void 0,this.dh=()=>{const t=Xa(this.xs.videoTracks);t!==this.Yr&&(this.Yr&&this.Yr.removeEventListener("activequalitychanged",this.Kl),this.Yr=t,t&&t.addEventListener("activequalitychanged",this.Kl),this.Kl())},this.Kl=()=>{const t=this.Yr&&this.Yr.activeQuality;if(!this.qualityLabel||!t)return;const i=t.label?t.label:t.height?t.height+"p":void 0;i&&(d(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.xs.videoTracks&&(this.xs.videoTracks.addEventListener(gl,this.dh),this.dh())}};Fo.registerComponent("activeQualityLabel",yl),f(),f();var bl="theo-upcoming-ad-notification",kl=["adbreakbegin","adbreakend","adadded","adloaded","adbegin","adend"],wl=class extends(Ho(pa)){createEl(){const t=Fo.createEl("div",{className:bl});return this.notificationText=Fo.createEl("div",{className:bl+"text"}),t.appendChild(this.notificationText),t}Zl(){if(!this.xs.ads)return;const t=this.xs.ads.scheduledAdBreaks;let i,s=1/0;for(let e=0;e<t.length;e++){const n=t[e],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)}td(){if(!this.xs.ads||this.xs.ads.playing||!this.currentAdBreak||!this.currentAdBreakValid||0===this.currentAdBreak.timeOffset)return void this.sd();const t=this.xs.currentTime;if(this.currentAdBreak.timeOffset>t+10)return void this.sd();const i=_.ceil(this.currentAdBreak.timeOffset-t);i<0?this.sd():this.ed(i)}ed(t){this.nd!==t&&(d(this.notificationText,"Your video will be temporarily interrupted in 0:"+(t<10?"0"+t:t)),this.nd=t,this.show())}sd(){this.nd=NaN,this.hide()}dispose(){var t;this.xs.removeEventListener("timeupdate",this.handleTimeUpdate),null==(t=this.xs.ads)||t.removeEventListener(kl,this.handleAdEvent),this.currentAdBreak=void 0,super.dispose()}constructor(t,i){super(t,i),this.currentAdBreak=void 0,this.currentAdBreakValid=!1,this.nd=NaN,this.handleTimeUpdate=()=>{this.td()},this.handleAdEvent=()=>{this.Zl(),this.td()},this.xs.ads&&(this.hide(),this.xs.addEventListener("timeupdate",this.handleTimeUpdate),this.xs.ads.addEventListener(kl,this.handleAdEvent))}};Fo.registerComponent("upcomingAdNotificationText",wl),f(),f();var _l=Fo.getComponent("Component");Fo.registerComponent("UplynkAdBreakBar",class extends _l{createEl(){const t=h.createElement("div");return t.className="theoplayer-ad-overlay-component theo-ad-remaining-container",t}get rd(){return this.h.adBreakProvider()}se(t,i){if(this.rd&&this.rd.endTime){const s=_.max(this.rd.endTime-t,0);d(i,"Content will resume in "+_.ceil(s)+"s"),this.show()}else this.hide()}constructor(t,i){super(t,i),this.od=()=>{this.se(this.player().currentTime(),this.el())},this.on(t,"timeupdate",this.od)}}),f();var xl=Fo.getComponent("ClickableComponent");Fo.registerComponent("UplynkAdSkipButton",class extends xl{createEl(){const t=h.createElement("div");return t.className="theoplayer-ad-overlay-component theoplayer-ad-skip theoplayer-ad-skip-countdown",this.ad=h.createElement("span"),t.appendChild(this.ad),this.se(t,this.ad),t}handleClick(){this.h.skipCallback()}se(t,i){this.ud<=_t.dd.ld?(ri(t,"theoplayer-ad-skip-countdown"),ei(t,"theoplayer-ad-skip-button"),d(i,"Skip ads")):d(i,"Skip ads in "+_.ceil(this.ud)+"s")}get ud(){return this.h.adBreak.startTime+this.h.adBreak.skipOffset-this.player().currentTime()}constructor(t,i){super(t,i),this.od=()=>{this.se(this.el(),this.ad)},this.on(t,"timeupdate",this.od)}}),f(),f();var Cl=Fo.getComponent("Component"),Sl=class extends Cl{buildCSSClass(){return"theo-uplynk-marker-bar"}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}updateMarkers(t){const i=this.children().slice();let s=0,e=0;for(;s<i.length&&e<t.length;s++,e++){const n=i[s],r=t[e];n.marker===r?n.updateMarker():(this.removeChild(n),this.addChild(this.fd,{marker:r}))}for(;s<i.length;s++)this.removeChild(i[s]);for(;e<t.length;e++){const i=t[e];this.addChild(this.fd,{marker:i})}}constructor(t,i){super(t,i)}};f();var jl=function(t){return t.vd="UplynkAdBreakBar",t.pd="UplynkAdSkipButton",t.md="UplynkAdBreakMarkerBar",t.gd="UplynkAdBreakMarker",t.yd="UplynkAssetMarkerBar",t.bd="UplynkAssetMarker",t.kd="UplynkContentNotificationBar",t.wd="UplynkContentNotification",t}({});function Tl(t,i){const s=t.uplynk;return Boolean(t&&void 0===s)||Boolean(t&&s&&void 0===s.ui)||Boolean(t&&s&&s.ui&&void 0===s.ui[i])||Boolean(t&&s&&s.ui&&!0===s.ui[i])}Ii(function(t){return class extends t{get _d(){return this.vo.controlBar.progressControl.seekBar}Ta(t){this.xd=!1,this.Ca.removeEventListener("timeupdate",this.Cd),this.Ca.removeEventListener("loadeddata",this.Sd),this.vo.removeChild("UplynkAdBreakBar"),this.vo.removeChild("UplynkAdSkipButton"),this._d.removeChild("UplynkAdBreakMarkerBar"),this._d.removeChild("UplynkAssetMarkerBar"),this.vo.removeChild("UplynkContentNotificationBar"),this.Ca.uplynk&&t&&Gt(t)&&this.Ca.addEventListener("loadeddata",this.Sd),super.Ta(t)}jd(){if(!function(t){return Tl(t,"assetMarkers")}(this.Td)||!this.xd)return;let t=this._d.getChild("UplynkAssetMarkerBar");t||(t=this._d.addChild("UplynkAssetMarkerBar")),t.updateMarkers(this.Ca.uplynk.assets)}Md(){if(!function(t){return Tl(t,"contentNotification")}(this.Td))return;let t=this.vo.getChild("UplynkContentNotificationBar");t||(t=this.vo.addChild("UplynkContentNotificationBar")),t.updateAssets(this.Ca.uplynk.assets)}kn(){this.Ca.removeEventListener("timeupdate",this.Cd),this.Ca.removeEventListener("loadeddata",this.Sd);const t=this.Ca.uplynk;null==t||t.ads.adBreaks.removeEventListener("addadbreak",this.Pd),null==t||t.ads.adBreaks.removeEventListener("removeadbreak",this.Nd),null==t||t.assets.removeEventListener("addasset",this.Ed),null==t||t.assets.removeEventListener("removeasset",this.Ed),super.kn()}constructor(t,i,s){super(t,i,s),this.xd=!1,this.Sd=()=>{this.xd=!0,isFinite(this.Bd())||this.Ca.addEventListener("timeupdate",this.Cd),this.Cd(),this.jd(),this.Md()},this.Pd=t=>{t.adBreak.addEventListener("adbreakbegin",this.Id),t.adBreak.addEventListener("adbreakend",this.Fd),this.Cd()},this.Nd=t=>{t.adBreak.removeEventListener("adbreakbegin",this.Id),t.adBreak.removeEventListener("adbreakend",this.Fd),this.Cd()},this.Cd=()=>{if(!function(t){return Tl(t,"adBreakMarkers")}(this.Td)||!this.xd)return;let t=this._d.getChild("UplynkAdBreakMarkerBar");t||(t=this._d.addChild("UplynkAdBreakMarkerBar")),t.updateMarkers(this.Ca.uplynk.ads.adBreaks)},this.Id=()=>{if(function(t){return Tl(t,"adNotification")}(this.Td)){const t=this.Ca.uplynk,i=t.ads.currentAdBreak;this.vo.addChild("UplynkAdBreakBar",{adBreakProvider:this.Dd}),-1!==i.skipOffset&&this.vo.addChild("UplynkAdSkipButton",{adBreak:i,skipCallback:t.ads.skip})}},this.Dd=()=>this.Ca.uplynk.ads.currentAdBreak,this.Fd=()=>{this.vo.removeChild("UplynkAdBreakBar"),this.vo.removeChild("UplynkAdSkipButton")},this.Ed=()=>{this.jd(),this.Md()};const e=this.Ca.uplynk;null==e||e.ads.adBreaks.addEventListener("addadbreak",this.Pd),null==e||e.ads.adBreaks.addEventListener("removeadbreak",this.Nd),null==e||e.assets.addEventListener("addasset",this.Ed),null==e||e.assets.addEventListener("removeasset",this.Ed)}}});Fo.registerComponent("UplynkAdBreakMarkerBar",class extends Sl{buildCSSClass(){return super.buildCSSClass()+" theo-uplynk-marker-bar-adbreak"}get fd(){return jl.gd}}),f(),f();var Ml=Fo.getComponent("Component"),Al=class extends Ml{get marker(){return this.h.marker}get seekable(){return this.player().seekable()}buildCSSClass(){return"theo-uplynk-marker"}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),this.updateMarker(e),e}updateMarker(t){void 0===t&&(t=this.el());const i=this.seekable.start(0),s=this.seekable.end(this.seekable.length-1),e=_.max(this.marker.startTime-i,0),n=void 0!==this.marker.endTime?_.max(s-this.marker.endTime,0):0,r=s-i;t.style.left=e/r*100+"%",t.style.right=n/r*100+"%"}constructor(t,i){super(t,i)}};Fo.registerComponent("UplynkAdBreakMarker",class extends Al{buildCSSClass(){return super.buildCSSClass()+" theo-uplynk-marker-adbreak"}}),f();Fo.registerComponent("UplynkAssetMarkerBar",class extends Sl{buildCSSClass(){return super.buildCSSClass()+" theo-uplynk-marker-bar-asset"}get fd(){return jl.bd}}),f();Fo.registerComponent("UplynkAssetMarker",class extends Al{buildCSSClass(){return super.buildCSSClass()+" theo-uplynk-marker-asset"}}),f();var Pl=Fo.getComponent("Component");Fo.registerComponent("UplynkContentNotificationBar",class extends Pl{buildCSSClass(){const t="theo-uplynk-content-notification-bar";return t+(Dt.ru||Dt.$d?" "+t+"-ios":"")}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}updateAssets(t){const i=this.children().slice();let s=0,e=0;for(;s<i.length&&e<t.length;s++,e++){const n=i[s],r=t[e];n.Ud===r?n.updateCountdown():(this.removeChild(n),this.addChild(jl.wd,{asset:r}))}for(;s<i.length;s++)this.removeChild(i[s]);for(;e<t.length;e++){const i=t[e];this.addChild(jl.wd,{asset:i})}}constructor(t,i){super(t,i)}}),f();var Nl=Fo.getComponent("Component");Fo.registerComponent("UplynkContentNotification",class extends Nl{get Ud(){return this.h.asset}buildCSSClass(){return"theo-uplynk-content-notification"}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}wo(){const t=h.createElement("img");t.src=this.Ud.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.Ud.description);d(i,s),this.el().appendChild(i),this.Rd=h.createElement("div"),this.Rd.className=this.buildCSSClass()+"-countdown",d(this.Rd,this.Od),this.el().appendChild(this.Rd)}get Od(){const t=_.min(10,this.Vd);return"Starting in "+_.ceil(t)+" seconds"}get Vd(){return _.max(0,this.Ud.startTime-this.player().currentTime())}updateCountdown(){const t=this.Vd;t>10||t<=0?this.hide():(d(this.Rd,this.Od),this.show())}constructor(t,i){super(t,i),this.Rd=void 0,this.wo(),this.on(t,"timeupdate",this.updateCountdown),this.hide()}});export{lt as ChromelessPlayer,nt as ErrorCategory,st as ErrorCode,Ou as Player,qt as cache,Bt as cast,pt as features,bt as players,wt as registerContentProtectionIntegration,ft as utils,gt as version,Fo 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,p=a.clearInterval,m=a.Error,g=a.TypeError,k=a.SyntaxError,w=a.Object,_=a.Math,x=a.parseInt,C=a.parseFloat,S=a.isNaN,j=a.Uint8Array;a.Worker,a.WorkerGlobalScope,a.XMLHttpRequest;import{$ as T,$a as M,A,Aa as P,B as N,Ba as E,C as B,Ca as I,D as F,Da as D,E as $,Ea as U,F as R,Fa as O,G as V,Ga as L,H,Ha as q,I as z,Ia as W,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 d,O as st,Oa as et,P as nt,Pa as rt,Q as ht,Qa as ot,R as at,Ra as ut,S as ct,Sa as lt,T as dt,Ta as ft,U as vt,Ua as pt,V as mt,Va as gt,W as yt,Wa as bt,X as kt,Xa as wt,Y as _t,Ya as xt,Z as Ct,Za as St,_ as jt,_a as Tt,a as Mt,aa as At,ab as Pt,b as Nt,ba as Et,bb as Bt,c as f,ca as It,cb as Ft,d as Dt,da as $t,db as Ut,e as Rt,ea as Ot,eb as Vt,f as Lt,fa as Ht,fb as qt,g as zt,ga as Wt,gb as Gt,h as Xt,ha as Jt,hb as Qt,i as Yt,ia as Kt,j as Zt,ja as ti,k as ii,ka as si,l as ei,la as ni,m as ri,ma as hi,n as oi,na as ai,o as ui,oa as ci,p as li,pa as di,q as fi,qa as vi,r as pi,ra as mi,s as gi,sa as yi,t as bi,ta as ki,u as wi,ua as _i,v as xi,va as Ci,w as Si,wa as ji,x as Ti,xa as Mi,y as Ai,ya as Pi,z as Ni,za as Ei}from"./THEOplayer.common.esm.js";f(),f(),f(),f();var Bi=[];function Ii(t){Bi.push(t)}var Fi=[];function Di(t){Fi.push(t)}f(),f(),f(),f();var b=void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},$i=void 0!==h?h:{createElement:function(){}};function Ui(t,i){return i||(i=t.slice(0)),t.raw=i,t}var Ri=1;function Oi(){return Ri++}var Vi,Li=w.prototype.toString,Hi=function(t){return Wi(t)?w.keys(t):[]};function qi(t,i){Hi(t).forEach(function(s){return i(t[s],s)})}function zi(t){for(var i=arguments.length,s=new Array(i>1?i-1:0),e=1;e<i;e++)s[e-1]=arguments[e];return w.assign?w.assign.apply(w,[t].concat(s)):(s.forEach(function(i){i&&qi(i,function(i,s){t[s]=i})}),t)}function Wi(t){return!!t&&"object"==typeof t}function Gi(t){return Wi(t)&&"[object Object]"===Li.call(t)&&t.constructor===w}var Xi=function(t,i,s){void 0===s&&(s=!!Gs&&Gs<11),"log"!==t&&i.unshift(t.toUpperCase()+":"),Vi.history.push(i),i.unshift("VIDEOJS:");var e=b.console&&b.console[t];e&&(s&&(i=i.map(function(t){if(Wi(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"](b.console,i):e(i))};(Vi=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];Xi("log",i)}).history=[],Vi.error=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Xi("error",i)},Vi.warn=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return Xi("warn",i)};var Ji=Vi,Qi="undefined"!=typeof globalThis?globalThis:void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Yi(t){return t.replace(/\n\r?\s*/g,"")}var Ki,Zi=function(t){for(var i="",s=0;s<arguments.length;s++)i+=Yi(t[s])+(arguments[s+1]||"");return i};function ts(t){return"string"==typeof t&&/\S/.test(t)}function is(t){if(/\s/.test(t))throw new m("class has illegal whitespace characters")}function ss(){return $i===b.document&&void 0!==$i.createElement}function es(t){return Wi(t)&&1===t.nodeType}function ns(t){return function(i,s){if(!ts(i))return $i[t](null);ts(s)&&(s=$i.querySelector(s));var e=es(s)?s:$i;return e[t]&&e[t](i)}}function rs(t,i,s,e){void 0===t&&(t="div"),void 0===i&&(i={}),void 0===s&&(s={});var n=$i.createElement(t);return w.getOwnPropertyNames(i).forEach(function(t){var s=i[t];-1!==t.indexOf("aria-")||"role"===t||"type"===t?(Ji.warn(Zi(Ki||(Ki=Ui(["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?hs(n,s):n[t]=s}),w.getOwnPropertyNames(s).forEach(function(t){n.setAttribute(t,s[t])}),e&&Ss(n,e),n}function hs(t,i){return void 0===t.textContent?t.innerText=i:t.textContent=i,t}function os(t,i){i.firstChild?i.insertBefore(t,i.firstChild):i.appendChild(t)}var as={},us="vdata"+(new Date).getTime();function cs(t){var i=t[us];return i||(i=t[us]=Oi()),as[i]||(as[i]={}),as[i]}function ls(t){var i=t[us];return!!i&&!!w.getOwnPropertyNames(as[i]).length}function ds(t){var i=t[us];if(i){delete as[i];try{delete t[us]}catch(i){t.removeAttribute?t.removeAttribute(us):t[us]=null}}}function fs(t,i){return is(i),t.classList?t.classList.contains(i):function(t){return new RegExp("(^|\\s)"+t+"($|\\s)")}(i).test(t.className)}function vs(t,i){return t.classList?t.classList.add(i):fs(t,i)||(t.className=(t.className+" "+i).trim()),t}function ps(t,i){return t.classList?t.classList.remove(i):(is(i),t.className=t.className.split(/\s+/).filter(function(t){return t!==i}).join(" ")),t}function ms(t,i,s){var e=fs(t,i);if("function"==typeof s&&(s=s(t,i)),"boolean"!=typeof s&&(s=!e),s!==e)return s?vs(t,i):ps(t,i),t}function gs(t,i){w.getOwnPropertyNames(i).forEach(function(s){var e=i[s];null==e||!1===e?t.removeAttribute(s):t.setAttribute(s,!0===e?"":e)})}function ys(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 bs(t,i,s){t.setAttribute(i,s)}function ks(t,i){t.removeAttribute(i)}function ws(t){var i;if(t.getBoundingClientRect&&t.parentNode&&(i=t.getBoundingClientRect()),!i)return{left:0,top:0};var s=$i.documentElement,e=$i.body,n=s.clientLeft||e.clientLeft||0,r=b.pageXOffset||e.scrollLeft,h=i.left+r-n,o=s.clientTop||e.clientTop||0,a=b.pageYOffset||e.scrollTop,u=i.top+a-o;return{left:_.round(h),top:_.round(u)}}function _s(t,i){var s={},e=ws(t),n=t.offsetWidth,r=t.offsetHeight,h=e.top,o=e.left,a=i.pageY,u=i.pageX;return i.changedTouches&&(u=i.changedTouches[0].pageX,a=i.changedTouches[0].pageY),s.y=_.max(0,_.min(1,(h-a+r)/r)),s.x=_.max(0,_.min(1,(u-o)/n)),s}function xs(t){return Wi(t)&&3===t.nodeType}function Cs(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function Ss(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()),es(t)||xs(t)?t:"string"==typeof t&&/\S/.test(t)?$i.createTextNode(t):void 0}).filter(function(t){return t})}(i).forEach(function(i){return t.appendChild(i)}),t}function js(t,i){return Ss(Cs(t),i)}var Ts,Ms=ns("querySelector"),As=ns("querySelectorAll"),Ps=b.navigator&&b.navigator.userAgent||"",Ns=/AppleWebKit\/([\d.]+)/i.exec(Ps),Es=Ns?C(Ns.pop()):null,Bs=/iPad/i.test(Ps),Is=/iPhone/i.test(Ps)&&!Bs,Fs=/iPod/i.test(Ps),Ds=Is||Bs||Fs,$s=(Ts=Ps.match(/OS (\d+)_/i))&&Ts[1]?Ts[1]:null,Us=/Android/i.test(Ps),Rs=function(){var t=Ps.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!t)return null;var i=t[1]&&C(t[1]),s=t[2]&&C(t[2]);return i&&s?C(t[1]+"."+t[2]):i||null}(),Os=Us&&/webkit/i.test(Ps)&&Rs<2.3,Vs=Us&&Rs<5&&Es<537,Ls=/Firefox/i.test(Ps),Hs=/Edge/i.test(Ps),qs=!Hs&&/Chrome/i.test(Ps),zs=function(){var t=Ps.match(/Chrome\/(\d+)/);return t&&t[1]?C(t[1]):null}(),Ws=/MSIE\s8\.0/.test(Ps),Gs=function(){var t=/MSIE\s(\d+)\.\d/.exec(Ps),i=t&&C(t[1]);return!i&&/Trident\/7.0/i.test(Ps)&&/rv:11.0/.test(Ps)&&(i=11),i}(),Xs=/Safari/i.test(Ps)&&!qs&&!Us&&!Hs,Js=Xs||Ds,Qs=ss()&&("ontouchstart"in b||b.DocumentTouch&&b.document instanceof b.DocumentTouch),Ys=ss()&&"backgroundSize"in b.document.createElement("video").style,Ks=w.freeze({__proto__:null,IS_IPAD:Bs,IS_IPHONE:Is,IS_IPOD:Fs,IS_IOS:Ds,IOS_VERSION:$s,IS_ANDROID:Us,ANDROID_VERSION:Rs,IS_OLD_ANDROID:Os,IS_NATIVE_ANDROID:Vs,IS_FIREFOX:Ls,IS_EDGE:Hs,IS_CHROME:qs,CHROME_VERSION:zs,IS_IE8:Ws,IE_VERSION:Gs,IS_SAFARI:Xs,IS_ANY_SAFARI:Js,TOUCH_ENABLED:Qs,BACKGROUND_SIZE_SUPPORTED:Ys});function Zs(t,i){var s=cs(t);0===s.handlers[i].length&&(delete s.handlers[i],t.removeEventListener?t.removeEventListener(i,s.dispatcher,!1):t.detachEvent&&t.detachEvent("on"+i,s.dispatcher)),w.getOwnPropertyNames(s.handlers).length<=0&&(delete s.handlers,delete s.dispatcher,delete s.disabled),0===w.getOwnPropertyNames(s).length&&ds(t)}function te(t,i,s,e){s.forEach(function(s){t(i,s,e)})}function ie(t){function i(){return!0}function s(){return!1}if(!t||!t.isPropagationStopped||!t.isImmediatePropagationStopped){var e=t||b.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||$i),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=$i.documentElement,h=$i.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 se=!1;!function(){try{var t=w.defineProperty({},"passive",{get:function(){se=!0}});b.addEventListener("test",null,t)}catch(t){}}();var ee=["touchstart","touchmove"];function ne(t,i,s){if(Array.isArray(i))return te(ne,t,i,s);var e=cs(t);if(e.handlers||(e.handlers={}),e.handlers[i]||(e.handlers[i]=[]),s.guid||(s.guid=Oi()),e.handlers[i].push(s),e.dispatcher||(e.disabled=!1,e.dispatcher=function(i,s){if(!e.disabled){i=ie(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){Ji.error(t)}}}),1===e.handlers[i].length)if(t.addEventListener){var n=!1;se&&ee.indexOf(i)>-1&&(n={passive:!0}),t.addEventListener(i,e.dispatcher,n)}else t.attachEvent&&t.attachEvent("on"+i,e.dispatcher)}function re(t,i,s){if(ls(t)){var e=cs(t);if(e.handlers){if(Array.isArray(i))return te(re,t,i,s);var n=function(i){e.handlers[i]=[],Zs(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);Zs(t,i)}else n(i)}else for(var o in e.handlers)n(o)}}}function he(t,i,s){var e=ls(t)?cs(t):{},n=t.parentNode||t.ownerDocument;if("string"==typeof i&&(i={type:i,target:t}),i=ie(i),e.dispatcher&&e.dispatcher.call(t,i,s),n&&!i.isPropagationStopped()&&!0===i.bubbles)he.call(null,n,i,s);else if(!n&&!i.defaultPrevented){var r=cs(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 oe(t,i,s){if(Array.isArray(i))return te(oe,t,i,s);var e=function e(){re(t,i,e),s.apply(this,arguments)};e.guid=s.guid=s.guid||Oi(),ne(t,i,e)}var ae,ue=!1,ce=function(){if(ss()){var t=$i.getElementsByTagName("video"),i=$i.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){le(1);break}void 0===u.player&&null!==u.getAttribute("data-setup")&&ae(u)}else ue||le(1)}};function le(t,i){i&&(ae=i),b.setTimeout(ce,t)}ss()&&"complete"===$i.readyState?ue=!0:oe(b,"load",function(){ue=!0});var de=function(t){var i=$i.createElement("style");return i.className=t,i},fe=function(t,i){t.styleSheet?t.styleSheet.cssText=i:t.textContent=i},n=function(t,i,s){i.guid||(i.guid=Oi());var e=function(){return i.apply(t,arguments)};return e.guid=s?s+"_"+i.guid:i.guid,e};function ve(t){return"string"!=typeof t?t:t.charAt(0).toUpperCase()+t.slice(1)}function pe(){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&&qi(i,function(i,s){Gi(i)?(Gi(t[s])||(t[s]={}),t[s]=pe(t[s],i)):t[s]=i})}),t}var me=function(){function t(t,i,s){if(!t&&this.play?this.t=t=this:this.t=t,this.h=pe({},this.h),i=this.h=pe(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"+Oi()}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),ds(this.v),this.v=null},i.player=function(){return this.t},i.options=function(t){return Ji.warn("this.options() has been deprecated and will be moved to the constructor in 6.0"),t?(this.h=pe(this.h,t),this.h):this.h},i.el=function(){return this.v},i.createEl=function(t,i,s){return rs(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=ve(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=ve(i),s||(s={}),!0===s&&(Ji.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 m("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&&ve(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:w.keys(s)).concat(w.keys(this.h).filter(function(t){return!e.some(function(i){return"string"==typeof i?t===i:t===i.name})})).map(function(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||ve(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))ne(this.v,t,n(this,i));else{var r=t,h=i,o=n(this,s),a=function(){return e.off(r,h,o)};a.guid=o.guid,this.on("dispose",a);var u=function(){return e.off("dispose",a)};u.guid=o.guid,t.nodeName?(ne(r,h,o),ne(r,"dispose",u)):"function"==typeof t.on&&(r.on(h,o),r.on("dispose",u))}return this},i.off=function(t,i,s){if(!t||"string"==typeof t||Array.isArray(t))re(this.v,t,i);else{var e=t,r=i,h=n(this,s);this.off("dispose",h),t.nodeName?(re(e,r,h),re(e,"dispose",h)):(e.off(r,h),e.off("dispose",h))}return this},i.one=function(t,i,s){var e=arguments,r=this;if("string"==typeof t||Array.isArray(t))oe(this.v,t,n(this,i));else{var h=t,o=i,a=n(this,s),u=function t(){r.off(h,o,t),a.apply(null,e)};u.guid=a.guid,this.on(h,o,u)}return this},i.trigger=function(t,i){return he(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 Ms(t,i||this.contentEl())},i.$$=function(t,i){return As(t,i||this.contentEl())},i.hasClass=function(t){return fs(this.v,t)},i.addClass=function(t){return vs(this.v,t),this},i.removeClass=function(t){return ps(this.v,t),this},i.toggleClass=function(t,i){return ms(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 bs(this.v,t,i),this},i.removeAttribute=function(t){return ks(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 x(-1!==n?e.slice(0,n):this.v["offset"+ve(t)],10)},i.currentDimension=function(t){var i=0;if("width"!==t&&"height"!==t)throw new m("currentDimension only accepts width or height value");if("function"==typeof b.getComputedStyle){var s=b.getComputedStyle(this.v);i=s.getPropertyValue(t)||s[t]}if(0===(i=C(i))){var e="offset"+ve(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;_.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=n(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=n(this,t);var s=b.setTimeout(t,i),e=function(){this.clearTimeout(s)};return e.guid="vjs-timeout-"+s,this.on("dispose",e),s},i.clearTimeout=function(t){b.clearTimeout(t);var i=function(){};return i.guid="vjs-timeout-"+t,this.off("dispose",i),t},i.setInterval=function(t,i){t=n(this,t);var s=b.setInterval(t,i),e=function(){this.clearInterval(s)};return e.guid="vjs-interval-"+s,this.on("dispose",e),s},i.clearInterval=function(t){b.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=ve(i),t.M||(t.M={}),"Player"===i&&t.M[i]){var e=t.M[i];if(e.players&&w.keys(e.players).length>0&&w.keys(e.players).map(function(t){return e.players[t]}).every(Boolean))throw new m("Can not register Player component after player has been created")}return t.M[i]=s,s}},t.getComponent=function(i){if(i)return i=ve(i),t.M&&t.M[i]?t.M[i]:b&&b.videojs&&b.videojs[i]?(Ji.warn("The "+i+" component was added to the videojs object when it should be registered using videojs.registerComponent(name, component)"),b.videojs[i]):void 0},t.extend=function(i){i=i||{},Ji.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=w.create(this.prototype)).constructor=e,e.extend=t.extend,i)i.hasOwnProperty(n)&&(e.prototype[n]=i[n]);return e},t}();me.registerComponent("Component",me);var ge=function(){};function ye(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function be(t,i){return(be=w.setPrototypeOf?w.setPrototypeOf.bind():function(t,i){return t.__proto__=i,t})(t,i)}function ke(t,i){t.prototype=w.create(i.prototype),t.prototype.constructor=t,be(t,i)}function we(t,i,s,e){return void 0===e&&(Ji.warn("DEPRECATED: Function '"+t+"' on 'TimeRanges' called without an index argument."),e=0),function(t,i,s){if(i<0||i>s)throw new m("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 _e(t){return void 0===t||0===t.length?{length:0,start:function(){throw new m("This TimeRanges object is empty")},end:function(){throw new m("This TimeRanges object is empty")}}:{length:t.length,start:we.bind(null,"start",0,t),end:we.bind(null,"end",1,t)}}function xe(t,i){return Array.isArray(t)?_e(t):void 0===t||void 0===i?_e():_e([[t,i]])}function Ce(t,i){var s,e,n=0;if(!i)return 0;t&&t.length||(t=xe(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}ge.prototype.A={},ge.prototype.on=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},ne(this,t,i),this.addEventListener=s},ge.prototype.addEventListener=ge.prototype.on,ge.prototype.off=function(t,i){re(this,t,i)},ge.prototype.removeEventListener=ge.prototype.off,ge.prototype.one=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},oe(this,t,i),this.addEventListener=s},ge.prototype.trigger=function(t){var i=t.type||t;"string"==typeof t&&(t={type:i}),t=ie(t),this.A[i]&&this["on"+i]&&this["on"+i](t),he(this,t)},ge.prototype.dispatchEvent=ge.prototype.trigger;var Se,je,Te,Me,Ae={prefixed:!0},Pe=[["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"]],Ne=Pe[0];for(je=0;je<Pe.length;je++)if(Pe[je][1]in $i){Se=Pe[je];break}if(Se){for(Te=0;Te<Se.length;Te++)Ae[Ne[Te]]=Se[Te];Ae.prefixed=Se[0]!==Ne[0]}function Ee(t){if(t instanceof Ee)return t;"number"==typeof t?this.code=t:"string"==typeof t?this.message=t:Wi(t)&&("number"==typeof t.code&&(this.code=t.code),zi(this,t)),this.message||(this.message=Ee.defaultMessages[this.code]||"")}for(Ee.prototype.code=0,Ee.prototype.message="",Ee.prototype.status=null,Ee.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],Ee.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."},Me=0;Me<Ee.errorTypes.length;Me++)Ee[Ee.errorTypes[Me]]=Me,Ee.prototype[Ee.errorTypes[Me]]=Me;var Be=function(t,i){var s,e=null;try{s=JSON.parse(t,i)}catch(t){e=t}return[e,s]};var Ie=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}})})},Fe=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=Ie(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(Ie))},De=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()},$e="vjs-modal-dialog",Ue=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).P=e.N=e.B=!1,e.closeable(!e.h.uncloseable),e.content(e.h.content),e.S=rs("div",{className:$e+"-content"},{role:"document"}),e.I=rs("p",{className:$e+"-description vjs-offscreen",id:e.el().getAttribute("aria-describedby")}),hs(e.I,e.description()),e.v.appendChild(e.I),e.v.appendChild(e.S),e.on(i,"languagechange",e.handleLanguagechange),e}ke(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 $e+" vjs-hidden "+t.prototype.buildCSSClass.call(this)},s.handleKeyPress=function(t){27===t.which&&this.closeable()&&this.close()},s.label=function(){return this.h.label||this.localize("Modal Window")},s.description=function(){var t=this.h.description||this.localize("This is a modal window.");return this.closeable()&&(t+=" "+this.localize("This modal can be closed by pressing the Escape key or activating the close button.")),t},s.open=function(){if(!this.P){var t=this.player();this.trigger("beforemodalopen"),this.P=!0,(this.h.fillAlways||!this.N&&!this.B)&&this.fill(),this.D=!t.paused(),this.h.pauseOnOpen&&this.D&&t.pause(),this.closeable()&&this.on(this.v.ownerDocument,"keydown",n(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",n(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.U=!!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.U},s.fill=function(){return this.fillWith(this.content())},s.fillWith=function(t){var i=this.contentEl(),s=i.parentNode,e=i.nextSibling;return this.trigger("beforemodalfill"),this.B=!0,s.removeChild(i),this.empty(),js(i,t),this.trigger("modalfill"),e?s.insertBefore(i,e):s.appendChild(i),this},s.empty=function(){return this.trigger("beforemodalempty"),Cs(this.contentEl()),this.trigger("modalempty"),this},s.content=function(t){return void 0!==t&&(this.R=t),this.R},s.handleLanguagechange=function(){this.v.setAttribute("aria-label",this.label()),hs(this.I,this.description()),this.opened()?this.fill():(this.N||this.B)&&(this.N=!1,this.B=!1,this.empty())},i}(me);Ue.prototype.h={pauseOnOpen:!0,temporary:!0},me.registerComponent("ModalDialog",Ue);var Re=function(){function t(i){var s=this;if(Ws)for(var e in s=$i.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);if(t.prototype.O.call(s,i),w.defineProperty(s,"length",{get:function(){return this.V}}),Ws)return s}var i=t.prototype;return i.O=function(t){var i=this.length||0,s=0,e=t.length;this.L=t,this.V=t.length;var n=function(t){""+t in this||w.defineProperty(this,""+t,{get:function(){return this.L[t]}})};if(i<e)for(s=i;s<e;s++)n.call(this,s)},i.getCueById=function(t){for(var i=null,s=0,e=this.length;s<e;s++){var n=this[s];if(n.id===t){i=n;break}}return i},t}(),Oe={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},Ve={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},Le={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},He={disabled:"disabled",hidden:"hidden",showing:"showing"},qe=function(t){function i(s){var e;void 0===s&&(s={});var n=ye(e=t.call(this)||this);if(Ws)for(var r in n=$i.createElement("custom"),i.prototype)"constructor"!==r&&(n[r]=i.prototype[r]);var h={id:s.id||["vjs_track",Oi()].join("_"),kind:s.kind||"",label:s.label||"",language:s.language||""},o=function(t){w.defineProperty(n,t,{get:function(){return h[t]},set:function(){}})};for(var a in h)o(a);return n||ye(e)}return ke(i,t),i}(ge),ze=function(t){var i=["protocol","hostname","port","pathname","search","hash","host"],s=$i.createElement("a");s.href=t;var e,n=""===s.host&&"file:"!==s.protocol;n&&((e=$i.createElement("div")).innerHTML='<a href="'+t+'"></a>',s=e.firstChild,e.setAttribute("style","display:none; position:absolute;"),$i.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&&$i.body.removeChild(e),r},We=function(t){var i=b.location,s=ze(t);return(":"===s.protocol?i.protocol:s.protocol)+s.host!==i.protocol+i.host},Ge={exports:{}};void 0!==s?Ge.exports=s:void 0!==Qi?Ge.exports=Qi:"undefined"!=typeof self?Ge.exports=self:Ge.exports={};var Xe=function(t){var i=Je.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)},Je=w.prototype.toString;var Qe,Ye,Ke,Ze,tn,sn,en,nn,rn,hn,on,an,un=Array.prototype.slice,cn=w.prototype.toString,ln=function(t){var i=this;if("function"!=typeof i||"[object Function]"!==cn.call(i))throw new g("Function.prototype.bind called on incompatible "+i);for(var s,e=un.call(arguments,1),n=_.max(0,i.length-e.length),r=[],h=0;h<n;h++)r.push("$"+h);if(s=Function("binder","return function ("+r.join(",")+"){ return binder.apply(this,arguments); }")(function(){if(this instanceof s){var n=i.apply(this,e.concat(un.call(arguments)));return w(n)===n?n:this}return i.apply(t,e.concat(un.call(arguments)))}),i.prototype){var o=function(){};o.prototype=i.prototype,s.prototype=new o,o.prototype=null}return s},dn=Function.prototype.bind||ln,fn=w.prototype.toString,vn=function(t){var i=fn.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]"===fn.call(t.callee)),s};w.keys||(Ye=w.prototype.hasOwnProperty,Ke=w.prototype.toString,Ze=vn,tn=w.prototype.propertyIsEnumerable,sn=!tn.call({toString:null},"toString"),en=tn.call(function(){},"prototype"),nn=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],rn=function(t){var i=t.constructor;return i&&i.prototype===t},hn={$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},on=function(){if(void 0===s)return!1;for(var t in s)try{if(!hn["$"+t]&&Ye.call(s,t)&&null!==s[t]&&"object"==typeof s[t])try{rn(s[t])}catch(t){return!0}}catch(t){return!0}return!1}(),an=function(t){if(void 0===s||!on)return rn(t);try{return rn(t)}catch(t){return!1}},Qe=function(t){var i=null!==t&&"object"==typeof t,s="[object Function]"===Ke.call(t),e=Ze(t),n=i&&"[object String]"===Ke.call(t),r=[];if(!i&&!s&&!e)throw new g("Object.keys called on a non-object");var h=en&&s;if(n&&t.length>0&&!Ye.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||!Ye.call(t,u)||r.push(String(u));if(sn)for(var c=an(t),l=0;l<nn.length;++l)c&&"constructor"===nn[l]||!Ye.call(t,nn[l])||r.push(nn[l]);return r});var pn=Qe,mn=Array.prototype.slice,gn=vn,yn=w.keys,bn=yn?function(t){return yn(t)}:pn,kn=w.keys;bn.shim=function(){if(w.keys){var t=function(){var t=w.keys(arguments);return t&&t.length===arguments.length}(1,2);t||(w.keys=function(t){return gn(t)?kn(mn.call(t)):kn(t)})}else w.keys=bn;return w.keys||bn};var wn=bn,_n="function"==typeof Mt&&"symbol"==typeof Mt("foo"),xn=w.prototype.toString,Cn=Array.prototype.concat,Sn=w.defineProperty,jn=Sn&&function(){var t={};try{for(var i in Sn(t,"x",{enumerable:!1,value:t}),t)return!1;return t.x===t}catch(t){return!1}}(),Tn=function(t,i,s,e){(!(i in t)||function(t){return"function"==typeof t&&"[object Function]"===xn.call(t)}(e)&&e())&&(jn?Sn(t,i,{configurable:!0,enumerable:!1,value:s,writable:!0}):t[i]=s)},Mn=function(t,i){var s=arguments.length>2?arguments[2]:{},e=wn(i);_n&&(e=Cn.call(e,w.getOwnPropertySymbols(i)));for(var n=0;n<e.length;n+=1)Tn(t,e[n],i[e[n]],s[e[n]])};Mn.supportsDescriptors=!!jn;var An,Pn=Mn,Nn=w.getOwnPropertyDescriptor?function(){return w.getOwnPropertyDescriptor(arguments,"callee").get}():function(){throw new g},En="function"==typeof Mt&&"symbol"==typeof Nt,Bn=w.getPrototypeOf||function(t){return t.__proto__},In=An,Fn=An,Dn=An,$n=void 0===j?An:Bn(j),Un={"$ %Array%":Array,"$ %ArrayBuffer%":"undefined"==typeof ArrayBuffer?An:ArrayBuffer,"$ %ArrayBufferPrototype%":"undefined"==typeof ArrayBuffer?An:ArrayBuffer.prototype,"$ %ArrayIteratorPrototype%":En?Bn([][Nt]()):An,"$ %ArrayPrototype%":Array.prototype,"$ %ArrayProto_entries%":Array.prototype.entries,"$ %ArrayProto_forEach%":Array.prototype.forEach,"$ %ArrayProto_keys%":Array.prototype.keys,"$ %ArrayProto_values%":Array.prototype.values,"$ %AsyncFromSyncIteratorPrototype%":An,"$ %AsyncFunction%":Fn,"$ %AsyncFunctionPrototype%":An,"$ %AsyncGenerator%":An,"$ %AsyncGeneratorFunction%":Dn,"$ %AsyncGeneratorPrototype%":An,"$ %AsyncIteratorPrototype%":An,"$ %Atomics%":"undefined"==typeof Atomics?An:Atomics,"$ %Boolean%":Boolean,"$ %BooleanPrototype%":Boolean.prototype,"$ %DataView%":"undefined"==typeof DataView?An:DataView,"$ %DataViewPrototype%":"undefined"==typeof DataView?An:DataView.prototype,"$ %Date%":Date,"$ %DatePrototype%":Date.prototype,"$ %decodeURI%":decodeURI,"$ %decodeURIComponent%":decodeURIComponent,"$ %encodeURI%":encodeURI,"$ %encodeURIComponent%":encodeURIComponent,"$ %Error%":m,"$ %ErrorPrototype%":m.prototype,"$ %eval%":eval,"$ %EvalError%":EvalError,"$ %EvalErrorPrototype%":EvalError.prototype,"$ %Float32Array%":"undefined"==typeof Float32Array?An:Float32Array,"$ %Float32ArrayPrototype%":"undefined"==typeof Float32Array?An:Float32Array.prototype,"$ %Float64Array%":"undefined"==typeof Float64Array?An:Float64Array,"$ %Float64ArrayPrototype%":"undefined"==typeof Float64Array?An:Float64Array.prototype,"$ %Function%":Function,"$ %FunctionPrototype%":Function.prototype,"$ %Generator%":An,"$ %GeneratorFunction%":In,"$ %GeneratorPrototype%":An,"$ %Int8Array%":"undefined"==typeof Int8Array?An:Int8Array,"$ %Int8ArrayPrototype%":"undefined"==typeof Int8Array?An:Int8Array.prototype,"$ %Int16Array%":"undefined"==typeof Int16Array?An:Int16Array,"$ %Int16ArrayPrototype%":"undefined"==typeof Int16Array?An:Int8Array.prototype,"$ %Int32Array%":"undefined"==typeof Int32Array?An:Int32Array,"$ %Int32ArrayPrototype%":"undefined"==typeof Int32Array?An:Int32Array.prototype,"$ %isFinite%":isFinite,"$ %isNaN%":S,"$ %IteratorPrototype%":En?Bn(Bn([][Nt]())):An,"$ %JSON%":JSON,"$ %JSONParse%":JSON.parse,"$ %Map%":"undefined"==typeof Map?An:Map,"$ %MapIteratorPrototype%":"undefined"!=typeof Map&&En?Bn((new Map)[Nt]()):An,"$ %MapPrototype%":"undefined"==typeof Map?An:Map.prototype,"$ %Math%":_,"$ %Number%":Number,"$ %NumberPrototype%":Number.prototype,"$ %Object%":w,"$ %ObjectPrototype%":w.prototype,"$ %ObjProto_toString%":w.prototype.toString,"$ %ObjProto_valueOf%":w.prototype.valueOf,"$ %parseFloat%":C,"$ %parseInt%":x,"$ %Promise%":"undefined"==typeof Promise?An:Promise,"$ %PromisePrototype%":"undefined"==typeof Promise?An:Promise.prototype,"$ %PromiseProto_then%":"undefined"==typeof Promise?An:Promise.prototype.then,"$ %Promise_all%":"undefined"==typeof Promise?An:Promise.all,"$ %Promise_reject%":"undefined"==typeof Promise?An:Promise.reject,"$ %Promise_resolve%":"undefined"==typeof Promise?An:Promise.resolve,"$ %Proxy%":"undefined"==typeof Proxy?An:Proxy,"$ %RangeError%":RangeError,"$ %RangeErrorPrototype%":RangeError.prototype,"$ %ReferenceError%":ReferenceError,"$ %ReferenceErrorPrototype%":ReferenceError.prototype,"$ %Reflect%":"undefined"==typeof Reflect?An:Reflect,"$ %RegExp%":RegExp,"$ %RegExpPrototype%":RegExp.prototype,"$ %Set%":"undefined"==typeof Set?An:Set,"$ %SetIteratorPrototype%":"undefined"!=typeof Set&&En?Bn((new Set)[Nt]()):An,"$ %SetPrototype%":"undefined"==typeof Set?An:Set.prototype,"$ %SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?An:SharedArrayBuffer,"$ %SharedArrayBufferPrototype%":"undefined"==typeof SharedArrayBuffer?An:SharedArrayBuffer.prototype,"$ %String%":String,"$ %StringIteratorPrototype%":En?Bn(""[Nt]()):An,"$ %StringPrototype%":String.prototype,"$ %Symbol%":En?Mt:An,"$ %SymbolPrototype%":En?Mt.prototype:An,"$ %SyntaxError%":k,"$ %SyntaxErrorPrototype%":k.prototype,"$ %ThrowTypeError%":Nn,"$ %TypedArray%":$n,"$ %TypedArrayPrototype%":$n?$n.prototype:An,"$ %TypeError%":g,"$ %TypeErrorPrototype%":g.prototype,"$ %Uint8Array%":void 0===j?An:j,"$ %Uint8ArrayPrototype%":void 0===j?An:j.prototype,"$ %Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?An:Uint8ClampedArray,"$ %Uint8ClampedArrayPrototype%":"undefined"==typeof Uint8ClampedArray?An:Uint8ClampedArray.prototype,"$ %Uint16Array%":"undefined"==typeof Uint16Array?An:Uint16Array,"$ %Uint16ArrayPrototype%":"undefined"==typeof Uint16Array?An:Uint16Array.prototype,"$ %Uint32Array%":"undefined"==typeof Uint32Array?An:Uint32Array,"$ %Uint32ArrayPrototype%":"undefined"==typeof Uint32Array?An:Uint32Array.prototype,"$ %URIError%":URIError,"$ %URIErrorPrototype%":URIError.prototype,"$ %WeakMap%":"undefined"==typeof WeakMap?An:WeakMap,"$ %WeakMapPrototype%":"undefined"==typeof WeakMap?An:WeakMap.prototype,"$ %WeakSet%":"undefined"==typeof WeakSet?An:WeakSet,"$ %WeakSetPrototype%":"undefined"==typeof WeakSet?An:WeakSet.prototype},Rn=function(t,i){if(arguments.length>1&&"boolean"!=typeof i)throw new g('"allowMissing" argument must be a boolean');var s="$ "+t;if(!(s in Un))throw new k("intrinsic "+t+" does not exist!");if(void 0===Un[s]&&!i)throw new g("intrinsic "+t+" exists, but is not available. Please file an issue!");return Un[s]},On=dn.call(Function.call,w.prototype.hasOwnProperty),Vn=Rn,Ln=Vn("%TypeError%"),Hn=Vn("%SyntaxError%"),qn=On,zn={"Property Descriptor":function(t,i){if("Object"!==t.Type(i))return!1;var s={"[[Configurable]]":!0,"[[Enumerable]]":!0,"[[Get]]":!0,"[[Set]]":!0,"[[Value]]":!0,"[[Writable]]":!0};for(var e in i)if(qn(i,e)&&!s[e])return!1;var n=qn(i,"[[Value]]"),r=qn(i,"[[Get]]")||qn(i,"[[Set]]");if(n&&r)throw new Ln("Property Descriptors may not be both accessor and data descriptors");return!0}},Wn=Number.isNaN||function(t){return t!=t},Gn=Number.isNaN||function(t){return t!=t},Xn=Number.isFinite||function(t){return"number"==typeof t&&!Gn(t)&&t!==1/0&&t!==-1/0},Jn=Function.prototype.toString,Qn=/^\s*class\b/,Yn=function(t){try{var i=Jn.call(t);return Qn.test(i)}catch(t){return!1}},Kn=w.prototype.toString,Zn="function"==typeof Mt&&"symbol"==typeof Mt.toStringTag,tr=function(t){if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if("function"==typeof t&&!t.prototype)return!0;if(Zn)return function(t){try{return!Yn(t)&&(Jn.call(t),!0)}catch(t){return!1}}(t);if(Yn(t))return!1;var i=Kn.call(t);return"[object Function]"===i||"[object GeneratorFunction]"===i},ir=w.prototype.toString,sr=function(t){return null===t||"function"!=typeof t&&"object"!=typeof t},er=tr,nr=function(t){var i;if((i=arguments.length>1?arguments[1]:"[object Date]"===ir.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(er(t[n[e]])&&(s=t[n[e]](),sr(s)))return s;throw new g("No default value")}throw new g("invalid [[DefaultValue]] hint supplied")},rr=Rn,hr=rr("%Object%"),or=rr("%TypeError%"),ar=rr("%String%"),ur=function(t,i,s,e){var n=zn[i];if("function"!=typeof n)throw new Hn("unknown record type: "+i);if(!n(t,e))throw new Ln(s+" must be a "+i);console.log(n(t,e),e)},cr=Wn,lr=Xn,dr=function(t){return t>=0?1:-1},fr=function(t,i){var s=t%i;return _.floor(s>=0?s:s+i)},vr=On,pr={ToPrimitive:function(t){return sr(t)?t:arguments.length>1?nr(t,arguments[1]):nr(t)},ToBoolean:function(t){return!!t},ToNumber:function(t){return+t},ToInteger:function(t){var i=this.ToNumber(t);return cr(i)?0:0!==i&&lr(i)?dr(i)*_.floor(_.abs(i)):i},ToInt32:function(t){return this.ToNumber(t)|0},ToUint32:function(t){return this.ToNumber(t)>>>0},ToUint16:function(t){var i=this.ToNumber(t);if(cr(i)||0===i||!lr(i))return 0;var s=dr(i)*_.floor(_.abs(i));return fr(s,65536)},ToString:function(t){return ar(t)},ToObject:function(t){return this.CheckObjectCoercible(t),hr(t)},CheckObjectCoercible:function(t,i){if(null==t)throw new or(i||"Cannot call method on "+t);return t},IsCallable:tr,SameValue:function(t,i){return t===i?0!==t||1/t==1/i:cr(t)&&cr(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(vr(t,s)&&!i[s])return!1;var e=vr(t,"[[Value]]"),n=vr(t,"[[Get]]")||vr(t,"[[Set]]");if(e&&n)throw new or("Property Descriptors may not be both accessor and data descriptors");return!0},IsAccessorDescriptor:function(t){return void 0!==t&&(ur(this,"Property Descriptor","Desc",t),!(!vr(t,"[[Get]]")&&!vr(t,"[[Set]]")))},IsDataDescriptor:function(t){return void 0!==t&&(ur(this,"Property Descriptor","Desc",t),!(!vr(t,"[[Value]]")&&!vr(t,"[[Writable]]")))},IsGenericDescriptor:function(t){return void 0!==t&&(ur(this,"Property Descriptor","Desc",t),!this.IsAccessorDescriptor(t)&&!this.IsDataDescriptor(t))},FromPropertyDescriptor:function(t){if(void 0===t)return t;if(ur(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 or("FromPropertyDescriptor must be called with a fully populated Property Descriptor")},ToPropertyDescriptor:function(t){if("Object"!==this.Type(t))throw new or("ToPropertyDescriptor requires an object");var i={};if(vr(t,"enumerable")&&(i["[[Enumerable]]"]=this.ToBoolean(t.enumerable)),vr(t,"configurable")&&(i["[[Configurable]]"]=this.ToBoolean(t.configurable)),vr(t,"value")&&(i["[[Value]]"]=t.value),vr(t,"writable")&&(i["[[Writable]]"]=this.ToBoolean(t.writable)),vr(t,"get")){var s=t.get;if(void 0!==s&&!this.IsCallable(s))throw new g("getter must be a function");i["[[Get]]"]=s}if(vr(t,"set")){var e=t.set;if(void 0!==e&&!this.IsCallable(e))throw new or("setter must be a function");i["[[Set]]"]=e}if((vr(i,"[[Get]]")||vr(i,"[[Set]]"))&&(vr(i,"[[Value]]")||vr(i,"[[Writable]]")))throw new or("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return i}},mr=dn.call(Function.call,String.prototype.replace),gr=/^[\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]+/,yr=/[\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]+$/,br=function(){var t=pr.ToString(pr.CheckObjectCoercible(this));return mr(mr(t,gr,""),yr,"")},kr=br,wr=function(){return String.prototype.trim&&"\u200b"==="\u200b".trim()?String.prototype.trim:kr},_r=Pn,xr=wr,Cr=Pn,Sr=br,jr=wr,Tr=function(){var t=xr();return _r(String.prototype,{trim:t},{trim:function(){return String.prototype.trim!==t}}),t},Mr=dn.call(Function.call,jr());Cr(Mr,{getPolyfill:jr,implementation:Sr,shim:Tr});var Ar=Mr,Pr=tr,Nr=w.prototype.toString,Er=w.prototype.hasOwnProperty,Br=Ar,Ir=function(t,i,s){if(!Pr(i))throw new g("iterator must be a function");var e;arguments.length>=3&&(e=s),"[object Array]"===Nr.call(t)?function(t,i,s){for(var e=0,n=t.length;e<n;e++)Er.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)Er.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))}(t,i,e)},Fr=function(){for(var t={},i=0;i<arguments.length;i++){var s=arguments[i];for(var e in s)Dr.call(s,e)&&(t[e]=s[e])}return t},Dr=w.prototype.hasOwnProperty;var $r=Ge.exports,Ur=Xe,Rr=function(t){if(!t)return{};var i={};return Ir(Br(t).split("\n"),function(t){var s=t.indexOf(":"),e=Br(t.slice(0,s)).toLowerCase(),n=Br(t.slice(s+1));void 0===i[e]?i[e]=n:!function(t){return"[object Array]"===w.prototype.toString.call(t)}(i[e])?i[e]=[i[e],n]:i[e].push(n)}),i},Or=Fr,Vr=Hr;function Lr(t,i,s){var e=t;return Ur(i)?(s=i,"string"==typeof t&&(e={uri:t})):e=Or(i,{uri:t}),e.callback=s,e}function Hr(t,i,s){return qr(i=Lr(t,i,s))}function qr(t){if(void 0===t.callback)throw new m("callback argument missing");var i=!1,s=function(s,e,n){i||(i=!0,t.callback(s,e,n))};function e(){var t=void 0;if(t=l.response?l.response:l.responseText||function(t){if("document"===t.responseType)return t.responseXML;var i=204===t.status&&t.responseXML&&"parsererror"===t.responseXML.documentElement.nodeName;if(""===t.responseType&&!i)return t.responseXML;return null}(l),b)try{t=JSON.parse(t)}catch(t){}return t}var n={body:void 0,headers:{},statusCode:0,method:v,url:f,rawRequest:l};function r(t){return c(d),t instanceof m||(t=new m(""+(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=Rr(l.getAllResponseHeaders()))):h=new m("Internal XMLHttpRequest Error"),s(h,r,r.body)}}var o,a,l=t.xhr||null;l||(l=t.cors||t.useXDR?new Hr.XDomainRequest:new Hr.XMLHttpRequest);var d,f=l.url=t.uri||t.url,v=l.method=t.method||"GET",p=t.body||t.data||null,g=l.headers=t.headers||{},y=!!t.sync,b=!1;if("json"in t&&(b=!0,g.accept||g.Accept||(g.Accept="application/json"),"GET"!==v&&"HEAD"!==v&&(g["content-type"]||g["Content-Type"]||(g["Content-Type"]="application/json"),p=JSON.stringify(t.json))),l.onreadystatechange=function(){4===l.readyState&&h()},l.onload=h,l.onerror=r,l.onprogress=function(){},l.ontimeout=r,l.open(v,f,!y,t.username,t.password),y||(l.withCredentials=!!t.withCredentials),!y&&t.timeout>0&&(d=u(function(){a=!0,l.abort("timeout");var t=new m("XMLHttpRequest timeout");t.code="ETIMEDOUT",r(t)},t.timeout)),l.setRequestHeader)for(o in g)g.hasOwnProperty(o)&&l.setRequestHeader(o,g[o]);else if(t.headers&&!function(t){for(var i in t)if(t.hasOwnProperty(i))return!1;return!0}(t.headers))throw new m("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}Hr.XMLHttpRequest=$r.XMLHttpRequest||function(){},Hr.XDomainRequest="withCredentials"in new Hr.XMLHttpRequest?Hr.XMLHttpRequest:$r.XDomainRequest,function(t,i){for(var s=0;s<t.length;s++)i(t[s])}(["get","put","post","patch","head","delete"],function(t){Hr["delete"===t?"del":t]=function(i,s,e){return(s=Lr(i,s,e)).method=t.toUpperCase(),qr(s)}});var zr=function(t,i){var s=new b.WebVTT.Parser(b,b.vttjs,b.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&&(b.console&&b.console.groupCollapsed&&b.console.groupCollapsed("Text Track parsing errors for "+i.src),e.forEach(function(t){return Ji.error(t)}),b.console&&b.console.groupEnd&&b.console.groupEnd()),s.flush()},Wr=function(t){function i(s){var e;if(void 0===s&&(s={}),!s.tech)throw new m("A tech was not provided.");var r=pe(s,{kind:Le[s.kind]||"subtitles",language:s.language||s.srclang||""}),h=He[r.mode]||"disabled",o=r.default;"metadata"!==r.kind&&"chapters"!==r.kind||(h="hidden");var a=e=t.call(this,r)||this;if(a.H=r.tech,Ws)for(var u in i.prototype)"constructor"!==u&&(a[u]=i.prototype[u]);a.L=[],a.q=[];var c=new Re(a.L),l=new Re(a.q),d=!1,f=n(a,function(){this.activeCues,d&&(this.trigger("cuechange"),d=!1)});return"disabled"!==h&&a.H.ready(function(){a.H.on("timeupdate",f)},!0),w.defineProperty(a,"default",{get:function(){return o},set:function(){}}),w.defineProperty(a,"mode",{get:function(){return h},set:function(t){var i=this;He[t]&&("showing"===(h=t)&&this.H.ready(function(){i.H.on("timeupdate",f)},!0),this.trigger("modechange"))}}),w.defineProperty(a,"cues",{get:function(){return this.W?c:null},set:function(){}}),w.defineProperty(a,"activeCues",{get:function(){if(!this.W)return null;if(0===this.cues.length)return l;for(var t=this.H.currentTime(),i=[],s=0,e=this.cues.length;s<e;s++){var n=this.cues[s];(n.startTime<=t&&n.endTime>=t||n.startTime===n.endTime&&n.startTime<=t&&n.startTime+.5>=t)&&i.push(n)}if(d=!1,i.length!==this.q.length)d=!0;else for(var r=0;r<i.length;r++)-1===this.q.indexOf(i[r])&&(d=!0);return this.q=i,l.O(this.q),l},set:function(){}}),r.src?(a.src=r.src,function(t,i){var s={uri:t},e=We(t);e&&(s.cors=e),Vr(s,n(this,function(t,s,e){if(t)return Ji.error(t,s);if(i.W=!0,"function"!=typeof b.WebVTT){if(i.H){var n=function(){return zr(e,i)};i.H.on("vttjsloaded",n),i.H.on("vttjserror",function(){Ji.error("vttjs failed to load, stopping trying to process "+i.src),i.H.off("vttjsloaded",n)})}}else zr(e,i)}))}(r.src,a)):a.W=!0,a||ye(e)}ke(i,t);var s=i.prototype;return s.addCue=function(t){var i=t;if(b.vttjs&&!(t instanceof b.vttjs.VTTCue)){for(var s in i=new b.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.O(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.O(this.L);break}}},i}(qe);Wr.prototype.A={cuechange:"cuechange"};var Gr=function(t){function i(s){var e,n;void 0===s&&(s={});var r=ye(e=t.call(this)||this);if(Ws)for(var h in r=$i.createElement("custom"),i.prototype)"constructor"!==h&&(r[h]=i.prototype[h]);var o=new Wr(s);return r.kind=o.kind,r.src=o.src,r.srclang=o.language,r.label=o.label,r.default=o.default,w.defineProperty(r,"readyState",{get:function(){return n}}),w.defineProperty(r,"track",{get:function(){return o}}),n=0,o.addEventListener("loadeddata",function(){n=2,r.trigger({type:"load",target:r})}),Ws?r||ye(e):e}return ke(i,t),i}(ge);Gr.prototype.A={load:"load"},Gr.NONE=0,Gr.LOADING=1,Gr.LOADED=2,Gr.ERROR=3;var Xr,Jr=function(){function t(i){void 0===i&&(i=[]);var s=this;if(Ws)for(var e in s=$i.createElement("custom"),t.prototype)"constructor"!==e&&(s[e]=t.prototype[e]);s.X=[],w.defineProperty(s,"length",{get:function(){return this.X.length}});for(var n=0,r=i.length;n<r;n++)s.J(i[n]);if(Ws)return s}var i=t.prototype;return i.J=function(t){var i=this.X.length;""+i in this||w.defineProperty(this,i,{get:function(){return this.X[i]}}),-1===this.X.indexOf(t)&&this.X.push(t)},i.Y=function(t){for(var i,s=0,e=this.X.length;s<e;s++)if(t===this.X[s].track){i=this.X[s];break}return i},i.K=function(t){for(var i=0,s=this.X.length;i<s;i++)if(t===this.X[i]){this.X.splice(i,1);break}},t}(),Qr=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=ye(n),Ws))for(var r in e=$i.createElement("custom"),i.prototype)"constructor"!==r&&(e[r]=i.prototype[r]);e.Z=[],w.defineProperty(e,"length",{get:function(){return this.Z.length}});for(var h=0;h<s.length;h++)e.tt(s[h]);return e||ye(n)}ke(i,t);var s=i.prototype;return s.tt=function(t){var i=this.Z.length;""+i in this||w.defineProperty(this,i,{get:function(){return this.Z[i]}}),-1===this.Z.indexOf(t)&&(this.Z.push(t),this.trigger({track:t,type:"addtrack"}))},s.it=function(t){for(var i,s=0,e=this.length;s<e;s++)if(this[s]===t){(i=this[s]).off&&i.off(),this.Z.splice(s,1);break}i&&this.trigger({track:i,type:"removetrack"})},s.getTrackById=function(t){for(var i=null,s=0,e=this.length;s<e;s++){var n=this[s];if(n.id===t){i=n;break}}return i},i}(ge);for(Xr in Qr.prototype.A={change:"change",addtrack:"addtrack",removetrack:"removetrack"},Qr.prototype.A)Qr.prototype["on"+Xr]=null;var Yr=function(t){function i(s){var e,n;if(void 0===s&&(s=[]),Ws){for(var r in n=$i.createElement("custom"),Qr.prototype)"constructor"!==r&&(n[r]=Qr.prototype[r]);for(var h in i.prototype)"constructor"!==h&&(n[h]=i.prototype[h])}return(n=e=t.call(this,s,n)||this)||ye(e)}return ke(i,t),i.prototype.tt=function(i){t.prototype.tt.call(this,i),i.addEventListener("modechange",n(this,function(){this.trigger("change")}))},i}(Qr),Kr=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].selected=!1)},Zr=function(t){function i(s){var e,n;void 0===s&&(s=[]);for(var r=s.length-1;r>=0;r--)if(s[r].selected){Kr(s,s[r]);break}if(Ws){for(var h in n=$i.createElement("custom"),Qr.prototype)"constructor"!==h&&(n[h]=Qr.prototype[h]);for(var o in i.prototype)"constructor"!==o&&(n[o]=i.prototype[o])}return(n=e=t.call(this,s,n)||this).st=!1,w.defineProperty(n,"selectedIndex",{get:function(){for(var t=0;t<this.length;t++)if(this[t].selected)return t;return-1},set:function(){}}),n||ye(e)}ke(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.selected&&Kr(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("selectedchange",function(){s.st||(s.st=!0,Kr(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}(Qr),th=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].enabled=!1)},ih=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){th(s,s[r]);break}if(Ws){for(var h in n=$i.createElement("custom"),Qr.prototype)"constructor"!==h&&(n[h]=Qr.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||ye(e)}ke(i,t);var s=i.prototype;return s.tt=function(i){var s=this;i.enabled&&th(this,i),t.prototype.tt.call(this,i),i.addEventListener&&i.addEventListener("enabledchange",function(){s.st||(s.st=!0,th(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}(Qr),sh=void 0;var eh=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 Yr,e.initTextTrackListeners(),e.initTrackListeners(),i.nativeControlsForTouch||e.emitTapEvents(),e.constructor&&(e.l=e.constructor.name||"Unknown Tech"),e}ke(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(n(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 xe(0,0)},s.bufferedPercent=function(){return Ce(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 Ee(t),this.trigger("error")),this.lt},s.played=function(){return this.et?xe(0,0):xe()},s.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},s.initTextTrackListeners=function(){var t=n(this,function(){this.trigger("texttrackchange")}),i=this.textTracks();i&&(i.addEventListener("removetrack",t),i.addEventListener("addtrack",t),this.on("dispose",n(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(!b.WebVTT)if($i.body.contains(this.el())){if(!this.h["vtt.js"]&&Gi(sh)&&w.keys(sh).length>0)return void this.trigger("vttjsloaded");var i=$i.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}),b.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 Zr,this.rt},s.audioTracks=function(){return this.ht=this.ht||new ih,this.ht},s.textTracks=function(){return this.nt=this.nt||new Yr,this.nt},s.remoteTextTracks=function(){return this.ft=this.ft||new Yr,this.ft},s.remoteTextTrackEls=function(){return this.vt=this.vt||new Jr,this.vt},s.addTextTrack=function(t,i,s){if(!t)throw new m("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 Wr(n);return r.tt(h),h}(this,t,i,s)},s.createRemoteTextTrack=function(t){var i=pe(t,{tech:this});return new Gr(i)},s.addRemoteTextTrack=function(t,i){void 0===t&&(t={});var s=this.createRemoteTextTrack(t);return!0!==i&&!1!==i&&(Ji.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 m("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]:b&&b.videojs&&b.videojs[t]?(Ji.warn("The "+t+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),b.videojs[t]):void 0},i}(me);eh.prototype.nt,eh.prototype.ht,eh.prototype.rt,eh.prototype.featuresVolumeControl=!0,eh.prototype.featuresFullscreenResize=!1,eh.prototype.featuresPlaybackRate=!1,eh.prototype.featuresProgressEvents=!1,eh.prototype.featuresTimeupdateEvents=!1,eh.prototype.featuresNativeTextTracks=!1,eh.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:Ji.error("No source hander found for the current source.")),this.disposeSourceHandler(),this.off("dispose",this.disposeSourceHandler),s!==t.nativeSourceHandler&&(this.bt=i,this.off(this.v,"loadstart",t.prototype.kt),this.off(this.v,"loadstart",t.prototype.wt),this.one(this.v,"loadstart",t.prototype.kt)),this.yt=s.handleSource(i,this,this.h),this.on("dispose",this.disposeSourceHandler),this},t.prototype.kt=function(){this.one(this.v,"loadstart",t.prototype.wt)},t.prototype.wt=function(){this.disposeSourceHandler(),this.one(this.v,"loadstart",t.prototype.wt)},t.prototype.disposeSourceHandler=function(){this.bt&&(this.clearTracks(["audio","video"]),this.bt=null),this.cleanupAutoTextTracks(),this.yt&&(this.off(this.v,"loadstart",t.prototype.kt),this.off(this.v,"loadstart",t.prototype.wt),this.yt.dispose&&this.yt.dispose(),this.yt=null)}},me.registerComponent("Tech",eh),me.registerComponent("MediaTechController",eh),eh.registerTech("Tech",eh);var nh=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=ve(h[r]),a=eh.getTech(o);if(o||(a=me.getComponent(o)),a&&a.isSupported()){i._t(o);break}}return n}return ke(i,t),i}(me);me.registerComponent("MediaLoader",nh);var rh=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}ke(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=zi({className:this.buildCSSClass(),tabIndex:0},s),"button"===i&&Ji.error("Creating a ClickableComponent with an HTML element of "+i+" is not supported; use a Button instead."),e=zi({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=rs("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){ne($i,"keydown",n(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){re($i,"keydown",n(this,this.handleKeyPress))},i}(me);me.registerComponent("ClickableComponent",rh);var hh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).update(),i.on("posterchange",n(ye(e),e.update)),e}ke(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=rs("div",{className:"vjs-poster",tabIndex:-1});return Ys||(this.jt=rs("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}(rh);me.registerComponent("PosterImage",hh);var oh="#222",ah={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 uh(t,i){return"rgba("+x(t[1]+t[1],16)+","+x(t[2]+t[2],16)+","+x(t[3]+t[3],16)+","+i+")"}function ch(t,i,s){try{t.style[i]=s}catch(t){return}}var lh=function(t){function i(i,s,e){var r;return r=t.call(this,i,s,e)||this,i.on("loadstart",n(ye(r),r.toggleDisplay)),i.on("texttrackchange",n(ye(r),r.updateDisplay)),i.ready(n(ye(r),function(){if(i.H&&i.H.featuresNativeTextTracks)this.hide();else{i.on("fullscreenchange",n(this,this.updateDisplay));for(var t=this.h.playerOptions.tracks||[],s=0;s<t.length;s++)this.t.addRemoteTextTrack(t[s],!0);var e,r,h={captions:1,subtitles:1},o=this.t.textTracks();if(o){for(var a=0;a<o.length;a++){var u=o[a];u.default&&("descriptions"!==u.kind||e?u.kind in h&&!r&&(r=u):e=u)}r?r.mode="showing":e&&(e.mode="showing")}}})),r}ke(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 b.WebVTT&&b.WebVTT.processCues(b,[],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 b.WebVTT&&t.activeCues){for(var i=this.t.textTrackSettings.getValues(),s=[],e=0;e<t.activeCues.length;e++)s.push(t.activeCues[e]);b.WebVTT.processCues(b,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&&ch(h.firstChild,"color",uh(i.color||"#fff",i.textOpacity)),i.backgroundColor&&(h.firstChild.style.backgroundColor=i.backgroundColor),i.backgroundOpacity&&ch(h.firstChild,"backgroundColor",uh(i.backgroundColor||"#000",i.backgroundOpacity)),i.windowColor&&(i.windowOpacity?ch(h,"backgroundColor",uh(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 "+oh:"raised"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #222, 2px 2px #222, 3px 3px "+oh:"depressed"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #ccc, 0 1px #ccc, -1px -1px #222, 0 -1px "+oh:"uniform"===i.edgeStyle&&(h.firstChild.style.textShadow="0 0 4px #222, 0 0 4px #222, 0 0 4px #222, 0 0 4px "+oh)),i.fontPercent&&1!==i.fontPercent){var o=b.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=ah[i.fontFamily])}}}},i}(me);me.registerComponent("TextTrackDisplay",lh);var dh=function(t){function i(){return t.apply(this,arguments)||this}return ke(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"})},i}(me);me.registerComponent("LoadingSpinner",dh);var fh=function(t){function i(){return t.apply(this,arguments)||this}ke(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=zi({className:this.buildCSSClass()},i),"button"!==t&&(Ji.warn("Creating a Button with an HTML element of "+t+" is deprecated; use ClickableComponent instead."),i=zi({tabIndex:0},i),s=zi({role:"button"},s)),s=zi({type:"button","aria-live":"polite"},s);var e=me.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 Ji.warn("Adding an actionable (user controllable) child to a Button ("+s+") is not supported; use a ClickableComponent instead."),me.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}(rh);me.registerComponent("Button",fh);var vh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Tt=!1,e.on("mousedown",e.handleMouseDown),e}ke(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}(fh);vh.prototype.St="Play Video",me.registerComponent("BigPlayButton",vh);var ph=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).controlText(s&&s.controlText||"Close"),e}ke(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}(fh);me.registerComponent("CloseButton",ph);var mh=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}ke(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}(fh);function gh(t,i){void 0===i&&(i=t),t=t<0?0:t;var s=_.floor(t%60),e=_.floor(t/60%60),n=_.floor(t/3600),r=_.floor(i/60%60),h=_.floor(i/3600);return(S(t)||t===1/0)&&(n=e=s="-"),(n=n>0||h>0?n+":":"")+(e=((n||r>=10)&&e<10?"0"+e:e)+":")+(s=s<10?"0"+s:s)}mh.prototype.St="Play",me.registerComponent("PlayToggle",mh);var yh=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}ke(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=rs("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=gh(i,this.t.duration());e!==this.Mt&&(this.Mt=e,this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e)},i}(me);me.registerComponent("CurrentTimeDisplay",yh);var bh=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}ke(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=rs("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=gh(i);this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e}},i}(me);me.registerComponent("DurationDisplay",bh);var kh=function(t){function i(){return t.apply(this,arguments)||this}return ke(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}(me);me.registerComponent("TimeDivider",kh);var wh=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}ke(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=rs("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=gh(this.t.remainingTime());s!==this.Mt&&(this.Mt=s,this.S.innerHTML='<span class="vjs-control-text">'+i+"</span> -"+s)}},i}(me);me.registerComponent("RemainingTimeDisplay",wh);var _h=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}ke(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=rs("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.Ct=rs("span",{className:"vjs-control-text",innerHTML:this.localize("Stream Type")}),this.At=$i.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}(me);me.registerComponent("LiveDisplay",_h);var xh=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}ke(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=zi({tabIndex:0},s),e=zi({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(),$i.body.focus(),$i.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;$i.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=_s(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}(me);function Ch(t,i){if(!t||!i)return"";if("function"==typeof b.getComputedStyle){var s=b.getComputedStyle(t);return s?s[i]:""}return t.currentStyle[i]||""}me.registerComponent("Slider",xh);var Sh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Nt=[],e.on(i,"progress",e.update),e.on(i,"languagechange",e.handleLanguagechange),e}ke(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-load-progress"});return this.Et=rs("span",{innerHTML:this.localize("Loaded")}),this.Bt=$i.createTextNode(": 0%"),this.Ct=rs("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.Et),this.Ct.appendChild(this.Bt),i.appendChild(this.Ct),i},s.update=function(t){var i=this.t.buffered(),s=this.t.duration(),e=this.t.bufferedEnd(),n=this.Nt,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(rs()),n[h]=u),u.style.left=r(o,e),u.style.width=r(a-o,e)}for(var c=n.length;c>i.length;c--)this.v.removeChild(n[c-1]);n.length=i.length},s.handleLanguagechange=function(){this.Et.innerHTML=this.localize("Loaded")},i}(me);me.registerComponent("LoadProgressBar",Sh);var jh=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(n(ye(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}ke(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this,"div",{className:"vjs-play-progress vjs-slider-bar"});return this.It=rs("span",{innerHTML:this.localize("Progress")}),this.Ft=$i.createTextNode(": 0%"),this.Ct=rs("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.It),this.Ct.appendChild(this.Ft),i.appendChild(this.Ct),i},s.updateDataAttr=function(t){var i=this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime();this.v.setAttribute("data-current-time",gh(i,this.t.duration()))},s.handleLanguagechange=function(){this.It.innerHTML=this.localize("Progress")},i}(me);me.registerComponent("PlayProgressBar",jh);var Th=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(n(ye(e),e.updateDataAttr)),e}ke(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=rs("div",{className:"vjs-time-tooltip"}),this.It=rs("span",{innerHTML:this.localize("Progress")}),this.Ft=$i.createTextNode(": 0%"),this.Ct=rs("span",{className:"vjs-control-text"}),this.Ct.appendChild(this.It),this.Ct.appendChild(this.Ft),i.appendChild(this.tooltip),i.appendChild(this.Ct),i},s.updateDataAttr=function(t){var i=gh(this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime(),this.t.duration());this.v.setAttribute("data-current-time",i),this.tooltip.innerHTML=i},s.handleLanguagechange=function(){this.It.innerHTML=this.localize("Progress")},i}(me);me.registerComponent("TooltipProgressBar",Th);var Mh=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(n(ye(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}ke(i,t);var s=i.prototype;return s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-holder"},{"aria-label":"progress bar"})},s.updateProgress=function(t){if(this.updateAriaAttributes(this.v),this.keepTooltipsInside){this.updateAriaAttributes(this.tooltipProgressBar.v),this.tooltipProgressBar.v.style.width=this.bar.v.style.width;var i=C(Ch(this.player().el(),"width")),s=C(Ch(this.tooltipProgressBar.tooltip,"width")),e=this.tooltipProgressBar.el().style;e.maxWidth=_.floor(i-s/2)+"px",e.minWidth=_.ceil(s/2)+"px",e.right="-"+s/2+"px"}},s.updateAriaAttributes=function(t){var i=this.t.scrubbing()?this.t.getCache().currentTime:this.t.currentTime();t.setAttribute("aria-valuenow",(100*this.getPercent()).toFixed(2)),t.setAttribute("aria-valuetext",gh(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}(xh);Mh.prototype.h={children:["loadProgressBar","mouseTimeDisplay","playProgressBar"],barName:"playProgressBar"},Mh.prototype.playerEvent="timeupdate",me.registerComponent("SeekBar",Mh);var Ah=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=rs("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)}}(n(ye(e),e.handleMouseMove),25))}),e}ke(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-ws(this.el().parentNode).left;this.update(s,e)},s.update=function(t,i){var s=gh(t,this.t.duration());if(this.el().style.left=i+"px",this.el().setAttribute("data-current-time",s),this.keepTooltipsInside){var e=i-this.Dt(i)+1,n=C(Ch(this.tooltip,"width"))/2;this.tooltip.innerHTML=s,this.tooltip.style.right="-"+(n-e)+"px"}},s.calculateDistance=function(t){return _s(this.el().parentNode,t).x},s.Dt=function(t){if(!this.keepTooltipsInside)return t;var i=C(Ch(this.player().el(),"width")),s=C(Ch(this.tooltip,"width"))/2,e=t;return t<s?e=_.ceil(s):t>i-s&&(e=_.floor(i-s)),e},i}(me);me.registerComponent("MouseTimeDisplay",Ah);var Ph=function(t){function i(){return t.apply(this,arguments)||this}return ke(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},i}(me);Ph.prototype.h={children:["seekBar"]},me.registerComponent("ProgressControl",Ph);var Nh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"fullscreenchange",e.handleFullscreenChange),e}ke(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}(fh);Nh.prototype.St="Fullscreen",me.registerComponent("FullscreenToggle",Nh);var Eh=function(t){function i(){return t.apply(this,arguments)||this}return ke(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}(me);me.registerComponent("VolumeLevel",Eh);var Bh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.updateARIAAttributes),i.ready(n(ye(e),e.updateARIAAttributes)),e}ke(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}(xh);Bh.prototype.h={children:["volumeLevel"],barName:"volumeLevel"},Bh.prototype.playerEvent="volumechange",me.registerComponent("VolumeBar",Bh);var Ih=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 ke(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control"})},i}(me);Ih.prototype.h={children:["volumeBar"]},me.registerComponent("VolumeControl",Ih);var Fh=function(t){function i(){return t.apply(this,arguments)||this}ke(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",n(this,function(){this.unlockShowing()}))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=rs(i,{className:"vjs-menu-content"});var s=t.prototype.createEl.call(this,"div",{append:this.S,className:"vjs-menu"});return s.appendChild(this.S),ne(s,"click",function(t){t.preventDefault(),t.stopImmediatePropagation()}),s},i}(me);me.registerComponent("Popup",Fh);var Dh=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e}ke(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}(rh);me.registerComponent("PopupButton",Dh);var $h=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}ke(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++)ps(this.v,"vjs-vol-"+n);vs(this.v,"vjs-vol-"+s)},i}(fh);$h.prototype.St="Mute",me.registerComponent("MuteToggle",$h);var Uh=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(ye(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}ke(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 Fh(this.t,{contentElType:"div"}),i=new Bh(this.t,this.h.volumeBar);return t.addChild(i),this.menuContent=t,this.volumeBar=i,this.attachVolumeBarEvents(),t},s.handleClick=function(i){$h.prototype.handleClick.call(this),t.prototype.handleClick.call(this)},s.attachVolumeBarEvents=function(){this.menuContent.on(["mousedown","touchdown"],n(this,this.handleMouseDown))},s.handleMouseDown=function(t){this.on(["mousemove","touchmove"],n(this.volumeBar,this.volumeBar.handleMouseMove)),this.on(this.v.ownerDocument,["mouseup","touchend"],this.handleMouseUp)},s.handleMouseUp=function(t){this.off(["mousemove","touchmove"],n(this.volumeBar,this.volumeBar.handleMouseMove))},i}(Dh);Uh.prototype.volumeUpdate=$h.prototype.update,Uh.prototype.St="Mute",me.registerComponent("VolumeMenuButton",Uh);var Rh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).$t=-1,e.on("keydown",e.handleKeyPress),e}ke(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",n(this,function(t){this.unlockShowing()}))},s.createEl=function(){var i=this.h.contentElType||"ul";this.S=rs(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),ne(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}(me);me.registerComponent("Menu",Rh);var Oh=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e.Ut=!0,e.v.setAttribute("aria-haspopup","true"),e.v.setAttribute("role","menuitem"),e.on("keydown",e.handleSubmenuKeyPress),e}ke(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.Rt=!1,this.v.setAttribute("aria-expanded","false"),this.items&&this.items.length<=this.Ot?this.hide():this.show()},s.createMenu=function(){var t=new Rh(this.t);if(this.Ot=0,this.h.title){var i=rs("li",{className:"vjs-menu-title",innerHTML:ve(this.h.title),tabIndex:-1});this.Ot+=1,t.m.unshift(i),os(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",n(this,function(t){this.unpressButton(),this.v.blur()})),this.Rt?this.unpressButton():this.pressButton()},s.handleKeyPress=function(i){27===i.which||9===i.which?(this.Rt&&this.unpressButton(),9!==i.which&&i.preventDefault()):38===i.which||40===i.which?this.Rt||(this.pressButton(),i.preventDefault()):t.prototype.handleKeyPress.call(this,i)},s.handleSubmenuKeyPress=function(t){27!==t.which&&9!==t.which||(this.Rt&&this.unpressButton(),9!==t.which&&t.preventDefault())},s.pressButton=function(){this.Ut&&(this.Rt=!0,this.menu.lockShowing(),this.v.setAttribute("aria-expanded","true"),this.menu.focus())},s.unpressButton=function(){this.Ut&&(this.Rt=!1,this.menu.unlockShowing(),this.v.setAttribute("aria-expanded","false"),this.v.focus())},s.disable=function(){return this.Rt=!1,this.menu.unlockShowing(),this.v.setAttribute("aria-expanded","false"),this.Ut=!1,t.prototype.disable.call(this)},s.enable=function(){return this.Ut=!0,t.prototype.enable.call(this)},i}(rh);me.registerComponent("MenuButton",Oh);var Vh=function(t){function i(i,s){var e,r=s.tracks;if((e=t.call(this,i,s)||this).items.length<=1&&e.hide(),!r)return ye(e);var h=n(ye(e),e.update);return r.addEventListener("removetrack",h),r.addEventListener("addtrack",h),e.t.on("dispose",function(){r.removeEventListener("removetrack",h),r.removeEventListener("addtrack",h)}),e}return ke(i,t),i}(Oh);me.registerComponent("TrackButton",Vh);var Lh=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}ke(i,t);var s=i.prototype;return s.createEl=function(i,s,e){this.nonIconControl=!0;var n=t.prototype.createEl.call(this,"li",zi({className:"vjs-menu-item",tabIndex:-1},s),e);return this.Vt=$i.createTextNode(this.localize(this.h.label)),n.appendChild(this.Vt),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.Vt.innerHTML=this.localize(this.h.label)},i}(rh);me.registerComponent("MenuItem",Lh);var Hh=function(t){function i(i,s){var e,r,h=s.track,o=i.textTracks();if(s.label=h.label||h.language||"Unknown",s.selected=h.default||"showing"===h.mode,(e=t.call(this,i,s)||this).track=h,o){var a=n(ye(e),e.handleTracksChange);i.on(["loadstart","texttrackchange"],a),o.addEventListener("change",a),e.on("dispose",function(){o.removeEventListener("change",a)})}o&&void 0===o.onchange&&e.on(["tap","click"],function(){if("object"!=typeof b.Event)try{r=new b.Event("change")}catch(t){}r||(r=$i.createEvent("Event")).initEvent("change",!0,!0),o.dispatchEvent(r)});return e}ke(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}(Lh);me.registerComponent("TextTrackMenuItem",Hh);var qh=function(t){function i(i,s){var e;return s.track={player:i,kind:s.kind,label:s.kind+" off",default:!1,mode:"disabled"},s.selectable=!0,(e=t.call(this,i,s)||this).selected(!0),e}return ke(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}(Hh);me.registerComponent("OffTextTrackMenuItem",qh);var zh=function(t){function i(i,s){return void 0===s&&(s={}),s.tracks=i.textTracks(),t.call(this,i,s)||this}return ke(i,t),i.prototype.createItems=function(t){void 0===t&&(t=[]),t.push(new qh(this.t,{kind:this.Lt})),this.Ot+=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.Lt&&t.push(new Hh(this.t,{track:e,selectable:!0}))}return t},i}(Vh);me.registerComponent("TextTrackButton",zh);var Wh=function(t){function i(i,s){var e,r=s.track,h=s.cue,o=i.currentTime();return s.selectable=!0,s.label=h.text,s.selected=h.startTime<=o&&o<h.endTime,(e=t.call(this,i,s)||this).track=r,e.cue=h,r.addEventListener("cuechange",n(ye(e),e.update)),e}ke(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}(Lh);me.registerComponent("ChaptersTrackMenuItem",Wh);var Gh=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}ke(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-chapters-button "+t.prototype.buildCSSClass.call(this)},s.update=function(i){this.Ht&&(!i||"addtrack"!==i.type&&"removetrack"!==i.type)||this.setTrack(this.findChaptersTrack()),t.prototype.update.call(this)},s.setTrack=function(t){if(this.Ht!==t){if(this.qt||(this.qt=this.update.bind(this)),this.Ht){var i=this.t.remoteTextTrackEls().Y(this.Ht);i&&i.removeEventListener("load",this.qt),this.Ht=null}if(this.Ht=t,this.Ht){this.Ht.mode="hidden";var s=this.t.remoteTextTrackEls().Y(this.Ht);s&&s.addEventListener("load",this.qt)}}},s.findChaptersTrack=function(){for(var t=this.t.textTracks()||[],i=t.length-1;i>=0;i--){var s=t[i];if(s.kind===this.Lt)return s}},s.getMenuCaption=function(){return this.Ht&&this.Ht.label?this.Ht.label:this.localize(ve(this.Lt))},s.createMenu=function(){return this.h.title=this.getMenuCaption(),t.prototype.createMenu.call(this)},s.createItems=function(){var t=[];if(!this.Ht)return t;var i=this.Ht.cues;if(!i)return t;for(var s=0,e=i.length;s<e;s++){var n=i[s],r=new Wh(this.t,{track:this.Ht,cue:n});t.push(r)}return t},i}(zh);Gh.prototype.Lt="chapters",Gh.prototype.St="Chapters",me.registerComponent("ChaptersButton",Gh);var Xh=function(t){function i(i,s,e){var r;(r=t.call(this,i,s,e)||this).v.setAttribute("aria-label","Descriptions Menu");var h=i.textTracks();if(h){var o=n(ye(r),r.handleTracksChange);h.addEventListener("change",o),r.on("dispose",function(){h.removeEventListener("change",o)})}return r}ke(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.Lt&&"showing"===r.mode){s=!0;break}}s?this.disable():this.enable()},s.buildCSSClass=function(){return"vjs-descriptions-button "+t.prototype.buildCSSClass.call(this)},i}(zh);Xh.prototype.Lt="descriptions",Xh.prototype.St="Descriptions",me.registerComponent("DescriptionsButton",Xh);var Jh=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 ke(i,t),i.prototype.buildCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildCSSClass.call(this)},i}(zh);Jh.prototype.Lt="subtitles",Jh.prototype.St="Subtitles",me.registerComponent("SubtitlesButton",Jh);var Qh=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 ke(i,t),i.prototype.handleClick=function(t){this.player().getChild("textTrackSettings").show(),this.player().getChild("textTrackSettings").v.focus()},i}(Hh);me.registerComponent("CaptionSettingsMenuItem",Qh);var Yh=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}ke(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 Qh(this.t,{kind:this.Lt})),this.Ot+=1),t.prototype.createItems.call(this,i)},i}(zh);Yh.prototype.Lt="captions",Yh.prototype.St="Captions",me.registerComponent("CaptionsButton",Yh);var Kh=function(t){function i(i,s){var e,r=s.track,h=i.audioTracks();if(s.label=r.label||r.language||"Unknown",s.selected=r.enabled,(e=t.call(this,i,s)||this).track=r,h){var o=n(ye(e),e.handleTracksChange);h.addEventListener("change",o),e.on("dispose",function(){h.removeEventListener("change",o)})}return e}ke(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}(Lh);me.registerComponent("AudioTrackMenuItem",Kh);var Zh=function(t){function i(i,s){var e;return void 0===s&&(s={}),s.tracks=i.audioTracks&&i.audioTracks(),(e=t.call(this,i,s)||this).v.setAttribute("aria-label","Audio Menu"),e}ke(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.Ot=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 Kh(this.t,{track:e,selectable:!0}))}return t},i}(Vh);Zh.prototype.St="Audio Track",me.registerComponent("AudioTrackButton",Zh);var to=function(t){function i(i,s){var e,n=s.rate,r=C(n,10);return s.label=n,s.selected=1===r,s.selectable=!0,(e=t.call(this,i,s)||this).label=n,e.rate=r,e.on(i,"ratechange",e.update),e}ke(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}(Lh);to.prototype.contentElType="button",me.registerComponent("PlaybackRateMenuItem",to);var io=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}ke(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this);return this.Vt=rs("div",{className:"vjs-playback-rate-value",innerHTML:1}),i.appendChild(this.Vt),i},s.buildCSSClass=function(){return"vjs-playback-rate "+t.prototype.buildCSSClass.call(this)},s.createMenu=function(){var t=new Rh(this.player()),i=this.playbackRates();if(i)for(var s=i.length-1;s>=0;s--)t.addChild(new to(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.Vt.innerHTML=this.player().playbackRate()+"x")},i}(Oh);io.prototype.St="Playback Rate",me.registerComponent("PlaybackRateMenuButton",io);var so=function(t){function i(){return t.apply(this,arguments)||this}ke(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}(me);me.registerComponent("Spacer",so);var eo=function(t){function i(){return t.apply(this,arguments)||this}ke(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="&nbsp;",i},i}(so);me.registerComponent("CustomControlSpacer",eo);var no=function(t){function i(){return t.apply(this,arguments)||this}return ke(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"},{role:"group"})},i}(me);no.prototype.h={children:["playToggle","volumeMenuButton","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subtitlesButton","captionsButton","audioTrackButton","fullscreenToggle"]},me.registerComponent("ControlBar",no);var ro=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"error",e.open),e}ke(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}(Ue);ro.prototype.h=pe(Ue.prototype.h,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),me.registerComponent("ErrorDisplay",ro);var ho="vjs-text-track-settings",oo=["#000","Black"],ao=["#00F","Blue"],uo=["#0FF","Cyan"],co=["#0F0","Green"],lo=["#F0F","Magenta"],fo=["#F00","Red"],vo=["#FFF","White"],po=["#FF0","Yellow"],mo=["1","Opaque"],go=["0.5","Semi-Transparent"],yo=["0","Transparent"],bo={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[oo,vo,fo,co,ao,po,lo,uo]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[mo,go,yo]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[vo,oo,fo,co,ao,po,lo,uo]},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:[mo,go]},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:[yo,go,mo]}};function ko(t,i){if(i&&(t=i(t)),t&&"none"!==t)return t}bo.windowColor.options=bo.backgroundColor.options;var wo,_o=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).setDefaults(),e.hide(),e.updateDisplay=n(ye(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()}),qi(bo,function(t){e.on(e.$(t.selector),"change",e.updateDisplay)}),e.h.persistTextTrackSettings&&e.restoreSettings(),e}ke(i,t);var s=i.prototype;return s.zt=function(t){var i=this,s=bo[t],e=s.id.replace("%s",this.o);return[rs("label",{className:"vjs-label",textContent:s.label},{for:e}),rs("select",{id:e},void 0,s.options.map(function(t){return rs("option",{textContent:i.localize(t[1]),value:t[0]})}))]},s.Wt=function(){var t=rs("legend",{textContent:this.localize("Text")}),i=this.zt("color"),s=rs("span",{className:"vjs-text-opacity vjs-opacity"},void 0,this.zt("textOpacity"));return rs("fieldset",{className:"vjs-fg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Gt=function(){var t=rs("legend",{textContent:this.localize("Background")}),i=this.zt("backgroundColor"),s=rs("span",{className:"vjs-bg-opacity vjs-opacity"},void 0,this.zt("backgroundOpacity"));return rs("fieldset",{className:"vjs-bg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Xt=function(){var t=rs("legend",{textContent:this.localize("Window")}),i=this.zt("windowColor"),s=rs("span",{className:"vjs-window-opacity vjs-opacity"},void 0,this.zt("windowOpacity"));return rs("fieldset",{className:"vjs-window-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Jt=function(){return rs("div",{className:"vjs-tracksettings-colors"},void 0,[this.Wt(),this.Gt(),this.Xt()])},s.Qt=function(){var t=rs("div",{className:"vjs-font-percent vjs-tracksetting"},void 0,this.zt("fontPercent")),i=rs("div",{className:"vjs-edge-style vjs-tracksetting"},void 0,this.zt("edgeStyle")),s=rs("div",{className:"vjs-font-family vjs-tracksetting"},void 0,this.zt("fontFamily"));return rs("div",{className:"vjs-tracksettings-font"},void 0,[t,i,s])},s.Yt=function(){var t=rs("button",{className:"vjs-default-button",textContent:this.localize("Defaults")}),i=rs("button",{className:"vjs-done-button",textContent:"Done"});return rs("div",{className:"vjs-tracksettings-controls"},void 0,[t,i])},s.createEl=function(){var t=rs("div",{className:"vjs-tracksettings"},void 0,[this.Jt(),this.Qt(),this.Yt()]),i=rs("div",{className:"vjs-control-text",id:"TTsettingsDialogLabel-"+this.o,textContent:"Caption Settings Dialog"},{"aria-level":"1",role:"heading"}),s=rs("div",{className:"vjs-control-text",id:"TTsettingsDialogDescription-"+this.o,textContent:"Beginning of dialog window. Escape will cancel and close the window."}),e=rs("div",void 0,{role:"document"},[i,s,t]);return rs("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),Hi(t).reduce(function(s,e){return i(s,t[e],e)},s)}(bo,function(i,s,e){var n=function(t,i){return ko(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;qi(bo,function(s,e){!function(t,i,s){if(i)for(var e=0;e<t.options.length;e++)if(ko(t.options[e].value,s)===i){t.selectedIndex=e;break}}(i.$(s.selector),t[e],s.parser)})},s.setDefaults=function(){var t=this;qi(bo,function(i){var s=i.hasOwnProperty("default")?i.default:0;t.$(i.selector).selectedIndex=s})},s.restoreSettings=function(){var t;try{t=JSON.parse(b.localStorage.getItem(ho))}catch(t){Ji.warn(t)}t&&this.setValues(t)},s.saveSettings=function(){if(this.h.persistTextTrackSettings){var t=this.getValues();try{w.keys(t).length?b.localStorage.setItem(ho,JSON.stringify(t)):b.localStorage.removeItem(ho)}catch(t){Ji.warn(t)}}},s.updateDisplay=function(){var t=this.t.getChild("textTrackDisplay");t&&t.updateDisplay()},i}(me);me.registerComponent("TextTrackSettings",_o);var xo,Co=function(t){function i(i,s){var e;e=t.call(this,i,s)||this;var r=i.source,h=!1;if(r&&(e.v.currentSrc!==r.src||i.tag&&3===i.tag.Kt)?e.setSource(r):e.Zt(e.v),e.v.hasChildNodes()){for(var o=e.v.childNodes,a=o.length,u=[];a--;){var c=o[a];"track"===c.nodeName.toLowerCase()&&(e.featuresNativeTextTracks?(e.remoteTextTrackEls().J(c),e.remoteTextTracks().tt(c.track),h||e.v.hasAttribute("crossorigin")||!We(c.src)||(h=!0)):u.push(c))}for(var l=0;l<u.length;l++)e.v.removeChild(u[l])}return["audio","video"].forEach(function(t){var i=e.el()[t+"Tracks"],s=e[t+"Tracks"](),n=ve(t);e["featuresNative"+n+"Tracks"]&&i&&i.addEventListener&&(e["handle"+n+"ti"]=function(t){s.trigger({type:"change",target:s,currentTarget:s,srcElement:s})},e["handle"+n+"ii"]=function(t){return s.addTrack(t.track)},e["handle"+n+"si"]=function(t){return s.removeTrack(t.track)},i.addEventListener("change",e["handle"+n+"ti"]),i.addEventListener("addtrack",e["handle"+n+"ii"]),i.addEventListener("removetrack",e["handle"+n+"si"]),e["removeOld"+n+"ei"]=function(t){return e.ni(s,i)},e.on("loadstart",e["removeOld"+n+"ei"]))}),e.featuresNativeTextTracks&&(h&&Ji.warn(Zi(wo||(wo=Ui(["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=n(ye(e),e.handleTextTrackChange),e.hi=n(ye(e),e.handleTextTrackAdd),e.oi=n(ye(e),e.handleTextTrackRemove),e.ai()),e.ci(),(Qs||Is||Vs)&&!0===i.nativeControlsForTouch&&e.setControls(!0),e.di(),e.triggerReady(),e}ke(i,t);var s=i.prototype;return s.dispose=function(){var s=this;["audio","video","text"].forEach(function(t){var i=ve(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=$i.createElement("video");var e=pe({},this.h.tag&&ys(this.h.tag));Qs&&!0===this.h.nativeControlsForTouch||delete e.controls,gs(t,zi(e,{id:this.h.techId,class:"vjs-tech"}))}t.playerId=this.h.playerId}void 0!==this.h.preload&&bs(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?bs(t,h,h):ks(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){Ji(t,"Video is not ready. (Video.js)")}},s.duration=function(){var t=this;if(this.v.duration===1/0&&Us&&qs&&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=b.navigator&&b.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=$i.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),b.performance&&"function"==typeof b.performance.now?t.creationTime=b.performance.now():b.performance&&b.performance.timing&&"number"==typeof b.performance.timing.navigationStart&&(t.creationTime=b.Date.now()-b.performance.timing.navigationStart),t},i}(eh);ss()&&(Co.TEST_VID=$i.createElement("video"),(xo=$i.createElement("track")).kind="captions",xo.srclang="en",xo.label="English",Co.TEST_VID.appendChild(xo)),Co.isSupported=function(){try{Co.TEST_VID.volume=.5}catch(t){return!1}return!(!Co.TEST_VID||!Co.TEST_VID.canPlayType)},Co.canControlVolume=function(){try{var t=Co.TEST_VID.volume;return Co.TEST_VID.volume=t/2+.1,t!==Co.TEST_VID.volume}catch(t){return!1}},Co.canControlPlaybackRate=function(){if(Us&&qs&&zs<58)return!1;try{var t=Co.TEST_VID.playbackRate;return Co.TEST_VID.playbackRate=t/2+.1,t!==Co.TEST_VID.playbackRate}catch(t){return!1}},Co.supportsNativeTextTracks=function(){return Js},Co.supportsNativeVideoTracks=function(){return!(!Co.TEST_VID||!Co.TEST_VID.videoTracks)},Co.supportsNativeAudioTracks=function(){return!(!Co.TEST_VID||!Co.TEST_VID.audioTracks)},Co.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange"],Co.prototype.featuresVolumeControl=Co.canControlVolume(),Co.prototype.featuresPlaybackRate=Co.canControlPlaybackRate(),Co.prototype.movingMediaElementInDOM=!Ds,Co.prototype.featuresFullscreenResize=!0,Co.prototype.featuresProgressEvents=!0,Co.prototype.featuresTimeupdateEvents=!0,Co.prototype.featuresNativeTextTracks=Co.supportsNativeTextTracks(),Co.prototype.featuresNativeVideoTracks=Co.supportsNativeVideoTracks(),Co.prototype.featuresNativeAudioTracks=Co.supportsNativeAudioTracks();var So=Co.TEST_VID&&Co.TEST_VID.constructor.prototype.canPlayType,jo=/^application\/(?:x-|vnd\.apple\.)mpegurl/i,To=/^video\/mp4/i;Co.patchCanPlayType=function(){Rs>=4&&!Ls?Co.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&jo.test(t)?"maybe":So.call(this,t)}:Os&&(Co.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&To.test(t)?"maybe":So.call(this,t)})},Co.unpatchCanPlayType=function(){var t=Co.TEST_VID.constructor.prototype.canPlayType;return Co.TEST_VID.constructor.prototype.canPlayType=So,t},Co.patchCanPlayType(),Co.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){}}()}}},Co.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){Co.prototype[t]=function(){return this.v[t]||this.v.hasAttribute(t)}}),["muted","defaultMuted","autoplay","loop","playsinline"].forEach(function(t){Co.prototype["set"+ve(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){Co.prototype[t]=function(){return this.v[t]}}),["volume","src","poster","preload","playbackRate"].forEach(function(t){Co.prototype["set"+ve(t)]=function(i){this.v[t]=i}}),["pause","load"].forEach(function(t){Co.prototype[t]=function(){return this.v[t]()}}),eh.withSourceHandlers(Co),Co.nativeSourceHandler={},Co.nativeSourceHandler.canPlayType=function(t){try{return Co.TEST_VID.canPlayType(t)}catch(t){return""}},Co.nativeSourceHandler.canHandleSource=function(t,i){if(t.type)return Co.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 Co.nativeSourceHandler.canPlayType("video/"+s)}return""},Co.nativeSourceHandler.handleSource=function(t,i,s){i.setSrc(t.src)},Co.nativeSourceHandler.dispose=function(){},Co.registerSourceHandler(Co.nativeSourceHandler),me.registerComponent("Html5",Co),eh.registerTech("Html5",Co);var Mo=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","ratechange","volumechange","texttrackchange"],Ao=function(t){function i(s,e,n){var r;if(s.id=s.id||["vjs_video",Oi()].join("_"),(e=zi(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(ys(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 m("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&&ys(s),r.language(r.h.language),e.languages){var a={};w.getOwnPropertyNames(e.languages).forEach(function(t){a[t.toLowerCase()]=e.languages[t]}),r.pi=a}else r.pi=i.prototype.h.languages;r.mi={},r.gi=e.poster||"",r.yi=!!e.controls,s.controls=!1,r.bi=!1,r.v=r.createEl();var u=pe(r.h);if(e.plugins){var c=e.plugins;w.getOwnPropertyNames(c).forEach(function(t){"function"==typeof this[t]?this[t](c[t]):Ji.error("Unable to find plugin:",t)},ye(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.ki()&&r.addClass("vjs-no-flex"),Ds||r.addClass("vjs-workinghover"),i.players[r.o]=ye(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._i),r.on("stageclick",r.xi),r}ke(i,t);var s=i.prototype;return s.dispose=function(){this.trigger("dispose"),this.off("dispose"),this.Ci&&this.Ci.parentNode&&this.Ci.parentNode.removeChild(this.Ci),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.Si=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=ys(s);if(w.getOwnPropertyNames(n).forEach(function(t){"class"===t?i.className+=" "+n[t]:i.setAttribute(t,n[t])}),s.playerId=s.id,s.id+="ji",s.className="vjs-tech",s.player=i.player=this,this.addClass("vjs-paused"),!0!==b.VIDEOJS_NO_DYNAMIC_STYLE){this.Ci=de("vjs-styles-dimensions");var r=Ms(".vjs-styles-defaults"),h=Ms("head");h.insertBefore(this.Ci,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);vs(u,"vjs-hidden"),u.setAttribute("hidden","hidden")}return s.Kt=s.networkState,s.parentNode&&!e&&s.parentNode.insertBefore(i,s),os(s,i),this.m.unshift(s),this.v=i,i},s.width=function(t){return this.dimension("width",t)},s.height=function(t){return this.dimension("height",t)},s.dimension=function(t,i){var s="width"===t?"Ti":"Mi";if(void 0===i)return this[s]||0;if(""===i)this[s]=void 0;else{var e=C(i);if(S(e))return Ji.error('Improper value "'+i+'" supplied for for '+t),this;this[s]=e}return this.Ai(),this},s.fluid=function(t){if(void 0===t)return!!this.Pi;this.Pi=!!t,t?this.addClass("vjs-fluid"):this.removeClass("vjs-fluid"),this.Ai()},s.aspectRatio=function(t){if(void 0===t)return this.Ni;if(!/^\d+\:\d+$/.test(t))throw new m("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.Ni=t,this.fluid(!0),this.Ai()},s.Ai=function(){if(!0!==b.VIDEOJS_NO_DYNAMIC_STYLE){var t,i,s,e=(void 0!==this.Ni&&"auto"!==this.Ni?this.Ni:this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9").split(":"),n=e[1]/e[0];t=void 0!==this.Ti?this.Ti:void 0!==this.Mi?this.Mi/n:this.videoWidth()||300,i=void 0!==this.Mi?this.Mi:t*n,s=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(s),fe(this.Ci,"\n ."+s+" {\n width: "+t+"px;\n height: "+i+"px;\n }\n\n ."+s+".vjs-fluid {\n padding-top: "+100*n+"%;\n }\n ")}else{var r="number"==typeof this.Ti?this.Ti:this.h.width,h="number"==typeof this.Mi?this.Mi: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&&(eh.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.Bi=t,this.j=!1;var e=zi({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.Si||!1,"vtt.js":this.h["vtt.js"]},this.h[t.toLowerCase()]);this.tag&&(e.tag=this.tag),i&&(this.Fi=i.type,i.src===this.mi.src&&this.mi.currentTime>0&&(e.startTime=this.mi.currentTime),this.mi.sources=null,this.mi.source=i,this.mi.src=i.src);var r=eh.getTech(t);r||(r=me.getComponent(t)),this.H=new r(e),this.H.ready(n(this,this.Di),!0),De(this.$i||[],this.H),Mo.forEach(function(t){s.on(s.H,t,s["handleTech"+ve(t)+"_"])}),this.on(this.H,"loadstart",this.Ui),this.on(this.H,"waiting",this.Ri),this.on(this.H,"canplay",this.Oi),this.on(this.H,"canplaythrough",this.Vi),this.on(this.H,"playing",this.Li),this.on(this.H,"ended",this.Hi),this.on(this.H,"seeking",this.qi),this.on(this.H,"seeked",this.zi),this.on(this.H,"play",this.Wi),this.on(this.H,"firstplay",this.Gi),this.on(this.H,"pause",this.Xi),this.on(this.H,"durationchange",this.Ji),this.on(this.H,"fullscreenchange",this.Qi),this.on(this.H,"error",this.Yi),this.on(this.H,"loadedmetadata",this.Ai),this.on(this.H,"resize",this.Ai),this.on(this.H,"posterchange",this.Ki),this.on(this.H,"textdata",this.Zi),this.usingNativeControls(this.ts("controls")),this.controls()&&!this.usingNativeControls()&&this.ss(),this.H.el().parentNode===this.contentEl()||"Html5"===t&&this.tag||os(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.$i=Fe(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 b.alert(i),new m(i)},s.ss=function(){this.es(),this.on(this.H,"mousedown",this.ns),this.on(this.H,"touchstart",this.rs),this.on(this.H,"touchmove",this.hs),this.on(this.H,"touchend",this.us),this.on(this.H,"tap",this.cs)},s.es=function(){this.off(this.H,"tap",this.cs),this.off(this.H,"touchstart",this.rs),this.off(this.H,"touchmove",this.hs),this.off(this.H,"touchend",this.us),this.off(this.H,"mousedown",this.ns)},s.Di=function(){if(this.triggerReady(),this.mi.volume&&this.ls("setVolume",this.mi.volume),this.Ki(),this.Ji(),(this.src()||this.currentSrc())&&this.tag&&this.h.autoplay&&this.paused()){try{delete this.tag.poster}catch(t){Ji("deleting tag.poster throws in some browsers",t)}this.play()}},s.Ui=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-seeking"),this.error(null),this.paused()?(this.hasStarted(!1),this.trigger("loadstart")):(this.trigger("loadstart"),this.trigger("firstplay"))},s.hasStarted=function(t){return void 0!==t?(this.et!==t&&(this.et=t,t?(this.addClass("vjs-has-started"),this.trigger("firstplay")):this.removeClass("vjs-has-started")),this):!!this.et},s.Wi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},s.Ri=function(){var t=this;this.addClass("vjs-waiting"),this.trigger("waiting"),this.one("timeupdate",function(){return t.removeClass("vjs-waiting")})},s.Oi=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},s.Vi=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},s.Li=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},s.qi=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},s.zi=function(){this.removeClass("vjs-seeking"),this.trigger("seeked")},s.Gi=function(){this.h.starttime&&(Ji.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.Xi=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},s.Hi=function(){this.addClass("vjs-ended"),this.h.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},s.Ji=function(){this.duration(this.ts("duration"))},s.ns=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.cs=function(){this.userActive(!this.userActive())},s.rs=function(){this.userWasActive=this.userActive()},s.hs=function(){this.userWasActive&&this.reportUserActivity()},s.us=function(t){t.cancelable&&t.preventDefault()},s._i=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},s.xi=function(){this.reportUserActivity()},s.Qi=function(t,i){i&&(this.toggleClass("vjs-ios-native-fs",!(!i.nativeIOSFullscreen||!i.isFullscreen)),this.isFullscreen(i.isFullscreen)),this.trigger("fullscreenchange")},s.Yi=function(){var t=this.H.error();this.error(t)},s.Zi=function(){var t=null;arguments.length>1&&(t=arguments[1]),this.trigger("textdata",t)},s.getCache=function(){return this.mi},s.ls=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 Ji(t),t}},s.ts=function(t){if(this.H&&this.H.j)try{return this.H[t]()}catch(i){throw void 0===this.H[t]?Ji("Video.js: "+t+" method not defined for "+this.Bi+" playback technology.",i):"TypeError"===i.name?(Ji("Video.js: "+t+" unavailable on "+this.Bi+" playback technology element.",i),this.H.j=!1):Ji(i),i}},s.play=function(){return this.src()||this.currentSrc()?this.ls("play"):this.H.one("loadstart",function(){this.play()}),this},s.pause=function(){return this.ls("pause"),this},s.paused=function(){return!1!==this.ts("paused")},s.scrubbing=function(t){return void 0!==t?(this.bi=!!t,t?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing"),this):this.bi},s.currentTime=function(t){return void 0!==t?(this.ls("setCurrentTime",t),this):(this.mi.currentTime=this.ts("currentTime")||0,this.mi.currentTime)},s.duration=function(t){return void 0===t?void 0!==this.mi.duration?this.mi.duration:NaN:((t=C(t))<0&&(t=1/0),t!==this.mi.duration&&(this.mi.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.ts("buffered");return t&&t.length||(t=xe(0,0)),t},s.bufferedPercent=function(){return Ce(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=_.max(0,_.min(1,C(t))),this.mi.volume=i,this.ls("setVolume",i),this):(i=C(this.ts("volume")),S(i)?1:i)},s.muted=function(t){return void 0!==t?(this.ls("setMuted",t),this):this.ts("muted")||!1},s.supportsFullScreen=function(){return this.ts("supportsFullScreen")||!1},s.isFullscreen=function(t){return void 0!==t?(this.ds=!!t,this):!!this.ds},s.requestFullscreen=function(t){var i,s=Ae;return this.isFullscreen(!0),s.requestFullscreen?(ne($i,s.fullscreenchange,n(this,function t(i){this.isFullscreen($i[s.fullscreenElement]),!1===this.isFullscreen()&&re($i,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.ls("enterFullScreen"):(this.enterFullWindow(),this.trigger("fullscreenchange")),this},s.exitFullscreen=function(){var t=Ae;return this.isFullscreen(!1),t.requestFullscreen?$i[t.exitFullscreen]():this.H.supportsFullScreen()?this.ls("exitFullScreen"):(this.exitFullWindow(),this.trigger("fullscreenchange")),this},s.enterFullWindow=function(){this.isFullWindow=!0,this.docOrigOverflow=$i.documentElement.style.overflow,ne($i,"keydown",n(this,this.fullWindowOnEscKey)),$i.documentElement.style.overflow="hidden",vs($i.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,re($i,"keydown",this.fullWindowOnEscKey),$i.documentElement.style.overflow=this.docOrigOverflow,ps($i.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=ve(e[s]),r=eh.getTech(n);if(r||(r=me.getComponent(n)),r){if(r.isSupported()&&(i=r.canPlayType(t)))return i}else Ji.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(ve).map(function(t){return[t,eh.getTech(t)||me.getComponent(t)]}).filter(function(t){var i=t[0],s=t[1];return s?s.isSupported():(Ji.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.ts("src");var i=eh.getTech(this.Bi);return i||(i=me.getComponent(this.Bi)),Array.isArray(t)?this.fs(t):"string"==typeof t?this.src({src:t}):t instanceof w&&(t.type&&!i.canPlaySource(t,this.h[this.Bi.toLowerCase()])?this.fs([t]):(this.mi.sources=null,this.mi.source=t,this.mi.src=t.src,this.Fi=t.type||"",this.ready(function(){i.prototype.hasOwnProperty("setSource")?this.ls("setSource",t):this.ls("src",t.src),"auto"===this.h.preload&&this.load(),this.h.autoplay&&this.play()},!0))),this},s.fs=function(t){var i=this.selectSource(t);i?(i.tech===this.Bi?this.src(i.source):this._t(i.tech,i.source),this.mi.sources=t):(this.setTimeout(function(){this.error({code:4,message:this.localize(this.h.notSupportedMessage)})},0),this.triggerReady())},s.load=function(){return this.ls("load"),this},s.reset=function(){return this._t(ve(this.h.techOrder[0]),null),this.ls("reset"),this},s.currentSources=function(){var t=this.currentSource(),i=[];return 0!==w.keys(t).length&&i.push(t),this.mi.sources||i},s.currentSource=function(){var t={},i=this.currentSrc();return i&&(t.src=i),this.mi.source||t},s.currentSrc=function(){return this.ts("currentSrc")||this.mi.src||""},s.currentType=function(){return this.Fi||""},s.preload=function(t){return void 0!==t?(this.ls("setPreload",t),this.h.preload=t,this):this.ts("preload")},s.autoplay=function(t){return void 0!==t?(this.ls("setAutoplay",t),this.h.autoplay=t,this):this.ts("autoplay",t)},s.playsinline=function(t){return void 0!==t?(this.ls("setPlaysinline",t),this.h.playsinline=t,this):this.ts("playsinline")},s.loop=function(t){return void 0!==t?(this.ls("setLoop",t),this.h.loop=t,this):this.ts("loop")},s.poster=function(t){return void 0===t?this.gi:(t||(t=""),this.gi=t,this.ls("setPoster",t),this.trigger("posterchange"),this)},s.Ki=function(){!this.gi&&this.H&&this.H.poster&&(this.gi=this.H.poster()||"",this.trigger("posterchange"))},s.controls=function(t){return void 0!==t?(t=!!t,this.yi!==t&&(this.yi=t,this.usingNativeControls()&&this.ls("setControls",t),t?(this.removeClass("vjs-controls-disabled"),this.addClass("vjs-controls-enabled"),this.trigger("controlsenabled"),this.usingNativeControls()||this.ss()):(this.removeClass("vjs-controls-enabled"),this.addClass("vjs-controls-disabled"),this.trigger("controlsdisabled"),this.usingNativeControls()||this.es())),this):!!this.yi},s.usingNativeControls=function(t){return void 0!==t?(t=!!t,this.vs!==t&&(this.vs=t,t?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols"))),this):!!this.vs},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 Ee(t),this.addClass("vjs-error"),Ji.error("(CODE:"+this.lt.code+" "+Ee.errorTypes[this.lt.code]+")",this.lt.message,this.lt),this.trigger("error"),this)},s.reportUserActivity=function(t){this.ps=!0},s.userActive=function(t){return void 0!==t?((t=!!t)!==this.gs&&(this.gs=t,t?(this.ps=!0,this.removeClass("vjs-user-inactive"),this.addClass("vjs-user-active"),this.trigger("useractive")):(this.ps=!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.gs},s.wi=function(){var t,i,s,e,r=n(this,this.reportUserActivity);this.on("mousedown",function(){r(),this.clearInterval(t),t=this.setInterval(r,250)}),this.on("mousemove",function(t){t.screenX===i&&t.screenY===s||(i=t.screenX,s=t.screenY,r())}),this.on("mouseup",function(i){r(),this.clearInterval(t)}),this.on("keydown",r),this.on("keyup",r),this.setInterval(function(){if(this.ps){this.ps=!1,this.userActive(!0),this.clearTimeout(e);var t=this.h.inactivityTimeout;t>0&&(e=this.setTimeout(function(){this.ps||this.userActive(!1)},t))}},250)},s.playbackRate=function(t){return void 0!==t?(this.ls("setPlaybackRate",t),this):this.H&&this.H.featuresPlaybackRate?this.ts("playbackRate"):1},s.isAudio=function(t){return void 0!==t?(this.ys=!!t,this):!!this.ys},s.videoTracks=function(){return this.H?this.H.videoTracks():(this.rt=this.rt||new Zr,this.rt)},s.audioTracks=function(){return this.H?this.H.audioTracks():(this.ht=this.ht||new ih,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.ts("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.bs:(this.bs!==String(t).toLowerCase()&&(this.bs=String(t).toLowerCase(),void 0!==this.v&&this.trigger("languagechange")),this)},s.languages=function(){return pe(i.prototype.h.languages,this.pi)},s.toJSON=function(){var t=pe(this.h),i=t.tracks;t.tracks=[];for(var s=0;s<i.length;s++){var e=i[s];(e=pe(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 Ue(this,i);return this.addChild(e),e.on("dispose",function(){s.removeChild(e)}),e.open()},i.getTagSettings=function(t){var i={sources:[],tracks:[]},s=ys(t),e=s["data-setup"];if(fs(t,"vjs-fluid")&&(s.fluid=!0),null!==e){var n=Be(e||"{}"),r=n[0],h=n[1];r&&Ji.error(r),zi(s,h)}if(zi(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(ys(c)):"track"===l&&i.tracks.push(ys(c))}return i},s.ki=function(){var t=$i.createElement("i");return!("flexBasis"in t.style||"webkitFlexBasis"in t.style||"mozFlexBasis"in t.style||"msFlexBasis"in t.style||"msFlexOrder"in t.style)},i}(me);Ao.players={};var Po=b.navigator;Ao.prototype.h={techOrder:["html5","flash"],html5:{},flash:{},defaultVolume:0,inactivityTimeout:2e3,playbackRates:[],children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","controlBar","errorDisplay","textTrackSettings"],language:Po&&(Po.languages&&Po.languages[0]||Po.userLanguage||Po.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",fullscreenOptions:{navigationUI:"hide"}},["ended","seeking","seekable","networkState","readyState"].forEach(function(t){Ao.prototype[t]=function(){return this.ts(t)}}),Mo.forEach(function(t){Ao.prototype["handleTech"+ve(t)+"_"]=function(){return this.trigger(t)}}),me.registerComponent("Player",Ao);var No,Eo,Bo=function(t){function i(s){var e;void 0===s&&(s={});var n=pe(s,{kind:Ve[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(Ws)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return w.defineProperty(r,"enabled",{get:function(){return h},set:function(t){"boolean"==typeof t&&t!==h&&(h=t,this.trigger("enabledchange"))}}),n.enabled&&(r.enabled=n.enabled),r.W=!0,r||ye(e)}return ke(i,t),i}(qe),Io=function(t){function i(s){var e;void 0===s&&(s={});var n=pe(s,{kind:Oe[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(Ws)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return w.defineProperty(r,"selected",{get:function(){return h},set:function(t){"boolean"==typeof t&&t!==h&&(h=t,this.trigger("selectedchange"))}}),n.selected&&(r.selected=n.selected),r||ye(e)}return ke(i,t),i}(qe);function Fo(t,i,s){var e;if("string"==typeof t){if(0===t.indexOf("#")&&(t=t.slice(1)),Fo.getPlayers()[t])return i&&Ji.warn('Player "'+t+'" is already initialised. Options will not be applied.'),s&&Fo.getPlayers()[t].ready(s),Fo.getPlayers()[t];e=function(t){return 0===t.indexOf("#")&&(t=t.slice(1)),$i.getElementById(t)}(t)}else e=t;if(!e||!e.nodeName)throw new g("The element or ID supplied is not valid. (videojs)");if(e.player||Ao.players[e.playerId])return e.player||Ao.players[e.playerId];i=i||{},Fo.hooks("beforesetup").forEach(function(t){var s=t(e,pe(i));Wi(s)&&!Array.isArray(s)?i=pe(i,s):Ji.error("please return an object in beforesetup hooks")});var n=new(me.getComponent("Player"))(e,i,s);return Fo.hooks("setup").forEach(function(t){return t(n)}),n}"undefined"==typeof HTMLVideoElement&&ss()&&($i.createElement("video"),$i.createElement("audio"),$i.createElement("track")),Fo.ks={},Fo.hooks=function(t,i){return Fo.ks[t]=Fo.ks[t]||[],i&&(Fo.ks[t]=Fo.ks[t].concat(i)),Fo.ks[t]},Fo.hook=function(t,i){Fo.hooks(t,i)},Fo.removeHook=function(t,i){var s=Fo.hooks(t).indexOf(i);return!(s<=-1)&&(Fo.ks[t]=Fo.ks[t].slice(),Fo.ks[t].splice(s,1),!0)},!0!==b.VIDEOJS_NO_DYNAMIC_STYLE&&ss()&&((No=Ms(".vjs-styles-defaults"))||(No=de("vjs-styles-defaults"),(Eo=Ms("head"))&&Eo.insertBefore(No,Eo.firstChild),fe(No,"\n .video-js {\n width: 300px;\n height: 150px;\n }\n\n .vjs-fluid {\n padding-top: 56.25%\n }\n "))),le(1,Fo),Fo.VERSION="5.20.6-opentelly.14",Fo.options=Ao.prototype.h,Fo.getPlayers=function(){return Ao.players},Fo.players=Ao.players,Fo.getComponent=me.getComponent,Fo.registerComponent=function(t,i){eh.isTech(i)&&Ji.warn("The "+t+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),me.registerComponent.call(me,t,i)},Fo.getTech=eh.getTech,Fo.registerTech=eh.registerTech,Fo.browser=Ks,Fo.TOUCH_ENABLED=Qs,Fo.extend=function(t,i){void 0===i&&(i={});var s=function(){t.apply(this,arguments)},e={};for(var n in Wi(i)?("function"==typeof i.init&&(Ji.warn("Constructor logic via init() is deprecated; please use constructor() instead."),i.constructor=i.init),i.constructor!==w.prototype.constructor&&(s=i.constructor),e=i):"function"==typeof i&&(s=i),function(t,i){if("function"!=typeof i&&null!==i)throw new g("Super expression must either be null or a function, not "+typeof i);t.prototype=w.create(i&&i.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),i&&(t.ws=i)}(s,t),e)e.hasOwnProperty(n)&&(s.prototype[n]=e[n]);return s},Fo.mergeOptions=pe,Fo.bind=n,Fo.plugin=function(t,i){Ao.prototype[t]=i},Fo.addLanguage=function(t,i){var s;return t=(""+t).toLowerCase(),Fo.options.languages=pe(Fo.options.languages,((s={})[t]=i,s)),Fo.options.languages[t]},Fo.log=Ji,Fo.createTimeRange=Fo.createTimeRanges=xe,Fo.formatTime=gh,Fo.parseUrl=ze,Fo.isCrossOrigin=We,Fo.EventTarget=ge,Fo.on=ne,Fo.one=oe,Fo.off=re,Fo.trigger=he,Fo.xhr=Vr,Fo.TextTrack=Wr,Fo.AudioTrack=Bo,Fo.VideoTrack=Io,Fo.isEl=es,Fo.isTextNode=xs,Fo.createEl=rs,Fo.hasClass=fs,Fo.addClass=vs,Fo.removeClass=ps,Fo.toggleClass=ms,Fo.setAttributes=gs,Fo.getAttributes=ys,Fo.emptyEl=Cs,Fo.appendContent=Ss,Fo.insertContent=js,Fo.computedStyle=Ch,f(),f();function Do(t){const i=t.duration;if(S(i)){var s;const i=null==(s=t.source)?void 0:s.streamType;return"live"===i||"dvr"===i}return i===1/0}function $o(t){return t.scrubbing()?t.getCache().currentTime:t.currentTime()}function Uo(t){const i=Vo(t);return Do(t)?i.end(i.length-1):i.start(0)}function Ro(t){return Vo(t).start(0)}function Oo(t){const i=Vo(t);return i.end(i.length-1)-i.start(0)}function Vo(t){const i=t.seekable;if(i&&i.length)return i;let s=t.duration;return s=isFinite(s)?s:0,new Wt([0,s])._s()}function Lo(t,i){void 0===i&&(i=t);const s=t<0?"-":"";t=_.abs(t);let e=_.floor(t%60),n=_.floor(t/60%60),r=_.floor(t/3600);const h=_.floor(i/60%60),o=_.floor(i/3600);return(S(t)||t===1/0)&&(r=n=e="-"),r=Number(r)>0||o>0?r+":":"",n=((r||h>=10)&&Number(n)<10?"0"+n:n)+":",e=Number(e)<10?"0"+e:e,s+r+n+e}function Ho(t){return class extends t{get xs(){var t;return null!=(t=this.Cs)?t:this.Cs=qo(this.player())}dispose(){this.Cs=void 0,super.dispose()}constructor(...t){super(...t),this.Cs=void 0}}}function qo(t){return t.tech({IWillNotUseThisInPlugins:!0}).theoplayer()}function zo(t){const i=qo(t),s=()=>{const s=$o(t);t.toggleClass("theo-at-live",function(t,i){if(Do(t)){const s=t.seekable;return 0===s.length||s.end(s.length-1)-i<10}return!1}(i,s)),t.toggleClass("vjs-live",Do(i)),t.toggleClass("theo-dvr",function(t){return"dvr"===Tt(t.duration,t.seekable,t.source)}(i))};t.on("emptied",s),t.on("timeupdate",s),t.on("durationchange",s)}f(),f();function Wo(t,i,s){t.toggleClass("theo-ad-playing",i),t.toggleClass("theo-dai-ad-playing",i&&s)}function Go(){this.userActive(!1)}f(),f(),f();var Xo=class{constructor(t,i){this.type=void 0,this.target=void 0,this.playerEvent=void 0,this.type=t.type,this.target=i,this.playerEvent=t}},Jo=["loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange","resize"],Qo=Fo.getTech("Tech"),Yo=Fo.getTech("Html5"),Ko=class extends Qo{Ss(){var t;for(const t of Jo)this.xs.addEventListener(t,this.js);this.xs.addEventListener("error",this.Ts),this.xs.addEventListener("contentprotectionerror",this.Ts),this.xs.addEventListener("sourcechange",this.Ms),this.xs.addEventListener("loadstart",this.As),null==(t=this.xs.presentation)||t.addEventListener(Pi.MODE_CHANGE,this.Ps),this.xs.textTracks.addEventListener("addtrack",this.Ns),this.xs.textTracks.addEventListener("removetrack",this.Es),this.xs.textTracks.addEventListener("change",this.Bs),this.xs.audioTracks.addEventListener("addtrack",this.Is),this.xs.audioTracks.addEventListener("removetrack",this.Fs),this.xs.audioTracks.addEventListener("change",this.Ds)}$s(){var t;for(const t of Jo)this.xs.removeEventListener(t,this.js);this.xs.removeEventListener("error",this.Ts),this.xs.removeEventListener("contentprotectionerror",this.Ts),this.xs.removeEventListener("sourcechange",this.Ms),this.xs.removeEventListener("loadstart",this.As),null==(t=this.xs.presentation)||t.removeEventListener(Pi.MODE_CHANGE,this.Ps),this.xs.textTracks.removeEventListener("addtrack",this.Ns),this.xs.textTracks.removeEventListener("removetrack",this.Es),this.xs.textTracks.removeEventListener("change",this.Bs),this.xs.audioTracks.removeEventListener("addtrack",this.Is),this.xs.audioTracks.removeEventListener("removetrack",this.Fs),this.xs.audioTracks.removeEventListener("change",this.Ds)}Us(t){this.trigger(new Xo(t,this))}createEl(){const t=this.h,i=t.player;if(!i)throw new m(this.localize('Missing required tech option "player"'));const s=i.element;return Fo.setAttributes(s,{id:t.techId}),s}theoplayer(){return this.xs}addTextTrack(t,i,s){return super.addTextTrack(t,i,s)}buffered(){return this.xs.buffered}played(){return this.xs.played}reset(){this.xs.stop()}play(){this.xs.play()}pause(){this.xs.pause()}paused(){return this.xs.paused}currentTime(){return this.xs.currentTime}setCurrentTime(t){this.xs.currentTime=t}duration(){return this.xs.duration}volume(){return this.xs.volume}setVolume(t){this.xs.volume=t}muted(){return this.xs.muted}setMuted(t){this.xs.muted=t}src(t){if(void 0!==t)this.setSrc(t);else{if(this.xs.src)return this.xs.src;if(this.xs.source){if(!ci(this.xs.source.ads))return this.xs.source.ads[0].sources;if(Qt(this.xs.source))return"This source is managed by the Uplynk integration extension.";if(Ft(this.xs.source))return"This source is managed by the DAI integration extension.";if(Jt(this.xs.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.xs.src}load(){this.setPreload("auto")}preload(){return this.xs.preload}setPreload(t){this.xs.preload=t}autoplay(){return this.xs.autoplay}setAutoplay(t){this.xs.autoplay=Boolean(t)}seeking(){return this.xs.seeking}seekable(){return this.xs.seekable}ended(){return this.xs.ended}playbackRate(){return this.xs.playbackRate}setPlaybackRate(t){this.xs.playbackRate=t}readyState(){return this.xs.readyState}networkState(){return 0}controls(){return!1}videoHeight(){return this.xs.videoHeight}videoWidth(){return this.xs.videoWidth}supportsFullScreen(){return this.xs.presentation.supportsMode(ni.FULLSCREEN)}enterFullScreen(){this.xs.presentation.requestMode(ni.FULLSCREEN)}exitFullScreen(){this.xs.presentation.requestMode(ni.INLINE)}Rs(){const t=this.xs.ads;if(t&&t.playing)return!0;const i=this.xs.vr;return!(!i||i.state===Vt.Os)}initTextTrackListeners(){return this.on("touchend",t=>{this.Rs()&&(t.preventDefault=()=>{})}),super.initTextTrackListeners()}Zt(){if(!this.src())return;const t=this.readyState();if(0===t){let t=!1;const i=()=>{t=!0};this.on("loadstart",i);const 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")})}const 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.$s(),this.xs=null,super.dispose()}static isSupported(){return!0}static canPlayType(){return"maybe"}static canPlaySource(t){return"maybe"}get featuresVolumeControl(){return V}constructor(t={},i){super(t,i),this.xs=void 0,this.js=t=>this.Us(t),this.Vs=!1,this.Ms=()=>{void 0===this.xs.errorObject&&(this.Us(new ti(this.xs.currentTime,this.xs.readyState)),this.Us(new I),this.Us(new si(this.xs.duration)))},this.As=()=>{this.Us(new It(this.xs.currentTime))},this.Ns=t=>{this.textTracks().tt(t.track)},this.Is=t=>{this.audioTracks().tt(t.track)},this.Es=t=>{this.textTracks().it(t.track)},this.Fs=t=>{this.audioTracks().it(t.track)},this.Bs=()=>{const t=this.textTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Ds=()=>{const t=this.audioTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Ps=()=>{if(!this.supportsFullScreen())return;const t=this.Vs,i=this.xs.presentation.currentMode===ni.FULLSCREEN;t!==i&&(this.Vs=i,this.trigger("fullscreenchange",{isFullscreen:i,nativeIOSFullscreen:!0}))},this.Ts=()=>{const t=this.xs.errorObject,i=t&&yt(t.code)||-1,s=t&&t.message||"An unknown error occurred.";this.error({code:i,message:this.localize(s)})},this.xs=this.h.player,this.Ss();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()}};Ko.prototype.featuresFullscreenResize=Yo.prototype.featuresFullscreenResize,Ko.prototype.featuresPlaybackRate=Yo.prototype.featuresPlaybackRate,Ko.prototype.featuresProgressEvents=!0,Ko.prototype.featuresTimeupdateEvents=!0,Ko.prototype.featuresNativeTextTracks=!0,Fo.registerTech("THEOplayer",Ko),f(),f(),f(),f();var Zo=class{constructor(t){this.Ls=void 0,this.Hs=t=>{ei(this.Ls,"theo-mobile-button-hover"),t.stopImmediatePropagation()},this.qs=t=>{ri(this.Ls,"theo-mobile-button-hover")},this.zs=t=>{this.Ls.blur()},this.Ls=t,t.addEventListener("touchstart",this.Hs),t.addEventListener("touchend",this.qs),t.addEventListener("focusin",this.zs)}};f(),f(),f(),f();var ta=Fo.getComponent("Menu"),ia=class extends(Ho(ta)){get Ws(){return this.player().el()}Gs(){ei(this.Ws,"theo-menu-opened")}Xs(){ri(this.Ws,"theo-menu-opened")}constructor(t,i){super(t,i)}};f();var sa=Fo.getComponent("MenuItem"),ea=class extends(Ho(sa)){get parentMenu(){return this.Js}buildCSSClass(){return"theo-menu-item vjs-menu-item"}createEl(){const t=super.createEl("li",{className:this.buildCSSClass(),tabIndex:0},{"aria-live":"off","aria-label":""});return t.innerHTML="",t}handleClick(t){this.Qs||(this.parentMenu.Ys(this),"tap"!==t.type&&"keydown"!==t.type||(this.Qs=!0,this.trigger("click"),this.Qs=!1))}dispose(){pi.Zs.Ks&&(this.el().removeEventListener("touchstart",this.Hs),this.el().removeEventListener("touchend",this.qs)),super.dispose()}constructor(t,i,s){super(t,z({selectable:!0},i)),this.Js=void 0,this.Qs=!1,this.Hs=t=>{ei(this.el(),"theo-mobile-menu-item-hover"),t.stopImmediatePropagation()},this.qs=t=>{ri(this.el(),"theo-mobile-menu-item-hover")},this.Js=s,pi.Zs.Ks&&(this.el().addEventListener("touchstart",this.Hs),this.el().addEventListener("touchend",this.qs))}};f();var na=Fo.getComponent("ClickableComponent"),ra=class extends na{get parentMenu(){return this.Js}get te(){return this.ie}set te(t){this.ie=t,this.el().setAttribute("tabindex",this.te?"0":"-1"),this.se()}buildCSSClass(){return"theo-primary-background theo-menu-header"}createEl(){const t=super.createEl("div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-live":"off","aria-label":""});return t.innerHTML="",t}handleClick(t){!this.Qs&&this.te&&(this.Js.ee(),"tap"===t.type&&(this.Qs=!0,this.trigger("click"),this.Qs=!1))}se(){this.te?this.el().setAttribute("aria-label",this.localize("Go back to the previous menu")):this.el().setAttribute("aria-label","")}constructor(t,i,s){super(t,i),this.Js=void 0,this.Qs=!1,this.ie=!1,this.Js=s,this.on(t,"languagechange",this.se)}},ha=class extends ia{get menuHeader(){return this.ne}get menuItems(){return this.children()}addMenuItem(t){t=z({playerOptions:this.h.playerOptions},t);const i=new ea(this.player(),t,this);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}addSubMenuItem(t){t=z({playerOptions:this.h.playerOptions},t);const i=this.re(this.player(),t);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}removeMenuItem(t){this.removeChild(t),this.trigger("menuchange")}buildCSSClass(){return"theo-menu vjs-menu"}Gs(){super.Gs(),s.removeEventListener("resize",this.he),s.addEventListener("resize",this.he),this.show()}oe(){const t=this.ae();if(!t)return;const i=t.getClientRects();pi.Zs.Ks?this.ue(t,i):this.ce(t,i)}ae(){var t;return null!=(t=this.contentEl().parentElement)?t:void 0}ce(t,i){}ue(t,i){}Xs(){s.removeEventListener("resize",this.he),super.Xs(),this.hide(),pi.Zs.Ks&&(this.el().removeAttribute("style"),this.contentEl().removeAttribute("style"))}createEl(){const t=super.createEl();t.className=this.buildCSSClass();const i=this.contentEl();ei(i,"theo-menu-content");const s=new ra(this.player(),this.h,this);return i.parentNode.insertBefore(s.el(),i),this.ne=s,t}Ys(t){}show(){return this.oe(),super.show()}dispose(){this.ne&&this.ne.dispose(),super.dispose()}constructor(t,i){super(t,i),this.le=void 0,this.he=()=>this.oe(),this.le=this.player().el(),this.hide(),this.on("menuchange",this.oe)}},oa=class extends ha{get de(){return this.fe}set de(t){this.fe&&this.fe.ve(this),this.fe=t,t&&t.pe(this)}me(t){this.de.ge(t,"replace")}ye(t){t.de.ge(this,"restore")}be(){ri(this.ke,"vjs-hidden"),this.ke.style.opacity="1",super.show()}we(){ei(this.ke,"vjs-hidden")}Gs(){this.de&&this.de.Gs(),super.Gs()}Xs(){this.de&&this.de.Xs(),super.Xs(),ei(this.ke,"vjs-hidden")}ae(){if(this.de&&this.de._e)return this.de._e.ke}ce(t,i){if(i.length>0){const t=i[0].height,s=i[0].width;this.fe.xe.style.height=t+"px",this.fe.xe.style.width=s+"px"}super.ce(t,i)}constructor(t,i){super(t,i)}};f();var aa=class{get xe(){return this.Ls}get _e(){return this.Ce}pe(t){t.we(),this.Ls.appendChild(t.ke)}ve(t){this.Ls.removeChild(t.ke)}ge(t,i){if(t==this.Ce)return;const s=this.Ce;if(this.Ce=t,this.Ce.be(),this._e.focus(),pi.Zs.Ks)s.we();else{const t="translateX(100%)",e="translateX(-100%)",n=ki("transform");s.ke.style.opacity="0",s.ke.style[n]="replace"===i?e:t,this.Ce.ke.style.opacity="1",this.Ce.ke.style[n]="",u(()=>{s.we(),s.ke.style[n]=""},300)}}Gs(){this.Se(),this.Ce.be(),this.je()}Xs(){this.Se(),this.Ce.we(),this.Te.we(),this.Ce=this.Te,this.je()}je(){vi(()=>{ri(this.Ls,"theo-no-transition"),ri(this.Ce.ke,"theo-no-transition")})}Se(){ei(this.Ls,"theo-no-transition"),ei(this.Ce.ke,"theo-no-transition")}constructor(t){this.Ce=void 0,this.Te=void 0,this.Ls=void 0,this.le=void 0,this.Te=this.Ce=t,this.Ls=h.createElement("div"),this.Ls.className="theo-tertiary-background theo-menu-animation-container",this.Ls.appendChild(this.Te.ke),this.le=this.Ce.player().el()}};f(),f();var ua=class extends oa{get ke(){return this.el()}get parentMenu(){return this.Me}re(t,i){const s=new ca(t,i,this);return s.subMenu.de=this.de,s}ee(){this.Ae()}Ys(t){super.Ys(t),this.Ae()}Ae(){this.parentMenu.ye(this)}buildCSSClass(){return"theo-submenu "+(this.Pe?"":"theo-leaf-submenu ")+"theo-menu-content theo-menu-content-animatable "+super.buildCSSClass()}addSubMenuItem(t){this.Pe=!0;const i=super.addSubMenuItem(t);return this.removeClass("theo-leaf-submenu"),i}constructor(t,i,s){super(t,i),this.Me=void 0,this.Pe=!1,this.Me=s,this.menuHeader.te=!0}},ca=class extends ea{get subMenu(){return this.Ne}handleClick(t){this.parentMenu.me(this.subMenu)}constructor(t,i,s){super(t,z({selectable:!1},i),s),this.Ne=void 0,this.Ne=new ua(t,i,s)}},la=class extends oa{get menuButton(){return this.Ee}createEl(){const t=Fo.createEl("div",{className:this.buildCSSClass()});return this.Be=super.createEl(),this.Be.className=super.buildCSSClass(),ei(this.Be,"theo-menu-content-animatable"),t.appendChild(this.Be),this.de=new aa(this),t.appendChild(this.de.xe),t}buildCSSClass(){return"theo-menu-animatable "+super.buildCSSClass()}re(t,i){const s=new ca(t,i,this);return s.subMenu.de=this.de,s}ce(t,i){super.ce(t,i);const s=this.le.getClientRects(),e=s.length>0?s[0]:void 0,n=C(getComputedStyle(this.el()).fontSize);Q(this.el(),this.Ee.el(),e,n)}get ke(){return this.Be}ee(){this.Ee.closeMenu()}dispose(){this.Ie||(this.Ie=!0,super.dispose())}constructor(t,i,s){super(t,i),this.Ee=void 0,this.Ie=!1,this.Ee=s}};f();var da=class{set Fe(t){this.De.innerHTML=this.$e.localize(t),this.Ue()&&this.Re(),li(this.$e.el())}get Fe(){return this.De.textContent||""}Ue(){return!ii(this.De,"vjs-hidden")}Oe(){this.$e.off("mouseover",this.Re),this.$e.off("mouseout",this.Ve),this.$e.off("dispose",this.Le),Yt(this.De)}constructor(t,i){this.De=void 0,this.$e=void 0,this.Re=()=>{ri(this.De,"vjs-hidden");const t=this.$e.player().contentEl().getClientRects(),i=t.length>0?t[0]:void 0,s=C(getComputedStyle(this.De).fontSize);Q(this.De,this.$e.el(),i,s)},this.Ve=()=>{ei(this.De,"vjs-hidden")},this.Le=()=>this.Oe(),this.$e=t,li(t.el()),fi(t.el()),this.De=h.createElement("span"),this.De.innerHTML=this.$e.localize(i),this.De.className="theo-button-tooltip vjs-hidden",this.De.setAttribute("aria-hidden","true"),this.$e.el().appendChild(this.De),this.$e.on("mouseover",this.Re),this.$e.on("mouseout",this.Ve),this.$e.on("dispose",this.Le)}},fa=Fo.getComponent("Button"),va=class extends(Ho(fa)){get He(){const t=this.el().parentElement;return!!t&&null!==t.querySelector(".theo-mobile-menu-background")}get menu(){return this.qe}isMenuOpen(){return this.ze}openMenu(){this.We&&!this.ze&&(this.qe.Gs(),this.el().setAttribute("aria-expanded","true"),this.ze=!0,this.qe.focus())}closeMenu(){this.We&&this.ze&&(this.qe.Xs(),this.el().setAttribute("aria-expanded","false"),this.ze=!1)}set minimumMenuItems(t){this.Ge=t,this.Xe()}buildCSSClass(){return"theo-controlbar-button vjs-menu-button vjs-menu-button-popup "+super.buildCSSClass()}createEl(t,i,s){return super.createEl("button",{},{"aria-live":"off"})}handleClick(){this.ze?this.closeMenu():this.openMenu()}enable(){return this.We=!0,super.enable()}disable(){return this.closeMenu(),this.We=!1,super.disable()}se(){this.De.Fe=this.controlText()}dispose(){this.player().removeChild(this.qe),this.qe.dispose(),this.De.Oe(),this.xs.removeEventListener("seeking",this.Je),super.dispose()}constructor(t,i){super(t,i),this.qe=void 0,this.De=void 0,this.ze=!1,this.Ge=1,this.We=!0,this.Qe=t=>{const i=this.el().contains(t.target),s=this.qe.el().contains(t.target);let e=!1;var n;pi.Zs.Ks&&this.He&&(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.Ye=t=>{27===t.which&&(this.closeMenu(),this.focus())},this.Je=()=>{this.ze&&this.closeMenu()},this.Xe=()=>{this.qe.menuItems.length>=this.Ge?this.show():(this.closeMenu(),this.hide())},this.qe=new la(t,i,this),this.player().getChild("controlBarMenuContainer").addChild(this.qe),this.De=new da(this,this.controlText()),this.el().setAttribute("aria-haspopup","true"),pi.Zs.Ke?(this.on(h,"touchend",this.Qe),new Zo(this.el())):(this.on(h,"click",this.Qe),this.on(h,"keydown",this.Ye),ji&&this.on(h,ji.Ze,this.closeMenu)),this.xs.addEventListener("seeking",this.Je),this.on(this.qe,"menuchange",this.Xe),this.on(t,"languagechange",this.se),this.Xe()}},pa=Fo.getComponent("Component"),ma=class extends(Fo.getComponent("ControlBar")){addMenuButton(t){t=z({playerOptions:this.h.playerOptions},t);const i=new va(this.player(),t);return this.addChild(i),i}removeMenuButton(t){this.removeChild(t)}createEl(){const 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)}};Fo.registerComponent("THEOControlBarShadow",class extends pa{createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-tertiary-color theo-control-bar-shadow"}}),f(),f();var ga=Fo.getComponent("VolumeBar"),ya=class extends ga{handleFocus(t){super.handleFocus(t),this.tn.addClass("focus-within")}handleBlur(t){super.handleBlur(t),this.tn.removeClass("focus-within")}constructor(t,i){super(t,i),this.tn=void 0,this.tn=i.sn}};f();var ba=Fo.getComponent("VolumeControl"),ka=class extends ba{constructor(t,i){super(t,i),this.nn=void 0,this.nn=new ya(t,{sn:this}),this.addChild(this.nn)}};ka.prototype.h=z({},ba.prototype.h,{children:[]}),Fo.registerComponent("VolumeControl",ka);var wa=class extends(Ho(ma)){rn(){this.hn(this.an())}un(){0===this.cn&&(this.cn=u(this.ln,100))}dn(t){"opacity"===t.propertyName&&(0!==this.cn&&(c(this.cn),this.cn=0),this.hn(!0))}fn(t){"opacity"===t.propertyName&&(this.an()||this.hn(!1))}an(){return"0"!==s.getComputedStyle(this.el()).opacity}hn(t){this.vn!==t&&(this.vn=t,t?this.pn():this.xs.textTrackStyle.marginBottom=void 0)}pn(){const t=this.el().getBoundingClientRect().height;this.xs.textTrackStyle.marginBottom!==t&&(this.xs.textTrackStyle.marginBottom=t)}dispose(){c(this.cn),this.cn=0,this.gn.mn(mi.yn,this.bn),this.gn.kn(),super.dispose()}constructor(t,i){super(t,i),this.gn=void 0,this.vn=!1,this.cn=0,this.ln=()=>{0!==this.cn&&(this.cn=0,this.hn(this.an()))},this.bn=()=>{this.vn&&this.pn()},this.on(t,"ready",this.rn),this.on(t,"pause",this.rn),this.on(t,"useractive",this.rn),this.on(t,"firstplay",this.un),this.on(t,"play",this.un),this.on(t,"userinactive",this.un),this.on("transitionstart",this.dn),this.on("transitionend",this.fn),this.gn=new _i(this.el()),this.gn.wn(mi.yn,this.bn),this.gn._n(!0)}};wa.prototype.h=z({},ma.prototype.h,{children:["progressControl","playToggle","muteToggle","volumeControl","currentTimeDisplay","timeDivider","durationDisplay","liveDisplay","remainingTimeDisplay","customControlSpacer","activeQualityLabel","vrButton","descriptionsButton","subtitlesButton","chromecastButton","airplayButton","multiViewButton","audioTrackButton","SettingsButton","fullscreenToggle"]}),Fo.registerComponent("ControlBar",wa),f();var _a=class extends ma{buildCSSClass(){return"theo-top-controlbar "+super.buildCSSClass()}constructor(t,i){super(t,i),t.topControlBar=this}};_a.prototype.h=z({},ma.prototype.h,{children:[]}),Fo.registerComponent("TopControlBar",_a),f();var xa=Fo.getComponent("CurrentTimeDisplay"),Ca=class extends(Ho(xa)){updateContent(){const t=$o(this.player()),i=this.xs,s=Ro(i),e=this.localize("Current Time"),n=Lo(_.max(0,t-s),Oo(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)}};Fo.registerComponent("CurrentTimeDisplay",Ca),f();var Sa=Fo.getComponent("DurationDisplay"),ja=class extends(Ho(Sa)){updateContent(){const t=this.xs,i=S(t.duration)?NaN:Oo(t),s=t.clip.endTime-t.clip.startTime,e=_.min(i,s)||0;if(this.ct!==e){this.ct=e;const t=this.localize("Duration Time"),i=Lo(e);this.S.innerHTML='<span class="vjs-control-text">'+t+"</span> "+i}}dispose(){var t;null==(t=this.xs)||t.clip.removeEventListener("change",this.xn),super.dispose()}constructor(t,i){var s;super(t,i),this.xn=()=>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.xs)||s.clip.addEventListener("change",this.xn)}};Fo.registerComponent("DurationDisplay",ja),f();var Ta=Fo.getComponent("Button"),Ma=class extends(Ho(Ta)){buildCSSClass(){return"theo-live-control "+super.buildCSSClass()}createEl(){const t=super.createEl("button",{},{"aria-live":"off"});return this.Cn=Fo.createEl("span",{className:"theo-live-control-indicator"}),Zt(t,this.Cn),t}createControlTextEl(t){const i=super.createControlTextEl(t);return Fo.removeClass(i,"vjs-control-text"),Fo.addClass(i,"theo-live-control-text"),i}handleClick(){var t;const i=this.xs;if(void 0!==(null==(t=i.hesp)?void 0:t.manifest))i.hesp.goLive();else{const t=this.player();t.currentTime(1/0),t.play()}}Sn(){Do(this.xs)?this.show():this.hide()}constructor(t,i){super(t,i),this.controlText("Live"),this.Sn(),this.on(t,"emptied",this.Sn),this.on(t,"durationchange",this.Sn),pi.Zs.Ke&&new Zo(this.el())}};Fo.registerComponent("LiveDisplay",Ma),f();var Aa=Fo.getComponent("LoadingSpinner");Fo.registerComponent("LoadingSpinner",class extends Aa{buildCSSClass(){return"theo-secondary-color vjs-loading-spinner "+super.buildCSSClass()}createEl(){const t=super.createEl();t.className=this.buildCSSClass();const i=Fo.createEl("div",{className:"theo-loading-spinner-rotator"}),s=Fo.createEl("div",{className:"theo-loading-spinner-circle-left"}),e=Fo.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)}}),f();var Pa=Fo.getComponent("LoadProgressBar"),Na=class extends(Ho(Pa)){update(){const t=this.xs,i=Wt.jn(Vo(t)),s=i.Tn(0),e=Wt.jn(t.buffered).Mn(i),n=i.An(0)-s;let r=e.V&&e.An(e.V-1)||0;r=_.max(0,r-s);const o=this.el(),a=this.Pn;o.style.width=Ea(r,n);for(let t=0;t<e.V;t++){const i=e.Tn(t),n=e.An(t);let u=a[t];u||(u=h.createElement("div"),a.push(u),o.appendChild(u)),u.style.left=Ea(i-s,r),u.style.width=Ea(n-i,r)}for(let t=a.length;t>e.V;t--)o.removeChild(a[t-1]);a.length=e.V}constructor(t,i){super(t,i),this.Pn=[],this.on(t,"emptied",this.update)}};function Ea(t,i){const s=t/i||0;return 100*(s>=1?1:s)+"%"}Fo.registerComponent("LoadProgressBar",Na),f();var Ba=Fo.getComponent("MouseTimeDisplay"),Ia=class extends(Ho(Ba)){handleMouseMove(t){const i=t,s=this.xs,e=Ro(s)+this.calculateDistance(i)*Oo(s),n=i.pageX-X(this.el().parentNode).left;this.update(e,n+"px")}handleTouchMove(t){const i=t,s=this.xs,e=Ro(s)+this.calculateDistance(i)*Oo(s),n=i.touches[0].pageX-X(this.el().parentNode).left;this.update(e,n+"px")}createEl(){const t=super.createEl();return this.Nn=Fo.createEl("span",{className:"theo-time-tooltip-text"}),t}update(t,i){this.En=t;const s=this.Bn(t);this.el().style.left=i,this.el().setAttribute("data-current-time",s),this.keepTooltipsInside&&(d(this.Nn,s),this.In())}In(){if(this.keepTooltipsInside&&this.tooltip.offsetParent){const t=this.player().contentEl(),i=t.getClientRects(),s=i.length>0?i[0]:void 0,e=C(getComputedStyle(t).fontSize);Q(this.tooltip,this.el(),s,e)}}Bn(t){const i=this.xs,s=t-Uo(i);return Lo(Do(i)?_.min(s,0):s,Oo(i))}dispose(){var t;this.xs.removeEventListener("dimensionchange",this.Fn),null==(t=this.xs.presentation)||t.removeEventListener(Pi.MODE_CHANGE,this.Fn),super.dispose()}constructor(t,i){var s;(super(t,i),this.En=NaN,this.Fn=()=>{const t=$o(this.player()),i=this.xs;let s=(t-Ro(i))/Oo(i)||0;s=Si(s,0,1),this.update(t,100*s+"%")},this.keepTooltipsInside&&(Fo.addClass(this.tooltip,"theo-secondary-color"),this.tooltip.appendChild(this.Nn)),this.on(t,"ready",()=>{this.on(t.controlBar.progressControl,"mouseenter",this.handleMouseMove)}),Dt.Ks)&&(this.on(t,"firstplay",this.Fn),this.on(t,"play",this.Fn),this.on(t,"seeking",this.Fn),this.on(t,"seeked",this.Fn),this.on(t,"timeupdate",this.Fn),this.xs.addEventListener("dimensionchange",this.Fn),null==(s=this.xs.presentation)||s.addEventListener(Pi.MODE_CHANGE,this.Fn),this.on(t,"ready",()=>{this.on(t.controlBar.progressControl,"touchstart",this.handleTouchMove),this.on(t.controlBar.progressControl,"touchmove",bi(t=>this.handleTouchMove(t),25)),this.Fn()}))}};Fo.registerComponent("MouseTimeDisplay",Ia),f();var Fa=Fo.getComponent("PlayProgressBar"),Da=class extends(Ho(Fa)){updateDataAttr(){const t=$o(this.player());this.el().setAttribute("data-current-time",this.Bn(t))}Bn(t){const i=this.xs;return Lo(t-Uo(i),Oo(i))}createEl(){const 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)}};Fo.registerComponent("PlayProgressBar",Da),f();var $a=Fo.getComponent("RemainingTimeDisplay"),Ua=class extends(Ho($a)){updateContent(){const t=this.xs,i=Oo(t);if(i){const s=Vo(t).end(0),e=this.localize("Remaining Time"),n=Lo(_.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)}};Fo.registerComponent("RemainingTimeDisplay",Ua),f(),f();var Ra=class{get xs(){var t;return null!=(t=this.Cs)?t:this.Cs=qo(this.Dn)}$n(){const t=this.Un;if(!t)return;const i=this.xs;if(0===i.seekable.length)return;const s=t.cues.slice();this.On.Rn(s);for(let t=0;t<s.length;t++){const e=s[t],n=s[t+1],r=!n||e.endTime!==n.startTime,h=new Oa(e,i,r);this.Vn.push(h),this.Ln.appendChild(h.xe)}}Hn(){this.xs.addEventListener("loadedmetadata",this.qn),this.xs.addEventListener("loadeddata",this.qn),this.xs.addEventListener("sourcechange",this.qn),this.xs.addEventListener("durationchange",this.zn),this.xs.clip.addEventListener("change",this.zn),this.xs.textTracks.addEventListener("addtrack",this.Wn),this.xs.textTracks.addEventListener("removetrack",this.Gn),this.xs.textTracks.addEventListener("change",this.qn)}Xn(){this.xs.removeEventListener("loadedmetadata",this.qn),this.xs.removeEventListener("loadeddata",this.qn),this.xs.removeEventListener("sourcechange",this.qn),this.xs.removeEventListener("durationchange",this.zn),this.xs.clip.removeEventListener("change",this.zn),this.xs.textTracks.removeEventListener("addtrack",this.Wn),this.xs.textTracks.removeEventListener("removetrack",this.Gn),this.xs.textTracks.removeEventListener("change",this.qn)}Jn(){if(!(this.xs.readyState<Et.Qn))for(const t of this.xs.textTracks)if(t.kind===jt.Yn&&t.mode===Ct.Kn&&t.cues.length>0&&t.readyState!==kt.ERROR)return t}Zn(t){const i=this.Un;t!==i&&(i&&(this.tr(),i.removeEventListener("cuechange",this.ir)),this.Un=t,t&&(t.addEventListener("cuechange",this.ir),this.zn()))}sr(t){this.On.er(t)}nr(){this.On.be()}rr(){this.On.we()}tr(){for(const t of this.Vn)t.Oe();this.On.hr(),this.Vn=[],this.ar=void 0}Oe(){this.Xn(),this.ur.removeEventListener("mousemove",this.cr),this.ur.removeEventListener("mouseenter",this.lr),this.ur.removeEventListener("mouseleave",this.dr),this.Zn(void 0),this.On.Oe(),this.Cs=void 0}constructor(t,i){this.Dn=void 0,this.Ln=void 0,this.On=void 0,this.ur=void 0,this.Un=void 0,this.Vn=void 0,this.ar=void 0,this.Cs=void 0,this.qn=void 0,this.Wn=void 0,this.Gn=void 0,this.cr=void 0,this.dr=void 0,this.lr=void 0,this.zn=void 0,this.ir=void 0,this.Dn=i,this.Vn=[],this.Cs=void 0,this.qn=()=>{this.Zn(this.Jn())},this.Wn=t=>{const i=t.track;i.kind===jt.Yn&&(i.addEventListener("addcue",this.qn),i.addEventListener("removecue",this.qn),i.addEventListener("readystatechange",this.qn)),this.qn()},this.Gn=t=>{const i=t.track;i.kind===jt.Yn&&(i.removeEventListener("addcue",this.qn),i.removeEventListener("removecue",this.qn),i.removeEventListener("readystatechange",this.qn)),this.qn()},this.cr=t=>{const i=this.xs,s=function(t,i){const s=X(t),e=t.offsetWidth,n=t.offsetHeight,r=s.top,h=s.left;let o,a;!function(t){return void 0!==t.changedTouches}(i)?(a=i.pageX,o=i.pageY):(a=i.changedTouches[0].pageX,o=i.changedTouches[0].pageY);const u=Si((r-o+n)/n,0,1),c=Si((a-h)/e,0,1);return{x:c,y:u}}(this.Ln,t);let e=Ro(i)+s.x*Oo(i);e===i.duration&&(e-=.1),this.sr(e)},this.dr=()=>{this.On.we()},this.lr=()=>{this.On.be()},this.zn=()=>{this.Un&&(this.tr(),this.$n(),this.ir())},this.ir=()=>{var t,i,s;const e=null==(i=this.Un)||null==(t=i.activeCues)?void 0:t[0],n=Ni(this.Vn,t=>t.pr===e);n!==this.ar&&(null==(s=this.ar)||s.mr(),this.ar=n,null==n||n.gr())},this.ur=t,this.On=new Va,this.Dn.contentEl().appendChild(this.On.xe),this.Ln=h.createElement("div"),ei(this.Ln,"theoplayer-chapterbar"),this.ur.appendChild(this.Ln),this.ur.addEventListener("mousemove",this.cr),this.ur.addEventListener("mouseenter",this.lr),this.ur.addEventListener("mouseleave",this.dr),this.Hn()}},Oa=class{get xe(){return this.Ls}gr(){ei(this.Ls,"theoplayer-chapter-indicator-active")}mr(){ri(this.Ls,"theoplayer-chapter-indicator-active")}yr(t,i){const s=t.seekable.start(0),e=t.seekable.end(t.seekable.length-1),n=e-s,r=this.pr.startTime,o=this.pr.endTime,a=o>=s&&r<=e,u=Si(r-s,0,n),c=Si(o-s,0,n),l=_.max(0,c-u),d=h.createElement("div");ei(d,"theoplayer-chapter-indicator");const f=h.createElement("div");ei(f,"theoplayer-chapter-indicator-highlight"),d.appendChild(f),i&&ei(d,"theoplayer-chapter-indicator-discontinuous");const v=u/n*100,p=l/n*100;return d.style.display=a?"":"none",d.style.width=p+"%",d.style.left=v+"%",d}Oe(){Yt(this.Ls)}constructor(t,i,s){this.pr=void 0,this.Ls=void 0,this.pr=t,this.Ls=this.yr(i,s)}},Va=class{we(){this.br--,0===this.br&&ri(this.xe,"theoplayer-chapter-hovering")}Rn(t){this.kr=t||[],this.kr.length>0&&(this.xe.style.display="")}wr(t){d(this._r,t.content)}hr(){this.kr=[],d(this._r,""),this.xe.style.display="none"}be(){this.br++,this.br>0&&ei(this.xe,"theoplayer-chapter-hovering")}er(t){for(const i of this.kr)if(La(i,t)){this.wr(i);break}}Oe(){Yt(this.xe)}constructor(){this.kr=[],this.xe=void 0,this._r=void 0,this.br=0,this.xe=h.createElement("div"),ei(this.xe,"theoplayer-chaptertitle"),this.xe.style.display="none",this._r=h.createElement("p"),this.xe.appendChild(this._r)}};function La(t,i){return new Wt([t.startTime,t.endTime]).Cr(i)}var Ha=Fo.getComponent("SeekBar"),qa=class extends(Ho(Ha)){updateAriaAttributes(t){const i=$o(this.player()),s=this.xs;t.setAttribute("aria-valuenow",(100*this.Sr(i)).toFixed(2)),t.setAttribute("aria-valuetext",Lo(i-Uo(s),Oo(s)))}getPercent(){return this.Sr(this.player().currentTime())}handleMouseMove(t){if(this.xs&&this.xs.ads&&this.xs.ads.playing)return;const i=this.xs;let s=Ro(i)+this.calculateDistance(t)*Oo(i);s>=i.duration&&(s=i.duration-.1),this.Ln.sr(s),this.player().currentTime(s)}handleMouseDown(t){this.playingStates.push(!this.player().paused()),this.Ln.nr(),super.handleMouseDown(t)}handleMouseUp(t){this.videoWasPlaying=Boolean(this.playingStates.pop()),this.Ln.rr(),super.handleMouseUp(t)}Sr(t){const i=this.xs,s=(t-Ro(i))/Oo(i);return Si(s,0,1)}dispose(){this.Ln.Oe(),B(this.playingStates)}constructor(t,i){super(t,i),this.Ln=void 0,this.playingStates=[],this.on(t,"emptied",this.update),this.on(t,"seeking",this.update),this.Ln=new Ra(this.el(),t)}};Fo.registerComponent("SeekBar",qa),f();var za=Fo.getComponent("ProgressControl");pi.Zs.Ks&&Fo.registerComponent("ProgressControl",class extends za{createEl(){return super.createEl("div",{className:"vjs-progress-control vjs-control"})}handleMouseMove(t){this.seekBar.handleMouseMove(t)}handleMouseDown(t){null==t.preventDefault||t.preventDefault.call(t),this.seekBar.handleMouseDown(t)}handleMouseUp(t){null==t.preventDefault||t.preventDefault.call(t),this.seekBar.handleMouseUp(t)}constructor(t,i){super(t,i),this.on(this,"touchmove",this.handleMouseMove),this.on("touchstart",this.handleMouseDown),this.on("touchend",this.handleMouseUp),this.seekBar.off(["touchmove","touchstart","touchend"])}}),f();var Wa=Fo.getComponent("TooltipProgressBar"),Ga=class extends(Ho(Wa)){updateDataAttr(){const t=$o(this.player()),i=this.Bn(t);this.el().setAttribute("data-current-time",i),this.tooltip.innerHTML=i}Bn(t){const i=this.xs;return Lo(t-Uo(i),Oo(i))}createEl(){const 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 Xa(t){for(const i of t)if(i.enabled)return i}function Ja(t){if(t)return t.label&&""!==t.label?{name:t.label,hd:!1}:{name:Qa(t),description:Ya(t),hd:!!t.height&&t.height>=720}}function Qa(t){return t.height?t.height+"p":t.bandwidth?Ya(t):""}function Ya(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":""}Fo.registerComponent("TooltipProgressBar",Ga),f(),f(),f(),f(),f();var Ka=class{get jr(){return this.Tr}set jr(t){const i=this.Tr;for(let s=i.length-1;s>=0;s--){const e=i[s];N(t,e)||this.Mr(e)}for(const i of t)this.Ar(i);this.Pr.oe()}get Nr(){return this.Pr.menuItems}Er(t){const i=this.Nr;if(i)for(const s of i)if(s.Br===t)return s}Ir(t){const i=this.Pr.addMenuItem();return i.Br=t,i.on("click",()=>this.Fr(i)),i.el().setAttribute("role","menuitemradio"),i}Dr(t){t.dispose()}$r(t){return!0}Ar(t){if(this.$r(t)){N(this.Tr,t)||this.Tr.push(t);const i=this.Er(t)||this.Ir(t);return this.Ur(i),i}this.Mr(t)}Mr(t){const i=this.Er(t);i&&(this.Pr.removeMenuItem(i),this.Dr(i)),A(this.Tr,t)}Oe(){const t=[];for(const i of this.Tr)t.push(i);for(const i of t)this.Mr(i);B(t)}constructor(t){this.Pr=void 0,this.Tr=[],this.Pr=t}},Za=class extends Ka{Rr(){return this.Or=h.createElement("span"),this.Or.className="theo-settings-control-menu-item-title",d(this.Or,this.Vr.localize("Quality")),this.Or}Lr(){return this.Hr=h.createElement("span"),this.Hr.className="theo-settings-control-menu-quality-automatic",d(this.Hr,this.Vr.localize("Automatic")),this.Hr}qr(){return this.zr=h.createElement("span"),d(this.zr,this.Vr.localize("Automatic")),this.zr}Wr(){return this.Gr=h.createElement("span"),this.Gr.className="theo-primary-color theo-settings-control-menu-item-hd-label",d(this.Gr,this.Vr.localize("HD")),this.Gr}Xr(){const t=h.createElement("span");t.className="theo-primary-color theo-settings-control-menu-item-value",t.appendChild(this.Hr),t.appendChild(h.createTextNode(" ")),t.appendChild(this.zr),t.appendChild(h.createTextNode(" ")),t.appendChild(this.Gr),this.Jr.el().appendChild(this.Or),this.Jr.el().appendChild(t),this.Jr.el().setAttribute("aria-label",this.Vr.localize("Open the video quality settings menu"))}Qr(){const t=this.Yr,i=t&&hu(t.targetQuality),s=t&&t.activeQuality,e=Ja(this.Kr(i||s))||{name:this.Vr.localize("Automatic")};d(this.zr,e.name),oi(this.Hr,"vjs-hidden",Boolean(i)),oi(this.Gr,"vjs-hidden",!e.hd)}Ur(t){const i=Ja(t.Br)||{name:this.Vr.localize("Automatic")};let s=i.name;i.hd&&(s+='<span class="theo-primary-color theo-settings-control-menu-item-hd-label">'+this.Vr.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.Vr.localize("Set video quality to ")+i.name),t.Br?t.selected(t.Br===this.Zr):t.selected(!this.Zr)}Fr(t){this.Yr&&(this.Yr.targetQuality=t.Br&&t.Br.videoQualities)}Kr(t,i){const s=i||this.jr;for(const i of s)if(t&&i&&-1!==i.videoQualities.indexOf(t))return i}Oe(){this.Cs.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.th),this.Vr.off("languagechange",this.se),this.Yr&&(this.Yr.removeEventListener("activequalitychanged",this.ih),this.Yr.removeEventListener("targetqualitychanged",this.sh),this.Yr.removeEventListener("update",this.eh)),super.Oe()}constructor(t,i,s){super(t.subMenu),this.Jr=void 0,this.Cs=void 0,this.Vr=void 0,this.Yr=void 0,this.Zr=void 0,this.Or=void 0,this.Hr=void 0,this.zr=void 0,this.Gr=void 0,this.th=()=>{const t=Xa(this.Cs.videoTracks);if(t===this.Yr)return;let i=[];if(this.Yr&&(this.Yr.removeEventListener("activequalitychanged",this.ih),this.Yr.removeEventListener("targetqualitychanged",this.sh),this.Yr.removeEventListener("update",this.eh)),this.Yr=t,t){t.addEventListener("activequalitychanged",this.ih),t.addEventListener("targetqualitychanged",this.sh),t.addEventListener("update",this.eh);const s=iu(nu(t.qualities.filter(t=>t.available)));i=s.length>1?[void 0,...s]:[void 0]}this.jr=i,this.sh(),this.ih()},this.eh=t=>{const i=t.track;if(i!==this.Yr)return;const s=iu(nu(i.qualities.filter(t=>t.available))),e=i&&hu(i.targetQuality);let n;this.Zr=this.Kr(e,s),n=s.length>1?[void 0,...s]:[void 0],this.jr=n,this.Qr()},this.ih=()=>{this.Ar(void 0),this.Qr()},this.sh=()=>{const t=Xa(this.Cs.videoTracks),i=t&&hu(t.targetQuality),s=this.Kr(i),e=this.Zr;s!==e&&(this.Zr=s,s&&e||this.Ar(void 0),e&&N(this.jr,e)&&this.Ar(e),i&&this.Ar(s),this.Qr())},this.se=()=>{d(this.Pr.menuHeader.el(),this.Vr.localize("Quality")),d(this.Or,this.Vr.localize("Quality")),d(this.Hr,this.Vr.localize("Automatic")),d(this.zr,this.Vr.localize("Automatic")),d(this.Gr,this.Vr.localize("HD")),this.Jr.el().setAttribute("aria-label",this.Vr.localize("Open the video quality settings menu"));for(const t of this.Nr)this.Ur(t);this.Qr()},this.Jr=t,this.Cs=i,this.Vr=s,this.Or=this.Rr(),this.Hr=this.Lr(),this.zr=this.qr(),this.Gr=this.Wr(),this.Xr(),d(this.Pr.menuHeader.el(),this.Vr.localize("Quality")),this.jr=[void 0],this.Cs.videoTracks.addEventListener(["addtrack","removetrack","change"],this.th),this.Vr.on("languagechange",this.se),this.th()}},tu=class{get height(){return this.nh[0].height}get bandwidth(){return this.nh[0].bandwidth}get videoQualities(){return this.nh}get label(){return this.nh[0].label}add(t){this.nh.push(t)}constructor(t){this.nh=void 0,this.nh=t}};function iu(t){const i=[];for(const s of t){const t=s;let e=!1;for(const s of i)if(ru(s,t)){s.add(t),e=!0;break}e||i.push(new tu([t]))}return i}function su(t,i){return t&&i?Ai(t,i):Ti.rh}function eu(t,i){return t===i?Ti.rh:su(t.height,i.height)||su(t.width,i.width)||su(t.bandwidth,i.bandwidth)}function nu(t){return xi(t,eu).reverse()}function ru(t,i){return t.label&&i.label&&t.label===i.label||ct(Ja(t),Ja(i))}function hu(t){return Lt(t)?1===t.length?t[0]:void 0:t}function ou(t){return 1===t?"Normal":""+_.round(100*t)/100}f();var au=class extends Ka{Rr(){return this.Or=h.createElement("span"),this.Or.className="theo-settings-control-menu-item-title",d(this.Or,this.Vr.localize("Speed")),this.Or}Xr(){const t=h.createElement("span");return t.className="theo-primary-color theo-settings-control-menu-item-value",this.Jr.el().appendChild(this.Or),this.Jr.el().appendChild(t),this.Jr.el().setAttribute("aria-label",this.Vr.localize("Open the video speed settings menu")),t}Ir(t){const i=super.Ir(t);return this.Ur(i),i}Ur(t){const i=t.Br,s=this.Vr.localize(ou(i));d(t.el(),s),t.el().setAttribute("aria-label",this.Vr.localize("Set video speed to ")+s),t.selected(t.Br===this.Cs.playbackRate)}Fr(t){this.Cs.playbackRate=t.Br}Oe(){this.Cs.removeEventListener("ratechange",this.hh),this.Vr.off("languagechange",this.se),super.Oe()}constructor(t,i,s,e){super(t.subMenu),this.Jr=void 0,this.Cs=void 0,this.Vr=void 0,this.oh=void 0,this.Or=void 0,this.ah=void 0,this.hh=()=>{this.oh&&this.Ar(this.oh);const t=this.Cs.playbackRate;this.oh=t,d(this.ah,this.Vr.localize(ou(t))),t&&this.Ar(t)},this.se=()=>{d(this.Pr.menuHeader.el(),this.Vr.localize("Speed")),d(this.Or,this.Vr.localize("Speed")),this.Jr.el().setAttribute("aria-label",this.Vr.localize("Open the video speed settings menu"));for(const t of this.Nr)this.Ur(t);this.hh()},this.Jr=t,this.Cs=i,this.Vr=s,this.Or=this.Rr(),this.ah=this.Xr(),d(this.Pr.menuHeader.el(),this.Vr.localize("Speed")),this.jr=e,this.Cs.addEventListener("ratechange",this.hh),this.Vr.on("languagechange",this.se),this.hh()}};Fo.registerComponent("SettingsButton",class extends va{createEl(){const t=super.createEl();return this.uh=Fo.createEl("span",{className:"theo-settings-control-label-hd theo-primary-background"}),d(this.uh,this.localize("HD")),t.appendChild(this.uh),t}buildCSSClass(){return"vjs-icon-cog theo-settings-control-button "+super.buildCSSClass()}se(){super.se(),d(this.uh,this.localize("HD")),d(this.menu.menuHeader.el(),this.localize("Settings"))}dispose(){this.Yr&&(this.Yr.removeEventListener("activequalitychanged",this.ih),this.Yr=void 0),this.xs.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.dh),this.fh.Oe(),this.ph.Oe(),super.dispose()}constructor(t,i){var s,e;super(t,i),this.mh=void 0,this.fh=void 0,this.gh=void 0,this.ph=void 0,this.Yr=void 0,this.dh=()=>{const t=Xa(this.xs.videoTracks);t!==this.Yr&&(this.Yr&&this.Yr.removeEventListener("activequalitychanged",this.ih),this.Yr=t,t&&t.addEventListener("activequalitychanged",this.ih),this.ih())},this.ih=()=>{var t;const i=null==(t=this.Yr)?void 0:t.activeQuality,s=Boolean(i&&i.height>=720);this.player().toggleClass("theo-hd",s)},ei(this.menu.el(),"theo-settings-control-menu"),d(this.menu.menuHeader.el(),t.localize("Settings")),this.controlText("Settings"),this.De.Fe=this.controlText(),this.mh=this.menu.addSubMenuItem({name:"QualityMenuItem"}),this.fh=new Za(this.mh,this.xs,t);const n=null!=(e=null==i||null==(s=i.playerOptions)?void 0:s.playbackRates)?e:[];this.gh=this.menu.addSubMenuItem({name:"PlaybackRateMenuItem"}),this.ph=new au(this.gh,this.xs,t,n),this.xs.videoTracks.addEventListener(["addtrack","removetrack","change"],this.dh),this.dh()}}),f(),f(),f();var uu=class extends Ka{yh(t){const i=t.label;if(i)return i;const s=t.language;if(s){const t=St(s);if(t)return t.bh}return s||""}kh(){this.jr=this.wh}Oe(){this.wh.removeEventListener("addtrack",this._h),this.wh.removeEventListener("removetrack",this.xh),this.wh.removeEventListener("change",this.Ch),super.Oe()}constructor(t,i){super(t),this.wh=void 0,this._h=t=>{const i=t.track;this.Ar(i),i.addEventListener("update",this.Sh)},this.xh=t=>{const i=t.track;this.Mr(i),i.removeEventListener("update",this.Sh)},this.Ch=t=>this.kh(),this.Sh=()=>{for(const t of this.jr)this.Ar(t)},this.wh=i,this.wh.addEventListener("addtrack",this._h),this.wh.addEventListener("removetrack",this.xh),this.wh.addEventListener("change",this.Ch),this.kh()}},cu=class extends uu{Ur(t){const i=t.Br,s=this.Vr.localize(this.yh(i));d(t.el(),s),t.el().setAttribute("aria-label",this.Vr.localize("Set the audio language to")+" "+s),t.selected(i.enabled)}Fr(t){const i=t.Br;for(const t of this.xs.audioTracks)t!==i&&(t.enabled=!1);i.enabled=!0}Oe(){this.Vr.off("languagechange",this.se),super.Oe()}constructor(t,i,s){super(t,i.audioTracks),this.xs=void 0,this.Vr=void 0,this.se=()=>{d(this.Pr.menuHeader.el(),this.Vr.localize("Language"));for(const t of this.Nr)this.Ur(t)},this.xs=i,this.Vr=s,d(this.Pr.menuHeader.el(),this.Vr.localize("Language")),this.Vr.on("languagechange",this.se)}};Fo.registerComponent("audioTrackButton",class extends va{buildCSSClass(){return"vjs-icon-audio theo-audio-track-control-button "+super.buildCSSClass()}dispose(){this.jh.Oe(),super.dispose()}constructor(t,i){super(t,i),this.jh=void 0,this.minimumMenuItems=2,this.jh=new cu(this.menu,this.xs,t),this.controlText("Language"),this.De.Fe=this.controlText()}}),f(),f();var lu=class extends uu{$r(t){return!!super.$r(t)&&(!t.forced&&At(t.kind))}Ir(t){const i=super.Ir(t);ei(i.el(),"theo-text-track-menu-item");const s=h.createElement("span");i.Th=s;const e=h.createElement("div");e.className="theo-text-track-menu-item-toggle",i.Mh=e;const n=t=>this.Ah(t,i);i.Ph=n,e.addEventListener("click",n);const 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}Ur(t){const i=t,s=i.Br,e=this.Vr.localize(this.yh(s));d(i.Th,e),i.el().setAttribute("aria-label",this.Vr.localize("Set the subtitle language to")+" "+e),i.el().setAttribute("role","menuitemcheckbox"),i.selected(s.mode===Ct.Kn)}Dr(t){const i=t;i.Mh.removeEventListener("click",i.Ph),super.Dr(t)}Fr(t){const i=t.Br;for(const t of this.xs.textTracks)t!==i&&T(t.kind,i.kind)&&(t.mode=Ct.Nh);i.mode!==Ct.Kn?i.mode=Ct.Kn:i.mode=Ct.Nh}Ah(t,i){t.stopImmediatePropagation(),this.Fr(i)}Oe(){this.Vr.off("languagechange",this.se),super.Oe()}constructor(t,i,s){super(t,i.textTracks),this.xs=void 0,this.Vr=void 0,this.se=()=>{d(this.Pr.menuHeader.el(),this.Vr.localize("Subtitles"));for(const t of this.Nr)this.Ur(t)},this.xs=i,this.Vr=s,d(this.Pr.menuHeader.el(),s.localize("Subtitles")),this.Vr.on("languagechange",this.se)}};Fo.registerComponent("subtitlesButton",class extends va{buildCSSClass(){return"vjs-icon-subtitles theo-text-track-control-button "+super.buildCSSClass()}dispose(){this.jh.Oe(),super.dispose()}constructor(t,i){super(t,i),this.jh=void 0,this.jh=new lu(this.menu,this.xs,t),this.controlText("Subtitles"),this.De.Fe=this.controlText()}}),f();var du=Fo.getComponent("playToggle"),fu=class extends(Ho(du)){handleClick(t){this.xs.muted||this.xs.prepareWithUserAction(),super.handleClick(t)}handlePlay(t){super.handlePlay(t),this.controlText("Pause"),this.De.Fe=this.controlText()}handlePause(t){this.xs.ended||(super.handlePause(t),this.controlText("Play"),this.De.Fe=this.controlText())}se(){this.De.Fe=this.controlText()}dispose(){this.De.Oe(),this.xs.removeEventListener("ended",this.Eh),super.dispose()}constructor(t,i){super(t,i),this.De=void 0,this.Eh=()=>{this.controlText("Replay"),this.De.Fe=this.controlText()},this.controlText("Play"),this.De=new da(this,this.controlText()),this.xs.addEventListener("ended",this.Eh),this.on(t,"languagechange",this.se),pi.Zs.Ke&&new Zo(this.el())}};Fo.registerComponent("playToggle",fu),f();var vu=Fo.getComponent("fullscreenToggle"),pu=class extends(Ho(vu)){handleClick(t){this.xs.prepareWithUserAction(),super.handleClick(t)}handleFullscreenChange(t){super.handleFullscreenChange(t),this.updateContent()}updateContent(){const t=this.player().isFullscreen()?"Exit fullscreen":"Fullscreen";this.controlText(t),this.De.Fe=this.controlText()}dispose(){this.De.Oe(),super.dispose()}constructor(t,i){super(t,i),this.De=void 0,this.controlText("Fullscreen"),this.De=new da(this,this.controlText()),pi.Zs.Ke&&new Zo(this.el()),this.on(t,"languagechange",this.updateContent)}};Fo.registerComponent("fullscreenToggle",pu),f();var mu=Fo.getComponent("muteToggle"),gu=class extends(Ho(mu)){handleClick(t){this.xs.muted&&!this.xs.paused&&this.xs.prepareWithUserAction(),super.handleClick(t)}update(t){super.update(t),this.se()}se(){const t=this.player().muted()?"Unmute":"Mute";this.controlText(t),this.De.Fe=this.controlText()}dispose(){this.De.Oe(),super.dispose()}constructor(t,i){super(t,i),this.De=void 0,this.controlText("Mute"),this.De=new da(this,this.controlText()),pi.Zs.Ke&&new Zo(this.el()),this.on(t,"languagechange",this.se),R&&(this.removeClass("vjs-hidden"),this.on(t,"loadstart",()=>{this.removeClass("vjs-hidden")}))}};Fo.registerComponent("muteToggle",gu),f();var yu=Fo.getComponent("BigPlayButton"),bu="theo-play-svg-circle",ku='<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="'+bu+'" 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>',wu=class extends(Ho(yu)){createEl(){const t=super.createEl(),i=Fo.createEl("div",{className:"theo-big-play-button-svg-container"});return i.innerHTML=ku,t.appendChild(i),t}buildCSSClass(){return"theo-primary-color "+super.buildCSSClass()}handleClick(t){this.xs.muted||this.xs.prepareWithUserAction(),super.handleClick(t),void 0!==this.xs.vr&&"unavailable"!==this.xs.vr.state&&(this.xs.vr.useDeviceMotionControls=!0)}};Fo.registerComponent("BigPlayButton",wu),f();var _u=/^([^#]*)#xywh=(\d+),(\d+),(\d+),(\d+)\s*$/;Fo.registerComponent("MouseTimeDisplay",class extends Ia{Bh(t){const i=t.track;"metadata"===i.kind&&"thumbnails"===i.label&&void 0===this.Ih&&(this.Ih=i,this.Fh=i.src?pi.Dh(i.src).href:void 0,this.Ih.addEventListener(["addcue","removecue"],this.$h),this.Uh())}Rh(t){t.track===this.Ih&&this.Oh()}createEl(){const t=super.createEl();return this.Vh=Fo.createEl("img",{className:"theo-time-tooltip-thumbnail"}),this.Lh=Fo.createEl("canvas",{className:"theo-time-tooltip-thumbnail"}),t}update(t,i){super.update(t,i),this.keepTooltipsInside&&this.Hh(t)}Hh(t){let i;if(this.Ih&&this.Ih.cues){const s=function(t,i){let s=t[0];for(const e of t)if(e.startTime<=i)s=e;else if(i>=e.endTime)return s;return s}(this.Ih.cues,t);i=s&&s.content}if(i===this.qh)return;if(this.qh=i,Fo.toggleClass(this.el(),"theo-time-tooltip-has-thumbnail",Boolean(i)),!i)return void this.zh();const s=i.match(_u);if(s){let[,t,i,e,n,r]=s;t=this.Wh(t);const h={Gh:Number(i),Xh:Number(e),Ti:Number(n),Mi:Number(r)};this.Jh(t,h)}else{const t=this.Wh(i);this.Jh(t)}}Uh(){S(this.En)||this.Hh(this.En)}Wh(t){return this.Ih&&this.Fh?pi.Dh(t,this.Fh).href:t}Jh(t,i){this.Vh&&(this.Vh.src!==t?(this.Vh.onload=()=>{this.Qh(i)},this.Vh.src="",this.Vh.src=t):this.Qh(i))}Qh(t){if(!this.Lh||!this.Vh)return;const i=this.Lh.getContext("2d");i&&(null!=t||(t={Gh:0,Xh:0,Ti:this.Vh.naturalWidth,Mi:this.Vh.naturalHeight}),this.Lh.width=t.Ti,this.Lh.height=t.Mi,i.drawImage(this.Vh,t.Gh,t.Xh,t.Ti,t.Mi,0,0,t.Ti,t.Mi),this.Yh(this.Lh))}Yh(t){this.Kh||(Zt(this.tooltip,t),this.Kh=t),this.In()}zh(){this.Kh&&(this.tooltip.removeChild(this.Kh),this.Kh=void 0,this.In())}Oh(){void 0!==this.Ih&&(this.Ih.removeEventListener(["addcue","removecue"],this.$h),this.Ih=void 0),this.Fh=void 0,this.zh(),this.qh=void 0}dispose(){this.Oh(),super.dispose()}constructor(t,i){super(t,i),this.Kh=void 0,this.Ih=void 0,this.Fh=void 0,this.Zh=t=>this.Bh(t),this.io=t=>this.Rh(t),this.$h=t=>this.Uh(),this.qh=void 0,this.showThumbnails=()=>{this.Kh&&this.Kh.hidden&&(this.Kh.hidden=!1,this.In())},this.hideThumbnails=()=>{!this.Kh||this.Kh.hidden||this.player().scrubbing()||(this.Kh.hidden=!0,this.In())},this.on(this.player().textTracks(),"addtrack",this.Zh),this.on(this.player().textTracks(),"removetrack",this.io),Dt.Ks&&(this.on(t,"seeking",this.showThumbnails),this.on(t,"seeked",this.hideThumbnails))}}),f();var xu=Fo.getComponent("VolumeLevel");Fo.registerComponent("VolumeLevel",class extends xu{createEl(){const t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-volume-level "+super.buildCSSClass()}}),f(),f();var Cu=Fo.getComponent("Component"),Su=class extends Cu{createEl(){const t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-menu-container "+super.buildCSSClass()}};Su.prototype.h=z({},Su.prototype.h,{children:[]}),Fo.registerComponent("controlBarMenuContainer",Su);var ju=Fo.getComponent("Player"),Tu=class extends ju{dispose(){const t=this.el(),i=this.contentEl(),s=t.parentNode,e=t.nextSibling;super.dispose(),Yt(i),this.Si&&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)}};Tu.prototype.h=z({},ju.prototype.h,{children:["bigPlayButton","AdControlPanel","TopControlBar","mediaLoader","upNextContainer","posterImage","chromecastOverlay","upcomingAdNotificationText","controlBarMenuContainer","controlBar","textTrackDisplay","loadingSpinner","errorDisplay","textTrackSettings","xrCompass"]}),Fo.registerComponent("Player",Tu),f(),f();var Mu=Fo.getComponent("Player"),Au=Mu.prototype.ns;Mu.prototype.ns=function(t){if(!(this.H&&this.H.Rs&&this.H.Rs()))return Au.call(this,t)};var Pu=Mu.prototype.createEl;function Nu(t,i,e,n){const r=z({controls:!0,playbackRates:[.25,.5,1,1.25,1.5,2]},e);r.controlBar=z({progressControl:{keepTooltipsInside:!0}},r.controlBar);const h=r.techOrder||(r.techOrder=[]);-1===h.indexOf("THEOplayer")&&h.unshift("THEOplayer");(r.theoplayer||(r.theoplayer={})).player=t,e&&zt(e.language)&&(r.languages=z({},r.languages,{[xt]:e.language}),r.language=xt),i.setAttribute("data-vjs-player","");const o=i.getAttribute("style"),a=Fo(t.element,r,n);return a.ready(()=>{zo(a),function(t,i){if(i){if(i.ads){const s=i=>{const s="adbreakbegin"===i.type,e=i.adBreak.integration===M.so;Wo(t,s,e)};i.ads.addEventListener("adbreakbegin",s),i.ads.addEventListener("adbreakend",s)}if(i.uplynk){var s;const e=i=>{const s="adbreakbegin"===i.type;Wo(t,s,!1)};null==(s=i.uplynk)||s.ads.adBreaks.addEventListener("addadbreak",t=>{t.adBreak.addEventListener("adbreakbegin",e),t.adBreak.addEventListener("adbreakend",e)})}i.addEventListener("sourcechange",()=>{Wo(t,!1,!1)})}}(a,t),function(t){t.on("mouseleave",Go)}(a)}),i.removeAttribute("data-vjs-player"),o?i.setAttribute("style",o):i.removeAttribute("style"),pi.Zs.Ks&&(ei(i,"theo-mobile"),function(t){const i=s.outerHeight,e=s.outerWidth,n=i>e;n?(ri(t,"theo-mobile-landscape"),ei(t,"theo-mobile-portrait")):(ri(t,"theo-mobile-portrait"),ei(t,"theo-mobile-landscape"))}(i)),function(t){t.on("seeking",()=>{ii(t.el(),"vjs-ended")&&t.currentTime()!==t.duration()&&t.play()})}(a),a}Mu.prototype.createEl=function(){const t=Pu.call(this),i=Fo.createEl("div");for(i.className="theo-player-wrapper";t.firstChild;)i.appendChild(t.firstChild);return t.appendChild(i),this.S=i,t},f(),f(),f(),f();var Eu=Fo.getComponent("Button");var Bu="THEOPiPCloseButton";Fo.registerComponent(Bu,class extends Eu{buildCSSClass(){return"theo-close-button theo-pip-close"}handleClick(){this.no.eo()}constructor(t,i){if(super(t,i),this.no=void 0,this.controlText("Close Picture-in-Picture"),!function(t){return!!t&&Boolean(t.no)}(i))throw new m("Invalid Picture-in-picture options.");this.no=i.no}});var Iu=class extends Y{get ro(){return this.ho}get oo(){return this.t.ds()}ao(){this.t.wn(it.uo,this.co),this.lo||this.t.wn(it.do,this.fo),this.t.vo.on("languagechange",this.se)}po(){var t;return"theo-pip-"+(null!=(t=this.mo)?t:"bottom-right")}yo(t){const i=this.bo;i&&!this.oo&&(this.ko||this.wo(),this._o(),ei(i,"theo-pip"),ei(i,this.po()),this.ho=!0,this.xo=t,this.Co=!1,this.So(new Ei(ni.PICTURE_IN_PICTURE)))}jo(t){const i=this.bo;i&&(this.To(),ri(i,"theo-pip"),ri(i,this.po()),this.ho=!1,this.Co=t,this.Mo=this.xo,this.xo=!1,this.So(new Ei(ni.INLINE)))}wo(){if(!this.ko){const t=this.t.vo;t.addChild(Bu,{no:this});const i=h.createElement("div");i.className="theo-pip-overlay",this.Ao=h.createElement("div"),this.Ao.className="theo-pip-overlay-text",d(this.Ao,t.localize("Video playing in Picture-in-Picture mode")),i.appendChild(this.Ao),Zt(t.el(),i),this.Po=i,this.ko=!0}}No(){this.Eo&&!this.Bo&&this.t.Io&&(this.Fo=this.t.Io.Do(et,this.$o),this.Bo=!0)}Uo(){this.Fo&&this.t.Io&&(this.t.Io.Ro(this.Fo),this.Bo=!1)}_o(){const t=this.t.vo.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"}To(){const t=this.t.vo.contentEl();t.style.top="",t.style.bottom="",t.style.right="",t.style.left="",t.style.width="",t.style.height="",t.style.position=""}Oo(){ri(this.bo,"theo-pip"),this.ro&&this.mo&&ri(this.bo,"theo-pip-"+this.mo),this.Po&&(Yt(this.Po),this.Po=void 0)}kn(){this.Oo(),this.Uo(),this.Vo(),this.t.mn(it.uo,this.co),this.t.mn(it.do,this.fo),this.t.vo.off("languagechange",this.se),this.t=void 0}constructor(t,i,s){super(),this.Lo=void 0,this.mo=void 0,this.lo=void 0,this.t=void 0,this.bo=void 0,this.Ho=!1,this.ho=!1,this.Co=!1,this.xo=!1,this.ko=!1,this.eo=void 0,this.Bo=!1,this.Fo=void 0,this.Po=void 0,this.Ao=void 0,this.Mo=!1,this.Eo=void 0,this.co=()=>{this.Ho=!0,this.Eo&&!this.ro&&this.Fo&&this.Lo&&this.Fo.qo<=this.Lo&&this.yo(!1)},this.fo=()=>{this.lo||(this.Ho=!1,this.eo(),this.jo(!1))},this.se=()=>{if(this.Ao){const t=this.t.vo;d(this.Ao,t.localize("Video playing in Picture-in-Picture mode"))}},this.$o=t=>{!this.xo&&this.Eo&&(S(t)||(this.Lo&&t<=this.Lo||this.Mo?this.ho||this.Co||this.yo(!1):this.ho?this.jo(!1):this.Co=!1))},this.Lo=i.visibility,this.mo=i.position,this.lo=i.retainPresentationModeOnSourceChange,this.Eo=void 0!==this.Lo,this.t=t,this.bo=t.zo,this.eo=s,this.ao()}},Fu=class extends E{Wo(){const t=super.Wo();return t===ni.INLINE&&this.Go.ro?ni.PICTURE_IN_PICTURE:t}Xo(t){return t===ni.PICTURE_IN_PICTURE||super.Xo(t)}Jo(t){this.Qo=this.Yo,t===ni.FULLSCREEN||t===ni.NATIVE_PICTURE_IN_PICTURE?this.Go.Uo():this.Go.No(),super.Jo(t)}Ko(t){super.Ko(t),t===ni.PICTURE_IN_PICTURE?$(this.ta.Zo(t=>this.ia(t))):t===ni.FULLSCREEN?this.Go.jo(!1):this.Go.jo(!0)}async ia(t){F(t),await Promise.all([this.sa(),this.ea.jo()]).catch(gi),F(t),this.Go.yo(!this.na),this.So(new Ei(this.Yo)),this.na=!1,this.ra=!1}_i(){this.ra||(this.Go.ro&&this.ha.ds?this.Jo(ni.FULLSCREEN):this.Qo!==ni.PICTURE_IN_PICTURE||this.ha.ds?super._i():(this.na=!0,this.Jo(ni.PICTURE_IN_PICTURE)))}kn(){super.kn(),this.Go.kn(),this.oa.mn(it.uo,this.aa),this.oa=void 0}constructor(t,i,s,e){super(i,s),this.oa=void 0,this.Go=void 0,this.Qo=ni.INLINE,this.na=!1,this.eo=()=>{this.Yo===ni.PICTURE_IN_PICTURE&&this.Jo(ni.INLINE)},this.ua=t=>{this.ra||(this.Yo!==ni.PICTURE_IN_PICTURE||this.Go.ro?this.Yo!==ni.PICTURE_IN_PICTURE&&this.Go.ro&&(this.na=!0,this.Jo(ni.PICTURE_IN_PICTURE)):this.Jo(ni.INLINE))},this.aa=()=>{this.Wo()!==ni.PICTURE_IN_PICTURE&&this.Wo()!==ni.INLINE||this.Go.No(),this.oa.mn(it.uo,this.aa)},this.oa=t,this.Go=new Iu(t,e.pip,this.eo),this.Go.wn(Pi.MODE_CHANGE,this.ua),this.oa.wn(it.uo,this.aa)}};f();var Du=class extends Y{get ca(){return Mi.la(this.vo.el())||this.vo.supportsFullScreen()}get ds(){return this.vo.isFullscreen()||this.da}yo(){this.vo.requestFullscreen()}jo(){this.vo.exitFullscreen(),this.fa.jo()}kn(){this.Vo(),this.vo.off("fullscreenchange",this.va),this.fa.mn(di.pa,this.va),this.fa.mn(di.ma,this.Us),this.vo.isFullWindow&&this.vo.exitFullscreen()}constructor(t,i){super(),this.vo=void 0,this.fa=void 0,this.Vs=!1,this.da=!1,this.ga=!1,this.va=()=>{if(this.ga)return;const t=this.Vs,i=this.ds;t!==i&&(this.Vs=i,this.So(new Ci))},this.ya=()=>{this.da=this.fa.ds,this.va()},this.ba=()=>{this.ga||(this.vo.isFullWindow&&this.vo.supportsFullScreen()||this.da&&!this.vo.supportsFullScreen())&&(this.ga=!0,this.vo.exitFullscreen(),this.vo.requestFullscreen(),this.ga=!1,this.va())},this.vo=t,this.fa=i,this.vo.on("fullscreenchange",this.va),this.fa.wn(di.pa,this.ya),this.fa.wn(di.ka,this.ba),this.fa.wn(di.ma,this.Us),this.va()}};function $u(t){return class extends t{get Io(){return this.wa}ds(){return this._a.Wo()===ni.FULLSCREEN}xa(){return function(t,i){const s=w.create(t),e=i.vo;return at(s,{get controls(){return e.controls()},set controls(t){e.controls(vt(t))},get presentation(){return i._a.Ca},get presentationMode(){return i._a.Wo()},set presentationMode(t){const s=ai(t);s&&i._a.Jo(s)},get ui(){return e},get visibility(){return i.Io.Ca}})}(this.Sa,this)}kn(){super.kn(),this._a.kn(),this.ja.kn(),this.vo.dispose(),this.wa.kn()}Ta(t){this.vo.src(""),super.Ta(t)}constructor(t,i,s){super(i,s),this.zo=void 0,this.vo=void 0,this.Sa=void 0,this.wa=void 0,this._a=void 0,this.ja=void 0,this.zo=t,this.wa=new rt(t),this.Sa=super.xa(),w.defineProperty(this.Sa,"constructor",{value:lt}),this.vo=Nu(this.Sa,this.zo,s.ui),this.ja=new Du(this.vo,this.Ma),this._a=new Fu(this,this.ja,this.Pa.Aa(),s),this._a.wn(Pi.MODE_CHANGE,this.Us)}}}function Uu(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(Rt(t)&&!S(t))return Si(t,0,1)}(t.visibility),t.retainPresentationModeOnSourceChange=vt(t.retainPresentationModeOnSourceChange),t}f(),f();var Ru=wi(()=>{let t=$u(ut());return t=function(t){let i=t;for(const t of Bi)i=t(i);return i}(t),t});function Ou(t,i){const s=function(t){const i=hi(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=Uu(i.pip),i}(i),e=h.createElement("div");ui(e),t.appendChild(e);const n=new(Ru())(t,e,s);n.Na=n;let r=n.Ca;return n.Ea(),n.Ba(ot),w.defineProperty(r,"constructor",{value:Ou}),r=ht(r),Ht(n),function(t){for(const i of Fi)i(t)}(n),r}f(),f(),f();var Vu="theo-cast-",Lu=Fo.getComponent("Button"),Hu=class extends(Ho(Lu)){get Ia(){throw new m("Fa")}get Da(){return this.h.Da}get $a(){return this.h.$a}buildCSSClass(){return Vu+"button theo-"+this.$a+"-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=Vu+"svg-container",r.innerHTML=this.Da,e.appendChild(n),e.appendChild(r),e}handleClick(t){var i;if(super.handleClick(t),this.Ua===Kt.AVAILABLE)null==(i=this.Ia)||i.start();else if(this.Ua===Kt.CONNECTED||this.Ua===Kt.CONNECTING){var s;null==(s=this.Ia)||s.stop()}}Ra(t){ri(this.bo,"theo-"+this.$a+"-"+this.Ua),this.Ua=t,ei(this.bo,"theo-"+this.$a+"-"+this.Ua),this.se()}se(){this.Oa(this.Ua),this.De.Fe=this.controlText()}Oa(t){t===Kt.CONNECTED?this.controlText("Stop Casting"):t===Kt.AVAILABLE?this.controlText("Start Casting"):t===Kt.CONNECTING?this.controlText("Connecting"):this.controlText("Unavailable")}constructor(t,i){var s;super(t,i),this.bo=void 0,this.Ua=void 0,this.De=void 0,this.Va=void 0,this.bo=t.el(),this.Ua=Kt.UNAVAILABLE,this.controlText("Unavailable"),this.De=new da(this,this.controlText()),null==(s=this.Ia)||s.addEventListener("statechange",t=>{const i=t;this.Ra(i.state)}),pi.Zs.Ke&&(this.Va=new Zo(this.el())),this.Ra(this.Ia?this.Ia.state:Kt.UNAVAILABLE),this.on(t,"languagechange",this.se)}},qu=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-'+qu+'">\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-'+qu+')">\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 qu++,t}Fo.registerComponent("chromecastButton",class extends Hu{get Ia(){var t;return null==(t=this.xs.cast)?void 0:t.chromecast}constructor(t,i){super(t,z({},i,{$a:"chromecast",Da:zu()}))}}),f();var Wu="theo-chromecast-",Gu=Fo.getComponent("Component"),Xu=class t extends(Ho(Gu)){buildCSSClass(){return Wu+"overlay "+super.buildCSSClass()}createEl(){const i=super.createEl();ei(i,Wu+"overlay");const s=Fo.createEl("div",{className:Wu+"status-icon",innerHTML:t.ICON_SVG}),e=Fo.createEl("div",{className:Wu+"status-info"});d(e,"Playing on");const n=Fo.createEl("div",{className:Wu+"status-title"}),r=Fo.createEl("div",{className:Wu+"status"});return this._r=n,r.appendChild(s),r.appendChild(e),r.appendChild(n),i.appendChild(r),i}dispose(){var t;null==(t=this.La)||t.removeEventListener("statechange",this.update),this.La=void 0,this.xs.removeEventListener("play",this.update),super.dispose()}constructor(t,i){var s,e;super(t,i),this.La=void 0,this.update=()=>{this.La?(this._r&&d(this._r,this.La.receiverName||""),this.La.state===Kt.CONNECTED?this.show():this.hide()):this.hide()},this.La=null==(s=this.xs.cast)?void 0:s.chromecast,null==(e=this.La)||e.addEventListener("statechange",this.update),this.xs.addEventListener("play",this.update),this.update()}};Xu.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>',Fo.registerComponent("chromecastOverlay",Xu),f(),f();Fo.registerComponent("airplayButton",class extends Hu{dispose(){var t,i;null==(t=this.xs.ads)||t.removeEventListener("adbreakbegin",this.Ha),null==(i=this.xs.ads)||i.removeEventListener("adbreakend",this.qa),this.xs.removeEventListener("currentsourcechange",this.qa),super.dispose()}get Ia(){var t;return null==(t=this.xs.cast)?void 0:t.airplay}constructor(t,i){var s,e;super(t,z({},i,{$a:"airplay",Da:'\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.qa=()=>{this.enable()},this.Ha=t=>{"theoads"!==t.adBreak.integration&&"google-dai"!==t.adBreak.integration&&this.disable()},null==(s=this.xs.ads)||s.addEventListener("adbreakbegin",this.Ha),null==(e=this.xs.ads)||e.addEventListener("adbreakend",this.qa),this.xs.addEventListener("currentsourcechange",this.qa)}}),f(),f(),f();var Ju=Fo.getComponent("Button"),Qu=class extends(Ho(Ju)){buildCSSClass(){return"theo-vr-button theo-controlbar-button "+super.buildCSSClass()}handleClick(){this.xs.vr.stereo=!this.xs.vr.stereo,this.se()}Sn(){const t=this.xs.vr;t&&t.state!==Vt.Os?(this.show(),t.canPresentVR?this.enable():this.disable()):this.hide(),this.se()}se(){const t=this.xs.vr;t&&t.state!==Vt.Os&&(t.stereo?this.controlText("Stop watching in VR"):t.canPresentVR?this.controlText("Watch in VR"):this.controlText("No VR capable device found"),this.za.Fe=this.controlText())}dispose(){var t;null==(t=this.xs.vr)||t.removeEventListener(["statechange","stereochange"],this.Wa),super.dispose()}constructor(t,i){var s;super(t,i),this.za=void 0,this.Va=void 0,this.Wa=()=>this.Sn(),this.controlText("Watch in VR"),this.za=new da(this,this.controlText()),null==(s=this.xs.vr)||s.addEventListener(["statechange","stereochange"],this.Wa),this.Sn(),pi.Zs.Ke&&(this.Va=new Zo(this.el())),this.on(t,"languagechange",this.se)}};Fo.registerComponent("vrButton",Qu),f();var Yu=Fo.getComponent("Component"),Ku=class extends Yu{createEl(){const t=super.createEl("div",{className:this.buildCSSClass()}),i=Fo.createEl("div",{className:"theo-360-fov"});return t.appendChild(i),this.Ga=i,t}buildCSSClass(){return"theo-360-compass "+super.buildCSSClass()}Sn(){this.xs.vr.state===Vt.Os?this.hide():this.show()}Xa(){const t=-this.xs.vr.direction.yaw+40;this.Ga.style[ki("transform")]="scale(0.875) rotate("+t+"deg) skew("+"-10deg)"}dispose(){this.xs.vr.removeEventListener("statechange",this.Wa),this.xs.vr.removeEventListener("directionchange",this.Ja),super.dispose()}constructor(t,i,s){super(t,i),this.xs=void 0,this.Wa=()=>this.Sn(),this.Ja=()=>this.Xa(),this.xs=s,this.xs.vr.addEventListener("statechange",this.Wa),this.xs.vr.addEventListener("directionchange",this.Ja),this.Sn(),this.Xa()}};f();var Zu=Fo.getComponent("Component"),tc=class extends Zu{Qa(){this.xs.vr.state===Vt.Ya?this.Ka():this.Za()}Ka(){if(this.tu)return;this.tu=!0;const t=this.xs.element;this.iu=t.style.zIndex||"",t.style.zIndex="2147483647",this.su=this.player().isFullscreen(),this.player().requestFullscreen()}Za(){if(!this.tu)return;this.tu=!1;this.xs.element.style.zIndex=this.iu,this.su?this.player().requestFullscreen():this.player().exitFullscreen()}dispose(){this.Za(),this.xs.vr.removeEventListener("statechange",this.eu),super.dispose()}constructor(t,i,s){super(t,i),this.xs=void 0,this.tu=!1,this.su=!1,this.iu="",this.eu=()=>this.Qa(),this.xs=s,this.xs.vr.addEventListener("statechange",this.eu),this.Qa()}};Di(function(t){const i=t.Ca;if(!i.vr)return;const s=t.vo,e=new Ku(s,{},i);if(t.wn(it.do,()=>{var i;s.removeChild(e);const n=null==(i=t.nu())?void 0:i.vr;void 0===n||n.nativeVR||s.addChild(e)}),Dt.ru){const t=new tc(s,{},i);s.addChild(t)}}),f(),f(),f();var ic=class extends Z{constructor(){super("relatedchange")}},sc=["relatedchange"],ec=class extends Y{get Ca(){return this.hu||(this.hu=function(t){let i;const s={get sources(){return t.ou},set sources(i){t.ou=i},addEventListener(t,s){i.wn(t,s)},removeEventListener(t,s){i.mn(t,s)}};return i=new P(sc,!0,s),i.au(t),s}(this)),this.hu}get ou(){return this.uu}set ou(t){this.uu=function(t){return t.filter(t=>t&&(Xt(t.link)||dt(t,["source"])))}(t),t.length>this.uu.length&&console.warn("One or more of the configured related content sources are invalid. Check if they have a source or a link."),this.So(new ic)}kn(){this.Vo(),this.uu=[]}constructor(...t){super(...t),this.hu=void 0,this.uu=[]}};Ot(function(t){return class extends t{xa(){const t=this.cu;return at(super.xa(),{get related(){return t.Ca}})}kn(){this.cu.kn(),super.kn()}constructor(t,i){super(t,i),this.cu=void 0,this.cu=new ec}}},$t.lu),f(),f();var nc=Fo.getComponent("Button"),rc=class extends nc{buildCSSClass(){return"vjs-icon-view-grid theo-related-button "+super.buildCSSClass()}handleClick(){this.fu.du?this.fu.we():this.fu.be()}se(){this.De.Fe=this.controlText()}dispose(){this.player().topControlBar.removeChild(this),super.dispose()}constructor(t,i,s){super(t,s),this.bo=void 0,this.fu=void 0,this.De=void 0,this.bo=t.el(),this.fu=i,this.player().topControlBar.addChild(this),this.hide(),this.controlText(this.localize("Related content")),this.De=new da(this,this.controlText()),this.on(t,"languagechange",this.se)}};f(),f();var hc=Fo.getComponent("Button"),oc=class extends hc{buildCSSClass(){return"theo-secondary-background theo-close-button"}handleClick(){this.vu.hide()}constructor(t,i){super(t),this.vu=void 0,this.vu=i}},ac=(()=>{const 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 uc(t,i,s){const e=ac.cloneNode(!0),n=e.querySelector(".theo-related-grid-tile-content");dt(s,["source"])?(n.style.cursor="pointer",n.addEventListener("click",()=>{t.source=s.source,i.we()})):Xt(s.link)&&n.setAttribute("href",s.link);const r=e.querySelector(".theo-related-grid-tile-image");r.style.backgroundImage='url("'+J(s.image)+'")',r.removeAttribute("id");const h=e.querySelector(".theo-related-grid-tile-title");s.title?(d(h,s.title),h.removeAttribute("id")):Yt(h);const o=e.querySelector(".theo-related-grid-tile-duration");return s.duration?(d(o,s.duration),o.removeAttribute("id")):Yt(o),e}var cc=[15,12,9,8,6,4,3,2,1];var lc=class{get pu(){return"theo-"+this.mu+"-item-grid"}gu(){this.yu.focus()}bu(t){this.ku(),function(t){if(t.length)for(const i of cc)if(t.length>=i){t.length=i;break}}(t),this.wu(t.length);for(const i of t){const t=uc(this._u.Ca,this.xu,i);this.Cu.appendChild(t)}}ku(){this.Cu.innerHTML=""}Su(){const t=h.createElement("div");t.className="theo-overlay-panel";const i=h.createElement("div");return i.className="theo-related-grid",this.ju.className="theo-related",this.yu.controlText("Close Related Content"),this.Tu.appendChild(this.ju),this.ju.appendChild(t),t.appendChild(this.yu.el()),t.appendChild(i),i}wu(t){ri(this.Cu,this.pu),this.mu=t,ei(this.Cu,this.pu)}kn(){Yt(this.ju),this.Mu.kn(),this.Au.kn(),this.yu.dispose(),this._u=void 0}constructor(t,i,s,e,n){this._u=void 0,this.Pu=void 0,this.xu=void 0,this.Tu=void 0,this.mu=void 0,this.yu=void 0,this.Cu=void 0,this.ju=void 0,this.Mu=void 0,this.Au=void 0,this.Nu=void 0,this._u=t,this.Pu=i,this.xu=s,this.Tu=e,this.mu=12,this.Nu=t=>{this.Cu.style.width=t.width+"px"},this.ju=h.createElement("div"),this.yu=new oc(this.Pu,{hide:()=>{this.xu.we()}}),this.Cu=this.Su(),this.Au=new dc(n),this.Au.wn(mi.yn,this.Nu),this.Mu=new Pt(this.Cu,this.Au),this.wu(12)}},dc=class extends Y{get Eu(){return this.Bu||0}get Iu(){return this.Fu.Iu}kn(){this.Vo(),this.Fu.mn(mi.yn,this.Du)}constructor(t){super(),this.Fu=void 0,this.Bu=void 0,this.Du=void 0,this.Fu=t,this.Du=t=>{let i=t.width;if(9*(t.width/16)>t.height){i=16*(t.height/9)}this.Bu=i,this.So(new yi(this.Eu,t.height))},this.Fu.wn(mi.yn,this.Du)}};f();var fc=class extends Z{constructor(){super("show")}};f();var vc=class extends Z{constructor(){super("hide")}},pc="theo-related-available",mc="theo-related-showing",gc=[...sc,"show","hide"],yc=class extends Y{get Ca(){return this.hu||(this.hu=function(t){let i;const s={get sources(){return t.ou},set sources(i){t.ou=i},get showing(){return t.du},show(){t.be()},hide(){t.we()},addEventListener(t,s){i.wn(t,s)},removeEventListener(t,s){i.mn(t,s)}};return i=new P(gc,!0,s),i.au(t),s}(this)),this.hu}get ou(){return this.$u.ou}set ou(t){this.$u.ou=t}get du(){return this.Uu}be(){const t=this.Uu;this.Uu=!0,this.Ru(mc),this.Ou.gu(),this.Pu.paused()?this.Vu=!0:this.Pu.pause(),t!==this.Uu&&this.So(new fc)}we(){const t=this.Uu;this.Uu=!1,this.Lu(mc),this.Hu.focus(),this.Vu||this.Pu.play(),this.Vu=!1,t!==this.Uu&&this.So(new vc)}Ru(t){this.Pu.el().classList.add(t)}Lu(t){this.Pu.el().classList.remove(t)}kn(){this.Vo(),this.Ou.kn()}constructor(t,i,s,e){super(),this.$u=void 0,this.Hu=void 0,this.hu=void 0,this.Pu=void 0,this.Ou=void 0,this.Uu=!1,this.Vu=!1,this.qu=t=>{const i=this.ou;this.Ou.bu(i),i.length?(this.Ru(pc),this.Hu.show()):(this.Lu(pc),this.Hu.hide()),this.So(t)},this.$u=i,this.$u.wn("relatedchange",this.qu),this.Pu=s,this.Ou=new lc(t,this.Pu,this,s.contentEl(),e),this.Hu=new rc(s,this,{})}};Ii(function(t){return class extends t{xa(){const t=this.zu;return at(super.xa(),{get related(){return t.Ca}})}kn(){this.zu.kn(),super.kn()}constructor(t,i,s){super(t,i,s),this.zu=void 0,this.zu=new yc(this,this.cu,this.vo,this.Wu)}}}),f(),f(),f();var bc=Fo.getComponent("Button"),kc=class extends bc{buildCSSClass(){return"vjs-icon-share theo-social-button "+super.buildCSSClass()}handleClick(){this.Gu.showing?this.Gu.hide():this.Gu.show()}se(){this.De.Fe=this.controlText()}dispose(){this.player().topControlBar.removeChild(this),super.dispose()}constructor(t,i,s){super(t,s),this.bo=void 0,this.Gu=void 0,this.De=void 0,this.bo=t.el(),this.Gu=i,this.player().topControlBar.addChild(this),this.hide(),this.controlText("Share Video"),this.De=new da(this,this.controlText()),this.on(t,"languagechange",this.se)}};function wc(t,i,s){switch(i){case"iconurl":return function(t,i){const s=h.createElement("a");var e;s.className="theo-social-iconurl",s.title=null!=(e=t.label)?e:"",s.target="Xu",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){const i=h.createElement("div");if(i.className="theo-social-text",t.label){const s=h.createElement("h5");s.className="theo-primary-background theo-social-label",d(s,t.label),i.appendChild(s)}const s=h.createElement("p");var e;return s.className="theo-social-content-container theo-tertiary-background",s.tabIndex=0,d(s,null!=(e=t.text)?e:""),i.appendChild(s),i}(t);case"texturl":return function(t,i){const s=h.createElement("div");if(s.className="theo-social-texturl",t.label){const i=h.createElement("h5");i.className="theo-primary-background theo-social-label",d(i,t.label),s.appendChild(i)}const e=h.createElement("div");e.className="theo-social-content-container theo-tertiary-background";const n=h.createElement("a");return n.target="Xu",n.href=i,d(n,i),e.appendChild(n),s.appendChild(e),s}(t,s)}}f();var _c="<URL>";var xc=class{get xe(){return this.ju}Ju(t){this.ku();for(const i of t)this.Qu(i)}gu(){this.yu.focus()}Qu(t){const i=function(t,i){return t.src?G(t.src,_c)?t.src.replace(_c,i):t.src:i}(t,this.xu.Yu),s=function(t){if(t)return t.icon?"iconurl":t.text?"text":"texturl"}(t),e=wc(t,s,i);e&&("iconurl"===s?this.Ku.appendChild(e):this.Zu.appendChild(e))}ku(){this.Ku.innerHTML="",this.Zu.innerHTML=""}kn(){Yt(this.ju),this.tc.kn()}constructor(t,i,s,e){this.oa=void 0,this.xu=void 0,this.Tu=void 0,this.sc=void 0,this.yu=void 0,this.Ou=void 0,this.ju=void 0,this.Ku=void 0,this.Zu=void 0,this.tc=void 0,this.oa=t,this.xu=i,this.Tu=s,this.sc=e;const n=h.createElement("div");n.className="theo-overlay-panel",this.yu=new oc(this.oa,this.xu.Ca),this.yu.controlText("Close Share"),this.Ou=h.createElement("div"),this.Ou.className="theo-social-container",this.ju=h.createElement("div"),this.ju.className="theo-social",this.Ku=h.createElement("div"),this.Ku.className="theo-social-icon-container",this.Zu=h.createElement("div"),this.Zu.className="theo-social-text-container",this.Tu.appendChild(this.ju),this.ju.appendChild(n),this.Ou.appendChild(this.Ku),this.Ou.appendChild(this.Zu),n.appendChild(this.yu.el()),n.appendChild(this.Ou),this.tc=new Pt(this.ju,this.sc)}},Cc="theo-social-available",Sc="theo-social-showing",jc=class{get Ca(){return this.hu}get du(){return this.Uu}get ec(){return this.nc}set ec(t){this.nc=t,this.Ou.Ju(t),t.length?(this.Ru(Cc),this.Hu.show()):(this.Lu(Cc),this.Hu.hide())}get Yu(){return this.rc||H()}set Yu(t){this.rc=t}be(){this.Uu=!0,this.Ru(Sc),this.Ou.gu(),this.hc.paused()?this.Vu=!0:this.hc.pause()}we(){this.Uu=!1,this.Lu(Sc),this.Hu.focus(),this.Vu||this.hc.play(),this.Vu=!1}Ru(t){this.hc.el().classList.add(t)}Lu(t){this.hc.el().classList.remove(t)}kn(){this.Hu.dispose(),this.Ou.kn()}constructor(t,i){this.Hu=void 0,this.hu=void 0,this.hc=void 0,this.Ou=void 0,this.Uu=!1,this.nc=[],this.rc=void 0,this.Vu=!1,this.hu=function(t){return{get showing(){return t.du},get items(){return t.ec},set items(i){t.ec=i},get url(){return t.Yu},set url(i){t.Yu=i},show(){t.be()},hide(){t.we()}}}(this),this.hc=t,this.Ou=new xc(this.hc,this,t.contentEl(),i),this.Hu=new kc(t,this.hu,{})}};Ii(function(t){return class extends t{xa(){const t=this.Gu;return at(super.xa(),{get social(){return t.Ca}})}constructor(t,i,s){super(t,i,s),this.Gu=void 0,this.Gu=new jc(this.vo,this.Wu)}}}),f(),f();var Tc=Fo.getComponent("Component"),Mc=class extends Tc{createEl(){const t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-upnext-container "+super.buildCSSClass()}};Mc.prototype.h=z({},Mc.prototype.h,{children:[]}),Fo.registerComponent("upNextContainer",Mc),f(),f();var Ac="theo-upnext-bar-",Pc=Fo.getComponent("Component"),Nc=class extends Pc{get du(){return this.Uu}set du(t){this.Uu=t,this.oc&&(this.oc.tabIndex=t?0:-1)}get ac(){return this.uc}set ac(t){this.uc=t}Ta(t){this.ku(),this.cc(t)}cc(t){if(t&&t.link&&t.image){const i=h.createElement("div");ei(i,Ac+"content"),i.onclick=()=>{this.lc.next()},i.onkeypress=t=>{13===t.which&&this.lc.next()};const s=h.createElement("div");if(s.style.backgroundImage='url("'+J(t.image)+'")',ei(s,Ac+"image"),i.appendChild(s),t.duration){const i=h.createElement("span");ei(i,Ac+"duration"),i.innerHTML=""+t.duration,s.appendChild(i)}const e=h.createElement("div");ei(e,Ac+"text");const n=h.createElement("div");if(ei(n,Ac+"upnext"),d(n,this.localize("Up Next")),e.appendChild(n),t.title){const i=h.createElement("div");ei(i,Ac+"title"),d(i,t.title),e.appendChild(i)}i.appendChild(e),this.oc=i,this.dc=n,this.el().appendChild(this.oc)}}ku(){this.el().innerHTML="",this.oc=void 0,this.dc=void 0}se(){this.dc&&d(this.dc,this.localize("Up Next"))}createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-upnext-bar "+super.buildCSSClass()}dispose(){this.tc.kn(),super.dispose()}constructor(t,i,s,e){super(t,s),this.lc=void 0,this.tc=void 0,this.Uu=void 0,this.uc=void 0,this.oc=void 0,this.dc=void 0,this.lc=i,this.tc=new Pt(this.el(),e),this.Uu=!1,this.uc=10,this.on(t,"languagechange",this.se)}};f();var Ec="theo-upnext-panel-",Bc=bu,Ic=Fo.getComponent("Component"),Fc=class extends Ic{get du(){return this.Uu}set du(t){this.Uu=t}get fc(){return this.vc}set fc(t){this.vc=t}get mc(){return this.gc}set mc(t){this.gc=t}Ta(t){this.ku(),this.yc(t)}yc(t){if(t&&t.link&&t.image){const i=h.createElement("div");i.className=Ec+"content";const s=h.createElement("div");s.style.backgroundImage='url("'+J(t.image)+'")',s.className=Ec+"image",i.appendChild(s);const e=h.createElement("div");e.className=Ec+"text";const n=h.createElement("div");if(n.className=Ec+"upnext",d(n,this.localize("Up Next")),e.appendChild(n),t.title){const i=h.createElement("div");i.className=Ec+"title",d(i,t.title),e.appendChild(i)}i.appendChild(e),this.bc=h.createElement("div"),this.bc.className=Ec+"autoplay",this.bc.innerHTML=ku;const r=this.bc.querySelector("svg");r.onclick=()=>{this.lc.next()},r.tabIndex=0,r.onkeypress=t=>{13===t.which&&this.lc.next()},this.kc=n,this.wc=this.bc.querySelector("."+Bc),i.appendChild(this.bc),this.el().appendChild(i)}}get _c(){return this.xc}set _c(t){this.xc=t,this.wc.style.strokeDashoffset=""+_.round(1e5*t)/1e5}ku(){this.el().innerHTML="",this.kc=void 0,this.wc=void 0}se(){this.kc&&d(this.kc,this.localize("Up Next"))}createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-upnext-panel "+super.buildCSSClass()}dispose(){this.tc.kn(),super.dispose()}constructor(t,i,s,e){super(t,s),this.lc=void 0,this.tc=void 0,this.kc=void 0,this.bc=void 0,this.wc=void 0,this.xc=0,this.Uu=void 0,this.vc=void 0,this.gc=void 0,this.lc=i,this.tc=new Pt(this.el(),e),this.Uu=!1,this.vc=10,this.gc=!0,this.on(t,"languagechange",this.se)}},Dc="theo-upnext-panel-showing",$c="theo-upnext-bar-showing",Uc=2*_.PI*73,Rc=class t{get Ca(){return this.hu}get Cc(){return this.Sc}get jc(){return this.Tc}get Mc(){return this.Ac}set Mc(t){this.Ac=t,this.Ou.Ta(t),this.Pc.Ta(t),this.hc.off("timeupdate",this.Nc),this.hc.off("ended",this.Ec),t&&(this.hc.on("timeupdate",this.Nc),this.hc.on("ended",this.Ec))}Bc(){this.Ou.fc?this.Ic=mt(this.Ou.fc):0===this.Ou.fc?this.Ic=0:this.Ic=10,0!==this.Ic?(isFinite(this.Ic)&&(this.Fc=!0),this.Ou.du=!0,this.Ru(Dc),this.Fc&&(this.Ou._c=Uc-Uc/this.Ic,this.Dc=v(this.$c,1e3))):this.Uc()}Rc(){this.Ou.du=!1,this.Lu(Dc),this.Fc&&(p(this.Dc),this.Oc=1,this.Ou._c=Uc)}Vc(){this.Pc.du=!0,this.Ru($c)}Lc(){this.Pc.du=!1,this.Lu($c)}Uc(){p(this.Dc),this.Mc&&(s.location.href=this.Mc.link)}Ru(t){this.hc.el().classList.add(t)}Lu(t){this.hc.el().classList.remove(t)}Hc(t,i){const s=t>=i&&!(this.qc&&this.qc.zc);this.Pc.du&&!s?this.Lc():!this.Pc.du&&s&&this.Vc()}Wc(t,i){this.Ou.du&&t<i&&!this.hc.ended()&&this.Rc()}static Gc(t,i){const s=mt(t);if(!S(s))return i-s;const e=(""+t).match(/^([1-9]?\d|100)%$/);if(e){return i*(1-x(e[1],10)/100)}}kn(){this.Dc&&p(this.Dc),this.hc.getChild("upNextContainer").removeChild(this.Ou),this.hc.getChild("upNextContainer").removeChild(this.Pc),this.Ou.dispose(),this.Pc.dispose()}constructor(i,s,e){this.Pc=void 0,this.Ou=void 0,this.hu=void 0,this.Sc=void 0,this.Tc=void 0,this.hc=void 0,this.Ac=void 0,this.Ic=10,this.Oc=1,this.Dc=void 0,this.Fc=!0,this.qc=void 0,this.$c=()=>{this.Oc!==this.Ic?(this.Ou._c-=Uc/this.Ic,this.Oc+=1):this.Uc()},this.Ec=()=>{this.Ou.du||this.Bc()},this.Nc=()=>{const i=this.hc.currentTime(),s=this.hc.duration(),e=s?t.Gc(this.Pc.ac,s):void 0;void 0!==e&&this.Hc(i,e),this.Ou.mc&&this.Wc(i,s)},this.hu=function(t){return{get source(){return t.Mc},set source(i){t.Mc=i},get bar(){return t.Cc},get panel(){return t.jc},next(){t.Uc()}}}(this),this.Pc=new Nc(i,this.hu,{},s),this.Ou=new Fc(i,this.hu,{},s),this.Sc=function(t,i){return{get showing(){return i.du},get offset(){return i.ac},set offset(t){i.ac=t},show(){t.Vc()},hide(){t.Lc()}}}(this,this.Pc),this.Tc=function(t,i){return{get showing(){return i.du},get countdownDuration(){return i.fc},set countdownDuration(t){i.fc=t},get showUpNextPanel(){return i.mc},set showUpNextPanel(t){i.mc=t},show(){t.Bc()},hide(){t.Rc()}}}(this,this.Ou),this.hc=i,this.qc=e,i.getChild("upNextContainer").addChild(this.Pc,{}),i.getChild("upNextContainer").addChild(this.Ou,{})}};Ii(function(t){return class extends t{xa(){const t=this.Xc;return at(super.xa(),{get upnext(){return t.Ca}})}kn(){this.Xc.kn(),super.kn()}constructor(t,i,s){super(t,i,s),this.Xc=void 0,this.Xc=new Rc(this.vo,this.Wu,this.Jc)}}}),f(),f();var Oc=Fo.getComponent("Component"),Vc=class extends Oc{createEl(){const 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);const n=h.createElement("div");return n.className="theo-context-version",d(n,"Powered by THEOplayer 11.4.0"),s.appendChild(n),s.href="https://www.theoplayer.com/player-referral",s.target="Xu",t.appendChild(i),t}Qc(t){const i=t;i.preventDefault(),this.show(),this.el().style.left="0",this.el().style.top="0";const s=this.player().contentEl(),e=s.getClientRects(),n=e.length>0?e[0]:void 0,r=i.clientX-s.getBoundingClientRect().left,h=C(getComputedStyle(this.el()).fontSize);K(this.el(),r,n,h);const o=i.clientY-s.getBoundingClientRect().top;tt(this.el(),o,n,h),this.Yc()}Kc(){this.hide(),this.clearTimeout(this.Zc)}Yc(){this.Zc=this.setTimeout(this.Kc,4e3)}tl(){this.clearTimeout(this.Zc)}dispose(){this.Kc(),this.off(this.player(),"contextmenu",this.Qc),this.el().removeEventListener("mousedown",Lc,!0),this.off(h,"mousedown",this.Kc),this.off("mouseout",this.Yc),this.off("mouseover",this.tl),super.dispose()}constructor(t,i){super(t,i),this.Zc=0,this.on(this.player(),"contextmenu",this.Qc),this.el().addEventListener("mousedown",Lc,!0),this.on(h,"mousedown",this.Kc),this.on("mouseout",this.Yc),this.on("mouseover",this.tl),this.Kc()}};function Lc(t){t.stopPropagation()}Di(function(t){const i=new Vc(t.vo,{});t.vo.addChild(i),t.vo.on("dispose",()=>{t.vo.removeChild(i),i.dispose()})}),f(),f(),f(),f();var Hc={Default:"","Monospaced Serif":D.il,"Proportional Serif":D.sl,"Monospaced Sans-Serif":D.nl,"Proportional Sans-Serif":D.rl},qc={White:"#ffffff",Yellow:"#ffff00",Green:"#00ff00",Cyan:"#00ffff",Blue:"#0000ff",Magenta:"#ff00ff",Red:"#ff0000",Black:"#000000"},zc=[50,75,100,150,200];function Wc(t){return{label:t+"%",value:t}}function Gc(t){return w.keys(t).map(i=>({label:i,value:t[i]}))}zc.map(function(t){return{label:t+"%",value:t/100+"em"}});var Xc=zc.map(function(t){return{label:t+"%",value:t+"%"}}),Jc=[25,50,75,100].map(Wc),Qc=[0,25,50,75,100].map(Wc),Yc=Gc(qc),Kc=Gc(Hc),Zc=Gc({None:"none","Drop Shadow":"dropshadow",Raised:"raised",Depressed:"depressed",Uniform:"uniform"}),tl=100,il="#000000",sl="#FFFFFF",el="#000000";f();var nl=class extends Ka{hl(){const t=this.Vr.localize(this.ol);d(this.al.subMenu.menuHeader.el(),t),this.Or=h.createElement("span"),this.Or.className="theo-settings-control-menu-item-title",d(this.Or,t);const i=h.createElement("span");return i.className="theo-primary-color theo-settings-control-menu-item-value",ei(this.al.el(),"theo-subtitle-options-menu-item"),this.al.el().appendChild(this.Or),this.al.el().appendChild(i),i}cl(t){const i=this.Er(t);i&&this.ll(i)}dl(){return this.jr}Fr(t){this.fl(t.Br)}ll(t){for(const t of this.Pr.menuItems)t.selected(!1);t?(t.selected(!0),this.vl(t.Br.label)):this.vl("Custom")}vl(t){this.pl=t,d(this.ml,this.Vr.localize(t)),this.al.parentMenu.oe()}Ir(t){const i=super.Ir(t);return ei(i.el(),"theo-subtitle-options-menu-item"),this.Ur(i),i}Ur(t){const i=this.Vr.localize(t.Br.label);d(t.el(),i);const s=this.Vr.localize("Set "+this.ol+" to ")+i;t.el().setAttribute("aria-label",s)}Oe(){this.Vr.off("languagechange",this.se),super.Oe()}constructor(t,i,s,e){super(t.subMenu),this.al=void 0,this.Vr=void 0,this.ol=void 0,this.Or=void 0,this.ml=void 0,this.pl=void 0,this.fl=void 0,this.se=void 0,this.al=t,this.Vr=e,this.pl="",this.se=()=>{const t=this.Vr.localize(this.ol);d(this.al.subMenu.menuHeader.el(),t),d(this.Or,t),this.vl(this.pl);for(const t of this.Nr)this.Ur(t)},this.ol=i,this.fl=s.gl,this.ml=this.hl(),this.jr=s.yl,this.Vr.on("languagechange",this.se)}};f();var rl=class t{static bl(t,i,s,e){if(void 0===t&&void 0===i)return;return W(void 0===t?s:t,void 0===i?e:i)}constructor(i){this.kl=void 0,this.wl=void 0,this._l=void 0,this.xl=void 0,this.Cl=void 0,this.Sl=void 0,this.jl=void 0,this.Tl=void 0,this.Ml=void 0,this.Al=void 0,this.Pl=void 0,this.Nl=void 0,this.El=void 0,this.Bl=void 0,this.Il=void 0,this.Fl=void 0,this.kl=i,this.Tl=t=>{this.kl.fontFamily=t.value},this.Ml=t=>{this.kl.fontSize=t.value},this.Al=i=>{this.wl=i.value,this.kl.fontColor=t.bl(this._l,this.wl,sl,tl)},this.Pl=i=>{this._l=i.value,this.kl.fontColor=t.bl(this._l,this.wl,sl,tl)},this.Nl=i=>{this.Cl=i.value,this.kl.backgroundColor=t.bl(this.Cl,this.xl,il,tl)},this.El=i=>{this.xl=i.value,this.kl.backgroundColor=t.bl(this.Cl,this.xl,il,tl)},this.Bl=i=>{this.jl=i.value,this.kl.windowColor=t.bl(this.jl,this.Sl,el,tl)},this.Il=i=>{this.Sl=i.value,this.kl.windowColor=t.bl(this.jl,this.Sl,el,tl)},this.Fl=t=>{this.kl.edgeStyle=t.value}}};f();var hl=class{Dl(t,i){const s=this.$l(t,i.dl());s&&i.cl(s)}$l(t,i){return Ni(i,i=>i.value===t)}Ul(t,i,s){let e,n;if(void 0===t)e=this.$l(void 0,i.dl()),n=this.$l(void 0,s.dl());else if(t){const r=function(t){let i=q(t);i||(i=q(t.slice(0,t.length-1).replace("rgb","rgba")+",1)"));i||(i=U(O(t),1));if(!i){const s=t.charAt(0).toUpperCase()+t.toLowerCase().slice(1);i=U(O(qc[s]),1)}return i}(t);if(r){const t=L(r),h=100*r.Rl;e=this.$l(t,i.dl()),n=this.$l(h,s.dl())}}e&&i.cl(e),n&&s.cl(n)}constructor(t,i){this.kl=void 0,this.Ol=void 0,this.Vl=void 0,this.kl=t,this.Ol=i,this.Vl=()=>{const t=this.kl.fontFamily;this.Dl(t,this.Ol["Font family"]);const i=this.kl.fontColor;this.Ul(i,this.Ol["Font color"],this.Ol["Font opacity"]);const s=this.kl.fontSize;this.Dl(s,this.Ol["Font size"]);const e=this.kl.backgroundColor;this.Ul(e,this.Ol["Background color"],this.Ol["Background opacity"]);const n=this.kl.windowColor;this.Ul(n,this.Ol["Window color"],this.Ol["Window opacity"]);const r=this.kl.edgeStyle;this.Dl(r,this.Ol["Character edge style"])},this.kl.addEventListener("change",this.Vl),this.Vl()}};var ol=class extends Ka{Ll(){return{"Font family":{yl:al(Kc),gl:this.Hl.Tl},"Font color":{yl:al(Yc),gl:this.Hl.Pl},"Font opacity":{yl:al(Jc),gl:this.Hl.Al},"Font size":{yl:al(Xc),gl:this.Hl.Ml},"Background color":{yl:al(Yc),gl:this.Hl.Nl},"Background opacity":{yl:al(Qc),gl:this.Hl.El},"Window color":{yl:al(Yc),gl:this.Hl.Bl},"Window opacity":{yl:al(Qc),gl:this.Hl.Il},"Character edge style":{yl:al(Zc),gl:this.Hl.Fl}}}ql(){this.Or=h.createElement("span"),this.Or.className="theo-settings-control-menu-item-title",this.zl=h.createElement("span"),this.zl.className="theo-primary-color theo-settings-control-menu-item-value",this.Jr.el().appendChild(this.Or),this.Jr.el().appendChild(this.zl),this.se()}Ir(t){const i=this.Pr.addSubMenuItem();return i.Br=t,this.Ol[t]=new nl(i,t,this.Wl[t],this.Vr),i}Ur(t){}Fr(t){}Oe(){this.Vr.off("languagechange",this.se),this.Gl.removeEventListener(["addtrack","removetrack"],this.Xl),super.Oe()}constructor(t,i,s,e){super(t.subMenu),this.Jr=void 0,this.Gl=void 0,this.Vr=void 0,this.Hl=void 0,this.Jl=void 0,this.Wl=void 0,this.Ol=void 0,this.Or=void 0,this.zl=void 0,this.Xl=void 0,this.se=void 0,this.Jr=t,this.Gl=i,this.Vr=e,this.Ol={},this.Xl=()=>{this.Gl.some(t=>At(t.kind))?this.Jr.show():this.Jr.hide()},this.se=()=>{d(this.Pr.menuHeader.el(),this.Vr.localize("Subtitle Options")),d(this.Or,this.Vr.localize("Subtitle")),d(this.zl,this.Vr.localize("Options")),this.Jr.el().setAttribute("aria-label",this.Vr.localize("Open the subtitle options menu"))},this.Hl=new rl(s),this.Wl=this.Ll(),this.jr=w.keys(this.Wl),this.ql(),this.Jl=new hl(s,this.Ol),this.Vr.on("languagechange",this.se),this.Gl.addEventListener(["addtrack","removetrack"],this.Xl),this.Xl()}};function al(t){const i=[{label:"Default",value:void 0}];for(const s of t)"Default"!==s.label&&i.push(s);return i}Di(function(t){const i=t.vo.controlBar.getChild("SettingsButton").menu,s=i.addSubMenuItem({name:"TextTrackOptionsMenuItem"}),e=new ol(s,t.nt.Ca,t.Ql.Ca,t.vo);t.vo.on("dispose",()=>{i.removeMenuItem(s),s.dispose(),e.Oe(),i.dispose()})}),f(),f();var ul=Fo.getComponent("Component"),cl=class extends ul{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}};cl.prototype.h=z({},ul.prototype.h,{children:[]}),Fo.registerComponent("AdControlPanel",cl),f(),f();var ll=Fo.getComponent("Component"),dl="theo-dai-countdown",fl=class extends ll{buildCSSClass(){return dl}createEl(t,i,s){const e=h.createElement("div");return e.className=dl,e}Yl(t,i){i.addEventListener("adbreakbegin",()=>this.show()),i.addEventListener("adbreakend",()=>this.hide()),t.addEventListener("timeupdate",this.se)}constructor(t,i,s){super(t,s),this.oa=void 0,this.hu=void 0,this.se=void 0,this.oa=t,this.hu=i,this.se=()=>{const t=this.hu.ads;t.playing&&t.currentAdBreak&&t.currentAds.length&&d(this.contentEl(),function(t,i,s){const e=t.ads;let n="";const r=e.length;if(r>1){const t=e.indexOf(i)+1;n=s("Ad")+" "+t+"/"+r+". "}const h=_.ceil(t.maxRemainingDuration);return n+=s("The content will resume in {1} seconds.").replace("{1}",""+h),n}(t.currentAdBreak,t.currentAds[0],t=>this.oa.localize(t)))},this.Yl(i,i.ads),this.on(t,"languagechange",this.se)}};f();var vl=Fo.getComponent("ClickableComponent"),pl=class extends vl{buildCSSClass(){return Ut}createEl(t,i,s){return this.h.Ca.element.querySelector("."+Ut)}emitTapEvents(){}se(){d(this.el(),this.localize("Learn more"))}constructor(t,i){super(t,i),d(this.el(),t.localize("Learn more")),this.on(t,"languagechange",this.se)}};Di(function(t){const i=t.Ca.ads;if(i&&i.dai){const i=t.vo,s=new fl(i,t.Ca);i.adControlBar.addChild(s);if(t.Ca.element.querySelector("."+Ut)){const s=new pl(i,{Ca:t.Ca});i.adControlBar.addChild(s)}}}),f(),f();var ml=Fo.getComponent("Component"),gl=["addtrack","removetrack","change"],yl=class extends(Ho(ml)){createEl(){const t=super.createEl();return this.qualityLabel=Fo.createEl("div",{className:"theo-quality-label-text"}),t.appendChild(this.qualityLabel),li(this.qualityLabel),t}dispose(){this.Yr&&(this.Yr.removeEventListener("activequalitychanged",this.Kl),this.Yr=void 0),this.xs.videoTracks.removeEventListener(gl,this.dh),super.dispose()}constructor(t,i){super(t,i),this.qualityLabel=void 0,this.Yr=void 0,this.startFadeOutID=void 0,this.removeLabelClassesID=void 0,this.dh=()=>{const t=Xa(this.xs.videoTracks);t!==this.Yr&&(this.Yr&&this.Yr.removeEventListener("activequalitychanged",this.Kl),this.Yr=t,t&&t.addEventListener("activequalitychanged",this.Kl),this.Kl())},this.Kl=()=>{const t=this.Yr&&this.Yr.activeQuality;if(!this.qualityLabel||!t)return;const i=t.label?t.label:t.height?t.height+"p":void 0;i&&(d(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.xs.videoTracks&&(this.xs.videoTracks.addEventListener(gl,this.dh),this.dh())}};Fo.registerComponent("activeQualityLabel",yl),f(),f();var bl="theo-upcoming-ad-notification",kl=["adbreakbegin","adbreakend","adadded","adloaded","adbegin","adend"],wl=class extends(Ho(pa)){createEl(){const t=Fo.createEl("div",{className:bl});return this.notificationText=Fo.createEl("div",{className:bl+"text"}),t.appendChild(this.notificationText),t}Zl(){if(!this.xs.ads)return;const t=this.xs.ads.scheduledAdBreaks;let i,s=1/0;for(let e=0;e<t.length;e++){const n=t[e],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)}td(){if(!this.xs.ads||this.xs.ads.playing||!this.currentAdBreak||!this.currentAdBreakValid||0===this.currentAdBreak.timeOffset)return void this.sd();const t=this.xs.currentTime;if(this.currentAdBreak.timeOffset>t+10)return void this.sd();const i=_.ceil(this.currentAdBreak.timeOffset-t);i<0?this.sd():this.ed(i)}ed(t){this.nd!==t&&(d(this.notificationText,"Your video will be temporarily interrupted in 0:"+(t<10?"0"+t:t)),this.nd=t,this.show())}sd(){this.nd=NaN,this.hide()}dispose(){var t;this.xs.removeEventListener("timeupdate",this.handleTimeUpdate),null==(t=this.xs.ads)||t.removeEventListener(kl,this.handleAdEvent),this.currentAdBreak=void 0,super.dispose()}constructor(t,i){super(t,i),this.currentAdBreak=void 0,this.currentAdBreakValid=!1,this.nd=NaN,this.handleTimeUpdate=()=>{this.td()},this.handleAdEvent=()=>{this.Zl(),this.td()},this.xs.ads&&(this.hide(),this.xs.addEventListener("timeupdate",this.handleTimeUpdate),this.xs.ads.addEventListener(kl,this.handleAdEvent))}};Fo.registerComponent("upcomingAdNotificationText",wl),f(),f();var _l=Fo.getComponent("Component");Fo.registerComponent("UplynkAdBreakBar",class extends _l{createEl(){const t=h.createElement("div");return t.className="theoplayer-ad-overlay-component theo-ad-remaining-container",t}get rd(){return this.h.adBreakProvider()}se(t,i){if(this.rd&&this.rd.endTime){const s=_.max(this.rd.endTime-t,0);d(i,"Content will resume in "+_.ceil(s)+"s"),this.show()}else this.hide()}constructor(t,i){super(t,i),this.od=()=>{this.se(this.player().currentTime(),this.el())},this.on(t,"timeupdate",this.od)}}),f();var xl=Fo.getComponent("ClickableComponent");Fo.registerComponent("UplynkAdSkipButton",class extends xl{createEl(){const t=h.createElement("div");return t.className="theoplayer-ad-overlay-component theoplayer-ad-skip theoplayer-ad-skip-countdown",this.ad=h.createElement("span"),t.appendChild(this.ad),this.se(t,this.ad),t}handleClick(){this.h.skipCallback()}se(t,i){this.ud<=_t.dd.ld?(ri(t,"theoplayer-ad-skip-countdown"),ei(t,"theoplayer-ad-skip-button"),d(i,"Skip ads")):d(i,"Skip ads in "+_.ceil(this.ud)+"s")}get ud(){return this.h.adBreak.startTime+this.h.adBreak.skipOffset-this.player().currentTime()}constructor(t,i){super(t,i),this.od=()=>{this.se(this.el(),this.ad)},this.on(t,"timeupdate",this.od)}}),f(),f();var Cl=Fo.getComponent("Component"),Sl=class extends Cl{buildCSSClass(){return"theo-uplynk-marker-bar"}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}updateMarkers(t){const i=this.children().slice();let s=0,e=0;for(;s<i.length&&e<t.length;s++,e++){const n=i[s],r=t[e];n.marker===r?n.updateMarker():(this.removeChild(n),this.addChild(this.fd,{marker:r}))}for(;s<i.length;s++)this.removeChild(i[s]);for(;e<t.length;e++){const i=t[e];this.addChild(this.fd,{marker:i})}}constructor(t,i){super(t,i)}};f();var jl=function(t){return t.vd="UplynkAdBreakBar",t.pd="UplynkAdSkipButton",t.md="UplynkAdBreakMarkerBar",t.gd="UplynkAdBreakMarker",t.yd="UplynkAssetMarkerBar",t.bd="UplynkAssetMarker",t.kd="UplynkContentNotificationBar",t.wd="UplynkContentNotification",t}({});function Tl(t,i){const s=t.uplynk;return Boolean(t&&void 0===s)||Boolean(t&&s&&void 0===s.ui)||Boolean(t&&s&&s.ui&&void 0===s.ui[i])||Boolean(t&&s&&s.ui&&!0===s.ui[i])}Ii(function(t){return class extends t{get _d(){return this.vo.controlBar.progressControl.seekBar}Ta(t){this.xd=!1,this.Ca.removeEventListener("timeupdate",this.Cd),this.Ca.removeEventListener("loadeddata",this.Sd),this.vo.removeChild("UplynkAdBreakBar"),this.vo.removeChild("UplynkAdSkipButton"),this._d.removeChild("UplynkAdBreakMarkerBar"),this._d.removeChild("UplynkAssetMarkerBar"),this.vo.removeChild("UplynkContentNotificationBar"),this.Ca.uplynk&&t&&Gt(t)&&this.Ca.addEventListener("loadeddata",this.Sd),super.Ta(t)}jd(){if(!function(t){return Tl(t,"assetMarkers")}(this.Td)||!this.xd)return;let t=this._d.getChild("UplynkAssetMarkerBar");t||(t=this._d.addChild("UplynkAssetMarkerBar")),t.updateMarkers(this.Ca.uplynk.assets)}Md(){if(!function(t){return Tl(t,"contentNotification")}(this.Td))return;let t=this.vo.getChild("UplynkContentNotificationBar");t||(t=this.vo.addChild("UplynkContentNotificationBar")),t.updateAssets(this.Ca.uplynk.assets)}kn(){this.Ca.removeEventListener("timeupdate",this.Cd),this.Ca.removeEventListener("loadeddata",this.Sd);const t=this.Ca.uplynk;null==t||t.ads.adBreaks.removeEventListener("addadbreak",this.Pd),null==t||t.ads.adBreaks.removeEventListener("removeadbreak",this.Nd),null==t||t.assets.removeEventListener("addasset",this.Ed),null==t||t.assets.removeEventListener("removeasset",this.Ed),super.kn()}constructor(t,i,s){super(t,i,s),this.xd=!1,this.Sd=()=>{this.xd=!0,isFinite(this.Bd())||this.Ca.addEventListener("timeupdate",this.Cd),this.Cd(),this.jd(),this.Md()},this.Pd=t=>{t.adBreak.addEventListener("adbreakbegin",this.Id),t.adBreak.addEventListener("adbreakend",this.Fd),this.Cd()},this.Nd=t=>{t.adBreak.removeEventListener("adbreakbegin",this.Id),t.adBreak.removeEventListener("adbreakend",this.Fd),this.Cd()},this.Cd=()=>{if(!function(t){return Tl(t,"adBreakMarkers")}(this.Td)||!this.xd)return;let t=this._d.getChild("UplynkAdBreakMarkerBar");t||(t=this._d.addChild("UplynkAdBreakMarkerBar")),t.updateMarkers(this.Ca.uplynk.ads.adBreaks)},this.Id=()=>{if(function(t){return Tl(t,"adNotification")}(this.Td)){const t=this.Ca.uplynk,i=t.ads.currentAdBreak;this.vo.addChild("UplynkAdBreakBar",{adBreakProvider:this.Dd}),-1!==i.skipOffset&&this.vo.addChild("UplynkAdSkipButton",{adBreak:i,skipCallback:t.ads.skip})}},this.Dd=()=>this.Ca.uplynk.ads.currentAdBreak,this.Fd=()=>{this.vo.removeChild("UplynkAdBreakBar"),this.vo.removeChild("UplynkAdSkipButton")},this.Ed=()=>{this.jd(),this.Md()};const e=this.Ca.uplynk;null==e||e.ads.adBreaks.addEventListener("addadbreak",this.Pd),null==e||e.ads.adBreaks.addEventListener("removeadbreak",this.Nd),null==e||e.assets.addEventListener("addasset",this.Ed),null==e||e.assets.addEventListener("removeasset",this.Ed)}}});Fo.registerComponent("UplynkAdBreakMarkerBar",class extends Sl{buildCSSClass(){return super.buildCSSClass()+" theo-uplynk-marker-bar-adbreak"}get fd(){return jl.gd}}),f(),f();var Ml=Fo.getComponent("Component"),Al=class extends Ml{get marker(){return this.h.marker}get seekable(){return this.player().seekable()}buildCSSClass(){return"theo-uplynk-marker"}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),this.updateMarker(e),e}updateMarker(t){void 0===t&&(t=this.el());const i=this.seekable.start(0),s=this.seekable.end(this.seekable.length-1),e=_.max(this.marker.startTime-i,0),n=void 0!==this.marker.endTime?_.max(s-this.marker.endTime,0):0,r=s-i;t.style.left=e/r*100+"%",t.style.right=n/r*100+"%"}constructor(t,i){super(t,i)}};Fo.registerComponent("UplynkAdBreakMarker",class extends Al{buildCSSClass(){return super.buildCSSClass()+" theo-uplynk-marker-adbreak"}}),f();Fo.registerComponent("UplynkAssetMarkerBar",class extends Sl{buildCSSClass(){return super.buildCSSClass()+" theo-uplynk-marker-bar-asset"}get fd(){return jl.bd}}),f();Fo.registerComponent("UplynkAssetMarker",class extends Al{buildCSSClass(){return super.buildCSSClass()+" theo-uplynk-marker-asset"}}),f();var Pl=Fo.getComponent("Component");Fo.registerComponent("UplynkContentNotificationBar",class extends Pl{buildCSSClass(){const t="theo-uplynk-content-notification-bar";return t+(Dt.ru||Dt.$d?" "+t+"-ios":"")}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}updateAssets(t){const i=this.children().slice();let s=0,e=0;for(;s<i.length&&e<t.length;s++,e++){const n=i[s],r=t[e];n.Ud===r?n.updateCountdown():(this.removeChild(n),this.addChild(jl.wd,{asset:r}))}for(;s<i.length;s++)this.removeChild(i[s]);for(;e<t.length;e++){const i=t[e];this.addChild(jl.wd,{asset:i})}}constructor(t,i){super(t,i)}}),f();var Nl=Fo.getComponent("Component");Fo.registerComponent("UplynkContentNotification",class extends Nl{get Ud(){return this.h.asset}buildCSSClass(){return"theo-uplynk-content-notification"}createEl(t,i,s){const e=h.createElement("div");return e.className=this.buildCSSClass(),e}wo(){const t=h.createElement("img");t.src=this.Ud.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.Ud.description);d(i,s),this.el().appendChild(i),this.Rd=h.createElement("div"),this.Rd.className=this.buildCSSClass()+"-countdown",d(this.Rd,this.Od),this.el().appendChild(this.Rd)}get Od(){const t=_.min(10,this.Vd);return"Starting in "+_.ceil(t)+" seconds"}get Vd(){return _.max(0,this.Ud.startTime-this.player().currentTime())}updateCountdown(){const t=this.Vd;t>10||t<=0?this.hide():(d(this.Rd,this.Od),this.show())}constructor(t,i){super(t,i),this.Rd=void 0,this.wo(),this.on(t,"timeupdate",this.updateCountdown),this.hide()}});export{lt as ChromelessPlayer,nt as ErrorCategory,st as ErrorCode,Ou as Player,qt as cache,Bt as cast,pt as features,bt as players,wt as registerContentProtectionIntegration,ft as utils,gt as version,Fo as videojs};
41
41
  //# sourceMappingURL=THEOplayer.esm.js.map