!function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,e),o.l=!0,o.exports}var n={};e.m=t,e.c=n,e.d=function(t,n,r){e.o(t,n)||Object.defineProperty(t,n,{configurable:!1,enumerable:!0,get:r})},e.n=function(t){var n=t&&t.__esModule?function(){return t.default}:function(){return t};return e.d(n,"a",n),n},e.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},e.p="",e(e.s=37)}([function(t,e,n){var r=n(29)("wks"),o=n(17),i=n(1).Symbol,s="function"==typeof i;(t.exports=function(t){return r[t]||(r[t]=s&&i[t]||(s?i:o)("Symbol."+t))}).store=r},function(t,e){var n=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=n)},function(t,e,n){var r=n(9),o=n(25);t.exports=n(5)?function(t,e,n){return r.f(t,e,o(1,n))}:function(t,e,n){return t[e]=n,t}},function(t,e,n){var r=n(10);t.exports=function(t){if(!r(t))throw TypeError(t+" is not an object!");return t}},function(t,e){var n=t.exports={version:"2.4.0"};"number"==typeof __e&&(__e=n)},function(t,e,n){t.exports=!n(15)(function(){return 7!=Object.defineProperty({},"a",{get:function(){return 7}}).a})},function(t,e,n){var r=n(1),o=n(2),i=n(7),s=n(17)("src"),a=Function.toString,l=(""+a).split("toString");n(4).inspectSource=function(t){return a.call(t)},(t.exports=function(t,e,n,a){var c="function"==typeof n;c&&(i(n,"name")||o(n,"name",e)),t[e]!==n&&(c&&(i(n,s)||o(n,s,t[e]?""+t[e]:l.join(String(e)))),t===r?t[e]=n:a?t[e]?t[e]=n:o(t,e,n):(delete t[e],o(t,e,n)))})(Function.prototype,"toString",function(){return"function"==typeof this&&this[s]||a.call(this)})},function(t,e){var n={}.hasOwnProperty;t.exports=function(t,e){return n.call(t,e)}},function(t,e){t.exports={}},function(t,e,n){var r=n(3),o=n(39),i=n(40),s=Object.defineProperty;e.f=n(5)?Object.defineProperty:function(t,e,n){if(r(t),e=i(e,!0),r(n),o)try{return s(t,e,n)}catch(t){}if("get"in n||"set"in n)throw TypeError("Accessors not supported!");return"value"in n&&(t[e]=n.value),t}},function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},function(t,e,n){var r=n(18);t.exports=function(t,e,n){if(r(t),void 0===e)return t;switch(n){case 1:return function(n){return t.call(e,n)};case 2:return function(n,r){return t.call(e,n,r)};case 3:return function(n,r,o){return t.call(e,n,r,o)}}return function(){return t.apply(e,arguments)}}},function(t,e){var n={}.toString;t.exports=function(t){return n.call(t).slice(8,-1)}},function(t,e){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(t){"object"==typeof window&&(n=window)}t.exports=n},function(t,e,n){var r=n(1),o=n(4),i=n(2),s=n(6),a=n(11),l=function(t,e,n){var c,u,h,p,d=t&l.F,f=t&l.G,v=t&l.S,y=t&l.P,g=t&l.B,m=f?r:v?r[e]||(r[e]={}):(r[e]||{}).prototype,A=f?o:o[e]||(o[e]={}),_=A.prototype||(A.prototype={});f&&(n=e);for(c in n)u=!d&&m&&void 0!==m[c],h=(u?m:n)[c],p=g&&u?a(h,r):y&&"function"==typeof h?a(Function.call,h):h,m&&s(m,c,h,t&l.U),A[c]!=h&&i(A,c,p),y&&_[c]!=h&&(_[c]=h)};r.core=o,l.F=1,l.G=2,l.S=4,l.P=8,l.B=16,l.W=32,l.U=64,l.R=128,t.exports=l},function(t,e){t.exports=function(t){try{return!!t()}catch(t){return!0}}},function(t,e,n){var r=n(10),o=n(1).document,i=r(o)&&r(o.createElement);t.exports=function(t){return i?o.createElement(t):{}}},function(t,e){var n=0,r=Math.random();t.exports=function(t){return"Symbol(".concat(void 0===t?"":t,")_",(++n+r).toString(36))}},function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},function(t,e,n){var r=n(27),o=n(20);t.exports=function(t){return r(o(t))}},function(t,e){t.exports=function(t){if(void 0==t)throw TypeError("Can't call method on  "+t);return t}},function(t,e){var n=Math.ceil,r=Math.floor;t.exports=function(t){return isNaN(t=+t)?0:(t>0?r:n)(t)}},function(t,e,n){var r=n(29)("keys"),o=n(17);t.exports=function(t){return r[t]||(r[t]=o(t))}},function(t,e,n){var r=n(12),o=n(0)("toStringTag"),i="Arguments"==r(function(){return arguments}()),s=function(t,e){try{return t[e]}catch(t){}};t.exports=function(t){var e,n,a;return void 0===t?"Undefined":null===t?"Null":"string"==typeof(n=s(e=Object(t),o))?n:i?r(e):"Object"==(a=r(e))&&"function"==typeof e.callee?"Arguments":a}},function(t,e,n){var r=n(9).f,o=n(7),i=n(0)("toStringTag");t.exports=function(t,e,n){t&&!o(t=n?t:t.prototype,i)&&r(t,i,{configurable:!0,value:e})}},function(t,e){t.exports=function(t,e){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:e}}},function(t,e,n){var r=n(42),o=n(30);t.exports=Object.keys||function(t){return r(t,o)}},function(t,e,n){var r=n(12);t.exports=Object("z").propertyIsEnumerable(0)?Object:function(t){return"String"==r(t)?t.split(""):Object(t)}},function(t,e,n){var r=n(21),o=Math.min;t.exports=function(t){return t>0?o(r(t),9007199254740991):0}},function(t,e,n){var r=n(1),o=r["__core-js_shared__"]||(r["__core-js_shared__"]={});t.exports=function(t){return o[t]||(o[t]={})}},function(t,e){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},function(t,e,n){var r=n(20);t.exports=function(t){return Object(r(t))}},function(t,e,n){"use strict";var r=n(33),o=n(14),i=n(6),s=n(2),a=n(7),l=n(8),c=n(51),u=n(24),h=n(54),p=n(0)("iterator"),d=!([].keys&&"next"in[].keys()),f=function(){return this};t.exports=function(t,e,n,v,y,g,m){c(n,e,v);var A,_,b,T=function(t){if(!d&&t in E)return E[t];switch(t){case"keys":case"values":return function(){return new n(this,t)}}return function(){return new n(this,t)}},w=e+" Iterator",C="values"==y,k=!1,E=t.prototype,x=E[p]||E["@@iterator"]||y&&E[y],S=x||T(y),j=y?C?T("entries"):S:void 0,P="Array"==e?E.entries||x:x;if(P&&(b=h(P.call(new t)))!==Object.prototype&&(u(b,w,!0),r||a(b,p)||s(b,p,f)),C&&x&&"values"!==x.name&&(k=!0,S=function(){return x.call(this)}),r&&!m||!d&&!k&&E[p]||s(E,p,S),l[e]=S,l[w]=f,y)if(A={values:C?S:T("values"),keys:g?S:T("keys"),entries:j},m)for(_ in A)_ in E||i(E,_,A[_]);else o(o.P+o.F*(d||k),e,A);return A}},function(t,e){t.exports=!1},function(t,e,n){t.exports=n(1).document&&document.documentElement},function(t,e,n){var r,o,i,s=n(11),a=n(66),l=n(34),c=n(16),u=n(1),h=u.process,p=u.setImmediate,d=u.clearImmediate,f=u.MessageChannel,v=0,y={},g=function(){var t=+this;if(y.hasOwnProperty(t)){var e=y[t];delete y[t],e()}},m=function(t){g.call(t.data)};p&&d||(p=function(t){for(var e=[],n=1;arguments.length>n;)e.push(arguments[n++]);return y[++v]=function(){a("function"==typeof t?t:Function(t),e)},r(v),v},d=function(t){delete y[t]},"process"==n(12)(h)?r=function(t){h.nextTick(s(g,t,1))}:f?(o=new f,i=o.port2,o.port1.onmessage=m,r=s(i.postMessage,i,1)):u.addEventListener&&"function"==typeof postMessage&&!u.importScripts?(r=function(t){u.postMessage(t+"","*")},u.addEventListener("message",m,!1)):r="onreadystatechange"in c("script")?function(t){l.appendChild(c("script")).onreadystatechange=function(){l.removeChild(this),g.call(t)}}:function(t){setTimeout(s(g,t,1),0)}),t.exports={set:p,clear:d}},function(t,e){function n(t){var e=r.call(t);return"[object Function]"===e||"function"==typeof t&&"[object RegExp]"!==e||"undefined"!=typeof window&&(t===window.setTimeout||t===window.alert||t===window.confirm||t===window.prompt)}t.exports=n;var r=Object.prototype.toString},function(t,e,n){n(38),n(47),n(71),t.exports=n(72)},function(t,e,n){var r=n(14);r(r.S+r.F,"Object",{assign:n(41)})},function(t,e,n){t.exports=!n(5)&&!n(15)(function(){return 7!=Object.defineProperty(n(16)("div"),"a",{get:function(){return 7}}).a})},function(t,e,n){var r=n(10);t.exports=function(t,e){if(!r(t))return t;var n,o;if(e&&"function"==typeof(n=t.toString)&&!r(o=n.call(t)))return o;if("function"==typeof(n=t.valueOf)&&!r(o=n.call(t)))return o;if(!e&&"function"==typeof(n=t.toString)&&!r(o=n.call(t)))return o;throw TypeError("Can't convert object to primitive value")}},function(t,e,n){"use strict";var r=n(26),o=n(45),i=n(46),s=n(31),a=n(27),l=Object.assign;t.exports=!l||n(15)(function(){var t={},e={},n=Symbol(),r="abcdefghijklmnopqrst";return t[n]=7,r.split("").forEach(function(t){e[t]=t}),7!=l({},t)[n]||Object.keys(l({},e)).join("")!=r})?function(t,e){for(var n=s(t),l=arguments.length,c=1,u=o.f,h=i.f;l>c;)for(var p,d=a(arguments[c++]),f=u?r(d).concat(u(d)):r(d),v=f.length,y=0;v>y;)h.call(d,p=f[y++])&&(n[p]=d[p]);return n}:l},function(t,e,n){var r=n(7),o=n(19),i=n(43)(!1),s=n(22)("IE_PROTO");t.exports=function(t,e){var n,a=o(t),l=0,c=[];for(n in a)n!=s&&r(a,n)&&c.push(n);for(;e.length>l;)r(a,n=e[l++])&&(~i(c,n)||c.push(n));return c}},function(t,e,n){var r=n(19),o=n(28),i=n(44);t.exports=function(t){return function(e,n,s){var a,l=r(e),c=o(l.length),u=i(s,c);if(t&&n!=n){for(;c>u;)if((a=l[u++])!=a)return!0}else for(;c>u;u++)if((t||u in l)&&l[u]===n)return t||u||0;return!t&&-1}}},function(t,e,n){var r=n(21),o=Math.max,i=Math.min;t.exports=function(t,e){return t=r(t),t<0?o(t+e,0):i(t,e)}},function(t,e){e.f=Object.getOwnPropertySymbols},function(t,e){e.f={}.propertyIsEnumerable},function(t,e,n){n(48),n(49),n(55),n(59),t.exports=n(4).Promise},function(t,e,n){"use strict";var r=n(23),o={};o[n(0)("toStringTag")]="z",o+""!="[object z]"&&n(6)(Object.prototype,"toString",function(){return"[object "+r(this)+"]"},!0)},function(t,e,n){"use strict";var r=n(50)(!0);n(32)(String,"String",function(t){this._t=String(t),this._i=0},function(){var t,e=this._t,n=this._i;return n>=e.length?{value:void 0,done:!0}:(t=r(e,n),this._i+=t.length,{value:t,done:!1})})},function(t,e,n){var r=n(21),o=n(20);t.exports=function(t){return function(e,n){var i,s,a=String(o(e)),l=r(n),c=a.length;return l<0||l>=c?t?"":void 0:(i=a.charCodeAt(l),i<55296||i>56319||l+1===c||(s=a.charCodeAt(l+1))<56320||s>57343?t?a.charAt(l):i:t?a.slice(l,l+2):s-56320+(i-55296<<10)+65536)}}},function(t,e,n){"use strict";var r=n(52),o=n(25),i=n(24),s={};n(2)(s,n(0)("iterator"),function(){return this}),t.exports=function(t,e,n){t.prototype=r(s,{next:o(1,n)}),i(t,e+" Iterator")}},function(t,e,n){var r=n(3),o=n(53),i=n(30),s=n(22)("IE_PROTO"),a=function(){},l=function(){var t,e=n(16)("iframe"),r=i.length;for(e.style.display="none",n(34).appendChild(e),e.src="javascript:",t=e.contentWindow.document,t.open(),t.write("<script>document.F=Object<\/script>"),t.close(),l=t.F;r--;)delete l.prototype[i[r]];return l()};t.exports=Object.create||function(t,e){var n;return null!==t?(a.prototype=r(t),n=new a,a.prototype=null,n[s]=t):n=l(),void 0===e?n:o(n,e)}},function(t,e,n){var r=n(9),o=n(3),i=n(26);t.exports=n(5)?Object.defineProperties:function(t,e){o(t);for(var n,s=i(e),a=s.length,l=0;a>l;)r.f(t,n=s[l++],e[n]);return t}},function(t,e,n){var r=n(7),o=n(31),i=n(22)("IE_PROTO"),s=Object.prototype;t.exports=Object.getPrototypeOf||function(t){return t=o(t),r(t,i)?t[i]:"function"==typeof t.constructor&&t instanceof t.constructor?t.constructor.prototype:t instanceof Object?s:null}},function(t,e,n){for(var r=n(56),o=n(6),i=n(1),s=n(2),a=n(8),l=n(0),c=l("iterator"),u=l("toStringTag"),h=a.Array,p=["NodeList","DOMTokenList","MediaList","StyleSheetList","CSSRuleList"],d=0;d<5;d++){var f,v=p[d],y=i[v],g=y&&y.prototype;if(g){g[c]||s(g,c,h),g[u]||s(g,u,v),a[v]=h;for(f in r)g[f]||o(g,f,r[f],!0)}}},function(t,e,n){"use strict";var r=n(57),o=n(58),i=n(8),s=n(19);t.exports=n(32)(Array,"Array",function(t,e){this._t=s(t),this._i=0,this._k=e},function(){var t=this._t,e=this._k,n=this._i++;return!t||n>=t.length?(this._t=void 0,o(1)):"keys"==e?o(0,n):"values"==e?o(0,t[n]):o(0,[n,t[n]])},"values"),i.Arguments=i.Array,r("keys"),r("values"),r("entries")},function(t,e,n){var r=n(0)("unscopables"),o=Array.prototype;void 0==o[r]&&n(2)(o,r,{}),t.exports=function(t){o[r][t]=!0}},function(t,e){t.exports=function(t,e){return{value:e,done:!!t}}},function(t,e,n){"use strict";var r,o,i,s=n(33),a=n(1),l=n(11),c=n(23),u=n(14),h=n(10),p=n(18),d=n(60),f=n(61),v=n(65),y=n(35).set,g=n(67)(),m=a.TypeError,A=a.process,_=a.Promise,A=a.process,b="process"==c(A),T=function(){},w=!!function(){try{var t=_.resolve(1),e=(t.constructor={})[n(0)("species")]=function(t){t(T,T)};return(b||"function"==typeof PromiseRejectionEvent)&&t.then(T)instanceof e}catch(t){}}(),C=function(t,e){return t===e||t===_&&e===i},k=function(t){var e;return!(!h(t)||"function"!=typeof(e=t.then))&&e},E=function(t){return C(_,t)?new x(t):new o(t)},x=o=function(t){var e,n;this.promise=new t(function(t,r){if(void 0!==e||void 0!==n)throw m("Bad Promise constructor");e=t,n=r}),this.resolve=p(e),this.reject=p(n)},S=function(t){try{t()}catch(t){return{error:t}}},j=function(t,e){if(!t._n){t._n=!0;var n=t._c;g(function(){for(var r=t._v,o=1==t._s,i=0;n.length>i;)!function(e){var n,i,s=o?e.ok:e.fail,a=e.resolve,l=e.reject,c=e.domain;try{s?(o||(2==t._h&&I(t),t._h=1),!0===s?n=r:(c&&c.enter(),n=s(r),c&&c.exit()),n===e.promise?l(m("Promise-chain cycle")):(i=k(n))?i.call(n,a,l):a(n)):l(r)}catch(t){l(t)}}(n[i++]);t._c=[],t._n=!1,e&&!t._h&&P(t)})}},P=function(t){y.call(a,function(){var e,n,r,o=t._v;if(O(t)&&(e=S(function(){b?A.emit("unhandledRejection",o,t):(n=a.onunhandledrejection)?n({promise:t,reason:o}):(r=a.console)&&r.error&&r.error("Unhandled promise rejection",o)}),t._h=b||O(t)?2:1),t._a=void 0,e)throw e.error})},O=function(t){if(1==t._h)return!1;for(var e,n=t._a||t._c,r=0;n.length>r;)if(e=n[r++],e.fail||!O(e.promise))return!1;return!0},I=function(t){y.call(a,function(){var e;b?A.emit("rejectionHandled",t):(e=a.onrejectionhandled)&&e({promise:t,reason:t._v})})},M=function(t){var e=this;e._d||(e._d=!0,e=e._w||e,e._v=t,e._s=2,e._a||(e._a=e._c.slice()),j(e,!0))},N=function(t){var e,n=this;if(!n._d){n._d=!0,n=n._w||n;try{if(n===t)throw m("Promise can't be resolved itself");(e=k(t))?g(function(){var r={_w:n,_d:!1};try{e.call(t,l(N,r,1),l(M,r,1))}catch(t){M.call(r,t)}}):(n._v=t,n._s=1,j(n,!1))}catch(t){M.call({_w:n,_d:!1},t)}}};w||(_=function(t){d(this,_,"Promise","_h"),p(t),r.call(this);try{t(l(N,this,1),l(M,this,1))}catch(t){M.call(this,t)}},r=function(t){this._c=[],this._a=void 0,this._s=0,this._d=!1,this._v=void 0,this._h=0,this._n=!1},r.prototype=n(68)(_.prototype,{then:function(t,e){var n=E(v(this,_));return n.ok="function"!=typeof t||t,n.fail="function"==typeof e&&e,n.domain=b?A.domain:void 0,this._c.push(n),this._a&&this._a.push(n),this._s&&j(this,!1),n.promise},catch:function(t){return this.then(void 0,t)}}),x=function(){var t=new r;this.promise=t,this.resolve=l(N,t,1),this.reject=l(M,t,1)}),u(u.G+u.W+u.F*!w,{Promise:_}),n(24)(_,"Promise"),n(69)("Promise"),i=n(4).Promise,u(u.S+u.F*!w,"Promise",{reject:function(t){var e=E(this);return(0,e.reject)(t),e.promise}}),u(u.S+u.F*(s||!w),"Promise",{resolve:function(t){if(t instanceof _&&C(t.constructor,this))return t;var e=E(this);return(0,e.resolve)(t),e.promise}}),u(u.S+u.F*!(w&&n(70)(function(t){_.all(t).catch(T)})),"Promise",{all:function(t){var e=this,n=E(e),r=n.resolve,o=n.reject,i=S(function(){var n=[],i=0,s=1;f(t,!1,function(t){var a=i++,l=!1;n.push(void 0),s++,e.resolve(t).then(function(t){l||(l=!0,n[a]=t,--s||r(n))},o)}),--s||r(n)});return i&&o(i.error),n.promise},race:function(t){var e=this,n=E(e),r=n.reject,o=S(function(){f(t,!1,function(t){e.resolve(t).then(n.resolve,r)})});return o&&r(o.error),n.promise}})},function(t,e){t.exports=function(t,e,n,r){if(!(t instanceof e)||void 0!==r&&r in t)throw TypeError(n+": incorrect invocation!");return t}},function(t,e,n){var r=n(11),o=n(62),i=n(63),s=n(3),a=n(28),l=n(64),c={},u={},e=t.exports=function(t,e,n,h,p){var d,f,v,y,g=p?function(){return t}:l(t),m=r(n,h,e?2:1),A=0;if("function"!=typeof g)throw TypeError(t+" is not iterable!");if(i(g)){for(d=a(t.length);d>A;A++)if((y=e?m(s(f=t[A])[0],f[1]):m(t[A]))===c||y===u)return y}else for(v=g.call(t);!(f=v.next()).done;)if((y=o(v,m,f.value,e))===c||y===u)return y};e.BREAK=c,e.RETURN=u},function(t,e,n){var r=n(3);t.exports=function(t,e,n,o){try{return o?e(r(n)[0],n[1]):e(n)}catch(e){var i=t.return;throw void 0!==i&&r(i.call(t)),e}}},function(t,e,n){var r=n(8),o=n(0)("iterator"),i=Array.prototype;t.exports=function(t){return void 0!==t&&(r.Array===t||i[o]===t)}},function(t,e,n){var r=n(23),o=n(0)("iterator"),i=n(8);t.exports=n(4).getIteratorMethod=function(t){if(void 0!=t)return t[o]||t["@@iterator"]||i[r(t)]}},function(t,e,n){var r=n(3),o=n(18),i=n(0)("species");t.exports=function(t,e){var n,s=r(t).constructor;return void 0===s||void 0==(n=r(s)[i])?e:o(n)}},function(t,e){t.exports=function(t,e,n){var r=void 0===n;switch(e.length){case 0:return r?t():t.call(n);case 1:return r?t(e[0]):t.call(n,e[0]);case 2:return r?t(e[0],e[1]):t.call(n,e[0],e[1]);case 3:return r?t(e[0],e[1],e[2]):t.call(n,e[0],e[1],e[2]);case 4:return r?t(e[0],e[1],e[2],e[3]):t.call(n,e[0],e[1],e[2],e[3])}return t.apply(n,e)}},function(t,e,n){var r=n(1),o=n(35).set,i=r.MutationObserver||r.WebKitMutationObserver,s=r.process,a=r.Promise,l="process"==n(12)(s);t.exports=function(){var t,e,n,c=function(){var r,o;for(l&&(r=s.domain)&&r.exit();t;){o=t.fn,t=t.next;try{o()}catch(r){throw t?n():e=void 0,r}}e=void 0,r&&r.enter()};if(l)n=function(){s.nextTick(c)};else if(i){var u=!0,h=document.createTextNode("");new i(c).observe(h,{characterData:!0}),n=function(){h.data=u=!u}}else if(a&&a.resolve){var p=a.resolve();n=function(){p.then(c)}}else n=function(){o.call(r,c)};return function(r){var o={fn:r,next:void 0};e&&(e.next=o),t||(t=o,n()),e=o}}},function(t,e,n){var r=n(6);t.exports=function(t,e,n){for(var o in e)r(t,o,e[o],n);return t}},function(t,e,n){"use strict";var r=n(1),o=n(9),i=n(5),s=n(0)("species");t.exports=function(t){var e=r[t];i&&e&&!e[s]&&o.f(e,s,{configurable:!0,get:function(){return this}})}},function(t,e,n){var r=n(0)("iterator"),o=!1;try{var i=[7][r]();i.return=function(){o=!0},Array.from(i,function(){throw 2})}catch(t){}t.exports=function(t,e){if(!e&&!o)return!1;var n=!1;try{var i=[7],s=i[r]();s.next=function(){return{done:n=!0}},i[r]=function(){return s},t(i)}catch(t){}return n}},function(t,e){!function(t,e){"use strict";function n(t){this.time=t.time,this.target=t.target,this.rootBounds=t.rootBounds,this.boundingClientRect=t.boundingClientRect,this.intersectionRect=t.intersectionRect||u(),this.isIntersecting=!!t.intersectionRect;var e=this.boundingClientRect,n=e.width*e.height,r=this.intersectionRect,o=r.width*r.height;this.intersectionRatio=n?o/n:this.isIntersecting?1:0}function r(t,e){var n=e||{};if("function"!=typeof t)throw new Error("callback must be a function");if(n.root&&1!=n.root.nodeType)throw new Error("root must be an Element");this._checkForIntersections=i(this._checkForIntersections.bind(this),this.THROTTLE_TIMEOUT),this._callback=t,this._observationTargets=[],this._queuedEntries=[],this._rootMarginValues=this._parseRootMargin(n.rootMargin),this.thresholds=this._initThresholds(n.threshold),this.root=n.root||null,this.rootMargin=this._rootMarginValues.map(function(t){return t.value+t.unit}).join(" ")}function o(){return t.performance&&performance.now&&performance.now()}function i(t,e){var n=null;return function(){n||(n=setTimeout(function(){t(),n=null},e))}}function s(t,e,n,r){"function"==typeof t.addEventListener?t.addEventListener(e,n,r||!1):"function"==typeof t.attachEvent&&t.attachEvent("on"+e,n)}function a(t,e,n,r){"function"==typeof t.removeEventListener?t.removeEventListener(e,n,r||!1):"function"==typeof t.detatchEvent&&t.detatchEvent("on"+e,n)}function l(t,e){var n=Math.max(t.top,e.top),r=Math.min(t.bottom,e.bottom),o=Math.max(t.left,e.left),i=Math.min(t.right,e.right),s=i-o,a=r-n;return s>=0&&a>=0&&{top:n,bottom:r,left:o,right:i,width:s,height:a}}function c(t){var e;try{e=t.getBoundingClientRect()}catch(t){}return e?(e.width&&e.height||(e={top:e.top,right:e.right,bottom:e.bottom,left:e.left,width:e.right-e.left,height:e.bottom-e.top}),e):u()}function u(){return{top:0,bottom:0,left:0,right:0,width:0,height:0}}function h(t,e){for(var n=e;n;){if(n==t)return!0;n=p(n)}return!1}function p(t){var e=t.parentNode;return e&&11==e.nodeType&&e.host?e.host:e}if("IntersectionObserver"in t&&"IntersectionObserverEntry"in t&&"intersectionRatio"in t.IntersectionObserverEntry.prototype)return void("isIntersecting"in t.IntersectionObserverEntry.prototype||Object.defineProperty(t.IntersectionObserverEntry.prototype,"isIntersecting",{get:function(){return this.intersectionRatio>0}}));var d=[];r.prototype.THROTTLE_TIMEOUT=100,r.prototype.POLL_INTERVAL=null,r.prototype.USE_MUTATION_OBSERVER=!0,r.prototype.observe=function(t){if(!this._observationTargets.some(function(e){return e.element==t})){if(!t||1!=t.nodeType)throw new Error("target must be an Element");this._registerInstance(),this._observationTargets.push({element:t,entry:null}),this._monitorIntersections(),this._checkForIntersections()}},r.prototype.unobserve=function(t){this._observationTargets=this._observationTargets.filter(function(e){return e.element!=t}),this._observationTargets.length||(this._unmonitorIntersections(),this._unregisterInstance())},r.prototype.disconnect=function(){this._observationTargets=[],this._unmonitorIntersections(),this._unregisterInstance()},r.prototype.takeRecords=function(){var t=this._queuedEntries.slice();return this._queuedEntries=[],t},r.prototype._initThresholds=function(t){var e=t||[0];return Array.isArray(e)||(e=[e]),e.sort().filter(function(t,e,n){if("number"!=typeof t||isNaN(t)||t<0||t>1)throw new Error("threshold must be a number between 0 and 1 inclusively");return t!==n[e-1]})},r.prototype._parseRootMargin=function(t){var e=t||"0px",n=e.split(/\s+/).map(function(t){var e=/^(-?\d*\.?\d+)(px|%)$/.exec(t);if(!e)throw new Error("rootMargin must be specified in pixels or percent");return{value:parseFloat(e[1]),unit:e[2]}});return n[1]=n[1]||n[0],n[2]=n[2]||n[0],n[3]=n[3]||n[1],n},r.prototype._monitorIntersections=function(){this._monitoringIntersections||(this._monitoringIntersections=!0,this.POLL_INTERVAL?this._monitoringInterval=setInterval(this._checkForIntersections,this.POLL_INTERVAL):(s(t,"resize",this._checkForIntersections,!0),s(e,"scroll",this._checkForIntersections,!0),this.USE_MUTATION_OBSERVER&&"MutationObserver"in t&&(this._domObserver=new MutationObserver(this._checkForIntersections),this._domObserver.observe(e,{attributes:!0,childList:!0,characterData:!0,subtree:!0}))))},r.prototype._unmonitorIntersections=function(){this._monitoringIntersections&&(this._monitoringIntersections=!1,clearInterval(this._monitoringInterval),this._monitoringInterval=null,a(t,"resize",this._checkForIntersections,!0),a(e,"scroll",this._checkForIntersections,!0),this._domObserver&&(this._domObserver.disconnect(),this._domObserver=null))},r.prototype._checkForIntersections=function(){var t=this._rootIsInDom(),e=t?this._getRootRect():u();this._observationTargets.forEach(function(r){var i=r.element,s=c(i),a=this._rootContainsTarget(i),l=r.entry,u=t&&a&&this._computeTargetAndRootIntersection(i,e),h=r.entry=new n({time:o(),target:i,boundingClientRect:s,rootBounds:e,intersectionRect:u});l?t&&a?this._hasCrossedThreshold(l,h)&&this._queuedEntries.push(h):l&&l.isIntersecting&&this._queuedEntries.push(h):this._queuedEntries.push(h)},this),this._queuedEntries.length&&this._callback(this.takeRecords(),this)},r.prototype._computeTargetAndRootIntersection=function(n,r){if("none"!=t.getComputedStyle(n).display){for(var o=c(n),i=o,s=p(n),a=!1;!a;){var u=null,h=1==s.nodeType?t.getComputedStyle(s):{};if("none"==h.display)return;if(s==this.root||s==e?(a=!0,u=r):s!=e.body&&s!=e.documentElement&&"visible"!=h.overflow&&(u=c(s)),u&&!(i=l(u,i)))break;s=p(s)}return i}},r.prototype._getRootRect=function(){var t;if(this.root)t=c(this.root);else{var n=e.documentElement,r=e.body;t={top:0,left:0,right:n.clientWidth||r.clientWidth,width:n.clientWidth||r.clientWidth,bottom:n.clientHeight||r.clientHeight,height:n.clientHeight||r.clientHeight}}return this._expandRectByRootMargin(t)},r.prototype._expandRectByRootMargin=function(t){var e=this._rootMarginValues.map(function(e,n){return"px"==e.unit?e.value:e.value*(n%2?t.width:t.height)/100}),n={top:t.top-e[0],right:t.right+e[1],bottom:t.bottom+e[2],left:t.left-e[3]};return n.width=n.right-n.left,n.height=n.bottom-n.top,n},r.prototype._hasCrossedThreshold=function(t,e){var n=t&&t.isIntersecting?t.intersectionRatio||0:-1,r=e.isIntersecting?e.intersectionRatio||0:-1;if(n!==r)for(var o=0;o<this.thresholds.length;o++){var i=this.thresholds[o];if(i==n||i==r||i<n!=i<r)return!0}},r.prototype._rootIsInDom=function(){return!this.root||h(e,this.root)},r.prototype._rootContainsTarget=function(t){return h(this.root||e,t)},r.prototype._registerInstance=function(){d.indexOf(this)<0&&d.push(this)},r.prototype._unregisterInstance=function(){var t=d.indexOf(this);-1!=t&&d.splice(t,1)},t.IntersectionObserver=r,t.IntersectionObserverEntry=n}(window,document)},function(t,e,n){"use strict";function r(t,e){var n=o(),r=i(t,e);return r.appendChild(n),{iframe:n,wrapper:r}}function o(){var t=document.createElement("iframe");return s(t,Mt),t.frameBorder="0",t.scrolling="no",t.setAttribute("allowfullscreen",!0),t.setAttribute("msallowfullscreen",!0),t.setAttribute("allowtransparency",!0),t.setAttribute("title","Video Player"),t}function i(t,e){var n=document.createElement("div");return s(n,It(e)),n.classList.add(Nt),n.id=t,n}function s(t,e){t.setAttribute("style",Object.keys(e).map(function(t){return t+":"+e[t]}).join(";")+";")}function a(){var t=window.navigator&&window.navigator.userAgent||"",e=/iPad/i.test(t),n=/iPhone/i.test(t)&&!e,r=/iPod/i.test(t),o=/Android/i.test(t);return e||n||r||o}function l(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Rt,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:a(),r=n?e.mobile:e.main,o=t?[r]:[e.ima,r];return{css:[e.css],js:o}}function c(t,e,n){var r=/FATAL/,o=0;return function(i,s){if(r.test(i)&&(window._assetLoadError={identifier:i,tag:s}),++o===t){var a=void 0;"function"==typeof window.Event?a=new Event(n):(a=document.createEvent("Event"),a.initEvent(n,!0,!0)),e.dispatchEvent(a)}return o}}function u(t){return function(e){var n=e.canAutoplay,r=e.guid,o=e.rawConfig,i=e.secret,s=e.showPlaylistBar,a=e.wrapper,l=JSON.parse(o);return s&&!l.playerConfig.has_playlist&&(console.warn("CNE Player: invalid playlist id."),a.style.height="0px"),l.environment&&(l.environment.guid=r,l.environment.secret=i,l.environment.canAutoplay=n),t._cne.createPlayer(l)}}function h(t,e,n,r){var o=!1;if(window.pAPI){var i=function(t){o||(o=!0,t?e(!0):n(!1))};if(setTimeout(i,t),window.pAPI.ready)r(i);else{var s=setInterval(function(){window.pAPI.ready&&(clearInterval(s),r(i))},50);setTimeout(function(){clearInterval(s)},t)}}else n(!1)}function p(t){return function(e){window.pAPIDeadline(1e4,function(){window._PUBLICA_ENABLED_=!0,t(e,this,!0)},function(){t(e+"-fail")},function(t){window.pAPI.ready(function(e){e&&e.adblock_detected?(window.pAPI.one("event_ima3_loaded",function(e){t(!!e&&!e.err)}),window.pAPI("ima3")):t(!1)})})}}function d(t,e,n){return"\n    "+(Lt.has(n)?Dt():"")+"\n    <script>\n    (function() {\n      window.pAPIDeadline = "+h+";\n      window."+e+" = ("+p+")(window."+t+");\n    })();\n    <\/script>"}function f(t){var e=t.assets,n=t.embedLocation,r=t.eventName,o=void 0===r?Ft:r,i=t.curriedBuildPlayer,s=void 0===i?u:i,a=t.curriedOnload,l=void 0===a?c:a,h=t._injectPublica,p=void 0===h?d:h,f=t.onload,g=void 0===f?"checkLoaded":f,m=t.onaderror,A=void 0===m?"onAdError":m,_=t.target,b=void 0===_?Bt:_,T=(arguments.length>1&&void 0!==arguments[1]&&arguments[1],e||{}),w=T.js,C=void 0===w?[]:w,k=T.css,E=void 0===k?[]:k;return'\n<!DOCTYPE html>\n<html class="embed-html">\n  <head>\n    \n    \n    <script>\n    (function() {\n      window.'+g+" = ("+l+")("+(C.length+E.length)+', window.frameElement, "'+o+'");\n      window._buildPlayer = ('+s+")(window);\n      "+(window._CNE_AD_FIXTURE_?"window._CNE_AD_FIXTURE_ = '"+window._CNE_AD_FIXTURE_+"';":"")+"\n    })();\n    <\/script>\n    "+p(g,A,n)+"\n    "+y(E,g)+'\n  </head>\n  <body class="embed-body">\n    <div id="embed-container">\n      <div id="'+b+'"></div>\n    </div>\n    '+v(C,g,A)+"\n  </body>\n</html>\n  "}function v(t,e,n){return t.map(function(t){var r=t.ad?"ad":"script",o=t.ad?'onerror="'+n+"('"+r+"')\" ":'onerror="'+e+"('"+r+"-FATAL', this)\" ";return'<script src="'+t.src+'" onload="'+e+"('"+r+"')\" "+o+"><\/script>"}).join("\n")}function y(t,e){return t.map(function(t){return'<link rel="stylesheet" href="'+t.src+'" onload="'+e+"('link')\" onerror=\""+e+"('link-FATAL', this)\" />"}).join("\n")}function g(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function m(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.escape,r=void 0===n||n,o=e.removeNull,i=void 0===o||o,s=r?encodeURIComponent:function(t){return t};return Object.keys(t).map(function(e){return i&&null==t[e]?null:s(e)+"="+s(t[e])}).filter(Boolean).join("&")}function A(){return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"").split("&").reduce(function(t,e){var n=e.split("="),r=Vt(n,2),o=r[0],i=r[1],s=void 0===i?"":i;return o?Object.assign(t,g({},decodeURIComponent(o),decodeURIComponent(s))):t},{})}function _(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function b(t){var e=t.type,n=t.category,r=t.message,o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=o.videoId;return{_ts:(new Date).toISOString(),_c:n,_t:e,cId:i,dim1:Object.keys(o).length?JSON.stringify(o):"",dim3:r}}function T(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function w(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function C(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}function k(t){var e=t.doc,n=void 0===e?document:e,r=t.target,o=t.template,i=n.getElementById(r);i&&(i.style.background="black",i.style.height="100%",i.style.overflow="hidden",i.style.padding="calc("+$t/2+"% - "+Yt/2+"px) 0px",i.style.width="100%",i.innerHTML=o)}function E(t,e){(arguments.length>2&&void 0!==arguments[2]?arguments[2]:Gt)(e),console.error("CNE Player: "+t,e,"errorData =>",e.data)}function x(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Kt;return'\n<div class="cne-error-message" style="color:white;font:'+Yt+"px/"+Yt+'px \'Open Sans\', sans-serif;text-align:center;height:100%;width:100%;" aria-live="polite">\n  <link href="http://fonts.googleapis.com/css?family=Open+Sans" rel="stylesheet" type="text/css" />\n  <h2>'+t+"</h2>\n</div>"}function S(t){return Xt({},t,{secret:null,player:null})}function j(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.buildEmbed,o=void 0===n?r:n,i=e.getAssets,s=void 0===i?l:i,a=e.iframeTemplate,c=void 0===a?f:a;return new Promise(function(e){var n=t.guid,r=t.initialPlayerConfig;r=void 0===r?{}:r;var i=r.adsDisabled,a=r.embedLocation,l=r.showPlaylistBar,u=o(n,l),h=u.iframe,p=u.wrapper,d=c({assets:s(i),embedLocation:a});e(te({},t,{iframe:h,template:d,wrapper:p}))}).catch(function(e){throw new Qt(e.message,{params:t,originalError:e})})}function P(t){var e=t.coordinator,n=t.guid,r=t.iframe,o=t.player,i=r.contentWindow,s=function t(){e.removePlayer(n),o.dispose(!0),i.removeEventListener("unload",t)};i.addEventListener("unload",s)}function O(t){var e=t.split(ne),n=ee(e,2),r=n[0];return n[1]||r}function I(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e<t.length;e++)n[e]=t[e];return n}return Array.from(t)}function M(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function N(){function t(t,e,n){var r=u,o=r.url;t._overrideAutoplay({override:n,url:o},e)}function e(e){u={guid:e,url:O(s.location.href)},l[e].setAttribute(oe,1),i(function(n,r){r!==e&&(l[r].removeAttribute(oe),n.pause(),t(n,c[r],!0))})}function n(e){l[e].removeAttribute(oe),u.guid===e&&(delete u.guid,i(function(n,r){r!==e&&t(n,c[r],!1)}))}function r(t){var e=a[t];e.isInterlude()&&p.disposePlayer(e)}function o(t){u.guid===t&&n(t),p&&r(t),delete l[t],delete c[t],delete a[t]}function i(t){Object.keys(a).forEach(function(e){t(a[e],e)})}var s=arguments.length>0&&void 0!==arguments[0]?arguments[0]:window,a={},l={},c={},u={url:O(s.location.href)},h=!1,p=void 0;return{PlayerCoordinator:function(){function r(t,e){M(this,r),h=t||!1,p=e.interludeCoordinator}return re(r,[{key:"addPlayer",value:function(r){var i=r.player,s=r.guid,h=r.secret,p=r.iframe;if(!s)return void console.error("No guid for playerCoordinator#addPlayer. Cannot add player!");a[s]=i,l[s]=p,c[s]=h,P({coordinator:this,guid:s,iframe:p,player:i}),u.guid&&(i.pause(),t(i,h,!0)),i.on(["_coordinator:play"],function(){return e(s)}),i.on(["_coordinator:pause","close-persistent"],function(){return n(s)}),i.on("dispose",function(){return o(s)})}},{key:"getPlayer",value:function(t){return console.warn("CNE Player: getPlayer will be removed in future releases."),a[t]}},{key:"removePlayer",value:function(t){o(t)}},{key:"setInterludeCoordinator",value:function(t){p=t}},{key:"currentVideoIds",value:function(){return Object.keys(a).reduce(function(t,e){var n=a[e],r=n.currentVideo()||{},o=r.id;return o?[].concat(I(t),[o]):t},[])}},{key:"canAutoplay",value:function(){return h}}]),r}(),players:a}}function R(t){var e=t.windowCne,n=t.canAutoplay,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:window;if(!e.playerCoordinator){var o=N(r),i=o.PlayerCoordinator,s=(o.players,new i(n,e));e.playerCoordinator=s}return e.playerCoordinator}function L(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:document,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:qt;e.body&&ie.test(e.readyState)?t():(n({category:"sanity",message:"Waiting for document.ready: "+e.readyState+"; body: "+!!e.body,type:"callOnDomReady"}),e.addEventListener("DOMContentLoaded",t))}function D(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:se;null!=e&&"function"==typeof e.mark&&e.mark(t)}function B(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.buildPlayerCoordinator,r=void 0===n?R:n,o=e.callOnDomReady,i=void 0===o?L:o,s=e.markPerformance,a=void 0===s?D:s;return new Promise(function(e){var n=t.canAutoplay,o=t.guid,s=t.rawConfig,l=t.secret,c=t.showPlaylistBar,u=t.theIframe,h=t.windowCne,p=t.wrapper;a("loaderjs_assets_loaded"),i(function(){var i=u.contentWindow._buildPlayer({canAutoplay:n,guid:o,rawConfig:s,secret:l,showPlaylistBar:c,wrapper:p});r({windowCne:h,canAutoplay:n}).addPlayer({player:i,guid:o,secret:l,iframe:u}),e(ae({},t,{player:i}))})}).catch(function(e){throw new Qt(e.message,{params:t,originalError:e,render:!0})})}function F(t,e){return e+'script[src*="'+t+'"]:not(.'+le+")"}function V(t,e){for(var n=t.fallbackMatcher,r=t.matcher,o=t.node,i=void 0===o?document:o,s=t.tester,a=F(r,e)+(n?", "+F(n,e):""),l=i.querySelectorAll(a),c=0,u=l.length;c<u;c++){var h=l[c];if(s.test(h.src))return h}return null}function H(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:le;return t.classList.add(e),t}function U(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.findNextAvailableScriptTag,r=void 0===n?V:n,o=e.markProcessed,i=void 0===o?H:o,s=e.track;return z(t,{findNextAvailableScriptTag:r,markProcessed:i,track:void 0===s?qt:s}).then(function(e){return ce({},t,{script:e,src:e.src})}).catch(function(e){throw new Qt(e.message,{params:t,originalError:e})})}function z(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.findNextAvailableScriptTag,r=e.markProcessed,o=e.track,i=t.inline?"":"body ";return new Promise(function(e,r){var s=n(t,i);s?e(s):setTimeout(function(){var s=n(t,i);s?(o({category:"sanity",message:"Player script found on second attempt.",type:"findScript"},t),e(s)):r(new Error("Unable to locate player script tag."))},0)}).then(r)}function W(){return ue()+ue()+"-"+ue()+"-"+ue()+"-"+ue()+"-"+ue()+ue()+ue()}function q(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function G(t){var e="((?:video|playlist))",n="([\\da-f]{24})",r="(?:\\.js)?(?:/)?\\??([^#]*)";switch(t){case"modern":return new RegExp("//.*/((?:script|inline|iframe))/"+e+"/"+n+r);case"deprecated":return new RegExp("//.*/(embed(?:js)?)/"+n+"/"+e+"/"+n+r);case"OLD":return new RegExp("//.*/(embed(?:js)?)/"+n+"/"+n+r)}}function X(t,e){var n=t.match(G("OLD"))||[],r=de(n,5),o=r[1],i=r[2],s=r[3],a=r[4];return s&&i||e(new Error(fe)),{embedType:/js/.test(o)?"script":"iframe",entityId:i,playerId:s,playerType:"video",queryString:a}}function K(t,e){var n=t.match(G("deprecated"))||[],r=de(n,6),o=r[1],i=r[2],s=r[3],a=r[4],l=r[5];return i&&a&&s?{embedType:/js/.test(o)?"script":"iframe",entityId:a,playerId:i,playerType:s,queryString:l}:X(t,e)}function Y(t,e){var n=t.match(G("modern"))||[],r=de(n,5),o=r[1],i=r[2],s=r[3],a=r[4];return o&&i&&s?{embedType:o,entityId:s,playerType:i,queryString:a}:K(t,e)}function $(t,e){var n,r=Y(t,e),o=r.embedType,i=r.entityId,s=r.playerId,a=r.playerType,l=r.queryString,c="video"===a?"videoId":"playlistId",u=A(l);return pe((n={embedType:o},q(n,c,i),q(n,"playerId",s),n),u)}function Q(){return!!me}function J(t){var e=Z(t),n=e.hostname,r=n.split("."),o=r.reverse(),i=Ae(o,3),s=i[0],a=i[1],l=i[2],c=void 0;return c=!l||a.length<s.length||_e.indexOf(a)<0?a:l,e.subdomain=n.slice(0,n.indexOf(c)),e}function Z(t){if(Q()){var e=document.createElement("a"),n=e.host,r=void 0===n?"":n,o=e.hostname,i=void 0===o?"":o,s=e.pathname,a=void 0===s?"":s,l=e.port,c=void 0===l?"":l,u=e.protocol,h=void 0===u?"":u,p=e.search;return{host:r,hostname:i,pathname:a,port:c,protocol:h,search:void 0===p?"":p}}return new URL(t)}function tt(t,e){return!("amp-article"!==t||!e)&&J(e).hostname}function et(t,e){var n=e.pageType,r=e.analyticsUrl,o=tt(n,r)||t,i=Te.exec(o);return i&&i[2]?i[1]&&i[2]?i[2]+"-videoportal":i[2]:""}function nt(t){switch(t){case"1":case"true":return!0;case"0":case"false":return!1;default:return t}}function rt(t){switch(t){case"inline":return{isScriptEmbed:!1,isIframeEmbed:!1};case"iframe":return{isScriptEmbed:!1,isIframeEmbed:!0};default:return{}}}function ot(t){var e=t.playlistId,n=t.showPlaylistBar,r=void 0===n?ke.showPlaylistBar:n;return{showPlaylistBar:!!e&&!!r}}function it(t){var e=t.loopVideo,n=t.playlistId,r=t.playerType,o=t.continuousPlay,i=void 0===o?ke.continuousPlay:o;return r?{playerType:r}:n?{playerType:"playlist"}:{playerType:"video-"+(i||e?"continuous":"single")}}function st(t){return t?{autoplay:!(xe.indexOf(t)>-1)&&null}:{}}function at(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.backendKeys,r=void 0===n?Ce:n,o=e.defaults,i=void 0===o?ke:o,s=t.embedType,a=t.playerId,l={},c=st(a);delete t.embedType,Object.keys(t).forEach(function(e){var n=nt(t[e]);r.indexOf(e)>-1&&(l[e]=n),c[e]=n});var u=we({},i,c,rt(s),Ee(c),ot(c),it(c));return{backendParams:l,initialPlayerConfig:u}}function lt(t,e){return t+"/"+je+"?"+m(e)}function ct(t,e){var n=t.playerId,r=t.embedType;n&&e({category:"deprecated",message:"Deprecated "+r+' embed with profileId: "'+n+'"',type:"deprecatedEmbed"},t)}function ut(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:qt;return new Promise(function(n,r){var o=t.apiUrl,i=t.src,s=$(i,r);ct(s,e);var a=at(s),l=a.backendParams,c=a.initialPlayerConfig,u=lt(o,l);n(Se({},t,{initialPlayerConfig:c,requestUrl:u}))}).catch(function(e){throw new Qt(e.message,{params:t,originalError:e})})}function ht(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.forceMin,n=void 0!==e&&e,r=t.win,o=void 0===r?window:r,i=o.document,s=n||!i.body?0:i.body.scrollHeight,a=Math.max(s,Pe);o.parent.postMessage({sentinel:"amp",type:"embed-size",height:a},"*")}function pt(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"html";t.parentElement;){if(t.matches(e))return t;t=t.parentElement}}function dt(t){t&&t.parentNode.removeChild(t)}function ft(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.doc,n=void 0===e?document:e,r=t.requestAmpResize,o=void 0===r?ht:r;dt(n.getElementById("interlude-container")),o({forceMin:!0})}function vt(t){dt(pt(t,"[data-cne-interlude]"))}function yt(t,e){gt("script",t,e)}function gt(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=n.callOnDomReady,o=void 0===r?L:r,i=n.errorTemplate,s=void 0===i?x:i,a=n.logEmbedError,l=void 0===a?E:a,c=n.removeInterludePlayer,u=void 0===c?vt:c,h=n.removeAmpInterludePlayer,p=void 0===h?ft:h,d=n.renderEmbedError,f=void 0===d?k:d,v=e.data||{},y=v.render,g=v.displayMessage,m=v.embedParams,A=void 0===m?{}:m,_=A.iframe,b=A.initialPlayerConfig;b=void 0===b?{}:b;var T=b.playerType,w=b.target,C=b.pageType;if(y){var S=s(g),j="script"===t?_.contentDocument:document;o(function(){_&&"interlude"===T?u(_):"interlude"===T&&"amp-article"===C?p():f({doc:j,target:w,template:S})},j)}l(g||e.message,e)}function mt(){return window._cne=window._cne||{},window._cne}function At(t){t.muted=!1;var e=t.play();return e&&"function"==typeof e.then&&"function"==typeof e.catch?e.catch(function(e){return"NotSupportedError"===e.name?Promise.reject(e):(t.muted=!0,t.play())}):Promise.resolve(!0)}function _t(t,e,n){return t.src="data:"+n+";base64,"+e,At(t)}function bt(t,e,n){for(var r=atob(e),o=new Array(r.length),i=0;i<r.length;i++)o[i]=r.charCodeAt(i);var s=new Uint8Array(o),a=new Blob([s],{type:n}),l=URL.createObjectURL(a);return t.src=l,At(t)}function Tt(){var t=document.createElement("video");return t.setAttribute("webkit-playsinline",""),t.setAttribute("playsinline",""),document.body.appendChild(t),t}function wt(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.playDataVideo,r=void 0===n?_t:n,o=e.playBlobVideo,i=void 0===o?bt:o,s=e.makeVideo,a=void 0===s?Tt:s;if(t&&t.playerCoordinator)return Promise.resolve(t.playerCoordinator.canAutoplay());var l=a(),c="AAAAHGZ0eXBpc29tAAACAGlzb21pc28ybXA0MQAAAAhmcmVlAAAC721kYXQhEAUgpBv/wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA3pwAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcCEQBSCkG//AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADengAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAcAAAAsJtb292AAAAbG12aGQAAAAAAAAAAAAAAAAAAAPoAAAALwABAAABAAAAAAAAAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAADAAAB7HRyYWsAAABcdGtoZAAAAAMAAAAAAAAAAAAAAAIAAAAAAAAALwAAAAAAAAAAAAAAAQEAAAAAAQAAAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAEAAAAAAAAAAAAAAAAAAACRlZHRzAAAAHGVsc3QAAAAAAAAAAQAAAC8AAAAAAAEAAAAAAWRtZGlhAAAAIG1kaGQAAAAAAAAAAAAAAAAAAKxEAAAIAFXEAAAAAAAtaGRscgAAAAAAAAAAc291bgAAAAAAAAAAAAAAAFNvdW5kSGFuZGxlcgAAAAEPbWluZgAAABBzbWhkAAAAAAAAAAAAAAAkZGluZgAAABxkcmVmAAAAAAAAAAEAAAAMdXJsIAAAAAEAAADTc3RibAAAAGdzdHNkAAAAAAAAAAEAAABXbXA0YQAAAAAAAAABAAAAAAAAAAAAAgAQAAAAAKxEAAAAAAAzZXNkcwAAAAADgICAIgACAASAgIAUQBUAAAAAAfQAAAHz+QWAgIACEhAGgICAAQIAAAAYc3R0cwAAAAAAAAABAAAAAgAABAAAAAAcc3RzYwAAAAAAAAABAAAAAQAAAAIAAAABAAAAHHN0c3oAAAAAAAAAAAAAAAIAAAFzAAABdAAAABRzdGNvAAAAAAAAAAEAAAAsAAAAYnVkdGEAAABabWV0YQAAAAAAAAAhaGRscgAAAAAAAAAAbWRpcmFwcGwAAAAAAAAAAAAAAAAtaWxzdAAAACWpdG9vAAAAHWRhdGEAAAABAAAAAExhdmY1Ni40MC4xMDE=";return new Promise(function(t,e){r(l,c,"video/mp4").catch(function(t){if("NotAllowedError"!==t.name)return i(l,c,"video/mp4");e(t)}).catch(function(t){return e(t)}).then(function(){return t(!0)})}).catch(function(t){return Gt({type:t.name,message:"Failed To Autoplay Video"}),!1}).then(function(t){return l&&l.parentNode&&l.parentNode.removeChild(l),t?l.muted?Oe.MUTED:Oe.ALWAYS:Oe.NEVER})}function Ct(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function kt(t){return new Promise(function(e,n){var r=new XMLHttpRequest,o=function(){return n(new TypeError("Network request failed"))},i=function(){var t={status:r.status,statusText:r.statusText,url:r.responseURL},n="response"in r?r.response:r.responseText;e(new Me(n,t))};r.onload=i,r.onerror=o,r.ontimeout=o,r.open("GET",t),r.send()})}function Et(t){return(arguments.length>1&&void 0!==arguments[1]?arguments[1]:window.fetch||kt)(t).then(function(e){if(e.ok)return e.json();var n=e.status,r=e.statusText;return e.json().then(function(e){throw new Jt("API ERROR: "+n+" ("+r+") response to "+t,{json:e,requestUrl:t})})})}function xt(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:St,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:Ne;return new Promise(function(r){if(t||document.querySelector("script[src='"+n+"']"))r();else{var o=e(n);o.onload=r,o.onerror=r,document.head.appendChild(o)}})}function St(t){var e=document.createElement("script");return e.async=!0,e.type="text/javascript",e.src=t,e}function jt(t){var e=t.eventName,n=void 0===e?Ft:e,r=t.iframe,o=t.markPerformance,i=void 0===o?D:o,s=t.script,a=t.template,l=t.wrapper;return new Promise(function(t,e){r.addEventListener(n,function(n){var r=n.target.contentWindow,o=r||{},i=o._cne,s=o._assetLoadError;if(s)return void e(new Zt("Failed to load asset.",s));i&&i.createPlayer?t(n.target):e(new Zt("Cannot create player."))}),s.parentNode.insertBefore(l,s),i("script_embed_populate_iframe"),r.contentDocument.open(),r.contentDocument.write(a),r.contentDocument.close(),i("script_embed_insert_embed_end")})}function Pt(t,e){return Re({},t,{playerConfig:Re({},e,t.playerConfig)})}function Ot(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.canAutoplay,r=void 0===n?wt:n,o=e.fetchConfig,i=void 0===o?Et:o,s=e.insertGptIframeProxy,a=void 0===s?xt:s,l=e.playerCodePromise,c=void 0===l?jt:l,u=t.iframe,h=t.requestUrl,p=t.script,d=t.template,f=t.windowCne,v=t.wrapper,y=t.initialPlayerConfig;return Promise.all([c({iframe:u,script:p,template:d,wrapper:v}),i(h),r(f),a(y.adsDisabled)]).then(function(e){var n=De(e,3),r=n[0],o=n[1],i=n[2],s=Pt(o,y),a=JSON.stringify(s);return Le({},t,{theIframe:r,rawConfig:a,canAutoplay:i})}).catch(function(e){throw new Qt(e.message,{params:t,originalError:e})})}Object.defineProperty(e,"__esModule",{value:!0});var It=function(t){return{"box-sizing":"content-box",display:"inline-block",height:t?"190px":"0px","padding-top":"56.25%",position:"relative",transition:"height 300ms ease-in-out","vertical-align":"top",width:"100%"}},Mt={height:"1px !important",left:"0px","min-height":"100%","min-width":"100%",position:"absolute",top:"0px",width:"1px !important"},Nt="cne-player-container",Rt={css:{src:"https://d2c8v52ll5s99u.cloudfront.net/player/player-style-63f19b366c5bbb1bd33c991de57a3261.css"},ima:{src:"//imasdk.googleapis.com/js/sdkloader/ima3.js",ad:!0},main:{src:"https://d2c8v52ll5s99u.cloudfront.net/player/main-4f8333e548b250c0d14e.js",ad:!1},mobile:{src:"https://d2c8v52ll5s99u.cloudfront.net/player/mobile-c848f060084fe97b7212.js",ad:!1}},Lt=new Set(["vogue"]),Dt=function(){return'<script>(function(){var n="\\x70\\x41"+"\\x50\\x49",m="\\x24\\x63"+"\\x6d\\x64",c=window[n]=function(a,b){c[m].push([a,b])},a,d=document;for(var f="",i=0;i<8;i++)f+=Math.floor(65536*(1+Math.random())).toString(16).substring(1);(f=f.split(""))[8]="e",f[2]="f",f[4]="4",f[6]="c",f[7]="a",f[21]="f",f[23]="8",f[24]="c",f[26]="6",f[28]="d",f[30]="2";i=0;"274e".split("").forEach(function(t){f[9+i]=t,i++});var g="";for(var chars="abcdefghiklmnopqrstuvwxyz",g1=0;g1<8;g1++){var rnum=Math.floor(Math.random()*chars.length);g+=chars.substring(rnum,rnum+1)}f=f.join("");g||(g="axtd");c[m]=[];a=d.createElement("script");a.src="//"+g+".rrvvorisiyf.com/"+f,(d.head||d.body).appendChild(a);})()<\/script>'},Bt="embedplayer",Ft="cne:iframe:loaded",Vt=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var s,a=t[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),Ht=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var s,a=t[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),Ut=function(){return(arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.cookie).split(/;\s*/).reduce(function(t,e){var n=e.split("="),r=Ht(n,2),o=r[0],i=r[1];return Object.assign(t,_({},o,decodeURIComponent(i)))},{})},zt=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Ut(),e=t.pID,n=void 0===e?"":e,r=t.sID,o=void 0===r?"":r,i=t.CN_sp,s=void 0===i?"":i,a=t.CN_xid,l=void 0===a?"":a,c={baseUrl:"//capture.condenastdigital.com/track?_o=cne",params:{app:"playerservice",cCh:"videos/show",pHr:window.location.href,pID:n,sID:o,uId:s,xid:l}};return function(){return c}}(),Wt=function(t){return(new(arguments.length>1&&void 0!==arguments[1]?arguments[1]:Image)).src=t},qt=function(t){var e=t.type,n=t.category,r=t.message,o=void 0===r?"":r,i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},s=zt(),a=s.baseUrl,l=s.params;return Wt([a,m(l),m(b({type:e,category:n,message:o},i))].join("&"))},Gt=function(t){var e=t.message,n=t.data,r=void 0===n?{}:n,o=t.type,i=void 0===o?"GenericError":o,s=r.embedParams;return qt({type:i,category:"error",message:e},s)},Xt=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},Kt="We're sorry, something went wrong.",Yt=18,$t=56.25,Qt=function(t){function e(t,n){var r=n.originalError,o=void 0===r?{}:r,i=n.params,s=void 0===i?{}:i,a=n.render,l=void 0!==a&&a;T(this,e);var c=w(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return c.message=t,c.data=Xt({displayMessage:void 0,embedParams:s,render:l},o.data),c.type=o.type||"EmbedError",c}return C(e,t),e}(Error),Jt=function(t){function e(t,n){var r=n.json,o=void 0===r?{}:r,i=n.requestUrl;T(this,e);var s=w(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return s.message=t,s.data={displayMessage:o.message||t,json:o,render:!0,requestUrl:i},s.type="FetchConfigError",s}return C(e,t),e}(Error),Zt=function(t){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.identifier,o=n.tag;T(this,e);var i=w(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return i.message=t,i.data={identifier:r,render:!0,tag:o},i.type="AssetLoadError",i}return C(e,t),e}(Error),te=(function(t){function e(t,n){var r=n.originalError,o=void 0===r?{}:r,i=n.params;T(this,e);var s=w(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return s.message=t,s.data=Xt({},i,o.data),s.type=o.type||"InterludeError",s}C(e,t)}(Error),function(t){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.url;T(this,e);var o=w(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return o.message=t,o.data={url:r},o.type="RecommendationApiError",o}C(e,t)}(Error),function(t){function e(t){T(this,e);var n=w(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return n.message=t,n.type="WaitForPageCreateError",n}C(e,t)}(Error),function(t){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};T(this,e);var r=w(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return r.message=t,r.data=S(n),r.type="InterludeRejectedError",r}C(e,t)}(Error),function(t){function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};T(this,e);var r=w(this,(e.__proto__||Object.getPrototypeOf(e)).call(this,t));return r.message=t,r.data=S(n),r.type="PreviousAttemptError",r}C(e,t)}(Error),Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t}),ee=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var s,a=t[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),ne=/(?:http[s]?:)?(?:\/\/)?[a-z]+\.(?:[a-z]+\.)?[^\/]+\/?|^\/|\/$|\/?\?.*$/,re=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),oe="data-cne-playing",ie=/complete|loaded|interactive/,se=function(){var t=void 0;try{t=window.top.performance}catch(e){t=window.performance}return t}(),ae=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},le="processed",ce=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},ue=function(){return Math.floor(65536*Math.random()).toString(16)},he=function(){return ue()},pe=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},de=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var s,a=t[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),fe="Unable to parse script source.",ve=n(73),ye=n.n(ve),ge=ye.a.browser||{},me=function(){var t=0;if("Microsoft Internet Explorer"==navigator.appName){var e=navigator.userAgent;null!=new RegExp("MSIE ([0-9]{1,}[.0-9]{0,})").exec(e)&&(t=parseFloat(RegExp.$1))}else if("Netscape"==navigator.appName){var n=navigator.userAgent,r=new RegExp("Trident/.*rv:([0-9]{1,}[.0-9]{0,})");null!=r.exec(n)&&(t=parseFloat(RegExp.$1))}return t}(),Ae=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var s,a=t[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}(),_e=["ac","ad","ae","aero","af","ag","ai","al","am","an","ao","aq","ar","arpa","as","asia","at","au","aw","ax","az","ba","bb","bd","be","bf","bg","bh","bi","bid","biz","bj","bm","bn","bo","br","bs","bt","bv","bw","by","bz","ca","cat","cc","cd","cf","cg","ch","ci","ck","cl","club","cm","cn","co","com","coop","cr","cu","cv","cx","cy","cz","de","dj","dk","dm","do","dz","ec","edu","ee","eg","er","es","et","eu","fi","fj","fk","fm","fo","fr","ga","gb","gd","ge","gf","gg","gh","gi","gl","gm","gn","gov","gp","gq","gr","gs","gt","gu","gw","gy","hk","hm","hn","hr","ht","hu","id","ie","il","im","in","info","int","io","iq","ir","is","it","je","jm","jo","jobs","jp","ke","kg","kh","ki","km","kn","kp","kr","kw","ky","kz","la","lb","lc","li","link","lk","lr","ls","lt","lu","lv","ly","ma","mc","md","me","mg","mh","mil","mk","ml","mm","mn","mo","mobi","mp","mq","mr","ms","mt","mu","museum","mv","mw","mx","my","mz","na","name","nc","ne","net","nf","ng","ni","nl","no","np","nr","nu","nz","om","online","org","pa","pe","pf","pg","ph","pk","pl","pm","pn","pr","pro","ps","pt","pw","py","qa","re","ro","rs","ru","rw","sa","sb","sc","sd","se","sg","sh","si","site","sj","sk","sl","sm","sn","so","sr","st","su","sv","sy","sz","tc","td","tel","tf","tg","th","tj","tk","tl","tm","tn","to","top","tp","tr","travel","tt","tv","tw","tz","ua","ug","uk","us","uy","uz","va","vc","ve","vg","vi","vip","vn","vu","wang","wf","win","ws","xn--0zwm56d","xn--11b5bs3a9aj6g","xn--3e0b707e","xn--45brj9c","xn--80akhbyknj4f","xn--90a3ac","xn--9t4b11yi5a","xn--clchc0ea0b2g2a9gcd","xn--deba0ad","xn--fiqs8s","xn--fiqz9s","xn--fpcrj9c3d","xn--fzc2c9e2c","xn--g6w251d","xn--gecrj9c","xn--h2brj9c","xn--hgbk6aj7f53bba","xn--hlcj6aya9esc7a","xn--j6w193g","xn--jxalpdlp","xn--kgbechtv","xn--kprw13d","xn--kpry57d","xn--lgbbat1ad8j","xn--mgbaam7a8h","xn--mgbayh7gpa","xn--mgbbh1a71e","xn--mgbc0a9azcg","xn--mgberp4a5d4ar","xn--o3cw4h","xn--ogbpf8fl","xn--p1ai","xn--pgbs0dh","xn--s9brj9c","xn--wgbh1c","xn--wgbl6a","xn--xkc2al3hye2a","xn--xkc2dl3a5ee0h","xn--yfro4i67o","xn--ygbi2ammx","xn--zckzah","xxx","xyz","ye","yt","za","zm","zw"].join(),be=["allure","architecturaldigest","arstechnica","bonappetit","brides","cntraveler","epicurious","glamour","golfdigest","gq","iris","newyorker","pitchfork","self","teenvogue","thescene","them","vanityfair","vogue","wired","wmagazine"],Te=new RegExp("(video)?\\.?("+be.join("|")+")"),we=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},Ce=["hasAnimatedThumb","interludeOverride","indexKey","iu","playlistId","playerType","shareToScene","theme","videoId"],ke={adsDisabled:!1,analyticsUrl:null,aoTest:null,autoplay:!0,companionSize:"300x60",companionTarget:null,continuousPlay:!0,doova:!0,embedLocation:"",forceMobile:!1,hasAnimatedThumb:!0,hasCompanion:!0,hideHoverTitle:!1,hidePosterTitle:!1,interludeOverride:null,indexKey:null,iu:null,loopVideo:!1,muted:!1,onReady:null,pageType:"",playerType:null,playlistId:null,recAlgorithm:null,recStrategy:null,section:null,shareToScene:!1,showPlaylistBar:!0,subSection:null,target:Bt,theme:"dark",videoId:null,isScriptEmbed:!0,isIframeEmbed:!1},Ee=function(t){return{embedLocation:et(window.location.hostname,t)}},xe=["5609731161646d168700000b","561eb5ce61646d732a000007","56214e9761646d59df000017","56674971ff2afb42b100001a"],Se=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},je="embed-api.json",Pe=100,Oe={ALWAYS:"ALWAYS",MUTED:"MUTED",NEVER:"NEVER"},Ie=function(){function t(t,e){for(var n=0;n<e.length;n++){var r=e[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,n,r){return n&&t(e.prototype,n),r&&t(e,r),e}}(),Me=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Ct(this,t),this.status=void 0===n.status?200:n.status,this.ok=this.status>=200&&this.status<300,this.statusText="statusText"in n?n.statusText:"OK",this.url=n.url||"",this._bodyText=e}return Ie(t,[{key:"text",value:function(){return Promise.resolve(this._bodyText)}},{key:"json",value:function(){return this.text().then(JSON.parse)}}]),t}(),Ne="//imasdk.googleapis.com/js/sdkloader/gpt_proxy.js",Re=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},Le=Object.assign||function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},De=function(){function t(t,e){var n=[],r=!0,o=!1,i=void 0;try{for(var s,a=t[Symbol.iterator]();!(r=(s=a.next()).done)&&(n.push(s.value),!e||n.length!==e);r=!0);}catch(t){o=!0,i=t}finally{try{!r&&a.return&&a.return()}finally{if(o)throw i}}return n}return function(e,n){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return t(e,n);throw new TypeError("Invalid attempt to destructure non-iterable instance")}}();D("player_js_start_execution");var Be=/cnevids/;D("script_embed_loaded"),function(t){var e=t.apiUrl,n=t.buildEmbedPieces,r=t.buildScriptPlayer,o=t.fallbackMatcher,i=t.findScript,s=t.generateGuid,a=t.generateSecret,l=t.getEnvironmentFromSrc,c=t.handleScriptEmbedError,u=t.initWindowCne,h=t.insertScriptEmbed,p=t.markPerformance,d=t.matcher,f=t.tester;p("loaderjs_loaded"),Promise.resolve({apiUrl:e,fallbackMatcher:o,guid:s(),matcher:d,secret:a(),tester:f,windowCne:u()}).then(i).then(l).then(n).then(h).then(r).catch(c)}({apiUrl:"//player.cnevids.com",buildEmbedPieces:j,buildScriptPlayer:B,fallbackMatcher:"/embedjs/",findScript:U,generateGuid:W,generateSecret:he,getEnvironmentFromSrc:ut,handleScriptEmbedError:yt,initWindowCne:mt,insertScriptEmbed:Ot,markPerformance:D,matcher:"/script/",tester:Be})},function(t,e,n){/**
 * @license
 * Video.js 6.6.0 <http://videojs.com/>
 * Copyright Brightcove, Inc. <https://www.brightcove.com/>
 * Available under Apache License Version 2.0
 * <https://github.com/videojs/video.js/blob/master/LICENSE>
 *
 * Includes vtt.js <https://github.com/mozilla/vtt.js>
 * Available under Apache License Version 2.0
 * <https://github.com/mozilla/vtt.js/blob/master/LICENSE>
 */
function r(t){return t&&"object"==typeof t&&"default"in t?t.default:t}function o(t,e){le(t).forEach(function(n){return e(t[n],n)})}function i(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;return le(t).reduce(function(n,r){return e(n,t[r],r)},n)}function s(t){for(var e=arguments.length,n=Array(e>1?e-1:0),r=1;r<e;r++)n[r-1]=arguments[r];return Object.assign?Object.assign.apply(Object,[t].concat(n)):(n.forEach(function(e){e&&o(e,function(e,n){t[n]=e})}),t)}function a(t){return!!t&&"object"===(void 0===t?"undefined":ne(t))}function l(t){return a(t)&&"[object Object]"===ae.call(t)&&t.constructor===Object}function c(t,e){if(!t||!e)return"";if("function"==typeof Et.getComputedStyle){var n=Et.getComputedStyle(t);return n?n[e]:""}return t.currentStyle[e]||""}function u(t){return"string"==typeof t&&/\S/.test(t)}function h(t){if(/\s/.test(t))throw new Error("class has illegal whitespace characters")}function p(t){return new RegExp("(^|\\s)"+t+"($|\\s)")}function d(){return xt===Et.document&&void 0!==xt.createElement}function f(t){return a(t)&&1===t.nodeType}function v(){try{return Et.parent!==Et.self}catch(t){return!0}}function y(t){return function(e,n){if(!u(e))return xt[t](null);u(n)&&(n=xt.querySelector(n));var r=f(n)?n:xt;return r[t]&&r[t](e)}}function g(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"div",e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=arguments[3],o=xt.createElement(t);return Object.getOwnPropertyNames(e).forEach(function(t){var n=e[t];-1!==t.indexOf("aria-")||"role"===t||"type"===t?(de.warn(St(fe,t,n)),o.setAttribute(t,n)):"textContent"===t?m(o,n):o[t]=n}),Object.getOwnPropertyNames(n).forEach(function(t){o.setAttribute(t,n[t])}),r&&D(o,r),o}function m(t,e){return void 0===t.textContent?t.innerText=e:t.textContent=e,t}function A(t,e){e.firstChild?e.insertBefore(t,e.firstChild):e.appendChild(t)}function _(t,e){return h(e),t.classList?t.classList.contains(e):p(e).test(t.className)}function b(t,e){return t.classList?t.classList.add(e):_(t,e)||(t.className=(t.className+" "+e).trim()),t}function T(t,e){return t.classList?t.classList.remove(e):(h(e),t.className=t.className.split(/\s+/).filter(function(t){return t!==e}).join(" ")),t}function w(t,e,n){var r=_(t,e);if("function"==typeof n&&(n=n(t,e)),"boolean"!=typeof n&&(n=!r),n!==r)return n?b(t,e):T(t,e),t}function C(t,e){Object.getOwnPropertyNames(e).forEach(function(n){var r=e[n];null===r||void 0===r||!1===r?t.removeAttribute(n):t.setAttribute(n,!0===r?"":r)})}function k(t){var e={};if(t&&t.attributes&&t.attributes.length>0)for(var n=t.attributes,r=n.length-1;r>=0;r--){var o=n[r].name,i=n[r].value;"boolean"!=typeof t[o]&&-1===",autoplay,controls,playsinline,loop,muted,default,defaultMuted,".indexOf(","+o+",")||(i=null!==i),e[o]=i}return e}function E(t,e){return t.getAttribute(e)}function x(t,e,n){t.setAttribute(e,n)}function S(t,e){t.removeAttribute(e)}function j(){xt.body.focus(),xt.onselectstart=function(){return!1}}function P(){xt.onselectstart=function(){return!0}}function O(t){if(t&&t.getBoundingClientRect&&t.parentNode){var e=t.getBoundingClientRect(),n={};return["bottom","height","left","right","top","width"].forEach(function(t){void 0!==e[t]&&(n[t]=e[t])}),n.height||(n.height=parseFloat(c(t,"height"))),n.width||(n.width=parseFloat(c(t,"width"))),n}}function I(t){var e=void 0;if(t.getBoundingClientRect&&t.parentNode&&(e=t.getBoundingClientRect()),!e)return{left:0,top:0};var n=xt.documentElement,r=xt.body,o=n.clientLeft||r.clientLeft||0,i=Et.pageXOffset||r.scrollLeft,s=e.left+i-o,a=n.clientTop||r.clientTop||0,l=Et.pageYOffset||r.scrollTop,c=e.top+l-a;return{left:Math.round(s),top:Math.round(c)}}function M(t,e){var n={},r=I(t),o=t.offsetWidth,i=t.offsetHeight,s=r.top,a=r.left,l=e.pageY,c=e.pageX;return e.changedTouches&&(c=e.changedTouches[0].pageX,l=e.changedTouches[0].pageY),n.y=Math.max(0,Math.min(1,(s-l+i)/i)),n.x=Math.max(0,Math.min(1,(c-a)/o)),n}function N(t){return a(t)&&3===t.nodeType}function R(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}function L(t){return"function"==typeof t&&(t=t()),(Array.isArray(t)?t:[t]).map(function(t){return"function"==typeof t&&(t=t()),f(t)||N(t)?t:"string"==typeof t&&/\S/.test(t)?xt.createTextNode(t):void 0}).filter(function(t){return t})}function D(t,e){return L(e).forEach(function(e){return t.appendChild(e)}),t}function B(t,e){return D(R(t),e)}function F(t){return void 0===t.button&&void 0===t.buttons||(0===t.button&&void 0===t.buttons||(9===$t||0===t.button&&1===t.buttons))}function V(){return me++}function H(t){var e=t[_e];return e||(e=t[_e]=V()),Ae[e]||(Ae[e]={}),Ae[e]}function U(t){var e=t[_e];return!!e&&!!Object.getOwnPropertyNames(Ae[e]).length}function z(t){var e=t[_e];if(e){delete Ae[e];try{delete t[_e]}catch(e){t.removeAttribute?t.removeAttribute(_e):t[_e]=null}}}function W(t,e){var n=H(t);0===n.handlers[e].length&&(delete n.handlers[e],t.removeEventListener?t.removeEventListener(e,n.dispatcher,!1):t.detachEvent&&t.detachEvent("on"+e,n.dispatcher)),Object.getOwnPropertyNames(n.handlers).length<=0&&(delete n.handlers,delete n.dispatcher,delete n.disabled),0===Object.getOwnPropertyNames(n).length&&z(t)}function q(t,e,n,r){n.forEach(function(n){t(e,n,r)})}function G(t){function e(){return!0}function n(){return!1}if(!t||!t.isPropagationStopped){var r=t||Et.event;t={};for(var o in r)"layerX"!==o&&"layerY"!==o&&"keyLocation"!==o&&"webkitMovementX"!==o&&"webkitMovementY"!==o&&("returnValue"===o&&r.preventDefault||(t[o]=r[o]));if(t.target||(t.target=t.srcElement||xt),t.relatedTarget||(t.relatedTarget=t.fromElement===t.target?t.toElement:t.fromElement),t.preventDefault=function(){r.preventDefault&&r.preventDefault(),t.returnValue=!1,r.returnValue=!1,t.defaultPrevented=!0},t.defaultPrevented=!1,t.stopPropagation=function(){r.stopPropagation&&r.stopPropagation(),t.cancelBubble=!0,r.cancelBubble=!0,t.isPropagationStopped=e},t.isPropagationStopped=n,t.stopImmediatePropagation=function(){r.stopImmediatePropagation&&r.stopImmediatePropagation(),t.isImmediatePropagationStopped=e,t.stopPropagation()},t.isImmediatePropagationStopped=n,null!==t.clientX&&void 0!==t.clientX){var i=xt.documentElement,s=xt.body;t.pageX=t.clientX+(i&&i.scrollLeft||s&&s.scrollLeft||0)-(i&&i.clientLeft||s&&s.clientLeft||0),t.pageY=t.clientY+(i&&i.scrollTop||s&&s.scrollTop||0)-(i&&i.clientTop||s&&s.clientTop||0)}t.which=t.charCode||t.keyCode,null!==t.button&&void 0!==t.button&&(t.button=1&t.button?0:4&t.button?1:2&t.button?2:0)}return t}function X(t,e,n){if(Array.isArray(e))return q(X,t,e,n);var r=H(t);if(r.handlers||(r.handlers={}),r.handlers[e]||(r.handlers[e]=[]),n.guid||(n.guid=V()),r.handlers[e].push(n),r.dispatcher||(r.disabled=!1,r.dispatcher=function(e,n){if(!r.disabled){e=G(e);var o=r.handlers[e.type];if(o)for(var i=o.slice(0),s=0,a=i.length;s<a&&!e.isImmediatePropagationStopped();s++)try{i[s].call(t,e,n)}catch(t){de.error(t)}}}),1===r.handlers[e].length)if(t.addEventListener){var o=!1;be&&Te.indexOf(e)>-1&&(o={passive:!0}),t.addEventListener(e,r.dispatcher,o)}else t.attachEvent&&t.attachEvent("on"+e,r.dispatcher)}function K(t,e,n){if(U(t)){var r=H(t);if(r.handlers){if(Array.isArray(e))return q(K,t,e,n);var o=function(t,e){r.handlers[e]=[],W(t,e)};if(void 0!==e){var i=r.handlers[e];if(i){if(!n)return void o(t,e);if(n.guid)for(var s=0;s<i.length;s++)i[s].guid===n.guid&&i.splice(s--,1);W(t,e)}}else for(var a in r.handlers)Object.prototype.hasOwnProperty.call(r.handlers||{},a)&&o(t,a)}}}function Y(t,e,n){var r=U(t)?H(t):{},o=t.parentNode||t.ownerDocument;if("string"==typeof e&&(e={type:e,target:t}),e=G(e),r.dispatcher&&r.dispatcher.call(t,e,n),o&&!e.isPropagationStopped()&&!0===e.bubbles)Y.call(null,o,e,n);else if(!o&&!e.defaultPrevented){var i=H(e.target);e.target[e.type]&&(i.disabled=!0,"function"==typeof e.target[e.type]&&e.target[e.type](),i.disabled=!1)}return!e.defaultPrevented}function $(t,e,n){if(Array.isArray(e))return q($,t,e,n);var r=function r(){K(t,e,r),n.apply(this,arguments)};r.guid=n.guid=n.guid||V(),X(t,e,r)}function Q(t,e){e&&(ke=e),Et.setTimeout(Ee,t)}function J(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.eventBusKey;if(n){if(!t[n].nodeName)throw new Error('The eventBusKey "'+n+'" does not refer to an element.');t.eventBusEl_=t[n]}else t.eventBusEl_=g("span",{className:"vjs-event-bus"});return s(t,Fe),t.on("dispose",function(){t.off(),Et.setTimeout(function(){t.eventBusEl_=null},0)}),t}function Z(t,e){return s(t,Ve),t.state=s({},t.state,e),"function"==typeof t.handleStateChanged&&Ie(t)&&t.on("statechanged",t.handleStateChanged),t}function tt(t){return"string"!=typeof t?t:t.charAt(0).toUpperCase()+t.slice(1)}function et(t,e){return tt(t)===tt(e)}function nt(){for(var t={},e=arguments.length,n=Array(e),r=0;r<e;r++)n[r]=arguments[r];return n.forEach(function(e){e&&o(e,function(e,n){if(!l(e))return void(t[n]=e);l(t[n])||(t[n]={}),t[n]=nt(t[n],e)})}),t}function rt(t,e,n){if("number"!=typeof e||e<0||e>n)throw new Error("Failed to execute '"+t+"' on 'TimeRanges': The index provided ("+e+") is non-numeric or out of bounds (0-"+n+").")}function ot(t,e,n,r){return rt(t,r,n.length-1),n[r][e]}function it(t){return void 0===t||0===t.length?{length:0,start:function(){throw new Error("This TimeRanges object is empty")},end:function(){throw new Error("This TimeRanges object is empty")}}:{length:t.length,start:ot.bind(null,"start",0,t),end:ot.bind(null,"end",1,t)}}function st(t,e){return Array.isArray(t)?it(t):void 0===t||void 0===e?it():it([[t,e]])}function at(t,e){var n=0,r=void 0,o=void 0;if(!e)return 0;t&&t.length||(t=st(0,0));for(var i=0;i<t.length;i++)r=t.start(i),o=t.end(i),o>e&&(o=e),n+=o-r;return n/e}function lt(t){if(t instanceof lt)return t;"number"==typeof t?this.code=t:"string"==typeof t?this.message=t:a(t)&&("number"==typeof t.code&&(this.code=t.code),s(this,t)),this.message||(this.message=lt.defaultMessages[this.code]||"")}function ct(t){return void 0!==t&&"function"==typeof t.then}function ut(t){ct(t)&&t.then(null,function(t){})}function ht(t,e,n,r){var o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},i=t.textTracks();o.kind=e,n&&(o.label=n),r&&(o.language=r),o.tech=t;var s=new On.text.TrackClass(o);return i.addTrack(s),s}function pt(t,e){Mn[t]=Mn[t]||[],Mn[t].push(e)}function dt(t,e,n){t.setTimeout(function(){return mt(e,Mn[e.type],n,t)},1)}function ft(t,e){t.forEach(function(t){return t.setTech&&t.setTech(e)})}function vt(t,e,n){return t.reduceRight(gt(n),e[n]())}function yt(t,e,n,r){return e[n](t.reduce(gt(n),r))}function gt(t){return function(e,n){return n[t]?n[t](e):e}}function mt(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments[2],r=arguments[3],o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:[],i=arguments.length>5&&void 0!==arguments[5]&&arguments[5],a=e[0],l=e.slice(1);if("string"==typeof a)mt(t,Mn[a],n,r,o,i);else if(a){var c=a(r);c.setSource(s({},t),function(e,s){if(e)return mt(t,l,n,r,o,i);o.push(c),mt(s,t.type===s.type?l:Mn[s.type],n,r,o,i)})}else l.length?mt(t,l,n,r,o,i):i?n(t,o):mt(t,Mn["*"],n,r,o,!0)}function At(t,e){return"rgba("+parseInt(t[1]+t[1],16)+","+parseInt(t[2]+t[2],16)+","+parseInt(t[3]+t[3],16)+","+e+")"}function _t(t,e,n){try{t.style[e]=n}catch(t){return}}function bt(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:t;t=t<0?0:t;var n=Math.floor(t%60),r=Math.floor(t/60%60),o=Math.floor(t/3600),i=Math.floor(e/60%60),s=Math.floor(e/3600);return(isNaN(t)||t===1/0)&&(o=r=n="-"),o=o>0||s>0?o+":":"",r=((o||i>=10)&&r<10?"0"+r:r)+":",n=n<10?"0"+n:n,o+r+n}function Tt(t,e){if(e&&(t=e(t)),t&&"none"!==t)return t}function wt(t,e){return Tt(t.options[t.options.selectedIndex].value,e)}function Ct(t,e,n){if(e)for(var r=0;r<t.options.length;r++)if(Tt(t.options[r].value,n)===e){t.selectedIndex=r;break}}function kt(t,e,n){var r=void 0;if("string"==typeof t){var o=kt.getPlayers();if(0===t.indexOf("#")&&(t=t.slice(1)),o[t])return e&&de.warn('Player "'+t+'" is already initialised. Options will not be applied.'),n&&o[t].ready(n),o[t];r=ve("#"+t)}else r=t;if(!r||!r.nodeName)throw new TypeError("The element or ID supplied is not valid. (videojs)");if(r.player||oo.players[r.playerId])return r.player||oo.players[r.playerId];f(r)&&!xt.body.contains(r)&&de.warn("The element supplied is not included in the DOM"),e=e||{},kt.hooks("beforesetup").forEach(function(t){var n=t(r,nt(e));if(!a(n)||Array.isArray(n))return void de.error("please return an object in beforesetup hooks");e=nt(e,n)});var i=He.getComponent("Player"),s=new i(r,e,n);return kt.hooks("setup").forEach(function(t){return t(s)}),s}var Et=r(n(74)),xt=r(n(75)),St=r(n(77)),jt=r(n(78)),Pt=r(n(79)),Ot=r(n(85)),It="6.6.0",Mt=Et.navigator&&Et.navigator.userAgent||"",Nt=/AppleWebKit\/([\d.]+)/i.exec(Mt),Rt=Nt?parseFloat(Nt.pop()):null,Lt=/iPad/i.test(Mt),Dt=/iPhone/i.test(Mt)&&!Lt,Bt=/iPod/i.test(Mt),Ft=Dt||Lt||Bt,Vt=function(){var t=Mt.match(/OS (\d+)_/i);return t&&t[1]?t[1]:null}(),Ht=/Android/i.test(Mt),Ut=function(){var t=Mt.match(/Android (\d+)(?:\.(\d+))?(?:\.(\d+))*/i);if(!t)return null;var e=t[1]&&parseFloat(t[1]),n=t[2]&&parseFloat(t[2]);return e&&n?parseFloat(t[1]+"."+t[2]):e||null}(),zt=Ht&&/webkit/i.test(Mt)&&Ut<2.3,Wt=Ht&&Ut<5&&Rt<537,qt=/Firefox/i.test(Mt),Gt=/Edge/i.test(Mt),Xt=!Gt&&/Chrome/i.test(Mt),Kt=function(){var t=Mt.match(/Chrome\/(\d+)/);return t&&t[1]?parseFloat(t[1]):null}(),Yt=/MSIE\s8\.0/.test(Mt),$t=function(){var t=/MSIE\s(\d+)\.\d/.exec(Mt),e=t&&parseFloat(t[1]);return!e&&/Trident\/7.0/i.test(Mt)&&/rv:11.0/.test(Mt)&&(e=11),e}(),Qt=/Safari/i.test(Mt)&&!Xt&&!Ht&&!Gt,Jt=Qt||Ft,Zt=d()&&("ontouchstart"in Et||Et.DocumentTouch&&Et.document instanceof Et.DocumentTouch),te=d()&&"backgroundSize"in Et.document.createElement("video").style,ee=(Object.freeze||Object)({IS_IPAD:Lt,IS_IPHONE:Dt,IS_IPOD:Bt,IS_IOS:Ft,IOS_VERSION:Vt,IS_ANDROID:Ht,ANDROID_VERSION:Ut,IS_OLD_ANDROID:zt,IS_NATIVE_ANDROID:Wt,IS_FIREFOX:qt,IS_EDGE:Gt,IS_CHROME:Xt,CHROME_VERSION:Kt,IS_IE8:Yt,IE_VERSION:$t,IS_SAFARI:Qt,IS_ANY_SAFARI:Jt,TOUCH_ENABLED:Zt,BACKGROUND_SIZE_SUPPORTED:te}),ne="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},re=function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")},oe=function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)},ie=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e},se=function(t,e){return t.raw=e,t},ae=Object.prototype.toString,le=function(t){return a(t)?Object.keys(t):[]},ce=void 0,ue="info",he=[],pe=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:!!$t&&$t<11,r=ce.levels[ue],o=new RegExp("^("+r+")$");if("log"!==t&&e.unshift(t.toUpperCase()+":"),he&&he.push([].concat(e)),e.unshift("VIDEOJS:"),Et.console){var i=Et.console[t];i||"debug"!==t||(i=Et.console.info||Et.console.log),i&&r&&o.test(t)&&(n&&(e=e.map(function(t){if(a(t)||Array.isArray(t))try{return JSON.stringify(t)}catch(e){return String(t)}return String(t)}).join(" ")),i.apply?i[Array.isArray(e)?"apply":"call"](Et.console,e):i(e))}};ce=function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];pe("log",e)},ce.levels={all:"debug|log|warn|error",off:"",debug:"debug|log|warn|error",info:"log|warn|error",warn:"warn|error",error:"error",DEFAULT:ue},ce.level=function(t){if("string"==typeof t){if(!ce.levels.hasOwnProperty(t))throw new Error('"'+t+'" in not a valid log level');ue=t}return ue},ce.history=function(){return he?[].concat(he):[]},ce.history.clear=function(){he&&(he.length=0)},ce.history.disable=function(){null!==he&&(he.length=0,he=null)},ce.history.enable=function(){null===he&&(he=[])},ce.error=function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];return pe("error",e)},ce.warn=function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];return pe("warn",e)},ce.debug=function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];return pe("debug",e)};var de=ce,fe=se(["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 ","."],["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 ","."]),ve=y("querySelector"),ye=y("querySelectorAll"),ge=(Object.freeze||Object)({isReal:d,isEl:f,isInFrame:v,createEl:g,textContent:m,prependTo:A,hasClass:_,addClass:b,removeClass:T,toggleClass:w,setAttributes:C,getAttributes:k,getAttribute:E,setAttribute:x,removeAttribute:S,blockTextSelection:j,unblockTextSelection:P,getBoundingClientRect:O,findPosition:I,getPointerPosition:M,isTextNode:N,emptyEl:R,normalizeContent:L,appendContent:D,insertContent:B,isSingleLeftClick:F,$:ve,$$:ye}),me=1,Ae={},_e="vdata"+(new Date).getTime(),be=!1;!function(){try{var t=Object.defineProperty({},"passive",{get:function(){be=!0}});Et.addEventListener("test",null,t),Et.removeEventListener("test",null,t)}catch(t){}}();var Te=["touchstart","touchmove"],we=(Object.freeze||Object)({fixEvent:G,on:X,off:K,trigger:Y,one:$}),Ce=!1,ke=void 0,Ee=function(){if(d()){var t=xt.getElementsByTagName("video"),e=xt.getElementsByTagName("audio"),n=xt.getElementsByTagName("video-js"),r=[];if(t&&t.length>0)for(var o=0,i=t.length;o<i;o++)r.push(t[o]);if(e&&e.length>0)for(var s=0,a=e.length;s<a;s++)r.push(e[s]);if(n&&n.length>0)for(var l=0,c=n.length;l<c;l++)r.push(n[l]);if(r&&r.length>0)for(var u=0,h=r.length;u<h;u++){var p=r[u];if(!p||!p.getAttribute){Q(1);break}if(void 0===p.player){var f=p.getAttribute("data-setup");null!==f&&ke(p)}}else Ce||Q(1)}};d()&&"complete"===xt.readyState?Ce=!0:$(Et,"load",function(){Ce=!0});var xe=function(t){var e=xt.createElement("style");return e.className=t,e},Se=function(t,e){t.styleSheet?t.styleSheet.cssText=e:t.textContent=e},je=function(t,e,n){e.guid||(e.guid=V());var r=function(){return e.apply(t,arguments)};return r.guid=n?n+"_"+e.guid:e.guid,r},Pe=function(t,e){var n=Date.now();return function(){var r=Date.now();r-n>=e&&(t.apply(void 0,arguments),n=r)}},Oe=function(){};Oe.prototype.allowedEvents_={},Oe.prototype.on=function(t,e){var n=this.addEventListener;this.addEventListener=function(){},X(this,t,e),this.addEventListener=n},Oe.prototype.addEventListener=Oe.prototype.on,Oe.prototype.off=function(t,e){K(this,t,e)},Oe.prototype.removeEventListener=Oe.prototype.off,Oe.prototype.one=function(t,e){var n=this.addEventListener;this.addEventListener=function(){},$(this,t,e),this.addEventListener=n},Oe.prototype.trigger=function(t){var e=t.type||t;"string"==typeof t&&(t={type:e}),t=G(t),this.allowedEvents_[e]&&this["on"+e]&&this["on"+e](t),Y(this,t)},Oe.prototype.dispatchEvent=Oe.prototype.trigger;var Ie=function(t){return t instanceof Oe||!!t.eventBusEl_&&["on","one","off","trigger"].every(function(e){return"function"==typeof t[e]})},Me=function(t){return"string"==typeof t&&/\S/.test(t)||Array.isArray(t)&&!!t.length},Ne=function(t){if(!t.nodeName&&!Ie(t))throw new Error("Invalid target; must be a DOM node or evented object.")},Re=function(t){if(!Me(t))throw new Error("Invalid event type; must be a non-empty string or array.")},Le=function(t){if("function"!=typeof t)throw new Error("Invalid listener; must be a function.")},De=function(t,e){var n=e.length<3||e[0]===t||e[0]===t.eventBusEl_,r=void 0,o=void 0,i=void 0;return n?(r=t.eventBusEl_,e.length>=3&&e.shift(),o=e[0],i=e[1]):(r=e[0],o=e[1],i=e[2]),Ne(r),Re(o),Le(i),i=je(t,i),{isTargetingSelf:n,target:r,type:o,listener:i}},Be=function(t,e,n,r){Ne(t),t.nodeName?we[e](t,n,r):t[e](n,r)},Fe={on:function(){for(var t=this,e=arguments.length,n=Array(e),r=0;r<e;r++)n[r]=arguments[r];var o=De(this,n),i=o.isTargetingSelf,s=o.target,a=o.type,l=o.listener;if(Be(s,"on",a,l),!i){var c=function(){return t.off(s,a,l)};c.guid=l.guid;var u=function(){return t.off("dispose",c)};u.guid=l.guid,Be(this,"on","dispose",c),Be(s,"on","dispose",u)}},one:function(){for(var t=this,e=arguments.length,n=Array(e),r=0;r<e;r++)n[r]=arguments[r];var o=De(this,n),i=o.isTargetingSelf,s=o.target,a=o.type,l=o.listener;if(i)Be(s,"one",a,l);else{var c=function e(){for(var n=arguments.length,r=Array(n),o=0;o<n;o++)r[o]=arguments[o];t.off(s,a,e),l.apply(null,r)};c.guid=l.guid,Be(s,"one",a,c)}},off:function(t,e,n){if(!t||Me(t))K(this.eventBusEl_,t,e);else{var r=t,o=e;Ne(r),Re(o),Le(n),n=je(this,n),this.off("dispose",n),r.nodeName?(K(r,o,n),K(r,"dispose",n)):Ie(r)&&(r.off(o,n),r.off("dispose",n))}},trigger:function(t,e){return Y(this.eventBusEl_,t,e)}},Ve={state:{},setState:function(t){var e=this;"function"==typeof t&&(t=t());var n=void 0;return o(t,function(t,r){e.state[r]!==t&&(n=n||{},n[r]={from:e.state[r],to:t}),e.state[r]=t}),n&&Ie(this)&&this.trigger({changes:n,type:"statechanged"}),n}},He=function(){function t(e,n,r){if(re(this,t),!e&&this.play?this.player_=e=this:this.player_=e,this.options_=nt({},this.options_),n=this.options_=nt(this.options_,n),this.id_=n.id||n.el&&n.el.id,!this.id_){var o=e&&e.id&&e.id()||"no_player";this.id_=o+"_component_"+V()}this.name_=n.name||null,n.el?this.el_=n.el:!1!==n.createEl&&(this.el_=this.createEl()),!1!==n.evented&&J(this,{eventBusKey:this.el_?"el_":null}),Z(this,this.constructor.defaultState),this.children_=[],this.childIndex_={},this.childNameIndex_={},!1!==n.initChildren&&this.initChildren(),this.ready(r),!1!==n.reportTouchActivity&&this.enableTouchActivity()}return t.prototype.dispose=function(){if(this.trigger({type:"dispose",bubbles:!1}),this.children_)for(var t=this.children_.length-1;t>=0;t--)this.children_[t].dispose&&this.children_[t].dispose();this.children_=null,this.childIndex_=null,this.childNameIndex_=null,this.el_&&(this.el_.parentNode&&this.el_.parentNode.removeChild(this.el_),z(this.el_),this.el_=null),this.player_=null},t.prototype.player=function(){return this.player_},t.prototype.options=function(t){return de.warn("this.options() has been deprecated and will be moved to the constructor in 6.0"),t?(this.options_=nt(this.options_,t),this.options_):this.options_},t.prototype.el=function(){return this.el_},t.prototype.createEl=function(t,e,n){return g(t,e,n)},t.prototype.localize=function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t,r=this.player_.language&&this.player_.language(),o=this.player_.languages&&this.player_.languages(),i=o&&o[r],s=r&&r.split("-")[0],a=o&&o[s],l=n;return i&&i[t]?l=i[t]:a&&a[t]&&(l=a[t]),e&&(l=l.replace(/\{(\d+)\}/g,function(t,n){var r=e[n-1],o=r;return void 0===r&&(o=t),o})),l},t.prototype.contentEl=function(){return this.contentEl_||this.el_},t.prototype.id=function(){return this.id_},t.prototype.name=function(){return this.name_},t.prototype.children=function(){return this.children_},t.prototype.getChildById=function(t){return this.childIndex_[t]},t.prototype.getChild=function(t){if(t)return t=tt(t),this.childNameIndex_[t]},t.prototype.addChild=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:this.children_.length,o=void 0,i=void 0;if("string"==typeof e){i=tt(e);var s=n.componentClass||i;n.name=i;var a=t.getComponent(s);if(!a)throw new Error("Component "+s+" does not exist");if("function"!=typeof a)return null;o=new a(this.player_||this,n)}else o=e;if(this.children_.splice(r,0,o),"function"==typeof o.id&&(this.childIndex_[o.id()]=o),i=i||o.name&&tt(o.name()),i&&(this.childNameIndex_[i]=o),"function"==typeof o.el&&o.el()){var l=this.contentEl().children,c=l[r]||null;this.contentEl().insertBefore(o.el(),c)}return o},t.prototype.removeChild=function(t){if("string"==typeof t&&(t=this.getChild(t)),t&&this.children_){for(var e=!1,n=this.children_.length-1;n>=0;n--)if(this.children_[n]===t){e=!0,this.children_.splice(n,1);break}if(e){this.childIndex_[t.id()]=null,this.childNameIndex_[t.name()]=null;var r=t.el();r&&r.parentNode===this.contentEl()&&this.contentEl().removeChild(t.el())}}},t.prototype.initChildren=function(){var e=this,n=this.options_.children;if(n){var r=this.options_,o=function(t){var n=t.name,o=t.opts;if(void 0!==r[n]&&(o=r[n]),!1!==o){!0===o&&(o={}),o.playerOptions=e.options_.playerOptions;var i=e.addChild(n,o);i&&(e[n]=i)}},i=void 0,s=t.getComponent("Tech");i=Array.isArray(n)?n:Object.keys(n),i.concat(Object.keys(this.options_).filter(function(t){return!i.some(function(e){return"string"==typeof e?t===e:t===e.name})})).map(function(t){var r=void 0,o=void 0;return"string"==typeof t?(r=t,o=n[r]||e.options_[r]||{}):(r=t.name,o=t),{name:r,opts:o}}).filter(function(e){var n=t.getComponent(e.opts.componentClass||tt(e.name));return n&&!s.isTech(n)}).forEach(o)}},t.prototype.buildCSSClass=function(){return""},t.prototype.ready=function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(t)return this.isReady_?void(e?t.call(this):this.setTimeout(t,1)):(this.readyQueue_=this.readyQueue_||[],void this.readyQueue_.push(t))},t.prototype.triggerReady=function(){this.isReady_=!0,this.setTimeout(function(){var t=this.readyQueue_;this.readyQueue_=[],t&&t.length>0&&t.forEach(function(t){t.call(this)},this),this.trigger("ready")},1)},t.prototype.$=function(t,e){return ve(t,e||this.contentEl())},t.prototype.$$=function(t,e){return ye(t,e||this.contentEl())},t.prototype.hasClass=function(t){return _(this.el_,t)},t.prototype.addClass=function(t){b(this.el_,t)},t.prototype.removeClass=function(t){T(this.el_,t)},t.prototype.toggleClass=function(t,e){w(this.el_,t,e)},t.prototype.show=function(){this.removeClass("vjs-hidden")},t.prototype.hide=function(){this.addClass("vjs-hidden")},t.prototype.lockShowing=function(){this.addClass("vjs-lock-showing")},t.prototype.unlockShowing=function(){this.removeClass("vjs-lock-showing")},t.prototype.getAttribute=function(t){return E(this.el_,t)},t.prototype.setAttribute=function(t,e){x(this.el_,t,e)},t.prototype.removeAttribute=function(t){S(this.el_,t)},t.prototype.width=function(t,e){return this.dimension("width",t,e)},t.prototype.height=function(t,e){return this.dimension("height",t,e)},t.prototype.dimensions=function(t,e){this.width(t,!0),this.height(e)},t.prototype.dimension=function(t,e,n){if(void 0!==e)return null!==e&&e===e||(e=0),-1!==(""+e).indexOf("%")||-1!==(""+e).indexOf("px")?this.el_.style[t]=e:this.el_.style[t]="auto"===e?"":e+"px",void(n||this.trigger("componentresize"));if(!this.el_)return 0;var r=this.el_.style[t],o=r.indexOf("px");return-1!==o?parseInt(r.slice(0,o),10):parseInt(this.el_["offset"+tt(t)],10)},t.prototype.currentDimension=function(t){var e=0;if("width"!==t&&"height"!==t)throw new Error("currentDimension only accepts width or height value");if("function"==typeof Et.getComputedStyle){var n=Et.getComputedStyle(this.el_);e=n.getPropertyValue(t)||n[t]}if(0===(e=parseFloat(e))){var r="offset"+tt(t);e=this.el_[r]}return e},t.prototype.currentDimensions=function(){return{width:this.currentDimension("width"),height:this.currentDimension("height")}},t.prototype.currentWidth=function(){return this.currentDimension("width")},t.prototype.currentHeight=function(){return this.currentDimension("height")},t.prototype.focus=function(){this.el_.focus()},t.prototype.blur=function(){this.el_.blur()},t.prototype.emitTapEvents=function(){var t=0,e=null,n=void 0;this.on("touchstart",function(r){1===r.touches.length&&(e={pageX:r.touches[0].pageX,pageY:r.touches[0].pageY},t=(new Date).getTime(),n=!0)}),this.on("touchmove",function(t){if(t.touches.length>1)n=!1;else if(e){var r=t.touches[0].pageX-e.pageX,o=t.touches[0].pageY-e.pageY,i=Math.sqrt(r*r+o*o);i>10&&(n=!1)}});var r=function(){n=!1};this.on("touchleave",r),this.on("touchcancel",r),this.on("touchend",function(r){if(e=null,!0===n){(new Date).getTime()-t<200&&(r.preventDefault(),this.trigger("tap"))}})},t.prototype.enableTouchActivity=function(){if(this.player()&&this.player().reportUserActivity){var t=je(this.player(),this.player().reportUserActivity),e=void 0;this.on("touchstart",function(){t(),this.clearInterval(e),e=this.setInterval(t,250)});var n=function(n){t(),this.clearInterval(e)};this.on("touchmove",t),this.on("touchend",n),this.on("touchcancel",n)}},t.prototype.setTimeout=function(t,e){var n=this;t=je(this,t);var r=Et.setTimeout(t,e),o=function(){return n.clearTimeout(r)};return o.guid="vjs-timeout-"+r,this.on("dispose",o),r},t.prototype.clearTimeout=function(t){Et.clearTimeout(t);var e=function(){};return e.guid="vjs-timeout-"+t,this.off("dispose",e),t},t.prototype.setInterval=function(t,e){var n=this;t=je(this,t);var r=Et.setInterval(t,e),o=function(){return n.clearInterval(r)};return o.guid="vjs-interval-"+r,this.on("dispose",o),r},t.prototype.clearInterval=function(t){Et.clearInterval(t);var e=function(){};return e.guid="vjs-interval-"+t,this.off("dispose",e),t},t.prototype.requestAnimationFrame=function(t){var e=this;if(this.supportsRaf_){t=je(this,t);var n=Et.requestAnimationFrame(t),r=function(){return e.cancelAnimationFrame(n)};return r.guid="vjs-raf-"+n,this.on("dispose",r),n}return this.setTimeout(t,1e3/60)},t.prototype.cancelAnimationFrame=function(t){if(this.supportsRaf_){Et.cancelAnimationFrame(t);var e=function(){};return e.guid="vjs-raf-"+t,this.off("dispose",e),t}return this.clearTimeout(t)},t.registerComponent=function(e,n){if("string"!=typeof e||!e)throw new Error('Illegal component name, "'+e+'"; must be a non-empty string.');var r=t.getComponent("Tech"),o=r&&r.isTech(n),i=t===n||t.prototype.isPrototypeOf(n.prototype);if(o||!i){var s=void 0;throw s=o?"techs must be registered using Tech.registerTech()":"must be a Component subclass",new Error('Illegal component, "'+e+'"; '+s+".")}e=tt(e),t.components_||(t.components_={});var a=t.getComponent("Player");if("Player"===e&&a&&a.players){var l=a.players,c=Object.keys(l);if(l&&c.length>0&&c.map(function(t){return l[t]}).every(Boolean))throw new Error("Can not register Player component after player has been created.")}return t.components_[e]=n,n},t.getComponent=function(e){if(e)return e=tt(e),t.components_&&t.components_[e]?t.components_[e]:void 0},t}();He.prototype.supportsRaf_="function"==typeof Et.requestAnimationFrame&&"function"==typeof Et.cancelAnimationFrame,He.registerComponent("Component",He);for(var Ue={},ze=[["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"]],We=ze[0],qe=void 0,Ge=0;Ge<ze.length;Ge++)if(ze[Ge][1]in xt){qe=ze[Ge];break}if(qe)for(var Xe=0;Xe<qe.length;Xe++)Ue[We[Xe]]=qe[Xe];lt.prototype.code=0,lt.prototype.message="",lt.prototype.status=null,lt.errorTypes=["MEDIA_ERR_CUSTOM","MEDIA_ERR_ABORTED","MEDIA_ERR_NETWORK","MEDIA_ERR_DECODE","MEDIA_ERR_SRC_NOT_SUPPORTED","MEDIA_ERR_ENCRYPTED"],lt.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."};for(var Ke=0;Ke<lt.errorTypes.length;Ke++)lt[lt.errorTypes[Ke]]=Ke,lt.prototype[lt.errorTypes[Ke]]=Ke;var Ye=function(t){return["kind","label","language","id","inBandMetadataTrackDispatchType","mode","src"].reduce(function(e,n,r){return t[n]&&(e[n]=t[n]),e},{cues:t.cues&&Array.prototype.map.call(t.cues,function(t){return{startTime:t.startTime,endTime:t.endTime,text:t.text,id:t.id}})})},$e=function(t){var e=t.$$("track"),n=Array.prototype.map.call(e,function(t){return t.track});return Array.prototype.map.call(e,function(t){var e=Ye(t.track);return t.src&&(e.src=t.src),e}).concat(Array.prototype.filter.call(t.textTracks(),function(t){return-1===n.indexOf(t)}).map(Ye))},Qe=function(t,e){return t.forEach(function(t){var n=e.addRemoteTextTrack(t).track;!t.src&&t.cues&&t.cues.forEach(function(t){return n.addCue(t)})}),e.textTracks()},Je={textTracksToJson:$e,jsonToTextTracks:Qe,trackToJson_:Ye},Ze="vjs-modal-dialog",tn=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.opened_=o.hasBeenOpened_=o.hasBeenFilled_=!1,o.closeable(!o.options_.uncloseable),o.content(o.options_.content),o.contentEl_=g("div",{className:Ze+"-content"},{role:"document"}),o.descEl_=g("p",{className:Ze+"-description vjs-control-text",id:o.el().getAttribute("aria-describedby")}),m(o.descEl_,o.description()),o.el_.appendChild(o.descEl_),o.el_.appendChild(o.contentEl_),o}return oe(e,t),e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass(),tabIndex:-1},{"aria-describedby":this.id()+"_description","aria-hidden":"true","aria-label":this.label(),role:"dialog"})},e.prototype.dispose=function(){this.contentEl_=null,this.descEl_=null,this.previouslyActiveEl_=null,t.prototype.dispose.call(this)},e.prototype.buildCSSClass=function(){return Ze+" vjs-hidden "+t.prototype.buildCSSClass.call(this)},e.prototype.handleKeyPress=function(t){27===t.which&&this.closeable()&&this.close()},e.prototype.label=function(){return this.localize(this.options_.label||"Modal Window")},e.prototype.description=function(){var t=this.options_.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},e.prototype.open=function(){if(!this.opened_){var t=this.player();this.trigger("beforemodalopen"),this.opened_=!0,(this.options_.fillAlways||!this.hasBeenOpened_&&!this.hasBeenFilled_)&&this.fill(),this.wasPlaying_=!t.paused(),this.options_.pauseOnOpen&&this.wasPlaying_&&t.pause(),this.closeable()&&this.on(this.el_.ownerDocument,"keydown",je(this,this.handleKeyPress)),this.hadControls_=t.controls(),t.controls(!1),this.show(),this.conditionalFocus_(),this.el().setAttribute("aria-hidden","false"),this.trigger("modalopen"),this.hasBeenOpened_=!0}},e.prototype.opened=function(t){return"boolean"==typeof t&&this[t?"open":"close"](),this.opened_},e.prototype.close=function(){if(this.opened_){var t=this.player();this.trigger("beforemodalclose"),this.opened_=!1,this.wasPlaying_&&this.options_.pauseOnOpen&&t.play(),this.closeable()&&this.off(this.el_.ownerDocument,"keydown",je(this,this.handleKeyPress)),this.hadControls_&&t.controls(!0),this.hide(),this.el().setAttribute("aria-hidden","true"),this.trigger("modalclose"),this.conditionalBlur_(),this.options_.temporary&&this.dispose()}},e.prototype.closeable=function(t){if("boolean"==typeof t){var e=this.closeable_=!!t,n=this.getChild("closeButton");if(e&&!n){var r=this.contentEl_;this.contentEl_=this.el_,n=this.addChild("closeButton",{controlText:"Close Modal Dialog"}),this.contentEl_=r,this.on(n,"close",this.close)}!e&&n&&(this.off(n,"close",this.close),this.removeChild(n),n.dispose())}return this.closeable_},e.prototype.fill=function(){this.fillWith(this.content())},e.prototype.fillWith=function(t){var e=this.contentEl(),n=e.parentNode,r=e.nextSibling;this.trigger("beforemodalfill"),this.hasBeenFilled_=!0,n.removeChild(e),this.empty(),B(e,t),this.trigger("modalfill"),r?n.insertBefore(e,r):n.appendChild(e);var o=this.getChild("closeButton");o&&n.appendChild(o.el_)},e.prototype.empty=function(){this.trigger("beforemodalempty"),R(this.contentEl()),this.trigger("modalempty")},e.prototype.content=function(t){return void 0!==t&&(this.content_=t),this.content_},e.prototype.conditionalFocus_=function(){var t=xt.activeElement,e=this.player_.el_;this.previouslyActiveEl_=null,(e.contains(t)||e===t)&&(this.previouslyActiveEl_=t,this.focus(),this.on(xt,"keydown",this.handleKeyDown))},e.prototype.conditionalBlur_=function(){this.previouslyActiveEl_&&(this.previouslyActiveEl_.focus(),this.previouslyActiveEl_=null),this.off(xt,"keydown",this.handleKeyDown)},e.prototype.handleKeyDown=function(t){if(9===t.which){for(var e=this.focusableEls_(),n=this.el_.querySelector(":focus"),r=void 0,o=0;o<e.length;o++)if(n===e[o]){r=o;break}xt.activeElement===this.el_&&(r=0),t.shiftKey&&0===r?(e[e.length-1].focus(),t.preventDefault()):t.shiftKey||r!==e.length-1||(e[0].focus(),t.preventDefault())}},e.prototype.focusableEls_=function(){var t=this.el_.querySelectorAll("*");return Array.prototype.filter.call(t,function(t){return(t instanceof Et.HTMLAnchorElement||t instanceof Et.HTMLAreaElement)&&t.hasAttribute("href")||(t instanceof Et.HTMLInputElement||t instanceof Et.HTMLSelectElement||t instanceof Et.HTMLTextAreaElement||t instanceof Et.HTMLButtonElement)&&!t.hasAttribute("disabled")||t instanceof Et.HTMLIFrameElement||t instanceof Et.HTMLObjectElement||t instanceof Et.HTMLEmbedElement||t.hasAttribute("tabindex")&&-1!==t.getAttribute("tabindex")||t.hasAttribute("contenteditable")})},e}(He);tn.prototype.options_={pauseOnOpen:!0,temporary:!0},He.registerComponent("ModalDialog",tn);var en=function(t){function e(){var n,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;re(this,e);var i=ie(this,t.call(this));if(!o&&(o=i,Yt)){o=xt.createElement("custom");for(var s in e.prototype)"constructor"!==s&&(o[s]=e.prototype[s])}o.tracks_=[],Object.defineProperty(o,"length",{get:function(){return this.tracks_.length}});for(var a=0;a<r.length;a++)o.addTrack(r[a]);return n=o,ie(i,n)}return oe(e,t),e.prototype.addTrack=function(t){var e=this.tracks_.length;""+e in this||Object.defineProperty(this,e,{get:function(){return this.tracks_[e]}}),-1===this.tracks_.indexOf(t)&&(this.tracks_.push(t),this.trigger({track:t,type:"addtrack"}))},e.prototype.removeTrack=function(t){for(var e=void 0,n=0,r=this.length;n<r;n++)if(this[n]===t){e=this[n],e.off&&e.off(),this.tracks_.splice(n,1);break}e&&this.trigger({track:e,type:"removetrack"})},e.prototype.getTrackById=function(t){for(var e=null,n=0,r=this.length;n<r;n++){var o=this[n];if(o.id===t){e=o;break}}return e},e}(Oe);en.prototype.allowedEvents_={change:"change",addtrack:"addtrack",removetrack:"removetrack"};for(var nn in en.prototype.allowedEvents_)en.prototype["on"+nn]=null;var rn=function(t,e){for(var n=0;n<t.length;n++)Object.keys(t[n]).length&&e.id!==t[n].id&&(t[n].enabled=!1)},on=function(t){function e(){var n,r,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];re(this,e);for(var i=void 0,s=o.length-1;s>=0;s--)if(o[s].enabled){rn(o,o[s]);break}if(Yt){i=xt.createElement("custom");for(var a in en.prototype)"constructor"!==a&&(i[a]=en.prototype[a]);for(var l in e.prototype)"constructor"!==l&&(i[l]=e.prototype[l])}return i=n=ie(this,t.call(this,o,i)),i.changing_=!1,r=i,ie(n,r)}return oe(e,t),e.prototype.addTrack=function(e){var n=this;e.enabled&&rn(this,e),t.prototype.addTrack.call(this,e),e.addEventListener&&e.addEventListener("enabledchange",function(){n.changing_||(n.changing_=!0,rn(n,e),n.changing_=!1,n.trigger("change"))})},e}(en),sn=function(t,e){for(var n=0;n<t.length;n++)Object.keys(t[n]).length&&e.id!==t[n].id&&(t[n].selected=!1)},an=function(t){function e(){var n,r,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];re(this,e);for(var i=void 0,s=o.length-1;s>=0;s--)if(o[s].selected){sn(o,o[s]);break}if(Yt){i=xt.createElement("custom");for(var a in en.prototype)"constructor"!==a&&(i[a]=en.prototype[a]);for(var l in e.prototype)"constructor"!==l&&(i[l]=e.prototype[l])}return i=n=ie(this,t.call(this,o,i)),i.changing_=!1,Object.defineProperty(i,"selectedIndex",{get:function(){for(var t=0;t<this.length;t++)if(this[t].selected)return t;return-1},set:function(){}}),r=i,ie(n,r)}return oe(e,t),e.prototype.addTrack=function(e){var n=this;e.selected&&sn(this,e),t.prototype.addTrack.call(this,e),e.addEventListener&&e.addEventListener("selectedchange",function(){n.changing_||(n.changing_=!0,sn(n,e),n.changing_=!1,n.trigger("change"))})},e}(en),ln=function(t){function e(){var n,r,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];re(this,e);var i=void 0;if(Yt){i=xt.createElement("custom");for(var s in en.prototype)"constructor"!==s&&(i[s]=en.prototype[s]);for(var a in e.prototype)"constructor"!==a&&(i[a]=e.prototype[a])}return i=n=ie(this,t.call(this,o,i)),r=i,ie(n,r)}return oe(e,t),e.prototype.addTrack=function(e){t.prototype.addTrack.call(this,e),e.addEventListener("modechange",je(this,function(){this.trigger("change")})),-1===["metadata","chapters"].indexOf(e.kind)&&e.addEventListener("modechange",je(this,function(){this.trigger("selectedlanguagechange")}))},e}(en),cn=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];re(this,t);var n=this;if(Yt){n=xt.createElement("custom");for(var r in t.prototype)"constructor"!==r&&(n[r]=t.prototype[r])}n.trackElements_=[],Object.defineProperty(n,"length",{get:function(){return this.trackElements_.length}});for(var o=0,i=e.length;o<i;o++)n.addTrackElement_(e[o]);if(Yt)return n}return t.prototype.addTrackElement_=function(t){var e=this.trackElements_.length;""+e in this||Object.defineProperty(this,e,{get:function(){return this.trackElements_[e]}}),-1===this.trackElements_.indexOf(t)&&this.trackElements_.push(t)},t.prototype.getTrackElementByTrack_=function(t){for(var e=void 0,n=0,r=this.trackElements_.length;n<r;n++)if(t===this.trackElements_[n].track){e=this.trackElements_[n];break}return e},t.prototype.removeTrackElement_=function(t){for(var e=0,n=this.trackElements_.length;e<n;e++)if(t===this.trackElements_[e]){this.trackElements_.splice(e,1);break}},t}(),un=function(){function t(e){re(this,t);var n=this;if(Yt){n=xt.createElement("custom");for(var r in t.prototype)"constructor"!==r&&(n[r]=t.prototype[r])}if(t.prototype.setCues_.call(n,e),Object.defineProperty(n,"length",{get:function(){return this.length_}}),Yt)return n}return t.prototype.setCues_=function(t){var e=this.length||0,n=0,r=t.length;this.cues_=t,this.length_=t.length;var o=function(t){""+t in this||Object.defineProperty(this,""+t,{get:function(){return this.cues_[t]}})};if(e<r)for(n=e;n<r;n++)o.call(this,n)},t.prototype.getCueById=function(t){for(var e=null,n=0,r=this.length;n<r;n++){var o=this[n];if(o.id===t){e=o;break}}return e},t}(),hn={alternative:"alternative",captions:"captions",main:"main",sign:"sign",subtitles:"subtitles",commentary:"commentary"},pn={alternative:"alternative",descriptions:"descriptions",main:"main","main-desc":"main-desc",translation:"translation",commentary:"commentary"},dn={subtitles:"subtitles",captions:"captions",descriptions:"descriptions",chapters:"chapters",metadata:"metadata"},fn={disabled:"disabled",hidden:"hidden",showing:"showing"},vn=function(t){function e(){var n,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};re(this,e);var o=ie(this,t.call(this)),i=o;if(Yt){i=xt.createElement("custom");for(var s in e.prototype)"constructor"!==s&&(i[s]=e.prototype[s])}var a={id:r.id||"vjs_track_"+V(),kind:r.kind||"",label:r.label||"",language:r.language||""};for(var l in a)!function(t){Object.defineProperty(i,t,{get:function(){return a[t]},set:function(){}})}(l);return n=i,ie(o,n)}return oe(e,t),e}(Oe),yn=function(t){var e=["protocol","hostname","port","pathname","search","hash","host"],n=xt.createElement("a");n.href=t;var r=""===n.host&&"file:"!==n.protocol,o=void 0;r&&(o=xt.createElement("div"),o.innerHTML='<a href="'+t+'"></a>',n=o.firstChild,o.setAttribute("style","display:none; position:absolute;"),xt.body.appendChild(o));for(var i={},s=0;s<e.length;s++)i[e[s]]=n[e[s]];return"http:"===i.protocol&&(i.host=i.host.replace(/:80$/,"")),"https:"===i.protocol&&(i.host=i.host.replace(/:443$/,"")),i.protocol||(i.protocol=Et.location.protocol),r&&xt.body.removeChild(o),i},gn=function(t){if(!t.match(/^https?:\/\//)){var e=xt.createElement("div");e.innerHTML='<a href="'+t+'">x</a>',t=e.firstChild.href}return t},mn=function(t){if("string"==typeof t){var e=/^(\/?)([\s\S]*?)((?:\.{1,2}|[^\/]+?)(\.([^\.\/\?]+)))(?:[\/]*|[\?].*)$/i,n=e.exec(t);if(n)return n.pop().toLowerCase()}return""},An=function(t){var e=Et.location,n=yn(t);return(":"===n.protocol?e.protocol:n.protocol)+n.host!==e.protocol+e.host},_n=(Object.freeze||Object)({parseUrl:yn,getAbsoluteURL:gn,getFileExtension:mn,isCrossOrigin:An}),bn=function(t,e){var n=new Et.WebVTT.Parser(Et,Et.vttjs,Et.WebVTT.StringDecoder()),r=[];n.oncue=function(t){e.addCue(t)},n.onparsingerror=function(t){r.push(t)},n.onflush=function(){e.trigger({type:"loadeddata",target:e})},n.parse(t),r.length>0&&(Et.console&&Et.console.groupCollapsed&&Et.console.groupCollapsed("Text Track parsing errors for "+e.src),r.forEach(function(t){return de.error(t)}),Et.console&&Et.console.groupEnd&&Et.console.groupEnd()),n.flush()},Tn=function(t,e){var n={uri:t},r=An(t);r&&(n.cors=r),Pt(n,je(this,function(t,n,r){if(t)return de.error(t,n);if(e.loaded_=!0,"function"!=typeof Et.WebVTT){if(e.tech_){var o=function(){return bn(r,e)};e.tech_.on("vttjsloaded",o),e.tech_.on("vttjserror",function(){de.error("vttjs failed to load, stopping trying to process "+e.src),e.tech_.off("vttjsloaded",o)})}}else bn(r,e)}))},wn=function(t){function e(){var n,r,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};if(re(this,e),!o.tech)throw new Error("A tech was not provided.");var i=nt(o,{kind:dn[o.kind]||"subtitles",language:o.language||o.srclang||""}),s=fn[i.mode]||"disabled",a=i.default;"metadata"!==i.kind&&"chapters"!==i.kind||(s="hidden");var l=n=ie(this,t.call(this,i));if(l.tech_=i.tech,Yt)for(var c in e.prototype)"constructor"!==c&&(l[c]=e.prototype[c]);l.cues_=[],l.activeCues_=[];var u=new un(l.cues_),h=new un(l.activeCues_),p=!1,d=je(l,function(){this.activeCues,p&&(this.trigger("cuechange"),p=!1)});return"disabled"!==s&&l.tech_.ready(function(){l.tech_.on("timeupdate",d)},!0),Object.defineProperty(l,"default",{get:function(){return a},set:function(){}}),Object.defineProperty(l,"mode",{get:function(){return s},set:function(t){var e=this;fn[t]&&(s=t,"showing"===s&&this.tech_.ready(function(){e.tech_.on("timeupdate",d)},!0),this.trigger("modechange"))}}),Object.defineProperty(l,"cues",{get:function(){return this.loaded_?u:null},set:function(){}}),Object.defineProperty(l,"activeCues",{get:function(){if(!this.loaded_)return null;if(0===this.cues.length)return h;for(var t=this.tech_.currentTime(),e=[],n=0,r=this.cues.length;n<r;n++){var o=this.cues[n];o.startTime<=t&&o.endTime>=t?e.push(o):o.startTime===o.endTime&&o.startTime<=t&&o.startTime+.5>=t&&e.push(o)}if(p=!1,e.length!==this.activeCues_.length)p=!0;else for(var i=0;i<e.length;i++)-1===this.activeCues_.indexOf(e[i])&&(p=!0);return this.activeCues_=e,h.setCues_(this.activeCues_),h},set:function(){}}),i.src?(l.src=i.src,Tn(i.src,l)):l.loaded_=!0,r=l,ie(n,r)}return oe(e,t),e.prototype.addCue=function(t){var e=t;if(Et.vttjs&&!(t instanceof Et.vttjs.VTTCue)){e=new Et.vttjs.VTTCue(t.startTime,t.endTime,t.text);for(var n in t)n in e||(e[n]=t[n]);e.id=t.id,e.originalCue_=t}for(var r=this.tech_.textTracks(),o=0;o<r.length;o++)r[o]!==this&&r[o].removeCue(e);this.cues_.push(e),this.cues.setCues_(this.cues_)},e.prototype.removeCue=function(t){for(var e=this.cues_.length;e--;){var n=this.cues_[e];if(n===t||n.originalCue_&&n.originalCue_===t){this.cues_.splice(e,1),this.cues.setCues_(this.cues_);break}}},e}(vn);wn.prototype.allowedEvents_={cuechange:"cuechange"};var Cn=function(t){function e(){var n,r,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};re(this,e);var i=nt(o,{kind:pn[o.kind]||""}),s=n=ie(this,t.call(this,i)),a=!1;if(Yt)for(var l in e.prototype)"constructor"!==l&&(s[l]=e.prototype[l]);return Object.defineProperty(s,"enabled",{get:function(){return a},set:function(t){"boolean"==typeof t&&t!==a&&(a=t,this.trigger("enabledchange"))}}),i.enabled&&(s.enabled=i.enabled),s.loaded_=!0,r=s,ie(n,r)}return oe(e,t),e}(vn),kn=function(t){function e(){var n,r,o=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};re(this,e);var i=nt(o,{kind:hn[o.kind]||""}),s=n=ie(this,t.call(this,i)),a=!1;if(Yt)for(var l in e.prototype)"constructor"!==l&&(s[l]=e.prototype[l]);return Object.defineProperty(s,"selected",{get:function(){return a},set:function(t){"boolean"==typeof t&&t!==a&&(a=t,this.trigger("selectedchange"))}}),i.selected&&(s.selected=i.selected),r=s,ie(n,r)}return oe(e,t),e}(vn),En=0,xn=2,Sn=function(t){function e(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};re(this,e);var r=ie(this,t.call(this)),o=void 0,i=r;if(Yt){i=xt.createElement("custom");for(var s in e.prototype)"constructor"!==s&&(i[s]=e.prototype[s])}var a=new wn(n);if(i.kind=a.kind,i.src=a.src,i.srclang=a.language,i.label=a.label,i.default=a.default,Object.defineProperty(i,"readyState",{get:function(){return o}}),Object.defineProperty(i,"track",{get:function(){return a}}),o=En,a.addEventListener("loadeddata",function(){o=xn,i.trigger({type:"load",target:i})}),Yt){var l;return l=i,ie(r,l)}return r}return oe(e,t),e}(Oe);Sn.prototype.allowedEvents_={load:"load"},Sn.NONE=En,Sn.LOADING=1,Sn.LOADED=xn,Sn.ERROR=3;var jn={audio:{ListClass:on,TrackClass:Cn,capitalName:"Audio"},video:{ListClass:an,TrackClass:kn,capitalName:"Video"},text:{ListClass:ln,TrackClass:wn,capitalName:"Text"}};Object.keys(jn).forEach(function(t){jn[t].getterName=t+"Tracks",jn[t].privateName=t+"Tracks_"});var Pn={remoteText:{ListClass:ln,TrackClass:wn,capitalName:"RemoteText",getterName:"remoteTextTracks",privateName:"remoteTextTracks_"},remoteTextEl:{ListClass:cn,TrackClass:Sn,capitalName:"RemoteTextTrackEls",getterName:"remoteTextTrackEls",privateName:"remoteTextTrackEls_"}},On=nt(jn,Pn);Pn.names=Object.keys(Pn),jn.names=Object.keys(jn),On.names=[].concat(Pn.names).concat(jn.names);var In=function(t){function e(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:function(){};re(this,e),n.reportTouchActivity=!1;var o=ie(this,t.call(this,null,n,r));return o.hasStarted_=!1,o.on("playing",function(){this.hasStarted_=!0}),o.on("loadstart",function(){this.hasStarted_=!1}),On.names.forEach(function(t){var e=On[t];n&&n[e.getterName]&&(o[e.privateName]=n[e.getterName])}),o.featuresProgressEvents||o.manualProgressOn(),o.featuresTimeupdateEvents||o.manualTimeUpdatesOn(),["Text","Audio","Video"].forEach(function(t){!1===n["native"+t+"Tracks"]&&(o["featuresNative"+t+"Tracks"]=!1)}),!1===n.nativeCaptions||!1===n.nativeTextTracks?o.featuresNativeTextTracks=!1:!0!==n.nativeCaptions&&!0!==n.nativeTextTracks||(o.featuresNativeTextTracks=!0),o.featuresNativeTextTracks||o.emulateTextTracks(),o.autoRemoteTextTracks_=new On.text.ListClass,o.initTrackListeners(),n.nativeControlsForTouch||o.emitTapEvents(),o.constructor&&(o.name_=o.constructor.name||"Unknown Tech"),o}return oe(e,t),e.prototype.manualProgressOn=function(){this.on("durationchange",this.onDurationChange),this.manualProgress=!0,this.one("ready",this.trackProgress)},e.prototype.manualProgressOff=function(){this.manualProgress=!1,this.stopTrackingProgress(),this.off("durationchange",this.onDurationChange)},e.prototype.trackProgress=function(t){this.stopTrackingProgress(),this.progressInterval=this.setInterval(je(this,function(){var t=this.bufferedPercent();this.bufferedPercent_!==t&&this.trigger("progress"),this.bufferedPercent_=t,1===t&&this.stopTrackingProgress()}),500)},e.prototype.onDurationChange=function(t){this.duration_=this.duration()},e.prototype.buffered=function(){return st(0,0)},e.prototype.bufferedPercent=function(){return at(this.buffered(),this.duration_)},e.prototype.stopTrackingProgress=function(){this.clearInterval(this.progressInterval)},e.prototype.manualTimeUpdatesOn=function(){this.manualTimeUpdates=!0,this.on("play",this.trackCurrentTime),this.on("pause",this.stopTrackingCurrentTime)},e.prototype.manualTimeUpdatesOff=function(){this.manualTimeUpdates=!1,this.stopTrackingCurrentTime(),this.off("play",this.trackCurrentTime),this.off("pause",this.stopTrackingCurrentTime)},e.prototype.trackCurrentTime=function(){this.currentTimeInterval&&this.stopTrackingCurrentTime(),this.currentTimeInterval=this.setInterval(function(){this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},250)},e.prototype.stopTrackingCurrentTime=function(){this.clearInterval(this.currentTimeInterval),this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},e.prototype.dispose=function(){this.clearTracks(jn.names),this.manualProgress&&this.manualProgressOff(),this.manualTimeUpdates&&this.manualTimeUpdatesOff(),t.prototype.dispose.call(this)},e.prototype.clearTracks=function(t){var e=this;t=[].concat(t),t.forEach(function(t){for(var n=e[t+"Tracks"]()||[],r=n.length;r--;){var o=n[r];"text"===t&&e.removeRemoteTextTrack(o),n.removeTrack(o)}})},e.prototype.cleanupAutoTextTracks=function(){for(var t=this.autoRemoteTextTracks_||[],e=t.length;e--;){var n=t[e];this.removeRemoteTextTrack(n)}},e.prototype.reset=function(){},e.prototype.error=function(t){return void 0!==t&&(this.error_=new lt(t),this.trigger("error")),this.error_},e.prototype.played=function(){return this.hasStarted_?st(0,0):st()},e.prototype.setCurrentTime=function(){this.manualTimeUpdates&&this.trigger({type:"timeupdate",target:this,manuallyTriggered:!0})},e.prototype.initTrackListeners=function(){var t=this;jn.names.forEach(function(e){var n=jn[e],r=function(){t.trigger(e+"trackchange")},o=t[n.getterName]();o.addEventListener("removetrack",r),o.addEventListener("addtrack",r),t.on("dispose",function(){o.removeEventListener("removetrack",r),o.removeEventListener("addtrack",r)})})},e.prototype.addWebVttScript_=function(){var t=this;if(!Et.WebVTT)if(xt.body.contains(this.el())){if(!this.options_["vtt.js"]&&l(Ot)&&Object.keys(Ot).length>0)return void this.trigger("vttjsloaded");var e=xt.createElement("script");e.src=this.options_["vtt.js"]||"https://vjs.zencdn.net/vttjs/0.12.4/vtt.min.js",e.onload=function(){t.trigger("vttjsloaded")},e.onerror=function(){t.trigger("vttjserror")},this.on("dispose",function(){e.onload=null,e.onerror=null}),Et.WebVTT=!0,this.el().parentNode.appendChild(e)}else this.ready(this.addWebVttScript_)},e.prototype.emulateTextTracks=function(){var t=this,e=this.textTracks(),n=this.remoteTextTracks(),r=function(t){return e.addTrack(t.track)},o=function(t){return e.removeTrack(t.track)};n.on("addtrack",r),n.on("removetrack",o),this.addWebVttScript_();var i=function(){return t.trigger("texttrackchange")},s=function(){i();for(var t=0;t<e.length;t++){var n=e[t];n.removeEventListener("cuechange",i),"showing"===n.mode&&n.addEventListener("cuechange",i)}};s(),e.addEventListener("change",s),e.addEventListener("addtrack",s),e.addEventListener("removetrack",s),this.on("dispose",function(){n.off("addtrack",r),n.off("removetrack",o),e.removeEventListener("change",s),e.removeEventListener("addtrack",s),e.removeEventListener("removetrack",s);for(var t=0;t<e.length;t++){e[t].removeEventListener("cuechange",i)}})},e.prototype.addTextTrack=function(t,e,n){if(!t)throw new Error("TextTrack kind is required but was not provided");return ht(this,t,e,n)},e.prototype.createRemoteTextTrack=function(t){var e=nt(t,{tech:this});return new Pn.remoteTextEl.TrackClass(e)},e.prototype.addRemoteTextTrack=function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments[1],r=this.createRemoteTextTrack(e);return!0!==n&&!1!==n&&(de.warn('Calling addRemoteTextTrack without explicitly setting the "manualCleanup" parameter to `true` is deprecated and default to `false` in future version of video.js'),n=!0),this.remoteTextTrackEls().addTrackElement_(r),this.remoteTextTracks().addTrack(r.track),!0!==n&&this.ready(function(){return t.autoRemoteTextTracks_.addTrack(r.track)}),r},e.prototype.removeRemoteTextTrack=function(t){var e=this.remoteTextTrackEls().getTrackElementByTrack_(t);this.remoteTextTrackEls().removeTrackElement_(e),this.remoteTextTracks().removeTrack(t),this.autoRemoteTextTracks_.removeTrack(t)},e.prototype.getVideoPlaybackQuality=function(){return{}},e.prototype.setPoster=function(){},e.prototype.playsinline=function(){},e.prototype.setPlaysinline=function(){},e.prototype.canPlayType=function(){return""},e.canPlayType=function(){return""},e.canPlaySource=function(t,n){return e.canPlayType(t.type)},e.isTech=function(t){return t.prototype instanceof e||t instanceof e||t===e},e.registerTech=function(t,n){if(e.techs_||(e.techs_={}),!e.isTech(n))throw new Error("Tech "+t+" must be a Tech");if(!e.canPlayType)throw new Error("Techs must have a static canPlayType method on them");if(!e.canPlaySource)throw new Error("Techs must have a static canPlaySource method on them");return t=tt(t),e.techs_[t]=n,"Tech"!==t&&e.defaultTechOrder_.push(t),n},e.getTech=function(t){if(t)return t=tt(t),e.techs_&&e.techs_[t]?e.techs_[t]:Et&&Et.videojs&&Et.videojs[t]?(de.warn("The "+t+" tech was added to the videojs object when it should be registered using videojs.registerTech(name, tech)"),Et.videojs[t]):void 0},e}(He);On.names.forEach(function(t){var e=On[t];In.prototype[e.getterName]=function(){return this[e.privateName]=this[e.privateName]||new e.ListClass,this[e.privateName]}}),In.prototype.featuresVolumeControl=!0,In.prototype.featuresFullscreenResize=!1,In.prototype.featuresPlaybackRate=!1,In.prototype.featuresProgressEvents=!1,In.prototype.featuresTimeupdateEvents=!1,In.prototype.featuresNativeTextTracks=!1,In.withSourceHandlers=function(t){t.registerSourceHandler=function(e,n){var r=t.sourceHandlers;r||(r=t.sourceHandlers=[]),void 0===n&&(n=r.length),r.splice(n,0,e)},t.canPlayType=function(e){for(var n=t.sourceHandlers||[],r=void 0,o=0;o<n.length;o++)if(r=n[o].canPlayType(e))return r;return""},t.selectSourceHandler=function(e,n){for(var r=t.sourceHandlers||[],o=0;o<r.length;o++)if(r[o].canHandleSource(e,n))return r[o];return null},t.canPlaySource=function(e,n){var r=t.selectSourceHandler(e,n);return r?r.canHandleSource(e,n):""},["seekable","duration"].forEach(function(t){var e=this[t];"function"==typeof e&&(this[t]=function(){return this.sourceHandler_&&this.sourceHandler_[t]?this.sourceHandler_[t].apply(this.sourceHandler_,arguments):e.apply(this,arguments)})},t.prototype),t.prototype.setSource=function(e){var n=t.selectSourceHandler(e,this.options_);n||(t.nativeSourceHandler?n=t.nativeSourceHandler:de.error("No source hander found for the current source.")),this.disposeSourceHandler(),this.off("dispose",this.disposeSourceHandler),n!==t.nativeSourceHandler&&(this.currentSource_=e),this.sourceHandler_=n.handleSource(e,this,this.options_),this.on("dispose",this.disposeSourceHandler)},t.prototype.disposeSourceHandler=function(){this.currentSource_&&(this.clearTracks(["audio","video"]),this.currentSource_=null),this.cleanupAutoTextTracks(),this.sourceHandler_&&(this.sourceHandler_.dispose&&this.sourceHandler_.dispose(),this.sourceHandler_=null)}},He.registerComponent("Tech",In),In.registerTech("Tech",In),In.defaultTechOrder_=[];var Mn={},Nn={buffered:1,currentTime:1,duration:1,seekable:1,played:1},Rn={setCurrentTime:1},Ln=function t(e){if(Array.isArray(e)){var n=[];e.forEach(function(e){e=t(e),Array.isArray(e)?n=n.concat(e):a(e)&&n.push(e)}),e=n}else e="string"==typeof e&&e.trim()?[{src:e}]:a(e)&&"string"==typeof e.src&&e.src&&e.src.trim()?[e]:[];return e},Dn=function(t){function e(n,r,o){re(this,e);var i=nt({createEl:!1},r),s=ie(this,t.call(this,n,i,o));if(r.playerOptions.sources&&0!==r.playerOptions.sources.length)n.src(r.playerOptions.sources);else for(var a=0,l=r.playerOptions.techOrder;a<l.length;a++){var c=tt(l[a]),u=In.getTech(c);if(c||(u=He.getComponent(c)),u&&u.isSupported()){n.loadTech_(c);break}}return s}return oe(e,t),e}(He);He.registerComponent("MediaLoader",Dn);var Bn=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.emitTapEvents(),o.enable(),o}return oe(e,t),e.prototype.createEl=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"div",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};n=s({innerHTML:'<span aria-hidden="true" class="vjs-icon-placeholder"></span>',className:this.buildCSSClass(),tabIndex:0},n),"button"===e&&de.error("Creating a ClickableComponent with an HTML element of "+e+" is not supported; use a Button instead."),r=s({role:"button","aria-live":"polite"},r),this.tabIndex_=n.tabIndex;var o=t.prototype.createEl.call(this,e,n,r);return this.createControlTextEl(o),o},e.prototype.dispose=function(){this.controlTextEl_=null,t.prototype.dispose.call(this)},e.prototype.createControlTextEl=function(t){return this.controlTextEl_=g("span",{className:"vjs-control-text"}),t&&t.appendChild(this.controlTextEl_),this.controlText(this.controlText_,t),this.controlTextEl_},e.prototype.controlText=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.el();if(void 0===t)return this.controlText_||"Need Text";var n=this.localize(t);this.controlText_=t,m(this.controlTextEl_,n),this.nonIconControl||e.setAttribute("title",n)},e.prototype.buildCSSClass=function(){return"vjs-control vjs-button "+t.prototype.buildCSSClass.call(this)},e.prototype.enable=function(){this.enabled_||(this.enabled_=!0,this.removeClass("vjs-disabled"),this.el_.setAttribute("aria-disabled","false"),void 0!==this.tabIndex_&&this.el_.setAttribute("tabIndex",this.tabIndex_),this.on(["tap","click"],this.handleClick),this.on("focus",this.handleFocus),this.on("blur",this.handleBlur))},e.prototype.disable=function(){this.enabled_=!1,this.addClass("vjs-disabled"),this.el_.setAttribute("aria-disabled","true"),void 0!==this.tabIndex_&&this.el_.removeAttribute("tabIndex"),this.off(["tap","click"],this.handleClick),this.off("focus",this.handleFocus),this.off("blur",this.handleBlur)},e.prototype.handleClick=function(t){},e.prototype.handleFocus=function(t){X(xt,"keydown",je(this,this.handleKeyPress))},e.prototype.handleKeyPress=function(e){32===e.which||13===e.which?(e.preventDefault(),this.trigger("click")):t.prototype.handleKeyPress&&t.prototype.handleKeyPress.call(this,e)},e.prototype.handleBlur=function(t){K(xt,"keydown",je(this,this.handleKeyPress))},e}(He);He.registerComponent("ClickableComponent",Bn);var Fn=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.update(),n.on("posterchange",je(o,o.update)),o}return oe(e,t),e.prototype.dispose=function(){this.player().off("posterchange",this.update),t.prototype.dispose.call(this)},e.prototype.createEl=function(){var t=g("div",{className:"vjs-poster",tabIndex:-1});return te||(this.fallbackImg_=g("img"),t.appendChild(this.fallbackImg_)),t},e.prototype.update=function(t){var e=this.player().poster();this.setSrc(e),e?this.show():this.hide()},e.prototype.setSrc=function(t){if(this.fallbackImg_)this.fallbackImg_.src=t;else{var e="";t&&(e='url("'+t+'")'),this.el_.style.backgroundImage=e}},e.prototype.handleClick=function(t){this.player_.controls()&&(this.player_.paused()?this.player_.play():this.player_.pause())},e}(Bn);He.registerComponent("PosterImage",Fn);var Vn={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'},Hn=function(t){function e(n,r,o){re(this,e);var i=ie(this,t.call(this,n,r,o));return n.on("loadstart",je(i,i.toggleDisplay)),n.on("texttrackchange",je(i,i.updateDisplay)),n.on("loadstart",je(i,i.preselectTrack)),n.ready(je(i,function(){if(n.tech_&&n.tech_.featuresNativeTextTracks)return void this.hide();n.on("fullscreenchange",je(this,this.updateDisplay));for(var t=this.options_.playerOptions.tracks||[],e=0;e<t.length;e++)this.player_.addRemoteTextTrack(t[e],!0);this.preselectTrack()})),i}return oe(e,t),e.prototype.preselectTrack=function(){for(var t={captions:1,subtitles:1},e=this.player_.textTracks(),n=this.player_.cache_.selectedLanguage,r=void 0,o=void 0,i=void 0,s=0;s<e.length;s++){var a=e[s];n&&n.enabled&&n.language===a.language?a.kind===n.kind?i=a:i||(i=a):n&&!n.enabled?(i=null,r=null,o=null):a.default&&("descriptions"!==a.kind||r?a.kind in t&&!o&&(o=a):r=a)}i?i.mode="showing":o?o.mode="showing":r&&(r.mode="showing")},e.prototype.toggleDisplay=function(){this.player_.tech_&&this.player_.tech_.featuresNativeTextTracks?this.hide():this.show()},e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-text-track-display"},{"aria-live":"off","aria-atomic":"true"})},e.prototype.clearDisplay=function(){"function"==typeof Et.WebVTT&&Et.WebVTT.processCues(Et,[],this.el_)},e.prototype.updateDisplay=function(){var t=this.player_.textTracks();this.clearDisplay();for(var e=null,n=null,r=t.length;r--;){var o=t[r];"showing"===o.mode&&("descriptions"===o.kind?e=o:n=o)}n?("off"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","off"),this.updateForTrack(n)):e&&("assertive"!==this.getAttribute("aria-live")&&this.setAttribute("aria-live","assertive"),this.updateForTrack(e))},e.prototype.updateForTrack=function(t){if("function"==typeof Et.WebVTT&&t.activeCues){for(var e=this.player_.textTrackSettings.getValues(),n=[],r=0;r<t.activeCues.length;r++)n.push(t.activeCues[r]);Et.WebVTT.processCues(Et,n,this.el_);for(var o=n.length;o--;){var i=n[o];if(i){var s=i.displayState;if(e.color&&(s.firstChild.style.color=e.color),e.textOpacity&&_t(s.firstChild,"color",At(e.color||"#fff",e.textOpacity)),e.backgroundColor&&(s.firstChild.style.backgroundColor=e.backgroundColor),e.backgroundOpacity&&_t(s.firstChild,"backgroundColor",At(e.backgroundColor||"#000",e.backgroundOpacity)),e.windowColor&&(e.windowOpacity?_t(s,"backgroundColor",At(e.windowColor,e.windowOpacity)):s.style.backgroundColor=e.windowColor),e.edgeStyle&&("dropshadow"===e.edgeStyle?s.firstChild.style.textShadow="2px 2px 3px #222, 2px 2px 4px #222, 2px 2px 5px #222":"raised"===e.edgeStyle?s.firstChild.style.textShadow="1px 1px #222, 2px 2px #222, 3px 3px #222":"depressed"===e.edgeStyle?s.firstChild.style.textShadow="1px 1px #ccc, 0 1px #ccc, -1px -1px #222, 0 -1px #222":"uniform"===e.edgeStyle&&(s.firstChild.style.textShadow="0 0 4px #222, 0 0 4px #222, 0 0 4px #222, 0 0 4px #222")),e.fontPercent&&1!==e.fontPercent){var a=Et.parseFloat(s.style.fontSize);s.style.fontSize=a*e.fontPercent+"px",s.style.height="auto",s.style.top="auto",s.style.bottom="2px"}e.fontFamily&&"default"!==e.fontFamily&&("small-caps"===e.fontFamily?s.firstChild.style.fontVariant="small-caps":s.firstChild.style.fontFamily=Vn[e.fontFamily])}}}},e}(He);He.registerComponent("TextTrackDisplay",Hn);var Un=function(t){function e(){return re(this,e),ie(this,t.apply(this,arguments))}return oe(e,t),e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-loading-spinner",dir:"ltr"})},e}(He);He.registerComponent("LoadingSpinner",Un);var zn=function(t){function e(){return re(this,e),ie(this,t.apply(this,arguments))}return oe(e,t),e.prototype.createEl=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};t="button",e=s({innerHTML:'<span aria-hidden="true" class="vjs-icon-placeholder"></span>',className:this.buildCSSClass()},e),n=s({type:"button","aria-live":"polite"},n);var r=He.prototype.createEl.call(this,t,e,n);return this.createControlTextEl(r),r},e.prototype.addChild=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.constructor.name;return de.warn("Adding an actionable (user controllable) child to a Button ("+n+") is not supported; use a ClickableComponent instead."),He.prototype.addChild.call(this,t,e)},e.prototype.enable=function(){t.prototype.enable.call(this),this.el_.removeAttribute("disabled")},e.prototype.disable=function(){t.prototype.disable.call(this),this.el_.setAttribute("disabled","disabled")},e.prototype.handleKeyPress=function(e){32!==e.which&&13!==e.which&&t.prototype.handleKeyPress.call(this,e)},e}(Bn);He.registerComponent("Button",zn);var Wn=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.mouseused_=!1,o.on("mousedown",o.handleMouseDown),o}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-big-play-button"},e.prototype.handleClick=function(t){var e=this.player_.play();if(!(this.mouseused_&&t.clientX&&t.clientY)){var n=this.player_.getChild("controlBar"),r=n&&n.getChild("playToggle");if(!r)return void this.player_.focus();var o=function(){return r.focus()};ct(e)?e.then(o,function(){}):this.setTimeout(o,1)}},e.prototype.handleKeyPress=function(e){this.mouseused_=!1,t.prototype.handleKeyPress.call(this,e)},e.prototype.handleMouseDown=function(t){this.mouseused_=!0},e}(zn);Wn.prototype.controlText_="Play Video",He.registerComponent("BigPlayButton",Wn);var qn=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.controlText(r&&r.controlText||o.localize("Close")),o}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-close-button "+t.prototype.buildCSSClass.call(this)},e.prototype.handleClick=function(t){this.trigger({type:"close",bubbles:!1})},e}(zn);He.registerComponent("CloseButton",qn);var Gn=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.on(n,"play",o.handlePlay),o.on(n,"pause",o.handlePause),o.on(n,"ended",o.handleEnded),o}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-play-control "+t.prototype.buildCSSClass.call(this)},e.prototype.handleClick=function(t){this.player_.paused()?this.player_.play():this.player_.pause()},e.prototype.handleSeeked=function(t){this.removeClass("vjs-ended"),this.player_.paused()?this.handlePause(t):this.handlePlay(t)},e.prototype.handlePlay=function(t){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.controlText("Pause")},e.prototype.handlePause=function(t){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.controlText("Play")},e.prototype.handleEnded=function(t){this.removeClass("vjs-playing"),this.addClass("vjs-ended"),this.controlText("Replay"),this.one(this.player_,"seeked",this.handleSeeked)},e}(zn);Gn.prototype.controlText_="Play",He.registerComponent("PlayToggle",Gn);var Xn=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.throttledUpdateContent=Pe(je(o,o.updateContent),25),o.on(n,"timeupdate",o.throttledUpdateContent),o}return oe(e,t),e.prototype.createEl=function(e){var n=this.buildCSSClass(),r=t.prototype.createEl.call(this,"div",{className:n+" vjs-time-control vjs-control"});return this.contentEl_=g("div",{className:n+"-display"},{"aria-live":"off"},g("span",{className:"vjs-control-text",textContent:this.localize(this.controlText_)})),this.updateTextNode_(),r.appendChild(this.contentEl_),r},e.prototype.dispose=function(){this.contentEl_=null,this.textNode_=null,t.prototype.dispose.call(this)},e.prototype.updateTextNode_=function(){if(this.contentEl_){for(;this.contentEl_.firstChild;)this.contentEl_.removeChild(this.contentEl_.firstChild);this.textNode_=xt.createTextNode(this.formattedTime_||"0:00"),this.contentEl_.appendChild(this.textNode_)}},e.prototype.formatTime_=function(t){return bt(t)},e.prototype.updateFormattedTime_=function(t){var e=this.formatTime_(t);e!==this.formattedTime_&&(this.formattedTime_=e,this.requestAnimationFrame(this.updateTextNode_))},e.prototype.updateContent=function(t){},e}(He);Xn.prototype.controlText_="Time",He.registerComponent("TimeDisplay",Xn);var Kn=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.on(n,"ended",o.handleEnded),o}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-current-time"},e.prototype.updateContent=function(t){var e=this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime();this.updateFormattedTime_(e)},e.prototype.handleEnded=function(t){this.player_.duration()&&this.updateFormattedTime_(this.player_.duration())},e}(Xn);Kn.prototype.controlText_="Current Time",He.registerComponent("CurrentTimeDisplay",Kn);var Yn=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.on(n,"durationchange",o.updateContent),o.on(n,"loadedmetadata",o.throttledUpdateContent),o}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-duration"},e.prototype.updateContent=function(t){var e=this.player_.duration();e&&this.duration_!==e&&(this.duration_=e,this.updateFormattedTime_(e))},e}(Xn);Yn.prototype.controlText_="Duration Time",He.registerComponent("DurationDisplay",Yn);var $n=function(t){function e(){return re(this,e),ie(this,t.apply(this,arguments))}return oe(e,t),e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-time-control vjs-time-divider",innerHTML:"<div><span>/</span></div>"})},e}(He);He.registerComponent("TimeDivider",$n);var Qn=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.on(n,"durationchange",o.throttledUpdateContent),o.on(n,"ended",o.handleEnded),o}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-remaining-time"},e.prototype.formatTime_=function(e){return"-"+t.prototype.formatTime_.call(this,e)},e.prototype.updateContent=function(t){this.player_.duration()&&(this.player_.remainingTimeDisplay?this.updateFormattedTime_(this.player_.remainingTimeDisplay()):this.updateFormattedTime_(this.player_.remainingTime()))},e.prototype.handleEnded=function(t){this.player_.duration()&&this.updateFormattedTime_(0)},e}(Xn);Qn.prototype.controlText_="Remaining Time",He.registerComponent("RemainingTimeDisplay",Qn);var Jn=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.updateShowing(),o.on(o.player(),"durationchange",o.updateShowing),o}return oe(e,t),e.prototype.createEl=function(){var e=t.prototype.createEl.call(this,"div",{className:"vjs-live-control vjs-control"});return this.contentEl_=g("div",{className:"vjs-live-display",innerHTML:'<span class="vjs-control-text">'+this.localize("Stream Type")+"</span>"+this.localize("LIVE")},{"aria-live":"off"}),e.appendChild(this.contentEl_),e},e.prototype.dispose=function(){this.contentEl_=null,t.prototype.dispose.call(this)},e.prototype.updateShowing=function(t){this.player().duration()===1/0?this.show():this.hide()},e}(He);He.registerComponent("LiveDisplay",Jn);var Zn=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.bar=o.getChild(o.options_.barName),o.vertical(!!o.options_.vertical),o.enable(),o}return oe(e,t),e.prototype.enabled=function(){return this.enabled_},e.prototype.enable=function(){this.enabled()||(this.on("mousedown",this.handleMouseDown),this.on("touchstart",this.handleMouseDown),this.on("focus",this.handleFocus),this.on("blur",this.handleBlur),this.on("click",this.handleClick),this.on(this.player_,"controlsvisible",this.update),this.playerEvent&&this.on(this.player_,this.playerEvent,this.update),this.removeClass("disabled"),this.setAttribute("tabindex",0),this.enabled_=!0)},e.prototype.disable=function(){if(this.enabled()){var t=this.bar.el_.ownerDocument;this.off("mousedown",this.handleMouseDown),this.off("touchstart",this.handleMouseDown),this.off("focus",this.handleFocus),this.off("blur",this.handleBlur),this.off("click",this.handleClick),this.off(this.player_,"controlsvisible",this.update),this.off(t,"mousemove",this.handleMouseMove),this.off(t,"mouseup",this.handleMouseUp),this.off(t,"touchmove",this.handleMouseMove),this.off(t,"touchend",this.handleMouseUp),this.removeAttribute("tabindex"),this.addClass("disabled"),this.playerEvent&&this.off(this.player_,this.playerEvent,this.update),this.enabled_=!1}},e.prototype.createEl=function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return n.className=n.className+" vjs-slider",n=s({tabIndex:0},n),r=s({role:"slider","aria-valuenow":0,"aria-valuemin":0,"aria-valuemax":100,tabIndex:0},r),t.prototype.createEl.call(this,e,n,r)},e.prototype.handleMouseDown=function(t){var e=this.bar.el_.ownerDocument;t.preventDefault(),j(),this.addClass("vjs-sliding"),this.trigger("slideractive"),this.on(e,"mousemove",this.handleMouseMove),this.on(e,"mouseup",this.handleMouseUp),this.on(e,"touchmove",this.handleMouseMove),this.on(e,"touchend",this.handleMouseUp),this.handleMouseMove(t)},e.prototype.handleMouseMove=function(t){},e.prototype.handleMouseUp=function(){var t=this.bar.el_.ownerDocument;P(),this.removeClass("vjs-sliding"),this.trigger("sliderinactive"),this.off(t,"mousemove",this.handleMouseMove),this.off(t,"mouseup",this.handleMouseUp),this.off(t,"touchmove",this.handleMouseMove),this.off(t,"touchend",this.handleMouseUp),this.update()},e.prototype.update=function(){if(this.el_){var t=this.getPercent(),e=this.bar;if(e){("number"!=typeof t||t!==t||t<0||t===1/0)&&(t=0);var n=(100*t).toFixed(2)+"%",r=e.el().style;return this.vertical()?r.height=n:r.width=n,t}}},e.prototype.calculateDistance=function(t){var e=M(this.el_,t);return this.vertical()?e.y:e.x},e.prototype.handleFocus=function(){this.on(this.bar.el_.ownerDocument,"keydown",this.handleKeyPress)},e.prototype.handleKeyPress=function(t){37===t.which||40===t.which?(t.preventDefault(),this.stepBack()):38!==t.which&&39!==t.which||(t.preventDefault(),this.stepForward())},e.prototype.handleBlur=function(){this.off(this.bar.el_.ownerDocument,"keydown",this.handleKeyPress)},e.prototype.handleClick=function(t){t.stopImmediatePropagation(),t.preventDefault()},e.prototype.vertical=function(t){if(void 0===t)return this.vertical_||!1;this.vertical_=!!t,this.vertical_?this.addClass("vjs-slider-vertical"):this.addClass("vjs-slider-horizontal")},e}(He);He.registerComponent("Slider",Zn);var tr=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.partEls_=[],o.on(n,"progress",o.update),o}return oe(e,t),e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-load-progress",innerHTML:'<span class="vjs-control-text"><span>'+this.localize("Loaded")+"</span>: 0%</span>"})},e.prototype.dispose=function(){this.partEls_=null,t.prototype.dispose.call(this)},e.prototype.update=function(t){var e=this.player_.buffered(),n=this.player_.duration(),r=this.player_.bufferedEnd(),o=this.partEls_,i=function(t,e){var n=t/e||0;return 100*(n>=1?1:n)+"%"};this.el_.style.width=i(r,n);for(var s=0;s<e.length;s++){var a=e.start(s),l=e.end(s),c=o[s];c||(c=this.el_.appendChild(g()),o[s]=c),c.style.left=i(a,r),c.style.width=i(l-a,r)}for(var u=o.length;u>e.length;u--)this.el_.removeChild(o[u-1]);o.length=e.length},e}(He);He.registerComponent("LoadProgressBar",tr);var er=function(t){function e(){return re(this,e),ie(this,t.apply(this,arguments))}return oe(e,t),e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-time-tooltip"})},e.prototype.update=function(t,e,n){var r=O(this.el_),o=O(this.player_.el()),i=t.width*e;if(o&&r){var s=t.left-o.left+i,a=t.width-i+(o.right-t.right),l=r.width/2;s<l?l+=l-s:a<l&&(l=a),l<0?l=0:l>r.width&&(l=r.width),this.el_.style.right="-"+l+"px",m(this.el_,n)}},e}(He);He.registerComponent("TimeTooltip",er);var nr=function(t){function e(){return re(this,e),ie(this,t.apply(this,arguments))}return oe(e,t),e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-play-progress vjs-slider-bar",innerHTML:'<span class="vjs-control-text"><span>'+this.localize("Progress")+"</span>: 0%</span>"})},e.prototype.update=function(t,e){var n=this;this.rafId_&&this.cancelAnimationFrame(this.rafId_),this.rafId_=this.requestAnimationFrame(function(){var r=n.player_.scrubbing()?n.player_.getCache().currentTime:n.player_.currentTime(),o=bt(r,n.player_.duration()),i=n.getChild("timeTooltip");i&&i.update(t,e,o)})},e}(He);nr.prototype.options_={children:[]},$t&&!($t>8)||Ft||Ht||nr.prototype.options_.children.push("timeTooltip"),He.registerComponent("PlayProgressBar",nr);var rr=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.update=Pe(je(o,o.update),25),o}return oe(e,t),e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-mouse-display"})},e.prototype.update=function(t,e){var n=this;this.rafId_&&this.cancelAnimationFrame(this.rafId_),this.rafId_=this.requestAnimationFrame(function(){var r=n.player_.duration(),o=bt(e*r,r);n.el_.style.left=t.width*e+"px",n.getChild("timeTooltip").update(t,e,o)})},e}(He);rr.prototype.options_={children:["timeTooltip"]},He.registerComponent("MouseTimeDisplay",rr);var or=30,ir=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.update=Pe(je(o,o.update),or),o.on(n,"timeupdate",o.update),o.on(n,"ended",o.handleEnded),o.updateInterval=null,o.on(n,["playing"],function(){o.clearInterval(o.updateInterval),o.updateInterval=o.setInterval(function(){o.requestAnimationFrame(function(){o.update()})},or)}),o.on(n,["ended","pause","waiting"],function(){o.clearInterval(o.updateInterval)}),o.on(n,["timeupdate","ended"],o.update),o}return oe(e,t),e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-holder"},{"aria-label":this.localize("Progress Bar")})},e.prototype.update_=function(t,e){var n=this.player_.duration();this.el_.setAttribute("aria-valuenow",(100*e).toFixed(2)),this.el_.setAttribute("aria-valuetext",this.localize("progress bar timing: currentTime={1} duration={2}",[bt(t,n),bt(n,n)],"{1} of {2}")),this.bar.update(O(this.el_),e)},e.prototype.update=function(e){var n=t.prototype.update.call(this);return this.update_(this.getCurrentTime_(),n),n},e.prototype.getCurrentTime_=function(){return this.player_.scrubbing()?this.player_.getCache().currentTime:this.player_.currentTime()},e.prototype.handleEnded=function(t){this.update_(this.player_.duration(),1)},e.prototype.getPercent=function(){var t=this.getCurrentTime_()/this.player_.duration();return t>=1?1:t},e.prototype.handleMouseDown=function(e){F(e)&&(this.player_.scrubbing(!0),this.videoWasPlaying=!this.player_.paused(),this.player_.pause(),t.prototype.handleMouseDown.call(this,e))},e.prototype.handleMouseMove=function(t){if(F(t)){var e=this.calculateDistance(t)*this.player_.duration();e===this.player_.duration()&&(e-=.1),this.player_.currentTime(e)}},e.prototype.enable=function(){t.prototype.enable.call(this);var e=this.getChild("mouseTimeDisplay");e&&e.show()},e.prototype.disable=function(){t.prototype.disable.call(this);var e=this.getChild("mouseTimeDisplay");e&&e.hide()},e.prototype.handleMouseUp=function(e){t.prototype.handleMouseUp.call(this,e),this.player_.scrubbing(!1),this.player_.trigger({type:"timeupdate",target:this,manuallyTriggered:!0}),this.videoWasPlaying&&this.player_.play()},e.prototype.stepForward=function(){this.player_.currentTime(this.player_.currentTime()+5)},e.prototype.stepBack=function(){this.player_.currentTime(this.player_.currentTime()-5)},e.prototype.handleAction=function(t){this.player_.paused()?this.player_.play():this.player_.pause()},e.prototype.handleKeyPress=function(e){32===e.which||13===e.which?(e.preventDefault(),this.handleAction(e)):t.prototype.handleKeyPress&&t.prototype.handleKeyPress.call(this,e)},e}(Zn);ir.prototype.options_={children:["loadProgressBar","playProgressBar"],barName:"playProgressBar"},$t&&!($t>8)||Ft||Ht||ir.prototype.options_.children.splice(1,0,"mouseTimeDisplay"),ir.prototype.playerEvent="timeupdate",He.registerComponent("SeekBar",ir);var sr=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.handleMouseMove=Pe(je(o,o.handleMouseMove),25),o.throttledHandleMouseSeek=Pe(je(o,o.handleMouseSeek),25),o.enable(),o}return oe(e,t),e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-progress-control vjs-control"})},e.prototype.handleMouseMove=function(t){var e=this.getChild("seekBar"),n=e.getChild("mouseTimeDisplay"),r=e.el(),o=O(r),i=M(r,t).x;i>1?i=1:i<0&&(i=0),n&&n.update(o,i)},e.prototype.handleMouseSeek=function(t){this.getChild("seekBar").handleMouseMove(t)},e.prototype.enabled=function(){return this.enabled_},e.prototype.disable=function(){this.children().forEach(function(t){return t.disable&&t.disable()}),this.enabled()&&(this.off(["mousedown","touchstart"],this.handleMouseDown),this.off(this.el_,"mousemove",this.handleMouseMove),this.handleMouseUp(),this.addClass("disabled"),this.enabled_=!1)},e.prototype.enable=function(){this.children().forEach(function(t){return t.enable&&t.enable()}),this.enabled()||(this.on(["mousedown","touchstart"],this.handleMouseDown),this.on(this.el_,"mousemove",this.handleMouseMove),this.removeClass("disabled"),this.enabled_=!0)},e.prototype.handleMouseDown=function(t){var e=this.el_.ownerDocument;this.on(e,"mousemove",this.throttledHandleMouseSeek),this.on(e,"touchmove",this.throttledHandleMouseSeek),this.on(e,"mouseup",this.handleMouseUp),this.on(e,"touchend",this.handleMouseUp)},e.prototype.handleMouseUp=function(t){var e=this.el_.ownerDocument;this.off(e,"mousemove",this.throttledHandleMouseSeek),this.off(e,"touchmove",this.throttledHandleMouseSeek),this.off(e,"mouseup",this.handleMouseUp),this.off(e,"touchend",this.handleMouseUp)},e}(He);sr.prototype.options_={children:["seekBar"]},He.registerComponent("ProgressControl",sr);var ar=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.on(n,"fullscreenchange",o.handleFullscreenChange),o}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-fullscreen-control "+t.prototype.buildCSSClass.call(this)},e.prototype.handleFullscreenChange=function(t){this.player_.isFullscreen()?this.controlText("Non-Fullscreen"):this.controlText("Fullscreen")},e.prototype.handleClick=function(t){this.player_.isFullscreen()?this.player_.exitFullscreen():this.player_.requestFullscreen()},e}(zn);ar.prototype.controlText_="Fullscreen",He.registerComponent("FullscreenToggle",ar);var lr=function(t,e){e.tech_&&!e.tech_.featuresVolumeControl&&t.addClass("vjs-hidden"),t.on(e,"loadstart",function(){e.tech_.featuresVolumeControl?t.removeClass("vjs-hidden"):t.addClass("vjs-hidden")})},cr=function(t){function e(){return re(this,e),ie(this,t.apply(this,arguments))}return oe(e,t),e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-level",innerHTML:'<span class="vjs-control-text"></span>'})},e}(He);He.registerComponent("VolumeLevel",cr);var ur=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.on("slideractive",o.updateLastVolume_),o.on(n,"volumechange",o.updateARIAAttributes),n.ready(function(){return o.updateARIAAttributes()}),o}return oe(e,t),e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-volume-bar vjs-slider-bar"},{"aria-label":this.localize("Volume Level"),"aria-live":"polite"})},e.prototype.handleMouseDown=function(e){F(e)&&t.prototype.handleMouseDown.call(this,e)},e.prototype.handleMouseMove=function(t){F(t)&&(this.checkMuted(),this.player_.volume(this.calculateDistance(t)))},e.prototype.checkMuted=function(){this.player_.muted()&&this.player_.muted(!1)},e.prototype.getPercent=function(){return this.player_.muted()?0:this.player_.volume()},e.prototype.stepForward=function(){this.checkMuted(),this.player_.volume(this.player_.volume()+.1)},e.prototype.stepBack=function(){this.checkMuted(),this.player_.volume(this.player_.volume()-.1)},e.prototype.updateARIAAttributes=function(t){var e=this.player_.muted()?0:this.volumeAsPercentage_();this.el_.setAttribute("aria-valuenow",e),this.el_.setAttribute("aria-valuetext",e+"%")},e.prototype.volumeAsPercentage_=function(){return Math.round(100*this.player_.volume())},e.prototype.updateLastVolume_=function(){var t=this,e=this.player_.volume();this.one("sliderinactive",function(){0===t.player_.volume()&&t.player_.lastVolume_(e)})},e}(Zn);ur.prototype.options_={children:["volumeLevel"],barName:"volumeLevel"},ur.prototype.playerEvent="volumechange",He.registerComponent("VolumeBar",ur);var hr=function(t){function e(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};re(this,e),r.vertical=r.vertical||!1,(void 0===r.volumeBar||l(r.volumeBar))&&(r.volumeBar=r.volumeBar||{},r.volumeBar.vertical=r.vertical);var o=ie(this,t.call(this,n,r));return lr(o,n),o.throttledHandleMouseMove=Pe(je(o,o.handleMouseMove),25),o.on("mousedown",o.handleMouseDown),o.on("touchstart",o.handleMouseDown),o.on(o.volumeBar,["focus","slideractive"],function(){o.volumeBar.addClass("vjs-slider-active"),o.addClass("vjs-slider-active"),o.trigger("slideractive")}),o.on(o.volumeBar,["blur","sliderinactive"],function(){o.volumeBar.removeClass("vjs-slider-active"),o.removeClass("vjs-slider-active"),o.trigger("sliderinactive")}),o}return oe(e,t),e.prototype.createEl=function(){var e="vjs-volume-horizontal";return this.options_.vertical&&(e="vjs-volume-vertical"),t.prototype.createEl.call(this,"div",{className:"vjs-volume-control vjs-control "+e})},e.prototype.handleMouseDown=function(t){var e=this.el_.ownerDocument;this.on(e,"mousemove",this.throttledHandleMouseMove),this.on(e,"touchmove",this.throttledHandleMouseMove),this.on(e,"mouseup",this.handleMouseUp),this.on(e,"touchend",this.handleMouseUp)},e.prototype.handleMouseUp=function(t){var e=this.el_.ownerDocument;this.off(e,"mousemove",this.throttledHandleMouseMove),this.off(e,"touchmove",this.throttledHandleMouseMove),this.off(e,"mouseup",this.handleMouseUp),this.off(e,"touchend",this.handleMouseUp)},e.prototype.handleMouseMove=function(t){this.volumeBar.handleMouseMove(t)},e}(He);hr.prototype.options_={children:["volumeBar"]},He.registerComponent("VolumeControl",hr);var pr=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return lr(o,n),o.on(n,["loadstart","volumechange"],o.update),o}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-mute-control "+t.prototype.buildCSSClass.call(this)},e.prototype.handleClick=function(t){var e=this.player_.volume(),n=this.player_.lastVolume_();if(0===e){var r=n<.1?.1:n;this.player_.volume(r),this.player_.muted(!1)}else this.player_.muted(!this.player_.muted())},e.prototype.update=function(t){this.updateIcon_(),this.updateControlText_()},e.prototype.updateIcon_=function(){var t=this.player_.volume(),e=3;0===t||this.player_.muted()?e=0:t<.33?e=1:t<.67&&(e=2);for(var n=0;n<4;n++)T(this.el_,"vjs-vol-"+n);b(this.el_,"vjs-vol-"+e)},e.prototype.updateControlText_=function(){var t=this.player_.muted()||0===this.player_.volume(),e=t?"Unmute":"Mute";this.controlText()!==e&&this.controlText(e)},e}(zn);pr.prototype.controlText_="Mute",He.registerComponent("MuteToggle",pr);var dr=function(t){function e(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};re(this,e),void 0!==r.inline?r.inline=r.inline:r.inline=!0,(void 0===r.volumeControl||l(r.volumeControl))&&(r.volumeControl=r.volumeControl||{},r.volumeControl.vertical=!r.inline);var o=ie(this,t.call(this,n,r));return lr(o,n),o.on(o.volumeControl,["slideractive"],o.sliderActive_),o.on(o.muteToggle,"focus",o.sliderActive_),o.on(o.volumeControl,["sliderinactive"],o.sliderInactive_),o.on(o.muteToggle,"blur",o.sliderInactive_),o}return oe(e,t),e.prototype.sliderActive_=function(){this.addClass("vjs-slider-active")},e.prototype.sliderInactive_=function(){this.removeClass("vjs-slider-active")},e.prototype.createEl=function(){var e="vjs-volume-panel-horizontal";return this.options_.inline||(e="vjs-volume-panel-vertical"),t.prototype.createEl.call(this,"div",{className:"vjs-volume-panel vjs-control "+e})},e}(He);dr.prototype.options_={children:["muteToggle","volumeControl"]},He.registerComponent("VolumePanel",dr);var fr=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return r&&(o.menuButton_=r.menuButton),o.focusedChild_=-1,o.on("keydown",o.handleKeyPress),o}return oe(e,t),e.prototype.addItem=function(t){this.addChild(t),t.on("click",je(this,function(e){this.menuButton_&&(this.menuButton_.unpressButton(),"CaptionSettingsMenuItem"!==t.name()&&this.menuButton_.focus())}))},e.prototype.createEl=function(){var e=this.options_.contentElType||"ul";this.contentEl_=g(e,{className:"vjs-menu-content"}),this.contentEl_.setAttribute("role","menu");var n=t.prototype.createEl.call(this,"div",{append:this.contentEl_,className:"vjs-menu"});return n.appendChild(this.contentEl_),X(n,"click",function(t){t.preventDefault(),t.stopImmediatePropagation()}),n},e.prototype.dispose=function(){this.contentEl_=null,t.prototype.dispose.call(this)},e.prototype.handleKeyPress=function(t){37===t.which||40===t.which?(t.preventDefault(),this.stepForward()):38!==t.which&&39!==t.which||(t.preventDefault(),this.stepBack())},e.prototype.stepForward=function(){var t=0;void 0!==this.focusedChild_&&(t=this.focusedChild_+1),this.focus(t)},e.prototype.stepBack=function(){var t=0;void 0!==this.focusedChild_&&(t=this.focusedChild_-1),this.focus(t)},e.prototype.focus=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=this.children().slice();e.length&&e[0].className&&/vjs-menu-title/.test(e[0].className)&&e.shift(),e.length>0&&(t<0?t=0:t>=e.length&&(t=e.length-1),this.focusedChild_=t,e[t].el_.focus())},e}(He);He.registerComponent("Menu",fr);var vr=function(t){function e(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};re(this,e);var o=ie(this,t.call(this,n,r));o.menuButton_=new zn(n,r),o.menuButton_.controlText(o.controlText_),o.menuButton_.el_.setAttribute("aria-haspopup","true");var i=zn.prototype.buildCSSClass();return o.menuButton_.el_.className=o.buildCSSClass()+" "+i,o.menuButton_.removeClass("vjs-control"),o.addChild(o.menuButton_),o.update(),o.enabled_=!0,o.on(o.menuButton_,"tap",o.handleClick),o.on(o.menuButton_,"click",o.handleClick),o.on(o.menuButton_,"focus",o.handleFocus),o.on(o.menuButton_,"blur",o.handleBlur),o.on("keydown",o.handleSubmenuKeyPress),o}return oe(e,t),e.prototype.update=function(){var t=this.createMenu();this.menu&&(this.menu.dispose(),this.removeChild(this.menu)),this.menu=t,this.addChild(t),this.buttonPressed_=!1,this.menuButton_.el_.setAttribute("aria-expanded","false"),this.items&&this.items.length<=this.hideThreshold_?this.hide():this.show()},e.prototype.createMenu=function(){var t=new fr(this.player_,{menuButton:this});if(this.hideThreshold_=0,this.options_.title){var e=g("li",{className:"vjs-menu-title",innerHTML:tt(this.options_.title),tabIndex:-1});this.hideThreshold_+=1,t.children_.unshift(e),A(e,t.contentEl())}if(this.items=this.createItems(),this.items)for(var n=0;n<this.items.length;n++)t.addItem(this.items[n]);return t},e.prototype.createItems=function(){},e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildWrapperCSSClass()},{})},e.prototype.buildWrapperCSSClass=function(){var e="vjs-menu-button";return!0===this.options_.inline?e+="-inline":e+="-popup","vjs-menu-button "+e+" "+zn.prototype.buildCSSClass()+" "+t.prototype.buildCSSClass.call(this)},e.prototype.buildCSSClass=function(){var e="vjs-menu-button";return!0===this.options_.inline?e+="-inline":e+="-popup","vjs-menu-button "+e+" "+t.prototype.buildCSSClass.call(this)},e.prototype.controlText=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.menuButton_.el();return this.menuButton_.controlText(t,e)},e.prototype.handleClick=function(t){this.one(this.menu.contentEl(),"mouseleave",je(this,function(t){this.unpressButton(),this.el_.blur()})),this.buttonPressed_?this.unpressButton():this.pressButton()},e.prototype.focus=function(){this.menuButton_.focus()},e.prototype.blur=function(){this.menuButton_.blur()},e.prototype.handleFocus=function(){X(xt,"keydown",je(this,this.handleKeyPress))},e.prototype.handleBlur=function(){K(xt,"keydown",je(this,this.handleKeyPress))},e.prototype.handleKeyPress=function(t){27===t.which||9===t.which?(this.buttonPressed_&&this.unpressButton(),9!==t.which&&(t.preventDefault(),this.menuButton_.el_.focus())):38!==t.which&&40!==t.which||this.buttonPressed_||(this.pressButton(),t.preventDefault())},e.prototype.handleSubmenuKeyPress=function(t){27!==t.which&&9!==t.which||(this.buttonPressed_&&this.unpressButton(),9!==t.which&&(t.preventDefault(),this.menuButton_.el_.focus()))},e.prototype.pressButton=function(){if(this.enabled_){if(this.buttonPressed_=!0,this.menu.lockShowing(),this.menuButton_.el_.setAttribute("aria-expanded","true"),Ft&&v())return;this.menu.focus()}},e.prototype.unpressButton=function(){this.enabled_&&(this.buttonPressed_=!1,this.menu.unlockShowing(),this.menuButton_.el_.setAttribute("aria-expanded","false"))},e.prototype.disable=function(){this.unpressButton(),this.enabled_=!1,this.addClass("vjs-disabled"),this.menuButton_.disable()},e.prototype.enable=function(){this.enabled_=!0,this.removeClass("vjs-disabled"),this.menuButton_.enable()},e}(He);He.registerComponent("MenuButton",vr);var yr=function(t){function e(n,r){re(this,e);var o=r.tracks,i=ie(this,t.call(this,n,r));if(i.items.length<=1&&i.hide(),!o)return ie(i);var s=je(i,i.update);return o.addEventListener("removetrack",s),o.addEventListener("addtrack",s),i.player_.on("ready",s),i.player_.on("dispose",function(){o.removeEventListener("removetrack",s),o.removeEventListener("addtrack",s)}),i}return oe(e,t),e}(vr);He.registerComponent("TrackButton",yr);var gr=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.selectable=r.selectable,o.selected(r.selected),o.selectable?o.el_.setAttribute("role","menuitemcheckbox"):o.el_.setAttribute("role","menuitem"),o}return oe(e,t),e.prototype.createEl=function(e,n,r){return this.nonIconControl=!0,t.prototype.createEl.call(this,"li",s({className:"vjs-menu-item",innerHTML:'<span class="vjs-menu-item-text">'+this.localize(this.options_.label)+"</span>",tabIndex:-1},n),r)},e.prototype.handleClick=function(t){this.selected(!0)},e.prototype.selected=function(t){this.selectable&&(t?(this.addClass("vjs-selected"),this.el_.setAttribute("aria-checked","true"),this.controlText(", selected")):(this.removeClass("vjs-selected"),this.el_.setAttribute("aria-checked","false"),this.controlText("")))},e}(Bn);He.registerComponent("MenuItem",gr);var mr=function(t){function e(n,r){re(this,e);var o=r.track,i=n.textTracks();r.label=o.label||o.language||"Unknown",r.selected="showing"===o.mode;var s=ie(this,t.call(this,n,r));s.track=o;var a=function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];s.handleTracksChange.apply(s,e)},l=function(){for(var t=arguments.length,e=Array(t),n=0;n<t;n++)e[n]=arguments[n];s.handleSelectedLanguageChange.apply(s,e)};if(n.on(["loadstart","texttrackchange"],a),i.addEventListener("change",a),i.addEventListener("selectedlanguagechange",l),s.on("dispose",function(){n.off(["loadstart","texttrackchange"],a),i.removeEventListener("change",a),i.removeEventListener("selectedlanguagechange",l)}),void 0===i.onchange){var c=void 0;s.on(["tap","click"],function(){if("object"!==ne(Et.Event))try{c=new Et.Event("change")}catch(t){}c||(c=xt.createEvent("Event"),c.initEvent("change",!0,!0)),i.dispatchEvent(c)})}return s.handleTracksChange(),s}return oe(e,t),e.prototype.handleClick=function(e){var n=this.track.kind,r=this.track.kinds,o=this.player_.textTracks();if(r||(r=[n]),t.prototype.handleClick.call(this,e),o)for(var i=0;i<o.length;i++){var s=o[i];s===this.track&&r.indexOf(s.kind)>-1?"showing"!==s.mode&&(s.mode="showing"):"disabled"!==s.mode&&(s.mode="disabled")}},e.prototype.handleTracksChange=function(t){this.selected("showing"===this.track.mode)},e.prototype.handleSelectedLanguageChange=function(t){if("showing"===this.track.mode){var e=this.player_.cache_.selectedLanguage;if(e&&e.enabled&&e.language===this.track.language&&e.kind!==this.track.kind)return;this.player_.cache_.selectedLanguage={enabled:!0,language:this.track.language,kind:this.track.kind}}},e.prototype.dispose=function(){this.track=null,t.prototype.dispose.call(this)},e}(gr);He.registerComponent("TextTrackMenuItem",mr);var Ar=function(t){function e(n,r){return re(this,e),r.track={player:n,kind:r.kind,kinds:r.kinds,default:!1,mode:"disabled"},r.kinds||(r.kinds=[r.kind]),r.label?r.track.label=r.label:r.track.label=r.kinds.join(" and ")+" off",r.selectable=!0,ie(this,t.call(this,n,r))}return oe(e,t),e.prototype.handleTracksChange=function(t){for(var e=this.player().textTracks(),n=!0,r=0,o=e.length;r<o;r++){var i=e[r];if(this.options_.kinds.indexOf(i.kind)>-1&&"showing"===i.mode){n=!1;break}}this.selected(n)},e.prototype.handleSelectedLanguageChange=function(t){for(var e=this.player().textTracks(),n=!0,r=0,o=e.length;r<o;r++){var i=e[r];if(["captions","descriptions","subtitles"].indexOf(i.kind)>-1&&"showing"===i.mode){n=!1;break}}n&&(this.player_.cache_.selectedLanguage={enabled:!1})},e}(mr);He.registerComponent("OffTextTrackMenuItem",Ar);var _r=function(t){function e(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return re(this,e),r.tracks=n.textTracks(),ie(this,t.call(this,n,r))}return oe(e,t),e.prototype.createItems=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:mr,n=void 0;this.label_&&(n=this.label_+" off"),t.push(new Ar(this.player_,{kinds:this.kinds_,kind:this.kind_,label:n})),this.hideThreshold_+=1;var r=this.player_.textTracks();Array.isArray(this.kinds_)||(this.kinds_=[this.kind_]);for(var o=0;o<r.length;o++){var i=r[o];if(this.kinds_.indexOf(i.kind)>-1){var s=new e(this.player_,{track:i,selectable:!0});s.addClass("vjs-"+i.kind+"-menu-item"),t.push(s)}}return t},e}(yr);He.registerComponent("TextTrackButton",_r);var br=function(t){function e(n,r){re(this,e);var o=r.track,i=r.cue,s=n.currentTime();r.selectable=!0,r.label=i.text,r.selected=i.startTime<=s&&s<i.endTime;var a=ie(this,t.call(this,n,r));return a.track=o,a.cue=i,o.addEventListener("cuechange",je(a,a.update)),a}return oe(e,t),e.prototype.handleClick=function(e){t.prototype.handleClick.call(this),this.player_.currentTime(this.cue.startTime),this.update(this.cue.startTime)},e.prototype.update=function(t){var e=this.cue,n=this.player_.currentTime();this.selected(e.startTime<=n&&n<e.endTime)},e}(gr);He.registerComponent("ChaptersTrackMenuItem",br);var Tr=function(t){function e(n,r,o){return re(this,e),ie(this,t.call(this,n,r,o))}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-chapters-button "+t.prototype.buildCSSClass.call(this)},e.prototype.buildWrapperCSSClass=function(){return"vjs-chapters-button "+t.prototype.buildWrapperCSSClass.call(this)},e.prototype.update=function(e){this.track_&&(!e||"addtrack"!==e.type&&"removetrack"!==e.type)||this.setTrack(this.findChaptersTrack()),t.prototype.update.call(this)},e.prototype.setTrack=function(t){if(this.track_!==t){if(this.updateHandler_||(this.updateHandler_=this.update.bind(this)),this.track_){var e=this.player_.remoteTextTrackEls().getTrackElementByTrack_(this.track_);e&&e.removeEventListener("load",this.updateHandler_),this.track_=null}if(this.track_=t,this.track_){this.track_.mode="hidden";var n=this.player_.remoteTextTrackEls().getTrackElementByTrack_(this.track_);n&&n.addEventListener("load",this.updateHandler_)}}},e.prototype.findChaptersTrack=function(){for(var t=this.player_.textTracks()||[],e=t.length-1;e>=0;e--){var n=t[e];if(n.kind===this.kind_)return n}},e.prototype.getMenuCaption=function(){return this.track_&&this.track_.label?this.track_.label:this.localize(tt(this.kind_))},e.prototype.createMenu=function(){return this.options_.title=this.getMenuCaption(),t.prototype.createMenu.call(this)},e.prototype.createItems=function(){var t=[];if(!this.track_)return t;var e=this.track_.cues;if(!e)return t;for(var n=0,r=e.length;n<r;n++){var o=e[n],i=new br(this.player_,{track:this.track_,cue:o});t.push(i)}return t},e}(_r);Tr.prototype.kind_="chapters",Tr.prototype.controlText_="Chapters",He.registerComponent("ChaptersButton",Tr);var wr=function(t){function e(n,r,o){re(this,e);var i=ie(this,t.call(this,n,r,o)),s=n.textTracks(),a=je(i,i.handleTracksChange);return s.addEventListener("change",a),i.on("dispose",function(){s.removeEventListener("change",a)}),i}return oe(e,t),e.prototype.handleTracksChange=function(t){for(var e=this.player().textTracks(),n=!1,r=0,o=e.length;r<o;r++){var i=e[r];if(i.kind!==this.kind_&&"showing"===i.mode){n=!0;break}}n?this.disable():this.enable()},e.prototype.buildCSSClass=function(){return"vjs-descriptions-button "+t.prototype.buildCSSClass.call(this)},e.prototype.buildWrapperCSSClass=function(){return"vjs-descriptions-button "+t.prototype.buildWrapperCSSClass.call(this)},e}(_r);wr.prototype.kind_="descriptions",wr.prototype.controlText_="Descriptions",He.registerComponent("DescriptionsButton",wr);var Cr=function(t){function e(n,r,o){return re(this,e),ie(this,t.call(this,n,r,o))}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildCSSClass.call(this)},e.prototype.buildWrapperCSSClass=function(){return"vjs-subtitles-button "+t.prototype.buildWrapperCSSClass.call(this)},e}(_r);Cr.prototype.kind_="subtitles",Cr.prototype.controlText_="Subtitles",He.registerComponent("SubtitlesButton",Cr);var kr=function(t){function e(n,r){re(this,e),r.track={player:n,kind:r.kind,label:r.kind+" settings",selectable:!1,default:!1,mode:"disabled"},r.selectable=!1,r.name="CaptionSettingsMenuItem";var o=ie(this,t.call(this,n,r));return o.addClass("vjs-texttrack-settings"),o.controlText(", opens "+r.kind+" settings dialog"),o}return oe(e,t),e.prototype.handleClick=function(t){this.player().getChild("textTrackSettings").open()},e}(mr);He.registerComponent("CaptionSettingsMenuItem",kr);var Er=function(t){function e(n,r,o){return re(this,e),ie(this,t.call(this,n,r,o))}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-captions-button "+t.prototype.buildCSSClass.call(this)},e.prototype.buildWrapperCSSClass=function(){return"vjs-captions-button "+t.prototype.buildWrapperCSSClass.call(this)},e.prototype.createItems=function(){var e=[];return this.player().tech_&&this.player().tech_.featuresNativeTextTracks||(e.push(new kr(this.player_,{kind:this.kind_})),this.hideThreshold_+=1),t.prototype.createItems.call(this,e)},e}(_r);Er.prototype.kind_="captions",Er.prototype.controlText_="Captions",He.registerComponent("CaptionsButton",Er);var xr=function(t){function e(){return re(this,e),ie(this,t.apply(this,arguments))}return oe(e,t),e.prototype.createEl=function(e,n,r){var o='<span class="vjs-menu-item-text">'+this.localize(this.options_.label);return"captions"===this.options_.track.kind&&(o+='\n        <span aria-hidden="true" class="vjs-icon-placeholder"></span>\n        <span class="vjs-control-text"> '+this.localize("Captions")+"</span>\n      "),o+="</span>",t.prototype.createEl.call(this,e,s({innerHTML:o},n),r)},e}(mr);He.registerComponent("SubsCapsMenuItem",xr);var Sr=function(t){function e(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};re(this,e);var o=ie(this,t.call(this,n,r));return o.label_="subtitles",["en","en-us","en-ca","fr-ca"].indexOf(o.player_.language_)>-1&&(o.label_="captions"),o.menuButton_.controlText(tt(o.label_)),o}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-subs-caps-button "+t.prototype.buildCSSClass.call(this)},e.prototype.buildWrapperCSSClass=function(){return"vjs-subs-caps-button "+t.prototype.buildWrapperCSSClass.call(this)},e.prototype.createItems=function(){var e=[];return this.player().tech_&&this.player().tech_.featuresNativeTextTracks||(e.push(new kr(this.player_,{kind:this.label_})),this.hideThreshold_+=1),e=t.prototype.createItems.call(this,e,xr)},e}(_r);Sr.prototype.kinds_=["captions","subtitles"],Sr.prototype.controlText_="Subtitles",He.registerComponent("SubsCapsButton",Sr);var jr=function(t){function e(n,r){re(this,e);var o=r.track,i=n.audioTracks();r.label=o.label||o.language||"Unknown",r.selected=o.enabled;var s=ie(this,t.call(this,n,r));s.track=o;var a=je(s,s.handleTracksChange);return i.addEventListener("change",a),s.on("dispose",function(){i.removeEventListener("change",a)}),s}return oe(e,t),e.prototype.handleClick=function(e){var n=this.player_.audioTracks();t.prototype.handleClick.call(this,e);for(var r=0;r<n.length;r++){var o=n[r];o.enabled=o===this.track}},e.prototype.handleTracksChange=function(t){this.selected(this.track.enabled)},e}(gr);He.registerComponent("AudioTrackMenuItem",jr);var Pr=function(t){function e(n){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return re(this,e),r.tracks=n.audioTracks(),ie(this,t.call(this,n,r))}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-audio-button "+t.prototype.buildCSSClass.call(this)},e.prototype.buildWrapperCSSClass=function(){return"vjs-audio-button "+t.prototype.buildWrapperCSSClass.call(this)},e.prototype.createItems=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[];this.hideThreshold_=1;for(var e=this.player_.audioTracks(),n=0;n<e.length;n++){var r=e[n];t.push(new jr(this.player_,{track:r,selectable:!0}))}return t},e}(yr);Pr.prototype.controlText_="Audio Track",He.registerComponent("AudioTrackButton",Pr);var Or=function(t){function e(n,r){re(this,e);var o=r.rate,i=parseFloat(o,10);r.label=o,r.selected=1===i,r.selectable=!0;var s=ie(this,t.call(this,n,r));return s.label=o,s.rate=i,s.on(n,"ratechange",s.update),s}return oe(e,t),e.prototype.handleClick=function(e){t.prototype.handleClick.call(this),this.player().playbackRate(this.rate)},e.prototype.update=function(t){this.selected(this.player().playbackRate()===this.rate)},e}(gr);Or.prototype.contentElType="button",He.registerComponent("PlaybackRateMenuItem",Or);var Ir=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.updateVisibility(),o.updateLabel(),o.on(n,"loadstart",o.updateVisibility),o.on(n,"ratechange",o.updateLabel),o}return oe(e,t),e.prototype.createEl=function(){var e=t.prototype.createEl.call(this);return this.labelEl_=g("div",{className:"vjs-playback-rate-value",innerHTML:"1x"}),e.appendChild(this.labelEl_),e},e.prototype.dispose=function(){this.labelEl_=null,t.prototype.dispose.call(this)},e.prototype.buildCSSClass=function(){return"vjs-playback-rate "+t.prototype.buildCSSClass.call(this)},e.prototype.buildWrapperCSSClass=function(){return"vjs-playback-rate "+t.prototype.buildWrapperCSSClass.call(this)},e.prototype.createMenu=function(){var t=new fr(this.player()),e=this.playbackRates();if(e)for(var n=e.length-1;n>=0;n--)t.addChild(new Or(this.player(),{rate:e[n]+"x"}));return t},e.prototype.updateARIAAttributes=function(){this.el().setAttribute("aria-valuenow",this.player().playbackRate())},e.prototype.handleClick=function(t){for(var e=this.player().playbackRate(),n=this.playbackRates(),r=n[0],o=0;o<n.length;o++)if(n[o]>e){r=n[o];break}this.player().playbackRate(r)},e.prototype.playbackRates=function(){return this.options_.playbackRates||this.options_.playerOptions&&this.options_.playerOptions.playbackRates},e.prototype.playbackRateSupported=function(){return this.player().tech_&&this.player().tech_.featuresPlaybackRate&&this.playbackRates()&&this.playbackRates().length>0},e.prototype.updateVisibility=function(t){this.playbackRateSupported()?this.removeClass("vjs-hidden"):this.addClass("vjs-hidden")},e.prototype.updateLabel=function(t){this.playbackRateSupported()&&(this.labelEl_.innerHTML=this.player().playbackRate()+"x")},e}(vr);Ir.prototype.controlText_="Playback Rate",He.registerComponent("PlaybackRateMenuButton",Ir);var Mr=function(t){function e(){return re(this,e),ie(this,t.apply(this,arguments))}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-spacer "+t.prototype.buildCSSClass.call(this)},e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:this.buildCSSClass()})},e}(He);He.registerComponent("Spacer",Mr);var Nr=function(t){function e(){return re(this,e),ie(this,t.apply(this,arguments))}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-custom-control-spacer "+t.prototype.buildCSSClass.call(this)},e.prototype.createEl=function(){var e=t.prototype.createEl.call(this,{className:this.buildCSSClass()});return e.innerHTML="&nbsp;",e},e}(Mr);He.registerComponent("CustomControlSpacer",Nr);var Rr=function(t){function e(){return re(this,e),ie(this,t.apply(this,arguments))}return oe(e,t),e.prototype.createEl=function(){return t.prototype.createEl.call(this,"div",{className:"vjs-control-bar",dir:"ltr"},{role:"group"})},e}(He);Rr.prototype.options_={children:["playToggle","volumePanel","currentTimeDisplay","timeDivider","durationDisplay","progressControl","liveDisplay","remainingTimeDisplay","customControlSpacer","playbackRateMenuButton","chaptersButton","descriptionsButton","subsCapsButton","audioTrackButton","fullscreenToggle"]},He.registerComponent("ControlBar",Rr);var Lr=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r));return o.on(n,"error",o.open),o}return oe(e,t),e.prototype.buildCSSClass=function(){return"vjs-error-display "+t.prototype.buildCSSClass.call(this)},e.prototype.content=function(){var t=this.player().error();return t?this.localize(t.message):""},e}(tn);Lr.prototype.options_=nt(tn.prototype.options_,{pauseOnOpen:!1,fillAlways:!0,temporary:!1,uncloseable:!0}),He.registerComponent("ErrorDisplay",Lr);var Dr=["#000","Black"],Br=["#00F","Blue"],Fr=["#0FF","Cyan"],Vr=["#0F0","Green"],Hr=["#F0F","Magenta"],Ur=["#F00","Red"],zr=["#FFF","White"],Wr=["#FF0","Yellow"],qr=["1","Opaque"],Gr=["0.5","Semi-Transparent"],Xr=["0","Transparent"],Kr={backgroundColor:{selector:".vjs-bg-color > select",id:"captions-background-color-%s",label:"Color",options:[Dr,zr,Ur,Vr,Br,Wr,Hr,Fr]},backgroundOpacity:{selector:".vjs-bg-opacity > select",id:"captions-background-opacity-%s",label:"Transparency",options:[qr,Gr,Xr]},color:{selector:".vjs-fg-color > select",id:"captions-foreground-color-%s",label:"Color",options:[zr,Dr,Ur,Vr,Br,Wr,Hr,Fr]},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:[qr,Gr]},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:[Xr,Gr,qr]}};Kr.windowColor.options=Kr.backgroundColor.options;var Yr=function(t){function e(n,r){re(this,e),r.temporary=!1;var i=ie(this,t.call(this,n,r));return i.updateDisplay=je(i,i.updateDisplay),i.fill(),i.hasBeenOpened_=i.hasBeenFilled_=!0,i.endDialog=g("p",{className:"vjs-control-text",textContent:i.localize("End of dialog window.")}),i.el().appendChild(i.endDialog),i.setDefaults(),void 0===r.persistTextTrackSettings&&(i.options_.persistTextTrackSettings=i.options_.playerOptions.persistTextTrackSettings),i.on(i.$(".vjs-done-button"),"click",function(){i.saveSettings(),i.close()}),i.on(i.$(".vjs-default-button"),"click",function(){i.setDefaults(),i.updateDisplay()}),o(Kr,function(t){i.on(i.$(t.selector),"change",i.updateDisplay)}),i.options_.persistTextTrackSettings&&i.restoreSettings(),i}return oe(e,t),e.prototype.dispose=function(){this.endDialog=null,t.prototype.dispose.call(this)},e.prototype.createElSelect_=function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"label",o=Kr[t],i=o.id.replace("%s",this.id_);return["<"+r+' id="'+i+'" class="'+("label"===r?"vjs-label":"")+'">',this.localize(o.label),"</"+r+">",'<select aria-labelledby="'+(""!==n?n+" ":"")+i+'">'].concat(o.options.map(function(t){var r=i+"-"+t[1];return['<option id="'+r+'" value="'+t[0]+'" ','aria-labelledby="'+(""!==n?n+" ":"")+i+" "+r+'">',e.localize(t[1]),"</option>"].join("")})).concat("</select>").join("")},e.prototype.createElFgColor_=function(){var t="captions-text-legend-"+this.id_;return['<fieldset class="vjs-fg-color vjs-track-setting">','<legend id="'+t+'">',this.localize("Text"),"</legend>",this.createElSelect_("color",t),'<span class="vjs-text-opacity vjs-opacity">',this.createElSelect_("textOpacity",t),"</span>","</fieldset>"].join("")},e.prototype.createElBgColor_=function(){var t="captions-background-"+this.id_;return['<fieldset class="vjs-bg-color vjs-track-setting">','<legend id="'+t+'">',this.localize("Background"),"</legend>",this.createElSelect_("backgroundColor",t),'<span class="vjs-bg-opacity vjs-opacity">',this.createElSelect_("backgroundOpacity",t),"</span>","</fieldset>"].join("")},e.prototype.createElWinColor_=function(){var t="captions-window-"+this.id_;return['<fieldset class="vjs-window-color vjs-track-setting">','<legend id="'+t+'">',this.localize("Window"),"</legend>",this.createElSelect_("windowColor",t),'<span class="vjs-window-opacity vjs-opacity">',this.createElSelect_("windowOpacity",t),"</span>","</fieldset>"].join("")},e.prototype.createElColors_=function(){return g("div",{className:"vjs-track-settings-colors",innerHTML:[this.createElFgColor_(),this.createElBgColor_(),this.createElWinColor_()].join("")})},e.prototype.createElFont_=function(){return g("div",{className:'vjs-track-settings-font">',innerHTML:['<fieldset class="vjs-font-percent vjs-track-setting">',this.createElSelect_("fontPercent","","legend"),"</fieldset>",'<fieldset class="vjs-edge-style vjs-track-setting">',this.createElSelect_("edgeStyle","","legend"),"</fieldset>",'<fieldset class="vjs-font-family vjs-track-setting">',this.createElSelect_("fontFamily","","legend"),"</fieldset>"].join("")})},e.prototype.createElControls_=function(){var t=this.localize("restore all settings to the default values");return g("div",{className:"vjs-track-settings-controls",innerHTML:['<button class="vjs-default-button" title="'+t+'">',this.localize("Reset"),'<span class="vjs-control-text"> '+t+"</span>","</button>",'<button class="vjs-done-button">'+this.localize("Done")+"</button>"].join("")})},e.prototype.content=function(){return[this.createElColors_(),this.createElFont_(),this.createElControls_()]},e.prototype.label=function(){return this.localize("Caption Settings Dialog")},e.prototype.description=function(){return this.localize("Beginning of dialog window. Escape will cancel and close the window.")},e.prototype.buildCSSClass=function(){return t.prototype.buildCSSClass.call(this)+" vjs-text-track-settings"},e.prototype.getValues=function(){var t=this;return i(Kr,function(e,n,r){var o=wt(t.$(n.selector),n.parser);return void 0!==o&&(e[r]=o),e},{})},e.prototype.setValues=function(t){var e=this;o(Kr,function(n,r){Ct(e.$(n.selector),t[r],n.parser)})},e.prototype.setDefaults=function(){var t=this;o(Kr,function(e){var n=e.hasOwnProperty("default")?e.default:0;t.$(e.selector).selectedIndex=n})},e.prototype.restoreSettings=function(){var t=void 0;try{t=JSON.parse(Et.localStorage.getItem("vjs-text-track-settings"))}catch(t){de.warn(t)}t&&this.setValues(t)},e.prototype.saveSettings=function(){if(this.options_.persistTextTrackSettings){var t=this.getValues();try{Object.keys(t).length?Et.localStorage.setItem("vjs-text-track-settings",JSON.stringify(t)):Et.localStorage.removeItem("vjs-text-track-settings")}catch(t){de.warn(t)}}},e.prototype.updateDisplay=function(){var t=this.player_.getChild("textTrackDisplay");t&&t.updateDisplay()},e.prototype.conditionalBlur_=function(){this.previouslyActiveEl_=null,this.off(xt,"keydown",this.handleKeyDown);var t=this.player_.controlBar,e=t&&t.subsCapsButton,n=t&&t.captionsButton;e?e.focus():n&&n.focus()},e}(tn);He.registerComponent("TextTrackSettings",Yr);var $r=se(["Text Tracks are being loaded from another origin but the crossorigin attribute isn't used.\n            This may prevent text tracks from loading."],["Text Tracks are being loaded from another origin but the crossorigin attribute isn't used.\n            This may prevent text tracks from loading."]),Qr=function(t){function e(n,r){re(this,e);var o=ie(this,t.call(this,n,r)),i=n.source,s=!1;if(i&&(o.el_.currentSrc!==i.src||n.tag&&3===n.tag.initNetworkState_)?o.setSource(i):o.handleLateInit_(o.el_),o.el_.hasChildNodes()){for(var a=o.el_.childNodes,l=a.length,c=[];l--;){var u=a[l];"track"===u.nodeName.toLowerCase()&&(o.featuresNativeTextTracks?(o.remoteTextTrackEls().addTrackElement_(u),o.remoteTextTracks().addTrack(u.track),o.textTracks().addTrack(u.track),s||o.el_.hasAttribute("crossorigin")||!An(u.src)||(s=!0)):c.push(u))}for(var h=0;h<c.length;h++)o.el_.removeChild(c[h])}return o.proxyNativeTracks_(),o.featuresNativeTextTracks&&s&&de.warn(St($r)),o.restoreMetadataTracksInIOSNativePlayer_(),(Zt||Dt||Wt)&&!0===n.nativeControlsForTouch&&o.setControls(!0),o.proxyWebkitFullscreen_(),o.triggerReady(),o}return oe(e,t),e.prototype.dispose=function(){e.disposeMediaElement(this.el_),this.options_=null,t.prototype.dispose.call(this)},e.prototype.restoreMetadataTracksInIOSNativePlayer_=function(){var t=this.textTracks(),e=void 0,n=function(){e=[];for(var n=0;n<t.length;n++){var r=t[n];"metadata"===r.kind&&e.push({track:r,storedMode:r.mode})}};n(),t.addEventListener("change",n),this.on("dispose",function(){return t.removeEventListener("change",n)});var r=function n(){for(var r=0;r<e.length;r++){var o=e[r];"disabled"===o.track.mode&&o.track.mode!==o.storedMode&&(o.track.mode=o.storedMode)}t.removeEventListener("change",n)};this.on("webkitbeginfullscreen",function(){t.removeEventListener("change",n),t.removeEventListener("change",r),t.addEventListener("change",r)}),this.on("webkitendfullscreen",function(){t.removeEventListener("change",n),t.addEventListener("change",n),t.removeEventListener("change",r)})},e.prototype.proxyNativeTracks_=function(){var t=this;jn.names.forEach(function(e){var n=jn[e],r=t.el()[n.getterName],o=t[n.getterName]();if(t["featuresNative"+n.capitalName+"Tracks"]&&r&&r.addEventListener){var i={change:function(t){o.trigger({type:"change",target:o,currentTarget:o,srcElement:o})},addtrack:function(t){o.addTrack(t.track)},removetrack:function(t){o.removeTrack(t.track)}},s=function(){for(var t=[],e=0;e<o.length;e++){for(var n=!1,i=0;i<r.length;i++)if(r[i]===o[e]){n=!0;break}n||t.push(o[e])}for(;t.length;)o.removeTrack(t.shift())};Object.keys(i).forEach(function(e){var n=i[e];r.addEventListener(e,n),t.on("dispose",function(t){return r.removeEventListener(e,n)})}),t.on("loadstart",s),t.on("dispose",function(e){return t.off("loadstart",s)})}})},e.prototype.createEl=function(){var t=this.options_.tag;if(!t||!this.options_.playerElIngest&&!this.movingMediaElementInDOM){if(t){var n=t.cloneNode(!0);t.parentNode&&t.parentNode.insertBefore(n,t),e.disposeMediaElement(t),t=n}else{t=xt.createElement("video");var r=this.options_.tag&&k(this.options_.tag),o=nt({},r);Zt&&!0===this.options_.nativeControlsForTouch||delete o.controls,C(t,s(o,{id:this.options_.techId,class:"vjs-tech"}))}t.playerId=this.options_.playerId}void 0!==this.options_.preload&&x(t,"preload",this.options_.preload);for(var i=["loop","muted","playsinline","autoplay"],a=0;a<i.length;a++){var l=i[a],c=this.options_[l];void 0!==c&&(c?x(t,l,l):S(t,l),t[l]=c)}return t},e.prototype.handleLateInit_=function(t){if(0!==t.networkState&&3!==t.networkState){if(0===t.readyState){var e=!1,n=function(){e=!0};this.on("loadstart",n);var r=function(){e||this.trigger("loadstart")};return this.on("loadedmetadata",r),void this.ready(function(){this.off("loadstart",n),this.off("loadedmetadata",r),e||this.trigger("loadstart")})}var o=["loadstart"];o.push("loadedmetadata"),t.readyState>=2&&o.push("loadeddata"),t.readyState>=3&&o.push("canplay"),t.readyState>=4&&o.push("canplaythrough"),this.ready(function(){o.forEach(function(t){this.trigger(t)},this)})}},e.prototype.setCurrentTime=function(t){try{this.el_.currentTime=t}catch(t){de(t,"Video is not ready. (Video.js)")}},e.prototype.duration=function(){var t=this;if(this.el_.duration===1/0&&Ht&&Xt&&0===this.el_.currentTime){var e=function e(){t.el_.currentTime>0&&(t.el_.duration===1/0&&t.trigger("durationchange"),t.off("timeupdate",e))};return this.on("timeupdate",e),NaN}return this.el_.duration||NaN},e.prototype.width=function(){return this.el_.offsetWidth},e.prototype.height=function(){return this.el_.offsetHeight},e.prototype.proxyWebkitFullscreen_=function(){var t=this;if("webkitDisplayingFullscreen"in this.el_){var e=function(){this.trigger("fullscreenchange",{isFullscreen:!1})},n=function(){"webkitPresentationMode"in this.el_&&"picture-in-picture"!==this.el_.webkitPresentationMode&&(this.one("webkitendfullscreen",e),this.trigger("fullscreenchange",{isFullscreen:!0}))};this.on("webkitbeginfullscreen",n),this.on("dispose",function(){t.off("webkitbeginfullscreen",n),t.off("webkitendfullscreen",e)})}},e.prototype.supportsFullScreen=function(){if("function"==typeof this.el_.webkitEnterFullScreen){var t=Et.navigator&&Et.navigator.userAgent||"";if(/Android/.test(t)||!/Chrome|Mac OS X 10.5/.test(t))return!0}return!1},e.prototype.enterFullScreen=function(){var t=this.el_;t.paused&&t.networkState<=t.HAVE_METADATA?(this.el_.play(),this.setTimeout(function(){t.pause(),t.webkitEnterFullScreen()},0)):t.webkitEnterFullScreen()},e.prototype.exitFullScreen=function(){this.el_.webkitExitFullScreen()},e.prototype.src=function(t){if(void 0===t)return this.el_.src;this.setSrc(t)},e.prototype.reset=function(){e.resetMediaElement(this.el_)},e.prototype.currentSrc=function(){return this.currentSource_?this.currentSource_.src:this.el_.currentSrc},e.prototype.setControls=function(t){this.el_.controls=!!t},e.prototype.addTextTrack=function(e,n,r){return this.featuresNativeTextTracks?this.el_.addTextTrack(e,n,r):t.prototype.addTextTrack.call(this,e,n,r)},e.prototype.createRemoteTextTrack=function(e){if(!this.featuresNativeTextTracks)return t.prototype.createRemoteTextTrack.call(this,e);var n=xt.createElement("track");return e.kind&&(n.kind=e.kind),e.label&&(n.label=e.label),(e.language||e.srclang)&&(n.srclang=e.language||e.srclang),e.default&&(n.default=e.default),e.id&&(n.id=e.id),e.src&&(n.src=e.src),n},e.prototype.addRemoteTextTrack=function(e,n){var r=t.prototype.addRemoteTextTrack.call(this,e,n);return this.featuresNativeTextTracks&&this.el().appendChild(r),r},e.prototype.removeRemoteTextTrack=function(e){if(t.prototype.removeRemoteTextTrack.call(this,e),this.featuresNativeTextTracks)for(var n=this.$$("track"),r=n.length;r--;)e!==n[r]&&e!==n[r].track||this.el().removeChild(n[r])},e.prototype.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),Et.performance&&"function"==typeof Et.performance.now?t.creationTime=Et.performance.now():Et.performance&&Et.performance.timing&&"number"==typeof Et.performance.timing.navigationStart&&(t.creationTime=Et.Date.now()-Et.performance.timing.navigationStart),t},e}(In);if(d()){Qr.TEST_VID=xt.createElement("video");var Jr=xt.createElement("track");Jr.kind="captions",Jr.srclang="en",Jr.label="English",Qr.TEST_VID.appendChild(Jr)}Qr.isSupported=function(){try{Qr.TEST_VID.volume=.5}catch(t){return!1}return!(!Qr.TEST_VID||!Qr.TEST_VID.canPlayType)},Qr.canPlayType=function(t){return Qr.TEST_VID.canPlayType(t)},Qr.canPlaySource=function(t,e){return Qr.canPlayType(t.type)},Qr.canControlVolume=function(){try{var t=Qr.TEST_VID.volume;return Qr.TEST_VID.volume=t/2+.1,t!==Qr.TEST_VID.volume}catch(t){return!1}},Qr.canControlPlaybackRate=function(){if(Ht&&Xt&&Kt<58)return!1;try{var t=Qr.TEST_VID.playbackRate;return Qr.TEST_VID.playbackRate=t/2+.1,t!==Qr.TEST_VID.playbackRate}catch(t){return!1}},Qr.supportsNativeTextTracks=function(){return Jt},Qr.supportsNativeVideoTracks=function(){return!(!Qr.TEST_VID||!Qr.TEST_VID.videoTracks)},Qr.supportsNativeAudioTracks=function(){return!(!Qr.TEST_VID||!Qr.TEST_VID.audioTracks)},Qr.Events=["loadstart","suspend","abort","error","emptied","stalled","loadedmetadata","loadeddata","canplay","canplaythrough","playing","waiting","seeking","seeked","ended","durationchange","timeupdate","progress","play","pause","ratechange","resize","volumechange"],Qr.prototype.featuresVolumeControl=Qr.canControlVolume(),Qr.prototype.featuresPlaybackRate=Qr.canControlPlaybackRate(),Qr.prototype.movingMediaElementInDOM=!Ft,Qr.prototype.featuresFullscreenResize=!0,Qr.prototype.featuresProgressEvents=!0,Qr.prototype.featuresTimeupdateEvents=!0,Qr.prototype.featuresNativeTextTracks=Qr.supportsNativeTextTracks(),Qr.prototype.featuresNativeVideoTracks=Qr.supportsNativeVideoTracks(),Qr.prototype.featuresNativeAudioTracks=Qr.supportsNativeAudioTracks();var Zr=Qr.TEST_VID&&Qr.TEST_VID.constructor.prototype.canPlayType,to=/^application\/(?:x-|vnd\.apple\.)mpegurl/i,eo=/^video\/mp4/i;Qr.patchCanPlayType=function(){Ut>=4&&!qt?Qr.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&to.test(t)?"maybe":Zr.call(this,t)}:zt&&(Qr.TEST_VID.constructor.prototype.canPlayType=function(t){return t&&eo.test(t)?"maybe":Zr.call(this,t)})},Qr.unpatchCanPlayType=function(){var t=Qr.TEST_VID.constructor.prototype.canPlayType;return Qr.TEST_VID.constructor.prototype.canPlayType=Zr,t},Qr.patchCanPlayType(),Qr.disposeMediaElement=function(t){if(t){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){}}()}},Qr.resetMediaElement=function(t){if(t){for(var e=t.querySelectorAll("source"),n=e.length;n--;)t.removeChild(e[n]);t.removeAttribute("src"),"function"==typeof t.load&&function(){try{t.load()}catch(t){}}()}},["muted","defaultMuted","autoplay","controls","loop","playsinline"].forEach(function(t){Qr.prototype[t]=function(){return this.el_[t]||this.el_.hasAttribute(t)}}),["muted","defaultMuted","autoplay","loop","playsinline"].forEach(function(t){Qr.prototype["set"+tt(t)]=function(e){this.el_[t]=e,e?this.el_.setAttribute(t,t):this.el_.removeAttribute(t)}}),["paused","currentTime","buffered","volume","poster","preload","error","seeking","seekable","ended","playbackRate","defaultPlaybackRate","played","networkState","readyState","videoWidth","videoHeight"].forEach(function(t){Qr.prototype[t]=function(){return this.el_[t]}}),["volume","src","poster","preload","playbackRate","defaultPlaybackRate"].forEach(function(t){Qr.prototype["set"+tt(t)]=function(e){this.el_[t]=e}}),["pause","load","play"].forEach(function(t){Qr.prototype[t]=function(){return this.el_[t]()}}),In.withSourceHandlers(Qr),Qr.nativeSourceHandler={},Qr.nativeSourceHandler.canPlayType=function(t){try{return Qr.TEST_VID.canPlayType(t)}catch(t){return""}},Qr.nativeSourceHandler.canHandleSource=function(t,e){if(t.type)return Qr.nativeSourceHandler.canPlayType(t.type);if(t.src){var n=mn(t.src);return Qr.nativeSourceHandler.canPlayType("video/"+n)}return""},Qr.nativeSourceHandler.handleSource=function(t,e,n){e.setSrc(t.src)},Qr.nativeSourceHandler.dispose=function(){},Qr.registerSourceHandler(Qr.nativeSourceHandler),In.registerTech("Html5",Qr);var no=se(["\n        Using the tech directly can be dangerous. I hope you know what you're doing.\n        See https://github.com/videojs/video.js/issues/2617 for more info.\n      "],["\n        Using the tech directly can be dangerous. I hope you know what you're doing.\n        See https://github.com/videojs/video.js/issues/2617 for more info.\n      "]),ro=["progress","abort","suspend","emptied","stalled","loadedmetadata","loadeddata","timeupdate","ratechange","resize","volumechange","texttrackchange"],oo=function(t){function e(n,r,o){if(re(this,e),n.id=n.id||"vjs_video_"+V(),r=s(e.getTagSettings(n),r),r.initChildren=!1,r.createEl=!1,r.evented=!1,r.reportTouchActivity=!1,!r.language)if("function"==typeof n.closest){var i=n.closest("[lang]");i&&i.getAttribute&&(r.language=i.getAttribute("lang"))}else for(var a=n;a&&1===a.nodeType;){if(k(a).hasOwnProperty("lang")){r.language=a.getAttribute("lang");break}a=a.parentNode}var l=ie(this,t.call(this,null,r,o));if(l.isReady_=!1,l.hasStarted_=!1,l.userActive_=!1,!l.options_||!l.options_.techOrder||!l.options_.techOrder.length)throw new Error("No techOrder specified. Did you overwrite videojs.options instead of just changing the properties you want to override?");if(l.tag=n,l.tagAttributes=n&&k(n),l.language(l.options_.language),r.languages){var c={};Object.getOwnPropertyNames(r.languages).forEach(function(t){c[t.toLowerCase()]=r.languages[t]}),l.languages_=c}else l.languages_=e.prototype.options_.languages;l.cache_={},l.poster_=r.poster||"",l.controls_=!!r.controls,l.cache_.lastVolume=1,n.controls=!1,n.removeAttribute("controls"),l.scrubbing_=!1,l.el_=l.createEl(),J(l,{eventBusKey:"el_"});var u=nt(l.options_);if(r.plugins){var h=r.plugins;Object.keys(h).forEach(function(t){if("function"!=typeof this[t])throw new Error('plugin "'+t+'" does not exist');this[t](h[t])},l)}l.options_.playerOptions=u,l.middleware_=[],l.initChildren(),l.isAudio("audio"===n.nodeName.toLowerCase()),l.controls()?l.addClass("vjs-controls-enabled"):l.addClass("vjs-controls-disabled"),l.el_.setAttribute("role","region"),l.isAudio()?l.el_.setAttribute("aria-label",l.localize("Audio Player")):l.el_.setAttribute("aria-label",l.localize("Video Player")),l.isAudio()&&l.addClass("vjs-audio"),l.flexNotSupported_()&&l.addClass("vjs-no-flex"),Ft||l.addClass("vjs-workinghover"),e.players[l.id_]=l;var p=It.split(".")[0];return l.addClass("vjs-v"+p),l.userActive(!0),l.reportUserActivity(),l.listenForUserActivity_(),l.on("fullscreenchange",l.handleFullscreenChange_),l.on("stageclick",l.handleStageClick_),l.changingSrc_=!1,l.playWaitingForReady_=!1,l.playOnLoadstart_=null,l.forceAutoplayInChrome_(),l}return oe(e,t),e.prototype.dispose=function(){this.trigger("dispose"),this.off("dispose"),this.styleEl_&&this.styleEl_.parentNode&&(this.styleEl_.parentNode.removeChild(this.styleEl_),this.styleEl_=null),e.players[this.id_]=null,this.tag&&this.tag.player&&(this.tag.player=null),this.el_&&this.el_.player&&(this.el_.player=null),this.tech_&&this.tech_.dispose(),this.playerElIngest_&&(this.playerElIngest_=null),this.tag&&(this.tag=null),t.prototype.dispose.call(this)},e.prototype.createEl=function(){var e=this.tag,n=void 0,r=this.playerElIngest_=e.parentNode&&e.parentNode.hasAttribute&&e.parentNode.hasAttribute("data-vjs-player"),o="video-js"===this.tag.tagName.toLowerCase();r?n=this.el_=e.parentNode:o||(n=this.el_=t.prototype.createEl.call(this,"div"));var i=k(e);if(o){for(n=this.el_=e,e=this.tag=xt.createElement("video");n.children.length;)e.appendChild(n.firstChild);_(n,"video-js")||b(n,"video-js"),n.appendChild(e),r=this.playerElIngest_=n}if(e.setAttribute("tabindex","-1"),e.removeAttribute("width"),e.removeAttribute("height"),Object.getOwnPropertyNames(i).forEach(function(t){"class"===t?(n.className+=" "+i[t],o&&(e.className+=" "+i[t])):(n.setAttribute(t,i[t]),o&&e.setAttribute(t,i[t]))}),e.playerId=e.id,e.id+="_html5_api",e.className="vjs-tech",e.player=n.player=this,this.addClass("vjs-paused"),!0!==Et.VIDEOJS_NO_DYNAMIC_STYLE){this.styleEl_=xe("vjs-styles-dimensions");var s=ve(".vjs-styles-defaults"),a=ve("head");a.insertBefore(this.styleEl_,s?s.nextSibling:a.firstChild)}this.width(this.options_.width),this.height(this.options_.height),this.fluid(this.options_.fluid),this.aspectRatio(this.options_.aspectRatio);for(var l=e.getElementsByTagName("a"),c=0;c<l.length;c++){var u=l.item(c);b(u,"vjs-hidden"),u.setAttribute("hidden","hidden")}return e.initNetworkState_=e.networkState,e.parentNode&&!r&&e.parentNode.insertBefore(n,e),A(e,n),this.children_.unshift(e),this.el_.setAttribute("lang",this.language_),this.el_=n,n},e.prototype.width=function(t,e){return this.dimension("width",t,e)},e.prototype.height=function(t,e){return this.dimension("height",t,e)},e.prototype.dimension=function(t,e,n){var r=t+"_";if(void 0===e)return this[r]||0;if(""===e)return this[r]=void 0,void this.updateStyleEl_();var o=parseFloat(e);if(isNaN(o))return void de.error('Improper value "'+e+'" supplied for for '+t);this[r]=o,this.updateStyleEl_(),this.isReady_&&!n&&this.trigger("playerresize")},e.prototype.fluid=function(t){if(void 0===t)return!!this.fluid_;this.fluid_=!!t,t?this.addClass("vjs-fluid"):this.removeClass("vjs-fluid"),this.updateStyleEl_()},e.prototype.aspectRatio=function(t){if(void 0===t)return this.aspectRatio_;if(!/^\d+\:\d+$/.test(t))throw new Error("Improper value supplied for aspect ratio. The format should be width:height, for example 16:9.");this.aspectRatio_=t,this.fluid(!0),this.updateStyleEl_()},e.prototype.updateStyleEl_=function(){if(!0===Et.VIDEOJS_NO_DYNAMIC_STYLE){var t="number"==typeof this.width_?this.width_:this.options_.width,e="number"==typeof this.height_?this.height_:this.options_.height,n=this.tech_&&this.tech_.el();return void(n&&(t>=0&&(n.width=t),e>=0&&(n.height=e)))}var r=void 0,o=void 0,i=void 0,s=void 0;i=void 0!==this.aspectRatio_&&"auto"!==this.aspectRatio_?this.aspectRatio_:this.videoWidth()>0?this.videoWidth()+":"+this.videoHeight():"16:9";var a=i.split(":"),l=a[1]/a[0];r=void 0!==this.width_?this.width_:void 0!==this.height_?this.height_/l:this.videoWidth()||300,o=void 0!==this.height_?this.height_:r*l,s=/^[^a-zA-Z]/.test(this.id())?"dimensions-"+this.id():this.id()+"-dimensions",this.addClass(s),Se(this.styleEl_,"\n      ."+s+" {\n        width: "+r+"px;\n        height: "+o+"px;\n      }\n\n      ."+s+".vjs-fluid {\n        padding-top: "+100*l+"%;\n      }\n    ")},e.prototype.loadTech_=function(t,e){var n=this;this.tech_&&this.unloadTech_();var r=tt(t),o=t.charAt(0).toLowerCase()+t.slice(1);"Html5"!==r&&this.tag&&(In.getTech("Html5").disposeMediaElement(this.tag),this.tag.player=null,this.tag=null),this.techName_=r,this.isReady_=!1;var i={source:e,nativeControlsForTouch:this.options_.nativeControlsForTouch,playerId:this.id(),techId:this.id()+"_"+r+"_api",autoplay:this.options_.autoplay,playsinline:this.options_.playsinline,preload:this.options_.preload,loop:this.options_.loop,muted:this.options_.muted,poster:this.poster(),language:this.language(),playerElIngest:this.playerElIngest_||!1,"vtt.js":this.options_["vtt.js"]};On.names.forEach(function(t){var e=On[t];i[e.getterName]=n[e.privateName]}),s(i,this.options_[r]),s(i,this.options_[o]),s(i,this.options_[t.toLowerCase()]),this.tag&&(i.tag=this.tag),e&&e.src===this.cache_.src&&this.cache_.currentTime>0&&(i.startTime=this.cache_.currentTime);var a=In.getTech(t);if(!a)throw new Error("No Tech named '"+r+"' exists! '"+r+"' should be registered using videojs.registerTech()'");this.tech_=new a(i),this.tech_.ready(je(this,this.handleTechReady_),!0),Je.jsonToTextTracks(this.textTracksJson_||[],this.tech_),ro.forEach(function(t){n.on(n.tech_,t,n["handleTech"+tt(t)+"_"])}),this.on(this.tech_,"loadstart",this.handleTechLoadStart_),this.on(this.tech_,"waiting",this.handleTechWaiting_),this.on(this.tech_,"canplay",this.handleTechCanPlay_),this.on(this.tech_,"canplaythrough",this.handleTechCanPlayThrough_),this.on(this.tech_,"playing",this.handleTechPlaying_),this.on(this.tech_,"ended",this.handleTechEnded_),this.on(this.tech_,"seeking",this.handleTechSeeking_),this.on(this.tech_,"seeked",this.handleTechSeeked_),this.on(this.tech_,"play",this.handleTechPlay_),this.on(this.tech_,"firstplay",this.handleTechFirstPlay_),this.on(this.tech_,"pause",this.handleTechPause_),this.on(this.tech_,"durationchange",this.handleTechDurationChange_),this.on(this.tech_,"fullscreenchange",this.handleTechFullscreenChange_),this.on(this.tech_,"error",this.handleTechError_),this.on(this.tech_,"loadedmetadata",this.updateStyleEl_),this.on(this.tech_,"posterchange",this.handleTechPosterChange_),this.on(this.tech_,"textdata",this.handleTechTextData_),this.usingNativeControls(this.techGet_("controls")),this.controls()&&!this.usingNativeControls()&&this.addTechControlsListeners_(),this.tech_.el().parentNode===this.el()||"Html5"===r&&this.tag||A(this.tech_.el(),this.el()),this.tag&&(this.tag.player=null,this.tag=null)},e.prototype.unloadTech_=function(){var t=this;On.names.forEach(function(e){var n=On[e];t[n.privateName]=t[n.getterName]()}),this.textTracksJson_=Je.textTracksToJson(this.tech_),this.isReady_=!1,this.tech_.dispose(),this.tech_=!1},e.prototype.tech=function(t){return void 0===t&&de.warn(St(no)),this.tech_},e.prototype.addTechControlsListeners_=function(){this.removeTechControlsListeners_(),this.on(this.tech_,"mousedown",this.handleTechClick_),this.on(this.tech_,"touchstart",this.handleTechTouchStart_),this.on(this.tech_,"touchmove",this.handleTechTouchMove_),this.on(this.tech_,"touchend",this.handleTechTouchEnd_),this.on(this.tech_,"tap",this.handleTechTap_)},e.prototype.removeTechControlsListeners_=function(){this.off(this.tech_,"tap",this.handleTechTap_),this.off(this.tech_,"touchstart",this.handleTechTouchStart_),this.off(this.tech_,"touchmove",this.handleTechTouchMove_),this.off(this.tech_,"touchend",this.handleTechTouchEnd_),this.off(this.tech_,"mousedown",this.handleTechClick_)},e.prototype.handleTechReady_=function(){if(this.triggerReady(),this.cache_.volume&&this.techCall_("setVolume",this.cache_.volume),this.handleTechPosterChange_(),this.handleTechDurationChange_(),(this.src()||this.currentSrc())&&this.tag&&this.options_.autoplay&&this.paused())try{delete this.tag.poster}catch(t){de("deleting tag.poster throws in some browsers",t)}},e.prototype.handleTechLoadStart_=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"))},e.prototype.hasStarted=function(t){if(void 0===t)return this.hasStarted_;t!==this.hasStarted_&&(this.hasStarted_=t,this.hasStarted_?(this.addClass("vjs-has-started"),this.trigger("firstplay")):this.removeClass("vjs-has-started"))},e.prototype.handleTechPlay_=function(){this.removeClass("vjs-ended"),this.removeClass("vjs-paused"),this.addClass("vjs-playing"),this.hasStarted(!0),this.trigger("play")},e.prototype.handleTechWaiting_=function(){var t=this;this.addClass("vjs-waiting"),this.trigger("waiting"),this.one("timeupdate",function(){return t.removeClass("vjs-waiting")})},e.prototype.handleTechCanPlay_=function(){this.removeClass("vjs-waiting"),this.trigger("canplay")},e.prototype.handleTechCanPlayThrough_=function(){this.removeClass("vjs-waiting"),this.trigger("canplaythrough")},e.prototype.handleTechPlaying_=function(){this.removeClass("vjs-waiting"),this.trigger("playing")},e.prototype.handleTechSeeking_=function(){this.addClass("vjs-seeking"),this.trigger("seeking")},e.prototype.handleTechSeeked_=function(){this.removeClass("vjs-seeking"),this.trigger("seeked")},e.prototype.handleTechFirstPlay_=function(){this.options_.starttime&&(de.warn("Passing the `starttime` option to the player will be deprecated in 6.0"),this.currentTime(this.options_.starttime)),this.addClass("vjs-has-started"),this.trigger("firstplay")},e.prototype.handleTechPause_=function(){this.removeClass("vjs-playing"),this.addClass("vjs-paused"),this.trigger("pause")},e.prototype.handleTechEnded_=function(){this.addClass("vjs-ended"),this.options_.loop?(this.currentTime(0),this.play()):this.paused()||this.pause(),this.trigger("ended")},e.prototype.handleTechDurationChange_=function(){this.duration(this.techGet_("duration"))},e.prototype.handleTechClick_=function(t){F(t)&&this.controls_&&(this.paused()?this.play():this.pause())},e.prototype.handleTechTap_=function(){this.userActive(!this.userActive())},e.prototype.handleTechTouchStart_=function(){this.userWasActive=this.userActive()},e.prototype.handleTechTouchMove_=function(){this.userWasActive&&this.reportUserActivity()},e.prototype.handleTechTouchEnd_=function(t){t.preventDefault()},e.prototype.handleFullscreenChange_=function(){this.isFullscreen()?this.addClass("vjs-fullscreen"):this.removeClass("vjs-fullscreen")},e.prototype.handleStageClick_=function(){this.reportUserActivity()},e.prototype.handleTechFullscreenChange_=function(t,e){e&&this.isFullscreen(e.isFullscreen),this.trigger("fullscreenchange")},e.prototype.handleTechError_=function(){var t=this.tech_.error();this.error(t)},e.prototype.handleTechTextData_=function(){var t=null;arguments.length>1&&(t=arguments[1]),this.trigger("textdata",t)},e.prototype.getCache=function(){return this.cache_},e.prototype.techCall_=function(t,e){this.ready(function(){if(t in Rn)return yt(this.middleware_,this.tech_,t,e);try{this.tech_&&this.tech_[t](e)}catch(t){throw de(t),t}},!0)},e.prototype.techGet_=function(t){if(this.tech_&&this.tech_.isReady_){if(t in Nn)return vt(this.middleware_,this.tech_,t);try{return this.tech_[t]()}catch(e){if(void 0===this.tech_[t])throw de("Video.js: "+t+" method not defined for "+this.techName_+" playback technology.",e),e;if("TypeError"===e.name)throw de("Video.js: "+t+" unavailable on "+this.techName_+" playback technology element.",e),this.tech_.isReady_=!1,e;throw de(e),e}}},e.prototype.play=function(){var t=this;if(this.playOnLoadstart_&&this.off("loadstart",this.playOnLoadstart_),this.isReady_){if(!this.changingSrc_&&(this.src()||this.currentSrc()))return this.techGet_("play");this.playOnLoadstart_=function(){t.playOnLoadstart_=null,ut(t.play())},this.one("loadstart",this.playOnLoadstart_)}else{if(this.playWaitingForReady_)return;this.playWaitingForReady_=!0,this.ready(function(){t.playWaitingForReady_=!1,ut(t.play())})}},e.prototype.pause=function(){this.techCall_("pause")},e.prototype.paused=function(){return!1!==this.techGet_("paused")},e.prototype.played=function(){return this.techGet_("played")||st(0,0)},e.prototype.scrubbing=function(t){if(void 0===t)return this.scrubbing_;this.scrubbing_=!!t,t?this.addClass("vjs-scrubbing"):this.removeClass("vjs-scrubbing")},e.prototype.currentTime=function(t){return void 0!==t?(t<0&&(t=0),void this.techCall_("setCurrentTime",t)):(this.cache_.currentTime=this.techGet_("currentTime")||0,this.cache_.currentTime)},e.prototype.duration=function(t){if(void 0===t)return void 0!==this.cache_.duration?this.cache_.duration:NaN;t=parseFloat(t),t<0&&(t=1/0),t!==this.cache_.duration&&(this.cache_.duration=t,t===1/0?this.addClass("vjs-live"):this.removeClass("vjs-live"),this.trigger("durationchange"))},e.prototype.remainingTime=function(){return this.duration()-this.currentTime()},e.prototype.remainingTimeDisplay=function(){return Math.floor(this.duration())-Math.floor(this.currentTime())},e.prototype.buffered=function(){var t=this.techGet_("buffered");return t&&t.length||(t=st(0,0)),t},e.prototype.bufferedPercent=function(){return at(this.buffered(),this.duration())},e.prototype.bufferedEnd=function(){var t=this.buffered(),e=this.duration(),n=t.end(t.length-1);return n>e&&(n=e),n},e.prototype.volume=function(t){var e=void 0;return void 0!==t?(e=Math.max(0,Math.min(1,parseFloat(t))),this.cache_.volume=e,this.techCall_("setVolume",e),void(e>0&&this.lastVolume_(e))):(e=parseFloat(this.techGet_("volume")),isNaN(e)?1:e)},e.prototype.muted=function(t){return void 0!==t?void this.techCall_("setMuted",t):this.techGet_("muted")||!1},e.prototype.defaultMuted=function(t){return void 0!==t?this.techCall_("setDefaultMuted",t):this.techGet_("defaultMuted")||!1},e.prototype.lastVolume_=function(t){return void 0!==t&&0!==t?void(this.cache_.lastVolume=t):this.cache_.lastVolume},e.prototype.supportsFullScreen=function(){return this.techGet_("supportsFullScreen")||!1},e.prototype.isFullscreen=function(t){return void 0!==t?void(this.isFullscreen_=!!t):!!this.isFullscreen_},e.prototype.requestFullscreen=function(){var t=Ue;this.isFullscreen(!0),t.requestFullscreen?(X(xt,t.fullscreenchange,je(this,function e(n){this.isFullscreen(xt[t.fullscreenElement]),!1===this.isFullscreen()&&K(xt,t.fullscreenchange,e),this.trigger("fullscreenchange")})),this.el_[t.requestFullscreen]()):this.tech_.supportsFullScreen()?this.techCall_("enterFullScreen"):(this.enterFullWindow(),this.trigger("fullscreenchange"))},e.prototype.exitFullscreen=function(){var t=Ue;this.isFullscreen(!1),t.requestFullscreen?xt[t.exitFullscreen]():this.tech_.supportsFullScreen()?this.techCall_("exitFullScreen"):(this.exitFullWindow(),this.trigger("fullscreenchange"))},e.prototype.enterFullWindow=function(){this.isFullWindow=!0,this.docOrigOverflow=xt.documentElement.style.overflow,X(xt,"keydown",je(this,this.fullWindowOnEscKey)),xt.documentElement.style.overflow="hidden",b(xt.body,"vjs-full-window"),this.trigger("enterFullWindow")},e.prototype.fullWindowOnEscKey=function(t){27===t.keyCode&&(!0===this.isFullscreen()?this.exitFullscreen():this.exitFullWindow())},e.prototype.exitFullWindow=function(){this.isFullWindow=!1,K(xt,"keydown",this.fullWindowOnEscKey),xt.documentElement.style.overflow=this.docOrigOverflow,T(xt.body,"vjs-full-window"),this.trigger("exitFullWindow")},e.prototype.canPlayType=function(t){for(var e=void 0,n=0,r=this.options_.techOrder;n<r.length;n++){var o=r[n],i=In.getTech(o);if(i||(i=He.getComponent(o)),i){if(i.isSupported()&&(e=i.canPlayType(t)))return e}else de.error('The "'+o+'" tech is undefined. Skipped browser support check for that tech.')}return""},e.prototype.selectSource=function(t){var e=this,n=this.options_.techOrder.map(function(t){return[t,In.getTech(t)]}).filter(function(t){var e=t[0],n=t[1];return n?n.isSupported():(de.error('The "'+e+'" tech is undefined. Skipped browser support check for that tech.'),!1)}),r=function(t,e,n){var r=void 0;return t.some(function(t){return e.some(function(e){if(r=n(t,e))return!0})}),r},o=function(t,n){var r=t[0];if(t[1].canPlaySource(n,e.options_[r.toLowerCase()]))return{source:n,tech:r}};return(this.options_.sourceOrder?r(t,n,function(t){return function(e,n){return t(n,e)}}(o)):r(n,t,o))||!1},e.prototype.src=function(t){var e=this;if(void 0===t)return this.cache_.src||"";var n=Ln(t);if(!n.length)return void this.setTimeout(function(){this.error({code:4,message:this.localize(this.options_.notSupportedMessage)})},0);this.cache_.sources=n,this.changingSrc_=!0,this.cache_.source=n[0],dt(this,n[0],function(t,r){if(e.middleware_=r,e.src_(t))return n.length>1?e.src(n.slice(1)):(e.setTimeout(function(){this.error({code:4,message:this.localize(this.options_.notSupportedMessage)})},0),void e.triggerReady());e.changingSrc_=!1,e.cache_.src=t.src,ft(r,e.tech_)})},e.prototype.src_=function(t){var e=this.selectSource([t]);return!e||(et(e.tech,this.techName_)?(this.ready(function(){this.tech_.constructor.prototype.hasOwnProperty("setSource")?this.techCall_("setSource",t):this.techCall_("src",t.src),"auto"===this.options_.preload&&this.load()},!0),!1):(this.changingSrc_=!0,this.loadTech_(e.tech,e.source),!1))},e.prototype.load=function(){this.techCall_("load")},e.prototype.reset=function(){this.loadTech_(this.options_.techOrder[0],null),this.techCall_("reset")},e.prototype.currentSources=function(){var t=this.currentSource(),e=[];return 0!==Object.keys(t).length&&e.push(t),this.cache_.sources||e},e.prototype.currentSource=function(){return this.cache_.source||{}},e.prototype.currentSrc=function(){return this.currentSource()&&this.currentSource().src||""},e.prototype.currentType=function(){return this.currentSource()&&this.currentSource().type||""},e.prototype.preload=function(t){return void 0!==t?(this.techCall_("setPreload",t),void(this.options_.preload=t)):this.techGet_("preload")},e.prototype.autoplay=function(t){return void 0!==t?(this.techCall_("setAutoplay",t),this.options_.autoplay=t,void this.ready(this.forceAutoplayInChrome_)):this.techGet_("autoplay",t)},e.prototype.forceAutoplayInChrome_=function(){this.paused()&&(this.autoplay()||this.options_.autoplay)&&Xt&&!Ht&&this.play()},e.prototype.playsinline=function(t){return void 0!==t?(this.techCall_("setPlaysinline",t),this.options_.playsinline=t,this):this.techGet_("playsinline")},e.prototype.loop=function(t){return void 0!==t?(this.techCall_("setLoop",t),void(this.options_.loop=t)):this.techGet_("loop")},e.prototype.poster=function(t){if(void 0===t)return this.poster_;t||(t=""),this.poster_=t,this.techCall_("setPoster",t),this.trigger("posterchange")},e.prototype.handleTechPosterChange_=function(){!this.poster_&&this.tech_&&this.tech_.poster&&(this.poster_=this.tech_.poster()||"",this.trigger("posterchange"))},e.prototype.controls=function(t){if(void 0===t)return!!this.controls_;t=!!t,this.controls_!==t&&(this.controls_=t,this.usingNativeControls()&&this.techCall_("setControls",t),this.controls_?(this.removeClass("vjs-controls-disabled"),this.addClass("vjs-controls-enabled"),this.trigger("controlsenabled"),this.usingNativeControls()||this.addTechControlsListeners_()):(this.removeClass("vjs-controls-enabled"),this.addClass("vjs-controls-disabled"),this.trigger("controlsdisabled"),this.usingNativeControls()||this.removeTechControlsListeners_()))},e.prototype.usingNativeControls=function(t){if(void 0===t)return!!this.usingNativeControls_;t=!!t,this.usingNativeControls_!==t&&(this.usingNativeControls_=t,this.usingNativeControls_?(this.addClass("vjs-using-native-controls"),this.trigger("usingnativecontrols")):(this.removeClass("vjs-using-native-controls"),this.trigger("usingcustomcontrols")))},e.prototype.error=function(t){return void 0===t?this.error_||null:null===t?(this.error_=t,this.removeClass("vjs-error"),void(this.errorDisplay&&this.errorDisplay.close())):(this.error_=new lt(t),this.addClass("vjs-error"),de.error("(CODE:"+this.error_.code+" "+lt.errorTypes[this.error_.code]+")",this.error_.message,this.error_),void this.trigger("error"))},e.prototype.reportUserActivity=function(t){this.userActivity_=!0},e.prototype.userActive=function(t){if(void 0===t)return this.userActive_;if((t=!!t)!==this.userActive_){if(this.userActive_=t,this.userActive_)return this.userActivity_=!0,this.removeClass("vjs-user-inactive"),this.addClass("vjs-user-active"),void this.trigger("useractive");this.tech_&&this.tech_.one("mousemove",function(t){t.stopPropagation(),t.preventDefault()}),this.userActivity_=!1,this.removeClass("vjs-user-active"),this.addClass("vjs-user-inactive"),this.trigger("userinactive")}},e.prototype.listenForUserActivity_=function(){var t=void 0,e=void 0,n=void 0,r=je(this,this.reportUserActivity),o=function(t){t.screenX===e&&t.screenY===n||(e=t.screenX,n=t.screenY,r())},i=function(){r(),this.clearInterval(t),t=this.setInterval(r,250)},s=function(e){r(),this.clearInterval(t)};this.on("mousedown",i),this.on("mousemove",o),this.on("mouseup",s),this.on("keydown",r),this.on("keyup",r);var a=void 0;this.setInterval(function(){if(this.userActivity_){this.userActivity_=!1,this.userActive(!0),this.clearTimeout(a);var t=this.options_.inactivityTimeout;t<=0||(a=this.setTimeout(function(){this.userActivity_||this.userActive(!1)},t))}},250)},e.prototype.playbackRate=function(t){return void 0!==t?void this.techCall_("setPlaybackRate",t):this.tech_&&this.tech_.featuresPlaybackRate?this.techGet_("playbackRate"):1},e.prototype.defaultPlaybackRate=function(t){return void 0!==t?this.techCall_("setDefaultPlaybackRate",t):this.tech_&&this.tech_.featuresPlaybackRate?this.techGet_("defaultPlaybackRate"):1},e.prototype.isAudio=function(t){return void 0!==t?void(this.isAudio_=!!t):!!this.isAudio_},e.prototype.addTextTrack=function(t,e,n){if(this.tech_)return this.tech_.addTextTrack(t,e,n)},e.prototype.addRemoteTextTrack=function(t,e){if(this.tech_)return this.tech_.addRemoteTextTrack(t,e)},e.prototype.removeRemoteTextTrack=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.track,n=void 0===e?arguments[0]:e;if(this.tech_)return this.tech_.removeRemoteTextTrack(n)},e.prototype.getVideoPlaybackQuality=function(){return this.techGet_("getVideoPlaybackQuality")},e.prototype.videoWidth=function(){return this.tech_&&this.tech_.videoWidth&&this.tech_.videoWidth()||0},e.prototype.videoHeight=function(){return this.tech_&&this.tech_.videoHeight&&this.tech_.videoHeight()||0},e.prototype.language=function(t){if(void 0===t)return this.language_;this.language_=String(t).toLowerCase()},e.prototype.languages=function(){return nt(e.prototype.options_.languages,this.languages_)},e.prototype.toJSON=function(){var t=nt(this.options_),e=t.tracks;t.tracks=[];for(var n=0;n<e.length;n++){var r=e[n];r=nt(r),r.player=void 0,t.tracks[n]=r}return t},e.prototype.createModal=function(t,e){var n=this;e=e||{},e.content=t||"";var r=new tn(this,e);return this.addChild(r),r.on("dispose",function(){n.removeChild(r)}),r.open(),r},e.getTagSettings=function(t){var e={sources:[],tracks:[]},n=k(t),r=n["data-setup"];if(_(t,"vjs-fluid")&&(n.fluid=!0),null!==r){var o=jt(r||"{}"),i=o[0],a=o[1];i&&de.error(i),s(n,a)}if(s(e,n),t.hasChildNodes())for(var l=t.childNodes,c=0,u=l.length;c<u;c++){var h=l[c],p=h.nodeName.toLowerCase();"source"===p?e.sources.push(k(h)):"track"===p&&e.tracks.push(k(h))}return e},e.prototype.flexNotSupported_=function(){var t=xt.createElement("i");return!("flexBasis"in t.style||"webkitFlexBasis"in t.style||"mozFlexBasis"in t.style||"msFlexBasis"in t.style||"msFlexOrder"in t.style)},e}(He);On.names.forEach(function(t){var e=On[t];oo.prototype[e.getterName]=function(){return this.tech_?this.tech_[e.getterName]():(this[e.privateName]=this[e.privateName]||new e.ListClass,this[e.privateName])}}),oo.players={};var io=Et.navigator;oo.prototype.options_={techOrder:In.defaultTechOrder_,html5:{},flash:{},inactivityTimeout:2e3,playbackRates:[],children:["mediaLoader","posterImage","textTrackDisplay","loadingSpinner","bigPlayButton","controlBar","errorDisplay","textTrackSettings"],language:io&&(io.languages&&io.languages[0]||io.userLanguage||io.language)||"en",languages:{},notSupportedMessage:"No compatible source was found for this media."},["ended","seeking","seekable","networkState","readyState"].forEach(function(t){oo.prototype[t]=function(){return this.techGet_(t)}}),ro.forEach(function(t){oo.prototype["handleTech"+tt(t)+"_"]=function(){return this.trigger(t)}}),He.registerComponent("Player",oo);var so={},ao=function(t){return so.hasOwnProperty(t)},lo=function(t){return ao(t)?so[t]:void 0},co=function(t,e){t.activePlugins_=t.activePlugins_||{},t.activePlugins_[e]=!0},uo=function(t,e,n){var r=(n?"before":"")+"pluginsetup";t.trigger(r,e),t.trigger(r+":"+e.name,e)},ho=function(t,e){var n=function(){uo(this,{name:t,plugin:e,instance:null},!0);var n=e.apply(this,arguments);return co(this,t),uo(this,{name:t,plugin:e,instance:n}),n};return Object.keys(e).forEach(function(t){n[t]=e[t]}),n},po=function(t,e){return e.prototype.name=t,function(){uo(this,{name:t,plugin:e,instance:null},!0);for(var n=arguments.length,r=Array(n),o=0;o<n;o++)r[o]=arguments[o];var i=new(Function.prototype.bind.apply(e,[null].concat([this].concat(r))));return this[t]=function(){return i},uo(this,i.getEventHash()),i}},fo=function(){function t(e){if(re(this,t),this.constructor===t)throw new Error("Plugin must be sub-classed; not directly instantiated.");this.player=e,J(this),delete this.trigger,Z(this,this.constructor.defaultState),co(e,this.name),this.dispose=je(this,this.dispose),e.on("dispose",this.dispose)}return t.prototype.version=function(){return this.constructor.VERSION},t.prototype.getEventHash=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return t.name=this.name,t.plugin=this.constructor,t.instance=this,t},t.prototype.trigger=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return Y(this.eventBusEl_,t,this.getEventHash(e))},t.prototype.handleStateChanged=function(t){},t.prototype.dispose=function(){var t=this.name,e=this.player;this.trigger("dispose"),this.off(),e.off("dispose",this.dispose),e.activePlugins_[t]=!1,this.player=this.state=null,e[t]=po(t,so[t])},t.isBasic=function(e){var n="string"==typeof e?lo(e):e;return"function"==typeof n&&!t.prototype.isPrototypeOf(n.prototype)},t.registerPlugin=function(e,n){if("string"!=typeof e)throw new Error('Illegal plugin name, "'+e+'", must be a string, was '+(void 0===e?"undefined":ne(e))+".");if(ao(e))de.warn('A plugin named "'+e+'" already exists. You may want to avoid re-registering plugins!');else if(oo.prototype.hasOwnProperty(e))throw new Error('Illegal plugin name, "'+e+'", cannot share a name with an existing player method!');if("function"!=typeof n)throw new Error('Illegal plugin for "'+e+'", must be a function, was '+(void 0===n?"undefined":ne(n))+".");return so[e]=n,"plugin"!==e&&(t.isBasic(n)?oo.prototype[e]=ho(e,n):oo.prototype[e]=po(e,n)),n},t.deregisterPlugin=function(t){if("plugin"===t)throw new Error("Cannot de-register base plugin.");ao(t)&&(delete so[t],delete oo.prototype[t])},t.getPlugins=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:Object.keys(so),e=void 0;return t.forEach(function(t){var n=lo(t);n&&(e=e||{},e[t]=n)}),e},t.getPluginVersion=function(t){var e=lo(t);return e&&e.VERSION||""},t}();fo.getPlugin=lo,fo.BASE_PLUGIN_NAME="plugin",fo.registerPlugin("plugin",fo),oo.prototype.usingPlugin=function(t){return!!this.activePlugins_&&!0===this.activePlugins_[t]},oo.prototype.hasPlugin=function(t){return!!ao(t)};var vo=function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+(void 0===e?"undefined":ne(e)));t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(t.super_=e)},yo=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=function(){t.apply(this,arguments)},r={};"object"===(void 0===e?"undefined":ne(e))?(e.constructor!==Object.prototype.constructor&&(n=e.constructor),r=e):"function"==typeof e&&(n=e),vo(n,t);for(var o in r)r.hasOwnProperty(o)&&(n.prototype[o]=r[o]);return n};if("undefined"==typeof HTMLVideoElement&&d()&&(xt.createElement("video"),xt.createElement("audio"),xt.createElement("track"),xt.createElement("video-js")),kt.hooks_={},kt.hooks=function(t,e){return kt.hooks_[t]=kt.hooks_[t]||[],e&&(kt.hooks_[t]=kt.hooks_[t].concat(e)),kt.hooks_[t]},kt.hook=function(t,e){kt.hooks(t,e)},kt.hookOnce=function(t,e){kt.hooks(t,[].concat(e).map(function(e){return function n(){kt.removeHook(t,n),e.apply(void 0,arguments)}}))},kt.removeHook=function(t,e){var n=kt.hooks(t).indexOf(e);return!(n<=-1)&&(kt.hooks_[t]=kt.hooks_[t].slice(),kt.hooks_[t].splice(n,1),!0)},!0!==Et.VIDEOJS_NO_DYNAMIC_STYLE&&d()){var go=ve(".vjs-styles-defaults");if(!go){go=xe("vjs-styles-defaults");var mo=ve("head");mo&&mo.insertBefore(go,mo.firstChild),Se(go,"\n      .video-js {\n        width: 300px;\n        height: 150px;\n      }\n\n      .vjs-fluid {\n        padding-top: 56.25%\n      }\n    ")}}Q(1,kt),kt.VERSION=It,kt.options=oo.prototype.options_,kt.getPlayers=function(){return oo.players},kt.players=oo.players,kt.getComponent=He.getComponent,kt.registerComponent=function(t,e){In.isTech(e)&&de.warn("The "+t+" tech was registered as a component. It should instead be registered using videojs.registerTech(name, tech)"),He.registerComponent.call(He,t,e)},kt.getTech=In.getTech,kt.registerTech=In.registerTech,kt.use=pt,kt.browser=ee,kt.TOUCH_ENABLED=Zt,kt.extend=yo,kt.mergeOptions=nt,kt.bind=je,kt.registerPlugin=fo.registerPlugin,kt.plugin=function(t,e){return de.warn("videojs.plugin() is deprecated; use videojs.registerPlugin() instead"),fo.registerPlugin(t,e)},kt.getPlugins=fo.getPlugins,kt.getPlugin=fo.getPlugin,kt.getPluginVersion=fo.getPluginVersion,kt.addLanguage=function(t,e){var n;return t=(""+t).toLowerCase(),kt.options.languages=nt(kt.options.languages,(n={},n[t]=e,n)),kt.options.languages[t]},kt.log=de,kt.createTimeRange=kt.createTimeRanges=st,kt.formatTime=bt,kt.parseUrl=yn,kt.isCrossOrigin=An,kt.EventTarget=Oe,kt.on=X,kt.one=$,kt.off=K,kt.trigger=Y,kt.xhr=Pt,kt.TextTrack=wn,kt.AudioTrack=Cn,kt.VideoTrack=kn,["isEl","isTextNode","createEl","hasClass","addClass","removeClass","toggleClass","setAttributes","getAttributes","emptyEl","appendContent","insertContent"].forEach(function(t){kt[t]=function(){return de.warn("videojs."+t+"() is deprecated; use videojs.dom."+t+"() instead"),ge[t].apply(null,arguments)}}),kt.computedStyle=c,kt.dom=ge,kt.url=_n,t.exports=kt},function(t,e,n){(function(e){var n;n="undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{},t.exports=n}).call(e,n(13))},function(t,e,n){(function(e){var r,o=void 0!==e?e:"undefined"!=typeof window?window:{},i=n(76);"undefined"!=typeof document?r=document:(r=o["__GLOBAL_DOCUMENT_CACHE@4"])||(r=o["__GLOBAL_DOCUMENT_CACHE@4"]=i),t.exports=r}).call(e,n(13))},function(t,e){},function(t,e){function n(t){return t.replace(/\n\r?\s*/g,"")}t.exports=function(t){for(var e="",r=0;r<arguments.length;r++)e+=n(t[r])+(arguments[r+1]||"");return e}},function(t,e){function n(t,e){var n,r=null;try{n=JSON.parse(t,e)}catch(t){r=t}return[r,n]}t.exports=n},function(t,e,n){"use strict";function r(t){for(var e in t)if(t.hasOwnProperty(e))return!1;return!0}function o(t,e,n){var r=t;return u(e)?(n=e,"string"==typeof t&&(r={uri:t})):r=p(e,{uri:t}),r.callback=n,r}function i(t,e,n){return e=o(t,e,n),s(e)}function s(t){function e(){4===u.readyState&&setTimeout(s,0)}function n(){var t=void 0;if(t=u.response?u.response:u.responseText||a(u),_)try{t=JSON.parse(t)}catch(t){}return t}function o(t){return clearTimeout(f),t instanceof Error||(t=new Error(""+(t||"Unknown XMLHttpRequest Error"))),t.statusCode=0,c(t,b)}function s(){if(!d){var e;clearTimeout(f),e=t.useXDR&&void 0===u.status?200:1223===u.status?204:u.status;var r=b,o=null;return 0!==e?(r={body:n(),statusCode:e,method:y,headers:{},url:v,rawRequest:u},u.getAllResponseHeaders&&(r.headers=h(u.getAllResponseHeaders()))):o=new Error("Internal XMLHttpRequest Error"),c(o,r,r.body)}}if(void 0===t.callback)throw new Error("callback argument missing");var l=!1,c=function(e,n,r){l||(l=!0,t.callback(e,n,r))},u=t.xhr||null;u||(u=t.cors||t.useXDR?new i.XDomainRequest:new i.XMLHttpRequest);var p,d,f,v=u.url=t.uri||t.url,y=u.method=t.method||"GET",g=t.body||t.data,m=u.headers=t.headers||{},A=!!t.sync,_=!1,b={body:void 0,headers:{},statusCode:0,method:y,url:v,rawRequest:u};if("json"in t&&!1!==t.json&&(_=!0,m.accept||m.Accept||(m.Accept="application/json"),"GET"!==y&&"HEAD"!==y&&(m["content-type"]||m["Content-Type"]||(m["Content-Type"]="application/json"),g=JSON.stringify(!0===t.json?g:t.json))),u.onreadystatechange=e,u.onload=s,u.onerror=o,u.onprogress=function(){},u.onabort=function(){d=!0},u.ontimeout=o,u.open(y,v,!A,t.username,t.password),A||(u.withCredentials=!!t.withCredentials),!A&&t.timeout>0&&(f=setTimeout(function(){if(!d){d=!0,u.abort("timeout");var t=new Error("XMLHttpRequest timeout");t.code="ETIMEDOUT",o(t)}},t.timeout)),u.setRequestHeader)for(p in m)m.hasOwnProperty(p)&&u.setRequestHeader(p,m[p]);else if(t.headers&&!r(t.headers))throw new Error("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(g||null),u}function a(t){if("document"===t.responseType)return t.responseXML;var e=t.responseXML&&"parsererror"===t.responseXML.documentElement.nodeName;return""!==t.responseType||e?null:t.responseXML}function l(){}var c=n(80),u=n(36),h=n(81),p=n(84);t.exports=i,i.XMLHttpRequest=c.XMLHttpRequest||l,i.XDomainRequest="withCredentials"in new i.XMLHttpRequest?i.XMLHttpRequest:c.XDomainRequest,function(t,e){for(var n=0;n<t.length;n++)e(t[n])}(["get","put","post","patch","head","delete"],function(t){i["delete"===t?"del":t]=function(e,n,r){return n=o(e,n,r),n.method=t.toUpperCase(),s(n)}})},function(t,e,n){(function(e){"undefined"!=typeof window?t.exports=window:void 0!==e?t.exports=e:"undefined"!=typeof self?t.exports=self:t.exports={}}).call(e,n(13))},function(t,e,n){var r=n(82),o=n(83),i=function(t){return"[object Array]"===Object.prototype.toString.call(t)};t.exports=function(t){if(!t)return{};var e={};return o(r(t).split("\n"),function(t){var n=t.indexOf(":"),o=r(t.slice(0,n)).toLowerCase(),s=r(t.slice(n+1));void 0===e[o]?e[o]=s:i(e[o])?e[o].push(s):e[o]=[e[o],s]}),e}},function(t,e){function n(t){return t.replace(/^\s*|\s*$/g,"")}e=t.exports=n,e.left=function(t){return t.replace(/^\s*/,"")},e.right=function(t){return t.replace(/\s*$/,"")}},function(t,e,n){function r(t,e,n){if(!a(e))throw new TypeError("iterator must be a function");arguments.length<3&&(n=this),"[object Array]"===l.call(t)?o(t,e,n):"string"==typeof t?i(t,e,n):s(t,e,n)}function o(t,e,n){for(var r=0,o=t.length;r<o;r++)c.call(t,r)&&e.call(n,t[r],r,t)}function i(t,e,n){for(var r=0,o=t.length;r<o;r++)e.call(n,t.charAt(r),r,t)}function s(t,e,n){for(var r in t)c.call(t,r)&&e.call(n,t[r],r,t)}var a=n(36);t.exports=r;var l=Object.prototype.toString,c=Object.prototype.hasOwnProperty},function(t,e){function n(){for(var t={},e=0;e<arguments.length;e++){var n=arguments[e];for(var o in n)r.call(n,o)&&(t[o]=n[o])}return t}t.exports=n;var r=Object.prototype.hasOwnProperty},function(t,e,n){var r=n(86),o=t.exports={WebVTT:n(87),VTTCue:n(88),VTTRegion:n(89)};r.vttjs=o,r.WebVTT=o.WebVTT;var i=o.VTTCue,s=o.VTTRegion,a=r.VTTCue,l=r.VTTRegion;o.shim=function(){r.VTTCue=i,r.VTTRegion=s},o.restore=function(){r.VTTCue=a,r.VTTRegion=l},r.VTTCue||o.shim()},function(t,e,n){(function(e){var n;n="undefined"!=typeof window?window:void 0!==e?e:"undefined"!=typeof self?self:{},t.exports=n}).call(e,n(13))},function(t,e){function n(t,e){this.name="ParsingError",this.code=t.code,this.message=e||t.message}function r(t){function e(t,e,n,r){return 3600*(0|t)+60*(0|e)+(0|n)+(0|r)/1e3}var n=t.match(/^(\d+):(\d{2})(:\d{2})?\.(\d{3})/);return n?n[3]?e(n[1],n[2],n[3].replace(":",""),n[4]):n[1]>59?e(n[1],n[2],0,n[4]):e(0,n[1],n[2],n[4]):null}function o(){this.values=y(null)}function i(t,e,n,r){var o=r?t.split(r):[t];for(var i in o)if("string"==typeof o[i]){var s=o[i].split(n);if(2===s.length){var a=s[0],l=s[1];e(a,l)}}}function s(t,e,s){function a(){var e=r(t);if(null===e)throw new n(n.Errors.BadTimeStamp,"Malformed timestamp: "+c);return t=t.replace(/^[^\sa-zA-Z-]+/,""),e}function l(){t=t.replace(/^\s+/,"")}var c=t;if(l(),e.startTime=a(),l(),"--\x3e"!==t.substr(0,3))throw new n(n.Errors.BadTimeStamp,"Malformed time stamp (time stamps must be separated by '--\x3e'): "+c);t=t.substr(3),l(),e.endTime=a(),l(),function(t,e){var n=new o;i(t,function(t,e){switch(t){case"region":for(var r=s.length-1;r>=0;r--)if(s[r].id===e){n.set(t,s[r].region);break}break;case"vertical":n.alt(t,e,["rl","lr"]);break;case"line":var o=e.split(","),i=o[0];n.integer(t,i),n.percent(t,i)&&n.set("snapToLines",!1),n.alt(t,i,["auto"]),2===o.length&&n.alt("lineAlign",o[1],["start","middle","end"]);break;case"position":o=e.split(","),n.percent(t,o[0]),2===o.length&&n.alt("positionAlign",o[1],["start","middle","end"]);break;case"size":n.percent(t,e);break;case"align":n.alt(t,e,["start","middle","end","left","right"])}},/:/,/\s/),e.region=n.get("region",null),e.vertical=n.get("vertical",""),e.line=n.get("line","auto"),e.lineAlign=n.get("lineAlign","start"),e.snapToLines=n.get("snapToLines",!0),e.size=n.get("size",100),e.align=n.get("align","middle"),e.position=n.get("position",{start:0,left:0,middle:50,end:100,right:100},e.align),e.positionAlign=n.get("positionAlign",{start:"start",left:"start",middle:"middle",end:"end",right:"end"},e.align)}(t,e)}function a(t,e){function n(t){return g[t]}for(var o,i=t.document.createElement("div"),s=i,a=[];null!==(o=function(){if(!e)return null;var t=e.match(/^([^<]*)(<[^>]+>?)?/);return function(t){return e=e.substr(t.length),t}(t[1]?t[1]:t[2])}());)if("<"!==o[0])s.appendChild(t.document.createTextNode(function(t){for(;u=t.match(/&(amp|lt|gt|lrm|rlm|nbsp);/);)t=t.replace(u[0],n);return t}(o)));else{if("/"===o[1]){a.length&&a[a.length-1]===o.substr(2).replace(">","")&&(a.pop(),s=s.parentNode);continue}var l,c=r(o.substr(1,o.length-2));if(c){l=t.document.createProcessingInstruction("timestamp",c),s.appendChild(l);continue}var u=o.match(/^<([^.\s\/0-9>]+)(\.[^\s\\>]+)?([^>\\]+)?(\\?)>?$/);if(!u)continue;if(!(l=function(e,n){var r=m[e];if(!r)return null;var o=t.document.createElement(r);o.localName=r;var i=A[e];return i&&n&&(o[i]=n.trim()),o}(u[1],u[3])))continue;if(!function(t,e){return!_[e.localName]||_[e.localName]===t.localName}(s,l))continue;u[2]&&(l.className=u[2].substr(1).replace("."," ")),a.push(u[1]),s.appendChild(l),s=l}return i}function l(t){for(var e=0;e<b.length;e++){var n=b[e];if(t>=n[0]&&t<=n[1])return!0}return!1}function c(t){function e(t,e){for(var n=e.childNodes.length-1;n>=0;n--)t.push(e.childNodes[n])}function n(t){if(!t||!t.length)return null;var r=t.pop(),o=r.textContent||r.innerText;if(o){var i=o.match(/^.*(\n|\r)/);return i?(t.length=0,i[0]):o}return"ruby"===r.tagName?n(t):r.childNodes?(e(t,r),n(t)):void 0}var r,o=[],i="";if(!t||!t.childNodes)return"ltr";for(e(o,t);i=n(o);)for(var s=0;s<i.length;s++)if(r=i.charCodeAt(s),l(r))return"rtl";return"ltr"}function u(t){if("number"==typeof t.line&&(t.snapToLines||t.line>=0&&t.line<=100))return t.line;if(!t.track||!t.track.textTrackList||!t.track.textTrackList.mediaElement)return-1;for(var e=t.track,n=e.textTrackList,r=0,o=0;o<n.length&&n[o]!==e;o++)"showing"===n[o].mode&&r++;return-1*++r}function h(){}function p(t,e,n){var r=/MSIE\s8\.0/.test(navigator.userAgent),o="rgba(255, 255, 255, 1)",i="rgba(0, 0, 0, 0.8)";r&&(o="rgb(255, 255, 255)",i="rgb(0, 0, 0)"),h.call(this),this.cue=e,this.cueDiv=a(t,e.text);var s={color:o,backgroundColor:i,position:"relative",left:0,right:0,top:0,bottom:0,display:"inline"};r||(s.writingMode=""===e.vertical?"horizontal-tb":"lr"===e.vertical?"vertical-lr":"vertical-rl",s.unicodeBidi="plaintext"),this.applyStyles(s,this.cueDiv),this.div=t.document.createElement("div"),s={textAlign:"middle"===e.align?"center":e.align,font:n.font,whiteSpace:"pre-line",position:"absolute"},r||(s.direction=c(this.cueDiv),s.writingMode=""===e.vertical?"horizontal-tb":"lr"===e.vertical?"vertical-lr":"vertical-rl".stylesunicodeBidi="plaintext"),this.applyStyles(s),this.div.appendChild(this.cueDiv);var l=0;switch(e.positionAlign){case"start":l=e.position;break;case"middle":l=e.position-e.size/2;break;case"end":l=e.position-e.size}""===e.vertical?this.applyStyles({left:this.formatStyle(l,"%"),width:this.formatStyle(e.size,"%")}):this.applyStyles({top:this.formatStyle(l,"%"),height:this.formatStyle(e.size,"%")}),this.move=function(t){this.applyStyles({top:this.formatStyle(t.top,"px"),bottom:this.formatStyle(t.bottom,"px"),left:this.formatStyle(t.left,"px"),right:this.formatStyle(t.right,"px"),height:this.formatStyle(t.height,"px"),width:this.formatStyle(t.width,"px")})}}function d(t){var e,n,r,o,i=/MSIE\s8\.0/.test(navigator.userAgent);if(t.div){n=t.div.offsetHeight,r=t.div.offsetWidth,o=t.div.offsetTop;var s=(s=t.div.childNodes)&&(s=s[0])&&s.getClientRects&&s.getClientRects();t=t.div.getBoundingClientRect(),e=s?Math.max(s[0]&&s[0].height||0,t.height/s.length):0}this.left=t.left,this.right=t.right,this.top=t.top||o,this.height=t.height||n,this.bottom=t.bottom||o+(t.height||n),this.width=t.width||r,this.lineHeight=void 0!==e?e:t.lineHeight,i&&!this.lineHeight&&(this.lineHeight=13)}function f(t,e,n,r){var o=new d(e),i=e.cue,s=u(i),a=[];if(i.snapToLines){var l;switch(i.vertical){case"":a=["+y","-y"],l="height";break;case"rl":a=["+x","-x"],l="width";break;case"lr":a=["-x","+x"],l="width"}var c=o.lineHeight,h=c*Math.round(s),p=n[l]+c,f=a[0];Math.abs(h)>p&&(h=h<0?-1:1,h*=Math.ceil(p/c)*c),s<0&&(h+=""===i.vertical?n.height:n.width,a=a.reverse()),o.move(f,h)}else{var v=o.lineHeight/n.height*100;switch(i.lineAlign){case"middle":s-=v/2;break;case"end":s-=v}switch(i.vertical){case"":e.applyStyles({top:e.formatStyle(s,"%")});break;case"rl":e.applyStyles({left:e.formatStyle(s,"%")});break;case"lr":e.applyStyles({right:e.formatStyle(s,"%")})}a=["+y","-x","+x","-y"],o=new d(e)}var y=function(t,e){for(var o,i=new d(t),s=1,a=0;a<e.length;a++){for(;t.overlapsOppositeAxis(n,e[a])||t.within(n)&&t.overlapsAny(r);)t.move(e[a]);if(t.within(n))return t;var l=t.intersectPercentage(n);s>l&&(o=new d(t),s=l),t=new d(i)}return o||i}(o,a);e.move(y.toCSSCompatValues(n))}function v(){}var y=Object.create||function(){function t(){}return function(e){if(1!==arguments.length)throw new Error("Object.create shim only accepts one parameter.");return t.prototype=e,new t}}();n.prototype=y(Error.prototype),n.prototype.constructor=n,n.Errors={BadSignature:{code:0,message:"Malformed WebVTT signature."},BadTimeStamp:{code:1,message:"Malformed time stamp."}},o.prototype={set:function(t,e){this.get(t)||""===e||(this.values[t]=e)},get:function(t,e,n){return n?this.has(t)?this.values[t]:e[n]:this.has(t)?this.values[t]:e},has:function(t){return t in this.values},alt:function(t,e,n){for(var r=0;r<n.length;++r)if(e===n[r]){this.set(t,e);break}},integer:function(t,e){/^-?\d+$/.test(e)&&this.set(t,parseInt(e,10))},percent:function(t,e){return!!(e.match(/^([\d]{1,3})(\.[\d]*)?%$/)&&(e=parseFloat(e))>=0&&e<=100)&&(this.set(t,e),!0)}};var g={"&amp;":"&","&lt;":"<","&gt;":">","&lrm;":"‎","&rlm;":"‏","&nbsp;":" "},m={c:"span",i:"i",b:"b",u:"u",ruby:"ruby",rt:"rt",v:"span",lang:"span"},A={v:"title",lang:"lang"},_={rt:"ruby"},b=[[1470,1470],[1472,1472],[1475,1475],[1478,1478],[1488,1514],[1520,1524],[1544,1544],[1547,1547],[1549,1549],[1563,1563],[1566,1610],[1645,1647],[1649,1749],[1765,1766],[1774,1775],[1786,1805],[1807,1808],[1810,1839],[1869,1957],[1969,1969],[1984,2026],[2036,2037],[2042,2042],[2048,2069],[2074,2074],[2084,2084],[2088,2088],[2096,2110],[2112,2136],[2142,2142],[2208,2208],[2210,2220],[8207,8207],[64285,64285],[64287,64296],[64298,64310],[64312,64316],[64318,64318],[64320,64321],[64323,64324],[64326,64449],[64467,64829],[64848,64911],[64914,64967],[65008,65020],[65136,65140],[65142,65276],[67584,67589],[67592,67592],[67594,67637],[67639,67640],[67644,67644],[67647,67669],[67671,67679],[67840,67867],[67872,67897],[67903,67903],[67968,68023],[68030,68031],[68096,68096],[68112,68115],[68117,68119],[68121,68147],[68160,68167],[68176,68184],[68192,68223],[68352,68405],[68416,68437],[68440,68466],[68472,68479],[68608,68680],[126464,126467],[126469,126495],[126497,126498],[126500,126500],[126503,126503],[126505,126514],[126516,126519],[126521,126521],[126523,126523],[126530,126530],[126535,126535],[126537,126537],[126539,126539],[126541,126543],[126545,126546],[126548,126548],[126551,126551],[126553,126553],[126555,126555],[126557,126557],[126559,126559],[126561,126562],[126564,126564],[126567,126570],[126572,126578],[126580,126583],[126585,126588],[126590,126590],[126592,126601],[126603,126619],[126625,126627],[126629,126633],[126635,126651],[1114109,1114109]];h.prototype.applyStyles=function(t,e){e=e||this.div;for(var n in t)t.hasOwnProperty(n)&&(e.style[n]=t[n])},h.prototype.formatStyle=function(t,e){return 0===t?0:t+e},p.prototype=y(h.prototype),p.prototype.constructor=p,d.prototype.move=function(t,e){switch(e=void 0!==e?e:this.lineHeight,t){case"+x":this.left+=e,this.right+=e;break;case"-x":this.left-=e,this.right-=e;break;case"+y":this.top+=e,this.bottom+=e;break;case"-y":this.top-=e,this.bottom-=e}},d.prototype.overlaps=function(t){return this.left<t.right&&this.right>t.left&&this.top<t.bottom&&this.bottom>t.top},d.prototype.overlapsAny=function(t){for(var e=0;e<t.length;e++)if(this.overlaps(t[e]))return!0;return!1},d.prototype.within=function(t){return this.top>=t.top&&this.bottom<=t.bottom&&this.left>=t.left&&this.right<=t.right},d.prototype.overlapsOppositeAxis=function(t,e){switch(e){case"+x":return this.left<t.left;case"-x":return this.right>t.right;case"+y":return this.top<t.top;case"-y":return this.bottom>t.bottom}},d.prototype.intersectPercentage=function(t){return Math.max(0,Math.min(this.right,t.right)-Math.max(this.left,t.left))*Math.max(0,Math.min(this.bottom,t.bottom)-Math.max(this.top,t.top))/(this.height*this.width)},d.prototype.toCSSCompatValues=function(t){return{top:this.top-t.top,bottom:t.bottom-this.bottom,left:this.left-t.left,right:t.right-this.right,height:this.height,width:this.width}},d.getSimpleBoxPosition=function(t){var e=t.div?t.div.offsetHeight:t.tagName?t.offsetHeight:0,n=t.div?t.div.offsetWidth:t.tagName?t.offsetWidth:0,r=t.div?t.div.offsetTop:t.tagName?t.offsetTop:0;return t=t.div?t.div.getBoundingClientRect():t.tagName?t.getBoundingClientRect():t,{left:t.left,right:t.right,top:t.top||r,height:t.height||e,bottom:t.bottom||r+(t.height||e),width:t.width||n}},v.StringDecoder=function(){return{decode:function(t){if(!t)return"";if("string"!=typeof t)throw new Error("Error - expected string data.");return decodeURIComponent(encodeURIComponent(t))}}},v.convertCueToDOMTree=function(t,e){return t&&e?a(t,e):null};v.processCues=function(t,e,n){if(!t||!e||!n)return null;for(;n.firstChild;)n.removeChild(n.firstChild);var r=t.document.createElement("div");if(r.style.position="absolute",r.style.left="0",r.style.right="0",r.style.top="0",r.style.bottom="0",r.style.margin="1.5%",n.appendChild(r),function(t){for(var e=0;e<t.length;e++)if(t[e].hasBeenReset||!t[e].displayState)return!0;return!1}(e)){var o=[],i=d.getSimpleBoxPosition(r),s=Math.round(.05*i.height*100)/100,a={font:s+"px sans-serif"};!function(){for(var n,s,l=0;l<e.length;l++)s=e[l],n=new p(t,s,a),r.appendChild(n.div),f(t,n,i,o),s.displayState=n.div,o.push(d.getSimpleBoxPosition(n))}()}else for(var l=0;l<e.length;l++)r.appendChild(e[l].displayState)},v.Parser=function(t,e,n){n||(n=e,e={}),e||(e={}),this.window=t,this.vttjs=e,this.state="INITIAL",this.buffer="",this.decoder=n||new TextDecoder("utf8"),this.regionList=[]},v.Parser.prototype={reportOrThrowError:function(t){if(!(t instanceof n))throw t;this.onparsingerror&&this.onparsingerror(t)},parse:function(t){function e(){for(var t=c.buffer,e=0;e<t.length&&"\r"!==t[e]&&"\n"!==t[e];)++e;var n=t.substr(0,e);return"\r"===t[e]&&++e,"\n"===t[e]&&++e,c.buffer=t.substr(e),n}function a(t){var e=new o;if(i(t,function(t,n){switch(t){case"id":e.set(t,n);break;case"width":e.percent(t,n);break;case"lines":e.integer(t,n);break;case"regionanchor":case"viewportanchor":var r=n.split(",");if(2!==r.length)break;var i=new o;if(i.percent("x",r[0]),i.percent("y",r[1]),!i.has("x")||!i.has("y"))break;e.set(t+"X",i.get("x")),e.set(t+"Y",i.get("y"));break;case"scroll":e.alt(t,n,["up"])}},/=/,/\s/),e.has("id")){var n=new(c.vttjs.VTTRegion||c.window.VTTRegion);n.width=e.get("width",100),n.lines=e.get("lines",3),n.regionAnchorX=e.get("regionanchorX",0),n.regionAnchorY=e.get("regionanchorY",100),n.viewportAnchorX=e.get("viewportanchorX",0),n.viewportAnchorY=e.get("viewportanchorY",100),n.scroll=e.get("scroll",""),c.onregion&&c.onregion(n),c.regionList.push({id:e.get("id"),region:n})}}function l(t){var e=new o;i(t,function(t,n){switch(t){case"MPEGT":e.integer(t+"S",n);break;case"LOCA":e.set(t+"L",r(n))}},/[^\d]:/,/,/),c.ontimestampmap&&c.ontimestampmap({MPEGTS:e.get("MPEGTS"),LOCAL:e.get("LOCAL")})}var c=this;t&&(c.buffer+=c.decoder.decode(t,{stream:!0}));try{var u;if("INITIAL"===c.state){if(!/\r\n|\n/.test(c.buffer))return this;u=e();var h=u.match(/^WEBVTT([ \t].*)?$/);if(!h||!h[0])throw new n(n.Errors.BadSignature);c.state="HEADER"}for(var p=!1;c.buffer;){if(!/\r\n|\n/.test(c.buffer))return this;switch(p?p=!1:u=e(),c.state){case"HEADER":/:/.test(u)?function(t){t.match(/X-TIMESTAMP-MAP/)?i(t,function(t,e){switch(t){case"X-TIMESTAMP-MAP":l(e)}},/=/):i(t,function(t,e){switch(t){case"Region":a(e)}},/:/)}(u):u||(c.state="ID");continue;case"NOTE":u||(c.state="ID");continue;case"ID":if(/^NOTE($|[ \t])/.test(u)){c.state="NOTE";break}if(!u)continue;if(c.cue=new(c.vttjs.VTTCue||c.window.VTTCue)(0,0,""),c.state="CUE",-1===u.indexOf("--\x3e")){c.cue.id=u;continue}case"CUE":try{s(u,c.cue,c.regionList)}catch(t){c.reportOrThrowError(t),c.cue=null,c.state="BADCUE";continue}c.state="CUETEXT";continue;case"CUETEXT":var d=-1!==u.indexOf("--\x3e");if(!u||d&&(p=!0)){c.oncue&&c.oncue(c.cue),c.cue=null,c.state="ID";continue}c.cue.text&&(c.cue.text+="\n"),c.cue.text+=u;continue;case"BADCUE":u||(c.state="ID");continue}}}catch(t){c.reportOrThrowError(t),"CUETEXT"===c.state&&c.cue&&c.oncue&&c.oncue(c.cue),c.cue=null,c.state="INITIAL"===c.state?"BADWEBVTT":"BADCUE"}return this},flush:function(){var t=this;try{if(t.buffer+=t.decoder.decode(),(t.cue||"HEADER"===t.state)&&(t.buffer+="\n\n",t.parse()),"INITIAL"===t.state)throw new n(n.Errors.BadSignature)}catch(e){t.reportOrThrowError(e)}return t.onflush&&t.onflush(),this}},t.exports=v},function(t,e){function n(t){return"string"==typeof t&&(!!a[t.toLowerCase()]&&t.toLowerCase())}function r(t){return"string"==typeof t&&(!!l[t.toLowerCase()]&&t.toLowerCase())}function o(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)t[r]=n[r]}return t}function i(t,e,i){var a=this,l=/MSIE\s8\.0/.test(navigator.userAgent),c={};l?a=document.createElement("custom"):c.enumerable=!0,a.hasBeenReset=!1;var u="",h=!1,p=t,d=e,f=i,v=null,y="",g=!0,m="auto",A="start",_=50,b="middle",T=50,w="middle";if(Object.defineProperty(a,"id",o({},c,{get:function(){return u},set:function(t){u=""+t}})),Object.defineProperty(a,"pauseOnExit",o({},c,{get:function(){return h},set:function(t){h=!!t}})),Object.defineProperty(a,"startTime",o({},c,{get:function(){return p},set:function(t){if("number"!=typeof t)throw new TypeError("Start time must be set to a number.");p=t,this.hasBeenReset=!0}})),Object.defineProperty(a,"endTime",o({},c,{get:function(){return d},set:function(t){if("number"!=typeof t)throw new TypeError("End time must be set to a number.");d=t,this.hasBeenReset=!0}})),Object.defineProperty(a,"text",o({},c,{get:function(){return f},set:function(t){f=""+t,this.hasBeenReset=!0}})),Object.defineProperty(a,"region",o({},c,{get:function(){return v},set:function(t){v=t,this.hasBeenReset=!0}})),Object.defineProperty(a,"vertical",o({},c,{get:function(){return y},set:function(t){var e=n(t);if(!1===e)throw new SyntaxError("An invalid or illegal string was specified.");y=e,this.hasBeenReset=!0}})),Object.defineProperty(a,"snapToLines",o({},c,{get:function(){return g},set:function(t){g=!!t,this.hasBeenReset=!0}})),Object.defineProperty(a,"line",o({},c,{get:function(){return m},set:function(t){if("number"!=typeof t&&t!==s)throw new SyntaxError("An invalid number or illegal string was specified.");m=t,this.hasBeenReset=!0}})),Object.defineProperty(a,"lineAlign",o({},c,{get:function(){return A},set:function(t){var e=r(t);if(!e)throw new SyntaxError("An invalid or illegal string was specified.");A=e,this.hasBeenReset=!0}})),Object.defineProperty(a,"position",o({},c,{get:function(){return _},set:function(t){if(t<0||t>100)throw new Error("Position must be between 0 and 100.");_=t,this.hasBeenReset=!0}})),Object.defineProperty(a,"positionAlign",o({},c,{get:function(){return b},set:function(t){var e=r(t);if(!e)throw new SyntaxError("An invalid or illegal string was specified.");b=e,this.hasBeenReset=!0}})),Object.defineProperty(a,"size",o({},c,{get:function(){return T},set:function(t){if(t<0||t>100)throw new Error("Size must be between 0 and 100.");T=t,this.hasBeenReset=!0}})),Object.defineProperty(a,"align",o({},c,{get:function(){return w},set:function(t){var e=r(t);if(!e)throw new SyntaxError("An invalid or illegal string was specified.");w=e,this.hasBeenReset=!0}})),a.displayState=void 0,l)return a}var s="auto",a={"":!0,lr:!0,rl:!0},l={start:!0,middle:!0,end:!0,left:!0,right:!0};i.prototype.getCueAsHTML=function(){return WebVTT.convertCueToDOMTree(window,this.text)},t.exports=i},function(t,e){function n(t){return"string"==typeof t&&(!!i[t.toLowerCase()]&&t.toLowerCase())}function r(t){return"number"==typeof t&&t>=0&&t<=100}function o(){var t=100,e=3,o=0,i=100,s=0,a=100,l="";Object.defineProperties(this,{width:{enumerable:!0,get:function(){return t},set:function(e){if(!r(e))throw new Error("Width must be between 0 and 100.");t=e}},lines:{enumerable:!0,get:function(){return e},set:function(t){if("number"!=typeof t)throw new TypeError("Lines must be set to a number.");e=t}},regionAnchorY:{enumerable:!0,get:function(){return i},set:function(t){if(!r(t))throw new Error("RegionAnchorX must be between 0 and 100.");i=t}},regionAnchorX:{enumerable:!0,get:function(){return o},set:function(t){if(!r(t))throw new Error("RegionAnchorY must be between 0 and 100.");o=t}},viewportAnchorY:{enumerable:!0,get:function(){return a},set:function(t){if(!r(t))throw new Error("ViewportAnchorY must be between 0 and 100.");a=t}},viewportAnchorX:{enumerable:!0,get:function(){return s},set:function(t){if(!r(t))throw new Error("ViewportAnchorX must be between 0 and 100.");s=t}},scroll:{enumerable:!0,get:function(){return l},set:function(t){var e=n(t);if(!1===e)throw new SyntaxError("An invalid or illegal string was specified.");l=e}}})}var i={"":!0,up:!0};t.exports=o}]);