@theoplayer/extended 6.1.0 → 6.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/THEOplayer.esm.js CHANGED
@@ -34,7 +34,7 @@
34
34
  THEOplayer is based on patented technology developed by
35
35
  THEO Technologies (https://www.theoplayer.com).
36
36
 
37
- Version: 6.1.0
38
- Created: 2023-10-02T15:57:56.782Z
37
+ Version: 6.2.0
38
+ Created: 2023-10-16T12:08:00.537Z
39
39
  */
40
- var h,r,a="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:void 0!==s?s:"undefined"!=typeof global?global:this,s=a.window,u=a.document,c=(a.location,a.navigator,a.setTimeout),v=a.clearTimeout,m=(a.setInterval,a.clearInterval,a.Error),g=a.TypeError,b=a.SyntaxError,w=a.Object,k=a.Math,j=a.parseInt,S=a.parseFloat,_=a.isNaN,x=a.Uint8Array;a.Worker,a.WorkerGlobalScope,a.XMLHttpRequest;import{$ as T,A as C,Aa as P,B as A,Ba as M,C as I,Ca as E,D,Da as F,E as N,Ea as $,F as B,G as O,H as R,I as U,J as V,K as L,L as H,M as z,N as W,O as q,P as G,Q as X,R as Q,S as J,T as Y,U as K,V as Z,W as tt,X as it,Y as st,Z as et,_ as nt,a as rt,aa as ht,b as ot,ba as at,c as ut,ca as ct,d as lt,da as ft,e as dt,ea as vt,f as pt,fa as mt,g as gt,ga as yt,h as bt,ha as wt,i as kt,ia as jt,j as St,ja as _t,k as xt,ka as Tt,l as Ct,la as Pt,m as At,ma as Mt,n as It,na as Et,o as Dt,oa as Ft,p as Nt,pa as $t,q as Bt,qa as Ot,r as Rt,ra as Ut,s as Vt,sa as Lt,t as Ht,ta as zt,u as Wt,ua as qt,v as Gt,va as Xt,w as Qt,wa as Jt,x as Yt,xa as Kt,y as Zt,ya as ti,z as ii,za as si}from"./THEOplayer.common.esm.js";(r=h||(h={}))[r.t=0]="t";var ei={};function ni(t,i){(ei[i]||(ei[i]=[])).push(t)}var ri=[];var o=void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},t=void 0!==u?u:{createElement:function(){}};function hi(t,i){return i||(i=t.slice(0)),t.raw=i,t}var oi=1;function ai(){return oi++}var ui,ci=w.prototype.toString,li=function(t){return vi(t)?w.keys(t):[]};function fi(t,i){li(t).forEach((function(s){return i(t[s],s)}))}function di(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&&fi(i,(function(i,s){t[s]=i}))})),t)}function vi(t){return!!t&&"object"==typeof t}function pi(t){return vi(t)&&"[object Object]"===ci.call(t)&&t.constructor===w}var mi=function(t,i,s){void 0===s&&(s=!!vs&&vs<11),"log"!==t&&i.unshift(t.toUpperCase()+":"),ui.history.push(i),i.unshift("VIDEOJS:");var e=o.console&&o.console[t];e&&(s&&(i=i.map((function(t){if(vi(t)||Array.isArray(t))try{return JSON.stringify(t)}catch(i){return String(t)}return String(t)})).join(" ")),e.apply?e[Array.isArray(i)?"apply":"call"](o.console,i):e(i))};(ui=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];mi("log",i)}).history=[],ui.error=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return mi("error",i)},ui.warn=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return mi("warn",i)};var gi=ui,yi="undefined"!=typeof globalThis?globalThis:void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function bi(t){return t.replace(/\n\r?\s*/g,"")}var wi,ki=function(t){for(var i="",s=0;s<arguments.length;s++)i+=bi(t[s])+(arguments[s+1]||"");return i};function ji(t){return"string"==typeof t&&/\S/.test(t)}function Si(t){if(/\s/.test(t))throw new m("class has illegal whitespace characters")}function _i(){return t===o.document&&void 0!==t.createElement}function xi(t){return vi(t)&&1===t.nodeType}function Ti(i){return function(s,e){if(!ji(s))return t[i](null);ji(e)&&(e=t.querySelector(e));var n=xi(e)?e:t;return n[i]&&n[i](s)}}function Ci(i,s,e,n){void 0===i&&(i="div"),void 0===s&&(s={}),void 0===e&&(e={});var r=t.createElement(i);return w.getOwnPropertyNames(s).forEach((function(t){var i=s[t];-1!==t.indexOf("aria-")||"role"===t||"type"===t?(gi.warn(ki(wi||(wi=hi(["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,i)),r.setAttribute(t,i)):"textContent"===t?Pi(r,i):r[t]=i})),w.getOwnPropertyNames(e).forEach((function(t){r.setAttribute(t,e[t])})),n&&Gi(r,n),r}function Pi(t,i){return void 0===t.textContent?t.innerText=i:t.textContent=i,t}function Ai(t,i){i.firstChild?i.insertBefore(t,i.firstChild):i.appendChild(t)}var Mi={},Ii="vdata"+(new Date).getTime();function Ei(t){var i=t[Ii];return i||(i=t[Ii]=ai()),Mi[i]||(Mi[i]={}),Mi[i]}function Di(t){var i=t[Ii];return!!i&&!!w.getOwnPropertyNames(Mi[i]).length}function Fi(t){var i=t[Ii];if(i){delete Mi[i];try{delete t[Ii]}catch(i){t.removeAttribute?t.removeAttribute(Ii):t[Ii]=null}}}function Ni(t,i){return Si(i),t.classList?t.classList.contains(i):function(t){return new RegExp("(^|\\s)"+t+"($|\\s)")}(i).test(t.className)}function $i(t,i){return t.classList?t.classList.add(i):Ni(t,i)||(t.className=(t.className+" "+i).trim()),t}function Bi(t,i){return t.classList?t.classList.remove(i):(Si(i),t.className=t.className.split(/\s+/).filter((function(t){return t!==i})).join(" ")),t}function Oi(t,i,s){var e=Ni(t,i);if("function"==typeof s&&(s=s(t,i)),"boolean"!=typeof s&&(s=!e),s!==e)return s?$i(t,i):Bi(t,i),t}function Ri(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 Ui(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 Vi(t,i,s){t.setAttribute(i,s)}function Li(t,i){t.removeAttribute(i)}function Hi(i){var s;if(i.getBoundingClientRect&&i.parentNode&&(s=i.getBoundingClientRect()),!s)return{left:0,top:0};var e=t.documentElement,n=t.body,r=e.clientLeft||n.clientLeft||0,h=o.pageXOffset||n.scrollLeft,a=s.left+h-r,u=e.clientTop||n.clientTop||0,c=o.pageYOffset||n.scrollTop,l=s.top+c-u;return{left:k.round(a),top:k.round(l)}}function zi(t,i){var s={},e=Hi(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=k.max(0,k.min(1,(h-a+r)/r)),s.x=k.max(0,k.min(1,(u-o)/n)),s}function Wi(t){return vi(t)&&3===t.nodeType}function qi(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function Gi(i,s){return function(i){return"function"==typeof i&&(i=i()),(Array.isArray(i)?i:[i]).map((function(i){return"function"==typeof i&&(i=i()),xi(i)||Wi(i)?i:"string"==typeof i&&/\S/.test(i)?t.createTextNode(i):void 0})).filter((function(t){return t}))}(s).forEach((function(t){return i.appendChild(t)})),i}function Xi(t,i){return Gi(qi(t),i)}var Qi=Ti("querySelector"),Ji=Ti("querySelectorAll"),Yi=o.navigator&&o.navigator.userAgent||"",Ki=/AppleWebKit\/([\d.]+)/i.exec(Yi),Zi=Ki?S(Ki.pop()):null,ts=/iPad/i.test(Yi),is=/iPhone/i.test(Yi)&&!ts,ss=/iPod/i.test(Yi),es=is||ts||ss,ns=function(){var t=Yi.match(/OS (\d+)_/i);return t&&t[1]?t[1]:null}(),rs=/Android/i.test(Yi),hs=function(){var t=Yi.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!t)return null;var i=t[1]&&S(t[1]),s=t[2]&&S(t[2]);return i&&s?S(t[1]+"."+t[2]):i||null}(),os=rs&&/webkit/i.test(Yi)&&hs<2.3,as=rs&&hs<5&&Zi<537,us=/Firefox/i.test(Yi),cs=/Edge/i.test(Yi),ls=!cs&&/Chrome/i.test(Yi),fs=function(){var t=Yi.match(/Chrome\/(\d+)/);return t&&t[1]?S(t[1]):null}(),ds=/MSIE\s8\.0/.test(Yi),vs=function(){var t=/MSIE\s(\d+)\.\d/.exec(Yi),i=t&&S(t[1]);return!i&&/Trident\/7.0/i.test(Yi)&&/rv:11.0/.test(Yi)&&(i=11),i}(),ps=/Safari/i.test(Yi)&&!ls&&!rs&&!cs,ms=ps||es,gs=_i()&&("ontouchstart"in o||o.DocumentTouch&&o.document instanceof o.DocumentTouch),ys=_i()&&"backgroundSize"in o.document.createElement("video").style,bs=w.freeze({__proto__:null,IS_IPAD:ts,IS_IPHONE:is,IS_IPOD:ss,IS_IOS:es,IOS_VERSION:ns,IS_ANDROID:rs,ANDROID_VERSION:hs,IS_OLD_ANDROID:os,IS_NATIVE_ANDROID:as,IS_FIREFOX:us,IS_EDGE:cs,IS_CHROME:ls,CHROME_VERSION:fs,IS_IE8:ds,IE_VERSION:vs,IS_SAFARI:ps,IS_ANY_SAFARI:ms,TOUCH_ENABLED:gs,BACKGROUND_SIZE_SUPPORTED:ys});function ws(t,i){var s=Ei(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&&Fi(t)}function ks(t,i,s,e){s.forEach((function(s){t(i,s,e)}))}function js(i){function s(){return!0}function e(){return!1}if(!i||!i.isPropagationStopped||!i.isImmediatePropagationStopped){var n=i||o.event;for(var r in i={},n)"layerX"!==r&&"layerY"!==r&&"keyLocation"!==r&&"webkitMovementX"!==r&&"webkitMovementY"!==r&&"path"!==r&&("returnValue"===r&&n.preventDefault||(i[r]=n[r]));if(i.target||(i.target=i.srcElement||t),i.relatedTarget||(i.relatedTarget=i.fromElement===i.target?i.toElement:i.fromElement),i.preventDefault=function(){n.preventDefault&&n.preventDefault(),i.returnValue=!1,n.returnValue=!1,i.defaultPrevented=!0},i.defaultPrevented=!1,i.stopPropagation=function(){n.stopPropagation&&n.stopPropagation(),i.cancelBubble=!0,n.cancelBubble=!0,i.isPropagationStopped=s},i.isPropagationStopped=e,i.stopImmediatePropagation=function(){n.stopImmediatePropagation&&n.stopImmediatePropagation(),i.isImmediatePropagationStopped=s,i.stopPropagation()},i.isImmediatePropagationStopped=e,null!==i.clientX&&void 0!==i.clientX){var h=t.documentElement,a=t.body;i.pageX=i.clientX+(h&&h.scrollLeft||a&&a.scrollLeft||0)-(h&&h.clientLeft||a&&a.clientLeft||0),i.pageY=i.clientY+(h&&h.scrollTop||a&&a.scrollTop||0)-(h&&h.clientTop||a&&a.clientTop||0)}i.which=i.charCode||i.keyCode,null!==i.button&&void 0!==i.button&&(i.button=1&i.button?0:4&i.button?1:2&i.button?2:0)}return i}var Ss=!1;!function(){try{var t=w.defineProperty({},"passive",{get:function(){Ss=!0}});o.addEventListener("test",null,t)}catch(t){}}();var _s=["touchstart","touchmove"];function xs(t,i,s){if(Array.isArray(i))return ks(xs,t,i,s);var e=Ei(t);if(e.handlers||(e.handlers={}),e.handlers[i]||(e.handlers[i]=[]),s.guid||(s.guid=ai()),e.handlers[i].push(s),e.dispatcher||(e.disabled=!1,e.dispatcher=function(i,s){if(!e.disabled){i=js(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){gi.error(t)}}}),1===e.handlers[i].length)if(t.addEventListener){var n=!1;Ss&&_s.indexOf(i)>-1&&(n={passive:!0}),t.addEventListener(i,e.dispatcher,n)}else t.attachEvent&&t.attachEvent("on"+i,e.dispatcher)}function Ts(t,i,s){if(Di(t)){var e=Ei(t);if(e.handlers){if(Array.isArray(i))return ks(Ts,t,i,s);var n=function(i){e.handlers[i]=[],ws(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);ws(t,i)}else n(i)}else for(var o in e.handlers)n(o)}}}function Cs(t,i,s){var e=Di(t)?Ei(t):{},n=t.parentNode||t.ownerDocument;if("string"==typeof i&&(i={type:i,target:t}),i=js(i),e.dispatcher&&e.dispatcher.call(t,i,s),n&&!i.isPropagationStopped()&&!0===i.bubbles)Cs.call(null,n,i,s);else if(!n&&!i.defaultPrevented){var r=Ei(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 Ps(t,i,s){if(Array.isArray(i))return ks(Ps,t,i,s);var e=function e(){Ts(t,i,e),s.apply(this,arguments)};e.guid=s.guid=s.guid||ai(),xs(t,i,e)}var As,Ms=!1,Is=function(){if(_i()){var i=t.getElementsByTagName("video"),s=t.getElementsByTagName("audio"),e=[];if(i&&i.length>0)for(var n=0,r=i.length;n<r;n++)e.push(i[n]);if(s&&s.length>0)for(var h=0,o=s.length;h<o;h++)e.push(s[h]);if(e&&e.length>0)for(var a=0,u=e.length;a<u;a++){var c=e[a];if(!c||!c.getAttribute){Es(1);break}void 0===c.player&&null!==c.getAttribute("data-setup")&&As(c)}else Ms||Es(1)}};function Es(t,i){i&&(As=i),o.setTimeout(Is,t)}_i()&&"complete"===t.readyState?Ms=!0:Ps(o,"load",(function(){Ms=!0}));var Ds=function(i){var s=t.createElement("style");return s.className=i,s},Fs=function(t,i){t.styleSheet?t.styleSheet.cssText=i:t.textContent=i},Ns=function(t,i,s){i.guid||(i.guid=ai());var e=function(){return i.apply(t,arguments)};return e.guid=s?s+"_"+i.guid:i.guid,e};function $s(t){return"string"!=typeof t?t:t.charAt(0).toUpperCase()+t.slice(1)}function Bs(){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&&fi(i,(function(i,s){pi(i)?(pi(t[s])||(t[s]={}),t[s]=Bs(t[s],i)):t[s]=i}))})),t}var i=function(){function t(t,i,s){if(!t&&this.play?this.h=t=this:this.h=t,this.o=Bs({},this.o),i=this.o=Bs(this.o,i),this.u=i.id||i.el&&i.el.id,!this.u){var e=t&&t.id&&t.id()||"no_player";this.u=e+"l"+ai()}this.v=i.name||null,i.el?this.m=i.el:!1!==i.createEl&&(this.m=this.createEl()),this.g=[],this.k={},this.j={},!1!==i.initChildren&&this.initChildren(),this.ready(s),!1!==i.reportTouchActivity&&this.enableTouchActivity()}var i=t.prototype;return i.dispose=function(){if(this.trigger({type:"dispose",bubbles:!1}),this.g)for(var t=this.g.length-1;t>=0;t--)this.g[t].dispose&&this.g[t].dispose();this.g=null,this.k=null,this.j=null,this.off(),this.m.parentNode&&this.m.parentNode.removeChild(this.m),Fi(this.m),this.m=null},i.player=function(){return this.h},i.options=function(t){return gi.warn("this.options() has been deprecated and will be moved to the constructor in 6.0"),t?(this.o=Bs(this.o,t),this.o):this.o},i.el=function(){return this.m},i.createEl=function(t,i,s){return Ci(t,i,s)},i.localize=function(t){var i=this.h.language&&this.h.language(),s=this.h.languages&&this.h.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.m},i.id=function(){return this.u},i.name=function(){return this.v},i.children=function(){return this.g},i.getChildById=function(t){return this.k[t]},i.getChild=function(t){if(t)return t=$s(t),this.j[t]},i.addChild=function(i,s,e){var n,r;if(void 0===s&&(s={}),void 0===e&&(e=this.g.length),"string"==typeof i){r=$s(i),s||(s={}),!0===s&&(gi.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.h||this,s)}else n=i;if(this.g.splice(e,0,n),"function"==typeof n.id&&(this.k[n.id()]=n),(r=r||n.name&&$s(n.name()))&&(this.j[r]=n),"function"==typeof n.el&&n.el()){var a=this.contentEl().children[e]||null;this.contentEl().insertBefore(n.el(),a)}return n},i.removeChild=function(t){if("string"==typeof t&&(t=this.getChild(t)),t&&this.g){for(var i=!1,s=this.g.length-1;s>=0;s--)if(this.g[s]===t){i=!0,this.g.splice(s,1);break}if(i){this.k[t.id()]=null,this.j[t.name()]=null;var e=t.el();e&&e.parentNode===this.contentEl()&&this.contentEl().removeChild(t.el())}}},i.initChildren=function(){var i=this,s=this.o.children;if(s){var e,n=this.o,r=t.getComponent("Tech");(e=Array.isArray(s)?s:w.keys(s)).concat(w.keys(this.o).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.o[e]||{}:(e=t.name,n=t),{name:e,opts:n}})).filter((function(i){var s=t.getComponent(i.opts.componentClass||$s(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.o.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))xs(this.m,t,Ns(this,i));else{var n=t,r=i,h=Ns(this,s),o=function(){return e.off(n,r,h)};o.guid=h.guid,this.on("dispose",o);var a=function(){return e.off("dispose",o)};a.guid=h.guid,t.nodeName?(xs(n,r,h),xs(n,"dispose",a)):"function"==typeof t.on&&(n.on(r,h),n.on("dispose",a))}return this},i.off=function(t,i,s){if(!t||"string"==typeof t||Array.isArray(t))Ts(this.m,t,i);else{var e=t,n=i,r=Ns(this,s);this.off("dispose",r),t.nodeName?(Ts(e,n,r),Ts(e,"dispose",r)):(e.off(n,r),e.off("dispose",r))}return this},i.one=function(t,i,s){var e=arguments,n=this;if("string"==typeof t||Array.isArray(t))Ps(this.m,t,Ns(this,i));else{var r=t,h=i,o=Ns(this,s),a=function t(){n.off(r,h,t),o.apply(null,e)};a.guid=o.guid,this.on(r,h,a)}return this},i.trigger=function(t,i){return Cs(this.m,t,i),this},i.ready=function(t,i){return void 0===i&&(i=!1),t&&(this.T?i?t.call(this):this.setTimeout(t,1):(this.C=this.C||[],this.C.push(t))),this},i.triggerReady=function(){this.T=!0,this.setTimeout((function(){var t=this.C;this.C=[],t&&t.length>0&&t.forEach((function(t){t.call(this)}),this),this.trigger("ready")}),1)},i.$=function(t,i){return Qi(t,i||this.contentEl())},i.$$=function(t,i){return Ji(t,i||this.contentEl())},i.hasClass=function(t){return Ni(this.m,t)},i.addClass=function(t){return $i(this.m,t),this},i.removeClass=function(t){return Bi(this.m,t),this},i.toggleClass=function(t,i){return Oi(this.m,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.m,t)},i.setAttribute=function(t,i){return Vi(this.m,t,i),this},i.removeAttribute=function(t){return Li(this.m,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.m.style[t]=i:this.m.style[t]="auto"===i?"":i+"px",s||this.trigger("resize"),this;if(!this.m)return 0;var e=this.m.style[t],n=e.indexOf("px");return j(-1!==n?e.slice(0,n):this.m["offset"+$s(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 o.getComputedStyle){var s=o.getComputedStyle(this.m);i=s.getPropertyValue(t)||s[t]}if(0===(i=S(i))){var e="offset"+$s(t);i=this.m[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.m.focus()},i.blur=function(){this.m.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;k.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=Ns(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=Ns(this,t);var s=o.setTimeout(t,i),e=function(){this.clearTimeout(s)};return e.guid="vjs-timeout-"+s,this.on("dispose",e),s},i.clearTimeout=function(t){o.clearTimeout(t);var i=function(){};return i.guid="vjs-timeout-"+t,this.off("dispose",i),t},i.setInterval=function(t,i){t=Ns(this,t);var s=o.setInterval(t,i),e=function(){this.clearInterval(s)};return e.guid="vjs-interval-"+s,this.on("dispose",e),s},i.clearInterval=function(t){o.clearInterval(t);var i=function(){};return i.guid="vjs-interval-"+t,this.off("dispose",i),t},t.registerComponent=function(i,s){if(i){if(i=$s(i),t.P||(t.P={}),"Player"===i&&t.P[i]){var e=t.P[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.P[i]=s,s}},t.getComponent=function(i){if(i)return i=$s(i),t.P&&t.P[i]?t.P[i]:o&&o.videojs&&o.videojs[i]?(gi.warn("The "+i+" component was added to the videojs object when it should be registered using videojs.registerComponent(name, component)"),o.videojs[i]):void 0},t.extend=function(i){i=i||{},gi.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}();i.registerComponent("Component",i);var Os=function(){};function Rs(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Us(t,i){return(Us=w.setPrototypeOf?w.setPrototypeOf.bind():function(t,i){return t.__proto__=i,t})(t,i)}function Vs(t,i){t.prototype=w.create(i.prototype),t.prototype.constructor=t,Us(t,i)}function Ls(t,i,s,e){return void 0===e&&(gi.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 Hs(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:Ls.bind(null,"start",0,t),end:Ls.bind(null,"end",1,t)}}function zs(t,i){return Array.isArray(t)?Hs(t):void 0===t||void 0===i?Hs():Hs([[t,i]])}function Ws(t,i){var s,e,n=0;if(!i)return 0;t&&t.length||(t=zs(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}Os.prototype.A={},Os.prototype.on=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},xs(this,t,i),this.addEventListener=s},Os.prototype.addEventListener=Os.prototype.on,Os.prototype.off=function(t,i){Ts(this,t,i)},Os.prototype.removeEventListener=Os.prototype.off,Os.prototype.one=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},Ps(this,t,i),this.addEventListener=s},Os.prototype.trigger=function(t){var i=t.type||t;"string"==typeof t&&(t={type:i}),t=js(t),this.A[i]&&this["on"+i]&&this["on"+i](t),Cs(this,t)},Os.prototype.dispatchEvent=Os.prototype.trigger;var qs,Gs,Xs,Qs,Js={prefixed:!0},Ys=[["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"]],Ks=Ys[0];for(Gs=0;Gs<Ys.length;Gs++)if(Ys[Gs][1]in t){qs=Ys[Gs];break}if(qs){for(Xs=0;Xs<qs.length;Xs++)Js[Ks[Xs]]=qs[Xs];Js.prefixed=qs[0]!==Ks[0]}function Zs(t){if(t instanceof Zs)return t;"number"==typeof t?this.code=t:"string"==typeof t?this.message=t:vi(t)&&("number"==typeof t.code&&(this.code=t.code),di(this,t)),this.message||(this.message=Zs.defaultMessages[this.code]||"")}for(Zs.prototype.code=0,Zs.prototype.message="",Zs.prototype.status=null,Zs.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],Zs.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."},Qs=0;Qs<Zs.errorTypes.length;Qs++)Zs[Zs.errorTypes[Qs]]=Qs,Zs.prototype[Zs.errorTypes[Qs]]=Qs;var te=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}}))})},se=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))},ee=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()},ne="vjs-modal-dialog",re=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).M=e.I=e.D=!1,e.closeable(!e.o.uncloseable),e.content(e.o.content),e.S=Ci("div",{className:ne+"-content"},{role:"document"}),e.F=Ci("p",{className:ne+"-description vjs-offscreen",id:e.el().getAttribute("aria-describedby")}),Pi(e.F,e.description()),e.m.appendChild(e.F),e.m.appendChild(e.S),e.on(i,"languagechange",e.handleLanguagechange),e}Vs(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()+"N","aria-hidden":"true","aria-label":this.label(),role:"dialog"})},s.buildCSSClass=function(){return ne+" vjs-hidden "+t.prototype.buildCSSClass.call(this)},s.handleKeyPress=function(t){27===t.which&&this.closeable()&&this.close()},s.label=function(){return this.o.label||this.localize("Modal Window")},s.description=function(){var t=this.o.description||this.localize("This is a modal window.");return this.closeable()&&(t+=" "+this.localize("This modal can be closed by pressing the Escape key or activating the close button.")),t},s.open=function(){if(!this.M){var t=this.player();this.trigger("beforemodalopen"),this.M=!0,(this.o.fillAlways||!this.I&&!this.D)&&this.fill(),this.B=!t.paused(),this.o.pauseOnOpen&&this.B&&t.pause(),this.closeable()&&this.on(this.m.ownerDocument,"keydown",Ns(this,this.handleKeyPress)),t.controls(!1),this.show(),this.el().setAttribute("aria-hidden","false"),this.trigger("modalopen"),this.I=!0}return this},s.opened=function(t){return"boolean"==typeof t&&this[t?"open":"close"](),this.M},s.close=function(){if(this.M){var t=this.player();this.trigger("beforemodalclose"),this.M=!1,this.B&&this.o.pauseOnOpen&&t.play(),this.closeable()&&this.off(this.m.ownerDocument,"keydown",Ns(this,this.handleKeyPress)),t.controls(!0),this.hide(),this.el().setAttribute("aria-hidden","true"),this.trigger("modalclose"),this.o.temporary&&this.dispose()}return this},s.closeable=function(t){if("boolean"==typeof t){var i=this.O=!!t,s=this.getChild("closeButton");if(i&&!s){var e=this.S;this.S=this.m,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.O},s.fill=function(){return this.fillWith(this.content())},s.fillWith=function(t){var i=this.contentEl(),s=i.parentNode,e=i.nextSibling;return this.trigger("beforemodalfill"),this.D=!0,s.removeChild(i),this.empty(),Xi(i,t),this.trigger("modalfill"),e?s.insertBefore(i,e):s.appendChild(i),this},s.empty=function(){return this.trigger("beforemodalempty"),qi(this.contentEl()),this.trigger("modalempty"),this},s.content=function(t){return void 0!==t&&(this.R=t),this.R},s.handleLanguagechange=function(){this.m.setAttribute("aria-label",this.label()),Pi(this.F,this.description()),this.opened()?this.fill():(this.I||this.D)&&(this.I=!1,this.D=!1,this.empty())},i}(i);re.prototype.o={pauseOnOpen:!0,temporary:!0},i.registerComponent("ModalDialog",re);var he=function(){function i(s){var e=this;if(ds)for(var n in e=t.createElement("custom"),i.prototype)"constructor"!==n&&(e[n]=i.prototype[n]);if(i.prototype.U.call(e,s),w.defineProperty(e,"length",{get:function(){return this.V}}),ds)return e}var s=i.prototype;return s.U=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)},s.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},i}(),oe={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},ae={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},ue={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},ce={disabled:"disabled",hidden:"hidden",showing:"showing"},le=function(i){function s(e){var n;void 0===e&&(e={});var r=Rs(n=i.call(this)||this);if(ds)for(var h in r=t.createElement("custom"),s.prototype)"constructor"!==h&&(r[h]=s.prototype[h]);var o={id:e.id||["vjs_track",ai()].join("_"),kind:e.kind||"",label:e.label||"",language:e.language||""},a=function(t){w.defineProperty(r,t,{get:function(){return o[t]},set:function(){}})};for(var u in o)a(u);return r||Rs(n)}return Vs(s,i),s}(Os),fe=function(i){var s=["protocol","hostname","port","pathname","search","hash","host"],e=t.createElement("a");e.href=i;var n,r=""===e.host&&"file:"!==e.protocol;r&&((n=t.createElement("div")).innerHTML='<a href="'+i+'"></a>',e=n.firstChild,n.setAttribute("style","display:none; position:absolute;"),t.body.appendChild(n));for(var h={},o=0;o<s.length;o++)h[s[o]]=e[s[o]];return"http:"===h.protocol&&(h.host=h.host.replace(/:80$/,"")),"https:"===h.protocol&&(h.host=h.host.replace(/:443$/,"")),r&&t.body.removeChild(n),h},de=function(t){var i=o.location,s=fe(t);return(":"===s.protocol?i.protocol:s.protocol)+s.host!==i.protocol+i.host},ve={exports:{}};void 0!==s?ve.exports=s:void 0!==yi?ve.exports=yi:"undefined"!=typeof self?ve.exports=self:ve.exports={};var pe=function(t){var i=me.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)},me=w.prototype.toString;var ge,ye,be,we,ke,je,Se,_e,xe,Te,Ce,Pe,Ae="Function.prototype.bind called on incompatible ",Me=Array.prototype.slice,Ie=w.prototype.toString,Ee="[object Function]",De=function(t){var i=this;if("function"!=typeof i||Ie.call(i)!==Ee)throw new g(Ae+i);for(var s,e=Me.call(arguments,1),n=function(){if(this instanceof s){var n=i.apply(this,e.concat(Me.call(arguments)));return w(n)===n?n:this}return i.apply(t,e.concat(Me.call(arguments)))},r=k.max(0,i.length-e.length),h=[],o=0;o<r;o++)h.push("$"+o);if(s=Function("binder","return function ("+h.join(",")+"){ return binder.apply(this,arguments); }")(n),i.prototype){var a=function(){};a.prototype=i.prototype,s.prototype=new a,a.prototype=null}return s},Fe=Function.prototype.bind||De,Ne=w.prototype.toString,$e=function(t){var i=Ne.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]"===Ne.call(t.callee)),s};w.keys||(ye=w.prototype.hasOwnProperty,be=w.prototype.toString,we=$e,ke=w.prototype.propertyIsEnumerable,je=!ke.call({toString:null},"toString"),Se=ke.call((function(){}),"prototype"),_e=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],xe=function(t){var i=t.constructor;return i&&i.prototype===t},Te={$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},Ce=function(){if(void 0===s)return!1;for(var t in s)try{if(!Te["$"+t]&&ye.call(s,t)&&null!==s[t]&&"object"==typeof s[t])try{xe(s[t])}catch(t){return!0}}catch(t){return!0}return!1}(),Pe=function(t){if(void 0===s||!Ce)return xe(t);try{return xe(t)}catch(t){return!1}},ge=function(t){var i=null!==t&&"object"==typeof t,s="[object Function]"===be.call(t),e=we(t),n=i&&"[object String]"===be.call(t),r=[];if(!i&&!s&&!e)throw new g("Object.keys called on a non-object");var h=Se&&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(je)for(var c=Pe(t),l=0;l<_e.length;++l)c&&"constructor"===_e[l]||!ye.call(t,_e[l])||r.push(_e[l]);return r});var Be=ge,Oe=Array.prototype.slice,Re=$e,Ue=w.keys,Ve=Ue?function(t){return Ue(t)}:Be,Le=w.keys;Ve.shim=function(){w.keys?function(){var t=w.keys(arguments);return t&&t.length===arguments.length}(1,2)||(w.keys=function(t){return Re(t)?Le(Oe.call(t)):Le(t)}):w.keys=Ve;return w.keys||Ve};var He=Ve,ze="function"==typeof Symbol&&"symbol"==typeof Symbol("foo"),We=w.prototype.toString,qe=Array.prototype.concat,Ge=w.defineProperty,Xe=Ge&&function(){var t={};try{for(var i in Ge(t,"x",{enumerable:!1,value:t}),t)return!1;return t.x===t}catch(t){return!1}}(),Qe=function(t,i,s,e){(!(i in t)||function(t){return"function"==typeof t&&"[object Function]"===We.call(t)}(e)&&e())&&(Xe?Ge(t,i,{configurable:!0,enumerable:!1,value:s,writable:!0}):t[i]=s)},Je=function(t,i){var s=arguments.length>2?arguments[2]:{},e=He(i);ze&&(e=qe.call(e,w.getOwnPropertySymbols(i)));for(var n=0;n<e.length;n+=1)Qe(t,e[n],i[e[n]],s[e[n]])};Je.supportsDescriptors=!!Xe;var Ye,Ke=Je,Ze=w.getOwnPropertyDescriptor?function(){return w.getOwnPropertyDescriptor(arguments,"callee").get}():function(){throw new g},tn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator,sn=w.getPrototypeOf||function(t){return t.__proto__},en=void 0===x?Ye:sn(x),nn={"$ %Array%":Array,"$ %ArrayBuffer%":"undefined"==typeof ArrayBuffer?Ye:ArrayBuffer,"$ %ArrayBufferPrototype%":"undefined"==typeof ArrayBuffer?Ye:ArrayBuffer.prototype,"$ %ArrayIteratorPrototype%":tn?sn([][Symbol.iterator]()):Ye,"$ %ArrayPrototype%":Array.prototype,"$ %ArrayProto_entries%":Array.prototype.entries,"$ %ArrayProto_forEach%":Array.prototype.forEach,"$ %ArrayProto_keys%":Array.prototype.keys,"$ %ArrayProto_values%":Array.prototype.values,"$ %AsyncFromSyncIteratorPrototype%":Ye,"$ %AsyncFunction%":undefined,"$ %AsyncFunctionPrototype%":Ye,"$ %AsyncGenerator%":Ye,"$ %AsyncGeneratorFunction%":undefined,"$ %AsyncGeneratorPrototype%":Ye,"$ %AsyncIteratorPrototype%":Ye,"$ %Atomics%":"undefined"==typeof Atomics?Ye:Atomics,"$ %Boolean%":Boolean,"$ %BooleanPrototype%":Boolean.prototype,"$ %DataView%":"undefined"==typeof DataView?Ye:DataView,"$ %DataViewPrototype%":"undefined"==typeof DataView?Ye: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?Ye:Float32Array,"$ %Float32ArrayPrototype%":"undefined"==typeof Float32Array?Ye:Float32Array.prototype,"$ %Float64Array%":"undefined"==typeof Float64Array?Ye:Float64Array,"$ %Float64ArrayPrototype%":"undefined"==typeof Float64Array?Ye:Float64Array.prototype,"$ %Function%":Function,"$ %FunctionPrototype%":Function.prototype,"$ %Generator%":Ye,"$ %GeneratorFunction%":undefined,"$ %GeneratorPrototype%":Ye,"$ %Int8Array%":"undefined"==typeof Int8Array?Ye:Int8Array,"$ %Int8ArrayPrototype%":"undefined"==typeof Int8Array?Ye:Int8Array.prototype,"$ %Int16Array%":"undefined"==typeof Int16Array?Ye:Int16Array,"$ %Int16ArrayPrototype%":"undefined"==typeof Int16Array?Ye:Int8Array.prototype,"$ %Int32Array%":"undefined"==typeof Int32Array?Ye:Int32Array,"$ %Int32ArrayPrototype%":"undefined"==typeof Int32Array?Ye:Int32Array.prototype,"$ %isFinite%":isFinite,"$ %isNaN%":_,"$ %IteratorPrototype%":tn?sn(sn([][Symbol.iterator]())):Ye,"$ %JSON%":JSON,"$ %JSONParse%":JSON.parse,"$ %Map%":"undefined"==typeof Map?Ye:Map,"$ %MapIteratorPrototype%":"undefined"!=typeof Map&&tn?sn((new Map)[Symbol.iterator]()):Ye,"$ %MapPrototype%":"undefined"==typeof Map?Ye:Map.prototype,"$ %Math%":k,"$ %Number%":Number,"$ %NumberPrototype%":Number.prototype,"$ %Object%":w,"$ %ObjectPrototype%":w.prototype,"$ %ObjProto_toString%":w.prototype.toString,"$ %ObjProto_valueOf%":w.prototype.valueOf,"$ %parseFloat%":S,"$ %parseInt%":j,"$ %Promise%":"undefined"==typeof Promise?Ye:Promise,"$ %PromisePrototype%":"undefined"==typeof Promise?Ye:Promise.prototype,"$ %PromiseProto_then%":"undefined"==typeof Promise?Ye:Promise.prototype.then,"$ %Promise_all%":"undefined"==typeof Promise?Ye:Promise.all,"$ %Promise_reject%":"undefined"==typeof Promise?Ye:Promise.reject,"$ %Promise_resolve%":"undefined"==typeof Promise?Ye:Promise.resolve,"$ %Proxy%":"undefined"==typeof Proxy?Ye:Proxy,"$ %RangeError%":RangeError,"$ %RangeErrorPrototype%":RangeError.prototype,"$ %ReferenceError%":ReferenceError,"$ %ReferenceErrorPrototype%":ReferenceError.prototype,"$ %Reflect%":"undefined"==typeof Reflect?Ye:Reflect,"$ %RegExp%":RegExp,"$ %RegExpPrototype%":RegExp.prototype,"$ %Set%":"undefined"==typeof Set?Ye:Set,"$ %SetIteratorPrototype%":"undefined"!=typeof Set&&tn?sn((new Set)[Symbol.iterator]()):Ye,"$ %SetPrototype%":"undefined"==typeof Set?Ye:Set.prototype,"$ %SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?Ye:SharedArrayBuffer,"$ %SharedArrayBufferPrototype%":"undefined"==typeof SharedArrayBuffer?Ye:SharedArrayBuffer.prototype,"$ %String%":String,"$ %StringIteratorPrototype%":tn?sn(""[Symbol.iterator]()):Ye,"$ %StringPrototype%":String.prototype,"$ %Symbol%":tn?Symbol:Ye,"$ %SymbolPrototype%":tn?Symbol.prototype:Ye,"$ %SyntaxError%":b,"$ %SyntaxErrorPrototype%":b.prototype,"$ %ThrowTypeError%":Ze,"$ %TypedArray%":en,"$ %TypedArrayPrototype%":en?en.prototype:Ye,"$ %TypeError%":g,"$ %TypeErrorPrototype%":g.prototype,"$ %Uint8Array%":void 0===x?Ye:x,"$ %Uint8ArrayPrototype%":void 0===x?Ye:x.prototype,"$ %Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?Ye:Uint8ClampedArray,"$ %Uint8ClampedArrayPrototype%":"undefined"==typeof Uint8ClampedArray?Ye:Uint8ClampedArray.prototype,"$ %Uint16Array%":"undefined"==typeof Uint16Array?Ye:Uint16Array,"$ %Uint16ArrayPrototype%":"undefined"==typeof Uint16Array?Ye:Uint16Array.prototype,"$ %Uint32Array%":"undefined"==typeof Uint32Array?Ye:Uint32Array,"$ %Uint32ArrayPrototype%":"undefined"==typeof Uint32Array?Ye:Uint32Array.prototype,"$ %URIError%":URIError,"$ %URIErrorPrototype%":URIError.prototype,"$ %WeakMap%":"undefined"==typeof WeakMap?Ye:WeakMap,"$ %WeakMapPrototype%":"undefined"==typeof WeakMap?Ye:WeakMap.prototype,"$ %WeakSet%":"undefined"==typeof WeakSet?Ye:WeakSet,"$ %WeakSetPrototype%":"undefined"==typeof WeakSet?Ye: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 nn))throw new b("intrinsic "+t+" does not exist!");if(void 0===nn[s]&&!i)throw new g("intrinsic "+t+" exists, but is not available. Please file an issue!");return nn[s]},hn=Fe.call(Function.call,w.prototype.hasOwnProperty),on=rn,an=on("%TypeError%"),un=on("%SyntaxError%"),cn=hn,ln={"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(cn(i,e)&&!s[e])return!1;var n=cn(i,"[[Value]]"),r=cn(i,"[[Get]]")||cn(i,"[[Set]]");if(n&&r)throw new an("Property Descriptors may not be both accessor and data descriptors");return!0}},fn=Number.isNaN||function(t){return t!=t},dn=Number.isNaN||function(t){return t!=t},vn=Number.isFinite||function(t){return"number"==typeof t&&!dn(t)&&t!==1/0&&t!==-1/0},pn=Function.prototype.toString,mn=/^\s*class\b/,gn=function(t){try{var i=pn.call(t);return mn.test(i)}catch(t){return!1}},yn=w.prototype.toString,bn="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,wn=function(t){if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if("function"==typeof t&&!t.prototype)return!0;if(bn)return function(t){try{return!gn(t)&&(pn.call(t),!0)}catch(t){return!1}}(t);if(gn(t))return!1;var i=yn.call(t);return"[object Function]"===i||"[object GeneratorFunction]"===i},kn=w.prototype.toString,jn=function(t){return null===t||"function"!=typeof t&&"object"!=typeof t},Sn=wn,_n=function(t){var i;if((i=arguments.length>1?arguments[1]:"[object Date]"===kn.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(Sn(t[n[e]])&&(s=t[n[e]](),jn(s)))return s;throw new g("No default value")}throw new g("invalid [[DefaultValue]] hint supplied")},xn=rn,Tn=xn("%Object%"),Cn=xn("%TypeError%"),Pn=xn("%String%"),An=function(t,i,s,e){var n=ln[i];if("function"!=typeof n)throw new un("unknown record type: "+i);if(!n(t,e))throw new an(s+" must be a "+i);console.log(n(t,e),e)},Mn=fn,In=vn,En=function(t){return t>=0?1:-1},Dn=function(t,i){var s=t%i;return k.floor(s>=0?s:s+i)},Fn=hn,Nn={ToPrimitive:function(t){return jn(t)?t:arguments.length>1?_n(t,arguments[1]):_n(t)},ToBoolean:function(t){return!!t},ToNumber:function(t){return+t},ToInteger:function(t){var i=this.ToNumber(t);return Mn(i)?0:0!==i&&In(i)?En(i)*k.floor(k.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(Mn(i)||0===i||!In(i))return 0;var s=En(i)*k.floor(k.abs(i));return Dn(s,65536)},ToString:function(t){return Pn(t)},ToObject:function(t){return this.CheckObjectCoercible(t),Tn(t)},CheckObjectCoercible:function(t,i){if(null==t)throw new Cn(i||"Cannot call method on "+t);return t},IsCallable:wn,SameValue:function(t,i){return t===i?0!==t||1/t==1/i:Mn(t)&&Mn(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(Fn(t,s)&&!i[s])return!1;var e=Fn(t,"[[Value]]"),n=Fn(t,"[[Get]]")||Fn(t,"[[Set]]");if(e&&n)throw new Cn("Property Descriptors may not be both accessor and data descriptors");return!0},IsAccessorDescriptor:function(t){return void 0!==t&&(An(this,"Property Descriptor","Desc",t),!(!Fn(t,"[[Get]]")&&!Fn(t,"[[Set]]")))},IsDataDescriptor:function(t){return void 0!==t&&(An(this,"Property Descriptor","Desc",t),!(!Fn(t,"[[Value]]")&&!Fn(t,"[[Writable]]")))},IsGenericDescriptor:function(t){return void 0!==t&&(An(this,"Property Descriptor","Desc",t),!this.IsAccessorDescriptor(t)&&!this.IsDataDescriptor(t))},FromPropertyDescriptor:function(t){if(void 0===t)return t;if(An(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 Cn("FromPropertyDescriptor must be called with a fully populated Property Descriptor")},ToPropertyDescriptor:function(t){if("Object"!==this.Type(t))throw new Cn("ToPropertyDescriptor requires an object");var i={};if(Fn(t,"enumerable")&&(i["[[Enumerable]]"]=this.ToBoolean(t.enumerable)),Fn(t,"configurable")&&(i["[[Configurable]]"]=this.ToBoolean(t.configurable)),Fn(t,"value")&&(i["[[Value]]"]=t.value),Fn(t,"writable")&&(i["[[Writable]]"]=this.ToBoolean(t.writable)),Fn(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(Fn(t,"set")){var e=t.set;if(void 0!==e&&!this.IsCallable(e))throw new Cn("setter must be a function");i["[[Set]]"]=e}if((Fn(i,"[[Get]]")||Fn(i,"[[Set]]"))&&(Fn(i,"[[Value]]")||Fn(i,"[[Writable]]")))throw new Cn("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return i}},$n=Fe.call(Function.call,String.prototype.replace),Bn=/^[\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]+/,On=/[\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]+$/,Rn=function(){var t=Nn.ToString(Nn.CheckObjectCoercible(this));return $n($n(t,Bn,""),On,"")},Un=Rn,Vn=function(){return String.prototype.trim&&"\u200b"==="\u200b".trim()?String.prototype.trim:Un},Ln=Ke,Hn=Vn,zn=Ke,Wn=Rn,qn=Vn,Gn=function(){var t=Hn();return Ln(String.prototype,{trim:t},{trim:function(){return String.prototype.trim!==t}}),t},Xn=Fe.call(Function.call,qn());zn(Xn,{getPolyfill:qn,implementation:Wn,shim:Gn});var Qn=Xn,Jn=wn,Yn=w.prototype.toString,Kn=w.prototype.hasOwnProperty,Zn=function(t,i,s){for(var e=0,n=t.length;e<n;e++)Kn.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))},tr=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)},ir=function(t,i,s){for(var e in t)Kn.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))},sr=Qn,er=function(t,i,s){if(!Jn(i))throw new g("iterator must be a function");var e;arguments.length>=3&&(e=s),"[object Array]"===Yn.call(t)?Zn(t,i,e):"string"==typeof t?tr(t,i,e):ir(t,i,e)},nr=function(){for(var t={},i=0;i<arguments.length;i++){var s=arguments[i];for(var e in s)rr.call(s,e)&&(t[e]=s[e])}return t},rr=w.prototype.hasOwnProperty;var hr=ve.exports,or=pe,ar=function(t){if(!t)return{};var i={};return er(sr(t).split("\n"),(function(t){var s=t.indexOf(":"),e=sr(t.slice(0,s)).toLowerCase(),n=sr(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},ur=nr,cr=fr;function lr(t,i,s){var e=t;return or(i)?(s=i,"string"==typeof t&&(e={uri:t})):e=ur(i,{uri:t}),e.callback=s,e}function fr(t,i,s){return dr(i=lr(t,i,s))}function dr(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=u.response?u.response:u.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}(u),b)try{t=JSON.parse(t)}catch(t){}return t}var n={body:void 0,headers:{},statusCode:0,method:d,url:f,rawRequest:u};function r(t){return v(l),t instanceof m||(t=new m(""+(t||"Unknown XMLHttpRequest Error"))),t.statusCode=0,s(t,n)}function h(){if(!a){var i;v(l),i=t.useXDR&&void 0===u.status?200:1223===u.status?204:u.status;var r=n,h=null;return 0!==i?(r={body:e(),statusCode:i,method:d,headers:{},url:f,rawRequest:u},u.getAllResponseHeaders&&(r.headers=ar(u.getAllResponseHeaders()))):h=new m("Internal XMLHttpRequest Error"),s(h,r,r.body)}}var o,a,u=t.xhr||null;u||(u=t.cors||t.useXDR?new fr.XDomainRequest:new fr.XMLHttpRequest);var l,f=u.url=t.uri||t.url,d=u.method=t.method||"GET",p=t.body||t.data||null,g=u.headers=t.headers||{},y=!!t.sync,b=!1;if("json"in t&&(b=!0,g.accept||g.Accept||(g.Accept="application/json"),"GET"!==d&&"HEAD"!==d&&(g["content-type"]||g["Content-Type"]||(g["Content-Type"]="application/json"),p=JSON.stringify(t.json))),u.onreadystatechange=function(){4===u.readyState&&h()},u.onload=h,u.onerror=r,u.onprogress=function(){},u.ontimeout=r,u.open(d,f,!y,t.username,t.password),y||(u.withCredentials=!!t.withCredentials),!y&&t.timeout>0&&(l=c((function(){a=!0,u.abort("timeout");var t=new m("XMLHttpRequest timeout");t.code="ETIMEDOUT",r(t)}),t.timeout)),u.setRequestHeader)for(o in g)g.hasOwnProperty(o)&&u.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&&(u.responseType=t.responseType),"beforeSend"in t&&"function"==typeof t.beforeSend&&t.beforeSend(u),u.send(p),u}fr.XMLHttpRequest=hr.XMLHttpRequest||function(){},fr.XDomainRequest="withCredentials"in new fr.XMLHttpRequest?fr.XMLHttpRequest:hr.XDomainRequest,function(t,i){for(var s=0;s<t.length;s++)i(t[s])}(["get","put","post","patch","head","delete"],(function(t){fr["delete"===t?"del":t]=function(i,s,e){return(s=lr(i,s,e)).method=t.toUpperCase(),dr(s)}}));var vr=function(t,i){var s=new o.WebVTT.Parser(o,o.vttjs,o.WebVTT.StringDecoder()),e=[];s.oncue=function(t){i.addCue(t)},s.onparsingerror=function(t){e.push(t)},s.onflush=function(){i.trigger({type:"loadeddata",target:i})},s.parse(t),e.length>0&&(o.console&&o.console.groupCollapsed&&o.console.groupCollapsed("Text Track parsing errors for "+i.src),e.forEach((function(t){return gi.error(t)})),o.console&&o.console.groupEnd&&o.console.groupEnd()),s.flush()},pr=function(t){function i(s){var e;if(void 0===s&&(s={}),!s.tech)throw new m("A tech was not provided.");var n=Bs(s,{kind:ue[s.kind]||"subtitles",language:s.language||s.srclang||""}),r=ce[n.mode]||"disabled",h=n.default;"metadata"!==n.kind&&"chapters"!==n.kind||(r="hidden");var a=e=t.call(this,n)||this;if(a.H=n.tech,ds)for(var u in i.prototype)"constructor"!==u&&(a[u]=i.prototype[u]);a.L=[],a.W=[];var c=new he(a.L),l=new he(a.W),f=!1,d=Ns(a,(function(){this.activeCues,f&&(this.trigger("cuechange"),f=!1)}));return"disabled"!==r&&a.H.ready((function(){a.H.on("timeupdate",d)}),!0),w.defineProperty(a,"default",{get:function(){return h},set:function(){}}),w.defineProperty(a,"mode",{get:function(){return r},set:function(t){var i=this;ce[t]&&("showing"===(r=t)&&this.H.ready((function(){i.H.on("timeupdate",d)}),!0),this.trigger("modechange"))}}),w.defineProperty(a,"cues",{get:function(){return this.q?c:null},set:function(){}}),w.defineProperty(a,"activeCues",{get:function(){if(!this.q)return null;if(0===this.cues.length)return l;for(var t=this.H.currentTime(),i=[],s=0,e=this.cues.length;s<e;s++){var n=this.cues[s];(n.startTime<=t&&n.endTime>=t||n.startTime===n.endTime&&n.startTime<=t&&n.startTime+.5>=t)&&i.push(n)}if(f=!1,i.length!==this.W.length)f=!0;else for(var r=0;r<i.length;r++)-1===this.W.indexOf(i[r])&&(f=!0);return this.W=i,l.U(this.W),l},set:function(){}}),n.src?(a.src=n.src,function(t,i){var s={uri:t},e=de(t);e&&(s.cors=e),cr(s,Ns(this,(function(t,s,e){if(t)return gi.error(t,s);if(i.q=!0,"function"!=typeof o.WebVTT){if(i.H){var n=function(){return vr(e,i)};i.H.on("vttjsloaded",n),i.H.on("vttjserror",(function(){gi.error("vttjs failed to load, stopping trying to process "+i.src),i.H.off("vttjsloaded",n)}))}}else vr(e,i)})))}(n.src,a)):a.q=!0,a||Rs(e)}Vs(i,t);var s=i.prototype;return s.addCue=function(t){var i=t;if(o.vttjs&&!(t instanceof o.vttjs.VTTCue)){for(var s in i=new o.vttjs.VTTCue(t.startTime,t.endTime,t.text),t)s in i||(i[s]=t[s]);i.id=t.id,i.G=t}var e=this.H.textTracks();if(e)for(var n=0;n<e.length;n++)e[n]!==this&&e[n].removeCue(i);this.L.push(i),this.cues.U(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.U(this.L);break}}},i}(le);pr.prototype.A={cuechange:"cuechange"};var mr=function(i){function s(e){var n,r;void 0===e&&(e={});var h=Rs(n=i.call(this)||this);if(ds)for(var o in h=t.createElement("custom"),s.prototype)"constructor"!==o&&(h[o]=s.prototype[o]);var a=new pr(e);return h.kind=a.kind,h.src=a.src,h.srclang=a.language,h.label=a.label,h.default=a.default,w.defineProperty(h,"readyState",{get:function(){return r}}),w.defineProperty(h,"track",{get:function(){return a}}),r=0,a.addEventListener("loadeddata",(function(){r=2,h.trigger({type:"load",target:h})})),ds?h||Rs(n):n}return Vs(s,i),s}(Os);mr.prototype.A={load:"load"},mr.NONE=0,mr.LOADING=1,mr.LOADED=2,mr.ERROR=3;var gr,yr=function(){function i(s){void 0===s&&(s=[]);var e=this;if(ds)for(var n in e=t.createElement("custom"),i.prototype)"constructor"!==n&&(e[n]=i.prototype[n]);e.X=[],w.defineProperty(e,"length",{get:function(){return this.X.length}});for(var r=0,h=s.length;r<h;r++)e.J(s[r]);if(ds)return e}var s=i.prototype;return s.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)},s.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},s.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}},i}(),br=function(i){function s(e,n){var r;if(void 0===e&&(e=[]),void 0===n&&(n=null),r=i.call(this)||this,!n&&(n=Rs(r),ds))for(var h in n=t.createElement("custom"),s.prototype)"constructor"!==h&&(n[h]=s.prototype[h]);n.Z=[],w.defineProperty(n,"length",{get:function(){return this.Z.length}});for(var o=0;o<e.length;o++)n.tt(e[o]);return n||Rs(r)}Vs(s,i);var e=s.prototype;return e.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"}))},e.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"})},e.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},s}(Os);for(gr in br.prototype.A={change:"change",addtrack:"addtrack",removetrack:"removetrack"},br.prototype.A)br.prototype["on"+gr]=null;var wr=function(i){function s(e){var n,r;if(void 0===e&&(e=[]),ds){for(var h in r=t.createElement("custom"),br.prototype)"constructor"!==h&&(r[h]=br.prototype[h]);for(var o in s.prototype)"constructor"!==o&&(r[o]=s.prototype[o])}return(r=n=i.call(this,e,r)||this)||Rs(n)}return Vs(s,i),s.prototype.tt=function(t){i.prototype.tt.call(this,t),t.addEventListener("modechange",Ns(this,(function(){this.trigger("change")})))},s}(br),kr=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].selected=!1)},jr=function(i){function s(e){var n,r;void 0===e&&(e=[]);for(var h=e.length-1;h>=0;h--)if(e[h].selected){kr(e,e[h]);break}if(ds){for(var o in r=t.createElement("custom"),br.prototype)"constructor"!==o&&(r[o]=br.prototype[o]);for(var a in s.prototype)"constructor"!==a&&(r[a]=s.prototype[a])}return(r=n=i.call(this,e,r)||this).st=!1,w.defineProperty(r,"selectedIndex",{get:function(){for(var t=0;t<this.length;t++)if(this[t].selected)return t;return-1},set:function(){}}),r||Rs(n)}Vs(s,i);var e=s.prototype;return e.tt=function(t){var s=this;t.selected&&kr(this,t),i.prototype.tt.call(this,t),t.addEventListener&&t.addEventListener("selectedchange",(function(){s.st||(s.st=!0,kr(s,t),s.st=!1,s.trigger("change"))}))},e.addTrack=function(t){this.tt(t)},e.removeTrack=function(t){i.prototype.it.call(this,t)},s}(br),Sr=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].enabled=!1)},_r=function(i){function s(e){var n,r;void 0===e&&(e=[]);for(var h=e.length-1;h>=0;h--)if(e[h].enabled){Sr(e,e[h]);break}if(ds){for(var o in r=t.createElement("custom"),br.prototype)"constructor"!==o&&(r[o]=br.prototype[o]);for(var a in s.prototype)"constructor"!==a&&(r[a]=s.prototype[a])}return(r=n=i.call(this,e,r)||this).st=!1,r||Rs(n)}Vs(s,i);var e=s.prototype;return e.tt=function(t){var s=this;t.enabled&&Sr(this,t),i.prototype.tt.call(this,t),t.addEventListener&&t.addEventListener("enabledchange",(function(){s.st||(s.st=!0,Sr(s,t),s.st=!1,s.trigger("change"))}))},e.addTrack=function(t){this.tt(t)},e.removeTrack=function(t){i.prototype.it.call(this,t)},s}(br);var xr=function(i){function s(t,s){var e;return void 0===t&&(t={}),void 0===s&&(s=function(){}),t.reportTouchActivity=!1,(e=i.call(this,null,t,s)||this).et=!1,e.on("playing",(function(){this.et=!0})),e.on("loadstart",(function(){this.et=!1})),e.nt=t.textTracks,e.rt=t.videoTracks,e.ht=t.audioTracks,e.featuresProgressEvents||e.manualProgressOn(),e.featuresTimeupdateEvents||e.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach((function(i){!1===t["native"+i+"Tracks"]&&(e["featuresNative"+i+"Tracks"]=!1)})),!1===t.nativeCaptions&&(e.featuresNativeTextTracks=!1),e.featuresNativeTextTracks||e.emulateTextTracks(),e.ot=new wr,e.initTextTrackListeners(),e.initTrackListeners(),t.nativeControlsForTouch||e.emitTapEvents(),e.constructor&&(e.v=e.constructor.name||"Unknown Tech"),e}Vs(s,i);var e=s.prototype;return e.manualProgressOn=function(){this.on("durationchange",this.onDurationChange),this.manualProgress=!0,this.one("ready",this.trackProgress)},e.manualProgressOff=function(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange)},e.trackProgress=function(t){this.stopTrackingProgress(),this.progressInterval=this.setInterval(Ns(this,(function(){var t=this.bufferedPercent();this.ut!==t&&this.trigger("progress"),this.ut=t,1===t&&this.stopTrackingProgress()})),500)},e.onDurationChange=function(t){this.ct=this.duration()},e.buffered=function(){return zs(0,0)},e.bufferedPercent=function(){return Ws(this.buffered(),this.ct)},e.stopTrackingProgress=function(){this.clearInterval(this.progressInterval)},e.manualTimeUpdatesOn=function(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime),this.on("pause",this.stopTrackingCurrentTime)},e.manualTimeUpdatesOff=function(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime),this.off("pause",this.stopTrackingCurrentTime)},e.trackCurrentTime=function(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval((function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}),250)},e.stopTrackingCurrentTime=function(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},e.dispose=function(){this.clearTracks(["audio","video","text"]),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),i.prototype.dispose.call(this)},e.clearTracks=function(t){var i=this;(t=[].concat(t)).forEach((function(t){for(var s=i[t+"Tracks"]()||[],e=s.length;e--;){var n=s[e];"text"===t&&i.removeRemoteTextTrack(n),s.it(n)}}))},e.cleanupAutoTextTracks=function(){for(var t=this.ot||[],i=t.length;i--;){var s=t[i];this.removeRemoteTextTrack(s)}},e.reset=function(){},e.error=function(t){return void 0!==t&&(this.lt=new Zs(t),this.trigger("error")),this.lt},e.played=function(){return this.et?zs(0,0):zs()},e.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},e.initTextTrackListeners=function(){var t=Ns(this,(function(){this.trigger("texttrackchange")})),i=this.textTracks();i&&(i.addEventListener("removetrack",t),i.addEventListener("addtrack",t),this.on("dispose",Ns(this,(function(){i.removeEventListener("removetrack",t),i.removeEventListener("addtrack",t)}))))},e.initTrackListeners=function(){var t=this;["video","audio"].forEach((function(i){var s=function(){t.trigger(i+"trackchange")},e=t[i+"Tracks"]();e.addEventListener("removetrack",s),e.addEventListener("addtrack",s),t.on("dispose",(function(){e.removeEventListener("removetrack",s),e.removeEventListener("addtrack",s)}))}))},e.ft=function(){var i=this;if(!o.WebVTT)if(t.body.contains(this.el())){if(!this.o["vtt.js"]&&pi(undefined)&&w.keys(undefined).length>0)return void this.trigger("vttjsloaded");var s=t.createElement("script");s.src=this.o["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.12.4/vtt.min.js",s.onload=function(){i.trigger("vttjsloaded")},s.onerror=function(){i.trigger("vttjserror")},this.on("dispose",(function(){s.onload=null,s.onerror=null})),o.WebVTT=!0,this.el().parentNode.appendChild(s)}else this.ready(this.ft)},e.emulateTextTracks=function(){var t=this,i=this.textTracks();if(i){var s=this.remoteTextTracks(),e=function(t){return i.tt(t.track)},n=function(t){return i.it(t.track)};s.on("addtrack",e),s.on("removetrack",n),this.ft();var r=function(){return t.trigger("texttrackchange")},h=function(){r();for(var t=0;t<i.length;t++){var s=i[t];s.removeEventListener("cuechange",r),"showing"===s.mode&&s.addEventListener("cuechange",r)}};h(),i.addEventListener("change",h),i.addEventListener("addtrack",h),i.addEventListener("removetrack",h),this.on("dispose",(function(){s.off("addtrack",e),s.off("removetrack",n),i.removeEventListener("change",h),i.removeEventListener("addtrack",h),i.removeEventListener("removetrack",h);for(var t=0;t<i.length;t++){i[t].removeEventListener("cuechange",r)}}))}},e.videoTracks=function(){return this.rt=this.rt||new jr,this.rt},e.audioTracks=function(){return this.ht=this.ht||new _r,this.ht},e.textTracks=function(){return this.nt=this.nt||new wr,this.nt},e.remoteTextTracks=function(){return this.dt=this.dt||new wr,this.dt},e.remoteTextTrackEls=function(){return this.vt=this.vt||new yr,this.vt},e.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 pr(n);return r.tt(h),h}(this,t,i,s)},e.createRemoteTextTrack=function(t){var i=Bs(t,{tech:this});return new mr(i)},e.addRemoteTextTrack=function(t,i){void 0===t&&(t={});var s=this.createRemoteTextTrack(t);return!0!==i&&!1!==i&&(gi.warn('Calling addRemoteTextTrack without explicitly setting the "manualCleanup" parameter to `true` is deprecated and default to `false` in future version of video.js'),i=!0),this.remoteTextTrackEls().J(s),this.remoteTextTracks().tt(s.track),!0!==i&&this.ot.tt(s.track),s},e.removeRemoteTextTrack=function(t){var i=this.remoteTextTrackEls().Y(t);this.remoteTextTrackEls().K(i),this.remoteTextTracks().it(t),this.ot.it(t)},e.getVideoPlaybackQuality=function(){return{}},e.setPoster=function(){},e.playsinline=function(){},e.setPlaysinline=function(){},e.canPlayType=function(){return""},s.isTech=function(t){return t.prototype instanceof s||t instanceof s||t===s},s.registerTech=function(t,i){if(s.gt||(s.gt={}),!s.isTech(i))throw new m("Tech "+t+" must be a Tech");return s.gt[t]=i,i},s.getTech=function(t){return s.gt&&s.gt[t]?s.gt[t]:o&&o.videojs&&o.videojs[t]?(gi.warn("The "+t+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),o.videojs[t]):void 0},s}(i);xr.prototype.nt,xr.prototype.ht,xr.prototype.rt,xr.prototype.featuresVolumeControl=!0,xr.prototype.featuresFullscreenResize=!1,xr.prototype.featuresPlaybackRate=!1,xr.prototype.featuresProgressEvents=!1,xr.prototype.featuresTimeupdateEvents=!1,xr.prototype.featuresNativeTextTracks=!1,xr.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.o);return s||(t.nativeSourceHandler?s=t.nativeSourceHandler:gi.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.m,"loadstart",t.prototype.wt),this.off(this.m,"loadstart",t.prototype.kt),this.one(this.m,"loadstart",t.prototype.wt)),this.yt=s.handleSource(i,this,this.o),this.on("dispose",this.disposeSourceHandler),this},t.prototype.wt=function(){this.one(this.m,"loadstart",t.prototype.kt)},t.prototype.kt=function(){this.disposeSourceHandler(),this.one(this.m,"loadstart",t.prototype.kt)},t.prototype.disposeSourceHandler=function(){this.bt&&(this.clearTracks(["audio","video"]),this.bt=null),this.cleanupAutoTextTracks(),this.yt&&(this.off(this.m,"loadstart",t.prototype.wt),this.off(this.m,"loadstart",t.prototype.kt),this.yt.dispose&&this.yt.dispose(),this.yt=null)}},i.registerComponent("Tech",xr),i.registerComponent("MediaTechController",xr),xr.registerTech("Tech",xr);var Tr=function(t){function s(s,e,n){var r;if(r=t.call(this,s,e,n)||this,e.playerOptions.sources&&0!==e.playerOptions.sources.length)s.src(e.playerOptions.sources);else for(var h=0,o=e.playerOptions.techOrder;h<o.length;h++){var a=$s(o[h]),u=xr.getTech(a);if(a||(u=i.getComponent(a)),u&&u.isSupported()){s.jt(a);break}}return r}return Vs(s,t),s}(i);i.registerComponent("MediaLoader",Tr);var Cr=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).emitTapEvents(),e.on(t,"languagechange",e.handleLanguagechange),e.enable(),e}Vs(s,i);var e=s.prototype;return e.createEl=function(t,s,e){void 0===t&&(t="div"),void 0===s&&(s={}),void 0===e&&(e={}),s=di({className:this.buildCSSClass(),tabIndex:0},s),"button"===t&&gi.error("Creating a ClickableComponent with an HTML element of "+t+" is not supported; use a Button instead."),e=di({role:"button","aria-live":"polite"},e),this.St=s.tabIndex;var n=i.prototype.createEl.call(this,t,s,e);return this.createControlTextEl(n),n},e.createControlTextEl=function(t){return this._t=Ci("span",{className:"vjs-control-text"}),t&&t.appendChild(this._t),this.controlText(this.xt,t),this._t},e.controlText=function(t,i){if(void 0===i&&(i=this.el()),void 0===t)return this.xt||"Need Text";var s=this.localize(t);return this.xt=t,this._t.innerHTML=s,this.nonIconControl||i.setAttribute("title",s),this},e.buildCSSClass=function(){return"vjs-control vjs-button "+i.prototype.buildCSSClass.call(this)},e.enable=function(){return this.removeClass("vjs-disabled"),this.m.setAttribute("aria-disabled","false"),void 0!==this.St&&this.m.setAttribute("tabIndex",this.St),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},e.disable=function(){return this.addClass("vjs-disabled"),this.m.setAttribute("aria-disabled","true"),void 0!==this.St&&this.m.removeAttribute("tabIndex"),this.off(["tap","click"],this.handleClick),this.off("focus",this.handleFocus),this.off("blur",this.handleBlur),this},e.handleLanguagechange=function(){this.controlText(this.xt)},e.handleClick=function(t){},e.handleFocus=function(i){xs(t,"keydown",Ns(this,this.handleKeyPress))},e.handleKeyPress=function(t){32===t.which||13===t.which?(t.preventDefault(),this.handleClick(t)):i.prototype.handleKeyPress&&i.prototype.handleKeyPress.call(this,t)},e.handleBlur=function(i){Ts(t,"keydown",Ns(this,this.handleKeyPress))},s}(i);i.registerComponent("ClickableComponent",Cr);var Pr=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).update(),i.on("posterchange",Ns(Rs(e),e.update)),e}Vs(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=Ci("div",{className:"vjs-poster",tabIndex:-1});return ys||(this.Tt=Ci("img"),t.appendChild(this.Tt)),t},s.update=function(t){var i=this.player().poster();this.setSrc(i),i?this.show():this.hide()},s.setSrc=function(t){if(this.Tt)this.Tt.src=t;else{var i="";t&&(i='url("'+t+'")'),this.m.style.backgroundImage=i}},s.handleClick=function(t){this.h.controls()&&(this.h.paused()?this.h.play():this.h.pause())},i}(Cr);i.registerComponent("PosterImage",Pr);var Ar="#222",Mr={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 Ir(t,i){return"rgba("+j(t[1]+t[1],16)+","+j(t[2]+t[2],16)+","+j(t[3]+t[3],16)+","+i+")"}function Er(t,i,s){try{t.style[i]=s}catch(t){return}}var Dr=function(t){function i(i,s,e){var n;return n=t.call(this,i,s,e)||this,i.on("loadstart",Ns(Rs(n),n.toggleDisplay)),i.on("texttrackchange",Ns(Rs(n),n.updateDisplay)),i.ready(Ns(Rs(n),(function(){if(i.H&&i.H.featuresNativeTextTracks)this.hide();else{i.on("fullscreenchange",Ns(this,this.updateDisplay));for(var t=this.o.playerOptions.tracks||[],s=0;s<t.length;s++)this.h.addRemoteTextTrack(t[s],!0);var e,n,r={captions:1,subtitles:1},h=this.h.textTracks();if(h){for(var o=0;o<h.length;o++){var a=h[o];a.default&&("descriptions"!==a.kind||e?a.kind in r&&!n&&(n=a):e=a)}n?n.mode="showing":e&&(e.mode="showing")}}}))),n}Vs(i,t);var s=i.prototype;return s.toggleDisplay=function(){this.h.H&&this.h.H.featuresNativeTextTracks?this.hide():this.show()},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-text-track-display"},{"aria-live":"off","aria-atomic":"true"})},s.clearDisplay=function(){"function"==typeof o.WebVTT&&o.WebVTT.processCues(o,[],this.m)},s.updateDisplay=function(){var t=this.h.textTracks();if(this.clearDisplay(),t){for(var i=null,s=null,e=t.length;e--;){var n=t[e];"showing"===n.mode&&("descriptions"===n.kind?i=n:s=n)}s?("off"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","off"),this.updateForTrack(s)):i&&("assertive"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","assertive"),this.updateForTrack(i))}},s.updateForTrack=function(t){if("function"==typeof o.WebVTT&&t.activeCues){for(var i=this.h.textTrackSettings.getValues(),s=[],e=0;e<t.activeCues.length;e++)s.push(t.activeCues[e]);o.WebVTT.processCues(o,s,this.m);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&&Er(h.firstChild,"color",Ir(i.color||"#fff",i.textOpacity)),i.backgroundColor&&(h.firstChild.style.backgroundColor=i.backgroundColor),i.backgroundOpacity&&Er(h.firstChild,"backgroundColor",Ir(i.backgroundColor||"#000",i.backgroundOpacity)),i.windowColor&&(i.windowOpacity?Er(h,"backgroundColor",Ir(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 "+Ar:"raised"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #222, 2px 2px #222, 3px 3px "+Ar:"depressed"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #ccc, 0 1px #ccc, -1px -1px #222, 0 -1px "+Ar:"uniform"===i.edgeStyle&&(h.firstChild.style.textShadow="0 0 4px #222, 0 0 4px #222, 0 0 4px #222, 0 0 4px "+Ar)),i.fontPercent&&1!==i.fontPercent){var a=o.parseFloat(h.style.fontSize);h.style.fontSize=a*i.fontPercent+"px",h.style.height="auto",h.style.top="auto",h.style.bottom="2px"}i.fontFamily&&"default"!==i.fontFamily&&("small-caps"===i.fontFamily?h.firstChild.style.fontVariant="small-caps":h.firstChild.style.fontFamily=Mr[i.fontFamily])}}}},i}(i);i.registerComponent("TextTrackDisplay",Dr);var Fr=function(t){function i(){return t.apply(this,arguments)||this}return Vs(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"})},i}(i);i.registerComponent("LoadingSpinner",Fr);var Nr=function(t){function s(){return t.apply(this,arguments)||this}Vs(s,t);var e=s.prototype;return e.createEl=function(t,s,e){void 0===t&&(t="button"),void 0===s&&(s={}),void 0===e&&(e={}),s=di({className:this.buildCSSClass()},s),"button"!==t&&(gi.warn("Creating a Button with an HTML element of "+t+" is deprecated; use ClickableComponent instead."),s=di({tabIndex:0},s),e=di({role:"button"},e)),e=di({type:"button","aria-live":"polite"},e);var n=i.prototype.createEl.call(this,t,s,e);return this.createControlTextEl(n),n},e.addChild=function(t,s){void 0===s&&(s={});var e=this.constructor.name;return gi.warn("Adding an actionable (user controllable) child to a Button ("+e+") is not supported; use a ClickableComponent instead."),i.prototype.addChild.call(this,t,s)},e.enable=function(){t.prototype.enable.call(this),this.m.removeAttribute("disabled")},e.disable=function(){t.prototype.disable.call(this),this.m.setAttribute("disabled","disabled")},e.handleKeyPress=function(i){32!==i.which&&13!==i.which&&t.prototype.handleKeyPress.call(this,i)},s}(Cr);i.registerComponent("Button",Nr);var $r=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Ct=!1,e.on("mousedown",e.handleMouseDown),e}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-big-play-button"},s.handleClick=function(t){var i=this.h.play();if(!(this.Ct&&t.clientX&&t.clientY)){var s=this.h.getChild("controlBar"),e=s&&s.getChild("playToggle");if(e){var n=function(){return e.focus()};if(i&&i.then){i.then(n,(function(){}))}else this.setTimeout(n,1)}else this.h.focus()}},s.handleKeyPress=function(i){this.Ct=!1,t.prototype.handleKeyPress.call(this,i)},s.handleMouseDown=function(t){this.Ct=!0},i}(Nr);$r.prototype.xt="Play Video",i.registerComponent("BigPlayButton",$r);var Br=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).controlText(s&&s.controlText||"Close"),e}Vs(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}(Nr);i.registerComponent("CloseButton",Br);var Or=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}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-play-control "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.h.paused()?this.h.play():this.h.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}(Nr);function Rr(t,i){void 0===i&&(i=t),t=t<0?0:t;var s=k.floor(t%60),e=k.floor(t/60%60),n=k.floor(t/3600),r=k.floor(i/60%60),h=k.floor(i/3600);return(_(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)}Or.prototype.xt="Play",i.registerComponent("PlayToggle",Or);var Ur=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}Vs(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=Ci("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.h.scrubbing()?this.h.getCache().currentTime:this.h.currentTime(),s=this.localize("Current Time"),e=Rr(i,this.h.duration());e!==this.Pt&&(this.Pt=e,this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e)},i}(i);i.registerComponent("CurrentTimeDisplay",Ur);var Vr=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}Vs(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=Ci("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.h.duration();if(i&&this.ct!==i){this.ct=i;var s=this.localize("Duration Time"),e=Rr(i);this.S.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e}},i}(i);i.registerComponent("DurationDisplay",Vr);var Lr=function(t){function i(){return t.apply(this,arguments)||this}return Vs(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-time-control vjs-time-divider",innerHTML:"<div><span>/</span></div>"})},i}(i);i.registerComponent("TimeDivider",Lr);var Hr=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}Vs(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=Ci("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.h.duration()){var i=this.localize("Remaining Time"),s=Rr(this.h.remainingTime());s!==this.Pt&&(this.Pt=s,this.S.innerHTML='<span class="vjs-control-text">'+i+"</span> -"+s)}},i}(i);i.registerComponent("RemainingTimeDisplay",Hr);var zr=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).updateShowing(),e.on(e.player(),"durationchange",e.updateShowing),e.on(e.player(),"languagechange",e.handleLanguagechange),e}Vs(s,i);var e=s.prototype;return e.createEl=function(){var s=i.prototype.createEl.call(this,"div",{className:"vjs-live-control vjs-control"});return this.S=Ci("div",{className:"vjs-live-display"},{"aria-live":"off"}),this._t=Ci("span",{className:"vjs-control-text",innerHTML:this.localize("Stream Type")}),this.At=t.createTextNode(this.localize("LIVE")),this.S.appendChild(this._t),this.S.appendChild(this.At),s.appendChild(this.S),s},e.updateShowing=function(t){this.player().duration()===1/0?this.show():this.hide()},e.handleLanguagechange=function(){this._t.innerHTML=this.localize("Stream Type"),this.At.innerHTML=this.localize("LIVE")},s}(i);i.registerComponent("LiveDisplay",zr);var Wr=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).bar=e.getChild(e.o.barName),e.vertical(!!e.o.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(t,"controlsvisible",e.update),e.on(t,e.playerEvent,e.update),e}Vs(s,i);var e=s.prototype;return e.createEl=function(t,s,e){return void 0===s&&(s={}),void 0===e&&(e={}),s.className=s.className+" vjs-slider",s=di({tabIndex:0},s),e=di({role:"slider","aria-valuenow":0,"aria-valuemin":0,"aria-valuemax":100,tabIndex:0},e),i.prototype.createEl.call(this,t,s,e)},e.handleMouseDown=function(i){var s=this.bar.m.ownerDocument;i.preventDefault(),t.body.focus(),t.onselectstart=function(){return!1},this.addClass("vjs-sliding"),this.trigger("slideractive"),this.on(s,"mousemove",this.handleMouseMove),this.on(s,"mouseup",this.handleMouseUp),this.on(s,"touchmove",this.handleMouseMove),this.on(s,"touchend",this.handleMouseUp),this.handleMouseMove(i)},e.handleMouseMove=function(t){},e.handleMouseUp=function(){var i=this.bar.m.ownerDocument;t.onselectstart=function(){return!0},this.removeClass("vjs-sliding"),this.trigger("sliderinactive"),this.off(i,"mousemove",this.handleMouseMove),this.off(i,"mouseup",this.handleMouseUp),this.off(i,"touchmove",this.handleMouseMove),this.off(i,"touchend",this.handleMouseUp),this.update()},e.update=function(){if(this.m){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}}},e.calculateDistance=function(t){var i=zi(this.m,t);return this.vertical()?i.y:i.x},e.handleFocus=function(){this.on(this.bar.m.ownerDocument,"keydown",this.handleKeyPress)},e.handleKeyPress=function(t){37===t.which||40===t.which?(t.preventDefault(),this.stepBack()):38!==t.which&&39!==t.which||(t.preventDefault(),this.stepForward())},e.handleBlur=function(){this.off(this.bar.m.ownerDocument,"keydown",this.handleKeyPress)},e.handleClick=function(t){t.stopImmediatePropagation(),t.preventDefault()},e.vertical=function(t){return void 0===t?this.Mt||!1:(this.Mt=!!t,this.Mt?this.addClass("vjs-slider-vertical"):this.addClass("vjs-slider-horizontal"),this)},s}(i);function qr(t,i){if(!t||!i)return"";if("function"==typeof o.getComputedStyle){var s=o.getComputedStyle(t);return s?s[i]:""}return t.currentStyle[i]||""}i.registerComponent("Slider",Wr);var Gr=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).It=[],e.on(t,"progress",e.update),e.on(t,"languagechange",e.handleLanguagechange),e}Vs(s,i);var e=s.prototype;return e.createEl=function(){var s=i.prototype.createEl.call(this,"div",{className:"vjs-load-progress"});return this.Et=Ci("span",{innerHTML:this.localize("Loaded")}),this.Dt=t.createTextNode(": 0%"),this._t=Ci("span",{className:"vjs-control-text"}),this._t.appendChild(this.Et),this._t.appendChild(this.Dt),s.appendChild(this._t),s},e.update=function(t){var i=this.h.buffered(),s=this.h.duration(),e=this.h.bufferedEnd(),n=this.It,r=function(t,i){var s=t/i||0;return 100*(s>=1?1:s)+"%"};this.m.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.m.appendChild(Ci()),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.m.removeChild(n[c-1]);n.length=i.length},e.handleLanguagechange=function(){this.Et.innerHTML=this.localize("Loaded")},s}(i);i.registerComponent("LoadProgressBar",Gr);var Xr=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).updateDataAttr(),e.on(t,"timeupdate",e.updateDataAttr),e.on(t,"languagechange",e.handleLanguagechange),t.ready(Ns(Rs(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}Vs(s,i);var e=s.prototype;return e.createEl=function(){var s=i.prototype.createEl.call(this,"div",{className:"vjs-play-progress vjs-slider-bar"});return this.Ft=Ci("span",{innerHTML:this.localize("Progress")}),this.Nt=t.createTextNode(": 0%"),this._t=Ci("span",{className:"vjs-control-text"}),this._t.appendChild(this.Ft),this._t.appendChild(this.Nt),s.appendChild(this._t),s},e.updateDataAttr=function(t){var i=this.h.scrubbing()?this.h.getCache().currentTime:this.h.currentTime();this.m.setAttribute("data-current-time",Rr(i,this.h.duration()))},e.handleLanguagechange=function(){this.Ft.innerHTML=this.localize("Progress")},s}(i);i.registerComponent("PlayProgressBar",Xr);var Qr=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).updateDataAttr(),e.on(t,"timeupdate",e.updateDataAttr),e.on(t,"languagechange",e.handleLanguagechange),t.ready(Ns(Rs(e),e.updateDataAttr)),e}Vs(s,i);var e=s.prototype;return e.createEl=function(){var s=i.prototype.createEl.call(this,"div",{className:"vjs-tooltip-progress-bar vjs-slider-bar"});return this.tooltip=Ci("div",{className:"vjs-time-tooltip"}),this.Ft=Ci("span",{innerHTML:this.localize("Progress")}),this.Nt=t.createTextNode(": 0%"),this._t=Ci("span",{className:"vjs-control-text"}),this._t.appendChild(this.Ft),this._t.appendChild(this.Nt),s.appendChild(this.tooltip),s.appendChild(this._t),s},e.updateDataAttr=function(t){var i=Rr(this.h.scrubbing()?this.h.getCache().currentTime:this.h.currentTime(),this.h.duration());this.m.setAttribute("data-current-time",i),this.tooltip.innerHTML=i},e.handleLanguagechange=function(){this.Ft.innerHTML=this.localize("Progress")},s}(i);i.registerComponent("TooltipProgressBar",Qr);var Jr=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(Ns(Rs(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}Vs(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.m),this.keepTooltipsInside){this.updateAriaAttributes(this.tooltipProgressBar.m),this.tooltipProgressBar.m.style.width=this.bar.m.style.width;var i=S(qr(this.player().el(),"width")),s=S(qr(this.tooltipProgressBar.tooltip,"width")),e=this.tooltipProgressBar.el().style;e.maxWidth=k.floor(i-s/2)+"px",e.minWidth=k.ceil(s/2)+"px",e.right="-"+s/2+"px"}},s.updateAriaAttributes=function(t){var i=this.h.scrubbing()?this.h.getCache().currentTime:this.h.currentTime();t.setAttribute("aria-valuenow",(100*this.getPercent()).toFixed(2)),t.setAttribute("aria-valuetext",Rr(i,this.h.duration()))},s.getPercent=function(){var t=this.h.currentTime()/this.h.duration();return t>=1?1:t},s.handleMouseDown=function(i){this.h.scrubbing(!0),this.videoWasPlaying=!this.h.paused(),this.h.pause(),t.prototype.handleMouseDown.call(this,i)},s.handleMouseMove=function(t){var i=this.calculateDistance(t)*this.h.duration();i===this.h.duration()&&(i-=.1),this.h.currentTime(i)},s.handleMouseUp=function(i){t.prototype.handleMouseUp.call(this,i),this.h.scrubbing(!1),this.videoWasPlaying&&this.h.play()},s.stepForward=function(){this.h.currentTime(this.h.currentTime()+5)},s.stepBack=function(){this.h.currentTime(this.h.currentTime()-5)},i}(Wr);Jr.prototype.o={children:["loadProgressBar","mouseTimeDisplay","playProgressBar"],barName:"playProgressBar"},Jr.prototype.playerEvent="timeupdate",i.registerComponent("SeekBar",Jr);var Yr=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=Ci("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)}}(Ns(Rs(e),e.handleMouseMove),25))})),e}Vs(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.h.duration(),s=this.calculateDistance(t)*i,e=t.pageX-Hi(this.el().parentNode).left;this.update(s,e)},s.update=function(t,i){var s=Rr(t,this.h.duration());if(this.el().style.left=i+"px",this.el().setAttribute("data-current-time",s),this.keepTooltipsInside){var e=i-this.$t(i)+1,n=S(qr(this.tooltip,"width"))/2;this.tooltip.innerHTML=s,this.tooltip.style.right="-"+(n-e)+"px"}},s.calculateDistance=function(t){return zi(this.el().parentNode,t).x},s.$t=function(t){if(!this.keepTooltipsInside)return t;var i=S(qr(this.player().el(),"width")),s=S(qr(this.tooltip,"width"))/2,e=t;return t<s?e=k.ceil(s):t>i-s&&(e=k.floor(i-s)),e},i}(i);i.registerComponent("MouseTimeDisplay",Yr);var Kr=function(t){function i(){return t.apply(this,arguments)||this}return Vs(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},i}(i);Kr.prototype.o={children:["seekBar"]},i.registerComponent("ProgressControl",Kr);var Zr=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"fullscreenchange",e.handleFullscreenChange),e}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-fullscreen-control "+t.prototype.buildCSSClass.call(this)},s.handleFullscreenChange=function(t){this.h.isFullscreen()?this.controlText("Non-Fullscreen"):this.controlText("Fullscreen")},s.handleClick=function(t){this.h.isFullscreen()?this.h.exitFullscreen():this.h.requestFullscreen()},i}(Nr);Zr.prototype.xt="Fullscreen",i.registerComponent("FullscreenToggle",Zr);var th=function(t){function i(){return t.apply(this,arguments)||this}return Vs(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-level",innerHTML:'<span class="vjs-control-text"></span>'})},i}(i);i.registerComponent("VolumeLevel",th);var ih=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.updateARIAAttributes),i.ready(Ns(Rs(e),e.updateARIAAttributes)),e}Vs(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.h.volume(this.calculateDistance(t))},s.checkMuted=function(){this.h.muted()&&this.h.muted(!1)},s.getPercent=function(){return this.h.muted()?0:this.h.volume()},s.stepForward=function(){this.checkMuted(),this.h.volume(this.h.volume()+.1)},s.stepBack=function(){this.checkMuted(),this.h.volume(this.h.volume()-.1)},s.updateARIAAttributes=function(t){var i=(100*this.h.volume()).toFixed(2);this.m.setAttribute("aria-valuenow",i),this.m.setAttribute("aria-valuetext",i+"%")},i}(Wr);ih.prototype.o={children:["volumeLevel"],barName:"volumeLevel"},ih.prototype.playerEvent="volumechange",i.registerComponent("VolumeBar",ih);var sh=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 Vs(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control"})},i}(i);sh.prototype.o={children:["volumeBar"]},i.registerComponent("VolumeControl",sh);var eh=function(t){function i(){return t.apply(this,arguments)||this}Vs(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",Ns(this,(function(){this.unlockShowing()})))},s.createEl=function(){var i=this.o.contentElType||"ul";this.S=Ci(i,{className:"vjs-menu-content"});var s=t.prototype.createEl.call(this,"div",{append:this.S,className:"vjs-menu"});return s.appendChild(this.S),xs(s,"click",(function(t){t.preventDefault(),t.stopImmediatePropagation()})),s},i}(i);i.registerComponent("Popup",eh);var nh=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e}Vs(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.o.inline?i+="-inline":i+="-popup","vjs-menu-button "+i+" "+t.prototype.buildCSSClass.call(this)},i}(Cr);i.registerComponent("PopupButton",nh);var rh=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}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-mute-control "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.h.muted(!this.h.muted())},s.update=function(t){var i=this.h.volume(),s=3;this.h.muted()?s=0:i<.33?s=1:i<.67&&(s=2);var e=this.h.muted()?"Unmute":"Mute";this.controlText()!==e&&this.controlText(e);for(var n=0;n<4;n++)Bi(this.m,"vjs-vol-"+n);$i(this.m,"vjs-vol-"+s)},i}(Nr);rh.prototype.xt="Mute",i.registerComponent("MuteToggle",rh);var hh=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(Rs(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}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){var i="";return i=this.o.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 eh(this.h,{contentElType:"div"}),i=new ih(this.h,this.o.volumeBar);return t.addChild(i),this.menuContent=t,this.volumeBar=i,this.attachVolumeBarEvents(),t},s.handleClick=function(i){rh.prototype.handleClick.call(this),t.prototype.handleClick.call(this)},s.attachVolumeBarEvents=function(){this.menuContent.on(["mousedown","touchdown"],Ns(this,this.handleMouseDown))},s.handleMouseDown=function(t){this.on(["mousemove","touchmove"],Ns(this.volumeBar,this.volumeBar.handleMouseMove)),this.on(this.m.ownerDocument,["mouseup","touchend"],this.handleMouseUp)},s.handleMouseUp=function(t){this.off(["mousemove","touchmove"],Ns(this.volumeBar,this.volumeBar.handleMouseMove))},i}(nh);hh.prototype.volumeUpdate=rh.prototype.update,hh.prototype.xt="Mute",i.registerComponent("VolumeMenuButton",hh);var oh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Bt=-1,e.on("keydown",e.handleKeyPress),e}Vs(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",Ns(this,(function(t){this.unlockShowing()})))},s.createEl=function(){var i=this.o.contentElType||"ul";this.S=Ci(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),xs(s,"click",(function(t){t.preventDefault(),t.stopImmediatePropagation()})),s},s.handleKeyPress=function(t){37===t.which||40===t.which?(t.preventDefault(),this.stepForward()):38!==t.which&&39!==t.which||(t.preventDefault(),this.stepBack())},s.stepForward=function(){var t=0;void 0!==this.Bt&&(t=this.Bt+1),this.focus(t)},s.stepBack=function(){var t=0;void 0!==this.Bt&&(t=this.Bt-1),this.focus(t)},s.focus=function(t){void 0===t&&(t=0);var i=this.children().slice();i.length&&i[0].className&&/vjs-menu-title/.test(i[0].className)&&i.shift(),i.length>0&&(t<0?t=0:t>=i.length&&(t=i.length-1),this.Bt=t,i[t].m.focus())},i}(i);i.registerComponent("Menu",oh);var ah=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e.Ot=!0,e.m.setAttribute("aria-haspopup","true"),e.m.setAttribute("role","menuitem"),e.on("keydown",e.handleSubmenuKeyPress),e}Vs(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.m.setAttribute("aria-expanded","false"),this.items&&this.items.length<=this.Ut?this.hide():this.show()},s.createMenu=function(){var t=new oh(this.h);if(this.Ut=0,this.o.title){var i=Ci("li",{className:"vjs-menu-title",innerHTML:$s(this.o.title),tabIndex:-1});this.Ut+=1,t.g.unshift(i),Ai(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.o.inline?i+="-inline":i+="-popup","vjs-menu-button "+i+" "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.one(this.menu.contentEl(),"mouseleave",Ns(this,(function(t){this.unpressButton(),this.m.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.Ot&&(this.Rt=!0,this.menu.lockShowing(),this.m.setAttribute("aria-expanded","true"),this.menu.focus())},s.unpressButton=function(){this.Ot&&(this.Rt=!1,this.menu.unlockShowing(),this.m.setAttribute("aria-expanded","false"),this.m.focus())},s.disable=function(){return this.Rt=!1,this.menu.unlockShowing(),this.m.setAttribute("aria-expanded","false"),this.Ot=!1,t.prototype.disable.call(this)},s.enable=function(){return this.Ot=!0,t.prototype.enable.call(this)},i}(Cr);i.registerComponent("MenuButton",ah);var uh=function(t){function i(i,s){var e,n=s.tracks;if((e=t.call(this,i,s)||this).items.length<=1&&e.hide(),!n)return Rs(e);var r=Ns(Rs(e),e.update);return n.addEventListener("removetrack",r),n.addEventListener("addtrack",r),e.h.on("dispose",(function(){n.removeEventListener("removetrack",r),n.removeEventListener("addtrack",r)})),e}return Vs(i,t),i}(ah);i.registerComponent("TrackButton",uh);var ch=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).selectable=s.selectable,e.selected(s.selected),e.selectable?e.m.setAttribute("role","menuitemcheckbox"):e.m.setAttribute("role","menuitem"),e}Vs(s,i);var e=s.prototype;return e.createEl=function(s,e,n){this.nonIconControl=!0;var r=i.prototype.createEl.call(this,"li",di({className:"vjs-menu-item",tabIndex:-1},e),n);return this.Vt=t.createTextNode(this.localize(this.o.label)),r.appendChild(this.Vt),r},e.handleClick=function(t){this.selected(!0)},e.selected=function(t){this.selectable&&(t?(this.addClass("vjs-selected"),this.m.setAttribute("aria-checked","true"),this.controlText(", selected")):(this.removeClass("vjs-selected"),this.m.setAttribute("aria-checked","false"),this.controlText("")))},e.handleLanguagechange=function(){i.prototype.handleLanguagechange.call(this),this.Vt.innerHTML=this.localize(this.o.label)},s}(Cr);i.registerComponent("MenuItem",ch);var lh=function(i){function s(s,e){var n,r,h=e.track,a=s.textTracks();if(e.label=h.label||h.language||"Unknown",e.selected=h.default||"showing"===h.mode,(n=i.call(this,s,e)||this).track=h,a){var u=Ns(Rs(n),n.handleTracksChange);s.on(["loadstart","texttrackchange"],u),a.addEventListener("change",u),n.on("dispose",(function(){a.removeEventListener("change",u)}))}a&&void 0===a.onchange&&n.on(["tap","click"],(function(){if("object"!=typeof o.Event)try{r=new o.Event("change")}catch(t){}r||(r=t.createEvent("Event")).initEvent("change",!0,!0),a.dispatchEvent(r)}));return n}Vs(s,i);var e=s.prototype;return e.handleClick=function(t){var s=this.track.kind,e=this.h.textTracks();if(i.prototype.handleClick.call(this,t),e)for(var n=0;n<e.length;n++){var r=e[n];r.kind===s&&(r===this.track?"showing"!==r.mode&&(r.mode="showing"):"disabled"!==r.mode&&(r.mode="disabled"))}},e.handleTracksChange=function(t){this.selected("showing"===this.track.mode)},s}(ch);i.registerComponent("TextTrackMenuItem",lh);var fh=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 Vs(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}(lh);i.registerComponent("OffTextTrackMenuItem",fh);var dh=function(t){function i(i,s){return void 0===s&&(s={}),s.tracks=i.textTracks(),t.call(this,i,s)||this}return Vs(i,t),i.prototype.createItems=function(t){void 0===t&&(t=[]),t.push(new fh(this.h,{kind:this.Lt})),this.Ut+=1;var i=this.h.textTracks();if(!i)return t;for(var s=0;s<i.length;s++){var e=i[s];e.kind===this.Lt&&t.push(new lh(this.h,{track:e,selectable:!0}))}return t},i}(uh);i.registerComponent("TextTrackButton",dh);var vh=function(t){function i(i,s){var e,n=s.track,r=s.cue,h=i.currentTime();return s.selectable=!0,s.label=r.text,s.selected=r.startTime<=h&&h<r.endTime,(e=t.call(this,i,s)||this).track=n,e.cue=r,n.addEventListener("cuechange",Ns(Rs(e),e.update)),e}Vs(i,t);var s=i.prototype;return s.handleClick=function(i){t.prototype.handleClick.call(this),this.h.currentTime(this.cue.startTime),this.update(this.cue.startTime)},s.update=function(t){var i=this.cue,s=this.h.currentTime();this.selected(i.startTime<=s&&s<i.endTime)},i}(ch);i.registerComponent("ChaptersTrackMenuItem",vh);var ph=function(t){function i(i,s,e){var n;return(n=t.call(this,i,s,e)||this).m.setAttribute("aria-label","Chapters Menu"),n}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-chapters-button "+t.prototype.buildCSSClass.call(this)},s.update=function(i){this.Ht&&(!i||"addtrack"!==i.type&&"removetrack"!==i.type)||this.setTrack(this.findChaptersTrack()),t.prototype.update.call(this)},s.setTrack=function(t){if(this.Ht!==t){if(this.zt||(this.zt=this.update.bind(this)),this.Ht){var i=this.h.remoteTextTrackEls().Y(this.Ht);i&&i.removeEventListener("load",this.zt),this.Ht=null}if(this.Ht=t,this.Ht){this.Ht.mode="hidden";var s=this.h.remoteTextTrackEls().Y(this.Ht);s&&s.addEventListener("load",this.zt)}}},s.findChaptersTrack=function(){for(var t=this.h.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($s(this.Lt))},s.createMenu=function(){return this.o.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 vh(this.h,{track:this.Ht,cue:n});t.push(r)}return t},i}(dh);ph.prototype.Lt="chapters",ph.prototype.xt="Chapters",i.registerComponent("ChaptersButton",ph);var mh=function(t){function i(i,s,e){var n;(n=t.call(this,i,s,e)||this).m.setAttribute("aria-label","Descriptions Menu");var r=i.textTracks();if(r){var h=Ns(Rs(n),n.handleTracksChange);r.addEventListener("change",h),n.on("dispose",(function(){r.removeEventListener("change",h)}))}return n}Vs(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}(dh);mh.prototype.Lt="descriptions",mh.prototype.xt="Descriptions",i.registerComponent("DescriptionsButton",mh);var gh=function(t){function i(i,s,e){var n;return(n=t.call(this,i,s,e)||this).m.setAttribute("aria-label","Subtitles Menu"),n}return Vs(i,t),i.prototype.buildCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildCSSClass.call(this)},i}(dh);gh.prototype.Lt="subtitles",gh.prototype.xt="Subtitles",i.registerComponent("SubtitlesButton",gh);var yh=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 Vs(i,t),i.prototype.handleClick=function(t){this.player().getChild("textTrackSettings").show(),this.player().getChild("textTrackSettings").m.focus()},i}(lh);i.registerComponent("CaptionSettingsMenuItem",yh);var bh=function(t){function i(i,s,e){var n;return(n=t.call(this,i,s,e)||this).m.setAttribute("aria-label","Captions Menu"),n}Vs(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 yh(this.h,{kind:this.Lt})),this.Ut+=1),t.prototype.createItems.call(this,i)},i}(dh);bh.prototype.Lt="captions",bh.prototype.xt="Captions",i.registerComponent("CaptionsButton",bh);var wh=function(t){function i(i,s){var e,n=s.track,r=i.audioTracks();if(s.label=n.label||n.language||"Unknown",s.selected=n.enabled,(e=t.call(this,i,s)||this).track=n,r){var h=Ns(Rs(e),e.handleTracksChange);r.addEventListener("change",h),e.on("dispose",(function(){r.removeEventListener("change",h)}))}return e}Vs(i,t);var s=i.prototype;return s.handleClick=function(i){var s=this.h.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}(ch);i.registerComponent("AudioTrackMenuItem",wh);var kh=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).m.setAttribute("aria-label","Audio Menu"),e}Vs(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.Ut=1;var i=this.h.audioTracks&&this.h.audioTracks();if(!i)return t;for(var s=0;s<i.length;s++){var e=i[s];t.push(new wh(this.h,{track:e,selectable:!0}))}return t},i}(uh);kh.prototype.xt="Audio Track",i.registerComponent("AudioTrackButton",kh);var jh=function(t){function i(i,s){var e,n=s.rate,r=S(n,10);return s.label=n,s.selected=1===r,s.selectable=!0,(e=t.call(this,i,s)||this).label=n,e.rate=r,e.on(i,"ratechange",e.update),e}Vs(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}(ch);jh.prototype.contentElType="button",i.registerComponent("PlaybackRateMenuItem",jh);var Sh=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}Vs(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this);return this.Vt=Ci("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 oh(this.player()),i=this.playbackRates();if(i)for(var s=i.length-1;s>=0;s--)t.addChild(new jh(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.o.playbackRates||this.o.playerOptions&&this.o.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}(ah);Sh.prototype.xt="Playback Rate",i.registerComponent("PlaybackRateMenuButton",Sh);var _h=function(t){function i(){return t.apply(this,arguments)||this}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-spacer "+t.prototype.buildCSSClass.call(this)},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass()})},i}(i);i.registerComponent("Spacer",_h);var xh=function(t){function i(){return t.apply(this,arguments)||this}Vs(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}(_h);i.registerComponent("CustomControlSpacer",xh);var Th=function(t){function i(){return t.apply(this,arguments)||this}return Vs(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"},{role:"group"})},i}(i);Th.prototype.o={children:["playToggle","volumeMenuButton","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subtitlesButton","captionsButton","audioTrackButton","fullscreenToggle"]},i.registerComponent("ControlBar",Th);var Ch=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"error",e.open),e}Vs(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}(re);Ch.prototype.o=Bs(re.prototype.o,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),i.registerComponent("ErrorDisplay",Ch);var Ph="vjs-text-track-settings",Ah=["#000","Black"],Mh=["#00F","Blue"],Ih=["#0FF","Cyan"],Eh=["#0F0","Green"],Dh=["#F0F","Magenta"],Fh=["#F00","Red"],Nh=["#FFF","White"],$h=["#FF0","Yellow"],Bh=["1","Opaque"],Oh=["0.5","Semi-Transparent"],Rh=["0","Transparent"],Uh={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[Ah,Nh,Fh,Eh,Mh,$h,Dh,Ih]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[Bh,Oh,Rh]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[Nh,Ah,Fh,Eh,Mh,$h,Dh,Ih]},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:[Bh,Oh]},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:[Rh,Oh,Bh]}};function Vh(t,i){if(i&&(t=i(t)),t&&"none"!==t)return t}Uh.windowColor.options=Uh.backgroundColor.options;var Lh,Hh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).setDefaults(),e.hide(),e.updateDisplay=Ns(Rs(e),e.updateDisplay),void 0===s.persistTextTrackSettings&&(e.o.persistTextTrackSettings=e.o.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()})),fi(Uh,(function(t){e.on(e.$(t.selector),"change",e.updateDisplay)})),e.o.persistTextTrackSettings&&e.restoreSettings(),e}Vs(i,t);var s=i.prototype;return s.Wt=function(t){var i=this,s=Uh[t],e=s.id.replace("%s",this.u);return[Ci("label",{className:"vjs-label",textContent:s.label},{for:e}),Ci("select",{id:e},void 0,s.options.map((function(t){return Ci("option",{textContent:i.localize(t[1]),value:t[0]})})))]},s.qt=function(){var t=Ci("legend",{textContent:this.localize("Text")}),i=this.Wt("color"),s=Ci("span",{className:"vjs-text-opacity vjs-opacity"},void 0,this.Wt("textOpacity"));return Ci("fieldset",{className:"vjs-fg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Gt=function(){var t=Ci("legend",{textContent:this.localize("Background")}),i=this.Wt("backgroundColor"),s=Ci("span",{className:"vjs-bg-opacity vjs-opacity"},void 0,this.Wt("backgroundOpacity"));return Ci("fieldset",{className:"vjs-bg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Xt=function(){var t=Ci("legend",{textContent:this.localize("Window")}),i=this.Wt("windowColor"),s=Ci("span",{className:"vjs-window-opacity vjs-opacity"},void 0,this.Wt("windowOpacity"));return Ci("fieldset",{className:"vjs-window-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Qt=function(){return Ci("div",{className:"vjs-tracksettings-colors"},void 0,[this.qt(),this.Gt(),this.Xt()])},s.Jt=function(){var t=Ci("div",{className:"vjs-font-percent vjs-tracksetting"},void 0,this.Wt("fontPercent")),i=Ci("div",{className:"vjs-edge-style vjs-tracksetting"},void 0,this.Wt("edgeStyle")),s=Ci("div",{className:"vjs-font-family vjs-tracksetting"},void 0,this.Wt("fontFamily"));return Ci("div",{className:"vjs-tracksettings-font"},void 0,[t,i,s])},s.Yt=function(){var t=Ci("button",{className:"vjs-default-button",textContent:this.localize("Defaults")}),i=Ci("button",{className:"vjs-done-button",textContent:"Done"});return Ci("div",{className:"vjs-tracksettings-controls"},void 0,[t,i])},s.createEl=function(){var t=Ci("div",{className:"vjs-tracksettings"},void 0,[this.Qt(),this.Jt(),this.Yt()]),i=Ci("div",{className:"vjs-control-text",id:"TTsettingsDialogLabel-"+this.u,textContent:"Caption Settings Dialog"},{"aria-level":"1",role:"heading"}),s=Ci("div",{className:"vjs-control-text",id:"TTsettingsDialogDescription-"+this.u,textContent:"Beginning of dialog window. Escape will cancel and close the window."}),e=Ci("div",void 0,{role:"document"},[i,s,t]);return Ci("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),li(t).reduce((function(s,e){return i(s,t[e],e)}),s)}(Uh,(function(i,s,e){var n=function(t,i){return Vh(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;fi(Uh,(function(s,e){!function(t,i,s){if(i)for(var e=0;e<t.options.length;e++)if(Vh(t.options[e].value,s)===i){t.selectedIndex=e;break}}(i.$(s.selector),t[e],s.parser)}))},s.setDefaults=function(){var t=this;fi(Uh,(function(i){var s=i.hasOwnProperty("default")?i.default:0;t.$(i.selector).selectedIndex=s}))},s.restoreSettings=function(){var t;try{t=JSON.parse(o.localStorage.getItem(Ph))}catch(t){gi.warn(t)}t&&this.setValues(t)},s.saveSettings=function(){if(this.o.persistTextTrackSettings){var t=this.getValues();try{w.keys(t).length?o.localStorage.setItem(Ph,JSON.stringify(t)):o.localStorage.removeItem(Ph)}catch(t){gi.warn(t)}}},s.updateDisplay=function(){var t=this.h.getChild("textTrackDisplay");t&&t.updateDisplay()},i}(i);i.registerComponent("TextTrackSettings",Hh);var zh,Wh=function(i){function s(t,s){var e;e=i.call(this,t,s)||this;var n=t.source,r=!1;if(n&&(e.m.currentSrc!==n.src||t.tag&&3===t.tag.Kt)?e.setSource(n):e.Zt(e.m),e.m.hasChildNodes()){for(var h=e.m.childNodes,o=h.length,a=[];o--;){var u=h[o];"track"===u.nodeName.toLowerCase()&&(e.featuresNativeTextTracks?(e.remoteTextTrackEls().J(u),e.remoteTextTracks().tt(u.track),r||e.m.hasAttribute("crossorigin")||!de(u.src)||(r=!0)):a.push(u))}for(var c=0;c<a.length;c++)e.m.removeChild(a[c])}return["audio","video"].forEach((function(t){var i=e.el()[t+"Tracks"],s=e[t+"Tracks"](),n=$s(t);e["featuresNative"+n+"Tracks"]&&i&&i.addEventListener&&(e["handle"+n+"ti"]=function(t){s.trigger({type:"change",target:s,currentTarget:s,srcElement:s})},e["handle"+n+"ii"]=function(t){return s.addTrack(t.track)},e["handle"+n+"si"]=function(t){return s.removeTrack(t.track)},i.addEventListener("change",e["handle"+n+"ti"]),i.addEventListener("addtrack",e["handle"+n+"ii"]),i.addEventListener("removetrack",e["handle"+n+"si"]),e["removeOld"+n+"ei"]=function(t){return e.ni(s,i)},e.on("loadstart",e["removeOld"+n+"ei"]))})),e.featuresNativeTextTracks&&(r&&gi.warn(ki(Lh||(Lh=hi(["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=Ns(Rs(e),e.handleTextTrackChange),e.hi=Ns(Rs(e),e.handleTextTrackAdd),e.oi=Ns(Rs(e),e.handleTextTrackRemove),e.ai()),e.ci(),(gs||is||as)&&!0===t.nativeControlsForTouch&&e.setControls(!0),e.fi(),e.triggerReady(),e}Vs(s,i);var e=s.prototype;return e.dispose=function(){var t=this;["audio","video","text"].forEach((function(i){var s=$s(i),e=t.m[i+"Tracks"];e&&e.removeEventListener&&(e.removeEventListener("change",t["handle"+s+"ti"]),e.removeEventListener("addtrack",t["handle"+s+"ii"]),e.removeEventListener("removetrack",t["handle"+s+"si"])),e&&t.off("loadstart",t["removeOld"+s+"ei"])})),s.disposeMediaElement(this.m),i.prototype.dispose.call(this)},e.ci=function(){var t,i=this.textTracks(),s=function(){t=[];for(var s=0;s<i.length;s++){var e=i[s];"metadata"===e.kind&&t.push({track:e,storedMode:e.mode})}};s(),i.addEventListener("change",s);var e=function s(){for(var e=0;e<t.length;e++){var n=t[e];"disabled"===n.track.mode&&n.track.mode!==n.storedMode&&(n.track.mode=n.storedMode)}i.removeEventListener("change",s)};this.on("webkitbeginfullscreen",(function(){i.removeEventListener("change",s),i.removeEventListener("change",e),i.addEventListener("change",e)})),this.on("webkitendfullscreen",(function(){i.removeEventListener("change",s),i.addEventListener("change",s),i.removeEventListener("change",e)}))},e.createEl=function(){var i=this.o.tag;if(!i||!this.o.playerElIngest&&!this.movingMediaElementInDOM){if(i){var e=i.cloneNode(!0);i.parentNode&&i.parentNode.insertBefore(e,i),s.disposeMediaElement(i),i=e}else{i=t.createElement("video");var n=Bs({},this.o.tag&&Ui(this.o.tag));gs&&!0===this.o.nativeControlsForTouch||delete n.controls,Ri(i,di(n,{id:this.o.techId,class:"vjs-tech"}))}i.playerId=this.o.playerId}void 0!==this.o.preload&&Vi(i,"preload",this.o.preload);for(var r=["loop","muted","playsinline","autoplay"],h=r.length-1;h>=0;h--){var o=r[h],a=this.o[o];void 0!==a&&(a?Vi(i,o,o):Li(i,o),i[o]=a)}return i},e.Zt=function(t){if(0!==t.networkState&&3!==t.networkState){if(0===t.readyState){var i=!1,s=function(){i=!0};this.on("loadstart",s);var e=function(){i||this.trigger("loadstart")};return this.on("loadedmetadata",e),void this.ready((function(){this.off("loadstart",s),this.off("loadedmetadata",e),i||this.trigger("loadstart")}))}var n=["loadstart"];n.push("loadedmetadata"),t.readyState>=2&&n.push("loadeddata"),t.readyState>=3&&n.push("canplay"),t.readyState>=4&&n.push("canplaythrough"),this.ready((function(){n.forEach((function(t){this.trigger(t)}),this)}))}},e.ai=function(){var t=this.el().textTracks;if(t){for(var i=0;i<t.length;i++)this.textTracks().tt(t[i]);t.addEventListener&&(t.addEventListener("change",this.ri),t.addEventListener("addtrack",this.hi),t.addEventListener("removetrack",this.oi)),this.on("loadstart",this.di)}},e.handleTextTrackChange=function(t){var i=this.textTracks();this.textTracks().trigger({type:"change",target:i,currentTarget:i,srcElement:i})},e.handleTextTrackAdd=function(t){this.textTracks().tt(t.track)},e.handleTextTrackRemove=function(t){this.textTracks().it(t.track)},e.ni=function(t,i){var s=[];if(i){for(var e=0;e<t.length;e++){for(var n=t[e],r=!1,h=0;h<i.length;h++)if(i[h]===n){r=!0;break}r||s.push(n)}for(var o=0;o<s.length;o++){var a=s[o];t.it(a)}}},e.di=function(t){var i=this.textTracks(),s=this.el().textTracks;this.ni(i,s)},e.play=function(){var t=this.m.play();void 0!==t&&"function"==typeof t.then&&t.then(null,(function(t){}))},e.setCurrentTime=function(t){try{this.m.currentTime=t}catch(t){gi(t,"Video is not ready. (Video.js)")}},e.duration=function(){var t=this;if(this.m.duration===1/0&&rs&&ls&&0===this.m.currentTime){return this.on("timeupdate",(function i(){t.m.currentTime>0&&(t.m.duration===1/0&&t.trigger("durationchange"),t.off("timeupdate",i))})),NaN}return this.m.duration||NaN},e.width=function(){return this.m.offsetWidth},e.height=function(){return this.m.offsetHeight},e.fi=function(){var t=this;if("webkitDisplayingFullscreen"in this.m){var i=function(){this.trigger("fullscreenchange",{isFullscreen:!1})},s=function(){"webkitPresentationMode"in this.m&&"picture-in-picture"!==this.m.webkitPresentationMode&&(this.one("webkitendfullscreen",i),this.trigger("fullscreenchange",{isFullscreen:!0,nativeIOSFullscreen:!0}))};this.on("webkitbeginfullscreen",s),this.on("dispose",(function(){t.off("webkitbeginfullscreen",s),t.off("webkitendfullscreen",i)}))}},e.supportsFullScreen=function(){if("function"==typeof this.m.webkitEnterFullScreen){var t=o.navigator&&o.navigator.userAgent||"";if(/Android/.test(t)||!/Chrome|Mac OS X 10.5/.test(t))return!0}return!1},e.enterFullScreen=function(){var t=this.m;t.paused&&t.networkState<=t.HAVE_METADATA?(this.m.play(),this.setTimeout((function(){t.pause(),t.webkitEnterFullScreen()}),0)):t.webkitEnterFullScreen()},e.exitFullScreen=function(){this.m.webkitExitFullScreen()},e.src=function(t){if(void 0===t)return this.m.src;this.setSrc(t)},e.reset=function(){s.resetMediaElement(this.m)},e.currentSrc=function(){return this.bt?this.bt.src:this.m.currentSrc},e.setControls=function(t){this.m.controls=!!t},e.addTextTrack=function(t,s,e){return this.featuresNativeTextTracks?this.m.addTextTrack(t,s,e):i.prototype.addTextTrack.call(this,t,s,e)},e.createRemoteTextTrack=function(s){if(!this.featuresNativeTextTracks)return i.prototype.createRemoteTextTrack.call(this,s);var e=t.createElement("track");return s.kind&&(e.kind=s.kind),s.label&&(e.label=s.label),(s.language||s.srclang)&&(e.srclang=s.language||s.srclang),s.default&&(e.default=s.default),s.id&&(e.id=s.id),s.src&&(e.src=s.src),e},e.addRemoteTextTrack=function(t,s){var e=i.prototype.addRemoteTextTrack.call(this,t,s);return this.featuresNativeTextTracks&&this.el().appendChild(e),e},e.removeRemoteTextTrack=function(t){if(i.prototype.removeRemoteTextTrack.call(this,t),this.featuresNativeTextTracks)for(var s=this.$$("track"),e=s.length;e--;)t!==s[e]&&t!==s[e].track||this.el().removeChild(s[e])},e.getVideoPlaybackQuality=function(){if("function"==typeof this.el().getVideoPlaybackQuality)return this.el().getVideoPlaybackQuality();var t={};return void 0!==this.el().webkitDroppedFrameCount&&void 0!==this.el().webkitDecodedFrameCount&&(t.droppedVideoFrames=this.el().webkitDroppedFrameCount,t.totalVideoFrames=this.el().webkitDecodedFrameCount),o.performance&&"function"==typeof o.performance.now?t.creationTime=o.performance.now():o.performance&&o.performance.timing&&"number"==typeof o.performance.timing.navigationStart&&(t.creationTime=o.Date.now()-o.performance.timing.navigationStart),t},s}(xr);_i()&&(Wh.TEST_VID=t.createElement("video"),(zh=t.createElement("track")).kind="captions",zh.srclang="en",zh.label="English",Wh.TEST_VID.appendChild(zh)),Wh.isSupported=function(){try{Wh.TEST_VID.volume=.5}catch(t){return!1}return!(!Wh.TEST_VID||!Wh.TEST_VID.canPlayType)},Wh.canControlVolume=function(){try{var t=Wh.TEST_VID.volume;return Wh.TEST_VID.volume=t/2+.1,t!==Wh.TEST_VID.volume}catch(t){return!1}},Wh.canControlPlaybackRate=function(){if(rs&&ls&&fs<58)return!1;try{var t=Wh.TEST_VID.playbackRate;return Wh.TEST_VID.playbackRate=t/2+.1,t!==Wh.TEST_VID.playbackRate}catch(t){return!1}},Wh.supportsNativeTextTracks=function(){return ms},Wh.supportsNativeVideoTracks=function(){return!(!Wh.TEST_VID||!Wh.TEST_VID.videoTracks)},Wh.supportsNativeAudioTracks=function(){return!(!Wh.TEST_VID||!Wh.TEST_VID.audioTracks)},Wh.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange"],Wh.prototype.featuresVolumeControl=Wh.canControlVolume(),Wh.prototype.featuresPlaybackRate=Wh.canControlPlaybackRate(),Wh.prototype.movingMediaElementInDOM=!es,Wh.prototype.featuresFullscreenResize=!0,Wh.prototype.featuresProgressEvents=!0,Wh.prototype.featuresTimeupdateEvents=!0,Wh.prototype.featuresNativeTextTracks=Wh.supportsNativeTextTracks(),Wh.prototype.featuresNativeVideoTracks=Wh.supportsNativeVideoTracks(),Wh.prototype.featuresNativeAudioTracks=Wh.supportsNativeAudioTracks();var qh=Wh.TEST_VID&&Wh.TEST_VID.constructor.prototype.canPlayType,Gh=/^application\/(?:x-|vnd\.apple\.)mpegurl/i,Xh=/^video\/mp4/i;Wh.patchCanPlayType=function(){hs>=4&&!us?Wh.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&Gh.test(t)?"maybe":qh.call(this,t)}:os&&(Wh.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&Xh.test(t)?"maybe":qh.call(this,t)})},Wh.unpatchCanPlayType=function(){var t=Wh.TEST_VID.constructor.prototype.canPlayType;return Wh.TEST_VID.constructor.prototype.canPlayType=qh,t},Wh.patchCanPlayType(),Wh.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){}}()}}},Wh.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){Wh.prototype[t]=function(){return this.m[t]||this.m.hasAttribute(t)}})),["muted","defaultMuted","autoplay","loop","playsinline"].forEach((function(t){Wh.prototype["set"+$s(t)]=function(i){this.m[t]=i,i?this.m.setAttribute(t,t):this.m.removeAttribute(t)}})),["paused","currentTime","buffered","volume","poster","preload","error","seeking","seekable","ended","playbackRate","played","networkState","readyState","videoWidth","videoHeight"].forEach((function(t){Wh.prototype[t]=function(){return this.m[t]}})),["volume","src","poster","preload","playbackRate"].forEach((function(t){Wh.prototype["set"+$s(t)]=function(i){this.m[t]=i}})),["pause","load"].forEach((function(t){Wh.prototype[t]=function(){return this.m[t]()}})),xr.withSourceHandlers(Wh),Wh.nativeSourceHandler={},Wh.nativeSourceHandler.canPlayType=function(t){try{return Wh.TEST_VID.canPlayType(t)}catch(t){return""}},Wh.nativeSourceHandler.canHandleSource=function(t,i){if(t.type)return Wh.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 Wh.nativeSourceHandler.canPlayType("video/"+s)}return""},Wh.nativeSourceHandler.handleSource=function(t,i,s){i.setSrc(t.src)},Wh.nativeSourceHandler.dispose=function(){},Wh.registerSourceHandler(Wh.nativeSourceHandler),i.registerComponent("Html5",Wh),xr.registerTech("Html5",Wh);var Qh=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","ratechange","volumechange","texttrackchange"],Jh=function(s){function e(t,i,n){var r;if(t.id=t.id||["vjs_video",ai()].join("_"),(i=di(e.getTagSettings(t),i)).initChildren=!1,i.createEl=!1,i.reportTouchActivity=!1,!i.language)if("function"==typeof t.closest){var h=t.closest("[lang]");h&&(i.language=h.getAttribute("lang"))}else for(var o=t;o&&1===o.nodeType;){if(Ui(o).hasOwnProperty("lang")){i.language=o.getAttribute("lang");break}o=o.parentNode}if(!(r=s.call(this,null,i,n)||this).o||!r.o.techOrder||!r.o.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=t,r.tagAttributes=t&&Ui(t),r.language(r.o.language),i.languages){var a={};w.getOwnPropertyNames(i.languages).forEach((function(t){a[t.toLowerCase()]=i.languages[t]})),r.vi=a}else r.vi=e.prototype.o.languages;r.pi={},r.mi=i.poster||"",r.gi=!!i.controls,t.controls=!1,r.yi=!1,r.m=r.createEl();var u=Bs(r.o);if(i.plugins){var c=i.plugins;w.getOwnPropertyNames(c).forEach((function(t){"function"==typeof this[t]?this[t](c[t]):gi.error("Unable to find plugin:",t)}),Rs(r))}r.o.playerOptions=u,r.initChildren(),r.isAudio("audio"===t.nodeName.toLowerCase()),r.controls()?r.addClass("vjs-controls-enabled"):r.addClass("vjs-controls-disabled"),r.m.setAttribute("role","region"),r.isAudio()?r.m.setAttribute("aria-label","audio player"):r.m.setAttribute("aria-label","video player"),r.isAudio()&&r.addClass("vjs-audio"),r.bi()&&r.addClass("vjs-no-flex"),es||r.addClass("vjs-workinghover"),e.players[r.u]=Rs(r);var l="5.20.6-opentelly.12".split(".")[0];return r.addClass("vjs-v"+l),r.userActive(!0),r.reportUserActivity(),r.wi(),r.on("fullscreenchange",r.ki),r.on("stageclick",r.ji),r}Vs(e,s);var n=e.prototype;return n.dispose=function(){this.trigger("dispose"),this.off("dispose"),this.Si&&this.Si.parentNode&&this.Si.parentNode.removeChild(this.Si),e.players[this.u]=null,this.tag&&this.tag.player&&(this.tag.player=null),this.m&&this.m.player&&(this.m.player=null),this.H&&this.H.dispose(),s.prototype.dispose.call(this)},n.createEl=function(){var t,i=this.tag,e=this._i=i.parentNode&&i.parentNode.hasAttribute&&i.parentNode.hasAttribute("data-vjs-player");t=this.m=e?i.parentNode:s.prototype.createEl.call(this,"div"),i.setAttribute("tabindex","-1"),i.removeAttribute("width"),i.removeAttribute("height");var n=Ui(i);if(w.getOwnPropertyNames(n).forEach((function(i){"class"===i?t.className+=" "+n[i]:t.setAttribute(i,n[i])})),i.playerId=i.id,i.id+="xi",i.className="vjs-tech",i.player=t.player=this,this.addClass("vjs-paused"),!0!==o.VIDEOJS_NO_DYNAMIC_STYLE){this.Si=Ds("vjs-styles-dimensions");var r=Qi(".vjs-styles-defaults"),h=Qi("head");h.insertBefore(this.Si,r?r.nextSibling:h.firstChild)}this.width(this.o.width),this.height(this.o.height),this.fluid(this.o.fluid),this.aspectRatio(this.o.aspectRatio);for(var a=i.getElementsByTagName("a"),u=0;u<a.length;u++){var c=a.item(u);$i(c,"vjs-hidden"),c.setAttribute("hidden","hidden")}return i.Kt=i.networkState,i.parentNode&&!e&&i.parentNode.insertBefore(t,i),Ai(i,t),this.g.unshift(i),this.m=t,t},n.width=function(t){return this.dimension("width",t)},n.height=function(t){return this.dimension("height",t)},n.dimension=function(t,i){var s="width"===t?"Ti":"Ci";if(void 0===i)return this[s]||0;if(""===i)this[s]=void 0;else{var e=S(i);if(_(e))return gi.error('Improper value "'+i+'" supplied for for '+t),this;this[s]=e}return this.Pi(),this},n.fluid=function(t){if(void 0===t)return!!this.Ai;this.Ai=!!t,t?this.addClass("vjs-fluid"):this.removeClass("vjs-fluid"),this.Pi()},n.aspectRatio=function(t){if(void 0===t)return this.Mi;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.Mi=t,this.fluid(!0),this.Pi()},n.Pi=function(){if(!0!==o.VIDEOJS_NO_DYNAMIC_STYLE){var t,i,s,e=(void 0!==this.Mi&&"auto"!==this.Mi?this.Mi:this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9").split(":"),n=e[1]/e[0];t=void 0!==this.Ti?this.Ti:void 0!==this.Ci?this.Ci/n:this.videoWidth()||300,i=void 0!==this.Ci?this.Ci:t*n,s=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(s),Fs(this.Si,"\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.o.width,h="number"==typeof this.Ci?this.Ci:this.o.height,a=this.H&&this.H.el();a&&(r>=0&&(a.width=r),h>=0&&(a.height=h))}},n.jt=function(t,s){var e=this;this.H&&this.Ii(),"Html5"!==t&&this.tag&&(xr.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.Ei=t,this.T=!1;var n=di({source:s,nativeControlsForTouch:this.o.nativeControlsForTouch,playerId:this.id(),techId:this.id()+"_"+t+"Di",videoTracks:this.rt,textTracks:this.nt,audioTracks:this.ht,autoplay:this.o.autoplay,playsinline:this.o.playsinline,preload:this.o.preload,loop:this.o.loop,muted:this.o.muted,poster:this.poster(),language:this.language(),playerElIngest:this._i||!1,"vtt.js":this.o["vtt.js"]},this.o[t.toLowerCase()]);this.tag&&(n.tag=this.tag),s&&(this.Fi=s.type,s.src===this.pi.src&&this.pi.currentTime>0&&(n.startTime=this.pi.currentTime),this.pi.sources=null,this.pi.source=s,this.pi.src=s.src);var r=xr.getTech(t);r||(r=i.getComponent(t)),this.H=new r(n),this.H.ready(Ns(this,this.Ni),!0),ee(this.$i||[],this.H),Qh.forEach((function(t){e.on(e.H,t,e["handleTech"+$s(t)+"_"])})),this.on(this.H,"loadstart",this.Bi),this.on(this.H,"waiting",this.Oi),this.on(this.H,"canplay",this.Ri),this.on(this.H,"canplaythrough",this.Ui),this.on(this.H,"playing",this.Vi),this.on(this.H,"ended",this.Li),this.on(this.H,"seeking",this.Hi),this.on(this.H,"seeked",this.zi),this.on(this.H,"play",this.Wi),this.on(this.H,"firstplay",this.qi),this.on(this.H,"pause",this.Gi),this.on(this.H,"durationchange",this.Xi),this.on(this.H,"fullscreenchange",this.Qi),this.on(this.H,"error",this.Ji),this.on(this.H,"loadedmetadata",this.Pi),this.on(this.H,"resize",this.Pi),this.on(this.H,"posterchange",this.Yi),this.on(this.H,"textdata",this.Ki),this.usingNativeControls(this.Zi("controls")),this.controls()&&!this.usingNativeControls()&&this.ts(),this.H.el().parentNode===this.contentEl()||"Html5"===t&&this.tag||Ai(this.H.el(),this.contentEl()),this.tag&&(this.tag.player=null,this.tag=null)},n.Ii=function(){this.rt=this.videoTracks(),this.nt=this.textTracks(),this.ht=this.audioTracks(),this.$i=se(this.H),this.T=!1,this.H.dispose(),this.H=!1},n.tech=function(t){if(t&&t.IWillNotUseThisInPlugins)return this.H;var i="\n Please make sure that you are not using this inside of a plugin.\n To disable this alert and error, please pass in an object with\n `IWillNotUseThisInPlugins` to the `tech` method. See\n https://github.com/videojs/video.js/issues/2617 for more info.\n ";throw o.alert(i),new m(i)},n.ts=function(){this.ss(),this.on(this.H,"mousedown",this.es),this.on(this.H,"touchstart",this.ns),this.on(this.H,"touchmove",this.rs),this.on(this.H,"touchend",this.hs),this.on(this.H,"tap",this.os)},n.ss=function(){this.off(this.H,"tap",this.os),this.off(this.H,"touchstart",this.ns),this.off(this.H,"touchmove",this.rs),this.off(this.H,"touchend",this.hs),this.off(this.H,"mousedown",this.es)},n.Ni=function(){if(this.triggerReady(),this.pi.volume&&this.us("setVolume",this.pi.volume),this.Yi(),this.Xi(),(this.src()||this.currentSrc())&&this.tag&&this.o.autoplay&&this.paused()){try{delete this.tag.poster}catch(t){gi("deleting tag.poster throws in some browsers",t)}this.play()}},n.Bi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-seeking"),this.error(null),this.paused()?(this.hasStarted(!1),this.trigger("loadstart")):(this.trigger("loadstart"),this.trigger("firstplay"))},n.hasStarted=function(t){return void 0!==t?(this.et!==t&&(this.et=t,t?(this.addClass("vjs-has-started"),this.trigger("firstplay")):this.removeClass("vjs-has-started")),this):!!this.et},n.Wi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},n.Oi=function(){var t=this;this.addClass("vjs-waiting"),this.trigger("waiting"),this.one("timeupdate",(function(){return t.removeClass("vjs-waiting")}))},n.Ri=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},n.Ui=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},n.Vi=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},n.Hi=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},n.zi=function(){this.removeClass("vjs-seeking"),this.trigger("seeked")},n.qi=function(){this.o.starttime&&(gi.warn("Passing the `starttime` option to the player will be deprecated in 6.0"),this.currentTime(this.o.starttime)),this.addClass("vjs-has-started"),this.trigger("firstplay")},n.Gi=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},n.Li=function(){this.addClass("vjs-ended"),this.o.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},n.Xi=function(){this.duration(this.Zi("duration"))},n.es=function(t){0===t.button&&this.controls()&&(void 0!==this.o&&void 0!==this.o.userActions&&void 0!==this.o.userActions.click&&!1===this.o.userActions.click||(void 0!==this.o&&void 0!==this.o.userActions&&"function"==typeof this.o.userActions.click?this.o.userActions.click.call(this,t):this.paused()?this.play():this.pause()))},n.os=function(){this.userActive(!this.userActive())},n.ns=function(){this.userWasActive=this.userActive()},n.rs=function(){this.userWasActive&&this.reportUserActivity()},n.hs=function(t){t.cancelable&&t.preventDefault()},n.ki=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},n.ji=function(){this.reportUserActivity()},n.Qi=function(t,i){i&&(this.toggleClass("vjs-ios-native-fs",!(!i.nativeIOSFullscreen||!i.isFullscreen)),this.isFullscreen(i.isFullscreen)),this.trigger("fullscreenchange")},n.Ji=function(){var t=this.H.error();this.error(t)},n.Ki=function(){var t=null;arguments.length>1&&(t=arguments[1]),this.trigger("textdata",t)},n.getCache=function(){return this.pi},n.us=function(t,i){if(this.H&&!this.H.T)this.H.ready((function(){this[t](i)}),!0);else try{this.H&&this.H[t](i)}catch(t){throw gi(t),t}},n.Zi=function(t){if(this.H&&this.H.T)try{return this.H[t]()}catch(i){throw void 0===this.H[t]?gi("Video.js: "+t+" method not defined for "+this.Ei+" playback technology.",i):"TypeError"===i.name?(gi("Video.js: "+t+" unavailable on "+this.Ei+" playback technology element.",i),this.H.T=!1):gi(i),i}},n.play=function(){return this.src()||this.currentSrc()?this.us("play"):this.H.one("loadstart",(function(){this.play()})),this},n.pause=function(){return this.us("pause"),this},n.paused=function(){return!1!==this.Zi("paused")},n.scrubbing=function(t){return void 0!==t?(this.yi=!!t,t?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing"),this):this.yi},n.currentTime=function(t){return void 0!==t?(this.us("setCurrentTime",t),this):(this.pi.currentTime=this.Zi("currentTime")||0,this.pi.currentTime)},n.duration=function(t){return void 0===t?void 0!==this.pi.duration?this.pi.duration:NaN:((t=S(t))<0&&(t=1/0),t!==this.pi.duration&&(this.pi.duration=t,t===1/0?this.addClass("vjs-live"):this.removeClass("vjs-live"),this.trigger("durationchange")),this)},n.remainingTime=function(){return this.duration()-this.currentTime()},n.buffered=function(){var t=this.Zi("buffered");return t&&t.length||(t=zs(0,0)),t},n.bufferedPercent=function(){return Ws(this.buffered(),this.duration())},n.bufferedEnd=function(){var t=this.buffered(),i=this.duration(),s=t.end(t.length-1);return s>i&&(s=i),s},n.volume=function(t){var i;return void 0!==t?(i=k.max(0,k.min(1,S(t))),this.pi.volume=i,this.us("setVolume",i),this):(i=S(this.Zi("volume")),_(i)?1:i)},n.muted=function(t){return void 0!==t?(this.us("setMuted",t),this):this.Zi("muted")||!1},n.supportsFullScreen=function(){return this.Zi("supportsFullScreen")||!1},n.isFullscreen=function(t){return void 0!==t?(this.cs=!!t,this):!!this.cs},n.requestFullscreen=function(i){var s,e=Js;return this.isFullscreen(!0),e.requestFullscreen?(xs(t,e.fullscreenchange,Ns(this,(function i(s){this.isFullscreen(t[e.fullscreenElement]),!1===this.isFullscreen()&&Ts(t,e.fullscreenchange,i),this.trigger("fullscreenchange")}))),e.prefixed||(s=this.o.fullscreenOptions,void 0!==i&&(s=i)),this.m[e.requestFullscreen](s)):this.H.supportsFullScreen()?this.us("enterFullScreen"):(this.enterFullWindow(),this.trigger("fullscreenchange")),this},n.exitFullscreen=function(){var i=Js;return this.isFullscreen(!1),i.requestFullscreen?t[i.exitFullscreen]():this.H.supportsFullScreen()?this.us("exitFullScreen"):(this.exitFullWindow(),this.trigger("fullscreenchange")),this},n.enterFullWindow=function(){this.isFullWindow=!0,this.docOrigOverflow=t.documentElement.style.overflow,xs(t,"keydown",Ns(this,this.fullWindowOnEscKey)),t.documentElement.style.overflow="hidden",$i(t.body,"vjs-full-window"),this.trigger("enterFullWindow")},n.fullWindowOnEscKey=function(t){27===t.keyCode&&(!0===this.isFullscreen()?this.exitFullscreen():this.exitFullWindow())},n.exitFullWindow=function(){this.isFullWindow=!1,Ts(t,"keydown",this.fullWindowOnEscKey),t.documentElement.style.overflow=this.docOrigOverflow,Bi(t.body,"vjs-full-window"),this.trigger("exitFullWindow")},n.canPlayType=function(t){for(var s,e=0,n=this.o.techOrder;e<n.length;e++){var r=$s(n[e]),h=xr.getTech(r);if(h||(h=i.getComponent(r)),h){if(h.isSupported()&&(s=h.canPlayType(t)))return s}else gi.error('The "'+r+'" tech is undefined. Skipped browser support check for that tech.')}return""},n.selectSource=function(t){var s,e=this,n=this.o.techOrder.map($s).map((function(t){return[t,xr.getTech(t)||i.getComponent(t)]})).filter((function(t){var i=t[0],s=t[1];return s?s.isSupported():(gi.error('The "'+i+'" tech is undefined. Skipped browser support check for that tech.'),!1)})),r=function(t,i,s){var e;return t.some((function(t){return i.some((function(i){if(e=s(t,i))return!0}))})),e},h=function(t,i){var s=t[0];if(t[1].canPlaySource(i,e.o[s.toLowerCase()]))return{source:i,tech:s}};return(this.o.sourceOrder?r(t,n,(s=h,function(t,i){return s(i,t)})):r(n,t,h))||!1},n.src=function(t){if(void 0===t)return this.Zi("src");var s=xr.getTech(this.Ei);return s||(s=i.getComponent(this.Ei)),Array.isArray(t)?this.ls(t):"string"==typeof t?this.src({src:t}):t instanceof w&&(t.type&&!s.canPlaySource(t,this.o[this.Ei.toLowerCase()])?this.ls([t]):(this.pi.sources=null,this.pi.source=t,this.pi.src=t.src,this.Fi=t.type||"",this.ready((function(){s.prototype.hasOwnProperty("setSource")?this.us("setSource",t):this.us("src",t.src),"auto"===this.o.preload&&this.load(),this.o.autoplay&&this.play()}),!0))),this},n.ls=function(t){var i=this.selectSource(t);i?(i.tech===this.Ei?this.src(i.source):this.jt(i.tech,i.source),this.pi.sources=t):(this.setTimeout((function(){this.error({code:4,message:this.localize(this.o.notSupportedMessage)})}),0),this.triggerReady())},n.load=function(){return this.us("load"),this},n.reset=function(){return this.jt($s(this.o.techOrder[0]),null),this.us("reset"),this},n.currentSources=function(){var t=this.currentSource(),i=[];return 0!==w.keys(t).length&&i.push(t),this.pi.sources||i},n.currentSource=function(){var t={},i=this.currentSrc();return i&&(t.src=i),this.pi.source||t},n.currentSrc=function(){return this.Zi("currentSrc")||this.pi.src||""},n.currentType=function(){return this.Fi||""},n.preload=function(t){return void 0!==t?(this.us("setPreload",t),this.o.preload=t,this):this.Zi("preload")},n.autoplay=function(t){return void 0!==t?(this.us("setAutoplay",t),this.o.autoplay=t,this):this.Zi("autoplay",t)},n.playsinline=function(t){return void 0!==t?(this.us("setPlaysinline",t),this.o.playsinline=t,this):this.Zi("playsinline")},n.loop=function(t){return void 0!==t?(this.us("setLoop",t),this.o.loop=t,this):this.Zi("loop")},n.poster=function(t){return void 0===t?this.mi:(t||(t=""),this.mi=t,this.us("setPoster",t),this.trigger("posterchange"),this)},n.Yi=function(){!this.mi&&this.H&&this.H.poster&&(this.mi=this.H.poster()||"",this.trigger("posterchange"))},n.controls=function(t){return void 0!==t?(t=!!t,this.gi!==t&&(this.gi=t,this.usingNativeControls()&&this.us("setControls",t),t?(this.removeClass("vjs-controls-disabled"),this.addClass("vjs-controls-enabled"),this.trigger("controlsenabled"),this.usingNativeControls()||this.ts()):(this.removeClass("vjs-controls-enabled"),this.addClass("vjs-controls-disabled"),this.trigger("controlsdisabled"),this.usingNativeControls()||this.ss())),this):!!this.gi},n.usingNativeControls=function(t){return void 0!==t?(t=!!t,this.fs!==t&&(this.fs=t,t?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols"))),this):!!this.fs},n.error=function(t){return void 0===t?this.lt||null:null===t?(this.lt=t,this.removeClass("vjs-error"),this.errorDisplay&&this.errorDisplay.close(),this):(this.lt=new Zs(t),this.addClass("vjs-error"),gi.error("(CODE:"+this.lt.code+" "+Zs.errorTypes[this.lt.code]+")",this.lt.message,this.lt),this.trigger("error"),this)},n.reportUserActivity=function(t){this.ds=!0},n.userActive=function(t){return void 0!==t?((t=!!t)!==this.vs&&(this.vs=t,t?(this.ds=!0,this.removeClass("vjs-user-inactive"),this.addClass("vjs-user-active"),this.trigger("useractive")):(this.ds=!1,this.H&&this.H.one("mousemove",(function(t){t.stopPropagation(),t.preventDefault()})),this.removeClass("vjs-user-active"),this.addClass("vjs-user-inactive"),this.trigger("userinactive"))),this):this.vs},n.wi=function(){var t,i,s,e,n=Ns(this,this.reportUserActivity);this.on("mousedown",(function(){n(),this.clearInterval(t),t=this.setInterval(n,250)})),this.on("mousemove",(function(t){t.screenX===i&&t.screenY===s||(i=t.screenX,s=t.screenY,n())})),this.on("mouseup",(function(i){n(),this.clearInterval(t)})),this.on("keydown",n),this.on("keyup",n),this.setInterval((function(){if(this.ds){this.ds=!1,this.userActive(!0),this.clearTimeout(e);var t=this.o.inactivityTimeout;t>0&&(e=this.setTimeout((function(){this.ds||this.userActive(!1)}),t))}}),250)},n.playbackRate=function(t){return void 0!==t?(this.us("setPlaybackRate",t),this):this.H&&this.H.featuresPlaybackRate?this.Zi("playbackRate"):1},n.isAudio=function(t){return void 0!==t?(this.ps=!!t,this):!!this.ps},n.videoTracks=function(){return this.H?this.H.videoTracks():(this.rt=this.rt||new jr,this.rt)},n.audioTracks=function(){return this.H?this.H.audioTracks():(this.ht=this.ht||new _r,this.ht)},n.textTracks=function(){if(this.H)return this.H.textTracks()},n.remoteTextTracks=function(){if(this.H)return this.H.remoteTextTracks()},n.remoteTextTrackEls=function(){if(this.H)return this.H.remoteTextTrackEls()},n.addTextTrack=function(t,i,s){if(this.H)return this.H.addTextTrack(t,i,s)},n.addRemoteTextTrack=function(t,i){if(this.H)return this.H.addRemoteTextTrack(t,i)},n.removeRemoteTextTrack=function(t){var i=void 0===t?{}:t,s=i.track,e=void 0===s?arguments[0]:s;if(this.H)return this.H.removeRemoteTextTrack(e)},n.getVideoPlaybackQuality=function(){return this.Zi("getVideoPlaybackQuality")},n.videoWidth=function(){return this.H&&this.H.videoWidth&&this.H.videoWidth()||0},n.videoHeight=function(){return this.H&&this.H.videoHeight&&this.H.videoHeight()||0},n.language=function(t){return void 0===t?this.gs:(this.gs!==String(t).toLowerCase()&&(this.gs=String(t).toLowerCase(),void 0!==this.m&&this.trigger("languagechange")),this)},n.languages=function(){return Bs(e.prototype.o.languages,this.vi)},n.toJSON=function(){var t=Bs(this.o),i=t.tracks;t.tracks=[];for(var s=0;s<i.length;s++){var e=i[s];(e=Bs(e)).player=void 0,t.tracks[s]=e}return t},n.createModal=function(t,i){var s=this;(i=i||{}).content=t||"";var e=new re(this,i);return this.addChild(e),e.on("dispose",(function(){s.removeChild(e)})),e.open()},e.getTagSettings=function(t){var i={sources:[],tracks:[]},s=Ui(t),e=s["data-setup"];if(Ni(t,"vjs-fluid")&&(s.fluid=!0),null!==e){var n=te(e||"{}"),r=n[0],h=n[1];r&&gi.error(r),di(s,h)}if(di(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(Ui(c)):"track"===l&&i.tracks.push(Ui(c))}return i},n.bi=function(){var i=t.createElement("i");return!("flexBasis"in i.style||"webkitFlexBasis"in i.style||"mozFlexBasis"in i.style||"msFlexBasis"in i.style||"msFlexOrder"in i.style)},e}(i);Jh.players={};var Yh=o.navigator;Jh.prototype.o={techOrder:["html5","flash"],html5:{},flash:{},defaultVolume:0,inactivityTimeout:2e3,playbackRates:[],children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","controlBar","errorDisplay","textTrackSettings"],language:Yh&&(Yh.languages&&Yh.languages[0]||Yh.userLanguage||Yh.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",fullscreenOptions:{navigationUI:"hide"}},["ended","seeking","seekable","networkState","readyState"].forEach((function(t){Jh.prototype[t]=function(){return this.Zi(t)}})),Qh.forEach((function(t){Jh.prototype["handleTech"+$s(t)+"_"]=function(){return this.trigger(t)}})),i.registerComponent("Player",Jh);var Kh,Zh,to=function(t){function i(s){var e;void 0===s&&(s={});var n=Bs(s,{kind:ae[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(ds)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.q=!0,r||Rs(e)}return Vs(i,t),i}(le),io=function(t){function i(s){var e;void 0===s&&(s={});var n=Bs(s,{kind:oe[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(ds)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||Rs(e)}return Vs(i,t),i}(le);function so(s,e,n){var r;if("string"==typeof s){if(0===s.indexOf("#")&&(s=s.slice(1)),so.getPlayers()[s])return e&&gi.warn('Player "'+s+'" is already initialised. Options will not be applied.'),n&&so.getPlayers()[s].ready(n),so.getPlayers()[s];r=function(i){return 0===i.indexOf("#")&&(i=i.slice(1)),t.getElementById(i)}(s)}else r=s;if(!r||!r.nodeName)throw new g("The element or ID supplied is not valid. (videojs)");if(r.player||Jh.players[r.playerId])return r.player||Jh.players[r.playerId];e=e||{},so.hooks("beforesetup").forEach((function(t){var i=t(r,Bs(e));vi(i)&&!Array.isArray(i)?e=Bs(e,i):gi.error("please return an object in beforesetup hooks")}));var h=new(i.getComponent("Player"))(r,e,n);return so.hooks("setup").forEach((function(t){return t(h)})),h}"undefined"==typeof HTMLVideoElement&&_i()&&(t.createElement("video"),t.createElement("audio"),t.createElement("track")),so.ys={},so.hooks=function(t,i){return so.ys[t]=so.ys[t]||[],i&&(so.ys[t]=so.ys[t].concat(i)),so.ys[t]},so.hook=function(t,i){so.hooks(t,i)},so.removeHook=function(t,i){var s=so.hooks(t).indexOf(i);return!(s<=-1)&&(so.ys[t]=so.ys[t].slice(),so.ys[t].splice(s,1),!0)},!0!==o.VIDEOJS_NO_DYNAMIC_STYLE&&_i()&&((Kh=Qi(".vjs-styles-defaults"))||(Kh=Ds("vjs-styles-defaults"),(Zh=Qi("head"))&&Zh.insertBefore(Kh,Zh.firstChild),Fs(Kh,"\n .video-js {\n width: 300px;\n height: 150px;\n }\n\n .vjs-fluid {\n padding-top: 56.25%\n }\n "))),Es(1,so),so.VERSION="5.20.6-opentelly.12",so.options=Jh.prototype.o,so.getPlayers=function(){return Jh.players},so.players=Jh.players,so.getComponent=i.getComponent,so.registerComponent=function(t,s){xr.isTech(s)&&gi.warn("The "+t+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),i.registerComponent.call(i,t,s)},so.getTech=xr.getTech,so.registerTech=xr.registerTech,so.browser=bs,so.TOUCH_ENABLED=gs,so.extend=function(t,i){void 0===i&&(i={});var s=function(){t.apply(this,arguments)},e={};for(var n in vi(i)?("function"==typeof i.init&&(gi.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.bs=i)}(s,t),e)e.hasOwnProperty(n)&&(s.prototype[n]=e[n]);return s},so.mergeOptions=Bs,so.bind=Ns,so.plugin=function(t,i){Jh.prototype[t]=i},so.addLanguage=function(t,i){var s;return t=(""+t).toLowerCase(),so.options.languages=Bs(so.options.languages,((s={})[t]=i,s)),so.options.languages[t]},so.log=gi,so.createTimeRange=so.createTimeRanges=zs,so.formatTime=Rr,so.parseUrl=fe,so.isCrossOrigin=de,so.EventTarget=Os,so.on=xs,so.one=Ps,so.off=Ts,so.trigger=Cs,so.xhr=cr,so.TextTrack=pr,so.AudioTrack=to,so.VideoTrack=io,so.isEl=xi,so.isTextNode=Wi,so.createEl=Ci,so.hasClass=Ni,so.addClass=$i,so.removeClass=Bi,so.toggleClass=Oi,so.setAttributes=Ri,so.getAttributes=Ui,so.emptyEl=qi,so.appendContent=Gi,so.insertContent=Xi,so.computedStyle=qr;function eo(t){return t.duration()===1/0}function no(t){return t.scrubbing()?t.getCache().currentTime:t.currentTime()}function ro(t){let i=ao(t);return eo(t)?i.end(i.length-1):i.start(0)}function ho(t){return ao(t).start(0)}function oo(t){let i=ao(t);return i.end(i.length-1)-i.start(0)}function ao(t){let i=t.seekable();if(i&&i.length)return i;let s=t.duration();return s=isFinite(s)?s:0,new K([0,s]).ws()}function uo(t,i){void 0===i&&(i=t);let s=t<0?"-":"";t=k.abs(t);let e=k.floor(t%60),n=k.floor(t/60%60),r=k.floor(t/3600);const h=k.floor(i/60%60),o=k.floor(i/3600);return(_(t)||t===1/0)&&(r=n=e="-"),r=r>0||o>0?r+":":"",n=((r||h>=10)&&n<10?"0"+n:n)+":",e=e<10?"0"+e:e,s+r+n+e}function co(){let t=this,i=no(t);t.toggleClass("theo-at-live",function(t,i){if(eo(t)){let s=ao(t);return s.end(s.length-1)-i<10}return!1}(t,i)),t.toggleClass("theo-dvr",function(t){return eo(t)&&oo(t)>=60}(t))}function lo(t,i,s){t.toggleClass("theo-ad-playing",i),t.toggleClass("theo-dai-ad-playing",i&&s)}function fo(){this.userActive(!1)}var vo,po;!function(t){t.ks="unavailable",t.js="available",t.Ss="presenting"}(vo||(vo={})),function(t){t.LOADED="DAILoaded",t.AD_BREAK_STARTED="DAIAdBreakStarted",t.AD_BREAK_ENDED="DAIAdBreakEnded",t.AD_PERIOD_STARTED="DAIAdPeriodStarted",t.AD_PERIOD_ENDED="DAIAdPeriodEnded",t.AD_PROGRESS="DAIAdProgress",t.CUEPOINTS_CHANGED="DAICuePointsChanged",t.CLICK="DAIClick",t.ERROR="DAIError",t.STARTED="DAIStarted",t.FIRST_QUARTILE="DAIFirstQuartile",t.MIDPOINT="DAIMidpoint",t.STREAM_INITIALIZED="DAIStreamInitialized",t.THIRD_QUARTILE="DAIThirdQuartile",t.COMPLETE="DAIComplete"}(po||(po={}));var mo=["loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange","resize"],go=so.getTech("Tech"),yo=so.getTech("Html5"),bo=class extends go{_s(){var t;for(const t of mo)this.xs.addEventListener(t,this.Ts);this.xs.addEventListener("error",this.Cs),this.xs.addEventListener("contentprotectionerror",this.Cs),this.xs.addEventListener("sourcechange",this.Ps),this.xs.addEventListener("loadstart",this.As),null==(t=this.xs.presentation)||t.addEventListener("presentationmodechange",this.Ms),this.xs.textTracks.addEventListener("addtrack",this.Is),this.xs.textTracks.addEventListener("removetrack",this.Es),this.xs.textTracks.addEventListener("change",this.Ds),this.xs.audioTracks.addEventListener("addtrack",this.Fs),this.xs.audioTracks.addEventListener("removetrack",this.Ns),this.xs.audioTracks.addEventListener("change",this.$s)}Bs(){var t;for(const t of mo)this.xs.removeEventListener(t,this.Ts);this.xs.removeEventListener("error",this.Cs),this.xs.removeEventListener("contentprotectionerror",this.Cs),this.xs.removeEventListener("sourcechange",this.Ps),this.xs.removeEventListener("loadstart",this.As),null==(t=this.xs.presentation)||t.removeEventListener("presentationmodechange",this.Ms),this.xs.textTracks.removeEventListener("addtrack",this.Is),this.xs.textTracks.removeEventListener("removetrack",this.Es),this.xs.textTracks.removeEventListener("change",this.Ds),this.xs.audioTracks.removeEventListener("addtrack",this.Fs),this.xs.audioTracks.removeEventListener("removetrack",this.Ns),this.xs.audioTracks.removeEventListener("change",this.$s)}Os(t){this.trigger(new class{constructor(t,i){this.type=t.type,this.target=i,this.playerEvent=t}}(t,this))}createEl(){let t=this.o,i=t.player;if(!i)throw new m(this.localize('Missing required tech option "player"'));let s=i.element;return so.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(!nt(this.xs.source.ads))return this.xs.source.ads[0].sources;if(function(t){if(t.sources)if(lt(t.sources)){for(const i of t.sources)if(!pt(i)&&"verizon-media"===i.integration)return!0}else if(!pt(t.sources))return"verizon-media"===t.sources.integration;return!1}(this.xs.source))return"This source is managed by the Verizon Media integration extension.";if(function(t){if(t.sources)if(lt(t.sources)){for(const i of t.sources)if(L(i))return!0}else if(dt(t.sources))return L(t.sources);return!1}(this.xs.source))return"This source is managed by the DAI integration extension."}}}setSrc(t){return this.setSource({src:t})}setSource(t){this.lt=null,this.trigger("error")}currentSrc(){return this.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=!!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(it.FULLSCREEN)}enterFullScreen(){this.xs.presentation.requestMode(it.FULLSCREEN)}exitFullScreen(){this.xs.presentation.requestMode(it.INLINE)}Rs(){let t=this.xs.ads;if(t&&t.playing)return!0;let i=this.xs.vr;return!(!i||i.state===vo.ks)}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,i=()=>{t=!0};this.on("loadstart",i);let s=()=>{t||this.trigger("loadstart")};return this.on("loadedmetadata",s),void this.ready((()=>{this.off("loadstart",i),this.off("loadedmetadata",s),t||this.trigger("loadstart")}))}let i=["loadstart"];i.push("loadedmetadata"),t>=2&&i.push("loadeddata"),t>=3&&i.push("canplay"),t>=4&&i.push("canplaythrough"),this.ready((()=>{for(const t of i)this.trigger(t)}))}dispose(){this.Bs(),this.xs=null,super.dispose()}static isSupported(){return!0}static canPlayType(){return"maybe"}static canPlaySource(t){return"maybe"}get featuresVolumeControl(){return Bt}constructor(t={},i){super(t,i),this.Ts=t=>this.Os(t),this.Us=!1,this.Ps=()=>{this.Os(new z(this.xs.currentTime,this.xs.readyState)),this.Os(new yt)},this.As=()=>{this.Os(new Y(this.xs.currentTime))},this.Is=t=>{this.textTracks().tt(t.track)},this.Fs=t=>{this.audioTracks().tt(t.track)},this.Es=t=>{this.textTracks().it(t.track)},this.Ns=t=>{this.audioTracks().it(t.track)},this.Ds=()=>{let t=this.textTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.$s=()=>{let t=this.audioTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Ms=()=>{if(!this.supportsFullScreen())return;let t=this.Us,i=this.xs.presentation.currentMode===it.FULLSCREEN;t!==i&&(this.Us=i,this.trigger("fullscreenchange",{isFullscreen:i,nativeIOSFullscreen:!0}))},this.Cs=()=>{const t=this.xs.errorObject,i=t&&q(t.code)||-1,s=t&&t.message||"An unknown error occurred.";this.error({code:i,message:this.localize(s)})},this.xs=this.o.player,this._s();const s=!this.paused();s&&this.pause(),t.preload&&this.setPreload(t.preload),t.autoplay&&this.setAutoplay(t.autoplay),t.muted&&this.setMuted(t.muted),t.source?this.setSrc(t.source):this.Zt(),s&&this.ready((()=>this.play())),this.triggerReady()}};function wo(t){return class extends t{get xs(){return this.Vs||(this.Vs=this.player().tech({IWillNotUseThisInPlugins:!0}).theoplayer()),this.Vs}dispose(){this.Vs=void 0,super.dispose()}constructor(...t){super(...t),this.Vs=void 0}}}bo.prototype.featuresFullscreenResize=yo.prototype.featuresFullscreenResize,bo.prototype.featuresPlaybackRate=yo.prototype.featuresPlaybackRate,bo.prototype.featuresProgressEvents=!0,bo.prototype.featuresTimeupdateEvents=!0,bo.prototype.featuresNativeTextTracks=!0,so.registerTech("THEOplayer",bo);var ko=class{constructor(t){this.Ls=t=>{xt(this.Hs,"theo-mobile-button-hover"),t.stopImmediatePropagation()},this.zs=t=>{Ct(this.Hs,"theo-mobile-button-hover")},this.Ws=t=>{this.Hs.blur()},this.Hs=t,t.addEventListener("touchstart",this.Ls),t.addEventListener("touchend",this.zs),t.addEventListener("focusin",this.Ws)}},jo=so.getComponent("Menu"),So=class extends(wo(jo)){get qs(){return this.player().el()}Gs(){xt(this.qs,"theo-menu-opened")}Xs(){Ct(this.qs,"theo-menu-opened")}constructor(t,i){super(t,i)}},_o=so.getComponent("MenuItem"),xo=class extends(wo(_o)){get parentMenu(){return this.Qs}buildCSSClass(){return"theo-menu-item vjs-menu-item"}createEl(){let t=super.createEl("li",{className:this.buildCSSClass(),tabIndex:0},{"aria-live":"off","aria-label":""});return t.innerHTML="",t}handleClick(t){this.Js||(this.parentMenu.Ys(this),"tap"!==t.type&&"keydown"!==t.type||(this.Js=!0,this.trigger("click"),this.Js=!1))}dispose(){rt.Zs.Ks&&(this.el().removeEventListener("touchstart",this.Ls),this.el().removeEventListener("touchend",this.zs)),super.dispose()}constructor(t,i,s){super(t,Rt({selectable:!0},i)),this.Js=!1,this.Ls=t=>{xt(this.el(),"theo-mobile-menu-item-hover"),t.stopImmediatePropagation()},this.zs=t=>{Ct(this.el(),"theo-mobile-menu-item-hover")},this.Qs=s,rt.Zs.Ks&&(this.el().addEventListener("touchstart",this.Ls),this.el().addEventListener("touchend",this.zs))}},To=so.getComponent("ClickableComponent"),Co=class extends To{get parentMenu(){return this.Qs}get te(){return this.ie}set te(t){this.ie=t,this.el().setAttribute("tabindex",this.te?"0":"-1"),this.se()}buildCSSClass(){return"theo-primary-background theo-menu-header"}createEl(){let t=super.createEl("div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-live":"off","aria-label":""});return t.innerHTML="",t}handleClick(t){!this.Js&&this.te&&(this.Qs.ee(),"tap"===t.type&&(this.Js=!0,this.trigger("click"),this.Js=!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=!1,this.ie=!1,this.Qs=s,this.on(t,"languagechange",this.se)}},Po=class extends So{get menuHeader(){return this.ne}get menuItems(){return this.children()}addMenuItem(t){t=Rt({playerOptions:this.o.playerOptions},t);let i=new xo(this.player(),t,this);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}addSubMenuItem(t){t=Rt({playerOptions:this.o.playerOptions},t);let i=this.re(this.player(),t);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}removeMenuItem(t){this.removeChild(t),this.trigger("menuchange")}buildCSSClass(){return"theo-menu vjs-menu"}Gs(){super.Gs(),s.removeEventListener("resize",this.he),s.addEventListener("resize",this.he),this.show()}oe(){let t=this.ae();if(!t)return;let i=t.getClientRects();rt.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(),rt.Zs.Ks&&(this.el().removeAttribute("style"),this.contentEl().removeAttribute("style"))}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=this.contentEl();xt(i,"theo-menu-content");let s=new Co(this.player(),this.o,this);return i.parentNode.insertBefore(s.el(),i),this.ne=s,t}Ys(t){}show(){return this.oe(),super.show()}dispose(){this.ne&&this.ne.dispose(),super.dispose()}constructor(t,i){super(t,i),this.he=()=>this.oe(),this.le=this.player().el(),this.hide(),this.on("menuchange",this.oe)}},Ao=class extends Po{get fe(){return this.de}set fe(t){this.de&&this.de.ve(this),this.de=t,t&&t.pe(this)}me(t){this.fe.ge(t,"replace")}ye(t){t.fe.ge(this,"restore")}be(){Ct(this.we,"vjs-hidden"),this.we.style.opacity="1",super.show()}ke(){xt(this.we,"vjs-hidden")}Gs(){this.fe&&this.fe.Gs(),super.Gs()}Xs(){this.fe&&this.fe.Xs(),super.Xs(),xt(this.we,"vjs-hidden")}ae(){if(this.fe&&this.fe.je)return this.fe.je.we}ce(t,i){if(i.length>0){let t=i[0].height,s=i[0].width;this.de.Se.style.height=t+"px",this.de.Se.style.width=s+"px"}super.ce(t,i)}constructor(t,i){super(t,i)}},Mo=class extends Ao{get we(){return this.el()}get parentMenu(){return this._e}re(t,i){let s=new Io(t,i,this);return s.subMenu.fe=this.fe,s}ee(){this.xe()}Ys(t){super.Ys(t),this.xe()}xe(){this.parentMenu.ye(this)}buildCSSClass(){return"theo-submenu "+(this.Te?"":"theo-leaf-submenu ")+"theo-menu-content theo-menu-content-animatable "+super.buildCSSClass()}addSubMenuItem(t){this.Te=!0;let i=super.addSubMenuItem(t);return this.removeClass("theo-leaf-submenu"),i}constructor(t,i,s){super(t,i),this.Te=!1,this._e=s,this.menuHeader.te=!0}},Io=class extends xo{get subMenu(){return this.Ce}handleClick(t){this.parentMenu.me(this.subMenu)}constructor(t,i,s){super(t,Rt({selectable:!1},i),s),this.Ce=new Mo(t,i,s)}},Eo=class extends Ao{get menuButton(){return this.Pe}createEl(){let t=so.createEl("div",{className:this.buildCSSClass()});return this.Ae=super.createEl(),this.Ae.className=super.buildCSSClass(),xt(this.Ae,"theo-menu-content-animatable"),t.appendChild(this.Ae),this.fe=new class{get Se(){return this.Hs}get je(){return this.Me}pe(t){t.ke(),this.Hs.appendChild(t.we)}ve(t){this.Hs.removeChild(t.we)}ge(t,i){if(t==this.Me)return;let s=this.Me;if(this.Me=t,this.Me.be(),this.je.focus(),rt.Zs.Ks)s.ke();else{const t="translateX(100%)",e="translateX(-100%)",n=at("transform");s.we.style.opacity="0",s.we.style[n]="replace"===i?e:t,this.Me.we.style.opacity="1",this.Me.we.style[n]="",c((()=>{s.ke(),s.we.style[n]=""}),300)}}Gs(){this.Ie(),this.Me.be(),this.Ee()}Xs(){this.Ie(),this.Me.ke(),this.De.ke(),this.Me=this.De,this.Ee()}Ee(){T((()=>{Ct(this.Hs,"theo-no-transition"),Ct(this.Me.we,"theo-no-transition")}))}Ie(){xt(this.Hs,"theo-no-transition"),xt(this.Me.we,"theo-no-transition")}constructor(t){this.De=this.Me=t,this.Hs=u.createElement("div"),this.Hs.className="theo-tertiary-background theo-menu-animation-container",this.Hs.appendChild(this.De.we),this.le=this.Me.player().el()}}(this),t.appendChild(this.fe.Se),t}buildCSSClass(){return"theo-menu-animatable "+super.buildCSSClass()}re(t,i){let s=new Io(t,i,this);return s.subMenu.fe=this.fe,s}ce(t,i){super.ce(t,i);let s=this.le.getClientRects(),e=s.length>0?s[0]:void 0,n=S(getComputedStyle(this.el()).fontSize);Ft(this.el(),this.Pe.el(),e,n)}get we(){return this.Ae}ee(){this.Pe.closeMenu()}dispose(){this.Fe||(this.Fe=!0,super.dispose())}constructor(t,i,s){super(t,i),this.Fe=!1,this.Pe=s}},Do=class{set Ne(t){this.$e.innerHTML=this.Be.localize(t),this.Oe(),this.Re(),It(this.Be.el())}get Ne(){return this.$e.textContent||""}Ue(){this.Be.off("mouseover",this.Re),this.Be.off("mouseout",this.Oe),this.Be.off("dispose",this.Ve),kt(this.$e)}constructor(t,i){this.Re=()=>{Ct(this.$e,"vjs-hidden");let t=this.Be.player().contentEl().getClientRects(),i=t.length>0?t[0]:void 0,s=S(getComputedStyle(this.$e).fontSize);Ft(this.$e,this.Be.el(),i,s)},this.Oe=()=>{xt(this.$e,"vjs-hidden")},this.Ve=()=>this.Ue(),this.Be=t,It(t.el()),Dt(t.el()),this.$e=u.createElement("span"),this.$e.innerHTML=this.Be.localize(i),this.$e.className="theo-button-tooltip vjs-hidden",this.$e.setAttribute("aria-hidden","true"),this.Be.el().appendChild(this.$e),this.Be.on("mouseover",this.Re),this.Be.on("mouseout",this.Oe),this.Be.on("dispose",this.Ve)}},Fo=so.getComponent("Button"),No=class extends(wo(Fo)){get Le(){const t=this.el().parentElement;return!!t&&null!==t.querySelector(".theo-mobile-menu-background")}get menu(){return this.He}isMenuOpen(){return this.ze}openMenu(){this.We&&!this.ze&&(this.He.Gs(),this.el().setAttribute("aria-expanded","true"),this.ze=!0,this.He.focus())}closeMenu(){this.We&&this.ze&&(this.He.Xs(),this.el().setAttribute("aria-expanded","false"),this.ze=!1)}set minimumMenuItems(t){this.qe=t,this.Ge()}buildCSSClass(){return"theo-controlbar-button vjs-menu-button vjs-menu-button-popup "+super.buildCSSClass()}createEl(t,i,s){return super.createEl("button",{},{"aria-live":"off"})}handleClick(){this.ze?this.closeMenu():this.openMenu()}enable(){return this.We=!0,super.enable()}disable(){return this.closeMenu(),this.We=!1,super.disable()}se(){this.$e.Ne=this.controlText()}dispose(){this.player().removeChild(this.He),this.He.dispose(),this.$e.Ue(),this.xs.removeEventListener("seeking",this.Xe),super.dispose()}constructor(t,i){super(t,i),this.ze=!1,this.qe=1,this.We=!0,this.Qe=t=>{let i=this.el().contains(t.target),s=this.He.el().contains(t.target),e=!1;var n;rt.Zs.Ks&&this.Le&&(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.Je=t=>{27===t.which&&(this.closeMenu(),this.focus())},this.Xe=()=>{this.ze&&this.closeMenu()},this.Ge=()=>{this.He.menuItems.length>=this.qe?this.show():(this.closeMenu(),this.hide())},this.He=new Eo(t,i,this),this.player().getChild("controlBarMenuContainer").addChild(this.He),this.$e=new Do(this,this.controlText()),this.el().setAttribute("aria-haspopup","true"),rt.Zs.Ye?(this.on(u,"touchend",this.Qe),new ko(this.el())):(this.on(u,"click",this.Qe),this.on(u,"keydown",this.Je),vt&&this.on(u,vt.Ke,this.closeMenu)),this.xs.addEventListener("seeking",this.Xe),this.on(this.He,"menuchange",this.Ge),this.on(t,"languagechange",this.se),this.Ge()}},$o=so.getComponent("Component"),Bo=class extends(so.getComponent("ControlBar")){addMenuButton(t){t=Rt({playerOptions:this.o.playerOptions},t);let i=new No(this.player(),t);return this.addChild(i),i}removeMenuButton(t){this.removeChild(t)}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-secondary-color vjs-control-bar "+super.buildCSSClass()}constructor(t,i){super(t,i),this.addChild("THEOControlBarShadow",void 0,0)}};so.registerComponent("THEOControlBarShadow",class extends $o{createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-tertiary-color theo-control-bar-shadow"}});var Oo=so.getComponent("VolumeBar"),Ro=class extends Oo{handleFocus(t){super.handleFocus(t),this.Ze.addClass("focus-within")}handleBlur(t){super.handleBlur(t),this.Ze.removeClass("focus-within")}constructor(t,i){super(t,i),this.Ze=i.tn}},Uo=so.getComponent("VolumeControl"),Vo=class extends Uo{constructor(t,i){super(t,i),this.sn=new Ro(t,{tn:this}),this.addChild(this.sn)}};Vo.prototype.o=Rt({},Uo.prototype.o,{children:[]}),so.registerComponent("VolumeControl",Vo);var Lo=class extends(wo(Bo)){nn(){return this.el().getBoundingClientRect().height}dispose(){this.el().removeEventListener("transitionstart",this.rn),this.el().removeEventListener("transitionend",this.hn),this.un.an("cn",this.ln),this.un.fn(),super.dispose()}constructor(t,i){super(t,i),this.rn=t=>{if("opacity"===t.propertyName){const t=this.nn();this.xs.textTrackStyle.marginBottom!==t&&(this.xs.textTrackStyle.marginBottom=t)}},this.hn=t=>{"opacity"===t.propertyName&&"0"===s.getComputedStyle(this.el()).opacity&&(this.xs.textTrackStyle.marginBottom=void 0)},this.ln=()=>{void 0!==this.xs.textTrackStyle.marginBottom&&(this.xs.textTrackStyle.marginBottom=this.nn())},this.el().addEventListener("transitionstart",this.rn),this.el().addEventListener("transitionend",this.hn),this.un=new ct(this.el()),this.un.dn("cn",this.ln),this.un.vn(!0)}};Lo.prototype.o=Rt({},Bo.prototype.o,{children:["progressControl","playToggle","muteToggle","volumeControl","currentTimeDisplay","timeDivider","durationDisplay","liveDisplay","remainingTimeDisplay","customControlSpacer","activeQualityLabel","vrButton","descriptionsButton","subtitlesButton","chromecastButton","airplayButton","multiViewButton","audioTrackButton","SettingsButton","fullscreenToggle"]}),so.registerComponent("ControlBar",Lo);var Ho=class extends Bo{buildCSSClass(){return"theo-top-controlbar "+super.buildCSSClass()}constructor(t,i){super(t,i),t.topControlBar=this}};Ho.prototype.o=Rt({},Bo.prototype.o,{children:[]}),so.registerComponent("TopControlBar",Ho);var zo=so.getComponent("CurrentTimeDisplay");so.registerComponent("CurrentTimeDisplay",class extends zo{updateContent(){let t=this.player(),i=no(t),s=ho(t),e=this.localize("Current Time"),n=uo(k.max(0,i-s),oo(t));n!==this.Pt&&(this.Pt=n,this.contentEl().innerHTML='<span class="vjs-control-text">'+e+"</span> "+n)}constructor(t,i){super(t,i),this.on(t,"timeupdate",this.updateContent),this.on(t,"emptied",this.updateContent)}});var Wo=so.getComponent("DurationDisplay"),qo=class extends(wo(Wo)){updateContent(){const t=_(this.xs.duration)?NaN:oo(this.player()),i=this.xs.clip.endTime-this.xs.clip.startTime,s=k.min(t,i)||0;if(this.ct!==s){this.ct=s;const t=this.localize("Duration Time"),i=uo(s);this.S.innerHTML='<span class="vjs-control-text">'+t+"</span> "+i}}constructor(t,i){super(t,i),this.pn=()=>this.updateContent(),this.off(t,"durationchange",this.updateContent),this.on(t,"durationchange",this.updateContent),this.off(t,"timeupdate",this.updateContent),this.on(t,"timeupdate",this.updateContent),this.off(t,"emptied",this.updateContent),this.on(t,"emptied",this.updateContent),this.xs&&this.xs.clip.addEventListener("change",this.pn)}};so.registerComponent("DurationDisplay",qo);var Go=so.getComponent("Button"),Xo=class extends(wo(Go)){buildCSSClass(){return"theo-live-control "+super.buildCSSClass()}createEl(){let t=super.createEl("button",{},{"aria-live":"off"});return this.mn=so.createEl("span",{className:"theo-live-control-indicator"}),t.insertBefore(this.mn,t.firstChild),t}createControlTextEl(t){let i=super.createControlTextEl(t);return so.removeClass(i,"vjs-control-text"),so.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(ro(t)),t.play()}}gn(){eo(this.player())?this.show():this.hide()}constructor(t,i){super(t,i),this.controlText("Live"),this.gn(),this.on(this.player(),"durationchange",this.gn),rt.Zs.Ye&&new ko(this.el())}};so.registerComponent("LiveDisplay",Xo);var Qo=so.getComponent("LoadingSpinner");so.registerComponent("LoadingSpinner",class extends Qo{buildCSSClass(){return"theo-secondary-color vjs-loading-spinner "+super.buildCSSClass()}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=so.createEl("div",{className:"theo-loading-spinner-rotator"}),s=so.createEl("div",{className:"theo-loading-spinner-circle-left"}),e=so.createEl("div",{className:"theo-loading-spinner-circle-right"});return i.appendChild(s),i.appendChild(e),t.appendChild(i),t}constructor(t,i){super(t,i)}});var Jo=so.getComponent("LoadProgressBar");function Yo(t,i){let s=t/i||0;return 100*(s>=1?1:s)+"%"}so.registerComponent("LoadProgressBar",class extends Jo{update(){let t=this.player(),i=K.yn(ao(t)),s=i.bn(0),e=K.yn(t.buffered()).wn(i),n=i.kn(0)-s,r=e.V&&e.kn(e.V-1)||0;r=k.max(0,r-s);let h=this.el(),o=this.jn;h.style.width=Yo(r,n);for(let t=0;t<e.V;t++){let i=e.bn(t),n=e.kn(t),a=o[t];a||(a=u.createElement("div"),o.push(a),h.appendChild(a)),a.style.left=Yo(i-s,r),a.style.width=Yo(n-i,r)}for(let t=o.length;t>e.V;t--)h.removeChild(o[t-1]);o.length=e.V}constructor(t,i){super(t,i),this.jn=[],this.on(t,"emptied",this.update)}});var Ko=so.getComponent("MouseTimeDisplay"),Zo=class extends(wo(Ko)){handleMouseMove(t){let i=this.player(),s=ho(i)+this.calculateDistance(t)*oo(i),e=t.pageX-Et(this.el().parentNode).left;this.update(s,e+"px")}handleTouchMove(t){let i=this.player(),s=ho(i)+this.calculateDistance(t)*oo(i),e=t.touches[0].pageX-Et(this.el().parentNode).left;this.update(s,e+"px")}createEl(){let t=super.createEl();return this.Sn=so.createEl("span",{className:"theo-time-tooltip-text"}),t}update(t,i){let s=this._n(t);if(this.el().style.left=i,this.el().setAttribute("data-current-time",s),this.keepTooltipsInside&&($t(this.Sn,s),this.tooltip.offsetParent)){let t=this.player().contentEl(),i=t.getClientRects(),s=i.length>0?i[0]:void 0,e=S(getComputedStyle(t).fontSize);Ft(this.tooltip,this.el(),s,e)}}_n(t){let i=this.player();const s=t-ro(i);return uo(eo(i)?k.min(s,0):s,oo(i))}constructor(t,i){var s;(super(t,i),this.xn=()=>{let t=this.player(),i=t.scrubbing()?t.getCache().currentTime:t.currentTime(),s=(i-ho(t))/oo(t)||0;s=bt(s,0,1),this.update(i,100*s+"%")},this.keepTooltipsInside&&(so.addClass(this.tooltip,"theo-secondary-color"),this.tooltip.appendChild(this.Sn)),ot.Ks)&&(this.on(t,"firstplay",this.xn),this.on(t,"play",this.xn),this.on(t,"seeking",this.xn),this.on(t,"seeked",this.xn),this.on(t,"timeupdate",this.xn),this.xs.addEventListener("dimensionchange",this.xn),null==(s=this.xs.presentation)||s.addEventListener("presentationmodechange",this.xn),t.on("ready",(()=>{this.on(t.controlBar.progressControl,"touchmove",gt((t=>this.handleTouchMove(t)),25)),this.xn()})))}};so.registerComponent("MouseTimeDisplay",Zo);var ta=so.getComponent("PlayProgressBar");so.registerComponent("PlayProgressBar",class extends ta{updateDataAttr(){let t=no(this.player());this.el().setAttribute("data-current-time",this._n(t))}_n(t){let i=this.player();return uo(t-ro(i),oo(i))}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-play-progress vjs-slider-bar "+super.buildCSSClass()}constructor(t,i){super(t,i)}});var ia=so.getComponent("RemainingTimeDisplay");so.registerComponent("RemainingTimeDisplay",class extends ia{updateContent(){const t=this.player(),i=oo(t);if(i){const s=ao(t).end(0),e=this.localize("Remaining Time"),n=uo(k.max(0,s-t.currentTime()),i);n!==this.Pt&&(this.Pt=n,this.contentEl().innerHTML='<span class="vjs-control-text">'+e+"</span> -"+n)}}constructor(t,i){super(t,i),this.on(t,"timeupdate",this.updateContent),this.on(t,"emptied",this.updateContent)}});var sa=class{get Se(){return this.Hs}Tn(){na(this.Cn,this.h.currentTime)&&this.Pn(),this.Cn.addEventListener("enter",this.Pn),this.Cn.addEventListener("exit",this.An)}Mn(){let t=this.h.seekable.start(0),i=this.h.seekable.end(this.h.seekable.length-1)-t,s=this.Cn.startTime,e=this.Cn.endTime-s,n=u.createElement("div");xt(n,"theoplayer-chapter-indicator");let r=u.createElement("div");xt(r,"theoplayer-chapter-indicator-highlight"),n.appendChild(r),this.In&&xt(n,"theoplayer-chapter-indicator-discontinuous");let h=k.min(s/i*100,100),o=100-h,a=k.min(e/i*100,o);return n.style.width=a+"%",n.style.left=h+"%",n}Ue(){this.Cn.removeEventListener("enter",this.Pn),this.Cn.removeEventListener("exit",this.An),kt(this.Hs)}constructor(t,i,s){this.Cn=t,this.h=i,this.In=s,this.Pn=()=>{xt(this.Se,"theoplayer-chapter-indicator-active")},this.An=()=>{Ct(this.Se,"theoplayer-chapter-indicator-active")},this.Hs=this.Mn(),this.Tn()}},ea=class{ke(){this.En--,0===this.En&&Ct(this.Se,"theoplayer-chapter-hovering")}Dn(t){this.Fn=t||[],this.Fn.length>0&&(this.Se.style.display="")}Nn(t){$t(this.$n,t.content)}Bn(){this.Fn=[],$t(this.$n,""),this.Se.style.display="none"}be(){this.En++,this.En>0&&xt(this.Se,"theoplayer-chapter-hovering")}On(t){for(let i of this.Fn)if(na(i,t)){this.Nn(i);break}}Ue(){kt(this.Se)}constructor(){this.Fn=[],this.En=0,this.Se=u.createElement("div"),xt(this.Se,"theoplayer-chaptertitle"),this.Se.style.display="none",this.$n=u.createElement("p"),this.Se.appendChild(this.$n)}};function na(t,i){return new K([t.startTime,t.endTime]).Rn(i)}var ra=so.getComponent("SeekBar"),ha=class extends(wo(ra)){updateAriaAttributes(t){let i=this.player(),s=no(i);t.setAttribute("aria-valuenow",(100*this.Un(s)).toFixed(2)),t.setAttribute("aria-valuetext",uo(s-ro(i),oo(i)))}getPercent(){return this.Un(this.player().currentTime())}handleMouseMove(t){if(this.xs&&this.xs.ads&&this.xs.ads.playing)return;let i=this.player(),s=ho(i)+this.calculateDistance(t)*oo(i);s>=i.duration()&&(s=i.duration()-.1),this.Ln.Vn(s),i.currentTime(s)}handleMouseDown(t){this.playingStates.push(!this.player().paused()),this.Ln.Hn(),super.handleMouseDown(t)}handleMouseUp(t){this.videoWasPlaying=Boolean(this.playingStates.pop()),this.Ln.zn(),super.handleMouseUp(t)}Un(t){let i=this.player(),s=(t-ho(i))/oo(i);return bt(s,0,1)}dispose(){this.Ln.Ue(),Zt(this.playingStates)}constructor(t,i){super(t,i),this.playingStates=[],this.on(t,"emptied",this.update),this.on(t,"seeking",this.update),this.Ln=new class{get xs(){return this.Vs||(this.Vs=this.Wn.tech({IWillNotUseThisInPlugins:!0}).theoplayer()),this.Vs}qn(t){if(t.kind!==X.Gn)return;if(0===this.xs.seekable.length)return;this.Xn=t;const i=t.cues.slice();this.Qn.Dn(i);for(let t=0;t<i.length;t++){let s=i[t],e=i[t+1],n=!e||s.endTime!==e.startTime,r=new sa(s,this.xs,n);this.Jn.push(r),this.Ln.appendChild(r.Se)}}Yn(){this.xs.addEventListener("loadedmetadata",this.Kn),this.xs.addEventListener("loadeddata",this.Kn),this.xs.addEventListener("sourcechange",this.Kn),this.xs.textTracks.addEventListener("addtrack",this.Zn),this.xs.textTracks.addEventListener("removetrack",this.tr),this.xs.textTracks.addEventListener("change",this.Kn)}ir(){this.xs.removeEventListener("loadedmetadata",this.Kn),this.xs.removeEventListener("loadeddata",this.Kn),this.xs.removeEventListener("sourcechange",this.Kn),this.xs.textTracks.removeEventListener("addtrack",this.Zn),this.xs.textTracks.removeEventListener("removetrack",this.tr),this.xs.textTracks.removeEventListener("change",this.Kn)}sr(){if(!(this.xs.readyState<H.er))for(let t of this.xs.textTracks)if(t.kind===X.Gn&&t.mode===U.nr&&t.cues.length>0&&t.readyState!==G.ERROR)return t}Vn(t){this.Qn.On(t)}Hn(){this.Qn.be()}zn(){this.Qn.ke()}Bn(){for(let t of this.Jn)t.Ue();this.Qn.Bn(),this.Jn=[],this.Xn=void 0}Ue(){this.ir(),this.rr.removeEventListener("mousemove",this.hr),this.rr.removeEventListener("mouseenter",this.ar),this.rr.removeEventListener("mouseleave",this.ur),this.Bn(),this.Qn.Ue(),this.Vs=void 0}constructor(t,i){this.Wn=i,this.Jn=[],this.Vs=void 0,this.Zn=t=>{let i=t.track;i.kind===X.Gn&&(i.addEventListener("addcue",this.Kn),i.addEventListener("removecue",this.Kn),i.addEventListener("readystatechange",this.Kn)),this.Kn()},this.tr=t=>{let i=t.track;i.kind===X.Gn&&(i.removeEventListener("addcue",this.Kn),i.removeEventListener("removecue",this.Kn),i.removeEventListener("readystatechange",this.Kn)),this.Kn()},this.hr=t=>{let i=this.Wn,s=function(t,i){let s,e,n=Et(t),r=t.offsetWidth,h=t.offsetHeight,o=n.top,a=n.left;!function(t){return void 0!==t.changedTouches}(i)?(e=i.pageX,s=i.pageY):(e=i.changedTouches[0].pageX,s=i.changedTouches[0].pageY);let u=bt((o-s+h)/h,0,1);return{x:bt((e-a)/r,0,1),y:u}}(this.Ln,t),e=ho(i)+s.x*oo(i);e===i.duration()&&(e-=.1),this.Vn(e)},this.ur=()=>{this.Qn.ke()},this.ar=()=>{this.Qn.be()},this.Kn=()=>{let t=this.sr();t!==this.Xn&&(this.Bn(),t&&this.qn(t))},this.rr=t,this.Qn=new ea,this.Wn.contentEl().appendChild(this.Qn.Se),this.Ln=u.createElement("div"),xt(this.Ln,"theoplayer-chapterbar"),this.rr.appendChild(this.Ln),this.rr.addEventListener("mousemove",this.hr),this.rr.addEventListener("mouseenter",this.ar),this.rr.addEventListener("mouseleave",this.ur),this.Yn()}}(this.el(),t)}};so.registerComponent("SeekBar",ha);var oa=so.getComponent("ProgressControl");rt.Zs.Ks&&so.registerComponent("ProgressControl",class extends oa{createEl(){return super.createEl("div",{className:"vjs-progress-control vjs-control"})}handleMouseMove(t){this.seekBar.handleMouseMove(t)}handleMouseDown(t){this.seekBar.handleMouseDown(t)}constructor(t,i){super(t,i),this.on(this,"touchmove",this.handleMouseMove),this.on("touchstart",this.handleMouseDown),this.seekBar.off(["touchmove","touchstart"])}});var aa=so.getComponent("TooltipProgressBar");function ua(t){for(let i of t)if(i.enabled)return i}function ca(t){if(t)return t.label&&""!==t.label?{name:t.label,hd:!1}:{name:la(t),description:fa(t),hd:!!t.height&&t.height>=720}}function la(t){return t.height?t.height+"p":t.bandwidth?fa(t):""}function fa(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":""}so.registerComponent("TooltipProgressBar",class extends aa{updateDataAttr(){let t=no(this.player()),i=this._n(t);this.el().setAttribute("data-current-time",i),this.tooltip.innerHTML=i}_n(t){let i=this.player();return uo(t-ro(i),oo(i))}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-tooltip-progress-bar vjs-slider-bar "+super.buildCSSClass()}constructor(t,i){super(t,i)}});var da=class{get cr(){return this.lr}set cr(t){let i=this.lr;for(let s=i.length-1;s>=0;s--){let e=i[s];Yt(t,e)||this.dr(e)}for(let i of t)this.pr(i);this.mr.oe()}get gr(){return this.mr.menuItems}yr(t){let i=this.gr;if(i)for(let s of i)if(s.br===t)return s}wr(t){let i=this.mr.addMenuItem();return i.br=t,i.on("click",(()=>this.kr(i))),i.el().setAttribute("role","menuitemradio"),i}jr(t){t.dispose()}Sr(t){return!0}pr(t){if(this.Sr(t)){Yt(this.lr,t)||this.lr.push(t);let i=this.yr(t)||this.wr(t);return this._r(i),i}this.dr(t)}dr(t){let i=this.yr(t);i&&(this.mr.removeMenuItem(i),this.jr(i)),Qt(this.lr,t)}Ue(){const t=[];for(let i of this.lr)t.push(i);for(let i of t)this.dr(i);Zt(t)}constructor(t){this.lr=[],this.mr=t}},va=class extends da{Tr(){return this.Cr=u.createElement("span"),this.Cr.className="theo-settings-control-menu-item-title",$t(this.Cr,this.Pr.localize("Quality")),this.Cr}Ar(){return this.Mr=u.createElement("span"),this.Mr.className="theo-settings-control-menu-quality-automatic",$t(this.Mr,this.Pr.localize("Automatic")),this.Mr}Ir(){return this.Er=u.createElement("span"),$t(this.Er,this.Pr.localize("Automatic")),this.Er}Dr(){return this.Fr=u.createElement("span"),this.Fr.className="theo-primary-color theo-settings-control-menu-item-hd-label",$t(this.Fr,this.Pr.localize("HD")),this.Fr}Nr(){let t=u.createElement("span");t.className="theo-primary-color theo-settings-control-menu-item-value",t.appendChild(this.Mr),t.appendChild(u.createTextNode(" ")),t.appendChild(this.Er),t.appendChild(u.createTextNode(" ")),t.appendChild(this.Fr),this.$r.el().appendChild(this.Cr),this.$r.el().appendChild(t),this.$r.el().setAttribute("aria-label",this.Pr.localize("Open the video quality settings menu"))}Br(){let t=this.Or,i=t&&ka(t.targetQuality),s=t&&t.activeQuality,e=ca(this.Rr(i||s))||{name:this.Pr.localize("Automatic")};$t(this.Er,e.name),At(this.Mr,"vjs-hidden",!!i),At(this.Fr,"vjs-hidden",!e.hd)}_r(t){let i=ca(t.br)||{name:this.Pr.localize("Automatic")},s=i.name;i.hd&&(s+='<span class="theo-primary-color theo-settings-control-menu-item-hd-label">'+this.Pr.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.Pr.localize("Set video quality to ")+i.name),t.br?t.selected(t.br===this.Ur):t.selected(!this.Ur)}kr(t){this.Or&&(this.Or.targetQuality=t.br&&t.br.videoQualities)}Rr(t,i){const s=i||this.cr;for(let i of s)if(t&&i&&-1!==i.videoQualities.indexOf(t))return i}Ue(){this.Vs.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.Vr),this.Pr.off("languagechange",this.se),this.Or&&(this.Or.removeEventListener("activequalitychanged",this.Lr),this.Or.removeEventListener("targetqualitychanged",this.Hr),this.Or.removeEventListener("update",this.zr)),super.Ue()}constructor(t,i,s){super(t.subMenu),this.Or=void 0,this.Ur=void 0,this.Vr=()=>{let t=ua(this.Vs.videoTracks);if(t===this.Or)return;let i=[];if(this.Or&&(this.Or.removeEventListener("activequalitychanged",this.Lr),this.Or.removeEventListener("targetqualitychanged",this.Hr),this.Or.removeEventListener("update",this.zr)),this.Or=t,t){t.addEventListener("activequalitychanged",this.Lr),t.addEventListener("targetqualitychanged",this.Hr),t.addEventListener("update",this.zr);const s=ma(ba(t.qualities.filter((t=>t.available))));i=s.length>1?[void 0,...s]:[void 0]}this.cr=i,this.Hr(),this.Lr()},this.zr=t=>{const i=t.track;if(i!==this.Or)return;const s=ma(ba(i.qualities.filter((t=>t.available)))),e=i&&ka(i.targetQuality);let n;this.Ur=this.Rr(e,s),n=s.length>1?[void 0,...s]:[void 0],this.cr=n,this.Br()},this.Lr=()=>{this.pr(void 0),this.Br()},this.Hr=()=>{let t=ua(this.Vs.videoTracks),i=t&&ka(t.targetQuality),s=this.Rr(i),e=this.Ur;s!==e&&(this.Ur=s,s&&e||this.pr(void 0),e&&Yt(this.cr,e)&&this.pr(e),i&&this.pr(s),this.Br())},this.se=()=>{$t(this.mr.menuHeader.el(),this.Pr.localize("Quality")),$t(this.Cr,this.Pr.localize("Quality")),$t(this.Mr,this.Pr.localize("Automatic")),$t(this.Er,this.Pr.localize("Automatic")),$t(this.Fr,this.Pr.localize("HD")),this.$r.el().setAttribute("aria-label",this.Pr.localize("Open the video quality settings menu"));for(const t of this.gr)this._r(t);this.Br()},this.$r=t,this.Vs=i,this.Pr=s,this.Cr=this.Tr(),this.Mr=this.Ar(),this.Er=this.Ir(),this.Fr=this.Dr(),this.Nr(),$t(this.mr.menuHeader.el(),this.Pr.localize("Quality")),this.cr=[void 0],this.Vs.videoTracks.addEventListener(["addtrack","removetrack","change"],this.Vr),this.Pr.on("languagechange",this.se),this.Vr()}},pa=class{get height(){return this.Wr[0].height}get bandwidth(){return this.Wr[0].bandwidth}get videoQualities(){return this.Wr}get label(){return this.Wr[0].label}add(t){this.Wr.push(t)}constructor(t){this.Wr=t}};function ma(t){let i=[];for(let s of t){let t=s,e=!1;for(let s of i)if(wa(s,t)){s.add(t),e=!0;break}e||i.push(new pa([t]))}return i}function ga(t,i){return t&&i?Wt(t,i):Ht.qr}function ya(t,i){return t===i?Ht.qr:ga(t.height,i.height)||ga(t.width,i.width)||ga(t.bandwidth,i.bandwidth)}function ba(t){return Vt(t,ya).reverse()}function wa(t,i){return t.label&&i.label&&t.label===i.label||B(ca(t),ca(i))}function ka(t){return lt(t)?1===t.length?t[0]:void 0:t}function ja(t){return 1===t?"Normal":""+k.round(100*t)/100}var Sa=class extends da{Tr(){return this.Cr=u.createElement("span"),this.Cr.className="theo-settings-control-menu-item-title",$t(this.Cr,this.Pr.localize("Speed")),this.Cr}Nr(){const t=u.createElement("span");return t.className="theo-primary-color theo-settings-control-menu-item-value",this.$r.el().appendChild(this.Cr),this.$r.el().appendChild(t),this.$r.el().setAttribute("aria-label",this.Pr.localize("Open the video speed settings menu")),t}wr(t){let i=super.wr(t);return this._r(i),i}_r(t){const i=t.br,s=this.Pr.localize(ja(i));$t(t.el(),s),t.el().setAttribute("aria-label",this.Pr.localize("Set video speed to "+s)),t.selected(t.br===this.Vs.playbackRate)}kr(t){this.Vs.playbackRate=t.br}Ue(){this.Vs.removeEventListener("ratechange",this.Gr),this.Pr.off("languagechange",this.se),super.Ue()}constructor(t,i,s,e){super(t.subMenu),this.Xr=void 0,this.Gr=()=>{this.Xr&&this.pr(this.Xr);let t=this.Vs.playbackRate;this.Xr=t,$t(this.Qr,this.Pr.localize(ja(t))),t&&this.pr(t)},this.se=()=>{$t(this.mr.menuHeader.el(),this.Pr.localize("Speed")),$t(this.Cr,this.Pr.localize("Speed")),this.$r.el().setAttribute("aria-label",this.Pr.localize("Open the video speed settings menu"));for(const t of this.gr)this._r(t);this.Gr()},this.$r=t,this.Vs=i,this.Pr=s,this.Cr=this.Tr(),this.Qr=this.Nr(),$t(this.mr.menuHeader.el(),this.Pr.localize("Speed")),this.cr=e,this.Vs.addEventListener("ratechange",this.Gr),this.Pr.on("languagechange",this.se),this.Gr()}};so.registerComponent("SettingsButton",class extends No{createEl(){let t=super.createEl();return this.Jr=so.createEl("span",{className:"theo-settings-control-label-hd theo-primary-background"}),$t(this.Jr,this.localize("HD")),t.appendChild(this.Jr),t}buildCSSClass(){return"vjs-icon-cog theo-settings-control-button "+super.buildCSSClass()}se(){super.se(),$t(this.Jr,this.localize("HD")),$t(this.menu.menuHeader.el(),this.localize("Settings"))}dispose(){this.Or&&(this.Or.removeEventListener("activequalitychanged",this.Lr),this.Or=void 0),this.xs.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.Yr),this.Kr.Ue(),this.Zr.Ue(),super.dispose()}constructor(t,i){var s,e;super(t,i),this.Or=void 0,this.Yr=()=>{let t=ua(this.xs.videoTracks);t!==this.Or&&(this.Or&&this.Or.removeEventListener("activequalitychanged",this.Lr),this.Or=t,t&&t.addEventListener("activequalitychanged",this.Lr),this.Lr())},this.Lr=()=>{var t;const i=null==(t=this.Or)?void 0:t.activeQuality,s=!!(i&&i.height>=720);this.player().toggleClass("theo-hd",s)},xt(this.menu.el(),"theo-settings-control-menu"),$t(this.menu.menuHeader.el(),t.localize("Settings")),this.controlText("Settings"),this.$e.Ne=this.controlText(),this.th=this.menu.addSubMenuItem({name:"QualityMenuItem"}),this.Kr=new va(this.th,this.xs,t);let n=null!=(e=null==i||null==(s=i.playerOptions)?void 0:s.playbackRates)?e:[];this.ih=this.menu.addSubMenuItem({name:"PlaybackRateMenuItem"}),this.Zr=new Sa(this.ih,this.xs,t,n),this.xs.videoTracks.addEventListener(["addtrack","removetrack","change"],this.Yr),this.Yr()}});var _a=class extends da{sh(t){let i=t.label;if(i)return i;let s=t.language;if(s){let t=M(s);if(t)return t.eh}return s||""}nh(){this.cr=this.rh}Ue(){this.rh.removeEventListener("addtrack",this.hh),this.rh.removeEventListener("removetrack",this.oh),this.rh.removeEventListener("change",this.ah),super.Ue()}constructor(t,i){super(t),this.hh=t=>{const i=t.track;this.pr(i),i.addEventListener("update",this.uh)},this.oh=t=>{const i=t.track;this.dr(i),i.removeEventListener("update",this.uh)},this.ah=t=>this.nh(),this.uh=()=>{for(const t of this.cr)this.pr(t)},this.rh=i,this.rh.addEventListener("addtrack",this.hh),this.rh.addEventListener("removetrack",this.oh),this.rh.addEventListener("change",this.ah),this.nh()}},xa=class extends _a{_r(t){let i=t.br,s=this.sh(i);$t(t.el(),this.sh(i)),t.el().setAttribute("aria-label",this.Pr.localize("Set the audio language to")+" "+s),t.selected(i.enabled)}kr(t){let i=t.br;for(let t of this.xs.audioTracks)t!==i&&(t.enabled=!1);i.enabled=!0}Ue(){this.Pr.off("languagechange",this.se),super.Ue()}constructor(t,i,s){super(t,i.audioTracks),this.se=()=>{$t(this.mr.menuHeader.el(),this.Pr.localize("Language"));for(const t of this.gr)this._r(t)},this.xs=i,this.Pr=s,$t(this.mr.menuHeader.el(),this.Pr.localize("Language")),this.Pr.on("languagechange",this.se)}};so.registerComponent("audioTrackButton",class extends No{buildCSSClass(){return"vjs-icon-audio theo-audio-track-control-button "+super.buildCSSClass()}dispose(){this.lh.Ue(),super.dispose()}constructor(t,i){super(t,i),this.minimumMenuItems=2,this.lh=new xa(this.menu,this.xs,t),this.controlText("Language"),this.$e.Ne=this.controlText()}});var Ta=class extends _a{Sr(t){return!!super.Sr(t)&&(!t.forced&&J(t.kind))}wr(t){let i=super.wr(t);xt(i.el(),"theo-text-track-menu-item");let s=u.createElement("span");i.fh=s;let e=u.createElement("div");e.className="theo-text-track-menu-item-toggle",i.dh=e;let n=t=>this.ph(t,i);i.mh=n,e.addEventListener("click",n);let r=u.createElement("div");return r.className="theo-text-track-menu-item-toggle-slider",e.appendChild(r),i.el().appendChild(s),i.el().appendChild(e),i}_r(t){let i=t,s=i.br,e=this.sh(s);$t(i.fh,e),i.el().setAttribute("aria-label",this.Pr.localize("Set the subtitle language to")+" "+e),i.el().setAttribute("role","menuitemcheckbox"),i.selected(s.mode===U.nr)}jr(t){let i=t;i.dh.removeEventListener("click",i.mh),super.jr(t)}kr(t){let i=t.br;for(let t of this.xs.textTracks)t!==i&&Q(t.kind,i.kind)&&(t.mode=U.gh);i.mode!==U.nr?i.mode=U.nr:i.mode=U.gh}ph(t,i){t.stopImmediatePropagation(),this.kr(i)}Ue(){this.Pr.off("languagechange",this.se),super.Ue()}constructor(t,i,s){super(t,i.textTracks),this.se=()=>{$t(this.mr.menuHeader.el(),this.Pr.localize("Subtitles"));for(const t of this.gr)this._r(t)},this.xs=i,this.Pr=s,$t(this.mr.menuHeader.el(),s.localize("Subtitles")),this.Pr.on("languagechange",this.se)}};so.registerComponent("subtitlesButton",class extends No{buildCSSClass(){return"vjs-icon-subtitles theo-text-track-control-button "+super.buildCSSClass()}dispose(){this.lh.Ue(),super.dispose()}constructor(t,i){super(t,i),this.lh=new Ta(this.menu,this.xs,t),this.controlText("Subtitles"),this.$e.Ne=this.controlText()}});var Ca,Pa=so.getComponent("playToggle");!function(t){t.yh="Pause",t.bh="Play",t.wh="Replay"}(Ca||(Ca={}));var Aa=class extends(wo(Pa)){handleClick(t){this.xs.muted||this.xs.prepareWithUserAction(),super.handleClick(t)}handlePlay(t){super.handlePlay(t),this.controlText("Pause"),this.$e.Ne=this.controlText()}handlePause(t){this.xs.ended||(super.handlePause(t),this.controlText("Play"),this.$e.Ne=this.controlText())}se(){this.$e.Ne=this.controlText()}dispose(){this.$e.Ue(),this.xs.removeEventListener("ended",this.kh),super.dispose()}constructor(t,i){super(t,i),this.kh=()=>{this.controlText("Replay"),this.$e.Ne=this.controlText()},this.controlText("Play"),this.$e=new Do(this,this.controlText()),this.xs.addEventListener("ended",this.kh),this.on(t,"languagechange",this.se),rt.Zs.Ye&&new ko(this.el())}};so.registerComponent("playToggle",Aa);var Ma,Ia=so.getComponent("fullscreenToggle");!function(t){t.jh="Exit fullscreen",t.Sh="Fullscreen"}(Ma||(Ma={}));var Ea=class extends(wo(Ia)){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.$e.Ne=this.controlText()}dispose(){this.$e.Ue(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Fullscreen"),this.$e=new Do(this,this.controlText()),rt.Zs.Ye&&new ko(this.el()),this.on(t,"languagechange",this.updateContent)}};so.registerComponent("fullscreenToggle",Ea);var Da,Fa=so.getComponent("muteToggle");!function(t){t._h="Unmute",t.xh="Mute"}(Da||(Da={}));var Na=class extends(wo(Fa)){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.$e.Ne=this.controlText()}dispose(){this.$e.Ue(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Mute"),this.$e=new Do(this,this.controlText()),rt.Zs.Ye&&new ko(this.el()),this.on(t,"languagechange",this.se),Nt&&(this.removeClass("vjs-hidden"),this.on(t,"loadstart",(()=>{this.removeClass("vjs-hidden")})))}};so.registerComponent("muteToggle",Na);var $a=so.getComponent("BigPlayButton"),Ba=class extends(wo($a)){createEl(){let t=super.createEl(),i=so.createEl("div",{className:"theo-big-play-button-svg-container"});return i.innerHTML='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 150 150" fill="currentColor">\n <circle cx="75" cy="75" r="73" fill="#000" fill-opacity="0.2"></circle>\n <circle cx="75" cy="75" r="73" class="theo-play-svg-circle" stroke-width="4" stroke="currentColor" fill="none" transform="rotate(-90,75,75)"></circle>\n <g transform="translate(85,75) scale(0.5625) translate(-75,-75)">\n <path d="m 123.89639,85.432 c -12.865,9.167 -29.482997,19.402 -49.848997,30.7 -19.634,11.035 -36.851,19.7 -51.65,26 l -16.3990002,6.099 c -1.033,-4.433 -2,-11.002 -2.9,-19.7 -2.033,-17.333 -3.04999998,-36.466 -3.04999998,-57.399 0,-19.167 1.38199998,-37.081 4.14799998,-53.75 l 4.0019995,-19.1499994 17.3990007,5.849 c 15.068,5.9999994 31.401,14.5169994 49,25.5509994 18.631,11.666 34.616997,22.766 47.948997,33.3 6.663,5.3 11.463,9.383 14.396,12.25 l -13.046,10.25"></path>\n </g>\n</svg>',t.appendChild(i),t}buildCSSClass(){return"theo-primary-color "+super.buildCSSClass()}handleClick(t){this.xs.muted||this.xs.prepareWithUserAction(),super.handleClick(t),void 0!==this.xs.vr&&"unavailable"!==this.xs.vr.state&&(this.xs.vr.useDeviceMotionControls=!0)}};so.registerComponent("BigPlayButton",Ba);var Oa=/^([^#]*)#xywh=(\d+),(\d+),(\d+),(\d+)\s*$/;so.registerComponent("MouseTimeDisplay",class extends Zo{Th(t){const i=t.track;"removetrack"===t.type&&i===this.Ch?(this.Ch=void 0,this.Ph=void 0,this.Ah(),this.Mh=void 0):"addtrack"===t.type&&"metadata"===i.kind&&"thumbnails"===i.label&&(this.Ch=i,this.Ph=i.src?rt.Ih(i.src).href:void 0)}createEl(){const t=super.createEl();return this.Eh=so.createEl("img",{className:"theo-time-tooltip-thumbnail"}),this.Dh=so.createEl("canvas",{className:"theo-time-tooltip-thumbnail"}),t}update(t,i){if(super.update(t,i),!this.keepTooltipsInside)return;let s;if(this.Ch&&this.Ch.cues){let i=function(t,i){let s=t[0];for(let e of t)if(e.startTime<=i)s=e;else if(i>=e.endTime)return s;return s}(this.Ch.cues,t);s=i&&i.content}if(s===this.Mh)return;if(this.Mh=s,so.toggleClass(this.el(),"theo-time-tooltip-has-thumbnail",!!s),!s)return void this.Ah();const e=s.match(Oa);if(e){let[,t,i,s,n,r]=e;t=this.Fh(t);const h={Nh:+i,$h:+s,Ti:+n,Ci:+r};this.Bh(t,h)}else{const t=this.Fh(s);this.Bh(t)}}Fh(t){return this.Ch&&this.Ph?rt.Ih(t,this.Ph).href:t}Bh(t,i){this.Eh&&(this.Eh.src!==t?(this.Eh.onload=()=>{this.Oh(i)},this.Eh.src="",this.Eh.src=t):this.Oh(i))}Oh(t){if(!this.Dh||!this.Eh)return;const i=this.Dh.getContext("2d");i&&(t=t||{Nh:0,$h:0,Ti:this.Eh.naturalWidth,Ci:this.Eh.naturalHeight},this.Dh.width=t.Ti,this.Dh.height=t.Ci,i.drawImage(this.Eh,t.Nh,t.$h,t.Ti,t.Ci,0,0,t.Ti,t.Ci),this.Rh(this.Dh))}Rh(t){this.Uh||(this.tooltip.firstChild?this.tooltip.insertBefore(t,this.tooltip.firstChild):this.tooltip.appendChild(t),this.Uh=t)}Ah(){this.Uh&&this.tooltip.removeChild(this.Uh),ot.Ks&&(this.off(this.player(),"seeking",this.showThumbnails),this.off(this.player(),"seeked",this.hideThumbnails)),this.Uh=void 0}constructor(t,i){super(t,i),this.Uh=void 0,this.Ch=void 0,this.Ph=void 0,this.Vh=t=>this.Th(t),this.showThumbnails=()=>{this.Uh&&(this.Uh.hidden=!1)},this.hideThumbnails=()=>{this.Uh&&!this.player().scrubbing()&&(this.Uh.hidden=!0)},this.player().textTracks().on("addtrack",this.Vh),this.player().textTracks().on("removetrack",this.Vh),ot.Ks&&(this.on(t,"seeking",this.showThumbnails),this.on(t,"seeked",this.hideThumbnails))}});var Ra=so.getComponent("VolumeLevel");so.registerComponent("VolumeLevel",class extends Ra{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-volume-level "+super.buildCSSClass()}});var Ua=so.getComponent("Component"),Va=class extends Ua{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-menu-container "+super.buildCSSClass()}};Va.prototype.o=Rt({},Va.prototype.o,{children:[]}),so.registerComponent("controlBarMenuContainer",Va);var La=so.getComponent("Player"),Ha=class extends La{dispose(){const t=this.el(),i=this.contentEl(),s=t.parentNode,e=t.nextSibling;super.dispose(),kt(i),this._i&&s&&(e?s.insertBefore(t,e):s.appendChild(t)),u.body.removeEventListener("keydown",this.handleKeyPress),u.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")},u.body.addEventListener("keydown",this.handleKeyPress),u.body.addEventListener("click",this.handleClick)}};Ha.prototype.o=Rt({},La.prototype.o,{children:["bigPlayButton","AdControlPanel","TopControlBar","mediaLoader","upNextContainer","posterImage","chromecastOverlay","controlBarMenuContainer","controlBar","textTrackDisplay","loadingSpinner","errorDisplay","textTrackSettings","xrCompass"]}),so.registerComponent("Player",Ha);var za=so.getComponent("Player"),Wa=za.prototype.es;za.prototype.es=function(t){if(!(this.H&&this.H.Rs&&this.H.Rs()))return Wa.call(this,t)};var qa,Ga=za.prototype.createEl;function Xa(t,i,e,n){let r=Rt({controls:!0,playbackRates:[.25,.5,1,1.25,1.5,2]},e);r.controlBar=Rt({progressControl:{keepTooltipsInside:!0}},r.controlBar);let h=r.techOrder||(r.techOrder=[]);-1===h.indexOf("THEOplayer")&&h.unshift("THEOplayer"),(r.theoplayer||(r.theoplayer={})).player=t,e&&dt(e.language)&&(r.languages=Rt({},r.languages,{[P]:e.language}),r.language=P),i.setAttribute("data-vjs-player","");let o=i.getAttribute("style"),a=so(t.element,r,n);return a.ready((()=>{!function(t){t.on("timeupdate",co),t.on("durationchange",co)}(a),function(t,i){if(i){if(i.ads){const s=i=>{const s="adbreakbegin"===i.type,e=i.adBreak.integration===F.Lh;lo(t,s,e)};i.ads.addEventListener("adbreakbegin",s),i.ads.addEventListener("adbreakend",s)}if(i.verizonMedia){const s=i=>{const s="adbreakbegin"===i.type;lo(t,s,!1)};i.verizonMedia.ads.adBreaks.addEventListener("addadbreak",(t=>{t.adBreak.addEventListener("adbreakbegin",s),t.adBreak.addEventListener("adbreakend",s)}))}i.addEventListener("sourcechange",(()=>{lo(t,!1,!1)}))}}(a,t),function(t){t.on("mouseleave",fo)}(a)})),i.removeAttribute("data-vjs-player"),o?i.setAttribute("style",o):i.removeAttribute("style"),rt.Zs.Ks&&(xt(i,"theo-mobile"),function(t){let i=s.outerHeight,e=s.outerWidth;i>e?(Ct(t,"theo-mobile-landscape"),xt(t,"theo-mobile-portrait")):(Ct(t,"theo-mobile-portrait"),xt(t,"theo-mobile-landscape"))}(i)),function(t){t.on("seeking",(()=>{St(t.el(),"vjs-ended")&&t.currentTime()!==t.duration()&&t.play()}))}(a),a}function Qa(t){return class extends t{Hh(){return function(t,i){let s=w.create(t);const e=i.zh;return N(s,{get controls(){return e.controls()},set controls(t){e.controls(O(t))},get ui(){return e}})}(this.Wh,this)}fn(){super.fn(),this.zh.dispose()}qh(t){this.zh.src(""),super.qh(t)}constructor(t,i,s){super(i,s),this.Gh=t,this.Wh=super.Hh(),w.defineProperty(this.Wh,"constructor",{value:zt}),this.zh=Xa(this.Wh,this.Gh,s.ui)}}}function Ja(t){return(t=t||{}).position=function(t){switch(t){case"top-left":case"top-right":case"bottom-left":case"bottom-right":return t;default:return}}(t.position),t.visibility=function(t){if(ut(t)&&!_(t))return bt(t,0,1)}(t.visibility),t.retainPresentationModeOnSourceChange=O(t.retainPresentationModeOnSourceChange),t}function Ya(){return qa||(qa=function(t,i){let s=t;if(ei[i])for(const t of ei[i])s=t(s);return s}(qa=Qa(Lt()),h.t)),qa}function Ka(t,i){const s=function(t){const i=t=W(t);return i.ui=i.ui||{},void 0!==t.width&&void 0===i.ui.width&&(i.ui.width=t.width),void 0!==t.height&&void 0===i.ui.height&&(i.ui.height=t.height),void 0!==t.fluid&&void 0===i.ui.fluid&&(i.ui.fluid=t.fluid),i.pip=Ja(i.pip),i}(i),e=u.createElement("div");e.style.position="absolute",t.appendChild(e);const n=new(Ya())(t,e,s);let r=n.Xh;return n.Qh(),n.Jh(Ut),w.defineProperty(r,"constructor",{value:Ka}),r=D(r),Ot(n),function(t){for(const i of ri)i(t)}(n),r}function Za(t){return{get ratio(){return t.Yh},get thresholds(){return t.Kh.slice()}}}function tu(t){let i=[],s=k.floor(1/t);if(_(s))return[];for(let e=0;e<=s;e++){let s=bt(e*t,0,1);i.push(s)}return i}za.prototype.createEl=function(){let t=Ga.call(this),i=so.createEl("div");for(i.className="theo-player-wrapper";t.firstChild;)i.appendChild(t.firstChild);return t.appendChild(i),this.S=i,t};ni((function(t){return class extends t{Hh(){const t=this.Zh;return N(super.Hh(),{get visibility(){return t.Xh}})}fn(){this.Zh&&(this.Zh.fn(),this.Zh=void 0),super.fn()}constructor(t,i,e){super(t,i,e),this.Zh=new class{get io(){return this.so}get eo(){return this.no}set eo(t){if(_(t)||t<0||t>1)throw new RangeError("The threshold must be a value between 0 and 1");this.no=t}get Xh(){return this.ro||(this.ro=function(t){return{get ratio(){return t.io},get visible(){return t.io>t.eo},get visibleThreshold(){return t.eo},set visibleThreshold(i){i=R(i),t.eo=i},addObserver:(i,s)=>(i=R(i),t.ho(i,s).Xh),removeObserver(i){let s=t.oo(i);s&&t.ao(s)}}}(this)),this.ro}uo(t){return i=>{this.so=i,null==t||t(this.so)}}ho(t,i){if(_(t))throw new g("step is not of the right type");if(t>1||t<=0)throw new RangeError("The step must be a number greater than 0 and smaller than or equal to 1");let e;return e="function"==typeof s.IntersectionObserver?new class{get Yh(){return this.co}get Kh(){return this.lo}fo(t){return i=>{let s=i[i.length-1];this.co=s.intersectionRatio,t(s.intersectionRatio)}}get Xh(){return this.ro||(this.ro=Za(this)),this.ro}do(){this.vo.disconnect()}constructor(t,i,e){this.co=1,this.ro=void 0,this.lo=tu(i);let n=this.fo(e);this.vo=new s.IntersectionObserver(n,{root:null,threshold:this.lo}),this.vo.observe(t)}}(this.po,t,this.uo(i)):new class extends class{get Yh(){return this.co}get Kh(){return this.lo}get Xh(){return this.ro||(this.ro=Za(this)),this.ro}mo(t){this.co=t;let i=this.lo,s=0;if(t>0)for(;s<i.length&&i[s]<=t;)++s;this.yo!==s&&(this.yo=s,this.bo(t))}constructor(t,i){this.co=1,this.yo=-1,this.ro=void 0,this.lo=tu(t),this.bo=i}}{wo(){let t=this.po.getBoundingClientRect(),i=k.max(0,k.min(s.innerWidth,t.right)-k.max(0,t.left)),e=k.max(0,k.min(s.innerHeight,t.bottom)-k.max(0,t.top)),n=t.width*t.height;return bt(i*e/n,0,1)}do(){s.removeEventListener("scroll",this.ko)}constructor(t,i,e){super(i,e),this.ko=gt((()=>this.mo(this.wo())),50),this.po=t,s.addEventListener("scroll",this.ko,!!ht&&{passive:!0}),ii((()=>this.mo(this.wo())))}}(this.po,t,this.uo(i)),this.jo.push(e),e}ao(t){t.do(),Qt(this.jo,t)}oo(t){for(let i of this.jo)if(i.Xh===t)return i}fn(){for(let t of this.jo)t.do();Zt(this.jo)}constructor(t){this.so=1,this.no=0,this.jo=[],this.ro=void 0,this.po=t,this.ho(.1,this.uo())}}(t)}}}),h.t);var iu=so.getComponent("Button");var su="THEOPiPCloseButton";so.registerComponent(su,class extends iu{buildCSSClass(){return"theo-close-button theo-pip-close"}handleClick(){this._o.So()}constructor(t,i){if(super(t,i),this.controlText("Close Picture-in-Picture"),!function(t){return!!t&&Boolean(t._o)}(i))throw new m("Invalid Picture-in-picture options.");this._o=i._o}});var eu=class extends V{get xo(){return this.To}get Co(){return this.h.cs()}Po(){this.h.dn("play",this.Ao),this.Mo||this.h.dn("sourcechange",this.Io),this.h.zh.on("languagechange",this.se)}Eo(){let t=this.Do;if(t)return"theo-pip-"+t}Fo(t){let i=this.po;if(i&&!this.Co){this.No||this.$o(),this.Bo(),xt(i,"theo-pip");let s=this.Eo();s&&xt(i,s),this.To=!0,this.Oo=t,this.Ro=!1,this.Uo(new tt(it.PICTURE_IN_PICTURE))}}Vo(t){let i=this.po;if(i){this.Lo(),Ct(i,"theo-pip");let s=this.Eo();s&&Ct(i,s),this.To=!1,this.Ro=t,this.Ho=this.Oo,this.Oo=!1,this.Uo(new tt(it.INLINE))}}$o(){if(!this.No){let t=this.h.zh;t.addChild(su,{_o:this});let i=u.createElement("div");i.className="theo-pip-overlay",this.zo=u.createElement("div"),this.zo.className="theo-pip-overlay-text",$t(this.zo,t.localize("Video playing in Picture-in-Picture mode")),i.appendChild(this.zo),t.el().appendChild(i),this.Wo=i,this.No=!0}}qo(){this.Go&&!this.Xo&&this.h.Zh&&(this.Qo=this.h.Zh.ho(.1,this.Jo),this.Xo=!0)}Yo(){this.Qo&&this.h.Zh&&(this.h.Zh.ao(this.Qo),this.Xo=!1)}Bo(){let t=this.h.zh.contentEl(),i=t.getBoundingClientRect(),s=u.documentElement.clientWidth,e=u.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"}Lo(){let t=this.h.zh.contentEl();t.style.top="",t.style.bottom="",t.style.right="",t.style.left="",t.style.width="",t.style.height="",t.style.position=""}Ko(){Ct(this.po,"theo-pip"),this.xo&&this.Do&&Ct(this.po,"theo-pip-"+this.Do),this.Wo&&(kt(this.Wo),this.Wo=void 0)}fn(){this.Ko(),this.Yo(),this.Zo(),this.h.an("play",this.Ao),this.h.an("sourcechange",this.Io),this.h.zh.off("languagechange",this.se),this.h=void 0}constructor(t,i,s){super(),this.ta=!1,this.To=!1,this.Ro=!1,this.Oo=!1,this.No=!1,this.Xo=!1,this.Ho=!1,this.Ao=()=>{this.ta=!0,this.Go&&!this.xo&&this.Qo&&this.eo&&this.Qo.Yh<=this.eo&&this.Fo(!1)},this.Io=()=>{this.Mo||(this.ta=!1,this.Vo(!1))},this.se=()=>{if(this.zo){const t=this.h.zh;$t(this.zo,t.localize("Video playing in Picture-in-Picture mode"))}},this.Jo=t=>{!this.Oo&&this.Go&&(_(t)||(this.eo&&t<=this.eo||this.Ho?this.To||this.Ro||this.Fo(!1):this.To?this.Vo(!1):this.Ro=!1))},this.eo=i.visibility,this.Do=i.position,this.Mo=i.retainPresentationModeOnSourceChange,this.Go=void 0!==this.eo,this.h=t,this.po=t.Gh,this.So=s,this.Po()}},nu=class extends st{ia(){let t=super.ia();return t===it.INLINE&&this.sa&&this.sa.xo?it.PICTURE_IN_PICTURE:t}ea(t){switch(t){case it.PICTURE_IN_PICTURE:return!0;default:return super.ea(t)}}na(t,i){t===it.FULLSCREEN&&this.sa.Yo(),super.na(t,i),t!==it.FULLSCREEN&&this.sa.qo()}ra(t,i){t!==i&&(t===it.FULLSCREEN&&this.sa.Vo(!1),t===it.INLINE&&i===it.PICTURE_IN_PICTURE&&this.sa.Vo(!0),super.ra(t,i),t===it.PICTURE_IN_PICTURE&&(i===it.INLINE?this.sa.Fo(!0):this.sa.Fo(!1)))}fn(){super.fn(),this.sa.fn(),this.ha.an("play",this.oa),this.ha=void 0}constructor(t,i,s){super(i),this.aa=()=>this.zr(),this.So=()=>this.ua(it.INLINE),this.oa=()=>{this.ia()!==it.FULLSCREEN&&this.sa.qo(),this.ha.an("play",this.oa)},this.ha=t,this.sa=new eu(t,s.pip,this.So),this.sa.dn("presentationmodechange",this.aa),this.ha.dn("play",this.oa),this.zr()}},ru=class extends C{get ca(){return mt.la(this.zh.el())||this.zh.supportsFullScreen()}get cs(){return this.zh.isFullscreen()||this.fa}Fo(){this.zh.requestFullscreen()}Vo(){this.zh.exitFullscreen(),this.da.Vo()}fn(){this.Zo(),this.zh.off("fullscreenchange",this.va),this.da.an(Z.pa,this.va),this.da.an(Z.ma,this.Os),this.zh.isFullWindow&&this.zh.exitFullscreen()}constructor(t,i){super(),this.Us=!1,this.fa=!1,this.ga=!1,this.va=()=>{if(this.ga)return;let t=this.Us,i=this.cs;t!==i&&(this.Us=i,this.Uo(new ft))},this.ya=()=>{this.fa=this.da.cs,this.va()},this.ba=()=>{this.ga||(this.zh.isFullWindow&&this.zh.supportsFullScreen()||this.fa&&!this.zh.supportsFullScreen())&&(this.ga=!0,this.zh.exitFullscreen(),this.zh.requestFullscreen(),this.ga=!1,this.va())},this.zh=t,this.da=i,this.zh.on("fullscreenchange",this.va),this.da.dn(Z.pa,this.ya),this.da.dn(Z.wa,this.ba),this.da.dn(Z.ma,this.Os),this.va()}};ni((function(t){return class extends t{cs(){return"fullscreen"===this.ka.ia()}Hh(){let t=this.ka;return N(super.Hh(),{get presentation(){return t.Xh},get presentationMode(){return t.Xh.currentMode},set presentationMode(i){t.Xh.requestMode(i)}})}fn(){this.ka.fn(),this.ja.fn(),super.fn()}constructor(t,i,s){super(t,i,s),this.ja=new ru(this.zh,this.Sa),this.ka=new nu(this,this.ja,s),this.ka.dn("presentationmodechange",this.Os)}}}),h.t);var hu="theo-cast-",ou=so.getComponent("Button"),au=class extends(wo(ou)){get _a(){throw new m("xa")}get Ta(){return this.o.Ta}get Ca(){return this.o.Ca}buildCSSClass(){return hu+"button theo-"+this.Ca+"-button theo-controlbar-button "+super.buildCSSClass()}createEl(t,i,s){let e=super.createEl(),n=u.createElement("div");n.className="theo-button-icon-blur";let r=u.createElement("div");return r.className=hu+"svg-container",r.innerHTML=this.Ta,e.appendChild(n),e.appendChild(r),e}handleClick(t){var i;if(super.handleClick(t),this.Pa===et.AVAILABLE)null==(i=this._a)||i.start();else if(this.Pa===et.CONNECTED||this.Pa===et.CONNECTING){var s;null==(s=this._a)||s.stop()}}Aa(t){Ct(this.po,"theo-"+this.Ca+"-"+this.Pa),this.Pa=t,xt(this.po,"theo-"+this.Ca+"-"+this.Pa),this.se()}se(){this.Ma(this.Pa),this.$e.Ne=this.controlText()}Ma(t){t===et.CONNECTED?this.controlText("Stop Casting"):t===et.AVAILABLE?this.controlText("Start Casting"):t===et.CONNECTING?this.controlText("Connecting"):this.controlText("Unavailable")}constructor(t,i){var s;super(t,i),this.po=t.el(),this.Pa=et.UNAVAILABLE,this.controlText("Unavailable"),this.$e=new Do(this,this.controlText()),null==(s=this._a)||s.addEventListener("statechange",(t=>{const i=t;this.Aa(i.state)})),rt.Zs.Ye&&new ko(this.el()),this.Aa(this._a?this._a.state:et.UNAVAILABLE),this.on(t,"languagechange",this.se)}},uu=0;function cu(){const t='\n <svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 48 48" fill="currentColor">\n <defs>\n <clipPath id="theo-chromecast-rings-mask-'+uu+'">\n <path d="M0-36h44V0H0z"/>\n </clipPath>\n </defs>\n\t <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\t <path class="theo-chromecast-inner" d="M10 14h28v20H26.74A26 26 0 0 0 10 17.26z"/>\n <g class="theo-chromecast-rings" fill="none" stroke="currentColor" stroke-width="4" transform="translate(2 42)" clip-path="url(#theo-chromecast-rings-mask-'+uu+')">\n <circle stroke="none" cx="0" cy="0" r="30" />\n <circle class="theo-chromecast-ring theo-chromecast-ring1" stroke-width="6" cx="0" cy="0" r="3" />\n <circle class="theo-chromecast-ring theo-chromecast-ring2" cx="0" cy="0" r="12" />\n <circle class="theo-chromecast-ring theo-chromecast-ring3" cx="0" cy="0" r="20"/>\n <path class="theo-chromecast-ring theo-chromecast-ring4" stroke-linecap="round" d="M0-20A20 20 0 0 1 20 0" />\n </g>\n </svg>';return uu++,t}so.registerComponent("chromecastButton",class extends au{get _a(){var t;return null==(t=this.xs.cast)?void 0:t.chromecast}constructor(t,i){super(t,Rt({},i,{Ca:"chromecast",Ta:cu()}))}});var lu="theo-chromecast-",fu=so.getComponent("Component"),du=class t extends(wo(fu)){buildCSSClass(){return lu+"overlay "+super.buildCSSClass()}createEl(){let i=super.createEl();xt(i,lu+"overlay");let s=so.createEl("div",{className:lu+"status-icon",innerHTML:t.ICON_SVG}),e=so.createEl("div",{className:lu+"status-info"});$t(e,"Playing on");let n=so.createEl("div",{className:lu+"status-title"}),r=so.createEl("div",{className:lu+"status"});return this.$n=n,r.appendChild(s),r.appendChild(e),r.appendChild(n),i.appendChild(r),i}dispose(){var t;null==(t=this.Ia)||t.removeEventListener("statechange",this.update),this.Ia=void 0,this.xs.removeEventListener("play",this.update),super.dispose()}constructor(t,i){var s,e;super(t,i),this.update=()=>{this.Ia?(this.$n&&$t(this.$n,this.Ia.receiverName||""),this.Ia.state===et.CONNECTED?this.show():this.hide()):this.hide()},this.Ia=null==(s=this.xs.cast)?void 0:s.chromecast,null==(e=this.Ia)||e.addEventListener("statechange",this.update),this.xs.addEventListener("play",this.update),this.update()}};du.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>',so.registerComponent("chromecastOverlay",du);so.registerComponent("airplayButton",class extends au{dispose(){var t,i;null==(t=this.xs.ads)||t.removeEventListener("adbreakbegin",this.Ea),null==(i=this.xs.ads)||i.removeEventListener("adbreakend",this.Da),this.xs.removeEventListener("currentsourcechange",this.Da),super.dispose()}get _a(){var t;return null==(t=this.xs.cast)?void 0:t.airplay}constructor(t,i){var s,e;super(t,Rt({},i,{Ca:"airplay",Ta:'\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.Da=()=>{this.enable()},this.Ea=()=>{this.disable()},null==(s=this.xs.ads)||s.addEventListener("adbreakbegin",this.Ea),null==(e=this.xs.ads)||e.addEventListener("adbreakend",this.Da),this.xs.addEventListener("currentsourcechange",this.Da)}});var vu={Default:"","Monospaced Serif":wt.Fa,"Proportional Serif":wt.Na,"Monospaced Sans-Serif":wt.$a,"Proportional Sans-Serif":wt.Ba},pu={White:"#ffffff",Yellow:"#ffff00",Green:"#00ff00",Cyan:"#00ffff",Blue:"#0000ff",Magenta:"#ff00ff",Red:"#ff0000",Black:"#000000"},mu=[50,75,100,150,200];function gu(t){return{label:t+"%",value:t}}function yu(t){return w.keys(t).map((i=>({label:i,value:t[i]})))}mu.map((function(t){return{label:t+"%",value:t/100+"em"}}));var bu=mu.map((function(t){return{label:t+"%",value:t+"%"}})),wu=[25,50,75,100].map(gu),ku=[0,25,50,75,100].map(gu),ju=yu(pu),Su=yu(vu),_u=yu({None:"none","Drop Shadow":"dropshadow",Raised:"raised",Depressed:"depressed",Uniform:"uniform"}),xu=100,Tu="#000000",Cu="#FFFFFF",Pu="#000000",Au=class extends da{Oa(){let t=this.Pr.localize(this.Ra);$t(this.Ua.subMenu.menuHeader.el(),t),this.Cr=u.createElement("span"),this.Cr.className="theo-settings-control-menu-item-title",$t(this.Cr,t);let i=u.createElement("span");return i.className="theo-primary-color theo-settings-control-menu-item-value",xt(this.Ua.el(),"theo-subtitle-options-menu-item"),this.Ua.el().appendChild(this.Cr),this.Ua.el().appendChild(i),i}Va(t){const i=this.yr(t);i&&this.La(i)}Ha(){return this.cr}kr(t){this.za(t.br)}La(t){for(let t of this.mr.menuItems)t.selected(!1);t?(t.selected(!0),this.Wa(t.br.label)):this.Wa("Custom")}Wa(t){this.qa=t,$t(this.Ga,this.Pr.localize(t)),this.Ua.parentMenu.oe()}wr(t){let i=super.wr(t);return xt(i.el(),"theo-subtitle-options-menu-item"),this._r(i),i}_r(t){const i=this.Pr.localize(t.br.label);$t(t.el(),i);const s=this.Pr.localize("Set "+this.mr.menuHeader.el().textContent+" to "+t.br.label);t.el().setAttribute("aria-label",s)}Ue(){this.Pr.off("languagechange",this.se),super.Ue()}constructor(t,i,s,e){super(t.subMenu),this.Ua=t,this.Pr=e,this.qa="",this.se=()=>{let t=this.Pr.localize(this.Ra);$t(this.Ua.subMenu.menuHeader.el(),t),$t(this.Cr,t),this.Wa(this.qa);for(const t of this.gr)this._r(t)},this.Ra=i,this.za=s.aa,this.Ga=this.Oa(),this.cr=s.Xa,this.Pr.on("languagechange",this.se)}};var Mu=class extends da{Qa(){return{"Font family":{Xa:Iu(Su),aa:this.Ya.Ja},"Font color":{Xa:Iu(ju),aa:this.Ya.Ka},"Font opacity":{Xa:Iu(wu),aa:this.Ya.Za},"Font size":{Xa:Iu(bu),aa:this.Ya.tu},"Background color":{Xa:Iu(ju),aa:this.Ya.iu},"Background opacity":{Xa:Iu(ku),aa:this.Ya.su},"Window color":{Xa:Iu(ju),aa:this.Ya.eu},"Window opacity":{Xa:Iu(ku),aa:this.Ya.nu},"Character edge style":{Xa:Iu(_u),aa:this.Ya.ru}}}hu(){$t(this.mr.menuHeader.el(),this.Pr.localize("Subtitle Options")),this.Cr=u.createElement("span"),this.Cr.className="theo-settings-control-menu-item-title",$t(this.Cr,this.Pr.localize("Subtitle")),this.ou=u.createElement("span"),this.ou.className="theo-primary-color theo-settings-control-menu-item-value",$t(this.ou,this.Pr.localize("Options")),this.$r.el().appendChild(this.Cr),this.$r.el().appendChild(this.ou),this.$r.el().setAttribute("aria-label",this.Pr.localize("Open the subtitle options menu")),this.au.addEventListener(["addtrack","removetrack"],this.uu),this.uu()}wr(t){let i=this.mr.addSubMenuItem();return i.br=t,this.cu[t]=new Au(i,t,this.lu[t],this.Pr),i}_r(t){}kr(t){}Ue(){this.Pr.off("languagechange",this.se),super.Ue()}constructor(t,i,s,e){super(t.subMenu),this.$r=t,this.au=i,this.Pr=e,this.cu={},this.uu=()=>{this.au.some((t=>J(t.kind)))?this.$r.show():this.$r.hide()},this.se=()=>{$t(this.mr.menuHeader.el(),this.Pr.localize("Subtitle Options")),$t(this.Cr,this.Pr.localize("Subtitle")),$t(this.ou,this.Pr.localize("Options")),this.$r.el().setAttribute("aria-label",this.Pr.localize("Open the subtitle options menu"))},this.Ya=new class t{static fu(t,i,s,e){if(void 0!==t||void 0!==i)return Mt(void 0===t?s:t,void 0===i?e:i)}constructor(i){this.du=i,this.Ja=t=>{this.du.fontFamily=t.value},this.tu=t=>{this.du.fontSize=t.value},this.Za=i=>{this.vu=i.value,this.du.fontColor=t.fu(this.pu,this.vu,Cu,xu)},this.Ka=i=>{this.pu=i.value,this.du.fontColor=t.fu(this.pu,this.vu,Cu,xu)},this.iu=i=>{this.mu=i.value,this.du.backgroundColor=t.fu(this.mu,this.gu,Tu,xu)},this.su=i=>{this.gu=i.value,this.du.backgroundColor=t.fu(this.mu,this.gu,Tu,xu)},this.eu=i=>{this.yu=i.value,this.du.windowColor=t.fu(this.yu,this.bu,Pu,xu)},this.nu=i=>{this.bu=i.value,this.du.windowColor=t.fu(this.yu,this.bu,Pu,xu)},this.ru=t=>{this.du.edgeStyle=t.value}}}(s),this.lu=this.Qa(),this.cr=w.keys(this.lu),this.hu(),this.wu=new class{ku(t,i){const s=this.ju(t,i.Ha());s&&i.Va(s)}ju(t,i){return Gt(i,(i=>i.value===t))}Su(t,i,s){let e,n;if(void 0===t)e=this.ju(void 0,i.Ha()),n=this.ju(void 0,s.Ha());else if(t){let r=function(t){let i=Pt(t);if(i||(i=Pt(t.slice(0,t.length-1).replace("rgb","rgba")+",1)")),i||(i=jt(_t(t),1)),!i){let s=t.charAt(0).toUpperCase()+t.toLowerCase().slice(1);i=jt(_t(pu[s]),1)}return i}(t);if(r){let t=Tt(r),h=100*r._u;e=this.ju(t,i.Ha()),n=this.ju(h,s.Ha())}}e&&i.Va(e),n&&s.Va(n)}constructor(t,i){this.du=t,this.cu=i,this.xu=()=>{let t=this.du.fontFamily;this.ku(t,this.cu["Font family"]);let i=this.du.fontColor;this.Su(i,this.cu["Font color"],this.cu["Font opacity"]);let s=this.du.fontSize;this.ku(s,this.cu["Font size"]);let e=this.du.backgroundColor;this.Su(e,this.cu["Background color"],this.cu["Background opacity"]);let n=this.du.windowColor;this.Su(n,this.cu["Window color"],this.cu["Window opacity"]);let r=this.du.edgeStyle;this.ku(r,this.cu["Character edge style"])},this.du.addEventListener("change",this.xu),this.xu()}}(s,this.cu),this.Pr.on("languagechange",this.se)}};function Iu(t){let i=[{label:"Default",value:void 0}];for(let s of t)"Default"!==s.label&&i.push(s);return i}ni((function(t){return class extends t{fn(){this.Tu.removeMenuItem(this.Cu),super.fn()}constructor(t,i,s){super(t,i,s),this.Tu=this.zh.controlBar.getChild("SettingsButton").menu,this.Cu=this.Tu.addSubMenuItem({name:"TextTrackOptionsMenuItem"}),new Mu(this.Cu,this.nt.Xh,this.Pu.Xh,this.zh)}}}),h.t);export{zt as ChromelessPlayer,I as ErrorCategory,A as ErrorCode,Ka as Player,$ as cache,E as cast,Xt as features,Kt as playerSuiteVersion,ti as players,si as registerContentProtectionIntegration,qt as utils,Jt as version,so as videojs};
40
+ var h,r,a="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:void 0!==s?s:"undefined"!=typeof global?global:this,s=a.window,u=a.document,c=(a.location,a.navigator,a.setTimeout),v=a.clearTimeout,m=(a.setInterval,a.clearInterval,a.Error),g=a.TypeError,b=a.SyntaxError,k=a.Object,w=a.Math,j=a.parseInt,S=a.parseFloat,_=a.isNaN,x=a.Uint8Array;a.Worker,a.WorkerGlobalScope,a.XMLHttpRequest;import{$ as T,A as C,Aa as P,B as A,Ba as M,C as I,Ca as E,D,Da as F,E as N,Ea as $,F as B,G as O,H as R,I as U,J as V,K as L,L as H,M as z,N as W,O as q,P as G,Q as X,R as Q,S as J,T as Y,U as K,V as Z,W as tt,X as it,Y as st,Z as et,_ as nt,a as rt,aa as ht,b as ot,ba as at,c as ut,ca as ct,d as lt,da as ft,e as dt,ea as vt,f as pt,fa as mt,g as gt,ga as yt,h as bt,ha as kt,i as wt,ia as jt,j as St,ja as _t,k as xt,ka as Tt,l as Ct,la as Pt,m as At,ma as Mt,n as It,na as Et,o as Dt,oa as Ft,p as Nt,pa as $t,q as Bt,qa as Ot,r as Rt,ra as Ut,s as Vt,sa as Lt,t as Ht,ta as zt,u as Wt,ua as qt,v as Gt,va as Xt,w as Qt,wa as Jt,x as Yt,xa as Kt,y as Zt,ya as ti,z as ii,za as si}from"./THEOplayer.common.esm.js";(r=h||(h={}))[r.t=0]="t";var ei={};function ni(t,i){(ei[i]||(ei[i]=[])).push(t)}var ri=[];var o=void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},t=void 0!==u?u:{createElement:function(){}};function hi(t,i){return i||(i=t.slice(0)),t.raw=i,t}var oi=1;function ai(){return oi++}var ui,ci=k.prototype.toString,li=function(t){return vi(t)?k.keys(t):[]};function fi(t,i){li(t).forEach((function(s){return i(t[s],s)}))}function di(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 k.assign?k.assign.apply(k,[t].concat(s)):(s.forEach((function(i){i&&fi(i,(function(i,s){t[s]=i}))})),t)}function vi(t){return!!t&&"object"==typeof t}function pi(t){return vi(t)&&"[object Object]"===ci.call(t)&&t.constructor===k}var mi=function(t,i,s){void 0===s&&(s=!!vs&&vs<11),"log"!==t&&i.unshift(t.toUpperCase()+":"),ui.history.push(i),i.unshift("VIDEOJS:");var e=o.console&&o.console[t];e&&(s&&(i=i.map((function(t){if(vi(t)||Array.isArray(t))try{return JSON.stringify(t)}catch(i){return String(t)}return String(t)})).join(" ")),e.apply?e[Array.isArray(i)?"apply":"call"](o.console,i):e(i))};(ui=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];mi("log",i)}).history=[],ui.error=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return mi("error",i)},ui.warn=function(){for(var t=arguments.length,i=new Array(t),s=0;s<t;s++)i[s]=arguments[s];return mi("warn",i)};var gi=ui,yi="undefined"!=typeof globalThis?globalThis:void 0!==s?s:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function bi(t){return t.replace(/\n\r?\s*/g,"")}var ki,wi=function(t){for(var i="",s=0;s<arguments.length;s++)i+=bi(t[s])+(arguments[s+1]||"");return i};function ji(t){return"string"==typeof t&&/\S/.test(t)}function Si(t){if(/\s/.test(t))throw new m("class has illegal whitespace characters")}function _i(){return t===o.document&&void 0!==t.createElement}function xi(t){return vi(t)&&1===t.nodeType}function Ti(i){return function(s,e){if(!ji(s))return t[i](null);ji(e)&&(e=t.querySelector(e));var n=xi(e)?e:t;return n[i]&&n[i](s)}}function Ci(i,s,e,n){void 0===i&&(i="div"),void 0===s&&(s={}),void 0===e&&(e={});var r=t.createElement(i);return k.getOwnPropertyNames(s).forEach((function(t){var i=s[t];-1!==t.indexOf("aria-")||"role"===t||"type"===t?(gi.warn(wi(ki||(ki=hi(["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,i)),r.setAttribute(t,i)):"textContent"===t?Pi(r,i):r[t]=i})),k.getOwnPropertyNames(e).forEach((function(t){r.setAttribute(t,e[t])})),n&&Gi(r,n),r}function Pi(t,i){return void 0===t.textContent?t.innerText=i:t.textContent=i,t}function Ai(t,i){i.firstChild?i.insertBefore(t,i.firstChild):i.appendChild(t)}var Mi={},Ii="vdata"+(new Date).getTime();function Ei(t){var i=t[Ii];return i||(i=t[Ii]=ai()),Mi[i]||(Mi[i]={}),Mi[i]}function Di(t){var i=t[Ii];return!!i&&!!k.getOwnPropertyNames(Mi[i]).length}function Fi(t){var i=t[Ii];if(i){delete Mi[i];try{delete t[Ii]}catch(i){t.removeAttribute?t.removeAttribute(Ii):t[Ii]=null}}}function Ni(t,i){return Si(i),t.classList?t.classList.contains(i):function(t){return new RegExp("(^|\\s)"+t+"($|\\s)")}(i).test(t.className)}function $i(t,i){return t.classList?t.classList.add(i):Ni(t,i)||(t.className=(t.className+" "+i).trim()),t}function Bi(t,i){return t.classList?t.classList.remove(i):(Si(i),t.className=t.className.split(/\s+/).filter((function(t){return t!==i})).join(" ")),t}function Oi(t,i,s){var e=Ni(t,i);if("function"==typeof s&&(s=s(t,i)),"boolean"!=typeof s&&(s=!e),s!==e)return s?$i(t,i):Bi(t,i),t}function Ri(t,i){k.getOwnPropertyNames(i).forEach((function(s){var e=i[s];null==e||!1===e?t.removeAttribute(s):t.setAttribute(s,!0===e?"":e)}))}function Ui(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 Vi(t,i,s){t.setAttribute(i,s)}function Li(t,i){t.removeAttribute(i)}function Hi(i){var s;if(i.getBoundingClientRect&&i.parentNode&&(s=i.getBoundingClientRect()),!s)return{left:0,top:0};var e=t.documentElement,n=t.body,r=e.clientLeft||n.clientLeft||0,h=o.pageXOffset||n.scrollLeft,a=s.left+h-r,u=e.clientTop||n.clientTop||0,c=o.pageYOffset||n.scrollTop,l=s.top+c-u;return{left:w.round(a),top:w.round(l)}}function zi(t,i){var s={},e=Hi(t),n=t.offsetWidth,r=t.offsetHeight,h=e.top,o=e.left,a=i.pageY,u=i.pageX;return i.changedTouches&&(u=i.changedTouches[0].pageX,a=i.changedTouches[0].pageY),s.y=w.max(0,w.min(1,(h-a+r)/r)),s.x=w.max(0,w.min(1,(u-o)/n)),s}function Wi(t){return vi(t)&&3===t.nodeType}function qi(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function Gi(i,s){return function(i){return"function"==typeof i&&(i=i()),(Array.isArray(i)?i:[i]).map((function(i){return"function"==typeof i&&(i=i()),xi(i)||Wi(i)?i:"string"==typeof i&&/\S/.test(i)?t.createTextNode(i):void 0})).filter((function(t){return t}))}(s).forEach((function(t){return i.appendChild(t)})),i}function Xi(t,i){return Gi(qi(t),i)}var Qi=Ti("querySelector"),Ji=Ti("querySelectorAll"),Yi=o.navigator&&o.navigator.userAgent||"",Ki=/AppleWebKit\/([\d.]+)/i.exec(Yi),Zi=Ki?S(Ki.pop()):null,ts=/iPad/i.test(Yi),is=/iPhone/i.test(Yi)&&!ts,ss=/iPod/i.test(Yi),es=is||ts||ss,ns=function(){var t=Yi.match(/OS (\d+)_/i);return t&&t[1]?t[1]:null}(),rs=/Android/i.test(Yi),hs=function(){var t=Yi.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!t)return null;var i=t[1]&&S(t[1]),s=t[2]&&S(t[2]);return i&&s?S(t[1]+"."+t[2]):i||null}(),os=rs&&/webkit/i.test(Yi)&&hs<2.3,as=rs&&hs<5&&Zi<537,us=/Firefox/i.test(Yi),cs=/Edge/i.test(Yi),ls=!cs&&/Chrome/i.test(Yi),fs=function(){var t=Yi.match(/Chrome\/(\d+)/);return t&&t[1]?S(t[1]):null}(),ds=/MSIE\s8\.0/.test(Yi),vs=function(){var t=/MSIE\s(\d+)\.\d/.exec(Yi),i=t&&S(t[1]);return!i&&/Trident\/7.0/i.test(Yi)&&/rv:11.0/.test(Yi)&&(i=11),i}(),ps=/Safari/i.test(Yi)&&!ls&&!rs&&!cs,ms=ps||es,gs=_i()&&("ontouchstart"in o||o.DocumentTouch&&o.document instanceof o.DocumentTouch),ys=_i()&&"backgroundSize"in o.document.createElement("video").style,bs=k.freeze({__proto__:null,IS_IPAD:ts,IS_IPHONE:is,IS_IPOD:ss,IS_IOS:es,IOS_VERSION:ns,IS_ANDROID:rs,ANDROID_VERSION:hs,IS_OLD_ANDROID:os,IS_NATIVE_ANDROID:as,IS_FIREFOX:us,IS_EDGE:cs,IS_CHROME:ls,CHROME_VERSION:fs,IS_IE8:ds,IE_VERSION:vs,IS_SAFARI:ps,IS_ANY_SAFARI:ms,TOUCH_ENABLED:gs,BACKGROUND_SIZE_SUPPORTED:ys});function ks(t,i){var s=Ei(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)),k.getOwnPropertyNames(s.handlers).length<=0&&(delete s.handlers,delete s.dispatcher,delete s.disabled),0===k.getOwnPropertyNames(s).length&&Fi(t)}function ws(t,i,s,e){s.forEach((function(s){t(i,s,e)}))}function js(i){function s(){return!0}function e(){return!1}if(!i||!i.isPropagationStopped||!i.isImmediatePropagationStopped){var n=i||o.event;for(var r in i={},n)"layerX"!==r&&"layerY"!==r&&"keyLocation"!==r&&"webkitMovementX"!==r&&"webkitMovementY"!==r&&"path"!==r&&("returnValue"===r&&n.preventDefault||(i[r]=n[r]));if(i.target||(i.target=i.srcElement||t),i.relatedTarget||(i.relatedTarget=i.fromElement===i.target?i.toElement:i.fromElement),i.preventDefault=function(){n.preventDefault&&n.preventDefault(),i.returnValue=!1,n.returnValue=!1,i.defaultPrevented=!0},i.defaultPrevented=!1,i.stopPropagation=function(){n.stopPropagation&&n.stopPropagation(),i.cancelBubble=!0,n.cancelBubble=!0,i.isPropagationStopped=s},i.isPropagationStopped=e,i.stopImmediatePropagation=function(){n.stopImmediatePropagation&&n.stopImmediatePropagation(),i.isImmediatePropagationStopped=s,i.stopPropagation()},i.isImmediatePropagationStopped=e,null!==i.clientX&&void 0!==i.clientX){var h=t.documentElement,a=t.body;i.pageX=i.clientX+(h&&h.scrollLeft||a&&a.scrollLeft||0)-(h&&h.clientLeft||a&&a.clientLeft||0),i.pageY=i.clientY+(h&&h.scrollTop||a&&a.scrollTop||0)-(h&&h.clientTop||a&&a.clientTop||0)}i.which=i.charCode||i.keyCode,null!==i.button&&void 0!==i.button&&(i.button=1&i.button?0:4&i.button?1:2&i.button?2:0)}return i}var Ss=!1;!function(){try{var t=k.defineProperty({},"passive",{get:function(){Ss=!0}});o.addEventListener("test",null,t)}catch(t){}}();var _s=["touchstart","touchmove"];function xs(t,i,s){if(Array.isArray(i))return ws(xs,t,i,s);var e=Ei(t);if(e.handlers||(e.handlers={}),e.handlers[i]||(e.handlers[i]=[]),s.guid||(s.guid=ai()),e.handlers[i].push(s),e.dispatcher||(e.disabled=!1,e.dispatcher=function(i,s){if(!e.disabled){i=js(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){gi.error(t)}}}),1===e.handlers[i].length)if(t.addEventListener){var n=!1;Ss&&_s.indexOf(i)>-1&&(n={passive:!0}),t.addEventListener(i,e.dispatcher,n)}else t.attachEvent&&t.attachEvent("on"+i,e.dispatcher)}function Ts(t,i,s){if(Di(t)){var e=Ei(t);if(e.handlers){if(Array.isArray(i))return ws(Ts,t,i,s);var n=function(i){e.handlers[i]=[],ks(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);ks(t,i)}else n(i)}else for(var o in e.handlers)n(o)}}}function Cs(t,i,s){var e=Di(t)?Ei(t):{},n=t.parentNode||t.ownerDocument;if("string"==typeof i&&(i={type:i,target:t}),i=js(i),e.dispatcher&&e.dispatcher.call(t,i,s),n&&!i.isPropagationStopped()&&!0===i.bubbles)Cs.call(null,n,i,s);else if(!n&&!i.defaultPrevented){var r=Ei(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 Ps(t,i,s){if(Array.isArray(i))return ws(Ps,t,i,s);var e=function e(){Ts(t,i,e),s.apply(this,arguments)};e.guid=s.guid=s.guid||ai(),xs(t,i,e)}var As,Ms=!1,Is=function(){if(_i()){var i=t.getElementsByTagName("video"),s=t.getElementsByTagName("audio"),e=[];if(i&&i.length>0)for(var n=0,r=i.length;n<r;n++)e.push(i[n]);if(s&&s.length>0)for(var h=0,o=s.length;h<o;h++)e.push(s[h]);if(e&&e.length>0)for(var a=0,u=e.length;a<u;a++){var c=e[a];if(!c||!c.getAttribute){Es(1);break}void 0===c.player&&null!==c.getAttribute("data-setup")&&As(c)}else Ms||Es(1)}};function Es(t,i){i&&(As=i),o.setTimeout(Is,t)}_i()&&"complete"===t.readyState?Ms=!0:Ps(o,"load",(function(){Ms=!0}));var Ds=function(i){var s=t.createElement("style");return s.className=i,s},Fs=function(t,i){t.styleSheet?t.styleSheet.cssText=i:t.textContent=i},Ns=function(t,i,s){i.guid||(i.guid=ai());var e=function(){return i.apply(t,arguments)};return e.guid=s?s+"_"+i.guid:i.guid,e};function $s(t){return"string"!=typeof t?t:t.charAt(0).toUpperCase()+t.slice(1)}function Bs(){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&&fi(i,(function(i,s){pi(i)?(pi(t[s])||(t[s]={}),t[s]=Bs(t[s],i)):t[s]=i}))})),t}var i=function(){function t(t,i,s){if(!t&&this.play?this.h=t=this:this.h=t,this.o=Bs({},this.o),i=this.o=Bs(this.o,i),this.u=i.id||i.el&&i.el.id,!this.u){var e=t&&t.id&&t.id()||"no_player";this.u=e+"l"+ai()}this.v=i.name||null,i.el?this.m=i.el:!1!==i.createEl&&(this.m=this.createEl()),this.k=[],this.j={},this.S={},!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.k)for(var t=this.k.length-1;t>=0;t--)this.k[t].dispose&&this.k[t].dispose();this.k=null,this.j=null,this.S=null,this.off(),this.m.parentNode&&this.m.parentNode.removeChild(this.m),Fi(this.m),this.m=null},i.player=function(){return this.h},i.options=function(t){return gi.warn("this.options() has been deprecated and will be moved to the constructor in 6.0"),t?(this.o=Bs(this.o,t),this.o):this.o},i.el=function(){return this.m},i.createEl=function(t,i,s){return Ci(t,i,s)},i.localize=function(t){var i=this.h.language&&this.h.language(),s=this.h.languages&&this.h.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.T||this.m},i.id=function(){return this.u},i.name=function(){return this.v},i.children=function(){return this.k},i.getChildById=function(t){return this.j[t]},i.getChild=function(t){if(t)return t=$s(t),this.S[t]},i.addChild=function(i,s,e){var n,r;if(void 0===s&&(s={}),void 0===e&&(e=this.k.length),"string"==typeof i){r=$s(i),s||(s={}),!0===s&&(gi.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.h||this,s)}else n=i;if(this.k.splice(e,0,n),"function"==typeof n.id&&(this.j[n.id()]=n),(r=r||n.name&&$s(n.name()))&&(this.S[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.k){for(var i=!1,s=this.k.length-1;s>=0;s--)if(this.k[s]===t){i=!0,this.k.splice(s,1);break}if(i){this.j[t.id()]=null,this.S[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.o.children;if(s){var e,n=this.o,r=t.getComponent("Tech");(e=Array.isArray(s)?s:k.keys(s)).concat(k.keys(this.o).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.o[e]||{}:(e=t.name,n=t),{name:e,opts:n}})).filter((function(i){var s=t.getComponent(i.opts.componentClass||$s(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.o.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))xs(this.m,t,Ns(this,i));else{var n=t,r=i,h=Ns(this,s),o=function(){return e.off(n,r,h)};o.guid=h.guid,this.on("dispose",o);var a=function(){return e.off("dispose",o)};a.guid=h.guid,t.nodeName?(xs(n,r,h),xs(n,"dispose",a)):"function"==typeof t.on&&(n.on(r,h),n.on("dispose",a))}return this},i.off=function(t,i,s){if(!t||"string"==typeof t||Array.isArray(t))Ts(this.m,t,i);else{var e=t,n=i,r=Ns(this,s);this.off("dispose",r),t.nodeName?(Ts(e,n,r),Ts(e,"dispose",r)):(e.off(n,r),e.off("dispose",r))}return this},i.one=function(t,i,s){var e=arguments,n=this;if("string"==typeof t||Array.isArray(t))Ps(this.m,t,Ns(this,i));else{var r=t,h=i,o=Ns(this,s),a=function t(){n.off(r,h,t),o.apply(null,e)};a.guid=o.guid,this.on(r,h,a)}return this},i.trigger=function(t,i){return Cs(this.m,t,i),this},i.ready=function(t,i){return void 0===i&&(i=!1),t&&(this.C?i?t.call(this):this.setTimeout(t,1):(this.P=this.P||[],this.P.push(t))),this},i.triggerReady=function(){this.C=!0,this.setTimeout((function(){var t=this.P;this.P=[],t&&t.length>0&&t.forEach((function(t){t.call(this)}),this),this.trigger("ready")}),1)},i.$=function(t,i){return Qi(t,i||this.contentEl())},i.$$=function(t,i){return Ji(t,i||this.contentEl())},i.hasClass=function(t){return Ni(this.m,t)},i.addClass=function(t){return $i(this.m,t),this},i.removeClass=function(t){return Bi(this.m,t),this},i.toggleClass=function(t,i){return Oi(this.m,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.m,t)},i.setAttribute=function(t,i){return Vi(this.m,t,i),this},i.removeAttribute=function(t){return Li(this.m,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.m.style[t]=i:this.m.style[t]="auto"===i?"":i+"px",s||this.trigger("resize"),this;if(!this.m)return 0;var e=this.m.style[t],n=e.indexOf("px");return j(-1!==n?e.slice(0,n):this.m["offset"+$s(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 o.getComputedStyle){var s=o.getComputedStyle(this.m);i=s.getPropertyValue(t)||s[t]}if(0===(i=S(i))){var e="offset"+$s(t);i=this.m[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.m.focus()},i.blur=function(){this.m.blur()},i.emitTapEvents=function(){var t,i=0,s=null;this.on("touchstart",(function(e){1===e.touches.length&&(s={pageX:e.touches[0].pageX,pageY:e.touches[0].pageY},i=(new Date).getTime(),t=!0)})),this.on("touchmove",(function(i){if(i.touches.length>1)t=!1;else if(s){var e=i.touches[0].pageX-s.pageX,n=i.touches[0].pageY-s.pageY;w.sqrt(e*e+n*n)>10&&(t=!1)}}));var e=function(){t=!1};this.on("touchleave",e),this.on("touchcancel",e),this.on("touchend",(function(e){(s=null,!0===t)&&((new Date).getTime()-i<200&&(e.preventDefault(),this.trigger("tap")))}))},i.enableTouchActivity=function(){if(this.player()&&this.player().reportUserActivity){var t,i=Ns(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=Ns(this,t);var s=o.setTimeout(t,i),e=function(){this.clearTimeout(s)};return e.guid="vjs-timeout-"+s,this.on("dispose",e),s},i.clearTimeout=function(t){o.clearTimeout(t);var i=function(){};return i.guid="vjs-timeout-"+t,this.off("dispose",i),t},i.setInterval=function(t,i){t=Ns(this,t);var s=o.setInterval(t,i),e=function(){this.clearInterval(s)};return e.guid="vjs-interval-"+s,this.on("dispose",e),s},i.clearInterval=function(t){o.clearInterval(t);var i=function(){};return i.guid="vjs-interval-"+t,this.off("dispose",i),t},t.registerComponent=function(i,s){if(i){if(i=$s(i),t.A||(t.A={}),"Player"===i&&t.A[i]){var e=t.A[i];if(e.players&&k.keys(e.players).length>0&&k.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.A[i]=s,s}},t.getComponent=function(i){if(i)return i=$s(i),t.A&&t.A[i]?t.A[i]:o&&o.videojs&&o.videojs[i]?(gi.warn("The "+i+" component was added to the videojs object when it should be registered using videojs.registerComponent(name, component)"),o.videojs[i]):void 0},t.extend=function(i){i=i||{},gi.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=k.create(this.prototype)).constructor=e,e.extend=t.extend,i)i.hasOwnProperty(n)&&(e.prototype[n]=i[n]);return e},t}();i.registerComponent("Component",i);var Os=function(){};function Rs(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Us(t,i){return(Us=k.setPrototypeOf?k.setPrototypeOf.bind():function(t,i){return t.__proto__=i,t})(t,i)}function Vs(t,i){t.prototype=k.create(i.prototype),t.prototype.constructor=t,Us(t,i)}function Ls(t,i,s,e){return void 0===e&&(gi.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 Hs(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:Ls.bind(null,"start",0,t),end:Ls.bind(null,"end",1,t)}}function zs(t,i){return Array.isArray(t)?Hs(t):void 0===t||void 0===i?Hs():Hs([[t,i]])}function Ws(t,i){var s,e,n=0;if(!i)return 0;t&&t.length||(t=zs(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}Os.prototype.M={},Os.prototype.on=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},xs(this,t,i),this.addEventListener=s},Os.prototype.addEventListener=Os.prototype.on,Os.prototype.off=function(t,i){Ts(this,t,i)},Os.prototype.removeEventListener=Os.prototype.off,Os.prototype.one=function(t,i){var s=this.addEventListener;this.addEventListener=function(){},Ps(this,t,i),this.addEventListener=s},Os.prototype.trigger=function(t){var i=t.type||t;"string"==typeof t&&(t={type:i}),t=js(t),this.M[i]&&this["on"+i]&&this["on"+i](t),Cs(this,t)},Os.prototype.dispatchEvent=Os.prototype.trigger;var qs,Gs,Xs,Qs,Js={prefixed:!0},Ys=[["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"]],Ks=Ys[0];for(Gs=0;Gs<Ys.length;Gs++)if(Ys[Gs][1]in t){qs=Ys[Gs];break}if(qs){for(Xs=0;Xs<qs.length;Xs++)Js[Ks[Xs]]=qs[Xs];Js.prefixed=qs[0]!==Ks[0]}function Zs(t){if(t instanceof Zs)return t;"number"==typeof t?this.code=t:"string"==typeof t?this.message=t:vi(t)&&("number"==typeof t.code&&(this.code=t.code),di(this,t)),this.message||(this.message=Zs.defaultMessages[this.code]||"")}for(Zs.prototype.code=0,Zs.prototype.message="",Zs.prototype.status=null,Zs.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],Zs.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."},Qs=0;Qs<Zs.errorTypes.length;Qs++)Zs[Zs.errorTypes[Qs]]=Qs,Zs.prototype[Zs.errorTypes[Qs]]=Qs;var te=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}}))})},se=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))},ee=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()},ne="vjs-modal-dialog",re=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).I=e.D=e.F=!1,e.closeable(!e.o.uncloseable),e.content(e.o.content),e.T=Ci("div",{className:ne+"-content"},{role:"document"}),e.N=Ci("p",{className:ne+"-description vjs-offscreen",id:e.el().getAttribute("aria-describedby")}),Pi(e.N,e.description()),e.m.appendChild(e.N),e.m.appendChild(e.T),e.on(i,"languagechange",e.handleLanguagechange),e}Vs(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()+"B","aria-hidden":"true","aria-label":this.label(),role:"dialog"})},s.buildCSSClass=function(){return ne+" vjs-hidden "+t.prototype.buildCSSClass.call(this)},s.handleKeyPress=function(t){27===t.which&&this.closeable()&&this.close()},s.label=function(){return this.o.label||this.localize("Modal Window")},s.description=function(){var t=this.o.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.I){var t=this.player();this.trigger("beforemodalopen"),this.I=!0,(this.o.fillAlways||!this.D&&!this.F)&&this.fill(),this.O=!t.paused(),this.o.pauseOnOpen&&this.O&&t.pause(),this.closeable()&&this.on(this.m.ownerDocument,"keydown",Ns(this,this.handleKeyPress)),t.controls(!1),this.show(),this.el().setAttribute("aria-hidden","false"),this.trigger("modalopen"),this.D=!0}return this},s.opened=function(t){return"boolean"==typeof t&&this[t?"open":"close"](),this.I},s.close=function(){if(this.I){var t=this.player();this.trigger("beforemodalclose"),this.I=!1,this.O&&this.o.pauseOnOpen&&t.play(),this.closeable()&&this.off(this.m.ownerDocument,"keydown",Ns(this,this.handleKeyPress)),t.controls(!0),this.hide(),this.el().setAttribute("aria-hidden","true"),this.trigger("modalclose"),this.o.temporary&&this.dispose()}return this},s.closeable=function(t){if("boolean"==typeof t){var i=this.R=!!t,s=this.getChild("closeButton");if(i&&!s){var e=this.T;this.T=this.m,s=this.addChild("closeButton",{controlText:"Close Modal Dialog"}),this.T=e,this.on(s,"close",this.close)}!i&&s&&(this.off(s,"close",this.close),this.removeChild(s),s.dispose())}return this.R},s.fill=function(){return this.fillWith(this.content())},s.fillWith=function(t){var i=this.contentEl(),s=i.parentNode,e=i.nextSibling;return this.trigger("beforemodalfill"),this.F=!0,s.removeChild(i),this.empty(),Xi(i,t),this.trigger("modalfill"),e?s.insertBefore(i,e):s.appendChild(i),this},s.empty=function(){return this.trigger("beforemodalempty"),qi(this.contentEl()),this.trigger("modalempty"),this},s.content=function(t){return void 0!==t&&(this.U=t),this.U},s.handleLanguagechange=function(){this.m.setAttribute("aria-label",this.label()),Pi(this.N,this.description()),this.opened()?this.fill():(this.D||this.F)&&(this.D=!1,this.F=!1,this.empty())},i}(i);re.prototype.o={pauseOnOpen:!0,temporary:!0},i.registerComponent("ModalDialog",re);var he=function(){function i(s){var e=this;if(ds)for(var n in e=t.createElement("custom"),i.prototype)"constructor"!==n&&(e[n]=i.prototype[n]);if(i.prototype.V.call(e,s),k.defineProperty(e,"length",{get:function(){return this.L}}),ds)return e}var s=i.prototype;return s.V=function(t){var i=this.length||0,s=0,e=t.length;this.H=t,this.L=t.length;var n=function(t){""+t in this||k.defineProperty(this,""+t,{get:function(){return this.H[t]}})};if(i<e)for(s=i;s<e;s++)n.call(this,s)},s.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},i}(),oe={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},ae={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},ue={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},ce={disabled:"disabled",hidden:"hidden",showing:"showing"},le=function(i){function s(e){var n;void 0===e&&(e={});var r=Rs(n=i.call(this)||this);if(ds)for(var h in r=t.createElement("custom"),s.prototype)"constructor"!==h&&(r[h]=s.prototype[h]);var o={id:e.id||["vjs_track",ai()].join("_"),kind:e.kind||"",label:e.label||"",language:e.language||""},a=function(t){k.defineProperty(r,t,{get:function(){return o[t]},set:function(){}})};for(var u in o)a(u);return r||Rs(n)}return Vs(s,i),s}(Os),fe=function(i){var s=["protocol","hostname","port","pathname","search","hash","host"],e=t.createElement("a");e.href=i;var n,r=""===e.host&&"file:"!==e.protocol;r&&((n=t.createElement("div")).innerHTML='<a href="'+i+'"></a>',e=n.firstChild,n.setAttribute("style","display:none; position:absolute;"),t.body.appendChild(n));for(var h={},o=0;o<s.length;o++)h[s[o]]=e[s[o]];return"http:"===h.protocol&&(h.host=h.host.replace(/:80$/,"")),"https:"===h.protocol&&(h.host=h.host.replace(/:443$/,"")),r&&t.body.removeChild(n),h},de=function(t){var i=o.location,s=fe(t);return(":"===s.protocol?i.protocol:s.protocol)+s.host!==i.protocol+i.host},ve={exports:{}};void 0!==s?ve.exports=s:void 0!==yi?ve.exports=yi:"undefined"!=typeof self?ve.exports=self:ve.exports={};var pe=function(t){var i=me.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)},me=k.prototype.toString;var ge,ye,be,ke,we,je,Se,_e,xe,Te,Ce,Pe,Ae=Array.prototype.slice,Me=k.prototype.toString,Ie=function(t){var i=this;if("function"!=typeof i||"[object Function]"!==Me.call(i))throw new g("Function.prototype.bind called on incompatible "+i);for(var s,e=Ae.call(arguments,1),n=w.max(0,i.length-e.length),r=[],h=0;h<n;h++)r.push("$"+h);if(s=Function("binder","return function ("+r.join(",")+"){ return binder.apply(this,arguments); }")((function(){if(this instanceof s){var n=i.apply(this,e.concat(Ae.call(arguments)));return k(n)===n?n:this}return i.apply(t,e.concat(Ae.call(arguments)))})),i.prototype){var o=function(){};o.prototype=i.prototype,s.prototype=new o,o.prototype=null}return s},Ee=Function.prototype.bind||Ie,De=k.prototype.toString,Fe=function(t){var i=De.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]"===De.call(t.callee)),s};k.keys||(ye=k.prototype.hasOwnProperty,be=k.prototype.toString,ke=Fe,we=k.prototype.propertyIsEnumerable,je=!we.call({toString:null},"toString"),Se=we.call((function(){}),"prototype"),_e=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"],xe=function(t){var i=t.constructor;return i&&i.prototype===t},Te={$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},Ce=function(){if(void 0===s)return!1;for(var t in s)try{if(!Te["$"+t]&&ye.call(s,t)&&null!==s[t]&&"object"==typeof s[t])try{xe(s[t])}catch(t){return!0}}catch(t){return!0}return!1}(),Pe=function(t){if(void 0===s||!Ce)return xe(t);try{return xe(t)}catch(t){return!1}},ge=function(t){var i=null!==t&&"object"==typeof t,s="[object Function]"===be.call(t),e=ke(t),n=i&&"[object String]"===be.call(t),r=[];if(!i&&!s&&!e)throw new g("Object.keys called on a non-object");var h=Se&&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(je)for(var c=Pe(t),l=0;l<_e.length;++l)c&&"constructor"===_e[l]||!ye.call(t,_e[l])||r.push(_e[l]);return r});var Ne=ge,$e=Array.prototype.slice,Be=Fe,Oe=k.keys,Re=Oe?function(t){return Oe(t)}:Ne,Ue=k.keys;Re.shim=function(){if(k.keys){var t=function(){var t=k.keys(arguments);return t&&t.length===arguments.length}(1,2);t||(k.keys=function(t){return Be(t)?Ue($e.call(t)):Ue(t)})}else k.keys=Re;return k.keys||Re};var Ve=Re,Le="function"==typeof Symbol&&"symbol"==typeof Symbol("foo"),He=k.prototype.toString,ze=Array.prototype.concat,We=k.defineProperty,qe=We&&function(){var t={};try{for(var i in We(t,"x",{enumerable:!1,value:t}),t)return!1;return t.x===t}catch(t){return!1}}(),Ge=function(t,i,s,e){(!(i in t)||function(t){return"function"==typeof t&&"[object Function]"===He.call(t)}(e)&&e())&&(qe?We(t,i,{configurable:!0,enumerable:!1,value:s,writable:!0}):t[i]=s)},Xe=function(t,i){var s=arguments.length>2?arguments[2]:{},e=Ve(i);Le&&(e=ze.call(e,k.getOwnPropertySymbols(i)));for(var n=0;n<e.length;n+=1)Ge(t,e[n],i[e[n]],s[e[n]])};Xe.supportsDescriptors=!!qe;var Qe,Je=Xe,Ye=k.getOwnPropertyDescriptor?function(){return k.getOwnPropertyDescriptor(arguments,"callee").get}():function(){throw new g},Ke="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator,Ze=k.getPrototypeOf||function(t){return t.__proto__},tn=void 0===x?Qe:Ze(x),sn={"$ %Array%":Array,"$ %ArrayBuffer%":"undefined"==typeof ArrayBuffer?Qe:ArrayBuffer,"$ %ArrayBufferPrototype%":"undefined"==typeof ArrayBuffer?Qe:ArrayBuffer.prototype,"$ %ArrayIteratorPrototype%":Ke?Ze([][Symbol.iterator]()):Qe,"$ %ArrayPrototype%":Array.prototype,"$ %ArrayProto_entries%":Array.prototype.entries,"$ %ArrayProto_forEach%":Array.prototype.forEach,"$ %ArrayProto_keys%":Array.prototype.keys,"$ %ArrayProto_values%":Array.prototype.values,"$ %AsyncFromSyncIteratorPrototype%":Qe,"$ %AsyncFunction%":undefined,"$ %AsyncFunctionPrototype%":Qe,"$ %AsyncGenerator%":Qe,"$ %AsyncGeneratorFunction%":undefined,"$ %AsyncGeneratorPrototype%":Qe,"$ %AsyncIteratorPrototype%":Qe,"$ %Atomics%":"undefined"==typeof Atomics?Qe:Atomics,"$ %Boolean%":Boolean,"$ %BooleanPrototype%":Boolean.prototype,"$ %DataView%":"undefined"==typeof DataView?Qe:DataView,"$ %DataViewPrototype%":"undefined"==typeof DataView?Qe: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?Qe:Float32Array,"$ %Float32ArrayPrototype%":"undefined"==typeof Float32Array?Qe:Float32Array.prototype,"$ %Float64Array%":"undefined"==typeof Float64Array?Qe:Float64Array,"$ %Float64ArrayPrototype%":"undefined"==typeof Float64Array?Qe:Float64Array.prototype,"$ %Function%":Function,"$ %FunctionPrototype%":Function.prototype,"$ %Generator%":Qe,"$ %GeneratorFunction%":undefined,"$ %GeneratorPrototype%":Qe,"$ %Int8Array%":"undefined"==typeof Int8Array?Qe:Int8Array,"$ %Int8ArrayPrototype%":"undefined"==typeof Int8Array?Qe:Int8Array.prototype,"$ %Int16Array%":"undefined"==typeof Int16Array?Qe:Int16Array,"$ %Int16ArrayPrototype%":"undefined"==typeof Int16Array?Qe:Int8Array.prototype,"$ %Int32Array%":"undefined"==typeof Int32Array?Qe:Int32Array,"$ %Int32ArrayPrototype%":"undefined"==typeof Int32Array?Qe:Int32Array.prototype,"$ %isFinite%":isFinite,"$ %isNaN%":_,"$ %IteratorPrototype%":Ke?Ze(Ze([][Symbol.iterator]())):Qe,"$ %JSON%":JSON,"$ %JSONParse%":JSON.parse,"$ %Map%":"undefined"==typeof Map?Qe:Map,"$ %MapIteratorPrototype%":"undefined"!=typeof Map&&Ke?Ze((new Map)[Symbol.iterator]()):Qe,"$ %MapPrototype%":"undefined"==typeof Map?Qe:Map.prototype,"$ %Math%":w,"$ %Number%":Number,"$ %NumberPrototype%":Number.prototype,"$ %Object%":k,"$ %ObjectPrototype%":k.prototype,"$ %ObjProto_toString%":k.prototype.toString,"$ %ObjProto_valueOf%":k.prototype.valueOf,"$ %parseFloat%":S,"$ %parseInt%":j,"$ %Promise%":"undefined"==typeof Promise?Qe:Promise,"$ %PromisePrototype%":"undefined"==typeof Promise?Qe:Promise.prototype,"$ %PromiseProto_then%":"undefined"==typeof Promise?Qe:Promise.prototype.then,"$ %Promise_all%":"undefined"==typeof Promise?Qe:Promise.all,"$ %Promise_reject%":"undefined"==typeof Promise?Qe:Promise.reject,"$ %Promise_resolve%":"undefined"==typeof Promise?Qe:Promise.resolve,"$ %Proxy%":"undefined"==typeof Proxy?Qe:Proxy,"$ %RangeError%":RangeError,"$ %RangeErrorPrototype%":RangeError.prototype,"$ %ReferenceError%":ReferenceError,"$ %ReferenceErrorPrototype%":ReferenceError.prototype,"$ %Reflect%":"undefined"==typeof Reflect?Qe:Reflect,"$ %RegExp%":RegExp,"$ %RegExpPrototype%":RegExp.prototype,"$ %Set%":"undefined"==typeof Set?Qe:Set,"$ %SetIteratorPrototype%":"undefined"!=typeof Set&&Ke?Ze((new Set)[Symbol.iterator]()):Qe,"$ %SetPrototype%":"undefined"==typeof Set?Qe:Set.prototype,"$ %SharedArrayBuffer%":"undefined"==typeof SharedArrayBuffer?Qe:SharedArrayBuffer,"$ %SharedArrayBufferPrototype%":"undefined"==typeof SharedArrayBuffer?Qe:SharedArrayBuffer.prototype,"$ %String%":String,"$ %StringIteratorPrototype%":Ke?Ze(""[Symbol.iterator]()):Qe,"$ %StringPrototype%":String.prototype,"$ %Symbol%":Ke?Symbol:Qe,"$ %SymbolPrototype%":Ke?Symbol.prototype:Qe,"$ %SyntaxError%":b,"$ %SyntaxErrorPrototype%":b.prototype,"$ %ThrowTypeError%":Ye,"$ %TypedArray%":tn,"$ %TypedArrayPrototype%":tn?tn.prototype:Qe,"$ %TypeError%":g,"$ %TypeErrorPrototype%":g.prototype,"$ %Uint8Array%":void 0===x?Qe:x,"$ %Uint8ArrayPrototype%":void 0===x?Qe:x.prototype,"$ %Uint8ClampedArray%":"undefined"==typeof Uint8ClampedArray?Qe:Uint8ClampedArray,"$ %Uint8ClampedArrayPrototype%":"undefined"==typeof Uint8ClampedArray?Qe:Uint8ClampedArray.prototype,"$ %Uint16Array%":"undefined"==typeof Uint16Array?Qe:Uint16Array,"$ %Uint16ArrayPrototype%":"undefined"==typeof Uint16Array?Qe:Uint16Array.prototype,"$ %Uint32Array%":"undefined"==typeof Uint32Array?Qe:Uint32Array,"$ %Uint32ArrayPrototype%":"undefined"==typeof Uint32Array?Qe:Uint32Array.prototype,"$ %URIError%":URIError,"$ %URIErrorPrototype%":URIError.prototype,"$ %WeakMap%":"undefined"==typeof WeakMap?Qe:WeakMap,"$ %WeakMapPrototype%":"undefined"==typeof WeakMap?Qe:WeakMap.prototype,"$ %WeakSet%":"undefined"==typeof WeakSet?Qe:WeakSet,"$ %WeakSetPrototype%":"undefined"==typeof WeakSet?Qe:WeakSet.prototype},en=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 sn))throw new b("intrinsic "+t+" does not exist!");if(void 0===sn[s]&&!i)throw new g("intrinsic "+t+" exists, but is not available. Please file an issue!");return sn[s]},nn=Ee.call(Function.call,k.prototype.hasOwnProperty),rn=en,hn=rn("%TypeError%"),on=rn("%SyntaxError%"),an=nn,un={"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(an(i,e)&&!s[e])return!1;var n=an(i,"[[Value]]"),r=an(i,"[[Get]]")||an(i,"[[Set]]");if(n&&r)throw new hn("Property Descriptors may not be both accessor and data descriptors");return!0}},cn=Number.isNaN||function(t){return t!=t},ln=Number.isNaN||function(t){return t!=t},fn=Number.isFinite||function(t){return"number"==typeof t&&!ln(t)&&t!==1/0&&t!==-1/0},dn=Function.prototype.toString,vn=/^\s*class\b/,pn=function(t){try{var i=dn.call(t);return vn.test(i)}catch(t){return!1}},mn=k.prototype.toString,gn="function"==typeof Symbol&&"symbol"==typeof Symbol.toStringTag,yn=function(t){if(!t)return!1;if("function"!=typeof t&&"object"!=typeof t)return!1;if("function"==typeof t&&!t.prototype)return!0;if(gn)return function(t){try{return!pn(t)&&(dn.call(t),!0)}catch(t){return!1}}(t);if(pn(t))return!1;var i=mn.call(t);return"[object Function]"===i||"[object GeneratorFunction]"===i},bn=k.prototype.toString,kn=function(t){return null===t||"function"!=typeof t&&"object"!=typeof t},wn=yn,jn=function(t){var i;if((i=arguments.length>1?arguments[1]:"[object Date]"===bn.call(t)?String:Number)===String||i===Number){var s,e,n=i===String?["toString","valueOf"]:["valueOf","toString"];for(e=0;e<n.length;++e)if(wn(t[n[e]])&&(s=t[n[e]](),kn(s)))return s;throw new g("No default value")}throw new g("invalid [[DefaultValue]] hint supplied")},Sn=en,_n=Sn("%Object%"),xn=Sn("%TypeError%"),Tn=Sn("%String%"),Cn=function(t,i,s,e){var n=un[i];if("function"!=typeof n)throw new on("unknown record type: "+i);if(!n(t,e))throw new hn(s+" must be a "+i);console.log(n(t,e),e)},Pn=cn,An=fn,Mn=function(t){return t>=0?1:-1},In=function(t,i){var s=t%i;return w.floor(s>=0?s:s+i)},En=nn,Dn={ToPrimitive:function(t){return kn(t)?t:arguments.length>1?jn(t,arguments[1]):jn(t)},ToBoolean:function(t){return!!t},ToNumber:function(t){return+t},ToInteger:function(t){var i=this.ToNumber(t);return Pn(i)?0:0!==i&&An(i)?Mn(i)*w.floor(w.abs(i)):i},ToInt32:function(t){return this.ToNumber(t)>>0},ToUint32:function(t){return this.ToNumber(t)>>>0},ToUint16:function(t){var i=this.ToNumber(t);if(Pn(i)||0===i||!An(i))return 0;var s=Mn(i)*w.floor(w.abs(i));return In(s,65536)},ToString:function(t){return Tn(t)},ToObject:function(t){return this.CheckObjectCoercible(t),_n(t)},CheckObjectCoercible:function(t,i){if(null==t)throw new xn(i||"Cannot call method on "+t);return t},IsCallable:yn,SameValue:function(t,i){return t===i?0!==t||1/t==1/i:Pn(t)&&Pn(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(En(t,s)&&!i[s])return!1;var e=En(t,"[[Value]]"),n=En(t,"[[Get]]")||En(t,"[[Set]]");if(e&&n)throw new xn("Property Descriptors may not be both accessor and data descriptors");return!0},IsAccessorDescriptor:function(t){return void 0!==t&&(Cn(this,"Property Descriptor","Desc",t),!(!En(t,"[[Get]]")&&!En(t,"[[Set]]")))},IsDataDescriptor:function(t){return void 0!==t&&(Cn(this,"Property Descriptor","Desc",t),!(!En(t,"[[Value]]")&&!En(t,"[[Writable]]")))},IsGenericDescriptor:function(t){return void 0!==t&&(Cn(this,"Property Descriptor","Desc",t),!this.IsAccessorDescriptor(t)&&!this.IsDataDescriptor(t))},FromPropertyDescriptor:function(t){if(void 0===t)return t;if(Cn(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 xn("FromPropertyDescriptor must be called with a fully populated Property Descriptor")},ToPropertyDescriptor:function(t){if("Object"!==this.Type(t))throw new xn("ToPropertyDescriptor requires an object");var i={};if(En(t,"enumerable")&&(i["[[Enumerable]]"]=this.ToBoolean(t.enumerable)),En(t,"configurable")&&(i["[[Configurable]]"]=this.ToBoolean(t.configurable)),En(t,"value")&&(i["[[Value]]"]=t.value),En(t,"writable")&&(i["[[Writable]]"]=this.ToBoolean(t.writable)),En(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(En(t,"set")){var e=t.set;if(void 0!==e&&!this.IsCallable(e))throw new xn("setter must be a function");i["[[Set]]"]=e}if((En(i,"[[Get]]")||En(i,"[[Set]]"))&&(En(i,"[[Value]]")||En(i,"[[Writable]]")))throw new xn("Invalid property descriptor. Cannot both specify accessors and a value or writable attribute");return i}},Fn=Ee.call(Function.call,String.prototype.replace),Nn=/^[\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]+/,$n=/[\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]+$/,Bn=function(){var t=Dn.ToString(Dn.CheckObjectCoercible(this));return Fn(Fn(t,Nn,""),$n,"")},On=Bn,Rn=function(){return String.prototype.trim&&"\u200b"==="\u200b".trim()?String.prototype.trim:On},Un=Je,Vn=Rn,Ln=Je,Hn=Bn,zn=Rn,Wn=function(){var t=Vn();return Un(String.prototype,{trim:t},{trim:function(){return String.prototype.trim!==t}}),t},qn=Ee.call(Function.call,zn());Ln(qn,{getPolyfill:zn,implementation:Hn,shim:Wn});var Gn=qn,Xn=yn,Qn=k.prototype.toString,Jn=k.prototype.hasOwnProperty,Yn=Gn,Kn=function(t,i,s){if(!Xn(i))throw new g("iterator must be a function");var e;arguments.length>=3&&(e=s),"[object Array]"===Qn.call(t)?function(t,i,s){for(var e=0,n=t.length;e<n;e++)Jn.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)Jn.call(t,e)&&(null==s?i(t[e],e,t):i.call(s,t[e],e,t))}(t,i,e)},Zn=function(){for(var t={},i=0;i<arguments.length;i++){var s=arguments[i];for(var e in s)tr.call(s,e)&&(t[e]=s[e])}return t},tr=k.prototype.hasOwnProperty;var ir=ve.exports,sr=pe,er=function(t){if(!t)return{};var i={};return Kn(Yn(t).split("\n"),(function(t){var s=t.indexOf(":"),e=Yn(t.slice(0,s)).toLowerCase(),n=Yn(t.slice(s+1));void 0===i[e]?i[e]=n:!function(t){return"[object Array]"===k.prototype.toString.call(t)}(i[e])?i[e]=[i[e],n]:i[e].push(n)})),i},nr=Zn,rr=or;function hr(t,i,s){var e=t;return sr(i)?(s=i,"string"==typeof t&&(e={uri:t})):e=nr(i,{uri:t}),e.callback=s,e}function or(t,i,s){return ar(i=hr(t,i,s))}function ar(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=u.response?u.response:u.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}(u),b)try{t=JSON.parse(t)}catch(t){}return t}var n={body:void 0,headers:{},statusCode:0,method:d,url:f,rawRequest:u};function r(t){return v(l),t instanceof m||(t=new m(""+(t||"Unknown XMLHttpRequest Error"))),t.statusCode=0,s(t,n)}function h(){if(!a){var i;v(l),i=t.useXDR&&void 0===u.status?200:1223===u.status?204:u.status;var r=n,h=null;return 0!==i?(r={body:e(),statusCode:i,method:d,headers:{},url:f,rawRequest:u},u.getAllResponseHeaders&&(r.headers=er(u.getAllResponseHeaders()))):h=new m("Internal XMLHttpRequest Error"),s(h,r,r.body)}}var o,a,u=t.xhr||null;u||(u=t.cors||t.useXDR?new or.XDomainRequest:new or.XMLHttpRequest);var l,f=u.url=t.uri||t.url,d=u.method=t.method||"GET",p=t.body||t.data||null,g=u.headers=t.headers||{},y=!!t.sync,b=!1;if("json"in t&&(b=!0,g.accept||g.Accept||(g.Accept="application/json"),"GET"!==d&&"HEAD"!==d&&(g["content-type"]||g["Content-Type"]||(g["Content-Type"]="application/json"),p=JSON.stringify(t.json))),u.onreadystatechange=function(){4===u.readyState&&h()},u.onload=h,u.onerror=r,u.onprogress=function(){},u.ontimeout=r,u.open(d,f,!y,t.username,t.password),y||(u.withCredentials=!!t.withCredentials),!y&&t.timeout>0&&(l=c((function(){a=!0,u.abort("timeout");var t=new m("XMLHttpRequest timeout");t.code="ETIMEDOUT",r(t)}),t.timeout)),u.setRequestHeader)for(o in g)g.hasOwnProperty(o)&&u.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&&(u.responseType=t.responseType),"beforeSend"in t&&"function"==typeof t.beforeSend&&t.beforeSend(u),u.send(p),u}or.XMLHttpRequest=ir.XMLHttpRequest||function(){},or.XDomainRequest="withCredentials"in new or.XMLHttpRequest?or.XMLHttpRequest:ir.XDomainRequest,function(t,i){for(var s=0;s<t.length;s++)i(t[s])}(["get","put","post","patch","head","delete"],(function(t){or["delete"===t?"del":t]=function(i,s,e){return(s=hr(i,s,e)).method=t.toUpperCase(),ar(s)}}));var ur=function(t,i){var s=new o.WebVTT.Parser(o,o.vttjs,o.WebVTT.StringDecoder()),e=[];s.oncue=function(t){i.addCue(t)},s.onparsingerror=function(t){e.push(t)},s.onflush=function(){i.trigger({type:"loadeddata",target:i})},s.parse(t),e.length>0&&(o.console&&o.console.groupCollapsed&&o.console.groupCollapsed("Text Track parsing errors for "+i.src),e.forEach((function(t){return gi.error(t)})),o.console&&o.console.groupEnd&&o.console.groupEnd()),s.flush()},cr=function(t){function i(s){var e;if(void 0===s&&(s={}),!s.tech)throw new m("A tech was not provided.");var n=Bs(s,{kind:ue[s.kind]||"subtitles",language:s.language||s.srclang||""}),r=ce[n.mode]||"disabled",h=n.default;"metadata"!==n.kind&&"chapters"!==n.kind||(r="hidden");var a=e=t.call(this,n)||this;if(a.W=n.tech,ds)for(var u in i.prototype)"constructor"!==u&&(a[u]=i.prototype[u]);a.H=[],a.q=[];var c=new he(a.H),l=new he(a.q),f=!1,d=Ns(a,(function(){this.activeCues,f&&(this.trigger("cuechange"),f=!1)}));return"disabled"!==r&&a.W.ready((function(){a.W.on("timeupdate",d)}),!0),k.defineProperty(a,"default",{get:function(){return h},set:function(){}}),k.defineProperty(a,"mode",{get:function(){return r},set:function(t){var i=this;ce[t]&&("showing"===(r=t)&&this.W.ready((function(){i.W.on("timeupdate",d)}),!0),this.trigger("modechange"))}}),k.defineProperty(a,"cues",{get:function(){return this.G?c:null},set:function(){}}),k.defineProperty(a,"activeCues",{get:function(){if(!this.G)return null;if(0===this.cues.length)return l;for(var t=this.W.currentTime(),i=[],s=0,e=this.cues.length;s<e;s++){var n=this.cues[s];(n.startTime<=t&&n.endTime>=t||n.startTime===n.endTime&&n.startTime<=t&&n.startTime+.5>=t)&&i.push(n)}if(f=!1,i.length!==this.q.length)f=!0;else for(var r=0;r<i.length;r++)-1===this.q.indexOf(i[r])&&(f=!0);return this.q=i,l.V(this.q),l},set:function(){}}),n.src?(a.src=n.src,function(t,i){var s={uri:t},e=de(t);e&&(s.cors=e),rr(s,Ns(this,(function(t,s,e){if(t)return gi.error(t,s);if(i.G=!0,"function"!=typeof o.WebVTT){if(i.W){var n=function(){return ur(e,i)};i.W.on("vttjsloaded",n),i.W.on("vttjserror",(function(){gi.error("vttjs failed to load, stopping trying to process "+i.src),i.W.off("vttjsloaded",n)}))}}else ur(e,i)})))}(n.src,a)):a.G=!0,a||Rs(e)}Vs(i,t);var s=i.prototype;return s.addCue=function(t){var i=t;if(o.vttjs&&!(t instanceof o.vttjs.VTTCue)){for(var s in i=new o.vttjs.VTTCue(t.startTime,t.endTime,t.text),t)s in i||(i[s]=t[s]);i.id=t.id,i.X=t}var e=this.W.textTracks();if(e)for(var n=0;n<e.length;n++)e[n]!==this&&e[n].removeCue(i);this.H.push(i),this.cues.V(this.H)},s.removeCue=function(t){for(var i=this.H.length;i--;){var s=this.H[i];if(s===t||s.X&&s.X===t){this.H.splice(i,1),this.cues.V(this.H);break}}},i}(le);cr.prototype.M={cuechange:"cuechange"};var lr=function(i){function s(e){var n,r;void 0===e&&(e={});var h=Rs(n=i.call(this)||this);if(ds)for(var o in h=t.createElement("custom"),s.prototype)"constructor"!==o&&(h[o]=s.prototype[o]);var a=new cr(e);return h.kind=a.kind,h.src=a.src,h.srclang=a.language,h.label=a.label,h.default=a.default,k.defineProperty(h,"readyState",{get:function(){return r}}),k.defineProperty(h,"track",{get:function(){return a}}),r=0,a.addEventListener("loadeddata",(function(){r=2,h.trigger({type:"load",target:h})})),ds?h||Rs(n):n}return Vs(s,i),s}(Os);lr.prototype.M={load:"load"},lr.NONE=0,lr.LOADING=1,lr.LOADED=2,lr.ERROR=3;var fr,dr=function(){function i(s){void 0===s&&(s=[]);var e=this;if(ds)for(var n in e=t.createElement("custom"),i.prototype)"constructor"!==n&&(e[n]=i.prototype[n]);e.J=[],k.defineProperty(e,"length",{get:function(){return this.J.length}});for(var r=0,h=s.length;r<h;r++)e.Y(s[r]);if(ds)return e}var s=i.prototype;return s.Y=function(t){var i=this.J.length;""+i in this||k.defineProperty(this,i,{get:function(){return this.J[i]}}),-1===this.J.indexOf(t)&&this.J.push(t)},s.K=function(t){for(var i,s=0,e=this.J.length;s<e;s++)if(t===this.J[s].track){i=this.J[s];break}return i},s.Z=function(t){for(var i=0,s=this.J.length;i<s;i++)if(t===this.J[i]){this.J.splice(i,1);break}},i}(),vr=function(i){function s(e,n){var r;if(void 0===e&&(e=[]),void 0===n&&(n=null),r=i.call(this)||this,!n&&(n=Rs(r),ds))for(var h in n=t.createElement("custom"),s.prototype)"constructor"!==h&&(n[h]=s.prototype[h]);n.tt=[],k.defineProperty(n,"length",{get:function(){return this.tt.length}});for(var o=0;o<e.length;o++)n.it(e[o]);return n||Rs(r)}Vs(s,i);var e=s.prototype;return e.it=function(t){var i=this.tt.length;""+i in this||k.defineProperty(this,i,{get:function(){return this.tt[i]}}),-1===this.tt.indexOf(t)&&(this.tt.push(t),this.trigger({track:t,type:"addtrack"}))},e.st=function(t){for(var i,s=0,e=this.length;s<e;s++)if(this[s]===t){(i=this[s]).off&&i.off(),this.tt.splice(s,1);break}i&&this.trigger({track:i,type:"removetrack"})},e.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},s}(Os);for(fr in vr.prototype.M={change:"change",addtrack:"addtrack",removetrack:"removetrack"},vr.prototype.M)vr.prototype["on"+fr]=null;var pr=function(i){function s(e){var n,r;if(void 0===e&&(e=[]),ds){for(var h in r=t.createElement("custom"),vr.prototype)"constructor"!==h&&(r[h]=vr.prototype[h]);for(var o in s.prototype)"constructor"!==o&&(r[o]=s.prototype[o])}return(r=n=i.call(this,e,r)||this)||Rs(n)}return Vs(s,i),s.prototype.it=function(t){i.prototype.it.call(this,t),t.addEventListener("modechange",Ns(this,(function(){this.trigger("change")})))},s}(vr),mr=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].selected=!1)},gr=function(i){function s(e){var n,r;void 0===e&&(e=[]);for(var h=e.length-1;h>=0;h--)if(e[h].selected){mr(e,e[h]);break}if(ds){for(var o in r=t.createElement("custom"),vr.prototype)"constructor"!==o&&(r[o]=vr.prototype[o]);for(var a in s.prototype)"constructor"!==a&&(r[a]=s.prototype[a])}return(r=n=i.call(this,e,r)||this).et=!1,k.defineProperty(r,"selectedIndex",{get:function(){for(var t=0;t<this.length;t++)if(this[t].selected)return t;return-1},set:function(){}}),r||Rs(n)}Vs(s,i);var e=s.prototype;return e.it=function(t){var s=this;t.selected&&mr(this,t),i.prototype.it.call(this,t),t.addEventListener&&t.addEventListener("selectedchange",(function(){s.et||(s.et=!0,mr(s,t),s.et=!1,s.trigger("change"))}))},e.addTrack=function(t){this.it(t)},e.removeTrack=function(t){i.prototype.st.call(this,t)},s}(vr),yr=function(t,i){for(var s=0;s<t.length;s++)i.id!==t[s].id&&(t[s].enabled=!1)},br=function(i){function s(e){var n,r;void 0===e&&(e=[]);for(var h=e.length-1;h>=0;h--)if(e[h].enabled){yr(e,e[h]);break}if(ds){for(var o in r=t.createElement("custom"),vr.prototype)"constructor"!==o&&(r[o]=vr.prototype[o]);for(var a in s.prototype)"constructor"!==a&&(r[a]=s.prototype[a])}return(r=n=i.call(this,e,r)||this).et=!1,r||Rs(n)}Vs(s,i);var e=s.prototype;return e.it=function(t){var s=this;t.enabled&&yr(this,t),i.prototype.it.call(this,t),t.addEventListener&&t.addEventListener("enabledchange",(function(){s.et||(s.et=!0,yr(s,t),s.et=!1,s.trigger("change"))}))},e.addTrack=function(t){this.it(t)},e.removeTrack=function(t){i.prototype.st.call(this,t)},s}(vr),kr=void 0;var wr=function(i){function s(t,s){var e;return void 0===t&&(t={}),void 0===s&&(s=function(){}),t.reportTouchActivity=!1,(e=i.call(this,null,t,s)||this).nt=!1,e.on("playing",(function(){this.nt=!0})),e.on("loadstart",(function(){this.nt=!1})),e.rt=t.textTracks,e.ht=t.videoTracks,e.ot=t.audioTracks,e.featuresProgressEvents||e.manualProgressOn(),e.featuresTimeupdateEvents||e.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach((function(i){!1===t["native"+i+"Tracks"]&&(e["featuresNative"+i+"Tracks"]=!1)})),!1===t.nativeCaptions&&(e.featuresNativeTextTracks=!1),e.featuresNativeTextTracks||e.emulateTextTracks(),e.ut=new pr,e.initTextTrackListeners(),e.initTrackListeners(),t.nativeControlsForTouch||e.emitTapEvents(),e.constructor&&(e.v=e.constructor.name||"Unknown Tech"),e}Vs(s,i);var e=s.prototype;return e.manualProgressOn=function(){this.on("durationchange",this.onDurationChange),this.manualProgress=!0,this.one("ready",this.trackProgress)},e.manualProgressOff=function(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange)},e.trackProgress=function(t){this.stopTrackingProgress(),this.progressInterval=this.setInterval(Ns(this,(function(){var t=this.bufferedPercent();this.ct!==t&&this.trigger("progress"),this.ct=t,1===t&&this.stopTrackingProgress()})),500)},e.onDurationChange=function(t){this.lt=this.duration()},e.buffered=function(){return zs(0,0)},e.bufferedPercent=function(){return Ws(this.buffered(),this.lt)},e.stopTrackingProgress=function(){this.clearInterval(this.progressInterval)},e.manualTimeUpdatesOn=function(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime),this.on("pause",this.stopTrackingCurrentTime)},e.manualTimeUpdatesOff=function(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime),this.off("pause",this.stopTrackingCurrentTime)},e.trackCurrentTime=function(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval((function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})}),250)},e.stopTrackingCurrentTime=function(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},e.dispose=function(){this.clearTracks(["audio","video","text"]),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),i.prototype.dispose.call(this)},e.clearTracks=function(t){var i=this;(t=[].concat(t)).forEach((function(t){for(var s=i[t+"Tracks"]()||[],e=s.length;e--;){var n=s[e];"text"===t&&i.removeRemoteTextTrack(n),s.st(n)}}))},e.cleanupAutoTextTracks=function(){for(var t=this.ut||[],i=t.length;i--;){var s=t[i];this.removeRemoteTextTrack(s)}},e.reset=function(){},e.error=function(t){return void 0!==t&&(this.ft=new Zs(t),this.trigger("error")),this.ft},e.played=function(){return this.nt?zs(0,0):zs()},e.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},e.initTextTrackListeners=function(){var t=Ns(this,(function(){this.trigger("texttrackchange")})),i=this.textTracks();i&&(i.addEventListener("removetrack",t),i.addEventListener("addtrack",t),this.on("dispose",Ns(this,(function(){i.removeEventListener("removetrack",t),i.removeEventListener("addtrack",t)}))))},e.initTrackListeners=function(){var t=this;["video","audio"].forEach((function(i){var s=function(){t.trigger(i+"trackchange")},e=t[i+"Tracks"]();e.addEventListener("removetrack",s),e.addEventListener("addtrack",s),t.on("dispose",(function(){e.removeEventListener("removetrack",s),e.removeEventListener("addtrack",s)}))}))},e.dt=function(){var i=this;if(!o.WebVTT)if(t.body.contains(this.el())){if(!this.o["vtt.js"]&&pi(kr)&&k.keys(kr).length>0)return void this.trigger("vttjsloaded");var s=t.createElement("script");s.src=this.o["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.12.4/vtt.min.js",s.onload=function(){i.trigger("vttjsloaded")},s.onerror=function(){i.trigger("vttjserror")},this.on("dispose",(function(){s.onload=null,s.onerror=null})),o.WebVTT=!0,this.el().parentNode.appendChild(s)}else this.ready(this.dt)},e.emulateTextTracks=function(){var t=this,i=this.textTracks();if(i){var s=this.remoteTextTracks(),e=function(t){return i.it(t.track)},n=function(t){return i.st(t.track)};s.on("addtrack",e),s.on("removetrack",n),this.dt();var r=function(){return t.trigger("texttrackchange")},h=function(){r();for(var t=0;t<i.length;t++){var s=i[t];s.removeEventListener("cuechange",r),"showing"===s.mode&&s.addEventListener("cuechange",r)}};h(),i.addEventListener("change",h),i.addEventListener("addtrack",h),i.addEventListener("removetrack",h),this.on("dispose",(function(){s.off("addtrack",e),s.off("removetrack",n),i.removeEventListener("change",h),i.removeEventListener("addtrack",h),i.removeEventListener("removetrack",h);for(var t=0;t<i.length;t++){i[t].removeEventListener("cuechange",r)}}))}},e.videoTracks=function(){return this.ht=this.ht||new gr,this.ht},e.audioTracks=function(){return this.ot=this.ot||new br,this.ot},e.textTracks=function(){return this.rt=this.rt||new pr,this.rt},e.remoteTextTracks=function(){return this.vt=this.vt||new pr,this.vt},e.remoteTextTrackEls=function(){return this.gt=this.gt||new dr,this.gt},e.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 cr(n);return r.it(h),h}(this,t,i,s)},e.createRemoteTextTrack=function(t){var i=Bs(t,{tech:this});return new lr(i)},e.addRemoteTextTrack=function(t,i){void 0===t&&(t={});var s=this.createRemoteTextTrack(t);return!0!==i&&!1!==i&&(gi.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().Y(s),this.remoteTextTracks().it(s.track),!0!==i&&this.ut.it(s.track),s},e.removeRemoteTextTrack=function(t){var i=this.remoteTextTrackEls().K(t);this.remoteTextTrackEls().Z(i),this.remoteTextTracks().st(t),this.ut.st(t)},e.getVideoPlaybackQuality=function(){return{}},e.setPoster=function(){},e.playsinline=function(){},e.setPlaysinline=function(){},e.canPlayType=function(){return""},s.isTech=function(t){return t.prototype instanceof s||t instanceof s||t===s},s.registerTech=function(t,i){if(s.yt||(s.yt={}),!s.isTech(i))throw new m("Tech "+t+" must be a Tech");return s.yt[t]=i,i},s.getTech=function(t){return s.yt&&s.yt[t]?s.yt[t]:o&&o.videojs&&o.videojs[t]?(gi.warn("The "+t+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),o.videojs[t]):void 0},s}(i);wr.prototype.rt,wr.prototype.ot,wr.prototype.ht,wr.prototype.featuresVolumeControl=!0,wr.prototype.featuresFullscreenResize=!1,wr.prototype.featuresPlaybackRate=!1,wr.prototype.featuresProgressEvents=!1,wr.prototype.featuresTimeupdateEvents=!1,wr.prototype.featuresNativeTextTracks=!1,wr.withSourceHandlers=function(t){t.registerSourceHandler=function(i,s){var e=t.sourceHandlers;e||(e=t.sourceHandlers=[]),void 0===s&&(s=e.length),e.splice(s,0,i)},t.canPlayType=function(i){for(var s,e=t.sourceHandlers||[],n=0;n<e.length;n++)if(s=e[n].canPlayType(i))return s;return""},t.selectSourceHandler=function(i,s){for(var e=t.sourceHandlers||[],n=0;n<e.length;n++)if(e[n].canHandleSource(i,s))return e[n];return null},t.canPlaySource=function(i,s){var e=t.selectSourceHandler(i,s);return e?e.canHandleSource(i,s):""};["seekable","duration"].forEach((function(t){var i=this[t];"function"==typeof i&&(this[t]=function(){return this.bt&&this.bt[t]?this.bt[t].apply(this.bt,arguments):i.apply(this,arguments)})}),t.prototype),t.prototype.setSource=function(i){var s=t.selectSourceHandler(i,this.o);return s||(t.nativeSourceHandler?s=t.nativeSourceHandler:gi.error("No source hander found for the current source.")),this.disposeSourceHandler(),this.off("dispose",this.disposeSourceHandler),s!==t.nativeSourceHandler&&(this.kt=i,this.off(this.m,"loadstart",t.prototype.wt),this.off(this.m,"loadstart",t.prototype.jt),this.one(this.m,"loadstart",t.prototype.wt)),this.bt=s.handleSource(i,this,this.o),this.on("dispose",this.disposeSourceHandler),this},t.prototype.wt=function(){this.one(this.m,"loadstart",t.prototype.jt)},t.prototype.jt=function(){this.disposeSourceHandler(),this.one(this.m,"loadstart",t.prototype.jt)},t.prototype.disposeSourceHandler=function(){this.kt&&(this.clearTracks(["audio","video"]),this.kt=null),this.cleanupAutoTextTracks(),this.bt&&(this.off(this.m,"loadstart",t.prototype.wt),this.off(this.m,"loadstart",t.prototype.jt),this.bt.dispose&&this.bt.dispose(),this.bt=null)}},i.registerComponent("Tech",wr),i.registerComponent("MediaTechController",wr),wr.registerTech("Tech",wr);var jr=function(t){function s(s,e,n){var r;if(r=t.call(this,s,e,n)||this,e.playerOptions.sources&&0!==e.playerOptions.sources.length)s.src(e.playerOptions.sources);else for(var h=0,o=e.playerOptions.techOrder;h<o.length;h++){var a=$s(o[h]),u=wr.getTech(a);if(a||(u=i.getComponent(a)),u&&u.isSupported()){s.St(a);break}}return r}return Vs(s,t),s}(i);i.registerComponent("MediaLoader",jr);var Sr=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).emitTapEvents(),e.on(t,"languagechange",e.handleLanguagechange),e.enable(),e}Vs(s,i);var e=s.prototype;return e.createEl=function(t,s,e){void 0===t&&(t="div"),void 0===s&&(s={}),void 0===e&&(e={}),s=di({className:this.buildCSSClass(),tabIndex:0},s),"button"===t&&gi.error("Creating a ClickableComponent with an HTML element of "+t+" is not supported; use a Button instead."),e=di({role:"button","aria-live":"polite"},e),this._t=s.tabIndex;var n=i.prototype.createEl.call(this,t,s,e);return this.createControlTextEl(n),n},e.createControlTextEl=function(t){return this.xt=Ci("span",{className:"vjs-control-text"}),t&&t.appendChild(this.xt),this.controlText(this.Tt,t),this.xt},e.controlText=function(t,i){if(void 0===i&&(i=this.el()),void 0===t)return this.Tt||"Need Text";var s=this.localize(t);return this.Tt=t,this.xt.innerHTML=s,this.nonIconControl||i.setAttribute("title",s),this},e.buildCSSClass=function(){return"vjs-control vjs-button "+i.prototype.buildCSSClass.call(this)},e.enable=function(){return this.removeClass("vjs-disabled"),this.m.setAttribute("aria-disabled","false"),void 0!==this._t&&this.m.setAttribute("tabIndex",this._t),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},e.disable=function(){return this.addClass("vjs-disabled"),this.m.setAttribute("aria-disabled","true"),void 0!==this._t&&this.m.removeAttribute("tabIndex"),this.off(["tap","click"],this.handleClick),this.off("focus",this.handleFocus),this.off("blur",this.handleBlur),this},e.handleLanguagechange=function(){this.controlText(this.Tt)},e.handleClick=function(t){},e.handleFocus=function(i){xs(t,"keydown",Ns(this,this.handleKeyPress))},e.handleKeyPress=function(t){32===t.which||13===t.which?(t.preventDefault(),this.handleClick(t)):i.prototype.handleKeyPress&&i.prototype.handleKeyPress.call(this,t)},e.handleBlur=function(i){Ts(t,"keydown",Ns(this,this.handleKeyPress))},s}(i);i.registerComponent("ClickableComponent",Sr);var _r=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).update(),i.on("posterchange",Ns(Rs(e),e.update)),e}Vs(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=Ci("div",{className:"vjs-poster",tabIndex:-1});return ys||(this.Ct=Ci("img"),t.appendChild(this.Ct)),t},s.update=function(t){var i=this.player().poster();this.setSrc(i),i?this.show():this.hide()},s.setSrc=function(t){if(this.Ct)this.Ct.src=t;else{var i="";t&&(i='url("'+t+'")'),this.m.style.backgroundImage=i}},s.handleClick=function(t){this.h.controls()&&(this.h.paused()?this.h.play():this.h.pause())},i}(Sr);i.registerComponent("PosterImage",_r);var xr="#222",Tr={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 Cr(t,i){return"rgba("+j(t[1]+t[1],16)+","+j(t[2]+t[2],16)+","+j(t[3]+t[3],16)+","+i+")"}function Pr(t,i,s){try{t.style[i]=s}catch(t){return}}var Ar=function(t){function i(i,s,e){var n;return n=t.call(this,i,s,e)||this,i.on("loadstart",Ns(Rs(n),n.toggleDisplay)),i.on("texttrackchange",Ns(Rs(n),n.updateDisplay)),i.ready(Ns(Rs(n),(function(){if(i.W&&i.W.featuresNativeTextTracks)this.hide();else{i.on("fullscreenchange",Ns(this,this.updateDisplay));for(var t=this.o.playerOptions.tracks||[],s=0;s<t.length;s++)this.h.addRemoteTextTrack(t[s],!0);var e,n,r={captions:1,subtitles:1},h=this.h.textTracks();if(h){for(var o=0;o<h.length;o++){var a=h[o];a.default&&("descriptions"!==a.kind||e?a.kind in r&&!n&&(n=a):e=a)}n?n.mode="showing":e&&(e.mode="showing")}}}))),n}Vs(i,t);var s=i.prototype;return s.toggleDisplay=function(){this.h.W&&this.h.W.featuresNativeTextTracks?this.hide():this.show()},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-text-track-display"},{"aria-live":"off","aria-atomic":"true"})},s.clearDisplay=function(){"function"==typeof o.WebVTT&&o.WebVTT.processCues(o,[],this.m)},s.updateDisplay=function(){var t=this.h.textTracks();if(this.clearDisplay(),t){for(var i=null,s=null,e=t.length;e--;){var n=t[e];"showing"===n.mode&&("descriptions"===n.kind?i=n:s=n)}s?("off"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","off"),this.updateForTrack(s)):i&&("assertive"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","assertive"),this.updateForTrack(i))}},s.updateForTrack=function(t){if("function"==typeof o.WebVTT&&t.activeCues){for(var i=this.h.textTrackSettings.getValues(),s=[],e=0;e<t.activeCues.length;e++)s.push(t.activeCues[e]);o.WebVTT.processCues(o,s,this.m);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&&Pr(h.firstChild,"color",Cr(i.color||"#fff",i.textOpacity)),i.backgroundColor&&(h.firstChild.style.backgroundColor=i.backgroundColor),i.backgroundOpacity&&Pr(h.firstChild,"backgroundColor",Cr(i.backgroundColor||"#000",i.backgroundOpacity)),i.windowColor&&(i.windowOpacity?Pr(h,"backgroundColor",Cr(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 "+xr:"raised"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #222, 2px 2px #222, 3px 3px "+xr:"depressed"===i.edgeStyle?h.firstChild.style.textShadow="1px 1px #ccc, 0 1px #ccc, -1px -1px #222, 0 -1px "+xr:"uniform"===i.edgeStyle&&(h.firstChild.style.textShadow="0 0 4px #222, 0 0 4px #222, 0 0 4px #222, 0 0 4px "+xr)),i.fontPercent&&1!==i.fontPercent){var a=o.parseFloat(h.style.fontSize);h.style.fontSize=a*i.fontPercent+"px",h.style.height="auto",h.style.top="auto",h.style.bottom="2px"}i.fontFamily&&"default"!==i.fontFamily&&("small-caps"===i.fontFamily?h.firstChild.style.fontVariant="small-caps":h.firstChild.style.fontFamily=Tr[i.fontFamily])}}}},i}(i);i.registerComponent("TextTrackDisplay",Ar);var Mr=function(t){function i(){return t.apply(this,arguments)||this}return Vs(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"})},i}(i);i.registerComponent("LoadingSpinner",Mr);var Ir=function(t){function s(){return t.apply(this,arguments)||this}Vs(s,t);var e=s.prototype;return e.createEl=function(t,s,e){void 0===t&&(t="button"),void 0===s&&(s={}),void 0===e&&(e={}),s=di({className:this.buildCSSClass()},s),"button"!==t&&(gi.warn("Creating a Button with an HTML element of "+t+" is deprecated; use ClickableComponent instead."),s=di({tabIndex:0},s),e=di({role:"button"},e)),e=di({type:"button","aria-live":"polite"},e);var n=i.prototype.createEl.call(this,t,s,e);return this.createControlTextEl(n),n},e.addChild=function(t,s){void 0===s&&(s={});var e=this.constructor.name;return gi.warn("Adding an actionable (user controllable) child to a Button ("+e+") is not supported; use a ClickableComponent instead."),i.prototype.addChild.call(this,t,s)},e.enable=function(){t.prototype.enable.call(this),this.m.removeAttribute("disabled")},e.disable=function(){t.prototype.disable.call(this),this.m.setAttribute("disabled","disabled")},e.handleKeyPress=function(i){32!==i.which&&13!==i.which&&t.prototype.handleKeyPress.call(this,i)},s}(Sr);i.registerComponent("Button",Ir);var Er=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Pt=!1,e.on("mousedown",e.handleMouseDown),e}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-big-play-button"},s.handleClick=function(t){var i=this.h.play();if(!(this.Pt&&t.clientX&&t.clientY)){var s=this.h.getChild("controlBar"),e=s&&s.getChild("playToggle");if(e){var n=function(){return e.focus()};if(i&&i.then){i.then(n,(function(){}))}else this.setTimeout(n,1)}else this.h.focus()}},s.handleKeyPress=function(i){this.Pt=!1,t.prototype.handleKeyPress.call(this,i)},s.handleMouseDown=function(t){this.Pt=!0},i}(Ir);Er.prototype.Tt="Play Video",i.registerComponent("BigPlayButton",Er);var Dr=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).controlText(s&&s.controlText||"Close"),e}Vs(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}(Ir);i.registerComponent("CloseButton",Dr);var Fr=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}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-play-control "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.h.paused()?this.h.play():this.h.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}(Ir);function Nr(t,i){void 0===i&&(i=t),t=t<0?0:t;var s=w.floor(t%60),e=w.floor(t/60%60),n=w.floor(t/3600),r=w.floor(i/60%60),h=w.floor(i/3600);return(_(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)}Fr.prototype.Tt="Play",i.registerComponent("PlayToggle",Fr);var $r=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}Vs(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.T=Ci("div",{className:"vjs-current-time-display",innerHTML:'<span class="vjs-control-text">Current Time </span>0:00'},{"aria-live":"off"}),i.appendChild(this.T),i},s.updateContent=function(t){var i=this.h.scrubbing()?this.h.getCache().currentTime:this.h.currentTime(),s=this.localize("Current Time"),e=Nr(i,this.h.duration());e!==this.At&&(this.At=e,this.T.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e)},i}(i);i.registerComponent("CurrentTimeDisplay",$r);var Br=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}Vs(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.T=Ci("div",{className:"vjs-duration-display",innerHTML:'<span class="vjs-control-text">'+this.localize("Duration Time")+"</span> 0:00"},{"aria-live":"off"}),i.appendChild(this.T),i},s.updateContent=function(t){var i=this.h.duration();if(i&&this.lt!==i){this.lt=i;var s=this.localize("Duration Time"),e=Nr(i);this.T.innerHTML='<span class="vjs-control-text">'+s+"</span> "+e}},i}(i);i.registerComponent("DurationDisplay",Br);var Or=function(t){function i(){return t.apply(this,arguments)||this}return Vs(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-time-control vjs-time-divider",innerHTML:"<div><span>/</span></div>"})},i}(i);i.registerComponent("TimeDivider",Or);var Rr=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}Vs(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.T=Ci("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.T),i},s.updateContent=function(t){if(this.h.duration()){var i=this.localize("Remaining Time"),s=Nr(this.h.remainingTime());s!==this.At&&(this.At=s,this.T.innerHTML='<span class="vjs-control-text">'+i+"</span> -"+s)}},i}(i);i.registerComponent("RemainingTimeDisplay",Rr);var Ur=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).updateShowing(),e.on(e.player(),"durationchange",e.updateShowing),e.on(e.player(),"languagechange",e.handleLanguagechange),e}Vs(s,i);var e=s.prototype;return e.createEl=function(){var s=i.prototype.createEl.call(this,"div",{className:"vjs-live-control vjs-control"});return this.T=Ci("div",{className:"vjs-live-display"},{"aria-live":"off"}),this.xt=Ci("span",{className:"vjs-control-text",innerHTML:this.localize("Stream Type")}),this.Mt=t.createTextNode(this.localize("LIVE")),this.T.appendChild(this.xt),this.T.appendChild(this.Mt),s.appendChild(this.T),s},e.updateShowing=function(t){this.player().duration()===1/0?this.show():this.hide()},e.handleLanguagechange=function(){this.xt.innerHTML=this.localize("Stream Type"),this.Mt.innerHTML=this.localize("LIVE")},s}(i);i.registerComponent("LiveDisplay",Ur);var Vr=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).bar=e.getChild(e.o.barName),e.vertical(!!e.o.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(t,"controlsvisible",e.update),e.on(t,e.playerEvent,e.update),e}Vs(s,i);var e=s.prototype;return e.createEl=function(t,s,e){return void 0===s&&(s={}),void 0===e&&(e={}),s.className=s.className+" vjs-slider",s=di({tabIndex:0},s),e=di({role:"slider","aria-valuenow":0,"aria-valuemin":0,"aria-valuemax":100,tabIndex:0},e),i.prototype.createEl.call(this,t,s,e)},e.handleMouseDown=function(i){var s=this.bar.m.ownerDocument;i.preventDefault(),t.body.focus(),t.onselectstart=function(){return!1},this.addClass("vjs-sliding"),this.trigger("slideractive"),this.on(s,"mousemove",this.handleMouseMove),this.on(s,"mouseup",this.handleMouseUp),this.on(s,"touchmove",this.handleMouseMove),this.on(s,"touchend",this.handleMouseUp),this.handleMouseMove(i)},e.handleMouseMove=function(t){},e.handleMouseUp=function(){var i=this.bar.m.ownerDocument;t.onselectstart=function(){return!0},this.removeClass("vjs-sliding"),this.trigger("sliderinactive"),this.off(i,"mousemove",this.handleMouseMove),this.off(i,"mouseup",this.handleMouseUp),this.off(i,"touchmove",this.handleMouseMove),this.off(i,"touchend",this.handleMouseUp),this.update()},e.update=function(){if(this.m){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}}},e.calculateDistance=function(t){var i=zi(this.m,t);return this.vertical()?i.y:i.x},e.handleFocus=function(){this.on(this.bar.m.ownerDocument,"keydown",this.handleKeyPress)},e.handleKeyPress=function(t){37===t.which||40===t.which?(t.preventDefault(),this.stepBack()):38!==t.which&&39!==t.which||(t.preventDefault(),this.stepForward())},e.handleBlur=function(){this.off(this.bar.m.ownerDocument,"keydown",this.handleKeyPress)},e.handleClick=function(t){t.stopImmediatePropagation(),t.preventDefault()},e.vertical=function(t){return void 0===t?this.It||!1:(this.It=!!t,this.It?this.addClass("vjs-slider-vertical"):this.addClass("vjs-slider-horizontal"),this)},s}(i);function Lr(t,i){if(!t||!i)return"";if("function"==typeof o.getComputedStyle){var s=o.getComputedStyle(t);return s?s[i]:""}return t.currentStyle[i]||""}i.registerComponent("Slider",Vr);var Hr=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).Et=[],e.on(t,"progress",e.update),e.on(t,"languagechange",e.handleLanguagechange),e}Vs(s,i);var e=s.prototype;return e.createEl=function(){var s=i.prototype.createEl.call(this,"div",{className:"vjs-load-progress"});return this.Dt=Ci("span",{innerHTML:this.localize("Loaded")}),this.Ft=t.createTextNode(": 0%"),this.xt=Ci("span",{className:"vjs-control-text"}),this.xt.appendChild(this.Dt),this.xt.appendChild(this.Ft),s.appendChild(this.xt),s},e.update=function(t){var i=this.h.buffered(),s=this.h.duration(),e=this.h.bufferedEnd(),n=this.Et,r=function(t,i){var s=t/i||0;return 100*(s>=1?1:s)+"%"};this.m.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.m.appendChild(Ci()),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.m.removeChild(n[c-1]);n.length=i.length},e.handleLanguagechange=function(){this.Dt.innerHTML=this.localize("Loaded")},s}(i);i.registerComponent("LoadProgressBar",Hr);var zr=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).updateDataAttr(),e.on(t,"timeupdate",e.updateDataAttr),e.on(t,"languagechange",e.handleLanguagechange),t.ready(Ns(Rs(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}Vs(s,i);var e=s.prototype;return e.createEl=function(){var s=i.prototype.createEl.call(this,"div",{className:"vjs-play-progress vjs-slider-bar"});return this.Nt=Ci("span",{innerHTML:this.localize("Progress")}),this.$t=t.createTextNode(": 0%"),this.xt=Ci("span",{className:"vjs-control-text"}),this.xt.appendChild(this.Nt),this.xt.appendChild(this.$t),s.appendChild(this.xt),s},e.updateDataAttr=function(t){var i=this.h.scrubbing()?this.h.getCache().currentTime:this.h.currentTime();this.m.setAttribute("data-current-time",Nr(i,this.h.duration()))},e.handleLanguagechange=function(){this.Nt.innerHTML=this.localize("Progress")},s}(i);i.registerComponent("PlayProgressBar",zr);var Wr=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).updateDataAttr(),e.on(t,"timeupdate",e.updateDataAttr),e.on(t,"languagechange",e.handleLanguagechange),t.ready(Ns(Rs(e),e.updateDataAttr)),e}Vs(s,i);var e=s.prototype;return e.createEl=function(){var s=i.prototype.createEl.call(this,"div",{className:"vjs-tooltip-progress-bar vjs-slider-bar"});return this.tooltip=Ci("div",{className:"vjs-time-tooltip"}),this.Nt=Ci("span",{innerHTML:this.localize("Progress")}),this.$t=t.createTextNode(": 0%"),this.xt=Ci("span",{className:"vjs-control-text"}),this.xt.appendChild(this.Nt),this.xt.appendChild(this.$t),s.appendChild(this.tooltip),s.appendChild(this.xt),s},e.updateDataAttr=function(t){var i=Nr(this.h.scrubbing()?this.h.getCache().currentTime:this.h.currentTime(),this.h.duration());this.m.setAttribute("data-current-time",i),this.tooltip.innerHTML=i},e.handleLanguagechange=function(){this.Nt.innerHTML=this.localize("Progress")},s}(i);i.registerComponent("TooltipProgressBar",Wr);var qr=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(Ns(Rs(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}Vs(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.m),this.keepTooltipsInside){this.updateAriaAttributes(this.tooltipProgressBar.m),this.tooltipProgressBar.m.style.width=this.bar.m.style.width;var i=S(Lr(this.player().el(),"width")),s=S(Lr(this.tooltipProgressBar.tooltip,"width")),e=this.tooltipProgressBar.el().style;e.maxWidth=w.floor(i-s/2)+"px",e.minWidth=w.ceil(s/2)+"px",e.right="-"+s/2+"px"}},s.updateAriaAttributes=function(t){var i=this.h.scrubbing()?this.h.getCache().currentTime:this.h.currentTime();t.setAttribute("aria-valuenow",(100*this.getPercent()).toFixed(2)),t.setAttribute("aria-valuetext",Nr(i,this.h.duration()))},s.getPercent=function(){var t=this.h.currentTime()/this.h.duration();return t>=1?1:t},s.handleMouseDown=function(i){this.h.scrubbing(!0),this.videoWasPlaying=!this.h.paused(),this.h.pause(),t.prototype.handleMouseDown.call(this,i)},s.handleMouseMove=function(t){var i=this.calculateDistance(t)*this.h.duration();i===this.h.duration()&&(i-=.1),this.h.currentTime(i)},s.handleMouseUp=function(i){t.prototype.handleMouseUp.call(this,i),this.h.scrubbing(!1),this.videoWasPlaying&&this.h.play()},s.stepForward=function(){this.h.currentTime(this.h.currentTime()+5)},s.stepBack=function(){this.h.currentTime(this.h.currentTime()-5)},i}(Vr);qr.prototype.o={children:["loadProgressBar","mouseTimeDisplay","playProgressBar"],barName:"playProgressBar"},qr.prototype.playerEvent="timeupdate",i.registerComponent("SeekBar",qr);var Gr=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=Ci("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)}}(Ns(Rs(e),e.handleMouseMove),25))})),e}Vs(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.h.duration(),s=this.calculateDistance(t)*i,e=t.pageX-Hi(this.el().parentNode).left;this.update(s,e)},s.update=function(t,i){var s=Nr(t,this.h.duration());if(this.el().style.left=i+"px",this.el().setAttribute("data-current-time",s),this.keepTooltipsInside){var e=i-this.Bt(i)+1,n=S(Lr(this.tooltip,"width"))/2;this.tooltip.innerHTML=s,this.tooltip.style.right="-"+(n-e)+"px"}},s.calculateDistance=function(t){return zi(this.el().parentNode,t).x},s.Bt=function(t){if(!this.keepTooltipsInside)return t;var i=S(Lr(this.player().el(),"width")),s=S(Lr(this.tooltip,"width"))/2,e=t;return t<s?e=w.ceil(s):t>i-s&&(e=w.floor(i-s)),e},i}(i);i.registerComponent("MouseTimeDisplay",Gr);var Xr=function(t){function i(){return t.apply(this,arguments)||this}return Vs(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},i}(i);Xr.prototype.o={children:["seekBar"]},i.registerComponent("ProgressControl",Xr);var Qr=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"fullscreenchange",e.handleFullscreenChange),e}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-fullscreen-control "+t.prototype.buildCSSClass.call(this)},s.handleFullscreenChange=function(t){this.h.isFullscreen()?this.controlText("Non-Fullscreen"):this.controlText("Fullscreen")},s.handleClick=function(t){this.h.isFullscreen()?this.h.exitFullscreen():this.h.requestFullscreen()},i}(Ir);Qr.prototype.Tt="Fullscreen",i.registerComponent("FullscreenToggle",Qr);var Jr=function(t){function i(){return t.apply(this,arguments)||this}return Vs(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-level",innerHTML:'<span class="vjs-control-text"></span>'})},i}(i);i.registerComponent("VolumeLevel",Jr);var Yr=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.updateARIAAttributes),i.ready(Ns(Rs(e),e.updateARIAAttributes)),e}Vs(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.h.volume(this.calculateDistance(t))},s.checkMuted=function(){this.h.muted()&&this.h.muted(!1)},s.getPercent=function(){return this.h.muted()?0:this.h.volume()},s.stepForward=function(){this.checkMuted(),this.h.volume(this.h.volume()+.1)},s.stepBack=function(){this.checkMuted(),this.h.volume(this.h.volume()-.1)},s.updateARIAAttributes=function(t){var i=(100*this.h.volume()).toFixed(2);this.m.setAttribute("aria-valuenow",i),this.m.setAttribute("aria-valuetext",i+"%")},i}(Vr);Yr.prototype.o={children:["volumeLevel"],barName:"volumeLevel"},Yr.prototype.playerEvent="volumechange",i.registerComponent("VolumeBar",Yr);var Kr=function(t){function i(i,s){var e;return e=t.call(this,i,s)||this,i.W&&!1===i.W.featuresVolumeControl&&e.addClass("vjs-hidden"),e.on(i,"loadstart",(function(){!1===i.W.featuresVolumeControl?this.addClass("vjs-hidden"):this.removeClass("vjs-hidden")})),e}return Vs(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control"})},i}(i);Kr.prototype.o={children:["volumeBar"]},i.registerComponent("VolumeControl",Kr);var Zr=function(t){function i(){return t.apply(this,arguments)||this}Vs(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",Ns(this,(function(){this.unlockShowing()})))},s.createEl=function(){var i=this.o.contentElType||"ul";this.T=Ci(i,{className:"vjs-menu-content"});var s=t.prototype.createEl.call(this,"div",{append:this.T,className:"vjs-menu"});return s.appendChild(this.T),xs(s,"click",(function(t){t.preventDefault(),t.stopImmediatePropagation()})),s},i}(i);i.registerComponent("Popup",Zr);var th=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e}Vs(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.o.inline?i+="-inline":i+="-popup","vjs-menu-button "+i+" "+t.prototype.buildCSSClass.call(this)},i}(Sr);i.registerComponent("PopupButton",th);var ih=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"volumechange",e.update),i.W&&!1===i.W.featuresVolumeControl&&e.addClass("vjs-hidden"),e.on(i,"loadstart",(function(){this.update(),!1===i.W.featuresVolumeControl?this.addClass("vjs-hidden"):this.removeClass("vjs-hidden")})),e}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-mute-control "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.h.muted(!this.h.muted())},s.update=function(t){var i=this.h.volume(),s=3;this.h.muted()?s=0:i<.33?s=1:i<.67&&(s=2);var e=this.h.muted()?"Unmute":"Mute";this.controlText()!==e&&this.controlText(e);for(var n=0;n<4;n++)Bi(this.m,"vjs-vol-"+n);$i(this.m,"vjs-vol-"+s)},i}(Ir);ih.prototype.Tt="Mute",i.registerComponent("MuteToggle",ih);var sh=function(t){function i(i,s){var e;function n(){i.W&&!1===i.W.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(Rs(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}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){var i="";return i=this.o.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 Zr(this.h,{contentElType:"div"}),i=new Yr(this.h,this.o.volumeBar);return t.addChild(i),this.menuContent=t,this.volumeBar=i,this.attachVolumeBarEvents(),t},s.handleClick=function(i){ih.prototype.handleClick.call(this),t.prototype.handleClick.call(this)},s.attachVolumeBarEvents=function(){this.menuContent.on(["mousedown","touchdown"],Ns(this,this.handleMouseDown))},s.handleMouseDown=function(t){this.on(["mousemove","touchmove"],Ns(this.volumeBar,this.volumeBar.handleMouseMove)),this.on(this.m.ownerDocument,["mouseup","touchend"],this.handleMouseUp)},s.handleMouseUp=function(t){this.off(["mousemove","touchmove"],Ns(this.volumeBar,this.volumeBar.handleMouseMove))},i}(th);sh.prototype.volumeUpdate=ih.prototype.update,sh.prototype.Tt="Mute",i.registerComponent("VolumeMenuButton",sh);var eh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).Ot=-1,e.on("keydown",e.handleKeyPress),e}Vs(i,t);var s=i.prototype;return s.addItem=function(t){this.addChild(t),t.on("click",Ns(this,(function(t){this.unlockShowing()})))},s.createEl=function(){var i=this.o.contentElType||"ul";this.T=Ci(i,{className:"vjs-menu-content"}),this.T.setAttribute("role","menu");var s=t.prototype.createEl.call(this,"div",{append:this.T,className:"vjs-menu"});return s.setAttribute("role","presentation"),s.appendChild(this.T),xs(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.Ot&&(t=this.Ot+1),this.focus(t)},s.stepBack=function(){var t=0;void 0!==this.Ot&&(t=this.Ot-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.Ot=t,i[t].m.focus())},i}(i);i.registerComponent("Menu",eh);var nh=function(t){function i(i,s){var e;return void 0===s&&(s={}),(e=t.call(this,i,s)||this).update(),e.Rt=!0,e.m.setAttribute("aria-haspopup","true"),e.m.setAttribute("role","menuitem"),e.on("keydown",e.handleSubmenuKeyPress),e}Vs(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.Ut=!1,this.m.setAttribute("aria-expanded","false"),this.items&&this.items.length<=this.Vt?this.hide():this.show()},s.createMenu=function(){var t=new eh(this.h);if(this.Vt=0,this.o.title){var i=Ci("li",{className:"vjs-menu-title",innerHTML:$s(this.o.title),tabIndex:-1});this.Vt+=1,t.k.unshift(i),Ai(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.o.inline?i+="-inline":i+="-popup","vjs-menu-button "+i+" "+t.prototype.buildCSSClass.call(this)},s.handleClick=function(t){this.one(this.menu.contentEl(),"mouseleave",Ns(this,(function(t){this.unpressButton(),this.m.blur()}))),this.Ut?this.unpressButton():this.pressButton()},s.handleKeyPress=function(i){27===i.which||9===i.which?(this.Ut&&this.unpressButton(),9!==i.which&&i.preventDefault()):38===i.which||40===i.which?this.Ut||(this.pressButton(),i.preventDefault()):t.prototype.handleKeyPress.call(this,i)},s.handleSubmenuKeyPress=function(t){27!==t.which&&9!==t.which||(this.Ut&&this.unpressButton(),9!==t.which&&t.preventDefault())},s.pressButton=function(){this.Rt&&(this.Ut=!0,this.menu.lockShowing(),this.m.setAttribute("aria-expanded","true"),this.menu.focus())},s.unpressButton=function(){this.Rt&&(this.Ut=!1,this.menu.unlockShowing(),this.m.setAttribute("aria-expanded","false"),this.m.focus())},s.disable=function(){return this.Ut=!1,this.menu.unlockShowing(),this.m.setAttribute("aria-expanded","false"),this.Rt=!1,t.prototype.disable.call(this)},s.enable=function(){return this.Rt=!0,t.prototype.enable.call(this)},i}(Sr);i.registerComponent("MenuButton",nh);var rh=function(t){function i(i,s){var e,n=s.tracks;if((e=t.call(this,i,s)||this).items.length<=1&&e.hide(),!n)return Rs(e);var r=Ns(Rs(e),e.update);return n.addEventListener("removetrack",r),n.addEventListener("addtrack",r),e.h.on("dispose",(function(){n.removeEventListener("removetrack",r),n.removeEventListener("addtrack",r)})),e}return Vs(i,t),i}(nh);i.registerComponent("TrackButton",rh);var hh=function(i){function s(t,s){var e;return(e=i.call(this,t,s)||this).selectable=s.selectable,e.selected(s.selected),e.selectable?e.m.setAttribute("role","menuitemcheckbox"):e.m.setAttribute("role","menuitem"),e}Vs(s,i);var e=s.prototype;return e.createEl=function(s,e,n){this.nonIconControl=!0;var r=i.prototype.createEl.call(this,"li",di({className:"vjs-menu-item",tabIndex:-1},e),n);return this.Lt=t.createTextNode(this.localize(this.o.label)),r.appendChild(this.Lt),r},e.handleClick=function(t){this.selected(!0)},e.selected=function(t){this.selectable&&(t?(this.addClass("vjs-selected"),this.m.setAttribute("aria-checked","true"),this.controlText(", selected")):(this.removeClass("vjs-selected"),this.m.setAttribute("aria-checked","false"),this.controlText("")))},e.handleLanguagechange=function(){i.prototype.handleLanguagechange.call(this),this.Lt.innerHTML=this.localize(this.o.label)},s}(Sr);i.registerComponent("MenuItem",hh);var oh=function(i){function s(s,e){var n,r,h=e.track,a=s.textTracks();if(e.label=h.label||h.language||"Unknown",e.selected=h.default||"showing"===h.mode,(n=i.call(this,s,e)||this).track=h,a){var u=Ns(Rs(n),n.handleTracksChange);s.on(["loadstart","texttrackchange"],u),a.addEventListener("change",u),n.on("dispose",(function(){a.removeEventListener("change",u)}))}a&&void 0===a.onchange&&n.on(["tap","click"],(function(){if("object"!=typeof o.Event)try{r=new o.Event("change")}catch(t){}r||(r=t.createEvent("Event")).initEvent("change",!0,!0),a.dispatchEvent(r)}));return n}Vs(s,i);var e=s.prototype;return e.handleClick=function(t){var s=this.track.kind,e=this.h.textTracks();if(i.prototype.handleClick.call(this,t),e)for(var n=0;n<e.length;n++){var r=e[n];r.kind===s&&(r===this.track?"showing"!==r.mode&&(r.mode="showing"):"disabled"!==r.mode&&(r.mode="disabled"))}},e.handleTracksChange=function(t){this.selected("showing"===this.track.mode)},s}(hh);i.registerComponent("TextTrackMenuItem",oh);var ah=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 Vs(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}(oh);i.registerComponent("OffTextTrackMenuItem",ah);var uh=function(t){function i(i,s){return void 0===s&&(s={}),s.tracks=i.textTracks(),t.call(this,i,s)||this}return Vs(i,t),i.prototype.createItems=function(t){void 0===t&&(t=[]),t.push(new ah(this.h,{kind:this.Ht})),this.Vt+=1;var i=this.h.textTracks();if(!i)return t;for(var s=0;s<i.length;s++){var e=i[s];e.kind===this.Ht&&t.push(new oh(this.h,{track:e,selectable:!0}))}return t},i}(rh);i.registerComponent("TextTrackButton",uh);var ch=function(t){function i(i,s){var e,n=s.track,r=s.cue,h=i.currentTime();return s.selectable=!0,s.label=r.text,s.selected=r.startTime<=h&&h<r.endTime,(e=t.call(this,i,s)||this).track=n,e.cue=r,n.addEventListener("cuechange",Ns(Rs(e),e.update)),e}Vs(i,t);var s=i.prototype;return s.handleClick=function(i){t.prototype.handleClick.call(this),this.h.currentTime(this.cue.startTime),this.update(this.cue.startTime)},s.update=function(t){var i=this.cue,s=this.h.currentTime();this.selected(i.startTime<=s&&s<i.endTime)},i}(hh);i.registerComponent("ChaptersTrackMenuItem",ch);var lh=function(t){function i(i,s,e){var n;return(n=t.call(this,i,s,e)||this).m.setAttribute("aria-label","Chapters Menu"),n}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-chapters-button "+t.prototype.buildCSSClass.call(this)},s.update=function(i){this.zt&&(!i||"addtrack"!==i.type&&"removetrack"!==i.type)||this.setTrack(this.findChaptersTrack()),t.prototype.update.call(this)},s.setTrack=function(t){if(this.zt!==t){if(this.Wt||(this.Wt=this.update.bind(this)),this.zt){var i=this.h.remoteTextTrackEls().K(this.zt);i&&i.removeEventListener("load",this.Wt),this.zt=null}if(this.zt=t,this.zt){this.zt.mode="hidden";var s=this.h.remoteTextTrackEls().K(this.zt);s&&s.addEventListener("load",this.Wt)}}},s.findChaptersTrack=function(){for(var t=this.h.textTracks()||[],i=t.length-1;i>=0;i--){var s=t[i];if(s.kind===this.Ht)return s}},s.getMenuCaption=function(){return this.zt&&this.zt.label?this.zt.label:this.localize($s(this.Ht))},s.createMenu=function(){return this.o.title=this.getMenuCaption(),t.prototype.createMenu.call(this)},s.createItems=function(){var t=[];if(!this.zt)return t;var i=this.zt.cues;if(!i)return t;for(var s=0,e=i.length;s<e;s++){var n=i[s],r=new ch(this.h,{track:this.zt,cue:n});t.push(r)}return t},i}(uh);lh.prototype.Ht="chapters",lh.prototype.Tt="Chapters",i.registerComponent("ChaptersButton",lh);var fh=function(t){function i(i,s,e){var n;(n=t.call(this,i,s,e)||this).m.setAttribute("aria-label","Descriptions Menu");var r=i.textTracks();if(r){var h=Ns(Rs(n),n.handleTracksChange);r.addEventListener("change",h),n.on("dispose",(function(){r.removeEventListener("change",h)}))}return n}Vs(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.Ht&&"showing"===r.mode){s=!0;break}}s?this.disable():this.enable()},s.buildCSSClass=function(){return"vjs-descriptions-button "+t.prototype.buildCSSClass.call(this)},i}(uh);fh.prototype.Ht="descriptions",fh.prototype.Tt="Descriptions",i.registerComponent("DescriptionsButton",fh);var dh=function(t){function i(i,s,e){var n;return(n=t.call(this,i,s,e)||this).m.setAttribute("aria-label","Subtitles Menu"),n}return Vs(i,t),i.prototype.buildCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildCSSClass.call(this)},i}(uh);dh.prototype.Ht="subtitles",dh.prototype.Tt="Subtitles",i.registerComponent("SubtitlesButton",dh);var vh=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 Vs(i,t),i.prototype.handleClick=function(t){this.player().getChild("textTrackSettings").show(),this.player().getChild("textTrackSettings").m.focus()},i}(oh);i.registerComponent("CaptionSettingsMenuItem",vh);var ph=function(t){function i(i,s,e){var n;return(n=t.call(this,i,s,e)||this).m.setAttribute("aria-label","Captions Menu"),n}Vs(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().W&&this.player().W.featuresNativeTextTracks||(i.push(new vh(this.h,{kind:this.Ht})),this.Vt+=1),t.prototype.createItems.call(this,i)},i}(uh);ph.prototype.Ht="captions",ph.prototype.Tt="Captions",i.registerComponent("CaptionsButton",ph);var mh=function(t){function i(i,s){var e,n=s.track,r=i.audioTracks();if(s.label=n.label||n.language||"Unknown",s.selected=n.enabled,(e=t.call(this,i,s)||this).track=n,r){var h=Ns(Rs(e),e.handleTracksChange);r.addEventListener("change",h),e.on("dispose",(function(){r.removeEventListener("change",h)}))}return e}Vs(i,t);var s=i.prototype;return s.handleClick=function(i){var s=this.h.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}(hh);i.registerComponent("AudioTrackMenuItem",mh);var gh=function(t){function i(i,s){var e;return void 0===s&&(s={}),s.tracks=i.audioTracks&&i.audioTracks(),(e=t.call(this,i,s)||this).m.setAttribute("aria-label","Audio Menu"),e}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-audio-button "+t.prototype.buildCSSClass.call(this)},s.createItems=function(t){void 0===t&&(t=[]),this.Vt=1;var i=this.h.audioTracks&&this.h.audioTracks();if(!i)return t;for(var s=0;s<i.length;s++){var e=i[s];t.push(new mh(this.h,{track:e,selectable:!0}))}return t},i}(rh);gh.prototype.Tt="Audio Track",i.registerComponent("AudioTrackButton",gh);var yh=function(t){function i(i,s){var e,n=s.rate,r=S(n,10);return s.label=n,s.selected=1===r,s.selectable=!0,(e=t.call(this,i,s)||this).label=n,e.rate=r,e.on(i,"ratechange",e.update),e}Vs(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}(hh);yh.prototype.contentElType="button",i.registerComponent("PlaybackRateMenuItem",yh);var bh=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}Vs(i,t);var s=i.prototype;return s.createEl=function(){var i=t.prototype.createEl.call(this);return this.Lt=Ci("div",{className:"vjs-playback-rate-value",innerHTML:1}),i.appendChild(this.Lt),i},s.buildCSSClass=function(){return"vjs-playback-rate "+t.prototype.buildCSSClass.call(this)},s.createMenu=function(){var t=new eh(this.player()),i=this.playbackRates();if(i)for(var s=i.length-1;s>=0;s--)t.addChild(new yh(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.o.playbackRates||this.o.playerOptions&&this.o.playerOptions.playbackRates},s.playbackRateSupported=function(){return this.player().W&&this.player().W.featuresPlaybackRate&&this.playbackRates()&&this.playbackRates().length>0},s.updateVisibility=function(t){this.playbackRateSupported()?this.removeClass("vjs-hidden"):this.addClass("vjs-hidden")},s.updateLabel=function(t){this.playbackRateSupported()&&(this.Lt.innerHTML=this.player().playbackRate()+"x")},i}(nh);bh.prototype.Tt="Playback Rate",i.registerComponent("PlaybackRateMenuButton",bh);var kh=function(t){function i(){return t.apply(this,arguments)||this}Vs(i,t);var s=i.prototype;return s.buildCSSClass=function(){return"vjs-spacer "+t.prototype.buildCSSClass.call(this)},s.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass()})},i}(i);i.registerComponent("Spacer",kh);var wh=function(t){function i(){return t.apply(this,arguments)||this}Vs(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}(kh);i.registerComponent("CustomControlSpacer",wh);var jh=function(t){function i(){return t.apply(this,arguments)||this}return Vs(i,t),i.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"},{role:"group"})},i}(i);jh.prototype.o={children:["playToggle","volumeMenuButton","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subtitlesButton","captionsButton","audioTrackButton","fullscreenToggle"]},i.registerComponent("ControlBar",jh);var Sh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).on(i,"error",e.open),e}Vs(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}(re);Sh.prototype.o=Bs(re.prototype.o,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),i.registerComponent("ErrorDisplay",Sh);var _h="vjs-text-track-settings",xh=["#000","Black"],Th=["#00F","Blue"],Ch=["#0FF","Cyan"],Ph=["#0F0","Green"],Ah=["#F0F","Magenta"],Mh=["#F00","Red"],Ih=["#FFF","White"],Eh=["#FF0","Yellow"],Dh=["1","Opaque"],Fh=["0.5","Semi-Transparent"],Nh=["0","Transparent"],$h={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[xh,Ih,Mh,Ph,Th,Eh,Ah,Ch]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[Dh,Fh,Nh]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[Ih,xh,Mh,Ph,Th,Eh,Ah,Ch]},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:[Dh,Fh]},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:[Nh,Fh,Dh]}};function Bh(t,i){if(i&&(t=i(t)),t&&"none"!==t)return t}$h.windowColor.options=$h.backgroundColor.options;var Oh,Rh=function(t){function i(i,s){var e;return(e=t.call(this,i,s)||this).setDefaults(),e.hide(),e.updateDisplay=Ns(Rs(e),e.updateDisplay),void 0===s.persistTextTrackSettings&&(e.o.persistTextTrackSettings=e.o.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()})),fi($h,(function(t){e.on(e.$(t.selector),"change",e.updateDisplay)})),e.o.persistTextTrackSettings&&e.restoreSettings(),e}Vs(i,t);var s=i.prototype;return s.qt=function(t){var i=this,s=$h[t],e=s.id.replace("%s",this.u);return[Ci("label",{className:"vjs-label",textContent:s.label},{for:e}),Ci("select",{id:e},void 0,s.options.map((function(t){return Ci("option",{textContent:i.localize(t[1]),value:t[0]})})))]},s.Gt=function(){var t=Ci("legend",{textContent:this.localize("Text")}),i=this.qt("color"),s=Ci("span",{className:"vjs-text-opacity vjs-opacity"},void 0,this.qt("textOpacity"));return Ci("fieldset",{className:"vjs-fg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Xt=function(){var t=Ci("legend",{textContent:this.localize("Background")}),i=this.qt("backgroundColor"),s=Ci("span",{className:"vjs-bg-opacity vjs-opacity"},void 0,this.qt("backgroundOpacity"));return Ci("fieldset",{className:"vjs-bg-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Qt=function(){var t=Ci("legend",{textContent:this.localize("Window")}),i=this.qt("windowColor"),s=Ci("span",{className:"vjs-window-opacity vjs-opacity"},void 0,this.qt("windowOpacity"));return Ci("fieldset",{className:"vjs-window-color vjs-tracksetting"},void 0,[t].concat(i,s))},s.Jt=function(){return Ci("div",{className:"vjs-tracksettings-colors"},void 0,[this.Gt(),this.Xt(),this.Qt()])},s.Yt=function(){var t=Ci("div",{className:"vjs-font-percent vjs-tracksetting"},void 0,this.qt("fontPercent")),i=Ci("div",{className:"vjs-edge-style vjs-tracksetting"},void 0,this.qt("edgeStyle")),s=Ci("div",{className:"vjs-font-family vjs-tracksetting"},void 0,this.qt("fontFamily"));return Ci("div",{className:"vjs-tracksettings-font"},void 0,[t,i,s])},s.Kt=function(){var t=Ci("button",{className:"vjs-default-button",textContent:this.localize("Defaults")}),i=Ci("button",{className:"vjs-done-button",textContent:"Done"});return Ci("div",{className:"vjs-tracksettings-controls"},void 0,[t,i])},s.createEl=function(){var t=Ci("div",{className:"vjs-tracksettings"},void 0,[this.Jt(),this.Yt(),this.Kt()]),i=Ci("div",{className:"vjs-control-text",id:"TTsettingsDialogLabel-"+this.u,textContent:"Caption Settings Dialog"},{"aria-level":"1",role:"heading"}),s=Ci("div",{className:"vjs-control-text",id:"TTsettingsDialogDescription-"+this.u,textContent:"Beginning of dialog window. Escape will cancel and close the window."}),e=Ci("div",void 0,{role:"document"},[i,s,t]);return Ci("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),li(t).reduce((function(s,e){return i(s,t[e],e)}),s)}($h,(function(i,s,e){var n=function(t,i){return Bh(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;fi($h,(function(s,e){!function(t,i,s){if(i)for(var e=0;e<t.options.length;e++)if(Bh(t.options[e].value,s)===i){t.selectedIndex=e;break}}(i.$(s.selector),t[e],s.parser)}))},s.setDefaults=function(){var t=this;fi($h,(function(i){var s=i.hasOwnProperty("default")?i.default:0;t.$(i.selector).selectedIndex=s}))},s.restoreSettings=function(){var t;try{t=JSON.parse(o.localStorage.getItem(_h))}catch(t){gi.warn(t)}t&&this.setValues(t)},s.saveSettings=function(){if(this.o.persistTextTrackSettings){var t=this.getValues();try{k.keys(t).length?o.localStorage.setItem(_h,JSON.stringify(t)):o.localStorage.removeItem(_h)}catch(t){gi.warn(t)}}},s.updateDisplay=function(){var t=this.h.getChild("textTrackDisplay");t&&t.updateDisplay()},i}(i);i.registerComponent("TextTrackSettings",Rh);var Uh,Vh=function(i){function s(t,s){var e;e=i.call(this,t,s)||this;var n=t.source,r=!1;if(n&&(e.m.currentSrc!==n.src||t.tag&&3===t.tag.Zt)?e.setSource(n):e.ti(e.m),e.m.hasChildNodes()){for(var h=e.m.childNodes,o=h.length,a=[];o--;){var u=h[o];"track"===u.nodeName.toLowerCase()&&(e.featuresNativeTextTracks?(e.remoteTextTrackEls().Y(u),e.remoteTextTracks().it(u.track),r||e.m.hasAttribute("crossorigin")||!de(u.src)||(r=!0)):a.push(u))}for(var c=0;c<a.length;c++)e.m.removeChild(a[c])}return["audio","video"].forEach((function(t){var i=e.el()[t+"Tracks"],s=e[t+"Tracks"](),n=$s(t);e["featuresNative"+n+"Tracks"]&&i&&i.addEventListener&&(e["handle"+n+"ii"]=function(t){s.trigger({type:"change",target:s,currentTarget:s,srcElement:s})},e["handle"+n+"si"]=function(t){return s.addTrack(t.track)},e["handle"+n+"ei"]=function(t){return s.removeTrack(t.track)},i.addEventListener("change",e["handle"+n+"ii"]),i.addEventListener("addtrack",e["handle"+n+"si"]),i.addEventListener("removetrack",e["handle"+n+"ei"]),e["removeOld"+n+"ni"]=function(t){return e.ri(s,i)},e.on("loadstart",e["removeOld"+n+"ni"]))})),e.featuresNativeTextTracks&&(r&&gi.warn(wi(Oh||(Oh=hi(["Text Tracks are being loaded from another origin but the crossorigin attribute isn't used.\n This may prevent text tracks from loading."])))),e.hi=Ns(Rs(e),e.handleTextTrackChange),e.oi=Ns(Rs(e),e.handleTextTrackAdd),e.ai=Ns(Rs(e),e.handleTextTrackRemove),e.ci()),e.fi(),(gs||is||as)&&!0===t.nativeControlsForTouch&&e.setControls(!0),e.di(),e.triggerReady(),e}Vs(s,i);var e=s.prototype;return e.dispose=function(){var t=this;["audio","video","text"].forEach((function(i){var s=$s(i),e=t.m[i+"Tracks"];e&&e.removeEventListener&&(e.removeEventListener("change",t["handle"+s+"ii"]),e.removeEventListener("addtrack",t["handle"+s+"si"]),e.removeEventListener("removetrack",t["handle"+s+"ei"])),e&&t.off("loadstart",t["removeOld"+s+"ni"])})),s.disposeMediaElement(this.m),i.prototype.dispose.call(this)},e.fi=function(){var t,i=this.textTracks(),s=function(){t=[];for(var s=0;s<i.length;s++){var e=i[s];"metadata"===e.kind&&t.push({track:e,storedMode:e.mode})}};s(),i.addEventListener("change",s);var e=function s(){for(var e=0;e<t.length;e++){var n=t[e];"disabled"===n.track.mode&&n.track.mode!==n.storedMode&&(n.track.mode=n.storedMode)}i.removeEventListener("change",s)};this.on("webkitbeginfullscreen",(function(){i.removeEventListener("change",s),i.removeEventListener("change",e),i.addEventListener("change",e)})),this.on("webkitendfullscreen",(function(){i.removeEventListener("change",s),i.addEventListener("change",s),i.removeEventListener("change",e)}))},e.createEl=function(){var i=this.o.tag;if(!i||!this.o.playerElIngest&&!this.movingMediaElementInDOM){if(i){var e=i.cloneNode(!0);i.parentNode&&i.parentNode.insertBefore(e,i),s.disposeMediaElement(i),i=e}else{i=t.createElement("video");var n=Bs({},this.o.tag&&Ui(this.o.tag));gs&&!0===this.o.nativeControlsForTouch||delete n.controls,Ri(i,di(n,{id:this.o.techId,class:"vjs-tech"}))}i.playerId=this.o.playerId}void 0!==this.o.preload&&Vi(i,"preload",this.o.preload);for(var r=["loop","muted","playsinline","autoplay"],h=r.length-1;h>=0;h--){var o=r[h],a=this.o[o];void 0!==a&&(a?Vi(i,o,o):Li(i,o),i[o]=a)}return i},e.ti=function(t){if(0!==t.networkState&&3!==t.networkState){if(0===t.readyState){var i=!1,s=function(){i=!0};this.on("loadstart",s);var e=function(){i||this.trigger("loadstart")};return this.on("loadedmetadata",e),void this.ready((function(){this.off("loadstart",s),this.off("loadedmetadata",e),i||this.trigger("loadstart")}))}var n=["loadstart"];n.push("loadedmetadata"),t.readyState>=2&&n.push("loadeddata"),t.readyState>=3&&n.push("canplay"),t.readyState>=4&&n.push("canplaythrough"),this.ready((function(){n.forEach((function(t){this.trigger(t)}),this)}))}},e.ci=function(){var t=this.el().textTracks;if(t){for(var i=0;i<t.length;i++)this.textTracks().it(t[i]);t.addEventListener&&(t.addEventListener("change",this.hi),t.addEventListener("addtrack",this.oi),t.addEventListener("removetrack",this.ai)),this.on("loadstart",this.vi)}},e.handleTextTrackChange=function(t){var i=this.textTracks();this.textTracks().trigger({type:"change",target:i,currentTarget:i,srcElement:i})},e.handleTextTrackAdd=function(t){this.textTracks().it(t.track)},e.handleTextTrackRemove=function(t){this.textTracks().st(t.track)},e.ri=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.st(a)}}},e.vi=function(t){var i=this.textTracks(),s=this.el().textTracks;this.ri(i,s)},e.play=function(){var t=this.m.play();void 0!==t&&"function"==typeof t.then&&t.then(null,(function(t){}))},e.setCurrentTime=function(t){try{this.m.currentTime=t}catch(t){gi(t,"Video is not ready. (Video.js)")}},e.duration=function(){var t=this;if(this.m.duration===1/0&&rs&&ls&&0===this.m.currentTime){return this.on("timeupdate",(function i(){t.m.currentTime>0&&(t.m.duration===1/0&&t.trigger("durationchange"),t.off("timeupdate",i))})),NaN}return this.m.duration||NaN},e.width=function(){return this.m.offsetWidth},e.height=function(){return this.m.offsetHeight},e.di=function(){var t=this;if("webkitDisplayingFullscreen"in this.m){var i=function(){this.trigger("fullscreenchange",{isFullscreen:!1})},s=function(){"webkitPresentationMode"in this.m&&"picture-in-picture"!==this.m.webkitPresentationMode&&(this.one("webkitendfullscreen",i),this.trigger("fullscreenchange",{isFullscreen:!0,nativeIOSFullscreen:!0}))};this.on("webkitbeginfullscreen",s),this.on("dispose",(function(){t.off("webkitbeginfullscreen",s),t.off("webkitendfullscreen",i)}))}},e.supportsFullScreen=function(){if("function"==typeof this.m.webkitEnterFullScreen){var t=o.navigator&&o.navigator.userAgent||"";if(/Android/.test(t)||!/Chrome|Mac OS X 10.5/.test(t))return!0}return!1},e.enterFullScreen=function(){var t=this.m;t.paused&&t.networkState<=t.HAVE_METADATA?(this.m.play(),this.setTimeout((function(){t.pause(),t.webkitEnterFullScreen()}),0)):t.webkitEnterFullScreen()},e.exitFullScreen=function(){this.m.webkitExitFullScreen()},e.src=function(t){if(void 0===t)return this.m.src;this.setSrc(t)},e.reset=function(){s.resetMediaElement(this.m)},e.currentSrc=function(){return this.kt?this.kt.src:this.m.currentSrc},e.setControls=function(t){this.m.controls=!!t},e.addTextTrack=function(t,s,e){return this.featuresNativeTextTracks?this.m.addTextTrack(t,s,e):i.prototype.addTextTrack.call(this,t,s,e)},e.createRemoteTextTrack=function(s){if(!this.featuresNativeTextTracks)return i.prototype.createRemoteTextTrack.call(this,s);var e=t.createElement("track");return s.kind&&(e.kind=s.kind),s.label&&(e.label=s.label),(s.language||s.srclang)&&(e.srclang=s.language||s.srclang),s.default&&(e.default=s.default),s.id&&(e.id=s.id),s.src&&(e.src=s.src),e},e.addRemoteTextTrack=function(t,s){var e=i.prototype.addRemoteTextTrack.call(this,t,s);return this.featuresNativeTextTracks&&this.el().appendChild(e),e},e.removeRemoteTextTrack=function(t){if(i.prototype.removeRemoteTextTrack.call(this,t),this.featuresNativeTextTracks)for(var s=this.$$("track"),e=s.length;e--;)t!==s[e]&&t!==s[e].track||this.el().removeChild(s[e])},e.getVideoPlaybackQuality=function(){if("function"==typeof this.el().getVideoPlaybackQuality)return this.el().getVideoPlaybackQuality();var t={};return void 0!==this.el().webkitDroppedFrameCount&&void 0!==this.el().webkitDecodedFrameCount&&(t.droppedVideoFrames=this.el().webkitDroppedFrameCount,t.totalVideoFrames=this.el().webkitDecodedFrameCount),o.performance&&"function"==typeof o.performance.now?t.creationTime=o.performance.now():o.performance&&o.performance.timing&&"number"==typeof o.performance.timing.navigationStart&&(t.creationTime=o.Date.now()-o.performance.timing.navigationStart),t},s}(wr);_i()&&(Vh.TEST_VID=t.createElement("video"),(Uh=t.createElement("track")).kind="captions",Uh.srclang="en",Uh.label="English",Vh.TEST_VID.appendChild(Uh)),Vh.isSupported=function(){try{Vh.TEST_VID.volume=.5}catch(t){return!1}return!(!Vh.TEST_VID||!Vh.TEST_VID.canPlayType)},Vh.canControlVolume=function(){try{var t=Vh.TEST_VID.volume;return Vh.TEST_VID.volume=t/2+.1,t!==Vh.TEST_VID.volume}catch(t){return!1}},Vh.canControlPlaybackRate=function(){if(rs&&ls&&fs<58)return!1;try{var t=Vh.TEST_VID.playbackRate;return Vh.TEST_VID.playbackRate=t/2+.1,t!==Vh.TEST_VID.playbackRate}catch(t){return!1}},Vh.supportsNativeTextTracks=function(){return ms},Vh.supportsNativeVideoTracks=function(){return!(!Vh.TEST_VID||!Vh.TEST_VID.videoTracks)},Vh.supportsNativeAudioTracks=function(){return!(!Vh.TEST_VID||!Vh.TEST_VID.audioTracks)},Vh.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange"],Vh.prototype.featuresVolumeControl=Vh.canControlVolume(),Vh.prototype.featuresPlaybackRate=Vh.canControlPlaybackRate(),Vh.prototype.movingMediaElementInDOM=!es,Vh.prototype.featuresFullscreenResize=!0,Vh.prototype.featuresProgressEvents=!0,Vh.prototype.featuresTimeupdateEvents=!0,Vh.prototype.featuresNativeTextTracks=Vh.supportsNativeTextTracks(),Vh.prototype.featuresNativeVideoTracks=Vh.supportsNativeVideoTracks(),Vh.prototype.featuresNativeAudioTracks=Vh.supportsNativeAudioTracks();var Lh=Vh.TEST_VID&&Vh.TEST_VID.constructor.prototype.canPlayType,Hh=/^application\/(?:x-|vnd\.apple\.)mpegurl/i,zh=/^video\/mp4/i;Vh.patchCanPlayType=function(){hs>=4&&!us?Vh.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&Hh.test(t)?"maybe":Lh.call(this,t)}:os&&(Vh.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&zh.test(t)?"maybe":Lh.call(this,t)})},Vh.unpatchCanPlayType=function(){var t=Vh.TEST_VID.constructor.prototype.canPlayType;return Vh.TEST_VID.constructor.prototype.canPlayType=Lh,t},Vh.patchCanPlayType(),Vh.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){}}()}}},Vh.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){Vh.prototype[t]=function(){return this.m[t]||this.m.hasAttribute(t)}})),["muted","defaultMuted","autoplay","loop","playsinline"].forEach((function(t){Vh.prototype["set"+$s(t)]=function(i){this.m[t]=i,i?this.m.setAttribute(t,t):this.m.removeAttribute(t)}})),["paused","currentTime","buffered","volume","poster","preload","error","seeking","seekable","ended","playbackRate","played","networkState","readyState","videoWidth","videoHeight"].forEach((function(t){Vh.prototype[t]=function(){return this.m[t]}})),["volume","src","poster","preload","playbackRate"].forEach((function(t){Vh.prototype["set"+$s(t)]=function(i){this.m[t]=i}})),["pause","load"].forEach((function(t){Vh.prototype[t]=function(){return this.m[t]()}})),wr.withSourceHandlers(Vh),Vh.nativeSourceHandler={},Vh.nativeSourceHandler.canPlayType=function(t){try{return Vh.TEST_VID.canPlayType(t)}catch(t){return""}},Vh.nativeSourceHandler.canHandleSource=function(t,i){if(t.type)return Vh.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 Vh.nativeSourceHandler.canPlayType("video/"+s)}return""},Vh.nativeSourceHandler.handleSource=function(t,i,s){i.setSrc(t.src)},Vh.nativeSourceHandler.dispose=function(){},Vh.registerSourceHandler(Vh.nativeSourceHandler),i.registerComponent("Html5",Vh),wr.registerTech("Html5",Vh);var Wh=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","ratechange","volumechange","texttrackchange"],qh=function(s){function e(t,i,n){var r;if(t.id=t.id||["vjs_video",ai()].join("_"),(i=di(e.getTagSettings(t),i)).initChildren=!1,i.createEl=!1,i.reportTouchActivity=!1,!i.language)if("function"==typeof t.closest){var h=t.closest("[lang]");h&&(i.language=h.getAttribute("lang"))}else for(var o=t;o&&1===o.nodeType;){if(Ui(o).hasOwnProperty("lang")){i.language=o.getAttribute("lang");break}o=o.parentNode}if(!(r=s.call(this,null,i,n)||this).o||!r.o.techOrder||!r.o.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=t,r.tagAttributes=t&&Ui(t),r.language(r.o.language),i.languages){var a={};k.getOwnPropertyNames(i.languages).forEach((function(t){a[t.toLowerCase()]=i.languages[t]})),r.pi=a}else r.pi=e.prototype.o.languages;r.mi={},r.gi=i.poster||"",r.yi=!!i.controls,t.controls=!1,r.bi=!1,r.m=r.createEl();var u=Bs(r.o);if(i.plugins){var c=i.plugins;k.getOwnPropertyNames(c).forEach((function(t){"function"==typeof this[t]?this[t](c[t]):gi.error("Unable to find plugin:",t)}),Rs(r))}r.o.playerOptions=u,r.initChildren(),r.isAudio("audio"===t.nodeName.toLowerCase()),r.controls()?r.addClass("vjs-controls-enabled"):r.addClass("vjs-controls-disabled"),r.m.setAttribute("role","region"),r.isAudio()?r.m.setAttribute("aria-label","audio player"):r.m.setAttribute("aria-label","video player"),r.isAudio()&&r.addClass("vjs-audio"),r.ki()&&r.addClass("vjs-no-flex"),es||r.addClass("vjs-workinghover"),e.players[r.u]=Rs(r);var l="5.20.6-opentelly.12".split(".")[0];return r.addClass("vjs-v"+l),r.userActive(!0),r.reportUserActivity(),r.wi(),r.on("fullscreenchange",r.ji),r.on("stageclick",r.Si),r}Vs(e,s);var n=e.prototype;return n.dispose=function(){this.trigger("dispose"),this.off("dispose"),this._i&&this._i.parentNode&&this._i.parentNode.removeChild(this._i),e.players[this.u]=null,this.tag&&this.tag.player&&(this.tag.player=null),this.m&&this.m.player&&(this.m.player=null),this.W&&this.W.dispose(),s.prototype.dispose.call(this)},n.createEl=function(){var t,i=this.tag,e=this.xi=i.parentNode&&i.parentNode.hasAttribute&&i.parentNode.hasAttribute("data-vjs-player");t=this.m=e?i.parentNode:s.prototype.createEl.call(this,"div"),i.setAttribute("tabindex","-1"),i.removeAttribute("width"),i.removeAttribute("height");var n=Ui(i);if(k.getOwnPropertyNames(n).forEach((function(i){"class"===i?t.className+=" "+n[i]:t.setAttribute(i,n[i])})),i.playerId=i.id,i.id+="Ti",i.className="vjs-tech",i.player=t.player=this,this.addClass("vjs-paused"),!0!==o.VIDEOJS_NO_DYNAMIC_STYLE){this._i=Ds("vjs-styles-dimensions");var r=Qi(".vjs-styles-defaults"),h=Qi("head");h.insertBefore(this._i,r?r.nextSibling:h.firstChild)}this.width(this.o.width),this.height(this.o.height),this.fluid(this.o.fluid),this.aspectRatio(this.o.aspectRatio);for(var a=i.getElementsByTagName("a"),u=0;u<a.length;u++){var c=a.item(u);$i(c,"vjs-hidden"),c.setAttribute("hidden","hidden")}return i.Zt=i.networkState,i.parentNode&&!e&&i.parentNode.insertBefore(t,i),Ai(i,t),this.k.unshift(i),this.m=t,t},n.width=function(t){return this.dimension("width",t)},n.height=function(t){return this.dimension("height",t)},n.dimension=function(t,i){var s="width"===t?"Ci":"Pi";if(void 0===i)return this[s]||0;if(""===i)this[s]=void 0;else{var e=S(i);if(_(e))return gi.error('Improper value "'+i+'" supplied for for '+t),this;this[s]=e}return this.Ai(),this},n.fluid=function(t){if(void 0===t)return!!this.Mi;this.Mi=!!t,t?this.addClass("vjs-fluid"):this.removeClass("vjs-fluid"),this.Ai()},n.aspectRatio=function(t){if(void 0===t)return this.Ii;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.Ii=t,this.fluid(!0),this.Ai()},n.Ai=function(){if(!0!==o.VIDEOJS_NO_DYNAMIC_STYLE){var t,i,s,e=(void 0!==this.Ii&&"auto"!==this.Ii?this.Ii:this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9").split(":"),n=e[1]/e[0];t=void 0!==this.Ci?this.Ci:void 0!==this.Pi?this.Pi/n:this.videoWidth()||300,i=void 0!==this.Pi?this.Pi:t*n,s=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(s),Fs(this._i,"\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.Ci?this.Ci:this.o.width,h="number"==typeof this.Pi?this.Pi:this.o.height,a=this.W&&this.W.el();a&&(r>=0&&(a.width=r),h>=0&&(a.height=h))}},n.St=function(t,s){var e=this;this.W&&this.Ei(),"Html5"!==t&&this.tag&&(wr.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.Di=t,this.C=!1;var n=di({source:s,nativeControlsForTouch:this.o.nativeControlsForTouch,playerId:this.id(),techId:this.id()+"_"+t+"Fi",videoTracks:this.ht,textTracks:this.rt,audioTracks:this.ot,autoplay:this.o.autoplay,playsinline:this.o.playsinline,preload:this.o.preload,loop:this.o.loop,muted:this.o.muted,poster:this.poster(),language:this.language(),playerElIngest:this.xi||!1,"vtt.js":this.o["vtt.js"]},this.o[t.toLowerCase()]);this.tag&&(n.tag=this.tag),s&&(this.Ni=s.type,s.src===this.mi.src&&this.mi.currentTime>0&&(n.startTime=this.mi.currentTime),this.mi.sources=null,this.mi.source=s,this.mi.src=s.src);var r=wr.getTech(t);r||(r=i.getComponent(t)),this.W=new r(n),this.W.ready(Ns(this,this.$i),!0),ee(this.Bi||[],this.W),Wh.forEach((function(t){e.on(e.W,t,e["handleTech"+$s(t)+"_"])})),this.on(this.W,"loadstart",this.Oi),this.on(this.W,"waiting",this.Ri),this.on(this.W,"canplay",this.Ui),this.on(this.W,"canplaythrough",this.Vi),this.on(this.W,"playing",this.Li),this.on(this.W,"ended",this.Hi),this.on(this.W,"seeking",this.zi),this.on(this.W,"seeked",this.Wi),this.on(this.W,"play",this.qi),this.on(this.W,"firstplay",this.Gi),this.on(this.W,"pause",this.Xi),this.on(this.W,"durationchange",this.Qi),this.on(this.W,"fullscreenchange",this.Ji),this.on(this.W,"error",this.Yi),this.on(this.W,"loadedmetadata",this.Ai),this.on(this.W,"resize",this.Ai),this.on(this.W,"posterchange",this.Ki),this.on(this.W,"textdata",this.Zi),this.usingNativeControls(this.ts("controls")),this.controls()&&!this.usingNativeControls()&&this.ss(),this.W.el().parentNode===this.contentEl()||"Html5"===t&&this.tag||Ai(this.W.el(),this.contentEl()),this.tag&&(this.tag.player=null,this.tag=null)},n.Ei=function(){this.ht=this.videoTracks(),this.rt=this.textTracks(),this.ot=this.audioTracks(),this.Bi=se(this.W),this.C=!1,this.W.dispose(),this.W=!1},n.tech=function(t){if(t&&t.IWillNotUseThisInPlugins)return this.W;var i="\n Please make sure that you are not using this inside of a plugin.\n To disable this alert and error, please pass in an object with\n `IWillNotUseThisInPlugins` to the `tech` method. See\n https://github.com/videojs/video.js/issues/2617 for more info.\n ";throw o.alert(i),new m(i)},n.ss=function(){this.es(),this.on(this.W,"mousedown",this.ns),this.on(this.W,"touchstart",this.rs),this.on(this.W,"touchmove",this.hs),this.on(this.W,"touchend",this.os),this.on(this.W,"tap",this.us)},n.es=function(){this.off(this.W,"tap",this.us),this.off(this.W,"touchstart",this.rs),this.off(this.W,"touchmove",this.hs),this.off(this.W,"touchend",this.os),this.off(this.W,"mousedown",this.ns)},n.$i=function(){if(this.triggerReady(),this.mi.volume&&this.cs("setVolume",this.mi.volume),this.Ki(),this.Qi(),(this.src()||this.currentSrc())&&this.tag&&this.o.autoplay&&this.paused()){try{delete this.tag.poster}catch(t){gi("deleting tag.poster throws in some browsers",t)}this.play()}},n.Oi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-seeking"),this.error(null),this.paused()?(this.hasStarted(!1),this.trigger("loadstart")):(this.trigger("loadstart"),this.trigger("firstplay"))},n.hasStarted=function(t){return void 0!==t?(this.nt!==t&&(this.nt=t,t?(this.addClass("vjs-has-started"),this.trigger("firstplay")):this.removeClass("vjs-has-started")),this):!!this.nt},n.qi=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},n.Ri=function(){var t=this;this.addClass("vjs-waiting"),this.trigger("waiting"),this.one("timeupdate",(function(){return t.removeClass("vjs-waiting")}))},n.Ui=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},n.Vi=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},n.Li=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},n.zi=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},n.Wi=function(){this.removeClass("vjs-seeking"),this.trigger("seeked")},n.Gi=function(){this.o.starttime&&(gi.warn("Passing the `starttime` option to the player will be deprecated in 6.0"),this.currentTime(this.o.starttime)),this.addClass("vjs-has-started"),this.trigger("firstplay")},n.Xi=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},n.Hi=function(){this.addClass("vjs-ended"),this.o.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},n.Qi=function(){this.duration(this.ts("duration"))},n.ns=function(t){0===t.button&&this.controls()&&(void 0!==this.o&&void 0!==this.o.userActions&&void 0!==this.o.userActions.click&&!1===this.o.userActions.click||(void 0!==this.o&&void 0!==this.o.userActions&&"function"==typeof this.o.userActions.click?this.o.userActions.click.call(this,t):this.paused()?this.play():this.pause()))},n.us=function(){this.userActive(!this.userActive())},n.rs=function(){this.userWasActive=this.userActive()},n.hs=function(){this.userWasActive&&this.reportUserActivity()},n.os=function(t){t.cancelable&&t.preventDefault()},n.ji=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},n.Si=function(){this.reportUserActivity()},n.Ji=function(t,i){i&&(this.toggleClass("vjs-ios-native-fs",!(!i.nativeIOSFullscreen||!i.isFullscreen)),this.isFullscreen(i.isFullscreen)),this.trigger("fullscreenchange")},n.Yi=function(){var t=this.W.error();this.error(t)},n.Zi=function(){var t=null;arguments.length>1&&(t=arguments[1]),this.trigger("textdata",t)},n.getCache=function(){return this.mi},n.cs=function(t,i){if(this.W&&!this.W.C)this.W.ready((function(){this[t](i)}),!0);else try{this.W&&this.W[t](i)}catch(t){throw gi(t),t}},n.ts=function(t){if(this.W&&this.W.C)try{return this.W[t]()}catch(i){throw void 0===this.W[t]?gi("Video.js: "+t+" method not defined for "+this.Di+" playback technology.",i):"TypeError"===i.name?(gi("Video.js: "+t+" unavailable on "+this.Di+" playback technology element.",i),this.W.C=!1):gi(i),i}},n.play=function(){return this.src()||this.currentSrc()?this.cs("play"):this.W.one("loadstart",(function(){this.play()})),this},n.pause=function(){return this.cs("pause"),this},n.paused=function(){return!1!==this.ts("paused")},n.scrubbing=function(t){return void 0!==t?(this.bi=!!t,t?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing"),this):this.bi},n.currentTime=function(t){return void 0!==t?(this.cs("setCurrentTime",t),this):(this.mi.currentTime=this.ts("currentTime")||0,this.mi.currentTime)},n.duration=function(t){return void 0===t?void 0!==this.mi.duration?this.mi.duration:NaN:((t=S(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)},n.remainingTime=function(){return this.duration()-this.currentTime()},n.buffered=function(){var t=this.ts("buffered");return t&&t.length||(t=zs(0,0)),t},n.bufferedPercent=function(){return Ws(this.buffered(),this.duration())},n.bufferedEnd=function(){var t=this.buffered(),i=this.duration(),s=t.end(t.length-1);return s>i&&(s=i),s},n.volume=function(t){var i;return void 0!==t?(i=w.max(0,w.min(1,S(t))),this.mi.volume=i,this.cs("setVolume",i),this):(i=S(this.ts("volume")),_(i)?1:i)},n.muted=function(t){return void 0!==t?(this.cs("setMuted",t),this):this.ts("muted")||!1},n.supportsFullScreen=function(){return this.ts("supportsFullScreen")||!1},n.isFullscreen=function(t){return void 0!==t?(this.ls=!!t,this):!!this.ls},n.requestFullscreen=function(i){var s,e=Js;return this.isFullscreen(!0),e.requestFullscreen?(xs(t,e.fullscreenchange,Ns(this,(function i(s){this.isFullscreen(t[e.fullscreenElement]),!1===this.isFullscreen()&&Ts(t,e.fullscreenchange,i),this.trigger("fullscreenchange")}))),e.prefixed||(s=this.o.fullscreenOptions,void 0!==i&&(s=i)),this.m[e.requestFullscreen](s)):this.W.supportsFullScreen()?this.cs("enterFullScreen"):(this.enterFullWindow(),this.trigger("fullscreenchange")),this},n.exitFullscreen=function(){var i=Js;return this.isFullscreen(!1),i.requestFullscreen?t[i.exitFullscreen]():this.W.supportsFullScreen()?this.cs("exitFullScreen"):(this.exitFullWindow(),this.trigger("fullscreenchange")),this},n.enterFullWindow=function(){this.isFullWindow=!0,this.docOrigOverflow=t.documentElement.style.overflow,xs(t,"keydown",Ns(this,this.fullWindowOnEscKey)),t.documentElement.style.overflow="hidden",$i(t.body,"vjs-full-window"),this.trigger("enterFullWindow")},n.fullWindowOnEscKey=function(t){27===t.keyCode&&(!0===this.isFullscreen()?this.exitFullscreen():this.exitFullWindow())},n.exitFullWindow=function(){this.isFullWindow=!1,Ts(t,"keydown",this.fullWindowOnEscKey),t.documentElement.style.overflow=this.docOrigOverflow,Bi(t.body,"vjs-full-window"),this.trigger("exitFullWindow")},n.canPlayType=function(t){for(var s,e=0,n=this.o.techOrder;e<n.length;e++){var r=$s(n[e]),h=wr.getTech(r);if(h||(h=i.getComponent(r)),h){if(h.isSupported()&&(s=h.canPlayType(t)))return s}else gi.error('The "'+r+'" tech is undefined. Skipped browser support check for that tech.')}return""},n.selectSource=function(t){var s,e=this,n=this.o.techOrder.map($s).map((function(t){return[t,wr.getTech(t)||i.getComponent(t)]})).filter((function(t){var i=t[0],s=t[1];return s?s.isSupported():(gi.error('The "'+i+'" tech is undefined. Skipped browser support check for that tech.'),!1)})),r=function(t,i,s){var e;return t.some((function(t){return i.some((function(i){if(e=s(t,i))return!0}))})),e},h=function(t,i){var s=t[0];if(t[1].canPlaySource(i,e.o[s.toLowerCase()]))return{source:i,tech:s}};return(this.o.sourceOrder?r(t,n,(s=h,function(t,i){return s(i,t)})):r(n,t,h))||!1},n.src=function(t){if(void 0===t)return this.ts("src");var s=wr.getTech(this.Di);return s||(s=i.getComponent(this.Di)),Array.isArray(t)?this.fs(t):"string"==typeof t?this.src({src:t}):t instanceof k&&(t.type&&!s.canPlaySource(t,this.o[this.Di.toLowerCase()])?this.fs([t]):(this.mi.sources=null,this.mi.source=t,this.mi.src=t.src,this.Ni=t.type||"",this.ready((function(){s.prototype.hasOwnProperty("setSource")?this.cs("setSource",t):this.cs("src",t.src),"auto"===this.o.preload&&this.load(),this.o.autoplay&&this.play()}),!0))),this},n.fs=function(t){var i=this.selectSource(t);i?(i.tech===this.Di?this.src(i.source):this.St(i.tech,i.source),this.mi.sources=t):(this.setTimeout((function(){this.error({code:4,message:this.localize(this.o.notSupportedMessage)})}),0),this.triggerReady())},n.load=function(){return this.cs("load"),this},n.reset=function(){return this.St($s(this.o.techOrder[0]),null),this.cs("reset"),this},n.currentSources=function(){var t=this.currentSource(),i=[];return 0!==k.keys(t).length&&i.push(t),this.mi.sources||i},n.currentSource=function(){var t={},i=this.currentSrc();return i&&(t.src=i),this.mi.source||t},n.currentSrc=function(){return this.ts("currentSrc")||this.mi.src||""},n.currentType=function(){return this.Ni||""},n.preload=function(t){return void 0!==t?(this.cs("setPreload",t),this.o.preload=t,this):this.ts("preload")},n.autoplay=function(t){return void 0!==t?(this.cs("setAutoplay",t),this.o.autoplay=t,this):this.ts("autoplay",t)},n.playsinline=function(t){return void 0!==t?(this.cs("setPlaysinline",t),this.o.playsinline=t,this):this.ts("playsinline")},n.loop=function(t){return void 0!==t?(this.cs("setLoop",t),this.o.loop=t,this):this.ts("loop")},n.poster=function(t){return void 0===t?this.gi:(t||(t=""),this.gi=t,this.cs("setPoster",t),this.trigger("posterchange"),this)},n.Ki=function(){!this.gi&&this.W&&this.W.poster&&(this.gi=this.W.poster()||"",this.trigger("posterchange"))},n.controls=function(t){return void 0!==t?(t=!!t,this.yi!==t&&(this.yi=t,this.usingNativeControls()&&this.cs("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},n.usingNativeControls=function(t){return void 0!==t?(t=!!t,this.ds!==t&&(this.ds=t,t?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols"))),this):!!this.ds},n.error=function(t){return void 0===t?this.ft||null:null===t?(this.ft=t,this.removeClass("vjs-error"),this.errorDisplay&&this.errorDisplay.close(),this):(this.ft=new Zs(t),this.addClass("vjs-error"),gi.error("(CODE:"+this.ft.code+" "+Zs.errorTypes[this.ft.code]+")",this.ft.message,this.ft),this.trigger("error"),this)},n.reportUserActivity=function(t){this.vs=!0},n.userActive=function(t){return void 0!==t?((t=!!t)!==this.ps&&(this.ps=t,t?(this.vs=!0,this.removeClass("vjs-user-inactive"),this.addClass("vjs-user-active"),this.trigger("useractive")):(this.vs=!1,this.W&&this.W.one("mousemove",(function(t){t.stopPropagation(),t.preventDefault()})),this.removeClass("vjs-user-active"),this.addClass("vjs-user-inactive"),this.trigger("userinactive"))),this):this.ps},n.wi=function(){var t,i,s,e,n=Ns(this,this.reportUserActivity);this.on("mousedown",(function(){n(),this.clearInterval(t),t=this.setInterval(n,250)})),this.on("mousemove",(function(t){t.screenX===i&&t.screenY===s||(i=t.screenX,s=t.screenY,n())})),this.on("mouseup",(function(i){n(),this.clearInterval(t)})),this.on("keydown",n),this.on("keyup",n),this.setInterval((function(){if(this.vs){this.vs=!1,this.userActive(!0),this.clearTimeout(e);var t=this.o.inactivityTimeout;t>0&&(e=this.setTimeout((function(){this.vs||this.userActive(!1)}),t))}}),250)},n.playbackRate=function(t){return void 0!==t?(this.cs("setPlaybackRate",t),this):this.W&&this.W.featuresPlaybackRate?this.ts("playbackRate"):1},n.isAudio=function(t){return void 0!==t?(this.gs=!!t,this):!!this.gs},n.videoTracks=function(){return this.W?this.W.videoTracks():(this.ht=this.ht||new gr,this.ht)},n.audioTracks=function(){return this.W?this.W.audioTracks():(this.ot=this.ot||new br,this.ot)},n.textTracks=function(){if(this.W)return this.W.textTracks()},n.remoteTextTracks=function(){if(this.W)return this.W.remoteTextTracks()},n.remoteTextTrackEls=function(){if(this.W)return this.W.remoteTextTrackEls()},n.addTextTrack=function(t,i,s){if(this.W)return this.W.addTextTrack(t,i,s)},n.addRemoteTextTrack=function(t,i){if(this.W)return this.W.addRemoteTextTrack(t,i)},n.removeRemoteTextTrack=function(t){var i=(void 0===t?{}:t).track,s=void 0===i?arguments[0]:i;if(this.W)return this.W.removeRemoteTextTrack(s)},n.getVideoPlaybackQuality=function(){return this.ts("getVideoPlaybackQuality")},n.videoWidth=function(){return this.W&&this.W.videoWidth&&this.W.videoWidth()||0},n.videoHeight=function(){return this.W&&this.W.videoHeight&&this.W.videoHeight()||0},n.language=function(t){return void 0===t?this.ys:(this.ys!==String(t).toLowerCase()&&(this.ys=String(t).toLowerCase(),void 0!==this.m&&this.trigger("languagechange")),this)},n.languages=function(){return Bs(e.prototype.o.languages,this.pi)},n.toJSON=function(){var t=Bs(this.o),i=t.tracks;t.tracks=[];for(var s=0;s<i.length;s++){var e=i[s];(e=Bs(e)).player=void 0,t.tracks[s]=e}return t},n.createModal=function(t,i){var s=this;(i=i||{}).content=t||"";var e=new re(this,i);return this.addChild(e),e.on("dispose",(function(){s.removeChild(e)})),e.open()},e.getTagSettings=function(t){var i={sources:[],tracks:[]},s=Ui(t),e=s["data-setup"];if(Ni(t,"vjs-fluid")&&(s.fluid=!0),null!==e){var n=te(e||"{}"),r=n[0],h=n[1];r&&gi.error(r),di(s,h)}if(di(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(Ui(c)):"track"===l&&i.tracks.push(Ui(c))}return i},n.ki=function(){var i=t.createElement("i");return!("flexBasis"in i.style||"webkitFlexBasis"in i.style||"mozFlexBasis"in i.style||"msFlexBasis"in i.style||"msFlexOrder"in i.style)},e}(i);qh.players={};var Gh=o.navigator;qh.prototype.o={techOrder:["html5","flash"],html5:{},flash:{},defaultVolume:0,inactivityTimeout:2e3,playbackRates:[],children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","controlBar","errorDisplay","textTrackSettings"],language:Gh&&(Gh.languages&&Gh.languages[0]||Gh.userLanguage||Gh.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media.",fullscreenOptions:{navigationUI:"hide"}},["ended","seeking","seekable","networkState","readyState"].forEach((function(t){qh.prototype[t]=function(){return this.ts(t)}})),Wh.forEach((function(t){qh.prototype["handleTech"+$s(t)+"_"]=function(){return this.trigger(t)}})),i.registerComponent("Player",qh);var Xh,Qh,Jh=function(t){function i(s){var e;void 0===s&&(s={});var n=Bs(s,{kind:ae[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(ds)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return k.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.G=!0,r||Rs(e)}return Vs(i,t),i}(le),Yh=function(t){function i(s){var e;void 0===s&&(s={});var n=Bs(s,{kind:oe[s.kind]||""}),r=e=t.call(this,n)||this,h=!1;if(ds)for(var o in i.prototype)"constructor"!==o&&(r[o]=i.prototype[o]);return k.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||Rs(e)}return Vs(i,t),i}(le);function Kh(s,e,n){var r;if("string"==typeof s){if(0===s.indexOf("#")&&(s=s.slice(1)),Kh.getPlayers()[s])return e&&gi.warn('Player "'+s+'" is already initialised. Options will not be applied.'),n&&Kh.getPlayers()[s].ready(n),Kh.getPlayers()[s];r=function(i){return 0===i.indexOf("#")&&(i=i.slice(1)),t.getElementById(i)}(s)}else r=s;if(!r||!r.nodeName)throw new g("The element or ID supplied is not valid. (videojs)");if(r.player||qh.players[r.playerId])return r.player||qh.players[r.playerId];e=e||{},Kh.hooks("beforesetup").forEach((function(t){var i=t(r,Bs(e));vi(i)&&!Array.isArray(i)?e=Bs(e,i):gi.error("please return an object in beforesetup hooks")}));var h=new(i.getComponent("Player"))(r,e,n);return Kh.hooks("setup").forEach((function(t){return t(h)})),h}"undefined"==typeof HTMLVideoElement&&_i()&&(t.createElement("video"),t.createElement("audio"),t.createElement("track")),Kh.bs={},Kh.hooks=function(t,i){return Kh.bs[t]=Kh.bs[t]||[],i&&(Kh.bs[t]=Kh.bs[t].concat(i)),Kh.bs[t]},Kh.hook=function(t,i){Kh.hooks(t,i)},Kh.removeHook=function(t,i){var s=Kh.hooks(t).indexOf(i);return!(s<=-1)&&(Kh.bs[t]=Kh.bs[t].slice(),Kh.bs[t].splice(s,1),!0)},!0!==o.VIDEOJS_NO_DYNAMIC_STYLE&&_i()&&((Xh=Qi(".vjs-styles-defaults"))||(Xh=Ds("vjs-styles-defaults"),(Qh=Qi("head"))&&Qh.insertBefore(Xh,Qh.firstChild),Fs(Xh,"\n .video-js {\n width: 300px;\n height: 150px;\n }\n\n .vjs-fluid {\n padding-top: 56.25%\n }\n "))),Es(1,Kh),Kh.VERSION="5.20.6-opentelly.12",Kh.options=qh.prototype.o,Kh.getPlayers=function(){return qh.players},Kh.players=qh.players,Kh.getComponent=i.getComponent,Kh.registerComponent=function(t,s){wr.isTech(s)&&gi.warn("The "+t+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),i.registerComponent.call(i,t,s)},Kh.getTech=wr.getTech,Kh.registerTech=wr.registerTech,Kh.browser=bs,Kh.TOUCH_ENABLED=gs,Kh.extend=function(t,i){void 0===i&&(i={});var s=function(){t.apply(this,arguments)},e={};for(var n in vi(i)?("function"==typeof i.init&&(gi.warn("Constructor logic via init() is deprecated; please use constructor() instead."),i.constructor=i.init),i.constructor!==k.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=k.create(i&&i.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),i&&(t.ks=i)}(s,t),e)e.hasOwnProperty(n)&&(s.prototype[n]=e[n]);return s},Kh.mergeOptions=Bs,Kh.bind=Ns,Kh.plugin=function(t,i){qh.prototype[t]=i},Kh.addLanguage=function(t,i){var s;return t=(""+t).toLowerCase(),Kh.options.languages=Bs(Kh.options.languages,((s={})[t]=i,s)),Kh.options.languages[t]},Kh.log=gi,Kh.createTimeRange=Kh.createTimeRanges=zs,Kh.formatTime=Nr,Kh.parseUrl=fe,Kh.isCrossOrigin=de,Kh.EventTarget=Os,Kh.on=xs,Kh.one=Ps,Kh.off=Ts,Kh.trigger=Cs,Kh.xhr=rr,Kh.TextTrack=cr,Kh.AudioTrack=Jh,Kh.VideoTrack=Yh,Kh.isEl=xi,Kh.isTextNode=Wi,Kh.createEl=Ci,Kh.hasClass=Ni,Kh.addClass=$i,Kh.removeClass=Bi,Kh.toggleClass=Oi,Kh.setAttributes=Ri,Kh.getAttributes=Ui,Kh.emptyEl=qi,Kh.appendContent=Gi,Kh.insertContent=Xi,Kh.computedStyle=Lr;var Zh=10,to=60;function io(t){return t.duration()===1/0}function so(t){return t.scrubbing()?t.getCache().currentTime:t.currentTime()}function eo(t){let i=ho(t);return io(t)?i.end(i.length-1):i.start(0)}function no(t){return ho(t).start(0)}function ro(t){let i=ho(t);return i.end(i.length-1)-i.start(0)}function ho(t){let i=t.seekable();if(i&&i.length)return i;let s=t.duration();return s=isFinite(s)?s:0,new K([0,s]).ws()}function oo(t,i){void 0===i&&(i=t);let s=t<0?"-":"";t=w.abs(t);let e=w.floor(t%60),n=w.floor(t/60%60),r=w.floor(t/3600);const h=w.floor(i/60%60),o=w.floor(i/3600);return(_(t)||t===1/0)&&(r=n=e="-"),r=r>0||o>0?r+":":"",n=((r||h>=10)&&n<10?"0"+n:n)+":",e=e<10?"0"+e:e,s+r+n+e}function ao(){let t=this,i=so(t);t.toggleClass("theo-at-live",function(t,i){if(io(t)){let s=ho(t);return s.end(s.length-1)-i<Zh}return!1}(t,i)),t.toggleClass("theo-dvr",function(t){return io(t)&&ro(t)>=to}(t))}var uo="theo-ad-playing",co="theo-dai-ad-playing";function lo(t,i,s){t.toggleClass(uo,i),t.toggleClass(co,i&&s)}function fo(){this.userActive(!1)}var vo,po,mo=class{constructor(t,i){this.type=t.type,this.target=i,this.playerEvent=t}};!function(t){t.js="unavailable",t.Ss="available",t._s="presenting"}(vo||(vo={})),function(t){t.LOADED="DAILoaded",t.AD_BREAK_STARTED="DAIAdBreakStarted",t.AD_BREAK_ENDED="DAIAdBreakEnded",t.AD_PERIOD_STARTED="DAIAdPeriodStarted",t.AD_PERIOD_ENDED="DAIAdPeriodEnded",t.AD_PROGRESS="DAIAdProgress",t.CUEPOINTS_CHANGED="DAICuePointsChanged",t.CLICK="DAIClick",t.ERROR="DAIError",t.STARTED="DAIStarted",t.FIRST_QUARTILE="DAIFirstQuartile",t.MIDPOINT="DAIMidpoint",t.STREAM_INITIALIZED="DAIStreamInitialized",t.THIRD_QUARTILE="DAIThirdQuartile",t.COMPLETE="DAIComplete"}(po||(po={}));var go=["loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","volumechange","resize"],yo=Kh.getTech("Tech"),bo=Kh.getTech("Html5"),ko=class extends yo{xs(){var t;for(const t of go)this.Ts.addEventListener(t,this.Cs);this.Ts.addEventListener("error",this.Ps),this.Ts.addEventListener("contentprotectionerror",this.Ps),this.Ts.addEventListener("sourcechange",this.As),this.Ts.addEventListener("loadstart",this.Ms),null==(t=this.Ts.presentation)||t.addEventListener("presentationmodechange",this.Is),this.Ts.textTracks.addEventListener("addtrack",this.Es),this.Ts.textTracks.addEventListener("removetrack",this.Ds),this.Ts.textTracks.addEventListener("change",this.Fs),this.Ts.audioTracks.addEventListener("addtrack",this.Ns),this.Ts.audioTracks.addEventListener("removetrack",this.$s),this.Ts.audioTracks.addEventListener("change",this.Bs)}Os(){var t;for(const t of go)this.Ts.removeEventListener(t,this.Cs);this.Ts.removeEventListener("error",this.Ps),this.Ts.removeEventListener("contentprotectionerror",this.Ps),this.Ts.removeEventListener("sourcechange",this.As),this.Ts.removeEventListener("loadstart",this.Ms),null==(t=this.Ts.presentation)||t.removeEventListener("presentationmodechange",this.Is),this.Ts.textTracks.removeEventListener("addtrack",this.Es),this.Ts.textTracks.removeEventListener("removetrack",this.Ds),this.Ts.textTracks.removeEventListener("change",this.Fs),this.Ts.audioTracks.removeEventListener("addtrack",this.Ns),this.Ts.audioTracks.removeEventListener("removetrack",this.$s),this.Ts.audioTracks.removeEventListener("change",this.Bs)}Rs(t){this.trigger(new mo(t,this))}createEl(){let t=this.o,i=t.player;if(!i)throw new m(this.localize('Missing required tech option "player"'));let s=i.element;return Kh.setAttributes(s,{id:t.techId}),s}theoplayer(){return this.Ts}addTextTrack(t,i,s){return super.addTextTrack(t,i,s)}buffered(){return this.Ts.buffered}played(){return this.Ts.played}reset(){this.Ts.stop()}play(){this.Ts.play()}pause(){this.Ts.pause()}paused(){return this.Ts.paused}currentTime(){return this.Ts.currentTime}setCurrentTime(t){this.Ts.currentTime=t}duration(){return this.Ts.duration}volume(){return this.Ts.volume}setVolume(t){this.Ts.volume=t}muted(){return this.Ts.muted}setMuted(t){this.Ts.muted=t}src(t){if(void 0!==t)this.setSrc(t);else{if(this.Ts.src)return this.Ts.src;if(this.Ts.source){if(!nt(this.Ts.source.ads))return this.Ts.source.ads[0].sources;if(function(t){if(t.sources)if(lt(t.sources)){for(const i of t.sources)if(!pt(i)&&"verizon-media"===i.integration)return!0}else if(!pt(t.sources))return"verizon-media"===t.sources.integration;return!1}(this.Ts.source))return"This source is managed by the Verizon Media integration extension.";if(function(t){if(t.sources)if(lt(t.sources)){for(const i of t.sources)if(L(i))return!0}else if(dt(t.sources))return L(t.sources);return!1}(this.Ts.source))return"This source is managed by the DAI integration extension."}}}setSrc(t){return this.setSource({src:t})}setSource(t){this.ft=null,this.trigger("error")}currentSrc(){return this.Ts.src}load(){this.setPreload("auto")}preload(){return this.Ts.preload}setPreload(t){this.Ts.preload=t}autoplay(){return this.Ts.autoplay}setAutoplay(t){this.Ts.autoplay=!!t}seeking(){return this.Ts.seeking}seekable(){return this.Ts.seekable}ended(){return this.Ts.ended}playbackRate(){return this.Ts.playbackRate}setPlaybackRate(t){this.Ts.playbackRate=t}readyState(){return this.Ts.readyState}networkState(){return 0}controls(){return!1}videoHeight(){return this.Ts.videoHeight}videoWidth(){return this.Ts.videoWidth}supportsFullScreen(){return this.Ts.presentation.supportsMode(it.FULLSCREEN)}enterFullScreen(){this.Ts.presentation.requestMode(it.FULLSCREEN)}exitFullScreen(){this.Ts.presentation.requestMode(it.INLINE)}Us(){let t=this.Ts.ads;if(t&&t.playing)return!0;let i=this.Ts.vr;return!(!i||i.state===vo.js)}initTextTrackListeners(){return this.on("touchend",(t=>{this.Us()&&(t.preventDefault=()=>{})})),super.initTextTrackListeners()}ti(){if(!this.src())return;const t=this.readyState();if(0===t){let t=!1,i=()=>{t=!0};this.on("loadstart",i);let s=()=>{t||this.trigger("loadstart")};return this.on("loadedmetadata",s),void this.ready((()=>{this.off("loadstart",i),this.off("loadedmetadata",s),t||this.trigger("loadstart")}))}let i=["loadstart"];i.push("loadedmetadata"),t>=2&&i.push("loadeddata"),t>=3&&i.push("canplay"),t>=4&&i.push("canplaythrough"),this.ready((()=>{for(const t of i)this.trigger(t)}))}dispose(){this.Os(),this.Ts=null,super.dispose()}static isSupported(){return!0}static canPlayType(){return"maybe"}static canPlaySource(t){return"maybe"}get featuresVolumeControl(){return Bt}constructor(t={},i){super(t,i),this.Cs=t=>this.Rs(t),this.Vs=!1,this.As=()=>{this.Rs(new z(this.Ts.currentTime,this.Ts.readyState)),this.Rs(new yt)},this.Ms=()=>{this.Rs(new Y(this.Ts.currentTime))},this.Es=t=>{this.textTracks().it(t.track)},this.Ns=t=>{this.audioTracks().it(t.track)},this.Ds=t=>{this.textTracks().st(t.track)},this.$s=t=>{this.audioTracks().st(t.track)},this.Fs=()=>{let t=this.textTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Bs=()=>{let t=this.audioTracks();t.trigger({type:"change",target:t,currentTarget:t,srcElement:t})},this.Is=()=>{if(!this.supportsFullScreen())return;let t=this.Vs,i=this.Ts.presentation.currentMode===it.FULLSCREEN;t!==i&&(this.Vs=i,this.trigger("fullscreenchange",{isFullscreen:i,nativeIOSFullscreen:!0}))},this.Ps=()=>{const t=this.Ts.errorObject,i=t&&q(t.code)||-1,s=t&&t.message||"An unknown error occurred.";this.error({code:i,message:this.localize(s)})},this.Ts=this.o.player,this.xs();const s=!this.paused();s&&this.pause(),t.preload&&this.setPreload(t.preload),t.autoplay&&this.setAutoplay(t.autoplay),t.muted&&this.setMuted(t.muted),t.source?this.setSrc(t.source):this.ti(),s&&this.ready((()=>this.play())),this.triggerReady()}};function wo(t){return class extends t{get Ts(){return this.Ls||(this.Ls=this.player().tech({IWillNotUseThisInPlugins:!0}).theoplayer()),this.Ls}dispose(){this.Ls=void 0,super.dispose()}constructor(...t){super(...t),this.Ls=void 0}}}ko.prototype.featuresFullscreenResize=bo.prototype.featuresFullscreenResize,ko.prototype.featuresPlaybackRate=bo.prototype.featuresPlaybackRate,ko.prototype.featuresProgressEvents=!0,ko.prototype.featuresTimeupdateEvents=!0,ko.prototype.featuresNativeTextTracks=!0,Kh.registerTech("THEOplayer",ko);var jo=class{constructor(t){this.Hs=t=>{xt(this.zs,"theo-mobile-button-hover"),t.stopImmediatePropagation()},this.Ws=t=>{Ct(this.zs,"theo-mobile-button-hover")},this.qs=t=>{this.zs.blur()},this.zs=t,t.addEventListener("touchstart",this.Hs),t.addEventListener("touchend",this.Ws),t.addEventListener("focusin",this.qs)}},So=Kh.getComponent("Menu"),_o=class extends(wo(So)){get Gs(){return this.player().el()}Xs(){xt(this.Gs,"theo-menu-opened")}Qs(){Ct(this.Gs,"theo-menu-opened")}constructor(t,i){super(t,i)}},xo=Kh.getComponent("MenuItem"),To=class extends(wo(xo)){get parentMenu(){return this.Js}buildCSSClass(){return"theo-menu-item vjs-menu-item"}createEl(){let t=super.createEl("li",{className:this.buildCSSClass(),tabIndex:0},{"aria-live":"off","aria-label":""});return t.innerHTML="",t}handleClick(t){this.Ys||(this.parentMenu.Ks(this),"tap"!==t.type&&"keydown"!==t.type||(this.Ys=!0,this.trigger("click"),this.Ys=!1))}dispose(){rt.te.Zs&&(this.el().removeEventListener("touchstart",this.Hs),this.el().removeEventListener("touchend",this.Ws)),super.dispose()}constructor(t,i,s){super(t,Rt({selectable:!0},i)),this.Ys=!1,this.Hs=t=>{xt(this.el(),"theo-mobile-menu-item-hover"),t.stopImmediatePropagation()},this.Ws=t=>{Ct(this.el(),"theo-mobile-menu-item-hover")},this.Js=s,rt.te.Zs&&(this.el().addEventListener("touchstart",this.Hs),this.el().addEventListener("touchend",this.Ws))}},Co=Kh.getComponent("ClickableComponent"),Po=class extends Co{get parentMenu(){return this.Js}get ie(){return this.se}set ie(t){this.se=t,this.el().setAttribute("tabindex",this.ie?"0":"-1"),this.ee()}buildCSSClass(){return"theo-primary-background theo-menu-header"}createEl(){let t=super.createEl("div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-live":"off","aria-label":""});return t.innerHTML="",t}handleClick(t){!this.Ys&&this.ie&&(this.Js.ne(),"tap"===t.type&&(this.Ys=!0,this.trigger("click"),this.Ys=!1))}ee(){this.ie?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.Ys=!1,this.se=!1,this.Js=s,this.on(t,"languagechange",this.ee)}},Ao=class extends _o{get menuHeader(){return this.re}get menuItems(){return this.children()}addMenuItem(t){t=Rt({playerOptions:this.o.playerOptions},t);let i=new To(this.player(),t,this);return this.addChild(i,void 0,t.index),this.trigger("menuchange"),i}addSubMenuItem(t){t=Rt({playerOptions:this.o.playerOptions},t);let i=this.he(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"}Xs(){super.Xs(),s.removeEventListener("resize",this.oe),s.addEventListener("resize",this.oe),this.show()}ae(){let t=this.ue();if(!t)return;let i=t.getClientRects();rt.te.Zs?this.ce(t,i):this.le(t,i)}ue(){var t;return null!=(t=this.contentEl().parentElement)?t:void 0}le(t,i){}ce(t,i){}Qs(){s.removeEventListener("resize",this.oe),super.Qs(),this.hide(),rt.te.Zs&&(this.el().removeAttribute("style"),this.contentEl().removeAttribute("style"))}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=this.contentEl();xt(i,"theo-menu-content");let s=new Po(this.player(),this.o,this);return i.parentNode.insertBefore(s.el(),i),this.re=s,t}Ks(t){}show(){return this.ae(),super.show()}dispose(){this.re&&this.re.dispose(),super.dispose()}constructor(t,i){super(t,i),this.oe=()=>this.ae(),this.fe=this.player().el(),this.hide(),this.on("menuchange",this.ae)}},Mo=class extends Ao{get de(){return this.ve}set de(t){this.ve&&this.ve.pe(this),this.ve=t,t&&t.me(this)}ge(t){this.de.ye(t,"replace")}be(t){t.de.ye(this,"restore")}ke(){Ct(this.we,"vjs-hidden"),this.we.style.opacity="1",super.show()}je(){xt(this.we,"vjs-hidden")}Xs(){this.de&&this.de.Xs(),super.Xs()}Qs(){this.de&&this.de.Qs(),super.Qs(),xt(this.we,"vjs-hidden")}ue(){if(this.de&&this.de.Se)return this.de.Se.we}le(t,i){if(i.length>0){let t=i[0].height,s=i[0].width;this.ve._e.style.height=t+"px",this.ve._e.style.width=s+"px"}super.le(t,i)}constructor(t,i){super(t,i)}},Io=class{get _e(){return this.zs}get Se(){return this.xe}me(t){t.je(),this.zs.appendChild(t.we)}pe(t){this.zs.removeChild(t.we)}ye(t,i){if(t==this.xe)return;let s=this.xe;if(this.xe=t,this.xe.ke(),this.Se.focus(),rt.te.Zs)s.je();else{const t="translateX(100%)",e="translateX(-100%)",n=at("transform");s.we.style.opacity="0",s.we.style[n]="replace"===i?e:t,this.xe.we.style.opacity="1",this.xe.we.style[n]="",c((()=>{s.je(),s.we.style[n]=""}),300)}}Xs(){this.Te(),this.xe.ke(),this.Ce()}Qs(){this.Te(),this.xe.je(),this.Pe.je(),this.xe=this.Pe,this.Ce()}Ce(){T((()=>{Ct(this.zs,"theo-no-transition"),Ct(this.xe.we,"theo-no-transition")}))}Te(){xt(this.zs,"theo-no-transition"),xt(this.xe.we,"theo-no-transition")}constructor(t){this.Pe=this.xe=t,this.zs=u.createElement("div"),this.zs.className="theo-tertiary-background theo-menu-animation-container",this.zs.appendChild(this.Pe.we),this.fe=this.xe.player().el()}},Eo=class extends Mo{get we(){return this.el()}get parentMenu(){return this.Ae}he(t,i){let s=new Do(t,i,this);return s.subMenu.de=this.de,s}ne(){this.Me()}Ks(t){super.Ks(t),this.Me()}Me(){this.parentMenu.be(this)}buildCSSClass(){return"theo-submenu "+(this.Ie?"":"theo-leaf-submenu ")+"theo-menu-content theo-menu-content-animatable "+super.buildCSSClass()}addSubMenuItem(t){this.Ie=!0;let i=super.addSubMenuItem(t);return this.removeClass("theo-leaf-submenu"),i}constructor(t,i,s){super(t,i),this.Ie=!1,this.Ae=s,this.menuHeader.ie=!0}},Do=class extends To{get subMenu(){return this.Ee}handleClick(t){this.parentMenu.ge(this.subMenu)}constructor(t,i,s){super(t,Rt({selectable:!1},i),s),this.Ee=new Eo(t,i,s)}},Fo=class extends Mo{get menuButton(){return this.De}createEl(){let t=Kh.createEl("div",{className:this.buildCSSClass()});return this.Fe=super.createEl(),this.Fe.className=super.buildCSSClass(),xt(this.Fe,"theo-menu-content-animatable"),t.appendChild(this.Fe),this.de=new Io(this),t.appendChild(this.de._e),t}buildCSSClass(){return"theo-menu-animatable "+super.buildCSSClass()}he(t,i){let s=new Do(t,i,this);return s.subMenu.de=this.de,s}le(t,i){super.le(t,i);let s=this.fe.getClientRects(),e=s.length>0?s[0]:void 0,n=S(getComputedStyle(this.el()).fontSize);Ft(this.el(),this.De.el(),e,n)}get we(){return this.Fe}ne(){this.De.closeMenu()}dispose(){this.Ne||(this.Ne=!0,super.dispose())}constructor(t,i,s){super(t,i),this.Ne=!1,this.De=s}},No=class{set $e(t){this.Be.innerHTML=this.Oe.localize(t),this.Re(),this.Ue(),It(this.Oe.el())}get $e(){return this.Be.textContent||""}Ve(){this.Oe.off("mouseover",this.Ue),this.Oe.off("mouseout",this.Re),this.Oe.off("dispose",this.Le),wt(this.Be)}constructor(t,i){this.Ue=()=>{Ct(this.Be,"vjs-hidden");let t=this.Oe.player().contentEl().getClientRects(),i=t.length>0?t[0]:void 0,s=S(getComputedStyle(this.Be).fontSize);Ft(this.Be,this.Oe.el(),i,s)},this.Re=()=>{xt(this.Be,"vjs-hidden")},this.Le=()=>this.Ve(),this.Oe=t,It(t.el()),Dt(t.el()),this.Be=u.createElement("span"),this.Be.innerHTML=this.Oe.localize(i),this.Be.className="theo-button-tooltip vjs-hidden",this.Be.setAttribute("aria-hidden","true"),this.Oe.el().appendChild(this.Be),this.Oe.on("mouseover",this.Ue),this.Oe.on("mouseout",this.Re),this.Oe.on("dispose",this.Le)}},$o=Kh.getComponent("Button"),Bo=class extends(wo($o)){get He(){const t=this.el().parentElement;return!!t&&null!==t.querySelector(".theo-mobile-menu-background")}get menu(){return this.ze}isMenuOpen(){return this.We}openMenu(){this.qe&&!this.We&&(this.ze.Xs(),this.el().setAttribute("aria-expanded","true"),this.We=!0,this.ze.focus())}closeMenu(){this.qe&&this.We&&(this.ze.Qs(),this.el().setAttribute("aria-expanded","false"),this.We=!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.We?this.closeMenu():this.openMenu()}enable(){return this.qe=!0,super.enable()}disable(){return this.closeMenu(),this.qe=!1,super.disable()}ee(){this.Be.$e=this.controlText()}dispose(){this.player().removeChild(this.ze),this.ze.dispose(),this.Be.Ve(),this.Ts.removeEventListener("seeking",this.Qe),super.dispose()}constructor(t,i){super(t,i),this.We=!1,this.Ge=1,this.qe=!0,this.Je=t=>{let i=this.el().contains(t.target),s=this.ze.el().contains(t.target),e=!1;var n;rt.te.Zs&&this.He&&(e=(null==(n=this.el().parentElement)?void 0:n.querySelector(".theo-mobile-menu-background"))===t.target);i||s||!this.We||(e&&t.preventDefault(),this.closeMenu())},this.Ye=t=>{27===t.which&&(this.closeMenu(),this.focus())},this.Qe=()=>{this.We&&this.closeMenu()},this.Xe=()=>{this.ze.menuItems.length>=this.Ge?this.show():(this.closeMenu(),this.hide())},this.ze=new Fo(t,i,this),this.player().getChild("controlBarMenuContainer").addChild(this.ze),this.Be=new No(this,this.controlText()),this.el().setAttribute("aria-haspopup","true"),rt.te.Ke?(this.on(u,"touchend",this.Je),new jo(this.el())):(this.on(u,"click",this.Je),this.on(u,"keydown",this.Ye),vt&&this.on(u,vt.Ze,this.closeMenu)),this.Ts.addEventListener("seeking",this.Qe),this.on(this.ze,"menuchange",this.Xe),this.on(t,"languagechange",this.ee),this.Xe()}},Oo=Kh.getComponent("Component"),Ro=class extends(Kh.getComponent("ControlBar")){addMenuButton(t){t=Rt({playerOptions:this.o.playerOptions},t);let i=new Bo(this.player(),t);return this.addChild(i),i}removeMenuButton(t){this.removeChild(t)}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-secondary-color vjs-control-bar "+super.buildCSSClass()}constructor(t,i){super(t,i),this.addChild("THEOControlBarShadow",void 0,0)}};Kh.registerComponent("THEOControlBarShadow",class extends Oo{createEl(){return super.createEl("div",{className:this.buildCSSClass()})}buildCSSClass(){return"theo-tertiary-color theo-control-bar-shadow"}});var Uo=Kh.getComponent("VolumeBar"),Vo=class extends Uo{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=i.sn}},Lo=Kh.getComponent("VolumeControl"),Ho=class extends Lo{constructor(t,i){super(t,i),this.nn=new Vo(t,{sn:this}),this.addChild(this.nn)}};Ho.prototype.o=Rt({},Lo.prototype.o,{children:[]}),Kh.registerComponent("VolumeControl",Ho);var zo=class extends(wo(Ro)){rn(){return this.el().getBoundingClientRect().height}dispose(){this.el().removeEventListener("transitionstart",this.hn),this.el().removeEventListener("transitionend",this.an),this.cn.un("ln",this.fn),this.cn.dn(),super.dispose()}constructor(t,i){super(t,i),this.hn=t=>{if("opacity"===t.propertyName){const t=this.rn();this.Ts.textTrackStyle.marginBottom!==t&&(this.Ts.textTrackStyle.marginBottom=t)}},this.an=t=>{"opacity"===t.propertyName&&"0"===s.getComputedStyle(this.el()).opacity&&(this.Ts.textTrackStyle.marginBottom=void 0)},this.fn=()=>{void 0!==this.Ts.textTrackStyle.marginBottom&&(this.Ts.textTrackStyle.marginBottom=this.rn())},this.el().addEventListener("transitionstart",this.hn),this.el().addEventListener("transitionend",this.an),this.cn=new ct(this.el()),this.cn.vn("ln",this.fn),this.cn.pn(!0)}};zo.prototype.o=Rt({},Ro.prototype.o,{children:["progressControl","playToggle","muteToggle","volumeControl","currentTimeDisplay","timeDivider","durationDisplay","liveDisplay","remainingTimeDisplay","customControlSpacer","activeQualityLabel","vrButton","descriptionsButton","subtitlesButton","chromecastButton","airplayButton","multiViewButton","audioTrackButton","SettingsButton","fullscreenToggle"]}),Kh.registerComponent("ControlBar",zo);var Wo=class extends Ro{buildCSSClass(){return"theo-top-controlbar "+super.buildCSSClass()}constructor(t,i){super(t,i),t.topControlBar=this}};Wo.prototype.o=Rt({},Ro.prototype.o,{children:[]}),Kh.registerComponent("TopControlBar",Wo);var qo=Kh.getComponent("CurrentTimeDisplay");Kh.registerComponent("CurrentTimeDisplay",class extends qo{updateContent(){let t=this.player(),i=so(t),s=no(t),e=this.localize("Current Time"),n=oo(w.max(0,i-s),ro(t));n!==this.At&&(this.At=n,this.contentEl().innerHTML='<span class="vjs-control-text">'+e+"</span> "+n)}constructor(t,i){super(t,i),this.on(t,"timeupdate",this.updateContent),this.on(t,"emptied",this.updateContent)}});var Go=Kh.getComponent("DurationDisplay"),Xo=class extends(wo(Go)){updateContent(){const t=_(this.Ts.duration)?NaN:ro(this.player()),i=this.Ts.clip.endTime-this.Ts.clip.startTime,s=w.min(t,i)||0;if(this.lt!==s){this.lt=s;const t=this.localize("Duration Time"),i=oo(s);this.T.innerHTML='<span class="vjs-control-text">'+t+"</span> "+i}}constructor(t,i){super(t,i),this.mn=()=>this.updateContent(),this.off(t,"durationchange",this.updateContent),this.on(t,"durationchange",this.updateContent),this.off(t,"timeupdate",this.updateContent),this.on(t,"timeupdate",this.updateContent),this.off(t,"emptied",this.updateContent),this.on(t,"emptied",this.updateContent),this.Ts&&this.Ts.clip.addEventListener("change",this.mn)}};Kh.registerComponent("DurationDisplay",Xo);var Qo=Kh.getComponent("Button"),Jo=class extends(wo(Qo)){buildCSSClass(){return"theo-live-control "+super.buildCSSClass()}createEl(){let t=super.createEl("button",{},{"aria-live":"off"});return this.gn=Kh.createEl("span",{className:"theo-live-control-indicator"}),t.insertBefore(this.gn,t.firstChild),t}createControlTextEl(t){let i=super.createControlTextEl(t);return Kh.removeClass(i,"vjs-control-text"),Kh.addClass(i,"theo-live-control-text"),i}handleClick(){var t;const i=this.Ts;if(void 0!==(null==(t=i.hesp)?void 0:t.manifest))i.hesp.goLive();else{const t=this.player();t.currentTime(eo(t)),t.play()}}yn(){io(this.player())?this.show():this.hide()}constructor(t,i){super(t,i),this.controlText("Live"),this.yn(),this.on(this.player(),"durationchange",this.yn),rt.te.Ke&&new jo(this.el())}};Kh.registerComponent("LiveDisplay",Jo);var Yo=Kh.getComponent("LoadingSpinner");Kh.registerComponent("LoadingSpinner",class extends Yo{buildCSSClass(){return"theo-secondary-color vjs-loading-spinner "+super.buildCSSClass()}createEl(){let t=super.createEl();t.className=this.buildCSSClass();let i=Kh.createEl("div",{className:"theo-loading-spinner-rotator"}),s=Kh.createEl("div",{className:"theo-loading-spinner-circle-left"}),e=Kh.createEl("div",{className:"theo-loading-spinner-circle-right"});return i.appendChild(s),i.appendChild(e),t.appendChild(i),t}constructor(t,i){super(t,i)}});var Ko=Kh.getComponent("LoadProgressBar");function Zo(t,i){let s=t/i||0;return 100*(s>=1?1:s)+"%"}Kh.registerComponent("LoadProgressBar",class extends Ko{update(){let t=this.player(),i=K.bn(ho(t)),s=i.kn(0),e=K.bn(t.buffered()).wn(i),n=i.jn(0)-s,r=e.L&&e.jn(e.L-1)||0;r=w.max(0,r-s);let h=this.el(),o=this.Sn;h.style.width=Zo(r,n);for(let t=0;t<e.L;t++){let i=e.kn(t),n=e.jn(t),a=o[t];a||(a=u.createElement("div"),o.push(a),h.appendChild(a)),a.style.left=Zo(i-s,r),a.style.width=Zo(n-i,r)}for(let t=o.length;t>e.L;t--)h.removeChild(o[t-1]);o.length=e.L}constructor(t,i){super(t,i),this.Sn=[],this.on(t,"emptied",this.update)}});var ta=Kh.getComponent("MouseTimeDisplay"),ia=class extends(wo(ta)){handleMouseMove(t){let i=this.player(),s=no(i)+this.calculateDistance(t)*ro(i),e=t.pageX-Et(this.el().parentNode).left;this.update(s,e+"px")}handleTouchMove(t){let i=this.player(),s=no(i)+this.calculateDistance(t)*ro(i),e=t.touches[0].pageX-Et(this.el().parentNode).left;this.update(s,e+"px")}createEl(){let t=super.createEl();return this._n=Kh.createEl("span",{className:"theo-time-tooltip-text"}),t}update(t,i){let s=this.xn(t);if(this.el().style.left=i,this.el().setAttribute("data-current-time",s),this.keepTooltipsInside&&($t(this._n,s),this.tooltip.offsetParent)){let t=this.player().contentEl(),i=t.getClientRects(),s=i.length>0?i[0]:void 0,e=S(getComputedStyle(t).fontSize);Ft(this.tooltip,this.el(),s,e)}}xn(t){let i=this.player();const s=t-eo(i);return oo(io(i)?w.min(s,0):s,ro(i))}constructor(t,i){var s;(super(t,i),this.Tn=()=>{let t=this.player(),i=t.scrubbing()?t.getCache().currentTime:t.currentTime(),s=(i-no(t))/ro(t)||0;s=bt(s,0,1),this.update(i,100*s+"%")},this.keepTooltipsInside&&(Kh.addClass(this.tooltip,"theo-secondary-color"),this.tooltip.appendChild(this._n)),ot.Zs)&&(this.on(t,"firstplay",this.Tn),this.on(t,"play",this.Tn),this.on(t,"seeking",this.Tn),this.on(t,"seeked",this.Tn),this.on(t,"timeupdate",this.Tn),this.Ts.addEventListener("dimensionchange",this.Tn),null==(s=this.Ts.presentation)||s.addEventListener("presentationmodechange",this.Tn),t.on("ready",(()=>{this.on(t.controlBar.progressControl,"touchmove",gt((t=>this.handleTouchMove(t)),25)),this.Tn()})))}};Kh.registerComponent("MouseTimeDisplay",ia);var sa=Kh.getComponent("PlayProgressBar");Kh.registerComponent("PlayProgressBar",class extends sa{updateDataAttr(){let t=so(this.player());this.el().setAttribute("data-current-time",this.xn(t))}xn(t){let i=this.player();return oo(t-eo(i),ro(i))}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-play-progress vjs-slider-bar "+super.buildCSSClass()}constructor(t,i){super(t,i)}});var ea=Kh.getComponent("RemainingTimeDisplay");Kh.registerComponent("RemainingTimeDisplay",class extends ea{updateContent(){const t=this.player(),i=ro(t);if(i){const s=ho(t).end(0),e=this.localize("Remaining Time"),n=oo(w.max(0,s-t.currentTime()),i);n!==this.At&&(this.At=n,this.contentEl().innerHTML='<span class="vjs-control-text">'+e+"</span> -"+n)}}constructor(t,i){super(t,i),this.on(t,"timeupdate",this.updateContent),this.on(t,"emptied",this.updateContent)}});var na=class{get Ts(){return this.Ls||(this.Ls=this.Cn.tech({IWillNotUseThisInPlugins:!0}).theoplayer()),this.Ls}Pn(t){if(t.kind!==X.An)return;if(0===this.Ts.seekable.length)return;this.Mn=t;const i=t.cues.slice();this.En.In(i);for(let t=0;t<i.length;t++){let s=i[t],e=i[t+1],n=!e||s.endTime!==e.startTime,r=new ra(s,this.Ts,n);this.Dn.push(r),this.Fn.appendChild(r._e)}}Nn(){this.Ts.addEventListener("loadedmetadata",this.$n),this.Ts.addEventListener("loadeddata",this.$n),this.Ts.addEventListener("sourcechange",this.$n),this.Ts.textTracks.addEventListener("addtrack",this.Bn),this.Ts.textTracks.addEventListener("removetrack",this.On),this.Ts.textTracks.addEventListener("change",this.$n)}Rn(){this.Ts.removeEventListener("loadedmetadata",this.$n),this.Ts.removeEventListener("loadeddata",this.$n),this.Ts.removeEventListener("sourcechange",this.$n),this.Ts.textTracks.removeEventListener("addtrack",this.Bn),this.Ts.textTracks.removeEventListener("removetrack",this.On),this.Ts.textTracks.removeEventListener("change",this.$n)}Un(){if(!(this.Ts.readyState<H.Vn))for(let t of this.Ts.textTracks)if(t.kind===X.An&&t.mode===U.Ln&&t.cues.length>0&&t.readyState!==G.ERROR)return t}Hn(t){this.En.zn(t)}Wn(){this.En.ke()}qn(){this.En.je()}Gn(){for(let t of this.Dn)t.Ve();this.En.Gn(),this.Dn=[],this.Mn=void 0}Ve(){this.Rn(),this.Xn.removeEventListener("mousemove",this.Qn),this.Xn.removeEventListener("mouseenter",this.Jn),this.Xn.removeEventListener("mouseleave",this.Yn),this.Gn(),this.En.Ve(),this.Ls=void 0}constructor(t,i){this.Cn=i,this.Dn=[],this.Ls=void 0,this.Bn=t=>{let i=t.track;i.kind===X.An&&(i.addEventListener("addcue",this.$n),i.addEventListener("removecue",this.$n),i.addEventListener("readystatechange",this.$n)),this.$n()},this.On=t=>{let i=t.track;i.kind===X.An&&(i.removeEventListener("addcue",this.$n),i.removeEventListener("removecue",this.$n),i.removeEventListener("readystatechange",this.$n)),this.$n()},this.Qn=t=>{let i=this.Cn,s=function(t,i){let s,e,n=Et(t),r=t.offsetWidth,h=t.offsetHeight,o=n.top,a=n.left;!function(t){return void 0!==t.changedTouches}(i)?(e=i.pageX,s=i.pageY):(e=i.changedTouches[0].pageX,s=i.changedTouches[0].pageY);let u=bt((o-s+h)/h,0,1),c=bt((e-a)/r,0,1);return{x:c,y:u}}(this.Fn,t),e=no(i)+s.x*ro(i);e===i.duration()&&(e-=.1),this.Hn(e)},this.Yn=()=>{this.En.je()},this.Jn=()=>{this.En.ke()},this.$n=()=>{let t=this.Un();t!==this.Mn&&(this.Gn(),t&&this.Pn(t))},this.Xn=t,this.En=new ha,this.Cn.contentEl().appendChild(this.En._e),this.Fn=u.createElement("div"),xt(this.Fn,"theoplayer-chapterbar"),this.Xn.appendChild(this.Fn),this.Xn.addEventListener("mousemove",this.Qn),this.Xn.addEventListener("mouseenter",this.Jn),this.Xn.addEventListener("mouseleave",this.Yn),this.Nn()}},ra=class{get _e(){return this.zs}Kn(){oa(this.Zn,this.h.currentTime)&&this.tr(),this.Zn.addEventListener("enter",this.tr),this.Zn.addEventListener("exit",this.ir)}sr(){let t=this.h.seekable.start(0),i=this.h.seekable.end(this.h.seekable.length-1)-t,s=this.Zn.startTime,e=this.Zn.endTime-s,n=u.createElement("div");xt(n,"theoplayer-chapter-indicator");let r=u.createElement("div");xt(r,"theoplayer-chapter-indicator-highlight"),n.appendChild(r),this.er&&xt(n,"theoplayer-chapter-indicator-discontinuous");let h=w.min(s/i*100,100),o=100-h,a=w.min(e/i*100,o);return n.style.width=a+"%",n.style.left=h+"%",n}Ve(){this.Zn.removeEventListener("enter",this.tr),this.Zn.removeEventListener("exit",this.ir),wt(this.zs)}constructor(t,i,s){this.Zn=t,this.h=i,this.er=s,this.tr=()=>{xt(this._e,"theoplayer-chapter-indicator-active")},this.ir=()=>{Ct(this._e,"theoplayer-chapter-indicator-active")},this.zs=this.sr(),this.Kn()}},ha=class{je(){this.nr--,0===this.nr&&Ct(this._e,"theoplayer-chapter-hovering")}In(t){this.rr=t||[],this.rr.length>0&&(this._e.style.display="")}hr(t){$t(this.ar,t.content)}Gn(){this.rr=[],$t(this.ar,""),this._e.style.display="none"}ke(){this.nr++,this.nr>0&&xt(this._e,"theoplayer-chapter-hovering")}zn(t){for(let i of this.rr)if(oa(i,t)){this.hr(i);break}}Ve(){wt(this._e)}constructor(){this.rr=[],this.nr=0,this._e=u.createElement("div"),xt(this._e,"theoplayer-chaptertitle"),this._e.style.display="none",this.ar=u.createElement("p"),this._e.appendChild(this.ar)}};function oa(t,i){return new K([t.startTime,t.endTime]).ur(i)}var aa=Kh.getComponent("SeekBar"),ua=class extends(wo(aa)){updateAriaAttributes(t){let i=this.player(),s=so(i);t.setAttribute("aria-valuenow",(100*this.cr(s)).toFixed(2)),t.setAttribute("aria-valuetext",oo(s-eo(i),ro(i)))}getPercent(){return this.cr(this.player().currentTime())}handleMouseMove(t){if(this.Ts&&this.Ts.ads&&this.Ts.ads.playing)return;let i=this.player(),s=no(i)+this.calculateDistance(t)*ro(i);s>=i.duration()&&(s=i.duration()-.1),this.Fn.Hn(s),i.currentTime(s)}handleMouseDown(t){this.playingStates.push(!this.player().paused()),this.Fn.Wn(),super.handleMouseDown(t)}handleMouseUp(t){this.videoWasPlaying=Boolean(this.playingStates.pop()),this.Fn.qn(),super.handleMouseUp(t)}cr(t){let i=this.player(),s=(t-no(i))/ro(i);return bt(s,0,1)}dispose(){this.Fn.Ve(),Zt(this.playingStates)}constructor(t,i){super(t,i),this.playingStates=[],this.on(t,"emptied",this.update),this.on(t,"seeking",this.update),this.Fn=new na(this.el(),t)}};Kh.registerComponent("SeekBar",ua);var ca=Kh.getComponent("ProgressControl");rt.te.Zs&&Kh.registerComponent("ProgressControl",class extends ca{createEl(){return super.createEl("div",{className:"vjs-progress-control vjs-control"})}handleMouseMove(t){this.seekBar.handleMouseMove(t)}handleMouseDown(t){this.seekBar.handleMouseDown(t)}constructor(t,i){super(t,i),this.on(this,"touchmove",this.handleMouseMove),this.on("touchstart",this.handleMouseDown),this.seekBar.off(["touchmove","touchstart"])}});var la=Kh.getComponent("TooltipProgressBar");function fa(t){for(const i of t)if(i.enabled)return i}function da(t){if(t)return t.label&&""!==t.label?{name:t.label,hd:!1}:{name:va(t),description:pa(t),hd:!!t.height&&t.height>=720}}function va(t){return t.height?t.height+"p":t.bandwidth?pa(t):""}function pa(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":""}Kh.registerComponent("TooltipProgressBar",class extends la{updateDataAttr(){let t=so(this.player()),i=this.xn(t);this.el().setAttribute("data-current-time",i),this.tooltip.innerHTML=i}xn(t){let i=this.player();return oo(t-eo(i),ro(i))}createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-tooltip-progress-bar vjs-slider-bar "+super.buildCSSClass()}constructor(t,i){super(t,i)}});var ma=class{get lr(){return this.dr}set lr(t){let i=this.dr;for(let s=i.length-1;s>=0;s--){let e=i[s];Yt(t,e)||this.pr(e)}for(let i of t)this.mr(i);this.gr.ae()}get yr(){return this.gr.menuItems}br(t){let i=this.yr;if(i)for(let s of i)if(s.kr===t)return s}wr(t){let i=this.gr.addMenuItem();return i.kr=t,i.on("click",(()=>this.jr(i))),i.el().setAttribute("role","menuitemradio"),i}Sr(t){t.dispose()}_r(t){return!0}mr(t){if(this._r(t)){Yt(this.dr,t)||this.dr.push(t);let i=this.br(t)||this.wr(t);return this.Tr(i),i}this.pr(t)}pr(t){let i=this.br(t);i&&(this.gr.removeMenuItem(i),this.Sr(i)),Qt(this.dr,t)}Ve(){const t=[];for(let i of this.dr)t.push(i);for(let i of t)this.pr(i);Zt(t)}constructor(t){this.dr=[],this.gr=t}},ga=class extends ma{Cr(){return this.Pr=u.createElement("span"),this.Pr.className="theo-settings-control-menu-item-title",$t(this.Pr,this.Ar.localize("Quality")),this.Pr}Mr(){return this.Ir=u.createElement("span"),this.Ir.className="theo-settings-control-menu-quality-automatic",$t(this.Ir,this.Ar.localize("Automatic")),this.Ir}Er(){return this.Dr=u.createElement("span"),$t(this.Dr,this.Ar.localize("Automatic")),this.Dr}Fr(){return this.Nr=u.createElement("span"),this.Nr.className="theo-primary-color theo-settings-control-menu-item-hd-label",$t(this.Nr,this.Ar.localize("HD")),this.Nr}$r(){let t=u.createElement("span");t.className="theo-primary-color theo-settings-control-menu-item-value",t.appendChild(this.Ir),t.appendChild(u.createTextNode(" ")),t.appendChild(this.Dr),t.appendChild(u.createTextNode(" ")),t.appendChild(this.Nr),this.Br.el().appendChild(this.Pr),this.Br.el().appendChild(t),this.Br.el().setAttribute("aria-label",this.Ar.localize("Open the video quality settings menu"))}Or(){let t=this.Rr,i=t&&_a(t.targetQuality),s=t&&t.activeQuality,e=da(this.Ur(i||s))||{name:this.Ar.localize("Automatic")};$t(this.Dr,e.name),At(this.Ir,"vjs-hidden",!!i),At(this.Nr,"vjs-hidden",!e.hd)}Tr(t){let i=da(t.kr)||{name:this.Ar.localize("Automatic")},s=i.name;i.hd&&(s+='<span class="theo-primary-color theo-settings-control-menu-item-hd-label">'+this.Ar.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.Ar.localize("Set video quality to ")+i.name),t.kr?t.selected(t.kr===this.Vr):t.selected(!this.Vr)}jr(t){this.Rr&&(this.Rr.targetQuality=t.kr&&t.kr.videoQualities)}Ur(t,i){const s=i||this.lr;for(let i of s)if(t&&i&&-1!==i.videoQualities.indexOf(t))return i}Ve(){this.Ls.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.Lr),this.Ar.off("languagechange",this.ee),this.Rr&&(this.Rr.removeEventListener("activequalitychanged",this.Hr),this.Rr.removeEventListener("targetqualitychanged",this.zr),this.Rr.removeEventListener("update",this.Wr)),super.Ve()}constructor(t,i,s){super(t.subMenu),this.Rr=void 0,this.Vr=void 0,this.Lr=()=>{let t=fa(this.Ls.videoTracks);if(t===this.Rr)return;let i=[];if(this.Rr&&(this.Rr.removeEventListener("activequalitychanged",this.Hr),this.Rr.removeEventListener("targetqualitychanged",this.zr),this.Rr.removeEventListener("update",this.Wr)),this.Rr=t,t){t.addEventListener("activequalitychanged",this.Hr),t.addEventListener("targetqualitychanged",this.zr),t.addEventListener("update",this.Wr);const s=ba(ja(t.qualities.filter((t=>t.available))));i=s.length>1?[void 0,...s]:[void 0]}this.lr=i,this.zr(),this.Hr()},this.Wr=t=>{const i=t.track;if(i!==this.Rr)return;const s=ba(ja(i.qualities.filter((t=>t.available)))),e=i&&_a(i.targetQuality);let n;this.Vr=this.Ur(e,s),n=s.length>1?[void 0,...s]:[void 0],this.lr=n,this.Or()},this.Hr=()=>{this.mr(void 0),this.Or()},this.zr=()=>{let t=fa(this.Ls.videoTracks),i=t&&_a(t.targetQuality),s=this.Ur(i),e=this.Vr;s!==e&&(this.Vr=s,s&&e||this.mr(void 0),e&&Yt(this.lr,e)&&this.mr(e),i&&this.mr(s),this.Or())},this.ee=()=>{$t(this.gr.menuHeader.el(),this.Ar.localize("Quality")),$t(this.Pr,this.Ar.localize("Quality")),$t(this.Ir,this.Ar.localize("Automatic")),$t(this.Dr,this.Ar.localize("Automatic")),$t(this.Nr,this.Ar.localize("HD")),this.Br.el().setAttribute("aria-label",this.Ar.localize("Open the video quality settings menu"));for(const t of this.yr)this.Tr(t);this.Or()},this.Br=t,this.Ls=i,this.Ar=s,this.Pr=this.Cr(),this.Ir=this.Mr(),this.Dr=this.Er(),this.Nr=this.Fr(),this.$r(),$t(this.gr.menuHeader.el(),this.Ar.localize("Quality")),this.lr=[void 0],this.Ls.videoTracks.addEventListener(["addtrack","removetrack","change"],this.Lr),this.Ar.on("languagechange",this.ee),this.Lr()}},ya=class{get height(){return this.qr[0].height}get bandwidth(){return this.qr[0].bandwidth}get videoQualities(){return this.qr}get label(){return this.qr[0].label}add(t){this.qr.push(t)}constructor(t){this.qr=t}};function ba(t){let i=[];for(let s of t){let t=s,e=!1;for(let s of i)if(Sa(s,t)){s.add(t),e=!0;break}e||i.push(new ya([t]))}return i}function ka(t,i){return t&&i?Wt(t,i):Ht.Gr}function wa(t,i){return t===i?Ht.Gr:ka(t.height,i.height)||ka(t.width,i.width)||ka(t.bandwidth,i.bandwidth)}function ja(t){return Vt(t,wa).reverse()}function Sa(t,i){return t.label&&i.label&&t.label===i.label||B(da(t),da(i))}function _a(t){return lt(t)?1===t.length?t[0]:void 0:t}function xa(t){return 1===t?"Normal":""+w.round(100*t)/100}var Ta=class extends ma{Cr(){return this.Pr=u.createElement("span"),this.Pr.className="theo-settings-control-menu-item-title",$t(this.Pr,this.Ar.localize("Speed")),this.Pr}$r(){const t=u.createElement("span");return t.className="theo-primary-color theo-settings-control-menu-item-value",this.Br.el().appendChild(this.Pr),this.Br.el().appendChild(t),this.Br.el().setAttribute("aria-label",this.Ar.localize("Open the video speed settings menu")),t}wr(t){let i=super.wr(t);return this.Tr(i),i}Tr(t){const i=t.kr,s=this.Ar.localize(xa(i));$t(t.el(),s),t.el().setAttribute("aria-label",this.Ar.localize("Set video speed to "+s)),t.selected(t.kr===this.Ls.playbackRate)}jr(t){this.Ls.playbackRate=t.kr}Ve(){this.Ls.removeEventListener("ratechange",this.Xr),this.Ar.off("languagechange",this.ee),super.Ve()}constructor(t,i,s,e){super(t.subMenu),this.Qr=void 0,this.Xr=()=>{this.Qr&&this.mr(this.Qr);let t=this.Ls.playbackRate;this.Qr=t,$t(this.Jr,this.Ar.localize(xa(t))),t&&this.mr(t)},this.ee=()=>{$t(this.gr.menuHeader.el(),this.Ar.localize("Speed")),$t(this.Pr,this.Ar.localize("Speed")),this.Br.el().setAttribute("aria-label",this.Ar.localize("Open the video speed settings menu"));for(const t of this.yr)this.Tr(t);this.Xr()},this.Br=t,this.Ls=i,this.Ar=s,this.Pr=this.Cr(),this.Jr=this.$r(),$t(this.gr.menuHeader.el(),this.Ar.localize("Speed")),this.lr=e,this.Ls.addEventListener("ratechange",this.Xr),this.Ar.on("languagechange",this.ee),this.Xr()}};Kh.registerComponent("SettingsButton",class extends Bo{createEl(){let t=super.createEl();return this.Yr=Kh.createEl("span",{className:"theo-settings-control-label-hd theo-primary-background"}),$t(this.Yr,this.localize("HD")),t.appendChild(this.Yr),t}buildCSSClass(){return"vjs-icon-cog theo-settings-control-button "+super.buildCSSClass()}ee(){super.ee(),$t(this.Yr,this.localize("HD")),$t(this.menu.menuHeader.el(),this.localize("Settings"))}dispose(){this.Rr&&(this.Rr.removeEventListener("activequalitychanged",this.Hr),this.Rr=void 0),this.Ts.videoTracks.removeEventListener(["addtrack","removetrack","change"],this.Kr),this.Zr.Ve(),this.th.Ve(),super.dispose()}constructor(t,i){var s,e;super(t,i),this.Rr=void 0,this.Kr=()=>{let t=fa(this.Ts.videoTracks);t!==this.Rr&&(this.Rr&&this.Rr.removeEventListener("activequalitychanged",this.Hr),this.Rr=t,t&&t.addEventListener("activequalitychanged",this.Hr),this.Hr())},this.Hr=()=>{var t;const i=null==(t=this.Rr)?void 0:t.activeQuality,s=!!(i&&i.height>=720);this.player().toggleClass("theo-hd",s)},xt(this.menu.el(),"theo-settings-control-menu"),$t(this.menu.menuHeader.el(),t.localize("Settings")),this.controlText("Settings"),this.Be.$e=this.controlText(),this.ih=this.menu.addSubMenuItem({name:"QualityMenuItem"}),this.Zr=new ga(this.ih,this.Ts,t);let n=null!=(e=null==i||null==(s=i.playerOptions)?void 0:s.playbackRates)?e:[];this.sh=this.menu.addSubMenuItem({name:"PlaybackRateMenuItem"}),this.th=new Ta(this.sh,this.Ts,t,n),this.Ts.videoTracks.addEventListener(["addtrack","removetrack","change"],this.Kr),this.Kr()}});var Ca=class extends ma{eh(t){let i=t.label;if(i)return i;let s=t.language;if(s){let t=M(s);if(t)return t.nh}return s||""}rh(){this.lr=this.hh}Ve(){this.hh.removeEventListener("addtrack",this.oh),this.hh.removeEventListener("removetrack",this.ah),this.hh.removeEventListener("change",this.uh),super.Ve()}constructor(t,i){super(t),this.oh=t=>{const i=t.track;this.mr(i),i.addEventListener("update",this.lh)},this.ah=t=>{const i=t.track;this.pr(i),i.removeEventListener("update",this.lh)},this.uh=t=>this.rh(),this.lh=()=>{for(const t of this.lr)this.mr(t)},this.hh=i,this.hh.addEventListener("addtrack",this.oh),this.hh.addEventListener("removetrack",this.ah),this.hh.addEventListener("change",this.uh),this.rh()}},Pa=class extends Ca{Tr(t){let i=t.kr,s=this.eh(i);$t(t.el(),this.eh(i)),t.el().setAttribute("aria-label",this.Ar.localize("Set the audio language to")+" "+s),t.selected(i.enabled)}jr(t){let i=t.kr;for(let t of this.Ts.audioTracks)t!==i&&(t.enabled=!1);i.enabled=!0}Ve(){this.Ar.off("languagechange",this.ee),super.Ve()}constructor(t,i,s){super(t,i.audioTracks),this.ee=()=>{$t(this.gr.menuHeader.el(),this.Ar.localize("Language"));for(const t of this.yr)this.Tr(t)},this.Ts=i,this.Ar=s,$t(this.gr.menuHeader.el(),this.Ar.localize("Language")),this.Ar.on("languagechange",this.ee)}};Kh.registerComponent("audioTrackButton",class extends Bo{buildCSSClass(){return"vjs-icon-audio theo-audio-track-control-button "+super.buildCSSClass()}dispose(){this.fh.Ve(),super.dispose()}constructor(t,i){super(t,i),this.minimumMenuItems=2,this.fh=new Pa(this.menu,this.Ts,t),this.controlText("Language"),this.Be.$e=this.controlText()}});var Aa=class extends Ca{_r(t){return!!super._r(t)&&(!t.forced&&J(t.kind))}wr(t){let i=super.wr(t);xt(i.el(),"theo-text-track-menu-item");let s=u.createElement("span");i.dh=s;let e=u.createElement("div");e.className="theo-text-track-menu-item-toggle",i.ph=e;let n=t=>this.mh(t,i);i.gh=n,e.addEventListener("click",n);let r=u.createElement("div");return r.className="theo-text-track-menu-item-toggle-slider",e.appendChild(r),i.el().appendChild(s),i.el().appendChild(e),i}Tr(t){let i=t,s=i.kr,e=this.eh(s);$t(i.dh,e),i.el().setAttribute("aria-label",this.Ar.localize("Set the subtitle language to")+" "+e),i.el().setAttribute("role","menuitemcheckbox"),i.selected(s.mode===U.Ln)}Sr(t){let i=t;i.ph.removeEventListener("click",i.gh),super.Sr(t)}jr(t){let i=t.kr;for(let t of this.Ts.textTracks)t!==i&&Q(t.kind,i.kind)&&(t.mode=U.yh);i.mode!==U.Ln?i.mode=U.Ln:i.mode=U.yh}mh(t,i){t.stopImmediatePropagation(),this.jr(i)}Ve(){this.Ar.off("languagechange",this.ee),super.Ve()}constructor(t,i,s){super(t,i.textTracks),this.ee=()=>{$t(this.gr.menuHeader.el(),this.Ar.localize("Subtitles"));for(const t of this.yr)this.Tr(t)},this.Ts=i,this.Ar=s,$t(this.gr.menuHeader.el(),s.localize("Subtitles")),this.Ar.on("languagechange",this.ee)}};Kh.registerComponent("subtitlesButton",class extends Bo{buildCSSClass(){return"vjs-icon-subtitles theo-text-track-control-button "+super.buildCSSClass()}dispose(){this.fh.Ve(),super.dispose()}constructor(t,i){super(t,i),this.fh=new Aa(this.menu,this.Ts,t),this.controlText("Subtitles"),this.Be.$e=this.controlText()}});var Ma,Ia=Kh.getComponent("playToggle");!function(t){t.bh="Pause",t.kh="Play",t.wh="Replay"}(Ma||(Ma={}));var Ea=class extends(wo(Ia)){handleClick(t){this.Ts.muted||this.Ts.prepareWithUserAction(),super.handleClick(t)}handlePlay(t){super.handlePlay(t),this.controlText("Pause"),this.Be.$e=this.controlText()}handlePause(t){this.Ts.ended||(super.handlePause(t),this.controlText("Play"),this.Be.$e=this.controlText())}ee(){this.Be.$e=this.controlText()}dispose(){this.Be.Ve(),this.Ts.removeEventListener("ended",this.jh),super.dispose()}constructor(t,i){super(t,i),this.jh=()=>{this.controlText("Replay"),this.Be.$e=this.controlText()},this.controlText("Play"),this.Be=new No(this,this.controlText()),this.Ts.addEventListener("ended",this.jh),this.on(t,"languagechange",this.ee),rt.te.Ke&&new jo(this.el())}};Kh.registerComponent("playToggle",Ea);var Da,Fa=Kh.getComponent("fullscreenToggle");!function(t){t.Sh="Exit fullscreen",t._h="Fullscreen"}(Da||(Da={}));var Na=class extends(wo(Fa)){handleClick(t){this.Ts.prepareWithUserAction(),super.handleClick(t)}handleFullscreenChange(t){super.handleFullscreenChange(t),this.updateContent()}updateContent(){const t=this.player().isFullscreen()?"Exit fullscreen":"Fullscreen";this.controlText(t),this.Be.$e=this.controlText()}dispose(){this.Be.Ve(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Fullscreen"),this.Be=new No(this,this.controlText()),rt.te.Ke&&new jo(this.el()),this.on(t,"languagechange",this.updateContent)}};Kh.registerComponent("fullscreenToggle",Na);var $a,Ba=Kh.getComponent("muteToggle");!function(t){t.xh="Unmute",t.Th="Mute"}($a||($a={}));var Oa=class extends(wo(Ba)){handleClick(t){this.Ts.muted&&!this.Ts.paused&&this.Ts.prepareWithUserAction(),super.handleClick(t)}update(t){super.update(t),this.ee()}ee(){const t=this.player().muted()?"Unmute":"Mute";this.controlText(t),this.Be.$e=this.controlText()}dispose(){this.Be.Ve(),super.dispose()}constructor(t,i){super(t,i),this.controlText("Mute"),this.Be=new No(this,this.controlText()),rt.te.Ke&&new jo(this.el()),this.on(t,"languagechange",this.ee),Nt&&(this.removeClass("vjs-hidden"),this.on(t,"loadstart",(()=>{this.removeClass("vjs-hidden")})))}};Kh.registerComponent("muteToggle",Oa);var Ra=Kh.getComponent("BigPlayButton"),Ua=class extends(wo(Ra)){createEl(){let t=super.createEl(),i=Kh.createEl("div",{className:"theo-big-play-button-svg-container"});return i.innerHTML='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 150 150" fill="currentColor">\n <circle cx="75" cy="75" r="73" fill="#000" fill-opacity="0.2"></circle>\n <circle cx="75" cy="75" r="73" class="theo-play-svg-circle" stroke-width="4" stroke="currentColor" fill="none" transform="rotate(-90,75,75)"></circle>\n <g transform="translate(85,75) scale(0.5625) translate(-75,-75)">\n <path d="m 123.89639,85.432 c -12.865,9.167 -29.482997,19.402 -49.848997,30.7 -19.634,11.035 -36.851,19.7 -51.65,26 l -16.3990002,6.099 c -1.033,-4.433 -2,-11.002 -2.9,-19.7 -2.033,-17.333 -3.04999998,-36.466 -3.04999998,-57.399 0,-19.167 1.38199998,-37.081 4.14799998,-53.75 l 4.0019995,-19.1499994 17.3990007,5.849 c 15.068,5.9999994 31.401,14.5169994 49,25.5509994 18.631,11.666 34.616997,22.766 47.948997,33.3 6.663,5.3 11.463,9.383 14.396,12.25 l -13.046,10.25"></path>\n </g>\n</svg>',t.appendChild(i),t}buildCSSClass(){return"theo-primary-color "+super.buildCSSClass()}handleClick(t){this.Ts.muted||this.Ts.prepareWithUserAction(),super.handleClick(t),void 0!==this.Ts.vr&&"unavailable"!==this.Ts.vr.state&&(this.Ts.vr.useDeviceMotionControls=!0)}};Kh.registerComponent("BigPlayButton",Ua);var Va=/^([^#]*)#xywh=(\d+),(\d+),(\d+),(\d+)\s*$/;Kh.registerComponent("MouseTimeDisplay",class extends ia{Ch(t){const i=t.track;"removetrack"===t.type&&i===this.Ph?(this.Ph=void 0,this.Ah=void 0,this.Mh(),this.Ih=void 0):"addtrack"===t.type&&"metadata"===i.kind&&"thumbnails"===i.label&&(this.Ph=i,this.Ah=i.src?rt.Eh(i.src).href:void 0)}createEl(){const t=super.createEl();return this.Dh=Kh.createEl("img",{className:"theo-time-tooltip-thumbnail"}),this.Fh=Kh.createEl("canvas",{className:"theo-time-tooltip-thumbnail"}),t}update(t,i){if(super.update(t,i),!this.keepTooltipsInside)return;let s;if(this.Ph&&this.Ph.cues){let i=function(t,i){let s=t[0];for(let e of t)if(e.startTime<=i)s=e;else if(i>=e.endTime)return s;return s}(this.Ph.cues,t);s=i&&i.content}if(s===this.Ih)return;if(this.Ih=s,Kh.toggleClass(this.el(),"theo-time-tooltip-has-thumbnail",!!s),!s)return void this.Mh();const e=s.match(Va);if(e){let[,t,i,s,n,r]=e;t=this.Nh(t);const h={$h:+i,Bh:+s,Ci:+n,Pi:+r};this.Oh(t,h)}else{const t=this.Nh(s);this.Oh(t)}}Nh(t){return this.Ph&&this.Ah?rt.Eh(t,this.Ah).href:t}Oh(t,i){this.Dh&&(this.Dh.src!==t?(this.Dh.onload=()=>{this.Rh(i)},this.Dh.src="",this.Dh.src=t):this.Rh(i))}Rh(t){if(!this.Fh||!this.Dh)return;const i=this.Fh.getContext("2d");i&&(t=t||{$h:0,Bh:0,Ci:this.Dh.naturalWidth,Pi:this.Dh.naturalHeight},this.Fh.width=t.Ci,this.Fh.height=t.Pi,i.drawImage(this.Dh,t.$h,t.Bh,t.Ci,t.Pi,0,0,t.Ci,t.Pi),this.Uh(this.Fh))}Uh(t){this.Vh||(this.tooltip.firstChild?this.tooltip.insertBefore(t,this.tooltip.firstChild):this.tooltip.appendChild(t),this.Vh=t)}Mh(){this.Vh&&this.tooltip.removeChild(this.Vh),ot.Zs&&(this.off(this.player(),"seeking",this.showThumbnails),this.off(this.player(),"seeked",this.hideThumbnails)),this.Vh=void 0}constructor(t,i){super(t,i),this.Vh=void 0,this.Ph=void 0,this.Ah=void 0,this.Lh=t=>this.Ch(t),this.showThumbnails=()=>{this.Vh&&(this.Vh.hidden=!1)},this.hideThumbnails=()=>{this.Vh&&!this.player().scrubbing()&&(this.Vh.hidden=!0)},this.player().textTracks().on("addtrack",this.Lh),this.player().textTracks().on("removetrack",this.Lh),ot.Zs&&(this.on(t,"seeking",this.showThumbnails),this.on(t,"seeked",this.hideThumbnails))}});var La=Kh.getComponent("VolumeLevel");Kh.registerComponent("VolumeLevel",class extends La{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-primary-color vjs-volume-level "+super.buildCSSClass()}});var Ha=Kh.getComponent("Component"),za=class extends Ha{createEl(){let t=super.createEl();return t.className=this.buildCSSClass(),t}buildCSSClass(){return"theo-menu-container "+super.buildCSSClass()}};za.prototype.o=Rt({},za.prototype.o,{children:[]}),Kh.registerComponent("controlBarMenuContainer",za);var Wa=Kh.getComponent("Player"),qa=class extends Wa{dispose(){const t=this.el(),i=this.contentEl(),s=t.parentNode,e=t.nextSibling;super.dispose(),wt(i),this.xi&&s&&(e?s.insertBefore(t,e):s.appendChild(t)),u.body.removeEventListener("keydown",this.handleKeyPress),u.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")},u.body.addEventListener("keydown",this.handleKeyPress),u.body.addEventListener("click",this.handleClick)}};qa.prototype.o=Rt({},Wa.prototype.o,{children:["bigPlayButton","AdControlPanel","TopControlBar","mediaLoader","upNextContainer","posterImage","chromecastOverlay","controlBarMenuContainer","controlBar","textTrackDisplay","loadingSpinner","errorDisplay","textTrackSettings","xrCompass"]}),Kh.registerComponent("Player",qa);var Ga=Kh.getComponent("Player"),Xa=Ga.prototype.ns;Ga.prototype.ns=function(t){if(!(this.W&&this.W.Us&&this.W.Us()))return Xa.call(this,t)};var Qa,Ja=Ga.prototype.createEl;function Ya(t,i,e,n){let r=Rt({controls:!0,playbackRates:[.25,.5,1,1.25,1.5,2]},e);r.controlBar=Rt({progressControl:{keepTooltipsInside:!0}},r.controlBar);let h=r.techOrder||(r.techOrder=[]);-1===h.indexOf("THEOplayer")&&h.unshift("THEOplayer"),(r.theoplayer||(r.theoplayer={})).player=t,e&&dt(e.language)&&(r.languages=Rt({},r.languages,{[P]:e.language}),r.language=P),i.setAttribute("data-vjs-player","");let o=i.getAttribute("style"),a=Kh(t.element,r,n);return a.ready((()=>{!function(t){t.on("timeupdate",ao),t.on("durationchange",ao)}(a),function(t,i){if(i){if(i.ads){const s=i=>{const s="adbreakbegin"===i.type,e=i.adBreak.integration===F.Hh;lo(t,s,e)};i.ads.addEventListener("adbreakbegin",s),i.ads.addEventListener("adbreakend",s)}if(i.verizonMedia){const s=i=>{const s="adbreakbegin"===i.type;lo(t,s,!1)};i.verizonMedia.ads.adBreaks.addEventListener("addadbreak",(t=>{t.adBreak.addEventListener("adbreakbegin",s),t.adBreak.addEventListener("adbreakend",s)}))}i.addEventListener("sourcechange",(()=>{lo(t,!1,!1)}))}}(a,t),function(t){t.on("mouseleave",fo)}(a)})),i.removeAttribute("data-vjs-player"),o?i.setAttribute("style",o):i.removeAttribute("style"),rt.te.Zs&&(xt(i,"theo-mobile"),function(t){let i=s.outerHeight,e=s.outerWidth,n=i>e;n?(Ct(t,"theo-mobile-landscape"),xt(t,"theo-mobile-portrait")):(Ct(t,"theo-mobile-portrait"),xt(t,"theo-mobile-landscape"))}(i)),function(t){t.on("seeking",(()=>{St(t.el(),"vjs-ended")&&t.currentTime()!==t.duration()&&t.play()}))}(a),a}function Ka(t){return class extends t{zh(){return function(t,i){let s=k.create(t);const e=i.Wh;return N(s,{get controls(){return e.controls()},set controls(t){e.controls(O(t))},get ui(){return e}})}(this.qh,this)}dn(){super.dn(),this.Wh.dispose()}Gh(t){this.Wh.src(""),super.Gh(t)}constructor(t,i,s){super(i,s),this.Xh=t,this.qh=super.zh(),k.defineProperty(this.qh,"constructor",{value:zt}),this.Wh=Ya(this.qh,this.Xh,s.ui)}}}function Za(t){return(t=t||{}).position=function(t){switch(t){case"top-left":case"top-right":case"bottom-left":case"bottom-right":return t;default:return}}(t.position),t.visibility=function(t){if(ut(t)&&!_(t))return bt(t,0,1)}(t.visibility),t.retainPresentationModeOnSourceChange=O(t.retainPresentationModeOnSourceChange),t}function tu(){return Qa||(Qa=function(t,i){let s=t;if(ei[i])for(const t of ei[i])s=t(s);return s}(Qa=Ka(Lt()),h.t)),Qa}function iu(t,i){const s=function(t){const i=W(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=Za(i.pip),i}(i),e=u.createElement("div");e.style.position="absolute",t.appendChild(e);const n=new(tu())(t,e,s);let r=n.Qh;return n.Jh(),n.Yh(Ut),k.defineProperty(r,"constructor",{value:iu}),r=D(r),Ot(n),function(t){for(const i of ri)i(t)}(n),r}function su(t){return{get ratio(){return t.Kh},get thresholds(){return t.Zh.slice()}}}function eu(t){const i=[],s=w.floor(1/t);if(_(s))return[];for(let e=0;e<=s;e++){const s=bt(e*t,0,1);i.push(s)}return i}Ga.prototype.createEl=function(){let t=Ja.call(this),i=Kh.createEl("div");for(i.className="theo-player-wrapper";t.firstChild;)i.appendChild(t.firstChild);return t.appendChild(i),this.T=i,t};var nu=class{get Kh(){return this.io}get Zh(){return this.so}eo(t){return i=>{const s=i[i.length-1];this.io=s.intersectionRatio,t(s.intersectionRatio)}}get Qh(){return this.no||(this.no=su(this)),this.no}ro(){this.ho.disconnect()}constructor(t,i,e){this.io=1,this.no=void 0,this.so=eu(i);const n=this.eo(e);this.ho=new s.IntersectionObserver(n,{root:null,threshold:this.so}),this.ho.observe(t)}},ru=class{get Kh(){return this.io}get Zh(){return this.so}get Qh(){return this.no||(this.no=su(this)),this.no}oo(t){this.io=t;const i=this.so;let s=0;if(t>0)for(;s<i.length&&i[s]<=t;)++s;this.ao!==s&&(this.ao=s,this.uo(t))}constructor(t,i){this.io=1,this.ao=-1,this.no=void 0,this.so=eu(t),this.uo=i}},hu=class extends ru{co(){const t=this.lo.getBoundingClientRect(),i=w.max(0,w.min(s.innerWidth,t.right)-w.max(0,t.left)),e=w.max(0,w.min(s.innerHeight,t.bottom)-w.max(0,t.top)),n=t.width*t.height;return bt(i*e/n,0,1)}ro(){s.removeEventListener("scroll",this.fo)}constructor(t,i,e){super(i,e),this.fo=gt((()=>this.oo(this.co())),50),this.lo=t,s.addEventListener("scroll",this.fo,!!ht&&{passive:!0}),ii((()=>this.oo(this.co())))}},ou=class{get do(){return this.vo}get po(){return this.mo}set po(t){if(_(t)||t<0||t>1)throw new RangeError("The threshold must be a value between 0 and 1");this.mo=t}get Qh(){return this.no||(this.no=function(t){return{get ratio(){return t.do},get visible(){return t.do>t.po},get visibleThreshold(){return t.po},set visibleThreshold(i){i=R(i),t.po=i},addObserver:(i,s)=>(i=R(i),t.yo(i,s).Qh),removeObserver(i){let s=t.bo(i);s&&t.ko(s)}}}(this)),this.no}wo(t){return i=>{this.vo=i,null==t||t(this.vo)}}yo(t,i){if(_(t))throw new g("step is not of the right type");if(t>1||t<=0)throw new RangeError("The step must be a number greater than 0 and smaller than or equal to 1");let e;return e="function"==typeof s.IntersectionObserver?new nu(this.lo,t,this.wo(i)):new hu(this.lo,t,this.wo(i)),this.jo.push(e),e}ko(t){t.ro(),Qt(this.jo,t)}bo(t){for(const i of this.jo)if(i.Qh===t)return i}dn(){for(const t of this.jo)t.ro();Zt(this.jo)}constructor(t){this.vo=1,this.mo=0,this.jo=[],this.no=void 0,this.lo=t,this.yo(.1,this.wo())}};ni((function(t){return class extends t{zh(){const t=this.So;return N(super.zh(),{get visibility(){return t.Qh}})}dn(){this.So&&(this.So.dn(),this.So=void 0),super.dn()}constructor(t,i,s){super(t,i,s),this.So=new ou(t)}}}),h.t);var au=Kh.getComponent("Button");var uu="THEOPiPCloseButton";Kh.registerComponent(uu,class extends au{buildCSSClass(){return"theo-close-button theo-pip-close"}handleClick(){this.xo._o()}constructor(t,i){if(super(t,i),this.controlText("Close Picture-in-Picture"),!function(t){return!!t&&Boolean(t.xo)}(i))throw new m("Invalid Picture-in-picture options.");this.xo=i.xo}});var cu=class extends V{get To(){return this.Co}get Po(){return this.h.ls()}Ao(){this.h.vn("play",this.Mo),this.Io||this.h.vn("sourcechange",this.Eo),this.h.Wh.on("languagechange",this.ee)}Do(){let t=this.Fo;if(t)return"theo-pip-"+t}No(t){let i=this.lo;if(i&&!this.Po){this.$o||this.Bo(),this.Oo(),xt(i,"theo-pip");let s=this.Do();s&&xt(i,s),this.Co=!0,this.Ro=t,this.Uo=!1,this.Vo(new tt(it.PICTURE_IN_PICTURE))}}Lo(t){let i=this.lo;if(i){this.Ho(),Ct(i,"theo-pip");let s=this.Do();s&&Ct(i,s),this.Co=!1,this.Uo=t,this.zo=this.Ro,this.Ro=!1,this.Vo(new tt(it.INLINE))}}Bo(){if(!this.$o){let t=this.h.Wh;t.addChild(uu,{xo:this});let i=u.createElement("div");i.className="theo-pip-overlay",this.Wo=u.createElement("div"),this.Wo.className="theo-pip-overlay-text",$t(this.Wo,t.localize("Video playing in Picture-in-Picture mode")),i.appendChild(this.Wo),t.el().appendChild(i),this.qo=i,this.$o=!0}}Go(){this.Xo&&!this.Qo&&this.h.So&&(this.Jo=this.h.So.yo(.1,this.Yo),this.Qo=!0)}Ko(){this.Jo&&this.h.So&&(this.h.So.ko(this.Jo),this.Qo=!1)}Oo(){let t=this.h.Wh.contentEl(),i=t.getBoundingClientRect(),s=u.documentElement.clientWidth,e=u.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"}Ho(){let t=this.h.Wh.contentEl();t.style.top="",t.style.bottom="",t.style.right="",t.style.left="",t.style.width="",t.style.height="",t.style.position=""}Zo(){Ct(this.lo,"theo-pip"),this.To&&this.Fo&&Ct(this.lo,"theo-pip-"+this.Fo),this.qo&&(wt(this.qo),this.qo=void 0)}dn(){this.Zo(),this.Ko(),this.ta(),this.h.un("play",this.Mo),this.h.un("sourcechange",this.Eo),this.h.Wh.off("languagechange",this.ee),this.h=void 0}constructor(t,i,s){super(),this.ia=!1,this.Co=!1,this.Uo=!1,this.Ro=!1,this.$o=!1,this.Qo=!1,this.zo=!1,this.Mo=()=>{this.ia=!0,this.Xo&&!this.To&&this.Jo&&this.po&&this.Jo.Kh<=this.po&&this.No(!1)},this.Eo=()=>{this.Io||(this.ia=!1,this.Lo(!1))},this.ee=()=>{if(this.Wo){const t=this.h.Wh;$t(this.Wo,t.localize("Video playing in Picture-in-Picture mode"))}},this.Yo=t=>{!this.Ro&&this.Xo&&(_(t)||(this.po&&t<=this.po||this.zo?this.Co||this.Uo||this.No(!1):this.Co?this.Lo(!1):this.Uo=!1))},this.po=i.visibility,this.Fo=i.position,this.Io=i.retainPresentationModeOnSourceChange,this.Xo=void 0!==this.po,this.h=t,this.lo=t.Xh,this._o=s,this.Ao()}},lu=class extends st{sa(){let t=super.sa();return t===it.INLINE&&this.ea&&this.ea.To?it.PICTURE_IN_PICTURE:t}na(t){return t===it.PICTURE_IN_PICTURE||super.na(t)}ra(t,i){t===it.FULLSCREEN&&this.ea.Ko(),super.ra(t,i),t!==it.FULLSCREEN&&this.ea.Go()}ha(t,i){t!==i&&(t===it.FULLSCREEN&&this.ea.Lo(!1),t===it.INLINE&&i===it.PICTURE_IN_PICTURE&&this.ea.Lo(!0),super.ha(t,i),t===it.PICTURE_IN_PICTURE&&(i===it.INLINE?this.ea.No(!0):this.ea.No(!1)))}dn(){super.dn(),this.ea.dn(),this.oa.un("play",this.aa),this.oa=void 0}constructor(t,i,s){super(i),this.ua=()=>this.Wr(),this._o=()=>this.ca(it.INLINE),this.aa=()=>{this.sa()!==it.FULLSCREEN&&this.ea.Go(),this.oa.un("play",this.aa)},this.oa=t,this.ea=new cu(t,s.pip,this._o),this.ea.vn("presentationmodechange",this.ua),this.oa.vn("play",this.aa),this.Wr()}},fu=class extends C{get la(){return mt.fa(this.Wh.el())||this.Wh.supportsFullScreen()}get ls(){return this.Wh.isFullscreen()||this.da}No(){this.Wh.requestFullscreen()}Lo(){this.Wh.exitFullscreen(),this.va.Lo()}dn(){this.ta(),this.Wh.off("fullscreenchange",this.pa),this.va.un(Z.ma,this.pa),this.va.un(Z.ga,this.Rs),this.Wh.isFullWindow&&this.Wh.exitFullscreen()}constructor(t,i){super(),this.Vs=!1,this.da=!1,this.ya=!1,this.pa=()=>{if(this.ya)return;let t=this.Vs,i=this.ls;t!==i&&(this.Vs=i,this.Vo(new ft))},this.ba=()=>{this.da=this.va.ls,this.pa()},this.ka=()=>{this.ya||(this.Wh.isFullWindow&&this.Wh.supportsFullScreen()||this.da&&!this.Wh.supportsFullScreen())&&(this.ya=!0,this.Wh.exitFullscreen(),this.Wh.requestFullscreen(),this.ya=!1,this.pa())},this.Wh=t,this.va=i,this.Wh.on("fullscreenchange",this.pa),this.va.vn(Z.ma,this.ba),this.va.vn(Z.wa,this.ka),this.va.vn(Z.ga,this.Rs),this.pa()}};ni((function(t){return class extends t{ls(){return"fullscreen"===this.ja.sa()}zh(){let t=this.ja;return N(super.zh(),{get presentation(){return t.Qh},get presentationMode(){return t.Qh.currentMode},set presentationMode(i){t.Qh.requestMode(i)}})}dn(){this.ja.dn(),this.Sa.dn(),super.dn()}constructor(t,i,s){super(t,i,s),this.Sa=new fu(this.Wh,this._a),this.ja=new lu(this,this.Sa,s),this.ja.vn("presentationmodechange",this.Rs)}}}),h.t);var du="theo-cast-",vu=Kh.getComponent("Button"),pu=class extends(wo(vu)){get xa(){throw new m("Ta")}get Ca(){return this.o.Ca}get Pa(){return this.o.Pa}buildCSSClass(){return du+"button theo-"+this.Pa+"-button theo-controlbar-button "+super.buildCSSClass()}createEl(t,i,s){let e=super.createEl(),n=u.createElement("div");n.className="theo-button-icon-blur";let r=u.createElement("div");return r.className=du+"svg-container",r.innerHTML=this.Ca,e.appendChild(n),e.appendChild(r),e}handleClick(t){var i;if(super.handleClick(t),this.Aa===et.AVAILABLE)null==(i=this.xa)||i.start();else if(this.Aa===et.CONNECTED||this.Aa===et.CONNECTING){var s;null==(s=this.xa)||s.stop()}}Ma(t){Ct(this.lo,"theo-"+this.Pa+"-"+this.Aa),this.Aa=t,xt(this.lo,"theo-"+this.Pa+"-"+this.Aa),this.ee()}ee(){this.Ia(this.Aa),this.Be.$e=this.controlText()}Ia(t){t===et.CONNECTED?this.controlText("Stop Casting"):t===et.AVAILABLE?this.controlText("Start Casting"):t===et.CONNECTING?this.controlText("Connecting"):this.controlText("Unavailable")}constructor(t,i){var s;super(t,i),this.lo=t.el(),this.Aa=et.UNAVAILABLE,this.controlText("Unavailable"),this.Be=new No(this,this.controlText()),null==(s=this.xa)||s.addEventListener("statechange",(t=>{const i=t;this.Ma(i.state)})),rt.te.Ke&&new jo(this.el()),this.Ma(this.xa?this.xa.state:et.UNAVAILABLE),this.on(t,"languagechange",this.ee)}},mu=0;function gu(){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-'+mu+'">\n <path d="M0-36h44V0H0z"/>\n </clipPath>\n </defs>\n\t <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\t <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-'+mu+')">\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 mu++,t}Kh.registerComponent("chromecastButton",class extends pu{get xa(){var t;return null==(t=this.Ts.cast)?void 0:t.chromecast}constructor(t,i){super(t,Rt({},i,{Pa:"chromecast",Ca:gu()}))}});var yu="theo-chromecast-",bu=Kh.getComponent("Component"),ku=class t extends(wo(bu)){buildCSSClass(){return yu+"overlay "+super.buildCSSClass()}createEl(){let i=super.createEl();xt(i,yu+"overlay");let s=Kh.createEl("div",{className:yu+"status-icon",innerHTML:t.ICON_SVG}),e=Kh.createEl("div",{className:yu+"status-info"});$t(e,"Playing on");let n=Kh.createEl("div",{className:yu+"status-title"}),r=Kh.createEl("div",{className:yu+"status"});return this.ar=n,r.appendChild(s),r.appendChild(e),r.appendChild(n),i.appendChild(r),i}dispose(){var t;null==(t=this.Ea)||t.removeEventListener("statechange",this.update),this.Ea=void 0,this.Ts.removeEventListener("play",this.update),super.dispose()}constructor(t,i){var s,e;super(t,i),this.update=()=>{this.Ea?(this.ar&&$t(this.ar,this.Ea.receiverName||""),this.Ea.state===et.CONNECTED?this.show():this.hide()):this.hide()},this.Ea=null==(s=this.Ts.cast)?void 0:s.chromecast,null==(e=this.Ea)||e.addEventListener("statechange",this.update),this.Ts.addEventListener("play",this.update),this.update()}};ku.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>',Kh.registerComponent("chromecastOverlay",ku);Kh.registerComponent("airplayButton",class extends pu{dispose(){var t,i;null==(t=this.Ts.ads)||t.removeEventListener("adbreakbegin",this.Da),null==(i=this.Ts.ads)||i.removeEventListener("adbreakend",this.Fa),this.Ts.removeEventListener("currentsourcechange",this.Fa),super.dispose()}get xa(){var t;return null==(t=this.Ts.cast)?void 0:t.airplay}constructor(t,i){var s,e;super(t,Rt({},i,{Pa:"airplay",Ca:'\n<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24">\n <path class="theo-cast-inner" d="M5 7h14v8H5z"/>\n <path d="M6 22h12l-6-6zM21 3H3c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h4v-2H3V5h18v12h-4v2h4c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2z"/>\n</svg>'})),this.Fa=()=>{this.enable()},this.Da=()=>{this.disable()},null==(s=this.Ts.ads)||s.addEventListener("adbreakbegin",this.Da),null==(e=this.Ts.ads)||e.addEventListener("adbreakend",this.Fa),this.Ts.addEventListener("currentsourcechange",this.Fa)}});var wu={Default:"","Monospaced Serif":kt.Na,"Proportional Serif":kt.$a,"Monospaced Sans-Serif":kt.Ba,"Proportional Sans-Serif":kt.Oa},ju={White:"#ffffff",Yellow:"#ffff00",Green:"#00ff00",Cyan:"#00ffff",Blue:"#0000ff",Magenta:"#ff00ff",Red:"#ff0000",Black:"#000000"},Su=[50,75,100,150,200];function _u(t){return{label:t+"%",value:t}}function xu(t){return k.keys(t).map((i=>({label:i,value:t[i]})))}Su.map((function(t){return{label:t+"%",value:t/100+"em"}}));var Tu=Su.map((function(t){return{label:t+"%",value:t+"%"}})),Cu=[25,50,75,100].map(_u),Pu=[0,25,50,75,100].map(_u),Au=xu(ju),Mu=xu(wu),Iu=xu({None:"none","Drop Shadow":"dropshadow",Raised:"raised",Depressed:"depressed",Uniform:"uniform"}),Eu=100,Du="#000000",Fu="#FFFFFF",Nu="#000000",$u=class extends ma{Ra(){let t=this.Ar.localize(this.Ua);$t(this.Va.subMenu.menuHeader.el(),t),this.Pr=u.createElement("span"),this.Pr.className="theo-settings-control-menu-item-title",$t(this.Pr,t);let i=u.createElement("span");return i.className="theo-primary-color theo-settings-control-menu-item-value",xt(this.Va.el(),"theo-subtitle-options-menu-item"),this.Va.el().appendChild(this.Pr),this.Va.el().appendChild(i),i}La(t){const i=this.br(t);i&&this.Ha(i)}za(){return this.lr}jr(t){this.Wa(t.kr)}Ha(t){for(let t of this.gr.menuItems)t.selected(!1);t?(t.selected(!0),this.qa(t.kr.label)):this.qa("Custom")}qa(t){this.Ga=t,$t(this.Xa,this.Ar.localize(t)),this.Va.parentMenu.ae()}wr(t){let i=super.wr(t);return xt(i.el(),"theo-subtitle-options-menu-item"),this.Tr(i),i}Tr(t){const i=this.Ar.localize(t.kr.label);$t(t.el(),i);const s=this.Ar.localize("Set "+this.gr.menuHeader.el().textContent+" to "+t.kr.label);t.el().setAttribute("aria-label",s)}Ve(){this.Ar.off("languagechange",this.ee),super.Ve()}constructor(t,i,s,e){super(t.subMenu),this.Va=t,this.Ar=e,this.Ga="",this.ee=()=>{let t=this.Ar.localize(this.Ua);$t(this.Va.subMenu.menuHeader.el(),t),$t(this.Pr,t),this.qa(this.Ga);for(const t of this.yr)this.Tr(t)},this.Ua=i,this.Wa=s.ua,this.Xa=this.Ra(),this.lr=s.Qa,this.Ar.on("languagechange",this.ee)}},Bu=class t{static Ja(t,i,s,e){if(void 0===t&&void 0===i)return;return Mt(void 0===t?s:t,void 0===i?e:i)}constructor(i){this.Ya=i,this.Ka=t=>{this.Ya.fontFamily=t.value},this.Za=t=>{this.Ya.fontSize=t.value},this.tu=i=>{this.iu=i.value,this.Ya.fontColor=t.Ja(this.su,this.iu,Fu,Eu)},this.eu=i=>{this.su=i.value,this.Ya.fontColor=t.Ja(this.su,this.iu,Fu,Eu)},this.nu=i=>{this.ru=i.value,this.Ya.backgroundColor=t.Ja(this.ru,this.hu,Du,Eu)},this.ou=i=>{this.hu=i.value,this.Ya.backgroundColor=t.Ja(this.ru,this.hu,Du,Eu)},this.au=i=>{this.uu=i.value,this.Ya.windowColor=t.Ja(this.uu,this.cu,Nu,Eu)},this.lu=i=>{this.cu=i.value,this.Ya.windowColor=t.Ja(this.uu,this.cu,Nu,Eu)},this.fu=t=>{this.Ya.edgeStyle=t.value}}},Ou=class{du(t,i){const s=this.vu(t,i.za());s&&i.La(s)}vu(t,i){return Gt(i,(i=>i.value===t))}pu(t,i,s){let e,n;if(void 0===t)e=this.vu(void 0,i.za()),n=this.vu(void 0,s.za());else if(t){let r=function(t){let i=Pt(t);i||(i=Pt(t.slice(0,t.length-1).replace("rgb","rgba")+",1)"));i||(i=jt(_t(t),1));if(!i){let s=t.charAt(0).toUpperCase()+t.toLowerCase().slice(1);i=jt(_t(ju[s]),1)}return i}(t);if(r){let t=Tt(r),h=100*r.mu;e=this.vu(t,i.za()),n=this.vu(h,s.za())}}e&&i.La(e),n&&s.La(n)}constructor(t,i){this.Ya=t,this.gu=i,this.yu=()=>{let t=this.Ya.fontFamily;this.du(t,this.gu["Font family"]);let i=this.Ya.fontColor;this.pu(i,this.gu["Font color"],this.gu["Font opacity"]);let s=this.Ya.fontSize;this.du(s,this.gu["Font size"]);let e=this.Ya.backgroundColor;this.pu(e,this.gu["Background color"],this.gu["Background opacity"]);let n=this.Ya.windowColor;this.pu(n,this.gu["Window color"],this.gu["Window opacity"]);let r=this.Ya.edgeStyle;this.du(r,this.gu["Character edge style"])},this.Ya.addEventListener("change",this.yu),this.yu()}};var Ru=class extends ma{bu(){return{"Font family":{Qa:Uu(Mu),ua:this.ku.Ka},"Font color":{Qa:Uu(Au),ua:this.ku.eu},"Font opacity":{Qa:Uu(Cu),ua:this.ku.tu},"Font size":{Qa:Uu(Tu),ua:this.ku.Za},"Background color":{Qa:Uu(Au),ua:this.ku.nu},"Background opacity":{Qa:Uu(Pu),ua:this.ku.ou},"Window color":{Qa:Uu(Au),ua:this.ku.au},"Window opacity":{Qa:Uu(Pu),ua:this.ku.lu},"Character edge style":{Qa:Uu(Iu),ua:this.ku.fu}}}wu(){$t(this.gr.menuHeader.el(),this.Ar.localize("Subtitle Options")),this.Pr=u.createElement("span"),this.Pr.className="theo-settings-control-menu-item-title",$t(this.Pr,this.Ar.localize("Subtitle")),this.ju=u.createElement("span"),this.ju.className="theo-primary-color theo-settings-control-menu-item-value",$t(this.ju,this.Ar.localize("Options")),this.Br.el().appendChild(this.Pr),this.Br.el().appendChild(this.ju),this.Br.el().setAttribute("aria-label",this.Ar.localize("Open the subtitle options menu")),this.Su.addEventListener(["addtrack","removetrack"],this._u),this._u()}wr(t){let i=this.gr.addSubMenuItem();return i.kr=t,this.gu[t]=new $u(i,t,this.xu[t],this.Ar),i}Tr(t){}jr(t){}Ve(){this.Ar.off("languagechange",this.ee),super.Ve()}constructor(t,i,s,e){super(t.subMenu),this.Br=t,this.Su=i,this.Ar=e,this.gu={},this._u=()=>{this.Su.some((t=>J(t.kind)))?this.Br.show():this.Br.hide()},this.ee=()=>{$t(this.gr.menuHeader.el(),this.Ar.localize("Subtitle Options")),$t(this.Pr,this.Ar.localize("Subtitle")),$t(this.ju,this.Ar.localize("Options")),this.Br.el().setAttribute("aria-label",this.Ar.localize("Open the subtitle options menu"))},this.ku=new Bu(s),this.xu=this.bu(),this.lr=k.keys(this.xu),this.wu(),this.Tu=new Ou(s,this.gu),this.Ar.on("languagechange",this.ee)}};function Uu(t){let i=[{label:"Default",value:void 0}];for(let s of t)"Default"!==s.label&&i.push(s);return i}ni((function(t){return class extends t{dn(){this.Cu.removeMenuItem(this.Pu),super.dn()}constructor(t,i,s){super(t,i,s),this.Cu=this.Wh.controlBar.getChild("SettingsButton").menu,this.Pu=this.Cu.addSubMenuItem({name:"TextTrackOptionsMenuItem"}),new Ru(this.Pu,this.rt.Qh,this.Au.Qh,this.Wh)}}}),h.t);export{zt as ChromelessPlayer,I as ErrorCategory,A as ErrorCode,iu as Player,$ as cache,E as cast,Xt as features,Kt as playerSuiteVersion,ti as players,si as registerContentProtectionIntegration,qt as utils,Jt as version,Kh as videojs};